mirror of
https://github.com/hanzoai/shadcn.git
synced 2026-11-02 10:35:35 +00:00
Squash merge of shadcn-ui/ui main branch into hanzo/ui, bringing in: - [email protected] through [email protected] releases - New apps/v4 directory structure - Registry system improvements and MCP server - Framework support (Vue, Svelte, React Native) - New templates (vite-app, monorepo-next, laravel) - Zod 4 compatibility (scoped override for zod@>4) - Test fixture corrections for alias resolution All 867 merge conflicts resolved preserving Hanzo customizations. 1020/1020 shadcn tests pass.
30 lines
848 B
TypeScript
30 lines
848 B
TypeScript
import { cookies } from "next/headers"
|
|
|
|
import {
|
|
SidebarInset,
|
|
SidebarProvider,
|
|
} from "@/registry/new-york-v4/ui/sidebar"
|
|
import { AppSidebar } from "@/app/(examples)/dashboard-03/components/app-sidebar"
|
|
import { SiteHeader } from "@/app/(examples)/dashboard-03/components/site-header"
|
|
|
|
export default async function DashboardLayout({
|
|
children,
|
|
}: {
|
|
children: React.ReactNode
|
|
}) {
|
|
const cookieStore = await cookies()
|
|
const defaultOpen = cookieStore.get("sidebar_state")?.value === "true"
|
|
|
|
return (
|
|
<main className="[--header-height:calc(theme(spacing.14))]">
|
|
<SidebarProvider defaultOpen={defaultOpen} className="flex flex-col">
|
|
<SiteHeader />
|
|
<div className="flex flex-1">
|
|
<AppSidebar />
|
|
<SidebarInset>{children}</SidebarInset>
|
|
</div>
|
|
</SidebarProvider>
|
|
</main>
|
|
)
|
|
}
|