@contentstudio/ui 0.1.15 → 0.1.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -303,6 +303,12 @@ export declare interface DropdownProps {
303
303
  showArrow?: boolean;
304
304
  /** Whether the parent should have relative positioning */
305
305
  parentPositionRelative?: boolean;
306
+ /** Distance between the dropdown button and menu in pixels */
307
+ offsetDistance?: number;
308
+ /** Whether to unstyle the component */
309
+ unstyled?: boolean;
310
+ /** Whether to match the width of the button */
311
+ matchWidth?: boolean;
306
312
  }
307
313
 
308
314
  export { HoverCard }
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import { defineComponent as A, computed as m, openBlock as f, createElementBlock as y, normalizeClass as $, renderSlot as O, createElementVNode as z, createCommentVNode as S, withKeys as Mt, withModifiers as dt, toDisplayString as D, createTextVNode as se, mergeProps as te, createBlock as q, resolveDynamicComponent as he, ref as R, watch as U, onMounted as qe, onUnmounted as pt, withDirectives as me, vModelText as Et, Fragment as ae, renderList as _e, vShow as De, normalizeStyle as E, unref as _, Transition as $e, withCtx as le, Teleport as Ye, createVNode as xe, shallowRef as Tt, getCurrentScope as ft, onScopeDispose as gt, shallowReadonly as pe, readonly as It, toValue as jt, inject as Ke, provide as je, nextTick as ht, createStaticVNode as Ft } from "vue";
1
+ import { defineComponent as A, computed as m, openBlock as f, createElementBlock as y, normalizeClass as $, renderSlot as O, createElementVNode as z, createCommentVNode as S, withKeys as Mt, withModifiers as dt, toDisplayString as D, createTextVNode as se, mergeProps as te, createBlock as q, resolveDynamicComponent as he, ref as R, watch as U, onMounted as qe, onUnmounted as pt, withDirectives as me, vModelText as Et, Fragment as ae, renderList as _e, vShow as De, normalizeStyle as E, unref as _, Transition as $e, withCtx as le, Teleport as Ye, createVNode as xe, shallowRef as Tt, getCurrentScope as ft, onScopeDispose as gt, shallowReadonly as pe, readonly as It, toValue as jt, inject as Ke, provide as je, nextTick as ht, createStaticVNode as Wt } from "vue";
2
2
  const Xe = {
3
3
  primary: {
4
4
  base: "blue",
@@ -115,7 +115,7 @@ const Xe = {
115
115
  break;
116
116
  }
117
117
  return i.join(" ");
118
- }, Wt = (s, t) => {
118
+ }, Ft = (s, t) => {
119
119
  if (t === "filled")
120
120
  return "cstu-text-white";
121
121
  const e = Xe[s];
@@ -856,17 +856,17 @@ const Xe = {
856
856
  xl: "rounded-2xl",
857
857
  full: "rounded-full"
858
858
  })[d] || "rounded-lg", u = m(() => {
859
- const d = "w-full flex items-center justify-between transition-colors duration-200", C = [
859
+ const d = "w-full flex items-center justify-between transition-colors duration-200", k = [
860
860
  I(e.size, "input"),
861
861
  Ve(e.size, "input")
862
- ].join(" "), k = i(e.radius), B = e.error ? "focus-within:ring-2 focus-within:ring-red-500/20 focus-within:border-red-500" : "focus-within:ring-2 focus-within:ring-blue-500/20 focus-within:border-blue-500", V = e.variant === "filled" ? `bg-gray-50 border border-transparent ${!e.disabled && `hover:bg-gray-100 focus-within:bg-white focus-within:border-gray-300 ${B}`}` : `bg-white border border-gray-300 ${!e.disabled && `hover:border-gray-400 ${B}`}`, L = re({
862
+ ].join(" "), C = i(e.radius), B = e.error ? "focus-within:ring-2 focus-within:ring-red-500/20 focus-within:border-red-500" : "focus-within:ring-2 focus-within:ring-blue-500/20 focus-within:border-blue-500", V = e.variant === "filled" ? `bg-gray-50 border border-transparent ${!e.disabled && `hover:bg-gray-100 focus-within:bg-white focus-within:border-gray-300 ${B}`}` : `bg-white border border-gray-300 ${!e.disabled && `hover:border-gray-400 ${B}`}`, L = re({
863
863
  disabled: e.disabled,
864
864
  error: e.error
865
865
  }), P = !e.disabled && "cursor-pointer";
866
866
  return [
867
867
  d,
868
- C,
869
868
  k,
869
+ C,
870
870
  V,
871
871
  L,
872
872
  P
@@ -876,7 +876,7 @@ const Xe = {
876
876
  return e.options;
877
877
  const d = a.value.toLowerCase();
878
878
  return e.options.filter(
879
- (C) => C.label.toLowerCase().includes(d)
879
+ (k) => k.label.toLowerCase().includes(d)
880
880
  );
881
881
  }), g = () => {
882
882
  var d;
@@ -890,8 +890,8 @@ const Xe = {
890
890
  }, w = () => {
891
891
  n.value || (n.value = !0);
892
892
  }, v = (d) => {
893
- const C = d.target;
894
- l.value && !l.value.contains(C) && (n.value = !1);
893
+ const k = d.target;
894
+ l.value && !l.value.contains(k) && (n.value = !1);
895
895
  };
896
896
  return U(() => e.modelValue, (d) => {
897
897
  d ? c.value && e.searchable && (a.value = c.value.label) : a.value = "";
@@ -899,7 +899,7 @@ const Xe = {
899
899
  document.addEventListener("click", v);
900
900
  }), pt(() => {
901
901
  document.removeEventListener("click", v);
902
- }), (d, C) => (f(), y("div", {
902
+ }), (d, k) => (f(), y("div", {
903
903
  class: "relative select",
904
904
  ref_key: "selectRoot",
905
905
  ref: l
@@ -915,7 +915,7 @@ const Xe = {
915
915
  key: 0,
916
916
  ref_key: "searchInput",
917
917
  ref: r,
918
- "onUpdate:modelValue": C[0] || (C[0] = (k) => a.value = k),
918
+ "onUpdate:modelValue": k[0] || (k[0] = (C) => a.value = C),
919
919
  placeholder: d.placeholder,
920
920
  type: "text",
921
921
  class: "w-full bg-transparent outline-none placeholder:text-gray-500",
@@ -931,7 +931,7 @@ const Xe = {
931
931
  type: "button",
932
932
  class: "p-1 hover:bg-gray-100 rounded-full text-gray-500 hover:text-gray-700",
933
933
  onClick: dt(b, ["stop"])
934
- }, C[1] || (C[1] = [
934
+ }, k[1] || (k[1] = [
935
935
  z("svg", {
936
936
  class: "w-4 h-4",
937
937
  fill: "none",
@@ -951,7 +951,7 @@ const Xe = {
951
951
  fill: "none",
952
952
  stroke: "currentColor",
953
953
  viewBox: "0 0 24 24"
954
- }, C[2] || (C[2] = [
954
+ }, k[2] || (k[2] = [
955
955
  z("path", {
956
956
  "stroke-linecap": "round",
957
957
  "stroke-linejoin": "round",
@@ -972,7 +972,7 @@ const Xe = {
972
972
  }, [
973
973
  d.loading ? (f(), y("div", ds, [
974
974
  O(d.$slots, "loader", {}, () => [
975
- C[3] || (C[3] = z("svg", {
975
+ k[3] || (k[3] = z("svg", {
976
976
  class: "animate-spin h-5 w-5 mx-auto",
977
977
  xmlns: "http://www.w3.org/2000/svg",
978
978
  fill: "none",
@@ -994,18 +994,18 @@ const Xe = {
994
994
  ], -1))
995
995
  ])
996
996
  ])) : (f(), y(ae, { key: 1 }, [
997
- (f(!0), y(ae, null, _e(p.value, (k) => (f(), y("div", {
998
- key: k.value,
997
+ (f(!0), y(ae, null, _e(p.value, (C) => (f(), y("div", {
998
+ key: C.value,
999
999
  class: $([
1000
1000
  "py-2.5 px-4 flex items-center transition-colors duration-200",
1001
1001
  "text-[14px] leading-5",
1002
1002
  "text-gray-900",
1003
- k.value === d.modelValue ? "bg-gray-50 font-medium" : "hover:bg-gray-50",
1004
- k.disabled ? "opacity-50 cursor-not-allowed" : "cursor-pointer"
1003
+ C.value === d.modelValue ? "bg-gray-50 font-medium" : "hover:bg-gray-50",
1004
+ C.disabled ? "opacity-50 cursor-not-allowed" : "cursor-pointer"
1005
1005
  ]),
1006
- onClick: (B) => !k.disabled && x(k)
1006
+ onClick: (B) => !C.disabled && x(C)
1007
1007
  }, [
1008
- d.withCheckIcon && k.value === d.modelValue ? (f(), y("svg", {
1008
+ d.withCheckIcon && C.value === d.modelValue ? (f(), y("svg", {
1009
1009
  key: 0,
1010
1010
  class: $([
1011
1011
  "w-4 h-4 text-blue-600 shrink-0",
@@ -1014,7 +1014,7 @@ const Xe = {
1014
1014
  fill: "none",
1015
1015
  stroke: "currentColor",
1016
1016
  viewBox: "0 0 24 24"
1017
- }, C[4] || (C[4] = [
1017
+ }, k[4] || (k[4] = [
1018
1018
  z("path", {
1019
1019
  "stroke-linecap": "round",
1020
1020
  "stroke-linejoin": "round",
@@ -1023,8 +1023,8 @@ const Xe = {
1023
1023
  }, null, -1)
1024
1024
  ]), 2)) : S("", !0),
1025
1025
  z("span", {
1026
- class: $({ "text-gray-500": k.disabled })
1027
- }, D(k.label), 3)
1026
+ class: $({ "text-gray-500": C.disabled })
1027
+ }, D(C.label), 3)
1028
1028
  ], 10, ps))), 128)),
1029
1029
  p.value.length === 0 ? (f(), y("div", fs, D(d.nothingFoundMessage || "No options found"), 1)) : S("", !0)
1030
1030
  ], 64))
@@ -1264,7 +1264,7 @@ const Cs = {
1264
1264
  active: !1,
1265
1265
  focus: !1,
1266
1266
  disabled: e.disabled
1267
- })), a = m(() => Nt(e.variant)), r = m(() => Wt(e.color, e.variant)), l = m(() => Ht(e.color, e.variant)), i = m(() => I(e.size, "alert")), u = m(() => qt(e.size, "alert")), c = m(() => Ge(e.size)), p = m(() => mt(e.size)), g = m(() => re({
1267
+ })), a = m(() => Nt(e.variant)), r = m(() => Ft(e.color, e.variant)), l = m(() => Ht(e.color, e.variant)), i = m(() => I(e.size, "alert")), u = m(() => qt(e.size, "alert")), c = m(() => Ge(e.size)), p = m(() => mt(e.size)), g = m(() => re({
1268
1268
  disabled: e.disabled,
1269
1269
  loading: e.loading
1270
1270
  })), x = m(() => Kt({
@@ -1549,7 +1549,7 @@ const jn = /* @__PURE__ */ A({
1549
1549
  }, _s = {
1550
1550
  key: 1,
1551
1551
  class: "text-lg font-medium mb-2"
1552
- }, Ds = { key: 2 }, Fn = /* @__PURE__ */ A({
1552
+ }, Ds = { key: 2 }, Wn = /* @__PURE__ */ A({
1553
1553
  __name: "Dialog",
1554
1554
  props: {
1555
1555
  title: {},
@@ -1638,7 +1638,7 @@ const jn = /* @__PURE__ */ A({
1638
1638
  start: "end",
1639
1639
  end: "start"
1640
1640
  };
1641
- function Fe(s, t, e) {
1641
+ function We(s, t, e) {
1642
1642
  return oe(s, ye(t, e));
1643
1643
  }
1644
1644
  function ze(s, t) {
@@ -1670,9 +1670,9 @@ function Ms(s, t, e) {
1670
1670
  }
1671
1671
  function Es(s) {
1672
1672
  const t = Re(s);
1673
- return [We(s), t, We(t)];
1673
+ return [Fe(s), t, Fe(t)];
1674
1674
  }
1675
- function We(s) {
1675
+ function Fe(s) {
1676
1676
  return s.replace(/start|end/g, (t) => Ps[t]);
1677
1677
  }
1678
1678
  function Ts(s, t, e) {
@@ -1691,7 +1691,7 @@ function Ts(s, t, e) {
1691
1691
  function Is(s, t, e, o) {
1692
1692
  const n = Be(s);
1693
1693
  let a = Ts(ie(s), e === "start", o);
1694
- return n && (a = a.map((r) => r + "-" + n), t && (a = a.concat(a.map(We)))), a;
1694
+ return n && (a = a.map((r) => r + "-" + n), t && (a = a.concat(a.map(Fe)))), a;
1695
1695
  }
1696
1696
  function Re(s) {
1697
1697
  return s.replace(/left|right|bottom|top/g, (t) => Vs[t]);
@@ -1779,7 +1779,7 @@ function at(s, t, e) {
1779
1779
  }
1780
1780
  return x;
1781
1781
  }
1782
- const Fs = async (s, t, e) => {
1782
+ const Ws = async (s, t, e) => {
1783
1783
  const {
1784
1784
  placement: o = "bottom",
1785
1785
  strategy: n = "absolute",
@@ -1800,8 +1800,8 @@ const Fs = async (s, t, e) => {
1800
1800
  fn: v
1801
1801
  } = l[h], {
1802
1802
  x: d,
1803
- y: C,
1804
- data: k,
1803
+ y: k,
1804
+ data: C,
1805
1805
  reset: B
1806
1806
  } = await v({
1807
1807
  x: c,
@@ -1817,11 +1817,11 @@ const Fs = async (s, t, e) => {
1817
1817
  floating: t
1818
1818
  }
1819
1819
  });
1820
- c = d ?? c, p = C ?? p, x = {
1820
+ c = d ?? c, p = k ?? p, x = {
1821
1821
  ...x,
1822
1822
  [w]: {
1823
1823
  ...x[w],
1824
- ...k
1824
+ ...C
1825
1825
  }
1826
1826
  }, B && b <= 50 && (b++, typeof B == "object" && (B.placement && (g = B.placement), B.rects && (u = B.rects === !0 ? await r.getElementRects({
1827
1827
  reference: s,
@@ -1866,7 +1866,7 @@ async function wt(s, t) {
1866
1866
  y: n,
1867
1867
  width: r.floating.width,
1868
1868
  height: r.floating.height
1869
- } : r.reference, C = await (a.getOffsetParent == null ? void 0 : a.getOffsetParent(l.floating)), k = await (a.isElement == null ? void 0 : a.isElement(C)) ? await (a.getScale == null ? void 0 : a.getScale(C)) || {
1869
+ } : r.reference, k = await (a.getOffsetParent == null ? void 0 : a.getOffsetParent(l.floating)), C = await (a.isElement == null ? void 0 : a.isElement(k)) ? await (a.getScale == null ? void 0 : a.getScale(k)) || {
1870
1870
  x: 1,
1871
1871
  y: 1
1872
1872
  } : {
@@ -1875,17 +1875,17 @@ async function wt(s, t) {
1875
1875
  }, B = Ae(a.convertOffsetParentRelativeRectToViewportRelativeRect ? await a.convertOffsetParentRelativeRectToViewportRelativeRect({
1876
1876
  elements: l,
1877
1877
  rect: d,
1878
- offsetParent: C,
1878
+ offsetParent: k,
1879
1879
  strategy: i
1880
1880
  }) : d);
1881
1881
  return {
1882
- top: (v.top - B.top + b.top) / k.y,
1883
- bottom: (B.bottom - v.bottom + b.bottom) / k.y,
1884
- left: (v.left - B.left + b.left) / k.x,
1885
- right: (B.right - v.right + b.right) / k.x
1882
+ top: (v.top - B.top + b.top) / C.y,
1883
+ bottom: (B.bottom - v.bottom + b.bottom) / C.y,
1884
+ left: (v.left - B.left + b.left) / C.x,
1885
+ right: (B.right - v.right + b.right) / C.x
1886
1886
  };
1887
1887
  }
1888
- const Ws = (s) => ({
1888
+ const Fs = (s) => ({
1889
1889
  name: "arrow",
1890
1890
  options: s,
1891
1891
  async fn(t) {
@@ -1906,10 +1906,10 @@ const Ws = (s) => ({
1906
1906
  const p = vt(c), g = {
1907
1907
  x: e,
1908
1908
  y: o
1909
- }, x = Je(n), b = Qe(x), h = await r.getDimensions(u), w = x === "y", v = w ? "top" : "left", d = w ? "bottom" : "right", C = w ? "clientHeight" : "clientWidth", k = a.reference[b] + a.reference[x] - g[x] - a.floating[b], B = g[x] - a.reference[x], V = await (r.getOffsetParent == null ? void 0 : r.getOffsetParent(u));
1910
- let L = V ? V[C] : 0;
1911
- (!L || !await (r.isElement == null ? void 0 : r.isElement(V))) && (L = l.floating[C] || a.floating[b]);
1912
- const P = k / 2 - B / 2, W = L / 2 - h[b] / 2 - 1, G = ye(p[v], W), we = ye(p[d], W), ee = G, Ce = L - h[b] - we, M = L / 2 - h[b] / 2 + P, de = Fe(ee, M, Ce), X = !i.arrow && Be(n) != null && M !== de && a.reference[b] / 2 - (M < ee ? G : we) - h[b] / 2 < 0, H = X ? M < ee ? M - ee : M - Ce : 0;
1909
+ }, x = Je(n), b = Qe(x), h = await r.getDimensions(u), w = x === "y", v = w ? "top" : "left", d = w ? "bottom" : "right", k = w ? "clientHeight" : "clientWidth", C = a.reference[b] + a.reference[x] - g[x] - a.floating[b], B = g[x] - a.reference[x], V = await (r.getOffsetParent == null ? void 0 : r.getOffsetParent(u));
1910
+ let L = V ? V[k] : 0;
1911
+ (!L || !await (r.isElement == null ? void 0 : r.isElement(V))) && (L = l.floating[k] || a.floating[b]);
1912
+ const P = C / 2 - B / 2, F = L / 2 - h[b] / 2 - 1, G = ye(p[v], F), we = ye(p[d], F), ee = G, Ce = L - h[b] - we, M = L / 2 - h[b] / 2 + P, de = We(ee, M, Ce), X = !i.arrow && Be(n) != null && M !== de && a.reference[b] / 2 - (M < ee ? G : we) - h[b] / 2 < 0, H = X ? M < ee ? M - ee : M - Ce : 0;
1913
1913
  return {
1914
1914
  [x]: g[x] + H,
1915
1915
  data: {
@@ -1946,18 +1946,18 @@ const Ws = (s) => ({
1946
1946
  } = ze(s, t);
1947
1947
  if ((e = a.arrow) != null && e.alignmentOffset)
1948
1948
  return {};
1949
- const v = ie(n), d = be(l), C = ie(l) === l, k = await (i.isRTL == null ? void 0 : i.isRTL(u.floating)), B = g || (C || !h ? [Re(l)] : Es(l)), V = b !== "none";
1950
- !g && V && B.push(...Is(l, h, b, k));
1951
- const L = [l, ...B], P = await wt(t, w), W = [];
1949
+ const v = ie(n), d = be(l), k = ie(l) === l, C = await (i.isRTL == null ? void 0 : i.isRTL(u.floating)), B = g || (k || !h ? [Re(l)] : Es(l)), V = b !== "none";
1950
+ !g && V && B.push(...Is(l, h, b, C));
1951
+ const L = [l, ...B], P = await wt(t, w), F = [];
1952
1952
  let G = ((o = a.flip) == null ? void 0 : o.overflows) || [];
1953
- if (c && W.push(P[v]), p) {
1954
- const M = Ms(n, r, k);
1955
- W.push(P[M[0]], P[M[1]]);
1953
+ if (c && F.push(P[v]), p) {
1954
+ const M = Ms(n, r, C);
1955
+ F.push(P[M[0]], P[M[1]]);
1956
1956
  }
1957
1957
  if (G = [...G, {
1958
1958
  placement: n,
1959
- overflows: W
1960
- }], !W.every((M) => M <= 0)) {
1959
+ overflows: F
1960
+ }], !F.every((M) => M <= 0)) {
1961
1961
  var we, ee;
1962
1962
  const M = (((we = a.flip) == null ? void 0 : we.index) || 0) + 1, de = L[M];
1963
1963
  if (de)
@@ -2082,12 +2082,12 @@ const qs = function(s) {
2082
2082
  }, c = await wt(t, i), p = be(ie(n)), g = bt(p);
2083
2083
  let x = u[g], b = u[p];
2084
2084
  if (a) {
2085
- const w = g === "y" ? "top" : "left", v = g === "y" ? "bottom" : "right", d = x + c[w], C = x - c[v];
2086
- x = Fe(d, x, C);
2085
+ const w = g === "y" ? "top" : "left", v = g === "y" ? "bottom" : "right", d = x + c[w], k = x - c[v];
2086
+ x = We(d, x, k);
2087
2087
  }
2088
2088
  if (r) {
2089
- const w = p === "y" ? "top" : "left", v = p === "y" ? "bottom" : "right", d = b + c[w], C = b - c[v];
2090
- b = Fe(d, b, C);
2089
+ const w = p === "y" ? "top" : "left", v = p === "y" ? "bottom" : "right", d = b + c[w], k = b - c[v];
2090
+ b = We(d, b, k);
2091
2091
  }
2092
2092
  const h = l.fn({
2093
2093
  ...t,
@@ -2140,7 +2140,7 @@ function Se(s) {
2140
2140
  overflowX: e,
2141
2141
  overflowY: o,
2142
2142
  display: n
2143
- } = F(s);
2143
+ } = W(s);
2144
2144
  return /auto|scroll|overlay|hidden|clip/.test(t + o + e) && !["inline", "contents"].includes(n);
2145
2145
  }
2146
2146
  function Ks(s) {
@@ -2156,7 +2156,7 @@ function Me(s) {
2156
2156
  });
2157
2157
  }
2158
2158
  function tt(s) {
2159
- const t = st(), e = j(s) ? F(s) : s;
2159
+ const t = st(), e = j(s) ? W(s) : s;
2160
2160
  return e.transform !== "none" || e.perspective !== "none" || (e.containerType ? e.containerType !== "normal" : !1) || !t && (e.backdropFilter ? e.backdropFilter !== "none" : !1) || !t && (e.filter ? e.filter !== "none" : !1) || ["transform", "perspective", "filter"].some((o) => (e.willChange || "").includes(o)) || ["paint", "layout", "strict", "content"].some((o) => (e.contain || "").includes(o));
2161
2161
  }
2162
2162
  function Xs(s) {
@@ -2176,7 +2176,7 @@ function st() {
2176
2176
  function ve(s) {
2177
2177
  return ["html", "body", "#document"].includes(ce(s));
2178
2178
  }
2179
- function F(s) {
2179
+ function W(s) {
2180
2180
  return T(s).getComputedStyle(s);
2181
2181
  }
2182
2182
  function Ee(s) {
@@ -2218,7 +2218,7 @@ function He(s) {
2218
2218
  return s.parent && Object.getPrototypeOf(s.parent) ? s.frameElement : null;
2219
2219
  }
2220
2220
  function kt(s) {
2221
- const t = F(s);
2221
+ const t = W(s);
2222
2222
  let e = parseFloat(t.width) || 0, o = parseFloat(t.height) || 0;
2223
2223
  const n = Y(s), a = n ? s.offsetWidth : e, r = n ? s.offsetHeight : o, l = Oe(e) !== a || Oe(o) !== r;
2224
2224
  return l && (e = a, o = r), {
@@ -2267,8 +2267,8 @@ function ue(s, t, e, o) {
2267
2267
  const g = T(a), x = o && j(o) ? T(o) : o;
2268
2268
  let b = g, h = He(b);
2269
2269
  for (; h && o && x !== b; ) {
2270
- const w = ge(h), v = h.getBoundingClientRect(), d = F(h), C = v.left + (h.clientLeft + parseFloat(d.paddingLeft)) * w.x, k = v.top + (h.clientTop + parseFloat(d.paddingTop)) * w.y;
2271
- i *= w.x, u *= w.y, c *= w.x, p *= w.y, i += C, u += k, b = T(h), h = He(b);
2270
+ const w = ge(h), v = h.getBoundingClientRect(), d = W(h), k = v.left + (h.clientLeft + parseFloat(d.paddingLeft)) * w.x, C = v.top + (h.clientTop + parseFloat(d.paddingTop)) * w.y;
2271
+ i *= w.x, u *= w.y, c *= w.x, p *= w.y, i += k, u += C, b = T(h), h = He(b);
2272
2272
  }
2273
2273
  }
2274
2274
  return Ae({
@@ -2327,7 +2327,7 @@ function Js(s) {
2327
2327
  const t = K(s), e = Ee(s), o = s.ownerDocument.body, n = oe(t.scrollWidth, t.clientWidth, o.scrollWidth, o.clientWidth), a = oe(t.scrollHeight, t.clientHeight, o.scrollHeight, o.clientHeight);
2328
2328
  let r = -e.scrollLeft + ot(s);
2329
2329
  const l = -e.scrollTop;
2330
- return F(o).direction === "rtl" && (r += oe(t.clientWidth, o.clientWidth) - n), {
2330
+ return W(o).direction === "rtl" && (r += oe(t.clientWidth, o.clientWidth) - n), {
2331
2331
  width: n,
2332
2332
  height: a,
2333
2333
  x: r,
@@ -2379,17 +2379,17 @@ function rt(s, t, e) {
2379
2379
  }
2380
2380
  function Bt(s, t) {
2381
2381
  const e = J(s);
2382
- return e === t || !j(e) || ve(e) ? !1 : F(e).position === "fixed" || Bt(e, t);
2382
+ return e === t || !j(e) || ve(e) ? !1 : W(e).position === "fixed" || Bt(e, t);
2383
2383
  }
2384
2384
  function sn(s, t) {
2385
2385
  const e = t.get(s);
2386
2386
  if (e)
2387
2387
  return e;
2388
2388
  let o = ke(s, [], !1).filter((l) => j(l) && ce(l) !== "body"), n = null;
2389
- const a = F(s).position === "fixed";
2389
+ const a = W(s).position === "fixed";
2390
2390
  let r = a ? J(s) : s;
2391
2391
  for (; j(r) && !ve(r); ) {
2392
- const l = F(r), i = tt(r);
2392
+ const l = W(r), i = tt(r);
2393
2393
  !i && l.position === "fixed" && (n = null), (a ? !i && !n : !i && l.position === "static" && !!n && ["absolute", "fixed"].includes(n.position) || Se(r) && !i && Bt(s, r)) ? o = o.filter((c) => c !== r) : n = l, r = J(r);
2394
2394
  }
2395
2395
  return t.set(s, o), o;
@@ -2444,10 +2444,10 @@ function an(s, t, e) {
2444
2444
  };
2445
2445
  }
2446
2446
  function Te(s) {
2447
- return F(s).position === "static";
2447
+ return W(s).position === "static";
2448
2448
  }
2449
2449
  function it(s, t) {
2450
- if (!Y(s) || F(s).position === "fixed")
2450
+ if (!Y(s) || W(s).position === "fixed")
2451
2451
  return null;
2452
2452
  if (t)
2453
2453
  return t(s);
@@ -2485,7 +2485,7 @@ const ln = async function(s) {
2485
2485
  };
2486
2486
  };
2487
2487
  function rn(s) {
2488
- return F(s).direction === "rtl";
2488
+ return W(s).direction === "rtl";
2489
2489
  }
2490
2490
  const un = {
2491
2491
  convertOffsetParentRelativeRectToViewportRelativeRect: Zs,
@@ -2520,26 +2520,26 @@ function cn(s, t) {
2520
2520
  rootMargin: -x + "px " + -b + "px " + -h + "px " + -w + "px",
2521
2521
  threshold: oe(0, ye(1, i)) || 1
2522
2522
  };
2523
- let C = !0;
2524
- function k(B) {
2523
+ let k = !0;
2524
+ function C(B) {
2525
2525
  const V = B[0].intersectionRatio;
2526
2526
  if (V !== i) {
2527
- if (!C)
2527
+ if (!k)
2528
2528
  return r();
2529
2529
  V ? r(!1, V) : o = setTimeout(() => {
2530
2530
  r(!1, 1e-7);
2531
2531
  }, 1e3);
2532
2532
  }
2533
- C = !1;
2533
+ k = !1;
2534
2534
  }
2535
2535
  try {
2536
- e = new IntersectionObserver(k, {
2536
+ e = new IntersectionObserver(C, {
2537
2537
  ...d,
2538
2538
  // Handle <iframe>s
2539
2539
  root: n.ownerDocument
2540
2540
  });
2541
2541
  } catch {
2542
- e = new IntersectionObserver(k, d);
2542
+ e = new IntersectionObserver(C, d);
2543
2543
  }
2544
2544
  e.observe(s);
2545
2545
  }
@@ -2564,8 +2564,8 @@ function dn(s, t, e, o) {
2564
2564
  r && (x = new ResizeObserver((v) => {
2565
2565
  let [d] = v;
2566
2566
  d && d.target === u && x && (x.unobserve(t), cancelAnimationFrame(g), g = requestAnimationFrame(() => {
2567
- var C;
2568
- (C = x) == null || C.observe(t);
2567
+ var k;
2568
+ (k = x) == null || k.observe(t);
2569
2569
  })), e();
2570
2570
  }), u && !i && x.observe(u), x.observe(t));
2571
2571
  let b, h = i ? ue(s) : null;
@@ -2581,7 +2581,7 @@ function dn(s, t, e, o) {
2581
2581
  }), p == null || p(), (v = x) == null || v.disconnect(), x = null, i && cancelAnimationFrame(b);
2582
2582
  };
2583
2583
  }
2584
- const Lt = qs, Ot = Ys, Rt = Hs, pn = Ws, fn = (s, t, e) => {
2584
+ const Lt = qs, Ot = Ys, Rt = Hs, pn = Fs, fn = (s, t, e) => {
2585
2585
  const o = /* @__PURE__ */ new Map(), n = {
2586
2586
  platform: un,
2587
2587
  ...e
@@ -2589,7 +2589,7 @@ const Lt = qs, Ot = Ys, Rt = Hs, pn = Ws, fn = (s, t, e) => {
2589
2589
  ...n.platform,
2590
2590
  _c: o
2591
2591
  };
2592
- return Fs(s, t, {
2592
+ return Ws(s, t, {
2593
2593
  ...n,
2594
2594
  platform: a
2595
2595
  });
@@ -2649,21 +2649,21 @@ function _t(s, t, e) {
2649
2649
  };
2650
2650
  if (!c.value)
2651
2651
  return L;
2652
- const P = ut(c.value, p.value), W = ut(c.value, g.value);
2652
+ const P = ut(c.value, p.value), F = ut(c.value, g.value);
2653
2653
  return i.value ? {
2654
2654
  ...L,
2655
- transform: "translate(" + P + "px, " + W + "px)",
2655
+ transform: "translate(" + P + "px, " + F + "px)",
2656
2656
  ...At(c.value) >= 1.5 && {
2657
2657
  willChange: "transform"
2658
2658
  }
2659
2659
  } : {
2660
2660
  position: x.value,
2661
2661
  left: P + "px",
2662
- top: W + "px"
2662
+ top: F + "px"
2663
2663
  };
2664
2664
  });
2665
2665
  let d;
2666
- function C() {
2666
+ function k() {
2667
2667
  if (u.value == null || c.value == null)
2668
2668
  return;
2669
2669
  const L = n.value;
@@ -2675,29 +2675,29 @@ function _t(s, t, e) {
2675
2675
  p.value = P.x, g.value = P.y, x.value = P.strategy, b.value = P.placement, h.value = P.middlewareData, w.value = L !== !1;
2676
2676
  });
2677
2677
  }
2678
- function k() {
2678
+ function C() {
2679
2679
  typeof d == "function" && (d(), d = void 0);
2680
2680
  }
2681
2681
  function B() {
2682
- if (k(), o === void 0) {
2683
- C();
2682
+ if (C(), o === void 0) {
2683
+ k();
2684
2684
  return;
2685
2685
  }
2686
2686
  if (u.value != null && c.value != null) {
2687
- d = o(u.value, c.value, C);
2687
+ d = o(u.value, c.value, k);
2688
2688
  return;
2689
2689
  }
2690
2690
  }
2691
2691
  function V() {
2692
2692
  n.value || (w.value = !1);
2693
2693
  }
2694
- return U([a, r, l, n], C, {
2694
+ return U([a, r, l, n], k, {
2695
2695
  flush: "sync"
2696
2696
  }), U([u, c], B, {
2697
2697
  flush: "sync"
2698
2698
  }), U(n, V, {
2699
2699
  flush: "sync"
2700
- }), ft() && gt(k), {
2700
+ }), ft() && gt(C), {
2701
2701
  x: pe(p),
2702
2702
  y: pe(g),
2703
2703
  strategy: pe(x),
@@ -2705,7 +2705,7 @@ function _t(s, t, e) {
2705
2705
  middlewareData: pe(h),
2706
2706
  isPositioned: pe(w),
2707
2707
  floatingStyles: v,
2708
- update: C
2708
+ update: k
2709
2709
  };
2710
2710
  }
2711
2711
  function mn(s) {
@@ -2815,21 +2815,21 @@ const Dt = Symbol("hover-card"), Vt = /* @__PURE__ */ A({
2815
2815
  middleware: [
2816
2816
  Lt(t.offset),
2817
2817
  Rt({
2818
- fallbackPlacements: ["top", "bottom", "right", "left"].filter((k) => k !== t.placement)
2818
+ fallbackPlacements: ["top", "bottom", "right", "left"].filter((C) => C !== t.placement)
2819
2819
  }),
2820
2820
  Ot({ padding: 8 }),
2821
2821
  hn({ element: o })
2822
2822
  ]
2823
2823
  });
2824
- U(r, async (k) => {
2825
- k && await b();
2824
+ U(r, async (C) => {
2825
+ C && await b();
2826
2826
  });
2827
2827
  const h = m(() => {
2828
- var k, B;
2829
- return (B = (k = g.value) == null ? void 0 : k.arrow) == null ? void 0 : B.x;
2828
+ var C, B;
2829
+ return (B = (C = g.value) == null ? void 0 : C.arrow) == null ? void 0 : B.x;
2830
2830
  }), w = m(() => {
2831
- var k, B;
2832
- return (B = (k = g.value) == null ? void 0 : k.arrow) == null ? void 0 : B.y;
2831
+ var C, B;
2832
+ return (B = (C = g.value) == null ? void 0 : C.arrow) == null ? void 0 : B.y;
2833
2833
  }), v = m(() => {
2834
2834
  switch (x.value) {
2835
2835
  case "top":
@@ -2856,23 +2856,23 @@ const Dt = Symbol("hover-card"), Vt = /* @__PURE__ */ A({
2856
2856
  default:
2857
2857
  return "translate(-50%, -50%)";
2858
2858
  }
2859
- }), C = m(() => ({
2859
+ }), k = m(() => ({
2860
2860
  xs: "w-[200px]",
2861
2861
  sm: "w-[240px]",
2862
2862
  md: "w-[320px]",
2863
2863
  lg: "w-[400px]",
2864
2864
  xl: "w-[480px]"
2865
2865
  })[t.size]);
2866
- return (k, B) => (f(), y("div", {
2866
+ return (C, B) => (f(), y("div", {
2867
2867
  ref_key: "reference",
2868
2868
  ref: n,
2869
2869
  class: "relative inline-block",
2870
- onMouseenter: B[2] || (B[2] = (V) => !k.disabled && _(l)()),
2871
- onMouseleave: B[3] || (B[3] = (V) => !k.disabled && _(i)())
2870
+ onMouseenter: B[2] || (B[2] = (V) => !C.disabled && _(l)()),
2871
+ onMouseleave: B[3] || (B[3] = (V) => !C.disabled && _(i)())
2872
2872
  }, [
2873
2873
  xe(Vt, null, {
2874
2874
  default: le(() => [
2875
- O(k.$slots, "target")
2875
+ O(C.$slots, "target")
2876
2876
  ]),
2877
2877
  _: 3
2878
2878
  }),
@@ -2897,16 +2897,16 @@ const Dt = Symbol("hover-card"), Vt = /* @__PURE__ */ A({
2897
2897
  position: _(p),
2898
2898
  top: `${_(c) ?? 0}px`,
2899
2899
  left: `${_(u) ?? 0}px`,
2900
- zIndex: k.zIndex || 1e3
2900
+ zIndex: C.zIndex || 1e3
2901
2901
  }),
2902
- class: $(["min-w-[200px]", [C.value]]),
2903
- onMouseenter: B[0] || (B[0] = (V) => !k.disabled && _(l)()),
2904
- onMouseleave: B[1] || (B[1] = (V) => !k.disabled && _(i)())
2902
+ class: $(["min-w-[200px]", [k.value]]),
2903
+ onMouseenter: B[0] || (B[0] = (V) => !C.disabled && _(l)()),
2904
+ onMouseleave: B[1] || (B[1] = (V) => !C.disabled && _(i)())
2905
2905
  }, [
2906
2906
  z("div", bn, [
2907
- O(k.$slots, "dropdown")
2907
+ O(C.$slots, "dropdown")
2908
2908
  ]),
2909
- k.withArrow ? (f(), y("div", {
2909
+ C.withArrow ? (f(), y("div", {
2910
2910
  key: 0,
2911
2911
  ref_key: "arrowRef",
2912
2912
  ref: o,
@@ -2932,7 +2932,7 @@ const Dt = Symbol("hover-card"), Vt = /* @__PURE__ */ A({
2932
2932
  Object.assign(vn, {
2933
2933
  Target: Vt
2934
2934
  });
2935
- const Wn = {}, wn = {
2935
+ const Fn = {}, wn = {
2936
2936
  key: 0,
2937
2937
  class: "badge-section mr-2"
2938
2938
  }, Cn = { class: "badge-label" }, kn = {
@@ -3030,7 +3030,8 @@ const Bn = ["data-active"], Nn = /* @__PURE__ */ A({
3030
3030
  disabledText: { default: "" },
3031
3031
  parentPositionRelative: { type: Boolean, default: !0 },
3032
3032
  offsetDistance: { default: 8 },
3033
- unstyled: { type: Boolean, default: !1 }
3033
+ unstyled: { type: Boolean, default: !1 },
3034
+ matchWidth: { type: Boolean, default: !1 }
3034
3035
  },
3035
3036
  emits: ["close", "update:open"],
3036
3037
  setup(s, { emit: t }) {
@@ -3081,9 +3082,9 @@ const Bn = ["data-active"], Nn = /* @__PURE__ */ A({
3081
3082
  je("dropdownClose", b);
3082
3083
  function h() {
3083
3084
  e.disabled || (n.value ? (n.value = !1, o("close"), o("update:open", !1)) : (n.value = !0, o("update:open", !0), setTimeout(() => {
3084
- var C, k;
3085
- (C = r.value) == null || C.focus();
3086
- const d = (k = r.value) == null ? void 0 : k.querySelector(".active");
3085
+ var k, C;
3086
+ (k = r.value) == null || k.focus();
3087
+ const d = (C = r.value) == null ? void 0 : C.querySelector(".active");
3087
3088
  d == null || d.scrollIntoView({ behavior: "smooth" });
3088
3089
  }, 100)));
3089
3090
  }
@@ -3093,7 +3094,7 @@ const Bn = ["data-active"], Nn = /* @__PURE__ */ A({
3093
3094
  function v(d = !1) {
3094
3095
  n.value = !1, !d && (o("close"), o("update:open", !1));
3095
3096
  }
3096
- return (d, C) => me((f(), y("div", {
3097
+ return (d, k) => me((f(), y("div", {
3097
3098
  class: $(["cstu-inline-block cstu-text-left cstu-dropdown-container", [
3098
3099
  { "cstu-relative": d.parentPositionRelative },
3099
3100
  { "cstu-grayscale cstu-filter cstu-cursor-not-allowed cstu-opacity-70": d.disabled },
@@ -3117,14 +3118,14 @@ const Bn = ["data-active"], Nn = /* @__PURE__ */ A({
3117
3118
  }, [
3118
3119
  O(d.$slots, "icon", { closeDropdown: v }),
3119
3120
  O(d.$slots, "selected", { closeDropdown: v }, () => [
3120
- C[0] || (C[0] = se("Select"))
3121
+ k[0] || (k[0] = se("Select"))
3121
3122
  ]),
3122
3123
  d.showArrow ? (f(), y("span", {
3123
3124
  key: 0,
3124
3125
  class: $(["cstu-transition cstu-leading-none", { "cstu-rotate-180": n.value }])
3125
3126
  }, [
3126
3127
  O(d.$slots, "arrow", { closeDropdown: v }, () => [
3127
- C[1] || (C[1] = Ft('<svg xmlns="http://www.w3.org/2000/svg" width="12" height="12" viewBox="0 0 12 12" fill="none"><g clip-path="url(#clip0_33663_12905)"><path d="M6 8.95312C5.91113 8.95312 5.82739 8.93604 5.74878 8.90186C5.67017 8.86768 5.6001 8.81982 5.53857 8.7583L0.93457 4.1543C0.886719 4.09961 0.845703 4.03467 0.811523 3.95947C0.777344 3.88428 0.760254 3.80225 0.760254 3.71338C0.760254 3.53564 0.823486 3.38354 0.949951 3.25708C1.07642 3.13062 1.23193 3.06738 1.4165 3.06738C1.49854 3.06738 1.57715 3.08276 1.65234 3.11353C1.72754 3.14429 1.7959 3.18701 1.85742 3.2417L6 7.40479L10.1426 3.2417C10.2041 3.18701 10.2725 3.14429 10.3477 3.11353C10.4229 3.08276 10.5015 3.06738 10.5835 3.06738C10.7681 3.06738 10.9236 3.13062 11.05 3.25708C11.1765 3.38354 11.2397 3.53564 11.2397 3.71338C11.2397 3.80225 11.2227 3.88428 11.1885 3.95947C11.1543 4.03467 11.1133 4.09961 11.0654 4.1543L6.46143 8.7583C6.3999 8.81982 6.32983 8.86768 6.25122 8.90186C6.17261 8.93604 6.08887 8.95312 6 8.95312Z" fill="#99A3A9"></path></g><defs><clipPath id="clip0_33663_12905"><rect width="10.5" height="11" fill="white" transform="matrix(1 0 0 -1 0.75 11.5)"></rect></clipPath></defs></svg>', 1))
3128
+ k[1] || (k[1] = Wt('<svg xmlns="http://www.w3.org/2000/svg" width="12" height="12" viewBox="0 0 12 12" fill="none"><g clip-path="url(#clip0_33663_12905)"><path d="M6 8.95312C5.91113 8.95312 5.82739 8.93604 5.74878 8.90186C5.67017 8.86768 5.6001 8.81982 5.53857 8.7583L0.93457 4.1543C0.886719 4.09961 0.845703 4.03467 0.811523 3.95947C0.777344 3.88428 0.760254 3.80225 0.760254 3.71338C0.760254 3.53564 0.823486 3.38354 0.949951 3.25708C1.07642 3.13062 1.23193 3.06738 1.4165 3.06738C1.49854 3.06738 1.57715 3.08276 1.65234 3.11353C1.72754 3.14429 1.7959 3.18701 1.85742 3.2417L6 7.40479L10.1426 3.2417C10.2041 3.18701 10.2725 3.14429 10.3477 3.11353C10.4229 3.08276 10.5015 3.06738 10.5835 3.06738C10.7681 3.06738 10.9236 3.13062 11.05 3.25708C11.1765 3.38354 11.2397 3.53564 11.2397 3.71338C11.2397 3.80225 11.2227 3.88428 11.1885 3.95947C11.1543 4.03467 11.1133 4.09961 11.0654 4.1543L6.46143 8.7583C6.3999 8.81982 6.32983 8.86768 6.25122 8.90186C6.17261 8.93604 6.08887 8.95312 6 8.95312Z" fill="#99A3A9"></path></g><defs><clipPath id="clip0_33663_12905"><rect width="10.5" height="11" fill="white" transform="matrix(1 0 0 -1 0.75 11.5)"></rect></clipPath></defs></svg>', 1))
3128
3129
  ])
3129
3130
  ], 2)) : S("", !0)
3130
3131
  ], 2),
@@ -3136,30 +3137,33 @@ const Bn = ["data-active"], Nn = /* @__PURE__ */ A({
3136
3137
  "leave-from-class": "cstu-transform cstu-opacity-100 cstu-scale-100",
3137
3138
  "leave-to-class": "cstu-transform cstu-opacity-0 cstu-scale-95"
3138
3139
  }, {
3139
- default: le(() => [
3140
- (f(), q(Ye, { to: "body" }, [
3141
- me(z("div", {
3142
- ref_key: "dropdownList",
3143
- ref: r,
3144
- style: E(_(u)),
3145
- class: $(["cstu-dropdown-menu cstu-max-h-72 cstu-px-[12px] cstu-py-[13px] cstu-min-w-[225px] cstu-overflow-y-auto cstu-origin-top-left cstu-rounded-lg cstu-shadow-custom cstu-bg-white focus:cstu-outline-none cstu-z-50", [x.value, d.dropdownClasses]])
3146
- }, [
3147
- z("div", {
3148
- class: "cstu-flex cstu-flex-col cstu-gap-[11px]",
3149
- role: "menu",
3150
- "aria-orientation": "vertical",
3151
- "aria-labelledby": "menu-button",
3152
- "data-active": a.value,
3153
- tabindex: "-1",
3154
- onKeydown: w
3140
+ default: le(() => {
3141
+ var C;
3142
+ return [
3143
+ (f(), q(Ye, { to: "body" }, [
3144
+ me(z("div", {
3145
+ ref_key: "dropdownList",
3146
+ ref: r,
3147
+ style: E([_(u), e.matchWidth ? { width: ((C = l.value) == null ? void 0 : C.offsetWidth) + "px" } : {}]),
3148
+ class: $(["cstu-dropdown-menu cstu-max-h-72 cstu-px-[12px] cstu-py-[13px] cstu-min-w-[225px] cstu-overflow-y-auto cstu-origin-top-left cstu-rounded-lg cstu-shadow-custom cstu-bg-white focus:cstu-outline-none cstu-z-50", [x.value, d.dropdownClasses]])
3155
3149
  }, [
3156
- O(d.$slots, "default", { closeDropdown: v })
3157
- ], 40, Bn)
3158
- ], 6), [
3159
- [De, n.value]
3160
- ])
3161
- ]))
3162
- ]),
3150
+ z("div", {
3151
+ class: "cstu-flex cstu-flex-col cstu-gap-[11px]",
3152
+ role: "menu",
3153
+ "aria-orientation": "vertical",
3154
+ "aria-labelledby": "menu-button",
3155
+ "data-active": a.value,
3156
+ tabindex: "-1",
3157
+ onKeydown: w
3158
+ }, [
3159
+ O(d.$slots, "default", { closeDropdown: v })
3160
+ ], 40, Bn)
3161
+ ], 6), [
3162
+ [De, n.value]
3163
+ ])
3164
+ ]))
3165
+ ];
3166
+ }),
3163
3167
  _: 3
3164
3168
  })
3165
3169
  ], 2)), [
@@ -3418,7 +3422,7 @@ export {
3418
3422
  Pn as Chip,
3419
3423
  In as Collapse,
3420
3424
  Yn as Collapsible,
3421
- Fn as Dialog,
3425
+ Wn as Dialog,
3422
3426
  Nn as Dropdown,
3423
3427
  qn as DropdownItem,
3424
3428
  vn as HoverCard,
@@ -3431,7 +3435,7 @@ export {
3431
3435
  Kn as SegmentedControl,
3432
3436
  Vn as Select,
3433
3437
  Dn as TextInput,
3434
- Wn as composables,
3438
+ Fn as composables,
3435
3439
  Dt as hoverCardInjectionKey,
3436
3440
  yn as useHoverCard
3437
3441
  };
@@ -1 +1 @@
1
- (function(B,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],e):(B=typeof globalThis<"u"?globalThis:B||self,e(B.ContentStudioDesignSystem={},B.Vue))})(this,function(B,e){"use strict";const ge={primary:{base:"blue",light:"50",main:"500",dark:"600",hover:"550",border:"600",focus:"600"},secondary:{base:"gray",light:"200",main:"575",dark:"700",hover:"600",border:"600",focus:"500"},success:{base:"green",light:"50",main:"500",dark:"700",hover:"600",border:"200",focus:"500"},warning:{base:"yellow",light:"50",main:"500",dark:"700",hover:"600",border:"200",focus:"500"},danger:{base:"red",light:"50",main:"500",dark:"700",hover:"600",border:"200",focus:"500"},info:{base:"sea-blue",light:"50",main:"500",dark:"700",hover:"600",border:"200",focus:"500"},dark:{base:"gray",light:"100",main:"900",dark:"950",hover:"800",border:"300",focus:"700"},light:{base:"gray",light:"50",main:"300",dark:"500",hover:"400",border:"200",focus:"300"}},F=(o,s,t={})=>{const{hover:l=!1,active:n=!1,focus:r=!1,disabled:i=!1}=t;if(i)return"cstu-bg-gray-100 cstu-border-gray-200 cstu-text-gray-400 cstu-cursor-not-allowed";const a=ge[o];if(!a||s==="default")return"";if(s==="text")return[`cstu-text-${a.base}-${a.main}`,l&&`hover:cstu-text-${a.base}-${a.hover}`,n&&`active:cstu-text-${a.base}-${a.dark}`,r&&`focus:cstu-text-${a.base}-${a.focus}`,i&&"cstu-opacity-50 cstu-cursor-not-allowed"].filter(Boolean);const c=[];switch(s){case"filled":c.push(`cstu-bg-${a.base}-${a.main}`),c.push("cstu-text-white"),l&&c.push(`hover:cstu-bg-${a.base}-${a.hover} hover:cstu-shadow-md`),n&&c.push(`active:cstu-bg-${a.base}-${a.dark}`),r&&c.push(`focus:cstu-ring-${a.base}-${a.focus}/20`);break;case"light":c.push(`cstu-bg-${a.base}-${a.light}`),c.push(`cstu-text-${a.base}-${a.main}`),l&&c.push(`hover:cstu-bg-${a.base}-250`),n&&c.push(`active:cstu-bg-${a.base}-300 active:!cstu-text-white`),r&&c.push(`focus:cstu-ring-${a.base}-${a.focus}/20`);break;case"outline":c.push("cstu-bg-white"),c.push(`cstu-text-${a.base}-${a.main}`),c.push(`cstu-border cstu-border-${a.base}-${a.main}`),l&&c.push(`hover:cstu-bg-${a.base}-50`),n&&c.push(`active:cstu-bg-${a.base}-100`),r&&c.push(`focus:cstu-ring-${a.base}-${a.focus}/20`);break;case"subtle":c.push(`cstu-text-${a.base}-${a.main}`),l&&c.push(`hover:cstu-bg-${a.base}-50`),n&&c.push(`active:cstu-bg-${a.base}-100`),r&&c.push(`focus:cstu-ring-${a.base}-${a.focus}/20`);break;case"white":c.push("cstu-bg-white cstu-text-gray-900"),l&&c.push("hover:cstu-bg-gray-50"),n&&c.push("active:cstu-bg-gray-100"),r&&c.push("focus:cstu-ring-gray-200");break;case"dot":c.push(`cstu-bg-${a.base}-${a.main}`);break;case"bordered":c.push("cstu-bg-white"),c.push(`cstu-text-${a.base}-${a.main}`),c.push(`cstu-border cstu-border-${a.base}-${a.border}`),l&&c.push(`hover:cstu-bg-${a.base}-50 hover:cstu-border-${a.base}-${a.main}`),n&&c.push(`active:cstu-bg-${a.base}-100`),r&&c.push(`focus:cstu-ring-${a.base}-${a.focus}/20`);break;case"bordered-transparent":c.push("cstu-bg-transparent"),c.push(`cstu-text-${a.base}-${a.main}`),c.push(`cstu-border cstu-border-${a.base}-${a.border}`),l&&c.push(`hover:cstu-bg-${a.base}-50/10 hover:cstu-border-${a.base}-${a.main}`),n&&c.push(`active:cstu-bg-${a.base}-100/20`),r&&c.push(`focus:cstu-ring-${a.base}-${a.focus}/20`);break}return c.join(" ")},rt=(o,s)=>{if(s==="filled")return"cstu-text-white";const t=ge[o];return`cstu-text-${t.base}-${t.main}`},at=(o,s)=>{if(s==="filled")return"cstu-text-white";const t=ge[o];return`cstu-text-${t.base}-${t.main}`},it=o=>{const s=["cstu-shadow-sm","cstu-transition-all cstu-duration-200"];switch(o){case"filled":s.push("cstu-border-transparent");break;case"light":s.push("cstu-border");break;case"outline":s.push("cstu-border");break;case"subtle":s.push("cstu-shadow-none");break;case"white":s.push("cstu-border");break;default:s.push("cstu-border")}return s.join(" ")},he={button:{xs:{height:"cstu-h-[30px]",gap:"cstu-gap-[0.55rem]",padding:{x:"cstu-px-[0.67rem]",y:"cstu-py-[0.67rem]"},text:"cstu-text-xs cstu-leading-none",icon:"cstu-w-3 cstu-h-3"},sm:{height:"cstu-h-[36px]",gap:"cstu-gap-[0.66rem]",padding:{x:"cstu-px-[0.8rem]",y:"cstu-py-[0.8rem]"},text:"cstu-text-sm cstu-leading-none",icon:"cstu-w-4 cstu-h-4"},md:{height:"cstu-h-[40px]",gap:"cstu-gap-[0.74rem]",padding:{x:"cstu-px-[0.89rem]",y:"cstu-py-[0.89rem]"},text:"cstu-text-base cstu-leading-none",icon:"cstu-w-5 cstu-h-5"},lg:{height:"cstu-h-[45px]",gap:"cstu-gap-[0.83rem]",padding:{x:"cstu-px-4",y:"cstu-py-4"},text:"cstu-text-lg cstu-leading-none",icon:"cstu-w-6 cstu-h-6"},xl:{height:"cstu-h-[50px]",gap:"cstu-gap-[0.92rem]",padding:{x:"cstu-px-[1.11rem]",y:"cstu-py-[1.11rem]"},text:"cstu-text-xl cstu-leading-none",icon:"cstu-w-7 cstu-h-7"}},badge:{xs:{padding:{x:"cstu-px-2",y:"cstu-py-0.5"},text:"cstu-text-xs",icon:"cstu-w-3 cstu-h-3"},sm:{padding:{x:"cstu-px-2.5",y:"cstu-py-1"},text:"cstu-text-sm",icon:"cstu-w-3.5 cstu-h-3.5"},md:{padding:{x:"cstu-px-3",y:"cstu-py-1.5"},text:"cstu-text-base",icon:"cstu-w-4 cstu-h-4"},lg:{padding:{x:"cstu-px-4",y:"cstu-py-2"},text:"cstu-text-lg",icon:"cstu-w-5 cstu-h-5"},xl:{padding:{x:"cstu-px-5",y:"cstu-py-2.5"},text:"cstu-text-xl",icon:"cstu-w-6 cstu-h-6"}},input:{xs:{padding:{x:"cstu-px-2",y:"cstu-py-1"},text:"cstu-text-xs",height:"cstu-h-7"},sm:{padding:{x:"cstu-px-3",y:"cstu-py-1.5"},text:"cstu-text-sm",height:"cstu-h-8"},md:{padding:{x:"cstu-px-3",y:"cstu-py-2"},text:"cstu-text-base",height:"cstu-h-10"},lg:{padding:{x:"cstu-px-4",y:"cstu-py-2.5"},text:"cstu-text-lg",height:"cstu-h-11"},xl:{padding:{x:"cstu-px-4",y:"cstu-py-3"},text:"cstu-text-xl",height:"cstu-h-12"}},notification:{xs:{padding:{x:"cstu-px-3",y:"cstu-py-2"},text:"cstu-text-xs"},sm:{padding:{x:"cstu-px-4",y:"cstu-py-2.5"},text:"cstu-text-sm"},md:{padding:{x:"cstu-px-4",y:"cstu-py-3"},text:"cstu-text-base"},lg:{padding:{x:"cstu-px-5",y:"cstu-py-4"},text:"cstu-text-lg"},xl:{padding:{x:"cstu-px-6",y:"cstu-py-5"},text:"cstu-text-xl"}},switch:{xs:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-xs",height:"cstu-h-4"},sm:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-sm",height:"cstu-h-5"},md:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-base",height:"cstu-h-6"},lg:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-lg",height:"cstu-h-7"},xl:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-xl",height:"cstu-h-8"}},chip:{xs:{padding:{x:"cstu-px-1.5",y:"cstu-py-0.5"},text:"cstu-text-xs",icon:"cstu-w-2.5 cstu-h-2.5"},sm:{padding:{x:"cstu-px-2",y:"cstu-py-1"},text:"cstu-text-sm",icon:"cstu-w-3 cstu-h-3"},md:{padding:{x:"cstu-px-2.5",y:"cstu-py-1.5"},text:"cstu-text-base",icon:"cstu-w-3.5 cstu-h-3.5"},lg:{padding:{x:"cstu-px-3",y:"cstu-py-2"},text:"cstu-text-lg",icon:"cstu-w-4 cstu-h-4"},xl:{padding:{x:"cstu-px-3.5",y:"cstu-py-2.5"},text:"cstu-text-xl",icon:"cstu-w-4.5 cstu-h-4.5"}},checkbox:{xs:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-xs",icon:"cstu-w-2 cstu-h-2"},sm:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-sm",icon:"cstu-w-2.5 cstu-h-2.5"},md:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-base",icon:"cstu-w-3 cstu-h-3"},lg:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-lg",icon:"cstu-w-4 cstu-h-4"},xl:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-xl",icon:"cstu-w-5 cstu-h-5"}},indicator:{xs:{padding:{x:"cstu-px-0.5",y:"cstu-py-0.5"},text:"cstu-text-[10px]",height:"cstu-h-3.5 cstu-min-w-3.5"},sm:{padding:{x:"cstu-px-1",y:"cstu-py-0.5"},text:"cstu-text-[11px]",height:"cstu-h-4 cstu-min-w-4"},md:{padding:{x:"cstu-px-1.5",y:"cstu-py-0.5"},text:"cstu-text-xs",height:"cstu-h-5 cstu-min-w-5"},lg:{padding:{x:"cstu-px-2",y:"cstu-py-0.5"},text:"cstu-text-xs",height:"cstu-h-6 cstu-min-w-6"},xl:{padding:{x:"cstu-px-2.5",y:"cstu-py-0.5"},text:"cstu-text-sm",height:"cstu-h-7 cstu-min-w-7"}},progress:{xs:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-xs",height:"cstu-h-1"},sm:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-sm",height:"cstu-h-1.5"},md:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-base",height:"cstu-h-2"},lg:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-sm",height:"cstu-h-6"},xl:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-base",height:"cstu-h-8"}},alert:{xs:{padding:{x:"cstu-px-3",y:"cstu-py-2"},text:"cstu-text-xs",icon:"cstu-w-4 cstu-h-4"},sm:{padding:{x:"cstu-px-3",y:"cstu-py-2.5"},text:"cstu-text-sm",icon:"cstu-w-5 cstu-h-5"},md:{padding:{x:"cstu-px-4",y:"cstu-py-3"},text:"cstu-text-base",icon:"cstu-w-5 cstu-h-5"},lg:{padding:{x:"cstu-px-5",y:"cstu-py-4"},text:"cstu-text-lg",icon:"cstu-w-6 cstu-h-6"},xl:{padding:{x:"cstu-px-6",y:"cstu-py-5"},text:"cstu-text-xl",icon:"cstu-w-7 cstu-h-7"}},segmentedControl:{xs:{gap:"cstu-gap-[8px]",padding:{x:"cstu-px-[10.5px]",y:"cstu-py-[3.5px]"},text:"cstu-text-xs",height:"cstu-h-6"},sm:{gap:"cstu-gap-[9px]",padding:{x:"cstu-px-[12px]",y:"cstu-py-[4px]"},text:"cstu-text-sm",height:"cstu-h-8"},md:{gap:"cstu-gap-[10px]",padding:{x:"cstu-px-[13.5px]",y:"cstu-py-[4.5px]"},text:"cstu-text-base",height:"cstu-h-10"},lg:{gap:"cstu-gap-[11px]",padding:{x:"cstu-px-[15px]",y:"cstu-py-[5px]"},text:"cstu-text-lg",height:"cstu-h-12"},xl:{gap:"cstu-gap-[12px]",padding:{x:"cstu-px-[16.5px]",y:"cstu-py-[5.5px]"},text:"cstu-text-xl",height:"cstu-h-14"}},segmentedControlContainer:{xs:{gap:"cstu-gap-[5.25px]",padding:{x:"cstu-px-[5.25px]",y:"cstu-py-[5.25px]"}},sm:{gap:"cstu-gap-[6px]",padding:{x:"cstu-px-[6px]",y:"cstu-py-[6px]"}},md:{gap:"cstu-gap-[6.75px]",padding:{x:"cstu-px-[6.75px]",y:"cstu-py-[6.75px]"}},lg:{gap:"cstu-gap-[7.5px]",padding:{x:"cstu-px-[7.5px]",y:"cstu-py-[7.5px]"}},xl:{gap:"cstu-gap-[8.25px]",padding:{x:"cstu-px-[8.25px]",y:"cstu-py-[8.25px]"}}},dropdown:{xs:{padding:{x:"cstu-px-[12px]",y:"cstu-py-[7px]"},text:"cstu-text-xs",height:void 0,icon:void 0,gap:"cstu-gap-[9px]"},sm:{padding:{x:"cstu-px-[12px]",y:"cstu-py-[7px]"},text:"cstu-text-sm",height:void 0,icon:void 0,gap:"cstu-gap-[9px]"},md:{padding:{x:"cstu-px-[12px]",y:"cstu-py-[7px]"},text:"cstu-text-base",height:void 0,icon:void 0,gap:"cstu-gap-[9px]"},lg:{padding:{x:"cstu-px-[12px]",y:"cstu-py-[7px]"},text:"cstu-text-lg",height:void 0,icon:void 0,gap:"cstu-gap-[9px]"},xl:{padding:{x:"cstu-px-[12px]",y:"cstu-py-[7px]"},text:"cstu-text-xl",height:void 0,icon:void 0,gap:"cstu-gap-[9px]"}}},N=(o,s)=>{var t,l;if(typeof s=="string"){const n=he[s][o];return[(t=n==null?void 0:n.padding)==null?void 0:t.x,(l=n==null?void 0:n.padding)==null?void 0:l.y,n==null?void 0:n.text,n==null?void 0:n.gap].filter(Boolean).join(" ")}return s[o]},ct=(o,s)=>he[s][o].icon||"",ae=(o,s)=>he[s][o].height||"",ye=o=>{switch(o){case"xs":return"cstu-text-xs";case"sm":return"cstu-text-sm";case"md":return"cstu-text-base";case"lg":return"cstu-text-lg";case"xl":return"cstu-text-xl";default:return"cstu-text-base"}},Ae=o=>{switch(o){case"xs":return"cstu-space-x-1";case"sm":return"cstu-space-x-2";case"md":return"cstu-space-x-3";case"lg":return"cstu-space-x-4";case"xl":return"cstu-space-x-5";default:return"cstu-space-x-3"}},W=o=>{const s=[];return o.disabled&&s.push("cstu-opacity-50 cstu-cursor-not-allowed cstu-pointer-events-none"),o.loading&&s.push("cstu-cursor-wait"),o.active&&s.push("cstu-ring-2 cstu-ring-offset-2"),o.error&&s.push("cstu-border-red-300 focus:cstu-ring-red-500/20 focus:cstu-border-red-500"),o.success&&s.push("cstu-border-green-300 focus:cstu-ring-green-500/20 focus:cstu-border-green-500"),s.join(" ")},dt=o=>o?"cstu-opacity-50 cstu-cursor-not-allowed cstu-pointer-events-none":"",ut=o=>{const s=[];return o.valid&&s.push("cstu-border-green-300 focus:cstu-ring-green-500/20 focus:cstu-border-green-500"),o.invalid&&s.push("cstu-border-red-300 focus:cstu-ring-red-500/20 focus:cstu-border-red-500"),o.pending&&s.push("cstu-border-yellow-300 focus:cstu-ring-yellow-500/20 focus:cstu-border-yellow-500"),s.join(" ")},pt=(o,s="primary")=>{const t=[];return o.hover&&t.push(`hover:cstu-bg-${s}-50`),o.active&&t.push(`active:cstu-bg-${s}-100`),o.focus&&t.push(`focus:cstu-outline-none focus:cstu-ring-2 focus:cstu-ring-${s}-500/20 focus:cstu-border-${s}-500`),t.join(" ")},ft=["disabled","type"],mt={key:0},gt=e.defineComponent({__name:"Button",props:{variant:{default:"filled"},color:{default:"primary"},size:{default:"md"},radius:{default:"md"},disabled:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},fullWidth:{type:Boolean,default:!1},type:{default:"button"},gradient:{}},emits:{click:o=>!0},setup(o,{emit:s}){const t=o,l=s,n=c=>{!t.disabled&&!t.loading&&l("click",c)},r=c=>({none:"cstu-rounded-none",xs:"cstu-rounded",sm:"cstu-rounded-md",md:"cstu-rounded-lg",lg:"cstu-rounded-xl",xl:"cstu-rounded-2xl",full:"cstu-rounded-full"})[c]||"cstu-rounded-lg",i=c=>{if(!c)return"bg-gradient-to-r";const d=(c%360+360)%360;return d>=337.5||d<22.5?"cstu-bg-gradient-to-r":d>=22.5&&d<67.5?"cstu-bg-gradient-to-tr":d>=67.5&&d<112.5?"cstu-bg-gradient-to-t":d>=112.5&&d<157.5?"cstu-bg-gradient-to-tl":d>=157.5&&d<202.5?"cstu-bg-gradient-to-l":d>=202.5&&d<247.5?"cstu-bg-gradient-to-bl":d>=247.5&&d<292.5?"cstu-bg-gradient-to-b":"cstu-bg-gradient-to-br"},a=e.computed(()=>{const c="cstu-inline-flex cstu-items-center cstu-justify-center cstu-font-medium cstu-transition-all cstu-duration-200";if(t.variant==="gradient"&&t.gradient){const b=`${i(t.gradient.deg)} cstu-from-${t.gradient.from}-500 cstu-to-${t.gradient.to||t.gradient.from}-600 hover:cstu-from-${t.gradient.from}-600 hover:cstu-to-${t.gradient.to||t.gradient.from}-700 cstu-text-white`;return[c,b,N(t.size,"button"),r(t.radius),W({disabled:t.disabled,loading:t.loading}),{"cstu-w-full":t.fullWidth,"cstu-cursor-pointer":!t.disabled&&!t.loading}]}const d=F(t.color,t.variant,{hover:!0,active:!0,focus:!0}),u=N(t.size,"button"),f=W({disabled:t.disabled,loading:t.loading}),m=ae(t.size,"button"),h=r(t.radius);return[c,d,u,m,f,h,{"cstu-w-full":t.fullWidth,"cstu-cursor-pointer":!t.disabled&&!t.loading}]});return(c,d)=>(e.openBlock(),e.createElementBlock("button",{class:e.normalizeClass(a.value),disabled:c.disabled||c.loading,type:c.type,onClick:n},[e.renderSlot(c.$slots,"leftSection"),e.renderSlot(c.$slots,"default"),c.loading?(e.openBlock(),e.createElementBlock("span",mt,[e.renderSlot(c.$slots,"loader",{},()=>[d[0]||(d[0]=e.createElementVNode("svg",{class:"cstu-animate-spin cstu-h-4 cstu-w-4",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24"},[e.createElementVNode("circle",{class:"cstu-opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor","stroke-width":"4"}),e.createElementVNode("path",{class:"cstu-opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"})],-1))])])):e.createCommentVNode("",!0),e.renderSlot(c.$slots,"rightSection")],10,ft))}}),_e=o=>{const s=["cstu-relative"];o.fullWidth&&s.push("cstu-w-full");const t=W({disabled:o.disabled,error:o.error,required:o.required||o.withAsterisk});return t&&s.push(t),s.join(" ")},xe=o=>{const s=["cstu-block","cstu-font-medium","cstu-mb-1"];switch(o.size){case"xs":s.push("cstu-text-xs");break;case"sm":s.push("cstu-text-sm");break;case"md":s.push("cstu-text-base");break;case"lg":s.push("cstu-text-lg");break;case"xl":s.push("cstu-text-xl");break;default:s.push("cstu-text-sm")}return o.error?s.push("cstu-text-red-500"):o.disabled?s.push("cstu-text-gray-400"):s.push("cstu-text-gray-700"),(o.required||o.withAsterisk)&&s.push('after:cstu-content-["*"] after:cstu-ml-0.5 after:cstu-text-red-500'),s.join(" ")},Pe=o=>{const s=["cstu-mt-1","cstu-text-sm"];return o.error?s.push("cstu-text-red-500"):o.disabled?s.push("cstu-text-gray-400"):s.push("cstu-text-gray-500"),s.join(" ")},ht=["aria-disabled","onKeydown"],yt={key:2,class:"cstu-text-sm cstu-text-red-500 cstu-mt-0.5"},xt={name:"Checkbox"},bt=e.defineComponent({...xt,props:{modelValue:{type:[Boolean,Array],default:!1},checked:{type:Boolean,default:!1},value:{},id:{},label:{},color:{default:"primary"},size:{default:"md"},labelPosition:{default:"right"},description:{},error:{},disabled:{type:Boolean,default:!1},indeterminate:{type:Boolean,default:!1},variant:{default:"filled"}},emits:["update:modelValue","change"],setup(o,{emit:s}){const t=o,l=s,n=e.computed(()=>t.modelValue||t.checked),r=()=>{if(t.disabled)return;const y=!n.value;l("update:modelValue",y),l("change",y)},i=()=>{r()},a=e.computed(()=>xe({size:t.size,disabled:t.disabled,error:t.error})),c=e.computed(()=>Pe({color:t.color})),d=e.computed(()=>["cstu-flex","cstu-flex-col",t.labelPosition==="left"?"cstu-order-first":""]),u={primary:"blue-450",secondary:"gray-500",success:"green-500",warning:"yellow-500",danger:"red-500",info:"blue-500",dark:"gray-900",light:"gray-300"},f=e.computed(()=>["cstu-inline-flex","cstu-items-center","cstu-justify-center","cstu-cursor-pointer","cstu-transition-colors","cstu-duration-200","cstu-ease-in-out",t.size==="xs"?"cstu-h-[12px] cstu-w-[12px] cstu-rounded":"",t.size==="sm"?"cstu-h-[14px] cstu-w-[14px] cstu-rounded":"",t.size==="md"?"cstu-h-[16px] cstu-w-[16px] cstu-rounded-md":"",t.size==="lg"?"cstu-h-[18px] cstu-w-[18px] cstu-rounded-md":"",t.size==="xl"?"cstu-h-[20px] cstu-w-[20px] cstu-rounded-md":"",t.disabled?"cstu-bg-gray-200 cstu-border cstu-border-gray-200 cstu-cursor-not-allowed":n.value||t.indeterminate?t.variant==="outlined"?`cstu-bg-transparent cstu-border cstu-border-${u[t.color]}`:`cstu-bg-${u[t.color]} cstu-border-${u[t.color]}`:"cstu-bg-white cstu-border cstu-border-gray-400/50"]),m=e.computed(()=>[t.variant==="outlined"&&(n.value||t.indeterminate)?`cstu-text-${u[t.color]}`:t.disabled?"cstu-text-gray-300":"cstu-text-white",t.size==="xs"?"cstu-h-[6px] cstu-w-[6px]":"",t.size==="sm"?"cstu-h-[7px] cstu-w-[7px]":"",t.size==="md"?"cstu-h-[8px] cstu-w-[8px]":"",t.size==="lg"?"cstu-h-[9px] cstu-w-[9px]":"",t.size==="xl"?"cstu-h-[10px] cstu-w-[10px]":""]),h=e.computed(()=>_e({disabled:t.disabled,error:t.error}));return(y,g)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass([h.value,"cstu-flex cstu-items-center cstu-gap-2"])},[e.createElementVNode("div",{class:e.normalizeClass(f.value),onClick:i,role:"checkbox","aria-disabled":y.disabled,tabindex:"0",onKeydown:e.withKeys(e.withModifiers(i,["prevent"]),["space"])},[n.value&&!y.indeterminate?(e.openBlock(),e.createElementBlock("svg",{key:0,class:e.normalizeClass(m.value),xmlns:"http://www.w3.org/2000/svg",width:"8",height:"6",viewBox:"0 0 8 6",fill:"none"},g[0]||(g[0]=[e.createElementVNode("path",{d:"M6.75 0.75L2.625 5.25L0.75 3.20455",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)]),2)):e.createCommentVNode("",!0),y.indeterminate?(e.openBlock(),e.createElementBlock("svg",{key:1,class:e.normalizeClass(m.value),xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 8 7",fill:"none"},g[1]||(g[1]=[e.createElementVNode("path",{d:"M6.80245 3.90741L0.697913 3.8936",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)]),2)):e.createCommentVNode("",!0)],42,ht),y.label||y.description?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(d.value)},[y.label?(e.openBlock(),e.createElementBlock("label",{key:0,class:e.normalizeClass([a.value,"cstu-pt-0.5"]),onClick:i},e.toDisplayString(y.label),3)):e.createCommentVNode("",!0),y.description?(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(c.value)},e.toDisplayString(y.description),3)):e.createCommentVNode("",!0),y.error?(e.openBlock(),e.createElementBlock("div",yt,e.toDisplayString(y.error),1)):e.createCommentVNode("",!0)],2)):e.createCommentVNode("",!0)],2))}}),wt=["aria-checked","aria-disabled"],Ct=["id","checked","disabled","value"],kt=["for"],Bt=e.defineComponent({__name:"Radio",props:{modelValue:{default:void 0},value:{default:void 0},id:{default:()=>`radio-${Math.random().toString(36).substr(2,9)}`},label:{},color:{default:"primary"},size:{default:"md"},labelPosition:{default:"right"},description:{},error:{},disabled:{type:Boolean,default:!1},variant:{default:"filled"}},emits:["update:modelValue","change"],setup(o,{emit:s}){const t=o,l={primary:"blue-450",secondary:"gray-500",success:"green-500",warning:"yellow-500",danger:"red-500",info:"blue-500",dark:"gray-900",light:"gray-300"},n={primary:"blue-300",secondary:"gray-300",success:"green-300",warning:"yellow-300",danger:"red-300",info:"blue-300",dark:"gray-300",light:"gray-300"},r=s,i=e.computed(()=>t.modelValue===t.value),a=()=>{t.disabled||(r("update:modelValue",t.value),r("change",t.value))},c=e.computed(()=>[_e({disabled:t.disabled,error:t.error}),"cstu-flex cstu-items-center cstu-gap-2",t.labelPosition==="left"?"cstu-flex-row-reverse":"cstu-flex-row"]),d=e.computed(()=>["cstu-relative cstu-flex cstu-items-center cstu-justify-center cstu-rounded-full cstu-transition-colors cstu-duration-200",g.value,i.value?t.variant==="outlined"?`cstu-bg-white !cstu-border-2 cstu-border-${n[t.color]}`:`cstu-bg-${l[t.color]} cstu-border cstu-border-${l[t.color]}`:t.variant==="outlined"?`cstu-bg-white !cstu-border-2 cstu-border-${n[t.color]}`:"cstu-bg-white cstu-border cstu-border-gray-300 hover:cstu-border-gray-400",t.disabled?"cstu-opacity-50 cstu-cursor-not-allowed !cstu-bg-gray-200 !cstu-border-gray-300":"cstu-cursor-pointer"]),u=e.computed(()=>["cstu-rounded-full",b.value,t.variant==="outlined"?`cstu-bg-${l[t.color]}`:"cstu-bg-white",t.disabled?`cstu-opacity-50 ${t.variant==="outlined"?"!cstu-bg-gray-300":"!cstu-bg-gray-200"}`:""]),f=e.computed(()=>xe({size:t.size,disabled:t.disabled,error:t.error})),m=e.computed(()=>Pe({color:t.color})),h=e.computed(()=>["cstu-text-sm cstu-text-red-500 cstu-mt-1"]),y=e.computed(()=>["cstu-flex cstu-flex-col",t.disabled?"cstu-cursor-not-allowed":"cstu-cursor-pointer"]),g=e.computed(()=>({xs:"cstu-w-[8px] cstu-h-[8px]",sm:"cstu-w-[12px] cstu-h-[12px]",md:"cstu-w-[16px] cstu-h-[16px]",lg:"cstu-w-[20px] cstu-h-[20px]",xl:"cstu-w-[24px] cstu-h-[24px]"})[t.size]),b=e.computed(()=>({xs:"cstu-w-[4px] cstu-h-[4px]",sm:"cstu-w-[6px] cstu-h-[6px]",md:"cstu-w-[8px] cstu-h-[8px]",lg:"cstu-w-[10px] cstu-h-[10px]",xl:"cstu-w-[12px] cstu-h-[12px]"})[t.size]);return(x,p)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(c.value),onClick:a,"aria-checked":i.value,"aria-disabled":x.disabled,role:"radio"},[e.createElementVNode("input",{ref:"radio",type:"radio",id:x.id,checked:i.value,disabled:x.disabled,value:x.value,onChange:a,class:"cstu-sr-only cstu-border-2"},null,40,Ct),e.createElementVNode("div",{class:e.normalizeClass(d.value)},[i.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass([u.value,"cstu-absolute cstu-left-1/2 cstu-top-1/2 cstu--translate-x-1/2 cstu--translate-y-1/2 cstu-transition-transform cstu-duration-200 cstu-ease-in-out"])},null,2)):e.createCommentVNode("",!0)],2),e.createElementVNode("div",{class:e.normalizeClass(y.value)},[x.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:x.id,class:e.normalizeClass(f.value)},[e.renderSlot(x.$slots,"label",{},()=>[e.createTextVNode(e.toDisplayString(x.label),1)])],10,kt)):e.createCommentVNode("",!0),x.description?(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(m.value)},[e.renderSlot(x.$slots,"description",{},()=>[e.createTextVNode(e.toDisplayString(x.description),1)])],2)):e.createCommentVNode("",!0),x.error?(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass(h.value)},[e.renderSlot(x.$slots,"error",{},()=>[e.createTextVNode(e.toDisplayString(x.error),1)])],2)):e.createCommentVNode("",!0)],2)],10,wt))}}),zt=["for"],$t={key:0,class:"text-red-500","aria-hidden":"true"},Et={class:"relative"},Vt=["id","type","value","placeholder","disabled","required"],St=e.defineComponent({__name:"TextInput",props:{id:{},type:{default:"text"},modelValue:{},placeholder:{},disabled:{type:Boolean,default:!1},label:{},labelProps:{},description:{},descriptionProps:{},error:{},errorProps:{},wrapperProps:{},inputProps:{},size:{default:"md"},radius:{default:"md"},rightSection:{},rightSectionProps:{},leftSection:{},leftSectionProps:{},withAsterisk:{type:Boolean,default:!1},required:{type:Boolean,default:!1}},emits:["update:modelValue"],setup(o){const s=o,t=n=>({none:"rounded-none",xs:"rounded",sm:"rounded-md",md:"rounded-lg",lg:"rounded-xl",xl:"rounded-2xl",full:"rounded-full"})[n]||"rounded-lg",l=e.computed(()=>{const n=["block w-full bg-white transition-all duration-200","border border-gray-200","text-gray-900","focus:outline-none focus:ring-2 focus:ring-offset-0 focus:border-transparent","placeholder:text-gray-400","shadow-sm"],r=N(s.size,"input"),i=N(s.size,"input"),a=W({disabled:s.disabled,error:s.withError||!!s.error}),c=t(s.radius),d={left:s.leftSection?"pl-10":"",right:s.rightSection?"pr-10":""},u=s.disabled?"":[s.withError||s.error?"focus:ring-red-500/20 focus:border-red-500":"focus:ring-blue-500/20 focus:border-blue-500","hover:border-gray-300"];return[...n,r,i,a,c,d.left,d.right,u].filter(Boolean).join(" ")});return(n,r)=>(e.openBlock(),e.createElementBlock("div",e.mergeProps({class:["relative flex flex-col",{"opacity-50 pointer-events-none":n.disabled}]},n.wrapperProps),[n.label?(e.openBlock(),e.createElementBlock("label",e.mergeProps({key:0,for:n.id,class:"mb-1 text-sm font-medium text-gray-700 flex items-center gap-1"},n.labelProps),[e.createTextVNode(e.toDisplayString(n.label)+" ",1),n.required||n.withAsterisk?(e.openBlock(),e.createElementBlock("span",$t,"*")):e.createCommentVNode("",!0)],16,zt)):e.createCommentVNode("",!0),e.createElementVNode("div",Et,[n.leftSection?(e.openBlock(),e.createElementBlock("div",e.mergeProps({key:0,class:"absolute inset-y-0 left-0 flex items-center pl-3"},n.leftSectionProps),[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(n.leftSection)))],16)):e.createCommentVNode("",!0),e.createElementVNode("input",e.mergeProps({id:n.id,type:n.type,value:n.modelValue,placeholder:n.placeholder,disabled:n.disabled,required:n.required,class:l.value,onInput:r[0]||(r[0]=i=>n.$emit("update:modelValue",i.target.value))},n.inputProps),null,16,Vt),n.rightSection?(e.openBlock(),e.createElementBlock("div",e.mergeProps({key:1,class:"absolute inset-y-0 right-0 flex items-center pr-3"},n.rightSectionProps),[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(n.rightSection)))],16)):e.createCommentVNode("",!0)]),n.description?(e.openBlock(),e.createElementBlock("p",e.mergeProps({key:1,class:"mt-1 text-sm text-gray-500"},n.descriptionProps),e.toDisplayString(n.description),17)):e.createCommentVNode("",!0),n.error?(e.openBlock(),e.createElementBlock("p",e.mergeProps({key:2,class:"mt-1 text-sm text-red-500"},n.errorProps),e.toDisplayString(n.error),17)):e.createCommentVNode("",!0)],16))}}),Nt=["aria-expanded","aria-disabled"],Dt=["placeholder","disabled"],Lt={key:1,class:"w-full truncate text-gray-900"},Ot={class:"flex items-center gap-2 shrink-0"},Rt={key:0,class:"py-3 text-center text-gray-500"},At=["onClick"],_t={key:0,class:"py-3 px-4 text-gray-500 text-center text-sm"},Pt=e.defineComponent({__name:"Select",props:{modelValue:{default:null},options:{default:()=>[]},placeholder:{default:"Select option"},disabled:{type:Boolean,default:!1},searchable:{type:Boolean,default:!1},clearable:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},error:{type:Boolean,default:!1},size:{default:"md"},radius:{default:"sm"},variant:{default:"outline"},color:{default:"primary"},withCheckIcon:{type:Boolean,default:!0},checkIconPosition:{default:"right"},nothingFoundMessage:{default:"Nothing found..."}},emits:["update:modelValue","change"],setup(o,{emit:s}){const t=o,l=s,n=e.ref(!1),r=e.ref(""),i=e.ref(null),a=e.ref(null),c=p=>({none:"rounded-none",xs:"rounded",sm:"rounded-md",md:"rounded-lg",lg:"rounded-xl",xl:"rounded-2xl",full:"rounded-full"})[p]||"rounded-lg",d=e.computed(()=>{const p="w-full flex items-center justify-between transition-colors duration-200",w=[N(t.size,"input"),ae(t.size,"input")].join(" "),C=c(t.radius),k=t.error?"focus-within:ring-2 focus-within:ring-red-500/20 focus-within:border-red-500":"focus-within:ring-2 focus-within:ring-blue-500/20 focus-within:border-blue-500",$=t.variant==="filled"?`bg-gray-50 border border-transparent ${!t.disabled&&`hover:bg-gray-100 focus-within:bg-white focus-within:border-gray-300 ${k}`}`:`bg-white border border-gray-300 ${!t.disabled&&`hover:border-gray-400 ${k}`}`,z=W({disabled:t.disabled,error:t.error}),E=!t.disabled&&"cursor-pointer";return[p,w,C,$,z,E].filter(Boolean).join(" ")}),u=e.computed(()=>t.options.find(p=>p.value===t.modelValue)),f=e.computed(()=>{if(!r.value)return t.options;const p=r.value.toLowerCase();return t.options.filter(w=>w.label.toLowerCase().includes(p))}),m=()=>{var p;t.disabled||(t.searchable?((p=i.value)==null||p.focus(),n.value=!0):n.value=!n.value)},h=p=>{l("update:modelValue",p.value),l("change",p),n.value=!1,t.searchable&&(r.value=p.label)},y=()=>{l("update:modelValue",null),l("change",null),r.value=""},g=()=>{n.value||(n.value=!0)},b=()=>{n.value||(n.value=!0)},x=p=>{const w=p.target;a.value&&!a.value.contains(w)&&(n.value=!1)};return e.watch(()=>t.modelValue,p=>{p?u.value&&t.searchable&&(r.value=u.value.label):r.value=""}),e.onMounted(()=>{document.addEventListener("click",x)}),e.onUnmounted(()=>{document.removeEventListener("click",x)}),(p,w)=>(e.openBlock(),e.createElementBlock("div",{class:"relative select",ref_key:"selectRoot",ref:a},[e.createElementVNode("div",{class:e.normalizeClass(d.value),role:"combobox","aria-expanded":n.value,"aria-disabled":p.disabled,onClick:m},[p.searchable?e.withDirectives((e.openBlock(),e.createElementBlock("input",{key:0,ref_key:"searchInput",ref:i,"onUpdate:modelValue":w[0]||(w[0]=C=>r.value=C),placeholder:p.placeholder,type:"text",class:"w-full bg-transparent outline-none placeholder:text-gray-500",disabled:p.disabled,onFocus:g,onInput:b},null,40,Dt)),[[e.vModelText,r.value]]):(e.openBlock(),e.createElementBlock("div",Lt,e.toDisplayString(u.value?u.value.label:p.placeholder),1)),e.createElementVNode("div",Ot,[p.clearable&&p.modelValue&&!p.disabled?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"p-1 hover:bg-gray-100 rounded-full text-gray-500 hover:text-gray-700",onClick:e.withModifiers(y,["stop"])},w[1]||(w[1]=[e.createElementVNode("svg",{class:"w-4 h-4",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M6 18L18 6M6 6l12 12"})],-1)]))):e.createCommentVNode("",!0),(e.openBlock(),e.createElementBlock("svg",{class:e.normalizeClass(["w-4 h-4 text-gray-500 transition-transform duration-200",{"rotate-180":n.value}]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},w[2]||(w[2]=[e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M19 9l-7 7-7-7"},null,-1)]),2))])],10,Nt),e.withDirectives(e.createElementVNode("div",{class:e.normalizeClass(["absolute w-full z-50 mt-1 bg-white","border border-gray-200",c(t.radius),"shadow-lg max-h-[240px] overflow-auto","divide-y divide-gray-100"])},[p.loading?(e.openBlock(),e.createElementBlock("div",Rt,[e.renderSlot(p.$slots,"loader",{},()=>[w[3]||(w[3]=e.createElementVNode("svg",{class:"animate-spin h-5 w-5 mx-auto",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24"},[e.createElementVNode("circle",{class:"opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor","stroke-width":"4"}),e.createElementVNode("path",{class:"opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"})],-1))])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value,C=>(e.openBlock(),e.createElementBlock("div",{key:C.value,class:e.normalizeClass(["py-2.5 px-4 flex items-center transition-colors duration-200","text-[14px] leading-5","text-gray-900",C.value===p.modelValue?"bg-gray-50 font-medium":"hover:bg-gray-50",C.disabled?"opacity-50 cursor-not-allowed":"cursor-pointer"]),onClick:k=>!C.disabled&&h(C)},[p.withCheckIcon&&C.value===p.modelValue?(e.openBlock(),e.createElementBlock("svg",{key:0,class:e.normalizeClass(["w-4 h-4 text-blue-600 shrink-0",p.checkIconPosition==="left"?"mr-2":"ml-2 order-last"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},w[4]||(w[4]=[e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M5 13l4 4L19 7"},null,-1)]),2)):e.createCommentVNode("",!0),e.createElementVNode("span",{class:e.normalizeClass({"text-gray-500":C.disabled})},e.toDisplayString(C.label),3)],10,At))),128)),f.value.length===0?(e.openBlock(),e.createElementBlock("div",_t,e.toDisplayString(p.nothingFoundMessage||"No options found"),1)):e.createCommentVNode("",!0)],64))],2),[[e.vShow,n.value]])],512))}}),Tt=["disabled"],Mt={key:0,class:"w-3.5 h-3.5",viewBox:"0 0 20 20",fill:"currentColor"},vt={key:1,class:"animate-spin"},It=e.defineComponent({__name:"Chip",props:{modelValue:{type:Boolean,default:!1},label:{default:""},size:{default:"md"},variant:{default:"filled"},color:{default:"primary"},radius:{default:"xl"},checked:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},withRemoveButton:{type:Boolean,default:!1},withCheckIcon:{type:Boolean,default:!0},checkIconPosition:{default:"left"},allowDeselect:{type:Boolean,default:!0},loading:{type:Boolean,default:!1}},emits:["update:modelValue"],setup(o,{emit:s}){const t=o,l=s,n=e.computed(()=>F(t.color)),r=e.computed(()=>N(t.size,"chip")),i=e.computed(()=>W({disabled:t.disabled,loading:t.loading})),a=e.computed(()=>F(t.color,"filled")),c=e.computed(()=>F(t.color,"outline")),d=()=>{t.disabled||t.loading||t.modelValue&&!t.allowDeselect||l("update:modelValue",!t.modelValue)};return(u,f)=>(e.openBlock(),e.createElementBlock("button",{class:e.normalizeClass(["inline-flex items-center justify-center gap-2 rounded-full transition-colors duration-200 select-none","focus:outline-none",n.value,r.value,i.value,u.modelValue?a.value:c.value,"cursor-pointer"]),disabled:u.disabled||u.loading,onClick:d},[u.withCheckIcon&&u.modelValue?(e.openBlock(),e.createElementBlock("svg",Mt,f[0]||(f[0]=[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z","clip-rule":"evenodd"},null,-1)]))):e.createCommentVNode("",!0),u.loading?(e.openBlock(),e.createElementBlock("span",vt,f[1]||(f[1]=[e.createElementVNode("svg",{class:"w-3.5 h-3.5",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24"},[e.createElementVNode("circle",{class:"opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor","stroke-width":"4"}),e.createElementVNode("path",{class:"opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"})],-1)]))):e.createCommentVNode("",!0),e.createElementVNode("span",{class:e.normalizeClass(["whitespace-nowrap",u.loading?"opacity-75":""])},e.toDisplayString(u.label),3)],10,Tt))}}),jt=(o,s=0)=>{const t={position:"absolute",transform:"translate(50%, -50%)"},[l,n]=o.split("-");if(l==="top"?t.top="0":l==="bottom"?(t.bottom="0",t.transform="translate(50%, 50%)"):l==="middle"&&(t.top="50%",n==="start"?t.transform="translate(-50%, -50%)":n==="end"?t.transform="translate(50%, -50%)":t.transform="translate(0, -50%)"),n==="start"?(t.left="0",t.transform=l==="bottom"?"translate(-50%, 50%)":"translate(-50%, -50%)"):n==="end"?t.right="0":n==="center"&&(t.left="50%",t.transform=l==="bottom"?"translate(-50%, 50%)":"translate(-50%, -50%)"),s){const r=t.transform.includes("50%")?"50%":"0",i=t.transform.includes("-50%")?"-50%":"50%";(l==="top"||l==="bottom")&&(t.transform=`translate(${r}, ${i}) translateY(${s}px)`),(n==="start"||n==="end")&&(t.transform=`translate(${r}, ${i}) translateX(${n==="start"?-s:s}px)`)}return t},Ft={name:"Indicator"},Wt=e.defineComponent({...Ft,props:{position:{default:"top-end"},size:{default:"md"},radius:{default:"xl"},color:{default:"primary"},variant:{default:"filled"},offset:{default:0},inline:{type:Boolean,default:!1},label:{default:""},withBorder:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},processing:{type:Boolean,default:!1},zIndex:{default:200}},setup(o){const s=o,t=e.computed(()=>[s.inline?"inline-block":"block","relative"]),l=e.computed(()=>({...s.inline&&{display:"inline-block"}})),n=e.computed(()=>["flex items-center justify-center","absolute","select-none","rounded-full",ae(s.size,"indicator"),N(s.size,"indicator"),!s.disabled&&`bg-${s.color==="primary"?"blue":s.color}-600 text-white`,s.disabled&&"bg-gray-200 text-gray-500",s.withBorder&&"border-2 border-white dark:border-gray-900",s.processing&&"animate-pulse"]),r=e.computed(()=>({...jt(s.position,s.offset),zIndex:s.zIndex}));return(i,a)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(t.value),style:e.normalizeStyle(l.value)},[i.disabled?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(n.value),style:e.normalizeStyle(r.value)},e.toDisplayString(i.label),7)),e.renderSlot(i.$slots,"default",{},void 0,!0)],6))}}),ao="",Ht=((o,s)=>{const t=o.__vccOpts||o;for(const[l,n]of s)t[l]=n;return t})(Wt,[["__scopeId","data-v-643e9acf"]]),qt=["aria-valuenow"],Yt=e.defineComponent({__name:"Progress",props:{value:{default:0},size:{default:"md"},color:{},label:{},striped:{type:Boolean,default:!1},animated:{type:Boolean,default:!1}},setup(o){return(s,t)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["relative w-full rounded-sm overflow-hidden","bg-gray-100",e.unref(ae)(s.size,"progress")]),role:"progressbar","aria-valuenow":s.value,"aria-valuemin":"0","aria-valuemax":"100"},[e.createElementVNode("div",{class:e.normalizeClass(["h-full transition-all duration-300 ease-in-out",e.unref(F)(s.color||"primary","filled"),{"bg-striped":s.striped&&!s.animated,"bg-striped animate-progress":s.animated}]),style:e.normalizeStyle({width:`${s.value}%`})},[s.label&&(s.size==="lg"||s.size==="xl")?(e.openBlock(),e.createElementBlock("span",{key:0,class:e.normalizeClass(["block px-2 py-1 text-white whitespace-nowrap font-medium leading-none",e.unref(ye)(s.size)])},e.toDisplayString(s.label),3)):e.createCommentVNode("",!0)],6)],10,qt))}}),co="",Kt={key:0,class:"flex-shrink-0"},Ut={key:0,class:"flex items-center justify-between"},Xt={key:1,class:"flex-shrink-0 ml-3"},Gt=["disabled"],Zt=e.defineComponent({__name:"Alert",props:{title:{},message:{},icon:{},variant:{default:"default"},color:{default:"primary"},size:{default:"md"},closable:{type:Boolean,default:!1},onClose:{},disabled:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},valid:{type:Boolean,default:void 0},invalid:{type:Boolean,default:void 0}},emits:["close"],setup(o,{emit:s}){const t=o,l=s,n=e.computed(()=>F(t.color,t.variant,{hover:!1,active:!1,focus:!1,disabled:t.disabled})),r=e.computed(()=>it(t.variant)),i=e.computed(()=>rt(t.color,t.variant)),a=e.computed(()=>at(t.color,t.variant)),c=e.computed(()=>N(t.size,"alert")),d=e.computed(()=>ct(t.size,"alert")),u=e.computed(()=>ye(t.size)),f=e.computed(()=>Ae(t.size)),m=e.computed(()=>W({disabled:t.disabled,loading:t.loading})),h=e.computed(()=>ut({valid:t.valid,invalid:t.invalid})),y=e.computed(()=>pt({hover:!0,focus:!0},t.color)),g=()=>{l("close")};return(b,x)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["relative rounded-md",r.value,n.value,c.value,m.value,h.value]),role:"alert"},[e.createElementVNode("div",{class:e.normalizeClass(["flex items-start",[f.value]])},[b.icon?(e.openBlock(),e.createElementBlock("div",Kt,[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(b.icon),{class:e.normalizeClass([d.value,i.value])},null,8,["class"]))])):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass(["flex-grow",[b.icon&&"ml-3"]])},[b.title?(e.openBlock(),e.createElementBlock("div",Ut,[e.createElementVNode("h3",{class:e.normalizeClass(["font-medium",a.value])},e.toDisplayString(b.title),3)])):e.createCommentVNode("",!0),b.message?(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["mt-1",b.variant==="filled"?"text-white/90":"text-gray-600",u.value])},e.toDisplayString(b.message),3)):e.createCommentVNode("",!0),e.renderSlot(b.$slots,"default")],2),b.closable?(e.openBlock(),e.createElementBlock("div",Xt,[e.createElementVNode("button",{type:"button",class:e.normalizeClass(["inline-flex rounded-md focus:outline-none focus:ring-2 focus:ring-offset-2",[b.variant==="filled"?"text-white/80 hover:text-white focus:ring-white":"text-gray-400 hover:text-gray-500 focus:ring-blue-500",y.value]]),disabled:b.disabled,onClick:g},x[0]||(x[0]=[e.createElementVNode("span",{class:"sr-only"},"Close",-1),e.createElementVNode("svg",{class:"h-5 w-5",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},[e.createElementVNode("path",{d:"M6.28 5.22a.75.75 0 00-1.06 1.06L8.94 10l-3.72 3.72a.75.75 0 101.06 1.06L10 11.06l3.72 3.72a.75.75 0 101.06-1.06L11.06 10l3.72-3.72a.75.75 0 00-1.06-1.06L10 8.94 6.28 5.22z"})],-1)]),10,Gt)])):e.createCommentVNode("",!0)],2)],2))}}),Qt=e.defineComponent({__name:"Collapse",props:{open:{type:Boolean,default:!1},duration:{default:200},class:{},size:{default:"md"},disableTransition:{type:Boolean,default:!1}},setup(o){const s=o,t=e.ref(null),l=e.ref(null),n={xs:"p-1",sm:"p-2",md:"p-3",lg:"p-4",xl:"p-5"},r=e.computed(()=>Ae(s.size)),i=e.computed(()=>n[s.size]),a=e.computed(()=>s.disableTransition?"":`transition-[height] ease-in-out duration-${s.duration}`),c=e.computed(()=>({enter:s.duration,leave:s.duration})),d=g=>{g.style.height="0",g.style.overflow="hidden"},u=g=>{const b=g.scrollHeight;g.style.height="0",g.offsetHeight,g.style.height=`${b}px`},f=g=>{g.style.height="",g.style.overflow=""},m=g=>{g.style.height=`${g.scrollHeight}px`,g.style.overflow="hidden",g.offsetHeight},h=g=>{g.style.height="0"},y=g=>{g.style.height="",g.style.overflow=""};return(g,b)=>(e.openBlock(),e.createBlock(e.Transition,{duration:c.value,onBeforeEnter:d,onEnter:u,onAfterEnter:f,onBeforeLeave:m,onLeave:h,onAfterLeave:y},{default:e.withCtx(()=>[e.withDirectives(e.createElementVNode("div",{class:e.normalizeClass(["overflow-hidden",r.value,a.value,s.class]),ref_key:"contentRef",ref:t},[e.createElementVNode("div",{ref_key:"innerRef",ref:l,class:e.normalizeClass(i.value)},[e.renderSlot(g.$slots,"default")],2)],2),[[e.vShow,g.open]])]),_:3},8,["duration"]))}}),Jt={class:"inline-block"},es=e.defineComponent({__name:"OvalLoader",props:{size:{default:"md"}},setup(o){const s={xs:"12px",sm:"16px",md:"24px",lg:"36px",xl:"48px"},t=o,l=e.computed(()=>{const n=parseInt(s[t.size]);return`${Math.max(2,n/12)}px`});return(n,r)=>(e.openBlock(),e.createElementBlock("span",Jt,[e.createElementVNode("span",{class:"inline-block rounded-full border-solid border-r-transparent border-current animate-[oval-spin_1.2s_linear_infinite]",style:e.normalizeStyle({width:s[t.size],height:s[t.size],borderWidth:l.value})},null,4)]))}}),uo="",ts=e.defineComponent({__name:"DotsLoader",props:{size:{default:"md"}},setup(o){const s={xs:"12px",sm:"16px",md:"24px",lg:"36px",xl:"48px"},t=o,l=e.computed(()=>`${parseInt(s[t.size])/3}px`),n=e.computed(()=>`${parseInt(s[t.size])/6}px`);return(r,i)=>(e.openBlock(),e.createElementBlock("span",{class:"inline-flex items-center",style:e.normalizeStyle({gap:n.value,height:s[t.size]})},[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(3,a=>e.createElementVNode("span",{key:a,class:"inline-block rounded-full animate-[dots-pulse_0.8s_infinite_linear] bg-current",style:e.normalizeStyle({width:l.value,height:l.value,animationDelay:`${(a-1)*.16}s`,opacity:1})},null,4)),64))],4))}}),po="",ss=e.defineComponent({__name:"BarsLoader",props:{size:{default:"md"}},setup(o){const s={xs:"12px",sm:"16px",md:"24px",lg:"36px",xl:"48px"},t=o,l=e.computed(()=>`${parseInt(s[t.size])/6}px`);return(n,r)=>(e.openBlock(),e.createElementBlock("span",{class:"inline-flex",style:e.normalizeStyle({gap:l.value,width:s[t.size],height:`${parseInt(s[t.size])/2}px`})},[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(3,i=>e.createElementVNode("span",{key:i,class:"flex-1 rounded-[2px] animate-[bars-scale_1.2s_cubic-bezier(0,0.5,0.5,1)_infinite] bg-current",style:e.normalizeStyle({animationDelay:`${(i-1)*-.12}s`,opacity:1})},null,4)),64))],4))}}),fo="",os=e.defineComponent({__name:"Loader",props:{variant:{default:"oval"},color:{default:"primary"},size:{default:"md"},class:{}},setup(o){const s=o,t=i=>/^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$/.test(i),l=e.computed(()=>!s.color||t(s.color)?"":{primary:"text-blue-500",secondary:"text-gray-500",success:"text-green-500",warning:"text-yellow-500",danger:"text-red-500",info:"text-blue-500",dark:"text-gray-900",light:"text-white"}[s.color]||""),n=e.computed(()=>!s.color||!t(s.color)?{}:{color:s.color}),r=e.computed(()=>{switch(s.variant){case"dots":return ts;case"bars":return ss;default:return es}});return(i,a)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(r.value),{class:e.normalizeClass(["inline-block",l.value,s.class]),style:e.normalizeStyle(n.value),size:s.size},null,8,["class","style","size"]))}}),ns={class:"p-4"},ls={key:0,class:"absolute top-2 right-2"},rs={key:1,class:"text-lg font-medium mb-2"},as={key:2},is=e.defineComponent({__name:"Dialog",props:{title:{},content:{},opened:{type:Boolean},size:{default:"md"},withCloseButton:{type:Boolean,default:!0},onClose:{},position:{default:()=>({bottom:"20px",right:"20px"})},keepMounted:{type:Boolean,default:!1},zIndex:{default:1e3}},setup(o){const s=o,t=e.computed(()=>({xs:"w-[280px]",sm:"w-[320px]",md:"w-[380px]",lg:"w-[440px]",xl:"w-[520px]"})[s.size]);return(l,n)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{"enter-active-class":"transition duration-200 ease-out","enter-from-class":"opacity-0 scale-95","enter-to-class":"opacity-100 scale-100","leave-active-class":"transition duration-200 ease-in","leave-from-class":"opacity-100 scale-100","leave-to-class":"opacity-0 scale-95"},{default:e.withCtx(()=>[l.opened||l.keepMounted?(e.openBlock(),e.createElementBlock("div",{key:0,style:e.normalizeStyle({position:"fixed",zIndex:l.zIndex||1e3,...l.position,display:l.opened?"block":"none"}),class:"min-w-[200px]"},[e.createElementVNode("div",{class:e.normalizeClass(["rounded-lg bg-white dark:bg-gray-800 shadow-lg border border-gray-200 dark:border-gray-700",[t.value]])},[e.createElementVNode("div",ns,[l.withCloseButton?(e.openBlock(),e.createElementBlock("div",ls,[e.createElementVNode("button",{onClick:n[0]||(n[0]=(...r)=>l.onClose&&l.onClose(...r)),class:"text-gray-400 hover:text-gray-500 dark:text-gray-500 dark:hover:text-gray-400 focus:outline-none"},n[1]||(n[1]=[e.createElementVNode("span",{class:"sr-only"},"Close",-1),e.createElementVNode("svg",{class:"h-5 w-5",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor"},[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z","clip-rule":"evenodd"})],-1)]))])):e.createCommentVNode("",!0),l.title?(e.openBlock(),e.createElementBlock("div",rs,e.toDisplayString(l.title),1)):e.createCommentVNode("",!0),l.content?(e.openBlock(),e.createElementBlock("div",as,e.toDisplayString(l.content),1)):e.createCommentVNode("",!0),e.renderSlot(l.$slots,"default")])],2)],4)):e.createCommentVNode("",!0)]),_:3})]))}}),X=Math.min,H=Math.max,ie=Math.round,ce=Math.floor,O=o=>({x:o,y:o}),cs={left:"right",right:"left",bottom:"top",top:"bottom"},ds={start:"end",end:"start"};function be(o,s,t){return H(o,X(s,t))}function te(o,s){return typeof o=="function"?o(s):o}function q(o){return o.split("-")[0]}function se(o){return o.split("-")[1]}function Te(o){return o==="x"?"y":"x"}function we(o){return o==="y"?"height":"width"}function G(o){return["top","bottom"].includes(q(o))?"y":"x"}function Ce(o){return Te(G(o))}function us(o,s,t){t===void 0&&(t=!1);const l=se(o),n=Ce(o),r=we(n);let i=n==="x"?l===(t?"end":"start")?"right":"left":l==="start"?"bottom":"top";return s.reference[r]>s.floating[r]&&(i=de(i)),[i,de(i)]}function ps(o){const s=de(o);return[ke(o),s,ke(s)]}function ke(o){return o.replace(/start|end/g,s=>ds[s])}function fs(o,s,t){const l=["left","right"],n=["right","left"],r=["top","bottom"],i=["bottom","top"];switch(o){case"top":case"bottom":return t?s?n:l:s?l:n;case"left":case"right":return s?r:i;default:return[]}}function ms(o,s,t,l){const n=se(o);let r=fs(q(o),t==="start",l);return n&&(r=r.map(i=>i+"-"+n),s&&(r=r.concat(r.map(ke)))),r}function de(o){return o.replace(/left|right|bottom|top/g,s=>cs[s])}function gs(o){return{top:0,right:0,bottom:0,left:0,...o}}function Me(o){return typeof o!="number"?gs(o):{top:o,right:o,bottom:o,left:o}}function ue(o){const{x:s,y:t,width:l,height:n}=o;return{width:l,height:n,top:t,left:s,right:s+l,bottom:t+n,x:s,y:t}}function ve(o,s,t){let{reference:l,floating:n}=o;const r=G(s),i=Ce(s),a=we(i),c=q(s),d=r==="y",u=l.x+l.width/2-n.width/2,f=l.y+l.height/2-n.height/2,m=l[a]/2-n[a]/2;let h;switch(c){case"top":h={x:u,y:l.y-n.height};break;case"bottom":h={x:u,y:l.y+l.height};break;case"right":h={x:l.x+l.width,y:f};break;case"left":h={x:l.x-n.width,y:f};break;default:h={x:l.x,y:l.y}}switch(se(s)){case"start":h[i]-=m*(t&&d?-1:1);break;case"end":h[i]+=m*(t&&d?-1:1);break}return h}const hs=async(o,s,t)=>{const{placement:l="bottom",strategy:n="absolute",middleware:r=[],platform:i}=t,a=r.filter(Boolean),c=await(i.isRTL==null?void 0:i.isRTL(s));let d=await i.getElementRects({reference:o,floating:s,strategy:n}),{x:u,y:f}=ve(d,l,c),m=l,h={},y=0;for(let g=0;g<a.length;g++){const{name:b,fn:x}=a[g],{x:p,y:w,data:C,reset:k}=await x({x:u,y:f,initialPlacement:l,placement:m,strategy:n,middlewareData:h,rects:d,platform:i,elements:{reference:o,floating:s}});u=p??u,f=w??f,h={...h,[b]:{...h[b],...C}},k&&y<=50&&(y++,typeof k=="object"&&(k.placement&&(m=k.placement),k.rects&&(d=k.rects===!0?await i.getElementRects({reference:o,floating:s,strategy:n}):k.rects),{x:u,y:f}=ve(d,m,c)),g=-1)}return{x:u,y:f,placement:m,strategy:n,middlewareData:h}};async function Ie(o,s){var t;s===void 0&&(s={});const{x:l,y:n,platform:r,rects:i,elements:a,strategy:c}=o,{boundary:d="clippingAncestors",rootBoundary:u="viewport",elementContext:f="floating",altBoundary:m=!1,padding:h=0}=te(s,o),y=Me(h),b=a[m?f==="floating"?"reference":"floating":f],x=ue(await r.getClippingRect({element:(t=await(r.isElement==null?void 0:r.isElement(b)))==null||t?b:b.contextElement||await(r.getDocumentElement==null?void 0:r.getDocumentElement(a.floating)),boundary:d,rootBoundary:u,strategy:c})),p=f==="floating"?{x:l,y:n,width:i.floating.width,height:i.floating.height}:i.reference,w=await(r.getOffsetParent==null?void 0:r.getOffsetParent(a.floating)),C=await(r.isElement==null?void 0:r.isElement(w))?await(r.getScale==null?void 0:r.getScale(w))||{x:1,y:1}:{x:1,y:1},k=ue(r.convertOffsetParentRelativeRectToViewportRelativeRect?await r.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:p,offsetParent:w,strategy:c}):p);return{top:(x.top-k.top+y.top)/C.y,bottom:(k.bottom-x.bottom+y.bottom)/C.y,left:(x.left-k.left+y.left)/C.x,right:(k.right-x.right+y.right)/C.x}}const ys=o=>({name:"arrow",options:o,async fn(s){const{x:t,y:l,placement:n,rects:r,platform:i,elements:a,middlewareData:c}=s,{element:d,padding:u=0}=te(o,s)||{};if(d==null)return{};const f=Me(u),m={x:t,y:l},h=Ce(n),y=we(h),g=await i.getDimensions(d),b=h==="y",x=b?"top":"left",p=b?"bottom":"right",w=b?"clientHeight":"clientWidth",C=r.reference[y]+r.reference[h]-m[h]-r.floating[y],k=m[h]-r.reference[h],$=await(i.getOffsetParent==null?void 0:i.getOffsetParent(d));let z=$?$[w]:0;(!z||!await(i.isElement==null?void 0:i.isElement($)))&&(z=a.floating[w]||r.floating[y]);const E=C/2-k/2,_=z/2-g[y]/2-1,v=X(f[x],_),le=X(f[p],_),U=v,re=z-g[y]-le,V=z/2-g[y]/2+E,ee=be(U,V,re),T=!c.arrow&&se(n)!=null&&V!==ee&&r.reference[y]/2-(V<U?v:le)-g[y]/2<0,P=T?V<U?V-U:V-re:0;return{[h]:m[h]+P,data:{[h]:ee,centerOffset:V-ee-P,...T&&{alignmentOffset:P}},reset:T}}}),xs=function(o){return o===void 0&&(o={}),{name:"flip",options:o,async fn(s){var t,l;const{placement:n,middlewareData:r,rects:i,initialPlacement:a,platform:c,elements:d}=s,{mainAxis:u=!0,crossAxis:f=!0,fallbackPlacements:m,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:y="none",flipAlignment:g=!0,...b}=te(o,s);if((t=r.arrow)!=null&&t.alignmentOffset)return{};const x=q(n),p=G(a),w=q(a)===a,C=await(c.isRTL==null?void 0:c.isRTL(d.floating)),k=m||(w||!g?[de(a)]:ps(a)),$=y!=="none";!m&&$&&k.push(...ms(a,g,y,C));const z=[a,...k],E=await Ie(s,b),_=[];let v=((l=r.flip)==null?void 0:l.overflows)||[];if(u&&_.push(E[x]),f){const V=us(n,i,C);_.push(E[V[0]],E[V[1]])}if(v=[...v,{placement:n,overflows:_}],!_.every(V=>V<=0)){var le,U;const V=(((le=r.flip)==null?void 0:le.index)||0)+1,ee=z[V];if(ee)return{data:{index:V,overflows:v},reset:{placement:ee}};let T=(U=v.filter(P=>P.overflows[0]<=0).sort((P,I)=>P.overflows[1]-I.overflows[1])[0])==null?void 0:U.placement;if(!T)switch(h){case"bestFit":{var re;const P=(re=v.filter(I=>{if($){const j=G(I.placement);return j===p||j==="y"}return!0}).map(I=>[I.placement,I.overflows.filter(j=>j>0).reduce((j,ro)=>j+ro,0)]).sort((I,j)=>I[1]-j[1])[0])==null?void 0:re[0];P&&(T=P);break}case"initialPlacement":T=a;break}if(n!==T)return{reset:{placement:T}}}return{}}}};async function bs(o,s){const{placement:t,platform:l,elements:n}=o,r=await(l.isRTL==null?void 0:l.isRTL(n.floating)),i=q(t),a=se(t),c=G(t)==="y",d=["left","top"].includes(i)?-1:1,u=r&&c?-1:1,f=te(s,o);let{mainAxis:m,crossAxis:h,alignmentAxis:y}=typeof f=="number"?{mainAxis:f,crossAxis:0,alignmentAxis:null}:{mainAxis:f.mainAxis||0,crossAxis:f.crossAxis||0,alignmentAxis:f.alignmentAxis};return a&&typeof y=="number"&&(h=a==="end"?y*-1:y),c?{x:h*u,y:m*d}:{x:m*d,y:h*u}}const ws=function(o){return o===void 0&&(o=0),{name:"offset",options:o,async fn(s){var t,l;const{x:n,y:r,placement:i,middlewareData:a}=s,c=await bs(s,o);return i===((t=a.offset)==null?void 0:t.placement)&&(l=a.arrow)!=null&&l.alignmentOffset?{}:{x:n+c.x,y:r+c.y,data:{...c,placement:i}}}}},Cs=function(o){return o===void 0&&(o={}),{name:"shift",options:o,async fn(s){const{x:t,y:l,placement:n}=s,{mainAxis:r=!0,crossAxis:i=!1,limiter:a={fn:b=>{let{x,y:p}=b;return{x,y:p}}},...c}=te(o,s),d={x:t,y:l},u=await Ie(s,c),f=G(q(n)),m=Te(f);let h=d[m],y=d[f];if(r){const b=m==="y"?"top":"left",x=m==="y"?"bottom":"right",p=h+u[b],w=h-u[x];h=be(p,h,w)}if(i){const b=f==="y"?"top":"left",x=f==="y"?"bottom":"right",p=y+u[b],w=y-u[x];y=be(p,y,w)}const g=a.fn({...s,[m]:h,[f]:y});return{...g,data:{x:g.x-t,y:g.y-l,enabled:{[m]:r,[f]:i}}}}}};function pe(){return typeof window<"u"}function Y(o){return Be(o)?(o.nodeName||"").toLowerCase():"#document"}function S(o){var s;return(o==null||(s=o.ownerDocument)==null?void 0:s.defaultView)||window}function R(o){var s;return(s=(Be(o)?o.ownerDocument:o.document)||window.document)==null?void 0:s.documentElement}function Be(o){return pe()?o instanceof Node||o instanceof S(o).Node:!1}function D(o){return pe()?o instanceof Element||o instanceof S(o).Element:!1}function A(o){return pe()?o instanceof HTMLElement||o instanceof S(o).HTMLElement:!1}function je(o){return!pe()||typeof ShadowRoot>"u"?!1:o instanceof ShadowRoot||o instanceof S(o).ShadowRoot}function oe(o){const{overflow:s,overflowX:t,overflowY:l,display:n}=L(o);return/auto|scroll|overlay|hidden|clip/.test(s+l+t)&&!["inline","contents"].includes(n)}function ks(o){return["table","td","th"].includes(Y(o))}function fe(o){return[":popover-open",":modal"].some(s=>{try{return o.matches(s)}catch{return!1}})}function ze(o){const s=$e(),t=D(o)?L(o):o;return t.transform!=="none"||t.perspective!=="none"||(t.containerType?t.containerType!=="normal":!1)||!s&&(t.backdropFilter?t.backdropFilter!=="none":!1)||!s&&(t.filter?t.filter!=="none":!1)||["transform","perspective","filter"].some(l=>(t.willChange||"").includes(l))||["paint","layout","strict","content"].some(l=>(t.contain||"").includes(l))}function Bs(o){let s=M(o);for(;A(s)&&!Z(s);){if(ze(s))return s;if(fe(s))return null;s=M(s)}return null}function $e(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function Z(o){return["html","body","#document"].includes(Y(o))}function L(o){return S(o).getComputedStyle(o)}function me(o){return D(o)?{scrollLeft:o.scrollLeft,scrollTop:o.scrollTop}:{scrollLeft:o.scrollX,scrollTop:o.scrollY}}function M(o){if(Y(o)==="html")return o;const s=o.assignedSlot||o.parentNode||je(o)&&o.host||R(o);return je(s)?s.host:s}function Fe(o){const s=M(o);return Z(s)?o.ownerDocument?o.ownerDocument.body:o.body:A(s)&&oe(s)?s:Fe(s)}function ne(o,s,t){var l;s===void 0&&(s=[]),t===void 0&&(t=!0);const n=Fe(o),r=n===((l=o.ownerDocument)==null?void 0:l.body),i=S(n);if(r){const a=Ee(i);return s.concat(i,i.visualViewport||[],oe(n)?n:[],a&&t?ne(a):[])}return s.concat(n,ne(n,[],t))}function Ee(o){return o.parent&&Object.getPrototypeOf(o.parent)?o.frameElement:null}function We(o){const s=L(o);let t=parseFloat(s.width)||0,l=parseFloat(s.height)||0;const n=A(o),r=n?o.offsetWidth:t,i=n?o.offsetHeight:l,a=ie(t)!==r||ie(l)!==i;return a&&(t=r,l=i),{width:t,height:l,$:a}}function Ve(o){return D(o)?o:o.contextElement}function Q(o){const s=Ve(o);if(!A(s))return O(1);const t=s.getBoundingClientRect(),{width:l,height:n,$:r}=We(s);let i=(r?ie(t.width):t.width)/l,a=(r?ie(t.height):t.height)/n;return(!i||!Number.isFinite(i))&&(i=1),(!a||!Number.isFinite(a))&&(a=1),{x:i,y:a}}const zs=O(0);function He(o){const s=S(o);return!$e()||!s.visualViewport?zs:{x:s.visualViewport.offsetLeft,y:s.visualViewport.offsetTop}}function $s(o,s,t){return s===void 0&&(s=!1),!t||s&&t!==S(o)?!1:s}function K(o,s,t,l){s===void 0&&(s=!1),t===void 0&&(t=!1);const n=o.getBoundingClientRect(),r=Ve(o);let i=O(1);s&&(l?D(l)&&(i=Q(l)):i=Q(o));const a=$s(r,t,l)?He(r):O(0);let c=(n.left+a.x)/i.x,d=(n.top+a.y)/i.y,u=n.width/i.x,f=n.height/i.y;if(r){const m=S(r),h=l&&D(l)?S(l):l;let y=m,g=Ee(y);for(;g&&l&&h!==y;){const b=Q(g),x=g.getBoundingClientRect(),p=L(g),w=x.left+(g.clientLeft+parseFloat(p.paddingLeft))*b.x,C=x.top+(g.clientTop+parseFloat(p.paddingTop))*b.y;c*=b.x,d*=b.y,u*=b.x,f*=b.y,c+=w,d+=C,y=S(g),g=Ee(y)}}return ue({width:u,height:f,x:c,y:d})}function Se(o,s){const t=me(o).scrollLeft;return s?s.left+t:K(R(o)).left+t}function qe(o,s,t){t===void 0&&(t=!1);const l=o.getBoundingClientRect(),n=l.left+s.scrollLeft-(t?0:Se(o,l)),r=l.top+s.scrollTop;return{x:n,y:r}}function Es(o){let{elements:s,rect:t,offsetParent:l,strategy:n}=o;const r=n==="fixed",i=R(l),a=s?fe(s.floating):!1;if(l===i||a&&r)return t;let c={scrollLeft:0,scrollTop:0},d=O(1);const u=O(0),f=A(l);if((f||!f&&!r)&&((Y(l)!=="body"||oe(i))&&(c=me(l)),A(l))){const h=K(l);d=Q(l),u.x=h.x+l.clientLeft,u.y=h.y+l.clientTop}const m=i&&!f&&!r?qe(i,c,!0):O(0);return{width:t.width*d.x,height:t.height*d.y,x:t.x*d.x-c.scrollLeft*d.x+u.x+m.x,y:t.y*d.y-c.scrollTop*d.y+u.y+m.y}}function Vs(o){return Array.from(o.getClientRects())}function Ss(o){const s=R(o),t=me(o),l=o.ownerDocument.body,n=H(s.scrollWidth,s.clientWidth,l.scrollWidth,l.clientWidth),r=H(s.scrollHeight,s.clientHeight,l.scrollHeight,l.clientHeight);let i=-t.scrollLeft+Se(o);const a=-t.scrollTop;return L(l).direction==="rtl"&&(i+=H(s.clientWidth,l.clientWidth)-n),{width:n,height:r,x:i,y:a}}function Ns(o,s){const t=S(o),l=R(o),n=t.visualViewport;let r=l.clientWidth,i=l.clientHeight,a=0,c=0;if(n){r=n.width,i=n.height;const d=$e();(!d||d&&s==="fixed")&&(a=n.offsetLeft,c=n.offsetTop)}return{width:r,height:i,x:a,y:c}}function Ds(o,s){const t=K(o,!0,s==="fixed"),l=t.top+o.clientTop,n=t.left+o.clientLeft,r=A(o)?Q(o):O(1),i=o.clientWidth*r.x,a=o.clientHeight*r.y,c=n*r.x,d=l*r.y;return{width:i,height:a,x:c,y:d}}function Ye(o,s,t){let l;if(s==="viewport")l=Ns(o,t);else if(s==="document")l=Ss(R(o));else if(D(s))l=Ds(s,t);else{const n=He(o);l={x:s.x-n.x,y:s.y-n.y,width:s.width,height:s.height}}return ue(l)}function Ke(o,s){const t=M(o);return t===s||!D(t)||Z(t)?!1:L(t).position==="fixed"||Ke(t,s)}function Ls(o,s){const t=s.get(o);if(t)return t;let l=ne(o,[],!1).filter(a=>D(a)&&Y(a)!=="body"),n=null;const r=L(o).position==="fixed";let i=r?M(o):o;for(;D(i)&&!Z(i);){const a=L(i),c=ze(i);!c&&a.position==="fixed"&&(n=null),(r?!c&&!n:!c&&a.position==="static"&&!!n&&["absolute","fixed"].includes(n.position)||oe(i)&&!c&&Ke(o,i))?l=l.filter(u=>u!==i):n=a,i=M(i)}return s.set(o,l),l}function Os(o){let{element:s,boundary:t,rootBoundary:l,strategy:n}=o;const i=[...t==="clippingAncestors"?fe(s)?[]:Ls(s,this._c):[].concat(t),l],a=i[0],c=i.reduce((d,u)=>{const f=Ye(s,u,n);return d.top=H(f.top,d.top),d.right=X(f.right,d.right),d.bottom=X(f.bottom,d.bottom),d.left=H(f.left,d.left),d},Ye(s,a,n));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function Rs(o){const{width:s,height:t}=We(o);return{width:s,height:t}}function As(o,s,t){const l=A(s),n=R(s),r=t==="fixed",i=K(o,!0,r,s);let a={scrollLeft:0,scrollTop:0};const c=O(0);if(l||!l&&!r)if((Y(s)!=="body"||oe(n))&&(a=me(s)),l){const m=K(s,!0,r,s);c.x=m.x+s.clientLeft,c.y=m.y+s.clientTop}else n&&(c.x=Se(n));const d=n&&!l&&!r?qe(n,a):O(0),u=i.left+a.scrollLeft-c.x-d.x,f=i.top+a.scrollTop-c.y-d.y;return{x:u,y:f,width:i.width,height:i.height}}function Ne(o){return L(o).position==="static"}function Ue(o,s){if(!A(o)||L(o).position==="fixed")return null;if(s)return s(o);let t=o.offsetParent;return R(o)===t&&(t=t.ownerDocument.body),t}function Xe(o,s){const t=S(o);if(fe(o))return t;if(!A(o)){let n=M(o);for(;n&&!Z(n);){if(D(n)&&!Ne(n))return n;n=M(n)}return t}let l=Ue(o,s);for(;l&&ks(l)&&Ne(l);)l=Ue(l,s);return l&&Z(l)&&Ne(l)&&!ze(l)?t:l||Bs(o)||t}const _s=async function(o){const s=this.getOffsetParent||Xe,t=this.getDimensions,l=await t(o.floating);return{reference:As(o.reference,await s(o.floating),o.strategy),floating:{x:0,y:0,width:l.width,height:l.height}}};function Ps(o){return L(o).direction==="rtl"}const Ts={convertOffsetParentRelativeRectToViewportRelativeRect:Es,getDocumentElement:R,getClippingRect:Os,getOffsetParent:Xe,getElementRects:_s,getClientRects:Vs,getDimensions:Rs,getScale:Q,isElement:D,isRTL:Ps};function Ms(o,s){let t=null,l;const n=R(o);function r(){var a;clearTimeout(l),(a=t)==null||a.disconnect(),t=null}function i(a,c){a===void 0&&(a=!1),c===void 0&&(c=1),r();const{left:d,top:u,width:f,height:m}=o.getBoundingClientRect();if(a||s(),!f||!m)return;const h=ce(u),y=ce(n.clientWidth-(d+f)),g=ce(n.clientHeight-(u+m)),b=ce(d),p={rootMargin:-h+"px "+-y+"px "+-g+"px "+-b+"px",threshold:H(0,X(1,c))||1};let w=!0;function C(k){const $=k[0].intersectionRatio;if($!==c){if(!w)return i();$?i(!1,$):l=setTimeout(()=>{i(!1,1e-7)},1e3)}w=!1}try{t=new IntersectionObserver(C,{...p,root:n.ownerDocument})}catch{t=new IntersectionObserver(C,p)}t.observe(o)}return i(!0),r}function vs(o,s,t,l){l===void 0&&(l={});const{ancestorScroll:n=!0,ancestorResize:r=!0,elementResize:i=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:c=!1}=l,d=Ve(o),u=n||r?[...d?ne(d):[],...ne(s)]:[];u.forEach(x=>{n&&x.addEventListener("scroll",t,{passive:!0}),r&&x.addEventListener("resize",t)});const f=d&&a?Ms(d,t):null;let m=-1,h=null;i&&(h=new ResizeObserver(x=>{let[p]=x;p&&p.target===d&&h&&(h.unobserve(s),cancelAnimationFrame(m),m=requestAnimationFrame(()=>{var w;(w=h)==null||w.observe(s)})),t()}),d&&!c&&h.observe(d),h.observe(s));let y,g=c?K(o):null;c&&b();function b(){const x=K(o);g&&(x.x!==g.x||x.y!==g.y||x.width!==g.width||x.height!==g.height)&&t(),g=x,y=requestAnimationFrame(b)}return t(),()=>{var x;u.forEach(p=>{n&&p.removeEventListener("scroll",t),r&&p.removeEventListener("resize",t)}),f==null||f(),(x=h)==null||x.disconnect(),h=null,c&&cancelAnimationFrame(y)}}const Ge=ws,Ze=Cs,Qe=xs,Is=ys,js=(o,s,t)=>{const l=new Map,n={platform:Ts,...t},r={...n.platform,_c:l};return hs(o,s,{...n,platform:r})};function Fs(o){return o!=null&&typeof o=="object"&&"$el"in o}function De(o){if(Fs(o)){const s=o.$el;return Be(s)&&Y(s)==="#comment"?null:s}return o}function J(o){return typeof o=="function"?o():e.unref(o)}function Ws(o){return{name:"arrow",options:o,fn(s){const t=De(J(o.element));return t==null?{}:Is({element:t,padding:o.padding}).fn(s)}}}function Je(o){return typeof window>"u"?1:(o.ownerDocument.defaultView||window).devicePixelRatio||1}function et(o,s){const t=Je(o);return Math.round(s*t)/t}function tt(o,s,t){t===void 0&&(t={});const l=t.whileElementsMounted,n=e.computed(()=>{var z;return(z=J(t.open))!=null?z:!0}),r=e.computed(()=>J(t.middleware)),i=e.computed(()=>{var z;return(z=J(t.placement))!=null?z:"bottom"}),a=e.computed(()=>{var z;return(z=J(t.strategy))!=null?z:"absolute"}),c=e.computed(()=>{var z;return(z=J(t.transform))!=null?z:!0}),d=e.computed(()=>De(o.value)),u=e.computed(()=>De(s.value)),f=e.ref(0),m=e.ref(0),h=e.ref(a.value),y=e.ref(i.value),g=e.shallowRef({}),b=e.ref(!1),x=e.computed(()=>{const z={position:h.value,left:"0",top:"0"};if(!u.value)return z;const E=et(u.value,f.value),_=et(u.value,m.value);return c.value?{...z,transform:"translate("+E+"px, "+_+"px)",...Je(u.value)>=1.5&&{willChange:"transform"}}:{position:h.value,left:E+"px",top:_+"px"}});let p;function w(){if(d.value==null||u.value==null)return;const z=n.value;js(d.value,u.value,{middleware:r.value,placement:i.value,strategy:a.value}).then(E=>{f.value=E.x,m.value=E.y,h.value=E.strategy,y.value=E.placement,g.value=E.middlewareData,b.value=z!==!1})}function C(){typeof p=="function"&&(p(),p=void 0)}function k(){if(C(),l===void 0){w();return}if(d.value!=null&&u.value!=null){p=l(d.value,u.value,w);return}}function $(){n.value||(b.value=!1)}return e.watch([r,i,a,n],w,{flush:"sync"}),e.watch([d,u],k,{flush:"sync"}),e.watch(n,$,{flush:"sync"}),e.getCurrentScope()&&e.onScopeDispose(C),{x:e.shallowReadonly(f),y:e.shallowReadonly(m),strategy:e.shallowReadonly(h),placement:e.shallowReadonly(y),middlewareData:e.shallowReadonly(g),isPositioned:e.shallowReadonly(b),floatingStyles:x,update:w}}function Hs(o){return e.getCurrentScope()?(e.onScopeDispose(o),!0):!1}const qs=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;function st(o,s,t={}){const{immediate:l=!0}=t,n=e.ref(!1);let r=null;function i(){r&&(clearTimeout(r),r=null)}function a(){n.value=!1,i()}function c(...d){i(),n.value=!0,r=setTimeout(()=>{n.value=!1,r=null,o(...d)},e.toValue(s))}return l&&(n.value=!0,qs&&c()),Hs(a),{isPending:e.readonly(n),start:c,stop:a}}function ot(o={}){const{openDelay:s=0,closeDelay:t=150,onOpen:l,onClose:n,initiallyOpened:r=!1}=o,i=e.ref(!1),{start:a,stop:c}=st(()=>{i.value=!0,l==null||l()},s),{start:d,stop:u}=st(()=>{i.value=!1,n==null||n()},t),f=()=>{u(),s===0?(i.value=!0,l==null||l()):a()},m=()=>{c(),t===0?(i.value=!1,n==null||n()):d()};return r&&f(),{isOpen:i,open:f,close:m}}const Le=Symbol("hover-card"),Oe=e.defineComponent({__name:"HoverCardTarget",props:{withWrapper:{type:Boolean,default:!1},wrapperClass:{default:""}},setup(o){return e.inject(Le,null),(s,t)=>s.withWrapper?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(s.wrapperClass)},[e.renderSlot(s.$slots,"default")],2)):e.renderSlot(s.$slots,"default",{key:1})}}),Ys={class:"rounded-lg bg-white dark:bg-gray-800 shadow-lg border border-gray-200 dark:border-gray-700 px-3 py-2"},nt=e.defineComponent({__name:"HoverCard",props:{initiallyOpened:{type:Boolean,default:!1},openDelay:{default:0},closeDelay:{default:150},placement:{default:"bottom"},onOpen:{},onClose:{},offset:{default:8},disabled:{type:Boolean,default:!1},size:{default:"md"},withArrow:{type:Boolean,default:!0},arrowOffset:{default:8},trapFocus:{type:Boolean,default:!0},zIndex:{default:1e3}},setup(o){const s=o,t=e.ref(!1);e.onMounted(()=>{t.value=!0});const l=e.ref(null),n=e.ref(null),r=e.ref(null),{isOpen:i,open:a,close:c}=ot({openDelay:s.openDelay,closeDelay:s.closeDelay,initiallyOpened:s.initiallyOpened});e.provide(Le,{isOpen:i,open:a,close:c});const{x:d,y:u,strategy:f,middlewareData:m,placement:h,update:y}=tt(n,r,{placement:s.placement,middleware:[Ge(s.offset),Qe({fallbackPlacements:["top","bottom","right","left"].filter(C=>C!==s.placement)}),Ze({padding:8}),Ws({element:l})]});e.watch(i,async C=>{C&&await y()});const g=e.computed(()=>{var C,k;return(k=(C=m.value)==null?void 0:C.arrow)==null?void 0:k.x}),b=e.computed(()=>{var C,k;return(k=(C=m.value)==null?void 0:C.arrow)==null?void 0:k.y}),x=e.computed(()=>{switch(h.value){case"top":return"bottom";case"bottom":return"top";case"left":return"right";case"right":return"left";default:return"bottom"}}),p=e.computed(()=>{switch(h.value){case"top":return"translate(-50%, 50%)";case"bottom":return"translate(-50%, -50%)";case"left":return"translate(50%, -50%)";case"right":return"translate(-50%, -50%)";default:return"translate(-50%, -50%)"}}),w=e.computed(()=>({xs:"w-[200px]",sm:"w-[240px]",md:"w-[320px]",lg:"w-[400px]",xl:"w-[480px]"})[s.size]);return(C,k)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"reference",ref:n,class:"relative inline-block",onMouseenter:k[2]||(k[2]=$=>!C.disabled&&e.unref(a)()),onMouseleave:k[3]||(k[3]=$=>!C.disabled&&e.unref(c)())},[e.createVNode(Oe,null,{default:e.withCtx(()=>[e.renderSlot(C.$slots,"target")]),_:3}),t.value?(e.openBlock(),e.createBlock(e.Teleport,{key:0,to:"body"},[e.createVNode(e.Transition,{"enter-active-class":"transition duration-200 ease-out","enter-from-class":"opacity-0 translate-y-1","enter-to-class":"opacity-100 translate-y-0","leave-active-class":"transition duration-150 ease-in","leave-from-class":"opacity-100 translate-y-0","leave-to-class":"opacity-0 translate-y-1"},{default:e.withCtx(()=>[e.unref(i)?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"floating",ref:r,style:e.normalizeStyle({position:e.unref(f),top:`${e.unref(u)??0}px`,left:`${e.unref(d)??0}px`,zIndex:C.zIndex||1e3}),class:e.normalizeClass(["min-w-[200px]",[w.value]]),onMouseenter:k[0]||(k[0]=$=>!C.disabled&&e.unref(a)()),onMouseleave:k[1]||(k[1]=$=>!C.disabled&&e.unref(c)())},[e.createElementVNode("div",Ys,[e.renderSlot(C.$slots,"dropdown")]),C.withArrow?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"arrowRef",ref:l,class:"absolute w-2 h-2 rotate-45 bg-white dark:bg-gray-800 border border-gray-200 dark:border-gray-700",style:e.normalizeStyle({position:"absolute",left:`${g.value??0}px`,top:`${b.value??0}px`,[x.value]:"-1px","z-index":-1,"transform-origin":"center",transform:`rotate(45deg) ${p.value}`})},null,4)):e.createCommentVNode("",!0)],38)):e.createCommentVNode("",!0)]),_:3})])):e.createCommentVNode("",!0)],544))}});Object.assign(nt,{Target:Oe});const Ks={},Us={key:0,class:"badge-section mr-2"},Xs={class:"badge-label"},Gs={key:1,class:"badge-section ml-2"},Zs=e.defineComponent({__name:"Badge",props:{size:{default:"md"},circle:{type:Boolean,default:!1},radius:{default:"xl"},color:{default:"primary"},gradient:{},leftSection:{},rightSection:{},fullWidth:{type:Boolean,default:!1},variant:{default:"filled"}},setup(o){const s=o,t=r=>({none:"rounded-none",xs:"rounded",sm:"rounded-md",md:"rounded-lg",lg:"rounded-xl",xl:"rounded-2xl",full:"rounded-full"})[r]||"rounded-lg",l=r=>`relative pl-6 before:absolute before:left-2 before:top-1/2 before:-translate-y-1/2 before:w-2 before:h-2 before:rounded-full before:bg-${r}-500`,n=e.computed(()=>{var f,m;const r="inline-flex items-center justify-center font-medium",i=s.variant==="gradient"?`bg-gradient-to-r from-${(f=s.gradient)==null?void 0:f.from} to-${(m=s.gradient)==null?void 0:m.to} text-white`:F(s.color,s.variant),a=N(s.size,"badge"),c=t(s.radius),d=s.variant==="dot"?l(s.color):"";return[r,i,a,c,d,{"aspect-square p-0":s.circle,"w-full":s.fullWidth}].filter(Boolean).join(" ")});return(r,i)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(n.value)},[r.leftSection?(e.openBlock(),e.createElementBlock("span",Us,[typeof r.leftSection=="string"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(r.leftSection),1)],64)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(r.leftSection),{key:1}))])):e.createCommentVNode("",!0),e.createElementVNode("span",Xs,[e.renderSlot(r.$slots,"default")]),r.rightSection?(e.openBlock(),e.createElementBlock("span",Gs,[typeof r.rightSection=="string"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(r.rightSection),1)],64)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(r.rightSection),{key:1}))])):e.createCommentVNode("",!0)],2))}}),mo="",Qs={mounted(o,s){o._clickOutside=t=>{const l=t.target;o===l||o.contains(l)||s.value(t)},document.addEventListener("click",o._clickOutside,!0),document.addEventListener("touchstart",o._clickOutside,!0)},unmounted(o){o._clickOutside&&(document.removeEventListener("click",o._clickOutside,!0),document.removeEventListener("touchstart",o._clickOutside,!0))}};function Js(o){return{none:"cstu-rounded-none",sm:"cstu-rounded-sm",md:"cstu-rounded",lg:"cstu-rounded-lg",xl:"cstu-rounded-xl",full:"cstu-rounded-full"}[o]}const eo=["data-active"],to=e.defineComponent({__name:"Dropdown",props:{size:{default:"md"},radius:{default:"md"},open:{type:Boolean,default:!1},buttonClasses:{default:""},dropdownClasses:{default:""},placement:{default:"bottom"},disabled:{type:Boolean,default:!1},containerClasses:{default:""},showArrow:{type:Boolean,default:!0},disabledText:{default:""},parentPositionRelative:{type:Boolean,default:!0},offsetDistance:{default:8},unstyled:{type:Boolean,default:!1}},emits:["close","update:open"],setup(o,{emit:s}){const t=o,l=s,n=e.ref(t.open),r=e.ref(0),i=e.ref(null),a=e.ref(null),c=e.computed(()=>{switch(t.placement){case"top":return"top-start";case"bottom":return"bottom-start";case"left":return"left-start";case"right":return"right-start";default:return"bottom-start"}}),{floatingStyles:d,update:u}=tt(a,i,{placement:c.value,middleware:[Ge(t.offsetDistance),Qe({fallbackPlacements:["top-start","bottom-start","left-start","right-start"],padding:8}),Ze({padding:8})],whileElementsMounted:vs,strategy:"fixed"}),f=e.inject("parentDropdownOpen",null);e.provide("parentDropdownOpen",n),e.watch(()=>f==null?void 0:f.value,p=>{p===!1&&(n.value=!1)},{immediate:!0}),e.watch(n,p=>{p&&e.nextTick(()=>{u()})});const m=e.computed(()=>N(t.size,"dropdown")),h=e.computed(()=>Js(t.radius));function y(p){var k,$;if(!n.value)return;if(!p){n.value=!1,l("close"),l("update:open",!1);return}(k=i.value)!=null&&k.contains(p.target)||($=a.value)!=null&&$.contains(p.target)||p.target.closest(".cstu-dropdown-menu")||(n.value=!1,l("close"),l("update:open",!1))}e.provide("dropdownClose",y);function g(){t.disabled||(n.value?(n.value=!1,l("close"),l("update:open",!1)):(n.value=!0,l("update:open",!0),setTimeout(()=>{var w,C;(w=i.value)==null||w.focus();const p=(C=i.value)==null?void 0:C.querySelector(".active");p==null||p.scrollIntoView({behavior:"smooth"})},100)))}function b(p){i.value&&(p.key==="ArrowUp"&&r.value>0?(p.preventDefault(),r.value--):p.key==="ArrowDown"&&r.value<i.value.children.length-1&&(p.preventDefault(),r.value++))}function x(p=!1){n.value=!1,!p&&(l("close"),l("update:open",!1))}return(p,w)=>e.withDirectives((e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["cstu-inline-block cstu-text-left cstu-dropdown-container",[{"cstu-relative":p.parentPositionRelative},{"cstu-grayscale cstu-filter cstu-cursor-not-allowed cstu-opacity-70":p.disabled},p.containerClasses]])},[e.createElementVNode("button",{ref_key:"buttonRef",ref:a,type:"button",class:e.normalizeClass([!p.unstyled&&"cstu-text-gray-500 cstu-inline-flex cstu-overflow-hidden cstu-text-ellipsis cstu-whitespace-pre cstu-justify-between cstu-items-center cstu-w-full focus:cstu-outline-none",!p.unstyled&&h.value,!p.unstyled&&m.value,{"cstu-pointer-events-none":p.disabled},p.buttonClasses||!p.unstyled&&"cstu-border cstu-border-gray-400/20 hover:cstu-bg-gray-100/50 hover:cstu-border-gray-400/25"]),"aria-expanded":"true","aria-haspopup":"true",onClick:g},[e.renderSlot(p.$slots,"icon",{closeDropdown:x}),e.renderSlot(p.$slots,"selected",{closeDropdown:x},()=>[w[0]||(w[0]=e.createTextVNode("Select"))]),p.showArrow?(e.openBlock(),e.createElementBlock("span",{key:0,class:e.normalizeClass(["cstu-transition cstu-leading-none",{"cstu-rotate-180":n.value}])},[e.renderSlot(p.$slots,"arrow",{closeDropdown:x},()=>[w[1]||(w[1]=e.createStaticVNode('<svg xmlns="http://www.w3.org/2000/svg" width="12" height="12" viewBox="0 0 12 12" fill="none"><g clip-path="url(#clip0_33663_12905)"><path d="M6 8.95312C5.91113 8.95312 5.82739 8.93604 5.74878 8.90186C5.67017 8.86768 5.6001 8.81982 5.53857 8.7583L0.93457 4.1543C0.886719 4.09961 0.845703 4.03467 0.811523 3.95947C0.777344 3.88428 0.760254 3.80225 0.760254 3.71338C0.760254 3.53564 0.823486 3.38354 0.949951 3.25708C1.07642 3.13062 1.23193 3.06738 1.4165 3.06738C1.49854 3.06738 1.57715 3.08276 1.65234 3.11353C1.72754 3.14429 1.7959 3.18701 1.85742 3.2417L6 7.40479L10.1426 3.2417C10.2041 3.18701 10.2725 3.14429 10.3477 3.11353C10.4229 3.08276 10.5015 3.06738 10.5835 3.06738C10.7681 3.06738 10.9236 3.13062 11.05 3.25708C11.1765 3.38354 11.2397 3.53564 11.2397 3.71338C11.2397 3.80225 11.2227 3.88428 11.1885 3.95947C11.1543 4.03467 11.1133 4.09961 11.0654 4.1543L6.46143 8.7583C6.3999 8.81982 6.32983 8.86768 6.25122 8.90186C6.17261 8.93604 6.08887 8.95312 6 8.95312Z" fill="#99A3A9"></path></g><defs><clipPath id="clip0_33663_12905"><rect width="10.5" height="11" fill="white" transform="matrix(1 0 0 -1 0.75 11.5)"></rect></clipPath></defs></svg>',1))])],2)):e.createCommentVNode("",!0)],2),e.createVNode(e.Transition,{"enter-active-class":"cstu-transition cstu-ease-out cstu-duration-100","enter-from-class":"cstu-transform cstu-opacity-0 cstu-scale-95","enter-to-class":"cstu-transform cstu-opacity-100 cstu-scale-100","leave-active-class":"cstu-transition cstu-ease-in cstu-duration-75","leave-from-class":"cstu-transform cstu-opacity-100 cstu-scale-100","leave-to-class":"cstu-transform cstu-opacity-0 cstu-scale-95"},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.withDirectives(e.createElementVNode("div",{ref_key:"dropdownList",ref:i,style:e.normalizeStyle(e.unref(d)),class:e.normalizeClass(["cstu-dropdown-menu cstu-max-h-72 cstu-px-[12px] cstu-py-[13px] cstu-min-w-[225px] cstu-overflow-y-auto cstu-origin-top-left cstu-rounded-lg cstu-shadow-custom cstu-bg-white focus:cstu-outline-none cstu-z-50",[h.value,p.dropdownClasses]])},[e.createElementVNode("div",{class:"cstu-flex cstu-flex-col cstu-gap-[11px]",role:"menu","aria-orientation":"vertical","aria-labelledby":"menu-button","data-active":r.value,tabindex:"-1",onKeydown:b},[e.renderSlot(p.$slots,"default",{closeDropdown:x})],40,eo)],6),[[e.vShow,n.value]])]))]),_:3})],2)),[[e.unref(Qs),y]])}}),so=e.defineComponent({__name:"DropdownItem",props:{disabled:{type:Boolean,default:!1},closeOnClick:{type:Boolean,default:!0},class:{default:""},selected:{type:Boolean,default:!1},size:{default:"md"}},emits:["click"],setup(o,{emit:s}){const t=o,l=s,n=e.inject("dropdownClose",()=>{}),r=e.computed(()=>t.class);function i(){t.disabled||(t.closeOnClick&&n(),l("click"))}return(a,c)=>(e.openBlock(),e.createElementBlock("div",{role:"menuitem",tabindex:"-1",class:e.normalizeClass(["cstu-cursor-pointer hover:cstu-bg-blue-50 active:cstu-bg-blue-50 cstu-rounded-lg",e.unref(ye)(t.size),"cstu-py-[5.5px] cstu-pr-[13.5px] cstu-pl-[10.5px]",{"cstu-cursor-not-allowed cstu-bg-gray-100":a.disabled},{"cstu-bg-blue-50":a.selected},r.value]),onClick:i},[e.renderSlot(a.$slots,"default",{selected:a.selected})],2))}}),lt=e.defineComponent({__name:"ListItem",props:{disabled:{type:Boolean,default:!1},selected:{type:Boolean,default:!1},class:{default:""},selectedClass:{default:""}},emits:["click"],setup(o,{emit:s}){const t=o,l=s,n=e.computed(()=>t.class);function r(){t.disabled||l("click")}return(i,a)=>(e.openBlock(),e.createElementBlock("div",{role:"listitem",tabindex:"-1",class:e.normalizeClass(["cstu-cursor-pointer cstu-rounded-lg","cstu-py-[5.5px] cstu-pr-[13.5px] cstu-pl-[10.5px]",{"hover:cstu-bg-blue-50 active:cstu-bg-blue-50":!i.disabled},{"cstu-cursor-not-allowed cstu-bg-gray-100 ":i.disabled},{[i.selectedClass||"cstu-bg-blue-50"]:i.selected&&!i.disabled},n.value]),onClick:r},[e.renderSlot(i.$slots,"default",{selected:i.selected})],2))}}),oo=e.defineComponent({__name:"Collapsible",props:{defaultOpen:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},class:{default:""},hideArrow:{type:Boolean,default:!1},buttonClass:{default:""},selectedClass:{default:""},modelValue:{type:Boolean,default:void 0}},emits:["update:modelValue"],setup(o,{emit:s}){const t=o,l=s,n=e.computed(()=>t.modelValue!==void 0),r=e.computed({get:()=>n.value?t.modelValue??!1:i.value,set:d=>{n.value?l("update:modelValue",d):i.value=d}}),i=e.ref(t.defaultOpen),a=e.computed(()=>t.class);function c(){t.disabled||(r.value=!r.value)}return(d,u)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["space-y-1 cstu-select-none",a.value])},[e.createVNode(lt,{role:"button",disabled:d.disabled,class:e.normalizeClass(["cstu-flex cstu-items-center cstu-justify-between",d.buttonClass].join(" ")),"selected-class":d.selectedClass,selected:r.value,onClick:c},{default:e.withCtx(()=>[e.renderSlot(d.$slots,"trigger",{open:r.value}),d.hideArrow?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("svg",{key:0,xmlns:"http://www.w3.org/2000/svg",width:"10",height:"7",viewBox:"0 0 10 7",fill:"none",class:e.normalizeClass(["cstu-transform cstu-transition-transform cstu-duration-200",{"cstu-rotate-180":r.value}])},u[0]||(u[0]=[e.createElementVNode("path",{d:"M5.64844 0.919922L9.81641 5.08789C9.91667 5.18815 9.9668 5.3099 9.9668 5.45312C9.9668 5.59635 9.91667 5.7181 9.81641 5.81836L9.34375 6.29102C9.24349 6.39128 9.12174 6.44499 8.97852 6.45215C8.83529 6.45931 8.71354 6.41276 8.61328 6.3125L5.2832 2.98242L1.95312 6.3125C1.85286 6.41276 1.73112 6.45931 1.58789 6.45215C1.44466 6.44499 1.32292 6.39128 1.22266 6.29102L0.75 5.81836C0.649739 5.7181 0.599609 5.59635 0.599609 5.45312C0.599609 5.3099 0.649739 5.18815 0.75 5.08789L4.91797 0.919922C5.01823 0.805339 5.13997 0.748047 5.2832 0.748047C5.42643 0.748047 5.54818 0.805339 5.64844 0.919922Z",fill:"#75797C"},null,-1)]),2))]),_:3},8,["disabled","class","selected-class","selected"]),e.createVNode(e.Transition,{"enter-active-class":"cstu-transition cstu-duration-100 cstu-ease-out","enter-from-class":"cstu-transform cstu-scale-95 cstu-opacity-0","enter-to-class":"cstu-transform cstu-scale-100 cstu-opacity-100","leave-active-class":"cstu-transition cstu-duration-75 cstu-ease-in","leave-from-class":"cstu-transform cstu-scale-100 cstu-opacity-100","leave-to-class":"cstu-transform cstu-scale-95 cstu-opacity-0"},{default:e.withCtx(()=>[e.withDirectives(e.createElementVNode("div",null,[e.renderSlot(d.$slots,"default")],512),[[e.vShow,r.value]])]),_:3})],2))}}),Re={none:"rounded-none",xs:"rounded",sm:"rounded-md",md:"rounded-lg",lg:"rounded-xl",xl:"rounded-2xl",full:"rounded-full"},no=["onClick","data-value"],lo=e.defineComponent({name:"SegmentedControl",__name:"SegmentedControl",props:{modelValue:{default:""},data:{},size:{default:"md"},radius:{default:"md"},color:{default:"primary"},disabled:{type:Boolean,default:!1},fullWidth:{type:Boolean,default:!1},transitionDuration:{default:200},withItemsBorders:{type:Boolean,default:!1},orientation:{default:"horizontal"}},emits:["update:modelValue"],setup(o,{emit:s}){const t=s,l=o,n=e.ref({}),r=e.ref(null),i=e.computed(()=>l.data.map(u=>typeof u=="string"?{value:u,label:u}:u)),a=e.computed(()=>l.orientation==="horizontal"?"cstu-flex-row":"cstu-flex-col"),c=async()=>{if(!l.modelValue)return;await e.nextTick();const u=n.value[l.modelValue];if(!u)return;const f=u.getBoundingClientRect(),m=u.parentElement.getBoundingClientRect();r.value={left:f.left-m.left,top:f.top-m.top,width:f.width,height:f.height}},d=u=>{t("update:modelValue",u)};return e.watch(()=>l.modelValue,c),e.watch(()=>l.orientation,c),e.onMounted(()=>{c(),window.addEventListener("resize",c)}),e.onUnmounted(()=>{window.removeEventListener("resize",c)}),(u,f)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["cstu-relative cstu-inline-flex",a.value,{"cstu-w-full":u.fullWidth,"cstu-opacity-50 cstu-pointer-events-none":u.disabled}]),role:"radiogroup"},[r.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["cstu-absolute cstu-bg-white cstu-rounded-[inherit]",e.unref(Re)[u.radius]]),style:e.normalizeStyle({transform:`translate(${r.value.left}px, ${r.value.top}px)`,width:`${r.value.width}px`,height:`${r.value.height}px`,transition:`transform ${u.transitionDuration}ms ease`,boxShadow:"0 1px 2px 0 rgb(0 0 0 / 0.05)"})},null,6)):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass(["cstu-relative cstu-flex",a.value,e.unref(Re)[u.radius],{"cstu-w-full":u.fullWidth,"cstu-divide-x cstu-divide-gray-200":u.withItemsBorders&&u.orientation==="horizontal","cstu-divide-y cstu-divide-gray-200":u.withItemsBorders&&u.orientation==="vertical"},e.unref(N)(u.size,"segmentedControlContainer"),"cstu-bg-gray-100"])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,m=>(e.openBlock(),e.createElementBlock("div",{key:m.value,class:e.normalizeClass(["cstu-relative cstu-flex-1","cstu-transition-all cstu-duration-200",e.unref(dt)(!!m.disabled),l.modelValue===m.value?"cstu-bg-white cstu-border-gray-500/15":"cstu-border-transparent",e.unref(N)(u.size,"segmentedControl"),"cstu-cursor-pointer","cstu-flex cstu-items-center cstu-justify-center hover:cstu-border-gray-500/15 cstu-border",e.unref(Re)[u.radius]]),onClick:()=>!m.disabled&&d(m.value),"data-value":m.value,ref_for:!0,ref:"el => segmentRefs[option.value] = el"},[e.createElementVNode("span",{class:e.normalizeClass([e.unref(xe)({size:u.size,disabled:m.disabled}),l.modelValue===m.value?"cstu-text-gray-500":"cstu-text-gray-600","cstu-select-none !cstu-mb-0 !cstu-font-normal cstu-capitalize cstu-whitespace-nowrap"])},e.toDisplayString(m.label),3)],10,no))),128))],2)],2))}}),go="";B.Alert=Zt,B.Badge=Zs,B.Button=gt,B.Checkbox=bt,B.Chip=It,B.Collapse=Qt,B.Collapsible=oo,B.Dialog=is,B.Dropdown=to,B.DropdownItem=so,B.HoverCard=nt,B.HoverCardTarget=Oe,B.Indicator=Ht,B.ListItem=lt,B.Loader=os,B.Progress=Yt,B.Radio=Bt,B.SegmentedControl=lo,B.Select=Pt,B.TextInput=St,B.composables=Ks,B.hoverCardInjectionKey=Le,B.useHoverCard=ot,Object.defineProperty(B,Symbol.toStringTag,{value:"Module"})});
1
+ (function(B,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],e):(B=typeof globalThis<"u"?globalThis:B||self,e(B.ContentStudioDesignSystem={},B.Vue))})(this,function(B,e){"use strict";const ge={primary:{base:"blue",light:"50",main:"500",dark:"600",hover:"550",border:"600",focus:"600"},secondary:{base:"gray",light:"200",main:"575",dark:"700",hover:"600",border:"600",focus:"500"},success:{base:"green",light:"50",main:"500",dark:"700",hover:"600",border:"200",focus:"500"},warning:{base:"yellow",light:"50",main:"500",dark:"700",hover:"600",border:"200",focus:"500"},danger:{base:"red",light:"50",main:"500",dark:"700",hover:"600",border:"200",focus:"500"},info:{base:"sea-blue",light:"50",main:"500",dark:"700",hover:"600",border:"200",focus:"500"},dark:{base:"gray",light:"100",main:"900",dark:"950",hover:"800",border:"300",focus:"700"},light:{base:"gray",light:"50",main:"300",dark:"500",hover:"400",border:"200",focus:"300"}},F=(o,s,t={})=>{const{hover:l=!1,active:n=!1,focus:r=!1,disabled:i=!1}=t;if(i)return"cstu-bg-gray-100 cstu-border-gray-200 cstu-text-gray-400 cstu-cursor-not-allowed";const a=ge[o];if(!a||s==="default")return"";if(s==="text")return[`cstu-text-${a.base}-${a.main}`,l&&`hover:cstu-text-${a.base}-${a.hover}`,n&&`active:cstu-text-${a.base}-${a.dark}`,r&&`focus:cstu-text-${a.base}-${a.focus}`,i&&"cstu-opacity-50 cstu-cursor-not-allowed"].filter(Boolean);const c=[];switch(s){case"filled":c.push(`cstu-bg-${a.base}-${a.main}`),c.push("cstu-text-white"),l&&c.push(`hover:cstu-bg-${a.base}-${a.hover} hover:cstu-shadow-md`),n&&c.push(`active:cstu-bg-${a.base}-${a.dark}`),r&&c.push(`focus:cstu-ring-${a.base}-${a.focus}/20`);break;case"light":c.push(`cstu-bg-${a.base}-${a.light}`),c.push(`cstu-text-${a.base}-${a.main}`),l&&c.push(`hover:cstu-bg-${a.base}-250`),n&&c.push(`active:cstu-bg-${a.base}-300 active:!cstu-text-white`),r&&c.push(`focus:cstu-ring-${a.base}-${a.focus}/20`);break;case"outline":c.push("cstu-bg-white"),c.push(`cstu-text-${a.base}-${a.main}`),c.push(`cstu-border cstu-border-${a.base}-${a.main}`),l&&c.push(`hover:cstu-bg-${a.base}-50`),n&&c.push(`active:cstu-bg-${a.base}-100`),r&&c.push(`focus:cstu-ring-${a.base}-${a.focus}/20`);break;case"subtle":c.push(`cstu-text-${a.base}-${a.main}`),l&&c.push(`hover:cstu-bg-${a.base}-50`),n&&c.push(`active:cstu-bg-${a.base}-100`),r&&c.push(`focus:cstu-ring-${a.base}-${a.focus}/20`);break;case"white":c.push("cstu-bg-white cstu-text-gray-900"),l&&c.push("hover:cstu-bg-gray-50"),n&&c.push("active:cstu-bg-gray-100"),r&&c.push("focus:cstu-ring-gray-200");break;case"dot":c.push(`cstu-bg-${a.base}-${a.main}`);break;case"bordered":c.push("cstu-bg-white"),c.push(`cstu-text-${a.base}-${a.main}`),c.push(`cstu-border cstu-border-${a.base}-${a.border}`),l&&c.push(`hover:cstu-bg-${a.base}-50 hover:cstu-border-${a.base}-${a.main}`),n&&c.push(`active:cstu-bg-${a.base}-100`),r&&c.push(`focus:cstu-ring-${a.base}-${a.focus}/20`);break;case"bordered-transparent":c.push("cstu-bg-transparent"),c.push(`cstu-text-${a.base}-${a.main}`),c.push(`cstu-border cstu-border-${a.base}-${a.border}`),l&&c.push(`hover:cstu-bg-${a.base}-50/10 hover:cstu-border-${a.base}-${a.main}`),n&&c.push(`active:cstu-bg-${a.base}-100/20`),r&&c.push(`focus:cstu-ring-${a.base}-${a.focus}/20`);break}return c.join(" ")},rt=(o,s)=>{if(s==="filled")return"cstu-text-white";const t=ge[o];return`cstu-text-${t.base}-${t.main}`},at=(o,s)=>{if(s==="filled")return"cstu-text-white";const t=ge[o];return`cstu-text-${t.base}-${t.main}`},it=o=>{const s=["cstu-shadow-sm","cstu-transition-all cstu-duration-200"];switch(o){case"filled":s.push("cstu-border-transparent");break;case"light":s.push("cstu-border");break;case"outline":s.push("cstu-border");break;case"subtle":s.push("cstu-shadow-none");break;case"white":s.push("cstu-border");break;default:s.push("cstu-border")}return s.join(" ")},he={button:{xs:{height:"cstu-h-[30px]",gap:"cstu-gap-[0.55rem]",padding:{x:"cstu-px-[0.67rem]",y:"cstu-py-[0.67rem]"},text:"cstu-text-xs cstu-leading-none",icon:"cstu-w-3 cstu-h-3"},sm:{height:"cstu-h-[36px]",gap:"cstu-gap-[0.66rem]",padding:{x:"cstu-px-[0.8rem]",y:"cstu-py-[0.8rem]"},text:"cstu-text-sm cstu-leading-none",icon:"cstu-w-4 cstu-h-4"},md:{height:"cstu-h-[40px]",gap:"cstu-gap-[0.74rem]",padding:{x:"cstu-px-[0.89rem]",y:"cstu-py-[0.89rem]"},text:"cstu-text-base cstu-leading-none",icon:"cstu-w-5 cstu-h-5"},lg:{height:"cstu-h-[45px]",gap:"cstu-gap-[0.83rem]",padding:{x:"cstu-px-4",y:"cstu-py-4"},text:"cstu-text-lg cstu-leading-none",icon:"cstu-w-6 cstu-h-6"},xl:{height:"cstu-h-[50px]",gap:"cstu-gap-[0.92rem]",padding:{x:"cstu-px-[1.11rem]",y:"cstu-py-[1.11rem]"},text:"cstu-text-xl cstu-leading-none",icon:"cstu-w-7 cstu-h-7"}},badge:{xs:{padding:{x:"cstu-px-2",y:"cstu-py-0.5"},text:"cstu-text-xs",icon:"cstu-w-3 cstu-h-3"},sm:{padding:{x:"cstu-px-2.5",y:"cstu-py-1"},text:"cstu-text-sm",icon:"cstu-w-3.5 cstu-h-3.5"},md:{padding:{x:"cstu-px-3",y:"cstu-py-1.5"},text:"cstu-text-base",icon:"cstu-w-4 cstu-h-4"},lg:{padding:{x:"cstu-px-4",y:"cstu-py-2"},text:"cstu-text-lg",icon:"cstu-w-5 cstu-h-5"},xl:{padding:{x:"cstu-px-5",y:"cstu-py-2.5"},text:"cstu-text-xl",icon:"cstu-w-6 cstu-h-6"}},input:{xs:{padding:{x:"cstu-px-2",y:"cstu-py-1"},text:"cstu-text-xs",height:"cstu-h-7"},sm:{padding:{x:"cstu-px-3",y:"cstu-py-1.5"},text:"cstu-text-sm",height:"cstu-h-8"},md:{padding:{x:"cstu-px-3",y:"cstu-py-2"},text:"cstu-text-base",height:"cstu-h-10"},lg:{padding:{x:"cstu-px-4",y:"cstu-py-2.5"},text:"cstu-text-lg",height:"cstu-h-11"},xl:{padding:{x:"cstu-px-4",y:"cstu-py-3"},text:"cstu-text-xl",height:"cstu-h-12"}},notification:{xs:{padding:{x:"cstu-px-3",y:"cstu-py-2"},text:"cstu-text-xs"},sm:{padding:{x:"cstu-px-4",y:"cstu-py-2.5"},text:"cstu-text-sm"},md:{padding:{x:"cstu-px-4",y:"cstu-py-3"},text:"cstu-text-base"},lg:{padding:{x:"cstu-px-5",y:"cstu-py-4"},text:"cstu-text-lg"},xl:{padding:{x:"cstu-px-6",y:"cstu-py-5"},text:"cstu-text-xl"}},switch:{xs:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-xs",height:"cstu-h-4"},sm:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-sm",height:"cstu-h-5"},md:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-base",height:"cstu-h-6"},lg:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-lg",height:"cstu-h-7"},xl:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-xl",height:"cstu-h-8"}},chip:{xs:{padding:{x:"cstu-px-1.5",y:"cstu-py-0.5"},text:"cstu-text-xs",icon:"cstu-w-2.5 cstu-h-2.5"},sm:{padding:{x:"cstu-px-2",y:"cstu-py-1"},text:"cstu-text-sm",icon:"cstu-w-3 cstu-h-3"},md:{padding:{x:"cstu-px-2.5",y:"cstu-py-1.5"},text:"cstu-text-base",icon:"cstu-w-3.5 cstu-h-3.5"},lg:{padding:{x:"cstu-px-3",y:"cstu-py-2"},text:"cstu-text-lg",icon:"cstu-w-4 cstu-h-4"},xl:{padding:{x:"cstu-px-3.5",y:"cstu-py-2.5"},text:"cstu-text-xl",icon:"cstu-w-4.5 cstu-h-4.5"}},checkbox:{xs:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-xs",icon:"cstu-w-2 cstu-h-2"},sm:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-sm",icon:"cstu-w-2.5 cstu-h-2.5"},md:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-base",icon:"cstu-w-3 cstu-h-3"},lg:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-lg",icon:"cstu-w-4 cstu-h-4"},xl:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-xl",icon:"cstu-w-5 cstu-h-5"}},indicator:{xs:{padding:{x:"cstu-px-0.5",y:"cstu-py-0.5"},text:"cstu-text-[10px]",height:"cstu-h-3.5 cstu-min-w-3.5"},sm:{padding:{x:"cstu-px-1",y:"cstu-py-0.5"},text:"cstu-text-[11px]",height:"cstu-h-4 cstu-min-w-4"},md:{padding:{x:"cstu-px-1.5",y:"cstu-py-0.5"},text:"cstu-text-xs",height:"cstu-h-5 cstu-min-w-5"},lg:{padding:{x:"cstu-px-2",y:"cstu-py-0.5"},text:"cstu-text-xs",height:"cstu-h-6 cstu-min-w-6"},xl:{padding:{x:"cstu-px-2.5",y:"cstu-py-0.5"},text:"cstu-text-sm",height:"cstu-h-7 cstu-min-w-7"}},progress:{xs:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-xs",height:"cstu-h-1"},sm:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-sm",height:"cstu-h-1.5"},md:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-base",height:"cstu-h-2"},lg:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-sm",height:"cstu-h-6"},xl:{padding:{x:"cstu-px-0",y:"cstu-py-0"},text:"cstu-text-base",height:"cstu-h-8"}},alert:{xs:{padding:{x:"cstu-px-3",y:"cstu-py-2"},text:"cstu-text-xs",icon:"cstu-w-4 cstu-h-4"},sm:{padding:{x:"cstu-px-3",y:"cstu-py-2.5"},text:"cstu-text-sm",icon:"cstu-w-5 cstu-h-5"},md:{padding:{x:"cstu-px-4",y:"cstu-py-3"},text:"cstu-text-base",icon:"cstu-w-5 cstu-h-5"},lg:{padding:{x:"cstu-px-5",y:"cstu-py-4"},text:"cstu-text-lg",icon:"cstu-w-6 cstu-h-6"},xl:{padding:{x:"cstu-px-6",y:"cstu-py-5"},text:"cstu-text-xl",icon:"cstu-w-7 cstu-h-7"}},segmentedControl:{xs:{gap:"cstu-gap-[8px]",padding:{x:"cstu-px-[10.5px]",y:"cstu-py-[3.5px]"},text:"cstu-text-xs",height:"cstu-h-6"},sm:{gap:"cstu-gap-[9px]",padding:{x:"cstu-px-[12px]",y:"cstu-py-[4px]"},text:"cstu-text-sm",height:"cstu-h-8"},md:{gap:"cstu-gap-[10px]",padding:{x:"cstu-px-[13.5px]",y:"cstu-py-[4.5px]"},text:"cstu-text-base",height:"cstu-h-10"},lg:{gap:"cstu-gap-[11px]",padding:{x:"cstu-px-[15px]",y:"cstu-py-[5px]"},text:"cstu-text-lg",height:"cstu-h-12"},xl:{gap:"cstu-gap-[12px]",padding:{x:"cstu-px-[16.5px]",y:"cstu-py-[5.5px]"},text:"cstu-text-xl",height:"cstu-h-14"}},segmentedControlContainer:{xs:{gap:"cstu-gap-[5.25px]",padding:{x:"cstu-px-[5.25px]",y:"cstu-py-[5.25px]"}},sm:{gap:"cstu-gap-[6px]",padding:{x:"cstu-px-[6px]",y:"cstu-py-[6px]"}},md:{gap:"cstu-gap-[6.75px]",padding:{x:"cstu-px-[6.75px]",y:"cstu-py-[6.75px]"}},lg:{gap:"cstu-gap-[7.5px]",padding:{x:"cstu-px-[7.5px]",y:"cstu-py-[7.5px]"}},xl:{gap:"cstu-gap-[8.25px]",padding:{x:"cstu-px-[8.25px]",y:"cstu-py-[8.25px]"}}},dropdown:{xs:{padding:{x:"cstu-px-[12px]",y:"cstu-py-[7px]"},text:"cstu-text-xs",height:void 0,icon:void 0,gap:"cstu-gap-[9px]"},sm:{padding:{x:"cstu-px-[12px]",y:"cstu-py-[7px]"},text:"cstu-text-sm",height:void 0,icon:void 0,gap:"cstu-gap-[9px]"},md:{padding:{x:"cstu-px-[12px]",y:"cstu-py-[7px]"},text:"cstu-text-base",height:void 0,icon:void 0,gap:"cstu-gap-[9px]"},lg:{padding:{x:"cstu-px-[12px]",y:"cstu-py-[7px]"},text:"cstu-text-lg",height:void 0,icon:void 0,gap:"cstu-gap-[9px]"},xl:{padding:{x:"cstu-px-[12px]",y:"cstu-py-[7px]"},text:"cstu-text-xl",height:void 0,icon:void 0,gap:"cstu-gap-[9px]"}}},N=(o,s)=>{var t,l;if(typeof s=="string"){const n=he[s][o];return[(t=n==null?void 0:n.padding)==null?void 0:t.x,(l=n==null?void 0:n.padding)==null?void 0:l.y,n==null?void 0:n.text,n==null?void 0:n.gap].filter(Boolean).join(" ")}return s[o]},ct=(o,s)=>he[s][o].icon||"",ae=(o,s)=>he[s][o].height||"",ye=o=>{switch(o){case"xs":return"cstu-text-xs";case"sm":return"cstu-text-sm";case"md":return"cstu-text-base";case"lg":return"cstu-text-lg";case"xl":return"cstu-text-xl";default:return"cstu-text-base"}},Ae=o=>{switch(o){case"xs":return"cstu-space-x-1";case"sm":return"cstu-space-x-2";case"md":return"cstu-space-x-3";case"lg":return"cstu-space-x-4";case"xl":return"cstu-space-x-5";default:return"cstu-space-x-3"}},W=o=>{const s=[];return o.disabled&&s.push("cstu-opacity-50 cstu-cursor-not-allowed cstu-pointer-events-none"),o.loading&&s.push("cstu-cursor-wait"),o.active&&s.push("cstu-ring-2 cstu-ring-offset-2"),o.error&&s.push("cstu-border-red-300 focus:cstu-ring-red-500/20 focus:cstu-border-red-500"),o.success&&s.push("cstu-border-green-300 focus:cstu-ring-green-500/20 focus:cstu-border-green-500"),s.join(" ")},dt=o=>o?"cstu-opacity-50 cstu-cursor-not-allowed cstu-pointer-events-none":"",ut=o=>{const s=[];return o.valid&&s.push("cstu-border-green-300 focus:cstu-ring-green-500/20 focus:cstu-border-green-500"),o.invalid&&s.push("cstu-border-red-300 focus:cstu-ring-red-500/20 focus:cstu-border-red-500"),o.pending&&s.push("cstu-border-yellow-300 focus:cstu-ring-yellow-500/20 focus:cstu-border-yellow-500"),s.join(" ")},pt=(o,s="primary")=>{const t=[];return o.hover&&t.push(`hover:cstu-bg-${s}-50`),o.active&&t.push(`active:cstu-bg-${s}-100`),o.focus&&t.push(`focus:cstu-outline-none focus:cstu-ring-2 focus:cstu-ring-${s}-500/20 focus:cstu-border-${s}-500`),t.join(" ")},ft=["disabled","type"],mt={key:0},gt=e.defineComponent({__name:"Button",props:{variant:{default:"filled"},color:{default:"primary"},size:{default:"md"},radius:{default:"md"},disabled:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},fullWidth:{type:Boolean,default:!1},type:{default:"button"},gradient:{}},emits:{click:o=>!0},setup(o,{emit:s}){const t=o,l=s,n=c=>{!t.disabled&&!t.loading&&l("click",c)},r=c=>({none:"cstu-rounded-none",xs:"cstu-rounded",sm:"cstu-rounded-md",md:"cstu-rounded-lg",lg:"cstu-rounded-xl",xl:"cstu-rounded-2xl",full:"cstu-rounded-full"})[c]||"cstu-rounded-lg",i=c=>{if(!c)return"bg-gradient-to-r";const d=(c%360+360)%360;return d>=337.5||d<22.5?"cstu-bg-gradient-to-r":d>=22.5&&d<67.5?"cstu-bg-gradient-to-tr":d>=67.5&&d<112.5?"cstu-bg-gradient-to-t":d>=112.5&&d<157.5?"cstu-bg-gradient-to-tl":d>=157.5&&d<202.5?"cstu-bg-gradient-to-l":d>=202.5&&d<247.5?"cstu-bg-gradient-to-bl":d>=247.5&&d<292.5?"cstu-bg-gradient-to-b":"cstu-bg-gradient-to-br"},a=e.computed(()=>{const c="cstu-inline-flex cstu-items-center cstu-justify-center cstu-font-medium cstu-transition-all cstu-duration-200";if(t.variant==="gradient"&&t.gradient){const b=`${i(t.gradient.deg)} cstu-from-${t.gradient.from}-500 cstu-to-${t.gradient.to||t.gradient.from}-600 hover:cstu-from-${t.gradient.from}-600 hover:cstu-to-${t.gradient.to||t.gradient.from}-700 cstu-text-white`;return[c,b,N(t.size,"button"),r(t.radius),W({disabled:t.disabled,loading:t.loading}),{"cstu-w-full":t.fullWidth,"cstu-cursor-pointer":!t.disabled&&!t.loading}]}const d=F(t.color,t.variant,{hover:!0,active:!0,focus:!0}),u=N(t.size,"button"),f=W({disabled:t.disabled,loading:t.loading}),m=ae(t.size,"button"),h=r(t.radius);return[c,d,u,m,f,h,{"cstu-w-full":t.fullWidth,"cstu-cursor-pointer":!t.disabled&&!t.loading}]});return(c,d)=>(e.openBlock(),e.createElementBlock("button",{class:e.normalizeClass(a.value),disabled:c.disabled||c.loading,type:c.type,onClick:n},[e.renderSlot(c.$slots,"leftSection"),e.renderSlot(c.$slots,"default"),c.loading?(e.openBlock(),e.createElementBlock("span",mt,[e.renderSlot(c.$slots,"loader",{},()=>[d[0]||(d[0]=e.createElementVNode("svg",{class:"cstu-animate-spin cstu-h-4 cstu-w-4",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24"},[e.createElementVNode("circle",{class:"cstu-opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor","stroke-width":"4"}),e.createElementVNode("path",{class:"cstu-opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"})],-1))])])):e.createCommentVNode("",!0),e.renderSlot(c.$slots,"rightSection")],10,ft))}}),_e=o=>{const s=["cstu-relative"];o.fullWidth&&s.push("cstu-w-full");const t=W({disabled:o.disabled,error:o.error,required:o.required||o.withAsterisk});return t&&s.push(t),s.join(" ")},xe=o=>{const s=["cstu-block","cstu-font-medium","cstu-mb-1"];switch(o.size){case"xs":s.push("cstu-text-xs");break;case"sm":s.push("cstu-text-sm");break;case"md":s.push("cstu-text-base");break;case"lg":s.push("cstu-text-lg");break;case"xl":s.push("cstu-text-xl");break;default:s.push("cstu-text-sm")}return o.error?s.push("cstu-text-red-500"):o.disabled?s.push("cstu-text-gray-400"):s.push("cstu-text-gray-700"),(o.required||o.withAsterisk)&&s.push('after:cstu-content-["*"] after:cstu-ml-0.5 after:cstu-text-red-500'),s.join(" ")},Pe=o=>{const s=["cstu-mt-1","cstu-text-sm"];return o.error?s.push("cstu-text-red-500"):o.disabled?s.push("cstu-text-gray-400"):s.push("cstu-text-gray-500"),s.join(" ")},ht=["aria-disabled","onKeydown"],yt={key:2,class:"cstu-text-sm cstu-text-red-500 cstu-mt-0.5"},xt={name:"Checkbox"},bt=e.defineComponent({...xt,props:{modelValue:{type:[Boolean,Array],default:!1},checked:{type:Boolean,default:!1},value:{},id:{},label:{},color:{default:"primary"},size:{default:"md"},labelPosition:{default:"right"},description:{},error:{},disabled:{type:Boolean,default:!1},indeterminate:{type:Boolean,default:!1},variant:{default:"filled"}},emits:["update:modelValue","change"],setup(o,{emit:s}){const t=o,l=s,n=e.computed(()=>t.modelValue||t.checked),r=()=>{if(t.disabled)return;const y=!n.value;l("update:modelValue",y),l("change",y)},i=()=>{r()},a=e.computed(()=>xe({size:t.size,disabled:t.disabled,error:t.error})),c=e.computed(()=>Pe({color:t.color})),d=e.computed(()=>["cstu-flex","cstu-flex-col",t.labelPosition==="left"?"cstu-order-first":""]),u={primary:"blue-450",secondary:"gray-500",success:"green-500",warning:"yellow-500",danger:"red-500",info:"blue-500",dark:"gray-900",light:"gray-300"},f=e.computed(()=>["cstu-inline-flex","cstu-items-center","cstu-justify-center","cstu-cursor-pointer","cstu-transition-colors","cstu-duration-200","cstu-ease-in-out",t.size==="xs"?"cstu-h-[12px] cstu-w-[12px] cstu-rounded":"",t.size==="sm"?"cstu-h-[14px] cstu-w-[14px] cstu-rounded":"",t.size==="md"?"cstu-h-[16px] cstu-w-[16px] cstu-rounded-md":"",t.size==="lg"?"cstu-h-[18px] cstu-w-[18px] cstu-rounded-md":"",t.size==="xl"?"cstu-h-[20px] cstu-w-[20px] cstu-rounded-md":"",t.disabled?"cstu-bg-gray-200 cstu-border cstu-border-gray-200 cstu-cursor-not-allowed":n.value||t.indeterminate?t.variant==="outlined"?`cstu-bg-transparent cstu-border cstu-border-${u[t.color]}`:`cstu-bg-${u[t.color]} cstu-border-${u[t.color]}`:"cstu-bg-white cstu-border cstu-border-gray-400/50"]),m=e.computed(()=>[t.variant==="outlined"&&(n.value||t.indeterminate)?`cstu-text-${u[t.color]}`:t.disabled?"cstu-text-gray-300":"cstu-text-white",t.size==="xs"?"cstu-h-[6px] cstu-w-[6px]":"",t.size==="sm"?"cstu-h-[7px] cstu-w-[7px]":"",t.size==="md"?"cstu-h-[8px] cstu-w-[8px]":"",t.size==="lg"?"cstu-h-[9px] cstu-w-[9px]":"",t.size==="xl"?"cstu-h-[10px] cstu-w-[10px]":""]),h=e.computed(()=>_e({disabled:t.disabled,error:t.error}));return(y,g)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass([h.value,"cstu-flex cstu-items-center cstu-gap-2"])},[e.createElementVNode("div",{class:e.normalizeClass(f.value),onClick:i,role:"checkbox","aria-disabled":y.disabled,tabindex:"0",onKeydown:e.withKeys(e.withModifiers(i,["prevent"]),["space"])},[n.value&&!y.indeterminate?(e.openBlock(),e.createElementBlock("svg",{key:0,class:e.normalizeClass(m.value),xmlns:"http://www.w3.org/2000/svg",width:"8",height:"6",viewBox:"0 0 8 6",fill:"none"},g[0]||(g[0]=[e.createElementVNode("path",{d:"M6.75 0.75L2.625 5.25L0.75 3.20455",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)]),2)):e.createCommentVNode("",!0),y.indeterminate?(e.openBlock(),e.createElementBlock("svg",{key:1,class:e.normalizeClass(m.value),xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 8 7",fill:"none"},g[1]||(g[1]=[e.createElementVNode("path",{d:"M6.80245 3.90741L0.697913 3.8936",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)]),2)):e.createCommentVNode("",!0)],42,ht),y.label||y.description?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(d.value)},[y.label?(e.openBlock(),e.createElementBlock("label",{key:0,class:e.normalizeClass([a.value,"cstu-pt-0.5"]),onClick:i},e.toDisplayString(y.label),3)):e.createCommentVNode("",!0),y.description?(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(c.value)},e.toDisplayString(y.description),3)):e.createCommentVNode("",!0),y.error?(e.openBlock(),e.createElementBlock("div",yt,e.toDisplayString(y.error),1)):e.createCommentVNode("",!0)],2)):e.createCommentVNode("",!0)],2))}}),wt=["aria-checked","aria-disabled"],Ct=["id","checked","disabled","value"],kt=["for"],Bt=e.defineComponent({__name:"Radio",props:{modelValue:{default:void 0},value:{default:void 0},id:{default:()=>`radio-${Math.random().toString(36).substr(2,9)}`},label:{},color:{default:"primary"},size:{default:"md"},labelPosition:{default:"right"},description:{},error:{},disabled:{type:Boolean,default:!1},variant:{default:"filled"}},emits:["update:modelValue","change"],setup(o,{emit:s}){const t=o,l={primary:"blue-450",secondary:"gray-500",success:"green-500",warning:"yellow-500",danger:"red-500",info:"blue-500",dark:"gray-900",light:"gray-300"},n={primary:"blue-300",secondary:"gray-300",success:"green-300",warning:"yellow-300",danger:"red-300",info:"blue-300",dark:"gray-300",light:"gray-300"},r=s,i=e.computed(()=>t.modelValue===t.value),a=()=>{t.disabled||(r("update:modelValue",t.value),r("change",t.value))},c=e.computed(()=>[_e({disabled:t.disabled,error:t.error}),"cstu-flex cstu-items-center cstu-gap-2",t.labelPosition==="left"?"cstu-flex-row-reverse":"cstu-flex-row"]),d=e.computed(()=>["cstu-relative cstu-flex cstu-items-center cstu-justify-center cstu-rounded-full cstu-transition-colors cstu-duration-200",g.value,i.value?t.variant==="outlined"?`cstu-bg-white !cstu-border-2 cstu-border-${n[t.color]}`:`cstu-bg-${l[t.color]} cstu-border cstu-border-${l[t.color]}`:t.variant==="outlined"?`cstu-bg-white !cstu-border-2 cstu-border-${n[t.color]}`:"cstu-bg-white cstu-border cstu-border-gray-300 hover:cstu-border-gray-400",t.disabled?"cstu-opacity-50 cstu-cursor-not-allowed !cstu-bg-gray-200 !cstu-border-gray-300":"cstu-cursor-pointer"]),u=e.computed(()=>["cstu-rounded-full",b.value,t.variant==="outlined"?`cstu-bg-${l[t.color]}`:"cstu-bg-white",t.disabled?`cstu-opacity-50 ${t.variant==="outlined"?"!cstu-bg-gray-300":"!cstu-bg-gray-200"}`:""]),f=e.computed(()=>xe({size:t.size,disabled:t.disabled,error:t.error})),m=e.computed(()=>Pe({color:t.color})),h=e.computed(()=>["cstu-text-sm cstu-text-red-500 cstu-mt-1"]),y=e.computed(()=>["cstu-flex cstu-flex-col",t.disabled?"cstu-cursor-not-allowed":"cstu-cursor-pointer"]),g=e.computed(()=>({xs:"cstu-w-[8px] cstu-h-[8px]",sm:"cstu-w-[12px] cstu-h-[12px]",md:"cstu-w-[16px] cstu-h-[16px]",lg:"cstu-w-[20px] cstu-h-[20px]",xl:"cstu-w-[24px] cstu-h-[24px]"})[t.size]),b=e.computed(()=>({xs:"cstu-w-[4px] cstu-h-[4px]",sm:"cstu-w-[6px] cstu-h-[6px]",md:"cstu-w-[8px] cstu-h-[8px]",lg:"cstu-w-[10px] cstu-h-[10px]",xl:"cstu-w-[12px] cstu-h-[12px]"})[t.size]);return(x,p)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(c.value),onClick:a,"aria-checked":i.value,"aria-disabled":x.disabled,role:"radio"},[e.createElementVNode("input",{ref:"radio",type:"radio",id:x.id,checked:i.value,disabled:x.disabled,value:x.value,onChange:a,class:"cstu-sr-only cstu-border-2"},null,40,Ct),e.createElementVNode("div",{class:e.normalizeClass(d.value)},[i.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass([u.value,"cstu-absolute cstu-left-1/2 cstu-top-1/2 cstu--translate-x-1/2 cstu--translate-y-1/2 cstu-transition-transform cstu-duration-200 cstu-ease-in-out"])},null,2)):e.createCommentVNode("",!0)],2),e.createElementVNode("div",{class:e.normalizeClass(y.value)},[x.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:x.id,class:e.normalizeClass(f.value)},[e.renderSlot(x.$slots,"label",{},()=>[e.createTextVNode(e.toDisplayString(x.label),1)])],10,kt)):e.createCommentVNode("",!0),x.description?(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(m.value)},[e.renderSlot(x.$slots,"description",{},()=>[e.createTextVNode(e.toDisplayString(x.description),1)])],2)):e.createCommentVNode("",!0),x.error?(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass(h.value)},[e.renderSlot(x.$slots,"error",{},()=>[e.createTextVNode(e.toDisplayString(x.error),1)])],2)):e.createCommentVNode("",!0)],2)],10,wt))}}),zt=["for"],$t={key:0,class:"text-red-500","aria-hidden":"true"},Et={class:"relative"},Vt=["id","type","value","placeholder","disabled","required"],St=e.defineComponent({__name:"TextInput",props:{id:{},type:{default:"text"},modelValue:{},placeholder:{},disabled:{type:Boolean,default:!1},label:{},labelProps:{},description:{},descriptionProps:{},error:{},errorProps:{},wrapperProps:{},inputProps:{},size:{default:"md"},radius:{default:"md"},rightSection:{},rightSectionProps:{},leftSection:{},leftSectionProps:{},withAsterisk:{type:Boolean,default:!1},required:{type:Boolean,default:!1}},emits:["update:modelValue"],setup(o){const s=o,t=n=>({none:"rounded-none",xs:"rounded",sm:"rounded-md",md:"rounded-lg",lg:"rounded-xl",xl:"rounded-2xl",full:"rounded-full"})[n]||"rounded-lg",l=e.computed(()=>{const n=["block w-full bg-white transition-all duration-200","border border-gray-200","text-gray-900","focus:outline-none focus:ring-2 focus:ring-offset-0 focus:border-transparent","placeholder:text-gray-400","shadow-sm"],r=N(s.size,"input"),i=N(s.size,"input"),a=W({disabled:s.disabled,error:s.withError||!!s.error}),c=t(s.radius),d={left:s.leftSection?"pl-10":"",right:s.rightSection?"pr-10":""},u=s.disabled?"":[s.withError||s.error?"focus:ring-red-500/20 focus:border-red-500":"focus:ring-blue-500/20 focus:border-blue-500","hover:border-gray-300"];return[...n,r,i,a,c,d.left,d.right,u].filter(Boolean).join(" ")});return(n,r)=>(e.openBlock(),e.createElementBlock("div",e.mergeProps({class:["relative flex flex-col",{"opacity-50 pointer-events-none":n.disabled}]},n.wrapperProps),[n.label?(e.openBlock(),e.createElementBlock("label",e.mergeProps({key:0,for:n.id,class:"mb-1 text-sm font-medium text-gray-700 flex items-center gap-1"},n.labelProps),[e.createTextVNode(e.toDisplayString(n.label)+" ",1),n.required||n.withAsterisk?(e.openBlock(),e.createElementBlock("span",$t,"*")):e.createCommentVNode("",!0)],16,zt)):e.createCommentVNode("",!0),e.createElementVNode("div",Et,[n.leftSection?(e.openBlock(),e.createElementBlock("div",e.mergeProps({key:0,class:"absolute inset-y-0 left-0 flex items-center pl-3"},n.leftSectionProps),[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(n.leftSection)))],16)):e.createCommentVNode("",!0),e.createElementVNode("input",e.mergeProps({id:n.id,type:n.type,value:n.modelValue,placeholder:n.placeholder,disabled:n.disabled,required:n.required,class:l.value,onInput:r[0]||(r[0]=i=>n.$emit("update:modelValue",i.target.value))},n.inputProps),null,16,Vt),n.rightSection?(e.openBlock(),e.createElementBlock("div",e.mergeProps({key:1,class:"absolute inset-y-0 right-0 flex items-center pr-3"},n.rightSectionProps),[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(n.rightSection)))],16)):e.createCommentVNode("",!0)]),n.description?(e.openBlock(),e.createElementBlock("p",e.mergeProps({key:1,class:"mt-1 text-sm text-gray-500"},n.descriptionProps),e.toDisplayString(n.description),17)):e.createCommentVNode("",!0),n.error?(e.openBlock(),e.createElementBlock("p",e.mergeProps({key:2,class:"mt-1 text-sm text-red-500"},n.errorProps),e.toDisplayString(n.error),17)):e.createCommentVNode("",!0)],16))}}),Nt=["aria-expanded","aria-disabled"],Dt=["placeholder","disabled"],Lt={key:1,class:"w-full truncate text-gray-900"},Ot={class:"flex items-center gap-2 shrink-0"},Rt={key:0,class:"py-3 text-center text-gray-500"},At=["onClick"],_t={key:0,class:"py-3 px-4 text-gray-500 text-center text-sm"},Pt=e.defineComponent({__name:"Select",props:{modelValue:{default:null},options:{default:()=>[]},placeholder:{default:"Select option"},disabled:{type:Boolean,default:!1},searchable:{type:Boolean,default:!1},clearable:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},error:{type:Boolean,default:!1},size:{default:"md"},radius:{default:"sm"},variant:{default:"outline"},color:{default:"primary"},withCheckIcon:{type:Boolean,default:!0},checkIconPosition:{default:"right"},nothingFoundMessage:{default:"Nothing found..."}},emits:["update:modelValue","change"],setup(o,{emit:s}){const t=o,l=s,n=e.ref(!1),r=e.ref(""),i=e.ref(null),a=e.ref(null),c=p=>({none:"rounded-none",xs:"rounded",sm:"rounded-md",md:"rounded-lg",lg:"rounded-xl",xl:"rounded-2xl",full:"rounded-full"})[p]||"rounded-lg",d=e.computed(()=>{const p="w-full flex items-center justify-between transition-colors duration-200",C=[N(t.size,"input"),ae(t.size,"input")].join(" "),w=c(t.radius),k=t.error?"focus-within:ring-2 focus-within:ring-red-500/20 focus-within:border-red-500":"focus-within:ring-2 focus-within:ring-blue-500/20 focus-within:border-blue-500",$=t.variant==="filled"?`bg-gray-50 border border-transparent ${!t.disabled&&`hover:bg-gray-100 focus-within:bg-white focus-within:border-gray-300 ${k}`}`:`bg-white border border-gray-300 ${!t.disabled&&`hover:border-gray-400 ${k}`}`,z=W({disabled:t.disabled,error:t.error}),E=!t.disabled&&"cursor-pointer";return[p,C,w,$,z,E].filter(Boolean).join(" ")}),u=e.computed(()=>t.options.find(p=>p.value===t.modelValue)),f=e.computed(()=>{if(!r.value)return t.options;const p=r.value.toLowerCase();return t.options.filter(C=>C.label.toLowerCase().includes(p))}),m=()=>{var p;t.disabled||(t.searchable?((p=i.value)==null||p.focus(),n.value=!0):n.value=!n.value)},h=p=>{l("update:modelValue",p.value),l("change",p),n.value=!1,t.searchable&&(r.value=p.label)},y=()=>{l("update:modelValue",null),l("change",null),r.value=""},g=()=>{n.value||(n.value=!0)},b=()=>{n.value||(n.value=!0)},x=p=>{const C=p.target;a.value&&!a.value.contains(C)&&(n.value=!1)};return e.watch(()=>t.modelValue,p=>{p?u.value&&t.searchable&&(r.value=u.value.label):r.value=""}),e.onMounted(()=>{document.addEventListener("click",x)}),e.onUnmounted(()=>{document.removeEventListener("click",x)}),(p,C)=>(e.openBlock(),e.createElementBlock("div",{class:"relative select",ref_key:"selectRoot",ref:a},[e.createElementVNode("div",{class:e.normalizeClass(d.value),role:"combobox","aria-expanded":n.value,"aria-disabled":p.disabled,onClick:m},[p.searchable?e.withDirectives((e.openBlock(),e.createElementBlock("input",{key:0,ref_key:"searchInput",ref:i,"onUpdate:modelValue":C[0]||(C[0]=w=>r.value=w),placeholder:p.placeholder,type:"text",class:"w-full bg-transparent outline-none placeholder:text-gray-500",disabled:p.disabled,onFocus:g,onInput:b},null,40,Dt)),[[e.vModelText,r.value]]):(e.openBlock(),e.createElementBlock("div",Lt,e.toDisplayString(u.value?u.value.label:p.placeholder),1)),e.createElementVNode("div",Ot,[p.clearable&&p.modelValue&&!p.disabled?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"p-1 hover:bg-gray-100 rounded-full text-gray-500 hover:text-gray-700",onClick:e.withModifiers(y,["stop"])},C[1]||(C[1]=[e.createElementVNode("svg",{class:"w-4 h-4",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M6 18L18 6M6 6l12 12"})],-1)]))):e.createCommentVNode("",!0),(e.openBlock(),e.createElementBlock("svg",{class:e.normalizeClass(["w-4 h-4 text-gray-500 transition-transform duration-200",{"rotate-180":n.value}]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},C[2]||(C[2]=[e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M19 9l-7 7-7-7"},null,-1)]),2))])],10,Nt),e.withDirectives(e.createElementVNode("div",{class:e.normalizeClass(["absolute w-full z-50 mt-1 bg-white","border border-gray-200",c(t.radius),"shadow-lg max-h-[240px] overflow-auto","divide-y divide-gray-100"])},[p.loading?(e.openBlock(),e.createElementBlock("div",Rt,[e.renderSlot(p.$slots,"loader",{},()=>[C[3]||(C[3]=e.createElementVNode("svg",{class:"animate-spin h-5 w-5 mx-auto",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24"},[e.createElementVNode("circle",{class:"opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor","stroke-width":"4"}),e.createElementVNode("path",{class:"opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"})],-1))])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value,w=>(e.openBlock(),e.createElementBlock("div",{key:w.value,class:e.normalizeClass(["py-2.5 px-4 flex items-center transition-colors duration-200","text-[14px] leading-5","text-gray-900",w.value===p.modelValue?"bg-gray-50 font-medium":"hover:bg-gray-50",w.disabled?"opacity-50 cursor-not-allowed":"cursor-pointer"]),onClick:k=>!w.disabled&&h(w)},[p.withCheckIcon&&w.value===p.modelValue?(e.openBlock(),e.createElementBlock("svg",{key:0,class:e.normalizeClass(["w-4 h-4 text-blue-600 shrink-0",p.checkIconPosition==="left"?"mr-2":"ml-2 order-last"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},C[4]||(C[4]=[e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M5 13l4 4L19 7"},null,-1)]),2)):e.createCommentVNode("",!0),e.createElementVNode("span",{class:e.normalizeClass({"text-gray-500":w.disabled})},e.toDisplayString(w.label),3)],10,At))),128)),f.value.length===0?(e.openBlock(),e.createElementBlock("div",_t,e.toDisplayString(p.nothingFoundMessage||"No options found"),1)):e.createCommentVNode("",!0)],64))],2),[[e.vShow,n.value]])],512))}}),Tt=["disabled"],Mt={key:0,class:"w-3.5 h-3.5",viewBox:"0 0 20 20",fill:"currentColor"},vt={key:1,class:"animate-spin"},It=e.defineComponent({__name:"Chip",props:{modelValue:{type:Boolean,default:!1},label:{default:""},size:{default:"md"},variant:{default:"filled"},color:{default:"primary"},radius:{default:"xl"},checked:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},withRemoveButton:{type:Boolean,default:!1},withCheckIcon:{type:Boolean,default:!0},checkIconPosition:{default:"left"},allowDeselect:{type:Boolean,default:!0},loading:{type:Boolean,default:!1}},emits:["update:modelValue"],setup(o,{emit:s}){const t=o,l=s,n=e.computed(()=>F(t.color)),r=e.computed(()=>N(t.size,"chip")),i=e.computed(()=>W({disabled:t.disabled,loading:t.loading})),a=e.computed(()=>F(t.color,"filled")),c=e.computed(()=>F(t.color,"outline")),d=()=>{t.disabled||t.loading||t.modelValue&&!t.allowDeselect||l("update:modelValue",!t.modelValue)};return(u,f)=>(e.openBlock(),e.createElementBlock("button",{class:e.normalizeClass(["inline-flex items-center justify-center gap-2 rounded-full transition-colors duration-200 select-none","focus:outline-none",n.value,r.value,i.value,u.modelValue?a.value:c.value,"cursor-pointer"]),disabled:u.disabled||u.loading,onClick:d},[u.withCheckIcon&&u.modelValue?(e.openBlock(),e.createElementBlock("svg",Mt,f[0]||(f[0]=[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z","clip-rule":"evenodd"},null,-1)]))):e.createCommentVNode("",!0),u.loading?(e.openBlock(),e.createElementBlock("span",vt,f[1]||(f[1]=[e.createElementVNode("svg",{class:"w-3.5 h-3.5",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24"},[e.createElementVNode("circle",{class:"opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor","stroke-width":"4"}),e.createElementVNode("path",{class:"opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"})],-1)]))):e.createCommentVNode("",!0),e.createElementVNode("span",{class:e.normalizeClass(["whitespace-nowrap",u.loading?"opacity-75":""])},e.toDisplayString(u.label),3)],10,Tt))}}),jt=(o,s=0)=>{const t={position:"absolute",transform:"translate(50%, -50%)"},[l,n]=o.split("-");if(l==="top"?t.top="0":l==="bottom"?(t.bottom="0",t.transform="translate(50%, 50%)"):l==="middle"&&(t.top="50%",n==="start"?t.transform="translate(-50%, -50%)":n==="end"?t.transform="translate(50%, -50%)":t.transform="translate(0, -50%)"),n==="start"?(t.left="0",t.transform=l==="bottom"?"translate(-50%, 50%)":"translate(-50%, -50%)"):n==="end"?t.right="0":n==="center"&&(t.left="50%",t.transform=l==="bottom"?"translate(-50%, 50%)":"translate(-50%, -50%)"),s){const r=t.transform.includes("50%")?"50%":"0",i=t.transform.includes("-50%")?"-50%":"50%";(l==="top"||l==="bottom")&&(t.transform=`translate(${r}, ${i}) translateY(${s}px)`),(n==="start"||n==="end")&&(t.transform=`translate(${r}, ${i}) translateX(${n==="start"?-s:s}px)`)}return t},Ft={name:"Indicator"},Wt=e.defineComponent({...Ft,props:{position:{default:"top-end"},size:{default:"md"},radius:{default:"xl"},color:{default:"primary"},variant:{default:"filled"},offset:{default:0},inline:{type:Boolean,default:!1},label:{default:""},withBorder:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},processing:{type:Boolean,default:!1},zIndex:{default:200}},setup(o){const s=o,t=e.computed(()=>[s.inline?"inline-block":"block","relative"]),l=e.computed(()=>({...s.inline&&{display:"inline-block"}})),n=e.computed(()=>["flex items-center justify-center","absolute","select-none","rounded-full",ae(s.size,"indicator"),N(s.size,"indicator"),!s.disabled&&`bg-${s.color==="primary"?"blue":s.color}-600 text-white`,s.disabled&&"bg-gray-200 text-gray-500",s.withBorder&&"border-2 border-white dark:border-gray-900",s.processing&&"animate-pulse"]),r=e.computed(()=>({...jt(s.position,s.offset),zIndex:s.zIndex}));return(i,a)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(t.value),style:e.normalizeStyle(l.value)},[i.disabled?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(n.value),style:e.normalizeStyle(r.value)},e.toDisplayString(i.label),7)),e.renderSlot(i.$slots,"default",{},void 0,!0)],6))}}),ao="",Ht=((o,s)=>{const t=o.__vccOpts||o;for(const[l,n]of s)t[l]=n;return t})(Wt,[["__scopeId","data-v-643e9acf"]]),qt=["aria-valuenow"],Yt=e.defineComponent({__name:"Progress",props:{value:{default:0},size:{default:"md"},color:{},label:{},striped:{type:Boolean,default:!1},animated:{type:Boolean,default:!1}},setup(o){return(s,t)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["relative w-full rounded-sm overflow-hidden","bg-gray-100",e.unref(ae)(s.size,"progress")]),role:"progressbar","aria-valuenow":s.value,"aria-valuemin":"0","aria-valuemax":"100"},[e.createElementVNode("div",{class:e.normalizeClass(["h-full transition-all duration-300 ease-in-out",e.unref(F)(s.color||"primary","filled"),{"bg-striped":s.striped&&!s.animated,"bg-striped animate-progress":s.animated}]),style:e.normalizeStyle({width:`${s.value}%`})},[s.label&&(s.size==="lg"||s.size==="xl")?(e.openBlock(),e.createElementBlock("span",{key:0,class:e.normalizeClass(["block px-2 py-1 text-white whitespace-nowrap font-medium leading-none",e.unref(ye)(s.size)])},e.toDisplayString(s.label),3)):e.createCommentVNode("",!0)],6)],10,qt))}}),co="",Kt={key:0,class:"flex-shrink-0"},Ut={key:0,class:"flex items-center justify-between"},Xt={key:1,class:"flex-shrink-0 ml-3"},Gt=["disabled"],Zt=e.defineComponent({__name:"Alert",props:{title:{},message:{},icon:{},variant:{default:"default"},color:{default:"primary"},size:{default:"md"},closable:{type:Boolean,default:!1},onClose:{},disabled:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},valid:{type:Boolean,default:void 0},invalid:{type:Boolean,default:void 0}},emits:["close"],setup(o,{emit:s}){const t=o,l=s,n=e.computed(()=>F(t.color,t.variant,{hover:!1,active:!1,focus:!1,disabled:t.disabled})),r=e.computed(()=>it(t.variant)),i=e.computed(()=>rt(t.color,t.variant)),a=e.computed(()=>at(t.color,t.variant)),c=e.computed(()=>N(t.size,"alert")),d=e.computed(()=>ct(t.size,"alert")),u=e.computed(()=>ye(t.size)),f=e.computed(()=>Ae(t.size)),m=e.computed(()=>W({disabled:t.disabled,loading:t.loading})),h=e.computed(()=>ut({valid:t.valid,invalid:t.invalid})),y=e.computed(()=>pt({hover:!0,focus:!0},t.color)),g=()=>{l("close")};return(b,x)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["relative rounded-md",r.value,n.value,c.value,m.value,h.value]),role:"alert"},[e.createElementVNode("div",{class:e.normalizeClass(["flex items-start",[f.value]])},[b.icon?(e.openBlock(),e.createElementBlock("div",Kt,[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(b.icon),{class:e.normalizeClass([d.value,i.value])},null,8,["class"]))])):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass(["flex-grow",[b.icon&&"ml-3"]])},[b.title?(e.openBlock(),e.createElementBlock("div",Ut,[e.createElementVNode("h3",{class:e.normalizeClass(["font-medium",a.value])},e.toDisplayString(b.title),3)])):e.createCommentVNode("",!0),b.message?(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["mt-1",b.variant==="filled"?"text-white/90":"text-gray-600",u.value])},e.toDisplayString(b.message),3)):e.createCommentVNode("",!0),e.renderSlot(b.$slots,"default")],2),b.closable?(e.openBlock(),e.createElementBlock("div",Xt,[e.createElementVNode("button",{type:"button",class:e.normalizeClass(["inline-flex rounded-md focus:outline-none focus:ring-2 focus:ring-offset-2",[b.variant==="filled"?"text-white/80 hover:text-white focus:ring-white":"text-gray-400 hover:text-gray-500 focus:ring-blue-500",y.value]]),disabled:b.disabled,onClick:g},x[0]||(x[0]=[e.createElementVNode("span",{class:"sr-only"},"Close",-1),e.createElementVNode("svg",{class:"h-5 w-5",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},[e.createElementVNode("path",{d:"M6.28 5.22a.75.75 0 00-1.06 1.06L8.94 10l-3.72 3.72a.75.75 0 101.06 1.06L10 11.06l3.72 3.72a.75.75 0 101.06-1.06L11.06 10l3.72-3.72a.75.75 0 00-1.06-1.06L10 8.94 6.28 5.22z"})],-1)]),10,Gt)])):e.createCommentVNode("",!0)],2)],2))}}),Qt=e.defineComponent({__name:"Collapse",props:{open:{type:Boolean,default:!1},duration:{default:200},class:{},size:{default:"md"},disableTransition:{type:Boolean,default:!1}},setup(o){const s=o,t=e.ref(null),l=e.ref(null),n={xs:"p-1",sm:"p-2",md:"p-3",lg:"p-4",xl:"p-5"},r=e.computed(()=>Ae(s.size)),i=e.computed(()=>n[s.size]),a=e.computed(()=>s.disableTransition?"":`transition-[height] ease-in-out duration-${s.duration}`),c=e.computed(()=>({enter:s.duration,leave:s.duration})),d=g=>{g.style.height="0",g.style.overflow="hidden"},u=g=>{const b=g.scrollHeight;g.style.height="0",g.offsetHeight,g.style.height=`${b}px`},f=g=>{g.style.height="",g.style.overflow=""},m=g=>{g.style.height=`${g.scrollHeight}px`,g.style.overflow="hidden",g.offsetHeight},h=g=>{g.style.height="0"},y=g=>{g.style.height="",g.style.overflow=""};return(g,b)=>(e.openBlock(),e.createBlock(e.Transition,{duration:c.value,onBeforeEnter:d,onEnter:u,onAfterEnter:f,onBeforeLeave:m,onLeave:h,onAfterLeave:y},{default:e.withCtx(()=>[e.withDirectives(e.createElementVNode("div",{class:e.normalizeClass(["overflow-hidden",r.value,a.value,s.class]),ref_key:"contentRef",ref:t},[e.createElementVNode("div",{ref_key:"innerRef",ref:l,class:e.normalizeClass(i.value)},[e.renderSlot(g.$slots,"default")],2)],2),[[e.vShow,g.open]])]),_:3},8,["duration"]))}}),Jt={class:"inline-block"},es=e.defineComponent({__name:"OvalLoader",props:{size:{default:"md"}},setup(o){const s={xs:"12px",sm:"16px",md:"24px",lg:"36px",xl:"48px"},t=o,l=e.computed(()=>{const n=parseInt(s[t.size]);return`${Math.max(2,n/12)}px`});return(n,r)=>(e.openBlock(),e.createElementBlock("span",Jt,[e.createElementVNode("span",{class:"inline-block rounded-full border-solid border-r-transparent border-current animate-[oval-spin_1.2s_linear_infinite]",style:e.normalizeStyle({width:s[t.size],height:s[t.size],borderWidth:l.value})},null,4)]))}}),uo="",ts=e.defineComponent({__name:"DotsLoader",props:{size:{default:"md"}},setup(o){const s={xs:"12px",sm:"16px",md:"24px",lg:"36px",xl:"48px"},t=o,l=e.computed(()=>`${parseInt(s[t.size])/3}px`),n=e.computed(()=>`${parseInt(s[t.size])/6}px`);return(r,i)=>(e.openBlock(),e.createElementBlock("span",{class:"inline-flex items-center",style:e.normalizeStyle({gap:n.value,height:s[t.size]})},[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(3,a=>e.createElementVNode("span",{key:a,class:"inline-block rounded-full animate-[dots-pulse_0.8s_infinite_linear] bg-current",style:e.normalizeStyle({width:l.value,height:l.value,animationDelay:`${(a-1)*.16}s`,opacity:1})},null,4)),64))],4))}}),po="",ss=e.defineComponent({__name:"BarsLoader",props:{size:{default:"md"}},setup(o){const s={xs:"12px",sm:"16px",md:"24px",lg:"36px",xl:"48px"},t=o,l=e.computed(()=>`${parseInt(s[t.size])/6}px`);return(n,r)=>(e.openBlock(),e.createElementBlock("span",{class:"inline-flex",style:e.normalizeStyle({gap:l.value,width:s[t.size],height:`${parseInt(s[t.size])/2}px`})},[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(3,i=>e.createElementVNode("span",{key:i,class:"flex-1 rounded-[2px] animate-[bars-scale_1.2s_cubic-bezier(0,0.5,0.5,1)_infinite] bg-current",style:e.normalizeStyle({animationDelay:`${(i-1)*-.12}s`,opacity:1})},null,4)),64))],4))}}),fo="",os=e.defineComponent({__name:"Loader",props:{variant:{default:"oval"},color:{default:"primary"},size:{default:"md"},class:{}},setup(o){const s=o,t=i=>/^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$/.test(i),l=e.computed(()=>!s.color||t(s.color)?"":{primary:"text-blue-500",secondary:"text-gray-500",success:"text-green-500",warning:"text-yellow-500",danger:"text-red-500",info:"text-blue-500",dark:"text-gray-900",light:"text-white"}[s.color]||""),n=e.computed(()=>!s.color||!t(s.color)?{}:{color:s.color}),r=e.computed(()=>{switch(s.variant){case"dots":return ts;case"bars":return ss;default:return es}});return(i,a)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(r.value),{class:e.normalizeClass(["inline-block",l.value,s.class]),style:e.normalizeStyle(n.value),size:s.size},null,8,["class","style","size"]))}}),ns={class:"p-4"},ls={key:0,class:"absolute top-2 right-2"},rs={key:1,class:"text-lg font-medium mb-2"},as={key:2},is=e.defineComponent({__name:"Dialog",props:{title:{},content:{},opened:{type:Boolean},size:{default:"md"},withCloseButton:{type:Boolean,default:!0},onClose:{},position:{default:()=>({bottom:"20px",right:"20px"})},keepMounted:{type:Boolean,default:!1},zIndex:{default:1e3}},setup(o){const s=o,t=e.computed(()=>({xs:"w-[280px]",sm:"w-[320px]",md:"w-[380px]",lg:"w-[440px]",xl:"w-[520px]"})[s.size]);return(l,n)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{"enter-active-class":"transition duration-200 ease-out","enter-from-class":"opacity-0 scale-95","enter-to-class":"opacity-100 scale-100","leave-active-class":"transition duration-200 ease-in","leave-from-class":"opacity-100 scale-100","leave-to-class":"opacity-0 scale-95"},{default:e.withCtx(()=>[l.opened||l.keepMounted?(e.openBlock(),e.createElementBlock("div",{key:0,style:e.normalizeStyle({position:"fixed",zIndex:l.zIndex||1e3,...l.position,display:l.opened?"block":"none"}),class:"min-w-[200px]"},[e.createElementVNode("div",{class:e.normalizeClass(["rounded-lg bg-white dark:bg-gray-800 shadow-lg border border-gray-200 dark:border-gray-700",[t.value]])},[e.createElementVNode("div",ns,[l.withCloseButton?(e.openBlock(),e.createElementBlock("div",ls,[e.createElementVNode("button",{onClick:n[0]||(n[0]=(...r)=>l.onClose&&l.onClose(...r)),class:"text-gray-400 hover:text-gray-500 dark:text-gray-500 dark:hover:text-gray-400 focus:outline-none"},n[1]||(n[1]=[e.createElementVNode("span",{class:"sr-only"},"Close",-1),e.createElementVNode("svg",{class:"h-5 w-5",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor"},[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z","clip-rule":"evenodd"})],-1)]))])):e.createCommentVNode("",!0),l.title?(e.openBlock(),e.createElementBlock("div",rs,e.toDisplayString(l.title),1)):e.createCommentVNode("",!0),l.content?(e.openBlock(),e.createElementBlock("div",as,e.toDisplayString(l.content),1)):e.createCommentVNode("",!0),e.renderSlot(l.$slots,"default")])],2)],4)):e.createCommentVNode("",!0)]),_:3})]))}}),X=Math.min,H=Math.max,ie=Math.round,ce=Math.floor,O=o=>({x:o,y:o}),cs={left:"right",right:"left",bottom:"top",top:"bottom"},ds={start:"end",end:"start"};function be(o,s,t){return H(o,X(s,t))}function te(o,s){return typeof o=="function"?o(s):o}function q(o){return o.split("-")[0]}function se(o){return o.split("-")[1]}function Te(o){return o==="x"?"y":"x"}function we(o){return o==="y"?"height":"width"}function G(o){return["top","bottom"].includes(q(o))?"y":"x"}function Ce(o){return Te(G(o))}function us(o,s,t){t===void 0&&(t=!1);const l=se(o),n=Ce(o),r=we(n);let i=n==="x"?l===(t?"end":"start")?"right":"left":l==="start"?"bottom":"top";return s.reference[r]>s.floating[r]&&(i=de(i)),[i,de(i)]}function ps(o){const s=de(o);return[ke(o),s,ke(s)]}function ke(o){return o.replace(/start|end/g,s=>ds[s])}function fs(o,s,t){const l=["left","right"],n=["right","left"],r=["top","bottom"],i=["bottom","top"];switch(o){case"top":case"bottom":return t?s?n:l:s?l:n;case"left":case"right":return s?r:i;default:return[]}}function ms(o,s,t,l){const n=se(o);let r=fs(q(o),t==="start",l);return n&&(r=r.map(i=>i+"-"+n),s&&(r=r.concat(r.map(ke)))),r}function de(o){return o.replace(/left|right|bottom|top/g,s=>cs[s])}function gs(o){return{top:0,right:0,bottom:0,left:0,...o}}function Me(o){return typeof o!="number"?gs(o):{top:o,right:o,bottom:o,left:o}}function ue(o){const{x:s,y:t,width:l,height:n}=o;return{width:l,height:n,top:t,left:s,right:s+l,bottom:t+n,x:s,y:t}}function ve(o,s,t){let{reference:l,floating:n}=o;const r=G(s),i=Ce(s),a=we(i),c=q(s),d=r==="y",u=l.x+l.width/2-n.width/2,f=l.y+l.height/2-n.height/2,m=l[a]/2-n[a]/2;let h;switch(c){case"top":h={x:u,y:l.y-n.height};break;case"bottom":h={x:u,y:l.y+l.height};break;case"right":h={x:l.x+l.width,y:f};break;case"left":h={x:l.x-n.width,y:f};break;default:h={x:l.x,y:l.y}}switch(se(s)){case"start":h[i]-=m*(t&&d?-1:1);break;case"end":h[i]+=m*(t&&d?-1:1);break}return h}const hs=async(o,s,t)=>{const{placement:l="bottom",strategy:n="absolute",middleware:r=[],platform:i}=t,a=r.filter(Boolean),c=await(i.isRTL==null?void 0:i.isRTL(s));let d=await i.getElementRects({reference:o,floating:s,strategy:n}),{x:u,y:f}=ve(d,l,c),m=l,h={},y=0;for(let g=0;g<a.length;g++){const{name:b,fn:x}=a[g],{x:p,y:C,data:w,reset:k}=await x({x:u,y:f,initialPlacement:l,placement:m,strategy:n,middlewareData:h,rects:d,platform:i,elements:{reference:o,floating:s}});u=p??u,f=C??f,h={...h,[b]:{...h[b],...w}},k&&y<=50&&(y++,typeof k=="object"&&(k.placement&&(m=k.placement),k.rects&&(d=k.rects===!0?await i.getElementRects({reference:o,floating:s,strategy:n}):k.rects),{x:u,y:f}=ve(d,m,c)),g=-1)}return{x:u,y:f,placement:m,strategy:n,middlewareData:h}};async function Ie(o,s){var t;s===void 0&&(s={});const{x:l,y:n,platform:r,rects:i,elements:a,strategy:c}=o,{boundary:d="clippingAncestors",rootBoundary:u="viewport",elementContext:f="floating",altBoundary:m=!1,padding:h=0}=te(s,o),y=Me(h),b=a[m?f==="floating"?"reference":"floating":f],x=ue(await r.getClippingRect({element:(t=await(r.isElement==null?void 0:r.isElement(b)))==null||t?b:b.contextElement||await(r.getDocumentElement==null?void 0:r.getDocumentElement(a.floating)),boundary:d,rootBoundary:u,strategy:c})),p=f==="floating"?{x:l,y:n,width:i.floating.width,height:i.floating.height}:i.reference,C=await(r.getOffsetParent==null?void 0:r.getOffsetParent(a.floating)),w=await(r.isElement==null?void 0:r.isElement(C))?await(r.getScale==null?void 0:r.getScale(C))||{x:1,y:1}:{x:1,y:1},k=ue(r.convertOffsetParentRelativeRectToViewportRelativeRect?await r.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:p,offsetParent:C,strategy:c}):p);return{top:(x.top-k.top+y.top)/w.y,bottom:(k.bottom-x.bottom+y.bottom)/w.y,left:(x.left-k.left+y.left)/w.x,right:(k.right-x.right+y.right)/w.x}}const ys=o=>({name:"arrow",options:o,async fn(s){const{x:t,y:l,placement:n,rects:r,platform:i,elements:a,middlewareData:c}=s,{element:d,padding:u=0}=te(o,s)||{};if(d==null)return{};const f=Me(u),m={x:t,y:l},h=Ce(n),y=we(h),g=await i.getDimensions(d),b=h==="y",x=b?"top":"left",p=b?"bottom":"right",C=b?"clientHeight":"clientWidth",w=r.reference[y]+r.reference[h]-m[h]-r.floating[y],k=m[h]-r.reference[h],$=await(i.getOffsetParent==null?void 0:i.getOffsetParent(d));let z=$?$[C]:0;(!z||!await(i.isElement==null?void 0:i.isElement($)))&&(z=a.floating[C]||r.floating[y]);const E=w/2-k/2,_=z/2-g[y]/2-1,v=X(f[x],_),le=X(f[p],_),U=v,re=z-g[y]-le,V=z/2-g[y]/2+E,ee=be(U,V,re),T=!c.arrow&&se(n)!=null&&V!==ee&&r.reference[y]/2-(V<U?v:le)-g[y]/2<0,P=T?V<U?V-U:V-re:0;return{[h]:m[h]+P,data:{[h]:ee,centerOffset:V-ee-P,...T&&{alignmentOffset:P}},reset:T}}}),xs=function(o){return o===void 0&&(o={}),{name:"flip",options:o,async fn(s){var t,l;const{placement:n,middlewareData:r,rects:i,initialPlacement:a,platform:c,elements:d}=s,{mainAxis:u=!0,crossAxis:f=!0,fallbackPlacements:m,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:y="none",flipAlignment:g=!0,...b}=te(o,s);if((t=r.arrow)!=null&&t.alignmentOffset)return{};const x=q(n),p=G(a),C=q(a)===a,w=await(c.isRTL==null?void 0:c.isRTL(d.floating)),k=m||(C||!g?[de(a)]:ps(a)),$=y!=="none";!m&&$&&k.push(...ms(a,g,y,w));const z=[a,...k],E=await Ie(s,b),_=[];let v=((l=r.flip)==null?void 0:l.overflows)||[];if(u&&_.push(E[x]),f){const V=us(n,i,w);_.push(E[V[0]],E[V[1]])}if(v=[...v,{placement:n,overflows:_}],!_.every(V=>V<=0)){var le,U;const V=(((le=r.flip)==null?void 0:le.index)||0)+1,ee=z[V];if(ee)return{data:{index:V,overflows:v},reset:{placement:ee}};let T=(U=v.filter(P=>P.overflows[0]<=0).sort((P,I)=>P.overflows[1]-I.overflows[1])[0])==null?void 0:U.placement;if(!T)switch(h){case"bestFit":{var re;const P=(re=v.filter(I=>{if($){const j=G(I.placement);return j===p||j==="y"}return!0}).map(I=>[I.placement,I.overflows.filter(j=>j>0).reduce((j,ro)=>j+ro,0)]).sort((I,j)=>I[1]-j[1])[0])==null?void 0:re[0];P&&(T=P);break}case"initialPlacement":T=a;break}if(n!==T)return{reset:{placement:T}}}return{}}}};async function bs(o,s){const{placement:t,platform:l,elements:n}=o,r=await(l.isRTL==null?void 0:l.isRTL(n.floating)),i=q(t),a=se(t),c=G(t)==="y",d=["left","top"].includes(i)?-1:1,u=r&&c?-1:1,f=te(s,o);let{mainAxis:m,crossAxis:h,alignmentAxis:y}=typeof f=="number"?{mainAxis:f,crossAxis:0,alignmentAxis:null}:{mainAxis:f.mainAxis||0,crossAxis:f.crossAxis||0,alignmentAxis:f.alignmentAxis};return a&&typeof y=="number"&&(h=a==="end"?y*-1:y),c?{x:h*u,y:m*d}:{x:m*d,y:h*u}}const ws=function(o){return o===void 0&&(o=0),{name:"offset",options:o,async fn(s){var t,l;const{x:n,y:r,placement:i,middlewareData:a}=s,c=await bs(s,o);return i===((t=a.offset)==null?void 0:t.placement)&&(l=a.arrow)!=null&&l.alignmentOffset?{}:{x:n+c.x,y:r+c.y,data:{...c,placement:i}}}}},Cs=function(o){return o===void 0&&(o={}),{name:"shift",options:o,async fn(s){const{x:t,y:l,placement:n}=s,{mainAxis:r=!0,crossAxis:i=!1,limiter:a={fn:b=>{let{x,y:p}=b;return{x,y:p}}},...c}=te(o,s),d={x:t,y:l},u=await Ie(s,c),f=G(q(n)),m=Te(f);let h=d[m],y=d[f];if(r){const b=m==="y"?"top":"left",x=m==="y"?"bottom":"right",p=h+u[b],C=h-u[x];h=be(p,h,C)}if(i){const b=f==="y"?"top":"left",x=f==="y"?"bottom":"right",p=y+u[b],C=y-u[x];y=be(p,y,C)}const g=a.fn({...s,[m]:h,[f]:y});return{...g,data:{x:g.x-t,y:g.y-l,enabled:{[m]:r,[f]:i}}}}}};function pe(){return typeof window<"u"}function Y(o){return Be(o)?(o.nodeName||"").toLowerCase():"#document"}function S(o){var s;return(o==null||(s=o.ownerDocument)==null?void 0:s.defaultView)||window}function R(o){var s;return(s=(Be(o)?o.ownerDocument:o.document)||window.document)==null?void 0:s.documentElement}function Be(o){return pe()?o instanceof Node||o instanceof S(o).Node:!1}function D(o){return pe()?o instanceof Element||o instanceof S(o).Element:!1}function A(o){return pe()?o instanceof HTMLElement||o instanceof S(o).HTMLElement:!1}function je(o){return!pe()||typeof ShadowRoot>"u"?!1:o instanceof ShadowRoot||o instanceof S(o).ShadowRoot}function oe(o){const{overflow:s,overflowX:t,overflowY:l,display:n}=L(o);return/auto|scroll|overlay|hidden|clip/.test(s+l+t)&&!["inline","contents"].includes(n)}function ks(o){return["table","td","th"].includes(Y(o))}function fe(o){return[":popover-open",":modal"].some(s=>{try{return o.matches(s)}catch{return!1}})}function ze(o){const s=$e(),t=D(o)?L(o):o;return t.transform!=="none"||t.perspective!=="none"||(t.containerType?t.containerType!=="normal":!1)||!s&&(t.backdropFilter?t.backdropFilter!=="none":!1)||!s&&(t.filter?t.filter!=="none":!1)||["transform","perspective","filter"].some(l=>(t.willChange||"").includes(l))||["paint","layout","strict","content"].some(l=>(t.contain||"").includes(l))}function Bs(o){let s=M(o);for(;A(s)&&!Z(s);){if(ze(s))return s;if(fe(s))return null;s=M(s)}return null}function $e(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function Z(o){return["html","body","#document"].includes(Y(o))}function L(o){return S(o).getComputedStyle(o)}function me(o){return D(o)?{scrollLeft:o.scrollLeft,scrollTop:o.scrollTop}:{scrollLeft:o.scrollX,scrollTop:o.scrollY}}function M(o){if(Y(o)==="html")return o;const s=o.assignedSlot||o.parentNode||je(o)&&o.host||R(o);return je(s)?s.host:s}function Fe(o){const s=M(o);return Z(s)?o.ownerDocument?o.ownerDocument.body:o.body:A(s)&&oe(s)?s:Fe(s)}function ne(o,s,t){var l;s===void 0&&(s=[]),t===void 0&&(t=!0);const n=Fe(o),r=n===((l=o.ownerDocument)==null?void 0:l.body),i=S(n);if(r){const a=Ee(i);return s.concat(i,i.visualViewport||[],oe(n)?n:[],a&&t?ne(a):[])}return s.concat(n,ne(n,[],t))}function Ee(o){return o.parent&&Object.getPrototypeOf(o.parent)?o.frameElement:null}function We(o){const s=L(o);let t=parseFloat(s.width)||0,l=parseFloat(s.height)||0;const n=A(o),r=n?o.offsetWidth:t,i=n?o.offsetHeight:l,a=ie(t)!==r||ie(l)!==i;return a&&(t=r,l=i),{width:t,height:l,$:a}}function Ve(o){return D(o)?o:o.contextElement}function Q(o){const s=Ve(o);if(!A(s))return O(1);const t=s.getBoundingClientRect(),{width:l,height:n,$:r}=We(s);let i=(r?ie(t.width):t.width)/l,a=(r?ie(t.height):t.height)/n;return(!i||!Number.isFinite(i))&&(i=1),(!a||!Number.isFinite(a))&&(a=1),{x:i,y:a}}const zs=O(0);function He(o){const s=S(o);return!$e()||!s.visualViewport?zs:{x:s.visualViewport.offsetLeft,y:s.visualViewport.offsetTop}}function $s(o,s,t){return s===void 0&&(s=!1),!t||s&&t!==S(o)?!1:s}function K(o,s,t,l){s===void 0&&(s=!1),t===void 0&&(t=!1);const n=o.getBoundingClientRect(),r=Ve(o);let i=O(1);s&&(l?D(l)&&(i=Q(l)):i=Q(o));const a=$s(r,t,l)?He(r):O(0);let c=(n.left+a.x)/i.x,d=(n.top+a.y)/i.y,u=n.width/i.x,f=n.height/i.y;if(r){const m=S(r),h=l&&D(l)?S(l):l;let y=m,g=Ee(y);for(;g&&l&&h!==y;){const b=Q(g),x=g.getBoundingClientRect(),p=L(g),C=x.left+(g.clientLeft+parseFloat(p.paddingLeft))*b.x,w=x.top+(g.clientTop+parseFloat(p.paddingTop))*b.y;c*=b.x,d*=b.y,u*=b.x,f*=b.y,c+=C,d+=w,y=S(g),g=Ee(y)}}return ue({width:u,height:f,x:c,y:d})}function Se(o,s){const t=me(o).scrollLeft;return s?s.left+t:K(R(o)).left+t}function qe(o,s,t){t===void 0&&(t=!1);const l=o.getBoundingClientRect(),n=l.left+s.scrollLeft-(t?0:Se(o,l)),r=l.top+s.scrollTop;return{x:n,y:r}}function Es(o){let{elements:s,rect:t,offsetParent:l,strategy:n}=o;const r=n==="fixed",i=R(l),a=s?fe(s.floating):!1;if(l===i||a&&r)return t;let c={scrollLeft:0,scrollTop:0},d=O(1);const u=O(0),f=A(l);if((f||!f&&!r)&&((Y(l)!=="body"||oe(i))&&(c=me(l)),A(l))){const h=K(l);d=Q(l),u.x=h.x+l.clientLeft,u.y=h.y+l.clientTop}const m=i&&!f&&!r?qe(i,c,!0):O(0);return{width:t.width*d.x,height:t.height*d.y,x:t.x*d.x-c.scrollLeft*d.x+u.x+m.x,y:t.y*d.y-c.scrollTop*d.y+u.y+m.y}}function Vs(o){return Array.from(o.getClientRects())}function Ss(o){const s=R(o),t=me(o),l=o.ownerDocument.body,n=H(s.scrollWidth,s.clientWidth,l.scrollWidth,l.clientWidth),r=H(s.scrollHeight,s.clientHeight,l.scrollHeight,l.clientHeight);let i=-t.scrollLeft+Se(o);const a=-t.scrollTop;return L(l).direction==="rtl"&&(i+=H(s.clientWidth,l.clientWidth)-n),{width:n,height:r,x:i,y:a}}function Ns(o,s){const t=S(o),l=R(o),n=t.visualViewport;let r=l.clientWidth,i=l.clientHeight,a=0,c=0;if(n){r=n.width,i=n.height;const d=$e();(!d||d&&s==="fixed")&&(a=n.offsetLeft,c=n.offsetTop)}return{width:r,height:i,x:a,y:c}}function Ds(o,s){const t=K(o,!0,s==="fixed"),l=t.top+o.clientTop,n=t.left+o.clientLeft,r=A(o)?Q(o):O(1),i=o.clientWidth*r.x,a=o.clientHeight*r.y,c=n*r.x,d=l*r.y;return{width:i,height:a,x:c,y:d}}function Ye(o,s,t){let l;if(s==="viewport")l=Ns(o,t);else if(s==="document")l=Ss(R(o));else if(D(s))l=Ds(s,t);else{const n=He(o);l={x:s.x-n.x,y:s.y-n.y,width:s.width,height:s.height}}return ue(l)}function Ke(o,s){const t=M(o);return t===s||!D(t)||Z(t)?!1:L(t).position==="fixed"||Ke(t,s)}function Ls(o,s){const t=s.get(o);if(t)return t;let l=ne(o,[],!1).filter(a=>D(a)&&Y(a)!=="body"),n=null;const r=L(o).position==="fixed";let i=r?M(o):o;for(;D(i)&&!Z(i);){const a=L(i),c=ze(i);!c&&a.position==="fixed"&&(n=null),(r?!c&&!n:!c&&a.position==="static"&&!!n&&["absolute","fixed"].includes(n.position)||oe(i)&&!c&&Ke(o,i))?l=l.filter(u=>u!==i):n=a,i=M(i)}return s.set(o,l),l}function Os(o){let{element:s,boundary:t,rootBoundary:l,strategy:n}=o;const i=[...t==="clippingAncestors"?fe(s)?[]:Ls(s,this._c):[].concat(t),l],a=i[0],c=i.reduce((d,u)=>{const f=Ye(s,u,n);return d.top=H(f.top,d.top),d.right=X(f.right,d.right),d.bottom=X(f.bottom,d.bottom),d.left=H(f.left,d.left),d},Ye(s,a,n));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function Rs(o){const{width:s,height:t}=We(o);return{width:s,height:t}}function As(o,s,t){const l=A(s),n=R(s),r=t==="fixed",i=K(o,!0,r,s);let a={scrollLeft:0,scrollTop:0};const c=O(0);if(l||!l&&!r)if((Y(s)!=="body"||oe(n))&&(a=me(s)),l){const m=K(s,!0,r,s);c.x=m.x+s.clientLeft,c.y=m.y+s.clientTop}else n&&(c.x=Se(n));const d=n&&!l&&!r?qe(n,a):O(0),u=i.left+a.scrollLeft-c.x-d.x,f=i.top+a.scrollTop-c.y-d.y;return{x:u,y:f,width:i.width,height:i.height}}function Ne(o){return L(o).position==="static"}function Ue(o,s){if(!A(o)||L(o).position==="fixed")return null;if(s)return s(o);let t=o.offsetParent;return R(o)===t&&(t=t.ownerDocument.body),t}function Xe(o,s){const t=S(o);if(fe(o))return t;if(!A(o)){let n=M(o);for(;n&&!Z(n);){if(D(n)&&!Ne(n))return n;n=M(n)}return t}let l=Ue(o,s);for(;l&&ks(l)&&Ne(l);)l=Ue(l,s);return l&&Z(l)&&Ne(l)&&!ze(l)?t:l||Bs(o)||t}const _s=async function(o){const s=this.getOffsetParent||Xe,t=this.getDimensions,l=await t(o.floating);return{reference:As(o.reference,await s(o.floating),o.strategy),floating:{x:0,y:0,width:l.width,height:l.height}}};function Ps(o){return L(o).direction==="rtl"}const Ts={convertOffsetParentRelativeRectToViewportRelativeRect:Es,getDocumentElement:R,getClippingRect:Os,getOffsetParent:Xe,getElementRects:_s,getClientRects:Vs,getDimensions:Rs,getScale:Q,isElement:D,isRTL:Ps};function Ms(o,s){let t=null,l;const n=R(o);function r(){var a;clearTimeout(l),(a=t)==null||a.disconnect(),t=null}function i(a,c){a===void 0&&(a=!1),c===void 0&&(c=1),r();const{left:d,top:u,width:f,height:m}=o.getBoundingClientRect();if(a||s(),!f||!m)return;const h=ce(u),y=ce(n.clientWidth-(d+f)),g=ce(n.clientHeight-(u+m)),b=ce(d),p={rootMargin:-h+"px "+-y+"px "+-g+"px "+-b+"px",threshold:H(0,X(1,c))||1};let C=!0;function w(k){const $=k[0].intersectionRatio;if($!==c){if(!C)return i();$?i(!1,$):l=setTimeout(()=>{i(!1,1e-7)},1e3)}C=!1}try{t=new IntersectionObserver(w,{...p,root:n.ownerDocument})}catch{t=new IntersectionObserver(w,p)}t.observe(o)}return i(!0),r}function vs(o,s,t,l){l===void 0&&(l={});const{ancestorScroll:n=!0,ancestorResize:r=!0,elementResize:i=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:c=!1}=l,d=Ve(o),u=n||r?[...d?ne(d):[],...ne(s)]:[];u.forEach(x=>{n&&x.addEventListener("scroll",t,{passive:!0}),r&&x.addEventListener("resize",t)});const f=d&&a?Ms(d,t):null;let m=-1,h=null;i&&(h=new ResizeObserver(x=>{let[p]=x;p&&p.target===d&&h&&(h.unobserve(s),cancelAnimationFrame(m),m=requestAnimationFrame(()=>{var C;(C=h)==null||C.observe(s)})),t()}),d&&!c&&h.observe(d),h.observe(s));let y,g=c?K(o):null;c&&b();function b(){const x=K(o);g&&(x.x!==g.x||x.y!==g.y||x.width!==g.width||x.height!==g.height)&&t(),g=x,y=requestAnimationFrame(b)}return t(),()=>{var x;u.forEach(p=>{n&&p.removeEventListener("scroll",t),r&&p.removeEventListener("resize",t)}),f==null||f(),(x=h)==null||x.disconnect(),h=null,c&&cancelAnimationFrame(y)}}const Ge=ws,Ze=Cs,Qe=xs,Is=ys,js=(o,s,t)=>{const l=new Map,n={platform:Ts,...t},r={...n.platform,_c:l};return hs(o,s,{...n,platform:r})};function Fs(o){return o!=null&&typeof o=="object"&&"$el"in o}function De(o){if(Fs(o)){const s=o.$el;return Be(s)&&Y(s)==="#comment"?null:s}return o}function J(o){return typeof o=="function"?o():e.unref(o)}function Ws(o){return{name:"arrow",options:o,fn(s){const t=De(J(o.element));return t==null?{}:Is({element:t,padding:o.padding}).fn(s)}}}function Je(o){return typeof window>"u"?1:(o.ownerDocument.defaultView||window).devicePixelRatio||1}function et(o,s){const t=Je(o);return Math.round(s*t)/t}function tt(o,s,t){t===void 0&&(t={});const l=t.whileElementsMounted,n=e.computed(()=>{var z;return(z=J(t.open))!=null?z:!0}),r=e.computed(()=>J(t.middleware)),i=e.computed(()=>{var z;return(z=J(t.placement))!=null?z:"bottom"}),a=e.computed(()=>{var z;return(z=J(t.strategy))!=null?z:"absolute"}),c=e.computed(()=>{var z;return(z=J(t.transform))!=null?z:!0}),d=e.computed(()=>De(o.value)),u=e.computed(()=>De(s.value)),f=e.ref(0),m=e.ref(0),h=e.ref(a.value),y=e.ref(i.value),g=e.shallowRef({}),b=e.ref(!1),x=e.computed(()=>{const z={position:h.value,left:"0",top:"0"};if(!u.value)return z;const E=et(u.value,f.value),_=et(u.value,m.value);return c.value?{...z,transform:"translate("+E+"px, "+_+"px)",...Je(u.value)>=1.5&&{willChange:"transform"}}:{position:h.value,left:E+"px",top:_+"px"}});let p;function C(){if(d.value==null||u.value==null)return;const z=n.value;js(d.value,u.value,{middleware:r.value,placement:i.value,strategy:a.value}).then(E=>{f.value=E.x,m.value=E.y,h.value=E.strategy,y.value=E.placement,g.value=E.middlewareData,b.value=z!==!1})}function w(){typeof p=="function"&&(p(),p=void 0)}function k(){if(w(),l===void 0){C();return}if(d.value!=null&&u.value!=null){p=l(d.value,u.value,C);return}}function $(){n.value||(b.value=!1)}return e.watch([r,i,a,n],C,{flush:"sync"}),e.watch([d,u],k,{flush:"sync"}),e.watch(n,$,{flush:"sync"}),e.getCurrentScope()&&e.onScopeDispose(w),{x:e.shallowReadonly(f),y:e.shallowReadonly(m),strategy:e.shallowReadonly(h),placement:e.shallowReadonly(y),middlewareData:e.shallowReadonly(g),isPositioned:e.shallowReadonly(b),floatingStyles:x,update:C}}function Hs(o){return e.getCurrentScope()?(e.onScopeDispose(o),!0):!1}const qs=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;function st(o,s,t={}){const{immediate:l=!0}=t,n=e.ref(!1);let r=null;function i(){r&&(clearTimeout(r),r=null)}function a(){n.value=!1,i()}function c(...d){i(),n.value=!0,r=setTimeout(()=>{n.value=!1,r=null,o(...d)},e.toValue(s))}return l&&(n.value=!0,qs&&c()),Hs(a),{isPending:e.readonly(n),start:c,stop:a}}function ot(o={}){const{openDelay:s=0,closeDelay:t=150,onOpen:l,onClose:n,initiallyOpened:r=!1}=o,i=e.ref(!1),{start:a,stop:c}=st(()=>{i.value=!0,l==null||l()},s),{start:d,stop:u}=st(()=>{i.value=!1,n==null||n()},t),f=()=>{u(),s===0?(i.value=!0,l==null||l()):a()},m=()=>{c(),t===0?(i.value=!1,n==null||n()):d()};return r&&f(),{isOpen:i,open:f,close:m}}const Le=Symbol("hover-card"),Oe=e.defineComponent({__name:"HoverCardTarget",props:{withWrapper:{type:Boolean,default:!1},wrapperClass:{default:""}},setup(o){return e.inject(Le,null),(s,t)=>s.withWrapper?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(s.wrapperClass)},[e.renderSlot(s.$slots,"default")],2)):e.renderSlot(s.$slots,"default",{key:1})}}),Ys={class:"rounded-lg bg-white dark:bg-gray-800 shadow-lg border border-gray-200 dark:border-gray-700 px-3 py-2"},nt=e.defineComponent({__name:"HoverCard",props:{initiallyOpened:{type:Boolean,default:!1},openDelay:{default:0},closeDelay:{default:150},placement:{default:"bottom"},onOpen:{},onClose:{},offset:{default:8},disabled:{type:Boolean,default:!1},size:{default:"md"},withArrow:{type:Boolean,default:!0},arrowOffset:{default:8},trapFocus:{type:Boolean,default:!0},zIndex:{default:1e3}},setup(o){const s=o,t=e.ref(!1);e.onMounted(()=>{t.value=!0});const l=e.ref(null),n=e.ref(null),r=e.ref(null),{isOpen:i,open:a,close:c}=ot({openDelay:s.openDelay,closeDelay:s.closeDelay,initiallyOpened:s.initiallyOpened});e.provide(Le,{isOpen:i,open:a,close:c});const{x:d,y:u,strategy:f,middlewareData:m,placement:h,update:y}=tt(n,r,{placement:s.placement,middleware:[Ge(s.offset),Qe({fallbackPlacements:["top","bottom","right","left"].filter(w=>w!==s.placement)}),Ze({padding:8}),Ws({element:l})]});e.watch(i,async w=>{w&&await y()});const g=e.computed(()=>{var w,k;return(k=(w=m.value)==null?void 0:w.arrow)==null?void 0:k.x}),b=e.computed(()=>{var w,k;return(k=(w=m.value)==null?void 0:w.arrow)==null?void 0:k.y}),x=e.computed(()=>{switch(h.value){case"top":return"bottom";case"bottom":return"top";case"left":return"right";case"right":return"left";default:return"bottom"}}),p=e.computed(()=>{switch(h.value){case"top":return"translate(-50%, 50%)";case"bottom":return"translate(-50%, -50%)";case"left":return"translate(50%, -50%)";case"right":return"translate(-50%, -50%)";default:return"translate(-50%, -50%)"}}),C=e.computed(()=>({xs:"w-[200px]",sm:"w-[240px]",md:"w-[320px]",lg:"w-[400px]",xl:"w-[480px]"})[s.size]);return(w,k)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"reference",ref:n,class:"relative inline-block",onMouseenter:k[2]||(k[2]=$=>!w.disabled&&e.unref(a)()),onMouseleave:k[3]||(k[3]=$=>!w.disabled&&e.unref(c)())},[e.createVNode(Oe,null,{default:e.withCtx(()=>[e.renderSlot(w.$slots,"target")]),_:3}),t.value?(e.openBlock(),e.createBlock(e.Teleport,{key:0,to:"body"},[e.createVNode(e.Transition,{"enter-active-class":"transition duration-200 ease-out","enter-from-class":"opacity-0 translate-y-1","enter-to-class":"opacity-100 translate-y-0","leave-active-class":"transition duration-150 ease-in","leave-from-class":"opacity-100 translate-y-0","leave-to-class":"opacity-0 translate-y-1"},{default:e.withCtx(()=>[e.unref(i)?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"floating",ref:r,style:e.normalizeStyle({position:e.unref(f),top:`${e.unref(u)??0}px`,left:`${e.unref(d)??0}px`,zIndex:w.zIndex||1e3}),class:e.normalizeClass(["min-w-[200px]",[C.value]]),onMouseenter:k[0]||(k[0]=$=>!w.disabled&&e.unref(a)()),onMouseleave:k[1]||(k[1]=$=>!w.disabled&&e.unref(c)())},[e.createElementVNode("div",Ys,[e.renderSlot(w.$slots,"dropdown")]),w.withArrow?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"arrowRef",ref:l,class:"absolute w-2 h-2 rotate-45 bg-white dark:bg-gray-800 border border-gray-200 dark:border-gray-700",style:e.normalizeStyle({position:"absolute",left:`${g.value??0}px`,top:`${b.value??0}px`,[x.value]:"-1px","z-index":-1,"transform-origin":"center",transform:`rotate(45deg) ${p.value}`})},null,4)):e.createCommentVNode("",!0)],38)):e.createCommentVNode("",!0)]),_:3})])):e.createCommentVNode("",!0)],544))}});Object.assign(nt,{Target:Oe});const Ks={},Us={key:0,class:"badge-section mr-2"},Xs={class:"badge-label"},Gs={key:1,class:"badge-section ml-2"},Zs=e.defineComponent({__name:"Badge",props:{size:{default:"md"},circle:{type:Boolean,default:!1},radius:{default:"xl"},color:{default:"primary"},gradient:{},leftSection:{},rightSection:{},fullWidth:{type:Boolean,default:!1},variant:{default:"filled"}},setup(o){const s=o,t=r=>({none:"rounded-none",xs:"rounded",sm:"rounded-md",md:"rounded-lg",lg:"rounded-xl",xl:"rounded-2xl",full:"rounded-full"})[r]||"rounded-lg",l=r=>`relative pl-6 before:absolute before:left-2 before:top-1/2 before:-translate-y-1/2 before:w-2 before:h-2 before:rounded-full before:bg-${r}-500`,n=e.computed(()=>{var f,m;const r="inline-flex items-center justify-center font-medium",i=s.variant==="gradient"?`bg-gradient-to-r from-${(f=s.gradient)==null?void 0:f.from} to-${(m=s.gradient)==null?void 0:m.to} text-white`:F(s.color,s.variant),a=N(s.size,"badge"),c=t(s.radius),d=s.variant==="dot"?l(s.color):"";return[r,i,a,c,d,{"aspect-square p-0":s.circle,"w-full":s.fullWidth}].filter(Boolean).join(" ")});return(r,i)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(n.value)},[r.leftSection?(e.openBlock(),e.createElementBlock("span",Us,[typeof r.leftSection=="string"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(r.leftSection),1)],64)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(r.leftSection),{key:1}))])):e.createCommentVNode("",!0),e.createElementVNode("span",Xs,[e.renderSlot(r.$slots,"default")]),r.rightSection?(e.openBlock(),e.createElementBlock("span",Gs,[typeof r.rightSection=="string"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(r.rightSection),1)],64)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(r.rightSection),{key:1}))])):e.createCommentVNode("",!0)],2))}}),mo="",Qs={mounted(o,s){o._clickOutside=t=>{const l=t.target;o===l||o.contains(l)||s.value(t)},document.addEventListener("click",o._clickOutside,!0),document.addEventListener("touchstart",o._clickOutside,!0)},unmounted(o){o._clickOutside&&(document.removeEventListener("click",o._clickOutside,!0),document.removeEventListener("touchstart",o._clickOutside,!0))}};function Js(o){return{none:"cstu-rounded-none",sm:"cstu-rounded-sm",md:"cstu-rounded",lg:"cstu-rounded-lg",xl:"cstu-rounded-xl",full:"cstu-rounded-full"}[o]}const eo=["data-active"],to=e.defineComponent({__name:"Dropdown",props:{size:{default:"md"},radius:{default:"md"},open:{type:Boolean,default:!1},buttonClasses:{default:""},dropdownClasses:{default:""},placement:{default:"bottom"},disabled:{type:Boolean,default:!1},containerClasses:{default:""},showArrow:{type:Boolean,default:!0},disabledText:{default:""},parentPositionRelative:{type:Boolean,default:!0},offsetDistance:{default:8},unstyled:{type:Boolean,default:!1},matchWidth:{type:Boolean,default:!1}},emits:["close","update:open"],setup(o,{emit:s}){const t=o,l=s,n=e.ref(t.open),r=e.ref(0),i=e.ref(null),a=e.ref(null),c=e.computed(()=>{switch(t.placement){case"top":return"top-start";case"bottom":return"bottom-start";case"left":return"left-start";case"right":return"right-start";default:return"bottom-start"}}),{floatingStyles:d,update:u}=tt(a,i,{placement:c.value,middleware:[Ge(t.offsetDistance),Qe({fallbackPlacements:["top-start","bottom-start","left-start","right-start"],padding:8}),Ze({padding:8})],whileElementsMounted:vs,strategy:"fixed"}),f=e.inject("parentDropdownOpen",null);e.provide("parentDropdownOpen",n),e.watch(()=>f==null?void 0:f.value,p=>{p===!1&&(n.value=!1)},{immediate:!0}),e.watch(n,p=>{p&&e.nextTick(()=>{u()})});const m=e.computed(()=>N(t.size,"dropdown")),h=e.computed(()=>Js(t.radius));function y(p){var k,$;if(!n.value)return;if(!p){n.value=!1,l("close"),l("update:open",!1);return}(k=i.value)!=null&&k.contains(p.target)||($=a.value)!=null&&$.contains(p.target)||p.target.closest(".cstu-dropdown-menu")||(n.value=!1,l("close"),l("update:open",!1))}e.provide("dropdownClose",y);function g(){t.disabled||(n.value?(n.value=!1,l("close"),l("update:open",!1)):(n.value=!0,l("update:open",!0),setTimeout(()=>{var C,w;(C=i.value)==null||C.focus();const p=(w=i.value)==null?void 0:w.querySelector(".active");p==null||p.scrollIntoView({behavior:"smooth"})},100)))}function b(p){i.value&&(p.key==="ArrowUp"&&r.value>0?(p.preventDefault(),r.value--):p.key==="ArrowDown"&&r.value<i.value.children.length-1&&(p.preventDefault(),r.value++))}function x(p=!1){n.value=!1,!p&&(l("close"),l("update:open",!1))}return(p,C)=>e.withDirectives((e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["cstu-inline-block cstu-text-left cstu-dropdown-container",[{"cstu-relative":p.parentPositionRelative},{"cstu-grayscale cstu-filter cstu-cursor-not-allowed cstu-opacity-70":p.disabled},p.containerClasses]])},[e.createElementVNode("button",{ref_key:"buttonRef",ref:a,type:"button",class:e.normalizeClass([!p.unstyled&&"cstu-text-gray-500 cstu-inline-flex cstu-overflow-hidden cstu-text-ellipsis cstu-whitespace-pre cstu-justify-between cstu-items-center cstu-w-full focus:cstu-outline-none",!p.unstyled&&h.value,!p.unstyled&&m.value,{"cstu-pointer-events-none":p.disabled},p.buttonClasses||!p.unstyled&&"cstu-border cstu-border-gray-400/20 hover:cstu-bg-gray-100/50 hover:cstu-border-gray-400/25"]),"aria-expanded":"true","aria-haspopup":"true",onClick:g},[e.renderSlot(p.$slots,"icon",{closeDropdown:x}),e.renderSlot(p.$slots,"selected",{closeDropdown:x},()=>[C[0]||(C[0]=e.createTextVNode("Select"))]),p.showArrow?(e.openBlock(),e.createElementBlock("span",{key:0,class:e.normalizeClass(["cstu-transition cstu-leading-none",{"cstu-rotate-180":n.value}])},[e.renderSlot(p.$slots,"arrow",{closeDropdown:x},()=>[C[1]||(C[1]=e.createStaticVNode('<svg xmlns="http://www.w3.org/2000/svg" width="12" height="12" viewBox="0 0 12 12" fill="none"><g clip-path="url(#clip0_33663_12905)"><path d="M6 8.95312C5.91113 8.95312 5.82739 8.93604 5.74878 8.90186C5.67017 8.86768 5.6001 8.81982 5.53857 8.7583L0.93457 4.1543C0.886719 4.09961 0.845703 4.03467 0.811523 3.95947C0.777344 3.88428 0.760254 3.80225 0.760254 3.71338C0.760254 3.53564 0.823486 3.38354 0.949951 3.25708C1.07642 3.13062 1.23193 3.06738 1.4165 3.06738C1.49854 3.06738 1.57715 3.08276 1.65234 3.11353C1.72754 3.14429 1.7959 3.18701 1.85742 3.2417L6 7.40479L10.1426 3.2417C10.2041 3.18701 10.2725 3.14429 10.3477 3.11353C10.4229 3.08276 10.5015 3.06738 10.5835 3.06738C10.7681 3.06738 10.9236 3.13062 11.05 3.25708C11.1765 3.38354 11.2397 3.53564 11.2397 3.71338C11.2397 3.80225 11.2227 3.88428 11.1885 3.95947C11.1543 4.03467 11.1133 4.09961 11.0654 4.1543L6.46143 8.7583C6.3999 8.81982 6.32983 8.86768 6.25122 8.90186C6.17261 8.93604 6.08887 8.95312 6 8.95312Z" fill="#99A3A9"></path></g><defs><clipPath id="clip0_33663_12905"><rect width="10.5" height="11" fill="white" transform="matrix(1 0 0 -1 0.75 11.5)"></rect></clipPath></defs></svg>',1))])],2)):e.createCommentVNode("",!0)],2),e.createVNode(e.Transition,{"enter-active-class":"cstu-transition cstu-ease-out cstu-duration-100","enter-from-class":"cstu-transform cstu-opacity-0 cstu-scale-95","enter-to-class":"cstu-transform cstu-opacity-100 cstu-scale-100","leave-active-class":"cstu-transition cstu-ease-in cstu-duration-75","leave-from-class":"cstu-transform cstu-opacity-100 cstu-scale-100","leave-to-class":"cstu-transform cstu-opacity-0 cstu-scale-95"},{default:e.withCtx(()=>{var w;return[(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.withDirectives(e.createElementVNode("div",{ref_key:"dropdownList",ref:i,style:e.normalizeStyle([e.unref(d),t.matchWidth?{width:((w=a.value)==null?void 0:w.offsetWidth)+"px"}:{}]),class:e.normalizeClass(["cstu-dropdown-menu cstu-max-h-72 cstu-px-[12px] cstu-py-[13px] cstu-min-w-[225px] cstu-overflow-y-auto cstu-origin-top-left cstu-rounded-lg cstu-shadow-custom cstu-bg-white focus:cstu-outline-none cstu-z-50",[h.value,p.dropdownClasses]])},[e.createElementVNode("div",{class:"cstu-flex cstu-flex-col cstu-gap-[11px]",role:"menu","aria-orientation":"vertical","aria-labelledby":"menu-button","data-active":r.value,tabindex:"-1",onKeydown:b},[e.renderSlot(p.$slots,"default",{closeDropdown:x})],40,eo)],6),[[e.vShow,n.value]])]))]}),_:3})],2)),[[e.unref(Qs),y]])}}),so=e.defineComponent({__name:"DropdownItem",props:{disabled:{type:Boolean,default:!1},closeOnClick:{type:Boolean,default:!0},class:{default:""},selected:{type:Boolean,default:!1},size:{default:"md"}},emits:["click"],setup(o,{emit:s}){const t=o,l=s,n=e.inject("dropdownClose",()=>{}),r=e.computed(()=>t.class);function i(){t.disabled||(t.closeOnClick&&n(),l("click"))}return(a,c)=>(e.openBlock(),e.createElementBlock("div",{role:"menuitem",tabindex:"-1",class:e.normalizeClass(["cstu-cursor-pointer hover:cstu-bg-blue-50 active:cstu-bg-blue-50 cstu-rounded-lg",e.unref(ye)(t.size),"cstu-py-[5.5px] cstu-pr-[13.5px] cstu-pl-[10.5px]",{"cstu-cursor-not-allowed cstu-bg-gray-100":a.disabled},{"cstu-bg-blue-50":a.selected},r.value]),onClick:i},[e.renderSlot(a.$slots,"default",{selected:a.selected})],2))}}),lt=e.defineComponent({__name:"ListItem",props:{disabled:{type:Boolean,default:!1},selected:{type:Boolean,default:!1},class:{default:""},selectedClass:{default:""}},emits:["click"],setup(o,{emit:s}){const t=o,l=s,n=e.computed(()=>t.class);function r(){t.disabled||l("click")}return(i,a)=>(e.openBlock(),e.createElementBlock("div",{role:"listitem",tabindex:"-1",class:e.normalizeClass(["cstu-cursor-pointer cstu-rounded-lg","cstu-py-[5.5px] cstu-pr-[13.5px] cstu-pl-[10.5px]",{"hover:cstu-bg-blue-50 active:cstu-bg-blue-50":!i.disabled},{"cstu-cursor-not-allowed cstu-bg-gray-100 ":i.disabled},{[i.selectedClass||"cstu-bg-blue-50"]:i.selected&&!i.disabled},n.value]),onClick:r},[e.renderSlot(i.$slots,"default",{selected:i.selected})],2))}}),oo=e.defineComponent({__name:"Collapsible",props:{defaultOpen:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},class:{default:""},hideArrow:{type:Boolean,default:!1},buttonClass:{default:""},selectedClass:{default:""},modelValue:{type:Boolean,default:void 0}},emits:["update:modelValue"],setup(o,{emit:s}){const t=o,l=s,n=e.computed(()=>t.modelValue!==void 0),r=e.computed({get:()=>n.value?t.modelValue??!1:i.value,set:d=>{n.value?l("update:modelValue",d):i.value=d}}),i=e.ref(t.defaultOpen),a=e.computed(()=>t.class);function c(){t.disabled||(r.value=!r.value)}return(d,u)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["space-y-1 cstu-select-none",a.value])},[e.createVNode(lt,{role:"button",disabled:d.disabled,class:e.normalizeClass(["cstu-flex cstu-items-center cstu-justify-between",d.buttonClass].join(" ")),"selected-class":d.selectedClass,selected:r.value,onClick:c},{default:e.withCtx(()=>[e.renderSlot(d.$slots,"trigger",{open:r.value}),d.hideArrow?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("svg",{key:0,xmlns:"http://www.w3.org/2000/svg",width:"10",height:"7",viewBox:"0 0 10 7",fill:"none",class:e.normalizeClass(["cstu-transform cstu-transition-transform cstu-duration-200",{"cstu-rotate-180":r.value}])},u[0]||(u[0]=[e.createElementVNode("path",{d:"M5.64844 0.919922L9.81641 5.08789C9.91667 5.18815 9.9668 5.3099 9.9668 5.45312C9.9668 5.59635 9.91667 5.7181 9.81641 5.81836L9.34375 6.29102C9.24349 6.39128 9.12174 6.44499 8.97852 6.45215C8.83529 6.45931 8.71354 6.41276 8.61328 6.3125L5.2832 2.98242L1.95312 6.3125C1.85286 6.41276 1.73112 6.45931 1.58789 6.45215C1.44466 6.44499 1.32292 6.39128 1.22266 6.29102L0.75 5.81836C0.649739 5.7181 0.599609 5.59635 0.599609 5.45312C0.599609 5.3099 0.649739 5.18815 0.75 5.08789L4.91797 0.919922C5.01823 0.805339 5.13997 0.748047 5.2832 0.748047C5.42643 0.748047 5.54818 0.805339 5.64844 0.919922Z",fill:"#75797C"},null,-1)]),2))]),_:3},8,["disabled","class","selected-class","selected"]),e.createVNode(e.Transition,{"enter-active-class":"cstu-transition cstu-duration-100 cstu-ease-out","enter-from-class":"cstu-transform cstu-scale-95 cstu-opacity-0","enter-to-class":"cstu-transform cstu-scale-100 cstu-opacity-100","leave-active-class":"cstu-transition cstu-duration-75 cstu-ease-in","leave-from-class":"cstu-transform cstu-scale-100 cstu-opacity-100","leave-to-class":"cstu-transform cstu-scale-95 cstu-opacity-0"},{default:e.withCtx(()=>[e.withDirectives(e.createElementVNode("div",null,[e.renderSlot(d.$slots,"default")],512),[[e.vShow,r.value]])]),_:3})],2))}}),Re={none:"rounded-none",xs:"rounded",sm:"rounded-md",md:"rounded-lg",lg:"rounded-xl",xl:"rounded-2xl",full:"rounded-full"},no=["onClick","data-value"],lo=e.defineComponent({name:"SegmentedControl",__name:"SegmentedControl",props:{modelValue:{default:""},data:{},size:{default:"md"},radius:{default:"md"},color:{default:"primary"},disabled:{type:Boolean,default:!1},fullWidth:{type:Boolean,default:!1},transitionDuration:{default:200},withItemsBorders:{type:Boolean,default:!1},orientation:{default:"horizontal"}},emits:["update:modelValue"],setup(o,{emit:s}){const t=s,l=o,n=e.ref({}),r=e.ref(null),i=e.computed(()=>l.data.map(u=>typeof u=="string"?{value:u,label:u}:u)),a=e.computed(()=>l.orientation==="horizontal"?"cstu-flex-row":"cstu-flex-col"),c=async()=>{if(!l.modelValue)return;await e.nextTick();const u=n.value[l.modelValue];if(!u)return;const f=u.getBoundingClientRect(),m=u.parentElement.getBoundingClientRect();r.value={left:f.left-m.left,top:f.top-m.top,width:f.width,height:f.height}},d=u=>{t("update:modelValue",u)};return e.watch(()=>l.modelValue,c),e.watch(()=>l.orientation,c),e.onMounted(()=>{c(),window.addEventListener("resize",c)}),e.onUnmounted(()=>{window.removeEventListener("resize",c)}),(u,f)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["cstu-relative cstu-inline-flex",a.value,{"cstu-w-full":u.fullWidth,"cstu-opacity-50 cstu-pointer-events-none":u.disabled}]),role:"radiogroup"},[r.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["cstu-absolute cstu-bg-white cstu-rounded-[inherit]",e.unref(Re)[u.radius]]),style:e.normalizeStyle({transform:`translate(${r.value.left}px, ${r.value.top}px)`,width:`${r.value.width}px`,height:`${r.value.height}px`,transition:`transform ${u.transitionDuration}ms ease`,boxShadow:"0 1px 2px 0 rgb(0 0 0 / 0.05)"})},null,6)):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass(["cstu-relative cstu-flex",a.value,e.unref(Re)[u.radius],{"cstu-w-full":u.fullWidth,"cstu-divide-x cstu-divide-gray-200":u.withItemsBorders&&u.orientation==="horizontal","cstu-divide-y cstu-divide-gray-200":u.withItemsBorders&&u.orientation==="vertical"},e.unref(N)(u.size,"segmentedControlContainer"),"cstu-bg-gray-100"])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,m=>(e.openBlock(),e.createElementBlock("div",{key:m.value,class:e.normalizeClass(["cstu-relative cstu-flex-1","cstu-transition-all cstu-duration-200",e.unref(dt)(!!m.disabled),l.modelValue===m.value?"cstu-bg-white cstu-border-gray-500/15":"cstu-border-transparent",e.unref(N)(u.size,"segmentedControl"),"cstu-cursor-pointer","cstu-flex cstu-items-center cstu-justify-center hover:cstu-border-gray-500/15 cstu-border",e.unref(Re)[u.radius]]),onClick:()=>!m.disabled&&d(m.value),"data-value":m.value,ref_for:!0,ref:"el => segmentRefs[option.value] = el"},[e.createElementVNode("span",{class:e.normalizeClass([e.unref(xe)({size:u.size,disabled:m.disabled}),l.modelValue===m.value?"cstu-text-gray-500":"cstu-text-gray-600","cstu-select-none !cstu-mb-0 !cstu-font-normal cstu-capitalize cstu-whitespace-nowrap"])},e.toDisplayString(m.label),3)],10,no))),128))],2)],2))}}),go="";B.Alert=Zt,B.Badge=Zs,B.Button=gt,B.Checkbox=bt,B.Chip=It,B.Collapse=Qt,B.Collapsible=oo,B.Dialog=is,B.Dropdown=to,B.DropdownItem=so,B.HoverCard=nt,B.HoverCardTarget=Oe,B.Indicator=Ht,B.ListItem=lt,B.Loader=os,B.Progress=Yt,B.Radio=Bt,B.SegmentedControl=lo,B.Select=Pt,B.TextInput=St,B.composables=Ks,B.hoverCardInjectionKey=Le,B.useHoverCard=ot,Object.defineProperty(B,Symbol.toStringTag,{value:"Module"})});
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@contentstudio/ui",
3
- "version": "0.1.15",
3
+ "version": "0.1.16",
4
4
  "type": "module",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.js",