import { cn } from "./index3.js";
import { Check, Minus } from "lucide-react";
import * as React from "react";
import { jsx } from "react/jsx-runtime";
import { Checkbox } from "@base-ui/react/checkbox";
//#region src/components/ui/checkbox.tsx
var Checkbox$1 = React.forwardRef(({ className, size = "sm", ...props }, ref) => {
	const sizeClasses = {
		sm: "size-4 rounded-[4px]",
		md: "size-5 rounded-[5px]",
		lg: "size-6 rounded-[6px]"
	};
	const iconClasses = {
		sm: "size-3",
		md: "size-3.5",
		lg: "size-4"
	};
	return /* @__PURE__ */ jsx(Checkbox.Root, {
		ref,
		"data-slot": "checkbox",
		"data-size": size,
		className: cn("relative flex shrink-0 items-center justify-center border shadow-xs bg-background transition-[border-color,background-color,color,box-shadow] duration-200 ease-out motion-reduce:transition-none", "border-border dark:border-border", "hover:border-primary hover:bg-primary/10 dark:hover:border-primary", "data-checked:border-primary data-checked:bg-primary data-checked:text-primary-foreground", "data-checked:hover:border-primary-alt data-checked:hover:bg-primary/90", "data-indeterminate:border-primary data-indeterminate:bg-primary data-indeterminate:text-primary-foreground", "data-indeterminate:hover:border-primary-alt data-indeterminate:hover:bg-primary/90", "focus-visible:outline-none focus-visible:ring-4 focus-visible:ring-bg-secondary focus-visible:shadow-[0_0_0_2px_var(--card),0_0_0_4px_var(--border)]", "dark:focus-visible:ring-bg-tertiary dark:focus-visible:shadow-[0_0_0_2px_var(--card),0_0_0_4px_var(--border)]", "before:content-[\"\"] before:absolute before:-inset-[4px] before:rounded-[inherit]", "disabled:cursor-not-allowed disabled:opacity-50", sizeClasses[size], className),
		...props,
		children: /* @__PURE__ */ jsx(Checkbox.Indicator, {
			"data-slot": "checkbox-indicator",
			className: "flex items-center justify-center text-current transition-transform duration-150 ease-out scale-100 motion-reduce:transition-none",
			children: props.indeterminate ? /* @__PURE__ */ jsx(Minus, {
				className: iconClasses[size],
				strokeWidth: 3
			}) : /* @__PURE__ */ jsx(Check, {
				className: iconClasses[size],
				strokeWidth: 3
			})
		})
	});
});
Checkbox$1.displayName = "Checkbox";
//#endregion
export { Checkbox$1 as Checkbox };

//# sourceMappingURL=index424.js.map