Introduction to the toggle control
Toggles are used to allow users to select a value between on and off, or true and false. To learn about its properties, click here.
Screen reader
- Screen reader announces the value of a toggle.
- To announce the changes, use a live label.
Keyboard tabbing
- Set the Tabindex property to 0.
- Set the FocusBorderThickness to a number greater than 0.
Color/contrast
- Set the FocusBorderColor with a contrast ratio of 3:1 with the background color.
- Set the Color property with a minimum luminosity contrast ratio of 4.5:1 with the background color. There are several tools available to analyze contrast ratios. Click here for one such tool.