react-semaphor 0.1.601 → 0.1.602

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 (75) hide show
  1. package/dist/analytics-protocol/index.js +9 -9
  2. package/dist/assistant-context/index.js +1 -1
  3. package/dist/brand-studio/index.js +7 -7
  4. package/dist/briefings/index.js +4 -4
  5. package/dist/chunks/{assistant-chat-BE0XXzZP.js → assistant-chat-BWF3GYip.js} +12 -12
  6. package/dist/chunks/{bookmark-impact-DXDAN5AY.js → bookmark-impact-BF3iRx5a.js} +3 -3
  7. package/dist/chunks/{bookmark-state-BMyB3Tb6.js → bookmark-state-CBSTdW6q.js} +4 -4
  8. package/dist/chunks/{card-filter-builder-CE0-YVN5.js → card-filter-builder-B8XHwMY6.js} +394 -394
  9. package/dist/chunks/{comparison-window-caption-Dxj2CHOa.js → comparison-window-caption-W83qB4V5.js} +4 -4
  10. package/dist/chunks/{dashboard-mJKPFRbb.js → dashboard-DG5EIYYB.js} +1 -1
  11. package/dist/chunks/{dashboard-briefing-launcher-CntwKyiZ.js → dashboard-briefing-launcher-CBSrhyWZ.js} +727 -718
  12. package/dist/chunks/{dashboard-controls-XO089DMg.js → dashboard-controls-D6ECO4N1.js} +15 -15
  13. package/dist/chunks/{dashboard-json-CQRiydUv.js → dashboard-json-DrJftBSL.js} +4 -4
  14. package/dist/chunks/{dates-B-Urp5OD.js → dates-Bz-qM5px.js} +10 -10
  15. package/dist/chunks/{edit-dashboard-visual-f-Dm-BLR.js → edit-dashboard-visual-BDYAJIbb.js} +1565 -1544
  16. package/dist/chunks/{filter-line-CKNMyNTQ.js → filter-line-BXT6y303.js} +6 -6
  17. package/dist/chunks/{filter-reach-copy-B8GGyVuR.js → filter-reach-copy-BukhZmzm.js} +1661 -1950
  18. package/dist/chunks/{filter-value-text-CRtKecI5.js → filter-value-text-D3-bf3_b.js} +4 -4
  19. package/dist/chunks/{index-DoPApnxg.js → index-BW0yozjs.js} +5 -5
  20. package/dist/chunks/{layout-grid-CiSCZdIr.js → layout-grid-Ds0diMeY.js} +1 -1
  21. package/dist/chunks/{matrix-analytical-definition-myf3D3Qx.js → matrix-analytical-definition-CgQgVeeI.js} +4 -4
  22. package/dist/chunks/{matrix-member-presentation-g0c_NpDW.js → matrix-member-presentation-DSBIIudt.js} +1 -1
  23. package/dist/chunks/{matrix-operation-contract-C1SuOHLZ.js → matrix-operation-contract--DkNCOzd.js} +517 -514
  24. package/dist/chunks/{metric-comparison-Cm0G893W.js → metric-comparison-zMylnIkc.js} +1 -1
  25. package/dist/chunks/{paintbrush-DQIwqlck.js → paintbrush-CX8pao1j.js} +1 -1
  26. package/dist/chunks/{palette-Cun747Rg.js → palette-CuA0HlzF.js} +1 -1
  27. package/dist/chunks/{pivot-result-contract-expectations-C1Dyx8du.js → pivot-result-contract-expectations-C8KL7hPx.js} +8 -8
  28. package/dist/chunks/{pivot-result-identity-CBS-ssEp.js → pivot-result-identity-C1AOH1PS.js} +1 -1
  29. package/dist/chunks/{raw-temporal-value-DN_l-Tss.js → raw-temporal-value-E416F-0L.js} +1 -1
  30. package/dist/chunks/{report-preferences-dialog-SDZEcG2x.js → report-preferences-dialog-CbuVNDGi.js} +13 -13
  31. package/dist/chunks/{report-runtime-context-BbedQdtc.js → report-runtime-context-E7USjN7E.js} +1 -1
  32. package/dist/chunks/{resolve-dashboard-input-context-DRBS0eRa.js → resolve-dashboard-input-context-CULCE_hM.js} +8417 -7052
  33. package/dist/chunks/{save-Dj5bjm7P.js → save-BKHlDONy.js} +1 -1
  34. package/dist/chunks/{saved-dashboard-context-DWVlJcsa.js → saved-dashboard-context-C1WlOx5z.js} +32 -32
  35. package/dist/chunks/{selection-filter-compiler-DmAr7yqC.js → selection-filter-compiler-ifT8JCXS.js} +1 -1
  36. package/dist/chunks/{semaphor-ready-indicator-OFOoAY-A.js → semaphor-ready-indicator-CBIRcDWs.js} +33414 -31523
  37. package/dist/chunks/{shelf-drop-preview-context-2swWypXu.js → shelf-drop-preview-context-xR69SMA8.js} +53 -53
  38. package/dist/chunks/{stored-dashboard-NtOuEX6a.js → stored-dashboard-BuM8vnWf.js} +739 -717
  39. package/dist/chunks/{style-sheet-parts-Qv4UcLAo.js → style-sheet-parts-Bt9ZNre8.js} +2 -2
  40. package/dist/chunks/{table-export-sheet-Do7ZB0_F.js → table-export-sheet-DVljtHkG.js} +1 -1
  41. package/dist/chunks/{token-types-Dy_aXO-U.js → token-types-D_xKgyVS.js} +1 -1
  42. package/dist/chunks/{upload-Bq-puSVy.js → upload-Dll_M7XQ.js} +1 -1
  43. package/dist/chunks/{validators-C7DFk3QK.js → validators-ClWHpYql.js} +2 -2
  44. package/dist/chunks/{variable-draft-Cy03qnEi.js → variable-draft-CDGGl53R.js} +27 -28
  45. package/dist/dashboard/index.js +2 -2
  46. package/dist/dashboard-authoring/index.js +3086 -2578
  47. package/dist/format-utils/index.js +14 -14
  48. package/dist/index.js +71 -73
  49. package/dist/report-runtime-context/index.js +1 -1
  50. package/dist/style.css +1 -1
  51. package/dist/surfboard/index.js +2 -2
  52. package/dist/types/components/dashboard/dashboard-web-component.d.ts +7 -0
  53. package/dist/types/index.js +5 -5
  54. package/dist/types/lib/dashboard-inputs/dashboard-input-target-context.d.ts +1 -1
  55. package/dist/types/lib/query-context/assemble-card-query.d.ts +6 -1
  56. package/dist/types/lib/stores/dashboard-store.d.ts +30 -0
  57. package/dist/types/shared/analytics-protocol/aggregate-expression.d.ts +15 -0
  58. package/dist/types/shared/dashboard-authoring/calculations/calculated-column.d.ts +52 -0
  59. package/dist/types/shared/dashboard-authoring/calculations/definition.d.ts +129 -0
  60. package/dist/types/shared/dashboard-authoring/calculations/resolve-dashboard-field-copies.d.ts +46 -0
  61. package/dist/types/shared/dashboard-authoring/calculations/tokens.d.ts +36 -0
  62. package/dist/types/shared/dashboard-authoring/changes/calculation-change.d.ts +399 -0
  63. package/dist/types/shared/dashboard-authoring/changes/dashboard-change.d.ts +144 -2
  64. package/dist/types/shared/dashboard-authoring/changes/diagnostics.d.ts +21 -2
  65. package/dist/types/shared/dashboard-authoring/changes/domain-change.d.ts +143 -266
  66. package/dist/types/shared/dashboard-authoring/changes/read-card-query.d.ts +2 -0
  67. package/dist/types/shared/dashboard-authoring/changes/resolve-dashboard-changes.d.ts +46 -0
  68. package/dist/types/shared/dashboard-authoring/index.d.ts +7 -1
  69. package/dist/types/shared/dashboard-authoring/operations/calculated-field-operations.d.ts +133 -0
  70. package/dist/types/shared/dashboard-authoring/operations/card-operations.d.ts +71 -0
  71. package/dist/types/shared/dashboard-authoring/operations/operation-types.d.ts +18 -5
  72. package/dist/types/shared/dashboard-authoring/outline/outline-dashboard.d.ts +21 -0
  73. package/dist/types/shared/usage-events/details.d.ts +2 -2
  74. package/dist/types/shared/usage-events/envelope.d.ts +2 -2
  75. package/package.json +1 -1
@@ -1,4 +1,4 @@
1
- import { c as a } from "./style-sheet-parts-Qv4UcLAo.js";
1
+ import { c as a } from "./style-sheet-parts-Bt9ZNre8.js";
2
2
  /**
3
3
  * @license lucide-react v0.453.0 - ISC
4
4
  *
@@ -1,19 +1,19 @@
1
1
  var Z = Object.defineProperty;
2
2
  var Q = (e, t, a) => t in e ? Z(e, t, { enumerable: !0, configurable: !0, writable: !0, value: a }) : e[t] = a;
3
3
  var F = (e, t, a) => Q(e, typeof t != "symbol" ? t + "" : t, a);
4
- import { D as S, F as U, G as K, H as W } from "./bookmark-state-BMyB3Tb6.js";
5
- import { s as X, k as Y, n as ee, m as te, o as ae, p as re, q as ne, t as se, u as oe, v as ie, w as j, x as de, y as le, z as ce } from "./resolve-dashboard-input-context-DRBS0eRa.js";
6
- import { c as ue, e as L, b as me, d as fe, p as q, f as he, g as pe, r as _, i as O, j as be, m as ge, k as Ce } from "./stored-dashboard-NtOuEX6a.js";
4
+ import { D as S, F as U, G as K, H as W } from "./bookmark-state-CBSTdW6q.js";
5
+ import { s as X, p as Y, q as ee, t as te, u as ae, v as re, w as ne, x as se, y as oe, z as ie, A as j, B as de, C as le, D as ce } from "./resolve-dashboard-input-context-CULCE_hM.js";
6
+ import { c as ue, e as L, b as me, d as fe, p as q, f as he, g as pe, r as D, i as O, j as be, m as ge, k as Ce } from "./stored-dashboard-BuM8vnWf.js";
7
7
  import { f as g, A as P, c as Ie, d as ye, e as M } from "./context-BJoEFgNl.js";
8
- import { a as ve, T as xe, P as Ve, o as I, d as B, b as w } from "./filter-value-text-CRtKecI5.js";
9
- import { k as Se, a9 as ke } from "./validators-C7DFk3QK.js";
10
- import { b as $e } from "./metric-comparison-Cm0G893W.js";
11
- import { i as qe } from "./matrix-analytical-definition-myf3D3Qx.js";
12
- function _e(e) {
8
+ import { a as ve, T as xe, P as Ve, o as I, d as B, b as _ } from "./filter-value-text-D3-bf3_b.js";
9
+ import { k as Se, a9 as $e } from "./validators-ClWHpYql.js";
10
+ import { b as ke } from "./metric-comparison-zMylnIkc.js";
11
+ import { i as qe } from "./matrix-analytical-definition-CgQgVeeI.js";
12
+ function De(e) {
13
13
  const t = e.qualifiedFieldName || e.name;
14
14
  return e.label && e.label !== t ? `${e.label} (field ${t})` : t;
15
15
  }
16
- function we(e, t = {}) {
16
+ function _e(e, t = {}) {
17
17
  if (!e) return [];
18
18
  const a = N(e, t);
19
19
  return a.length === 0 ? [] : e.logicalOperator === "AND" && !e.negate ? a : [z(e, a)];
@@ -25,7 +25,7 @@ function N(e, t) {
25
25
  const s = z(r, n);
26
26
  return [n.length > 1 && !r.negate ? { ...s, text: `(${s.text})` } : s];
27
27
  });
28
- return [...e.conditions.map((r) => De(r, t)), ...a];
28
+ return [...e.conditions.map((r) => we(r, t)), ...a];
29
29
  }
30
30
  function z(e, t) {
31
31
  const a = t.map((r) => r.text).join(e.logicalOperator === "OR" ? " or " : " and ");
@@ -34,10 +34,10 @@ function z(e, t) {
34
34
  omittedValues: t.reduce((r, n) => r + n.omittedValues, 0)
35
35
  };
36
36
  }
37
- function De(e, t) {
37
+ function we(e, t) {
38
38
  const a = Array.isArray(e.value) ? e.value : [e.value];
39
39
  return ve({
40
- subject: _e(e.field),
40
+ subject: De(e.field),
41
41
  operator: e.operator,
42
42
  values: a,
43
43
  reading: Fe(e),
@@ -47,7 +47,7 @@ function De(e, t) {
47
47
  }, t);
48
48
  }
49
49
  function Fe(e) {
50
- return e.temporalBucket ? { kind: "bucket", bucket: e.temporalBucket } : ke(e.field.dataType) ? xe : Ve;
50
+ return e.temporalBucket ? { kind: "bucket", bucket: e.temporalBucket } : $e(e.field.dataType) ? xe : Ve;
51
51
  }
52
52
  function H(e) {
53
53
  if (e.kind === "target") return `a target of ${e.targetValue}`;
@@ -64,7 +64,7 @@ function Ae(e, t) {
64
64
  const a = t.source === "explicit" ? "set on the measure" : `from the dashboard date comparison on ${Me(t.owner)}`;
65
65
  return `${e} is compared with ${H(t.spec)} (${a})`;
66
66
  }
67
- function $(e) {
67
+ function k(e) {
68
68
  const t = X(e) ?? "undefined";
69
69
  return `${A(t, 2654435769).toString(16)}${A(t, 2246822507).toString(16)}`;
70
70
  }
@@ -81,11 +81,11 @@ function Re(e, t, a) {
81
81
  var y;
82
82
  const r = t !== "pending" && (t == null ? void 0 : t.status) === "ready" ? t : void 0, n = Te(e, t);
83
83
  if (n) {
84
- const v = t !== "pending" && (t == null ? void 0 : t.status) === "blocked" ? Ee(t) : void 0, k = v ? g(v, h.textChars) : void 0;
84
+ const v = t !== "pending" && (t == null ? void 0 : t.status) === "blocked" ? Ee(t) : void 0, $ = v ? g(v, h.textChars) : void 0;
85
85
  return {
86
86
  // A card that runs but is not described still changes when it runs differently.
87
- fingerprint: $(r ? R(r, a.calendar) : { reason: n, message: k }),
88
- description: { status: "not_described", reason: n, ...k ? { message: k } : {} }
87
+ fingerprint: k(r ? R(r, a.calendar) : { reason: n, message: $ }),
88
+ description: { status: "not_described", reason: n, ...$ ? { message: $ } : {} }
89
89
  };
90
90
  }
91
91
  const s = r, l = s.queryContext, m = Le(s), o = Be(s, a), c = ze(s), i = Oe(s), u = l.drillSteps.map((v) => g(
@@ -100,7 +100,7 @@ function Re(e, t, a) {
100
100
  comparisons: I(i.length, h.cardFields)
101
101
  }, p = Object.fromEntries(Object.entries(f).filter(([, v]) => v > 0));
102
102
  return {
103
- fingerprint: $(R(s, a.calendar)),
103
+ fingerprint: k(R(s, a.calendar)),
104
104
  description: {
105
105
  status: "described",
106
106
  fields: m.slice(0, h.cardFields),
@@ -158,7 +158,7 @@ function Le(e) {
158
158
  function Oe(e) {
159
159
  const t = e.queryContext;
160
160
  return (t.finalConfig.metricColumns ?? []).flatMap((a) => {
161
- const r = $e({
161
+ const r = ke({
162
162
  metricComparison: a.comparison,
163
163
  globalDateComparison: t.globalDateComparison
164
164
  });
@@ -180,7 +180,7 @@ function Be(e, { calendar: t }) {
180
180
  text: g(b.text, h.textChars),
181
181
  ...b.omittedValues ? { omittedValues: b.omittedValues } : {}
182
182
  };
183
- }), o = a.resolvedFilterParts, c = [["card", o.authored], ["drill", o.drill], ["selection", o.selections]].flatMap(([i, u]) => we(u, r).map((d) => ({
183
+ }), o = a.resolvedFilterParts, c = [["card", o.authored], ["drill", o.drill], ["selection", o.selections]].flatMap(([i, u]) => _e(u, r).map((d) => ({
184
184
  origin: i,
185
185
  text: g(d.text, h.textChars),
186
186
  ...d.omittedValues ? { omittedValues: d.omittedValues } : {}
@@ -214,7 +214,7 @@ function ze(e) {
214
214
  return {
215
215
  label: g(((o = a.get(r)) == null ? void 0 : o.label) || r, h.labelChars),
216
216
  valueText: g(
217
- `${w(l, { maxListedValues: h.inputValues }).text}${m.size ? `; ${[...m].join("; ")}` : ""}`,
217
+ `${_(l, { maxListedValues: h.inputValues }).text}${m.size ? `; ${[...m].join("; ")}` : ""}`,
218
218
  h.textChars
219
219
  )
220
220
  };
@@ -225,7 +225,7 @@ function He(e) {
225
225
  return L({ sql: e.card.sql, controlBindings: t.controlBindings }).map((a) => ({
226
226
  name: g(a.paramId, h.labelChars),
227
227
  valueText: g(
228
- w(t.controlValues[a.controlId], { maxListedValues: h.inputValues }).text,
228
+ _(t.controlValues[a.controlId], { maxListedValues: h.inputValues }).text,
229
229
  h.textChars
230
230
  )
231
231
  }));
@@ -396,7 +396,7 @@ function Xe(e, t, a) {
396
396
  if ((n == null ? void 0 : n.kind) === "filter" && n.filterValue)
397
397
  o = B(n.filterValue, s, m);
398
398
  else if ((n == null ? void 0 : n.kind) === "control") {
399
- const i = w(n.controlValue, m);
399
+ const i = _(n.controlValue, m);
400
400
  o = { text: `${s} is set to ${i.text}`, omittedValues: i.omittedValues };
401
401
  }
402
402
  if (!o) return;
@@ -410,7 +410,7 @@ function Xe(e, t, a) {
410
410
  ...a ? { notApplied: "opened_from_another_dashboard" } : {},
411
411
  // The resolved value itself, with any date comparison on it and whether
412
412
  // the view applies it, so any change counts, shown or not.
413
- fingerprint: $(
413
+ fingerprint: k(
414
414
  (n == null ? void 0 : n.kind) === "filter" ? { filter: n.filterValue, comparison: n.comparisonSelection ?? null, notApplied: a } : { control: n == null ? void 0 : n.controlValue }
415
415
  )
416
416
  }
@@ -421,7 +421,7 @@ function ft(e) {
421
421
  }
422
422
  function Ye(e) {
423
423
  const { place: t, calendar: a } = e, r = q(e.dashboard), n = be({ dashboard: r, host: {}, calendar: a, materializeInputs: !1 }), s = {
424
- ..._({ dashboard: r, capture: {}, calendar: a }).runtimeValues,
424
+ ...D({ dashboard: r, capture: {}, calendar: a }).runtimeValues,
425
425
  cardViewState: t.cardViewState ?? {}
426
426
  }, l = t.cardId ? tt(r, t.cardId) : void 0, m = l ? G({
427
427
  dashboard: r,
@@ -448,7 +448,7 @@ function Ye(e) {
448
448
  };
449
449
  }
450
450
  function et(e) {
451
- const t = e.dashboard ? S(e.dashboard).find((r) => r.cardId === e.cardId) : void 0, a = D({
451
+ const t = e.dashboard ? S(e.dashboard).find((r) => r.cardId === e.cardId) : void 0, a = w({
452
452
  card: e.card ?? (t == null ? void 0 : t.card),
453
453
  snapshot: e.snapshot,
454
454
  documentSection: (t == null ? void 0 : t.kind) === "documentSectionCard"
@@ -488,7 +488,7 @@ function G(e) {
488
488
  ...e.withRequest ? { withRequest: !0 } : {}
489
489
  });
490
490
  }
491
- function D(e) {
491
+ function w(e) {
492
492
  var a;
493
493
  const { snapshot: t } = e;
494
494
  if (e.documentSection) return { status: "unavailable", reason: "document_section" };
@@ -518,7 +518,7 @@ function ht(e) {
518
518
  ), n = S(r).find((c) => c.cardId === e.cardId);
519
519
  if (!n) return { status: "refused", reason: "card_not_found" };
520
520
  if (n.kind === "documentSectionCard") return { status: "refused", reason: "document_section" };
521
- const { runtimeValues: s, transientContexts: l } = _({
521
+ const { runtimeValues: s, transientContexts: l } = D({
522
522
  dashboard: r,
523
523
  capture: a,
524
524
  calendar: t
@@ -532,7 +532,7 @@ function ht(e) {
532
532
  withRequest: !0
533
533
  });
534
534
  if (!m) return { status: "refused", reason: "card_not_found" };
535
- const o = D({ card: n.card, snapshot: m, documentSection: !1 });
535
+ const o = w({ card: n.card, snapshot: m, documentSection: !1 });
536
536
  return o.status === "ready" ? { ...o, renderConfig: m.queryContext.finalConfig } : o.reason === "pending" ? { status: "refused", reason: "blocked" } : {
537
537
  status: "refused",
538
538
  reason: o.reason,
@@ -571,7 +571,7 @@ function pt(e) {
571
571
  if ((l == null ? void 0 : l.kind) !== "variable") return { status: "refused", reason: "broken", message: `${n.name} has no card to run.` };
572
572
  const m = ie(s) && s.document ? s.document : void 0, o = rt(a, s.id, !!m, e.inputs ?? {}, t);
573
573
  if (!o.ok) return { status: "refused", reason: "broken", message: o.message };
574
- const { runtimeValues: c, transientContexts: i } = _({ dashboard: a, capture: o.capture, calendar: t }), u = m ? { sheetId: s.id, sectionId: void 0, documentFilterValues: [], documentControlDefinitions: [], documentControlValues: {} } : void 0, d = O({
574
+ const { runtimeValues: c, transientContexts: i } = D({ dashboard: a, capture: o.capture, calendar: t }), u = m ? { sheetId: s.id, sectionId: void 0, documentFilterValues: [], documentControlDefinitions: [], documentControlValues: {} } : void 0, d = O({
575
575
  dashboard: a,
576
576
  cardId: n.id,
577
577
  cardOverride: l.card,
@@ -591,7 +591,7 @@ function pt(e) {
591
591
  });
592
592
  if ((d == null ? void 0 : d.status) === "blocked")
593
593
  return d.reason === "requiredInput" ? { status: "refused", reason: "held", message: `${n.name} waits for ${d.missingRequiredLabels.join(", ")}.`, missingRequired: d.missingRequiredLabels } : { status: "refused", reason: "broken", message: d.message ?? `${n.name} can't run until its filter mapping is resolved.` };
594
- const b = D({ card: l.card, snapshot: d, documentSection: !1 });
594
+ const b = w({ card: l.card, snapshot: d, documentSection: !1 });
595
595
  return b.status !== "ready" ? { status: "refused", reason: "broken", message: b.message ?? `${n.name} has no query to run.` } : { status: "ready", variable: n, place: m ? "document" : "sheet", request: b.request };
596
596
  }
597
597
  function rt(e, t, a, r, n) {
@@ -624,7 +624,7 @@ export {
624
624
  et as a,
625
625
  ht as b,
626
626
  pt as c,
627
- D as d,
627
+ w as d,
628
628
  ft as e,
629
629
  Ye as f,
630
630
  G as g,
@@ -1,4 +1,4 @@
1
- import { i as d } from "./matrix-analytical-definition-myf3D3Qx.js";
1
+ import { i as d } from "./matrix-analytical-definition-CgQgVeeI.js";
2
2
  function m(e, t) {
3
3
  var a, l;
4
4
  const n = e.name.split(".").pop(), r = (a = e.fieldMeta) == null ? void 0 : a.qualifiedFieldName, i = !!(t.qualifiedFieldName && (r || e.name) === t.qualifiedFieldName), o = !((l = t.qualifiedFieldName) != null && l.includes(".")) && n === t.name;