react-semaphor 0.1.467 → 0.1.469

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 (70) hide show
  1. package/dist/analytics-protocol/index.cjs +1 -1
  2. package/dist/analytics-protocol/index.js +158 -285
  3. package/dist/brand-studio/index.cjs +1 -1
  4. package/dist/brand-studio/index.js +4 -4
  5. package/dist/briefings/index.js +4 -4
  6. package/dist/chunks/{analyze-result-contract-CMZDRRwo.js → analyze-result-contract-kaCNxjA7.js} +1 -1
  7. package/dist/chunks/{common-types-Co766x6t.js → common-types-BgI-ymBp.js} +30 -23
  8. package/dist/chunks/common-types-tRK8fhXV.cjs +1 -0
  9. package/dist/chunks/{dashboard-briefing-launcher-FbEIrobt.cjs → dashboard-briefing-launcher-BqxcYhO2.cjs} +1 -1
  10. package/dist/chunks/{dashboard-briefing-launcher-Ctu63_Di.js → dashboard-briefing-launcher-kKSBCRLE.js} +9 -9
  11. package/dist/chunks/{dashboard-controls-DeDCphnd.js → dashboard-controls-DP2rftVR.js} +9 -9
  12. package/dist/chunks/{dashboard-controls-BKm3JIEo.cjs → dashboard-controls-Z8ow3GV6.cjs} +1 -1
  13. package/dist/chunks/{dashboard-filter-value-compatibility-B8ynE_O1.js → dashboard-filter-value-compatibility-Ce7jUVh-.js} +8 -8
  14. package/dist/chunks/{dashboard-filter-value-compatibility-Bnl2lsng.cjs → dashboard-filter-value-compatibility-iCPBcrRS.cjs} +1 -1
  15. package/dist/chunks/{dashboard-input-contract-Px64VWBL.js → dashboard-input-contract-Ciboc347.js} +6 -6
  16. package/dist/chunks/{dashboard-json-BygDylH8.js → dashboard-json-3qT123Xa.js} +7 -7
  17. package/dist/chunks/{dashboard-json-BV6wbV2p.cjs → dashboard-json-CPq7IMvR.cjs} +1 -1
  18. package/dist/chunks/edit-dashboard-visual-7eUCTZnx.cjs +172 -0
  19. package/dist/chunks/{edit-dashboard-visual-CYOtYa4w.js → edit-dashboard-visual-Clz6LQOX.js} +7164 -7298
  20. package/dist/chunks/{editor-action-buttons-Baks5RYd.js → editor-action-buttons-CFbMRQSE.js} +6 -6
  21. package/dist/chunks/{editor-action-buttons-CRRjegRd.cjs → editor-action-buttons-WJFWflfs.cjs} +1 -1
  22. package/dist/chunks/{index-B31RKKGb.js → index-8Cm77joZ.js} +29054 -28935
  23. package/dist/chunks/{index-yJRh4x9j.cjs → index-DKaQRhKm.cjs} +179 -167
  24. package/dist/chunks/{index-BlCnNcaB.js → index-DO4BESNy.js} +9 -9
  25. package/dist/chunks/matrix-result-contract-ClC6Pd_g.js +822 -0
  26. package/dist/chunks/matrix-result-contract-DF-qt0jx.cjs +1 -0
  27. package/dist/chunks/{pivot-header-presentation-CSf6CyOt.js → pivot-header-presentation-OpY8xzdT.js} +2 -2
  28. package/dist/chunks/{pivot-result-identity-BvT51Nog.js → pivot-result-identity-CCMpd8ZA.js} +1 -1
  29. package/dist/chunks/{pivot-result-lifecycle--NNNPUtG.js → pivot-result-lifecycle-B38AZx4a.js} +19 -19
  30. package/dist/chunks/{raw-temporal-contract-BqVMduCs.js → raw-temporal-contract-r_EMdR85.js} +1 -1
  31. package/dist/chunks/{report-preferences-dialog-CRNoMzNj.cjs → report-preferences-dialog-C5UOCTwt.cjs} +1 -1
  32. package/dist/chunks/{report-preferences-dialog-CZPqG-em.js → report-preferences-dialog-D-NDYRrk.js} +6 -6
  33. package/dist/chunks/{report-runtime-context-CrTzKt0C.js → report-runtime-context-CcXUjpb-.js} +7 -7
  34. package/dist/chunks/{saved-temporal-bucket-format-DfqnCGCz.js → saved-temporal-bucket-format-hylaofsQ.js} +29 -29
  35. package/dist/chunks/{switch-B6rFVSdw.js → switch-BagpmPNw.js} +24 -9
  36. package/dist/chunks/{switch-BghC7eOM.cjs → switch-DyE2_OmQ.cjs} +2 -2
  37. package/dist/chunks/{temporal-bucket-DFYIkexB.js → temporal-bucket-Cc9fmx8s.js} +12 -12
  38. package/dist/chunks/{temporal-bucket-authoring-ZxFzhTmL.js → temporal-bucket-authoring-DjPFtRSF.js} +3 -3
  39. package/dist/chunks/{temporal-bucket-contract-COPPwwbi.js → temporal-bucket-contract-DT4kU0VY.js} +1 -1
  40. package/dist/chunks/{token-types-p1M3SA2G.js → token-types-Z889rD6g.js} +1 -1
  41. package/dist/chunks/{update-policy-BKOA5S76.js → update-policy-Bu5Tw43R.js} +1 -1
  42. package/dist/chunks/{validators-CCpBY1e0.js → validators-DhTaCK1O.js} +50 -50
  43. package/dist/dashboard/index.cjs +1 -1
  44. package/dist/dashboard/index.js +2 -2
  45. package/dist/dashboard-authoring/index.cjs +1 -1
  46. package/dist/dashboard-authoring/index.js +4 -4
  47. package/dist/data-app-builder/index.cjs +1 -1
  48. package/dist/data-app-builder/index.js +2 -2
  49. package/dist/data-app-codegen/index.js +2 -2
  50. package/dist/data-app-codegen-node/index.js +3 -3
  51. package/dist/data-app-sdk/index.js +3 -3
  52. package/dist/data-app-sdk-adapters/index.js +2 -2
  53. package/dist/data-app-sdk-validation/index.js +9 -9
  54. package/dist/format-utils/index.js +10 -10
  55. package/dist/index.cjs +1 -1
  56. package/dist/index.js +117 -115
  57. package/dist/report-runtime-context/index.js +2 -2
  58. package/dist/style.css +1 -1
  59. package/dist/surfboard/index.cjs +1 -1
  60. package/dist/surfboard/index.js +3 -3
  61. package/dist/types/analytics-protocol.d.ts +74 -0
  62. package/dist/types/index.cjs +1 -1
  63. package/dist/types/index.js +18 -16
  64. package/dist/types/main.d.ts +10 -0
  65. package/dist/types/types.d.ts +9 -0
  66. package/package.json +1 -1
  67. package/dist/chunks/common-types-o3LJcrpg.cjs +0 -1
  68. package/dist/chunks/edit-dashboard-visual-DWN052a9.cjs +0 -172
  69. package/dist/chunks/matrix-result-contract-DQ9_UadF.js +0 -421
  70. package/dist/chunks/matrix-result-contract-DiHDIyQk.cjs +0 -1
@@ -1,8 +1,8 @@
1
- import "../chunks/pivot-result-lifecycle--NNNPUtG.js";
1
+ import "../chunks/pivot-result-lifecycle-B38AZx4a.js";
2
2
  import "../value-format-preferences/index.js";
3
- import "../chunks/validators-CCpBY1e0.js";
4
- import "../chunks/analyze-result-contract-CMZDRRwo.js";
5
- import { a3 as t, a7 as f, a2 as g, a6 as o, ab as B, a4 as l, X as m, a5 as I, af as T, W as d, ah as C, A as E, ai as u, Z as F, d as p, aa as A, a9 as c, S as D, T as _, a as b, ao as R, g as N, an as S, al as h, am as y, a8 as G, Y as L, U as M, ac as U, ag as v, ae as V, V as z, ad as O, aj as x, ak as J } from "../chunks/index-BlCnNcaB.js";
3
+ import "../chunks/validators-DhTaCK1O.js";
4
+ import "../chunks/analyze-result-contract-kaCNxjA7.js";
5
+ import { a3 as t, a7 as f, a2 as g, a6 as o, ab as B, a4 as l, X as m, a5 as I, af as T, W as d, ah as C, A as E, ai as u, Z as F, d as p, aa as A, a9 as c, S as D, T as _, a as b, ao as R, g as N, an as S, al as h, am as y, a8 as G, Y as L, U as M, ac as U, ag as v, ae as V, V as z, ad as O, aj as x, ak as J } from "../chunks/index-DO4BESNy.js";
6
6
  export {
7
7
  t as BRIEFING_ARTIFACT_FORMATS,
8
8
  f as BRIEFING_CONTENT_LIMITS,
@@ -1,4 +1,4 @@
1
- import { f as t, g as n } from "./validators-CCpBY1e0.js";
1
+ import { e as t, f as n } from "./validators-DhTaCK1O.js";
2
2
  const o = new Set(
3
3
  Object.keys(t)
4
4
  );
@@ -1,6 +1,6 @@
1
- import "./validators-CCpBY1e0.js";
2
- const t = "SEMAPHOR_CALCULATED_FIELD";
3
- function D(Y) {
1
+ import "./validators-DhTaCK1O.js";
2
+ const n = "SEMAPHOR_CALCULATED_FIELD", e = "calculated_fields";
3
+ function u(Y) {
4
4
  return (Y == null ? void 0 : Y.sourceField) || (Y == null ? void 0 : Y.name) || "";
5
5
  }
6
6
  const r = [
@@ -38,39 +38,46 @@ const r = [
38
38
  // Custom format
39
39
  "custom"
40
40
  ];
41
- function u(Y) {
41
+ function _(Y) {
42
42
  return Y.role === "metric" && "expression" in Y && !!Y.expression;
43
43
  }
44
44
  function o(Y) {
45
45
  return !!Y.expression;
46
46
  }
47
- function _(Y) {
48
- return !!Y.expression;
49
- }
50
47
  function c(Y) {
51
- var n, s;
52
- const M = Y;
53
- return !!(M != null && M.expression && ((s = (n = M.calculatedFormula) == null ? void 0 : n.inputFields) != null && s.length));
48
+ return !!Y.expression;
54
49
  }
55
50
  function L(Y) {
56
- return !!(Y && (Y.entityName === t || Y.entityId === t));
51
+ var M, a;
52
+ const t = Y;
53
+ return !!(t != null && t.expression && ((a = (M = t.calculatedFormula) == null ? void 0 : M.inputFields) != null && a.length));
54
+ }
55
+ function A(Y) {
56
+ return !!(Y && (Y.entityName === n || Y.entityId === n));
57
+ }
58
+ function i(Y) {
59
+ return Y ? [Y.entityName, Y.entityId, Y.qualifiedEntityName].some(
60
+ (t) => t === n || t === e
61
+ ) : !1;
57
62
  }
58
- var a = /* @__PURE__ */ ((Y) => (Y.SUBTOTAL = "__SUBTOTAL__", Y.TOTAL = "__TOTAL__", Y.ALL = "__ALL__", Y))(a || {});
59
- const m = {
63
+ var s = /* @__PURE__ */ ((Y) => (Y.SUBTOTAL = "__SUBTOTAL__", Y.TOTAL = "__TOTAL__", Y.ALL = "__ALL__", Y))(s || {});
64
+ const l = {
60
65
  database: null,
61
66
  schema: null,
62
67
  table: null
63
- }, A = "__card_default__";
68
+ }, m = "__card_default__";
64
69
  export {
65
- A as C,
70
+ m as C,
66
71
  r as D,
67
- m as E,
68
- a as P,
69
- t as a,
72
+ l as E,
73
+ e as L,
74
+ s as P,
75
+ n as a,
70
76
  o as b,
71
- _ as c,
72
- L as d,
73
- D as g,
74
- c as h,
75
- u as i
77
+ c,
78
+ A as d,
79
+ i as e,
80
+ u as g,
81
+ L as h,
82
+ _ as i
76
83
  };
@@ -0,0 +1 @@
1
+ "use strict";require("./validators-DO-YuzgO.cjs");const t="SEMAPHOR_CALCULATED_FIELD",a="calculated_fields";function s(Y){return(Y==null?void 0:Y.sourceField)||(Y==null?void 0:Y.name)||""}const _=["MM-DD-YYYY","YYYY-MM-DD","MM/DD/YYYY","DD/MM/YYYY","MMMM DD, YYYY","MMM DD, YYYY","DD MMM YYYY","YYYY-MM-DD HH:mm","YYYY-MM-DD HH:mm:ss","YYYY-MM-DD HH:mm Z","YYYY-MM-DD HH:mm:ss Z","Week of MMM DD, YYYY","Week of MMMM DD, YYYY","YYYY-WW","MMM YYYY","MMMM YYYY","YYYY-MM","MM/YYYY","YYYY MMM","Q1 YYYY","YYYY Q1","1st Quarter YYYY","YYYY-Q1","Quarter 1, YYYY","YYYY","YY","custom"];function D(Y){return Y.role==="metric"&&"expression"in Y&&!!Y.expression}function r(Y){return!!Y.expression}function l(Y){return!!Y.expression}function c(Y){var n,M;const e=Y;return!!(e!=null&&e.expression&&((M=(n=e.calculatedFormula)==null?void 0:n.inputFields)!=null&&M.length))}function A(Y){return!!(Y&&(Y.entityName===t||Y.entityId===t))}function E(Y){return Y?[Y.entityName,Y.entityId,Y.qualifiedEntityName].some(e=>e===t||e===a):!1}var u=(Y=>(Y.SUBTOTAL="__SUBTOTAL__",Y.TOTAL="__TOTAL__",Y.ALL="__ALL__",Y))(u||{});const L={database:null,schema:null,table:null},i="__card_default__";exports.CALCULATED_FIELD_ENTITY_MARKER=t;exports.CONTROL_CARD_DEFAULT_VALUE=i;exports.DATE_FORMAT_VALUES=_;exports.EMPTY_SELECTION=L;exports.LEGACY_CALCULATED_FIELD_ENTITY_MARKER=a;exports.PivotMarkerEnum=u;exports.getFieldRuntimeColumnName=s;exports.hasCalculatedFieldMarker=A;exports.hasCalculatedFormulaInputs=c;exports.hasSyntheticCalculatedFieldOwner=E;exports.isCalculatedDimension=r;exports.isCalculatedField=l;exports.isCalculatedMetric=D;
@@ -1,4 +1,4 @@
1
- "use strict";const e=require("react/jsx-runtime"),p=require("react"),s=require("./index-yJRh4x9j.cjs"),n=require("./switch-BghC7eOM.cjs"),Ce=require("./layout-grid-xm8pqtx0.cjs"),K=require("./x-B6ghREd2.cjs"),V=require("./editor-action-buttons-CRRjegRd.cjs"),we=require("./saved-temporal-bucket-format-Ca4hUfTo.cjs");require("./validators-DO-YuzgO.cjs");require("./analyze-result-contract-CMwVg9w2.cjs");require("../value-format-preferences/index.cjs");const Ue=require("./search-BqqhaMx9.cjs"),Oe=require("./mouse-pointer-2-DX4A_XZw.cjs"),Ne=require("./pivot-header-presentation-DyV0iOZ_.cjs");require("./appearance-runtime-provider-BgNYdUYH.cjs");require("./appearance-context-DhyjbQk1.cjs");require("./index-ByFbacH7.cjs");require("./temporal-bucket-authoring-C6sZAVqS.cjs");require("./color-CyB5o13F.cjs");require("react-dom");const X=require("./index-CQN-X1jN.cjs");/**
1
+ "use strict";const e=require("react/jsx-runtime"),p=require("react"),s=require("./index-DKaQRhKm.cjs"),n=require("./switch-DyE2_OmQ.cjs"),Ce=require("./layout-grid-xm8pqtx0.cjs"),K=require("./x-B6ghREd2.cjs"),V=require("./editor-action-buttons-WJFWflfs.cjs"),we=require("./saved-temporal-bucket-format-Ca4hUfTo.cjs");require("./validators-DO-YuzgO.cjs");require("./analyze-result-contract-CMwVg9w2.cjs");require("../value-format-preferences/index.cjs");const Ue=require("./search-BqqhaMx9.cjs"),Oe=require("./mouse-pointer-2-DX4A_XZw.cjs"),Ne=require("./pivot-header-presentation-DyV0iOZ_.cjs");require("./appearance-runtime-provider-BgNYdUYH.cjs");require("./appearance-context-DhyjbQk1.cjs");require("./index-ByFbacH7.cjs");require("./temporal-bucket-authoring-C6sZAVqS.cjs");require("./color-CyB5o13F.cjs");require("react-dom");const X=require("./index-CQN-X1jN.cjs");/**
2
2
  * @license lucide-react v0.453.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.
@@ -1,24 +1,24 @@
1
1
  import { jsx as e, jsxs as r, Fragment as W } from "react/jsx-runtime";
2
2
  import Wt, { useState as E, useEffect as Q, useMemo as ee, useContext as Ht, useRef as he, useCallback as K } from "react";
3
- import { cm as et, aH as De, aI as ke, aK as Ae, bb as wt, bY as Gt, cn as Kt, co as qt, aZ as fe, ca as Nt, bl as Pe, s as Xt, o as Zt, cp as Qt, aP as tt, aS as rt, aT as at, aU as nt, aV as st, aW as ot, aX as it, aY as St, bk as lt, aG as O, cq as Yt, cr as Jt, cs as qe, cb as $e, cc as je, ct as Dt, cd as We, bW as G, b1 as er, bB as Me, cu as tr, bV as rr, aJ as ct, aL as dt, cv as ar, aF as nr, ba as sr, bw as kt, cw as or, bZ as ir, u as lr, aM as cr, b3 as dr, az as He, O as ue, aw as ut, as as At, at as ht, P as Et, ar as ur, ay as hr, ch as mr, cx as pr, bu as fr, au as gt, R as gr, T as br, cy as xr, cz as vr, cA as yr, cB as Cr, cC as wr, cD as Nr, cE as It, cF as Sr, b4 as Dr, cG as kr, ce as Ft, cH as Ar, cI as Er, cJ as Re, cK as Ir, cL as Fr, cM as Lr, an as Br, ap as Tr, a3 as Vr, a2 as Rr, a1 as Ur, a0 as Pr, Z as Mr, X as Or, cN as _r, cO as zr, cP as $r, cQ as jr, cR as Wr, al as Hr, cS as Gr, cT as Kr, a9 as qr, cU as Xr, cV as Zr, cW as Qr } from "./index-B31RKKGb.js";
4
- import { B, O as Se, Z as Ye, L as te, M as Lt, d as Bt, c as q, K as Yr, D as ge, u as P, z as be, aw as Tt, av as Je, E as Vt, P as Oe, a as _e, b as ze, aH as Jr, aI as ea, S as Rt, aJ as ta, aK as ra, aL as aa, aM as na, aF as sa } from "./switch-B6rFVSdw.js";
3
+ import { cm as et, aH as De, aI as ke, aK as Ae, bb as wt, bY as Gt, cn as Kt, co as qt, aZ as fe, ca as Nt, bl as Pe, s as Xt, o as Zt, cp as Qt, aP as tt, aS as rt, aT as at, aU as nt, aV as st, aW as ot, aX as it, aY as St, bk as lt, aG as O, cq as Yt, cr as Jt, cs as qe, cb as $e, cc as je, ct as Dt, cd as We, bW as G, b1 as er, bB as Me, cu as tr, bV as rr, aJ as ct, aL as dt, cv as ar, aF as nr, ba as sr, bw as kt, cw as or, bZ as ir, u as lr, aM as cr, b3 as dr, az as He, O as ue, aw as ut, as as At, at as ht, P as Et, ar as ur, ay as hr, ch as mr, cx as pr, bu as fr, au as gt, R as gr, T as br, cy as xr, cz as vr, cA as yr, cB as Cr, cC as wr, cD as Nr, cE as It, cF as Sr, b4 as Dr, cG as kr, ce as Ft, cH as Ar, cI as Er, cJ as Re, cK as Ir, cL as Fr, cM as Lr, an as Br, ap as Tr, a3 as Vr, a2 as Rr, a1 as Ur, a0 as Pr, Z as Mr, X as Or, cN as _r, cO as zr, cP as $r, cQ as jr, cR as Wr, al as Hr, cS as Gr, cT as Kr, a9 as qr, cU as Xr, cV as Zr, cW as Qr } from "./index-8Cm77joZ.js";
4
+ import { B, O as Se, Z as Ye, L as te, M as Lt, d as Bt, c as q, K as Yr, D as ge, u as P, z as be, aw as Tt, av as Je, E as Vt, P as Oe, a as _e, b as ze, aH as Jr, aI as ea, S as Rt, aJ as ta, aK as ra, aL as aa, aM as na, aF as sa } from "./switch-BagpmPNw.js";
5
5
  import { L as mt } from "./layout-grid-CiubineE.js";
6
6
  import { c as Ee, X as Ge, C as Ut } from "./x-CXDkqdur.js";
7
- import { u as pt, V as oa, E as Xe, a as Ze, b as ia, c as la, L as ca, d as da, e as Pt, C as Mt, F as ua, f as ha } from "./editor-action-buttons-Baks5RYd.js";
8
- import { v as bt } from "./saved-temporal-bucket-format-DfqnCGCz.js";
9
- import "./validators-CCpBY1e0.js";
10
- import "./analyze-result-contract-CMZDRRwo.js";
7
+ import { u as pt, V as oa, E as Xe, a as Ze, b as ia, c as la, L as ca, d as da, e as Pt, C as Mt, F as ua, f as ha } from "./editor-action-buttons-CFbMRQSE.js";
8
+ import { v as bt } from "./saved-temporal-bucket-format-hylaofsQ.js";
9
+ import "./validators-DhTaCK1O.js";
10
+ import "./analyze-result-contract-kaCNxjA7.js";
11
11
  import "../value-format-preferences/index.js";
12
12
  import { S as ma } from "./search-BHsQIWBV.js";
13
13
  import { M as pa } from "./mouse-pointer-2-BZvGk45-.js";
14
- import { u as xt } from "./pivot-header-presentation-CSf6CyOt.js";
14
+ import { u as xt } from "./pivot-header-presentation-OpY8xzdT.js";
15
15
  import "./appearance-runtime-provider-CjmE4gBY.js";
16
16
  import "./appearance-context-DVXt8qjW.js";
17
17
  import "./index-DSKR3nKn.js";
18
- import "./temporal-bucket-authoring-ZxFzhTmL.js";
18
+ import "./temporal-bucket-authoring-DjPFtRSF.js";
19
19
  import "./color-CJvdlFM_.js";
20
20
  import "react-dom";
21
- import { g as se, d as fa, a as ga } from "./index-BlCnNcaB.js";
21
+ import { g as se, d as fa, a as ga } from "./index-DO4BESNy.js";
22
22
  /**
23
23
  * @license lucide-react v0.453.0 - ISC
24
24
  *
@@ -1,24 +1,24 @@
1
1
  import { jsx as e, jsxs as o, Fragment as T } from "react/jsx-runtime";
2
- import { u as S, B as R, ax as mt, z as sr, O as na, Z as sa, c as be, ay as oa, az as ia, aA as ot, aB as xe, aC as pt, aD as or, L as Be, aE as ir, aF as da, D as $t, Q as Gt, V as Bt, W as zt, Y as Ht, X as la, i as ca, aG as ua } from "./switch-B6rFVSdw.js";
3
- import { bx as ma, by as pa, az as q, aH as dr, bz as ha, aZ as K, aI as lr, aJ as fa, aK as it, aL as dt, aF as ga, bA as ge, bB as Ge, bC as ba, bD as jt, bE as cr, bF as ur, bG as xa, bH as ht, bI as va, bJ as ya, bK as wa, bL as Na, bM as Sa, bN as Da, b8 as ve, bO as ye, aG as C, bP as Ca, bQ as mr, bl as ft, bR as ka, bS as Ea, bT as pr, bU as La, bV as hr, bW as V, bX as Ia, ap as Ma, bY as Aa, bZ as Pa, b_ as Oa, b$ as _a, n as Ra, u as Fe, t as Ua, o as rt, c0 as Va, c1 as Ta, c2 as Fa, c3 as $a, N as Ga, c4 as Ba, c5 as za, I as qt, c6 as Ha, c7 as ja, c8 as qa, c9 as Ka, ca as Wa, cb as Kt, cc as Wt, cd as Qt, ce as Qa, cf as Ja, cg as Ya, ch as Xa, b1 as Jt, ci as Za, cj as en, ck as tn, s as rn, cl as an, aP as nn, aS as sn, aT as on, aU as dn, aV as ln, aW as cn, aX as un, aY as Yt, g as lt } from "./index-B31RKKGb.js";
2
+ import { u as S, B as R, ax as mt, z as sr, O as na, Z as sa, c as be, ay as oa, az as ia, aA as ot, aB as xe, aC as pt, aD as or, L as Be, aE as ir, aF as da, D as $t, Q as Gt, V as Bt, W as zt, Y as Ht, X as la, i as ca, aG as ua } from "./switch-BagpmPNw.js";
3
+ import { bx as ma, by as pa, az as q, aH as dr, bz as ha, aZ as K, aI as lr, aJ as fa, aK as it, aL as dt, aF as ga, bA as ge, bB as Ge, bC as ba, bD as jt, bE as cr, bF as ur, bG as xa, bH as ht, bI as va, bJ as ya, bK as wa, bL as Na, bM as Sa, bN as Da, b8 as ve, bO as ye, aG as C, bP as Ca, bQ as mr, bl as ft, bR as ka, bS as Ea, bT as pr, bU as La, bV as hr, bW as V, bX as Ia, ap as Ma, bY as Aa, bZ as Pa, b_ as Oa, b$ as _a, n as Ra, u as Fe, t as Ua, o as rt, c0 as Va, c1 as Ta, c2 as Fa, c3 as $a, N as Ga, c4 as Ba, c5 as za, I as qt, c6 as Ha, c7 as ja, c8 as qa, c9 as Ka, ca as Wa, cb as Kt, cc as Wt, cd as Qt, ce as Qa, cf as Ja, cg as Ya, ch as Xa, b1 as Jt, ci as Za, cj as en, ck as tn, s as rn, cl as an, aP as nn, aS as sn, aT as on, aU as dn, aV as ln, aW as cn, aX as un, aY as Yt, g as lt } from "./index-8Cm77joZ.js";
4
4
  import { c as ee, X as fr, C as mn } from "./x-CXDkqdur.js";
5
- import "./saved-temporal-bucket-format-DfqnCGCz.js";
6
- import "./validators-CCpBY1e0.js";
7
- import "./analyze-result-contract-CMZDRRwo.js";
5
+ import "./saved-temporal-bucket-format-hylaofsQ.js";
6
+ import "./validators-DhTaCK1O.js";
7
+ import "./analyze-result-contract-kaCNxjA7.js";
8
8
  import "../value-format-preferences/index.js";
9
9
  import * as I from "react";
10
10
  import gr, { useState as N, useMemo as Z, useEffect as ze, useRef as Xt, useLayoutEffect as pn, useCallback as hn } from "react";
11
11
  import "./appearance-context-DVXt8qjW.js";
12
12
  import "./index-DSKR3nKn.js";
13
- import "./temporal-bucket-authoring-ZxFzhTmL.js";
13
+ import "./temporal-bucket-authoring-DjPFtRSF.js";
14
14
  import "./color-CJvdlFM_.js";
15
15
  import { createPortal as fn } from "react-dom";
16
- import "./index-BlCnNcaB.js";
16
+ import "./index-DO4BESNy.js";
17
17
  import "./appearance-runtime-provider-CjmE4gBY.js";
18
- import { c as gn, u as bn, A as xn, a as vn, f as yn, V as wn, N as Nn, g as Sn, U as Dn } from "./dashboard-briefing-launcher-Ctu63_Di.js";
18
+ import { c as gn, u as bn, A as xn, a as vn, f as yn, V as wn, N as Nn, g as Sn, U as Dn } from "./dashboard-briefing-launcher-kKSBCRLE.js";
19
19
  import { S as Cn, C as kn } from "./search-BHsQIWBV.js";
20
20
  import { d as br } from "./format-types-CFHQoIuk.js";
21
- import { R as En } from "./report-preferences-dialog-CZPqG-em.js";
21
+ import { R as En } from "./report-preferences-dialog-D-NDYRrk.js";
22
22
  import { u as Ln } from "./use-debounced-dirty-check-BwAbnX_5.js";
23
23
  import { s as at } from "./normalize-dashboard-for-dirty-check-5KpZN8xr.js";
24
24
  import { S as Zt } from "./save-DgMfP0j8.js";
@@ -1,4 +1,4 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),l=require("./switch-BghC7eOM.cjs"),s=require("./index-yJRh4x9j.cjs"),U=require("./x-B6ghREd2.cjs");require("./saved-temporal-bucket-format-Ca4hUfTo.cjs");require("./validators-DO-YuzgO.cjs");require("./analyze-result-contract-CMwVg9w2.cjs");require("../value-format-preferences/index.cjs");const y=require("react");require("./appearance-context-DhyjbQk1.cjs");require("./index-ByFbacH7.cjs");require("./temporal-bucket-authoring-C6sZAVqS.cjs");require("./color-CyB5o13F.cjs");const cs=require("react-dom");require("./index-CQN-X1jN.cjs");require("./appearance-runtime-provider-BgNYdUYH.cjs");const $=require("./dashboard-briefing-launcher-FbEIrobt.cjs"),wt=require("./search-BqqhaMx9.cjs"),St=require("./format-types-PSZZ7hG8.cjs"),us=require("./report-preferences-dialog-CRNoMzNj.cjs"),ms=require("./use-debounced-dirty-check-XHSwAefL.cjs"),qe=require("./normalize-dashboard-for-dirty-check-BXRUMVb2.cjs"),xt=require("./save-3dYRmehL.cjs"),hs=require("./palette-BN-jYtaK.cjs"),ps=require("./braces-v55uLCAK.cjs");function fs(t){const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const n in t)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(a,n,r.get?r:{enumerable:!0,get:()=>t[n]})}}return a.default=t,Object.freeze(a)}const M=fs(y);/**
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),l=require("./switch-DyE2_OmQ.cjs"),s=require("./index-DKaQRhKm.cjs"),U=require("./x-B6ghREd2.cjs");require("./saved-temporal-bucket-format-Ca4hUfTo.cjs");require("./validators-DO-YuzgO.cjs");require("./analyze-result-contract-CMwVg9w2.cjs");require("../value-format-preferences/index.cjs");const y=require("react");require("./appearance-context-DhyjbQk1.cjs");require("./index-ByFbacH7.cjs");require("./temporal-bucket-authoring-C6sZAVqS.cjs");require("./color-CyB5o13F.cjs");const cs=require("react-dom");require("./index-CQN-X1jN.cjs");require("./appearance-runtime-provider-BgNYdUYH.cjs");const $=require("./dashboard-briefing-launcher-BqxcYhO2.cjs"),wt=require("./search-BqqhaMx9.cjs"),St=require("./format-types-PSZZ7hG8.cjs"),us=require("./report-preferences-dialog-C5UOCTwt.cjs"),ms=require("./use-debounced-dirty-check-XHSwAefL.cjs"),qe=require("./normalize-dashboard-for-dirty-check-BXRUMVb2.cjs"),xt=require("./save-3dYRmehL.cjs"),hs=require("./palette-BN-jYtaK.cjs"),ps=require("./braces-v55uLCAK.cjs");function fs(t){const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const n in t)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(a,n,r.get?r:{enumerable:!0,get:()=>t[n]})}}return a.default=t,Object.freeze(a)}const M=fs(y);/**
2
2
  * @license lucide-react v0.453.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.
@@ -1,8 +1,8 @@
1
1
  var O = Object.defineProperty;
2
2
  var M = (e, n, i) => n in e ? O(e, n, { enumerable: !0, configurable: !0, writable: !0, value: i }) : e[n] = i;
3
- var w = (e, n, i) => M(e, typeof n != "symbol" ? n + "" : n, i);
4
- import { ah as h, aj as S, j as N, ag as q, C as I, F as D } from "./validators-CCpBY1e0.js";
5
- import "./analyze-result-contract-CMZDRRwo.js";
3
+ var C = (e, n, i) => M(e, typeof n != "symbol" ? n + "" : n, i);
4
+ import { ah as h, aj as S, h as N, ag as q, B as I, E as D } from "./validators-DhTaCK1O.js";
5
+ import "./analyze-result-contract-kaCNxjA7.js";
6
6
  import "../value-format-preferences/index.js";
7
7
  function p(e) {
8
8
  return !!e && typeof e == "object" && !Array.isArray(e);
@@ -229,7 +229,7 @@ function $e(e) {
229
229
  class X extends Error {
230
230
  constructor(i) {
231
231
  super(i.map((d) => d.message).join(" "));
232
- w(this, "issues");
232
+ C(this, "issues");
233
233
  this.name = "DashboardFilterMappingContractError", this.issues = i;
234
234
  }
235
235
  }
@@ -557,12 +557,12 @@ function oe({
557
557
  });
558
558
  return;
559
559
  }
560
- const C = a.get(b.id);
561
- if (C) {
560
+ const w = a.get(b.id);
561
+ if (w) {
562
562
  t.push({
563
563
  code: "duplicate_filter_reference",
564
564
  path: `${u}.filterReference.filterId`,
565
- message: `${u}.filterReference duplicates dashboard filter '${b.id}' already owned by Dashboard Input '${C}'.`,
565
+ message: `${u}.filterReference duplicates dashboard filter '${b.id}' already owned by Dashboard Input '${w}'.`,
566
566
  inputId: l.id
567
567
  });
568
568
  return;
@@ -662,7 +662,7 @@ const de = {
662
662
  "is null",
663
663
  "is not null"
664
664
  ]),
665
- boolean: /* @__PURE__ */ new Set(["=", "!=", "is null", "is not null"])
665
+ boolean: /* @__PURE__ */ new Set(["=", "!=", "in", "not in", "is null", "is not null"])
666
666
  };
667
667
  function ae(e) {
668
668
  const n = D(e);
@@ -1 +1 @@
1
- "use strict";var H=Object.defineProperty;var L=(e,n,i)=>n in e?H(e,n,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[n]=i;var N=(e,n,i)=>L(e,typeof n!="symbol"?n+"":n,i);const f=require("./validators-DO-YuzgO.cjs");require("./analyze-result-contract-CMwVg9w2.cjs");require("../value-format-preferences/index.cjs");function p(e){return!!e&&typeof e=="object"&&!Array.isArray(e)}function k(e){return p(e)&&typeof e.name=="string"}function F(e){return!p(e)||e.kind!=="semantic"&&e.kind!=="physical"||(e.kind==="semantic"?[e.datasetId,e.datasetName,e.connectionId]:[e.databaseName,e.schemaName]).some(i=>i!==void 0&&typeof i!="string")?!1:f.hasCompleteSemaphorSourceIdentity(e)}function v(e,n){var c,o;if((n==null?void 0:n.mode)!=="database"&&e.type==="dataset"&&"domainId"in e&&e.domainId){const s=e,d={kind:"semantic",domainId:s.domainId,datasetId:s.id,datasetName:s.name,connectionId:s.connectionId||(n==null?void 0:n.connectionId),label:s.label};return F(d)?f.canonicalizeSemaphorSourceIdentity(d):void 0}const i=e.connectionId||(n==null?void 0:n.connectionId),a=e.type==="dataset"&&"table"in e&&e.table?e.table:e.name;if(!i||!a)return;const t={kind:"physical",connectionId:i,connectionType:e.connectionType||(n==null?void 0:n.connectionType),tableName:a,databaseName:e.database||((c=n==null?void 0:n.dbSelection)==null?void 0:c.database),schemaName:e.schema||((o=n==null?void 0:n.dbSelection)==null?void 0:o.schema),dialect:e.dialect};return F(t)?t:void 0}function V(e,n){var s,d;const i=v(e,n);if(!i)return;const a=e.type==="dataset"&&"table"in e&&typeof e.table=="string"?e.table.trim():void 0,t=i.kind==="physical"?i.tableName:a,c=e.connectionId||(n==null?void 0:n.connectionId),o=t&&c?{connectionId:c,databaseName:e.database||((s=n==null?void 0:n.dbSelection)==null?void 0:s.database),schemaName:e.schema||((d=n==null?void 0:n.dbSelection)==null?void 0:d.schema),tableName:t}:void 0;return{source:i,...o?{executionTable:o}:{}}}function x(e){const n=p(e.dataSource)?e.dataSource:void 0;if(typeof e.sql=="string"&&e.sql.trim()){const o=[],s=Array.isArray(n==null?void 0:n.selectedEntities)?n.selectedEntities:[];for(const d of s){if(!k(d))continue;const r=V(d,n);r&&!o.some(T=>f.semaphorSourcesReferToSameDataset(T.source,r.source))&&o.push(r)}return{cardId:e.id,kind:"sql",pinnedCatalogSources:o}}if(!p(e.config))return{cardId:e.id,kind:"unconfigured"};const i=[],a=p(e.config.matrixIntent)?e.config.matrixIntent:void 0,t=e.type==="matrixTable"?(a==null?void 0:a.kind)==="matrix"?a.source:e.config.source:void 0;F(t)&&i.push(t);const c=p(e.config.joinPlan)?e.config.joinPlan:void 0;if(c){const o=Array.isArray(c.joins)?c.joins:[],s=[c.baseEntity];for(const d of o)p(d)&&s.push(d.source,d.target);for(const d of s){if(!k(d))continue;const r=v(d,n);r&&i.push(r)}}else if(e.type!=="matrixTable"){const o=Array.isArray(n==null?void 0:n.selectedEntities)?n.selectedEntities:[];if(o.length===1&&k(o[0])){const s=v(o[0],n);s&&i.push(s)}}if(!i.length&&!c&&e.type!=="matrixTable"){const o=e.config.queryBaseSource;F(o)&&i.push(o)}return{cardId:e.id,kind:"config",executableSources:f.mergeSemaphorSourcesByIdentity(i)}}function w(e,n){return(e.kind==="config"?e.executableSources:e.kind==="sql"?e.pinnedCatalogSources.map(a=>a.source):[]).some(a=>f.semaphorSourcesReferToSameDataset(a,n))}function U(e,n){if(e.kind==="config")return e.executableSources.find(i=>f.semaphorSourcesReferToSameDataset(i,n))}function W(e,n){var i;return(i=C(e,n))==null?void 0:i.source}function C(e,n){if(e.kind==="sql")return e.pinnedCatalogSources.find(i=>f.semaphorSourcesReferToSameDataset(i.source,n))}function R(e){const n=new Set;for(const i of[e.name,e.sourceField]){if(!i)continue;const a=f.normalizeAnalyticsCatalogName(i);if(!a)continue;n.add(a);const t=a.split("."),c=t[t.length-1];c&&n.add(c)}return n}function z(e,n){const i=f.normalizeAnalyticsCatalogDataType(e),a=f.normalizeAnalyticsCatalogDataType(n);return i==="unknown"||a==="unknown"?!1:(i==="date"||i==="datetime")&&(a==="date"||a==="datetime")?!0:i===a}function K(e,n){return f.semaphorSourcesReferToSameDataset(e.field.source,n.field.source)&&f.normalizeAnalyticsCatalogName(e.field.name)===f.normalizeAnalyticsCatalogName(n.field.name)&&f.normalizeAnalyticsCatalogName(e.field.sourceField||e.field.name)===f.normalizeAnalyticsCatalogName(n.field.sourceField||n.field.name)}function P(e,n){if(e.kind!=="field")return!1;const i=R(n),a=R(e.field);return z(n.dataType,e.field.dataType)&&[...a].some(t=>i.has(t))}function Y(e){const n=e.candidates.filter(i=>P(i,e.logicalValueField));return n.length===1?{status:"matched",target:n[0]}:n.length>1?{status:"ambiguous"}:{status:"notApplicable"}}function G(e){const n=[];for(const i of e.acceptedTargets)!z(e.logicalValueField.dataType,i.field.dataType)||n.some(a=>K(a,i))||n.push(i);return n.length===1?{status:"matched",target:n[0]}:n.length>1?{status:"ambiguous"}:{status:"notApplicable"}}const J=/\{\{-?\s*filters\s*\|\s*where\s*-?\}\}/i,Q=/\{\{-?\s*filters\s*\|\s*and\s*-?\}\}/i,X=/\bwhere\b/i;function B(e){return e!=null&&e.trim()?J.test(e)||Q.test(e):!1}function Z(e){return!(e!=null&&e.trim())||B(e)?null:X.test(e)?{helper:"{{ filters | and }}",description:"For queries with an existing WHERE clause."}:{helper:"{{ filters | where }}",description:"For queries without a WHERE clause."}}function ee(e){return(e.field.sourceField||e.field.name).trim()||void 0}function ne(e){if(e.inventory.kind!=="sql"||e.target.kind!=="field")return{status:"ineligible"};const n=C(e.inventory,e.target.field.source),i=ee(e.target);if(!n||!i)return{status:"ineligible"};if(n.executionTable){const o=[n.executionTable.databaseName,n.executionTable.schemaName,n.executionTable.tableName,i].filter(Boolean).join(".");return{status:"eligible",source:n.source,executionIdentifier:o}}if(e.inventory.pinnedCatalogSources.length!==1)return{status:"ineligible"};const a=f.normalizeAnalyticsCatalogName(i),t=(e.candidateTargets||[]).filter(o=>f.normalizeAnalyticsCatalogName(o.field.sourceField||o.field.name)===a),c=[];for(const o of t)c.some(s=>f.semaphorSourcesReferToSameDataset(s,o.field.source))||c.push(o.field.source);return c.length>1?{status:"ineligible"}:{status:"eligible",source:n.source,executionIdentifier:i}}class j extends Error{constructor(i){super(i.map(a=>a.message).join(" "));N(this,"issues");this.name="DashboardFilterMappingContractError",this.issues=i}}const ie={string:!0,number:!0,boolean:!0,date:!0,datetime:!0};function b(e){return typeof e=="string"&&e.trim().length>0}function m(e){return!!e&&typeof e=="object"&&!Array.isArray(e)}function I(e){return Array.isArray(e)&&e.every(n=>typeof n=="string")}function te(e){if(!m(e))return!1;switch(e.kind){case"allSheets":return e.sheetKinds===void 0||I(e.sheetKinds)&&e.sheetKinds.every(n=>n==="dashboard"||n==="document");case"sheets":return I(e.sheetIds);case"cards":return I(e.cardIds);case"documentSections":return b(e.sheetId)&&I(e.sectionIds);default:return!1}}function re(e){return e==="shared"||e==="perSheet"||e==="perCard"||e==="perDocumentSection"}function se(e){return m(e)?b(e.id)&&b(e.column)&&b(e.dataType):!1}function oe(e,n,i,a){var s;if(!m(n)){a.push({code:"invalid_option_source",path:i,message:`${i} must be a semantic or physical option source.`,inputId:e});return}const t=n.source,c=[["labelField",n.labelField],["valueField",n.valueField],["searchField",n.searchField]];if(!m(t)||t.kind!=="semantic"&&t.kind!=="physical"||!f.hasCompleteSemaphorSourceIdentity(t)||!m(n.labelField)||!m(n.valueField)||n.searchField!==void 0&&!m(n.searchField)||n.disambiguationFields!==void 0&&(!Array.isArray(n.disambiguationFields)||!n.disambiguationFields.every(m))){a.push({code:"invalid_option_source",path:i,message:`${i} must contain a valid semantic or physical source and field references.`,inputId:e});return}for(const[d,r]of c)r!==void 0&&m(r)&&(!b(r.name)||r.source!==void 0&&!f.semaphorSourcesReferToSameDataset(r.source,t))&&a.push({code:"invalid_option_source",path:`${i}.${d}`,message:`${i}.${d} must be a named field belonging to the declared option source.`,inputId:e});for(const[d,r]of((s=n.disambiguationFields)==null?void 0:s.entries())||[])(!m(r)||!b(r.name)||r.source!==void 0&&!f.semaphorSourcesReferToSameDataset(r.source,t))&&a.push({code:"invalid_option_source",path:`${i}.disambiguationFields[${d}]`,message:`${i}.disambiguationFields[${d}] must be a named field belonging to the declared option source.`,inputId:e});const o=n.valueField;["string","number","boolean","date","datetime"].includes(String(o.dataType))||a.push({code:"invalid_option_source",path:`${i}.valueField.dataType`,message:`${i}.valueField.dataType must be a known option-value datatype.`,inputId:e})}function ae(e,n,i,a,t,c){var r;if(b(n.bindingId)||t.push({code:"invalid_binding_id",path:`${i}.bindingId`,message:`${i}.bindingId must be an opaque non-empty id.`,inputId:e,cardId:n.cardId}),((r=n.target)==null?void 0:r.kind)!=="field"){t.push({code:"unsupported_target",path:`${i}.target`,message:`${i}.target must be one direct field target.`,inputId:e,cardId:n.cardId,bindingId:n.bindingId});return}const o=n.target.field;if(!b(o==null?void 0:o.name)||!o.source||o.source.kind!=="semantic"&&o.source.kind!=="physical"||!f.hasCompleteSemaphorSourceIdentity(o.source)){t.push({code:"invalid_target_field",path:`${i}.target.field`,message:`${i}.target.field must have a name and a source-qualified semantic or physical identity.`,inputId:e,cardId:n.cardId,bindingId:n.bindingId});return}if(Object.prototype.hasOwnProperty.call(ie,o.dataType)||t.push({code:"unknown_target_data_type",path:`${i}.target.field.dataType`,message:`${i}.target.field.dataType must be known.`,inputId:e,cardId:n.cardId,bindingId:n.bindingId}),o.sourceField!==void 0&&!b(o.sourceField)&&t.push({code:"invalid_target_field",path:`${i}.target.field.sourceField`,message:`${i}.target.field.sourceField must be a non-empty catalog-grounded column when provided.`,inputId:e,cardId:n.cardId,bindingId:n.bindingId}),!c)return;const s=a.get(n.cardId);if(!s){t.push({code:"unknown_card",path:`${i}.cardId`,message:`${i}.cardId '${n.cardId}' does not exist.`,inputId:e,cardId:n.cardId,bindingId:n.bindingId});return}const d=x(s);(d.kind==="unconfigured"||!w(d,o.source))&&t.push({code:"unavailable_card_source",path:`${i}.target.field.source`,message:`${i}.target field source is not declared by card '${s.id}'.`,inputId:e,cardId:s.id,bindingId:n.bindingId})}function de(e,n,i,a,t,c){if(n===void 0)return;if(!m(n)||n.kind!=="cardMappings"||!Array.isArray(n.cards)){t.push({code:"invalid_application",path:i,message:`${i} must be a cardMappings application with a cards array.`,inputId:e});return}const o=new Set;n.cards.forEach((s,d)=>{const r=`${i}.cards[${d}]`;if(!b(s==null?void 0:s.cardId)){t.push({code:"unknown_card",path:`${r}.cardId`,message:`${r}.cardId is required.`,inputId:e});return}if(o.has(s.cardId)){t.push({code:"duplicate_card_application",path:`${r}.cardId`,message:`${i} contains more than one entry for card '${s.cardId}'.`,inputId:e,cardId:s.cardId});return}if(o.add(s.cardId),c&&!a.has(s.cardId)){t.push({code:"unknown_card",path:`${r}.cardId`,message:`${r}.cardId '${s.cardId}' does not exist.`,inputId:e,cardId:s.cardId});return}s.kind==="bound"?ae(e,s,r,a,t,c):s.kind!=="excluded"&&t.push({code:"invalid_application",path:r,message:`${r}.kind must be 'bound' or 'excluded'.`,inputId:e,cardId:s.cardId})})}function q({inputs:e,dashboardFilters:n,cards:i=[],validateCardTargets:a=!1}){const t=[],c=new Map((n||[]).map(r=>[r.id,r])),o=new Map(a?i.map(r=>[r.id,r]):[]),s=[],d=new Map;return e!=null&&!Array.isArray(e)?(t.push({code:"invalid_input",path:"dashboard.inputs",message:"dashboard.inputs must be an array when present."}),{ok:!1,inputs:s,issues:t}):((Array.isArray(e)?e:[]).forEach((r,T)=>{const u=`dashboard.inputs[${T}]`;if(!m(r)||r.kind!=="filter"&&r.kind!=="control"||!b(r.id)||!b(r.label)||!b(r.variableName)||!te(r.scope)||!re(r.runtimeScope)){t.push({code:"invalid_input",path:u,message:`${u} must be a complete filter or control Dashboard Input envelope.`,inputId:m(r)&&typeof r.id=="string"?r.id:void 0});return}if(r.kind==="control"&&!m(r.control)){t.push({code:"invalid_input",path:`${u}.control`,message:`${u}.control must be a control definition.`,inputId:r.id});return}const l=r;if(l.kind==="control"){s.push(l);return}const $=l.filter,g=l.filterReference,y=$!==void 0,E=!!g;if(y&&E){t.push({code:"both_filter_definitions",path:u,message:`${u} must contain either filter or filterReference, not both.`,inputId:l.id});return}if(!y&&!E){t.push({code:"missing_filter_definition",path:u,message:`${u} must contain filter or filterReference.`,inputId:l.id});return}if(y&&!se($)){t.push({code:"invalid_input",path:`${u}.filter`,message:`${u}.filter must be a complete dashboard filter definition.`,inputId:l.id});return}let h,_;if(y)h=$,_="embedded";else{if((g==null?void 0:g.kind)!=="dashboardFilter"){t.push({code:"invalid_filter_reference",path:`${u}.filterReference.kind`,message:`${u}.filterReference.kind must be 'dashboardFilter'.`,inputId:l.id});return}const D=typeof(g==null?void 0:g.filterId)=="string"?g.filterId:void 0;if(h=D?c.get(D):void 0,_="dashboardFilter",!h){t.push({code:"orphaned_filter_reference",path:`${u}.filterReference.filterId`,message:`${u}.filterReference cannot resolve dashboard filter '${D||""}'.`,inputId:l.id});return}if(h.kind==="global-date"){t.push({code:"global_date_reference",path:`${u}.filterReference`,message:`${u}.filterReference cannot reference the Global Date filter.`,inputId:l.id});return}const A=d.get(h.id);if(A){t.push({code:"duplicate_filter_reference",path:`${u}.filterReference.filterId`,message:`${u}.filterReference duplicates dashboard filter '${h.id}' already owned by Dashboard Input '${A}'.`,inputId:l.id});return}d.set(h.id,l.id)}if(!h)return;if(l.optionSource!==void 0&&oe(l.id,l.optionSource,`${u}.optionSource`,t),l.application&&h.kind==="global-date"){t.push({code:"global_date_reference",path:`${u}.application`,message:`${u}.application cannot map the Global Date filter.`,inputId:l.id});return}l.application&&l.scope.kind!=="allSheets"&&l.scope.kind!=="sheets"&&t.push({code:"unsupported_mapped_scope",path:`${u}.scope`,message:`${u}.scope must be allSheets or sheets when cardMappings are present.`,inputId:l.id}),de(l.id,l.application,`${u}.application`,o,t,a);const{filter:me,filterReference:be,compatibility:S,...O}=l;s.push({...O,filter:h,...y&&S?{compatibility:S}:{},...l.optionSource?{optionSource:l.optionSource}:{},definitionOrigin:_})}),t.length?{ok:!1,inputs:s,issues:t}:{ok:!0,inputs:s})}function ce(e){const n=q(e);if(!n.ok)throw new j(n.issues);return n.inputs}function le(e=()=>globalThis.crypto.randomUUID()){return e()}const ue={date:new Set(["between","not between","=","!=",">",">=","<","<=","is null","is not null"]),number:new Set(["between","not between","=","!=",">",">=","<","<=","in","not in","is null","is not null"]),string:new Set(["=","!=","in","not in","like","not like","is null","is not null"]),boolean:new Set(["=","!=","is null","is not null"])};function M(e){const n=f.normalizeAnalyticsCatalogDataType(e);return n==="number"||n==="boolean"?n:n==="date"||n==="datetime"?"date":"string"}function fe(e,n){return typeof n!="string"?!1:ue[M(e)].has(n)}exports.DashboardFilterMappingContractError=j;exports.buildDashboardCardSourceIndex=x;exports.createDashboardFilterBindingId=le;exports.dashboardCardFilterSourceInventoryContains=w;exports.dashboardFilterTargetMatchesLogicalValue=P;exports.dashboardFilterValueTypeForDataType=M;exports.findDashboardCardExecutableSource=U;exports.findDashboardCardPinnedCatalogSource=W;exports.findDashboardSqlPinnedCatalogSource=C;exports.getDashboardFilterSubscriptionHint=Z;exports.hasDashboardFilterSubscription=B;exports.isDashboardFilterOperationCompatible=fe;exports.normalizeDashboardInputs=q;exports.requireNormalizedDashboardInputs=ce;exports.resolveDashboardFilterAutomaticTarget=Y;exports.resolveDashboardFilterInheritedTarget=G;exports.resolveDashboardSqlFilterTarget=ne;
1
+ "use strict";var H=Object.defineProperty;var L=(e,n,i)=>n in e?H(e,n,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[n]=i;var N=(e,n,i)=>L(e,typeof n!="symbol"?n+"":n,i);const f=require("./validators-DO-YuzgO.cjs");require("./analyze-result-contract-CMwVg9w2.cjs");require("../value-format-preferences/index.cjs");function p(e){return!!e&&typeof e=="object"&&!Array.isArray(e)}function k(e){return p(e)&&typeof e.name=="string"}function F(e){return!p(e)||e.kind!=="semantic"&&e.kind!=="physical"||(e.kind==="semantic"?[e.datasetId,e.datasetName,e.connectionId]:[e.databaseName,e.schemaName]).some(i=>i!==void 0&&typeof i!="string")?!1:f.hasCompleteSemaphorSourceIdentity(e)}function v(e,n){var c,o;if((n==null?void 0:n.mode)!=="database"&&e.type==="dataset"&&"domainId"in e&&e.domainId){const s=e,d={kind:"semantic",domainId:s.domainId,datasetId:s.id,datasetName:s.name,connectionId:s.connectionId||(n==null?void 0:n.connectionId),label:s.label};return F(d)?f.canonicalizeSemaphorSourceIdentity(d):void 0}const i=e.connectionId||(n==null?void 0:n.connectionId),a=e.type==="dataset"&&"table"in e&&e.table?e.table:e.name;if(!i||!a)return;const t={kind:"physical",connectionId:i,connectionType:e.connectionType||(n==null?void 0:n.connectionType),tableName:a,databaseName:e.database||((c=n==null?void 0:n.dbSelection)==null?void 0:c.database),schemaName:e.schema||((o=n==null?void 0:n.dbSelection)==null?void 0:o.schema),dialect:e.dialect};return F(t)?t:void 0}function V(e,n){var s,d;const i=v(e,n);if(!i)return;const a=e.type==="dataset"&&"table"in e&&typeof e.table=="string"?e.table.trim():void 0,t=i.kind==="physical"?i.tableName:a,c=e.connectionId||(n==null?void 0:n.connectionId),o=t&&c?{connectionId:c,databaseName:e.database||((s=n==null?void 0:n.dbSelection)==null?void 0:s.database),schemaName:e.schema||((d=n==null?void 0:n.dbSelection)==null?void 0:d.schema),tableName:t}:void 0;return{source:i,...o?{executionTable:o}:{}}}function x(e){const n=p(e.dataSource)?e.dataSource:void 0;if(typeof e.sql=="string"&&e.sql.trim()){const o=[],s=Array.isArray(n==null?void 0:n.selectedEntities)?n.selectedEntities:[];for(const d of s){if(!k(d))continue;const r=V(d,n);r&&!o.some(T=>f.semaphorSourcesReferToSameDataset(T.source,r.source))&&o.push(r)}return{cardId:e.id,kind:"sql",pinnedCatalogSources:o}}if(!p(e.config))return{cardId:e.id,kind:"unconfigured"};const i=[],a=p(e.config.matrixIntent)?e.config.matrixIntent:void 0,t=e.type==="matrixTable"?(a==null?void 0:a.kind)==="matrix"?a.source:e.config.source:void 0;F(t)&&i.push(t);const c=p(e.config.joinPlan)?e.config.joinPlan:void 0;if(c){const o=Array.isArray(c.joins)?c.joins:[],s=[c.baseEntity];for(const d of o)p(d)&&s.push(d.source,d.target);for(const d of s){if(!k(d))continue;const r=v(d,n);r&&i.push(r)}}else if(e.type!=="matrixTable"){const o=Array.isArray(n==null?void 0:n.selectedEntities)?n.selectedEntities:[];if(o.length===1&&k(o[0])){const s=v(o[0],n);s&&i.push(s)}}if(!i.length&&!c&&e.type!=="matrixTable"){const o=e.config.queryBaseSource;F(o)&&i.push(o)}return{cardId:e.id,kind:"config",executableSources:f.mergeSemaphorSourcesByIdentity(i)}}function w(e,n){return(e.kind==="config"?e.executableSources:e.kind==="sql"?e.pinnedCatalogSources.map(a=>a.source):[]).some(a=>f.semaphorSourcesReferToSameDataset(a,n))}function U(e,n){if(e.kind==="config")return e.executableSources.find(i=>f.semaphorSourcesReferToSameDataset(i,n))}function W(e,n){var i;return(i=C(e,n))==null?void 0:i.source}function C(e,n){if(e.kind==="sql")return e.pinnedCatalogSources.find(i=>f.semaphorSourcesReferToSameDataset(i.source,n))}function R(e){const n=new Set;for(const i of[e.name,e.sourceField]){if(!i)continue;const a=f.normalizeAnalyticsCatalogName(i);if(!a)continue;n.add(a);const t=a.split("."),c=t[t.length-1];c&&n.add(c)}return n}function z(e,n){const i=f.normalizeAnalyticsCatalogDataType(e),a=f.normalizeAnalyticsCatalogDataType(n);return i==="unknown"||a==="unknown"?!1:(i==="date"||i==="datetime")&&(a==="date"||a==="datetime")?!0:i===a}function K(e,n){return f.semaphorSourcesReferToSameDataset(e.field.source,n.field.source)&&f.normalizeAnalyticsCatalogName(e.field.name)===f.normalizeAnalyticsCatalogName(n.field.name)&&f.normalizeAnalyticsCatalogName(e.field.sourceField||e.field.name)===f.normalizeAnalyticsCatalogName(n.field.sourceField||n.field.name)}function P(e,n){if(e.kind!=="field")return!1;const i=R(n),a=R(e.field);return z(n.dataType,e.field.dataType)&&[...a].some(t=>i.has(t))}function Y(e){const n=e.candidates.filter(i=>P(i,e.logicalValueField));return n.length===1?{status:"matched",target:n[0]}:n.length>1?{status:"ambiguous"}:{status:"notApplicable"}}function G(e){const n=[];for(const i of e.acceptedTargets)!z(e.logicalValueField.dataType,i.field.dataType)||n.some(a=>K(a,i))||n.push(i);return n.length===1?{status:"matched",target:n[0]}:n.length>1?{status:"ambiguous"}:{status:"notApplicable"}}const J=/\{\{-?\s*filters\s*\|\s*where\s*-?\}\}/i,Q=/\{\{-?\s*filters\s*\|\s*and\s*-?\}\}/i,X=/\bwhere\b/i;function B(e){return e!=null&&e.trim()?J.test(e)||Q.test(e):!1}function Z(e){return!(e!=null&&e.trim())||B(e)?null:X.test(e)?{helper:"{{ filters | and }}",description:"For queries with an existing WHERE clause."}:{helper:"{{ filters | where }}",description:"For queries without a WHERE clause."}}function ee(e){return(e.field.sourceField||e.field.name).trim()||void 0}function ne(e){if(e.inventory.kind!=="sql"||e.target.kind!=="field")return{status:"ineligible"};const n=C(e.inventory,e.target.field.source),i=ee(e.target);if(!n||!i)return{status:"ineligible"};if(n.executionTable){const o=[n.executionTable.databaseName,n.executionTable.schemaName,n.executionTable.tableName,i].filter(Boolean).join(".");return{status:"eligible",source:n.source,executionIdentifier:o}}if(e.inventory.pinnedCatalogSources.length!==1)return{status:"ineligible"};const a=f.normalizeAnalyticsCatalogName(i),t=(e.candidateTargets||[]).filter(o=>f.normalizeAnalyticsCatalogName(o.field.sourceField||o.field.name)===a),c=[];for(const o of t)c.some(s=>f.semaphorSourcesReferToSameDataset(s,o.field.source))||c.push(o.field.source);return c.length>1?{status:"ineligible"}:{status:"eligible",source:n.source,executionIdentifier:i}}class j extends Error{constructor(i){super(i.map(a=>a.message).join(" "));N(this,"issues");this.name="DashboardFilterMappingContractError",this.issues=i}}const ie={string:!0,number:!0,boolean:!0,date:!0,datetime:!0};function b(e){return typeof e=="string"&&e.trim().length>0}function m(e){return!!e&&typeof e=="object"&&!Array.isArray(e)}function I(e){return Array.isArray(e)&&e.every(n=>typeof n=="string")}function te(e){if(!m(e))return!1;switch(e.kind){case"allSheets":return e.sheetKinds===void 0||I(e.sheetKinds)&&e.sheetKinds.every(n=>n==="dashboard"||n==="document");case"sheets":return I(e.sheetIds);case"cards":return I(e.cardIds);case"documentSections":return b(e.sheetId)&&I(e.sectionIds);default:return!1}}function re(e){return e==="shared"||e==="perSheet"||e==="perCard"||e==="perDocumentSection"}function se(e){return m(e)?b(e.id)&&b(e.column)&&b(e.dataType):!1}function oe(e,n,i,a){var s;if(!m(n)){a.push({code:"invalid_option_source",path:i,message:`${i} must be a semantic or physical option source.`,inputId:e});return}const t=n.source,c=[["labelField",n.labelField],["valueField",n.valueField],["searchField",n.searchField]];if(!m(t)||t.kind!=="semantic"&&t.kind!=="physical"||!f.hasCompleteSemaphorSourceIdentity(t)||!m(n.labelField)||!m(n.valueField)||n.searchField!==void 0&&!m(n.searchField)||n.disambiguationFields!==void 0&&(!Array.isArray(n.disambiguationFields)||!n.disambiguationFields.every(m))){a.push({code:"invalid_option_source",path:i,message:`${i} must contain a valid semantic or physical source and field references.`,inputId:e});return}for(const[d,r]of c)r!==void 0&&m(r)&&(!b(r.name)||r.source!==void 0&&!f.semaphorSourcesReferToSameDataset(r.source,t))&&a.push({code:"invalid_option_source",path:`${i}.${d}`,message:`${i}.${d} must be a named field belonging to the declared option source.`,inputId:e});for(const[d,r]of((s=n.disambiguationFields)==null?void 0:s.entries())||[])(!m(r)||!b(r.name)||r.source!==void 0&&!f.semaphorSourcesReferToSameDataset(r.source,t))&&a.push({code:"invalid_option_source",path:`${i}.disambiguationFields[${d}]`,message:`${i}.disambiguationFields[${d}] must be a named field belonging to the declared option source.`,inputId:e});const o=n.valueField;["string","number","boolean","date","datetime"].includes(String(o.dataType))||a.push({code:"invalid_option_source",path:`${i}.valueField.dataType`,message:`${i}.valueField.dataType must be a known option-value datatype.`,inputId:e})}function ae(e,n,i,a,t,c){var r;if(b(n.bindingId)||t.push({code:"invalid_binding_id",path:`${i}.bindingId`,message:`${i}.bindingId must be an opaque non-empty id.`,inputId:e,cardId:n.cardId}),((r=n.target)==null?void 0:r.kind)!=="field"){t.push({code:"unsupported_target",path:`${i}.target`,message:`${i}.target must be one direct field target.`,inputId:e,cardId:n.cardId,bindingId:n.bindingId});return}const o=n.target.field;if(!b(o==null?void 0:o.name)||!o.source||o.source.kind!=="semantic"&&o.source.kind!=="physical"||!f.hasCompleteSemaphorSourceIdentity(o.source)){t.push({code:"invalid_target_field",path:`${i}.target.field`,message:`${i}.target.field must have a name and a source-qualified semantic or physical identity.`,inputId:e,cardId:n.cardId,bindingId:n.bindingId});return}if(Object.prototype.hasOwnProperty.call(ie,o.dataType)||t.push({code:"unknown_target_data_type",path:`${i}.target.field.dataType`,message:`${i}.target.field.dataType must be known.`,inputId:e,cardId:n.cardId,bindingId:n.bindingId}),o.sourceField!==void 0&&!b(o.sourceField)&&t.push({code:"invalid_target_field",path:`${i}.target.field.sourceField`,message:`${i}.target.field.sourceField must be a non-empty catalog-grounded column when provided.`,inputId:e,cardId:n.cardId,bindingId:n.bindingId}),!c)return;const s=a.get(n.cardId);if(!s){t.push({code:"unknown_card",path:`${i}.cardId`,message:`${i}.cardId '${n.cardId}' does not exist.`,inputId:e,cardId:n.cardId,bindingId:n.bindingId});return}const d=x(s);(d.kind==="unconfigured"||!w(d,o.source))&&t.push({code:"unavailable_card_source",path:`${i}.target.field.source`,message:`${i}.target field source is not declared by card '${s.id}'.`,inputId:e,cardId:s.id,bindingId:n.bindingId})}function de(e,n,i,a,t,c){if(n===void 0)return;if(!m(n)||n.kind!=="cardMappings"||!Array.isArray(n.cards)){t.push({code:"invalid_application",path:i,message:`${i} must be a cardMappings application with a cards array.`,inputId:e});return}const o=new Set;n.cards.forEach((s,d)=>{const r=`${i}.cards[${d}]`;if(!b(s==null?void 0:s.cardId)){t.push({code:"unknown_card",path:`${r}.cardId`,message:`${r}.cardId is required.`,inputId:e});return}if(o.has(s.cardId)){t.push({code:"duplicate_card_application",path:`${r}.cardId`,message:`${i} contains more than one entry for card '${s.cardId}'.`,inputId:e,cardId:s.cardId});return}if(o.add(s.cardId),c&&!a.has(s.cardId)){t.push({code:"unknown_card",path:`${r}.cardId`,message:`${r}.cardId '${s.cardId}' does not exist.`,inputId:e,cardId:s.cardId});return}s.kind==="bound"?ae(e,s,r,a,t,c):s.kind!=="excluded"&&t.push({code:"invalid_application",path:r,message:`${r}.kind must be 'bound' or 'excluded'.`,inputId:e,cardId:s.cardId})})}function q({inputs:e,dashboardFilters:n,cards:i=[],validateCardTargets:a=!1}){const t=[],c=new Map((n||[]).map(r=>[r.id,r])),o=new Map(a?i.map(r=>[r.id,r]):[]),s=[],d=new Map;return e!=null&&!Array.isArray(e)?(t.push({code:"invalid_input",path:"dashboard.inputs",message:"dashboard.inputs must be an array when present."}),{ok:!1,inputs:s,issues:t}):((Array.isArray(e)?e:[]).forEach((r,T)=>{const u=`dashboard.inputs[${T}]`;if(!m(r)||r.kind!=="filter"&&r.kind!=="control"||!b(r.id)||!b(r.label)||!b(r.variableName)||!te(r.scope)||!re(r.runtimeScope)){t.push({code:"invalid_input",path:u,message:`${u} must be a complete filter or control Dashboard Input envelope.`,inputId:m(r)&&typeof r.id=="string"?r.id:void 0});return}if(r.kind==="control"&&!m(r.control)){t.push({code:"invalid_input",path:`${u}.control`,message:`${u}.control must be a control definition.`,inputId:r.id});return}const l=r;if(l.kind==="control"){s.push(l);return}const $=l.filter,g=l.filterReference,y=$!==void 0,E=!!g;if(y&&E){t.push({code:"both_filter_definitions",path:u,message:`${u} must contain either filter or filterReference, not both.`,inputId:l.id});return}if(!y&&!E){t.push({code:"missing_filter_definition",path:u,message:`${u} must contain filter or filterReference.`,inputId:l.id});return}if(y&&!se($)){t.push({code:"invalid_input",path:`${u}.filter`,message:`${u}.filter must be a complete dashboard filter definition.`,inputId:l.id});return}let h,_;if(y)h=$,_="embedded";else{if((g==null?void 0:g.kind)!=="dashboardFilter"){t.push({code:"invalid_filter_reference",path:`${u}.filterReference.kind`,message:`${u}.filterReference.kind must be 'dashboardFilter'.`,inputId:l.id});return}const D=typeof(g==null?void 0:g.filterId)=="string"?g.filterId:void 0;if(h=D?c.get(D):void 0,_="dashboardFilter",!h){t.push({code:"orphaned_filter_reference",path:`${u}.filterReference.filterId`,message:`${u}.filterReference cannot resolve dashboard filter '${D||""}'.`,inputId:l.id});return}if(h.kind==="global-date"){t.push({code:"global_date_reference",path:`${u}.filterReference`,message:`${u}.filterReference cannot reference the Global Date filter.`,inputId:l.id});return}const A=d.get(h.id);if(A){t.push({code:"duplicate_filter_reference",path:`${u}.filterReference.filterId`,message:`${u}.filterReference duplicates dashboard filter '${h.id}' already owned by Dashboard Input '${A}'.`,inputId:l.id});return}d.set(h.id,l.id)}if(!h)return;if(l.optionSource!==void 0&&oe(l.id,l.optionSource,`${u}.optionSource`,t),l.application&&h.kind==="global-date"){t.push({code:"global_date_reference",path:`${u}.application`,message:`${u}.application cannot map the Global Date filter.`,inputId:l.id});return}l.application&&l.scope.kind!=="allSheets"&&l.scope.kind!=="sheets"&&t.push({code:"unsupported_mapped_scope",path:`${u}.scope`,message:`${u}.scope must be allSheets or sheets when cardMappings are present.`,inputId:l.id}),de(l.id,l.application,`${u}.application`,o,t,a);const{filter:me,filterReference:be,compatibility:S,...O}=l;s.push({...O,filter:h,...y&&S?{compatibility:S}:{},...l.optionSource?{optionSource:l.optionSource}:{},definitionOrigin:_})}),t.length?{ok:!1,inputs:s,issues:t}:{ok:!0,inputs:s})}function ce(e){const n=q(e);if(!n.ok)throw new j(n.issues);return n.inputs}function le(e=()=>globalThis.crypto.randomUUID()){return e()}const ue={date:new Set(["between","not between","=","!=",">",">=","<","<=","is null","is not null"]),number:new Set(["between","not between","=","!=",">",">=","<","<=","in","not in","is null","is not null"]),string:new Set(["=","!=","in","not in","like","not like","is null","is not null"]),boolean:new Set(["=","!=","in","not in","is null","is not null"])};function M(e){const n=f.normalizeAnalyticsCatalogDataType(e);return n==="number"||n==="boolean"?n:n==="date"||n==="datetime"?"date":"string"}function fe(e,n){return typeof n!="string"?!1:ue[M(e)].has(n)}exports.DashboardFilterMappingContractError=j;exports.buildDashboardCardSourceIndex=x;exports.createDashboardFilterBindingId=le;exports.dashboardCardFilterSourceInventoryContains=w;exports.dashboardFilterTargetMatchesLogicalValue=P;exports.dashboardFilterValueTypeForDataType=M;exports.findDashboardCardExecutableSource=U;exports.findDashboardCardPinnedCatalogSource=W;exports.findDashboardSqlPinnedCatalogSource=C;exports.getDashboardFilterSubscriptionHint=Z;exports.hasDashboardFilterSubscription=B;exports.isDashboardFilterOperationCompatible=fe;exports.normalizeDashboardInputs=q;exports.requireNormalizedDashboardInputs=ce;exports.resolveDashboardFilterAutomaticTarget=Y;exports.resolveDashboardFilterInheritedTarget=G;exports.resolveDashboardSqlFilterTarget=ne;
@@ -1,4 +1,4 @@
1
- import { F as _ } from "./validators-CCpBY1e0.js";
1
+ import { E as _ } from "./validators-DhTaCK1O.js";
2
2
  function C(e, n) {
3
3
  const t = e.split(".").map((r) => r.trim()), i = n.split(".").map((r) => r.trim());
4
4
  if (t.length === 0 || i.length === 0 || t.some((r) => !r) || i.some((r) => !r))
@@ -96,7 +96,7 @@ function S(e, n) {
96
96
  source: { kind: "physical", connectionId: o, tableName: m }
97
97
  };
98
98
  }
99
- function A(e, n) {
99
+ function E(e, n) {
100
100
  const t = u(e.fieldMeta) ? e.fieldMeta : void 0, i = typeof (t == null ? void 0 : t.qualifiedFieldName) == "string" ? t.qualifiedFieldName.trim() : "", s = h(
101
101
  t == null ? void 0 : t.qualifiedFieldName
102
102
  ), o = typeof e.column == "string" ? e.column.trim() : "", a = h(o), r = typeof e.qualifiedTableName == "string" ? e.qualifiedTableName.trim() : "", c = v(
@@ -117,7 +117,7 @@ function A(e, n) {
117
117
  const g = a || s || m;
118
118
  return g ? { status: "resolved", qualifiedFieldName: g } : { status: "unresolved", reason: "incomplete_field_identity" };
119
119
  }
120
- function E(e) {
120
+ function A(e) {
121
121
  if (!u(e))
122
122
  return { status: "ineligible", reason: "invalid_input" };
123
123
  if (e.kind === "global-date")
@@ -134,7 +134,7 @@ function E(e) {
134
134
  return { status: "ineligible", reason: "custom_filter" };
135
135
  if (e.targetColumns !== void 0 && (!Array.isArray(e.targetColumns) || e.targetColumns.length > 0))
136
136
  return { status: "ineligible", reason: "multi_target_filter" };
137
- const s = T(e), o = A(e, s === void 0);
137
+ const s = T(e), o = E(e, s === void 0);
138
138
  if (o.status === "unresolved")
139
139
  return { status: "ineligible", reason: o.reason };
140
140
  const a = s || S(e, o.qualifiedFieldName);
@@ -148,7 +148,7 @@ function E(e) {
148
148
  function B(e) {
149
149
  if (!u(e) || e.kind !== "filter" || !u(e.filter))
150
150
  return { status: "ineligible", reason: "invalid_input" };
151
- const n = E(
151
+ const n = A(
152
152
  e.filter
153
153
  );
154
154
  return n.status === "ineligible" ? n : n.kind === "field_date" && u(e.compatibility) && e.compatibility.source === "cardInlineFilter" ? { status: "ineligible", reason: "card_inline_filter" } : n;
@@ -178,6 +178,6 @@ export {
178
178
  j as g,
179
179
  k as i,
180
180
  N as q,
181
- E as r,
181
+ A as r,
182
182
  F as s
183
183
  };
@@ -1,19 +1,19 @@
1
1
  import { jsxs as d, jsx as e } from "react/jsx-runtime";
2
2
  import { useMemo as p, useState as u, useRef as f, useEffect as b } from "react";
3
3
  import { X as S } from "./x-CXDkqdur.js";
4
- import { u as a, c as N, B as D, C as J } from "./switch-B6rFVSdw.js";
5
- import "./saved-temporal-bucket-format-DfqnCGCz.js";
6
- import "./validators-CCpBY1e0.js";
7
- import "./analyze-result-contract-CMZDRRwo.js";
4
+ import { u as a, c as N, B as D, C as J } from "./switch-BagpmPNw.js";
5
+ import "./saved-temporal-bucket-format-hylaofsQ.js";
6
+ import "./validators-DhTaCK1O.js";
7
+ import "./analyze-result-contract-kaCNxjA7.js";
8
8
  import "../value-format-preferences/index.js";
9
- import "./index-B31RKKGb.js";
9
+ import "./index-8Cm77joZ.js";
10
10
  import "./appearance-runtime-provider-CjmE4gBY.js";
11
11
  import "./appearance-context-DVXt8qjW.js";
12
12
  import "./index-DSKR3nKn.js";
13
- import "./temporal-bucket-authoring-ZxFzhTmL.js";
13
+ import "./temporal-bucket-authoring-DjPFtRSF.js";
14
14
  import "./color-CJvdlFM_.js";
15
15
  import "react-dom";
16
- import "./index-BlCnNcaB.js";
16
+ import "./index-DO4BESNy.js";
17
17
  function q() {
18
18
  const r = a((o) => o.dashboard), c = a((o) => o.actions.setDashboard), h = a(
19
19
  (o) => o.showDashboardJSON
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),o=require("react"),b=require("./x-B6ghREd2.cjs"),r=require("./switch-BghC7eOM.cjs");require("./saved-temporal-bucket-format-Ca4hUfTo.cjs");require("./validators-DO-YuzgO.cjs");require("./analyze-result-contract-CMwVg9w2.cjs");require("../value-format-preferences/index.cjs");require("./index-yJRh4x9j.cjs");require("./appearance-runtime-provider-BgNYdUYH.cjs");require("./appearance-context-DhyjbQk1.cjs");require("./index-ByFbacH7.cjs");require("./temporal-bucket-authoring-C6sZAVqS.cjs");require("./color-CyB5o13F.cjs");require("react-dom");require("./index-CQN-X1jN.cjs");function S(){const t=r.useDashboardStore(e=>e.dashboard),d=r.useDashboardStore(e=>e.actions.setDashboard),c=r.useDashboardStore(e=>e.showDashboardJSON),h=r.useDashboardStore(e=>e.actions.setShowDashboardJSON),s=o.useMemo(()=>t?JSON.stringify(t,null,2):"",[t]),[l,n]=o.useState(s),i=o.useRef(s);return o.useEffect(()=>{s!==i.current&&(n(s),i.current=s)},[s]),a.jsxs("div",{className:r.cn("relative p-2",{hidden:!c}),children:[a.jsxs(r.Button,{variant:"secondary",size:"sm",className:"absolute right-2 top-2 z-10 h-8",onClick:()=>h(!1),children:[a.jsx(b.X,{className:"mr-2 h-4 w-4"}),"Close"]}),a.jsx("div",{className:"h-[550px] overflow-hidden",children:a.jsx(r.CodeEditor,{value:l,onValueChange:e=>{n(e);try{const u=JSON.parse(e);i.current=JSON.stringify(u,null,2),d(u)}catch{}},language:"json"})})]})}exports.default=S;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),o=require("react"),b=require("./x-B6ghREd2.cjs"),r=require("./switch-DyE2_OmQ.cjs");require("./saved-temporal-bucket-format-Ca4hUfTo.cjs");require("./validators-DO-YuzgO.cjs");require("./analyze-result-contract-CMwVg9w2.cjs");require("../value-format-preferences/index.cjs");require("./index-DKaQRhKm.cjs");require("./appearance-runtime-provider-BgNYdUYH.cjs");require("./appearance-context-DhyjbQk1.cjs");require("./index-ByFbacH7.cjs");require("./temporal-bucket-authoring-C6sZAVqS.cjs");require("./color-CyB5o13F.cjs");require("react-dom");require("./index-CQN-X1jN.cjs");function S(){const t=r.useDashboardStore(e=>e.dashboard),d=r.useDashboardStore(e=>e.actions.setDashboard),c=r.useDashboardStore(e=>e.showDashboardJSON),h=r.useDashboardStore(e=>e.actions.setShowDashboardJSON),s=o.useMemo(()=>t?JSON.stringify(t,null,2):"",[t]),[l,n]=o.useState(s),i=o.useRef(s);return o.useEffect(()=>{s!==i.current&&(n(s),i.current=s)},[s]),a.jsxs("div",{className:r.cn("relative p-2",{hidden:!c}),children:[a.jsxs(r.Button,{variant:"secondary",size:"sm",className:"absolute right-2 top-2 z-10 h-8",onClick:()=>h(!1),children:[a.jsx(b.X,{className:"mr-2 h-4 w-4"}),"Close"]}),a.jsx("div",{className:"h-[550px] overflow-hidden",children:a.jsx(r.CodeEditor,{value:l,onValueChange:e=>{n(e);try{const u=JSON.parse(e);i.current=JSON.stringify(u,null,2),d(u)}catch{}},language:"json"})})]})}exports.default=S;