forked from M3-Academy/desafio-react-e-typescript
Merge pull request 'feature/header' (#10) from feature/header into development
Reviewed-on: #10
This commit is contained in:
commit
099618cdf9
61
package-lock.json
generated
61
package-lock.json
generated
@ -22,6 +22,7 @@
|
||||
"react": "^18.2.0",
|
||||
"react-bootstrap": "^2.7.0",
|
||||
"react-dom": "^18.2.0",
|
||||
"react-router-dom": "^6.6.2",
|
||||
"react-scripts": "5.0.1",
|
||||
"react-text-mask": "^5.5.0",
|
||||
"typescript": "^4.9.4",
|
||||
@ -3140,6 +3141,14 @@
|
||||
"react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0"
|
||||
}
|
||||
},
|
||||
"node_modules/@remix-run/router": {
|
||||
"version": "1.2.1",
|
||||
"resolved": "https://registry.npmjs.org/@remix-run/router/-/router-1.2.1.tgz",
|
||||
"integrity": "sha512-XiY0IsyHR+DXYS5vBxpoBe/8veTeoRpMHP+vDosLZxL5bnpetzI0igkxkLZS235ldLzyfkxF+2divEwWHP3vMQ==",
|
||||
"engines": {
|
||||
"node": ">=14"
|
||||
}
|
||||
},
|
||||
"node_modules/@restart/hooks": {
|
||||
"version": "0.4.7",
|
||||
"resolved": "https://registry.npmjs.org/@restart/hooks/-/hooks-0.4.7.tgz",
|
||||
@ -15327,6 +15336,36 @@
|
||||
"node": ">=0.10.0"
|
||||
}
|
||||
},
|
||||
"node_modules/react-router": {
|
||||
"version": "6.6.2",
|
||||
"resolved": "https://registry.npmjs.org/react-router/-/react-router-6.6.2.tgz",
|
||||
"integrity": "sha512-uJPG55Pek3orClbURDvfljhqFvMgJRo59Pktywkk8hUUkTY2aRfza8Yhl/vZQXs+TNQyr6tu+uqz/fLxPICOGQ==",
|
||||
"dependencies": {
|
||||
"@remix-run/router": "1.2.1"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=14"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"react": ">=16.8"
|
||||
}
|
||||
},
|
||||
"node_modules/react-router-dom": {
|
||||
"version": "6.6.2",
|
||||
"resolved": "https://registry.npmjs.org/react-router-dom/-/react-router-dom-6.6.2.tgz",
|
||||
"integrity": "sha512-6SCDXxRQqW5af8ImOqKza7icmQ47/EMbz572uFjzvcArg3lZ+04PxSPp8qGs+p2Y+q+b+S/AjXv8m8dyLndIIA==",
|
||||
"dependencies": {
|
||||
"@remix-run/router": "1.2.1",
|
||||
"react-router": "6.6.2"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=14"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"react": ">=16.8",
|
||||
"react-dom": ">=16.8"
|
||||
}
|
||||
},
|
||||
"node_modules/react-scripts": {
|
||||
"version": "5.0.1",
|
||||
"resolved": "https://registry.npmjs.org/react-scripts/-/react-scripts-5.0.1.tgz",
|
||||
@ -20870,6 +20909,11 @@
|
||||
"@swc/helpers": "^0.4.14"
|
||||
}
|
||||
},
|
||||
"@remix-run/router": {
|
||||
"version": "1.2.1",
|
||||
"resolved": "https://registry.npmjs.org/@remix-run/router/-/router-1.2.1.tgz",
|
||||
"integrity": "sha512-XiY0IsyHR+DXYS5vBxpoBe/8veTeoRpMHP+vDosLZxL5bnpetzI0igkxkLZS235ldLzyfkxF+2divEwWHP3vMQ=="
|
||||
},
|
||||
"@restart/hooks": {
|
||||
"version": "0.4.7",
|
||||
"resolved": "https://registry.npmjs.org/@restart/hooks/-/hooks-0.4.7.tgz",
|
||||
@ -29643,6 +29687,23 @@
|
||||
"resolved": "https://registry.npmjs.org/react-refresh/-/react-refresh-0.11.0.tgz",
|
||||
"integrity": "sha512-F27qZr8uUqwhWZboondsPx8tnC3Ct3SxZA3V5WyEvujRyyNv0VYPhoBg1gZ8/MV5tubQp76Trw8lTv9hzRBa+A=="
|
||||
},
|
||||
"react-router": {
|
||||
"version": "6.6.2",
|
||||
"resolved": "https://registry.npmjs.org/react-router/-/react-router-6.6.2.tgz",
|
||||
"integrity": "sha512-uJPG55Pek3orClbURDvfljhqFvMgJRo59Pktywkk8hUUkTY2aRfza8Yhl/vZQXs+TNQyr6tu+uqz/fLxPICOGQ==",
|
||||
"requires": {
|
||||
"@remix-run/router": "1.2.1"
|
||||
}
|
||||
},
|
||||
"react-router-dom": {
|
||||
"version": "6.6.2",
|
||||
"resolved": "https://registry.npmjs.org/react-router-dom/-/react-router-dom-6.6.2.tgz",
|
||||
"integrity": "sha512-6SCDXxRQqW5af8ImOqKza7icmQ47/EMbz572uFjzvcArg3lZ+04PxSPp8qGs+p2Y+q+b+S/AjXv8m8dyLndIIA==",
|
||||
"requires": {
|
||||
"@remix-run/router": "1.2.1",
|
||||
"react-router": "6.6.2"
|
||||
}
|
||||
},
|
||||
"react-scripts": {
|
||||
"version": "5.0.1",
|
||||
"resolved": "https://registry.npmjs.org/react-scripts/-/react-scripts-5.0.1.tgz",
|
||||
|
@ -16,6 +16,7 @@
|
||||
"react": "^18.2.0",
|
||||
"react-bootstrap": "^2.7.0",
|
||||
"react-dom": "^18.2.0",
|
||||
"react-router-dom": "^6.6.2",
|
||||
"react-scripts": "5.0.1",
|
||||
"react-text-mask": "^5.5.0",
|
||||
"typescript": "^4.9.4",
|
||||
|
@ -1,21 +1,23 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<link rel="icon" href="%PUBLIC_URL%/favicon.ico" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
<meta name="theme-color" content="#000000" />
|
||||
<meta
|
||||
name="description"
|
||||
content="Web site created using create-react-app"
|
||||
/>
|
||||
<link rel="apple-touch-icon" href="%PUBLIC_URL%/logo192.png" />
|
||||
<!--
|
||||
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<link rel="icon" href="%PUBLIC_URL%/favicon.ico" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
<meta name="theme-color" content="#000000" />
|
||||
<meta name="description" content="Web site created using create-react-app" />
|
||||
<link rel="apple-touch-icon" href="%PUBLIC_URL%/logo192.png" />
|
||||
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.2.3/dist/css/bootstrap.min.css" rel="stylesheet"
|
||||
integrity="sha384-rbsA2VBKQhggwzxH7pPCaAqO46MgnOM80zW1RWuH61DGLwZJEdK2Kadq2F9CUG65" crossorigin="anonymous">
|
||||
<!--
|
||||
manifest.json provides metadata used when your web app is installed on a
|
||||
user's mobile device or desktop. See https://developers.google.com/web/fundamentals/web-app-manifest/
|
||||
|
||||
|
||||
-->
|
||||
<link rel="manifest" href="%PUBLIC_URL%/manifest.json" />
|
||||
<!--
|
||||
<link rel="manifest" href="%PUBLIC_URL%/manifest.json" />
|
||||
<!--
|
||||
Notice the use of %PUBLIC_URL% in the tags above.
|
||||
It will be replaced with the URL of the `public` folder during the build.
|
||||
Only files inside the `public` folder can be referenced from the HTML.
|
||||
@ -24,12 +26,13 @@
|
||||
work correctly both with client-side routing and a non-root public URL.
|
||||
Learn how to configure a non-root public URL by running `npm run build`.
|
||||
-->
|
||||
<title>React App</title>
|
||||
</head>
|
||||
<body>
|
||||
<noscript>You need to enable JavaScript to run this app.</noscript>
|
||||
<div id="root"></div>
|
||||
<!--
|
||||
<title>React App</title>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<noscript>You need to enable JavaScript to run this app.</noscript>
|
||||
<div id="root"></div>
|
||||
<!--
|
||||
This HTML file is a template.
|
||||
If you open it directly in the browser, you will see an empty page.
|
||||
|
||||
@ -38,6 +41,11 @@
|
||||
|
||||
To begin the development, run `npm start` or `yarn start`.
|
||||
To create a production bundle, use `npm run build` or `yarn build`.
|
||||
|
||||
-->
|
||||
</body>
|
||||
</html>
|
||||
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.2.3/dist/js/bootstrap.bundle.min.js"
|
||||
integrity="sha384-kenU1KFdBIe4zVF0s0G1M5b4hcpxyD9F7jL+jjXkk+Q2h455rYXK/7HAuoJl+0I4"
|
||||
crossorigin="anonymous"></script>
|
||||
</body>
|
||||
|
||||
</html>
|
34
src/components/Caminhos/Caminhos.tsx
Normal file
34
src/components/Caminhos/Caminhos.tsx
Normal file
@ -0,0 +1,34 @@
|
||||
import homeImg from "./assets/image/home.png";
|
||||
import styles from "./caminhos.module.scss";
|
||||
import { Link, Outlet } from "react-router-dom";
|
||||
import { Home } from "../../pages/Home";
|
||||
import React, { useState } from "react";
|
||||
|
||||
const Caminhos = (prop: { titulo: string }) => {
|
||||
return (
|
||||
<>
|
||||
<nav>
|
||||
<ul className={styles["caminhos-itens"]}>
|
||||
<li className={styles["caminhos-item"]}>
|
||||
<Link to="/">
|
||||
<img
|
||||
className={styles["home_img"]}
|
||||
src={homeImg}
|
||||
alt="Home image"
|
||||
/>
|
||||
</Link>
|
||||
</li>
|
||||
<li className={styles["caminhos-item"]}>
|
||||
<p>></p>
|
||||
</li>
|
||||
<li className={styles["caminhos-item"]}>
|
||||
<p>{prop.titulo}</p>
|
||||
</li>
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
<Outlet />
|
||||
</>
|
||||
);
|
||||
};
|
||||
export { Caminhos };
|
BIN
src/components/Caminhos/assets/image/home.png
Normal file
BIN
src/components/Caminhos/assets/image/home.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 480 B |
22
src/components/Caminhos/caminhos.module.scss
Normal file
22
src/components/Caminhos/caminhos.module.scss
Normal file
@ -0,0 +1,22 @@
|
||||
.caminhos-itens {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
gap: 5px;
|
||||
p {
|
||||
font-family: "Roboto";
|
||||
font-style: normal;
|
||||
font-weight: 400;
|
||||
font-size: 12px;
|
||||
text-transform: uppercase;
|
||||
color: #c4c4c4;
|
||||
@media screen and (min-width: 2500px) {
|
||||
font-size: 24px;
|
||||
}
|
||||
}
|
||||
}
|
||||
.home_img {
|
||||
width: 16px;
|
||||
@media screen and (min-width: 2500px) {
|
||||
width: 31.25px;
|
||||
}
|
||||
}
|
@ -1,8 +1,14 @@
|
||||
import React from "react";
|
||||
import m3LogoImg from "./assets/image/Logo-M3Academy.svg";
|
||||
|
||||
import styles from "./m3logo.module.scss";
|
||||
const M3Logo = () => {
|
||||
return <img src={m3LogoImg} alt="M3 Academy logo" />;
|
||||
return (
|
||||
<img
|
||||
className={styles["M3LogoImg"]}
|
||||
src={m3LogoImg}
|
||||
alt="M3 Academy logo"
|
||||
/>
|
||||
);
|
||||
};
|
||||
|
||||
export { M3Logo };
|
||||
|
6
src/components/M3Logo/m3logo.module.scss
Normal file
6
src/components/M3Logo/m3logo.module.scss
Normal file
@ -0,0 +1,6 @@
|
||||
.M3LogoImg {
|
||||
width: 136px;
|
||||
@media screen and (min-width: 2500px) {
|
||||
width: 265px;
|
||||
}
|
||||
}
|
@ -1,32 +1,79 @@
|
||||
import Container from "react-bootstrap/Container";
|
||||
import Nav from "react-bootstrap/Nav";
|
||||
import Navbar from "react-bootstrap/Navbar";
|
||||
import NavDropdown from "react-bootstrap/NavDropdown";
|
||||
import { M3Logo } from "../M3Logo/M3Logo";
|
||||
import styles from "./navigationBar.module.scss";
|
||||
|
||||
import m3LogoImg from "./assets/image/Logo-M3Academy.svg";
|
||||
import { Cart } from "../Cart/Cart";
|
||||
import React, { useState } from "react";
|
||||
import { Link, Outlet } from "react-router-dom";
|
||||
import { Enter } from "../Enter/Enter";
|
||||
const NavigationBar = () => {
|
||||
return (
|
||||
<Navbar collapseOnSelect expand="lg" bg="dark" variant="dark">
|
||||
<Container>
|
||||
<Navbar.Toggle aria-controls="responsive-navbar-nav" />
|
||||
<Navbar.Collapse id="responsive-navbar-nav">
|
||||
<Nav className="me-auto">
|
||||
<Nav.Link className={styles["cursosNav"]} href="#cursos">
|
||||
CURSOS
|
||||
</Nav.Link>
|
||||
<Nav.Link className={styles["saibaNav"]} href="#saibamais">
|
||||
SAIBA MAIS
|
||||
</Nav.Link>
|
||||
<Nav.Link
|
||||
className={styles["instituicionaisNav"]}
|
||||
href="#institucionais"
|
||||
>
|
||||
INSTITUCIONAIS
|
||||
</Nav.Link>
|
||||
</Nav>
|
||||
</Navbar.Collapse>
|
||||
</Container>
|
||||
</Navbar>
|
||||
<>
|
||||
<nav
|
||||
className="navbar navbar-expand-xpp bg-body-tertiary "
|
||||
id="navegador"
|
||||
>
|
||||
<div className="container-fluid">
|
||||
<button
|
||||
className="navbar-toggler"
|
||||
type="button"
|
||||
data-bs-toggle="offcanvas"
|
||||
data-bs-target="#navbarOffcanvasLg"
|
||||
aria-controls="navbarOffcanvasLg"
|
||||
aria-expanded="false"
|
||||
aria-label="Toggle navigation"
|
||||
>
|
||||
<span className="navbar-toggler-icon"></span>
|
||||
</button>
|
||||
<a className="navbar-brand" href="#">
|
||||
<img
|
||||
className="logoM3Img"
|
||||
src={m3LogoImg}
|
||||
alt="M3 Academy mobile"
|
||||
/>
|
||||
</a>
|
||||
<div className="carrinho-wrapper">
|
||||
<Cart />
|
||||
</div>
|
||||
|
||||
<div
|
||||
className="offcanvas offcanvas-end"
|
||||
id="navbarOffcanvasLg"
|
||||
aria-labelledby="navbarOffcanvasLgLabel"
|
||||
>
|
||||
<div className="offcanvas-header">
|
||||
<div className="entrar_wrapper">
|
||||
<Enter></Enter>
|
||||
</div>
|
||||
<button
|
||||
type="button"
|
||||
className="btn-close text-reset"
|
||||
data-bs-dismiss="offcanvas"
|
||||
aria-label="Close"
|
||||
></button>
|
||||
</div>
|
||||
|
||||
<ul className="navbar-nav">
|
||||
<li className="nav-item">
|
||||
<Link className="nav-link" to="/cursos">
|
||||
CURSOS
|
||||
</Link>
|
||||
</li>
|
||||
<li className="nav-item">
|
||||
<Link className="nav-link" to="/cursos">
|
||||
SAIBA MAIS
|
||||
</Link>
|
||||
</li>
|
||||
<li className="nav-item">
|
||||
<Link className="nav-link" to="/cursos">
|
||||
INSTITUCIONAIS
|
||||
</Link>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</nav>
|
||||
<Outlet />
|
||||
</>
|
||||
);
|
||||
};
|
||||
|
||||
|
File diff suppressed because one or more lines are too long
After Width: | Height: | Size: 19 KiB |
@ -1,28 +1 @@
|
||||
.cursosNav {
|
||||
color: #ffffff;
|
||||
font-family: "Roboto";
|
||||
font-weight: 500;
|
||||
font-size: 14px;
|
||||
@media screen and (min-width: 2500px) {
|
||||
font-size: 28px;
|
||||
}
|
||||
}
|
||||
.saibaNav {
|
||||
color: #ffffff;
|
||||
font-family: "Roboto";
|
||||
font-weight: 500;
|
||||
font-size: 14px;
|
||||
@media screen and (min-width: 2500px) {
|
||||
font-size: 28px;
|
||||
}
|
||||
}
|
||||
|
||||
.instituicionaisNav {
|
||||
color: #ffffff;
|
||||
font-family: "Roboto";
|
||||
font-weight: 500;
|
||||
font-size: 14px;
|
||||
@media screen and (min-width: 2500px) {
|
||||
font-size: 28px;
|
||||
}
|
||||
}
|
||||
|
27
src/components/Router/Router.tsx
Normal file
27
src/components/Router/Router.tsx
Normal file
@ -0,0 +1,27 @@
|
||||
import React from "react";
|
||||
import { Routes, Route, BrowserRouter } from "react-router-dom";
|
||||
import { Home } from "../../pages/Home";
|
||||
import { Teste } from "../../pages/Teste";
|
||||
import { Cursos } from "../../pages/Cursos";
|
||||
/*
|
||||
import Home from "./Home";
|
||||
import Sobre from "./Sobre";
|
||||
import Usuario from "./Usuario";
|
||||
<Route component={Home} path="/" exact />
|
||||
<Route component={Sobre} path="/sobre" />
|
||||
<Route component={Usuario} path="/usuario" />
|
||||
*/
|
||||
|
||||
const RoutesUrl = () => {
|
||||
return (
|
||||
<BrowserRouter>
|
||||
<Routes>
|
||||
<Route path="/" element={<Teste titulo={"home"} />}>
|
||||
<Route path="cursos" element={<Cursos titulo={"Cursos"} />} />
|
||||
</Route>
|
||||
</Routes>
|
||||
</BrowserRouter>
|
||||
);
|
||||
};
|
||||
|
||||
export { RoutesUrl };
|
@ -10,16 +10,8 @@
|
||||
gap: 10px;
|
||||
width: 264px;
|
||||
height: 32px;
|
||||
/*
|
||||
position: absolute;
|
||||
|
||||
left: 508px;
|
||||
top: 22px;
|
||||
*/
|
||||
/* white */
|
||||
|
||||
background: #ffffff;
|
||||
/* primary-700 */
|
||||
|
||||
border: 2px solid #f2f2f2;
|
||||
border-radius: 5px;
|
||||
@ -27,6 +19,11 @@
|
||||
width: 515.62px;
|
||||
height: 57px;
|
||||
}
|
||||
@media screen and (max-width: 1024px) {
|
||||
width: 992px;
|
||||
height: 36px;
|
||||
margin: 20px 0 20px 0;
|
||||
}
|
||||
}
|
||||
.buscaBtn {
|
||||
position: relative;
|
||||
@ -49,6 +46,10 @@
|
||||
font-size: 28px;
|
||||
}
|
||||
}
|
||||
@media screen and (max-width: 1024px) {
|
||||
right: 30px;
|
||||
top: 23px;
|
||||
}
|
||||
}
|
||||
|
||||
.searchImg {
|
||||
|
@ -1,14 +1,19 @@
|
||||
import React from "react";
|
||||
import ReactDOM from "react-dom/client";
|
||||
import "./styles/main.scss";
|
||||
import { Home } from "./pages/Home";
|
||||
|
||||
import { Home } from "./pages/Home";
|
||||
import { Teste } from "./pages/Teste";
|
||||
|
||||
import { BrowserRouter } from "react-router-dom";
|
||||
const root = ReactDOM.createRoot(
|
||||
document.getElementById("root") as HTMLElement
|
||||
);
|
||||
root.render(
|
||||
<React.StrictMode>
|
||||
<Home />
|
||||
<BrowserRouter>
|
||||
<Home titulo={"home"}></Home>
|
||||
</BrowserRouter>
|
||||
</React.StrictMode>
|
||||
);
|
||||
|
||||
|
15
src/pages/Cursos.tsx
Normal file
15
src/pages/Cursos.tsx
Normal file
@ -0,0 +1,15 @@
|
||||
import React from "react";
|
||||
import { CursosBody } from "../sectors/Body/CursosBody";
|
||||
import { Caminhos } from "../components/Caminhos/Caminhos";
|
||||
import { Header } from "../sectors/Header/Header";
|
||||
const Cursos = (prop: { titulo: string }) => {
|
||||
return (
|
||||
<div>
|
||||
<Header></Header>
|
||||
<Caminhos titulo={prop.titulo}></Caminhos>
|
||||
<CursosBody></CursosBody>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
export { Cursos };
|
@ -1,11 +1,10 @@
|
||||
import React from "react";
|
||||
import { AccordionBody } from "../components/AccordionBody/AccordionBody";
|
||||
import { Header } from "../sectors/Header/Header";
|
||||
|
||||
const Home = () => {
|
||||
//const style = { background: "black" };
|
||||
const Home = (prop: { titulo: string }) => {
|
||||
return (
|
||||
<div /*style={style}*/>
|
||||
<AccordionBody />
|
||||
<div>
|
||||
<Header></Header>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
13
src/pages/Teste.tsx
Normal file
13
src/pages/Teste.tsx
Normal file
@ -0,0 +1,13 @@
|
||||
import React from "react";
|
||||
import { Header } from "../sectors/Header/Header";
|
||||
import { Caminhos } from "../components/Caminhos/Caminhos";
|
||||
|
||||
const Teste = (prop: { titulo: string }) => {
|
||||
return (
|
||||
<div>
|
||||
<Caminhos titulo={prop.titulo}></Caminhos>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
export { Teste };
|
7
src/sectors/Body/CursosBody.tsx
Normal file
7
src/sectors/Body/CursosBody.tsx
Normal file
@ -0,0 +1,7 @@
|
||||
import React from "react";
|
||||
|
||||
const CursosBody = () => {
|
||||
return <h2>Cursos</h2>;
|
||||
};
|
||||
|
||||
export { CursosBody };
|
14
src/sectors/Header/BottomHeader/BottomHeader.tsx
Normal file
14
src/sectors/Header/BottomHeader/BottomHeader.tsx
Normal file
@ -0,0 +1,14 @@
|
||||
import { NavigationBar } from "../../../components/NavigationBar/NavigationBar";
|
||||
import { SearchBox } from "../../../components/SearchBox/SearchBox";
|
||||
const BottomHeader = () => {
|
||||
return (
|
||||
<div className="bottom_header">
|
||||
<NavigationBar></NavigationBar>
|
||||
<div className="search-wrapper">
|
||||
<SearchBox></SearchBox>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
export { BottomHeader };
|
@ -1,10 +1,11 @@
|
||||
import React from "react";
|
||||
import { TopHeader } from "./TopHeader/TopHeader";
|
||||
|
||||
import { BottomHeader } from "./BottomHeader/BottomHeader";
|
||||
const Header = () => {
|
||||
return (
|
||||
<header className="header">
|
||||
<TopHeader />
|
||||
<BottomHeader></BottomHeader>
|
||||
</header>
|
||||
);
|
||||
};
|
||||
|
@ -1,40 +1,21 @@
|
||||
import React from "react";
|
||||
import styles from "./styles.module.scss";
|
||||
import logoAcademy from "./assets/images/Logo-M3Academy 1.svg";
|
||||
import searchImg from "./assets/images/search_2.png";
|
||||
import cartImg from "./assets/images/cart_1.png";
|
||||
import { M3Logo } from "../../../components/M3Logo/M3Logo";
|
||||
|
||||
import { SearchBox } from "../../../components/SearchBox/SearchBox";
|
||||
import { Enter } from "../../../components/Enter/Enter";
|
||||
import { Cart } from "../../../components/Cart/Cart";
|
||||
const TopHeader = () => {
|
||||
return (
|
||||
<div className={styles["TopHeader"]}>
|
||||
<img
|
||||
className={styles["logoAcademyImg"]}
|
||||
alt="LogoM3Academy"
|
||||
src={logoAcademy}
|
||||
/>
|
||||
<div className={styles["search-wrapper"]}>
|
||||
<input
|
||||
className={styles["search-input"]}
|
||||
id="title-name"
|
||||
name="title-name"
|
||||
type="text"
|
||||
placeholder="Buscar"
|
||||
required
|
||||
/>
|
||||
<button className={styles["buscaBtn"]}>
|
||||
<img
|
||||
className={styles["searchImg"]}
|
||||
alt="LogoM3Academy"
|
||||
src={searchImg}
|
||||
/>
|
||||
</button>
|
||||
<div className="top_header">
|
||||
<M3Logo></M3Logo>
|
||||
<div className="search_box">
|
||||
<SearchBox></SearchBox>
|
||||
</div>
|
||||
<div className="sign_up">
|
||||
<Enter></Enter>
|
||||
<Cart></Cart>
|
||||
</div>
|
||||
<a className={styles["loginLink"]} href="/">
|
||||
ENTRAR
|
||||
</a>
|
||||
<a className={styles["cartLink"]} href="/">
|
||||
<img className={styles["cartImg"]} src={cartImg} alt="ImagemCarrinho" />
|
||||
</a>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
@ -18,12 +18,3 @@ button {
|
||||
li {
|
||||
list-style-type: none;
|
||||
}
|
||||
/*
|
||||
$grid-breakpoints: (
|
||||
xs: 0,
|
||||
sm: 375px,
|
||||
md: 768px,
|
||||
lg: 1025px,
|
||||
xl: 1280px,
|
||||
xxl: 2500px,
|
||||
);*/
|
||||
|
@ -3,4 +3,7 @@
|
||||
@import "common/reset.scss";
|
||||
@import "partials/header.scss";
|
||||
@import "partials/container.scss";
|
||||
@import "~bootstrap/scss/bootstrap";
|
||||
@import "utils/custom.scss";
|
||||
@import "partials/navigation.scss";
|
||||
@import "partials/top_header.scss";
|
||||
@import "partials/bottom_header.scss";
|
||||
|
21
src/styles/partials/bottom_header.scss
Normal file
21
src/styles/partials/bottom_header.scss
Normal file
@ -0,0 +1,21 @@
|
||||
.bottom_header {
|
||||
background: black;
|
||||
padding: 0 100px 0 64px;
|
||||
border-top: 1px solid #e5e5e5;
|
||||
@media screen and (max-width: 1025px) {
|
||||
padding: 0 16px 0 16px;
|
||||
}
|
||||
@media screen and (min-width: 1025px) {
|
||||
.search-wrapper {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
@media screen and (max-width: 1025px) {
|
||||
.bottom_header {
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
.search-wrapper {
|
||||
}
|
||||
}
|
||||
}
|
@ -1,6 +1,4 @@
|
||||
.header {
|
||||
width: 100%;
|
||||
height: 162px;
|
||||
background-color: $black100;
|
||||
padding-top: 22px;
|
||||
}
|
||||
|
58
src/styles/partials/navigation.scss
Normal file
58
src/styles/partials/navigation.scss
Normal file
@ -0,0 +1,58 @@
|
||||
@media screen and (min-width: 1025px) {
|
||||
.logoM3Img {
|
||||
display: none;
|
||||
}
|
||||
.carrinho-wrapper {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
.logoM3Img {
|
||||
width: 136px;
|
||||
}
|
||||
.nav-link {
|
||||
font-family: "Roboto";
|
||||
color: white;
|
||||
font-size: 14px;
|
||||
font-weight: 500;
|
||||
&:hover {
|
||||
color: aqua;
|
||||
}
|
||||
.active {
|
||||
color: aquamarine;
|
||||
}
|
||||
@media screen and (min-width: 2500px) {
|
||||
font-size: 28px;
|
||||
}
|
||||
@media screen and (max-width: 1025px) {
|
||||
color: #c4c4c4;
|
||||
}
|
||||
}
|
||||
.bottom_header {
|
||||
background: black;
|
||||
}
|
||||
|
||||
.navbar-toggler {
|
||||
background-color: transparent;
|
||||
}
|
||||
.navbar-toggler-icon {
|
||||
background-color: white;
|
||||
}
|
||||
|
||||
@media screen and (max-width: 1024px) {
|
||||
.container-fluid {
|
||||
padding: 0 0 0 0;
|
||||
}
|
||||
.navbar-nav {
|
||||
margin-left: 20px;
|
||||
}
|
||||
.offcanvas-header {
|
||||
background-color: black;
|
||||
}
|
||||
.btn-close {
|
||||
color: white;
|
||||
}
|
||||
.offcanvas {
|
||||
width: 100%;
|
||||
height: 585px;
|
||||
}
|
||||
}
|
15
src/styles/partials/top_header.scss
Normal file
15
src/styles/partials/top_header.scss
Normal file
@ -0,0 +1,15 @@
|
||||
.top_header {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: space-between;
|
||||
margin: 0 auto;
|
||||
padding: 22px 100px 22px 100px;
|
||||
@media screen and (max-width: 1024px) {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
.sign_up {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
gap: 55px;
|
||||
}
|
20
src/styles/utils/custom.scss
Normal file
20
src/styles/utils/custom.scss
Normal file
@ -0,0 +1,20 @@
|
||||
// Custom.scss
|
||||
// Option A: Include all of Bootstrap
|
||||
|
||||
// Include any default variable overrides here (though functions won't be available)
|
||||
@import "/node_modules/bootstrap/scss/functions";
|
||||
|
||||
$grid-breakpoints: (
|
||||
xs: 0,
|
||||
xsm: 362px,
|
||||
sm: 576px,
|
||||
md: 768px,
|
||||
lg: 992px,
|
||||
xpp: 1025px,
|
||||
xl: 1200px,
|
||||
xxl: 1400px,
|
||||
);
|
||||
|
||||
@import "/node_modules/bootstrap/scss/bootstrap.scss";
|
||||
|
||||
// Then add additional custom code here
|
Loading…
x
Reference in New Issue
Block a user