react-semaphor 0.1.444 → 0.1.446

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 (136) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/dist/analytics-protocol/index.cjs +1 -1
  3. package/dist/analytics-protocol/index.js +123 -107
  4. package/dist/appearance/index.cjs +1 -1
  5. package/dist/brand-studio/index.cjs +2 -2
  6. package/dist/brand-studio/index.js +5 -4
  7. package/dist/briefings/index.cjs +1 -1
  8. package/dist/briefings/index.js +526 -457
  9. package/dist/chunks/analyze-result-contract-BHb7sUUW.cjs +1 -0
  10. package/dist/chunks/analyze-result-contract-DUv3QnMl.js +29 -0
  11. package/dist/chunks/{braces-CbO-aIwH.js → braces-BKimshER.cjs} +1 -1
  12. package/dist/chunks/{code-editor-BpADiIlq.js → code-editor-B4gTfvc5.js} +6800 -6560
  13. package/dist/chunks/code-editor-BYVorgOf.cjs +138 -0
  14. package/dist/chunks/common-types-CQ6SHfLk.cjs +1 -0
  15. package/dist/chunks/{common-types-ClkOI-3O.js → common-types-DFsDdpH7.js} +22 -21
  16. package/dist/chunks/dashboard-DGX9b3T-.cjs +1402 -0
  17. package/dist/chunks/{dashboard-CJNVq8XI.js → dashboard-ECv6p6DC.js} +50511 -47720
  18. package/dist/chunks/{dashboard-briefing-launcher-Bg_SeBV8.js → dashboard-briefing-launcher-BpWq3shh.js} +190 -187
  19. package/dist/chunks/dashboard-briefing-launcher-C2kEWFgy.cjs +26 -0
  20. package/dist/chunks/{dashboard-controls-CYBi_mes.js → dashboard-controls-DNoMwxMy.cjs} +2 -2
  21. package/dist/chunks/{dashboard-controls-Da9MkPaf.js → dashboard-controls-DPLepxZy.js} +14 -13
  22. package/dist/chunks/dashboard-date-comparison-definition-DZq0htjG.cjs +1 -0
  23. package/dist/chunks/{dashboard-json-BtrdGo1U.js → dashboard-json-0Etvlp57.js} +14 -12
  24. package/dist/chunks/dashboard-json-4LbKuMSm.cjs +1 -0
  25. package/dist/chunks/{edit-dashboard-visual-kE6_3R3j.js → edit-dashboard-visual-0uKSZPPa.js} +8302 -8123
  26. package/dist/chunks/edit-dashboard-visual-C1uVqhI5.cjs +182 -0
  27. package/dist/chunks/{editor-action-buttons-8_CQa8Hb.js → editor-action-buttons-DKXO5aK7.cjs} +1 -1
  28. package/dist/chunks/{editor-action-buttons-DROkx4PS.js → editor-action-buttons-DpA5PdEo.js} +24 -23
  29. package/dist/chunks/{index-D7KJindZ.js → format-types-CSv0V7mm.cjs} +1 -1
  30. package/dist/chunks/{index-CnujJ3fa.js → format-types-CZH5w1lo.js} +23 -17
  31. package/dist/chunks/{layout-grid-B08pP7v6.js → layout-grid-3-HWzEwU.cjs} +1 -1
  32. package/dist/chunks/{metric-comparison-CPoDx56y.js → metric-comparison-BJ_Qu1ZF.js} +1 -1
  33. package/dist/chunks/metric-comparison-CUAJ8n4y.cjs +1 -0
  34. package/dist/chunks/mouse-pointer-2-BOL92ext.cjs +6 -0
  35. package/dist/chunks/mouse-pointer-2-DXNw3_3o.js +19 -0
  36. package/dist/chunks/{palette-C0yjT5Tv.js → palette-DW_l7Jr0.cjs} +1 -1
  37. package/dist/chunks/pivot-result-identity-B6QCWOSi.js +94 -0
  38. package/dist/chunks/pivot-result-identity-CDLRT-YG.cjs +1 -0
  39. package/dist/chunks/pivot-result-lifecycle-BM3Pl-D1.js +914 -0
  40. package/dist/chunks/pivot-result-lifecycle-DPc0ANwk.cjs +4 -0
  41. package/dist/chunks/presentation-execution-BTV-Q43g.cjs +1 -0
  42. package/dist/chunks/presentation-execution-CGlb7YZ6.js +637 -0
  43. package/dist/chunks/report-preferences-dialog-CBMox_qt.cjs +1 -0
  44. package/dist/chunks/{report-preferences-dialog-Dq7rmN93.js → report-preferences-dialog-CkZ2KHWX.js} +7 -6
  45. package/dist/chunks/report-runtime-context-C8LZFsqV.cjs +1 -0
  46. package/dist/chunks/report-runtime-context-Qzn11HQe.js +387 -0
  47. package/dist/chunks/{save-Xdc4pnys.js → save-4_uMnE6s.cjs} +1 -1
  48. package/dist/chunks/{search-Dcud9ajy.js → search-6ZmeMq55.cjs} +1 -1
  49. package/dist/chunks/temporal-bucket-BnPxGrAi.js +446 -0
  50. package/dist/chunks/temporal-bucket-authoring-BUZMuVca.js +205 -0
  51. package/dist/chunks/temporal-bucket-authoring-CPTwHzvs.cjs +1 -0
  52. package/dist/chunks/temporal-bucket-contract-B2bJ1oe4.js +108 -0
  53. package/dist/chunks/temporal-bucket-contract-ChDBWX8I.cjs +1 -0
  54. package/dist/chunks/temporal-bucket-pMnV-4Nj.cjs +1 -0
  55. package/dist/chunks/{comparison-document-migration-Dj6xZMCb.js → temporal-result-owner-Cb27SSG9.js} +152 -123
  56. package/dist/chunks/temporal-result-owner-f6-i65Fb.cjs +1 -0
  57. package/dist/chunks/token-types-BdQ8kHBm.cjs +1 -0
  58. package/dist/chunks/token-types-DLo91nOf.js +8 -0
  59. package/dist/chunks/{update-policy-DnF_74zC.js → update-policy-BxvYMYz0.cjs} +1 -1
  60. package/dist/chunks/{update-policy-De2NswtM.js → update-policy-eg59mQqv.js} +1 -1
  61. package/dist/chunks/validators-9D4KBqKD.cjs +1 -0
  62. package/dist/chunks/validators-wZ2WlNHc.js +4640 -0
  63. package/dist/dashboard/index.cjs +1 -1
  64. package/dist/dashboard/index.js +2 -2
  65. package/dist/dashboard-authoring/index.cjs +3 -3
  66. package/dist/dashboard-authoring/index.js +136 -126
  67. package/dist/data-app-builder/index.cjs +13 -18
  68. package/dist/data-app-builder/index.js +91 -105
  69. package/dist/data-app-codegen/index.cjs +1 -1
  70. package/dist/data-app-codegen/index.js +2 -2
  71. package/dist/data-app-codegen-node/index.cjs +1 -1
  72. package/dist/data-app-codegen-node/index.js +3 -3
  73. package/dist/data-app-sdk/index.cjs +2 -2
  74. package/dist/data-app-sdk/index.js +34 -35
  75. package/dist/data-app-sdk-adapters/index.cjs +1 -1
  76. package/dist/data-app-sdk-adapters/index.js +5 -5
  77. package/dist/data-app-sdk-validation/index.cjs +1 -1
  78. package/dist/data-app-sdk-validation/index.js +9 -10
  79. package/dist/format-utils/index.cjs +3 -3
  80. package/dist/format-utils/index.js +155 -176
  81. package/dist/index.cjs +1 -1
  82. package/dist/index.js +180 -174
  83. package/dist/report-runtime-context/index.cjs +1 -1
  84. package/dist/report-runtime-context/index.js +7 -392
  85. package/dist/shared/index.cjs +1 -1
  86. package/dist/style.css +1 -1
  87. package/dist/surfboard/index.cjs +1 -1
  88. package/dist/surfboard/index.js +3 -3
  89. package/dist/types/analytics-protocol.d.ts +257 -48
  90. package/dist/types/briefings.d.ts +138 -50
  91. package/dist/types/dashboard-assistant.d.ts +207 -52
  92. package/dist/types/dashboard-authoring.d.ts +182 -50
  93. package/dist/types/dashboard.d.ts +290 -48
  94. package/dist/types/data-app-builder.d.ts +48 -42
  95. package/dist/types/data-app-codegen-node.d.ts +50 -44
  96. package/dist/types/data-app-codegen.d.ts +50 -44
  97. package/dist/types/data-app-sdk-adapters.d.ts +48 -42
  98. package/dist/types/data-app-sdk-validation.d.ts +81 -43
  99. package/dist/types/data-app-sdk.d.ts +83 -45
  100. package/dist/types/format-utils.d.ts +645 -67
  101. package/dist/types/index.cjs +1 -1
  102. package/dist/types/index.js +19 -19
  103. package/dist/types/main.d.ts +305 -100
  104. package/dist/types/report-runtime-context.d.ts +3 -0
  105. package/dist/types/shared.d.ts +116 -41
  106. package/dist/types/surfboard.d.ts +290 -48
  107. package/dist/types/types.d.ts +455 -65
  108. package/package.json +3 -1
  109. package/dist/chunks/analyze-result-contract-BswhsmWT.js +0 -1
  110. package/dist/chunks/analyze-result-contract-CfOBEwaC.js +0 -1998
  111. package/dist/chunks/code-editor-M7HTUhdF.js +0 -138
  112. package/dist/chunks/common-types-C73-Ud1-.js +0 -1
  113. package/dist/chunks/comparison-document-migration-DbU_BTxR.js +0 -1
  114. package/dist/chunks/csv-utils-BZDvO2Fw.js +0 -376
  115. package/dist/chunks/csv-utils-Co0WxHke.js +0 -4
  116. package/dist/chunks/dashboard-DxZuqe8t.js +0 -1402
  117. package/dist/chunks/dashboard-briefing-launcher-Do6ZcOj4.js +0 -26
  118. package/dist/chunks/dashboard-date-comparison-definition-DGZr3m-b.js +0 -1
  119. package/dist/chunks/dashboard-json-ezLyW7AK.js +0 -1
  120. package/dist/chunks/edit-dashboard-visual-DEb9MeSM.js +0 -182
  121. package/dist/chunks/metric-comparison-DVy3fll_.js +0 -1
  122. package/dist/chunks/numeric-presentation-BJs5lSar.js +0 -517
  123. package/dist/chunks/numeric-presentation-Dlb-Dk4c.js +0 -1
  124. package/dist/chunks/report-preferences-dialog-D5sIaFnb.js +0 -1
  125. package/dist/chunks/source-identity-5OPV4gvg.js +0 -92
  126. package/dist/chunks/source-identity-Cbo2LOHQ.js +0 -1
  127. package/dist/chunks/validators-B2vUAqTf.js +0 -1
  128. package/dist/chunks/validators-Bce_J7Vd.js +0 -2448
  129. /package/dist/chunks/{card-config-utils-15sRtebL.js → card-config-utils-15sRtebL.cjs} +0 -0
  130. /package/dist/chunks/{catalog-field-grounding-Bnx-3tE0.js → catalog-field-grounding-Bnx-3tE0.cjs} +0 -0
  131. /package/dist/chunks/{dashboard-input-contract-DV3cshjz.js → dashboard-input-contract-DV3cshjz.cjs} +0 -0
  132. /package/dist/chunks/{index-Dpm_VET4.js → index-Dpm_VET4.cjs} +0 -0
  133. /package/dist/chunks/{index-jSrCwPQz.js → index-jSrCwPQz.cjs} +0 -0
  134. /package/dist/chunks/{normalize-dashboard-for-dirty-check-BXRUMVb2.js → normalize-dashboard-for-dirty-check-BXRUMVb2.cjs} +0 -0
  135. /package/dist/chunks/{operators-DrTQsJXv.js → operators-DrTQsJXv.cjs} +0 -0
  136. /package/dist/chunks/{use-debounced-dirty-check-XHSwAefL.js → use-debounced-dirty-check-XHSwAefL.cjs} +0 -0
@@ -1,25 +1,28 @@
1
1
  import { jsx as e, jsxs as r, Fragment as W } from "react/jsx-runtime";
2
2
  import jt, { useState as E, useEffect as J, useMemo as ee, useContext as Wt, useRef as he, useCallback as q } from "react";
3
- import { aH as Se, aI as De, aK as ke, bb as Ct, b_ as Ht, co as Gt, cp as Kt, aZ as fe, cc as wt, bm as Ve, y as qt, w as Xt, cq as Yt, aP as Je, aS as et, aT as tt, aU as rt, aV as at, aW as nt, aX as st, aY as Nt, bl as ot, aG as O, cr as Zt, cs as Qt, ct as Ke, cd as Oe, ce as ze, cu as St, cf as _e, bY as K, b1 as Jt, bD as Re, cv as er, bX as tr, aJ as it, aL as lt, cw as rr, aF as ar, ba as nr, by as Dt, cx as sr, b$ as or, av as ir, aM as lr, b3 as cr, az as $e, at as ue, a6 as ct, a3 as kt, a2 as dt, as as At, a4 as dr, Y as ur, cj as hr, cy as mr, bw as pr, N as ft, R as fr, au as gr, cz as br, cA as xr, cB as vr, cC as yr, cD as Cr, cE as wr, cF as Nr, cG as Sr, cH as Et, cI as Dr, b4 as kr, cJ as Ar, cg as It, cK as Er, cL as Ir, cM as Be, cN as Fr, cO as Lr, cP as Br, o as Tr, aj as Vr, ae as Rr, T as Ur, ad as Pr, aa as Mr, Z as Or, a9 as zr, cQ as _r, cR as $r, cS as jr, cT as Wr, cU as Hr, B as Gr, cV as Kr, cW as qr, a1 as Xr, cX as Yr, cY as Zr, cZ as Qr } from "./dashboard-CJNVq8XI.js";
4
- import { B, O as Ne, Z as Ze, L as te, M as Ft, d as Lt, c as X, K as Jr, E as ge, u as P, A as be, aH as gt, av as Bt, au as Qe, D as Tt, S as ut, P as Ue, a as Pe, b as Me, aI as ea, aJ as ta, aK as ra, aL as aa, aM as na, aF as sa } from "./code-editor-BpADiIlq.js";
5
- import { L as ht } from "./layout-grid-D5tYJg1-.js";
3
+ import { aH as Se, aI as De, aK as ke, bb as yt, b_ as Ht, co as Gt, cp as Kt, aZ as fe, cc as Ct, bm as Ve, y as qt, w as Xt, cq as Yt, aP as Je, aS as et, aT as tt, aU as rt, aV as at, aW as nt, aX as st, aY as wt, bl as ot, aG as O, cr as Zt, cs as Qt, ct as Ke, cd as Oe, ce as ze, cu as Nt, cf as _e, bY as K, b1 as Jt, bD as Re, cv as er, bX as tr, aJ as it, aL as lt, cw as rr, aF as ar, ba as nr, by as St, cx as sr, b$ as or, av as ir, aM as lr, b3 as cr, az as $e, at as ue, a6 as ct, a3 as Dt, a2 as dt, as as kt, a4 as dr, Y as ur, cj as hr, cy as mr, bw as pr, N as pt, R as fr, au as gr, cz as br, cA as xr, cB as vr, cC as yr, cD as Cr, cE as wr, cF as Nr, cG as Sr, cH as At, cI as Dr, b4 as kr, cJ as Ar, cg as Et, cK as Er, cL as Ir, cM as Be, cN as Fr, cO as Lr, cP as Br, o as Tr, aj as Vr, ae as Rr, T as Ur, ad as Pr, aa as Mr, Z as Or, a9 as zr, cQ as _r, cR as $r, cS as jr, cT as Wr, cU as Hr, B as Gr, cV as Kr, cW as qr, a1 as Xr, cX as Yr, cY as Zr, cZ as Qr } from "./dashboard-ECv6p6DC.js";
4
+ import { B, O as Ne, Z as Ze, L as te, M as It, d as Ft, c as X, K as Jr, E as ge, u as P, A as be, aH as ft, av as Lt, au as Qe, D as Bt, P as Ue, a as Pe, b as Me, aI as ea, aJ as ta, S as Tt, aK as ra, aL as aa, aM as na, aF as sa } from "./code-editor-B4gTfvc5.js";
5
+ import { L as ut } from "./layout-grid-D5tYJg1-.js";
6
6
  import { c as Ae, X as je, C as Vt } from "./index-xHCrHprY.js";
7
- import { u as mt, V as oa, E as qe, a as Xe, b as ia, c as la, L as ca, d as da, e as Rt, C as Ut, F as ua, f as ha } from "./editor-action-buttons-DROkx4PS.js";
8
- import "./analyze-result-contract-CfOBEwaC.js";
7
+ import { u as ht, V as oa, E as qe, a as Xe, b as ia, c as la, L as ca, d as da, e as Rt, C as Ut, F as ua, f as ha } from "./editor-action-buttons-DpA5PdEo.js";
8
+ import "./validators-wZ2WlNHc.js";
9
+ import "./analyze-result-contract-DUv3QnMl.js";
9
10
  import "../value-format-preferences/index.js";
10
11
  import { S as ma } from "./search-DHZCro8B.js";
11
- import { j as bt } from "./csv-utils-BZDvO2Fw.js";
12
+ import { M as pa } from "./mouse-pointer-2-DXNw3_3o.js";
13
+ import { y as gt } from "./pivot-result-lifecycle-BM3Pl-D1.js";
12
14
  import "./index-If0wlXGi.js";
13
- import "./comparison-document-migration-Dj6xZMCb.js";
15
+ import "./temporal-bucket-authoring-BUZMuVca.js";
16
+ import "./temporal-result-owner-Cb27SSG9.js";
14
17
  import "react-dom";
15
- import { getBriefingPresentation as se, describeBriefingSchedule as pa, getBriefingCreationIntents as fa } from "../briefings/index.js";
18
+ import { getBriefingPresentation as se, describeBriefingSchedule as fa, getBriefingCreationIntents as ga } from "../briefings/index.js";
16
19
  /**
17
20
  * @license lucide-react v0.453.0 - ISC
18
21
  *
19
22
  * This source code is licensed under the ISC license.
20
23
  * See the LICENSE file in the root directory of this source tree.
21
24
  */
22
- const ga = Ae("ArrowUpRight", [
25
+ const ba = Ae("ArrowUpRight", [
23
26
  ["path", { d: "M7 7h10v10", key: "1tivn9" }],
24
27
  ["path", { d: "M7 17 17 7", key: "1vkiza" }]
25
28
  ]);
@@ -29,7 +32,7 @@ const ga = Ae("ArrowUpRight", [
29
32
  * This source code is licensed under the ISC license.
30
33
  * See the LICENSE file in the root directory of this source tree.
31
34
  */
32
- const ba = Ae("CalendarRange", [
35
+ const xa = Ae("CalendarRange", [
33
36
  ["rect", { width: "18", height: "18", x: "3", y: "4", rx: "2", key: "1hopcy" }],
34
37
  ["path", { d: "M16 2v4", key: "4m81vk" }],
35
38
  ["path", { d: "M3 10h18", key: "8toen8" }],
@@ -45,7 +48,7 @@ const ba = Ae("CalendarRange", [
45
48
  * This source code is licensed under the ISC license.
46
49
  * See the LICENSE file in the root directory of this source tree.
47
50
  */
48
- const xa = Ae("CircleX", [
51
+ const va = Ae("CircleX", [
49
52
  ["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
50
53
  ["path", { d: "m15 9-6 6", key: "1uzhvr" }],
51
54
  ["path", { d: "m9 9 6 6", key: "z0biqf" }]
@@ -56,7 +59,7 @@ const xa = Ae("CircleX", [
56
59
  * This source code is licensed under the ISC license.
57
60
  * See the LICENSE file in the root directory of this source tree.
58
61
  */
59
- const xt = Ae("FileDown", [
62
+ const bt = Ae("FileDown", [
60
63
  ["path", { d: "M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z", key: "1rqfz7" }],
61
64
  ["path", { d: "M14 2v4a2 2 0 0 0 2 2h4", key: "tnqrlb" }],
62
65
  ["path", { d: "M12 18v-6", key: "17g6i2" }],
@@ -68,7 +71,7 @@ const xt = Ae("FileDown", [
68
71
  * This source code is licensed under the ISC license.
69
72
  * See the LICENSE file in the root directory of this source tree.
70
73
  */
71
- const va = Ae("Newspaper", [
74
+ const ya = Ae("Newspaper", [
72
75
  [
73
76
  "path",
74
77
  {
@@ -80,7 +83,7 @@ const va = Ae("Newspaper", [
80
83
  ["path", { d: "M15 18h-5", key: "95g1m2" }],
81
84
  ["path", { d: "M10 6h8v4h-8V6Z", key: "smlsk5" }]
82
85
  ]);
83
- function ya() {
86
+ function Ca() {
84
87
  return /* @__PURE__ */ e("div", { className: "space-y-1.5 py-1", children: [...Array(5)].map((t, a) => /* @__PURE__ */ r(
85
88
  "div",
86
89
  {
@@ -96,7 +99,7 @@ function ya() {
96
99
  a
97
100
  )) });
98
101
  }
99
- function Ca({
102
+ function wa({
100
103
  open: t,
101
104
  onOpenChange: a,
102
105
  onSubmit: i,
@@ -119,7 +122,7 @@ function Ca({
119
122
  children: [
120
123
  /* @__PURE__ */ r("div", { className: "flex h-10 shrink-0 items-center justify-between gap-2 border-b border-border/60 px-3", children: [
121
124
  /* @__PURE__ */ r("div", { className: "flex min-w-0 items-center gap-2", children: [
122
- /* @__PURE__ */ e(ht, { className: "h-3.5 w-3.5 shrink-0 text-muted-foreground" }),
125
+ /* @__PURE__ */ e(ut, { className: "h-3.5 w-3.5 shrink-0 text-muted-foreground" }),
123
126
  /* @__PURE__ */ r("div", { className: "flex min-w-0 items-baseline gap-2", children: [
124
127
  /* @__PURE__ */ e(ke, { className: "truncate text-[13px] font-medium leading-none tracking-normal", children: "New library visual" }),
125
128
  /* @__PURE__ */ e("span", { className: "shrink-0 text-[10px] font-medium uppercase leading-none tracking-[0.08em] text-muted-foreground", children: "Visual" })
@@ -212,22 +215,22 @@ function Mt(t, a) {
212
215
  const i = (s = t.ownership.createdBy) == null ? void 0 : s.type;
213
216
  return i === "tenant" || i === "organization" && a;
214
217
  }
215
- function pt(t, a) {
218
+ function mt(t, a) {
216
219
  var i, s;
217
220
  return Mt(t, a) ? ((i = t.ownership.createdBy) == null ? void 0 : i.name) || ((s = t.createdByTenantUserRel) == null ? void 0 : s.name) || t.lastModifiedBy || "Unknown" : "Organization";
218
221
  }
219
- function wa(t, a) {
220
- return pt(t, a).split(/\s+/).filter(Boolean).slice(0, 2).map((s) => s.charAt(0).toUpperCase()).join("") || "?";
222
+ function Na(t, a) {
223
+ return mt(t, a).split(/\s+/).filter(Boolean).slice(0, 2).map((s) => s.charAt(0).toUpperCase()).join("") || "?";
221
224
  }
222
- function Na(t) {
225
+ function Sa(t) {
223
226
  const a = (t || "").toLowerCase();
224
- return a.includes("table") ? Ft : a.includes("pie") || a.includes("donut") ? Zt : a.includes("line") ? Qt : a.includes("bar") ? Jr : ht;
227
+ return a.includes("table") ? It : a.includes("pie") || a.includes("donut") ? Zt : a.includes("line") ? Qt : a.includes("bar") ? Jr : ut;
225
228
  }
226
- function Sa({ visual: t }) {
229
+ function Da({ visual: t }) {
227
230
  const a = t.ownership.status === "public" ? "Public" : t.ownership.status === "shared" || t.ownership.sharedCount > 0 ? "Shared" : "Private";
228
231
  return /* @__PURE__ */ e("span", { className: "inline-flex items-center rounded-[4px] border border-border/60 px-1.5 py-px text-[11px] text-muted-foreground", children: a });
229
232
  }
230
- function Un({
233
+ function zn({
231
234
  open: t,
232
235
  onOpenChange: a
233
236
  }) {
@@ -239,7 +242,7 @@ function Un({
239
242
  c(/* @__PURE__ */ new Set()), d(null), f(null), p(!1), y(null);
240
243
  }, g = () => {
241
244
  a(!1), N();
242
- }, { selectVisual: S } = Ct(), { handleAddLibraryVisual: k, handleEditLibraryVisual: U } = mt(), { isConsoleMode: b } = Ht(), {
245
+ }, { selectVisual: S } = yt(), { handleAddLibraryVisual: k, handleEditLibraryVisual: U } = ht(), { isConsoleMode: b } = Ht(), {
243
246
  resources: x,
244
247
  isLoading: T,
245
248
  isError: F,
@@ -380,7 +383,7 @@ function Un({
380
383
  children: [
381
384
  /* @__PURE__ */ r("div", { className: "flex h-10 shrink-0 items-center justify-between gap-2 border-b border-border/60 px-3", children: [
382
385
  /* @__PURE__ */ r("div", { className: "flex min-w-0 items-center gap-2", children: [
383
- /* @__PURE__ */ e(Ft, { className: "h-3.5 w-3.5 shrink-0 text-muted-foreground" }),
386
+ /* @__PURE__ */ e(It, { className: "h-3.5 w-3.5 shrink-0 text-muted-foreground" }),
384
387
  /* @__PURE__ */ r("div", { className: "flex min-w-0 items-baseline gap-2", children: [
385
388
  /* @__PURE__ */ e(ke, { className: "truncate text-[13px] font-medium leading-none tracking-normal", children: "Visuals library" }),
386
389
  /* @__PURE__ */ e("span", { className: "shrink-0 text-[10px] font-medium uppercase leading-none tracking-[0.08em] text-muted-foreground", children: "Add to dashboard" })
@@ -427,12 +430,12 @@ function Un({
427
430
  }
428
431
  )
429
432
  ] }),
430
- /* @__PURE__ */ e("div", { className: "min-h-0 flex-1 overflow-auto", children: T ? /* @__PURE__ */ e("div", { className: "p-3", children: /* @__PURE__ */ e(ya, {}) }) : F ? /* @__PURE__ */ e("div", { className: "flex flex-col items-center gap-2 px-4 py-12 text-center", children: /* @__PURE__ */ e("p", { className: "text-[13px] text-destructive", children: "Failed to load visuals" }) }) : z.length === 0 ? /* @__PURE__ */ r("div", { className: "flex flex-col items-center gap-2 px-4 py-12 text-center", children: [
431
- /* @__PURE__ */ e(ht, { className: "h-5 w-5 text-muted-foreground/60" }),
433
+ /* @__PURE__ */ e("div", { className: "min-h-0 flex-1 overflow-auto", children: T ? /* @__PURE__ */ e("div", { className: "p-3", children: /* @__PURE__ */ e(Ca, {}) }) : F ? /* @__PURE__ */ e("div", { className: "flex flex-col items-center gap-2 px-4 py-12 text-center", children: /* @__PURE__ */ e("p", { className: "text-[13px] text-destructive", children: "Failed to load visuals" }) }) : z.length === 0 ? /* @__PURE__ */ r("div", { className: "flex flex-col items-center gap-2 px-4 py-12 text-center", children: [
434
+ /* @__PURE__ */ e(ut, { className: "h-5 w-5 text-muted-foreground/60" }),
432
435
  /* @__PURE__ */ e("p", { className: "text-[13px] font-medium", children: i ? "No visuals found" : "No visuals yet" }),
433
436
  /* @__PURE__ */ e("p", { className: "text-[12px] text-muted-foreground", children: i ? "Try a different search." : "Create a saved visual to add it here." })
434
437
  ] }) : /* @__PURE__ */ e(
435
- Da,
438
+ ka,
436
439
  {
437
440
  visuals: z,
438
441
  selectedIds: n,
@@ -477,7 +480,7 @@ function Un({
477
480
  onClick: Ge,
478
481
  disabled: re.length !== 1 || le.length !== 1,
479
482
  children: [
480
- /* @__PURE__ */ e(wt, { className: "h-3.5 w-3.5" }),
483
+ /* @__PURE__ */ e(Ct, { className: "h-3.5 w-3.5" }),
481
484
  "Share"
482
485
  ]
483
486
  }
@@ -515,7 +518,7 @@ function Un({
515
518
  onClick: _,
516
519
  disabled: n.size === 0,
517
520
  children: [
518
- /* @__PURE__ */ e(Lt, { className: "h-3.5 w-3.5" }),
521
+ /* @__PURE__ */ e(Ft, { className: "h-3.5 w-3.5" }),
519
522
  n.size === 0 ? "Add to dashboard" : `Add ${n.size} visual${n.size === 1 ? "" : "s"}`
520
523
  ]
521
524
  }
@@ -526,7 +529,7 @@ function Un({
526
529
  }
527
530
  ) }),
528
531
  /* @__PURE__ */ e(
529
- Ca,
532
+ wa,
530
533
  {
531
534
  open: u,
532
535
  onOpenChange: m,
@@ -575,7 +578,7 @@ function Un({
575
578
  /* @__PURE__ */ r(nt, { children: [
576
579
  /* @__PURE__ */ e(st, { disabled: G, children: "Cancel" }),
577
580
  /* @__PURE__ */ r(
578
- Nt,
581
+ wt,
579
582
  {
580
583
  onClick: (v) => {
581
584
  v.preventDefault(), Ie();
@@ -593,7 +596,7 @@ function Un({
593
596
  )
594
597
  ] });
595
598
  }
596
- function Da({
599
+ function ka({
597
600
  visuals: t,
598
601
  selectedIds: a,
599
602
  allFilteredSelected: i,
@@ -628,7 +631,7 @@ function Da({
628
631
  /* @__PURE__ */ e("span", { className: "text-right", children: "Actions" })
629
632
  ] }),
630
633
  t.map((y) => /* @__PURE__ */ e(
631
- ka,
634
+ Aa,
632
635
  {
633
636
  visual: y,
634
637
  selected: a.has(y.id),
@@ -647,7 +650,7 @@ function Da({
647
650
  ))
648
651
  ] });
649
652
  }
650
- function ka({
653
+ function Aa({
651
654
  visual: t,
652
655
  selected: a,
653
656
  onToggleSelection: i,
@@ -662,7 +665,7 @@ function ka({
662
665
  isConsoleMode: f
663
666
  }) {
664
667
  var C;
665
- const h = Na(t.kind), p = () => {
668
+ const h = Sa(t.kind), p = () => {
666
669
  s(t);
667
670
  };
668
671
  return /* @__PURE__ */ r(
@@ -712,14 +715,14 @@ function ka({
712
715
  }
713
716
  ),
714
717
  /* @__PURE__ */ r("div", { className: "flex min-w-0 items-center gap-2", children: [
715
- /* @__PURE__ */ e("div", { className: "flex h-5 w-5 shrink-0 items-center justify-center rounded-full bg-muted text-[9px] font-medium text-muted-foreground", children: wa(t, f) }),
716
- /* @__PURE__ */ e("span", { className: "truncate text-muted-foreground", children: pt(t, f) })
718
+ /* @__PURE__ */ e("div", { className: "flex h-5 w-5 shrink-0 items-center justify-center rounded-full bg-muted text-[9px] font-medium text-muted-foreground", children: Na(t, f) }),
719
+ /* @__PURE__ */ e("span", { className: "truncate text-muted-foreground", children: mt(t, f) })
717
720
  ] }),
718
721
  /* @__PURE__ */ e("span", { className: "text-muted-foreground", children: Pt(t.updatedAt) }),
719
- /* @__PURE__ */ e(Sa, { visual: t }),
722
+ /* @__PURE__ */ e(Da, { visual: t }),
720
723
  /* @__PURE__ */ e("span", { className: "text-right tabular-nums text-muted-foreground", children: t.ownership.sharedCount > 0 ? t.ownership.sharedCount : "—" }),
721
724
  /* @__PURE__ */ e(
722
- Aa,
725
+ Ea,
723
726
  {
724
727
  visual: t,
725
728
  onOpenVisual: n,
@@ -736,7 +739,7 @@ function ka({
736
739
  }
737
740
  );
738
741
  }
739
- function Aa({
742
+ function Ea({
740
743
  visual: t,
741
744
  onOpenVisual: a,
742
745
  onEditDetails: i,
@@ -772,7 +775,7 @@ function Aa({
772
775
  variant: "ghost",
773
776
  className: "w-7 px-0",
774
777
  "aria-label": "More actions",
775
- children: /* @__PURE__ */ e(St, { className: "h-3.5 w-3.5" })
778
+ children: /* @__PURE__ */ e(Nt, { className: "h-3.5 w-3.5" })
776
779
  }
777
780
  ) }),
778
781
  /* @__PURE__ */ r(
@@ -801,7 +804,7 @@ function Aa({
801
804
  "Edit details"
802
805
  ] }),
803
806
  t.permissions.canShare && /* @__PURE__ */ r(K, { onClick: () => s(t), children: [
804
- /* @__PURE__ */ e(wt, { className: "h-3.5 w-3.5" }),
807
+ /* @__PURE__ */ e(Ct, { className: "h-3.5 w-3.5" }),
805
808
  "Share"
806
809
  ] }),
807
810
  t.permissions.canDelete && /* @__PURE__ */ r(W, { children: [
@@ -823,7 +826,7 @@ function Aa({
823
826
  /* @__PURE__ */ r("div", { className: "space-y-1 px-2 py-1.5 text-[11px] text-muted-foreground", children: [
824
827
  Mt(t, l) && /* @__PURE__ */ r("div", { className: "flex items-center gap-1.5", children: [
825
828
  /* @__PURE__ */ e(er, { className: "h-3 w-3" }),
826
- /* @__PURE__ */ e("span", { className: "truncate", children: pt(t, l) })
829
+ /* @__PURE__ */ e("span", { className: "truncate", children: mt(t, l) })
827
830
  ] }),
828
831
  /* @__PURE__ */ r("div", { className: "flex items-center gap-1.5", children: [
829
832
  /* @__PURE__ */ e(tr, { className: "h-3 w-3" }),
@@ -838,7 +841,7 @@ function Aa({
838
841
  }
839
842
  );
840
843
  }
841
- function Ea({
844
+ function Ia({
842
845
  open: t,
843
846
  onOpenChange: a,
844
847
  isLibraryVisual: i,
@@ -942,8 +945,8 @@ function Ea({
942
945
  ] })
943
946
  ] }) });
944
947
  }
945
- function Ia() {
946
- const [t, a] = E(!1), [i, s] = E(!1), [n, c] = E(null), [u, m] = E(null), l = ge((b) => b.frame), d = ge((b) => b.card), o = nr(), f = P((b) => b.selectedSheetId), h = P((b) => b.dashboard), { getUpdatedFrame: p } = mt(), { selectVisual: C } = Ct(), { addFrame: y, setSelectedFrameId: D, setIsVisualEditing: I } = be(), N = Dt(), g = !!(l != null && l.visualId), S = (() => {
948
+ function Fa() {
949
+ const [t, a] = E(!1), [i, s] = E(!1), [n, c] = E(null), [u, m] = E(null), l = ge((b) => b.frame), d = ge((b) => b.card), o = nr(), f = P((b) => b.selectedSheetId), h = P((b) => b.dashboard), { getUpdatedFrame: p } = ht(), { selectVisual: C } = yt(), { addFrame: y, setSelectedFrameId: D, setIsVisualEditing: I } = be(), N = St(), g = !!(l != null && l.visualId), S = (() => {
947
950
  var b, x;
948
951
  return ((b = l == null ? void 0 : l.cards) == null ? void 0 : b.length) === 1 && ((x = l.cards[0]) != null && x.title) ? l.cards[0].title : o != null && o.title ? o.title : (d == null ? void 0 : d.title) || "Untitled Visual";
949
952
  })(), k = sr((b) => {
@@ -951,7 +954,7 @@ function Ia() {
951
954
  try {
952
955
  const x = {
953
956
  ...n,
954
- id: gt(),
957
+ id: ft(),
955
958
  visualId: b.id
956
959
  // Link to the newly created library visual
957
960
  };
@@ -977,7 +980,7 @@ function Ia() {
977
980
  O.error("No sheet selected");
978
981
  return;
979
982
  }
980
- const x = p(), T = Bt(x);
983
+ const x = p(), T = Lt(x);
981
984
  if (T) {
982
985
  O.error(T);
983
986
  return;
@@ -1019,7 +1022,7 @@ function Ia() {
1019
1022
  const A = {
1020
1023
  ...H,
1021
1024
  // Card title already synced
1022
- id: gt(),
1025
+ id: ft(),
1023
1026
  visualId: void 0
1024
1027
  // Explicitly no visualId for local visuals
1025
1028
  };
@@ -1043,15 +1046,15 @@ function Ia() {
1043
1046
  isSaving: k.isPending
1044
1047
  };
1045
1048
  }
1046
- function Pn(t = {}) {
1047
- const { isInspectionMode: a } = or(), i = ge((A) => A.frame), s = ge((A) => A.editorContext), n = ir((A) => A.selectedVisual), c = P((A) => A.selectedFrameId), u = P((A) => A.selectedSheetId), m = P((A) => A.dashboard), { setIsVisualEditing: l, updateFrame: d } = be(), [o, f] = E(!1), [h, p] = E("both"), C = Dt(), y = (s == null ? void 0 : s.type) === "documentSection", D = !!(i != null && i.visualId || n != null && n.id), I = !!(i != null && i.visualId && c), N = D && !I, {
1049
+ function _n(t = {}) {
1050
+ const { isInspectionMode: a } = or(), i = ge((A) => A.frame), s = ge((A) => A.editorContext), n = ir((A) => A.selectedVisual), c = P((A) => A.selectedFrameId), u = P((A) => A.selectedSheetId), m = P((A) => A.dashboard), { setIsVisualEditing: l, updateFrame: d } = be(), [o, f] = E(!1), [h, p] = E("both"), C = St(), y = (s == null ? void 0 : s.type) === "documentSection", D = !!(i != null && i.visualId || n != null && n.id), I = !!(i != null && i.visualId && c), N = D && !I, {
1048
1051
  saveAsDialogOpen: g,
1049
1052
  setSaveAsDialogOpen: S,
1050
1053
  handleSaveAs: k,
1051
1054
  isLibraryVisual: U,
1052
1055
  currentVisualName: b,
1053
1056
  isSaving: x
1054
- } = Ia(), { getUpdatedFrame: T } = mt();
1057
+ } = Fa(), { getUpdatedFrame: T } = ht();
1055
1058
  if (a)
1056
1059
  return /* @__PURE__ */ r(W, { children: [
1057
1060
  /* @__PURE__ */ e(
@@ -1075,7 +1078,7 @@ function Pn(t = {}) {
1075
1078
  }
1076
1079
  if (o) return;
1077
1080
  f(!0);
1078
- const A = T(), V = Bt(A);
1081
+ const A = T(), V = Lt(A);
1079
1082
  if (V) {
1080
1083
  f(!1), O.error(V);
1081
1084
  return;
@@ -1133,7 +1136,7 @@ function Pn(t = {}) {
1133
1136
  onClick: F,
1134
1137
  disabled: o,
1135
1138
  children: [
1136
- /* @__PURE__ */ e(Lt, { className: "h-3.5 w-3.5" }),
1139
+ /* @__PURE__ */ e(Ft, { className: "h-3.5 w-3.5" }),
1137
1140
  o ? "Applying..." : "Apply Locally"
1138
1141
  ]
1139
1142
  }
@@ -1180,7 +1183,7 @@ function Pn(t = {}) {
1180
1183
  ] }),
1181
1184
  /* @__PURE__ */ e(Xe, {}),
1182
1185
  /* @__PURE__ */ e(
1183
- Ea,
1186
+ Ia,
1184
1187
  {
1185
1188
  open: g,
1186
1189
  onOpenChange: (A) => {
@@ -1195,11 +1198,11 @@ function Pn(t = {}) {
1195
1198
  )
1196
1199
  ] });
1197
1200
  }
1198
- function Mn({ className: t }) {
1199
- const a = ge((d) => d.isDevMode), i = P((d) => d.isVisualEditing), { setIsDevMode: s } = Tt(), { config: n } = Wt(lr).tokenProps, c = (n == null ? void 0 : n.showAdvancedMode) !== !1;
1201
+ function $n({ className: t }) {
1202
+ const a = ge((d) => d.isDevMode), i = P((d) => d.isVisualEditing), { setIsDevMode: s } = Bt(), { config: n } = Wt(lr).tokenProps, c = (n == null ? void 0 : n.showAdvancedMode) !== !1;
1200
1203
  if (!i || !c)
1201
1204
  return null;
1202
- const u = a ? ut : cr, m = a ? "Drag & drop" : "SQL", l = a ? "Switch to drag-and-drop mode" : "Switch to SQL mode";
1205
+ const u = a ? pa : cr, m = a ? "Visual editor" : "SQL editor", l = a ? "Switch to visual editor" : "Switch to SQL editor";
1203
1206
  return /* @__PURE__ */ r(
1204
1207
  "button",
1205
1208
  {
@@ -1218,7 +1221,7 @@ function Mn({ className: t }) {
1218
1221
  }
1219
1222
  );
1220
1223
  }
1221
- function On({
1224
+ function jn({
1222
1225
  open: t,
1223
1226
  onOpenChange: a,
1224
1227
  onSave: i,
@@ -1258,12 +1261,12 @@ function On({
1258
1261
  ] })
1259
1262
  ] }) });
1260
1263
  }
1261
- const Fa = 1e4, La = 15e3, Ba = 3e4, Ta = 3e4, Va = 12e4, vt = 2 * 60 * 60 * 1e3;
1262
- function Ra(t) {
1264
+ const La = 1e4, Ba = 15e3, Ta = 3e4, Va = 3e4, Ra = 12e4, xt = 2 * 60 * 60 * 1e3;
1265
+ function Ua(t) {
1263
1266
  const a = Date.now() - t.getTime();
1264
- return a < Ta ? Fa : a < Va ? La : Ba;
1267
+ return a < Va ? La : a < Ra ? Ba : Ta;
1265
1268
  }
1266
- function zn() {
1269
+ function Wn() {
1267
1270
  const { authToken: t, tokenProps: a } = $e(), i = ue((h) => h.activeExports), [s, n] = E(
1268
1271
  typeof document < "u" ? !document.hidden : !0
1269
1272
  ), c = he(null), u = he(!1), m = he(void 0), l = a == null ? void 0 : a.apiServiceUrl, d = t == null ? void 0 : t.accessToken, o = q(() => {
@@ -1292,7 +1295,7 @@ function zn() {
1292
1295
  return;
1293
1296
  }
1294
1297
  const p = Date.now(), C = h.filter(
1295
- (g) => p - g.startedAt.getTime() > vt
1298
+ (g) => p - g.startedAt.getTime() > xt
1296
1299
  );
1297
1300
  if (C.length > 0) {
1298
1301
  const { updateExport: g } = ue.getState().actions;
@@ -1304,7 +1307,7 @@ function zn() {
1304
1307
  });
1305
1308
  }
1306
1309
  const y = h.filter(
1307
- (g) => p - g.startedAt.getTime() <= vt
1310
+ (g) => p - g.startedAt.getTime() <= xt
1308
1311
  );
1309
1312
  if (y.length === 0) {
1310
1313
  u.current = !1;
@@ -1313,7 +1316,7 @@ function zn() {
1313
1316
  const D = await Promise.allSettled(
1314
1317
  y.map(async (g) => {
1315
1318
  try {
1316
- const S = await kt(l, d, g.id);
1319
+ const S = await Dt(l, d, g.id);
1317
1320
  let k;
1318
1321
  if (S.status === "completed")
1319
1322
  try {
@@ -1350,7 +1353,7 @@ function zn() {
1350
1353
  const g = N.reduce(
1351
1354
  (k, U) => U.startedAt < k ? U.startedAt : k,
1352
1355
  N[0].startedAt
1353
- ), S = Ra(g);
1356
+ ), S = Ua(g);
1354
1357
  c.current && clearTimeout(c.current), c.current = setTimeout(() => {
1355
1358
  var k;
1356
1359
  (k = m.current) == null || k.call(m);
@@ -1377,8 +1380,8 @@ function zn() {
1377
1380
  inProgressCount: o().length
1378
1381
  };
1379
1382
  }
1380
- function _n() {
1381
- const { authToken: t, tokenProps: a } = $e(), i = ue((m) => m.activeExports), { addExport: s } = At(), n = he(!1), c = a == null ? void 0 : a.apiServiceUrl, u = t == null ? void 0 : t.accessToken;
1383
+ function Hn() {
1384
+ const { authToken: t, tokenProps: a } = $e(), i = ue((m) => m.activeExports), { addExport: s } = kt(), n = he(!1), c = a == null ? void 0 : a.apiServiceUrl, u = t == null ? void 0 : t.accessToken;
1382
1385
  J(() => {
1383
1386
  if (n.current || !c || !u) return;
1384
1387
  (async () => {
@@ -1405,7 +1408,7 @@ function _n() {
1405
1408
  id: d.id,
1406
1409
  status: d.status,
1407
1410
  progress: o,
1408
- title: Ua(d),
1411
+ title: Pa(d),
1409
1412
  totalRows: d.totalRows,
1410
1413
  totalChunks: d.totalChunks,
1411
1414
  completedChunks: d.completedChunks,
@@ -1426,12 +1429,12 @@ function _n() {
1426
1429
  })();
1427
1430
  }, [c, u, s, i]);
1428
1431
  }
1429
- function Ua(t) {
1432
+ function Pa(t) {
1430
1433
  return t.title ? t.title : ct(
1431
1434
  t.status
1432
1435
  ) ? "Export in progress..." : t.status === "completed" ? "Export completed" : t.status === "failed" ? "Export failed" : "Export";
1433
1436
  }
1434
- function Pa({
1437
+ function Ma({
1435
1438
  export: t,
1436
1439
  onRemove: a
1437
1440
  }) {
@@ -1444,7 +1447,7 @@ function Pa({
1444
1447
  case "completed":
1445
1448
  return /* @__PURE__ */ e(pr, { className: "mt-0.5 h-5 w-5 shrink-0 text-green-600" });
1446
1449
  case "failed":
1447
- return /* @__PURE__ */ e(xa, { className: "mt-0.5 h-5 w-5 shrink-0 text-destructive" });
1450
+ return /* @__PURE__ */ e(va, { className: "mt-0.5 h-5 w-5 shrink-0 text-destructive" });
1448
1451
  default:
1449
1452
  return /* @__PURE__ */ e(te, { className: "text-foreground-muted mt-0.5 h-5 w-5 shrink-0 animate-spin" });
1450
1453
  }
@@ -1496,7 +1499,7 @@ function Pa({
1496
1499
  ] }),
1497
1500
  /* @__PURE__ */ r("div", { className: "ml-8", children: [
1498
1501
  t.status === "completed" && /* @__PURE__ */ r("div", { className: "flex items-center justify-between", children: [
1499
- /* @__PURE__ */ e("span", { className: "text-xs text-muted-foreground", children: bt(t.startedAt, { addSuffix: !0 }) }),
1502
+ /* @__PURE__ */ e("span", { className: "text-xs text-muted-foreground", children: gt(t.startedAt, { addSuffix: !0 }) }),
1500
1503
  t.downloadUrl && /* @__PURE__ */ r(
1501
1504
  B,
1502
1505
  {
@@ -1518,12 +1521,12 @@ function Pa({
1518
1521
  "% complete"
1519
1522
  ] })
1520
1523
  ] }),
1521
- t.status === "failed" && /* @__PURE__ */ e("span", { className: "text-xs text-muted-foreground", children: bt(t.startedAt, { addSuffix: !0 }) })
1524
+ t.status === "failed" && /* @__PURE__ */ e("span", { className: "text-xs text-muted-foreground", children: gt(t.startedAt, { addSuffix: !0 }) })
1522
1525
  ] })
1523
1526
  ] });
1524
1527
  }
1525
- function Ma() {
1526
- const { authToken: t, tokenProps: a } = $e(), i = ue((y) => y.activeExports), { clearCompleted: s, removeExport: n, updateExport: c } = At(), [u, m] = E(!1), [l, d] = E(!1), o = Array.from(i.values()).sort(
1528
+ function Oa() {
1529
+ const { authToken: t, tokenProps: a } = $e(), i = ue((y) => y.activeExports), { clearCompleted: s, removeExport: n, updateExport: c } = kt(), [u, m] = E(!1), [l, d] = E(!1), o = Array.from(i.values()).sort(
1527
1530
  (y, D) => D.startedAt.getTime() - y.startedAt.getTime()
1528
1531
  ), f = o.some(
1529
1532
  (y) => y.status === "completed" || y.status === "failed"
@@ -1536,7 +1539,7 @@ function Ma() {
1536
1539
  await Promise.all(
1537
1540
  I.map(async (N) => {
1538
1541
  try {
1539
- const g = await kt(y, D, N.id);
1542
+ const g = await Dt(y, D, N.id);
1540
1543
  let S;
1541
1544
  if (g.status === "completed")
1542
1545
  try {
@@ -1583,7 +1586,7 @@ function Ma() {
1583
1586
  const I = o.filter(
1584
1587
  (g) => g.status === "completed" || g.status === "failed"
1585
1588
  ), N = await Promise.allSettled(
1586
- I.map(async (g) => (await ft(y, D, g.id), g.id))
1589
+ I.map(async (g) => (await pt(y, D, g.id), g.id))
1587
1590
  );
1588
1591
  for (const g of N)
1589
1592
  g.status === "fulfilled" ? n(g.value) : console.error("Failed to delete export:", g.reason);
@@ -1601,7 +1604,7 @@ function Ma() {
1601
1604
  const D = a == null ? void 0 : a.apiServiceUrl, I = t == null ? void 0 : t.accessToken;
1602
1605
  if (D && I)
1603
1606
  try {
1604
- await ft(D, I, y), n(y);
1607
+ await pt(D, I, y), n(y);
1605
1608
  return;
1606
1609
  } catch (N) {
1607
1610
  console.error(`Failed to cancel export ${y}:`, N);
@@ -1611,13 +1614,13 @@ function Ma() {
1611
1614
  [a == null ? void 0 : a.apiServiceUrl, t == null ? void 0 : t.accessToken, n]
1612
1615
  );
1613
1616
  return o.length === 0 ? /* @__PURE__ */ r("div", { className: "p-6 text-center", children: [
1614
- /* @__PURE__ */ e(xt, { className: "mx-auto mb-2 h-8 w-8 text-muted-foreground" }),
1617
+ /* @__PURE__ */ e(bt, { className: "mx-auto mb-2 h-8 w-8 text-muted-foreground" }),
1615
1618
  /* @__PURE__ */ e("p", { className: "text-sm text-muted-foreground", children: "No active exports" }),
1616
1619
  /* @__PURE__ */ e("p", { className: "mt-1 text-xs text-muted-foreground", children: "Large exports will appear here" })
1617
1620
  ] }) : /* @__PURE__ */ r("div", { className: "flex flex-col", children: [
1618
1621
  /* @__PURE__ */ r("div", { className: "flex items-center justify-between border-b px-4 py-3", children: [
1619
1622
  /* @__PURE__ */ r("div", { className: "flex items-center gap-2", children: [
1620
- /* @__PURE__ */ e(xt, { className: "h-5 w-5 text-muted-foreground" }),
1623
+ /* @__PURE__ */ e(bt, { className: "h-5 w-5 text-muted-foreground" }),
1621
1624
  /* @__PURE__ */ e("h4", { className: "font-semibold", children: "Exports" })
1622
1625
  ] }),
1623
1626
  /* @__PURE__ */ r("div", { className: "flex items-center gap-1", children: [
@@ -1652,7 +1655,7 @@ function Ma() {
1652
1655
  ] })
1653
1656
  ] }),
1654
1657
  /* @__PURE__ */ e("div", { className: "max-h-[350px] overflow-y-auto", children: /* @__PURE__ */ e("div", { className: "divide-y", children: o.map((y) => /* @__PURE__ */ e(
1655
- Pa,
1658
+ Ma,
1656
1659
  {
1657
1660
  export: y,
1658
1661
  onRemove: C
@@ -1661,7 +1664,7 @@ function Ma() {
1661
1664
  )) }) })
1662
1665
  ] });
1663
1666
  }
1664
- function $n({
1667
+ function Gn({
1665
1668
  variant: t
1666
1669
  }) {
1667
1670
  const a = ue((l) => l.activeExports), i = gr(), s = a.size > 0, n = Array.from(a.values()).some(
@@ -1687,10 +1690,10 @@ function $n({
1687
1690
  ]
1688
1691
  }
1689
1692
  ) }),
1690
- /* @__PURE__ */ e(Me, { className: "w-80 p-0", align: "end", sideOffset: 8, children: /* @__PURE__ */ e(Ma, {}) })
1693
+ /* @__PURE__ */ e(Me, { className: "w-80 p-0", align: "end", sideOffset: 8, children: /* @__PURE__ */ e(Oa, {}) })
1691
1694
  ] });
1692
1695
  }
1693
- function Oa(t) {
1696
+ function za(t) {
1694
1697
  if (t)
1695
1698
  return {
1696
1699
  renamed: t.type === "rename" ? { oldId: t.oldId, newId: t.newId } : void 0,
@@ -1699,7 +1702,7 @@ function Oa(t) {
1699
1702
  affectedBindingControlIds: t.type === "add" || t.type === "update" ? t.affectedBindingControlIds : void 0
1700
1703
  };
1701
1704
  }
1702
- function za({
1705
+ function _a({
1703
1706
  open: t,
1704
1707
  onOpenChange: a,
1705
1708
  trigger: i,
@@ -1761,7 +1764,7 @@ function za({
1761
1764
  p(
1762
1765
  x,
1763
1766
  T,
1764
- Oa(F)
1767
+ za(F)
1765
1768
  );
1766
1769
  }, S = q(() => {
1767
1770
  if (c) {
@@ -1796,7 +1799,7 @@ function za({
1796
1799
  ] });
1797
1800
  return s ? /* @__PURE__ */ r(Ue, { open: o, onOpenChange: m, children: [
1798
1801
  /* @__PURE__ */ e(Pe, { asChild: !0, children: i || /* @__PURE__ */ r(B, { variant: "outline", className: "h-7 px-2", size: "sm", children: [
1799
- /* @__PURE__ */ e(ut, { className: "mr-2 h-4 w-4" }),
1802
+ /* @__PURE__ */ e(Tt, { className: "mr-2 h-4 w-4" }),
1800
1803
  "Controls"
1801
1804
  ] }) }),
1802
1805
  /* @__PURE__ */ e(
@@ -1837,7 +1840,7 @@ function za({
1837
1840
  }
1838
1841
  ) });
1839
1842
  }
1840
- const _a = [
1843
+ const $a = [
1841
1844
  "enum",
1842
1845
  "multi_enum",
1843
1846
  "text",
@@ -1845,7 +1848,7 @@ const _a = [
1845
1848
  "boolean",
1846
1849
  "date"
1847
1850
  ];
1848
- function $a({
1851
+ function ja({
1849
1852
  open: t,
1850
1853
  onOpenChange: a,
1851
1854
  initialMode: i = "manage"
@@ -1877,10 +1880,10 @@ function $a({
1877
1880
  () => D.map((x) => x.control),
1878
1881
  [D]
1879
1882
  ), N = ee(
1880
- () => Wa(I),
1883
+ () => Ha(I),
1881
1884
  [I]
1882
1885
  ), g = ee(
1883
- () => ja(o),
1886
+ () => Wa(o),
1884
1887
  [o]
1885
1888
  ), S = q(() => {
1886
1889
  if (s) {
@@ -1891,7 +1894,7 @@ function $a({
1891
1894
  }, [s, n, d]), k = q(
1892
1895
  (x, T, F) => {
1893
1896
  !C || !(p != null && p.document) || h(
1894
- Ga({
1897
+ Ka({
1895
1898
  allInputs: o.inputs || [],
1896
1899
  documentSheetId: p.id,
1897
1900
  currentDocumentInputs: y,
@@ -1938,7 +1941,7 @@ function $a({
1938
1941
  availableMetricChoices: [],
1939
1942
  structuralParticipants: [],
1940
1943
  structuralParticipantIdsByControlId: {},
1941
- allowedControlTypes: _a,
1944
+ allowedControlTypes: $a,
1942
1945
  initialCreateFlow: i === "create",
1943
1946
  onCreateFlowActiveChange: d,
1944
1947
  onCreateFlowComplete: S,
@@ -1950,22 +1953,22 @@ function $a({
1950
1953
  }
1951
1954
  ) });
1952
1955
  }
1953
- function ja(t) {
1956
+ function Wa(t) {
1954
1957
  return (t.controls || []).map((a) => a.id);
1955
1958
  }
1956
- function Wa(t) {
1959
+ function Ha(t) {
1957
1960
  const a = {};
1958
1961
  for (const i of t)
1959
1962
  i.defaultValue !== void 0 && (a[i.id] = i.defaultValue);
1960
1963
  return a;
1961
1964
  }
1962
- function Ha(t, a) {
1965
+ function Ga(t, a) {
1963
1966
  return a ? Object.prototype.hasOwnProperty.call(a, t.id) ? {
1964
1967
  ...t,
1965
1968
  defaultValue: a[t.id]
1966
1969
  } : t.defaultValue === void 0 ? t : { ...t, defaultValue: void 0 } : t.defaultValue === void 0 ? t : { ...t, defaultValue: void 0 };
1967
1970
  }
1968
- function Ga({
1971
+ function Ka({
1969
1972
  allInputs: t,
1970
1973
  documentSheetId: a,
1971
1974
  currentDocumentInputs: i,
@@ -1976,7 +1979,7 @@ function Ga({
1976
1979
  const u = new Map(
1977
1980
  s.map((h) => [
1978
1981
  h.id,
1979
- Ha(h, n)
1982
+ Ga(h, n)
1980
1983
  ])
1981
1984
  ), m = (c == null ? void 0 : c.type) === "rename" ? { oldId: c.oldId, newId: c.newId } : null, l = /* @__PURE__ */ new Set(), d = [];
1982
1985
  for (const h of i) {
@@ -2017,7 +2020,7 @@ function Ga({
2017
2020
  (h) => !o.has(h.id)
2018
2021
  ), ...d];
2019
2022
  }
2020
- function Ka({
2023
+ function qa({
2021
2024
  showFilters: t,
2022
2025
  onShowFiltersChange: a,
2023
2026
  pickerContent: i,
@@ -2053,7 +2056,7 @@ function Ka({
2053
2056
  u
2054
2057
  ),
2055
2058
  children: [
2056
- t ? /* @__PURE__ */ e(ua, { className: "h-3.5 w-3.5" }) : /* @__PURE__ */ e(Et, { className: "h-3.5 w-3.5" }),
2059
+ t ? /* @__PURE__ */ e(ua, { className: "h-3.5 w-3.5" }) : /* @__PURE__ */ e(At, { className: "h-3.5 w-3.5" }),
2057
2060
  "Filter"
2058
2061
  ]
2059
2062
  }
@@ -2104,9 +2107,9 @@ function Ka({
2104
2107
  }
2105
2108
  );
2106
2109
  }
2107
- function qa() {
2110
+ function Xa() {
2108
2111
  ha();
2109
- const t = P((l) => l.selectedSheetId), a = P((l) => l.selectedFrameId), i = P((l) => l.dashboard), s = P((l) => l.actions.getSelectedFrame), { setSelectedFrameId: n } = be(), { setCard: c } = Tt(), u = ge((l) => l.card.dataSource);
2112
+ const t = P((l) => l.selectedSheetId), a = P((l) => l.selectedFrameId), i = P((l) => l.dashboard), s = P((l) => l.actions.getSelectedFrame), { setSelectedFrameId: n } = be(), { setCard: c } = Bt(), u = ge((l) => l.card.dataSource);
2110
2113
  return J(() => {
2111
2114
  var d, o;
2112
2115
  let l = s();
@@ -2122,10 +2125,10 @@ function qa() {
2122
2125
  hasEntities: !!(u != null && u.selectedEntities && u.selectedEntities.length > 0)
2123
2126
  };
2124
2127
  }
2125
- function Xa() {
2128
+ function Ya() {
2126
2129
  const t = P((l) => l.dashboard), a = P(
2127
2130
  (l) => l.semanticExecutionPayload
2128
- ), i = P((l) => l.actions.addFilter), { hasEntities: s } = qa(), { isLoading: n } = Dr(), c = ee(
2131
+ ), i = P((l) => l.actions.addFilter), { hasEntities: s } = Xa(), { isLoading: n } = Dr(), c = ee(
2129
2132
  () => ra(t, a),
2130
2133
  [t, a]
2131
2134
  ), m = !aa(t.filters) && c.hasEligibleCards && !n;
@@ -2138,7 +2141,7 @@ function Xa() {
2138
2141
  title: `Applies to ${c.eligibleCardCount} of ${c.totalCardCount} date-aware cards`,
2139
2142
  className: "flex w-full items-start gap-2 rounded-[4px] px-2 py-1.5 text-left outline-none transition-colors hover:bg-muted/40 focus-visible:bg-muted/40 focus-visible:ring-1 focus-visible:ring-inset focus-visible:ring-border",
2140
2143
  children: [
2141
- /* @__PURE__ */ e(ba, { className: "mt-0.5 h-3.5 w-3.5 shrink-0 text-muted-foreground" }),
2144
+ /* @__PURE__ */ e(xa, { className: "mt-0.5 h-3.5 w-3.5 shrink-0 text-muted-foreground" }),
2142
2145
  /* @__PURE__ */ r("span", { className: "flex min-w-0 flex-col", children: [
2143
2146
  /* @__PURE__ */ e("span", { className: "text-[12px] font-medium text-foreground", children: "Add global date filter" }),
2144
2147
  /* @__PURE__ */ e("span", { className: "text-[11px] leading-[1.4] text-muted-foreground", children: "One date range across all date-aware cards." })
@@ -2154,8 +2157,8 @@ function Xa() {
2154
2157
  s && /* @__PURE__ */ e("div", { className: "flex flex-1 overflow-hidden", children: /* @__PURE__ */ e(Ar, { context: "filter" }) })
2155
2158
  ] });
2156
2159
  }
2157
- const yt = !1;
2158
- function Ya({
2160
+ const vt = !1;
2161
+ function Za({
2159
2162
  onAddFilter: t,
2160
2163
  onAddControl: a,
2161
2164
  onManageControls: i,
@@ -2171,7 +2174,7 @@ function Ya({
2171
2174
  /* @__PURE__ */ e(
2172
2175
  Ye,
2173
2176
  {
2174
- icon: Et,
2177
+ icon: At,
2175
2178
  label: "Add filter",
2176
2179
  onClick: () => {
2177
2180
  t(), s();
@@ -2181,7 +2184,7 @@ function Ya({
2181
2184
  /* @__PURE__ */ e(
2182
2185
  Ye,
2183
2186
  {
2184
- icon: ut,
2187
+ icon: Tt,
2185
2188
  label: "Add control",
2186
2189
  onClick: () => {
2187
2190
  a(), s();
@@ -2191,7 +2194,7 @@ function Ya({
2191
2194
  /* @__PURE__ */ e(
2192
2195
  Ye,
2193
2196
  {
2194
- icon: It,
2197
+ icon: Et,
2195
2198
  label: "Manage controls",
2196
2199
  onClick: () => {
2197
2200
  i(), s();
@@ -2202,9 +2205,9 @@ function Ya({
2202
2205
  /* @__PURE__ */ e("div", { className: "border-t border-border/60" }),
2203
2206
  /* @__PURE__ */ r("div", { className: "space-y-1 p-2", children: [
2204
2207
  /* @__PURE__ */ e("p", { className: "px-1 text-[10px] font-medium uppercase tracking-[0.08em] text-muted-foreground", children: "Display" }),
2205
- yt,
2208
+ vt,
2206
2209
  /* @__PURE__ */ e(
2207
- Za,
2210
+ Qa,
2208
2211
  {
2209
2212
  id: "filter-display-wrap",
2210
2213
  label: "Wrap to multiple lines",
@@ -2212,7 +2215,7 @@ function Ya({
2212
2215
  onCheckedChange: (m) => c({ toolbarWrap: m === !0 })
2213
2216
  }
2214
2217
  ),
2215
- yt
2218
+ vt
2216
2219
  ] })
2217
2220
  ] });
2218
2221
  }
@@ -2234,7 +2237,7 @@ function Ye({
2234
2237
  }
2235
2238
  );
2236
2239
  }
2237
- function Za({
2240
+ function Qa({
2238
2241
  id: t,
2239
2242
  label: a,
2240
2243
  checked: i,
@@ -2252,7 +2255,7 @@ function Za({
2252
2255
  )
2253
2256
  ] });
2254
2257
  }
2255
- function jn({
2258
+ function Kn({
2256
2259
  size: t,
2257
2260
  className: a,
2258
2261
  primaryButtonClassName: i,
@@ -2291,13 +2294,13 @@ function jn({
2291
2294
  }, [I]);
2292
2295
  return /* @__PURE__ */ r(W, { children: [
2293
2296
  /* @__PURE__ */ e(
2294
- Ka,
2297
+ qa,
2295
2298
  {
2296
2299
  showFilters: D ? !1 : o,
2297
2300
  onShowFiltersChange: N,
2298
- pickerContent: /* @__PURE__ */ e(Xa, {}),
2301
+ pickerContent: /* @__PURE__ */ e(Ya, {}),
2299
2302
  settingsContent: (b) => /* @__PURE__ */ e(
2300
- Ya,
2303
+ Za,
2301
2304
  {
2302
2305
  onAddFilter: g,
2303
2306
  onAddControl: S,
@@ -2314,7 +2317,7 @@ function jn({
2314
2317
  }
2315
2318
  ),
2316
2319
  u ? D ? /* @__PURE__ */ e(
2317
- $a,
2320
+ ja,
2318
2321
  {
2319
2322
  open: !0,
2320
2323
  onOpenChange: (b) => {
@@ -2323,7 +2326,7 @@ function jn({
2323
2326
  initialMode: u
2324
2327
  }
2325
2328
  ) : /* @__PURE__ */ e(
2326
- za,
2329
+ _a,
2327
2330
  {
2328
2331
  open: !0,
2329
2332
  onOpenChange: (b) => {
@@ -2335,7 +2338,7 @@ function jn({
2335
2338
  ) : null
2336
2339
  ] });
2337
2340
  }
2338
- function Qa({
2341
+ function Ja({
2339
2342
  disabled: t,
2340
2343
  briefingCount: a,
2341
2344
  className: i,
@@ -2353,18 +2356,18 @@ function Qa({
2353
2356
  onClick: s,
2354
2357
  "aria-label": "Reports & briefings",
2355
2358
  children: [
2356
- /* @__PURE__ */ e(va, { className: "h-3.5 w-3.5" }),
2359
+ /* @__PURE__ */ e(ya, { className: "h-3.5 w-3.5" }),
2357
2360
  "Reports & briefings",
2358
2361
  n ? /* @__PURE__ */ e("span", { className: "ml-0.5 rounded-control bg-muted px-1 text-[10px] tabular-nums text-foreground/70", children: a }) : null
2359
2362
  ]
2360
2363
  }
2361
2364
  );
2362
2365
  }
2363
- const Ja = "text-[10px] font-medium uppercase tracking-[0.08em] text-muted-foreground", Ot = "inline-flex h-7 items-center gap-1.5 rounded-control px-2 text-[12px] text-muted-foreground hover:bg-muted hover:text-foreground disabled:opacity-50", Te = "inline-flex h-7 items-center gap-1.5 rounded-control bg-primary px-3 text-[12px] font-medium text-primary-foreground hover:bg-primary/90 disabled:opacity-50";
2364
- function en(t) {
2366
+ const en = "text-[10px] font-medium uppercase tracking-[0.08em] text-muted-foreground", Ot = "inline-flex h-7 items-center gap-1.5 rounded-control px-2 text-[12px] text-muted-foreground hover:bg-muted hover:text-foreground disabled:opacity-50", Te = "inline-flex h-7 items-center gap-1.5 rounded-control bg-primary px-3 text-[12px] font-medium text-primary-foreground hover:bg-primary/90 disabled:opacity-50";
2367
+ function tn(t) {
2365
2368
  return t === "dashboard" ? "This dashboard" : "Project";
2366
2369
  }
2367
- function tn(t) {
2370
+ function rn(t) {
2368
2371
  if (!t) return "Never";
2369
2372
  const a = new Date(t);
2370
2373
  if (Number.isNaN(a.getTime())) return "Unknown";
@@ -2378,13 +2381,13 @@ function tn(t) {
2378
2381
  const u = Math.round(c / 7);
2379
2382
  return u < 5 ? `${u}w ago` : `${Math.round(c / 30)}mo ago`;
2380
2383
  }
2381
- function rn(t) {
2382
- return t.scheduleExpr ? pa(
2384
+ function an(t) {
2385
+ return t.scheduleExpr ? fa(
2383
2386
  t.scheduleExpr,
2384
2387
  t.timezone || "UTC"
2385
2388
  ) ?? "Invalid schedule" : "On demand";
2386
2389
  }
2387
- function an(t) {
2390
+ function nn(t) {
2388
2391
  if (t.lastRunStatus) {
2389
2392
  const a = t.lastRunStatus.toString().toUpperCase();
2390
2393
  return a === "SUCCESS" ? "Last run completed." : a === "FAILED" ? "Last run failed." : `Last run ${t.lastRunStatus.toString().toLowerCase()}`;
@@ -2394,10 +2397,10 @@ function an(t) {
2394
2397
  function zt(t) {
2395
2398
  return t.hasActiveRun ? "Running" : t.lastRunStatus ? `Last run ${t.lastRunStatus.toString().toLowerCase()}` : "Idle";
2396
2399
  }
2397
- function nn(t) {
2400
+ function sn(t) {
2398
2401
  return t.source.type === "dashboard" ? "This dashboard" : "Project";
2399
2402
  }
2400
- function sn({
2403
+ function on({
2401
2404
  activeView: t,
2402
2405
  onChange: a
2403
2406
  }) {
@@ -2420,7 +2423,7 @@ function sn({
2420
2423
  "h-6 rounded-[3px] px-2 text-[11px] transition-colors",
2421
2424
  s ? "bg-background font-medium text-foreground shadow-sm" : "text-muted-foreground hover:text-foreground"
2422
2425
  ),
2423
- children: en(i)
2426
+ children: tn(i)
2424
2427
  },
2425
2428
  i
2426
2429
  );
@@ -2428,7 +2431,7 @@ function sn({
2428
2431
  }
2429
2432
  );
2430
2433
  }
2431
- function on({
2434
+ function ln({
2432
2435
  briefings: t,
2433
2436
  dashboardLabel: a,
2434
2437
  sourceView: i,
@@ -2459,7 +2462,7 @@ function on({
2459
2462
  children: [
2460
2463
  g ? null : /* @__PURE__ */ r("header", { className: "flex items-start justify-between gap-3 border-b border-border px-4 py-3", children: [
2461
2464
  /* @__PURE__ */ r("div", { className: "min-w-0", children: [
2462
- /* @__PURE__ */ e("div", { className: Ja, children: x }),
2465
+ /* @__PURE__ */ e("div", { className: en, children: x }),
2463
2466
  /* @__PURE__ */ e("h2", { className: "mt-0.5 truncate text-[14px] font-semibold leading-5", children: T })
2464
2467
  ] }),
2465
2468
  /* @__PURE__ */ e(
@@ -2476,7 +2479,7 @@ function on({
2476
2479
  /* @__PURE__ */ r("div", { className: "flex items-center justify-between gap-3 border-b border-border px-4 py-2", children: [
2477
2480
  /* @__PURE__ */ r("div", { className: "flex min-w-0 items-center gap-3", children: [
2478
2481
  /* @__PURE__ */ e(
2479
- sn,
2482
+ on,
2480
2483
  {
2481
2484
  activeView: i,
2482
2485
  onChange: c
@@ -2558,7 +2561,7 @@ function on({
2558
2561
  /* @__PURE__ */ r("div", { className: "flex-1 overflow-y-auto", children: [
2559
2562
  s ? /* @__PURE__ */ e("div", { className: "m-4 rounded-card border border-destructive/30 bg-destructive/10 px-3 py-2 text-[12px] text-destructive", children: s }) : null,
2560
2563
  !n && t.length === 0 && !s ? /* @__PURE__ */ e(
2561
- ln,
2564
+ cn,
2562
2565
  {
2563
2566
  onNew: l,
2564
2567
  canCreate: d,
@@ -2568,7 +2571,7 @@ function on({
2568
2571
  }
2569
2572
  ) : null,
2570
2573
  t.map((F) => /* @__PURE__ */ e(
2571
- dn,
2574
+ un,
2572
2575
  {
2573
2576
  briefing: F,
2574
2577
  isOpening: y === F.id,
@@ -2588,7 +2591,7 @@ function on({
2588
2591
  className: X(Ot, "h-6 px-1 text-[11px]"),
2589
2592
  children: [
2590
2593
  "Manage all reports & briefings",
2591
- /* @__PURE__ */ e(ga, { className: "h-3 w-3" })
2594
+ /* @__PURE__ */ e(ba, { className: "h-3 w-3" })
2592
2595
  ]
2593
2596
  }
2594
2597
  ) }) : null
@@ -2596,7 +2599,7 @@ function on({
2596
2599
  }
2597
2600
  );
2598
2601
  }
2599
- function ln({
2602
+ function cn({
2600
2603
  onNew: t,
2601
2604
  canCreate: a,
2602
2605
  canCreateScheduledReport: i,
@@ -2611,7 +2614,7 @@ function ln({
2611
2614
  description: "Create an analytical briefing to monitor this dashboard and brief your team."
2612
2615
  } : null;
2613
2616
  return /* @__PURE__ */ r("div", { className: "flex h-full flex-col items-center justify-center px-8 py-12 text-center", children: [
2614
- /* @__PURE__ */ e(cn, { className: "mb-5 h-[88px] w-[112px] text-border" }),
2617
+ /* @__PURE__ */ e(dn, { className: "mb-5 h-[88px] w-[112px] text-border" }),
2615
2618
  /* @__PURE__ */ e("div", { className: "text-[13px] font-medium text-foreground", children: (c == null ? void 0 : c.title) ?? "Have an analyst brief your team" }),
2616
2619
  /* @__PURE__ */ e("p", { className: "mt-1.5 max-w-[320px] text-[12px] leading-5 text-muted-foreground", children: (c == null ? void 0 : c.description) ?? "Describe what to watch. An analyst digs into this dashboard and the data behind it, then briefs your team on the cadence you choose." }),
2617
2620
  a ? /* @__PURE__ */ r("div", { className: "mt-4 flex flex-wrap justify-center gap-2", children: [
@@ -2637,7 +2640,7 @@ function ln({
2637
2640
  ] }) : null
2638
2641
  ] });
2639
2642
  }
2640
- function cn({ className: t }) {
2643
+ function dn({ className: t }) {
2641
2644
  return /* @__PURE__ */ r(
2642
2645
  "svg",
2643
2646
  {
@@ -2814,7 +2817,7 @@ function cn({ className: t }) {
2814
2817
  }
2815
2818
  );
2816
2819
  }
2817
- function dn({
2820
+ function un({
2818
2821
  briefing: t,
2819
2822
  isOpening: a,
2820
2823
  isBusy: i,
@@ -2823,7 +2826,7 @@ function dn({
2823
2826
  onTogglePause: c,
2824
2827
  onDelete: u
2825
2828
  }) {
2826
- const m = t.status === "PAUSED", l = t.hasActiveRun, d = an(t), o = tn(t.lastRunAt), f = t.lastRunStatus, h = se(t), p = f === "SUCCESS" ? Be.success.dot : f === "FAILED" ? Be.danger.dot : f ? Be.warning.dot : Be.neutral.dot;
2829
+ const m = t.status === "PAUSED", l = t.hasActiveRun, d = nn(t), o = rn(t.lastRunAt), f = t.lastRunStatus, h = se(t), p = f === "SUCCESS" ? Be.success.dot : f === "FAILED" ? Be.danger.dot : f ? Be.warning.dot : Be.neutral.dot;
2827
2830
  return /* @__PURE__ */ r(
2828
2831
  "div",
2829
2832
  {
@@ -2850,10 +2853,10 @@ function dn({
2850
2853
  /* @__PURE__ */ r("div", { className: "mt-1 flex flex-wrap items-center gap-x-1.5 text-[11px] text-muted-foreground", children: [
2851
2854
  /* @__PURE__ */ e("span", { children: h.typeLabel }),
2852
2855
  /* @__PURE__ */ e("span", { className: "text-border", children: "·" }),
2853
- /* @__PURE__ */ e("span", { children: nn(t) }),
2856
+ /* @__PURE__ */ e("span", { children: sn(t) }),
2854
2857
  /* @__PURE__ */ e("span", { className: "text-border", children: "·" }),
2855
2858
  /* @__PURE__ */ e(Ir, { className: "h-3 w-3" }),
2856
- /* @__PURE__ */ e("span", { className: "truncate", children: rn(t) }),
2859
+ /* @__PURE__ */ e("span", { className: "truncate", children: an(t) }),
2857
2860
  t.lastRunAt ? /* @__PURE__ */ r(W, { children: [
2858
2861
  /* @__PURE__ */ e("span", { className: "text-border", children: "·" }),
2859
2862
  /* @__PURE__ */ r("span", { children: [
@@ -2885,12 +2888,12 @@ function dn({
2885
2888
  onClick: (C) => C.stopPropagation(),
2886
2889
  className: "inline-flex h-6 w-6 items-center justify-center rounded-control text-muted-foreground/70 opacity-60 hover:bg-muted hover:text-foreground/80 focus-visible:opacity-100 group-hover:opacity-100",
2887
2890
  "aria-label": `${h.noun === "report" ? "Report" : "Briefing"} actions`,
2888
- children: /* @__PURE__ */ e(St, { className: "h-3.5 w-3.5" })
2891
+ children: /* @__PURE__ */ e(Nt, { className: "h-3.5 w-3.5" })
2889
2892
  }
2890
2893
  ) }),
2891
2894
  /* @__PURE__ */ r(_e, { align: "end", className: "w-44", children: [
2892
2895
  /* @__PURE__ */ r(K, { onClick: s, children: [
2893
- /* @__PURE__ */ e(It, { className: "h-3.5 w-3.5" }),
2896
+ /* @__PURE__ */ e(Et, { className: "h-3.5 w-3.5" }),
2894
2897
  "Edit ",
2895
2898
  h.noun
2896
2899
  ] }),
@@ -2942,19 +2945,19 @@ function dn({
2942
2945
  }
2943
2946
  );
2944
2947
  }
2945
- const un = 2e3, hn = 20 * 6e4;
2946
- function mn(t) {
2948
+ const hn = 2e3, mn = 20 * 6e4;
2949
+ function pn(t) {
2947
2950
  return (t == null ? void 0 : t.trim()) || "This dashboard";
2948
2951
  }
2949
- function pn(t) {
2952
+ function fn(t) {
2950
2953
  return t === "This dashboard" ? "Watch this dashboard" : `Watch ${t}`;
2951
2954
  }
2952
- function fn(t, a, i) {
2955
+ function gn(t, a, i) {
2953
2956
  return a !== "dashboard" ? t : t.filter(
2954
2957
  (s) => s.source.type === "dashboard" && s.source.dashboardId === i
2955
2958
  );
2956
2959
  }
2957
- async function gn(t) {
2960
+ async function bn(t) {
2958
2961
  const i = [];
2959
2962
  let s = 1, n = 0, c = Number.POSITIVE_INFINITY;
2960
2963
  for (; n < c; ) {
@@ -2968,7 +2971,7 @@ async function gn(t) {
2968
2971
  }
2969
2972
  return i;
2970
2973
  }
2971
- const bn = {
2974
+ const xn = {
2972
2975
  listBriefings: zr,
2973
2976
  getBriefing: Or,
2974
2977
  pauseBriefing: Mr,
@@ -2976,7 +2979,7 @@ const bn = {
2976
2979
  deleteBriefing: Ur,
2977
2980
  runBriefingNow: Rr
2978
2981
  };
2979
- function xn({
2982
+ function vn({
2980
2983
  briefingId: t,
2981
2984
  initialRun: a,
2982
2985
  apiServiceUrl: i,
@@ -2988,8 +2991,8 @@ function xn({
2988
2991
  const [m, l] = E(a), { startRun: d } = qr({
2989
2992
  apiServiceUrl: i,
2990
2993
  token: s,
2991
- intervalMs: un,
2992
- timeoutMs: hn,
2994
+ intervalMs: hn,
2995
+ timeoutMs: mn,
2993
2996
  fetchRun: ({
2994
2997
  apiServiceUrl: f,
2995
2998
  token: h,
@@ -3009,10 +3012,10 @@ function xn({
3009
3012
  o.current || (o.current = !0, Yr(a.status) ? d(a) : Zr(a.status) && n(a));
3010
3013
  }, [a, n, d]), /* @__PURE__ */ e(Qr, { run: m, onExpand: u });
3011
3014
  }
3012
- function Wn(t) {
3013
- return /* @__PURE__ */ e(Tr, { children: /* @__PURE__ */ e(vn, { ...t }) });
3015
+ function qn(t) {
3016
+ return /* @__PURE__ */ e(Tr, { children: /* @__PURE__ */ e(yn, { ...t }) });
3014
3017
  }
3015
- function vn({
3018
+ function yn({
3016
3019
  dashboardId: t,
3017
3020
  dashboardTitle: a,
3018
3021
  apiServiceUrl: i,
@@ -3043,8 +3046,8 @@ function vn({
3043
3046
  }, [N, o]);
3044
3047
  const [ce, me] = E(
3045
3048
  null
3046
- ), [Q, Ce] = E(null), _ = i ?? (p == null ? void 0 : p.apiServiceUrl), $ = s ?? (h == null ? void 0 : h.accessToken), ne = ee(() => ({ ...bn, ...f }), [f]), pe = mn(a), Ie = ee(() => {
3047
- const w = fn(
3049
+ ), [Q, Ce] = E(null), _ = i ?? (p == null ? void 0 : p.apiServiceUrl), $ = s ?? (h == null ? void 0 : h.accessToken), ne = ee(() => ({ ...xn, ...f }), [f]), pe = pn(a), Ie = ee(() => {
3050
+ const w = gn(
3048
3051
  F,
3049
3052
  x,
3050
3053
  t
@@ -3058,12 +3061,12 @@ function vn({
3058
3061
  }, [t, F, x, o]), Ge = ee(() => x === "dashboard" ? {
3059
3062
  source: { type: "dashboard", dashboardId: t },
3060
3063
  label: pe,
3061
- detail: pn(pe)
3064
+ detail: fn(pe)
3062
3065
  } : {
3063
3066
  source: { type: "project" },
3064
3067
  label: "This project",
3065
3068
  detail: "Use any data in this project."
3066
- }, [t, pe, x]), we = !!(_ && $), de = fa({
3069
+ }, [t, pe, x]), we = !!(_ && $), de = ga({
3067
3070
  canCreate: C.canCreate,
3068
3071
  analyticalBriefingsEnabled: C.analyticalBriefingsEnabled,
3069
3072
  scheduledReportAvailable: x === "dashboard"
@@ -3072,7 +3075,7 @@ function vn({
3072
3075
  G(!0), le(null);
3073
3076
  try {
3074
3077
  H(
3075
- await gn({
3078
+ await bn({
3076
3079
  apiClient: ne,
3077
3080
  apiServiceUrl: _,
3078
3081
  token: $
@@ -3120,7 +3123,7 @@ function vn({
3120
3123
  _,
3121
3124
  $,
3122
3125
  w.id,
3123
- { requestId: yn() }
3126
+ { requestId: Cn() }
3124
3127
  ), Y();
3125
3128
  } catch (R) {
3126
3129
  O.error(
@@ -3176,7 +3179,7 @@ function vn({
3176
3179
  }, $t = Ie.length;
3177
3180
  return C.surfaceVisible ? /* @__PURE__ */ r(_r, { open: N, onOpenChange: g, children: [
3178
3181
  d ? null : /* @__PURE__ */ e(
3179
- Qa,
3182
+ Ja,
3180
3183
  {
3181
3184
  disabled: n || !we,
3182
3185
  briefingCount: $t,
@@ -3255,7 +3258,7 @@ function vn({
3255
3258
  )
3256
3259
  ] }) : null,
3257
3260
  j === "list" ? /* @__PURE__ */ e(
3258
- on,
3261
+ ln,
3259
3262
  {
3260
3263
  briefings: Ie,
3261
3264
  dashboardLabel: pe,
@@ -3319,7 +3322,7 @@ function vn({
3319
3322
  }
3320
3323
  ),
3321
3324
  ce && _ && $ ? /* @__PURE__ */ e(
3322
- xn,
3325
+ vn,
3323
3326
  {
3324
3327
  briefingId: ce.briefing.id,
3325
3328
  initialRun: ce.run,
@@ -3380,7 +3383,7 @@ function vn({
3380
3383
  /* @__PURE__ */ r(nt, { children: [
3381
3384
  /* @__PURE__ */ e(st, { children: "Cancel" }),
3382
3385
  /* @__PURE__ */ r(
3383
- Nt,
3386
+ wt,
3384
3387
  {
3385
3388
  className: "bg-destructive/90 hover:bg-destructive",
3386
3389
  onClick: _t,
@@ -3397,23 +3400,23 @@ function vn({
3397
3400
  )
3398
3401
  ] }) : null;
3399
3402
  }
3400
- function yn() {
3403
+ function Cn() {
3401
3404
  return typeof crypto < "u" && typeof crypto.randomUUID == "function" ? crypto.randomUUID() : `briefing-run-now-${Date.now()}-${Math.random().toString(36).slice(2, 8)}`;
3402
3405
  }
3403
3406
  export {
3404
- Mn as A,
3405
- Wn as D,
3406
- Pa as E,
3407
- $n as N,
3408
- On as U,
3409
- Pn as V,
3410
- Qa as W,
3411
- za as a,
3412
- Ka as b,
3413
- jn as c,
3414
- $a as d,
3415
- Ma as e,
3416
- Un as f,
3417
- _n as g,
3418
- zn as u
3407
+ $n as A,
3408
+ qn as D,
3409
+ Ma as E,
3410
+ Gn as N,
3411
+ jn as U,
3412
+ _n as V,
3413
+ Ja as W,
3414
+ _a as a,
3415
+ qa as b,
3416
+ Kn as c,
3417
+ ja as d,
3418
+ Oa as e,
3419
+ zn as f,
3420
+ Hn as g,
3421
+ Wn as u
3419
3422
  };