t-convex-nextjs-saas/src/components/ui/checkbox.tsx
nxtkofi d41d4687ee feat(legal): add GDPR-compliant cookie consent banner
Add CookieBanner component with useCookieConsent hook, translations in EN/PL, and integration into root layout

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
2026-05-02 16:02:13 +02:00

30 lines
709 B
TypeScript

import { cn } from "@/lib/utils";
interface CheckboxProps {
checked?: boolean;
disabled?: boolean;
onCheckedChange?: (checked: boolean) => void;
id?: string;
}
export function Checkbox({
checked,
disabled,
onCheckedChange,
id,
}: CheckboxProps) {
return (
<input
id={id}
type="checkbox"
checked={checked}
disabled={disabled}
onChange={(e) => onCheckedChange?.(e.target.checked)}
className={cn(
"h-4 w-4 shrink-0 cursor-pointer rounded-sm border border-primary",
"accent-primary focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring",
"disabled:cursor-not-allowed disabled:opacity-50"
)}
/>
);
}