import { t as e } from "../../chunks/clsx.js";
import { useId as t } from "react";
import { Icon as n } from "@clubmed/trident-icons";
import { jsx as r, jsxs as i } from "react/jsx-runtime";
//#region lib/ui/forms/Filter.tsx
function a(a) {
	let o = t(), { id: s = o, name: c = s, className: l, dataTestId: u, disabled: d = !1, "data-testid": f, tabIndex: p = 0, hasDropdown: m, onChange: h, value: g, children: _, ...v } = a;
	return /* @__PURE__ */ r("div", {
		className: e(l, "relative"),
		children: /* @__PURE__ */ i("label", {
			"data-testid": `filter-container-${s}`,
			className: "relative",
			children: [/* @__PURE__ */ r("input", {
				...v,
				id: s,
				name: c,
				"data-testid": f ?? u,
				type: "checkbox",
				tabIndex: p,
				"data-name": "Filter",
				value: typeof g == "boolean" ? String(g) : g,
				disabled: d,
				onChange: (e) => {
					h?.(e.nativeEvent, e.target.checked);
				}
			}), /* @__PURE__ */ i("span", { children: [
				/* @__PURE__ */ r("span", {
					className: "font-semibold",
					children: _
				}),
				/* @__PURE__ */ r(n, {
					className: "check",
					width: null,
					name: "CheckDefault",
					color: "black"
				}),
				m && /* @__PURE__ */ r(n, {
					name: "ArrowDefaultDown",
					className: "ml-8",
					width: "24px",
					color: "black"
				})
			] })]
		})
	});
}
//#endregion
export { a as Filter };

//# sourceMappingURL=Filter.js.map