diff --git a/resources/js/Layouts/StudioLayout.jsx b/resources/js/Layouts/StudioLayout.jsx new file mode 100644 index 00000000..43cfae6a --- /dev/null +++ b/resources/js/Layouts/StudioLayout.jsx @@ -0,0 +1,107 @@ +import React, { useState } from 'react' +import { Link, usePage } from '@inertiajs/react' + +const navItems = [ + { label: 'Overview', href: '/studio', icon: 'fa-solid fa-chart-line' }, + { label: 'Artworks', href: '/studio/artworks', icon: 'fa-solid fa-images' }, + { label: 'Drafts', href: '/studio/artworks/drafts', icon: 'fa-solid fa-file-pen' }, + { label: 'Archived', href: '/studio/artworks/archived', icon: 'fa-solid fa-box-archive' }, + { label: 'Analytics', href: '/studio/analytics', icon: 'fa-solid fa-chart-pie' }, +] + +function NavLink({ item, active }) { + return ( + + + {item.label} + + ) +} + +export default function StudioLayout({ children, title }) { + const { url, props } = usePage() + const user = props.auth?.user + const [mobileOpen, setMobileOpen] = useState(false) + + const isActive = (href) => { + if (href === '/studio') return url === '/studio' + return url.startsWith(href) + } + + return ( +
+ {/* Mobile top bar */} +
+

Studio

+ +
+ + {/* Mobile nav overlay */} + {mobileOpen && ( +
setMobileOpen(false)}> + +
+ )} + +
+ {/* Desktop sidebar */} + + + {/* Main content */} +
+ {title && ( +

{title}

+ )} + {children} +
+
+
+ ) +} + +function StudioSidebarContent({ isActive, onNavigate }) { + return ( + <> +
+

Creator Studio

+
+ + + +
+ + + Upload + +
+ + ) +}