Checkbox
Checkbox allows users to select one or more options.
Usage
import { useState } from 'react';import { Checkbox } from '@masumdev/rn-ui';
export function CheckboxExample() { const [checked, setChecked] = useState(false);
return ( <Checkbox label="Accept terms and conditions" checked={checked} onCheckedChange={setChecked} tone="primary" /> );}Props API
| Prop | Type | Default | Description |
|---|---|---|---|
checked | boolean | — | Checked boolean state. |
onCheckedChange | (checked: boolean) => void | — | Callback when toggle state changes. |
label | string | — | Adjacent label text. |
tone | 'primary' | 'secondary' | 'accent' | 'success' | 'primary' | Color tone when checked. |