Compare commits

..

No commits in common. "main" and "feature/main-content-top" have entirely different histories.

11 changed files with 4 additions and 315 deletions

View File

@ -2,22 +2,12 @@
This project was bootstrapped with [Create React App](https://github.com/facebook/create-react-app).
## About
This project is an institutional page, with a mobile sidebar 'menu
hamburger', contact form with formik, accordion menu in the footer, input validation using yup and route navigation with no need to reload the page!
Este Projeto é uma página institucional, com 'menu hamburguer' mobile, formulário de contato com formik, menu acordeon no footer, validação de inputs utilizando yup e navegação por rotas sem necessidade de reload da página!
## Available Scripts
In the project directory, you can run:
### `npm start`
Rode o projeto no modo de desenvolvimento. \
Abra [http://localhost:3000](http://localhost:3000) para ve-lo no navegador.
Runs the app in the development mode.\
Open [http://localhost:3000](http://localhost:3000) to view it in the browser.
@ -54,19 +44,3 @@ You dont have to ever use `eject`. The curated feature set is suitable for sm
You can learn more in the [Create React App documentation](https://facebook.github.io/create-react-app/docs/getting-started).
To learn React, check out the [React documentation](https://reactjs.org/).
## Libraries that I used
React
react-dom
react-router-dom
typescript
sass
react-headless-accordion
Classnames
Formik
Yup
## Node version
node: ^16.18.11

View File

@ -1,3 +0,0 @@
<svg width="25" height="13" viewBox="0 0 25 13" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M23.7428 11.3959C23.741 11.6959 23.6177 11.9953 23.373 12.226L23.3728 12.2261C22.8668 12.7035 22.037 12.7035 21.5311 12.2261L21.5232 12.2345L21.5311 12.2261L12.3457 3.5599L12.0712 3.30091L11.7967 3.5599L2.61178 12.2258C2.10549 12.7033 1.27571 12.7032 0.769767 12.2259L0.769708 12.2258C0.525704 11.9957 0.402467 11.6972 0.400037 11.398C0.401876 11.0981 0.525111 10.7986 0.769782 10.5678L0.769785 10.5678L11.1506 0.773762C11.4013 0.537307 11.7333 0.415846 12.0712 0.415846C12.4093 0.415846 12.7415 0.537566 12.9922 0.773969L23.3728 10.568L23.3729 10.5681C23.6171 10.7983 23.7403 11.0968 23.7428 11.3959Z" fill="white" stroke="white" stroke-width="0.8"/>
</svg>

Before

Width:  |  Height:  |  Size: 764 B

View File

@ -1,11 +0,0 @@
<svg width="34" height="34" viewBox="0 0 34 34" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_3715_5917)">
<path d="M17.0042 0H16.9958C7.62238 0 0 7.6245 0 17C0 20.7188 1.1985 24.1655 3.23638 26.9641L1.11775 33.2796L7.65213 31.1908C10.3403 32.9715 13.5469 34 17.0042 34C26.3776 34 34 26.3734 34 17C34 7.62663 26.3776 0 17.0042 0Z" fill="#4CAF50"/>
<path d="M26.8962 24.0061C26.486 25.1642 24.8583 26.1247 23.5599 26.4052C22.6717 26.5944 21.5114 26.7452 17.6057 25.126C12.6098 23.0562 9.39255 17.9796 9.1418 17.6502C8.90167 17.3209 7.12305 14.9621 7.12305 12.5226C7.12305 10.0831 8.36192 8.89524 8.8613 8.38524C9.27142 7.96661 9.9493 7.77536 10.5995 7.77536C10.8099 7.77536 10.999 7.78599 11.169 7.79449C11.6684 7.81574 11.9192 7.84549 12.2485 8.63386C12.6587 9.62199 13.6574 12.0615 13.7764 12.3122C13.8975 12.563 14.0187 12.903 13.8487 13.2324C13.6893 13.5724 13.549 13.7232 13.2983 14.0122C13.0475 14.3012 12.8095 14.5222 12.5588 14.8325C12.3293 15.1024 12.07 15.3914 12.359 15.8907C12.648 16.3795 13.6468 18.0094 15.1173 19.3184C17.0149 21.0077 18.5534 21.5475 19.1038 21.777C19.5139 21.947 20.0027 21.9066 20.3023 21.5879C20.6827 21.1777 21.1523 20.4977 21.6304 19.8284C21.9704 19.3481 22.3997 19.2886 22.8502 19.4586C23.3092 19.618 25.738 20.8186 26.2374 21.0672C26.7368 21.318 27.0662 21.437 27.1873 21.6474C27.3063 21.8577 27.3063 22.8459 26.8962 24.0061Z" fill="white"/>
</g>
<defs>
<clipPath id="clip0_3715_5917">
<rect width="34" height="34" fill="white"/>
</clipPath>
</defs>
</svg>

Before

Width:  |  Height:  |  Size: 1.5 KiB

View File

@ -12,8 +12,6 @@ import { Contato } from "../components/main/components/Contato";
import home from "../assets/svgs/home.svg";
import seta from "../assets/svgs/seta.svg";
import whats from "../assets/svgs/whatsapp.svg";
import setaCima from "../assets/svgs/seta-para-cima.svg";
const MainContent = () => {
return (
@ -47,25 +45,6 @@ const MainContent = () => {
<Route path="/contato" element={<Contato />} />
</Routes>
</Router>
<a
className={style["main-link-topButton"]}
href="https://api.whatsapp.com/send/?phone=%2B5522997240484&text&type=phone_number&app_absent=0"
target="_blank"
>
<img
className={style["main-whatssap-link"]}
src={whats}
alt="Whatsapp"
/>
</a>
<a className={style["main-link-topButton"]} href="#">
<img
className={style["main-content-backToTop"]}
src={setaCima}
alt="Volte ao Topo"
/>
</a>
</main>
);
};

View File

@ -5,10 +5,6 @@
height: 64px;
background: variables.$color-black;
@media screen and (min-width: 2500px) {
height: 96px;
}
@media screen and (max-width: 1024px) {
height: 134px;
}
@ -41,11 +37,6 @@
text-transform: capitalize;
color: variables.$color-white;
@media screen and (min-width: 2500px) {
font-size: 20px;
line-height: 23px;
}
@media screen and (max-width: 1024px) {
order: 1;
width: 100%;
@ -65,23 +56,11 @@
width: 100%;
}
.creditcard {
@media screen and (min-width: 2500px) {
height: 40px;
}
}
.footer-line {
width: 24px;
border: 1px solid variables.$color-grey;
transform: rotate(90deg);
}
.vtex-certified {
@media screen and (min-width: 2500px) {
height: 66px;
}
}
}
.footer-copyright {
@ -97,14 +76,6 @@
width: 100%;
}
a {
img {
@media screen and (min-width: 2500px) {
height: 30px;
}
}
}
span {
font-weight: 400;
font-size: 10px;
@ -112,11 +83,6 @@
text-transform: capitalize;
white-space: nowrap;
color: variables.$color-white;
@media screen and (min-width: 2500px) {
font-size: 20px;
line-height: 23px;
}
}
}
}

View File

@ -9,10 +9,6 @@
display: flex;
position: relative;
@media screen and (min-width: 2500px) {
height: 297px;
}
.footer-wrapper {
display: flex;
justify-content: space-between;
@ -94,10 +90,6 @@
display: flex;
gap: 121px;
@media screen and (min-width: 2500px) {
gap: 293px;
}
@media screen and (max-width: 1024px) {
display: none;
}
@ -113,11 +105,6 @@
line-height: 16px;
text-transform: uppercase;
color: variables.$color-black3;
@media screen and (min-width: 2500px) {
font-size: 28px;
line-height: 33px;
}
}
h4 {
@ -126,11 +113,6 @@
line-height: 14px;
text-transform: capitalize;
color: variables.$color-black3;
@media screen and (min-width: 2500px) {
font-size: 24px;
line-height: 28px;
}
}
a {
@ -140,11 +122,6 @@
text-transform: capitalize;
text-decoration: none;
color: variables.$color-black3;
@media screen and (min-width: 2500px) {
font-size: 24px;
line-height: 28px;
}
}
}
}
@ -164,12 +141,6 @@
.footer-social-media-wrapper {
display: flex;
gap: 10px;
img {
@media screen and (min-width: 2500px) {
height: 70px;
}
}
}
a {
@ -178,11 +149,6 @@
line-height: 16px;
text-decoration: none;
color: variables.$color-black3;
@media screen and (min-width: 2500px) {
font-size: 28px;
line-height: 33px;
}
}
}
}

View File

@ -21,23 +21,13 @@
a {
img {
width: 100%;
height: 16px;
@media screen and (min-width: 2500px) {
height: 31.25px;
}
width: auto;
}
}
figure {
img {
width: 100%;
height: 8px;
@media screen and (min-width: 2500px) {
height: 15.62px;
}
width: auto;
}
}
@ -46,13 +36,6 @@
font-size: 12px;
line-height: 14px;
color: variables.$color-grey;
text-transform: uppercase;
@media screen and (min-width: 2500px) {
font-weight: 400;
font-size: 24px;
line-height: 28px;
}
}
}
@ -67,11 +50,6 @@
letter-spacing: 0.1em;
text-transform: uppercase;
color: variables.$color-black2;
@media screen and (min-width: 2500px) {
font-size: 48px;
line-height: 56px;
}
}
@media screen and (max-width: 1024px) {
@ -113,11 +91,6 @@
line-height: 19px;
color: variables.$color-grey3;
text-decoration: none;
@media screen and (min-width: 2500px) {
font-size: 32px;
line-height: 38px;
}
}
.selected {
@ -153,11 +126,6 @@
color: variables.$color-black2;
margin-bottom: 12px;
@media screen and (min-width: 2500px) {
font-size: 48px;
line-height: 56px;
}
@media screen and (max-width: 1024px) {
text-align: center;
}
@ -169,60 +137,6 @@
line-height: 15px;
color: variables.$color-grey3;
margin-bottom: 12px;
@media screen and (min-width: 2500px) {
font-size: 26px;
line-height: 30px;
margin-bottom: 24px;
}
}
}
}
.main-link-topButton {
img {
width: auto;
}
.main-whatssap-link,
.main-content-backToTop {
position: fixed;
z-index: 6;
right: 16px;
}
.main-whatssap-link {
bottom: 220px;
@media screen and (min-width: 2500px) {
height: 66px;
}
@media screen and (max-width: 1024px) {
bottom: 90px;
}
}
.main-content-backToTop {
background: variables.$color-grey;
padding: 13px 10px;
border-radius: 50%;
width: 34px;
height: 34px;
bottom: 180px;
@media screen and (min-width: 2500px) {
width: 66px;
height: 66px;
padding: 25px 20px;
bottom: 150px;
}
@media screen and (max-width: 1024px) {
bottom: 50px;
}
}
}

View File

@ -31,7 +31,6 @@ const MainForm = () => {
onSubmit={(values: IFormMain, { resetForm }) => {
console.log(values);
resetForm();
console.log("blah");
}}
initialValues={initialValues}
validationSchema={FormMainSchema}

View File

@ -4,10 +4,6 @@
width: 100%;
height: 650px;
@media screen and (min-width: 2500px) {
height: 900px;
}
.main-form {
width: 100%;
height: 600px;
@ -27,11 +23,6 @@
margin-left: 15px;
margin-bottom: 12px;
@media screen and (min-width: 2500px) {
font-size: 28px;
line-height: 33px;
}
}
input {
@ -40,23 +31,6 @@
border-radius: 25px;
margin-bottom: 12px;
@media screen and (min-width: 2500px) {
font-size: 28px;
line-height: 33px;
}
}
input::placeholder {
font-weight: 400;
font-size: 14px;
line-height: 16px;
color: variables.$color-grey6;
@media screen and (min-width: 2500px) {
font-size: 28px;
line-height: 33px;
}
}
.form-feedback {
@ -67,13 +41,6 @@
font-size: 12px;
line-height: 14px;
color: variables.$color-red;
@media screen and (min-width: 2500px) {
font-size: 24px;
line-height: 28px;
bottom: 80px;
}
}
}
@ -82,19 +49,9 @@
align-items: center;
justify-content: center;
margin-bottom: 12px;
margin-top: 12px;
label {
display: flex;
}
input {
margin-left: 4.28px;
@media screen and (min-width: 2500px) {
width: 35.15px;
height: 35.15px;
}
}
.main-form-dot,
@ -102,11 +59,6 @@
font-weight: 400;
font-size: 14px;
line-height: 16px;
@media screen and (min-width: 2500px) {
font-size: 28px;
line-height: 33px;
}
}
.main-form-dot {
@ -120,19 +72,13 @@
.form-feedback {
position: absolute;
right: 18%;
// right: 100px;
// bottom: 0px;
font-weight: 400;
font-size: 12px;
line-height: 14px;
color: variables.$color-red;
@media screen and (min-width: 2500px) {
font-size: 24px;
line-height: 28px;
right: 15%;
}
@media screen and (max-width: 360px) {
display: flex;
}
@ -140,7 +86,6 @@
}
.main-form-button {
font-style: normal;
font-weight: 400;
font-size: 16px;
line-height: 19px;
@ -154,11 +99,6 @@
background: variables.$color-black;
border-radius: 25px;
@media screen and (min-width: 2500px) {
font-size: 32px;
line-height: 38px;
}
@media screen and (max-width: 360px) {
margin-top: 4px;
}

View File

@ -6,10 +6,6 @@
border-top: 1px solid variables.$color-black;
background: variables.$color-white;
@media screen and (min-width: 2500px) {
height: 141.24px;
}
@media screen and (max-width: 1024px) {
height: auto;
}
@ -42,11 +38,6 @@
margin-bottom: 8px;
@media screen and (min-width: 2500px) {
font-size: 36px;
line-height: 42px;
}
@media screen and (max-width: 1024px) {
font-size: 14px;
line-height: 16px;
@ -77,13 +68,6 @@
border: 1px solid variables.$color-grey2;
border-radius: 4px;
@media screen and (min-width: 2500px) {
min-width: 668px;
font-size: 28px;
line-height: 33px;
}
@media screen and (max-width: 1024px) {
min-width: 100%;
}
@ -94,11 +78,6 @@
font-size: 14px;
line-height: 16px;
color: variables.$color-grey;
@media screen and (min-width: 2500px) {
font-size: 28px;
line-height: 33px;
}
}
.form-feedback {
@ -109,13 +88,6 @@
font-size: 12px;
line-height: 14px;
color: variables.$color-red;
@media screen and (min-width: 2500px) {
font-size: 24px;
line-height: 28px;
right: -95px;
}
}
}
@ -136,12 +108,6 @@
letter-spacing: 0.05em;
color: variables.$color-white;
@media screen and (min-width: 2500px) {
width: 246px;
font-size: 24px;
}
@media screen and (max-width: 1024px) {
width: 100%;
}

View File

@ -18,7 +18,6 @@ $color-grey2: #e5e5e5;
$color-grey3: #7d7d7d;
$color-grey4: #f2f2f2;
$color-grey5: #c6c6c6;
$color-grey6: #b9b7b7;
$color-red: #ff0000;