@trilogy-data/trilogy-studio-components 0.1.28 → 0.1.30

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 (110) hide show
  1. package/README.md +1 -0
  2. package/dist/AssetAutoImporter-BA8C4p09.js +403 -0
  3. package/dist/{ChatCreatorModal-Cd40SvdM.js → ChatCreatorModal-94gZ9D-y.js} +1 -1
  4. package/dist/{CodeBlock-Dj-GfTbW.js → CodeBlock-C9o09ipr.js} +1 -1
  5. package/dist/{CommunityModels-lX2RhHCG.js → CommunityModels-D48H9Bqt.js} +6 -6
  6. package/dist/{ConnectionView-CZ06qjjE.js → ConnectionView-sEXGE8Vs.js} +5 -5
  7. package/dist/{CreateEditorFromDatasourcePopup-DwA938kf.js → CreateEditorFromDatasourcePopup-BUoegyem.js} +2 -2
  8. package/dist/{Dashboard-CQsIqWZC.js → Dashboard-C6adKZ7q.js} +202 -203
  9. package/dist/{DashboardImportSelector-CkqH52FX.js → DashboardImportSelector-CQqXshDj.js} +1 -1
  10. package/dist/{DashboardMobile-DWFlel5p.js → DashboardMobile-BU1nDLQv.js} +42 -42
  11. package/dist/{Editor-DQ66Vp6v.js → Editor-DO4VRvek.js} +9 -10
  12. package/dist/{ErrorMessage-D5JeF3Iz.js → ErrorMessage-Cz7q7vJI.js} +1 -1
  13. package/dist/{GlobalChatPanel-B_s3COHE.js → GlobalChatPanel-Ct6oSj_A.js} +20 -20
  14. package/dist/{IDE-4-Jg6gsM.js → IDE-kdaEhA4g.js} +19 -20
  15. package/dist/{JobsView-B5NWDUgP.js → JobsView-BcyWrDRf.js} +11 -11
  16. package/dist/{LLMChat-eKgEc-I3.js → LLMChat-Dg8VvTIP.js} +19 -19
  17. package/dist/{LLMView-CdTwMLVV.js → LLMView-CZNNYXC1.js} +61 -61
  18. package/dist/{LoadingView-Bu3wLJ7J.js → LoadingView-k2CIKiN7.js} +1 -1
  19. package/dist/{MarkdownRenderer-B6lqdkgc.js → MarkdownRenderer-Dlb_KGmk.js} +1 -1
  20. package/dist/{MobileIDE-CZlg20oa.js → MobileIDE-BQcdjWUT.js} +26 -27
  21. package/dist/{ModelCard-Bs_d7Jis.js → ModelCard-Dn2b5WLs.js} +5 -5
  22. package/dist/{ModelView-BP5yyecx.js → ModelView-BEi83zrX.js} +6 -6
  23. package/dist/{PageLoading-DKFeqkmK.js → PageLoading-C7H6q6U6.js} +248 -248
  24. package/dist/{ResultComponent-BaDheojB.js → ResultComponent-DW9Q9tp9.js} +5 -5
  25. package/dist/{Results-CrpHB101.js → Results-N2OttUlb.js} +19 -19
  26. package/dist/{StatusIcon-Clfyy-Yn.js → StatusIcon-B21tjIXx.js} +1 -1
  27. package/dist/{StoreTokenModal-CO5hXMs3.js → StoreTokenModal-CHgvjLGl.js} +1 -1
  28. package/dist/{SymbolsPane-XFVErDFb.js → SymbolsPane-DUrLpSSw.js} +11 -11
  29. package/dist/{TutorialPage-CMcTYDOV.js → TutorialPage-DHgPuFN0.js} +11 -11
  30. package/dist/{VegaLiteChart-DX_LbF3g.js → VegaLiteChart-BqHLSptG.js} +11116 -11067
  31. package/dist/{WelcomePage-B6E35FUa.js → WelcomePage-CN6ptsoF.js} +3 -3
  32. package/dist/agent.js +1349 -0
  33. package/dist/components/VegaLiteChart.vue.d.ts.map +1 -1
  34. package/dist/components/chartControlsManager.d.ts +0 -1
  35. package/dist/components/chartControlsManager.d.ts.map +1 -1
  36. package/dist/{cssMode-zpO2ap2B.js → cssMode-DW4OByy3.js} +2 -2
  37. package/dist/dashboard.js +63 -63
  38. package/dist/dashboards/chartTheme.d.ts +68 -0
  39. package/dist/dashboards/chartTheme.d.ts.map +1 -0
  40. package/dist/dashboards/donutSpec.d.ts +2 -1
  41. package/dist/dashboards/donutSpec.d.ts.map +1 -1
  42. package/dist/dashboards/headlineSpec.d.ts +2 -1
  43. package/dist/dashboards/headlineSpec.d.ts.map +1 -1
  44. package/dist/dashboards/helpers.d.ts +23 -0
  45. package/dist/dashboards/helpers.d.ts.map +1 -1
  46. package/dist/dashboards/index.d.ts +2 -0
  47. package/dist/dashboards/index.d.ts.map +1 -1
  48. package/dist/dashboards/layerSpec.d.ts +4 -1
  49. package/dist/dashboards/layerSpec.d.ts.map +1 -1
  50. package/dist/dashboards/pointSpec.d.ts +2 -1
  51. package/dist/dashboards/pointSpec.d.ts.map +1 -1
  52. package/dist/dashboards/spec.d.ts +8 -1
  53. package/dist/dashboards/spec.d.ts.map +1 -1
  54. package/dist/{editor.main-BQh6DxDB.js → editor.main-TuTbSVcN.js} +22 -22
  55. package/dist/{editorStore-CiWH_nGN.js → editorStore-Czhpct1j.js} +1751 -1181
  56. package/dist/entry.agent.d.ts +12 -0
  57. package/dist/entry.agent.d.ts.map +1 -0
  58. package/dist/entry.llm.d.ts +1 -1
  59. package/dist/entry.llm.d.ts.map +1 -1
  60. package/dist/{freemarker2-DQBqlEXc.js → freemarker2-ZGcKAI8o.js} +1 -1
  61. package/dist/{globalChatRuntime-DAERmOdu.js → globalChatRuntime-BnMYNYqe.js} +35 -35
  62. package/dist/{handlebars-tgYxaM70.js → handlebars-B3s0Qrrb.js} +1 -1
  63. package/dist/{helpers-C2pARJoZ.js → helpers-B3tq3RZK.js} +17 -17
  64. package/dist/{html-jJahD3Mi.js → html-DM1koKCG.js} +1 -1
  65. package/dist/{htmlMode-BA1-8l2e.js → htmlMode-CpPImbDh.js} +2 -2
  66. package/dist/{javascript-Cypfo7va.js → javascript-jClqu73w.js} +1 -1
  67. package/dist/{jsonMode-xJye8PWS.js → jsonMode-CwFYTPO9.js} +2 -2
  68. package/dist/{liquid-BGDrv5da.js → liquid-C6l-UINC.js} +1 -1
  69. package/dist/llm/chatAgentPrompt.d.ts +4 -16
  70. package/dist/llm/chatAgentPrompt.d.ts.map +1 -1
  71. package/dist/llm/dashboardAgentRuntime.d.ts +10 -10
  72. package/dist/llm/dashboardAgentTools.d.ts +10 -10
  73. package/dist/llm/data/prompts.d.ts +1 -1
  74. package/dist/llm/data/prompts.d.ts.map +1 -1
  75. package/dist/llm/data/trilogySyntax.generated.d.ts +3 -3
  76. package/dist/llm/data/trilogySyntax.generated.d.ts.map +1 -1
  77. package/dist/llm/returnToUserTool.d.ts +20 -0
  78. package/dist/llm/returnToUserTool.d.ts.map +1 -0
  79. package/dist/llm/toolLoopCore.d.ts +7 -0
  80. package/dist/llm/toolLoopCore.d.ts.map +1 -1
  81. package/dist/llm/utils.d.ts.map +1 -1
  82. package/dist/{llm-Wf4Etiu9.js → llm-Bc1CfjOE.js} +2203 -2722
  83. package/dist/llm.js +3 -3
  84. package/dist/{localStorage-C3xms-ab.js → localStorage-Cy0sHlT0.js} +19 -19
  85. package/dist/{lspLanguageFeatures-V3e_p9oN.js → lspLanguageFeatures-GDtuGOTD.js} +1 -1
  86. package/dist/{mdx-BUR1aImW.js → mdx-BQEQ0k1f.js} +1 -1
  87. package/dist/monaco.js +3 -3
  88. package/dist/{python-YLkl0pc6.js → python-USoVCfWY.js} +1 -1
  89. package/dist/{razor-BP8TRMDY.js → razor-BxmgiR-q.js} +1 -1
  90. package/dist/{reconcile-BH_ReGDR.js → reconcile-DtPcgEjQ.js} +1 -1
  91. package/dist/{remoteStoreSync-B0K8QScO.js → remoteStoreSync-CscErZ-I.js} +2 -2
  92. package/dist/{stores-DTGQZ4_B.js → stores-DgdADCiH.js} +323 -323
  93. package/dist/stores.js +3 -4
  94. package/dist/trilogy-studio-components.css +1 -1
  95. package/dist/{tsMode-BH9HS_sH.js → tsMode-BEQ7aXX4.js} +1 -1
  96. package/dist/{typescript-BM-ynfk9.js → typescript-CzBSjjfY.js} +1 -1
  97. package/dist/{useChatWithTools-BSrzJtYI.js → useChatWithTools-CMhGxdyr.js} +14 -14
  98. package/dist/{useDashboard-CGeIdDuX.js → useDashboard-CjZgjmgb.js} +553 -553
  99. package/dist/{useGlobalChatPanel-D9kMZLeF.js → useGlobalChatPanel-Doeilj18.js} +69 -70
  100. package/dist/views/LLMView.vue.d.ts +23 -23
  101. package/dist/views/TutorialPage.vue.d.ts +10 -10
  102. package/dist/views.js +147 -148
  103. package/dist/vite.agent.config.d.ts +3 -0
  104. package/dist/vite.agent.config.d.ts.map +1 -0
  105. package/dist/{workers-B9Eybl-M.js → workers-CHvkad0r.js} +2 -2
  106. package/dist/{xml-M5WFPSpA.js → xml-ODdyS0gX.js} +1 -1
  107. package/dist/{yaml-CEeFwjz9.js → yaml-PCBTA2qD.js} +1 -1
  108. package/package.json +7 -2
  109. package/dist/AssetAutoImporter-C_7Ms9xe.js +0 -403
  110. package/dist/rolldown-runtime-B0aSnxlc.js +0 -20
@@ -1,27 +1,27 @@
1
- import { t as e } from "./_plugin-vue_export-helper-f9Rw-Il4.js";
2
- import { o as t } from "./config-DwTONafa.js";
3
- import { c as n, u as r } from "./base-DuKnVD-A.js";
4
- import { $t as i, Ft as a, Gt as o, Kt as s, Zt as c, an as l, fn as u, in as d, ln as f, rn as p, tn as m, un as h } from "./llm-Wf4Etiu9.js";
5
- import { a as g, f as _, g as v, p as y } from "./stores-DTGQZ4_B.js";
6
- import { S as b, _ as x, b as S, d as C, et as w, f as ee, g as T, h as E, it as te, l as D, m as O, p as ne, t as re, u as ie } from "./editorStore-CiWH_nGN.js";
7
- import { n as ae, t as oe } from "./DashboardImportSelector-CkqH52FX.js";
8
- import { f as k, p as A, r as se, u as ce } from "./useGlobalChatPanel-D9kMZLeF.js";
9
- import { t as j } from "./ErrorMessage-D5JeF3Iz.js";
10
- import { t as le } from "./VegaLiteChart-DX_LbF3g.js";
11
- import { t as ue } from "./LoadingView-Bu3wLJ7J.js";
1
+ import { $t as e, Jt as t, Lt as n, an as r, dn as i, fn as a, on as o, qt as s, rn as c, sn as l, tn as u } from "./llm-Bc1CfjOE.js";
2
+ import { t as d } from "./_plugin-vue_export-helper-f9Rw-Il4.js";
3
+ import { o as f } from "./config-DwTONafa.js";
4
+ import { c as p, u as m } from "./base-DuKnVD-A.js";
5
+ import { S as h, _ as g, b as _, d as v, et as y, f as b, g as x, h as S, it as C, l as w, m as T, p as E, pt as D, t as ee, u as O } from "./editorStore-Czhpct1j.js";
6
+ import { a as k, f as te, g as ne, p as re } from "./stores-DgdADCiH.js";
7
+ import { t as ie } from "./VegaLiteChart-BqHLSptG.js";
8
+ import { n as ae, t as oe } from "./DashboardImportSelector-CQqXshDj.js";
9
+ import { f as A, p as se, r as ce, u as le } from "./useGlobalChatPanel-Doeilj18.js";
10
+ import { t as j } from "./ErrorMessage-Cz7q7vJI.js";
11
+ import { t as ue } from "./LoadingView-k2CIKiN7.js";
12
12
  import { t as de } from "./DrilldownPane-BheRHJMs.js";
13
- import { t as fe } from "./MarkdownRenderer-B6lqdkgc.js";
14
- import { a as pe, d as me, l as he, o as M } from "./workers-B9Eybl-M.js";
15
- import "./editor.main-BQh6DxDB.js";
13
+ import { t as fe } from "./MarkdownRenderer-Dlb_KGmk.js";
14
+ import { a as pe, d as me, l as he, o as M } from "./workers-CHvkad0r.js";
15
+ import "./editor.main-TuTbSVcN.js";
16
16
  import { t as ge } from "./tokenTheme-DBbeCrCg.js";
17
- import { t as _e } from "./SymbolsPane-XFVErDFb.js";
17
+ import { t as _e } from "./SymbolsPane-DUrLpSSw.js";
18
18
  import { n as ve, t as ye } from "./useResizableDialog-Cs90WJdF.js";
19
19
  import { Fragment as N, Teleport as be, computed as P, createBlock as F, createCommentVNode as I, createElementBlock as L, createElementVNode as R, createTextVNode as z, createVNode as B, defineComponent as V, inject as H, nextTick as xe, normalizeClass as U, normalizeStyle as Se, onBeforeUnmount as Ce, onMounted as we, onUnmounted as Te, openBlock as W, ref as G, renderList as K, renderSlot as Ee, resolveComponent as q, resolveDynamicComponent as De, toDisplayString as J, unref as Y, vModelRadio as Oe, vModelText as ke, vShow as Ae, watch as X, withCtx as Z, withDirectives as je, withKeys as Me, withModifiers as Ne } from "vue";
20
20
  //#region components/dashboard/DashboardSharePopup.vue?vue&type=script&setup=true&lang.ts
21
21
  var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
22
22
  "data-testid": "dashboard-json",
23
23
  class: "json-code"
24
- }, Le = /*#__PURE__*/ e(/* @__PURE__ */ V({
24
+ }, Le = /*#__PURE__*/ d(/* @__PURE__ */ V({
25
25
  __name: "DashboardSharePopup",
26
26
  props: {
27
27
  dashboard: {},
@@ -59,7 +59,7 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
59
59
  console.error("Could not copy text: ", e);
60
60
  });
61
61
  };
62
- return (t, n) => (W(), F(A, {
62
+ return (t, n) => (W(), F(se, {
63
63
  show: e.isOpen,
64
64
  title: "Export Definition",
65
65
  "max-width": "860px",
@@ -111,58 +111,58 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
111
111
  "data-testid",
112
112
  "onBlur",
113
113
  "onKeyup"
114
- ], ut = ["disabled", "onClick"], dt = { class: "section" }, ft = ["disabled"], pt = /*#__PURE__*/ e(/* @__PURE__ */ V({
114
+ ], ut = ["disabled", "onClick"], dt = { class: "section" }, ft = ["disabled"], pt = /*#__PURE__*/ d(/* @__PURE__ */ V({
115
115
  __name: "DashboardThemePopup",
116
116
  props: {
117
117
  dashboard: {},
118
118
  isOpen: { type: Boolean }
119
119
  },
120
120
  emits: ["close", "theme-change"],
121
- setup(e, { emit: n }) {
122
- let r = e, a = n, o = H("userSettingsStore", null), s = t(o), c = P(() => r.dashboard?.theme || {}), u = P(() => c.value.preset || "default"), g = P(() => h({
123
- theme: c.value,
124
- mode: s.value
121
+ setup(e, { emit: t }) {
122
+ let n = e, s = t, d = H("userSettingsStore", null), p = f(d), m = P(() => n.dashboard?.theme || {}), h = P(() => m.value.preset || "default"), g = P(() => a({
123
+ theme: m.value,
124
+ mode: p.value
125
125
  }).vars);
126
126
  function _(e) {
127
- return h({
127
+ return a({
128
128
  theme: { preset: e },
129
- mode: s.value
129
+ mode: p.value
130
130
  }).vars;
131
131
  }
132
- let v = P(() => Object.keys(c.value).length > 0);
132
+ let v = P(() => Object.keys(m.value).length > 0);
133
133
  function y(e) {
134
- a("theme-change", { preset: e });
134
+ s("theme-change", { preset: e });
135
135
  }
136
136
  function b(e, t) {
137
- a("theme-change", { [e]: t });
137
+ s("theme-change", { [e]: t });
138
138
  }
139
139
  function x(e) {
140
- a("theme-change", { mobileCards: e });
140
+ s("theme-change", { mobileCards: e });
141
141
  }
142
142
  function S() {
143
- a("theme-change", null);
143
+ s("theme-change", null);
144
144
  }
145
145
  let C = G({}), w = G({});
146
- X([() => r.isOpen, c], ([e]) => {
146
+ X([() => n.isOpen, m], ([e]) => {
147
147
  if (!e) return;
148
148
  let t = {};
149
- for (let e of l) t[e.key] = c.value[e.key] || "";
149
+ for (let e of l) t[e.key] = m.value[e.key] || "";
150
150
  C.value = t, w.value = {};
151
151
  }, { immediate: !0 });
152
- function ee(e) {
153
- let t = c.value[e];
154
- return t && /^#[0-9a-f]{6}$/i.test(t) ? t : l.find((t) => t.key === e).placeholder[s.value];
155
- }
156
152
  function T(e) {
153
+ let t = m.value[e];
154
+ return t && /^#[0-9a-f]{6}$/i.test(t) ? t : l.find((t) => t.key === e).placeholder[p.value];
155
+ }
156
+ function E(e) {
157
157
  let t = (C.value[e] || "").trim();
158
158
  if (t === "") {
159
159
  w.value = {
160
160
  ...w.value,
161
161
  [e]: !1
162
- }, c.value[e] && a("theme-change", { [e]: void 0 });
162
+ }, m.value[e] && s("theme-change", { [e]: void 0 });
163
163
  return;
164
164
  }
165
- if (!f(t)) {
165
+ if (!i(t)) {
166
166
  w.value = {
167
167
  ...w.value,
168
168
  [e]: !0
@@ -172,9 +172,9 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
172
172
  w.value = {
173
173
  ...w.value,
174
174
  [e]: !1
175
- }, a("theme-change", { [e]: t });
175
+ }, s("theme-change", { [e]: t });
176
176
  }
177
- function E(e, t) {
177
+ function D(e, t) {
178
178
  let n = t.target.value;
179
179
  C.value = {
180
180
  ...C.value,
@@ -182,24 +182,24 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
182
182
  }, w.value = {
183
183
  ...w.value,
184
184
  [e]: !1
185
- }, a("theme-change", { [e]: n });
185
+ }, s("theme-change", { [e]: n });
186
186
  }
187
- function te(e) {
187
+ function ee(e) {
188
188
  C.value = {
189
189
  ...C.value,
190
190
  [e]: ""
191
191
  }, w.value = {
192
192
  ...w.value,
193
193
  [e]: !1
194
- }, a("theme-change", { [e]: void 0 });
194
+ }, s("theme-change", { [e]: void 0 });
195
195
  }
196
- let D = l, O = d, ne = i, re = m, ie = p;
197
- return (t, n) => (W(), F(A, {
196
+ let O = l, k = o, te = u, ne = c, re = r;
197
+ return (t, n) => (W(), F(se, {
198
198
  show: e.isOpen,
199
199
  title: "Dashboard theme",
200
200
  "max-width": "640px",
201
201
  "test-id": "dashboard-theme-popup",
202
- onClose: n[7] ||= (e) => a("close")
202
+ onClose: n[7] ||= (e) => s("close")
203
203
  }, {
204
204
  footer: Z(() => [R("button", {
205
205
  type: "button",
@@ -211,7 +211,7 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
211
211
  type: "button",
212
212
  class: "btn btn-done",
213
213
  "data-testid": "theme-done-button",
214
- onClick: n[6] ||= (e) => a("close")
214
+ onClick: n[6] ||= (e) => s("close")
215
215
  }, " Done ")]),
216
216
  default: Z(() => [R("div", Re, [
217
217
  n[20] ||= R("p", { class: "picker-intro" }, [
@@ -219,12 +219,12 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
219
219
  R("strong", null, "Auto"),
220
220
  z(" follows the preset, and colors left blank follow your light/dark setting. ")
221
221
  ], -1),
222
- R("section", ze, [n[9] ||= R("h4", { class: "section-title" }, "Preset", -1), R("div", Be, [(W(!0), L(N, null, K(Y(O), (e) => (W(), L("button", {
222
+ R("section", ze, [n[9] ||= R("h4", { class: "section-title" }, "Preset", -1), R("div", Be, [(W(!0), L(N, null, K(Y(k), (e) => (W(), L("button", {
223
223
  key: e.value,
224
224
  type: "button",
225
- class: U(["preset-card", { selected: u.value === e.value }]),
225
+ class: U(["preset-card", { selected: h.value === e.value }]),
226
226
  "data-testid": `theme-preset-${e.value}`,
227
- "aria-pressed": u.value === e.value,
227
+ "aria-pressed": h.value === e.value,
228
228
  onClick: (t) => y(e.value)
229
229
  }, [
230
230
  R("span", {
@@ -239,52 +239,52 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
239
239
  n[14] ||= R("h4", { class: "section-title" }, "Adjustments", -1),
240
240
  R("div", Ge, [n[10] ||= R("span", { class: "knob-label" }, "Corners", -1), R("div", Ke, [R("button", {
241
241
  type: "button",
242
- class: U(["chip", { selected: !c.value.corners }]),
242
+ class: U(["chip", { selected: !m.value.corners }]),
243
243
  onClick: n[0] ||= (e) => b("corners", void 0)
244
- }, " Auto ", 2), (W(!0), L(N, null, K(Y(ne), (e) => (W(), L("button", {
244
+ }, " Auto ", 2), (W(!0), L(N, null, K(Y(te), (e) => (W(), L("button", {
245
245
  key: e.value,
246
246
  type: "button",
247
- class: U(["chip", { selected: c.value.corners === e.value }]),
247
+ class: U(["chip", { selected: m.value.corners === e.value }]),
248
248
  title: e.hint,
249
249
  onClick: (t) => b("corners", e.value)
250
250
  }, J(e.label), 11, qe))), 128))])]),
251
251
  R("div", Je, [n[11] ||= R("span", { class: "knob-label" }, "Density", -1), R("div", Ye, [R("button", {
252
252
  type: "button",
253
- class: U(["chip", { selected: !c.value.density }]),
253
+ class: U(["chip", { selected: !m.value.density }]),
254
254
  onClick: n[1] ||= (e) => b("density", void 0)
255
- }, " Auto ", 2), (W(!0), L(N, null, K(Y(re), (e) => (W(), L("button", {
255
+ }, " Auto ", 2), (W(!0), L(N, null, K(Y(ne), (e) => (W(), L("button", {
256
256
  key: e.value,
257
257
  type: "button",
258
- class: U(["chip", { selected: c.value.density === e.value }]),
258
+ class: U(["chip", { selected: m.value.density === e.value }]),
259
259
  title: e.hint,
260
260
  onClick: (t) => b("density", e.value)
261
261
  }, J(e.label), 11, Xe))), 128))])]),
262
262
  R("div", Ze, [n[12] ||= R("span", { class: "knob-label" }, "Elevation", -1), R("div", Qe, [R("button", {
263
263
  type: "button",
264
- class: U(["chip", { selected: !c.value.elevation }]),
264
+ class: U(["chip", { selected: !m.value.elevation }]),
265
265
  onClick: n[2] ||= (e) => b("elevation", void 0)
266
- }, " Auto ", 2), (W(!0), L(N, null, K(Y(ie), (e) => (W(), L("button", {
266
+ }, " Auto ", 2), (W(!0), L(N, null, K(Y(re), (e) => (W(), L("button", {
267
267
  key: e.value,
268
268
  type: "button",
269
- class: U(["chip", { selected: c.value.elevation === e.value }]),
269
+ class: U(["chip", { selected: m.value.elevation === e.value }]),
270
270
  title: e.hint,
271
271
  onClick: (t) => b("elevation", e.value)
272
272
  }, J(e.label), 11, $e))), 128))])]),
273
273
  R("div", et, [n[13] ||= R("span", { class: "knob-label" }, "On mobile", -1), R("div", tt, [
274
274
  R("button", {
275
275
  type: "button",
276
- class: U(["chip", { selected: c.value.mobileCards === void 0 }]),
276
+ class: U(["chip", { selected: m.value.mobileCards === void 0 }]),
277
277
  onClick: n[3] ||= (e) => x(void 0)
278
278
  }, " Auto ", 2),
279
279
  R("button", {
280
280
  type: "button",
281
- class: U(["chip", { selected: c.value.mobileCards === !1 }]),
281
+ class: U(["chip", { selected: m.value.mobileCards === !1 }]),
282
282
  title: "Panels flatten to the page background below 768px.",
283
283
  onClick: n[4] ||= (e) => x(!1)
284
284
  }, " Flatten ", 2),
285
285
  R("button", {
286
286
  type: "button",
287
- class: U(["chip", { selected: c.value.mobileCards === !0 }]),
287
+ class: U(["chip", { selected: m.value.mobileCards === !0 }]),
288
288
  title: "Panels keep their card treatment on narrow screens.",
289
289
  onClick: n[5] ||= (e) => x(!0)
290
290
  }, " Keep cards ", 2)
@@ -293,7 +293,7 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
293
293
  R("section", nt, [
294
294
  n[16] ||= R("h4", { class: "section-title" }, "Colors", -1),
295
295
  n[17] ||= R("p", { class: "section-note" }, " A color you set applies in both light and dark mode. Set them as a group so text stays readable, or leave them blank to follow the app theme. ", -1),
296
- R("div", rt, [(W(!0), L(N, null, K(Y(D), (e) => (W(), L("div", {
296
+ R("div", rt, [(W(!0), L(N, null, K(Y(O), (e) => (W(), L("div", {
297
297
  key: e.key,
298
298
  class: "color-row"
299
299
  }, [R("label", {
@@ -302,10 +302,10 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
302
302
  }, [R("span", at, J(e.label), 1), R("span", ot, J(e.hint), 1)], 8, it), R("div", st, [
303
303
  R("input", {
304
304
  type: "color",
305
- class: U(["color-swatch", { unset: !c.value[e.key] }]),
306
- value: ee(e.key),
305
+ class: U(["color-swatch", { unset: !m.value[e.key] }]),
306
+ value: T(e.key),
307
307
  "aria-label": `${e.label} color`,
308
- onInput: (t) => E(e.key, t)
308
+ onInput: (t) => D(e.key, t)
309
309
  }, null, 42, ct),
310
310
  je(R("input", {
311
311
  id: `theme-color-${e.key}`,
@@ -315,16 +315,16 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
315
315
  "data-testid": `theme-color-${e.key}`,
316
316
  placeholder: "Inherited",
317
317
  spellcheck: "false",
318
- onBlur: (t) => T(e.key),
319
- onKeyup: Me((t) => T(e.key), ["enter"])
318
+ onBlur: (t) => E(e.key),
319
+ onKeyup: Me((t) => E(e.key), ["enter"])
320
320
  }, null, 42, lt), [[ke, C.value[e.key]]]),
321
321
  R("button", {
322
322
  type: "button",
323
323
  class: "color-clear",
324
- disabled: !c.value[e.key],
324
+ disabled: !m.value[e.key],
325
325
  title: "Clear — follow the app theme",
326
326
  "aria-label": "Clear color",
327
- onClick: (t) => te(e.key)
327
+ onClick: (t) => ee(e.key)
328
328
  }, [...n[15] ||= [R("i", {
329
329
  class: "mdi mdi-close",
330
330
  "aria-hidden": "true"
@@ -339,7 +339,7 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
339
339
  _: 1
340
340
  }, 8, ["show"]));
341
341
  }
342
- }), [["__scopeId", "data-v-2a56fa57"]]), mt = ["onClick"], ht = { class: "completion-details" }, gt = { class: "completion-label" }, _t = { class: "completion-description" }, vt = /*#__PURE__*/ e(/* @__PURE__ */ V({
342
+ }), [["__scopeId", "data-v-2a56fa57"]]), mt = ["onClick"], ht = { class: "completion-details" }, gt = { class: "completion-label" }, _t = { class: "completion-description" }, vt = /*#__PURE__*/ d(/* @__PURE__ */ V({
343
343
  __name: "DashboardFilterAutocomplete",
344
344
  props: {
345
345
  inputValue: {
@@ -432,7 +432,7 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
432
432
  }, jt = ["disabled"], Mt = { class: "button-content" }, Nt = ["disabled"], Pt = { class: "button-content" }, Ft = {
433
433
  key: 0,
434
434
  class: "loader-container"
435
- }, It = ["disabled"], Lt = { class: "button-content" }, Rt = /*#__PURE__*/ e(/* @__PURE__ */ V({
435
+ }, It = ["disabled"], Lt = { class: "button-content" }, Rt = /*#__PURE__*/ d(/* @__PURE__ */ V({
436
436
  __name: "DashboardHeaderFilterInput",
437
437
  props: {
438
438
  filterValue: {
@@ -456,9 +456,9 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
456
456
  "clear-filter"
457
457
  ],
458
458
  setup(e, { emit: t }) {
459
- let n = e, r = t, i = v(), a = G(n.isLoading), o = G(null), s = G(null), c = G(null), l = G(n.filterValue || ""), u = G(!1), d = G(!1), f = P(() => l.value.replace(/\n/g, " ")), p = P(() => l.value.trim().length > 0);
459
+ let n = e, r = t, i = ne(), a = G(n.isLoading), o = G(null), s = G(null), c = G(null), l = G(n.filterValue || ""), u = G(!1), d = G(!1), f = P(() => l.value.replace(/\n/g, " ")), p = P(() => l.value.trim().length > 0);
460
460
  function m() {
461
- r("filter-apply", l.value), u.value = !1, y();
461
+ r("filter-apply", l.value), u.value = !1, v();
462
462
  }
463
463
  function h() {
464
464
  l.value = "", u.value = !0, r("filter-change", ""), r("filter-apply", ""), r("clear-filter", ""), setTimeout(() => {
@@ -478,10 +478,10 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
478
478
  }
479
479
  }, 0);
480
480
  }
481
- function y() {
481
+ function v() {
482
482
  d.value = !1;
483
483
  }
484
- let b = () => {
484
+ let y = () => {
485
485
  a.value = !0;
486
486
  let e = n.globalCompletion.map((e) => ({
487
487
  name: e.label,
@@ -494,14 +494,14 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
494
494
  a.value = !1;
495
495
  });
496
496
  };
497
- function x(e) {
498
- e.key === "Enter" && !e.shiftKey && !e.ctrlKey && !e.altKey ? d.value || (e.preventDefault(), m()) : (e.ctrlKey || e.metaKey) && e.shiftKey && e.key === "Enter" ? (e.preventDefault(), b()) : e.key === "Escape" && d.value && (e.preventDefault(), y());
497
+ function b(e) {
498
+ e.key === "Enter" && !e.shiftKey && !e.ctrlKey && !e.altKey ? d.value || (e.preventDefault(), m()) : (e.ctrlKey || e.metaKey) && e.shiftKey && e.key === "Enter" ? (e.preventDefault(), y()) : e.key === "Escape" && d.value && (e.preventDefault(), v());
499
499
  }
500
- function S(e) {
501
- (e.ctrlKey || e.metaKey) && e.key === "Enter" && !e.shiftKey ? (e.preventDefault(), m()) : (e.ctrlKey || e.metaKey) && e.shiftKey && e.key === "Enter" ? (e.preventDefault(), b()) : e.key === "Escape" && (e.preventDefault(), y());
500
+ function x(e) {
501
+ (e.ctrlKey || e.metaKey) && e.key === "Enter" && !e.shiftKey ? (e.preventDefault(), m()) : (e.ctrlKey || e.metaKey) && e.shiftKey && e.key === "Enter" ? (e.preventDefault(), y()) : e.key === "Escape" && (e.preventDefault(), v());
502
502
  }
503
- let C = P(() => (n.filterError || "").length > 0 ? "error" : l.value ? "valid" : "neutral");
504
- function w(e) {
503
+ let S = P(() => (n.filterError || "").length > 0 ? "error" : l.value ? "valid" : "neutral");
504
+ function C(e) {
505
505
  l.value = e.text, u.value = !0, r("filter-change", l.value);
506
506
  let t = d.value ? s.value : o.value;
507
507
  t && (t.focus(), t.setSelectionRange(e.cursorPosition, e.cursorPosition));
@@ -511,7 +511,7 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
511
511
  }), X(() => n.isLoading, (e) => {
512
512
  a.value = e;
513
513
  }), ae(() => [c.value, o.value], () => {
514
- y();
514
+ v();
515
515
  }, { enabled: () => d.value }), (t, n) => (W(), L("div", yt, [R("div", bt, [
516
516
  R("input", {
517
517
  id: "filter",
@@ -521,10 +521,10 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
521
521
  type: "text",
522
522
  value: f.value,
523
523
  onInput: g,
524
- onKeydown: x,
524
+ onKeydown: b,
525
525
  onFocus: _,
526
526
  placeholder: "Add a global filter...",
527
- class: U({ "filter-error": C.value === "error" }),
527
+ class: U({ "filter-error": S.value === "error" }),
528
528
  disabled: a.value
529
529
  }, null, 42, xt),
530
530
  d.value ? (W(), L("div", {
@@ -534,17 +534,17 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
534
534
  class: "filter-dropdown"
535
535
  }, [
536
536
  R("div", { class: "dropdown-header" }, [n[1] ||= R("span", null, "Global Filters", -1), R("button", {
537
- onClick: y,
537
+ onClick: v,
538
538
  class: "close-button",
539
539
  title: "Close (Esc)"
540
540
  }, [...n[0] ||= [R("i", { class: "mdi mdi-close" }, null, -1)]])]),
541
541
  R("textarea", {
542
542
  ref_key: "filterTextareaRef",
543
543
  ref: s,
544
- class: U(["filter-textarea", { "filter-error": C.value === "error" }]),
544
+ class: U(["filter-textarea", { "filter-error": S.value === "error" }]),
545
545
  value: l.value,
546
546
  onInput: g,
547
- onKeydown: S,
547
+ onKeydown: x,
548
548
  placeholder: Y(i).hasActiveDefaultConnection ? "Use a SQL condition (ex color='blue' or color='red') or text to filter.\nUse Ctrl+Enter to apply, Ctrl+Shift+Enter for text to SQL" : "Use a SQL condition (ex color='blue') to filter.\nUse Ctrl+Enter to apply",
549
549
  disabled: a.value,
550
550
  rows: "4"
@@ -559,7 +559,7 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
559
559
  }, [...n[3] ||= [R("i", { class: "mdi mdi-check" }, null, -1), z(" Apply ", -1)]], 10, Tt),
560
560
  Y(i).hasActiveDefaultConnection ? (W(), L("button", {
561
561
  key: 0,
562
- onClick: b,
562
+ onClick: y,
563
563
  class: "llm-button",
564
564
  disabled: a.value,
565
565
  title: "Text to filter (Ctrl+Shift+Enter)"
@@ -581,14 +581,14 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
581
581
  "input-value": l.value,
582
582
  "completion-items": e.globalCompletion,
583
583
  "input-element": d.value ? s.value : o.value,
584
- onSelectCompletion: w
584
+ onSelectCompletion: C
585
585
  }, null, 8, [
586
586
  "input-value",
587
587
  "completion-items",
588
588
  "input-element"
589
589
  ])) : I("", !0),
590
590
  R("div", kt, [
591
- C.value === "error" ? (W(), L("div", At, [n[8] ||= R("i", { class: "mdi mdi-alert-circle-outline" }, null, -1), B(k, {
591
+ S.value === "error" ? (W(), L("div", At, [n[8] ||= R("i", { class: "mdi mdi-alert-circle-outline" }, null, -1), B(A, {
592
592
  content: e.filterError || "Unknown Error",
593
593
  position: "bottom"
594
594
  }, {
@@ -604,7 +604,7 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
604
604
  "data-testid": "filter-search-button",
605
605
  disabled: a.value,
606
606
  title: "Apply filter (Enter)"
607
- }, [R("div", Mt, [n[10] ||= R("i", { class: "mdi mdi-magnify" }, null, -1), B(k, {
607
+ }, [R("div", Mt, [n[10] ||= R("i", { class: "mdi mdi-magnify" }, null, -1), B(A, {
608
608
  content: u.value ? "Apply changes (Enter)" : "Search (Enter)",
609
609
  position: "top"
610
610
  }, {
@@ -613,7 +613,7 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
613
613
  }, 8, ["content"])])], 10, jt),
614
614
  Y(i).hasActiveDefaultConnection ? (W(), L("button", {
615
615
  key: 1,
616
- onClick: b,
616
+ onClick: y,
617
617
  class: "input-icon-button",
618
618
  "data-testid": "filter-llm-button",
619
619
  disabled: a.value,
@@ -621,7 +621,7 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
621
621
  }, [R("div", Pt, [
622
622
  R("i", { class: U(["mdi mdi-auto-fix", { hidden: a.value }]) }, null, 2),
623
623
  a.value ? (W(), L("div", Ft, [...n[11] ||= [R("div", { class: "loader" }, null, -1)]])) : I("", !0),
624
- B(k, {
624
+ B(A, {
625
625
  content: a.value ? "Processing..." : "Text to filter (Ctrl+Shift+Enter)",
626
626
  position: "top"
627
627
  }, {
@@ -636,7 +636,7 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
636
636
  "data-testid": "clear-filters-button",
637
637
  disabled: a.value,
638
638
  title: "Clear all filters"
639
- }, [R("div", Lt, [n[14] ||= R("i", { class: "mdi mdi-close" }, null, -1), B(k, {
639
+ }, [R("div", Lt, [n[14] ||= R("i", { class: "mdi mdi-close" }, null, -1), B(A, {
640
640
  content: "Clear all filters",
641
641
  position: "top"
642
642
  }, {
@@ -665,7 +665,7 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
665
665
  }, Gt = { class: "select-wrapper" }, Kt = ["value", "title"], qt = ["value"], Jt = ["value"], Yt = { class: "grid-actions top-actions" }, Xt = { class: "controls-row filter-row" }, Zt = { class: "grid-actions filter-actions" }, Qt = ["disabled", "title"], $t = { class: "filter-action-label" }, en = {
666
666
  class: "mode-selector",
667
667
  "data-testid": "mode-selector-wrapper"
668
- }, tn = { class: "select-wrapper" }, nn = ["value", "disabled"], rn = /*#__PURE__*/ e(/* @__PURE__ */ V({
668
+ }, tn = { class: "select-wrapper" }, nn = ["value", "disabled"], rn = /*#__PURE__*/ d(/* @__PURE__ */ V({
669
669
  __name: "DashboardHeader",
670
670
  props: {
671
671
  dashboard: {
@@ -716,14 +716,14 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
716
716
  "theme-change"
717
717
  ],
718
718
  setup(e, { emit: t }) {
719
- let n = e, r = t, i = b(), a = re(), o = g(), s = G(!1), c = G(!1), l = G(!1), u = G(!1), d = G(""), f = G(null);
719
+ let n = e, r = t, i = h(), a = ee(), o = k(), s = G(!1), c = G(!1), l = G(!1), u = G(!1), d = G(""), f = G(null);
720
720
  function p() {
721
721
  c.value = !c.value;
722
722
  }
723
723
  function m() {
724
724
  c.value = !1;
725
725
  }
726
- function h() {
726
+ function g() {
727
727
  l.value = !l.value;
728
728
  }
729
729
  function _(e) {
@@ -740,35 +740,35 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
740
740
  let t = e.target;
741
741
  r("mode-change", t.value);
742
742
  }
743
- function x() {
743
+ function b() {
744
744
  n.editsLocked || (u.value = !0, d.value = n.dashboard?.name || "Untitled Dashboard", setTimeout(() => {
745
745
  f.value?.focus();
746
746
  }, 0));
747
747
  }
748
- function S() {
748
+ function x() {
749
749
  u.value = !1, r("title-update", d.value);
750
750
  }
751
- function C() {
751
+ function S() {
752
752
  u.value = !1, d.value = n.dashboard?.name || "Untitled Dashboard";
753
753
  }
754
- let w = P(() => n.selectedConnection ? i.connections[n.selectedConnection] || i.connectionByName(n.selectedConnection) : void 0), ee = P(() => {
754
+ let w = P(() => n.selectedConnection ? i.connections[n.selectedConnection] || i.connectionByName(n.selectedConnection) : void 0), T = P(() => {
755
755
  let e = Object.values(i.connections).filter((e) => e.model && !e.deleted), t = w.value;
756
756
  return t && !e.some((e) => e.id === t.id) && e.push(t), e.sort((e, t) => e.name.localeCompare(t.name));
757
- }), T = P(() => w.value?.id || n.selectedConnection), E = P(() => !!n.selectedConnection && !w.value), D = P(() => w.value?.name || n.selectedConnection), O = P(() => {
757
+ }), E = P(() => w.value?.id || n.selectedConnection), D = P(() => !!n.selectedConnection && !w.value), O = P(() => w.value?.name || n.selectedConnection), te = P(() => {
758
758
  let e = w.value;
759
- return e ? Object.values(a.editors).filter((t) => te(t.type) && t.connectionId === e.id).sort((e, t) => e.name.localeCompare(t.name)).map((e) => ({
759
+ return e ? Object.values(a.editors).filter((t) => C(t.type) && t.connectionId === e.id).sort((e, t) => e.name.localeCompare(t.name)).map((e) => ({
760
760
  id: e.id,
761
761
  name: e.name.replace(/\//g, "."),
762
762
  alias: ""
763
763
  })) : [];
764
764
  }), ne = P(() => n.dashboard?.imports || []);
765
- function ie(e) {
765
+ function re(e) {
766
766
  r("import-change", e);
767
767
  }
768
- function ae() {
768
+ function ie() {
769
769
  r("refresh");
770
770
  }
771
- let k = P(() => {
771
+ let ae = P(() => {
772
772
  switch (n.dashboard?.state) {
773
773
  case "editing": return "mdi mdi-pencil-outline";
774
774
  case "published": return "mdi mdi-eye-outline";
@@ -779,15 +779,15 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
779
779
  return (t, n) => (W(), L("div", zt, [
780
780
  R("div", { class: U(["controls-row title-row", { "view-title-row": e.dashboard.state !== "editing" }]) }, [R("div", {
781
781
  class: "dashboard-title",
782
- onClick: x
782
+ onClick: b
783
783
  }, [u.value ? je((W(), L("input", {
784
784
  key: 1,
785
785
  ref_key: "titleInput",
786
786
  ref: f,
787
787
  "data-testid": "dashboard-title-input",
788
788
  "onUpdate:modelValue": n[0] ||= (e) => d.value = e,
789
- onBlur: S,
790
- onKeyup: [Me(S, ["enter"]), Me(C, ["esc"])],
789
+ onBlur: x,
790
+ onKeyup: [Me(x, ["enter"]), Me(S, ["esc"])],
791
791
  class: "title-input",
792
792
  type: "text"
793
793
  }, null, 544)), [[ke, d.value]]) : (W(), L("span", Bt, [R("span", Vt, J(e.dashboard?.name || "Untitled Dashboard"), 1), e.editsLocked ? I("", !0) : (W(), L("span", Ht, [...n[11] ||= [R("i", { class: "mdi mdi-pencil-outline" }, null, -1)]]))]))]), e.dashboard.state === "editing" ? (W(), L("div", Ut, [
@@ -795,20 +795,20 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
795
795
  id: "connection",
796
796
  "data-testid": "connection-selector",
797
797
  onChange: n[1] ||= (e) => t.$emit("connection-change", e),
798
- value: T.value,
799
- title: D.value
800
- }, [E.value ? (W(), L("option", {
798
+ value: E.value,
799
+ title: O.value
800
+ }, [D.value ? (W(), L("option", {
801
801
  key: 0,
802
802
  value: e.selectedConnection,
803
803
  disabled: ""
804
- }, J(D.value) + " (unavailable) ", 9, qt)) : I("", !0), (W(!0), L(N, null, K(ee.value, (e) => (W(), L("option", {
804
+ }, J(O.value) + " (unavailable) ", 9, qt)) : I("", !0), (W(!0), L(N, null, K(T.value, (e) => (W(), L("option", {
805
805
  key: e.id,
806
806
  value: e.id
807
807
  }, J(e.name), 9, Jt))), 128))], 40, Kt)])]),
808
808
  B(oe, {
809
- "available-imports": O.value,
809
+ "available-imports": te.value,
810
810
  "active-imports": ne.value,
811
- "onUpdate:imports": ie,
811
+ "onUpdate:imports": re,
812
812
  onExplore: n[2] ||= (e) => Y(o).openTab("editors", null, e.id)
813
813
  }, null, 8, ["available-imports", "active-imports"]),
814
814
  R("div", Yt, [R("button", {
@@ -844,7 +844,7 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
844
844
  "global-completion",
845
845
  "validate-filter"
846
846
  ]), R("div", Zt, [
847
- B(ce, {
847
+ B(le, {
848
848
  action: v,
849
849
  "use-default-style": !1,
850
850
  class: "btn btn-secondary filter-action-btn dashboard-download-action",
@@ -861,7 +861,7 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
861
861
  }),
862
862
  e.editsLocked ? I("", !0) : (W(), L("button", {
863
863
  key: 0,
864
- onClick: h,
864
+ onClick: g,
865
865
  class: U(["btn filter-action-btn dashboard-theme-action", l.value ? "btn-primary" : "btn-secondary"]),
866
866
  "data-testid": "dashboard-theme-button",
867
867
  title: "Dashboard theme",
@@ -910,7 +910,7 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
910
910
  "aria-hidden": "true"
911
911
  }, null, -1), R("span", $t, J(e.chatOpen ? "Close AI" : "AI"), 1)], 10, Qt),
912
912
  R("button", {
913
- onClick: ae,
913
+ onClick: ie,
914
914
  class: "btn btn-primary filter-action-btn",
915
915
  "data-testid": "refresh-button",
916
916
  title: "Refresh dashboard",
@@ -919,7 +919,7 @@ var Pe = { class: "share-popup-body" }, Fe = { class: "json-container" }, Ie = {
919
919
  class: "mdi mdi-refresh filter-action-icon",
920
920
  "aria-hidden": "true"
921
921
  }, null, -1), R("span", { class: "filter-action-label" }, "Refresh", -1)]]),
922
- R("div", en, [R("div", tn, [R("i", { class: U(k.value + " select-icon") }, null, 2), R("select", {
922
+ R("div", en, [R("div", tn, [R("i", { class: U(ae.value + " select-icon") }, null, 2), R("select", {
923
923
  id: "viewMode",
924
924
  "data-testid": "mode-selector",
925
925
  onChange: y,
@@ -1025,7 +1025,7 @@ function an(e) {
1025
1025
  var on = V({
1026
1026
  name: "DashboardChart",
1027
1027
  components: {
1028
- VegaLiteChart: le,
1028
+ VegaLiteChart: ie,
1029
1029
  ErrorMessage: j,
1030
1030
  LoadingView: ue,
1031
1031
  DrilldownPane: de
@@ -1068,30 +1068,30 @@ var on = V({
1068
1068
  required: !0
1069
1069
  }
1070
1070
  },
1071
- setup(e, { emit: t }) {
1072
- let n = G(null), r = P(() => e.getItemData(e.itemId, e.dashboardId)), i = P(() => r.value.structured_content.query), a = P(() => r.value.results || null), o = P(() => r.value.name || ""), s = P(() => (r.value.height || 300) - 75), l = P(() => r.value.width || 300), u = P(() => {
1073
- if (r.value.chartConfig) return {
1074
- ...r.value.chartConfig,
1071
+ setup(t, { emit: n }) {
1072
+ let r = G(null), i = P(() => t.getItemData(t.itemId, t.dashboardId)), a = P(() => i.value.structured_content.query), o = P(() => i.value.results || null), s = P(() => i.value.name || ""), c = P(() => (i.value.height || 300) - 75), l = P(() => i.value.width || 300), u = P(() => {
1073
+ if (i.value.chartConfig) return {
1074
+ ...i.value.chartConfig,
1075
1075
  showTitle: !1
1076
1076
  };
1077
- }), d = P(() => r.value.loading || !1), f = P(() => r.value.error || null), p = P(() => r.value.filters || []), m = P(() => r.value.loadStartTime || null), h = P(() => (r.value.chartFilters || []).map((e) => e.value)), g = P(() => r.value.hasDrilldown), _ = P(() => r.value.onRefresh || null), v = H("analyticsStore", null), y = (t) => {
1077
+ }), d = P(() => i.value.loading || !1), f = P(() => i.value.error || null), p = P(() => i.value.filters || []), m = P(() => i.value.loadStartTime || null), h = P(() => (i.value.chartFilters || []).map((e) => e.value)), g = P(() => i.value.hasDrilldown), _ = P(() => i.value.onRefresh || null), v = H("analyticsStore", null), y = (e) => {
1078
1078
  let n = {
1079
- ...t,
1079
+ ...e,
1080
1080
  showTitle: !1
1081
1081
  };
1082
1082
  if (g.value) {
1083
- e.setItemData(e.itemId, e.dashboardId, { drilldownChartConfig: n });
1083
+ t.setItemData(t.itemId, t.dashboardId, { drilldownChartConfig: n });
1084
1084
  return;
1085
1085
  }
1086
- e.setItemData(e.itemId, e.dashboardId, { chartConfig: n });
1087
- }, { chartContainer: b, ready: x, showLoading: S, controlsVisible: C, executeQuery: w, handleLocalRefresh: ee, onChartMouseEnter: T, onChartMouseLeave: E } = an({
1088
- dashboardId: () => e.dashboardId,
1089
- itemId: () => e.itemId,
1090
- query: i,
1091
- results: a,
1086
+ t.setItemData(t.itemId, t.dashboardId, { chartConfig: n });
1087
+ }, { chartContainer: b, ready: x, showLoading: S, controlsVisible: C, executeQuery: w, handleLocalRefresh: T, onChartMouseEnter: E, onChartMouseLeave: D } = an({
1088
+ dashboardId: () => t.dashboardId,
1089
+ itemId: () => t.itemId,
1090
+ query: a,
1091
+ results: o,
1092
1092
  loading: d,
1093
1093
  onRefresh: _,
1094
- getDashboardQueryExecutor: e.getDashboardQueryExecutor,
1094
+ getDashboardQueryExecutor: t.getDashboardQueryExecutor,
1095
1095
  analyticsStore: v,
1096
1096
  analyticsEvent: "dashboard-chart-execution",
1097
1097
  analyticsType: "CHART",
@@ -1099,51 +1099,51 @@ var on = V({
1099
1099
  });
1100
1100
  return {
1101
1101
  chartContainer: b,
1102
- results: a,
1102
+ results: o,
1103
1103
  ready: x,
1104
1104
  loading: d,
1105
1105
  showLoading: S,
1106
1106
  error: f,
1107
1107
  filters: p,
1108
- query: i,
1109
- chartHeight: s,
1108
+ query: a,
1109
+ chartHeight: c,
1110
1110
  chartWidth: l,
1111
1111
  chartConfig: u,
1112
- chartTitle: o,
1112
+ chartTitle: s,
1113
1113
  onChartConfigChange: y,
1114
1114
  onRefresh: _,
1115
- handleLocalRefresh: ee,
1115
+ handleLocalRefresh: T,
1116
1116
  chartSelection: h,
1117
1117
  startTime: m,
1118
- handleDimensionClick: (n) => {
1119
- t("dimension-click", {
1120
- source: e.itemId,
1121
- filters: n.filters,
1122
- chart: n.chart,
1123
- append: n.append
1118
+ handleDimensionClick: (e) => {
1119
+ n("dimension-click", {
1120
+ source: t.itemId,
1121
+ filters: e.filters,
1122
+ chart: e.chart,
1123
+ append: e.append
1124
1124
  });
1125
1125
  },
1126
1126
  handleBackgroundClick: () => {
1127
- t("background-click");
1127
+ n("background-click");
1128
1128
  },
1129
- activeDrilldown: n,
1130
- activateDrilldown: (e) => {
1131
- let t = e.filters, r = Object.keys(t)[0], i = c(e.filters);
1132
- r && (n.value = {
1133
- remove: r,
1134
- filter: i
1129
+ activeDrilldown: r,
1130
+ activateDrilldown: (t) => {
1131
+ let n = t.filters, i = Object.keys(n)[0], a = e(t.filters);
1132
+ i && (r.value = {
1133
+ remove: i,
1134
+ filter: a
1135
1135
  });
1136
1136
  },
1137
- submitDrilldown: async (t) => {
1138
- let a = await e.getDashboardQueryExecutor(e.dashboardId).createDrilldownQuery(i.value, t, n.value.remove, n.value.filter, r.value.rootContent || [], (r.value.imports || []).map((e) => ({
1137
+ submitDrilldown: async (e) => {
1138
+ let n = await t.getDashboardQueryExecutor(t.dashboardId).createDrilldownQuery(a.value, e, r.value.remove, r.value.filter, i.value.rootContent || [], (i.value.imports || []).map((e) => ({
1139
1139
  name: e.name,
1140
1140
  alias: e.alias
1141
1141
  })));
1142
- e.setItemData(e.itemId, e.dashboardId, {
1143
- drilldown: a,
1142
+ t.setItemData(t.itemId, t.dashboardId, {
1143
+ drilldown: n,
1144
1144
  drilldownChartConfig: null,
1145
1145
  loading: !0
1146
- }), S.value = !0, n.value = null, await w().then(() => {
1146
+ }), S.value = !0, r.value = null, await w().then(() => {
1147
1147
  x.value = !0;
1148
1148
  }).catch((e) => {
1149
1149
  console.error("Error executing drilldown query:", e), x.value = !0;
@@ -1152,10 +1152,10 @@ var on = V({
1152
1152
  });
1153
1153
  },
1154
1154
  controlsVisible: C,
1155
- onChartMouseEnter: T,
1156
- onChartMouseLeave: E,
1155
+ onChartMouseEnter: E,
1156
+ onChartMouseLeave: D,
1157
1157
  revertDrilldown: async () => {
1158
- e.setItemData(e.itemId, e.dashboardId, {
1158
+ t.setItemData(t.itemId, t.dashboardId, {
1159
1159
  drilldown: null,
1160
1160
  drilldownChartConfig: null,
1161
1161
  loading: !0
@@ -1255,7 +1255,7 @@ function cn(e, t, n, r, i, a) {
1255
1255
  }, [...t[6] ||= [R("i", { class: "mdi mdi-undo icon" }, null, -1)]])], 2)) : I("", !0)
1256
1256
  ], 34);
1257
1257
  }
1258
- var ln = /*#__PURE__*/ e(on, [["render", cn], ["__scopeId", "data-v-36046d80"]]), un = V({
1258
+ var ln = /*#__PURE__*/ d(on, [["render", cn], ["__scopeId", "data-v-36046d80"]]), un = V({
1259
1259
  name: "DynamicMarkdownChart",
1260
1260
  components: {
1261
1261
  ErrorMessage: j,
@@ -1374,10 +1374,10 @@ function dn(e, t, n, r, i, a) {
1374
1374
  title: "Refresh text"
1375
1375
  }, [...t[3] ||= [R("i", { class: "mdi mdi-refresh icon" }, null, -1)]])], 2)) : I("", !0)], 34);
1376
1376
  }
1377
- var fn = /*#__PURE__*/ e(un, [["render", dn], ["__scopeId", "data-v-ffafce48"]]), pn = V({
1377
+ var fn = /*#__PURE__*/ d(un, [["render", dn], ["__scopeId", "data-v-ffafce48"]]), pn = V({
1378
1378
  name: "DashboardTable",
1379
1379
  components: {
1380
- DataTable: se,
1380
+ DataTable: ce,
1381
1381
  ErrorMessage: j,
1382
1382
  LoadingView: ue
1383
1383
  },
@@ -1517,10 +1517,10 @@ function hn(e, t, n, r, i, a) {
1517
1517
  }, [...t[3] ||= [R("i", { class: "mdi mdi-refresh icon" }, null, -1)]])], 2)) : I("", !0)
1518
1518
  ], 34);
1519
1519
  }
1520
- var gn = /*#__PURE__*/ e(pn, [["render", hn], ["__scopeId", "data-v-2fa93a82"]]), _n = { class: "filter-tile" }, vn = ["title"], yn = ["disabled", "aria-expanded"], bn = ["title"], xn = { class: "dropdown-search" }, Sn = ["placeholder"], Cn = { class: "dropdown-scroll" }, wn = ["checked"], Tn = ["checked", "onChange"], En = ["innerHTML"], Dn = {
1520
+ var gn = /*#__PURE__*/ d(pn, [["render", hn], ["__scopeId", "data-v-2fa93a82"]]), _n = { class: "filter-tile" }, vn = ["title"], yn = ["disabled", "aria-expanded"], bn = ["title"], xn = { class: "dropdown-search" }, Sn = ["placeholder"], Cn = { class: "dropdown-scroll" }, wn = ["checked"], Tn = ["checked", "onChange"], En = ["innerHTML"], Dn = {
1521
1521
  key: 1,
1522
1522
  class: "dropdown-empty"
1523
- }, On = { class: "dropdown-footer" }, kn = /*#__PURE__*/ e(/* @__PURE__ */ V({
1523
+ }, On = { class: "dropdown-footer" }, kn = /*#__PURE__*/ d(/* @__PURE__ */ V({
1524
1524
  __name: "DashboardDataSelector",
1525
1525
  props: {
1526
1526
  headers: {
@@ -1547,28 +1547,28 @@ var gn = /*#__PURE__*/ e(pn, [["render", hn], ["__scopeId", "data-v-2fa93a82"]])
1547
1547
  },
1548
1548
  emits: ["cell-click", "background-click"],
1549
1549
  setup(e, { emit: t }) {
1550
- let r = e, i = t, a = G([...r.initialSelection ?? []]), o = G([]), s = G(""), c = G(!1), l = G(null), u = G(null), d = G(null), f = P(() => Array.from(r.headers.values())), p = P(() => f.value[0] || null), m = P(() => f.value[1] || f.value[0] || null);
1550
+ let n = e, r = t, i = G([...n.initialSelection ?? []]), a = G([]), o = G(""), s = G(!1), c = G(null), l = G(null), u = G(null), d = P(() => Array.from(n.headers.values())), f = P(() => d.value[0] || null), m = P(() => d.value[1] || d.value[0] || null);
1551
1551
  function h(e, t) {
1552
1552
  switch (t.type) {
1553
- case n.FLOAT: return t.traits?.includes("usd") ? `$${Number(e).toFixed(t.scale || 2)}` : t.traits?.includes("percent") ? `${(Number(e) * 100).toFixed(2)}%` : Number(e).toFixed(t.scale || 2);
1554
- case n.DATETIME:
1555
- case n.TIMESTAMP:
1556
- case n.DATE:
1557
- case n.TIME: return e instanceof Date ? e.toLocaleString() : String(e);
1558
- case n.BOOLEAN: return e ? "✓" : "✗";
1559
- case n.ARRAY:
1560
- case n.STRUCT: return JSON.stringify(e);
1553
+ case p.FLOAT: return t.traits?.includes("usd") ? `$${Number(e).toFixed(t.scale || 2)}` : t.traits?.includes("percent") ? `${(Number(e) * 100).toFixed(2)}%` : Number(e).toFixed(t.scale || 2);
1554
+ case p.DATETIME:
1555
+ case p.TIMESTAMP:
1556
+ case p.DATE:
1557
+ case p.TIME: return e instanceof Date ? e.toLocaleString() : String(e);
1558
+ case p.BOOLEAN: return e ? "✓" : "✗";
1559
+ case p.ARRAY:
1560
+ case p.STRUCT: return JSON.stringify(e);
1561
1561
  default: return String(e);
1562
1562
  }
1563
1563
  }
1564
1564
  let g = P(() => {
1565
- let e = p.value, t = m.value;
1566
- if (!e || !t || !r.results || r.results.length === 0) return [];
1567
- let n = e.name, i = t.name, a = [];
1568
- for (let t of r.results) {
1569
- let r = t[n], o = t[i];
1570
- r != null && o != null && a.push({
1571
- label: h(r, e),
1565
+ let e = f.value, t = m.value;
1566
+ if (!e || !t || !n.results || n.results.length === 0) return [];
1567
+ let r = e.name, i = t.name, a = [];
1568
+ for (let t of n.results) {
1569
+ let n = t[r], o = t[i];
1570
+ n != null && o != null && a.push({
1571
+ label: h(n, e),
1572
1572
  value: o
1573
1573
  });
1574
1574
  }
@@ -1578,17 +1578,17 @@ var gn = /*#__PURE__*/ e(pn, [["render", hn], ["__scopeId", "data-v-2fa93a82"]])
1578
1578
  for (let t of g.value) e.set(t.value, t.label);
1579
1579
  return e;
1580
1580
  }), v = P(() => {
1581
- if (!s.value) return g.value;
1582
- let e = s.value.toLowerCase();
1581
+ if (!o.value) return g.value;
1582
+ let e = o.value.toLowerCase();
1583
1583
  return g.value.filter((t) => t.label.toLowerCase().includes(e));
1584
- }), y = P(() => p.value?.name || "Field"), b = P(() => a.value.length > 0), x = P(() => !g.value || g.value.length === 0 ? "No data available" : a.value.length === 0 ? `All (${g.value.length})` : a.value.length === 1 ? _.value.get(a.value[0]) ?? String(a.value[0]) : `${_.value.get(a.value[0]) ?? String(a.value[0])} +${a.value.length - 1}`), S = P(() => !g.value || g.value.length === 0), C = P(() => v.value.length > 0 && v.value.every((e) => o.value.includes(e.value))), w = G({});
1585
- function ee() {
1586
- let e = l.value;
1584
+ }), y = P(() => f.value?.name || "Field"), b = P(() => i.value.length > 0), x = P(() => !g.value || g.value.length === 0 ? "No data available" : i.value.length === 0 ? `All (${g.value.length})` : i.value.length === 1 ? _.value.get(i.value[0]) ?? String(i.value[0]) : `${_.value.get(i.value[0]) ?? String(i.value[0])} +${i.value.length - 1}`), S = P(() => !g.value || g.value.length === 0), C = P(() => v.value.length > 0 && v.value.every((e) => a.value.includes(e.value))), w = G({});
1585
+ function T() {
1586
+ let e = c.value;
1587
1587
  if (!e) {
1588
1588
  w.value = {};
1589
1589
  return;
1590
1590
  }
1591
- let t = e.getBoundingClientRect(), n = window.visualViewport, r = n?.offsetLeft ?? 0, i = n?.offsetTop ?? 0, a = n?.width ?? window.innerWidth, o = n?.height ?? window.innerHeight, s = r + a, c = i + o, u = Math.min(Math.max(t.width, 220), Math.max(0, a - 16)), d = Math.min(Math.max(t.left, r + 8), Math.max(r + 8, s - u - 8)), f = c - t.bottom - 4 - 8, p = t.top - i - 4 - 8, m = f < 240 && p > f, h = Math.min(360, Math.max(96, m ? p : f)), g = m ? Math.max(i + 8, t.top - 4 - h) : Math.max(i + 8, t.bottom + 4);
1591
+ let t = e.getBoundingClientRect(), n = window.visualViewport, r = n?.offsetLeft ?? 0, i = n?.offsetTop ?? 0, a = n?.width ?? window.innerWidth, o = n?.height ?? window.innerHeight, s = r + a, l = i + o, u = Math.min(Math.max(t.width, 220), Math.max(0, a - 16)), d = Math.min(Math.max(t.left, r + 8), Math.max(r + 8, s - u - 8)), f = l - t.bottom - 4 - 8, p = t.top - i - 4 - 8, m = f < 240 && p > f, h = Math.min(360, Math.max(96, m ? p : f)), g = m ? Math.max(i + 8, t.top - 4 - h) : Math.max(i + 8, t.bottom + 4);
1592
1592
  w.value = {
1593
1593
  position: "fixed",
1594
1594
  top: `${g}px`,
@@ -1598,49 +1598,49 @@ var gn = /*#__PURE__*/ e(pn, [["render", hn], ["__scopeId", "data-v-2fa93a82"]])
1598
1598
  maxHeight: `${h}px`
1599
1599
  };
1600
1600
  }
1601
- function T() {
1602
- S.value || (o.value = [...a.value], s.value = "", c.value = !0, xe(() => {
1603
- ee(), d.value?.focus();
1601
+ function E() {
1602
+ S.value || (a.value = [...i.value], o.value = "", s.value = !0, xe(() => {
1603
+ T(), u.value?.focus();
1604
1604
  }));
1605
1605
  }
1606
- function E() {
1607
- c.value = !1;
1606
+ function D() {
1607
+ s.value = !1;
1608
1608
  }
1609
- function te() {
1610
- c.value ? E() : T();
1609
+ function ee() {
1610
+ s.value ? D() : E();
1611
1611
  }
1612
- ae(() => [l.value, u.value], () => E(), { enabled: () => c.value });
1613
- function D() {
1614
- c.value && ee();
1612
+ ae(() => [c.value, l.value], () => D(), { enabled: () => s.value });
1613
+ function O() {
1614
+ s.value && T();
1615
1615
  }
1616
- X(c, (e) => {
1617
- e ? (window.addEventListener("scroll", D, !0), window.addEventListener("resize", D), window.visualViewport?.addEventListener("scroll", D), window.visualViewport?.addEventListener("resize", D)) : (window.removeEventListener("scroll", D, !0), window.removeEventListener("resize", D), window.visualViewport?.removeEventListener("scroll", D), window.visualViewport?.removeEventListener("resize", D));
1616
+ X(s, (e) => {
1617
+ e ? (window.addEventListener("scroll", O, !0), window.addEventListener("resize", O), window.visualViewport?.addEventListener("scroll", O), window.visualViewport?.addEventListener("resize", O)) : (window.removeEventListener("scroll", O, !0), window.removeEventListener("resize", O), window.visualViewport?.removeEventListener("scroll", O), window.visualViewport?.removeEventListener("resize", O));
1618
1618
  }), Ce(() => {
1619
- window.removeEventListener("scroll", D, !0), window.removeEventListener("resize", D), window.visualViewport?.removeEventListener("scroll", D), window.visualViewport?.removeEventListener("resize", D);
1619
+ window.removeEventListener("scroll", O, !0), window.removeEventListener("resize", O), window.visualViewport?.removeEventListener("scroll", O), window.visualViewport?.removeEventListener("resize", O);
1620
1620
  });
1621
- function O(e) {
1622
- return o.value.includes(e);
1621
+ function k(e) {
1622
+ return a.value.includes(e);
1623
1623
  }
1624
- function ne(e) {
1625
- let t = o.value.indexOf(e.value);
1626
- t === -1 ? o.value.push(e.value) : o.value.splice(t, 1);
1624
+ function te(e) {
1625
+ let t = a.value.indexOf(e.value);
1626
+ t === -1 ? a.value.push(e.value) : a.value.splice(t, 1);
1627
1627
  }
1628
- function re() {
1629
- if (C.value) o.value = o.value.filter((e) => !v.value.some((t) => t.value === e));
1628
+ function ne() {
1629
+ if (C.value) a.value = a.value.filter((e) => !v.value.some((t) => t.value === e));
1630
1630
  else {
1631
- let e = [...o.value];
1631
+ let e = [...a.value];
1632
1632
  for (let t of v.value) e.includes(t.value) || e.push(t.value);
1633
- o.value = e;
1633
+ a.value = e;
1634
1634
  }
1635
1635
  }
1636
- function ie() {
1637
- o.value = [];
1636
+ function re() {
1637
+ a.value = [];
1638
1638
  }
1639
- function oe(e) {
1639
+ function ie(e) {
1640
1640
  let t = m.value?.address || m.value?.name;
1641
1641
  if (!t) return;
1642
1642
  if (e.length === 0) {
1643
- i("background-click");
1643
+ r("background-click");
1644
1644
  return;
1645
1645
  }
1646
1646
  let n = e.length === 1 ? {
@@ -1650,35 +1650,35 @@ var gn = /*#__PURE__*/ e(pn, [["render", hn], ["__scopeId", "data-v-2fa93a82"]])
1650
1650
  op: "in",
1651
1651
  value: [...e]
1652
1652
  };
1653
- i("cell-click", {
1653
+ r("cell-click", {
1654
1654
  filters: { [t]: n },
1655
1655
  append: !1
1656
1656
  });
1657
1657
  }
1658
- function k() {
1659
- a.value = [...o.value], oe(a.value), E();
1658
+ function oe() {
1659
+ i.value = [...a.value], ie(i.value), D();
1660
1660
  }
1661
1661
  function A() {
1662
- a.value = [], o.value = [], oe([]), E();
1662
+ i.value = [], a.value = [], ie([]), D();
1663
1663
  }
1664
- X(() => r.initialSelection, (e) => {
1664
+ X(() => n.initialSelection, (e) => {
1665
1665
  let t = e ?? [];
1666
- t.length === a.value.length && t.every((e, t) => e === a.value[t]) || (a.value = [...t]);
1666
+ t.length === i.value.length && t.every((e, t) => e === i.value[t]) || (i.value = [...t]);
1667
1667
  });
1668
1668
  function se(e) {
1669
1669
  return e.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;").replace(/'/g, "&#39;");
1670
1670
  }
1671
1671
  function ce(e) {
1672
1672
  let t = se(e);
1673
- if (!s.value) return t;
1674
- let n = s.value.toLowerCase(), r = t.toLowerCase().indexOf(n);
1675
- return r === -1 ? t : `${t.slice(0, r)}<mark>${t.slice(r, r + s.value.length)}</mark>${t.slice(r + s.value.length)}`;
1676
- }
1677
- function j(e) {
1678
- (e.key === "Enter" || e.key === " " || e.key === "ArrowDown") && (e.preventDefault(), T());
1673
+ if (!o.value) return t;
1674
+ let n = o.value.toLowerCase(), r = t.toLowerCase().indexOf(n);
1675
+ return r === -1 ? t : `${t.slice(0, r)}<mark>${t.slice(r, r + o.value.length)}</mark>${t.slice(r + o.value.length)}`;
1679
1676
  }
1680
1677
  function le(e) {
1681
- e.key === "Escape" ? (e.preventDefault(), E(), l.value?.focus()) : e.key === "Enter" && (e.ctrlKey || e.metaKey) && (e.preventDefault(), k());
1678
+ (e.key === "Enter" || e.key === " " || e.key === "ArrowDown") && (e.preventDefault(), E());
1679
+ }
1680
+ function j(e) {
1681
+ e.key === "Escape" ? (e.preventDefault(), D(), c.value?.focus()) : e.key === "Enter" && (e.ctrlKey || e.metaKey) && (e.preventDefault(), oe());
1682
1682
  }
1683
1683
  return (e, t) => (W(), L("div", _n, [
1684
1684
  R("div", {
@@ -1687,25 +1687,25 @@ var gn = /*#__PURE__*/ e(pn, [["render", hn], ["__scopeId", "data-v-2fa93a82"]])
1687
1687
  }, J(y.value), 9, vn),
1688
1688
  R("button", {
1689
1689
  ref_key: "triggerRef",
1690
- ref: l,
1690
+ ref: c,
1691
1691
  type: "button",
1692
1692
  class: U(["filter-trigger", {
1693
- "is-open": c.value,
1693
+ "is-open": s.value,
1694
1694
  "has-selection": b.value,
1695
1695
  "is-disabled": S.value
1696
1696
  }]),
1697
1697
  disabled: S.value,
1698
- "aria-expanded": c.value,
1698
+ "aria-expanded": s.value,
1699
1699
  "aria-haspopup": "listbox",
1700
- onClick: te,
1701
- onKeydown: j
1700
+ onClick: ee,
1701
+ onKeydown: le
1702
1702
  }, [
1703
1703
  R("span", { class: U(["filter-value", { muted: !b.value }]) }, J(x.value), 3),
1704
- b.value && a.value.length > 1 ? (W(), L("span", {
1704
+ b.value && i.value.length > 1 ? (W(), L("span", {
1705
1705
  key: 0,
1706
1706
  class: "filter-count-badge",
1707
- title: `${a.value.length} selected`
1708
- }, J(a.value.length), 9, bn)) : I("", !0),
1707
+ title: `${i.value.length} selected`
1708
+ }, J(i.value.length), 9, bn)) : I("", !0),
1709
1709
  b.value ? (W(), L("span", {
1710
1710
  key: 1,
1711
1711
  class: "filter-clear",
@@ -1740,14 +1740,14 @@ var gn = /*#__PURE__*/ e(pn, [["render", hn], ["__scopeId", "data-v-2fa93a82"]])
1740
1740
  fill: "none"
1741
1741
  })], -1)
1742
1742
  ], 42, yn),
1743
- (W(), F(be, { to: "body" }, [c.value ? (W(), L("div", {
1743
+ (W(), F(be, { to: "body" }, [s.value ? (W(), L("div", {
1744
1744
  key: 0,
1745
1745
  ref_key: "dropdownRef",
1746
- ref: u,
1746
+ ref: l,
1747
1747
  class: "filter-dropdown",
1748
1748
  style: Se(w.value),
1749
1749
  role: "dialog",
1750
- onKeydown: le
1750
+ onKeydown: j
1751
1751
  }, [
1752
1752
  R("div", xn, [t[5] ||= R("svg", {
1753
1753
  viewBox: "0 0 24 24",
@@ -1768,12 +1768,12 @@ var gn = /*#__PURE__*/ e(pn, [["render", hn], ["__scopeId", "data-v-2fa93a82"]])
1768
1768
  "stroke-linecap": "round"
1769
1769
  })], -1), je(R("input", {
1770
1770
  ref_key: "searchInputRef",
1771
- ref: d,
1772
- "onUpdate:modelValue": t[0] ||= (e) => s.value = e,
1771
+ ref: u,
1772
+ "onUpdate:modelValue": t[0] ||= (e) => o.value = e,
1773
1773
  type: "text",
1774
1774
  class: "dropdown-search-input",
1775
1775
  placeholder: `Search ${y.value.toLowerCase()}...`
1776
- }, null, 8, Sn), [[ke, s.value]])]),
1776
+ }, null, 8, Sn), [[ke, o.value]])]),
1777
1777
  R("div", Cn, [
1778
1778
  v.value.length > 0 ? (W(), L("label", {
1779
1779
  key: 0,
@@ -1782,28 +1782,28 @@ var gn = /*#__PURE__*/ e(pn, [["render", hn], ["__scopeId", "data-v-2fa93a82"]])
1782
1782
  }, [R("input", {
1783
1783
  type: "checkbox",
1784
1784
  checked: C.value,
1785
- onChange: re
1786
- }, null, 40, wn), R("span", null, J(s.value ? `Select ${v.value.length} matching` : `All (${g.value.length})`), 1)], 32)) : I("", !0),
1785
+ onChange: ne
1786
+ }, null, 40, wn), R("span", null, J(o.value ? `Select ${v.value.length} matching` : `All (${g.value.length})`), 1)], 32)) : I("", !0),
1787
1787
  (W(!0), L(N, null, K(v.value, (e, n) => (W(), L("label", {
1788
1788
  key: n,
1789
- class: U(["dropdown-item", { selected: O(e.value) }]),
1789
+ class: U(["dropdown-item", { selected: k(e.value) }]),
1790
1790
  onMousedown: t[2] ||= Ne(() => {}, ["prevent"])
1791
1791
  }, [R("input", {
1792
1792
  type: "checkbox",
1793
- checked: O(e.value),
1794
- onChange: (t) => ne(e)
1793
+ checked: k(e.value),
1794
+ onChange: (t) => te(e)
1795
1795
  }, null, 40, Tn), R("span", { innerHTML: ce(e.label) }, null, 8, En)], 34))), 128)),
1796
1796
  v.value.length === 0 ? (W(), L("div", Dn, "No matches found")) : I("", !0)
1797
1797
  ]),
1798
1798
  R("div", On, [R("button", {
1799
1799
  type: "button",
1800
1800
  class: "footer-btn",
1801
- onClick: ie
1801
+ onClick: re
1802
1802
  }, "Clear"), R("button", {
1803
1803
  type: "button",
1804
1804
  class: "footer-btn primary",
1805
- onClick: k
1806
- }, " Apply" + J(o.value.length > 0 ? ` (${o.value.length})` : ""), 1)])
1805
+ onClick: oe
1806
+ }, " Apply" + J(a.value.length > 0 ? ` (${a.value.length})` : ""), 1)])
1807
1807
  ], 36)) : I("", !0)]))
1808
1808
  ]));
1809
1809
  }
@@ -1937,7 +1937,7 @@ function Mn(e, t, n, r, i, a) {
1937
1937
  subtle: ""
1938
1938
  }, null, 8, ["startTime"])])) : I("", !0)], 34);
1939
1939
  }
1940
- var Nn = /*#__PURE__*/ e(An, [["render", Mn], ["__scopeId", "data-v-164bba0a"]]), Pn = {
1940
+ var Nn = /*#__PURE__*/ d(An, [["render", Mn], ["__scopeId", "data-v-164bba0a"]]), Pn = {
1941
1941
  good: "Good",
1942
1942
  bad: "Bad",
1943
1943
  mixed: "Mixed",
@@ -2064,7 +2064,7 @@ function Gn(e, t, n, r, i, a) {
2064
2064
  title: "Refresh memo data"
2065
2065
  }, [...t[5] ||= [R("i", { class: "mdi mdi-refresh icon" }, null, -1)]])])) : I("", !0)], 2);
2066
2066
  }
2067
- var Kn = /*#__PURE__*/ e(Fn, [["render", Gn], ["__scopeId", "data-v-076ae1b1"]]), qn = V({
2067
+ var Kn = /*#__PURE__*/ d(Fn, [["render", Gn], ["__scopeId", "data-v-076ae1b1"]]), qn = V({
2068
2068
  name: "DashboardClaim",
2069
2069
  components: {
2070
2070
  MarkdownRenderer: fe,
@@ -2177,7 +2177,7 @@ function er(e, t, n, r, i, a) {
2177
2177
  title: "Refresh claim data"
2178
2178
  }, [...t[4] ||= [R("i", { class: "mdi mdi-refresh icon" }, null, -1)]])])) : I("", !0)]);
2179
2179
  }
2180
- var tr = /*#__PURE__*/ e(qn, [["render", er], ["__scopeId", "data-v-f46fbf38"]]), nr = V({
2180
+ var tr = /*#__PURE__*/ d(qn, [["render", er], ["__scopeId", "data-v-f46fbf38"]]), nr = V({
2181
2181
  name: "DashboardAppendixHeader",
2182
2182
  props: {
2183
2183
  dashboardId: {
@@ -2208,7 +2208,7 @@ function ar(e, t, n, r, i, a) {
2208
2208
  }, null, -1)
2209
2209
  ]);
2210
2210
  }
2211
- var or = /*#__PURE__*/ e(nr, [["render", ar], ["__scopeId", "data-v-46b63709"]]), sr = 8, cr = 200, lr = 512, ur = 2e3;
2211
+ var or = /*#__PURE__*/ d(nr, [["render", ar], ["__scopeId", "data-v-46b63709"]]), sr = 8, cr = 200, lr = 512, ur = 2e3;
2212
2212
  function dr(e) {
2213
2213
  return typeof e == "string" ? e.length <= lr : typeof e == "number" ? Number.isFinite(e) : e instanceof Date && !Number.isNaN(e.getTime());
2214
2214
  }
@@ -2284,7 +2284,7 @@ function mr(e) {
2284
2284
  }
2285
2285
  }
2286
2286
  function hr(e) {
2287
- return Math.min(T, Math.max(40, Math.round(e)));
2287
+ return Math.min(x, Math.max(40, Math.round(e)));
2288
2288
  }
2289
2289
  function gr(e) {
2290
2290
  if (!e?.headers) return [];
@@ -2413,7 +2413,7 @@ var br = 40, xr = class {
2413
2413
  'use strict';
2414
2414
 
2415
2415
  var VERSION = 1;
2416
- var HELLO = '${O}';
2416
+ var HELLO = '${T}';
2417
2417
 
2418
2418
  var port = null;
2419
2419
  var pending = [];
@@ -2596,7 +2596,7 @@ function wr(e) {
2596
2596
  return /^https:\/\/[a-z0-9.-]+(:\d+)?$/i.test(e);
2597
2597
  }
2598
2598
  function Tr(e = {}) {
2599
- let t = (e.cdnOrigins ?? ne).filter(wr), n = t.length ? " " + t.join(" ") : "";
2599
+ let t = (e.cdnOrigins ?? E).filter(wr), n = t.length ? " " + t.join(" ") : "";
2600
2600
  return [
2601
2601
  "default-src 'none'",
2602
2602
  `script-src 'unsafe-inline' 'unsafe-eval' blob:${n}`,
@@ -2863,11 +2863,11 @@ var Pr = V({
2863
2863
  }
2864
2864
  },
2865
2865
  emits: ["dimension-click", "background-click"],
2866
- setup(e, { emit: n }) {
2867
- let r = G(null), i = G(null), a = G(null), o = G(0), s = null, c = null, l = P(() => e.getItemData(e.itemId, e.dashboardId)), u = P(() => l.value.freeformData || null), d = P(() => u.value?.html || ""), f = P(() => l.value.structured_content?.query || ""), p = P(() => l.value.results || null), m = P(() => l.value.loading || !1), h = P(() => l.value.error || null), g = P(() => l.value.filters || []), _ = P(() => l.value.loadStartTime || null), v = P(() => l.value.onRefresh || null), y = P(() => l.value.name || "Custom widget"), b = H("analyticsStore", null), x = H("userSettingsStore", null), S = t(x), { chartContainer: C, showLoading: w, controlsVisible: ee, handleLocalRefresh: T, onChartMouseEnter: te, onChartMouseLeave: D } = an({
2866
+ setup(e, { emit: t }) {
2867
+ let n = G(null), r = G(null), i = G(null), a = G(0), o = null, s = null, c = P(() => e.getItemData(e.itemId, e.dashboardId)), l = P(() => c.value.freeformData || null), u = P(() => l.value?.html || ""), d = P(() => c.value.structured_content?.query || ""), p = P(() => c.value.results || null), m = P(() => c.value.loading || !1), h = P(() => c.value.error || null), g = P(() => c.value.filters || []), _ = P(() => c.value.loadStartTime || null), v = P(() => c.value.onRefresh || null), y = P(() => c.value.name || "Custom widget"), b = H("analyticsStore", null), x = H("userSettingsStore", null), C = f(x), { chartContainer: w, showLoading: T, controlsVisible: E, handleLocalRefresh: D, onChartMouseEnter: ee, onChartMouseLeave: O } = an({
2868
2868
  dashboardId: () => e.dashboardId,
2869
2869
  itemId: () => e.itemId,
2870
- query: f,
2870
+ query: d,
2871
2871
  results: p,
2872
2872
  loading: m,
2873
2873
  onRefresh: v,
@@ -2877,73 +2877,73 @@ var Pr = V({
2877
2877
  analyticsType: "FREEFORM",
2878
2878
  loadingDelayMs: 250
2879
2879
  });
2880
- function O() {
2880
+ function k() {
2881
2881
  return Nr({
2882
- mode: S.value,
2883
- element: C.value
2882
+ mode: C.value,
2883
+ element: w.value
2884
2884
  });
2885
2885
  }
2886
- let ne = P(() => d.value ? (o.value, S.value, kr({
2887
- html: d.value,
2888
- theme: O()
2889
- })) : ""), re = P(() => a.value ? { height: `${a.value}px` } : void 0);
2890
- function ie() {
2891
- s && s.postState(yr({
2886
+ let te = P(() => u.value ? (a.value, C.value, kr({
2887
+ html: u.value,
2888
+ theme: k()
2889
+ })) : ""), ne = P(() => i.value ? { height: `${i.value}px` } : void 0);
2890
+ function re() {
2891
+ o && o.postState(yr({
2892
2892
  status: m.value ? "loading" : h.value ? "error" : "ready",
2893
2893
  results: p.value,
2894
2894
  filters: g.value,
2895
2895
  error: h.value
2896
2896
  }));
2897
2897
  }
2898
- function ae() {
2899
- c &&= (clearTimeout(c), null);
2898
+ function ie() {
2899
+ s &&= (clearTimeout(s), null);
2900
2900
  }
2901
- function oe() {
2902
- ae(), c = setTimeout(() => {
2903
- s?.connected && !i.value && (i.value = "Widget did not finish loading.");
2904
- }, E);
2901
+ function ae() {
2902
+ ie(), s = setTimeout(() => {
2903
+ o?.connected && !r.value && (r.value = "Widget did not finish loading.");
2904
+ }, S);
2905
2905
  }
2906
- function k(t) {
2907
- if (t.mode === "clear") {
2908
- n("background-click");
2906
+ function oe(n) {
2907
+ if (n.mode === "clear") {
2908
+ t("background-click");
2909
2909
  return;
2910
2910
  }
2911
- let r = _r(t.filters, p.value), i = {};
2911
+ let r = _r(n.filters, p.value), i = {};
2912
2912
  for (let [e, t] of Object.entries(r)) (t.op === "eq" || t.op === "in") && (i[e] = t.value);
2913
- n("dimension-click", {
2913
+ t("dimension-click", {
2914
2914
  source: e.itemId,
2915
2915
  filters: r,
2916
2916
  chart: i,
2917
- append: t.mode === "append"
2917
+ append: n.mode === "append"
2918
2918
  });
2919
2919
  }
2920
2920
  function A() {
2921
- ae(), s?.destroy(), s = null;
2921
+ ie(), o?.destroy(), o = null;
2922
2922
  }
2923
2923
  function se() {
2924
2924
  A();
2925
- let t = r.value;
2926
- t && (i.value = null, s = new xr({
2925
+ let t = n.value;
2926
+ t && (r.value = null, o = new xr({
2927
2927
  itemId: e.itemId,
2928
2928
  editMode: e.editMode,
2929
2929
  onReady: () => {
2930
- ae(), i.value = null;
2930
+ ie(), r.value = null;
2931
2931
  },
2932
- onFilter: k,
2933
- onRefresh: () => T(),
2932
+ onFilter: oe,
2933
+ onRefresh: () => D(),
2934
2934
  onResize: (e) => {
2935
- a.value = e;
2935
+ i.value = e;
2936
2936
  },
2937
2937
  onLog: (t, n) => {
2938
2938
  let r = `[widget ${e.itemId}]`;
2939
2939
  t === "error" ? console.error(r, n) : t === "warn" ? console.warn(r, n) : console.log(r, n);
2940
2940
  }
2941
- }), s.attach(t), s.postTheme(O()), ie(), oe());
2941
+ }), o.attach(t), o.postTheme(k()), re(), ae());
2942
2942
  }
2943
2943
  function ce() {
2944
- a.value = null, o.value += 1;
2944
+ i.value = null, a.value += 1;
2945
2945
  }
2946
- return X([ne, r], ([e, t]) => {
2946
+ return X([te, n], ([e, t]) => {
2947
2947
  if (!e || !t) {
2948
2948
  A();
2949
2949
  return;
@@ -2957,26 +2957,26 @@ var Pr = V({
2957
2957
  m,
2958
2958
  h,
2959
2959
  g
2960
- ], () => ie()), X(S, async () => {
2961
- await xe(), s?.postTheme(O());
2960
+ ], () => re()), X(C, async () => {
2961
+ await xe(), o?.postTheme(k());
2962
2962
  }), Ce(A), {
2963
- chartContainer: C,
2964
- frameRef: r,
2965
- srcdoc: ne,
2966
- frameStyle: re,
2967
- html: d,
2968
- query: f,
2963
+ chartContainer: w,
2964
+ frameRef: n,
2965
+ srcdoc: te,
2966
+ frameStyle: ne,
2967
+ html: u,
2968
+ query: d,
2969
2969
  filters: g,
2970
2970
  loading: m,
2971
- showLoading: w,
2971
+ showLoading: T,
2972
2972
  error: h,
2973
2973
  startTime: _,
2974
- controlsVisible: ee,
2975
- widgetFailure: i,
2974
+ controlsVisible: E,
2975
+ widgetFailure: r,
2976
2976
  widgetTitle: y,
2977
- handleLocalRefresh: T,
2978
- onChartMouseEnter: te,
2979
- onChartMouseLeave: D,
2977
+ handleLocalRefresh: D,
2978
+ onChartMouseEnter: ee,
2979
+ onChartMouseLeave: O,
2980
2980
  reloadWidget: ce,
2981
2981
  FREEFORM_SANDBOX: Cr
2982
2982
  };
@@ -3049,7 +3049,7 @@ function Br(e, t, n, r, i, a) {
3049
3049
  }, [...t[7] ||= [R("i", { class: "mdi mdi-reload icon" }, null, -1)]])], 2)
3050
3050
  ], 544);
3051
3051
  }
3052
- var Vr = /*#__PURE__*/ e(Pr, [["render", Br], ["__scopeId", "data-v-da53ca6d"]]), Hr = ["data-testid"], Ur = ["data-testid"], Wr = ["data-testid"], Gr = ["data-testid"], Kr = {
3052
+ var Vr = /*#__PURE__*/ d(Pr, [["render", Br], ["__scopeId", "data-v-da53ca6d"]]), Hr = ["data-testid"], Ur = ["data-testid"], Wr = ["data-testid"], Gr = ["data-testid"], Kr = {
3053
3053
  key: 1,
3054
3054
  class: "grid-item-header"
3055
3055
  }, qr = { class: "grid-item-header-left" }, Jr = {
@@ -3067,7 +3067,7 @@ var Vr = /*#__PURE__*/ e(Pr, [["render", Br], ["__scopeId", "data-v-da53ca6d"]])
3067
3067
  }, bi = {
3068
3068
  key: 1,
3069
3069
  class: "mdi mdi-filter-outline icon"
3070
- }, xi = ["data-testid"], Si = ["data-testid"], Ci = ["aria-label"], wi = { class: "mobile-filter-popover-header" }, Ti = { class: "mobile-filter-popover-values" }, Ei = /*#__PURE__*/ e(/* @__PURE__ */ V({
3070
+ }, xi = ["data-testid"], Si = ["data-testid"], Ci = ["aria-label"], wi = { class: "mobile-filter-popover-header" }, Ti = { class: "mobile-filter-popover-values" }, Ei = /*#__PURE__*/ d(/* @__PURE__ */ V({
3071
3071
  __name: "DashboardGridItem",
3072
3072
  props: {
3073
3073
  dashboardId: {},
@@ -3088,7 +3088,7 @@ var Vr = /*#__PURE__*/ e(Pr, [["render", Br], ["__scopeId", "data-v-da53ca6d"]])
3088
3088
  "copy-item"
3089
3089
  ],
3090
3090
  setup(e, { emit: t }) {
3091
- let n = e, r = t, i = G(!1), o = G(""), s = G(!1), c = G(!1), l = G(null), u = G(null), d = G(null), f = G(null), p = G({});
3091
+ let r = e, i = t, a = G(!1), o = G(""), s = G(!1), c = G(!1), l = G(null), u = G(null), d = G(null), f = G(null), p = G({});
3092
3092
  function m(e) {
3093
3093
  return e.replace(/'''/g, "'").replace("local.", "");
3094
3094
  }
@@ -3107,100 +3107,100 @@ var Vr = /*#__PURE__*/ e(Pr, [["render", Br], ["__scopeId", "data-v-da53ca6d"]])
3107
3107
  navigator.clipboard.writeText(h(e, t));
3108
3108
  }
3109
3109
  function _() {
3110
- if (!n.editMode) return;
3111
- let e = n.getItemData(n.item.i, n.dashboardId);
3112
- s.value = !1, c.value = !1, i.value = !0, o.value = e.name, setTimeout(() => {
3113
- let e = document.getElementById(`title-input-${n.item.i}`);
3110
+ if (!r.editMode) return;
3111
+ let e = r.getItemData(r.item.i, r.dashboardId);
3112
+ s.value = !1, c.value = !1, a.value = !0, o.value = e.name, setTimeout(() => {
3113
+ let e = document.getElementById(`title-input-${r.item.i}`);
3114
3114
  e && e.focus();
3115
3115
  }, 0);
3116
3116
  }
3117
3117
  function v() {
3118
- if (i.value) {
3119
- let e = n.getItemData(n.item.i, n.dashboardId), t = o.value.trim() || e.name;
3120
- n.setItemData(n.item.i, n.dashboardId, { name: t }), i.value = !1;
3118
+ if (a.value) {
3119
+ let e = r.getItemData(r.item.i, r.dashboardId), t = o.value.trim() || e.name;
3120
+ r.setItemData(r.item.i, r.dashboardId, { name: t }), a.value = !1;
3121
3121
  }
3122
3122
  }
3123
3123
  function y() {
3124
- let e = !n.getItemData(n.item.i, n.dashboardId).allowCrossFilter;
3125
- n.setItemData(n.item.i, n.dashboardId, { allowCrossFilter: e });
3124
+ let e = !r.getItemData(r.item.i, r.dashboardId).allowCrossFilter;
3125
+ r.setItemData(r.item.i, r.dashboardId, { allowCrossFilter: e });
3126
3126
  }
3127
3127
  function b() {
3128
- let e = n.item.h + 1;
3129
- n.setItemData(n.item.i, n.dashboardId, { dimensions: {
3130
- width: n.item.w,
3128
+ let e = r.item.h + 1;
3129
+ r.setItemData(r.item.i, r.dashboardId, { dimensions: {
3130
+ width: r.item.w,
3131
3131
  height: e
3132
3132
  } });
3133
3133
  }
3134
3134
  function x() {
3135
- let e = Math.max(1, n.item.h - 1);
3136
- n.setItemData(n.item.i, n.dashboardId, { dimensions: {
3137
- width: n.item.w,
3135
+ let e = Math.max(1, r.item.h - 1);
3136
+ r.setItemData(r.item.i, r.dashboardId, { dimensions: {
3137
+ width: r.item.w,
3138
3138
  height: e
3139
3139
  } });
3140
3140
  }
3141
3141
  function S() {
3142
- i.value = !1;
3142
+ a.value = !1;
3143
3143
  }
3144
3144
  function C() {
3145
- if (O.value) {
3145
+ if (k.value) {
3146
3146
  _();
3147
3147
  return;
3148
3148
  }
3149
- r("edit-content", n.item);
3149
+ i("edit-content", r.item);
3150
3150
  }
3151
3151
  function w() {
3152
- confirm(`Are you sure you want to remove "${D.value.name}"?`) && r("remove-item", n.item.i);
3152
+ confirm(`Are you sure you want to remove "${O.value.name}"?`) && i("remove-item", r.item.i);
3153
3153
  }
3154
- function ee() {
3155
- r("copy-item", n.item.i);
3154
+ function T() {
3155
+ i("copy-item", r.item.i);
3156
3156
  }
3157
- function T(e) {
3158
- r("dimension-click", e);
3157
+ function E(e) {
3158
+ i("dimension-click", e);
3159
3159
  }
3160
- function E() {
3161
- r("background-click", n.item.i);
3160
+ function D() {
3161
+ i("background-click", r.item.i);
3162
3162
  }
3163
- function te(e) {
3164
- r("remove-filter", n.item.i, e);
3165
- }
3166
- let D = P(() => n.getItemData(n.item.i, n.dashboardId)), O = P(() => D.value.type === a.SECTION_HEADER), ne = P(() => D.value.type === a.FREEFORM), re = P(() => {
3167
- switch (D.value.type) {
3168
- case a.CHART: return ln;
3169
- case a.TABLE: return gn;
3170
- case a.FILTER: return Nn;
3171
- case a.SECTION_HEADER: return null;
3172
- case a.MEMO: return Kn;
3173
- case a.CLAIM: return tr;
3174
- case a.APPENDIX_HEADER: return or;
3175
- case a.FREEFORM: return Vr;
3176
- case a.MARKDOWN:
3163
+ function ee(e) {
3164
+ i("remove-filter", r.item.i, e);
3165
+ }
3166
+ let O = P(() => r.getItemData(r.item.i, r.dashboardId)), k = P(() => O.value.type === n.SECTION_HEADER), te = P(() => O.value.type === n.FREEFORM), ne = P(() => {
3167
+ switch (O.value.type) {
3168
+ case n.CHART: return ln;
3169
+ case n.TABLE: return gn;
3170
+ case n.FILTER: return Nn;
3171
+ case n.SECTION_HEADER: return null;
3172
+ case n.MEMO: return Kn;
3173
+ case n.CLAIM: return tr;
3174
+ case n.APPENDIX_HEADER: return or;
3175
+ case n.FREEFORM: return Vr;
3176
+ case n.MARKDOWN:
3177
3177
  default: return fn;
3178
3178
  }
3179
- }), ie = P(() => {
3180
- switch (D.value.type) {
3181
- case a.CHART: return "Chart Name";
3182
- case a.TABLE: return "Table Name";
3183
- case a.FILTER: return "Filter Name";
3184
- case a.SECTION_HEADER: return "Section Header";
3185
- case a.MEMO: return "Executive Memo";
3186
- case a.CLAIM: return "Claim";
3187
- case a.APPENDIX_HEADER: return "Appendix";
3188
- case a.FREEFORM: return "Widget Name";
3189
- case a.MARKDOWN:
3179
+ }), re = P(() => {
3180
+ switch (O.value.type) {
3181
+ case n.CHART: return "Chart Name";
3182
+ case n.TABLE: return "Table Name";
3183
+ case n.FILTER: return "Filter Name";
3184
+ case n.SECTION_HEADER: return "Section Header";
3185
+ case n.MEMO: return "Executive Memo";
3186
+ case n.CLAIM: return "Claim";
3187
+ case n.APPENDIX_HEADER: return "Appendix";
3188
+ case n.FREEFORM: return "Widget Name";
3189
+ case n.MARKDOWN:
3190
3190
  default: return "Note Name";
3191
3191
  }
3192
- }), oe = [
3193
- a.CHART,
3194
- a.TABLE,
3195
- a.MARKDOWN,
3196
- a.FREEFORM
3197
- ], A = [
3198
- a.CHART,
3199
- a.TABLE,
3200
- a.FILTER,
3201
- a.FREEFORM
3202
- ], se = P(() => oe.includes(D.value.type)), ce = P(() => A.includes(D.value.type)), j = P(() => D.value.filters ? D.value.filters.length : 0), le = P(() => (D.value.filters || []).slice(0, 2)), ue = P(() => Math.max(0, j.value - le.value.length)), de = P(() => {
3203
- let e = D.value.filters || [];
3192
+ }), ie = [
3193
+ n.CHART,
3194
+ n.TABLE,
3195
+ n.MARKDOWN,
3196
+ n.FREEFORM
3197
+ ], oe = [
3198
+ n.CHART,
3199
+ n.TABLE,
3200
+ n.FILTER,
3201
+ n.FREEFORM
3202
+ ], se = P(() => ie.includes(O.value.type)), ce = P(() => oe.includes(O.value.type)), le = P(() => O.value.filters ? O.value.filters.length : 0), j = P(() => (O.value.filters || []).slice(0, 2)), ue = P(() => Math.max(0, le.value - j.value.length)), de = P(() => {
3203
+ let e = O.value.filters || [];
3204
3204
  return ["global", "cross"].map((t) => ({
3205
3205
  type: t,
3206
3206
  filters: e.filter((e) => t === "global" ? e.source === "global" : e.source !== "global")
@@ -3249,7 +3249,7 @@ var Vr = /*#__PURE__*/ e(Pr, [["render", Br], ["__scopeId", "data-v-da53ca6d"]])
3249
3249
  level: 3
3250
3250
  };
3251
3251
  }
3252
- let he = P(() => me(D.value.name, ie.value)), M = P(() => he.value.text), ge = P(() => `item-title-level-${he.value.level}`), _e = P(() => s.value && !i.value && !c.value);
3252
+ let he = P(() => me(O.value.name, re.value)), M = P(() => he.value.text), ge = P(() => `item-title-level-${he.value.level}`), _e = P(() => s.value && !a.value && !c.value);
3253
3253
  function ve() {
3254
3254
  _e.value && (c.value = !0, s.value = !1);
3255
3255
  }
@@ -3262,18 +3262,18 @@ var Vr = /*#__PURE__*/ e(Pr, [["render", Br], ["__scopeId", "data-v-da53ca6d"]])
3262
3262
  return ae([l, u], ve, {
3263
3263
  enabled: () => _e.value,
3264
3264
  eventName: "mousedown"
3265
- }), (t, r) => (W(), L(N, null, [R("div", {
3265
+ }), (t, i) => (W(), L(N, null, [R("div", {
3266
3266
  class: U(["grid-item-content", {
3267
3267
  "grid-item-chart-style": ce.value,
3268
- "grid-item-markdown-style": D.value.type === Y(a).MARKDOWN,
3269
- "grid-item-section-header-style": O.value,
3268
+ "grid-item-markdown-style": O.value.type === Y(n).MARKDOWN,
3269
+ "grid-item-section-header-style": k.value,
3270
3270
  "grid-item-edit-style": e.editMode
3271
3271
  }]),
3272
3272
  "data-testid": `dashboard-component-${e.item.i}`,
3273
3273
  onMouseenter: ye,
3274
3274
  onMouseleave: z
3275
3275
  }, [
3276
- e.editMode && O.value ? (W(), L("div", {
3276
+ e.editMode && k.value ? (W(), L("div", {
3277
3277
  key: 0,
3278
3278
  class: U(["dev-toolbar-shell", { "dev-toolbar-visible": _e.value }])
3279
3279
  }, [R("div", {
@@ -3287,21 +3287,21 @@ var Vr = /*#__PURE__*/ e(Pr, [["render", Br], ["__scopeId", "data-v-da53ca6d"]])
3287
3287
  class: "control-btn",
3288
3288
  "data-testid": `edit-dashboard-item-content-${e.item.i}`,
3289
3289
  title: "Edit title"
3290
- }, [...r[4] ||= [R("i", { class: "mdi mdi-pencil-outline icon" }, null, -1)]], 8, Ur),
3290
+ }, [...i[4] ||= [R("i", { class: "mdi mdi-pencil-outline icon" }, null, -1)]], 8, Ur),
3291
3291
  R("button", {
3292
- onClick: ee,
3292
+ onClick: T,
3293
3293
  class: "control-btn",
3294
3294
  "data-testid": `copy-dashboard-item-${e.item.i}`,
3295
3295
  title: "Copy item"
3296
- }, [...r[5] ||= [R("i", { class: "mdi mdi-content-copy icon" }, null, -1)]], 8, Wr),
3296
+ }, [...i[5] ||= [R("i", { class: "mdi mdi-content-copy icon" }, null, -1)]], 8, Wr),
3297
3297
  R("button", {
3298
3298
  onClick: w,
3299
3299
  class: "control-btn dashboard-remove-btn",
3300
3300
  "data-testid": `remove-dashboard-item-${e.item.i}`,
3301
3301
  title: "Remove item"
3302
- }, [...r[6] ||= [R("i", { class: "mdi mdi-delete-outline icon" }, null, -1)]], 8, Gr)
3302
+ }, [...i[6] ||= [R("i", { class: "mdi mdi-delete-outline icon" }, null, -1)]], 8, Gr)
3303
3303
  ], 512)], 2)) : I("", !0),
3304
- O.value ? I("", !0) : (W(), L("div", Kr, [R("div", qr, [e.editMode ? (W(), L("div", Jr, [...r[7] ||= [R("svg", {
3304
+ k.value ? I("", !0) : (W(), L("div", Kr, [R("div", qr, [e.editMode ? (W(), L("div", Jr, [...i[7] ||= [R("svg", {
3305
3305
  xmlns: "http://www.w3.org/2000/svg",
3306
3306
  width: "16",
3307
3307
  height: "16",
@@ -3331,31 +3331,31 @@ var Vr = /*#__PURE__*/ e(Pr, [["render", Br], ["__scopeId", "data-v-da53ca6d"]])
3331
3331
  x2: "21",
3332
3332
  y2: "18"
3333
3333
  })
3334
- ], -1)]])) : I("", !0), R("div", Yr, [i.value ? je((W(), L("input", {
3334
+ ], -1)]])) : I("", !0), R("div", Yr, [a.value ? je((W(), L("input", {
3335
3335
  key: 1,
3336
3336
  id: `title-input-${e.item.i}`,
3337
- "onUpdate:modelValue": r[0] ||= (e) => o.value = e,
3337
+ "onUpdate:modelValue": i[0] ||= (e) => o.value = e,
3338
3338
  onBlur: v,
3339
3339
  onKeyup: [Me(v, ["enter"]), Me(S, ["esc"])],
3340
3340
  class: "title-input",
3341
3341
  type: "text",
3342
- placeholder: ie.value
3342
+ placeholder: re.value
3343
3343
  }, null, 40, $r)), [[ke, o.value]]) : (W(), L("div", {
3344
3344
  key: 0,
3345
3345
  class: U(["item-title editable-title", [ge.value, { "item-title-static": !e.editMode }]]),
3346
3346
  title: M.value,
3347
3347
  onClick: _
3348
- }, [R("span", Zr, J(M.value), 1), e.editMode ? (W(), L("i", Qr)) : I("", !0)], 10, Xr))])]), R("div", ei, [ne.value ? (W(), F(k, {
3348
+ }, [R("span", Zr, J(M.value), 1), e.editMode ? (W(), L("i", Qr)) : I("", !0)], 10, Xr))])]), R("div", ei, [te.value ? (W(), F(A, {
3349
3349
  key: 0,
3350
3350
  content: "Custom code widget — runs in a sandboxed frame with no network or app access",
3351
3351
  position: "bottom"
3352
3352
  }, {
3353
- default: Z(() => [...r[8] ||= [R("span", {
3353
+ default: Z(() => [...i[8] ||= [R("span", {
3354
3354
  class: "widget-badge",
3355
3355
  "data-testid": "freeform-widget-badge"
3356
3356
  }, [R("i", { class: "mdi mdi-code-braces" })], -1)]]),
3357
3357
  _: 1
3358
- })) : I("", !0), se.value && j.value > 0 ? (W(), L("div", ti, [R("div", ni, [(W(!0), L(N, null, K(le.value, (t, n) => (W(), F(k, {
3358
+ })) : I("", !0), se.value && le.value > 0 ? (W(), L("div", ti, [R("div", ni, [(W(!0), L(N, null, K(j.value, (t, n) => (W(), F(A, {
3359
3359
  key: `${t.source}-${t.value}-${n}`,
3360
3360
  content: h(t.value, t.parameters),
3361
3361
  position: "bottom"
@@ -3370,12 +3370,12 @@ var Vr = /*#__PURE__*/ e(Pr, [["render", Br], ["__scopeId", "data-v-da53ca6d"]])
3370
3370
  e.editMode && t.source !== "global" ? (W(), L("button", {
3371
3371
  key: 0,
3372
3372
  class: "filter-remove-btn",
3373
- onClick: (e) => te(t.source),
3373
+ onClick: (e) => ee(t.source),
3374
3374
  title: `Remove ${t.source} filter`
3375
3375
  }, " x ", 8, ci)) : I("", !0)
3376
3376
  ])]),
3377
3377
  _: 2
3378
- }, 1032, ["content"]))), 128)), ue.value > 0 ? (W(), F(k, {
3378
+ }, 1032, ["content"]))), 128)), ue.value > 0 ? (W(), F(A, {
3379
3379
  key: 0,
3380
3380
  content: `${ue.value} more filter(s)`,
3381
3381
  position: "bottom"
@@ -3389,31 +3389,31 @@ var Vr = /*#__PURE__*/ e(Pr, [["render", Br], ["__scopeId", "data-v-da53ca6d"]])
3389
3389
  "aria-expanded": f.value === e.type,
3390
3390
  onClick: Ne((t) => pe(t, e.type), ["stop"])
3391
3391
  }, J(e.type) + ":" + J(e.filters.length), 9, di))), 128))])])) : I("", !0)])])),
3392
- R("div", { class: U(["content-area", { "section-header-content": O.value }]) }, [O.value ? (W(), L(N, { key: 0 }, [i.value ? je((W(), L("input", {
3392
+ R("div", { class: U(["content-area", { "section-header-content": k.value }]) }, [k.value ? (W(), L(N, { key: 0 }, [a.value ? je((W(), L("input", {
3393
3393
  key: 1,
3394
3394
  id: `title-input-${e.item.i}`,
3395
- "onUpdate:modelValue": r[1] ||= (e) => o.value = e,
3395
+ "onUpdate:modelValue": i[1] ||= (e) => o.value = e,
3396
3396
  onBlur: v,
3397
3397
  onKeyup: [Me(v, ["enter"]), Me(S, ["esc"])],
3398
3398
  class: "title-input section-header-input no-drag",
3399
3399
  type: "text",
3400
- placeholder: ie.value
3400
+ placeholder: re.value
3401
3401
  }, null, 40, mi)), [[ke, o.value]]) : (W(), L("div", {
3402
3402
  key: 0,
3403
3403
  class: U(["section-header-display no-drag", [ge.value, { "section-header-editable": e.editMode }]]),
3404
3404
  title: M.value,
3405
3405
  onClick: _
3406
- }, [R("span", pi, J(M.value), 1)], 10, fi))], 64)) : (W(), F(De(re.value), {
3406
+ }, [R("span", pi, J(M.value), 1)], 10, fi))], 64)) : (W(), F(De(ne.value), {
3407
3407
  key: 1,
3408
- dashboardId: n.dashboardId,
3408
+ dashboardId: r.dashboardId,
3409
3409
  itemId: e.item.i,
3410
3410
  setItemData: e.setItemData,
3411
3411
  getItemData: e.getItemData,
3412
3412
  getDashboardQueryExecutor: e.getDashboardQueryExecutor,
3413
3413
  editMode: e.editMode,
3414
- symbols: n.symbols || [],
3415
- onDimensionClick: T,
3416
- onBackgroundClick: E
3414
+ symbols: r.symbols || [],
3415
+ onDimensionClick: E,
3416
+ onBackgroundClick: D
3417
3417
  }, null, 40, [
3418
3418
  "dashboardId",
3419
3419
  "itemId",
@@ -3422,7 +3422,7 @@ var Vr = /*#__PURE__*/ e(Pr, [["render", Br], ["__scopeId", "data-v-da53ca6d"]])
3422
3422
  "getDashboardQueryExecutor",
3423
3423
  "editMode",
3424
3424
  "symbols"
3425
- ])), e.editMode && !O.value ? (W(), L("div", {
3425
+ ])), e.editMode && !k.value ? (W(), L("div", {
3426
3426
  key: 2,
3427
3427
  class: U(["content-edit-overlay no-drag", { "content-edit-overlay-visible": _e.value }])
3428
3428
  }, [R("div", {
@@ -3436,37 +3436,37 @@ var Vr = /*#__PURE__*/ e(Pr, [["render", Br], ["__scopeId", "data-v-da53ca6d"]])
3436
3436
  class: "control-btn",
3437
3437
  "data-testid": `increase-height-item-${e.item.i}`,
3438
3438
  title: "Increase height"
3439
- }, [...r[9] ||= [R("i", { class: "mdi mdi-plus icon" }, null, -1)]], 8, hi),
3439
+ }, [...i[9] ||= [R("i", { class: "mdi mdi-plus icon" }, null, -1)]], 8, hi),
3440
3440
  R("button", {
3441
3441
  onClick: x,
3442
3442
  class: "control-btn",
3443
3443
  "data-testid": `decrease-height-item-${e.item.i}`,
3444
3444
  title: "Decrease height"
3445
- }, [...r[10] ||= [R("i", { class: "mdi mdi-minus icon" }, null, -1)]], 8, gi),
3445
+ }, [...i[10] ||= [R("i", { class: "mdi mdi-minus icon" }, null, -1)]], 8, gi),
3446
3446
  R("button", {
3447
3447
  onClick: C,
3448
3448
  class: "control-btn",
3449
3449
  "data-testid": `edit-dashboard-item-content-${e.item.i}`,
3450
3450
  title: "Edit data"
3451
- }, [...r[11] ||= [R("i", { class: "mdi mdi-database-edit-outline icon" }, null, -1)]], 8, _i),
3451
+ }, [...i[11] ||= [R("i", { class: "mdi mdi-database-edit-outline icon" }, null, -1)]], 8, _i),
3452
3452
  R("button", {
3453
3453
  onClick: y,
3454
3454
  class: "control-btn",
3455
3455
  "data-testid": `toggle-crossfilter-item-content-${e.item.i}`,
3456
- title: D.value.allowCrossFilter ? "Toggle cross-filtering OFF" : "Toggle cross-filtering ON"
3457
- }, [D.value.allowCrossFilter ? (W(), L("i", yi)) : (W(), L("i", bi))], 8, vi),
3456
+ title: O.value.allowCrossFilter ? "Toggle cross-filtering OFF" : "Toggle cross-filtering ON"
3457
+ }, [O.value.allowCrossFilter ? (W(), L("i", yi)) : (W(), L("i", bi))], 8, vi),
3458
3458
  R("button", {
3459
- onClick: ee,
3459
+ onClick: T,
3460
3460
  class: "control-btn",
3461
3461
  "data-testid": `copy-dashboard-item-${e.item.i}`,
3462
3462
  title: "Copy item"
3463
- }, [...r[12] ||= [R("i", { class: "mdi mdi-content-copy icon" }, null, -1)]], 8, xi),
3463
+ }, [...i[12] ||= [R("i", { class: "mdi mdi-content-copy icon" }, null, -1)]], 8, xi),
3464
3464
  R("button", {
3465
3465
  onClick: w,
3466
3466
  class: "control-btn dashboard-remove-btn",
3467
3467
  "data-testid": `remove-dashboard-item-${e.item.i}`,
3468
3468
  title: "Remove item"
3469
- }, [...r[13] ||= [R("i", { class: "mdi mdi-delete-outline icon" }, null, -1)]], 8, Si)
3469
+ }, [...i[13] ||= [R("i", { class: "mdi mdi-delete-outline icon" }, null, -1)]], 8, Si)
3470
3470
  ], 512)], 2)) : I("", !0)], 2)
3471
3471
  ], 42, Hr), (W(), F(be, { to: "body" }, [f.value ? (W(), L("div", {
3472
3472
  key: 0,
@@ -3476,12 +3476,12 @@ var Vr = /*#__PURE__*/ e(Pr, [["render", Br], ["__scopeId", "data-v-da53ca6d"]])
3476
3476
  style: Se(p.value),
3477
3477
  role: "dialog",
3478
3478
  "aria-label": `${f.value} filters`,
3479
- onClick: r[3] ||= Ne(() => {}, ["stop"])
3479
+ onClick: i[3] ||= Ne(() => {}, ["stop"])
3480
3480
  }, [R("div", wi, [R("span", null, J(f.value) + " filters", 1), R("button", {
3481
3481
  type: "button",
3482
3482
  "aria-label": "Close filter details",
3483
- onClick: r[2] ||= (e) => f.value = null
3484
- }, [...r[14] ||= [R("i", { class: "mdi mdi-close" }, null, -1)]])]), R("div", Ti, [(W(!0), L(N, null, K(fe.value, (e, t) => (W(), L("div", {
3483
+ onClick: i[2] ||= (e) => f.value = null
3484
+ }, [...i[14] ||= [R("i", { class: "mdi mdi-close" }, null, -1)]])]), R("div", Ti, [(W(!0), L(N, null, K(fe.value, (e, t) => (W(), L("div", {
3485
3485
  key: `${e.source}-${t}`,
3486
3486
  class: "mobile-filter-popover-value"
3487
3487
  }, J(h(e.value, e.parameters)), 1))), 128))])], 12, Ci)) : I("", !0)]))], 64));
@@ -3493,70 +3493,70 @@ var Vr = /*#__PURE__*/ e(Pr, [["render", Br], ["__scopeId", "data-v-da53ca6d"]])
3493
3493
  }, ki = ["data-testid"], Ai = ["value", "data-testid"], ji = { class: "item-option-card" }, Mi = {
3494
3494
  class: "item-option-icon",
3495
3495
  "aria-hidden": "true"
3496
- }, Ni = { class: "item-option-text" }, Pi = { class: "item-option-label" }, Fi = { class: "item-option-help" }, Ii = /*#__PURE__*/ e(/* @__PURE__ */ V({
3496
+ }, Ni = { class: "item-option-text" }, Pi = { class: "item-option-label" }, Fi = { class: "item-option-help" }, Ii = /*#__PURE__*/ d(/* @__PURE__ */ V({
3497
3497
  __name: "DashboardAddItemModal",
3498
3498
  props: { show: { type: Boolean } },
3499
3499
  emits: ["add", "close"],
3500
3500
  setup(e, { emit: t }) {
3501
- let n = t, r = G(a.CHART), i = [
3501
+ let r = t, i = G(n.CHART), a = [
3502
3502
  {
3503
- value: a.CHART,
3503
+ value: n.CHART,
3504
3504
  label: "Chart",
3505
3505
  description: "Visualize trends, comparisons, and distributions.",
3506
3506
  icon: "mdi-chart-bar",
3507
3507
  testId: "dashboard-add-item-type-chart"
3508
3508
  },
3509
3509
  {
3510
- value: a.TABLE,
3510
+ value: n.TABLE,
3511
3511
  label: "Table",
3512
3512
  description: "Show detailed rows and values in a grid.",
3513
3513
  icon: "mdi-table-large",
3514
3514
  testId: "dashboard-add-item-type-table"
3515
3515
  },
3516
3516
  {
3517
- value: a.MARKDOWN,
3517
+ value: n.MARKDOWN,
3518
3518
  label: "Markdown",
3519
3519
  description: "Add notes, headings, or narrative context.",
3520
3520
  icon: "mdi-text-box-outline",
3521
3521
  testId: "dashboard-add-item-type-markdown"
3522
3522
  },
3523
3523
  {
3524
- value: a.FILTER,
3524
+ value: n.FILTER,
3525
3525
  label: "Filter",
3526
3526
  description: "Let viewers narrow the dashboard interactively.",
3527
3527
  icon: "mdi-filter-variant",
3528
3528
  testId: "dashboard-add-item-type-filter"
3529
3529
  },
3530
3530
  {
3531
- value: a.FREEFORM,
3531
+ value: n.FREEFORM,
3532
3532
  label: "Custom Widget",
3533
3533
  description: "Hand-authored HTML rendered in a sandboxed frame, wired to a query.",
3534
3534
  icon: "mdi-code-braces",
3535
3535
  testId: "dashboard-add-item-type-freeform"
3536
3536
  },
3537
3537
  {
3538
- value: a.SECTION_HEADER,
3538
+ value: n.SECTION_HEADER,
3539
3539
  label: "Section Header",
3540
3540
  description: "Break the dashboard into labeled sections.",
3541
3541
  icon: "mdi-format-title",
3542
3542
  testId: "dashboard-add-item-type-section-header"
3543
3543
  },
3544
3544
  {
3545
- value: a.MEMO,
3545
+ value: n.MEMO,
3546
3546
  label: "Executive Memo",
3547
3547
  description: "Headline, verdict, magnitude, cause, action, confidence — at the top of a report.",
3548
3548
  icon: "mdi-file-document-edit-outline",
3549
3549
  testId: "dashboard-add-item-type-memo"
3550
3550
  },
3551
3551
  {
3552
- value: a.CLAIM,
3552
+ value: n.CLAIM,
3553
3553
  label: "Claim Section",
3554
3554
  description: "A single claim with caveat and drilldown — pair with a chart for evidence.",
3555
3555
  icon: "mdi-comment-quote-outline",
3556
3556
  testId: "dashboard-add-item-type-claim"
3557
3557
  },
3558
3558
  {
3559
- value: a.APPENDIX_HEADER,
3559
+ value: n.APPENDIX_HEADER,
3560
3560
  label: "Appendix Header",
3561
3561
  description: "Divider that introduces the auditability section at the bottom of a report.",
3562
3562
  icon: "mdi-bookshelf",
@@ -3564,12 +3564,12 @@ var Vr = /*#__PURE__*/ e(Pr, [["render", Br], ["__scopeId", "data-v-da53ca6d"]])
3564
3564
  }
3565
3565
  ];
3566
3566
  function o() {
3567
- n("add", r.value);
3567
+ r("add", i.value);
3568
3568
  }
3569
3569
  function s() {
3570
- n("close");
3570
+ r("close");
3571
3571
  }
3572
- return (t, n) => (W(), F(A, {
3572
+ return (t, n) => (W(), F(se, {
3573
3573
  show: e.show,
3574
3574
  title: "Add New Item",
3575
3575
  "max-width": "680px",
@@ -3584,18 +3584,18 @@ var Vr = /*#__PURE__*/ e(Pr, [["render", Br], ["__scopeId", "data-v-da53ca6d"]])
3584
3584
  class: "add-button",
3585
3585
  "data-testid": "dashboard-add-item-confirm"
3586
3586
  }, " Add Item ")]),
3587
- default: Z(() => [R("div", Di, [n[1] ||= R("p", { class: "add-item-description" }, "Choose the kind of block you want to add to the dashboard.", -1), R("div", Oi, [(W(), L(N, null, K(i, (e) => R("label", {
3587
+ default: Z(() => [R("div", Di, [n[1] ||= R("p", { class: "add-item-description" }, "Choose the kind of block you want to add to the dashboard.", -1), R("div", Oi, [(W(), L(N, null, K(a, (e) => R("label", {
3588
3588
  key: e.value,
3589
- class: U(["item-option", { selected: r.value === e.value }]),
3589
+ class: U(["item-option", { selected: i.value === e.value }]),
3590
3590
  "data-testid": `${e.testId}-option`
3591
3591
  }, [je(R("input", {
3592
- "onUpdate:modelValue": n[0] ||= (e) => r.value = e,
3592
+ "onUpdate:modelValue": n[0] ||= (e) => i.value = e,
3593
3593
  class: "item-option-input",
3594
3594
  type: "radio",
3595
3595
  name: "dashboard-add-item-type",
3596
3596
  value: e.value,
3597
3597
  "data-testid": e.testId
3598
- }, null, 8, Ai), [[Oe, r.value]]), R("span", ji, [R("span", Mi, [R("i", { class: U(["mdi", e.icon]) }, null, 2)]), R("span", Ni, [R("span", Pi, J(e.label), 1), R("span", Fi, J(e.description), 1)])])], 10, ki)), 64))])])]),
3598
+ }, null, 8, Ai), [[Oe, i.value]]), R("span", ji, [R("span", Mi, [R("i", { class: U(["mdi", e.icon]) }, null, 2)]), R("span", Ni, [R("span", Pi, J(e.label), 1), R("span", Fi, J(e.description), 1)])])], 10, ki)), 64))])])]),
3599
3599
  _: 1
3600
3600
  }, 8, ["show"]));
3601
3601
  }
@@ -3700,7 +3700,7 @@ var Q = null, Vi = V({
3700
3700
  data() {
3701
3701
  return {
3702
3702
  lastOperation: null,
3703
- editor: new w({
3703
+ editor: new y({
3704
3704
  id: "simple-editor",
3705
3705
  name: "My Query",
3706
3706
  type: "trilogy",
@@ -3719,7 +3719,7 @@ var Q = null, Vi = V({
3719
3719
  isMobile: H("isMobile"),
3720
3720
  llmConnectionStore: H("llmConnectionStore"),
3721
3721
  analyticsStore: H("analyticsStore"),
3722
- userSettingsStore: u()
3722
+ userSettingsStore: D()
3723
3723
  };
3724
3724
  },
3725
3725
  created() {
@@ -3838,33 +3838,33 @@ var Q = null, Vi = V({
3838
3838
  },
3839
3839
  async runQuery() {
3840
3840
  this.$emit("query-started"), this.editor.setError(null);
3841
- let e = !1, t = this.connectionStore, n = this.queryExecutionService, i = Q;
3842
- if (!this.editor.loading && i) try {
3841
+ let e = !1, t = this.connectionStore, n = this.queryExecutionService, r = Q;
3842
+ if (!this.editor.loading && r) try {
3843
3843
  this.analyticsStore && this.analyticsStore.log("studio-query-execution", this.editor.type, !0), this.editor.loading = !0, this.lastOperation = null, this.editor.startTime = Date.now();
3844
- let a = this.editor.connectionId && t.connections[this.editor.connectionId] || t.connectionByName(this.editor.connection), o = zi(i, this.editor.contents);
3845
- if (!o) {
3846
- this.editor.results = new r(/* @__PURE__ */ new Map(), []), this.editor.loading = !1;
3844
+ let i = this.editor.connectionId && t.connections[this.editor.connectionId] || t.connectionByName(this.editor.connection), a = zi(r, this.editor.contents);
3845
+ if (!a) {
3846
+ this.editor.results = new m(/* @__PURE__ */ new Map(), []), this.editor.loading = !1;
3847
3847
  return;
3848
3848
  }
3849
- let s = {
3850
- text: o,
3851
- queryType: a ? a.query_type : "",
3849
+ let o = {
3850
+ text: a,
3851
+ queryType: i ? i.query_type : "",
3852
3852
  editorType: this.editor.type,
3853
3853
  imports: this.imports,
3854
3854
  extraContent: this.rootContent
3855
- }, { resultPromise: c, cancellation: l } = await n.executeQuery(a?.id || this.editor.connection, s, () => {}, (t) => {
3855
+ }, { resultPromise: s, cancellation: c } = await n.executeQuery(i?.id || this.editor.connection, o, () => {}, (t) => {
3856
3856
  !e && t.error && (this.editor.loading = !1, t.message && this.editor.setError(t.message)), !e && t.running && (this.editor.error = null, this.editor.loading = !0);
3857
3857
  });
3858
3858
  this.editor.cancelCallback = () => {
3859
- l.isActive() && l.cancel(), this.editor.loading = !1, this.editor.cancelCallback = null;
3859
+ c.isActive() && c.cancel(), this.editor.loading = !1, this.editor.cancelCallback = null;
3860
3860
  };
3861
- let u = await c;
3861
+ let l = await s;
3862
3862
  e = !0, this.lastOperation = {
3863
- success: u.success,
3864
- duration: u.executionTime,
3865
- rows: u.results?.data ? u.results?.data?.length : void 0,
3863
+ success: l.success,
3864
+ duration: l.executionTime,
3865
+ rows: l.results?.data ? l.results?.data?.length : void 0,
3866
3866
  type: this.editor.type
3867
- }, u.success ? (this.editor.executed_contents = o, u.generatedSql && (this.editor.generated_sql = u.generatedSql), u.results && (this.editor.results = u.results, this.editor.duration = u.executionTime)) : u.error && (this.editor.executed_contents = o, this.editor.setError(u.error));
3867
+ }, l.success ? (this.editor.executed_contents = a, l.generatedSql && (this.editor.generated_sql = l.generatedSql), l.results && (this.editor.results = l.results, this.editor.duration = l.executionTime)) : l.error && (this.editor.executed_contents = a, this.editor.setError(l.error));
3868
3868
  } catch (e) {
3869
3869
  e instanceof Error && this.editor.setError(e.message || "Query execution failed"), this.lastOperation = {
3870
3870
  success: !1,
@@ -3883,15 +3883,15 @@ var Q = null, Vi = V({
3883
3883
  return;
3884
3884
  }
3885
3885
  try {
3886
- this.analyticsStore && this.analyticsStore.log("studio-llm-generation", this.editor.type, !0), this.editor.loading = !0, this.editor.startTime = Date.now(), this.editor.results = new r(/* @__PURE__ */ new Map(), []), this.editor.setError(null);
3887
- let i = Q.getValue();
3886
+ this.analyticsStore && this.analyticsStore.log("studio-llm-generation", this.editor.type, !0), this.editor.loading = !0, this.editor.startTime = Date.now(), this.editor.results = new m(/* @__PURE__ */ new Map(), []), this.editor.setError(null);
3887
+ let r = Q.getValue();
3888
3888
  if (await this.validateQuery(!1), !this.editor.completionSymbols || this.editor.completionSymbols.length === 0) throw Error("There are no imported concepts for LLM generation");
3889
- let a = this.editor.completionSymbols.map((e) => ({
3889
+ let i = this.editor.completionSymbols.map((e) => ({
3890
3890
  name: e.label,
3891
3891
  type: e.datatype,
3892
3892
  description: e.description,
3893
3893
  calculation: e.calculation
3894
- })), o = await e.generateQueryCompletion(i, a, async (e) => {
3894
+ })), a = await e.generateQueryCompletion(r, i, async (e) => {
3895
3895
  let r = this.editor.connectionId && n.connections[this.editor.connectionId] || n.connectionByName(this.editor.connection), i = {
3896
3896
  text: e,
3897
3897
  queryType: r ? r.query_type : "",
@@ -3908,7 +3908,7 @@ var Q = null, Vi = V({
3908
3908
  throw e;
3909
3909
  }
3910
3910
  });
3911
- if (o) Q.setValue(o.content), this.editor.contents = Q.getValue(), this.lastOperation = {
3911
+ if (a) Q.setValue(a.content), this.editor.contents = Q.getValue(), this.lastOperation = {
3912
3912
  success: !0,
3913
3913
  duration: Date.now() - (this.editor.startTime || 0),
3914
3914
  type: "LLM Generation"
@@ -4008,7 +4008,7 @@ function na(e, t, n, r, i, a) {
4008
4008
  ])])) : I("", !0)])
4009
4009
  ]);
4010
4010
  }
4011
- var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]]), ia = { class: "editor-overlay" }, aa = { class: "editor-actions" }, oa = ["data-testid"], sa = /*#__PURE__*/ e(/* @__PURE__ */ V({
4011
+ var ra = /*#__PURE__*/ d(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]]), ia = { class: "editor-overlay" }, aa = { class: "editor-actions" }, oa = ["data-testid"], sa = /*#__PURE__*/ d(/* @__PURE__ */ V({
4012
4012
  __name: "DashboardEditorDialog",
4013
4013
  props: {
4014
4014
  initialWidth: {},
@@ -4043,7 +4043,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4043
4043
  B(ve, { onStartResize: Y(o) }, null, 8, ["onStartResize"])
4044
4044
  ], 4)]));
4045
4045
  }
4046
- }), [["__scopeId", "data-v-730a6200"]]), ca = { class: "editor-body" }, la = /*#__PURE__*/ e(/* @__PURE__ */ V({
4046
+ }), [["__scopeId", "data-v-730a6200"]]), ca = { class: "editor-body" }, la = /*#__PURE__*/ d(/* @__PURE__ */ V({
4047
4047
  __name: "DashboardChartEditor",
4048
4048
  props: {
4049
4049
  content: {},
@@ -4093,7 +4093,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4093
4093
  }, pa = {
4094
4094
  key: 1,
4095
4095
  class: "tab-content"
4096
- }, ma = /*#__PURE__*/ e(/* @__PURE__ */ V({
4096
+ }, ma = /*#__PURE__*/ d(/* @__PURE__ */ V({
4097
4097
  __name: "DashboardMarkdownEditor",
4098
4098
  props: {
4099
4099
  content: {},
@@ -4245,7 +4245,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4245
4245
  }, ba = {
4246
4246
  key: 2,
4247
4247
  class: "tab-content api-tab"
4248
- }, xa = { class: "theme-list" }, Sa = /*#__PURE__*/ e(/* @__PURE__ */ V({
4248
+ }, xa = { class: "theme-list" }, Sa = /*#__PURE__*/ d(/* @__PURE__ */ V({
4249
4249
  __name: "DashboardFreeformEditor",
4250
4250
  props: {
4251
4251
  content: {},
@@ -4260,7 +4260,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4260
4260
  let n = e, r = t, i = P(() => ({
4261
4261
  html: n.content?.html || "",
4262
4262
  query: n.content?.query || ""
4263
- })), a = G(i.value.html), o = G(i.value.query), s = G(n.imports), c = G(null), l = G("html"), u = P(() => a.value.length > x), d = [
4263
+ })), a = G(i.value.html), o = G(i.value.query), s = G(n.imports), c = G(null), l = G("html"), u = P(() => a.value.length > g), d = [
4264
4264
  {
4265
4265
  name: "--widget-text",
4266
4266
  description: "primary text"
@@ -4353,7 +4353,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4353
4353
  placeholder: "Author a self-contained HTML fragment. Subscribe to trilogy state, render, then call trilogy.ready().",
4354
4354
  class: "html-editor"
4355
4355
  }, null, 512), [[ke, a.value]]),
4356
- u.value ? (W(), L("div", va, " Widget HTML is " + J(a.value.length.toLocaleString()) + " characters — the limit is " + J(Y(x).toLocaleString()) + ". Trim it before saving. ", 1)) : I("", !0)
4356
+ u.value ? (W(), L("div", va, " Widget HTML is " + J(a.value.length.toLocaleString()) + " characters — the limit is " + J(Y(g).toLocaleString()) + ". Trim it before saving. ", 1)) : I("", !0)
4357
4357
  ])) : I("", !0),
4358
4358
  l.value === "query" ? (W(), L("div", ya, [r[8] ||= R("div", { class: "editor-help" }, [R("p", null, " The query runs through the normal dashboard pipeline — global filters and cross-filters apply automatically. Its rows are pushed to the widget; the widget never issues queries of its own. ")], -1), B(ra, {
4359
4359
  class: "editor-content",
@@ -4429,7 +4429,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4429
4429
  r[13] ||= R("li", null, "No access to the parent page, and no popups, forms, or top-level navigation.", -1),
4430
4430
  R("li", null, [
4431
4431
  r[9] ||= z(" Libraries may be loaded from ", -1),
4432
- (W(!0), L(N, null, K(Y(ne), (e) => (W(), L("code", { key: e }, J(e), 1))), 128)),
4432
+ (W(!0), L(N, null, K(Y(E), (e) => (W(), L("code", { key: e }, J(e), 1))), 128)),
4433
4433
  r[10] ||= z(". ", -1)
4434
4434
  ])
4435
4435
  ])
@@ -4450,9 +4450,9 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4450
4450
  "start-chat-with-prompt"
4451
4451
  ],
4452
4452
  setup(e, { emit: t }) {
4453
- let n = H("dashboardStore"), r = H("llmConnectionStore"), i = H("saveDashboards");
4454
- if (!n || !r || !i) throw Error("DashboardStore or LLMConnectionStore not provided");
4455
- let o = e, s = P(() => r.activeConnection), c = t, l = G(""), u = G(""), d = G(null), f = $ / 4, p = [
4453
+ let r = H("dashboardStore"), i = H("llmConnectionStore"), a = H("saveDashboards");
4454
+ if (!r || !i || !a) throw Error("DashboardStore or LLMConnectionStore not provided");
4455
+ let o = e, s = P(() => i.activeConnection), c = t, l = G(""), u = G(""), d = G(null), f = $ / 4, p = [
4456
4456
  {
4457
4457
  id: "summary",
4458
4458
  name: "Summary Dashboard",
@@ -4465,7 +4465,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4465
4465
  y: 0,
4466
4466
  w: $,
4467
4467
  h: 3,
4468
- type: a.MARKDOWN
4468
+ type: n.MARKDOWN
4469
4469
  },
4470
4470
  {
4471
4471
  i: "kpi1",
@@ -4473,7 +4473,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4473
4473
  y: 3,
4474
4474
  w: $ / 4,
4475
4475
  h: 4,
4476
- type: a.CHART
4476
+ type: n.CHART
4477
4477
  },
4478
4478
  {
4479
4479
  i: "kpi2",
@@ -4481,7 +4481,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4481
4481
  y: 3,
4482
4482
  w: $ / 4,
4483
4483
  h: 4,
4484
- type: a.CHART
4484
+ type: n.CHART
4485
4485
  },
4486
4486
  {
4487
4487
  i: "kpi3",
@@ -4489,7 +4489,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4489
4489
  y: 3,
4490
4490
  w: $ / 4,
4491
4491
  h: 4,
4492
- type: a.CHART
4492
+ type: n.CHART
4493
4493
  },
4494
4494
  {
4495
4495
  i: "kpi4",
@@ -4497,7 +4497,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4497
4497
  y: 3,
4498
4498
  w: $ / 4,
4499
4499
  h: 4,
4500
- type: a.CHART
4500
+ type: n.CHART
4501
4501
  },
4502
4502
  {
4503
4503
  i: "trend",
@@ -4505,7 +4505,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4505
4505
  y: 7,
4506
4506
  w: $ / 2,
4507
4507
  h: 8,
4508
- type: a.CHART
4508
+ type: n.CHART
4509
4509
  },
4510
4510
  {
4511
4511
  i: "breakdown",
@@ -4513,7 +4513,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4513
4513
  y: 7,
4514
4514
  w: $ / 2,
4515
4515
  h: 8,
4516
- type: a.CHART
4516
+ type: n.CHART
4517
4517
  }
4518
4518
  ]
4519
4519
  },
@@ -4529,7 +4529,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4529
4529
  y: 0,
4530
4530
  w: $,
4531
4531
  h: 3,
4532
- type: a.MARKDOWN
4532
+ type: n.MARKDOWN
4533
4533
  },
4534
4534
  {
4535
4535
  i: "overview",
@@ -4537,7 +4537,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4537
4537
  y: 3,
4538
4538
  w: $,
4539
4539
  h: 5,
4540
- type: a.CHART
4540
+ type: n.CHART
4541
4541
  },
4542
4542
  {
4543
4543
  i: "detail1",
@@ -4545,7 +4545,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4545
4545
  y: 8,
4546
4546
  w: $ / 2,
4547
4547
  h: 8,
4548
- type: a.CHART
4548
+ type: n.CHART
4549
4549
  },
4550
4550
  {
4551
4551
  i: "detail2",
@@ -4553,7 +4553,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4553
4553
  y: 10,
4554
4554
  w: $ / 2,
4555
4555
  h: 8,
4556
- type: a.CHART
4556
+ type: n.CHART
4557
4557
  },
4558
4558
  {
4559
4559
  i: "datatable",
@@ -4561,7 +4561,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4561
4561
  y: 20,
4562
4562
  w: $,
4563
4563
  h: 8,
4564
- type: a.TABLE
4564
+ type: n.TABLE
4565
4565
  }
4566
4566
  ]
4567
4567
  },
@@ -4577,7 +4577,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4577
4577
  y: 0,
4578
4578
  w: $,
4579
4579
  h: 3,
4580
- type: a.MARKDOWN
4580
+ type: n.MARKDOWN
4581
4581
  },
4582
4582
  {
4583
4583
  i: "compare1",
@@ -4585,7 +4585,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4585
4585
  y: 3,
4586
4586
  w: $ / 2,
4587
4587
  h: 6,
4588
- type: a.CHART
4588
+ type: n.CHART
4589
4589
  },
4590
4590
  {
4591
4591
  i: "compare2",
@@ -4593,7 +4593,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4593
4593
  y: 3,
4594
4594
  w: $ / 2,
4595
4595
  h: 6,
4596
- type: a.CHART
4596
+ type: n.CHART
4597
4597
  },
4598
4598
  {
4599
4599
  i: "compare3",
@@ -4601,7 +4601,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4601
4601
  y: 9,
4602
4602
  w: $ / 2,
4603
4603
  h: 6,
4604
- type: a.CHART
4604
+ type: n.CHART
4605
4605
  },
4606
4606
  {
4607
4607
  i: "compare4",
@@ -4609,7 +4609,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4609
4609
  y: 9,
4610
4610
  w: $ / 2,
4611
4611
  h: 6,
4612
- type: a.CHART
4612
+ type: n.CHART
4613
4613
  },
4614
4614
  {
4615
4615
  i: "summary",
@@ -4617,7 +4617,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4617
4617
  y: 15,
4618
4618
  w: $,
4619
4619
  h: 5,
4620
- type: a.MARKDOWN
4620
+ type: n.MARKDOWN
4621
4621
  }
4622
4622
  ]
4623
4623
  },
@@ -4633,7 +4633,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4633
4633
  y: 0,
4634
4634
  w: $,
4635
4635
  h: 3,
4636
- type: a.MARKDOWN
4636
+ type: n.MARKDOWN
4637
4637
  },
4638
4638
  {
4639
4639
  i: "maintrend",
@@ -4641,7 +4641,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4641
4641
  y: 3,
4642
4642
  w: $,
4643
4643
  h: 8,
4644
- type: a.CHART
4644
+ type: n.CHART
4645
4645
  },
4646
4646
  {
4647
4647
  i: "breakdown1",
@@ -4649,7 +4649,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4649
4649
  y: 11,
4650
4650
  w: $ / 3,
4651
4651
  h: 6,
4652
- type: a.CHART
4652
+ type: n.CHART
4653
4653
  },
4654
4654
  {
4655
4655
  i: "breakdown2",
@@ -4657,7 +4657,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4657
4657
  y: 11,
4658
4658
  w: $ / 3,
4659
4659
  h: 6,
4660
- type: a.CHART
4660
+ type: n.CHART
4661
4661
  },
4662
4662
  {
4663
4663
  i: "breakdown3",
@@ -4665,7 +4665,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4665
4665
  y: 11,
4666
4666
  w: $ / 3,
4667
4667
  h: 6,
4668
- type: a.CHART
4668
+ type: n.CHART
4669
4669
  },
4670
4670
  {
4671
4671
  i: "forecast",
@@ -4673,7 +4673,7 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4673
4673
  y: 17,
4674
4674
  w: $,
4675
4675
  h: 6,
4676
- type: a.CHART
4676
+ type: n.CHART
4677
4677
  }
4678
4678
  ]
4679
4679
  }
@@ -4682,12 +4682,12 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4682
4682
  d.value = e;
4683
4683
  let t = p.find((t) => t.id === e);
4684
4684
  if (t && o.dashboardId) {
4685
- for (let e of t.layout) n.addItemToDashboard(o.dashboardId, e.type, e.x, e.y, e.w, e.h);
4685
+ for (let e of t.layout) r.addItemToDashboard(o.dashboardId, e.type, e.x, e.y, e.w, e.h);
4686
4686
  c("template-selected", e);
4687
4687
  }
4688
4688
  }
4689
4689
  function h() {
4690
- o.dashboardId && l.value && (n.updateDashboardDescription(o.dashboardId, l.value), c("description-updated", l.value));
4690
+ o.dashboardId && l.value && (r.updateDashboardDescription(o.dashboardId, l.value), c("description-updated", l.value));
4691
4691
  }
4692
4692
  function g() {
4693
4693
  let e = u.value.trim();
@@ -4738,39 +4738,39 @@ var ra = /*#__PURE__*/ e(Vi, [["render", na], ["__scopeId", "data-v-79e13368"]])
4738
4738
  });
4739
4739
  //#endregion
4740
4740
  //#region components/dashboard/useDashboard.ts
4741
- function La(e, t, n, r) {
4742
- let i = y(), c = re(), l = b(), u = r || H("queryExecutionService"), { setActiveDashboard: d } = g();
4741
+ function La(e, r, i, a) {
4742
+ let o = re(), c = ee(), l = h(), u = a || H("queryExecutionService"), { setActiveDashboard: d } = k();
4743
4743
  if (!u) throw Error("QueryExecutionService not provided");
4744
- let f = G(""), p = G(""), m = G(""), h = G(null), v = G(null), x = G(!1), w = G(!1), T = G(!1), E = G(!1), te = G([]), O = P(() => t.maxWidth || "100vw"), ne = P(() => e.value ? e.value.layout : []), ae = P(() => e.value ? [...e.value.layout].sort((e, t) => (e.y + e.y + e.h) / 2 - (t.y + t.y + t.h) / 2) : []), oe = P(() => e.value ? e.value.connectionId ? e.value.connectionId : l.connectionByName(e.value.connection)?.id || e.value.connection : ""), k = P(() => t.viewMode ? !1 : e.value ? e.value.state === "editing" : !1), A = P(() => e.value ? C(e.value, c) : []);
4744
+ let f = G(""), p = G(""), m = G(""), g = G(null), y = G(null), x = G(!1), S = G(!1), C = G(!1), T = G(!1), E = G([]), D = P(() => r.maxWidth || "100vw"), ne = P(() => e.value ? e.value.layout : []), ie = P(() => e.value ? [...e.value.layout].sort((e, t) => (e.y + e.y + e.h) / 2 - (t.y + t.y + t.h) / 2) : []), ae = P(() => e.value ? e.value.connectionId ? e.value.connectionId : l.connectionByName(e.value.connection)?.id || e.value.connection : ""), oe = P(() => r.viewMode ? !1 : e.value ? e.value.state === "editing" : !1), A = P(() => e.value ? v(e.value, c) : []);
4745
4745
  function se(e) {
4746
4746
  if (!e?.id) return;
4747
- e.state === "fullscreen" && n.fullScreen(!0), i.setActiveDashboard(e.id), m.value = "", f.value = "", p.value = "", te.value = [], e.filter && (f.value = e.filter, p.value = e.filter);
4748
- let t = z(e.id), r = Object.keys(e.gridItems).filter((t) => e.gridItems[t].type !== a.SECTION_HEADER && !e.gridItems[t].results);
4747
+ e.state === "fullscreen" && i.fullScreen(!0), o.setActiveDashboard(e.id), m.value = "", f.value = "", p.value = "", E.value = [], e.filter && (f.value = e.filter, p.value = e.filter);
4748
+ let t = z(e.id), r = Object.keys(e.gridItems).filter((t) => e.gridItems[t].type !== n.SECTION_HEADER && !e.gridItems[t].results);
4749
4749
  t?.runBatch(r), ue();
4750
4750
  }
4751
4751
  X(() => e.value?.id, (t, n) => {
4752
4752
  t && t !== n && e.value && se(e.value);
4753
4753
  }), we(() => {
4754
4754
  e.value && se(e.value);
4755
- let r = new ResizeObserver(() => {
4756
- n.triggerResize();
4757
- }), i = t.isMobile ? ".mobile-container" : ".grid-container", a = document.querySelector(i);
4758
- a && r.observe(a);
4755
+ let t = new ResizeObserver(() => {
4756
+ i.triggerResize();
4757
+ }), n = r.isMobile ? ".mobile-container" : ".grid-container", a = document.querySelector(n);
4758
+ a && t.observe(a);
4759
4759
  }), Ce(() => {
4760
- h.value !== null && clearTimeout(h.value);
4760
+ g.value !== null && clearTimeout(g.value);
4761
4761
  });
4762
4762
  async function ce() {
4763
4763
  if (e.value && e.value.id) {
4764
4764
  f.value = "", p.value = "", m.value = "";
4765
- let t = i.removeAllFilters(e.value.id);
4766
- await i.getQueryExecutor(e.value.id)?.runBatch(t);
4765
+ let t = o.removeAllFilters(e.value.id);
4766
+ await o.getQueryExecutor(e.value.id)?.runBatch(t);
4767
4767
  }
4768
4768
  }
4769
- async function j(t) {
4770
- if (!t || _(t) === "") {
4769
+ async function le(t) {
4770
+ if (!t || te(t) === "") {
4771
4771
  if (m.value = "", e.value && e.value.id) {
4772
- let n = i.updateDashboardFilter(e.value.id, _(t));
4773
- await i.getQueryExecutor(e.value.id)?.runBatch(n);
4772
+ let n = o.updateDashboardFilter(e.value.id, te(t));
4773
+ await o.getQueryExecutor(e.value.id)?.runBatch(n);
4774
4774
  }
4775
4775
  return;
4776
4776
  }
@@ -4782,12 +4782,12 @@ function La(e, t, n, r) {
4782
4782
  extraContent: A.value
4783
4783
  }).then(() => {
4784
4784
  if (m.value = "", e.value && e.value.id) {
4785
- let n = i.updateDashboardFilter(e.value.id, t);
4786
- i.getQueryExecutor(e.value.id)?.runBatch(n);
4785
+ let n = o.updateDashboardFilter(e.value.id, t);
4786
+ o.getQueryExecutor(e.value.id)?.runBatch(n);
4787
4787
  }
4788
4788
  }).catch((e) => (m.value = e.message, !1)));
4789
4789
  }
4790
- let le = async (t) => {
4790
+ let j = async (t) => {
4791
4791
  let n = t.replace(/^\s*where\s+/i, "");
4792
4792
  if (e.value && e.value.id) {
4793
4793
  let t = await u?.executeQuery(e.value.connectionId || e.value.connection, {
@@ -4804,63 +4804,63 @@ function La(e, t, n, r) {
4804
4804
  };
4805
4805
  async function ue() {
4806
4806
  if (e.value && e.value.id && u) {
4807
- let t = await i.populateCompletion(e.value.id, u, c);
4808
- t && (te.value = t), m.value = "";
4807
+ let t = await o.populateCompletion(e.value.id, u, c);
4808
+ t && (E.value = t), m.value = "";
4809
4809
  }
4810
4810
  }
4811
4811
  async function de(t) {
4812
- e.value && e.value.id && (i.updateDashboardImports(e.value.id, t), await ue());
4812
+ e.value && e.value.id && (o.updateDashboardImports(e.value.id, t), await ue());
4813
4813
  }
4814
4814
  let fe = (t) => {
4815
- e.value && (i.setState(e.value.id, t), xe(() => {
4816
- n.triggerResize();
4815
+ e.value && (o.setState(e.value.id, t), xe(() => {
4816
+ i.triggerResize();
4817
4817
  }));
4818
4818
  }, pe = (t) => {
4819
- e.value && e.value.id && i.updateDashboardLayout(e.value.id, t);
4819
+ e.value && e.value.id && o.updateDashboardLayout(e.value.id, t);
4820
4820
  };
4821
4821
  function me() {
4822
- E.value = !0;
4822
+ T.value = !0;
4823
4823
  }
4824
- function he(t = a.CHART) {
4824
+ function he(t = n.CHART) {
4825
4825
  if (!e.value || !e.value.id) return;
4826
- let r = t === a.SECTION_HEADER ? i.addItemToDashboard(e.value.id, t, 0, 0, 20, 1) : i.addItemToDashboard(e.value.id, t);
4827
- E.value = !1, xe(() => {
4828
- n.dimensionsUpdate(r);
4826
+ let r = t === n.SECTION_HEADER ? o.addItemToDashboard(e.value.id, t, 0, 0, 20, 1) : o.addItemToDashboard(e.value.id, t);
4827
+ T.value = !1, xe(() => {
4828
+ i.dimensionsUpdate(r);
4829
4829
  });
4830
4830
  }
4831
4831
  function M(t) {
4832
- e.value && e.value.id && i.updateDashboardTitle(e.value.id, t);
4832
+ e.value && e.value.id && o.updateDashboardTitle(e.value.id, t);
4833
4833
  }
4834
4834
  function ge(t) {
4835
- e.value && e.value.id && i.setDashboardTheme(e.value.id, t);
4835
+ e.value && e.value.id && o.setDashboardTheme(e.value.id, t);
4836
4836
  }
4837
4837
  function _e() {
4838
- e.value && e.value.id && i.clearDashboardItems(e.value.id);
4838
+ e.value && e.value.id && o.clearDashboardItems(e.value.id);
4839
4839
  }
4840
4840
  function ve(t) {
4841
- e.value && e.value.id && i.removeItemFromDashboard(e.value.id, t);
4841
+ e.value && e.value.id && o.removeItemFromDashboard(e.value.id, t);
4842
4842
  }
4843
4843
  function ye(t) {
4844
- e.value && e.value.id && i.copyItemInDashboard(e.value.id, t);
4844
+ e.value && e.value.id && o.copyItemInDashboard(e.value.id, t);
4845
4845
  }
4846
4846
  function N() {
4847
- E.value = !1;
4847
+ T.value = !1;
4848
4848
  }
4849
4849
  function be(t) {
4850
- if (v.value = t, !e.value || !e.value.id) return;
4851
- let n = e.value.gridItems[t.i];
4852
- n && (n.type === a.CHART ? x.value = !0 : n.type === a.MARKDOWN ? w.value = !0 : n.type === a.TABLE || n.type === a.FILTER ? x.value = !0 : n.type === a.FREEFORM ? T.value = !0 : n.type === a.SECTION_HEADER && (v.value = null));
4850
+ if (y.value = t, !e.value || !e.value.id) return;
4851
+ let r = e.value.gridItems[t.i];
4852
+ r && (r.type === n.CHART ? x.value = !0 : r.type === n.MARKDOWN ? S.value = !0 : r.type === n.TABLE || r.type === n.FILTER ? x.value = !0 : r.type === n.FREEFORM ? C.value = !0 : r.type === n.SECTION_HEADER && (y.value = null));
4853
4853
  }
4854
4854
  function F(t) {
4855
- if (!e.value || !e.value.id || !v.value) return;
4856
- let n = v.value.i;
4855
+ if (!e.value || !e.value.id || !y.value) return;
4856
+ let n = y.value.i;
4857
4857
  R(n, e.value.id, { content: t }), I();
4858
4858
  }
4859
4859
  function I() {
4860
- x.value = !1, w.value = !1, T.value = !1, v.value = null;
4860
+ x.value = !1, S.value = !1, C.value = !1, y.value = null;
4861
4861
  }
4862
4862
  function L(t, n) {
4863
- return n && e.value && e.value.id !== n || !e.value ? ee(t) : ie(e.value, t, {
4863
+ return n && e.value && e.value.id !== n || !e.value ? b(t) : O(e.value, t, {
4864
4864
  rootContent: A.value,
4865
4865
  onRefresh: V
4866
4866
  });
@@ -4871,52 +4871,52 @@ function La(e, t, n, r) {
4871
4871
  console.warn("Dashboard ID mismatch. Cannot set item data. Given:", n, "Expected:", e.value.id);
4872
4872
  return;
4873
4873
  }
4874
- D(i, e.value.id, t, r), r.content && z(e.value.id)?.runSingle(t);
4874
+ w(o, e.value.id, t, r), r.content && z(e.value.id)?.runSingle(t);
4875
4875
  }
4876
4876
  }
4877
4877
  function z(t) {
4878
4878
  if (!e.value || !e.value.id) throw Error("Dashboard not found or not initialized");
4879
4879
  if (!u) throw Error("Query execution service not found");
4880
- let n = i.dashboards[t], r = S(n, l), a = i.getOrCreateQueryExecutor(t, {
4880
+ let n = o.dashboards[t], r = _(n, l), i = o.getOrCreateQueryExecutor(t, {
4881
4881
  queryExecutionService: u,
4882
4882
  connectionName: r,
4883
4883
  dashboardId: t,
4884
- getDashboardData: (e) => i.dashboards[e],
4884
+ getDashboardData: (e) => o.dashboards[e],
4885
4885
  getItemData: L,
4886
4886
  setItemData: R
4887
4887
  });
4888
- return a || console.warn("No query executor found for dashboard:", e.value.id), a;
4888
+ return i || console.warn("No query executor found for dashboard:", e.value.id), i;
4889
4889
  }
4890
4890
  function B(t) {
4891
4891
  let n = t.target.value;
4892
- e.value && e.value.id && (i.updateDashboardConnection(e.value.id, n), i.getQueryExecutor(e.value.id)?.setConnection(n));
4892
+ e.value && e.value.id && (o.updateDashboardConnection(e.value.id, n), o.getQueryExecutor(e.value.id)?.setConnection(n));
4893
4893
  }
4894
4894
  function V(t) {
4895
4895
  if (e.value) {
4896
4896
  if (t) {
4897
- let r = i.getQueryExecutor(e.value.id)?.runSingle(t);
4898
- return n.dimensionsUpdate(t), r ?? void 0;
4897
+ let n = o.getQueryExecutor(e.value.id)?.runSingle(t);
4898
+ return i.dimensionsUpdate(t), n ?? void 0;
4899
4899
  }
4900
- i.getQueryExecutor(e.value.id)?.runBatch(Object.keys(e.value.gridItems));
4900
+ o.getQueryExecutor(e.value.id)?.runBatch(Object.keys(e.value.gridItems));
4901
4901
  }
4902
4902
  }
4903
- function U(t) {
4903
+ function U(n) {
4904
4904
  if (!e.value || !e.value.id) return;
4905
- let n = o(te.value), r = s(t.filters, n);
4906
- if (!r || Object.keys(r).length === 0) {
4907
- console.log("No valid filters to apply from cross-filter event, given ", t.filters, n);
4905
+ let r = s(E.value), i = t(n.filters, r);
4906
+ if (!i || Object.keys(i).length === 0) {
4907
+ console.log("No valid filters to apply from cross-filter event, given ", n.filters, r);
4908
4908
  return;
4909
4909
  }
4910
- let a = i.updateItemCrossFilters(e.value.id, t.source, r, t.chart, t.append ? "append" : "add");
4911
- i.getQueryExecutor(e.value.id)?.runBatch(a);
4910
+ let a = o.updateItemCrossFilters(e.value.id, n.source, i, n.chart, n.append ? "append" : "add");
4911
+ o.getQueryExecutor(e.value.id)?.runBatch(a);
4912
4912
  }
4913
4913
  function Se(t, n) {
4914
- e.value && e.value.id && (i.removeItemCrossFilter(e.value.id, t, n), i.getQueryExecutor(e.value.id)?.runSingle(t));
4914
+ e.value && e.value.id && (o.removeItemCrossFilter(e.value.id, t, n), o.getQueryExecutor(e.value.id)?.runSingle(t));
4915
4915
  }
4916
4916
  function Te(t) {
4917
4917
  if (!e.value || !e.value.id) return;
4918
- let n = i.removeItemCrossFilterSource(e.value.id, t);
4919
- i.getQueryExecutor(e.value.id)?.runBatch(n);
4918
+ let n = o.removeItemCrossFilterSource(e.value.id, t);
4919
+ o.getQueryExecutor(e.value.id)?.runBatch(n);
4920
4920
  }
4921
4921
  function W(e) {
4922
4922
  d(e);
@@ -4924,23 +4924,23 @@ function La(e, t, n, r) {
4924
4924
  return {
4925
4925
  dashboard: e,
4926
4926
  layout: ne,
4927
- sortedLayout: ae,
4928
- editMode: k,
4929
- selectedConnection: oe,
4927
+ sortedLayout: ie,
4928
+ editMode: oe,
4929
+ selectedConnection: ae,
4930
4930
  filter: f,
4931
4931
  filterError: m,
4932
- globalCompletion: te,
4933
- showAddItemModal: E,
4932
+ globalCompletion: E,
4933
+ showAddItemModal: T,
4934
4934
  showQueryEditor: x,
4935
- showMarkdownEditor: w,
4936
- showFreeformEditor: T,
4937
- editingItem: v,
4938
- dashboardMaxWidth: O,
4935
+ showMarkdownEditor: S,
4936
+ showFreeformEditor: C,
4937
+ editingItem: y,
4938
+ dashboardMaxWidth: D,
4939
4939
  rootContent: A,
4940
- handleFilterChange: j,
4940
+ handleFilterChange: le,
4941
4941
  handleFilterClear: ce,
4942
4942
  handleImportChange: de,
4943
- validateFilter: le,
4943
+ validateFilter: j,
4944
4944
  onConnectionChange: B,
4945
4945
  toggleMode: fe,
4946
4946
  onLayoutUpdated: pe,