layout.tsx — ui Source File
Architecture documentation for layout.tsx, a tsx file in the ui codebase. 5 imports, 0 dependents.
Entity Profile
Dependency Diagram
graph LR b7f0f4e9_2143_dd41_b7b8_da86fa0e74b7["layout.tsx"] cce19b8b_ad0a_042e_a83f_b21457a79caa["headers"] b7f0f4e9_2143_dd41_b7b8_da86fa0e74b7 --> cce19b8b_ad0a_042e_a83f_b21457a79caa 12632a83_ef01_5f03_4110_ed33d49893b7["sidebar"] b7f0f4e9_2143_dd41_b7b8_da86fa0e74b7 --> 12632a83_ef01_5f03_4110_ed33d49893b7 efe0ae46_0dac_94a8_dce5_5fcb8fcc9fea["app-sidebar"] b7f0f4e9_2143_dd41_b7b8_da86fa0e74b7 --> efe0ae46_0dac_94a8_dce5_5fcb8fcc9fea 93056d81_03ee_c2e7_aba8_3e26afc5edf3["site-header"] b7f0f4e9_2143_dd41_b7b8_da86fa0e74b7 --> 93056d81_03ee_c2e7_aba8_3e26afc5edf3 ddbf1f08_c37d_05f9_2795_eb458c9d4ecc["theme.css"] b7f0f4e9_2143_dd41_b7b8_da86fa0e74b7 --> ddbf1f08_c37d_05f9_2795_eb458c9d4ecc style b7f0f4e9_2143_dd41_b7b8_da86fa0e74b7 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
import { cookies } from "next/headers"
import {
SidebarInset,
SidebarProvider,
} from "@/registry/new-york-v4/ui/sidebar"
import { AppSidebar } from "@/app/(examples)/dashboard/components/app-sidebar"
import { SiteHeader } from "@/app/(examples)/dashboard/components/site-header"
import "@/app/(examples)/dashboard/theme.css"
export default async function DashboardLayout({
children,
}: {
children: React.ReactNode
}) {
const cookieStore = await cookies()
const defaultOpen = cookieStore.get("sidebar_state")?.value === "true"
return (
<SidebarProvider
defaultOpen={defaultOpen}
style={
{
"--sidebar-width": "calc(var(--spacing) * 72)",
} as React.CSSProperties
}
>
<AppSidebar variant="inset" />
<SidebarInset>
<SiteHeader />
<div className="flex flex-1 flex-col">{children}</div>
</SidebarInset>
</SidebarProvider>
)
}
Domain
Subdomains
Functions
Dependencies
- app-sidebar
- headers
- sidebar
- site-header
- theme.css
Source
Frequently Asked Questions
What does layout.tsx do?
layout.tsx is a source file in the ui codebase, written in tsx. It belongs to the DocumentationAtlas domain, Changelog subdomain.
What functions are defined in layout.tsx?
layout.tsx defines 1 function(s): DashboardLayout.
What does layout.tsx depend on?
layout.tsx imports 5 module(s): app-sidebar, headers, sidebar, site-header, theme.css.
Where is layout.tsx in the architecture?
layout.tsx is located at apps/v4/app/(examples)/dashboard/layout.tsx (domain: DocumentationAtlas, subdomain: Changelog, directory: apps/v4/app/(examples)/dashboard).
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free