react-semaphor 0.1.407 → 0.1.409

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 (47) hide show
  1. package/dist/analytics-protocol/index.cjs +1 -1
  2. package/dist/analytics-protocol/index.js +22 -21
  3. package/dist/chunks/{calendar-preferences-dialog-BEJunQM-.js → calendar-preferences-dialog-B8FmFRHX.js} +1 -1
  4. package/dist/chunks/{calendar-preferences-dialog-BDovl96B.js → calendar-preferences-dialog-ck4AU-to.js} +1 -1
  5. package/dist/chunks/{dashboard-briefing-launcher-D-G1kXb8.js → dashboard-briefing-launcher-Br_1IK1z.js} +1 -1
  6. package/dist/chunks/{dashboard-briefing-launcher-DmybDHiR.js → dashboard-briefing-launcher-Tr2SqDMK.js} +2 -2
  7. package/dist/chunks/{dashboard-controls-DgjlAGWu.js → dashboard-controls-B2bEv8uG.js} +3 -3
  8. package/dist/chunks/{dashboard-controls-DIPQW6Vj.js → dashboard-controls-B7OObDNl.js} +1 -1
  9. package/dist/chunks/{dashboard-json-DUmEB8x3.js → dashboard-json-DAB8WVyb.js} +1 -1
  10. package/dist/chunks/{dashboard-json-DvW8_MWp.js → dashboard-json-DNixjalS.js} +1 -1
  11. package/dist/chunks/{edit-dashboard-visual-BZnVLA4S.js → edit-dashboard-visual-DWygSAp3.js} +1 -1
  12. package/dist/chunks/{edit-dashboard-visual-BuwFsoeW.js → edit-dashboard-visual-Dh8Ge3-B.js} +2 -2
  13. package/dist/chunks/{index-DhkNgPPm.js → index-BkTLAfKy.js} +4 -4
  14. package/dist/chunks/{index-D7JKnhyA.js → index-CQIMj-FF.js} +2 -2
  15. package/dist/chunks/source-identity-BM2FvJDP.js +1 -0
  16. package/dist/chunks/{source-identity-y0VSSreA.js → source-identity-Cv4Nm3TM.js} +23 -15
  17. package/dist/chunks/{update-policy-Bv3_5LFK.js → update-policy-BnEbPhHW.js} +305 -282
  18. package/dist/chunks/update-policy-CWg9c08k.js +3 -0
  19. package/dist/chunks/{use-create-flow-overlay-state-C9QPAd9_.js → use-create-flow-overlay-state-CZA-dSns.js} +1 -1
  20. package/dist/chunks/{use-create-flow-overlay-state-B8clS9IG.js → use-create-flow-overlay-state-uujasvbD.js} +1 -1
  21. package/dist/chunks/{validators-DaBsAUsR.js → validators-C-_9Ew5G.js} +1 -1
  22. package/dist/chunks/{validators-BCQB11_y.js → validators-CB9BFarT.js} +1 -1
  23. package/dist/dashboard/index.cjs +1 -1
  24. package/dist/dashboard/index.js +1 -1
  25. package/dist/dashboard-authoring/index.cjs +1 -1
  26. package/dist/dashboard-authoring/index.js +2 -2
  27. package/dist/data-app-builder/index.cjs +1 -1
  28. package/dist/data-app-builder/index.js +1 -1
  29. package/dist/data-app-codegen/index.cjs +1 -1
  30. package/dist/data-app-codegen/index.js +1 -1
  31. package/dist/data-app-codegen-node/index.cjs +304 -105
  32. package/dist/data-app-codegen-node/index.js +800 -503
  33. package/dist/data-app-sdk/index.cjs +2 -2
  34. package/dist/data-app-sdk/index.js +158 -155
  35. package/dist/data-app-sdk-adapters/index.cjs +1 -1
  36. package/dist/data-app-sdk-adapters/index.js +1 -1
  37. package/dist/data-app-sdk-validation/index.cjs +1 -1
  38. package/dist/data-app-sdk-validation/index.js +2 -2
  39. package/dist/index.cjs +1 -1
  40. package/dist/index.js +4 -4
  41. package/dist/surfboard/index.cjs +1 -1
  42. package/dist/surfboard/index.js +2 -2
  43. package/dist/types/analytics-protocol.d.ts +2 -0
  44. package/dist/types/data-app-sdk.d.ts +3 -0
  45. package/package.json +1 -1
  46. package/dist/chunks/source-identity-uMaUe036.js +0 -1
  47. package/dist/chunks/update-policy-2M0canB_.js +0 -3
@@ -1,11 +1,12 @@
1
1
  import { toSemaphorInputSnapshots as Pr, toSemaphorInputBinding as zr, toSemaphorActiveInputSnapshots as X, toSemaphorMatrixIntent as Fr, toSemaphorSqlIntent as Mr, toSemaphorInputOptionsIntent as jr, toSemaphorRecordsIntent as Hr, toSemaphorAnalysisQueryOptions as Vr, toSemaphorAnalysisIntent as Qr, toSemaphorMetricIntent as Ur, hasSemaphorInputValue as ue, normalizeSemaphorInputOptions as gr, toSemaphorInputSpec as mr } from "../data-app-sdk-adapters/index.js";
2
2
  import { jsxs as p, Fragment as yr, jsx as a } from "react/jsx-runtime";
3
3
  import { createContext as Ie, useContext as Q, useState as F, useRef as E, useEffect as B, useMemo as I, Fragment as Gr, useId as hr, useCallback as O, useReducer as Jr } from "react";
4
- import { a as Yr, m as Xr } from "../chunks/source-identity-y0VSSreA.js";
4
+ import { a as Yr, m as Xr } from "../chunks/source-identity-Cv4Nm3TM.js";
5
+ import { d as ro } from "../chunks/source-identity-Cv4Nm3TM.js";
5
6
  import "../chunks/analyze-result-contract-DPjm6btg.js";
6
7
  import { M as Zr, a as et, S as rt, E as tt, C as nt } from "../chunks/search-BHsQIWBV.js";
7
8
  import { X as it, C as ot, j as st } from "../chunks/x-CXDkqdur.js";
8
- import { b as at } from "../chunks/validators-DaBsAUsR.js";
9
+ import { b as at } from "../chunks/validators-C-_9Ew5G.js";
9
10
  function me(e, r, t = {}) {
10
11
  return {
11
12
  ...t,
@@ -291,24 +292,24 @@ function Me(e) {
291
292
  (v = n == null ? void 0 : n.coverage) == null ? void 0 : v.missingObligations
292
293
  ), f = Ce(
293
294
  (g = n == null ? void 0 : n.coverage) == null ? void 0 : g.warnings
294
- ), d = [], c = xe(r);
295
- (t == null ? void 0 : t.status) === "error" && d.push({
295
+ ), l = [], c = xe(r);
296
+ (t == null ? void 0 : t.status) === "error" && l.push({
296
297
  trace: r,
297
298
  tone: "error",
298
299
  title: c,
299
300
  message: t.errorMessage || "Query attempt failed."
300
301
  });
301
302
  for (const h of r.clientWarnings)
302
- d.push({ trace: r, tone: "warning", title: c, message: h });
303
+ l.push({ trace: r, tone: "warning", title: c, message: h });
303
304
  for (const h of i)
304
- d.push({ trace: r, tone: "warning", title: c, ...h });
305
+ l.push({ trace: r, tone: "warning", title: c, ...h });
305
306
  for (const h of o)
306
- d.push({ trace: r, tone: "error", title: c, ...h });
307
+ l.push({ trace: r, tone: "error", title: c, ...h });
307
308
  for (const h of u)
308
- d.push({ trace: r, tone: "warning", title: c, message: h });
309
+ l.push({ trace: r, tone: "warning", title: c, message: h });
309
310
  for (const h of f)
310
- d.push({ trace: r, tone: "warning", title: c, ...h });
311
- return d;
311
+ l.push({ trace: r, tone: "warning", title: c, ...h });
312
+ return l;
312
313
  });
313
314
  }
314
315
  function mt(e) {
@@ -1558,7 +1559,7 @@ function $t({
1558
1559
  Cn,
1559
1560
  t,
1560
1561
  Rr
1561
- ), o = E(n), u = hr(), [f, d] = F({ open: !1 });
1562
+ ), o = E(n), u = hr(), [f, l] = F({ open: !1 });
1562
1563
  o.current = n, B(() => {
1563
1564
  i({ type: "config", config: t });
1564
1565
  }, [t]), B(() => {
@@ -1573,11 +1574,11 @@ function $t({
1573
1574
  };
1574
1575
  }, [u, n.enabled, n.exposeWindowBridge]);
1575
1576
  const c = I(() => ({ state: n, dispatch: i }), [n]), y = O((h) => {
1576
- d({ open: !0, focus: h });
1577
+ l({ open: !0, focus: h });
1577
1578
  }, []), m = O(() => {
1578
- d((h) => ({ ...h, open: !1 }));
1579
+ l((h) => ({ ...h, open: !1 }));
1579
1580
  }, []), v = O((h) => {
1580
- d({ open: !0, focus: h });
1581
+ l({ open: !0, focus: h });
1581
1582
  }, []), g = I(
1582
1583
  () => ({
1583
1584
  open: f.open,
@@ -1629,7 +1630,7 @@ function Bt({
1629
1630
  className: n,
1630
1631
  style: i
1631
1632
  } = {}) {
1632
- const o = qr(), u = Q(He), [f, d] = F(""), [c, y] = F(!1), m = E(null), v = E(null), g = u == null ? void 0 : u.openDevtools, h = u == null ? void 0 : u.closeDevtools, T = (u == null ? void 0 : u.open) === !0;
1633
+ const o = qr(), u = Q(He), [f, l] = F(""), [c, y] = F(!1), m = E(null), v = E(null), g = u == null ? void 0 : u.openDevtools, h = u == null ? void 0 : u.closeDevtools, T = (u == null ? void 0 : u.open) === !0;
1633
1634
  B(() => {
1634
1635
  wr();
1635
1636
  }, []), B(() => {
@@ -1646,13 +1647,13 @@ function Bt({
1646
1647
  document.removeEventListener("pointerdown", S, !0), document.removeEventListener("mousedown", S, !0), document.removeEventListener("click", S, !0);
1647
1648
  };
1648
1649
  }, [h, T]);
1649
- const l = I(
1650
+ const d = I(
1650
1651
  () => ht(o.queries),
1651
1652
  [o.queries]
1652
1653
  ), b = I(
1653
1654
  () => Me(o.queries),
1654
1655
  [o.queries]
1655
- ), K = tn(l), A = I(
1656
+ ), K = tn(d), A = I(
1656
1657
  () => nn(o.queries, f),
1657
1658
  [o.queries, f]
1658
1659
  ), N = I(
@@ -1674,7 +1675,7 @@ function Bt({
1674
1675
  style: {
1675
1676
  ...s.launcher,
1676
1677
  ...xt(e),
1677
- ...qt(l.severity),
1678
+ ...qt(d.severity),
1678
1679
  ...i
1679
1680
  },
1680
1681
  onClick: () => {
@@ -1690,11 +1691,11 @@ function Bt({
1690
1691
  },
1691
1692
  children: [
1692
1693
  /* @__PURE__ */ a(Wt, {}),
1693
- /* @__PURE__ */ a("span", { style: s.launcherText, children: l.total }),
1694
- l.issueCount > 0 ? /* @__PURE__ */ p("span", { style: s.launcherIssueCount, children: [
1695
- l.issueCount,
1694
+ /* @__PURE__ */ a("span", { style: s.launcherText, children: d.total }),
1695
+ d.issueCount > 0 ? /* @__PURE__ */ p("span", { style: s.launcherIssueCount, children: [
1696
+ d.issueCount,
1696
1697
  " issue",
1697
- l.issueCount === 1 ? "" : "s"
1698
+ d.issueCount === 1 ? "" : "s"
1698
1699
  ] }) : null
1699
1700
  ]
1700
1701
  }
@@ -1717,17 +1718,17 @@ function Bt({
1717
1718
  /* @__PURE__ */ p("div", { style: s.panelTitleBlock, children: [
1718
1719
  /* @__PURE__ */ a("div", { style: s.panelTitle, children: "Semaphor Inspector" }),
1719
1720
  /* @__PURE__ */ p("div", { style: s.panelSubtitle, children: [
1720
- l.total,
1721
+ d.total,
1721
1722
  " queries · ",
1722
- l.loading,
1723
+ d.loading,
1723
1724
  " loading ·",
1724
1725
  " ",
1725
- l.failed,
1726
+ d.failed,
1726
1727
  " failed · ",
1727
- l.errorCount,
1728
+ d.errorCount,
1728
1729
  " errors ·",
1729
1730
  " ",
1730
- l.warningCount,
1731
+ d.warningCount,
1731
1732
  " warnings"
1732
1733
  ] })
1733
1734
  ] }),
@@ -1762,7 +1763,7 @@ function Bt({
1762
1763
  {
1763
1764
  "aria-label": "Search Semaphor traces",
1764
1765
  value: f,
1765
- onChange: (S) => d(S.currentTarget.value),
1766
+ onChange: (S) => l(S.currentTarget.value),
1766
1767
  placeholder: "Search traces",
1767
1768
  style: s.searchInput
1768
1769
  }
@@ -1874,15 +1875,15 @@ function Qi({
1874
1875
  B(() => {
1875
1876
  wr();
1876
1877
  }, []);
1877
- const d = r || (f == null ? void 0 : f.id), c = I(
1878
+ const l = r || (f == null ? void 0 : f.id), c = I(
1878
1879
  () => sn(o.queries, {
1879
1880
  queryId: e,
1880
- viewId: d
1881
+ viewId: l
1881
1882
  }),
1882
1883
  [
1883
1884
  o.queries,
1884
1885
  e,
1885
- d
1886
+ l
1886
1887
  ]
1887
1888
  );
1888
1889
  if (!o.enabled || !u || !c)
@@ -1924,7 +1925,7 @@ function Kt({
1924
1925
  activeInputs: i,
1925
1926
  debug: o
1926
1927
  }) {
1927
- const u = Q(je), f = Q(Ve), d = !!(u != null && u.state.enabled), c = u == null ? void 0 : u.dispatch, y = Kn(e), m = pt(e), v = I(
1928
+ const u = Q(je), f = Q(Ve), l = !!(u != null && u.state.enabled), c = u == null ? void 0 : u.dispatch, y = Kn(e), m = pt(e), v = I(
1928
1929
  () => JSON.stringify(e),
1929
1930
  [e]
1930
1931
  ), g = I(
@@ -1933,8 +1934,8 @@ function Kt({
1933
1934
  ), h = I(
1934
1935
  () => JSON.stringify(n || null),
1935
1936
  [n]
1936
- ), T = E(e), l = E(v), b = E(n), K = E(h), A = E(i), N = E(g), $ = Bn(o), S = JSON.stringify($ || []), w = E($), L = E(S);
1937
- l.current !== v && (l.current = v, T.current = e), K.current !== h && (K.current = h, b.current = n), N.current !== g && (N.current = g, A.current = i), L.current !== S && (L.current = S, w.current = $);
1937
+ ), T = E(e), d = E(v), b = E(n), K = E(h), A = E(i), N = E(g), $ = Bn(o), S = JSON.stringify($ || []), w = E($), L = E(S);
1938
+ d.current !== v && (d.current = v, T.current = e), K.current !== h && (K.current = h, b.current = n), N.current !== g && (N.current = g, A.current = i), L.current !== S && (L.current = S, w.current = $);
1938
1939
  const x = T.current, D = b.current, pe = A.current, re = w.current, te = hr(), C = I(
1939
1940
  () => y || `query_${Dr(t)}`,
1940
1941
  [t, y]
@@ -1979,16 +1980,16 @@ function Kt({
1979
1980
  ]
1980
1981
  );
1981
1982
  B(() => {
1982
- if (!(!d || !c))
1983
+ if (!(!l || !c))
1983
1984
  return c({ type: "register", descriptor: Ye }), () => {
1984
1985
  c({ type: "unregister", traceKey: j });
1985
1986
  };
1986
- }, [Ye, c, d, j]);
1987
+ }, [Ye, c, l, j]);
1987
1988
  const P = O(
1988
1989
  (k, U) => {
1989
- !d || !c || c({ type: "event", traceKey: j, event: k, latestAttempt: U });
1990
+ !l || !c || c({ type: "event", traceKey: j, event: k, latestAttempt: U });
1990
1991
  },
1991
- [c, d, j]
1992
+ [c, l, j]
1992
1993
  ), Xe = O(() => {
1993
1994
  P(
1994
1995
  {
@@ -2059,10 +2060,10 @@ function Kt({
2059
2060
  ge(k, 0);
2060
2061
  },
2061
2062
  [ge]
2062
- ), Ae = d ? u == null ? void 0 : u.state.entries[j] : void 0;
2063
+ ), Ae = l ? u == null ? void 0 : u.state.entries[j] : void 0;
2063
2064
  return I(
2064
2065
  () => ({
2065
- enabled: d,
2066
+ enabled: l,
2066
2067
  queryId: C,
2067
2068
  trace: Ae ? ve(Ae) : void 0,
2068
2069
  start: Xe,
@@ -2072,7 +2073,7 @@ function Kt({
2072
2073
  validationFailure: rr
2073
2074
  }),
2074
2075
  [
2075
- d,
2076
+ l,
2076
2077
  ge,
2077
2078
  er,
2078
2079
  C,
@@ -2113,7 +2114,7 @@ function _t({
2113
2114
  (w = t == null ? void 0 : t.coverage) == null ? void 0 : w.missingObligations
2114
2115
  ), u = $e(
2115
2116
  (L = t == null ? void 0 : t.coverage) == null ? void 0 : L.warnings
2116
- ), f = t == null ? void 0 : t.compiledQuery, d = An(t), c = ((x = e.server) == null ? void 0 : x.compiledSql) || d.compiledSql, y = dt(t), m = [
2117
+ ), f = t == null ? void 0 : t.compiledQuery, l = An(t), c = ((x = e.server) == null ? void 0 : x.compiledSql) || l.compiledSql, y = dt(t), m = [
2117
2118
  ...r != null && r.errorMessage ? [r.errorMessage] : [],
2118
2119
  ...i
2119
2120
  ], v = [
@@ -2121,7 +2122,7 @@ function _t({
2121
2122
  ...n,
2122
2123
  ...o,
2123
2124
  ...u
2124
- ], g = e.inputsApplied.length > 0, h = !!(f || c), T = pn(e), l = hn(r == null ? void 0 : r.rowCount), b = bn(r == null ? void 0 : r.durationMs), K = e.sourceRefs.length, A = kr(e), N = Ar(A);
2125
+ ], g = e.inputsApplied.length > 0, h = !!(f || c), T = pn(e), d = hn(r == null ? void 0 : r.rowCount), b = bn(r == null ? void 0 : r.durationMs), K = e.sourceRefs.length, A = kr(e), N = Ar(A);
2125
2126
  return /* @__PURE__ */ p("div", { style: s.detailsPane, children: [
2126
2127
  /* @__PURE__ */ p("div", { style: s.detailsHeader, children: [
2127
2128
  /* @__PURE__ */ p("div", { style: s.detailsHeaderTopRow, children: [
@@ -2151,7 +2152,7 @@ function _t({
2151
2152
  /* @__PURE__ */ a("span", { style: s.metaStripItem, children: T }),
2152
2153
  /* @__PURE__ */ a("span", { style: s.metaStripDot, children: "·" }),
2153
2154
  /* @__PURE__ */ p("span", { style: s.metaStripItem, children: [
2154
- l,
2155
+ d,
2155
2156
  " rows"
2156
2157
  ] }),
2157
2158
  /* @__PURE__ */ a("span", { style: s.metaStripDot, children: "·" }),
@@ -2218,22 +2219,22 @@ function Nt({
2218
2219
  label: "Raw",
2219
2220
  render: () => /* @__PURE__ */ a("pre", { style: s.codeBlock, children: vn(e) })
2220
2221
  });
2221
- const u = (T = o[0]) == null ? void 0 : T.id, f = e.traceId || `${e.viewId ?? ""}:${e.queryId}`, [d, c] = F(u), y = E(f), m = E(!1), v = o.map((l) => l.id).join("|");
2222
+ const u = (T = o[0]) == null ? void 0 : T.id, f = e.traceId || `${e.viewId ?? ""}:${e.queryId}`, [l, c] = F(u), y = E(f), m = E(!1), v = o.map((d) => d.id).join("|");
2222
2223
  B(() => {
2223
2224
  if (y.current !== f) {
2224
2225
  y.current = f, m.current = !1, c(u);
2225
2226
  return;
2226
2227
  }
2227
- if (!(d ? v.split("|").includes(d) : !1)) {
2228
+ if (!(l ? v.split("|").includes(l) : !1)) {
2228
2229
  m.current = !1, c(u);
2229
2230
  return;
2230
2231
  }
2231
- !m.current && d !== u && c(u);
2232
- }, [d, u, v, f]);
2233
- const g = o.find((l) => l.id === d) ?? o[0];
2232
+ !m.current && l !== u && c(u);
2233
+ }, [l, u, v, f]);
2234
+ const g = o.find((d) => d.id === l) ?? o[0];
2234
2235
  return /* @__PURE__ */ p("div", { style: s.traceTabs, children: [
2235
- /* @__PURE__ */ a("div", { style: s.traceTabBar, role: "tablist", "aria-label": "Trace details", children: o.map((l) => {
2236
- const b = l.id === g.id;
2236
+ /* @__PURE__ */ a("div", { style: s.traceTabBar, role: "tablist", "aria-label": "Trace details", children: o.map((d) => {
2237
+ const b = d.id === g.id;
2237
2238
  return /* @__PURE__ */ a(
2238
2239
  "button",
2239
2240
  {
@@ -2246,11 +2247,11 @@ function Nt({
2246
2247
  ...b ? s.traceTabActive : null
2247
2248
  },
2248
2249
  onClick: () => {
2249
- m.current = !0, c(l.id);
2250
+ m.current = !0, c(d.id);
2250
2251
  },
2251
- children: l.label
2252
+ children: d.label
2252
2253
  },
2253
- l.id
2254
+ d.id
2254
2255
  );
2255
2256
  }) }),
2256
2257
  /* @__PURE__ */ a("div", { style: s.traceTabPanel, role: "tabpanel", children: g.render() })
@@ -2279,7 +2280,7 @@ function zt({
2279
2280
  issues: e,
2280
2281
  onSelect: r
2281
2282
  }) {
2282
- const [t, n] = F(!1), i = e.slice(0, 6), o = e.length - i.length, u = e.filter((c) => c.tone === "error").length, f = e.length - u, d = [
2283
+ const [t, n] = F(!1), i = e.slice(0, 6), o = e.length - i.length, u = e.filter((c) => c.tone === "error").length, f = e.length - u, l = [
2283
2284
  u ? `${u} error${u === 1 ? "" : "s"}` : "",
2284
2285
  f ? `${f} warning${f === 1 ? "" : "s"}` : ""
2285
2286
  ].filter(Boolean);
@@ -2334,7 +2335,7 @@ function zt({
2334
2335
  " in traces"
2335
2336
  ] }) : null
2336
2337
  ] }) : /* @__PURE__ */ p("div", { style: s.issueSummaryCollapsed, children: [
2337
- d.join(" · "),
2338
+ l.join(" · "),
2338
2339
  " across traces"
2339
2340
  ] })
2340
2341
  ] });
@@ -2837,8 +2838,8 @@ function gn(e) {
2837
2838
  return [e.aggregate, e.label || e.name].filter(Boolean).join(" ");
2838
2839
  }
2839
2840
  function mn(e) {
2840
- var f, d, c;
2841
- const r = e.valuePreview || "redacted", t = e.inputLabel || e.inputId, n = ((f = e.fieldRef) == null ? void 0 : f.label) || ((d = e.fieldRef) == null ? void 0 : d.name), i = (c = e.fieldRef) != null && c.source ? z(e.fieldRef.source) : void 0, o = [n ? `on ${n}` : void 0, i].filter(Boolean).join(" · "), u = [
2841
+ var f, l, c;
2842
+ const r = e.valuePreview || "redacted", t = e.inputLabel || e.inputId, n = ((f = e.fieldRef) == null ? void 0 : f.label) || ((l = e.fieldRef) == null ? void 0 : l.name), i = (c = e.fieldRef) != null && c.source ? z(e.fieldRef.source) : void 0, o = [n ? `on ${n}` : void 0, i].filter(Boolean).join(" · "), u = [
2842
2843
  t,
2843
2844
  e.inputId,
2844
2845
  e.operator,
@@ -3495,9 +3496,9 @@ function Ge({
3495
3496
  return {
3496
3497
  records: e.map((o, u) => {
3497
3498
  const f = {};
3498
- return r.forEach((d) => {
3499
- if (Object.prototype.hasOwnProperty.call(o, d.key)) {
3500
- f[d.key] = o[d.key];
3499
+ return r.forEach((l) => {
3500
+ if (Object.prototype.hasOwnProperty.call(o, l.key)) {
3501
+ f[l.key] = o[l.key];
3501
3502
  return;
3502
3503
  }
3503
3504
  n.push({
@@ -3505,11 +3506,11 @@ function Ge({
3505
3506
  severity: "warning",
3506
3507
  resultSetKey: t,
3507
3508
  rowIndex: u,
3508
- columnKey: d.key,
3509
- ...d.name ? { columnName: d.name } : {},
3510
- ...d.label ? { columnLabel: d.label } : {},
3509
+ columnKey: l.key,
3510
+ ...l.name ? { columnName: l.name } : {},
3511
+ ...l.label ? { columnLabel: l.label } : {},
3511
3512
  availableKeys: Object.keys(o),
3512
- message: `Analysis result set "${t}" row ${u} is missing column key "${d.key}". Rows must expose values by column.key; labels and column names are display metadata only.`
3513
+ message: `Analysis result set "${t}" row ${u} is missing column key "${l.key}". Rows must expose values by column.key; labels and column names are display metadata only.`
3513
3514
  });
3514
3515
  }), f;
3515
3516
  }),
@@ -4004,22 +4005,22 @@ function Ui(e) {
4004
4005
  () => gr(e.options),
4005
4006
  [e.options]
4006
4007
  ), u = O(
4007
- (d) => {
4008
+ (l) => {
4008
4009
  var y;
4009
- const c = d;
4010
+ const c = l;
4010
4011
  (y = e.onValueChange) == null || y.call(e, c), n || t(c);
4011
4012
  },
4012
4013
  [n, e]
4013
4014
  ), f = O(() => u(void 0), [u]);
4014
4015
  return I(() => {
4015
- const d = mr(e);
4016
+ const l = mr(e);
4016
4017
  return {
4017
4018
  id: e.id,
4018
4019
  kind: e.kind,
4019
4020
  label: e.label,
4020
- field: d.field,
4021
- operator: d.operator,
4022
- relationshipHint: d.relationshipHint,
4021
+ field: l.field,
4022
+ operator: l.operator,
4023
+ relationshipHint: l.relationshipHint,
4023
4024
  controlRole: e.kind === "control" ? e.role : void 0,
4024
4025
  value: i,
4025
4026
  options: o,
@@ -4027,14 +4028,14 @@ function Ui(e) {
4027
4028
  setValue: u,
4028
4029
  clear: f,
4029
4030
  toAnalyticsInput: () => ({
4030
- inputId: d.inputId,
4031
- field: d.field,
4031
+ inputId: l.inputId,
4032
+ field: l.field,
4032
4033
  kind: e.kind,
4033
4034
  label: e.label,
4034
4035
  value: i,
4035
4036
  isActive: ue(i),
4036
- operator: d.operator,
4037
- relationshipHint: d.relationshipHint,
4037
+ operator: l.operator,
4038
+ relationshipHint: l.relationshipHint,
4038
4039
  controlRole: e.kind === "control" ? e.role : void 0
4039
4040
  })
4040
4041
  };
@@ -4060,7 +4061,7 @@ function Gi(e) {
4060
4061
  ...v,
4061
4062
  [n.id]: y
4062
4063
  }));
4063
- }, d = () => f(void 0), c = mr(n);
4064
+ }, l = () => f(void 0), c = mr(n);
4064
4065
  return {
4065
4066
  id: n.id,
4066
4067
  kind: n.kind,
@@ -4073,7 +4074,7 @@ function Gi(e) {
4073
4074
  options: u,
4074
4075
  isActive: ue(o),
4075
4076
  setValue: f,
4076
- clear: d,
4077
+ clear: l,
4077
4078
  toAnalyticsInput: () => ({
4078
4079
  inputId: c.inputId,
4079
4080
  field: c.field,
@@ -4175,51 +4176,51 @@ function Yi(e, r = {}) {
4175
4176
  i.success
4176
4177
  ]
4177
4178
  ), f = O(
4178
- (l) => {
4179
+ (d) => {
4179
4180
  var K, A, N, $, S, w, L, x, D;
4180
4181
  const b = n.request;
4181
4182
  if (b.intent)
4182
4183
  switch (n.queryKind) {
4183
4184
  case "metric":
4184
- return (K = l.executor) == null ? void 0 : K.executeMetric(
4185
+ return (K = d.executor) == null ? void 0 : K.executeMetric(
4185
4186
  b.intent,
4186
- l
4187
+ d
4187
4188
  );
4188
4189
  case "analysis":
4189
- return (N = (A = l.executor) == null ? void 0 : A.executeAnalysis) == null ? void 0 : N.call(
4190
+ return (N = (A = d.executor) == null ? void 0 : A.executeAnalysis) == null ? void 0 : N.call(
4190
4191
  A,
4191
4192
  b.intent,
4192
- l,
4193
+ d,
4193
4194
  b.analysisOptions
4194
4195
  );
4195
4196
  case "records":
4196
- return ($ = l.executor) == null ? void 0 : $.executeRecords(
4197
+ return ($ = d.executor) == null ? void 0 : $.executeRecords(
4197
4198
  b.intent,
4198
- l
4199
+ d
4199
4200
  );
4200
4201
  case "inputOptions":
4201
- return (S = l.executor) == null ? void 0 : S.executeInputOptions(
4202
+ return (S = d.executor) == null ? void 0 : S.executeInputOptions(
4202
4203
  b.intent,
4203
- l
4204
+ d
4204
4205
  );
4205
4206
  case "sql":
4206
- return (L = (w = l.executor) == null ? void 0 : w.executeSql) == null ? void 0 : L.call(
4207
+ return (L = (w = d.executor) == null ? void 0 : w.executeSql) == null ? void 0 : L.call(
4207
4208
  w,
4208
4209
  b.intent,
4209
- l
4210
+ d
4210
4211
  );
4211
4212
  case "matrix":
4212
- return (D = (x = l.executor) == null ? void 0 : x.executeMatrix) == null ? void 0 : D.call(
4213
+ return (D = (x = d.executor) == null ? void 0 : x.executeMatrix) == null ? void 0 : D.call(
4213
4214
  x,
4214
4215
  b.intent,
4215
- l
4216
+ d
4216
4217
  );
4217
4218
  default:
4218
4219
  return Se(n);
4219
4220
  }
4220
4221
  },
4221
4222
  [n]
4222
- ), d = $i(
4223
+ ), l = $i(
4223
4224
  n.request.queryKey,
4224
4225
  f,
4225
4226
  n.request.idleData,
@@ -4227,142 +4228,143 @@ function Yi(e, r = {}) {
4227
4228
  u
4228
4229
  ), c = i.queryId, y = i.validationFailure;
4229
4230
  B(() => {
4230
- const l = n.request.error;
4231
- if (!l) {
4231
+ const d = n.request.error;
4232
+ if (!d) {
4232
4233
  o.current = null;
4233
4234
  return;
4234
4235
  }
4235
- const b = `${c}:${l.message}`;
4236
- o.current !== b && (o.current = b, y(l));
4236
+ const b = `${c}:${d.message}`;
4237
+ o.current !== b && (o.current = b, y(d));
4237
4238
  }, [
4238
4239
  n.request.error,
4239
4240
  n.request.queryKey,
4240
4241
  c,
4241
4242
  y
4242
4243
  ]);
4243
- const m = n.request.error ? n.request.idleData : d.data, v = n.request.error ? "error" : d.status, g = !n.request.error && d.status === "loading", h = n.request.error || d.error, T = i.trace;
4244
+ const m = n.request.error ? n.request.idleData : l.data, v = n.request.error ? "error" : l.status, g = !n.request.error && l.status === "loading", h = n.request.error || l.error, T = i.trace;
4244
4245
  switch (n.queryKind) {
4245
4246
  case "metric": {
4246
- const l = m, b = J({
4247
+ const d = m, b = J({
4247
4248
  queryKind: n.queryKind,
4248
4249
  status: v,
4249
4250
  isLoading: g,
4250
4251
  error: h,
4251
4252
  trace: T,
4252
- payload: l,
4253
+ payload: d,
4253
4254
  activeInputs: n.request.activeInputs,
4254
- isStale: d.isStale
4255
+ isStale: l.isStale
4255
4256
  });
4256
4257
  return {
4257
4258
  id: t.id,
4258
4259
  intent: n.request.intent,
4259
- value: (l == null ? void 0 : l.value) ?? null,
4260
- measures: l == null ? void 0 : l.measures,
4261
- comparisonValue: l == null ? void 0 : l.comparisonValue,
4262
- delta: l == null ? void 0 : l.delta,
4263
- deltaPercent: l == null ? void 0 : l.deltaPercent,
4264
- records: l == null ? void 0 : l.records,
4260
+ value: (d == null ? void 0 : d.value) ?? null,
4261
+ measures: d == null ? void 0 : d.measures,
4262
+ measureBindings: d == null ? void 0 : d.measureBindings,
4263
+ comparisonValue: d == null ? void 0 : d.comparisonValue,
4264
+ delta: d == null ? void 0 : d.delta,
4265
+ deltaPercent: d == null ? void 0 : d.deltaPercent,
4266
+ records: d == null ? void 0 : d.records,
4265
4267
  ...b
4266
4268
  };
4267
4269
  }
4268
4270
  case "analysis": {
4269
- const l = Or(m), b = J({
4271
+ const d = Or(m), b = J({
4270
4272
  queryKind: n.queryKind,
4271
4273
  status: v,
4272
4274
  isLoading: g,
4273
4275
  error: h,
4274
4276
  trace: T,
4275
- payload: l,
4277
+ payload: d,
4276
4278
  activeInputs: n.request.activeInputs,
4277
- isStale: d.isStale
4279
+ isStale: l.isStale
4278
4280
  });
4279
4281
  return {
4280
4282
  id: t.id,
4281
4283
  intent: n.request.intent,
4282
- ...l || {},
4284
+ ...d || {},
4283
4285
  ...b
4284
4286
  };
4285
4287
  }
4286
4288
  case "records": {
4287
- const l = m, b = J({
4289
+ const d = m, b = J({
4288
4290
  queryKind: n.queryKind,
4289
4291
  status: v,
4290
4292
  isLoading: g,
4291
4293
  error: h,
4292
4294
  trace: T,
4293
- payload: l,
4295
+ payload: d,
4294
4296
  activeInputs: n.request.activeInputs,
4295
- isStale: d.isStale
4297
+ isStale: l.isStale
4296
4298
  });
4297
4299
  return {
4298
4300
  id: t.id,
4299
4301
  intent: n.request.intent,
4300
- records: (l == null ? void 0 : l.records) || [],
4301
- columns: l == null ? void 0 : l.columns,
4302
- rowCount: l == null ? void 0 : l.rowCount,
4303
- pagination: l == null ? void 0 : l.pagination,
4304
- totals: l == null ? void 0 : l.totals,
4302
+ records: (d == null ? void 0 : d.records) || [],
4303
+ columns: d == null ? void 0 : d.columns,
4304
+ rowCount: d == null ? void 0 : d.rowCount,
4305
+ pagination: d == null ? void 0 : d.pagination,
4306
+ totals: d == null ? void 0 : d.totals,
4305
4307
  ...b
4306
4308
  };
4307
4309
  }
4308
4310
  case "inputOptions": {
4309
- const l = m, b = J({
4311
+ const d = m, b = J({
4310
4312
  queryKind: n.queryKind,
4311
4313
  status: v,
4312
4314
  isLoading: g,
4313
4315
  error: h,
4314
4316
  trace: T,
4315
- payload: l,
4317
+ payload: d,
4316
4318
  activeInputs: n.request.activeInputs,
4317
- isStale: d.isStale
4319
+ isStale: l.isStale
4318
4320
  });
4319
4321
  return {
4320
4322
  id: t.id,
4321
4323
  intent: n.request.intent,
4322
- options: (l == null ? void 0 : l.options) || [],
4324
+ options: (d == null ? void 0 : d.options) || [],
4323
4325
  ...b
4324
4326
  };
4325
4327
  }
4326
4328
  case "sql": {
4327
- const l = m, b = J({
4329
+ const d = m, b = J({
4328
4330
  queryKind: n.queryKind,
4329
4331
  status: v,
4330
4332
  isLoading: g,
4331
4333
  error: h,
4332
4334
  trace: T,
4333
- payload: l,
4335
+ payload: d,
4334
4336
  activeInputs: n.request.activeInputs,
4335
- isStale: d.isStale
4337
+ isStale: l.isStale
4336
4338
  });
4337
4339
  return {
4338
4340
  id: t.id,
4339
4341
  intent: n.request.intent,
4340
- records: (l == null ? void 0 : l.records) || [],
4341
- columns: l == null ? void 0 : l.columns,
4342
- rowCount: l == null ? void 0 : l.rowCount,
4343
- pagination: l == null ? void 0 : l.pagination,
4344
- output: l == null ? void 0 : l.output,
4345
- rowLimitExceeded: l == null ? void 0 : l.rowLimitExceeded,
4342
+ records: (d == null ? void 0 : d.records) || [],
4343
+ columns: d == null ? void 0 : d.columns,
4344
+ rowCount: d == null ? void 0 : d.rowCount,
4345
+ pagination: d == null ? void 0 : d.pagination,
4346
+ output: d == null ? void 0 : d.output,
4347
+ rowLimitExceeded: d == null ? void 0 : d.rowLimitExceeded,
4346
4348
  ...b
4347
4349
  };
4348
4350
  }
4349
4351
  case "matrix": {
4350
- const l = m, b = J({
4352
+ const d = m, b = J({
4351
4353
  queryKind: n.queryKind,
4352
4354
  status: v,
4353
4355
  isLoading: g,
4354
4356
  error: h,
4355
4357
  trace: T,
4356
- payload: l,
4358
+ payload: d,
4357
4359
  activeInputs: n.request.activeInputs,
4358
- isStale: d.isStale
4360
+ isStale: l.isStale
4359
4361
  });
4360
4362
  return {
4361
4363
  id: t.id,
4362
4364
  intent: n.request.intent,
4363
- matrixResult: l == null ? void 0 : l.matrixResult,
4364
- grid: l == null ? void 0 : l.grid,
4365
- expansion: l == null ? void 0 : l.expansion,
4365
+ matrixResult: d == null ? void 0 : d.matrixResult,
4366
+ grid: d == null ? void 0 : d.grid,
4367
+ expansion: d == null ? void 0 : d.expansion,
4366
4368
  ...b
4367
4369
  };
4368
4370
  }
@@ -4384,7 +4386,7 @@ function J(e) {
4384
4386
  isEmpty: Li(e.queryKind, e.payload, e.status),
4385
4387
  isPartial: Ri(e.payload, r),
4386
4388
  isFiltered: !!((f = e.activeInputs) != null && f.some(
4387
- (d) => d.kind === "filter" && d.isActive
4389
+ (l) => l.kind === "filter" && l.isActive
4388
4390
  )),
4389
4391
  isStale: e.isStale,
4390
4392
  isValidated: !!t,
@@ -4407,30 +4409,30 @@ function Li(e, r, t) {
4407
4409
  return !1;
4408
4410
  switch (e) {
4409
4411
  case "metric": {
4410
- const d = r;
4411
- return (d == null ? void 0 : d.value) == null && !_(d == null ? void 0 : d.records);
4412
+ const l = r;
4413
+ return (l == null ? void 0 : l.value) == null && !_(l == null ? void 0 : l.records);
4412
4414
  }
4413
4415
  case "analysis": {
4414
- const d = r;
4415
- return d ? !d.answerSummary && !_(d.records) && !_(d.changes) && !_(d.drivers) && !_(d.largestNegativeChanges) && !_(d.largestPositiveChanges) && !_(d.largestNegativeDrivers) && !_(d.largestPositiveDrivers) && !Object.values(d.resultSets || {}).some(
4416
+ const l = r;
4417
+ return l ? !l.answerSummary && !_(l.records) && !_(l.changes) && !_(l.drivers) && !_(l.largestNegativeChanges) && !_(l.largestPositiveChanges) && !_(l.largestNegativeDrivers) && !_(l.largestPositiveDrivers) && !Object.values(l.resultSets || {}).some(
4416
4418
  (c) => _(c.records)
4417
4419
  ) : !0;
4418
4420
  }
4419
4421
  case "records": {
4420
- const d = r;
4421
- return !_(d == null ? void 0 : d.records);
4422
+ const l = r;
4423
+ return !_(l == null ? void 0 : l.records);
4422
4424
  }
4423
4425
  case "sql": {
4424
- const d = r;
4425
- return !_(d == null ? void 0 : d.records) && (d == null ? void 0 : d.output) === void 0;
4426
+ const l = r;
4427
+ return !_(l == null ? void 0 : l.records) && (l == null ? void 0 : l.output) === void 0;
4426
4428
  }
4427
4429
  case "inputOptions": {
4428
- const d = r;
4429
- return !((n = d == null ? void 0 : d.options) != null && n.length);
4430
+ const l = r;
4431
+ return !((n = l == null ? void 0 : l.options) != null && n.length);
4430
4432
  }
4431
4433
  case "matrix": {
4432
- const d = r;
4433
- return !((o = (i = d == null ? void 0 : d.matrixResult) == null ? void 0 : i.cells) != null && o.length) && !((f = (u = d == null ? void 0 : d.grid) == null ? void 0 : u.cells) != null && f.length);
4434
+ const l = r;
4435
+ return !((o = (i = l == null ? void 0 : l.matrixResult) == null ? void 0 : i.cells) != null && o.length) && !((f = (u = l == null ? void 0 : l.grid) == null ? void 0 : u.cells) != null && f.length);
4434
4436
  }
4435
4437
  default:
4436
4438
  return Se(e);
@@ -4440,7 +4442,7 @@ function _(e) {
4440
4442
  return Array.isArray(e) && e.length > 0;
4441
4443
  }
4442
4444
  function $i(e, r, t, n, i) {
4443
- const o = Ai(), u = E(r), f = E(n), [d, c] = F({
4445
+ const o = Ai(), u = E(r), f = E(n), [l, c] = F({
4444
4446
  status: "idle",
4445
4447
  data: t,
4446
4448
  error: null,
@@ -4485,7 +4487,7 @@ function $i(e, r, t, n, i) {
4485
4487
  }), () => {
4486
4488
  m = !0;
4487
4489
  };
4488
- }, [t, e, o, i]), d;
4490
+ }, [t, e, o, i]), l;
4489
4491
  }
4490
4492
  function _r() {
4491
4493
  return typeof performance < "u" && performance.now ? performance.now() : Date.now();
@@ -4512,16 +4514,16 @@ function Xi({
4512
4514
  children: i
4513
4515
  }) {
4514
4516
  var g;
4515
- const o = Ti(), u = ((g = o == null ? void 0 : o.authToken) == null ? void 0 : g.accessToken) || e, f = (o == null ? void 0 : o.dataApiBaseUrl) || (o == null ? void 0 : o.apiBaseUrl) || r, d = (o == null ? void 0 : o.debug) ?? n, c = Oi(d), y = I(() => mi(), []), m = t || y, v = I(
4517
+ const o = Ti(), u = ((g = o == null ? void 0 : o.authToken) == null ? void 0 : g.accessToken) || e, f = (o == null ? void 0 : o.dataApiBaseUrl) || (o == null ? void 0 : o.apiBaseUrl) || r, l = (o == null ? void 0 : o.debug) ?? n, c = Oi(l), y = I(() => mi(), []), m = t || y, v = I(
4516
4518
  () => ({
4517
4519
  token: u,
4518
4520
  apiBaseUrl: f,
4519
4521
  executor: m,
4520
- debug: d
4522
+ debug: l
4521
4523
  }),
4522
- [f, d, m, u]
4524
+ [f, l, m, u]
4523
4525
  );
4524
- return /* @__PURE__ */ a($t, { debug: d, children: /* @__PURE__ */ p(Wr.Provider, { value: v, children: [
4526
+ return /* @__PURE__ */ a($t, { debug: l, children: /* @__PURE__ */ p(Wr.Provider, { value: v, children: [
4525
4527
  i,
4526
4528
  c ? /* @__PURE__ */ a(Bt, { ...c }) : null
4527
4529
  ] }) });
@@ -4536,6 +4538,7 @@ export {
4536
4538
  ji as defineSemaphorInput,
4537
4539
  Ci as isSemaphorInputValueValidForOptions,
4538
4540
  Hi as semaphor,
4541
+ ro as semaphorMetricMeasureBindingKey,
4539
4542
  Ji as useClearInvalidSemaphorInputValue,
4540
4543
  qr as useSemaphorDevtools,
4541
4544
  Ui as useSemaphorInput,