{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "sidebar-controlled",
  "type": "registry:internal",
  "files": [
    {
      "path": "registry/new-york-v4/internal/sidebar-controlled.tsx",
      "content": "\"use client\"\n\nimport * as React from \"react\"\nimport {\n  FrameIcon,\n  LifeBuoyIcon,\n  MapIcon,\n  PanelLeftCloseIcon,\n  PanelLeftOpenIcon,\n  PieChartIcon,\n  SendIcon,\n} from \"lucide-react\"\n\nimport { Button } from \"@/registry/new-york-v4/ui/button\"\nimport {\n  Sidebar,\n  SidebarContent,\n  SidebarGroup,\n  SidebarGroupContent,\n  SidebarGroupLabel,\n  SidebarInset,\n  SidebarMenu,\n  SidebarMenuButton,\n  SidebarMenuItem,\n  SidebarProvider,\n} from \"@/registry/new-york-v4/ui/sidebar\"\n\nconst projects = [\n  {\n    name: \"Design Engineering\",\n    url: \"#\",\n    icon: FrameIcon,\n  },\n  {\n    name: \"Sales & Marketing\",\n    url: \"#\",\n    icon: PieChartIcon,\n  },\n  {\n    name: \"Travel\",\n    url: \"#\",\n    icon: MapIcon,\n  },\n  {\n    name: \"Support\",\n    url: \"#\",\n    icon: LifeBuoyIcon,\n  },\n  {\n    name: \"Feedback\",\n    url: \"#\",\n    icon: SendIcon,\n  },\n]\n\nexport default function AppSidebar() {\n  const [open, setOpen] = React.useState(true)\n\n  return (\n    <SidebarProvider open={open} onOpenChange={setOpen}>\n      <Sidebar>\n        <SidebarContent>\n          <SidebarGroup>\n            <SidebarGroupLabel>Projects</SidebarGroupLabel>\n            <SidebarGroupContent>\n              <SidebarMenu>\n                {projects.map((project) => (\n                  <SidebarMenuItem key={project.name}>\n                    <SidebarMenuButton asChild>\n                      <a href={project.url}>\n                        <project.icon />\n                        <span>{project.name}</span>\n                      </a>\n                    </SidebarMenuButton>\n                  </SidebarMenuItem>\n                ))}\n              </SidebarMenu>\n            </SidebarGroupContent>\n          </SidebarGroup>\n        </SidebarContent>\n      </Sidebar>\n      <SidebarInset>\n        <header className=\"flex h-12 items-center justify-between px-4\">\n          <Button\n            onClick={() => setOpen((open) => !open)}\n            size=\"sm\"\n            variant=\"ghost\"\n          >\n            {open ? <PanelLeftCloseIcon /> : <PanelLeftOpenIcon />}\n            <span>{open ? \"Close\" : \"Open\"} Sidebar</span>\n          </Button>\n        </header>\n      </SidebarInset>\n    </SidebarProvider>\n  )\n}\n",
      "type": "registry:component"
    }
  ]
}