{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "select-invalid",
  "title": "Select component in an invalid state",
  "description": "Select component in an invalid state, built from the select component.",
  "registryDependencies": [
    "field",
    "select"
  ],
  "files": [
    {
      "path": "registry/patterns/select-invalid/select-invalid.tsx",
      "content": "/**\n * Select component in an invalid state - adapted for tealmac UI from the ReUI example \"c-select-9\"\n * (https://github.com/keenthemes/reui), MIT License, Copyright (c) 2025\n * Keenthemes Inc. The full licence text is in THIRD_PARTY_NOTICES.md.\n * Changes: tealmac UI import paths and theme tokens, lucide icons, logical\n * (RTL-safe) spacing and alignment, reduced-motion support and sample\n * content.\n */\nimport { Field, FieldError, FieldLabel } from \"@/components/ui/field\"\nimport {\n  Select,\n  SelectContent,\n  SelectGroup,\n  SelectItem,\n  SelectTrigger,\n  SelectValue,\n} from \"@/components/ui/select\"\n\nconst items = [\n  { label: \"Select a fruit\", value: null },\n  { label: \"Apple\", value: \"apple\" },\n  { label: \"Banana\", value: \"banana\" },\n  { label: \"Blueberry\", value: \"blueberry\" },\n]\n\nexport function SelectInvalid() {\n  return (\n    <Field className=\"max-w-xs\" data-invalid>\n      <FieldLabel htmlFor=\"select-fruit-invalid\">Favorite Fruit</FieldLabel>\n      <Select>\n        <SelectTrigger id=\"select-fruit-invalid\" aria-invalid>\n          <SelectValue placeholder=\"Select a fruit\" />\n        </SelectTrigger>\n        <SelectContent position=\"popper\">\n          <SelectGroup>\n            {items.map((item) => (\n              <SelectItem key={item.value} value={item.value as string}>\n                {item.label}\n              </SelectItem>\n            ))}\n          </SelectGroup>\n        </SelectContent>\n      </Select>\n      <FieldError errors={[{ message: \"Please select a valid fruit.\" }]} />\n    </Field>\n  )\n}\n",
      "type": "registry:block"
    }
  ],
  "type": "registry:block"
}