react-semaphor 0.1.526 → 0.1.528

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 (180) hide show
  1. package/DATA_APP_SDK.md +5 -1
  2. package/dist/analytics-protocol/index.js +1190 -296
  3. package/dist/brand-studio/index.js +15 -15
  4. package/dist/briefings/index.js +50 -49
  5. package/dist/chunks/{calculated-field-identity-D1ofR4KJ.js → calculated-field-identity-DUu-tCQw.js} +66 -65
  6. package/dist/chunks/{card-config-utils-9sv4e-Vb.js → card-config-utils-BdPceiw8.js} +68 -65
  7. package/dist/chunks/{constants-DeLIHVAW.js → constants-DNWVy8Y3.js} +4 -4
  8. package/dist/chunks/dashboard-BkskKMck.js +14 -0
  9. package/dist/chunks/{dashboard-briefing-launcher-DXz1GhFZ.js → dashboard-briefing-launcher-Bb0RhGRC.js} +372 -359
  10. package/dist/chunks/{dashboard-controls-Df8qOSrs.js → dashboard-controls-loWTHPMi.js} +739 -686
  11. package/dist/chunks/{dashboard-json-Xldp0qww.js → dashboard-json-DUci_SOR.js} +10 -10
  12. package/dist/chunks/{edit-dashboard-visual-COHBqyic.js → edit-dashboard-visual-z9WN26w7.js} +6603 -6572
  13. package/dist/chunks/{editor-action-buttons-DahlP57T.js → editor-action-buttons-CGSFK9S-.js} +266 -267
  14. package/dist/chunks/{field-aggregations-BQjogiI1.js → field-aggregations-CdXSo1pb.js} +19 -19
  15. package/dist/chunks/{field-dependencies-v-lJNzC7.js → field-dependencies-CGYic38w.js} +1 -1
  16. package/dist/chunks/{index-CbjuruKe.js → index-CTYnXU85.js} +781 -780
  17. package/dist/chunks/{matrix-analytical-definition-BimC4XIV.js → matrix-analytical-definition-BJyH5-99.js} +1 -1
  18. package/dist/chunks/{matrix-card-CIlz0Dnp.js → matrix-card-DhykwdZs.js} +7 -6
  19. package/dist/chunks/{matrix-control-sources-2VAzGlt8.js → matrix-control-sources-BV9ywFtJ.js} +11 -11
  20. package/dist/chunks/{matrix-definition-E5gXXSTZ.js → matrix-definition-Cdn3LoxW.js} +3 -3
  21. package/dist/chunks/{semantic-format-Baqp8kD_.js → matrix-formatter-1Mm8x8w7.js} +655 -511
  22. package/dist/chunks/{matrix-member-presentation-Bw7-JCrr.js → matrix-member-presentation-BBW0n1iY.js} +1 -1
  23. package/dist/chunks/matrix-operation-contract-Dp7kFpVk.js +1383 -0
  24. package/dist/chunks/{metric-comparison-BphoJ9bq.js → metric-comparison-Crljx_XY.js} +15 -10
  25. package/dist/chunks/{numeric-presentation-VhMUHfrJ.js → numeric-presentation-LvnNY5Ma.js} +68 -68
  26. package/dist/chunks/pivot-header-presentation-CZa3556D.js +618 -0
  27. package/dist/chunks/{pivot-result-identity-BzUQiCEV.js → pivot-result-identity-CY__BuwI.js} +1 -1
  28. package/dist/chunks/{pivot-result-lifecycle-BFO354lk.js → pivot-result-lifecycle-Bqdtknud.js} +259 -204
  29. package/dist/chunks/{raw-temporal-7bFbXd2a.js → raw-temporal-CdnA_OXJ.js} +10 -10
  30. package/dist/chunks/{raw-temporal-contract-BQZIJ1fn.js → raw-temporal-contract-Bc9z83t-.js} +1 -1
  31. package/dist/chunks/relative-date-DAF9J7mt.js +456 -0
  32. package/dist/chunks/{report-preferences-dialog-BcH-0lR-.js → report-preferences-dialog-VV0-Ro6F.js} +131 -132
  33. package/dist/chunks/{report-runtime-context-CxIoGyNM.js → report-runtime-context-CtaGGlit.js} +1 -1
  34. package/dist/chunks/{selection-reducer-NF5C07yM.js → selection-reducer-IZjBSU6Z.js} +47 -26
  35. package/dist/chunks/semantic-format-BBLvfwua.js +192 -0
  36. package/dist/chunks/{semaphor-ready-indicator-BLRDuLr4.js → semaphor-ready-indicator-DbA4mVQL.js} +49909 -46207
  37. package/dist/chunks/{slider-BYIH4icg.js → slider-DpiJG8lv.js} +81 -82
  38. package/dist/chunks/{source-entity-resolution-Bzefiive.js → source-entity-resolution-Bde29mqE.js} +25 -25
  39. package/dist/chunks/switch-C4YH-W1X.js +24003 -0
  40. package/dist/chunks/{temporal-bucket-PcLFSYWX.js → temporal-bucket-DlFuhCnT.js} +6 -6
  41. package/dist/chunks/{temporal-bucket-contract-DTLDRzgV.js → temporal-bucket-contract-C6lUGPS3.js} +1 -1
  42. package/dist/chunks/temporal-input-presentation-DyMWCZYh.js +195 -0
  43. package/dist/chunks/{token-types-BC6RcUY8.js → token-types-UjyNz95-.js} +1 -1
  44. package/dist/chunks/{validators-CsdOtZI6.js → validators-CQcG0EPN.js} +852 -731
  45. package/dist/chunks/zoned-wall-clock-BkxV9jS2.js +46 -0
  46. package/dist/dashboard/index.js +1 -1
  47. package/dist/dashboard-authoring/index.js +138 -137
  48. package/dist/data-app-sdk/index.js +12 -12
  49. package/dist/data-app-sdk-adapters/index.js +23 -22
  50. package/dist/data-app-sdk-validation/index.js +27 -26
  51. package/dist/format-utils/index.js +247 -329
  52. package/dist/index.js +165 -168
  53. package/dist/report-runtime-context/index.js +2 -2
  54. package/dist/style.css +1 -1
  55. package/dist/surfboard/index.js +1 -1
  56. package/dist/types/briefings/index.d.ts +3 -0
  57. package/dist/types/components/explorer/filters/card-date-filter.d.ts +13 -5
  58. package/dist/types/components/explorer/filters/card-date-selection.d.ts +28 -0
  59. package/dist/types/components/sharing-and-management/dashboard-actions-menu.d.ts +1 -1
  60. package/dist/types/components/sharing-and-management/hooks/use-resource-management.d.ts +0 -1
  61. package/dist/types/components/surfboard/download-settings-dialog.d.ts +8 -0
  62. package/dist/types/components/surfboard/filter/types.d.ts +8 -29
  63. package/dist/types/components/surfboard/filter/use-dashboard-filter-mapping-popover.d.ts +5 -1
  64. package/dist/types/components/ui-custom/date-range-picker.d.ts +18 -2
  65. package/dist/types/components/ui-custom/date-range-presets.d.ts +8 -21
  66. package/dist/types/components/ui-custom/report-calendar.d.ts +18 -0
  67. package/dist/types/components/visual/aggregated-table/utils/export-utils.d.ts +3 -5
  68. package/dist/types/components/visual/data-table/data-table-toolbar.d.ts +1 -1
  69. package/dist/types/components/visual/pivot-table/utils/pivot-table-export-utils.d.ts +3 -1
  70. package/dist/types/index.js +5 -5
  71. package/dist/types/lib/api/exports-api.d.ts +3 -0
  72. package/dist/types/lib/csv-download.d.ts +9 -0
  73. package/dist/types/lib/csv-encoding-options.d.ts +6 -0
  74. package/dist/types/lib/dashboard-inputs/dashboard-filter-mapping-storage-transition.d.ts +2 -1
  75. package/dist/types/lib/dashboard-navigation/build-carried-click-context.d.ts +0 -1
  76. package/dist/types/lib/document/document-input-runtime.d.ts +2 -1
  77. package/dist/types/lib/export-utils.d.ts +17 -15
  78. package/dist/types/lib/hooks/explorer/use-filter-builder.d.ts +2 -2
  79. package/dist/types/lib/hooks/use-relative-date-summarizer.d.ts +7 -0
  80. package/dist/types/lib/matrix-table/matrix-application-adapter.d.ts +3 -2
  81. package/dist/types/lib/matrix-table/matrix-card-adapter.d.ts +1 -1
  82. package/dist/types/lib/matrix-table/matrix-card-draft.d.ts +1 -1
  83. package/dist/types/lib/matrix-table/matrix-dataset-history.d.ts +47 -0
  84. package/dist/types/lib/matrix-table/matrix-delivery.d.ts +7 -3
  85. package/dist/types/lib/matrix-table/matrix-execution-context.d.ts +2 -0
  86. package/dist/types/lib/matrix-table/matrix-query-transport.d.ts +4 -1
  87. package/dist/types/lib/matrix-table/matrix-runtime-types.d.ts +105 -4
  88. package/dist/types/lib/matrix-table/matrix-runtime.d.ts +43 -2
  89. package/dist/types/lib/matrix-table/use-matrix.d.ts +6 -0
  90. package/dist/types/lib/query-context/build-card-query-context.d.ts +5 -1
  91. package/dist/types/lib/query-context/build-dashboard-card-query-contract.d.ts +0 -1
  92. package/dist/types/lib/query-context/build-global-date-comparison-context.d.ts +1 -2
  93. package/dist/types/lib/query-context/compile-dashboard-card-filters.d.ts +1 -2
  94. package/dist/types/lib/query-context/dashboard-card-query-key.d.ts +10 -0
  95. package/dist/types/lib/query-context/query-auth-scope.d.ts +5 -0
  96. package/dist/types/lib/stores/dashboard-store.d.ts +9 -4
  97. package/dist/types/lib/temporal-filter/temporal-filter-utils.d.ts +9 -2
  98. package/dist/types/lib/types/common-types.d.ts +5 -0
  99. package/dist/types/lib/types/explorer-types.d.ts +14 -0
  100. package/dist/types/lib/types/semantic-types.d.ts +4 -2
  101. package/dist/types/lib/types/token-types.d.ts +0 -1
  102. package/dist/types/lib/utils/aggregate-expression-utils.d.ts +0 -4
  103. package/dist/types/lib/utils/card-definition.d.ts +1 -1
  104. package/dist/types/lib/utils/date-timezone-utils.d.ts +4 -46
  105. package/dist/types/lib/utils/filter-default-value-utils.d.ts +8 -2
  106. package/dist/types/lib/utils/inline-filter-utils.d.ts +3 -2
  107. package/dist/types/lib/utils/relative-date-description.d.ts +38 -0
  108. package/dist/types/shared/analytics-protocol/aggregate-expression.d.ts +89 -0
  109. package/dist/types/shared/analytics-protocol/analytics-refusal.d.ts +32 -0
  110. package/dist/types/shared/analytics-protocol/contracts.d.ts +48 -7
  111. package/dist/types/shared/analytics-protocol/index.d.ts +15 -1
  112. package/dist/types/shared/analytics-protocol/matrix-definition-contract.d.ts +20 -20
  113. package/dist/types/shared/analytics-protocol/matrix-operation-contract.d.ts +10 -10
  114. package/dist/types/shared/analytics-protocol/matrix-operation-request.d.ts +8 -8
  115. package/dist/types/shared/analytics-protocol/matrix-window-contract.d.ts +61 -6
  116. package/dist/types/shared/analytics-protocol/measure-aggregation-profile.d.ts +63 -0
  117. package/dist/types/shared/analytics-protocol/metric-comparison.d.ts +9 -3
  118. package/dist/types/shared/analytics-protocol/operation-temporal-state.d.ts +64 -0
  119. package/dist/types/shared/analytics-protocol/relative-date-filter.d.ts +61 -0
  120. package/dist/types/shared/analytics-protocol/relative-date-label.d.ts +20 -0
  121. package/dist/types/shared/analytics-protocol/runtime-schemas.d.ts +0 -2
  122. package/dist/types/shared/analytics-protocol/time-window-schema.d.ts +314 -0
  123. package/dist/types/shared/analytics-protocol/time-window.d.ts +13 -0
  124. package/dist/types/shared/dashboard-authoring/matrix-delivery.d.ts +8 -4
  125. package/dist/types/shared/format-utils/exporters/csv-utils.d.ts +46 -15
  126. package/dist/types/shared/format-utils/exporters/index.d.ts +2 -3
  127. package/dist/types/shared/format-utils/flat-table-export-totals.d.ts +2 -1
  128. package/dist/types/shared/format-utils/matrix-export-presentation.d.ts +2 -2
  129. package/dist/types/shared/format-utils/types/format-types.d.ts +0 -42
  130. package/dist/types/shared/temporal/calendar-periods.d.ts +56 -0
  131. package/dist/types/shared/temporal/index.d.ts +5 -0
  132. package/dist/types/shared/temporal/relative-date.d.ts +21 -0
  133. package/dist/types/shared/temporal/temporal-parity-fixtures.d.ts +73 -0
  134. package/dist/types/shared/temporal/time-window-periods.d.ts +21 -0
  135. package/dist/types/shared/temporal/zoned-wall-clock.d.ts +23 -0
  136. package/package.json +1 -17
  137. package/src/data-app-sdk/README.md +6 -3
  138. package/dist/chunks/code-highlight-994tgM9v.js +0 -22265
  139. package/dist/chunks/dashboard-CsHvEtjN.js +0 -15
  140. package/dist/chunks/dashboard-date-comparison-definition-BqNhECUr.js +0 -183
  141. package/dist/chunks/matrix-formatter-WBgtebUT.js +0 -341
  142. package/dist/chunks/matrix-operation-contract-D32U2CSw.js +0 -1802
  143. package/dist/chunks/mouse-pointer-2-BZvGk45-.js +0 -19
  144. package/dist/chunks/pivot-header-presentation-CGtudHo7.js +0 -661
  145. package/dist/chunks/pre-block-Cq1RqhZX.js +0 -3987
  146. package/dist/chunks/search-CJz-QQ0Q.js +0 -24
  147. package/dist/chunks/switch-XaAACBrJ.js +0 -2234
  148. package/dist/chunks/temporal-input-presentation-2RJrvmYL.js +0 -222
  149. package/dist/chunks/update-policy-DhAUtiC8.js +0 -913
  150. package/dist/data-app-builder/index.js +0 -3666
  151. package/dist/data-app-builder-browser-runtime/index.js +0 -8
  152. package/dist/data-app-codegen/index.js +0 -22
  153. package/dist/data-app-codegen-node/index.js +0 -1807
  154. package/dist/types/components/data-app-runtime/published-data-app-runtime.d.ts +0 -7
  155. package/dist/types/components/surfboard/json-to-csv.d.ts +0 -7
  156. package/dist/types/components/visual/data-table/utils/export-utils.d.ts +0 -31
  157. package/dist/types/data-app-builder/browser-runtime.d.ts +0 -174
  158. package/dist/types/data-app-builder/constants.d.ts +0 -14
  159. package/dist/types/data-app-builder/data-app-builder.d.ts +0 -14
  160. package/dist/types/data-app-builder/index.d.ts +0 -1
  161. package/dist/types/data-app-builder/lib/api.d.ts +0 -36
  162. package/dist/types/data-app-builder/lib/context-select.d.ts +0 -3
  163. package/dist/types/data-app-builder/lib/diagnostics.d.ts +0 -12
  164. package/dist/types/data-app-builder/lib/file-tree.d.ts +0 -2
  165. package/dist/types/data-app-builder/types.d.ts +0 -558
  166. package/dist/types/data-app-builder-browser-runtime.d.ts +0 -2
  167. package/dist/types/data-app-builder.d.ts +0 -2
  168. package/dist/types/data-app-codegen/generate-contract.d.ts +0 -26
  169. package/dist/types/data-app-codegen/generated-contract-files.d.ts +0 -7
  170. package/dist/types/data-app-codegen/generated-contract-validation.d.ts +0 -13
  171. package/dist/types/data-app-codegen/index.d.ts +0 -6
  172. package/dist/types/data-app-codegen/live-execution.d.ts +0 -42
  173. package/dist/types/data-app-codegen/node.d.ts +0 -2
  174. package/dist/types/data-app-codegen/update-policy.d.ts +0 -25
  175. package/dist/types/data-app-codegen/validation.d.ts +0 -8
  176. package/dist/types/data-app-codegen-node.d.ts +0 -2
  177. package/dist/types/data-app-codegen.d.ts +0 -2
  178. package/dist/types/shared/analytics-protocol/data-app-codegen-summary.d.ts +0 -418
  179. package/dist/types/shared/format-utils/exporters/pivot-exporter.d.ts +0 -13
  180. package/dist/types/shared/format-utils/exporters/table-exporter.d.ts +0 -10
@@ -1,28 +1,26 @@
1
1
  import { jsx as t, jsxs as r, Fragment as $ } from "react/jsx-runtime";
2
- import Nt, { useState as A, useEffect as K, useMemo as Z, useCallback as W, useLayoutEffect as xt, useRef as ce, useContext as qt } from "react";
3
- import { B as T, L as re, C as St, _ as z, c as G, u as L, G as me, E as be, as as et, H as Dt, P as Pe, a as Me, b as _e, aN as Gt, aO as Qt, aP as Kt, aQ as Yt, aR as Zt, aS as Xt, Z as Jt } from "./code-highlight-994tgM9v.js";
4
- import { c0 as rt, aU as Se, aV as De, aX as ke, b1 as kt, aJ as er, c1 as tr, c2 as rr, bQ as Et, b9 as Oe, n as ar, R as nr, c3 as sr, b7 as at, c4 as or, c5 as ir, c6 as Ye, bR as je, bS as We, c7 as At, bT as He, bC as q, b_ as ze, c8 as lr, bB as dr, aW as nt, aY as st, c9 as cr, aT as ur, b0 as hr, bk as Ft, ca as mr, bE as pr, u as fr, ax as qe, H as he, ar as ot, an as It, ao as $e, J as Lt, am as gr, at as br, cb as xr, cc as vr, ap as vt, L as yr, cd as Cr, ce as wr, cf as Nr, cg as Sr, ch as Dr, ci as kr, cj as Bt, ck as Er, cl as Ar, bU as Tt, cm as Fr, cn as Ir, co as Ue, cp as Lr, cq as Br, cr as Tr, aj as Ur, ak as Rr, $ as Vr, _ as Pr, Z as Mr, Y as _r, T as Or, P as zr, cs as $r, ct as jr, cu as Wr, cv as Hr, cw as qr, ah as Gr, cx as Qr, cy as Kr, a5 as Yr, cz as Zr, cA as Xr, cB as Jr } from "./semaphor-ready-indicator-BLRDuLr4.js";
5
- import { P as ge, A as it, g as lt, h as dt, i as ct, j as ut, k as ht, l as mt, m as Ut, C as ea, b as ta, q as ra, R as Rt, D as aa } from "./pre-block-Cq1RqhZX.js";
6
- import { L as Ne, m as tt, g as Vt, f as na, S as Pt } from "./switch-XaAACBrJ.js";
2
+ import Nt, { useState as A, useEffect as Y, useMemo as X, useCallback as W, useLayoutEffect as xt, useRef as ce, useContext as qt } from "react";
3
+ import { B as T, m as Ne, r as et, L as re, k as St, d as Dt, aj as z, c as G, j as Gt, u as L, a2 as me, a0 as be, aN as tt, a3 as kt, P as Me, a as _e, b as Oe, aW as Kt, aX as Yt, S as Et, aY as Qt, aZ as Xt, a_ as Zt, a$ as Jt, ah as er } from "./switch-C4YH-W1X.js";
4
+ import { cg as rt, aY as Se, aZ as De, a$ as ke, b5 as At, aN as tr, ch as rr, ci as ar, bm as ge, bW as It, bd as ze, q as nr, m as sr, cj as or, c8 as at, c9 as nt, ca as st, cb as ot, cc as it, cd as lt, ce as dt, cf as Ft, bb as ct, ck as ir, cl as lr, cm as Qe, bX as We, bY as He, cn as Lt, bZ as qe, bI as q, c6 as dr, c5 as $e, co as cr, bG as ur, a_ as ut, b0 as ht, cp as hr, aX as mr, b4 as pr, bp as Bt, cq as fr, bK as gr, u as br, cr as xr, cs as vr, aB as Ge, L as he, au as mt, aq as Tt, ar as je, N as Ut, ap as yr, aw as Cr, R as Rt, ct as wr, cu as Nr, as as vt, P as Sr, cv as Dr, cw as kr, cx as Er, cy as Ar, cz as Ir, cA as Fr, cB as Vt, cC as Lr, cD as Br, cE as Tr, b_ as Pt, cF as Ur, cG as Rr, cH as Re, cI as Vr, cJ as Pr, cK as Mr, am as _r, an as Or, a2 as zr, a1 as $r, a0 as jr, $ as Wr, Y as Hr, W as qr, cL as Gr, cM as Kr, cN as Yr, cO as Qr, cP as Xr, ak as Zr, cQ as Jr, cR as ea, a8 as ta, cS as ra, cT as aa, cU as na } from "./semaphor-ready-indicator-DbA4mVQL.js";
7
5
  import { L as pt } from "./layout-grid-CiubineE.js";
8
- import { c as Ge, X as Qe, C as Mt } from "./x-CXDkqdur.js";
9
- import { a as ft, V as sa, E as Ze, b as Xe, c as oa, d as ia, L as la, e as da, g as _t, C as Ot, F as ca, h as ua } from "./editor-action-buttons-DahlP57T.js";
10
- import "./validators-CsdOtZI6.js";
11
- import "./matrix-operation-contract-D32U2CSw.js";
6
+ import { c as Ee, X as Ke, C as Mt } from "./x-CXDkqdur.js";
7
+ import { a as ft, V as sa, E as Xe, b as Ze, c as oa, d as ia, L as la, e as da, g as _t, C as Ot, F as ca, h as ua } from "./editor-action-buttons-CGSFK9S-.js";
8
+ import "./validators-CQcG0EPN.js";
9
+ import "./matrix-operation-contract-Dp7kFpVk.js";
10
+ import "zod";
12
11
  import "../value-format-preferences/index.js";
13
- import { S as ha } from "./search-CJz-QQ0Q.js";
14
- import { s as Re } from "./normalize-dashboard-for-dirty-check-Bk3VYv_q.js";
15
- import { v as yt, s as ma } from "./card-config-utils-9sv4e-Vb.js";
16
- import { M as pa } from "./mouse-pointer-2-BZvGk45-.js";
17
- import { k as fa } from "./matrix-formatter-WBgtebUT.js";
18
- import { d as se, e as ga, h as ba } from "./index-CbjuruKe.js";
12
+ import { S as ha } from "./selection-reducer-IZjBSU6Z.js";
13
+ import { s as Ve } from "./normalize-dashboard-for-dirty-check-Bk3VYv_q.js";
14
+ import { v as yt, s as ma } from "./card-config-utils-BdPceiw8.js";
15
+ import { l as pa } from "./matrix-formatter-1Mm8x8w7.js";
16
+ import { d as se, e as fa, h as ga } from "./index-CTYnXU85.js";
19
17
  /**
20
18
  * @license lucide-react v0.453.0 - ISC
21
19
  *
22
20
  * This source code is licensed under the ISC license.
23
21
  * See the LICENSE file in the root directory of this source tree.
24
22
  */
25
- const xa = Ge("ArrowUpRight", [
23
+ const ba = Ee("ArrowUpRight", [
26
24
  ["path", { d: "M7 7h10v10", key: "1tivn9" }],
27
25
  ["path", { d: "M7 17 17 7", key: "1vkiza" }]
28
26
  ]);
@@ -32,7 +30,7 @@ const xa = Ge("ArrowUpRight", [
32
30
  * This source code is licensed under the ISC license.
33
31
  * See the LICENSE file in the root directory of this source tree.
34
32
  */
35
- const va = Ge("CalendarRange", [
33
+ const xa = Ee("CalendarRange", [
36
34
  ["rect", { width: "18", height: "18", x: "3", y: "4", rx: "2", key: "1hopcy" }],
37
35
  ["path", { d: "M16 2v4", key: "4m81vk" }],
38
36
  ["path", { d: "M3 10h18", key: "8toen8" }],
@@ -48,7 +46,7 @@ const va = Ge("CalendarRange", [
48
46
  * This source code is licensed under the ISC license.
49
47
  * See the LICENSE file in the root directory of this source tree.
50
48
  */
51
- const ya = Ge("FileDown", [
49
+ const va = Ee("FileDown", [
52
50
  ["path", { d: "M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z", key: "1rqfz7" }],
53
51
  ["path", { d: "M14 2v4a2 2 0 0 0 2 2h4", key: "tnqrlb" }],
54
52
  ["path", { d: "M12 18v-6", key: "17g6i2" }],
@@ -60,7 +58,22 @@ const ya = Ge("FileDown", [
60
58
  * This source code is licensed under the ISC license.
61
59
  * See the LICENSE file in the root directory of this source tree.
62
60
  */
63
- const Ca = Ge("Newspaper", [
61
+ const ya = Ee("MousePointer2", [
62
+ [
63
+ "path",
64
+ {
65
+ d: "M4.037 4.688a.495.495 0 0 1 .651-.651l16 6.5a.5.5 0 0 1-.063.947l-6.124 1.58a2 2 0 0 0-1.438 1.435l-1.579 6.126a.5.5 0 0 1-.947.063z",
66
+ key: "edeuup"
67
+ }
68
+ ]
69
+ ]);
70
+ /**
71
+ * @license lucide-react v0.453.0 - ISC
72
+ *
73
+ * This source code is licensed under the ISC license.
74
+ * See the LICENSE file in the root directory of this source tree.
75
+ */
76
+ const Ca = Ee("Newspaper", [
64
77
  [
65
78
  "path",
66
79
  {
@@ -95,7 +108,7 @@ function Na({
95
108
  isCreating: n
96
109
  }) {
97
110
  const i = rt("interactive"), [s, c] = A(""), [m, l] = A("");
98
- K(() => {
111
+ Y(() => {
99
112
  e || (c(""), l(""));
100
113
  }, [e]);
101
114
  const u = () => {
@@ -127,7 +140,7 @@ function Na({
127
140
  onClick: () => d(!1),
128
141
  "aria-label": "Close",
129
142
  disabled: n,
130
- children: /* @__PURE__ */ t(Qe, { className: "h-3.5 w-3.5" })
143
+ children: /* @__PURE__ */ t(Ke, { className: "h-3.5 w-3.5" })
131
144
  }
132
145
  )
133
146
  ] }),
@@ -136,7 +149,7 @@ function Na({
136
149
  /* @__PURE__ */ r("div", { className: "space-y-1.5", children: [
137
150
  /* @__PURE__ */ t(Ne, { htmlFor: "visual-title", className: "text-[12px]", children: "Name" }),
138
151
  /* @__PURE__ */ t(
139
- tt,
152
+ et,
140
153
  {
141
154
  id: "visual-title",
142
155
  size: "sm",
@@ -153,7 +166,7 @@ function Na({
153
166
  /* @__PURE__ */ r("div", { className: "space-y-1.5", children: [
154
167
  /* @__PURE__ */ t(Ne, { htmlFor: "visual-description", className: "text-[12px]", children: "Description" }),
155
168
  /* @__PURE__ */ t(
156
- tt,
169
+ et,
157
170
  {
158
171
  id: "visual-description",
159
172
  size: "sm",
@@ -214,13 +227,13 @@ function Sa(e, a) {
214
227
  }
215
228
  function Da(e) {
216
229
  const a = (e || "").toLowerCase();
217
- return a.includes("table") ? Vt : a.includes("pie") || a.includes("donut") ? or : a.includes("line") ? ir : a.includes("bar") ? na : pt;
230
+ return a.includes("table") ? St : a.includes("pie") || a.includes("donut") ? ir : a.includes("line") ? lr : a.includes("bar") ? Gt : pt;
218
231
  }
219
232
  function ka({ visual: e }) {
220
233
  const a = e.ownership.status === "public" ? "Public" : e.ownership.status === "shared" || e.ownership.sharedCount > 0 ? "Shared" : "Private";
221
234
  return /* @__PURE__ */ t("span", { className: "inline-flex items-center rounded-[4px] border border-border/60 px-1.5 py-px text-[11px] text-muted-foreground", children: a });
222
235
  }
223
- function zn({
236
+ function _n({
224
237
  open: e,
225
238
  onOpenChange: a
226
239
  }) {
@@ -232,26 +245,26 @@ function zn({
232
245
  c(/* @__PURE__ */ new Set()), d(null), h(null), g(!1), x(null);
233
246
  }, w = () => {
234
247
  a(!1), C();
235
- }, { selectVisual: E } = kt(), { handleAddLibraryVisual: U, handleEditLibraryVisual: b } = ft(), { isConsoleMode: y } = er(), {
248
+ }, { selectVisual: E } = At(), { handleAddLibraryVisual: U, handleEditLibraryVisual: b } = ft(), { isConsoleMode: y } = tr(), {
236
249
  resources: R,
237
- isLoading: F,
250
+ isLoading: I,
238
251
  isError: H,
239
- createResource: I,
252
+ createResource: F,
240
253
  updateResource: P,
241
- deleteResourceAsync: X,
254
+ deleteResourceAsync: Z,
242
255
  duplicateResource: ae,
243
- isCreating: Ee,
256
+ isCreating: Ae,
244
257
  isDeleting: oe
245
- } = tr(
258
+ } = rr(
246
259
  void 0,
247
260
  (v) => {
248
261
  l(!1), v && (E(v), b(v), w());
249
262
  }
250
263
  ), {
251
- startUpdating: Ae,
264
+ startUpdating: Ie,
252
265
  stopUpdating: Fe,
253
266
  isUpdating: ie
254
- } = rr(), j = R, J = Z(() => {
267
+ } = ar(), j = R, J = X(() => {
255
268
  const v = n.trim().toLowerCase();
256
269
  return v ? j.filter(
257
270
  (B) => {
@@ -259,14 +272,14 @@ function zn({
259
272
  return ((M = B.title) == null ? void 0 : M.toLowerCase().includes(v)) || ((te = B.description) == null ? void 0 : te.toLowerCase().includes(v)) || ((de = B.kind) == null ? void 0 : de.toLowerCase().includes(v));
260
273
  }
261
274
  ) : j;
262
- }, [n, j]), le = Z(
275
+ }, [n, j]), le = X(
263
276
  () => j.filter(
264
277
  (v) => s.has(v.id)
265
278
  ),
266
279
  [s, j]
267
280
  ), ee = le.filter(
268
281
  (v) => v.permissions.canDelete
269
- ), Ie = le.filter(
282
+ ), Le = le.filter(
270
283
  (v) => v.permissions.canShare
271
284
  ), xe = J.length > 0 && J.every(
272
285
  (v) => s.has(v.id)
@@ -275,7 +288,7 @@ function zn({
275
288
  ), pe = (v) => {
276
289
  const B = new Set(s);
277
290
  v(B), c(B);
278
- }, Y = (v) => {
291
+ }, Q = (v) => {
279
292
  pe((B) => {
280
293
  B.has(v) ? B.delete(v) : B.add(v);
281
294
  });
@@ -306,17 +319,17 @@ function zn({
306
319
  S(v), ae(v, {
307
320
  onSettled: () => S(null)
308
321
  });
309
- }, Le = () => {
322
+ }, Be = () => {
310
323
  if (ee.length === 0) {
311
324
  z.error("Select a visual you can delete");
312
325
  return;
313
326
  }
314
327
  x(null), g(!0);
315
- }, Ke = async () => {
328
+ }, Ye = async () => {
316
329
  const v = k ? [k] : ee;
317
330
  try {
318
331
  for (const B of v)
319
- await X(B.id);
332
+ await Z(B.id);
320
333
  c((B) => {
321
334
  const M = new Set(B);
322
335
  return v.forEach(
@@ -347,7 +360,7 @@ function zn({
347
360
  return;
348
361
  }
349
362
  const te = Object.keys(M), de = te.length === 1 ? te[0] : void 0;
350
- Ae(p.id, de), P(
363
+ Ie(p.id, de), P(
351
364
  {
352
365
  resourceId: p.id,
353
366
  data: M
@@ -361,11 +374,11 @@ function zn({
361
374
  }
362
375
  }
363
376
  );
364
- }, Q = (v) => {
377
+ }, K = (v) => {
365
378
  a(v), v || C();
366
379
  }, we = k ? 1 : ee.length;
367
380
  return /* @__PURE__ */ r($, { children: [
368
- /* @__PURE__ */ t(Se, { open: e, onOpenChange: Q, children: /* @__PURE__ */ r(
381
+ /* @__PURE__ */ t(Se, { open: e, onOpenChange: K, children: /* @__PURE__ */ r(
369
382
  De,
370
383
  {
371
384
  showCloseButton: !1,
@@ -374,7 +387,7 @@ function zn({
374
387
  children: [
375
388
  /* @__PURE__ */ r("div", { className: "flex h-10 shrink-0 items-center justify-between gap-2 border-b border-border/60 px-3", children: [
376
389
  /* @__PURE__ */ r("div", { className: "flex min-w-0 items-center gap-2", children: [
377
- /* @__PURE__ */ t(Vt, { className: "h-3.5 w-3.5 shrink-0 text-muted-foreground" }),
390
+ /* @__PURE__ */ t(St, { className: "h-3.5 w-3.5 shrink-0 text-muted-foreground" }),
378
391
  /* @__PURE__ */ r("div", { className: "flex min-w-0 items-baseline gap-2", children: [
379
392
  /* @__PURE__ */ t(ke, { className: "truncate text-[13px] font-medium leading-none tracking-normal", children: "Visuals library" }),
380
393
  /* @__PURE__ */ t("span", { className: "shrink-0 text-[10px] font-medium uppercase leading-none tracking-[0.08em] text-muted-foreground", children: "Add to dashboard" })
@@ -386,7 +399,7 @@ function zn({
386
399
  size: "xs",
387
400
  variant: "ghost",
388
401
  className: "w-7 px-0 text-muted-foreground hover:text-foreground",
389
- onClick: () => Q(!1),
402
+ onClick: () => K(!1),
390
403
  "aria-label": "Close visuals library",
391
404
  children: "×"
392
405
  }
@@ -421,7 +434,7 @@ function zn({
421
434
  }
422
435
  )
423
436
  ] }),
424
- /* @__PURE__ */ t("div", { className: "min-h-0 flex-1 overflow-auto", children: F ? /* @__PURE__ */ t("div", { className: "p-3", children: /* @__PURE__ */ t(wa, {}) }) : H ? /* @__PURE__ */ t("div", { className: "flex flex-col items-center gap-2 px-4 py-12 text-center", children: /* @__PURE__ */ t("p", { className: "text-[13px] text-destructive", children: "Failed to load visuals" }) }) : J.length === 0 ? /* @__PURE__ */ r("div", { className: "flex flex-col items-center gap-2 px-4 py-12 text-center", children: [
437
+ /* @__PURE__ */ t("div", { className: "min-h-0 flex-1 overflow-auto", children: I ? /* @__PURE__ */ t("div", { className: "p-3", children: /* @__PURE__ */ t(wa, {}) }) : H ? /* @__PURE__ */ t("div", { className: "flex flex-col items-center gap-2 px-4 py-12 text-center", children: /* @__PURE__ */ t("p", { className: "text-[13px] text-destructive", children: "Failed to load visuals" }) }) : J.length === 0 ? /* @__PURE__ */ r("div", { className: "flex flex-col items-center gap-2 px-4 py-12 text-center", children: [
425
438
  /* @__PURE__ */ t(pt, { className: "h-5 w-5 text-muted-foreground/60" }),
426
439
  /* @__PURE__ */ t("p", { className: "text-[13px] font-medium", children: n ? "No visuals found" : "No visuals yet" }),
427
440
  /* @__PURE__ */ t("p", { className: "text-[12px] text-muted-foreground", children: n ? "Try a different search." : "Create a saved visual to add it here." })
@@ -433,7 +446,7 @@ function zn({
433
446
  allFilteredSelected: xe,
434
447
  someFilteredSelected: ue,
435
448
  onSelectAll: ve,
436
- onToggleSelection: Y,
449
+ onToggleSelection: Q,
437
450
  onAddVisual: _,
438
451
  onOpenVisual: ne,
439
452
  onEditDetails: h,
@@ -469,9 +482,9 @@ function zn({
469
482
  size: "xs",
470
483
  variant: "outline",
471
484
  onClick: ye,
472
- disabled: le.length !== 1 || Ie.length !== 1,
485
+ disabled: le.length !== 1 || Le.length !== 1,
473
486
  children: [
474
- /* @__PURE__ */ t(Et, { className: "h-3.5 w-3.5" }),
487
+ /* @__PURE__ */ t(It, { className: "h-3.5 w-3.5" }),
475
488
  "Share"
476
489
  ]
477
490
  }
@@ -482,10 +495,10 @@ function zn({
482
495
  size: "xs",
483
496
  variant: "outline",
484
497
  className: "text-destructive hover:text-destructive",
485
- onClick: Le,
498
+ onClick: Be,
486
499
  disabled: ee.length === 0,
487
500
  children: [
488
- /* @__PURE__ */ t(Oe, { className: "h-3.5 w-3.5" }),
501
+ /* @__PURE__ */ t(ze, { className: "h-3.5 w-3.5" }),
489
502
  "Delete ",
490
503
  ee.length || s.size
491
504
  ]
@@ -498,7 +511,7 @@ function zn({
498
511
  {
499
512
  size: "xs",
500
513
  variant: "outline",
501
- onClick: () => Q(!1),
514
+ onClick: () => K(!1),
502
515
  children: "Close"
503
516
  }
504
517
  ),
@@ -509,7 +522,7 @@ function zn({
509
522
  onClick: O,
510
523
  disabled: s.size === 0,
511
524
  children: [
512
- /* @__PURE__ */ t(St, { className: "h-3.5 w-3.5" }),
525
+ /* @__PURE__ */ t(Dt, { className: "h-3.5 w-3.5" }),
513
526
  s.size === 0 ? "Add to dashboard" : `Add ${s.size} visual${s.size === 1 ? "" : "s"}`
514
527
  ]
515
528
  }
@@ -524,20 +537,20 @@ function zn({
524
537
  {
525
538
  open: m,
526
539
  onOpenChange: l,
527
- onSubmit: I,
528
- isCreating: Ee
540
+ onSubmit: F,
541
+ isCreating: Ae
529
542
  }
530
543
  ),
531
544
  u && /* @__PURE__ */ t(
532
- ar,
545
+ nr,
533
546
  {
534
547
  resource: u,
535
- resourceType: nr.VISUAL,
548
+ resourceType: sr.VISUAL,
536
549
  onClose: () => d(null)
537
550
  }
538
551
  ),
539
552
  p && /* @__PURE__ */ t(
540
- sr,
553
+ or,
541
554
  {
542
555
  open: !!p,
543
556
  resourceLabel: "Visual",
@@ -549,34 +562,34 @@ function zn({
549
562
  }
550
563
  ),
551
564
  /* @__PURE__ */ t(
552
- it,
565
+ at,
553
566
  {
554
567
  open: f,
555
568
  onOpenChange: (v) => {
556
569
  !v && oe || (g(v), v || x(null));
557
570
  },
558
- children: /* @__PURE__ */ r(lt, { children: [
559
- /* @__PURE__ */ r(dt, { children: [
560
- /* @__PURE__ */ r(ct, { children: [
571
+ children: /* @__PURE__ */ r(nt, { children: [
572
+ /* @__PURE__ */ r(st, { children: [
573
+ /* @__PURE__ */ r(ot, { children: [
561
574
  "Delete ",
562
575
  we,
563
576
  " visual",
564
577
  we === 1 ? "" : "s",
565
578
  "?"
566
579
  ] }),
567
- /* @__PURE__ */ t(ut, { children: "This cannot be undone. Visuals already added to dashboards may need to be removed from those dashboards separately." })
580
+ /* @__PURE__ */ t(it, { children: "This cannot be undone. Visuals already added to dashboards may need to be removed from those dashboards separately." })
568
581
  ] }),
569
- /* @__PURE__ */ r(ht, { children: [
570
- /* @__PURE__ */ t(mt, { disabled: oe, children: "Cancel" }),
582
+ /* @__PURE__ */ r(lt, { children: [
583
+ /* @__PURE__ */ t(dt, { disabled: oe, children: "Cancel" }),
571
584
  /* @__PURE__ */ r(
572
- Ut,
585
+ Ft,
573
586
  {
574
587
  onClick: (v) => {
575
- v.preventDefault(), Ke();
588
+ v.preventDefault(), Ye();
576
589
  },
577
590
  disabled: oe || we === 0,
578
591
  children: [
579
- oe ? /* @__PURE__ */ t(re, { className: "h-3.5 w-3.5 animate-spin" }) : /* @__PURE__ */ t(Oe, { className: "h-3.5 w-3.5" }),
592
+ oe ? /* @__PURE__ */ t(re, { className: "h-3.5 w-3.5 animate-spin" }) : /* @__PURE__ */ t(ze, { className: "h-3.5 w-3.5" }),
580
593
  oe ? "Deleting..." : "Delete"
581
594
  ]
582
595
  }
@@ -607,7 +620,7 @@ function Ea({
607
620
  return /* @__PURE__ */ r("div", { className: "min-w-[48rem]", children: [
608
621
  /* @__PURE__ */ r("div", { className: "grid h-9 grid-cols-[2.5rem_minmax(14rem,1.8fr)_minmax(10rem,1fr)_8rem_7rem_5rem_5.5rem] items-center border-b border-border/60 px-3 text-[10px] font-medium uppercase tracking-[0.08em] text-muted-foreground", children: [
609
622
  /* @__PURE__ */ t(
610
- at,
623
+ ct,
611
624
  {
612
625
  checked: o ? !0 : n ? "indeterminate" : !1,
613
626
  onCheckedChange: i,
@@ -668,7 +681,7 @@ function Aa({
668
681
  ),
669
682
  children: [
670
683
  /* @__PURE__ */ t("div", { children: /* @__PURE__ */ t(
671
- at,
684
+ ct,
672
685
  {
673
686
  checked: a,
674
687
  onCheckedChange: () => o(e.id),
@@ -713,7 +726,7 @@ function Aa({
713
726
  /* @__PURE__ */ t(ka, { visual: e }),
714
727
  /* @__PURE__ */ t("span", { className: "text-right tabular-nums text-muted-foreground", children: e.ownership.sharedCount > 0 ? e.ownership.sharedCount : "—" }),
715
728
  /* @__PURE__ */ t(
716
- Fa,
729
+ Ia,
717
730
  {
718
731
  visual: e,
719
732
  onOpenVisual: i,
@@ -730,7 +743,7 @@ function Aa({
730
743
  }
731
744
  );
732
745
  }
733
- function Fa({
746
+ function Ia({
734
747
  visual: e,
735
748
  onOpenVisual: a,
736
749
  onEditDetails: o,
@@ -755,28 +768,28 @@ function Fa({
755
768
  className: "w-7 px-0",
756
769
  onClick: () => a(e),
757
770
  "aria-label": "Edit visual",
758
- children: /* @__PURE__ */ t(Ye, { className: "h-3.5 w-3.5" })
771
+ children: /* @__PURE__ */ t(Qe, { className: "h-3.5 w-3.5" })
759
772
  }
760
773
  ),
761
- /* @__PURE__ */ r(je, { modal: !1, children: [
762
- /* @__PURE__ */ t(We, { asChild: !0, children: /* @__PURE__ */ t(
774
+ /* @__PURE__ */ r(We, { modal: !1, children: [
775
+ /* @__PURE__ */ t(He, { asChild: !0, children: /* @__PURE__ */ t(
763
776
  T,
764
777
  {
765
778
  size: "xs",
766
779
  variant: "ghost",
767
780
  className: "w-7 px-0",
768
781
  "aria-label": "More actions",
769
- children: /* @__PURE__ */ t(At, { className: "h-3.5 w-3.5" })
782
+ children: /* @__PURE__ */ t(Lt, { className: "h-3.5 w-3.5" })
770
783
  }
771
784
  ) }),
772
785
  /* @__PURE__ */ r(
773
- He,
786
+ qe,
774
787
  {
775
788
  align: "end",
776
789
  className: "z-[60] w-44 rounded-[6px] border-border/60 p-1 shadow-sm",
777
790
  children: [
778
791
  /* @__PURE__ */ r(q, { onClick: () => a(e), children: [
779
- /* @__PURE__ */ t(Ye, { className: "h-3.5 w-3.5" }),
792
+ /* @__PURE__ */ t(Qe, { className: "h-3.5 w-3.5" }),
780
793
  "Edit visual"
781
794
  ] }),
782
795
  /* @__PURE__ */ r(
@@ -785,21 +798,21 @@ function Fa({
785
798
  onClick: () => s(e.id),
786
799
  disabled: c === e.id,
787
800
  children: [
788
- c === e.id ? /* @__PURE__ */ t(re, { className: "h-3.5 w-3.5 animate-spin" }) : /* @__PURE__ */ t(ea, { className: "h-3.5 w-3.5" }),
801
+ c === e.id ? /* @__PURE__ */ t(re, { className: "h-3.5 w-3.5 animate-spin" }) : /* @__PURE__ */ t(dr, { className: "h-3.5 w-3.5" }),
789
802
  c === e.id ? "Duplicating..." : "Duplicate"
790
803
  ]
791
804
  }
792
805
  ),
793
806
  e.permissions.canEdit && /* @__PURE__ */ r(q, { onClick: () => o(e), children: [
794
- /* @__PURE__ */ t(Ye, { className: "h-3.5 w-3.5" }),
807
+ /* @__PURE__ */ t(Qe, { className: "h-3.5 w-3.5" }),
795
808
  "Edit details"
796
809
  ] }),
797
810
  e.permissions.canShare && /* @__PURE__ */ r(q, { onClick: () => n(e), children: [
798
- /* @__PURE__ */ t(Et, { className: "h-3.5 w-3.5" }),
811
+ /* @__PURE__ */ t(It, { className: "h-3.5 w-3.5" }),
799
812
  "Share"
800
813
  ] }),
801
814
  e.permissions.canDelete && /* @__PURE__ */ r($, { children: [
802
- /* @__PURE__ */ t(ze, {}),
815
+ /* @__PURE__ */ t($e, {}),
803
816
  /* @__PURE__ */ r(
804
817
  q,
805
818
  {
@@ -807,20 +820,20 @@ function Fa({
807
820
  onClick: () => i(e),
808
821
  disabled: m,
809
822
  children: [
810
- /* @__PURE__ */ t(Oe, { className: "h-3.5 w-3.5" }),
823
+ /* @__PURE__ */ t(ze, { className: "h-3.5 w-3.5" }),
811
824
  m ? "Deleting..." : "Delete"
812
825
  ]
813
826
  }
814
827
  )
815
828
  ] }),
816
- /* @__PURE__ */ t(ze, {}),
829
+ /* @__PURE__ */ t($e, {}),
817
830
  /* @__PURE__ */ r("div", { className: "space-y-1 px-2 py-1.5 text-[11px] text-muted-foreground", children: [
818
831
  $t(e, l) && /* @__PURE__ */ r("div", { className: "flex items-center gap-1.5", children: [
819
- /* @__PURE__ */ t(lr, { className: "h-3 w-3" }),
832
+ /* @__PURE__ */ t(cr, { className: "h-3 w-3" }),
820
833
  /* @__PURE__ */ t("span", { className: "truncate", children: gt(e, l) })
821
834
  ] }),
822
835
  /* @__PURE__ */ r("div", { className: "flex items-center gap-1.5", children: [
823
- /* @__PURE__ */ t(dr, { className: "h-3 w-3" }),
836
+ /* @__PURE__ */ t(ur, { className: "h-3 w-3" }),
824
837
  /* @__PURE__ */ t("span", { children: zt(e.updatedAt) })
825
838
  ] })
826
839
  ] })
@@ -832,21 +845,21 @@ function Fa({
832
845
  }
833
846
  );
834
847
  }
835
- function $n(e, a, o = !1) {
848
+ function On(e, a, o = !1) {
836
849
  const n = L((u) => u.dashboard), i = L(
837
850
  (u) => u.isDashboardEditing
838
851
  ), s = L(
839
852
  (u) => u.onDashboardLifecycleEvent
840
853
  ), c = W(() => {
841
854
  const u = L.getState().dashboard;
842
- return a || !e || !u || u.id !== e.id ? !1 : Re(u) !== Re(e);
855
+ return a || !e || !u || u.id !== e.id ? !1 : Ve(u) !== Ve(e);
843
856
  }, [e, a]);
844
857
  xt(() => (L.setState({ checkUnsavedDashboardChanges: c }), () => {
845
858
  L.getState().checkUnsavedDashboardChanges === c && L.setState({ checkUnsavedDashboardChanges: null });
846
859
  }), [c]);
847
- const m = Z(() => !o || a || !n || i && (!e || n.id !== e.id) ? null : {
860
+ const m = X(() => !o || a || !n || i && (!e || n.id !== e.id) ? null : {
848
861
  dashboardId: n.id,
849
- dirty: i && e ? Re(n) !== Re(e) : !1
862
+ dirty: i && e ? Ve(n) !== Ve(e) : !1
850
863
  }, [
851
864
  i,
852
865
  a,
@@ -871,7 +884,7 @@ function $n(e, a, o = !1) {
871
884
  }));
872
885
  }, [m, s]), c;
873
886
  }
874
- function Ia({
887
+ function Fa({
875
888
  open: e,
876
889
  onOpenChange: a,
877
890
  isLibraryVisual: o,
@@ -915,7 +928,7 @@ function Ia({
915
928
  });
916
929
  };
917
930
  return /* @__PURE__ */ t(Se, { open: e, onOpenChange: a, children: /* @__PURE__ */ r(De, { className: "sm:max-w-[500px]", children: [
918
- /* @__PURE__ */ r(nt, { children: [
931
+ /* @__PURE__ */ r(ut, { children: [
919
932
  /* @__PURE__ */ r(ke, { className: "flex items-center gap-2", children: [
920
933
  /* @__PURE__ */ t("span", { children: "Save Visual As" }),
921
934
  h.badgeType !== "local" && /* @__PURE__ */ t(
@@ -927,13 +940,13 @@ function Ia({
927
940
  }
928
941
  )
929
942
  ] }),
930
- /* @__PURE__ */ t(st, { children: h.description })
943
+ /* @__PURE__ */ t(ht, { children: h.description })
931
944
  ] }),
932
945
  /* @__PURE__ */ r("div", { className: "grid gap-4 py-4", children: [
933
946
  /* @__PURE__ */ r("div", { className: "grid gap-2", children: [
934
947
  /* @__PURE__ */ t(Ne, { htmlFor: "name", children: "Name" }),
935
948
  /* @__PURE__ */ t(
936
- tt,
949
+ et,
937
950
  {
938
951
  id: "name",
939
952
  value: m,
@@ -946,7 +959,7 @@ function Ia({
946
959
  /* @__PURE__ */ r("div", { className: "grid gap-2", children: [
947
960
  /* @__PURE__ */ t(Ne, { htmlFor: "description", children: "Description (optional)" }),
948
961
  /* @__PURE__ */ t(
949
- cr,
962
+ hr,
950
963
  {
951
964
  id: "description",
952
965
  value: u,
@@ -958,7 +971,7 @@ function Ia({
958
971
  )
959
972
  ] })
960
973
  ] }),
961
- /* @__PURE__ */ r(ur, { children: [
974
+ /* @__PURE__ */ r(mr, { children: [
962
975
  /* @__PURE__ */ t(
963
976
  T,
964
977
  {
@@ -976,10 +989,10 @@ function Ia({
976
989
  ] }) });
977
990
  }
978
991
  function La() {
979
- const [e, a] = A(!1), [o, n] = A(!1), [i, s] = A(null), [c, m] = A(null), l = me((b) => b.frame), u = me((b) => b.card), d = hr(), p = L((b) => b.selectedSheetId), h = L((b) => b.dashboard), { getUpdatedFrame: f } = ft(), { selectVisual: g } = kt(), { addFrame: k, setSelectedFrameId: x, setIsVisualEditing: D } = be(), S = Ft(), C = !!(l != null && l.visualId), w = (() => {
992
+ const [e, a] = A(!1), [o, n] = A(!1), [i, s] = A(null), [c, m] = A(null), l = me((b) => b.frame), u = me((b) => b.card), d = pr(), p = L((b) => b.selectedSheetId), h = L((b) => b.dashboard), { getUpdatedFrame: f } = ft(), { selectVisual: g } = At(), { addFrame: k, setSelectedFrameId: x, setIsVisualEditing: D } = be(), S = Bt(), C = !!(l != null && l.visualId), w = (() => {
980
993
  var b, y;
981
994
  return ((b = l == null ? void 0 : l.cards) == null ? void 0 : b.length) === 1 && ((y = l.cards[0]) != null && y.title) ? l.cards[0].title : d != null && d.title ? d.title : (u == null ? void 0 : u.title) || "Untitled Visual";
982
- })(), E = mr((b) => {
995
+ })(), E = fr((b) => {
983
996
  b != null && b.id && (g(b), o && i && c && p && (async () => {
984
997
  try {
985
998
  const y = {
@@ -1010,7 +1023,7 @@ function La() {
1010
1023
  z.error("No sheet selected");
1011
1024
  return;
1012
1025
  }
1013
- const y = f(), F = y.cards.length === 1 ? {
1026
+ const y = f(), I = y.cards.length === 1 ? {
1014
1027
  ...y,
1015
1028
  cards: y.cards.map((H) => ({
1016
1029
  ...H,
@@ -1022,8 +1035,8 @@ function La() {
1022
1035
  let H = null;
1023
1036
  if (b.saveToCurrentDashboard)
1024
1037
  try {
1025
- H = await S(F, {
1026
- previousFrame: et(h, F.id)
1038
+ H = await S(I, {
1039
+ previousFrame: tt(h, I.id)
1027
1040
  });
1028
1041
  } catch (P) {
1029
1042
  console.error(
@@ -1034,34 +1047,34 @@ function La() {
1034
1047
  );
1035
1048
  return;
1036
1049
  }
1037
- n(b.saveToCurrentDashboard), s(F), m(H);
1038
- const I = {
1050
+ n(b.saveToCurrentDashboard), s(I), m(H);
1051
+ const F = {
1039
1052
  title: b.name,
1040
1053
  description: b.description,
1041
- frameObject: F,
1054
+ frameObject: I,
1042
1055
  // Card title synced for single-card frames
1043
1056
  isPrivate: !1
1044
1057
  };
1045
- E.mutate(I);
1058
+ E.mutate(F);
1046
1059
  } else if (b.saveToCurrentDashboard) {
1047
1060
  const H = {
1048
- ...F,
1061
+ ...I,
1049
1062
  // Card title already synced
1050
1063
  id: yt(),
1051
1064
  visualId: void 0
1052
1065
  // Explicitly no visualId for local visuals
1053
1066
  };
1054
1067
  try {
1055
- const I = await S(F, {
1056
- previousFrame: et(h, F.id)
1068
+ const F = await S(I, {
1069
+ previousFrame: tt(h, I.id)
1057
1070
  });
1058
1071
  k(p, H, {
1059
1072
  position: "end",
1060
- semanticExecutionPayload: I
1073
+ semanticExecutionPayload: F
1061
1074
  }), x(H.id), z.success("Visual saved to dashboard"), a(!1), D(!1);
1062
- } catch (I) {
1063
- console.error("Failed to save visual to dashboard:", I), z.error(
1064
- I instanceof Error ? I.message : "Failed to prepare semantic metadata for the visual"
1075
+ } catch (F) {
1076
+ console.error("Failed to save visual to dashboard:", F), z.error(
1077
+ F instanceof Error ? F.message : "Failed to prepare semantic metadata for the visual"
1065
1078
  );
1066
1079
  }
1067
1080
  }
@@ -1071,8 +1084,8 @@ function La() {
1071
1084
  isSaving: E.isPending
1072
1085
  };
1073
1086
  }
1074
- function jn(e = {}) {
1075
- const { isInspectionMode: a } = pr(), o = me((I) => I.frame), n = me((I) => I.editorContext), i = fr((I) => I.selectedVisual), s = L((I) => I.selectedFrameId), c = L((I) => I.selectedSheetId), m = L((I) => I.dashboard), { setIsVisualEditing: l, updateFrame: u } = be(), [d, p] = A(!1), [h, f] = A("both"), g = Ft(), k = (n == null ? void 0 : n.type) === "documentSection", x = !!(o != null && o.visualId || i != null && i.id), D = !!(o != null && o.visualId && s), S = x && !D, {
1087
+ function zn(e = {}) {
1088
+ const { isInspectionMode: a } = gr(), o = me((F) => F.frame), n = me((F) => F.editorContext), i = br((F) => F.selectedVisual), s = L((F) => F.selectedFrameId), c = L((F) => F.selectedSheetId), m = L((F) => F.dashboard), { setIsVisualEditing: l, updateFrame: u } = be(), [d, p] = A(!1), [h, f] = A("both"), g = Bt(), k = (n == null ? void 0 : n.type) === "documentSection", x = !!(o != null && o.visualId || i != null && i.id), D = !!(o != null && o.visualId && s), S = x && !D, {
1076
1089
  saveAsDialogOpen: C,
1077
1090
  setSaveAsDialogOpen: w,
1078
1091
  handleSaveAs: E,
@@ -1083,20 +1096,20 @@ function jn(e = {}) {
1083
1096
  if (a)
1084
1097
  return /* @__PURE__ */ r($, { children: [
1085
1098
  /* @__PURE__ */ t(
1086
- Ze,
1099
+ Xe,
1087
1100
  {
1088
1101
  className: "rounded-control",
1089
1102
  variant: "default"
1090
1103
  }
1091
1104
  ),
1092
- /* @__PURE__ */ t(Xe, {})
1105
+ /* @__PURE__ */ t(Ze, {})
1093
1106
  ] });
1094
1107
  if (k)
1095
1108
  return /* @__PURE__ */ r($, { children: [
1096
- /* @__PURE__ */ t(Ze, { className: "rounded-control", variant: "default" }),
1097
- /* @__PURE__ */ t(Xe, {})
1109
+ /* @__PURE__ */ t(Xe, { className: "rounded-control", variant: "default" }),
1110
+ /* @__PURE__ */ t(Ze, {})
1098
1111
  ] });
1099
- const F = async () => {
1112
+ const I = async () => {
1100
1113
  if (!c) {
1101
1114
  z.error("No sheet selected");
1102
1115
  return;
@@ -1106,10 +1119,10 @@ function jn(e = {}) {
1106
1119
  const P = {
1107
1120
  ...R(),
1108
1121
  visualId: void 0
1109
- }, X = et(m, P.id);
1122
+ }, Z = tt(m, P.id);
1110
1123
  try {
1111
1124
  const ae = await g(P, {
1112
- previousFrame: X
1125
+ previousFrame: Z
1113
1126
  });
1114
1127
  u(c, P, {
1115
1128
  semanticExecutionPayload: ae
@@ -1123,16 +1136,16 @@ function jn(e = {}) {
1123
1136
  setTimeout(() => {
1124
1137
  p(!1), z.success("Changes applied. Visual is now local to this dashboard"), l(!1);
1125
1138
  }, 300);
1126
- }, H = (I) => {
1127
- f(I), w(!0);
1139
+ }, H = (F) => {
1140
+ f(F), w(!0);
1128
1141
  };
1129
1142
  return /* @__PURE__ */ r($, { children: [
1130
1143
  /* @__PURE__ */ r("div", { className: "inline-flex items-center overflow-hidden rounded-control", children: [
1131
- !x && /* @__PURE__ */ t(Ze, { className: "!rounded-none", variant: "default" }),
1144
+ !x && /* @__PURE__ */ t(Xe, { className: "!rounded-none", variant: "default" }),
1132
1145
  x && S && /* @__PURE__ */ t(oa, { className: "!rounded-none", variant: "default" }),
1133
1146
  x && D && /* @__PURE__ */ t(ia, { className: "!rounded-none" }),
1134
- /* @__PURE__ */ r(je, { modal: !1, children: [
1135
- /* @__PURE__ */ t(We, { asChild: !0, children: /* @__PURE__ */ t(
1147
+ /* @__PURE__ */ r(We, { modal: !1, children: [
1148
+ /* @__PURE__ */ t(He, { asChild: !0, children: /* @__PURE__ */ t(
1136
1149
  T,
1137
1150
  {
1138
1151
  variant: "default",
@@ -1144,7 +1157,7 @@ function jn(e = {}) {
1144
1157
  }
1145
1158
  ) }),
1146
1159
  /* @__PURE__ */ r(
1147
- He,
1160
+ qe,
1148
1161
  {
1149
1162
  align: "end",
1150
1163
  className: "min-w-[220px] rounded-control border border-border/60 p-1 shadow-sm",
@@ -1153,15 +1166,15 @@ function jn(e = {}) {
1153
1166
  /* @__PURE__ */ r(
1154
1167
  q,
1155
1168
  {
1156
- onClick: F,
1169
+ onClick: I,
1157
1170
  disabled: d,
1158
1171
  children: [
1159
- /* @__PURE__ */ t(St, { className: "h-3.5 w-3.5" }),
1172
+ /* @__PURE__ */ t(Dt, { className: "h-3.5 w-3.5" }),
1160
1173
  d ? "Applying..." : "Apply Locally"
1161
1174
  ]
1162
1175
  }
1163
1176
  ),
1164
- /* @__PURE__ */ t(ze, {})
1177
+ /* @__PURE__ */ t($e, {})
1165
1178
  ] }),
1166
1179
  /* @__PURE__ */ r(
1167
1180
  q,
@@ -1201,13 +1214,13 @@ function jn(e = {}) {
1201
1214
  )
1202
1215
  ] })
1203
1216
  ] }),
1204
- /* @__PURE__ */ t(Xe, {}),
1217
+ /* @__PURE__ */ t(Ze, {}),
1205
1218
  /* @__PURE__ */ t(
1206
- Ia,
1219
+ Fa,
1207
1220
  {
1208
1221
  open: C,
1209
- onOpenChange: (I) => {
1210
- y || w(I);
1222
+ onOpenChange: (F) => {
1223
+ y || w(F);
1211
1224
  },
1212
1225
  isLibraryVisual: U,
1213
1226
  currentVisualName: b,
@@ -1218,11 +1231,11 @@ function jn(e = {}) {
1218
1231
  )
1219
1232
  ] });
1220
1233
  }
1221
- function Wn({ className: e }) {
1222
- const a = me((d) => d.isDevMode), o = me((d) => d.card.type), n = L((d) => d.isVisualEditing), { setIsDevMode: i } = Dt(), { config: s } = qt(ta).tokenProps, c = (s == null ? void 0 : s.showAdvancedMode) !== !1;
1234
+ function $n({ className: e }) {
1235
+ const a = me((d) => d.isDevMode), o = me((d) => d.card.type), n = L((d) => d.isVisualEditing), { setIsDevMode: i } = kt(), { config: s } = qt(xr).tokenProps, c = (s == null ? void 0 : s.showAdvancedMode) !== !1;
1223
1236
  if (!n || !c || !ma(o))
1224
1237
  return null;
1225
- const m = a ? pa : ra, l = a ? "Visual editor" : "SQL editor", u = a ? "Switch to visual editor" : "Switch to SQL editor";
1238
+ const m = a ? ya : vr, l = a ? "Visual editor" : "SQL editor", u = a ? "Switch to visual editor" : "Switch to SQL editor";
1226
1239
  return /* @__PURE__ */ r(
1227
1240
  "button",
1228
1241
  {
@@ -1241,7 +1254,7 @@ function Wn({ className: e }) {
1241
1254
  }
1242
1255
  );
1243
1256
  }
1244
- function Hn({
1257
+ function jn({
1245
1258
  open: e,
1246
1259
  onOpenChange: a,
1247
1260
  onSave: o,
@@ -1253,14 +1266,14 @@ function Hn({
1253
1266
  discardLabel: l = "Discard changes",
1254
1267
  saveLabel: u = "Save"
1255
1268
  }) {
1256
- return /* @__PURE__ */ t(it, { open: e, onOpenChange: (p) => {
1269
+ return /* @__PURE__ */ t(at, { open: e, onOpenChange: (p) => {
1257
1270
  !p && i || a(p);
1258
- }, children: /* @__PURE__ */ r(lt, { children: [
1259
- /* @__PURE__ */ r(dt, { children: [
1260
- /* @__PURE__ */ t(ct, { children: s }),
1261
- /* @__PURE__ */ t(ut, { children: c })
1271
+ }, children: /* @__PURE__ */ r(nt, { children: [
1272
+ /* @__PURE__ */ r(st, { children: [
1273
+ /* @__PURE__ */ t(ot, { children: s }),
1274
+ /* @__PURE__ */ t(it, { children: c })
1262
1275
  ] }),
1263
- /* @__PURE__ */ r(ht, { children: [
1276
+ /* @__PURE__ */ r(lt, { children: [
1264
1277
  /* @__PURE__ */ t(
1265
1278
  T,
1266
1279
  {
@@ -1273,7 +1286,7 @@ function Hn({
1273
1286
  children: l
1274
1287
  }
1275
1288
  ),
1276
- /* @__PURE__ */ t(mt, { disabled: i, children: m }),
1289
+ /* @__PURE__ */ t(dt, { disabled: i, children: m }),
1277
1290
  /* @__PURE__ */ t(T, { type: "button", size: "xs", onClick: o, disabled: i, children: i ? /* @__PURE__ */ r($, { children: [
1278
1291
  /* @__PURE__ */ t(re, { className: "mr-2 h-3.5 w-3.5 animate-spin" }),
1279
1292
  "Saving..."
@@ -1303,16 +1316,16 @@ function Pa(e) {
1303
1316
  const a = Date.now() - e.getTime();
1304
1317
  return a < Ra ? Ba : a < Va ? Ta : Ua;
1305
1318
  }
1306
- function qn() {
1307
- const { authToken: e, tokenProps: a } = qe(), o = he((h) => h.activeExports), [n, i] = A(
1319
+ function Wn() {
1320
+ const { authToken: e, tokenProps: a } = Ge(), o = he((h) => h.activeExports), [n, i] = A(
1308
1321
  typeof document < "u" ? !document.hidden : !0
1309
1322
  ), s = ce(null), c = ce(!1), m = ce(void 0), l = a == null ? void 0 : a.apiServiceUrl, u = e == null ? void 0 : e.accessToken, d = W(() => {
1310
1323
  const h = he.getState().activeExports;
1311
1324
  return Array.from(h.values()).filter(
1312
- (f) => ot(f.status)
1325
+ (f) => mt(f.status)
1313
1326
  );
1314
1327
  }, []);
1315
- K(() => {
1328
+ Y(() => {
1316
1329
  if (typeof document > "u") return;
1317
1330
  const h = () => {
1318
1331
  i(!document.hidden);
@@ -1353,11 +1366,11 @@ function qn() {
1353
1366
  const x = await Promise.allSettled(
1354
1367
  k.map(async (C) => {
1355
1368
  try {
1356
- const w = await It(l, u, C.id);
1369
+ const w = await Tt(l, u, C.id);
1357
1370
  let E;
1358
1371
  if (w.status === "completed")
1359
1372
  try {
1360
- E = await $e(l, u, C.id);
1373
+ E = await je(l, u, C.id);
1361
1374
  } catch (U) {
1362
1375
  console.error(
1363
1376
  `[useExportPolling] Failed to get download URL for ${C.id}:`,
@@ -1388,18 +1401,18 @@ function qn() {
1388
1401
  } else
1389
1402
  c.current = !1;
1390
1403
  }, [l, u, d]);
1391
- return K(() => {
1404
+ return Y(() => {
1392
1405
  m.current = p;
1393
- }, [p]), K(() => {
1406
+ }, [p]), Y(() => {
1394
1407
  var f;
1395
1408
  d().length > 0 && n && !c.current && (c.current = !0, (f = m.current) == null || f.call(m));
1396
- }, [o, n, d]), K(() => {
1409
+ }, [o, n, d]), Y(() => {
1397
1410
  var f;
1398
1411
  const h = d();
1399
1412
  n && h.length > 0 && !c.current && (c.current = !0, (f = m.current) == null || f.call(m));
1400
- }, [n, d]), K(() => {
1413
+ }, [n, d]), Y(() => {
1401
1414
  !n && s.current && (clearTimeout(s.current), s.current = null, c.current = !1);
1402
- }, [n]), K(() => () => {
1415
+ }, [n]), Y(() => () => {
1403
1416
  s.current && (clearTimeout(s.current), s.current = null);
1404
1417
  }, []), {
1405
1418
  isPolling: c.current,
@@ -1407,13 +1420,13 @@ function qn() {
1407
1420
  inProgressCount: d().length
1408
1421
  };
1409
1422
  }
1410
- function Gn() {
1411
- const { authToken: e, tokenProps: a } = qe(), o = he((m) => m.activeExports), { addExport: n } = Lt(), i = ce(!1), s = a == null ? void 0 : a.apiServiceUrl, c = e == null ? void 0 : e.accessToken;
1412
- K(() => {
1423
+ function Hn() {
1424
+ const { authToken: e, tokenProps: a } = Ge(), o = he((m) => m.activeExports), { addExport: n } = Ut(), i = ce(!1), s = a == null ? void 0 : a.apiServiceUrl, c = e == null ? void 0 : e.accessToken;
1425
+ Y(() => {
1413
1426
  if (i.current || !s || !c) return;
1414
1427
  (async () => {
1415
1428
  try {
1416
- const { exports: l } = await gr(s, c, {
1429
+ const { exports: l } = await yr(s, c, {
1417
1430
  status: ["pending", "processing", "chunking", "compacting", "completed", "failed"],
1418
1431
  limit: 20
1419
1432
  // Limit to recent exports
@@ -1423,7 +1436,7 @@ function Gn() {
1423
1436
  let d;
1424
1437
  if (u.status === "completed")
1425
1438
  try {
1426
- d = await $e(s, c, u.id);
1439
+ d = await je(s, c, u.id);
1427
1440
  } catch (h) {
1428
1441
  console.error(
1429
1442
  `[useExportRecovery] Failed to get download URL for ${u.id}:`,
@@ -1446,7 +1459,7 @@ function Gn() {
1446
1459
  }, [s, c, n, o]);
1447
1460
  }
1448
1461
  function Ma(e) {
1449
- return e.title ? e.title : ot(
1462
+ return e.title ? e.title : mt(
1450
1463
  e.status
1451
1464
  ) ? "Export in progress..." : e.status === "completed" ? "Export completed" : e.status === "failed" ? "Export failed" : "Export";
1452
1465
  }
@@ -1456,7 +1469,7 @@ function _a({
1456
1469
  onDownload: o
1457
1470
  }) {
1458
1471
  const [n, i] = A("idle");
1459
- K(() => {
1472
+ Y(() => {
1460
1473
  e.downloadUrl && i("idle");
1461
1474
  }, [e.downloadUrl]);
1462
1475
  const s = async () => {
@@ -1469,7 +1482,7 @@ function _a({
1469
1482
  i(g === "denied" ? "denied" : "idle");
1470
1483
  }, c = (g) => {
1471
1484
  g.stopPropagation(), a == null || a(e.id);
1472
- }, m = ot(e.status), l = (() => {
1485
+ }, m = mt(e.status), l = (() => {
1473
1486
  switch (e.status) {
1474
1487
  case "pending":
1475
1488
  return "Queued...";
@@ -1478,9 +1491,9 @@ function _a({
1478
1491
  default:
1479
1492
  return "Processing...";
1480
1493
  }
1481
- })(), u = e.status === "completed" ? "bg-emerald-500" : e.status === "failed" ? "bg-destructive" : e.status === "pending" ? "bg-muted-foreground/40" : "animate-pulse bg-muted-foreground/60", d = e.status === "completed" ? "Ready" : e.status === "failed" ? "Failed" : "In progress", p = fa(e.startedAt, { addSuffix: !0 }), h = [
1494
+ })(), u = e.status === "completed" ? "bg-emerald-500" : e.status === "failed" ? "bg-destructive" : e.status === "pending" ? "bg-muted-foreground/40" : "animate-pulse bg-muted-foreground/60", d = e.status === "completed" ? "Ready" : e.status === "failed" ? "Failed" : "In progress", p = pa(e.startedAt, { addSuffix: !0 }), h = [
1482
1495
  e.status === "completed" && e.totalRows !== null ? `${e.totalRows.toLocaleString()} rows` : null,
1483
- e.status === "completed" && e.fileSize ? br(e.fileSize) : null
1496
+ e.status === "completed" && e.fileSize ? Cr(e.fileSize) : null
1484
1497
  ].filter((g) => !!g), f = /* @__PURE__ */ t("span", { className: "text-muted-foreground/50", children: "·" });
1485
1498
  return /* @__PURE__ */ r("div", { className: "group flex items-start gap-2.5 px-3 py-2 transition-colors hover:bg-muted/40 focus-within:bg-muted/40", children: [
1486
1499
  /* @__PURE__ */ t("span", { className: "flex h-5 shrink-0 items-center", "aria-hidden": "true", children: /* @__PURE__ */ t("span", { className: `h-1.5 w-1.5 rounded-full ${u}` }) }),
@@ -1510,7 +1523,7 @@ function _a({
1510
1523
  onClick: c,
1511
1524
  "aria-label": "Remove notification",
1512
1525
  title: "Remove",
1513
- children: /* @__PURE__ */ t(Qe, { className: "h-3.5 w-3.5", strokeWidth: 1.75 })
1526
+ children: /* @__PURE__ */ t(Ke, { className: "h-3.5 w-3.5", strokeWidth: 1.75 })
1514
1527
  }
1515
1528
  )
1516
1529
  ] }),
@@ -1526,7 +1539,7 @@ function _a({
1526
1539
  /* @__PURE__ */ t("span", { children: p })
1527
1540
  ] }),
1528
1541
  e.status === "completed" && n === "denied" && /* @__PURE__ */ r("div", { role: "alert", className: "mt-1 flex items-start gap-1.5 text-[12px] leading-4 text-foreground", children: [
1529
- /* @__PURE__ */ t(xr, { className: "mt-0.5 h-3 w-3 shrink-0 text-destructive", strokeWidth: 1.75 }),
1542
+ /* @__PURE__ */ t(wr, { className: "mt-0.5 h-3 w-3 shrink-0 text-destructive", strokeWidth: 1.75 }),
1530
1543
  /* @__PURE__ */ t("span", { children: "This link expired. Refresh the tray to sign the file again." })
1531
1544
  ] }),
1532
1545
  m && /* @__PURE__ */ r("div", { className: "text-[12px] leading-4 text-muted-foreground", children: [
@@ -1537,7 +1550,7 @@ function _a({
1537
1550
  " ",
1538
1551
  /* @__PURE__ */ t("span", { className: "tabular-nums", children: e.progress === null ? `${e.rowsProcessed.toLocaleString()} rows processed` : `${e.progress}% complete` })
1539
1552
  ] }),
1540
- e.progress !== null && /* @__PURE__ */ t(vr, { value: e.progress, className: "mt-1.5 h-1" })
1553
+ e.progress !== null && /* @__PURE__ */ t(Nr, { value: e.progress, className: "mt-1.5 h-1" })
1541
1554
  ] }),
1542
1555
  e.status === "failed" && /* @__PURE__ */ r($, { children: [
1543
1556
  /* @__PURE__ */ r("div", { className: "flex items-center gap-1.5 text-[12px] leading-4 text-muted-foreground", children: [
@@ -1551,7 +1564,7 @@ function _a({
1551
1564
  ] });
1552
1565
  }
1553
1566
  function Oa() {
1554
- const { authToken: e, tokenProps: a } = qe(), o = he((x) => x.activeExports), { clearCompleted: n, removeExport: i, updateExport: s } = Lt(), [c, m] = A(!1), [l, u] = A(!1), d = Array.from(o.values()).sort(
1567
+ const { authToken: e, tokenProps: a } = Ge(), o = he((x) => x.activeExports), { clearCompleted: n, removeExport: i, updateExport: s } = Ut(), [c, m] = A(!1), [l, u] = A(!1), d = Array.from(o.values()).sort(
1555
1568
  (x, D) => D.startedAt.getTime() - x.startedAt.getTime()
1556
1569
  ), p = d.some(
1557
1570
  (x) => x.status === "completed" || x.status === "failed"
@@ -1564,11 +1577,11 @@ function Oa() {
1564
1577
  await Promise.all(
1565
1578
  S.map(async (C) => {
1566
1579
  try {
1567
- const w = await It(x, D, C.id);
1580
+ const w = await Tt(x, D, C.id);
1568
1581
  let E;
1569
1582
  if (w.status === "completed")
1570
1583
  try {
1571
- E = await $e(
1584
+ E = await je(
1572
1585
  x,
1573
1586
  D,
1574
1587
  C.id
@@ -1635,7 +1648,7 @@ function Oa() {
1635
1648
  const D = a == null ? void 0 : a.apiServiceUrl, S = e == null ? void 0 : e.accessToken;
1636
1649
  if (!D || !S) return "denied";
1637
1650
  try {
1638
- const C = await $e(D, S, x.id);
1651
+ const C = await je(D, S, x.id);
1639
1652
  return s(x.id, { downloadUrl: C }), window.open(C, "_blank"), "opened";
1640
1653
  } catch (C) {
1641
1654
  return console.error(`Failed to get download URL for ${x.id}:`, C), s(x.id, { downloadUrl: void 0 }), "denied";
@@ -1644,7 +1657,7 @@ function Oa() {
1644
1657
  [a == null ? void 0 : a.apiServiceUrl, e == null ? void 0 : e.accessToken, s]
1645
1658
  );
1646
1659
  return d.length === 0 ? /* @__PURE__ */ r("div", { className: "flex flex-col items-center gap-1.5 px-6 py-8 text-center", children: [
1647
- /* @__PURE__ */ t("span", { className: "flex h-8 w-8 items-center justify-center rounded-[6px] border border-border text-muted-foreground", children: /* @__PURE__ */ t(ya, { className: "h-3.5 w-3.5", strokeWidth: 1.75 }) }),
1660
+ /* @__PURE__ */ t("span", { className: "flex h-8 w-8 items-center justify-center rounded-[6px] border border-border text-muted-foreground", children: /* @__PURE__ */ t(va, { className: "h-3.5 w-3.5", strokeWidth: 1.75 }) }),
1648
1661
  /* @__PURE__ */ t("p", { className: "text-[13px] font-medium", children: "No exports yet" }),
1649
1662
  /* @__PURE__ */ t("p", { className: "text-[12px] text-muted-foreground", children: "Large exports run in the background and land here." })
1650
1663
  ] }) : /* @__PURE__ */ r("div", { className: "flex flex-col", children: [
@@ -1695,14 +1708,14 @@ function Oa() {
1695
1708
  )) }) })
1696
1709
  ] });
1697
1710
  }
1698
- function Qn({
1711
+ function qn({
1699
1712
  variant: e
1700
1713
  }) {
1701
- const a = he((l) => l.activeExports), o = yr(), n = a.size > 0, i = Array.from(a.values()).some(
1714
+ const a = he((l) => l.activeExports), o = Sr(), n = a.size > 0, i = Array.from(a.values()).some(
1702
1715
  (l) => l.status === "completed" || l.status === "failed"
1703
1716
  ), c = o > 0 ? o > 9 ? "9+" : String(o) : null;
1704
- return /* @__PURE__ */ r(Pe, { children: [
1705
- /* @__PURE__ */ t(Me, { asChild: !0, children: /* @__PURE__ */ r(
1717
+ return /* @__PURE__ */ r(Me, { children: [
1718
+ /* @__PURE__ */ t(_e, { asChild: !0, children: /* @__PURE__ */ r(
1706
1719
  T,
1707
1720
  {
1708
1721
  variant: e ?? "ghost",
@@ -1710,7 +1723,7 @@ function Qn({
1710
1723
  className: "relative w-7 px-0 text-muted-foreground hover:text-foreground",
1711
1724
  "aria-label": "Export notifications",
1712
1725
  children: [
1713
- /* @__PURE__ */ t(Cr, { className: "h-3.5 w-3.5" }),
1726
+ /* @__PURE__ */ t(Dr, { className: "h-3.5 w-3.5" }),
1714
1727
  n && /* @__PURE__ */ t(
1715
1728
  "span",
1716
1729
  {
@@ -1721,7 +1734,7 @@ function Qn({
1721
1734
  ]
1722
1735
  }
1723
1736
  ) }),
1724
- /* @__PURE__ */ t(_e, { className: "w-80 p-0", align: "end", sideOffset: 8, children: /* @__PURE__ */ t(Oa, {}) })
1737
+ /* @__PURE__ */ t(Oe, { className: "w-80 p-0", align: "end", sideOffset: 8, children: /* @__PURE__ */ t(Oa, {}) })
1725
1738
  ] });
1726
1739
  }
1727
1740
  function za(e) {
@@ -1758,16 +1771,16 @@ function $a({
1758
1771
  // create and make consumers use `forceClose()` from a dedicated
1759
1772
  // button.
1760
1773
  dismissMode: n ? "passive" : "explicit-only"
1761
- }), h = L((y) => y.dashboard), { setDashboardControlsModel: f } = be(), { participants: g } = wr(Gt(h)), k = Array.from(
1774
+ }), h = L((y) => y.dashboard), { setDashboardControlsModel: f } = be(), { participants: g } = kr(Kt(h)), k = Array.from(
1762
1775
  new Map(
1763
1776
  g.flatMap(
1764
1777
  (y) => y.fieldChoices.map((R) => {
1765
- var F;
1778
+ var I;
1766
1779
  return [
1767
1780
  R.value,
1768
1781
  {
1769
1782
  option: R,
1770
- target: (F = y.fieldTargetMap) == null ? void 0 : F[R.value]
1783
+ target: (I = y.fieldTargetMap) == null ? void 0 : I[R.value]
1771
1784
  }
1772
1785
  ];
1773
1786
  })
@@ -1777,25 +1790,25 @@ function $a({
1777
1790
  new Map(
1778
1791
  g.flatMap(
1779
1792
  (y) => y.metricChoices.map((R) => {
1780
- var F;
1793
+ var I;
1781
1794
  return [
1782
1795
  R.value,
1783
1796
  {
1784
1797
  option: R,
1785
- target: (F = y.metricTargetMap) == null ? void 0 : F[R.value]
1798
+ target: (I = y.metricTargetMap) == null ? void 0 : I[R.value]
1786
1799
  }
1787
1800
  ];
1788
1801
  })
1789
1802
  )
1790
1803
  ).values()
1791
- ), D = Qt({
1804
+ ), D = Yt({
1792
1805
  ...h || {},
1793
1806
  controls: []
1794
- }), S = Nr(h), C = (y, R, F) => {
1807
+ }), S = Er(h), C = (y, R, I) => {
1795
1808
  f(
1796
1809
  y,
1797
1810
  R,
1798
- za(F)
1811
+ za(I)
1799
1812
  );
1800
1813
  }, w = W(() => {
1801
1814
  if (s) {
@@ -1810,7 +1823,7 @@ function $a({
1810
1823
  controls: h.controls || [],
1811
1824
  reservedControlIds: D,
1812
1825
  defaultValues: h.defaultControlValues || {},
1813
- usageByControlId: Sr(h),
1826
+ usageByControlId: Ar(h),
1814
1827
  availableFieldChoices: k,
1815
1828
  availableMetricChoices: x,
1816
1829
  structuralParticipants: g,
@@ -1828,13 +1841,13 @@ function $a({
1828
1841
  ] }),
1829
1842
  E
1830
1843
  ] });
1831
- return n ? /* @__PURE__ */ r(Pe, { open: d, onOpenChange: m, children: [
1832
- /* @__PURE__ */ t(Me, { asChild: !0, children: o || /* @__PURE__ */ r(T, { variant: "outline", className: "h-7 px-2", size: "sm", children: [
1833
- /* @__PURE__ */ t(Pt, { className: "mr-2 h-4 w-4" }),
1844
+ return n ? /* @__PURE__ */ r(Me, { open: d, onOpenChange: m, children: [
1845
+ /* @__PURE__ */ t(_e, { asChild: !0, children: o || /* @__PURE__ */ r(T, { variant: "outline", className: "h-7 px-2", size: "sm", children: [
1846
+ /* @__PURE__ */ t(Et, { className: "mr-2 h-4 w-4" }),
1834
1847
  "Controls"
1835
1848
  ] }) }),
1836
1849
  /* @__PURE__ */ t(
1837
- _e,
1850
+ Oe,
1838
1851
  {
1839
1852
  className: "w-[620px] max-w-[95vw] space-y-4",
1840
1853
  align: "end",
@@ -1851,13 +1864,13 @@ function $a({
1851
1864
  onPointerDownOutside: u,
1852
1865
  children: [
1853
1866
  /* @__PURE__ */ r(
1854
- nt,
1867
+ ut,
1855
1868
  {
1856
1869
  className: l ? "space-y-0" : void 0,
1857
1870
  children: [
1858
1871
  /* @__PURE__ */ t(ke, { className: "text-[15px]", children: U }),
1859
1872
  /* @__PURE__ */ t(
1860
- st,
1873
+ ht,
1861
1874
  {
1862
1875
  className: l ? "sr-only" : "text-[13px]",
1863
1876
  children: l ? "Configure and add a shared dashboard control." : "Add shared controls viewers can use across the dashboard. Each card can decide how to respond to the same control."
@@ -1899,21 +1912,21 @@ function Wa({
1899
1912
  dismissMode: "explicit-only"
1900
1913
  }), d = L((y) => y.dashboard), p = L((y) => y.selectedSheetId), { setDashboardInputs: h } = be(), f = (b = d.sheets) == null ? void 0 : b.find(
1901
1914
  (y) => y.id === p
1902
- ), g = (f == null ? void 0 : f.kind) === "document" && !!f.document, k = Z(
1903
- () => g && (f != null && f.document) ? Dr(d, f.id) : [],
1915
+ ), g = (f == null ? void 0 : f.kind) === "document" && !!f.document, k = X(
1916
+ () => g && (f != null && f.document) ? Ir(d, f.id) : [],
1904
1917
  [d, g, f == null ? void 0 : f.document, f == null ? void 0 : f.id]
1905
- ), x = Z(
1918
+ ), x = X(
1906
1919
  () => k.filter(
1907
1920
  (y) => y.kind === "control"
1908
1921
  ),
1909
1922
  [k]
1910
- ), D = Z(
1923
+ ), D = X(
1911
1924
  () => x.map((y) => y.control),
1912
1925
  [x]
1913
- ), S = Z(
1926
+ ), S = X(
1914
1927
  () => qa(D),
1915
1928
  [D]
1916
- ), C = Z(
1929
+ ), C = X(
1917
1930
  () => Ha(d),
1918
1931
  [d]
1919
1932
  ), w = W(() => {
@@ -1923,15 +1936,15 @@ function Wa({
1923
1936
  }
1924
1937
  u(!1);
1925
1938
  }, [n, i, u]), E = W(
1926
- (y, R, F) => {
1939
+ (y, R, I) => {
1927
1940
  !g || !(f != null && f.document) || h(
1928
- Qa({
1941
+ Ka({
1929
1942
  allInputs: d.inputs || [],
1930
1943
  documentSheetId: f.id,
1931
1944
  currentDocumentInputs: k,
1932
1945
  nextControls: y,
1933
1946
  nextDefaultValues: R,
1934
- change: F
1947
+ change: I
1935
1948
  })
1936
1949
  );
1937
1950
  },
@@ -1950,10 +1963,10 @@ function Wa({
1950
1963
  onEscapeKeyDown: m,
1951
1964
  onPointerDownOutside: m,
1952
1965
  children: [
1953
- /* @__PURE__ */ r(nt, { className: c ? "space-y-0" : void 0, children: [
1966
+ /* @__PURE__ */ r(ut, { className: c ? "space-y-0" : void 0, children: [
1954
1967
  /* @__PURE__ */ t(ke, { className: "text-[15px]", children: c ? "Add document control" : "Document Controls" }),
1955
1968
  /* @__PURE__ */ t(
1956
- st,
1969
+ ht,
1957
1970
  {
1958
1971
  className: c ? "sr-only" : "text-[13px]",
1959
1972
  children: c ? "Configure and add a document-local control input." : "Add document-local control inputs. They are stored on this document sheet and are not dashboard controls."
@@ -1999,7 +2012,7 @@ function Ga(e, a) {
1999
2012
  defaultValue: a[e.id]
2000
2013
  } : e.defaultValue === void 0 ? e : { ...e, defaultValue: void 0 } : e.defaultValue === void 0 ? e : { ...e, defaultValue: void 0 };
2001
2014
  }
2002
- function Qa({
2015
+ function Ka({
2003
2016
  allInputs: e,
2004
2017
  documentSheetId: a,
2005
2018
  currentDocumentInputs: o,
@@ -2022,7 +2035,7 @@ function Qa({
2022
2035
  if (!f)
2023
2036
  continue;
2024
2037
  l.add(f.id);
2025
- const g = Kt(
2038
+ const g = Qt(
2026
2039
  f.id,
2027
2040
  [...e, ...u].filter(
2028
2041
  (x) => x.id !== h.id
@@ -2038,7 +2051,7 @@ function Qa({
2038
2051
  }
2039
2052
  for (const h of c.values())
2040
2053
  l.has(h.id) || u.push(
2041
- kr({
2054
+ Fr({
2042
2055
  control: h,
2043
2056
  existingInputs: [...e, ...u],
2044
2057
  sheetId: a
@@ -2051,7 +2064,7 @@ function Qa({
2051
2064
  (h) => !d.has(h.id)
2052
2065
  ), ...u];
2053
2066
  }
2054
- function Ka({
2067
+ function Ya({
2055
2068
  showFilters: e,
2056
2069
  onShowFiltersChange: a,
2057
2070
  pickerContent: o,
@@ -2076,8 +2089,8 @@ function Ka({
2076
2089
  s
2077
2090
  ),
2078
2091
  children: [
2079
- /* @__PURE__ */ r(Pe, { open: e, onOpenChange: a, children: [
2080
- /* @__PURE__ */ t(Me, { asChild: !0, children: /* @__PURE__ */ r(
2092
+ /* @__PURE__ */ r(Me, { open: e, onOpenChange: a, children: [
2093
+ /* @__PURE__ */ t(_e, { asChild: !0, children: /* @__PURE__ */ r(
2081
2094
  T,
2082
2095
  {
2083
2096
  variant: "ghost",
@@ -2087,13 +2100,13 @@ function Ka({
2087
2100
  c
2088
2101
  ),
2089
2102
  children: [
2090
- e ? /* @__PURE__ */ t(ca, { className: "h-3.5 w-3.5" }) : /* @__PURE__ */ t(Bt, { className: "h-3.5 w-3.5" }),
2103
+ e ? /* @__PURE__ */ t(ca, { className: "h-3.5 w-3.5" }) : /* @__PURE__ */ t(Vt, { className: "h-3.5 w-3.5" }),
2091
2104
  "Filter"
2092
2105
  ]
2093
2106
  }
2094
2107
  ) }),
2095
2108
  /* @__PURE__ */ t(
2096
- _e,
2109
+ Oe,
2097
2110
  {
2098
2111
  align: "end",
2099
2112
  sideOffset: 6,
@@ -2106,8 +2119,8 @@ function Ka({
2106
2119
  }
2107
2120
  )
2108
2121
  ] }),
2109
- /* @__PURE__ */ r(Pe, { open: p, onOpenChange: h, children: [
2110
- /* @__PURE__ */ t(Me, { asChild: !0, children: /* @__PURE__ */ t(
2122
+ /* @__PURE__ */ r(Me, { open: p, onOpenChange: h, children: [
2123
+ /* @__PURE__ */ t(_e, { asChild: !0, children: /* @__PURE__ */ t(
2111
2124
  T,
2112
2125
  {
2113
2126
  variant: "ghost",
@@ -2121,7 +2134,7 @@ function Ka({
2121
2134
  }
2122
2135
  ) }),
2123
2136
  /* @__PURE__ */ t(
2124
- _e,
2137
+ Oe,
2125
2138
  {
2126
2139
  align: "end",
2127
2140
  sideOffset: 6,
@@ -2138,10 +2151,10 @@ function Ka({
2138
2151
  }
2139
2152
  );
2140
2153
  }
2141
- function Ya() {
2154
+ function Qa() {
2142
2155
  ua();
2143
- const e = L((l) => l.selectedSheetId), a = L((l) => l.selectedFrameId), o = L((l) => l.dashboard), n = L((l) => l.actions.getSelectedFrame), { setSelectedFrameId: i } = be(), { setCard: s } = Dt(), c = me((l) => l.card.dataSource);
2144
- return K(() => {
2156
+ const e = L((l) => l.selectedSheetId), a = L((l) => l.selectedFrameId), o = L((l) => l.dashboard), n = L((l) => l.actions.getSelectedFrame), { setSelectedFrameId: i } = be(), { setCard: s } = kt(), c = me((l) => l.card.dataSource);
2157
+ return Y(() => {
2145
2158
  var u, d;
2146
2159
  let l = n();
2147
2160
  if (!l) {
@@ -2156,11 +2169,11 @@ function Ya() {
2156
2169
  hasEntities: !!(c != null && c.selectedEntities && c.selectedEntities.length > 0)
2157
2170
  };
2158
2171
  }
2159
- function Za() {
2172
+ function Xa() {
2160
2173
  const e = L((l) => l.dashboard), a = L(
2161
2174
  (l) => l.semanticExecutionPayload
2162
- ), o = L((l) => l.actions.addFilter), { hasEntities: n } = Ya(), { isLoading: i } = Er(), s = Z(
2163
- () => Yt(e, a),
2175
+ ), o = L((l) => l.actions.addFilter), { hasEntities: n } = Qa(), { isLoading: i } = Lr(), s = X(
2176
+ () => Xt(e, a),
2164
2177
  [e, a]
2165
2178
  ), m = !Zt(e.filters) && s.hasEligibleCards && !i;
2166
2179
  return /* @__PURE__ */ r("div", { className: "flex h-[520px] w-[400px] flex-col", children: [
@@ -2168,11 +2181,11 @@ function Za() {
2168
2181
  "button",
2169
2182
  {
2170
2183
  type: "button",
2171
- onClick: () => o(Xt()),
2184
+ onClick: () => o(Jt()),
2172
2185
  title: `Applies to ${s.eligibleCardCount} of ${s.totalCardCount} date-aware cards`,
2173
2186
  className: "flex w-full items-start gap-2 rounded-control 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",
2174
2187
  children: [
2175
- /* @__PURE__ */ t(va, { className: "mt-0.5 h-3.5 w-3.5 shrink-0 text-muted-foreground" }),
2188
+ /* @__PURE__ */ t(xa, { className: "mt-0.5 h-3.5 w-3.5 shrink-0 text-muted-foreground" }),
2176
2189
  /* @__PURE__ */ r("span", { className: "flex min-w-0 flex-col", children: [
2177
2190
  /* @__PURE__ */ t("span", { className: "text-[12px] font-medium text-foreground", children: "Add global date filter" }),
2178
2191
  /* @__PURE__ */ t("span", { className: "text-[11px] leading-[1.4] text-muted-foreground", children: "One date range across all date-aware cards." })
@@ -2181,15 +2194,15 @@ function Za() {
2181
2194
  }
2182
2195
  ) }),
2183
2196
  !n && /* @__PURE__ */ r("div", { className: "flex flex-1 flex-col items-center justify-center px-6 py-8 text-center", children: [
2184
- /* @__PURE__ */ t(aa, { className: "mb-3 h-10 w-10 text-muted-foreground/50" }),
2197
+ /* @__PURE__ */ t(Br, { className: "mb-3 h-10 w-10 text-muted-foreground/50" }),
2185
2198
  /* @__PURE__ */ t("h3", { className: "mb-1 text-[13px] font-medium text-foreground", children: "No fields configured" }),
2186
2199
  /* @__PURE__ */ t("p", { className: "text-[11px] text-muted-foreground", children: "Configure a data source for this card to enable filtering." })
2187
2200
  ] }),
2188
- n && /* @__PURE__ */ t("div", { className: "flex flex-1 overflow-hidden", children: /* @__PURE__ */ t(Ar, { context: "filter" }) })
2201
+ n && /* @__PURE__ */ t("div", { className: "flex flex-1 overflow-hidden", children: /* @__PURE__ */ t(Tr, { context: "filter" }) })
2189
2202
  ] });
2190
2203
  }
2191
2204
  const wt = !1;
2192
- function Xa({
2205
+ function Za({
2193
2206
  onAddFilter: e,
2194
2207
  onAddControl: a,
2195
2208
  onManageControls: o,
@@ -2205,7 +2218,7 @@ function Xa({
2205
2218
  /* @__PURE__ */ t(
2206
2219
  Je,
2207
2220
  {
2208
- icon: Bt,
2221
+ icon: Vt,
2209
2222
  label: "Add filter",
2210
2223
  onClick: () => {
2211
2224
  e(), n();
@@ -2215,7 +2228,7 @@ function Xa({
2215
2228
  /* @__PURE__ */ t(
2216
2229
  Je,
2217
2230
  {
2218
- icon: Pt,
2231
+ icon: Et,
2219
2232
  label: "Add control",
2220
2233
  onClick: () => {
2221
2234
  a(), n();
@@ -2225,7 +2238,7 @@ function Xa({
2225
2238
  /* @__PURE__ */ t(
2226
2239
  Je,
2227
2240
  {
2228
- icon: Tt,
2241
+ icon: Pt,
2229
2242
  label: "Manage controls",
2230
2243
  onClick: () => {
2231
2244
  o(), n();
@@ -2275,7 +2288,7 @@ function Ja({
2275
2288
  onCheckedChange: n
2276
2289
  }) {
2277
2290
  return /* @__PURE__ */ r("div", { className: "flex items-center gap-2 rounded-control px-1 py-1 transition-colors hover:bg-muted/40 focus-within:bg-muted/40", children: [
2278
- /* @__PURE__ */ t(at, { id: e, checked: o, onCheckedChange: n }),
2291
+ /* @__PURE__ */ t(ct, { id: e, checked: o, onCheckedChange: n }),
2279
2292
  /* @__PURE__ */ t(
2280
2293
  Ne,
2281
2294
  {
@@ -2286,7 +2299,7 @@ function Ja({
2286
2299
  )
2287
2300
  ] });
2288
2301
  }
2289
- function Kn({
2302
+ function Gn({
2290
2303
  size: e,
2291
2304
  className: a,
2292
2305
  primaryButtonClassName: o,
@@ -2295,9 +2308,9 @@ function Kn({
2295
2308
  settingsContentClassName: s
2296
2309
  }) {
2297
2310
  var U;
2298
- const [c, m] = A(null), l = L((b) => b.dashboard), u = L((b) => b.selectedSheetId), d = L((b) => b.showFilters), p = Fr((b) => b.setPanelOpen), h = L((b) => b.actions), { setDocumentPanelTarget: f, setShowFilters: g } = h, k = (U = l.sheets) == null ? void 0 : U.find(
2311
+ const [c, m] = A(null), l = L((b) => b.dashboard), u = L((b) => b.selectedSheetId), d = L((b) => b.showFilters), p = Ur((b) => b.setPanelOpen), h = L((b) => b.actions), { setDocumentPanelTarget: f, setShowFilters: g } = h, k = (U = l.sheets) == null ? void 0 : U.find(
2299
2312
  (b) => b.id === u
2300
- ), x = Jt(k), D = W((b) => {
2313
+ ), x = er(k), D = W((b) => {
2301
2314
  window.setTimeout(() => {
2302
2315
  m(b);
2303
2316
  }, 0);
@@ -2328,13 +2341,13 @@ function Kn({
2328
2341
  }, [D]);
2329
2342
  return /* @__PURE__ */ r($, { children: [
2330
2343
  /* @__PURE__ */ t(
2331
- Ka,
2344
+ Ya,
2332
2345
  {
2333
2346
  showFilters: x ? !1 : d,
2334
2347
  onShowFiltersChange: S,
2335
- pickerContent: /* @__PURE__ */ t(Za, {}),
2348
+ pickerContent: /* @__PURE__ */ t(Xa, {}),
2336
2349
  settingsContent: (b) => /* @__PURE__ */ t(
2337
- Xa,
2350
+ Za,
2338
2351
  {
2339
2352
  onAddFilter: C,
2340
2353
  onAddControl: w,
@@ -2397,7 +2410,7 @@ function en({
2397
2410
  }
2398
2411
  );
2399
2412
  }
2400
- const tn = "text-[10px] font-medium uppercase tracking-[0.08em] text-muted-foreground", jt = "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", Ve = "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";
2413
+ const tn = "text-[10px] font-medium uppercase tracking-[0.08em] text-muted-foreground", jt = "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", Pe = "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";
2401
2414
  function rn(e) {
2402
2415
  return e === "dashboard" ? "This dashboard" : "Project";
2403
2416
  }
@@ -2416,7 +2429,7 @@ function an(e) {
2416
2429
  return c < 5 ? `${c}w ago` : `${Math.round(s / 30)}mo ago`;
2417
2430
  }
2418
2431
  function nn(e) {
2419
- return e.scheduleExpr ? ga(
2432
+ return e.scheduleExpr ? fa(
2420
2433
  e.scheduleExpr,
2421
2434
  e.timezone || "UTC"
2422
2435
  ) ?? "Invalid schedule" : "On demand";
@@ -2487,7 +2500,7 @@ function dn({
2487
2500
  contentKind: S,
2488
2501
  hideHeader: C = !1
2489
2502
  }) {
2490
- const w = e.length, E = e.filter((F) => F.status === "ACTIVE").length, U = S === "reports" ? w === 1 ? "report" : "reports" : S === "briefings" ? w === 1 ? "briefing" : "briefings" : w === 1 ? "item" : "items", b = e.find((F) => F.hasActiveRun) ?? null, y = S ?? "reports & briefings", R = o === "dashboard" ? a : `Project ${y}`;
2503
+ const w = e.length, E = e.filter((I) => I.status === "ACTIVE").length, U = S === "reports" ? w === 1 ? "report" : "reports" : S === "briefings" ? w === 1 ? "briefing" : "briefings" : w === 1 ? "item" : "items", b = e.find((I) => I.hasActiveRun) ?? null, y = S ?? "reports & briefings", R = o === "dashboard" ? a : `Project ${y}`;
2491
2504
  return /* @__PURE__ */ r(
2492
2505
  "section",
2493
2506
  {
@@ -2506,7 +2519,7 @@ function dn({
2506
2519
  onClick: c,
2507
2520
  className: "rounded-control p-1 text-muted-foreground hover:bg-muted hover:text-foreground",
2508
2521
  "aria-label": `Close ${y.replace("&", "and")} panel`,
2509
- children: /* @__PURE__ */ t(Qe, { className: "h-3.5 w-3.5" })
2522
+ children: /* @__PURE__ */ t(Ke, { className: "h-3.5 w-3.5" })
2510
2523
  }
2511
2524
  )
2512
2525
  ] }),
@@ -2548,12 +2561,12 @@ function dn({
2548
2561
  // case without crowding the toolbar.
2549
2562
  /* @__PURE__ */ t(re, { className: "h-3.5 w-3.5 animate-spin text-muted-foreground" })
2550
2563
  ) : null,
2551
- w > 0 && u ? p && d ? /* @__PURE__ */ r(je, { children: [
2552
- /* @__PURE__ */ t(We, { asChild: !0, children: /* @__PURE__ */ r("button", { className: Ve, children: [
2564
+ w > 0 && u ? p && d ? /* @__PURE__ */ r(We, { children: [
2565
+ /* @__PURE__ */ t(He, { asChild: !0, children: /* @__PURE__ */ r("button", { className: Pe, children: [
2553
2566
  /* @__PURE__ */ t(ge, { className: "h-3 w-3" }),
2554
2567
  " New"
2555
2568
  ] }) }),
2556
- /* @__PURE__ */ r(He, { align: "end", children: [
2569
+ /* @__PURE__ */ r(qe, { align: "end", children: [
2557
2570
  /* @__PURE__ */ t(q, { onClick: () => l("scheduled_report"), children: "Schedule a report" }),
2558
2571
  /* @__PURE__ */ t(
2559
2572
  q,
@@ -2567,7 +2580,7 @@ function dn({
2567
2580
  "button",
2568
2581
  {
2569
2582
  onClick: () => l("scheduled_report"),
2570
- className: Ve,
2583
+ className: Pe,
2571
2584
  children: [
2572
2585
  /* @__PURE__ */ t(ge, { className: "h-3 w-3" }),
2573
2586
  " Schedule report"
@@ -2577,7 +2590,7 @@ function dn({
2577
2590
  "button",
2578
2591
  {
2579
2592
  onClick: () => l("analytical_briefing"),
2580
- className: Ve,
2593
+ className: Pe,
2581
2594
  children: [
2582
2595
  /* @__PURE__ */ t(ge, { className: "h-3 w-3" }),
2583
2596
  " New briefing"
@@ -2604,18 +2617,18 @@ function dn({
2604
2617
  contentKind: S
2605
2618
  }
2606
2619
  ) : null,
2607
- e.map((F) => /* @__PURE__ */ t(
2620
+ e.map((I) => /* @__PURE__ */ t(
2608
2621
  hn,
2609
2622
  {
2610
- briefing: F,
2611
- isOpening: k === F.id,
2612
- isBusy: x === F.id,
2613
- onOpen: () => m(F.id),
2614
- onRunNow: () => h(F),
2615
- onTogglePause: () => f(F),
2616
- onDelete: () => g(F)
2623
+ briefing: I,
2624
+ isOpening: k === I.id,
2625
+ isBusy: x === I.id,
2626
+ onOpen: () => m(I.id),
2627
+ onRunNow: () => h(I),
2628
+ onTogglePause: () => f(I),
2629
+ onDelete: () => g(I)
2617
2630
  },
2618
- F.id
2631
+ I.id
2619
2632
  ))
2620
2633
  ] }),
2621
2634
  D ? /* @__PURE__ */ t("div", { className: "border-t border-border px-4 py-2.5", children: /* @__PURE__ */ r(
@@ -2625,7 +2638,7 @@ function dn({
2625
2638
  className: G(jt, "h-6 px-1 text-[11px]"),
2626
2639
  children: [
2627
2640
  "Manage all reports & briefings",
2628
- /* @__PURE__ */ t(xa, { className: "h-3 w-3" })
2641
+ /* @__PURE__ */ t(ba, { className: "h-3 w-3" })
2629
2642
  ]
2630
2643
  }
2631
2644
  ) }) : null
@@ -2656,7 +2669,7 @@ function cn({
2656
2669
  "button",
2657
2670
  {
2658
2671
  onClick: () => e("scheduled_report"),
2659
- className: Ve,
2672
+ className: Pe,
2660
2673
  children: [
2661
2674
  /* @__PURE__ */ t(ge, { className: "h-3 w-3" }),
2662
2675
  " Schedule a report"
@@ -2860,7 +2873,7 @@ function hn({
2860
2873
  onTogglePause: s,
2861
2874
  onDelete: c
2862
2875
  }) {
2863
- const m = e.status === "PAUSED", l = e.hasActiveRun, u = sn(e), d = an(e.lastRunAt), p = e.lastRunStatus, h = se(e), f = p === "SUCCESS" ? Ue.success.dot : p === "FAILED" ? Ue.danger.dot : p ? Ue.warning.dot : Ue.neutral.dot;
2876
+ const m = e.status === "PAUSED", l = e.hasActiveRun, u = sn(e), d = an(e.lastRunAt), p = e.lastRunStatus, h = se(e), f = p === "SUCCESS" ? Re.success.dot : p === "FAILED" ? Re.danger.dot : p ? Re.warning.dot : Re.neutral.dot;
2864
2877
  return /* @__PURE__ */ r(
2865
2878
  "div",
2866
2879
  {
@@ -2889,7 +2902,7 @@ function hn({
2889
2902
  /* @__PURE__ */ t("span", { className: "text-border", children: "·" }),
2890
2903
  /* @__PURE__ */ t("span", { children: on(e) }),
2891
2904
  /* @__PURE__ */ t("span", { className: "text-border", children: "·" }),
2892
- /* @__PURE__ */ t(Ir, { className: "h-3 w-3" }),
2905
+ /* @__PURE__ */ t(Rr, { className: "h-3 w-3" }),
2893
2906
  /* @__PURE__ */ t("span", { className: "truncate", children: nn(e) }),
2894
2907
  e.lastRunAt ? /* @__PURE__ */ r($, { children: [
2895
2908
  /* @__PURE__ */ t("span", { className: "text-border", children: "·" }),
@@ -2914,20 +2927,20 @@ function hn({
2914
2927
  ]
2915
2928
  }
2916
2929
  ),
2917
- /* @__PURE__ */ t("div", { className: "absolute right-3 top-3", children: o ? /* @__PURE__ */ t(re, { className: "h-3.5 w-3.5 animate-spin text-muted-foreground/70" }) : a ? /* @__PURE__ */ t(re, { className: "h-3.5 w-3.5 animate-spin text-muted-foreground/70" }) : /* @__PURE__ */ r(je, { children: [
2918
- /* @__PURE__ */ t(We, { asChild: !0, children: /* @__PURE__ */ t(
2930
+ /* @__PURE__ */ t("div", { className: "absolute right-3 top-3", children: o ? /* @__PURE__ */ t(re, { className: "h-3.5 w-3.5 animate-spin text-muted-foreground/70" }) : a ? /* @__PURE__ */ t(re, { className: "h-3.5 w-3.5 animate-spin text-muted-foreground/70" }) : /* @__PURE__ */ r(We, { children: [
2931
+ /* @__PURE__ */ t(He, { asChild: !0, children: /* @__PURE__ */ t(
2919
2932
  "button",
2920
2933
  {
2921
2934
  type: "button",
2922
2935
  onClick: (g) => g.stopPropagation(),
2923
2936
  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",
2924
2937
  "aria-label": `${h.noun === "report" ? "Report" : "Briefing"} actions`,
2925
- children: /* @__PURE__ */ t(At, { className: "h-3.5 w-3.5" })
2938
+ children: /* @__PURE__ */ t(Lt, { className: "h-3.5 w-3.5" })
2926
2939
  }
2927
2940
  ) }),
2928
- /* @__PURE__ */ r(He, { align: "end", className: "w-44", children: [
2941
+ /* @__PURE__ */ r(qe, { align: "end", className: "w-44", children: [
2929
2942
  /* @__PURE__ */ r(q, { onClick: n, children: [
2930
- /* @__PURE__ */ t(Tt, { className: "h-3.5 w-3.5" }),
2943
+ /* @__PURE__ */ t(Pt, { className: "h-3.5 w-3.5" }),
2931
2944
  "Edit ",
2932
2945
  h.noun
2933
2946
  ] }),
@@ -2938,7 +2951,7 @@ function hn({
2938
2951
  g.preventDefault(), i();
2939
2952
  },
2940
2953
  children: [
2941
- /* @__PURE__ */ t(Lr, { className: "h-3.5 w-3.5" }),
2954
+ /* @__PURE__ */ t(Vr, { className: "h-3.5 w-3.5" }),
2942
2955
  "Run now"
2943
2956
  ]
2944
2957
  }
@@ -2950,15 +2963,15 @@ function hn({
2950
2963
  g.preventDefault(), s();
2951
2964
  },
2952
2965
  children: m ? /* @__PURE__ */ r($, { children: [
2953
- /* @__PURE__ */ t(Br, { className: "h-3.5 w-3.5" }),
2966
+ /* @__PURE__ */ t(Pr, { className: "h-3.5 w-3.5" }),
2954
2967
  "Resume"
2955
2968
  ] }) : /* @__PURE__ */ r($, { children: [
2956
- /* @__PURE__ */ t(Tr, { className: "h-3.5 w-3.5" }),
2969
+ /* @__PURE__ */ t(Mr, { className: "h-3.5 w-3.5" }),
2957
2970
  "Pause"
2958
2971
  ] })
2959
2972
  }
2960
2973
  ) : null,
2961
- /* @__PURE__ */ t(ze, {}),
2974
+ /* @__PURE__ */ t($e, {}),
2962
2975
  /* @__PURE__ */ r(
2963
2976
  q,
2964
2977
  {
@@ -2967,7 +2980,7 @@ function hn({
2967
2980
  },
2968
2981
  className: "text-destructive focus:bg-destructive/10 focus:text-destructive",
2969
2982
  children: [
2970
- /* @__PURE__ */ t(Oe, { className: "h-3.5 w-3.5" }),
2983
+ /* @__PURE__ */ t(ze, { className: "h-3.5 w-3.5" }),
2971
2984
  "Delete ",
2972
2985
  h.noun
2973
2986
  ]
@@ -3006,12 +3019,12 @@ async function xn(e) {
3006
3019
  return o;
3007
3020
  }
3008
3021
  const vn = {
3009
- listBriefings: zr,
3010
- getBriefing: Or,
3011
- pauseBriefing: _r,
3012
- resumeBriefing: Mr,
3013
- deleteBriefing: Pr,
3014
- runBriefingNow: Vr
3022
+ listBriefings: qr,
3023
+ getBriefing: Hr,
3024
+ pauseBriefing: Wr,
3025
+ resumeBriefing: jr,
3026
+ deleteBriefing: $r,
3027
+ runBriefingNow: zr
3015
3028
  };
3016
3029
  function yn({
3017
3030
  briefingId: e,
@@ -3022,7 +3035,7 @@ function yn({
3022
3035
  onTimeout: s,
3023
3036
  onExpand: c
3024
3037
  }) {
3025
- const [m, l] = A(a), { startRun: u } = Kr({
3038
+ const [m, l] = A(a), { startRun: u } = ea({
3026
3039
  apiServiceUrl: o,
3027
3040
  token: n,
3028
3041
  intervalMs: mn,
@@ -3031,7 +3044,7 @@ function yn({
3031
3044
  apiServiceUrl: p,
3032
3045
  token: h,
3033
3046
  runId: f
3034
- }) => Yr(p, h, e, f),
3047
+ }) => ta(p, h, e, f),
3035
3048
  onRun: (p) => {
3036
3049
  l(p);
3037
3050
  },
@@ -3042,12 +3055,12 @@ function yn({
3042
3055
  s();
3043
3056
  }
3044
3057
  }), d = ce(!1);
3045
- return K(() => {
3046
- d.current || (d.current = !0, Zr(a.status) ? u(a) : Xr(a.status) && i(a));
3047
- }, [a, i, u]), /* @__PURE__ */ t(Jr, { run: m, onExpand: c });
3058
+ return Y(() => {
3059
+ d.current || (d.current = !0, ra(a.status) ? u(a) : aa(a.status) && i(a));
3060
+ }, [a, i, u]), /* @__PURE__ */ t(na, { run: m, onExpand: c });
3048
3061
  }
3049
- function Yn(e) {
3050
- return /* @__PURE__ */ t(Ur, { children: /* @__PURE__ */ t(Cn, { ...e }) });
3062
+ function Kn(e) {
3063
+ return /* @__PURE__ */ t(_r, { children: /* @__PURE__ */ t(Cn, { ...e }) });
3051
3064
  }
3052
3065
  function Cn({
3053
3066
  dashboardId: e,
@@ -3063,26 +3076,26 @@ function Cn({
3063
3076
  workflowIntent: d,
3064
3077
  client: p
3065
3078
  }) {
3066
- const { authToken: h, tokenProps: f } = qe(), g = Rr(), k = !d || g.canCreate && (d === "scheduled_report" || g.analyticalBriefingsEnabled), [x, D] = A(!1), S = m ?? x, C = (N) => {
3079
+ const { authToken: h, tokenProps: f } = Ge(), g = Or(), k = !d || g.canCreate && (d === "scheduled_report" || g.analyticalBriefingsEnabled), [x, D] = A(!1), S = m ?? x, C = (N) => {
3067
3080
  m === void 0 && D(N), l == null || l(N);
3068
3081
  }, [w, E] = A(
3069
3082
  d ? "author" : "list"
3070
3083
  ), [U, b] = A(
3071
3084
  d ?? "analytical_briefing"
3072
- ), [y, R] = A("dashboard"), [F, H] = A(
3085
+ ), [y, R] = A("dashboard"), [I, H] = A(
3073
3086
  []
3074
- ), [I, P] = A(null), X = d && !k && !I ? "list" : w, [ae, Ee] = A(!1), [oe, Ae] = A(null), [Fe, ie] = A(null), [j, J] = A(
3087
+ ), [F, P] = A(null), Z = d && !k && !F ? "list" : w, [ae, Ae] = A(!1), [oe, Ie] = A(null), [Fe, ie] = A(null), [j, J] = A(
3075
3088
  null
3076
- ), [le, ee] = A(null), Ie = ce(null), xe = ce(S);
3077
- K(() => {
3089
+ ), [le, ee] = A(null), Le = ce(null), xe = ce(S);
3090
+ Y(() => {
3078
3091
  const N = S && !xe.current;
3079
3092
  xe.current = S, !(!N || !d) && (P(null), R("dashboard"), b(d), E("author"), ee(null));
3080
3093
  }, [S, d]);
3081
3094
  const [ue, pe] = A(
3082
3095
  null
3083
- ), [Y, ve] = A(null), _ = o ?? (f == null ? void 0 : f.apiServiceUrl), O = n ?? (h == null ? void 0 : h.accessToken), ne = Z(() => ({ ...vn, ...p }), [p]), fe = fn(a), Le = Z(() => {
3096
+ ), [Q, ve] = A(null), _ = o ?? (f == null ? void 0 : f.apiServiceUrl), O = n ?? (h == null ? void 0 : h.accessToken), ne = X(() => ({ ...vn, ...p }), [p]), fe = fn(a), Be = X(() => {
3084
3097
  const N = bn(
3085
- F,
3098
+ I,
3086
3099
  y,
3087
3100
  e
3088
3101
  );
@@ -3090,9 +3103,9 @@ function Cn({
3090
3103
  return N;
3091
3104
  const V = d === "scheduled_report" ? "report" : "briefing";
3092
3105
  return N.filter(
3093
- (Be) => se(Be).noun === V
3106
+ (Te) => se(Te).noun === V
3094
3107
  );
3095
- }, [e, F, y, d]), Ke = Z(() => y === "dashboard" ? {
3108
+ }, [e, I, y, d]), Ye = X(() => y === "dashboard" ? {
3096
3109
  source: { type: "dashboard", dashboardId: e },
3097
3110
  label: fe,
3098
3111
  detail: gn(fe)
@@ -3100,13 +3113,13 @@ function Cn({
3100
3113
  source: { type: "project" },
3101
3114
  label: "This project",
3102
3115
  detail: "Use any data in this project."
3103
- }, [e, fe, y]), ye = !!(_ && O), Ce = ba({
3116
+ }, [e, fe, y]), ye = !!(_ && O), Ce = ga({
3104
3117
  canCreate: g.canCreate,
3105
3118
  analyticalBriefingsEnabled: g.analyticalBriefingsEnabled,
3106
3119
  scheduledReportAvailable: y === "dashboard"
3107
- }), Q = W(async () => {
3120
+ }), K = W(async () => {
3108
3121
  if (!(!_ || !O)) {
3109
- Ee(!0), ee(null);
3122
+ Ae(!0), ee(null);
3110
3123
  try {
3111
3124
  H(
3112
3125
  await xn({
@@ -3120,20 +3133,20 @@ function Cn({
3120
3133
  N instanceof Error ? N.message : "Could not load briefings."
3121
3134
  );
3122
3135
  } finally {
3123
- Ee(!1);
3136
+ Ae(!1);
3124
3137
  }
3125
3138
  }
3126
3139
  }, [ne, _, O]);
3127
- K(() => {
3128
- !S || X !== "list" || !ye || Q();
3129
- }, [ye, X, Q, S]);
3140
+ Y(() => {
3141
+ !S || Z !== "list" || !ye || K();
3142
+ }, [ye, Z, K, S]);
3130
3143
  const we = () => {
3131
3144
  P(null), R("dashboard"), E("list"), C(!0);
3132
3145
  }, v = (N) => {
3133
3146
  P(null), b(N), E("author");
3134
3147
  }, B = async (N) => {
3135
3148
  if (!(!_ || !O)) {
3136
- Ae(N), ee(null);
3149
+ Ie(N), ee(null);
3137
3150
  try {
3138
3151
  const V = await ne.getBriefing(
3139
3152
  _,
@@ -3146,7 +3159,7 @@ function Cn({
3146
3159
  V instanceof Error ? V.message : "Could not open briefing."
3147
3160
  );
3148
3161
  } finally {
3149
- Ae(null);
3162
+ Ie(null);
3150
3163
  }
3151
3164
  }
3152
3165
  }, M = async (N) => {
@@ -3158,7 +3171,7 @@ function Cn({
3158
3171
  O,
3159
3172
  N.id,
3160
3173
  { requestId: wn() }
3161
- ), Q();
3174
+ ), K();
3162
3175
  } catch (V) {
3163
3176
  z.error(
3164
3177
  V instanceof Error ? V.message : "Could not start the run."
@@ -3169,10 +3182,10 @@ function Cn({
3169
3182
  }
3170
3183
  }, te = async (N) => {
3171
3184
  if (!_ || !O) return;
3172
- const { noun: V } = se(N), Be = V === "report" ? "Report" : "Briefing";
3185
+ const { noun: V } = se(N), Te = V === "report" ? "Report" : "Briefing";
3173
3186
  ie(N.id);
3174
3187
  try {
3175
- const Te = N.status === "PAUSED" ? await ne.resumeBriefing(
3188
+ const Ue = N.status === "PAUSED" ? await ne.resumeBriefing(
3176
3189
  _,
3177
3190
  O,
3178
3191
  N.id
@@ -3182,11 +3195,11 @@ function Cn({
3182
3195
  N.id
3183
3196
  );
3184
3197
  z.success(
3185
- Te.briefing.status === "PAUSED" ? `${Be} paused` : `${Be} resumed`
3186
- ), Q();
3187
- } catch (Te) {
3198
+ Ue.briefing.status === "PAUSED" ? `${Te} paused` : `${Te} resumed`
3199
+ ), K();
3200
+ } catch (Ue) {
3188
3201
  z.error(
3189
- Te instanceof Error ? Te.message : `Could not update the ${V} status.`
3202
+ Ue instanceof Error ? Ue.message : `Could not update the ${V} status.`
3190
3203
  );
3191
3204
  } finally {
3192
3205
  ie(null);
@@ -3202,7 +3215,7 @@ function Cn({
3202
3215
  N.id
3203
3216
  );
3204
3217
  const { noun: V } = se(N);
3205
- z.success(`${V === "report" ? "Report" : "Briefing"} deleted`), J(null), Q();
3218
+ z.success(`${V === "report" ? "Report" : "Briefing"} deleted`), J(null), K();
3206
3219
  } catch (V) {
3207
3220
  z.error(
3208
3221
  V instanceof Error ? V.message : "Could not delete the briefing."
@@ -3210,8 +3223,8 @@ function Cn({
3210
3223
  } finally {
3211
3224
  ie(null);
3212
3225
  }
3213
- }, Ht = Le.length;
3214
- return g.surfaceVisible ? /* @__PURE__ */ r($r, { open: S, onOpenChange: C, children: [
3226
+ }, Ht = Be.length;
3227
+ return g.surfaceVisible ? /* @__PURE__ */ r(Gr, { open: S, onOpenChange: C, children: [
3215
3228
  u ? null : /* @__PURE__ */ t(
3216
3229
  en,
3217
3230
  {
@@ -3222,20 +3235,20 @@ function Cn({
3222
3235
  }
3223
3236
  ),
3224
3237
  /* @__PURE__ */ r(
3225
- jr,
3238
+ Kr,
3226
3239
  {
3227
- ref: Ie,
3240
+ ref: Le,
3228
3241
  side: "right",
3229
3242
  hideClose: !0,
3230
3243
  className: "flex h-full w-full flex-col overflow-hidden p-0 outline-none sm:max-w-[560px]",
3231
3244
  onOpenAutoFocus: (N) => {
3232
3245
  var V;
3233
- N.preventDefault(), (V = Ie.current) == null || V.focus({ preventScroll: !0 });
3246
+ N.preventDefault(), (V = Le.current) == null || V.focus({ preventScroll: !0 });
3234
3247
  },
3235
3248
  children: [
3236
- /* @__PURE__ */ r(Wr, { className: "sr-only", children: [
3237
- /* @__PURE__ */ t(Hr, { children: "Reports & briefings" }),
3238
- /* @__PURE__ */ t(qr, { children: "Manage reports and briefings for this dashboard." })
3249
+ /* @__PURE__ */ r(Yr, { className: "sr-only", children: [
3250
+ /* @__PURE__ */ t(Qr, { children: "Reports & briefings" }),
3251
+ /* @__PURE__ */ t(Xr, { children: "Manage reports and briefings for this dashboard." })
3239
3252
  ] }),
3240
3253
  d ? /* @__PURE__ */ r("div", { className: "flex shrink-0 items-start justify-between gap-3 border-b border-border pl-4 pr-3 pt-2", children: [
3241
3254
  /* @__PURE__ */ r(
@@ -3250,17 +3263,17 @@ function Cn({
3250
3263
  {
3251
3264
  type: "button",
3252
3265
  role: "tab",
3253
- "aria-selected": X === "author",
3266
+ "aria-selected": Z === "author",
3254
3267
  disabled: !k,
3255
3268
  className: G(
3256
3269
  "-mb-px border-b-2 px-0.5 pb-2 text-[12px] transition-colors",
3257
- X === "author" ? "border-foreground font-medium text-foreground" : "border-transparent text-muted-foreground hover:text-foreground",
3270
+ Z === "author" ? "border-foreground font-medium text-foreground" : "border-transparent text-muted-foreground hover:text-foreground",
3258
3271
  !k && "cursor-not-allowed opacity-50"
3259
3272
  ),
3260
3273
  onClick: () => {
3261
3274
  k && (P(null), b(d), R("dashboard"), E("author"));
3262
3275
  },
3263
- children: I ? `Edit ${se(I).noun}` : d === "scheduled_report" ? "Schedule report" : "Create briefing"
3276
+ children: F ? `Edit ${se(F).noun}` : d === "scheduled_report" ? "Schedule report" : "Create briefing"
3264
3277
  }
3265
3278
  ),
3266
3279
  /* @__PURE__ */ t(
@@ -3268,10 +3281,10 @@ function Cn({
3268
3281
  {
3269
3282
  type: "button",
3270
3283
  role: "tab",
3271
- "aria-selected": X === "list",
3284
+ "aria-selected": Z === "list",
3272
3285
  className: G(
3273
3286
  "-mb-px border-b-2 px-0.5 pb-2 text-[12px] transition-colors",
3274
- X === "list" ? "border-foreground font-medium text-foreground" : "border-transparent text-muted-foreground hover:text-foreground"
3287
+ Z === "list" ? "border-foreground font-medium text-foreground" : "border-transparent text-muted-foreground hover:text-foreground"
3275
3288
  ),
3276
3289
  onClick: () => E("list"),
3277
3290
  children: d === "scheduled_report" ? "Manage reports" : "Manage briefings"
@@ -3287,14 +3300,14 @@ function Cn({
3287
3300
  onClick: () => C(!1),
3288
3301
  className: "rounded-control p-1 text-muted-foreground hover:bg-muted hover:text-foreground",
3289
3302
  "aria-label": d === "scheduled_report" ? "Close email report workflow" : "Close analytical briefing workflow",
3290
- children: /* @__PURE__ */ t(Qe, { className: "h-3.5 w-3.5" })
3303
+ children: /* @__PURE__ */ t(Ke, { className: "h-3.5 w-3.5" })
3291
3304
  }
3292
3305
  )
3293
3306
  ] }) : null,
3294
- X === "list" ? /* @__PURE__ */ t(
3307
+ Z === "list" ? /* @__PURE__ */ t(
3295
3308
  dn,
3296
3309
  {
3297
- briefings: Le,
3310
+ briefings: Be,
3298
3311
  dashboardLabel: fe,
3299
3312
  sourceView: y,
3300
3313
  error: le,
@@ -3326,26 +3339,26 @@ function Cn({
3326
3339
  hideHeader: !!d
3327
3340
  }
3328
3341
  ) : /* @__PURE__ */ t(
3329
- Gr,
3342
+ Zr,
3330
3343
  {
3331
3344
  apiServiceUrl: _,
3332
3345
  token: O,
3333
- briefing: I,
3346
+ briefing: F,
3334
3347
  intent: U,
3335
- sourceContext: I ? void 0 : Ke,
3336
- title: I ? `Edit ${se(I).noun}` : U === "scheduled_report" ? "Schedule report" : "Create analytical briefing",
3348
+ sourceContext: F ? void 0 : Ye,
3349
+ title: F ? `Edit ${se(F).noun}` : U === "scheduled_report" ? "Schedule report" : "Create analytical briefing",
3337
3350
  hideHeader: !!d,
3338
3351
  className: "h-full min-h-0 max-w-none border-0 shadow-none",
3339
3352
  onBack: d ? void 0 : () => E("list"),
3340
3353
  onCancel: () => C(!1),
3341
3354
  onDeleted: () => {
3342
- const N = I ? se(I).noun : "briefing";
3343
- z.success(`${N === "report" ? "Report" : "Briefing"} deleted`), P(null), E("list"), Q();
3355
+ const N = F ? se(F).noun : "briefing";
3356
+ z.success(`${N === "report" ? "Report" : "Briefing"} deleted`), P(null), E("list"), K();
3344
3357
  },
3345
3358
  onRunStarted: () => {
3346
3359
  },
3347
3360
  onSaved: (N) => {
3348
- P(N), Q();
3361
+ P(N), K();
3349
3362
  },
3350
3363
  onMinimizeRun: ({ briefing: N, run: V }) => {
3351
3364
  pe({ briefing: N, run: V }), C(!1);
@@ -3366,58 +3379,58 @@ function Cn({
3366
3379
  ve({
3367
3380
  briefing: ue.briefing,
3368
3381
  run: N
3369
- }), pe(null), Q();
3382
+ }), pe(null), K();
3370
3383
  },
3371
3384
  onTimeout: () => {
3372
- pe(null), Q();
3385
+ pe(null), K();
3373
3386
  },
3374
3387
  onExpand: () => {
3375
3388
  P(ue.briefing), E("author"), pe(null), C(!0);
3376
3389
  }
3377
3390
  }
3378
3391
  ) : null,
3379
- Y ? /* @__PURE__ */ t("div", { className: "fixed bottom-4 right-4 z-50 w-[360px]", children: /* @__PURE__ */ t(
3380
- Qr,
3392
+ Q ? /* @__PURE__ */ t("div", { className: "fixed bottom-4 right-4 z-50 w-[360px]", children: /* @__PURE__ */ t(
3393
+ Jr,
3381
3394
  {
3382
- title: Y.run.status === "SUCCESS" ? `${Y.briefing.name} is ready` : `${Y.briefing.name} run failed`,
3383
- durationSeconds: Y.run.startedAt && Y.run.completedAt ? Math.max(
3395
+ title: Q.run.status === "SUCCESS" ? `${Q.briefing.name} is ready` : `${Q.briefing.name} run failed`,
3396
+ durationSeconds: Q.run.startedAt && Q.run.completedAt ? Math.max(
3384
3397
  0,
3385
3398
  Math.floor(
3386
- (new Date(Y.run.completedAt).getTime() - new Date(Y.run.startedAt).getTime()) / 1e3
3399
+ (new Date(Q.run.completedAt).getTime() - new Date(Q.run.startedAt).getTime()) / 1e3
3387
3400
  )
3388
3401
  ) : null,
3389
- status: Y.run.status === "SUCCESS" ? "success" : "failed",
3402
+ status: Q.run.status === "SUCCESS" ? "success" : "failed",
3390
3403
  onView: () => {
3391
- P(Y.briefing), E("author"), ve(null), C(!0);
3404
+ P(Q.briefing), E("author"), ve(null), C(!0);
3392
3405
  },
3393
3406
  onDismiss: () => ve(null)
3394
3407
  }
3395
3408
  ) }) : null,
3396
3409
  /* @__PURE__ */ t(
3397
- it,
3410
+ at,
3398
3411
  {
3399
3412
  open: !!j,
3400
3413
  onOpenChange: (N) => {
3401
3414
  N || J(null);
3402
3415
  },
3403
- children: /* @__PURE__ */ r(lt, { children: [
3404
- /* @__PURE__ */ r(dt, { children: [
3405
- /* @__PURE__ */ r(ct, { children: [
3416
+ children: /* @__PURE__ */ r(nt, { children: [
3417
+ /* @__PURE__ */ r(st, { children: [
3418
+ /* @__PURE__ */ r(ot, { children: [
3406
3419
  "Delete",
3407
3420
  " ",
3408
3421
  j ? se(j).noun : "briefing",
3409
3422
  "?"
3410
3423
  ] }),
3411
- /* @__PURE__ */ r(ut, { children: [
3424
+ /* @__PURE__ */ r(it, { children: [
3412
3425
  "This permanently deletes ",
3413
3426
  /* @__PURE__ */ t("strong", { children: j == null ? void 0 : j.name }),
3414
3427
  ". Recipients will stop receiving it."
3415
3428
  ] })
3416
3429
  ] }),
3417
- /* @__PURE__ */ r(ht, { children: [
3418
- /* @__PURE__ */ t(mt, { children: "Cancel" }),
3430
+ /* @__PURE__ */ r(lt, { children: [
3431
+ /* @__PURE__ */ t(dt, { children: "Cancel" }),
3419
3432
  /* @__PURE__ */ r(
3420
- Ut,
3433
+ Ft,
3421
3434
  {
3422
3435
  className: "bg-destructive/90 hover:bg-destructive",
3423
3436
  onClick: de,
@@ -3438,20 +3451,20 @@ function wn() {
3438
3451
  return typeof crypto < "u" && typeof crypto.randomUUID == "function" ? crypto.randomUUID() : `briefing-run-now-${Date.now()}-${Math.random().toString(36).slice(2, 8)}`;
3439
3452
  }
3440
3453
  export {
3441
- Wn as A,
3454
+ $n as A,
3442
3455
  $a as D,
3443
3456
  Oa as E,
3444
- Qn as N,
3445
- Hn as U,
3446
- zn as V,
3457
+ qn as N,
3458
+ jn as U,
3459
+ _n as V,
3447
3460
  en as W,
3448
- jn as a,
3461
+ zn as a,
3449
3462
  _a as b,
3450
- qn as c,
3451
- Gn as d,
3463
+ Wn as c,
3464
+ Hn as d,
3452
3465
  Wa as e,
3453
- Ka as f,
3454
- Kn as g,
3455
- Yn as h,
3456
- $n as u
3466
+ Ya as f,
3467
+ Gn as g,
3468
+ Kn as h,
3469
+ On as u
3457
3470
  };