component-stateslisted
Install: claude install-skill KyaniteLabs/tastecheck
# Component States
An interactive control is a lifecycle, not a resting style. Map every applicable state
to semantics, a visible treatment, and recovery.
## Decision order and evidence contract
1. Name role, interaction model, owner, and applicable states.
2. Give each state an ARIA/DOM mapping, visible non-color treatment, trigger, and recovery.
3. Test keyboard, focus-visible, contrast, reduced motion, and async completion.
Report one evidence row per state; `n/a` needs a subject-absence reason. Hand field
validation to `form-ux`, region emptiness to `empty-states`, and missing state tokens
back as gaps rather than invented fallbacks.
## Async and destructive controls
Name one semantic owner; visual states only present its lifecycle.
| State / event | Guard and observable contract |
|---|---|
| `ready` / invoke | Click, Enter, Space, and script use one eligible route; accepted work creates a request key. |
| `confirming` | Use only for irreversible, broad, or cascading work; name consequence, move focus in, and restore the invoker on cancel. |
| `submitting` | Create the key before dispatch; reject duplicates; expose native disabled/busy and a working label. |
| matching completion | Only the matching key may settle current work; stale results cannot clear busy, alter another target, or move focus. |
| success / failure | Record data before presentation; confirm locally and choose focus, or retain context with nearby error and retry/cancel. |
Test a real and a stal