{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "suggestions",
  "registryDependencies": [
    "utils"
  ],
  "files": [
    {
      "path": "src/registry/ui/suggestions.tsx",
      "content": "\"use client\";\n\nimport { cn } from \"@/lib/utils\";\n\nexport type Suggestion = string | { label: string; value?: string };\n\n/** A row of starter prompts. One line that scrolls sideways on narrow screens, wraps on wider ones. */\nexport function Suggestions({\n  items,\n  onSelect,\n  disabled = false,\n  label = \"Suggested prompts\",\n  className,\n}: {\n  items: Suggestion[];\n  /** Called with the prompt text: `value` when given, otherwise the label. */\n  onSelect: (prompt: string) => void;\n  /** Keep the row visible but inert, e.g. while a reply streams. Avoids losing keyboard focus. */\n  disabled?: boolean;\n  /** Accessible name of the group. */\n  label?: string;\n  className?: string;\n}) {\n  return (\n    <div\n      role=\"group\"\n      aria-label={label}\n      className={cn(\n        \"-m-1 flex gap-2 overflow-x-auto p-1 sm:flex-wrap sm:overflow-visible [scrollbar-width:none] [&::-webkit-scrollbar]:hidden\",\n        className,\n      )}\n    >\n      {items.map((item) => {\n        const text = typeof item === \"string\" ? item : item.label;\n        const value = typeof item === \"string\" ? item : (item.value ?? item.label);\n        return (\n          <button\n            key={text}\n            type=\"button\"\n            disabled={disabled}\n            onClick={() => onSelect(value)}\n            className=\"shrink-0 whitespace-nowrap rounded border px-3 py-1.5 text-[14px] text-muted-foreground outline-none transition-colors hover:border-foreground/40 hover:text-foreground focus-visible:ring-2 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50\"\n          >\n            {text}\n          </button>\n        );\n      })}\n    </div>\n  );\n}\n",
      "type": "registry:ui"
    }
  ],
  "type": "registry:ui"
}