Slide Toggles

Svelte Component

A sliding toggle element that can capture input from a user.

Examples

Usage

typescript
let valueChecked: boolean = false;
html
<SlideToggle bind:checked={valueChecked}>(label)</SlideToggle>

Size

Set size to sm, md, or lg.

html
<SlideToggle bind:checked={valueChecked} size="lg" />

Disabled

html
<SlideToggle bind:checked={valueChecked} disabled />