Import
Basic Usage
Props
If
true, the component is checked.The default checked state. Use when the component is not controlled.
color
'primary' | 'secondary' | 'error' | 'info' | 'success' | 'warning' | 'default'
default:"'primary'"
The color of the component. Supports both default and custom theme colors.
The size of the component.
small is equivalent to the dense checkbox styling.If
true, the component is disabled.If
true, the component appears indeterminate. This does not set the native input element to indeterminate due to inconsistent behavior across browsers. However, we set a data-indeterminate attribute on the input.If
true, the ripple effect is disabled.The icon to display when the component is checked. Defaults to
<CheckBoxIcon />.The icon to display when the component is unchecked. Defaults to
<CheckBoxOutlineBlankIcon />.The icon to display when the component is indeterminate. Defaults to
<IndeterminateCheckBoxIcon />.Callback fired when the state is changed. You can pull out the new checked state by accessing
event.target.checked (boolean).If
true, the input element is required.The value of the component. The DOM API casts this to a string. The browser uses “on” as the default value.
The system prop that allows defining system overrides as well as additional CSS styles.
API Reference
- Checkbox API
- Inherits ButtonBase API