fndn/ui

Components

Switch

Turns a setting on or off, taking effect at once.

Details

An on/off toggle that takes effect immediately. The track fills with ink when on and the thumb travels across; pressing squeezes the thumb. It is a native button with role=switch, so state lives in aria-checked and no engine is needed. An optional label wrapper makes the text part of the hit area.