react-semaphor 0.1.561 → 0.1.562

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 (138) hide show
  1. package/dist/analytics-protocol/index.js +452 -429
  2. package/dist/assistant-context/index.js +1 -1
  3. package/dist/assistant-protocol/index.js +5 -5
  4. package/dist/brand-studio/index.js +9 -9
  5. package/dist/briefings/index.js +5 -5
  6. package/dist/chunks/{analytics-base-schemas-CB3oFAXk.js → analytics-base-schemas-BaIQrEzX.js} +139 -134
  7. package/dist/chunks/{assistant-chat-DiVHY3Hw.js → assistant-chat-R_yT8xH4.js} +104 -104
  8. package/dist/chunks/{bookmark-impact-CR09dpkn.js → bookmark-impact-D4Kl4amw.js} +2 -2
  9. package/dist/chunks/{bookmark-state-BusLpkb7.js → bookmark-state-CWeoGbrx.js} +25 -25
  10. package/dist/chunks/{braces-u8VorWJc.js → braces-DzgoQC64.js} +1 -1
  11. package/dist/chunks/{comparison-window-caption-DDsIWJYT.js → comparison-window-caption-D1EUXzaR.js} +562 -437
  12. package/dist/chunks/{context-TUjw9eqr.js → context-R31TSL5V.js} +1 -1
  13. package/dist/chunks/{dashboard-BRdZBPqr.js → dashboard-Bp1y5oun.js} +1 -1
  14. package/dist/chunks/{dashboard-briefing-launcher-CgvTLndW.js → dashboard-briefing-launcher-S5FB3aUW.js} +155 -154
  15. package/dist/chunks/{dashboard-controls-B4vfSzTF.js → dashboard-controls-CfC_6Ztn.js} +970 -968
  16. package/dist/chunks/{dashboard-json-Y3MF59g7.js → dashboard-json-gYZT7ZQY.js} +5 -5
  17. package/dist/chunks/dates-DFY7Gfss.js +91 -0
  18. package/dist/chunks/{edit-dashboard-visual-DwjZcxj-.js → edit-dashboard-visual-u7OI_g8Q.js} +4636 -4681
  19. package/dist/chunks/{filter-reach-copy-bijwf_-b.js → filter-reach-copy-CvV7W5dd.js} +1470 -1101
  20. package/dist/chunks/{filter-value-text-DFnhwuEW.js → filter-value-text-CPwFkrMz.js} +11 -10
  21. package/dist/chunks/{global-date-filter-utils-BXgCpvQM.js → global-date-filter-utils-N1kcsOFE.js} +8997 -7417
  22. package/dist/chunks/{index-ClwbY3BL.js → index-CNGkfUp4.js} +91 -85
  23. package/dist/chunks/{layout-grid-CtvCBfOm.js → layout-grid-BM65viQh.js} +1 -1
  24. package/dist/chunks/{list-filter-BklYgciR.js → list-filter-BoeLBfL3.js} +1 -1
  25. package/dist/chunks/{matrix-analytical-definition-pU51-JmY.js → matrix-analytical-definition-hEucouWM.js} +4 -4
  26. package/dist/chunks/{matrix-card-CUorIB7Q.js → matrix-card-CCh9JjP1.js} +3 -3
  27. package/dist/chunks/{matrix-member-presentation-Df5UgCGN.js → matrix-member-presentation-DsAUbuoL.js} +1 -1
  28. package/dist/chunks/{matrix-operation-contract-BSiGEXVC.js → matrix-operation-contract-DsLdFdSa.js} +339 -330
  29. package/dist/chunks/{metric-comparison-95aC0uEO.js → metric-comparison-Bnso1cm1.js} +2 -2
  30. package/dist/chunks/{model-change-B5wQhg5G.js → model-change-T1cRkh3m.js} +1 -1
  31. package/dist/chunks/{palette-DTnMhipt.js → palette-p1XSJFgB.js} +1 -1
  32. package/dist/chunks/{pivot-result-contract-expectations-Bo-86vwS.js → pivot-result-contract-expectations-B53jqszr.js} +5 -5
  33. package/dist/chunks/{pivot-result-identity-olvXJoB9.js → pivot-result-identity-Dq5jm-EC.js} +1 -1
  34. package/dist/chunks/{zoned-wall-clock-CGLVI40Q.js → raw-temporal-value-Bqz8wc7L.js} +97 -46
  35. package/dist/chunks/{report-preferences-dialog-C2YUIwKG.js → report-preferences-dialog-C4RAR8u5.js} +68 -63
  36. package/dist/chunks/{report-runtime-context-DoIUr3MP.js → report-runtime-context-BITkNSDa.js} +2 -2
  37. package/dist/chunks/{resolve-dashboard-input-context-q_iiNXE1.js → resolve-dashboard-input-context-DaDrZGuA.js} +3455 -1744
  38. package/dist/chunks/{save-DH4RyrnG.js → save-CHV1B1fL.js} +1 -1
  39. package/dist/chunks/{saved-dashboard-context-8jqfI7hI.js → saved-dashboard-context-DFYBrE6O.js} +94 -95
  40. package/dist/chunks/{selection-filter-compiler-BKXmyLrS.js → selection-filter-compiler-CUDRnUxc.js} +19 -18
  41. package/dist/chunks/{selection-reducer-CV7K4FI6.js → selection-reducer-Bz5aywT4.js} +1 -1
  42. package/dist/chunks/{semaphor-ready-indicator-E2XWyibu.js → semaphor-ready-indicator-Cfuafnem.js} +37067 -38400
  43. package/dist/chunks/{shelf-drop-preview-context-C29EUzDp.js → shelf-drop-preview-context-BR2GEYog.js} +81 -82
  44. package/dist/chunks/{source-entity-resolution-BXI3nQ5Z.js → source-entity-resolution-DdDVXFB8.js} +6 -6
  45. package/dist/chunks/{switch-balDSHc7.js → switch-BW4yXSYs.js} +3 -3
  46. package/dist/chunks/{table-export-sheet-CK8tvh4d.js → table-export-sheet-bSXxGn-v.js} +1 -1
  47. package/dist/chunks/{temporal-input-presentation-B77JsAzU.js → temporal-input-presentation-sk9gqLi6.js} +699 -741
  48. package/dist/chunks/{token-types-DhYH5YKb.js → token-types-BUK06hU2.js} +1 -1
  49. package/dist/chunks/{upload-Ufj8vjyn.js → upload-BnmuyPqW.js} +1 -1
  50. package/dist/chunks/{use-create-flow-overlay-state-9WsnzEO5.js → use-create-flow-overlay-state-DyzhWvRJ.js} +6 -6
  51. package/dist/chunks/{validators-BtaCFIEB.js → validators-BIM0FE31.js} +764 -885
  52. package/dist/dashboard/index.js +2 -2
  53. package/dist/dashboard-authoring/index.js +2278 -3030
  54. package/dist/data-app-sdk/index.js +43 -43
  55. package/dist/data-app-sdk-adapters/index.js +3 -3
  56. package/dist/data-app-sdk-validation/index.js +22 -22
  57. package/dist/format-utils/index.js +215 -209
  58. package/dist/index.js +225 -224
  59. package/dist/report-runtime-context/index.js +2 -2
  60. package/dist/style.css +1 -1
  61. package/dist/surfboard/index.js +2 -2
  62. package/dist/types/briefings/attachment-outcomes.d.ts +1 -1
  63. package/dist/types/components/dashboard/dashboard-create-dialog.d.ts +23 -0
  64. package/dist/types/components/index.d.ts +1 -2
  65. package/dist/types/components/surfboard/filter/types.d.ts +3 -1
  66. package/dist/types/index.js +5 -5
  67. package/dist/types/lib/formatters/raw-temporal-presentation.d.ts +59 -2
  68. package/dist/types/lib/interactions/get-click-context-from-matrix.d.ts +5 -0
  69. package/dist/types/lib/interactions/get-click-context-from-table.d.ts +45 -0
  70. package/dist/types/lib/print/print-inputs.d.ts +2 -1
  71. package/dist/types/lib/query-context/assemble-card-query.d.ts +2 -0
  72. package/dist/types/lib/query-context/build-dashboard-execution-snapshot.d.ts +5 -0
  73. package/dist/types/lib/selection/selection-from-click-context.d.ts +41 -0
  74. package/dist/types/lib/types/common-types.d.ts +6 -0
  75. package/dist/types/lib/types/explorer-types.d.ts +7 -1
  76. package/dist/types/lib/types/interaction-types.d.ts +3 -1
  77. package/dist/types/lib/types/token-types.d.ts +0 -1
  78. package/dist/types/shared/analytics-protocol/analytics-base-schemas.d.ts +3 -1
  79. package/dist/types/shared/analytics-protocol/contracts.d.ts +9 -40
  80. package/dist/types/shared/analytics-protocol/selection-contract.d.ts +12 -2
  81. package/dist/types/shared/analytics-protocol/validators.d.ts +1 -2
  82. package/dist/types/shared/assistant-protocol/context.d.ts +8 -8
  83. package/dist/types/shared/dashboard-authoring/card-formats/sql-date-pattern.d.ts +7 -1
  84. package/dist/types/shared/dashboard-authoring/card-settings/card-display-write.d.ts +24 -0
  85. package/dist/types/shared/dashboard-authoring/card-settings/card-kinds.d.ts +1 -1
  86. package/dist/types/shared/dashboard-authoring/card-settings/column-polarity-write.d.ts +5 -0
  87. package/dist/types/shared/dashboard-authoring/card-settings/index.d.ts +4 -2
  88. package/dist/types/shared/dashboard-authoring/card-settings/inputs.d.ts +15 -0
  89. package/dist/types/shared/dashboard-authoring/card-settings/resolved.d.ts +12 -1
  90. package/dist/types/shared/dashboard-authoring/card-settings/views.d.ts +5 -3
  91. package/dist/types/shared/dashboard-authoring/changes/dashboard-change.d.ts +3230 -4658
  92. package/dist/types/shared/dashboard-authoring/changes/diagnostics.d.ts +24 -2
  93. package/dist/types/shared/dashboard-authoring/changes/field-ref.d.ts +91 -0
  94. package/dist/types/shared/dashboard-authoring/changes/read-card-query.d.ts +7 -0
  95. package/dist/types/shared/dashboard-authoring/changes/resolve-dashboard-changes.d.ts +27 -1
  96. package/dist/types/shared/dashboard-authoring/changes/resolve-dashboard-create.d.ts +26 -0
  97. package/dist/types/shared/dashboard-authoring/click-to-filter-settings.d.ts +2 -1
  98. package/dist/types/shared/dashboard-authoring/conditional-formatting/schema.d.ts +10 -10
  99. package/dist/types/shared/dashboard-authoring/detail-date-presentation.d.ts +9 -0
  100. package/dist/types/shared/dashboard-authoring/index.d.ts +8 -6
  101. package/dist/types/shared/dashboard-authoring/measure-calculations/apply.d.ts +8 -0
  102. package/dist/types/shared/dashboard-authoring/measure-calculations/comparison.d.ts +16 -0
  103. package/dist/types/shared/dashboard-authoring/measure-calculations/dates.d.ts +41 -0
  104. package/dist/types/shared/dashboard-authoring/measure-calculations/index.d.ts +17 -0
  105. package/dist/types/shared/dashboard-authoring/measure-calculations/options.d.ts +63 -0
  106. package/dist/types/shared/dashboard-authoring/measure-calculations/read.d.ts +16 -0
  107. package/dist/types/shared/dashboard-authoring/measure-calculations/resolve.d.ts +79 -0
  108. package/dist/types/shared/dashboard-authoring/measure-calculations/schemas.d.ts +934 -0
  109. package/dist/types/shared/dashboard-authoring/measure-calculations/sentences.d.ts +4 -0
  110. package/dist/types/shared/dashboard-authoring/measure-calculations/set.d.ts +11 -0
  111. package/dist/types/shared/dashboard-authoring/measure-calculations/transform.d.ts +63 -0
  112. package/dist/types/shared/dashboard-authoring/measure-calculations/window-transforms.d.ts +60 -0
  113. package/dist/types/shared/dashboard-authoring/new-card.d.ts +12 -1
  114. package/dist/types/shared/dashboard-authoring/operations/apply-dashboard-operations.d.ts +2 -1
  115. package/dist/types/shared/dashboard-authoring/operations/operation-sentences.d.ts +46 -0
  116. package/dist/types/shared/dashboard-authoring/operations/operation-types.d.ts +52 -2
  117. package/dist/types/shared/dashboard-authoring/outline/outline-dashboard.d.ts +13 -1
  118. package/dist/types/shared/dashboard-authoring/text-card-words/blocks.d.ts +58 -0
  119. package/dist/types/shared/dashboard-authoring/text-card-words/index.d.ts +55 -0
  120. package/dist/types/shared/dashboard-authoring/text-card-words/rich-content.d.ts +18 -0
  121. package/dist/types/shared/format-utils/document-print.d.ts +82 -0
  122. package/dist/types/shared/format-utils/index.d.ts +1 -0
  123. package/dist/types/shared/format-utils/raw-temporal.d.ts +2 -7
  124. package/dist/types/shared/temporal/index.d.ts +1 -0
  125. package/dist/types/shared/temporal/raw-temporal-equality.d.ts +19 -0
  126. package/dist/types/shared/temporal/raw-temporal-value.d.ts +29 -0
  127. package/dist/types/shared/temporal/zoned-wall-clock.d.ts +6 -0
  128. package/package.json +1 -1
  129. package/dist/chunks/custom-visual-inputs-DfolidZ9.js +0 -292
  130. package/dist/chunks/document-dashboard-inputs-CvBbFTUA.js +0 -1718
  131. package/dist/types/components/dashboard/ai-dashboard-create-dialog.d.ts +0 -38
  132. package/dist/types/components/dashboard/dashboard-create-template.d.ts +0 -10
  133. package/dist/types/lib/hooks/use-dashboard-authoring.d.ts +0 -49
  134. package/dist/types/shared/dashboard-authoring/artifact-compiler.d.ts +0 -6
  135. package/dist/types/shared/dashboard-authoring/contracts.d.ts +0 -106
  136. package/dist/types/shared/dashboard-authoring/protocol-adapter.d.ts +0 -7
  137. package/dist/types/shared/dashboard-authoring/source-matching.d.ts +0 -34
  138. package/dist/types/shared/dashboard-authoring/validators.d.ts +0 -2
@@ -1,24 +1,24 @@
1
- import { M as ve, x as O, w as It, B as St, C as kt, E as wt, G as At, v as xt, h as je, j as X, k as Ft, b as Dt, d as Ye } from "./analytics-base-schemas-CB3oFAXk.js";
1
+ import { M as be, y as O, x as yt, C as bt, D as vt, F as It, H as St, w as At, h as $e, j as X, k as wt, m as kt, b as xt, d as je } from "./analytics-base-schemas-BaIQrEzX.js";
2
2
  import { z as a } from "zod";
3
- function Mt(e) {
3
+ function Ft(e) {
4
4
  return typeof e == "string" || typeof e == "number" && Number.isFinite(e) || typeof e == "boolean";
5
5
  }
6
- function Et(e) {
7
- return !Array.isArray(e) || e.length === 0 || e.length > ve || !e.every(Mt) ? {
6
+ function Dt(e) {
7
+ return !Array.isArray(e) || e.length === 0 || e.length > be || !e.every(Ft) ? {
8
8
  ok: !1,
9
- error: `matchValues must be 1 to ${ve} string, number or boolean values.`
9
+ error: `matchValues must be 1 to ${be} string, number or boolean values.`
10
10
  } : { ok: !0, values: e };
11
11
  }
12
- const Tt = [
12
+ const Mt = [
13
13
  "day",
14
14
  "week",
15
15
  "month",
16
16
  "quarter",
17
17
  "year"
18
- ], Ma = ["this", "previous"], Nt = ["now", "latest_available"], Rt = [
18
+ ], Fa = ["this", "previous"], Et = ["now", "latest_available"], Nt = [
19
19
  "include_partial",
20
20
  "complete_periods"
21
- ], Ea = {
21
+ ], Da = {
22
22
  second: 31536e4,
23
23
  minute: 5256e3,
24
24
  hour: 87600,
@@ -28,23 +28,23 @@ const Tt = [
28
28
  quarter: 40,
29
29
  year: 10
30
30
  };
31
- function Ct(e) {
31
+ function Tt(e) {
32
32
  return e.anchor ?? "latest_available";
33
33
  }
34
34
  function M(e) {
35
35
  return !!e && (e.kind === void 0 || e.kind === "relative");
36
36
  }
37
- function $t(e) {
37
+ function Rt(e) {
38
38
  return (e == null ? void 0 : e.kind) === "calendar";
39
39
  }
40
- function Ta(e) {
41
- return M(e) && e.anchor === "latest_available" || Yt(e) ? null : M(e) && e.unit === "day" && e.completeness !== "complete_periods" ? { mode: "between", unit: "day", from: 1 - e.value, to: 0 } : Ot(M(e) ? { ...e, anchor: "now" } : e);
40
+ function Ma(e) {
41
+ return M(e) && e.anchor === "latest_available" || $t(e) ? null : M(e) && e.unit === "day" && e.completeness !== "complete_periods" ? { mode: "between", unit: "day", from: 1 - e.value, to: 0 } : jt(M(e) ? { ...e, anchor: "now" } : e);
42
42
  }
43
- const jt = /* @__PURE__ */ new Set(["week", "month", "quarter", "year"]);
44
- function Yt(e) {
45
- return M(e) && jt.has(e.unit) && e.completeness !== "complete_periods";
43
+ const Ct = /* @__PURE__ */ new Set(["week", "month", "quarter", "year"]);
44
+ function $t(e) {
45
+ return M(e) && Ct.has(e.unit) && e.completeness !== "complete_periods";
46
46
  }
47
- function Na(e) {
47
+ function Ea(e) {
48
48
  const t = e;
49
49
  return t.mode === "between" ? t.unit === "day" && t.to === 0 && typeof t.from == "number" && t.from <= 0 ? { unit: "day", value: 1 - t.from } : null : t.mode === "last" && typeof t.n == "number" ? t.relativeTo === "latest_data" ? null : {
50
50
  unit: t.unit,
@@ -53,8 +53,8 @@ function Na(e) {
53
53
  completeness: t.complete ? "complete_periods" : "include_partial"
54
54
  } : t.mode === "this" ? t.boundary ? null : { kind: "calendar", unit: t.unit, period: "this", ...t.toDate ? { toDate: !0 } : {} } : t.mode === "previous" ? { kind: "calendar", unit: t.unit, period: "previous" } : null;
55
55
  }
56
- function Ot(e, t = {}) {
57
- if ($t(e))
56
+ function jt(e, t = {}) {
57
+ if (Rt(e))
58
58
  return e.period === "previous" ? { mode: "previous", unit: e.unit } : {
59
59
  mode: "this",
60
60
  unit: e.unit,
@@ -62,7 +62,7 @@ function Ot(e, t = {}) {
62
62
  };
63
63
  if (!M(e))
64
64
  return null;
65
- const i = Ct(e) === "latest_available" ? { relativeTo: "latest_data" } : {}, s = e.value, l = (t.completeness ?? e.completeness) === "complete_periods";
65
+ const i = Tt(e) === "latest_available" ? { relativeTo: "latest_data" } : {}, s = e.value, l = (t.completeness ?? e.completeness) === "complete_periods";
66
66
  switch (e.unit) {
67
67
  case "second":
68
68
  return null;
@@ -79,39 +79,39 @@ function Ot(e, t = {}) {
79
79
  };
80
80
  }
81
81
  }
82
- function r(e, t, i) {
82
+ function o(e, t, i) {
83
83
  return i ? { code: e, message: t, path: i } : { code: e, message: t };
84
84
  }
85
- function c(e) {
85
+ function m(e) {
86
86
  return typeof e == "string" && e.trim().length > 0;
87
87
  }
88
- function Pt(e) {
88
+ function Yt(e) {
89
89
  const t = /* @__PURE__ */ new Set();
90
- return qt(e, (i) => (t.add(i), `{${i}}`)), Array.from(t);
90
+ return Ot(e, (i) => (t.add(i), `{${i}}`)), Array.from(t);
91
91
  }
92
- function qt(e, t) {
92
+ function Ot(e, t) {
93
93
  let i = "", s = 0, l = 0;
94
94
  for (; l < e.length; ) {
95
95
  const n = e[l];
96
96
  if (n === "'" || n === '"') {
97
- l = Lt(e, l);
97
+ l = Pt(e, l);
98
98
  continue;
99
99
  }
100
100
  if (n === "{") {
101
- const o = e.indexOf("}", l + 1);
102
- if (o === -1) {
101
+ const r = e.indexOf("}", l + 1);
102
+ if (r === -1) {
103
103
  l += 1;
104
104
  continue;
105
105
  }
106
- const d = e.slice(l + 1, o);
107
- /^[A-Za-z_][A-Za-z0-9_]*$/.test(d) && (i += e.slice(s, l) + t(d), s = o + 1), l = o + 1;
106
+ const d = e.slice(l + 1, r);
107
+ /^[A-Za-z_][A-Za-z0-9_]*$/.test(d) && (i += e.slice(s, l) + t(d), s = r + 1), l = r + 1;
108
108
  continue;
109
109
  }
110
110
  l += 1;
111
111
  }
112
112
  return i + e.slice(s);
113
113
  }
114
- function Lt(e, t) {
114
+ function Pt(e, t) {
115
115
  const i = e[t];
116
116
  let s = t + 1;
117
117
  for (; s < e.length; ) {
@@ -129,7 +129,7 @@ function Lt(e, t) {
129
129
  function f(e) {
130
130
  return !!(e && typeof e == "object" && !Array.isArray(e));
131
131
  }
132
- const Bt = /* @__PURE__ */ new Set([
132
+ const qt = /* @__PURE__ */ new Set([
133
133
  "SUM",
134
134
  "COUNT",
135
135
  "AVG",
@@ -138,22 +138,22 @@ const Bt = /* @__PURE__ */ new Set([
138
138
  "MEDIAN",
139
139
  "DISTINCT"
140
140
  ]);
141
- function se(e, t, i) {
141
+ function ne(e, t, i) {
142
142
  if (!e || typeof e != "object") {
143
143
  i.push(
144
- r("missing_source", "Analytics intent needs a source.", t)
144
+ o("missing_source", "Analytics intent needs a source.", t)
145
145
  );
146
146
  return;
147
147
  }
148
148
  if (e.kind === "semantic") {
149
- c(e.domainId) || i.push(
150
- r(
149
+ m(e.domainId) || i.push(
150
+ o(
151
151
  "missing_semantic_domain",
152
152
  "Semantic source needs a domainId.",
153
153
  `${t}.domainId`
154
154
  )
155
- ), c(e.datasetName) || i.push(
156
- r(
155
+ ), m(e.datasetName) || i.push(
156
+ o(
157
157
  "missing_dataset_name",
158
158
  "Semantic source needs a datasetName.",
159
159
  `${t}.datasetName`
@@ -162,14 +162,14 @@ function se(e, t, i) {
162
162
  return;
163
163
  }
164
164
  if (e.kind === "physical") {
165
- c(e.connectionId) || i.push(
166
- r(
165
+ m(e.connectionId) || i.push(
166
+ o(
167
167
  "missing_connection_id",
168
168
  "Physical source needs a connectionId.",
169
169
  `${t}.connectionId`
170
170
  )
171
- ), c(e.tableName) || i.push(
172
- r(
171
+ ), m(e.tableName) || i.push(
172
+ o(
173
173
  "missing_table_name",
174
174
  "Physical source needs a tableName.",
175
175
  `${t}.tableName`
@@ -178,8 +178,8 @@ function se(e, t, i) {
178
178
  return;
179
179
  }
180
180
  if (e.kind === "sql") {
181
- c(e.connectionId) || i.push(
182
- r(
181
+ m(e.connectionId) || i.push(
182
+ o(
183
183
  "missing_connection_id",
184
184
  "SQL source needs a connectionId.",
185
185
  `${t}.connectionId`
@@ -188,40 +188,40 @@ function se(e, t, i) {
188
188
  return;
189
189
  }
190
190
  i.push(
191
- r("invalid_source_kind", "Source kind is not supported.", t)
191
+ o("invalid_source_kind", "Source kind is not supported.", t)
192
192
  );
193
193
  }
194
- function _(e, t, i, s = {}) {
194
+ function y(e, t, i, s = {}) {
195
195
  if (!e || !f(e)) {
196
196
  s.required && i.push(
197
- r("missing_field_ref", "Field reference needs a name.", t)
197
+ o("missing_field_ref", "Field reference needs a name.", t)
198
198
  );
199
199
  return;
200
200
  }
201
- c(e.name) || i.push(
202
- r(
201
+ m(e.name) || i.push(
202
+ o(
203
203
  "missing_field_ref",
204
204
  "Field reference needs a name.",
205
205
  `${t}.name`
206
206
  )
207
- ), e.source !== void 0 && se(e.source, `${t}.source`, i), re(e.aggregate, `${t}.aggregate`, i);
207
+ ), e.source !== void 0 && ne(e.source, `${t}.source`, i), se(e.aggregate, `${t}.aggregate`, i);
208
208
  }
209
- function re(e, t, i) {
210
- e !== void 0 && (typeof e != "string" || !Bt.has(e)) && i.push(
211
- r(
209
+ function se(e, t, i) {
210
+ e !== void 0 && (typeof e != "string" || !qt.has(e)) && i.push(
211
+ o(
212
212
  "invalid_aggregate",
213
213
  "Field aggregate must be SUM, COUNT, AVG, MIN, MAX, MEDIAN, or DISTINCT.",
214
214
  t
215
215
  )
216
216
  );
217
217
  }
218
- const Ht = /* @__PURE__ */ new Set([
218
+ const Lt = /* @__PURE__ */ new Set([
219
219
  "measure",
220
220
  "dimension",
221
221
  "date",
222
222
  "id",
223
223
  "unknown"
224
- ]), Vt = /* @__PURE__ */ new Set(["row", "aggregate"]), Oe = /* @__PURE__ */ new Set([
224
+ ]), Bt = /* @__PURE__ */ new Set(["row", "aggregate"]), Ht = /* @__PURE__ */ new Set([
225
225
  "string",
226
226
  "number",
227
227
  "boolean",
@@ -229,12 +229,12 @@ const Ht = /* @__PURE__ */ new Set([
229
229
  "datetime",
230
230
  "unknown"
231
231
  ]);
232
- function Pe(e, t, i) {
232
+ function Vt(e, t, i) {
233
233
  if (e === void 0)
234
234
  return;
235
235
  if (!f(e)) {
236
236
  i.push(
237
- r(
237
+ o(
238
238
  "invalid_value_format",
239
239
  "Value format must be a structured object.",
240
240
  t
@@ -242,12 +242,12 @@ function Pe(e, t, i) {
242
242
  );
243
243
  return;
244
244
  }
245
- const s = (e.type === "temporal_bucket" ? O : It).safeParse(e);
245
+ const s = (e.type === "temporal_bucket" ? O : yt).safeParse(e);
246
246
  if (s.success) return;
247
247
  const l = e.type === "temporal_bucket" ? "invalid_temporal_bucket_format" : "invalid_value_format";
248
248
  for (const n of s.error.issues)
249
249
  i.push(
250
- r(
250
+ o(
251
251
  l,
252
252
  n.message,
253
253
  [t, ...n.path.map(String)].filter(Boolean).join(".")
@@ -270,7 +270,7 @@ const Ut = /* @__PURE__ */ new Set([
270
270
  function Gt(e, t, i) {
271
271
  if (!e || !f(e)) {
272
272
  i.push(
273
- r(
273
+ o(
274
274
  "invalid_derived_field_input",
275
275
  "Derived field inputs must be structured input references.",
276
276
  t
@@ -279,88 +279,88 @@ function Gt(e, t, i) {
279
279
  return;
280
280
  }
281
281
  if (e.kind === "field") {
282
- _(e.field, `${t}.field`, i, { required: !0 }), re(e.aggregate, `${t}.aggregate`, i);
282
+ y(e.field, `${t}.field`, i, { required: !0 }), se(e.aggregate, `${t}.aggregate`, i);
283
283
  return;
284
284
  }
285
285
  i.push(
286
- r(
286
+ o(
287
287
  "invalid_derived_field_input",
288
288
  "Derived field input kind must be field.",
289
289
  `${t}.kind`
290
290
  )
291
291
  );
292
292
  }
293
- function oe(e) {
293
+ function re(e) {
294
294
  const t = [];
295
295
  if (!f(e))
296
296
  return t.push(
297
- r(
297
+ o(
298
298
  "invalid_derived_field",
299
299
  "Derived field definition must be a structured object."
300
300
  )
301
301
  ), { ok: !1, errors: t, warnings: [] };
302
302
  if (e.kind !== "derived_field" && t.push(
303
- r(
303
+ o(
304
304
  "invalid_derived_field_kind",
305
305
  "Derived field kind must be derived_field.",
306
306
  "kind"
307
307
  )
308
- ), c(e.name) || t.push(
309
- r(
308
+ ), m(e.name) || t.push(
309
+ o(
310
310
  "invalid_derived_field_name",
311
311
  "Derived field needs a name.",
312
312
  "name"
313
313
  )
314
- ), c(e.label) || t.push(
315
- r(
314
+ ), m(e.label) || t.push(
315
+ o(
316
316
  "invalid_derived_field_label",
317
317
  "Derived field needs a label.",
318
318
  "label"
319
319
  )
320
- ), Ht.has(e.resultRole) || t.push(
321
- r(
320
+ ), Lt.has(e.resultRole) || t.push(
321
+ o(
322
322
  "invalid_derived_field_role",
323
323
  "Derived field resultRole must be measure, dimension, date, id, or unknown.",
324
324
  "resultRole"
325
325
  )
326
- ), Oe.has(e.dataType) || t.push(
327
- r(
326
+ ), Ht.has(e.dataType) || t.push(
327
+ o(
328
328
  "invalid_derived_field_data_type",
329
329
  "Derived field dataType must be string, number, boolean, date, datetime, or unknown.",
330
330
  "dataType"
331
331
  )
332
- ), Vt.has(e.computeStage) || t.push(
333
- r(
332
+ ), Bt.has(e.computeStage) || t.push(
333
+ o(
334
334
  "invalid_derived_field_compute_stage",
335
335
  "Derived field computeStage must be row or aggregate.",
336
336
  "computeStage"
337
337
  )
338
338
  ), e.computeStage === "aggregate" && e.resultRole !== "measure" && t.push(
339
- r(
339
+ o(
340
340
  "invalid_derived_field_compute_stage",
341
341
  "Aggregate-stage derived fields must have resultRole measure.",
342
342
  "computeStage"
343
343
  )
344
344
  ), e.resultRole !== "measure" && e.defaultAggregate !== void 0 && t.push(
345
- r(
345
+ o(
346
346
  "invalid_derived_field_aggregate",
347
347
  "Only measure derived fields may declare defaultAggregate.",
348
348
  "defaultAggregate"
349
349
  )
350
350
  ), e.computeStage === "row" && e.resultRole === "measure" && e.defaultAggregate === void 0 && t.push(
351
- r(
351
+ o(
352
352
  "missing_derived_field_default_aggregate",
353
353
  "Row-stage measure derived fields must declare defaultAggregate so row results have explicit rollup semantics.",
354
354
  "defaultAggregate"
355
355
  )
356
- ), re(
356
+ ), se(
357
357
  e.defaultAggregate,
358
358
  "defaultAggregate",
359
359
  t
360
360
  ), e.aggregationBehavior !== void 0 && !Ut.has(
361
361
  e.aggregationBehavior
362
362
  ) && t.push(
363
- r(
363
+ o(
364
364
  "invalid_derived_field_aggregation_behavior",
365
365
  "Derived field aggregationBehavior is not supported.",
366
366
  "aggregationBehavior"
@@ -368,33 +368,33 @@ function oe(e) {
368
368
  ), e.aggregationStrategy !== void 0 && !zt.has(
369
369
  e.aggregationStrategy
370
370
  ) && t.push(
371
- r(
371
+ o(
372
372
  "invalid_derived_field_aggregation_strategy",
373
373
  "Derived field aggregationStrategy is not supported.",
374
374
  "aggregationStrategy"
375
375
  )
376
- ), c(e.expression) || t.push(
377
- r(
376
+ ), m(e.expression) || t.push(
377
+ o(
378
378
  "invalid_derived_field_expression",
379
379
  "Derived field needs a named-token expression.",
380
380
  "expression"
381
381
  )
382
382
  ), e.expressionLanguage !== void 0 && e.expressionLanguage !== "semaphor_sql_template" && t.push(
383
- r(
383
+ o(
384
384
  "invalid_derived_field_expression_language",
385
385
  "Derived field expressionLanguage must be semaphor_sql_template.",
386
386
  "expressionLanguage"
387
387
  )
388
388
  ), !f(e.inputs) || Object.keys(e.inputs).length === 0 ? t.push(
389
- r(
389
+ o(
390
390
  "invalid_derived_field_inputs",
391
391
  "Derived field needs at least one typed input.",
392
392
  "inputs"
393
393
  )
394
394
  ) : Object.entries(e.inputs).forEach(([s, l]) => {
395
- if (!c(s)) {
395
+ if (!m(s)) {
396
396
  t.push(
397
- r(
397
+ o(
398
398
  "invalid_derived_field_input_name",
399
399
  "Derived field input names must be non-empty strings.",
400
400
  "inputs"
@@ -407,72 +407,72 @@ function oe(e) {
407
407
  `inputs.${s}`,
408
408
  t
409
409
  );
410
- }), c(e.expression) && f(e.inputs)) {
411
- const s = Pt(
410
+ }), m(e.expression) && f(e.inputs)) {
411
+ const s = Yt(
412
412
  e.expression
413
413
  ), l = new Set(s), n = Object.keys(e.inputs).filter(
414
- (o) => c(o)
414
+ (r) => m(r)
415
415
  );
416
- s.forEach((o) => {
417
- Object.prototype.hasOwnProperty.call(e.inputs, o) || t.push(
418
- r(
416
+ s.forEach((r) => {
417
+ Object.prototype.hasOwnProperty.call(e.inputs, r) || t.push(
418
+ o(
419
419
  "invalid_derived_field_expression_token",
420
- `Derived field expression token "{${o}}" needs a matching inputs.${o} entry.`,
420
+ `Derived field expression token "{${r}}" needs a matching inputs.${r} entry.`,
421
421
  "expression"
422
422
  )
423
423
  );
424
- }), n.forEach((o) => {
425
- l.has(o) || t.push(
426
- r(
424
+ }), n.forEach((r) => {
425
+ l.has(r) || t.push(
426
+ o(
427
427
  "unused_derived_field_input",
428
- `Derived field input "${o}" is not referenced by expression.`,
429
- `inputs.${o}`
428
+ `Derived field input "${r}" is not referenced by expression.`,
429
+ `inputs.${r}`
430
430
  )
431
431
  );
432
432
  });
433
433
  }
434
434
  const i = e.format;
435
435
  return f(i) && i.type === "temporal_bucket" ? t.push(
436
- r(
436
+ o(
437
437
  "invalid_derived_field_format",
438
438
  "Derived field computation metadata cannot own temporal bucket presentation; declare grain and format on the grouped field.",
439
439
  "format"
440
440
  )
441
- ) : Pe(i, "format", t), e.tags !== void 0 && (!Array.isArray(e.tags) || e.tags.some((s) => !c(s))) && t.push(
442
- r(
441
+ ) : Vt(i, "format", t), e.tags !== void 0 && (!Array.isArray(e.tags) || e.tags.some((s) => !m(s))) && t.push(
442
+ o(
443
443
  "invalid_derived_field_tags",
444
444
  "Derived field tags must be non-empty strings.",
445
445
  "tags"
446
446
  )
447
447
  ), { ok: t.length === 0, errors: t, warnings: [] };
448
448
  }
449
- const D = a.string().min(1).refine((e) => e.trim().length > 0, "Must not be blank."), le = a.union([
450
- St.extend({ domainId: D, datasetName: D }).strict(),
451
- kt.extend({ connectionId: D, tableName: D }).strict()
452
- ]), qe = wt.extend({
449
+ const D = a.string().min(1).refine((e) => e.trim().length > 0, "Must not be blank."), oe = a.union([
450
+ bt.extend({ domainId: D, datasetName: D }).strict(),
451
+ vt.extend({ connectionId: D, tableName: D }).strict()
452
+ ]), Ye = It.extend({
453
453
  name: D,
454
- source: le.optional()
455
- }).strict(), de = At.extend({
456
- format: xt.optional(),
454
+ source: oe.optional()
455
+ }).strict(), le = St.extend({
456
+ format: At.optional(),
457
457
  inputs: a.record(
458
458
  a.object({
459
459
  kind: a.literal("field"),
460
- field: qe,
461
- aggregate: je.optional()
460
+ field: Ye,
461
+ aggregate: $e.optional()
462
462
  }).strict()
463
463
  )
464
464
  }).strict().superRefine((e, t) => {
465
465
  var i;
466
- for (const s of oe(e).errors)
466
+ for (const s of re(e).errors)
467
467
  t.addIssue({
468
468
  code: "custom",
469
469
  path: ((i = s.path) == null ? void 0 : i.split(".")) ?? [],
470
470
  message: s.message
471
471
  });
472
- }), Qt = qe.extend({
473
- derivedField: de.optional()
472
+ }), Qt = Ye.extend({
473
+ derivedField: le.optional()
474
474
  }).strict();
475
- function ue(e) {
475
+ function de(e) {
476
476
  return typeof e == "string" ? e.trim().toLowerCase() : "";
477
477
  }
478
478
  function Kt(e) {
@@ -489,8 +489,8 @@ function Xt(e) {
489
489
  )
490
490
  );
491
491
  }
492
- function ce(e) {
493
- const t = Be(e);
492
+ function ue(e) {
493
+ const t = Pe(e);
494
494
  return t ? ei(t) ? "number" : t.includes("timestamp") || t.includes("datetime") || t.startsWith("time") ? "datetime" : t.includes("date") ? "date" : t.includes("bool") ? "boolean" : "string" : "unknown";
495
495
  }
496
496
  const U = /* @__PURE__ */ new Map([
@@ -531,7 +531,7 @@ function Wt(e) {
531
531
  const t = (i = /^number\s*\(\s*\d+\s*,\s*(\d+)\s*\)$/.exec(e)) == null ? void 0 : i[1];
532
532
  return t === void 0 ? null : Number(t) === 0 ? "integer" : "decimal";
533
533
  }
534
- function Le(e) {
534
+ function Oe(e) {
535
535
  const t = e.split(/[\s(]/, 1)[0] || "";
536
536
  if (t === "number")
537
537
  return { numeric: !0, kind: Wt(e) };
@@ -543,66 +543,66 @@ function Le(e) {
543
543
  return i ? { numeric: !0, kind: U.get(i) ?? null } : { numeric: !1, kind: null };
544
544
  }
545
545
  function ei(e) {
546
- return Le(e).numeric;
546
+ return Oe(e).numeric;
547
547
  }
548
548
  function ti(e) {
549
- return Le(Be(e)).kind;
549
+ return Oe(Pe(e)).kind;
550
550
  }
551
- function Be(e) {
552
- let t = ue(e), i = "";
551
+ function Pe(e) {
552
+ let t = de(e), i = "";
553
553
  for (; t && t !== i; )
554
- i = t, t = Ie(t, "nullable"), t = Ie(t, "lowcardinality");
554
+ i = t, t = ve(t, "nullable"), t = ve(t, "lowcardinality");
555
555
  return t;
556
556
  }
557
- function Ie(e, t) {
557
+ function ve(e, t) {
558
558
  const i = `${t}(`;
559
559
  return !e.startsWith(i) || !e.endsWith(")") ? e : e.slice(i.length, -1).trim();
560
560
  }
561
561
  function ii(e) {
562
- const t = ce(e);
562
+ const t = ue(e);
563
563
  return t === "date" || t === "datetime";
564
564
  }
565
- function He(e) {
565
+ function qe(e) {
566
566
  return ii(e.dataType || e.data_type);
567
567
  }
568
- function Ve(e) {
569
- const t = Ue(e);
568
+ function Le(e) {
569
+ const t = Be(e);
570
570
  return t === "id" || t === "row_id";
571
571
  }
572
- function Se(e) {
573
- const t = Ue(e);
574
- return Ve(e) || t.endsWith("_id") || t.endsWith("_key") || t.endsWith("_number");
572
+ function Ie(e) {
573
+ const t = Be(e);
574
+ return Le(e) || t.endsWith("_id") || t.endsWith("_key") || t.endsWith("_number");
575
575
  }
576
- function Ue(e) {
577
- return ue(
576
+ function Be(e) {
577
+ return de(
578
578
  Kt(e) || e.name || e.alias
579
579
  ).replace(/[^a-z0-9]+/g, "_").replace(/^_+|_+$/g, "");
580
580
  }
581
- function ze(e, t = {}) {
582
- const i = ue(e.role);
583
- return i === "metric" || i === "measure" ? !t.excludeIdentifiers || !Se(e) : i === "groupby" || i === "dimension" || i === "date" || i === "id" ? !1 : ce(
581
+ function He(e, t = {}) {
582
+ const i = de(e.role);
583
+ return i === "metric" || i === "measure" ? !t.excludeIdentifiers || !Ie(e) : i === "groupby" || i === "dimension" || i === "date" || i === "id" ? !1 : ue(
584
584
  e.dataType || e.data_type
585
- ) === "number" && (!t.excludeIdentifiers || !Se(e));
585
+ ) === "number" && (!t.excludeIdentifiers || !Ie(e));
586
586
  }
587
- function Ra(e) {
588
- return !ze(e) && !He(e);
587
+ function Na(e) {
588
+ return !He(e) && !qe(e);
589
589
  }
590
- function Ca(e) {
590
+ function Ta(e) {
591
591
  const t = /* @__PURE__ */ new Set(), i = /* @__PURE__ */ new Set(), s = /* @__PURE__ */ new Set();
592
592
  for (const l of e) {
593
- if (Ve(l))
593
+ if (Le(l))
594
594
  continue;
595
595
  const n = Xt(l);
596
596
  if (n.length !== 0) {
597
- if (He(l)) {
598
- n.forEach((o) => i.add(o));
597
+ if (qe(l)) {
598
+ n.forEach((r) => i.add(r));
599
599
  continue;
600
600
  }
601
- if (ze(l, { excludeIdentifiers: !0 })) {
602
- n.forEach((o) => t.add(o));
601
+ if (He(l, { excludeIdentifiers: !0 })) {
602
+ n.forEach((r) => t.add(r));
603
603
  continue;
604
604
  }
605
- n.forEach((o) => s.add(o));
605
+ n.forEach((r) => s.add(r));
606
606
  }
607
607
  }
608
608
  return {
@@ -621,25 +621,25 @@ function P(e) {
621
621
  exponent: Number(t[5] ?? "0")
622
622
  } : null;
623
623
  }
624
- function ke(e) {
625
- const { sign: t, whole: i, fraction: s = "", exponent: l } = e, n = (i + s).replace(/^0+/, ""), o = n.replace(/0+$/, ""), d = l - s.length + n.length - o.length;
626
- return !Number.isSafeInteger(l) || !Number.isSafeInteger(d) ? null : o ? `${t === "-" ? "-" : ""}${o}e${d}` : "0";
624
+ function Se(e) {
625
+ const { sign: t, whole: i, fraction: s = "", exponent: l } = e, n = (i + s).replace(/^0+/, ""), r = n.replace(/0+$/, ""), d = l - s.length + n.length - r.length;
626
+ return !Number.isSafeInteger(l) || !Number.isSafeInteger(d) ? null : r ? `${t === "-" ? "-" : ""}${r}e${d}` : "0";
627
627
  }
628
- function $a(e) {
628
+ function Ra(e) {
629
629
  const t = P(e);
630
630
  if (!t) return null;
631
631
  const i = t.sign === "+" ? e.slice(1) : e, s = Number(e);
632
632
  if (!Number.isFinite(s)) return i;
633
- const l = ke(t), n = P(String(s));
634
- return l !== null && n !== null && l === ke(n) ? s : i;
633
+ const l = Se(t), n = P(String(s));
634
+ return l !== null && n !== null && l === Se(n) ? s : i;
635
635
  }
636
- function ja(e) {
636
+ function Ca(e) {
637
637
  if (e.length > E)
638
638
  throw new RangeError("Exact numeric text exceeds 16 KiB.");
639
639
  const t = P(e);
640
640
  if (!t) throw new TypeError("Expected finite decimal text.");
641
- const { sign: i, whole: s, fraction: l, exponent: n } = t, o = `${i}${s || "0"}${l ? `.${l}` : ""}`;
642
- return R(`${o}e${n}`);
641
+ const { sign: i, whole: s, fraction: l, exponent: n } = t, r = `${i}${s || "0"}${l ? `.${l}` : ""}`;
642
+ return R(`${r}e${n}`);
643
643
  }
644
644
  function R(e) {
645
645
  if (e.length > E)
@@ -650,31 +650,31 @@ function R(e) {
650
650
  const { sign: i, whole: s, fraction: l = "", exponent: n } = t;
651
651
  if (!Number.isSafeInteger(n) || Math.abs(n) > E)
652
652
  throw new RangeError("Exact numeric exponent exceeds the text budget.");
653
- const o = s + l, d = s.length + n;
654
- if (Math.max(o.length, d) + Math.max(0, -d) + 3 > E)
653
+ const r = s + l, d = s.length + n;
654
+ if (Math.max(r.length, d) + Math.max(0, -d) + 3 > E)
655
655
  throw new RangeError("Normalized exact numeric text exceeds 16 KiB.");
656
- let m;
657
- d <= 0 ? m = `0.${"0".repeat(-d)}${o}` : d >= o.length ? m = o + "0".repeat(d - o.length) : m = `${o.slice(0, d)}.${o.slice(d)}`;
658
- const [u, g = ""] = m.split("."), y = u.replace(/^0+(?=\d)/, ""), I = g.replace(/0+$/, ""), S = y + (I ? `.${I}` : "");
656
+ let p;
657
+ d <= 0 ? p = `0.${"0".repeat(-d)}${r}` : d >= r.length ? p = r + "0".repeat(d - r.length) : p = `${r.slice(0, d)}.${r.slice(d)}`;
658
+ const [u, g = ""] = p.split("."), _ = u.replace(/^0+(?=\d)/, ""), I = g.replace(/0+$/, ""), S = _ + (I ? `.${I}` : "");
659
659
  return i === "-" && S !== "0" ? `-${S}` : S;
660
660
  }
661
- function Ya(e, t) {
661
+ function $a(e, t) {
662
662
  const i = e.startsWith("-"), s = t.startsWith("-");
663
663
  if (i !== s) return i ? -1 : 1;
664
- const [l, n = ""] = (i ? e.slice(1) : e).split("."), [o, d = ""] = (s ? t.slice(1) : t).split(".");
665
- let p = Math.sign(l.length - o.length);
666
- if (!p && l !== o && (p = l < o ? -1 : 1), !p) {
667
- const m = Math.max(n.length, d.length), u = n.padEnd(m, "0"), g = d.padEnd(m, "0");
668
- p = u === g ? 0 : u < g ? -1 : 1;
664
+ const [l, n = ""] = (i ? e.slice(1) : e).split("."), [r, d = ""] = (s ? t.slice(1) : t).split(".");
665
+ let c = Math.sign(l.length - r.length);
666
+ if (!c && l !== r && (c = l < r ? -1 : 1), !c) {
667
+ const p = Math.max(n.length, d.length), u = n.padEnd(p, "0"), g = d.padEnd(p, "0");
668
+ c = u === g ? 0 : u < g ? -1 : 1;
669
669
  }
670
- return p === 0 ? 0 : i ? -p : p;
670
+ return c === 0 ? 0 : i ? -c : c;
671
671
  }
672
- function Oa(e, t) {
672
+ function ja(e, t) {
673
673
  if (typeof t == "number" && !Number.isFinite(t))
674
674
  throw new TypeError("Numeric scale must be finite.");
675
675
  const i = [e, R(String(t))].map((n) => {
676
- const [o, d = ""] = n.split(".");
677
- return { coefficient: BigInt(o + d), digits: d.length };
676
+ const [r, d = ""] = n.split(".");
677
+ return { coefficient: BigInt(r + d), digits: d.length };
678
678
  }), s = i[0].coefficient * i[1].coefficient, l = i[0].digits + i[1].digits;
679
679
  return R(`${s}e-${l}`);
680
680
  }
@@ -685,7 +685,7 @@ function ai(e) {
685
685
  return !1;
686
686
  }
687
687
  }
688
- const Ge = a.object({
688
+ const Ve = a.object({
689
689
  kind: a.literal("exact_number"),
690
690
  type: a.enum(["integer", "decimal"]),
691
691
  value: a.string().max(E).refine(ai, "Expected canonical decimal text.")
@@ -696,15 +696,15 @@ const Ge = a.object({
696
696
  a.string(),
697
697
  a.boolean(),
698
698
  a.number().finite(),
699
- Ge
699
+ Ve
700
700
  ]);
701
701
  function si(e, t) {
702
- return Ge.parse({ kind: "exact_number", type: t, value: R(e) });
702
+ return Ve.parse({ kind: "exact_number", type: t, value: R(e) });
703
703
  }
704
- function Pa(e) {
704
+ function Ya(e) {
705
705
  return typeof e == "object" && e !== null && "kind" in e && e.kind === "exact_number" && "type" in e && (e.type === "integer" || e.type === "decimal") && "value" in e && typeof e.value == "string";
706
706
  }
707
- function qa(e) {
707
+ function Oa(e) {
708
708
  const t = ti(e.nativeDataType);
709
709
  if (!t) throw new TypeError("Numeric result type is not established.");
710
710
  if (e.value === null) return null;
@@ -717,10 +717,10 @@ function qa(e) {
717
717
  throw new TypeError("Exact numeric sidecar is required; rounded result values cannot substitute.");
718
718
  return si(e.exactText, t);
719
719
  }
720
- const pe = a.string().uuid(), me = a.enum(["rows", "columns"]), La = a.enum(["member", "subtotal", "grand_total", "others"]), ri = a.discriminatedUnion("kind", [
720
+ const ce = a.string().uuid(), pe = a.enum(["rows", "columns"]), Pa = a.enum(["member", "subtotal", "grand_total", "others"]), ri = a.discriminatedUnion("kind", [
721
721
  a.object({ kind: a.literal("value"), value: ni }).strict(),
722
- a.object({ kind: a.literal("others"), rankingId: pe }).strict()
723
- ]), A = a.array(a.object({ levelId: pe, member: ri }).strict()).readonly().superRefine((e, t) => {
722
+ a.object({ kind: a.literal("others"), rankingId: ce }).strict()
723
+ ]), k = a.array(a.object({ levelId: ce, member: ri }).strict()).readonly().superRefine((e, t) => {
724
724
  new Set(e.map((i) => i.levelId)).size !== e.length && t.addIssue({
725
725
  code: "custom",
726
726
  path: [],
@@ -732,12 +732,12 @@ const pe = a.string().uuid(), me = a.enum(["rows", "columns"]), La = a.enum(["me
732
732
  path: [],
733
733
  message: "Others is terminal."
734
734
  });
735
- }), Ba = a.object({
736
- rowPath: A,
737
- columnPath: A,
738
- measureId: pe
735
+ }), qa = a.object({
736
+ rowPath: k,
737
+ columnPath: k,
738
+ measureId: ce
739
739
  }).strict();
740
- function Qe(e) {
740
+ function Ue(e) {
741
741
  return JSON.stringify(
742
742
  e.map(({ levelId: t, member: i }) => [
743
743
  t,
@@ -784,17 +784,17 @@ const di = [
784
784
  // Custom format
785
785
  "custom"
786
786
  ];
787
- function Ha(e) {
787
+ function La(e) {
788
788
  return e.role === "metric" && "expression" in e && !!e.expression;
789
789
  }
790
- function Va(e) {
790
+ function Ba(e) {
791
791
  return !!e.expression;
792
792
  }
793
793
  function ui(e) {
794
794
  return !!(e && (e.calculationRepresentation || e.expression || e.derivedField || e.calculatedFieldOrigin || e.calculatedFormula || J(e)));
795
795
  }
796
- function Ke(e) {
797
- var g, y, I;
796
+ function ze(e) {
797
+ var g, _, I;
798
798
  if (!e)
799
799
  return {
800
800
  representation: "physical",
@@ -803,12 +803,12 @@ function Ke(e) {
803
803
  runtimeExecutable: !1,
804
804
  legacyManual: !1
805
805
  };
806
- const t = e.fieldScope === "domain" ? "domain" : "local", i = ((g = e.derivedField) == null ? void 0 : g.computeStage) || ((y = e.calculatedFormula) == null ? void 0 : y.computeStage), s = !e.calculatedFormula || Array.isArray(e.calculatedFormula.inputFields) && e.calculatedFormula.inputFields.every((S) => {
807
- const be = S && li(S);
808
- return typeof be == "string" && !!be.trim();
806
+ const t = e.fieldScope === "domain" ? "domain" : "local", i = ((g = e.derivedField) == null ? void 0 : g.computeStage) || ((_ = e.calculatedFormula) == null ? void 0 : _.computeStage), s = !e.calculatedFormula || Array.isArray(e.calculatedFormula.inputFields) && e.calculatedFormula.inputFields.every((S) => {
807
+ const ye = S && li(S);
808
+ return typeof ye == "string" && !!ye.trim();
809
809
  }), l = typeof e.expression == "string" && !!e.expression.trim() && s, n = e.calculationRepresentation;
810
810
  if (e.derivedField || n === "typed-derived") {
811
- const S = e.derivedField !== void 0 && oe(e.derivedField).ok;
811
+ const S = e.derivedField !== void 0 && re(e.derivedField).ok;
812
812
  return {
813
813
  representation: "typed-derived",
814
814
  ownership: t,
@@ -826,33 +826,33 @@ function Ke(e) {
826
826
  runtimeExecutable: !1,
827
827
  legacyManual: !1
828
828
  };
829
- const d = i || (e.role === "groupby" || ((I = e.calculatedFieldOrigin) == null ? void 0 : I.role) === "groupby" ? "row" : void 0), p = t === "domain" || J(e) || e.fieldScope === "card" || e.fieldScope === "sheet" || e.fieldScope === "dashboard" ? "manual" : "inline-expression", m = n === "manual" || n === "inline-expression" ? n : p, u = (!n || n === "manual" || n === "inline-expression") && !(n === "inline-expression" && J(e));
829
+ const d = i || (e.role === "groupby" || ((I = e.calculatedFieldOrigin) == null ? void 0 : I.role) === "groupby" ? "row" : void 0), c = t === "domain" || J(e) || e.fieldScope === "card" || e.fieldScope === "sheet" || e.fieldScope === "dashboard" ? "manual" : "inline-expression", p = n === "manual" || n === "inline-expression" ? n : c, u = (!n || n === "manual" || n === "inline-expression") && !(n === "inline-expression" && J(e));
830
830
  return {
831
- representation: m,
831
+ representation: p,
832
832
  ownership: t,
833
833
  completeness: l && u ? "complete" : "incomplete",
834
834
  computeStage: d,
835
835
  runtimeExecutable: l,
836
- legacyManual: m === "manual" && t === "local" && !d
836
+ legacyManual: p === "manual" && t === "local" && !d
837
837
  };
838
838
  }
839
- function Ua(e) {
839
+ function Ha(e) {
840
840
  if (e.calculationRepresentation) return e;
841
- const { representation: t } = Ke(e);
841
+ const { representation: t } = ze(e);
842
842
  return t === "physical" ? e : { ...e, calculationRepresentation: t };
843
843
  }
844
- function za(e) {
845
- return Ke(e).computeStage;
844
+ function Va(e) {
845
+ return ze(e).computeStage;
846
846
  }
847
- function Ga(e, t) {
847
+ function Ua(e, t) {
848
848
  return e === "aggregate" && t === "default";
849
849
  }
850
- function Qa(e) {
850
+ function za(e) {
851
851
  var i, s;
852
852
  const t = e;
853
853
  return !!(t != null && t.expression && ((s = (i = t.calculatedFormula) == null ? void 0 : i.inputFields) != null && s.length));
854
854
  }
855
- function Ka(e) {
855
+ function Ga(e) {
856
856
  return !!(e && (e.entityName === Z || e.entityId === Z));
857
857
  }
858
858
  function J(e) {
@@ -861,10 +861,10 @@ function J(e) {
861
861
  ) : !1;
862
862
  }
863
863
  function ci(e) {
864
- const t = Ze(e);
864
+ const t = Qe(e);
865
865
  return t.length > 0 ? t.join(".") : void 0;
866
866
  }
867
- function Xa(e) {
867
+ function Qa(e) {
868
868
  const t = ci(
869
869
  e.qualifiedName
870
870
  ), i = (t == null ? void 0 : t.split(".")) || [];
@@ -879,19 +879,19 @@ function Xa(e) {
879
879
  );
880
880
  return s;
881
881
  }
882
- function Za(e) {
882
+ function Ka(e) {
883
883
  return !e.left.tableName || !e.right.tableName ? !1 : e.capabilities.prefixLevels.every((t) => {
884
884
  const i = x(e.left, t), s = x(e.right, t);
885
885
  return !i || !s || i === s;
886
886
  });
887
887
  }
888
- function Ja(e) {
888
+ function Xa(e) {
889
889
  return e.capabilities.prefixLevels.every((t) => {
890
890
  const i = x(e.requested, t);
891
891
  return i ? x(e.allowed, t) === i : !0;
892
892
  });
893
893
  }
894
- function Xe(e, t = {}) {
894
+ function Ge(e, t = {}) {
895
895
  const i = C(e), s = {
896
896
  connectionId: t.connectionId,
897
897
  connectionType: e,
@@ -968,7 +968,7 @@ function Xe(e, t = {}) {
968
968
  supportsFilterClause: !1
969
969
  } : s;
970
970
  }
971
- const fe = [
971
+ const me = [
972
972
  "GoogleSheets",
973
973
  "FileUpload",
974
974
  "MySQL",
@@ -982,10 +982,10 @@ const fe = [
982
982
  "API",
983
983
  "none"
984
984
  ];
985
- function Wa(e) {
985
+ function Za(e) {
986
986
  if (!e) return;
987
- const t = fe.filter(
988
- (i) => i !== "none" && Xe(i).dialect === e
987
+ const t = me.filter(
988
+ (i) => i !== "none" && Ge(i).dialect === e
989
989
  );
990
990
  return t.length === 1 ? t[0] : void 0;
991
991
  }
@@ -993,17 +993,17 @@ const pi = {
993
993
  postgres: "PostgreSQL",
994
994
  sqlserver: "MSSQL"
995
995
  };
996
- function en(e) {
996
+ function Ja(e) {
997
997
  const t = C(e);
998
998
  if (t)
999
- return fe.find(
999
+ return me.find(
1000
1000
  (i) => C(i) === t
1001
1001
  ) ?? pi[t];
1002
1002
  }
1003
- function tn(e, t = {}) {
1003
+ function Wa(e, t = {}) {
1004
1004
  return mi(
1005
1005
  e
1006
- ) ? Xe(e, t) : void 0;
1006
+ ) ? Ge(e, t) : void 0;
1007
1007
  }
1008
1008
  function mi(e) {
1009
1009
  const t = C(e);
@@ -1017,7 +1017,7 @@ function mi(e) {
1017
1017
  if (t === "s3" || t === "api" || t === "googlesheets" || t === "fileupload" || t === "bigquery")
1018
1018
  return t;
1019
1019
  }
1020
- function an(e) {
1020
+ function en(e) {
1021
1021
  const t = C(e);
1022
1022
  switch (t) {
1023
1023
  case "mysql":
@@ -1038,12 +1038,12 @@ function an(e) {
1038
1038
  return "unknown";
1039
1039
  }
1040
1040
  }
1041
- function nn(e) {
1041
+ function tn(e) {
1042
1042
  return e.capabilities.prefixLevels.every(
1043
1043
  (t) => !!x(e.source, t)
1044
1044
  );
1045
1045
  }
1046
- function sn(e) {
1046
+ function an(e) {
1047
1047
  const t = e.quoteIdentifier ?? _i;
1048
1048
  return e.capabilities.prefixLevels.map((i) => x(e.source, i)).filter((i) => !!i).map((i) => t(i, e.capabilities.dialect)).join(".");
1049
1049
  }
@@ -1065,14 +1065,14 @@ function hi(e) {
1065
1065
  return t.slice(1, -1).split(s + s).join(s);
1066
1066
  return t;
1067
1067
  }
1068
- function Ze(e) {
1068
+ function Qe(e) {
1069
1069
  const t = e == null ? void 0 : e.trim();
1070
1070
  if (!t) return [];
1071
1071
  const i = t.split(".").map(hi);
1072
1072
  return i.some((s) => !s) ? [] : i;
1073
1073
  }
1074
- function rn(e) {
1075
- const t = Ze(e ?? void 0);
1074
+ function nn(e) {
1075
+ const t = Qe(e ?? void 0);
1076
1076
  return t[t.length - 1] || "";
1077
1077
  }
1078
1078
  function _i(e, t) {
@@ -1090,58 +1090,58 @@ function yi(e) {
1090
1090
  const t = e.charCodeAt(0);
1091
1091
  return t >= 48 && t <= 57 || t >= 97 && t <= 122;
1092
1092
  }
1093
- function on(e) {
1093
+ function sn(e) {
1094
1094
  return typeof e == "object" && e !== null && e.mode === "last" && e.relativeTo === "latest_data";
1095
1095
  }
1096
1096
  function bi(e) {
1097
1097
  return e === "between" || e === "not between";
1098
1098
  }
1099
- const B = a.enum(["day", "week", "month", "quarter", "year"]), vi = a.enum(["minute", "hour"]), Je = a.number().int().positive(), we = a.number().int(), We = a.object({
1099
+ const B = a.enum(["day", "week", "month", "quarter", "year"]), vi = a.enum(["minute", "hour"]), Ke = a.number().int().positive(), Ae = a.number().int(), Xe = a.object({
1100
1100
  mode: a.literal("last"),
1101
- n: Je,
1101
+ n: Ke,
1102
1102
  unit: vi,
1103
1103
  complete: a.literal(!1).optional(),
1104
1104
  relativeTo: a.literal("latest_data").optional()
1105
- }), et = a.object({
1105
+ }), Ze = a.object({
1106
1106
  mode: a.literal("last"),
1107
- n: Je,
1107
+ n: Ke,
1108
1108
  unit: B,
1109
1109
  complete: a.boolean().optional(),
1110
1110
  relativeTo: a.literal("latest_data").optional()
1111
- }), tt = a.object({
1111
+ }), Je = a.object({
1112
1112
  mode: a.literal("this"),
1113
1113
  unit: B,
1114
1114
  toDate: a.boolean().optional(),
1115
1115
  boundary: a.enum(["first_day", "last_day"]).optional()
1116
- }), it = a.object({ mode: a.literal("previous"), unit: B }), at = a.object({
1116
+ }), We = a.object({ mode: a.literal("previous"), unit: B }), et = a.object({
1117
1117
  mode: a.literal("between"),
1118
1118
  unit: B,
1119
- from: we,
1120
- to: we
1119
+ from: Ae,
1120
+ to: Ae
1121
1121
  }), W = {
1122
1122
  check: (e) => e.boundary === void 0 || e.unit === "month",
1123
1123
  message: 'A month boundary requires unit "month".'
1124
1124
  }, Ii = a.union([
1125
- We.strict(),
1126
- et.strict(),
1127
- tt.strict().refine(W.check, {
1125
+ Xe.strict(),
1126
+ Ze.strict(),
1127
+ Je.strict().refine(W.check, {
1128
1128
  message: W.message,
1129
1129
  path: ["boundary"]
1130
1130
  }),
1131
- it.strict(),
1132
- at.strict()
1131
+ We.strict(),
1132
+ et.strict()
1133
1133
  ]), Si = a.union([
1134
+ Xe,
1135
+ Ze,
1136
+ Je.refine(W.check),
1134
1137
  We,
1135
- et,
1136
- tt.refine(W.check),
1137
- it,
1138
- at
1138
+ et
1139
1139
  ]);
1140
- function ln(e) {
1140
+ function rn(e) {
1141
1141
  const t = Si.safeParse(e);
1142
1142
  return t.success ? t.data : void 0;
1143
1143
  }
1144
- const v = a.string().min(1), Ae = a.enum(["groupby", "metric", "sortby", "pivotby", "detail"]), nt = a.enum([
1144
+ const v = a.string().min(1), we = a.enum(["groupby", "metric", "sortby", "pivotby", "detail"]), tt = a.enum([
1145
1145
  "table",
1146
1146
  "view",
1147
1147
  "materialized view",
@@ -1152,8 +1152,8 @@ const v = a.string().min(1), Ae = a.enum(["groupby", "metric", "sortby", "pivotb
1152
1152
  "upload"
1153
1153
  ]), z = a.object({
1154
1154
  connectionId: v,
1155
- connectionType: a.enum(fe),
1156
- type: nt,
1155
+ connectionType: a.enum(me),
1156
+ type: tt,
1157
1157
  name: v,
1158
1158
  // Grounded relationship plans retain semantic identity and display metadata.
1159
1159
  // SQL stays server-resolved; it is not accepted inside a join entity.
@@ -1187,30 +1187,30 @@ const v = a.string().min(1), Ae = a.enum(["groupby", "metric", "sortby", "pivotb
1187
1187
  dataType: v,
1188
1188
  entityId: v,
1189
1189
  entityName: v,
1190
- entityType: nt,
1190
+ entityType: tt,
1191
1191
  alias: a.string().optional(),
1192
1192
  sourceField: a.string().optional(),
1193
- source: le.optional(),
1193
+ source: oe.optional(),
1194
1194
  nativeDataType: a.string().optional(),
1195
1195
  description: a.string().optional(),
1196
1196
  qualifiedEntityName: a.string().optional(),
1197
1197
  dateFormat: a.enum(di).optional(),
1198
1198
  customFormat: a.string().optional(),
1199
1199
  granularity: X.optional(),
1200
- role: Ae.optional(),
1200
+ role: we.optional(),
1201
1201
  calculationRepresentation: a.enum(["inline-expression", "manual", "typed-derived"]).optional(),
1202
- calculatedFieldOrigin: a.object({ id: v, role: Ae.optional() }).strict().optional(),
1202
+ calculatedFieldOrigin: a.object({ id: v, role: we.optional() }).strict().optional(),
1203
1203
  aggregateOrigin: a.enum(["default", "explicit"]).optional(),
1204
1204
  labelOrigin: a.enum(["semantic", "override"]).optional(),
1205
1205
  formatOrigin: a.enum(["semantic", "override"]).optional(),
1206
1206
  expression: a.string().optional(),
1207
- derivedField: de.optional(),
1207
+ derivedField: le.optional(),
1208
1208
  format: O.optional(),
1209
1209
  semanticTemporalPresentation: a.object({
1210
1210
  granularity: X,
1211
- format: Ft
1211
+ format: wt
1212
1212
  }).strict().optional(),
1213
- aggregate: je.optional(),
1213
+ aggregate: $e.optional(),
1214
1214
  fieldScope: a.enum(["card", "sheet", "dashboard", "domain"]).optional(),
1215
1215
  calculatedFormula: a.object({
1216
1216
  operation: a.enum([
@@ -1228,7 +1228,7 @@ const v = a.string().min(1), Ae = a.enum(["groupby", "metric", "sortby", "pivotb
1228
1228
  computeStage: a.enum(["row", "aggregate"]).optional()
1229
1229
  }).strict().optional()
1230
1230
  }).strict()
1231
- ), ki = a.union([
1231
+ ), Ai = a.union([
1232
1232
  a.string(),
1233
1233
  a.number().finite(),
1234
1234
  a.boolean(),
@@ -1256,9 +1256,10 @@ const v = a.string().min(1), Ae = a.enum(["groupby", "metric", "sortby", "pivotb
1256
1256
  "isNull",
1257
1257
  "isNotNull"
1258
1258
  ]),
1259
- value: a.union([ki, a.array(a.string()), a.array(a.number().finite())]),
1259
+ value: a.union([Ai, a.array(a.string()), a.array(a.number().finite())]),
1260
1260
  label: a.string().optional(),
1261
- temporalBucket: Dt.optional(),
1261
+ temporalBucket: xt.optional(),
1262
+ rawTemporal: kt.optional(),
1262
1263
  relativeMeta: Ii.optional(),
1263
1264
  latestValue: a.literal(!0).optional(),
1264
1265
  latestValuePolicy: a.literal("snapshot").optional()
@@ -1273,7 +1274,7 @@ const v = a.string().min(1), Ae = a.enum(["groupby", "metric", "sortby", "pivotb
1273
1274
  path: ["relativeMeta"],
1274
1275
  message: "A relative date requires between or not between."
1275
1276
  }), e.latestValue) {
1276
- const n = [e.field.nativeDataType, e.field.dataType].map((o) => ce(o)).some((o) => o === "date" || o === "datetime");
1277
+ const n = [e.field.nativeDataType, e.field.dataType].map((r) => ue(r)).some((r) => r === "date" || r === "datetime");
1277
1278
  (i !== "=" || !n) && t.addIssue({
1278
1279
  code: "custom",
1279
1280
  path: ["latestValue"],
@@ -1285,15 +1286,15 @@ const v = a.string().min(1), Ae = a.enum(["groupby", "metric", "sortby", "pivotb
1285
1286
  path: ["value"],
1286
1287
  message: "Membership requires an array."
1287
1288
  });
1288
- }), st = a.lazy(
1289
+ }), it = a.lazy(
1289
1290
  () => a.object({
1290
1291
  id: v,
1291
1292
  logicalOperator: a.enum(["AND", "OR"]),
1292
1293
  negate: a.boolean(),
1293
1294
  conditions: a.array(wi),
1294
- groups: a.array(st)
1295
+ groups: a.array(it)
1295
1296
  }).strict()
1296
- ), Ai = a.object({
1297
+ ), ki = a.object({
1297
1298
  baseEntity: z,
1298
1299
  joins: a.array(
1299
1300
  a.object({
@@ -1331,50 +1332,50 @@ const v = a.string().min(1), Ae = a.enum(["groupby", "metric", "sortby", "pivotb
1331
1332
  "MIN",
1332
1333
  "MAX",
1333
1334
  "MEDIAN"
1334
- ]), rt = Qt.omit({
1335
+ ]), at = Qt.omit({
1335
1336
  aggregate: !0
1336
1337
  }), Mi = {
1337
1338
  id: b,
1338
- field: rt,
1339
+ field: at,
1339
1340
  grain: X.optional()
1340
1341
  }, ee = a.object(Mi).strict(), Ei = a.object({
1341
1342
  id: b,
1342
1343
  kind: a.literal("aggregate"),
1343
- field: rt,
1344
+ field: at,
1344
1345
  aggregate: Di
1345
- }).strict(), Ti = a.object({
1346
+ }).strict(), Ni = a.object({
1346
1347
  id: b,
1347
1348
  kind: a.literal("calculated"),
1348
- definition: de
1349
- }).strict(), ot = a.discriminatedUnion("kind", [Ei, Ti]), Ni = a.discriminatedUnion("kind", [
1349
+ definition: le
1350
+ }).strict(), nt = a.discriminatedUnion("kind", [Ei, Ni]), Ti = a.discriminatedUnion("kind", [
1350
1351
  a.object({ kind: a.literal("member") }).strict(),
1351
1352
  a.object({
1352
1353
  kind: a.literal("measure"),
1353
1354
  measureId: b,
1354
- oppositePath: A
1355
+ oppositePath: k
1355
1356
  }).strict()
1356
1357
  ]), Ri = {
1357
- axis: me,
1358
+ axis: pe,
1358
1359
  levelId: b,
1359
1360
  scope: a.discriminatedUnion("kind", [
1360
1361
  a.object({ kind: a.literal("level") }).strict(),
1361
- a.object({ kind: a.literal("branch"), parent: A }).strict()
1362
+ a.object({ kind: a.literal("branch"), parent: k }).strict()
1362
1363
  ]),
1363
- target: Ni,
1364
+ target: Ti,
1364
1365
  direction: a.enum(["asc", "desc"]),
1365
1366
  nulls: a.enum(["first", "last"])
1366
- }, lt = a.object(Ri).strict(), Ci = a.object({
1367
+ }, st = a.object(Ri).strict(), Ci = a.object({
1367
1368
  id: b,
1368
- axis: me,
1369
+ axis: pe,
1369
1370
  levelId: b,
1370
1371
  direction: a.enum(["top", "bottom"]),
1371
1372
  count: Fi,
1372
1373
  measureId: b,
1373
- oppositePath: A,
1374
+ oppositePath: k,
1374
1375
  others: a.boolean()
1375
1376
  }).strict(), G = a.number().finite(), $i = a.object({
1376
1377
  id: b,
1377
- axis: me,
1378
+ axis: pe,
1378
1379
  levelId: b,
1379
1380
  measureId: b,
1380
1381
  operator: a.enum(["=", "!=", ">", ">=", "<", "<=", "between", "not between"]),
@@ -1385,24 +1386,24 @@ const v = a.string().min(1), Ae = a.enum(["groupby", "metric", "sortby", "pivotb
1385
1386
  }).strict().superRefine((e, t) => {
1386
1387
  const i = e.operator === "between" || e.operator === "not between";
1387
1388
  i !== Array.isArray(e.value) ? h(t, ["value"], i ? "A range condition needs a low and a high bound." : "A comparison needs one number.") : i && e.value[0] > e.value[1] && h(t, ["value"], "The low bound must not exceed the high bound.");
1388
- }), dt = a.object({
1389
- source: le,
1389
+ }), rt = a.object({
1390
+ source: oe,
1390
1391
  rows: a.array(ee).min(1).readonly(),
1391
1392
  columns: a.array(ee).readonly(),
1392
- measures: a.array(ot).min(1).readonly(),
1393
- filters: st.optional(),
1394
- joinPlan: Ai.optional(),
1393
+ measures: a.array(nt).min(1).readonly(),
1394
+ filters: it.optional(),
1395
+ joinPlan: ki.optional(),
1395
1396
  relationshipHint: a.object({ relationshipIds: a.array(xi).optional() }).strict().optional(),
1396
- sorts: a.array(lt).readonly(),
1397
+ sorts: a.array(st).readonly(),
1397
1398
  rankings: a.array(Ci).readonly(),
1398
1399
  measureFilters: a.array($i).readonly().optional()
1399
1400
  }).strict();
1400
- function ut(e) {
1401
+ function ot(e) {
1401
1402
  return JSON.stringify([
1402
1403
  e.axis,
1403
1404
  e.levelId,
1404
1405
  e.scope.kind,
1405
- e.scope.kind === "branch" ? Qe(e.scope.parent) : null
1406
+ e.scope.kind === "branch" ? Ue(e.scope.parent) : null
1406
1407
  ]);
1407
1408
  }
1408
1409
  function h(e, t, i) {
@@ -1412,12 +1413,12 @@ function w(e, t, i) {
1412
1413
  new Set(e).size !== e.length && h(t, i, "Duplicate identity.");
1413
1414
  }
1414
1415
  function L(e, t, i, s, l, n = !1) {
1415
- i.length > e[t].length && h(s, l, "Path exceeds axis depth."), i.forEach((o, d) => {
1416
- var p;
1417
- if (o.levelId !== ((p = e[t][d]) == null ? void 0 : p.id) && h(s, [...l, d], "Path must be an ordered axis prefix."), o.member.kind === "others") {
1418
- const m = o.member.rankingId;
1416
+ i.length > e[t].length && h(s, l, "Path exceeds axis depth."), i.forEach((r, d) => {
1417
+ var c;
1418
+ if (r.levelId !== ((c = e[t][d]) == null ? void 0 : c.id) && h(s, [...l, d], "Path must be an ordered axis prefix."), r.member.kind === "others") {
1419
+ const p = r.member.rankingId;
1419
1420
  (n || d !== i.length - 1 || !e.rankings.some(
1420
- (u) => u.id === m && u.others && u.axis === t && u.levelId === o.levelId
1421
+ (u) => u.id === p && u.others && u.axis === t && u.levelId === r.levelId
1421
1422
  )) && h(
1422
1423
  s,
1423
1424
  [...l, d],
@@ -1426,28 +1427,28 @@ function L(e, t, i, s, l, n = !1) {
1426
1427
  }
1427
1428
  });
1428
1429
  }
1429
- function ct(e, t, i, s) {
1430
- w(t.map(ut), i, s), t.forEach((l, n) => {
1431
- const o = [...s, n], d = e[l.axis].findIndex((p) => p.id === l.levelId);
1432
- if (d < 0 && h(i, o, "Sort level is not on its axis."), l.scope.kind === "branch" && (L(
1430
+ function lt(e, t, i, s) {
1431
+ w(t.map(ot), i, s), t.forEach((l, n) => {
1432
+ const r = [...s, n], d = e[l.axis].findIndex((c) => c.id === l.levelId);
1433
+ if (d < 0 && h(i, r, "Sort level is not on its axis."), l.scope.kind === "branch" && (L(
1433
1434
  e,
1434
1435
  l.axis,
1435
1436
  l.scope.parent,
1436
1437
  i,
1437
- [...o, "scope", "parent"],
1438
+ [...r, "scope", "parent"],
1438
1439
  !0
1439
1440
  ), l.scope.parent.length !== d && h(
1440
1441
  i,
1441
- o,
1442
+ r,
1442
1443
  "Branch sort must name the immediate parent of its level."
1443
1444
  )), l.target.kind === "measure") {
1444
- const p = l.target.measureId;
1445
- e.measures.some((m) => m.id === p) || h(i, o, "Unknown sort measure."), L(
1445
+ const c = l.target.measureId;
1446
+ e.measures.some((p) => p.id === c) || h(i, r, "Unknown sort measure."), L(
1446
1447
  e,
1447
1448
  l.axis === "rows" ? "columns" : "rows",
1448
1449
  l.target.oppositePath,
1449
1450
  i,
1450
- [...o, "target", "oppositePath"],
1451
+ [...r, "target", "oppositePath"],
1451
1452
  !0
1452
1453
  );
1453
1454
  }
@@ -1463,7 +1464,7 @@ function Y(e, t, i, s) {
1463
1464
  function Q(e, t, i) {
1464
1465
  (e.aggregationBehavior === "snapshot" || e.aggregationBehavior === "weighted" || e.aggregationStrategy === "weighted") && h(t, i, "This measure semantic requires a later capability.");
1465
1466
  }
1466
- function pt(e, t) {
1467
+ function dt(e, t) {
1467
1468
  w(
1468
1469
  [...e.rows, ...e.columns, ...e.measures].map((n) => n.id),
1469
1470
  t,
@@ -1478,8 +1479,8 @@ function pt(e, t) {
1478
1479
  ["rankings"]
1479
1480
  );
1480
1481
  for (const n of ["rows", "columns"])
1481
- e[n].forEach((o, d) => {
1482
- o.grain && o.field.dataType !== void 0 && !["date", "datetime", "unknown"].includes(o.field.dataType) && h(t, [n, d, "grain"], "Grain requires a temporal field.");
1482
+ e[n].forEach((r, d) => {
1483
+ r.grain && r.field.dataType !== void 0 && !["date", "datetime", "unknown"].includes(r.field.dataType) && h(t, [n, d, "grain"], "Grain requires a temporal field.");
1483
1484
  });
1484
1485
  const i = [
1485
1486
  ...e.rows,
@@ -1497,8 +1498,8 @@ function pt(e, t) {
1497
1498
  [n.id],
1498
1499
  "Aggregate-stage calculations cannot be grouped or wrapped in an aggregate."
1499
1500
  ), Q(n.field.derivedField, t, [n.id]);
1500
- for (const o of Object.values(n.field.derivedField.inputs))
1501
- Y(o.field.source, e.source, t, [n.id, "inputs"]);
1501
+ for (const r of Object.values(n.field.derivedField.inputs))
1502
+ Y(r.field.source, e.source, t, [n.id, "inputs"]);
1502
1503
  }
1503
1504
  for (const n of e.measures)
1504
1505
  if (n.kind === "calculated") {
@@ -1507,71 +1508,71 @@ function pt(e, t) {
1507
1508
  [n.id],
1508
1509
  "Calculated measures require aggregate stage and measure role."
1509
1510
  ), Q(n.definition, t, [n.id]);
1510
- for (const o of Object.values(n.definition.inputs))
1511
- Y(o.field.source, e.source, t, [
1511
+ for (const r of Object.values(n.definition.inputs))
1512
+ Y(r.field.source, e.source, t, [
1512
1513
  n.id,
1513
1514
  "inputs"
1514
1515
  ]);
1515
1516
  }
1516
1517
  const s = (n) => {
1517
- const o = (d, p) => {
1518
- var m, u;
1519
- if ((d.aggregate || ((m = d.derivedField) == null ? void 0 : m.computeStage) === "aggregate") && h(t, p, "Aggregate/HAVING filters are not supported."), d.derivedField) {
1520
- Q(d.derivedField, t, p);
1518
+ const r = (d, c) => {
1519
+ var p, u;
1520
+ if ((d.aggregate || ((p = d.derivedField) == null ? void 0 : p.computeStage) === "aggregate") && h(t, c, "Aggregate/HAVING filters are not supported."), d.derivedField) {
1521
+ Q(d.derivedField, t, c);
1521
1522
  for (const g of Object.values(d.derivedField.inputs))
1522
- Y(g.field.source, e.source, t, p);
1523
+ Y(g.field.source, e.source, t, c);
1523
1524
  }
1524
1525
  for (const g of ((u = d.calculatedFormula) == null ? void 0 : u.inputFields) ?? [])
1525
- o(g, p);
1526
+ r(g, c);
1526
1527
  };
1527
1528
  for (const d of n.conditions)
1528
- o(d.field, ["filters", d.id]);
1529
+ r(d.field, ["filters", d.id]);
1529
1530
  n.groups.forEach(s);
1530
1531
  };
1531
1532
  if (e.filters && s(e.filters), e.joinPlan) {
1532
1533
  const n = [
1533
1534
  e.joinPlan.baseEntity,
1534
- ...e.joinPlan.joins.flatMap((o) => [o.source, o.target])
1535
+ ...e.joinPlan.joins.flatMap((r) => [r.source, r.target])
1535
1536
  ];
1536
- (new Set(n.map((o) => o.connectionId)).size > 1 || e.source.kind === "physical" && n[0].connectionId !== e.source.connectionId) && h(t, ["joinPlan"], "Joins must stay within the source connection."), w(
1537
- e.joinPlan.joins.map((o) => o.id),
1537
+ (new Set(n.map((r) => r.connectionId)).size > 1 || e.source.kind === "physical" && n[0].connectionId !== e.source.connectionId) && h(t, ["joinPlan"], "Joins must stay within the source connection."), w(
1538
+ e.joinPlan.joins.map((r) => r.id),
1538
1539
  t,
1539
1540
  ["joinPlan", "joins"]
1540
1541
  );
1541
1542
  }
1542
- ct(e, e.sorts, t, ["sorts"]);
1543
+ lt(e, e.sorts, t, ["sorts"]);
1543
1544
  const l = e.measureFilters ?? [];
1544
1545
  w(l.map((n) => n.id), t, ["measureFilters"]), w(
1545
1546
  l.map((n) => JSON.stringify([n.axis, n.levelId])),
1546
1547
  t,
1547
1548
  ["measureFilters"]
1548
- ), l.forEach((n, o) => {
1549
- (!e[n.axis].some((d) => d.id === n.levelId) || !e.measures.some((d) => d.id === n.measureId)) && h(t, ["measureFilters", o], "Unknown measure filter level or measure.");
1550
- }), e.rankings.forEach((n, o) => {
1551
- (!e[n.axis].some((d) => d.id === n.levelId) || !e.measures.some((d) => d.id === n.measureId)) && h(t, ["rankings", o], "Unknown ranking level or measure."), L(
1549
+ ), l.forEach((n, r) => {
1550
+ (!e[n.axis].some((d) => d.id === n.levelId) || !e.measures.some((d) => d.id === n.measureId)) && h(t, ["measureFilters", r], "Unknown measure filter level or measure.");
1551
+ }), e.rankings.forEach((n, r) => {
1552
+ (!e[n.axis].some((d) => d.id === n.levelId) || !e.measures.some((d) => d.id === n.measureId)) && h(t, ["rankings", r], "Unknown ranking level or measure."), L(
1552
1553
  e,
1553
1554
  n.axis === "rows" ? "columns" : "rows",
1554
1555
  n.oppositePath,
1555
1556
  t,
1556
- ["rankings", o, "oppositePath"],
1557
+ ["rankings", r, "oppositePath"],
1557
1558
  !0
1558
1559
  );
1559
1560
  });
1560
1561
  }
1561
- const j = dt.superRefine(pt), ji = dt.extend({
1562
+ const j = rt.superRefine(dt), ji = rt.extend({
1562
1563
  rows: a.array(ee).readonly(),
1563
- measures: a.array(ot).readonly()
1564
- }), Yi = ji.superRefine(pt), Oi = j.innerType().extend({ kind: a.literal("matrix") }), Pi = Oi.superRefine(({ kind: e, ...t }, i) => {
1564
+ measures: a.array(nt).readonly()
1565
+ }), Yi = ji.superRefine(dt), Oi = j.innerType().extend({ kind: a.literal("matrix") }), Pi = Oi.superRefine(({ kind: e, ...t }, i) => {
1565
1566
  const s = j.safeParse(t);
1566
1567
  s.success || s.error.issues.forEach((l) => i.addIssue(l));
1567
- }), qi = "{member}", xe = a.object({
1568
+ }), qi = "{member}", ke = a.object({
1568
1569
  visible: a.boolean(),
1569
1570
  position: a.enum(["before", "after"]),
1570
1571
  /** As written; a subtotal's `{member}` becomes its member's name. */
1571
1572
  label: a.string().optional()
1572
- }).strict(), Fe = a.object({
1573
- grand: xe,
1574
- levels: a.record(b, xe).readonly(),
1573
+ }).strict(), xe = a.object({
1574
+ grand: ke,
1575
+ levels: a.record(b, ke).readonly(),
1575
1576
  /**
1576
1577
  * Skip a subtotal that only repeats one row: an expanded group with
1577
1578
  * exactly one child shows no subtotal. Off when absent.
@@ -1587,35 +1588,35 @@ const j = dt.superRefine(pt), ji = dt.extend({
1587
1588
  measureLabels: a.record(b, a.string()).readonly(),
1588
1589
  levelFormats: a.record(b, O).readonly(),
1589
1590
  measureFormats: a.record(b, O).readonly(),
1590
- totals: a.object({ rows: Fe, columns: Fe }).strict()
1591
- }, ge = a.object(Li).strict(), Bi = a.object({
1591
+ totals: a.object({ rows: xe, columns: xe }).strict()
1592
+ }, fe = a.object(Li).strict(), Bi = a.object({
1592
1593
  depth: a.number().int().nonnegative().max(Number.MAX_SAFE_INTEGER),
1593
1594
  overrides: a.array(
1594
- a.object({ path: A, expanded: a.boolean() }).strict()
1595
+ a.object({ path: k, expanded: a.boolean() }).strict()
1595
1596
  ).readonly()
1596
- }).strict(), De = Bi.superRefine(
1597
+ }).strict(), Fe = Bi.superRefine(
1597
1598
  (e, t) => w(
1598
- e.overrides.map((i) => Qe(i.path)),
1599
+ e.overrides.map((i) => Ue(i.path)),
1599
1600
  t,
1600
1601
  ["overrides"]
1601
1602
  )
1602
- ), Hi = { rows: De, columns: De }, H = a.object(Hi).strict(), Vi = H.extend({ sorts: a.array(lt).readonly() }).strict(), Ui = Vi.superRefine(
1603
- (e, t) => w(e.sorts.map(ut), t, ["sorts"])
1603
+ ), Hi = { rows: Fe, columns: Fe }, H = a.object(Hi).strict(), Vi = H.extend({ sorts: a.array(st).readonly() }).strict(), Ui = Vi.superRefine(
1604
+ (e, t) => w(e.sorts.map(ot), t, ["sorts"])
1604
1605
  );
1605
1606
  function V(e, t) {
1606
- var p, m;
1607
- const { spec: i, presentation: s, defaults: l, session: n } = e, o = new Set([...i.rows, ...i.columns].map((u) => u.id)), d = new Set(i.measures.map((u) => u.id));
1607
+ var c, p;
1608
+ const { spec: i, presentation: s, defaults: l, session: n } = e, r = new Set([...i.rows, ...i.columns].map((u) => u.id)), d = new Set(i.measures.map((u) => u.id));
1608
1609
  for (const u of [
1609
1610
  "levelLabels",
1610
1611
  "levelFormats",
1611
1612
  "measureLabels",
1612
1613
  "measureFormats"
1613
1614
  ]) {
1614
- const g = u.startsWith("level") ? o : d;
1615
- for (const y of Object.keys(s[u]))
1616
- g.has(y) || h(
1615
+ const g = u.startsWith("level") ? r : d;
1616
+ for (const _ of Object.keys(s[u]))
1617
+ g.has(_) || h(
1617
1618
  t,
1618
- ["presentation", u, y],
1619
+ ["presentation", u, _],
1619
1620
  "Unknown presentation reference."
1620
1621
  );
1621
1622
  }
@@ -1626,13 +1627,13 @@ function V(e, t) {
1626
1627
  "Measures cannot own temporal bucket formats."
1627
1628
  );
1628
1629
  for (const [u, g] of Object.entries(s.levelFormats))
1629
- g.type === "temporal_bucket" && !((p = [...i.rows, ...i.columns].find((y) => y.id === u)) != null && p.grain) && h(
1630
+ g.type === "temporal_bucket" && !((c = [...i.rows, ...i.columns].find((_) => _.id === u)) != null && c.grain) && h(
1630
1631
  t,
1631
1632
  ["presentation", "levelFormats", u],
1632
1633
  "Temporal bucket formats require a grain."
1633
1634
  );
1634
1635
  for (const u of ["rows", "columns"]) {
1635
- (m = s.totals[u].grand.label) != null && m.includes(
1636
+ (p = s.totals[u].grand.label) != null && p.includes(
1636
1637
  qi
1637
1638
  ) && h(
1638
1639
  t,
@@ -1640,13 +1641,13 @@ function V(e, t) {
1640
1641
  "The grand total has no member, so its label cannot use {member}."
1641
1642
  );
1642
1643
  const g = Object.keys(s.totals[u].levels);
1643
- (g.length !== i[u].length || g.some((y) => !i[u].some((I) => I.id === y))) && h(
1644
+ (g.length !== i[u].length || g.some((_) => !i[u].some((I) => I.id === _))) && h(
1644
1645
  t,
1645
1646
  ["presentation", "totals", u],
1646
1647
  "Subtotal map must contain exactly the current axis levels."
1647
1648
  );
1648
- for (const y of [l, ...n ? [n] : []])
1649
- for (const I of y[u].overrides)
1649
+ for (const _ of [l, ...n ? [n] : []])
1650
+ for (const I of _[u].overrides)
1650
1651
  L(
1651
1652
  i,
1652
1653
  u,
@@ -1660,24 +1661,24 @@ function V(e, t) {
1660
1661
  "Use depth to expand/collapse the root."
1661
1662
  );
1662
1663
  }
1663
- n && ct(i, n.sorts, t, ["session", "sorts"]);
1664
+ n && lt(i, n.sorts, t, ["session", "sorts"]);
1664
1665
  }
1665
1666
  const zi = a.object({
1666
1667
  spec: j,
1667
- presentation: ge,
1668
+ presentation: fe,
1668
1669
  defaults: H,
1669
1670
  session: Ui.optional()
1670
- }).strict(), dn = zi.superRefine(V), Gi = a.object({
1671
+ }).strict(), on = zi.superRefine(V), Gi = a.object({
1671
1672
  version: a.literal(1),
1672
1673
  spec: j,
1673
- presentation: ge,
1674
+ presentation: fe,
1674
1675
  defaultView: H
1675
1676
  }).strict(), Qi = Gi.superRefine(
1676
1677
  (e, t) => V({ ...e, defaults: e.defaultView }, t)
1677
1678
  ), Ki = Qi.innerType().extend({
1678
1679
  spec: Yi
1679
- }), un = Ki.superRefine((e, t) => V({ ...e, defaults: e.defaultView }, t)), Me = a.object({ spec: j, presentation: ge }).strict(), Xi = a.union([
1680
- Me.extend({
1680
+ }), ln = Ki.superRefine((e, t) => V({ ...e, defaults: e.defaultView }, t)), De = a.object({ spec: j, presentation: fe }).strict(), Xi = a.union([
1681
+ De.extend({
1681
1682
  mode: a.literal("layout"),
1682
1683
  format: a.enum(["csv", "xlsx", "pdf"]),
1683
1684
  expansion: a.union([
@@ -1685,8 +1686,8 @@ const zi = a.object({
1685
1686
  a.object({ kind: a.literal("all") }).strict()
1686
1687
  ])
1687
1688
  }).strict(),
1688
- Me.extend({ mode: a.literal("flat"), format: a.enum(["csv", "xlsx"]) }).strict()
1689
- ]), cn = Xi.superRefine(
1689
+ De.extend({ mode: a.literal("flat"), format: a.enum(["csv", "xlsx"]) }).strict()
1690
+ ]), dn = Xi.superRefine(
1690
1691
  (e, t) => V(
1691
1692
  {
1692
1693
  ...e,
@@ -1698,29 +1699,29 @@ const zi = a.object({
1698
1699
  t
1699
1700
  )
1700
1701
  );
1701
- function pn(e) {
1702
+ function un(e) {
1702
1703
  return e && "id" in e ? e.id : void 0;
1703
1704
  }
1704
1705
  const Zi = "SUM";
1705
- function k(e) {
1706
+ function A(e) {
1706
1707
  return typeof e == "string" && e.trim().length > 0;
1707
1708
  }
1708
- function T(e) {
1709
- return k(e) ? e.trim().toLowerCase() : "";
1709
+ function N(e) {
1710
+ return A(e) ? e.trim().toLowerCase() : "";
1710
1711
  }
1711
- function mn(e) {
1712
- const t = k(e.id) ? e.id.trim() : void 0;
1712
+ function cn(e) {
1713
+ const t = A(e.id) ? e.id.trim() : void 0;
1713
1714
  if (!t) return;
1714
- const i = T(t), s = k(e.table) ? e.table.trim() : void 0;
1715
- if (!(i === T(e.name) || s && i === T(s)))
1715
+ const i = N(t), s = A(e.table) ? e.table.trim() : void 0;
1716
+ if (!(i === N(e.name) || s && i === N(s)))
1716
1717
  return t;
1717
1718
  }
1718
1719
  function F(e) {
1719
- const t = k(e.datasetId) ? e.datasetId.trim() : void 0;
1720
+ const t = A(e.datasetId) ? e.datasetId.trim() : void 0;
1720
1721
  if (t)
1721
- return T(t) === T(e.datasetName) ? void 0 : t;
1722
+ return N(t) === N(e.datasetName) ? void 0 : t;
1722
1723
  }
1723
- function mt(e) {
1724
+ function ut(e) {
1724
1725
  if (e.kind !== "semantic") return e;
1725
1726
  const t = F(e), { datasetId: i, ...s } = e;
1726
1727
  return {
@@ -1728,8 +1729,8 @@ function mt(e) {
1728
1729
  ...t ? { datasetId: t } : {}
1729
1730
  };
1730
1731
  }
1731
- function fn(e) {
1732
- return e ? e.kind === "semantic" ? !!(k(e.domainId) && (k(e.datasetId) || k(e.datasetName))) : e.kind === "physical" ? k(e.connectionId) && k(e.tableName) : k(e.connectionId) : !1;
1732
+ function pn(e) {
1733
+ return e ? e.kind === "semantic" ? !!(A(e.domainId) && (A(e.datasetId) || A(e.datasetName))) : e.kind === "physical" ? A(e.connectionId) && A(e.tableName) : A(e.connectionId) : !1;
1733
1734
  }
1734
1735
  function te(e) {
1735
1736
  if (!e)
@@ -1755,7 +1756,7 @@ function te(e) {
1755
1756
  e.label || ""
1756
1757
  ].join(":");
1757
1758
  }
1758
- function he(e, t) {
1759
+ function ge(e, t) {
1759
1760
  if (!e || !t)
1760
1761
  return e === t;
1761
1762
  if (e.kind !== t.kind)
@@ -1768,8 +1769,8 @@ function he(e, t) {
1768
1769
  }
1769
1770
  return te(e) === te(t);
1770
1771
  }
1771
- function ft(e, t) {
1772
- return e.kind !== "semantic" || t.kind !== "semantic" ? e : mt({
1772
+ function ct(e, t) {
1773
+ return e.kind !== "semantic" || t.kind !== "semantic" ? e : ut({
1773
1774
  ...e,
1774
1775
  datasetName: e.datasetName || t.datasetName,
1775
1776
  datasetId: F(e) || F(t),
@@ -1777,19 +1778,19 @@ function ft(e, t) {
1777
1778
  connectionId: e.connectionId || t.connectionId
1778
1779
  });
1779
1780
  }
1780
- function gn(e) {
1781
+ function mn(e) {
1781
1782
  const t = [];
1782
1783
  for (const i of e) {
1783
- const s = mt(
1784
+ const s = ut(
1784
1785
  i
1785
1786
  ), l = t.findIndex(
1786
- (n) => he(n, s)
1787
+ (n) => ge(n, s)
1787
1788
  );
1788
1789
  if (l === -1) {
1789
1790
  t.push(s);
1790
1791
  continue;
1791
1792
  }
1792
- t[l] = ft(
1793
+ t[l] = ct(
1793
1794
  t[l],
1794
1795
  s
1795
1796
  );
@@ -1797,16 +1798,16 @@ function gn(e) {
1797
1798
  return t;
1798
1799
  }
1799
1800
  function Ji(e, t) {
1800
- return e.name === t.name && he(e.source, t.source);
1801
+ return e.name === t.name && ge(e.source, t.source);
1801
1802
  }
1802
- function hn(e) {
1803
+ function fn(e) {
1803
1804
  return [
1804
1805
  e.source ? te(e.source) : "unknown",
1805
- gt(e),
1806
+ pt(e),
1806
1807
  e.name
1807
1808
  ].filter(Boolean).join(":");
1808
1809
  }
1809
- function gt(e) {
1810
+ function pt(e) {
1810
1811
  return Wi(
1811
1812
  e.aggregate || Zi
1812
1813
  );
@@ -1814,42 +1815,42 @@ function gt(e) {
1814
1815
  function Wi(e) {
1815
1816
  return e.trim().toUpperCase();
1816
1817
  }
1817
- function _n(e, t) {
1818
+ function gn(e, t) {
1818
1819
  return {
1819
1820
  ...e,
1820
1821
  label: e.label || t.label,
1821
1822
  role: e.role || t.role,
1822
1823
  dataType: e.dataType || t.dataType,
1823
- source: e.source && t.source ? ft(e.source, t.source) : e.source || t.source
1824
+ source: e.source && t.source ? ct(e.source, t.source) : e.source || t.source
1824
1825
  };
1825
1826
  }
1826
1827
  function ea(e) {
1827
1828
  for (let t = 0; t < e.length; t += 1) {
1828
1829
  const i = e[t];
1829
1830
  if (e.some(
1830
- (s, l) => l !== t && _t(s, i)
1831
+ (s, l) => l !== t && ft(s, i)
1831
1832
  ))
1832
1833
  return !1;
1833
1834
  }
1834
1835
  return !0;
1835
1836
  }
1836
- function ht(e, t) {
1837
+ function mt(e, t) {
1837
1838
  return Ji(e, t);
1838
1839
  }
1839
- function _t(e, t) {
1840
- return ht(e, t) && $(e) === $(t);
1840
+ function ft(e, t) {
1841
+ return mt(e, t) && $(e) === $(t);
1841
1842
  }
1842
1843
  function ta(e) {
1843
1844
  return `Metric intent has duplicate measure "${e.name}" with the same aggregate (${$(e)}). Use different aggregates to request both, or remove one entry.`;
1844
1845
  }
1845
- function Ee(e) {
1846
+ function Me(e) {
1846
1847
  return typeof e == "string" || typeof e == "number" || typeof e == "boolean" || e === null;
1847
1848
  }
1848
1849
  function ia(e, t, i) {
1849
1850
  if (e !== void 0) {
1850
1851
  if (!e || typeof e != "object" || Array.isArray(e)) {
1851
1852
  i.push(
1852
- r(
1853
+ o(
1853
1854
  "invalid_sql_default_parameters",
1854
1855
  "SQL defaultParameters must be an object keyed by parameter name.",
1855
1856
  t
@@ -1860,7 +1861,7 @@ function ia(e, t, i) {
1860
1861
  Object.entries(e).forEach(([s, l]) => {
1861
1862
  if (!s.trim()) {
1862
1863
  i.push(
1863
- r(
1864
+ o(
1864
1865
  "invalid_sql_default_parameter_name",
1865
1866
  "SQL defaultParameters names must be non-empty strings.",
1866
1867
  `${t}.${s}`
@@ -1868,8 +1869,8 @@ function ia(e, t, i) {
1868
1869
  );
1869
1870
  return;
1870
1871
  }
1871
- (Array.isArray(l) ? l.every(Ee) : Ee(l)) || i.push(
1872
- r(
1872
+ (Array.isArray(l) ? l.every(Me) : Me(l)) || i.push(
1873
+ o(
1873
1874
  "invalid_sql_default_parameter_value",
1874
1875
  "SQL defaultParameters values must be strings, numbers, booleans, nulls, or arrays of those scalar values.",
1875
1876
  `${t}.${s}`
@@ -1879,18 +1880,18 @@ function ia(e, t, i) {
1879
1880
  }
1880
1881
  }
1881
1882
  function aa(e, t) {
1882
- return _e(e, t).length === 1;
1883
+ return he(e, t).length === 1;
1883
1884
  }
1884
1885
  function na(e, t) {
1885
- return _e(e, t).length === 1;
1886
+ return he(e, t).length === 1;
1886
1887
  }
1887
- function _e(e, t) {
1888
+ function he(e, t) {
1888
1889
  return t.filter(
1889
1890
  (s) => sa(e, s)
1890
1891
  );
1891
1892
  }
1892
1893
  function sa(e, t) {
1893
- return ra(e, t) ? e.source ? ht(t, e) : !0 : !1;
1894
+ return ra(e, t) ? e.source ? mt(t, e) : !0 : !1;
1894
1895
  }
1895
1896
  function ra(e, t) {
1896
1897
  return !(t.name !== e.name || e.role !== void 0 && t.role !== void 0 && t.role !== e.role || oa(e, t) && $(t) !== $(e));
@@ -1899,37 +1900,37 @@ function oa(e, t) {
1899
1900
  return e.role === "measure" || t.role === "measure" || e.aggregate !== void 0 || t.aggregate !== void 0;
1900
1901
  }
1901
1902
  function $(e) {
1902
- return gt(e);
1903
+ return pt(e);
1903
1904
  }
1904
- const la = /^(\d{4})-(\d{2})-(\d{2})$/, yt = /^(\d{4})-(\d{2})-(\d{2})T(\d{2}):(\d{2})(?::(\d{2})(?:\.(\d+))?)?(Z|[+-]\d{2}:\d{2})$/;
1905
+ const la = /^(\d{4})-(\d{2})-(\d{2})$/, gt = /^(\d{4})-(\d{2})-(\d{2})T(\d{2}):(\d{2})(?::(\d{2})(?:\.(\d+))?)?(Z|[+-]\d{2}:\d{2})$/;
1905
1906
  function ie(e) {
1906
1907
  if (typeof e != "string")
1907
1908
  return null;
1908
1909
  const t = e.trim(), i = la.exec(t);
1909
1910
  if (i) {
1910
- const [, y, I, S] = i;
1911
- return Te(y, I, S) ? new Date(Date.UTC(Number(y), Number(I) - 1, Number(S))) : null;
1911
+ const [, _, I, S] = i;
1912
+ return Ee(_, I, S) ? new Date(Date.UTC(Number(_), Number(I) - 1, Number(S))) : null;
1912
1913
  }
1913
- const s = yt.exec(t);
1914
+ const s = gt.exec(t);
1914
1915
  if (!s)
1915
1916
  return null;
1916
- const [, l, n, o, d, p, m = "00", , u] = s;
1917
- if (!Te(l, n, o) || !N(d, 0, 23) || !N(p, 0, 59) || !N(m, 0, 59) || !da(u))
1917
+ const [, l, n, r, d, c, p = "00", , u] = s;
1918
+ if (!Ee(l, n, r) || !T(d, 0, 23) || !T(c, 0, 59) || !T(p, 0, 59) || !da(u))
1918
1919
  return null;
1919
1920
  const g = new Date(t);
1920
1921
  return Number.isFinite(g.getTime()) ? g : null;
1921
1922
  }
1922
- function yn(e) {
1923
- return typeof e != "string" || !yt.test(e.trim()) ? null : ie(e);
1923
+ function hn(e) {
1924
+ return typeof e != "string" || !gt.test(e.trim()) ? null : ie(e);
1924
1925
  }
1925
- function Te(e, t, i) {
1926
+ function Ee(e, t, i) {
1926
1927
  const s = Number(e), l = Number(t), n = Number(i);
1927
1928
  if (!Number.isInteger(s) || !Number.isInteger(l) || !Number.isInteger(n) || l < 1 || l > 12)
1928
1929
  return !1;
1929
- const o = new Date(Date.UTC(s, l - 1, n));
1930
- return o.getUTCFullYear() === s && o.getUTCMonth() === l - 1 && o.getUTCDate() === n;
1930
+ const r = new Date(Date.UTC(s, l - 1, n));
1931
+ return r.getUTCFullYear() === s && r.getUTCMonth() === l - 1 && r.getUTCDate() === n;
1931
1932
  }
1932
- function N(e, t, i) {
1933
+ function T(e, t, i) {
1933
1934
  const s = Number(e);
1934
1935
  return Number.isInteger(s) && s >= t && s <= i;
1935
1936
  }
@@ -1937,13 +1938,13 @@ function da(e) {
1937
1938
  if (e === "Z")
1938
1939
  return !0;
1939
1940
  const t = /^([+-])(\d{2}):(\d{2})$/.exec(e);
1940
- return !!(t && N(t[2], 0, 23) && N(t[3], 0, 59));
1941
+ return !!(t && T(t[2], 0, 23) && T(t[3], 0, 59));
1941
1942
  }
1942
1943
  function Ne(e, t, i) {
1943
1944
  if (e !== void 0) {
1944
1945
  if (!f(e)) {
1945
1946
  i.push(
1946
- r(
1947
+ o(
1947
1948
  "invalid_pagination",
1948
1949
  "Pagination must be an object with positive integer page and pageSize.",
1949
1950
  t
@@ -1952,13 +1953,13 @@ function Ne(e, t, i) {
1952
1953
  return;
1953
1954
  }
1954
1955
  (!Number.isInteger(e.page) || typeof e.page != "number" || e.page < 1) && i.push(
1955
- r(
1956
+ o(
1956
1957
  "invalid_pagination_page",
1957
1958
  "Pagination page must be a positive integer.",
1958
1959
  `${t}.page`
1959
1960
  )
1960
1961
  ), (!Number.isInteger(e.pageSize) || typeof e.pageSize != "number" || e.pageSize < 1) && i.push(
1961
- r(
1962
+ o(
1962
1963
  "invalid_pagination_page_size",
1963
1964
  "Pagination pageSize must be a positive integer.",
1964
1965
  `${t}.pageSize`
@@ -1966,7 +1967,7 @@ function Ne(e, t, i) {
1966
1967
  );
1967
1968
  }
1968
1969
  }
1969
- function Re(e) {
1970
+ function Te(e) {
1970
1971
  const t = /* @__PURE__ */ new Set();
1971
1972
  for (const i of e) {
1972
1973
  if (t.has(i))
@@ -1978,7 +1979,7 @@ function Re(e) {
1978
1979
  function ua(e, t, i) {
1979
1980
  if (!f(e)) {
1980
1981
  i.push(
1981
- r(
1982
+ o(
1982
1983
  "invalid_input_binding",
1983
1984
  "Input bindings must be structured objects.",
1984
1985
  t
@@ -1986,28 +1987,28 @@ function ua(e, t, i) {
1986
1987
  );
1987
1988
  return;
1988
1989
  }
1989
- c(e.inputId) || i.push(
1990
- r(
1990
+ m(e.inputId) || i.push(
1991
+ o(
1991
1992
  "invalid_input_binding",
1992
1993
  "Input bindings need a non-empty inputId.",
1993
1994
  `${t}.inputId`
1994
1995
  )
1995
1996
  ), e.kind !== void 0 && e.kind !== "filter" && e.kind !== "control" && i.push(
1996
- r(
1997
+ o(
1997
1998
  "invalid_input_binding",
1998
1999
  "Input binding kind must be filter or control.",
1999
2000
  `${t}.kind`
2000
2001
  )
2001
- ), e.field !== void 0 && _(e.field, `${t}.field`, i), e.relationshipHint !== void 0 && ye(
2002
+ ), e.field !== void 0 && y(e.field, `${t}.field`, i), e.relationshipHint !== void 0 && _e(
2002
2003
  e.relationshipHint,
2003
2004
  `${t}.relationshipHint`,
2004
2005
  i
2005
2006
  );
2006
2007
  }
2007
- function ye(e, t, i) {
2008
+ function _e(e, t, i) {
2008
2009
  if (!f(e)) {
2009
2010
  i.push(
2010
- r(
2011
+ o(
2011
2012
  "invalid_relationship_hint",
2012
2013
  "Relationship hints must be structured objects.",
2013
2014
  t
@@ -2015,8 +2016,8 @@ function ye(e, t, i) {
2015
2016
  );
2016
2017
  return;
2017
2018
  }
2018
- e.relationshipIds !== void 0 && (!Array.isArray(e.relationshipIds) || e.relationshipIds.some((s) => !c(s))) && i.push(
2019
- r(
2019
+ e.relationshipIds !== void 0 && (!Array.isArray(e.relationshipIds) || e.relationshipIds.some((s) => !m(s))) && i.push(
2020
+ o(
2020
2021
  "invalid_relationship_hint",
2021
2022
  "Relationship hint relationshipIds must be non-empty strings.",
2022
2023
  `${t}.relationshipIds`
@@ -2026,29 +2027,29 @@ function ye(e, t, i) {
2026
2027
  function ca(e, t) {
2027
2028
  var s, l;
2028
2029
  if (((s = e.source) == null ? void 0 : s.kind) !== "semantic" && ((l = e.source) == null ? void 0 : l.kind) !== "physical" && t.push(
2029
- r(
2030
+ o(
2030
2031
  "invalid_input_options_source",
2031
2032
  "Input options must use a semantic or physical source.",
2032
2033
  "source"
2033
2034
  )
2034
- ), c(e.inputId) || t.push(
2035
- r(
2035
+ ), m(e.inputId) || t.push(
2036
+ o(
2036
2037
  "missing_input_options_input_id",
2037
2038
  "Input options intent needs the inputId it populates.",
2038
2039
  "inputId"
2039
2040
  )
2040
2041
  ), e.search !== void 0 && typeof e.search != "string" && t.push(
2041
- r(
2042
+ o(
2042
2043
  "invalid_input_options_search",
2043
2044
  "Input options search must be a string.",
2044
2045
  "search"
2045
2046
  )
2046
2047
  ), e.matchValues !== void 0) {
2047
- const n = Et(e.matchValues);
2048
+ const n = Dt(e.matchValues);
2048
2049
  n.ok || t.push(
2049
- r("invalid_input_options_match_values", n.error, "matchValues")
2050
+ o("invalid_input_options_match_values", n.error, "matchValues")
2050
2051
  ), typeof e.search == "string" && e.search.trim() && t.push(
2051
- r(
2052
+ o(
2052
2053
  "invalid_input_options_match_values",
2053
2054
  "Input options matchValues cannot be combined with search.",
2054
2055
  "matchValues"
@@ -2056,35 +2057,35 @@ function ca(e, t) {
2056
2057
  );
2057
2058
  }
2058
2059
  if (e.limit !== void 0 && (typeof e.limit != "number" || !Number.isFinite(e.limit) || !Number.isInteger(e.limit) || e.limit <= 0) && t.push(
2059
- r(
2060
+ o(
2060
2061
  "invalid_input_options_limit",
2061
2062
  "Input options limit must be a positive finite number.",
2062
2063
  "limit"
2063
2064
  )
2064
- ), (!e.labelField || !c(e.labelField.name)) && t.push(
2065
- r(
2065
+ ), (!e.labelField || !m(e.labelField.name)) && t.push(
2066
+ o(
2066
2067
  "missing_input_options_label_field",
2067
2068
  "Input options intent needs a labelField.",
2068
2069
  "labelField"
2069
2070
  )
2070
- ), _(e.labelField, "labelField", t, {
2071
+ ), y(e.labelField, "labelField", t, {
2071
2072
  required: !0
2072
- }), (!e.valueField || !c(e.valueField.name)) && t.push(
2073
- r(
2073
+ }), (!e.valueField || !m(e.valueField.name)) && t.push(
2074
+ o(
2074
2075
  "missing_input_options_value_field",
2075
2076
  "Input options intent needs a valueField.",
2076
2077
  "valueField"
2077
2078
  )
2078
- ), _(e.valueField, "valueField", t, {
2079
+ ), y(e.valueField, "valueField", t, {
2079
2080
  required: !0
2080
- }), e.searchField !== void 0 && _(e.searchField, "searchField", t, {
2081
+ }), e.searchField !== void 0 && y(e.searchField, "searchField", t, {
2081
2082
  required: !0
2082
- }), e.disambiguationFields !== void 0 && (Array.isArray(e.disambiguationFields) ? e.disambiguationFields.forEach((n, o) => {
2083
- _(n, `disambiguationFields.${o}`, t, {
2083
+ }), e.disambiguationFields !== void 0 && (Array.isArray(e.disambiguationFields) ? e.disambiguationFields.forEach((n, r) => {
2084
+ y(n, `disambiguationFields.${r}`, t, {
2084
2085
  required: !0
2085
2086
  });
2086
2087
  }) : t.push(
2087
- r(
2088
+ o(
2088
2089
  "invalid_input_options_disambiguation_fields",
2089
2090
  "Input options disambiguationFields must be an array of field refs.",
2090
2091
  "disambiguationFields"
@@ -2093,16 +2094,16 @@ function ca(e, t) {
2093
2094
  { field: e.labelField, path: "labelField" },
2094
2095
  { field: e.valueField, path: "valueField" },
2095
2096
  ...e.searchField ? [{ field: e.searchField, path: "searchField" }] : [],
2096
- ...Array.isArray(e.disambiguationFields) ? e.disambiguationFields.map((n, o) => ({
2097
+ ...Array.isArray(e.disambiguationFields) ? e.disambiguationFields.map((n, r) => ({
2097
2098
  field: n,
2098
- path: `disambiguationFields.${o}`
2099
+ path: `disambiguationFields.${r}`
2099
2100
  })) : []
2100
- ].forEach(({ field: n, path: o }) => {
2101
- n != null && n.source && !he(n.source, e.source) && t.push(
2102
- r(
2101
+ ].forEach(({ field: n, path: r }) => {
2102
+ n != null && n.source && !ge(n.source, e.source) && t.push(
2103
+ o(
2103
2104
  "input_options_field_source_mismatch",
2104
2105
  "Input option fields must belong to the declared option source.",
2105
- `${o}.source`
2106
+ `${r}.source`
2106
2107
  )
2107
2108
  );
2108
2109
  }), e.dependencies !== void 0) {
@@ -2115,37 +2116,37 @@ function ca(e, t) {
2115
2116
  const n = e.population;
2116
2117
  if (!f(n))
2117
2118
  t.push(
2118
- r(
2119
+ o(
2119
2120
  "invalid_input_options_population",
2120
2121
  "Input options population must be a structured object.",
2121
2122
  "population"
2122
2123
  )
2123
2124
  );
2124
2125
  else {
2125
- const o = n.kind;
2126
- o !== "option_source" && o !== "related_population" && t.push(
2127
- r(
2126
+ const r = n.kind;
2127
+ r !== "option_source" && r !== "related_population" && t.push(
2128
+ o(
2128
2129
  "invalid_input_options_population",
2129
2130
  "Input options population kind must be option_source or related_population.",
2130
2131
  "population.kind"
2131
2132
  )
2132
- ), o === "option_source" && n.baseSource !== void 0 && t.push(
2133
- r(
2133
+ ), r === "option_source" && n.baseSource !== void 0 && t.push(
2134
+ o(
2134
2135
  "invalid_input_options_population",
2135
2136
  "Input options population baseSource is only valid for related_population.",
2136
2137
  "population.baseSource"
2137
2138
  )
2138
- ), o === "option_source" && n.relationshipHint !== void 0 && t.push(
2139
- r(
2139
+ ), r === "option_source" && n.relationshipHint !== void 0 && t.push(
2140
+ o(
2140
2141
  "invalid_input_options_population",
2141
2142
  "Input options population relationshipHint is only valid for related_population.",
2142
2143
  "population.relationshipHint"
2143
2144
  )
2144
- ), o === "related_population" && (se(
2145
+ ), r === "related_population" && (ne(
2145
2146
  n.baseSource,
2146
2147
  "population.baseSource",
2147
2148
  t
2148
- ), n.relationshipHint !== void 0 && ye(
2149
+ ), n.relationshipHint !== void 0 && _e(
2149
2150
  n.relationshipHint,
2150
2151
  "population.relationshipHint",
2151
2152
  t
@@ -2157,7 +2158,7 @@ function pa(e, t) {
2157
2158
  if (!(!("inputs" in e) || e.inputs === void 0)) {
2158
2159
  if (!Array.isArray(e.inputs)) {
2159
2160
  t.push(
2160
- r(
2161
+ o(
2161
2162
  "invalid_input_binding",
2162
2163
  "Analytics intent inputs must be an array of input bindings.",
2163
2164
  "inputs"
@@ -2174,7 +2175,7 @@ function ma(e, t = "protocol") {
2174
2175
  const i = [];
2175
2176
  if (!f(e))
2176
2177
  return i.push(
2177
- r(
2178
+ o(
2178
2179
  "invalid_input_options_dependencies",
2179
2180
  "Input options dependencies must be a structured object.",
2180
2181
  "dependencies"
@@ -2182,7 +2183,7 @@ function ma(e, t = "protocol") {
2182
2183
  ), { ok: !1, errors: i, warnings: [] };
2183
2184
  const s = e, l = s.mode;
2184
2185
  if (l !== void 0 && l !== "independent" && l !== "explicit" && l !== "all_applicable" && i.push(
2185
- r(
2186
+ o(
2186
2187
  "invalid_input_options_dependencies",
2187
2188
  "Input options dependencies mode must be independent, explicit, or all_applicable.",
2188
2189
  "dependencies.mode"
@@ -2198,7 +2199,7 @@ function ma(e, t = "protocol") {
2198
2199
  i,
2199
2200
  "Input options excludeInputIds must be non-empty strings."
2200
2201
  ), l === "all_applicable" && s.includeInputIds !== void 0 && i.push(
2201
- r(
2202
+ o(
2202
2203
  "invalid_input_options_dependencies",
2203
2204
  "All applicable dependencies cannot specify includeInputIds.",
2204
2205
  "dependencies.includeInputIds"
@@ -2212,8 +2213,8 @@ function ma(e, t = "protocol") {
2212
2213
  const n = new Set(
2213
2214
  Array.isArray(s.includeInputIds) ? s.includeInputIds : []
2214
2215
  );
2215
- (l !== "explicit" || new Set(s.omitInputIds).size !== s.omitInputIds.length || s.omitInputIds.some((o) => !n.has(o))) && i.push(
2216
- r(
2216
+ (l !== "explicit" || new Set(s.omitInputIds).size !== s.omitInputIds.length || s.omitInputIds.some((r) => !n.has(r))) && i.push(
2217
+ o(
2217
2218
  "invalid_input_options_dependencies",
2218
2219
  "A browse override may only omit unique ids from an explicit includeInputIds list.",
2219
2220
  "dependencies.omitInputIds"
@@ -2225,31 +2226,31 @@ function ma(e, t = "protocol") {
2225
2226
  function fa(e, t) {
2226
2227
  const { mode: i, includeInputIds: s, excludeInputIds: l } = e;
2227
2228
  i === void 0 && t.push(
2228
- r(
2229
+ o(
2229
2230
  "invalid_input_options_dependencies",
2230
2231
  "Dashboard option dependencies must declare a mode.",
2231
2232
  "dependencies.mode"
2232
2233
  )
2233
2234
  );
2234
- for (const [n, o] of [
2235
+ for (const [n, r] of [
2235
2236
  ["dependencies.includeInputIds", s],
2236
2237
  ["dependencies.excludeInputIds", l]
2237
2238
  ])
2238
- Array.isArray(o) && new Set(o).size !== o.length && t.push(
2239
- r(
2239
+ Array.isArray(r) && new Set(r).size !== r.length && t.push(
2240
+ o(
2240
2241
  "invalid_input_options_dependencies",
2241
2242
  "Dashboard option dependency input IDs must be unique.",
2242
2243
  n
2243
2244
  )
2244
2245
  );
2245
2246
  i === "independent" && (s !== void 0 || l !== void 0) && t.push(
2246
- r(
2247
+ o(
2247
2248
  "invalid_input_options_dependencies",
2248
2249
  "Independent dashboard dependencies cannot specify input IDs.",
2249
2250
  "dependencies"
2250
2251
  )
2251
2252
  ), i === "explicit" && (!Array.isArray(s) || s.length === 0 || l !== void 0) && t.push(
2252
- r(
2253
+ o(
2253
2254
  "invalid_input_options_dependencies",
2254
2255
  "Explicit dashboard dependencies require included input IDs and cannot specify exclusions.",
2255
2256
  "dependencies"
@@ -2257,21 +2258,21 @@ function fa(e, t) {
2257
2258
  );
2258
2259
  }
2259
2260
  function ga(e, t) {
2260
- var l, n, o;
2261
+ var l, n, r;
2261
2262
  const i = new Set(
2262
2263
  Array.isArray(e.inputs) ? e.inputs.map((d) => f(d) ? d.inputId : void 0).filter((d) => typeof d == "string") : []
2263
2264
  ), s = new Set(((l = e.dependencies) == null ? void 0 : l.omitInputIds) || []);
2264
2265
  for (const d of ((n = e.dependencies) == null ? void 0 : n.includeInputIds) || [])
2265
2266
  !i.has(d) && !s.has(d) && t.push(
2266
- r(
2267
+ o(
2267
2268
  "invalid_input_options_dependencies",
2268
2269
  `Input options dependency "${d}" is not declared in inputs.`,
2269
2270
  "dependencies.includeInputIds"
2270
2271
  )
2271
2272
  );
2272
- for (const d of ((o = e.dependencies) == null ? void 0 : o.excludeInputIds) || [])
2273
+ for (const d of ((r = e.dependencies) == null ? void 0 : r.excludeInputIds) || [])
2273
2274
  d !== e.inputId && !i.has(d) && t.push(
2274
- r(
2275
+ o(
2275
2276
  "invalid_input_options_dependencies",
2276
2277
  `Input options dependency exclusion "${d}" is not the populated inputId and is not declared in inputs.`,
2277
2278
  "dependencies.excludeInputIds"
@@ -2279,79 +2280,15 @@ function ga(e, t) {
2279
2280
  );
2280
2281
  }
2281
2282
  function K(e, t, i, s) {
2282
- e !== void 0 && (!Array.isArray(e) || e.some((l) => !c(l))) && i.push(r("invalid_input_options_dependencies", s, t));
2283
- }
2284
- const ha = new Set(Ye);
2285
- function _a(e, t, i) {
2286
- if (f(e) && e.type === "temporal_bucket") {
2287
- i.push(
2288
- r(
2289
- "invalid_scalar_value_format",
2290
- "Scalar and measure slots cannot own temporal bucket presentation; declare it with grain on a grouped field or axis.",
2291
- t
2292
- )
2293
- );
2294
- return;
2295
- }
2296
- Pe(e, t, i);
2297
- }
2298
- function Ce(e, t, i) {
2299
- if (!f(e)) {
2300
- i.push(
2301
- r(
2302
- "invalid_result_column_ref",
2303
- "Result calculation references must use columnKey or field.",
2304
- t
2305
- )
2306
- );
2307
- return;
2308
- }
2309
- const s = c(e.columnKey), l = f(e.field);
2310
- if (s === l) {
2311
- i.push(
2312
- r(
2313
- "invalid_result_column_ref",
2314
- "Result calculation references must identify exactly one of columnKey or field.",
2315
- t
2316
- )
2317
- );
2318
- return;
2319
- }
2320
- l && _(e.field, `${t}.field`, i, {
2321
- required: !0
2322
- });
2323
- }
2324
- function ya(e, t, i) {
2325
- if (!f(e)) {
2326
- i.push(
2327
- r(
2328
- "invalid_result_calculation_output",
2329
- "Result calculation output must be a structured object.",
2330
- t
2331
- )
2332
- );
2333
- return;
2334
- }
2335
- c(e.key) || i.push(
2336
- r(
2337
- "invalid_result_calculation_output",
2338
- "Result calculation output needs a stable key.",
2339
- `${t}.key`
2340
- )
2341
- ), e.dataType !== void 0 && (typeof e.dataType != "string" || !Oe.has(e.dataType)) && i.push(
2342
- r(
2343
- "invalid_result_calculation_output",
2344
- "Result calculation output dataType must be string, number, boolean, date, datetime, or unknown.",
2345
- `${t}.dataType`
2346
- )
2347
- ), _a(e.format, `${t}.format`, i);
2283
+ e !== void 0 && (!Array.isArray(e) || e.some((l) => !m(l))) && i.push(o("invalid_input_options_dependencies", s, t));
2348
2284
  }
2349
- function ba(e, t) {
2285
+ const ha = new Set(je);
2286
+ function _a(e, t) {
2350
2287
  if (e.analysis === void 0)
2351
2288
  return;
2352
2289
  if (!f(e.analysis)) {
2353
2290
  t.push(
2354
- r(
2291
+ o(
2355
2292
  "invalid_measure_analysis",
2356
2293
  "Metric analysis must be a structured object.",
2357
2294
  "analysis"
@@ -2361,7 +2298,7 @@ function ba(e, t) {
2361
2298
  }
2362
2299
  if (e.analysis.kind !== "period_change") {
2363
2300
  t.push(
2364
- r(
2301
+ o(
2365
2302
  "invalid_measure_analysis",
2366
2303
  "Metric analysis kind is not supported.",
2367
2304
  "analysis.kind"
@@ -2370,19 +2307,19 @@ function ba(e, t) {
2370
2307
  return;
2371
2308
  }
2372
2309
  e.dateField || t.push(
2373
- r(
2310
+ o(
2374
2311
  "missing_analysis_date_field",
2375
2312
  "Period-change analysis needs a dateField.",
2376
2313
  "dateField"
2377
2314
  )
2378
2315
  ), e.timeGrain || t.push(
2379
- r(
2316
+ o(
2380
2317
  "missing_analysis_time_grain",
2381
2318
  "Period-change analysis needs a timeGrain.",
2382
2319
  "timeGrain"
2383
2320
  )
2384
2321
  ), e.analysis.orderBy !== void 0 && e.analysis.orderBy !== "absolute_change" && e.analysis.orderBy !== "positive_change" && e.analysis.orderBy !== "negative_change" && e.analysis.orderBy !== "period" && t.push(
2385
- r(
2322
+ o(
2386
2323
  "invalid_measure_analysis",
2387
2324
  "Period-change analysis orderBy must be absolute_change, positive_change, negative_change, or period.",
2388
2325
  "analysis.orderBy"
@@ -2391,34 +2328,34 @@ function ba(e, t) {
2391
2328
  const { timeWindow: i } = e.analysis;
2392
2329
  i !== void 0 && ae(i, "analysis.timeWindow", t);
2393
2330
  }
2394
- const va = new Set(
2395
- Tt
2396
- ), Ia = new Set(
2331
+ const ya = new Set(
2332
+ Mt
2333
+ ), ba = new Set(
2334
+ Et
2335
+ ), va = new Set(
2397
2336
  Nt
2398
- ), Sa = new Set(
2399
- Rt
2400
2337
  );
2401
- function ka(e, t, i) {
2402
- va.has(e.unit) || i.push(
2403
- r(
2338
+ function Ia(e, t, i) {
2339
+ ya.has(e.unit) || i.push(
2340
+ o(
2404
2341
  "invalid_time_window",
2405
2342
  "Calendar time window unit must be one of: day, week, month, quarter, year.",
2406
2343
  `${t}.unit`
2407
2344
  )
2408
2345
  ), e.period !== "this" && e.period !== "previous" && i.push(
2409
- r(
2346
+ o(
2410
2347
  "invalid_time_window",
2411
2348
  "Calendar time window period must be this or previous.",
2412
2349
  `${t}.period`
2413
2350
  )
2414
2351
  ), e.toDate !== void 0 && typeof e.toDate != "boolean" ? i.push(
2415
- r(
2352
+ o(
2416
2353
  "invalid_time_window",
2417
2354
  "Calendar time window toDate must be a boolean.",
2418
2355
  `${t}.toDate`
2419
2356
  )
2420
2357
  ) : e.toDate === !0 && e.period !== "this" && i.push(
2421
- r(
2358
+ o(
2422
2359
  "invalid_time_window",
2423
2360
  "Calendar time window toDate is only allowed with period this.",
2424
2361
  `${t}.toDate`
@@ -2428,7 +2365,7 @@ function ka(e, t, i) {
2428
2365
  function ae(e, t, i) {
2429
2366
  if (!f(e)) {
2430
2367
  i.push(
2431
- r(
2368
+ o(
2432
2369
  "invalid_time_window",
2433
2370
  "Time window must be a structured object.",
2434
2371
  t
@@ -2437,44 +2374,44 @@ function ae(e, t, i) {
2437
2374
  return;
2438
2375
  }
2439
2376
  if (e.kind !== void 0 && e.kind !== "relative" && e.kind !== "calendar" && e.kind !== "absolute" && i.push(
2440
- r(
2377
+ o(
2441
2378
  "invalid_time_window",
2442
2379
  "Time window kind must be relative, calendar or absolute.",
2443
2380
  `${t}.kind`
2444
2381
  )
2445
2382
  ), e.kind === "calendar") {
2446
- ka(e, t, i);
2383
+ Ia(e, t, i);
2447
2384
  return;
2448
2385
  }
2449
2386
  if (e.kind === "absolute") {
2450
- if (c(e.start) || i.push(
2451
- r(
2387
+ if (m(e.start) || i.push(
2388
+ o(
2452
2389
  "invalid_time_window",
2453
2390
  "Absolute time window start must be a non-empty ISO date or timestamp string.",
2454
2391
  `${t}.start`
2455
2392
  )
2456
- ), c(e.end) || i.push(
2457
- r(
2393
+ ), m(e.end) || i.push(
2394
+ o(
2458
2395
  "invalid_time_window",
2459
2396
  "Absolute time window end must be a non-empty ISO date or timestamp string.",
2460
2397
  `${t}.end`
2461
2398
  )
2462
- ), c(e.start) && c(e.end)) {
2399
+ ), m(e.start) && m(e.end)) {
2463
2400
  const s = ie(e.start), l = ie(e.end);
2464
2401
  s || i.push(
2465
- r(
2402
+ o(
2466
2403
  "invalid_time_window",
2467
2404
  "Absolute time window start must be a valid ISO date or timestamp.",
2468
2405
  `${t}.start`
2469
2406
  )
2470
2407
  ), l || i.push(
2471
- r(
2408
+ o(
2472
2409
  "invalid_time_window",
2473
2410
  "Absolute time window end must be a valid ISO date or timestamp.",
2474
2411
  `${t}.end`
2475
2412
  )
2476
2413
  ), s && l && s.getTime() > l.getTime() && i.push(
2477
- r(
2414
+ o(
2478
2415
  "invalid_time_window",
2479
2416
  "Absolute time window start must be before or equal to end.",
2480
2417
  t
@@ -2484,36 +2421,36 @@ function ae(e, t, i) {
2484
2421
  return;
2485
2422
  }
2486
2423
  (typeof e.unit != "string" || !ha.has(e.unit)) && i.push(
2487
- r(
2424
+ o(
2488
2425
  "invalid_time_window",
2489
- `Time window unit must be one of: ${Ye.join(", ")}.`,
2426
+ `Time window unit must be one of: ${je.join(", ")}.`,
2490
2427
  `${t}.unit`
2491
2428
  )
2492
2429
  ), (typeof e.value != "number" || !Number.isFinite(e.value) || e.value <= 0) && i.push(
2493
- r(
2430
+ o(
2494
2431
  "invalid_time_window",
2495
2432
  "Time window value must be a positive number.",
2496
2433
  `${t}.value`
2497
2434
  )
2498
- ), e.anchor !== void 0 && !Ia.has(e.anchor) && i.push(
2499
- r(
2435
+ ), e.anchor !== void 0 && !ba.has(e.anchor) && i.push(
2436
+ o(
2500
2437
  "invalid_time_window",
2501
2438
  "Time window anchor must be now or latest_available.",
2502
2439
  `${t}.anchor`
2503
2440
  )
2504
- ), e.completeness !== void 0 && !Sa.has(e.completeness) && i.push(
2505
- r(
2441
+ ), e.completeness !== void 0 && !va.has(e.completeness) && i.push(
2442
+ o(
2506
2443
  "invalid_time_window",
2507
2444
  "Time window completeness must be include_partial or complete_periods.",
2508
2445
  `${t}.completeness`
2509
2446
  )
2510
2447
  );
2511
2448
  }
2512
- function ne(e, t, i) {
2449
+ function Re(e, t, i) {
2513
2450
  if (e !== void 0) {
2514
2451
  if (!Array.isArray(e)) {
2515
2452
  i.push(
2516
- r(
2453
+ o(
2517
2454
  "invalid_analytics_filters",
2518
2455
  "Analytics filters must be an array.",
2519
2456
  t
@@ -2522,11 +2459,11 @@ function ne(e, t, i) {
2522
2459
  return;
2523
2460
  }
2524
2461
  e.forEach((s, l) => {
2525
- var p;
2462
+ var c;
2526
2463
  const n = `${t}.${l}`;
2527
2464
  if (!f(s)) {
2528
2465
  i.push(
2529
- r(
2466
+ o(
2530
2467
  "invalid_analytics_filter",
2531
2468
  "Analytics filter must be a structured object.",
2532
2469
  n
@@ -2534,38 +2471,38 @@ function ne(e, t, i) {
2534
2471
  );
2535
2472
  return;
2536
2473
  }
2537
- const o = s;
2538
- _(o.field, `${n}.field`, i, {
2474
+ const r = s;
2475
+ y(r.field, `${n}.field`, i, {
2539
2476
  required: !0
2540
- }), o.scope !== void 0 && o.scope !== "row" && o.scope !== "aggregate" && i.push(
2541
- r(
2477
+ }), r.scope !== void 0 && r.scope !== "row" && r.scope !== "aggregate" && i.push(
2478
+ o(
2542
2479
  "invalid_analytics_filter_scope",
2543
2480
  "Analytics filter scope must be row or aggregate.",
2544
2481
  `${n}.scope`
2545
2482
  )
2546
- ), o.scope === "aggregate" && ((p = o.field) == null ? void 0 : p.role) !== void 0 && o.field.role !== "measure" && i.push(
2547
- r(
2483
+ ), r.scope === "aggregate" && ((c = r.field) == null ? void 0 : c.role) !== void 0 && r.field.role !== "measure" && i.push(
2484
+ o(
2548
2485
  "invalid_analytics_filter_scope",
2549
2486
  "Aggregate-scope analytics filters must target a measure field.",
2550
2487
  `${n}.scope`
2551
2488
  )
2552
2489
  );
2553
- const d = o.operator === "is_null" || o.operator === "is_not_null";
2554
- if (o.operator !== void 0 && o.operator !== "=" && o.operator !== "!=" && o.operator !== "in" && o.operator !== "not_in" && o.operator !== "contains" && o.operator !== "not_contains" && o.operator !== "between" && o.operator !== "not_between" && o.operator !== ">" && o.operator !== ">=" && o.operator !== "<" && o.operator !== "<=" && o.operator !== "is_null" && o.operator !== "is_not_null" && i.push(
2555
- r(
2490
+ const d = r.operator === "is_null" || r.operator === "is_not_null";
2491
+ if (r.operator !== void 0 && r.operator !== "=" && r.operator !== "!=" && r.operator !== "in" && r.operator !== "not_in" && r.operator !== "contains" && r.operator !== "not_contains" && r.operator !== "between" && r.operator !== "not_between" && r.operator !== ">" && r.operator !== ">=" && r.operator !== "<" && r.operator !== "<=" && r.operator !== "is_null" && r.operator !== "is_not_null" && i.push(
2492
+ o(
2556
2493
  "invalid_analytics_filter_operator",
2557
2494
  "Analytics filter operator is not supported.",
2558
2495
  `${n}.operator`
2559
2496
  )
2560
- ), o.values === void 0 && !d && i.push(
2561
- r(
2497
+ ), r.values === void 0 && !d && i.push(
2498
+ o(
2562
2499
  "missing_analytics_filter_value",
2563
2500
  "Analytics filter needs values unless it is a null check.",
2564
2501
  n
2565
2502
  )
2566
- ), d && o.values !== void 0) {
2503
+ ), d && r.values !== void 0) {
2567
2504
  i.push(
2568
- r(
2505
+ o(
2569
2506
  "invalid_analytics_filter_values",
2570
2507
  "Null-check analytics filters must not include values.",
2571
2508
  `${n}.values`
@@ -2573,9 +2510,9 @@ function ne(e, t, i) {
2573
2510
  );
2574
2511
  return;
2575
2512
  }
2576
- if (o.values !== void 0 && !Array.isArray(o.values)) {
2513
+ if (r.values !== void 0 && !Array.isArray(r.values)) {
2577
2514
  i.push(
2578
- r(
2515
+ o(
2579
2516
  "invalid_analytics_filter_values",
2580
2517
  "Analytics filter values must be an array when provided.",
2581
2518
  `${n}.values`
@@ -2583,11 +2520,11 @@ function ne(e, t, i) {
2583
2520
  );
2584
2521
  return;
2585
2522
  }
2586
- if (o.values !== void 0) {
2587
- const m = o.values.length;
2588
- if (o.operator === "between" || o.operator === "not_between") {
2589
- m !== 2 && i.push(
2590
- r(
2523
+ if (r.values !== void 0) {
2524
+ const p = r.values.length;
2525
+ if (r.operator === "between" || r.operator === "not_between") {
2526
+ p !== 2 && i.push(
2527
+ o(
2591
2528
  "invalid_analytics_filter_values",
2592
2529
  "Between analytics filters must include exactly two values.",
2593
2530
  `${n}.values`
@@ -2595,8 +2532,8 @@ function ne(e, t, i) {
2595
2532
  );
2596
2533
  return;
2597
2534
  }
2598
- (o.operator === "contains" || o.operator === "not_contains" || o.operator === "=" || o.operator === "!=" || o.operator === ">" || o.operator === ">=" || o.operator === "<" || o.operator === "<=" || o.operator === void 0) && m !== 1 && i.push(
2599
- r(
2535
+ (r.operator === "contains" || r.operator === "not_contains" || r.operator === "=" || r.operator === "!=" || r.operator === ">" || r.operator === ">=" || r.operator === "<" || r.operator === "<=" || r.operator === void 0) && p !== 1 && i.push(
2536
+ o(
2600
2537
  "invalid_analytics_filter_values",
2601
2538
  "Scalar analytics filters must include exactly one value. Use in/not_in for multiple values.",
2602
2539
  `${n}.values`
@@ -2606,71 +2543,14 @@ function ne(e, t, i) {
2606
2543
  });
2607
2544
  }
2608
2545
  }
2609
- function bn(e) {
2610
- const t = [];
2611
- if (!f(e))
2612
- return t.push(
2613
- r(
2614
- "invalid_result_calculation",
2615
- "Result calculation must be a structured object."
2616
- )
2617
- ), { ok: !1, errors: t, warnings: [] };
2618
- if (c(e.id) || t.push(
2619
- r(
2620
- "invalid_result_calculation_id",
2621
- "Result calculation needs an id.",
2622
- "id"
2623
- )
2624
- ), c(e.label) || t.push(
2625
- r(
2626
- "invalid_result_calculation_label",
2627
- "Result calculation needs a label.",
2628
- "label"
2629
- )
2630
- ), e.kind !== "percent_of_total" && e.kind !== "rank" && e.kind !== "running_total" && e.kind !== "previous_row_delta" && t.push(
2631
- r(
2632
- "invalid_result_calculation_kind",
2633
- "Result calculation kind must be percent_of_total, rank, running_total, or previous_row_delta.",
2634
- "kind"
2635
- )
2636
- ), Ce(e.input, "input", t), ya(e.output, "output", t), e.kind === "percent_of_total") {
2637
- const i = e.denominator;
2638
- i !== void 0 && (f(i) ? i.scope === "population" ? (_(i.metric, "denominator.metric", t, {
2639
- required: !0
2640
- }), ne(
2641
- i.filters,
2642
- "denominator.filters",
2643
- t
2644
- )) : i.scope !== "returned_result" && t.push(
2645
- r(
2646
- "invalid_result_calculation_denominator",
2647
- "Percent-of-total denominator scope must be returned_result or population.",
2648
- "denominator.scope"
2649
- )
2650
- ) : t.push(
2651
- r(
2652
- "invalid_result_calculation_denominator",
2653
- "Percent-of-total denominator must be a structured object.",
2654
- "denominator"
2655
- )
2656
- ));
2657
- }
2658
- return e.kind === "rank" && e.order !== void 0 && e.order !== "asc" && e.order !== "desc" && t.push(
2659
- r(
2660
- "invalid_result_calculation_order",
2661
- "Rank result calculation order must be asc or desc.",
2662
- "order"
2663
- )
2664
- ), (e.kind === "running_total" || e.kind === "previous_row_delta") && e.orderBy !== void 0 && Ce(e.orderBy, "orderBy", t), { ok: t.length === 0, errors: t, warnings: [] };
2665
- }
2666
- function bt(e) {
2546
+ function ht(e) {
2667
2547
  var s;
2668
2548
  const t = [], i = [];
2669
2549
  if (!e || typeof e != "object")
2670
2550
  return {
2671
2551
  ok: !1,
2672
2552
  errors: [
2673
- r(
2553
+ o(
2674
2554
  "invalid_analytics_intent",
2675
2555
  "Analytics intent must be a structured object."
2676
2556
  )
@@ -2685,126 +2565,126 @@ function bt(e) {
2685
2565
  };
2686
2566
  if (e.kind === "matrix") {
2687
2567
  const l = Pi.safeParse(e);
2688
- return l.success || t.push(...l.error.issues.map((n) => r("invalid_matrix_intent", n.message, n.path.join(".")))), { ok: t.length === 0, errors: t, warnings: i, repairHints: $e(t) };
2568
+ return l.success || t.push(...l.error.issues.map((n) => o("invalid_matrix_intent", n.message, n.path.join(".")))), { ok: t.length === 0, errors: t, warnings: i, repairHints: Ce(t) };
2689
2569
  }
2690
2570
  if (e.version !== void 0 && e.version !== 1 && t.push(
2691
- r(
2571
+ o(
2692
2572
  "invalid_version",
2693
2573
  "Analytics intent version must be 1.",
2694
2574
  "version"
2695
2575
  )
2696
- ), se(e.source, "source", t), wa(e, t), pa(e, t), "relationshipHint" in e && e.relationshipHint !== void 0 && ye(
2576
+ ), ne(e.source, "source", t), Sa(e, t), pa(e, t), "relationshipHint" in e && e.relationshipHint !== void 0 && _e(
2697
2577
  e.relationshipHint,
2698
2578
  "relationshipHint",
2699
2579
  t
2700
2580
  ), e.kind === "metric") {
2701
2581
  const l = Array.isArray(e.measures) ? e.measures.filter(
2702
- (n) => f(n) && c(n.name)
2582
+ (n) => f(n) && m(n.name)
2703
2583
  ) : [];
2704
2584
  if (!Array.isArray(e.measures) || e.measures.length === 0 ? t.push(
2705
- r(
2585
+ o(
2706
2586
  "missing_measure",
2707
2587
  "Metric intent needs at least one measure.",
2708
2588
  "measures"
2709
2589
  )
2710
2590
  ) : e.measures.some(
2711
- (n) => !f(n) || !c(n.name)
2591
+ (n) => !f(n) || !m(n.name)
2712
2592
  ) && t.push(
2713
- r(
2593
+ o(
2714
2594
  "invalid_measure_list",
2715
2595
  "Metric intent measures must be an array of field references with names.",
2716
2596
  "measures"
2717
2597
  )
2718
- ), l.forEach((n, o) => {
2719
- _(n, `measures.${o}`, t, {
2598
+ ), l.forEach((n, r) => {
2599
+ y(n, `measures.${r}`, t, {
2720
2600
  required: !0
2721
2601
  });
2722
2602
  }), l.length > 0 && !ea(l)) {
2723
2603
  const n = l.find(
2724
- (o, d) => l.some(
2725
- (p, m) => m !== d && _t(p, o)
2604
+ (r, d) => l.some(
2605
+ (c, p) => p !== d && ft(c, r)
2726
2606
  )
2727
2607
  );
2728
2608
  n && t.push(
2729
- r(
2609
+ o(
2730
2610
  "duplicate_measure",
2731
2611
  ta(n),
2732
2612
  "measures"
2733
2613
  )
2734
2614
  );
2735
2615
  }
2736
- if (f(e.primaryMeasure) && c(e.primaryMeasure.name) && _e(
2616
+ if (f(e.primaryMeasure) && m(e.primaryMeasure.name) && he(
2737
2617
  e.primaryMeasure,
2738
2618
  l
2739
2619
  ).length > 1 && t.push(
2740
- r(
2620
+ o(
2741
2621
  "ambiguous_primary_measure",
2742
2622
  "Metric intent primaryMeasure must identify exactly one selected measure.",
2743
2623
  "primaryMeasure"
2744
2624
  )
2745
- ), e.primaryMeasure !== void 0 && (_(e.primaryMeasure, "primaryMeasure", t, {
2625
+ ), e.primaryMeasure !== void 0 && (y(e.primaryMeasure, "primaryMeasure", t, {
2746
2626
  required: !0
2747
- }), f(e.primaryMeasure) && c(e.primaryMeasure.name) && l.length > 0 && !aa(
2627
+ }), f(e.primaryMeasure) && m(e.primaryMeasure.name) && l.length > 0 && !aa(
2748
2628
  e.primaryMeasure,
2749
2629
  l
2750
2630
  ) && t.push(
2751
- r(
2631
+ o(
2752
2632
  "invalid_primary_measure",
2753
2633
  "Metric intent primaryMeasure must match one measure field reference.",
2754
2634
  "primaryMeasure"
2755
2635
  )
2756
2636
  )), e.dimensions !== void 0 && !Array.isArray(e.dimensions) ? t.push(
2757
- r(
2637
+ o(
2758
2638
  "invalid_measure_dimensions",
2759
2639
  "Metric intent dimensions must be an array of field references.",
2760
2640
  "dimensions"
2761
2641
  )
2762
2642
  ) : Array.isArray(e.dimensions) && e.dimensions.some(
2763
- (n) => !f(n) || !c(n.name)
2643
+ (n) => !f(n) || !m(n.name)
2764
2644
  ) && t.push(
2765
- r(
2645
+ o(
2766
2646
  "invalid_measure_dimensions",
2767
2647
  "Metric intent dimensions must be an array of field references with names.",
2768
2648
  "dimensions"
2769
2649
  )
2770
- ), e.dateField !== void 0 && _(e.dateField, "dateField", t), e.timeWindow !== void 0 && (ae(e.timeWindow, "timeWindow", t), e.dateField || t.push(
2771
- r(
2650
+ ), e.dateField !== void 0 && y(e.dateField, "dateField", t), e.timeWindow !== void 0 && (ae(e.timeWindow, "timeWindow", t), e.dateField || t.push(
2651
+ o(
2772
2652
  "missing_time_window_date_field",
2773
2653
  "Metric timeWindow needs a dateField.",
2774
2654
  "dateField"
2775
2655
  )
2776
- )), ne(e.filters, "filters", t), Array.isArray(e.dimensions) && e.dimensions.forEach((n, o) => {
2777
- _(n, `dimensions.${o}`, t);
2656
+ )), Re(e.filters, "filters", t), Array.isArray(e.dimensions) && e.dimensions.forEach((n, r) => {
2657
+ y(n, `dimensions.${r}`, t);
2778
2658
  }), e.orderBy !== void 0) {
2779
2659
  if (!f(e.orderBy))
2780
2660
  t.push(
2781
- r(
2661
+ o(
2782
2662
  "invalid_measure_order_by",
2783
2663
  "Metric intent orderBy must be a structured object.",
2784
2664
  "orderBy"
2785
2665
  )
2786
2666
  );
2787
- else if (_(e.orderBy.field, "orderBy.field", t, {
2667
+ else if (y(e.orderBy.field, "orderBy.field", t, {
2788
2668
  required: !0
2789
2669
  }), e.orderBy.direction !== "asc" && e.orderBy.direction !== "desc" && t.push(
2790
- r(
2670
+ o(
2791
2671
  "invalid_measure_order_direction",
2792
2672
  "Metric intent orderBy direction must be asc or desc.",
2793
2673
  "orderBy.direction"
2794
2674
  )
2795
- ), f(e.orderBy.field) && c(e.orderBy.field.name)) {
2675
+ ), f(e.orderBy.field) && m(e.orderBy.field.name)) {
2796
2676
  const n = [
2797
2677
  ...l,
2798
2678
  ...e.timeGrain && e.dateField && f(e.dateField) ? [e.dateField] : [],
2799
2679
  ...Array.isArray(e.dimensions) ? e.dimensions.filter(
2800
- (o) => f(o) && c(o.name)
2680
+ (r) => f(r) && m(r.name)
2801
2681
  ) : []
2802
2682
  ];
2803
2683
  n.length > 0 && !na(
2804
2684
  e.orderBy.field,
2805
2685
  n
2806
2686
  ) && t.push(
2807
- r(
2687
+ o(
2808
2688
  "invalid_measure_order_by",
2809
2689
  "Metric intent orderBy.field must match one selected measure, grouped dateField, or dimension.",
2810
2690
  "orderBy.field"
@@ -2812,48 +2692,48 @@ function bt(e) {
2812
2692
  );
2813
2693
  }
2814
2694
  }
2815
- ba(e, t);
2695
+ _a(e, t);
2816
2696
  } else if (e.kind === "records") {
2817
2697
  if (!Array.isArray(e.fields) || e.fields.length === 0 ? t.push(
2818
- r(
2698
+ o(
2819
2699
  "missing_record_fields",
2820
2700
  "Records intent needs at least one field.",
2821
2701
  "fields"
2822
2702
  )
2823
2703
  ) : e.fields.some(
2824
- (l) => !f(l) || !c(l.name)
2704
+ (l) => !f(l) || !m(l.name)
2825
2705
  ) && t.push(
2826
- r(
2706
+ o(
2827
2707
  "invalid_record_fields",
2828
2708
  "Records intent fields must be field references with names.",
2829
2709
  "fields"
2830
2710
  )
2831
2711
  ), Array.isArray(e.fields) && e.fields.forEach((l, n) => {
2832
- _(l, `fields.${n}`, t);
2833
- }), e.dateField !== void 0 && _(e.dateField, "dateField", t), Ne(e.pagination, "pagination", t), e.timeWindow !== void 0 && (ae(e.timeWindow, "timeWindow", t), e.dateField || t.push(
2834
- r(
2712
+ y(l, `fields.${n}`, t);
2713
+ }), e.dateField !== void 0 && y(e.dateField, "dateField", t), Ne(e.pagination, "pagination", t), e.timeWindow !== void 0 && (ae(e.timeWindow, "timeWindow", t), e.dateField || t.push(
2714
+ o(
2835
2715
  "missing_time_window_date_field",
2836
2716
  "Records timeWindow needs a dateField.",
2837
2717
  "dateField"
2838
2718
  )
2839
- )), ne(e.filters, "filters", t), Array.isArray(e.filters) && e.filters.forEach((l, n) => {
2719
+ )), Re(e.filters, "filters", t), Array.isArray(e.filters) && e.filters.forEach((l, n) => {
2840
2720
  f(l) && l.scope === "aggregate" && t.push(
2841
- r(
2721
+ o(
2842
2722
  "unsupported_record_filter_scope",
2843
2723
  "Records intents support row-scope filters only. Use a metric intent for aggregate-scope filters.",
2844
2724
  `filters.${n}.scope`
2845
2725
  )
2846
2726
  );
2847
- }), e.orderBy !== void 0 && (f(e.orderBy) ? (_(e.orderBy.field, "orderBy.field", t, {
2727
+ }), e.orderBy !== void 0 && (f(e.orderBy) ? (y(e.orderBy.field, "orderBy.field", t, {
2848
2728
  required: !0
2849
2729
  }), e.orderBy.direction !== "asc" && e.orderBy.direction !== "desc" && t.push(
2850
- r(
2730
+ o(
2851
2731
  "invalid_record_order_direction",
2852
2732
  "Records intent orderBy direction must be asc or desc.",
2853
2733
  "orderBy.direction"
2854
2734
  )
2855
2735
  )) : t.push(
2856
- r(
2736
+ o(
2857
2737
  "invalid_record_order_by",
2858
2738
  "Records intent orderBy must be a structured object.",
2859
2739
  "orderBy"
@@ -2861,7 +2741,7 @@ function bt(e) {
2861
2741
  )), e.totals !== void 0)
2862
2742
  if (!f(e.totals))
2863
2743
  t.push(
2864
- r(
2744
+ o(
2865
2745
  "invalid_records_totals",
2866
2746
  "Records totals must be a structured server totals request.",
2867
2747
  "totals"
@@ -2869,7 +2749,7 @@ function bt(e) {
2869
2749
  );
2870
2750
  else {
2871
2751
  e.totals.mode !== "server" && t.push(
2872
- r(
2752
+ o(
2873
2753
  "invalid_records_totals",
2874
2754
  "Records totals mode must be server.",
2875
2755
  "totals.mode"
@@ -2877,39 +2757,39 @@ function bt(e) {
2877
2757
  );
2878
2758
  const l = e.totals.measures;
2879
2759
  !Array.isArray(l) || l.length === 0 ? t.push(
2880
- r(
2760
+ o(
2881
2761
  "missing_records_totals_measures",
2882
2762
  "Records server totals need at least one measure.",
2883
2763
  "totals.measures"
2884
2764
  )
2885
- ) : l.forEach((n, o) => {
2886
- _(n, `totals.measures.${o}`, t, {
2765
+ ) : l.forEach((n, r) => {
2766
+ y(n, `totals.measures.${r}`, t, {
2887
2767
  required: !0
2888
2768
  }), (!f(n) || n.role !== "measure") && t.push(
2889
- r(
2769
+ o(
2890
2770
  "invalid_records_totals_measure",
2891
2771
  "Records server totals measures must be measure field references.",
2892
- `totals.measures.${o}.role`
2772
+ `totals.measures.${r}.role`
2893
2773
  )
2894
2774
  );
2895
2775
  });
2896
2776
  }
2897
2777
  } else e.kind === "inputOptions" ? ca(e, t) : e.kind === "sql" ? (((s = e.source) == null ? void 0 : s.kind) !== "sql" && t.push(
2898
- r(
2778
+ o(
2899
2779
  "invalid_sql_source",
2900
2780
  "SQL analytics intent must use a SQL execution source.",
2901
2781
  "source"
2902
2782
  )
2903
- ), c(e.sql) || t.push(
2904
- r("missing_sql", "SQL analytics intent needs SQL text.", "sql")
2783
+ ), m(e.sql) || t.push(
2784
+ o("missing_sql", "SQL analytics intent needs SQL text.", "sql")
2905
2785
  ), ia(
2906
2786
  e.defaultParameters,
2907
2787
  "defaultParameters",
2908
2788
  t
2909
2789
  ), Array.isArray(e.fields) && e.fields.forEach((l, n) => {
2910
- _(l, `fields.${n}`, t);
2790
+ y(l, `fields.${n}`, t);
2911
2791
  }), Ne(e.pagination, "pagination", t)) : t.push(
2912
- r(
2792
+ o(
2913
2793
  "invalid_analytics_kind",
2914
2794
  "Analytics kind is not supported.",
2915
2795
  "kind"
@@ -2919,14 +2799,14 @@ function bt(e) {
2919
2799
  ok: t.length === 0,
2920
2800
  errors: t,
2921
2801
  warnings: i,
2922
- repairHints: $e(t)
2802
+ repairHints: Ce(t)
2923
2803
  };
2924
2804
  }
2925
- function wa(e, t) {
2805
+ function Sa(e, t) {
2926
2806
  if (!(!("derivedFields" in e) || e.derivedFields === void 0)) {
2927
2807
  if (!Array.isArray(e.derivedFields)) {
2928
2808
  t.push(
2929
- r(
2809
+ o(
2930
2810
  "invalid_derived_fields",
2931
2811
  "Analytics intent derivedFields must be an array of derived field definitions.",
2932
2812
  "derivedFields"
@@ -2935,7 +2815,7 @@ function wa(e, t) {
2935
2815
  return;
2936
2816
  }
2937
2817
  e.derivedFields.forEach((i, s) => {
2938
- oe(
2818
+ re(
2939
2819
  i
2940
2820
  ).errors.forEach((n) => {
2941
2821
  t.push({
@@ -2952,7 +2832,7 @@ function Aa(e) {
2952
2832
  return {
2953
2833
  ok: !1,
2954
2834
  errors: [
2955
- r(
2835
+ o(
2956
2836
  "invalid_operation_intent",
2957
2837
  "Operation intent must be a structured object."
2958
2838
  )
@@ -2966,27 +2846,27 @@ function Aa(e) {
2966
2846
  ]
2967
2847
  };
2968
2848
  if (e.version !== 1 && t.push(
2969
- r(
2849
+ o(
2970
2850
  "invalid_version",
2971
2851
  "Operation intent version must be 1.",
2972
2852
  "version"
2973
2853
  )
2974
2854
  ), e.kind === "answer_obligations")
2975
2855
  !Array.isArray(e.obligations) || e.obligations.length === 0 ? t.push(
2976
- r(
2856
+ o(
2977
2857
  "missing_obligations",
2978
2858
  "Answer-obligations operation intent needs at least one obligation.",
2979
2859
  "obligations"
2980
2860
  )
2981
2861
  ) : e.obligations.forEach((s, l) => {
2982
- c(s.id) || t.push(
2983
- r(
2862
+ m(s.id) || t.push(
2863
+ o(
2984
2864
  "missing_obligation_id",
2985
2865
  "Each analytics obligation needs an id.",
2986
2866
  `obligations.${l}.id`
2987
2867
  )
2988
- ), c(s.prompt) || t.push(
2989
- r(
2868
+ ), m(s.prompt) || t.push(
2869
+ o(
2990
2870
  "missing_obligation_prompt",
2991
2871
  "Each analytics obligation needs a prompt.",
2992
2872
  `obligations.${l}.prompt`
@@ -2994,21 +2874,21 @@ function Aa(e) {
2994
2874
  );
2995
2875
  });
2996
2876
  else if (e.kind === "dashboard_change") {
2997
- if (c(e.instruction) || t.push(
2998
- r(
2877
+ if (m(e.instruction) || t.push(
2878
+ o(
2999
2879
  "missing_instruction",
3000
2880
  "Change operation intent needs an instruction.",
3001
2881
  "instruction"
3002
2882
  )
3003
2883
  ), e.analyticsIntent) {
3004
- const s = bt(
2884
+ const s = ht(
3005
2885
  e.analyticsIntent
3006
2886
  );
3007
2887
  t.push(...s.errors), i.push(...s.warnings);
3008
2888
  }
3009
2889
  } else
3010
2890
  t.push(
3011
- r(
2891
+ o(
3012
2892
  "invalid_operation_kind",
3013
2893
  "Operation intent kind is not supported.",
3014
2894
  "kind"
@@ -3018,16 +2898,16 @@ function Aa(e) {
3018
2898
  ok: t.length === 0,
3019
2899
  errors: t,
3020
2900
  warnings: i,
3021
- repairHints: vt(t)
2901
+ repairHints: _t(t)
3022
2902
  };
3023
2903
  }
3024
- function vn(e) {
2904
+ function _n(e) {
3025
2905
  const t = [], i = [];
3026
2906
  if (!e || typeof e != "object")
3027
2907
  return {
3028
2908
  ok: !1,
3029
2909
  errors: [
3030
- r(
2910
+ o(
3031
2911
  "invalid_recovery_plan",
3032
2912
  "Analytics recovery plan must be a structured object."
3033
2913
  )
@@ -3041,9 +2921,9 @@ function vn(e) {
3041
2921
  ]
3042
2922
  };
3043
2923
  e.version !== 1 && t.push(
3044
- r("invalid_version", "Recovery plan version must be 1.", "version")
2924
+ o("invalid_version", "Recovery plan version must be 1.", "version")
3045
2925
  ), e.kind !== "analytics_recovery_plan" && t.push(
3046
- r(
2926
+ o(
3047
2927
  "invalid_recovery_plan_kind",
3048
2928
  "Recovery plan kind must be analytics_recovery_plan.",
3049
2929
  "kind"
@@ -3053,7 +2933,7 @@ function vn(e) {
3053
2933
  e.operationIntent
3054
2934
  );
3055
2935
  return t.push(...s.errors), i.push(...s.warnings), Array.isArray(e.plannedToolCalls) || t.push(
3056
- r(
2936
+ o(
3057
2937
  "invalid_planned_tool_calls",
3058
2938
  "Recovery plan plannedToolCalls must be an array.",
3059
2939
  "plannedToolCalls"
@@ -3062,16 +2942,16 @@ function vn(e) {
3062
2942
  ok: t.length === 0,
3063
2943
  errors: t,
3064
2944
  warnings: i,
3065
- repairHints: vt(t)
2945
+ repairHints: _t(t)
3066
2946
  };
3067
2947
  }
3068
- function vt(e) {
2948
+ function _t(e) {
3069
2949
  return e.map((t) => ({
3070
2950
  code: t.code,
3071
2951
  recommendedNextStep: t.code === "missing_obligations" ? "Normalize the user request into one or more typed analytics obligations before recovery planning." : "Correct the operation/recovery contract shape before planning execution."
3072
2952
  }));
3073
2953
  }
3074
- function $e(e) {
2954
+ function Ce(e) {
3075
2955
  return e.map((t) => {
3076
2956
  switch (t.code) {
3077
2957
  case "invalid_matrix_intent":
@@ -3159,18 +3039,18 @@ function $e(e) {
3159
3039
  }
3160
3040
  }).filter((t) => !!t);
3161
3041
  }
3162
- function xa(e, t, i, s) {
3042
+ function wa(e, t, i, s) {
3163
3043
  if (!e || typeof e != "object") {
3164
3044
  i.push(
3165
- r("invalid_view", "Dashboard view must be an object.", t)
3045
+ o("invalid_view", "Dashboard view must be an object.", t)
3166
3046
  );
3167
3047
  return;
3168
3048
  }
3169
- if (c(e.title) || i.push(
3170
- r("missing_view_title", "Dashboard view needs a title.", t)
3049
+ if (m(e.title) || i.push(
3050
+ o("missing_view_title", "Dashboard view needs a title.", t)
3171
3051
  ), !e.presentation || typeof e.presentation != "object") {
3172
3052
  i.push(
3173
- r(
3053
+ o(
3174
3054
  "missing_presentation",
3175
3055
  "Dashboard view needs a presentation.",
3176
3056
  `${t}.presentation`
@@ -3179,8 +3059,8 @@ function xa(e, t, i, s) {
3179
3059
  return;
3180
3060
  }
3181
3061
  if (e.presentation.kind === "text") {
3182
- c(e.text) || s.push(
3183
- r(
3062
+ m(e.text) || s.push(
3063
+ o(
3184
3064
  "missing_text_content",
3185
3065
  "Text views should include text content.",
3186
3066
  `${t}.text`
@@ -3190,7 +3070,7 @@ function xa(e, t, i, s) {
3190
3070
  }
3191
3071
  if (!e.analytics) {
3192
3072
  i.push(
3193
- r(
3073
+ o(
3194
3074
  "missing_view_analytics",
3195
3075
  "Non-text dashboard views need analytics intent.",
3196
3076
  `${t}.analytics`
@@ -3199,16 +3079,16 @@ function xa(e, t, i, s) {
3199
3079
  return;
3200
3080
  }
3201
3081
  e.presentation.kind === "matrixTable" && e.analytics.kind !== "matrix" && i.push(
3202
- r(
3082
+ o(
3203
3083
  "invalid_matrix_view_analytics",
3204
3084
  "Matrix table views need matrix analytics intent.",
3205
3085
  `${t}.analytics.kind`
3206
3086
  )
3207
3087
  );
3208
- const l = bt(e.analytics);
3088
+ const l = ht(e.analytics);
3209
3089
  for (const n of l.errors)
3210
3090
  i.push(
3211
- r(
3091
+ o(
3212
3092
  n.code,
3213
3093
  n.message,
3214
3094
  `${t}.analytics${n.path ? `.${n.path}` : ""}`
@@ -3216,20 +3096,20 @@ function xa(e, t, i, s) {
3216
3096
  );
3217
3097
  for (const n of l.warnings)
3218
3098
  s.push(
3219
- r(
3099
+ o(
3220
3100
  n.code,
3221
3101
  n.message,
3222
3102
  `${t}.analytics${n.path ? `.${n.path}` : ""}`
3223
3103
  )
3224
3104
  );
3225
3105
  }
3226
- function In(e) {
3106
+ function yn(e) {
3227
3107
  const t = [], i = [];
3228
3108
  if (!e || typeof e != "object")
3229
3109
  return {
3230
3110
  ok: !1,
3231
3111
  errors: [
3232
- r(
3112
+ o(
3233
3113
  "invalid_dashboard_intent",
3234
3114
  "Dashboard intent must be a structured object."
3235
3115
  )
@@ -3237,61 +3117,61 @@ function In(e) {
3237
3117
  warnings: i
3238
3118
  };
3239
3119
  e.version !== 1 && t.push(
3240
- r("invalid_version", "Dashboard intent version must be 1.")
3120
+ o("invalid_version", "Dashboard intent version must be 1.")
3241
3121
  ), e.kind !== "dashboard" && t.push(
3242
- r("invalid_kind", "Experience intent kind must be dashboard.")
3243
- ), c(e.title) || t.push(
3244
- r("missing_title", "Dashboard intent needs a title.", "title")
3122
+ o("invalid_kind", "Experience intent kind must be dashboard.")
3123
+ ), m(e.title) || t.push(
3124
+ o("missing_title", "Dashboard intent needs a title.", "title")
3245
3125
  );
3246
- const s = Array.isArray(e.inputs) ? e.inputs : [], l = Re(
3247
- s.filter(f).map((p) => p.id).filter((p) => typeof p == "string")
3126
+ const s = Array.isArray(e.inputs) ? e.inputs : [], l = Te(
3127
+ s.filter(f).map((c) => c.id).filter((c) => typeof c == "string")
3248
3128
  );
3249
3129
  l && t.push(
3250
- r(
3130
+ o(
3251
3131
  "duplicate_input_id",
3252
3132
  `Duplicate input id: ${l}.`,
3253
3133
  "inputs"
3254
3134
  )
3255
3135
  );
3256
- for (const [p, m] of s.entries()) {
3257
- const u = `inputs.${p}`;
3258
- if (!f(m)) {
3136
+ for (const [c, p] of s.entries()) {
3137
+ const u = `inputs.${c}`;
3138
+ if (!f(p)) {
3259
3139
  t.push(
3260
- r("invalid_input", "Dashboard input must be an object.", u)
3140
+ o("invalid_input", "Dashboard input must be an object.", u)
3261
3141
  );
3262
3142
  continue;
3263
3143
  }
3264
- c(m.id) || t.push(
3265
- r("missing_input_id", "Input needs an id.", `${u}.id`)
3266
- ), c(m.label) || t.push(
3267
- r("missing_input_label", "Input needs a label.", `${u}.label`)
3268
- ), !m.field || !c(m.field.name) ? t.push(
3269
- r("missing_input_field", "Input needs a field.", `${u}.field`)
3270
- ) : _(m.field, `${u}.field`, t);
3144
+ m(p.id) || t.push(
3145
+ o("missing_input_id", "Input needs an id.", `${u}.id`)
3146
+ ), m(p.label) || t.push(
3147
+ o("missing_input_label", "Input needs a label.", `${u}.label`)
3148
+ ), !p.field || !m(p.field.name) ? t.push(
3149
+ o("missing_input_field", "Input needs a field.", `${u}.field`)
3150
+ ) : y(p.field, `${u}.field`, t);
3271
3151
  }
3272
3152
  const n = Array.isArray(e.sections) ? e.sections : [];
3273
3153
  n.length === 0 && t.push(
3274
- r(
3154
+ o(
3275
3155
  "missing_sections",
3276
3156
  "Dashboard intent needs at least one section.",
3277
3157
  "sections"
3278
3158
  )
3279
3159
  );
3280
- const o = n.flatMap(
3281
- (p) => p && typeof p == "object" && Array.isArray(p.views) ? p.views.filter(f).map((m) => m.id).filter((m) => !!m) : []
3282
- ), d = Re(o);
3160
+ const r = n.flatMap(
3161
+ (c) => c && typeof c == "object" && Array.isArray(c.views) ? c.views.filter(f).map((p) => p.id).filter((p) => !!p) : []
3162
+ ), d = Te(r);
3283
3163
  d && t.push(
3284
- r(
3164
+ o(
3285
3165
  "duplicate_view_id",
3286
3166
  `Duplicate dashboard view id: ${d}.`,
3287
3167
  "sections"
3288
3168
  )
3289
3169
  );
3290
- for (const [p, m] of n.entries()) {
3291
- const u = `sections.${p}`;
3292
- if (!m || typeof m != "object") {
3170
+ for (const [c, p] of n.entries()) {
3171
+ const u = `sections.${c}`;
3172
+ if (!p || typeof p != "object") {
3293
3173
  t.push(
3294
- r(
3174
+ o(
3295
3175
  "invalid_section",
3296
3176
  "Dashboard section must be an object.",
3297
3177
  u
@@ -3299,15 +3179,15 @@ function In(e) {
3299
3179
  );
3300
3180
  continue;
3301
3181
  }
3302
- if (c(m.title) || t.push(
3303
- r(
3182
+ if (m(p.title) || t.push(
3183
+ o(
3304
3184
  "missing_section_title",
3305
3185
  "Dashboard section needs a title.",
3306
3186
  u
3307
3187
  )
3308
- ), !Array.isArray(m.views) || m.views.length === 0) {
3188
+ ), !Array.isArray(p.views) || p.views.length === 0) {
3309
3189
  t.push(
3310
- r(
3190
+ o(
3311
3191
  "missing_section_views",
3312
3192
  "Dashboard section needs at least one view.",
3313
3193
  `${u}.views`
@@ -3315,9 +3195,9 @@ function In(e) {
3315
3195
  );
3316
3196
  continue;
3317
3197
  }
3318
- for (const [g, y] of m.views.entries())
3319
- xa(
3320
- y,
3198
+ for (const [g, _] of p.views.entries())
3199
+ wa(
3200
+ _,
3321
3201
  `${u}.views.${g}`,
3322
3202
  t,
3323
3203
  i
@@ -3326,128 +3206,127 @@ function In(e) {
3326
3206
  return { ok: t.length === 0, errors: t, warnings: i };
3327
3207
  }
3328
3208
  export {
3329
- ge as $,
3209
+ $i as $,
3330
3210
  mi as A,
3331
- Xa as B,
3211
+ Qa as B,
3332
3212
  Z as C,
3333
3213
  di as D,
3334
- mn as E,
3335
- Ja as F,
3336
- fn as G,
3337
- te as H,
3338
- st as I,
3339
- La as J,
3340
- me as K,
3214
+ cn as E,
3215
+ Xa as F,
3216
+ de as G,
3217
+ ue as H,
3218
+ ge as I,
3219
+ ht as J,
3220
+ un as K,
3341
3221
  oi as L,
3342
- Di as M,
3343
- rt as N,
3344
- ee as O,
3345
- ot as P,
3346
- ri as Q,
3347
- A as R,
3348
- Ba as S,
3349
- Ni as T,
3350
- lt as U,
3351
- Ci as V,
3352
- $i as W,
3353
- ut as X,
3354
- j as Y,
3355
- xe as Z,
3356
- qi as _,
3357
- gt as a,
3358
- Ya as a$,
3359
- De as a0,
3360
- H as a1,
3361
- Ui as a2,
3362
- dn as a3,
3363
- cn as a4,
3364
- le as a5,
3365
- Mt as a6,
3366
- Et as a7,
3367
- ie as a8,
3368
- ma as a9,
3222
+ pn as M,
3223
+ te as N,
3224
+ it as O,
3225
+ Pa as P,
3226
+ pe as Q,
3227
+ Di as R,
3228
+ at as S,
3229
+ ee as T,
3230
+ nt as U,
3231
+ ri as V,
3232
+ k as W,
3233
+ qa as X,
3234
+ Ti as Y,
3235
+ st as Z,
3236
+ Ci as _,
3237
+ pt as a,
3238
+ Ca as a$,
3239
+ ot as a0,
3240
+ j as a1,
3241
+ ke as a2,
3242
+ qi as a3,
3243
+ fe as a4,
3244
+ Fe as a5,
3245
+ H as a6,
3246
+ Ui as a7,
3247
+ on as a8,
3248
+ dn as a9,
3369
3249
  F as aA,
3370
- mt as aB,
3371
- he as aC,
3372
- ft as aD,
3373
- hn as aE,
3374
- bi as aF,
3375
- Ii as aG,
3376
- Tt as aH,
3377
- Ma as aI,
3250
+ ut as aB,
3251
+ ct as aC,
3252
+ fn as aD,
3253
+ bi as aE,
3254
+ Ii as aF,
3255
+ Mt as aG,
3256
+ Fa as aH,
3257
+ Et as aI,
3378
3258
  Nt as aJ,
3379
- Rt as aK,
3380
- Ea as aL,
3381
- Ct as aM,
3382
- M as aN,
3383
- $t as aO,
3384
- Ta as aP,
3385
- Yt as aQ,
3386
- Na as aR,
3387
- Ot as aS,
3388
- Ge as aT,
3389
- ni as aU,
3390
- si as aV,
3391
- Pa as aW,
3392
- qa as aX,
3393
- R as aY,
3394
- $a as aZ,
3395
- L as a_,
3396
- bn as aa,
3397
- bt as ab,
3398
- Aa as ac,
3399
- vn as ad,
3400
- In as ae,
3401
- oe as af,
3402
- ue as ag,
3403
- Kt as ah,
3404
- Xt as ai,
3405
- ce as aj,
3406
- ti as ak,
3407
- ii as al,
3408
- He as am,
3409
- Ve as an,
3410
- Se as ao,
3411
- ze as ap,
3412
- Ra as aq,
3413
- Ca as ar,
3414
- Xe as as,
3415
- fe as at,
3416
- Wa as au,
3417
- en as av,
3418
- nn as aw,
3419
- sn as ax,
3420
- rn as ay,
3421
- pn as az,
3422
- Va as b,
3259
+ Da as aK,
3260
+ Tt as aL,
3261
+ M as aM,
3262
+ Rt as aN,
3263
+ Ma as aO,
3264
+ $t as aP,
3265
+ Ea as aQ,
3266
+ jt as aR,
3267
+ Ve as aS,
3268
+ ni as aT,
3269
+ si as aU,
3270
+ Ya as aV,
3271
+ Oa as aW,
3272
+ R as aX,
3273
+ Ra as aY,
3274
+ L as aZ,
3275
+ $a as a_,
3276
+ oe as aa,
3277
+ Ft as ab,
3278
+ Dt as ac,
3279
+ ie as ad,
3280
+ ma as ae,
3281
+ Aa as af,
3282
+ _n as ag,
3283
+ yn as ah,
3284
+ re as ai,
3285
+ Kt as aj,
3286
+ Xt as ak,
3287
+ ti as al,
3288
+ ii as am,
3289
+ qe as an,
3290
+ Le as ao,
3291
+ Ie as ap,
3292
+ He as aq,
3293
+ Na as ar,
3294
+ Ta as as,
3295
+ Ge as at,
3296
+ me as au,
3297
+ Za as av,
3298
+ Ja as aw,
3299
+ tn as ax,
3300
+ an as ay,
3301
+ nn as az,
3302
+ Ba as b,
3423
3303
  ja as b0,
3424
- Oa as b1,
3425
- Yi as b2,
3426
- de as b3,
3427
- qt as b4,
3428
- Ae as b5,
3304
+ Yi as b1,
3305
+ le as b2,
3306
+ Ot as b3,
3307
+ we as b4,
3429
3308
  ui as c,
3430
- Ke as d,
3431
- za as e,
3432
- Ga as f,
3309
+ ze as d,
3310
+ Va as e,
3311
+ Ua as f,
3433
3312
  li as g,
3434
- Qa as h,
3435
- Ha as i,
3436
- Ka as j,
3313
+ za as h,
3314
+ La as i,
3315
+ Ga as j,
3437
3316
  J as k,
3438
- un as l,
3317
+ ln as l,
3439
3318
  Pi as m,
3440
- Ua as n,
3319
+ Ha as n,
3441
3320
  Qi as o,
3442
- _n as p,
3443
- gn as q,
3444
- yn as r,
3321
+ gn as p,
3322
+ mn as q,
3323
+ hn as r,
3445
3324
  Ji as s,
3446
- Qe as t,
3447
- on as u,
3448
- ln as v,
3449
- tn as w,
3450
- an as x,
3451
- Za as y,
3325
+ Ue as t,
3326
+ sn as u,
3327
+ rn as v,
3328
+ Wa as w,
3329
+ en as x,
3330
+ Ka as y,
3452
3331
  ci as z
3453
3332
  };