Component states

Every interactive class hook in each state the themes style, in one grid, under the theme you chose. Use the theme picker in the header to compare themes.

How to read this page

  • Rest, pressed, current, checked, invalid and disabled are set by attributes, so they are shown side by side.
  • Hover and keyboard focus cannot be set by an attribute, so the controls are live: move the pointer over a control, then Tab to it. An effect shown on hover must be shown on focus too (hover and focus parity, WCAG 1.4.13); compare the two as you go.
  • Invalid uses aria-invalid="true", and the native :user-invalid state appears after you type in the last field and leave it.

The grid

HookRestPressed, current or checkedInvalidDisabled
button——
toggle-button—
Link in textRead the guidanceRead the guidance——
action-linkStart now———
text-input—
checkbox-input
radio-input
select—
switch-button—
Disclosure (summary)
Closed

Content.

Open

Content.

——

Related