Home / File/ sidebar-header.tsx — ui Source File

sidebar-header.tsx — ui Source File

Architecture documentation for sidebar-header.tsx, a tsx file in the ui codebase. 3 imports, 0 dependents.

File tsx DocumentationAtlas ContentSourcing 3 imports 1 functions

Entity Profile

Dependency Diagram

graph LR
  93d36e04_bdbb_74af_4a2c_ee5a74efa5a8["sidebar-header.tsx"]
  c4ec47ed_7434_868c_4320_f03b26dfd4e8["dropdown-menu"]
  93d36e04_bdbb_74af_4a2c_ee5a74efa5a8 --> c4ec47ed_7434_868c_4320_f03b26dfd4e8
  ae980154_1718_a5bc_ef81_3a801fffff75["sidebar"]
  93d36e04_bdbb_74af_4a2c_ee5a74efa5a8 --> ae980154_1718_a5bc_ef81_3a801fffff75
  d39cd1e4_1b2d_9aa2_1d29_fd0b4bfb61c3["lucide-react"]
  93d36e04_bdbb_74af_4a2c_ee5a74efa5a8 --> d39cd1e4_1b2d_9aa2_1d29_fd0b4bfb61c3
  style 93d36e04_bdbb_74af_4a2c_ee5a74efa5a8 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

"use client"

import {
  DropdownMenu,
  DropdownMenuContent,
  DropdownMenuItem,
  DropdownMenuTrigger,
} from "@/examples/base/ui/dropdown-menu"
import {
  Sidebar,
  SidebarHeader,
  SidebarInset,
  SidebarMenu,
  SidebarMenuButton,
  SidebarMenuItem,
  SidebarProvider,
  SidebarTrigger,
} from "@/examples/base/ui/sidebar"
import { ChevronDownIcon } from "lucide-react"

export default function AppSidebar() {
  return (
    <SidebarProvider>
      <Sidebar>
        <SidebarHeader>
          <SidebarMenu>
            <SidebarMenuItem>
              <DropdownMenu>
                <DropdownMenuTrigger
                  render={
                    <SidebarMenuButton className="data-[state=open]:bg-sidebar-accent data-[state=open]:text-sidebar-accent-foreground" />
                  }
                >
                  Select Workspace
                  <ChevronDownIcon className="ml-auto" />
                </DropdownMenuTrigger>
                <DropdownMenuContent className="w-(--radix-popper-anchor-width)">
                  <DropdownMenuItem>
                    <span>Acme Inc</span>
                  </DropdownMenuItem>
                  <DropdownMenuItem>
                    <span>Acme Corp.</span>
                  </DropdownMenuItem>
                </DropdownMenuContent>
              </DropdownMenu>
            </SidebarMenuItem>
          </SidebarMenu>
        </SidebarHeader>
      </Sidebar>
      <SidebarInset>
        <header className="flex h-12 items-center justify-between px-4">
          <SidebarTrigger />
        </header>
      </SidebarInset>
    </SidebarProvider>
  )
}

Subdomains

Functions

Dependencies

  • dropdown-menu
  • lucide-react
  • sidebar

Frequently Asked Questions

What does sidebar-header.tsx do?
sidebar-header.tsx is a source file in the ui codebase, written in tsx. It belongs to the DocumentationAtlas domain, ContentSourcing subdomain.
What functions are defined in sidebar-header.tsx?
sidebar-header.tsx defines 1 function(s): AppSidebar.
What does sidebar-header.tsx depend on?
sidebar-header.tsx imports 3 module(s): dropdown-menu, lucide-react, sidebar.
Where is sidebar-header.tsx in the architecture?
sidebar-header.tsx is located at apps/v4/examples/base/sidebar-header.tsx (domain: DocumentationAtlas, subdomain: ContentSourcing, directory: apps/v4/examples/base).

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free