import { j as o } from "./jsx-runtime-Sp0orL4X.js";
import * as k from "@radix-ui/react-switch";
import * as r from "react";
import * as g from "@radix-ui/react-accordion";
import { ChevronDownIcon as Y, Cross2Icon as M, CaretSortIcon as $, CheckIcon as D, ChevronRightIcon as z, DotFilledIcon as P, MagnifyingGlassIcon as W } from "@radix-ui/react-icons";
import { cva as j } from "class-variance-authority";
import * as m from "@radix-ui/react-alert-dialog";
import { Slot as Z } from "@radix-ui/react-slot";
import * as _ from "@radix-ui/react-label";
import * as x from "@radix-ui/react-scroll-area";
import * as b from "@radix-ui/react-tabs";
import * as y from "@radix-ui/react-tooltip";
import * as h from "@radix-ui/react-popover";
import * as C from "@radix-ui/react-hover-card";
import * as c from "@radix-ui/react-select";
import * as n from "@radix-ui/react-dropdown-menu";
import * as O from "@radix-ui/react-separator";
import * as u from "@radix-ui/react-toast";
import { Command as p } from "cmdk";
import * as f from "@radix-ui/react-dialog";
import * as i from "@radix-ui/react-context-menu";
import { clsx as ee } from "clsx";
import { twMerge as te } from "tailwind-merge";
const s = (...e) => te(ee(e)), ae = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(
  k.Root,
  {
    className: s(
      "peer inline-flex h-[24px] w-[44px] shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-slate-400 focus-visible:ring-offset-2 focus-visible:ring-offset-white disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-slate-900 data-[state=unchecked]:bg-slate-200 dark:focus-visible:ring-slate-800 dark:focus-visible:ring-offset-slate-950 dark:data-[state=checked]:bg-slate-50 dark:data-[state=unchecked]:bg-slate-800",
      e
    ),
    ...t,
    ref: a,
    children: /* @__PURE__ */ o.jsx(
      k.Thumb,
      {
        className: s(
          "pointer-events-none block h-5 w-5 rounded-full bg-white shadow-lg ring-0 transition-transform data-[state=checked]:translate-x-5 data-[state=unchecked]:translate-x-0 dark:bg-slate-950"
        )
      }
    )
  }
));
ae.displayName = k.Root.displayName;
const I = j(
  "inline-flex items-center justify-center rounded-md text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50",
  {
    variants: {
      variant: {
        default: "bg-primary text-primary-foreground shadow hover:bg-primary/90",
        destructive: "bg-destructive text-destructive-foreground shadow-sm hover:bg-destructive/90",
        outline: "border border-input bg-background shadow-sm hover:bg-accent hover:text-accent-foreground",
        secondary: "bg-secondary text-secondary-foreground shadow-sm hover:bg-secondary/80",
        ghost: "hover:bg-accent hover:text-accent-foreground",
        link: "text-primary underline-offset-4 hover:underline"
      },
      size: {
        default: "h-9 px-4 py-2",
        sm: "h-8 rounded-md px-3 text-xs",
        lg: "h-10 rounded-md px-8",
        icon: "h-9 w-9"
      }
    },
    defaultVariants: {
      variant: "default",
      size: "default"
    }
  }
), oe = r.forwardRef(
  ({ className: e, variant: t, size: a, asChild: d = !1, ...l }, R) => {
    const X = d ? Z : "button";
    return /* @__PURE__ */ o.jsx(X, { className: s(I({ variant: t, size: a, className: e })), ref: R, ...l });
  }
);
oe.displayName = "Button";
const It = g.Root, se = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(g.Item, { ref: a, className: s("border-b", e), ...t }));
se.displayName = "AccordionItem";
const re = r.forwardRef(({ className: e, children: t, ...a }, d) => /* @__PURE__ */ o.jsx(g.Header, { className: "flex", children: /* @__PURE__ */ o.jsxs(
  g.Trigger,
  {
    ref: d,
    className: s(
      "flex flex-1 items-center justify-between py-4 text-sm font-medium transition-all hover:underline [&[data-state=open]>svg]:rotate-180",
      e
    ),
    ...a,
    children: [
      t,
      a.hideArrow ? null : /* @__PURE__ */ o.jsx(Y, { className: "h-4 w-4 shrink-0 text-muted-foreground transition-transform duration-200" })
    ]
  }
) }));
re.displayName = g.Trigger.displayName;
const de = r.forwardRef(({ className: e, children: t, ...a }, d) => /* @__PURE__ */ o.jsx(
  g.Content,
  {
    ref: d,
    className: s(
      "text-sm data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down",
      e
    ),
    ...a,
    children: /* @__PURE__ */ o.jsx("div", { className: "pb-4 pt-0", children: t })
  }
));
de.displayName = g.Content.displayName;
const ne = j(
  "inline-flex items-center rounded-md border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",
  {
    variants: {
      variant: {
        default: "border-transparent bg-primary text-primary-foreground shadow hover:bg-primary/80",
        secondary: "border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",
        destructive: "border-transparent bg-destructive text-destructive-foreground shadow hover:bg-destructive/80",
        outline: "text-foreground"
      }
    },
    defaultVariants: {
      variant: "default"
    }
  }
), At = ({ className: e, variant: t, ...a }) => /* @__PURE__ */ o.jsx("div", { className: s(ne({ variant: t }), e), ...a }), Mt = m.Root, zt = m.Trigger, L = ({ className: e, ...t }) => /* @__PURE__ */ o.jsx(m.Portal, { className: s(e), ...t });
L.displayName = m.Portal.displayName;
const E = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(
  m.Overlay,
  {
    className: s(
      "fixed inset-0 z-50 bg-background/80 backdrop-blur-sm data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",
      e
    ),
    ...t,
    ref: a
  }
));
E.displayName = m.Overlay.displayName;
const ie = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsxs(L, { children: [
  /* @__PURE__ */ o.jsx(E, {}),
  /* @__PURE__ */ o.jsx(
    m.Content,
    {
      ref: a,
      className: s(
        "fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 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 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg md:w-full",
        e
      ),
      ...t
    }
  )
] }));
ie.displayName = m.Content.displayName;
const le = ({ className: e, ...t }) => /* @__PURE__ */ o.jsx("div", { className: s("flex flex-col space-y-2 text-center sm:text-left", e), ...t });
le.displayName = "AlertDialogHeader";
const ce = ({ className: e, ...t }) => /* @__PURE__ */ o.jsx("div", { className: s("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2", e), ...t });
ce.displayName = "AlertDialogFooter";
const me = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(m.Title, { ref: a, className: s("text-lg font-semibold", e), ...t }));
me.displayName = m.Title.displayName;
const pe = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(m.Description, { ref: a, className: s("text-sm text-muted-foreground", e), ...t }));
pe.displayName = m.Description.displayName;
const fe = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(m.Action, { ref: a, className: s(I(), e), ...t }));
fe.displayName = m.Action.displayName;
const ue = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(
  m.Cancel,
  {
    ref: a,
    className: s(I({ variant: "outline" }), "mt-2 sm:mt-0", e),
    ...t
  }
));
ue.displayName = m.Cancel.displayName;
const xe = f.Root, Pt = f.Trigger, V = ({ className: e, ...t }) => /* @__PURE__ */ o.jsx(f.Portal, { className: s(e), ...t });
V.displayName = f.Portal.displayName;
const G = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(
  f.Overlay,
  {
    ref: a,
    className: s(
      "fixed inset-0 z-50 bg-background/80 backdrop-blur-sm data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",
      e
    ),
    ...t
  }
));
G.displayName = f.Overlay.displayName;
const H = r.forwardRef(({ className: e, children: t, ...a }, d) => /* @__PURE__ */ o.jsxs(V, { children: [
  /* @__PURE__ */ o.jsx(G, {}),
  /* @__PURE__ */ o.jsxs(
    f.Content,
    {
      ref: d,
      className: s(
        "fixed left-[50%] top-[50%] z-[999] grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 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 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg md:w-full",
        e
      ),
      ...a,
      children: [
        t,
        /* @__PURE__ */ o.jsxs(f.Close, { className: "absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground", children: [
          /* @__PURE__ */ o.jsx(M, { className: "h-4 w-4" }),
          /* @__PURE__ */ o.jsx("span", { className: "sr-only", children: "Close" })
        ] })
      ]
    }
  )
] }));
H.displayName = f.Content.displayName;
const ge = ({ className: e, ...t }) => /* @__PURE__ */ o.jsx("div", { className: s("flex flex-col space-y-1.5 text-center sm:text-left", e), ...t });
ge.displayName = "DialogHeader";
const be = ({ className: e, ...t }) => /* @__PURE__ */ o.jsx("div", { className: s("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2", e), ...t });
be.displayName = "DialogFooter";
const ye = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(
  f.Title,
  {
    ref: a,
    className: s("text-lg font-semibold leading-none tracking-tight", e),
    ...t
  }
));
ye.displayName = f.Title.displayName;
const Ne = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(f.Description, { ref: a, className: s("text-sm text-muted-foreground", e), ...t }));
Ne.displayName = f.Description.displayName;
const he = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx("div", { ref: a, className: s("rounded-xl border bg-card text-card-foreground shadow", e), ...t }));
he.displayName = "Card";
const we = r.forwardRef(
  ({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx("div", { ref: a, className: s("flex flex-col space-y-1.5 p-6", e), ...t })
);
we.displayName = "CardHeader";
const ve = r.forwardRef(
  ({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx("h3", { ref: a, className: s("font-semibold leading-none tracking-tight", e), ...t })
);
ve.displayName = "CardTitle";
const je = r.forwardRef(
  ({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx("p", { ref: a, className: s("text-sm text-muted-foreground", e), ...t })
);
je.displayName = "CardDescription";
const Ce = r.forwardRef(
  ({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx("div", { ref: a, className: s("p-6 pt-0", e), ...t })
);
Ce.displayName = "CardContent";
const Re = r.forwardRef(
  ({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx("div", { ref: a, className: s(" flex items-center p-6 pt-0", e), ...t })
);
Re.displayName = "CardFooter";
const Te = r.forwardRef(({ className: e, type: t, ...a }, d) => /* @__PURE__ */ o.jsx(
  "input",
  {
    type: t,
    className: s(
      "flex h-9 w-full rounded-md border border-border bg-background px-3 py-1 text-sm shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50",
      e
    ),
    ref: d,
    ...a,
    autoCapitalize: "off",
    autoCorrect: "off",
    spellCheck: "false"
  }
));
Te.displayName = "Input";
const Se = j("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"), ke = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(_.Root, { ref: a, className: s(Se(), e), ...t }));
ke.displayName = _.Root.displayName;
const De = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(
  "textarea",
  {
    className: s(
      "flex min-h-[60px] w-full rounded-md border border-input bg-transparent px-3 py-2 text-sm shadow-sm placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50",
      e
    ),
    ref: a,
    ...t,
    autoCapitalize: "off",
    autoCorrect: "off",
    spellCheck: "false"
  }
));
De.displayName = "Textarea";
const Ie = r.forwardRef(({ className: e, children: t, ...a }, d) => /* @__PURE__ */ o.jsxs(x.Root, { ref: d, className: s("relative overflow-hidden", e), ...a, children: [
  /* @__PURE__ */ o.jsx(x.Viewport, { className: "h-full w-full rounded-[inherit]", children: t }),
  /* @__PURE__ */ o.jsx(F, {}),
  /* @__PURE__ */ o.jsx(x.Corner, {})
] }));
Ie.displayName = x.Root.displayName;
const F = r.forwardRef(({ className: e, orientation: t = "vertical", ...a }, d) => /* @__PURE__ */ o.jsx(
  x.ScrollAreaScrollbar,
  {
    ref: d,
    orientation: t,
    className: s(
      "flex touch-none select-none transition-colors",
      t === "vertical" && "h-full w-2.5 border-l border-l-transparent p-[1px]",
      t === "horizontal" && "h-2.5 border-t border-t-transparent p-[1px]",
      e
    ),
    ...a,
    children: /* @__PURE__ */ o.jsx(x.ScrollAreaThumb, { className: "relative flex-1 rounded-full bg-border" })
  }
));
F.displayName = x.ScrollAreaScrollbar.displayName;
const _t = b.Root, Ae = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(
  b.List,
  {
    ref: a,
    className: s(
      "inline-flex h-9 items-center justify-center rounded-lg bg-muted p-1 text-muted-foreground",
      e
    ),
    ...t
  }
));
Ae.displayName = b.List.displayName;
const Me = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(
  b.Trigger,
  {
    ref: a,
    className: s(
      "inline-flex items-center justify-center whitespace-nowrap rounded-md px-3 py-1 text-sm font-medium ring-offset-background transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow",
      e
    ),
    ...t
  }
));
Me.displayName = b.Trigger.displayName;
const ze = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(
  b.Content,
  {
    ref: a,
    className: s(
      "mt-2 ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
      e
    ),
    ...t
  }
));
ze.displayName = b.Content.displayName;
const Ot = y.Portal, Lt = y.Provider, Et = y.Root, Vt = y.Trigger, Pe = r.forwardRef(({ className: e, sideOffset: t = 4, ...a }, d) => /* @__PURE__ */ o.jsx(
  y.Content,
  {
    ref: d,
    sideOffset: t,
    className: s(
      "z-50 overflow-hidden rounded-md bg-primary px-3 py-1.5 text-xs text-primary-foreground animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
      e
    ),
    ...a
  }
));
Pe.displayName = y.Content.displayName;
const Gt = h.Root, Ht = h.Trigger, _e = r.forwardRef(({ className: e, align: t = "center", sideOffset: a = 4, ...d }, l) => /* @__PURE__ */ o.jsx(h.Portal, { children: /* @__PURE__ */ o.jsx(
  h.Content,
  {
    ref: l,
    align: t,
    sideOffset: a,
    className: s(
      "z-50 w-72 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none 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 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
      e
    ),
    ...d
  }
) }));
_e.displayName = h.Content.displayName;
const Ft = C.Root, Bt = C.Trigger, Oe = r.forwardRef(({ className: e, align: t = "center", sideOffset: a = 4, ...d }, l) => /* @__PURE__ */ o.jsx(
  C.Content,
  {
    ref: l,
    align: t,
    sideOffset: a,
    className: s(
      "z-50 w-64 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none 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 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
      e
    ),
    ...d
  }
));
Oe.displayName = C.Content.displayName;
const Ut = c.Root, qt = c.Group, Jt = c.Value, Le = r.forwardRef(({ className: e, children: t, ...a }, d) => /* @__PURE__ */ o.jsxs(
  c.Trigger,
  {
    ref: d,
    className: s(
      "flex h-9 w-full items-center justify-between rounded-md border border-input bg-transparent px-3 py-2 text-sm shadow-sm ring-offset-background placeholder:text-muted-foreground focus:outline-none focus:ring-1 focus:ring-ring disabled:cursor-not-allowed disabled:opacity-50",
      e
    ),
    ...a,
    children: [
      t,
      /* @__PURE__ */ o.jsx(c.Icon, { asChild: !0, children: /* @__PURE__ */ o.jsx($, { className: "h-4 w-4 opacity-50" }) })
    ]
  }
));
Le.displayName = c.Trigger.displayName;
const Ee = r.forwardRef(({ className: e, children: t, position: a = "popper", ...d }, l) => /* @__PURE__ */ o.jsx(c.Portal, { children: /* @__PURE__ */ o.jsx(
  c.Content,
  {
    ref: l,
    className: s(
      "relative z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover text-popover-foreground shadow-md 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 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
      a === "popper" && "data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",
      e
    ),
    position: a,
    ...d,
    children: /* @__PURE__ */ o.jsx(
      c.Viewport,
      {
        className: s(
          "p-1",
          a === "popper" && "h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"
        ),
        children: t
      }
    )
  }
) }));
Ee.displayName = c.Content.displayName;
const Ve = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(c.Label, { ref: a, className: s("px-2 py-1.5 text-sm font-semibold", e), ...t }));
Ve.displayName = c.Label.displayName;
const Ge = r.forwardRef(({ className: e, children: t, ...a }, d) => /* @__PURE__ */ o.jsxs(
  c.Item,
  {
    ref: d,
    className: s(
      "relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-2 pr-8 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
      e
    ),
    ...a,
    children: [
      /* @__PURE__ */ o.jsx("span", { className: "absolute right-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ o.jsx(c.ItemIndicator, { children: /* @__PURE__ */ o.jsx(D, { className: "h-4 w-4" }) }) }),
      /* @__PURE__ */ o.jsx(c.ItemText, { children: t })
    ]
  }
));
Ge.displayName = c.Item.displayName;
const He = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(c.Separator, { ref: a, className: s("-mx-1 my-1 h-px bg-muted", e), ...t }));
He.displayName = c.Separator.displayName;
const Kt = n.Root, Qt = n.Trigger, Xt = n.Group, Yt = n.Portal, $t = n.Sub, Wt = n.RadioGroup, Fe = r.forwardRef(({ className: e, inset: t, children: a, ...d }, l) => /* @__PURE__ */ o.jsxs(
  n.SubTrigger,
  {
    ref: l,
    className: s(
      "flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent data-[state=open]:bg-accent",
      t && "pl-8",
      e
    ),
    ...d,
    children: [
      a,
      /* @__PURE__ */ o.jsx(z, { className: "ml-auto h-4 w-4" })
    ]
  }
));
Fe.displayName = n.SubTrigger.displayName;
const Be = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(
  n.SubContent,
  {
    ref: a,
    className: s(
      "z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-lg 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 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
      e
    ),
    ...t
  }
));
Be.displayName = n.SubContent.displayName;
const Ue = r.forwardRef(({ className: e, sideOffset: t = 4, ...a }, d) => /* @__PURE__ */ o.jsx(n.Portal, { children: /* @__PURE__ */ o.jsx(
  n.Content,
  {
    ref: d,
    sideOffset: t,
    className: s(
      "z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md",
      "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 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
      e
    ),
    ...a
  }
) }));
Ue.displayName = n.Content.displayName;
const qe = r.forwardRef(({ className: e, inset: t, ...a }, d) => /* @__PURE__ */ o.jsx(
  n.Item,
  {
    ref: d,
    className: s(
      "relative flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
      t && "pl-8",
      e
    ),
    ...a
  }
));
qe.displayName = n.Item.displayName;
const Je = r.forwardRef(({ className: e, children: t, checked: a, ...d }, l) => /* @__PURE__ */ o.jsxs(
  n.CheckboxItem,
  {
    ref: l,
    className: s(
      "relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
      e
    ),
    checked: a,
    ...d,
    children: [
      /* @__PURE__ */ o.jsx("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ o.jsx(n.ItemIndicator, { children: /* @__PURE__ */ o.jsx(D, { className: "h-4 w-4" }) }) }),
      t
    ]
  }
));
Je.displayName = n.CheckboxItem.displayName;
const Ke = r.forwardRef(({ className: e, children: t, ...a }, d) => /* @__PURE__ */ o.jsxs(
  n.RadioItem,
  {
    ref: d,
    className: s(
      "relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
      e
    ),
    ...a,
    children: [
      /* @__PURE__ */ o.jsx("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ o.jsx(n.ItemIndicator, { children: /* @__PURE__ */ o.jsx(P, { className: "h-4 w-4 fill-current" }) }) }),
      t
    ]
  }
));
Ke.displayName = n.RadioItem.displayName;
const Qe = r.forwardRef(({ className: e, inset: t, ...a }, d) => /* @__PURE__ */ o.jsx(
  n.Label,
  {
    ref: d,
    className: s("px-2 py-1.5 text-sm font-semibold", t && "pl-8", e),
    ...a
  }
));
Qe.displayName = n.Label.displayName;
const Xe = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(n.Separator, { ref: a, className: s("-mx-1 my-1 h-px bg-muted", e), ...t }));
Xe.displayName = n.Separator.displayName;
const Ye = ({ className: e, ...t }) => /* @__PURE__ */ o.jsx("span", { className: s("ml-auto text-xs tracking-widest opacity-60", e), ...t });
Ye.displayName = "DropdownMenuShortcut";
const $e = r.forwardRef(({ className: e, orientation: t = "horizontal", decorative: a = !0, ...d }, l) => /* @__PURE__ */ o.jsx(
  O.Root,
  {
    ref: l,
    decorative: a,
    orientation: t,
    className: s("shrink-0 bg-border", t === "horizontal" ? "h-[1px] w-full" : "h-full w-[1px]", e),
    ...d
  }
));
$e.displayName = O.Root.displayName;
const We = 1, Ze = 1e6;
let T = 0;
function et() {
  return T = (T + 1) % Number.MAX_VALUE, T.toString();
}
const S = /* @__PURE__ */ new Map(), A = (e) => {
  if (S.has(e))
    return;
  const t = setTimeout(() => {
    S.delete(e), N({
      type: "REMOVE_TOAST",
      toastId: e
    });
  }, Ze);
  S.set(e, t);
}, tt = (e, t) => {
  switch (t.type) {
    case "ADD_TOAST":
      return {
        ...e,
        toasts: [t.toast, ...e.toasts].slice(0, We)
      };
    case "UPDATE_TOAST":
      return {
        ...e,
        toasts: e.toasts.map((a) => a.id === t.toast.id ? { ...a, ...t.toast } : a)
      };
    case "DISMISS_TOAST": {
      const { toastId: a } = t;
      return a ? A(a) : e.toasts.forEach((d) => {
        A(d.id);
      }), {
        ...e,
        toasts: e.toasts.map(
          (d) => d.id === a || a === void 0 ? {
            ...d,
            open: !1
          } : d
        )
      };
    }
    case "REMOVE_TOAST":
      return t.toastId === void 0 ? {
        ...e,
        toasts: []
      } : {
        ...e,
        toasts: e.toasts.filter((a) => a.id !== t.toastId)
      };
  }
}, w = [];
let v = { toasts: [] };
function N(e) {
  v = tt(v, e), w.forEach((t) => {
    t(v);
  });
}
function at({ ...e }) {
  const t = et(), a = (l) => N({
    type: "UPDATE_TOAST",
    toast: { ...l, id: t }
  }), d = () => N({ type: "DISMISS_TOAST", toastId: t });
  return N({
    type: "ADD_TOAST",
    toast: {
      ...e,
      id: t,
      open: !0,
      onOpenChange: (l) => {
        l || d();
      }
    }
  }), {
    id: t,
    dismiss: d,
    update: a
  };
}
function ot() {
  const [e, t] = r.useState(v);
  return r.useEffect(() => (w.push(t), () => {
    const a = w.indexOf(t);
    a > -1 && w.splice(a, 1);
  }), [e]), {
    ...e,
    toast: at,
    dismiss: (a) => N({ type: "DISMISS_TOAST", toastId: a })
  };
}
const st = u.Provider, B = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(
  u.Viewport,
  {
    ref: a,
    className: s(
      "fixed top-0 z-[100] flex max-h-screen w-full flex-col-reverse p-4 sm:bottom-0 sm:right-0 sm:top-auto sm:flex-col md:max-w-[420px]",
      e
    ),
    ...t
  }
));
B.displayName = u.Viewport.displayName;
const rt = j(
  "group pointer-events-auto relative flex w-full items-center justify-between space-x-2 overflow-hidden rounded-md border p-4 pr-6 shadow-lg transition-all data-[swipe=cancel]:translate-x-0 data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-to-right-full data-[state=open]:slide-in-from-top-full data-[state=open]:sm:slide-in-from-bottom-full",
  {
    variants: {
      variant: {
        default: "border bg-background",
        destructive: "destructive group border-destructive bg-destructive text-destructive-foreground"
      }
    },
    defaultVariants: {
      variant: "default"
    }
  }
), U = r.forwardRef(({ className: e, variant: t, ...a }, d) => /* @__PURE__ */ o.jsx(u.Root, { ref: d, className: s(rt({ variant: t }), e), ...a }));
U.displayName = u.Root.displayName;
const dt = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(
  u.Action,
  {
    ref: a,
    className: s(
      "inline-flex h-8 shrink-0 items-center justify-center rounded-md border bg-transparent px-3 text-sm font-medium transition-colors hover:bg-secondary focus:outline-none focus:ring-1 focus:ring-ring disabled:pointer-events-none disabled:opacity-50 group-[.destructive]:border-muted/40 group-[.destructive]:hover:border-destructive/30 group-[.destructive]:hover:bg-destructive group-[.destructive]:hover:text-destructive-foreground group-[.destructive]:focus:ring-destructive",
      e
    ),
    ...t
  }
));
dt.displayName = u.Action.displayName;
const q = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(
  u.Close,
  {
    ref: a,
    className: s(
      "absolute right-1 top-1 rounded-md p-1 text-foreground/50 opacity-0 transition-opacity hover:text-foreground focus:opacity-100 focus:outline-none focus:ring-1 group-hover:opacity-100 group-[.destructive]:text-red-300 group-[.destructive]:hover:text-red-50 group-[.destructive]:focus:ring-red-400 group-[.destructive]:focus:ring-offset-red-600",
      e
    ),
    "toast-close": "",
    ...t,
    children: /* @__PURE__ */ o.jsx(M, { className: "h-4 w-4" })
  }
));
q.displayName = u.Close.displayName;
const J = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(u.Title, { ref: a, className: s("text-sm font-semibold [&+div]:text-xs", e), ...t }));
J.displayName = u.Title.displayName;
const K = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(u.Description, { ref: a, className: s("text-sm opacity-90", e), ...t }));
K.displayName = u.Description.displayName;
function Zt() {
  const { toasts: e } = ot();
  return /* @__PURE__ */ o.jsxs(st, { children: [
    e.map(({ id: t, title: a, description: d, action: l, ...R }) => /* @__PURE__ */ o.jsxs(U, { ...R, children: [
      /* @__PURE__ */ o.jsxs("div", { className: "grid gap-1", children: [
        a && /* @__PURE__ */ o.jsx(J, { children: a }),
        d && /* @__PURE__ */ o.jsx(K, { children: d })
      ] }),
      l,
      /* @__PURE__ */ o.jsx(q, {})
    ] }, t)),
    /* @__PURE__ */ o.jsx(B, {})
  ] });
}
const ea = ({ className: e, ...t }) => /* @__PURE__ */ o.jsx("div", { className: s("animate-pulse rounded-md bg-primary/10", e), ...t }), Q = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(
  p,
  {
    ref: a,
    className: s(
      "flex h-full w-full flex-col overflow-hidden rounded-md bg-popover text-popover-foreground",
      e
    ),
    ...t
  }
));
Q.displayName = p.displayName;
const ta = ({ children: e, ...t }) => /* @__PURE__ */ o.jsx(xe, { ...t, children: /* @__PURE__ */ o.jsx(H, { className: "overflow-hidden p-0", children: /* @__PURE__ */ o.jsx(Q, { className: "[&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-group]]:px-2 [&_[cmdk-input-wrapper]_svg]:h-5 [&_[cmdk-input-wrapper]_svg]:w-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:h-5 [&_[cmdk-item]_svg]:w-5", children: e }) }) }), nt = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsxs("div", { className: "flex items-center border-b px-3", "cmdk-input-wrapper": "", children: [
  /* @__PURE__ */ o.jsx(W, { className: "mr-2 h-4 w-4 shrink-0 opacity-50" }),
  /* @__PURE__ */ o.jsx(
    p.Input,
    {
      ref: a,
      className: s(
        "flex h-10 w-full rounded-md bg-transparent py-3 text-sm outline-none placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50",
        e
      ),
      ...t
    }
  )
] }));
nt.displayName = p.Input.displayName;
const it = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(
  p.List,
  {
    ref: a,
    className: s("max-h-[300px] overflow-y-auto overflow-x-hidden", e),
    ...t
  }
));
it.displayName = p.List.displayName;
const lt = r.forwardRef((e, t) => /* @__PURE__ */ o.jsx(p.Empty, { ref: t, className: "py-6 text-center text-sm", ...e }));
lt.displayName = p.Empty.displayName;
const ct = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(
  p.Group,
  {
    ref: a,
    className: s(
      "overflow-hidden p-1 text-foreground [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground",
      e
    ),
    ...t
  }
));
ct.displayName = p.Group.displayName;
const mt = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(p.Separator, { ref: a, className: s("-mx-1 h-px bg-border", e), ...t }));
mt.displayName = p.Separator.displayName;
const pt = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(
  p.Item,
  {
    ref: a,
    className: s(
      "relative flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none aria-selected:bg-accent aria-selected:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
      e
    ),
    ...t
  }
));
pt.displayName = p.Item.displayName;
const ft = ({ className: e, ...t }) => /* @__PURE__ */ o.jsx("span", { className: s("ml-auto text-xs tracking-widest text-muted-foreground", e), ...t });
ft.displayName = "CommandShortcut";
const aa = i.Root, oa = i.Trigger, sa = i.Group, ra = i.Portal, da = i.Sub, na = i.RadioGroup, ut = r.forwardRef(({ className: e, inset: t, children: a, ...d }, l) => /* @__PURE__ */ o.jsxs(
  i.SubTrigger,
  {
    ref: l,
    className: s(
      "flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground",
      t && "pl-8",
      e
    ),
    ...d,
    children: [
      a,
      /* @__PURE__ */ o.jsx(z, { className: "ml-auto h-4 w-4" })
    ]
  }
));
ut.displayName = i.SubTrigger.displayName;
const xt = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(
  i.SubContent,
  {
    ref: a,
    className: s(
      "z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-lg 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 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
      e
    ),
    ...t
  }
));
xt.displayName = i.SubContent.displayName;
const gt = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(i.Portal, { children: /* @__PURE__ */ o.jsx(
  i.Content,
  {
    ref: a,
    className: s(
      "z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md 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 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
      e
    ),
    ...t
  }
) }));
gt.displayName = i.Content.displayName;
const bt = r.forwardRef(({ className: e, inset: t, ...a }, d) => /* @__PURE__ */ o.jsx(
  i.Item,
  {
    ref: d,
    className: s(
      "relative flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
      t && "pl-8",
      e
    ),
    ...a
  }
));
bt.displayName = i.Item.displayName;
const yt = r.forwardRef(({ className: e, children: t, checked: a, ...d }, l) => /* @__PURE__ */ o.jsxs(
  i.CheckboxItem,
  {
    ref: l,
    className: s(
      "relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
      e
    ),
    checked: a,
    ...d,
    children: [
      /* @__PURE__ */ o.jsx("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ o.jsx(i.ItemIndicator, { children: /* @__PURE__ */ o.jsx(D, { className: "h-4 w-4" }) }) }),
      t
    ]
  }
));
yt.displayName = i.CheckboxItem.displayName;
const Nt = r.forwardRef(({ className: e, children: t, ...a }, d) => /* @__PURE__ */ o.jsxs(
  i.RadioItem,
  {
    ref: d,
    className: s(
      "relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
      e
    ),
    ...a,
    children: [
      /* @__PURE__ */ o.jsx("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ o.jsx(i.ItemIndicator, { children: /* @__PURE__ */ o.jsx(P, { className: "h-4 w-4 fill-current" }) }) }),
      t
    ]
  }
));
Nt.displayName = i.RadioItem.displayName;
const ht = r.forwardRef(({ className: e, inset: t, ...a }, d) => /* @__PURE__ */ o.jsx(
  i.Label,
  {
    ref: d,
    className: s("px-2 py-1.5 text-sm font-semibold text-foreground", t && "pl-8", e),
    ...a
  }
));
ht.displayName = i.Label.displayName;
const wt = r.forwardRef(({ className: e, ...t }, a) => /* @__PURE__ */ o.jsx(i.Separator, { ref: a, className: s("-mx-1 my-1 h-px bg-border", e), ...t }));
wt.displayName = i.Separator.displayName;
const vt = ({ className: e, ...t }) => /* @__PURE__ */ o.jsx("span", { className: s("ml-auto text-xs tracking-widest text-muted-foreground", e), ...t });
vt.displayName = "ContextMenuShortcut";
export {
  Mt as $,
  Ae as A,
  oe as B,
  aa as C,
  xe as D,
  Me as E,
  ze as F,
  ae as G,
  It as H,
  se as I,
  re as J,
  de as K,
  ke as L,
  ot as M,
  Te as N,
  Ot as O,
  Gt as P,
  Kt as Q,
  Qt as R,
  ea as S,
  Et as T,
  Ue as U,
  Ie as V,
  Qe as W,
  Xe as X,
  Xt as Y,
  qe as Z,
  Ye as _,
  oa as a,
  ie as a0,
  le as a1,
  me as a2,
  zt as a3,
  pe as a4,
  ce as a5,
  ue as a6,
  fe as a7,
  Je as a8,
  Ft as a9,
  at as aA,
  ta as aB,
  ft as aC,
  mt as aD,
  yt as aE,
  Nt as aF,
  ht as aG,
  wt as aH,
  vt as aI,
  sa as aJ,
  ra as aK,
  da as aL,
  xt as aM,
  ut as aN,
  na as aO,
  Bt as aa,
  Oe as ab,
  $e as ac,
  At as ad,
  Ut as ae,
  Le as af,
  Jt as ag,
  Ee as ah,
  Ge as ai,
  Lt as aj,
  Zt as ak,
  s as al,
  I as am,
  ne as an,
  ve as ao,
  F as ap,
  qt as aq,
  Ve as ar,
  He as as,
  Ke as at,
  Yt as au,
  $t as av,
  Be as aw,
  Fe as ax,
  Wt as ay,
  tt as az,
  gt as b,
  bt as c,
  Vt as d,
  Pe as e,
  he as f,
  we as g,
  je as h,
  Ce as i,
  De as j,
  Re as k,
  Pt as l,
  H as m,
  ge as n,
  ye as o,
  Ne as p,
  be as q,
  Ht as r,
  _e as s,
  Q as t,
  nt as u,
  it as v,
  lt as w,
  ct as x,
  pt as y,
  _t as z
};
