diff --git a/frontend/public/logo.png b/frontend/public/logo.png new file mode 100644 index 0000000..2cd032e Binary files /dev/null and b/frontend/public/logo.png differ diff --git a/frontend/src/components/Layout.tsx b/frontend/src/components/Layout.tsx index 8edd57e..e5285c1 100644 --- a/frontend/src/components/Layout.tsx +++ b/frontend/src/components/Layout.tsx @@ -12,13 +12,28 @@ import { Server, Users } from 'lucide-react' -import { useState } from 'react' +import { useState, useEffect } from 'react' export default function Layout() { const { user, clearAuth } = useAuthStore() const navigate = useNavigate() const location = useLocation() - const [sidebarOpen, setSidebarOpen] = useState(true) + const [sidebarOpen, setSidebarOpen] = useState(false) + + // Set sidebar open by default on desktop, closed on mobile + useEffect(() => { + const handleResize = () => { + if (window.innerWidth >= 1024) { + setSidebarOpen(true) + } else { + setSidebarOpen(false) + } + } + + handleResize() // Set initial state + window.addEventListener('resize', handleResize) + return () => window.removeEventListener('resize', handleResize) + }, []) const handleLogout = () => { clearAuth() @@ -48,6 +63,14 @@ export default function Layout() { return (
{
+ // Fallback to text if image not found
+ const target = e.target as HTMLImageElement
+ target.style.display = 'none'
+ const fallback = target.nextElementSibling as HTMLElement
+ if (fallback) fallback.style.display = 'flex'
+ }}
+ />
+ Dev Release V.1
+