25 lines
735 B
TypeScript
25 lines
735 B
TypeScript
"use client"
|
|
|
|
import { AuthGuard } from "@/components/auth-guard"
|
|
import { DashboardSidebar } from "@/components/dashboard-sidebar"
|
|
import { Header } from "@/components/header"
|
|
import { RoleGuard } from "@/components/role-guard"
|
|
|
|
export default function DashboardLayout({ children }: { children: React.ReactNode }) {
|
|
return (
|
|
<div className="flex min-h-screen flex-col bg-muted/20">
|
|
<Header />
|
|
<div className="mx-auto flex w-full max-w-7xl flex-1 px-4">
|
|
<div className="hidden md:block">
|
|
<DashboardSidebar />
|
|
</div>
|
|
<main className="flex-1 p-6">
|
|
<AuthGuard>
|
|
<RoleGuard>{children}</RoleGuard>
|
|
</AuthGuard>
|
|
</main>
|
|
</div>
|
|
</div>
|
|
)
|
|
}
|