import { t as e } from "../chunks/ui.module-BisoTevy.js";
import { n as t } from "../chunks/uiClasses-BNjBunnY.js";
import { t as n } from "../chunks/CheckBox.module-C5SjPwSj.js";
import { useId as r } from "react";
import { cn as i } from "@ryuzaki13/react-foundation-lib/utils";
import { CircleIcon as a } from "lucide-react";
import { jsx as o, jsxs as s } from "react/jsx-runtime";
var c = { radioInput: "gu8UMB" }, l = ({ label: l, description: u, placeholder: d, disabled: f, size: p, className: m, onChange: h, value: g, id: _, tone: v = "neutral", ...y }) => {
	let b = r(), x = _ ?? b, S = u ? `${x}-description` : void 0, C = l ?? d, w = g ?? !1;
	return /* @__PURE__ */ s("div", {
		className: i(e.uiElement, p && e.uiSizable, p && e[p], f && e.disabled, m),
		children: [/* @__PURE__ */ s("div", {
			className: n.row,
			children: [/* @__PURE__ */ s("div", {
				className: i(n.wrapper, t(v)),
				children: [/* @__PURE__ */ o("input", {
					...y,
					id: x,
					type: "checkbox",
					role: "radio",
					checked: w,
					disabled: f,
					"aria-disabled": f,
					"aria-checked": w,
					"aria-describedby": S,
					className: i(e.uiSelectionControl, n.input, c.radioInput),
					onChange: () => h?.(!w)
				}), /* @__PURE__ */ o("div", {
					className: i(e.uiSelectionIcon, n.icon),
					"aria-hidden": "true",
					children: /* @__PURE__ */ o(a, {})
				})]
			}), C && /* @__PURE__ */ o("label", {
				htmlFor: x,
				className: e.uiLabel,
				children: C
			})]
		}), u && /* @__PURE__ */ o("p", {
			id: S,
			className: e.uiDescription,
			children: u
		})]
	});
};
//#endregion
export { l as RadioButton };

//# sourceMappingURL=index.js.map