Dashboard UI Kit

Apps PreviewDownload Design Package

    Table of contents

  1. Basic Usage
  2. Prop Table

Toggle

import { Toggle } from '@duik/it'
import Toggle from '@duik/toggle'

Toggles work the same way as checkboxes, e.g. you can group them with "name" property in your forms.

Basic Usage

<Toggle defaultChecked />
ReactHTML Snippet
<Toggle label="Check me" />
ReactHTML Snippet
<Toggle description="With Description" label="Toggle" />
ReactHTML Snippet
<Toggle description="With Description" disabled label="Toggle" />
ReactHTML Snippet

Prop table

className

Required: false

type: string
className, e.g. "my-custom-styling"
label

Required: false

type: React.ReactNode
Label text or node
description

Required: false

type: React.ReactNode
Label text or node
...rest

Required: false

type: any
Other properties are passed to the input element