Files
MattrixwvReactComponents/lib/component/input/checkbox/TertiaryCheckbox.tsx
2026-02-11 22:18:32 -05:00

31 lines
660 B
TypeScript

import type { CheckboxProps } from "$/types/InputTypes";
import clsx from "clsx";
import { forwardRef } from "react";
import MattrixwvCheckbox from "./MattrixwvCheckbox";
const TertiaryCheckbox = forwardRef<HTMLInputElement, CheckboxProps>(({
className,
showBox = true,
...props
}, ref) => {
return (
<MattrixwvCheckbox
className={clsx(
className,
{
"group-data-checked:bg-tertiary group-data-checked:stroke-white": showBox,
"group-data-checked:stroke-tertiary": !showBox
}
)}
showBox={showBox}
{...props}
ref={ref}
/>
);
});
TertiaryCheckbox.displayName = "TertiaryCheckbox";
export default TertiaryCheckbox;