2025-07-28 07:50:50 +08:00
|
|
|
import { AppSidebar } from '@/components/app-sidebar';
|
|
|
|
|
|
|
|
|
|
import WithAuth from '@/components/providers/with-auth';
|
|
|
|
|
import { DashboardProvider } from '@/components/providers/dashboard-provider';
|
|
|
|
|
import { SidebarProvider, SidebarInset } from '@nice/ui/components/sidebar';
|
|
|
|
|
import { SiteHeader } from '@/components/site-header';
|
|
|
|
|
|
|
|
|
|
export default function DashboardLayout({ children }: { children: React.ReactNode }) {
|
|
|
|
|
return (
|
2025-07-28 10:32:25 +08:00
|
|
|
// <WithAuth>
|
2025-07-28 07:50:50 +08:00
|
|
|
|
2025-07-28 10:32:25 +08:00
|
|
|
// </WithAuth>
|
|
|
|
|
<DashboardProvider>
|
|
|
|
|
<SidebarProvider
|
|
|
|
|
style={
|
|
|
|
|
{
|
|
|
|
|
'--sidebar-width': 'calc(var(--spacing) * 72)',
|
|
|
|
|
'--header-height': 'calc(var(--spacing) * 12)',
|
|
|
|
|
} as React.CSSProperties
|
|
|
|
|
}
|
|
|
|
|
>
|
|
|
|
|
<AppSidebar variant="inset" />
|
|
|
|
|
<SidebarInset className="rounded-br-xl overflow-hidden">
|
|
|
|
|
<>
|
|
|
|
|
<SiteHeader></SiteHeader>
|
|
|
|
|
{children}
|
|
|
|
|
</>
|
|
|
|
|
|
|
|
|
|
</SidebarInset>
|
|
|
|
|
</SidebarProvider>
|
|
|
|
|
</DashboardProvider>
|
2025-07-28 07:50:50 +08:00
|
|
|
|
|
|
|
|
);
|
|
|
|
|
}
|