{
  "$schema": "https://registry.buildy.tw/schema/registry-item.json",
  "dependencies": [],
  "description": "A form field: label, control (children), hint and error text. `htmlFor` ties the label to the id of the control.",
  "devDependencies": [],
  "digest": "0.1.0",
  "files": [
    {
      "content": "{#- Code generated by packages/kit-compose/src/server-organisms.ts from packages/compose-gen/specs (compose-gen organism emitters on kit-compose). DO NOT EDIT.\n    Source: packages/compose-gen/specs/parts/field.json\n    A form field: label, control (children), hint and error text. `htmlFor` ties the label to the id of the control.\n    Props (p): label, htmlFor, hint, error, className; children: markup. -#}\n{%- set v_label = (p.label ?? null) -%}\n{%- set v_htmlFor = (p.htmlFor ?? null) -%}\n{%- set v_hint = (p.hint ?? null) -%}\n{%- set v_error = (p.error ?? null) -%}\n{%- set c_4 -%}\n  {%- set c_1 -%}\n    {{ og_text(v_label) }}\n  {%- endset -%}\n  {{ include('compose/Label.html.twig', {'class': 'text-xs font-bold text-foreground', 'htmlFor': og_s(v_htmlFor), 'children': c_1}, with_context = false) }}\n  {{ og_slot((children ?? null))|raw }}\n  {%- if og_t(v_error) %}\n    {%- set c_2 -%}\n      {{ og_text(v_error) }}\n    {%- endset -%}\n    {{ include('compose/Text.html.twig', {'class': 'm-0 text-xs font-semibold text-destructive', 'attrs': og_attrs(['role', 'alert']), 'children': c_2}, with_context = false) }}\n  {%- elseif og_t(v_hint) %}\n    {%- set c_3 -%}\n      {{ og_text(v_hint) }}\n    {%- endset -%}\n    {{ include('compose/Text.html.twig', {'class': 'm-0 text-xs font-medium text-muted-foreground', 'children': c_3}, with_context = false) }}\n  {%- endif %}\n{%- endset -%}\n{{ include('compose/Box.html.twig', {'class': og_s(og_cnv(['flex min-w-0 flex-col gap-2', (p.className ?? '')])), 'children': c_4}, with_context = false) }}\n",
      "path": "blocks/field.html.twig",
      "target": "blocks/field.html.twig"
    }
  ],
  "meta": {
    "category": "components",
    "kind": "component",
    "tags": [
      "twig",
      "component"
    ]
  },
  "name": "field",
  "registryDependencies": [
    "box",
    "label",
    "text",
    "utils"
  ],
  "runtime": "twig",
  "title": "Field",
  "type": "registry:component"
}
