react-semaphor 0.1.579 → 0.1.580
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assistant-context/index.js +1 -1
- package/dist/assistant-protocol/index.js +52 -50
- package/dist/briefings/index.js +1 -1
- package/dist/chunks/add-to-dashboard-DhP8wVtM.js +291 -0
- package/dist/chunks/{assistant-chat-DBuKmREJ.js → assistant-chat-CUwGURJj.js} +2261 -2184
- package/dist/chunks/{bookmark-impact-MH4Dr-Ya.js → bookmark-impact-BNyR-yDX.js} +1 -1
- package/dist/chunks/{card-filter-builder-B9vtXVIZ.js → card-filter-builder-k9yqDSw8.js} +168 -180
- package/dist/chunks/{comparison-window-caption-PtcDWvkN.js → comparison-window-caption-DdLqMgiG.js} +180 -183
- package/dist/chunks/{dashboard-C4fyqxvV.js → dashboard-DvcAk8uJ.js} +1 -1
- package/dist/chunks/{dashboard-briefing-launcher-A9CLFv0s.js → dashboard-briefing-launcher-DBgS97ZH.js} +154 -154
- package/dist/chunks/{dashboard-controls-oKDW-835.js → dashboard-controls-BiZ1rlNC.js} +7 -7
- package/dist/chunks/{dashboard-json-Bej2NBkS.js → dashboard-json-B25xzYcJ.js} +1 -1
- package/dist/chunks/{dates-BhL-mimk.js → dates-3Pah03_l.js} +4 -4
- package/dist/chunks/{edit-dashboard-visual-BFsCY2GP.js → edit-dashboard-visual-DYuO3mEU.js} +8 -9
- package/dist/chunks/{filter-reach-copy-Xus3MfSo.js → filter-reach-copy-CzLt96tq.js} +124 -124
- package/dist/chunks/{index-CwlaI-UP.js → index-BMZq6JT6.js} +1 -1
- package/dist/chunks/{report-preferences-dialog-CcekIvkV.js → report-preferences-dialog-DpAetrdY.js} +7 -7
- package/dist/chunks/{resolve-dashboard-input-context-DoZHMivF.js → resolve-dashboard-input-context-CNxtkCzj.js} +6265 -6190
- package/dist/chunks/{saved-dashboard-context-LiDPCJ3r.js → saved-dashboard-context-Bnt0H7mi.js} +2 -2
- package/dist/chunks/{semaphor-ready-indicator-cAOfbBuc.js → semaphor-ready-indicator-Dwmvmf0S.js} +15009 -14989
- package/dist/chunks/{shelf-drop-preview-context-CwoYR7v1.js → shelf-drop-preview-context-CiveteBS.js} +2 -2
- package/dist/chunks/{stored-dashboard-CjnPEWO-.js → stored-dashboard-D3gu-D7A.js} +66 -66
- package/dist/chunks/{table-export-sheet-CP8zSOhj.js → table-export-sheet-BNGSJA2N.js} +1 -1
- package/dist/chunks/{variable-draft-T4EOBvcu.js → variable-draft-C3_RL2gI.js} +2 -2
- package/dist/dashboard/index.js +1 -1
- package/dist/dashboard-authoring/index.js +356 -349
- package/dist/format-utils/index.js +4 -4
- package/dist/index.js +11 -11
- package/dist/style.css +1 -1
- package/dist/surfboard/index.js +1 -1
- package/dist/types/shared/assistant-protocol/model-change.d.ts +23 -3
- package/dist/types/shared/assistant-protocol/parts.d.ts +10 -1
- package/dist/types/shared/dashboard-authoring/changes/aggregates.d.ts +2 -0
- package/dist/types/shared/dashboard-authoring/changes/dashboard-change.d.ts +9 -58
- package/dist/types/shared/dashboard-authoring/changes/domain-change.d.ts +1738 -0
- package/dist/types/shared/dashboard-authoring/index.d.ts +1 -0
- package/package.json +1 -1
- package/dist/chunks/add-to-dashboard-DQFuDA5R.js +0 -271
|
@@ -1,25 +1,25 @@
|
|
|
1
|
-
import { c as
|
|
1
|
+
import { c as nt, B as U, X as ce, x as Ne, q as mn, a8 as pn, t as at, u as rt, v as st, w as ot, a9 as Ot, F as Oe, s as le, y as xe, z as ge, A as be, D as ve, E as re, e as it, f as lt, h as dt, L as fn, d as hn } from "./style-sheet-parts-C7qGZuH1.js";
|
|
2
2
|
import { jsx as t, jsxs as l, Fragment as fe } from "react/jsx-runtime";
|
|
3
3
|
import * as _e from "react";
|
|
4
4
|
import vt, { useMemo as Q, useState as H, useRef as Ae, useCallback as ne, useEffect as de, forwardRef as xn, Fragment as gn } from "react";
|
|
5
|
-
import { b1 as ct, u as ut, af as se, c4 as _t, cB as J, cC as bn, c0 as Ie, cD as
|
|
6
|
-
import { D as
|
|
7
|
-
import {
|
|
8
|
-
import { c as
|
|
5
|
+
import { b1 as ct, u as ut, af as se, c4 as _t, cB as J, cC as bn, c0 as Ie, cD as Ge, cE as Vt, cF as vn, bW as Ve, cG as yn, ag as Rt, bD as Nn, bE as Cn, bG as wn, bw as kn, cH as Sn, h as Dn, cI as In, cJ as Tn, cK as yt, bV as Et, cL as Ln, cM as zt, cN as Mt, cO as An, cP as $n, cQ as Fn, cR as On, cS as _n, cT as Vn, cU as Rn, bx as En, cV as Nt, cW as qt, cX as zn, bA as Mn, cY as qn, cZ as jn, c_ as Gn, c$ as ye, d0 as jt, d1 as Un, d2 as Bn, d3 as Wn, d4 as Kn, d5 as Qn, d6 as Xe, d7 as he, d8 as Ze, d9 as et, da as tt, db as Hn, dc as Re, dd as Ee, de as ze, df as Me, dg as Gt, dh as Ut, di as Bt } from "./semaphor-ready-indicator-Dwmvmf0S.js";
|
|
6
|
+
import { D as Pn } from "./token-types-iKMplaBL.js";
|
|
7
|
+
import { fg as Wt, fh as Yn, fi as Jn, fj as Xn, fk as Zn, fl as ea, fm as $e, fn as Ct, fo as wt, fp as Ke, fq as Qe, fr as ta, fs as na, ft as kt, fu as aa, fv as ra, fw as Fe, fx as sa, fy as St, fz as Kt, fA as Qt, fB as Ht, fC as Pt, fD as oa, fE as ia, fF as Dt, fG as la, fH as It, fI as da, fJ as ca, fK as ua, fL as ma, fM as He, a as qe, fN as Pe, ba as pa, fO as fa, fP as ha, fQ as xa, fR as ga } from "./resolve-dashboard-input-context-CNxtkCzj.js";
|
|
8
|
+
import { c as M } from "./pickers-DkqmtnTL.js";
|
|
9
9
|
import { r as Yt } from "./validators-B8fpdinG.js";
|
|
10
10
|
import "./matrix-operation-contract-DCVinw1o.js";
|
|
11
11
|
import "./analytics-base-schemas-BaIQrEzX.js";
|
|
12
12
|
import "../value-format-preferences/index.js";
|
|
13
|
-
import { U as
|
|
13
|
+
import { U as ba } from "./upload-CiGNKJ_0.js";
|
|
14
14
|
import { a as Jt } from "./metric-comparison-n9NsIa-2.js";
|
|
15
|
-
import { S as Xt } from "./filter-reach-copy-
|
|
15
|
+
import { S as Xt } from "./filter-reach-copy-CzLt96tq.js";
|
|
16
16
|
/**
|
|
17
17
|
* @license lucide-react v0.453.0 - ISC
|
|
18
18
|
*
|
|
19
19
|
* This source code is licensed under the ISC license.
|
|
20
20
|
* See the LICENSE file in the root directory of this source tree.
|
|
21
21
|
*/
|
|
22
|
-
const
|
|
22
|
+
const va = nt("Boxes", [
|
|
23
23
|
[
|
|
24
24
|
"path",
|
|
25
25
|
{
|
|
@@ -57,7 +57,7 @@ const ba = Ge("Boxes", [
|
|
|
57
57
|
* This source code is licensed under the ISC license.
|
|
58
58
|
* See the LICENSE file in the root directory of this source tree.
|
|
59
59
|
*/
|
|
60
|
-
const Nr =
|
|
60
|
+
const Nr = nt("FilterX", [
|
|
61
61
|
["path", { d: "M13.013 3H2l8 9.46V19l4 2v-8.54l.9-1.055", key: "1fi1da" }],
|
|
62
62
|
["path", { d: "m22 3-5 5", key: "12jva0" }],
|
|
63
63
|
["path", { d: "m17 3 5 5", key: "k36vhe" }]
|
|
@@ -68,23 +68,12 @@ const Nr = Ge("FilterX", [
|
|
|
68
68
|
* This source code is licensed under the ISC license.
|
|
69
69
|
* See the LICENSE file in the root directory of this source tree.
|
|
70
70
|
*/
|
|
71
|
-
const
|
|
71
|
+
const ya = nt("Library", [
|
|
72
72
|
["path", { d: "m16 6 4 14", key: "ji33uf" }],
|
|
73
73
|
["path", { d: "M12 6v14", key: "1n7gus" }],
|
|
74
74
|
["path", { d: "M8 8v12", key: "1gg7y9" }],
|
|
75
75
|
["path", { d: "M4 4v16", key: "6qkkli" }]
|
|
76
76
|
]);
|
|
77
|
-
/**
|
|
78
|
-
* @license lucide-react v0.453.0 - ISC
|
|
79
|
-
*
|
|
80
|
-
* This source code is licensed under the ISC license.
|
|
81
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
82
|
-
*/
|
|
83
|
-
const ya = Ge("Link2", [
|
|
84
|
-
["path", { d: "M9 17H7A5 5 0 0 1 7 7h2", key: "8i5ue5" }],
|
|
85
|
-
["path", { d: "M15 7h2a5 5 0 1 1 0 10h-2", key: "1b9ql8" }],
|
|
86
|
-
["line", { x1: "8", x2: "16", y1: "12", y2: "12", key: "1jonct" }]
|
|
87
|
-
]);
|
|
88
77
|
function Na(e, n, a) {
|
|
89
78
|
switch (e) {
|
|
90
79
|
case "none":
|
|
@@ -268,7 +257,7 @@ function Da({
|
|
|
268
257
|
/* @__PURE__ */ t(
|
|
269
258
|
Ie,
|
|
270
259
|
{
|
|
271
|
-
className:
|
|
260
|
+
className: M(
|
|
272
261
|
"h-3 w-3 shrink-0 text-muted-foreground transition-transform",
|
|
273
262
|
y && "rotate-90"
|
|
274
263
|
),
|
|
@@ -303,7 +292,7 @@ function Da({
|
|
|
303
292
|
);
|
|
304
293
|
return /* @__PURE__ */ t("li", { children: /* @__PURE__ */ l("label", { className: "flex cursor-pointer items-start gap-2 rounded-[4px] px-9 py-1.5 transition-colors hover:bg-muted/40", children: [
|
|
305
294
|
/* @__PURE__ */ t(
|
|
306
|
-
|
|
295
|
+
Ge,
|
|
307
296
|
{
|
|
308
297
|
checked: P,
|
|
309
298
|
onCheckedChange: () => j(O),
|
|
@@ -398,7 +387,7 @@ function La({
|
|
|
398
387
|
/* @__PURE__ */ t(
|
|
399
388
|
Ie,
|
|
400
389
|
{
|
|
401
|
-
className:
|
|
390
|
+
className: M(
|
|
402
391
|
"h-3 w-3 shrink-0 text-muted-foreground transition-transform",
|
|
403
392
|
i && "rotate-90"
|
|
404
393
|
),
|
|
@@ -500,7 +489,7 @@ function Aa({
|
|
|
500
489
|
};
|
|
501
490
|
return /* @__PURE__ */ l("div", { className: "space-y-2 px-8 py-2", children: [
|
|
502
491
|
/* @__PURE__ */ l("div", { className: "rounded-[6px] border border-dashed border-border bg-muted/20 p-4 text-center", children: [
|
|
503
|
-
/* @__PURE__ */ t(
|
|
492
|
+
/* @__PURE__ */ t(ba, { className: "mx-auto mb-2 h-5 w-5 text-muted-foreground" }),
|
|
504
493
|
/* @__PURE__ */ t("p", { className: "text-[12px] text-muted-foreground", children: "Add CSV, JSON, or Excel files." }),
|
|
505
494
|
/* @__PURE__ */ t(
|
|
506
495
|
"input",
|
|
@@ -665,7 +654,7 @@ function Fa({
|
|
|
665
654
|
onSelectionChange: u
|
|
666
655
|
}) {
|
|
667
656
|
var i;
|
|
668
|
-
const d =
|
|
657
|
+
const d = Ue("/v1/databases", { connection_id: e.id }, [
|
|
669
658
|
"databases",
|
|
670
659
|
e.id
|
|
671
660
|
]);
|
|
@@ -710,7 +699,7 @@ function nn({
|
|
|
710
699
|
onSelectionChange: u
|
|
711
700
|
}) {
|
|
712
701
|
var i;
|
|
713
|
-
const d =
|
|
702
|
+
const d = Ue(
|
|
714
703
|
"/v1/schemas",
|
|
715
704
|
{
|
|
716
705
|
connection_id: e.id,
|
|
@@ -751,7 +740,7 @@ function pt({
|
|
|
751
740
|
selectedEntities: u,
|
|
752
741
|
onSelectionChange: d
|
|
753
742
|
}) {
|
|
754
|
-
const c =
|
|
743
|
+
const c = Ue(
|
|
755
744
|
"/v1/tables",
|
|
756
745
|
{
|
|
757
746
|
connection_id: e.id,
|
|
@@ -830,7 +819,7 @@ function pt({
|
|
|
830
819
|
);
|
|
831
820
|
return /* @__PURE__ */ t("li", { children: /* @__PURE__ */ l("label", { className: "flex cursor-pointer items-center gap-2.5 py-1.5 pl-12 pr-4 transition-colors hover:bg-muted/40", children: [
|
|
832
821
|
/* @__PURE__ */ t(
|
|
833
|
-
|
|
822
|
+
Ge,
|
|
834
823
|
{
|
|
835
824
|
checked: k,
|
|
836
825
|
onCheckedChange: () => w(h.table_name, h.table_type),
|
|
@@ -858,7 +847,7 @@ function Oa({
|
|
|
858
847
|
selectedEntities: a,
|
|
859
848
|
onSelectionChange: o
|
|
860
849
|
}) {
|
|
861
|
-
const u =
|
|
850
|
+
const u = Ue("/v1/datamodels", { connection_id: e.id }, [
|
|
862
851
|
"datamodels",
|
|
863
852
|
e.id
|
|
864
853
|
]), d = Q(() => {
|
|
@@ -909,7 +898,7 @@ function Oa({
|
|
|
909
898
|
);
|
|
910
899
|
return /* @__PURE__ */ t("li", { children: /* @__PURE__ */ l("label", { className: "flex cursor-pointer items-start gap-2.5 py-1.5 pl-12 pr-4 transition-colors hover:bg-muted/40", children: [
|
|
911
900
|
/* @__PURE__ */ t(
|
|
912
|
-
|
|
901
|
+
Ge,
|
|
913
902
|
{
|
|
914
903
|
checked: m,
|
|
915
904
|
onCheckedChange: () => c(i),
|
|
@@ -917,7 +906,7 @@ function Oa({
|
|
|
917
906
|
}
|
|
918
907
|
),
|
|
919
908
|
/* @__PURE__ */ t(
|
|
920
|
-
|
|
909
|
+
va,
|
|
921
910
|
{
|
|
922
911
|
className: "mt-[2px] h-3.5 w-3.5 shrink-0 text-muted-foreground",
|
|
923
912
|
strokeWidth: 1.75
|
|
@@ -947,7 +936,7 @@ function an({
|
|
|
947
936
|
{
|
|
948
937
|
type: "button",
|
|
949
938
|
onClick: () => d((s) => !s),
|
|
950
|
-
className:
|
|
939
|
+
className: M(
|
|
951
940
|
"flex h-6 w-full items-center gap-1.5 pr-4 text-left transition-colors hover:bg-muted/40",
|
|
952
941
|
n === 1 ? "pl-8" : "pl-10"
|
|
953
942
|
),
|
|
@@ -955,7 +944,7 @@ function an({
|
|
|
955
944
|
/* @__PURE__ */ t(
|
|
956
945
|
Ie,
|
|
957
946
|
{
|
|
958
|
-
className:
|
|
947
|
+
className: M(
|
|
959
948
|
"h-2.5 w-2.5 shrink-0 text-muted-foreground transition-transform",
|
|
960
949
|
c && "rotate-90"
|
|
961
950
|
),
|
|
@@ -969,7 +958,7 @@ function an({
|
|
|
969
958
|
o(c)
|
|
970
959
|
] });
|
|
971
960
|
}
|
|
972
|
-
function
|
|
961
|
+
function Ue(e, n, a, o = !0) {
|
|
973
962
|
const { tokenProps: u } = ct(), d = ut((i) => i.authToken), c = Q(
|
|
974
963
|
() => Object.fromEntries(
|
|
975
964
|
Object.entries(n).filter(([, i]) => i !== void 0)
|
|
@@ -1043,7 +1032,7 @@ function Ea({
|
|
|
1043
1032
|
}
|
|
1044
1033
|
);
|
|
1045
1034
|
}
|
|
1046
|
-
function
|
|
1035
|
+
function Ye(e) {
|
|
1047
1036
|
if (e != null && e.length)
|
|
1048
1037
|
return e.every((n) => n.type === "dataset") ? "semanticDomain" : e.every((n) => n.type === "url") ? "url" : e.every(
|
|
1049
1038
|
(n) => n.type === "upload" || n.type === "file"
|
|
@@ -1057,7 +1046,7 @@ function Cr({
|
|
|
1057
1046
|
onDataSourceChange: u
|
|
1058
1047
|
}) {
|
|
1059
1048
|
var Se, me;
|
|
1060
|
-
const { tokenProps: d } = ct(), c = d.config, i = d.semanticDomainAccess ||
|
|
1049
|
+
const { tokenProps: d } = ct(), c = d.config, i = d.semanticDomainAccess || Pn, [s, m] = H([]), [f, w] = H(""), [y, h] = H("all"), [N, k] = H(
|
|
1061
1050
|
void 0
|
|
1062
1051
|
), _ = Ae(!1), { updateDataSource: D } = Rt(), j = u ?? D, O = i.mode, T = (c == null ? void 0 : c.showDirectSource) !== !1, P = O === "include" || O === "exclude" || !T, X = O !== "all", p = T && !P, I = P ? "semanticDomain" : a.mode, A = !T, S = O === "include" && (((Se = i.domainIds) == null ? void 0 : Se.length) || 0) === 1 ? (me = i.domainIds) == null ? void 0 : me[0] : void 0, v = ne(
|
|
1063
1052
|
($) => {
|
|
@@ -1117,7 +1106,7 @@ function Cr({
|
|
|
1117
1106
|
return;
|
|
1118
1107
|
}
|
|
1119
1108
|
_.current || (m([...o || []]), k(
|
|
1120
|
-
|
|
1109
|
+
Ye(o)
|
|
1121
1110
|
));
|
|
1122
1111
|
}, [e, o, P]);
|
|
1123
1112
|
const q = ($) => {
|
|
@@ -1127,13 +1116,13 @@ function Cr({
|
|
|
1127
1116
|
}, C = ne(
|
|
1128
1117
|
($, ae) => {
|
|
1129
1118
|
_.current = !0, m($), k(
|
|
1130
|
-
ae ??
|
|
1119
|
+
ae ?? Ye($)
|
|
1131
1120
|
);
|
|
1132
1121
|
},
|
|
1133
1122
|
[]
|
|
1134
1123
|
), Z = () => {
|
|
1135
1124
|
var ae, r;
|
|
1136
|
-
const $ =
|
|
1125
|
+
const $ = Ye(s) ?? N ?? I;
|
|
1137
1126
|
if ($ === "semanticDomain") {
|
|
1138
1127
|
const g = en(s) || a.semanticDomainId, b = ((ae = s == null ? void 0 : s[0]) == null ? void 0 : ae.connectionId) || a.connectionId, L = ((r = s == null ? void 0 : s[0]) == null ? void 0 : r.connectionType) || a.connectionType;
|
|
1139
1128
|
j({
|
|
@@ -1166,7 +1155,7 @@ function Cr({
|
|
|
1166
1155
|
});
|
|
1167
1156
|
}
|
|
1168
1157
|
n(!1);
|
|
1169
|
-
}, { semanticDomains: V } = Zt(), { connections:
|
|
1158
|
+
}, { semanticDomains: V } = Zt(), { connections: z } = Vt(), K = Q(
|
|
1170
1159
|
() => new Map(
|
|
1171
1160
|
V.map(($) => [
|
|
1172
1161
|
$.id,
|
|
@@ -1176,7 +1165,7 @@ function Cr({
|
|
|
1176
1165
|
[V]
|
|
1177
1166
|
), G = ($) => {
|
|
1178
1167
|
h($), $ === "semantic" || $.startsWith("domain:") ? a.mode !== "semanticDomain" && v("semanticDomain") : ($ === "direct" || $.startsWith("conn:")) && a.mode === "semanticDomain" && v("database");
|
|
1179
|
-
}, ee = y.startsWith("domain:"), te = y.startsWith("conn:"),
|
|
1168
|
+
}, ee = y.startsWith("domain:"), te = y.startsWith("conn:"), Be = ee ? y.slice(7) : void 0, We = te ? y.slice(5) : void 0, oe = !p || y === "all" || y === "semantic" || ee, Te = T && !P && (y === "all" || y === "direct" || te), ue = ((o == null ? void 0 : o.length) ?? 0) > 0, Ce = s.length === 0 && !ue, we = s.length === 0 && ue ? "Clear" : "Add", ke = A ? "Select dataset" : "Add data";
|
|
1180
1169
|
return /* @__PURE__ */ t(Nn, { open: e, onOpenChange: n, children: /* @__PURE__ */ l(
|
|
1181
1170
|
Cn,
|
|
1182
1171
|
{
|
|
@@ -1236,7 +1225,7 @@ function Cr({
|
|
|
1236
1225
|
onClick: () => G("all")
|
|
1237
1226
|
}
|
|
1238
1227
|
),
|
|
1239
|
-
(V.length > 0 ||
|
|
1228
|
+
(V.length > 0 || z.length > 0) && /* @__PURE__ */ l(fe, { children: [
|
|
1240
1229
|
/* @__PURE__ */ t(
|
|
1241
1230
|
De,
|
|
1242
1231
|
{
|
|
@@ -1264,7 +1253,7 @@ function Cr({
|
|
|
1264
1253
|
},
|
|
1265
1254
|
`domain:${$.id}`
|
|
1266
1255
|
)),
|
|
1267
|
-
|
|
1256
|
+
z.map(($) => /* @__PURE__ */ t(
|
|
1268
1257
|
De,
|
|
1269
1258
|
{
|
|
1270
1259
|
label: $.name,
|
|
@@ -1281,7 +1270,7 @@ function Cr({
|
|
|
1281
1270
|
{
|
|
1282
1271
|
domainAccess: i,
|
|
1283
1272
|
search: f,
|
|
1284
|
-
scopeDomainId:
|
|
1273
|
+
scopeDomainId: Be,
|
|
1285
1274
|
selectedEntities: s,
|
|
1286
1275
|
onSelectionChange: ($) => C($, "semanticDomain")
|
|
1287
1276
|
}
|
|
@@ -1290,7 +1279,7 @@ function Cr({
|
|
|
1290
1279
|
Ta,
|
|
1291
1280
|
{
|
|
1292
1281
|
search: f,
|
|
1293
|
-
scopeConnectionId:
|
|
1282
|
+
scopeConnectionId: We,
|
|
1294
1283
|
selectedEntities: s,
|
|
1295
1284
|
onSelectionChange: ($) => C($)
|
|
1296
1285
|
}
|
|
@@ -1321,7 +1310,7 @@ function Cr({
|
|
|
1321
1310
|
type: "button",
|
|
1322
1311
|
onClick: Z,
|
|
1323
1312
|
disabled: Ce,
|
|
1324
|
-
className:
|
|
1313
|
+
className: M(
|
|
1325
1314
|
"inline-flex h-7 items-center gap-1.5 rounded-control bg-primary px-2.5 text-[12px] font-medium text-primary-foreground transition-colors hover:bg-primary/90",
|
|
1326
1315
|
Ce && "cursor-not-allowed opacity-50 hover:bg-primary"
|
|
1327
1316
|
),
|
|
@@ -1360,7 +1349,7 @@ function De({
|
|
|
1360
1349
|
type: "button",
|
|
1361
1350
|
onClick: a,
|
|
1362
1351
|
"aria-pressed": n,
|
|
1363
|
-
className:
|
|
1352
|
+
className: M(
|
|
1364
1353
|
"inline-flex h-6 shrink-0 items-center whitespace-nowrap rounded-control px-2 text-[11px] font-medium transition-colors",
|
|
1365
1354
|
n ? "bg-primary text-primary-foreground hover:bg-primary/90" : "text-muted-foreground hover:bg-muted hover:text-foreground"
|
|
1366
1355
|
),
|
|
@@ -1433,8 +1422,8 @@ function kr({
|
|
|
1433
1422
|
library: "fill-blue-50 dark:fill-blue-950"
|
|
1434
1423
|
}, h = {
|
|
1435
1424
|
local: /* @__PURE__ */ t("span", { className: "h-2 w-2 rounded-full bg-current/70" }),
|
|
1436
|
-
linked: /* @__PURE__ */ t(
|
|
1437
|
-
library: /* @__PURE__ */ t(
|
|
1425
|
+
linked: /* @__PURE__ */ t(Tn, { className: "h-3.5 w-3.5" }),
|
|
1426
|
+
library: /* @__PURE__ */ t(ya, { className: "h-3.5 w-3.5" })
|
|
1438
1427
|
}, N = {
|
|
1439
1428
|
local: "Local",
|
|
1440
1429
|
linked: "Linked",
|
|
@@ -1445,7 +1434,7 @@ function kr({
|
|
|
1445
1434
|
In,
|
|
1446
1435
|
{
|
|
1447
1436
|
variant: "outline",
|
|
1448
|
-
className:
|
|
1437
|
+
className: M(
|
|
1449
1438
|
"cursor-help select-none transition-all",
|
|
1450
1439
|
m[s],
|
|
1451
1440
|
a
|
|
@@ -1460,7 +1449,7 @@ function kr({
|
|
|
1460
1449
|
ot,
|
|
1461
1450
|
{
|
|
1462
1451
|
side: "bottom",
|
|
1463
|
-
className:
|
|
1452
|
+
className: M("max-w-xs", w[s]),
|
|
1464
1453
|
children: [
|
|
1465
1454
|
/* @__PURE__ */ t(Ot, { className: y[s] }),
|
|
1466
1455
|
/* @__PURE__ */ t("p", { children: f[s] })
|
|
@@ -1469,7 +1458,7 @@ function kr({
|
|
|
1469
1458
|
)
|
|
1470
1459
|
] }) });
|
|
1471
1460
|
}
|
|
1472
|
-
const
|
|
1461
|
+
const za = xn(
|
|
1473
1462
|
({
|
|
1474
1463
|
side: e = "bottom",
|
|
1475
1464
|
children: n,
|
|
@@ -1491,7 +1480,7 @@ const Ma = xn(
|
|
|
1491
1480
|
onClick: u,
|
|
1492
1481
|
...s,
|
|
1493
1482
|
...c,
|
|
1494
|
-
className:
|
|
1483
|
+
className: M(`${Yn}`, a),
|
|
1495
1484
|
children: n
|
|
1496
1485
|
}
|
|
1497
1486
|
) }),
|
|
@@ -1500,7 +1489,7 @@ const Ma = xn(
|
|
|
1500
1489
|
{
|
|
1501
1490
|
side: e,
|
|
1502
1491
|
sideOffset: 10,
|
|
1503
|
-
className:
|
|
1492
|
+
className: M(
|
|
1504
1493
|
"border-foreground/20 bg-foreground text-background"
|
|
1505
1494
|
),
|
|
1506
1495
|
children: [
|
|
@@ -1511,17 +1500,17 @@ const Ma = xn(
|
|
|
1511
1500
|
)
|
|
1512
1501
|
] }) })
|
|
1513
1502
|
);
|
|
1514
|
-
|
|
1515
|
-
function
|
|
1503
|
+
za.displayName = "IconButton";
|
|
1504
|
+
function Ma(e, n) {
|
|
1516
1505
|
var s, m;
|
|
1517
|
-
const a = e.qualifiedFieldName || e.name, o = e.qualifiedFieldName ? e.qualifiedFieldName.split(".").slice(0, -1).join(".") : e.qualifiedEntityName || e.entityName, u = n.connectionId || ((s = n.dataSource) == null ? void 0 : s.connectionId) || "", d =
|
|
1506
|
+
const a = e.qualifiedFieldName || e.name, o = e.qualifiedFieldName ? e.qualifiedFieldName.split(".").slice(0, -1).join(".") : e.qualifiedEntityName || e.entityName, u = n.connectionId || ((s = n.dataSource) == null ? void 0 : s.connectionId) || "", d = Jn(e), c = Xn(
|
|
1518
1507
|
n.dataSource,
|
|
1519
1508
|
{
|
|
1520
1509
|
connectionId: u,
|
|
1521
1510
|
connectionType: (m = n.dataSource) == null ? void 0 : m.connectionType
|
|
1522
1511
|
},
|
|
1523
1512
|
e
|
|
1524
|
-
), i =
|
|
1513
|
+
), i = Zn(n.dataSource, c, e) || "";
|
|
1525
1514
|
return {
|
|
1526
1515
|
column: a,
|
|
1527
1516
|
title: Xt(e),
|
|
@@ -1561,7 +1550,7 @@ function qa(e) {
|
|
|
1561
1550
|
/* @__PURE__ */ t(
|
|
1562
1551
|
"span",
|
|
1563
1552
|
{
|
|
1564
|
-
className:
|
|
1553
|
+
className: M(
|
|
1565
1554
|
"flex h-5 w-5 items-center justify-center rounded-full border text-[10px] font-medium tabular-nums",
|
|
1566
1555
|
c ? "border-foreground bg-foreground text-background" : i ? "border-foreground/30 bg-foreground/10 text-foreground" : "border-border/60 bg-background text-muted-foreground"
|
|
1567
1556
|
),
|
|
@@ -1571,7 +1560,7 @@ function qa(e) {
|
|
|
1571
1560
|
/* @__PURE__ */ t(
|
|
1572
1561
|
"span",
|
|
1573
1562
|
{
|
|
1574
|
-
className:
|
|
1563
|
+
className: M(
|
|
1575
1564
|
"text-[12px]",
|
|
1576
1565
|
c ? "font-medium text-foreground" : "text-muted-foreground"
|
|
1577
1566
|
),
|
|
@@ -1600,7 +1589,7 @@ function je(e) {
|
|
|
1600
1589
|
function ja(e) {
|
|
1601
1590
|
const { control: n, scope: a, detail: o } = e;
|
|
1602
1591
|
return /* @__PURE__ */ l("div", { className: "flex items-start gap-2.5 rounded-control border border-border/60 bg-muted/30 px-3 py-2.5", children: [
|
|
1603
|
-
/* @__PURE__ */ t(
|
|
1592
|
+
/* @__PURE__ */ t(Vn, { className: "mt-0.5 h-3.5 w-3.5 shrink-0 text-foreground" }),
|
|
1604
1593
|
/* @__PURE__ */ l("div", { className: "min-w-0 space-y-0.5", children: [
|
|
1605
1594
|
/* @__PURE__ */ t("div", { className: "text-[13px] font-medium text-foreground", children: n.label }),
|
|
1606
1595
|
/* @__PURE__ */ l("div", { className: "text-[12px] text-muted-foreground", children: [
|
|
@@ -1634,7 +1623,7 @@ function Tt(e) {
|
|
|
1634
1623
|
return /* @__PURE__ */ l("div", { className: "space-y-3", children: [
|
|
1635
1624
|
/* @__PURE__ */ t(rn, { control: n, onChange: s }),
|
|
1636
1625
|
/* @__PURE__ */ t(
|
|
1637
|
-
|
|
1626
|
+
zt,
|
|
1638
1627
|
{
|
|
1639
1628
|
control: n,
|
|
1640
1629
|
availableFieldChoices: o,
|
|
@@ -1646,7 +1635,7 @@ function Tt(e) {
|
|
|
1646
1635
|
}
|
|
1647
1636
|
),
|
|
1648
1637
|
/* @__PURE__ */ t(
|
|
1649
|
-
|
|
1638
|
+
Mt,
|
|
1650
1639
|
{
|
|
1651
1640
|
control: n,
|
|
1652
1641
|
value: a,
|
|
@@ -1783,19 +1772,19 @@ function Ua(e) {
|
|
|
1783
1772
|
e.reservedIds
|
|
1784
1773
|
), a = e.type === n.type ? {
|
|
1785
1774
|
...n,
|
|
1786
|
-
label:
|
|
1775
|
+
label: He[e.type]
|
|
1787
1776
|
} : {
|
|
1788
1777
|
...Pt({
|
|
1789
1778
|
controls: [
|
|
1790
1779
|
{
|
|
1791
1780
|
...n,
|
|
1792
|
-
label:
|
|
1781
|
+
label: He[e.type]
|
|
1793
1782
|
}
|
|
1794
1783
|
],
|
|
1795
1784
|
controlId: n.id,
|
|
1796
1785
|
nextType: e.type
|
|
1797
1786
|
}).controls[0],
|
|
1798
|
-
label:
|
|
1787
|
+
label: He[e.type]
|
|
1799
1788
|
};
|
|
1800
1789
|
return {
|
|
1801
1790
|
step: 2,
|
|
@@ -1824,7 +1813,7 @@ function Sr({
|
|
|
1824
1813
|
const _ = Q(
|
|
1825
1814
|
() => new Set(a || []),
|
|
1826
1815
|
[a]
|
|
1827
|
-
), D =
|
|
1816
|
+
), D = oa(e), j = ea(e), [O, T] = H(
|
|
1828
1817
|
null
|
|
1829
1818
|
), [P, X] = H(
|
|
1830
1819
|
null
|
|
@@ -1872,7 +1861,7 @@ function Sr({
|
|
|
1872
1861
|
fields: s || [],
|
|
1873
1862
|
metrics: m || []
|
|
1874
1863
|
};
|
|
1875
|
-
const r = p.selectedCardIds || [], g =
|
|
1864
|
+
const r = p.selectedCardIds || [], g = Ke({
|
|
1876
1865
|
controlType: p.control.type,
|
|
1877
1866
|
participants: f || [],
|
|
1878
1867
|
selectedCardIds: r
|
|
@@ -1903,7 +1892,7 @@ function Sr({
|
|
|
1903
1892
|
control: $e(e, n, Array.from(_))
|
|
1904
1893
|
}), X(null), T(null));
|
|
1905
1894
|
}, [n, c, _, e]);
|
|
1906
|
-
const
|
|
1895
|
+
const z = (r) => {
|
|
1907
1896
|
if (!C(r.type))
|
|
1908
1897
|
return {
|
|
1909
1898
|
fields: s || [],
|
|
@@ -1915,7 +1904,7 @@ function Sr({
|
|
|
1915
1904
|
fields: s || [],
|
|
1916
1905
|
metrics: m || []
|
|
1917
1906
|
};
|
|
1918
|
-
const b =
|
|
1907
|
+
const b = Ke({
|
|
1919
1908
|
controlType: r.type,
|
|
1920
1909
|
participants: f || [],
|
|
1921
1910
|
selectedCardIds: g
|
|
@@ -1936,11 +1925,11 @@ function Sr({
|
|
|
1936
1925
|
nextControl: r.control,
|
|
1937
1926
|
cardBindingsById: void 0
|
|
1938
1927
|
};
|
|
1939
|
-
const g = (w == null ? void 0 : w[r.control.id]) || [], b =
|
|
1928
|
+
const g = (w == null ? void 0 : w[r.control.id]) || [], b = Ke({
|
|
1940
1929
|
controlType: r.control.type,
|
|
1941
1930
|
participants: f || [],
|
|
1942
1931
|
selectedCardIds: r.nextSelectedCardIds
|
|
1943
|
-
}), L =
|
|
1932
|
+
}), L = ua({
|
|
1944
1933
|
control: r.control,
|
|
1945
1934
|
choices: b.choices
|
|
1946
1935
|
}), R = Object.fromEntries(
|
|
@@ -1960,10 +1949,10 @@ function Sr({
|
|
|
1960
1949
|
};
|
|
1961
1950
|
}, G = ne(
|
|
1962
1951
|
(r, g = o, b = { type: "update" }) => {
|
|
1963
|
-
const L = r.map((R) => (
|
|
1952
|
+
const L = r.map((R) => (Qe({
|
|
1964
1953
|
control: R,
|
|
1965
1954
|
defaultValues: g
|
|
1966
|
-
}),
|
|
1955
|
+
}), ta(
|
|
1967
1956
|
R
|
|
1968
1957
|
)));
|
|
1969
1958
|
u(L, g, b);
|
|
@@ -1978,7 +1967,7 @@ function Sr({
|
|
|
1978
1967
|
(W) => W.id === r
|
|
1979
1968
|
);
|
|
1980
1969
|
let E, F;
|
|
1981
|
-
if (R && (!b ||
|
|
1970
|
+
if (R && (!b || da({ control: b }, { control: R })) && e === "dashboard" && (R.type === "field_selector" || R.type === "metric_selector")) {
|
|
1982
1971
|
const W = (w == null ? void 0 : w[R.id]) || [], pe = K({
|
|
1983
1972
|
control: R,
|
|
1984
1973
|
nextSelectedCardIds: W
|
|
@@ -1986,7 +1975,7 @@ function Sr({
|
|
|
1986
1975
|
L = L.map(
|
|
1987
1976
|
(ie) => ie.id === r ? pe.nextControl : ie
|
|
1988
1977
|
), E = pe.cardBindingsById, F = [R.id];
|
|
1989
|
-
} else if (b && (!R || !
|
|
1978
|
+
} else if (b && (!R || !ca(R.type)) && e === "dashboard" && (b.type === "field_selector" || b.type === "metric_selector")) {
|
|
1990
1979
|
const W = (w == null ? void 0 : w[b.id]) || [];
|
|
1991
1980
|
E = Object.fromEntries(
|
|
1992
1981
|
W.map((pe) => [pe, void 0])
|
|
@@ -1997,7 +1986,7 @@ function Sr({
|
|
|
1997
1986
|
);
|
|
1998
1987
|
let Y = o;
|
|
1999
1988
|
if (b && B) {
|
|
2000
|
-
const W =
|
|
1989
|
+
const W = Qe({
|
|
2001
1990
|
control: b,
|
|
2002
1991
|
defaultValues: o
|
|
2003
1992
|
});
|
|
@@ -2019,7 +2008,7 @@ function Sr({
|
|
|
2019
2008
|
}, te = (r, g) => {
|
|
2020
2009
|
if (!g.trim())
|
|
2021
2010
|
return;
|
|
2022
|
-
const b =
|
|
2011
|
+
const b = ma(g);
|
|
2023
2012
|
if (b === r || _.has(b) || n.some(
|
|
2024
2013
|
(E) => E.id === b && E.id !== r
|
|
2025
2014
|
))
|
|
@@ -2041,7 +2030,7 @@ function Sr({
|
|
|
2041
2030
|
oldId: r,
|
|
2042
2031
|
newId: b
|
|
2043
2032
|
});
|
|
2044
|
-
},
|
|
2033
|
+
}, Be = (r) => {
|
|
2045
2034
|
const g = n.filter((L) => L.id !== r);
|
|
2046
2035
|
if (!o) {
|
|
2047
2036
|
G(g, void 0, { type: "remove", controlId: r });
|
|
@@ -2049,7 +2038,7 @@ function Sr({
|
|
|
2049
2038
|
}
|
|
2050
2039
|
const b = { ...o };
|
|
2051
2040
|
delete b[r], G(g, b, { type: "remove", controlId: r });
|
|
2052
|
-
},
|
|
2041
|
+
}, We = ne(() => {
|
|
2053
2042
|
S.current = void 0, I({
|
|
2054
2043
|
step: 1,
|
|
2055
2044
|
control: $e(e, n, Array.from(_))
|
|
@@ -2082,7 +2071,7 @@ function Sr({
|
|
|
2082
2071
|
if (!p)
|
|
2083
2072
|
return !1;
|
|
2084
2073
|
if (p.step === 2 && C(p.control.type))
|
|
2085
|
-
return (p.selectedCardIds || []).length > 0 &&
|
|
2074
|
+
return (p.selectedCardIds || []).length > 0 && na({
|
|
2086
2075
|
participants: f || [],
|
|
2087
2076
|
selectedCardIds: p.selectedCardIds || [],
|
|
2088
2077
|
control: p.control,
|
|
@@ -2091,7 +2080,7 @@ function Sr({
|
|
|
2091
2080
|
if (p.step !== 2 && p.step !== 3 || !p.control.label.trim())
|
|
2092
2081
|
return !1;
|
|
2093
2082
|
const g = p.control.source.kind === "sql_query" ? p.control : kt(p.control);
|
|
2094
|
-
if (g.source.kind === "manual" && (
|
|
2083
|
+
if (g.source.kind === "manual" && (aa(g) && g.source.options.length === 0 || g.source.options.some(
|
|
2095
2084
|
(L) => L.label.trim().length === 0 || L.value.trim().length === 0
|
|
2096
2085
|
)))
|
|
2097
2086
|
return !1;
|
|
@@ -2099,14 +2088,14 @@ function Sr({
|
|
|
2099
2088
|
const { connectionId: b, sql: L, valueColumn: R } = g.source;
|
|
2100
2089
|
return b.trim().length > 0 && L.trim().length > 0 && R.trim().length > 0;
|
|
2101
2090
|
}
|
|
2102
|
-
return
|
|
2091
|
+
return ra(
|
|
2103
2092
|
Fe(g, p.defaultValue)
|
|
2104
2093
|
);
|
|
2105
2094
|
})(), Ce = () => {
|
|
2106
2095
|
var E;
|
|
2107
2096
|
if (!p)
|
|
2108
2097
|
return;
|
|
2109
|
-
const r = kt(p.control), g =
|
|
2098
|
+
const r = kt(p.control), g = la({
|
|
2110
2099
|
label: r.label,
|
|
2111
2100
|
fallbackId: r.id,
|
|
2112
2101
|
existingControls: n,
|
|
@@ -2175,7 +2164,7 @@ function Sr({
|
|
|
2175
2164
|
}
|
|
2176
2165
|
);
|
|
2177
2166
|
X(g), I(null), k == null || k();
|
|
2178
|
-
}, [n, p, o, G, k]), gt = p ? C(p.control.type) ? ["Choose type", "Select cards", "Configure", "Finish"] : ["Choose type", "Configure", "Finish"] : [], Se = p != null && p.createdControlId ? `[[param.${p.createdControlId}]]` : p ? `[[param.${
|
|
2167
|
+
}, [n, p, o, G, k]), gt = p ? C(p.control.type) ? ["Choose type", "Select cards", "Configure", "Finish"] : ["Choose type", "Configure", "Finish"] : [], Se = p != null && p.createdControlId ? `[[param.${p.createdControlId}]]` : p ? `[[param.${sa(p.control.label) || p.control.id}]]` : "", me = St({
|
|
2179
2168
|
controls: n,
|
|
2180
2169
|
defaultValues: o
|
|
2181
2170
|
}), $ = p ? [...n, p.control] : n, ae = p ? St({
|
|
@@ -2281,7 +2270,7 @@ function Sr({
|
|
|
2281
2270
|
className: "flex items-start gap-2 rounded-control px-1.5 py-1 text-[13px] hover:bg-muted/40",
|
|
2282
2271
|
children: [
|
|
2283
2272
|
/* @__PURE__ */ t(
|
|
2284
|
-
|
|
2273
|
+
Ge,
|
|
2285
2274
|
{
|
|
2286
2275
|
checked: g,
|
|
2287
2276
|
onCheckedChange: (b) => I(
|
|
@@ -2454,7 +2443,7 @@ function Sr({
|
|
|
2454
2443
|
] }) : null,
|
|
2455
2444
|
!p && n.length === 0 ? /* @__PURE__ */ t("div", { className: "rounded-md border border-dashed p-3 text-sm text-muted-foreground", children: d }) : null,
|
|
2456
2445
|
!p && n.map((r) => {
|
|
2457
|
-
const g =
|
|
2446
|
+
const g = z(r), b = i == null ? void 0 : i[r.id], L = Qe({
|
|
2458
2447
|
control: r,
|
|
2459
2448
|
defaultValues: o
|
|
2460
2449
|
}), R = P === r.id, E = "inline-flex shrink-0 items-center rounded-[4px] border border-border/60 bg-muted/40 px-1.5 py-0.5 text-[11px] font-medium text-muted-foreground";
|
|
@@ -2495,7 +2484,7 @@ function Sr({
|
|
|
2495
2484
|
size: "xs",
|
|
2496
2485
|
variant: "ghost",
|
|
2497
2486
|
className: "h-7 w-7 shrink-0 p-0 text-muted-foreground",
|
|
2498
|
-
onClick: () =>
|
|
2487
|
+
onClick: () => Be(r.id),
|
|
2499
2488
|
"aria-label": `Remove ${r.label}`,
|
|
2500
2489
|
children: /* @__PURE__ */ t(Et, { className: "h-3.5 w-3.5" })
|
|
2501
2490
|
}
|
|
@@ -2569,7 +2558,7 @@ function Sr({
|
|
|
2569
2558
|
] }),
|
|
2570
2559
|
C(r.type) ? /* @__PURE__ */ l(fe, { children: [
|
|
2571
2560
|
/* @__PURE__ */ t(
|
|
2572
|
-
|
|
2561
|
+
Ln,
|
|
2573
2562
|
{
|
|
2574
2563
|
type: r.type,
|
|
2575
2564
|
participants: wt(
|
|
@@ -2617,7 +2606,7 @@ function Sr({
|
|
|
2617
2606
|
)
|
|
2618
2607
|
] }) : null,
|
|
2619
2608
|
/* @__PURE__ */ t(
|
|
2620
|
-
|
|
2609
|
+
zt,
|
|
2621
2610
|
{
|
|
2622
2611
|
control: r,
|
|
2623
2612
|
availableFieldChoices: g.fields,
|
|
@@ -2629,7 +2618,7 @@ function Sr({
|
|
|
2629
2618
|
}
|
|
2630
2619
|
),
|
|
2631
2620
|
r.initialValueStrategy === "saved_default" && /* @__PURE__ */ t(
|
|
2632
|
-
|
|
2621
|
+
Mt,
|
|
2633
2622
|
{
|
|
2634
2623
|
control: r,
|
|
2635
2624
|
value: L,
|
|
@@ -2651,12 +2640,12 @@ function Sr({
|
|
|
2651
2640
|
}
|
|
2652
2641
|
),
|
|
2653
2642
|
/* @__PURE__ */ l(
|
|
2654
|
-
|
|
2643
|
+
An,
|
|
2655
2644
|
{
|
|
2656
2645
|
open: O === r.id,
|
|
2657
2646
|
onOpenChange: (F) => T(F ? r.id : null),
|
|
2658
2647
|
children: [
|
|
2659
|
-
/* @__PURE__ */ t(
|
|
2648
|
+
/* @__PURE__ */ t($n, { asChild: !0, children: /* @__PURE__ */ l(
|
|
2660
2649
|
U,
|
|
2661
2650
|
{
|
|
2662
2651
|
type: "button",
|
|
@@ -2669,12 +2658,12 @@ function Sr({
|
|
|
2669
2658
|
]
|
|
2670
2659
|
}
|
|
2671
2660
|
) }),
|
|
2672
|
-
/* @__PURE__ */ l(
|
|
2661
|
+
/* @__PURE__ */ l(Fn, { className: "space-y-3 pt-2", children: [
|
|
2673
2662
|
/* @__PURE__ */ l("div", { className: "grid gap-3 md:grid-cols-2", children: [
|
|
2674
2663
|
/* @__PURE__ */ l("div", { className: "flex flex-col gap-1.5", children: [
|
|
2675
2664
|
/* @__PURE__ */ t(le, { className: "text-[10px] font-medium uppercase tracking-[0.08em] text-muted-foreground", children: "Variable name" }),
|
|
2676
2665
|
/* @__PURE__ */ t(
|
|
2677
|
-
|
|
2666
|
+
On,
|
|
2678
2667
|
{
|
|
2679
2668
|
controlId: r.id,
|
|
2680
2669
|
onCommit: (F) => te(r.id, F)
|
|
@@ -2694,7 +2683,7 @@ function Sr({
|
|
|
2694
2683
|
})),
|
|
2695
2684
|
children: [
|
|
2696
2685
|
/* @__PURE__ */ t(ge, { size: "xs", children: /* @__PURE__ */ t(be, {}) }),
|
|
2697
|
-
/* @__PURE__ */ t(ve, { children:
|
|
2686
|
+
/* @__PURE__ */ t(ve, { children: ia.map((F) => /* @__PURE__ */ t(
|
|
2698
2687
|
re,
|
|
2699
2688
|
{
|
|
2700
2689
|
value: F.value,
|
|
@@ -2708,7 +2697,7 @@ function Sr({
|
|
|
2708
2697
|
] })
|
|
2709
2698
|
] }),
|
|
2710
2699
|
/* @__PURE__ */ t(
|
|
2711
|
-
|
|
2700
|
+
_n,
|
|
2712
2701
|
{
|
|
2713
2702
|
control: r,
|
|
2714
2703
|
onChange: (F) => ee(r.id, () => F)
|
|
@@ -2730,7 +2719,7 @@ function Sr({
|
|
|
2730
2719
|
type: "button",
|
|
2731
2720
|
variant: "outline",
|
|
2732
2721
|
size: "xs",
|
|
2733
|
-
onClick:
|
|
2722
|
+
onClick: We,
|
|
2734
2723
|
children: [
|
|
2735
2724
|
/* @__PURE__ */ t(Ve, { className: "h-3.5 w-3.5" }),
|
|
2736
2725
|
"Add control"
|
|
@@ -2813,7 +2802,7 @@ function Ka({
|
|
|
2813
2802
|
u(I), a == null || a(I);
|
|
2814
2803
|
};
|
|
2815
2804
|
se((I) => I.card.dataSource);
|
|
2816
|
-
const { filterableFields: c, isLoading: i } =
|
|
2805
|
+
const { filterableFields: c, isLoading: i } = Rn(), s = n || c || [], m = {
|
|
2817
2806
|
id: "default",
|
|
2818
2807
|
qualifiedFieldName: "default",
|
|
2819
2808
|
name: "default",
|
|
@@ -2908,7 +2897,7 @@ function Ka({
|
|
|
2908
2897
|
}, k = (I, A, S) => N(I, A, (v) => ({
|
|
2909
2898
|
..."value" in S || "operator" in S || "field" in S ? sn(v) : v,
|
|
2910
2899
|
...S
|
|
2911
|
-
})), _ = (I, A, S) => N(I, A, () => S), D =
|
|
2900
|
+
})), _ = (I, A, S) => N(I, A, () => S), D = En(), j = (I, A) => {
|
|
2912
2901
|
const S = (v) => v.id === I ? {
|
|
2913
2902
|
...v,
|
|
2914
2903
|
logicalOperator: A
|
|
@@ -2956,29 +2945,29 @@ function Ka({
|
|
|
2956
2945
|
return `${x} = ${qt} /* the latest value each time the card runs */`;
|
|
2957
2946
|
const Z = Yt(v.relativeMeta);
|
|
2958
2947
|
if (Z && (q === "between" || q === "not between")) {
|
|
2959
|
-
const V = q === "between" ? "BETWEEN" : "NOT BETWEEN", { label:
|
|
2948
|
+
const V = q === "between" ? "BETWEEN" : "NOT BETWEEN", { label: z, range: K } = zn(Z, {
|
|
2960
2949
|
tz: (D == null ? void 0 : D.tz) ?? "UTC",
|
|
2961
2950
|
weekStart: (D == null ? void 0 : D.weekStart) ?? 1,
|
|
2962
2951
|
anchor: (D == null ? void 0 : D.anchor) ?? "now"
|
|
2963
2952
|
});
|
|
2964
|
-
return K ? `${x} ${V} '${K.start.toISOString()}' AND '${K.end.toISOString()}' /* ${
|
|
2953
|
+
return K ? `${x} ${V} '${K.start.toISOString()}' AND '${K.end.toISOString()}' /* ${z}: dates update each time the card runs */` : Jt(Z).dataAnchored ? `${x} ${V} ${z} /* dates count back from the latest data each time the card runs */` : `${x} ${V} ${z} /* dates follow your calendar each time the card runs */`;
|
|
2965
2954
|
}
|
|
2966
2955
|
if (v.field.dataType === "string" && !["in", "not in"].includes(v.operator))
|
|
2967
2956
|
typeof C == "string" ? C = `'${C}'` : Array.isArray(C) && (C = `'${C.join(", ")}'`);
|
|
2968
2957
|
else if (v.field.dataType === "date" || v.field.dataType === "datetime" || v.field.dataType === "timestamp")
|
|
2969
2958
|
if (v.operator === "between" && Array.isArray(C) && C.length === 2) {
|
|
2970
|
-
const V = C[0] ? `'${C[0]}'` : "NULL",
|
|
2971
|
-
return `${x} BETWEEN ${V} AND ${
|
|
2959
|
+
const V = C[0] ? `'${C[0]}'` : "NULL", z = C[1] ? `'${C[1]}'` : "NULL";
|
|
2960
|
+
return `${x} BETWEEN ${V} AND ${z}`;
|
|
2972
2961
|
} else if ((v.operator === "in" || v.operator === "not in") && Array.isArray(C)) {
|
|
2973
|
-
const V = C.map((
|
|
2962
|
+
const V = C.map((z) => z ? `'${z}'` : "NULL").join(", ");
|
|
2974
2963
|
return `${x} ${q} (${V})`;
|
|
2975
2964
|
} else typeof C == "string" || C instanceof Date ? C = `'${C}'` : Array.isArray(C) && C.length > 0 && (C = `'${C[0]}'`);
|
|
2976
2965
|
else if (["in", "not in"].includes(v.operator)) {
|
|
2977
2966
|
let V = [];
|
|
2978
2967
|
Array.isArray(C) ? V = C.map(
|
|
2979
|
-
(
|
|
2980
|
-
) : typeof C == "string" ? V = C.split(",").map((
|
|
2981
|
-
const K =
|
|
2968
|
+
(z) => typeof z == "string" ? `'${z}'` : String(z)
|
|
2969
|
+
) : typeof C == "string" ? V = C.split(",").map((z) => {
|
|
2970
|
+
const K = z.trim();
|
|
2982
2971
|
return v.field.dataType === "string" ? `'${K}'` : K;
|
|
2983
2972
|
}) : typeof C == "number" && (V = [String(C)]), C = `(${V.join(", ")})`;
|
|
2984
2973
|
}
|
|
@@ -2998,7 +2987,7 @@ function Ka({
|
|
|
2998
2987
|
}
|
|
2999
2988
|
}, S = (v) => {
|
|
3000
2989
|
const x = v.conditions.map(A), q = v.groups.map(
|
|
3001
|
-
(
|
|
2990
|
+
(z) => S(z)
|
|
3002
2991
|
), C = [...x, ...q].filter(Boolean);
|
|
3003
2992
|
if (C.length === 0) return "";
|
|
3004
2993
|
const Z = C.join(` ${v.logicalOperator} `), V = C.length > 1 ? `(${Z})` : Z;
|
|
@@ -3034,7 +3023,7 @@ function Qa({
|
|
|
3034
3023
|
/* @__PURE__ */ t(st, { asChild: !0, children: /* @__PURE__ */ t(
|
|
3035
3024
|
"div",
|
|
3036
3025
|
{
|
|
3037
|
-
className:
|
|
3026
|
+
className: M(
|
|
3038
3027
|
"w-[200px] overflow-hidden text-ellipsis whitespace-nowrap text-sm",
|
|
3039
3028
|
n
|
|
3040
3029
|
),
|
|
@@ -3064,7 +3053,7 @@ function Ha({
|
|
|
3064
3053
|
role: "combobox",
|
|
3065
3054
|
"aria-expanded": d,
|
|
3066
3055
|
title: e ? `${e.entityName}.${e.name}` : void 0,
|
|
3067
|
-
className:
|
|
3056
|
+
className: M(
|
|
3068
3057
|
"min-w-0 justify-between gap-1.5 font-normal",
|
|
3069
3058
|
!e && "text-muted-foreground",
|
|
3070
3059
|
u
|
|
@@ -3085,7 +3074,7 @@ function Ha({
|
|
|
3085
3074
|
m.preventDefault(), (w = (f = m.currentTarget) == null ? void 0 : f.querySelector('input[type="text"]')) == null || w.focus();
|
|
3086
3075
|
},
|
|
3087
3076
|
children: /* @__PURE__ */ t(
|
|
3088
|
-
|
|
3077
|
+
qn,
|
|
3089
3078
|
{
|
|
3090
3079
|
fields: a,
|
|
3091
3080
|
selectedIds: i,
|
|
@@ -3110,14 +3099,14 @@ function on(e, n) {
|
|
|
3110
3099
|
), d = n ? n.dataSource : a, c = n ? n.connectionId || ((m = n.dataSource) == null ? void 0 : m.connectionId) : u || (a == null ? void 0 : a.connectionId) || o, i = Q(
|
|
3111
3100
|
() => ({
|
|
3112
3101
|
id: `card-filter-option:${e.id}`,
|
|
3113
|
-
...
|
|
3102
|
+
...Ma(e, { dataSource: d, connectionId: c })
|
|
3114
3103
|
}),
|
|
3115
3104
|
[c, d, e]
|
|
3116
3105
|
), s = Q(
|
|
3117
|
-
() =>
|
|
3106
|
+
() => jn({ filter: i }),
|
|
3118
3107
|
[i]
|
|
3119
3108
|
);
|
|
3120
|
-
return
|
|
3109
|
+
return Gn(i, {
|
|
3121
3110
|
inputContext: s,
|
|
3122
3111
|
currentSelectionPolicy: "exclude"
|
|
3123
3112
|
});
|
|
@@ -3141,7 +3130,7 @@ function Pa({
|
|
|
3141
3130
|
}, y = (h) => {
|
|
3142
3131
|
i(h), !h && s.query && s.setQuery("");
|
|
3143
3132
|
};
|
|
3144
|
-
return /* @__PURE__ */ t("div", { className:
|
|
3133
|
+
return /* @__PURE__ */ t("div", { className: M("w-full", d), children: /* @__PURE__ */ l(it, { open: c, onOpenChange: y, modal: !0, children: [
|
|
3145
3134
|
/* @__PURE__ */ t(lt, { asChild: !0, children: /* @__PURE__ */ l(
|
|
3146
3135
|
U,
|
|
3147
3136
|
{
|
|
@@ -3245,7 +3234,7 @@ function Ya({
|
|
|
3245
3234
|
size: "xs",
|
|
3246
3235
|
role: "combobox",
|
|
3247
3236
|
"aria-expanded": c,
|
|
3248
|
-
className:
|
|
3237
|
+
className: M(
|
|
3249
3238
|
"min-w-0 flex-1 justify-between gap-1.5 px-2 font-normal",
|
|
3250
3239
|
d
|
|
3251
3240
|
),
|
|
@@ -3253,7 +3242,7 @@ function Ya({
|
|
|
3253
3242
|
/* @__PURE__ */ t(
|
|
3254
3243
|
"span",
|
|
3255
3244
|
{
|
|
3256
|
-
className:
|
|
3245
|
+
className: M("truncate", !a && "text-muted-foreground"),
|
|
3257
3246
|
children: a ? f : u
|
|
3258
3247
|
}
|
|
3259
3248
|
),
|
|
@@ -3298,12 +3287,12 @@ function Ja({
|
|
|
3298
3287
|
onChange: d,
|
|
3299
3288
|
className: c
|
|
3300
3289
|
}) {
|
|
3301
|
-
const i =
|
|
3290
|
+
const i = Un(), s = Bn(), m = n === "between" || n === "not between", f = Q(() => {
|
|
3302
3291
|
if (!m || !a) return;
|
|
3303
3292
|
const D = s(a);
|
|
3304
3293
|
return {
|
|
3305
3294
|
...D,
|
|
3306
|
-
tooltip: D.dates ? void 0 : Jt(a).dataAnchored ?
|
|
3295
|
+
tooltip: D.dates ? void 0 : Jt(a).dataAnchored ? Wn : Kn
|
|
3307
3296
|
};
|
|
3308
3297
|
}, [m, a, s]), w = Q(() => {
|
|
3309
3298
|
if (m) {
|
|
@@ -3312,7 +3301,7 @@ function Ja({
|
|
|
3312
3301
|
return D ? { from: D.start, to: D.end } : void 0;
|
|
3313
3302
|
}
|
|
3314
3303
|
if (e && Array.isArray(e) && e.length === 2) {
|
|
3315
|
-
const D =
|
|
3304
|
+
const D = Pe(e[0], i, "start"), j = Pe(e[1], i, "end");
|
|
3316
3305
|
if (D && j)
|
|
3317
3306
|
return { from: D, to: j };
|
|
3318
3307
|
}
|
|
@@ -3320,10 +3309,10 @@ function Ja({
|
|
|
3320
3309
|
}, [e, m, f, i]), y = Q(() => {
|
|
3321
3310
|
if (!e || m || o) return;
|
|
3322
3311
|
const D = Array.isArray(e) ? e[0] : e;
|
|
3323
|
-
return
|
|
3324
|
-
}, [e, m, o, i]), h = (D) => n === "<=" || n === ">" ?
|
|
3312
|
+
return Pe(D, i, "start");
|
|
3313
|
+
}, [e, m, o, i]), h = (D) => n === "<=" || n === ">" ? ha(D, i) : xa(D, i);
|
|
3325
3314
|
return /* @__PURE__ */ t(
|
|
3326
|
-
|
|
3315
|
+
Qn,
|
|
3327
3316
|
{
|
|
3328
3317
|
value: m ? w : void 0,
|
|
3329
3318
|
selectionMode: m ? "range" : "single",
|
|
@@ -3341,7 +3330,7 @@ function Ja({
|
|
|
3341
3330
|
d({ value: "" });
|
|
3342
3331
|
return;
|
|
3343
3332
|
}
|
|
3344
|
-
const j = h(D), O =
|
|
3333
|
+
const j = h(D), O = fa(j, n, {
|
|
3345
3334
|
timezone: i
|
|
3346
3335
|
});
|
|
3347
3336
|
d({ value: typeof O == "string" ? O : O.toISOString() });
|
|
@@ -3360,10 +3349,10 @@ function Ja({
|
|
|
3360
3349
|
relativeSummary: f,
|
|
3361
3350
|
supplementalFooter: m ? /* @__PURE__ */ t("p", { className: "border-t border-border px-3 py-2 text-[11px] text-muted-foreground", children: "Presets and Relative update each time the card runs. Static dates stay fixed." }) : void 0,
|
|
3362
3351
|
timezone: i,
|
|
3363
|
-
enableTimePrecision:
|
|
3352
|
+
enableTimePrecision: pa(u),
|
|
3364
3353
|
staticTimeInputs: !1,
|
|
3365
3354
|
showRelativeTab: m,
|
|
3366
|
-
className:
|
|
3355
|
+
className: M("min-w-0", c),
|
|
3367
3356
|
buttonClassName: "h-7 text-[12px] [&>span]:text-[12px]",
|
|
3368
3357
|
placeholder: "Select date…"
|
|
3369
3358
|
}
|
|
@@ -3436,8 +3425,8 @@ const Xa = (e) => e.conditions.length > 0 || e.groups.length > 0, ht = [
|
|
|
3436
3425
|
isNotNull: "Is not null",
|
|
3437
3426
|
"not between": "Not between"
|
|
3438
3427
|
};
|
|
3439
|
-
function
|
|
3440
|
-
return rr[e] ||
|
|
3428
|
+
function Je(e) {
|
|
3429
|
+
return rr[e] || ga(e);
|
|
3441
3430
|
}
|
|
3442
3431
|
function sr(e) {
|
|
3443
3432
|
switch (e) {
|
|
@@ -3470,7 +3459,7 @@ function dn({
|
|
|
3470
3459
|
{
|
|
3471
3460
|
size: "xs",
|
|
3472
3461
|
"aria-label": a,
|
|
3473
|
-
className:
|
|
3462
|
+
className: M(ln, "font-medium"),
|
|
3474
3463
|
children: /* @__PURE__ */ t(be, {})
|
|
3475
3464
|
}
|
|
3476
3465
|
),
|
|
@@ -3510,7 +3499,7 @@ function cn({
|
|
|
3510
3499
|
{
|
|
3511
3500
|
ref: y,
|
|
3512
3501
|
style: _,
|
|
3513
|
-
className:
|
|
3502
|
+
className: M(
|
|
3514
3503
|
"flex items-center gap-2 rounded-control px-1.5 py-1 transition-colors hover:bg-muted/40",
|
|
3515
3504
|
k && "z-50 opacity-50"
|
|
3516
3505
|
),
|
|
@@ -3533,7 +3522,7 @@ function cn({
|
|
|
3533
3522
|
onValueChange: (T) => d(a, T),
|
|
3534
3523
|
"aria-label": "Logical operator"
|
|
3535
3524
|
}
|
|
3536
|
-
) : /* @__PURE__ */ t("span", { className:
|
|
3525
|
+
) : /* @__PURE__ */ t("span", { className: M(ln, "text-center", xt), children: "Where" }),
|
|
3537
3526
|
/* @__PURE__ */ t(
|
|
3538
3527
|
Ha,
|
|
3539
3528
|
{
|
|
@@ -3547,7 +3536,7 @@ function cn({
|
|
|
3547
3536
|
},
|
|
3548
3537
|
availableFields: c,
|
|
3549
3538
|
placeholder: "Select field",
|
|
3550
|
-
className:
|
|
3539
|
+
className: M("w-60 shrink-0", $t)
|
|
3551
3540
|
}
|
|
3552
3541
|
),
|
|
3553
3542
|
/* @__PURE__ */ l(
|
|
@@ -3565,11 +3554,11 @@ function cn({
|
|
|
3565
3554
|
{
|
|
3566
3555
|
size: "xs",
|
|
3567
3556
|
"aria-label": "Operator",
|
|
3568
|
-
className:
|
|
3569
|
-
children: /* @__PURE__ */ t(be, { children: e.operator ?
|
|
3557
|
+
className: M("w-40 shrink-0", $t),
|
|
3558
|
+
children: /* @__PURE__ */ t(be, { children: e.operator ? Je(e.operator) : "" })
|
|
3570
3559
|
}
|
|
3571
3560
|
),
|
|
3572
|
-
/* @__PURE__ */ t(ve, { children: sr(D).map((T) => /* @__PURE__ */ t(re, { value: T, children:
|
|
3561
|
+
/* @__PURE__ */ t(ve, { children: sr(D).map((T) => /* @__PURE__ */ t(re, { value: T, children: Je(T) }, T)) })
|
|
3573
3562
|
]
|
|
3574
3563
|
}
|
|
3575
3564
|
),
|
|
@@ -3594,7 +3583,7 @@ function cn({
|
|
|
3594
3583
|
value: T.target.value
|
|
3595
3584
|
}),
|
|
3596
3585
|
className: "min-w-0 flex-1",
|
|
3597
|
-
placeholder: `${
|
|
3586
|
+
placeholder: `${Je(e.operator)}…`
|
|
3598
3587
|
}
|
|
3599
3588
|
) : /* @__PURE__ */ t(
|
|
3600
3589
|
Ya,
|
|
@@ -3681,7 +3670,7 @@ function un({
|
|
|
3681
3670
|
type: "button",
|
|
3682
3671
|
size: "xs",
|
|
3683
3672
|
variant: "outline",
|
|
3684
|
-
className:
|
|
3673
|
+
className: M("gap-1.5", Ft),
|
|
3685
3674
|
onClick: e,
|
|
3686
3675
|
children: [
|
|
3687
3676
|
/* @__PURE__ */ t(Ve, { className: "h-3 w-3" }),
|
|
@@ -3695,7 +3684,7 @@ function un({
|
|
|
3695
3684
|
type: "button",
|
|
3696
3685
|
size: "xs",
|
|
3697
3686
|
variant: "ghost",
|
|
3698
|
-
className:
|
|
3687
|
+
className: M("gap-1.5 text-muted-foreground hover:text-foreground", Ft),
|
|
3699
3688
|
onClick: n,
|
|
3700
3689
|
children: [
|
|
3701
3690
|
/* @__PURE__ */ t(Ve, { className: "h-3 w-3" }),
|
|
@@ -3755,7 +3744,7 @@ function or({
|
|
|
3755
3744
|
{
|
|
3756
3745
|
ref: j,
|
|
3757
3746
|
style: X,
|
|
3758
|
-
className:
|
|
3747
|
+
className: M(
|
|
3759
3748
|
n > 0 && "mt-2 overflow-hidden rounded-[6px] border border-border/60",
|
|
3760
3749
|
P && "z-50 opacity-50"
|
|
3761
3750
|
),
|
|
@@ -3808,23 +3797,23 @@ function or({
|
|
|
3808
3797
|
}
|
|
3809
3798
|
)
|
|
3810
3799
|
] }),
|
|
3811
|
-
/* @__PURE__ */ l("div", { className:
|
|
3800
|
+
/* @__PURE__ */ l("div", { className: M(n > 0 && "p-2"), children: [
|
|
3812
3801
|
/* @__PURE__ */ t(
|
|
3813
3802
|
Re,
|
|
3814
3803
|
{
|
|
3815
|
-
sensors:
|
|
3816
|
-
he(
|
|
3817
|
-
he(
|
|
3818
|
-
coordinateGetter:
|
|
3804
|
+
sensors: Xe(
|
|
3805
|
+
he(tt),
|
|
3806
|
+
he(et, {
|
|
3807
|
+
coordinateGetter: Ze
|
|
3819
3808
|
})
|
|
3820
3809
|
),
|
|
3821
3810
|
collisionDetection: Ee,
|
|
3822
3811
|
onDragEnd: p,
|
|
3823
3812
|
children: /* @__PURE__ */ t(
|
|
3824
|
-
|
|
3813
|
+
ze,
|
|
3825
3814
|
{
|
|
3826
3815
|
items: e.conditions.map((A) => A.id),
|
|
3827
|
-
strategy:
|
|
3816
|
+
strategy: Me,
|
|
3828
3817
|
children: /* @__PURE__ */ t("div", { className: "space-y-0.5", children: e.conditions.map((A, S) => /* @__PURE__ */ t(
|
|
3829
3818
|
cn,
|
|
3830
3819
|
{
|
|
@@ -3848,19 +3837,19 @@ function or({
|
|
|
3848
3837
|
/* @__PURE__ */ t(
|
|
3849
3838
|
Re,
|
|
3850
3839
|
{
|
|
3851
|
-
sensors:
|
|
3852
|
-
he(
|
|
3853
|
-
he(
|
|
3854
|
-
coordinateGetter:
|
|
3840
|
+
sensors: Xe(
|
|
3841
|
+
he(tt),
|
|
3842
|
+
he(et, {
|
|
3843
|
+
coordinateGetter: Ze
|
|
3855
3844
|
})
|
|
3856
3845
|
),
|
|
3857
3846
|
collisionDetection: Ee,
|
|
3858
3847
|
onDragEnd: I,
|
|
3859
3848
|
children: /* @__PURE__ */ t(
|
|
3860
|
-
|
|
3849
|
+
ze,
|
|
3861
3850
|
{
|
|
3862
3851
|
items: e.groups.map((A) => A.id),
|
|
3863
|
-
strategy:
|
|
3852
|
+
strategy: Me,
|
|
3864
3853
|
children: e.groups.map(
|
|
3865
3854
|
(A) => h(A, n + 1, e.id)
|
|
3866
3855
|
)
|
|
@@ -3912,10 +3901,10 @@ function Ir({
|
|
|
3912
3901
|
...c ? {
|
|
3913
3902
|
onChange: (x) => c(Xa(x) ? x : null)
|
|
3914
3903
|
} : {}
|
|
3915
|
-
}), p =
|
|
3916
|
-
he(
|
|
3917
|
-
he(
|
|
3918
|
-
coordinateGetter:
|
|
3904
|
+
}), p = Xe(
|
|
3905
|
+
he(tt),
|
|
3906
|
+
he(et, {
|
|
3907
|
+
coordinateGetter: Ze
|
|
3919
3908
|
})
|
|
3920
3909
|
), [I, A] = H(!1), S = (x, q = 0, C) => {
|
|
3921
3910
|
if (q === 0) {
|
|
@@ -3927,10 +3916,10 @@ function Ir({
|
|
|
3927
3916
|
sensors: p,
|
|
3928
3917
|
collisionDetection: Ee,
|
|
3929
3918
|
onDragEnd: (V) => {
|
|
3930
|
-
const { active:
|
|
3931
|
-
if (K &&
|
|
3919
|
+
const { active: z, over: K } = V;
|
|
3920
|
+
if (K && z.id !== K.id) {
|
|
3932
3921
|
const G = x.conditions.findIndex(
|
|
3933
|
-
(te) => te.id ===
|
|
3922
|
+
(te) => te.id === z.id
|
|
3934
3923
|
), ee = x.conditions.findIndex(
|
|
3935
3924
|
(te) => te.id === K.id
|
|
3936
3925
|
);
|
|
@@ -3938,15 +3927,15 @@ function Ir({
|
|
|
3938
3927
|
}
|
|
3939
3928
|
},
|
|
3940
3929
|
children: /* @__PURE__ */ t(
|
|
3941
|
-
|
|
3930
|
+
ze,
|
|
3942
3931
|
{
|
|
3943
3932
|
items: x.conditions.map((V) => V.id),
|
|
3944
|
-
strategy:
|
|
3945
|
-
children: /* @__PURE__ */ t("div", { className: "space-y-0.5", children: x.conditions.map((V,
|
|
3933
|
+
strategy: Me,
|
|
3934
|
+
children: /* @__PURE__ */ t("div", { className: "space-y-0.5", children: x.conditions.map((V, z) => /* @__PURE__ */ t(
|
|
3946
3935
|
cn,
|
|
3947
3936
|
{
|
|
3948
3937
|
condition: V,
|
|
3949
|
-
index:
|
|
3938
|
+
index: z,
|
|
3950
3939
|
groupId: x.id,
|
|
3951
3940
|
groupLogicalOperator: x.logicalOperator,
|
|
3952
3941
|
onRemoveCondition: h,
|
|
@@ -3968,10 +3957,10 @@ function Ir({
|
|
|
3968
3957
|
sensors: p,
|
|
3969
3958
|
collisionDetection: Ee,
|
|
3970
3959
|
onDragEnd: (V) => {
|
|
3971
|
-
const { active:
|
|
3972
|
-
if (K &&
|
|
3960
|
+
const { active: z, over: K } = V;
|
|
3961
|
+
if (K && z.id !== K.id) {
|
|
3973
3962
|
const G = x.groups.findIndex(
|
|
3974
|
-
(te) => te.id ===
|
|
3963
|
+
(te) => te.id === z.id
|
|
3975
3964
|
), ee = x.groups.findIndex(
|
|
3976
3965
|
(te) => te.id === K.id
|
|
3977
3966
|
);
|
|
@@ -3979,10 +3968,10 @@ function Ir({
|
|
|
3979
3968
|
}
|
|
3980
3969
|
},
|
|
3981
3970
|
children: /* @__PURE__ */ t(
|
|
3982
|
-
|
|
3971
|
+
ze,
|
|
3983
3972
|
{
|
|
3984
3973
|
items: x.groups.map((V) => V.id),
|
|
3985
|
-
strategy:
|
|
3974
|
+
strategy: Me,
|
|
3986
3975
|
children: x.groups.map(
|
|
3987
3976
|
(V) => S(V, q + 1, x.id)
|
|
3988
3977
|
)
|
|
@@ -4026,8 +4015,8 @@ function Ir({
|
|
|
4026
4015
|
},
|
|
4027
4016
|
x.id
|
|
4028
4017
|
);
|
|
4029
|
-
}, v =
|
|
4030
|
-
return /* @__PURE__ */ l("div", { className:
|
|
4018
|
+
}, v = Hn(e);
|
|
4019
|
+
return /* @__PURE__ */ l("div", { className: M("group/filters", i ? "flex flex-col" : "flex min-h-0 flex-1 flex-col"), "data-inline": i || void 0, children: [
|
|
4031
4020
|
/* @__PURE__ */ l("div", { className: i ? "" : "min-h-0 flex-1 overflow-y-auto px-3 py-3", children: [
|
|
4032
4021
|
f ? /* @__PURE__ */ l("div", { className: "flex items-center justify-center gap-2 py-6 text-[12px] text-muted-foreground", children: [
|
|
4033
4022
|
/* @__PURE__ */ t(fn, { className: "h-3.5 w-3.5 animate-spin" }),
|
|
@@ -4054,7 +4043,7 @@ function Ir({
|
|
|
4054
4043
|
/* @__PURE__ */ t("span", { className: "text-[11px] text-muted-foreground", children: "Nest conditions in groups" })
|
|
4055
4044
|
] }),
|
|
4056
4045
|
X && !i && /* @__PURE__ */ l("div", { className: "mt-3 border-t border-border/60 pt-3", children: [
|
|
4057
|
-
/* @__PURE__ */ t("div", { className:
|
|
4046
|
+
/* @__PURE__ */ t("div", { className: M("mb-1.5", xt), children: "Where clause" }),
|
|
4058
4047
|
/* @__PURE__ */ t("pre", { className: "overflow-x-auto whitespace-pre-wrap break-words rounded-[6px] border border-border bg-muted/40 px-3 py-2 font-mono text-[12px] leading-[1.55] text-foreground", children: P(s) })
|
|
4059
4048
|
] })
|
|
4060
4049
|
] }),
|
|
@@ -4087,14 +4076,13 @@ export {
|
|
|
4087
4076
|
Cr as A,
|
|
4088
4077
|
Sr as C,
|
|
4089
4078
|
Nr as F,
|
|
4090
|
-
|
|
4091
|
-
|
|
4079
|
+
za as I,
|
|
4080
|
+
ya as L,
|
|
4092
4081
|
kr as V,
|
|
4093
|
-
|
|
4094
|
-
|
|
4095
|
-
|
|
4096
|
-
|
|
4097
|
-
za as e,
|
|
4082
|
+
wr as a,
|
|
4083
|
+
Ir as b,
|
|
4084
|
+
Zt as c,
|
|
4085
|
+
Ma as d,
|
|
4098
4086
|
Va as g,
|
|
4099
4087
|
en as i,
|
|
4100
4088
|
Dr as u
|