{
  "component": {
    "id": "masked-input",
    "name": "Masked input",
    "tier": "pro",
    "exampleId": "masked-input",
    "access": "pro",
    "requiresAuthorization": true
  },
  "source": {
    "demoModule": "src/masked-input-demo.tsx",
    "exportName": "MaskedInputDemo",
    "sha256": "2fa0d37b4ada1e286febc01a151976a1ffdc8017d36e3d42fc50621c09ffa31d",
    "helperImports": [],
    "directComponentImports": [
      "masked-input"
    ],
    "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/masked-input",
    "registryUrl": "https://tidalui.com/r/pro/masked-input.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/masked-input",
      "purpose": "component",
      "command": "npx shadcn@latest add @tidal-pro/masked-input",
      "registryUrl": "https://tidalui.com/r/pro/masked-input.json",
      "access": "pro",
      "sourceDelivery": "server-gated",
      "requiresAuthorization": true
    }
  ],
  "imports": {
    "componentPath": "components/ui/masked-input.tsx",
    "exports": [
      "TidalMaskedInput"
    ],
    "stylesheets": [
      "components/ui/tidal.css",
      "components/ui/masked-input.css"
    ],
    "scopeClass": "tidal-scope"
  },
  "dependencies": {
    "npm": [],
    "registry": [],
    "additionalRegistry": [],
    "installClosure": [
      "masked-input"
    ],
    "css": [
      "components/ui/tidal.css",
      "components/ui/masked-input.css"
    ],
    "demoCss": [],
    "consumerOwned": [
      "react",
      "react-dom"
    ]
  },
  "files": {
    "sourceFile": "/examples/masked-input.tsx",
    "demoStyles": [],
    "inlinedDemoStyles": [
      "src/masked-input-demo.css"
    ],
    "assets": []
  },
  "example": {
    "language": "tsx",
    "source": "import \"./components/ui/tidal.css\";\n\nimport \"./components/ui/masked-input.css\";\n\nimport { useRef, useState, type FormEvent } from \"react\";\n\nimport { TidalMaskedInput } from \"./components/ui/masked-input\";\n\n\n\nconst tidalExampleStyles = \".tidal-scope .masked-input-demo {\\n  display: grid;\\n  width: 100%;\\n  max-width: 560px;\\n  min-width: 0;\\n  gap: 22px;\\n  margin: 0 auto;\\n}\\n\\n.tidal-scope .masked-input-demo-actions {\\n  display: flex;\\n  min-width: 0;\\n  flex-wrap: wrap;\\n  gap: 8px;\\n}\\n\\n.tidal-scope .masked-input-demo-actions button {\\n  min-width: 44px;\\n  min-height: 44px;\\n  padding: 9px 14px;\\n  color: var(--t-ink);\\n  background: var(--t-surface);\\n  border: 1px solid var(--t-border);\\n  border-radius: var(--t-radius-control);\\n  font: inherit;\\n  font-size: 12px;\\n  font-weight: 700;\\n  line-height: 1.25;\\n  overflow-wrap: anywhere;\\n  cursor: pointer;\\n  transition:\\n    color 160ms var(--t-ease-out),\\n    background 160ms var(--t-ease-out),\\n    border-color 160ms var(--t-ease-out),\\n    transform 140ms var(--t-ease-out);\\n}\\n\\n.tidal-scope .masked-input-demo-actions button:last-child {\\n  margin-inline-start: auto;\\n  color: var(--t-surface);\\n  background: var(--t-ink);\\n  border-color: var(--t-ink);\\n}\\n\\n.tidal-scope .masked-input-demo-actions button:focus-visible {\\n  outline: 2px solid var(--t-accent);\\n  outline-offset: 3px;\\n}\\n\\n.tidal-scope .masked-input-demo-status,\\n.tidal-scope .masked-input-demo-note {\\n  margin: 0;\\n  color: var(--t-muted);\\n  font-size: 11px;\\n  line-height: 1.55;\\n  overflow-wrap: anywhere;\\n}\\n\\n.tidal-scope .masked-input-demo-status {\\n  min-height: 18px;\\n  color: var(--t-ink);\\n  font-weight: 650;\\n}\\n\\n@media (hover: hover) and (pointer: fine) {\\n  .tidal-scope .masked-input-demo-actions button:hover {\\n    color: var(--t-surface);\\n    background: var(--t-ink);\\n    border-color: var(--t-ink);\\n  }\\n\\n  .tidal-scope .masked-input-demo-actions button:active {\\n    transform: scale(0.975);\\n  }\\n}\\n\\n@media (max-width: 390px) {\\n  .tidal-scope .masked-input-demo {\\n    gap: 18px;\\n  }\\n\\n  .tidal-scope .masked-input-demo-actions {\\n    display: grid;\\n    grid-template-columns: repeat(2, minmax(0, 1fr));\\n  }\\n\\n  .tidal-scope .masked-input-demo-actions button:last-child {\\n    grid-column: 1 / -1;\\n    margin-inline-start: 0;\\n  }\\n}\\n\\n@media (prefers-reduced-motion: reduce) {\\n  .tidal-scope .masked-input-demo-actions button {\\n    transition: none;\\n    transform: none;\\n  }\\n}\";\n\nconst INITIAL_PHONE = \"442079460123\";\n\nconst INITIAL_REFERENCE = \"UI2026WAVE\";\n\nexport function MaskedInputDemo() {\n  const [phone, setPhone] = useState(INITIAL_PHONE);\n  const [reference, setReference] = useState(INITIAL_REFERENCE);\n  const [status, setStatus] = useState(\n    \"The visible format and raw form values are ready to inspect.\",\n  );\n  const phoneInput = useRef<HTMLInputElement>(null);\n\n  function submit(event: FormEvent<HTMLFormElement>) {\n    event.preventDefault();\n    const data = new FormData(event.currentTarget);\n    setStatus(\n      `Local form values: phone ${String(data.get(\"phone\"))}; reference ${String(data.get(\"reference\"))}.`,\n    );\n  }\n\n  return (\n    <form\n      className=\"masked-input-demo\"\n      onSubmit={submit}\n      onReset={() => {\n        setPhone(\"\");\n        setReference(\"\");\n        setStatus(\"Local fields cleared.\");\n        queueMicrotask(() =>\n          phoneInput.current?.focus({ preventScroll: true }),\n        );\n      }}\n    >\n      <TidalMaskedInput\n        ref={phoneInput}\n        label=\"Sample phone number\"\n        mask=\"+## ## #### ####\"\n        value={phone}\n        onValueChange={(next) => {\n          setPhone(next);\n          setStatus(\"Sample phone value changed locally.\");\n        }}\n        name=\"phone\"\n        inputMode=\"numeric\"\n        autoComplete=\"tel\"\n        placeholder=\"+44 20 7946 0123\"\n        description=\"This example format is supplied by the demo. Consumers choose the mask that fits their data.\"\n        required\n      />\n\n      <TidalMaskedInput\n        label=\"Project reference\"\n        mask=\"AA-####-****\"\n        value={reference}\n        onValueChange={(next) => {\n          setReference(next);\n          setStatus(\"Project reference changed locally.\");\n        }}\n        name=\"reference\"\n        autoComplete=\"off\"\n        placeholder=\"UI-2026-WAVE\"\n        description=\"Letters are normalized to uppercase; the raw form value omits separators.\"\n        required\n      />\n\n      <div className=\"masked-input-demo-actions\">\n        <button\n          type=\"button\"\n          onClick={() => {\n            setPhone(INITIAL_PHONE);\n            setReference(INITIAL_REFERENCE);\n            setStatus(\"Sample values restored.\");\n            phoneInput.current?.focus({ preventScroll: true });\n          }}\n        >\n          Fill sample\n        </button>\n        <button type=\"reset\">Clear</button>\n        <button type=\"submit\">Read form values</button>\n      </div>\n\n      <output className=\"masked-input-demo-status\">{status}</output>\n      <p className=\"masked-input-demo-note\">\n        Local sample only. The component formats input and prepares exact native\n        form values; it makes no request and stores nothing.\n      </p>\n    </form>\n  );\n}\n\nexport default function AgentExample() {\n  return (\n    <div className=\"tidal-scope\" data-theme=\"light\" dir=\"ltr\">\n      <style>{tidalExampleStyles}</style>\n      <MaskedInputDemo />\n    </div>\n  );\n}\n",
    "sourceFile": "/examples/masked-input.tsx",
    "fixtureData": "Existing demo fixture data only; replace with consumer-owned data before production use."
  },
  "controlledState": [
    {
      "prop": "value",
      "type": "inferred-from-existing-demo",
      "initial": "INITIAL_PHONE",
      "setter": "setPhone",
      "proposalCanBeRejected": false
    }
  ],
  "events": [
    {
      "name": "onClick",
      "nativeType": "React synthetic event or native callback",
      "callerFirst": true,
      "preventable": true,
      "observedResult": "The existing demo callback remains the source of truth; this example does not call a live service."
    },
    {
      "name": "onReset",
      "nativeType": "React synthetic event or native callback",
      "callerFirst": true,
      "preventable": true,
      "observedResult": "The existing demo callback remains the source of truth; this example does not call a live service."
    },
    {
      "name": "onSubmit",
      "nativeType": "React synthetic event or native callback",
      "callerFirst": true,
      "preventable": true,
      "observedResult": "The existing demo callback remains the source of truth; this example does not call a live service."
    },
    {
      "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": [
      "phone",
      "reference"
    ],
    "expectedFormData": {
      "phone": "fixture value",
      "reference": "fixture value"
    },
    "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": []
}
