{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "queue",
  "registryDependencies": [
    "https://taki-ui.com/r/button.json",
    "https://taki-ui.com/r/disclosure.json"
  ],
  "files": [
    {
      "path": "registry/new-york/ai-elements/queue.tsx",
      "content": "\"use client\"\n\nimport type { ComponentProps } from \"react\"\nimport { ChevronDownIcon, PaperclipIcon } from \"lucide-react\"\n\nimport { cn } from \"@/lib/utils\"\nimport { Button } from \"@/registry/new-york/ui/button\"\nimport { Disclosure, DisclosurePanel } from \"@/registry/new-york/ui/disclosure\"\n\nexport type QueueMessagePart = {\n  type: string\n  text?: string\n  url?: string\n  filename?: string\n  mediaType?: string\n}\n\nexport type QueueMessage = {\n  id: string\n  parts: QueueMessagePart[]\n}\n\nexport type QueueTodo = {\n  id: string\n  title: string\n  description?: string\n  status?: \"pending\" | \"completed\"\n}\n\nexport type QueueItemProps = ComponentProps<\"li\">\n\nexport const QueueItem = ({ className, ...props }: QueueItemProps) => (\n  <li\n    className={cn(\n      \"group hover:bg-muted flex flex-col gap-1 rounded-md px-3 py-1 text-sm transition-colors\",\n      className\n    )}\n    {...props}\n  />\n)\n\nexport type QueueItemIndicatorProps = ComponentProps<\"span\"> & {\n  completed?: boolean\n}\n\nexport const QueueItemIndicator = ({\n  completed = false,\n  className,\n  ...props\n}: QueueItemIndicatorProps) => (\n  <span\n    className={cn(\n      \"mt-0.5 inline-block size-2.5 rounded-full border\",\n      completed\n        ? \"border-muted-foreground/20 bg-muted-foreground/10\"\n        : \"border-muted-foreground/50\",\n      className\n    )}\n    {...props}\n  />\n)\n\nexport type QueueItemContentProps = ComponentProps<\"span\"> & {\n  completed?: boolean\n}\n\nexport const QueueItemContent = ({\n  completed = false,\n  className,\n  ...props\n}: QueueItemContentProps) => (\n  <span\n    className={cn(\n      \"line-clamp-1 grow break-words\",\n      completed\n        ? \"text-muted-foreground/50 line-through\"\n        : \"text-muted-foreground\",\n      className\n    )}\n    {...props}\n  />\n)\n\nexport type QueueItemDescriptionProps = ComponentProps<\"div\"> & {\n  completed?: boolean\n}\n\nexport const QueueItemDescription = ({\n  completed = false,\n  className,\n  ...props\n}: QueueItemDescriptionProps) => (\n  <div\n    className={cn(\n      \"ml-6 text-xs\",\n      completed\n        ? \"text-muted-foreground/40 line-through\"\n        : \"text-muted-foreground\",\n      className\n    )}\n    {...props}\n  />\n)\n\nexport type QueueItemActionsProps = ComponentProps<\"div\">\n\nexport const QueueItemActions = ({\n  className,\n  ...props\n}: QueueItemActionsProps) => (\n  <div className={cn(\"flex gap-1\", className)} {...props} />\n)\n\nexport type QueueItemActionProps = Omit<\n  ComponentProps<typeof Button>,\n  \"variant\" | \"size\"\n>\n\nexport const QueueItemAction = ({\n  className,\n  ...props\n}: QueueItemActionProps) => (\n  <Button\n    className={cn(\n      \"text-muted-foreground hover:bg-muted-foreground/10 hover:text-foreground size-auto rounded p-1 opacity-0 transition-opacity group-hover:opacity-100\",\n      className\n    )}\n    size=\"icon\"\n    type=\"button\"\n    variant=\"ghost\"\n    {...props}\n  />\n)\n\nexport type QueueItemAttachmentProps = ComponentProps<\"div\">\n\nexport const QueueItemAttachment = ({\n  className,\n  ...props\n}: QueueItemAttachmentProps) => (\n  <div className={cn(\"mt-1 flex flex-wrap gap-2\", className)} {...props} />\n)\n\nexport type QueueItemImageProps = ComponentProps<\"img\">\n\nexport const QueueItemImage = ({\n  className,\n  ...props\n}: QueueItemImageProps) => (\n  <img\n    alt=\"\"\n    className={cn(\"h-8 w-8 rounded border object-cover\", className)}\n    height={32}\n    width={32}\n    {...props}\n  />\n)\n\nexport type QueueItemFileProps = ComponentProps<\"span\">\n\nexport const QueueItemFile = ({\n  children,\n  className,\n  ...props\n}: QueueItemFileProps) => (\n  <span\n    className={cn(\n      \"bg-muted flex items-center gap-1 rounded border px-2 py-1 text-xs\",\n      className\n    )}\n    {...props}\n  >\n    <PaperclipIcon size={12} />\n    <span className=\"max-w-[100px] truncate\">{children}</span>\n  </span>\n)\n\nexport type QueueListProps = ComponentProps<\"div\">\n\nexport const QueueList = ({\n  children,\n  className,\n  ...props\n}: QueueListProps) => (\n  <div className={cn(\"mt-2 -mb-1 overflow-y-auto\", className)} {...props}>\n    <div className=\"max-h-40 pr-4\">\n      <ul>{children}</ul>\n    </div>\n  </div>\n)\n\n// QueueSection - collapsible section container\nexport type QueueSectionProps = ComponentProps<typeof Disclosure>\n\nexport const QueueSection = ({\n  className,\n  defaultExpanded = true,\n  ...props\n}: QueueSectionProps) => (\n  <Disclosure\n    className={cn(className)}\n    defaultExpanded={defaultExpanded}\n    {...props}\n  />\n)\n\n// QueueSectionTrigger - section header/trigger\nexport type QueueSectionTriggerProps = ComponentProps<typeof Button>\n\nexport const QueueSectionTrigger = ({\n  children,\n  className,\n  ...props\n}: QueueSectionTriggerProps) => (\n  <Button\n    slot=\"trigger\"\n    className={cn(\n      \"group bg-muted/40 text-foreground hover:bg-muted flex w-full items-center justify-between rounded-md px-3 py-2 text-left text-sm transition-colors\",\n      className\n    )}\n    type=\"button\"\n    {...props}\n  >\n    {children}\n  </Button>\n)\n\n// QueueSectionLabel - label content with icon and count\nexport type QueueSectionLabelProps = ComponentProps<\"span\"> & {\n  count?: number\n  label: string\n  icon?: React.ReactNode\n}\n\nexport const QueueSectionLabel = ({\n  count,\n  label,\n  icon,\n  className,\n  ...props\n}: QueueSectionLabelProps) => (\n  <span className={cn(\"flex w-full items-center gap-2\", className)} {...props}>\n    <ChevronDownIcon className=\"size-4 transition-transform group-data-[state=closed]:-rotate-90\" />\n    <span>\n      {count} {label}\n    </span>\n    <span className=\"ms-auto inline-block\">{icon}</span>\n  </span>\n)\n\n// QueueSectionContent - collapsible content area\nexport type QueueSectionContentProps = ComponentProps<typeof DisclosurePanel>\n\nexport const QueueSectionContent = ({\n  className,\n  ...props\n}: QueueSectionContentProps) => (\n  <DisclosurePanel className={cn(className)} {...props} />\n)\n\nexport type QueueProps = ComponentProps<\"div\">\n\nexport const Queue = ({ className, ...props }: QueueProps) => (\n  <div\n    className={cn(\n      \"border-border bg-background flex flex-col gap-2 rounded-xl border px-3 pt-2 pb-2 shadow-xs\",\n      className\n    )}\n    {...props}\n  />\n)\n",
      "type": "registry:ui"
    }
  ],
  "type": "registry:ui"
}