{
  "component": {
    "id": "toggle-group",
    "name": "Toggle group",
    "tier": "pro",
    "exampleId": "toggle-group",
    "access": "pro",
    "requiresAuthorization": true
  },
  "source": {
    "demoModule": "src/toggle-group-demo.tsx",
    "exportName": "ToggleGroupDemo",
    "sha256": "bf51abe4e8127996083a3f2c490ca28e8aa676c822bef434d6b1bdc9bb236c56",
    "helperImports": [],
    "directComponentImports": [
      "toggle-group"
    ],
    "sampleBoundary": "Existing local demo fixture with fictional data and callbacks. No live service, customer data, access key, or Pro source is included."
  },
  "install": {
    "command": "npx shadcn@latest add @tidal-pro/toggle-group",
    "registryUrl": "https://tidalui.com/r/pro/toggle-group.json",
    "namespace": "@tidal-pro",
    "access": "pro",
    "sourceDelivery": "server-gated",
    "requiresAuthorization": true,
    "tokenSource": "local-env",
    "tokenEnvName": "TIDALUI_TOKEN",
    "cli": {
      "package": "shadcn",
      "requested": "latest"
    }
  },
  "installPlan": [
    {
      "order": 1,
      "kind": "primary",
      "dependency": "@tidal-pro/toggle-group",
      "purpose": "component",
      "command": "npx shadcn@latest add @tidal-pro/toggle-group",
      "registryUrl": "https://tidalui.com/r/pro/toggle-group.json",
      "access": "pro",
      "sourceDelivery": "server-gated",
      "requiresAuthorization": true
    }
  ],
  "imports": {
    "componentPath": "components/ui/toggle-group.tsx",
    "exports": [
      "TidalToggleGroup"
    ],
    "stylesheets": [
      "components/ui/tidal.css",
      "components/ui/toggle-group.css"
    ],
    "scopeClass": "tidal-scope"
  },
  "dependencies": {
    "npm": [
      "lucide-react"
    ],
    "registry": [],
    "additionalRegistry": [],
    "installClosure": [
      "toggle-group"
    ],
    "css": [
      "components/ui/tidal.css",
      "components/ui/toggle-group.css"
    ],
    "demoCss": [],
    "consumerOwned": [
      "react",
      "react-dom"
    ]
  },
  "files": {
    "sourceFile": "/examples/toggle-group.tsx",
    "demoStyles": [],
    "inlinedDemoStyles": [
      "src/toggle-group-demo.css"
    ],
    "assets": []
  },
  "example": {
    "language": "tsx",
    "source": "\"use client\";\n\nimport \"./components/ui/tidal.css\";\n\nimport { useId, useState } from \"react\";\n\nimport { AlignJustify, CalendarDays, CircleUserRound, Grid2X2, List, Tag } from \"lucide-react\";\n\nimport { TidalToggleGroup } from \"./components/ui/toggle-group\";\n\nimport \"./components/ui/toggle-group.css\";\n\n\n\nconst tidalExampleStyles = \".tidal-scope .toggle-group-demo,\\n.tidal-scope .toggle-group-demo * {\\n  box-sizing: border-box;\\n}\\n\\n.tidal-scope .toggle-group-demo {\\n  container: toggle-group-demo / inline-size;\\n  display: grid;\\n  gap: 16px;\\n  width: min(100%, 620px);\\n  min-width: 0;\\n  color: var(--t-ink);\\n}\\n\\n.tidal-scope .toggle-group-demo-controls {\\n  display: grid;\\n  grid-template-columns: minmax(280px, 0.95fr) minmax(0, 1.05fr);\\n  gap: 16px;\\n}\\n\\n.tidal-scope .toggle-group-demo-controls > div {\\n  display: grid;\\n  min-width: 0;\\n  gap: 8px;\\n}\\n\\n.tidal-scope .toggle-group-demo-controls > div > span {\\n  color: var(--t-muted);\\n  font-size: 11px;\\n  font-weight: 650;\\n  line-height: 1.4;\\n}\\n\\n.tidal-scope .toggle-group-demo-controls .tidal-toggle-group {\\n  width: 100%;\\n}\\n\\n.tidal-scope .toggle-group-demo-controls .tidal-toggle-group-item {\\n  min-width: 44px;\\n  flex: 1 1 0;\\n  gap: 5px;\\n  padding-inline: 6px;\\n}\\n\\n.tidal-scope .toggle-group-demo-projects {\\n  display: block;\\n  min-width: 0;\\n}\\n\\n.tidal-scope .toggle-group-demo-projects article {\\n  display: flex;\\n  align-items: center;\\n  justify-content: space-between;\\n  gap: 10px;\\n  min-width: 0;\\n  min-height: 52px;\\n  padding: 6px 10px;\\n  border: 1px solid var(--t-border);\\n  border-radius: 10px;\\n  background: var(--t-surface);\\n  transition:\\n    border-radius 220ms var(--t-ease-out),\\n    background 220ms var(--t-ease-out);\\n}\\n\\n.tidal-scope .toggle-group-demo-projects[data-layout=\\\"grid\\\"] article {\\n  border-radius: 14px;\\n  background: var(--t-wash);\\n}\\n\\n.tidal-scope .toggle-group-demo-projects[data-layout=\\\"dense\\\"] article {\\n  min-height: 44px;\\n  padding-block: 3px;\\n}\\n\\n.tidal-scope .toggle-group-demo-project-name {\\n  display: grid;\\n  min-width: 0;\\n}\\n\\n.tidal-scope .toggle-group-demo-project-name strong {\\n  min-width: 0;\\n  font-size: 13px;\\n  line-height: 1.35;\\n  overflow-wrap: anywhere;\\n}\\n\\n.tidal-scope .toggle-group-demo-project-name > span {\\n  color: var(--t-muted);\\n  font-size: 11px;\\n  line-height: 1.25;\\n  text-transform: capitalize;\\n}\\n\\n.tidal-scope .toggle-group-demo-project-meta {\\n  display: flex;\\n  flex-wrap: wrap;\\n  justify-content: flex-end;\\n  gap: 6px;\\n  min-width: 0;\\n}\\n\\n.tidal-scope .toggle-group-demo-project-meta span {\\n  display: inline-flex;\\n  min-height: 24px;\\n  align-items: center;\\n  padding-inline: 7px;\\n  border: 1px solid var(--t-border);\\n  border-radius: 6px;\\n  color: var(--t-muted);\\n  font-size: 11px;\\n  line-height: 1.25;\\n  overflow-wrap: anywhere;\\n}\\n\\n.tidal-scope .toggle-group-demo-note {\\n  margin: 0;\\n  color: var(--t-muted);\\n  font-size: 11px;\\n  line-height: 1.5;\\n}\\n\\n@container toggle-group-demo (max-width: 520px) {\\n  .tidal-scope .toggle-group-demo-controls {\\n    grid-template-columns: minmax(0, 1fr);\\n  }\\n}\\n\\n@container toggle-group-demo (max-width: 300px) {\\n  .tidal-scope .toggle-group-demo-projects article {\\n    align-items: flex-start;\\n    flex-direction: column;\\n  }\\n\\n  .tidal-scope .toggle-group-demo-project-meta {\\n    justify-content: flex-start;\\n  }\\n}\\n\\n@media (prefers-reduced-motion: reduce) {\\n  .tidal-scope .toggle-group-demo-projects article {\\n    transition: none;\\n  }\\n}\";\n\nexport function ToggleGroupDemo() {\n  const generatedId = useId().replace(/:/g, \"\");\n  const [layout, setLayout] = useState<string | null>(\"grid\");\n  const [details, setDetails] = useState<string[]>([\"owner\", \"status\"]);\n\n  return (\n    <section\n      className=\"toggle-group-demo\"\n      aria-labelledby={`${generatedId}-title`}\n    >\n      <div className=\"toggle-group-demo-controls\">\n        <div>\n          <span id={`${generatedId}-title`}>Project view</span>\n          <TidalToggleGroup\n            type=\"single\"\n            label=\"Project layout\"\n            value={layout}\n            onValueChange={setLayout}\n            items={[\n              {\n                id: \"grid\",\n                value: \"grid\",\n                label: \"Grid\",\n                icon: <Grid2X2 aria-hidden=\"true\" />,\n              },\n              {\n                id: \"list\",\n                value: \"list\",\n                label: \"List\",\n                icon: <List aria-hidden=\"true\" />,\n              },\n              {\n                id: \"dense\",\n                value: \"dense\",\n                label: \"Dense\",\n                icon: <AlignJustify aria-hidden=\"true\" />,\n              },\n            ]}\n          />\n        </div>\n        <div>\n          <span>Visible details</span>\n          <TidalToggleGroup\n            type=\"multiple\"\n            label=\"Visible project details\"\n            value={details}\n            onValueChange={setDetails}\n            items={[\n              {\n                id: \"owner\",\n                value: \"owner\",\n                label: \"Owner\",\n                icon: <CircleUserRound aria-hidden=\"true\" />,\n              },\n              {\n                id: \"due\",\n                value: \"due\",\n                label: \"Due date\",\n                icon: <CalendarDays aria-hidden=\"true\" />,\n              },\n              {\n                id: \"status\",\n                value: \"status\",\n                label: \"Status\",\n                icon: <Tag aria-hidden=\"true\" />,\n              },\n            ]}\n          />\n        </div>\n      </div>\n\n      <div\n        className=\"toggle-group-demo-projects\"\n        data-layout={layout ?? \"plain\"}\n        aria-label=\"Sample project preview\"\n      >\n        <article>\n          <div className=\"toggle-group-demo-project-name\">\n            <strong>Launch notes</strong>\n            <span>{layout ? `${layout} view` : \"plain view\"}</span>\n          </div>\n          <div className=\"toggle-group-demo-project-meta\">\n            {details.includes(\"owner\") ? <span>Ava</span> : null}\n            {details.includes(\"due\") ? <span>Oct 18</span> : null}\n            {details.includes(\"status\") ? <span>Ready</span> : null}\n          </div>\n        </article>\n      </div>\n      <p className=\"toggle-group-demo-note\">\n        Sample project data. Changes stay in this preview.\n      </p>\n    </section>\n  );\n}\n\nexport default function AgentExample() {\n  return (\n    <div className=\"tidal-scope\" data-theme=\"light\" dir=\"ltr\">\n      <style>{tidalExampleStyles}</style>\n      <ToggleGroupDemo />\n    </div>\n  );\n}\n",
    "sourceFile": "/examples/toggle-group.tsx",
    "fixtureData": "Existing demo fixture data only; replace with consumer-owned data before production use."
  },
  "controlledState": [
    {
      "prop": "value",
      "type": "inferred-from-existing-demo",
      "initial": "\"grid\"",
      "setter": "setLayout",
      "proposalCanBeRejected": false
    }
  ],
  "events": [
    {
      "name": "onValueChange",
      "nativeType": "component callback",
      "callerFirst": true,
      "preventable": true,
      "observedResult": "The existing demo callback remains the source of truth; this example does not call a live service."
    }
  ],
  "nativeForm": {
    "participates": true,
    "names": [],
    "expectedFormData": {},
    "submitBehavior": "The existing demo's native form callback receives the submit event.",
    "resetBehavior": "Native reset behavior remains available where the demo renders a resettable control.",
    "disabledBehavior": "Disabled controls remain excluded from successful native form submission.",
    "readOnlyBehavior": "Read-only controls retain their value and remain inspectable by the consumer."
  },
  "accessibility": {
    "labelSource": "Existing demo label or ARIA prop",
    "semantics": "Preserve the component's native element and the semantics demonstrated by the source fixture.",
    "keyboard": [
      "Tab and Shift+Tab",
      "Enter or Space for native activation",
      "Arrow keys where the component exposes a composite control"
    ],
    "focusReturn": "Preserve browser focus order and visible focus.",
    "errorAnnouncement": "No error announcement path is present in this demo; the consumer owns validation messaging.",
    "reducedMotion": "Verify prefers-reduced-motion with the existing component transition path.",
    "forcedColors": "Verify visible borders, text, and focus in forced-colors mode."
  },
  "responsive": {
    "widths": [
      320,
      390,
      768,
      1260
    ],
    "shortViewport": "Check the example at a 300px viewport height with keyboard or portal content visible.",
    "overflow": "The page should not gain horizontal overflow; component-local scrolling must remain intentional.",
    "touchTargetMinPx": 44,
    "coarseInputFontPx": 16
  },
  "errors": [
    {
      "fixture": "No error fixture is exposed by the existing demo; inject a consumer-owned failure state before production use.",
      "visibleResult": "The consumer-visible result must remain explicit and must not be replaced by a silent console error.",
      "focusResult": "Focus must remain on the triggering control or move to the announced error according to the native pattern.",
      "ownership": "Consumer-owned sample state only; no network request or customer data is used."
    }
  ],
  "verification": {
    "commands": [
      "npx tsc --noEmit",
      "npx vite build"
    ],
    "lockfile": "Use the consumer project's committed lockfile.",
    "browser": [
      "Chromium 1260x800",
      "Chromium 390x844",
      "Keyboard and reduced-motion pass"
    ]
  },
  "validation": {
    "consumerFixture": {
      "tsc": "pass",
      "viteBuild": "pass",
      "resourceModel": "Generated usage plus only the component files and CSS delivered by the primary item and listed registry dependencies."
    },
    "registryArtifact": "server-gated"
  },
  "exceptions": []
}
