diff --git a/src/shared/Layout.tsx b/src/shared/Layout.tsx index 2746334..2551485 100644 --- a/src/shared/Layout.tsx +++ b/src/shared/Layout.tsx @@ -1,5 +1,7 @@ import type { ReactNode } from 'react'; +import { useState } from 'react'; import { Link } from 'react-router-dom'; +import { HamburgerMenuIcon, Cross1Icon } from '@radix-ui/react-icons'; import { LeftSidebar } from './LeftSidebar'; interface LayoutProps { @@ -9,19 +11,42 @@ interface LayoutProps { } export function Layout({ children, showSidebar = true, rightSidebar }: LayoutProps) { + const [isMobileSidebarOpen, setIsMobileSidebarOpen] = useState(false); + return (
{/* Left Sidebar - fixed positioning */} - {showSidebar && } + {showSidebar && ( + setIsMobileSidebarOpen(false)} + /> + )} {/* Main Content */} -
+
{/* Top Header */}
- - Gem Wiki (잼위키) - +
+ {/* Hamburger Menu Button - only visible on mobile/tablet */} + {showSidebar && ( + + )} + + Gem Wiki (잼위키) + +
+ ); } diff --git a/src/shared/RightSidebar.tsx b/src/shared/RightSidebar.tsx index 297ce53..32c26fb 100644 --- a/src/shared/RightSidebar.tsx +++ b/src/shared/RightSidebar.tsx @@ -16,7 +16,7 @@ export function RightSidebar() { if (headings.length === 0) { return ( -