diff --git a/src/components/Layout.tsx b/src/components/Layout.tsx index 2f1aeba..c9835ec 100644 --- a/src/components/Layout.tsx +++ b/src/components/Layout.tsx @@ -37,7 +37,7 @@ const Layout = ({ children }: LayoutProps) => { setIsMounted(true); }, []); - // Schließe das Menü nur beim Routenwechsel + // Schließe das Menü beim Routenwechsel useEffect(() => { setIsMenuOpen(false); }, [location.pathname, setIsMenuOpen]); @@ -198,8 +198,18 @@ const Layout = ({ children }: LayoutProps) => { transition={{ type: "spring", stiffness: 300, damping: 30 }} className="fixed right-0 top-0 h-full w-80 bg-zinc-900 shadow-xl md:hidden z-50 border-l border-zinc-800" > - {/* Header-Spacer */} -
+ {/* Sidebar Header mit Close-Button */} +
+ Menu + setIsMenuOpen(false)} + aria-label="Close sidebar" + className="p-2 rounded-lg text-zinc-400 hover:text-white hover:bg-zinc-800/50 transition-colors" + whileTap={{ scale: 0.95 }} + > + + +
{/* Scrollbarer Sidebar-Inhalt */}
@@ -224,9 +234,9 @@ const Layout = ({ children }: LayoutProps) => { {/* Language Switcher */}
- - Sprache ändern - + + Sprache ändern +
@@ -246,4 +256,4 @@ const Layout = ({ children }: LayoutProps) => { ); }; -export default Layout; \ No newline at end of file +export default Layout;