From 2b0862dea37bbdc40c1d3a42283cc8595a20d686 Mon Sep 17 00:00:00 2001 From: HenriqueSSan Date: Wed, 4 Jan 2023 16:47:54 -0300 Subject: [PATCH] refactor(route): split code in other components --- src/assets/brands/svgs/whatsapp.svg | 11 ++++++++ src/routes/index.module.scss | 39 +++++++++++++++++++++++++++ src/routes/index.tsx | 41 ++++++++++++++++++++++------- src/styles/global/_config.scss | 6 +++++ 4 files changed, 88 insertions(+), 9 deletions(-) create mode 100644 src/assets/brands/svgs/whatsapp.svg diff --git a/src/assets/brands/svgs/whatsapp.svg b/src/assets/brands/svgs/whatsapp.svg new file mode 100644 index 0000000..53c5037 --- /dev/null +++ b/src/assets/brands/svgs/whatsapp.svg @@ -0,0 +1,11 @@ + + + + + + + + + + + diff --git a/src/routes/index.module.scss b/src/routes/index.module.scss index 68c08ce..4f3abb9 100644 --- a/src/routes/index.module.scss +++ b/src/routes/index.module.scss @@ -35,3 +35,42 @@ main :global { width: function.fluid(2299.68px, 2500px); } } + +.scroll__fixed { + position: fixed; + right: 16px; + margin-bottom: 28px; + bottom: 0; + display: flex; + align-items: center; + flex-direction: column; + gap: 5px; + + @media screen and (min-width: 1025px) { + /* bottom: calc(10vh + 168px); */ + + margin-bottom: 168px; + } + + @media screen and (min-width: 2500px) { + /* bottom: 16.812vh; */ + + margin-bottom: 229.24px; + } + + &-whatsapp, + &-top { + width: 34px; + height: 34px; + + @media screen and (min-width: 2500px) { + width: 66px; + height: 66px; + } + } + + &-top { + background-color: var(--clr-gray-400); + border-radius: 100%; + } +} diff --git a/src/routes/index.tsx b/src/routes/index.tsx index e5e88c3..847088c 100644 --- a/src/routes/index.tsx +++ b/src/routes/index.tsx @@ -1,18 +1,42 @@ import { useMemo } from 'react' import { Outlet, Route, Routes } from 'react-router-dom' + +import { Header } from '../template/Header' import { Breadcrumb } from '../modules/components/Breadcrumb' +import { Sidebar } from '../template/Sidebar' import { About } from '../pages/Institutional/About' import { Contact } from '../pages/Institutional/Contact' -import { Footer } from '../template/Footer' -import { Header } from '../template/Header' import { Newsletter } from '../template/Newsletter' -import { Sidebar } from '../template/Sidebar' +import { Footer } from '../template/Footer' -import css from './index.module.scss' +import whatsappImg from '../assets/brands/svgs/whatsapp.svg' + +import styles from './index.module.scss' + +export function RouterBreadcrumb() { + let list = useMemo(() => [{ name: 'Introduction', href: '/' }], []) + + return ( +
+ +
+ ) +} + +export function ScrollFixed() { + return ( +
+ + + + + + +
+ ) +} export function Router() { - let listBreadcrumb = useMemo(() => [{ name: 'Introduction', href: '/' }], []) - return (
-
- -
+