forked from M3-Academy/desafio-react-e-typescript
feature/desafio-react-e-typescript #1
16
src/components/Main.tsx
Normal file
16
src/components/Main.tsx
Normal file
@ -0,0 +1,16 @@
|
||||
import React from "react";
|
||||
|
||||
import styles from "../styles/main.module.scss";
|
||||
import { Newsletter } from "./Newsletter";
|
||||
|
||||
const Main = () => {
|
||||
return (
|
||||
<main>
|
||||
<div className={styles["main-wrapper"]}>
|
||||
<Newsletter />
|
||||
</div>
|
||||
</main>
|
||||
);
|
||||
};
|
||||
|
||||
export { Main };
|
17
src/components/Newsletter.tsx
Normal file
17
src/components/Newsletter.tsx
Normal file
@ -0,0 +1,17 @@
|
||||
import React from "react";
|
||||
|
||||
import styles from "../styles/main.module.scss";
|
||||
import { CustomForm } from "./CustomForm";
|
||||
|
||||
const Newsletter = () => {
|
||||
return (
|
||||
<div className={styles["main-wrapper__newsletter"]}>
|
||||
<h2 className={styles["main-wrapper__newsletter-title"]}>
|
||||
Assine nossa newsletter
|
||||
</h2>
|
||||
<CustomForm place="E-mail" button="Enviar" />
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
export { Newsletter };
|
@ -1,11 +1,13 @@
|
||||
import React from "react";
|
||||
import { Footer } from "../components/Footer";
|
||||
import { Header } from "../components/Header";
|
||||
import { Main } from "../components/Main";
|
||||
|
||||
const Home = () => {
|
||||
return (
|
||||
<>
|
||||
<Header />
|
||||
<Main />
|
||||
<Footer />
|
||||
</>
|
||||
);
|
||||
|
@ -7,3 +7,4 @@
|
||||
//Project Parts
|
||||
@import "./partials/Header.module.scss";
|
||||
@import "./partials/Footer.module.scss";
|
||||
@import "./partials/MainContent.module.scss";
|
||||
|
@ -37,8 +37,8 @@
|
||||
outline: none;
|
||||
height: 12px;
|
||||
|
||||
::placeholder {
|
||||
color: $gray3;
|
||||
&::placeholder {
|
||||
color: $gray2;
|
||||
}
|
||||
}
|
||||
|
||||
|
92
src/styles/partials/MainContent.module.scss
Normal file
92
src/styles/partials/MainContent.module.scss
Normal file
@ -0,0 +1,92 @@
|
||||
.main-wrapper {
|
||||
&__newsletter {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
padding: 16px 0;
|
||||
|
||||
&-title {
|
||||
font-weight: 500;
|
||||
font-size: 18px;
|
||||
line-height: 21px;
|
||||
letter-spacing: 0.05em;
|
||||
margin: 0 0 8px 0;
|
||||
}
|
||||
|
||||
form {
|
||||
width: 37.4%;
|
||||
|
||||
.campo-busca {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
&__input {
|
||||
color: $gray3;
|
||||
font-size: 14px;
|
||||
line-height: 16px;
|
||||
border-radius: 5px;
|
||||
padding: 13px 16px;
|
||||
border: 1px solid #e5e5e5;
|
||||
width: 64.62%;
|
||||
outline: none;
|
||||
height: 14px;
|
||||
margin-right: 8px;
|
||||
|
||||
&::placeholder {
|
||||
color: $gray2;
|
||||
}
|
||||
}
|
||||
|
||||
&__img {
|
||||
padding: 14px 20px;
|
||||
background: $black;
|
||||
box-shadow: 0px 4px 4px rgba(0, 0, 0, 0.25);
|
||||
border-radius: 4px;
|
||||
color: $white;
|
||||
font-weight: 700;
|
||||
font-size: 12px;
|
||||
line-height: 14px;
|
||||
text-align: center;
|
||||
letter-spacing: 0.05em;
|
||||
width: 26.6%;
|
||||
height: 42px;
|
||||
border: none;
|
||||
|
||||
img {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@media screen and (min-width: 2500px) {
|
||||
.main-wrapper {
|
||||
&__newsletter {
|
||||
&-title {
|
||||
font-size: 36px;
|
||||
line-height: 42px;
|
||||
}
|
||||
|
||||
form {
|
||||
width: 37.4%;
|
||||
|
||||
.campo-busca {
|
||||
&__input {
|
||||
width: 67.9%;
|
||||
font-size: 28px;
|
||||
line-height: 33px;
|
||||
height: 31px;
|
||||
}
|
||||
|
||||
&__img {
|
||||
height: 59px;
|
||||
font-size: 24px;
|
||||
line-height: 28px;
|
||||
width: 26.4%;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user