{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "workspace-tabs",
  "type": "registry:block",
  "title": "Tabbed workspace",
  "description": "Library keyboard behavior and persistent inactive panels for filters and drafts.",
  "registryDependencies": [
    "tabs"
  ],
  "files": [
    {
      "path": "blocks/workspace-tabs.tsx",
      "type": "registry:component",
      "target": "components/shine/workspace-tabs.tsx",
      "content": "\"use client\";\nimport { useState, type ReactNode } from \"react\";\nimport { Tabs, TabsContent, TabsList, TabsTrigger } from \"@/components/ui/tabs\";\n\n/** Radix/Base UI owns tab semantics and keyboard; mounted panels preserve drafts. */\nexport function WorkspaceTabs({ label, tabs, defaultValue, value, onValueChange }: {\n  label: string; tabs: { value: string; label: string; content: ReactNode; disabled?: boolean }[];\n  defaultValue?: string; value?: string; onValueChange?: (value: string) => void;\n}) {\n  const [local, setLocal] = useState(defaultValue || tabs.find(tab => !tab.disabled)?.value || \"\");\n  const selected = value ?? local;\n  return <Tabs data-product-pattern=\"workspace-tabs\" value={selected} onValueChange={next => { setLocal(next); onValueChange?.(next); }} className=\"min-w-0 gap-4\">\n    <div className=\"max-w-full overflow-x-auto\"><TabsList aria-label={label} className=\"h-auto min-h-11 w-max justify-start\">\n      {tabs.map(tab => <TabsTrigger key={tab.value} value={tab.value} disabled={tab.disabled} className=\"min-h-11 text-foreground\">{tab.label}</TabsTrigger>)}\n    </TabsList></div>\n    {tabs.map(tab => <TabsContent key={tab.value} value={tab.value} forceMount hidden={selected !== tab.value} className=\"min-w-0 data-[state=inactive]:hidden\">{tab.content}</TabsContent>)}\n  </Tabs>;\n}\n"
    }
  ]
}
