NavMain() — ui Function Reference
Architecture documentation for the NavMain() function in nav-main.tsx from the ui codebase.
Entity Profile
Dependency Diagram
graph TD 85f2ed68_f490_e0aa_0e64_3bc1315bb377["NavMain()"] c0c7e2ec_5fa8_3e13_d30d_2e54b211eb2e["nav-main.tsx"] 85f2ed68_f490_e0aa_0e64_3bc1315bb377 -->|defined in| c0c7e2ec_5fa8_3e13_d30d_2e54b211eb2e style 85f2ed68_f490_e0aa_0e64_3bc1315bb377 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
apps/v4/registry/bases/base/blocks/dashboard-01/components/nav-main.tsx lines 13–69
export function NavMain({
items,
}: {
items: {
title: string
url: string
icon?: React.ReactNode
}[]
}) {
return (
<SidebarGroup>
<SidebarGroupContent className="flex flex-col gap-2">
<SidebarMenu>
<SidebarMenuItem className="flex items-center gap-2">
<SidebarMenuButton
tooltip="Quick Create"
className="bg-primary text-primary-foreground hover:bg-primary/90 hover:text-primary-foreground active:bg-primary/90 active:text-primary-foreground min-w-8 duration-200 ease-linear"
>
<IconPlaceholder
lucide="CirclePlusIcon"
tabler="IconCirclePlusFilled"
hugeicons="PlusSignCircleIcon"
phosphor="PlusCircleIcon"
remixicon="RiAddCircleFill"
/>
<span>Quick Create</span>
</SidebarMenuButton>
<Button
size="icon"
className="size-8 group-data-[collapsible=icon]:opacity-0"
variant="outline"
>
<IconPlaceholder
lucide="MailIcon"
tabler="IconMail"
hugeicons="Mail01Icon"
phosphor="EnvelopeIcon"
remixicon="RiMailLine"
/>
<span className="sr-only">Inbox</span>
</Button>
</SidebarMenuItem>
</SidebarMenu>
<SidebarMenu>
{items.map((item) => (
<SidebarMenuItem key={item.title}>
<SidebarMenuButton tooltip={item.title}>
{item.icon}
<span>{item.title}</span>
</SidebarMenuButton>
</SidebarMenuItem>
))}
</SidebarMenu>
</SidebarGroupContent>
</SidebarGroup>
)
}
Domain
Subdomains
Source
Frequently Asked Questions
What does NavMain() do?
NavMain() is a function in the ui codebase, defined in apps/v4/registry/bases/base/blocks/dashboard-01/components/nav-main.tsx.
Where is NavMain() defined?
NavMain() is defined in apps/v4/registry/bases/base/blocks/dashboard-01/components/nav-main.tsx at line 13.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free