React
Is new design vision part implemented using new tokens?
React
Is new design vision part implemented using new tokens?
import { CheckboxGroup } from '@optimus-web/core';
const MyCheckboxGroupComponent = () => {
const [groupValues, setGroupValues] = useState(values);
const handleChange = (_event: React.SyntheticEvent<HTMLElement>, newValues: InputValue[]) => {
setGroupValues(newValues);
};
return <CheckboxGroup values={groupValues} onChange={handleChange} label='Fruits' options={[
{ name: 'fruit', value: 'apple', label: 'Apple' },
{ name: 'fruit', value: 'strawberry', label: 'Strawberry' },
{ name: 'fruit', value: 'lemon', label: 'Lemon' },
]}/>;
};
import { Checkbox } from '@optimus-web/core';
const MyCheckboxComponent = () => {
const [checked, setChecked] = useState<>(false);
return <Checkbox checked={false} value="label" name="checkbox" onChange={(_, true) => setChecked(true)}/>
}