@devtable/dashboard 14.0.0 → 14.0.1

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.
@@ -938,7 +938,7 @@ class Gy {
938
938
  };
939
939
  }
940
940
  }
941
- class C$ {
941
+ class S$ {
942
942
  constructor(t) {
943
943
  this.implementation = t;
944
944
  }
@@ -6545,7 +6545,7 @@ class wl {
6545
6545
  }), this.instanceRegistry.clear(), this.factoryRegistry.clear();
6546
6546
  }
6547
6547
  }
6548
- const um = "14.0.0", C0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
6548
+ const um = "14.0.1", C0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
6549
6549
  __proto__: null,
6550
6550
  version: um
6551
6551
  }, Symbol.toStringTag, { value: "Module" }));
@@ -26953,7 +26953,7 @@ const jx = p.model("ViewDivisionConfig", {
26953
26953
  const r = e.panelIDs.filter((i) => i !== t);
26954
26954
  e.panelIDs.length = 0, e.panelIDs.push(...r);
26955
26955
  }
26956
- })), xr = "13.45.0", D$ = {
26956
+ })), xr = "13.45.0", z$ = {
26957
26957
  definition: {
26958
26958
  sqlSnippets: [],
26959
26959
  queries: [],
@@ -29776,7 +29776,7 @@ const H8 = D(({
29776
29776
  ] }) });
29777
29777
  });
29778
29778
  var K8 = /* @__PURE__ */ ((e) => (e.Use = "use", e.Edit = "edit", e))(K8 || {});
29779
- const I$ = {
29779
+ const D$ = {
29780
29780
  [J.Division]: "Division",
29781
29781
  [J.Tabs]: "Tabs",
29782
29782
  [J.Modal]: "Modal"
@@ -29784,7 +29784,7 @@ const I$ = {
29784
29784
  [J.Division]: "rgba(255, 0, 0, 0.2)",
29785
29785
  [J.Modal]: "rgba(0, 0, 0, 0.2)",
29786
29786
  [J.Tabs]: "rgba(255, 200, 100, 0.4)"
29787
- }, M$ = {
29787
+ }, I$ = {
29788
29788
  [J.Division]: "#ff4000",
29789
29789
  [J.Modal]: "#000",
29790
29790
  [J.Tabs]: "#ffad18"
@@ -30266,14 +30266,20 @@ const J8 = p.compose("FiltersModel", Ox, p.model("FiltersModel", {
30266
30266
  delay: 0
30267
30267
  }));
30268
30268
  }
30269
- })), lM = (e) => "cols" in e;
30270
- function cM(e) {
30269
+ }));
30270
+ function lM(e) {
30271
30271
  var t;
30272
- return lM(e) ? {
30273
- filters: e.cols.filter((r) => r.type === "filter").map((r) => r.metricSourceCol),
30274
- groupBys: e.cols.filter((r) => r.type === "group_by").map((r) => r.metricSourceCol),
30275
- trendingDateCol: ((t = e.cols.find((r) => r.type === "trending_date_col")) == null ? void 0 : t.metricSourceCol) ?? null
30276
- } : {
30272
+ if ("cols" in e) {
30273
+ const {
30274
+ cols: r
30275
+ } = e;
30276
+ return {
30277
+ filters: r.filter((i) => i.type === "filter").map((i) => i.metricSourceCol),
30278
+ groupBys: r.filter((i) => i.type === "group_by").map((i) => i.metricSourceCol),
30279
+ trendingDateCol: ((t = r.find((i) => i.type === "trending_date_col")) == null ? void 0 : t.metricSourceCol) ?? null
30280
+ };
30281
+ }
30282
+ return {
30277
30283
  filters: e.filters,
30278
30284
  groupBys: e.groupBys,
30279
30285
  trendingDateCol: null
@@ -30294,7 +30300,7 @@ function ng(e) {
30294
30300
  return i ? $d[i] : r.dimension !== null ? $d.dimension : "ERROR";
30295
30301
  });
30296
30302
  }
30297
- function dM(e) {
30303
+ function cM(e) {
30298
30304
  if (e.length === 0)
30299
30305
  return [];
30300
30306
  const t = ng(e);
@@ -30321,7 +30327,7 @@ function dM(e) {
30321
30327
  })
30322
30328
  }));
30323
30329
  }
30324
- function uM(e) {
30330
+ function dM(e) {
30325
30331
  if (e.length === 0)
30326
30332
  return [];
30327
30333
  const t = ng(e);
@@ -30336,7 +30342,7 @@ function uM(e) {
30336
30342
  }))
30337
30343
  }));
30338
30344
  }
30339
- function hM(e, t) {
30345
+ function uM(e, t) {
30340
30346
  if (!t)
30341
30347
  throw new Error("Shouldnt run query without ID");
30342
30348
  if (e === "derived")
@@ -30345,7 +30351,7 @@ function hM(e, t) {
30345
30351
  return `/buffet/api/metric_management/combined_metric/${t}`;
30346
30352
  throw new Error(`Unexpected metric type[${e}]`);
30347
30353
  }
30348
- const pM = p.model({
30354
+ const hM = p.model({
30349
30355
  data: p.optional(p.frozen(), null),
30350
30356
  filters: p.optional(p.frozen(), []),
30351
30357
  groupBys: p.optional(p.frozen(), []),
@@ -30375,10 +30381,10 @@ const pM = p.model({
30375
30381
  return (t = this.metric) == null ? void 0 : t.type;
30376
30382
  },
30377
30383
  get filterColOptions() {
30378
- return dM(e.filters);
30384
+ return cM(e.filters);
30379
30385
  },
30380
30386
  get groupByColOptions() {
30381
- return uM(e.groupBys);
30387
+ return dM(e.groupBys);
30382
30388
  },
30383
30389
  get flatGroupByColOptions() {
30384
30390
  const t = this.groupByColOptions, r = [];
@@ -30399,7 +30405,7 @@ const pM = p.model({
30399
30405
  if (e.mmInfo.type === me.MericoMetricSystem && !(!e.metricID || !e.metricType)) {
30400
30406
  (t = e.controller) == null || t.abort(), e.controller = new AbortController(), e.state = "loading";
30401
30407
  try {
30402
- const r = hM(e.metricType, e.metricID), i = Ta(e.mmInfo.dataSource, {
30408
+ const r = uM(e.metricType, e.metricID), i = Ta(e.mmInfo.dataSource, {
30403
30409
  url: r,
30404
30410
  method: "GET",
30405
30411
  data: {
@@ -30413,7 +30419,7 @@ const pM = p.model({
30413
30419
  filters: l,
30414
30420
  groupBys: c,
30415
30421
  trendingDateCol: d
30416
- } = cM(s.data);
30422
+ } = lM(s.data);
30417
30423
  e.data = o, e.filters = l, e.groupBys = c, e.trendingDateCol = d, e.state = "idle", e.error = null;
30418
30424
  } catch (r) {
30419
30425
  if (!Gt.isCancel(r)) {
@@ -30431,7 +30437,7 @@ const pM = p.model({
30431
30437
  delay: 0
30432
30438
  }));
30433
30439
  }
30434
- })), mM = p.model({
30440
+ })), pM = p.model({
30435
30441
  keyword: p.optional(p.string, ""),
30436
30442
  data: p.optional(p.frozen(), []),
30437
30443
  state: p.optional(p.enumeration(["idle", "loading", "error"]), "idle"),
@@ -30489,9 +30495,9 @@ const pM = p.model({
30489
30495
  delay: 0
30490
30496
  }));
30491
30497
  }
30492
- })), xM = p.model({
30493
- metrics: p.optional(mM, {}),
30494
- metricDetail: p.optional(pM, {}),
30498
+ })), mM = p.model({
30499
+ metrics: p.optional(pM, {}),
30500
+ metricDetail: p.optional(hM, {}),
30495
30501
  keyword: p.optional(p.string, ""),
30496
30502
  metricID: p.optional(p.string, "")
30497
30503
  }).views((e) => ({
@@ -30520,11 +30526,11 @@ const pM = p.model({
30520
30526
  selectMetric(t) {
30521
30527
  e.metricID = t;
30522
30528
  }
30523
- })), gM = p.compose("DataSourceModel", Cx, p.model({
30529
+ })), xM = p.compose("DataSourceModel", Cx, p.model({
30524
30530
  dbInfo: p.optional(oM, {}),
30525
- mericoMetricInfo: p.optional(xM, {})
30526
- })), fM = p.model("DataSourcesModel", {
30527
- list: p.optional(p.array(gM), [])
30531
+ mericoMetricInfo: p.optional(mM, {})
30532
+ })), gM = p.model("DataSourcesModel", {
30533
+ list: p.optional(p.array(xM), [])
30528
30534
  }).views((e) => ({
30529
30535
  find({
30530
30536
  type: t,
@@ -30543,31 +30549,31 @@ const pM = p.model({
30543
30549
  e.list.length = 0, e.list.push(...t);
30544
30550
  }
30545
30551
  }));
30546
- function bM(e) {
30552
+ function fM(e) {
30547
30553
  return e.length === 1 && e[0] === "_QUERY_VARS_";
30548
30554
  }
30549
- function yM(e) {
30555
+ function bM(e) {
30550
30556
  return e.length === 1 && e[0] === "_MOCK_CONTEXT_";
30551
30557
  }
30552
- function _M(e) {
30558
+ function yM(e) {
30553
30559
  return e.length === 1 && e[0] === "_FILTERS_";
30554
30560
  }
30555
- function vM(e) {
30561
+ function _M(e) {
30556
30562
  return e.length === 2 && e[0] === "_FILTERS_";
30557
30563
  }
30558
- function jM(e) {
30564
+ function vM(e) {
30559
30565
  return e.length === 1 && e[0] === "_SQL_SNIPPETS_";
30560
30566
  }
30561
- function wM(e) {
30567
+ function jM(e) {
30562
30568
  return e.length === 2 && e[0] === "_SQL_SNIPPETS_";
30563
30569
  }
30564
- function SM(e) {
30570
+ function wM(e) {
30565
30571
  return e.length === 2 && e[0] === "_QUERIES_";
30566
30572
  }
30567
- function CM(e) {
30573
+ function SM(e) {
30568
30574
  return e.length === 1 && e[0] === "_QUERIES_";
30569
30575
  }
30570
- function kM(e) {
30576
+ function CM(e) {
30571
30577
  return e.length === 2 && e[0] === "_VIEWS_";
30572
30578
  }
30573
30579
  function oo(e) {
@@ -30583,7 +30589,7 @@ function br(e) {
30583
30589
  children: null
30584
30590
  };
30585
30591
  }
30586
- function TM(e) {
30592
+ function kM(e) {
30587
30593
  switch (e._type) {
30588
30594
  case "GROUP":
30589
30595
  case "ACTION":
@@ -30604,7 +30610,7 @@ function TM(e) {
30604
30610
  return e.parentID ? ["_VIEWS_", e.parentID, "_PANELS_", e.value, "_TABS_", "Data"] : (console.error("[getPathFromOption] parentID is required"), null);
30605
30611
  }
30606
30612
  }
30607
- const zM = p.model("EditorModel", {
30613
+ const TM = p.model("EditorModel", {
30608
30614
  path: p.optional(p.frozen(), []),
30609
30615
  settings_open: p.optional(p.boolean, !1)
30610
30616
  }).views((e) => ({
@@ -30692,7 +30698,7 @@ const zM = p.model("EditorModel", {
30692
30698
  e.setSettingsOpen(!1);
30693
30699
  },
30694
30700
  navigate(t) {
30695
- const r = TM(t);
30701
+ const r = kM(t);
30696
30702
  r && e.setPath(r);
30697
30703
  }
30698
30704
  })).views((e) => ({
@@ -30792,7 +30798,7 @@ const zM = p.model("EditorModel", {
30792
30798
  }), u.push(m);
30793
30799
  }), u;
30794
30800
  }
30795
- })), DM = p.compose("LayoutsModel", qx, p.model({
30801
+ })), zM = p.compose("LayoutsModel", qx, p.model({
30796
30802
  currentLayoutWrapperWidth: p.optional(p.number, 0)
30797
30803
  })).views((e) => ({
30798
30804
  get divisionPreviewScale() {
@@ -30887,7 +30893,7 @@ const zM = p.model("EditorModel", {
30887
30893
  this.removeByID(r);
30888
30894
  });
30889
30895
  }
30890
- })), IM = Lx.views((e) => ({
30896
+ })), DM = Lx.views((e) => ({
30891
30897
  get realDataFieldOptions() {
30892
30898
  return e.queryIDs.length === 0 ? [] : e.queries.map((t) => {
30893
30899
  const r = t.data;
@@ -31000,8 +31006,8 @@ const zM = p.model("EditorModel", {
31000
31006
  moveToView(t, r) {
31001
31007
  ut(e).content.views.findByID(t).removePanelID(e.id), ut(e).content.views.findByID(r).appendPanelID(e.id), ut(e).editor.setPath(["_VIEWS_", r, "_PANELS_", e.id]);
31002
31008
  }
31003
- })), MM = p.compose("PanelsModel", Px, p.model({
31004
- list: p.optional(p.array(IM), [])
31009
+ })), IM = p.compose("PanelsModel", Px, p.model({
31010
+ list: p.optional(p.array(DM), [])
31005
31011
  })).views((e) => ({
31006
31012
  get contentModel() {
31007
31013
  return ut(e).content;
@@ -31066,7 +31072,7 @@ const zM = p.model("EditorModel", {
31066
31072
  replaceByIndex(t, r) {
31067
31073
  e.list.splice(t, 1, r);
31068
31074
  }
31069
- })), LM = zx.actions((e) => ({
31075
+ })), MM = zx.actions((e) => ({
31070
31076
  getSchema() {
31071
31077
  const t = e.json, r = [], i = [];
31072
31078
  e.panels.forEach((o) => {
@@ -31092,8 +31098,8 @@ const zM = p.model("EditorModel", {
31092
31098
  const t = JSON.stringify(this.getSchema(), null, 2), r = e.name;
31093
31099
  ci(r, t);
31094
31100
  }
31095
- })), PM = p.compose("ViewsModel", Dx, p.model({
31096
- current: p.optional(p.array(LM), []),
31101
+ })), LM = p.compose("ViewsModel", Dx, p.model({
31102
+ current: p.optional(p.array(MM), []),
31097
31103
  idOfVIE: p.string
31098
31104
  // VIE: view in edit
31099
31105
  })).views((e) => ({
@@ -31192,7 +31198,7 @@ function rg(e) {
31192
31198
  idOfVIE: r
31193
31199
  };
31194
31200
  }
31195
- const EM = p.model({
31201
+ const PM = p.model({
31196
31202
  id: p.string,
31197
31203
  name: p.string,
31198
31204
  dashboard_id: p.string,
@@ -31203,9 +31209,9 @@ const EM = p.model({
31203
31209
  filters: J8,
31204
31210
  queries: tM,
31205
31211
  sqlSnippets: nM,
31206
- views: PM,
31207
- panels: MM,
31208
- layouts: DM,
31212
+ views: LM,
31213
+ panels: IM,
31214
+ layouts: zM,
31209
31215
  mock_context: ex,
31210
31216
  /**
31211
31217
  * this field should be excluded from snapshot
@@ -31526,7 +31532,7 @@ const EM = p.model({
31526
31532
  } = a;
31527
31533
  e.id = r, e.name = i, e.version = s, _t(e.filters.current, o), _t(e.views.current, rg(l).current), _t(e.panels.list, c), _t(e.queries.current, d), _t(e.sqlSnippets.current, u), e.mock_context.current = h;
31528
31534
  }
31529
- })), ig = p.snapshotProcessor(EM, {
31535
+ })), ig = p.snapshotProcessor(PM, {
31530
31536
  preProcessor(e) {
31531
31537
  return {
31532
31538
  ...e,
@@ -31543,10 +31549,10 @@ const EM = p.model({
31543
31549
  }, e);
31544
31550
  }
31545
31551
  });
31546
- function L$(e, t) {
31552
+ function M$(e, t) {
31547
31553
  t.filters && _t(e.filters.current, t.filters);
31548
31554
  }
31549
- function RM({
31555
+ function EM({
31550
31556
  id: e,
31551
31557
  name: t,
31552
31558
  dashboard_id: r,
@@ -31593,16 +31599,16 @@ function RM({
31593
31599
  }
31594
31600
  });
31595
31601
  }
31596
- const $M = p.model({
31602
+ const RM = p.model({
31597
31603
  id: p.identifier,
31598
31604
  name: p.string,
31599
31605
  group: p.string,
31600
31606
  content: ig,
31601
31607
  content_id: p.string,
31602
- datasources: fM,
31608
+ datasources: gM,
31603
31609
  globalSQLSnippets: kx,
31604
31610
  context: nc,
31605
- editor: zM
31611
+ editor: TM
31606
31612
  }).views((e) => ({
31607
31613
  get json() {
31608
31614
  return {
@@ -31638,18 +31644,18 @@ const $M = p.model({
31638
31644
  e.id = i, e.name = a, e.group = s, e.content_id = o, this.updateCurrentContent(r);
31639
31645
  }
31640
31646
  }));
31641
- function AM({
31647
+ function $M({
31642
31648
  id: e,
31643
31649
  name: t,
31644
31650
  group: r,
31645
31651
  content_id: i
31646
31652
  }, a, s, o, l, c) {
31647
- return $M.create({
31653
+ return RM.create({
31648
31654
  id: e,
31649
31655
  name: t,
31650
31656
  group: r,
31651
31657
  content_id: i,
31652
- content: RM(a, l, c),
31658
+ content: EM(a, l, c),
31653
31659
  datasources: {
31654
31660
  list: s
31655
31661
  },
@@ -31660,7 +31666,7 @@ function AM({
31660
31666
  editor: {}
31661
31667
  });
31662
31668
  }
31663
- const OM = {
31669
+ const AM = {
31664
31670
  translation: {
31665
31671
  filter: {
31666
31672
  label: "Filter",
@@ -32666,7 +32672,7 @@ Variable: {{ your_var }}`,
32666
32672
  not_found: "Nothing found..."
32667
32673
  }
32668
32674
  }
32669
- }, VM = {
32675
+ }, OM = {
32670
32676
  translation: {
32671
32677
  filter: {
32672
32678
  label: "筛选器",
@@ -33679,8 +33685,8 @@ Variable: {{ your_var }}`,
33679
33685
  escapeValue: !1
33680
33686
  },
33681
33687
  resources: {
33682
- en: OM,
33683
- zh: VM
33688
+ en: AM,
33689
+ zh: OM
33684
33690
  }
33685
33691
  }).use(My).use(ab);
33686
33692
  Pa.init();
@@ -33790,7 +33796,7 @@ function sg(e, t) {
33790
33796
  function og(e) {
33791
33797
  return B.useCallback((t) => t.provideValue(rt.pluginManager, e.pluginManager).provideValue(rt.vizManager, e.vizManager).provideValue(rt.colorManager, e.colorManager), []);
33792
33798
  }
33793
- const FM = D(({
33799
+ const VM = D(({
33794
33800
  saveDashboardChanges: e
33795
33801
  }) => {
33796
33802
  const {
@@ -33832,7 +33838,7 @@ const FM = D(({
33832
33838
  /* @__PURE__ */ n.jsx(re.Dropdown, { children: /* @__PURE__ */ n.jsx(re.Item, { leftSection: /* @__PURE__ */ n.jsx(nn, { size: 14, color: "red" }), disabled: !s, onClick: a, children: t("common.actions.revert_changes") }) })
33833
33839
  ] })
33834
33840
  ] });
33835
- }), NM = D(({
33841
+ }), FM = D(({
33836
33842
  saveDashboardChanges: e,
33837
33843
  onExit: t,
33838
33844
  headerSlot: r = null
@@ -33855,7 +33861,7 @@ const FM = D(({
33855
33861
  /* @__PURE__ */ n.jsx(L, { size: "xs", color: a ? "red" : "green", leftSection: /* @__PURE__ */ n.jsx(vu, { size: 20 }), onClick: s, children: /* @__PURE__ */ n.jsx(b, { gap: 4, children: /* @__PURE__ */ n.jsx(Fa, { i18nKey: "common.actions.end_editing", values: {
33856
33862
  name: i.name
33857
33863
  }, children: /* @__PURE__ */ n.jsx(S, { td: "underline", size: "xs", children: i.name }) }) }) }),
33858
- /* @__PURE__ */ n.jsx(FM, { saveDashboardChanges: e })
33864
+ /* @__PURE__ */ n.jsx(VM, { saveDashboardChanges: e })
33859
33865
  ] }),
33860
33866
  /* @__PURE__ */ n.jsx(b, { justify: "flex-end", sx: {
33861
33867
  flexGrow: 1
@@ -33867,7 +33873,7 @@ const FM = D(({
33867
33873
  borderTop: "none",
33868
33874
  borderRight: "1px solid #e9ecef",
33869
33875
  borderBottom: "1px solid #e9ecef"
33870
- }, qM = D(() => {
33876
+ }, NM = D(() => {
33871
33877
  var a;
33872
33878
  const {
33873
33879
  t: e
@@ -33879,7 +33885,7 @@ const FM = D(({
33879
33885
  ...Ad,
33880
33886
  background: "rgb(231, 245, 255)"
33881
33887
  }, children: e("panel.add") });
33882
- }), BM = D(({
33888
+ }), qM = D(({
33883
33889
  done: e
33884
33890
  }) => {
33885
33891
  var V, ye;
@@ -33982,7 +33988,7 @@ const FM = D(({
33982
33988
  /* @__PURE__ */ n.jsx(L, { color: "green", size: "xs", type: "submit", leftSection: /* @__PURE__ */ n.jsx(Oe, { size: 18 }), disabled: !P, children: t("common.actions.save_changes") })
33983
33989
  ] })
33984
33990
  ] }) });
33985
- }), HM = D(() => {
33991
+ }), BM = D(() => {
33986
33992
  const {
33987
33993
  t: e
33988
33994
  } = y(), [t, {
@@ -34020,7 +34026,7 @@ const FM = D(({
34020
34026
  ] }),
34021
34027
  /* @__PURE__ */ n.jsx(Ge, { opened: t, onClose: c, title: e("breakpoint.label", {
34022
34028
  count: 2
34023
- }), withinPortal: !0, zIndex: 320, size: 600, closeOnClickOutside: !1, children: /* @__PURE__ */ n.jsx(BM, { done: c }) })
34029
+ }), withinPortal: !0, zIndex: 320, size: 600, closeOnClickOutside: !1, children: /* @__PURE__ */ n.jsx(qM, { done: c }) })
34024
34030
  ] });
34025
34031
  }), Od = {
34026
34032
  height: "30px",
@@ -34028,7 +34034,7 @@ const FM = D(({
34028
34034
  borderTop: "none",
34029
34035
  borderLeft: "1px solid #e9ecef",
34030
34036
  borderBottom: "1px solid #e9ecef"
34031
- }, QM = D(() => {
34037
+ }, HM = D(() => {
34032
34038
  var a;
34033
34039
  const {
34034
34040
  t: e
@@ -34052,7 +34058,7 @@ const FM = D(({
34052
34058
  }, children: [
34053
34059
  /* @__PURE__ */ n.jsx(v.Thead, { children: e }),
34054
34060
  /* @__PURE__ */ n.jsx(v.Tbody, { children: t })
34055
- ] }), GM = ({
34061
+ ] }), QM = ({
34056
34062
  content: e
34057
34063
  }) => {
34058
34064
  const {
@@ -34072,7 +34078,7 @@ const FM = D(({
34072
34078
  /* @__PURE__ */ n.jsx(v.Td, { children: t(`view.component.${i.type}.label`) })
34073
34079
  ] }, i.id)) })
34074
34080
  ] });
34075
- }, WM = ({
34081
+ }, GM = ({
34076
34082
  content: e
34077
34083
  }) => {
34078
34084
  const {
@@ -34092,7 +34098,7 @@ const FM = D(({
34092
34098
  /* @__PURE__ */ n.jsx(v.Td, { children: i.label })
34093
34099
  ] }, i.id)) })
34094
34100
  ] });
34095
- }, UM = ({
34101
+ }, WM = ({
34096
34102
  content: e
34097
34103
  }) => {
34098
34104
  const {
@@ -34112,7 +34118,7 @@ const FM = D(({
34112
34118
  /* @__PURE__ */ n.jsx(v.Td, { children: i.viz.type })
34113
34119
  ] }, i.id)) })
34114
34120
  ] });
34115
- }, YM = ({
34121
+ }, UM = ({
34116
34122
  content: e
34117
34123
  }) => {
34118
34124
  var i;
@@ -34139,7 +34145,7 @@ const FM = D(({
34139
34145
  /* @__PURE__ */ n.jsx(v.Td, { children: a.key })
34140
34146
  ] }, a.id)) })
34141
34147
  ] });
34142
- }, KM = ({
34148
+ }, YM = ({
34143
34149
  content: e
34144
34150
  }) => {
34145
34151
  var i;
@@ -34150,7 +34156,7 @@ const FM = D(({
34150
34156
  /* @__PURE__ */ n.jsx(S, { pl: 10, size: "sm", fw: 500, c: "dimmed", ta: "center", children: t("sql_snippet.labels") }),
34151
34157
  /* @__PURE__ */ n.jsx(Dt, { size: "sm", pl: 10, ff: "monospace", icon: /* @__PURE__ */ n.jsx(Va, { size: 10 }), children: r.map((a) => /* @__PURE__ */ n.jsx(Dt.Item, { children: a.key }, a.key)) })
34152
34158
  ] });
34153
- }, XM = ({
34159
+ }, KM = ({
34154
34160
  content: e
34155
34161
  }) => {
34156
34162
  var i;
@@ -34161,21 +34167,21 @@ const FM = D(({
34161
34167
  /* @__PURE__ */ n.jsx(S, { pl: 10, size: "sm", fw: 500, c: "dimmed", ta: "center", children: t("mock_context.label") }),
34162
34168
  /* @__PURE__ */ n.jsx(Dt, { size: "sm", pl: 10, ff: "monospace", icon: /* @__PURE__ */ n.jsx(Va, { size: 10 }), children: r.map((a) => /* @__PURE__ */ n.jsx(Dt.Item, { children: a }, a)) })
34163
34169
  ] });
34164
- }, ZM = ({
34170
+ }, XM = ({
34165
34171
  content: e
34166
34172
  }) => e ? /* @__PURE__ */ n.jsxs(R, { children: [
34167
34173
  /* @__PURE__ */ n.jsx(A, { mt: 20, mb: 10, variant: "dashed" }),
34168
34174
  /* @__PURE__ */ n.jsx(S, { ta: "left", c: "dimmed", size: "sm", children: "Preview" }),
34169
34175
  /* @__PURE__ */ n.jsxs(T, { children: [
34176
+ /* @__PURE__ */ n.jsx(QM, { content: e }),
34170
34177
  /* @__PURE__ */ n.jsx(GM, { content: e }),
34171
34178
  /* @__PURE__ */ n.jsx(WM, { content: e }),
34172
34179
  /* @__PURE__ */ n.jsx(UM, { content: e }),
34173
34180
  /* @__PURE__ */ n.jsx(YM, { content: e }),
34174
- /* @__PURE__ */ n.jsx(KM, { content: e }),
34175
- /* @__PURE__ */ n.jsx(XM, { content: e })
34181
+ /* @__PURE__ */ n.jsx(KM, { content: e })
34176
34182
  ] })
34177
34183
  ] }) : null;
34178
- function JM(e) {
34184
+ function ZM(e) {
34179
34185
  if (e.target === null)
34180
34186
  throw new Error("FileReader failed with null result");
34181
34187
  if (typeof e.target.result != "string")
@@ -34185,7 +34191,7 @@ function JM(e) {
34185
34191
  throw new Error("Schema version mismatch");
34186
34192
  return t;
34187
34193
  }
34188
- const eL = D(({
34194
+ const JM = D(({
34189
34195
  onSuccess: e,
34190
34196
  stretchModal: t,
34191
34197
  shrinkModal: r
@@ -34231,7 +34237,7 @@ const eL = D(({
34231
34237
  const P = new FileReader();
34232
34238
  P.readAsText(m, "UTF-8"), P.onload = ($) => {
34233
34239
  try {
34234
- const V = JM($);
34240
+ const V = ZM($);
34235
34241
  l("content", V), u("content");
34236
34242
  } catch (V) {
34237
34243
  console.error(V), d("content", {
@@ -34267,7 +34273,7 @@ const eL = D(({
34267
34273
  }, children: x == null ? void 0 : x.version })
34268
34274
  ] })
34269
34275
  ] }) }) : /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
34270
- /* @__PURE__ */ n.jsx(ZM, { content: x }),
34276
+ /* @__PURE__ */ n.jsx(XM, { content: x }),
34271
34277
  /* @__PURE__ */ n.jsx(b, { justify: "flex-end", my: "md", children: /* @__PURE__ */ n.jsx(L, { type: "submit", color: "green", disabled: _, children: i("common.actions.confirm") }) })
34272
34278
  ] })
34273
34279
  ] }) });
@@ -34277,7 +34283,7 @@ const eL = D(({
34277
34283
  borderTop: "none",
34278
34284
  borderRight: "1px solid #e9ecef",
34279
34285
  borderBottom: "1px solid #e9ecef"
34280
- }, tL = D(() => {
34286
+ }, eL = D(() => {
34281
34287
  var d;
34282
34288
  const {
34283
34289
  t: e
@@ -34298,10 +34304,10 @@ const eL = D(({
34298
34304
  }, children: e("import.label") }),
34299
34305
  /* @__PURE__ */ n.jsx(Ge, { opened: t, onClose: i, title: e("import.title"), trapFocus: !0, onDragStart: (u) => {
34300
34306
  u.stopPropagation();
34301
- }, withinPortal: !0, zIndex: 320, size: a ? "90vw" : 500, children: /* @__PURE__ */ n.jsx(eL, { onSuccess: i, stretchModal: s, shrinkModal: o }) })
34307
+ }, withinPortal: !0, zIndex: 320, size: a ? "90vw" : 500, children: /* @__PURE__ */ n.jsx(JM, { onSuccess: i, stretchModal: s, shrinkModal: o }) })
34302
34308
  ] });
34303
34309
  });
34304
- const nL = ({
34310
+ const tL = ({
34305
34311
  iconKey: e,
34306
34312
  ...t
34307
34313
  }) => {
@@ -34323,7 +34329,7 @@ const nL = ({
34323
34329
  default:
34324
34330
  return null;
34325
34331
  }
34326
- }, rL = ({
34332
+ }, nL = ({
34327
34333
  action: e
34328
34334
  }) => {
34329
34335
  const {
@@ -34333,7 +34339,7 @@ const nL = ({
34333
34339
  /* @__PURE__ */ n.jsx(S, { c: "dimmed", size: "xs", children: t(e.viz.displayName) }),
34334
34340
  /* @__PURE__ */ n.jsx(S, { c: "dimmed", size: "xs", className: "spotlight-action-viz-group", children: t(e.viz.displayGroup) })
34335
34341
  ] }) : null;
34336
- }, iL = D(({
34342
+ }, rL = D(({
34337
34343
  action: e,
34338
34344
  query: t
34339
34345
  }) => {
@@ -34341,23 +34347,23 @@ const nL = ({
34341
34347
  t: r
34342
34348
  } = y();
34343
34349
  return /* @__PURE__ */ n.jsx(R, { className: "spotlight-custom-action-component", children: /* @__PURE__ */ n.jsxs(b, { wrap: "nowrap", children: [
34344
- /* @__PURE__ */ n.jsx(nL, { iconKey: e.iconKey, size: 14 }),
34350
+ /* @__PURE__ */ n.jsx(tL, { iconKey: e.iconKey, size: 14 }),
34345
34351
  /* @__PURE__ */ n.jsxs("div", { style: {
34346
34352
  flex: 1
34347
34353
  }, children: [
34348
34354
  /* @__PURE__ */ n.jsx(tf, { highlight: t, size: "sm", children: e.title ? r(e.title) : "" }),
34349
- /* @__PURE__ */ n.jsx(rL, { action: e })
34355
+ /* @__PURE__ */ n.jsx(nL, { action: e })
34350
34356
  ] })
34351
34357
  ] }) });
34352
- }), aL = ({
34358
+ }), iL = ({
34353
34359
  groups: e,
34354
34360
  query: t
34355
34361
  }) => {
34356
34362
  const {
34357
34363
  t: r
34358
34364
  } = y();
34359
- return e.length === 0 ? /* @__PURE__ */ n.jsx(Nr.Empty, { children: r("spotlight.not_found") }) : /* @__PURE__ */ n.jsx(n.Fragment, { children: e.map((i) => /* @__PURE__ */ n.jsx(Nr.ActionsGroup, { label: i.group, children: i.actions.map((a) => /* @__PURE__ */ n.jsx(Nr.Action, { onClick: a.onClick, children: /* @__PURE__ */ n.jsx(iL, { action: a, query: t }) }, a.id)) }, i.group)) });
34360
- }, sL = D(() => {
34365
+ return e.length === 0 ? /* @__PURE__ */ n.jsx(Nr.Empty, { children: r("spotlight.not_found") }) : /* @__PURE__ */ n.jsx(n.Fragment, { children: e.map((i) => /* @__PURE__ */ n.jsx(Nr.ActionsGroup, { label: i.group, children: i.actions.map((a) => /* @__PURE__ */ n.jsx(Nr.Action, { onClick: a.onClick, children: /* @__PURE__ */ n.jsx(rL, { action: a, query: t }) }, a.id)) }, i.group)) });
34366
+ }, aL = D(() => {
34361
34367
  const {
34362
34368
  t: e,
34363
34369
  i18n: t
@@ -34405,7 +34411,7 @@ const nL = ({
34405
34411
  }
34406
34412
  }, children: [
34407
34413
  /* @__PURE__ */ n.jsx(Nr.Search, { placeholder: e("spotlight.placeholder"), leftSection: /* @__PURE__ */ n.jsx(Su, { size: "1.2rem" }) }),
34408
- /* @__PURE__ */ n.jsx(Nr.ActionsList, { children: /* @__PURE__ */ n.jsx(aL, { groups: l, query: a }) })
34414
+ /* @__PURE__ */ n.jsx(Nr.ActionsList, { children: /* @__PURE__ */ n.jsx(iL, { groups: l, query: a }) })
34409
34415
  ] });
34410
34416
  }), Fd = ({
34411
34417
  children: e
@@ -34417,7 +34423,7 @@ const nL = ({
34417
34423
  }, children: e }), Nd = function() {
34418
34424
  var t;
34419
34425
  return (((t = navigator.userAgentData) == null ? void 0 : t.platform) ?? navigator.platform).toLowerCase().includes("mac");
34420
- }(), oL = () => {
34426
+ }(), sL = () => {
34421
34427
  const {
34422
34428
  t: e
34423
34429
  } = y();
@@ -34447,7 +34453,7 @@ const nL = ({
34447
34453
  lineHeight: 1
34448
34454
  }, children: e("spotlight.trigger_text") })
34449
34455
  ] }) }) });
34450
- }, lL = {
34456
+ }, oL = {
34451
34457
  position: "fixed",
34452
34458
  top: 60,
34453
34459
  // height of mantine-header
@@ -34457,7 +34463,7 @@ const nL = ({
34457
34463
  zIndex: 299,
34458
34464
  borderBottom: "1px solid #e9ecef",
34459
34465
  background: "rgba(233,236,239, 0.15)"
34460
- }, cL = D(() => /* @__PURE__ */ n.jsx(R, { sx: lL, pl: {
34466
+ }, lL = D(() => /* @__PURE__ */ n.jsx(R, { sx: oL, pl: {
34461
34467
  base: 200,
34462
34468
  xs: 200,
34463
34469
  sm: 200,
@@ -34468,17 +34474,17 @@ const nL = ({
34468
34474
  height: "30px"
34469
34475
  }, children: [
34470
34476
  /* @__PURE__ */ n.jsxs(b, { justify: "flex-start", gap: 0, children: [
34471
- /* @__PURE__ */ n.jsx(qM, {}),
34472
- /* @__PURE__ */ n.jsx(tL, {}),
34473
- /* @__PURE__ */ n.jsx(oL, {})
34477
+ /* @__PURE__ */ n.jsx(NM, {}),
34478
+ /* @__PURE__ */ n.jsx(eL, {}),
34479
+ /* @__PURE__ */ n.jsx(sL, {})
34474
34480
  ] }),
34475
- /* @__PURE__ */ n.jsx(HM, {}),
34476
- /* @__PURE__ */ n.jsx(b, { justify: "flex-end", gap: 0, children: /* @__PURE__ */ n.jsx(QM, {}) })
34477
- ] }) })), dL = D((e) => /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
34478
- /* @__PURE__ */ n.jsx(NM, { ...e }),
34479
- /* @__PURE__ */ n.jsx(cL, {})
34481
+ /* @__PURE__ */ n.jsx(BM, {}),
34482
+ /* @__PURE__ */ n.jsx(b, { justify: "flex-end", gap: 0, children: /* @__PURE__ */ n.jsx(HM, {}) })
34483
+ ] }) })), cL = D((e) => /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
34484
+ /* @__PURE__ */ n.jsx(FM, { ...e }),
34485
+ /* @__PURE__ */ n.jsx(lL, {})
34480
34486
  ] }));
34481
- function uL(e, t, r) {
34487
+ function dL(e, t, r) {
34482
34488
  const i = [];
34483
34489
  return e.filter((a) => "__INTERACTIONS" in a.viz.conf).forEach((a, s) => {
34484
34490
  const o = t[a.id];
@@ -34540,21 +34546,21 @@ function uL(e, t, r) {
34540
34546
  });
34541
34547
  }), i;
34542
34548
  }
34543
- function hL(e, t) {
34549
+ function uL(e, t) {
34544
34550
  const r = e.filters.keyLabelMap;
34545
34551
  return {
34546
- edges: uL(e.panels.list, t, r),
34552
+ edges: dL(e.panels.list, t, r),
34547
34553
  edgeNodes: []
34548
34554
  };
34549
34555
  }
34550
34556
  function lg(e, t, r) {
34551
34557
  return e * t + e * r;
34552
34558
  }
34553
- function pL(e, t, r) {
34559
+ function hL(e, t, r) {
34554
34560
  return e * t + (e - 1) * r;
34555
34561
  }
34556
- const Ea = 25, ac = 40, cg = 25, sc = 350, mL = 150, xL = 150, dg = 150, qd = 300, ha = 40, ug = 25, gL = 300;
34557
- function fL(e, t) {
34562
+ const Ea = 25, ac = 40, cg = 25, sc = 350, pL = 150, mL = 150, dg = 150, qd = 300, ha = 40, ug = 25, xL = 300;
34563
+ function gL(e, t) {
34558
34564
  const r = w.keyBy(t, (a) => a.id), i = [];
34559
34565
  return e.current.forEach((a, s) => {
34560
34566
  a.panelIDs.forEach((o, l) => {
@@ -34602,14 +34608,14 @@ function fL(e, t) {
34602
34608
  });
34603
34609
  }), i;
34604
34610
  }
34605
- const bL = {
34611
+ const fL = {
34606
34612
  [J.Division]: "Div",
34607
34613
  [J.Modal]: "Modal",
34608
34614
  [J.Tabs]: "Tabs"
34609
- }, yL = X8;
34610
- function _L(e) {
34615
+ }, bL = X8;
34616
+ function yL(e) {
34611
34617
  return e.current.map((r, i) => {
34612
- const a = pL(r.panelIDs.length, ha, ug) + ac + cg;
34618
+ const a = hL(r.panelIDs.length, ha, ug) + ac + cg;
34613
34619
  let s = [];
34614
34620
  return r.type === J.Tabs && (s = r.config.tabsInOrder.map((l) => l.view_id)), {
34615
34621
  id: r.id,
@@ -34619,7 +34625,7 @@ function _L(e) {
34619
34625
  _sub_view_ids: [],
34620
34626
  _tab_view_ids: s,
34621
34627
  data: {
34622
- label: `${bL[r.type]}:${r.name}`
34628
+ label: `${fL[r.type]}:${r.name}`
34623
34629
  },
34624
34630
  position: {
34625
34631
  x: 0,
@@ -34629,14 +34635,14 @@ function _L(e) {
34629
34635
  targetPosition: pn.Left,
34630
34636
  className: "light",
34631
34637
  style: {
34632
- backgroundColor: yL[r.type],
34638
+ backgroundColor: bL[r.type],
34633
34639
  width: sc,
34634
34640
  height: a
34635
34641
  }
34636
34642
  };
34637
34643
  });
34638
34644
  }
34639
- function vL(e) {
34645
+ function _L(e) {
34640
34646
  const t = w.keyBy(e, (r) => r.id);
34641
34647
  e.forEach((r) => {
34642
34648
  r._node_type !== "view-root" || r._view_type !== J.Tabs || r._tab_view_ids.forEach((i) => {
@@ -34644,13 +34650,13 @@ function vL(e) {
34644
34650
  });
34645
34651
  });
34646
34652
  }
34647
- function jL(e) {
34648
- const t = _L(e.views);
34649
- vL(t);
34650
- const r = fL(e.views, e.panels.list);
34653
+ function vL(e) {
34654
+ const t = yL(e.views);
34655
+ _L(t);
34656
+ const r = gL(e.views, e.panels.list);
34651
34657
  return [...t, ...r];
34652
34658
  }
34653
- function wL({
34659
+ function jL({
34654
34660
  nodeMap: e,
34655
34661
  nodes: t,
34656
34662
  edges: r
@@ -34664,7 +34670,7 @@ function wL({
34664
34670
  }, ac));
34665
34671
  });
34666
34672
  }
34667
- function SL({
34673
+ function wL({
34668
34674
  nodeMap: e,
34669
34675
  nodes: t,
34670
34676
  edges: r
@@ -34677,7 +34683,7 @@ function SL({
34677
34683
  o._node_type !== "view-root" || s._node_type !== "view-root" || (s._view_level += 1 + o._view_level, o._sub_view_ids.push(s.id));
34678
34684
  }), t.sort((i, a) => i._node_type === "view-root" && a._node_type === "view-root" ? i._view_level - a._view_level : i._node_type !== "view-root" && a._node_type !== "view-root" ? 0 : i._node_type === "view-root" ? -1 : 1);
34679
34685
  }
34680
- function CL({
34686
+ function SL({
34681
34687
  nodeMap: e,
34682
34688
  nodes: t,
34683
34689
  edges: r
@@ -34689,13 +34695,13 @@ function CL({
34689
34695
  const s = e[a.source], o = e[a.target];
34690
34696
  if (s && o && s.parentNode) {
34691
34697
  const l = e[s.parentNode], c = l.position.x, d = Number(w.get(o, "style.height", 0)), u = Number(l.style.width);
34692
- o.position.x = c + u + gL, l._view_level === 0 && o._sub_view_ids.length === 0 && (s.sourcePosition = pn.Left, o.targetPosition = pn.Right, o.position.x *= -1);
34698
+ o.position.x = c + u + xL, l._view_level === 0 && o._sub_view_ids.length === 0 && (s.sourcePosition = pn.Left, o.targetPosition = pn.Right, o.position.x *= -1);
34693
34699
  const m = o.position.x, g = w.get(i, m, 0);
34694
34700
  o.position.y = g, i[m] = g + d + dg;
34695
34701
  }
34696
34702
  });
34697
34703
  }
34698
- function kL({
34704
+ function CL({
34699
34705
  nodeMap: e,
34700
34706
  nodes: t,
34701
34707
  edges: r
@@ -34704,10 +34710,10 @@ function kL({
34704
34710
  r.forEach((o) => {
34705
34711
  i.add(o.source), a.add(o.target);
34706
34712
  }), t.filter((o) => o._node_type !== "view-root" || o.id === "Main" || o.parentNode ? !1 : !i.has(o.id) && !a.has(o.id)).forEach((o, l) => {
34707
- o.position.x = lg(l, sc, xL), o.position.y = 0 - mL - dg;
34713
+ o.position.x = lg(l, sc, mL), o.position.y = 0 - pL - dg;
34708
34714
  });
34709
34715
  }
34710
- function TL({
34716
+ function kL({
34711
34717
  nodeMap: e,
34712
34718
  nodes: t,
34713
34719
  edges: r
@@ -34717,28 +34723,28 @@ function TL({
34717
34723
  nodes: t,
34718
34724
  edges: r
34719
34725
  };
34720
- return kL(i), SL(i), wL(i), CL(i), {
34726
+ return CL(i), wL(i), jL(i), SL(i), {
34721
34727
  nodes: t,
34722
34728
  edges: r
34723
34729
  };
34724
34730
  }
34725
- function zL(e) {
34726
- const t = jL(e), r = w.keyBy(t, (c) => c.id), {
34731
+ function TL(e) {
34732
+ const t = vL(e), r = w.keyBy(t, (c) => c.id), {
34727
34733
  edges: i,
34728
34734
  edgeNodes: a
34729
- } = hL(e, r), s = [...t, ...a], o = w.keyBy(s, (c) => c.id), l = {
34735
+ } = uL(e, r), s = [...t, ...a], o = w.keyBy(s, (c) => c.id), l = {
34730
34736
  edges: w.uniqBy(i, (c) => c.id),
34731
34737
  nodes: s,
34732
34738
  nodeMap: o
34733
34739
  };
34734
- return TL(l);
34740
+ return kL(l);
34735
34741
  }
34736
34742
  const Ls = {
34737
34743
  "builtin:op:open-link": /* @__PURE__ */ n.jsx(sa, { color: "blue", size: 20, radius: "xl", children: /* @__PURE__ */ n.jsx(Wf, { size: 14 }) }),
34738
34744
  "builtin:op:set_filter_values": /* @__PURE__ */ n.jsx(sa, { color: "orange", size: 20, radius: "xl", children: /* @__PURE__ */ n.jsx(Uf, { size: 14 }) }),
34739
34745
  "builtin:op:clear_filter_values": /* @__PURE__ */ n.jsx(sa, { color: "orange", size: 20, radius: "xl", children: /* @__PURE__ */ n.jsx(bu, { size: 14 }) })
34740
34746
  };
34741
- function DL(e) {
34747
+ function zL(e) {
34742
34748
  const t = [];
34743
34749
  return e.forEach((r) => {
34744
34750
  switch (r.schemaRef) {
@@ -34785,14 +34791,14 @@ function DL(e) {
34785
34791
  }
34786
34792
  }), t;
34787
34793
  }
34788
- const IL = Ug(({
34794
+ const DL = Ug(({
34789
34795
  data: e,
34790
34796
  isConnectable: t,
34791
34797
  sourcePosition: r = pn.Right,
34792
34798
  targetPosition: i = pn.Left,
34793
34799
  ...a
34794
34800
  }) => {
34795
- const s = z(() => DL(e.interactions), [e.interactions]);
34801
+ const s = z(() => zL(e.interactions), [e.interactions]);
34796
34802
  return /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
34797
34803
  /* @__PURE__ */ n.jsx(Mc, { type: "target", position: i, isConnectable: t }),
34798
34804
  /* @__PURE__ */ n.jsx(R, { sx: {
@@ -34807,19 +34813,19 @@ const IL = Ug(({
34807
34813
  /* @__PURE__ */ n.jsx(Mc, { type: "source", position: r, isConnectable: t })
34808
34814
  ] });
34809
34815
  });
34810
- const ML = {
34811
- interaction: IL
34812
- }, LL = D(() => {
34816
+ const IL = {
34817
+ interaction: DL
34818
+ }, ML = D(() => {
34813
34819
  const e = Je(), {
34814
34820
  edges: t,
34815
34821
  nodes: r
34816
- } = zL(e);
34817
- return /* @__PURE__ */ n.jsxs(Py, { nodes: r, edges: t, onNodesChange: w.noop, onEdgesChange: w.noop, onConnect: w.noop, className: "interactions-viewer", fitView: !0, nodeTypes: ML, children: [
34822
+ } = TL(e);
34823
+ return /* @__PURE__ */ n.jsxs(Py, { nodes: r, edges: t, onNodesChange: w.noop, onEdgesChange: w.noop, onConnect: w.noop, className: "interactions-viewer", fitView: !0, nodeTypes: IL, children: [
34818
34824
  /* @__PURE__ */ n.jsx(Ey, {}),
34819
34825
  /* @__PURE__ */ n.jsx(Ry, {}),
34820
34826
  /* @__PURE__ */ n.jsx($y, {})
34821
34827
  ] });
34822
- }), PL = D(({
34828
+ }), LL = D(({
34823
34829
  opened: e,
34824
34830
  close: t
34825
34831
  }) => {
@@ -34846,10 +34852,10 @@ const ML = {
34846
34852
  }
34847
34853
  },
34848
34854
  zIndex: 300,
34849
- children: /* @__PURE__ */ n.jsx(LL, {})
34855
+ children: /* @__PURE__ */ n.jsx(ML, {})
34850
34856
  }
34851
34857
  );
34852
- }), EL = {
34858
+ }), PL = {
34853
34859
  "> button": {
34854
34860
  "&:first-of-type": {
34855
34861
  borderTopRightRadius: 0,
@@ -34871,7 +34877,7 @@ const ML = {
34871
34877
  }
34872
34878
  }
34873
34879
  };
34874
- function RL({
34880
+ function EL({
34875
34881
  onClick: e,
34876
34882
  name: t,
34877
34883
  active: r,
@@ -34905,7 +34911,7 @@ function RL({
34905
34911
  }, children: /* @__PURE__ */ n.jsx(Kf, { size: 16 }) }) })
34906
34912
  ] });
34907
34913
  }
34908
- const $L = D(() => {
34914
+ const RL = D(() => {
34909
34915
  const {
34910
34916
  t: e
34911
34917
  } = y(), t = we(), r = je(), i = fe((s) => () => r.views.setIDOfVIE(s), [r]), a = (s) => {
@@ -34914,7 +34920,7 @@ const $L = D(() => {
34914
34920
  return /* @__PURE__ */ n.jsxs(R, { sx: {
34915
34921
  position: "relative"
34916
34922
  }, children: [
34917
- r.views.options.map((s) => /* @__PURE__ */ n.jsx(RL, { active: r.views.idOfVIE === s.value, name: s.label, onClick: i(s.value), openSettings: () => a(s.value) }, s.value)),
34923
+ r.views.options.map((s) => /* @__PURE__ */ n.jsx(EL, { active: r.views.idOfVIE === s.value, name: s.label, onClick: i(s.value), openSettings: () => a(s.value) }, s.value)),
34918
34924
  /* @__PURE__ */ n.jsx(A, { variant: "dashed" }),
34919
34925
  /* @__PURE__ */ n.jsx(L, { variant: "subtle", rightSection: /* @__PURE__ */ n.jsx(rn, { size: 14 }), size: "sm", px: "xs", color: "blue", onClick: r.views.addARandomNewView, sx: {
34920
34926
  width: "100%",
@@ -34925,7 +34931,7 @@ const $L = D(() => {
34925
34931
  }
34926
34932
  }, children: e("view.add") })
34927
34933
  ] });
34928
- }), AL = D(() => {
34934
+ }), $L = D(() => {
34929
34935
  const {
34930
34936
  t: e
34931
34937
  } = y(), t = we(), r = je(), i = () => {
@@ -34944,7 +34950,7 @@ const $L = D(() => {
34944
34950
  return /* @__PURE__ */ n.jsxs($t.Navbar, { p: 0, zIndex: 299, children: [
34945
34951
  /* @__PURE__ */ n.jsxs($t.Section, { children: [
34946
34952
  /* @__PURE__ */ n.jsxs(b, { grow: !0, gap: 0, sx: {
34947
- ...EL,
34953
+ ...PL,
34948
34954
  button: {
34949
34955
  borderWidth: 0,
34950
34956
  borderBottomWidth: 1,
@@ -34961,7 +34967,7 @@ const $L = D(() => {
34961
34967
  height: "30px"
34962
34968
  }, onClick: l, children: /* @__PURE__ */ n.jsx(jo, { size: 18 }) }) })
34963
34969
  ] }),
34964
- /* @__PURE__ */ n.jsx(PL, { opened: s, close: c })
34970
+ /* @__PURE__ */ n.jsx(LL, { opened: s, close: c })
34965
34971
  ] }),
34966
34972
  /* @__PURE__ */ n.jsx($t.Section, { py: 5, sx: {
34967
34973
  borderBottom: "1px solid #eee"
@@ -34971,12 +34977,12 @@ const $L = D(() => {
34971
34977
  }, children: e("view.labels") }) }),
34972
34978
  /* @__PURE__ */ n.jsx($t.Section, { grow: !0, sx: {
34973
34979
  overflow: "auto"
34974
- }, children: /* @__PURE__ */ n.jsx($L, {}) }),
34980
+ }, children: /* @__PURE__ */ n.jsx(RL, {}) }),
34975
34981
  /* @__PURE__ */ n.jsx($t.Section, { children: /* @__PURE__ */ n.jsx(b, { grow: !0, p: "md", pt: "sm", sx: {
34976
34982
  borderTop: "1px solid #eee"
34977
34983
  }, children: /* @__PURE__ */ n.jsx(L, { size: "xs", leftSection: /* @__PURE__ */ n.jsx(Zr, { size: 20 }), onClick: () => t.editor.open([]), children: e("common.titles.settings") }) }) })
34978
34984
  ] });
34979
- }), OL = D(({
34985
+ }), AL = D(({
34980
34986
  filter: e
34981
34987
  }) => {
34982
34988
  const {
@@ -34994,7 +35000,7 @@ const $L = D(() => {
34994
35000
  }
34995
35001
  } }, e.id)
34996
35002
  ] });
34997
- }), VL = [{
35003
+ }), OL = [{
34998
35004
  label: "2022",
34999
35005
  value: "YYYY"
35000
35006
  }, {
@@ -35009,7 +35015,7 @@ const $L = D(() => {
35009
35015
  }, {
35010
35016
  label: "2022-01-01",
35011
35017
  value: "YYYY-MM-DD"
35012
- }], FL = D(function({
35018
+ }], VL = D(function({
35013
35019
  filter: t
35014
35020
  }) {
35015
35021
  const {
@@ -35033,7 +35039,7 @@ const $L = D(() => {
35033
35039
  /* @__PURE__ */ n.jsx(he, { checked: i.allowSingleDateInRange, onChange: (o) => i.setAllowSingleDateInRange(o.currentTarget.checked), label: r("filter.widget.date_range.allow_single_date") })
35034
35040
  ] }),
35035
35041
  /* @__PURE__ */ n.jsxs(b, { grow: !0, children: [
35036
- /* @__PURE__ */ n.jsx(N, { data: VL, label: r("filter.widget.date_range.display_format"), value: i.inputFormat, onChange: i.setInputFormat }),
35042
+ /* @__PURE__ */ n.jsx(N, { data: OL, label: r("filter.widget.date_range.display_format"), value: i.inputFormat, onChange: i.setInputFormat }),
35037
35043
  /* @__PURE__ */ n.jsx(ce, { label: r("filter.widget.date_range.max_days"), min: 0, value: i.max_days, onChange: i.setMaxDays, hideControls: !0 })
35038
35044
  ] }),
35039
35045
  /* @__PURE__ */ n.jsxs(b, { children: [
@@ -35047,7 +35053,7 @@ const $L = D(() => {
35047
35053
  ] }),
35048
35054
  /* @__PURE__ */ n.jsx(Lr, { filter: t })
35049
35055
  ] });
35050
- }), NL = `
35056
+ }), FL = `
35051
35057
  // row
35052
35058
  {
35053
35059
  label: string;
@@ -35060,9 +35066,9 @@ const $L = D(() => {
35060
35066
  } = y(), [t, r] = K(!1);
35061
35067
  return /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
35062
35068
  /* @__PURE__ */ n.jsx(L, { variant: "subtle", size: "compact-sm", onClick: () => r((i) => !i), children: e(t ? "common.actions.close" : "filter.widget.common.see_data_structure") }),
35063
- /* @__PURE__ */ n.jsx(Ei, { in: t, children: /* @__PURE__ */ n.jsx(xn, { language: "typescript", withCopyButton: !1, code: NL }) })
35069
+ /* @__PURE__ */ n.jsx(Ei, { in: t, children: /* @__PURE__ */ n.jsx(xn, { language: "typescript", withCopyButton: !1, code: FL }) })
35064
35070
  ] });
35065
- }, qL = D(function({
35071
+ }, NL = D(function({
35066
35072
  filter: t
35067
35073
  }) {
35068
35074
  const {
@@ -35194,7 +35200,7 @@ const $L = D(() => {
35194
35200
  /* @__PURE__ */ n.jsx(L, { size: "xs", color: "blue", leftSection: /* @__PURE__ */ n.jsx(Di, { size: 20 }), onClick: i, children: t("common.actions.add_an_option") }),
35195
35201
  /* @__PURE__ */ n.jsx(N, { placeholder: t("filter.widget.select.preset_options.apply"), value: null, onChange: s, data: a, size: "xs" })
35196
35202
  ] });
35197
- }), BL = D(({
35203
+ }), qL = D(({
35198
35204
  config: e
35199
35205
  }) => {
35200
35206
  const {
@@ -35227,7 +35233,7 @@ const $L = D(() => {
35227
35233
  ] }, o)),
35228
35234
  /* @__PURE__ */ n.jsx(Hd, { config: e })
35229
35235
  ] });
35230
- }), HL = D(({
35236
+ }), BL = D(({
35231
35237
  filter: e
35232
35238
  }) => {
35233
35239
  const {
@@ -35261,14 +35267,14 @@ const $L = D(() => {
35261
35267
  width: "100%"
35262
35268
  }, children: /* @__PURE__ */ n.jsx(S, { c: "white", size: "16px", children: t("filter.widget.common.using_query") }) })
35263
35269
  ] }),
35264
- /* @__PURE__ */ n.jsx(BL, { config: r })
35270
+ /* @__PURE__ */ n.jsx(qL, { config: r })
35265
35271
  ] }),
35266
35272
  /* @__PURE__ */ n.jsx(A, { label: t("filter.widget.common.or_fetch_options_from_datasource"), labelPosition: "center" }),
35267
35273
  /* @__PURE__ */ n.jsx(he, { checked: r.default_selection_count === 1, onChange: (i) => r.setDefaultSelectionCount(i.currentTarget.checked ? 1 : 0), label: t("filter.widget.select.select_first_option_by_default") }),
35268
35274
  /* @__PURE__ */ n.jsx(us, { value: r.options_query_id, onChange: r.setOptionsQueryID }),
35269
35275
  /* @__PURE__ */ n.jsx(hg, {})
35270
35276
  ] });
35271
- }), QL = D(function({
35277
+ }), HL = D(function({
35272
35278
  filter: t
35273
35279
  }) {
35274
35280
  const {
@@ -35285,7 +35291,7 @@ const $L = D(() => {
35285
35291
  ] }),
35286
35292
  /* @__PURE__ */ n.jsx(he, { checked: i.required, onChange: (a) => i.setRequired(a.currentTarget.checked), label: r("filter.widget.text_input.required") })
35287
35293
  ] });
35288
- }), GL = D(function({
35294
+ }), QL = D(function({
35289
35295
  filter: t
35290
35296
  }) {
35291
35297
  const {
@@ -35297,14 +35303,14 @@ const $L = D(() => {
35297
35303
  /* @__PURE__ */ n.jsx(S, { pt: "0", pb: "md", c: "gray", size: "sm", children: r("common.titles.config") }),
35298
35304
  /* @__PURE__ */ n.jsx(xn, { mt: 22, language: "json", withCopyButton: !1, code: JSON.stringify(t, null, 4) })
35299
35305
  ] });
35300
- }), WL = {
35301
- [ee.Select]: HL,
35302
- [ee.MultiSelect]: qL,
35306
+ }), GL = {
35307
+ [ee.Select]: BL,
35308
+ [ee.MultiSelect]: NL,
35303
35309
  [ee.TreeSelect]: pI,
35304
35310
  [ee.TreeSingleSelect]: yI,
35305
- [ee.TextInput]: QL,
35306
- [ee.Checkbox]: OL,
35307
- [ee.DateRange]: FL
35311
+ [ee.TextInput]: HL,
35312
+ [ee.Checkbox]: AL,
35313
+ [ee.DateRange]: VL
35308
35314
  }, $n = {
35309
35315
  [ee.Select]: "filter.widget.names.select",
35310
35316
  [ee.MultiSelect]: "filter.widget.names.multi_select",
@@ -35313,13 +35319,13 @@ const $L = D(() => {
35313
35319
  [ee.TextInput]: "filter.widget.names.text_input",
35314
35320
  [ee.Checkbox]: "filter.widget.names.checkbox",
35315
35321
  [ee.DateRange]: "filter.widget.names.date_range"
35316
- }, UL = D(function({
35322
+ }, WL = D(function({
35317
35323
  filter: t
35318
35324
  }) {
35319
35325
  const {
35320
35326
  t: r,
35321
35327
  i18n: i
35322
- } = y(), a = je(), s = B.useMemo(() => WL[t.type], [t.type]), o = z(() => [{
35328
+ } = y(), a = je(), s = B.useMemo(() => GL[t.type], [t.type]), o = z(() => [{
35323
35329
  label: r($n[ee.Select]),
35324
35330
  value: "select"
35325
35331
  }, {
@@ -35365,9 +35371,9 @@ const $L = D(() => {
35365
35371
  /* @__PURE__ */ n.jsx(s, { filter: t })
35366
35372
  ] })
35367
35373
  ] }),
35368
- /* @__PURE__ */ n.jsx(GL, { filter: t })
35374
+ /* @__PURE__ */ n.jsx(QL, { filter: t })
35369
35375
  ] });
35370
- }), YL = D(({
35376
+ }), UL = D(({
35371
35377
  id: e
35372
35378
  }) => {
35373
35379
  const {
@@ -35410,9 +35416,9 @@ const $L = D(() => {
35410
35416
  flexGrow: 1,
35411
35417
  maxHeight: "calc(100% - 52px)",
35412
35418
  overflow: "auto"
35413
- }, children: /* @__PURE__ */ n.jsx(UL, { filter: s }) })
35419
+ }, children: /* @__PURE__ */ n.jsx(WL, { filter: s }) })
35414
35420
  ] });
35415
- }), KL = D(() => {
35421
+ }), YL = D(() => {
35416
35422
  const {
35417
35423
  t: e
35418
35424
  } = y(), [t, r] = K([]), i = we(), a = (d) => {
@@ -35485,7 +35491,7 @@ const $L = D(() => {
35485
35491
  ] }, d.id)) })
35486
35492
  ] }) }) })
35487
35493
  ] });
35488
- }), XL = D(() => {
35494
+ }), KL = D(() => {
35489
35495
  const {
35490
35496
  t: e
35491
35497
  } = y(), t = je(), [r, i] = K(() => JSON.stringify(t.mock_context.current, null, 4)), a = () => {
@@ -35534,7 +35540,7 @@ const $L = D(() => {
35534
35540
  } })
35535
35541
  ] }) })
35536
35542
  ] });
35537
- }), ZL = D(() => {
35543
+ }), XL = D(() => {
35538
35544
  const {
35539
35545
  t: e
35540
35546
  } = y(), {
@@ -35545,7 +35551,7 @@ const $L = D(() => {
35545
35551
  flexGrow: 1
35546
35552
  }
35547
35553
  } }, t.id);
35548
- }), JL = D(() => {
35554
+ }), ZL = D(() => {
35549
35555
  const {
35550
35556
  t: e
35551
35557
  } = y(), {
@@ -35575,10 +35581,10 @@ const $L = D(() => {
35575
35581
  ] }),
35576
35582
  /* @__PURE__ */ n.jsx(he, { ml: 6, label: e("panel.style.border"), checked: i.border.enabled, onChange: (a) => i.border.setEnabled(a.currentTarget.checked) })
35577
35583
  ] }) });
35578
- }), e9 = () => /* @__PURE__ */ n.jsxs("span", { className: "mantine-103svbs mantine-InputWrapper-required mantine-Select-required", "aria-hidden": "true", children: [
35584
+ }), JL = () => /* @__PURE__ */ n.jsxs("span", { className: "mantine-103svbs mantine-InputWrapper-required mantine-Select-required", "aria-hidden": "true", children: [
35579
35585
  " ",
35580
35586
  "*"
35581
- ] }), t9 = D(() => {
35587
+ ] }), e9 = D(() => {
35582
35588
  const {
35583
35589
  t: e
35584
35590
  } = y(), {
@@ -35596,13 +35602,13 @@ const $L = D(() => {
35596
35602
  /* @__PURE__ */ n.jsxs(b, { align: "center", children: [
35597
35603
  /* @__PURE__ */ n.jsxs(S, { size: "14px", fw: 500, children: [
35598
35604
  e("panel.panel_name"),
35599
- /* @__PURE__ */ n.jsx(e9, {})
35605
+ /* @__PURE__ */ n.jsx(JL, {})
35600
35606
  ] }),
35601
35607
  /* @__PURE__ */ n.jsx(oe, { variant: "subtle", color: "blue", disabled: !s || l, onClick: o, children: /* @__PURE__ */ n.jsx(Oe, { size: 18 }) })
35602
35608
  ] }),
35603
35609
  /* @__PURE__ */ n.jsx(E, { value: i, onChange: a, required: !0 })
35604
35610
  ] });
35605
- }), n9 = D(() => {
35611
+ }), t9 = D(() => {
35606
35612
  const {
35607
35613
  t: e
35608
35614
  } = y(), {
@@ -35615,21 +35621,21 @@ const $L = D(() => {
35615
35621
  /* @__PURE__ */ n.jsx(he, { size: "sm", checked: !0, disabled: !0, label: e("panel.use_name_as_title") })
35616
35622
  ] }) });
35617
35623
  });
35618
- function r9() {
35624
+ function n9() {
35619
35625
  const {
35620
35626
  t: e
35621
35627
  } = y();
35622
35628
  return /* @__PURE__ */ n.jsxs(T, { sx: {
35623
35629
  height: "100%"
35624
35630
  }, children: [
35625
- /* @__PURE__ */ n.jsx(JL, {}),
35631
+ /* @__PURE__ */ n.jsx(ZL, {}),
35626
35632
  /* @__PURE__ */ n.jsx(A, { label: e("common.info"), labelPosition: "center", variant: "dashed" }),
35633
+ /* @__PURE__ */ n.jsx(e9, {}),
35627
35634
  /* @__PURE__ */ n.jsx(t9, {}),
35628
- /* @__PURE__ */ n.jsx(n9, {}),
35629
- /* @__PURE__ */ n.jsx(ZL, {})
35635
+ /* @__PURE__ */ n.jsx(XL, {})
35630
35636
  ] });
35631
35637
  }
35632
- const i9 = {
35638
+ const r9 = {
35633
35639
  width: "fit-content",
35634
35640
  minWidth: "100%",
35635
35641
  tableLayout: "fixed",
@@ -35684,7 +35690,7 @@ function pg({
35684
35690
  });
35685
35691
  return e.length === 0 ? /* @__PURE__ */ n.jsx(R, { sx: {
35686
35692
  height: "5em"
35687
- } }) : /* @__PURE__ */ n.jsx(Ze, { children: /* @__PURE__ */ n.jsxs(v, { sx: i9, children: [
35693
+ } }) : /* @__PURE__ */ n.jsx(Ze, { children: /* @__PURE__ */ n.jsxs(v, { sx: r9, children: [
35688
35694
  /* @__PURE__ */ n.jsx(v.Thead, { children: r.getHeaderGroups().map((i) => /* @__PURE__ */ n.jsx(v.Tr, { children: i.headers.map((a) => /* @__PURE__ */ n.jsxs(v.Th, { style: {
35689
35695
  width: a.getSize()
35690
35696
  }, children: [
@@ -35694,7 +35700,7 @@ function pg({
35694
35700
  /* @__PURE__ */ n.jsx(v.Tbody, { children: r.getRowModel().rows.map((i) => /* @__PURE__ */ n.jsx(v.Tr, { children: i.getVisibleCells().map((a) => /* @__PURE__ */ n.jsx(v.Td, { children: /* @__PURE__ */ n.jsx(Ze, { children: typeof a.getValue() == "object" ? /* @__PURE__ */ n.jsx("pre", { children: JSON.stringify(a.getValue(), null, 2) }) : Wr(a.column.columnDef.cell, a.getContext()) }) }, a.id)) }, i.id)) })
35695
35701
  ] }) });
35696
35702
  }
35697
- const a9 = [{
35703
+ const i9 = [{
35698
35704
  label: "10",
35699
35705
  value: "10"
35700
35706
  }, {
@@ -35706,7 +35712,7 @@ const a9 = [{
35706
35712
  }, {
35707
35713
  label: "100",
35708
35714
  value: "100"
35709
- }], s9 = {
35715
+ }], a9 = {
35710
35716
  icon: {
35711
35717
  width: "80px",
35712
35718
  textAlign: "center"
@@ -35716,7 +35722,7 @@ const a9 = [{
35716
35722
  paddingLeft: "80px"
35717
35723
  }
35718
35724
  }
35719
- }, o9 = ({
35725
+ }, s9 = ({
35720
35726
  data: e,
35721
35727
  page: t,
35722
35728
  setPage: r,
@@ -35743,8 +35749,8 @@ const a9 = [{
35743
35749
  {
35744
35750
  leftSection: /* @__PURE__ */ n.jsx(S, { ta: "center", c: "dimmed", size: "14px", children: s("common.pagination.page_size") }),
35745
35751
  size: "xs",
35746
- styles: s9,
35747
- data: a9,
35752
+ styles: a9,
35753
+ data: i9,
35748
35754
  value: String(i),
35749
35755
  onChange: c
35750
35756
  }
@@ -35754,7 +35760,7 @@ const a9 = [{
35754
35760
  total: o
35755
35761
  }) }) })
35756
35762
  ] });
35757
- }, l9 = am(({
35763
+ }, o9 = am(({
35758
35764
  data: e,
35759
35765
  loading: t
35760
35766
  }) => {
@@ -35763,7 +35769,7 @@ const a9 = [{
35763
35769
  return e.slice(l, c);
35764
35770
  }, [e, r, a]);
35765
35771
  return /* @__PURE__ */ n.jsxs(Ze, { children: [
35766
- /* @__PURE__ */ n.jsx(o9, { data: e, page: r, setPage: i, limit: a, setLimit: s }),
35772
+ /* @__PURE__ */ n.jsx(s9, { data: e, page: r, setPage: i, limit: a, setLimit: s }),
35767
35773
  /* @__PURE__ */ n.jsxs(R, { py: 10, sx: {
35768
35774
  width: "100%",
35769
35775
  height: "calc(100% - 42px)",
@@ -35776,7 +35782,7 @@ const a9 = [{
35776
35782
  /* @__PURE__ */ n.jsx(pg, { data: o })
35777
35783
  ] })
35778
35784
  ] });
35779
- }), c9 = D(({
35785
+ }), l9 = D(({
35780
35786
  queryID: e
35781
35787
  }) => {
35782
35788
  const t = Je(), r = B.useMemo(() => t.queries.findByID(e), [t, e]);
@@ -35827,11 +35833,11 @@ const a9 = [{
35827
35833
  flexGrow: 1,
35828
35834
  overflow: "auto"
35829
35835
  }, children: [
35830
- /* @__PURE__ */ n.jsx(c9, { queryID: e }),
35831
- /* @__PURE__ */ n.jsx(l9, { data: s, loading: l })
35836
+ /* @__PURE__ */ n.jsx(l9, { queryID: e }),
35837
+ /* @__PURE__ */ n.jsx(o9, { data: s, loading: l })
35832
35838
  ] })
35833
35839
  ] });
35834
- }), d9 = D(function() {
35840
+ }), c9 = D(function() {
35835
35841
  const {
35836
35842
  t
35837
35843
  } = y(), r = we(), i = je(), {
@@ -35850,14 +35856,14 @@ const a9 = [{
35850
35856
  ] })
35851
35857
  ] })
35852
35858
  ] });
35853
- }), u9 = D(() => {
35859
+ }), d9 = D(() => {
35854
35860
  const {
35855
35861
  panel: e
35856
35862
  } = Nt();
35857
35863
  return e.title.show ? /* @__PURE__ */ n.jsx(b, { grow: !0, justify: "center", className: "panel-title-wrapper", sx: {
35858
35864
  flexGrow: 1
35859
35865
  }, children: /* @__PURE__ */ n.jsx(S, { size: "sm", ta: "center", lineClamp: 1, className: "panel-title-text", children: e.title.show ? e.name : "" }) }) : null;
35860
- }), h9 = D(() => {
35866
+ }), u9 = D(() => {
35861
35867
  const {
35862
35868
  panel: e
35863
35869
  } = Nt();
@@ -35870,11 +35876,11 @@ const a9 = [{
35870
35876
  height: "450px !important"
35871
35877
  }, children: [
35872
35878
  /* @__PURE__ */ n.jsx(R, { className: "panel-description-popover-wrapper", children: /* @__PURE__ */ n.jsx(Gx, {}) }),
35873
- /* @__PURE__ */ n.jsx(u9, {}),
35879
+ /* @__PURE__ */ n.jsx(d9, {}),
35874
35880
  /* @__PURE__ */ n.jsx(Xx, { panel: e })
35875
35881
  ] }) });
35876
35882
  });
35877
- function p9() {
35883
+ function h9() {
35878
35884
  const {
35879
35885
  t: e
35880
35886
  } = y(), {
@@ -35891,7 +35897,7 @@ function p9() {
35891
35897
  };
35892
35898
  }), [t]);
35893
35899
  }
35894
- const m9 = D(({
35900
+ const p9 = D(({
35895
35901
  value: e,
35896
35902
  submit: t
35897
35903
  }) => {
@@ -35901,21 +35907,21 @@ const m9 = D(({
35901
35907
  H(() => {
35902
35908
  a(e);
35903
35909
  }, [e]);
35904
- const s = p9(), o = e !== i;
35910
+ const s = h9(), o = e !== i;
35905
35911
  return /* @__PURE__ */ n.jsx(N, { label: r("visualization.component"), value: i, searchable: !0, onChange: a, data: s, rightSection: /* @__PURE__ */ n.jsx(oe, { variant: "filled", color: "green", disabled: !o, onClick: () => t(i), styles: {
35906
35912
  root: {
35907
35913
  pointerEvents: "all"
35908
35914
  }
35909
35915
  }, children: /* @__PURE__ */ n.jsx(Oe, { size: 20 }) }), maxDropdownHeight: 600 });
35910
35916
  }), Qd = [];
35911
- function x9(e, t) {
35917
+ function m9(e, t) {
35912
35918
  try {
35913
35919
  return e.resolveComponent(t).createConfig();
35914
35920
  } catch {
35915
35921
  return null;
35916
35922
  }
35917
35923
  }
35918
- function g9() {
35924
+ function x9() {
35919
35925
  const {
35920
35926
  data: e,
35921
35927
  panel: {
@@ -35943,7 +35949,7 @@ function g9() {
35943
35949
  return console.info(be(h, "message")), null;
35944
35950
  }
35945
35951
  }
35946
- const f9 = D(() => {
35952
+ const g9 = D(() => {
35947
35953
  const {
35948
35954
  data: e,
35949
35955
  panel: {
@@ -35954,7 +35960,7 @@ const f9 = D(() => {
35954
35960
  } = sr(Un), i = B.useCallback((d) => {
35955
35961
  if (d === t.type)
35956
35962
  return;
35957
- const u = x9(r, d);
35963
+ const u = m9(r, d);
35958
35964
  t.setType(d), t.setConf(u || {});
35959
35965
  }, [t.type]), a = (d) => {
35960
35966
  try {
@@ -35965,7 +35971,7 @@ const f9 = D(() => {
35965
35971
  }, s = B.useMemo(() => {
35966
35972
  var d;
35967
35973
  return (d = Qd.find((u) => u.value === t.type)) == null ? void 0 : d.Panel;
35968
- }, [t.type, Qd]), o = g9(), l = s ? Kr(s, {
35974
+ }, [t.type, Qd]), o = x9(), l = s ? Kr(s, {
35969
35975
  data: e,
35970
35976
  conf: t.conf,
35971
35977
  setConf: t.setConf
@@ -35974,7 +35980,7 @@ const f9 = D(() => {
35974
35980
  height: "100%",
35975
35981
  overflow: "hidden"
35976
35982
  }, children: [
35977
- /* @__PURE__ */ n.jsx(m9, { submit: i, value: t.type }),
35983
+ /* @__PURE__ */ n.jsx(p9, { submit: i, value: t.type }),
35978
35984
  /* @__PURE__ */ n.jsxs(Ze, { children: [
35979
35985
  /* @__PURE__ */ n.jsx(T, { pb: 10, sx: {
35980
35986
  flexGrow: 1,
@@ -35984,7 +35990,7 @@ const f9 = D(() => {
35984
35990
  !c && /* @__PURE__ */ n.jsx(ru, { minRows: 20, label: "Config", value: JSON.stringify(t.conf, null, 2), onChange: a })
35985
35991
  ] })
35986
35992
  ] });
35987
- }), b9 = D(({
35993
+ }), f9 = D(({
35988
35994
  panel: e,
35989
35995
  sourceViewID: t
35990
35996
  }) => {
@@ -36020,7 +36026,7 @@ const f9 = D(() => {
36020
36026
  ] })
36021
36027
  ] }) })
36022
36028
  ] });
36023
- }), y9 = D(({
36029
+ }), b9 = D(({
36024
36030
  sx: e = {}
36025
36031
  }) => {
36026
36032
  const {
@@ -36070,7 +36076,7 @@ const f9 = D(() => {
36070
36076
  average: !1
36071
36077
  }
36072
36078
  };
36073
- class _9 {
36079
+ class y9 {
36074
36080
  constructor(t) {
36075
36081
  Y(this, "panel");
36076
36082
  Y(this, "selected");
@@ -36120,13 +36126,13 @@ class _9 {
36120
36126
  }
36121
36127
  }
36122
36128
  }
36123
- function v9() {
36129
+ function _9() {
36124
36130
  const {
36125
36131
  panel: e
36126
36132
  } = xt();
36127
- return mn(() => new _9(e), [e]);
36133
+ return mn(() => new y9(e), [e]);
36128
36134
  }
36129
- const j9 = B.forwardRef(function({
36135
+ const v9 = B.forwardRef(function({
36130
36136
  value: t,
36131
36137
  onChange: r,
36132
36138
  remove: i
@@ -36153,7 +36159,7 @@ const j9 = B.forwardRef(function({
36153
36159
  ] }),
36154
36160
  /* @__PURE__ */ n.jsx(L, { mt: 20, leftSection: /* @__PURE__ */ n.jsx(ht, { size: 16 }), color: "red", variant: "light", onClick: i, children: s("panel.variable.delete") })
36155
36161
  ] });
36156
- }), w9 = D((e) => {
36162
+ }), j9 = D((e) => {
36157
36163
  const {
36158
36164
  t
36159
36165
  } = y(), r = mn(() => HI(e.variable), [e.variable]), i = () => e.uiModel.remove(e.variable);
@@ -36162,7 +36168,7 @@ const j9 = B.forwardRef(function({
36162
36168
  /* @__PURE__ */ n.jsx(L, { variant: "subtle", size: "xs", disabled: !r.changed, color: "red", onClick: r.reset, leftSection: /* @__PURE__ */ n.jsx(nn, { size: 18 }), children: t("common.actions.revert_changes") }),
36163
36169
  /* @__PURE__ */ n.jsx(L, { variant: "filled", size: "xs", disabled: !r.changed, color: "green", onClick: r.commit, leftSection: /* @__PURE__ */ n.jsx(Oe, { size: 18 }), children: t("common.actions.save_changes") })
36164
36170
  ] }),
36165
- /* @__PURE__ */ n.jsx(j9, { value: Tn(r.copy), onChange: r.update, remove: i })
36171
+ /* @__PURE__ */ n.jsx(v9, { value: Tn(r.copy), onChange: r.update, remove: i })
36166
36172
  ] });
36167
36173
  });
36168
36174
  D((e) => {
@@ -36171,7 +36177,7 @@ D((e) => {
36171
36177
  } = e;
36172
36178
  return /* @__PURE__ */ n.jsx(T, { className: "var-list", children: t.variables.map((r) => /* @__PURE__ */ n.jsx(L, { variant: t.selected === r ? "filled" : "subtle", color: "gray", onClick: () => t.select(r), children: r.name }, r.name)) });
36173
36179
  });
36174
- const S9 = D(({
36180
+ const w9 = D(({
36175
36181
  model: e
36176
36182
  }) => {
36177
36183
  const {
@@ -36185,12 +36191,12 @@ const S9 = D(({
36185
36191
  alignSelf: "flex-end",
36186
36192
  height: "38px"
36187
36193
  }, children: t("panel.variable.add") }) });
36188
- }), C9 = D(() => {
36194
+ }), S9 = D(() => {
36189
36195
  var r;
36190
36196
  const {
36191
36197
  t: e
36192
- } = y(), t = v9();
36193
- return t.variableOptions.length === 0 ? /* @__PURE__ */ n.jsx(S9, { model: t }) : /* @__PURE__ */ n.jsxs(T, { pb: 20, children: [
36198
+ } = y(), t = _9();
36199
+ return t.variableOptions.length === 0 ? /* @__PURE__ */ n.jsx(w9, { model: t }) : /* @__PURE__ */ n.jsxs(T, { pb: 20, children: [
36194
36200
  /* @__PURE__ */ n.jsxs(b, { justify: "flex-start", children: [
36195
36201
  /* @__PURE__ */ n.jsx(N, { label: e("panel.variable.labels"), data: t.variableOptions, value: (r = t.selected) == null ? void 0 : r.name, onChange: t.selectByName, maxDropdownHeight: 600, sx: {
36196
36202
  flexGrow: 1
@@ -36203,9 +36209,9 @@ const S9 = D(({
36203
36209
  }, children: e("panel.variable.add") })
36204
36210
  ] }),
36205
36211
  /* @__PURE__ */ n.jsx(A, { variant: "dashed" }),
36206
- t.selected ? /* @__PURE__ */ n.jsx(w9, { uiModel: t, variable: t.selected }) : /* @__PURE__ */ n.jsx("span", { children: "Select or create a new variable on right side" })
36212
+ t.selected ? /* @__PURE__ */ n.jsx(j9, { uiModel: t, variable: t.selected }) : /* @__PURE__ */ n.jsx("span", { children: "Select or create a new variable on right side" })
36207
36213
  ] });
36208
- }), k9 = {
36214
+ }), C9 = {
36209
36215
  root: {
36210
36216
  flexGrow: 1,
36211
36217
  width: "100%",
@@ -36237,21 +36243,21 @@ const S9 = D(({
36237
36243
  flexGrow: 0,
36238
36244
  flexShrink: 0
36239
36245
  }, children: [
36240
- /* @__PURE__ */ n.jsx(h9, {}),
36246
+ /* @__PURE__ */ n.jsx(u9, {}),
36241
36247
  /* @__PURE__ */ n.jsx(R, { sx: {
36242
36248
  flexGrow: 1
36243
- }, children: /* @__PURE__ */ n.jsx(y9, {}) })
36249
+ }, children: /* @__PURE__ */ n.jsx(b9, {}) })
36244
36250
  ] })
36245
36251
  ] });
36246
- function T9(e) {
36252
+ function k9(e) {
36247
36253
  return !["richText", "button"].includes(e);
36248
36254
  }
36249
- const z9 = D(({
36255
+ const T9 = D(({
36250
36256
  panel: e
36251
36257
  }) => {
36252
36258
  const {
36253
36259
  t
36254
- } = y(), r = fn(), i = we(), a = je(), [s, o] = K(i.editor.panelTab), l = e.queries, d = T9(e.viz.type) && e.dataLoading, u = d || e.queryErrors.length > 0 || e.queryStateMessages !== "" || l.length === 0, h = i.editor.path[1];
36260
+ } = y(), r = fn(), i = we(), a = je(), [s, o] = K(i.editor.panelTab), l = e.queries, d = k9(e.viz.type) && e.dataLoading, u = d || e.queryErrors.length > 0 || e.queryStateMessages !== "" || l.length === 0, h = i.editor.path[1];
36255
36261
  H(() => {
36256
36262
  o((_) => u && _ === "Visualization" ? "Data" : _);
36257
36263
  }, [e.id, u]);
@@ -36287,11 +36293,11 @@ const z9 = D(({
36287
36293
  }, children: [
36288
36294
  /* @__PURE__ */ n.jsx(S, { size: "sm", pt: 9, pb: 8, children: e.name }),
36289
36295
  /* @__PURE__ */ n.jsxs(b, { justify: "flex-end", wrap: "nowrap", children: [
36290
- /* @__PURE__ */ n.jsx(b9, { panel: e, sourceViewID: h }),
36296
+ /* @__PURE__ */ n.jsx(f9, { panel: e, sourceViewID: h }),
36291
36297
  /* @__PURE__ */ n.jsx(L, { size: "xs", variant: "subtle", color: "red", onClick: x, leftSection: /* @__PURE__ */ n.jsx(ht, { size: 14 }), children: t("panel.delete") })
36292
36298
  ] })
36293
36299
  ] }),
36294
- /* @__PURE__ */ n.jsxs(j, { value: s, onChange: m, keepMounted: !1, styles: k9, children: [
36300
+ /* @__PURE__ */ n.jsxs(j, { value: s, onChange: m, keepMounted: !1, styles: C9, children: [
36295
36301
  /* @__PURE__ */ n.jsxs(j.List, { children: [
36296
36302
  /* @__PURE__ */ n.jsx(j.Tab, { value: "Data", leftSection: /* @__PURE__ */ n.jsx(ir, { size: 14 }), disabled: d, children: t("data.label") }),
36297
36303
  /* @__PURE__ */ n.jsx(j.Tab, { value: "Panel", leftSection: /* @__PURE__ */ n.jsx(vo, { size: 14 }), children: t("panel.label") }),
@@ -36303,15 +36309,15 @@ const z9 = D(({
36303
36309
  /* @__PURE__ */ n.jsx(lr, { visible: d, transitionProps: {
36304
36310
  exitDuration: 0
36305
36311
  } }),
36306
- /* @__PURE__ */ n.jsx(d9, {})
36312
+ /* @__PURE__ */ n.jsx(c9, {})
36307
36313
  ] }),
36308
- /* @__PURE__ */ n.jsx(j.Panel, { value: "Panel", children: /* @__PURE__ */ n.jsx(Es, { children: /* @__PURE__ */ n.jsx(r9, {}) }) }),
36309
- /* @__PURE__ */ n.jsx(j.Panel, { value: "Variables", children: /* @__PURE__ */ n.jsx(Es, { children: /* @__PURE__ */ n.jsx(C9, {}) }) }),
36310
- /* @__PURE__ */ n.jsx(j.Panel, { value: "Visualization", children: /* @__PURE__ */ n.jsx(Ze, { children: /* @__PURE__ */ n.jsx(Es, { children: /* @__PURE__ */ n.jsx(f9, {}) }) }) }),
36314
+ /* @__PURE__ */ n.jsx(j.Panel, { value: "Panel", children: /* @__PURE__ */ n.jsx(Es, { children: /* @__PURE__ */ n.jsx(n9, {}) }) }),
36315
+ /* @__PURE__ */ n.jsx(j.Panel, { value: "Variables", children: /* @__PURE__ */ n.jsx(Es, { children: /* @__PURE__ */ n.jsx(S9, {}) }) }),
36316
+ /* @__PURE__ */ n.jsx(j.Panel, { value: "Visualization", children: /* @__PURE__ */ n.jsx(Ze, { children: /* @__PURE__ */ n.jsx(Es, { children: /* @__PURE__ */ n.jsx(g9, {}) }) }) }),
36311
36317
  /* @__PURE__ */ n.jsx(j.Panel, { value: "Interactions", children: /* @__PURE__ */ n.jsx(Ze, { children: /* @__PURE__ */ n.jsx(Mw, {}) }) })
36312
36318
  ] })
36313
36319
  ] });
36314
- }), D9 = D(({
36320
+ }), z9 = D(({
36315
36321
  viewID: e,
36316
36322
  panelID: t
36317
36323
  }) => {
@@ -36323,12 +36329,12 @@ const z9 = D(({
36323
36329
  "] is not found"
36324
36330
  ] });
36325
36331
  const a = r.panels.findByID(t);
36326
- return a ? /* @__PURE__ */ n.jsx(z9, { panel: a }) : /* @__PURE__ */ n.jsxs(S, { size: "14px", children: [
36332
+ return a ? /* @__PURE__ */ n.jsx(T9, { panel: a }) : /* @__PURE__ */ n.jsxs(S, { size: "14px", children: [
36327
36333
  "Panel by ID[",
36328
36334
  t,
36329
36335
  "] is not found"
36330
36336
  ] });
36331
- }), I9 = D(() => {
36337
+ }), D9 = D(() => {
36332
36338
  const {
36333
36339
  t: e
36334
36340
  } = y(), [t, r] = K([]), i = fn(), a = we(), s = (m) => {
@@ -36435,7 +36441,7 @@ const z9 = D(({
36435
36441
  }) })
36436
36442
  ] }) }) })
36437
36443
  ] });
36438
- }), M9 = (e) => {
36444
+ }), I9 = (e) => {
36439
36445
  const {
36440
36446
  t
36441
36447
  } = y(), {
@@ -36466,7 +36472,7 @@ const z9 = D(({
36466
36472
  }, children: /* @__PURE__ */ n.jsx(L, { disabled: !0, size: "xs", leftSection: /* @__PURE__ */ n.jsx(ht, { size: 16 }), children: t("query.delete") }) }) }) : /* @__PURE__ */ n.jsx(L, { color: "red", size: "xs", onClick: c, leftSection: /* @__PURE__ */ n.jsx(ht, { size: 16 }), sx: {
36467
36473
  alignSelf: "flex-end"
36468
36474
  }, children: t("query.delete") });
36469
- }, L9 = D(M9), mg = ({
36475
+ }, M9 = D(I9), mg = ({
36470
36476
  width: e = "calc(100% - 32px)",
36471
36477
  lastWidth: t = "50%",
36472
36478
  height: r,
@@ -36478,7 +36484,7 @@ const z9 = D(({
36478
36484
  /* @__PURE__ */ n.jsx(kc, { width: t, height: r, radius: "xs" })
36479
36485
  ] }), ki = ({
36480
36486
  value: e
36481
- }) => e === null || e === "" ? null : /* @__PURE__ */ n.jsx(ue, { label: e, disabled: !e, multiline: !0, zIndex: 340, children: /* @__PURE__ */ n.jsx(oe, { variant: "subtle", children: /* @__PURE__ */ n.jsx(mt, { size: 14 }) }) }), P9 = ({
36487
+ }) => e === null || e === "" ? null : /* @__PURE__ */ n.jsx(ue, { label: e, disabled: !e, multiline: !0, zIndex: 340, children: /* @__PURE__ */ n.jsx(oe, { variant: "subtle", children: /* @__PURE__ */ n.jsx(mt, { size: 14 }) }) }), L9 = ({
36482
36488
  column: e
36483
36489
  }) => {
36484
36490
  const {
@@ -36486,7 +36492,7 @@ const z9 = D(({
36486
36492
  column_key_text: r
36487
36493
  } = e;
36488
36494
  return t ? /* @__PURE__ */ n.jsx(ue, { label: r, disabled: !r, children: /* @__PURE__ */ n.jsx(rr, { variant: "light", children: t }) }) : null;
36489
- }, E9 = D(({
36495
+ }, P9 = D(({
36490
36496
  dataSource: e
36491
36497
  }) => {
36492
36498
  const {
@@ -36540,13 +36546,13 @@ const z9 = D(({
36540
36546
  /* @__PURE__ */ n.jsx(v.Td, { children: r.ordinal_position }),
36541
36547
  /* @__PURE__ */ n.jsx(v.Td, { children: r.column_name }),
36542
36548
  /* @__PURE__ */ n.jsx(v.Td, { children: /* @__PURE__ */ n.jsx(ki, { value: r.column_comment }) }),
36543
- /* @__PURE__ */ n.jsx(v.Td, { children: /* @__PURE__ */ n.jsx(P9, { column: r }) }),
36549
+ /* @__PURE__ */ n.jsx(v.Td, { children: /* @__PURE__ */ n.jsx(L9, { column: r }) }),
36544
36550
  /* @__PURE__ */ n.jsx(v.Td, { children: r.column_type }),
36545
36551
  /* @__PURE__ */ n.jsx(v.Td, { children: r.is_nullable }),
36546
36552
  /* @__PURE__ */ n.jsx(v.Td, { children: /* @__PURE__ */ n.jsx(ki, { value: r.column_default }) })
36547
36553
  ] }, r.column_name)) })
36548
36554
  ] });
36549
- }), R9 = D(({
36555
+ }), E9 = D(({
36550
36556
  dataSource: e
36551
36557
  }) => {
36552
36558
  const {
@@ -36594,7 +36600,7 @@ const z9 = D(({
36594
36600
  /* @__PURE__ */ n.jsx(v.Td, { children: i.column_name })
36595
36601
  ] }, i.index_name)) })
36596
36602
  ] });
36597
- }), $9 = D(({
36603
+ }), R9 = D(({
36598
36604
  dataSource: e
36599
36605
  }) => {
36600
36606
  const {
@@ -36647,29 +36653,29 @@ const z9 = D(({
36647
36653
  /* @__PURE__ */ n.jsx(v.Td, { children: /* @__PURE__ */ n.jsx(ki, { value: i.comment }) })
36648
36654
  ] }, i.index_name)) })
36649
36655
  ] });
36650
- }), A9 = D(({
36656
+ }), $9 = D(({
36651
36657
  dataSource: e
36652
36658
  }) => {
36653
36659
  const {
36654
36660
  indexes: t
36655
36661
  } = e.dbInfo;
36656
- return t.loading || t.empty ? null : e.type === me.MySQL ? /* @__PURE__ */ n.jsx(R9, { dataSource: e }) : e.type === me.Postgresql ? /* @__PURE__ */ n.jsx($9, { dataSource: e }) : null;
36657
- }), O9 = D(({
36662
+ return t.loading || t.empty ? null : e.type === me.MySQL ? /* @__PURE__ */ n.jsx(E9, { dataSource: e }) : e.type === me.Postgresql ? /* @__PURE__ */ n.jsx(R9, { dataSource: e }) : null;
36663
+ }), A9 = D(({
36658
36664
  dataSource: e
36659
36665
  }) => /* @__PURE__ */ n.jsxs(T, { gap: 40, pt: 10, sx: {
36660
36666
  flexGrow: 1,
36661
36667
  overflow: "auto",
36662
36668
  position: "relative"
36663
36669
  }, children: [
36664
- /* @__PURE__ */ n.jsx(Ze, { children: /* @__PURE__ */ n.jsx(E9, { dataSource: e }) }),
36665
- /* @__PURE__ */ n.jsx(Ze, { children: /* @__PURE__ */ n.jsx(A9, { dataSource: e }) })
36670
+ /* @__PURE__ */ n.jsx(Ze, { children: /* @__PURE__ */ n.jsx(P9, { dataSource: e }) }),
36671
+ /* @__PURE__ */ n.jsx(Ze, { children: /* @__PURE__ */ n.jsx($9, { dataSource: e }) })
36666
36672
  ] }));
36667
- function V9({
36673
+ function O9({
36668
36674
  table_type: e
36669
36675
  }) {
36670
36676
  return e === "VIEW" ? /* @__PURE__ */ n.jsx(ko, { size: 14 }) : e === "BASE TABLE" ? /* @__PURE__ */ n.jsx(Zf, { size: 14 }) : null;
36671
36677
  }
36672
- const F9 = D(({
36678
+ const V9 = D(({
36673
36679
  dataSource: e
36674
36680
  }) => {
36675
36681
  const t = e.dbInfo, {
@@ -36680,17 +36686,17 @@ const F9 = D(({
36680
36686
  ".mantine-NavLink-label": {
36681
36687
  fontFamily: "monospace"
36682
36688
  }
36683
- }, children: Object.entries(r.data).map(([i, a]) => /* @__PURE__ */ n.jsx(Rs, { label: i, title: i, leftSection: /* @__PURE__ */ n.jsx(ir, { size: 14 }), defaultOpened: t.table_schema === i, pl: 0, childrenOffset: 14, children: a.map((s) => /* @__PURE__ */ n.jsx(Rs, { label: s.table_name, title: s.table_name, leftSection: /* @__PURE__ */ n.jsx(V9, { table_type: s.table_type }), onClick: () => {
36689
+ }, children: Object.entries(r.data).map(([i, a]) => /* @__PURE__ */ n.jsx(Rs, { label: i, title: i, leftSection: /* @__PURE__ */ n.jsx(ir, { size: 14 }), defaultOpened: t.table_schema === i, pl: 0, childrenOffset: 14, children: a.map((s) => /* @__PURE__ */ n.jsx(Rs, { label: s.table_name, title: s.table_name, leftSection: /* @__PURE__ */ n.jsx(O9, { table_type: s.table_type }), onClick: () => {
36684
36690
  t.setKeywords(i, s.table_name);
36685
36691
  }, active: t.table_name === s.table_name }, s.table_name)) }, i)) });
36686
- }), N9 = ({
36692
+ }), F9 = ({
36687
36693
  visible: e
36688
36694
  }) => /* @__PURE__ */ n.jsx(R, { py: 10, sx: {
36689
36695
  width: "100%",
36690
36696
  height: "100%",
36691
36697
  overflow: "hidden",
36692
36698
  position: "relative"
36693
- }, children: /* @__PURE__ */ n.jsx(lr, { visible: e }) }), q9 = [{
36699
+ }, children: /* @__PURE__ */ n.jsx(lr, { visible: e }) }), N9 = [{
36694
36700
  label: "10",
36695
36701
  value: "10"
36696
36702
  }, {
@@ -36702,7 +36708,7 @@ const F9 = D(({
36702
36708
  }, {
36703
36709
  label: "100",
36704
36710
  value: "100"
36705
- }], B9 = {
36711
+ }], q9 = {
36706
36712
  section: {
36707
36713
  width: "50px",
36708
36714
  textAlign: "center"
@@ -36710,7 +36716,7 @@ const F9 = D(({
36710
36716
  input: {
36711
36717
  paddingLeft: "50px"
36712
36718
  }
36713
- }, H9 = D(({
36719
+ }, B9 = D(({
36714
36720
  dataSource: e
36715
36721
  }) => {
36716
36722
  const {
@@ -36725,7 +36731,7 @@ const F9 = D(({
36725
36731
  height: "30px"
36726
36732
  }
36727
36733
  } }),
36728
- /* @__PURE__ */ n.jsx(N, { leftSection: /* @__PURE__ */ n.jsx(S, { ta: "center", c: "dimmed", size: "14px", children: t("common.pagination.page_size") }), size: "xs", styles: B9, data: q9, value: String(r.limit), onChange: (i) => r.setLimit(Number(i)), comboboxProps: {
36734
+ /* @__PURE__ */ n.jsx(N, { leftSection: /* @__PURE__ */ n.jsx(S, { ta: "center", c: "dimmed", size: "14px", children: t("common.pagination.page_size") }), size: "xs", styles: q9, data: N9, value: String(r.limit), onChange: (i) => r.setLimit(Number(i)), comboboxProps: {
36729
36735
  zIndex: 340
36730
36736
  } })
36731
36737
  ] }),
@@ -36733,12 +36739,12 @@ const F9 = D(({
36733
36739
  total: r.total
36734
36740
  }) }) })
36735
36741
  ] });
36736
- }), Q9 = D(({
36742
+ }), H9 = D(({
36737
36743
  dataSource: e
36738
36744
  }) => {
36739
36745
  const t = e.dbInfo.tableData;
36740
- return t.maxPage === 0 ? /* @__PURE__ */ n.jsx(S, { mt: 20, c: "red", size: "md", ta: "center", ff: "monospace", children: "This table is empty" }) : t.error ? /* @__PURE__ */ n.jsx(S, { mt: 20, c: "red", size: "md", ta: "center", ff: "monospace", children: t.error }) : t.page === 1 && t.loading ? /* @__PURE__ */ n.jsx(N9, { visible: !0 }) : /* @__PURE__ */ n.jsxs(Ze, { children: [
36741
- /* @__PURE__ */ n.jsx(H9, { dataSource: e }),
36746
+ return t.maxPage === 0 ? /* @__PURE__ */ n.jsx(S, { mt: 20, c: "red", size: "md", ta: "center", ff: "monospace", children: "This table is empty" }) : t.error ? /* @__PURE__ */ n.jsx(S, { mt: 20, c: "red", size: "md", ta: "center", ff: "monospace", children: t.error }) : t.page === 1 && t.loading ? /* @__PURE__ */ n.jsx(F9, { visible: !0 }) : /* @__PURE__ */ n.jsxs(Ze, { children: [
36747
+ /* @__PURE__ */ n.jsx(B9, { dataSource: e }),
36742
36748
  /* @__PURE__ */ n.jsxs(R, { py: 10, sx: {
36743
36749
  width: "100%",
36744
36750
  height: "calc(100% - 42px)",
@@ -36751,7 +36757,7 @@ const F9 = D(({
36751
36757
  /* @__PURE__ */ n.jsx(pg, { data: t.data })
36752
36758
  ] })
36753
36759
  ] });
36754
- }), G9 = {
36760
+ }), Q9 = {
36755
36761
  root: {
36756
36762
  flexGrow: 1,
36757
36763
  overflow: "auto",
@@ -36763,7 +36769,7 @@ const F9 = D(({
36763
36769
  tab: {
36764
36770
  minWidth: 120
36765
36771
  }
36766
- }, W9 = D(({
36772
+ }, G9 = D(({
36767
36773
  dataSource: e
36768
36774
  }) => {
36769
36775
  const {
@@ -36778,21 +36784,21 @@ const F9 = D(({
36778
36784
  flexGrow: 0,
36779
36785
  flexShrink: 0,
36780
36786
  position: "relative"
36781
- }, children: /* @__PURE__ */ n.jsx(Ze, { children: /* @__PURE__ */ n.jsx(F9, { dataSource: e }) }) }),
36782
- /* @__PURE__ */ n.jsxs(j, { defaultValue: "structure", styles: G9, children: [
36787
+ }, children: /* @__PURE__ */ n.jsx(Ze, { children: /* @__PURE__ */ n.jsx(V9, { dataSource: e }) }) }),
36788
+ /* @__PURE__ */ n.jsxs(j, { defaultValue: "structure", styles: Q9, children: [
36783
36789
  /* @__PURE__ */ n.jsxs(j.List, { children: [
36784
36790
  /* @__PURE__ */ n.jsx(j.Tab, { value: "structure", leftSection: /* @__PURE__ */ n.jsx(Jf, { size: 14 }), children: t("data_source.table_structure_short") }),
36785
36791
  /* @__PURE__ */ n.jsx(j.Tab, { value: "data", leftSection: /* @__PURE__ */ n.jsx(ir, { size: 14 }), children: t("data.label") })
36786
36792
  ] }),
36787
- /* @__PURE__ */ n.jsx(j.Panel, { value: "structure", children: /* @__PURE__ */ n.jsx(O9, { dataSource: e }) }),
36793
+ /* @__PURE__ */ n.jsx(j.Panel, { value: "structure", children: /* @__PURE__ */ n.jsx(A9, { dataSource: e }) }),
36788
36794
  /* @__PURE__ */ n.jsx(j.Panel, { value: "data", sx: {
36789
36795
  width: "100%",
36790
36796
  height: "calc(100% - 36px)",
36791
36797
  overflow: "hidden"
36792
- }, children: /* @__PURE__ */ n.jsx(Q9, { dataSource: e }) })
36798
+ }, children: /* @__PURE__ */ n.jsx(H9, { dataSource: e }) })
36793
36799
  ] })
36794
36800
  ] });
36795
- }), U9 = {
36801
+ }), W9 = {
36796
36802
  modal: {
36797
36803
  paddingLeft: "0px !important",
36798
36804
  paddingRight: "0px !important"
@@ -36833,9 +36839,9 @@ const F9 = D(({
36833
36839
  to: "red"
36834
36840
  }, children: e.type })
36835
36841
  ] })
36836
- ] }), zIndex: 320, size: "96vw", styles: U9, children: /* @__PURE__ */ n.jsx(R, { sx: {
36842
+ ] }), zIndex: 320, size: "96vw", styles: W9, children: /* @__PURE__ */ n.jsx(R, { sx: {
36837
36843
  height: "calc(100vh - 220px)"
36838
- }, children: /* @__PURE__ */ n.jsx(W9, { dataSource: e }) }) }),
36844
+ }, children: /* @__PURE__ */ n.jsx(G9, { dataSource: e }) }) }),
36839
36845
  /* @__PURE__ */ n.jsx(L, { variant: "subtle", onClick: () => a(!0), px: 16, styles: {
36840
36846
  inner: {
36841
36847
  justifyContent: "flex-start"
@@ -36847,7 +36853,7 @@ const F9 = D(({
36847
36853
  mysql: "MySQL",
36848
36854
  postgresql: "PostgreSQL",
36849
36855
  merico_metric_system: "指标系统"
36850
- }, Y9 = ({
36856
+ }, U9 = ({
36851
36857
  option: e,
36852
36858
  ...t
36853
36859
  }) => {
@@ -36908,7 +36914,7 @@ const F9 = D(({
36908
36914
  size: "compact-xs",
36909
36915
  px: 10
36910
36916
  } })
36911
- ] }), renderOption: Y9, rightSection: d ? /* @__PURE__ */ n.jsx(S, { size: "xs", c: "dimmed", children: gg[d.type] ?? d.type }) : void 0, rightSectionWidth: 85, maxDropdownHeight: 500, styles: {
36917
+ ] }), renderOption: U9, rightSection: d ? /* @__PURE__ */ n.jsx(S, { size: "xs", c: "dimmed", children: gg[d.type] ?? d.type }) : void 0, rightSectionWidth: 85, maxDropdownHeight: 500, styles: {
36912
36918
  root: {
36913
36919
  flex: 1,
36914
36920
  minWidth: "300px"
@@ -36925,7 +36931,7 @@ const F9 = D(({
36925
36931
  }
36926
36932
  }
36927
36933
  }, disabled: s, value: e.key, onChange: c });
36928
- }), K9 = D(({
36934
+ }), Y9 = D(({
36929
36935
  queryModel: e
36930
36936
  }) => {
36931
36937
  const {
@@ -36956,10 +36962,10 @@ const F9 = D(({
36956
36962
  /* @__PURE__ */ n.jsx(yr, { label: t("query.run_by_condition.label"), description: t("query.run_by_condition.description"), placeholder: t("query.run_by_condition.unset"), data: a, value: [...e.run_by], onChange: e.setRunBy, renderOption: ld, maxDropdownHeight: 500 }),
36957
36963
  e.typedAsHTTP && /* @__PURE__ */ n.jsx(yr, { label: t("query.re_run_condition.label"), placeholder: t("query.re_run_condition.label"), data: a, value: [...e.config.react_to], onChange: e.config.setReactTo, renderOption: ld, maxDropdownHeight: 500 }),
36958
36964
  /* @__PURE__ */ n.jsx(A, { mt: 20, mb: 10, variant: "dashed" }),
36959
- /* @__PURE__ */ n.jsx(L9, { queryModel: e })
36965
+ /* @__PURE__ */ n.jsx(M9, { queryModel: e })
36960
36966
  ] }) });
36961
36967
  });
36962
- function X9({
36968
+ function K9({
36963
36969
  content: e
36964
36970
  }) {
36965
36971
  return /* @__PURE__ */ n.jsxs(He, { width: "60vw", shadow: "md", zIndex: 340, children: [
@@ -36967,7 +36973,7 @@ function X9({
36967
36973
  /* @__PURE__ */ n.jsx(He.Dropdown, { children: /* @__PURE__ */ n.jsx(xn, { language: "sql", withCopyButton: !1, code: e }) })
36968
36974
  ] });
36969
36975
  }
36970
- const Z9 = D(() => {
36976
+ const X9 = D(() => {
36971
36977
  const t = [...we().globalSQLSnippets.list];
36972
36978
  return t.length === 0 ? null : /* @__PURE__ */ n.jsxs(v, { horizontalSpacing: "xs", verticalSpacing: "xs", fz: "sm", highlightOnHover: !0, children: [
36973
36979
  /* @__PURE__ */ n.jsx(v.Thead, { children: /* @__PURE__ */ n.jsxs(v.Tr, { children: [
@@ -36981,11 +36987,11 @@ const Z9 = D(() => {
36981
36987
  } = r;
36982
36988
  return /* @__PURE__ */ n.jsxs(v.Tr, { children: [
36983
36989
  /* @__PURE__ */ n.jsx(v.Td, { children: i }),
36984
- /* @__PURE__ */ n.jsx(v.Td, { width: 200, children: /* @__PURE__ */ n.jsx(X9, { content: a }) })
36990
+ /* @__PURE__ */ n.jsx(v.Td, { width: 200, children: /* @__PURE__ */ n.jsx(K9, { content: a }) })
36985
36991
  ] }, i);
36986
36992
  }) })
36987
36993
  ] });
36988
- }), J9 = `
36994
+ }), Z9 = `
36989
36995
  -- You may reference query variables in SQL or VizConfig.
36990
36996
  SELECT *
36991
36997
  FROM commit
@@ -37019,13 +37025,13 @@ WHERE
37019
37025
  ] }),
37020
37026
  /* @__PURE__ */ n.jsx(j.Panel, { value: "guide", pt: "xs", children: /* @__PURE__ */ n.jsx(xn, { language: "sql", sx: {
37021
37027
  width: "100%"
37022
- }, withCopyButton: !1, code: J9 }) }),
37028
+ }, withCopyButton: !1, code: Z9 }) }),
37023
37029
  /* @__PURE__ */ n.jsx(j.Panel, { value: "local_query_vars", pt: "xs", children: /* @__PURE__ */ n.jsx(xn, { language: "json", sx: {
37024
37030
  width: "100%"
37025
37031
  }, withCopyButton: !1, code: o }) }),
37026
37032
  /* @__PURE__ */ n.jsx(j.Panel, { value: "global_sql_snippets", pt: "xs", children: /* @__PURE__ */ n.jsxs(T, { gap: 10, children: [
37027
37033
  /* @__PURE__ */ n.jsx(Pi, { icon: /* @__PURE__ */ n.jsx(zi, { size: 16 }), title: i("global_sql_snippet.labels"), children: i("global_sql_snippet.description") }),
37028
- /* @__PURE__ */ n.jsx(Z9, {})
37034
+ /* @__PURE__ */ n.jsx(X9, {})
37029
37035
  ] }) })
37030
37036
  ] }) });
37031
37037
  }), oc = D(() => {
@@ -37045,7 +37051,7 @@ WHERE
37045
37051
  `),
37046
37052
  post: ["function process_result(resp, utils, state) {", " return resp.data", "}"].join(`
37047
37053
  `)
37048
- }, eP = D(({
37054
+ }, J9 = D(({
37049
37055
  queryModel: e
37050
37056
  }) => {
37051
37057
  const {
@@ -37105,7 +37111,7 @@ WHERE
37105
37111
  ] }) })
37106
37112
  ] }, o.id)) })
37107
37113
  ] });
37108
- }), tP = D(({
37114
+ }), eP = D(({
37109
37115
  queryModel: e
37110
37116
  }) => {
37111
37117
  const {
@@ -37131,7 +37137,7 @@ WHERE
37131
37137
  } }), sx: {
37132
37138
  transform: "none !important"
37133
37139
  }, children: t("query.dependency.label") }) });
37134
- }), nP = "SELECT 1", rP = D(({
37140
+ }), tP = "SELECT 1", nP = D(({
37135
37141
  queryModel: e
37136
37142
  }) => {
37137
37143
  const {
@@ -37141,7 +37147,7 @@ WHERE
37141
37147
  }, o = () => {
37142
37148
  a(r.sql);
37143
37149
  }, l = () => {
37144
- a(nP);
37150
+ a(tP);
37145
37151
  };
37146
37152
  H(() => {
37147
37153
  a(r.sql);
@@ -37154,7 +37160,7 @@ WHERE
37154
37160
  flexShrink: 0,
37155
37161
  flexGrow: 0
37156
37162
  }, children: [
37157
- /* @__PURE__ */ n.jsx(b, { justify: "flex-start", children: /* @__PURE__ */ n.jsx(tP, { queryModel: e }) }),
37163
+ /* @__PURE__ */ n.jsx(b, { justify: "flex-start", children: /* @__PURE__ */ n.jsx(eP, { queryModel: e }) }),
37158
37164
  /* @__PURE__ */ n.jsxs(b, { justify: "flex-end", children: [
37159
37165
  /* @__PURE__ */ n.jsx(L, { onClick: l, size: "xs", variant: "default", leftSection: /* @__PURE__ */ n.jsx(fu, { size: 16 }), children: t("common.actions.reset_to_default") }),
37160
37166
  /* @__PURE__ */ n.jsx(L, { onClick: o, color: "red", size: "xs", disabled: !c, leftSection: /* @__PURE__ */ n.jsx(nn, { size: 16 }), children: t("common.actions.revert_changes") }),
@@ -37163,7 +37169,7 @@ WHERE
37163
37169
  ] }),
37164
37170
  /* @__PURE__ */ n.jsx(_l, { height: "100%", value: i, onChange: a, theme: "sql-dark", defaultLanguage: "sql" })
37165
37171
  ] });
37166
- }), iP = ({
37172
+ }), rP = ({
37167
37173
  value: e,
37168
37174
  height: t = "200px",
37169
37175
  defaultLanguage: r = "sql"
@@ -37176,17 +37182,17 @@ WHERE
37176
37182
  enabled: !1
37177
37183
  },
37178
37184
  readOnly: !0
37179
- } }), aP = D(({
37185
+ } }), iP = D(({
37180
37186
  value: e
37181
37187
  }) => {
37182
37188
  const r = Je().payloadForSQL, i = B.useMemo(() => Mo(e, r), [e, r]);
37183
- return /* @__PURE__ */ n.jsx(iP, { height: "100%", value: i });
37189
+ return /* @__PURE__ */ n.jsx(rP, { height: "100%", value: i });
37184
37190
  }), Wd = {
37185
37191
  pre: ["function process_request({ context, filters, sql }, utils) {", " // modify and return sql", " return sql", "}"].join(`
37186
37192
  `),
37187
37193
  post: ["function process_result(data, utils, state) {", " // process data and return the result", " return data", "}"].join(`
37188
37194
  `)
37189
- }, sP = D(({
37195
+ }, aP = D(({
37190
37196
  queryModel: e
37191
37197
  }) => {
37192
37198
  const {
@@ -37214,18 +37220,18 @@ WHERE
37214
37220
  ] }),
37215
37221
  /* @__PURE__ */ n.jsx(j.Panel, { value: "Edit", sx: {
37216
37222
  position: "relative"
37217
- }, p: "sm", children: /* @__PURE__ */ n.jsx(rP, { queryModel: e }) }),
37218
- /* @__PURE__ */ n.jsx(j.Panel, { value: "Preview", p: 0, pl: 4, children: /* @__PURE__ */ n.jsx(aP, { value: r.sql }) }),
37223
+ }, p: "sm", children: /* @__PURE__ */ n.jsx(nP, { queryModel: e }) }),
37224
+ /* @__PURE__ */ n.jsx(j.Panel, { value: "Preview", p: 0, pl: 4, children: /* @__PURE__ */ n.jsx(iP, { value: r.sql }) }),
37219
37225
  /* @__PURE__ */ n.jsx(j.Panel, { value: "pre_process", sx: {
37220
37226
  position: "relative"
37221
37227
  }, p: "sm", children: /* @__PURE__ */ n.jsx(kr, { label: "", value: e.pre_process, onChange: e.setPreProcess, defaultValue: Wd.pre }) }),
37222
37228
  /* @__PURE__ */ n.jsx(j.Panel, { value: "post_process", p: "sm", children: /* @__PURE__ */ n.jsx(kr, { label: "", value: e.post_process, onChange: e.setPostProcess, defaultValue: Wd.post }) })
37223
37229
  ] });
37224
- }), oP = {
37230
+ }), sP = {
37225
37231
  pre: ["function transform(queries, state, utils) {", " // use queries & dashboar state to build new data", " const data = []", " return data", "}"].join(`
37226
37232
  `),
37227
37233
  post: ""
37228
- }, lP = D(({
37234
+ }, oP = D(({
37229
37235
  queryModel: e
37230
37236
  }) => {
37231
37237
  const {
@@ -37242,13 +37248,13 @@ WHERE
37242
37248
  /* @__PURE__ */ n.jsx(S, { size: "sm", children: t("query.transform.guide.write_function") }),
37243
37249
  /* @__PURE__ */ n.jsx(R, { sx: {
37244
37250
  flexGrow: 1
37245
- }, children: /* @__PURE__ */ n.jsx(kr, { label: "", value: e.pre_process, onChange: e.setPreProcess, defaultValue: oP.pre }) })
37251
+ }, children: /* @__PURE__ */ n.jsx(kr, { label: "", value: e.pre_process, onChange: e.setPreProcess, defaultValue: sP.pre }) })
37246
37252
  ] });
37247
37253
  }), xi = {
37248
37254
  height: "calc(100% - 44px)",
37249
37255
  // Tabs.List
37250
37256
  padding: 0
37251
- }, cP = D(({
37257
+ }, lP = D(({
37252
37258
  queryModel: e
37253
37259
  }) => {
37254
37260
  const {
@@ -37269,16 +37275,16 @@ WHERE
37269
37275
  /* @__PURE__ */ n.jsx(j.Tab, { value: "Data", disabled: !e.canPreviewData, children: /* @__PURE__ */ n.jsx(ue, { label: e.guideToPreviewData, disabled: e.canPreviewData, withinPortal: !0, children: /* @__PURE__ */ n.jsx(S, { size: "sm", children: t("data.preview_data") }) }) }),
37270
37276
  /* @__PURE__ */ n.jsx(j.Tab, { value: "Usage", disabled: l, children: /* @__PURE__ */ n.jsx(ue, { label: t("query.usage.unused_description"), disabled: !l, withinPortal: !0, children: /* @__PURE__ */ n.jsx(S, { size: "sm", children: t("query.usage.label") }) }) })
37271
37277
  ] }),
37272
- /* @__PURE__ */ n.jsx(j.Panel, { value: "Configurations", pt: 0, p: 0, children: /* @__PURE__ */ n.jsx(K9, { queryModel: e }) }),
37278
+ /* @__PURE__ */ n.jsx(j.Panel, { value: "Configurations", pt: 0, p: 0, children: /* @__PURE__ */ n.jsx(Y9, { queryModel: e }) }),
37273
37279
  e.typedAsSQL && /* @__PURE__ */ n.jsx(j.Panel, { value: "SQL", sx: xi, children: /* @__PURE__ */ n.jsx(T, { sx: {
37274
37280
  height: "100%"
37275
- }, children: /* @__PURE__ */ n.jsx(sP, { queryModel: e }) }) }),
37281
+ }, children: /* @__PURE__ */ n.jsx(aP, { queryModel: e }) }) }),
37276
37282
  e.typedAsHTTP && /* @__PURE__ */ n.jsx(j.Panel, { value: "HTTP", sx: xi, children: /* @__PURE__ */ n.jsx(T, { sx: {
37277
37283
  height: "100%"
37278
- }, children: /* @__PURE__ */ n.jsx(eP, { queryModel: e }) }) }),
37284
+ }, children: /* @__PURE__ */ n.jsx(J9, { queryModel: e }) }) }),
37279
37285
  e.isTransform && /* @__PURE__ */ n.jsx(j.Panel, { value: "Transform", sx: xi, children: /* @__PURE__ */ n.jsx(T, { sx: {
37280
37286
  height: "100%"
37281
- }, children: /* @__PURE__ */ n.jsx(lP, { queryModel: e }) }) }),
37287
+ }, children: /* @__PURE__ */ n.jsx(oP, { queryModel: e }) }) }),
37282
37288
  /* @__PURE__ */ n.jsx(j.Panel, { value: "Data", sx: {
37283
37289
  ...xi,
37284
37290
  overflow: "hidden"
@@ -37288,7 +37294,7 @@ WHERE
37288
37294
  overflow: "hidden"
37289
37295
  }, children: /* @__PURE__ */ n.jsx(yg, { queryModel: e }) })
37290
37296
  ] });
37291
- }), dP = ({
37297
+ }), cP = ({
37292
37298
  width: e,
37293
37299
  height: t
37294
37300
  }) => /* @__PURE__ */ n.jsxs("svg", { width: e, height: t, viewBox: "0 0 36 36", fill: "none", children: [
@@ -37309,14 +37315,14 @@ WHERE
37309
37315
  /* @__PURE__ */ n.jsx("path", { d: "M6.66665 6.66699C7.03484 6.66699 7.33331 6.96547 7.33331 7.33366V11.3337C7.33331 11.7018 7.03484 12.0003 6.66665 12.0003C6.29846 12.0003 5.99998 11.7018 5.99998 11.3337V7.33366C5.99998 6.96547 6.29846 6.66699 6.66665 6.66699Z", fill: r }),
37310
37316
  /* @__PURE__ */ n.jsx("path", { d: "M9.99998 11.3337V7.33366C9.99998 6.96547 9.7015 6.66699 9.33331 6.66699C8.96512 6.66699 8.66665 6.96547 8.66665 7.33366V11.3337C8.66665 11.7018 8.96512 12.0003 9.33331 12.0003C9.7015 12.0003 9.99998 11.7018 9.99998 11.3337Z", fill: r }),
37311
37317
  /* @__PURE__ */ n.jsx("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M4.66665 3.33366V2.66699C4.66665 2.13656 4.87736 1.62785 5.25243 1.25278C5.62751 0.877706 6.13621 0.666992 6.66665 0.666992H9.33331C9.86375 0.666992 10.3725 0.877706 10.7475 1.25278C11.1226 1.62785 11.3333 2.13656 11.3333 2.66699V3.33366H14C14.3682 3.33366 14.6666 3.63214 14.6666 4.00033C14.6666 4.36852 14.3682 4.66699 14 4.66699H13.3333V13.3337C13.3333 13.8641 13.1226 14.3728 12.7475 14.7479C12.3725 15.1229 11.8637 15.3337 11.3333 15.3337H4.66665C4.13621 15.3337 3.62751 15.1229 3.25243 14.7479C2.87736 14.3728 2.66665 13.8641 2.66665 13.3337V4.66699H1.99998C1.63179 4.66699 1.33331 4.36852 1.33331 4.00033C1.33331 3.63214 1.63179 3.33366 1.99998 3.33366H4.66665ZM6.19524 2.19559C6.32027 2.07056 6.48984 2.00033 6.66665 2.00033H9.33331C9.51012 2.00033 9.67969 2.07056 9.80472 2.19559C9.92974 2.32061 9.99998 2.49018 9.99998 2.66699V3.33366H5.99998V2.66699C5.99998 2.49018 6.07022 2.32061 6.19524 2.19559ZM3.99998 4.66699V13.3337C3.99998 13.5105 4.07022 13.68 4.19524 13.8051C4.32027 13.9301 4.48984 14.0003 4.66665 14.0003H11.3333C11.5101 14.0003 11.6797 13.9301 11.8047 13.8051C11.9297 13.68 12 13.5105 12 13.3337V4.66699H3.99998Z", fill: r })
37312
- ] }), uP = ({
37318
+ ] }), dP = ({
37313
37319
  width: e,
37314
37320
  height: t
37315
37321
  }) => /* @__PURE__ */ n.jsxs("svg", { viewBox: "0 0 18 18", fill: "none", width: e, height: t, children: [
37316
37322
  /* @__PURE__ */ n.jsx("path", { d: "M7.5 3.75C7.5 2.92157 8.17157 2.25 9 2.25C9.82843 2.25 10.5 2.92157 10.5 3.75C10.5 4.57843 9.82843 5.25 9 5.25C8.17157 5.25 7.5 4.57843 7.5 3.75Z", fill: "#3D3E45" }),
37317
37323
  /* @__PURE__ */ n.jsx("path", { d: "M7.5 9C7.5 8.17157 8.17157 7.5 9 7.5C9.82843 7.5 10.5 8.17157 10.5 9C10.5 9.82843 9.82843 10.5 9 10.5C8.17157 10.5 7.5 9.82843 7.5 9Z", fill: "#3D3E45" }),
37318
37324
  /* @__PURE__ */ n.jsx("path", { d: "M9 12.75C8.17157 12.75 7.5 13.4216 7.5 14.25C7.5 15.0784 8.17157 15.75 9 15.75C9.82843 15.75 10.5 15.0784 10.5 14.25C10.5 13.4216 9.82843 12.75 9 12.75Z", fill: "#3D3E45" })
37319
- ] }), hP = D(({
37325
+ ] }), uP = D(({
37320
37326
  queryModel: e
37321
37327
  }) => {
37322
37328
  const {
@@ -37345,12 +37351,12 @@ WHERE
37345
37351
  }, withinPortal: !0, zIndex: 320, position: "bottom-end", children: /* @__PURE__ */ n.jsx(L, { leftSection: /* @__PURE__ */ n.jsx(Yd, { width: 14, height: 14, color: "gray" }), variant: "subtle", color: "gray", onClick: (c) => {
37346
37352
  c.stopPropagation();
37347
37353
  }, children: "删除查询" }) }) : /* @__PURE__ */ n.jsx(re.Item, { leftSection: /* @__PURE__ */ n.jsx(Yd, { width: 14, height: 14 }), color: "red", onClick: l, children: "删除查询" });
37348
- }), pP = D(({
37354
+ }), hP = D(({
37349
37355
  queryModel: e
37350
37356
  }) => /* @__PURE__ */ n.jsxs(re, { shadow: "md", width: 120, trigger: "hover", children: [
37351
- /* @__PURE__ */ n.jsx(re.Target, { children: /* @__PURE__ */ n.jsx(oe, { variant: "subtle", "aria-label": "Settings", children: /* @__PURE__ */ n.jsx(uP, { width: 18, height: 18 }) }) }),
37352
- /* @__PURE__ */ n.jsx(re.Dropdown, { children: /* @__PURE__ */ n.jsx(hP, { queryModel: e }) })
37353
- ] })), mP = {
37357
+ /* @__PURE__ */ n.jsx(re.Target, { children: /* @__PURE__ */ n.jsx(oe, { variant: "subtle", "aria-label": "Settings", children: /* @__PURE__ */ n.jsx(dP, { width: 18, height: 18 }) }) }),
37358
+ /* @__PURE__ */ n.jsx(re.Dropdown, { children: /* @__PURE__ */ n.jsx(uP, { queryModel: e }) })
37359
+ ] })), pP = {
37354
37360
  width: "fit-content",
37355
37361
  minWidth: "100%",
37356
37362
  tableLayout: "fixed",
@@ -37387,7 +37393,7 @@ WHERE
37387
37393
  }
37388
37394
  }
37389
37395
  };
37390
- function xP({
37396
+ function mP({
37391
37397
  data: e
37392
37398
  }) {
37393
37399
  const t = z(() => {
@@ -37405,7 +37411,7 @@ function xP({
37405
37411
  });
37406
37412
  return e.length === 0 ? /* @__PURE__ */ n.jsx(R, { sx: {
37407
37413
  height: "5em"
37408
- } }) : /* @__PURE__ */ n.jsx(Ze, { children: /* @__PURE__ */ n.jsxs(v, { sx: mP, stickyHeader: !0, stickyHeaderOffset: 0, children: [
37414
+ } }) : /* @__PURE__ */ n.jsx(Ze, { children: /* @__PURE__ */ n.jsxs(v, { sx: pP, stickyHeader: !0, stickyHeaderOffset: 0, children: [
37409
37415
  /* @__PURE__ */ n.jsx(v.Thead, { style: {
37410
37416
  backgroundColor: "#F9F9FA"
37411
37417
  }, children: r.getHeaderGroups().map((i) => /* @__PURE__ */ n.jsx(v.Tr, { children: i.headers.map((a) => /* @__PURE__ */ n.jsxs(v.Th, { style: {
@@ -37417,7 +37423,7 @@ function xP({
37417
37423
  /* @__PURE__ */ n.jsx(v.Tbody, { children: r.getRowModel().rows.map((i) => /* @__PURE__ */ n.jsx(v.Tr, { children: i.getVisibleCells().map((a) => /* @__PURE__ */ n.jsx(v.Td, { children: /* @__PURE__ */ n.jsx(Ze, { children: typeof a.getValue() == "object" ? /* @__PURE__ */ n.jsx("pre", { children: JSON.stringify(a.getValue(), null, 2) }) : Wr(a.column.columnDef.cell, a.getContext()) }) }, a.id)) }, i.id)) })
37418
37424
  ] }) });
37419
37425
  }
37420
- const gP = [{
37426
+ const xP = [{
37421
37427
  label: "10",
37422
37428
  value: "10"
37423
37429
  }, {
@@ -37429,7 +37435,7 @@ const gP = [{
37429
37435
  }, {
37430
37436
  label: "100",
37431
37437
  value: "100"
37432
- }], fP = {
37438
+ }], gP = {
37433
37439
  root: {
37434
37440
  width: "150px"
37435
37441
  },
@@ -37443,7 +37449,7 @@ const gP = [{
37443
37449
  paddingLeft: "70px",
37444
37450
  paddingRight: 0
37445
37451
  }
37446
- }, bP = ({
37452
+ }, fP = ({
37447
37453
  data: e,
37448
37454
  page: t,
37449
37455
  setPage: r,
@@ -37465,8 +37471,8 @@ const gP = [{
37465
37471
  {
37466
37472
  leftSection: /* @__PURE__ */ n.jsx(S, { ta: "center", c: "dimmed", size: "xs", children: s("common.pagination.page_size") }),
37467
37473
  size: "xs",
37468
- styles: fP,
37469
- data: gP,
37474
+ styles: gP,
37475
+ data: xP,
37470
37476
  value: String(i),
37471
37477
  onChange: c
37472
37478
  }
@@ -37481,7 +37487,7 @@ const gP = [{
37481
37487
  total: o
37482
37488
  }) }) })
37483
37489
  ] });
37484
- }, yP = am(({
37490
+ }, bP = am(({
37485
37491
  data: e,
37486
37492
  loading: t
37487
37493
  }) => {
@@ -37495,7 +37501,7 @@ const gP = [{
37495
37501
  overflow: "hidden"
37496
37502
  }
37497
37503
  }, children: [
37498
- /* @__PURE__ */ n.jsx(bP, { data: e, page: r, setPage: i, limit: a, setLimit: s }),
37504
+ /* @__PURE__ */ n.jsx(fP, { data: e, page: r, setPage: i, limit: a, setLimit: s }),
37499
37505
  /* @__PURE__ */ n.jsxs(R, { sx: {
37500
37506
  width: "100%",
37501
37507
  height: "calc(100% - 42px)",
@@ -37505,10 +37511,10 @@ const gP = [{
37505
37511
  /* @__PURE__ */ n.jsx(lr, { visible: t, overlayProps: {
37506
37512
  blur: 2
37507
37513
  } }),
37508
- /* @__PURE__ */ n.jsx(xP, { data: o })
37514
+ /* @__PURE__ */ n.jsx(mP, { data: o })
37509
37515
  ] })
37510
37516
  ] }) });
37511
- }), _P = D(({
37517
+ }), yP = D(({
37512
37518
  queryModel: e
37513
37519
  }) => {
37514
37520
  const {
@@ -37518,7 +37524,7 @@ const gP = [{
37518
37524
  stateMessage: a
37519
37525
  } = e;
37520
37526
  return t === "loading" ? null : r ? /* @__PURE__ */ n.jsx(S, { mt: 10, c: "red", size: "md", ta: "center", ff: "monospace", children: r }) : i ? /* @__PURE__ */ n.jsx(S, { mt: 10, c: "red", size: "md", ta: "center", ff: "monospace", children: i }) : a ? /* @__PURE__ */ n.jsx(S, { size: "sm", mt: 10, c: "gray", ta: "center", children: a }) : null;
37521
- }), vP = D(({
37527
+ }), _P = D(({
37522
37528
  queryModel: e
37523
37529
  }) => {
37524
37530
  y();
@@ -37550,26 +37556,26 @@ const gP = [{
37550
37556
  flexGrow: 1,
37551
37557
  overflow: "hidden"
37552
37558
  }, children: [
37553
- /* @__PURE__ */ n.jsx(_P, { queryModel: e }),
37554
- /* @__PURE__ */ n.jsx(yP, { data: t, loading: i })
37559
+ /* @__PURE__ */ n.jsx(yP, { queryModel: e }),
37560
+ /* @__PURE__ */ n.jsx(bP, { data: t, loading: i })
37555
37561
  ] })
37556
37562
  ] });
37557
- }), jP = () => /* @__PURE__ */ n.jsxs("svg", { width: "14", height: "14", viewBox: "0 0 14 14", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: [
37563
+ }), vP = () => /* @__PURE__ */ n.jsxs("svg", { width: "14", height: "14", viewBox: "0 0 14 14", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: [
37558
37564
  /* @__PURE__ */ n.jsx("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M7.24335 1.62305C7.50108 1.62305 7.71001 1.83198 7.71001 2.08971L7.71001 11.423C7.71001 11.6808 7.50108 11.8897 7.24335 11.8897C6.98561 11.8897 6.77668 11.6808 6.77668 11.423L6.77668 2.08971C6.77668 1.83198 6.98561 1.62305 7.24335 1.62305Z", fill: "#3D3E45" }),
37559
37565
  /* @__PURE__ */ n.jsx("path", { d: "M9.93845 9.4786C9.80779 9.4786 9.70045 9.43893 9.61645 9.3596C9.53712 9.2756 9.49745 9.17293 9.49745 9.0516L9.49745 5.0056C9.49745 4.88427 9.53712 4.78393 9.61645 4.7046C9.70045 4.6206 9.80312 4.5786 9.92445 4.5786L12.1995 4.5786C12.3208 4.5786 12.4211 4.61827 12.5005 4.6976C12.5845 4.77227 12.6265 4.87027 12.6265 4.9916C12.6265 5.09427 12.5845 5.18527 12.5005 5.2646C12.4211 5.34393 12.3208 5.3836 12.1995 5.3836L10.3725 5.3836V6.6156H11.8845C12.0058 6.6156 12.1061 6.65527 12.1855 6.7346C12.2695 6.80927 12.3115 6.90727 12.3115 7.0286C12.3115 7.13127 12.2695 7.22227 12.1855 7.3016C12.1061 7.38093 12.0058 7.4206 11.8845 7.4206H10.3725L10.3725 9.0516C10.3725 9.17293 10.3281 9.2756 10.2395 9.3596C10.1555 9.43893 10.0551 9.4786 9.93845 9.4786Z", fill: "#3D3E45" }),
37560
37566
  /* @__PURE__ */ n.jsx("path", { d: "M3.34754 9.4786C3.21687 9.4786 3.10954 9.43893 3.02554 9.3596C2.94154 9.2756 2.89954 9.17293 2.89954 9.0516L2.89954 5.3836H1.80054C1.6792 5.3836 1.57654 5.34627 1.49254 5.2716C1.4132 5.19693 1.37354 5.09893 1.37354 4.9776C1.37354 4.85627 1.4132 4.7606 1.49254 4.6906C1.57654 4.61593 1.6792 4.5786 1.80054 4.5786H4.90854C5.02987 4.5786 5.1302 4.61593 5.20954 4.6906C5.29354 4.76527 5.33554 4.86327 5.33554 4.9846C5.33554 5.10593 5.29354 5.20393 5.20954 5.2786C5.1302 5.3486 5.02987 5.3836 4.90854 5.3836H3.80954L3.80954 9.0516C3.80954 9.17293 3.7652 9.2756 3.67654 9.3596C3.59254 9.43893 3.48287 9.4786 3.34754 9.4786Z", fill: "#3D3E45" })
37561
- ] }), wP = () => /* @__PURE__ */ n.jsxs("svg", { width: "14", height: "14", viewBox: "0 0 14 14", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: [
37567
+ ] }), jP = () => /* @__PURE__ */ n.jsxs("svg", { width: "14", height: "14", viewBox: "0 0 14 14", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: [
37562
37568
  /* @__PURE__ */ n.jsx("g", { clipPath: "url(#clip0_245_10828)", children: /* @__PURE__ */ n.jsx("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M9.91663 1.16634C9.91663 0.844175 9.65546 0.583008 9.33329 0.583008C9.01113 0.583008 8.74996 0.844175 8.74996 1.16634V1.74967L5.24996 1.74967V1.16634C5.24996 0.844175 4.98879 0.583008 4.66663 0.583008C4.34446 0.583008 4.08329 0.844175 4.08329 1.16634V1.74967H2.91663C1.95013 1.74967 1.16663 2.53318 1.16663 3.49967L1.16663 11.6663C1.16663 12.6328 1.95013 13.4163 2.91663 13.4163L11.0833 13.4163C12.0498 13.4163 12.8333 12.6328 12.8333 11.6663L12.8333 3.49967C12.8333 2.53318 12.0498 1.74967 11.0833 1.74967H9.91663V1.16634ZM11.6666 5.24967V3.49967C11.6666 3.17751 11.4055 2.91634 11.0833 2.91634H9.91663V3.49967C9.91663 3.82184 9.65546 4.08301 9.33329 4.08301C9.01113 4.08301 8.74996 3.82184 8.74996 3.49967V2.91634L5.24996 2.91634V3.49967C5.24996 3.82184 4.98879 4.08301 4.66663 4.08301C4.34446 4.08301 4.08329 3.82184 4.08329 3.49967V2.91634L2.91663 2.91634C2.59446 2.91634 2.33329 3.17751 2.33329 3.49967L2.33329 5.24967L11.6666 5.24967ZM2.33329 6.41634L11.6666 6.41634L11.6666 11.6663C11.6666 11.9885 11.4055 12.2497 11.0833 12.2497L2.91663 12.2497C2.59446 12.2497 2.33329 11.9885 2.33329 11.6663V6.41634Z", fill: "#3D3E45" }) }),
37563
37569
  /* @__PURE__ */ n.jsx("defs", { children: /* @__PURE__ */ n.jsx("clipPath", { id: "clip0_245_10828", children: /* @__PURE__ */ n.jsx("rect", { width: "14", height: "14", fill: "white" }) }) })
37564
- ] }), SP = () => /* @__PURE__ */ n.jsxs("svg", { width: "14", height: "14", viewBox: "0 0 14 14", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: [
37570
+ ] }), wP = () => /* @__PURE__ */ n.jsxs("svg", { width: "14", height: "14", viewBox: "0 0 14 14", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: [
37565
37571
  /* @__PURE__ */ n.jsx("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M3.11108 2.13932C2.78892 2.13932 2.52775 2.40049 2.52775 2.72266V10.8893C2.52775 11.2115 2.78892 11.4727 3.11108 11.4727H11.2778C11.5999 11.4727 11.8611 11.2115 11.8611 10.8893V2.72266C11.8611 2.40049 11.5999 2.13932 11.2778 2.13932H3.11108ZM1.36108 2.72266C1.36108 1.75616 2.14459 0.972656 3.11108 0.972656H11.2778C12.2442 0.972656 13.0278 1.75616 13.0278 2.72266V10.8893C13.0278 11.8558 12.2442 12.6393 11.2778 12.6393H3.11108C2.14459 12.6393 1.36108 11.8558 1.36108 10.8893V2.72266Z", fill: "#3D3E45" }),
37566
37572
  /* @__PURE__ */ n.jsx("path", { d: "M9.84418 8.37166C9.94816 8.37166 10.0348 8.40631 10.1041 8.47563C10.1734 8.54494 10.2081 8.63159 10.2081 8.73556C10.2081 8.8352 10.1734 8.91968 10.1041 8.989C10.0348 9.05398 9.94816 9.08647 9.84418 9.08647H7.63475C7.52211 9.08647 7.4333 9.05182 7.36832 8.9825C7.30334 8.91318 7.27084 8.82437 7.27084 8.71607C7.27084 8.60776 7.30983 8.51245 7.38781 8.43014L8.80445 6.91603C8.96474 6.74274 9.09038 6.56512 9.18135 6.38317C9.27666 6.20121 9.32432 6.04309 9.32432 5.90879C9.32432 5.69218 9.2615 5.51889 9.13587 5.38892C9.01023 5.25462 8.84344 5.18747 8.63549 5.18747C8.55318 5.18747 8.4687 5.20697 8.38206 5.24596C8.29541 5.28495 8.21094 5.3391 8.12862 5.40842C8.05064 5.47773 7.977 5.55788 7.90768 5.64885C7.85569 5.71817 7.80371 5.76149 7.75172 5.77882C7.69973 5.79615 7.65208 5.80481 7.60876 5.80481C7.51345 5.80481 7.42464 5.77016 7.34233 5.70084C7.26435 5.62719 7.22536 5.54271 7.22536 5.44741C7.22536 5.37376 7.24918 5.30228 7.29684 5.23296C7.34882 5.16365 7.41164 5.09216 7.48529 5.01852C7.59359 4.91021 7.7149 4.8149 7.8492 4.73259C7.98349 4.65028 8.12213 4.58746 8.26509 4.54414C8.40805 4.49648 8.54668 4.47266 8.68098 4.47266C8.97124 4.47266 9.22251 4.53114 9.43479 4.64811C9.6514 4.76075 9.81819 4.92321 9.93516 5.13549C10.0521 5.34343 10.1106 5.59037 10.1106 5.8763C10.1106 6.11457 10.0391 6.381 9.89617 6.67559C9.75754 6.96585 9.56909 7.23878 9.33081 7.49438L8.50837 8.37166H9.84418Z", fill: "#3D3E45" }),
37567
37573
  /* @__PURE__ */ n.jsx("path", { d: "M5.49994 9.08647C5.37864 9.08647 5.279 9.04965 5.20102 8.976C5.12304 8.89802 5.08405 8.80271 5.08405 8.69007V5.62518L4.70065 5.90879C4.64 5.95644 4.56418 5.98027 4.47321 5.98027C4.36923 5.98027 4.27826 5.94128 4.20028 5.8633C4.1223 5.78532 4.08331 5.69218 4.08331 5.58387C4.08331 5.44524 4.15046 5.3326 4.28475 5.24596L5.22051 4.62212C5.26384 4.59179 5.31149 4.57013 5.36348 4.55713C5.4198 4.54414 5.47178 4.53764 5.51944 4.53764C5.64507 4.53764 5.74471 4.57663 5.81836 4.65461C5.89201 4.72826 5.92883 4.8214 5.92883 4.93404V8.69007C5.92883 8.80271 5.88768 8.89802 5.80536 8.976C5.72738 9.04965 5.62558 9.08647 5.49994 9.08647Z", fill: "#3D3E45" })
37568
- ] }), CP = () => /* @__PURE__ */ n.jsxs("svg", { width: "14", height: "14", viewBox: "0 0 14 14", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: [
37574
+ ] }), SP = () => /* @__PURE__ */ n.jsxs("svg", { width: "14", height: "14", viewBox: "0 0 14 14", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: [
37569
37575
  /* @__PURE__ */ n.jsx("path", { d: "M12.0334 5.64833C12.3099 5.64833 12.55 5.67744 12.7537 5.73565C12.9623 5.79386 13.1224 5.87632 13.2339 5.98303C13.3504 6.0849 13.4086 6.20859 13.4086 6.35412C13.4086 6.45113 13.3795 6.5433 13.3213 6.63061C13.263 6.71307 13.1782 6.7543 13.0666 6.7543C12.989 6.7543 12.9235 6.7446 12.8701 6.7252C12.8216 6.70094 12.778 6.67184 12.7392 6.63788C12.7004 6.60393 12.6543 6.5724 12.6009 6.54329C12.5524 6.51419 12.4772 6.49236 12.3754 6.47781C12.2783 6.45841 12.2056 6.44871 12.1571 6.44871C11.9097 6.44871 11.6987 6.50206 11.5241 6.60878C11.3543 6.7155 11.2233 6.86102 11.1311 7.04535C11.039 7.22482 10.9929 7.43341 10.9929 7.67109C10.9929 7.90393 11.039 8.11251 11.1311 8.29684C11.2282 8.47631 11.3591 8.61941 11.5241 8.72613C11.6938 8.83284 11.8879 8.8862 12.1061 8.8862C12.2274 8.8862 12.3317 8.87893 12.419 8.86437C12.5063 8.84982 12.5791 8.82799 12.6373 8.79889C12.7052 8.76008 12.7658 8.71885 12.8192 8.6752C12.8726 8.63154 12.9526 8.60971 13.0593 8.60971C13.1854 8.60971 13.2824 8.65094 13.3504 8.7334C13.4183 8.81102 13.4522 8.90803 13.4522 9.02445C13.4522 9.14572 13.3843 9.25728 13.2485 9.35915C13.1127 9.45616 12.9332 9.5362 12.7101 9.59926C12.4918 9.65747 12.2541 9.68657 11.997 9.68657C11.6138 9.68657 11.2815 9.59926 11.0002 9.42463C10.7188 9.24516 10.5005 9.00262 10.3453 8.69702C10.1949 8.39143 10.1198 8.04945 10.1198 7.67109C10.1198 7.27333 10.1998 6.92408 10.3599 6.62333C10.5248 6.31774 10.7504 6.08005 11.0366 5.91027C11.3276 5.73565 11.6599 5.64833 12.0334 5.64833Z", fill: "#3D3E45" }),
37570
37576
  /* @__PURE__ */ n.jsx("path", { d: "M7.74826 5.64833C8.08781 5.64833 8.39099 5.73565 8.65778 5.91027C8.92942 6.08005 9.14285 6.31531 9.29807 6.61606C9.45815 6.9168 9.53819 7.26606 9.53819 7.66382C9.53819 8.06158 9.45815 8.41326 9.29807 8.71885C9.14285 9.0196 8.93184 9.25728 8.66505 9.43191C8.40311 9.60169 8.10722 9.68657 7.77737 9.68657C7.58334 9.68657 7.40143 9.65505 7.23166 9.59199C7.06188 9.52893 6.91151 9.44889 6.78054 9.35187C6.65442 9.25486 6.55498 9.15784 6.48222 9.06083C6.41431 8.95896 6.38035 8.87408 6.38035 8.80617L6.60591 8.71158V9.24273C6.60591 9.36885 6.56468 9.47557 6.48222 9.56288C6.39976 9.64534 6.29547 9.68657 6.16935 9.68657C6.04323 9.68657 5.93894 9.64534 5.85647 9.56288C5.77401 9.48042 5.73278 9.3737 5.73278 9.24273V4.67333C5.73278 4.54722 5.77401 4.44292 5.85647 4.36046C5.93894 4.27315 6.04323 4.22949 6.16935 4.22949C6.29547 4.22949 6.39976 4.27315 6.48222 4.36046C6.56468 4.44292 6.60591 4.54722 6.60591 4.67333V6.52147L6.48222 6.45598C6.48222 6.39292 6.51617 6.31774 6.58408 6.23042C6.652 6.13826 6.74416 6.04852 6.86058 5.96121C6.97699 5.86904 7.11039 5.79386 7.26076 5.73565C7.41599 5.67744 7.57849 5.64833 7.74826 5.64833ZM7.63912 6.44871C7.42569 6.44871 7.23893 6.50206 7.07886 6.60878C6.91879 6.7155 6.79267 6.86102 6.7005 7.04535C6.61319 7.22482 6.56953 7.43098 6.56953 7.66382C6.56953 7.8918 6.61319 8.10038 6.7005 8.28956C6.79267 8.47389 6.91879 8.61941 7.07886 8.72613C7.23893 8.83285 7.42569 8.8862 7.63912 8.8862C7.85255 8.8862 8.03688 8.83285 8.19211 8.72613C8.35218 8.61941 8.47587 8.47389 8.56319 8.28956C8.65535 8.10038 8.70143 7.8918 8.70143 7.66382C8.70143 7.43098 8.65535 7.22482 8.56319 7.04535C8.47587 6.86102 8.35218 6.7155 8.19211 6.60878C8.03688 6.50206 7.85255 6.44871 7.63912 6.44871Z", fill: "#3D3E45" }),
37571
37577
  /* @__PURE__ */ n.jsx("path", { d: "M3.02845 5.66289L1.45681 9.35915C1.42286 9.45131 1.3695 9.52408 1.29674 9.57743C1.22883 9.62594 1.15364 9.65019 1.07118 9.65019C0.940211 9.65019 0.843196 9.61381 0.780136 9.54105C0.717077 9.46829 0.685547 9.37855 0.685547 9.27184C0.685547 9.22818 0.692823 9.1821 0.707375 9.13359L2.51913 4.78248C2.55793 4.68546 2.61614 4.61028 2.69375 4.55692C2.77622 4.50356 2.86353 4.48173 2.95569 4.49143C3.04301 4.49143 3.12304 4.51811 3.19581 4.57147C3.27342 4.61998 3.3292 4.69031 3.36316 4.78248L5.15308 9.04628C5.17733 9.10934 5.18946 9.16755 5.18946 9.2209C5.18946 9.35187 5.1458 9.45616 5.05849 9.53378C4.97603 9.61139 4.88386 9.65019 4.782 9.65019C4.69468 9.65019 4.61465 9.62352 4.54189 9.57016C4.47398 9.5168 4.42062 9.44404 4.38181 9.35187L2.81745 5.70654L3.02845 5.66289ZM1.68237 8.47146L2.08256 7.63471H4.04711L4.18536 8.47146H1.68237Z", fill: "#3D3E45" })
37572
- ] }), kP = () => /* @__PURE__ */ n.jsxs("svg", { width: "14", height: "14", viewBox: "0 0 14 14", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: [
37578
+ ] }), CP = () => /* @__PURE__ */ n.jsxs("svg", { width: "14", height: "14", viewBox: "0 0 14 14", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: [
37573
37579
  /* @__PURE__ */ n.jsx("g", { clipPath: "url(#clip0_567_6919)", children: /* @__PURE__ */ n.jsx("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M7.00001 1.02051C7.29533 1.02051 7.53473 1.25991 7.53473 1.55523V2.99492L11.3486 5.17429C11.5152 5.2695 11.6181 5.44667 11.6181 5.63856V9.97475L13.0725 10.702C13.3366 10.834 13.4437 11.1552 13.3116 11.4194C13.1795 11.6835 12.8583 11.7906 12.5942 11.6585L11.1002 10.9115L7.26531 13.1028C7.10091 13.1968 6.8991 13.1968 6.73471 13.1028L2.89985 10.9115L1.40581 11.6585C1.14167 11.7906 0.820476 11.6835 0.688405 11.4194C0.556335 11.1552 0.663399 10.834 0.92754 10.702L2.38195 9.97475V5.63856C2.38195 5.44667 2.48477 5.2695 2.65138 5.17429L6.46529 2.99492V1.55523C6.46529 1.25991 6.70469 1.02051 7.00001 1.02051ZM7.00001 3.9211L3.99444 5.63856L7.00001 7.35603L10.0056 5.63856L7.00001 3.9211ZM10.5486 6.55999L7.53473 8.28221V11.7171L10.5486 9.99492V6.55999ZM6.46529 11.7171V8.28221L3.4514 6.55999V9.99492L6.46529 11.7171Z", fill: "#3D3E45" }) }),
37574
37580
  /* @__PURE__ */ n.jsx("defs", { children: /* @__PURE__ */ n.jsx("clipPath", { id: "clip0_567_6919", children: /* @__PURE__ */ n.jsx("rect", { width: "14", height: "14", fill: "white" }) }) })
37575
37581
  ] }), lc = ({
@@ -37577,19 +37583,19 @@ const gP = [{
37577
37583
  }) => {
37578
37584
  switch (e) {
37579
37585
  case "boolean":
37580
- return /* @__PURE__ */ n.jsx(jP, {});
37586
+ return /* @__PURE__ */ n.jsx(vP, {});
37581
37587
  case "date":
37582
- return /* @__PURE__ */ n.jsx(wP, {});
37588
+ return /* @__PURE__ */ n.jsx(jP, {});
37583
37589
  case "number":
37584
- return /* @__PURE__ */ n.jsx(SP, {});
37590
+ return /* @__PURE__ */ n.jsx(wP, {});
37585
37591
  case "string":
37586
- return /* @__PURE__ */ n.jsx(CP, {});
37592
+ return /* @__PURE__ */ n.jsx(SP, {});
37587
37593
  case "dimension":
37588
- return /* @__PURE__ */ n.jsx(kP, {});
37594
+ return /* @__PURE__ */ n.jsx(CP, {});
37589
37595
  default:
37590
37596
  return null;
37591
37597
  }
37592
- }, TP = {
37598
+ }, kP = {
37593
37599
  option: {
37594
37600
  fontFamily: "monospace",
37595
37601
  "&.sub-option": {
@@ -37635,7 +37641,7 @@ const gP = [{
37635
37641
  }
37636
37642
  }
37637
37643
  }
37638
- }, zP = {
37644
+ }, TP = {
37639
37645
  root: {
37640
37646
  maxWidth: "unset"
37641
37647
  },
@@ -37664,10 +37670,10 @@ const gP = [{
37664
37670
  }) => {
37665
37671
  const a = e.metricDetail, s = e.metrics.loading || a.loading, o = a.error, l = a.filterColOptions, c = rf({
37666
37672
  onDropdownClose: () => c.resetSelectedOption()
37667
- }), d = z(() => s ? /* @__PURE__ */ n.jsx(mo, { size: "xs" }) : t ? /* @__PURE__ */ n.jsx(In, { size: "xs", onClick: () => r(null) }) : /* @__PURE__ */ n.jsx(Yn.Chevron, { size: "xs" }), [s, t]), u = /* @__PURE__ */ n.jsx(af, { component: "button", type: "button", variant: "unstyled", size: "xs", pointer: !0, rightSection: d, rightSectionPointerEvents: !s && t ? "all" : "none", onClick: () => c.toggleDropdown(), disabled: s || l.length === 0, styles: zP, error: !!o, children: t || /* @__PURE__ */ n.jsx(sf.Placeholder, { children: "选择维度" }) });
37673
+ }), d = z(() => s ? /* @__PURE__ */ n.jsx(mo, { size: "xs" }) : t ? /* @__PURE__ */ n.jsx(In, { size: "xs", onClick: () => r(null) }) : /* @__PURE__ */ n.jsx(Yn.Chevron, { size: "xs" }), [s, t]), u = /* @__PURE__ */ n.jsx(af, { component: "button", type: "button", variant: "unstyled", size: "xs", pointer: !0, rightSection: d, rightSectionPointerEvents: !s && t ? "all" : "none", onClick: () => c.toggleDropdown(), disabled: s || l.length === 0, styles: TP, error: !!o, children: t || /* @__PURE__ */ n.jsx(sf.Placeholder, { children: "选择维度" }) });
37668
37674
  return /* @__PURE__ */ n.jsxs(Yn, { store: c, onOptionSubmit: (h) => {
37669
37675
  r(h), c.closeDropdown();
37670
- }, styles: TP, children: [
37676
+ }, styles: kP, children: [
37671
37677
  /* @__PURE__ */ n.jsx(Yn.Target, { children: o ? /* @__PURE__ */ n.jsx(ue, { label: o, children: u }) : u }),
37672
37678
  /* @__PURE__ */ n.jsx(Yn.Dropdown, { miw: 300, children: /* @__PURE__ */ n.jsx(Yn.Options, { children: l.map(({
37673
37679
  group: h,
@@ -37687,7 +37693,7 @@ const gP = [{
37687
37693
  fontFamily: "monospace"
37688
37694
  }
37689
37695
  }
37690
- }, DP = {
37696
+ }, zP = {
37691
37697
  root: {
37692
37698
  maxWidth: "unset"
37693
37699
  },
@@ -37710,7 +37716,7 @@ const gP = [{
37710
37716
  backgroundColor: "var(--mantine-color-gray-2)"
37711
37717
  }
37712
37718
  }
37713
- }, IP = ({
37719
+ }, DP = ({
37714
37720
  option: e,
37715
37721
  ...t
37716
37722
  }) => {
@@ -37772,9 +37778,9 @@ const gP = [{
37772
37778
  size: "xs",
37773
37779
  variant: "unstyled",
37774
37780
  placeholder: "选择变量",
37775
- styles: DP,
37781
+ styles: zP,
37776
37782
  data: s,
37777
- renderOption: IP,
37783
+ renderOption: DP,
37778
37784
  maxDropdownHeight: 600,
37779
37785
  value: t,
37780
37786
  onChange: o,
@@ -37794,7 +37800,7 @@ const gP = [{
37794
37800
  flexShrink: 0
37795
37801
  }
37796
37802
  }, children: /* @__PURE__ */ n.jsx(Va, {}) });
37797
- }), MP = D(({
37803
+ }), IP = D(({
37798
37804
  queryModel: e
37799
37805
  }) => {
37800
37806
  const t = e.config, i = e.datasource.mericoMetricInfo;
@@ -37840,7 +37846,7 @@ const gP = [{
37840
37846
  ] })
37841
37847
  ] })
37842
37848
  ] });
37843
- }), LP = D(({
37849
+ }), MP = D(({
37844
37850
  queryModel: e,
37845
37851
  variable: t
37846
37852
  }) => {
@@ -37851,7 +37857,7 @@ const gP = [{
37851
37857
  }), Zd = ({
37852
37858
  queryModel: e,
37853
37859
  variable: t
37854
- }) => t ? /* @__PURE__ */ n.jsx(LP, { queryModel: e, variable: t }) : null, PP = D(({
37860
+ }) => t ? /* @__PURE__ */ n.jsx(MP, { queryModel: e, variable: t }) : null, LP = D(({
37855
37861
  queryModel: e
37856
37862
  }) => {
37857
37863
  const t = e.config, s = e.datasource.mericoMetricInfo.metricDetail.trendingDateCol;
@@ -37895,7 +37901,7 @@ const gP = [{
37895
37901
  ] }, "dimension.step")
37896
37902
  ] })
37897
37903
  ] });
37898
- }), EP = D(({
37904
+ }), PP = D(({
37899
37905
  queryModel: e
37900
37906
  }) => {
37901
37907
  const t = e.config, s = e.datasource.mericoMetricInfo.metricDetail.trendingDateCol;
@@ -37905,9 +37911,9 @@ const gP = [{
37905
37911
  /* @__PURE__ */ n.jsx(ue, { label: "将看板的时间&步长筛选器与相应的查询维度关联上。", children: /* @__PURE__ */ n.jsx(oe, { size: "xs", variant: "subtle", color: "gray", children: /* @__PURE__ */ n.jsx(mt, {}) }) }),
37906
37912
  s ? /* @__PURE__ */ n.jsx(tt, { size: "xs", color: "red", checked: t.timeQuery.enabled, onChange: (o) => t.setTimeQueryEnabled(o.currentTarget.checked) }) : /* @__PURE__ */ n.jsx(ue, { label: "由于指标未设定时序维度,所以不具备时间序列展示功能。", children: /* @__PURE__ */ n.jsx(R, { children: /* @__PURE__ */ n.jsx(tt, { size: "xs", color: "red", disabled: !s }) }) })
37907
37913
  ] }),
37908
- /* @__PURE__ */ n.jsx(PP, { queryModel: e })
37914
+ /* @__PURE__ */ n.jsx(LP, { queryModel: e })
37909
37915
  ] });
37910
- }), RP = {
37916
+ }), EP = {
37911
37917
  label: {
37912
37918
  fontWeight: "normal"
37913
37919
  },
@@ -37933,7 +37939,7 @@ const gP = [{
37933
37939
  option: {
37934
37940
  fontFamily: "monospace"
37935
37941
  }
37936
- }, $P = (e) => {
37942
+ }, RP = (e) => {
37937
37943
  const t = e.option;
37938
37944
  return /* @__PURE__ */ n.jsxs(T, { gap: 1, styles: {
37939
37945
  root: {
@@ -37946,7 +37952,7 @@ const gP = [{
37946
37952
  ] }),
37947
37953
  /* @__PURE__ */ n.jsx(S, { size: "xs", c: "dimmed", pl: 18, children: t.description })
37948
37954
  ] });
37949
- }, AP = D(({
37955
+ }, $P = D(({
37950
37956
  queryModel: e
37951
37957
  }) => {
37952
37958
  const t = e.config, i = e.datasource.mericoMetricInfo, a = i.metricDetail, s = i.metrics.loading || a.loading, o = a.groupByColOptions, l = (c) => {
@@ -37957,8 +37963,8 @@ const gP = [{
37957
37963
  }) : u.push(h.value);
37958
37964
  }), t.setGroupBys(u);
37959
37965
  };
37960
- return /* @__PURE__ */ n.jsx(yr, { size: "sm", label: "分组聚合维度", description: "指标在查询时按照哪些维度进行聚合计算。最多支持两个维度的聚合计算。若选择按时间序列展示,则仅可选择一个聚合维度。", data: o, searchable: !0, styles: RP, renderOption: $P, rightSection: s ? /* @__PURE__ */ n.jsx(mo, { size: "xs" }) : null, value: [...t.groupByValues], onChange: l, maxValues: t.timeQuery.enabled ? 1 : 2, placeholder: t.timeQuery.enabled ? "仅可选一个维度" : "最多选两个维度", disabled: s });
37961
- }), OP = D(({
37966
+ return /* @__PURE__ */ n.jsx(yr, { size: "sm", label: "分组聚合维度", description: "指标在查询时按照哪些维度进行聚合计算。最多支持两个维度的聚合计算。若选择按时间序列展示,则仅可选择一个聚合维度。", data: o, searchable: !0, styles: EP, renderOption: RP, rightSection: s ? /* @__PURE__ */ n.jsx(mo, { size: "xs" }) : null, value: [...t.groupByValues], onChange: l, maxValues: t.timeQuery.enabled ? 1 : 2, placeholder: t.timeQuery.enabled ? "仅可选一个维度" : "最多选两个维度", disabled: s });
37967
+ }), AP = D(({
37962
37968
  queryModel: e
37963
37969
  }) => {
37964
37970
  const t = e.config, r = t.id;
@@ -37971,19 +37977,19 @@ const gP = [{
37971
37977
  }), e.setRunBy(i);
37972
37978
  }, [t.usedFilterVariableSet, t.usedTimeQueryVariableSet, e.run_by]), /* @__PURE__ */ n.jsxs(T, { gap: 16, pos: "relative", children: [
37973
37979
  !r && /* @__PURE__ */ n.jsx(or, { color: "#fff", backgroundOpacity: 0.5, blur: 3, children: /* @__PURE__ */ n.jsx(Qn, { h: "100%", children: /* @__PURE__ */ n.jsx(S, { size: "sm", c: "black", children: "请先选择指标" }) }) }),
37974
- /* @__PURE__ */ n.jsx(MP, { queryModel: e }),
37975
- /* @__PURE__ */ n.jsx(EP, { queryModel: e }),
37976
- /* @__PURE__ */ n.jsx(AP, { queryModel: e })
37980
+ /* @__PURE__ */ n.jsx(IP, { queryModel: e }),
37981
+ /* @__PURE__ */ n.jsx(PP, { queryModel: e }),
37982
+ /* @__PURE__ */ n.jsx($P, { queryModel: e })
37977
37983
  ] });
37978
- }), VP = D(({
37984
+ }), OP = D(({
37979
37985
  queryModel: e
37980
37986
  }) => (e.config, /* @__PURE__ */ n.jsx(T, { children: /* @__PURE__ */ n.jsx(xn, { language: "json", sx: {
37981
37987
  width: "100%",
37982
37988
  height: "100%",
37983
37989
  minHeight: "400px",
37984
37990
  overflowY: "auto"
37985
- }, withCopyButton: !1, code: e.metricQueryPayloadString }) }))), FP = ["function process_result(resp, utils, state) {", " return resp.data", "}"].join(`
37986
- `), NP = {
37991
+ }, withCopyButton: !1, code: e.metricQueryPayloadString }) }))), VP = ["function process_result(resp, utils, state) {", " return resp.data", "}"].join(`
37992
+ `), FP = {
37987
37993
  root: {
37988
37994
  minHeight: "350px",
37989
37995
  maxHeight: "50vh",
@@ -37999,23 +38005,23 @@ const gP = [{
37999
38005
  height: "calc(100% - 36px)",
38000
38006
  overflowY: "auto"
38001
38007
  }
38002
- }, qP = D(({
38008
+ }, NP = D(({
38003
38009
  queryModel: e
38004
38010
  }) => {
38005
38011
  const [t, r] = K("编辑查询");
38006
- return /* @__PURE__ */ n.jsxs(j, { color: "red", defaultValue: "编辑查询", styles: NP, value: t, onChange: r, children: [
38012
+ return /* @__PURE__ */ n.jsxs(j, { color: "red", defaultValue: "编辑查询", styles: FP, value: t, onChange: r, children: [
38007
38013
  /* @__PURE__ */ n.jsxs(j.List, { children: [
38008
38014
  /* @__PURE__ */ n.jsx(j.Tab, { value: "编辑查询", size: "xs", children: "编辑查询" }),
38009
38015
  /* @__PURE__ */ n.jsx(j.Tab, { value: "加工结果", size: "xs", children: "加工结果" }),
38010
38016
  /* @__PURE__ */ n.jsx(j.Tab, { value: "使用情况", size: "xs", children: "使用情况" }),
38011
38017
  /* @__PURE__ */ n.jsx(j.Tab, { value: "预览查询", size: "xs", leftSection: /* @__PURE__ */ n.jsx(ko, { size: 14 }), ml: "auto", children: "预览查询" })
38012
38018
  ] }),
38013
- /* @__PURE__ */ n.jsx(j.Panel, { value: "编辑查询", pt: "xs", children: /* @__PURE__ */ n.jsx(OP, { queryModel: e }) }),
38014
- /* @__PURE__ */ n.jsx(j.Panel, { value: "加工结果", pt: "xs", children: /* @__PURE__ */ n.jsx(kr, { label: "", value: e.post_process, onChange: e.setPostProcess, defaultValue: FP }) }),
38019
+ /* @__PURE__ */ n.jsx(j.Panel, { value: "编辑查询", pt: "xs", children: /* @__PURE__ */ n.jsx(AP, { queryModel: e }) }),
38020
+ /* @__PURE__ */ n.jsx(j.Panel, { value: "加工结果", pt: "xs", children: /* @__PURE__ */ n.jsx(kr, { label: "", value: e.post_process, onChange: e.setPostProcess, defaultValue: VP }) }),
38015
38021
  /* @__PURE__ */ n.jsx(j.Panel, { value: "使用情况", pt: "xs", children: /* @__PURE__ */ n.jsx(yg, { queryModel: e }) }),
38016
- /* @__PURE__ */ n.jsx(j.Panel, { value: "预览查询", pt: "xs", children: /* @__PURE__ */ n.jsx(VP, { queryModel: e }) })
38022
+ /* @__PURE__ */ n.jsx(j.Panel, { value: "预览查询", pt: "xs", children: /* @__PURE__ */ n.jsx(OP, { queryModel: e }) })
38017
38023
  ] });
38018
- }), BP = D(() => {
38024
+ }), qP = D(() => {
38019
38025
  const e = we();
38020
38026
  return /* @__PURE__ */ n.jsxs(T, { styles: {
38021
38027
  root: {
@@ -38035,7 +38041,7 @@ const gP = [{
38035
38041
  overflowY: "auto"
38036
38042
  }, withCopyButton: !1, code: e.queryVariablesString })
38037
38043
  ] });
38038
- }), HP = D(({
38044
+ }), BP = D(({
38039
38045
  queryModel: e
38040
38046
  }) => {
38041
38047
  const t = e.metricQueryPayloadError;
@@ -38043,7 +38049,7 @@ const gP = [{
38043
38049
  /* @__PURE__ */ n.jsx(He.Target, { children: /* @__PURE__ */ n.jsx(R, { children: /* @__PURE__ */ n.jsx(L, { size: "xs", leftSection: /* @__PURE__ */ n.jsx(Ud, { width: 14, height: 14, color: "rgb(173, 181, 189)" }), variant: "filled", color: "red", disabled: !0, children: "执行查询" }) }) }),
38044
38050
  /* @__PURE__ */ n.jsx(He.Dropdown, { children: /* @__PURE__ */ n.jsx(Dt, { size: "xs", children: t.map((r) => /* @__PURE__ */ n.jsx(Dt.Item, { children: r }, r)) }) })
38045
38051
  ] }) : /* @__PURE__ */ n.jsx(L, { size: "xs", leftSection: /* @__PURE__ */ n.jsx(Ud, { width: 14, height: 14 }), variant: "filled", color: "red", onClick: () => e.fetchData(!0), children: "执行查询" });
38046
- }), QP = ({
38052
+ }), HP = ({
38047
38053
  option: e,
38048
38054
  ...t
38049
38055
  }) => {
@@ -38067,7 +38073,7 @@ const gP = [{
38067
38073
  ] }),
38068
38074
  /* @__PURE__ */ n.jsx(S, { ml: 16, size: "xs", c: t.checked ? "rgba(255,255,255,.8)" : "dimmed", children: r.description })
38069
38075
  ] });
38070
- }, GP = D(({
38076
+ }, QP = D(({
38071
38077
  queryModel: e
38072
38078
  }) => {
38073
38079
  const t = e.config, i = e.datasource.mericoMetricInfo, a = i.metrics;
@@ -38091,14 +38097,14 @@ const gP = [{
38091
38097
  root: {
38092
38098
  flexGrow: 1
38093
38099
  }
38094
- } }) }) : /* @__PURE__ */ n.jsx(N, { size: "xs", label: "指标", data: s, renderOption: QP, styles: {
38100
+ } }) }) : /* @__PURE__ */ n.jsx(N, { size: "xs", label: "指标", data: s, renderOption: HP, styles: {
38095
38101
  root: {
38096
38102
  flexGrow: 1
38097
38103
  }
38098
38104
  }, maxDropdownHeight: 500, value: t.id, onChange: o, rightSection: l ? /* @__PURE__ */ n.jsx(mo, { size: "xs" }) : null }),
38099
- /* @__PURE__ */ n.jsx(ue, { label: "跳转到指标明细页查看详情。", disabled: l, children: /* @__PURE__ */ n.jsx(Ti, { size: "md", variant: "subtle", mb: 2, href: `/admin/metrics/detail/${t.id}`, target: "_blank", underline: "never", children: /* @__PURE__ */ n.jsx(dP, { width: 14, height: 14 }) }) })
38105
+ /* @__PURE__ */ n.jsx(ue, { label: "跳转到指标明细页查看详情。", disabled: l, children: /* @__PURE__ */ n.jsx(Ti, { size: "md", variant: "subtle", mb: 2, href: `/admin/metrics/detail/${t.id}`, target: "_blank", underline: "never", children: /* @__PURE__ */ n.jsx(cP, { width: 14, height: 14 }) }) })
38100
38106
  ] }) });
38101
- }), WP = D(({
38107
+ }), GP = D(({
38102
38108
  queryModel: e
38103
38109
  }) => {
38104
38110
  const {
@@ -38131,11 +38137,11 @@ const gP = [{
38131
38137
  }, children: [
38132
38138
  /* @__PURE__ */ n.jsxs(b, { justify: "flex-start", grow: !0, gap: 24, align: "flex-end", children: [
38133
38139
  /* @__PURE__ */ n.jsx(fg, { queryModel: e, size: "xs" }),
38134
- /* @__PURE__ */ n.jsx(GP, { queryModel: e })
38140
+ /* @__PURE__ */ n.jsx(QP, { queryModel: e })
38135
38141
  ] }),
38136
38142
  /* @__PURE__ */ n.jsxs(b, { justify: "flex-end", children: [
38137
- /* @__PURE__ */ n.jsx(HP, { queryModel: e }),
38138
- /* @__PURE__ */ n.jsx(pP, { queryModel: e })
38143
+ /* @__PURE__ */ n.jsx(BP, { queryModel: e }),
38144
+ /* @__PURE__ */ n.jsx(hP, { queryModel: e })
38139
38145
  ] })
38140
38146
  ] }),
38141
38147
  /* @__PURE__ */ n.jsxs(b, { justify: "space-between", grow: !0, gap: 12, align: "flex-start", sx: {
@@ -38143,22 +38149,22 @@ const gP = [{
38143
38149
  flexShrink: 1,
38144
38150
  overflowY: "hidden"
38145
38151
  }, children: [
38146
- /* @__PURE__ */ n.jsx(qP, { queryModel: e }),
38147
- /* @__PURE__ */ n.jsx(BP, {})
38152
+ /* @__PURE__ */ n.jsx(NP, { queryModel: e }),
38153
+ /* @__PURE__ */ n.jsx(qP, {})
38148
38154
  ] }),
38149
- /* @__PURE__ */ n.jsx(vP, { queryModel: e })
38155
+ /* @__PURE__ */ n.jsx(_P, { queryModel: e })
38150
38156
  ] });
38151
- }), UP = D(({
38157
+ }), WP = D(({
38152
38158
  id: e
38153
38159
  }) => {
38154
38160
  const r = je().queries.findByID(e);
38155
- return e === "" ? null : r ? r.isMericoMetricQuery ? /* @__PURE__ */ n.jsx(WP, { queryModel: r }) : /* @__PURE__ */ n.jsx(cP, { queryModel: r }) : /* @__PURE__ */ n.jsx(S, { size: "14px", c: "red", children: "Invalid Query ID" });
38156
- }), YP = D(({
38161
+ return e === "" ? null : r ? r.isMericoMetricQuery ? /* @__PURE__ */ n.jsx(GP, { queryModel: r }) : /* @__PURE__ */ n.jsx(lP, { queryModel: r }) : /* @__PURE__ */ n.jsx(S, { size: "14px", c: "red", children: "Invalid Query ID" });
38162
+ }), UP = D(({
38157
38163
  value: e
38158
38164
  }) => {
38159
38165
  const r = Je().payloadForSQL, i = z(() => Mo(e, r), [e, r]);
38160
38166
  return /* @__PURE__ */ n.jsx(_l, { height: "100%", value: i });
38161
- }), KP = D(({
38167
+ }), YP = D(({
38162
38168
  item: e,
38163
38169
  remove: t,
38164
38170
  onKeyChanged: r
@@ -38222,10 +38228,10 @@ const gP = [{
38222
38228
  }, children: /* @__PURE__ */ n.jsx(Oe, { size: 18 }) })
38223
38229
  ] }),
38224
38230
  /* @__PURE__ */ n.jsx(j.Panel, { value: "SQL", pt: "sm", children: /* @__PURE__ */ n.jsx(_l, { height: "100%", value: h, onChange: m, defaultLanguage: "sql", theme: "sql-dark" }) }),
38225
- /* @__PURE__ */ n.jsx(j.Panel, { value: "Preview", pt: "sm", children: /* @__PURE__ */ n.jsx(YP, { value: h }) })
38231
+ /* @__PURE__ */ n.jsx(j.Panel, { value: "Preview", pt: "sm", children: /* @__PURE__ */ n.jsx(UP, { value: h }) })
38226
38232
  ] })
38227
38233
  ] });
38228
- }), XP = D(({
38234
+ }), KP = D(({
38229
38235
  id: e
38230
38236
  }) => {
38231
38237
  const t = we(), r = je(), i = z(() => r.sqlSnippets.findByKey(e), [e]);
@@ -38244,8 +38250,8 @@ const gP = [{
38244
38250
  }, o = (l) => {
38245
38251
  t.editor.setPath(["_SQL_SNIPPETS_", l]);
38246
38252
  };
38247
- return /* @__PURE__ */ n.jsx(KP, { item: i, remove: s, onKeyChanged: o });
38248
- }), ZP = D(() => {
38253
+ return /* @__PURE__ */ n.jsx(YP, { item: i, remove: s, onKeyChanged: o });
38254
+ }), XP = D(() => {
38249
38255
  const {
38250
38256
  t: e
38251
38257
  } = y(), [t, r] = K([]), i = fn(), a = we(), s = (m) => {
@@ -38341,9 +38347,9 @@ const gP = [{
38341
38347
  }) })
38342
38348
  ] }) }) })
38343
38349
  ] });
38344
- }), JP = D(({
38350
+ }), ZP = D(({
38345
38351
  view: e
38346
- }) => !e || e.type !== J.Division ? null : /* @__PURE__ */ n.jsx(T, {})), eE = D(({
38352
+ }) => !e || e.type !== J.Division ? null : /* @__PURE__ */ n.jsx(T, {})), JP = D(({
38347
38353
  view: e
38348
38354
  }) => {
38349
38355
  const {
@@ -38374,7 +38380,7 @@ const gP = [{
38374
38380
  /* @__PURE__ */ n.jsx(N, { label: t("common.tabs.orientation.label"), value: s.orientation, onChange: s.setOrientation, data: a }),
38375
38381
  /* @__PURE__ */ n.jsx(tt, { label: t("common.tabs.grow_tabs"), checked: s.grow, onChange: (o) => s.setGrow(o.currentTarget.checked) })
38376
38382
  ] });
38377
- }), tE = ({
38383
+ }), eE = ({
38378
38384
  disabled: e,
38379
38385
  value: t,
38380
38386
  onChange: r
@@ -38393,7 +38399,7 @@ const gP = [{
38393
38399
  readOnly: e
38394
38400
  } })
38395
38401
  ] });
38396
- }, nE = ({
38402
+ }, tE = ({
38397
38403
  value: e,
38398
38404
  onChange: t
38399
38405
  }) => {
@@ -38433,7 +38439,7 @@ const gP = [{
38433
38439
  }, children: /* @__PURE__ */ n.jsx(Zr, { size: 14 }) }),
38434
38440
  /* @__PURE__ */ n.jsx(Ge, { size: 800, title: r("view.component.modal.custom_title"), opened: i, onClose: s, closeOnClickOutside: !1, withCloseButton: !1, zIndex: 320, children: i && /* @__PURE__ */ n.jsxs(T, { children: [
38435
38441
  /* @__PURE__ */ n.jsx(he, { mt: 10, label: r("common.enabled"), checked: o.enabled, onChange: (g) => c(g.currentTarget.checked) }),
38436
- /* @__PURE__ */ n.jsx(tE, { value: o.func_content, onChange: h, disabled: !o.enabled }),
38442
+ /* @__PURE__ */ n.jsx(eE, { value: o.func_content, onChange: h, disabled: !o.enabled }),
38437
38443
  /* @__PURE__ */ n.jsxs(b, { justify: "space-between", children: [
38438
38444
  /* @__PURE__ */ n.jsx(L, { onClick: m, color: "red", leftSection: /* @__PURE__ */ n.jsx(nn, { size: 20 }), children: r("common.actions.revert") }),
38439
38445
  /* @__PURE__ */ n.jsxs(b, { justify: "flex-end", children: [
@@ -38443,7 +38449,7 @@ const gP = [{
38443
38449
  ] })
38444
38450
  ] }) })
38445
38451
  ] });
38446
- }, rE = D(({
38452
+ }, nE = D(({
38447
38453
  view: e
38448
38454
  }) => {
38449
38455
  const {
@@ -38458,20 +38464,20 @@ const gP = [{
38458
38464
  /* @__PURE__ */ n.jsx(E, { label: t("view.component.modal.title"), value: i, onChange: w.noop, disabled: !0, sx: {
38459
38465
  flexGrow: 1
38460
38466
  } }),
38461
- /* @__PURE__ */ n.jsx(nE, { value: r.custom_modal_title, onChange: r.custom_modal_title.replace })
38467
+ /* @__PURE__ */ n.jsx(tE, { value: r.custom_modal_title, onChange: r.custom_modal_title.replace })
38462
38468
  ] }),
38463
38469
  /* @__PURE__ */ n.jsxs(b, { grow: !0, children: [
38464
38470
  /* @__PURE__ */ n.jsx(E, { label: t("view.component.modal.width"), value: r.width, onChange: (a) => r.setWidth(a.currentTarget.value), placeholder: "600px / 50vw" }),
38465
38471
  /* @__PURE__ */ n.jsx(E, { label: t("view.component.modal.height"), value: r.height, onChange: (a) => r.setHeight(a.currentTarget.value), placeholder: "600px / 50vw" })
38466
38472
  ] })
38467
38473
  ] });
38468
- }), iE = D(({
38474
+ }), rE = D(({
38469
38475
  view: e
38470
38476
  }) => /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
38471
- /* @__PURE__ */ n.jsx(JP, { view: e }),
38472
- /* @__PURE__ */ n.jsx(rE, { view: e }),
38473
- /* @__PURE__ */ n.jsx(eE, { view: e })
38474
- ] })), aE = D(({
38477
+ /* @__PURE__ */ n.jsx(ZP, { view: e }),
38478
+ /* @__PURE__ */ n.jsx(nE, { view: e }),
38479
+ /* @__PURE__ */ n.jsx(JP, { view: e })
38480
+ ] })), iE = D(({
38475
38481
  view: e
38476
38482
  }) => {
38477
38483
  const {
@@ -38497,9 +38503,9 @@ const gP = [{
38497
38503
  withinPortal: !0,
38498
38504
  zIndex: 320
38499
38505
  }, value: e.type, onChange: e.setType, data: i }),
38500
- /* @__PURE__ */ n.jsx(iE, { view: e })
38506
+ /* @__PURE__ */ n.jsx(rE, { view: e })
38501
38507
  ] }) : null;
38502
- }), sE = D(({
38508
+ }), aE = D(({
38503
38509
  id: e
38504
38510
  }) => {
38505
38511
  const {
@@ -38542,14 +38548,14 @@ const gP = [{
38542
38548
  flexGrow: 1,
38543
38549
  maxHeight: "calc(100% - 52px)",
38544
38550
  overflow: "auto"
38545
- }, children: /* @__PURE__ */ n.jsx(aE, { view: s }) })
38551
+ }, children: /* @__PURE__ */ n.jsx(iE, { view: s }) })
38546
38552
  ] });
38547
- }), oE = D(() => /* @__PURE__ */ n.jsx(T, { sx: {
38553
+ }), sE = D(() => /* @__PURE__ */ n.jsx(T, { sx: {
38548
38554
  height: "100%"
38549
- }, p: "sm", children: /* @__PURE__ */ n.jsx(bg, {}) })), lE = D(() => {
38555
+ }, p: "sm", children: /* @__PURE__ */ n.jsx(bg, {}) })), oE = D(() => {
38550
38556
  const e = we().editor, t = e.path;
38551
- return bM(t) ? /* @__PURE__ */ n.jsx(oE, {}) : yM(t) ? /* @__PURE__ */ n.jsx(XL, {}) : _M(t) ? /* @__PURE__ */ n.jsx(KL, {}) : vM(t) ? /* @__PURE__ */ n.jsx(R, { p: "xs", pl: 20, children: /* @__PURE__ */ n.jsx(YL, { id: t[1] }) }) : jM(t) ? /* @__PURE__ */ n.jsx(ZP, {}) : wM(t) ? /* @__PURE__ */ n.jsx(XP, { id: t[1] }) : CM(t) ? /* @__PURE__ */ n.jsx(I9, {}) : SM(t) ? /* @__PURE__ */ n.jsx(UP, { id: t[1] }) : kM(t) ? /* @__PURE__ */ n.jsx(R, { p: "xs", pl: 20, children: /* @__PURE__ */ n.jsx(sE, { id: t[1] }) }) : oo(t) ? /* @__PURE__ */ n.jsx(D9, { viewID: t[1], panelID: t[3] }) : /* @__PURE__ */ n.jsx(R, { children: e.path });
38552
- }), cE = D(() => /* @__PURE__ */ n.jsx(lE, {})), dE = D(() => {
38557
+ return fM(t) ? /* @__PURE__ */ n.jsx(sE, {}) : bM(t) ? /* @__PURE__ */ n.jsx(KL, {}) : yM(t) ? /* @__PURE__ */ n.jsx(YL, {}) : _M(t) ? /* @__PURE__ */ n.jsx(R, { p: "xs", pl: 20, children: /* @__PURE__ */ n.jsx(UL, { id: t[1] }) }) : vM(t) ? /* @__PURE__ */ n.jsx(XP, {}) : jM(t) ? /* @__PURE__ */ n.jsx(KP, { id: t[1] }) : SM(t) ? /* @__PURE__ */ n.jsx(D9, {}) : wM(t) ? /* @__PURE__ */ n.jsx(WP, { id: t[1] }) : CM(t) ? /* @__PURE__ */ n.jsx(R, { p: "xs", pl: 20, children: /* @__PURE__ */ n.jsx(aE, { id: t[1] }) }) : oo(t) ? /* @__PURE__ */ n.jsx(z9, { viewID: t[1], panelID: t[3] }) : /* @__PURE__ */ n.jsx(R, { children: e.path });
38558
+ }), lE = D(() => /* @__PURE__ */ n.jsx(oE, {})), cE = D(() => {
38553
38559
  const {
38554
38560
  t: e
38555
38561
  } = y(), t = we(), r = () => {
@@ -38573,7 +38579,7 @@ const gP = [{
38573
38579
  justifyContent: "flex-start"
38574
38580
  }
38575
38581
  }, children: e("filter.add") });
38576
- }), uE = D(({
38582
+ }), dE = D(({
38577
38583
  parentID: e
38578
38584
  }) => {
38579
38585
  const {
@@ -38590,7 +38596,7 @@ const gP = [{
38590
38596
  justifyContent: "flex-start"
38591
38597
  }
38592
38598
  }, children: t("panel.add") });
38593
- }), hE = D(() => {
38599
+ }), uE = D(() => {
38594
38600
  const {
38595
38601
  t: e
38596
38602
  } = y(), t = we(), r = () => {
@@ -38614,7 +38620,7 @@ const gP = [{
38614
38620
  justifyContent: "flex-start"
38615
38621
  }
38616
38622
  }, children: e("query.add") });
38617
- }), pE = D(() => {
38623
+ }), hE = D(() => {
38618
38624
  const {
38619
38625
  t: e
38620
38626
  } = y(), t = we(), r = () => {
@@ -38632,7 +38638,7 @@ const gP = [{
38632
38638
  justifyContent: "flex-start"
38633
38639
  }
38634
38640
  }, children: e("sql_snippet.add") });
38635
- }), mE = D(() => {
38641
+ }), pE = D(() => {
38636
38642
  const {
38637
38643
  t: e
38638
38644
  } = y(), t = je();
@@ -38644,7 +38650,7 @@ const gP = [{
38644
38650
  justifyContent: "flex-start"
38645
38651
  }
38646
38652
  }, children: e("view.add") });
38647
- }), xE = D(() => {
38653
+ }), mE = D(() => {
38648
38654
  const {
38649
38655
  t: e
38650
38656
  } = y(), t = we();
@@ -38657,7 +38663,7 @@ const gP = [{
38657
38663
  justifyContent: "space-between"
38658
38664
  }
38659
38665
  }, children: e("query.manage") });
38660
- }), gE = D(() => {
38666
+ }), xE = D(() => {
38661
38667
  const {
38662
38668
  t: e
38663
38669
  } = y(), t = we();
@@ -38670,7 +38676,7 @@ const gP = [{
38670
38676
  justifyContent: "space-between"
38671
38677
  }
38672
38678
  }, children: e("sql_snippet.manage") });
38673
- }), fE = D(() => {
38679
+ }), gE = D(() => {
38674
38680
  const {
38675
38681
  t: e
38676
38682
  } = y(), t = we();
@@ -38683,10 +38689,10 @@ const gP = [{
38683
38689
  justifyContent: "space-between"
38684
38690
  }
38685
38691
  }, children: e("filter.manage") });
38686
- }), bE = D(({
38692
+ }), fE = D(({
38687
38693
  action_type: e,
38688
38694
  parentID: t
38689
- }) => e === "_Add_A_Filter_" ? /* @__PURE__ */ n.jsx(dE, {}) : e === "_Add_A_SQL_SNIPPET_" ? /* @__PURE__ */ n.jsx(pE, {}) : e === "_Add_A_QUERY_" ? /* @__PURE__ */ n.jsx(hE, {}) : e === "_Add_A_VIEW_" ? /* @__PURE__ */ n.jsx(mE, {}) : e === "_Add_A_PANEL_" ? /* @__PURE__ */ n.jsx(uE, { parentID: t }) : e === "_QUERIES_SETTINGS_" ? /* @__PURE__ */ n.jsx(xE, {}) : e === "_SQL_SNIPPETS_SETTINGS_" ? /* @__PURE__ */ n.jsx(gE, {}) : e === "_FILTERS_SETTINGS_" ? /* @__PURE__ */ n.jsx(fE, {}) : null), vg = D(({
38695
+ }) => e === "_Add_A_Filter_" ? /* @__PURE__ */ n.jsx(cE, {}) : e === "_Add_A_SQL_SNIPPET_" ? /* @__PURE__ */ n.jsx(hE, {}) : e === "_Add_A_QUERY_" ? /* @__PURE__ */ n.jsx(uE, {}) : e === "_Add_A_VIEW_" ? /* @__PURE__ */ n.jsx(pE, {}) : e === "_Add_A_PANEL_" ? /* @__PURE__ */ n.jsx(dE, { parentID: t }) : e === "_QUERIES_SETTINGS_" ? /* @__PURE__ */ n.jsx(mE, {}) : e === "_SQL_SNIPPETS_SETTINGS_" ? /* @__PURE__ */ n.jsx(xE, {}) : e === "_FILTERS_SETTINGS_" ? /* @__PURE__ */ n.jsx(gE, {}) : null), vg = D(({
38690
38696
  option: e
38691
38697
  }) => {
38692
38698
  var u;
@@ -38695,13 +38701,13 @@ const gP = [{
38695
38701
  } = y(), r = we().editor, i = r.isOptionActive, a = i(r.path, e), s = r.isOptionOpened, o = r.navigate, l = s(e), [c, d] = K(l);
38696
38702
  return H(() => {
38697
38703
  d(l);
38698
- }, [l]), /* @__PURE__ */ n.jsx(Rs, { active: a, defaultOpened: l, opened: c, onChange: d, label: t(e.label), onClick: () => o(e), leftSection: e.Icon ? /* @__PURE__ */ n.jsx(e.Icon, { size: 18 }) : null, children: (u = e.children) == null ? void 0 : u.map((h) => h._type === "ACTION" ? /* @__PURE__ */ n.jsx(bE, { action_type: h._action_type, parentID: h.parentID }, `_ADD_${h.value}_`) : /* @__PURE__ */ n.jsx(vg, { option: h }, h.value)) }, e.label);
38699
- }), yE = D(() => {
38704
+ }, [l]), /* @__PURE__ */ n.jsx(Rs, { active: a, defaultOpened: l, opened: c, onChange: d, label: t(e.label), onClick: () => o(e), leftSection: e.Icon ? /* @__PURE__ */ n.jsx(e.Icon, { size: 18 }) : null, children: (u = e.children) == null ? void 0 : u.map((h) => h._type === "ACTION" ? /* @__PURE__ */ n.jsx(fE, { action_type: h._action_type, parentID: h.parentID }, `_ADD_${h.value}_`) : /* @__PURE__ */ n.jsx(vg, { option: h }, h.value)) }, e.label);
38705
+ }), bE = D(() => {
38700
38706
  const e = we();
38701
38707
  return /* @__PURE__ */ n.jsx(R, { sx: {
38702
38708
  position: "relative"
38703
38709
  }, children: e.editor.navOptions.map((t) => /* @__PURE__ */ n.jsx(vg, { option: t }, t.value)) });
38704
- }), _E = D(() => {
38710
+ }), yE = D(() => {
38705
38711
  const {
38706
38712
  t: e
38707
38713
  } = y(), t = we();
@@ -38720,12 +38726,12 @@ const gP = [{
38720
38726
  }, children: e("common.titles.settings") }) }),
38721
38727
  /* @__PURE__ */ n.jsx($t.Section, { grow: !0, sx: {
38722
38728
  overflow: "auto"
38723
- }, children: /* @__PURE__ */ n.jsx(yE, {}) }),
38729
+ }, children: /* @__PURE__ */ n.jsx(bE, {}) }),
38724
38730
  /* @__PURE__ */ n.jsx($t.Section, { children: /* @__PURE__ */ n.jsx(b, { grow: !0, p: "md", pt: "sm", sx: {
38725
38731
  borderTop: "1px solid #eee"
38726
38732
  }, children: /* @__PURE__ */ n.jsx(L, { size: "xs", color: "red", leftSection: /* @__PURE__ */ n.jsx(bo, { size: 18 }), onClick: () => t.editor.close(), children: e("common.actions.close") }) }) })
38727
38733
  ] });
38728
- }), vE = {
38734
+ }), _E = {
38729
38735
  root: {
38730
38736
  height: "100vh",
38731
38737
  display: "flex",
@@ -38747,7 +38753,7 @@ const gP = [{
38747
38753
  paddingTop: 0,
38748
38754
  height: "100vh"
38749
38755
  }
38750
- }, jE = D(() => {
38756
+ }, vE = D(() => {
38751
38757
  const e = we().editor;
38752
38758
  return /* @__PURE__ */ n.jsx(Ge, { onClose: () => e.setSettingsOpen(!1), closeOnEscape: !1, closeOnClickOutside: !1, opened: e.settings_open, fullScreen: !0, title: null, transitionProps: {
38753
38759
  duration: 0
@@ -38770,17 +38776,17 @@ const gP = [{
38770
38776
  },
38771
38777
  breakpoint: "xxs"
38772
38778
  //FIXME(leto): not sure
38773
- }, styles: vE, children: [
38774
- /* @__PURE__ */ n.jsx(_E, {}),
38775
- /* @__PURE__ */ n.jsx($t.Main, { children: /* @__PURE__ */ n.jsx(cE, {}) })
38779
+ }, styles: _E, children: [
38780
+ /* @__PURE__ */ n.jsx(yE, {}),
38781
+ /* @__PURE__ */ n.jsx($t.Main, { children: /* @__PURE__ */ n.jsx(lE, {}) })
38776
38782
  ] }) });
38777
- }), wE = (e) => e.replace(/([^:])(\/\/+)/g, "$1/");
38778
- function SE(e) {
38783
+ }), jE = (e) => e.replace(/([^:])(\/\/+)/g, "$1/");
38784
+ function wE(e) {
38779
38785
  H(() => {
38780
38786
  if (_s.__getMonacoInstance())
38781
38787
  return;
38782
38788
  console.log("loading monaco for @devtable/dashboard");
38783
- const r = wE(e);
38789
+ const r = jE(e);
38784
38790
  _s.config({
38785
38791
  paths: {
38786
38792
  vs: r
@@ -38790,7 +38796,7 @@ function SE(e) {
38790
38796
  }
38791
38797
  ph();
38792
38798
  sm();
38793
- const CE = {
38799
+ const SE = {
38794
38800
  root: {
38795
38801
  height: "100vh",
38796
38802
  display: "flex",
@@ -38809,7 +38815,7 @@ const CE = {
38809
38815
  // main header & sub header
38810
38816
  height: "100vh"
38811
38817
  }
38812
- }, kE = ({
38818
+ }, CE = ({
38813
38819
  context: e,
38814
38820
  dashboard: t,
38815
38821
  content: r,
@@ -38823,12 +38829,12 @@ const CE = {
38823
38829
  onExit: u,
38824
38830
  lang: h
38825
38831
  }, m) => {
38826
- SE(s.monacoPath), Ku(s);
38832
+ wE(s.monacoPath), Ku(s);
38827
38833
  const {
38828
38834
  data: g = []
38829
38835
  } = _r(jl), {
38830
38836
  data: x = []
38831
- } = _r(om), _ = B.useMemo(() => AM(t, r, g, x, e, c ?? {}), [t, r]);
38837
+ } = _r(om), _ = B.useMemo(() => $M(t, r, g, x, e, c ?? {}), [t, r]);
38832
38838
  B.useImperativeHandle(m, () => _, [_]), sg(_.content, !0), B.useEffect(() => {
38833
38839
  _.context.replace(e);
38834
38840
  }, [e]), B.useEffect(() => {
@@ -38863,7 +38869,7 @@ const CE = {
38863
38869
  }, children: /* @__PURE__ */ n.jsx(Zu, { value: _, children: /* @__PURE__ */ n.jsx(rh, { value: _.content, children: /* @__PURE__ */ n.jsxs(Eo.Provider, { value: {
38864
38870
  inEditMode: !0
38865
38871
  }, children: [
38866
- /* @__PURE__ */ n.jsx(sL, {}),
38872
+ /* @__PURE__ */ n.jsx(aL, {}),
38867
38873
  /* @__PURE__ */ n.jsx(Un.Provider, { value: k, children: /* @__PURE__ */ n.jsxs(ds, { configure: M, children: [
38868
38874
  /* @__PURE__ */ n.jsxs($t, { padding: 0, navbar: {
38869
38875
  width: {
@@ -38876,17 +38882,17 @@ const CE = {
38876
38882
  },
38877
38883
  breakpoint: "xxs"
38878
38884
  //FIXME(leto): not sure
38879
- }, styles: CE, children: [
38880
- /* @__PURE__ */ n.jsx(dL, { onExit: u, saveDashboardChanges: I, headerSlot: l }),
38881
- /* @__PURE__ */ n.jsx(AL, {}),
38885
+ }, styles: SE, children: [
38886
+ /* @__PURE__ */ n.jsx(cL, { onExit: u, saveDashboardChanges: I, headerSlot: l }),
38887
+ /* @__PURE__ */ n.jsx($L, {}),
38882
38888
  /* @__PURE__ */ n.jsx($t.Main, { children: /* @__PURE__ */ n.jsx(R, { className: `${a} dashboard-root`, sx: {
38883
38889
  position: "relative"
38884
38890
  }, children: _.content.views.visibleViews.map((P) => /* @__PURE__ */ n.jsx(Y8, { view: P }, P.id)) }) })
38885
38891
  ] }),
38886
- /* @__PURE__ */ n.jsx(jE, {})
38892
+ /* @__PURE__ */ n.jsx(vE, {})
38887
38893
  ] }) })
38888
38894
  ] }) }) }) }) }) }) }) });
38889
- }, P$ = D(le(kE));
38895
+ }, L$ = D(le(CE));
38890
38896
  const jg = p.model({
38891
38897
  id: p.string,
38892
38898
  name: p.string,
@@ -38990,7 +38996,7 @@ const jg = p.model({
38990
38996
  // setupAutoSave();
38991
38997
  // },
38992
38998
  }));
38993
- function TE({
38999
+ function kE({
38994
39000
  id: e,
38995
39001
  name: t,
38996
39002
  dashboard_id: r,
@@ -39033,7 +39039,7 @@ function TE({
39033
39039
  }
39034
39040
  });
39035
39041
  }
39036
- const zE = p.model({
39042
+ const TE = p.model({
39037
39043
  id: p.identifier,
39038
39044
  name: p.string,
39039
39045
  group: p.string,
@@ -39043,18 +39049,18 @@ const zE = p.model({
39043
39049
  globalSQLSnippets: kx,
39044
39050
  context: nc
39045
39051
  });
39046
- function DE({
39052
+ function zE({
39047
39053
  id: e,
39048
39054
  name: t,
39049
39055
  group: r,
39050
39056
  content_id: i
39051
39057
  }, a, s, o, l, c, d) {
39052
- return zE.create({
39058
+ return TE.create({
39053
39059
  id: e,
39054
39060
  name: t,
39055
39061
  group: r,
39056
39062
  content_id: i,
39057
- content: TE(a, l, c, d),
39063
+ content: kE(a, l, c, d),
39058
39064
  datasources: {
39059
39065
  list: s
39060
39066
  },
@@ -39066,7 +39072,7 @@ function DE({
39066
39072
  }
39067
39073
  ph();
39068
39074
  sm();
39069
- const IE = ({
39075
+ const DE = ({
39070
39076
  context: e,
39071
39077
  dashboard: t,
39072
39078
  content: r,
@@ -39085,7 +39091,7 @@ const IE = ({
39085
39091
  data: m = []
39086
39092
  } = _r(jl), {
39087
39093
  data: g = []
39088
- } = _r(om), x = B.useMemo(() => DE(t, r, m, g, e, l ?? {}, d ?? null), [t, r, d]);
39094
+ } = _r(om), x = B.useMemo(() => zE(t, r, m, g, e, l ?? {}, d ?? null), [t, r, d]);
39089
39095
  sg(x.content, !1), B.useEffect(() => {
39090
39096
  x.context.replace(e);
39091
39097
  }, [e]), B.useEffect(() => {
@@ -39123,7 +39129,7 @@ const IE = ({
39123
39129
  }, children: /* @__PURE__ */ n.jsx(Eo.Provider, { value: {
39124
39130
  inEditMode: !1
39125
39131
  }, children: /* @__PURE__ */ n.jsx(R, { className: `${i} dashboard-root`, children: /* @__PURE__ */ n.jsx(Un.Provider, { value: _, children: /* @__PURE__ */ n.jsx(ds, { configure: I, children: x.content.views.visibleViews.map((k) => /* @__PURE__ */ n.jsx(ic, { view: k }, k.id)) }) }) }) }) }) }) }) }) }) }) }) });
39126
- }, E$ = D(IE);
39132
+ }, P$ = D(DE);
39127
39133
  F.extend(Xb);
39128
39134
  F.extend(Zb);
39129
39135
  F.extend(Jb);
@@ -39161,7 +39167,7 @@ F.tz.setDefault("UTC");
39161
39167
  F.updateLocale("en", {
39162
39168
  weekStart: 1
39163
39169
  });
39164
- const R$ = () => Promise.resolve().then(() => C0).then(({
39170
+ const E$ = () => Promise.resolve().then(() => C0).then(({
39165
39171
  version: e
39166
39172
  }) => (console.log(`[@devtable/dashboard] version: ${e}`), e));
39167
39173
  export {
@@ -39174,12 +39180,12 @@ export {
39174
39180
  so as DEFAULT_CUSTOM_MODAL_TITLE,
39175
39181
  Wy as DashboardApiClient,
39176
39182
  Uy as DashboardApiFacadeClient,
39177
- P$ as DashboardEditor,
39183
+ L$ as DashboardEditor,
39178
39184
  ee as DashboardFilterType,
39179
39185
  K8 as DashboardMode,
39180
- $M as DashboardModel,
39186
+ RM as DashboardModel,
39181
39187
  Zu as DashboardModelContextProvider,
39182
- zE as DashboardRenderModel,
39188
+ TE as DashboardRenderModel,
39183
39189
  th as DashboardThemeContextProvider,
39184
39190
  Y8 as DashboardViewEditor,
39185
39191
  ic as DashboardViewRender,
@@ -39191,7 +39197,7 @@ export {
39191
39197
  Gx as DescriptionPopover,
39192
39198
  BI as DraftModel,
39193
39199
  J as EViewComponentType,
39194
- C$ as FacadeApiClient,
39200
+ S$ as FacadeApiClient,
39195
39201
  sx as FilterCheckboxConfigMeta,
39196
39202
  dx as FilterDateRangeConfigMeta,
39197
39203
  vx as FilterMeta,
@@ -39217,44 +39223,44 @@ export {
39217
39223
  sh as PanelContextProvider,
39218
39224
  v8 as PanelErrorOrStateMessage,
39219
39225
  Y6 as PanelMeta,
39220
- IM as PanelModel,
39226
+ DM as PanelModel,
39221
39227
  Jx as PanelRender,
39222
39228
  Lx as PanelRenderModel,
39223
39229
  Q6 as PanelStyleMeta,
39224
39230
  G6 as PanelTitleMeta,
39225
39231
  U6 as PanelVizMeta,
39226
39232
  Xx as PanelVizSection,
39227
- MM as PanelsModel,
39233
+ IM as PanelsModel,
39228
39234
  Px as PanelsRenderModel,
39229
39235
  tM as QueriesModel,
39230
39236
  Nx as QueriesRenderModel,
39231
39237
  eI as QueryMeta,
39232
39238
  eM as QueryModel,
39233
39239
  Fx as QueryRenderModel,
39234
- E$ as ReadOnlyDashboard,
39240
+ P$ as ReadOnlyDashboard,
39235
39241
  rI as SQLSnippetMeta,
39236
39242
  NI as SQLSnippetRenderModel,
39237
39243
  nM as SQLSnippetsModel,
39238
39244
  Bx as SQLSnippetsRenderModel,
39239
39245
  W6 as VariableMeta,
39240
39246
  X8 as ViewComponentTypeBackground,
39241
- M$ as ViewComponentTypeColor,
39242
- I$ as ViewComponentTypeName,
39247
+ I$ as ViewComponentTypeColor,
39248
+ D$ as ViewComponentTypeName,
39243
39249
  jx as ViewDivisionConfig,
39244
39250
  LI as ViewMeta,
39245
39251
  wx as ViewModalConfig,
39246
39252
  zx as ViewRenderModel,
39247
39253
  Sx as ViewTabsConfig,
39248
- PM as ViewsModel,
39254
+ LM as ViewsModel,
39249
39255
  Dx as ViewsRenderModel,
39250
39256
  _8 as Viz,
39251
- L$ as applyPartialDashboard,
39257
+ M$ as applyPartialDashboard,
39252
39258
  Ku as configureAPIClient,
39253
- RM as createContentModel,
39254
- TE as createContentRenderModel,
39259
+ EM as createContentModel,
39260
+ kE as createContentRenderModel,
39255
39261
  Tx as createContextMeta,
39256
- AM as createDashboardModel,
39257
- DE as createDashboardRenderModel,
39262
+ $M as createDashboardModel,
39263
+ zE as createDashboardRenderModel,
39258
39264
  HI as createDraft,
39259
39265
  iI as createFilterCheckboxConfig,
39260
39266
  oI as createFilterDateRangeConfig,
@@ -39277,8 +39283,8 @@ export {
39277
39283
  RI as getInitialViewsRenderModel,
39278
39284
  AI as getNewPanel,
39279
39285
  aI as getStaticDateRangeDefaultValue,
39280
- R$ as getVersion,
39281
- D$ as initialDashboardContent,
39286
+ E$ as getVersion,
39287
+ z$ as initialDashboardContent,
39282
39288
  Ju as useDashboardContext,
39283
39289
  s_ as useDashboardThemeContext,
39284
39290
  je as useEditContentModelContext,