react-semaphor 0.1.71 → 0.1.72

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.
@@ -1,7 +1,7 @@
1
1
  import { jsxs as a, jsx as e, Fragment as Z } from "react/jsx-runtime";
2
- import { c as ce, a3 as Bs, u as J, a4 as At, a5 as It, B as q, a6 as Et, a7 as Ye, a8 as js, $ as et, a9 as je, aa as rt, ab as er, ac as Ve, ad as lt, ae as it, af as ot, ag as bt, ah as G, ai as we, aj as _t, I as ke, ak as $s, al as ma, am as Pl, an as Cn, ao as tr, f as Y, ap as qs, aq as Ll, ar, as as Vl, at as Rl, au as Gs, av as te, x as wn, aw as zl, ax as Bl, ay as vt, az as Ba, aA as ja, aB as sr, aC as nr, aD as Be, aE as ft, aF as jl, aG as $l, aH as Pt, aI as Lt, aJ as Pe, aK as gt, aL as Jt, aM as ct, aN as ks, aO as Ht, aP as Ds, aQ as Qe, aR as rr, aS as lr, aT as Vt, aU as ql, aV as $a, aW as qa, aX as Ga, aY as Ua, aZ as Ka, a_ as _a, a$ as Ja, b0 as Ha, b1 as Gl, b2 as Qa, b3 as xa, a2 as ee, b4 as Ul, b5 as xt, b6 as Kl, a1 as T, b7 as Le, o as Qt, b8 as ir, b9 as Me, ba as Te, bb as _l, bc as pt, bd as Wa, be as Oa, bf as Ya, bg as Jl, bh as Hl, bi as Us, bj as Ks, bk as Ql, bl as or, bm as Wl, R as da, bn as Yl, bo as Xl, bp as Zl, bq as Ia, w as ei, br as ti, bs as Pa, bt as cr, bu as ai, s as _s, bv as Xa, bw as si, bx as st, by as ni, bz as ri, bA as Ea, bB as li, bC as Ma, bD as Fa, bE as Za, X as ba, G as Sn, T as kn, L as dr, K as ur, z as kt, A as ii, H as oi, V as ci, bF as di, bG as Dn, bH as Tn, bI as mr, bJ as hr, bK as pr, bL as ui, bM as es, bN as ts, bO as fr, bP as Xe, bQ as Ie, bR as Ee, bS as Re, bT as Wt, bU as as, bV as Ne, bW as va, bX as mi, bY as La, bZ as Mt, b_ as gr, b$ as Js, c0 as hi, c1 as xr, c2 as Ze, c3 as fe, c4 as ge, c5 as xe, c6 as br, c7 as ha, c8 as ne, c9 as re, ca as le, cb as ie, cc as Q, cd as vr, ce as yr, cf as Nr, cg as Cr, ch as ya, g as Rt, ci as An, cj as Hs, ck as Tt, cl as pi, cm as Ts, cn as wr, co as Qs, cp as Sr, cq as Nt, cr as In, cs as fi, ct as gi, cu as xi, cv as kr, cw as ia, cx as bi, cy as vi, cz as Dr, cA as yi, cB as ss, cC as Ni, cD as Ci, cE as As, cF as Ft, cG as Ue, cH as Ot, cI as wi, cJ as Si, cK as Ws, cL as ns, cM as pa, cN as ki, cO as Ys, cP as Di, cQ as Ti, cR as Xs, cS as Ai, cT as Tr, cU as Ar, cV as Ir, cW as Er, cX as Ii, cY as Ei, cZ as rs, c_ as Mi, c$ as Fi, d0 as En, d1 as Oi, E as Na, b as Zs, d2 as Mr, d3 as Pi, d4 as Li, d5 as Vi, d6 as Ri, d7 as zi, d8 as Bi, d9 as Fr, da as ji, db as en, dc as Or, dd as Pr, de as Lr, df as Ca, dg as ls, dh as Vr, di as Is, dj as tn, dk as an, dl as Rr, dm as zr, dn as Br, dp as sn, dq as is, dr as os, ds as $i, P as zt, e as Bt, h as jt, dt as Ut, du as qi, dv as Gi, dw as Ui, dx as Ki, dy as _i, dz as Ji, dA as jr, dB as _e, dC as fa, dD as Va, dE as Dt, dF as Hi, dG as Qi, dH as Wi, dI as Yi, dJ as Xi, dK as $r, dL as Zi, i as cs, j as ds, k as us, l as ms, m as ea, n as wa, dM as eo, dN as nt, dO as Sa, dP as Mn, dQ as to, dR as Fn, dS as ao, dT as so, dU as no, dV as ro, dW as On, dX as lo, dY as io, dZ as oo, d_ as co, d$ as uo, Q as Pn, e0 as Ln, e1 as mo, e2 as ho, e3 as qr, e4 as po, e5 as Gr, e6 as fo, e7 as go, e8 as xo, e9 as bo, ea as vo, eb as yo, ec as No, ed as Co, ee as wo, ef as So, eg as Ur, eh as ko, ei as Do, ej as To, ek as Ao, el as Io, em as Eo, en as Kr, eo as xs, ep as bs, eq as nn, er as Mo, es as Fo, et as Vn, eu as Oo, ev as Po, ew as Lo, ex as ta, ey as aa, ez as Vo, eA as Ro, eB as _r, eC as zo, eD as Es, eE as Bo, eF as jo, eG as Ra, eH as Kt, eI as Ms, eJ as Fs, eK as za, eL as Jr, eM as sa, eN as na, eO as rn, eP as $o, eQ as qo, eR as Go, eS as Uo, eT as Ko, eU as _o, eV as vs, eW as Jo, eX as Ho, eY as Qo, F as Hr, eZ as Wo, e_ as Yo, e$ as Xo, f0 as Rn, f1 as Zo, f2 as ec, f3 as tc, f4 as ac, f5 as sc, f6 as Qr, f7 as Wr, f8 as nc, f9 as rc, fa as lc, fb as ic, fc as oc, fd as cc, fe as dc, S as uc, ff as mc, U as hc, fg as pc, C as fc } from "./index-B6tXS6wT.js";
3
- import * as Os from "react";
4
- import ga, { useRef as dt, useEffect as he, useState as R, useMemo as qe, useCallback as ye, useContext as hs, Suspense as Yr } from "react";
2
+ import { c as ce, a3 as js, u as J, a4 as At, a5 as It, B as q, a6 as Et, a7 as Ye, a8 as $s, $ as et, a9 as je, aa as rt, ab as sr, ac as Ve, ad as lt, ae as it, af as ot, ag as bt, ah as G, ai as we, aj as _t, I as ke, ak as qs, al as ma, am as Ll, an as kn, ao as nr, f as Y, ap as Gs, aq as Vl, ar as rr, as as Rl, at as zl, au as Us, av as te, x as Dn, aw as Bl, ax as jl, ay as vt, az as Ba, aA as ja, aB as lr, aC as ir, aD as Be, aE as ft, aF as $l, aG as ql, aH as Pt, aI as Lt, aJ as Pe, aK as gt, aL as Jt, aM as ct, aN as ks, aO as Ht, aP as Ds, aQ as Qe, aR as or, aS as cr, aT as Vt, aU as Gl, aV as $a, aW as qa, aX as Ga, aY as Ua, aZ as Ka, a_ as _a, a$ as Ja, b0 as Ha, b1 as Ul, b2 as Qa, b3 as xa, a2 as ee, b4 as Kl, b5 as xt, b6 as _l, a1 as T, b7 as Le, o as Qt, b8 as dr, b9 as Me, ba as Te, bb as Jl, bc as pt, bd as Wa, be as Oa, bf as Ya, bg as Hl, bh as Ql, bi as Ks, bj as _s, bk as Wl, bl as ur, bm as Yl, R as da, bn as Xl, bo as Zl, bp as ei, bq as Ia, w as ti, br as ai, bs as Pa, bt as mr, bu as si, s as Js, bv as Xa, bw as ni, bx as st, by as ri, bz as li, bA as Ea, bB as ii, bC as Ma, bD as Fa, bE as Za, X as ba, G as Tn, T as An, L as hr, K as pr, z as kt, A as oi, H as ci, V as di, bF as ui, bG as In, bH as En, bI as fr, bJ as gr, bK as xr, bL as mi, bM as es, bN as ts, bO as br, bP as Xe, bQ as Ie, bR as Ee, bS as Re, bT as Wt, bU as as, bV as Ne, bW as va, bX as hi, bY as La, bZ as Mt, b_ as vr, b$ as Hs, c0 as pi, c1 as yr, c2 as Ze, c3 as fe, c4 as ge, c5 as xe, c6 as Nr, c7 as ha, c8 as ne, c9 as re, ca as le, cb as ie, cc as Q, cd as Cr, ce as wr, cf as Sr, cg as kr, ch as ya, g as Rt, ci as Mn, cj as Qs, ck as Tt, cl as fi, cm as Ts, cn as Dr, co as Ws, cp as Tr, cq as Nt, cr as Fn, cs as gi, ct as xi, cu as bi, cv as Ar, cw as ia, cx as vi, cy as yi, cz as Ir, cA as Ni, cB as ss, cC as Ci, cD as wi, cE as As, cF as Ft, cG as Ue, cH as Ot, cI as Si, cJ as ki, cK as Ys, cL as ns, cM as pa, cN as Di, cO as Xs, cP as Ti, cQ as Is, cR as Zs, cS as Ai, cT as Er, cU as Mr, cV as Fr, cW as Or, cX as Ii, cY as Ei, cZ as rs, c_ as Mi, c$ as Fi, d0 as On, d1 as Oi, E as Na, b as en, d2 as Pr, d3 as Pi, d4 as Li, d5 as Vi, d6 as Ri, d7 as zi, d8 as Bi, d9 as Lr, da as ji, db as tn, dc as Vr, dd as an, de as sn, df as Ca, dg as ls, dh as Rr, di as Es, dj as nn, dk as rn, dl as zr, dm as Br, dn as jr, dp as ln, dq as is, dr as os, ds as $i, P as zt, e as Bt, h as jt, dt as Ut, du as qi, dv as Gi, dw as Ui, dx as Ki, dy as _i, dz as Ji, dA as $r, dB as _e, dC as fa, dD as Va, dE as Dt, dF as Hi, dG as Qi, dH as Wi, dI as Yi, dJ as Xi, dK as qr, dL as Zi, i as cs, j as ds, k as us, l as ms, m as ea, n as wa, dM as eo, dN as nt, dO as Sa, dP as Pn, dQ as to, dR as Ln, dS as ao, dT as so, dU as no, dV as ro, dW as Vn, dX as lo, dY as io, dZ as oo, d_ as co, d$ as uo, Q as Rn, e0 as zn, e1 as mo, e2 as ho, e3 as Gr, e4 as po, e5 as Ur, e6 as fo, e7 as go, e8 as xo, e9 as bo, ea as vo, eb as yo, ec as No, ed as Co, ee as wo, ef as So, eg as Kr, eh as ko, ei as Do, ej as To, ek as Ao, el as Io, em as Eo, en as _r, eo as xs, ep as bs, eq as on, er as Mo, es as Fo, et as Bn, eu as Oo, ev as Po, ew as Lo, ex as ta, ey as aa, ez as Vo, eA as Ro, eB as Jr, eC as zo, eD as Ms, eE as Bo, eF as jo, eG as Ra, eH as Kt, eI as Fs, eJ as Os, eK as za, eL as Hr, eM as sa, eN as na, eO as cn, eP as $o, eQ as qo, eR as Go, eS as Uo, eT as Ko, eU as _o, eV as vs, eW as Jo, eX as Ho, eY as Qo, F as Qr, eZ as Wo, e_ as Yo, e$ as Xo, f0 as jn, f1 as Zo, f2 as ec, f3 as tc, f4 as ac, f5 as sc, f6 as Wr, f7 as Yr, f8 as nc, f9 as rc, fa as lc, fb as ic, fc as oc, fd as cc, fe as dc, S as uc, ff as mc, U as hc, fg as pc, C as fc } from "./index-CqRITkaw.js";
3
+ import * as Ps from "react";
4
+ import ga, { useRef as dt, useEffect as he, useState as R, useMemo as qe, useCallback as ye, useContext as hs, Suspense as Xr } from "react";
5
5
  import { createPortal as gc } from "react-dom";
6
6
  /**
7
7
  * @license lucide-react v0.453.0 - ISC
@@ -66,7 +66,7 @@ const yc = ce("CirclePlus", [
66
66
  * This source code is licensed under the ISC license.
67
67
  * See the LICENSE file in the root directory of this source tree.
68
68
  */
69
- const Xr = ce("CircleX", [
69
+ const Zr = ce("CircleX", [
70
70
  ["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
71
71
  ["path", { d: "m15 9-6 6", key: "1uzhvr" }],
72
72
  ["path", { d: "m9 9 6 6", key: "z0biqf" }]
@@ -167,7 +167,7 @@ const kc = ce("EyeClosed", [
167
167
  * This source code is licensed under the ISC license.
168
168
  * See the LICENSE file in the root directory of this source tree.
169
169
  */
170
- const Zr = ce("FileCode2", [
170
+ const el = ce("FileCode2", [
171
171
  ["path", { d: "M4 22h14a2 2 0 0 0 2-2V7l-5-5H6a2 2 0 0 0-2 2v4", key: "1pf5j1" }],
172
172
  ["path", { d: "M14 2v4a2 2 0 0 0 2 2h4", key: "tnqrlb" }],
173
173
  ["path", { d: "m5 12-3 3 3 3", key: "oke12k" }],
@@ -429,7 +429,7 @@ const $c = ce("PanelLeft", [
429
429
  * This source code is licensed under the ISC license.
430
430
  * See the LICENSE file in the root directory of this source tree.
431
431
  */
432
- const zn = ce("RotateCcw", [
432
+ const $n = ce("RotateCcw", [
433
433
  ["path", { d: "M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8", key: "1357e3" }],
434
434
  ["path", { d: "M3 3v5h5", key: "1xhq8a" }]
435
435
  ]);
@@ -501,7 +501,7 @@ const Gc = ce("ShieldX", [
501
501
  * This source code is licensed under the ISC license.
502
502
  * See the LICENSE file in the root directory of this source tree.
503
503
  */
504
- const el = ce("SlidersHorizontal", [
504
+ const tl = ce("SlidersHorizontal", [
505
505
  ["line", { x1: "21", x2: "14", y1: "4", y2: "4", key: "obuewd" }],
506
506
  ["line", { x1: "10", x2: "3", y1: "4", y2: "4", key: "1q6298" }],
507
507
  ["line", { x1: "21", x2: "12", y1: "12", y2: "12", key: "1iu8h1" }],
@@ -555,7 +555,7 @@ const _c = ce("Sun", [
555
555
  * This source code is licensed under the ISC license.
556
556
  * See the LICENSE file in the root directory of this source tree.
557
557
  */
558
- const tl = ce("Tag", [
558
+ const al = ce("Tag", [
559
559
  [
560
560
  "path",
561
561
  {
@@ -627,7 +627,7 @@ const Wc = ce("Wand", [
627
627
  ["path", { d: "m3 21 9-9", key: "1jfql5" }],
628
628
  ["path", { d: "M12.2 6.2 11 5", key: "i3da3b" }]
629
629
  ]);
630
- function al(t, s = {}) {
630
+ function sl(t, s = {}) {
631
631
  const { enabled: n = !0, eventType: r = "mousedown" } = s, l = dt(null);
632
632
  return he(() => {
633
633
  const i = (c) => {
@@ -640,7 +640,7 @@ function al(t, s = {}) {
640
640
  }, [t, n, r]), l;
641
641
  }
642
642
  function Yc() {
643
- const { setTheme: t } = Bs(), s = J(
643
+ const { setTheme: t } = js(), s = J(
644
644
  (n) => n.actions.setDashboardTheme
645
645
  );
646
646
  return /* @__PURE__ */ a(At, { children: [
@@ -692,7 +692,7 @@ function Yc() {
692
692
  ] })
693
693
  ] });
694
694
  }
695
- function Ps(t) {
695
+ function Ls(t) {
696
696
  var s;
697
697
  return {
698
698
  ...t,
@@ -750,18 +750,18 @@ async function ed(t, s, n, r, l) {
750
750
  if (!l)
751
751
  return null;
752
752
  const i = JSON.stringify(n), c = `${t}/v1/lens`;
753
- return await js(c, l, {
753
+ return await $s(c, l, {
754
754
  name: s,
755
755
  template: i,
756
756
  filterValues: r,
757
757
  operation: "create"
758
758
  });
759
759
  }
760
- async function Ls(t, s, n) {
760
+ async function Vs(t, s, n) {
761
761
  if (!n)
762
762
  return null;
763
763
  const { id: r, template: l, filterValues: i, isDefault: c, shared: o } = s, d = `${t}/v1/lens`;
764
- return await js(d, n, {
764
+ return await $s(d, n, {
765
765
  lensId: r,
766
766
  template: l,
767
767
  filterValues: i,
@@ -774,7 +774,7 @@ async function td(t, s, n) {
774
774
  if (!n)
775
775
  return null;
776
776
  const r = `${t}/v1/lens`;
777
- return await js(r, n, {
777
+ return await $s(r, n, {
778
778
  operation: "delete",
779
779
  lensId: s
780
780
  });
@@ -783,7 +783,7 @@ function ad() {
783
783
  const [t, s] = R(""), [n, r] = R(!1), l = J((y) => y.lenses), { setLenses: i, setSelectedLensId: c } = et(), [o, d] = R(!1), [u, m] = R(!1), h = J((y) => y.dashboard), p = J((y) => y.filterValues), { authToken: f, tokenProps: v } = je();
784
784
  async function b() {
785
785
  d(!0);
786
- const y = Ps(
786
+ const y = Ls(
787
787
  h
788
788
  ), k = await ed(
789
789
  v.apiServiceUrl,
@@ -795,7 +795,7 @@ function ad() {
795
795
  k && (i([...l || [], k]), c(k.id), m(!1)), d(!1);
796
796
  }
797
797
  return /* @__PURE__ */ a(rt, { open: u, onOpenChange: m, children: [
798
- /* @__PURE__ */ e(er, { asChild: !0, children: /* @__PURE__ */ a(
798
+ /* @__PURE__ */ e(sr, { asChild: !0, children: /* @__PURE__ */ a(
799
799
  q,
800
800
  {
801
801
  variant: "secondary",
@@ -865,30 +865,30 @@ function sd() {
865
865
  ...h,
866
866
  isDefault: !h.isDefault
867
867
  };
868
- await Ls(o.apiServiceUrl, f, c == null ? void 0 : c.accessToken);
868
+ await Vs(o.apiServiceUrl, f, c == null ? void 0 : c.accessToken);
869
869
  const v = n == null ? void 0 : n.find((b) => b.isDefault);
870
870
  if (v && v.id !== h.id) {
871
871
  const b = {
872
872
  ...v,
873
873
  isDefault: !1
874
874
  };
875
- await Ls(o.apiServiceUrl, b, c == null ? void 0 : c.accessToken);
875
+ await Vs(o.apiServiceUrl, b, c == null ? void 0 : c.accessToken);
876
876
  }
877
877
  }
878
878
  return /* @__PURE__ */ a(At, { open: t, onOpenChange: s, children: [
879
879
  /* @__PURE__ */ e(It, { asChild: !0, children: /* @__PURE__ */ e(ke, { tooltip: "Lenses", className: "h-7 p-2", children: /* @__PURE__ */ e(Ec, { className: "h-4 w-4" }) }) }),
880
880
  /* @__PURE__ */ a(Et, { align: "end", className: "w-60", children: [
881
- /* @__PURE__ */ e($s, { className: "px-3", children: "Lenses" }),
881
+ /* @__PURE__ */ e(qs, { className: "px-3", children: "Lenses" }),
882
882
  /* @__PURE__ */ e(ma, {}),
883
883
  /* @__PURE__ */ a(
884
- Pl,
884
+ Ll,
885
885
  {
886
886
  value: r,
887
887
  onValueChange: d,
888
888
  children: [
889
- /* @__PURE__ */ e(Cn, { value: "original", children: "Original" }),
889
+ /* @__PURE__ */ e(kn, { value: "original", children: "Original" }),
890
890
  n == null ? void 0 : n.map((h) => /* @__PURE__ */ a(
891
- Cn,
891
+ kn,
892
892
  {
893
893
  className: "group flex justify-between gap-2",
894
894
  value: h.id,
@@ -896,7 +896,7 @@ function sd() {
896
896
  /* @__PURE__ */ e("p", { children: h.name }),
897
897
  /* @__PURE__ */ a("span", { className: "flex items-center gap-3", children: [
898
898
  /* @__PURE__ */ e(
899
- tr,
899
+ nr,
900
900
  {
901
901
  onClick: (p) => {
902
902
  p.preventDefault(), m(h);
@@ -912,7 +912,7 @@ function sd() {
912
912
  }
913
913
  ),
914
914
  /* @__PURE__ */ e(
915
- qs,
915
+ Gs,
916
916
  {
917
917
  onClick: (p) => {
918
918
  p.preventDefault(), u(h.id);
@@ -941,7 +941,7 @@ function nd({
941
941
  "Generating PDF... may take up to 60 seconds"
942
942
  );
943
943
  try {
944
- await wn(d.apiServiceUrl), te.dismiss(h), te.success("PDF downloaded successfully!", {
944
+ await Dn(d.apiServiceUrl), te.dismiss(h), te.success("PDF downloaded successfully!", {
945
945
  duration: 2e3
946
946
  });
947
947
  } catch (p) {
@@ -958,7 +958,7 @@ function nd({
958
958
  "Generating protected PDF... may take up to 60 seconds"
959
959
  );
960
960
  try {
961
- await wn(d.apiServiceUrl, r), te.dismiss(h), te.success("Protected PDF downloaded successfully!", {
961
+ await Dn(d.apiServiceUrl, r), te.dismiss(h), te.success("Protected PDF downloaded successfully!", {
962
962
  duration: 2e3,
963
963
  position: "top-right"
964
964
  });
@@ -975,16 +975,16 @@ function nd({
975
975
  size: "sm",
976
976
  className: "h-7 p-2",
977
977
  disabled: o,
978
- children: /* @__PURE__ */ e(Ll, { className: Y("size-4", t) })
978
+ children: /* @__PURE__ */ e(Vl, { className: Y("size-4", t) })
979
979
  }
980
980
  ) }),
981
981
  /* @__PURE__ */ a(Et, { align: "end", children: [
982
982
  /* @__PURE__ */ a(Ye, { onClick: u, children: [
983
- /* @__PURE__ */ e(ar, { className: "mr-2 h-4 w-4" }),
983
+ /* @__PURE__ */ e(rr, { className: "mr-2 h-4 w-4" }),
984
984
  "Download PDF"
985
985
  ] }),
986
986
  /* @__PURE__ */ a(Ye, { onClick: () => n(!0), children: [
987
- /* @__PURE__ */ e(Vl, { className: "mr-2 h-4 w-4" }),
987
+ /* @__PURE__ */ e(Rl, { className: "mr-2 h-4 w-4" }),
988
988
  "Download Protected PDF"
989
989
  ] })
990
990
  ] })
@@ -1024,7 +1024,7 @@ function nd({
1024
1024
  size: "sm",
1025
1025
  className: "absolute right-0 top-0 h-full px-3 py-2 hover:bg-transparent",
1026
1026
  onClick: () => c(!i),
1027
- children: i ? /* @__PURE__ */ e(Rl, { className: "h-4 w-4 text-muted-foreground" }) : /* @__PURE__ */ e(Gs, { className: "h-4 w-4 text-muted-foreground" })
1027
+ children: i ? /* @__PURE__ */ e(zl, { className: "h-4 w-4 text-muted-foreground" }) : /* @__PURE__ */ e(Us, { className: "h-4 w-4 text-muted-foreground" })
1028
1028
  }
1029
1029
  )
1030
1030
  ] })
@@ -1065,11 +1065,11 @@ function rd({
1065
1065
  tooltip: "Schedule Dashboard",
1066
1066
  className: Y("h-7 p-2", t),
1067
1067
  onClick: () => n(!0),
1068
- children: /* @__PURE__ */ e(zl, { className: "size-4" })
1068
+ children: /* @__PURE__ */ e(Bl, { className: "size-4" })
1069
1069
  }
1070
1070
  ),
1071
1071
  /* @__PURE__ */ e(
1072
- Bl,
1072
+ jl,
1073
1073
  {
1074
1074
  open: s,
1075
1075
  onOpenChange: n,
@@ -1226,7 +1226,7 @@ function pd({
1226
1226
  /* @__PURE__ */ e("span", { className: "ml-2 text-xs text-muted-foreground", children: "(optional)" })
1227
1227
  ] }),
1228
1228
  /* @__PURE__ */ e(
1229
- sr,
1229
+ lr,
1230
1230
  {
1231
1231
  id: "group-description",
1232
1232
  placeholder: "Describe the purpose of this group...",
@@ -1246,7 +1246,7 @@ function pd({
1246
1246
  ] })
1247
1247
  ] }),
1248
1248
  /* @__PURE__ */ e("div", { className: "rounded-lg border bg-muted/50 p-4", children: /* @__PURE__ */ a("div", { className: "flex gap-3", children: [
1249
- /* @__PURE__ */ e(nr, { className: "h-4 w-4 mt-0.5 text-muted-foreground" }),
1249
+ /* @__PURE__ */ e(ir, { className: "h-4 w-4 mt-0.5 text-muted-foreground" }),
1250
1250
  /* @__PURE__ */ e("div", { className: "text-sm text-muted-foreground", children: "This group will be accessible to users in your workspace. You can add members after creating the group." })
1251
1251
  ] }) })
1252
1252
  ] }),
@@ -1286,7 +1286,7 @@ function fd({
1286
1286
  group: n,
1287
1287
  onUpdate: r
1288
1288
  }) {
1289
- const [l, i] = R("members"), [c, o] = R(""), [d, u] = R([]), [m, h] = R([]), { data: p, isLoading: f, refetch: v } = jl(n.id), b = n.type === "TENANT_GROUP" ? "tenant" : "organization", { users: y, isLoading: k } = $l({
1289
+ const [l, i] = R("members"), [c, o] = R(""), [d, u] = R([]), [m, h] = R([]), { data: p, isLoading: f, refetch: v } = $l(n.id), b = n.type === "TENANT_GROUP" ? "tenant" : "organization", { users: y, isLoading: k } = ql({
1290
1290
  type: b,
1291
1291
  tenantId: n.tenantId || void 0,
1292
1292
  active: !0,
@@ -1481,7 +1481,7 @@ function gd({
1481
1481
  onClick: n,
1482
1482
  children: [
1483
1483
  /* @__PURE__ */ e(Qe, { checked: s }),
1484
- /* @__PURE__ */ e(rr, { className: "h-8 w-8", children: /* @__PURE__ */ e(lr, { className: "text-xs", children: r }) }),
1484
+ /* @__PURE__ */ e(or, { className: "h-8 w-8", children: /* @__PURE__ */ e(cr, { className: "text-xs", children: r }) }),
1485
1485
  /* @__PURE__ */ a("div", { className: "flex-1", children: [
1486
1486
  /* @__PURE__ */ e("p", { className: "text-sm font-medium", children: ((c = t.user) == null ? void 0 : c.name) || "Unknown User" }),
1487
1487
  /* @__PURE__ */ e("p", { className: "text-xs text-muted-foreground", children: (o = t.user) == null ? void 0 : o.email })
@@ -1504,7 +1504,7 @@ function xd({
1504
1504
  onClick: n,
1505
1505
  children: [
1506
1506
  /* @__PURE__ */ e(Qe, { checked: s }),
1507
- /* @__PURE__ */ e(rr, { className: "h-8 w-8", children: /* @__PURE__ */ e(lr, { className: "text-xs", children: r }) }),
1507
+ /* @__PURE__ */ e(or, { className: "h-8 w-8", children: /* @__PURE__ */ e(cr, { className: "text-xs", children: r }) }),
1508
1508
  /* @__PURE__ */ a("div", { className: "flex-1", children: [
1509
1509
  /* @__PURE__ */ e("p", { className: "text-sm font-medium", children: t.name }),
1510
1510
  /* @__PURE__ */ e("p", { className: "text-xs text-muted-foreground", children: t.email })
@@ -1517,7 +1517,7 @@ function bd({
1517
1517
  open: t,
1518
1518
  onOpenChange: s
1519
1519
  }) {
1520
- const [n, r] = R("groups"), [l, i] = R(""), [c, o] = R(null), [d, u] = R(!1), [m, h] = R(null), { tokenProps: p } = je(), { currentUser: f } = Vt(), v = ud(), b = (f == null ? void 0 : f.type) === "tenant", y = p == null ? void 0 : p.tenantId, { groups: k, isLoading: A, refetch: V } = ql({
1520
+ const [n, r] = R("groups"), [l, i] = R(""), [c, o] = R(null), [d, u] = R(!1), [m, h] = R(null), { tokenProps: p } = je(), { currentUser: f } = Vt(), v = ud(), b = (f == null ? void 0 : f.type) === "tenant", y = p == null ? void 0 : p.tenantId, { groups: k, isLoading: A, refetch: V } = Gl({
1521
1521
  type: b ? "TENANT_GROUP" : "all",
1522
1522
  tenantId: b ? y : void 0,
1523
1523
  includeMembers: !1
@@ -1661,7 +1661,7 @@ function vd({
1661
1661
  ] }),
1662
1662
  /* @__PURE__ */ a("span", { children: [
1663
1663
  "Created ",
1664
- Gl(new Date(t.createdAt), "MMM d, yyyy")
1664
+ Ul(new Date(t.createdAt), "MMM d, yyyy")
1665
1665
  ] })
1666
1666
  ] })
1667
1667
  ] }),
@@ -1690,7 +1690,7 @@ function vd({
1690
1690
  ] })
1691
1691
  ] }) });
1692
1692
  }
1693
- function ln(t) {
1693
+ function dn(t) {
1694
1694
  const [s, n] = R(null), [r, l] = R(null);
1695
1695
  return he(() => {
1696
1696
  if (!t || t.trim() === "") {
@@ -1763,7 +1763,7 @@ function Nd(t, s) {
1763
1763
  }
1764
1764
  return t[0].id;
1765
1765
  }
1766
- async function Bn(t, s, n, r) {
1766
+ async function qn(t, s, n, r) {
1767
1767
  if (!s || !n)
1768
1768
  throw new Error("Missing auth token or visual ID");
1769
1769
  const l = ["resource-by-id", "visual", n], i = r.getQueryData(l);
@@ -1790,7 +1790,7 @@ async function Bn(t, s, n, r) {
1790
1790
  throw te.dismiss(c), o;
1791
1791
  }
1792
1792
  }
1793
- function sl(t) {
1793
+ function nl(t) {
1794
1794
  if (typeof t == "string")
1795
1795
  return JSON.parse(t);
1796
1796
  if (typeof t == "object")
@@ -1802,13 +1802,13 @@ function Cd(t, s) {
1802
1802
  const n = (t == null ? void 0 : t.frameObject) ?? ((i = t == null ? void 0 : t.visual) == null ? void 0 : i.frameObject);
1803
1803
  if (!n)
1804
1804
  return !1;
1805
- const r = sl(n);
1805
+ const r = nl(n);
1806
1806
  if (!(r != null && r.cards) || r.cards.length === 0)
1807
1807
  return !1;
1808
1808
  const l = (c = r.cards) == null ? void 0 : c.find(
1809
1809
  (o) => o.id === r.activeCardId
1810
1810
  );
1811
- return l ? (Kl({
1811
+ return l ? (_l({
1812
1812
  ...s,
1813
1813
  frame: r,
1814
1814
  card: l,
@@ -1817,7 +1817,7 @@ function Cd(t, s) {
1817
1817
  }
1818
1818
  function wd() {
1819
1819
  var p;
1820
- const { setCardSql: t } = ee(), s = T((f) => f.frame), n = T((f) => f.card), r = ln(
1820
+ const { setCardSql: t } = ee(), s = T((f) => f.frame), n = T((f) => f.card), r = dn(
1821
1821
  ((p = n.customCardPreferences) == null ? void 0 : p.url) || ""
1822
1822
  ), l = T(
1823
1823
  (f) => f.selectedSchemaName
@@ -1895,13 +1895,13 @@ function Yt() {
1895
1895
  clearSelectedFrameId: I,
1896
1896
  addFrame: w,
1897
1897
  setIsDashboardPanelOpen: g
1898
- } = et(), x = J((N) => N.selectedSheetId), C = J((N) => N.selectedFrameId), M = J((N) => N.dashboard), S = J((N) => N.filterValues), L = Ul((r == null ? void 0 : r.id) || "", {
1898
+ } = et(), x = J((N) => N.selectedSheetId), C = J((N) => N.selectedFrameId), M = J((N) => N.dashboard), S = J((N) => N.filterValues), L = Kl((r == null ? void 0 : r.id) || "", {
1899
1899
  enabled: !!(r != null && r.id) && !!(t != null && t.accessToken)
1900
1900
  }), E = ye(
1901
1901
  async (N) => {
1902
1902
  try {
1903
1903
  l(N), I();
1904
- const { data: F, fromCache: P } = await Bn(
1904
+ const { data: F, fromCache: P } = await qn(
1905
1905
  s.apiServiceUrl,
1906
1906
  (t == null ? void 0 : t.accessToken) || "",
1907
1907
  N.id,
@@ -1969,7 +1969,7 @@ function Yt() {
1969
1969
  success: !1,
1970
1970
  error: "No sheet selected. Please select a sheet first."
1971
1971
  };
1972
- const { data: P, fromCache: K } = await Bn(
1972
+ const { data: P, fromCache: K } = await qn(
1973
1973
  s.apiServiceUrl,
1974
1974
  (t == null ? void 0 : t.accessToken) || "",
1975
1975
  N.id,
@@ -1977,7 +1977,7 @@ function Yt() {
1977
1977
  ), B = (P == null ? void 0 : P.frameObject) ?? ((F = P == null ? void 0 : P.visual) == null ? void 0 : F.frameObject);
1978
1978
  if (!B)
1979
1979
  return { success: !1, error: "Visual has no frame data" };
1980
- const z = sl(B);
1980
+ const z = nl(B);
1981
1981
  if (!(z != null && z.cards) || z.cards.length === 0)
1982
1982
  return { success: !1, error: "Visual frame is malformed" };
1983
1983
  const U = {
@@ -2060,7 +2060,7 @@ function Sd({
2060
2060
  /* @__PURE__ */ a("div", { className: "grid gap-2", children: [
2061
2061
  /* @__PURE__ */ e(G, { htmlFor: "description", children: "Description (optional)" }),
2062
2062
  /* @__PURE__ */ e(
2063
- sr,
2063
+ lr,
2064
2064
  {
2065
2065
  id: "description",
2066
2066
  value: d,
@@ -2147,7 +2147,7 @@ function kd({
2147
2147
  const { setCardSql: n } = ee();
2148
2148
  T((d) => d.frame);
2149
2149
  const r = T((d) => d.card);
2150
- ln(
2150
+ dn(
2151
2151
  ((o = r.customCardPreferences) == null ? void 0 : o.url) || ""
2152
2152
  ), T(
2153
2153
  (d) => d.selectedSchemaName
@@ -2183,7 +2183,7 @@ function Dd({
2183
2183
  }) {
2184
2184
  const n = vt(), [r, l] = R(!1), i = J(
2185
2185
  (p) => p.actions.setIsDashboardPanelOpen
2186
- ), { setIsVisualEditing: c } = et(), { getUpdatedFrame: o } = Yt(), d = Qa(), u = T((p) => p.frame), m = ir();
2186
+ ), { setIsVisualEditing: c } = et(), { getUpdatedFrame: o } = Yt(), d = Qa(), u = T((p) => p.frame), m = dr();
2187
2187
  return /* @__PURE__ */ a(
2188
2188
  q,
2189
2189
  {
@@ -2232,7 +2232,7 @@ function Dd({
2232
2232
  function Td({
2233
2233
  className: t
2234
2234
  }) {
2235
- const s = vt(), [n, r] = R(!1), l = Qa(), i = T((p) => p.frame), c = J((p) => p.selectedSheetId), { updateFrame: o, setIsVisualEditing: d } = et(), { getUpdatedFrame: u } = Yt(), m = ir();
2235
+ const s = vt(), [n, r] = R(!1), l = Qa(), i = T((p) => p.frame), c = J((p) => p.selectedSheetId), { updateFrame: o, setIsVisualEditing: d } = et(), { getUpdatedFrame: u } = Yt(), m = dr();
2236
2236
  return /* @__PURE__ */ e(
2237
2237
  q,
2238
2238
  {
@@ -2344,7 +2344,7 @@ function Id({ className: t }) {
2344
2344
  }
2345
2345
  );
2346
2346
  }
2347
- function on() {
2347
+ function un() {
2348
2348
  const { setTempQueryData: t } = ee(), s = vt();
2349
2349
  T((b) => b.isDevMode);
2350
2350
  const n = T((b) => b.tempQueryData), r = T((b) => b.card), { queryKey: l } = Me(r), {
@@ -2382,7 +2382,7 @@ function on() {
2382
2382
  function Ed() {
2383
2383
  const [t, s] = R(!1), [n, r] = R(!1), [l, i] = R(null), c = T((O) => O.frame), o = T((O) => O.card), d = Qa(), u = J((O) => O.selectedSheetId), m = J(
2384
2384
  (O) => O.actions.setIsDashboardPanelOpen
2385
- ), { getUpdatedFrame: h } = Yt(), { selectVisual: p } = xa(), { addFrame: f, setSelectedFrameId: v, setIsVisualEditing: b } = et(), y = !!(c != null && c.visualId), k = (d == null ? void 0 : d.title) || (o == null ? void 0 : o.title) || "Untitled Visual", A = _l((O) => {
2385
+ ), { getUpdatedFrame: h } = Yt(), { selectVisual: p } = xa(), { addFrame: f, setSelectedFrameId: v, setIsVisualEditing: b } = et(), y = !!(c != null && c.visualId), k = (d == null ? void 0 : d.title) || (o == null ? void 0 : o.title) || "Untitled Visual", A = Jl((O) => {
2386
2386
  if (O != null && O.id) {
2387
2387
  if (p(O), n && l && u) {
2388
2388
  const I = {
@@ -2537,13 +2537,13 @@ function Fd({
2537
2537
  const n = T((o) => o.isDevMode), r = J((o) => o.isVisualEditing), { setIsDevMode: l } = ee(), { config: i } = hs(Ya).tokenProps, c = (i == null ? void 0 : i.showAdvancedMode) !== !1;
2538
2538
  return !r || !c ? null : /* @__PURE__ */ a("div", { className: Y("flex items-center space-x-2", t), children: [
2539
2539
  /* @__PURE__ */ e(
2540
- Jl,
2540
+ Hl,
2541
2541
  {
2542
2542
  className: Y("", s),
2543
2543
  checked: n,
2544
2544
  onCheckedChange: () => l(!n),
2545
2545
  id: "advanced-mode",
2546
- icon: /* @__PURE__ */ e(Hl, { className: "h-4 w-4" }),
2546
+ icon: /* @__PURE__ */ e(Ql, { className: "h-4 w-4" }),
2547
2547
  tooltip: n ? "Standard Mode" : "Advanced Mode"
2548
2548
  }
2549
2549
  ),
@@ -2556,7 +2556,7 @@ function Od() {
2556
2556
  authToken: t,
2557
2557
  tokenProps: s,
2558
2558
  id: n
2559
- } = je(), { isLocalDev: r, isConsoleMode: l } = Us(), { permissions: i } = Ks(), c = Ql(), { isLoading: o } = or();
2559
+ } = je(), { isLocalDev: r, isConsoleMode: l } = Ks(), { permissions: i } = _s(), c = Wl(), { isLoading: o } = ur();
2560
2560
  J((j) => j.theme);
2561
2561
  const d = J((j) => j.lenses), u = J((j) => j.selectedLensId), m = d == null ? void 0 : d.find((j) => j.id === u), h = J((j) => j.dashboard);
2562
2562
  J((j) => j.selectedSheetId);
@@ -2580,10 +2580,10 @@ function Od() {
2580
2580
  (j) => j.actions
2581
2581
  ), { setInitialDashboard: P, clearSelectedDashboard: K } = pt(
2582
2582
  (j) => j.actions
2583
- ), { resources: B } = Wl(da.DASHBOARD), { currentUser: z } = Vt(), U = Yl(z), $ = x || C, X = $ ? {
2583
+ ), { resources: B } = Yl(da.DASHBOARD), { currentUser: z } = Vt(), U = Xl(z), $ = x || C, X = $ ? {
2584
2584
  id: $.id,
2585
2585
  title: (h == null ? void 0 : h.title) || $.title || "Dashboard"
2586
- } : null, { handleAddNewFrame: de } = Xl(), [be, Ce] = R(!1), Se = Zl(da.DASHBOARD), ue = async (j, ve) => {
2586
+ } : null, { handleAddNewFrame: de } = Zl(), [be, Ce] = R(!1), Se = ei(da.DASHBOARD), ue = async (j, ve) => {
2587
2587
  if (!(h != null && h.id)) {
2588
2588
  console.log("No dashboard ID found");
2589
2589
  return;
@@ -2622,7 +2622,7 @@ function Od() {
2622
2622
  N(!0);
2623
2623
  };
2624
2624
  async function $e() {
2625
- const j = Ps(
2625
+ const j = Ls(
2626
2626
  h
2627
2627
  );
2628
2628
  Ce(!0);
@@ -2646,14 +2646,14 @@ function Od() {
2646
2646
  }
2647
2647
  async function tt() {
2648
2648
  if (b(!0), !u || !m) return;
2649
- const j = Ps(
2649
+ const j = Ls(
2650
2650
  h
2651
2651
  ), ve = JSON.stringify(j), pe = {
2652
2652
  ...m,
2653
2653
  template: ve,
2654
2654
  filterValues: w
2655
2655
  };
2656
- await Ls(
2656
+ await Vs(
2657
2657
  s.apiServiceUrl,
2658
2658
  pe,
2659
2659
  t == null ? void 0 : t.accessToken
@@ -2694,7 +2694,7 @@ function Od() {
2694
2694
  tooltip: "Dashboard Hub",
2695
2695
  onClick: () => K(),
2696
2696
  className: "h-7 p-2",
2697
- children: /* @__PURE__ */ e(tr, { className: "h-4 w-4" })
2697
+ children: /* @__PURE__ */ e(nr, { className: "h-4 w-4" })
2698
2698
  }
2699
2699
  )
2700
2700
  ] }),
@@ -2731,7 +2731,7 @@ function Od() {
2731
2731
  ke,
2732
2732
  {
2733
2733
  tooltip: "Invalidate Token",
2734
- onClick: () => ei(s.apiServiceUrl),
2734
+ onClick: () => ti(s.apiServiceUrl),
2735
2735
  className: "h-7 p-2",
2736
2736
  children: /* @__PURE__ */ e(Gc, { className: "h-4 w-4" })
2737
2737
  }
@@ -2753,7 +2753,7 @@ function Od() {
2753
2753
  tooltip: "Share Dashboard",
2754
2754
  onClick: () => k(!0),
2755
2755
  className: "h-7 p-2",
2756
- children: /* @__PURE__ */ e(ti, { className: "h-4 w-4" })
2756
+ children: /* @__PURE__ */ e(ai, { className: "h-4 w-4" })
2757
2757
  }
2758
2758
  ),
2759
2759
  !S && !g && p && i.canUseFilters && c && /* @__PURE__ */ e(
@@ -2804,7 +2804,7 @@ function Od() {
2804
2804
  onClick: me,
2805
2805
  size: "sm",
2806
2806
  children: [
2807
- /* @__PURE__ */ e(cr, { className: "mr-2 h-4 w-4" }),
2807
+ /* @__PURE__ */ e(mr, { className: "mr-2 h-4 w-4" }),
2808
2808
  "Edit"
2809
2809
  ]
2810
2810
  }
@@ -2829,7 +2829,7 @@ function Od() {
2829
2829
  onClick: () => F(!L),
2830
2830
  size: "sm",
2831
2831
  variant: "ghost",
2832
- children: /* @__PURE__ */ e(ai, { className: "h-4 w-4" })
2832
+ children: /* @__PURE__ */ e(si, { className: "h-4 w-4" })
2833
2833
  }
2834
2834
  ) }),
2835
2835
  !g && r && /* @__PURE__ */ e(Yc, {}),
@@ -2842,13 +2842,13 @@ function Od() {
2842
2842
  N(!1), F(!1);
2843
2843
  },
2844
2844
  children: [
2845
- /* @__PURE__ */ e(qs, { className: "mr-2 h-4 w-4" }),
2845
+ /* @__PURE__ */ e(Gs, { className: "mr-2 h-4 w-4" }),
2846
2846
  "Close"
2847
2847
  ]
2848
2848
  }
2849
2849
  ),
2850
2850
  y && X && /* @__PURE__ */ e(
2851
- _s,
2851
+ Js,
2852
2852
  {
2853
2853
  resource: X,
2854
2854
  resourceType: da.DASHBOARD,
@@ -2867,7 +2867,7 @@ function Od() {
2867
2867
  }
2868
2868
  );
2869
2869
  }
2870
- function cn(t) {
2870
+ function mn(t) {
2871
2871
  const { tokenProps: s, authToken: n } = je(), r = s == null ? void 0 : s.apiServiceUrl;
2872
2872
  return Xa({
2873
2873
  queryKey: ["joinability-map", t],
@@ -2875,7 +2875,7 @@ function cn(t) {
2875
2875
  if (!t || !(n != null && n.accessToken))
2876
2876
  return null;
2877
2877
  const l = `${r}/v1/domains/${t}/joinability`;
2878
- return si(l, n.accessToken);
2878
+ return ni(l, n.accessToken);
2879
2879
  },
2880
2880
  // Only run query when semantic domain exists AND auth is ready
2881
2881
  // This prevents caching null responses before auth token loads
@@ -2907,7 +2907,7 @@ function ua(t, s, n) {
2907
2907
  }
2908
2908
  return { isValid: !0 };
2909
2909
  }
2910
- function Vs(t, s, n, r, l) {
2910
+ function Rs(t, s, n, r, l) {
2911
2911
  if (t !== "kpi" || l.length < 3)
2912
2912
  return;
2913
2913
  const i = (s == null ? void 0 : s.groupByColumns) && s.groupByColumns.length > 0, c = (s == null ? void 0 : s.comparisonType) === "none";
@@ -2916,9 +2916,9 @@ function Vs(t, s, n, r, l) {
2916
2916
  comparisonType: "none"
2917
2917
  });
2918
2918
  }
2919
- const dn = (t) => {
2919
+ const hn = (t) => {
2920
2920
  var E;
2921
- const s = (E = t == null ? void 0 : t.dataSource) == null ? void 0 : E.semanticDomainId, { data: n } = cn(s), {
2921
+ const s = (E = t == null ? void 0 : t.dataSource) == null ? void 0 : E.semanticDomainId, { data: n } = mn(s), {
2922
2922
  updateCardConfig: r,
2923
2923
  updateGroupByColumn: l,
2924
2924
  updateMetricColumn: i,
@@ -3055,7 +3055,7 @@ const dn = (t) => {
3055
3055
  const P = v("metrics")[D];
3056
3056
  P && i(f, P.id, {
3057
3057
  aggregate: N,
3058
- label: ni(
3058
+ label: ri(
3059
3059
  P.name,
3060
3060
  N
3061
3061
  )
@@ -3144,7 +3144,7 @@ const dn = (t) => {
3144
3144
  ...v("pivotBy"),
3145
3145
  ...v("metrics"),
3146
3146
  ...v("sortBy")
3147
- ], F = ri(D, N, {
3147
+ ], F = li(D, N, {
3148
3148
  joinPlan: (U = t == null ? void 0 : t.config) == null ? void 0 : U.joinPlan,
3149
3149
  joinabilityMap: n == null ? void 0 : n.joinabilityMap,
3150
3150
  semanticDomainId: s
@@ -3153,7 +3153,7 @@ const dn = (t) => {
3153
3153
  F.showError && Ea();
3154
3154
  return;
3155
3155
  }
3156
- const P = li(
3156
+ const P = ii(
3157
3157
  D,
3158
3158
  N,
3159
3159
  p
@@ -3185,7 +3185,7 @@ const dn = (t) => {
3185
3185
  const z = Fa(D, P, B);
3186
3186
  if (z) {
3187
3187
  const $ = [...B, z];
3188
- b(P, $), P === "metrics" && Vs(
3188
+ b(P, $), P === "metrics" && Rs(
3189
3189
  p,
3190
3190
  t == null ? void 0 : t.config,
3191
3191
  r,
@@ -3268,7 +3268,7 @@ const dn = (t) => {
3268
3268
  function ka(t) {
3269
3269
  return `${t}-${xt()}`;
3270
3270
  }
3271
- function jn(t, s) {
3271
+ function Gn(t, s) {
3272
3272
  const n = Za(t.replace(/_/g, " "));
3273
3273
  switch (s) {
3274
3274
  case "SUM":
@@ -3302,7 +3302,7 @@ function Pd(t, s) {
3302
3302
  return n;
3303
3303
  }
3304
3304
  }
3305
- function un(t) {
3305
+ function pn(t) {
3306
3306
  if (!t || !t.selectedEntities || t.selectedEntities.length === 0)
3307
3307
  return {
3308
3308
  tableName: void 0,
@@ -3320,19 +3320,19 @@ function un(t) {
3320
3320
  connectionType: t.connectionType
3321
3321
  };
3322
3322
  }
3323
- function nl(t) {
3323
+ function rl(t) {
3324
3324
  if (!t || !t.selectedEntities || t.selectedEntities.length === 0)
3325
3325
  return !1;
3326
3326
  const s = t.selectedEntities[0];
3327
3327
  return !!(s != null && s.name);
3328
3328
  }
3329
- function rl() {
3329
+ function ll() {
3330
3330
  const t = T((w) => w.sqlGen), s = T((w) => w.isDevMode), n = T((w) => w.card.dataSource), r = T(
3331
3331
  (w) => {
3332
3332
  var g, x;
3333
3333
  return (x = (g = w.card) == null ? void 0 : g.queryConfig) == null ? void 0 : x.metricColumns;
3334
3334
  }
3335
- ), { tableName: l, schemaName: i, databaseName: c } = un(n), o = nl(n), d = T(
3335
+ ), { tableName: l, schemaName: i, databaseName: c } = pn(n), o = rl(n), d = T(
3336
3336
  (w) => w.selectedDatamodelId
3337
3337
  ), {
3338
3338
  addColumnToMetricColumns: u,
@@ -3353,11 +3353,11 @@ function rl() {
3353
3353
  if (!s) return;
3354
3354
  const g = A(w);
3355
3355
  if (s && o && l) {
3356
- const C = dr(g, t);
3356
+ const C = hr(g, t);
3357
3357
  f(C);
3358
3358
  const M = (x = y == null ? void 0 : y.find(
3359
3359
  (L) => L.id === d
3360
- )) == null ? void 0 : x.name, S = ur(
3360
+ )) == null ? void 0 : x.name, S = pr(
3361
3361
  C,
3362
3362
  kt(i || ""),
3363
3363
  kt(l),
@@ -3367,7 +3367,7 @@ function rl() {
3367
3367
  );
3368
3368
  S && (h(S), p(!0));
3369
3369
  } else if (!s) {
3370
- if (ii(g.data_type))
3370
+ if (oi(g.data_type))
3371
3371
  if (r && r.length > 0) {
3372
3372
  const C = {
3373
3373
  ...g,
@@ -3383,13 +3383,13 @@ function rl() {
3383
3383
  role: "metric",
3384
3384
  id: ka(g.column_name),
3385
3385
  name: g.column_name,
3386
- label: jn(g.column_name, "COUNT"),
3386
+ label: Gn(g.column_name, "COUNT"),
3387
3387
  type: g.data_type,
3388
3388
  aggregate: "COUNT"
3389
3389
  };
3390
3390
  u(C);
3391
3391
  }
3392
- if (oi(g.data_type)) {
3392
+ if (ci(g.data_type)) {
3393
3393
  const C = {
3394
3394
  ...g,
3395
3395
  role: "groupby",
@@ -3401,13 +3401,13 @@ function rl() {
3401
3401
  };
3402
3402
  m(C);
3403
3403
  }
3404
- if (Sn(g.data_type)) {
3404
+ if (Tn(g.data_type)) {
3405
3405
  const C = {
3406
3406
  ...g,
3407
3407
  role: "metric",
3408
3408
  id: ka(g.column_name),
3409
3409
  name: g.column_name,
3410
- label: jn(g.column_name, "SUM"),
3410
+ label: Gn(g.column_name, "SUM"),
3411
3411
  type: g.data_type,
3412
3412
  aggregate: "SUM"
3413
3413
  };
@@ -3420,7 +3420,7 @@ function rl() {
3420
3420
  console.warn("Cannot generate SQL: missing table metadata");
3421
3421
  return;
3422
3422
  }
3423
- const w = kn({
3423
+ const w = An({
3424
3424
  schemaName: i || "",
3425
3425
  tableName: l,
3426
3426
  modelName: k,
@@ -3436,7 +3436,7 @@ function rl() {
3436
3436
  console.warn("Cannot generate SQL: missing table metadata");
3437
3437
  return;
3438
3438
  }
3439
- const w = kn({
3439
+ const w = An({
3440
3440
  schemaName: i || "",
3441
3441
  tableName: l,
3442
3442
  modelName: k,
@@ -3445,15 +3445,15 @@ function rl() {
3445
3445
  });
3446
3446
  h(`SELECT COUNT(*) as count FROM ${w}`), p(!0);
3447
3447
  },
3448
- isNumberField: (w) => Sn(w.dataType)
3448
+ isNumberField: (w) => Tn(w.dataType)
3449
3449
  };
3450
3450
  }
3451
- function ll() {
3451
+ function il() {
3452
3452
  const t = T((v) => v.selectedConnectionId), s = T((v) => v.selectedDatamodelId), n = T((v) => v.selectedDatabaseName), r = T((v) => v.selectedSchemaName), l = T((v) => v.selectedTableName), i = J((v) => v.dashboard.filters) || [], c = J((v) => v.selectedSheetId), o = J((v) => v.actions.addFilter), d = J((v) => v.actions.removeFilter), { removeFilterValues: u } = et(), { modelItems: m, tableName: h, connectionType: p } = ba();
3453
3453
  function f(v, b = "sheet", y) {
3454
3454
  var C;
3455
3455
  const k = kt(v.column_name), A = kt(n || ""), V = kt(r || ""), O = kt(h);
3456
- let I = ci({
3456
+ let I = di({
3457
3457
  schemaName: V,
3458
3458
  tableName: O,
3459
3459
  connectionType: p,
@@ -3462,9 +3462,9 @@ function ll() {
3462
3462
  const g = (C = m == null ? void 0 : m.find(
3463
3463
  (M) => M.id === s
3464
3464
  )) == null ? void 0 : C.name;
3465
- s && s !== "none" && (w = `${Tn}.${g}.${k}`, I = `${Tn}.${g}`), y != null && y.qualifiedFieldName && (w = y.qualifiedFieldName), y != null && y.entityName && (I = y.entityName);
3465
+ s && s !== "none" && (w = `${En}.${g}.${k}`, I = `${En}.${g}`), y != null && y.qualifiedFieldName && (w = y.qualifiedFieldName), y != null && y.entityName && (I = y.entityName);
3466
3466
  let x;
3467
- if (b === "sheet" && c ? x = di(
3467
+ if (b === "sheet" && c ? x = ui(
3468
3468
  i,
3469
3469
  w,
3470
3470
  O,
@@ -3493,7 +3493,7 @@ function ll() {
3493
3493
  operation: "in",
3494
3494
  applyToSheetIds: S,
3495
3495
  // Add sheet scoping
3496
- sql: Dn(
3496
+ sql: In(
3497
3497
  v.data_type,
3498
3498
  I,
3499
3499
  k
@@ -3513,7 +3513,7 @@ function ll() {
3513
3513
  operation: "in",
3514
3514
  applyToSheetIds: S,
3515
3515
  // Add sheet scoping
3516
- sql: Dn(
3516
+ sql: In(
3517
3517
  v.data_type,
3518
3518
  I,
3519
3519
  k
@@ -3525,20 +3525,20 @@ function ll() {
3525
3525
  return { assignFilter: f };
3526
3526
  }
3527
3527
  function Ld({ column: t }) {
3528
- const [s, n] = R(!1), r = T((k) => k.card.dataSource), { tableName: l, schemaName: i, databaseName: c } = un(r), o = T(
3528
+ const [s, n] = R(!1), r = T((k) => k.card.dataSource), { tableName: l, schemaName: i, databaseName: c } = pn(r), o = T(
3529
3529
  (k) => k.selectedDatamodelId
3530
- ), d = T((k) => k.sqlGen), { modelItems: u, connectionType: m } = ba(), h = T((k) => k.actions.setSqlGen), p = T((k) => k.actions.setCardSql), f = T((k) => k.actions.setRunSql), v = nl(r);
3530
+ ), d = T((k) => k.sqlGen), { modelItems: u, connectionType: m } = ba(), h = T((k) => k.actions.setSqlGen), p = T((k) => k.actions.setCardSql), f = T((k) => k.actions.setRunSql), v = rl(r);
3531
3531
  function b(k, A) {
3532
3532
  var w;
3533
3533
  if (!v || !l) {
3534
3534
  console.warn("Cannot generate SQL: missing table metadata");
3535
3535
  return;
3536
3536
  }
3537
- const V = dr(k, d, A), O = (w = u == null ? void 0 : u.find(
3537
+ const V = hr(k, d, A), O = (w = u == null ? void 0 : u.find(
3538
3538
  (g) => g.id === o
3539
3539
  )) == null ? void 0 : w.name;
3540
3540
  h(V);
3541
- const I = ur(
3541
+ const I = pr(
3542
3542
  V,
3543
3543
  kt(i || ""),
3544
3544
  kt(l),
@@ -3592,10 +3592,10 @@ function Ld({ column: t }) {
3592
3592
  )
3593
3593
  ] });
3594
3594
  }
3595
- return v ? /* @__PURE__ */ a(mr, { openDelay: 0, open: s, onOpenChange: n, children: [
3596
- /* @__PURE__ */ e(hr, { asChild: !0, children: /* @__PURE__ */ e(Oa, { className: "invisible size-3.5 cursor-pointer text-foreground/40 group-hover/container:visible" }) }),
3595
+ return v ? /* @__PURE__ */ a(fr, { openDelay: 0, open: s, onOpenChange: n, children: [
3596
+ /* @__PURE__ */ e(gr, { asChild: !0, children: /* @__PURE__ */ e(Oa, { className: "invisible size-3.5 cursor-pointer text-foreground/40 group-hover/container:visible" }) }),
3597
3597
  /* @__PURE__ */ e(
3598
- pr,
3598
+ xr,
3599
3599
  {
3600
3600
  align: "center",
3601
3601
  className: "w-20 rounded-md p-0 shadow-none",
@@ -3623,7 +3623,7 @@ function Rd({
3623
3623
  context: s = "editor",
3624
3624
  fieldState: n
3625
3625
  }) {
3626
- const r = T(($) => $.isDevMode), l = s === "filter", i = r || l || (n == null ? void 0 : n.state) === "unreachable" && !l, c = J(($) => $.dashboard.filters), o = J(($) => $.selectedSheetId), d = J(($) => $.actions.removeFilter), { removeFilterValues: u } = et(), { assignFilter: m } = ll(), h = l ? ui(c, o) : c, p = l ? h == null ? void 0 : h.find(
3626
+ const r = T(($) => $.isDevMode), l = s === "filter", i = r || l || (n == null ? void 0 : n.state) === "unreachable" && !l, c = J(($) => $.dashboard.filters), o = J(($) => $.selectedSheetId), d = J(($) => $.actions.removeFilter), { removeFilterValues: u } = et(), { assignFilter: m } = il(), h = l ? mi(c, o) : c, p = l ? h == null ? void 0 : h.find(
3627
3627
  ($) => {
3628
3628
  var X;
3629
3629
  return $.title === t.name || ((X = $.column) == null ? void 0 : X.includes(t.name));
@@ -3659,7 +3659,7 @@ function Rd({
3659
3659
  } = es({
3660
3660
  id: t.id,
3661
3661
  disabled: i
3662
- }), [M, S] = R(!1), L = T(($) => $.card), { handleFieldClick: E } = dn(L), { handleDevModeFieldClick: D, isNumberField: N } = rl(), F = () => {
3662
+ }), [M, S] = R(!1), L = T(($) => $.card), { handleFieldClick: E } = hn(L), { handleDevModeFieldClick: D, isNumberField: N } = ll(), F = () => {
3663
3663
  v && (console.log("[SourceField] Removing multi-sheet filter:", v.id), u(v.id), d(v.id)), V(null), k(!1);
3664
3664
  }, P = () => {
3665
3665
  if (l) {
@@ -3762,7 +3762,7 @@ function Rd({
3762
3762
  className: "flex min-w-0 items-center gap-3 p-2",
3763
3763
  onClick: P,
3764
3764
  children: [
3765
- fr(t.dataType),
3765
+ br(t.dataType),
3766
3766
  /* @__PURE__ */ e(Xe, { children: /* @__PURE__ */ a(Ie, { children: [
3767
3767
  /* @__PURE__ */ e(Ee, { asChild: !0, children: /* @__PURE__ */ e("div", { className: "min-w-0 flex-1 overflow-hidden", children: /* @__PURE__ */ e(
3768
3768
  "span",
@@ -3807,7 +3807,7 @@ function Rd({
3807
3807
  // </div>
3808
3808
  /* @__PURE__ */ e("div", { className: "text-muted-foreground-700 px-2 pb-3 text-sm", children: /* @__PURE__ */ e(Wt, { className: "", children: /* @__PURE__ */ a(as, { className: "space-y-2 p-3", children: [
3809
3809
  /* @__PURE__ */ a("div", { className: "flex items-center gap-2", children: [
3810
- /* @__PURE__ */ e(tl, { className: "h-4 w-4 text-muted-foreground" }),
3810
+ /* @__PURE__ */ e(al, { className: "h-4 w-4 text-muted-foreground" }),
3811
3811
  /* @__PURE__ */ e("span", { className: "break-all", children: t.label || t.name })
3812
3812
  ] }),
3813
3813
  /* @__PURE__ */ a("div", { className: "flex items-center gap-2", children: [
@@ -3839,11 +3839,11 @@ function zd({ context: t = "editor" } = {}) {
3839
3839
  columnGroups: m = [],
3840
3840
  isLoading: h,
3841
3841
  error: p
3842
- } = va(), f = (i == null ? void 0 : i.mode) === "semanticDomain" ? i.semanticDomainId : void 0, { data: v } = cn(f), b = [
3842
+ } = va(), f = (i == null ? void 0 : i.mode) === "semanticDomain" ? i.semanticDomainId : void 0, { data: v } = mn(f), b = [
3843
3843
  ...(c == null ? void 0 : c.groupByColumns) || [],
3844
3844
  ...(c == null ? void 0 : c.metricColumns) || []
3845
3845
  ];
3846
- (S = (M = c == null ? void 0 : c.joinPlan) == null ? void 0 : M.baseEntity) == null || S.name, (E = (L = d == null ? void 0 : d.resolvedJoinPlan) == null ? void 0 : L.baseEntity) == null || E.name, rl();
3846
+ (S = (M = c == null ? void 0 : c.joinPlan) == null ? void 0 : M.baseEntity) == null || S.name, (E = (L = d == null ? void 0 : d.resolvedJoinPlan) == null ? void 0 : L.baseEntity) == null || E.name, ll();
3847
3847
  const y = u.filter(
3848
3848
  (D) => D.name.toLowerCase().includes(s.toLowerCase()) || D.dataType.toLowerCase().includes(s.toLowerCase()) || D.label && D.label.toLowerCase().includes(s.toLowerCase()) || D.qualifiedEntityName && D.qualifiedEntityName.toLowerCase().includes(s.toLowerCase())
3849
3849
  ), k = (D) => {
@@ -3856,7 +3856,7 @@ function zd({ context: t = "editor" } = {}) {
3856
3856
  )).reduce((D, N) => {
3857
3857
  const F = N.qualifiedEntityName || "Other Fields";
3858
3858
  return D[F] || (D[F] = {
3859
- label: mi(N.entityName),
3859
+ label: hi(N.entityName),
3860
3860
  fields: []
3861
3861
  }), D[F].fields.push(N), D;
3862
3862
  }, {}), I = Object.keys(V), w = y.filter(
@@ -3911,22 +3911,22 @@ function zd({ context: t = "editor" } = {}) {
3911
3911
  /* @__PURE__ */ e("span", { className: "ml-2 text-xs font-semibold", children: y.length })
3912
3912
  ] }),
3913
3913
  /* @__PURE__ */ a(Pe, { value: "dimensions", className: "text-xs", children: [
3914
- /* @__PURE__ */ e(gr, { className: "size-4 shrink-0" }),
3914
+ /* @__PURE__ */ e(vr, { className: "size-4 shrink-0" }),
3915
3915
  /* @__PURE__ */ e("span", { className: "ml-2 text-xs font-semibold", children: w })
3916
3916
  ] }),
3917
3917
  /* @__PURE__ */ a(Pe, { value: "metrics", className: "text-xs", children: [
3918
- /* @__PURE__ */ e(Js, { className: "size-4 shrink-0" }),
3918
+ /* @__PURE__ */ e(Hs, { className: "size-4 shrink-0" }),
3919
3919
  /* @__PURE__ */ e("span", { className: "ml-2 text-xs font-semibold", children: g })
3920
3920
  ] }),
3921
3921
  /* @__PURE__ */ a(Pe, { value: "calculated", className: "text-xs", children: [
3922
- /* @__PURE__ */ e(hi, { className: "size-4 shrink-0" }),
3922
+ /* @__PURE__ */ e(pi, { className: "size-4 shrink-0" }),
3923
3923
  /* @__PURE__ */ e("span", { className: "ml-2 text-xs font-semibold", children: x })
3924
3924
  ] })
3925
3925
  ] })
3926
3926
  }
3927
3927
  )
3928
3928
  ] }),
3929
- /* @__PURE__ */ a(xr, { className: "py-2", children: [
3929
+ /* @__PURE__ */ a(yr, { className: "py-2", children: [
3930
3930
  /* @__PURE__ */ e(
3931
3931
  Ze,
3932
3932
  {
@@ -3963,7 +3963,7 @@ function zd({ context: t = "editor" } = {}) {
3963
3963
  }
3964
3964
  ) }),
3965
3965
  /* @__PURE__ */ e(xe, { className: "pb-2", children: /* @__PURE__ */ e("div", { className: "space-y-1", children: N.fields.map((P) => {
3966
- const K = br(P, {
3966
+ const K = Nr(P, {
3967
3967
  joinabilityMap: (v == null ? void 0 : v.joinabilityMap) || null,
3968
3968
  selectedFields: b,
3969
3969
  cardConfig: c,
@@ -3998,7 +3998,7 @@ function zd({ context: t = "editor" } = {}) {
3998
3998
  ] })
3999
3999
  ] });
4000
4000
  }
4001
- function il({ context: t = "editor" } = {}) {
4001
+ function ol({ context: t = "editor" } = {}) {
4002
4002
  return /* @__PURE__ */ a(
4003
4003
  "div",
4004
4004
  {
@@ -4411,10 +4411,10 @@ function jd({
4411
4411
  (N) => N.name === S.target.name
4412
4412
  ), D = d.has(S.id);
4413
4413
  return /* @__PURE__ */ a(Wt, { className: "border", children: [
4414
- /* @__PURE__ */ e(vr, { className: "pb-3", children: /* @__PURE__ */ a("div", { className: "flex items-center justify-between", children: [
4414
+ /* @__PURE__ */ e(Cr, { className: "pb-3", children: /* @__PURE__ */ a("div", { className: "flex items-center justify-between", children: [
4415
4415
  /* @__PURE__ */ a("div", { className: "flex items-center gap-2", children: [
4416
4416
  /* @__PURE__ */ e(Ne, { children: S.sequence }),
4417
- /* @__PURE__ */ a(yr, { className: "text-sm", children: [
4417
+ /* @__PURE__ */ a(wr, { className: "text-sm", children: [
4418
4418
  "Join ",
4419
4419
  S.sequence,
4420
4420
  L && E && /* @__PURE__ */ a("span", { className: "ml-2 font-normal text-gray-600", children: [
@@ -4434,7 +4434,7 @@ function jd({
4434
4434
  size: "sm",
4435
4435
  onClick: () => f(S.id),
4436
4436
  disabled: S.sequence === 1,
4437
- children: /* @__PURE__ */ e(Nr, { className: "h-4 w-4" })
4437
+ children: /* @__PURE__ */ e(Sr, { className: "h-4 w-4" })
4438
4438
  }
4439
4439
  ),
4440
4440
  /* @__PURE__ */ e(
@@ -4444,7 +4444,7 @@ function jd({
4444
4444
  size: "sm",
4445
4445
  onClick: () => v(S.id),
4446
4446
  disabled: S.sequence === o.joins.length,
4447
- children: /* @__PURE__ */ e(Cr, { className: "h-4 w-4" })
4447
+ children: /* @__PURE__ */ e(kr, { className: "h-4 w-4" })
4448
4448
  }
4449
4449
  ),
4450
4450
  /* @__PURE__ */ e(
@@ -4903,7 +4903,7 @@ function jd({
4903
4903
  ] })
4904
4904
  ] });
4905
4905
  }
4906
- function Rs({
4906
+ function zs({
4907
4907
  children: t,
4908
4908
  open: s,
4909
4909
  onOpenChange: n,
@@ -5088,7 +5088,7 @@ ${y.joinType} JOIN ${k.name}
5088
5088
  onClick: () => i(!0),
5089
5089
  children: [
5090
5090
  /* @__PURE__ */ e(
5091
- An,
5091
+ Mn,
5092
5092
  {
5093
5093
  className: Y("mr-1 h-3 w-3", {
5094
5094
  "text-blue-500": r.joins.length > 0,
@@ -5128,7 +5128,7 @@ ${y.joinType} JOIN ${k.name}
5128
5128
  variant: "secondary",
5129
5129
  className: "h-6 gap-1 bg-blue-50 text-blue-700 dark:bg-blue-950 dark:text-blue-300",
5130
5130
  children: [
5131
- /* @__PURE__ */ e(Hs, { className: "h-3 w-3" }),
5131
+ /* @__PURE__ */ e(Qs, { className: "h-3 w-3" }),
5132
5132
  "Auto"
5133
5133
  ]
5134
5134
  }
@@ -5149,7 +5149,7 @@ ${y.joinType} JOIN ${k.name}
5149
5149
  ] }) })
5150
5150
  ] }) }),
5151
5151
  /* @__PURE__ */ e(
5152
- Rs,
5152
+ zs,
5153
5153
  {
5154
5154
  open: l,
5155
5155
  onOpenChange: i,
@@ -5163,7 +5163,7 @@ ${y.joinType} JOIN ${k.name}
5163
5163
  )
5164
5164
  ] }),
5165
5165
  r.joins.length === 0 && /* @__PURE__ */ e(
5166
- Rs,
5166
+ zs,
5167
5167
  {
5168
5168
  open: l,
5169
5169
  onOpenChange: i,
@@ -5180,7 +5180,7 @@ ${y.joinType} JOIN ${k.name}
5180
5180
  size: "sm",
5181
5181
  className: "w-full",
5182
5182
  children: [
5183
- /* @__PURE__ */ e(An, { className: "mr-3 size-4" }),
5183
+ /* @__PURE__ */ e(Mn, { className: "mr-3 size-4" }),
5184
5184
  "Configure Joins"
5185
5185
  ]
5186
5186
  }
@@ -5231,7 +5231,7 @@ function Gd({
5231
5231
  case "file":
5232
5232
  case "url":
5233
5233
  case "upload":
5234
- return /* @__PURE__ */ e(pi, { className: "h-4 w-4" });
5234
+ return /* @__PURE__ */ e(fi, { className: "h-4 w-4" });
5235
5235
  default:
5236
5236
  return /* @__PURE__ */ e(Mt, { className: "h-4 w-4" });
5237
5237
  }
@@ -5334,11 +5334,11 @@ function Ud({
5334
5334
  title: s,
5335
5335
  maxDetails: n = 10
5336
5336
  }) {
5337
- const l = wr(t).slice(0, n), i = l.find(
5337
+ const l = Dr(t).slice(0, n), i = l.find(
5338
5338
  (o) => o.label === "Description"
5339
5339
  ), c = l.filter((o) => o.label === "Description" ? !1 : !["Connection", "Database", "Schema"].includes(o.label));
5340
5340
  return /* @__PURE__ */ e(Re, { side: "top", className: "ml-5 max-w-xs", children: /* @__PURE__ */ a("div", { className: "space-y-2", children: [
5341
- /* @__PURE__ */ e("div", { className: "text-sm font-medium", children: s || Qs(t) }),
5341
+ /* @__PURE__ */ e("div", { className: "text-sm font-medium", children: s || Ws(t) }),
5342
5342
  i && /* @__PURE__ */ a("div", { className: "border-t border-border pt-2", children: [
5343
5343
  /* @__PURE__ */ e("div", { className: "mb-1 text-xs text-muted-foreground", children: "Description:" }),
5344
5344
  /* @__PURE__ */ e("div", { className: "text-xs leading-relaxed", children: i.value })
@@ -5361,7 +5361,7 @@ function Kd({
5361
5361
  " more entities"
5362
5362
  ] }),
5363
5363
  /* @__PURE__ */ e("div", { className: "space-y-1", children: t.map((s, n) => {
5364
- const r = wr(s), l = r.find(
5364
+ const r = Dr(s), l = r.find(
5365
5365
  (c) => c.label === "Description"
5366
5366
  ), i = r.filter((c) => c.label === "Description" ? !1 : !["Connection", "Database", "Schema"].includes(c.label)).slice(0, 3);
5367
5367
  return /* @__PURE__ */ a(
@@ -5369,7 +5369,7 @@ function Kd({
5369
5369
  {
5370
5370
  className: "border-b border-border pb-1 last:border-b-0",
5371
5371
  children: [
5372
- /* @__PURE__ */ e("div", { className: "text-xs font-medium", children: Qs(s) }),
5372
+ /* @__PURE__ */ e("div", { className: "text-xs font-medium", children: Ws(s) }),
5373
5373
  l && /* @__PURE__ */ a("div", { className: "mb-1 mt-1", children: [
5374
5374
  /* @__PURE__ */ e("div", { className: "text-xs text-muted-foreground", children: "Description:" }),
5375
5375
  /* @__PURE__ */ e("div", { className: "text-xs leading-relaxed", children: l.value })
@@ -5395,7 +5395,7 @@ function Kd({
5395
5395
  }) })
5396
5396
  ] }) });
5397
5397
  }
5398
- function ol() {
5398
+ function cl() {
5399
5399
  const t = T((c) => c.card.dataSource), {
5400
5400
  setSelectedConnectionId: s,
5401
5401
  setSelectedDatabaseName: n,
@@ -5406,7 +5406,7 @@ function ol() {
5406
5406
  he(() => {
5407
5407
  var f;
5408
5408
  if (!t) return;
5409
- const { tableName: c, schemaName: o, databaseName: d, connectionId: u } = un(t), m = (f = t.selectedEntities) == null ? void 0 : f[0], p = (m == null ? void 0 : m.type) === "model" && "id" in m ? m.id : "";
5409
+ const { tableName: c, schemaName: o, databaseName: d, connectionId: u } = pn(t), m = (f = t.selectedEntities) == null ? void 0 : f[0], p = (m == null ? void 0 : m.type) === "model" && "id" in m ? m.id : "";
5410
5410
  s(u || ""), n(d || ""), r(o || ""), l(c || ""), i(p);
5411
5411
  }, [
5412
5412
  t,
@@ -5417,12 +5417,12 @@ function ol() {
5417
5417
  i
5418
5418
  ]);
5419
5419
  }
5420
- function cl({
5420
+ function dl({
5421
5421
  isVisible: t
5422
5422
  // onToggleVisibility,
5423
5423
  }) {
5424
5424
  const s = T((p) => p.isDevMode);
5425
- ol();
5425
+ cl();
5426
5426
  const [n, r] = R(!1), [l, i] = R(!1), [c, o] = R(!0), d = T((p) => p.card.dataSource);
5427
5427
  Vt();
5428
5428
  const { updateDataSource: u } = ee(), m = {
@@ -5488,7 +5488,7 @@ function cl({
5488
5488
  variant: "secondary",
5489
5489
  className: "group relative cursor-pointer pr-6 text-xs transition-colors hover:border-red-200 hover:bg-red-50 dark:hover:border-red-800 dark:hover:bg-red-950",
5490
5490
  children: [
5491
- Qs(p),
5491
+ Ws(p),
5492
5492
  /* @__PURE__ */ e(
5493
5493
  "button",
5494
5494
  {
@@ -5533,9 +5533,9 @@ function cl({
5533
5533
  ]
5534
5534
  }
5535
5535
  ),
5536
- /* @__PURE__ */ e(il, {}),
5536
+ /* @__PURE__ */ e(ol, {}),
5537
5537
  /* @__PURE__ */ e(
5538
- Sr,
5538
+ Tr,
5539
5539
  {
5540
5540
  incomingSelectedEntities: (d == null ? void 0 : d.selectedEntities) || [],
5541
5541
  dialogMode: "dataSource",
@@ -5555,7 +5555,7 @@ function cl({
5555
5555
  }
5556
5556
  );
5557
5557
  }
5558
- function mn({
5558
+ function fn({
5559
5559
  error: t,
5560
5560
  errorSql: s,
5561
5561
  onSendFeedback: n,
@@ -5573,7 +5573,7 @@ function mn({
5573
5573
  l
5574
5574
  ),
5575
5575
  children: /* @__PURE__ */ a("div", { className: "flex items-start gap-3", children: [
5576
- /* @__PURE__ */ e(nr, { className: "mt-0.5 h-5 w-5 flex-shrink-0 text-destructive" }),
5576
+ /* @__PURE__ */ e(ir, { className: "mt-0.5 h-5 w-5 flex-shrink-0 text-destructive" }),
5577
5577
  /* @__PURE__ */ a("div", { className: "flex-1 space-y-3", children: [
5578
5578
  /* @__PURE__ */ a("div", { className: "space-y-2", children: [
5579
5579
  /* @__PURE__ */ e("p", { className: "text-sm font-medium text-destructive", children: c }),
@@ -5590,11 +5590,11 @@ function mn({
5590
5590
  ] }),
5591
5591
  /* @__PURE__ */ a("div", { className: "flex flex-wrap items-center gap-2", children: [
5592
5592
  /* @__PURE__ */ e(
5593
- In,
5593
+ Fn,
5594
5594
  {
5595
5595
  open: o,
5596
5596
  onOpenChange: d,
5597
- children: /* @__PURE__ */ e(fi, { asChild: !0, children: /* @__PURE__ */ e(
5597
+ children: /* @__PURE__ */ e(gi, { asChild: !0, children: /* @__PURE__ */ e(
5598
5598
  q,
5599
5599
  {
5600
5600
  variant: "outline",
@@ -5619,7 +5619,7 @@ function mn({
5619
5619
  className: "h-8",
5620
5620
  onClick: r,
5621
5621
  children: [
5622
- /* @__PURE__ */ e(Zr, { className: "mr-1.5 h-3.5 w-3.5" }),
5622
+ /* @__PURE__ */ e(el, { className: "mr-1.5 h-3.5 w-3.5" }),
5623
5623
  "Open in Editor"
5624
5624
  ]
5625
5625
  }
@@ -5632,25 +5632,25 @@ function mn({
5632
5632
  className: "h-8",
5633
5633
  onClick: n,
5634
5634
  children: [
5635
- /* @__PURE__ */ e(gi, { className: "mr-1.5 h-3.5 w-3.5" }),
5635
+ /* @__PURE__ */ e(xi, { className: "mr-1.5 h-3.5 w-3.5" }),
5636
5636
  "Send Feedback"
5637
5637
  ]
5638
5638
  }
5639
5639
  )
5640
5640
  ] }),
5641
- /* @__PURE__ */ e(In, { open: o, onOpenChange: d, children: /* @__PURE__ */ e(xi, { className: "space-y-2", children: /* @__PURE__ */ a("div", { className: "mt-3 space-y-2", children: [
5641
+ /* @__PURE__ */ e(Fn, { open: o, onOpenChange: d, children: /* @__PURE__ */ e(bi, { className: "space-y-2", children: /* @__PURE__ */ a("div", { className: "mt-3 space-y-2", children: [
5642
5642
  /* @__PURE__ */ a("div", { className: "flex items-center justify-between", children: [
5643
5643
  /* @__PURE__ */ e("p", { className: "text-xs font-medium text-muted-foreground", children: s ? "Error SQL Query" : "SQL Query" }),
5644
5644
  s && /* @__PURE__ */ e(Nt, { text: s, className: "h-6 w-6" })
5645
5645
  ] }),
5646
- s ? /* @__PURE__ */ e("div", { className: "rounded-md bg-background/60 p-2 max-h-80 overflow-auto", children: /* @__PURE__ */ e(kr, { code: s, language: "sql" }) }) : /* @__PURE__ */ e("div", { className: "rounded-md bg-background/60 p-3", children: /* @__PURE__ */ e("p", { className: "text-xs text-muted-foreground italic", children: "SQL query not available for this error" }) })
5646
+ s ? /* @__PURE__ */ e("div", { className: "rounded-md bg-background/60 p-2 max-h-80 overflow-auto", children: /* @__PURE__ */ e(Ar, { code: s, language: "sql" }) }) : /* @__PURE__ */ e("div", { className: "rounded-md bg-background/60 p-3", children: /* @__PURE__ */ e("p", { className: "text-xs text-muted-foreground italic", children: "SQL query not available for this error" }) })
5647
5647
  ] }) }) })
5648
5648
  ] })
5649
5649
  ] })
5650
5650
  }
5651
5651
  );
5652
5652
  }
5653
- function dl({
5653
+ function ul({
5654
5654
  sql: t,
5655
5655
  error: s,
5656
5656
  errorSql: n,
@@ -5674,7 +5674,7 @@ function dl({
5674
5674
  variant: "secondary",
5675
5675
  size: "sm",
5676
5676
  children: [
5677
- /* @__PURE__ */ e(Zr, { className: "mr-2 h-4 w-4" }),
5677
+ /* @__PURE__ */ e(el, { className: "mr-2 h-4 w-4" }),
5678
5678
  "View in SQL Editor"
5679
5679
  ]
5680
5680
  }
@@ -5702,7 +5702,7 @@ function dl({
5702
5702
  size: "sm",
5703
5703
  className: "h-6 w-6 p-0",
5704
5704
  onClick: () => u(!1),
5705
- children: /* @__PURE__ */ e(Xr, { className: "h-4 w-4" })
5705
+ children: /* @__PURE__ */ e(Zr, { className: "h-4 w-4" })
5706
5706
  }
5707
5707
  )
5708
5708
  ] }),
@@ -5739,7 +5739,7 @@ function dl({
5739
5739
  ] }) }),
5740
5740
  /* @__PURE__ */ a("div", { className: "min-h-0 flex-1 overflow-auto text-xs leading-relaxed text-foreground/80", children: [
5741
5741
  s && /* @__PURE__ */ e(
5742
- mn,
5742
+ fn,
5743
5743
  {
5744
5744
  error: s,
5745
5745
  errorSql: n,
@@ -5749,7 +5749,7 @@ function dl({
5749
5749
  ),
5750
5750
  !s && t && /* @__PURE__ */ e("div", { className: "flex flex-col space-y-1.5", children: /* @__PURE__ */ a("div", { className: "relative", children: [
5751
5751
  /* @__PURE__ */ e("div", { className: "absolute right-2 top-2 z-10", children: /* @__PURE__ */ e(Nt, { text: t, className: "h-6 w-6" }) }),
5752
- /* @__PURE__ */ e(kr, { code: t, language: "sql" })
5752
+ /* @__PURE__ */ e(Ar, { code: t, language: "sql" })
5753
5753
  ] }) })
5754
5754
  ] }),
5755
5755
  s && r && /* @__PURE__ */ e("div", { className: "mt-3", children: /* @__PURE__ */ a(
@@ -5772,10 +5772,10 @@ function _d({
5772
5772
  errorSql: n,
5773
5773
  onDebugWithAssistant: r
5774
5774
  }) {
5775
- return /* @__PURE__ */ a(mr, { openDelay: s ? 0 : 500, children: [
5776
- /* @__PURE__ */ e(hr, { asChild: !0, children: /* @__PURE__ */ e(q, { variant: "link", className: "h-5 p-0", children: s ? /* @__PURE__ */ e(Xr, { className: "h-4 w-4 text-red-500" }) : /* @__PURE__ */ e(ia, { className: "h-4 w-4 text-muted-foreground" }) }) }),
5777
- /* @__PURE__ */ e(pr, { align: "start", className: "flex w-[700px]", children: /* @__PURE__ */ e(
5778
- dl,
5775
+ return /* @__PURE__ */ a(fr, { openDelay: s ? 0 : 500, children: [
5776
+ /* @__PURE__ */ e(gr, { asChild: !0, children: /* @__PURE__ */ e(q, { variant: "link", className: "h-5 p-0", children: s ? /* @__PURE__ */ e(Zr, { className: "h-4 w-4 text-red-500" }) : /* @__PURE__ */ e(ia, { className: "h-4 w-4 text-muted-foreground" }) }) }),
5777
+ /* @__PURE__ */ e(xr, { align: "start", className: "flex w-[700px]", children: /* @__PURE__ */ e(
5778
+ ul,
5779
5779
  {
5780
5780
  errorSql: n,
5781
5781
  sql: t,
@@ -5786,12 +5786,12 @@ function _d({
5786
5786
  ] });
5787
5787
  }
5788
5788
  function Jd(t) {
5789
- return bi({ attr: { viewBox: "0 0 448 512" }, child: [{ tag: "path", attr: { d: "M439.8 200.5c-7.7-30.9-22.3-54.2-53.4-54.2h-40.1v47.4c0 36.8-31.2 67.8-66.8 67.8H172.7c-29.2 0-53.4 25-53.4 54.3v101.8c0 29 25.2 46 53.4 54.3 33.8 9.9 66.3 11.7 106.8 0 26.9-7.8 53.4-23.5 53.4-54.3v-40.7H226.2v-13.6h160.2c31.1 0 42.6-21.7 53.4-54.2 11.2-33.5 10.7-65.7 0-108.6zM286.2 404c11.1 0 20.1 9.1 20.1 20.3 0 11.3-9 20.4-20.1 20.4-11 0-20.1-9.2-20.1-20.4.1-11.3 9.1-20.3 20.1-20.3zM167.8 248.1h106.8c29.7 0 53.4-24.5 53.4-54.3V91.9c0-29-24.4-50.7-53.4-55.6-35.8-5.9-74.7-5.6-106.8.1-45.2 8-53.4 24.7-53.4 55.6v40.7h106.9v13.6h-147c-31.1 0-58.3 18.7-66.8 54.2-9.8 40.7-10.2 66.1 0 108.6 7.6 31.6 25.7 54.2 56.8 54.2H101v-48.8c0-35.3 30.5-66.4 66.8-66.4zm-6.7-142.6c-11.1 0-20.1-9.1-20.1-20.3.1-11.3 9-20.4 20.1-20.4 11 0 20.1 9.2 20.1 20.4s-9 20.3-20.1 20.3z" }, child: [] }] })(t);
5789
+ return vi({ attr: { viewBox: "0 0 448 512" }, child: [{ tag: "path", attr: { d: "M439.8 200.5c-7.7-30.9-22.3-54.2-53.4-54.2h-40.1v47.4c0 36.8-31.2 67.8-66.8 67.8H172.7c-29.2 0-53.4 25-53.4 54.3v101.8c0 29 25.2 46 53.4 54.3 33.8 9.9 66.3 11.7 106.8 0 26.9-7.8 53.4-23.5 53.4-54.3v-40.7H226.2v-13.6h160.2c31.1 0 42.6-21.7 53.4-54.2 11.2-33.5 10.7-65.7 0-108.6zM286.2 404c11.1 0 20.1 9.1 20.1 20.3 0 11.3-9 20.4-20.1 20.4-11 0-20.1-9.2-20.1-20.4.1-11.3 9.1-20.3 20.1-20.3zM167.8 248.1h106.8c29.7 0 53.4-24.5 53.4-54.3V91.9c0-29-24.4-50.7-53.4-55.6-35.8-5.9-74.7-5.6-106.8.1-45.2 8-53.4 24.7-53.4 55.6v40.7h106.9v13.6h-147c-31.1 0-58.3 18.7-66.8 54.2-9.8 40.7-10.2 66.1 0 108.6 7.6 31.6 25.7 54.2 56.8 54.2H101v-48.8c0-35.3 30.5-66.4 66.8-66.4zm-6.7-142.6c-11.1 0-20.1-9.1-20.1-20.3.1-11.3 9-20.4 20.1-20.4 11 0 20.1 9.2 20.1 20.4s-9 20.3-20.1 20.3z" }, child: [] }] })(t);
5790
5790
  }
5791
- function ul(t) {
5792
- const { theme: s } = Bs(), n = J((b) => b.theme), r = T((b) => b.frame), l = T((b) => b.card), i = T((b) => b.activeTabCardId), c = vi(), { refetch: o } = Me(l), { updateCardTab: d, setRunSql: u } = ee(), m = dt(), h = dt({}), p = r.cards.find((b) => b.id === i), f = ye(() => {
5791
+ function ml(t) {
5792
+ const { theme: s } = js(), n = J((b) => b.theme), r = T((b) => b.frame), l = T((b) => b.card), i = T((b) => b.activeTabCardId), c = yi(), { refetch: o } = Me(l), { updateCardTab: d, setRunSql: u } = ee(), m = dt(), h = dt({}), p = r.cards.find((b) => b.id === i), f = ye(() => {
5793
5793
  let b = "";
5794
- return t === "python" && (b = (p == null ? void 0 : p.python) || Dr), t === "sql" && (b = (p == null ? void 0 : p.sql) || ""), b;
5794
+ return t === "python" && (b = (p == null ? void 0 : p.python) || Ir), t === "sql" && (b = (p == null ? void 0 : p.sql) || ""), b;
5795
5795
  }, [t, p]);
5796
5796
  he(() => {
5797
5797
  if (i && l.id && l.id !== i) {
@@ -5824,7 +5824,7 @@ function ul(t) {
5824
5824
  inherit: !0,
5825
5825
  rules: [],
5826
5826
  colors: {
5827
- "editor.background": y === "light" ? "#ffffff" : yi("240 10% 10%")
5827
+ "editor.background": y === "light" ? "#ffffff" : Ni("240 10% 10%")
5828
5828
  // 'editor.background':
5829
5829
  // activeTheme === 'light'
5830
5830
  // ? '#ffffff'
@@ -5850,9 +5850,9 @@ function ul(t) {
5850
5850
  return { handleEditorDidMount: v };
5851
5851
  }
5852
5852
  function Hd() {
5853
- const t = T((c) => c.card.sql), s = T((c) => c.sqlGen), { setCardSql: n, setSqlGen: r } = ee(), { handleEditorDidMount: l } = ul("sql");
5853
+ const t = T((c) => c.card.sql), s = T((c) => c.sqlGen), { setCardSql: n, setSqlGen: r } = ee(), { handleEditorDidMount: l } = ml("sql");
5854
5854
  function i(c) {
5855
- n(c), Ni(s) || r({});
5855
+ n(c), Ci(s) || r({});
5856
5856
  }
5857
5857
  return /* @__PURE__ */ a("div", { className: "relative h-full w-full", children: [
5858
5858
  !t && /* @__PURE__ */ e("div", { className: "pointer-events-none absolute left-[65px] top-3 z-10 font-mono text-sm text-muted-foreground", children: "Write your SQL here" }),
@@ -5882,7 +5882,7 @@ function Hd() {
5882
5882
  ] });
5883
5883
  }
5884
5884
  function Qd() {
5885
- const t = T((l) => l.card.python), { setCardPython: s } = ee(), { handleEditorDidMount: n } = ul("python");
5885
+ const t = T((l) => l.card.python), { setCardPython: s } = ee(), { handleEditorDidMount: n } = ml("python");
5886
5886
  function r(l) {
5887
5887
  s(l);
5888
5888
  }
@@ -5892,7 +5892,7 @@ function Qd() {
5892
5892
  className: "pt-3",
5893
5893
  theme: "default",
5894
5894
  onChange: r,
5895
- value: t || Dr,
5895
+ value: t || Ir,
5896
5896
  options: {
5897
5897
  minimap: {
5898
5898
  enabled: !1
@@ -5937,7 +5937,7 @@ function Wd({ jsonString: t }) {
5937
5937
  );
5938
5938
  }
5939
5939
  function Yd() {
5940
- const t = vt(), { isConsoleMode: s } = Us(), [n, r] = R(!1), [l, i] = R(!1);
5940
+ const t = vt(), { isConsoleMode: s } = Ks(), [n, r] = R(!1), [l, i] = R(!1);
5941
5941
  T(($) => $.frame);
5942
5942
  const c = T(($) => $.card);
5943
5943
  T(($) => $.isShowingVisual), T(
@@ -5957,7 +5957,7 @@ function Yd() {
5957
5957
  }), u = T(($) => {
5958
5958
  var X;
5959
5959
  return (X = $ == null ? void 0 : $.card) == null ? void 0 : X.python;
5960
- }), { cardFilterValues: m } = Ci(
5960
+ }), { cardFilterValues: m } = wi(
5961
5961
  (c == null ? void 0 : c.id) ?? ""
5962
5962
  ), {
5963
5963
  setCardCustomCfg: h,
@@ -6130,7 +6130,7 @@ ${u}` : ""}
6130
6130
  className: "h-8 shrink-0",
6131
6131
  size: "sm",
6132
6132
  children: [
6133
- C || M ? /* @__PURE__ */ e(Be, { className: "mr-2 h-4 w-4 animate-spin" }) : /* @__PURE__ */ e(wi, { className: "mr-2 h-4 w-4" }),
6133
+ C || M ? /* @__PURE__ */ e(Be, { className: "mr-2 h-4 w-4 animate-spin" }) : /* @__PURE__ */ e(Si, { className: "mr-2 h-4 w-4" }),
6134
6134
  "Run"
6135
6135
  ]
6136
6136
  }
@@ -6144,9 +6144,9 @@ ${u}` : ""}
6144
6144
  onDebugWithAssistant: K
6145
6145
  }
6146
6146
  ),
6147
- /* @__PURE__ */ e(on, {}),
6147
+ /* @__PURE__ */ e(un, {}),
6148
6148
  /* @__PURE__ */ a(
6149
- Si,
6149
+ ki,
6150
6150
  {
6151
6151
  pressed: n,
6152
6152
  onPressedChange: ($) => r($),
@@ -6168,7 +6168,7 @@ ${u}` : ""}
6168
6168
  },
6169
6169
  className: "flex h-9 w-full cursor-text items-center justify-start px-3 text-left text-sm text-muted-foreground",
6170
6170
  children: [
6171
- /* @__PURE__ */ e(Hs, { className: "mr-3 size-4 text-foreground/70" }),
6171
+ /* @__PURE__ */ e(Qs, { className: "mr-3 size-4 text-foreground/70" }),
6172
6172
  "Type your question..."
6173
6173
  ]
6174
6174
  }
@@ -6197,7 +6197,7 @@ ${u}` : ""}
6197
6197
  }
6198
6198
  const Xd = [
6199
6199
  { value: "table", label: "Table", icon: ns },
6200
- { value: "aggregateTable", label: "Aggregate", icon: gr },
6200
+ { value: "aggregateTable", label: "Aggregate", icon: vr },
6201
6201
  { value: "pivotTable", label: "Pivot", icon: ps }
6202
6202
  ];
6203
6203
  function Zd({ className: t }) {
@@ -6226,7 +6226,7 @@ function Zd({ className: t }) {
6226
6226
  }
6227
6227
  };
6228
6228
  return /* @__PURE__ */ e("div", { className: Y("flex items-center", t), children: /* @__PURE__ */ e(
6229
- Ws,
6229
+ Ys,
6230
6230
  {
6231
6231
  value: s.type,
6232
6232
  onValueChange: o,
@@ -6265,12 +6265,12 @@ function eu({ card: t }) {
6265
6265
  var V, O, I, w, g, x, C, M, S, L, E;
6266
6266
  const [s, n] = R(!1), [r, l] = R(
6267
6267
  []
6268
- ), { authToken: i } = je(), { theme: c } = Bs(), o = ki(i == null ? void 0 : i.accessToken), d = J((D) => D.themeStyle), u = {
6268
+ ), { authToken: i } = je(), { theme: c } = js(), o = Di(i == null ? void 0 : i.accessToken), d = J((D) => D.themeStyle), u = {
6269
6269
  mode: c || "system",
6270
6270
  colors: ((O = (V = d == null ? void 0 : d.chart) == null ? void 0 : V.dataset) == null ? void 0 : O.backgroundColor) || []
6271
6271
  };
6272
6272
  (I = t.customCardPreferences) != null && I.inputData;
6273
- const { getCard: m } = Ys(((w = t.customCardPreferences) == null ? void 0 : w.url) || ""), h = ((g = t.customCardPreferences) == null ? void 0 : g.visualType) || "single", p = T((D) => D.frame), { setCustomCardPreferences: f } = ee(), { data: v } = Me(t), b = ye((D, N) => {
6273
+ const { getCard: m } = Xs(((w = t.customCardPreferences) == null ? void 0 : w.url) || ""), h = ((g = t.customCardPreferences) == null ? void 0 : g.visualType) || "single", p = T((D) => D.frame), { setCustomCardPreferences: f } = ee(), { data: v } = Me(t), b = ye((D, N) => {
6274
6274
  l((F) => ({
6275
6275
  ...F,
6276
6276
  [D]: N
@@ -6292,7 +6292,7 @@ function eu({ card: t }) {
6292
6292
  return F || null;
6293
6293
  });
6294
6294
  return /* @__PURE__ */ e("div", { className: "semaphor-custom mb-3 flex grow basis-0 flex-col space-y-2 overflow-y-auto", children: /* @__PURE__ */ a(
6295
- Yr,
6295
+ Xr,
6296
6296
  {
6297
6297
  fallback: /* @__PURE__ */ e(Z, {}),
6298
6298
  children: [
@@ -6317,7 +6317,7 @@ function eu({ card: t }) {
6317
6317
  );
6318
6318
  if (F)
6319
6319
  return /* @__PURE__ */ e(
6320
- Di,
6320
+ Ti,
6321
6321
  {
6322
6322
  onLoadingStatus: k,
6323
6323
  onDataChange: b,
@@ -6401,21 +6401,21 @@ function tu({ type: t, isLinked: s, className: n }) {
6401
6401
  side: "bottom",
6402
6402
  className: Y("max-w-xs", u[c]),
6403
6403
  children: [
6404
- /* @__PURE__ */ e(Ti, { className: m[c] }),
6404
+ /* @__PURE__ */ e(Is, { className: m[c] }),
6405
6405
  /* @__PURE__ */ e("p", { children: d[c] })
6406
6406
  ]
6407
6407
  }
6408
6408
  )
6409
6409
  ] }) });
6410
6410
  }
6411
- function ml({
6411
+ function hl({
6412
6412
  // card,
6413
6413
  // showCard,
6414
6414
  className: t,
6415
6415
  ...s
6416
6416
  }) {
6417
6417
  var K;
6418
- const n = T((B) => B.card), r = ((K = n.customCardPreferences) == null ? void 0 : K.showCardHeader) ?? !0, l = T((B) => B.frame), i = J((B) => B.dashboard.filters), [c, o] = R(!1), { currentUser: d } = Vt(), { tokenProps: u } = hs(Ya), m = T((B) => B.actions.setRunSql), { updateFilter: h } = et(), p = i == null ? void 0 : i.find((B) => B.id === l.filterId), { data: f, isLoading: v, isFetching: b, errorMessage: y, errorSql: k, pagination: A } = Me(n), { setCard: V, updateCardInFrame: O, setIsDevMode: I, setCardSql: w } = ee(), { data: g } = Xs(n), x = qe(() => {
6418
+ const n = T((B) => B.card), r = ((K = n.customCardPreferences) == null ? void 0 : K.showCardHeader) ?? !0, l = T((B) => B.frame), i = J((B) => B.dashboard.filters), [c, o] = R(!1), { currentUser: d } = Vt(), { tokenProps: u } = hs(Ya), m = T((B) => B.actions.setRunSql), { updateFilter: h } = et(), p = i == null ? void 0 : i.find((B) => B.id === l.filterId), { data: f, isLoading: v, isFetching: b, errorMessage: y, errorSql: k, pagination: A } = Me(n), { setCard: V, updateCardInFrame: O, setIsDevMode: I, setCardSql: w } = ee(), { data: g } = Zs(n), x = qe(() => {
6419
6419
  var B;
6420
6420
  return n.type !== "pivotTable" || !((B = f == null ? void 0 : f.records) != null && B.length) ? null : {
6421
6421
  records: f.records,
@@ -6440,7 +6440,7 @@ function ml({
6440
6440
  }, L = qe(() => {
6441
6441
  const B = typeof window < "u" ? window.location.href : "", z = typeof navigator < "u" ? navigator.userAgent : "", U = typeof window < "u" ? `${window.innerWidth}x${window.innerHeight}` : "";
6442
6442
  return {
6443
- category: Tr.QUERY_GENERATION,
6443
+ category: Er.QUERY_GENERATION,
6444
6444
  user: d,
6445
6445
  tokenContext: u,
6446
6446
  systemState: {
@@ -6471,7 +6471,7 @@ function ml({
6471
6471
  V(U), O(U), n.sql && ((X = ($ = n.preferences) == null ? void 0 : $.tablePrefs) != null && X.enableDevModePagination) && m(!0);
6472
6472
  }, D = (B) => {
6473
6473
  var $, X, de, be;
6474
- const z = Mr(
6474
+ const z = Pr(
6475
6475
  B,
6476
6476
  ($ = n.config) == null ? void 0 : $.metricColumns,
6477
6477
  (X = n.config) == null ? void 0 : X.groupByColumns
@@ -6483,7 +6483,7 @@ function ml({
6483
6483
  }
6484
6484
  };
6485
6485
  V(U), O(U), n.sql && ((be = (de = n.preferences) == null ? void 0 : de.tablePrefs) != null && be.enableDevModePagination) && m(!0);
6486
- }, N = qe(() => !n.id || !(f != null && f.records) ? null : Ar({
6486
+ }, N = qe(() => !n.id || !(f != null && f.records) ? null : Mr({
6487
6487
  card: n,
6488
6488
  data: f == null ? void 0 : f.records,
6489
6489
  cardType: n.type,
@@ -6501,12 +6501,12 @@ function ml({
6501
6501
  g
6502
6502
  ]);
6503
6503
  function F(B) {
6504
- return /* @__PURE__ */ e(Na, { FallbackComponent: Zs, children: /* @__PURE__ */ e(eu, { card: B }) });
6504
+ return /* @__PURE__ */ e(Na, { FallbackComponent: en, children: /* @__PURE__ */ e(eu, { card: B }) });
6505
6505
  }
6506
6506
  function P() {
6507
6507
  if (f != null && f.records && (f == null ? void 0 : f.records.length) === 0 && !v && !b)
6508
6508
  return y ? /* @__PURE__ */ e("div", { className: "flex h-full flex-col items-start justify-start overflow-auto p-4", children: /* @__PURE__ */ e(
6509
- mn,
6509
+ fn,
6510
6510
  {
6511
6511
  error: y,
6512
6512
  errorSql: k || n.sql || n.python,
@@ -6553,7 +6553,7 @@ function ml({
6553
6553
  data: C.data,
6554
6554
  options: C.options,
6555
6555
  onAggregationChange: (B) => {
6556
- const z = En(
6556
+ const z = On(
6557
6557
  B,
6558
6558
  n.config
6559
6559
  ), U = { ...n, config: z };
@@ -6579,7 +6579,7 @@ function ml({
6579
6579
  paginationMetadata: A,
6580
6580
  onPaginationChange: E,
6581
6581
  onAggregationChange: (B) => {
6582
- const z = En(
6582
+ const z = On(
6583
6583
  B,
6584
6584
  n.config
6585
6585
  ), U = { ...n, config: z };
@@ -6596,10 +6596,10 @@ function ml({
6596
6596
  className: Y("relative flex h-full flex-col rounded-none", t),
6597
6597
  ...s,
6598
6598
  children: [
6599
- r && /* @__PURE__ */ a(vr, { className: "flex flex-row items-start justify-between py-4", children: [
6599
+ r && /* @__PURE__ */ a(Cr, { className: "flex flex-row items-start justify-between py-4", children: [
6600
6600
  /* @__PURE__ */ a("div", { className: "flex-1", children: [
6601
6601
  /* @__PURE__ */ a("div", { className: "flex items-center gap-2", children: [
6602
- /* @__PURE__ */ e(yr, { className: "text-base", children: /* @__PURE__ */ e(
6602
+ /* @__PURE__ */ e(wr, { className: "text-base", children: /* @__PURE__ */ e(
6603
6603
  Ia,
6604
6604
  {
6605
6605
  value: n.title,
@@ -6637,12 +6637,12 @@ function ml({
6637
6637
  inputClassName: "text-sm"
6638
6638
  }
6639
6639
  ) }),
6640
- /* @__PURE__ */ e(Ir, { filter: p })
6640
+ /* @__PURE__ */ e(Fr, { filter: p })
6641
6641
  ] })
6642
6642
  ] }),
6643
6643
  /* @__PURE__ */ e(as, { className: "flex grow flex-col", children: P() }),
6644
6644
  /* @__PURE__ */ e(
6645
- Er,
6645
+ Or,
6646
6646
  {
6647
6647
  open: c,
6648
6648
  onOpenChange: o,
@@ -6767,7 +6767,7 @@ const Cs = ({
6767
6767
  /* @__PURE__ */ e(q, { onClick: l, variant: "outline", children: "Close" })
6768
6768
  ] });
6769
6769
  function ru() {
6770
- const [t, s] = R(!1), [n, r] = R(""), [l, i] = R(""), [c, o] = R(""), [d, u] = R(""), m = T((I) => I.card), h = T((I) => I.card.customCfg), p = h ? JSON.stringify(h, null, 2) : "", { data: f } = Me(m), { data: v } = Xs(m), { setCardCustomCfg: b, setCustomVisualCode: y } = ee(), k = (I) => {
6770
+ const [t, s] = R(!1), [n, r] = R(""), [l, i] = R(""), [c, o] = R(""), [d, u] = R(""), m = T((I) => I.card), h = T((I) => I.card.customCfg), p = h ? JSON.stringify(h, null, 2) : "", { data: f } = Me(m), { data: v } = Zs(m), { setCardCustomCfg: b, setCustomVisualCode: y } = ee(), k = (I) => {
6771
6771
  var w, g;
6772
6772
  return JSON.stringify(
6773
6773
  {
@@ -6786,7 +6786,7 @@ function ru() {
6786
6786
  }, A = () => {
6787
6787
  var w, g;
6788
6788
  if (!((w = f == null ? void 0 : f.records) != null && w.length)) return;
6789
- const I = Ar({
6789
+ const I = Mr({
6790
6790
  card: m,
6791
6791
  data: f.records,
6792
6792
  cardType: m.type,
@@ -6816,7 +6816,7 @@ function ru() {
6816
6816
  }
6817
6817
  }, O = Object.keys(h || {}).length === 0;
6818
6818
  return /* @__PURE__ */ a(rt, { open: t, onOpenChange: s, children: [
6819
- /* @__PURE__ */ e(er, { asChild: !0, children: /* @__PURE__ */ e(
6819
+ /* @__PURE__ */ e(sr, { asChild: !0, children: /* @__PURE__ */ e(
6820
6820
  ke,
6821
6821
  {
6822
6822
  tooltip: "Customize Visual",
@@ -6828,7 +6828,7 @@ function ru() {
6828
6828
  /* @__PURE__ */ a(lt, { className: "flex h-[600px] grow flex-col overflow-auto sm:min-w-[900px] lg:min-w-[1200px]", children: [
6829
6829
  /* @__PURE__ */ e(au, {}),
6830
6830
  /* @__PURE__ */ a("div", { className: "flex grow gap-2", children: [
6831
- /* @__PURE__ */ e(Na, { FallbackComponent: Zs, children: /* @__PURE__ */ e(ml, { className: "w-1/2 rounded shadow-none" }) }),
6831
+ /* @__PURE__ */ e(Na, { FallbackComponent: en, children: /* @__PURE__ */ e(hl, { className: "w-1/2 rounded shadow-none" }) }),
6832
6832
  /* @__PURE__ */ e(
6833
6833
  su,
6834
6834
  {
@@ -6859,7 +6859,7 @@ function fs(t) {
6859
6859
  const [s, n] = R(null);
6860
6860
  return s;
6861
6861
  }
6862
- function hl() {
6862
+ function pl() {
6863
6863
  const { authToken: t, tokenProps: s } = je(), { data: n, isLoading: r, isFetching: l, isError: i } = Xa({
6864
6864
  queryKey: ["plugins", t == null ? void 0 : t.accessToken],
6865
6865
  queryFn: () => Ri(s.apiServiceUrl, t == null ? void 0 : t.accessToken)
@@ -6867,12 +6867,12 @@ function hl() {
6867
6867
  });
6868
6868
  return { data: n, isLoading: r, isFetching: l, isError: i };
6869
6869
  }
6870
- function pl() {
6870
+ function fl() {
6871
6871
  const {
6872
6872
  data: t,
6873
6873
  isLoading: s,
6874
6874
  isError: n
6875
- } = hl(), r = zi({
6875
+ } = pl(), r = zi({
6876
6876
  queries: ((t == null ? void 0 : t.plugins) || []).map((o) => ({
6877
6877
  queryKey: ["manifest", o.value],
6878
6878
  queryFn: () => Bi(o.value),
@@ -6914,7 +6914,7 @@ function lu({
6914
6914
  setCardPreferences: n,
6915
6915
  setCardType: r,
6916
6916
  setCustomCardPreferences: l
6917
- } = ee(), { data: i, isLoading: c, isError: o } = pl(), d = ye(
6917
+ } = ee(), { data: i, isLoading: c, isError: o } = fl(), d = ye(
6918
6918
  (u, m) => {
6919
6919
  s(null), n({}), r(u), m && l({
6920
6920
  type: "component",
@@ -6992,22 +6992,22 @@ function ou({
6992
6992
  { type: "table", name: "Table", icon: ns },
6993
6993
  { type: "bar", name: "Bar Chart", icon: os },
6994
6994
  { type: "line", name: "Line Chart", icon: is },
6995
- { type: "stackedBar", name: "Stacked Bar", icon: tn },
6996
- { type: "stackedLine", name: "Stacked Line", icon: Is },
6997
- { type: "scatter", name: "Scatter", icon: zr },
6998
- { type: "bubble", name: "Bubble", icon: Rr },
6999
- { type: "pie", name: "Pie Chart", icon: sn },
7000
- { type: "doughnut", name: "Doughnut", icon: an },
7001
- { type: "funnel", name: "Funnel", icon: Lr },
7002
- { type: "radar", name: "Radar", icon: Br },
7003
- { type: "polarArea", name: "Polar Area", icon: Vr },
7004
- { type: "tornado", name: "Tornado", icon: Pr },
7005
- { type: "range", name: "Range", icon: Or },
6995
+ { type: "stackedBar", name: "Stacked Bar", icon: nn },
6996
+ { type: "stackedLine", name: "Stacked Line", icon: Es },
6997
+ { type: "scatter", name: "Scatter", icon: Br },
6998
+ { type: "bubble", name: "Bubble", icon: zr },
6999
+ { type: "pie", name: "Pie Chart", icon: ln },
7000
+ { type: "doughnut", name: "Doughnut", icon: rn },
7001
+ { type: "funnel", name: "Funnel", icon: sn },
7002
+ { type: "radar", name: "Radar", icon: jr },
7003
+ { type: "polarArea", name: "Polar Area", icon: Rr },
7004
+ { type: "tornado", name: "Tornado", icon: an },
7005
+ { type: "range", name: "Range", icon: Vr },
7006
7006
  { type: "bullet", name: "Bullet Chart", icon: Ca },
7007
7007
  { type: "treemap", name: "Treemap", icon: ls },
7008
- { type: "kpi", name: "KPI", icon: en },
7008
+ { type: "kpi", name: "KPI", icon: tn },
7009
7009
  { type: "text", name: "Text", icon: $i },
7010
- { type: "map", name: "Map", icon: Fr },
7010
+ { type: "map", name: "Map", icon: Lr },
7011
7011
  { type: "custom", name: "Custom", icon: la }
7012
7012
  ].filter(
7013
7013
  (p) => p.name.toLowerCase().includes(n.toLowerCase())
@@ -7020,7 +7020,7 @@ function ou({
7020
7020
  onClick: () => u(p.type),
7021
7021
  className: "flex flex-col items-center gap-2 rounded-lg border border-border bg-background p-3 transition-all hover:border-primary/50 hover:bg-muted/50 hover:shadow-sm",
7022
7022
  children: [
7023
- /* @__PURE__ */ e(f, { className: Y("h-6 w-6", s), strokeWidth: p.icon === Is ? 0 : void 0 }),
7023
+ /* @__PURE__ */ e(f, { className: Y("h-6 w-6", s), strokeWidth: p.icon === Es ? 0 : void 0 }),
7024
7024
  /* @__PURE__ */ e("span", { className: "text-xs font-medium text-foreground", children: p.name })
7025
7025
  ]
7026
7026
  },
@@ -7041,45 +7041,45 @@ function cu({
7041
7041
  case "line":
7042
7042
  return /* @__PURE__ */ e(is, { className: s });
7043
7043
  case "pie":
7044
- return /* @__PURE__ */ e(sn, { className: s });
7044
+ return /* @__PURE__ */ e(ln, { className: s });
7045
7045
  case "radar":
7046
- return /* @__PURE__ */ e(Br, { className: s });
7046
+ return /* @__PURE__ */ e(jr, { className: s });
7047
7047
  case "scatter":
7048
- return /* @__PURE__ */ e(zr, { className: s });
7048
+ return /* @__PURE__ */ e(Br, { className: s });
7049
7049
  case "bubble":
7050
- return /* @__PURE__ */ e(Rr, { className: s });
7050
+ return /* @__PURE__ */ e(zr, { className: s });
7051
7051
  case "doughnut":
7052
- return /* @__PURE__ */ e(an, { className: s });
7052
+ return /* @__PURE__ */ e(rn, { className: s });
7053
7053
  case "stackedBar":
7054
- return /* @__PURE__ */ e(tn, { className: s });
7054
+ return /* @__PURE__ */ e(nn, { className: s });
7055
7055
  case "stackedLine":
7056
- return /* @__PURE__ */ e(Is, { className: s });
7056
+ return /* @__PURE__ */ e(Es, { className: s });
7057
7057
  case "polarArea":
7058
- return /* @__PURE__ */ e(Vr, { className: s });
7058
+ return /* @__PURE__ */ e(Rr, { className: s });
7059
7059
  case "treemap":
7060
7060
  return /* @__PURE__ */ e(ls, { className: s });
7061
7061
  case "bullet":
7062
7062
  return /* @__PURE__ */ e(Ca, { className: s });
7063
7063
  case "funnel":
7064
- return /* @__PURE__ */ e(Lr, { className: s });
7064
+ return /* @__PURE__ */ e(sn, { className: s });
7065
7065
  case "tornado":
7066
7066
  case "pyramid":
7067
- return /* @__PURE__ */ e(Pr, { className: s });
7067
+ return /* @__PURE__ */ e(an, { className: s });
7068
7068
  case "range":
7069
- return /* @__PURE__ */ e(Or, { className: s });
7069
+ return /* @__PURE__ */ e(Vr, { className: s });
7070
7070
  case "kpi":
7071
- return /* @__PURE__ */ e(en, { className: s });
7071
+ return /* @__PURE__ */ e(tn, { className: s });
7072
7072
  case "text":
7073
7073
  return /* @__PURE__ */ e(ji, { className: s });
7074
7074
  case "map":
7075
- return /* @__PURE__ */ e(Fr, { className: s });
7075
+ return /* @__PURE__ */ e(Lr, { className: s });
7076
7076
  case "custom":
7077
7077
  return n && l ? /* @__PURE__ */ e(l, { className: s }) : r ? r == null ? void 0 : r.charAt(0).toUpperCase() : /* @__PURE__ */ e(la, { className: s });
7078
7078
  default:
7079
7079
  return /* @__PURE__ */ e(ns, { className: s });
7080
7080
  }
7081
7081
  }
7082
- function fl({
7082
+ function gl({
7083
7083
  variant: t = "ghost"
7084
7084
  }) {
7085
7085
  var o, d;
@@ -7269,11 +7269,11 @@ function mu({
7269
7269
  {
7270
7270
  className: "h-8 w-8 p-0",
7271
7271
  tooltip: "Display Options",
7272
- children: /* @__PURE__ */ e(el, { className: "h-4 w-4" })
7272
+ children: /* @__PURE__ */ e(tl, { className: "h-4 w-4" })
7273
7273
  }
7274
7274
  ) }),
7275
7275
  /* @__PURE__ */ a(Et, { align: "end", className: "w-64", children: [
7276
- /* @__PURE__ */ e($s, { children: "Display Options" }),
7276
+ /* @__PURE__ */ e(qs, { children: "Display Options" }),
7277
7277
  /* @__PURE__ */ e(ma, {}),
7278
7278
  /* @__PURE__ */ e("div", { className: "px-2 py-1.5", children: /* @__PURE__ */ e("p", { className: "mb-2 text-xs text-muted-foreground", children: "Changes apply to dashboard view only" }) }),
7279
7279
  /* @__PURE__ */ a(
@@ -7339,7 +7339,7 @@ function mu({
7339
7339
  ] })
7340
7340
  ] }) });
7341
7341
  }
7342
- function gl() {
7342
+ function xl() {
7343
7343
  const t = T((i) => i.card), s = T(
7344
7344
  (i) => {
7345
7345
  var c, o;
@@ -7458,7 +7458,7 @@ function hu() {
7458
7458
  displayTab: y
7459
7459
  });
7460
7460
  },
7461
- children: b.displayTab === !0 || b.displayTab === void 0 ? /* @__PURE__ */ e(Gs, { className: "mr-2 size-3.5 text-muted-foreground hover:text-foreground" }) : /* @__PURE__ */ e(kc, { className: "mr-2 size-3.5 text-muted-foreground hover:text-foreground" })
7461
+ children: b.displayTab === !0 || b.displayTab === void 0 ? /* @__PURE__ */ e(Us, { className: "mr-2 size-3.5 text-muted-foreground hover:text-foreground" }) : /* @__PURE__ */ e(kc, { className: "mr-2 size-3.5 text-muted-foreground hover:text-foreground" })
7462
7462
  }
7463
7463
  );
7464
7464
  }
@@ -7517,7 +7517,7 @@ function hu() {
7517
7517
  )
7518
7518
  ] }) });
7519
7519
  }
7520
- function zs() {
7520
+ function Bs() {
7521
7521
  const t = T((y) => y.frame), s = T((y) => y.card), n = T((y) => y.isSqlRunning), r = T((y) => y.isDevMode), { setFrame: l, setActiveTabCardId: i, setCard: c, setIsDevMode: o, setRunSql: d } = ee(), { data: u, isLoading: m, isFetching: h, isError: p } = Me(s);
7522
7522
  function f(y) {
7523
7523
  const k = t.cards.find((A) => A.id === y);
@@ -7557,7 +7557,7 @@ function zs() {
7557
7557
  card: s,
7558
7558
  data: u == null ? void 0 : u.records
7559
7559
  }
7560
- ) }) }) }) : /* @__PURE__ */ e(Na, { FallbackComponent: Zs, children: /* @__PURE__ */ e(ml, { className: "grow border-none shadow-none" }) });
7560
+ ) }) }) }) : /* @__PURE__ */ e(Na, { FallbackComponent: en, children: /* @__PURE__ */ e(hl, { className: "grow border-none shadow-none" }) });
7561
7561
  }
7562
7562
  return /* @__PURE__ */ a(
7563
7563
  Pt,
@@ -7572,7 +7572,7 @@ function zs() {
7572
7572
  }
7573
7573
  );
7574
7574
  }
7575
- function $n({
7575
+ function Un({
7576
7576
  children: t
7577
7577
  }) {
7578
7578
  var w, g;
@@ -7619,7 +7619,7 @@ function $n({
7619
7619
  className: "z-10 mb-0 flex min-h-10 items-center justify-end gap-2 px-6",
7620
7620
  children: [
7621
7621
  r && /* @__PURE__ */ a("div", { className: "flex grow items-center", children: [
7622
- /* @__PURE__ */ e(fl, {}),
7622
+ /* @__PURE__ */ e(gl, {}),
7623
7623
  l && /* @__PURE__ */ e(ke, { tooltip: "Visual Docs", onClick: I, children: /* @__PURE__ */ e(bc, { className: "size-4" }) }),
7624
7624
  !["table", "custom"].includes(s.type) && l && /* @__PURE__ */ e(ru, {})
7625
7625
  ] }),
@@ -7663,7 +7663,7 @@ function $n({
7663
7663
  A(!0), y();
7664
7664
  },
7665
7665
  children: /* @__PURE__ */ e(
7666
- jr,
7666
+ $r,
7667
7667
  {
7668
7668
  className: Y("h-4 w-4", {
7669
7669
  "animate-spin": k
@@ -7672,7 +7672,7 @@ function $n({
7672
7672
  )
7673
7673
  }
7674
7674
  ),
7675
- /* @__PURE__ */ e(gl, {})
7675
+ /* @__PURE__ */ e(xl, {})
7676
7676
  ] }),
7677
7677
  s.type === "table" && s.sql && n && /* @__PURE__ */ a("div", { className: "mr-2 flex items-center gap-3", children: [
7678
7678
  /* @__PURE__ */ e(
@@ -7698,7 +7698,7 @@ function $n({
7698
7698
  ]
7699
7699
  }
7700
7700
  ),
7701
- r ? /* @__PURE__ */ e(zs, {}) : /* @__PURE__ */ a(
7701
+ r ? /* @__PURE__ */ e(Bs, {}) : /* @__PURE__ */ a(
7702
7702
  Ft,
7703
7703
  {
7704
7704
  className: "px-6",
@@ -7812,7 +7812,7 @@ function gu() {
7812
7812
  var b, y;
7813
7813
  const t = T(
7814
7814
  (k) => k.card.customCardPreferences
7815
- ), { data: s } = hl(), n = (s == null ? void 0 : s.plugins) || [], r = T((k) => k.card), l = T((k) => k.frame), i = (t == null ? void 0 : t.visualType) || "single", { setCustomCardPreferences: c } = ee(), { components: o, manifest: d } = Ys(
7815
+ ), { data: s } = pl(), n = (s == null ? void 0 : s.plugins) || [], r = T((k) => k.card), l = T((k) => k.frame), i = (t == null ? void 0 : t.visualType) || "single", { setCustomCardPreferences: c } = ee(), { components: o, manifest: d } = Xs(
7816
7816
  (t == null ? void 0 : t.url) || ""
7817
7817
  ), u = (b = d == null ? void 0 : d.visuals) == null ? void 0 : b.find(
7818
7818
  (k) => k.name === (t == null ? void 0 : t.componentName)
@@ -8087,7 +8087,7 @@ function Xt() {
8087
8087
  /* @__PURE__ */ e("div", { className: "flex items-center gap-2", children: ((p = n == null ? void 0 : n.onClickFilter) == null ? void 0 : p.find(
8088
8088
  (f) => f.columnIndex === m
8089
8089
  )) && /* @__PURE__ */ e(
8090
- cr,
8090
+ mr,
8091
8091
  {
8092
8092
  onClick: () => {
8093
8093
  s((f) => {
@@ -8151,7 +8151,7 @@ function xu({ idx: t }) {
8151
8151
  }
8152
8152
  }
8153
8153
  return /* @__PURE__ */ a(zt, { children: [
8154
- /* @__PURE__ */ e(Bt, { children: /* @__PURE__ */ e(tl, { className: "size-4 rotate-[135deg] cursor-pointer text-muted-foreground hover:text-foreground" }) }),
8154
+ /* @__PURE__ */ e(Bt, { children: /* @__PURE__ */ e(al, { className: "size-4 rotate-[135deg] cursor-pointer text-muted-foreground hover:text-foreground" }) }),
8155
8155
  /* @__PURE__ */ e(jt, { className: "w-fit px-2 py-1", children: /* @__PURE__ */ a("div", { className: "flex gap-1", children: [
8156
8156
  /* @__PURE__ */ e(
8157
8157
  "button",
@@ -8228,7 +8228,7 @@ function bu() {
8228
8228
  defaultMetricKeys: r
8229
8229
  };
8230
8230
  }
8231
- function hn({
8231
+ function gn({
8232
8232
  children: t,
8233
8233
  className: s,
8234
8234
  delayDuration: n
@@ -8247,7 +8247,7 @@ function hn({
8247
8247
  /* @__PURE__ */ e(Re, { children: t })
8248
8248
  ] }) });
8249
8249
  }
8250
- function xl() {
8250
+ function bl() {
8251
8251
  const t = T((d) => d.card), s = T(
8252
8252
  (d) => {
8253
8253
  var u, m, h;
@@ -8262,7 +8262,7 @@ function xl() {
8262
8262
  {
8263
8263
  className: "flex h-8 items-center rounded-md bg-muted/70 px-3 hover:bg-muted",
8264
8264
  title: d,
8265
- children: bl(d)
8265
+ children: vl(d)
8266
8266
  },
8267
8267
  d
8268
8268
  )) })
@@ -8270,7 +8270,7 @@ function xl() {
8270
8270
  /* @__PURE__ */ a("div", { className: "space-y-2", children: [
8271
8271
  /* @__PURE__ */ e(G, { children: l }),
8272
8272
  /* @__PURE__ */ e("div", { className: "my-1 max-h-[125px] space-y-1 overflow-y-auto", children: c.map((d, u) => /* @__PURE__ */ e(
8273
- vl,
8273
+ yl,
8274
8274
  {
8275
8275
  className: "flex h-8 items-center bg-muted/70 px-3 hover:bg-muted",
8276
8276
  iconClassName: "invisible group-hover:visible",
@@ -8282,10 +8282,10 @@ function xl() {
8282
8282
  ] })
8283
8283
  ] });
8284
8284
  }
8285
- function bl(t, s = 30) {
8285
+ function vl(t, s = 30) {
8286
8286
  return t.length > s ? t.slice(0, s) + "..." : t;
8287
8287
  }
8288
- function vl({
8288
+ function yl({
8289
8289
  col: t,
8290
8290
  idx: s,
8291
8291
  className: n,
@@ -8334,7 +8334,7 @@ function vl({
8334
8334
  n
8335
8335
  ),
8336
8336
  children: [
8337
- l || /* @__PURE__ */ e(hn, { className: "max-w-[100px]", title: t, children: bl(t) }),
8337
+ l || /* @__PURE__ */ e(gn, { className: "max-w-[100px]", title: t, children: vl(t) }),
8338
8338
  /* @__PURE__ */ a("div", { className: "flex gap-2", children: [
8339
8339
  /* @__PURE__ */ e(
8340
8340
  os,
@@ -8375,7 +8375,7 @@ function vl({
8375
8375
  function oa() {
8376
8376
  const t = J(
8377
8377
  (o) => o.dashboard.filters
8378
- ), s = T((o) => o.frame), { setFrame: n } = ee(), { columns: r } = ba(), { assignFilter: l } = ll();
8378
+ ), s = T((o) => o.frame), { setFrame: n } = ee(), { columns: r } = ba(), { assignFilter: l } = il();
8379
8379
  function i(o) {
8380
8380
  const d = l(o, "frame");
8381
8381
  n({ ...s, filterId: d });
@@ -8384,7 +8384,7 @@ function oa() {
8384
8384
  return /* @__PURE__ */ a("div", { className: "space-y-3", children: [
8385
8385
  /* @__PURE__ */ e(G, { children: "Card Filter" }),
8386
8386
  /* @__PURE__ */ e(vu, { onSelect: i, columns: r }),
8387
- c && /* @__PURE__ */ e($r, { filter: c })
8387
+ c && /* @__PURE__ */ e(qr, { filter: c })
8388
8388
  ] });
8389
8389
  }
8390
8390
  function vu({
@@ -8392,7 +8392,7 @@ function vu({
8392
8392
  onSelect: s
8393
8393
  }) {
8394
8394
  var c;
8395
- const [n, r] = Os.useState(!1), [l, i] = Os.useState("");
8395
+ const [n, r] = Ps.useState(!1), [l, i] = Ps.useState("");
8396
8396
  return /* @__PURE__ */ a(zt, { open: n, onOpenChange: r, children: [
8397
8397
  /* @__PURE__ */ e(Bt, { asChild: !0, children: /* @__PURE__ */ a(
8398
8398
  q,
@@ -8470,7 +8470,7 @@ function yu({
8470
8470
  ] }),
8471
8471
  /* @__PURE__ */ a(fe, { value: "item-2", children: [
8472
8472
  /* @__PURE__ */ e(ge, { children: "Settings" }),
8473
- /* @__PURE__ */ e(xe, { className: "space-y-4 px-2", children: /* @__PURE__ */ e(xl, {}) })
8473
+ /* @__PURE__ */ e(xe, { className: "space-y-4 px-2", children: /* @__PURE__ */ e(bl, {}) })
8474
8474
  ] }),
8475
8475
  /* @__PURE__ */ a(fe, { value: "item-3", children: [
8476
8476
  /* @__PURE__ */ e(ge, { children: "Click Filters" }),
@@ -8524,7 +8524,7 @@ function Nu({
8524
8524
  ] })
8525
8525
  ] }) });
8526
8526
  }
8527
- function yl() {
8527
+ function Nl() {
8528
8528
  const t = T((o) => o.card.type), s = T((o) => o.isDevMode), n = T((o) => o.card.preferences), { setCardPreferences: r } = T((o) => o.actions);
8529
8529
  function l(o) {
8530
8530
  var m;
@@ -8629,7 +8629,7 @@ function Su() {
8629
8629
  }
8630
8630
  ),
8631
8631
  !["kpi"].includes(t) && /* @__PURE__ */ a("div", { className: "space-y-4", children: [
8632
- /* @__PURE__ */ e(yl, {}),
8632
+ /* @__PURE__ */ e(Nl, {}),
8633
8633
  /* @__PURE__ */ e(Xt, {}),
8634
8634
  /* @__PURE__ */ e(oa, {})
8635
8635
  ] })
@@ -8848,7 +8848,7 @@ function Tu() {
8848
8848
  }
8849
8849
  ) || [], d = T(
8850
8850
  (b) => b.actions.setColorRanges
8851
- ), u = [...new Set(Mn.map((b) => b.currency))];
8851
+ ), u = [...new Set(Pn.map((b) => b.currency))];
8852
8852
  return /* @__PURE__ */ a("div", { children: [
8853
8853
  !r && /* @__PURE__ */ a("div", { className: "mb-3 flex items-center gap-2", children: [
8854
8854
  /* @__PURE__ */ e(
@@ -8891,7 +8891,7 @@ function Tu() {
8891
8891
  /* @__PURE__ */ e(ie, { children: /* @__PURE__ */ a(fa, { children: [
8892
8892
  /* @__PURE__ */ e(Va, { children: "Format" }),
8893
8893
  /* @__PURE__ */ e(Q, { value: "none", children: "Auto" }, "none"),
8894
- Mn.map((b) => /* @__PURE__ */ e(Q, { value: b.locale, children: b.locale }, b.locale))
8894
+ Pn.map((b) => /* @__PURE__ */ e(Q, { value: b.locale, children: b.locale }, b.locale))
8895
8895
  ] }) })
8896
8896
  ]
8897
8897
  }
@@ -9136,7 +9136,7 @@ function Fu() {
9136
9136
  var d, u, m, h, p, f, v, b, y, k, A, V, O, I, w, g, x, C;
9137
9137
  const t = T((M) => M.card), s = (u = (d = t == null ? void 0 : t.preferences) == null ? void 0 : d.mapVisualOptions) == null ? void 0 : u.topoJsonUrl, [n, r] = R(
9138
9138
  ((h = (m = t == null ? void 0 : t.preferences) == null ? void 0 : m.mapVisualOptions) == null ? void 0 : h.customTopoJsonUrl) || ""
9139
- ), { setCardPreferences: l } = ee(), { data: i } = Xs(t), c = Object.keys((i == null ? void 0 : i.objects) || {}).map((M) => ({
9139
+ ), { setCardPreferences: l } = ee(), { data: i } = Zs(t), c = Object.keys((i == null ? void 0 : i.objects) || {}).map((M) => ({
9140
9140
  label: M,
9141
9141
  value: M
9142
9142
  })) || [];
@@ -9350,7 +9350,7 @@ function Ou() {
9350
9350
  });
9351
9351
  }
9352
9352
  return /* @__PURE__ */ a(
9353
- Ws,
9353
+ Ys,
9354
9354
  {
9355
9355
  value: (r = t == null ? void 0 : t.textVisualOptions) != null && r.isDynamicText ? "dynamic" : "static",
9356
9356
  onValueChange: n,
@@ -9480,7 +9480,7 @@ function Pu() {
9480
9480
  /* @__PURE__ */ e(ge, { children: "Settings" }),
9481
9481
  /* @__PURE__ */ a(xe, { className: "space-y-4 px-2", children: [
9482
9482
  n(),
9483
- /* @__PURE__ */ e(xl, {})
9483
+ /* @__PURE__ */ e(bl, {})
9484
9484
  ] })
9485
9485
  ] }),
9486
9486
  /* @__PURE__ */ a(fe, { value: "item-3", children: [
@@ -9528,12 +9528,12 @@ function Lu({
9528
9528
  ] })
9529
9529
  ] });
9530
9530
  }
9531
- function Nl({ color: t, onColorChange: s, onClose: n }) {
9531
+ function Cl({ color: t, onColorChange: s, onClose: n }) {
9532
9532
  const [r, l] = R(0), [i, c] = R(100), [o, d] = R(50), [u, m] = R(t);
9533
9533
  he(() => {
9534
- const y = qn(t);
9534
+ const y = Kn(t);
9535
9535
  if (y) {
9536
- const k = Gn(y.r, y.g, y.b);
9536
+ const k = _n(y.r, y.g, y.b);
9537
9537
  l(k.h), c(k.s), d(k.l), m(t);
9538
9538
  }
9539
9539
  }, [t]);
@@ -9547,9 +9547,9 @@ function Nl({ color: t, onColorChange: s, onClose: n }) {
9547
9547
  m(O);
9548
9548
  }, v = (y) => {
9549
9549
  if (m(y), /^#[0-9A-Fa-f]{6}$/.test(y)) {
9550
- const k = qn(y);
9550
+ const k = Kn(y);
9551
9551
  if (k) {
9552
- const A = Gn(k.r, k.g, k.b);
9552
+ const A = _n(k.r, k.g, k.b);
9553
9553
  l(A.h), c(A.s), d(A.l);
9554
9554
  }
9555
9555
  }
@@ -9655,7 +9655,7 @@ function Nl({ color: t, onColorChange: s, onClose: n }) {
9655
9655
  ] })
9656
9656
  ] });
9657
9657
  }
9658
- function qn(t) {
9658
+ function Kn(t) {
9659
9659
  const s = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(t);
9660
9660
  return s ? {
9661
9661
  r: parseInt(s[1], 16),
@@ -9666,7 +9666,7 @@ function qn(t) {
9666
9666
  function Vu(t, s, n) {
9667
9667
  return "#" + ((1 << 24) + (t << 16) + (s << 8) + n).toString(16).slice(1);
9668
9668
  }
9669
- function Gn(t, s, n) {
9669
+ function _n(t, s, n) {
9670
9670
  t /= 255, s /= 255, n /= 255;
9671
9671
  const r = Math.max(t, s, n), l = Math.min(t, s, n);
9672
9672
  let i = 0, c = 0;
@@ -9738,7 +9738,7 @@ const zu = [
9738
9738
  "#fbbf24"
9739
9739
  // yellow-400
9740
9740
  ];
9741
- function Cl() {
9741
+ function wl() {
9742
9742
  var V, O, I, w, g, x, C, M, S, L;
9743
9743
  const t = T((E) => E.card), s = T((E) => {
9744
9744
  var D;
@@ -9794,7 +9794,7 @@ function Cl() {
9794
9794
  he(() => {
9795
9795
  const E = {};
9796
9796
  h.forEach((D, N) => {
9797
- E[D] = Fn(
9797
+ E[D] = Ln(
9798
9798
  D,
9799
9799
  N,
9800
9800
  s == null ? void 0 : s.colorConfig
@@ -9854,7 +9854,7 @@ function Cl() {
9854
9854
  r(D);
9855
9855
  const N = {};
9856
9856
  h.forEach((F, P) => {
9857
- N[F] = Fn(F, P, void 0);
9857
+ N[F] = Ln(F, P, void 0);
9858
9858
  }), c(N);
9859
9859
  }, A = Object.keys(((L = s == null ? void 0 : s.colorConfig) == null ? void 0 : L.segments) || {}).length > 0;
9860
9860
  return /* @__PURE__ */ a(fe, { value: "colors", className: "border-b-0", children: [
@@ -9869,7 +9869,7 @@ function Cl() {
9869
9869
  className: "ml-auto flex items-center gap-1 text-xs text-muted-foreground hover:text-foreground",
9870
9870
  onClick: k,
9871
9871
  children: [
9872
- /* @__PURE__ */ e(zn, { className: "h-3 w-3" }),
9872
+ /* @__PURE__ */ e($n, { className: "h-3 w-3" }),
9873
9873
  "Reset All"
9874
9874
  ]
9875
9875
  }
@@ -9952,7 +9952,7 @@ function Cl() {
9952
9952
  v(E, D), d(null);
9953
9953
  },
9954
9954
  children: [
9955
- /* @__PURE__ */ e(zn, { className: "h-3 w-3" }),
9955
+ /* @__PURE__ */ e($n, { className: "h-3 w-3" }),
9956
9956
  "Reset"
9957
9957
  ]
9958
9958
  }
@@ -9975,7 +9975,7 @@ function Cl() {
9975
9975
  }
9976
9976
  ),
9977
9977
  /* @__PURE__ */ e("div", { className: "relative rounded-lg bg-white shadow-lg", children: /* @__PURE__ */ e(
9978
- Nl,
9978
+ Cl,
9979
9979
  {
9980
9980
  color: u.color,
9981
9981
  onColorChange: (E) => {
@@ -10128,7 +10128,7 @@ const Bu = [
10128
10128
  { value: "nl-NL", label: "Dutch" },
10129
10129
  { value: "sv-SE", label: "Swedish" }
10130
10130
  ], qu = (t) => t.charAt(0).toUpperCase() + t.slice(1);
10131
- function pn({
10131
+ function xn({
10132
10132
  formatOptions: t = {},
10133
10133
  onFormatOptionsChange: s,
10134
10134
  showTitle: n = !0,
@@ -10294,7 +10294,7 @@ function pn({
10294
10294
  ] })
10295
10295
  ] });
10296
10296
  }
10297
- function Un({ axis: t, label: s, type: n, config: r, onChange: l }) {
10297
+ function Jn({ axis: t, label: s, type: n, config: r, onChange: l }) {
10298
10298
  var h, p, f, v, b, y, k, A, V, O, I, w;
10299
10299
  const i = (g, x) => {
10300
10300
  l({
@@ -10406,7 +10406,7 @@ function Un({ axis: t, label: s, type: n, config: r, onChange: l }) {
10406
10406
  ] })
10407
10407
  ] }),
10408
10408
  n === "value" && /* @__PURE__ */ e(
10409
- pn,
10409
+ xn,
10410
10410
  {
10411
10411
  formatOptions: (r == null ? void 0 : r.formatOptions) || {},
10412
10412
  onFormatOptionsChange: (g) => l({
@@ -10464,7 +10464,7 @@ function Un({ axis: t, label: s, type: n, config: r, onChange: l }) {
10464
10464
  ] })
10465
10465
  ] });
10466
10466
  }
10467
- function wl() {
10467
+ function Sl() {
10468
10468
  const t = T((c) => c.card), s = T((c) => {
10469
10469
  var o;
10470
10470
  return (o = c.card) == null ? void 0 : o.preferences;
@@ -10488,12 +10488,12 @@ function wl() {
10488
10488
  };
10489
10489
  return /* @__PURE__ */ a(fe, { value: "axes", className: "border-b-0", children: [
10490
10490
  /* @__PURE__ */ e(ge, { className: "flex w-full items-center gap-2 py-2 text-sm font-medium hover:no-underline", children: /* @__PURE__ */ a("div", { className: "flex items-center gap-2", children: [
10491
- /* @__PURE__ */ e(el, { className: "h-4 w-4 text-muted-foreground" }),
10491
+ /* @__PURE__ */ e(tl, { className: "h-4 w-4 text-muted-foreground" }),
10492
10492
  /* @__PURE__ */ e("span", { children: "Axes" })
10493
10493
  ] }) }),
10494
10494
  /* @__PURE__ */ e(xe, { className: "pt-2", children: /* @__PURE__ */ a(Ze, { type: "single", collapsible: !0, className: "w-full", children: [
10495
10495
  l.hasXAxis && /* @__PURE__ */ e(
10496
- Un,
10496
+ Jn,
10497
10497
  {
10498
10498
  axis: "x",
10499
10499
  label: "X-Axis",
@@ -10503,7 +10503,7 @@ function wl() {
10503
10503
  }
10504
10504
  ),
10505
10505
  l.hasYAxis && /* @__PURE__ */ e(
10506
- Un,
10506
+ Jn,
10507
10507
  {
10508
10508
  axis: "y",
10509
10509
  label: "Y-Axis",
@@ -10515,7 +10515,7 @@ function wl() {
10515
10515
  ] }) })
10516
10516
  ] });
10517
10517
  }
10518
- function Sl() {
10518
+ function kl() {
10519
10519
  const t = T((u) => u.card), s = T(
10520
10520
  (u) => {
10521
10521
  var m, h, p, f;
@@ -10580,7 +10580,7 @@ function Sl() {
10580
10580
  ] }) })
10581
10581
  ] });
10582
10582
  }
10583
- function kl() {
10583
+ function Dl() {
10584
10584
  var S, L, E, D, N, F, P, K, B;
10585
10585
  const t = T((z) => z.card), s = T(
10586
10586
  (z) => {
@@ -10913,13 +10913,13 @@ function Ta({
10913
10913
  }
10914
10914
  );
10915
10915
  }
10916
- const Kn = ["poor", "satisfactory", "good"];
10917
- function _n(t) {
10916
+ const Hn = ["poor", "satisfactory", "good"];
10917
+ function Qn(t) {
10918
10918
  if (!t) return;
10919
10919
  const s = { ...t };
10920
10920
  return s.targetMetricKey || delete s.targetMetricKey, s.comparativeMetricKey || delete s.comparativeMetricKey, !s.targetValue && s.targetValue !== 0 && delete s.targetValue, (!s.rangeKeys || Object.keys(s.rangeKeys).length === 0) && delete s.rangeKeys, (!s.ranges || Object.keys(s.ranges).length === 0) && delete s.ranges, (!s.rangeLabels || Object.keys(s.rangeLabels).length === 0) && delete s.rangeLabels, s;
10921
10921
  }
10922
- function Dl() {
10922
+ function Tl() {
10923
10923
  var E, D;
10924
10924
  const t = T((N) => N.card.preferences), s = T((N) => N.card), n = T((N) => N.isDevMode), { setCardPreferences: r, setChartOrientation: l } = ee(), i = qe(
10925
10925
  () => (t == null ? void 0 : t.bulletConfig) || {},
@@ -10969,10 +10969,10 @@ function Dl() {
10969
10969
  ...i.rangeKeys || {}
10970
10970
  };
10971
10971
  let U = !1;
10972
- if (Kn.forEach((de, be) => {
10972
+ if (Hn.forEach((de, be) => {
10973
10973
  !z[de] && B[be] && (z[de] = B[be].value, U = !0);
10974
10974
  }), U && (N.rangeKeys = z, F = !0, i.showRanges === void 0 && (N.showRanges = !0)), F) {
10975
- const de = _n({
10975
+ const de = Qn({
10976
10976
  ...i,
10977
10977
  ...N
10978
10978
  });
@@ -10983,7 +10983,7 @@ function Dl() {
10983
10983
  }
10984
10984
  }, [y, i, t, r]);
10985
10985
  const k = (N) => {
10986
- const F = _n({
10986
+ const F = Qn({
10987
10987
  ...i,
10988
10988
  ...N
10989
10989
  });
@@ -11199,7 +11199,7 @@ function Dl() {
11199
11199
  /* @__PURE__ */ e("span", { children: "Use % of value" })
11200
11200
  ] })
11201
11201
  ] }),
11202
- d && /* @__PURE__ */ e("div", { className: "space-y-3", children: Kn.map((N) => {
11202
+ d && /* @__PURE__ */ e("div", { className: "space-y-3", children: Hn.map((N) => {
11203
11203
  var F, P, K, B, z;
11204
11204
  return /* @__PURE__ */ a(
11205
11205
  "div",
@@ -11292,11 +11292,11 @@ function Gu() {
11292
11292
  return /* @__PURE__ */ a("div", { className: "space-y-4 px-6 py-4", children: [
11293
11293
  /* @__PURE__ */ e("h3", { className: "text-sm font-medium", children: "Chart Configuration" }),
11294
11294
  /* @__PURE__ */ a(Ze, { type: "single", collapsible: !0, className: "w-full px-2", children: [
11295
- (t == null ? void 0 : t.type) === "bullet" && /* @__PURE__ */ e(Dl, {}),
11296
- /* @__PURE__ */ e(Cl, {}),
11295
+ (t == null ? void 0 : t.type) === "bullet" && /* @__PURE__ */ e(Tl, {}),
11297
11296
  /* @__PURE__ */ e(wl, {}),
11298
11297
  /* @__PURE__ */ e(Sl, {}),
11299
- /* @__PURE__ */ e(kl, {})
11298
+ /* @__PURE__ */ e(kl, {}),
11299
+ /* @__PURE__ */ e(Dl, {})
11300
11300
  ] })
11301
11301
  ] });
11302
11302
  }
@@ -11462,8 +11462,8 @@ function Hu() {
11462
11462
  }
11463
11463
  ) }),
11464
11464
  !r && /* @__PURE__ */ e(Ot, {}),
11465
- /* @__PURE__ */ e(Ue, { minSize: 40, defaultSize: 75, maxSize: 100, children: /* @__PURE__ */ e($n, {}) })
11466
- ] }) : /* @__PURE__ */ e($n, {})
11465
+ /* @__PURE__ */ e(Ue, { minSize: 40, defaultSize: 75, maxSize: 100, children: /* @__PURE__ */ e(Un, {}) })
11466
+ ] }) : /* @__PURE__ */ e(Un, {})
11467
11467
  }
11468
11468
  )
11469
11469
  ]
@@ -11472,7 +11472,7 @@ function Hu() {
11472
11472
  }
11473
11473
  function Qu(t) {
11474
11474
  var Ke;
11475
- On(
11475
+ Vn(
11476
11476
  (_) => _.currentAIContext
11477
11477
  );
11478
11478
  const [s, n] = R(""), [r, l] = R(null), { authToken: i, tokenProps: c } = je(), o = T((_) => {
@@ -11499,7 +11499,7 @@ function Qu(t) {
11499
11499
  errorMessage: x,
11500
11500
  refetch: C,
11501
11501
  data: M
11502
- } = Me(A), { setTriggerAIRun: S, setCurrentAssitantScope: L, setCardConfig: E } = ee(), { selectedDatamodelName: D, connectionType: N, selectedDatamodelId: F } = ba(), P = (Ke = or().data) == null ? void 0 : Ke.assistantProfileId, {
11502
+ } = Me(A), { setTriggerAIRun: S, setCurrentAssitantScope: L, setCardConfig: E } = ee(), { selectedDatamodelName: D, connectionType: N, selectedDatamodelId: F } = ba(), P = (Ke = ur().data) == null ? void 0 : Ke.assistantProfileId, {
11503
11503
  messages: K,
11504
11504
  setMessages: B,
11505
11505
  regenerate: z,
@@ -11516,7 +11516,7 @@ function Qu(t) {
11516
11516
  Authorization: `Bearer ${i == null ? void 0 : i.accessToken}`
11517
11517
  }),
11518
11518
  body: () => {
11519
- const _ = On.getState();
11519
+ const _ = Vn.getState();
11520
11520
  return {
11521
11521
  random: Math.random(),
11522
11522
  assistantId: "editor-assistant",
@@ -11659,10 +11659,10 @@ function Qu(t) {
11659
11659
  schemaName: w || "",
11660
11660
  tableName: O || "",
11661
11661
  datamodelId: F || "",
11662
- datamodelName: Pn(D),
11662
+ datamodelName: Rn(D),
11663
11663
  connectionId: I || "",
11664
11664
  connectionType: N || ""
11665
- }, oe = Ln([...b, _]);
11665
+ }, oe = zn([...b, _]);
11666
11666
  H(oe);
11667
11667
  }
11668
11668
  function me() {
@@ -11670,7 +11670,7 @@ function Qu(t) {
11670
11670
  databaseName: V || "",
11671
11671
  schemaName: w || "",
11672
11672
  tableName: O || "",
11673
- datamodelName: Pn(D),
11673
+ datamodelName: Rn(D),
11674
11674
  connectionId: I || "",
11675
11675
  connectionType: N || "",
11676
11676
  datamodelId: F || ""
@@ -11679,7 +11679,7 @@ function Qu(t) {
11679
11679
  [...g || [], ...b],
11680
11680
  _
11681
11681
  ) || b.length === 0) {
11682
- const Ge = Ln([
11682
+ const Ge = zn([
11683
11683
  ...g || [],
11684
11684
  ...b,
11685
11685
  _
@@ -11720,12 +11720,12 @@ const Wu = [
11720
11720
  subtitle: "sales by category"
11721
11721
  }
11722
11722
  ];
11723
- function Jn({
11723
+ function Wn({
11724
11724
  isFullscreen: t,
11725
11725
  onFullscreenChange: s,
11726
11726
  fullscreenContainer: n
11727
11727
  }) {
11728
- const r = dt(null), [l, i] = R(!1), [c, o] = R(qr), [d, u] = R(!1), [m, h] = R(!1), [p, f] = R(!1), v = t ?? p, b = po(), { setCurrentAIContext: y } = Gr(), { clearQueue: k } = fo(), { clearFileAttachments: A } = go(), V = xo("editor"), O = J((se) => se.dashboard.aiContext), I = T((se) => se.card.dataSource), w = T((se) => se.actions.setCardSql), g = T((se) => se.actions.setRunSql), x = T((se) => se.showAIDialog), C = J(
11728
+ const r = dt(null), [l, i] = R(!1), [c, o] = R(Gr), [d, u] = R(!1), [m, h] = R(!1), [p, f] = R(!1), v = t ?? p, b = po(), { setCurrentAIContext: y } = Ur(), { clearQueue: k } = fo(), { clearFileAttachments: A } = go(), V = xo("editor"), O = J((se) => se.dashboard.aiContext), I = T((se) => se.card.dataSource), w = T((se) => se.actions.setCardSql), g = T((se) => se.actions.setRunSql), x = T((se) => se.showAIDialog), C = J(
11729
11729
  (se) => se.handleOpenAssistantProfile
11730
11730
  ), { setShowAIDialog: M, setCardPython: S } = ee(), { setDataSource: L } = ee(), { assistantProfile: E } = bo(), {
11731
11731
  messages: D,
@@ -11863,7 +11863,7 @@ function Jn({
11863
11863
  }
11864
11864
  ) }),
11865
11865
  /* @__PURE__ */ a(Et, { align: "end", children: [
11866
- /* @__PURE__ */ e($s, { children: "Options" }),
11866
+ /* @__PURE__ */ e(qs, { children: "Options" }),
11867
11867
  /* @__PURE__ */ e(ma, {}),
11868
11868
  /* @__PURE__ */ e(
11869
11869
  Ut,
@@ -11950,7 +11950,7 @@ function Jn({
11950
11950
  onClick: () => {
11951
11951
  N([]), k("editor"), $(), me();
11952
11952
  },
11953
- children: /* @__PURE__ */ e(Ur, { className: "size-4" })
11953
+ children: /* @__PURE__ */ e(Kr, { className: "size-4" })
11954
11954
  }
11955
11955
  ),
11956
11956
  /* @__PURE__ */ e(
@@ -11970,7 +11970,7 @@ function Jn({
11970
11970
  }
11971
11971
  ),
11972
11972
  /* @__PURE__ */ e(
11973
- xr,
11973
+ yr,
11974
11974
  {
11975
11975
  ref: $e,
11976
11976
  className: "mt-2 flex w-full grow basis-0",
@@ -12073,12 +12073,12 @@ function Jn({
12073
12073
  " total tokens"
12074
12074
  ] }) }),
12075
12075
  /* @__PURE__ */ e(
12076
- Sr,
12076
+ Tr,
12077
12077
  {
12078
12078
  incomingSelectedEntities: (I == null ? void 0 : I.selectedEntities) || [],
12079
12079
  open: m,
12080
12080
  onOpenChange: h,
12081
- dataSource: I || Kr,
12081
+ dataSource: I || _r,
12082
12082
  dialogMode: "aiContext"
12083
12083
  }
12084
12084
  )
@@ -12107,12 +12107,12 @@ function Xu() {
12107
12107
  );
12108
12108
  return { standardFirst: t, updatePreference: s };
12109
12109
  }
12110
- const Hn = ({
12110
+ const Yn = ({
12111
12111
  pluginVisual: t,
12112
12112
  index: s,
12113
12113
  onSelect: n
12114
12114
  }) => {
12115
- const r = fs(t.icon || ""), l = t.name.charAt(0).toUpperCase(), i = nn(t.name);
12115
+ const r = fs(t.icon || ""), l = t.name.charAt(0).toUpperCase(), i = on(t.name);
12116
12116
  return /* @__PURE__ */ e(
12117
12117
  wa,
12118
12118
  {
@@ -12139,7 +12139,7 @@ const Hn = ({
12139
12139
  },
12140
12140
  `${t.url}-${t.name}-${s}`
12141
12141
  );
12142
- }, Qn = [
12142
+ }, Xn = [
12143
12143
  "default",
12144
12144
  "standardPlugin",
12145
12145
  "customPlugin"
@@ -12149,16 +12149,16 @@ function Zu({
12149
12149
  onChartChange: s
12150
12150
  }) {
12151
12151
  var I;
12152
- const [n, r] = R(!1), { data: l } = pl();
12152
+ const [n, r] = R(!1), { data: l } = fl();
12153
12153
  Xu();
12154
12154
  const c = ((I = T((w) => w.card).customCardPreferences) == null ? void 0 : I.url) || "";
12155
- ln(c);
12155
+ dn(c);
12156
12156
  const { setCardType: o, setCardPreferences: d, setIsDevMode: u } = T(
12157
12157
  (w) => w.actions
12158
12158
  ), { setCardCustomCfg: m, setCustomCardPreferences: h, setQueryConfig: p } = ee(), [f, v] = gs("chart-section-active", null), b = qe(() => f ? [
12159
12159
  f,
12160
- ...Qn.filter((w) => w !== f)
12161
- ] : Qn, [f]);
12160
+ ...Xn.filter((w) => w !== f)
12161
+ ] : Xn, [f]);
12162
12162
  function y(w) {
12163
12163
  m(null), d({}), o(w), ["custom", "map"].includes(w) && (u(!0), p(void 0)), s(w), r(!1);
12164
12164
  }
@@ -12207,7 +12207,7 @@ function Zu({
12207
12207
  if (M && S)
12208
12208
  return /* @__PURE__ */ e(em, { icon: M, componentName: S });
12209
12209
  if (S) {
12210
- const L = nn(S);
12210
+ const L = on(S);
12211
12211
  if (L)
12212
12212
  return L;
12213
12213
  }
@@ -12299,7 +12299,7 @@ function Zu({
12299
12299
  ] }),
12300
12300
  className: "[&_[cmdk-group-heading]]:text-sm [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground",
12301
12301
  children: g.filter((x) => x.componentType === "chart").map((x, C) => /* @__PURE__ */ e(
12302
- Hn,
12302
+ Yn,
12303
12303
  {
12304
12304
  pluginVisual: x,
12305
12305
  index: C,
@@ -12340,7 +12340,7 @@ function Zu({
12340
12340
  ] }),
12341
12341
  className: "[&_[cmdk-group-heading]]:text-sm [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground",
12342
12342
  children: g.map((x, C) => /* @__PURE__ */ e(
12343
- Hn,
12343
+ Yn,
12344
12344
  {
12345
12345
  pluginVisual: x,
12346
12346
  index: C,
@@ -12362,7 +12362,7 @@ const em = ({
12362
12362
  icon: t,
12363
12363
  componentName: s
12364
12364
  }) => {
12365
- const n = fs(), r = nn(s);
12365
+ const n = fs(), r = on(s);
12366
12366
  return n ? /* @__PURE__ */ e(n, { className: "h-4 w-4" }) : r || /* @__PURE__ */ e(la, { className: "h-4 w-4" });
12367
12367
  }, tm = [
12368
12368
  { id: "table", icon: ns, label: "Table" },
@@ -12370,48 +12370,88 @@ const em = ({
12370
12370
  { id: "line", icon: is, label: "Line Chart" },
12371
12371
  {
12372
12372
  id: "stackedBar",
12373
- icon: tn,
12373
+ icon: nn,
12374
12374
  label: "Stacked Bar",
12375
- requiresPivot: !0
12375
+ requiresPivot: !1
12376
12376
  },
12377
- { id: "pie", icon: sn, label: "Pie Chart" },
12378
- { id: "doughnut", icon: an, label: "Donut Chart" },
12379
- { id: "kpi", icon: en, label: "KPI" },
12377
+ { id: "pie", icon: ln, label: "Pie Chart" },
12378
+ { id: "doughnut", icon: rn, label: "Donut Chart" },
12379
+ { id: "kpi", icon: tn, label: "KPI" },
12380
12380
  { id: "treemap", icon: ls, label: "Treemap" },
12381
- { id: "bullet", icon: Ca, label: "Bullet Chart" }
12381
+ { id: "bullet", icon: Ca, label: "Bullet Chart" },
12382
+ { id: "funnel", icon: sn, label: "Funnel Chart" },
12383
+ { id: "tornado", icon: an, label: "Tornado Chart" }
12382
12384
  ];
12383
12385
  function am({
12384
12386
  selectedChart: t,
12385
- onChartChange: s
12387
+ onChartChange: s,
12388
+ isDropdownExpanded: n,
12389
+ onToggleDropdown: r
12386
12390
  }) {
12387
- var l;
12388
- const n = T((i) => i.card), r = ((l = n == null ? void 0 : n.config) == null ? void 0 : l.pivotByColumns) && n.config.pivotByColumns.length > 0;
12389
- return /* @__PURE__ */ e("div", { className: "flex items-center gap-0.5", children: tm.map((i) => {
12390
- if (i.requiresPivot && !r)
12391
- return null;
12392
- const c = i.icon, o = t === i.id;
12393
- return /* @__PURE__ */ a(Ie, { children: [
12394
- /* @__PURE__ */ e(Ee, { asChild: !0, children: /* @__PURE__ */ a(
12391
+ var o;
12392
+ const l = T((d) => d.card), i = ((o = l == null ? void 0 : l.config) == null ? void 0 : o.pivotByColumns) && l.config.pivotByColumns.length > 0, c = tm.filter(
12393
+ (d) => !(d.requiresPivot && !i)
12394
+ );
12395
+ return /* @__PURE__ */ a("div", { className: "grid grid-cols-6 gap-2", children: [
12396
+ c.map((d) => {
12397
+ const u = d.icon, m = t === d.id;
12398
+ return /* @__PURE__ */ a(Ie, { children: [
12399
+ /* @__PURE__ */ e(Ee, { asChild: !0, children: /* @__PURE__ */ a(
12400
+ q,
12401
+ {
12402
+ variant: "ghost",
12403
+ size: "sm",
12404
+ onClick: () => s(d.id),
12405
+ className: Y(
12406
+ "h-8 w-8 p-0",
12407
+ m && "bg-accent text-accent-foreground"
12408
+ ),
12409
+ children: [
12410
+ /* @__PURE__ */ e(u, { className: "h-4 w-4" }),
12411
+ /* @__PURE__ */ e("span", { className: "sr-only", children: d.label })
12412
+ ]
12413
+ }
12414
+ ) }),
12415
+ /* @__PURE__ */ a(
12416
+ Re,
12417
+ {
12418
+ side: "bottom",
12419
+ className: "border-foreground/20 bg-foreground text-background",
12420
+ children: [
12421
+ /* @__PURE__ */ e("p", { children: d.label }),
12422
+ /* @__PURE__ */ e(Is, { className: "fill-foreground" })
12423
+ ]
12424
+ }
12425
+ )
12426
+ ] }, d.id);
12427
+ }),
12428
+ r && /* @__PURE__ */ a(Ie, { children: [
12429
+ /* @__PURE__ */ e(Ee, { asChild: !0, children: /* @__PURE__ */ e(
12395
12430
  q,
12396
12431
  {
12397
12432
  variant: "ghost",
12398
12433
  size: "sm",
12399
- onClick: () => s(i.id),
12400
- className: Y(
12401
- "h-8 w-8 p-0",
12402
- o && "bg-accent text-accent-foreground"
12403
- ),
12434
+ onClick: r,
12435
+ className: "h-8 w-8 p-0",
12436
+ "aria-label": n ? "Hide all charts" : "Show all charts",
12437
+ children: n ? /* @__PURE__ */ e(ya, { className: "h-4 w-4" }) : /* @__PURE__ */ e(Rt, { className: "h-4 w-4" })
12438
+ }
12439
+ ) }),
12440
+ /* @__PURE__ */ a(
12441
+ Re,
12442
+ {
12443
+ side: "bottom",
12444
+ className: "border-foreground/20 bg-foreground text-background",
12404
12445
  children: [
12405
- /* @__PURE__ */ e(c, { className: "h-4 w-4" }),
12406
- /* @__PURE__ */ e("span", { className: "sr-only", children: i.label })
12446
+ /* @__PURE__ */ e("p", { children: n ? "Hide dropdown" : "Show all charts" }),
12447
+ /* @__PURE__ */ e(Is, { className: "fill-foreground" })
12407
12448
  ]
12408
12449
  }
12409
- ) }),
12410
- /* @__PURE__ */ e(Re, { side: "bottom", children: /* @__PURE__ */ e("p", { children: i.label }) })
12411
- ] }, i.id);
12412
- }) });
12450
+ )
12451
+ ] })
12452
+ ] });
12413
12453
  }
12414
- const fn = ({ dataType: t }) => fr(t);
12454
+ const bn = ({ dataType: t }) => br(t);
12415
12455
  function sm({
12416
12456
  aliasTemplate: t,
12417
12457
  onAliasTemplateChange: s
@@ -12606,12 +12646,12 @@ function rm({
12606
12646
  (d) => d === t.label || d === t.name
12607
12647
  ), i = l ? r.indexOf(l) : -1;
12608
12648
  function c() {
12609
- return /* @__PURE__ */ e("div", { className: "pr-1", children: l && /* @__PURE__ */ e(vl, { idx: i, col: l, children: /* @__PURE__ */ e("div", { className: "w-[130px] text-xs text-muted-foreground", children: "Display Series As" }) }) });
12649
+ return /* @__PURE__ */ e("div", { className: "pr-1", children: l && /* @__PURE__ */ e(yl, { idx: i, col: l, children: /* @__PURE__ */ e("div", { className: "w-[130px] text-xs text-muted-foreground", children: "Display Series As" }) }) });
12610
12650
  }
12611
12651
  function o() {
12612
12652
  return /* @__PURE__ */ a("div", { className: "space-y-1", children: [
12613
12653
  /* @__PURE__ */ e(G, { className: "text-xs font-medium text-muted-foreground", children: "Data Labels" }),
12614
- /* @__PURE__ */ e(yl, {})
12654
+ /* @__PURE__ */ e(Nl, {})
12615
12655
  ] });
12616
12656
  }
12617
12657
  return /* @__PURE__ */ a("div", { className: "space-y-1", children: [
@@ -12828,7 +12868,7 @@ function im({
12828
12868
  className: "justify-start h-auto py-2 px-3",
12829
12869
  onClick: () => v(I),
12830
12870
  children: [
12831
- /* @__PURE__ */ e(fn, { dataType: st(I.dataType) }),
12871
+ /* @__PURE__ */ e(bn, { dataType: st(I.dataType) }),
12832
12872
  /* @__PURE__ */ a("div", { className: "ml-2 text-left", children: [
12833
12873
  /* @__PURE__ */ e("div", { className: "text-sm font-medium", children: I.label }),
12834
12874
  /* @__PURE__ */ a("div", { className: "text-xs text-muted-foreground", children: [
@@ -12943,7 +12983,7 @@ function om({
12943
12983
  onCheckedChange: () => m(p.value)
12944
12984
  }
12945
12985
  ),
12946
- /* @__PURE__ */ e(hn, { className: "text-sm", children: p.label })
12986
+ /* @__PURE__ */ e(gn, { className: "text-sm", children: p.label })
12947
12987
  ]
12948
12988
  },
12949
12989
  p.id
@@ -12960,7 +13000,7 @@ function cm({
12960
13000
  hasPivotColumns: i = !1,
12961
13001
  cardType: c
12962
13002
  }) {
12963
- var xn, bn, vn, yn;
13003
+ var yn, Nn, Cn, wn;
12964
13004
  const {
12965
13005
  attributes: o,
12966
13006
  listeners: d,
@@ -12981,7 +13021,7 @@ function cm({
12981
13021
  handleKpiTrendlineWindowChange: g,
12982
13022
  handleKpiTrendlineGranularityChange: x,
12983
13023
  handleKpiTargetValueChange: C
12984
- } = dn(f), [M, S] = R(!1), [L, E] = R(!1), [D, N] = R(null), [F, P] = R(
13024
+ } = hn(f), [M, S] = R(!1), [L, E] = R(!1), [D, N] = R(null), [F, P] = R(
12985
13025
  t.dateFormat || "YYYY-MM-DD"
12986
13026
  ), [K, B] = R(t.customFormat || ""), [z, U] = R(!!t.customFormat), [$, X] = R(
12987
13027
  t.granularity || "day"
@@ -12989,14 +13029,14 @@ function cm({
12989
13029
  t.aliasTemplate || ""
12990
13030
  ), [Ce, Se] = R(
12991
13031
  t.valueAliases || {}
12992
- ), [ue, H] = R((xn = t.parameters) == null ? void 0 : xn.filters), ae = (W) => {
13032
+ ), [ue, H] = R((yn = t.parameters) == null ? void 0 : yn.filters), ae = (W) => {
12993
13033
  W === "custom" ? U(!0) : (U(!1), P(W), s === "groupBy" && y(n, W, ""));
12994
13034
  }, me = (W) => {
12995
13035
  B(W), s === "groupBy" && y(n, "custom", W);
12996
13036
  }, $e = (W) => {
12997
13037
  var He;
12998
13038
  X(W);
12999
- const Oe = (He = Vn(W)[0]) == null ? void 0 : He.value;
13039
+ const Oe = (He = Bn(W)[0]) == null ? void 0 : He.value;
13000
13040
  Oe && !z && (P(Oe), s === "groupBy" && y(n, Oe, "")), s === "groupBy" && k(n, W);
13001
13041
  }, tt = (W) => {
13002
13042
  be(W), s === "metrics" && A(n, W);
@@ -13024,7 +13064,7 @@ function cm({
13024
13064
  }, We = {
13025
13065
  transform: ts.Transform.toString(m),
13026
13066
  transition: h
13027
- }, at = st(t.dataType), ze = at === "date", j = c === "kpi", ve = Vn($), pe = s !== "pivotBy", mt = ze && s === "groupBy" && (!j || ((bn = f.config) == null ? void 0 : bn.comparisonType) === "start_vs_end"), ut = !j && ze && s === "groupBy", ht = c && Oo.includes(c) && ze && s === "groupBy", yt = c === "kpi" && ze && s === "groupBy", Je = c && c !== "pivotTable" && s === "metrics" && ((vn = f.config) == null ? void 0 : vn.comparisonType) === "target", Zt = s === "metrics", $t = () => /* @__PURE__ */ e(
13067
+ }, at = st(t.dataType), ze = at === "date", j = c === "kpi", ve = Bn($), pe = s !== "pivotBy", mt = ze && s === "groupBy" && (!j || ((Nn = f.config) == null ? void 0 : Nn.comparisonType) === "start_vs_end"), ut = !j && ze && s === "groupBy", ht = c && Oo.includes(c) && ze && s === "groupBy", yt = c === "kpi" && ze && s === "groupBy", Je = c && c !== "pivotTable" && s === "metrics" && ((Cn = f.config) == null ? void 0 : Cn.comparisonType) === "target", Zt = s === "metrics", $t = () => /* @__PURE__ */ e(
13028
13068
  "div",
13029
13069
  {
13030
13070
  title: `${t.entityName}.${t.name}`,
@@ -13098,7 +13138,7 @@ function cm({
13098
13138
  ] })
13099
13139
  ] })
13100
13140
  ] }) : null, Ae = () => {
13101
- var Oe, He, St, ca, Nn;
13141
+ var Oe, He, St, ca, Sn;
13102
13142
  const W = ht, Fe = yt;
13103
13143
  return !W && !Fe ? null : /* @__PURE__ */ a(Z, { children: [
13104
13144
  W && /* @__PURE__ */ a("div", { className: "space-y-1", children: [
@@ -13141,9 +13181,9 @@ function cm({
13141
13181
  min: "1",
13142
13182
  max: "365",
13143
13183
  value: ((ca = f.config) == null ? void 0 : ca.trendlineWindow) || 30,
13144
- onChange: (Fl) => {
13145
- const Ol = parseInt(Fl.target.value) || 30;
13146
- g(Ol);
13184
+ onChange: (Ol) => {
13185
+ const Pl = parseInt(Ol.target.value) || 30;
13186
+ g(Pl);
13147
13187
  },
13148
13188
  className: "h-8 text-xs",
13149
13189
  placeholder: "30"
@@ -13155,7 +13195,7 @@ function cm({
13155
13195
  /* @__PURE__ */ a(
13156
13196
  ne,
13157
13197
  {
13158
- value: ((Nn = f.config) == null ? void 0 : Nn.trendlineGranularity) || "day",
13198
+ value: ((Sn = f.config) == null ? void 0 : Sn.trendlineGranularity) || "day",
13159
13199
  onValueChange: x,
13160
13200
  children: [
13161
13201
  /* @__PURE__ */ e(re, { className: "h-8 w-full text-xs", children: /* @__PURE__ */ e(le, { placeholder: "Select granularity..." }) }),
@@ -13187,7 +13227,7 @@ function cm({
13187
13227
  }
13188
13228
  )
13189
13229
  ] }) : null;
13190
- }, Il = () => Zt ? /* @__PURE__ */ a(Z, { children: [
13230
+ }, El = () => Zt ? /* @__PURE__ */ a(Z, { children: [
13191
13231
  /* @__PURE__ */ a("div", { className: "space-y-1", children: [
13192
13232
  /* @__PURE__ */ e(G, { className: "text-xs font-medium text-muted-foreground", children: "Aggregation" }),
13193
13233
  /* @__PURE__ */ a(
@@ -13319,7 +13359,7 @@ function cm({
13319
13359
  }
13320
13360
  )
13321
13361
  ] })
13322
- ] }) : null, { columns: El = [] } = va(), Ml = (ue == null ? void 0 : ue.conditions) && ue.conditions.length > 0;
13362
+ ] }) : null, { columns: Ml = [] } = va(), Fl = (ue == null ? void 0 : ue.conditions) && ue.conditions.length > 0;
13323
13363
  return /* @__PURE__ */ a(Z, { children: [
13324
13364
  /* @__PURE__ */ a(
13325
13365
  "div",
@@ -13331,18 +13371,18 @@ function cm({
13331
13371
  className: `group mx-auto flex w-full flex-col gap-2 rounded border border-border bg-background p-2 transition-all hover:shadow-sm dark:border-gray-800 ${p ? "z-50 scale-95 opacity-50" : "border-slate-200"} ${s === "filters" ? "cursor-default" : "cursor-move"}`,
13332
13372
  children: [
13333
13373
  /* @__PURE__ */ a("div", { className: "flex grow items-center gap-2", children: [
13334
- /* @__PURE__ */ e(fn, { dataType: at }),
13374
+ /* @__PURE__ */ e(bn, { dataType: at }),
13335
13375
  /* @__PURE__ */ e(
13336
- hn,
13376
+ gn,
13337
13377
  {
13338
13378
  className: Y(
13339
13379
  "w-[140px] flex-1 text-sm",
13340
- Ml && "w-[120px]"
13380
+ Fl && "w-[120px]"
13341
13381
  ),
13342
13382
  children: Fo(t)
13343
13383
  }
13344
13384
  ),
13345
- s === "metrics" && ((yn = ue == null ? void 0 : ue.conditions) == null ? void 0 : yn.length) && !M && /* @__PURE__ */ e(Xe, { children: /* @__PURE__ */ a(Ie, { children: [
13385
+ s === "metrics" && ((wn = ue == null ? void 0 : ue.conditions) == null ? void 0 : wn.length) && !M && /* @__PURE__ */ e(Xe, { children: /* @__PURE__ */ a(Ie, { children: [
13346
13386
  /* @__PURE__ */ e(Ee, { asChild: !0, children: /* @__PURE__ */ a("div", { className: "flex items-center gap-1 rounded bg-primary/10 px-1.5 py-0.5 text-xs", children: [
13347
13387
  /* @__PURE__ */ e(Pa, { className: "h-3 w-3" }),
13348
13388
  /* @__PURE__ */ e("span", { children: ue.conditions.length })
@@ -13388,7 +13428,7 @@ function cm({
13388
13428
  Fe
13389
13429
  ), l(Fe);
13390
13430
  },
13391
- children: r === "asc" ? /* @__PURE__ */ e(Nr, { className: "h-3 w-3" }) : /* @__PURE__ */ e(Cr, { className: "h-3 w-3" })
13431
+ children: r === "asc" ? /* @__PURE__ */ e(Sr, { className: "h-3 w-3" }) : /* @__PURE__ */ e(kr, { className: "h-3 w-3" })
13392
13432
  }
13393
13433
  ),
13394
13434
  /* @__PURE__ */ e(
@@ -13411,7 +13451,7 @@ function cm({
13411
13451
  De(),
13412
13452
  Ae(),
13413
13453
  Gt(),
13414
- Il()
13454
+ El()
13415
13455
  ] })
13416
13456
  ]
13417
13457
  }
@@ -13423,7 +13463,7 @@ function cm({
13423
13463
  onOpenChange: (W) => {
13424
13464
  E(W), W || N(null);
13425
13465
  },
13426
- availableFields: El,
13466
+ availableFields: Ml,
13427
13467
  existingFilters: ue,
13428
13468
  editingCondition: D,
13429
13469
  onSave: (W) => {
@@ -13625,7 +13665,7 @@ function Aa({
13625
13665
  )
13626
13666
  ] });
13627
13667
  }
13628
- const Wn = [
13668
+ const Zn = [
13629
13669
  { value: "green", color: "#16a34a", label: "Green" },
13630
13670
  { value: "red", color: "#dc2626", label: "Red" },
13631
13671
  { value: "neutral", color: "#6b7280", label: "Neutral" }
@@ -13655,8 +13695,8 @@ function Ss({
13655
13695
  label: n
13656
13696
  }) {
13657
13697
  const [r, l] = R(!1), [i, c] = R(!1), o = () => {
13658
- const d = Wn.find((u) => u.value === t);
13659
- return d ? d.color : t.startsWith("#") ? t : Wn[2].color;
13698
+ const d = Zn.find((u) => u.value === t);
13699
+ return d ? d.color : t.startsWith("#") ? t : Zn[2].color;
13660
13700
  };
13661
13701
  return /* @__PURE__ */ a(Z, { children: [
13662
13702
  /* @__PURE__ */ a("div", { className: "flex items-center gap-2", children: [
@@ -13708,7 +13748,7 @@ function Ss({
13708
13748
  }
13709
13749
  ),
13710
13750
  /* @__PURE__ */ e("div", { className: "relative rounded-lg bg-white shadow-lg", children: /* @__PURE__ */ e(
13711
- Nl,
13751
+ Cl,
13712
13752
  {
13713
13753
  color: o(),
13714
13754
  onColorChange: (d) => {
@@ -13720,7 +13760,7 @@ function Ss({
13720
13760
  ] })
13721
13761
  ] });
13722
13762
  }
13723
- const Yn = {
13763
+ const er = {
13724
13764
  difference: {
13725
13765
  label: "Difference",
13726
13766
  description: "Shows the exact difference between two values.",
@@ -13801,7 +13841,7 @@ function mm() {
13801
13841
  /* @__PURE__ */ a(Ie, { children: [
13802
13842
  /* @__PURE__ */ e(Ee, { asChild: !0, children: /* @__PURE__ */ e(ia, { className: "h-3 w-3 cursor-help text-muted-foreground" }) }),
13803
13843
  /* @__PURE__ */ e(Re, { side: "right", className: "max-w-xs", children: (() => {
13804
- const g = o.calculationType || "difference", x = Yn[g];
13844
+ const g = o.calculationType || "difference", x = er[g];
13805
13845
  return /* @__PURE__ */ a("div", { className: "space-y-2 text-xs", children: [
13806
13846
  /* @__PURE__ */ e("div", { className: "text-sm font-semibold", children: x == null ? void 0 : x.label }),
13807
13847
  /* @__PURE__ */ e("p", { children: x == null ? void 0 : x.description }),
@@ -13828,13 +13868,13 @@ function mm() {
13828
13868
  }),
13829
13869
  children: [
13830
13870
  /* @__PURE__ */ e(re, { id: "calculation-type", className: "h-7 text-xs", children: /* @__PURE__ */ e(le, {}) }),
13831
- /* @__PURE__ */ e(ie, { children: Object.entries(Yn).map(([g, x]) => /* @__PURE__ */ e(Q, { value: g, className: "text-xs", children: x.label }, g)) })
13871
+ /* @__PURE__ */ e(ie, { children: Object.entries(er).map(([g, x]) => /* @__PURE__ */ e(Q, { value: g, className: "text-xs", children: x.label }, g)) })
13832
13872
  ]
13833
13873
  }
13834
13874
  )
13835
13875
  ] }),
13836
13876
  /* @__PURE__ */ e(
13837
- pn,
13877
+ xn,
13838
13878
  {
13839
13879
  formatOptions: o.formatOptions || {},
13840
13880
  onFormatOptionsChange: (g) => d({ formatOptions: g }),
@@ -14095,7 +14135,7 @@ function hm() {
14095
14135
  /* @__PURE__ */ e("span", { children: "Number Format" })
14096
14136
  ] }) }),
14097
14137
  /* @__PURE__ */ e(xe, { className: "space-y-4 pb-4 pt-2", children: /* @__PURE__ */ e(
14098
- pn,
14138
+ xn,
14099
14139
  {
14100
14140
  formatOptions: n,
14101
14141
  onFormatOptionsChange: (c) => {
@@ -14141,7 +14181,7 @@ function pm() {
14141
14181
  /* @__PURE__ */ e("span", { children: "Treemap Colors" })
14142
14182
  ] }) }),
14143
14183
  /* @__PURE__ */ e(xe, { className: "space-y-4 border-t border-border bg-background/50 px-3 py-4 text-sm", children: /* @__PURE__ */ a(
14144
- Ws,
14184
+ Ys,
14145
14185
  {
14146
14186
  value: r,
14147
14187
  onValueChange: (c) => l(c ?? "branch"),
@@ -14270,18 +14310,18 @@ function fm({
14270
14310
  ] }),
14271
14311
  !i && /* @__PURE__ */ a(fe, { value: "configuration", className: "border-b-0", children: [
14272
14312
  /* @__PURE__ */ e(ge, { className: "flex w-full items-center gap-2 py-2 text-sm font-medium hover:no-underline", children: /* @__PURE__ */ a("div", { className: "flex items-center gap-2", children: [
14273
- /* @__PURE__ */ e(_r, { className: "h-4 w-4 text-muted-foreground" }),
14313
+ /* @__PURE__ */ e(Jr, { className: "h-4 w-4 text-muted-foreground" }),
14274
14314
  /* @__PURE__ */ e("span", { children: "CONFIGURATION" })
14275
14315
  ] }) }),
14276
14316
  /* @__PURE__ */ e(xe, { className: "rounded-md border border-border bg-muted/50 px-3 py-0", children: /* @__PURE__ */ a(Ze, { type: "single", collapsible: !0, className: "w-full", children: [
14277
14317
  /* @__PURE__ */ e(hm, {}),
14278
14318
  /* @__PURE__ */ e(mm, {}),
14279
- /* @__PURE__ */ e(Cl, {}),
14280
- /* @__PURE__ */ e(pm, {}),
14281
- o === "bullet" && /* @__PURE__ */ e(Dl, {}),
14282
14319
  /* @__PURE__ */ e(wl, {}),
14320
+ /* @__PURE__ */ e(pm, {}),
14321
+ o === "bullet" && /* @__PURE__ */ e(Tl, {}),
14283
14322
  /* @__PURE__ */ e(Sl, {}),
14284
- /* @__PURE__ */ e(kl, {})
14323
+ /* @__PURE__ */ e(kl, {}),
14324
+ /* @__PURE__ */ e(Dl, {})
14285
14325
  ] }) })
14286
14326
  ] })
14287
14327
  ]
@@ -14382,12 +14422,12 @@ function gm({ onEditJoins: t }) {
14382
14422
  size: "sm",
14383
14423
  onClick: t,
14384
14424
  className: "h-7 gap-1 p-2 text-xs text-blue-700 hover:text-blue-900 dark:text-blue-300 dark:hover:text-blue-100",
14385
- children: /* @__PURE__ */ e(Ur, { className: "size-3.5" })
14425
+ children: /* @__PURE__ */ e(Kr, { className: "size-3.5" })
14386
14426
  }
14387
14427
  )
14388
14428
  ] }) });
14389
14429
  }
14390
- const Xn = {
14430
+ const tr = {
14391
14431
  getItem(t) {
14392
14432
  if (typeof window > "u") return null;
14393
14433
  try {
@@ -14415,7 +14455,7 @@ function xm({
14415
14455
  activeField: c
14416
14456
  }) {
14417
14457
  var g, x;
14418
- const [o, d] = R(() => Xn.getItem("chart-selector-expanded") === "true"), [u, m] = R(!1), h = T((C) => C.card), p = T(
14458
+ const [o, d] = R(() => tr.getItem("chart-selector-expanded") === "true"), [u, m] = R(!1), h = T((C) => C.card), p = T(
14419
14459
  (C) => C.actions.updateCardConfig
14420
14460
  ), f = n.length > 0 || r.length > 0 || l.length > 0, { data: v, autoJoinMetadata: b } = Me(h), y = ((g = h == null ? void 0 : h.config) == null ? void 0 : g.joinPlan) || (b != null && b.autoResolved ? b.resolvedJoinPlan : {
14421
14461
  baseEntity: {
@@ -14444,7 +14484,7 @@ function xm({
14444
14484
  m(!0);
14445
14485
  };
14446
14486
  he(() => {
14447
- Xn.setItem(
14487
+ tr.setItem(
14448
14488
  "chart-selector-expanded",
14449
14489
  String(o)
14450
14490
  );
@@ -14481,34 +14521,20 @@ function xm({
14481
14521
  )
14482
14522
  }
14483
14523
  ),
14484
- /* @__PURE__ */ a(
14524
+ /* @__PURE__ */ e(
14485
14525
  "div",
14486
14526
  {
14487
14527
  "data-content": "Chart Quick Selector",
14488
- className: "flex items-center justify-center gap-0.5",
14489
- children: [
14490
- /* @__PURE__ */ e(
14491
- am,
14492
- {
14493
- selectedChart: t,
14494
- onChartChange: s
14495
- }
14496
- ),
14497
- /* @__PURE__ */ a(Ie, { children: [
14498
- /* @__PURE__ */ e(Ee, { asChild: !0, children: /* @__PURE__ */ e(
14499
- q,
14500
- {
14501
- variant: "ghost",
14502
- size: "sm",
14503
- onClick: w,
14504
- className: "h-8 w-8 p-0",
14505
- "aria-label": o ? "Hide all charts" : "Show all charts",
14506
- children: o ? /* @__PURE__ */ e(ya, { className: "h-4 w-4" }) : /* @__PURE__ */ e(Rt, { className: "h-4 w-4" })
14507
- }
14508
- ) }),
14509
- /* @__PURE__ */ e(Re, { side: "bottom", children: /* @__PURE__ */ e("p", { children: o ? "Hide dropdown" : "Show all charts" }) })
14510
- ] })
14511
- ]
14528
+ className: "flex items-center justify-center",
14529
+ children: /* @__PURE__ */ e(
14530
+ am,
14531
+ {
14532
+ selectedChart: t,
14533
+ onChartChange: s,
14534
+ isDropdownExpanded: o,
14535
+ onToggleDropdown: w
14536
+ }
14537
+ )
14512
14538
  }
14513
14539
  )
14514
14540
  ]
@@ -14518,7 +14544,7 @@ function xm({
14518
14544
  "div",
14519
14545
  {
14520
14546
  className: Y("invisible flex gap-2", { visible: f || v }),
14521
- children: /* @__PURE__ */ e(on, {})
14547
+ children: /* @__PURE__ */ e(un, {})
14522
14548
  }
14523
14549
  ) }),
14524
14550
  /* @__PURE__ */ a(ct, { className: "w-full flex-1 basis-0 px-6 pb-6", children: [
@@ -14538,7 +14564,7 @@ function xm({
14538
14564
  /* @__PURE__ */ e(ha, { orientation: "horizontal" })
14539
14565
  ] }),
14540
14566
  /* @__PURE__ */ e(
14541
- Rs,
14567
+ zs,
14542
14568
  {
14543
14569
  open: u,
14544
14570
  onOpenChange: m,
@@ -14695,7 +14721,7 @@ function bm({
14695
14721
  }, k = (I, w, g) => {
14696
14722
  const x = (C) => C.id === I ? {
14697
14723
  ...C,
14698
- conditions: Es(C.conditions, w, g)
14724
+ conditions: Ms(C.conditions, w, g)
14699
14725
  } : {
14700
14726
  ...C,
14701
14727
  groups: C.groups.map(x)
@@ -14704,7 +14730,7 @@ function bm({
14704
14730
  }, A = (I, w, g) => {
14705
14731
  const x = (C) => C.id === I ? {
14706
14732
  ...C,
14707
- groups: Es(C.groups, w, g)
14733
+ groups: Ms(C.groups, w, g)
14708
14734
  } : {
14709
14735
  ...C,
14710
14736
  groups: C.groups.map(x)
@@ -14804,11 +14830,11 @@ const ym = (t) => {
14804
14830
  case "table":
14805
14831
  return /* @__PURE__ */ e(Ts, { className: "h-3 w-3" });
14806
14832
  case "view":
14807
- return /* @__PURE__ */ e(Gs, { className: "h-3 w-3" });
14833
+ return /* @__PURE__ */ e(Us, { className: "h-3 w-3" });
14808
14834
  case "dataset":
14809
- return /* @__PURE__ */ e(Js, { className: "h-3 w-3" });
14835
+ return /* @__PURE__ */ e(Hs, { className: "h-3 w-3" });
14810
14836
  case "file":
14811
- return /* @__PURE__ */ e(ar, { className: "h-3 w-3" });
14837
+ return /* @__PURE__ */ e(rr, { className: "h-3 w-3" });
14812
14838
  default:
14813
14839
  return /* @__PURE__ */ e(Ts, { className: "h-3 w-3" });
14814
14840
  }
@@ -14903,7 +14929,7 @@ function Cm({
14903
14929
  ] }) })
14904
14930
  ] });
14905
14931
  }
14906
- function gn(t) {
14932
+ function vn(t) {
14907
14933
  var b;
14908
14934
  const s = T((y) => y.card), { authToken: n, tokenProps: r } = je(), l = T((y) => y.card.config), i = l == null ? void 0 : l.joinPlan, c = {
14909
14935
  ...t,
@@ -14967,9 +14993,9 @@ function wm({
14967
14993
  placeholder: r = "Select items...",
14968
14994
  className: l
14969
14995
  }) {
14970
- const [i, c] = Os.useState(!1), {
14996
+ const [i, c] = Ps.useState(!1), {
14971
14997
  filterValues: o
14972
- } = gn(t), d = (m) => {
14998
+ } = vn(t), d = (m) => {
14973
14999
  n(s.filter((h) => h !== m));
14974
15000
  }, u = (m) => {
14975
15001
  s.includes(m) ? n(s.filter((h) => h !== m)) : n([...s, m]);
@@ -15046,7 +15072,7 @@ function Sm({
15046
15072
  placeholder: r = "Select value...",
15047
15073
  className: l
15048
15074
  }) {
15049
- const { filterValues: i, isPending: c, error: o } = gn(t);
15075
+ const { filterValues: i, isPending: c, error: o } = vn(t);
15050
15076
  return c ? /* @__PURE__ */ a("div", { className: "flex flex-1 items-center justify-center p-2 text-xs text-gray-500", children: [
15051
15077
  /* @__PURE__ */ e(Be, { className: "mr-2 size-3.5 animate-spin" }),
15052
15078
  " Loading values..."
@@ -15186,7 +15212,7 @@ const Dm = [
15186
15212
  isNotNull: "Is Not Null",
15187
15213
  "not between": "Not Between"
15188
15214
  };
15189
- function Zn(t) {
15215
+ function ar(t) {
15190
15216
  return Mm[t] || nt(t);
15191
15217
  }
15192
15218
  function Fm(t) {
@@ -15203,7 +15229,7 @@ function Fm(t) {
15203
15229
  return Dm;
15204
15230
  }
15205
15231
  }
15206
- function Tl({
15232
+ function Al({
15207
15233
  condition: t,
15208
15234
  index: s,
15209
15235
  groupId: n,
@@ -15221,7 +15247,7 @@ function Tl({
15221
15247
  transform: p,
15222
15248
  transition: f,
15223
15249
  isDragging: v
15224
- } = es({ id: t.id }), { isPending: b, error: y } = gn(
15250
+ } = es({ id: t.id }), { isPending: b, error: y } = vn(
15225
15251
  t.field
15226
15252
  ), k = {
15227
15253
  transform: ts.Transform.toString(p),
@@ -15240,7 +15266,7 @@ function Tl({
15240
15266
  ...u,
15241
15267
  ...m,
15242
15268
  className: "cursor-grab active:cursor-grabbing",
15243
- children: /* @__PURE__ */ e(rn, { className: "h-4 w-4 flex-shrink-0 text-gray-400" })
15269
+ children: /* @__PURE__ */ e(cn, { className: "h-4 w-4 flex-shrink-0 text-gray-400" })
15244
15270
  }
15245
15271
  ),
15246
15272
  s > 0 && /* @__PURE__ */ a(
@@ -15293,9 +15319,9 @@ function Tl({
15293
15319
  });
15294
15320
  },
15295
15321
  children: [
15296
- /* @__PURE__ */ e(re, { className: "w-32", children: /* @__PURE__ */ e(le, { children: t.operator ? Zn(t.operator) : "" }) }),
15322
+ /* @__PURE__ */ e(re, { className: "w-32", children: /* @__PURE__ */ e(le, { children: t.operator ? ar(t.operator) : "" }) }),
15297
15323
  /* @__PURE__ */ e(ie, { children: Fm(st(t.field.dataType)).map(
15298
- (A) => /* @__PURE__ */ e(Q, { className: "hover:bg-muted", value: A, children: Zn(A) }, A)
15324
+ (A) => /* @__PURE__ */ e(Q, { className: "hover:bg-muted", value: A, children: ar(A) }, A)
15299
15325
  ) })
15300
15326
  ]
15301
15327
  }
@@ -15447,7 +15473,7 @@ function Om({
15447
15473
  ...y,
15448
15474
  ...k,
15449
15475
  className: "cursor-grab active:cursor-grabbing",
15450
- children: /* @__PURE__ */ e(rn, { className: "h-4 w-4 text-muted-foreground" })
15476
+ children: /* @__PURE__ */ e(cn, { className: "h-4 w-4 text-muted-foreground" })
15451
15477
  }
15452
15478
  ),
15453
15479
  /* @__PURE__ */ e(
@@ -15493,8 +15519,8 @@ function Om({
15493
15519
  {
15494
15520
  sensors: Ra(
15495
15521
  Kt(za),
15496
- Kt(Fs, {
15497
- coordinateGetter: Ms
15522
+ Kt(Os, {
15523
+ coordinateGetter: Fs
15498
15524
  })
15499
15525
  ),
15500
15526
  collisionDetection: na,
@@ -15505,7 +15531,7 @@ function Om({
15505
15531
  items: t.conditions.map((C) => C.id),
15506
15532
  strategy: aa,
15507
15533
  children: t.conditions.map((C, M) => /* @__PURE__ */ e(
15508
- Tl,
15534
+ Al,
15509
15535
  {
15510
15536
  condition: C,
15511
15537
  index: M,
@@ -15529,8 +15555,8 @@ function Om({
15529
15555
  {
15530
15556
  sensors: Ra(
15531
15557
  Kt(za),
15532
- Kt(Fs, {
15533
- coordinateGetter: Ms
15558
+ Kt(Os, {
15559
+ coordinateGetter: Fs
15534
15560
  })
15535
15561
  ),
15536
15562
  collisionDetection: na,
@@ -15609,8 +15635,8 @@ function Pm({
15609
15635
  availableFields: s
15610
15636
  }), I = Ra(
15611
15637
  Kt(za),
15612
- Kt(Fs, {
15613
- coordinateGetter: Ms
15638
+ Kt(Os, {
15639
+ coordinateGetter: Fs
15614
15640
  })
15615
15641
  ), [w, g] = R(!1), x = (S, L, E) => {
15616
15642
  const D = (N) => N.id === S ? {
@@ -15648,7 +15674,7 @@ function Pm({
15648
15674
  items: S.conditions.map((D) => D.id),
15649
15675
  strategy: aa,
15650
15676
  children: S.conditions.map((D, N) => /* @__PURE__ */ e(
15651
- Tl,
15677
+ Al,
15652
15678
  {
15653
15679
  condition: D,
15654
15680
  index: N,
@@ -15744,7 +15770,7 @@ function Pm({
15744
15770
  updateConditionFields: f
15745
15771
  },
15746
15772
  S.id
15747
- ), M = Jr(t);
15773
+ ), M = Hr(t);
15748
15774
  return /* @__PURE__ */ a("div", { className: "space-y-4", children: [
15749
15775
  /* @__PURE__ */ e(Wt, { children: /* @__PURE__ */ e(as, { className: "p-4", children: /* @__PURE__ */ a("div", { className: "space-y-4", children: [
15750
15776
  o ? /* @__PURE__ */ a("div", { className: "flex items-center justify-center p-4", children: [
@@ -15839,7 +15865,7 @@ function Vm({
15839
15865
  var y, k;
15840
15866
  const [l, i] = R(null), c = T((A) => A.card), o = T(
15841
15867
  (A) => A.actions.updateCardConfig
15842
- ), d = (y = c == null ? void 0 : c.config) == null ? void 0 : y.joinPlan, u = (k = c == null ? void 0 : c.dataSource) == null ? void 0 : k.semanticDomainId, { data: m } = cn(u), h = [
15868
+ ), d = (y = c == null ? void 0 : c.config) == null ? void 0 : y.joinPlan, u = (k = c == null ? void 0 : c.dataSource) == null ? void 0 : k.semanticDomainId, { data: m } = mn(u), h = [
15843
15869
  ...s,
15844
15870
  ...n("groupBy"),
15845
15871
  ...n("pivotBy"),
@@ -15934,7 +15960,7 @@ function Vm({
15934
15960
  }
15935
15961
  if (F !== M.qualifiedEntityName && M.qualifiedEntityName)
15936
15962
  if (u && (m != null && m.joinabilityMap)) {
15937
- if (br(M, {
15963
+ if (Nr(M, {
15938
15964
  joinabilityMap: m.joinabilityMap,
15939
15965
  selectedFields: S,
15940
15966
  baseEntityName: (C = d == null ? void 0 : d.baseEntity) == null ? void 0 : C.name
@@ -15981,7 +16007,7 @@ function Vm({
15981
16007
  x,
15982
16008
  L
15983
16009
  ), N = [...L, D];
15984
- i(null), r(x, N), x === "metrics" && t && Vs(
16010
+ i(null), r(x, N), x === "metrics" && t && Rs(
15985
16011
  c.type,
15986
16012
  c.config,
15987
16013
  o,
@@ -16022,7 +16048,7 @@ function Vm({
16022
16048
  const N = M.filter(
16023
16049
  (P) => P.id !== I
16024
16050
  ), F = [...S, D];
16025
- r(g, N), r(x, F), x === "metrics" && t && Vs(
16051
+ r(g, N), r(x, F), x === "metrics" && t && Rs(
16026
16052
  c.type,
16027
16053
  c.config,
16028
16054
  o,
@@ -16035,7 +16061,7 @@ function Vm({
16035
16061
  if (g && x && g === x && g !== "source") {
16036
16062
  const M = n(g), S = M.findIndex((E) => E.id === I), L = M.findIndex((E) => E.id === w);
16037
16063
  if (S !== L) {
16038
- const E = Es(M, S, L);
16064
+ const E = Ms(M, S, L);
16039
16065
  r(g, E);
16040
16066
  }
16041
16067
  }
@@ -16160,7 +16186,7 @@ function jm({
16160
16186
  sortState: o,
16161
16187
  splitViewEnabled: d
16162
16188
  }) {
16163
- return !d || t.type === "table" ? /* @__PURE__ */ e(zs, {}) : /* @__PURE__ */ a(
16189
+ return !d || t.type === "table" ? /* @__PURE__ */ e(Bs, {}) : /* @__PURE__ */ a(
16164
16190
  Ft,
16165
16191
  {
16166
16192
  direction: "vertical",
@@ -16173,7 +16199,7 @@ function jm({
16173
16199
  minSize: 30,
16174
16200
  role: "chart-section",
16175
16201
  className: "flex flex-col pb-3",
16176
- children: /* @__PURE__ */ e(zs, {})
16202
+ children: /* @__PURE__ */ e(Bs, {})
16177
16203
  }
16178
16204
  ),
16179
16205
  /* @__PURE__ */ e(Ot, { withHandle: !0 }),
@@ -16210,7 +16236,7 @@ function Gm({
16210
16236
  isOpen: t,
16211
16237
  onClose: s
16212
16238
  }) {
16213
- const n = al(s, {
16239
+ const n = sl(s, {
16214
16240
  enabled: t
16215
16241
  }), r = T(
16216
16242
  (m) => {
@@ -16227,7 +16253,7 @@ function Gm({
16227
16253
  var h;
16228
16254
  return ((h = m.card.customCardPreferences) == null ? void 0 : h.settings) || {};
16229
16255
  }
16230
- ), { data: o } = Me(l), { getCard: d } = Ys(r), u = qe(() => !r || r.trim() === "" ? null : d("Chart Settings"), [d, r]);
16256
+ ), { data: o } = Me(l), { getCard: d } = Xs(r), u = qe(() => !r || r.trim() === "" ? null : d("Chart Settings"), [d, r]);
16231
16257
  return /* @__PURE__ */ e(
16232
16258
  "div",
16233
16259
  {
@@ -16253,7 +16279,7 @@ function Gm({
16253
16279
  }
16254
16280
  )
16255
16281
  ] }),
16256
- /* @__PURE__ */ e("div", { className: "h-full min-h-0 flex-1", children: u && /* @__PURE__ */ e(Yr, { fallback: /* @__PURE__ */ e("div", { children: "Loading chart settings..." }), children: /* @__PURE__ */ e(
16282
+ /* @__PURE__ */ e("div", { className: "h-full min-h-0 flex-1", children: u && /* @__PURE__ */ e(Xr, { fallback: /* @__PURE__ */ e("div", { children: "Loading chart settings..." }), children: /* @__PURE__ */ e(
16257
16283
  u,
16258
16284
  {
16259
16285
  chartData: (o == null ? void 0 : o.records) || [],
@@ -16354,7 +16380,7 @@ function Um({
16354
16380
  }
16355
16381
  const be = (ae) => {
16356
16382
  if (!u.config) return;
16357
- const me = Mr(
16383
+ const me = Pr(
16358
16384
  ae,
16359
16385
  u.config.metricColumns,
16360
16386
  u.config.groupByColumns
@@ -16378,7 +16404,7 @@ function Um({
16378
16404
  /* @__PURE__ */ a("div", { className: "group/visualization relative flex h-full max-w-full grow flex-col pt-4", children: [
16379
16405
  /* @__PURE__ */ a("div", { className: "flex items-center gap-2 px-6", children: [
16380
16406
  /* @__PURE__ */ a("div", { className: "flex items-center justify-between gap-2", children: [
16381
- t === "chart" && b && /* @__PURE__ */ e(fl, { variant: "outline" }),
16407
+ t === "chart" && b && /* @__PURE__ */ e(gl, { variant: "outline" }),
16382
16408
  /* @__PURE__ */ e(
16383
16409
  Rm,
16384
16410
  {
@@ -16392,7 +16418,7 @@ function Um({
16392
16418
  {
16393
16419
  cardId: i.id,
16394
16420
  cardFilters: (ue = i.config) == null ? void 0 : ue.filters,
16395
- cardFilterCount: Jr(
16421
+ cardFilterCount: Hr(
16396
16422
  ((H = i.config) == null ? void 0 : H.filters) || null
16397
16423
  ),
16398
16424
  onFiltersClick: l
@@ -16406,7 +16432,7 @@ function Um({
16406
16432
  }
16407
16433
  ),
16408
16434
  /* @__PURE__ */ e("div", { className: "ml-2", children: /* @__PURE__ */ e(Bm, {}) }),
16409
- b && /* @__PURE__ */ e(on, {})
16435
+ b && /* @__PURE__ */ e(un, {})
16410
16436
  ] }),
16411
16437
  /* @__PURE__ */ a("div", { className: Y("flex grow items-center justify-end gap-2"), children: [
16412
16438
  /* @__PURE__ */ e(
@@ -16418,7 +16444,7 @@ function Um({
16418
16444
  U(!0), K();
16419
16445
  },
16420
16446
  children: /* @__PURE__ */ e(
16421
- jr,
16447
+ $r,
16422
16448
  {
16423
16449
  className: Y("h-4 w-4", {
16424
16450
  "animate-spin": z
@@ -16435,7 +16461,7 @@ function Um({
16435
16461
  children: C ? /* @__PURE__ */ e(Ac, { className: "size-4" }) : /* @__PURE__ */ e(Uc, { className: "size-4" })
16436
16462
  }
16437
16463
  ),
16438
- t === "chart" && /* @__PURE__ */ e(gl, {}),
16464
+ t === "chart" && /* @__PURE__ */ e(xl, {}),
16439
16465
  !b && /* @__PURE__ */ e(
16440
16466
  ke,
16441
16467
  {
@@ -16443,10 +16469,10 @@ function Um({
16443
16469
  tooltip: "AI",
16444
16470
  className: "h-8",
16445
16471
  "aria-label": "AI",
16446
- children: /* @__PURE__ */ e(Hs, { className: "size-4" })
16472
+ children: /* @__PURE__ */ e(Qs, { className: "size-4" })
16447
16473
  }
16448
16474
  ),
16449
- r && qr
16475
+ r && Gr
16450
16476
  ] })
16451
16477
  ] }),
16452
16478
  !k && S && /* @__PURE__ */ e(
@@ -16456,7 +16482,7 @@ function Um({
16456
16482
  tooltip: "Open Chart Settings",
16457
16483
  onClick: () => A(!0),
16458
16484
  className: "absolute right-5 top-1/2 z-40 size-10 -translate-y-1/2 rounded-full border border-border bg-background shadow-lg hover:bg-muted focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
16459
- children: /* @__PURE__ */ e(_r, { className: "size-4" })
16485
+ children: /* @__PURE__ */ e(Jr, { className: "size-4" })
16460
16486
  }
16461
16487
  ),
16462
16488
  /* @__PURE__ */ a("div", { className: "mt-3 flex min-h-0 grow flex-col", children: [
@@ -16495,13 +16521,13 @@ function Um({
16495
16521
  }
16496
16522
  ) }),
16497
16523
  t === "info" && x && /* @__PURE__ */ e("div", { className: "flex min-h-0 flex-1 flex-col pb-6", children: /* @__PURE__ */ e("div", { className: "flex min-h-0 flex-1 flex-col rounded-md bg-background px-6", children: E ? /* @__PURE__ */ e(
16498
- mn,
16524
+ fn,
16499
16525
  {
16500
16526
  error: E,
16501
16527
  errorSql: F,
16502
16528
  onSendFeedback: () => {
16503
16529
  const ae = Ko(
16504
- Tr.QUERY_GENERATION,
16530
+ Er.QUERY_GENERATION,
16505
16531
  {
16506
16532
  cardConfig: u.config,
16507
16533
  dataSource: i.dataSource,
@@ -16525,7 +16551,7 @@ function Um({
16525
16551
  ) : (
16526
16552
  /* Show normal SQL display when there's no error */
16527
16553
  /* @__PURE__ */ e(
16528
- dl,
16554
+ ul,
16529
16555
  {
16530
16556
  sql: L == null ? void 0 : L.sql,
16531
16557
  error: E,
@@ -16542,7 +16568,7 @@ function Um({
16542
16568
  }
16543
16569
  ),
16544
16570
  I && /* @__PURE__ */ e(
16545
- Er,
16571
+ Or,
16546
16572
  {
16547
16573
  open: V,
16548
16574
  onOpenChange: O,
@@ -16563,8 +16589,8 @@ function Km({ activeField: t }) {
16563
16589
  {
16564
16590
  className: `flex max-w-[300px] items-center gap-2 rounded-lg border border-blue-500 bg-background p-2 shadow-lg transition-all duration-200 ${s ? "scale-100 opacity-100" : "scale-95 opacity-0"}`,
16565
16591
  children: [
16566
- /* @__PURE__ */ e(rn, { className: "h-3 w-3 shrink-0 text-muted-foreground" }),
16567
- /* @__PURE__ */ e(fn, { dataType: t.dataType }),
16592
+ /* @__PURE__ */ e(cn, { className: "h-3 w-3 shrink-0 text-muted-foreground" }),
16593
+ /* @__PURE__ */ e(bn, { dataType: t.dataType }),
16568
16594
  /* @__PURE__ */ e("span", { className: "overflow-hidden text-ellipsis whitespace-nowrap text-sm dark:text-muted-foreground", children: t.label || t.name })
16569
16595
  ]
16570
16596
  }
@@ -16622,7 +16648,7 @@ function Jm() {
16622
16648
  ), x = v, {
16623
16649
  getFieldsForContainer: C,
16624
16650
  setFieldsForContainer: M
16625
- } = dn(x), { activeField: S, handleDragStart: L, handleDragEnd: E } = Vm({
16651
+ } = hn(x), { activeField: S, handleDragStart: L, handleDragEnd: E } = Vm({
16626
16652
  activeCardId: f.activeCardId,
16627
16653
  sourceFields: O,
16628
16654
  getFieldsForContainer: C,
@@ -16654,7 +16680,7 @@ function Jm() {
16654
16680
  children: [
16655
16681
  /* @__PURE__ */ a("div", { className: "flex h-full grow", children: [
16656
16682
  /* @__PURE__ */ e(
16657
- cl,
16683
+ dl,
16658
16684
  {
16659
16685
  isVisible: c,
16660
16686
  onToggleVisibility: () => o(!c)
@@ -16684,7 +16710,7 @@ function Jm() {
16684
16710
  onFiltersClick: () => i(!0),
16685
16711
  filterCount: K,
16686
16712
  activeCard: x,
16687
- dataSourceState: v.dataSource || Kr,
16713
+ dataSourceState: v.dataSource || _r,
16688
16714
  columns: O,
16689
16715
  columnsLoading: I,
16690
16716
  columnsError: w,
@@ -16731,7 +16757,7 @@ function Hm({ authToken: t, onSave: s, onClose: n }) {
16731
16757
  d("editor", w);
16732
16758
  },
16733
16759
  [d]
16734
- ), { setAuthToken: v } = et(), { setShowAIDialog: b, setOnSave: y, setOnClose: k } = ee(), { setActiveAssistantType: A } = Gr();
16760
+ ), { setAuthToken: v } = et(), { setShowAIDialog: b, setOnSave: y, setOnClose: k } = ee(), { setActiveAssistantType: A } = Ur();
16735
16761
  he(() => {
16736
16762
  s && y(s), n && k(n);
16737
16763
  }, [s, y, n, k]), he(() => {
@@ -16751,7 +16777,7 @@ function Hm({ authToken: t, onSave: s, onClose: n }) {
16751
16777
  }
16752
16778
  function O() {
16753
16779
  return /* @__PURE__ */ a(Z, { children: [
16754
- /* @__PURE__ */ e(cl, { isVisible: !0, onToggleVisibility: () => {
16780
+ /* @__PURE__ */ e(dl, { isVisible: !0, onToggleVisibility: () => {
16755
16781
  } }),
16756
16782
  /* @__PURE__ */ a("div", { className: "relative flex grow border-l", children: [
16757
16783
  /* @__PURE__ */ a(
@@ -16775,7 +16801,7 @@ function Hm({ authToken: t, onSave: s, onClose: n }) {
16775
16801
  defaultSize: u.isOpen ? 40 : 0,
16776
16802
  className: "flex",
16777
16803
  children: /* @__PURE__ */ e("div", { className: "grow overflow-y-auto", children: /* @__PURE__ */ e(
16778
- Jn,
16804
+ Wn,
16779
16805
  {
16780
16806
  isFullscreen: p,
16781
16807
  onFullscreenChange: (w) => c(w ? "editor" : null),
@@ -16823,7 +16849,7 @@ function Hm({ authToken: t, onSave: s, onClose: n }) {
16823
16849
  defaultSize: u.isOpen ? 40 : 0,
16824
16850
  className: "flex",
16825
16851
  children: /* @__PURE__ */ e("div", { className: "grow overflow-y-auto", children: /* @__PURE__ */ e(
16826
- Jn,
16852
+ Wn,
16827
16853
  {
16828
16854
  isFullscreen: p,
16829
16855
  onFullscreenChange: (w) => c(w ? "editor" : null),
@@ -16847,7 +16873,7 @@ function Hm({ authToken: t, onSave: s, onClose: n }) {
16847
16873
  )
16848
16874
  ] });
16849
16875
  }
16850
- return /* @__PURE__ */ e(Na, { FallbackComponent: Hr, children: i ? /* @__PURE__ */ e(
16876
+ return /* @__PURE__ */ e(Na, { FallbackComponent: Qr, children: i ? /* @__PURE__ */ e(
16851
16877
  "section",
16852
16878
  {
16853
16879
  className: "isolate flex h-full grow",
@@ -16877,7 +16903,7 @@ function Qm() {
16877
16903
  );
16878
16904
  }
16879
16905
  function Wm() {
16880
- ol();
16906
+ cl();
16881
16907
  const t = J((d) => d.selectedSheetId), s = J((d) => d.selectedFrameId), n = J((d) => d.dashboard), r = J((d) => d.actions.getSelectedFrame), { setSelectedFrameId: l } = et(), { setCard: i } = ee(), c = T((d) => d.card.dataSource);
16882
16908
  return he(() => {
16883
16909
  var u, m;
@@ -16907,7 +16933,7 @@ function Ym() {
16907
16933
  onClick: () => t(!1),
16908
16934
  className: "h-7 w-7 p-0",
16909
16935
  variant: "ghost",
16910
- children: /* @__PURE__ */ e(qs, {})
16936
+ children: /* @__PURE__ */ e(Gs, {})
16911
16937
  }
16912
16938
  )
16913
16939
  ] }),
@@ -16916,7 +16942,7 @@ function Ym() {
16916
16942
  /* @__PURE__ */ e("h3", { className: "mb-2 text-sm font-medium text-foreground", children: "No fields configured" }),
16917
16943
  /* @__PURE__ */ e("p", { className: "text-xs text-muted-foreground", children: "Please configure a data source for this card to enable filtering" })
16918
16944
  ] }),
16919
- s && /* @__PURE__ */ e("div", { className: "flex grow", children: /* @__PURE__ */ e(sa, { collisionDetection: na, children: /* @__PURE__ */ e(ta, { items: [], strategy: aa, children: /* @__PURE__ */ e(il, { context: "filter" }) }) }) })
16945
+ s && /* @__PURE__ */ e("div", { className: "flex grow", children: /* @__PURE__ */ e(sa, { collisionDetection: na, children: /* @__PURE__ */ e(ta, { items: [], strategy: aa, children: /* @__PURE__ */ e(ol, { context: "filter" }) }) }) })
16920
16946
  ] });
16921
16947
  }
16922
16948
  function Xm() {
@@ -16933,8 +16959,8 @@ function Xm() {
16933
16959
  {
16934
16960
  className: "flex min-w-[250px] max-w-fit flex-col gap-1 p-2",
16935
16961
  children: [
16936
- /* @__PURE__ */ e($r, { filter: r }),
16937
- /* @__PURE__ */ e(Ir, { filter: r })
16962
+ /* @__PURE__ */ e(qr, { filter: r }),
16963
+ /* @__PURE__ */ e(Fr, { filter: r })
16938
16964
  ]
16939
16965
  },
16940
16966
  r.id
@@ -17025,7 +17051,7 @@ function eh() {
17025
17051
  }
17026
17052
  );
17027
17053
  }
17028
- function Al() {
17054
+ function Il() {
17029
17055
  return /* @__PURE__ */ e(ct, { className: "w-full flex-1", children: /* @__PURE__ */ a("div", { className: "space-y-4 px-4 py-2", children: [
17030
17056
  /* @__PURE__ */ e("div", { className: "h-9 w-full rounded bg-muted animate-pulse" }),
17031
17057
  /* @__PURE__ */ e("div", { className: "h-9 w-full rounded bg-muted animate-pulse" }),
@@ -17056,7 +17082,7 @@ function ah({
17056
17082
  formatDate: u
17057
17083
  }) {
17058
17084
  var I, w, g, x;
17059
- const { selectVisual: m } = xa(), h = Xo(t.id), p = th(t.id), { isConsoleMode: f } = Us(), v = ga.useRef(null), [b, y] = R(!1), [k, A] = R(!1);
17085
+ const { selectVisual: m } = xa(), h = Xo(t.id), p = th(t.id), { isConsoleMode: f } = Ks(), v = ga.useRef(null), [b, y] = R(!1), [k, A] = R(!1);
17060
17086
  he(() => {
17061
17087
  n ? (y(!0), A(!0)) : k && (y(!1), A(!1));
17062
17088
  }, [n, k]), he(() => {
@@ -17135,7 +17161,7 @@ function ah({
17135
17161
  C.stopPropagation(), i == null || i(t);
17136
17162
  },
17137
17163
  title: "Edit details",
17138
- children: /* @__PURE__ */ e(Rn, { className: "h-3 w-3" })
17164
+ children: /* @__PURE__ */ e(jn, { className: "h-3 w-3" })
17139
17165
  }
17140
17166
  ),
17141
17167
  /* @__PURE__ */ a(
@@ -17192,7 +17218,7 @@ function ah({
17192
17218
  C.stopPropagation(), i == null || i(t);
17193
17219
  },
17194
17220
  children: [
17195
- /* @__PURE__ */ e(Rn, { className: "mr-2 h-3 w-3" }),
17221
+ /* @__PURE__ */ e(jn, { className: "mr-2 h-3 w-3" }),
17196
17222
  "Edit details"
17197
17223
  ]
17198
17224
  }
@@ -17372,7 +17398,7 @@ function nh() {
17372
17398
  startUpdating: P,
17373
17399
  stopUpdating: K,
17374
17400
  isUpdating: B
17375
- } = Qr(), z = (H, ae, me) => {
17401
+ } = Wr(), z = (H, ae, me) => {
17376
17402
  var _;
17377
17403
  const $e = Object.fromEntries(
17378
17404
  Object.entries(ae).filter(([, oe]) => oe !== void 0)
@@ -17433,7 +17459,7 @@ function nh() {
17433
17459
  }
17434
17460
  });
17435
17461
  };
17436
- return O ? /* @__PURE__ */ e(Al, {}) : I ? /* @__PURE__ */ e(ct, { className: "w-full flex-1 pr-2", children: /* @__PURE__ */ a("div", { className: "py-8 text-center text-muted-foreground", children: [
17462
+ return O ? /* @__PURE__ */ e(Il, {}) : I ? /* @__PURE__ */ e(ct, { className: "w-full flex-1 pr-2", children: /* @__PURE__ */ a("div", { className: "py-8 text-center text-muted-foreground", children: [
17437
17463
  /* @__PURE__ */ e("p", { className: "text-sm text-destructive", children: "Failed to load visuals" }),
17438
17464
  /* @__PURE__ */ e(
17439
17465
  q,
@@ -17490,7 +17516,7 @@ function nh() {
17490
17516
  H.id
17491
17517
  )) }) }),
17492
17518
  l && c && /* @__PURE__ */ e(
17493
- _s,
17519
+ Js,
17494
17520
  {
17495
17521
  resource: c,
17496
17522
  resourceType: da.VISUAL,
@@ -17500,7 +17526,7 @@ function nh() {
17500
17526
  }
17501
17527
  ),
17502
17528
  v && /* @__PURE__ */ e(
17503
- Wr,
17529
+ Yr,
17504
17530
  {
17505
17531
  open: !!v,
17506
17532
  resourceLabel: "Visual",
@@ -17658,7 +17684,7 @@ function ih(t) {
17658
17684
  ), g = pt(
17659
17685
  (j) => j.actions.clearSelectedDashboard
17660
17686
  ), { tokenProps: x, id: C } = je();
17661
- Ks();
17687
+ _s();
17662
17688
  const { onCreateSuccess: M } = ic({
17663
17689
  onDashboardSelect: r
17664
17690
  }), {
@@ -17710,7 +17736,7 @@ function ih(t) {
17710
17736
  startUpdating: me,
17711
17737
  stopUpdating: $e,
17712
17738
  isUpdating: tt
17713
- } = Qr(), Ke = (j, ve, pe) => {
17739
+ } = Wr(), Ke = (j, ve, pe) => {
17714
17740
  var yt;
17715
17741
  const mt = Object.fromEntries(
17716
17742
  Object.entries(ve).filter(([, Je]) => Je !== void 0)
@@ -17765,7 +17791,7 @@ function ih(t) {
17765
17791
  }
17766
17792
  });
17767
17793
  };
17768
- return L ? /* @__PURE__ */ e(Al, {}) : E ? /* @__PURE__ */ e(lh, { onRetry: () => window.location.reload() }) : /* @__PURE__ */ a("div", { className: "relative flex h-full flex-1 flex-col gap-4", children: [
17794
+ return L ? /* @__PURE__ */ e(Il, {}) : E ? /* @__PURE__ */ e(lh, { onRetry: () => window.location.reload() }) : /* @__PURE__ */ a("div", { className: "relative flex h-full flex-1 flex-col gap-4", children: [
17769
17795
  S && S.length > 5 && /* @__PURE__ */ e("div", { className: "space-y-2", children: /* @__PURE__ */ e(
17770
17796
  Le,
17771
17797
  {
@@ -17777,7 +17803,7 @@ function ih(t) {
17777
17803
  }
17778
17804
  ) }),
17779
17805
  /* @__PURE__ */ e("div", { className: "flex flex-1 flex-col", children: /* @__PURE__ */ e("div", { className: "flex flex-1 basis-0 flex-col gap-3 overflow-y-auto", children: de.length === 0 ? /* @__PURE__ */ a("div", { className: "py-8 text-center", children: [
17780
- /* @__PURE__ */ e("div", { className: "mb-3", children: /* @__PURE__ */ e(Js, { className: "mx-auto h-12 w-12 text-muted-foreground/50" }) }),
17806
+ /* @__PURE__ */ e("div", { className: "mb-3", children: /* @__PURE__ */ e(Hs, { className: "mx-auto h-12 w-12 text-muted-foreground/50" }) }),
17781
17807
  /* @__PURE__ */ e("h3", { className: "mb-1 font-medium text-foreground", children: l ? "No dashboards found" : "No dashboards yet" }),
17782
17808
  /* @__PURE__ */ e("p", { className: "mb-4 text-sm text-muted-foreground", children: l ? "Try adjusting your search" : X ? "Create your first dashboard to get started" : "No dashboards have been shared with you yet" }),
17783
17809
  X && !l && /* @__PURE__ */ a(
@@ -17810,7 +17836,7 @@ function ih(t) {
17810
17836
  j.id
17811
17837
  )) }) }),
17812
17838
  d && m && /* @__PURE__ */ e(
17813
- _s,
17839
+ Js,
17814
17840
  {
17815
17841
  resource: m,
17816
17842
  resourceType: da.DASHBOARD,
@@ -17856,7 +17882,7 @@ function ih(t) {
17856
17882
  }
17857
17883
  ),
17858
17884
  A && /* @__PURE__ */ e(
17859
- Wr,
17885
+ Yr,
17860
17886
  {
17861
17887
  open: !!A,
17862
17888
  resourceLabel: "Dashboard",
@@ -17900,10 +17926,10 @@ function oh({
17900
17926
  (w) => w.actions
17901
17927
  ), {
17902
17928
  currentUser: d
17903
- } = Vt(), u = d, { permissions: m } = Ks(), p = dc() && m.canAccessVisuals && i, f = "dashboards", [v, b] = gs(
17929
+ } = Vt(), u = d, { permissions: m } = _s(), p = dc() && m.canAccessVisuals && i, f = "dashboards", [v, b] = gs(
17904
17930
  "resource-management-active-tab",
17905
17931
  f
17906
- ), y = p ? v : "dashboards", k = l === "overlay", A = al(s, {
17932
+ ), y = p ? v : "dashboards", k = l === "overlay", A = sl(s, {
17907
17933
  enabled: t && k
17908
17934
  }), V = Y(
17909
17935
  "flex h-full flex-col border-r bg-background",
@@ -17990,7 +18016,7 @@ function hh({
17990
18016
  u.current && m.current && (r ? (u.current.resize(i), m.current.resize(100 - i)) : (u.current.resize(0), m.current.resize(100)));
17991
18017
  }, [r]);
17992
18018
  const { preferences: h } = n;
17993
- return /* @__PURE__ */ e(Na, { FallbackComponent: Hr, children: /* @__PURE__ */ a(uc, { dashboardProps: n, children: [
18019
+ return /* @__PURE__ */ e(Na, { FallbackComponent: Qr, children: /* @__PURE__ */ a(uc, { dashboardProps: n, children: [
17994
18020
  /* @__PURE__ */ e(mc, {}),
17995
18021
  /* @__PURE__ */ e(hc, { children: /* @__PURE__ */ a(pc, { preferences: h, children: [
17996
18022
  /* @__PURE__ */ e(eh, {}),
@@ -18057,5 +18083,5 @@ export {
18057
18083
  rd as S,
18058
18084
  Md as V,
18059
18085
  Xc as c,
18060
- Ps as g
18086
+ Ls as g
18061
18087
  };