diff --git a/src/components/ButtonElement.jsx b/src/components/ButtonElement.jsx index d66f904..13293f1 100644 --- a/src/components/ButtonElement.jsx +++ b/src/components/ButtonElement.jsx @@ -5,7 +5,7 @@ export const Button = styled(Link)` border-radius: 50px; background: ${({ primary }) => (primary ? "#01BF71" : "#010606")}; white-space: nowrap; - padding: ${({ big }) => (big ? " 14px 48px" : "12px 30px")}; + padding: ${({ big }) => (big ? "14px 48px" : "12px 30px")}; color: ${({ dark }) => (dark ? "#010106" : "#fff")}; font-size: $ ${({ fontBig }) => (fontBig ? "20px" : "16px")}; outline: none; diff --git a/src/components/HeroSection/index.jsx b/src/components/HeroSection/index.jsx index 5e3ac7d..aaf9633 100755 --- a/src/components/HeroSection/index.jsx +++ b/src/components/HeroSection/index.jsx @@ -1,4 +1,3 @@ -import React from "react"; import img from "../../images/F23.prince.learning.turquoise.jpg"; import { HeroCitationBlock, @@ -124,7 +123,7 @@ export default function HeroSection() {
                                 
-                                    {citation}
+                                    <>{citation}
                                 
                             
diff --git a/src/components/NavBar/index.jsx b/src/components/NavBar/index.jsx index 4c2e1e3..4654e59 100755 --- a/src/components/NavBar/index.jsx +++ b/src/components/NavBar/index.jsx @@ -15,16 +15,20 @@ import { export default function NavBar({ toggle }) { const [scrollNav, setScrollNav] = useState(false); - const changeNav = () => { - if (window.scrollY >= 80) { - setScrollNav(true); - } else { - setScrollNav(false); - } - }; - useEffect(() => { + const changeNav = () => { + if (window.scrollY >= 80) { + setScrollNav(true); + } else { + setScrollNav(false); + } + }; + window.addEventListener("scroll", changeNav); + + return () => { + window.removeEventListener("scroll", changeNav); + }; }, []); const toggleHome = () => { diff --git a/src/components/Notebooks/NotebookElements.jsx b/src/components/Notebooks/NotebookElements.jsx index 659e569..132a2df 100644 --- a/src/components/Notebooks/NotebookElements.jsx +++ b/src/components/Notebooks/NotebookElements.jsx @@ -14,7 +14,7 @@ export const NotebookWrapper = styled.div` display: grid; z-index: 1; /* height: 1250px; */ - width: 100% ; + width: 100%; max-width: 1100px; margin-right: auto; margin-left: auto; @@ -62,7 +62,7 @@ export const Column2 = styled.p` ` export const TextWrapper = styled.div` - max-width: 540px ; + max-width: 540px; padding-top: 0; padding-bottom: 0; ` diff --git a/src/components/ScrollToTop.jsx b/src/components/ScrollToTop.jsx index a6d7498..ec78401 100755 --- a/src/components/ScrollToTop.jsx +++ b/src/components/ScrollToTop.jsx @@ -5,7 +5,7 @@ export default function ScrollToTop() { const { pathname } = useLocation(); useEffect(() => { - window.scrollTo(0, 0, {}); + window.scrollTo(0, 0, { behavior: "smooth" }); }, [pathname]); return null;