Update
This commit is contained in:
@@ -8,11 +8,11 @@ interface AppShellProps {
|
||||
}
|
||||
|
||||
export function AppShell({ children, variant = 'header' }: AppShellProps) {
|
||||
const isOpen = usePage<SharedData>().props.sidebarOpen;
|
||||
const defaultSidebarOpen = true;
|
||||
|
||||
if (variant === 'header') {
|
||||
return <div className="flex min-h-screen w-full flex-col">{children}</div>;
|
||||
}
|
||||
|
||||
return <SidebarProvider defaultOpen={isOpen}>{children}</SidebarProvider>;
|
||||
return <SidebarProvider defaultOpen={defaultSidebarOpen}>{children}</SidebarProvider>;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user