{
  "id": "form",
  "name": "Form",
  "level": "organism",
  "status": "stable",
  "purpose": "Runs a whole form: checks every answer and shows what needs fixing before it sends.",
  "description": "Apple-style form orchestrator built around React Hook Form. Pass `methods` from `useForm()` (typically wired with a Zod resolver via `@hookform/resolvers/zod`) and the orchestrator handles `handleSubmit`, `FormProvider`, the auto-mounted ErrorSummary on failed submits, success transient on the Submit button, and the canonical Apple-app-shell action row. The compound parts — `Form.Field`, `Form.Input`, `Form.Textarea`, `Form.Checkbox`, `Form.Switch`, `Form.RadioGroup`, `Form.Select`, `Form.Slider`, `Form.Submit`, `Form.Reset`, `Form.ErrorSummary`, `Form.Section`, `Form.Surface` — read RHF state via `useFormContext()` so consumers never prop-drill.",
  "role": "input",
  "import": "@rrios-forge/ui/organisms/form",
  "exports": [
    "Form",
    "FormCheckbox",
    "FormErrorSummary",
    "FormField",
    "FormInput",
    "FormRadioGroup",
    "FormReset",
    "FormSelect",
    "FormSlider",
    "FormSubmit",
    "FormSurface",
    "FormSwitch",
    "FormTextarea",
    "FORM_DENSITIES",
    "FORM_INTENTS",
    "formVariants",
    "buildErrorSummary"
  ],
  "source": "packages/ui/src/organisms/form",
  "axes": [
    {
      "axis": "align",
      "part": null,
      "values": [
        "between",
        "end"
      ],
      "default": "end",
      "meaning": "Distribution along the main axis."
    },
    {
      "axis": "tone",
      "part": null,
      "values": [
        "neutral",
        "muted"
      ],
      "default": "neutral",
      "meaning": "Which semantic colour family the element speaks in."
    },
    {
      "axis": "material",
      "part": null,
      "values": [
        "vibrant",
        "solid"
      ],
      "default": "vibrant",
      "meaning": "The layer's material (ADR-022, ADR-027)."
    }
  ],
  "needs": [
    {
      "need": "Complex validated form",
      "answer": "`Form` organism (RHF + Zod)"
    }
  ],
  "patterns": [],
  "a11yExceptions": [],
  "decisions": [
    {
      "id": "ADR-019",
      "title": "Composer organism (message/post authoring surface)"
    }
  ],
  "stories": [
    {
      "name": "Playground",
      "id": "components-organisms-form--playground",
      "interaction": false,
      "snapshots": [
        "dark",
        "light"
      ],
      "skipsSnapshot": false,
      "docs": "/?path=/story/components-organisms-form--playground",
      "frame": "/iframe.html?id=components-organisms-form--playground&viewMode=story"
    },
    {
      "name": "On a card",
      "id": "components-organisms-form--surface",
      "interaction": false,
      "snapshots": [
        "dark",
        "light"
      ],
      "skipsSnapshot": false,
      "docs": "/?path=/story/components-organisms-form--surface",
      "frame": "/iframe.html?id=components-organisms-form--surface&viewMode=story"
    },
    {
      "name": "Toggles and choices",
      "id": "components-organisms-form--controlled-fields",
      "interaction": false,
      "snapshots": [
        "dark",
        "light"
      ],
      "skipsSnapshot": false,
      "docs": "/?path=/story/components-organisms-form--controlled-fields",
      "frame": "/iframe.html?id=components-organisms-form--controlled-fields&viewMode=story"
    },
    {
      "name": "Repeating fields",
      "id": "components-organisms-form--field-array",
      "interaction": false,
      "snapshots": [
        "dark",
        "light"
      ],
      "skipsSnapshot": false,
      "docs": "/?path=/story/components-organisms-form--field-array",
      "frame": "/iframe.html?id=components-organisms-form--field-array&viewMode=story"
    },
    {
      "name": "Errors on submit",
      "id": "components-organisms-form--invalid-on-submit",
      "interaction": true,
      "snapshots": [
        "dark",
        "light"
      ],
      "skipsSnapshot": false,
      "docs": "/?path=/story/components-organisms-form--invalid-on-submit",
      "frame": "/iframe.html?id=components-organisms-form--invalid-on-submit&viewMode=story"
    },
    {
      "name": "Editing",
      "id": "components-organisms-form--edit-intent",
      "interaction": false,
      "snapshots": [
        "dark",
        "light"
      ],
      "skipsSnapshot": false,
      "docs": "/?path=/story/components-organisms-form--edit-intent",
      "frame": "/iframe.html?id=components-organisms-form--edit-intent&viewMode=story"
    },
    {
      "name": "Fix and submit",
      "id": "components-organisms-form--fix-and-submit",
      "interaction": true,
      "snapshots": [],
      "skipsSnapshot": true,
      "docs": "/?path=/story/components-organisms-form--fix-and-submit",
      "frame": "/iframe.html?id=components-organisms-form--fix-and-submit&viewMode=story"
    }
  ],
  "storyFile": "tooling/storybook/stories/components/organisms/form.stories.tsx"
}
