{
  "id": "switch",
  "name": "Switch",
  "level": "atom",
  "status": "stable",
  "purpose": "Turns a setting on or off, applied at once.",
  "description": "Binary on/off toggle for instant changes. Composes `@radix-ui/react-switch` (`role=\"switch\"`, `aria-checked`). Use Switch for changes that apply the moment the user toggles; use Checkbox for choices that apply on submit.",
  "role": "input",
  "import": "@rrios-forge/ui/atoms/switch",
  "exports": [
    "Switch",
    "switchVariants",
    "SWITCH_SIZES",
    "SWITCH_THUMB_CLASSES"
  ],
  "source": "packages/ui/src/atoms/switch",
  "axes": [
    {
      "axis": "size",
      "part": null,
      "values": [
        "sm",
        "md",
        "lg"
      ],
      "default": "md",
      "meaning": "Ergonomic scale, in three families (control, text, container)."
    }
  ],
  "needs": [
    {
      "need": "Binary toggle / checkbox / radio group",
      "answer": "`Switch` (in `SettingsField` with label) / `Checkbox` / `ChoiceGroup` with `Radio`"
    }
  ],
  "patterns": [],
  "a11yExceptions": [],
  "decisions": [
    {
      "id": "ADR-037",
      "title": "Continuity motion: a decelerating curve, a travelling indicator, view transitions and the SegmentedControl"
    }
  ],
  "stories": [
    {
      "name": "Playground",
      "id": "components-atoms-switch--playground",
      "interaction": false,
      "snapshots": [
        "dark",
        "light"
      ],
      "skipsSnapshot": false,
      "docs": "/?path=/story/components-atoms-switch--playground",
      "frame": "/iframe.html?id=components-atoms-switch--playground&viewMode=story"
    },
    {
      "name": "Sizes",
      "id": "components-atoms-switch--sizes",
      "interaction": false,
      "snapshots": [
        "dark",
        "light"
      ],
      "skipsSnapshot": false,
      "docs": "/?path=/story/components-atoms-switch--sizes",
      "frame": "/iframe.html?id=components-atoms-switch--sizes&viewMode=story"
    },
    {
      "name": "States",
      "id": "components-atoms-switch--states",
      "interaction": false,
      "snapshots": [
        "dark",
        "high-contrast",
        "light"
      ],
      "skipsSnapshot": false,
      "docs": "/?path=/story/components-atoms-switch--states",
      "frame": "/iframe.html?id=components-atoms-switch--states&viewMode=story"
    },
    {
      "name": "With label",
      "id": "components-atoms-switch--with-label",
      "interaction": false,
      "snapshots": [
        "dark",
        "light"
      ],
      "skipsSnapshot": false,
      "docs": "/?path=/story/components-atoms-switch--with-label",
      "frame": "/iframe.html?id=components-atoms-switch--with-label&viewMode=story"
    }
  ],
  "storyFile": "tooling/storybook/stories/components/atoms/switch.stories.tsx"
}
