From 1f6c9dd88608cbb56458d311431d92d9d3c8270a Mon Sep 17 00:00:00 2001 From: tomas Date: Tue, 9 Jan 2024 19:14:03 +0100 Subject: [PATCH] fix missing discord links! --- src/Header/Navbar.tsx | 3 ++- src/components/Marquee.tsx | 31 ++++--------------------------- 2 files changed, 6 insertions(+), 28 deletions(-) diff --git a/src/Header/Navbar.tsx b/src/Header/Navbar.tsx index 389217e..83532e4 100644 --- a/src/Header/Navbar.tsx +++ b/src/Header/Navbar.tsx @@ -2,6 +2,7 @@ import { motion, AnimatePresence } from 'framer-motion' import { useState } from 'react' import { styled } from 'styled-components' import { useNavigate } from 'react-router-dom' +import { DISCORD_INVITE_LINK } from '../constants' const StyledNavbar = styled.div` border: 5px solid #7816f4; @@ -104,7 +105,7 @@ const Navbar = () => { ))} setHoveredItem(e.currentTarget)} onMouseLeave={() => setHoveredItem(null)}> Discord diff --git a/src/components/Marquee.tsx b/src/components/Marquee.tsx index 7a18ba6..71066a3 100644 --- a/src/components/Marquee.tsx +++ b/src/components/Marquee.tsx @@ -1,6 +1,6 @@ import styled from 'styled-components' import { motion, useSpring, useViewportScroll } from 'framer-motion' -import { ACCENT_COLOR } from '../constants' +import { ACCENT_COLOR, DISCORD_INVITE_LINK } from '../constants' import { useEffect } from 'react' const MarqueeContainer = styled.div` @@ -9,7 +9,7 @@ const MarqueeContainer = styled.div` overflow: hidden; ` -const Track = styled(motion.div)` +const Track = styled(motion.a)` white-space: nowrap; height: 50px; position: relative; @@ -57,31 +57,6 @@ const Title = styled.h1` ` const Marquee = () => { - // const trackRef = useRef(null) - // const [contentWidth, setContentWidth] = useState(0) - // const direction = 0 - - // useEffect(() => { - // if (trackRef.current) { - // const width = trackRef.current.offsetWidth - // setContentWidth(width) - // } - // }, []) - - // const marqueeVariants = { - // animate: { - // x: [0, -1035], - // transition: { - // x: { - // repeat: Infinity, - // repeatType: 'loop', - // duration: 5, - // ease: 'linear', - // }, - // }, - // }, - // } - const direction = Math.random() > 0.5 ? 1 : -1 const { scrollYProgress } = useViewportScroll() @@ -100,6 +75,8 @@ const Marquee = () => { return ( {Array.from({ length: 50 }).map(() => (