import { t as e } from "../chunks/ui.module-BisoTevy.js";
import { useId as t, useState as n } from "react";
import { cn as r } from "@ryuzaki13/react-foundation-lib/utils";
import { ChevronDownIcon as i, ChevronUpIcon as a } from "lucide-react";
import { jsx as o, jsxs as s } from "react/jsx-runtime";
var c = {
	disclosure: "O-da-N",
	disclosureButton: "_9yjaDf",
	disclosureGroup: "KAIPfW"
};
//#endregion
//#region src/disclosure/Disclosure.tsx
function l({ label: l, defaultOpen: u, children: d }) {
	let [f, p] = n(u === !0), m = t(), h = t();
	return /* @__PURE__ */ s("div", {
		className: r(e.uiElement, e.uiPanel, c.disclosure),
		children: [/* @__PURE__ */ s("button", {
			id: h,
			type: "button",
			"aria-expanded": f,
			"aria-controls": m,
			className: r(c.disclosureButton, "fontBold radiusSm paddingSm gapSm"),
			"data-ui": "disclosure-toggle",
			"data-action": f ? "collapse-disclosure" : "expand-disclosure",
			onClick: () => p((e) => !e),
			children: [o(f ? a : i, {}), l]
		}), f && /* @__PURE__ */ o("div", {
			id: m,
			role: "region",
			"aria-labelledby": h,
			children: /* @__PURE__ */ o("div", {
				className: "paddingMd",
				children: d
			})
		})]
	});
}
//#endregion
//#region src/disclosure/DisclosureGroup.tsx
function u({ className: e, children: t }) {
	return /* @__PURE__ */ o("div", {
		className: r(c.disclosureGroup, e),
		children: t
	});
}
//#endregion
export { l as Disclosure, u as DisclosureGroup };

//# sourceMappingURL=index.js.map