React
Peer dependencies, not bundled
Section titled “Peer dependencies, not bundled”react and react-dom are peers and are left external in the build. Bundling React would give you two copies and break hooks, so the package resolves to whichever React your app already has — 19 or newer.
Controlled and uncontrolled
Section titled “Controlled and uncontrolled”Two components keep their own state unless you drive them:
Switch— passonto control it; leave it out and it keeps its own, seeded fromdefaultOn.onChange(on, event)reports the value it is moving to.Accordion— passstateto control it; leave it out and it keeps its own, seeded fromdefaultState.onToggle(state, event)likewise.
When you control one, the component does not move on its own — the value you pass wins, and acting on the callback is your job.
Accessible names
Section titled “Accessible names”Some components cannot name themselves, because the design draws no label layer:
Switchneedsaria-labeloraria-labelledbyfrom you.Fieldrenders the label and you supply the control;controlIdis what ties them together.- An icon-only
Buttontakes its name fromlabel.
Each component’s Usage tab lists its accessibility facts with a link to the line that makes each one true.
Server rendering
Section titled “Server rendering”Every component renders to static markup with react-dom/server; the test suite asserts it for both the ESM and the CJS build.