react-semaphor 0.1.542 → 0.1.544

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 (66) hide show
  1. package/dist/activity/index.js +73 -0
  2. package/dist/assistant-context/index.js +1 -1
  3. package/dist/briefings/index.js +51 -50
  4. package/dist/chunks/{apply-dashboard-operations-Btbp2-6v.js → apply-dashboard-operations-Bz4n1Lq6.js} +44 -44
  5. package/dist/chunks/{assistant-chat-oHF5lTjA.js → assistant-chat-BNLkCDml.js} +288 -288
  6. package/dist/chunks/{comparison-window-caption-ChIyd_-L.js → comparison-window-caption-BTkrN3W4.js} +468 -463
  7. package/dist/chunks/dashboard-briefing-launcher-DQ_8O_e2.js +3725 -0
  8. package/dist/chunks/{dashboard-controls-CIn22Qgp.js → dashboard-controls-8RyBTQUO.js} +530 -525
  9. package/dist/chunks/dashboard-g5a4DKWq.js +14 -0
  10. package/dist/chunks/{dashboard-json-ZUYsIExq.js → dashboard-json-7qT9jmfL.js} +1 -1
  11. package/dist/chunks/{document-dashboard-inputs-C6MJVyoI.js → document-dashboard-inputs-BC6p-ESg.js} +4 -4
  12. package/dist/chunks/{document-sheet-utils-BsZUnHRl.js → document-sheet-utils-Duo9uLoH.js} +11 -11
  13. package/dist/chunks/{edit-dashboard-visual-DLdereA7.js → edit-dashboard-visual-BfJwnRIZ.js} +249 -248
  14. package/dist/chunks/export-file-format-C-tJsxsf.js +111 -0
  15. package/dist/chunks/{index-CV5rHq5D.js → index-DkAyQvC6.js} +59 -58
  16. package/dist/chunks/{matrix-formatter-BnsTX90d.js → matrix-formatter-CxJLkztA.js} +1 -1
  17. package/dist/chunks/{numeric-presentation-BSAqPpHt.js → numeric-presentation-DESvLiu9.js} +1 -1
  18. package/dist/chunks/{pivot-result-lifecycle-BBlAfBA0.js → pivot-result-lifecycle-DM4CyGKs.js} +287 -395
  19. package/dist/chunks/{raw-temporal-presentation-CZ2r0Vb_.js → raw-temporal-presentation-CLiVi90c.js} +2 -2
  20. package/dist/chunks/{report-preferences-dialog-MRUWpMcJ.js → report-preferences-dialog-Df7VpRVW.js} +195 -195
  21. package/dist/chunks/{saved-dashboard-context-DjPqgFly.js → saved-dashboard-context-B-mQ--nV.js} +3 -3
  22. package/dist/chunks/{semaphor-ready-indicator-BWSpRsPj.js → semaphor-ready-indicator-DDAxk8us.js} +39892 -39380
  23. package/dist/chunks/{shelf-drop-preview-context-CQbFLm3q.js → shelf-drop-preview-context-BSRPwaED.js} +414 -371
  24. package/dist/chunks/{table-export-sheet-BHSnuZHd.js → table-export-sheet-CPfGAQ9X.js} +1 -1
  25. package/dist/chunks/{use-create-flow-overlay-state-BJDNqdOh.js → use-create-flow-overlay-state-BxzFviM-.js} +67 -78
  26. package/dist/dashboard/index.js +1 -1
  27. package/dist/dashboard-authoring/index.js +72 -72
  28. package/dist/data-app-sdk/index.js +1 -1
  29. package/dist/format-utils/index.js +226 -223
  30. package/dist/index.js +266 -271
  31. package/dist/style.css +1 -1
  32. package/dist/surfboard/index.js +1 -1
  33. package/dist/types/activity.d.ts +2 -0
  34. package/dist/types/components/activity/activity-bell.d.ts +11 -0
  35. package/dist/types/components/activity/activity-instance.d.ts +50 -0
  36. package/dist/types/components/activity/activity-notices.d.ts +7 -0
  37. package/dist/types/components/activity/activity-provider.d.ts +21 -0
  38. package/dist/types/components/activity/activity-types.d.ts +177 -0
  39. package/dist/types/components/activity/index.d.ts +6 -0
  40. package/dist/types/components/activity/use-activity.d.ts +20 -0
  41. package/dist/types/components/briefings/briefing-author/run-model.d.ts +1 -2
  42. package/dist/types/components/briefings/briefing-author.d.ts +14 -12
  43. package/dist/types/components/briefings/dashboard-briefing-launcher.d.ts +5 -0
  44. package/dist/types/components/briefings/use-briefing-run-detail.d.ts +34 -0
  45. package/dist/types/components/index.d.ts +1 -4
  46. package/dist/types/lib/activity-identity.d.ts +21 -0
  47. package/dist/types/lib/api/exports-api.d.ts +4 -4
  48. package/dist/types/lib/hooks/index.d.ts +1 -3
  49. package/dist/types/lib/matrix-table/matrix-delivery.d.ts +4 -0
  50. package/dist/types/shared/activity/activity-contract.d.ts +84 -0
  51. package/dist/types/shared/activity/index.d.ts +5 -0
  52. package/dist/types/shared/dashboard-authoring/card-export-request.d.ts +6 -0
  53. package/dist/types/shared/format-utils/export-policy.d.ts +12 -0
  54. package/package.json +5 -1
  55. package/dist/chunks/dashboard-briefing-launcher-B-cm719R.js +0 -4248
  56. package/dist/chunks/dashboard-s5WJBcK8.js +0 -14
  57. package/dist/types/components/briefings/briefing-author/run-ui.d.ts +0 -81
  58. package/dist/types/components/briefings/use-briefing-run-polling.d.ts +0 -34
  59. package/dist/types/components/notifications/export-notification-item.d.ts +0 -24
  60. package/dist/types/components/notifications/export-notification-list.d.ts +0 -8
  61. package/dist/types/components/notifications/index.d.ts +0 -3
  62. package/dist/types/components/notifications/notification-bell.d.ts +0 -13
  63. package/dist/types/lib/exports/bounded-request.d.ts +0 -12
  64. package/dist/types/lib/hooks/use-export-polling.d.ts +0 -32
  65. package/dist/types/lib/hooks/use-export-recovery.d.ts +0 -11
  66. package/dist/types/lib/stores/export-store.d.ts +0 -62
@@ -2,7 +2,7 @@ var ft = Object.defineProperty;
2
2
  var ht = (e, t, r) => t in e ? ft(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r;
3
3
  var ne = (e, t, r) => ht(e, typeof t != "symbol" ? t + "" : t, r);
4
4
  import { z as S } from "zod";
5
- import { e as ct } from "./comparison-window-caption-ChIyd_-L.js";
5
+ import { e as ct } from "./comparison-window-caption-BTkrN3W4.js";
6
6
  var E = Uint8Array, I = Uint16Array, pe = Int32Array, xe = new E([
7
7
  0,
8
8
  0,
@@ -1,6 +1,6 @@
1
- import { c as W, C as Se } from "./x-4f5U2XwU.js";
2
- import { useEffect as K, forwardRef as nt, useMemo as H, useState as z, useRef as se, useCallback as F, Fragment as st } from "react";
3
- import { Z as qe, _ as ot, aE as dt, u as it, f as ct, aF as ut, aG as mt, aH as De, aI as pt, aJ as ft, aK as Me, aL as ze, aM as ht, aN as gt, aO as bt, aP as xt, aQ as vt, aR as yt } from "./semaphor-ready-indicator-BWSpRsPj.js";
1
+ import { c as fe, C as Se } from "./x-4f5U2XwU.js";
2
+ import { useEffect as K, forwardRef as nt, useMemo as H, useState as z, useRef as ne, useCallback as F, Fragment as st } from "react";
3
+ import { Y as qe, Z as ot, aD as dt, u as it, f as ct, aE as ut, aF as mt, aG as De, aH as pt, aI as ft, aJ as Me, aK as ze, aL as ht, aM as gt, aN as bt, aO as xt, aP as vt, aQ as yt, aR as Ct } from "./semaphor-ready-indicator-DDAxk8us.js";
4
4
  import { jsx as t, jsxs as o, Fragment as X } from "react/jsx-runtime";
5
5
  import "./index-CuHybtft.js";
6
6
  import "./validators-DMHTpf7a.js";
@@ -9,8 +9,8 @@ import "./analytics-base-schemas-BFAoRlkU.js";
9
9
  import "zod";
10
10
  import "../value-format-preferences/index.js";
11
11
  import { c as R } from "./class-utils-Df1OVOT1.js";
12
- import { m as Re, n as je, o as Be, p as $e, x as Qe, B as E, l as M, q as Ue, r as oe, s as de, t as ie, u as ce, v as ue } from "./switch-C3jLxlG0.js";
13
- import { D as Ct, E as kt, F as G, G as we, H as Te, I as me, J as pe, K as Nt, L as St, M as _e, N as Dt, O as wt, P as J, Q as Tt, R as Ve, S as Ye, T as He, U as Xe, V as Ge, W as _t, X as Vt, Y as Le, Z as Lt, _ as Ee, $ as Et, a0 as It, a1 as Ft, a2 as Ot, a3 as fe } from "./document-dashboard-inputs-C6MJVyoI.js";
12
+ import { m as Re, n as je, o as Be, p as $e, x as Qe, B as E, l as M, q as Ue, r as se, s as oe, t as de, u as ie, v as ce } from "./switch-C3jLxlG0.js";
13
+ import { D as kt, E as Nt, F as G, G as we, H as Te, I as ue, J as me, K as St, L as Dt, M as _e, N as wt, O as Tt, P as J, Q as _t, R as Ve, S as Ye, T as He, U as Xe, V as Ge, W as Vt, X as Lt, Y as Le, Z as Et, _ as Ee, $ as It, a0 as Ft, a1 as Ot, a2 as At, a3 as pe } from "./document-dashboard-inputs-BC6p-ESg.js";
14
14
  import { C as Ie } from "./selection-reducer-Dj_8xD69.js";
15
15
  /**
16
16
  * @license lucide-react v0.453.0 - ISC
@@ -18,17 +18,7 @@ import { C as Ie } from "./selection-reducer-Dj_8xD69.js";
18
18
  * This source code is licensed under the ISC license.
19
19
  * See the LICENSE file in the root directory of this source tree.
20
20
  */
21
- const At = W("CircleCheck", [
22
- ["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
23
- ["path", { d: "m9 12 2 2 4-4", key: "dzmm74" }]
24
- ]);
25
- /**
26
- * @license lucide-react v0.453.0 - ISC
27
- *
28
- * This source code is licensed under the ISC license.
29
- * See the LICENSE file in the root directory of this source tree.
30
- */
31
- const ra = W("FilterX", [
21
+ const ra = fe("FilterX", [
32
22
  ["path", { d: "M13.013 3H2l8 9.46V19l4 2v-8.54l.9-1.055", key: "1fi1da" }],
33
23
  ["path", { d: "m22 3-5 5", key: "12jva0" }],
34
24
  ["path", { d: "m17 3 5 5", key: "k36vhe" }]
@@ -39,7 +29,7 @@ const ra = W("FilterX", [
39
29
  * This source code is licensed under the ISC license.
40
30
  * See the LICENSE file in the root directory of this source tree.
41
31
  */
42
- const qt = W("Library", [
32
+ const qt = fe("Library", [
43
33
  ["path", { d: "m16 6 4 14", key: "ji33uf" }],
44
34
  ["path", { d: "M12 6v14", key: "1n7gus" }],
45
35
  ["path", { d: "M8 8v12", key: "1gg7y9" }],
@@ -51,7 +41,7 @@ const qt = W("Library", [
51
41
  * This source code is licensed under the ISC license.
52
42
  * See the LICENSE file in the root directory of this source tree.
53
43
  */
54
- const Mt = W("Link2", [
44
+ const Mt = fe("Link2", [
55
45
  ["path", { d: "M9 17H7A5 5 0 0 1 7 7h2", key: "8i5ue5" }],
56
46
  ["path", { d: "M15 7h2a5 5 0 1 1 0 10h-2", key: "1b9ql8" }],
57
47
  ["line", { x1: "8", x2: "16", y1: "12", y2: "12", key: "1jonct" }]
@@ -179,7 +169,7 @@ const zt = nt(
179
169
  onClick: k,
180
170
  ...p,
181
171
  ...g,
182
- className: R(`${Ct}`, u),
172
+ className: R(`${kt}`, u),
183
173
  children: n
184
174
  }
185
175
  ) }),
@@ -263,7 +253,7 @@ function Z(s) {
263
253
  function jt(s) {
264
254
  const { control: n, scope: u, detail: i } = s;
265
255
  return /* @__PURE__ */ o("div", { className: "flex items-start gap-2.5 rounded-control border border-border/60 bg-muted/30 px-3 py-2.5", children: [
266
- /* @__PURE__ */ t(At, { className: "mt-0.5 h-3.5 w-3.5 shrink-0 text-foreground" }),
256
+ /* @__PURE__ */ t(Ct, { className: "mt-0.5 h-3.5 w-3.5 shrink-0 text-foreground" }),
267
257
  /* @__PURE__ */ o("div", { className: "min-w-0 space-y-0.5", children: [
268
258
  /* @__PURE__ */ t("div", { className: "text-[13px] font-medium text-foreground", children: n.label }),
269
259
  /* @__PURE__ */ o("div", { className: "text-[12px] text-muted-foreground", children: [
@@ -446,19 +436,19 @@ function $t(s) {
446
436
  s.reservedIds
447
437
  ), u = s.type === n.type ? {
448
438
  ...n,
449
- label: fe[s.type]
439
+ label: pe[s.type]
450
440
  } : {
451
441
  ...Ge({
452
442
  controls: [
453
443
  {
454
444
  ...n,
455
- label: fe[s.type]
445
+ label: pe[s.type]
456
446
  }
457
447
  ],
458
448
  controlId: n.id,
459
449
  nextType: s.type
460
450
  }).controls[0],
461
- label: fe[s.type]
451
+ label: pe[s.type]
462
452
  };
463
453
  return {
464
454
  step: 2,
@@ -487,7 +477,7 @@ function sa({
487
477
  const O = H(
488
478
  () => new Set(u || []),
489
479
  [u]
490
- ), Ke = _t(s), Ze = kt(s), [he, P] = z(
480
+ ), Ke = Vt(s), Ze = Nt(s), [he, W] = z(
491
481
  null
492
482
  ), [We, Q] = z(
493
483
  null
@@ -496,7 +486,7 @@ function sa({
496
486
  step: 1,
497
487
  control: G(s, n, Array.from(O))
498
488
  } : null
499
- ), U = se({}), j = se(void 0), ge = se(g), be = H(() => {
489
+ ), U = ne({}), j = ne(void 0), ge = ne(g), be = H(() => {
500
490
  const e = we({ scope: s, card: S });
501
491
  if (!T)
502
492
  return e;
@@ -518,7 +508,7 @@ function sa({
518
508
  ), L = F(
519
509
  (e) => s === "dashboard" && (e === "field_selector" || e === "metric_selector"),
520
510
  [s]
521
- ), ee = H(
511
+ ), P = H(
522
512
  () => a ? Te(
523
513
  x || [],
524
514
  a.control.type
@@ -535,7 +525,7 @@ function sa({
535
525
  fields: p || [],
536
526
  metrics: N || []
537
527
  };
538
- const e = a.selectedCardIds || [], l = me({
528
+ const e = a.selectedCardIds || [], l = ue({
539
529
  controlType: a.control.type,
540
530
  participants: x || [],
541
531
  selectedCardIds: e
@@ -564,7 +554,7 @@ function sa({
564
554
  ge.current = g, e && (D({
565
555
  step: 1,
566
556
  control: G(s, n, Array.from(O))
567
- }), Q(null), P(null));
557
+ }), Q(null), W(null));
568
558
  }, [n, g, O, s]);
569
559
  const et = (e) => {
570
560
  if (!L(e.type))
@@ -578,7 +568,7 @@ function sa({
578
568
  fields: p || [],
579
569
  metrics: N || []
580
570
  };
581
- const r = me({
571
+ const r = ue({
582
572
  controlType: e.type,
583
573
  participants: x || [],
584
574
  selectedCardIds: l
@@ -593,17 +583,17 @@ function sa({
593
583
  target: r.metricTargetMap[d.value]
594
584
  })) : []
595
585
  };
596
- }, te = (e) => {
586
+ }, ee = (e) => {
597
587
  if (!L(e.control.type))
598
588
  return {
599
589
  nextControl: e.control,
600
590
  cardBindingsById: void 0
601
591
  };
602
- const l = (f == null ? void 0 : f[e.control.id]) || [], r = me({
592
+ const l = (f == null ? void 0 : f[e.control.id]) || [], r = ue({
603
593
  controlType: e.control.type,
604
594
  participants: x || [],
605
595
  selectedCardIds: e.nextSelectedCardIds
606
- }), d = Ft({
596
+ }), d = Ot({
607
597
  control: e.control,
608
598
  choices: r.choices
609
599
  }), m = Object.fromEntries(
@@ -623,10 +613,10 @@ function sa({
623
613
  };
624
614
  }, V = F(
625
615
  (e, l = i, r = { type: "update" }) => {
626
- const d = e.map((m) => (pe({
616
+ const d = e.map((m) => (me({
627
617
  control: m,
628
618
  defaultValues: l
629
- }), Nt(
619
+ }), St(
630
620
  m
631
621
  )));
632
622
  k(d, l, r);
@@ -641,15 +631,15 @@ function sa({
641
631
  (C) => C.id === e
642
632
  );
643
633
  let h, c;
644
- if (m && (!r || Et({ control: r }, { control: m })) && s === "dashboard" && (m.type === "field_selector" || m.type === "metric_selector")) {
645
- const C = (f == null ? void 0 : f[m.id]) || [], q = te({
634
+ if (m && (!r || It({ control: r }, { control: m })) && s === "dashboard" && (m.type === "field_selector" || m.type === "metric_selector")) {
635
+ const C = (f == null ? void 0 : f[m.id]) || [], q = ee({
646
636
  control: m,
647
637
  nextSelectedCardIds: C
648
638
  });
649
639
  d = d.map(
650
640
  (A) => A.id === e ? q.nextControl : A
651
641
  ), h = q.cardBindingsById, c = [m.id];
652
- } else if (r && (!m || !It(m.type)) && s === "dashboard" && (r.type === "field_selector" || r.type === "metric_selector")) {
642
+ } else if (r && (!m || !Ft(m.type)) && s === "dashboard" && (r.type === "field_selector" || r.type === "metric_selector")) {
653
643
  const C = (f == null ? void 0 : f[r.id]) || [];
654
644
  h = Object.fromEntries(
655
645
  C.map((q) => [q, void 0])
@@ -660,7 +650,7 @@ function sa({
660
650
  );
661
651
  let w = i;
662
652
  if (r && y) {
663
- const C = pe({
653
+ const C = me({
664
654
  control: r,
665
655
  defaultValues: i
666
656
  });
@@ -682,7 +672,7 @@ function sa({
682
672
  }, tt = (e, l) => {
683
673
  if (!l.trim())
684
674
  return;
685
- const r = Ot(l);
675
+ const r = At(l);
686
676
  if (r === e || O.has(r) || n.some(
687
677
  (h) => h.id === r && h.id !== e
688
678
  ))
@@ -716,7 +706,7 @@ function sa({
716
706
  j.current = void 0, D({
717
707
  step: 1,
718
708
  control: G(s, n, Array.from(O))
719
- }), Q(null), P(null);
709
+ }), Q(null), W(null);
720
710
  }, [n, O, s]), $ = (e) => {
721
711
  D(
722
712
  (l) => l && (() => {
@@ -741,11 +731,11 @@ function sa({
741
731
  defaultValue: e
742
732
  })
743
733
  );
744
- }, ae = (() => {
734
+ }, te = (() => {
745
735
  if (!a)
746
736
  return !1;
747
737
  if (a.step === 2 && L(a.control.type))
748
- return (a.selectedCardIds || []).length > 0 && St({
738
+ return (a.selectedCardIds || []).length > 0 && Dt({
749
739
  participants: x || [],
750
740
  selectedCardIds: a.selectedCardIds || [],
751
741
  control: a.control,
@@ -754,7 +744,7 @@ function sa({
754
744
  if (a.step !== 2 && a.step !== 3 || !a.control.label.trim())
755
745
  return !1;
756
746
  const l = a.control.source.kind === "sql_query" ? a.control : _e(a.control);
757
- if (l.source.kind === "manual" && (Dt(l) && l.source.options.length === 0 || l.source.options.some(
747
+ if (l.source.kind === "manual" && (wt(l) && l.source.options.length === 0 || l.source.options.some(
758
748
  (d) => d.label.trim().length === 0 || d.value.trim().length === 0
759
749
  )))
760
750
  return !1;
@@ -762,14 +752,14 @@ function sa({
762
752
  const { connectionId: r, sql: d, valueColumn: m } = l.source;
763
753
  return r.trim().length > 0 && d.trim().length > 0 && m.trim().length > 0;
764
754
  }
765
- return wt(
755
+ return Tt(
766
756
  J(l, a.defaultValue)
767
757
  );
768
758
  })(), ve = () => {
769
759
  var h;
770
760
  if (!a)
771
761
  return;
772
- const e = _e(a.control), l = Lt({
762
+ const e = _e(a.control), l = Et({
773
763
  label: e.label,
774
764
  fallbackId: e.id,
775
765
  existingControls: n,
@@ -795,7 +785,7 @@ function sa({
795
785
  matrixTargetIds: a.matrixTargetIds,
796
786
  cardBindingsById: d
797
787
  });
798
- }, re = F(() => {
788
+ }, ae = F(() => {
799
789
  D(null);
800
790
  }, []), ye = F(() => {
801
791
  if (!(a != null && a.createdControlId)) {
@@ -838,11 +828,11 @@ function sa({
838
828
  }
839
829
  );
840
830
  Q(l), D(null), I == null || I();
841
- }, [n, a, i, V, I]), lt = a ? L(a.control.type) ? ["Choose type", "Select cards", "Configure", "Finish"] : ["Choose type", "Configure", "Finish"] : [], Ce = a != null && a.createdControlId ? `[[param.${a.createdControlId}]]` : a ? `[[param.${Tt(a.control.label) || a.control.id}]]` : "", le = Ve({
831
+ }, [n, a, i, V, I]), lt = a ? L(a.control.type) ? ["Choose type", "Select cards", "Configure", "Finish"] : ["Choose type", "Configure", "Finish"] : [], Ce = a != null && a.createdControlId ? `[[param.${a.createdControlId}]]` : a ? `[[param.${_t(a.control.label) || a.control.id}]]` : "", re = Ve({
842
832
  controls: n,
843
833
  defaultValues: i
844
- }), ne = a ? [...n, a.control] : n, ke = a ? Ve({
845
- controls: ne,
834
+ }), le = a ? [...n, a.control] : n, ke = a ? Ve({
835
+ controls: le,
846
836
  defaultValues: i,
847
837
  overrides: [
848
838
  {
@@ -850,7 +840,7 @@ function sa({
850
840
  value: a.defaultValue
851
841
  }
852
842
  ]
853
- }) : le;
843
+ }) : re;
854
844
  return /* @__PURE__ */ o("div", { className: "space-y-4", children: [
855
845
  a ? /* @__PURE__ */ o("div", { className: "space-y-4 pb-1", children: [
856
846
  /* @__PURE__ */ t(
@@ -914,7 +904,7 @@ function sa({
914
904
  type: "button",
915
905
  variant: "outline",
916
906
  size: "xs",
917
- onClick: re,
907
+ onClick: ae,
918
908
  children: "Back to controls"
919
909
  }
920
910
  )
@@ -936,7 +926,7 @@ function sa({
936
926
  ),
937
927
  /* @__PURE__ */ t("p", { className: "text-[12px] text-muted-foreground", children: "Choose which cards should respond to this shared control." })
938
928
  ] }),
939
- ee.length === 0 ? /* @__PURE__ */ t("div", { className: "rounded-control border border-border/60 bg-muted/30 px-3 py-2.5 text-[12px] text-muted-foreground", children: "No eligible cards are available yet. Add compatible metrics or group-by fields to cards first." }) : /* @__PURE__ */ t("div", { className: "space-y-1 rounded-control border border-border/60 bg-background p-2", children: ee.map((e) => {
929
+ P.length === 0 ? /* @__PURE__ */ t("div", { className: "rounded-control border border-border/60 bg-muted/30 px-3 py-2.5 text-[12px] text-muted-foreground", children: "No eligible cards are available yet. Add compatible metrics or group-by fields to cards first." }) : /* @__PURE__ */ t("div", { className: "space-y-1 rounded-control border border-border/60 bg-background p-2", children: P.map((e) => {
940
930
  const l = (a.selectedCardIds || []).includes(e.cardId);
941
931
  return /* @__PURE__ */ o(
942
932
  "label",
@@ -972,7 +962,7 @@ function sa({
972
962
  /* @__PURE__ */ t(
973
963
  De,
974
964
  {
975
- participants: ee,
965
+ participants: P,
976
966
  selectedCardIds: a.selectedCardIds || [],
977
967
  control: a.control,
978
968
  selected: a.matrixTargetIds,
@@ -1009,7 +999,7 @@ function sa({
1009
999
  step: 3
1010
1000
  }
1011
1001
  ),
1012
- disabled: !ae,
1002
+ disabled: !te,
1013
1003
  children: "Next"
1014
1004
  }
1015
1005
  )
@@ -1023,7 +1013,7 @@ function sa({
1023
1013
  defaultValue: a.defaultValue,
1024
1014
  availableFieldChoices: Y.fields,
1025
1015
  availableMetricChoices: Y.metrics,
1026
- previewControlDefinitions: ne,
1016
+ previewControlDefinitions: le,
1027
1017
  previewControlValues: ke,
1028
1018
  onControlChange: (e) => $(() => e),
1029
1019
  onLabelChange: (e) => $((l) => ({
@@ -1038,7 +1028,7 @@ function sa({
1038
1028
  }
1039
1029
  ),
1040
1030
  onNext: ve,
1041
- nextDisabled: !ae
1031
+ nextDisabled: !te
1042
1032
  }
1043
1033
  ),
1044
1034
  a.step === 3 && L(a.control.type) && /* @__PURE__ */ t(
@@ -1048,7 +1038,7 @@ function sa({
1048
1038
  defaultValue: a.defaultValue,
1049
1039
  availableFieldChoices: Y.fields,
1050
1040
  availableMetricChoices: Y.metrics,
1051
- previewControlDefinitions: ne,
1041
+ previewControlDefinitions: le,
1052
1042
  previewControlValues: ke,
1053
1043
  onControlChange: (e) => $(() => e),
1054
1044
  onLabelChange: (e) => $((l) => ({
@@ -1063,7 +1053,7 @@ function sa({
1063
1053
  }
1064
1054
  ),
1065
1055
  onNext: ve,
1066
- nextDisabled: !ae
1056
+ nextDisabled: !te
1067
1057
  }
1068
1058
  ),
1069
1059
  a.step === 3 && !L(a.control.type) && /* @__PURE__ */ t(
@@ -1086,7 +1076,7 @@ function sa({
1086
1076
  step: 2
1087
1077
  }
1088
1078
  ),
1089
- onCancel: re,
1079
+ onCancel: ae,
1090
1080
  onDone: ye
1091
1081
  }
1092
1082
  ),
@@ -1110,14 +1100,14 @@ function sa({
1110
1100
  step: 3
1111
1101
  }
1112
1102
  ),
1113
- onCancel: re,
1103
+ onCancel: ae,
1114
1104
  onDone: ye
1115
1105
  }
1116
1106
  )
1117
1107
  ] }) : null,
1118
1108
  !a && n.length === 0 ? /* @__PURE__ */ t("div", { className: "rounded-md border border-dashed p-3 text-sm text-muted-foreground", children: b }) : null,
1119
1109
  !a && n.map((e) => {
1120
- const l = et(e), r = v == null ? void 0 : v[e.id], d = pe({
1110
+ const l = et(e), r = v == null ? void 0 : v[e.id], d = me({
1121
1111
  control: e,
1122
1112
  defaultValues: i
1123
1113
  }), m = We === e.id, h = "inline-flex shrink-0 items-center rounded-[4px] border border-border/60 bg-muted/40 px-1.5 py-0.5 text-[11px] font-medium text-muted-foreground";
@@ -1184,7 +1174,7 @@ function sa({
1184
1174
  /* @__PURE__ */ o("div", { className: "flex flex-col gap-1.5", children: [
1185
1175
  /* @__PURE__ */ t(M, { className: "text-[10px] font-medium uppercase tracking-[0.08em] text-muted-foreground", children: "Type" }),
1186
1176
  /* @__PURE__ */ o(
1187
- oe,
1177
+ se,
1188
1178
  {
1189
1179
  value: e.type,
1190
1180
  onValueChange: (c) => {
@@ -1197,10 +1187,10 @@ function sa({
1197
1187
  V(y.controls, y.defaultValues);
1198
1188
  },
1199
1189
  children: [
1200
- /* @__PURE__ */ t(de, { size: "xs", children: /* @__PURE__ */ t(ie, {}) }),
1201
- /* @__PURE__ */ t(ce, { children: Pe(e.type).map(
1190
+ /* @__PURE__ */ t(oe, { size: "xs", children: /* @__PURE__ */ t(de, {}) }),
1191
+ /* @__PURE__ */ t(ie, { children: Pe(e.type).map(
1202
1192
  (c) => /* @__PURE__ */ t(
1203
- ue,
1193
+ ce,
1204
1194
  {
1205
1195
  value: c.value,
1206
1196
  children: c.label
@@ -1215,7 +1205,7 @@ function sa({
1215
1205
  /* @__PURE__ */ o("div", { className: "flex flex-col gap-1.5", children: [
1216
1206
  /* @__PURE__ */ t(M, { className: "text-[10px] font-medium uppercase tracking-[0.08em] text-muted-foreground", children: "Show in" }),
1217
1207
  /* @__PURE__ */ o(
1218
- oe,
1208
+ se,
1219
1209
  {
1220
1210
  value: e.placement || Ze,
1221
1211
  onValueChange: (c) => B(e.id, (y) => ({
@@ -1223,8 +1213,8 @@ function sa({
1223
1213
  placement: c
1224
1214
  })),
1225
1215
  children: [
1226
- /* @__PURE__ */ t(de, { size: "xs", children: /* @__PURE__ */ t(ie, {}) }),
1227
- /* @__PURE__ */ t(ce, { children: Ke.map((c) => /* @__PURE__ */ t(ue, { value: c.value, children: c.label }, c.value)) })
1216
+ /* @__PURE__ */ t(oe, { size: "xs", children: /* @__PURE__ */ t(de, {}) }),
1217
+ /* @__PURE__ */ t(ie, { children: Ke.map((c) => /* @__PURE__ */ t(ce, { value: c.value, children: c.label }, c.value)) })
1228
1218
  ]
1229
1219
  }
1230
1220
  )
@@ -1245,7 +1235,7 @@ function sa({
1245
1235
  })),
1246
1236
  selectedCardIds: (f == null ? void 0 : f[e.id]) || [],
1247
1237
  onChange: (c) => {
1248
- const y = te({
1238
+ const y = ee({
1249
1239
  control: e,
1250
1240
  nextSelectedCardIds: c
1251
1241
  }), w = n.map(
@@ -1265,7 +1255,7 @@ function sa({
1265
1255
  selectedCardIds: (f == null ? void 0 : f[e.id]) || [],
1266
1256
  control: e,
1267
1257
  onChange: (c, y) => {
1268
- const w = te({
1258
+ const w = ee({
1269
1259
  control: e,
1270
1260
  nextSelectedCardIds: (f == null ? void 0 : f[e.id]) || [],
1271
1261
  matrixTargetIds: { [c]: y }
@@ -1286,7 +1276,7 @@ function sa({
1286
1276
  availableFieldChoices: l.fields,
1287
1277
  availableMetricChoices: l.metrics,
1288
1278
  previewControlDefinitions: n,
1289
- previewControlValues: le,
1279
+ previewControlValues: re,
1290
1280
  controlLifecycle: "edit",
1291
1281
  onChange: (c) => B(e.id, () => c)
1292
1282
  }
@@ -1299,7 +1289,7 @@ function sa({
1299
1289
  allowNoDefault: !0,
1300
1290
  allowCardDefault: !0,
1301
1291
  previewControlDefinitions: n,
1302
- previewControlValues: le,
1292
+ previewControlValues: re,
1303
1293
  onChange: (c) => {
1304
1294
  const y = n.map(
1305
1295
  (w) => w.id === e.id ? { ...w, defaultValue: c } : w
@@ -1317,7 +1307,7 @@ function sa({
1317
1307
  ht,
1318
1308
  {
1319
1309
  open: he === e.id,
1320
- onOpenChange: (c) => P(c ? e.id : null),
1310
+ onOpenChange: (c) => W(c ? e.id : null),
1321
1311
  children: [
1322
1312
  /* @__PURE__ */ t(gt, { asChild: !0, children: /* @__PURE__ */ o(
1323
1313
  E,
@@ -1348,7 +1338,7 @@ function sa({
1348
1338
  /* @__PURE__ */ o("div", { className: "flex flex-col gap-1.5", children: [
1349
1339
  /* @__PURE__ */ t(M, { className: "text-[10px] font-medium uppercase tracking-[0.08em] text-muted-foreground", children: "Initial value" }),
1350
1340
  /* @__PURE__ */ o(
1351
- oe,
1341
+ se,
1352
1342
  {
1353
1343
  value: e.initialValueStrategy,
1354
1344
  onValueChange: (c) => B(e.id, (y) => ({
@@ -1356,9 +1346,9 @@ function sa({
1356
1346
  initialValueStrategy: c
1357
1347
  })),
1358
1348
  children: [
1359
- /* @__PURE__ */ t(de, { size: "xs", children: /* @__PURE__ */ t(ie, {}) }),
1360
- /* @__PURE__ */ t(ce, { children: Vt.map((c) => /* @__PURE__ */ t(
1361
- ue,
1349
+ /* @__PURE__ */ t(oe, { size: "xs", children: /* @__PURE__ */ t(de, {}) }),
1350
+ /* @__PURE__ */ t(ie, { children: Lt.map((c) => /* @__PURE__ */ t(
1351
+ ce,
1362
1352
  {
1363
1353
  value: c.value,
1364
1354
  children: c.label
@@ -1444,6 +1434,5 @@ export {
1444
1434
  na as V,
1445
1435
  Mt as a,
1446
1436
  la as b,
1447
- At as c,
1448
1437
  oa as u
1449
1438
  };
@@ -1,4 +1,4 @@
1
- import { D as o } from "../chunks/dashboard-s5WJBcK8.js";
1
+ import { D as o } from "../chunks/dashboard-g5a4DKWq.js";
2
2
  import { C as s, E as C } from "../chunks/table-settings-CLZocegs.js";
3
3
  export {
4
4
  s as CONTROL_CARD_DEFAULT_VALUE,