react-semaphor 0.1.571 → 0.1.573

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (42) hide show
  1. package/dist/assistant-context/index.js +1 -1
  2. package/dist/assistant-protocol/index.js +62 -59
  3. package/dist/briefings/index.js +1 -1
  4. package/dist/chunks/{model-change-T1cRkh3m.js → add-to-dashboard-B6Ah8Lub.js} +121 -84
  5. package/dist/chunks/{assistant-chat-SkCraw2C.js → assistant-chat-D95DtCj7.js} +2398 -2300
  6. package/dist/chunks/{bookmark-impact-DCYD-6Fr.js → bookmark-impact-DUWw3wlA.js} +2 -2
  7. package/dist/chunks/{bookmark-state-CflS88gq.js → bookmark-state-BEl_G9vr.js} +54 -54
  8. package/dist/chunks/{card-filter-builder-D-aSYpyr.js → card-filter-builder-B3bEPylu.js} +54 -54
  9. package/dist/chunks/{dashboard-B_w_ekUz.js → dashboard-DdALjmc3.js} +1 -1
  10. package/dist/chunks/{dashboard-briefing-launcher-_g1m2tJ3.js → dashboard-briefing-launcher-D2vevpyl.js} +923 -956
  11. package/dist/chunks/{dashboard-controls-CY0gbcCt.js → dashboard-controls-DxrsGK9A.js} +103 -103
  12. package/dist/chunks/{dashboard-json-DsM79yem.js → dashboard-json-rwds0HjB.js} +1 -1
  13. package/dist/chunks/{dates-RSEzJ9N7.js → dates-DlYMDaF2.js} +5 -5
  14. package/dist/chunks/{edit-dashboard-visual-cX0FM-4i.js → edit-dashboard-visual-BCDz5HOb.js} +1354 -1317
  15. package/dist/chunks/{filter-reach-copy-thzt25Rc.js → filter-reach-copy-BTAXnbwQ.js} +9 -9
  16. package/dist/chunks/{index-y3HUzRNk.js → index-8BxDk8EP.js} +2 -2
  17. package/dist/chunks/{report-preferences-dialog-B_GXs91t.js → report-preferences-dialog-D9nBczmk.js} +725 -801
  18. package/dist/chunks/{resolve-dashboard-input-context-Lkbwycwe.js → resolve-dashboard-input-context-DBFuNhZo.js} +3961 -3923
  19. package/dist/chunks/{saved-dashboard-context-DC_TEd6y.js → saved-dashboard-context-AChHk4tw.js} +3 -3
  20. package/dist/chunks/{semaphor-ready-indicator-CBQamwQY.js → semaphor-ready-indicator-BdOAS4Uw.js} +25293 -24700
  21. package/dist/chunks/{shelf-drop-preview-context-Bkjf0XXw.js → shelf-drop-preview-context-B1goDUYE.js} +259 -259
  22. package/dist/chunks/{stored-dashboard-C0hekXiI.js → stored-dashboard-rpLzf4mk.js} +231 -231
  23. package/dist/chunks/{variable-draft-DvglU8yj.js → variable-draft-DPSMDwqt.js} +2 -2
  24. package/dist/dashboard/index.js +2 -2
  25. package/dist/dashboard-authoring/index.js +1381 -1368
  26. package/dist/index.js +147 -147
  27. package/dist/style.css +1 -1
  28. package/dist/surfboard/index.js +2 -2
  29. package/dist/types/components/dashboard/summary-card.d.ts +5 -0
  30. package/dist/types/index.js +1 -1
  31. package/dist/types/lib/formatters/kpi-number-formatter.d.ts +12 -0
  32. package/dist/types/lib/types/explorer-types.d.ts +6 -0
  33. package/dist/types/shared/assistant-protocol/model-change.d.ts +52 -1
  34. package/dist/types/shared/assistant-protocol/parts.d.ts +49 -2
  35. package/dist/types/shared/dashboard-authoring/card-settings/card-display-write.d.ts +5 -0
  36. package/dist/types/shared/dashboard-authoring/card-settings/card-kinds.d.ts +1 -1
  37. package/dist/types/shared/dashboard-authoring/card-settings/inputs.d.ts +2 -0
  38. package/dist/types/shared/dashboard-authoring/card-settings/resolved.d.ts +2 -0
  39. package/dist/types/shared/dashboard-authoring/changes/card-query-part.d.ts +1 -0
  40. package/dist/types/shared/dashboard-authoring/changes/dashboard-change.d.ts +4 -0
  41. package/dist/types/shared/dashboard-authoring/kpi-figure.d.ts +38 -0
  42. package/package.json +1 -1
@@ -1,18 +1,18 @@
1
- import { gX as co, cB as uo, c1 as fo, aT as po, bd as mo, f as go, bV as yo, N as oe, gY as bo, gZ as Ne, e6 as Rt, e9 as ho, bM as Co, g_ as Io, au as vo, fO as Kt, fQ as Fo, bx as Le, g$ as qt, P as So, fS as To, d0 as Fe, s as _, fJ as Se, n as je, h0 as Do, cW as Nt, cY as Lt, cH as Mo, c$ as Vo, cZ as bt, c_ as ko, b as xo, cJ as Po, cV as wo, cT as Oo, bA as jt, a4 as q, gl as Ao, h1 as Te, h2 as zt, h3 as Eo, h4 as ze, gA as De, h5 as Bo, h6 as Ge, h7 as _o, h8 as Ro, h9 as Ko, ha as qo, hb as No, l as He, hc as Lo, k as ee, r as jo, h as zo, hd as U, gO as $e, he as ge, hf as Gt, hg as Go, J as Ho, hh as $o, hi as Uo, fI as Qo, hj as Wo, hk as Yo, e as Jo, hl as Zo, hm as Ht, a0 as $t, hn as Xo, ho as er, hp as tr, hq as Ut, j as Ue, cs as nr, a5 as or, o as Qt, cr as rr, gx as ir, q as sr, t as ht, C as ar, hr as lr, hs as cr, ct as ur, ht as dr } from "./resolve-dashboard-input-context-Lkbwycwe.js";
1
+ import { g$ as co, cC as uo, c2 as fo, aU as po, be as mo, f as go, bW as yo, N as oe, h0 as bo, h1 as Ne, e8 as Rt, eb as ho, bN as Co, h2 as Io, av as vo, fS as Kt, fU as Fo, by as Le, h3 as qt, P as So, fW as To, d1 as Fe, s as _, fN as Se, n as je, h4 as Do, cX as Nt, cZ as Lt, cI as Mo, d0 as Vo, c_ as bt, c$ as ko, b as Po, cK as xo, cW as wo, cU as Oo, bB as jt, a4 as q, gp as Eo, h5 as Te, h6 as zt, h7 as Ao, h8 as ze, gE as De, h9 as Bo, ha as Ge, hb as _o, hc as Ro, hd as Ko, he as qo, hf as No, l as He, hg as Lo, k as ee, r as jo, h as zo, hh as $, gS as Ue, hi as ge, hj as Gt, hk as Go, J as Ho, hl as Uo, hm as $o, fM as Qo, hn as Wo, ho as Jo, e as Yo, hp as Zo, hq as Ht, a0 as Ut, hr as Xo, hs as er, ht as tr, hu as $t, j as $e, ct as nr, a5 as or, o as Qt, cs as rr, gB as ir, q as sr, t as ht, C as ar, hv as lr, hw as cr, cu as ur, hx as dr } from "./resolve-dashboard-input-context-DBFuNhZo.js";
2
2
  import { ak as fr, a5 as re, J as pr, v as mr, aw as Oe, w as gr, a7 as Ct, ay as Wt, U as yr, r as br } from "./validators-B8fpdinG.js";
3
- import { q as Yt } from "./matrix-operation-contract-DCVinw1o.js";
3
+ import { q as Jt } from "./matrix-operation-contract-DCVinw1o.js";
4
4
  import { S as Qe } from "./analytics-base-schemas-BaIQrEzX.js";
5
5
  import "./pickers-DkqmtnTL.js";
6
- import { canonicalizeSupportedCurrencyCode as Jt } from "../value-format-preferences/index.js";
6
+ import { canonicalizeSupportedCurrencyCode as Yt } from "../value-format-preferences/index.js";
7
7
  import { ZodError as hr } from "zod";
8
8
  import { b as ye, r as Cr, aW as Ir, i as vr, aD as Fr, aA as It } from "./temporal-input-presentation-CqbJjIuu.js";
9
- import { aB as Zt, aC as Xt, aD as ke, $ as Sr, aE as en, aF as tn, aA as nn, aG as on, n as Tr, l as Dr, v as rn, t as j, aH as sn, k as an, C as Ae, aI as H, z as ie, i as ln, o as Mr, u as Vr, B as We, aJ as kr, ah as xr, F as cn, D as Pr, az as vt, N as un, O as dn, I as fn } from "./bookmark-state-CflS88gq.js";
9
+ import { aB as Zt, aC as Xt, aD as ke, a0 as Sr, aE as en, aF as tn, aA as nn, aG as on, n as Tr, l as Dr, v as rn, t as j, aH as sn, k as an, C as Ee, aI as H, z as ie, i as ln, o as Mr, u as Vr, B as We, aJ as kr, ai as Pr, F as cn, D as xr, J as vt, O as un, P as dn, I as fn } from "./bookmark-state-BEl_G9vr.js";
10
10
  import "./schema-C9NPiIru.js";
11
11
  import "./index-CV_Kzou0.js";
12
12
  import "./context-R31TSL5V.js";
13
13
  import { D as wr } from "./report-runtime-context-BhPzLTbS.js";
14
14
  import { r as Q, C as Or } from "./metric-comparison-n9NsIa-2.js";
15
- import { p as Ar, d as Er } from "./pivot-result-contract-expectations-C-HnUKYe.js";
15
+ import { p as Er, d as Ar } from "./pivot-result-contract-expectations-C-HnUKYe.js";
16
16
  import { isPdfTableCardType as Br, PDF_CAPACITY as _r } from "../pdf-export-policy/index.js";
17
17
  import { c as Rr } from "./selection-filter-compiler-CUDRnUxc.js";
18
18
  import { a as Kr, h as qr, s as Nr } from "./matrix-analytical-definition-dkS8szLM.js";
@@ -32,7 +32,7 @@ const jr = (e, t) => {
32
32
  continue;
33
33
  }
34
34
  const i = e[r], s = t[r];
35
- if (!Ee(i, s))
35
+ if (!Ae(i, s))
36
36
  if (Array.isArray(i) && Array.isArray(s))
37
37
  n[r] = s;
38
38
  else if (Ft(i) && Ft(s)) {
@@ -42,13 +42,13 @@ const jr = (e, t) => {
42
42
  n[r] = s;
43
43
  }
44
44
  return n;
45
- }, Ee = (e, t) => {
45
+ }, Ae = (e, t) => {
46
46
  if (e === t) return !0;
47
47
  if (e && t && typeof e == "object" && typeof t == "object") {
48
48
  if (Array.isArray(e) && Array.isArray(t))
49
- return e.length !== t.length ? !1 : e.every((r, i) => Ee(r, t[i]));
49
+ return e.length !== t.length ? !1 : e.every((r, i) => Ae(r, t[i]));
50
50
  const n = Object.keys(e), o = Object.keys(t);
51
- return n.length !== o.length ? !1 : n.every((r) => Ee(e[r], t[r]));
51
+ return n.length !== o.length ? !1 : n.every((r) => Ae(e[r], t[r]));
52
52
  }
53
53
  return !1;
54
54
  }, Ft = (e) => e !== null && typeof e == "object" && !Array.isArray(e), be = (e) => {
@@ -75,18 +75,18 @@ function Hr(e) {
75
75
  const n = new Uint8Array(16);
76
76
  return n[0] = (t = parseInt(e.slice(0, 8), 16)) >>> 24, n[1] = t >>> 16 & 255, n[2] = t >>> 8 & 255, n[3] = t & 255, n[4] = (t = parseInt(e.slice(9, 13), 16)) >>> 8, n[5] = t & 255, n[6] = (t = parseInt(e.slice(14, 18), 16)) >>> 8, n[7] = t & 255, n[8] = (t = parseInt(e.slice(19, 23), 16)) >>> 8, n[9] = t & 255, n[10] = (t = parseInt(e.slice(24, 36), 16)) / 1099511627776 & 255, n[11] = t / 4294967296 & 255, n[12] = t >>> 24 & 255, n[13] = t >>> 16 & 255, n[14] = t >>> 8 & 255, n[15] = t & 255, n;
77
77
  }
78
- function $r(e) {
78
+ function Ur(e) {
79
79
  e = unescape(encodeURIComponent(e));
80
80
  const t = [];
81
81
  for (let n = 0; n < e.length; ++n)
82
82
  t.push(e.charCodeAt(n));
83
83
  return t;
84
84
  }
85
- const Ur = "6ba7b810-9dad-11d1-80b4-00c04fd430c8", Qr = "6ba7b811-9dad-11d1-80b4-00c04fd430c8";
85
+ const $r = "6ba7b810-9dad-11d1-80b4-00c04fd430c8", Qr = "6ba7b811-9dad-11d1-80b4-00c04fd430c8";
86
86
  function Wr(e, t, n) {
87
87
  function o(r, i, s, a) {
88
88
  var c;
89
- if (typeof r == "string" && (r = $r(r)), typeof i == "string" && (i = Hr(i)), ((c = i) === null || c === void 0 ? void 0 : c.length) !== 16)
89
+ if (typeof r == "string" && (r = Ur(r)), typeof i == "string" && (i = Hr(i)), ((c = i) === null || c === void 0 ? void 0 : c.length) !== 16)
90
90
  throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");
91
91
  let l = new Uint8Array(16 + r.length);
92
92
  if (l.set(i), l.set(r, i.length), l = n(l), l[6] = l[6] & 15 | t, l[8] = l[8] & 63 | 128, s) {
@@ -101,9 +101,9 @@ function Wr(e, t, n) {
101
101
  o.name = e;
102
102
  } catch {
103
103
  }
104
- return o.DNS = Ur, o.URL = Qr, o;
104
+ return o.DNS = $r, o.URL = Qr, o;
105
105
  }
106
- function Yr(e, t, n, o) {
106
+ function Jr(e, t, n, o) {
107
107
  switch (e) {
108
108
  case 0:
109
109
  return t & n ^ ~t & o;
@@ -115,10 +115,10 @@ function Yr(e, t, n, o) {
115
115
  return t ^ n ^ o;
116
116
  }
117
117
  }
118
- function xe(e, t) {
118
+ function Pe(e, t) {
119
119
  return e << t | e >>> 32 - t;
120
120
  }
121
- function Jr(e) {
121
+ function Yr(e) {
122
122
  const t = [1518500249, 1859775393, 2400959708, 3395469782], n = [1732584193, 4023233417, 2562383102, 271733878, 3285377520];
123
123
  if (typeof e == "string") {
124
124
  const s = unescape(encodeURIComponent(e));
@@ -140,17 +140,17 @@ function Jr(e) {
140
140
  for (let m = 0; m < 16; ++m)
141
141
  a[m] = i[s][m];
142
142
  for (let m = 16; m < 80; ++m)
143
- a[m] = xe(a[m - 3] ^ a[m - 8] ^ a[m - 14] ^ a[m - 16], 1);
143
+ a[m] = Pe(a[m - 3] ^ a[m - 8] ^ a[m - 14] ^ a[m - 16], 1);
144
144
  let c = n[0], l = n[1], u = n[2], d = n[3], f = n[4];
145
145
  for (let m = 0; m < 80; ++m) {
146
- const g = Math.floor(m / 20), p = xe(c, 5) + Yr(g, l, u, d) + f + t[g] + a[m] >>> 0;
147
- f = d, d = u, u = xe(l, 30) >>> 0, l = c, c = p;
146
+ const g = Math.floor(m / 20), p = Pe(c, 5) + Jr(g, l, u, d) + f + t[g] + a[m] >>> 0;
147
+ f = d, d = u, u = Pe(l, 30) >>> 0, l = c, c = p;
148
148
  }
149
149
  n[0] = n[0] + c >>> 0, n[1] = n[1] + l >>> 0, n[2] = n[2] + u >>> 0, n[3] = n[3] + d >>> 0, n[4] = n[4] + f >>> 0;
150
150
  }
151
151
  return [n[0] >> 24 & 255, n[0] >> 16 & 255, n[0] >> 8 & 255, n[0] & 255, n[1] >> 24 & 255, n[1] >> 16 & 255, n[1] >> 8 & 255, n[1] & 255, n[2] >> 24 & 255, n[2] >> 16 & 255, n[2] >> 8 & 255, n[2] & 255, n[3] >> 24 & 255, n[3] >> 16 & 255, n[3] >> 8 & 255, n[3] & 255, n[4] >> 24 & 255, n[4] >> 16 & 255, n[4] >> 8 & 255, n[4] & 255];
152
152
  }
153
- const Zr = Wr("v5", 80, Jr), St = /\[\[\s*param\.([A-Za-z0-9_.-]+)\s*\]\]/g, Tt = /\bparam\s*\(\s*(['"])([^'"]+)\1/g;
153
+ const Zr = Wr("v5", 80, Yr), St = /\[\[\s*param\.([A-Za-z0-9_.-]+)\s*\]\]/g, Tt = /\bparam\s*\(\s*(['"])([^'"]+)\1/g;
154
154
  function Xr(e) {
155
155
  const t = [];
156
156
  let n = 0;
@@ -185,7 +185,7 @@ function pn(e) {
185
185
  }
186
186
  return Array.from(t);
187
187
  }
188
- function Ye(e) {
188
+ function Je(e) {
189
189
  const t = /* @__PURE__ */ new Set(), n = /* @__PURE__ */ new Map();
190
190
  for (const o of e.controlBindings || [])
191
191
  t.add(o.controlId), o.target === "sql_param" && n.set(o.paramId, o.controlId);
@@ -433,7 +433,7 @@ function gi(e, t, n, o) {
433
433
  const r = [...e], [i] = r.splice(t, 1), s = o === "before" ? n > t ? n - 1 : n : n > t ? n : n + 1;
434
434
  return r.splice(s, 0, i), r;
435
435
  }
436
- function Pe(e, t, n) {
436
+ function xe(e, t, n) {
437
437
  if (!(e != null && e.length)) return null;
438
438
  const o = e.findIndex(
439
439
  (i) => n(i).includes(t.draggingColumnId)
@@ -454,7 +454,7 @@ function sl(e, t, n) {
454
454
  return e.type === "detailTable" ? we(
455
455
  o,
456
456
  "detailColumns",
457
- Pe(
457
+ xe(
458
458
  o == null ? void 0 : o.detailColumns,
459
459
  t,
460
460
  (r) => me(r, "detail", n)
@@ -462,7 +462,7 @@ function sl(e, t, n) {
462
462
  ) : we(
463
463
  o,
464
464
  "groupByColumns",
465
- Pe(
465
+ xe(
466
466
  o == null ? void 0 : o.groupByColumns,
467
467
  t,
468
468
  (r) => me(r, "groupby", n)
@@ -470,7 +470,7 @@ function sl(e, t, n) {
470
470
  ) ?? we(
471
471
  o,
472
472
  "metricColumns",
473
- Pe(
473
+ xe(
474
474
  o == null ? void 0 : o.metricColumns,
475
475
  t,
476
476
  (r) => me(r, "metric", n)
@@ -558,7 +558,7 @@ function Ci(e) {
558
558
  metricId: e.metricId
559
559
  });
560
560
  }
561
- function Je(e) {
561
+ function Ye(e) {
562
562
  var s;
563
563
  const t = (s = e.resultColumn) == null ? void 0 : s.pivotIdentity, n = e.card.config.pivotByColumns || [];
564
564
  if (!t || n.length === 0 || t.members.length !== n.length || t.members.some(
@@ -594,13 +594,13 @@ function Ii(e) {
594
594
  } = e;
595
595
  if (!W(n) || n.type !== "table")
596
596
  return;
597
- const a = Je({
597
+ const a = Ye({
598
598
  resultColumn: r == null ? void 0 : r.find((I) => I.key === t),
599
599
  card: n,
600
600
  columnKeyMap: o
601
601
  });
602
602
  if (!a) return;
603
- const { identity: c, pivotFields: l, authoredMetrics: u, authoredMetric: d } = a, m = Ar({
603
+ const { identity: c, pivotFields: l, authoredMetrics: u, authoredMetric: d } = a, m = Er({
604
604
  members: c.members,
605
605
  resolveTemporalFormat: (I) => {
606
606
  var v;
@@ -680,7 +680,7 @@ function vi(e, t) {
680
680
  (p) => p.pivotIdentity && n.includes(p.key)
681
681
  );
682
682
  if (c.some(
683
- (p) => !Je({
683
+ (p) => !Ye({
684
684
  resultColumn: p,
685
685
  card: o,
686
686
  columnKeyMap: r
@@ -855,7 +855,7 @@ function ki(e) {
855
855
  const t = (n = e == null ? void 0 : e.numberFormat) == null ? void 0 : n.style;
856
856
  return t === void 0 || t === "decimal" || t === "currency";
857
857
  }
858
- function xi(e, t) {
858
+ function Pi(e, t) {
859
859
  const n = t == null ? void 0 : t.type;
860
860
  if (n && n !== "none" && n !== "number")
861
861
  return { currencyBindable: !1 };
@@ -869,7 +869,7 @@ function xi(e, t) {
869
869
  currencyBindable: Ie(a)
870
870
  };
871
871
  }
872
- function Pi(e, t) {
872
+ function xi(e, t) {
873
873
  const n = ye(t.format, {
874
874
  preserveOmittedProperties: !0
875
875
  }), o = re(t.dataType) === "number" ? { type: "number" } : void 0, r = n || o;
@@ -971,13 +971,13 @@ function Mt(e) {
971
971
  return [
972
972
  ...new Map(
973
973
  e.map((t) => [
974
- $(t),
974
+ U(t),
975
975
  t
976
976
  ])
977
977
  ).values()
978
978
  ];
979
979
  }
980
- function Ai(e, t = [], n) {
980
+ function Ei(e, t = [], n) {
981
981
  var D;
982
982
  const o = !!((D = e.sql) != null && D.trim()), r = Kt(e.type), i = o && r && e.type !== "kpi" && e.type !== "matrixTable", s = wi(e), a = So(e), c = !o && e.type === "kpi" ? s.map(
983
983
  (C) => Be(e, {
@@ -994,8 +994,8 @@ function Ai(e, t = [], n) {
994
994
  measureId: C.measureId
995
995
  })
996
996
  ), f = l.filter((C) => {
997
- var w, A;
998
- return ((w = C.canonical) == null ? void 0 : w.type) === "number" || ((A = C.canonical) == null ? void 0 : A.type) === "currency";
997
+ var w, E;
998
+ return ((w = C.canonical) == null ? void 0 : w.type) === "number" || ((E = C.canonical) == null ? void 0 : E.type) === "currency";
999
999
  }).map(
1000
1000
  (C) => ({
1001
1001
  kind: "matrix_measure",
@@ -1004,10 +1004,10 @@ function Ai(e, t = [], n) {
1004
1004
  ), m = e.type === "matrixTable" ? [] : e.type === "kpi" ? c.filter((C) => C.currencyBindable).flatMap(
1005
1005
  (C) => C.target ? [C.target] : []
1006
1006
  ) : (o || !r ? [] : s).filter(
1007
- (C) => (To(e.type) ? xi(
1007
+ (C) => (To(e.type) ? Pi(
1008
1008
  C,
1009
1009
  Oi(a, C)
1010
- ) : Pi(e, C)).currencyBindable
1010
+ ) : xi(e, C)).currencyBindable
1011
1011
  ).map(
1012
1012
  (C) => ({
1013
1013
  kind: "metric",
@@ -1059,10 +1059,10 @@ function ul(e) {
1059
1059
  var t;
1060
1060
  return (t = e.card.sql) != null && t.trim() ? { kind: "column", columnKey: e.columnKey } : e.metricId ? { kind: "metric", metricId: e.metricId } : void 0;
1061
1061
  }
1062
- function $(e) {
1062
+ function U(e) {
1063
1063
  return e.kind === "metric" ? `metric:${e.metricId}` : e.kind === "column" ? `column:${e.columnKey}` : `matrix_measure:${e.measureId}`;
1064
1064
  }
1065
- function Ei(e) {
1065
+ function Ai(e) {
1066
1066
  if (!e || typeof e != "object" || Array.isArray(e))
1067
1067
  return;
1068
1068
  const t = e;
@@ -1074,7 +1074,7 @@ function Ei(e) {
1074
1074
  return { kind: "matrix_measure", measureId: t.measureId };
1075
1075
  }
1076
1076
  function Vt(e) {
1077
- const t = Jt(e);
1077
+ const t = Yt(e);
1078
1078
  return typeof e == "string" && e === t ? t : void 0;
1079
1079
  }
1080
1080
  function Dn(e) {
@@ -1125,7 +1125,7 @@ function fl(e) {
1125
1125
  return Mn({
1126
1126
  ...e,
1127
1127
  referencedControlIds: new Set(
1128
- Ye({
1128
+ Je({
1129
1129
  sql: e.filterSql,
1130
1130
  controlBindings: []
1131
1131
  })
@@ -1137,7 +1137,7 @@ function pl(e) {
1137
1137
  return Mn({
1138
1138
  ...e,
1139
1139
  referencedControlIds: new Set(
1140
- Ye({
1140
+ Je({
1141
1141
  sql: (t = e.source) == null ? void 0 : t.sql,
1142
1142
  controlBindings: []
1143
1143
  })
@@ -1147,10 +1147,10 @@ function pl(e) {
1147
1147
  function Vn(e) {
1148
1148
  return {
1149
1149
  knownKeys: new Set(
1150
- e.knownTargets.map($)
1150
+ e.knownTargets.map(U)
1151
1151
  ),
1152
1152
  eligibleKeys: new Set(
1153
- e.eligibleTargets.map($)
1153
+ e.eligibleTargets.map(U)
1154
1154
  ),
1155
1155
  controlsById: new Map(
1156
1156
  (e.controls || []).map((t) => [t.id, t])
@@ -1163,14 +1163,14 @@ function kn(e, t) {
1163
1163
  const n = e, o = typeof n.controlId == "string" && n.controlId.trim() ? n.controlId : void 0;
1164
1164
  if (!o)
1165
1165
  return { diagnostic: { code: "invalid_binding_shape" } };
1166
- const r = Ei(
1166
+ const r = Ai(
1167
1167
  n.presentationTarget
1168
1168
  );
1169
1169
  if (!r)
1170
1170
  return {
1171
1171
  diagnostic: { code: "missing_target", controlId: o }
1172
1172
  };
1173
- const i = $(r);
1173
+ const i = U(r);
1174
1174
  if (!t.knownKeys.has(i))
1175
1175
  return {
1176
1176
  diagnostic: { code: "stale_target", controlId: o }
@@ -1205,7 +1205,7 @@ function ml(e) {
1205
1205
  }
1206
1206
  function Bi(e) {
1207
1207
  var r;
1208
- const t = [], n = $(e.target), o = Vn(e);
1208
+ const t = [], n = U(e.target), o = Vn(e);
1209
1209
  for (const i of e.bindings || []) {
1210
1210
  const s = kn(i, o);
1211
1211
  if ("diagnostic" in s) {
@@ -1213,10 +1213,10 @@ function Bi(e) {
1213
1213
  continue;
1214
1214
  }
1215
1215
  const a = s.binding;
1216
- if (!a || $(
1216
+ if (!a || U(
1217
1217
  a.presentationTarget
1218
1218
  ) !== n) continue;
1219
- const l = Jt(
1219
+ const l = Yt(
1220
1220
  (r = e.values) == null ? void 0 : r[a.control.id]
1221
1221
  );
1222
1222
  if (!(!l || !a.currencies.includes(l)))
@@ -1225,7 +1225,7 @@ function Bi(e) {
1225
1225
  return { diagnostics: t };
1226
1226
  }
1227
1227
  function _i(e, t, n, o) {
1228
- const r = { ...e, config: { ...e.config, matrix: t } }, i = Ai(r, [], o), s = Sn(r, o), a = { ...t.presentation.measureFormats };
1228
+ const r = { ...e, config: { ...e.config, matrix: t } }, i = Ei(r, [], o), s = Sn(r, o), a = { ...t.presentation.measureFormats };
1229
1229
  for (const c of s) {
1230
1230
  const l = { kind: "matrix_measure", measureId: c.measureId }, { currency: u } = Bi({
1231
1231
  ...n,
@@ -1350,7 +1350,7 @@ function Li(e, t) {
1350
1350
  controlBindings: Ni(e.controlBindings, t)
1351
1351
  }) : "__none__";
1352
1352
  }
1353
- const ji = ["table", "detailTable"], xt = (e) => ji.includes(e.type), zi = "calendar-context";
1353
+ const ji = ["table", "detailTable"], Pt = (e) => ji.includes(e.type), zi = "calendar-context";
1354
1354
  function Gi(e) {
1355
1355
  const { id: t, label: n, field: o, ...r } = e;
1356
1356
  return {
@@ -1405,7 +1405,7 @@ function Hi(e) {
1405
1405
  filters: e.filters ? Ve(e.filters) : void 0
1406
1406
  };
1407
1407
  }
1408
- function $i(e, t, n) {
1408
+ function Ui(e, t, n) {
1409
1409
  if (!e)
1410
1410
  return JSON.stringify(e);
1411
1411
  if (n === "matrixTable" && e.matrix) return _(Kr(e.matrix.spec));
@@ -1415,7 +1415,7 @@ function $i(e, t, n) {
1415
1415
  filters: Ve(i.filters)
1416
1416
  });
1417
1417
  }
1418
- function Ui(e) {
1418
+ function $i(e) {
1419
1419
  if (!e)
1420
1420
  return null;
1421
1421
  const { format: t, ...n } = e;
@@ -1476,14 +1476,14 @@ function Wi(e, {
1476
1476
  controlBindings: s
1477
1477
  }),
1478
1478
  _(
1479
- Ui(c)
1479
+ $i(c)
1480
1480
  ),
1481
1481
  _(l ?? null),
1482
1482
  zi,
1483
1483
  _(u),
1484
1484
  JSON.stringify(f),
1485
1485
  JSON.stringify(m),
1486
- $i(
1486
+ Ui(
1487
1487
  h,
1488
1488
  I,
1489
1489
  e.type
@@ -1491,9 +1491,9 @@ function Wi(e, {
1491
1491
  t
1492
1492
  ];
1493
1493
  }
1494
- function Yi(e, t, n) {
1494
+ function Ji(e, t, n) {
1495
1495
  var a, c, l;
1496
- const o = Wi(e, t), r = _(o), i = ((a = n == null ? void 0 : n.resolvePaginationConfig) == null ? void 0 : a.call(n, r)) ?? e.paginationConfig, s = xt(e) && Se(e.config) || xt(e) && e.sql && ((l = (c = e.preferences) == null ? void 0 : c.tablePrefs) == null ? void 0 : l.enableDevModePagination);
1496
+ const o = Wi(e, t), r = _(o), i = ((a = n == null ? void 0 : n.resolvePaginationConfig) == null ? void 0 : a.call(n, r)) ?? e.paginationConfig, s = Pt(e) && Se(e.config) || Pt(e) && e.sql && ((l = (c = e.preferences) == null ? void 0 : c.tablePrefs) == null ? void 0 : l.enableDevModePagination);
1497
1497
  return {
1498
1498
  queryKey: [
1499
1499
  ...o,
@@ -1503,8 +1503,8 @@ function Yi(e, t, n) {
1503
1503
  paginationConfig: i
1504
1504
  };
1505
1505
  }
1506
- function Ji(e, t, n, o) {
1507
- return Yi(
1506
+ function Yi(e, t, n, o) {
1507
+ return Ji(
1508
1508
  e,
1509
1509
  {
1510
1510
  finalFiltersKey: t.finalFiltersKey,
@@ -1521,7 +1521,7 @@ function Ji(e, t, n, o) {
1521
1521
  o
1522
1522
  );
1523
1523
  }
1524
- function xn(e) {
1524
+ function Pn(e) {
1525
1525
  const t = {
1526
1526
  ...Or,
1527
1527
  ...e.presentation
@@ -1586,7 +1586,7 @@ function xn(e) {
1586
1586
  }
1587
1587
  function gl(e) {
1588
1588
  var t, n;
1589
- return xn({
1589
+ return Pn({
1590
1590
  comparisonMetadata: e.comparisonMetadata,
1591
1591
  presentation: (n = (t = e.card) == null ? void 0 : t.preferences) == null ? void 0 : n.comparisonPresentation,
1592
1592
  resolveMetricName: ({ metricId: o, metricAlias: r }) => {
@@ -1630,7 +1630,7 @@ function et(e, t) {
1630
1630
  metricAlias: Q(e)
1631
1631
  } : { kind: "dimension", role: t, fieldId: e.id };
1632
1632
  }
1633
- function Pt(e) {
1633
+ function xt(e) {
1634
1634
  const t = /* @__PURE__ */ new Map();
1635
1635
  for (const n of e) t.set(n, (t.get(n) ?? 0) + 1);
1636
1636
  return t;
@@ -1650,7 +1650,7 @@ function Xi(e, t) {
1650
1650
  }
1651
1651
  ] : [];
1652
1652
  })
1653
- ), s = Pt(i.map((m) => m.columnId)), a = Pt(
1653
+ ), s = xt(i.map((m) => m.columnId)), a = xt(
1654
1654
  i.flatMap(
1655
1655
  (m) => m.outputKey ? [m.outputKey] : []
1656
1656
  )
@@ -1674,7 +1674,7 @@ function Xi(e, t) {
1674
1674
  for (const g of t.columns) {
1675
1675
  if (!g.pivotIdentity || !o.has(g.key) || l.has(g.key))
1676
1676
  continue;
1677
- const p = Je({
1677
+ const p = Ye({
1678
1678
  resultColumn: g,
1679
1679
  card: m,
1680
1680
  columnKeyMap: r
@@ -1753,7 +1753,7 @@ function ns(e, t, n, o) {
1753
1753
  const m = e.type === "table" ? (c = e.preferences) == null ? void 0 : c.comparisonPresentation : void 0;
1754
1754
  sn(m) || (r = r.filter((g) => !f.comparisonColumnKeys.has(g)));
1755
1755
  } else {
1756
- const f = xn({
1756
+ const f = Pn({
1757
1757
  comparisonMetadata: s,
1758
1758
  presentation: (l = e.preferences) == null ? void 0 : l.comparisonPresentation,
1759
1759
  resolveMetricName: o
@@ -1823,7 +1823,7 @@ function is(e, t, n) {
1823
1823
  function ss(e, t) {
1824
1824
  return e ? "query" : t === "server" ? "page-only" : "browser";
1825
1825
  }
1826
- function Pn(e, t) {
1826
+ function xn(e, t) {
1827
1827
  var n, o, r;
1828
1828
  return !!t && ((r = (o = (n = e.preferences) == null ? void 0 : n.tablePrefs) == null ? void 0 : o.columnVisibility) == null ? void 0 : r[t]) === !1;
1829
1829
  }
@@ -1912,7 +1912,7 @@ function Il(e) {
1912
1912
  const S = d(b);
1913
1913
  return u(l.entries.has(S) ? S : void 0) ?? ((V = l.entries.get(S)) == null ? void 0 : V.authorLabel);
1914
1914
  }
1915
- ), g = (b) => Pn(t, b), p = (b) => {
1915
+ ), g = (b) => xn(t, b), p = (b) => {
1916
1916
  const S = l.owners.get(b);
1917
1917
  if (!S || i === "card-type") return;
1918
1918
  const V = l.entries.get(S.columnId);
@@ -1933,12 +1933,12 @@ function Il(e) {
1933
1933
  ], w = [
1934
1934
  ...new Set(C.filter((b) => !v.has(b)))
1935
1935
  ];
1936
- let A;
1936
+ let E;
1937
1937
  if (s != null && s.sort && a !== "page-only") {
1938
1938
  const b = s.sort.filter(
1939
1939
  (S) => v.has(S.columnId)
1940
1940
  );
1941
- A = b.length || !s.sort.length ? b : void 0;
1941
+ E = b.length || !s.sort.length ? b : void 0;
1942
1942
  }
1943
1943
  const M = Tr(
1944
1944
  s ? {
@@ -1953,28 +1953,28 @@ function Il(e) {
1953
1953
  ([b]) => v.has(b)
1954
1954
  )
1955
1955
  ),
1956
- sort: A,
1956
+ sort: E,
1957
1957
  widths: Object.fromEntries(
1958
1958
  Object.entries(s.widths ?? {}).filter(
1959
1959
  ([b]) => v.has(b)
1960
1960
  )
1961
1961
  )
1962
1962
  } : void 0
1963
- ), F = M == null ? void 0 : M.order, k = F ? cs(y, p, F, n.columns) : y, O = F ? [...k, ...f.filter(g)] : f, P = _e(k, p).flatMap(
1963
+ ), F = M == null ? void 0 : M.order, k = F ? cs(y, p, F, n.columns) : y, O = F ? [...k, ...f.filter(g)] : f, x = _e(k, p).flatMap(
1964
1964
  (b) => b.columnId ? [b.columnId] : []
1965
1965
  ), T = new Set((M == null ? void 0 : M.hidden) ?? []);
1966
- P.length && P.every((b) => T.has(b)) && T.delete(P[0]);
1967
- const x = o === "screen" ? os(t, n, f) : /* @__PURE__ */ new Map(), E = (b, S) => {
1966
+ x.length && x.every((b) => T.has(b)) && T.delete(x[0]);
1967
+ const P = o === "screen" ? os(t, n, f) : /* @__PURE__ */ new Map(), A = (b, S) => {
1968
1968
  const V = u(S == null ? void 0 : S.columnId);
1969
1969
  if ((S == null ? void 0 : S.part) === "base" && V) return V;
1970
- const K = x.get(b);
1970
+ const K = P.get(b);
1971
1971
  if (K)
1972
1972
  return fi(
1973
1973
  ((S == null ? void 0 : S.part) === "comparison" ? V : void 0) ?? (K.metric.label || K.metric.name),
1974
1974
  K.kind
1975
1975
  );
1976
- const J = m.get(b);
1977
- if (J) return J;
1976
+ const Y = m.get(b);
1977
+ if (Y) return Y;
1978
1978
  const Z = Ii({
1979
1979
  columnId: b,
1980
1980
  card: t,
@@ -1993,17 +1993,17 @@ function Il(e) {
1993
1993
  ...S ? { columnId: S.columnId } : {},
1994
1994
  part: V,
1995
1995
  visible: !g(b) && !(S && T.has(S.columnId)),
1996
- label: E(b, S),
1996
+ label: A(b, S),
1997
1997
  resizable: !i && Zi({ part: V, columnId: S == null ? void 0 : S.columnId })
1998
1998
  };
1999
1999
  }), z = Object.fromEntries(
2000
2000
  R.map((b) => [b.outputKey, b.label])
2001
- ), Y = {
2001
+ ), J = {
2002
2002
  ...((gt = (mt = t.preferences) == null ? void 0 : mt.tablePrefs) == null ? void 0 : gt.columnSizing) ?? {}
2003
2003
  };
2004
2004
  for (const b of R) {
2005
2005
  const S = b.resizable ? (yt = M == null ? void 0 : M.widths) == null ? void 0 : yt[b.columnId] : void 0;
2006
- S !== void 0 && (Y[b.outputKey] = S);
2006
+ S !== void 0 && (J[b.outputKey] = S);
2007
2007
  }
2008
2008
  const ce = a === "page-only" ? [] : a === "query" ? D : (M == null ? void 0 : M.sort) ?? [], ao = new Map(
2009
2009
  ce.map((b) => [b.columnId, b.direction])
@@ -2015,24 +2015,24 @@ function Il(e) {
2015
2015
  let ue;
2016
2016
  if (i)
2017
2017
  ue = { available: !1, reason: i };
2018
- else if (!P.length)
2018
+ else if (!x.length)
2019
2019
  ue = { available: !1, reason: "no-addressable-columns" };
2020
2020
  else {
2021
- const b = new Set(F ?? []), S = P.filter(
2021
+ const b = new Set(F ?? []), S = x.filter(
2022
2022
  (V) => !T.has(V)
2023
2023
  ).length;
2024
2024
  ue = {
2025
2025
  available: !0,
2026
2026
  canReset: ct,
2027
- items: P.map((V) => {
2028
- const K = l.entries.get(V), J = T.has(V), Z = ao.get(V);
2027
+ items: x.map((V) => {
2028
+ const K = l.entries.get(V), Y = T.has(V), Z = ao.get(V);
2029
2029
  return {
2030
2030
  columnId: V,
2031
2031
  label: u(V) ?? K.authorLabel,
2032
2032
  authorLabel: K.authorLabel,
2033
- hidden: J,
2033
+ hidden: Y,
2034
2034
  isNew: F !== void 0 && !b.has(V),
2035
- canHide: !J && S > 1,
2035
+ canHide: !Y && S > 1,
2036
2036
  ...Z ? { sort: Z } : {}
2037
2037
  };
2038
2038
  })
@@ -2042,7 +2042,7 @@ function Il(e) {
2042
2042
  columns: R,
2043
2043
  visibleKeys: R.filter((b) => b.visible).map((b) => b.outputKey),
2044
2044
  labels: z,
2045
- columnSizing: Y,
2045
+ columnSizing: J,
2046
2046
  sortMode: a,
2047
2047
  clientSort: lo,
2048
2048
  panel: ue,
@@ -2079,7 +2079,7 @@ function us(e, t) {
2079
2079
  const i = wn(e, r.columnId);
2080
2080
  if (!i) return [];
2081
2081
  const s = Nr(i.field, i.role);
2082
- return Pn(e, s) ? [] : [
2082
+ return xn(e, s) ? [] : [
2083
2083
  {
2084
2084
  ...i.field,
2085
2085
  alias: s,
@@ -2148,11 +2148,11 @@ function On(e) {
2148
2148
  var t, n, o, r;
2149
2149
  return ((r = (o = (n = (t = e.preferences) == null ? void 0 : t.tablePrefs) == null ? void 0 : n.tableStyle) == null ? void 0 : o.totals) == null ? void 0 : r.enabled) === !0;
2150
2150
  }
2151
- function An(e) {
2151
+ function En(e) {
2152
2152
  return nt(e) ? On(e) : !1;
2153
2153
  }
2154
2154
  function fs(e, t, n) {
2155
- if (!An(e))
2155
+ if (!En(e))
2156
2156
  return;
2157
2157
  const o = tt(e, n).filter((r) => r.role !== "metric").map((r) => new Set(ae(r)));
2158
2158
  return t.find(
@@ -2165,7 +2165,7 @@ function Tl({
2165
2165
  visibleColumnIds: n,
2166
2166
  totalsByColumnId: o
2167
2167
  }) {
2168
- if (!An(e) || !o || Object.keys(o).length === 0)
2168
+ if (!En(e) || !o || Object.keys(o).length === 0)
2169
2169
  return;
2170
2170
  const r = fs(
2171
2171
  e,
@@ -2204,7 +2204,7 @@ function ps(e, t, n) {
2204
2204
  if (!nt(e) || !On(e))
2205
2205
  return;
2206
2206
  const o = tt(e, t), r = new Set(
2207
- Er(
2207
+ Ar(
2208
2208
  o.filter((c) => c.role === "metric")
2209
2209
  )
2210
2210
  ), i = o.filter((c) => c.role !== "metric"), s = n && i.find(
@@ -2292,10 +2292,10 @@ function kl({
2292
2292
  pageSize: (e == null ? void 0 : e.pageSize) ?? t
2293
2293
  };
2294
2294
  }
2295
- function xl(e, t, n) {
2295
+ function Pl(e, t, n) {
2296
2296
  return (e == null ? void 0 : e.queryInputIdentity) === n && e.page === t.page && e.pageSize === t.pageSize;
2297
2297
  }
2298
- function Pl(e, t) {
2298
+ function xl(e, t) {
2299
2299
  return !e || !t || e.page === t.page && e.pageSize === t.pageSize ? e : {
2300
2300
  ...e,
2301
2301
  page: t.page,
@@ -2399,7 +2399,7 @@ function Ts(e) {
2399
2399
  if (!m.success) return u(m.error.message);
2400
2400
  t = m.data;
2401
2401
  const g = [...r, ...i].map((p) => {
2402
- const y = Lt({ binding: p, definitions: n, controlValues: e.controlValues }), h = !p.matrixTargetId && y !== void 0 && y !== Ae ? f(m.data, p) : [];
2402
+ const y = Lt({ binding: p, definitions: n, controlValues: e.controlValues }), h = !p.matrixTargetId && y !== void 0 && y !== Ee ? f(m.data, p) : [];
2403
2403
  return {
2404
2404
  binding: p,
2405
2405
  selectedValue: y,
@@ -2407,33 +2407,33 @@ function Ts(e) {
2407
2407
  };
2408
2408
  });
2409
2409
  for (const { binding: p, targetId: y, selectedValue: h } of g) {
2410
- if (h === void 0 || h === Ae)
2410
+ if (h === void 0 || h === Ee)
2411
2411
  continue;
2412
2412
  const I = (F) => u(F, p.controlId), v = p.target === "config_metric_selector" || p.target === "config_aggregation", D = f(t, p);
2413
2413
  (!y || !D.some((F) => F.id === y)) && I("Choose a valid Matrix level or measure target for this control.");
2414
2414
  const C = `${p.target}:${y}`;
2415
2415
  s.has(C) && I("Multiple controls cannot replace the same Matrix target."), s.add(C);
2416
2416
  const w = (F) => {
2417
- const k = (l().byId.get(F.id) ?? []).filter((P) => !F.source || Oe(F.source, P.field.source ?? e.spec.source));
2417
+ const k = (l().byId.get(F.id) ?? []).filter((x) => !F.source || Oe(F.source, x.field.source ?? e.spec.source));
2418
2418
  if (k.length !== 1) return I(k.length ? "The selected field is ambiguous in the authorized Matrix field catalog." : "The selected field is not in the authorized Matrix field catalog.");
2419
2419
  const O = gr.safeParse(k[0].field);
2420
2420
  return O.success ? O.data : I(O.error.message);
2421
- }, A = p.target === "config_metric_selector" || p.target === "config_field_selector" ? p.mapping[h] : void 0, M = A && typeof A == "object" && "kind" in A && A.kind === "matrix_instance" ? A.id : void 0;
2421
+ }, E = p.target === "config_metric_selector" || p.target === "config_field_selector" ? p.mapping[h] : void 0, M = E && typeof E == "object" && "kind" in E && E.kind === "matrix_instance" ? E.id : void 0;
2422
2422
  if (v) {
2423
2423
  a.set(y, p.controlId);
2424
2424
  const F = M === void 0 ? void 0 : m.data.measures.find(
2425
2425
  (T) => T.id === M && T.kind === "aggregate"
2426
2426
  );
2427
2427
  M !== void 0 && !F && I("The selected Matrix aggregate measure is no longer available.");
2428
- const k = p.target === "config_metric_selector" && !F ? Vo({ binding: p, selectedValue: h }) : void 0, O = ((F == null ? void 0 : F.kind) === "aggregate" ? F.aggregate : k == null ? void 0 : k.aggregate) ?? (p.target === "config_aggregation" ? bt({ binding: p, selectedValue: h }) : void 0), P = O === void 0 ? void 0 : mr.safeParse(O);
2429
- P && !P.success && I("This aggregation is not supported by Matrix."), t = {
2428
+ const k = p.target === "config_metric_selector" && !F ? Vo({ binding: p, selectedValue: h }) : void 0, O = ((F == null ? void 0 : F.kind) === "aggregate" ? F.aggregate : k == null ? void 0 : k.aggregate) ?? (p.target === "config_aggregation" ? bt({ binding: p, selectedValue: h }) : void 0), x = O === void 0 ? void 0 : mr.safeParse(O);
2429
+ x && !x.success && I("This aggregation is not supported by Matrix."), t = {
2430
2430
  ...t,
2431
2431
  measures: t.measures.map(
2432
2432
  (T) => T.id !== y || T.kind !== "aggregate" ? T : {
2433
2433
  ...T,
2434
2434
  ...k ? { field: w(k) } : {},
2435
2435
  ...(F == null ? void 0 : F.kind) === "aggregate" ? { field: F.field } : {},
2436
- aggregate: P != null && P.success ? P.data : T.aggregate
2436
+ aggregate: x != null && x.success ? x.data : T.aggregate
2437
2437
  }
2438
2438
  )
2439
2439
  };
@@ -2444,15 +2444,15 @@ function Ts(e) {
2444
2444
  M !== void 0 && !F && I("The selected Matrix level is no longer available.");
2445
2445
  const k = p.target === "config_field_selector" && !F ? ko({ binding: p, selectedValue: h }) : void 0, O = p.target === "config_grain" ? bt({ binding: p, selectedValue: h }) : F ? F.grain : k == null ? void 0 : k.granularity;
2446
2446
  O !== void 0 && !Ss.has(O) && I("This time grain is not supported by Matrix.");
2447
- const P = (T) => T.map((x) => {
2448
- if (x.id !== y) return x;
2449
- const E = (F == null ? void 0 : F.field) ?? (k ? w(k) : x.field), R = d(E, p.controlId), z = O ?? (k && Ct(R) ? x.grain : void 0);
2450
- return z && !Ct(R) && I("A time grain requires a temporal Matrix level."), { ...x, field: E, grain: z };
2447
+ const x = (T) => T.map((P) => {
2448
+ if (P.id !== y) return P;
2449
+ const A = (F == null ? void 0 : F.field) ?? (k ? w(k) : P.field), R = d(A, p.controlId), z = O ?? (k && Ct(R) ? P.grain : void 0);
2450
+ return z && !Ct(R) && I("A time grain requires a temporal Matrix level."), { ...P, field: A, grain: z };
2451
2451
  });
2452
2452
  t = {
2453
2453
  ...t,
2454
- rows: P(t.rows),
2455
- columns: P(t.columns)
2454
+ rows: x(t.rows),
2455
+ columns: x(t.columns)
2456
2456
  };
2457
2457
  }
2458
2458
  }
@@ -2460,16 +2460,16 @@ function Ts(e) {
2460
2460
  const h = t.measures.find((v) => v.id === p);
2461
2461
  if (!h || h.kind !== "aggregate") continue;
2462
2462
  const I = d(h.field, y);
2463
- xo(I).some((v) => v.value === h.aggregate) || u(`Aggregation '${h.aggregate}' is not eligible for this Matrix field datatype.`, y);
2463
+ Po(I).some((v) => v.value === h.aggregate) || u(`Aggregation '${h.aggregate}' is not eligible for this Matrix field datatype.`, y);
2464
2464
  }
2465
2465
  try {
2466
- return Po(m.data, t);
2466
+ return xo(m.data, t);
2467
2467
  } catch (p) {
2468
2468
  if (p instanceof hr) return u(p.message);
2469
2469
  throw p;
2470
2470
  }
2471
2471
  }
2472
- function En(e, t) {
2472
+ function An(e, t) {
2473
2473
  const n = [], o = (r) => {
2474
2474
  if (r.source) {
2475
2475
  const i = yr.safeParse(r.source);
@@ -2480,18 +2480,18 @@ function En(e, t) {
2480
2480
  };
2481
2481
  for (const r of e) {
2482
2482
  if (r.target !== "config_field_selector" && r.target !== "config_metric_selector") continue;
2483
- const i = t == null ? void 0 : t.get(r), s = t ? i && i !== Ae ? [r.mapping[i]] : [] : Object.values(r.mapping);
2483
+ const i = t == null ? void 0 : t.get(r), s = t ? i && i !== Ee ? [r.mapping[i]] : [] : Object.values(r.mapping);
2484
2484
  for (const a of s)
2485
2485
  a && "role" in a && o(a);
2486
2486
  }
2487
2487
  return n;
2488
2488
  }
2489
2489
  function Ds(e, t = [], n = []) {
2490
- return Wt([...jt(e), ...En(t), ...n]);
2490
+ return Wt([...jt(e), ...An(t), ...n]);
2491
2491
  }
2492
2492
  function Ms(e, t = {}) {
2493
2493
  const n = t.controlBindings ?? [], o = Nt(t.controlDefinitions ?? [], t.cardControlDefinitions ?? []), r = new Map(n.filter((i) => i.target === "config_field_selector" || i.target === "config_metric_selector").map((i) => [i, Lt({ binding: i, definitions: o, controlValues: t.controlValues })]));
2494
- return Wt([...jt(e), ...En(n, r)]);
2494
+ return Wt([...jt(e), ...An(n, r)]);
2495
2495
  }
2496
2496
  function Vs(e, t) {
2497
2497
  return {
@@ -2505,16 +2505,16 @@ function Vs(e, t) {
2505
2505
  };
2506
2506
  }
2507
2507
  function ks(e, t) {
2508
- return Ne(e) ? xs(e, t) : e.config ?? {};
2508
+ return Ne(e) ? Ps(e, t) : e.config ?? {};
2509
2509
  }
2510
- function xs(e, t) {
2510
+ function Ps(e, t) {
2511
2511
  var o;
2512
2512
  const n = (o = t == null ? void 0 : t.steps[t.steps.length - 1]) == null ? void 0 : o.toField;
2513
2513
  return n ? di(e.config ?? {}, n, {
2514
2514
  sortPolicy: "retargetDimensionSort"
2515
2515
  }) : e.config ?? {};
2516
2516
  }
2517
- function Ps(e, t) {
2517
+ function xs(e, t) {
2518
2518
  const n = (e == null ? void 0 : e.steps) ?? [];
2519
2519
  if (n.length !== 0)
2520
2520
  return {
@@ -2563,21 +2563,21 @@ function Os(e) {
2563
2563
  let t = !1;
2564
2564
  const n = (o = e.inputs) == null ? void 0 : o.map((r) => {
2565
2565
  if (r.kind !== "filter" || !r.filter) return r;
2566
- const i = As(
2566
+ const i = Es(
2567
2567
  r.filter,
2568
- new Set(Es(e.defaultInputValues, r))
2568
+ new Set(As(e.defaultInputValues, r))
2569
2569
  );
2570
2570
  return i === r.filter ? r : (t = !0, { ...r, filter: i });
2571
2571
  });
2572
2572
  return t ? { ...e, inputs: n } : e;
2573
2573
  }
2574
- function As(e, t) {
2574
+ function Es(e, t) {
2575
2575
  if (t.size !== 1 || !ot(e.operation))
2576
2576
  return e;
2577
2577
  const [n] = t;
2578
2578
  return rt(e.operation) === n ? e : { ...e, operation: ws(n) };
2579
2579
  }
2580
- function Es(e, t) {
2580
+ function As(e, t) {
2581
2581
  var r;
2582
2582
  const n = (i) => Object.values(i ?? {}).map((s) => s[t.id]);
2583
2583
  return (t.runtimeScope === "shared" ? [(r = e == null ? void 0 : e.shared) == null ? void 0 : r[t.id]] : t.runtimeScope === "perSheet" ? n(e == null ? void 0 : e.bySheetId) : t.runtimeScope === "perCard" ? n(e == null ? void 0 : e.byCardId) : t.runtimeScope === "perDocumentSection" ? n(e == null ? void 0 : e.byDocumentSectionId) : []).flatMap(
@@ -2587,7 +2587,7 @@ function Es(e, t) {
2587
2587
  function Bs(e) {
2588
2588
  return ot(e.operation) ? [rt(e.operation)] : [];
2589
2589
  }
2590
- function Al(e) {
2590
+ function El(e) {
2591
2591
  const t = Zt(e), o = q(t).issues.length ? t : Ba(t);
2592
2592
  return ci(Os(o)).dashboard;
2593
2593
  }
@@ -2598,7 +2598,7 @@ function it(e, t) {
2598
2598
  continue;
2599
2599
  const r = [];
2600
2600
  for (const i of o.inlineFilters) {
2601
- const s = Ao(i, t);
2601
+ const s = Eo(i, t);
2602
2602
  s && r.push(s);
2603
2603
  }
2604
2604
  r.length > 0 && (n[o.id] = r);
@@ -2645,7 +2645,7 @@ function st(e, t, n) {
2645
2645
  n
2646
2646
  );
2647
2647
  }
2648
- function El(e, t, n) {
2648
+ function Al(e, t, n) {
2649
2649
  return _n(e, t, n);
2650
2650
  }
2651
2651
  function _n(e, t, n) {
@@ -2720,7 +2720,7 @@ function Kn(e, t, n) {
2720
2720
  { hasExplicitRuntimeOverrides: t !== void 0 }
2721
2721
  );
2722
2722
  return {
2723
- ...Eo({
2723
+ ...Ao({
2724
2724
  dashboardValues: o.dashboardControlValues,
2725
2725
  cardValuesMap: o.cardControlValuesMap
2726
2726
  }),
@@ -2853,7 +2853,7 @@ function qn(e) {
2853
2853
  return { filterInputs: t, controlInputIds: n, compatibility: o };
2854
2854
  }
2855
2855
  function Nn(e, t) {
2856
- const n = Yt(t);
2856
+ const n = Jt(t);
2857
2857
  if (!n) return;
2858
2858
  const o = ie(e, n);
2859
2859
  return o ? Lo(o, e) ? "applies" : "not-eligible" : "removed";
@@ -3252,15 +3252,15 @@ function Ll(e, t, n) {
3252
3252
  restore: o
3253
3253
  };
3254
3254
  }
3255
- const At = (e) => JSON.stringify([e.scope, e.target, e.inputId]);
3255
+ const Et = (e) => JSON.stringify([e.scope, e.target, e.inputId]);
3256
3256
  function pe(e) {
3257
3257
  return !e || e.status === "cleared" && !e.comparisonSelection;
3258
3258
  }
3259
3259
  function Hn(e, t) {
3260
3260
  const n = new Map(
3261
- ne(e).map((i) => [At(i), i])
3261
+ ne(e).map((i) => [Et(i), i])
3262
3262
  ), o = new Map(
3263
- ne(t).map((i) => [At(i), i])
3263
+ ne(t).map((i) => [Et(i), i])
3264
3264
  ), r = {};
3265
3265
  for (const [i, s] of o) {
3266
3266
  const a = n.get(i);
@@ -3295,7 +3295,7 @@ function Gs(e) {
3295
3295
  }
3296
3296
  function Hs(e, t, n) {
3297
3297
  var r, i;
3298
- const o = Yt(n);
3298
+ const o = Jt(n);
3299
3299
  if (o) {
3300
3300
  const s = (i = (r = ie(e, o)) == null ? void 0 : r.title) == null ? void 0 : i.trim();
3301
3301
  return s ? `Selection in ${s}` : "Selection";
@@ -3334,7 +3334,7 @@ function zl(e) {
3334
3334
  });
3335
3335
  return r;
3336
3336
  }
3337
- function Et(e) {
3337
+ function At(e) {
3338
3338
  const t = ee(e.filter);
3339
3339
  return {
3340
3340
  inputId: e.inputId,
@@ -3348,7 +3348,7 @@ function Et(e) {
3348
3348
  }
3349
3349
  };
3350
3350
  }
3351
- function $s(e) {
3351
+ function Us(e) {
3352
3352
  var r, i;
3353
3353
  if ((r = e.card.sql) != null && r.trim())
3354
3354
  return {
@@ -3378,7 +3378,7 @@ function $s(e) {
3378
3378
  fieldCandidates: t,
3379
3379
  resolution: {
3380
3380
  status: "resolved",
3381
- resolvedOwner: Et(n)
3381
+ resolvedOwner: At(n)
3382
3382
  }
3383
3383
  };
3384
3384
  const o = t.filter(
@@ -3389,7 +3389,7 @@ function $s(e) {
3389
3389
  fieldCandidates: t,
3390
3390
  resolution: {
3391
3391
  status: "resolved",
3392
- resolvedOwner: Et(o[0].input)
3392
+ resolvedOwner: At(o[0].input)
3393
3393
  }
3394
3394
  } : o.length > 1 ? {
3395
3395
  inputs: e.inputs,
@@ -3424,7 +3424,7 @@ function Gl(e) {
3424
3424
  }
3425
3425
  return t;
3426
3426
  }
3427
- const Us = /* @__PURE__ */ new Set([
3427
+ const $s = /* @__PURE__ */ new Set([
3428
3428
  "between",
3429
3429
  "not between",
3430
3430
  "=",
@@ -3437,9 +3437,9 @@ const Us = /* @__PURE__ */ new Set([
3437
3437
  "is not null"
3438
3438
  ]), Qs = /^(\d{4}-\d{2}-\d{2})T/, Ws = /^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}(?::\d{2}(?:\.\d{1,9})?)?(?:Z|[+-]\d{2}:\d{2})$/;
3439
3439
  function lt(e) {
3440
- return Us.has(e);
3440
+ return $s.has(e);
3441
3441
  }
3442
- function Ys(e, t) {
3442
+ function Js(e, t) {
3443
3443
  if (e instanceof Date)
3444
3444
  return Number.isNaN(e.getTime()) ? e : t ? It(e, t, "yyyy-MM-dd") : e.toISOString().slice(0, 10);
3445
3445
  if (typeof e != "string")
@@ -3453,13 +3453,13 @@ function Ys(e, t) {
3453
3453
  const o = Qs.exec(n);
3454
3454
  return o ? o[1] : e;
3455
3455
  }
3456
- function $n(e, t) {
3456
+ function Un(e, t) {
3457
3457
  return Array.isArray(e) ? e.map(
3458
- (n) => Ys(n, t)
3458
+ (n) => Js(n, t)
3459
3459
  ) : e;
3460
3460
  }
3461
- function Un(e) {
3462
- return typeof e.allowMinutePrecision == "boolean" ? e.allowMinutePrecision : $e(
3461
+ function $n(e) {
3462
+ return typeof e.allowMinutePrecision == "boolean" ? e.allowMinutePrecision : Ue(
3463
3463
  e.dashboard,
3464
3464
  e.semanticExecutionPayload
3465
3465
  ).allEligibleTargetsAreDateTime;
@@ -3478,7 +3478,7 @@ function Qn(e) {
3478
3478
  ...n,
3479
3479
  filterId: t.id
3480
3480
  };
3481
- const i = n, s = i.temporalPrecision === "minute" || ge(i.relativeMeta) === "minute", a = !r && s, c = i.operation === "is null" || i.operation === "is not null" ? [] : a ? $n(i.values, o) : i.values, l = r || ge(i.relativeMeta) !== "minute" ? i.relativeMeta : void 0, u = r && i.temporalPrecision === "minute" ? i.temporalPrecision : void 0, {
3481
+ const i = n, s = i.temporalPrecision === "minute" || ge(i.relativeMeta) === "minute", a = !r && s, c = i.operation === "is null" || i.operation === "is not null" ? [] : a ? Un(i.values, o) : i.values, l = r || ge(i.relativeMeta) !== "minute" ? i.relativeMeta : void 0, u = r && i.temporalPrecision === "minute" ? i.temporalPrecision : void 0, {
3482
3482
  relativeMeta: d,
3483
3483
  temporalPrecision: f,
3484
3484
  values: m,
@@ -3492,11 +3492,11 @@ function Qn(e) {
3492
3492
  ...u ? { temporalPrecision: u } : {}
3493
3493
  };
3494
3494
  }
3495
- function Js(e) {
3496
- const t = U(e.filters);
3495
+ function Ys(e) {
3496
+ const t = $(e.filters);
3497
3497
  if (!t)
3498
3498
  return e.filterValues;
3499
- const n = Un(e);
3499
+ const n = $n(e);
3500
3500
  return e.filterValues.map((o) => o.filterId !== t.id ? o : Qn({
3501
3501
  globalDateFilter: t,
3502
3502
  globalDateFilterValue: o,
@@ -3524,7 +3524,7 @@ function Wn(e) {
3524
3524
  name: o.qualifiedFieldName || o.name,
3525
3525
  operation: a.operation,
3526
3526
  valueType: "date",
3527
- values: a.operation === "is null" || a.operation === "is not null" ? [] : m ? $n(
3527
+ values: a.operation === "is null" || a.operation === "is not null" ? [] : m ? Un(
3528
3528
  a.values,
3529
3529
  i
3530
3530
  ) : a.values,
@@ -3588,14 +3588,14 @@ function ea(e) {
3588
3588
  const o = Xs(t);
3589
3589
  return o && ((i = (r = n.domainsById[o.domainId]) == null ? void 0 : r.datasetsByName[o.datasetName]) == null ? void 0 : i.primaryDateField) || null;
3590
3590
  }
3591
- function Yn(e) {
3592
- const t = U(e.filters);
3591
+ function Jn(e) {
3592
+ const t = $(e.filters);
3593
3593
  return t ? e.filterValues.filter(
3594
3594
  (n) => n.filterId !== t.id
3595
3595
  ) : e.filterValues;
3596
3596
  }
3597
3597
  function Hl(e) {
3598
- const t = U(e.filters), n = Yn({
3598
+ const t = $(e.filters), n = Jn({
3599
3599
  filters: e.filters,
3600
3600
  filterValues: e.filterValues
3601
3601
  });
@@ -3618,7 +3618,7 @@ function Hl(e) {
3618
3618
  }
3619
3619
  function ta(e) {
3620
3620
  var u;
3621
- const t = U(e.filters), n = t ? e.cardFilterValues.find(
3621
+ const t = $(e.filters), n = t ? e.cardFilterValues.find(
3622
3622
  (d) => d.filterId === t.id
3623
3623
  ) : void 0, o = t ? e.cardFilterValues.filter(
3624
3624
  (d) => d.filterId !== t.id
@@ -3648,7 +3648,7 @@ function ta(e) {
3648
3648
  effectiveFilterValue: f,
3649
3649
  mappedFilterValue: (m = e.mappedFilterValuesByInputId) == null ? void 0 : m.get(d.inputId)
3650
3650
  }] : [];
3651
- })) || [], l = $s({
3651
+ })) || [], l = Us({
3652
3652
  inputs: c,
3653
3653
  temporalBinding: r,
3654
3654
  card: e.card
@@ -3659,10 +3659,10 @@ function ta(e) {
3659
3659
  dateComparisonPlan: l
3660
3660
  };
3661
3661
  }
3662
- function $l(e) {
3663
- const t = U(e.filters), n = Un(e), o = t ? e.filterValues.find(
3662
+ function Ul(e) {
3663
+ const t = $(e.filters), n = $n(e), o = t ? e.filterValues.find(
3664
3664
  (s) => s.filterId === t.id
3665
- ) : void 0, r = Yn(e);
3665
+ ) : void 0, r = Jn(e);
3666
3666
  return !t || !o || !lt(o.operation) ? r : [
3667
3667
  {
3668
3668
  ...Qn({
@@ -3679,7 +3679,7 @@ function $l(e) {
3679
3679
  }
3680
3680
  class na extends Error {
3681
3681
  }
3682
- function Ul(e, t) {
3682
+ function $l(e, t) {
3683
3683
  const n = new Map((e ? H(e) : []).map(({ card: o }) => [o.id, o]));
3684
3684
  return t && n.set(t.id, t), [...n.values()].flatMap((o) => {
3685
3685
  const r = Le(o);
@@ -3693,7 +3693,7 @@ function oa(e, t, n) {
3693
3693
  ...n,
3694
3694
  spec: o.spec,
3695
3695
  catalog: t.map((u) => ({ ...u, id: u.resolvedField.id }))
3696
- }), i = r ? { ...o, spec: r.spec } : o, s = $o(t), a = Uo(t), c = (u) => {
3696
+ }), i = r ? { ...o, spec: r.spec } : o, s = Uo(t), a = $o(t), c = (u) => {
3697
3697
  const d = a(u, i.spec.source);
3698
3698
  if (!(!d && u.derivedField)) {
3699
3699
  if (!d) throw new na(`Matrix field metadata is unavailable: ${u.name}`);
@@ -3753,7 +3753,7 @@ function sa(e, t, n = {}) {
3753
3753
  if (o.length === 0) return e;
3754
3754
  const r = Wo.includes(
3755
3755
  t
3756
- ), i = Yo.includes(
3756
+ ), i = Jo.includes(
3757
3757
  t
3758
3758
  ), s = (l) => {
3759
3759
  var u;
@@ -3785,15 +3785,15 @@ function sa(e, t, n = {}) {
3785
3785
  } : e;
3786
3786
  }
3787
3787
  function Ql(e, t = {}) {
3788
- return Jn(Zn(e, t));
3788
+ return Yn(Zn(e, t));
3789
3789
  }
3790
- function Jn(e) {
3790
+ function Yn(e) {
3791
3791
  return ra([e.authored, e.drill, e.selections]);
3792
3792
  }
3793
3793
  function Zn(e, t = {}) {
3794
3794
  return {
3795
- authored: t.includeAuthoredFilters === !1 ? void 0 : Jo(e),
3796
- drill: Ps(t.drill, e.id),
3795
+ authored: t.includeAuthoredFilters === !1 ? void 0 : Yo(e),
3796
+ drill: xs(t.drill, e.id),
3797
3797
  selections: Rr(t.selections ?? [])
3798
3798
  };
3799
3799
  }
@@ -3803,7 +3803,7 @@ function aa(e, t, n) {
3803
3803
  { ...o, filters: n },
3804
3804
  e.type,
3805
3805
  // A data variable's card keeps its own period comparison (P3b-03).
3806
- { keepsPeriodComparison: xr(e) }
3806
+ { keepsPeriodComparison: Pr(e) }
3807
3807
  ) : o;
3808
3808
  }
3809
3809
  function la(e) {
@@ -3837,7 +3837,7 @@ function Xn(e, t, n) {
3837
3837
  const r = t.controlBindings.filter(
3838
3838
  (f) => !Fe(f)
3839
3839
  ), i = new Set(
3840
- Ye({
3840
+ Je({
3841
3841
  sql: e.sql,
3842
3842
  controlBindings: r
3843
3843
  })
@@ -3893,19 +3893,19 @@ function ua({
3893
3893
  (F) => F.status === "apply"
3894
3894
  ),
3895
3895
  drill: o == null ? void 0 : o.drill
3896
- }), h = Jn(y), I = f === !1 ? Me(h, !0) : h, v = aa(
3896
+ }), h = Yn(y), I = f === !1 ? Me(h, !0) : h, v = aa(
3897
3897
  e,
3898
3898
  o == null ? void 0 : o.drill,
3899
3899
  I
3900
3900
  ), D = us({ ...e, config: v }, r) ?? v, C = In(D, {
3901
3901
  cardType: e.type,
3902
3902
  dataSource: e.dataSource,
3903
- temporalResultOwner: $t({
3903
+ temporalResultOwner: Ut({
3904
3904
  hasExecutableConfig: Se(D, e.type),
3905
3905
  sql: e.sql,
3906
3906
  normalizedPython: je(e.python || "")
3907
3907
  })
3908
- }) || D, w = ia(I) || "", A = p ? Xn(
3908
+ }) || D, w = ia(I) || "", E = p ? Xn(
3909
3909
  e,
3910
3910
  {
3911
3911
  controlValues: p.controlValues,
@@ -3941,7 +3941,7 @@ function ua({
3941
3941
  dateComparisonInputs: p.dateComparisonInputs
3942
3942
  } : {}
3943
3943
  },
3944
- ...A,
3944
+ ...E,
3945
3945
  resolvedFilters: I,
3946
3946
  resolvedFilterParts: y,
3947
3947
  drillSteps: ((M = o == null ? void 0 : o.drill) == null ? void 0 : M.steps) ?? Xo,
@@ -4118,7 +4118,7 @@ function ba({
4118
4118
  (y) => y.status === "apply" ? [[y.inputId, y.filterValue]] : []
4119
4119
  )
4120
4120
  )
4121
- }), f = U(c), m = !!(f && d.cardFilterValues.some(
4121
+ }), f = $(c), m = !!(f && d.cardFilterValues.some(
4122
4122
  (y) => y.filterId === f.id
4123
4123
  )), g = d.resolvedPrimaryDateField && !((p = e.sql) != null && p.trim()) ? d.dateComparisonPlan.inputs.length ? fa({
4124
4124
  card: e,
@@ -4167,12 +4167,12 @@ function ha(e, t, n) {
4167
4167
  cardFilterValues: s,
4168
4168
  resolvedPrimaryDateField: a,
4169
4169
  globalDateComparison: c
4170
- } = i, { queryKey: l, queryInputIdentity: u, paginationConfig: d } = Ji(
4170
+ } = i, { queryKey: l, queryInputIdentity: u, paginationConfig: d } = Yi(
4171
4171
  e,
4172
4172
  r.queryContext,
4173
4173
  n.calendarContext,
4174
4174
  { resolvePaginationConfig: n.resolvePaginationConfig }
4175
- ), f = t.queryRelevantConfig, m = je(e.python || ""), g = $t({
4175
+ ), f = t.queryRelevantConfig, m = je(e.python || ""), g = Ut({
4176
4176
  hasExecutableConfig: Se(f, e.type),
4177
4177
  sql: e.sql,
4178
4178
  normalizedPython: m
@@ -4226,11 +4226,11 @@ function va({
4226
4226
  dashboardRuntimeValues: o,
4227
4227
  calendar: r
4228
4228
  }) {
4229
- const i = Ut({
4229
+ const i = $t({
4230
4230
  dashboard: t,
4231
4231
  dashboardInputValues: o.dashboardInputValues,
4232
4232
  transientContexts: void 0
4233
- }) ? Ue({
4233
+ }) ? $e({
4234
4234
  transientContexts: void 0,
4235
4235
  dashboard: t,
4236
4236
  sheetId: n.sheetId,
@@ -4278,7 +4278,7 @@ function Fa(e, t) {
4278
4278
  controls: Array.from(n.values())
4279
4279
  };
4280
4280
  }
4281
- function Yl({
4281
+ function Jl({
4282
4282
  card: e,
4283
4283
  place: t,
4284
4284
  source: n
@@ -4293,7 +4293,7 @@ function Yl({
4293
4293
  function Sa(e, t, n) {
4294
4294
  return {
4295
4295
  calendarContext: n ?? wr,
4296
- allowGlobalDateMinutePrecision: $e(
4296
+ allowGlobalDateMinutePrecision: Ue(
4297
4297
  e,
4298
4298
  t
4299
4299
  ).allEligibleTargetsAreDateTime,
@@ -4301,7 +4301,7 @@ function Sa(e, t, n) {
4301
4301
  globalCacheConfig: e.globalCacheConfig
4302
4302
  };
4303
4303
  }
4304
- function Jl(e, t) {
4304
+ function Yl(e, t) {
4305
4305
  return io(
4306
4306
  e,
4307
4307
  t,
@@ -4351,9 +4351,9 @@ function Da({
4351
4351
  message: "Matrix field metadata is required.",
4352
4352
  context: v
4353
4353
  };
4354
- const A = Ms(C.config.spec, v), M = r.filter(
4355
- (x) => x.field.source && A.some(
4356
- (E) => Oe(E, x.field.source)
4354
+ const E = Ms(C.config.spec, v), M = r.filter(
4355
+ (P) => P.field.source && E.some(
4356
+ (A) => Oe(A, P.field.source)
4357
4357
  )
4358
4358
  ), F = oa(h, M, v), { params: k } = w, O = k.dashboardInputContext;
4359
4359
  F.config = {
@@ -4377,15 +4377,15 @@ function Da({
4377
4377
  M
4378
4378
  )
4379
4379
  };
4380
- const P = {
4380
+ const x = {
4381
4381
  ...h,
4382
4382
  config: { matrix: F.config }
4383
- }, T = qe(P, I, n, !1);
4383
+ }, T = qe(x, I, n, !1);
4384
4384
  return {
4385
4385
  status: "ready",
4386
4386
  value: {
4387
4387
  assembled: {
4388
- card: P,
4388
+ card: x,
4389
4389
  context: { ...T.context, resolvedDateFields: F.fields },
4390
4390
  inputContext: T.inputContext
4391
4391
  },
@@ -4422,43 +4422,43 @@ function Da({
4422
4422
  const w = (p = m.dashboardInputContext) == null ? void 0 : p.inputs.find(
4423
4423
  (T) => T.kind === "filter" && T.filter.id === g.id
4424
4424
  ), M = or(s, g).filter(
4425
- ({ card: T, sheet: x }) => !w || Pr(w, {
4425
+ ({ card: T, sheet: P }) => !w || xr(w, {
4426
4426
  cardId: T.id,
4427
- sheetId: x.id,
4428
- sheetKind: Qt(x) ? "document" : "dashboard"
4427
+ sheetId: P.id,
4428
+ sheetKind: Qt(P) ? "document" : "dashboard"
4429
4429
  })
4430
- ).map(({ card: T, sheet: x }) => ({
4430
+ ).map(({ card: T, sheet: P }) => ({
4431
4431
  card: T,
4432
- value: T.id === a ? l : c(T, { kind: "sheet", sheetId: x.id })
4432
+ value: T.id === a ? l : c(T, { kind: "sheet", sheetId: P.id })
4433
4433
  })), F = new Map(
4434
- M.map(({ card: T, value: x }) => [
4434
+ M.map(({ card: T, value: P }) => [
4435
4435
  T.id,
4436
- x.status === "ready" ? x.value.assembled.card : null
4436
+ P.status === "ready" ? P.value.assembled.card : null
4437
4437
  ])
4438
4438
  ), k = new Map(
4439
- M.map(({ card: T, value: x }) => {
4440
- var E;
4439
+ M.map(({ card: T, value: P }) => {
4440
+ var A;
4441
4441
  return [
4442
4442
  T.id,
4443
- x.status === "ready" ? (E = x.value.matrix) == null ? void 0 : E.fields : void 0
4443
+ P.status === "ready" ? (A = P.value.matrix) == null ? void 0 : A.fields : void 0
4444
4444
  ];
4445
4445
  })
4446
4446
  ), O = M.flatMap(
4447
- ({ card: T, value: x }) => {
4448
- const E = T.id, R = x.status === "ready" ? x.value.assembled.context : x.context;
4449
- if (!R) return [E];
4450
- const z = x.status === "ready" ? x.value.assembled.card : T;
4447
+ ({ card: T, value: P }) => {
4448
+ const A = T.id, R = P.status === "ready" ? P.value.assembled.context : P.context;
4449
+ if (!R) return [A];
4450
+ const z = P.status === "ready" ? P.value.assembled.card : T;
4451
4451
  try {
4452
- const Y = Ke(
4452
+ const J = Ke(
4453
4453
  z,
4454
4454
  R.filterCompilationInput
4455
4455
  );
4456
- return Y.status === "blocked" || Y.filterValues.some((ce) => ce.filterId === g.id) ? [E] : [];
4456
+ return J.status === "blocked" || J.filterValues.some((ce) => ce.filterId === g.id) ? [A] : [];
4457
4457
  } catch {
4458
- return F.set(E, null), [E];
4458
+ return F.set(A, null), [A];
4459
4459
  }
4460
4460
  }
4461
- ), P = $e(
4461
+ ), x = Ue(
4462
4462
  s,
4463
4463
  o,
4464
4464
  g,
@@ -4466,16 +4466,16 @@ function Da({
4466
4466
  k,
4467
4467
  O
4468
4468
  );
4469
- if ((y = P.unresolvedCardIds) != null && y.length)
4469
+ if ((y = x.unresolvedCardIds) != null && y.length)
4470
4470
  return {
4471
4471
  status: "blocked",
4472
4472
  cardId: a,
4473
4473
  mappingDispositions: [],
4474
4474
  reason: "coverage",
4475
4475
  missingRequiredLabels: [],
4476
- message: `Date precision requires field metadata and valid inputs for: ${P.unresolvedCardIds.join(", ")}.`
4476
+ message: `Date precision requires field metadata and valid inputs for: ${x.unresolvedCardIds.join(", ")}.`
4477
4477
  };
4478
- v = P.allEligibleTargetsAreDateTime;
4478
+ v = x.allEligibleTargetsAreDateTime;
4479
4479
  }
4480
4480
  const D = io(u, f, v);
4481
4481
  if (D.status === "blocked")
@@ -4560,11 +4560,11 @@ function oo(e, t) {
4560
4560
  }
4561
4561
  function Va(e, t, n, o, r) {
4562
4562
  var l, u;
4563
- const { dashboard: i } = n, s = oo(i, e.id), a = s ? void 0 : n.transientContexts, c = Ut({
4563
+ const { dashboard: i } = n, s = oo(i, e.id), a = s ? void 0 : n.transientContexts, c = $t({
4564
4564
  dashboard: i,
4565
4565
  dashboardInputValues: o.dashboardInputValues,
4566
4566
  transientContexts: a
4567
- }) ? Ue({
4567
+ }) ? $e({
4568
4568
  transientContexts: a,
4569
4569
  dashboard: i,
4570
4570
  sheetId: t,
@@ -4625,7 +4625,7 @@ function Zl({
4625
4625
  }) {
4626
4626
  const u = e ? [...rr(e)] : void 0, d = r ?? null, f = (I) => {
4627
4627
  var v;
4628
- return e ? Pa({
4628
+ return e ? xa({
4629
4629
  dashboard: e,
4630
4630
  runtimeValues: { dashboardInputValues: t },
4631
4631
  adHocFilterValues: n,
@@ -4653,7 +4653,7 @@ function Zl({
4653
4653
  const y = ir({
4654
4654
  filterDefinitions: u,
4655
4655
  filterValues: m
4656
- }), h = Js({
4656
+ }), h = Ys({
4657
4657
  filters: u,
4658
4658
  filterValues: y,
4659
4659
  dashboard: e,
@@ -4738,7 +4738,7 @@ function ka(e, t, n) {
4738
4738
  ..."temporalPrecision" in e && e.temporalPrecision === "minute" ? { temporalPrecision: "minute" } : {}
4739
4739
  };
4740
4740
  }
4741
- function xa(e, t, n) {
4741
+ function Pa(e, t, n) {
4742
4742
  const o = t, r = ar(e);
4743
4743
  return lr({
4744
4744
  definition: e,
@@ -4766,7 +4766,7 @@ function so(e, t, n) {
4766
4766
  continue;
4767
4767
  }
4768
4768
  const u = sr(
4769
- xa(l.filter, a, n.calendar)
4769
+ Pa(l.filter, a, n.calendar)
4770
4770
  );
4771
4771
  if (u) {
4772
4772
  if (l.runtimeScope === "shared") {
@@ -4784,7 +4784,7 @@ function so(e, t, n) {
4784
4784
  }
4785
4785
  return { slots: r, adHocFilterValues: i, droppedFilterIds: s };
4786
4786
  }
4787
- function Pa(e) {
4787
+ function xa(e) {
4788
4788
  const { dashboard: t, sheetId: n } = e, o = [];
4789
4789
  if (n)
4790
4790
  for (const { input: r } of ur(t, n, e.sheetKind)) {
@@ -4850,7 +4850,7 @@ function Oa(e, t, n, o) {
4850
4850
  var l, u, d;
4851
4851
  const r = {}, i = (l = e.preferences) == null ? void 0 : l.textVisualOptions;
4852
4852
  if (!i) return r;
4853
- const s = Ue({
4853
+ const s = $e({
4854
4854
  // Authoring: carried drill context never applies to a dashboard being edited.
4855
4855
  transientContexts: void 0,
4856
4856
  dashboard: n,
@@ -4876,7 +4876,7 @@ function Oa(e, t, n, o) {
4876
4876
  f.type === "list" ? f.items.forEach((m) => m.forEach(c)) : f.children.forEach(c);
4877
4877
  }), r;
4878
4878
  }
4879
- function Aa(e, t) {
4879
+ function Ea(e, t) {
4880
4880
  var i;
4881
4881
  const n = _t(e);
4882
4882
  if (!n.some((s) => {
@@ -4901,23 +4901,23 @@ function Aa(e, t) {
4901
4901
  }
4902
4902
  return o;
4903
4903
  }
4904
- function Ea(e) {
4904
+ function Aa(e) {
4905
4905
  var n;
4906
4906
  const t = (n = e.sheets) == null ? void 0 : n.map(
4907
- (o) => Aa(o, e)
4907
+ (o) => Ea(o, e)
4908
4908
  );
4909
4909
  return t && t.some((o, r) => o !== e.sheets[r]) ? { ...e, sheets: t } : e;
4910
4910
  }
4911
4911
  function Ba(e) {
4912
4912
  const t = q(e);
4913
4913
  return t.issues.length === 0 && !t.needsUpgrade ? e : t.issues.length ? t.toStoredDashboard() : q(
4914
- Ea(e)
4914
+ Aa(e)
4915
4915
  ).toStoredDashboard();
4916
4916
  }
4917
4917
  export {
4918
4918
  rt as $,
4919
4919
  so as A,
4920
- Pa as B,
4920
+ xa as B,
4921
4921
  ec as C,
4922
4922
  da as D,
4923
4923
  eo as E,
@@ -4925,12 +4925,12 @@ export {
4925
4925
  tl as G,
4926
4926
  di as H,
4927
4927
  Ts as I,
4928
- xt as J,
4928
+ Pt as J,
4929
4929
  Il as K,
4930
4930
  oi as L,
4931
4931
  bl as M,
4932
- Pi as N,
4933
- xi as O,
4932
+ xi as N,
4933
+ Pi as O,
4934
4934
  Vi as P,
4935
4935
  ul as Q,
4936
4936
  Sn as R,
@@ -4938,8 +4938,8 @@ export {
4938
4938
  il as T,
4939
4939
  fs as U,
4940
4940
  ps as V,
4941
- Ai as W,
4942
- $ as X,
4941
+ Ei as W,
4942
+ U as X,
4943
4943
  gl as Y,
4944
4944
  Bi as Z,
4945
4945
  yl as _,
@@ -4952,12 +4952,12 @@ export {
4952
4952
  wi as a4,
4953
4953
  ll as a5,
4954
4954
  nt as a6,
4955
- An as a7,
4956
- Jl as a8,
4955
+ En as a7,
4956
+ Yl as a8,
4957
4957
  Sa as a9,
4958
4958
  On as aA,
4959
4959
  Wl as aB,
4960
- $l as aC,
4960
+ Ul as aC,
4961
4961
  se as aD,
4962
4962
  yn as aE,
4963
4963
  rl as aF,
@@ -4966,7 +4966,7 @@ export {
4966
4966
  Da as aI,
4967
4967
  yi as aJ,
4968
4968
  sl as aK,
4969
- Ul as aL,
4969
+ $l as aL,
4970
4970
  pn as aM,
4971
4971
  fl as aN,
4972
4972
  Hl as aO,
@@ -4978,14 +4978,14 @@ export {
4978
4978
  cl as aU,
4979
4979
  na as aV,
4980
4980
  Wn as aW,
4981
- Ye as aX,
4981
+ Je as aX,
4982
4982
  pl as aY,
4983
4983
  Dl as aZ,
4984
4984
  Ml as a_,
4985
4985
  _t as aa,
4986
4986
  wa as ab,
4987
4987
  Oa as ac,
4988
- Aa as ad,
4988
+ Ea as ad,
4989
4989
  Zi as ae,
4990
4990
  Ll as af,
4991
4991
  ql as ag,
@@ -4997,27 +4997,27 @@ export {
4997
4997
  aa as am,
4998
4998
  Ql as an,
4999
4999
  Tl as ao,
5000
- Yl as ap,
5000
+ Jl as ap,
5001
5001
  bs as aq,
5002
5002
  hs as ar,
5003
5003
  Ta as as,
5004
5004
  kl as at,
5005
- xl as au,
5005
+ Pl as au,
5006
5006
  Is as av,
5007
5007
  Re as aw,
5008
5008
  ys as ax,
5009
5009
  vs as ay,
5010
- Pl as az,
5010
+ xl as az,
5011
5011
  hl as b,
5012
5012
  Fl as b0,
5013
5013
  Sl as b1,
5014
5014
  Vl as b2,
5015
5015
  gs as b3,
5016
5016
  ne as b4,
5017
- El as b5,
5017
+ Al as b5,
5018
5018
  zl as b6,
5019
5019
  jl as b7,
5020
- Ji as c,
5020
+ Yi as c,
5021
5021
  la as d,
5022
5022
  ei as e,
5023
5023
  vl as f,
@@ -5030,8 +5030,8 @@ export {
5030
5030
  Xl as m,
5031
5031
  Rl as n,
5032
5032
  st as o,
5033
- Al as p,
5034
- xa as q,
5033
+ El as p,
5034
+ Pa as q,
5035
5035
  Bl as r,
5036
5036
  Ds as s,
5037
5037
  Ms as t,