v0.5.0
Minor Changes
-
280ec88: Add an
invalidprop: it adds the--invalidmodifier and setsaria-invalid. A directaria-invalidalso turns the modifier on. Styling moves from the attribute selector to the modifier.The toggle now tracks its own checked state (controlled
checkedwins, otherwisedefaultCheckedkept current throughonCheckedChange, which is still forwarded), so a--checkedmodifier on the root replaces thedata-stateselectors; the thumb follows the root modifier.Controlled
checkedis now the single source of truth: the internal state only updates whilecheckedis undefined, so a controlled value that later becomesundefinedfalls back to the last uncontrolled state rather than a stale pick.