From the #543 WS4 audit — a cross-family sweep item:
- ButtonRoot.vue:210-226:
as='div' renders role=button + tabindex but no Enter/Space onKeydown.
- ToggleRoot.vue:149-154: handles Space only; Enter relies on native button semantics; non-native
as also never gets role=button (:173).
- PaginationItem.vue:112-122: same native-button reliance.
- Atom.vue:101-108:
as="button" doesn't default type="button" — a bare polymorphic button inside a form submits it. ~4 LOC but a behavior change; decide intentionality.
Fix pattern: when as is not a native button, add role=button (where missing), and an onKeydown handler mapping Enter/Space to the click path. Sibling components (CollapsibleActivator.vue:84-104, ExpansionPanelActivator.vue:89-110) already implement exactly this fallback — mirror them.
From the #543 WS4 audit — a cross-family sweep item:
as='div'renders role=button + tabindex but no Enter/Space onKeydown.asalso never gets role=button (:173).as="button"doesn't defaulttype="button"— a bare polymorphic button inside a form submits it. ~4 LOC but a behavior change; decide intentionality.Fix pattern: when
asis not a native button, add role=button (where missing), and an onKeydown handler mapping Enter/Space to the click path. Sibling components (CollapsibleActivator.vue:84-104, ExpansionPanelActivator.vue:89-110) already implement exactly this fallback — mirror them.