InvokeAI/invokeai/frontend/web/src/common/components/IAICheckbox.tsx

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

18 lines
394 B
TypeScript
Raw Normal View History

2022-10-27 04:24:00 +00:00
import { Checkbox, CheckboxProps } from '@chakra-ui/react';
import { memo, ReactNode } from 'react';
2022-10-27 04:24:00 +00:00
type IAICheckboxProps = CheckboxProps & {
2022-12-24 20:28:59 +00:00
label: string | ReactNode;
2022-10-27 04:24:00 +00:00
};
const IAICheckbox = (props: IAICheckboxProps) => {
2023-03-06 09:02:40 +00:00
const { label, ...rest } = props;
2022-10-27 04:24:00 +00:00
return (
2023-03-06 09:02:40 +00:00
<Checkbox colorScheme="accent" {...rest}>
2022-10-27 04:24:00 +00:00
{label}
</Checkbox>
);
};
export default memo(IAICheckbox);