From e01e0a6a97ff0b9a68339ad4b24a73db726b0149 Mon Sep 17 00:00:00 2001 From: Kevin Loritsch Date: Wed, 3 Sep 2025 19:34:49 -0700 Subject: [PATCH] harder mobile adjustments --- src/app/components/Navbar.tsx | 104 ++++++++++++++++++++++++++------- src/app/components/Project.tsx | 2 +- 2 files changed, 84 insertions(+), 22 deletions(-) diff --git a/src/app/components/Navbar.tsx b/src/app/components/Navbar.tsx index 00d3c56..0579c58 100644 --- a/src/app/components/Navbar.tsx +++ b/src/app/components/Navbar.tsx @@ -1,8 +1,9 @@ "use client"; -import { motion } from "motion/react"; +import { motion, AnimatePresence } from "motion/react"; import { Link as ScrollLink } from "react-scroll"; import Link from "next/link"; import { useState, useEffect } from "react"; +import { FaBars, FaTimes } from "react-icons/fa"; import navbarItems from "@/data/NavbarData"; @@ -42,28 +43,89 @@ const use10vhAsPixels = () => { const Navbar = () => { const pixels = use10vhAsPixels(); + const [isOpen, setIsOpen] = useState(false); + + const toggleMenu = () => setIsOpen((prev) => !prev); + return ( -
-
- -

Kevin Loritsch

- -
-
- {navbarItems.map(({ name, link }, i) => ( - - - - {name} - +
+
+
+ +

Kevin Loritsch

+ +
+
+ {navbarItems.map(({ name, link }, i) => ( + + + + {name} + + - - ))} + ))} +
+
+
+
+ + Kevin Loritsch + + +
+ +
+
+ {navbarItems.map(({ name, link }, i) => ( + + + + {name} + + + + ))} +
+
); diff --git a/src/app/components/Project.tsx b/src/app/components/Project.tsx index 258c636..e6ed7f8 100644 --- a/src/app/components/Project.tsx +++ b/src/app/components/Project.tsx @@ -96,7 +96,7 @@ const Project = ({