Checkbox Group View Source

A container which renders a collection of checkboxes

If you're looking to use an individual checkbox, check out the Checkbox component.

Usage

...
import { CheckboxGroup } from 'react-native-material-design';

render() {
    return (
        <CheckboxGroup
            onSelect={(values) => { console.log(`${values} are currently selected`)}}
            checked={[1, 3]}
            items={[{
                value: 1, label: 'Checkbox 1'
            }, {
                value: 2, label: 'Checkbox 2'
            }, {
                value: 3, label: 'Checkbox 3 Disabled', disabled: true
            }]}
        />
    );
}
...

Props

Prop Type Description Required Default
theme THEME_NAME false light
primary PRIMARY_COLORS false PRIMARY
onSelect func Called when a checkbox item is selected. An array of currently selected items is returned false
checked array An array of item values which are checked on component mount false
items
value
label
disabled
array
string, number
string
bool
An array of checkbox objects
The value of the checkbox returned in the onSelect array
The supporting text of the checkbox
Whether the checkbox is rendered as disabled. Will not respond to touches
false