Form control to toggle the state of a single option. Generates a styled checkbox input element.
- All Checkbox main features
- Custom icon
- Custom z-depths
- Disable shadow
- RTL (right-to-left) support
Identical to Checkbox. See Checkbox usage instructions and replace "Checkbox" with "Switch".
See: Checkbox
Parameter | Required | Type | Default | Description |
---|---|---|---|---|
raised | optional | Boolean | true | Shows a shadow below the thumb; when the Switch state is on , the depth is incremented by 1 |
wash | optional | Boolean | true on touch devices | Set to false to always hide the wash (radial feedback); note that a (hidden) wash is still drawn to create a large tap target |
shadowDepthOff | optional | Number 0-5 | 1 | The shadow depth for the thumb in off state |
shadowDepthOn | optional | Number 0-5 | 2 | The shadow depth for the thumb in on state |