react-semaphor 0.1.288 → 0.1.289

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.
Files changed (27) hide show
  1. package/dist/chunks/{dashboard-controls-BiW05-mC.js → dashboard-controls-BZpyFg-k.js} +4 -4
  2. package/dist/chunks/{dashboard-controls-Zmrx1YI2.js → dashboard-controls-Dsh15H8E.js} +1 -1
  3. package/dist/chunks/{dashboard-filter-controls-button-7f-bvHT_.js → dashboard-filter-controls-button-CG5DgZpQ.js} +3 -3
  4. package/dist/chunks/{dashboard-filter-controls-button-BRd93sFp.js → dashboard-filter-controls-button-DJvp8skg.js} +1 -1
  5. package/dist/chunks/{dashboard-json-B98ND-fr.js → dashboard-json-CPhdiaLF.js} +1 -1
  6. package/dist/chunks/{dashboard-json-Co1UgUNw.js → dashboard-json-cootX4Nq.js} +1 -1
  7. package/dist/chunks/{dashboard-summary-settings-dialog-XvwdRn2n.js → dashboard-summary-settings-dialog-DOaMWikr.js} +1 -1
  8. package/dist/chunks/{dashboard-summary-settings-dialog-CcNH2IIt.js → dashboard-summary-settings-dialog-F6Dl15za.js} +1 -1
  9. package/dist/chunks/{edit-dashboard-visual-DcTqSs2k.js → edit-dashboard-visual-DIpn7oJy.js} +505 -529
  10. package/dist/chunks/{edit-dashboard-visual-DBvH4PxE.js → edit-dashboard-visual-fAiZdiCV.js} +28 -33
  11. package/dist/chunks/{index-J8IvoGB3.js → index-Cab2h5Fi.js} +1917 -1915
  12. package/dist/chunks/{index-COoAiuFD.js → index-CnmC-NR5.js} +38 -38
  13. package/dist/chunks/{resource-management-panel-B1q16xjI.js → resource-management-panel-AZ46U35q.js} +2 -2
  14. package/dist/chunks/{resource-management-panel-C37Ddk0o.js → resource-management-panel-gJirpIDQ.js} +1 -1
  15. package/dist/chunks/{use-create-flow-overlay-state-DkquwAuI.js → use-create-flow-overlay-state-3oPHFeIs.js} +1 -1
  16. package/dist/chunks/{use-create-flow-overlay-state-sPNLNhJR.js → use-create-flow-overlay-state-B6yjr4UZ.js} +2 -2
  17. package/dist/chunks/{use-visual-utils-CzoNgtEf.js → use-visual-utils-CyzOMb7j.js} +1 -1
  18. package/dist/chunks/{use-visual-utils-DMRRNJY1.js → use-visual-utils-DmENJikx.js} +1 -1
  19. package/dist/dashboard/index.cjs +1 -1
  20. package/dist/dashboard/index.js +1 -1
  21. package/dist/index.cjs +1 -1
  22. package/dist/index.js +5 -5
  23. package/dist/surfboard/index.cjs +1 -1
  24. package/dist/surfboard/index.js +2 -2
  25. package/dist/types/main.d.ts +5 -0
  26. package/dist/types/types.d.ts +5 -0
  27. package/package.json +1 -1
@@ -1,9 +1,9 @@
1
1
  import { jsxs as a, jsx as e, Fragment as Ne } from "react/jsx-runtime";
2
- import { bM as ze, x as ut, M as xe, U as F, e7 as ni, e8 as Fo, L as z, y as te, z as ae, A as ne, E as se, F as j, ac as We, B as H, ct as St, e9 as Qn, ea as si, eb as ri, ec as li, ed as ii, ee as Jn, a6 as Et, X as nt, ef as Ys, ch as Yn, d as pa, e as fa, f as ga, g as xa, h as Ba, bZ as Nt, bW as xt, bT as yt, bU as mt, bV as ht, eg as cl, eh as Ro, ei as oi, v as _n, ej as za, cP as Ja, c as W, cc as wt, ek as ci, el as vs, cB as di, em as Lo, en as Po, eo as Vo, ep as un, eq as Bo, er as ui, es as zo, H as Wn, C as Xn, et as _o, eu as $o, u as Me, ev as qt, ew as Pa, cC as Ya, cD as Wa, ex as zs, cF as Xa, cG as dt, ey as _a, ez as qo, eA as _s, eB as Ln, b as wa, ag as mi, e6 as mn, eC as Ws, eD as jo, eE as Ko, eF as hi, eG as pi, eH as fi, dG as Xs, dE as Go, I as De, P as Tt, eI as Uo, l as kt, eJ as Ho, w as la, eK as Qo, eL as Jo, eM as Yo, bN as Za, bO as Sa, bP as Ta, bQ as xn, bR as Gt, bS as Va, eN as $s, eO as Ht, eP as ct, eQ as Qt, dm as ba, eR as gi, eS as $n, eT as qn, eU as jn, eV as Zs, eW as xi, eX as Wo, eY as Xo, eZ as Zo, k as bi, e_ as ec, e$ as tc, f0 as ac, f1 as nc, f2 as vi, f3 as sc, f4 as ys, f5 as rc, f6 as dl, f7 as lc, f8 as ul, f9 as er, fa as ic, fb as bn, fc as oc, R as vn, fd as Zn, fe as en, cQ as tr, ff as yi, i as ia, fg as cc, cn as Pt, co as _t, fh as dc, cp as $t, c$ as ar, db as nr, N as Ni, fi as sr, fj as uc, fk as Ci, fl as wi, fm as zt, d$ as Ns, fn as mc, fo as hc, fp as pc, fq as Si, ax as Ti, fr as ki, fs as fc, ft as gc, fu as xc, fv as hn, fw as bc, fx as vc, fy as ml, fz as yc, Z as es, a4 as rr, fA as Nc, fB as lr, dr as Cc, fC as hl, a7 as pt, fD as wc, dN as ir, dO as or, dP as ma, dQ as Pn, fE as Sc, e0 as Tc, fF as Ii, fG as kc, fH as Ic, d4 as ts, fI as Dc, fJ as Ac, fK as pl, fL as Ec, j as Ot, dc as va, ds as as, cK as Lt, fM as ea, fN as ya, fO as Na, fP as oa, fQ as $a, fR as Oc, fS as Mc, b2 as Fc, fT as Rc, fU as Lc, fV as Pc, fW as Vc, da as ha, fX as Bc, fY as Di, fZ as zc, f_ as _c, f$ as $c, g0 as Ai, dH as fl, c6 as qc, cd as Ut, dj as jc, g1 as Kc, g2 as Gc, g3 as Uc, g4 as gl, g5 as Hc, g6 as Qc, g7 as Jc, g8 as Yc, af as Wc, dp as Xc, g9 as Zc, ga as Ei, gb as ed, gc as td, gd as ad, ge as nd, gf as sd, gg as rd, gh as qs, gi as ld, gj as id, gk as od, gl as js, gm as cd, gn as dd, go as ud, gp as md, gq as xl, gr as hd, gs as bl, gt as vl, dd as Ks, cS as pd, gu as fd, cT as gd, cU as xd, cV as bd, cW as vd, cX as yd, cY as Nd, cZ as Cd, gv as tn, gw as wd, S as Ge, gx as Sd, gy as Td, gz as Oi, cE as cr, de as kd, cH as Id, gA as Dd, gB as Ad, gC as pn, gD as Kn, gE as Ed, gF as qa, gG as qe, gH as je, gI as Ke, gJ as Od, gK as Md, gL as Mi, gM as Fi, gN as aa, gO as On, gP as yl, gQ as Fd, dn as Ri, gR as Rd, gS as Ld, gT as Pd, gU as yn, gV as Vd, gW as Bd, gX as zd, m as ja, n as Ka, o as Ga, p as Ua, q as Ha, r as Qa, gY as _d, gZ as $d, g_ as Nl, g$ as qd, s as ka, h0 as jd, h1 as Cs, h2 as Cl, h3 as Kd, h4 as At, h5 as Gd, h6 as Ud, h7 as Hd, h8 as Qd, h9 as Jd, ha as ws, hb as Li, hc as Yd, hd as Wd, he as Xd, hf as Gn, hg as Zd, hh as eu, hi as dr, hj as ur, hk as Pi, hl as tu, d2 as Vi, hm as Bi, hn as zi, ho as au, e5 as nu, hp as Ze, hq as su, bg as ru, hr as Mn, hs as lu, ht as wl, hu as iu, hv as ou, bc as Sl, hw as Tl, hx as cu, hy as du, hz as uu, hA as mu, hB as hu, hC as pu, hD as fu, hE as gu, hF as xu, hG as bu, hH as vu, hI as yu, hJ as Nu, hK as Cu, hL as _i, hM as wu, hN as Su, hO as Tu, hP as ku, hQ as Iu, hR as Du, hS as Au, hT as Eu, hU as Ou, hV as Mu, hW as Fu, hX as $i, hY as Ru, hZ as mr, h_ as ns, h$ as qi, i0 as Lu, i1 as Pu, i2 as Vu, i3 as Bu, i4 as zu, i5 as _u, i6 as ss, i7 as Ss, i8 as $u, i9 as qu, ia as ju, ib as Ku, ic as Gu, id as kl, ie as Ca, ig as Uu, ih as ji, ii as Ki, ij as Gs, ik as Gi, il as Il, d6 as Dl, im as Hu, io as Qu, ip as Ju, iq as Vn, ir as Yu, is as hr, it as Wu, iu as Xu, iv as Un, iw as Zu, ix as em, iy as tm, iz as fn, iA as na, iB as Us, iC as Hs, iD as gn, iE as Ui, aY as am, iF as nm, iG as Ts, iH as ks, iI as sm, iJ as Is, iK as rm, iL as Al, iM as El, iN as lm, iO as im, iP as om, iQ as cm, iR as dm, iS as um, iT as rs, cM as ls, iU as is, iV as Ol, iW as Hi, dW as Ds, iX as mm, iY as hm, iZ as pm, _ as fm } from "./index-J8IvoGB3.js";
2
+ import { bM as _e, x as ut, M as xe, U as F, e7 as ni, e8 as Fo, L as z, y as te, z as ae, A as ne, E as se, F as j, ac as We, B as H, ct as St, e9 as Qn, ea as si, eb as ri, ec as li, ed as ii, ee as Jn, a6 as Et, X as nt, ef as Ys, ch as Yn, d as pa, e as fa, f as ga, g as xa, h as Ba, bZ as Nt, bW as gt, bT as yt, bU as mt, bV as ht, eg as cl, eh as Ro, ei as oi, v as _n, ej as za, cP as Ja, c as W, cc as wt, ek as ci, el as vs, cB as di, em as Lo, en as Po, eo as Vo, ep as un, eq as Bo, er as ui, es as zo, H as Wn, C as Xn, et as _o, eu as $o, u as Me, ev as qt, ew as Pa, cC as Ya, cD as Wa, ex as zs, cF as Xa, cG as dt, ey as _a, ez as qo, eA as _s, eB as Ln, b as wa, ag as mi, e6 as mn, eC as Ws, eD as jo, eE as Ko, eF as hi, eG as pi, eH as fi, dG as Xs, dE as Go, I as De, P as Tt, eI as Uo, l as kt, eJ as Ho, w as la, eK as Qo, eL as Jo, eM as Yo, bN as Za, bO as Sa, bP as Ta, bQ as xn, bR as Gt, bS as Va, eN as $s, eO as Ht, eP as ct, eQ as Qt, dm as ba, eR as gi, eS as $n, eT as qn, eU as jn, eV as Zs, eW as xi, eX as Wo, eY as Xo, eZ as Zo, k as bi, e_ as ec, e$ as tc, f0 as ac, f1 as nc, f2 as vi, f3 as sc, f4 as ys, f5 as rc, f6 as dl, f7 as lc, f8 as ul, f9 as er, fa as ic, fb as bn, fc as oc, R as vn, fd as Zn, fe as en, cQ as tr, ff as yi, i as ia, fg as cc, cn as Pt, co as _t, fh as dc, cp as $t, c$ as ar, db as nr, N as Ni, fi as sr, fj as uc, fk as Ci, fl as wi, fm as zt, d$ as Ns, fn as mc, fo as hc, fp as pc, fq as Si, ax as Ti, fr as ki, fs as fc, ft as gc, fu as xc, fv as hn, fw as bc, fx as vc, fy as ml, fz as yc, Z as es, a4 as rr, fA as Nc, fB as lr, dr as Cc, fC as hl, a7 as xt, fD as wc, dN as ir, dO as or, dP as ma, dQ as Pn, fE as Sc, e0 as Tc, fF as Ii, fG as kc, fH as Ic, d4 as ts, fI as Dc, fJ as Ac, fK as pl, fL as Ec, j as Ot, dc as va, ds as as, cK as Lt, fM as ea, fN as ya, fO as Na, fP as oa, fQ as $a, fR as Oc, fS as Mc, b2 as Fc, fT as Rc, fU as Lc, fV as Pc, fW as Vc, da as ha, fX as Bc, fY as Di, fZ as zc, f_ as _c, f$ as $c, g0 as Ai, dH as fl, c6 as qc, cd as Ut, dj as jc, g1 as Kc, g2 as Gc, g3 as Uc, g4 as gl, g5 as Hc, g6 as Qc, g7 as Jc, g8 as Yc, af as Wc, dp as Xc, g9 as Zc, ga as Ei, gb as ed, gc as td, gd as ad, ge as nd, gf as sd, gg as rd, gh as qs, gi as ld, gj as id, gk as od, gl as js, gm as cd, gn as dd, go as ud, gp as md, gq as xl, gr as hd, gs as bl, gt as vl, dd as Ks, cS as pd, gu as fd, cT as gd, cU as xd, cV as bd, cW as vd, cX as yd, cY as Nd, cZ as Cd, gv as tn, gw as wd, S as Ge, gx as Sd, gy as Td, gz as Oi, cE as cr, de as kd, cH as Id, gA as Dd, gB as Ad, gC as pn, gD as Kn, gE as Ed, gF as qa, gG as qe, gH as je, gI as Ke, gJ as Od, gK as Md, gL as Mi, gM as Fi, gN as aa, gO as On, gP as yl, gQ as Fd, dn as Ri, gR as Rd, gS as Ld, gT as Pd, gU as yn, gV as Vd, gW as Bd, gX as zd, m as ja, n as Ka, o as Ga, p as Ua, q as Ha, r as Qa, gY as _d, gZ as $d, g_ as Nl, g$ as qd, s as ka, h0 as jd, h1 as Cs, h2 as Cl, h3 as Kd, h4 as At, h5 as Gd, h6 as Ud, h7 as Hd, h8 as Qd, h9 as Jd, ha as ws, hb as Li, hc as Yd, hd as Wd, he as Xd, hf as Gn, hg as Zd, hh as eu, hi as dr, hj as ur, hk as Pi, hl as tu, d2 as Vi, hm as Bi, hn as zi, ho as au, e5 as nu, hp as Ze, hq as su, bg as ru, hr as Mn, hs as lu, ht as wl, hu as iu, hv as ou, bc as Sl, hw as Tl, hx as cu, hy as du, hz as uu, hA as mu, hB as hu, hC as pu, hD as fu, hE as gu, hF as xu, hG as bu, hH as vu, hI as yu, hJ as Nu, hK as Cu, hL as _i, hM as wu, hN as Su, hO as Tu, hP as ku, hQ as Iu, hR as Du, hS as Au, hT as Eu, hU as Ou, hV as Mu, hW as Fu, hX as $i, hY as Ru, hZ as mr, h_ as ns, h$ as qi, i0 as Lu, i1 as Pu, i2 as Vu, i3 as Bu, i4 as zu, i5 as _u, i6 as ss, i7 as Ss, i8 as $u, i9 as qu, ia as ju, ib as Ku, ic as Gu, id as kl, ie as Ca, ig as Uu, ih as ji, ii as Ki, ij as Gs, ik as Gi, il as Il, d6 as Dl, im as Hu, io as Qu, ip as Ju, iq as Vn, ir as Yu, is as hr, it as Wu, iu as Xu, iv as Un, iw as Zu, ix as em, iy as tm, iz as fn, iA as na, iB as Us, iC as Hs, iD as gn, iE as Ui, aY as am, iF as nm, iG as Ts, iH as ks, iI as sm, iJ as Is, iK as rm, iL as Al, iM as El, iN as lm, iO as im, iP as om, iQ as cm, iR as dm, iS as um, iT as rs, cM as ls, iU as is, iV as Ol, iW as Hi, dW as Ds, iX as mm, iY as hm, iZ as pm, _ as fm } from "./index-Cab2h5Fi.js";
3
3
  import * as Bn from "react";
4
4
  import ta, { useState as G, useRef as Ie, useCallback as ke, useEffect as Ce, useMemo as oe, useContext as pr, Suspense as gm } from "react";
5
- import { r as Qi, f as Nn } from "./use-visual-utils-CzoNgtEf.js";
6
- import { f as bt, C as Ml, g as fr, V as Ji, u as xm, e as bm } from "./use-create-flow-overlay-state-sPNLNhJR.js";
5
+ import { r as Qi, f as Nn } from "./use-visual-utils-CyzOMb7j.js";
6
+ import { f as bt, C as Ml, g as fr, V as Ji, u as xm, e as bm } from "./use-create-flow-overlay-state-B6yjr4UZ.js";
7
7
  import { createPortal as vm } from "react-dom";
8
8
  /**
9
9
  * @license lucide-react v0.453.0 - ISC
@@ -11,7 +11,7 @@ import { createPortal as vm } from "react-dom";
11
11
  * This source code is licensed under the ISC license.
12
12
  * See the LICENSE file in the root directory of this source tree.
13
13
  */
14
- const ym = ze("ArrowDownAZ", [
14
+ const ym = _e("ArrowDownAZ", [
15
15
  ["path", { d: "m3 16 4 4 4-4", key: "1co6wj" }],
16
16
  ["path", { d: "M7 20V4", key: "1yoxec" }],
17
17
  ["path", { d: "M20 8h-5", key: "1vsyxs" }],
@@ -24,7 +24,7 @@ const ym = ze("ArrowDownAZ", [
24
24
  * This source code is licensed under the ISC license.
25
25
  * See the LICENSE file in the root directory of this source tree.
26
26
  */
27
- const Nm = ze("ArrowUpAZ", [
27
+ const Nm = _e("ArrowUpAZ", [
28
28
  ["path", { d: "m3 8 4-4 4 4", key: "11wl7u" }],
29
29
  ["path", { d: "M7 4v16", key: "1glfcx" }],
30
30
  ["path", { d: "M20 8h-5", key: "1vsyxs" }],
@@ -37,7 +37,7 @@ const Nm = ze("ArrowUpAZ", [
37
37
  * This source code is licensed under the ISC license.
38
38
  * See the LICENSE file in the root directory of this source tree.
39
39
  */
40
- const Yi = ze("Blocks", [
40
+ const Yi = _e("Blocks", [
41
41
  ["rect", { width: "7", height: "7", x: "14", y: "3", rx: "1", key: "6d4xhi" }],
42
42
  [
43
43
  "path",
@@ -53,21 +53,7 @@ const Yi = ze("Blocks", [
53
53
  * This source code is licensed under the ISC license.
54
54
  * See the LICENSE file in the root directory of this source tree.
55
55
  */
56
- const Cm = ze("Bot", [
57
- ["path", { d: "M12 8V4H8", key: "hb8ula" }],
58
- ["rect", { width: "16", height: "12", x: "4", y: "8", rx: "2", key: "enze0r" }],
59
- ["path", { d: "M2 14h2", key: "vft8re" }],
60
- ["path", { d: "M20 14h2", key: "4cs60a" }],
61
- ["path", { d: "M15 13v2", key: "1xurst" }],
62
- ["path", { d: "M9 13v2", key: "rq6x2g" }]
63
- ]);
64
- /**
65
- * @license lucide-react v0.453.0 - ISC
66
- *
67
- * This source code is licensed under the ISC license.
68
- * See the LICENSE file in the root directory of this source tree.
69
- */
70
- const wm = ze("Braces", [
56
+ const Cm = _e("Braces", [
71
57
  [
72
58
  "path",
73
59
  { d: "M8 3H7a2 2 0 0 0-2 2v5a2 2 0 0 1-2 2 2 2 0 0 1 2 2v5c0 1.1.9 2 2 2h1", key: "ezmyqa" }
@@ -86,7 +72,7 @@ const wm = ze("Braces", [
86
72
  * This source code is licensed under the ISC license.
87
73
  * See the LICENSE file in the root directory of this source tree.
88
74
  */
89
- const gr = ze("Columns3", [
75
+ const gr = _e("Columns3", [
90
76
  ["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2", key: "afitv7" }],
91
77
  ["path", { d: "M9 3v18", key: "fh3hqa" }],
92
78
  ["path", { d: "M15 3v18", key: "14nvp0" }]
@@ -97,7 +83,7 @@ const gr = ze("Columns3", [
97
83
  * This source code is licensed under the ISC license.
98
84
  * See the LICENSE file in the root directory of this source tree.
99
85
  */
100
- const Sm = ze("Component", [
86
+ const wm = _e("Component", [
101
87
  [
102
88
  "path",
103
89
  {
@@ -133,7 +119,7 @@ const Sm = ze("Component", [
133
119
  * This source code is licensed under the ISC license.
134
120
  * See the LICENSE file in the root directory of this source tree.
135
121
  */
136
- const Wi = ze("FileCode2", [
122
+ const Wi = _e("FileCode2", [
137
123
  ["path", { d: "M4 22h14a2 2 0 0 0 2-2V7l-5-5H6a2 2 0 0 0-2 2v4", key: "1pf5j1" }],
138
124
  ["path", { d: "M14 2v4a2 2 0 0 0 2 2h4", key: "tnqrlb" }],
139
125
  ["path", { d: "m5 12-3 3 3 3", key: "oke12k" }],
@@ -145,7 +131,7 @@ const Wi = ze("FileCode2", [
145
131
  * This source code is licensed under the ISC license.
146
132
  * See the LICENSE file in the root directory of this source tree.
147
133
  */
148
- const Tm = ze("FileJson2", [
134
+ const Sm = _e("FileJson2", [
149
135
  ["path", { d: "M4 22h14a2 2 0 0 0 2-2V7l-5-5H6a2 2 0 0 0-2 2v4", key: "1pf5j1" }],
150
136
  ["path", { d: "M14 2v4a2 2 0 0 0 2 2h4", key: "tnqrlb" }],
151
137
  [
@@ -163,7 +149,7 @@ const Tm = ze("FileJson2", [
163
149
  * This source code is licensed under the ISC license.
164
150
  * See the LICENSE file in the root directory of this source tree.
165
151
  */
166
- const km = ze("Fullscreen", [
152
+ const Tm = _e("Fullscreen", [
167
153
  ["path", { d: "M3 7V5a2 2 0 0 1 2-2h2", key: "aa7l1z" }],
168
154
  ["path", { d: "M17 3h2a2 2 0 0 1 2 2v2", key: "4qcy5o" }],
169
155
  ["path", { d: "M21 17v2a2 2 0 0 1-2 2h-2", key: "6vwrx8" }],
@@ -176,7 +162,7 @@ const km = ze("Fullscreen", [
176
162
  * This source code is licensed under the ISC license.
177
163
  * See the LICENSE file in the root directory of this source tree.
178
164
  */
179
- const Xi = ze("GitCompareArrows", [
165
+ const Xi = _e("GitCompareArrows", [
180
166
  ["circle", { cx: "5", cy: "6", r: "3", key: "1qnov2" }],
181
167
  ["path", { d: "M12 6h5a2 2 0 0 1 2 2v7", key: "1yj91y" }],
182
168
  ["path", { d: "m15 9-3-3 3-3", key: "1lwv8l" }],
@@ -190,7 +176,7 @@ const Xi = ze("GitCompareArrows", [
190
176
  * This source code is licensed under the ISC license.
191
177
  * See the LICENSE file in the root directory of this source tree.
192
178
  */
193
- const Im = ze("Hammer", [
179
+ const km = _e("Hammer", [
194
180
  ["path", { d: "m15 12-8.373 8.373a1 1 0 1 1-3-3L12 9", key: "eefl8a" }],
195
181
  ["path", { d: "m18 15 4-4", key: "16gjal" }],
196
182
  [
@@ -207,7 +193,7 @@ const Im = ze("Hammer", [
207
193
  * This source code is licensed under the ISC license.
208
194
  * See the LICENSE file in the root directory of this source tree.
209
195
  */
210
- const Dm = ze("LayoutList", [
196
+ const Im = _e("LayoutList", [
211
197
  ["rect", { width: "7", height: "7", x: "3", y: "3", rx: "1", key: "1g98yp" }],
212
198
  ["rect", { width: "7", height: "7", x: "3", y: "14", rx: "1", key: "1bb6yr" }],
213
199
  ["path", { d: "M14 4h7", key: "3xa0d5" }],
@@ -221,7 +207,7 @@ const Dm = ze("LayoutList", [
221
207
  * This source code is licensed under the ISC license.
222
208
  * See the LICENSE file in the root directory of this source tree.
223
209
  */
224
- const Am = ze("ListEnd", [
210
+ const Dm = _e("ListEnd", [
225
211
  ["path", { d: "M16 12H3", key: "1a2rj7" }],
226
212
  ["path", { d: "M16 6H3", key: "1wxfjs" }],
227
213
  ["path", { d: "M10 18H3", key: "13769t" }],
@@ -234,7 +220,7 @@ const Am = ze("ListEnd", [
234
220
  * This source code is licensed under the ISC license.
235
221
  * See the LICENSE file in the root directory of this source tree.
236
222
  */
237
- const Fl = ze("ListFilter", [
223
+ const Fl = _e("ListFilter", [
238
224
  ["path", { d: "M3 6h18", key: "d0wm0j" }],
239
225
  ["path", { d: "M7 12h10", key: "b7w52i" }],
240
226
  ["path", { d: "M10 18h4", key: "1ulq68" }]
@@ -245,7 +231,7 @@ const Fl = ze("ListFilter", [
245
231
  * This source code is licensed under the ISC license.
246
232
  * See the LICENSE file in the root directory of this source tree.
247
233
  */
248
- const Em = ze("ListStart", [
234
+ const Am = _e("ListStart", [
249
235
  ["path", { d: "M16 12H3", key: "1a2rj7" }],
250
236
  ["path", { d: "M16 18H3", key: "12xzn7" }],
251
237
  ["path", { d: "M10 6H3", key: "lf8lx7" }],
@@ -258,7 +244,7 @@ const Em = ze("ListStart", [
258
244
  * This source code is licensed under the ISC license.
259
245
  * See the LICENSE file in the root directory of this source tree.
260
246
  */
261
- const Om = ze("ListX", [
247
+ const Em = _e("ListX", [
262
248
  ["path", { d: "M11 12H3", key: "51ecnj" }],
263
249
  ["path", { d: "M16 6H3", key: "1wxfjs" }],
264
250
  ["path", { d: "M16 18H3", key: "12xzn7" }],
@@ -271,7 +257,7 @@ const Om = ze("ListX", [
271
257
  * This source code is licensed under the ISC license.
272
258
  * See the LICENSE file in the root directory of this source tree.
273
259
  */
274
- const As = ze("MoveHorizontal", [
260
+ const As = _e("MoveHorizontal", [
275
261
  ["path", { d: "m18 8 4 4-4 4", key: "1ak13k" }],
276
262
  ["path", { d: "M2 12h20", key: "9i4pu4" }],
277
263
  ["path", { d: "m6 8-4 4 4 4", key: "15zrgr" }]
@@ -282,7 +268,7 @@ const As = ze("MoveHorizontal", [
282
268
  * This source code is licensed under the ISC license.
283
269
  * See the LICENSE file in the root directory of this source tree.
284
270
  */
285
- const Es = ze("MoveVertical", [
271
+ const Es = _e("MoveVertical", [
286
272
  ["path", { d: "M12 2v20", key: "t6zp3m" }],
287
273
  ["path", { d: "m8 18 4 4 4-4", key: "bh5tu3" }],
288
274
  ["path", { d: "m8 6 4-4 4 4", key: "ybng9g" }]
@@ -293,7 +279,7 @@ const Es = ze("MoveVertical", [
293
279
  * This source code is licensed under the ISC license.
294
280
  * See the LICENSE file in the root directory of this source tree.
295
281
  */
296
- const Mm = ze("Palette", [
282
+ const Om = _e("Palette", [
297
283
  ["circle", { cx: "13.5", cy: "6.5", r: ".5", fill: "currentColor", key: "1okk4w" }],
298
284
  ["circle", { cx: "17.5", cy: "10.5", r: ".5", fill: "currentColor", key: "f64h9f" }],
299
285
  ["circle", { cx: "8.5", cy: "7.5", r: ".5", fill: "currentColor", key: "fotxhn" }],
@@ -312,7 +298,7 @@ const Mm = ze("Palette", [
312
298
  * This source code is licensed under the ISC license.
313
299
  * See the LICENSE file in the root directory of this source tree.
314
300
  */
315
- const Fm = ze("PanelRightClose", [
301
+ const Mm = _e("PanelRightClose", [
316
302
  ["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2", key: "afitv7" }],
317
303
  ["path", { d: "M15 3v18", key: "14nvp0" }],
318
304
  ["path", { d: "m8 9 3 3-3 3", key: "12hl5m" }]
@@ -323,7 +309,7 @@ const Fm = ze("PanelRightClose", [
323
309
  * This source code is licensed under the ISC license.
324
310
  * See the LICENSE file in the root directory of this source tree.
325
311
  */
326
- const Rm = ze("PanelRight", [
312
+ const Fm = _e("PanelRight", [
327
313
  ["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2", key: "afitv7" }],
328
314
  ["path", { d: "M15 3v18", key: "14nvp0" }]
329
315
  ]);
@@ -333,7 +319,7 @@ const Rm = ze("PanelRight", [
333
319
  * This source code is licensed under the ISC license.
334
320
  * See the LICENSE file in the root directory of this source tree.
335
321
  */
336
- const Qs = ze("RotateCcw", [
322
+ const Qs = _e("RotateCcw", [
337
323
  ["path", { d: "M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8", key: "1357e3" }],
338
324
  ["path", { d: "M3 3v5h5", key: "1xhq8a" }]
339
325
  ]);
@@ -343,7 +329,7 @@ const Qs = ze("RotateCcw", [
343
329
  * This source code is licensed under the ISC license.
344
330
  * See the LICENSE file in the root directory of this source tree.
345
331
  */
346
- const os = ze("Rows3", [
332
+ const os = _e("Rows3", [
347
333
  ["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2", key: "afitv7" }],
348
334
  ["path", { d: "M21 9H3", key: "1338ky" }],
349
335
  ["path", { d: "M21 15H3", key: "9uk58r" }]
@@ -354,7 +340,7 @@ const os = ze("Rows3", [
354
340
  * This source code is licensed under the ISC license.
355
341
  * See the LICENSE file in the root directory of this source tree.
356
342
  */
357
- const Lm = ze("SendHorizontal", [
343
+ const Rm = _e("SendHorizontal", [
358
344
  [
359
345
  "path",
360
346
  {
@@ -370,7 +356,7 @@ const Lm = ze("SendHorizontal", [
370
356
  * This source code is licensed under the ISC license.
371
357
  * See the LICENSE file in the root directory of this source tree.
372
358
  */
373
- const Pm = ze("Shapes", [
359
+ const Lm = _e("Shapes", [
374
360
  [
375
361
  "path",
376
362
  {
@@ -387,7 +373,7 @@ const Pm = ze("Shapes", [
387
373
  * This source code is licensed under the ISC license.
388
374
  * See the LICENSE file in the root directory of this source tree.
389
375
  */
390
- const Vm = ze("Sigma", [
376
+ const Pm = _e("Sigma", [
391
377
  [
392
378
  "path",
393
379
  {
@@ -402,7 +388,7 @@ const Vm = ze("Sigma", [
402
388
  * This source code is licensed under the ISC license.
403
389
  * See the LICENSE file in the root directory of this source tree.
404
390
  */
405
- const Bm = ze("Spline", [
391
+ const Vm = _e("Spline", [
406
392
  ["circle", { cx: "19", cy: "5", r: "2", key: "mhkx31" }],
407
393
  ["circle", { cx: "5", cy: "19", r: "2", key: "v8kfzx" }],
408
394
  ["path", { d: "M5 17A12 12 0 0 1 17 5", key: "1okkup" }]
@@ -413,7 +399,7 @@ const Bm = ze("Spline", [
413
399
  * This source code is licensed under the ISC license.
414
400
  * See the LICENSE file in the root directory of this source tree.
415
401
  */
416
- const zm = ze("SquareFunction", [
402
+ const Bm = _e("SquareFunction", [
417
403
  ["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2", ry: "2", key: "1m3agn" }],
418
404
  ["path", { d: "M9 17c2 0 2.8-1 2.8-2.8V10c0-2 1-3.3 3.2-3", key: "m1af9g" }],
419
405
  ["path", { d: "M9 11.2h5.7", key: "3zgcl2" }]
@@ -424,7 +410,7 @@ const zm = ze("SquareFunction", [
424
410
  * This source code is licensed under the ISC license.
425
411
  * See the LICENSE file in the root directory of this source tree.
426
412
  */
427
- const _m = ze("SquareSplitVertical", [
413
+ const zm = _e("SquareSplitVertical", [
428
414
  ["path", { d: "M5 8V5c0-1 1-2 2-2h10c1 0 2 1 2 2v3", key: "1pi83i" }],
429
415
  ["path", { d: "M19 16v3c0 1-1 2-2 2H7c-1 0-2-1-2-2v-3", key: "ido5k7" }],
430
416
  ["line", { x1: "4", x2: "20", y1: "12", y2: "12", key: "1e0a9i" }]
@@ -435,7 +421,7 @@ const _m = ze("SquareSplitVertical", [
435
421
  * This source code is licensed under the ISC license.
436
422
  * See the LICENSE file in the root directory of this source tree.
437
423
  */
438
- const $m = ze("Tags", [
424
+ const _m = _e("Tags", [
439
425
  ["path", { d: "m15 5 6.3 6.3a2.4 2.4 0 0 1 0 3.4L17 19", key: "1cbfv1" }],
440
426
  [
441
427
  "path",
@@ -452,7 +438,7 @@ const $m = ze("Tags", [
452
438
  * This source code is licensed under the ISC license.
453
439
  * See the LICENSE file in the root directory of this source tree.
454
440
  */
455
- const qm = ze("Wand", [
441
+ const $m = _e("Wand", [
456
442
  ["path", { d: "M15 4V2", key: "z1p9b7" }],
457
443
  ["path", { d: "M15 16v-2", key: "px0unx" }],
458
444
  ["path", { d: "M8 9h2", key: "1g203m" }],
@@ -497,7 +483,7 @@ function Zi({
497
483
  );
498
484
  return { value: c, onChange: h, flush: f };
499
485
  }
500
- function jm({
486
+ function qm({
501
487
  initialJoinPlan: t,
502
488
  availableDataSources: s
503
489
  }) {
@@ -794,7 +780,7 @@ ${A.joinType} JOIN ${b.name}
794
780
  ))
795
781
  };
796
782
  }
797
- function Km({
783
+ function jm({
798
784
  joinPlan: t,
799
785
  availableDataSources: s,
800
786
  onSave: n,
@@ -825,7 +811,7 @@ function Km({
825
811
  removeJoinKey: I,
826
812
  generateSQLPreview: A,
827
813
  isValidConfiguration: b
828
- } = jm({
814
+ } = qm({
829
815
  initialJoinPlan: t,
830
816
  availableDataSources: s
831
817
  }), L = (N) => {
@@ -1407,7 +1393,7 @@ function eo({
1407
1393
  /* @__PURE__ */ e(Ba, { children: "Configure the join between the two entities to combine the fields." })
1408
1394
  ] }),
1409
1395
  /* @__PURE__ */ e(
1410
- Km,
1396
+ jm,
1411
1397
  {
1412
1398
  joinPlan: r,
1413
1399
  availableDataSources: c,
@@ -1420,7 +1406,7 @@ function eo({
1420
1406
  t
1421
1407
  ] });
1422
1408
  }
1423
- function Gm({
1409
+ function Km({
1424
1410
  joins: t,
1425
1411
  baseEntityId: s,
1426
1412
  availableDataSources: n,
@@ -1575,12 +1561,12 @@ ${D.joinType} JOIN ${I.name}
1575
1561
  if (p.length < 2)
1576
1562
  return null;
1577
1563
  const C = l.joins.length > 0 && /* @__PURE__ */ e(
1578
- xt,
1564
+ gt,
1579
1565
  {
1580
1566
  side: "bottom",
1581
1567
  className: "ml-4 max-w-md overflow-hidden p-0",
1582
1568
  children: /* @__PURE__ */ e(
1583
- Gm,
1569
+ Km,
1584
1570
  {
1585
1571
  joins: l.joins,
1586
1572
  baseEntityId: l.baseEntity.name,
@@ -1646,7 +1632,7 @@ ${D.joinType} JOIN ${I.name}
1646
1632
  )
1647
1633
  ] });
1648
1634
  }
1649
- function Um({
1635
+ function Gm({
1650
1636
  open: t,
1651
1637
  onOpenChange: s
1652
1638
  }) {
@@ -1768,7 +1754,7 @@ function Ll({
1768
1754
  title: s
1769
1755
  }) {
1770
1756
  const { isConsoleMode: n } = di();
1771
- return /* @__PURE__ */ e(xt, { side: "top", className: "ml-5 max-w-xs", children: /* @__PURE__ */ a("div", { className: "space-y-2", children: [
1757
+ return /* @__PURE__ */ e(gt, { side: "top", className: "ml-5 max-w-xs", children: /* @__PURE__ */ a("div", { className: "space-y-2", children: [
1772
1758
  /* @__PURE__ */ e("div", { className: "text-sm font-medium", children: s ?? `${t.length} more entities` }),
1773
1759
  /* @__PURE__ */ e("div", { className: "space-y-1", children: t.map((r, c) => {
1774
1760
  const o = Lo(r), l = o.find(
@@ -1964,7 +1950,7 @@ function ao({
1964
1950
  }
1965
1951
  ),
1966
1952
  /* @__PURE__ */ e(
1967
- Um,
1953
+ Gm,
1968
1954
  {
1969
1955
  open: c,
1970
1956
  onOpenChange: o
@@ -1974,11 +1960,11 @@ function ao({
1974
1960
  }
1975
1961
  );
1976
1962
  }
1977
- function Hm(t) {
1963
+ function Um(t) {
1978
1964
  return zo({ 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);
1979
1965
  }
1980
- const Qm = 300;
1981
- function Jm() {
1966
+ const Hm = 300;
1967
+ function Qm() {
1982
1968
  const t = F((C) => C.card.sql), s = F((C) => C.sqlGen), n = F((C) => C.card), r = bt(), { setCardSql: c, setSqlGen: o, setRunSql: l } = xe(), d = oe(() => r !== n.type ? { ...n, type: r } : n, [n, r]), { queryKey: i } = Nt(d), u = Wn(), f = Ie(i);
1983
1969
  f.current = i;
1984
1970
  const h = Ie(s);
@@ -1996,7 +1982,7 @@ function Jm() {
1996
1982
  storeValue: t,
1997
1983
  defaultValue: "",
1998
1984
  onStoreUpdate: p,
1999
- delay: Qm
1985
+ delay: Hm
2000
1986
  });
2001
1987
  Ce(() => Qi(y), [y]);
2002
1988
  function v(C) {
@@ -2020,15 +2006,15 @@ function Jm() {
2020
2006
  )
2021
2007
  ] });
2022
2008
  }
2023
- const Ym = 300;
2024
- function Wm() {
2009
+ const Jm = 300;
2010
+ function Ym() {
2025
2011
  const t = F((p) => p.card.python), s = F((p) => p.card), n = bt(), { setCardPython: r, setRunSql: c } = xe(), o = oe(() => n !== s.type ? { ...s, type: n } : s, [s, n]), { queryKey: l } = Nt(o), d = Wn(), i = Ie(l);
2026
2012
  i.current = l;
2027
2013
  const { value: u, onChange: f, flush: h } = Zi({
2028
2014
  storeValue: t,
2029
2015
  defaultValue: $o,
2030
2016
  onStoreUpdate: r,
2031
- delay: Ym
2017
+ delay: Jm
2032
2018
  });
2033
2019
  return Ce(() => Qi(h), [h]), /* @__PURE__ */ e(
2034
2020
  Xn,
@@ -2045,11 +2031,11 @@ function Wm() {
2045
2031
  }
2046
2032
  );
2047
2033
  }
2048
- const Xm = {
2034
+ const Wm = {
2049
2035
  async writeTextToClipboard(t) {
2050
2036
  return typeof navigator > "u" || !navigator.clipboard ? !1 : (await navigator.clipboard.writeText(t), !0);
2051
2037
  }
2052
- }, Fn = 50, Zm = [
2038
+ }, Fn = 50, Xm = [
2053
2039
  { target: "queryRequest", label: "Query Request" },
2054
2040
  { target: "queryResponse", label: "Query Response" },
2055
2041
  { target: "cardConfig", label: "Card Config" },
@@ -2085,7 +2071,7 @@ function La(t) {
2085
2071
  return "Payload";
2086
2072
  }
2087
2073
  }
2088
- function eh(t) {
2074
+ function Zm(t) {
2089
2075
  if (!t || typeof t != "object")
2090
2076
  return { value: t };
2091
2077
  const s = t.records;
@@ -2156,7 +2142,7 @@ function no({
2156
2142
  const b = v[l];
2157
2143
  if (b === void 0)
2158
2144
  return null;
2159
- const L = l === "queryResponse" ? eh(b) : { value: b }, N = Pl(L.value);
2145
+ const L = l === "queryResponse" ? Zm(b) : { value: b }, N = Pl(L.value);
2160
2146
  return N ? {
2161
2147
  target: l,
2162
2148
  title: La(l),
@@ -2171,7 +2157,7 @@ function no({
2171
2157
  if (!N)
2172
2158
  return ut.error(`Unable to serialize ${La(b).toLowerCase()}`), !1;
2173
2159
  try {
2174
- return await Xm.writeTextToClipboard(N) ? (ut.success(`${La(b)} copied`), !0) : (ut.error("Clipboard is not available"), !1);
2160
+ return await Wm.writeTextToClipboard(N) ? (ut.success(`${La(b)} copied`), !0) : (ut.error("Clipboard is not available"), !1);
2175
2161
  } catch (M) {
2176
2162
  return console.error("Failed to copy debug payload", M), ut.error(`Unable to copy ${La(b).toLowerCase()}`), !1;
2177
2163
  }
@@ -2253,7 +2239,7 @@ function no({
2253
2239
  ]
2254
2240
  }
2255
2241
  ) }),
2256
- /* @__PURE__ */ e(Xa, { align: "start", className: "w-56", children: Zm.map((b) => /* @__PURE__ */ e(
2242
+ /* @__PURE__ */ e(Xa, { align: "start", className: "w-56", children: Xm.map((b) => /* @__PURE__ */ e(
2257
2243
  dt,
2258
2244
  {
2259
2245
  disabled: !w(b.target),
@@ -2320,12 +2306,12 @@ function no({
2320
2306
  ] }) })
2321
2307
  ] });
2322
2308
  }
2323
- const th = /\{\{-?\s*filters\s*\|\s*where\s*-?\}\}/i, ah = /\{\{-?\s*filters\s*\|\s*and\s*-?\}\}/i, nh = /\bwhere\b/i;
2324
- function sh(t) {
2325
- return t != null && t.trim() ? th.test(t) || ah.test(t) : !1;
2309
+ const eh = /\{\{-?\s*filters\s*\|\s*where\s*-?\}\}/i, th = /\{\{-?\s*filters\s*\|\s*and\s*-?\}\}/i, ah = /\bwhere\b/i;
2310
+ function nh(t) {
2311
+ return t != null && t.trim() ? eh.test(t) || th.test(t) : !1;
2326
2312
  }
2327
- function rh(t) {
2328
- return !(t != null && t.trim()) || sh(t) ? null : nh.test(t) ? {
2313
+ function sh(t) {
2314
+ return !(t != null && t.trim()) || nh(t) ? null : ah.test(t) ? {
2329
2315
  helper: "{{ filters | and }}",
2330
2316
  description: "Use this inside your existing WHERE clause to append dashboard filters."
2331
2317
  } : {
@@ -2333,7 +2319,7 @@ function rh(t) {
2333
2319
  description: "Use this when the query does not already have a WHERE clause."
2334
2320
  };
2335
2321
  }
2336
- function lh(t) {
2322
+ function rh(t) {
2337
2323
  const {
2338
2324
  request: s,
2339
2325
  mode: n = "draft",
@@ -2365,7 +2351,7 @@ ${s}`
2365
2351
 
2366
2352
  `);
2367
2353
  }
2368
- function ih(t) {
2354
+ function lh(t) {
2369
2355
  const {
2370
2356
  request: s,
2371
2357
  failedSql: n,
@@ -2398,7 +2384,7 @@ ${r}`
2398
2384
 
2399
2385
  `);
2400
2386
  }
2401
- function oh(t, s) {
2387
+ function ih(t, s) {
2402
2388
  typeof window > "u" || window.dispatchEvent(
2403
2389
  new CustomEvent("semaphor:inline-query-writer", {
2404
2390
  detail: {
@@ -2419,7 +2405,7 @@ const Os = {
2419
2405
  finalOutcome: "idle",
2420
2406
  hasTools: !1
2421
2407
  };
2422
- function ch(t) {
2408
+ function oh(t) {
2423
2409
  if (typeof t == "string" && (t === "SQL_EMPTY" || t === "SQL_PARSE_ERROR" || t === "SQL_MULTI_STATEMENT" || t === "SQL_READ_ONLY_VIOLATION" || t === "SQL_EXPLAIN_ERROR" || t === "SQL_CONNECTION_ERROR"))
2424
2410
  return t;
2425
2411
  }
@@ -2432,7 +2418,7 @@ function Vl(t) {
2432
2418
  function Bl(t) {
2433
2419
  return t === "getTableColumns" ? "Discovering columns" : t === "getDomainRelationships" ? "Resolving relationships" : t === "getChartSQLSyntax" ? "Reviewing SQL syntax" : t === "getUserSql" ? "Inspecting current query" : "Analyzing context";
2434
2420
  }
2435
- function dh(t, s) {
2421
+ function ch(t, s) {
2436
2422
  return t === _s && s > 0 ? `${_s} ${s}/${Ln}` : t;
2437
2423
  }
2438
2424
  function Rn(t) {
@@ -2449,7 +2435,7 @@ function zl(t) {
2449
2435
  return c;
2450
2436
  }
2451
2437
  }
2452
- function uh(t) {
2438
+ function dh(t) {
2453
2439
  if (!t) return "";
2454
2440
  const s = t.trim(), n = t.match(/```sql\s*([\s\S]*?)```/i);
2455
2441
  if (n != null && n[1])
@@ -2465,14 +2451,14 @@ function _l(t) {
2465
2451
  const c = n.parts[r];
2466
2452
  if ((c == null ? void 0 : c.type) !== "text" || typeof (c == null ? void 0 : c.text) != "string")
2467
2453
  continue;
2468
- const o = uh(c.text);
2454
+ const o = dh(c.text);
2469
2455
  if (o)
2470
2456
  return o;
2471
2457
  }
2472
2458
  }
2473
2459
  return "";
2474
2460
  }
2475
- function mh({
2461
+ function uh({
2476
2462
  currentSql: t,
2477
2463
  currentPython: s,
2478
2464
  selectedDatabaseName: n,
@@ -2497,8 +2483,8 @@ function mh({
2497
2483
  () => Rn("inline-query-session")
2498
2484
  ), $ = Ie(null), Y = Ie(null), le = Ie(null), Q = Ie(0), ce = Ie(0), he = Ie(
2499
2485
  Rn("inline-run-token")
2500
- ), Oe = Ie(V), Fe = Ie(/* @__PURE__ */ new Set()), me = Ie(/* @__PURE__ */ new Map()), pe = Ie(0), Te = Ie(""), Pe = Ie(!1), Re = Ie(!1), ue = Ie(Os), ie = Ie(!1), _e = Ie(null), Ue = Ie(() => {
2501
- }), lt = (ln = i.apiServiceUrl) == null ? void 0 : ln.replace(/\/$/, ""), ft = lt ? `${lt}/v1/sql/validate` : "/v1/sql/validate", et = ke(
2486
+ ), Oe = Ie(V), Fe = Ie(/* @__PURE__ */ new Set()), me = Ie(/* @__PURE__ */ new Map()), pe = Ie(0), Te = Ie(""), Pe = Ie(!1), Re = Ie(!1), ue = Ie(Os), ie = Ie(!1), ze = Ie(null), Ue = Ie(() => {
2487
+ }), lt = (ln = i.apiServiceUrl) == null ? void 0 : ln.replace(/\/$/, ""), pt = lt ? `${lt}/v1/sql/validate` : "/v1/sql/validate", et = ke(
2502
2488
  (K) => {
2503
2489
  T((re) => {
2504
2490
  const Z = K(re);
@@ -2560,7 +2546,7 @@ function mh({
2560
2546
  Pe.current = !0;
2561
2547
  }, []), X = ke(
2562
2548
  (K, re, Z) => {
2563
- oh(K, {
2549
+ ih(K, {
2564
2550
  runId: re,
2565
2551
  attemptCount: typeof (Z == null ? void 0 : Z.attemptCount) == "number" ? Z.attemptCount : pe.current,
2566
2552
  errorCode: Z == null ? void 0 : Z.errorCode,
@@ -2590,12 +2576,12 @@ function mh({
2590
2576
  []
2591
2577
  );
2592
2578
  Ce(() => {
2593
- const K = _e.current;
2594
- !K || K.sessionId !== V || (_e.current = null, ge(K.message, K.runToken));
2579
+ const K = ze.current;
2580
+ !K || K.sessionId !== V || (ze.current = null, ge(K.message, K.runToken));
2595
2581
  }, [V, ge]);
2596
2582
  const we = V, $e = ke(
2597
2583
  async ({ toolCall: K }) => {
2598
- var rt, Bt, ca, Zt, gt, Ra;
2584
+ var rt, Bt, ca, Zt, ft, Ra;
2599
2585
  if (we !== Oe.current)
2600
2586
  return;
2601
2587
  const re = String(K.toolName || "").trim();
@@ -2644,7 +2630,7 @@ function mh({
2644
2630
  phase: E.phase === "self-healing" ? "self-healing" : "drafting",
2645
2631
  hasTools: !0
2646
2632
  }), X("inline_tool_step", Z, { hasTools: !0 });
2647
- const tt = ((Zt = K.input) == null ? void 0 : Zt.sql) ?? ((gt = K.args) == null ? void 0 : gt.sql);
2633
+ const tt = ((Zt = K.input) == null ? void 0 : Zt.sql) ?? ((ft = K.args) == null ? void 0 : ft.sql);
2648
2634
  typeof tt == "string" && tt.trim().length > 0 && (ie.current = !1, O(tt.trim())), (Ra = Y.current) == null || Ra.call(Y, {
2649
2635
  tool: re,
2650
2636
  toolCallId: K.toolCallId,
@@ -2776,7 +2762,7 @@ function mh({
2776
2762
  }), g({ status: "validating" });
2777
2763
  try {
2778
2764
  const Ae = await Xs(
2779
- ft,
2765
+ pt,
2780
2766
  (d == null ? void 0 : d.accessToken) || "",
2781
2767
  {
2782
2768
  sql: K,
@@ -2799,7 +2785,7 @@ function mh({
2799
2785
  })), X("inline_draft_validated", re, {
2800
2786
  finalOutcome: "validated"
2801
2787
  }), { status: "valid" };
2802
- const Ee = ch(Ae == null ? void 0 : Ae.errorCode) || "UNKNOWN", tt = typeof (Ae == null ? void 0 : Ae.error) == "string" && Ae.error || typeof ((ye = Ae == null ? void 0 : Ae.details) == null ? void 0 : ye.error) == "string" && Ae.details.error || "SQL validation failed. Please revise the query draft.";
2788
+ const Ee = oh(Ae == null ? void 0 : Ae.errorCode) || "UNKNOWN", tt = typeof (Ae == null ? void 0 : Ae.error) == "string" && Ae.error || typeof ((ye = Ae == null ? void 0 : Ae.details) == null ? void 0 : ye.error) == "string" && Ae.details.error || "SQL validation failed. Please revise the query draft.";
2803
2789
  return g({
2804
2790
  status: "invalid",
2805
2791
  message: tt,
@@ -2851,7 +2837,7 @@ function mh({
2851
2837
  X,
2852
2838
  Je,
2853
2839
  h,
2854
- ft,
2840
+ pt,
2855
2841
  Qe,
2856
2842
  U
2857
2843
  ]
@@ -2946,10 +2932,10 @@ function mh({
2946
2932
  attemptCount: Bt,
2947
2933
  errorCode: Ee.errorCode
2948
2934
  }), ie.current = !0, it(), ot([]), O("");
2949
- const ca = m.map((gt) => {
2950
- const Ra = gt != null && gt.database ? `${gt.database}.` : "", xs = gt != null && gt.schema ? `${gt.schema}.` : "", bs = (gt == null ? void 0 : gt.name) || "unknown";
2935
+ const ca = m.map((ft) => {
2936
+ const Ra = ft != null && ft.database ? `${ft.database}.` : "", xs = ft != null && ft.schema ? `${ft.schema}.` : "", bs = (ft == null ? void 0 : ft.name) || "unknown";
2951
2937
  return `${Ra}${xs}${bs}`;
2952
- }), Zt = ih({
2938
+ }), Zt = lh({
2953
2939
  request: k,
2954
2940
  failedSql: K,
2955
2941
  errorMessage: Ee.error,
@@ -2992,7 +2978,7 @@ function mh({
2992
2978
  hasTools: !1,
2993
2979
  finalOutcome: "drafting"
2994
2980
  }), Le(), it(), B(re), O(""), D(Z), L(ye), M(!1), g({ status: "idle" }), Q.current += 1, ot([]), P(!0);
2995
- const Bt = lh({
2981
+ const Bt = rh({
2996
2982
  request: re,
2997
2983
  mode: Z,
2998
2984
  currentSql: Ae,
@@ -3000,7 +2986,7 @@ function mh({
3000
2986
  selectedSchemaName: r || "",
3001
2987
  selectedDatabaseName: n || ""
3002
2988
  });
3003
- _e.current = {
2989
+ ze.current = {
3004
2990
  sessionId: rt,
3005
2991
  message: Bt,
3006
2992
  runToken: tt
@@ -3133,7 +3119,7 @@ function mh({
3133
3119
  disabled: Be,
3134
3120
  "aria-label": Xt,
3135
3121
  title: Xt,
3136
- children: /* @__PURE__ */ e(Lm, { className: "size-3.5" })
3122
+ children: /* @__PURE__ */ e(Rm, { className: "size-3.5" })
3137
3123
  }
3138
3124
  )
3139
3125
  ] }),
@@ -3231,7 +3217,7 @@ function mh({
3231
3217
  "rounded-full border px-2 py-0.5 text-[11px]",
3232
3218
  Z ? "border-foreground/30 bg-foreground/10 text-foreground" : ye ? "border-border/60 bg-muted/20 text-muted-foreground" : "border-border/50 bg-background text-muted-foreground/80"
3233
3219
  ].join(" "),
3234
- children: dh(K, E.attempt)
3220
+ children: ch(K, E.attempt)
3235
3221
  },
3236
3222
  `${K}-${re}`
3237
3223
  );
@@ -3248,7 +3234,7 @@ function mh({
3248
3234
  }
3249
3235
  ) }),
3250
3236
  /* @__PURE__ */ e(
3251
- xt,
3237
+ gt,
3252
3238
  {
3253
3239
  side: "top",
3254
3240
  align: "start",
@@ -3338,7 +3324,7 @@ function mh({
3338
3324
  }
3339
3325
  );
3340
3326
  }
3341
- function hh() {
3327
+ function mh() {
3342
3328
  var Re, ue;
3343
3329
  const t = Wn(), [s, n] = G(!1), r = F((ie) => ie.frame), c = F((ie) => ie.card);
3344
3330
  F((ie) => ie.isShowingVisual), F(
@@ -3356,8 +3342,8 @@ function hh() {
3356
3342
  F((ie) => ie.showAIDialog);
3357
3343
  const d = F((ie) => ie.selectedTableName), i = Me(
3358
3344
  (ie) => {
3359
- var _e, Ue;
3360
- return ((Ue = (_e = ie.dashboard) == null ? void 0 : _e.filters) == null ? void 0 : Ue.length) ?? 0;
3345
+ var ze, Ue;
3346
+ return ((Ue = (ze = ie.dashboard) == null ? void 0 : ze.filters) == null ? void 0 : Ue.length) ?? 0;
3361
3347
  }
3362
3348
  ), { cardFilterValues: u } = Yo(
3363
3349
  (c == null ? void 0 : c.id) ?? ""
@@ -3372,9 +3358,9 @@ function hh() {
3372
3358
  () => {
3373
3359
  var ie;
3374
3360
  return (ie = p == null ? void 0 : p.visuals) == null ? void 0 : ie.find(
3375
- (_e) => {
3361
+ (ze) => {
3376
3362
  var Ue;
3377
- return _e.name === ((Ue = h == null ? void 0 : h.customCardPreferences) == null ? void 0 : Ue.componentName);
3363
+ return ze.name === ((Ue = h == null ? void 0 : h.customCardPreferences) == null ? void 0 : Ue.componentName);
3378
3364
  }
3379
3365
  );
3380
3366
  },
@@ -3388,14 +3374,14 @@ function hh() {
3388
3374
  [r, h, x]
3389
3375
  ), v = oe(() => {
3390
3376
  const ie = y.findIndex(
3391
- (_e) => (_e == null ? void 0 : _e.id) === (c == null ? void 0 : c.id)
3377
+ (ze) => (ze == null ? void 0 : ze.id) === (c == null ? void 0 : c.id)
3392
3378
  );
3393
3379
  return ie < 0 ? -1 : Gt(c, ie);
3394
3380
  }, [y, c]), C = oe(() => !h || x !== "multiple" || v < 0 ? c.type : Va(
3395
3381
  c,
3396
3382
  v,
3397
3383
  m == null ? void 0 : m.slots
3398
- ) ?? c.type, [h, x, v, c, m == null ? void 0 : m.slots]), k = oe(() => C !== c.type ? { ...c, type: C } : c, [c, C]), B = oe(() => i === 0 ? null : rh(c == null ? void 0 : c.sql), [c == null ? void 0 : c.sql, i]), w = Ie(!0), {
3384
+ ) ?? c.type, [h, x, v, c, m == null ? void 0 : m.slots]), k = oe(() => C !== c.type ? { ...c, type: C } : c, [c, C]), B = oe(() => i === 0 ? null : sh(c == null ? void 0 : c.sql), [c == null ? void 0 : c.sql, i]), w = Ie(!0), {
3399
3385
  setCardCustomCfg: O,
3400
3386
  setQueryResultColumns: S,
3401
3387
  setCardSql: D,
@@ -3456,8 +3442,8 @@ function hh() {
3456
3442
  }
3457
3443
  me.current();
3458
3444
  }, [f]);
3459
- function pe(ie, _e) {
3460
- D(ie), _e && T(!0);
3445
+ function pe(ie, ze) {
3446
+ D(ie), ze && T(!0);
3461
3447
  }
3462
3448
  function Te() {
3463
3449
  return /* @__PURE__ */ a(
@@ -3480,7 +3466,7 @@ function hh() {
3480
3466
  {
3481
3467
  id: "sql-container",
3482
3468
  className: "relative flex w-[99%]",
3483
- children: /* @__PURE__ */ e(Jm, {})
3469
+ children: /* @__PURE__ */ e(Qm, {})
3484
3470
  }
3485
3471
  ),
3486
3472
  s && /* @__PURE__ */ e("code", { className: "absolute right-6 top-3 text-xs text-muted-foreground/70", children: "sql" })
@@ -3508,7 +3494,7 @@ function hh() {
3508
3494
  {
3509
3495
  id: "python-container",
3510
3496
  className: "relative flex w-[99%] pt-0",
3511
- children: /* @__PURE__ */ e(Wm, {})
3497
+ children: /* @__PURE__ */ e(Ym, {})
3512
3498
  }
3513
3499
  ),
3514
3500
  /* @__PURE__ */ e("code", { className: "absolute right-6 top-3 text-xs text-muted-foreground/70", children: "python" })
@@ -3581,13 +3567,13 @@ function hh() {
3581
3567
  size: "sm",
3582
3568
  variant: "outline",
3583
3569
  children: [
3584
- /* @__PURE__ */ e(Hm, { className: "mr-2 size-4 text-foreground/70" }),
3570
+ /* @__PURE__ */ e(Um, { className: "mr-2 size-4 text-foreground/70" }),
3585
3571
  "Python"
3586
3572
  ]
3587
3573
  }
3588
3574
  ),
3589
3575
  /* @__PURE__ */ e(
3590
- mh,
3576
+ uh,
3591
3577
  {
3592
3578
  currentSql: c == null ? void 0 : c.sql,
3593
3579
  currentPython: c == null ? void 0 : c.python,
@@ -3634,7 +3620,7 @@ function hh() {
3634
3620
  )
3635
3621
  );
3636
3622
  }
3637
- function ph(t, s) {
3623
+ function hh(t, s) {
3638
3624
  var o;
3639
3625
  let n = 0, r = 0;
3640
3626
  const c = Math.min(t.length, 50);
@@ -3649,7 +3635,7 @@ function ph(t, s) {
3649
3635
  }
3650
3636
  return r === 0 ? "null" : n / r > 0.7 ? "number" : "text";
3651
3637
  }
3652
- function fh(t) {
3638
+ function ph(t) {
3653
3639
  if (t === null) return "null";
3654
3640
  if (t === void 0) return "";
3655
3641
  if (typeof t == "number" || typeof t == "bigint" || typeof t == "boolean") return String(t);
@@ -3660,7 +3646,7 @@ function fh(t) {
3660
3646
  return String(t);
3661
3647
  }
3662
3648
  }
3663
- function gh({
3649
+ function fh({
3664
3650
  data: t,
3665
3651
  card: s,
3666
3652
  paginationMetadata: n,
@@ -3698,7 +3684,7 @@ function gh({
3698
3684
  ), k = ta.useMemo(() => {
3699
3685
  const R = {};
3700
3686
  for (const g of d)
3701
- R[g] = ph(t, g);
3687
+ R[g] = hh(t, g);
3702
3688
  return R;
3703
3689
  }, [d, t]), B = ta.useMemo(
3704
3690
  () => d.map((R) => {
@@ -3734,7 +3720,7 @@ function gh({
3734
3720
  E && "text-right tabular-nums",
3735
3721
  _ === null && "text-muted-foreground/50 italic"
3736
3722
  ),
3737
- children: fh(_)
3723
+ children: ph(_)
3738
3724
  }
3739
3725
  );
3740
3726
  }
@@ -3864,13 +3850,13 @@ function gh({
3864
3850
  ] }) })
3865
3851
  ] });
3866
3852
  }
3867
- const xh = [
3853
+ const gh = [
3868
3854
  { value: "table", label: "Table", icon: Zn },
3869
3855
  { value: "aggregateTable", label: "Aggregate", icon: en },
3870
3856
  { value: "pivotTable", label: "Pivot", icon: tr },
3871
3857
  { value: "detailTable", label: "Detail", icon: yi }
3872
3858
  ];
3873
- function bh({ className: t }) {
3859
+ function xh({ className: t }) {
3874
3860
  const s = F((h) => h.card), n = F((h) => h.frame), r = bt(), { setCard: c, updateCardInFrame: o } = xe(), l = [
3875
3861
  "table",
3876
3862
  "aggregateTable",
@@ -3972,7 +3958,7 @@ function bh({ className: t }) {
3972
3958
  value: r,
3973
3959
  onValueChange: u,
3974
3960
  className: "flex flex-row items-center gap-1 border-b border-border/60",
3975
- children: xh.map((h) => {
3961
+ children: gh.map((h) => {
3976
3962
  const p = h.icon, m = r === h.value;
3977
3963
  return /* @__PURE__ */ a("div", { className: "flex items-center", children: [
3978
3964
  /* @__PURE__ */ e(
@@ -4093,7 +4079,7 @@ function xr({
4093
4079
  className: "h-8",
4094
4080
  onClick: c,
4095
4081
  children: [
4096
- /* @__PURE__ */ e(Im, { className: "mr-1.5 h-3.5 w-3.5" }),
4082
+ /* @__PURE__ */ e(km, { className: "mr-1.5 h-3.5 w-3.5" }),
4097
4083
  "Debug with Assistant"
4098
4084
  ]
4099
4085
  }
@@ -4246,7 +4232,7 @@ function ro({
4246
4232
  viewport: ge
4247
4233
  }
4248
4234
  };
4249
- }, [h, p, n, d, g, E]), _e = (de, X) => {
4235
+ }, [h, p, n, d, g, E]), ze = (de, X) => {
4250
4236
  var we, $e;
4251
4237
  const ge = {
4252
4238
  ...n,
@@ -4293,7 +4279,7 @@ function ro({
4293
4279
  A,
4294
4280
  Y
4295
4281
  ]);
4296
- function ft(de) {
4282
+ function pt(de) {
4297
4283
  return /* @__PURE__ */ e(es, { FallbackComponent: rr, children: /* @__PURE__ */ e(Nc, { card: de }) });
4298
4284
  }
4299
4285
  function et() {
@@ -4317,7 +4303,7 @@ function ro({
4317
4303
  return A === "table" || A === "detailTable" ? /* @__PURE__ */ e("div", { className: "relative mb-2 flex h-full min-h-0 w-full flex-1 grow basis-0", children: /* @__PURE__ */ e(gc, {}) }) : /* @__PURE__ */ e("div", { className: "z-50 flex h-full items-center justify-center", children: /* @__PURE__ */ e(zt, { size: "md", color: "muted", "aria-label": "Loading data" }) });
4318
4304
  if (!b.id) return null;
4319
4305
  if (A === "custom")
4320
- return ft(n);
4306
+ return pt(n);
4321
4307
  if (![
4322
4308
  "table",
4323
4309
  "pivotTable",
@@ -4339,7 +4325,7 @@ function ro({
4339
4325
  data: V,
4340
4326
  comparisonMetadata: (de = N == null ? void 0 : N.metadata) == null ? void 0 : de.comparisonMetadata,
4341
4327
  paginationMetadata: T,
4342
- onPaginationChange: _e,
4328
+ onPaginationChange: ze,
4343
4329
  onSortChange: Ue,
4344
4330
  isLoading: M || R
4345
4331
  }
@@ -4376,7 +4362,7 @@ function ro({
4376
4362
  groupByColumns: N == null ? void 0 : N.groupByColumns,
4377
4363
  pivotSchema: N == null ? void 0 : N.pivotSchema,
4378
4364
  paginationMetadata: T,
4379
- onPaginationChange: _e,
4365
+ onPaginationChange: ze,
4380
4366
  onAggregationChange: (X) => {
4381
4367
  const ge = ml(
4382
4368
  X,
@@ -4419,7 +4405,7 @@ function ro({
4419
4405
  ) }),
4420
4406
  /* @__PURE__ */ e(mc, { card: n }),
4421
4407
  /* @__PURE__ */ e(Ji, {}),
4422
- /* @__PURE__ */ e("div", { className: "ml-auto", children: /* @__PURE__ */ e(bh, {}) })
4408
+ /* @__PURE__ */ e("div", { className: "ml-auto", children: /* @__PURE__ */ e(xh, {}) })
4423
4409
  ] }),
4424
4410
  /* @__PURE__ */ e("div", { className: "w-1/2", children: /* @__PURE__ */ e(
4425
4411
  Ns,
@@ -4501,7 +4487,7 @@ const Ms = ({
4501
4487
  readOnly: r,
4502
4488
  embedded: !0
4503
4489
  }
4504
- ), vh = () => /* @__PURE__ */ a(ga, { children: [
4490
+ ), bh = () => /* @__PURE__ */ a(ga, { children: [
4505
4491
  /* @__PURE__ */ e("div", { className: "flex items-center gap-2", children: /* @__PURE__ */ e(xa, { children: "Customize Card" }) }),
4506
4492
  /* @__PURE__ */ a(Ba, { children: [
4507
4493
  "See the configuration options and documentation",
@@ -4515,7 +4501,7 @@ const Ms = ({
4515
4501
  }
4516
4502
  )
4517
4503
  ] })
4518
- ] }), yh = ({
4504
+ ] }), vh = ({
4519
4505
  // defaultConfig,
4520
4506
  customCode: t,
4521
4507
  cardCustomCfgString: s,
@@ -4575,7 +4561,7 @@ const Ms = ({
4575
4561
  )
4576
4562
  }
4577
4563
  )
4578
- ] }), Nh = ({
4564
+ ] }), yh = ({
4579
4565
  error: t,
4580
4566
  hasCardCustomConfig: s,
4581
4567
  onReset: n,
@@ -4587,7 +4573,7 @@ const Ms = ({
4587
4573
  /* @__PURE__ */ e(H, { onClick: r, variant: "outline", children: "Apply" }),
4588
4574
  /* @__PURE__ */ e(H, { onClick: c, variant: "outline", children: "Close" })
4589
4575
  ] });
4590
- function Ch({
4576
+ function Nh({
4591
4577
  triggerVariant: t = "icon",
4592
4578
  className: s,
4593
4579
  label: n = "Customize Visual"
@@ -4657,7 +4643,7 @@ function Ch({
4657
4643
  ]
4658
4644
  }
4659
4645
  ) : /* @__PURE__ */ e(
4660
- pt,
4646
+ xt,
4661
4647
  {
4662
4648
  tooltip: "Customize Visual",
4663
4649
  onClick: D,
@@ -4669,11 +4655,11 @@ function Ch({
4669
4655
  }
4670
4656
  ) }),
4671
4657
  /* @__PURE__ */ a(fa, { className: "flex h-[600px] grow flex-col overflow-auto sm:min-w-[900px] lg:min-w-[1200px]", children: [
4672
- /* @__PURE__ */ e(vh, {}),
4658
+ /* @__PURE__ */ e(bh, {}),
4673
4659
  /* @__PURE__ */ a("div", { className: "flex grow gap-2", children: [
4674
4660
  /* @__PURE__ */ e(es, { FallbackComponent: rr, children: /* @__PURE__ */ e(ro, { className: "w-1/2 rounded shadow-none" }) }),
4675
4661
  /* @__PURE__ */ e(
4676
- yh,
4662
+ vh,
4677
4663
  {
4678
4664
  customCode: u,
4679
4665
  cardCustomCfgString: v,
@@ -4684,7 +4670,7 @@ function Ch({
4684
4670
  )
4685
4671
  ] }),
4686
4672
  /* @__PURE__ */ e(
4687
- Nh,
4673
+ yh,
4688
4674
  {
4689
4675
  error: h,
4690
4676
  hasCardCustomConfig: !!y,
@@ -4698,7 +4684,7 @@ function Ch({
4698
4684
  ] })
4699
4685
  ] });
4700
4686
  }
4701
- function wh({ isStarred: t, onClick: s, className: n }) {
4687
+ function Ch({ isStarred: t, onClick: s, className: n }) {
4702
4688
  return /* @__PURE__ */ e(
4703
4689
  "button",
4704
4690
  {
@@ -4742,12 +4728,12 @@ function $l({
4742
4728
  "absolute left-1 top-1 z-10 transition-opacity",
4743
4729
  c ? "opacity-100" : "opacity-0 group-hover:opacity-100 group-focus-within:opacity-100"
4744
4730
  ),
4745
- children: /* @__PURE__ */ e(wh, { isStarred: c, onClick: () => d() })
4731
+ children: /* @__PURE__ */ e(Ch, { isStarred: c, onClick: () => d() })
4746
4732
  }
4747
4733
  ),
4748
4734
  n && r && /* @__PURE__ */ e("div", { className: "absolute right-1 top-1 z-10", children: /* @__PURE__ */ a(mt, { children: [
4749
4735
  /* @__PURE__ */ e(ht, { asChild: !0, children: /* @__PURE__ */ e("span", { className: "flex items-center justify-center", children: /* @__PURE__ */ e(qt, { className: "h-3 w-3 text-muted-foreground" }) }) }),
4750
- /* @__PURE__ */ e(xt, { side: "top", className: "text-xs", children: r })
4736
+ /* @__PURE__ */ e(gt, { side: "top", className: "text-xs", children: r })
4751
4737
  ] }) }),
4752
4738
  /* @__PURE__ */ a(
4753
4739
  "button",
@@ -4808,7 +4794,7 @@ const ql = [
4808
4794
  { id: "map", name: "Map" }
4809
4795
  // { id: 'tableBuilder', name: 'Table Builder' },
4810
4796
  ];
4811
- function Sh({ onChartSelect: t, onClose: s }) {
4797
+ function wh({ onChartSelect: t, onClose: s }) {
4812
4798
  const [n, r] = G(""), { starredCharts: c, isStarred: o, toggleStar: l } = kc(), { data: d = [], isLoading: i } = Ic(), { setCardType: u, setCardPreferences: f, setIsDevMode: h } = F(
4813
4799
  (b) => b.actions
4814
4800
  ), p = F((b) => b.card), {
@@ -4925,7 +4911,7 @@ function Sh({ onChartSelect: t, onClose: s }) {
4925
4911
  ] })
4926
4912
  ] });
4927
4913
  }
4928
- function Th({
4914
+ function Sh({
4929
4915
  selectedChart: t,
4930
4916
  onChartChange: s
4931
4917
  }) {
@@ -4971,7 +4957,7 @@ function Th({
4971
4957
  }
4972
4958
  );
4973
4959
  }
4974
- return /* @__PURE__ */ e(Pm, { className: "h-4 w-4" });
4960
+ return /* @__PURE__ */ e(Lm, { className: "h-4 w-4" });
4975
4961
  }, [x, y]);
4976
4962
  return {
4977
4963
  displayChartType: x,
@@ -5017,7 +5003,7 @@ function br({
5017
5003
  badgeLabel: u,
5018
5004
  handleChartSelect: f,
5019
5005
  handleClearCustomVisual: h
5020
- } = Th({ selectedChart: t, onChartChange: s });
5006
+ } = Sh({ selectedChart: t, onChartChange: s });
5021
5007
  return /* @__PURE__ */ a("div", { className: W("relative w-full", r), children: [
5022
5008
  /* @__PURE__ */ a(Tt, { open: c, onOpenChange: o, children: [
5023
5009
  /* @__PURE__ */ e(Ot, { asChild: !0, children: /* @__PURE__ */ a(
@@ -5049,7 +5035,7 @@ function br({
5049
5035
  align: "start",
5050
5036
  onOpenAutoFocus: (p) => p.preventDefault(),
5051
5037
  children: /* @__PURE__ */ e(
5052
- Sh,
5038
+ wh,
5053
5039
  {
5054
5040
  onChartSelect: (p) => f(p),
5055
5041
  onClose: () => o(!1)
@@ -5080,7 +5066,7 @@ function br({
5080
5066
  )
5081
5067
  ] });
5082
5068
  }
5083
- function kh() {
5069
+ function Th() {
5084
5070
  const t = F(
5085
5071
  (i) => {
5086
5072
  var u, f;
@@ -5102,18 +5088,18 @@ function kh() {
5102
5088
  };
5103
5089
  function o() {
5104
5090
  const i = t ?? "x";
5105
- return /* @__PURE__ */ e(pt, { onClick: () => {
5091
+ return /* @__PURE__ */ e(xt, { onClick: () => {
5106
5092
  c(i === "x" ? "y" : "x");
5107
5093
  }, tooltip: "Chart Orientation", children: i === "x" ? /* @__PURE__ */ e(Es, { className: "size-4" }) : /* @__PURE__ */ e(As, { className: "size-4" }) });
5108
5094
  }
5109
5095
  function l() {
5110
- return /* @__PURE__ */ e(pt, { onClick: () => {
5096
+ return /* @__PURE__ */ e(xt, { onClick: () => {
5111
5097
  c(t === "y" || t === void 0 ? "x" : "y");
5112
5098
  }, tooltip: "Chart Orientation", children: t === "y" || t === void 0 ? /* @__PURE__ */ e(Es, { className: "size-4" }) : /* @__PURE__ */ e(As, { className: "size-4" }) });
5113
5099
  }
5114
5100
  function d() {
5115
5101
  const i = t ?? "y";
5116
- return /* @__PURE__ */ e(pt, { onClick: () => {
5102
+ return /* @__PURE__ */ e(xt, { onClick: () => {
5117
5103
  c(i === "y" ? "x" : "y");
5118
5104
  }, tooltip: "Chart Orientation", children: i === "y" ? /* @__PURE__ */ e(As, { className: "size-4" }) : /* @__PURE__ */ e(Es, { className: "size-4" }) });
5119
5105
  }
@@ -5150,7 +5136,7 @@ function vr({
5150
5136
  ]
5151
5137
  }
5152
5138
  ) : /* @__PURE__ */ e(
5153
- pt,
5139
+ xt,
5154
5140
  {
5155
5141
  className: "h-8 w-8 p-0",
5156
5142
  tooltip: "Display Options",
@@ -5357,7 +5343,7 @@ function yr({
5357
5343
  ]
5358
5344
  }
5359
5345
  ) : /* @__PURE__ */ a(
5360
- pt,
5346
+ xt,
5361
5347
  {
5362
5348
  tooltip: "Add Inline Filter",
5363
5349
  className: W("relative", {
@@ -5397,7 +5383,7 @@ function yr({
5397
5383
  x.length > 0 && /* @__PURE__ */ a("div", { className: "border-t px-4 py-3", children: [
5398
5384
  /* @__PURE__ */ e("p", { className: "mb-2 text-xs font-medium text-muted-foreground", children: "Active Filters" }),
5399
5385
  /* @__PURE__ */ e("div", { className: "space-y-1", children: x.map((I) => /* @__PURE__ */ e(
5400
- Ih,
5386
+ kh,
5401
5387
  {
5402
5388
  filter: I,
5403
5389
  onUpdate: (A) => k(I.id, A),
@@ -5413,7 +5399,7 @@ function yr({
5413
5399
  }
5414
5400
  );
5415
5401
  }
5416
- function Ih({
5402
+ function kh({
5417
5403
  filter: t,
5418
5404
  onUpdate: s,
5419
5405
  onRemove: n
@@ -5452,16 +5438,16 @@ function Ih({
5452
5438
  ] })
5453
5439
  ] });
5454
5440
  }
5455
- const Dh = {
5441
+ const Ih = {
5456
5442
  metric_selector: "Displayed metric",
5457
5443
  field_selector: "Group by field",
5458
5444
  aggregation_selector: "Aggregation",
5459
5445
  grain_selector: "Time grain"
5460
5446
  };
5461
- function Ah(t, s) {
5447
+ function Dh(t, s) {
5462
5448
  return t && typeof t == "object" && "label" in t && typeof t.label == "string" && t.label.trim().length > 0 ? t.label : s || null;
5463
5449
  }
5464
- const Eh = {
5450
+ const Ah = {
5465
5451
  metric_selector: "config_metric_selector",
5466
5452
  field_selector: "config_field_selector",
5467
5453
  aggregation_selector: "config_aggregation",
@@ -5470,14 +5456,14 @@ const Eh = {
5470
5456
  function Hn(t, s) {
5471
5457
  return `${t}:${s}`;
5472
5458
  }
5473
- function Oh(t, s, n) {
5459
+ function Eh(t, s, n) {
5474
5460
  const r = new Set(
5475
5461
  n.filter((o) => o.target !== "sql_param").map((o) => Hn(o.controlId, o.target))
5476
5462
  ), c = s.map((o) => {
5477
5463
  const l = Ai({
5478
5464
  card: t,
5479
5465
  control: o
5480
- }).map((f) => f.value), d = Eh[o.type], u = [
5466
+ }).map((f) => f.value), d = Ah[o.type], u = [
5481
5467
  ...d ? [d] : [],
5482
5468
  ...l.filter((f) => f !== d)
5483
5469
  ].find(
@@ -5494,7 +5480,7 @@ function Oh(t, s, n) {
5494
5480
  mapping: {}
5495
5481
  } : null;
5496
5482
  }
5497
- function Mh({
5483
+ function Oh({
5498
5484
  card: t,
5499
5485
  dashboardControls: s,
5500
5486
  bindings: n,
@@ -5571,7 +5557,7 @@ function Mh({
5571
5557
  }, C = (B) => {
5572
5558
  r(n.filter((w, O) => O !== B));
5573
5559
  }, k = () => {
5574
- const B = Oh(t, d, n);
5560
+ const B = Eh(t, d, n);
5575
5561
  B && r([...n, B]);
5576
5562
  };
5577
5563
  if (typeof t.sql == "string" && t.sql.trim().length > 0) {
@@ -5641,7 +5627,7 @@ function Mh({
5641
5627
  value: g,
5642
5628
  label: (E == null ? void 0 : E.label) || g
5643
5629
  };
5644
- }), L = `${B.controlId}-${B.target}-${w}`, N = i[L] ?? w === 0, M = Object.keys(B.mapping).length, R = S != null && S.type ? Dh[S.type] || S.type : null;
5630
+ }), L = `${B.controlId}-${B.target}-${w}`, N = i[L] ?? w === 0, M = Object.keys(B.mapping).length, R = S != null && S.type ? Ih[S.type] || S.type : null;
5645
5631
  return /* @__PURE__ */ a(
5646
5632
  Pt,
5647
5633
  {
@@ -5692,7 +5678,7 @@ function Mh({
5692
5678
  /* @__PURE__ */ e($t, { className: "space-y-3 border-t px-3 pb-3 pt-2", children: b.length === 0 ? /* @__PURE__ */ e("div", { className: "rounded-md border border-dashed p-3 text-sm text-muted-foreground", children: "Add choices to this control first so you can decide what each choice changes in the card." }) : A.length === 0 ? /* @__PURE__ */ e("div", { className: "rounded-md border border-dashed p-3 text-sm text-muted-foreground", children: "No matching targets are available for this binding yet." }) : /* @__PURE__ */ a("div", { className: "space-y-2", children: [
5693
5679
  /* @__PURE__ */ e(z, { className: "text-xs", children: "Map each choice" }),
5694
5680
  /* @__PURE__ */ e("div", { className: "space-y-2", children: b.map((g) => {
5695
- const E = B.mapping[g.value], T = B.target === "config_metric_selector" || B.target === "config_field_selector" ? typeof E == "string" ? E : E == null ? void 0 : E.id : typeof E == "string" ? E : void 0, _ = !l && typeof T == "string" && !A.some((q) => q.value === T), P = Ah(
5681
+ const E = B.mapping[g.value], T = B.target === "config_metric_selector" || B.target === "config_field_selector" ? typeof E == "string" ? E : E == null ? void 0 : E.id : typeof E == "string" ? E : void 0, _ = !l && typeof T == "string" && !A.some((q) => q.value === T), P = Dh(
5696
5682
  E,
5697
5683
  T
5698
5684
  ), V = T && _ ? [
@@ -5793,8 +5779,8 @@ function Mh({
5793
5779
  ] }) : null
5794
5780
  ] });
5795
5781
  }
5796
- const Fh = [];
5797
- function Rh({
5782
+ const Mh = [];
5783
+ function Fh({
5798
5784
  className: t,
5799
5785
  triggerVariant: s = "icon",
5800
5786
  label: n = "Controls"
@@ -5805,7 +5791,7 @@ function Rh({
5805
5791
  preventPassiveDismissDuringCreate: c,
5806
5792
  resolvedOpen: o,
5807
5793
  setIsCreateFlowActive: l
5808
- } = xm({}), d = F((R) => R.card), i = F((R) => R.frame), u = Me((R) => R.dashboard), h = Me((R) => R.dashboard.controls) || Fh, { setCard: p, updateCardInFrame: m } = xe(), [x, y] = G(null);
5794
+ } = xm({}), d = F((R) => R.card), i = F((R) => R.frame), u = Me((R) => R.dashboard), h = Me((R) => R.dashboard.controls) || Mh, { setCard: p, updateCardInFrame: m } = xe(), [x, y] = G(null);
5809
5795
  Ce(() => {
5810
5796
  o && !x && (d != null && d.id) && y(d.id);
5811
5797
  }, [d == null ? void 0 : d.id, o, x]), Ce(() => {
@@ -5893,7 +5879,7 @@ function Rh({
5893
5879
  ]
5894
5880
  }
5895
5881
  ) : /* @__PURE__ */ a(
5896
- pt,
5882
+ xt,
5897
5883
  {
5898
5884
  tooltip: "Configure Controls",
5899
5885
  className: W("relative", {
@@ -5939,7 +5925,7 @@ function Rh({
5939
5925
  /* @__PURE__ */ e("p", { className: "text-xs text-muted-foreground", children: "Choose what each control changes in this card." })
5940
5926
  ] }),
5941
5927
  v ? /* @__PURE__ */ e(
5942
- Mh,
5928
+ Oh,
5943
5929
  {
5944
5930
  card: v,
5945
5931
  dashboardControls: h,
@@ -5996,19 +5982,19 @@ function lo({
5996
5982
  "map"
5997
5983
  ].includes(o.type);
5998
5984
  return f || h || n || r || c ? /* @__PURE__ */ a("div", { "data-info": "visual-settings", className: "flex items-center gap-2", children: [
5999
- f && /* @__PURE__ */ e(Ne, { children: /* @__PURE__ */ e(kh, {}) }),
6000
- h && /* @__PURE__ */ a(pt, { tooltip: "Grid Style", onClick: u, children: [
5985
+ f && /* @__PURE__ */ e(Ne, { children: /* @__PURE__ */ e(Th, {}) }),
5986
+ h && /* @__PURE__ */ a(xt, { tooltip: "Grid Style", onClick: u, children: [
6001
5987
  (d === "xy" || !d) && /* @__PURE__ */ e(tr, { className: "size-4" }),
6002
5988
  d === "x" && /* @__PURE__ */ e(gr, { className: "size-4" }),
6003
5989
  d === "y" && /* @__PURE__ */ e(os, { className: "size-4" }),
6004
5990
  d === "none" && /* @__PURE__ */ e(Yc, { className: "size-4" })
6005
5991
  ] }),
6006
5992
  n && /* @__PURE__ */ e(yr, {}),
6007
- r && /* @__PURE__ */ e(Rh, {}),
5993
+ r && /* @__PURE__ */ e(Fh, {}),
6008
5994
  c && /* @__PURE__ */ e(vr, {})
6009
5995
  ] }) : null;
6010
5996
  }
6011
- function Lh({
5997
+ function Rh({
6012
5998
  visible: t
6013
5999
  }) {
6014
6000
  const s = Me((l) => l.selectedFrameId), n = Wc((l) => l.selectedVisual), r = F((l) => l.frame), o = !!!(r != null && r.visualId || n != null && n.id) && !!s;
@@ -6020,7 +6006,7 @@ function Lh({
6020
6006
  }
6021
6007
  ) });
6022
6008
  }
6023
- function Ph({
6009
+ function Lh({
6024
6010
  isPreviewMode: t,
6025
6011
  onPreviewToggle: s,
6026
6012
  configCard: n
@@ -6190,7 +6176,7 @@ function Ph({
6190
6176
  /* @__PURE__ */ e("span", { children: $.label || `Tab ${q + 1}` })
6191
6177
  ] }) }),
6192
6178
  /* @__PURE__ */ e(
6193
- xt,
6179
+ gt,
6194
6180
  {
6195
6181
  side: "bottom",
6196
6182
  className: "w-64 p-3 text-left",
@@ -6245,7 +6231,7 @@ function Ph({
6245
6231
  );
6246
6232
  }),
6247
6233
  /* @__PURE__ */ e(
6248
- pt,
6234
+ xt,
6249
6235
  {
6250
6236
  tooltip: "Add Card",
6251
6237
  className: "ml-1 h-8 px-2 hover:bg-muted-foreground/50",
@@ -6368,7 +6354,7 @@ function ua({
6368
6354
  Re,
6369
6355
  ue
6370
6356
  ]
6371
- ), { cardFilters: _e, cardFilterValues: Ue } = oe(
6357
+ ), { cardFilters: ze, cardFilterValues: Ue } = oe(
6372
6358
  () => l ? nd({
6373
6359
  card: l,
6374
6360
  interactionStates: Oe,
@@ -6388,9 +6374,9 @@ function ua({
6388
6374
  );
6389
6375
  function lt(X) {
6390
6376
  const ge = n.cards.find((we) => we.id === X);
6391
- ge && (Nn(), p(), ft(X), u(X), m(), x(ge));
6377
+ ge && (Nn(), p(), pt(X), u(X), m(), x(ge));
6392
6378
  }
6393
- function ft(X) {
6379
+ function pt(X) {
6394
6380
  const ge = F.getState().card, we = F.getState().frame, $e = {
6395
6381
  ...we,
6396
6382
  cards: we.cards.map((st) => st.id === ge.id ? ge : st),
@@ -6454,7 +6440,7 @@ function ua({
6454
6440
  multiInputData: y,
6455
6441
  params: S,
6456
6442
  theme: D,
6457
- filters: _e,
6443
+ filters: ze,
6458
6444
  filterValues: [
6459
6445
  ...Ue || [],
6460
6446
  ...Pe || []
@@ -6478,7 +6464,7 @@ function ua({
6478
6464
  isFetching: Y,
6479
6465
  isError: le
6480
6466
  }) : r.type === "kpi" ? $ || Y ? /* @__PURE__ */ e("div", { className: "z-50 flex h-full items-center justify-center", children: /* @__PURE__ */ e(zt, { size: "md", color: "muted", "aria-label": "Loading data" }) }) : /* @__PURE__ */ e("div", { className: "flex h-full items-center justify-center", children: /* @__PURE__ */ a("div", { className: "w-1/2 space-y-3", children: [
6481
- /* @__PURE__ */ e(Lh, { visible: !0 }),
6467
+ /* @__PURE__ */ e(Rh, { visible: !0 }),
6482
6468
  /* @__PURE__ */ e("div", { className: "rounded-md border border-border", children: /* @__PURE__ */ e(
6483
6469
  sd,
6484
6470
  {
@@ -6516,7 +6502,7 @@ function ua({
6516
6502
  X.id
6517
6503
  )),
6518
6504
  /* @__PURE__ */ e(
6519
- Ph,
6505
+ Lh,
6520
6506
  {
6521
6507
  isPreviewMode: g,
6522
6508
  onPreviewToggle: o,
@@ -6527,7 +6513,7 @@ function ua({
6527
6513
  }
6528
6514
  );
6529
6515
  }
6530
- function Vh({
6516
+ function Ph({
6531
6517
  onClick: t,
6532
6518
  className: s
6533
6519
  }) {
@@ -6632,7 +6618,7 @@ function io({
6632
6618
  /* @__PURE__ */ e("p", { className: "text-sm text-muted-foreground", children: "Open Customize, paste visual code, and apply it to preview the renderer here." })
6633
6619
  ] }),
6634
6620
  /* @__PURE__ */ e(
6635
- Vh,
6621
+ Ph,
6636
6622
  {
6637
6623
  onClick: () => c(!0)
6638
6624
  }
@@ -6922,7 +6908,7 @@ function jl({
6922
6908
  k(Pe), c.sql && ((ue = (Re = c.preferences) == null ? void 0 : Re.tablePrefs) != null && ue.enableDevModePagination) && p(!0);
6923
6909
  }
6924
6910
  function Q(me) {
6925
- var Re, ue, ie, _e, Ue;
6911
+ var Re, ue, ie, ze, Ue;
6926
6912
  const pe = lr(
6927
6913
  me,
6928
6914
  (Re = c.config) == null ? void 0 : Re.metricColumns,
@@ -6940,7 +6926,7 @@ function jl({
6940
6926
  ...r,
6941
6927
  cards: r.cards.map((lt) => lt.id === c.id ? Te : lt)
6942
6928
  };
6943
- k(Pe), c.sql && ((Ue = (_e = c.preferences) == null ? void 0 : _e.tablePrefs) != null && Ue.enableDevModePagination) && p(!0);
6929
+ k(Pe), c.sql && ((Ue = (ze = c.preferences) == null ? void 0 : ze.tablePrefs) != null && Ue.enableDevModePagination) && p(!0);
6944
6930
  }
6945
6931
  function ce() {
6946
6932
  var pe;
@@ -6975,7 +6961,7 @@ function jl({
6975
6961
  children: [
6976
6962
  d && /* @__PURE__ */ e("div", { className: "flex grow items-center", children: /* @__PURE__ */ a("div", { className: "flex items-center gap-3", children: [
6977
6963
  (s == null ? void 0 : s.show) && /* @__PURE__ */ e(
6978
- pt,
6964
+ xt,
6979
6965
  {
6980
6966
  tooltip: s.isOpen ? "Hide Visual Aside" : "Show Visual Aside",
6981
6967
  className: "h-9 w-9 px-0",
@@ -6994,7 +6980,7 @@ function jl({
6994
6980
  /* @__PURE__ */ a("div", { className: "flex items-center gap-2", children: [
6995
6981
  t,
6996
6982
  /* @__PURE__ */ e(
6997
- pt,
6983
+ xt,
6998
6984
  {
6999
6985
  tooltip: "Refresh",
7000
6986
  disabled: N || M,
@@ -7028,12 +7014,12 @@ function jl({
7028
7014
  }
7029
7015
  ),
7030
7016
  (l || f) && /* @__PURE__ */ a(Ne, { children: [
7031
- /* @__PURE__ */ e(_h, {}),
7032
- o && /* @__PURE__ */ e(zh, {})
7017
+ /* @__PURE__ */ e(zh, {}),
7018
+ o && /* @__PURE__ */ e(Bh, {})
7033
7019
  ] }),
7034
7020
  /* @__PURE__ */ a(Ya, { modal: !1, children: [
7035
7021
  /* @__PURE__ */ e(Wa, { asChild: !0, children: /* @__PURE__ */ e(
7036
- pt,
7022
+ xt,
7037
7023
  {
7038
7024
  tooltip: "More Options",
7039
7025
  className: "h-8 w-8 px-0",
@@ -7046,7 +7032,7 @@ function jl({
7046
7032
  /* @__PURE__ */ e(Lt, {}),
7047
7033
  /* @__PURE__ */ a("div", { className: "px-1 py-1", children: [
7048
7034
  !y && !["table", "detailTable", "custom"].includes(c.type) && u && /* @__PURE__ */ e(
7049
- Ch,
7035
+ Nh,
7050
7036
  {
7051
7037
  triggerVariant: "menu",
7052
7038
  className: "w-full"
@@ -7092,7 +7078,7 @@ function jl({
7092
7078
  className: "h-8 w-full justify-start gap-2 px-2 text-sm",
7093
7079
  onClick: he,
7094
7080
  children: [
7095
- /* @__PURE__ */ e(Tm, { className: "h-4 w-4" }),
7081
+ /* @__PURE__ */ e(Sm, { className: "h-4 w-4" }),
7096
7082
  /* @__PURE__ */ e("span", { children: "Download JSON" })
7097
7083
  ]
7098
7084
  }
@@ -7146,7 +7132,7 @@ function jl({
7146
7132
  defaultSize: 30,
7147
7133
  minSize: 10,
7148
7134
  className: "relative flex h-full min-h-0 w-full flex-1 basis-0",
7149
- children: h && /* @__PURE__ */ e(Bh, {})
7135
+ children: h && /* @__PURE__ */ e(Vh, {})
7150
7136
  }
7151
7137
  ),
7152
7138
  /* @__PURE__ */ e(Qt, {})
@@ -7165,7 +7151,7 @@ function jl({
7165
7151
  ),
7166
7152
  children: [
7167
7153
  Array.isArray(L == null ? void 0 : L.records) && !R && (l ? /* @__PURE__ */ e(
7168
- gh,
7154
+ fh,
7169
7155
  {
7170
7156
  data: L.records,
7171
7157
  card: b,
@@ -7206,7 +7192,7 @@ function jl({
7206
7192
  }
7207
7193
  ) : /* @__PURE__ */ e(Ne, { children: "No Active Card" });
7208
7194
  }
7209
- function Bh() {
7195
+ function Vh() {
7210
7196
  const t = F((n) => n.pythonStdOut);
7211
7197
  if (!t) return null;
7212
7198
  const s = t.replace(/\n/g, "<br>");
@@ -7218,7 +7204,7 @@ function Bh() {
7218
7204
  ] })
7219
7205
  ] });
7220
7206
  }
7221
- function zh() {
7207
+ function Bh() {
7222
7208
  var d, i, u, f, h, p, m, x;
7223
7209
  const t = F((y) => y.card), s = F((y) => y.actions.setCard), n = F((y) => y.actions.setRunSql), r = F(
7224
7210
  (y) => y.actions.setCardPreferences
@@ -7282,7 +7268,7 @@ function zh() {
7282
7268
  )
7283
7269
  ] });
7284
7270
  }
7285
- function _h() {
7271
+ function zh() {
7286
7272
  const t = F((n) => n.isShowingVisual), s = F(
7287
7273
  (n) => n.actions.setIsShowingVisual
7288
7274
  );
@@ -7373,7 +7359,7 @@ function sa({
7373
7359
  }
7374
7360
  );
7375
7361
  }
7376
- function $h(t, s) {
7362
+ function _h(t, s) {
7377
7363
  return qs(t, s) || null;
7378
7364
  }
7379
7365
  function cn(t) {
@@ -7387,7 +7373,7 @@ function cn(t) {
7387
7373
  const n = t.match(/^(\d+)\+$/);
7388
7374
  return n ? `Tabs ${Number(n[1]) + 1}+` : `Tab ${t}`;
7389
7375
  }
7390
- function qh(t) {
7376
+ function $h(t) {
7391
7377
  return t ? Array.isArray(t) ? t : [t] : [];
7392
7378
  }
7393
7379
  function Fs(t) {
@@ -7398,7 +7384,7 @@ function Fs(t) {
7398
7384
  const s = !!((c = t.sql) != null && c.trim()), n = bn(t.config);
7399
7385
  return s || n;
7400
7386
  }
7401
- function jh({
7387
+ function qh({
7402
7388
  slots: t,
7403
7389
  cards: s,
7404
7390
  minInputs: n
@@ -7455,16 +7441,16 @@ function jh({
7455
7441
  }
7456
7442
  }), s.forEach((o, l) => {
7457
7443
  if (!o) return;
7458
- const d = $h(t, l);
7444
+ const d = _h(t, l);
7459
7445
  if (!d || !d.expectedType) return;
7460
- const i = qh(d.expectedType);
7446
+ const i = $h(d.expectedType);
7461
7447
  i.length !== 0 && (i.includes(o.type) || r.push({
7462
7448
  type: "wrong-type",
7463
7449
  message: `${cn(l)} ("${d.label}") expects ${i.join(", ")}, but is configured as ${o.type}.`
7464
7450
  }));
7465
7451
  })), r;
7466
7452
  }
7467
- const Kh = {
7453
+ const jh = {
7468
7454
  table: ({ children: t }) => /* @__PURE__ */ e("table", { className: "my-3 w-full border-collapse overflow-hidden rounded-md border border-border text-sm", children: t }),
7469
7455
  thead: ({ children: t }) => /* @__PURE__ */ e("thead", { className: "bg-muted", children: t }),
7470
7456
  th: ({ children: t }) => /* @__PURE__ */ e("th", { className: "border border-border px-3 py-2 text-left font-medium", children: t }),
@@ -7511,7 +7497,7 @@ function co() {
7511
7497
  }),
7512
7498
  [C, f == null ? void 0 : f.slots]
7513
7499
  ), B = oe(
7514
- () => jh({
7500
+ () => qh({
7515
7501
  slots: f == null ? void 0 : f.slots,
7516
7502
  cards: k,
7517
7503
  minInputs: x
@@ -7622,7 +7608,7 @@ function co() {
7622
7608
  /* @__PURE__ */ e(z, { children: $.title }),
7623
7609
  ((Y = $.docs) == null ? void 0 : Y.description) && /* @__PURE__ */ e(yt, { delayDuration: 0, children: /* @__PURE__ */ a(mt, { children: [
7624
7610
  /* @__PURE__ */ e(ht, { asChild: !0, children: /* @__PURE__ */ e(qt, { className: "h-3.5 w-3.5 cursor-help text-muted-foreground" }) }),
7625
- /* @__PURE__ */ e(xt, { side: "right", className: "max-w-xs", children: /* @__PURE__ */ e("p", { className: "text-xs", children: $.docs.description }) })
7611
+ /* @__PURE__ */ e(gt, { side: "right", className: "max-w-xs", children: /* @__PURE__ */ e("p", { className: "text-xs", children: $.docs.description }) })
7626
7612
  ] }) })
7627
7613
  ] }),
7628
7614
  D(
@@ -7726,7 +7712,7 @@ function co() {
7726
7712
  ((t == null ? void 0 : t.type) === "component" || (t == null ? void 0 : t.type) === void 0) && t && (!p || m) && /* @__PURE__ */ e(Ne, { children: i && /* @__PURE__ */ e(
7727
7713
  sa,
7728
7714
  {
7729
- icon: /* @__PURE__ */ e(Sm, { className: "h-3.5 w-3.5" }),
7715
+ icon: /* @__PURE__ */ e(wm, { className: "h-3.5 w-3.5" }),
7730
7716
  className: "h-9 w-full",
7731
7717
  label: "Select Component",
7732
7718
  options: (i == null ? void 0 : i.map((g) => ({
@@ -7780,7 +7766,7 @@ function co() {
7780
7766
  Od,
7781
7767
  {
7782
7768
  remarkPlugins: [Md],
7783
- components: Kh,
7769
+ components: jh,
7784
7770
  children: f.docs.dataSchema
7785
7771
  }
7786
7772
  ) })
@@ -7814,7 +7800,7 @@ function co() {
7814
7800
  }
7815
7801
  );
7816
7802
  }
7817
- function Gh({
7803
+ function Kh({
7818
7804
  colorRanges: t,
7819
7805
  setColorRanges: s
7820
7806
  }) {
@@ -7896,7 +7882,7 @@ function Gh({
7896
7882
  ] }, d))
7897
7883
  ] });
7898
7884
  }
7899
- function Uh() {
7885
+ function Gh() {
7900
7886
  var f, h, p, m, x;
7901
7887
  const t = F((y) => y.card.preferences), s = F(
7902
7888
  (y) => y.actions.setCardPreferences
@@ -8053,7 +8039,7 @@ function Uh() {
8053
8039
  ] }) }),
8054
8040
  /* @__PURE__ */ e(za, { className: "my-3" }),
8055
8041
  /* @__PURE__ */ e(
8056
- Gh,
8042
+ Kh,
8057
8043
  {
8058
8044
  colorRanges: d,
8059
8045
  setColorRanges: i
@@ -8062,7 +8048,7 @@ function Uh() {
8062
8048
  ] })
8063
8049
  ] });
8064
8050
  }
8065
- const Hh = {
8051
+ const Uh = {
8066
8052
  combo: {
8067
8053
  label: "Combo Chart",
8068
8054
  query: "SELECT x-axis, metric-1, metric-2, ... FROM table",
@@ -8328,9 +8314,9 @@ const Hh = {
8328
8314
  }
8329
8315
  };
8330
8316
  function uo(t) {
8331
- return Hh[t];
8317
+ return Uh[t];
8332
8318
  }
8333
- function Qh({
8319
+ function Hh({
8334
8320
  chartType: t,
8335
8321
  showDocsLink: s = !0
8336
8322
  }) {
@@ -8382,7 +8368,7 @@ function Qh({
8382
8368
  )
8383
8369
  ] }) : null;
8384
8370
  }
8385
- function Jh({
8371
+ function Qh({
8386
8372
  chartType: t
8387
8373
  }) {
8388
8374
  return uo(t) ? /* @__PURE__ */ a($n, { openDelay: 200, children: [
@@ -8401,7 +8387,7 @@ function Jh({
8401
8387
  side: "left",
8402
8388
  align: "start",
8403
8389
  sideOffset: 8,
8404
- children: /* @__PURE__ */ e(Qh, { chartType: t })
8390
+ children: /* @__PURE__ */ e(Hh, { chartType: t })
8405
8391
  }
8406
8392
  )
8407
8393
  ] }) : null;
@@ -8412,13 +8398,13 @@ function cs({
8412
8398
  }) {
8413
8399
  return /* @__PURE__ */ a("div", { className: "flex items-center justify-between", children: [
8414
8400
  /* @__PURE__ */ e("h3", { className: "text-sm font-medium", children: s }),
8415
- /* @__PURE__ */ e(Jh, { chartType: t })
8401
+ /* @__PURE__ */ e(Qh, { chartType: t })
8416
8402
  ] });
8417
8403
  }
8418
- function Yh() {
8404
+ function Jh() {
8419
8405
  return /* @__PURE__ */ a("div", { className: "space-y-6 px-6 py-4", children: [
8420
8406
  /* @__PURE__ */ e(cs, { chartType: "kpi" }),
8421
- /* @__PURE__ */ e("section", { children: /* @__PURE__ */ e(Uh, {}) })
8407
+ /* @__PURE__ */ e("section", { children: /* @__PURE__ */ e(Gh, {}) })
8422
8408
  ] });
8423
8409
  }
8424
8410
  function Kl({
@@ -8556,7 +8542,7 @@ function mo() {
8556
8542
  );
8557
8543
  }) });
8558
8544
  }
8559
- const Wh = [
8545
+ const Yh = [
8560
8546
  {
8561
8547
  label: "Mercator",
8562
8548
  value: "mercator"
@@ -8613,7 +8599,7 @@ const Wh = [
8613
8599
  label: "Natural Earth 1",
8614
8600
  value: "naturalEarth1"
8615
8601
  }
8616
- ], Xh = [
8602
+ ], Wh = [
8617
8603
  "blues",
8618
8604
  "brBG",
8619
8605
  "buGn",
@@ -8652,11 +8638,11 @@ const Wh = [
8652
8638
  "ylGnBu",
8653
8639
  "ylOrBr",
8654
8640
  "ylOrRd"
8655
- ], Zh = Xh.map((t) => ({
8641
+ ], Xh = Wh.map((t) => ({
8656
8642
  label: t,
8657
8643
  value: t
8658
8644
  }));
8659
- function ep() {
8645
+ function Zh() {
8660
8646
  var i, u, f, h, p, m, x, y, v, C, k, B, w, O, S, D, I, A;
8661
8647
  const t = F((b) => b.card), s = (u = (i = t == null ? void 0 : t.preferences) == null ? void 0 : i.mapVisualOptions) == null ? void 0 : u.topoJsonUrl, [n, r] = G(
8662
8648
  ((h = (f = t == null ? void 0 : t.preferences) == null ? void 0 : f.mapVisualOptions) == null ? void 0 : h.customTopoJsonUrl) || ""
@@ -8748,7 +8734,7 @@ function ep() {
8748
8734
  sa,
8749
8735
  {
8750
8736
  className: "h-9",
8751
- options: Wh,
8737
+ options: Yh,
8752
8738
  value: ((y = (x = t.preferences) == null ? void 0 : x.mapVisualOptions) == null ? void 0 : y.projection) || "",
8753
8739
  label: "Projection",
8754
8740
  onValueChange: (b) => {
@@ -8770,7 +8756,7 @@ function ep() {
8770
8756
  sa,
8771
8757
  {
8772
8758
  className: "h-9",
8773
- options: Zh,
8759
+ options: Xh,
8774
8760
  value: ((C = (v = t.preferences) == null ? void 0 : v.mapVisualOptions) == null ? void 0 : C.colorScale) || "",
8775
8761
  label: "Select Color Scale",
8776
8762
  onValueChange: (b) => {
@@ -8875,7 +8861,7 @@ function ho({ color: t, onColorChange: s, onClose: n }) {
8875
8861
  const C = v.currentTarget.getBoundingClientRect(), k = Math.max(0, Math.min(1, (v.clientX - C.left) / C.width)), B = Math.max(0, Math.min(1, (v.clientY - C.top) / C.height)), w = k * 100, O = (1 - B) * 100;
8876
8862
  l(w), i(O), m(r, w, O);
8877
8863
  }, m = (v, C, k) => {
8878
- const B = ap(v, C, k), w = tp(B.r, B.g, B.b);
8864
+ const B = tp(v, C, k), w = ep(B.r, B.g, B.b);
8879
8865
  f(w);
8880
8866
  }, x = (v) => {
8881
8867
  if (f(v), /^#[0-9A-Fa-f]{6}$/.test(v)) {
@@ -8995,7 +8981,7 @@ function Gl(t) {
8995
8981
  b: parseInt(s[3], 16)
8996
8982
  } : null;
8997
8983
  }
8998
- function tp(t, s, n) {
8984
+ function ep(t, s, n) {
8999
8985
  return "#" + ((1 << 24) + (t << 16) + (s << 8) + n).toString(16).slice(1);
9000
8986
  }
9001
8987
  function Ul(t, s, n) {
@@ -9023,7 +9009,7 @@ function Ul(t, s, n) {
9023
9009
  l: Math.round(d * 100)
9024
9010
  };
9025
9011
  }
9026
- function ap(t, s, n) {
9012
+ function tp(t, s, n) {
9027
9013
  t /= 360, s /= 100, n /= 100;
9028
9014
  let r, c, o;
9029
9015
  if (s === 0)
@@ -9042,7 +9028,7 @@ const Hl = [
9042
9028
  { value: "green", color: "#16a34a", label: "Green" },
9043
9029
  { value: "red", color: "#dc2626", label: "Red" },
9044
9030
  { value: "neutral", color: "#6b7280", label: "Neutral" }
9045
- ], np = [
9031
+ ], ap = [
9046
9032
  "#16a34a",
9047
9033
  // green-600
9048
9034
  "#dc2626",
@@ -9083,7 +9069,7 @@ function ra({
9083
9069
  }
9084
9070
  ) }),
9085
9071
  /* @__PURE__ */ e(kt, { align: "start", className: "w-auto p-2", children: /* @__PURE__ */ a("div", { className: "space-y-2", children: [
9086
- /* @__PURE__ */ e("div", { className: "grid grid-cols-3 items-center justify-items-center gap-1", children: np.map((i) => /* @__PURE__ */ e(
9072
+ /* @__PURE__ */ e("div", { className: "grid grid-cols-3 items-center justify-items-center gap-1", children: ap.map((i) => /* @__PURE__ */ e(
9087
9073
  "button",
9088
9074
  {
9089
9075
  className: W(
@@ -9160,14 +9146,14 @@ function Js(t, s) {
9160
9146
  maximumFractionDigits: s
9161
9147
  };
9162
9148
  }
9163
- const sp = [
9149
+ const np = [
9164
9150
  "auto",
9165
9151
  "number",
9166
9152
  "currency",
9167
9153
  "percent",
9168
9154
  "scientific",
9169
9155
  "date"
9170
- ], rp = [
9156
+ ], sp = [
9171
9157
  // 🌐 Global Reserve & Major Currencies
9172
9158
  { value: "USD", label: "USD - US Dollar" },
9173
9159
  { value: "EUR", label: "EUR - Euro" },
@@ -9220,7 +9206,7 @@ const sp = [
9220
9206
  { value: "VND", label: "VND - Vietnamese Dong" },
9221
9207
  { value: "TWD", label: "TWD - New Taiwan Dollar" },
9222
9208
  { value: "ILS", label: "ILS - Israeli New Shekel" }
9223
- ], lp = [
9209
+ ], rp = [
9224
9210
  { value: "en-US", label: "English (US)" },
9225
9211
  { value: "en-GB", label: "English (UK)" },
9226
9212
  { value: "en-IN", label: "English (India)" },
@@ -9237,7 +9223,7 @@ const sp = [
9237
9223
  { value: "hi-IN", label: "Hindi" },
9238
9224
  { value: "nl-NL", label: "Dutch" },
9239
9225
  { value: "sv-SE", label: "Swedish" }
9240
- ], ip = (t) => t.charAt(0).toUpperCase() + t.slice(1);
9226
+ ], lp = (t) => t.charAt(0).toUpperCase() + t.slice(1);
9241
9227
  function an({
9242
9228
  formatOptions: t = {},
9243
9229
  onFormatOptionsChange: s,
@@ -9289,7 +9275,7 @@ function an({
9289
9275
  children: /* @__PURE__ */ e(ne, {})
9290
9276
  }
9291
9277
  ),
9292
- /* @__PURE__ */ e(se, { children: sp.map((m) => /* @__PURE__ */ e(j, { value: m, className: "text-xs", children: m === "auto" ? "Auto (Default)" : ip(m) }, m)) })
9278
+ /* @__PURE__ */ e(se, { children: np.map((m) => /* @__PURE__ */ e(j, { value: m, className: "text-xs", children: m === "auto" ? "Auto (Default)" : lp(m) }, m)) })
9293
9279
  ]
9294
9280
  }
9295
9281
  )
@@ -9351,7 +9337,7 @@ function an({
9351
9337
  children: /* @__PURE__ */ e(ne, {})
9352
9338
  }
9353
9339
  ),
9354
- /* @__PURE__ */ e(se, { children: rp.map((m) => /* @__PURE__ */ e(
9340
+ /* @__PURE__ */ e(se, { children: sp.map((m) => /* @__PURE__ */ e(
9355
9341
  j,
9356
9342
  {
9357
9343
  value: m.value,
@@ -9394,7 +9380,7 @@ function an({
9394
9380
  children: /* @__PURE__ */ e(ne, {})
9395
9381
  }
9396
9382
  ),
9397
- /* @__PURE__ */ e(se, { children: lp.map((m) => /* @__PURE__ */ e(
9383
+ /* @__PURE__ */ e(se, { children: rp.map((m) => /* @__PURE__ */ e(
9398
9384
  j,
9399
9385
  {
9400
9386
  value: m.value,
@@ -9510,7 +9496,7 @@ function Nr({
9510
9496
  }
9511
9497
  );
9512
9498
  }
9513
- function op() {
9499
+ function ip() {
9514
9500
  const t = Me(
9515
9501
  (d) => d.dashboard.filters
9516
9502
  ), s = F((d) => d.frame), { setFrame: n } = xe(), { dashboardFilterableFields: r } = yn(), { assignFilter: c } = Vd();
@@ -9522,7 +9508,7 @@ function op() {
9522
9508
  return /* @__PURE__ */ a("div", { className: "space-y-3", children: [
9523
9509
  /* @__PURE__ */ e(z, { children: "Card Filter" }),
9524
9510
  /* @__PURE__ */ e(
9525
- cp,
9511
+ op,
9526
9512
  {
9527
9513
  onSelect: o,
9528
9514
  columns: r
@@ -9531,7 +9517,7 @@ function op() {
9531
9517
  l && /* @__PURE__ */ e(Bd, { filter: l })
9532
9518
  ] });
9533
9519
  }
9534
- function cp({
9520
+ function op({
9535
9521
  columns: t,
9536
9522
  onSelect: s
9537
9523
  }) {
@@ -9586,18 +9572,18 @@ function cp({
9586
9572
  ] }) })
9587
9573
  ] });
9588
9574
  }
9589
- const dp = [
9575
+ const cp = [
9590
9576
  { value: "difference", label: "Difference" },
9591
9577
  { value: "change", label: "Change (%)" },
9592
9578
  { value: "change_difference", label: "Change + Difference" },
9593
9579
  { value: "ratio", label: "Ratio" }
9594
- ], up = [
9580
+ ], dp = [
9595
9581
  { value: "arrow_badge", label: "Arrow + Badge" },
9596
9582
  { value: "arrow", label: "Arrow Only" },
9597
9583
  { value: "badge", label: "Badge Only" },
9598
9584
  { value: "none", label: "None" }
9599
9585
  ];
9600
- function mp({
9586
+ function up({
9601
9587
  cardType: t = "table"
9602
9588
  }) {
9603
9589
  var f, h, p, m, x;
@@ -9648,7 +9634,7 @@ function mp({
9648
9634
  }),
9649
9635
  children: [
9650
9636
  /* @__PURE__ */ e(ae, { className: "h-7 text-xs", children: /* @__PURE__ */ e(ne, {}) }),
9651
- /* @__PURE__ */ e(se, { children: dp.map((y) => /* @__PURE__ */ e(
9637
+ /* @__PURE__ */ e(se, { children: cp.map((y) => /* @__PURE__ */ e(
9652
9638
  j,
9653
9639
  {
9654
9640
  value: y.value,
@@ -9683,7 +9669,7 @@ function mp({
9683
9669
  }),
9684
9670
  children: [
9685
9671
  /* @__PURE__ */ e(ae, { className: "h-7 text-xs", children: /* @__PURE__ */ e(ne, {}) }),
9686
- /* @__PURE__ */ e(se, { children: up.map((y) => /* @__PURE__ */ e(
9672
+ /* @__PURE__ */ e(se, { children: dp.map((y) => /* @__PURE__ */ e(
9687
9673
  j,
9688
9674
  {
9689
9675
  value: y.value,
@@ -9785,7 +9771,7 @@ function mp({
9785
9771
  /* @__PURE__ */ e(je, { children: "Click Filters" }),
9786
9772
  /* @__PURE__ */ a(Ke, { className: "space-y-4 px-2", children: [
9787
9773
  /* @__PURE__ */ e(mo, {}),
9788
- /* @__PURE__ */ e(op, {})
9774
+ /* @__PURE__ */ e(ip, {})
9789
9775
  ] })
9790
9776
  ] })
9791
9777
  ] }),
@@ -9802,7 +9788,7 @@ function mp({
9802
9788
  ] })
9803
9789
  ] });
9804
9790
  }
9805
- function hp() {
9791
+ function mp() {
9806
9792
  var r;
9807
9793
  const t = F((c) => c.card.preferences), { setCardPreferences: s } = F((c) => c.actions);
9808
9794
  function n(c) {
@@ -9834,16 +9820,16 @@ function hp() {
9834
9820
  }
9835
9821
  );
9836
9822
  }
9837
- function pp() {
9823
+ function hp() {
9838
9824
  return /* @__PURE__ */ a("div", { className: "space-y-4 px-6 py-4", children: [
9839
9825
  /* @__PURE__ */ e(cs, { chartType: "text" }),
9840
9826
  /* @__PURE__ */ a("div", { className: "space-y-2", children: [
9841
9827
  /* @__PURE__ */ e(z, { children: "Text Type" }),
9842
- /* @__PURE__ */ e(hp, {})
9828
+ /* @__PURE__ */ e(mp, {})
9843
9829
  ] })
9844
9830
  ] });
9845
9831
  }
9846
- const fp = [
9832
+ const pp = [
9847
9833
  "#000000",
9848
9834
  // black
9849
9835
  "#ffffff",
@@ -9875,7 +9861,7 @@ const fp = [
9875
9861
  "#fbbf24"
9876
9862
  // yellow-400
9877
9863
  ];
9878
- function gp() {
9864
+ function fp() {
9879
9865
  var O, S, D, I, A, b, L, N, M, R;
9880
9866
  const t = F((g) => g.card), s = F((g) => {
9881
9867
  var E;
@@ -9996,7 +9982,7 @@ function gp() {
9996
9982
  }, w = Object.keys(((R = s == null ? void 0 : s.colorConfig) == null ? void 0 : R.segments) || {}).length > 0;
9997
9983
  return /* @__PURE__ */ a(qe, { value: "colors", className: "border-b-0", children: [
9998
9984
  /* @__PURE__ */ e(je, { 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: [
9999
- /* @__PURE__ */ e(Mm, { className: "h-4 w-4 text-muted-foreground" }),
9985
+ /* @__PURE__ */ e(Om, { className: "h-4 w-4 text-muted-foreground" }),
10000
9986
  /* @__PURE__ */ e("span", { children: "Colors" })
10001
9987
  ] }) }),
10002
9988
  /* @__PURE__ */ e(Ke, { className: "", children: /* @__PURE__ */ a("div", { className: "space-y-3", children: [
@@ -10051,7 +10037,7 @@ function gp() {
10051
10037
  ] }),
10052
10038
  /* @__PURE__ */ a("div", { className: "space-y-1", children: [
10053
10039
  /* @__PURE__ */ e("p", { className: "text-xs font-medium text-muted-foreground", children: "Popular Colors" }),
10054
- /* @__PURE__ */ e("div", { className: "grid grid-cols-5 gap-1.5", children: fp.map((P, V) => /* @__PURE__ */ e(
10040
+ /* @__PURE__ */ e("div", { className: "grid grid-cols-5 gap-1.5", children: pp.map((P, V) => /* @__PURE__ */ e(
10055
10041
  "button",
10056
10042
  {
10057
10043
  className: W(
@@ -10450,7 +10436,7 @@ function Ls(t, s, n) {
10450
10436
  }
10451
10437
  return "";
10452
10438
  }
10453
- function xp() {
10439
+ function gp() {
10454
10440
  const t = F((i) => i.card), s = F((i) => {
10455
10441
  var u;
10456
10442
  return (u = i.card) == null ? void 0 : u.preferences;
@@ -10529,7 +10515,7 @@ function xp() {
10529
10515
  ] }) })
10530
10516
  ] });
10531
10517
  }
10532
- function bp() {
10518
+ function xp() {
10533
10519
  const t = F((h) => h.card), s = bt(), n = F(
10534
10520
  (h) => {
10535
10521
  var p, m, x, y;
@@ -10547,7 +10533,7 @@ function bp() {
10547
10533
  }, u = ["top", "bottom", "left", "right"], f = ["start", "center", "end"];
10548
10534
  return /* @__PURE__ */ a(qe, { value: "legend", className: "border-b-0", children: [
10549
10535
  /* @__PURE__ */ e(je, { 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: [
10550
- /* @__PURE__ */ e(Dm, { className: "h-4 w-4 text-muted-foreground" }),
10536
+ /* @__PURE__ */ e(Im, { className: "h-4 w-4 text-muted-foreground" }),
10551
10537
  /* @__PURE__ */ e("span", { children: "Legend" })
10552
10538
  ] }) }),
10553
10539
  /* @__PURE__ */ e(Ke, { className: "pt-2", children: /* @__PURE__ */ a("div", { className: "space-y-3", children: [
@@ -10595,7 +10581,7 @@ function bp() {
10595
10581
  ] }) })
10596
10582
  ] });
10597
10583
  }
10598
- function vp() {
10584
+ function bp() {
10599
10585
  var M, R, g, E, T, _, P;
10600
10586
  const t = F((V) => V.card), s = bt(), n = F(
10601
10587
  (V) => {
@@ -10663,7 +10649,7 @@ function vp() {
10663
10649
  const I = () => At(S), A = ["center", "start", "end"], b = ["center", "start", "end", "top", "bottom"], L = (x == null ? void 0 : x.formatMode) || (x != null && x.format && !["auto"].includes(x.format) ? "override" : "inherit"), N = (x == null ? void 0 : x.format) === "none";
10664
10650
  return /* @__PURE__ */ a(qe, { value: "data-labels", className: "border-b-0", children: [
10665
10651
  /* @__PURE__ */ e(je, { 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: [
10666
- /* @__PURE__ */ e($m, { className: "h-4 w-4 text-muted-foreground" }),
10652
+ /* @__PURE__ */ e(_m, { className: "h-4 w-4 text-muted-foreground" }),
10667
10653
  /* @__PURE__ */ e("span", { children: "Data Labels" })
10668
10654
  ] }) }),
10669
10655
  /* @__PURE__ */ e(Ke, { className: "pt-2", children: /* @__PURE__ */ a("div", { className: "space-y-3", children: [
@@ -10901,7 +10887,7 @@ Difference: Primary - Secondary`,
10901
10887
  example: "You've achieved 80% of your sales quota."
10902
10888
  }
10903
10889
  };
10904
- function yp() {
10890
+ function vp() {
10905
10891
  var p, m, x, y, v, C, k, B, w, O;
10906
10892
  const t = F((S) => S.card), { setCardPreferences: s } = xe(), n = bt(), r = ((p = t.config) == null ? void 0 : p.metricColumns) || [], c = ((m = t.config) == null ? void 0 : m.groupByColumns) || [], o = r.length === 2 && c.length === 0, l = r.some(
10907
10893
  (S) => S.comparisonType && S.comparisonType !== "none"
@@ -10959,7 +10945,7 @@ function yp() {
10959
10945
  ),
10960
10946
  /* @__PURE__ */ a(mt, { children: [
10961
10947
  /* @__PURE__ */ e(ht, { asChild: !0, children: /* @__PURE__ */ e(qt, { className: "h-3 w-3 cursor-help text-muted-foreground" }) }),
10962
- /* @__PURE__ */ e(xt, { side: "right", className: "max-w-xs", children: (() => {
10948
+ /* @__PURE__ */ e(gt, { side: "right", className: "max-w-xs", children: (() => {
10963
10949
  const S = i.calculationType || "difference", D = Jl[S];
10964
10950
  return /* @__PURE__ */ a("div", { className: "space-y-2 text-xs", children: [
10965
10951
  /* @__PURE__ */ e("div", { className: "text-sm font-semibold", children: D == null ? void 0 : D.label }),
@@ -11242,7 +11228,7 @@ function yp() {
11242
11228
  ] })
11243
11229
  ] });
11244
11230
  }
11245
- function Np() {
11231
+ function yp() {
11246
11232
  var o;
11247
11233
  const t = F((l) => {
11248
11234
  var d;
@@ -11308,8 +11294,8 @@ function Np() {
11308
11294
  ) })
11309
11295
  ] });
11310
11296
  }
11311
- const Cp = Object.keys(Li);
11312
- function wp() {
11297
+ const Np = Object.keys(Li);
11298
+ function Cp() {
11313
11299
  const t = F((p) => p.card), s = F((p) => {
11314
11300
  var m;
11315
11301
  return (m = p.card) == null ? void 0 : m.preferences;
@@ -11349,7 +11335,7 @@ function wp() {
11349
11335
  onValueChange: (p) => u(p ?? "blue"),
11350
11336
  className: "space-y-3",
11351
11337
  children: [
11352
- Cp.map((p) => {
11338
+ Np.map((p) => {
11353
11339
  const m = Li[p];
11354
11340
  return /* @__PURE__ */ a(
11355
11341
  "div",
@@ -11433,7 +11419,7 @@ function Wl(t) {
11433
11419
  const s = { ...t };
11434
11420
  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;
11435
11421
  }
11436
- function Sp() {
11422
+ function wp() {
11437
11423
  var M, R;
11438
11424
  const t = F((g) => g.card.preferences), s = F((g) => g.card), n = F((g) => g.isDevMode), { setCardPreferences: r, setChartOrientation: c } = xe(), o = oe(
11439
11425
  () => (t == null ? void 0 : t.bulletConfig) || {},
@@ -11689,7 +11675,7 @@ function Sp() {
11689
11675
  children: /* @__PURE__ */ e(qt, { className: "h-3.5 w-3.5" })
11690
11676
  }
11691
11677
  ) }),
11692
- /* @__PURE__ */ e(xt, { side: "top", children: "Use columns or static values for Poor / Average / Good." })
11678
+ /* @__PURE__ */ e(gt, { side: "top", children: "Use columns or static values for Poor / Average / Good." })
11693
11679
  ] }) })
11694
11680
  ] }),
11695
11681
  /* @__PURE__ */ e("div", { className: "flex items-center gap-2 text-xs font-medium", children: /* @__PURE__ */ e(
@@ -11809,7 +11795,7 @@ function Xl(t) {
11809
11795
  if (s.xMetricKey || delete s.xMetricKey, s.yMetricKey || delete s.yMetricKey, s.radiusMetricKey || delete s.radiusMetricKey, s.labelKey || delete s.labelKey, s.groupKey || delete s.groupKey, s.enableGrouping === void 0 && delete s.enableGrouping, s.radiusScale || delete s.radiusScale, s.fixedRadius === void 0 && delete s.fixedRadius, s.minRadius === void 0 && delete s.minRadius, s.maxRadius === void 0 && delete s.maxRadius, Object.keys(s).length !== 0)
11810
11796
  return s;
11811
11797
  }
11812
- function Tp() {
11798
+ function Sp() {
11813
11799
  var O, S, D, I, A, b, L, N, M, R, g, E;
11814
11800
  const t = F((T) => T.card.preferences), s = F((T) => T.card), n = bt(), r = F((T) => T.isDevMode), { setCardPreferences: c, updateCardInFrame: o } = xe(), l = n === "bubble", d = n === "scatter", i = oe(
11815
11801
  () => (t == null ? void 0 : t.bubbleScatterConfig) || {},
@@ -11891,7 +11877,7 @@ function Tp() {
11891
11877
  "Dimensions",
11892
11878
  /* @__PURE__ */ e(yt, { children: /* @__PURE__ */ a(mt, { children: [
11893
11879
  /* @__PURE__ */ e(ht, { children: /* @__PURE__ */ e(qt, { className: "h-3 w-3" }) }),
11894
- /* @__PURE__ */ e(xt, { side: "right", className: "max-w-xs", children: /* @__PURE__ */ e("p", { children: "Label identifies each point. Group creates separate series in the legend." }) })
11880
+ /* @__PURE__ */ e(gt, { side: "right", className: "max-w-xs", children: /* @__PURE__ */ e("p", { children: "Label identifies each point. Group creates separate series in the legend." }) })
11895
11881
  ] }) })
11896
11882
  ] }),
11897
11883
  /* @__PURE__ */ a("div", { className: "space-y-1", children: [
@@ -12193,7 +12179,7 @@ function Tp() {
12193
12179
  ] })
12194
12180
  ] });
12195
12181
  }
12196
- const kp = [
12182
+ const Tp = [
12197
12183
  {
12198
12184
  value: "percentOfTotal",
12199
12185
  label: "% of Total",
@@ -12205,7 +12191,7 @@ const kp = [
12205
12191
  description: "First stage = 100%, others relative to first stage"
12206
12192
  }
12207
12193
  ];
12208
- function Ip() {
12194
+ function kp() {
12209
12195
  const t = F((p) => p.card), s = F((p) => {
12210
12196
  var m;
12211
12197
  return (m = p.card) == null ? void 0 : m.preferences;
@@ -12239,7 +12225,7 @@ function Ip() {
12239
12225
  value: o,
12240
12226
  onValueChange: (p) => u(p),
12241
12227
  className: "space-y-2",
12242
- children: kp.map((p) => /* @__PURE__ */ a(
12228
+ children: Tp.map((p) => /* @__PURE__ */ a(
12243
12229
  "div",
12244
12230
  {
12245
12231
  className: "flex items-start gap-2 rounded-md border border-border px-3 py-2",
@@ -12334,7 +12320,7 @@ function ds() {
12334
12320
  defaultMetricKeys: r
12335
12321
  };
12336
12322
  }
12337
- const Dp = [
12323
+ const Ip = [
12338
12324
  { value: "USD", label: "USD - US Dollar" },
12339
12325
  { value: "EUR", label: "EUR - Euro" },
12340
12326
  { value: "GBP", label: "GBP - British Pound" },
@@ -12343,7 +12329,7 @@ const Dp = [
12343
12329
  { value: "INR", label: "INR - Indian Rupee" },
12344
12330
  { value: "CAD", label: "CAD - Canadian Dollar" },
12345
12331
  { value: "AUD", label: "AUD - Australian Dollar" }
12346
- ], Ap = [
12332
+ ], Dp = [
12347
12333
  { value: "en-US", label: "English (US)" },
12348
12334
  { value: "en-GB", label: "English (UK)" },
12349
12335
  { value: "de-DE", label: "German" },
@@ -12352,7 +12338,7 @@ const Dp = [
12352
12338
  { value: "it-IT", label: "Italian" },
12353
12339
  { value: "pt-BR", label: "Portuguese (Brazil)" },
12354
12340
  { value: "zh-CN", label: "Chinese (Simplified)" }
12355
- ], Ep = ["center", "start", "end"], Op = ["center", "start", "end", "top", "bottom"];
12341
+ ], Ap = ["center", "start", "end"], Ep = ["center", "start", "end", "top", "bottom"];
12356
12342
  function us({
12357
12343
  config: t,
12358
12344
  onChange: s,
@@ -12412,7 +12398,7 @@ function us({
12412
12398
  onValueChange: (w) => i("anchor", w),
12413
12399
  children: [
12414
12400
  /* @__PURE__ */ e(ae, { className: "h-7 w-24 text-xs", children: /* @__PURE__ */ e(ne, {}) }),
12415
- /* @__PURE__ */ e(se, { children: Ep.map((w) => /* @__PURE__ */ e(j, { value: w, className: "text-xs", children: At(w) }, w)) })
12401
+ /* @__PURE__ */ e(se, { children: Ap.map((w) => /* @__PURE__ */ e(j, { value: w, className: "text-xs", children: At(w) }, w)) })
12416
12402
  ]
12417
12403
  }
12418
12404
  )
@@ -12426,7 +12412,7 @@ function us({
12426
12412
  onValueChange: (w) => i("align", w),
12427
12413
  children: [
12428
12414
  /* @__PURE__ */ e(ae, { className: "h-7 w-24 text-xs", children: /* @__PURE__ */ e(ne, {}) }),
12429
- /* @__PURE__ */ e(se, { children: Op.map((w) => /* @__PURE__ */ e(j, { value: w, className: "text-xs", children: At(w) }, w)) })
12415
+ /* @__PURE__ */ e(se, { children: Ep.map((w) => /* @__PURE__ */ e(j, { value: w, className: "text-xs", children: At(w) }, w)) })
12430
12416
  ]
12431
12417
  }
12432
12418
  )
@@ -12471,7 +12457,7 @@ function us({
12471
12457
  onValueChange: (w) => f("currency", w),
12472
12458
  children: [
12473
12459
  /* @__PURE__ */ e(ae, { className: "h-7 w-28 text-xs", children: /* @__PURE__ */ e(ne, {}) }),
12474
- /* @__PURE__ */ e(se, { children: Dp.map((w) => /* @__PURE__ */ e(
12460
+ /* @__PURE__ */ e(se, { children: Ip.map((w) => /* @__PURE__ */ e(
12475
12461
  j,
12476
12462
  {
12477
12463
  value: w.value,
@@ -12504,7 +12490,7 @@ function us({
12504
12490
  onValueChange: (w) => f("locale", w),
12505
12491
  children: [
12506
12492
  /* @__PURE__ */ e(ae, { className: "h-7 w-28 text-xs", children: /* @__PURE__ */ e(ne, {}) }),
12507
- /* @__PURE__ */ e(se, { children: Ap.map((w) => /* @__PURE__ */ e(
12493
+ /* @__PURE__ */ e(se, { children: Dp.map((w) => /* @__PURE__ */ e(
12508
12494
  j,
12509
12495
  {
12510
12496
  value: w.value,
@@ -12590,10 +12576,10 @@ function us({
12590
12576
  ] })
12591
12577
  ] });
12592
12578
  }
12593
- const Mp = [
12579
+ const Op = [
12594
12580
  { type: "bar", icon: ur, label: "Bar" },
12595
12581
  { type: "line", icon: dr, label: "Line" }
12596
- ], Fp = [0, 1, 2, 3, 4, 5, 6, 8, 10], Rp = [
12582
+ ], Mp = [0, 1, 2, 3, 4, 5, 6, 8, 10], Fp = [
12597
12583
  { value: "circle", label: "Circle ●" },
12598
12584
  { value: "rect", label: "Square ■" },
12599
12585
  { value: "rectRounded", label: "Rounded ▢" },
@@ -12604,13 +12590,13 @@ const Mp = [
12604
12590
  { value: "star", label: "Star ★" },
12605
12591
  { value: "dash", label: "Dash —" },
12606
12592
  { value: "line", label: "Line │" }
12607
- ], Lp = [
12593
+ ], Rp = [
12608
12594
  { value: "solid", label: "Solid ───" },
12609
12595
  { value: "dashed", label: "Dashed - - -" },
12610
12596
  { value: "dotted", label: "Dotted ···" },
12611
12597
  { value: "dash-dot", label: "Dash-Dot -·-·" }
12612
12598
  ];
12613
- function Pp() {
12599
+ function Lp() {
12614
12600
  return F((s) => {
12615
12601
  var n;
12616
12602
  return (n = s.card) == null ? void 0 : n.type;
@@ -12619,14 +12605,14 @@ function Pp() {
12619
12605
  /* @__PURE__ */ e(en, { className: "h-4 w-4 text-muted-foreground" }),
12620
12606
  /* @__PURE__ */ e("span", { children: "Series" })
12621
12607
  ] }) }),
12622
- /* @__PURE__ */ e(Ke, { className: "pt-2", children: /* @__PURE__ */ e(Vp, {}) })
12608
+ /* @__PURE__ */ e(Ke, { className: "pt-2", children: /* @__PURE__ */ e(Pp, {}) })
12623
12609
  ] });
12624
12610
  }
12625
- function Vp() {
12611
+ function Pp() {
12626
12612
  const { transformedMetricKeys: t } = ds();
12627
- return t.length === 0 ? /* @__PURE__ */ e("div", { className: "rounded-lg border border-dashed border-border p-4 text-center text-xs text-muted-foreground", children: "Add metrics to configure series" }) : /* @__PURE__ */ e("div", { className: "space-y-3", children: t.map((s, n) => /* @__PURE__ */ e(Bp, { metricKey: s, idx: n }, s)) });
12613
+ return t.length === 0 ? /* @__PURE__ */ e("div", { className: "rounded-lg border border-dashed border-border p-4 text-center text-xs text-muted-foreground", children: "Add metrics to configure series" }) : /* @__PURE__ */ e("div", { className: "space-y-3", children: t.map((s, n) => /* @__PURE__ */ e(Vp, { metricKey: s, idx: n }, s)) });
12628
12614
  }
12629
- function Bp({ metricKey: t, idx: s }) {
12615
+ function Vp({ metricKey: t, idx: s }) {
12630
12616
  var C;
12631
12617
  const [n, r] = G(!1), c = F((k) => {
12632
12618
  var B;
@@ -12723,7 +12709,7 @@ function Bp({ metricKey: t, idx: s }) {
12723
12709
  /* @__PURE__ */ a("div", { className: "flex items-end gap-4", children: [
12724
12710
  /* @__PURE__ */ a("div", { className: "flex-1 space-y-1.5", children: [
12725
12711
  /* @__PURE__ */ e(z, { className: "text-xs text-muted-foreground", children: "Chart Type" }),
12726
- /* @__PURE__ */ e("div", { className: "flex gap-2", children: Mp.map(({ type: k, icon: B, label: w }) => /* @__PURE__ */ a(
12712
+ /* @__PURE__ */ e("div", { className: "flex gap-2", children: Op.map(({ type: k, icon: B, label: w }) => /* @__PURE__ */ a(
12727
12713
  "button",
12728
12714
  {
12729
12715
  onClick: () => m(k),
@@ -12769,7 +12755,7 @@ function Bp({ metricKey: t, idx: s }) {
12769
12755
  onValueChange: (k) => p({ lineStyle: k }),
12770
12756
  children: [
12771
12757
  /* @__PURE__ */ e(ae, { className: "h-8 w-full text-xs", children: /* @__PURE__ */ e(ne, {}) }),
12772
- /* @__PURE__ */ e(se, { children: Lp.map(({ value: k, label: B }) => /* @__PURE__ */ e(
12758
+ /* @__PURE__ */ e(se, { children: Rp.map(({ value: k, label: B }) => /* @__PURE__ */ e(
12773
12759
  j,
12774
12760
  {
12775
12761
  value: k,
@@ -12791,7 +12777,7 @@ function Bp({ metricKey: t, idx: s }) {
12791
12777
  onValueChange: (k) => p({ pointRadius: Number(k) }),
12792
12778
  children: [
12793
12779
  /* @__PURE__ */ e(ae, { className: "h-8 w-full text-xs", children: /* @__PURE__ */ e(ne, {}) }),
12794
- /* @__PURE__ */ e(se, { children: Fp.map((k) => /* @__PURE__ */ e(
12780
+ /* @__PURE__ */ e(se, { children: Mp.map((k) => /* @__PURE__ */ e(
12795
12781
  j,
12796
12782
  {
12797
12783
  value: String(k),
@@ -12813,7 +12799,7 @@ function Bp({ metricKey: t, idx: s }) {
12813
12799
  onValueChange: (k) => p({ pointStyle: k }),
12814
12800
  children: [
12815
12801
  /* @__PURE__ */ e(ae, { className: "h-8 w-full text-xs", children: /* @__PURE__ */ e(ne, {}) }),
12816
- /* @__PURE__ */ e(se, { children: Rp.map(({ value: k, label: B }) => /* @__PURE__ */ e(
12802
+ /* @__PURE__ */ e(se, { children: Fp.map(({ value: k, label: B }) => /* @__PURE__ */ e(
12817
12803
  j,
12818
12804
  {
12819
12805
  value: k,
@@ -12861,7 +12847,7 @@ const Ps = [
12861
12847
  { value: "-1", label: "Previous Series", description: "Fill to the series below" },
12862
12848
  { value: "+1", label: "Next Series", description: "Fill to the series above" },
12863
12849
  { value: "false", label: "No Fill (Line)", description: "Show as line without fill" }
12864
- ], zp = [0, 1, 2, 3, 4, 5, 6, 8, 10], _p = [
12850
+ ], Bp = [0, 1, 2, 3, 4, 5, 6, 8, 10], zp = [
12865
12851
  { value: "circle", label: "Circle ●" },
12866
12852
  { value: "rect", label: "Square ■" },
12867
12853
  { value: "rectRounded", label: "Rounded ▢" },
@@ -12872,16 +12858,16 @@ const Ps = [
12872
12858
  { value: "star", label: "Star ★" },
12873
12859
  { value: "dash", label: "Dash —" },
12874
12860
  { value: "line", label: "Line │" }
12875
- ], $p = [
12861
+ ], _p = [
12876
12862
  { value: "solid", label: "Solid ───" },
12877
12863
  { value: "dashed", label: "Dashed - - -" },
12878
12864
  { value: "dotted", label: "Dotted ···" },
12879
12865
  { value: "dash-dot", label: "Dash-Dot -·-·" }
12880
12866
  ];
12881
- function qp(t) {
12867
+ function $p(t) {
12882
12868
  return t == null ? "origin" : t === !1 ? "false" : t;
12883
12869
  }
12884
- function jp() {
12870
+ function qp() {
12885
12871
  const t = F((s) => {
12886
12872
  var n;
12887
12873
  return (n = s.card) == null ? void 0 : n.type;
@@ -12891,14 +12877,14 @@ function jp() {
12891
12877
  /* @__PURE__ */ e(en, { className: "h-4 w-4 text-muted-foreground" }),
12892
12878
  /* @__PURE__ */ e("span", { children: "Series" })
12893
12879
  ] }) }),
12894
- /* @__PURE__ */ e(Ke, { className: "pt-2", children: /* @__PURE__ */ e(Kp, {}) })
12880
+ /* @__PURE__ */ e(Ke, { className: "pt-2", children: /* @__PURE__ */ e(jp, {}) })
12895
12881
  ] });
12896
12882
  }
12897
- function Kp() {
12883
+ function jp() {
12898
12884
  const { transformedMetricKeys: t } = ds();
12899
- return t.length === 0 ? /* @__PURE__ */ e("div", { className: "rounded-lg border border-dashed border-border p-4 text-center text-xs text-muted-foreground", children: "Add metrics to configure series" }) : /* @__PURE__ */ e("div", { className: "space-y-3", children: t.map((s, n) => /* @__PURE__ */ e(Gp, { metricKey: s, idx: n }, s)) });
12885
+ return t.length === 0 ? /* @__PURE__ */ e("div", { className: "rounded-lg border border-dashed border-border p-4 text-center text-xs text-muted-foreground", children: "Add metrics to configure series" }) : /* @__PURE__ */ e("div", { className: "space-y-3", children: t.map((s, n) => /* @__PURE__ */ e(Kp, { metricKey: s, idx: n }, s)) });
12900
12886
  }
12901
- function Gp({ metricKey: t, idx: s }) {
12887
+ function Kp({ metricKey: t, idx: s }) {
12902
12888
  var y;
12903
12889
  const [n, r] = G(!1), c = F((v) => {
12904
12890
  var C;
@@ -12908,7 +12894,7 @@ function Gp({ metricKey: t, idx: s }) {
12908
12894
  var C, k;
12909
12895
  return (k = (C = v.card) == null ? void 0 : C.preferences) == null ? void 0 : k.datasetOptions;
12910
12896
  }
12911
- ), l = o == null ? void 0 : o.find((v) => v.idx === s), { setCardPreferences: d } = F((v) => v.actions), i = qp(l == null ? void 0 : l.fill), u = ((y = l == null ? void 0 : l.dataLabels) == null ? void 0 : y.enabled) ?? !1, f = Ps.find((v) => v.value === i) || Ps[0];
12897
+ ), l = o == null ? void 0 : o.find((v) => v.idx === s), { setCardPreferences: d } = F((v) => v.actions), i = $p(l == null ? void 0 : l.fill), u = ((y = l == null ? void 0 : l.dataLabels) == null ? void 0 : y.enabled) ?? !1, f = Ps.find((v) => v.value === i) || Ps[0];
12912
12898
  function h(v) {
12913
12899
  const C = {
12914
12900
  idx: s,
@@ -13010,7 +12996,7 @@ function Gp({ metricKey: t, idx: s }) {
13010
12996
  onValueChange: (v) => h({ lineStyle: v }),
13011
12997
  children: [
13012
12998
  /* @__PURE__ */ e(ae, { className: "h-8 w-full text-xs", children: /* @__PURE__ */ e(ne, {}) }),
13013
- /* @__PURE__ */ e(se, { children: $p.map(({ value: v, label: C }) => /* @__PURE__ */ e(
12999
+ /* @__PURE__ */ e(se, { children: _p.map(({ value: v, label: C }) => /* @__PURE__ */ e(
13014
13000
  j,
13015
13001
  {
13016
13002
  value: v,
@@ -13032,7 +13018,7 @@ function Gp({ metricKey: t, idx: s }) {
13032
13018
  onValueChange: (v) => h({ pointRadius: Number(v) }),
13033
13019
  children: [
13034
13020
  /* @__PURE__ */ e(ae, { className: "h-8 w-full text-xs", children: /* @__PURE__ */ e(ne, {}) }),
13035
- /* @__PURE__ */ e(se, { children: zp.map((v) => /* @__PURE__ */ e(
13021
+ /* @__PURE__ */ e(se, { children: Bp.map((v) => /* @__PURE__ */ e(
13036
13022
  j,
13037
13023
  {
13038
13024
  value: String(v),
@@ -13054,7 +13040,7 @@ function Gp({ metricKey: t, idx: s }) {
13054
13040
  onValueChange: (v) => h({ pointStyle: v }),
13055
13041
  children: [
13056
13042
  /* @__PURE__ */ e(ae, { className: "h-8 w-full text-xs", children: /* @__PURE__ */ e(ne, {}) }),
13057
- /* @__PURE__ */ e(se, { children: _p.map(({ value: v, label: C }) => /* @__PURE__ */ e(
13043
+ /* @__PURE__ */ e(se, { children: zp.map(({ value: v, label: C }) => /* @__PURE__ */ e(
13058
13044
  j,
13059
13045
  {
13060
13046
  value: v,
@@ -13095,7 +13081,7 @@ function Gp({ metricKey: t, idx: s }) {
13095
13081
  ] }) }) })
13096
13082
  ] }) });
13097
13083
  }
13098
- const Up = [0, 1, 2, 3, 4, 5, 6, 8, 10], Hp = [
13084
+ const Gp = [0, 1, 2, 3, 4, 5, 6, 8, 10], Up = [
13099
13085
  { value: "circle", label: "Circle ●" },
13100
13086
  { value: "rect", label: "Square ■" },
13101
13087
  { value: "rectRounded", label: "Rounded ▢" },
@@ -13112,7 +13098,7 @@ const Up = [0, 1, 2, 3, 4, 5, 6, 8, 10], Hp = [
13112
13098
  { value: "dotted", label: "Dotted ···" },
13113
13099
  { value: "dash-dot", label: "Dash-Dot -·-·" }
13114
13100
  ];
13115
- function Qp() {
13101
+ function Hp() {
13116
13102
  return F((s) => {
13117
13103
  var n;
13118
13104
  return (n = s.card) == null ? void 0 : n.type;
@@ -13121,14 +13107,14 @@ function Qp() {
13121
13107
  /* @__PURE__ */ e(en, { className: "h-4 w-4 text-muted-foreground" }),
13122
13108
  /* @__PURE__ */ e("span", { children: "Series" })
13123
13109
  ] }) }),
13124
- /* @__PURE__ */ e(Ke, { className: "pt-2", children: /* @__PURE__ */ e(Jp, {}) })
13110
+ /* @__PURE__ */ e(Ke, { className: "pt-2", children: /* @__PURE__ */ e(Qp, {}) })
13125
13111
  ] });
13126
13112
  }
13127
- function Jp() {
13113
+ function Qp() {
13128
13114
  const { transformedMetricKeys: t } = ds();
13129
- return t.length === 0 ? /* @__PURE__ */ e("div", { className: "rounded-lg border border-dashed border-border p-4 text-center text-xs text-muted-foreground", children: "Add metrics to configure series" }) : /* @__PURE__ */ e("div", { className: "space-y-3", children: t.map((s, n) => /* @__PURE__ */ e(Yp, { metricKey: s, idx: n }, s)) });
13115
+ return t.length === 0 ? /* @__PURE__ */ e("div", { className: "rounded-lg border border-dashed border-border p-4 text-center text-xs text-muted-foreground", children: "Add metrics to configure series" }) : /* @__PURE__ */ e("div", { className: "space-y-3", children: t.map((s, n) => /* @__PURE__ */ e(Jp, { metricKey: s, idx: n }, s)) });
13130
13116
  }
13131
- function Yp({ metricKey: t, idx: s }) {
13117
+ function Jp({ metricKey: t, idx: s }) {
13132
13118
  var v;
13133
13119
  const [n, r] = G(!1), c = F((C) => {
13134
13120
  var k;
@@ -13239,7 +13225,7 @@ function Yp({ metricKey: t, idx: s }) {
13239
13225
  onValueChange: (C) => m({ pointRadius: Number(C) }),
13240
13226
  children: [
13241
13227
  /* @__PURE__ */ e(ae, { className: "h-8 w-full text-xs", children: /* @__PURE__ */ e(ne, {}) }),
13242
- /* @__PURE__ */ e(se, { children: Up.map((C) => /* @__PURE__ */ e(
13228
+ /* @__PURE__ */ e(se, { children: Gp.map((C) => /* @__PURE__ */ e(
13243
13229
  j,
13244
13230
  {
13245
13231
  value: String(C),
@@ -13261,7 +13247,7 @@ function Yp({ metricKey: t, idx: s }) {
13261
13247
  onValueChange: (C) => m({ pointStyle: C }),
13262
13248
  children: [
13263
13249
  /* @__PURE__ */ e(ae, { className: "h-8 w-full text-xs", children: /* @__PURE__ */ e(ne, {}) }),
13264
- /* @__PURE__ */ e(se, { children: Hp.map(({ value: C, label: k }) => /* @__PURE__ */ e(
13250
+ /* @__PURE__ */ e(se, { children: Up.map(({ value: C, label: k }) => /* @__PURE__ */ e(
13265
13251
  j,
13266
13252
  {
13267
13253
  value: C,
@@ -13302,8 +13288,8 @@ function Yp({ metricKey: t, idx: s }) {
13302
13288
  ] }) }) })
13303
13289
  ] }) });
13304
13290
  }
13305
- const Wp = [0, 2, 4, 6, 8, 10, 12, 16, 20];
13306
- function Xp() {
13291
+ const Yp = [0, 2, 4, 6, 8, 10, 12, 16, 20];
13292
+ function Wp() {
13307
13293
  const t = F((s) => {
13308
13294
  var n;
13309
13295
  return (n = s.card) == null ? void 0 : n.type;
@@ -13313,14 +13299,14 @@ function Xp() {
13313
13299
  /* @__PURE__ */ e(en, { className: "h-4 w-4 text-muted-foreground" }),
13314
13300
  /* @__PURE__ */ e("span", { children: "Series" })
13315
13301
  ] }) }),
13316
- /* @__PURE__ */ e(Ke, { className: "pt-2", children: /* @__PURE__ */ e(Zp, {}) })
13302
+ /* @__PURE__ */ e(Ke, { className: "pt-2", children: /* @__PURE__ */ e(Xp, {}) })
13317
13303
  ] });
13318
13304
  }
13319
- function Zp() {
13305
+ function Xp() {
13320
13306
  const { transformedMetricKeys: t } = ds();
13321
- return t.length === 0 ? /* @__PURE__ */ e("div", { className: "rounded-lg border border-dashed border-border p-4 text-center text-xs text-muted-foreground", children: "Add metrics to configure series" }) : /* @__PURE__ */ e("div", { className: "space-y-3", children: t.map((s, n) => /* @__PURE__ */ e(ef, { metricKey: s, idx: n }, s)) });
13307
+ return t.length === 0 ? /* @__PURE__ */ e("div", { className: "rounded-lg border border-dashed border-border p-4 text-center text-xs text-muted-foreground", children: "Add metrics to configure series" }) : /* @__PURE__ */ e("div", { className: "space-y-3", children: t.map((s, n) => /* @__PURE__ */ e(Zp, { metricKey: s, idx: n }, s)) });
13322
13308
  }
13323
- function ef({ metricKey: t, idx: s }) {
13309
+ function Zp({ metricKey: t, idx: s }) {
13324
13310
  var x;
13325
13311
  const [n, r] = G(!1), c = F((y) => {
13326
13312
  var v;
@@ -13411,7 +13397,7 @@ function ef({ metricKey: t, idx: s }) {
13411
13397
  onValueChange: (y) => h({ borderRadius: Number(y) }),
13412
13398
  children: [
13413
13399
  /* @__PURE__ */ e(ae, { className: "h-8 w-full text-xs", children: /* @__PURE__ */ e(ne, {}) }),
13414
- /* @__PURE__ */ e(se, { children: Wp.map((y) => /* @__PURE__ */ e(
13400
+ /* @__PURE__ */ e(se, { children: Yp.map((y) => /* @__PURE__ */ e(
13415
13401
  j,
13416
13402
  {
13417
13403
  value: String(y),
@@ -13451,7 +13437,7 @@ function ef({ metricKey: t, idx: s }) {
13451
13437
  ] }) }) })
13452
13438
  ] }) });
13453
13439
  }
13454
- const tf = [0, 1, 2, 3, 4, 5, 6, 8, 10], af = [
13440
+ const ef = [0, 1, 2, 3, 4, 5, 6, 8, 10], tf = [
13455
13441
  { value: "circle", label: "Circle ●" },
13456
13442
  { value: "rect", label: "Square ■" },
13457
13443
  { value: "rectRounded", label: "Rounded ▢" },
@@ -13462,13 +13448,13 @@ const tf = [0, 1, 2, 3, 4, 5, 6, 8, 10], af = [
13462
13448
  { value: "star", label: "Star ★" },
13463
13449
  { value: "dash", label: "Dash —" },
13464
13450
  { value: "line", label: "Line │" }
13465
- ], nf = [
13451
+ ], af = [
13466
13452
  { value: "solid", label: "Solid ───" },
13467
13453
  { value: "dashed", label: "Dashed - - -" },
13468
13454
  { value: "dotted", label: "Dotted ···" },
13469
13455
  { value: "dash-dot", label: "Dash-Dot -·-·" }
13470
13456
  ];
13471
- function sf() {
13457
+ function nf() {
13472
13458
  const t = F((d) => d.card), s = F((d) => {
13473
13459
  var i;
13474
13460
  return (i = d.card) == null ? void 0 : i.preferences;
@@ -13487,7 +13473,7 @@ function sf() {
13487
13473
  };
13488
13474
  return /* @__PURE__ */ a(qe, { value: "line-style", className: "border-b-0", children: [
13489
13475
  /* @__PURE__ */ e(je, { 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: [
13490
- /* @__PURE__ */ e(Bm, { className: "h-4 w-4 text-muted-foreground" }),
13476
+ /* @__PURE__ */ e(Vm, { className: "h-4 w-4 text-muted-foreground" }),
13491
13477
  /* @__PURE__ */ e("span", { children: "Line Style" })
13492
13478
  ] }) }),
13493
13479
  /* @__PURE__ */ e(Ke, { className: "pt-2", children: /* @__PURE__ */ a("div", { className: "space-y-3", children: [
@@ -13501,7 +13487,7 @@ function sf() {
13501
13487
  onValueChange: (d) => l("lineStyle", d),
13502
13488
  children: [
13503
13489
  /* @__PURE__ */ e(ae, { className: "h-8 text-xs", children: /* @__PURE__ */ e(ne, {}) }),
13504
- /* @__PURE__ */ e(se, { children: nf.map(({ value: d, label: i }) => /* @__PURE__ */ e(j, { value: d, className: "text-xs", children: i }, d)) })
13490
+ /* @__PURE__ */ e(se, { children: af.map(({ value: d, label: i }) => /* @__PURE__ */ e(j, { value: d, className: "text-xs", children: i }, d)) })
13505
13491
  ]
13506
13492
  }
13507
13493
  )
@@ -13515,7 +13501,7 @@ function sf() {
13515
13501
  onValueChange: (d) => l("pointRadius", Number(d)),
13516
13502
  children: [
13517
13503
  /* @__PURE__ */ e(ae, { className: "h-8 text-xs", children: /* @__PURE__ */ e(ne, {}) }),
13518
- /* @__PURE__ */ e(se, { children: tf.map((d) => /* @__PURE__ */ e(
13504
+ /* @__PURE__ */ e(se, { children: ef.map((d) => /* @__PURE__ */ e(
13519
13505
  j,
13520
13506
  {
13521
13507
  value: String(d),
@@ -13537,7 +13523,7 @@ function sf() {
13537
13523
  onValueChange: (d) => l("pointStyle", d),
13538
13524
  children: [
13539
13525
  /* @__PURE__ */ e(ae, { className: "h-8 text-xs", children: /* @__PURE__ */ e(ne, {}) }),
13540
- /* @__PURE__ */ e(se, { children: af.map(({ value: d, label: i }) => /* @__PURE__ */ e(j, { value: d, className: "text-xs", children: i }, d)) })
13526
+ /* @__PURE__ */ e(se, { children: tf.map(({ value: d, label: i }) => /* @__PURE__ */ e(j, { value: d, className: "text-xs", children: i }, d)) })
13541
13527
  ]
13542
13528
  }
13543
13529
  )
@@ -13545,14 +13531,14 @@ function sf() {
13545
13531
  ] }) })
13546
13532
  ] });
13547
13533
  }
13548
- const rf = [0, 2, 4, 6, 8, 10, 12, 16, 20], lf = [
13534
+ const sf = [0, 2, 4, 6, 8, 10, 12, 16, 20], rf = [
13549
13535
  { value: "0.5", label: "50%" },
13550
13536
  { value: "0.6", label: "60%" },
13551
13537
  { value: "0.7", label: "70%" },
13552
13538
  { value: "0.8", label: "80%" },
13553
13539
  { value: "0.9", label: "90%" },
13554
13540
  { value: "1", label: "100%" }
13555
- ], of = [
13541
+ ], lf = [
13556
13542
  { value: "0.5", label: "50%" },
13557
13543
  { value: "0.6", label: "60%" },
13558
13544
  { value: "0.7", label: "70%" },
@@ -13560,7 +13546,7 @@ const rf = [0, 2, 4, 6, 8, 10, 12, 16, 20], lf = [
13560
13546
  { value: "0.9", label: "90%" },
13561
13547
  { value: "1", label: "100%" }
13562
13548
  ];
13563
- function cf() {
13549
+ function of() {
13564
13550
  const t = F((d) => d.card), s = F((d) => {
13565
13551
  var i;
13566
13552
  return (i = d.card) == null ? void 0 : i.preferences;
@@ -13593,7 +13579,7 @@ function cf() {
13593
13579
  onValueChange: (d) => l("borderRadius", Number(d)),
13594
13580
  children: [
13595
13581
  /* @__PURE__ */ e(ae, { className: "h-8 text-xs", children: /* @__PURE__ */ e(ne, {}) }),
13596
- /* @__PURE__ */ e(se, { children: rf.map((d) => /* @__PURE__ */ e(
13582
+ /* @__PURE__ */ e(se, { children: sf.map((d) => /* @__PURE__ */ e(
13597
13583
  j,
13598
13584
  {
13599
13585
  value: String(d),
@@ -13615,7 +13601,7 @@ function cf() {
13615
13601
  onValueChange: (d) => l("barPercentage", Number(d)),
13616
13602
  children: [
13617
13603
  /* @__PURE__ */ e(ae, { className: "h-8 text-xs", children: /* @__PURE__ */ e(ne, {}) }),
13618
- /* @__PURE__ */ e(se, { children: lf.map(({ value: d, label: i }) => /* @__PURE__ */ e(j, { value: d, className: "text-xs", children: i }, d)) })
13604
+ /* @__PURE__ */ e(se, { children: rf.map(({ value: d, label: i }) => /* @__PURE__ */ e(j, { value: d, className: "text-xs", children: i }, d)) })
13619
13605
  ]
13620
13606
  }
13621
13607
  )
@@ -13629,7 +13615,7 @@ function cf() {
13629
13615
  onValueChange: (d) => l("categoryPercentage", Number(d)),
13630
13616
  children: [
13631
13617
  /* @__PURE__ */ e(ae, { className: "h-8 text-xs", children: /* @__PURE__ */ e(ne, {}) }),
13632
- /* @__PURE__ */ e(se, { children: of.map(({ value: d, label: i }) => /* @__PURE__ */ e(j, { value: d, className: "text-xs", children: i }, d)) })
13618
+ /* @__PURE__ */ e(se, { children: lf.map(({ value: d, label: i }) => /* @__PURE__ */ e(j, { value: d, className: "text-xs", children: i }, d)) })
13633
13619
  ]
13634
13620
  }
13635
13621
  )
@@ -13637,7 +13623,7 @@ function cf() {
13637
13623
  ] }) })
13638
13624
  ] });
13639
13625
  }
13640
- function df() {
13626
+ function cf() {
13641
13627
  const t = F(
13642
13628
  (n) => {
13643
13629
  var r, c;
@@ -13670,7 +13656,7 @@ function df() {
13670
13656
  ] }) })
13671
13657
  ] });
13672
13658
  }
13673
- const uf = ["kpi"], Zl = {
13659
+ const df = ["kpi"], Zl = {
13674
13660
  none: "None",
13675
13661
  previous_period: "Previous Period",
13676
13662
  same_period_last_year: "Same Period Last Year",
@@ -13680,25 +13666,25 @@ const uf = ["kpi"], Zl = {
13680
13666
  function da(t) {
13681
13667
  return typeof t == "string" ? t.trim().toLowerCase() : ((t == null ? void 0 : t.id) || (t == null ? void 0 : t.qualifiedFieldName) || (t == null ? void 0 : t.name) || (t == null ? void 0 : t.label) || "").trim().toLowerCase();
13682
13668
  }
13683
- function mf(t) {
13669
+ function uf(t) {
13684
13670
  if (!(t != null && t.name) || !(t != null && t.dataType) || t.role === "metric")
13685
13671
  return !1;
13686
13672
  const s = Ze(t.dataType);
13687
13673
  return ["date", "string", "boolean"].includes(s);
13688
13674
  }
13689
- function hf(t) {
13675
+ function mf(t) {
13690
13676
  return {
13691
13677
  ...t,
13692
13678
  role: "groupby"
13693
13679
  };
13694
13680
  }
13695
- function pf() {
13681
+ function hf() {
13696
13682
  var k, B;
13697
13683
  const t = F((w) => w.card), s = F(
13698
13684
  (w) => w.actions.updateCardConfig
13699
- ), n = bt(), { scopedFields: r } = zi(), c = ((k = t.config) == null ? void 0 : k.metricColumns) || [], o = ((B = t.config) == null ? void 0 : B.summary) || {}, l = o.breakdownDimensions || [], d = uf.includes(n), i = c.length > 0, u = o.enabled === !0, f = d && i, { comparisonType: h } = au(t.config, n), p = Zl[h] || Zl.none, m = Array.from(
13685
+ ), n = bt(), { scopedFields: r } = zi(), c = ((k = t.config) == null ? void 0 : k.metricColumns) || [], o = ((B = t.config) == null ? void 0 : B.summary) || {}, l = o.breakdownDimensions || [], d = df.includes(n), i = c.length > 0, u = o.enabled === !0, f = d && i, { comparisonType: h } = au(t.config, n), p = Zl[h] || Zl.none, m = Array.from(
13700
13686
  new Map(
13701
- r.filter(mf).map((w) => [da(w), hf(w)])
13687
+ r.filter(uf).map((w) => [da(w), mf(w)])
13702
13688
  ).values()
13703
13689
  ), x = new Set(
13704
13690
  m.map((w) => da(w))
@@ -13841,13 +13827,13 @@ function pf() {
13841
13827
  ] })
13842
13828
  ] });
13843
13829
  }
13844
- const ff = [];
13845
- function gf() {
13830
+ const pf = [];
13831
+ function ff() {
13846
13832
  var c;
13847
- const t = F((o) => o.card), s = ((c = t == null ? void 0 : t.config) == null ? void 0 : c.metricColumns) ?? ff, { updateMetricColumn: n, updateCardInFrame: r } = xe();
13833
+ const t = F((o) => o.card), s = ((c = t == null ? void 0 : t.config) == null ? void 0 : c.metricColumns) ?? pf, { updateMetricColumn: n, updateCardInFrame: r } = xe();
13848
13834
  return !t || t.type === "kpi" || s.length === 0 ? null : /* @__PURE__ */ a(qe, { value: "metric-formats", className: "border-b-0", children: [
13849
13835
  /* @__PURE__ */ e(je, { 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: [
13850
- /* @__PURE__ */ e(wm, { className: "h-4 w-4" }),
13836
+ /* @__PURE__ */ e(Cm, { className: "h-4 w-4" }),
13851
13837
  /* @__PURE__ */ e("span", { children: "Metric Formats" })
13852
13838
  ] }) }),
13853
13839
  /* @__PURE__ */ e(Ke, { className: "space-y-4 pt-2", children: s.map((o) => /* @__PURE__ */ a("div", { className: "space-y-2 rounded-md border border-border/60 p-3", children: [
@@ -13873,7 +13859,7 @@ function gf() {
13873
13859
  ] }, o.id)) })
13874
13860
  ] });
13875
13861
  }
13876
- const xf = /* @__PURE__ */ new Set([
13862
+ const gf = /* @__PURE__ */ new Set([
13877
13863
  "area",
13878
13864
  "bar",
13879
13865
  "bubble",
@@ -13892,12 +13878,12 @@ const xf = /* @__PURE__ */ new Set([
13892
13878
  "stackedLine",
13893
13879
  "tornado"
13894
13880
  ]);
13895
- function bf() {
13881
+ function xf() {
13896
13882
  const t = F((i) => i.card), s = F((i) => {
13897
13883
  var u;
13898
13884
  return (u = i.card) == null ? void 0 : u.preferences;
13899
13885
  }), n = bt(), { setCardPreferences: r, updateCardInFrame: c } = xe();
13900
- if (!t || !xf.has(n || ""))
13886
+ if (!t || !gf.has(n || ""))
13901
13887
  return null;
13902
13888
  const o = s == null ? void 0 : s.tooltipConfig, l = (o == null ? void 0 : o.formatMode) || (o == null ? void 0 : o.mode) || "inherit", d = (i) => {
13903
13889
  const u = {
@@ -13956,36 +13942,36 @@ function po({ mode: t }) {
13956
13942
  return (r = n.card) == null ? void 0 : r.type;
13957
13943
  });
13958
13944
  return /* @__PURE__ */ a(Ne, { children: [
13959
- s === "combo" && /* @__PURE__ */ e(Pp, {}),
13960
- (s === "area" || s === "stackedArea") && /* @__PURE__ */ e(jp, {}),
13961
- s === "line" && /* @__PURE__ */ e(Qp, {}),
13962
- (s === "bar" || s === "horizontalBar" || s === "stackedBar") && /* @__PURE__ */ e(Xp, {}),
13963
- /* @__PURE__ */ e(sf, {}),
13964
- /* @__PURE__ */ e(cf, {}),
13965
- /* @__PURE__ */ e(Np, {}),
13966
- t === "config" && /* @__PURE__ */ e(yp, {}),
13967
- t === "config" && /* @__PURE__ */ e(pf, {}),
13968
- /* @__PURE__ */ e(wp, {}),
13969
- s === "bullet" && /* @__PURE__ */ e(Sp, {}),
13970
- s === "funnel" && /* @__PURE__ */ e(Ip, {}),
13971
- (s === "bubble" || s === "scatter") && /* @__PURE__ */ e(Tp, {}),
13972
- (s === "stackedBar" || s === "stackedLine") && /* @__PURE__ */ e(df, {}),
13973
- /* @__PURE__ */ e(gf, {}),
13945
+ s === "combo" && /* @__PURE__ */ e(Lp, {}),
13946
+ (s === "area" || s === "stackedArea") && /* @__PURE__ */ e(qp, {}),
13947
+ s === "line" && /* @__PURE__ */ e(Hp, {}),
13948
+ (s === "bar" || s === "horizontalBar" || s === "stackedBar") && /* @__PURE__ */ e(Wp, {}),
13949
+ /* @__PURE__ */ e(nf, {}),
13950
+ /* @__PURE__ */ e(of, {}),
13951
+ /* @__PURE__ */ e(yp, {}),
13952
+ t === "config" && /* @__PURE__ */ e(vp, {}),
13953
+ t === "config" && /* @__PURE__ */ e(hf, {}),
13954
+ /* @__PURE__ */ e(Cp, {}),
13955
+ s === "bullet" && /* @__PURE__ */ e(wp, {}),
13956
+ s === "funnel" && /* @__PURE__ */ e(kp, {}),
13957
+ (s === "bubble" || s === "scatter") && /* @__PURE__ */ e(Sp, {}),
13958
+ (s === "stackedBar" || s === "stackedLine") && /* @__PURE__ */ e(cf, {}),
13959
+ /* @__PURE__ */ e(ff, {}),
13960
+ /* @__PURE__ */ e(fp, {}),
13974
13961
  /* @__PURE__ */ e(gp, {}),
13975
13962
  /* @__PURE__ */ e(xp, {}),
13976
13963
  /* @__PURE__ */ e(bp, {}),
13977
- /* @__PURE__ */ e(vp, {}),
13978
- /* @__PURE__ */ e(bf, {})
13964
+ /* @__PURE__ */ e(xf, {})
13979
13965
  ] });
13980
13966
  }
13981
- function vf() {
13967
+ function bf() {
13982
13968
  const t = F((n) => n.card), s = t == null ? void 0 : t.type;
13983
13969
  return s ? /* @__PURE__ */ a("div", { className: "space-y-4 px-6 py-4", children: [
13984
13970
  /* @__PURE__ */ e(cs, { chartType: s }),
13985
13971
  /* @__PURE__ */ e(qa, { type: "single", collapsible: !0, className: "w-full px-2", children: /* @__PURE__ */ e(po, { mode: "dev" }) })
13986
13972
  ] }) : null;
13987
13973
  }
13988
- function yf() {
13974
+ function vf() {
13989
13975
  const t = F((c) => c.card), s = t.type;
13990
13976
  if (tn(t) === "dynamic")
13991
13977
  return /* @__PURE__ */ e("div", { className: "p-6", children: /* @__PURE__ */ a(Mi, { children: [
@@ -13996,17 +13982,17 @@ function yf() {
13996
13982
  function r() {
13997
13983
  switch (s) {
13998
13984
  case "kpi":
13999
- return /* @__PURE__ */ e(Yh, {});
13985
+ return /* @__PURE__ */ e(Jh, {});
14000
13986
  case "table":
14001
- return /* @__PURE__ */ e(mp, {});
13987
+ return /* @__PURE__ */ e(up, {});
14002
13988
  case "map":
14003
- return /* @__PURE__ */ e(ep, {});
13989
+ return /* @__PURE__ */ e(Zh, {});
14004
13990
  case "custom":
14005
13991
  return /* @__PURE__ */ e("div", { className: "px-6 py-2", children: /* @__PURE__ */ e(co, {}) });
14006
13992
  case "text":
14007
- return /* @__PURE__ */ e(pp, {});
13993
+ return /* @__PURE__ */ e(hp, {});
14008
13994
  default:
14009
- return /* @__PURE__ */ e(vf, {});
13995
+ return /* @__PURE__ */ e(bf, {});
14010
13996
  }
14011
13997
  }
14012
13998
  return /* @__PURE__ */ a(Ja, { className: "h-full w-full text-sm", children: [
@@ -14014,7 +14000,7 @@ function yf() {
14014
14000
  /* @__PURE__ */ e(er, { orientation: "horizontal" })
14015
14001
  ] });
14016
14002
  }
14017
- function Nf() {
14003
+ function yf() {
14018
14004
  const t = Ie(null), s = Ie(null), n = F((h) => h.isShowingVisual), r = F((h) => h.isDevMode), c = F((h) => h.showAIDialog), [o, l] = G(!1), d = n && !c, i = d && (!r || o), u = r && d, f = () => l((h) => !h);
14019
14005
  return Ce(() => {
14020
14006
  var h, p, m, x;
@@ -14032,7 +14018,7 @@ function Nf() {
14032
14018
  className: "flex",
14033
14019
  minSize: 20,
14034
14020
  defaultSize: 40,
14035
- children: /* @__PURE__ */ e(hh, {})
14021
+ children: /* @__PURE__ */ e(mh, {})
14036
14022
  }
14037
14023
  ),
14038
14024
  /* @__PURE__ */ e(
@@ -14057,7 +14043,7 @@ function Nf() {
14057
14043
  className: "flex",
14058
14044
  defaultSize: 25,
14059
14045
  maxSize: 30,
14060
- children: /* @__PURE__ */ e(yf, {})
14046
+ children: /* @__PURE__ */ e(vf, {})
14061
14047
  }
14062
14048
  ) }),
14063
14049
  !c && /* @__PURE__ */ e(Qt, {}),
@@ -14087,7 +14073,7 @@ function Nf() {
14087
14073
  }
14088
14074
  );
14089
14075
  }
14090
- function Cf(t) {
14076
+ function Nf(t) {
14091
14077
  var Je;
14092
14078
  mn(
14093
14079
  (U) => U.currentAIContext
@@ -14295,7 +14281,7 @@ function Cf(t) {
14295
14281
  } else
14296
14282
  n("Analyzing...");
14297
14283
  }
14298
- function _e(U) {
14284
+ function ze(U) {
14299
14285
  const be = ou(v, U);
14300
14286
  Ue(be);
14301
14287
  }
@@ -14329,7 +14315,7 @@ function Cf(t) {
14329
14315
  }, be = Tl([...v, U]);
14330
14316
  Ue(be);
14331
14317
  }
14332
- function ft() {
14318
+ function pt() {
14333
14319
  const U = {
14334
14320
  databaseName: w || "",
14335
14321
  schemaName: D || "",
@@ -14360,9 +14346,9 @@ function Cf(t) {
14360
14346
  sendMessage: Pe,
14361
14347
  regenerate: Re,
14362
14348
  isLoading: et,
14363
- handleSetAIScope: ft,
14349
+ handleSetAIScope: pt,
14364
14350
  handleAddCurrentTableToScope: lt,
14365
- removeFromCurrentSelections: _e,
14351
+ removeFromCurrentSelections: ze,
14366
14352
  currentAssitantScope: v,
14367
14353
  setCurrentAssitantScope: M,
14368
14354
  stop: pe,
@@ -14374,7 +14360,7 @@ function Cf(t) {
14374
14360
  clearError: Te
14375
14361
  };
14376
14362
  }
14377
- const wf = [
14363
+ const Cf = [
14378
14364
  {
14379
14365
  title: "Help me write a query for",
14380
14366
  subtitle: "orders by month"
@@ -14406,7 +14392,7 @@ function ei({
14406
14392
  llmUsage: le,
14407
14393
  errorMessage: Q,
14408
14394
  clearError: ce
14409
- } = Cf(), [he, Oe] = G(""), Fe = (fe) => {
14395
+ } = Nf(), [he, Oe] = G(""), Fe = (fe) => {
14410
14396
  Oe(fe.target.value);
14411
14397
  }, me = (fe) => {
14412
14398
  fe.preventDefault();
@@ -14437,10 +14423,10 @@ function ei({
14437
14423
  // Load 5 more each time
14438
14424
  }), {
14439
14425
  scrollRef: ie,
14440
- contentRef: _e,
14426
+ contentRef: ze,
14441
14427
  isAtBottom: Ue,
14442
14428
  hasNewMessages: lt,
14443
- newMessageCount: ft,
14429
+ newMessageCount: pt,
14444
14430
  scrollToBottom: et,
14445
14431
  handleScroll: Qe,
14446
14432
  resetNewMessageCount: Je
@@ -14612,7 +14598,7 @@ function ei({
14612
14598
  }
14613
14599
  ),
14614
14600
  /* @__PURE__ */ e(
14615
- pt,
14601
+ xt,
14616
14602
  {
14617
14603
  tooltip: y ? "Exit Fullscreen" : "Expand",
14618
14604
  className: "h-7 p-2 text-muted-foreground hover:text-foreground",
@@ -14621,7 +14607,7 @@ function ei({
14621
14607
  }
14622
14608
  ),
14623
14609
  /* @__PURE__ */ e(
14624
- pt,
14610
+ xt,
14625
14611
  {
14626
14612
  className: "h-7 p-2 text-muted-foreground hover:text-foreground",
14627
14613
  tooltip: "New Chat",
@@ -14656,7 +14642,7 @@ function ei({
14656
14642
  children: /* @__PURE__ */ a(
14657
14643
  "div",
14658
14644
  {
14659
- ref: _e,
14645
+ ref: ze,
14660
14646
  className: "min-w-0 space-y-4 py-2 pr-3",
14661
14647
  "data-role": "messages",
14662
14648
  children: [
@@ -14714,7 +14700,7 @@ function ei({
14714
14700
  "aria-label": "Scroll to bottom",
14715
14701
  children: [
14716
14702
  /* @__PURE__ */ e(Et, { className: "h-4 w-4" }),
14717
- lt && ft > 0 && /* @__PURE__ */ e("span", { className: "ml-1.5 flex h-5 w-5 items-center justify-center rounded-full bg-primary text-xs text-primary-foreground", children: ft > 9 ? "9+" : ft })
14703
+ lt && pt > 0 && /* @__PURE__ */ e("span", { className: "ml-1.5 flex h-5 w-5 items-center justify-center rounded-full bg-primary text-xs text-primary-foreground", children: pt > 9 ? "9+" : pt })
14718
14704
  ]
14719
14705
  }
14720
14706
  ) }),
@@ -14724,7 +14710,7 @@ function ei({
14724
14710
  Tu,
14725
14711
  {
14726
14712
  onClick: Ve,
14727
- placeholders: wf
14713
+ placeholders: Cf
14728
14714
  }
14729
14715
  ),
14730
14716
  /* @__PURE__ */ e("div", { children: jt && T && /* @__PURE__ */ e(
@@ -14789,7 +14775,7 @@ function ei({
14789
14775
  n
14790
14776
  ) : Kt;
14791
14777
  }
14792
- function Sf(t, s, n) {
14778
+ function wf(t, s, n) {
14793
14779
  if (!s) return !1;
14794
14780
  const r = s.qualifiedFieldName, c = s.qualifiedEntityName, o = c && s.name ? `${c}.${s.name}` : r;
14795
14781
  return t.some((l) => {
@@ -14798,7 +14784,7 @@ function Sf(t, s, n) {
14798
14784
  return r ? m ? m === o || m.endsWith(`.${r}`) : f === s.name : m ? m === o : f === s.name;
14799
14785
  });
14800
14786
  }
14801
- function Tf({
14787
+ function Sf({
14802
14788
  aliasTemplate: t,
14803
14789
  onAliasTemplateChange: s
14804
14790
  }) {
@@ -14858,7 +14844,7 @@ function Tf({
14858
14844
  ] })
14859
14845
  ] });
14860
14846
  }
14861
- function kf({
14847
+ function Tf({
14862
14848
  valueAliases: t,
14863
14849
  onValueAliasesChange: s
14864
14850
  }) {
@@ -14980,7 +14966,7 @@ function kf({
14980
14966
  ] })
14981
14967
  ] });
14982
14968
  }
14983
- function If({ idx: t }) {
14969
+ function kf({ idx: t }) {
14984
14970
  var d;
14985
14971
  const s = F((i) => {
14986
14972
  var u;
@@ -15041,7 +15027,7 @@ function If({ idx: t }) {
15041
15027
  onClick: () => l("start", t),
15042
15028
  className: "h-7 p-1 text-xs font-normal",
15043
15029
  children: /* @__PURE__ */ e(
15044
- Am,
15030
+ Dm,
15045
15031
  {
15046
15032
  className: W("h-4 w-4", {
15047
15033
  "rotate-90": c === "y"
@@ -15056,7 +15042,7 @@ function If({ idx: t }) {
15056
15042
  onClick: () => l("center", t),
15057
15043
  className: "h-7 p-1 text-xs font-normal",
15058
15044
  children: /* @__PURE__ */ e(
15059
- Om,
15045
+ Em,
15060
15046
  {
15061
15047
  className: W("h-4 w-4", {
15062
15048
  "rotate-90": c === "y"
@@ -15071,7 +15057,7 @@ function If({ idx: t }) {
15071
15057
  onClick: () => l("end", t),
15072
15058
  className: "h-7 p-1 text-xs font-normal",
15073
15059
  children: /* @__PURE__ */ e(
15074
- Em,
15060
+ Am,
15075
15061
  {
15076
15062
  className: W("h-4 w-4", {
15077
15063
  "rotate-90": c === "y"
@@ -15099,13 +15085,13 @@ function Cr({
15099
15085
  children: t
15100
15086
  }
15101
15087
  ) }),
15102
- /* @__PURE__ */ e(xt, { children: t })
15088
+ /* @__PURE__ */ e(gt, { children: t })
15103
15089
  ] }) });
15104
15090
  }
15105
- function Df(t, s = 30) {
15091
+ function If(t, s = 30) {
15106
15092
  return t.length > s ? t.slice(0, s) + "..." : t;
15107
15093
  }
15108
- function Af({
15094
+ function Df({
15109
15095
  col: t,
15110
15096
  idx: s,
15111
15097
  className: n,
@@ -15154,7 +15140,7 @@ function Af({
15154
15140
  n
15155
15141
  ),
15156
15142
  children: [
15157
- c || /* @__PURE__ */ e(Cr, { className: "max-w-[100px]", title: t, children: Df(t) }),
15143
+ c || /* @__PURE__ */ e(Cr, { className: "max-w-[100px]", title: t, children: If(t) }),
15158
15144
  /* @__PURE__ */ a("div", { className: "flex gap-2", children: [
15159
15145
  /* @__PURE__ */ e(
15160
15146
  ur,
@@ -15186,13 +15172,13 @@ function Af({
15186
15172
  )
15187
15173
  }
15188
15174
  ),
15189
- /* @__PURE__ */ e(If, { idx: s })
15175
+ /* @__PURE__ */ e(kf, { idx: s })
15190
15176
  ] })
15191
15177
  ]
15192
15178
  }
15193
15179
  );
15194
15180
  }
15195
- function Ef() {
15181
+ function Af() {
15196
15182
  const t = F((d) => d.card.type), s = F((d) => d.isDevMode), n = F((d) => d.card.preferences), { setCardPreferences: r } = F((d) => d.actions);
15197
15183
  function c(d) {
15198
15184
  var f;
@@ -15261,7 +15247,7 @@ function Ef() {
15261
15247
  }
15262
15248
  return /* @__PURE__ */ e(Ne, { children: s ? o() : l() });
15263
15249
  }
15264
- function Of({
15250
+ function Ef({
15265
15251
  column: t
15266
15252
  }) {
15267
15253
  const s = F((i) => i.card.type), n = F(
@@ -15273,12 +15259,12 @@ function Of({
15273
15259
  (i) => i === t.label || i === t.name
15274
15260
  ), o = c ? r.indexOf(c) : -1;
15275
15261
  function l() {
15276
- return /* @__PURE__ */ e("div", { className: "pr-1", children: c && /* @__PURE__ */ e(Af, { idx: o, col: c, children: /* @__PURE__ */ e("div", { className: "w-[130px] text-xs text-muted-foreground", children: "Display Series As" }) }) });
15262
+ return /* @__PURE__ */ e("div", { className: "pr-1", children: c && /* @__PURE__ */ e(Df, { idx: o, col: c, children: /* @__PURE__ */ e("div", { className: "w-[130px] text-xs text-muted-foreground", children: "Display Series As" }) }) });
15277
15263
  }
15278
15264
  function d() {
15279
15265
  return /* @__PURE__ */ a("div", { className: "space-y-1", children: [
15280
15266
  /* @__PURE__ */ e(z, { className: "text-xs font-medium text-muted-foreground", children: "Data Labels" }),
15281
- /* @__PURE__ */ e(Ef, {})
15267
+ /* @__PURE__ */ e(Af, {})
15282
15268
  ] });
15283
15269
  }
15284
15270
  return /* @__PURE__ */ a("div", { className: "space-y-1", children: [
@@ -15286,7 +15272,7 @@ function Of({
15286
15272
  ["pie", "doughnut"].includes(s) && d()
15287
15273
  ] });
15288
15274
  }
15289
- function Mf({
15275
+ function Of({
15290
15276
  field: t,
15291
15277
  searchQuery: s = "",
15292
15278
  limit: n = 500
@@ -15515,7 +15501,7 @@ function fo({
15515
15501
  ] }),
15516
15502
  m.length === 0 && !u && n.length > 0 && /* @__PURE__ */ e("div", { className: "text-center py-4 text-sm text-muted-foreground", children: "All available fields are already filtered" })
15517
15503
  ] }) : /* @__PURE__ */ e(
15518
- Ff,
15504
+ Mf,
15519
15505
  {
15520
15506
  field: h.field,
15521
15507
  selectedValues: h.selectedValues,
@@ -15540,7 +15526,7 @@ function fo({
15540
15526
  ] })
15541
15527
  ] }) });
15542
15528
  }
15543
- function Ff({
15529
+ function Mf({
15544
15530
  field: t,
15545
15531
  selectedValues: s,
15546
15532
  onValuesChange: n,
@@ -15550,7 +15536,7 @@ function Ff({
15550
15536
  values: l,
15551
15537
  isLoading: d,
15552
15538
  isFetching: i
15553
- } = Mf({
15539
+ } = Of({
15554
15540
  field: t,
15555
15541
  searchQuery: c,
15556
15542
  limit: 500
@@ -15618,7 +15604,7 @@ function Ff({
15618
15604
  ] })
15619
15605
  ] });
15620
15606
  }
15621
- function Rf({
15607
+ function Ff({
15622
15608
  field: t,
15623
15609
  zone: s,
15624
15610
  index: n,
@@ -15667,7 +15653,7 @@ function Rf({
15667
15653
  } = qi(m), [Fe, me] = G(!1), [pe, Te] = G(() => {
15668
15654
  var J;
15669
15655
  return !!((J = t.parameters) != null && J.windowTransform);
15670
- }), [Pe, Re] = G(!1), [ue, ie] = G(!1), [_e, Ue] = G(null), lt = oe(() => {
15656
+ }), [Pe, Re] = G(!1), [ue, ie] = G(!1), [ze, Ue] = G(null), lt = oe(() => {
15671
15657
  const J = (ve) => ve != null && ve.startsWith("card-source-") ? ve.replace("card-source-", "") : ve, ee = J(t.id), Se = k.find((ve) => {
15672
15658
  if (t.qualifiedFieldName && ve.qualifiedFieldName && ve.qualifiedFieldName === t.qualifiedFieldName || t.qualifiedEntityName && ve.qualifiedEntityName && ve.qualifiedEntityName === t.qualifiedEntityName && ve.name === t.name)
15673
15659
  return !0;
@@ -15685,7 +15671,7 @@ function Rf({
15685
15671
  t.qualifiedEntityName,
15686
15672
  t.qualifiedFieldName,
15687
15673
  k
15688
- ]), ft = Lu(
15674
+ ]), pt = Lu(
15689
15675
  lt.dataType
15690
15676
  ), [et, Qe] = G(
15691
15677
  t.dateFormat || "YYYY-MM-DD"
@@ -15738,7 +15724,7 @@ function Rf({
15738
15724
  return (ee = J.dashboard) == null ? void 0 : ee.filters;
15739
15725
  }), hs = Me(
15740
15726
  (J) => J.filterValues
15741
- ), Xt = t.granularity || "day", kn = ft.includes(Xt) ? Xt : "day", rn = s === "groupBy" && !ft.includes(Xt), Ma = Ss(kn), ps = be ? "custom" : Ma.some((J) => J.value === et) ? et : ((Fr = Ma[0]) == null ? void 0 : Fr.value) ?? "YYYY-MM-DD";
15727
+ ), Xt = t.granularity || "day", kn = pt.includes(Xt) ? Xt : "day", rn = s === "groupBy" && !pt.includes(Xt), Ma = Ss(kn), ps = be ? "custom" : Ma.some((J) => J.value === et) ? et : ((Fr = Ma[0]) == null ? void 0 : Fr.value) ?? "YYYY-MM-DD";
15742
15728
  Ce(() => {
15743
15729
  var Se;
15744
15730
  if (w || !rn) {
@@ -15788,7 +15774,7 @@ function Rf({
15788
15774
  }, Se = (Xe) => Xe.conditions.some((vt) => Ze(vt.field.dataType || "") === "date" && ee(vt)) ? !0 : Xe.groups.some((vt) => Se(vt));
15789
15775
  return Se(J);
15790
15776
  }, [(Rr = m.config) == null ? void 0 : Rr.filters, Dt]), Dn = oe(
15791
- () => Sf(
15777
+ () => wf(
15792
15778
  Vt || [],
15793
15779
  Dt,
15794
15780
  hs
@@ -15803,7 +15789,7 @@ function Rf({
15803
15789
  It || []
15804
15790
  ), rt = ((zr = (Br = (Vr = K.parameters) == null ? void 0 : Vr.windowTransform) == null ? void 0 : Br.orderBy) == null ? void 0 : zr.fieldId) || "", Bt = ((qr = ($r = (_r = K.parameters) == null ? void 0 : _r.windowTransform) == null ? void 0 : $r.orderBy) == null ? void 0 : qr.direction) || "asc", ca = tt.find(
15805
15791
  (J) => J.id === rt
15806
- ), Zt = ye === "running_total" || ye === "moving_average" || ye === "previous_period_delta", gt = Z && Zt && !!ca && Ze(ca.dataType || "") !== "date", Ra = Ku({
15792
+ ), Zt = ye === "running_total" || ye === "moving_average" || ye === "previous_period_delta", ft = Z && Zt && !!ca && Ze(ca.dataType || "") !== "date", Ra = Ku({
15807
15793
  cardType: l || "table",
15808
15794
  cardConfig: m.config || {},
15809
15795
  orderByFieldId: rt || void 0
@@ -15891,7 +15877,7 @@ function Rf({
15891
15877
  onValueChange: jt,
15892
15878
  children: [
15893
15879
  /* @__PURE__ */ e(ae, { className: "h-8 w-full text-xs", children: /* @__PURE__ */ e(ne, { placeholder: "Select granularity..." }) }),
15894
- /* @__PURE__ */ e(se, { children: ft.map((J) => /* @__PURE__ */ e(j, { className: "text-xs", value: J, children: Dl(J) }, J)) })
15880
+ /* @__PURE__ */ e(se, { children: pt.map((J) => /* @__PURE__ */ e(j, { className: "text-xs", value: J, children: Dl(J) }, J)) })
15895
15881
  ]
15896
15882
  }
15897
15883
  )
@@ -16132,7 +16118,7 @@ function Rf({
16132
16118
  }
16133
16119
  ),
16134
16120
  !rt && /* @__PURE__ */ e("div", { className: "text-xs text-amber-700", children: "No date trend detected. Select an order field." }),
16135
- gt && /* @__PURE__ */ e("div", { className: "text-xs text-amber-700", children: "No date trend detected. The transform will follow the selected order field." })
16121
+ ft && /* @__PURE__ */ e("div", { className: "text-xs text-amber-700", children: "No date trend detected. The transform will follow the selected order field." })
16136
16122
  ] }),
16137
16123
  /* @__PURE__ */ a("div", { className: "space-y-1", children: [
16138
16124
  /* @__PURE__ */ e(z, { className: "text-xs font-medium text-muted-foreground", children: "Direction" }),
@@ -16302,7 +16288,7 @@ function Rf({
16302
16288
  children: at
16303
16289
  }
16304
16290
  ) }),
16305
- ee && Se && /* @__PURE__ */ e(xt, { side: "right", children: Se })
16291
+ ee && Se && /* @__PURE__ */ e(gt, { side: "right", children: Se })
16306
16292
  ] }) });
16307
16293
  return /* @__PURE__ */ a(Ne, { children: [
16308
16294
  ve("previous_period", "Previous Period"),
@@ -16360,7 +16346,7 @@ function Rf({
16360
16346
  /* @__PURE__ */ e(yt, { children: /* @__PURE__ */ a(mt, { children: [
16361
16347
  /* @__PURE__ */ e(ht, { asChild: !0, children: /* @__PURE__ */ e("span", { className: "cursor-help text-muted-foreground", children: Array.isArray(ee.value) ? ee.value.length === 1 ? String(ee.value[0]) : ee.value.length <= 2 ? ee.value.join(", ") : `${ee.value.slice(0, 2).join(", ")} +${ee.value.length - 2}` : String(ee.value) }) }),
16362
16348
  Array.isArray(ee.value) && ee.value.length > 1 && /* @__PURE__ */ e(
16363
- xt,
16349
+ gt,
16364
16350
  {
16365
16351
  side: "top",
16366
16352
  className: "max-w-[300px]",
@@ -16431,17 +16417,17 @@ function Rf({
16431
16417
  }
16432
16418
  )
16433
16419
  ] }),
16434
- /* @__PURE__ */ e(Of, { column: t }),
16420
+ /* @__PURE__ */ e(Ef, { column: t }),
16435
16421
  o && /* @__PURE__ */ a(Ne, { children: [
16436
16422
  /* @__PURE__ */ e(
16437
- Tf,
16423
+ Sf,
16438
16424
  {
16439
16425
  aliasTemplate: X,
16440
16426
  onAliasTemplateChange: Kt
16441
16427
  }
16442
16428
  ),
16443
16429
  /* @__PURE__ */ e(
16444
- kf,
16430
+ Tf,
16445
16431
  {
16446
16432
  valueAliases: we,
16447
16433
  onValueAliasesChange: fe
@@ -16507,7 +16493,7 @@ function Rf({
16507
16493
  /* @__PURE__ */ e(ba, { className: "h-3 w-3" }),
16508
16494
  /* @__PURE__ */ e("span", { children: Ve.conditions.length })
16509
16495
  ] }) }),
16510
- /* @__PURE__ */ e(xt, { side: "top", children: /* @__PURE__ */ e("div", { className: "text-xs", children: Ve.conditions.map((J) => /* @__PURE__ */ a("div", { children: [
16496
+ /* @__PURE__ */ e(gt, { side: "top", children: /* @__PURE__ */ e("div", { className: "text-xs", children: Ve.conditions.map((J) => /* @__PURE__ */ a("div", { children: [
16511
16497
  J.field.label,
16512
16498
  ":",
16513
16499
  " ",
@@ -16577,7 +16563,7 @@ function Rf({
16577
16563
  },
16578
16564
  availableFields: B,
16579
16565
  existingFilters: Ve,
16580
- editingCondition: _e,
16566
+ editingCondition: ze,
16581
16567
  onSave: (J) => {
16582
16568
  var ee;
16583
16569
  if (J)
@@ -16676,10 +16662,10 @@ function Rf({
16676
16662
  )
16677
16663
  ] });
16678
16664
  }
16679
- function Lf({ concept: t }) {
16665
+ function Rf({ concept: t }) {
16680
16666
  return /* @__PURE__ */ e(yt, { children: /* @__PURE__ */ a(mt, { delayDuration: 300, children: [
16681
16667
  /* @__PURE__ */ e(ht, { asChild: !0, children: /* @__PURE__ */ e(Qu, { className: "size-4 text-muted-foreground hover:text-foreground" }) }),
16682
- /* @__PURE__ */ e(xt, { side: "right", align: "start", className: "p-3", children: (() => {
16668
+ /* @__PURE__ */ e(gt, { side: "right", align: "start", className: "p-3", children: (() => {
16683
16669
  switch (t) {
16684
16670
  case "groupBy":
16685
16671
  return /* @__PURE__ */ a("div", { className: "w-64 space-y-2", children: [
@@ -16769,10 +16755,10 @@ function Lf({ concept: t }) {
16769
16755
  })() })
16770
16756
  ] }) });
16771
16757
  }
16772
- const Pf = {
16758
+ const Lf = {
16773
16759
  groupBy: os,
16774
16760
  pivotBy: gr,
16775
- metrics: Vm,
16761
+ metrics: Pm,
16776
16762
  detailColumns: Zn,
16777
16763
  sortBy: Bi
16778
16764
  };
@@ -16799,7 +16785,7 @@ function dn({
16799
16785
  };
16800
16786
  if (t === "sortBy" && c === !1)
16801
16787
  return null;
16802
- const y = t !== "sortBy" && h !== "kpi", v = Pf[t] || St;
16788
+ const y = t !== "sortBy" && h !== "kpi", v = Lf[t] || St;
16803
16789
  return /* @__PURE__ */ a("div", { className: "mb-3 w-full", children: [
16804
16790
  /* @__PURE__ */ e("div", { className: "mb-1.5 flex items-center gap-2", children: /* @__PURE__ */ e(
16805
16791
  z,
@@ -16832,7 +16818,7 @@ function dn({
16832
16818
  children: s.length === 0 ? /* @__PURE__ */ a("div", { className: "flex min-h-[56px] items-center justify-center gap-2 text-sm text-muted-foreground/85", children: [
16833
16819
  /* @__PURE__ */ e(v, { className: "h-3.5 w-3.5 shrink-0 text-muted-foreground/80" }),
16834
16820
  /* @__PURE__ */ e("span", { children: r }),
16835
- y && /* @__PURE__ */ e(Lf, { concept: t })
16821
+ y && /* @__PURE__ */ e(Rf, { concept: t })
16836
16822
  ] }) : /* @__PURE__ */ e(
16837
16823
  oa,
16838
16824
  {
@@ -16846,7 +16832,7 @@ function dn({
16846
16832
  {
16847
16833
  className: "flex w-full items-center gap-2",
16848
16834
  children: /* @__PURE__ */ e("div", { className: "min-w-0 flex-1", children: /* @__PURE__ */ e(
16849
- Rf,
16835
+ Ff,
16850
16836
  {
16851
16837
  field: C,
16852
16838
  zone: t,
@@ -16867,7 +16853,7 @@ function dn({
16867
16853
  )
16868
16854
  ] });
16869
16855
  }
16870
- function Vf({
16856
+ function Pf({
16871
16857
  groupByFields: t,
16872
16858
  pivotByFields: s,
16873
16859
  metricsFields: n,
@@ -17077,7 +17063,7 @@ function Vf({
17077
17063
  )
17078
17064
  ] });
17079
17065
  }
17080
- function Bf({ onEditJoins: t }) {
17066
+ function Vf({ onEditJoins: t }) {
17081
17067
  const s = F((d) => d.card), { autoJoinMetadata: n } = Nt(s);
17082
17068
  if (!(n != null && n.autoResolved))
17083
17069
  return null;
@@ -17095,7 +17081,7 @@ function Bf({ onEditJoins: t }) {
17095
17081
  }));
17096
17082
  return /* @__PURE__ */ e(Qn, { className: "border-blue-500/20 bg-blue-50/15 shadow-sm dark:bg-blue-950/10", children: /* @__PURE__ */ a("div", { className: "flex items-center justify-between p-3", children: [
17097
17083
  /* @__PURE__ */ a("div", { className: "flex items-center gap-2", children: [
17098
- /* @__PURE__ */ e(qm, { className: "size-4 text-blue-600/90 dark:text-blue-400" }),
17084
+ /* @__PURE__ */ e($m, { className: "size-4 text-blue-600/90 dark:text-blue-400" }),
17099
17085
  /* @__PURE__ */ e("h3", { className: "text-xs font-semibold tracking-wide text-blue-900/90 dark:text-blue-100", children: "Resolved Joins" }),
17100
17086
  /* @__PURE__ */ e(yt, { children: /* @__PURE__ */ a(mt, { children: [
17101
17087
  /* @__PURE__ */ e(ht, { asChild: !0, children: /* @__PURE__ */ e(
@@ -17107,7 +17093,7 @@ function Bf({ onEditJoins: t }) {
17107
17093
  }
17108
17094
  ) }),
17109
17095
  /* @__PURE__ */ e(
17110
- xt,
17096
+ gt,
17111
17097
  {
17112
17098
  side: "bottom",
17113
17099
  align: "start",
@@ -17194,7 +17180,7 @@ const ti = {
17194
17180
  }
17195
17181
  }
17196
17182
  };
17197
- function zf({
17183
+ function Bf({
17198
17184
  selectedChart: t,
17199
17185
  onChartChange: s,
17200
17186
  groupByFields: n,
@@ -17302,9 +17288,9 @@ function zf({
17302
17288
  C ? "pt-1" : "pt-4"
17303
17289
  ),
17304
17290
  children: [
17305
- /* @__PURE__ */ e(Bf, { onEditJoins: D }),
17291
+ /* @__PURE__ */ e(Vf, { onEditJoins: D }),
17306
17292
  /* @__PURE__ */ e(
17307
- Vf,
17293
+ Pf,
17308
17294
  {
17309
17295
  groupByFields: n,
17310
17296
  pivotByFields: r,
@@ -17334,7 +17320,7 @@ function zf({
17334
17320
  }
17335
17321
  );
17336
17322
  }
17337
- function _f({
17323
+ function zf({
17338
17324
  initialFilters: t,
17339
17325
  availableFields: s
17340
17326
  } = {}) {
@@ -17560,7 +17546,7 @@ function _f({
17560
17546
  hasAnyFilters: B
17561
17547
  };
17562
17548
  }
17563
- function $f({
17549
+ function _f({
17564
17550
  children: t,
17565
17551
  className: s,
17566
17552
  delayDuration: n
@@ -17576,17 +17562,17 @@ function $f({
17576
17562
  children: t
17577
17563
  }
17578
17564
  ) }),
17579
- /* @__PURE__ */ e(xt, { children: t })
17565
+ /* @__PURE__ */ e(gt, { children: t })
17580
17566
  ] }) });
17581
17567
  }
17582
- const qf = (t) => {
17568
+ const $f = (t) => {
17583
17569
  if (t.qualifiedEntityName) {
17584
17570
  const s = t.qualifiedEntityName.split(".");
17585
17571
  return s.length > 1 ? s[0] : "default";
17586
17572
  }
17587
17573
  return "default";
17588
17574
  };
17589
- function jf({
17575
+ function qf({
17590
17576
  value: t,
17591
17577
  onValueChange: s,
17592
17578
  availableFields: n,
@@ -17596,7 +17582,7 @@ function jf({
17596
17582
  const [o, l] = ta.useState(!1), d = ta.useMemo(() => {
17597
17583
  const i = {};
17598
17584
  return n.forEach((u) => {
17599
- const f = qf(u);
17585
+ const f = $f(u);
17600
17586
  i[f] || (i[f] = {}), i[f][u.entityId] || (i[f][u.entityId] = []), i[f][u.entityId].push(u);
17601
17587
  }), i;
17602
17588
  }, [n]);
@@ -17613,7 +17599,7 @@ function jf({
17613
17599
  c
17614
17600
  ),
17615
17601
  children: [
17616
- t ? /* @__PURE__ */ e("div", { className: "flex items-center gap-2", children: /* @__PURE__ */ a($f, { children: [
17602
+ t ? /* @__PURE__ */ e("div", { className: "flex items-center gap-2", children: /* @__PURE__ */ a(_f, { children: [
17617
17603
  t.entityName,
17618
17604
  ".",
17619
17605
  t.name
@@ -17727,7 +17713,7 @@ function wr(t) {
17727
17713
  })
17728
17714
  ), isPending: p, error: m };
17729
17715
  }
17730
- function Kf({
17716
+ function jf({
17731
17717
  field: t,
17732
17718
  selected: s,
17733
17719
  onChange: n,
@@ -17806,7 +17792,7 @@ function Kf({
17806
17792
  ] }) })
17807
17793
  ] }) });
17808
17794
  }
17809
- function Gf({
17795
+ function Kf({
17810
17796
  field: t,
17811
17797
  value: s,
17812
17798
  onChange: n,
@@ -17830,7 +17816,7 @@ function Gf({
17830
17816
  )) })
17831
17817
  ] });
17832
17818
  }
17833
- function Uf({
17819
+ function Gf({
17834
17820
  value: t,
17835
17821
  operator: s,
17836
17822
  onChange: n,
@@ -17883,7 +17869,7 @@ function Uf({
17883
17869
  }
17884
17870
  );
17885
17871
  }
17886
- const Hf = [
17872
+ const Uf = [
17887
17873
  "=",
17888
17874
  "!=",
17889
17875
  ">",
@@ -17897,7 +17883,7 @@ const Hf = [
17897
17883
  "not in",
17898
17884
  "isNull",
17899
17885
  "isNotNull"
17900
- ], Qf = [
17886
+ ], Hf = [
17901
17887
  "=",
17902
17888
  "!=",
17903
17889
  "contains",
@@ -17907,7 +17893,7 @@ const Hf = [
17907
17893
  "not in",
17908
17894
  "isNull",
17909
17895
  "isNotNull"
17910
- ], Jf = [
17896
+ ], Qf = [
17911
17897
  "=",
17912
17898
  "!=",
17913
17899
  ">",
@@ -17918,7 +17904,7 @@ const Hf = [
17918
17904
  "not in",
17919
17905
  "isNull",
17920
17906
  "isNotNull"
17921
- ], Yf = ["=", "!=", "isNull", "isNotNull"], Wf = [
17907
+ ], Jf = ["=", "!=", "isNull", "isNotNull"], Yf = [
17922
17908
  "between",
17923
17909
  // Default operator for dates
17924
17910
  "=",
@@ -17929,7 +17915,7 @@ const Hf = [
17929
17915
  ">=",
17930
17916
  "isNull",
17931
17917
  "isNotNull"
17932
- ], Xf = {
17918
+ ], Wf = {
17933
17919
  "=": "Equals",
17934
17920
  "!=": "Not Equals",
17935
17921
  ">": "Greater Than",
@@ -17947,20 +17933,20 @@ const Hf = [
17947
17933
  "not between": "Not Between"
17948
17934
  };
17949
17935
  function ai(t) {
17950
- return Xf[t] || At(t);
17936
+ return Wf[t] || At(t);
17951
17937
  }
17952
- function Zf(t) {
17938
+ function Xf(t) {
17953
17939
  switch (t) {
17954
17940
  case "string":
17955
- return Qf;
17941
+ return Hf;
17956
17942
  case "number":
17957
- return Jf;
17943
+ return Qf;
17958
17944
  case "boolean":
17959
- return Yf;
17945
+ return Jf;
17960
17946
  case "date":
17961
- return Wf;
17947
+ return Yf;
17962
17948
  default:
17963
- return Hf;
17949
+ return Uf;
17964
17950
  }
17965
17951
  }
17966
17952
  function go({
@@ -18019,7 +18005,7 @@ function go({
18019
18005
  ),
18020
18006
  s === 0 && /* @__PURE__ */ e("div", { className: "w-24" }),
18021
18007
  /* @__PURE__ */ e(
18022
- jf,
18008
+ qf,
18023
18009
  {
18024
18010
  value: t.field,
18025
18011
  onValueChange: (k) => {
@@ -18057,7 +18043,7 @@ function go({
18057
18043
  },
18058
18044
  children: [
18059
18045
  /* @__PURE__ */ e(ae, { className: "w-32", children: /* @__PURE__ */ e(ne, { children: t.operator ? ai(t.operator) : "" }) }),
18060
- /* @__PURE__ */ e(se, { children: Zf(Ze(t.field.dataType)).map(
18046
+ /* @__PURE__ */ e(se, { children: Xf(Ze(t.field.dataType)).map(
18061
18047
  (k) => /* @__PURE__ */ e(j, { className: "hover:bg-muted", value: k, children: ai(k) }, k)
18062
18048
  ) })
18063
18049
  ]
@@ -18067,7 +18053,7 @@ function go({
18067
18053
  /* @__PURE__ */ e(la, { className: "mr-2 size-3.5 animate-spin" }),
18068
18054
  " Loading values..."
18069
18055
  ] }) : v ? /* @__PURE__ */ e("div", { className: "flex-1 p-2 text-xs text-red-500", children: "Error loading values" }) : /* @__PURE__ */ e(
18070
- Kf,
18056
+ jf,
18071
18057
  {
18072
18058
  field: t.field,
18073
18059
  selected: Array.isArray(t.value) && t.value.every((k) => typeof k == "string") ? t.value : [],
@@ -18090,7 +18076,7 @@ function go({
18090
18076
  placeholder: t.operator.charAt(0).toUpperCase() + t.operator.slice(1) + "..."
18091
18077
  }
18092
18078
  ) : /* @__PURE__ */ e(
18093
- Gf,
18079
+ Kf,
18094
18080
  {
18095
18081
  field: t.field,
18096
18082
  value: typeof t.value == "string" ? t.value : "",
@@ -18119,7 +18105,7 @@ function go({
18119
18105
  // - Handles different operators (=, !=, >, <, between, in, etc.)
18120
18106
  // - Supports timezone-aware date selection
18121
18107
  /* @__PURE__ */ e(
18122
- Uf,
18108
+ Gf,
18123
18109
  {
18124
18110
  value: t.value,
18125
18111
  operator: t.operator,
@@ -18150,7 +18136,7 @@ function go({
18150
18136
  }
18151
18137
  );
18152
18138
  }
18153
- function eg({
18139
+ function Zf({
18154
18140
  group: t,
18155
18141
  depth: s,
18156
18142
  parentGroupId: n,
@@ -18343,7 +18329,7 @@ function eg({
18343
18329
  }
18344
18330
  );
18345
18331
  }
18346
- function tg({
18332
+ function eg({
18347
18333
  filters: t,
18348
18334
  availableFields: s,
18349
18335
  onSave: n,
@@ -18367,7 +18353,7 @@ function tg({
18367
18353
  generateSQLPreview: k,
18368
18354
  hasAnyFilters: B,
18369
18355
  setCurrentFilters: w
18370
- } = _f({
18356
+ } = zf({
18371
18357
  initialFilters: t,
18372
18358
  availableFields: s
18373
18359
  }), O = fn(
@@ -18487,7 +18473,7 @@ function tg({
18487
18473
  )
18488
18474
  ] })
18489
18475
  ] }) }, L.id) : /* @__PURE__ */ e(
18490
- eg,
18476
+ Zf,
18491
18477
  {
18492
18478
  group: L,
18493
18479
  depth: N,
@@ -18552,7 +18538,7 @@ function tg({
18552
18538
  ] })
18553
18539
  ] });
18554
18540
  }
18555
- function ag({
18541
+ function tg({
18556
18542
  cardId: t,
18557
18543
  filters: s,
18558
18544
  onFiltersChange: n,
@@ -18576,7 +18562,7 @@ function ag({
18576
18562
  /* @__PURE__ */ e(Ba, { children: "Add filters to the card to limit the data that is displayed." })
18577
18563
  ] }),
18578
18564
  /* @__PURE__ */ e(
18579
- tg,
18565
+ eg,
18580
18566
  {
18581
18567
  filters: s,
18582
18568
  availableFields: c,
@@ -18594,7 +18580,7 @@ function ag({
18594
18580
  )
18595
18581
  ] });
18596
18582
  }
18597
- function ng({
18583
+ function ag({
18598
18584
  activeCardId: t,
18599
18585
  sourceFields: s,
18600
18586
  getFieldsForContainer: n,
@@ -18852,7 +18838,7 @@ function ng({
18852
18838
  handleDragEnd: v
18853
18839
  };
18854
18840
  }
18855
- function sg({
18841
+ function ng({
18856
18842
  activeView: t,
18857
18843
  onViewChange: s,
18858
18844
  splitViewEnabled: n
@@ -18894,7 +18880,7 @@ function sg({
18894
18880
  }
18895
18881
  ) });
18896
18882
  }
18897
- const rg = [
18883
+ const sg = [
18898
18884
  { value: "10", label: "Top 10" },
18899
18885
  { value: "20", label: "Top 20" },
18900
18886
  { value: "50", label: "Top 50" },
@@ -18904,7 +18890,7 @@ const rg = [
18904
18890
  { value: "1000", label: "Top 1000" }
18905
18891
  // { value: 'custom', label: 'Custom' },
18906
18892
  ];
18907
- function lg() {
18893
+ function rg() {
18908
18894
  var i, u;
18909
18895
  const t = F((f) => f.card), { updateRowLimit: s } = xe(), [n, r] = G(!1), [c, o] = G(""), l = (f) => {
18910
18896
  if (f === "custom") {
@@ -18933,12 +18919,12 @@ function lg() {
18933
18919
  onValueChange: l,
18934
18920
  children: [
18935
18921
  /* @__PURE__ */ e(ae, { className: "h-8 w-24 border-none px-1 [&>svg]:hidden", children: /* @__PURE__ */ e(ne, { placeholder: "Select limit" }) }),
18936
- /* @__PURE__ */ e(se, { children: rg.map((f) => /* @__PURE__ */ e(j, { value: f.value, children: f.label }, f.value)) })
18922
+ /* @__PURE__ */ e(se, { children: sg.map((f) => /* @__PURE__ */ e(j, { value: f.value, children: f.label }, f.value)) })
18937
18923
  ]
18938
18924
  }
18939
18925
  ) });
18940
18926
  }
18941
- function ig({
18927
+ function lg({
18942
18928
  card: t,
18943
18929
  queryData: s,
18944
18930
  isLoading: n,
@@ -19041,11 +19027,11 @@ function ig({
19041
19027
  )
19042
19028
  ] });
19043
19029
  }
19044
- const og = "semaphor-split-view-enabled";
19045
- function cg() {
19046
- return to(og, !0);
19030
+ const ig = "semaphor-split-view-enabled";
19031
+ function og() {
19032
+ return to(ig, !0);
19047
19033
  }
19048
- function dg({
19034
+ function cg({
19049
19035
  // selectedChart,
19050
19036
  activeView: t,
19051
19037
  onViewChange: s,
@@ -19065,7 +19051,7 @@ function dg({
19065
19051
  (ue) => ue.actions.removeCardInlineFilterValue
19066
19052
  ), i = Me((ue) => ue.filterValues), u = Me((ue) => ue.selectedSheetId), { updateCardConfig: f, setCard: h, updateCardInFrame: p, setShowAIDialog: m } = xe(), x = F((ue) => ue.showAIDialog), y = F((ue) => ue.isDevMode), v = Me((ue) => ue.isVisualEditing), [C, k] = G(!1), [B, w] = G(!1), [O, S] = G(!1), [D, I] = G(
19067
19053
  null
19068
- ), { config: A } = pr(nr).tokenProps, b = (A == null ? void 0 : A.showInfoTab) !== !1, L = (A == null ? void 0 : A.showQueryDebugTools) !== !1, [N, M] = cg();
19054
+ ), { config: A } = pr(nr).tokenProps, b = (A == null ? void 0 : A.showInfoTab) !== !1, L = (A == null ? void 0 : A.showQueryDebugTools) !== !1, [N, M] = og();
19069
19055
  F(
19070
19056
  (ue) => {
19071
19057
  var ie;
@@ -19093,7 +19079,7 @@ function dg({
19093
19079
  const ue = !N;
19094
19080
  ue && t === "table" && s("chart"), M(ue);
19095
19081
  }, Fe = (ue, ie) => {
19096
- const _e = {
19082
+ const ze = {
19097
19083
  ...r,
19098
19084
  paginationConfig: {
19099
19085
  page: ue + 1,
@@ -19101,7 +19087,7 @@ function dg({
19101
19087
  pageSize: ie
19102
19088
  }
19103
19089
  };
19104
- h(_e), p(_e);
19090
+ h(ze), p(ze);
19105
19091
  }, me = (ue) => {
19106
19092
  if (!o.config) return;
19107
19093
  const ie = lr(
@@ -19129,7 +19115,7 @@ function dg({
19129
19115
  /* @__PURE__ */ a("div", { className: "flex items-center justify-between gap-2", children: [
19130
19116
  t === "chart" && x && !g && /* @__PURE__ */ e("div", { className: "w-[200px]", children: /* @__PURE__ */ e(br, { variant: y ? "secondary" : "ghost" }) }),
19131
19117
  /* @__PURE__ */ e(
19132
- sg,
19118
+ ng,
19133
19119
  {
19134
19120
  activeView: t,
19135
19121
  onViewChange: s,
@@ -19158,12 +19144,12 @@ function dg({
19158
19144
  variant: "compact"
19159
19145
  }
19160
19146
  ),
19161
- /* @__PURE__ */ e("div", { className: "ml-2", children: /* @__PURE__ */ e(lg, {}) }),
19147
+ /* @__PURE__ */ e("div", { className: "ml-2", children: /* @__PURE__ */ e(rg, {}) }),
19162
19148
  x && /* @__PURE__ */ e(fr, {})
19163
19149
  ] }),
19164
19150
  /* @__PURE__ */ a("div", { className: W("flex grow items-center justify-end gap-2"), children: [
19165
19151
  /* @__PURE__ */ e(
19166
- pt,
19152
+ xt,
19167
19153
  {
19168
19154
  tooltip: "Refresh",
19169
19155
  disabled: _ || P,
@@ -19187,19 +19173,9 @@ function dg({
19187
19173
  showDisplayOptions: !1
19188
19174
  }
19189
19175
  ),
19190
- !x && /* @__PURE__ */ e(
19191
- pt,
19192
- {
19193
- onClick: () => m(!x),
19194
- tooltip: "AI",
19195
- className: "h-8",
19196
- "aria-label": "AI",
19197
- children: /* @__PURE__ */ e(Cm, { className: "size-4" })
19198
- }
19199
- ),
19200
19176
  t === "chart" && /* @__PURE__ */ a(Ya, { modal: !1, children: [
19201
19177
  /* @__PURE__ */ e(Wa, { asChild: !0, children: /* @__PURE__ */ e(
19202
- pt,
19178
+ xt,
19203
19179
  {
19204
19180
  tooltip: "More Options",
19205
19181
  className: "h-8",
@@ -19211,7 +19187,7 @@ function dg({
19211
19187
  /* @__PURE__ */ e(as, { children: "More Options" }),
19212
19188
  /* @__PURE__ */ e(Lt, {}),
19213
19189
  /* @__PURE__ */ a(dt, { onClick: Oe, children: [
19214
- N ? /* @__PURE__ */ e(km, { className: "mr-2 h-4 w-4" }) : /* @__PURE__ */ e(_m, { className: "mr-2 h-4 w-4" }),
19190
+ N ? /* @__PURE__ */ e(Tm, { className: "mr-2 h-4 w-4" }) : /* @__PURE__ */ e(zm, { className: "mr-2 h-4 w-4" }),
19215
19191
  N ? "Hide Results Table" : "Show Results Table"
19216
19192
  ] }),
19217
19193
  /* @__PURE__ */ e(Lt, {}),
@@ -19254,7 +19230,7 @@ function dg({
19254
19230
  ].includes(r.type)
19255
19231
  }),
19256
19232
  children: /* @__PURE__ */ e(
19257
- ig,
19233
+ lg,
19258
19234
  {
19259
19235
  card: r,
19260
19236
  queryData: E,
@@ -19351,7 +19327,7 @@ function dg({
19351
19327
  }
19352
19328
  );
19353
19329
  }
19354
- function ug({ activeField: t }) {
19330
+ function dg({ activeField: t }) {
19355
19331
  const [s, n] = G(!0);
19356
19332
  return Ce(() => {
19357
19333
  t && n(!0);
@@ -19367,7 +19343,7 @@ function ug({ activeField: t }) {
19367
19343
  }
19368
19344
  ) : null;
19369
19345
  }
19370
- const mg = () => {
19346
+ const ug = () => {
19371
19347
  const t = console.error;
19372
19348
  console.error = (...r) => {
19373
19349
  r.length > 0 && typeof r[0] == "string" && r[0].includes(
@@ -19394,7 +19370,7 @@ const mg = () => {
19394
19370
  );
19395
19371
  };
19396
19372
  };
19397
- function hg({ column: t, isSelected: s, onSelect: n, availableFields: r, width: c, onWidthChange: o }) {
19373
+ function mg({ column: t, isSelected: s, onSelect: n, availableFields: r, width: c, onWidthChange: o }) {
19398
19374
  var P, V, q;
19399
19375
  const l = F(($) => $.card), { updateCardConfig: d, removeGroupByColumn: i, removeMetricColumn: u, updateFilters: f } = xe(), [h, p] = G(!1), [m, x] = G(!1), y = Ie(null), v = ke(($) => {
19400
19376
  $.preventDefault(), $.stopPropagation(), x(!0), y.current = {
@@ -19423,7 +19399,7 @@ function hg({ column: t, isSelected: s, onSelect: n, availableFields: r, width:
19423
19399
  } = ns({ id: t.id }), b = {
19424
19400
  transform: ss.Transform.toString(D),
19425
19401
  transition: I
19426
- }, L = Ze(t.dataType), N = pg(L), M = () => {
19402
+ }, L = Ze(t.dataType), N = hg(L), M = () => {
19427
19403
  var le;
19428
19404
  const $ = ((le = l == null ? void 0 : l.config) == null ? void 0 : le.sortByColumns) || [], Y = $.findIndex((Q) => Q.name === t.name);
19429
19405
  if (Y !== -1) {
@@ -19626,7 +19602,7 @@ function hg({ column: t, isSelected: s, onSelect: n, availableFields: r, width:
19626
19602
  }
19627
19603
  );
19628
19604
  }
19629
- function pg(t) {
19605
+ function hg(t) {
19630
19606
  switch (t) {
19631
19607
  case "number":
19632
19608
  return is;
@@ -19637,7 +19613,7 @@ function pg(t) {
19637
19613
  return rs;
19638
19614
  }
19639
19615
  }
19640
- function fg({
19616
+ function pg({
19641
19617
  selectedColumn: t,
19642
19618
  onColumnSelect: s,
19643
19619
  isLoading: n = !1,
@@ -19748,7 +19724,7 @@ function fg({
19748
19724
  items: m.map((M) => M.id),
19749
19725
  strategy: Ol,
19750
19726
  children: m.map((M) => /* @__PURE__ */ e(
19751
- hg,
19727
+ mg,
19752
19728
  {
19753
19729
  column: M,
19754
19730
  isSelected: (t == null ? void 0 : t.id) === M.id,
@@ -19835,7 +19811,7 @@ function fg({
19835
19811
  "border-r border-border px-3 py-2 text-sm",
19836
19812
  (t == null ? void 0 : t.id) === g.id && "bg-primary/5"
19837
19813
  ),
19838
- children: /* @__PURE__ */ e("span", { className: "block truncate", children: gg(E, g) })
19814
+ children: /* @__PURE__ */ e("span", { className: "block truncate", children: fg(E, g) })
19839
19815
  },
19840
19816
  `${R}-${g.id}`
19841
19817
  );
@@ -19865,7 +19841,7 @@ function fg({
19865
19841
  ] })
19866
19842
  ] });
19867
19843
  }
19868
- function gg(t, s) {
19844
+ function fg(t, s) {
19869
19845
  if (t == null)
19870
19846
  return "—";
19871
19847
  if (typeof t == "number")
@@ -19884,7 +19860,7 @@ function gg(t, s) {
19884
19860
  }
19885
19861
  return String(t);
19886
19862
  }
19887
- function xg({
19863
+ function gg({
19888
19864
  entityGroups: t,
19889
19865
  isLoading: s = !1
19890
19866
  }) {
@@ -19949,7 +19925,7 @@ function xg({
19949
19925
  className: "h-7 w-7 p-0 text-muted-foreground hover:text-foreground",
19950
19926
  onClick: () => d(!1),
19951
19927
  title: "Close panel",
19952
- children: /* @__PURE__ */ e(Fm, { className: "h-4 w-4" })
19928
+ children: /* @__PURE__ */ e(Mm, { className: "h-4 w-4" })
19953
19929
  }
19954
19930
  )
19955
19931
  ] }),
@@ -20096,11 +20072,11 @@ function xg({
20096
20072
  className: "h-8 w-8 p-0",
20097
20073
  onClick: () => d(!0),
20098
20074
  title: "Open panel",
20099
- children: /* @__PURE__ */ e(Rm, { className: "h-4 w-4" })
20075
+ children: /* @__PURE__ */ e(Fm, { className: "h-4 w-4" })
20100
20076
  }
20101
20077
  ) });
20102
20078
  }
20103
- const bg = [
20079
+ const xg = [
20104
20080
  { name: "SUM", description: "Sum of values", syntax: "SUM([column])" },
20105
20081
  { name: "AVG", description: "Average of values", syntax: "AVG([column])" },
20106
20082
  { name: "COUNT", description: "Count of rows", syntax: "COUNT([column])" },
@@ -20117,7 +20093,7 @@ const bg = [
20117
20093
  { name: "DATEPART", description: "Extract date part", syntax: "DATEPART(year, [date])" },
20118
20094
  { name: "DATEDIFF", description: "Difference between dates", syntax: "DATEDIFF(day, [date1], [date2])" }
20119
20095
  ];
20120
- function vg({
20096
+ function bg({
20121
20097
  value: t,
20122
20098
  onChange: s,
20123
20099
  onSubmit: n,
@@ -20174,14 +20150,14 @@ function vg({
20174
20150
  size: "sm",
20175
20151
  className: "h-7 w-7 p-0 text-muted-foreground hover:text-foreground",
20176
20152
  title: "Insert function",
20177
- children: /* @__PURE__ */ e(zm, { className: "h-4 w-4" })
20153
+ children: /* @__PURE__ */ e(Bm, { className: "h-4 w-4" })
20178
20154
  }
20179
20155
  ) }),
20180
20156
  /* @__PURE__ */ e(kt, { className: "w-[300px] p-0", align: "start", children: /* @__PURE__ */ a(ja, { children: [
20181
20157
  /* @__PURE__ */ e(Ka, { placeholder: "Search functions..." }),
20182
20158
  /* @__PURE__ */ a(Ga, { children: [
20183
20159
  /* @__PURE__ */ e(Ua, { children: "No functions found." }),
20184
- /* @__PURE__ */ e(Ha, { heading: "Functions", children: bg.map((x) => /* @__PURE__ */ e(
20160
+ /* @__PURE__ */ e(Ha, { heading: "Functions", children: xg.map((x) => /* @__PURE__ */ e(
20185
20161
  Qa,
20186
20162
  {
20187
20163
  value: x.name,
@@ -20273,7 +20249,7 @@ function vg({
20273
20249
  ] })
20274
20250
  ] });
20275
20251
  }
20276
- function yg({ className: t }) {
20252
+ function vg({ className: t }) {
20277
20253
  var m, x, y, v;
20278
20254
  const s = F((C) => C.card), [n, r] = G(null), [c, o] = G(""), {
20279
20255
  columns: l = [],
@@ -20290,7 +20266,7 @@ function yg({ className: t }) {
20290
20266
  };
20291
20267
  return /* @__PURE__ */ a("div", { className: W("flex h-full w-full flex-col", t), children: [
20292
20268
  /* @__PURE__ */ e(
20293
- vg,
20269
+ bg,
20294
20270
  {
20295
20271
  value: c,
20296
20272
  onChange: o,
@@ -20302,7 +20278,7 @@ function yg({ className: t }) {
20302
20278
  ),
20303
20279
  /* @__PURE__ */ a("div", { className: "flex flex-1 overflow-hidden", children: [
20304
20280
  /* @__PURE__ */ e("div", { className: "flex-1 overflow-auto", children: /* @__PURE__ */ e(
20305
- fg,
20281
+ pg,
20306
20282
  {
20307
20283
  selectedColumn: n,
20308
20284
  onColumnSelect: f,
@@ -20312,7 +20288,7 @@ function yg({ className: t }) {
20312
20288
  }
20313
20289
  ) }),
20314
20290
  /* @__PURE__ */ e(
20315
- xg,
20291
+ gg,
20316
20292
  {
20317
20293
  entityGroups: d,
20318
20294
  isLoading: i
@@ -20321,12 +20297,12 @@ function yg({ className: t }) {
20321
20297
  ] })
20322
20298
  ] });
20323
20299
  }
20324
- function Ng() {
20300
+ function yg() {
20325
20301
  var T, _;
20326
20302
  const [t, s] = G(
20327
20303
  "chart"
20328
20304
  ), [n, r] = G(!1), [c, o] = G(!0), l = F((P) => P.showAIDialog), d = Me((P) => P.isVisualEditing), { setCardType: i } = xe(), u = F((P) => P.card.type);
20329
- Ce(() => mg(), []);
20305
+ Ce(() => ug(), []);
20330
20306
  const f = (P) => {
20331
20307
  i(P);
20332
20308
  }, h = F((P) => P.frame), p = F((P) => P.card);
@@ -20346,7 +20322,7 @@ function Ng() {
20346
20322
  ), S = p, {
20347
20323
  getFieldsForContainer: D,
20348
20324
  setFieldsForContainer: I
20349
- } = qi(S), { activeField: A, handleDragStart: b, handleDragEnd: L } = ng({
20325
+ } = qi(S), { activeField: A, handleDragStart: b, handleDragEnd: L } = ag({
20350
20326
  activeCardId: h.activeCardId,
20351
20327
  sourceFields: B,
20352
20328
  getFieldsForContainer: D,
@@ -20384,9 +20360,9 @@ function Ng() {
20384
20360
  onToggleVisibility: () => o(!c)
20385
20361
  }
20386
20362
  ),
20387
- /* @__PURE__ */ e("div", { className: "flex flex-1 transition-all duration-300 ease-in-out", children: u === "tableBuilder" ? /* @__PURE__ */ e(yg, { className: "flex-1" }) : /* @__PURE__ */ a(Ne, { children: [
20363
+ /* @__PURE__ */ e("div", { className: "flex flex-1 transition-all duration-300 ease-in-out", children: u === "tableBuilder" ? /* @__PURE__ */ e(vg, { className: "flex-1" }) : /* @__PURE__ */ a(Ne, { children: [
20388
20364
  !l && /* @__PURE__ */ e(
20389
- zf,
20365
+ Bf,
20390
20366
  {
20391
20367
  selectedChart: u,
20392
20368
  onChartChange: f,
@@ -20399,7 +20375,7 @@ function Ng() {
20399
20375
  }
20400
20376
  ),
20401
20377
  /* @__PURE__ */ e(
20402
- dg,
20378
+ cg,
20403
20379
  {
20404
20380
  selectedChart: u,
20405
20381
  activeView: t,
@@ -20429,7 +20405,7 @@ function Ng() {
20429
20405
  ) })
20430
20406
  ] }),
20431
20407
  S && /* @__PURE__ */ e(
20432
- ag,
20408
+ tg,
20433
20409
  {
20434
20410
  cardId: S.id,
20435
20411
  filters: ((_ = S.config) == null ? void 0 : _.filters) || null,
@@ -20440,12 +20416,12 @@ function Ng() {
20440
20416
  onOpenChange: r
20441
20417
  }
20442
20418
  ),
20443
- /* @__PURE__ */ e(Hi, { dropAnimation: null, children: /* @__PURE__ */ e(ug, { activeField: A || null }) })
20419
+ /* @__PURE__ */ e(Hi, { dropAnimation: null, children: /* @__PURE__ */ e(dg, { activeField: A || null }) })
20444
20420
  ]
20445
20421
  }
20446
20422
  );
20447
20423
  }
20448
- function Cg({ authToken: t, onSave: s, onClose: n }) {
20424
+ function Ng({ authToken: t, onSave: s, onClose: n }) {
20449
20425
  const r = Ie(null), c = F((S) => S.showAIDialog), o = F((S) => S.isDevMode), l = Ds((S) => S.setFullscreen), d = Ds((S) => S.setPanelOpen), i = Ds((S) => S.setContainer), u = mm("editor"), f = hm(), h = pm("editor"), p = f === "editor", m = ke(
20450
20426
  (S) => {
20451
20427
  i("editor", S);
@@ -20485,7 +20461,7 @@ function Cg({ authToken: t, onSave: s, onClose: n }) {
20485
20461
  ),
20486
20462
  direction: "horizontal",
20487
20463
  children: [
20488
- /* @__PURE__ */ e(ct, { className: "min-w-[510px] rounded-none", children: /* @__PURE__ */ e(Nf, {}) }),
20464
+ /* @__PURE__ */ e(ct, { className: "min-w-[510px] rounded-none", children: /* @__PURE__ */ e(yf, {}) }),
20489
20465
  /* @__PURE__ */ e(Qt, { disabled: !c }),
20490
20466
  /* @__PURE__ */ e(
20491
20467
  ct,
@@ -20533,7 +20509,7 @@ function Cg({ authToken: t, onSave: s, onClose: n }) {
20533
20509
  ),
20534
20510
  direction: "horizontal",
20535
20511
  children: [
20536
- /* @__PURE__ */ e(ct, { className: "min-w-[510px] grow rounded-none", children: /* @__PURE__ */ e(Ng, {}) }),
20512
+ /* @__PURE__ */ e(ct, { className: "min-w-[510px] grow rounded-none", children: /* @__PURE__ */ e(yg, {}) }),
20537
20513
  /* @__PURE__ */ e(Qt, { disabled: !c }),
20538
20514
  /* @__PURE__ */ e(
20539
20515
  ct,
@@ -20577,7 +20553,7 @@ function Cg({ authToken: t, onSave: s, onClose: n }) {
20577
20553
  }
20578
20554
  ) : O() });
20579
20555
  }
20580
- function Ag() {
20556
+ function Dg() {
20581
20557
  Me((i) => i.selectedCardId);
20582
20558
  const t = Me((i) => i.selectedSheetId), s = Me((i) => i.dashboard), { setIsVisualEditing: n, setSelectedSheetId: r } = Me(
20583
20559
  (i) => i.actions
@@ -20607,10 +20583,10 @@ function Ag() {
20607
20583
  className: W("flex-1 grow basis-0 overflow-auto", {
20608
20584
  "max-h-0 overflow-hidden": !c
20609
20585
  }),
20610
- children: /* @__PURE__ */ e(Cg, { onSave: l, onClose: d })
20586
+ children: /* @__PURE__ */ e(Ng, { onSave: l, onClose: d })
20611
20587
  }
20612
20588
  );
20613
20589
  }
20614
20590
  export {
20615
- Ag as default
20591
+ Dg as default
20616
20592
  };