If true
, the component appears selected.
A control element. For instance, it can be be a Radio
, a Switch
or a Checkbox
.
If true
, the control will be disabled.
Pass a ref to the input
element.
The text to be used in an enclosing label element.
The position of the label.
Callback fired when the state is changed.
The value of the component.
Drop in replacement of the Radio
, Switch
and Checkbox
component.
Use this component if you want to display an extra label.
Demos:
API:
Drop in replacement of the Radio
, Switch
and Checkbox
component.
Use this component if you want to display an extra label.
Name | Type | Description |
---|---|---|
checked | bool | If |
classes | object | Override or extend the styles applied to the component. See CSS API below for more details. |
className | string | |
control (required) | element | A control element. For instance, it can be be a |
disabled | bool | If |
inputRef | custom | Pass a ref to the |
label | node | The text to be used in an enclosing label element. |
labelPlacement | 'bottom' | 'end' | 'start' | 'top' | The position of the label. |
name | string | |
onChange | function | The event source of the callback.
You can pull out the new checked state by accessing |
value | any | The value of the component. |