import { t as e } from "./utils-B7XIe3qq.js";
import { t } from "./dist-CTlQcJNK.js";
import { a as n, o as r, t as i } from "./dist-koa_pEtu.js";
import { t as a } from "./dist-CpMqmV-i.js";
import { t as o } from "./dist-C0wG5dwG.js";
import { _ as s, a as c, c as l, d as u, f as d, g as f, h as p, i as m, l as h, n as g, o as _, p as v, r as y, s as b, t as x, u as S } from "./dist-Dq1IoZXt.js";
import * as C from "react";
import { jsx as w } from "react/jsx-runtime";
//#region node_modules/@radix-ui/react-dropdown-menu/dist/index.mjs
var T = "DropdownMenu", [E, ee] = n(T, [s]), D = s(), [O, k] = E(T), A = (e) => {
	let { __scopeDropdownMenu: t, children: n, dir: r, open: i, defaultOpen: s, onOpenChange: c, modal: l = !0 } = e, u = D(t), f = C.useRef(null), [p, m] = o({
		prop: i,
		defaultProp: s ?? !1,
		onChange: c,
		caller: T
	});
	return /* @__PURE__ */ w(O, {
		scope: t,
		triggerId: a(),
		triggerRef: f,
		contentId: a(),
		open: p,
		onOpenChange: m,
		onOpenToggle: C.useCallback(() => m((e) => !e), [m]),
		modal: l,
		children: /* @__PURE__ */ w(d, {
			...u,
			open: p,
			onOpenChange: m,
			dir: r,
			modal: l,
			children: n
		})
	});
};
A.displayName = T;
var j = "DropdownMenuTrigger", M = C.forwardRef((e, n) => {
	let { __scopeDropdownMenu: a, disabled: o = !1, ...s } = e, c = k(j, a);
	return /* @__PURE__ */ w(x, {
		asChild: !0,
		...D(a),
		children: /* @__PURE__ */ w(i.button, {
			type: "button",
			id: c.triggerId,
			"aria-haspopup": "menu",
			"aria-expanded": c.open,
			"aria-controls": c.open ? c.contentId : void 0,
			"data-state": c.open ? "open" : "closed",
			"data-disabled": o ? "" : void 0,
			disabled: o,
			...s,
			ref: t(n, c.triggerRef),
			onPointerDown: r(e.onPointerDown, (e) => {
				!o && e.button === 0 && e.ctrlKey === !1 && (c.onOpenToggle(), c.open || e.preventDefault());
			}),
			onKeyDown: r(e.onKeyDown, (e) => {
				o || (["Enter", " "].includes(e.key) && c.onOpenToggle(), e.key === "ArrowDown" && c.onOpenChange(!0), [
					"Enter",
					" ",
					"ArrowDown"
				].includes(e.key) && e.preventDefault());
			})
		})
	});
});
M.displayName = j;
var N = "DropdownMenuPortal", P = (e) => {
	let { __scopeDropdownMenu: t, ...n } = e;
	return /* @__PURE__ */ w(h, {
		...D(t),
		...n
	});
};
P.displayName = N;
var F = "DropdownMenuContent", I = C.forwardRef((e, t) => {
	let { __scopeDropdownMenu: n, ...i } = e, a = k(F, n), o = D(n), s = C.useRef(!1);
	return /* @__PURE__ */ w(m, {
		id: a.contentId,
		"aria-labelledby": a.triggerId,
		...o,
		...i,
		ref: t,
		onCloseAutoFocus: r(e.onCloseAutoFocus, (e) => {
			s.current || a.triggerRef.current?.focus(), s.current = !1, e.preventDefault();
		}),
		onInteractOutside: r(e.onInteractOutside, (e) => {
			let t = e.detail.originalEvent, n = t.button === 0 && t.ctrlKey === !0, r = t.button === 2 || n;
			(!a.modal || r) && (s.current = !0);
		}),
		style: {
			...e.style,
			"--radix-dropdown-menu-content-transform-origin": "var(--radix-popper-transform-origin)",
			"--radix-dropdown-menu-content-available-width": "var(--radix-popper-available-width)",
			"--radix-dropdown-menu-content-available-height": "var(--radix-popper-available-height)",
			"--radix-dropdown-menu-trigger-width": "var(--radix-popper-anchor-width)",
			"--radix-dropdown-menu-trigger-height": "var(--radix-popper-anchor-height)"
		}
	});
});
I.displayName = F;
var L = "DropdownMenuGroup", R = C.forwardRef((e, t) => {
	let { __scopeDropdownMenu: n, ...r } = e;
	return /* @__PURE__ */ w(c, {
		...D(n),
		...r,
		ref: t
	});
});
R.displayName = L;
var z = "DropdownMenuLabel", B = C.forwardRef((e, t) => {
	let { __scopeDropdownMenu: n, ...r } = e;
	return /* @__PURE__ */ w(l, {
		...D(n),
		...r,
		ref: t
	});
});
B.displayName = z;
var V = "DropdownMenuItem", H = C.forwardRef((e, t) => {
	let { __scopeDropdownMenu: n, ...r } = e;
	return /* @__PURE__ */ w(_, {
		...D(n),
		...r,
		ref: t
	});
});
H.displayName = V;
var U = "DropdownMenuCheckboxItem", W = C.forwardRef((e, t) => {
	let { __scopeDropdownMenu: n, ...r } = e;
	return /* @__PURE__ */ w(y, {
		...D(n),
		...r,
		ref: t
	});
});
W.displayName = U;
var G = "DropdownMenuRadioGroup", K = C.forwardRef((e, t) => {
	let { __scopeDropdownMenu: n, ...r } = e;
	return /* @__PURE__ */ w(S, {
		...D(n),
		...r,
		ref: t
	});
});
K.displayName = G;
var q = "DropdownMenuRadioItem", te = C.forwardRef((e, t) => {
	let { __scopeDropdownMenu: n, ...r } = e;
	return /* @__PURE__ */ w(u, {
		...D(n),
		...r,
		ref: t
	});
});
te.displayName = q;
var J = "DropdownMenuItemIndicator", Y = C.forwardRef((e, t) => {
	let { __scopeDropdownMenu: n, ...r } = e;
	return /* @__PURE__ */ w(b, {
		...D(n),
		...r,
		ref: t
	});
});
Y.displayName = J;
var X = "DropdownMenuSeparator", Z = C.forwardRef((e, t) => {
	let { __scopeDropdownMenu: n, ...r } = e;
	return /* @__PURE__ */ w(v, {
		...D(n),
		...r,
		ref: t
	});
});
Z.displayName = X;
var Q = "DropdownMenuArrow", $ = C.forwardRef((e, t) => {
	let { __scopeDropdownMenu: n, ...r } = e;
	return /* @__PURE__ */ w(g, {
		...D(n),
		...r,
		ref: t
	});
});
$.displayName = Q;
var ne = "DropdownMenuSubTrigger", re = C.forwardRef((e, t) => {
	let { __scopeDropdownMenu: n, ...r } = e;
	return /* @__PURE__ */ w(f, {
		...D(n),
		...r,
		ref: t
	});
});
re.displayName = ne;
var ie = "DropdownMenuSubContent", ae = C.forwardRef((e, t) => {
	let { __scopeDropdownMenu: n, ...r } = e;
	return /* @__PURE__ */ w(p, {
		...D(n),
		...r,
		ref: t,
		style: {
			...e.style,
			"--radix-dropdown-menu-content-transform-origin": "var(--radix-popper-transform-origin)",
			"--radix-dropdown-menu-content-available-width": "var(--radix-popper-available-width)",
			"--radix-dropdown-menu-content-available-height": "var(--radix-popper-available-height)",
			"--radix-dropdown-menu-trigger-width": "var(--radix-popper-anchor-width)",
			"--radix-dropdown-menu-trigger-height": "var(--radix-popper-anchor-height)"
		}
	});
});
ae.displayName = ie;
var oe = A, se = M, ce = P, le = I, ue = B, de = H, fe = Z;
//#endregion
//#region src/react/primitives/dropdown-menu.tsx
function pe({ ...e }) {
	return /* @__PURE__ */ w(oe, { ...e });
}
function me({ ...e }) {
	return /* @__PURE__ */ w(se, { ...e });
}
function he({ ...e }) {
	return /* @__PURE__ */ w(ce, { ...e });
}
function ge({ className: t, sideOffset: n = 8, ...r }) {
	return /* @__PURE__ */ w(he, { children: /* @__PURE__ */ w(le, {
		sideOffset: n,
		className: e("data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 z-50 min-w-[12rem] overflow-hidden rounded-xl border p-1 shadow-xl", "border-border-glass bg-popover backdrop-blur-xl", t),
		...r
	}) });
}
function _e({ className: t, ...n }) {
	return /* @__PURE__ */ w(de, {
		className: e("relative flex cursor-pointer items-center rounded-lg px-3 py-2 text-sm transition-colors outline-none select-none", "text-foreground hover:bg-accent focus:bg-accent", "data-[disabled]:pointer-events-none data-[disabled]:opacity-50", t),
		...n
	});
}
function ve({ className: t, ...n }) {
	return /* @__PURE__ */ w(ue, {
		className: e("text-foreground px-3 py-2 text-sm font-semibold", t),
		...n
	});
}
function ye({ className: t, ...n }) {
	return /* @__PURE__ */ w(fe, {
		className: e("bg-border my-1 h-px", t),
		...n
	});
}
//#endregion
export { ye as a, ve as i, ge as n, me as o, _e as r, pe as t };

//# sourceMappingURL=dropdown-menu-ChWWguC6.js.map