{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "ai-task",
  "title": "AI: Task",
  "description": "A collapsible task and subtask list with file chips for agent activity.",
  "dependencies": [
    "@untitledui/icons@^0.0.22"
  ],
  "registryDependencies": [
    "@nx-ui/utils",
    "@nx-ui/collapsible"
  ],
  "files": [
    {
      "path": "components/ai/task.tsx",
      "content": "\"use client\"\n\nimport type { ComponentProps } from \"react\"\nimport { ChevronDown, SearchLg } from \"@untitledui/icons\"\n\nimport {\n  Collapsible,\n  CollapsibleContent,\n  CollapsibleTrigger,\n} from \"@/components/ui/collapsible\"\nimport { cn } from \"@/lib/utils\"\n\nexport type TaskItemFileProps = ComponentProps<\"div\">\n\nexport const TaskItemFile = ({\n  children,\n  className,\n  ...props\n}: TaskItemFileProps) => (\n  <div\n    className={cn(\n      \"inline-flex items-center gap-1 rounded-md border bg-secondary px-1.5 py-0.5 text-foreground text-xs\",\n      className\n    )}\n    {...props}\n  >\n    {children}\n  </div>\n)\n\nexport type TaskItemProps = ComponentProps<\"div\">\n\nexport const TaskItem = ({ children, className, ...props }: TaskItemProps) => (\n  <div className={cn(\"text-muted-foreground text-sm\", className)} {...props}>\n    {children}\n  </div>\n)\n\nexport type TaskProps = ComponentProps<typeof Collapsible>\n\nexport const Task = ({ defaultOpen = true, className, ...props }: TaskProps) => (\n  <Collapsible className={cn(className)} defaultOpen={defaultOpen} {...props} />\n)\n\nexport type TaskTriggerProps = ComponentProps<typeof CollapsibleTrigger> & {\n  title: string\n}\n\nexport const TaskTrigger = ({\n  children,\n  className,\n  title,\n  ...props\n}: TaskTriggerProps) => (\n  <CollapsibleTrigger\n    className={cn(\"group flex w-full\", className)}\n    // The default trigger renders a <div>, not a native <button>, so opt out of\n    // Base UI's native-button semantics to avoid the runtime warning.\n    nativeButton={children ? undefined : false}\n    render={\n      children ? undefined : (\n        <div className=\"flex w-full cursor-pointer items-center gap-2 text-muted-foreground text-sm transition-colors hover:text-foreground\">\n          <SearchLg className=\"size-4\" />\n          <p className=\"text-sm\">{title}</p>\n          <ChevronDown className=\"size-4 transition-transform group-data-panel-open:rotate-180\" />\n        </div>\n      )\n    }\n    {...props}\n  >\n    {children}\n  </CollapsibleTrigger>\n)\n\nexport type TaskContentProps = ComponentProps<typeof CollapsibleContent>\n\nexport const TaskContent = ({\n  children,\n  className,\n  ...props\n}: TaskContentProps) => (\n  <CollapsibleContent\n    className={cn(\n      \"data-closed:fade-out-0 data-closed:slide-out-to-top-2 data-open:slide-in-from-top-2 text-popover-foreground outline-none data-closed:animate-out data-open:animate-in\",\n      className\n    )}\n    {...props}\n  >\n    <div className=\"mt-4 space-y-2 border-muted border-l-2 pl-4\">{children}</div>\n  </CollapsibleContent>\n)\n",
      "type": "registry:ui",
      "target": "components/ai/task.tsx"
    }
  ],
  "type": "registry:ui"
}