diff --git a/components/Home/Hero/Hero.tsx b/components/Home/Hero/Hero.tsx index 3a9a949..f2e130f 100644 --- a/components/Home/Hero/Hero.tsx +++ b/components/Home/Hero/Hero.tsx @@ -16,7 +16,7 @@ const Hero = () => { alt="Rhein river aerial view" layout="fill" objectFit="cover" - className="blur-md" + className="blur-md scale-105" priority /> {/* Dark overlay for better text contrast */} diff --git a/components/Navbar/DesktopNav.tsx b/components/Navbar/DesktopNav.tsx index e7d8cf7..381d26e 100644 --- a/components/Navbar/DesktopNav.tsx +++ b/components/Navbar/DesktopNav.tsx @@ -40,9 +40,11 @@ const Nav = ({openNav}: Props) => { return (
diff --git a/components/Navbar/MobileNav.tsx b/components/Navbar/MobileNav.tsx index 853025d..331b6ff 100644 --- a/components/Navbar/MobileNav.tsx +++ b/components/Navbar/MobileNav.tsx @@ -1,7 +1,9 @@ import {navLinks} from "@/constant/Constant"; import Link from "next/link"; -import React from "react"; +import React, {useContext} from "react"; import {CgClose} from "react-icons/cg"; +import {ThemeContext} from "@/components/provider/ThemeProvider"; +import {themeColors} from "@/components/Helper/ThemeColors"; type Props = { showNav: boolean; @@ -9,32 +11,52 @@ type Props = { }; const MobileNav = ({closeNav, showNav}: Props) => { - const navOpen = showNav ? "translate-x-0" : "translate-x-[-100%]"; - + const navOpen = showNav ? "translate-y-0 opacity-100" : "-translate-y-20 opacity-0 pointer-events-none"; + const {theme, toggleTheme} = useContext(ThemeContext); + const colors = themeColors[theme]; return ( -
- {/* overlay */} +
+ {/* overlay background */}
- {/* Navlinks */} + className={`fixed inset-0 z-[10000] transition-opacity duration-500 ${ + showNav ? "opacity-60 bg-black" : "opacity-0 pointer-events-none" + }`} + onClick={closeNav} + /> + + {/* nav menu */}
- {navLinks.map((link) => { - return ( +
+ {/* Close icon */} + + + {navLinks.map((link) => ( -

+

{link.label}

- ); - })} - {/* Close icon */} - + ))} + + {/* Theme toggle button */} + +
);