InvokeAI/invokeai/frontend/web/src/common/components/IAISimpleCheckbox.tsx
2023-06-04 22:34:58 +10:00

20 lines
490 B
TypeScript

import { Checkbox, CheckboxProps, Text } from '@chakra-ui/react';
import { memo, ReactElement } from 'react';
type IAISimpleCheckboxProps = CheckboxProps & {
label: string | ReactElement;
};
const IAISimpleCheckbox = (props: IAISimpleCheckboxProps) => {
const { label, ...rest } = props;
return (
<Checkbox colorScheme="accent" {...rest}>
<Text color="base.200" fontSize="md">
{label}
</Text>
</Checkbox>
);
};
export default memo(IAISimpleCheckbox);