{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "field-trigger",
  "title": "Field Trigger",
  "author": "zyx1121 (https://github.com/zyx1121)",
  "description": "Shared class list for pick-a-value triggers.",
  "files": [
    {
      "path": "registry/zyx/components/ui/field-trigger.ts",
      "content": "// The closed state of every pick-a-value control (select, combobox): it has\n// to read as the same kind of field as Input, so they share one class list.\n// The outline is a frame (FrameEdges) colored by fieldFrameClassName.\nexport const fieldTriggerClassName =\n  \"group/field relative flex h-10 w-fit rounded-control items-center justify-between gap-2 bg-transparent px-3 text-body whitespace-nowrap transition-colors outline-none select-none disabled:cursor-not-allowed disabled:opacity-50 data-placeholder:text-muted-foreground [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0\"\n\n// A field's frame: the input line color at rest, the text color in focus,\n// red when invalid. The frame's parent is the field (group/field): a trigger itself, or\n// the box around an input.\nexport const fieldFrameClassName =\n  \"text-input transition duration-state group-focus-visible/field:text-ring group-has-focus-visible/field:text-ring group-aria-invalid/field:text-destructive group-has-aria-invalid/field:text-destructive\"\n",
      "type": "registry:ui"
    }
  ],
  "meta": {
    "useWhen": "Styling your own pick-a-value trigger like select and combobox.",
    "notFor": "Buttons; use button.",
    "related": [
      "select",
      "combobox"
    ]
  },
  "docs": "Use when: Styling your own pick-a-value trigger like select and combobox.\nNot for: Buttons; use button.\nGuide: https://ui.zyx.tw/index.md",
  "categories": [
    "primitive",
    "form"
  ],
  "type": "registry:ui"
}