@trilogy-data/trilogy-studio-components 0.1.19 → 0.1.21
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.
- package/dist/{AssetAutoImporter-CUqhhNvb.js → AssetAutoImporter-IfDvXCFE.js} +5 -5
- package/dist/{ChatCreatorModal-CixOpWSH.js → ChatCreatorModal-BG6DyTV3.js} +2 -2
- package/dist/{CodeBlock-CDWXUAiQ.js → CodeBlock-Br-z9kG9.js} +1 -1
- package/dist/{CommunityModels-BKBxewjm.js → CommunityModels-DlK6gSx6.js} +7 -7
- package/dist/{ConfirmDialog-tNLC5CUN.js → ConfirmDialog-CYTEamQQ.js} +2 -2
- package/dist/{ConnectionView-Dyqm2oeV.js → ConnectionView-B_qlbq8s.js} +7 -7
- package/dist/{CreateEditorFromDatasourcePopup-D5mwCk5D.js → CreateEditorFromDatasourcePopup-bSSd8xci.js} +4 -4
- package/dist/{Dashboard-Bsoj1oUW.js → Dashboard-BN0T29JU.js} +1384 -1295
- package/dist/{DashboardCreatorInline-BLbkDxBF.js → DashboardCreatorInline-CPrHcaZC.js} +3 -3
- package/dist/{DashboardImportSelector-YRySr7k3.js → DashboardImportSelector-8mxsOld1.js} +1 -1
- package/dist/{DashboardMobile-Ao8NtF1f.js → DashboardMobile-BFcFiWhG.js} +4 -4
- package/dist/{DataTable-Bf7xeKSf.js → DataTable-CcALeEBZ.js} +2 -2
- package/dist/{DrilldownPane-OZMttRBx.js → DrilldownPane-oN6u9FSj.js} +6110 -6053
- package/dist/{Editor-N40lTR0s.js → Editor-BRnH6Fhm.js} +7 -7
- package/dist/{EditorCreatorInline-DCFnyl5w.js → EditorCreatorInline-BDWVUdax.js} +2 -2
- package/dist/{ErrorMessage-QW4GXCEn.js → ErrorMessage-BcAwiBgc.js} +1 -1
- package/dist/{HintComponent-B1B6qtaG.js → HintComponent-BZ7QT0Cf.js} +1 -1
- package/dist/{IDE-kbUDZPcL.js → IDE-BYphurDi.js} +10 -10
- package/dist/{JobsView-AYNUDnKG.js → JobsView-Bzv-qCJD.js} +4 -4
- package/dist/{LLMChat-CZTQUh53.js → LLMChat-DUReWNVL.js} +9 -9
- package/dist/{LLMConnectionList-BkvCZP5Q.js → LLMConnectionList-CS8b_fyI.js} +9 -9
- package/dist/{LLMView-CaTlmLGb.js → LLMView-D031rgKZ.js} +8 -8
- package/dist/{LoadingButton-BdM3Rygq.js → LoadingButton-3lCHccOe.js} +2 -2
- package/dist/{LoadingView-DXMQWonY.js → LoadingView-CCvQjQXB.js} +1 -1
- package/dist/{MarkdownRenderer-cdaHKql1.js → MarkdownRenderer-ToJ3ndVO.js} +3 -3
- package/dist/{MobileIDE-Bi7GNE2X.js → MobileIDE-YK0ZzWHh.js} +17 -17
- package/dist/{ModalDialog-D-yprLG4.js → ModalDialog-DUjJI7a8.js} +1 -1
- package/dist/{ModelCard-Cd6OxExX.js → ModelCard-DqfChNPX.js} +6 -6
- package/dist/{ModelCreator-DeI-n86Z.js → ModelCreator-DM1J950f.js} +4 -4
- package/dist/{ModelView-Surdb5KW.js → ModelView--DBf6oe2.js} +6 -6
- package/dist/{ResultComponent-CXkTwZFS.js → ResultComponent-DPeHR38g.js} +5 -5
- package/dist/{Sidebar-CfOATms_.js → Sidebar-Dq-6dIQq.js} +11 -11
- package/dist/{StatusIcon-CahClDuz.js → StatusIcon-BRguDu_P.js} +2 -2
- package/dist/{StoreTokenModal-CyPiGrhJ.js → StoreTokenModal-B379wQ3M.js} +2 -2
- package/dist/{SymbolsPane-CZaqqs5e.js → SymbolsPane-BrwZzMNn.js} +1 -1
- package/dist/Tooltip-Du2RDSUJ.js +104 -0
- package/dist/{TrilogyEmbedProvider-scDWYeoJ.js → TrilogyEmbedProvider-SmcmJEz6.js} +1 -1
- package/dist/{TutorialPage-IisHiPL6.js → TutorialPage-A-44DRyk.js} +12 -12
- package/dist/{UserProfile-CQAUnKyQ.js → UserProfile-DmDQyEIc.js} +4 -4
- package/dist/{WelcomePage-Bq-h9f64.js → WelcomePage-CeP5qQXC.js} +2 -2
- package/dist/_plugin-vue_export-helper-Ckr1Vx8X.js +368 -0
- package/dist/components/LoadingButton.vue.d.ts +6 -5
- package/dist/components/LoadingButton.vue.d.ts.map +1 -1
- package/dist/components/MarkdownRenderer.vue.d.ts.map +1 -1
- package/dist/components/Tooltip.vue.d.ts +6 -5
- package/dist/components/Tooltip.vue.d.ts.map +1 -1
- package/dist/components/VegaLiteChart.vue.d.ts +6 -5
- package/dist/components/VegaLiteChart.vue.d.ts.map +1 -1
- package/dist/components/chartHelpers.d.ts.map +1 -1
- package/dist/components/connection/ConnectionDatabase.vue.d.ts +6 -5
- package/dist/components/connection/ConnectionDatabase.vue.d.ts.map +1 -1
- package/dist/components/dashboard/Dashboard.vue.d.ts +3 -1
- package/dist/components/dashboard/Dashboard.vue.d.ts.map +1 -1
- package/dist/components/dashboard/DashboardChart.vue.d.ts +8 -7
- package/dist/components/dashboard/DashboardChart.vue.d.ts.map +1 -1
- package/dist/components/dashboard/DashboardFilter.vue.d.ts +1 -1
- package/dist/components/dashboard/DashboardGridItem.vue.d.ts.map +1 -1
- package/dist/components/dashboard/DashboardHeader.vue.d.ts +10 -0
- package/dist/components/dashboard/DashboardHeader.vue.d.ts.map +1 -1
- package/dist/components/dashboard/DashboardMarkdown.vue.d.ts +1 -1
- package/dist/components/dashboard/DashboardTable.vue.d.ts +1 -1
- package/dist/components/dashboard/useDashboard.d.ts.map +1 -1
- package/dist/components/editor/Editor.vue.d.ts +12 -10
- package/dist/components/editor/Editor.vue.d.ts.map +1 -1
- package/dist/components/editor/EditorCreatorInline.vue.d.ts +6 -5
- package/dist/components/editor/EditorCreatorInline.vue.d.ts.map +1 -1
- package/dist/components/editor/EditorHeader.vue.d.ts +6 -5
- package/dist/components/editor/EditorHeader.vue.d.ts.map +1 -1
- package/dist/components/editor/ResultComponent.vue.d.ts +48 -40
- package/dist/components/editor/ResultComponent.vue.d.ts.map +1 -1
- package/dist/components/editor/Results.vue.d.ts +12 -10
- package/dist/components/editor/Results.vue.d.ts.map +1 -1
- package/dist/components/llm/ArtifactsPane.vue.d.ts +12 -10
- package/dist/components/llm/ArtifactsPane.vue.d.ts.map +1 -1
- package/dist/components/llm/ChatArtifact.vue.d.ts +6 -5
- package/dist/components/llm/ChatArtifact.vue.d.ts.map +1 -1
- package/dist/components/llm/LLMChatSplitView.vue.d.ts +12 -10
- package/dist/components/llm/LLMChatSplitView.vue.d.ts.map +1 -1
- package/dist/components/llm/LLMEditorRefinement.vue.d.ts +12 -10
- package/dist/components/llm/LLMEditorRefinement.vue.d.ts.map +1 -1
- package/dist/components/model/ModelCard.vue.d.ts +18 -15
- package/dist/components/model/ModelCard.vue.d.ts.map +1 -1
- package/dist/components/model/ModelCreator.vue.d.ts +12 -10
- package/dist/components/model/ModelCreator.vue.d.ts.map +1 -1
- package/dist/components/sidebar/ConnectionList.vue.d.ts +18 -15
- package/dist/components/sidebar/ConnectionList.vue.d.ts.map +1 -1
- package/dist/components/sidebar/ConnectionListItem.vue.d.ts +6 -5
- package/dist/components/sidebar/ConnectionListItem.vue.d.ts.map +1 -1
- package/dist/components/sidebar/DashboardList.vue.d.ts +14 -12
- package/dist/components/sidebar/DashboardList.vue.d.ts.map +1 -1
- package/dist/components/sidebar/DashboardListItem.vue.d.ts +7 -6
- package/dist/components/sidebar/DashboardListItem.vue.d.ts.map +1 -1
- package/dist/components/sidebar/EditorList.vue.d.ts +18 -15
- package/dist/components/sidebar/EditorList.vue.d.ts.map +1 -1
- package/dist/components/sidebar/EditorListItem.vue.d.ts +6 -5
- package/dist/components/sidebar/EditorListItem.vue.d.ts.map +1 -1
- package/dist/components/sidebar/LLMConnectionCreator.vue.d.ts +6 -5
- package/dist/components/sidebar/LLMConnectionCreator.vue.d.ts.map +1 -1
- package/dist/components/sidebar/LLMConnectionList.vue.d.ts +12 -10
- package/dist/components/sidebar/LLMConnectionList.vue.d.ts.map +1 -1
- package/dist/components/sidebar/LLMConnectionListItem.vue.d.ts +6 -5
- package/dist/components/sidebar/LLMConnectionListItem.vue.d.ts.map +1 -1
- package/dist/components/sidebar/ModelSidebar.vue.d.ts +24 -20
- package/dist/components/sidebar/ModelSidebar.vue.d.ts.map +1 -1
- package/dist/components/sidebar/Sidebar.vue.d.ts +92 -77
- package/dist/components/sidebar/Sidebar.vue.d.ts.map +1 -1
- package/dist/components/tutorial/TutorialPrompt.vue.d.ts +60 -50
- package/dist/components/tutorial/TutorialPrompt.vue.d.ts.map +1 -1
- package/dist/composables/useCrossFilterEligibility.d.ts.map +1 -1
- package/dist/composables/useEmbeddedDashboardGroup.d.ts +5 -9
- package/dist/composables/useEmbeddedDashboardGroup.d.ts.map +1 -1
- package/dist/composables/useResolvedCrossFilterController.d.ts +1 -1
- package/dist/composables/useResolvedCrossFilterController.d.ts.map +1 -1
- package/dist/connections/bigquery_oauth.d.ts +1 -0
- package/dist/connections/bigquery_oauth.d.ts.map +1 -1
- package/dist/connections/duckdb.d.ts.map +1 -1
- package/dist/connections/motherduck.d.ts +1 -1
- package/dist/connections/motherduck.d.ts.map +1 -1
- package/dist/connections/snowflake.d.ts +9 -2
- package/dist/connections/snowflake.d.ts.map +1 -1
- package/dist/connections.js +2 -2
- package/dist/dashboard.js +23 -18
- package/dist/dashboards/barChartSpec.d.ts.map +1 -1
- package/dist/dashboards/barHChartSpec.d.ts.map +1 -1
- package/dist/dashboards/base.d.ts +13 -12
- package/dist/dashboards/base.d.ts.map +1 -1
- package/dist/dashboards/conditions.d.ts +26 -0
- package/dist/dashboards/conditions.d.ts.map +1 -1
- package/dist/dashboards/crossFilters.d.ts +28 -8
- package/dist/dashboards/crossFilters.d.ts.map +1 -1
- package/dist/dashboards/dashboardQueryExecutor.d.ts.map +1 -1
- package/dist/dashboards/helpers.d.ts +2 -0
- package/dist/dashboards/helpers.d.ts.map +1 -1
- package/dist/dashboards/spec.d.ts.map +1 -1
- package/dist/{editorStore-BTPcljeQ.js → editorStore-CHHdik0L.js} +1 -1
- package/dist/editors/results.d.ts +1 -0
- package/dist/editors/results.d.ts.map +1 -1
- package/dist/embed.js +2 -2
- package/dist/icons/registerMdiIcons.d.ts +2 -1
- package/dist/icons/registerMdiIcons.d.ts.map +1 -1
- package/dist/monaco.js +1 -1
- package/dist/{queryExecutionService-KrjL0UCa.js → queryExecutionService-D1ynkTop.js} +852 -690
- package/dist/{remoteProject-CvjztZU1.js → remoteProject-DrsKUWjF.js} +1 -1
- package/dist/{snowflake-CY1Gnu3y.js → snowflake-BUHnLz1S.js} +1587 -1539
- package/dist/stores/dashboardStore.d.ts +2 -1
- package/dist/stores/dashboardStore.d.ts.map +1 -1
- package/dist/stores/queryExecutionService.d.ts.map +1 -1
- package/dist/stores/resolver.d.ts +2 -0
- package/dist/stores/resolver.d.ts.map +1 -1
- package/dist/stores.js +2 -2
- package/dist/trilogy-studio-components.css +1 -1
- package/dist/{useDashboard-CtX3sEag.js → useDashboard-DlVElw8y.js} +1130 -1093
- package/dist/{useResizableDialog-BZgmdwim.js → useResizableDialog-B6WRQMxc.js} +1 -1
- package/dist/views/ConnectionView.vue.d.ts +6 -5
- package/dist/views/ConnectionView.vue.d.ts.map +1 -1
- package/dist/views/LLMView.vue.d.ts +36 -30
- package/dist/views/LLMView.vue.d.ts.map +1 -1
- package/dist/views/ModelView.vue.d.ts +36 -30
- package/dist/views/ModelView.vue.d.ts.map +1 -1
- package/dist/views/ResponsiveIDE.vue.d.ts.map +1 -1
- package/dist/views/TutorialPage.vue.d.ts +196 -162
- package/dist/views/TutorialPage.vue.d.ts.map +1 -1
- package/dist/views.js +109 -104
- package/package.json +1 -1
- package/dist/Tooltip-D4kSH91A.js +0 -62
- package/dist/_plugin-vue_export-helper-BzkwV_Yn.js +0 -361
|
@@ -1,23 +1,23 @@
|
|
|
1
|
-
import { defineComponent as J, ref as S, watch as
|
|
2
|
-
import { a as st, u as
|
|
1
|
+
import { defineComponent as J, ref as S, watch as ue, createBlock as _, openBlock as h, withCtx as ee, createElementVNode as t, toDisplayString as P, normalizeClass as q, computed as p, createElementBlock as y, createCommentVNode as R, normalizeStyle as Te, Fragment as fe, renderList as we, createTextVNode as Ce, unref as ie, createVNode as z, withDirectives as ce, withKeys as ge, vModelText as pe, onMounted as Ge, onUnmounted as ot, inject as j, resolveComponent as Z, Teleport as nt, withModifiers as Oe, resolveDynamicComponent as it, vModelRadio as rt, vShow as lt, renderSlot as Ke, onBeforeUnmount as at, nextTick as We } from "vue";
|
|
2
|
+
import { a as st, u as ze, j as dt } from "./editorStore-CHHdik0L.js";
|
|
3
3
|
import { u as ut } from "./toolLoopCore-CK_KVuAS.js";
|
|
4
|
-
import { u as ct, e as
|
|
5
|
-
import { u as
|
|
6
|
-
import { M as
|
|
7
|
-
import { _ as Y } from "./_plugin-vue_export-helper-
|
|
8
|
-
import { T as
|
|
9
|
-
import yt from "./LoadingButton-
|
|
10
|
-
import
|
|
11
|
-
import { D as gt, V as bt } from "./DrilldownPane-
|
|
12
|
-
import { L as
|
|
13
|
-
import { M as Ct } from "./MarkdownRenderer-
|
|
14
|
-
import { D as wt } from "./DataTable-
|
|
15
|
-
import { C as
|
|
4
|
+
import { u as ct, e as Je, w as mt, h as C, a as ht, p as ft, q as vt, O as Ue } from "./queryExecutionService-D1ynkTop.js";
|
|
5
|
+
import { u as Ve, D as pt } from "./DashboardImportSelector-8mxsOld1.js";
|
|
6
|
+
import { M as Ye } from "./ModalDialog-DUjJI7a8.js";
|
|
7
|
+
import { _ as Y } from "./_plugin-vue_export-helper-Ckr1Vx8X.js";
|
|
8
|
+
import { T as be } from "./Tooltip-Du2RDSUJ.js";
|
|
9
|
+
import yt from "./LoadingButton-3lCHccOe.js";
|
|
10
|
+
import Le from "./ErrorMessage-BcAwiBgc.js";
|
|
11
|
+
import { D as gt, V as bt } from "./DrilldownPane-oN6u9FSj.js";
|
|
12
|
+
import { L as Me } from "./LoadingView-CCvQjQXB.js";
|
|
13
|
+
import { M as Ct } from "./MarkdownRenderer-ToJ3ndVO.js";
|
|
14
|
+
import { D as wt } from "./DataTable-CcALeEBZ.js";
|
|
15
|
+
import { C as he, R as je } from "./snowflake-BUHnLz1S.js";
|
|
16
16
|
import { u as kt } from "./config-AzVcp1pU.js";
|
|
17
|
-
import { e as
|
|
18
|
-
import { S as
|
|
19
|
-
import { u as
|
|
20
|
-
const
|
|
17
|
+
import { e as $e, K as de, a as ve, R as St } from "./toggleHighContrast-q6tdBRv8.js";
|
|
18
|
+
import { S as Et } from "./SymbolsPane-BrwZzMNn.js";
|
|
19
|
+
import { u as Dt, R as It } from "./useResizableDialog-B6WRQMxc.js";
|
|
20
|
+
const Tt = { class: "share-popup-body" }, $t = { class: "json-container" }, Lt = {
|
|
21
21
|
"data-testid": "dashboard-json",
|
|
22
22
|
class: "json-code"
|
|
23
23
|
}, Mt = /* @__PURE__ */ J({
|
|
@@ -27,25 +27,25 @@ const It = { class: "share-popup-body" }, $t = { class: "json-container" }, Lt =
|
|
|
27
27
|
isOpen: { type: Boolean }
|
|
28
28
|
},
|
|
29
29
|
emits: ["close"],
|
|
30
|
-
setup(e, { emit:
|
|
31
|
-
const
|
|
30
|
+
setup(e, { emit: n }) {
|
|
31
|
+
const o = e, l = n, r = S(""), i = S(!1), s = (c) => {
|
|
32
32
|
if (!c) return null;
|
|
33
33
|
const a = JSON.parse(JSON.stringify(c));
|
|
34
34
|
if (delete a.id, delete a.connection, delete a.storage, delete a.changed, delete a.deleted, a.layout && Array.isArray(a.layout) && (a.layout = a.layout.map((v) => {
|
|
35
|
-
const
|
|
36
|
-
return delete
|
|
35
|
+
const w = { ...v };
|
|
36
|
+
return delete w.static, delete w.moved, delete w.state, w;
|
|
37
37
|
})), a.gridItems && typeof a.gridItems == "object")
|
|
38
|
-
for (const [v,
|
|
39
|
-
const
|
|
40
|
-
delete
|
|
38
|
+
for (const [v, w] of Object.entries(a.gridItems)) {
|
|
39
|
+
const b = { ...w };
|
|
40
|
+
delete b.results, delete b.loading, delete b.loadStartTime, delete b.error, b.filters || delete b.filters, b.crossFilters || delete b.crossFilters, b.chartFilters || delete b.chartFilters, b.conceptFilters || delete b.conceptFilters, b.chartConfig && delete b.chartConfig.showDebug, a.gridItems[v] = b;
|
|
41
41
|
}
|
|
42
42
|
return a.imports && Array.isArray(a.imports) && (a.imports = a.imports.map((v) => {
|
|
43
|
-
const
|
|
44
|
-
return delete
|
|
43
|
+
const w = { ...v };
|
|
44
|
+
return delete w.id, w;
|
|
45
45
|
})), a;
|
|
46
46
|
};
|
|
47
|
-
|
|
48
|
-
[() =>
|
|
47
|
+
ue(
|
|
48
|
+
[() => o.dashboard, () => o.isOpen],
|
|
49
49
|
([c, a]) => {
|
|
50
50
|
if (a && c) {
|
|
51
51
|
const v = s(c);
|
|
@@ -63,14 +63,14 @@ const It = { class: "share-popup-body" }, $t = { class: "json-container" }, Lt =
|
|
|
63
63
|
console.error("Could not copy text: ", c);
|
|
64
64
|
});
|
|
65
65
|
};
|
|
66
|
-
return (c, a) => (
|
|
66
|
+
return (c, a) => (h(), _(Ye, {
|
|
67
67
|
show: e.isOpen,
|
|
68
68
|
title: "Export Definition",
|
|
69
69
|
"max-width": "860px",
|
|
70
70
|
"test-id": "dashboard-share-popup",
|
|
71
71
|
onClose: a[1] || (a[1] = (v) => l("close"))
|
|
72
72
|
}, {
|
|
73
|
-
footer:
|
|
73
|
+
footer: ee(() => [
|
|
74
74
|
t("button", {
|
|
75
75
|
class: "secondary-button",
|
|
76
76
|
onClick: a[0] || (a[0] = (v) => l("close"))
|
|
@@ -81,20 +81,20 @@ const It = { class: "share-popup-body" }, $t = { class: "json-container" }, Lt =
|
|
|
81
81
|
"data-testid": "copy-json-button"
|
|
82
82
|
}, [
|
|
83
83
|
t("i", {
|
|
84
|
-
class:
|
|
84
|
+
class: q(["mdi", i.value ? "mdi-check-circle-outline" : "mdi-content-copy"]),
|
|
85
85
|
"aria-hidden": "true"
|
|
86
86
|
}, null, 2),
|
|
87
|
-
t("span", null,
|
|
87
|
+
t("span", null, P(i.value ? "Copied" : "Copy JSON"), 1)
|
|
88
88
|
])
|
|
89
89
|
]),
|
|
90
|
-
default:
|
|
91
|
-
t("div",
|
|
90
|
+
default: ee(() => [
|
|
91
|
+
t("div", Tt, [
|
|
92
92
|
a[3] || (a[3] = t("p", { class: "share-popup-description" }, " Copy a definition of this dashboard; it can be imported by others with the same model defined. Existing runtime/results info is removed automatically. ", -1)),
|
|
93
93
|
t("div", $t, [
|
|
94
94
|
a[2] || (a[2] = t("div", { class: "json-toolbar" }, [
|
|
95
95
|
t("span", { class: "json-toolbar-label" }, "dashboard.json")
|
|
96
96
|
], -1)),
|
|
97
|
-
t("pre", Lt,
|
|
97
|
+
t("pre", Lt, P(r.value), 1)
|
|
98
98
|
])
|
|
99
99
|
])
|
|
100
100
|
]),
|
|
@@ -118,20 +118,20 @@ const It = { class: "share-popup-body" }, $t = { class: "json-container" }, Lt =
|
|
|
118
118
|
}
|
|
119
119
|
},
|
|
120
120
|
emits: ["select-completion"],
|
|
121
|
-
setup(e, { emit:
|
|
122
|
-
const
|
|
123
|
-
if (!
|
|
124
|
-
const k =
|
|
121
|
+
setup(e, { emit: n }) {
|
|
122
|
+
const o = e, l = n, r = S(!1), i = S(0), s = S(0), f = S(""), c = S(0), a = S(null), v = p(() => {
|
|
123
|
+
if (!o.inputElement) return {};
|
|
124
|
+
const k = o.inputElement.getBoundingClientRect();
|
|
125
125
|
return {
|
|
126
126
|
top: `${k.bottom + 50}px`,
|
|
127
127
|
left: `${k.left}px`,
|
|
128
128
|
width: `${k.width}px`,
|
|
129
129
|
maxHeight: "200px"
|
|
130
130
|
};
|
|
131
|
-
}),
|
|
132
|
-
if (!
|
|
133
|
-
s.value =
|
|
134
|
-
const k =
|
|
131
|
+
}), w = () => {
|
|
132
|
+
if (!o.inputElement) return;
|
|
133
|
+
s.value = o.inputElement.selectionStart || 0;
|
|
134
|
+
const k = o.inputValue;
|
|
135
135
|
let M = s.value;
|
|
136
136
|
for (; M > 0 && !/\s/.test(k.charAt(M - 1)); )
|
|
137
137
|
M--;
|
|
@@ -139,31 +139,31 @@ const It = { class: "share-popup-body" }, $t = { class: "json-container" }, Lt =
|
|
|
139
139
|
for (; T < k.length && !/\s/.test(k.charAt(T)); )
|
|
140
140
|
T++;
|
|
141
141
|
c.value = M, f.value = k.substring(M, T);
|
|
142
|
-
},
|
|
142
|
+
}, b = p(() => {
|
|
143
143
|
if (!f.value.trim()) return [];
|
|
144
144
|
const k = f.value.toLowerCase();
|
|
145
|
-
return
|
|
146
|
-
const
|
|
147
|
-
return
|
|
145
|
+
return o.completionItems.filter((M) => M.label.toLowerCase().includes(k)).sort((M, T) => {
|
|
146
|
+
const O = M.label.toLowerCase().startsWith(k), W = T.label.toLowerCase().startsWith(k);
|
|
147
|
+
return O && !W ? -1 : !O && W ? 1 : M.label.localeCompare(T.label);
|
|
148
148
|
}).slice(0, 10);
|
|
149
149
|
});
|
|
150
|
-
|
|
150
|
+
ue(b, (k) => {
|
|
151
151
|
r.value = k.length > 0, i.value = 0;
|
|
152
152
|
});
|
|
153
|
-
const
|
|
154
|
-
const M =
|
|
153
|
+
const I = (k) => {
|
|
154
|
+
const M = o.inputValue.substring(0, c.value), T = o.inputValue.substring(s.value);
|
|
155
155
|
l("select-completion", {
|
|
156
156
|
text: M + k.label + T,
|
|
157
157
|
cursorPosition: c.value + k.label.length
|
|
158
158
|
}), r.value = !1;
|
|
159
|
-
},
|
|
160
|
-
return
|
|
161
|
-
() =>
|
|
159
|
+
}, x = (k) => k.trilogySubType ? k.trilogySubType.toLowerCase() : k.type.toLowerCase();
|
|
160
|
+
return ue(
|
|
161
|
+
() => o.inputValue,
|
|
162
162
|
() => {
|
|
163
|
-
|
|
163
|
+
w();
|
|
164
164
|
}
|
|
165
|
-
),
|
|
166
|
-
() => [a.value,
|
|
165
|
+
), Ve(
|
|
166
|
+
() => [a.value, o.inputElement],
|
|
167
167
|
() => {
|
|
168
168
|
r.value = !1;
|
|
169
169
|
},
|
|
@@ -171,50 +171,50 @@ const It = { class: "share-popup-body" }, $t = { class: "json-container" }, Lt =
|
|
|
171
171
|
enabled: () => r.value,
|
|
172
172
|
eventName: "mousedown"
|
|
173
173
|
}
|
|
174
|
-
),
|
|
174
|
+
), w(), (k, M) => r.value ? (h(), y("div", {
|
|
175
175
|
key: 0,
|
|
176
176
|
ref_key: "dropdown",
|
|
177
177
|
ref: a,
|
|
178
178
|
class: "autocomplete-dropdown",
|
|
179
|
-
style:
|
|
179
|
+
style: Te(v.value)
|
|
180
180
|
}, [
|
|
181
|
-
(
|
|
182
|
-
key:
|
|
183
|
-
class:
|
|
184
|
-
onClick: (
|
|
181
|
+
(h(!0), y(fe, null, we(b.value, (T, O) => (h(), y("div", {
|
|
182
|
+
key: O,
|
|
183
|
+
class: q(["completion-item", { selected: O === i.value }]),
|
|
184
|
+
onClick: (W) => I(T)
|
|
185
185
|
}, [
|
|
186
186
|
t("div", {
|
|
187
|
-
class:
|
|
187
|
+
class: q(["symbol-icon", x(T)])
|
|
188
188
|
}, [
|
|
189
|
-
T.trilogySubType ? (
|
|
189
|
+
T.trilogySubType ? (h(), y("i", {
|
|
190
190
|
key: 0,
|
|
191
|
-
class:
|
|
192
|
-
}, null, 2)) : (
|
|
193
|
-
|
|
191
|
+
class: q(`mdi ${T.trilogySubType === "key" ? "mdi-key-outline" : T.trilogySubType === "property" ? "mdi-tag-outline" : "mdi-cube-outline"}`)
|
|
192
|
+
}, null, 2)) : (h(), y(fe, { key: 1 }, [
|
|
193
|
+
Ce(P(T.type === "function" ? "ƒ" : T.type === "variable" ? "V" : T.type === "class" ? "C" : T.type === "interface" ? "I" : T.type === "method" ? "M" : T.type === "property" ? "P" : T.type === "field" ? "F" : T.type === "constant" ? "K" : T.type === "enum" ? "E" : T.type === "keyword" ? "K" : "S"), 1)
|
|
194
194
|
], 64))
|
|
195
195
|
], 2),
|
|
196
196
|
t("div", qt, [
|
|
197
|
-
t("div", Ft,
|
|
198
|
-
t("div", xt,
|
|
197
|
+
t("div", Ft, P(T.label), 1),
|
|
198
|
+
t("div", xt, P(T.description), 1)
|
|
199
199
|
])
|
|
200
200
|
], 10, At))), 128))
|
|
201
201
|
], 4)) : R("", !0);
|
|
202
202
|
}
|
|
203
|
-
}),
|
|
203
|
+
}), Ot = /* @__PURE__ */ Y(Ht, [["__scopeId", "data-v-89468628"]]), Vt = { class: "filter-container" }, Qt = { class: "filter-input-wrapper" }, Bt = ["value", "disabled"], Nt = ["value", "placeholder", "disabled"], Pt = {
|
|
204
204
|
key: 0,
|
|
205
205
|
class: "dropdown-error-message",
|
|
206
206
|
"data-testid": "dropdown-error-message"
|
|
207
207
|
}, Kt = { class: "dropdown-actions" }, Wt = ["disabled"], Ut = ["disabled"], jt = {
|
|
208
208
|
key: 0,
|
|
209
209
|
class: "loader-container"
|
|
210
|
-
},
|
|
210
|
+
}, _t = ["disabled"], Gt = { class: "filter-inline-actions" }, zt = {
|
|
211
211
|
key: 0,
|
|
212
212
|
class: "filter-status error",
|
|
213
213
|
"data-testid": "filter-error-icon"
|
|
214
|
-
}, Jt = ["disabled"], Yt = { class: "button-content" }, Zt = ["disabled"], Xt = { class: "button-content" },
|
|
214
|
+
}, Jt = ["disabled"], Yt = { class: "button-content" }, Zt = ["disabled"], Xt = { class: "button-content" }, eo = {
|
|
215
215
|
key: 0,
|
|
216
216
|
class: "loader-container"
|
|
217
|
-
},
|
|
217
|
+
}, to = ["disabled"], oo = { class: "button-content" }, no = /* @__PURE__ */ J({
|
|
218
218
|
__name: "DashboardHeaderFilterInput",
|
|
219
219
|
props: {
|
|
220
220
|
filterValue: {
|
|
@@ -233,76 +233,76 @@ const It = { class: "share-popup-body" }, $t = { class: "json-container" }, Lt =
|
|
|
233
233
|
}
|
|
234
234
|
},
|
|
235
235
|
emits: ["filter-change", "filter-apply", "clear-filter"],
|
|
236
|
-
setup(e, { emit:
|
|
237
|
-
const
|
|
238
|
-
function
|
|
239
|
-
l("filter-apply", a.value), v.value = !1,
|
|
236
|
+
setup(e, { emit: n }) {
|
|
237
|
+
const o = e, l = n, r = ct(), i = S(o.isLoading), s = S(null), f = S(null), c = S(null), a = S(o.filterValue || ""), v = S(!1), w = S(!1), b = p(() => a.value.replace(/\n/g, " ")), I = p(() => a.value.trim().length > 0);
|
|
238
|
+
function x() {
|
|
239
|
+
l("filter-apply", a.value), v.value = !1, O();
|
|
240
240
|
}
|
|
241
241
|
function k() {
|
|
242
242
|
a.value = "", v.value = !0, l("filter-change", ""), l("filter-apply", ""), l("clear-filter", ""), setTimeout(() => {
|
|
243
243
|
f.value && f.value.focus();
|
|
244
244
|
}, 0);
|
|
245
245
|
}
|
|
246
|
-
function M(
|
|
247
|
-
const
|
|
248
|
-
a.value =
|
|
246
|
+
function M(E) {
|
|
247
|
+
const m = E.target;
|
|
248
|
+
a.value = m.value, v.value = !0, l("filter-change", a.value);
|
|
249
249
|
}
|
|
250
250
|
function T() {
|
|
251
|
-
|
|
251
|
+
w.value = !0, setTimeout(() => {
|
|
252
252
|
if (f.value) {
|
|
253
253
|
f.value.focus();
|
|
254
|
-
const
|
|
255
|
-
f.value.setSelectionRange(
|
|
254
|
+
const E = a.value.length;
|
|
255
|
+
f.value.setSelectionRange(E, E);
|
|
256
256
|
}
|
|
257
257
|
}, 0);
|
|
258
258
|
}
|
|
259
|
-
function
|
|
260
|
-
|
|
259
|
+
function O() {
|
|
260
|
+
w.value = !1;
|
|
261
261
|
}
|
|
262
|
-
const
|
|
262
|
+
const W = () => {
|
|
263
263
|
i.value = !0;
|
|
264
|
-
const
|
|
265
|
-
name:
|
|
266
|
-
type:
|
|
267
|
-
description:
|
|
264
|
+
const E = o.globalCompletion.map((m) => ({
|
|
265
|
+
name: m.label,
|
|
266
|
+
type: m.datatype,
|
|
267
|
+
description: m.description
|
|
268
268
|
}));
|
|
269
|
-
r.generateFilterQuery(a.value,
|
|
270
|
-
|
|
269
|
+
r.generateFilterQuery(a.value, E, o.validateFilter).then((m) => {
|
|
270
|
+
m && m.length > 0 && (a.value = m.replace(/^\s*where\s+/i, ""), v.value = !0, l("filter-apply", a.value)), i.value = !1;
|
|
271
271
|
}).catch(() => {
|
|
272
272
|
i.value = !1;
|
|
273
273
|
});
|
|
274
274
|
};
|
|
275
|
-
function
|
|
276
|
-
|
|
277
|
-
}
|
|
278
|
-
function $(
|
|
279
|
-
(
|
|
280
|
-
}
|
|
281
|
-
const g = p(() => (
|
|
282
|
-
function B(
|
|
283
|
-
a.value =
|
|
284
|
-
const
|
|
285
|
-
|
|
286
|
-
}
|
|
287
|
-
return
|
|
288
|
-
() =>
|
|
289
|
-
(
|
|
290
|
-
|
|
275
|
+
function V(E) {
|
|
276
|
+
E.key === "Enter" && !E.shiftKey && !E.ctrlKey && !E.altKey ? w.value || (E.preventDefault(), x()) : (E.ctrlKey || E.metaKey) && E.shiftKey && E.key === "Enter" ? (E.preventDefault(), W()) : E.key === "Escape" && w.value && (E.preventDefault(), O());
|
|
277
|
+
}
|
|
278
|
+
function $(E) {
|
|
279
|
+
(E.ctrlKey || E.metaKey) && E.key === "Enter" && !E.shiftKey ? (E.preventDefault(), x()) : (E.ctrlKey || E.metaKey) && E.shiftKey && E.key === "Enter" ? (E.preventDefault(), W()) : E.key === "Escape" && (E.preventDefault(), O());
|
|
280
|
+
}
|
|
281
|
+
const g = p(() => (o.filterError || "").length > 0 ? "error" : a.value ? "valid" : "neutral");
|
|
282
|
+
function B(E) {
|
|
283
|
+
a.value = E.text, v.value = !0, l("filter-change", a.value);
|
|
284
|
+
const m = w.value ? f.value : s.value;
|
|
285
|
+
m && (m.focus(), m.setSelectionRange(E.cursorPosition, E.cursorPosition));
|
|
286
|
+
}
|
|
287
|
+
return ue(
|
|
288
|
+
() => o.filterValue,
|
|
289
|
+
(E) => {
|
|
290
|
+
E !== a.value && (a.value = E || "", v.value = !1);
|
|
291
291
|
}
|
|
292
|
-
),
|
|
293
|
-
() =>
|
|
294
|
-
(
|
|
295
|
-
i.value =
|
|
292
|
+
), ue(
|
|
293
|
+
() => o.isLoading,
|
|
294
|
+
(E) => {
|
|
295
|
+
i.value = E;
|
|
296
296
|
}
|
|
297
|
-
),
|
|
297
|
+
), Ve(
|
|
298
298
|
() => [c.value, s.value],
|
|
299
299
|
() => {
|
|
300
|
-
|
|
300
|
+
O();
|
|
301
301
|
},
|
|
302
302
|
{
|
|
303
|
-
enabled: () =>
|
|
303
|
+
enabled: () => w.value
|
|
304
304
|
}
|
|
305
|
-
), (
|
|
305
|
+
), (E, m) => (h(), y("div", Vt, [
|
|
306
306
|
t("div", Qt, [
|
|
307
307
|
t("input", {
|
|
308
308
|
id: "filter",
|
|
@@ -310,34 +310,34 @@ const It = { class: "share-popup-body" }, $t = { class: "json-container" }, Lt =
|
|
|
310
310
|
ref: s,
|
|
311
311
|
"data-testid": "filter-input",
|
|
312
312
|
type: "text",
|
|
313
|
-
value:
|
|
313
|
+
value: b.value,
|
|
314
314
|
onInput: M,
|
|
315
|
-
onKeydown:
|
|
315
|
+
onKeydown: V,
|
|
316
316
|
onFocus: T,
|
|
317
317
|
placeholder: "Add a global filter...",
|
|
318
|
-
class:
|
|
318
|
+
class: q({ "filter-error": g.value === "error" }),
|
|
319
319
|
disabled: i.value
|
|
320
320
|
}, null, 42, Bt),
|
|
321
|
-
|
|
321
|
+
w.value ? (h(), y("div", {
|
|
322
322
|
key: 0,
|
|
323
323
|
ref_key: "filterDropdownRef",
|
|
324
324
|
ref: c,
|
|
325
325
|
class: "filter-dropdown"
|
|
326
326
|
}, [
|
|
327
327
|
t("div", { class: "dropdown-header" }, [
|
|
328
|
-
|
|
328
|
+
m[1] || (m[1] = t("span", null, "Global Filters", -1)),
|
|
329
329
|
t("button", {
|
|
330
|
-
onClick:
|
|
330
|
+
onClick: O,
|
|
331
331
|
class: "close-button",
|
|
332
332
|
title: "Close (Esc)"
|
|
333
|
-
}, [...
|
|
333
|
+
}, [...m[0] || (m[0] = [
|
|
334
334
|
t("i", { class: "mdi mdi-close" }, null, -1)
|
|
335
335
|
])])
|
|
336
336
|
]),
|
|
337
337
|
t("textarea", {
|
|
338
338
|
ref_key: "filterTextareaRef",
|
|
339
339
|
ref: f,
|
|
340
|
-
class:
|
|
340
|
+
class: q(["filter-textarea", { "filter-error": g.value === "error" }]),
|
|
341
341
|
value: a.value,
|
|
342
342
|
onInput: M,
|
|
343
343
|
onKeydown: $,
|
|
@@ -347,61 +347,61 @@ Use Ctrl+Enter to apply`,
|
|
|
347
347
|
disabled: i.value,
|
|
348
348
|
rows: "4"
|
|
349
349
|
}, null, 42, Nt),
|
|
350
|
-
e.filterError ? (
|
|
351
|
-
|
|
352
|
-
t("span", null,
|
|
350
|
+
e.filterError ? (h(), y("div", Pt, [
|
|
351
|
+
m[2] || (m[2] = t("i", { class: "mdi mdi-alert-circle-outline" }, null, -1)),
|
|
352
|
+
t("span", null, P(e.filterError), 1)
|
|
353
353
|
])) : R("", !0),
|
|
354
354
|
t("div", Kt, [
|
|
355
355
|
t("button", {
|
|
356
|
-
onClick:
|
|
357
|
-
class:
|
|
356
|
+
onClick: x,
|
|
357
|
+
class: q(["apply-button", { "has-changes": v.value }]),
|
|
358
358
|
disabled: i.value,
|
|
359
359
|
title: "Apply filter (Ctrl+Enter)"
|
|
360
|
-
}, [...
|
|
360
|
+
}, [...m[3] || (m[3] = [
|
|
361
361
|
t("i", { class: "mdi mdi-check" }, null, -1),
|
|
362
|
-
|
|
362
|
+
Ce(" Apply ", -1)
|
|
363
363
|
])], 10, Wt),
|
|
364
|
-
ie(r).hasActiveDefaultConnection ? (
|
|
364
|
+
ie(r).hasActiveDefaultConnection ? (h(), y("button", {
|
|
365
365
|
key: 0,
|
|
366
|
-
onClick:
|
|
366
|
+
onClick: W,
|
|
367
367
|
class: "llm-button",
|
|
368
368
|
disabled: i.value,
|
|
369
369
|
title: "Text to filter (Ctrl+Shift+Enter)"
|
|
370
370
|
}, [
|
|
371
371
|
t("i", {
|
|
372
|
-
class:
|
|
372
|
+
class: q(["mdi mdi-auto-fix", { hidden: i.value }])
|
|
373
373
|
}, null, 2),
|
|
374
|
-
i.value ? (
|
|
374
|
+
i.value ? (h(), y("div", jt, [...m[4] || (m[4] = [
|
|
375
375
|
t("div", { class: "loader" }, null, -1)
|
|
376
376
|
])])) : R("", !0),
|
|
377
|
-
|
|
377
|
+
m[5] || (m[5] = Ce(" Text to Filter ", -1))
|
|
378
378
|
], 8, Ut)) : R("", !0),
|
|
379
379
|
t("button", {
|
|
380
380
|
onClick: k,
|
|
381
381
|
class: "clear-button",
|
|
382
382
|
disabled: i.value,
|
|
383
383
|
title: "Clear filter"
|
|
384
|
-
}, [...
|
|
384
|
+
}, [...m[6] || (m[6] = [
|
|
385
385
|
t("i", { class: "mdi mdi-close-circle-outline" }, null, -1),
|
|
386
|
-
|
|
387
|
-
])], 8,
|
|
386
|
+
Ce(" Clear ", -1)
|
|
387
|
+
])], 8, _t)
|
|
388
388
|
])
|
|
389
389
|
], 512)) : R("", !0),
|
|
390
|
-
(
|
|
390
|
+
(w.value ? f.value : s.value) ? (h(), _(Ot, {
|
|
391
391
|
key: 1,
|
|
392
392
|
"input-value": a.value,
|
|
393
393
|
"completion-items": e.globalCompletion,
|
|
394
|
-
"input-element":
|
|
394
|
+
"input-element": w.value ? f.value : s.value,
|
|
395
395
|
onSelectCompletion: B
|
|
396
396
|
}, null, 8, ["input-value", "completion-items", "input-element"])) : R("", !0),
|
|
397
|
-
t("div",
|
|
398
|
-
g.value === "error" ? (
|
|
399
|
-
|
|
400
|
-
z(
|
|
397
|
+
t("div", Gt, [
|
|
398
|
+
g.value === "error" ? (h(), y("div", zt, [
|
|
399
|
+
m[8] || (m[8] = t("i", { class: "mdi mdi-alert-circle-outline" }, null, -1)),
|
|
400
|
+
z(be, {
|
|
401
401
|
content: e.filterError || "Unknown Error",
|
|
402
402
|
position: "bottom"
|
|
403
403
|
}, {
|
|
404
|
-
default:
|
|
404
|
+
default: ee(() => [...m[7] || (m[7] = [
|
|
405
405
|
t("span", {
|
|
406
406
|
class: "tooltip-trigger",
|
|
407
407
|
"data-testid": "filter-error-tooltip-trigger"
|
|
@@ -411,28 +411,28 @@ Use Ctrl+Enter to apply`,
|
|
|
411
411
|
}, 8, ["content"])
|
|
412
412
|
])) : R("", !0),
|
|
413
413
|
t("button", {
|
|
414
|
-
onClick:
|
|
415
|
-
class:
|
|
414
|
+
onClick: x,
|
|
415
|
+
class: q(["input-icon-button", { "has-changes": v.value }]),
|
|
416
416
|
"data-testid": "filter-search-button",
|
|
417
417
|
disabled: i.value,
|
|
418
418
|
title: "Apply filter (Enter)"
|
|
419
419
|
}, [
|
|
420
420
|
t("div", Yt, [
|
|
421
|
-
|
|
422
|
-
z(
|
|
421
|
+
m[10] || (m[10] = t("i", { class: "mdi mdi-magnify" }, null, -1)),
|
|
422
|
+
z(be, {
|
|
423
423
|
content: v.value ? "Apply changes (Enter)" : "Search (Enter)",
|
|
424
424
|
position: "top"
|
|
425
425
|
}, {
|
|
426
|
-
default:
|
|
426
|
+
default: ee(() => [...m[9] || (m[9] = [
|
|
427
427
|
t("span", { class: "tooltip-trigger" }, null, -1)
|
|
428
428
|
])]),
|
|
429
429
|
_: 1
|
|
430
430
|
}, 8, ["content"])
|
|
431
431
|
])
|
|
432
432
|
], 10, Jt),
|
|
433
|
-
ie(r).hasActiveDefaultConnection ? (
|
|
433
|
+
ie(r).hasActiveDefaultConnection ? (h(), y("button", {
|
|
434
434
|
key: 1,
|
|
435
|
-
onClick:
|
|
435
|
+
onClick: W,
|
|
436
436
|
class: "input-icon-button",
|
|
437
437
|
"data-testid": "filter-llm-button",
|
|
438
438
|
disabled: i.value,
|
|
@@ -440,23 +440,23 @@ Use Ctrl+Enter to apply`,
|
|
|
440
440
|
}, [
|
|
441
441
|
t("div", Xt, [
|
|
442
442
|
t("i", {
|
|
443
|
-
class:
|
|
443
|
+
class: q(["mdi mdi-auto-fix", { hidden: i.value }])
|
|
444
444
|
}, null, 2),
|
|
445
|
-
i.value ? (
|
|
445
|
+
i.value ? (h(), y("div", eo, [...m[11] || (m[11] = [
|
|
446
446
|
t("div", { class: "loader" }, null, -1)
|
|
447
447
|
])])) : R("", !0),
|
|
448
|
-
z(
|
|
448
|
+
z(be, {
|
|
449
449
|
content: i.value ? "Processing..." : "Text to filter (Ctrl+Shift+Enter)",
|
|
450
450
|
position: "top"
|
|
451
451
|
}, {
|
|
452
|
-
default:
|
|
452
|
+
default: ee(() => [...m[12] || (m[12] = [
|
|
453
453
|
t("span", { class: "tooltip-trigger" }, null, -1)
|
|
454
454
|
])]),
|
|
455
455
|
_: 1
|
|
456
456
|
}, 8, ["content"])
|
|
457
457
|
])
|
|
458
458
|
], 8, Zt)) : R("", !0),
|
|
459
|
-
|
|
459
|
+
I.value ? (h(), y("button", {
|
|
460
460
|
key: 2,
|
|
461
461
|
onClick: k,
|
|
462
462
|
class: "input-icon-button clear-icon-button",
|
|
@@ -464,43 +464,43 @@ Use Ctrl+Enter to apply`,
|
|
|
464
464
|
disabled: i.value,
|
|
465
465
|
title: "Clear all filters"
|
|
466
466
|
}, [
|
|
467
|
-
t("div",
|
|
468
|
-
|
|
469
|
-
z(
|
|
467
|
+
t("div", oo, [
|
|
468
|
+
m[14] || (m[14] = t("i", { class: "mdi mdi-close" }, null, -1)),
|
|
469
|
+
z(be, {
|
|
470
470
|
content: "Clear all filters",
|
|
471
471
|
position: "top"
|
|
472
472
|
}, {
|
|
473
|
-
default:
|
|
473
|
+
default: ee(() => [...m[13] || (m[13] = [
|
|
474
474
|
t("span", { class: "tooltip-trigger" }, null, -1)
|
|
475
475
|
])]),
|
|
476
476
|
_: 1
|
|
477
477
|
})
|
|
478
478
|
])
|
|
479
|
-
], 8,
|
|
479
|
+
], 8, to)) : R("", !0)
|
|
480
480
|
])
|
|
481
481
|
])
|
|
482
482
|
]));
|
|
483
483
|
}
|
|
484
|
-
}),
|
|
484
|
+
}), io = /* @__PURE__ */ Y(no, [["__scopeId", "data-v-ff037c5f"]]), ro = {
|
|
485
485
|
class: "dashboard-controls",
|
|
486
486
|
"data-testid": "dashboard-controls"
|
|
487
|
-
},
|
|
487
|
+
}, lo = {
|
|
488
488
|
key: 0,
|
|
489
489
|
class: "editable-text"
|
|
490
|
-
},
|
|
490
|
+
}, ao = { class: "title-text" }, so = {
|
|
491
491
|
key: 0,
|
|
492
492
|
class: "edit-indicator",
|
|
493
493
|
"data-testid": "edit-dashboard-title"
|
|
494
|
-
},
|
|
494
|
+
}, uo = {
|
|
495
495
|
key: 0,
|
|
496
496
|
class: "dashboard-right-controls"
|
|
497
|
-
},
|
|
497
|
+
}, co = {
|
|
498
498
|
class: "connection-selector",
|
|
499
499
|
"data-testid": "connection-selector-wrapper"
|
|
500
|
-
},
|
|
500
|
+
}, mo = { class: "select-wrapper" }, ho = ["value", "title"], fo = ["value"], vo = { class: "grid-actions top-actions" }, po = { class: "controls-row filter-row" }, yo = { class: "grid-actions filter-actions" }, go = {
|
|
501
501
|
class: "mode-selector",
|
|
502
502
|
"data-testid": "mode-selector-wrapper"
|
|
503
|
-
},
|
|
503
|
+
}, bo = { class: "select-wrapper" }, Co = ["value", "disabled"], wo = /* @__PURE__ */ J({
|
|
504
504
|
__name: "DashboardHeader",
|
|
505
505
|
props: {
|
|
506
506
|
dashboard: {
|
|
@@ -520,6 +520,10 @@ Use Ctrl+Enter to apply`,
|
|
|
520
520
|
validateFilter: {
|
|
521
521
|
type: Function,
|
|
522
522
|
default: () => !0
|
|
523
|
+
},
|
|
524
|
+
exportImageAction: {
|
|
525
|
+
type: Function,
|
|
526
|
+
default: null
|
|
523
527
|
}
|
|
524
528
|
},
|
|
525
529
|
emits: [
|
|
@@ -534,55 +538,59 @@ Use Ctrl+Enter to apply`,
|
|
|
534
538
|
"title-update",
|
|
535
539
|
"export-image"
|
|
536
540
|
],
|
|
537
|
-
setup(e, { emit:
|
|
538
|
-
const
|
|
539
|
-
function
|
|
541
|
+
setup(e, { emit: n }) {
|
|
542
|
+
const o = e, l = n, r = st(), i = ze(), s = Je(), f = S(!1), c = S(!1), a = S(!1), v = S(""), w = S(null);
|
|
543
|
+
function b() {
|
|
540
544
|
c.value = !c.value;
|
|
541
545
|
}
|
|
542
|
-
function
|
|
546
|
+
function I() {
|
|
543
547
|
c.value = !1;
|
|
544
548
|
}
|
|
545
|
-
function
|
|
546
|
-
l("filter-change",
|
|
549
|
+
function x(m) {
|
|
550
|
+
l("filter-change", m);
|
|
547
551
|
}
|
|
548
552
|
async function k() {
|
|
549
|
-
|
|
553
|
+
if (o.exportImageAction) {
|
|
554
|
+
await o.exportImageAction();
|
|
555
|
+
return;
|
|
556
|
+
}
|
|
557
|
+
l("export-image");
|
|
550
558
|
}
|
|
551
|
-
function M(
|
|
552
|
-
const
|
|
553
|
-
l("mode-change",
|
|
559
|
+
function M(m) {
|
|
560
|
+
const D = m.target;
|
|
561
|
+
l("mode-change", D.value);
|
|
554
562
|
}
|
|
555
563
|
function T() {
|
|
556
|
-
var
|
|
557
|
-
|
|
558
|
-
var
|
|
559
|
-
(
|
|
564
|
+
var m;
|
|
565
|
+
o.editsLocked || (a.value = !0, v.value = ((m = o.dashboard) == null ? void 0 : m.name) || "Untitled Dashboard", setTimeout(() => {
|
|
566
|
+
var D;
|
|
567
|
+
(D = w.value) == null || D.focus();
|
|
560
568
|
}, 0));
|
|
561
569
|
}
|
|
562
|
-
function
|
|
570
|
+
function O() {
|
|
563
571
|
a.value = !1, l("title-update", v.value);
|
|
564
572
|
}
|
|
565
|
-
function
|
|
566
|
-
var
|
|
567
|
-
a.value = !1, v.value = ((
|
|
573
|
+
function W() {
|
|
574
|
+
var m;
|
|
575
|
+
a.value = !1, v.value = ((m = o.dashboard) == null ? void 0 : m.name) || "Untitled Dashboard";
|
|
568
576
|
}
|
|
569
|
-
const
|
|
570
|
-
id:
|
|
571
|
-
name:
|
|
577
|
+
const V = p(() => Object.values(i.editors).filter((D) => D.connection === o.selectedConnection).sort((D, te) => D.name.localeCompare(te.name)).map((D) => ({
|
|
578
|
+
id: D.id,
|
|
579
|
+
name: D.name.replace(/\//g, "."),
|
|
572
580
|
alias: ""
|
|
573
581
|
}))), $ = p(() => {
|
|
574
|
-
var
|
|
575
|
-
return ((
|
|
582
|
+
var m;
|
|
583
|
+
return ((m = o.dashboard) == null ? void 0 : m.imports) || [];
|
|
576
584
|
});
|
|
577
|
-
function g(
|
|
578
|
-
l("import-change",
|
|
585
|
+
function g(m) {
|
|
586
|
+
l("import-change", m);
|
|
579
587
|
}
|
|
580
588
|
function B() {
|
|
581
589
|
l("refresh");
|
|
582
590
|
}
|
|
583
|
-
const
|
|
584
|
-
var
|
|
585
|
-
switch ((
|
|
591
|
+
const E = p(() => {
|
|
592
|
+
var m;
|
|
593
|
+
switch ((m = o.dashboard) == null ? void 0 : m.state) {
|
|
586
594
|
case "editing":
|
|
587
595
|
return "mdi mdi-pencil-outline";
|
|
588
596
|
case "published":
|
|
@@ -593,71 +601,71 @@ Use Ctrl+Enter to apply`,
|
|
|
593
601
|
return "mdi mdi-eye-outline";
|
|
594
602
|
}
|
|
595
603
|
});
|
|
596
|
-
return (
|
|
597
|
-
var
|
|
598
|
-
return
|
|
604
|
+
return (m, D) => {
|
|
605
|
+
var te, ne;
|
|
606
|
+
return h(), y("div", ro, [
|
|
599
607
|
t("div", {
|
|
600
|
-
class:
|
|
608
|
+
class: q(["controls-row title-row", { "view-title-row": e.dashboard.state !== "editing" }])
|
|
601
609
|
}, [
|
|
602
610
|
t("div", {
|
|
603
611
|
class: "dashboard-title",
|
|
604
612
|
onClick: T
|
|
605
613
|
}, [
|
|
606
|
-
a.value ?
|
|
614
|
+
a.value ? ce((h(), y("input", {
|
|
607
615
|
key: 1,
|
|
608
616
|
ref_key: "titleInput",
|
|
609
|
-
ref:
|
|
617
|
+
ref: w,
|
|
610
618
|
"data-testid": "dashboard-title-input",
|
|
611
|
-
"onUpdate:modelValue":
|
|
612
|
-
onBlur:
|
|
619
|
+
"onUpdate:modelValue": D[0] || (D[0] = (U) => v.value = U),
|
|
620
|
+
onBlur: O,
|
|
613
621
|
onKeyup: [
|
|
614
|
-
|
|
615
|
-
|
|
622
|
+
ge(O, ["enter"]),
|
|
623
|
+
ge(W, ["esc"])
|
|
616
624
|
],
|
|
617
625
|
class: "title-input",
|
|
618
626
|
type: "text"
|
|
619
627
|
}, null, 544)), [
|
|
620
|
-
[
|
|
621
|
-
]) : (
|
|
622
|
-
t("span",
|
|
623
|
-
e.editsLocked ? R("", !0) : (
|
|
628
|
+
[pe, v.value]
|
|
629
|
+
]) : (h(), y("span", lo, [
|
|
630
|
+
t("span", ao, P(((te = e.dashboard) == null ? void 0 : te.name) || "Untitled Dashboard"), 1),
|
|
631
|
+
e.editsLocked ? R("", !0) : (h(), y("span", so, [...D[6] || (D[6] = [
|
|
624
632
|
t("i", { class: "mdi mdi-pencil-outline" }, null, -1)
|
|
625
633
|
])]))
|
|
626
634
|
]))
|
|
627
635
|
]),
|
|
628
|
-
e.dashboard.state === "editing" ? (
|
|
629
|
-
t("div",
|
|
630
|
-
t("div",
|
|
631
|
-
|
|
636
|
+
e.dashboard.state === "editing" ? (h(), y("div", uo, [
|
|
637
|
+
t("div", co, [
|
|
638
|
+
t("div", mo, [
|
|
639
|
+
D[7] || (D[7] = t("i", { class: "mdi mdi-database-outline select-icon" }, null, -1)),
|
|
632
640
|
t("select", {
|
|
633
641
|
id: "connection",
|
|
634
642
|
"data-testid": "connection-selector",
|
|
635
|
-
onChange:
|
|
643
|
+
onChange: D[1] || (D[1] = (U) => m.$emit("connection-change", U)),
|
|
636
644
|
value: e.selectedConnection,
|
|
637
645
|
title: e.selectedConnection
|
|
638
646
|
}, [
|
|
639
|
-
(
|
|
647
|
+
(h(!0), y(fe, null, we(Object.values(ie(r).connections).filter(
|
|
640
648
|
(U) => U.model
|
|
641
|
-
), (U) => (
|
|
649
|
+
), (U) => (h(), y("option", {
|
|
642
650
|
key: U.name,
|
|
643
651
|
value: U.name
|
|
644
|
-
},
|
|
645
|
-
], 40,
|
|
652
|
+
}, P(U.name), 9, fo))), 128))
|
|
653
|
+
], 40, ho)
|
|
646
654
|
])
|
|
647
655
|
]),
|
|
648
656
|
z(pt, {
|
|
649
|
-
"available-imports":
|
|
657
|
+
"available-imports": V.value,
|
|
650
658
|
"active-imports": $.value,
|
|
651
659
|
"onUpdate:imports": g,
|
|
652
|
-
onExplore:
|
|
660
|
+
onExplore: D[2] || (D[2] = (U) => ie(s).openTab("editors", null, U.id))
|
|
653
661
|
}, null, 8, ["available-imports", "active-imports"]),
|
|
654
|
-
t("div",
|
|
662
|
+
t("div", vo, [
|
|
655
663
|
t("button", {
|
|
656
|
-
onClick:
|
|
664
|
+
onClick: D[3] || (D[3] = (U) => m.$emit("add-item")),
|
|
657
665
|
class: "btn btn-success",
|
|
658
666
|
"data-testid": "add-item-button",
|
|
659
667
|
title: "Add Item"
|
|
660
|
-
}, [...
|
|
668
|
+
}, [...D[8] || (D[8] = [
|
|
661
669
|
t("i", {
|
|
662
670
|
class: "mdi mdi-plus top-action-icon",
|
|
663
671
|
"aria-hidden": "true"
|
|
@@ -665,11 +673,11 @@ Use Ctrl+Enter to apply`,
|
|
|
665
673
|
t("span", { class: "top-action-label" }, "Add", -1)
|
|
666
674
|
])]),
|
|
667
675
|
t("button", {
|
|
668
|
-
onClick:
|
|
676
|
+
onClick: D[4] || (D[4] = (U) => m.$emit("clear-items")),
|
|
669
677
|
class: "btn btn-danger",
|
|
670
678
|
"data-testid": "clear-items-button",
|
|
671
679
|
title: "Clear All"
|
|
672
|
-
}, [...
|
|
680
|
+
}, [...D[9] || (D[9] = [
|
|
673
681
|
t("i", {
|
|
674
682
|
class: "mdi mdi-delete-outline top-action-icon",
|
|
675
683
|
"aria-hidden": "true"
|
|
@@ -679,17 +687,17 @@ Use Ctrl+Enter to apply`,
|
|
|
679
687
|
])
|
|
680
688
|
])) : R("", !0)
|
|
681
689
|
], 2),
|
|
682
|
-
t("div",
|
|
683
|
-
z(
|
|
684
|
-
"filter-value": ((
|
|
690
|
+
t("div", po, [
|
|
691
|
+
z(io, {
|
|
692
|
+
"filter-value": ((ne = e.dashboard) == null ? void 0 : ne.filter) || "",
|
|
685
693
|
"filter-error": e.filterError,
|
|
686
694
|
"is-loading": f.value,
|
|
687
695
|
"global-completion": e.globalCompletion,
|
|
688
696
|
"validate-filter": e.validateFilter,
|
|
689
|
-
onFilterApply:
|
|
690
|
-
onClearFilter:
|
|
697
|
+
onFilterApply: x,
|
|
698
|
+
onClearFilter: D[5] || (D[5] = (U) => m.$emit("clear-filter", ""))
|
|
691
699
|
}, null, 8, ["filter-value", "filter-error", "is-loading", "global-completion", "validate-filter"]),
|
|
692
|
-
t("div",
|
|
700
|
+
t("div", yo, [
|
|
693
701
|
z(yt, {
|
|
694
702
|
action: k,
|
|
695
703
|
"use-default-style": !1,
|
|
@@ -699,7 +707,7 @@ Use Ctrl+Enter to apply`,
|
|
|
699
707
|
title: "Download dashboard image",
|
|
700
708
|
"aria-label": "Download dashboard image"
|
|
701
709
|
}, {
|
|
702
|
-
default:
|
|
710
|
+
default: ee(() => [...D[10] || (D[10] = [
|
|
703
711
|
t("i", {
|
|
704
712
|
class: "mdi mdi-download-outline filter-action-icon",
|
|
705
713
|
"aria-hidden": "true"
|
|
@@ -709,12 +717,12 @@ Use Ctrl+Enter to apply`,
|
|
|
709
717
|
_: 1
|
|
710
718
|
}),
|
|
711
719
|
t("button", {
|
|
712
|
-
onClick:
|
|
720
|
+
onClick: b,
|
|
713
721
|
class: "btn btn-secondary filter-action-btn",
|
|
714
722
|
"data-testid": "share-dashboard-button",
|
|
715
723
|
title: "Export dashboard",
|
|
716
724
|
"aria-label": "Export dashboard"
|
|
717
|
-
}, [...
|
|
725
|
+
}, [...D[11] || (D[11] = [
|
|
718
726
|
t("i", {
|
|
719
727
|
class: "mdi mdi-export-variant filter-action-icon",
|
|
720
728
|
"aria-hidden": "true"
|
|
@@ -727,17 +735,17 @@ Use Ctrl+Enter to apply`,
|
|
|
727
735
|
"data-testid": "refresh-button",
|
|
728
736
|
title: "Refresh dashboard",
|
|
729
737
|
"aria-label": "Refresh dashboard"
|
|
730
|
-
}, [...
|
|
738
|
+
}, [...D[12] || (D[12] = [
|
|
731
739
|
t("i", {
|
|
732
740
|
class: "mdi mdi-refresh filter-action-icon",
|
|
733
741
|
"aria-hidden": "true"
|
|
734
742
|
}, null, -1),
|
|
735
743
|
t("span", { class: "filter-action-label" }, "Refresh", -1)
|
|
736
744
|
])]),
|
|
737
|
-
t("div",
|
|
738
|
-
t("div",
|
|
745
|
+
t("div", go, [
|
|
746
|
+
t("div", bo, [
|
|
739
747
|
t("i", {
|
|
740
|
-
class:
|
|
748
|
+
class: q(E.value + " select-icon")
|
|
741
749
|
}, null, 2),
|
|
742
750
|
t("select", {
|
|
743
751
|
id: "viewMode",
|
|
@@ -746,7 +754,7 @@ Use Ctrl+Enter to apply`,
|
|
|
746
754
|
value: e.dashboard.state,
|
|
747
755
|
disabled: e.editsLocked,
|
|
748
756
|
class: "mode-select"
|
|
749
|
-
}, [...
|
|
757
|
+
}, [...D[13] || (D[13] = [
|
|
750
758
|
t("option", {
|
|
751
759
|
value: "editing",
|
|
752
760
|
"data-testid": "edit-mode-option"
|
|
@@ -759,7 +767,7 @@ Use Ctrl+Enter to apply`,
|
|
|
759
767
|
value: "fullscreen",
|
|
760
768
|
"data-testid": "fullscreen-mode-option"
|
|
761
769
|
}, "Fullscreen", -1)
|
|
762
|
-
])], 40,
|
|
770
|
+
])], 40, Co)
|
|
763
771
|
])
|
|
764
772
|
])
|
|
765
773
|
])
|
|
@@ -767,37 +775,37 @@ Use Ctrl+Enter to apply`,
|
|
|
767
775
|
z(Rt, {
|
|
768
776
|
dashboard: e.dashboard,
|
|
769
777
|
"is-open": c.value,
|
|
770
|
-
onClose:
|
|
778
|
+
onClose: I
|
|
771
779
|
}, null, 8, ["dashboard", "is-open"])
|
|
772
780
|
]);
|
|
773
781
|
};
|
|
774
782
|
}
|
|
775
|
-
}),
|
|
776
|
-
function
|
|
777
|
-
const
|
|
783
|
+
}), Wi = /* @__PURE__ */ Y(wo, [["__scopeId", "data-v-b0dab49c"]]);
|
|
784
|
+
function Re(e) {
|
|
785
|
+
const n = S(null), o = S(!1), l = S(null), r = S(!1), i = S(null), s = S(!1), f = () => {
|
|
778
786
|
i.value && (clearTimeout(i.value), i.value = null);
|
|
779
787
|
}, c = () => {
|
|
780
|
-
if (!
|
|
781
|
-
const
|
|
788
|
+
if (!n.value) return 0;
|
|
789
|
+
const I = n.value.getBoundingClientRect(), x = window.scrollY || document.documentElement.scrollTop, k = I.top + x, M = Math.floor(k / 200) * 10;
|
|
782
790
|
return Math.min(M, 100);
|
|
783
791
|
};
|
|
784
|
-
|
|
792
|
+
Ge(() => {
|
|
785
793
|
setTimeout(() => {
|
|
786
|
-
const
|
|
794
|
+
const I = c();
|
|
787
795
|
if (!e.results.value) {
|
|
788
|
-
|
|
796
|
+
o.value = !0;
|
|
789
797
|
return;
|
|
790
798
|
}
|
|
791
799
|
setTimeout(() => {
|
|
792
|
-
|
|
793
|
-
},
|
|
800
|
+
o.value = !0;
|
|
801
|
+
}, I);
|
|
794
802
|
}, 0);
|
|
795
|
-
}),
|
|
803
|
+
}), ot(() => {
|
|
796
804
|
f();
|
|
797
|
-
}),
|
|
805
|
+
}), ue(
|
|
798
806
|
e.loading,
|
|
799
|
-
(
|
|
800
|
-
if (f(),
|
|
807
|
+
(I) => {
|
|
808
|
+
if (f(), I) {
|
|
801
809
|
i.value = setTimeout(() => {
|
|
802
810
|
r.value = !0, i.value = null;
|
|
803
811
|
}, e.loadingDelayMs ?? 150);
|
|
@@ -810,25 +818,25 @@ function Le(e) {
|
|
|
810
818
|
const a = async () => {
|
|
811
819
|
var M;
|
|
812
820
|
if (!e.query.value) return;
|
|
813
|
-
const
|
|
821
|
+
const I = e.dashboardId(), x = e.itemId(), k = e.getDashboardQueryExecutor(I);
|
|
814
822
|
if (!k)
|
|
815
823
|
throw new Error("Dashboard query executor not found!");
|
|
816
824
|
try {
|
|
817
|
-
(M = e.analyticsStore) == null || M.log(e.analyticsEvent, e.analyticsType, !0), l.value && k.cancelQuery(l.value), l.value = await k.runSingle(
|
|
825
|
+
(M = e.analyticsStore) == null || M.log(e.analyticsEvent, e.analyticsType, !0), l.value && k.cancelQuery(l.value), l.value = await k.runSingle(x), await k.waitForQuery(l.value);
|
|
818
826
|
} catch (T) {
|
|
819
827
|
console.error("Error setting up query:", T), l.value = null;
|
|
820
828
|
}
|
|
821
829
|
};
|
|
822
830
|
return {
|
|
823
|
-
chartContainer:
|
|
824
|
-
ready:
|
|
831
|
+
chartContainer: n,
|
|
832
|
+
ready: o,
|
|
825
833
|
showLoading: r,
|
|
826
834
|
controlsVisible: s,
|
|
827
835
|
executeQuery: a,
|
|
828
836
|
handleLocalRefresh: () => {
|
|
829
|
-
const
|
|
830
|
-
if (
|
|
831
|
-
|
|
837
|
+
const I = e.onRefresh.value;
|
|
838
|
+
if (I) {
|
|
839
|
+
I(e.itemId());
|
|
832
840
|
return;
|
|
833
841
|
}
|
|
834
842
|
a();
|
|
@@ -841,12 +849,12 @@ function Le(e) {
|
|
|
841
849
|
}
|
|
842
850
|
};
|
|
843
851
|
}
|
|
844
|
-
const
|
|
852
|
+
const ko = J({
|
|
845
853
|
name: "DashboardChart",
|
|
846
854
|
components: {
|
|
847
855
|
VegaLiteChart: bt,
|
|
848
|
-
ErrorMessage:
|
|
849
|
-
LoadingView:
|
|
856
|
+
ErrorMessage: Le,
|
|
857
|
+
LoadingView: Me,
|
|
850
858
|
DrilldownPane: gt
|
|
851
859
|
},
|
|
852
860
|
props: {
|
|
@@ -881,38 +889,38 @@ const kn = J({
|
|
|
881
889
|
required: !0
|
|
882
890
|
}
|
|
883
891
|
},
|
|
884
|
-
setup(e, { emit:
|
|
885
|
-
const
|
|
892
|
+
setup(e, { emit: n }) {
|
|
893
|
+
const o = S(null), l = p(() => e.getItemData(e.itemId, e.dashboardId)), r = p(() => l.value.structured_content.query), i = p(() => l.value.results || null), s = p(() => l.value.name || ""), f = p(() => (l.value.height || 300) - 75), c = p(() => l.value.width || 300), a = p(() => {
|
|
886
894
|
if (l.value.chartConfig)
|
|
887
895
|
return {
|
|
888
896
|
...l.value.chartConfig,
|
|
889
897
|
showTitle: !1
|
|
890
898
|
};
|
|
891
|
-
}), v = p(() => l.value.loading || !1),
|
|
899
|
+
}), v = p(() => l.value.loading || !1), w = p(() => l.value.error || null), b = p(() => l.value.filters || []), I = p(() => l.value.loadStartTime || null), x = p(() => (l.value.chartFilters || []).map((G) => G.value)), k = p(() => l.value.hasDrilldown), M = p(() => l.value.onRefresh || null), T = j(
|
|
892
900
|
"analyticsStore",
|
|
893
901
|
null
|
|
894
|
-
),
|
|
895
|
-
const
|
|
896
|
-
...
|
|
902
|
+
), O = (G) => {
|
|
903
|
+
const re = {
|
|
904
|
+
...G,
|
|
897
905
|
showTitle: !1
|
|
898
906
|
};
|
|
899
907
|
if (k.value) {
|
|
900
908
|
e.setItemData(e.itemId, e.dashboardId, {
|
|
901
|
-
drilldownChartConfig:
|
|
909
|
+
drilldownChartConfig: re
|
|
902
910
|
});
|
|
903
911
|
return;
|
|
904
912
|
}
|
|
905
|
-
e.setItemData(e.itemId, e.dashboardId, { chartConfig:
|
|
913
|
+
e.setItemData(e.itemId, e.dashboardId, { chartConfig: re });
|
|
906
914
|
}, {
|
|
907
|
-
chartContainer:
|
|
908
|
-
ready:
|
|
915
|
+
chartContainer: W,
|
|
916
|
+
ready: V,
|
|
909
917
|
showLoading: $,
|
|
910
918
|
controlsVisible: g,
|
|
911
919
|
executeQuery: B,
|
|
912
|
-
handleLocalRefresh:
|
|
913
|
-
onChartMouseEnter:
|
|
914
|
-
onChartMouseLeave:
|
|
915
|
-
} =
|
|
920
|
+
handleLocalRefresh: E,
|
|
921
|
+
onChartMouseEnter: m,
|
|
922
|
+
onChartMouseLeave: D
|
|
923
|
+
} = Re({
|
|
916
924
|
dashboardId: () => e.dashboardId,
|
|
917
925
|
itemId: () => e.itemId,
|
|
918
926
|
query: r,
|
|
@@ -926,63 +934,63 @@ const kn = J({
|
|
|
926
934
|
loadingDelayMs: 250
|
|
927
935
|
});
|
|
928
936
|
return {
|
|
929
|
-
chartContainer:
|
|
937
|
+
chartContainer: W,
|
|
930
938
|
results: i,
|
|
931
|
-
ready:
|
|
939
|
+
ready: V,
|
|
932
940
|
loading: v,
|
|
933
941
|
showLoading: $,
|
|
934
|
-
error:
|
|
935
|
-
filters:
|
|
942
|
+
error: w,
|
|
943
|
+
filters: b,
|
|
936
944
|
query: r,
|
|
937
945
|
chartHeight: f,
|
|
938
946
|
chartWidth: c,
|
|
939
947
|
chartConfig: a,
|
|
940
948
|
chartTitle: s,
|
|
941
|
-
onChartConfigChange:
|
|
949
|
+
onChartConfigChange: O,
|
|
942
950
|
onRefresh: M,
|
|
943
|
-
handleLocalRefresh:
|
|
944
|
-
chartSelection:
|
|
945
|
-
startTime:
|
|
946
|
-
handleDimensionClick: (
|
|
947
|
-
|
|
951
|
+
handleLocalRefresh: E,
|
|
952
|
+
chartSelection: x,
|
|
953
|
+
startTime: I,
|
|
954
|
+
handleDimensionClick: (G) => {
|
|
955
|
+
n("dimension-click", {
|
|
948
956
|
source: e.itemId,
|
|
949
|
-
filters:
|
|
950
|
-
chart:
|
|
951
|
-
append:
|
|
957
|
+
filters: G.filters,
|
|
958
|
+
chart: G.chart,
|
|
959
|
+
append: G.append
|
|
952
960
|
});
|
|
953
961
|
},
|
|
954
962
|
handleBackgroundClick: () => {
|
|
955
|
-
|
|
963
|
+
n("background-click");
|
|
956
964
|
},
|
|
957
|
-
activeDrilldown:
|
|
958
|
-
activateDrilldown: (
|
|
959
|
-
let
|
|
960
|
-
|
|
965
|
+
activeDrilldown: o,
|
|
966
|
+
activateDrilldown: (G) => {
|
|
967
|
+
let re = G.filters, le = Object.keys(re)[0], X = mt(G.filters);
|
|
968
|
+
le && (o.value = { remove: le, filter: X });
|
|
961
969
|
},
|
|
962
|
-
submitDrilldown: async (
|
|
963
|
-
let
|
|
970
|
+
submitDrilldown: async (G) => {
|
|
971
|
+
let le = await e.getDashboardQueryExecutor(e.dashboardId).createDrilldownQuery(
|
|
964
972
|
r.value,
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
|
|
973
|
+
G,
|
|
974
|
+
o.value.remove,
|
|
975
|
+
o.value.filter,
|
|
968
976
|
l.value.rootContent || [],
|
|
969
|
-
(l.value.imports || []).map((
|
|
977
|
+
(l.value.imports || []).map((X) => ({ name: X.name, alias: X.alias }))
|
|
970
978
|
);
|
|
971
979
|
e.setItemData(e.itemId, e.dashboardId, {
|
|
972
|
-
drilldown:
|
|
980
|
+
drilldown: le,
|
|
973
981
|
drilldownChartConfig: null,
|
|
974
982
|
loading: !0
|
|
975
|
-
}), $.value = !0,
|
|
976
|
-
|
|
977
|
-
}).catch((
|
|
978
|
-
console.error("Error executing drilldown query:",
|
|
983
|
+
}), $.value = !0, o.value = null, await B().then(() => {
|
|
984
|
+
V.value = !0;
|
|
985
|
+
}).catch((X) => {
|
|
986
|
+
console.error("Error executing drilldown query:", X), V.value = !0;
|
|
979
987
|
}).finally(() => {
|
|
980
988
|
$.value = !1;
|
|
981
989
|
});
|
|
982
990
|
},
|
|
983
991
|
controlsVisible: g,
|
|
984
|
-
onChartMouseEnter:
|
|
985
|
-
onChartMouseLeave:
|
|
992
|
+
onChartMouseEnter: m,
|
|
993
|
+
onChartMouseLeave: D,
|
|
986
994
|
revertDrilldown: async () => {
|
|
987
995
|
e.setItemData(e.itemId, e.dashboardId, {
|
|
988
996
|
drilldown: null,
|
|
@@ -993,32 +1001,32 @@ const kn = J({
|
|
|
993
1001
|
hasDrilldown: k
|
|
994
1002
|
};
|
|
995
1003
|
}
|
|
996
|
-
}),
|
|
1004
|
+
}), So = {
|
|
997
1005
|
key: 3,
|
|
998
1006
|
class: "loading-overlay"
|
|
999
1007
|
};
|
|
1000
|
-
function
|
|
1001
|
-
const s =
|
|
1002
|
-
return
|
|
1008
|
+
function Eo(e, n, o, l, r, i) {
|
|
1009
|
+
const s = Z("drilldown-pane"), f = Z("ErrorMessage"), c = Z("VegaLiteChart"), a = Z("LoadingView");
|
|
1010
|
+
return h(), y("div", {
|
|
1003
1011
|
ref: "chartContainer",
|
|
1004
|
-
class:
|
|
1005
|
-
onMouseenter:
|
|
1006
|
-
onMouseleave:
|
|
1012
|
+
class: q(["chart-placeholder no-drag", { "chart-placeholder-edit-mode": e.editMode }]),
|
|
1013
|
+
onMouseenter: n[3] || (n[3] = (...v) => e.onChartMouseEnter && e.onChartMouseEnter(...v)),
|
|
1014
|
+
onMouseleave: n[4] || (n[4] = (...v) => e.onChartMouseLeave && e.onChartMouseLeave(...v))
|
|
1007
1015
|
}, [
|
|
1008
|
-
e.activeDrilldown ? (
|
|
1016
|
+
e.activeDrilldown ? (h(), _(s, {
|
|
1009
1017
|
key: 0,
|
|
1010
1018
|
"drilldown-remove": e.activeDrilldown.remove,
|
|
1011
1019
|
"drilldown-filter": e.activeDrilldown.filter,
|
|
1012
|
-
onClose:
|
|
1020
|
+
onClose: n[0] || (n[0] = (v) => e.activeDrilldown = null),
|
|
1013
1021
|
symbols: e.symbols,
|
|
1014
1022
|
onSubmit: e.submitDrilldown
|
|
1015
|
-
}, null, 8, ["drilldown-remove", "drilldown-filter", "symbols", "onSubmit"])) : e.error && !e.loading ? (
|
|
1023
|
+
}, null, 8, ["drilldown-remove", "drilldown-filter", "symbols", "onSubmit"])) : e.error && !e.loading ? (h(), _(f, {
|
|
1016
1024
|
key: 1,
|
|
1017
1025
|
compact: !0,
|
|
1018
1026
|
details: e.error,
|
|
1019
1027
|
query: e.query,
|
|
1020
1028
|
filters: e.filters
|
|
1021
|
-
}, null, 8, ["details", "query", "filters"])) : e.results && e.ready ? (
|
|
1029
|
+
}, null, 8, ["details", "query", "filters"])) : e.results && e.ready ? (h(), _(c, {
|
|
1022
1030
|
key: 2,
|
|
1023
1031
|
id: `${e.itemId}-${e.dashboardId}`,
|
|
1024
1032
|
columns: e.results.headers,
|
|
@@ -1037,40 +1045,40 @@ function Dn(e, o, n, l, r, i) {
|
|
|
1037
1045
|
onDrilldownClick: e.activateDrilldown,
|
|
1038
1046
|
onRevertDrilldown: e.revertDrilldown
|
|
1039
1047
|
}, null, 8, ["id", "columns", "data", "showControls", "initialConfig", "containerHeight", "container-width", "onChartConfigChange", "chartSelection", "chartTitle", "drilldown-active", "onDimensionClick", "onBackgroundClick", "onRefreshClick", "onDrilldownClick", "onRevertDrilldown"])) : R("", !0),
|
|
1040
|
-
e.loading && e.showLoading ? (
|
|
1048
|
+
e.loading && e.showLoading ? (h(), y("div", So, [
|
|
1041
1049
|
z(a, {
|
|
1042
1050
|
startTime: e.startTime,
|
|
1043
1051
|
text: "",
|
|
1044
1052
|
subtle: ""
|
|
1045
1053
|
}, null, 8, ["startTime"])
|
|
1046
1054
|
])) : R("", !0),
|
|
1047
|
-
!e.editMode || !(e.results && e.ready) ? (
|
|
1055
|
+
!e.editMode || !(e.results && e.ready) ? (h(), y("div", {
|
|
1048
1056
|
key: 4,
|
|
1049
|
-
class:
|
|
1057
|
+
class: q(["controls-toggle", { "controls-visible": e.controlsVisible }])
|
|
1050
1058
|
}, [
|
|
1051
1059
|
t("button", {
|
|
1052
|
-
onClick:
|
|
1060
|
+
onClick: n[1] || (n[1] = (...v) => e.handleLocalRefresh && e.handleLocalRefresh(...v)),
|
|
1053
1061
|
class: "control-btn",
|
|
1054
1062
|
"data-testid": "refresh-chart-btn",
|
|
1055
1063
|
title: "Refresh table"
|
|
1056
|
-
}, [...
|
|
1064
|
+
}, [...n[5] || (n[5] = [
|
|
1057
1065
|
t("i", { class: "mdi mdi-refresh icon" }, null, -1)
|
|
1058
1066
|
])]),
|
|
1059
1067
|
t("button", {
|
|
1060
|
-
onClick:
|
|
1068
|
+
onClick: n[2] || (n[2] = (...v) => e.revertDrilldown && e.revertDrilldown(...v)),
|
|
1061
1069
|
class: "control-btn",
|
|
1062
1070
|
"data-testid": "refresh-chart-btn",
|
|
1063
1071
|
title: "Clear Drilldown"
|
|
1064
|
-
}, [...
|
|
1072
|
+
}, [...n[6] || (n[6] = [
|
|
1065
1073
|
t("i", { class: "mdi mdi-undo icon" }, null, -1)
|
|
1066
1074
|
])])
|
|
1067
1075
|
], 2)) : R("", !0)
|
|
1068
1076
|
], 34);
|
|
1069
1077
|
}
|
|
1070
|
-
const
|
|
1078
|
+
const Do = /* @__PURE__ */ Y(ko, [["render", Eo], ["__scopeId", "data-v-36046d80"]]), Io = J({
|
|
1071
1079
|
name: "DynamicMarkdownChart",
|
|
1072
1080
|
components: {
|
|
1073
|
-
ErrorMessage:
|
|
1081
|
+
ErrorMessage: Le,
|
|
1074
1082
|
MarkdownRenderer: Ct
|
|
1075
1083
|
},
|
|
1076
1084
|
props: {
|
|
@@ -1102,17 +1110,17 @@ const En = /* @__PURE__ */ Y(kn, [["render", Dn], ["__scopeId", "data-v-36046d80
|
|
|
1102
1110
|
}
|
|
1103
1111
|
},
|
|
1104
1112
|
setup(e) {
|
|
1105
|
-
const
|
|
1106
|
-
if (!
|
|
1113
|
+
const n = p(() => e.getItemData(e.itemId, e.dashboardId)), o = p(() => n.value.structured_content || { markdown: "", query: "" }), l = p(() => o.value.markdown || ""), r = p(() => o.value.query || ""), i = p(() => n.value.results || null), s = p(() => n.value.loading || !1), f = p(() => n.value.error || null), c = p(() => n.value.filters || []), a = p(() => n.value.loadStartTime || null), v = p(() => n.value.onRefresh || null), w = j("connectionStore"), b = j("analyticsStore");
|
|
1114
|
+
if (!w)
|
|
1107
1115
|
throw new Error("Connection store not found!");
|
|
1108
1116
|
const {
|
|
1109
|
-
chartContainer:
|
|
1110
|
-
ready:
|
|
1117
|
+
chartContainer: I,
|
|
1118
|
+
ready: x,
|
|
1111
1119
|
controlsVisible: k,
|
|
1112
1120
|
handleLocalRefresh: M,
|
|
1113
1121
|
onChartMouseEnter: T,
|
|
1114
|
-
onChartMouseLeave:
|
|
1115
|
-
} =
|
|
1122
|
+
onChartMouseLeave: O
|
|
1123
|
+
} = Re({
|
|
1116
1124
|
dashboardId: () => e.dashboardId,
|
|
1117
1125
|
itemId: () => e.itemId,
|
|
1118
1126
|
query: r,
|
|
@@ -1120,14 +1128,14 @@ const En = /* @__PURE__ */ Y(kn, [["render", Dn], ["__scopeId", "data-v-36046d80
|
|
|
1120
1128
|
loading: s,
|
|
1121
1129
|
onRefresh: v,
|
|
1122
1130
|
getDashboardQueryExecutor: e.getDashboardQueryExecutor,
|
|
1123
|
-
analyticsStore:
|
|
1131
|
+
analyticsStore: b,
|
|
1124
1132
|
analyticsEvent: "dashboard-markdown-execution",
|
|
1125
1133
|
analyticsType: "MARKDOWN"
|
|
1126
1134
|
});
|
|
1127
1135
|
return {
|
|
1128
|
-
chartContainer:
|
|
1136
|
+
chartContainer: I,
|
|
1129
1137
|
results: i,
|
|
1130
|
-
ready:
|
|
1138
|
+
ready: x,
|
|
1131
1139
|
loading: s,
|
|
1132
1140
|
error: f,
|
|
1133
1141
|
filters: c,
|
|
@@ -1137,51 +1145,51 @@ const En = /* @__PURE__ */ Y(kn, [["render", Dn], ["__scopeId", "data-v-36046d80
|
|
|
1137
1145
|
startTime: a,
|
|
1138
1146
|
controlsVisible: k,
|
|
1139
1147
|
onChartMouseEnter: T,
|
|
1140
|
-
onChartMouseLeave:
|
|
1148
|
+
onChartMouseLeave: O
|
|
1141
1149
|
};
|
|
1142
1150
|
}
|
|
1143
1151
|
});
|
|
1144
|
-
function
|
|
1145
|
-
const s =
|
|
1146
|
-
return
|
|
1152
|
+
function To(e, n, o, l, r, i) {
|
|
1153
|
+
const s = Z("ErrorMessage"), f = Z("MarkdownRenderer");
|
|
1154
|
+
return h(), y("div", {
|
|
1147
1155
|
ref: "chartContainer",
|
|
1148
|
-
class:
|
|
1149
|
-
onMouseenter:
|
|
1150
|
-
onMouseleave:
|
|
1156
|
+
class: q(["chart-placeholder no-drag", { "chart-placeholder-edit-mode": e.editMode }]),
|
|
1157
|
+
onMouseenter: n[1] || (n[1] = (...c) => e.onChartMouseEnter && e.onChartMouseEnter(...c)),
|
|
1158
|
+
onMouseleave: n[2] || (n[2] = (...c) => e.onChartMouseLeave && e.onChartMouseLeave(...c))
|
|
1151
1159
|
}, [
|
|
1152
|
-
e.error && !e.loading ? (
|
|
1160
|
+
e.error && !e.loading ? (h(), _(s, {
|
|
1153
1161
|
key: 0,
|
|
1154
1162
|
compact: !0,
|
|
1155
1163
|
details: e.error,
|
|
1156
1164
|
query: e.query,
|
|
1157
1165
|
filters: e.filters
|
|
1158
|
-
}, null, 8, ["details", "query", "filters"])) : e.ready ? (
|
|
1166
|
+
}, null, 8, ["details", "query", "filters"])) : e.ready ? (h(), _(f, {
|
|
1159
1167
|
key: 1,
|
|
1160
1168
|
markdown: e.markdown,
|
|
1161
1169
|
results: e.results,
|
|
1162
1170
|
loading: e.loading
|
|
1163
1171
|
}, null, 8, ["markdown", "results", "loading"])) : R("", !0),
|
|
1164
|
-
!e.loading && e.editMode ? (
|
|
1172
|
+
!e.loading && e.editMode ? (h(), y("div", {
|
|
1165
1173
|
key: 2,
|
|
1166
|
-
class:
|
|
1174
|
+
class: q(["controls-toggle", { "controls-visible": e.controlsVisible }])
|
|
1167
1175
|
}, [
|
|
1168
1176
|
t("button", {
|
|
1169
|
-
onClick:
|
|
1177
|
+
onClick: n[0] || (n[0] = (...c) => e.handleLocalRefresh && e.handleLocalRefresh(...c)),
|
|
1170
1178
|
class: "control-btn",
|
|
1171
1179
|
"data-testid": "refresh-chart-btn",
|
|
1172
1180
|
title: "Refresh text"
|
|
1173
|
-
}, [...
|
|
1181
|
+
}, [...n[3] || (n[3] = [
|
|
1174
1182
|
t("i", { class: "mdi mdi-refresh icon" }, null, -1)
|
|
1175
1183
|
])])
|
|
1176
1184
|
], 2)) : R("", !0)
|
|
1177
1185
|
], 34);
|
|
1178
1186
|
}
|
|
1179
|
-
const $
|
|
1187
|
+
const $o = /* @__PURE__ */ Y(Io, [["render", To], ["__scopeId", "data-v-ffafce48"]]), Lo = J({
|
|
1180
1188
|
name: "DashboardTable",
|
|
1181
1189
|
components: {
|
|
1182
1190
|
DataTable: wt,
|
|
1183
|
-
ErrorMessage:
|
|
1184
|
-
LoadingView:
|
|
1191
|
+
ErrorMessage: Le,
|
|
1192
|
+
LoadingView: Me
|
|
1185
1193
|
},
|
|
1186
1194
|
props: {
|
|
1187
1195
|
dashboardId: {
|
|
@@ -1211,32 +1219,32 @@ const $n = /* @__PURE__ */ Y(Tn, [["render", In], ["__scopeId", "data-v-ffafce48
|
|
|
1211
1219
|
required: !0
|
|
1212
1220
|
}
|
|
1213
1221
|
},
|
|
1214
|
-
setup(e, { emit:
|
|
1215
|
-
const
|
|
1216
|
-
if (!
|
|
1222
|
+
setup(e, { emit: n }) {
|
|
1223
|
+
const o = p(() => e.getItemData(e.itemId, e.dashboardId)), l = p(() => o.value.content), r = p(() => o.value.results || null), i = p(() => o.value.loading || !1), s = p(() => o.value.error || null), f = p(() => o.value.filters || []), c = p(() => o.value.loadStartTime || null), a = p(() => (o.value.height || 300) - 75), v = p(() => (o.value.width || 300) - 100), w = p(() => o.value.onRefresh || null), b = j("connectionStore"), I = j("analyticsStore");
|
|
1224
|
+
if (!b)
|
|
1217
1225
|
throw new Error("Connection store not found!");
|
|
1218
1226
|
const {
|
|
1219
|
-
chartContainer:
|
|
1227
|
+
chartContainer: x,
|
|
1220
1228
|
ready: k,
|
|
1221
1229
|
showLoading: M,
|
|
1222
1230
|
controlsVisible: T,
|
|
1223
|
-
handleLocalRefresh:
|
|
1224
|
-
onChartMouseEnter:
|
|
1225
|
-
onChartMouseLeave:
|
|
1226
|
-
} =
|
|
1231
|
+
handleLocalRefresh: O,
|
|
1232
|
+
onChartMouseEnter: W,
|
|
1233
|
+
onChartMouseLeave: V
|
|
1234
|
+
} = Re({
|
|
1227
1235
|
dashboardId: () => e.dashboardId,
|
|
1228
1236
|
itemId: () => e.itemId,
|
|
1229
1237
|
query: l,
|
|
1230
1238
|
results: r,
|
|
1231
1239
|
loading: i,
|
|
1232
|
-
onRefresh:
|
|
1240
|
+
onRefresh: w,
|
|
1233
1241
|
getDashboardQueryExecutor: e.getDashboardQueryExecutor,
|
|
1234
|
-
analyticsStore:
|
|
1242
|
+
analyticsStore: I,
|
|
1235
1243
|
analyticsEvent: "dashboard-table-execution",
|
|
1236
1244
|
analyticsType: "TABLE"
|
|
1237
1245
|
});
|
|
1238
1246
|
return {
|
|
1239
|
-
chartContainer:
|
|
1247
|
+
chartContainer: x,
|
|
1240
1248
|
results: r,
|
|
1241
1249
|
ready: k,
|
|
1242
1250
|
loading: i,
|
|
@@ -1246,11 +1254,11 @@ const $n = /* @__PURE__ */ Y(Tn, [["render", In], ["__scopeId", "data-v-ffafce48
|
|
|
1246
1254
|
query: l,
|
|
1247
1255
|
chartHeight: a,
|
|
1248
1256
|
chartWidth: v,
|
|
1249
|
-
onRefresh:
|
|
1250
|
-
handleLocalRefresh:
|
|
1257
|
+
onRefresh: w,
|
|
1258
|
+
handleLocalRefresh: O,
|
|
1251
1259
|
startTime: c,
|
|
1252
1260
|
handleDimensionClick: (B) => {
|
|
1253
|
-
|
|
1261
|
+
n("dimension-click", {
|
|
1254
1262
|
source: e.itemId,
|
|
1255
1263
|
filters: B.filters,
|
|
1256
1264
|
chart: B.chart,
|
|
@@ -1258,32 +1266,32 @@ const $n = /* @__PURE__ */ Y(Tn, [["render", In], ["__scopeId", "data-v-ffafce48
|
|
|
1258
1266
|
});
|
|
1259
1267
|
},
|
|
1260
1268
|
handleBackgroundClick: () => {
|
|
1261
|
-
|
|
1269
|
+
n("background-click");
|
|
1262
1270
|
},
|
|
1263
1271
|
controlsVisible: T,
|
|
1264
|
-
onChartMouseEnter:
|
|
1265
|
-
onChartMouseLeave:
|
|
1272
|
+
onChartMouseEnter: W,
|
|
1273
|
+
onChartMouseLeave: V
|
|
1266
1274
|
};
|
|
1267
1275
|
}
|
|
1268
|
-
}),
|
|
1276
|
+
}), Mo = {
|
|
1269
1277
|
key: 2,
|
|
1270
1278
|
class: "loading-overlay"
|
|
1271
1279
|
};
|
|
1272
|
-
function
|
|
1273
|
-
const s =
|
|
1274
|
-
return
|
|
1280
|
+
function Ro(e, n, o, l, r, i) {
|
|
1281
|
+
const s = Z("ErrorMessage"), f = Z("data-table"), c = Z("LoadingView");
|
|
1282
|
+
return h(), y("div", {
|
|
1275
1283
|
ref: "chartContainer",
|
|
1276
|
-
class:
|
|
1277
|
-
onMouseenter:
|
|
1278
|
-
onMouseleave:
|
|
1284
|
+
class: q(["chart-placeholder no-drag", { "chart-placeholder-edit-mode": e.editMode }]),
|
|
1285
|
+
onMouseenter: n[1] || (n[1] = (...a) => e.onChartMouseEnter && e.onChartMouseEnter(...a)),
|
|
1286
|
+
onMouseleave: n[2] || (n[2] = (...a) => e.onChartMouseLeave && e.onChartMouseLeave(...a))
|
|
1279
1287
|
}, [
|
|
1280
|
-
e.error && !e.loading ? (
|
|
1288
|
+
e.error && !e.loading ? (h(), _(s, {
|
|
1281
1289
|
key: 0,
|
|
1282
1290
|
compact: !0,
|
|
1283
1291
|
details: e.error,
|
|
1284
1292
|
query: e.query,
|
|
1285
1293
|
filters: e.filters
|
|
1286
|
-
}, null, 8, ["details", "query", "filters"])) : e.results && e.ready ? (
|
|
1294
|
+
}, null, 8, ["details", "query", "filters"])) : e.results && e.ready ? (h(), _(f, {
|
|
1287
1295
|
key: 1,
|
|
1288
1296
|
id: `${e.itemId}-${e.dashboardId}`,
|
|
1289
1297
|
headers: e.results.headers,
|
|
@@ -1295,29 +1303,29 @@ function Rn(e, o, n, l, r, i) {
|
|
|
1295
1303
|
onCellClick: e.handleDimensionClick,
|
|
1296
1304
|
onBackgroundClick: e.handleBackgroundClick
|
|
1297
1305
|
}, null, 8, ["id", "headers", "results", "containerHeight", "onCellClick", "onBackgroundClick"])) : R("", !0),
|
|
1298
|
-
e.loading && e.showLoading ? (
|
|
1306
|
+
e.loading && e.showLoading ? (h(), y("div", Mo, [
|
|
1299
1307
|
z(c, {
|
|
1300
1308
|
startTime: e.startTime,
|
|
1301
1309
|
text: "",
|
|
1302
1310
|
subtle: ""
|
|
1303
1311
|
}, null, 8, ["startTime"])
|
|
1304
1312
|
])) : R("", !0),
|
|
1305
|
-
!e.loading && e.editMode ? (
|
|
1313
|
+
!e.loading && e.editMode ? (h(), y("div", {
|
|
1306
1314
|
key: 3,
|
|
1307
|
-
class:
|
|
1315
|
+
class: q(["controls-toggle", { "controls-visible": e.controlsVisible }])
|
|
1308
1316
|
}, [
|
|
1309
1317
|
t("button", {
|
|
1310
|
-
onClick:
|
|
1318
|
+
onClick: n[0] || (n[0] = (...a) => e.handleLocalRefresh && e.handleLocalRefresh(...a)),
|
|
1311
1319
|
class: "control-btn",
|
|
1312
1320
|
"data-testid": "refresh-chart-btn",
|
|
1313
1321
|
title: "Refresh table"
|
|
1314
|
-
}, [...
|
|
1322
|
+
}, [...n[3] || (n[3] = [
|
|
1315
1323
|
t("i", { class: "mdi mdi-refresh icon" }, null, -1)
|
|
1316
1324
|
])])
|
|
1317
1325
|
], 2)) : R("", !0)
|
|
1318
1326
|
], 34);
|
|
1319
1327
|
}
|
|
1320
|
-
const
|
|
1328
|
+
const Ao = /* @__PURE__ */ Y(Lo, [["render", Ro], ["__scopeId", "data-v-2fa93a82"]]), qo = {
|
|
1321
1329
|
data() {
|
|
1322
1330
|
return {
|
|
1323
1331
|
selectedValue: "",
|
|
@@ -1357,10 +1365,10 @@ const An = /* @__PURE__ */ Y(Ln, [["render", Rn], ["__scopeId", "data-v-2fa93a82
|
|
|
1357
1365
|
}
|
|
1358
1366
|
},
|
|
1359
1367
|
setup() {
|
|
1360
|
-
const e = j("userSettingsStore", null),
|
|
1368
|
+
const e = j("userSettingsStore", null), n = kt(e);
|
|
1361
1369
|
return {
|
|
1362
1370
|
settingsStore: e,
|
|
1363
|
-
currentTheme:
|
|
1371
|
+
currentTheme: n
|
|
1364
1372
|
};
|
|
1365
1373
|
},
|
|
1366
1374
|
computed: {
|
|
@@ -1382,23 +1390,23 @@ const An = /* @__PURE__ */ Y(Ln, [["render", Rn], ["__scopeId", "data-v-2fa93a82
|
|
|
1382
1390
|
selectOptions() {
|
|
1383
1391
|
if (!this.displayColumn || !this.valueColumn || !this.results || this.results.length === 0)
|
|
1384
1392
|
return [];
|
|
1385
|
-
const e = this.displayColumn.name,
|
|
1393
|
+
const e = this.displayColumn.name, n = this.valueColumn.name, o = [];
|
|
1386
1394
|
return this.results.forEach((l) => {
|
|
1387
|
-
const r = l[e], i = l[
|
|
1395
|
+
const r = l[e], i = l[n];
|
|
1388
1396
|
if (r != null && i !== null && i !== void 0) {
|
|
1389
1397
|
const s = this.formatValue(r, this.displayColumn);
|
|
1390
|
-
|
|
1398
|
+
o.push({
|
|
1391
1399
|
label: s,
|
|
1392
1400
|
value: i
|
|
1393
1401
|
});
|
|
1394
1402
|
}
|
|
1395
|
-
}),
|
|
1403
|
+
}), o;
|
|
1396
1404
|
},
|
|
1397
1405
|
filteredOptions() {
|
|
1398
1406
|
if (!this.searchText)
|
|
1399
1407
|
return this.selectOptions;
|
|
1400
1408
|
const e = this.searchText.toLowerCase();
|
|
1401
|
-
return this.selectOptions.filter((
|
|
1409
|
+
return this.selectOptions.filter((n) => n.label.toLowerCase().includes(e));
|
|
1402
1410
|
},
|
|
1403
1411
|
placeholderText() {
|
|
1404
1412
|
return this.hasSelection ? this.selectedLabel || "Type to search..." : !this.selectOptions || this.selectOptions.length === 0 ? "No data available" : "All";
|
|
@@ -1432,20 +1440,20 @@ const An = /* @__PURE__ */ Y(Ln, [["render", Rn], ["__scopeId", "data-v-2fa93a82
|
|
|
1432
1440
|
}
|
|
1433
1441
|
},
|
|
1434
1442
|
methods: {
|
|
1435
|
-
formatValue(e,
|
|
1436
|
-
var
|
|
1437
|
-
switch (
|
|
1438
|
-
case
|
|
1439
|
-
return (
|
|
1440
|
-
case
|
|
1441
|
-
case
|
|
1442
|
-
case
|
|
1443
|
-
case
|
|
1443
|
+
formatValue(e, n) {
|
|
1444
|
+
var o, l;
|
|
1445
|
+
switch (n.type) {
|
|
1446
|
+
case he.FLOAT:
|
|
1447
|
+
return (o = n.traits) != null && o.includes("usd") ? `$${Number(e).toFixed(n.scale || 2)}` : (l = n.traits) != null && l.includes("percent") ? `${(Number(e) * 100).toFixed(2)}%` : Number(e).toFixed(n.scale || 2);
|
|
1448
|
+
case he.DATETIME:
|
|
1449
|
+
case he.TIMESTAMP:
|
|
1450
|
+
case he.DATE:
|
|
1451
|
+
case he.TIME:
|
|
1444
1452
|
return e instanceof Date ? e.toLocaleString() : String(e);
|
|
1445
|
-
case
|
|
1453
|
+
case he.BOOLEAN:
|
|
1446
1454
|
return e ? "✓" : "✗";
|
|
1447
|
-
case
|
|
1448
|
-
case
|
|
1455
|
+
case he.ARRAY:
|
|
1456
|
+
case he.STRUCT:
|
|
1449
1457
|
return JSON.stringify(e);
|
|
1450
1458
|
default:
|
|
1451
1459
|
return String(e);
|
|
@@ -1454,7 +1462,7 @@ const An = /* @__PURE__ */ Y(Ln, [["render", Rn], ["__scopeId", "data-v-2fa93a82
|
|
|
1454
1462
|
highlightMatch(e) {
|
|
1455
1463
|
if (!this.searchText)
|
|
1456
1464
|
return e;
|
|
1457
|
-
const
|
|
1465
|
+
const n = this.searchText.toLowerCase(), l = e.toLowerCase().indexOf(n);
|
|
1458
1466
|
if (l === -1)
|
|
1459
1467
|
return e;
|
|
1460
1468
|
const r = e.slice(0, l), i = e.slice(l, l + this.searchText.length), s = e.slice(l + this.searchText.length);
|
|
@@ -1490,29 +1498,29 @@ const An = /* @__PURE__ */ Y(Ln, [["render", Rn], ["__scopeId", "data-v-2fa93a82
|
|
|
1490
1498
|
});
|
|
1491
1499
|
}
|
|
1492
1500
|
}
|
|
1493
|
-
},
|
|
1501
|
+
}, Fo = { class: "result-select row pa-0 ba-0" }, xo = { class: "select-container" }, Ho = { class: "search-input-wrapper" }, Oo = {
|
|
1494
1502
|
key: 0,
|
|
1495
1503
|
class: "inline-label"
|
|
1496
|
-
},
|
|
1497
|
-
function
|
|
1498
|
-
return
|
|
1499
|
-
t("div",
|
|
1500
|
-
t("div",
|
|
1501
|
-
i.hasSelection ? (
|
|
1502
|
-
|
|
1504
|
+
}, Vo = ["placeholder", "disabled"], Qo = ["onMousedown", "innerHTML"];
|
|
1505
|
+
function Bo(e, n, o, l, r, i) {
|
|
1506
|
+
return h(), y("div", Fo, [
|
|
1507
|
+
t("div", xo, [
|
|
1508
|
+
t("div", Ho, [
|
|
1509
|
+
i.hasSelection ? (h(), y("span", Oo, P(i.fieldLabel) + ": ", 1)) : R("", !0),
|
|
1510
|
+
ce(t("input", {
|
|
1503
1511
|
ref: "searchInput",
|
|
1504
|
-
"onUpdate:modelValue":
|
|
1512
|
+
"onUpdate:modelValue": n[0] || (n[0] = (s) => r.searchText = s),
|
|
1505
1513
|
type: "text",
|
|
1506
|
-
class:
|
|
1514
|
+
class: q(["search-input", { "has-inline-label": i.hasSelection }]),
|
|
1507
1515
|
placeholder: i.placeholderText,
|
|
1508
1516
|
disabled: !i.selectOptions || i.selectOptions.length === 0,
|
|
1509
|
-
onFocus:
|
|
1510
|
-
onInput:
|
|
1511
|
-
onBlur:
|
|
1512
|
-
}, null, 42,
|
|
1513
|
-
[
|
|
1517
|
+
onFocus: n[1] || (n[1] = (...s) => i.handleFocus && i.handleFocus(...s)),
|
|
1518
|
+
onInput: n[2] || (n[2] = (...s) => i.onSearchInput && i.onSearchInput(...s)),
|
|
1519
|
+
onBlur: n[3] || (n[3] = (...s) => i.handleBlur && i.handleBlur(...s))
|
|
1520
|
+
}, null, 42, Vo), [
|
|
1521
|
+
[pe, r.searchText]
|
|
1514
1522
|
]),
|
|
1515
|
-
|
|
1523
|
+
n[5] || (n[5] = t("span", { class: "search-icon" }, [
|
|
1516
1524
|
t("svg", {
|
|
1517
1525
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1518
1526
|
viewBox: "0 0 24 24",
|
|
@@ -1531,40 +1539,40 @@ function Bn(e, o, n, l, r, i) {
|
|
|
1531
1539
|
])
|
|
1532
1540
|
], -1))
|
|
1533
1541
|
]),
|
|
1534
|
-
(
|
|
1535
|
-
r.showDropdown && i.filteredOptions.length > 0 ? (
|
|
1542
|
+
(h(), _(nt, { to: "body" }, [
|
|
1543
|
+
r.showDropdown && i.filteredOptions.length > 0 ? (h(), y("div", {
|
|
1536
1544
|
key: 0,
|
|
1537
1545
|
class: "dropdown-list",
|
|
1538
|
-
style:
|
|
1546
|
+
style: Te(i.dropdownStyle)
|
|
1539
1547
|
}, [
|
|
1540
1548
|
t("div", {
|
|
1541
|
-
class:
|
|
1542
|
-
onMousedown:
|
|
1549
|
+
class: q(["dropdown-item select-all", { selected: !r.selectedValue }]),
|
|
1550
|
+
onMousedown: n[4] || (n[4] = Oe((...s) => i.selectAll && i.selectAll(...s), ["prevent"]))
|
|
1543
1551
|
}, " All ", 34),
|
|
1544
|
-
(
|
|
1552
|
+
(h(!0), y(fe, null, we(i.filteredOptions, (s, f) => (h(), y("div", {
|
|
1545
1553
|
key: f,
|
|
1546
|
-
class:
|
|
1547
|
-
onMousedown:
|
|
1554
|
+
class: q(["dropdown-item", { selected: r.selectedValue === s.value }]),
|
|
1555
|
+
onMousedown: Oe((c) => i.selectOption(s), ["prevent"]),
|
|
1548
1556
|
innerHTML: i.highlightMatch(s.label)
|
|
1549
|
-
}, null, 42,
|
|
1557
|
+
}, null, 42, Qo))), 128))
|
|
1550
1558
|
], 4)) : R("", !0),
|
|
1551
|
-
r.showDropdown && r.searchText && i.filteredOptions.length === 0 ? (
|
|
1559
|
+
r.showDropdown && r.searchText && i.filteredOptions.length === 0 ? (h(), y("div", {
|
|
1552
1560
|
key: 1,
|
|
1553
1561
|
class: "dropdown-list",
|
|
1554
|
-
style:
|
|
1555
|
-
}, [...
|
|
1562
|
+
style: Te(i.dropdownStyle)
|
|
1563
|
+
}, [...n[6] || (n[6] = [
|
|
1556
1564
|
t("div", { class: "dropdown-item no-results" }, "No matches found", -1)
|
|
1557
1565
|
])], 4)) : R("", !0)
|
|
1558
1566
|
]))
|
|
1559
1567
|
])
|
|
1560
1568
|
]);
|
|
1561
1569
|
}
|
|
1562
|
-
const
|
|
1570
|
+
const No = /* @__PURE__ */ Y(qo, [["render", Bo], ["__scopeId", "data-v-660a47c4"]]), Po = J({
|
|
1563
1571
|
name: "DashboardFilter",
|
|
1564
1572
|
components: {
|
|
1565
|
-
DashboardDataSelector:
|
|
1566
|
-
ErrorMessage:
|
|
1567
|
-
LoadingView:
|
|
1573
|
+
DashboardDataSelector: No,
|
|
1574
|
+
ErrorMessage: Le,
|
|
1575
|
+
LoadingView: Me
|
|
1568
1576
|
},
|
|
1569
1577
|
props: {
|
|
1570
1578
|
dashboardId: {
|
|
@@ -1594,32 +1602,32 @@ const Nn = /* @__PURE__ */ Y(qn, [["render", Bn], ["__scopeId", "data-v-660a47c4
|
|
|
1594
1602
|
required: !0
|
|
1595
1603
|
}
|
|
1596
1604
|
},
|
|
1597
|
-
setup(e, { emit:
|
|
1598
|
-
const
|
|
1599
|
-
if (!
|
|
1605
|
+
setup(e, { emit: n }) {
|
|
1606
|
+
const o = p(() => e.getItemData(e.itemId, e.dashboardId)), l = p(() => o.value.content), r = p(() => o.value.results || null), i = p(() => o.value.loading || !1), s = p(() => o.value.error || null), f = p(() => o.value.filters || []), c = p(() => o.value.loadStartTime || null), a = p(() => (o.value.height || 300) - 75), v = p(() => (o.value.width || 300) - 100), w = p(() => o.value.onRefresh || null), b = j("connectionStore"), I = j("analyticsStore");
|
|
1607
|
+
if (!b)
|
|
1600
1608
|
throw new Error("Connection store not found!");
|
|
1601
1609
|
const {
|
|
1602
|
-
chartContainer:
|
|
1610
|
+
chartContainer: x,
|
|
1603
1611
|
ready: k,
|
|
1604
1612
|
showLoading: M,
|
|
1605
1613
|
controlsVisible: T,
|
|
1606
|
-
handleLocalRefresh:
|
|
1607
|
-
onChartMouseEnter:
|
|
1608
|
-
onChartMouseLeave:
|
|
1609
|
-
} =
|
|
1614
|
+
handleLocalRefresh: O,
|
|
1615
|
+
onChartMouseEnter: W,
|
|
1616
|
+
onChartMouseLeave: V
|
|
1617
|
+
} = Re({
|
|
1610
1618
|
dashboardId: () => e.dashboardId,
|
|
1611
1619
|
itemId: () => e.itemId,
|
|
1612
1620
|
query: l,
|
|
1613
1621
|
results: r,
|
|
1614
1622
|
loading: i,
|
|
1615
|
-
onRefresh:
|
|
1623
|
+
onRefresh: w,
|
|
1616
1624
|
getDashboardQueryExecutor: e.getDashboardQueryExecutor,
|
|
1617
|
-
analyticsStore:
|
|
1625
|
+
analyticsStore: I,
|
|
1618
1626
|
analyticsEvent: "dashboard-filter-execution",
|
|
1619
1627
|
analyticsType: "FILTER"
|
|
1620
1628
|
});
|
|
1621
1629
|
return {
|
|
1622
|
-
chartContainer:
|
|
1630
|
+
chartContainer: x,
|
|
1623
1631
|
results: r,
|
|
1624
1632
|
ready: k,
|
|
1625
1633
|
loading: i,
|
|
@@ -1629,11 +1637,11 @@ const Nn = /* @__PURE__ */ Y(qn, [["render", Bn], ["__scopeId", "data-v-660a47c4
|
|
|
1629
1637
|
query: l,
|
|
1630
1638
|
chartHeight: a,
|
|
1631
1639
|
chartWidth: v,
|
|
1632
|
-
onRefresh:
|
|
1633
|
-
handleLocalRefresh:
|
|
1640
|
+
onRefresh: w,
|
|
1641
|
+
handleLocalRefresh: O,
|
|
1634
1642
|
startTime: c,
|
|
1635
1643
|
handleDimensionClick: (B) => {
|
|
1636
|
-
|
|
1644
|
+
n("dimension-click", {
|
|
1637
1645
|
source: e.itemId,
|
|
1638
1646
|
filters: B.filters,
|
|
1639
1647
|
chart: B.chart,
|
|
@@ -1641,32 +1649,32 @@ const Nn = /* @__PURE__ */ Y(qn, [["render", Bn], ["__scopeId", "data-v-660a47c4
|
|
|
1641
1649
|
});
|
|
1642
1650
|
},
|
|
1643
1651
|
handleBackgroundClick: () => {
|
|
1644
|
-
|
|
1652
|
+
n("background-click");
|
|
1645
1653
|
},
|
|
1646
1654
|
controlsVisible: T,
|
|
1647
|
-
onChartMouseEnter:
|
|
1648
|
-
onChartMouseLeave:
|
|
1655
|
+
onChartMouseEnter: W,
|
|
1656
|
+
onChartMouseLeave: V
|
|
1649
1657
|
};
|
|
1650
1658
|
}
|
|
1651
|
-
}),
|
|
1659
|
+
}), Ko = {
|
|
1652
1660
|
key: 2,
|
|
1653
1661
|
class: "loading-overlay"
|
|
1654
1662
|
};
|
|
1655
|
-
function
|
|
1656
|
-
const s =
|
|
1657
|
-
return
|
|
1663
|
+
function Wo(e, n, o, l, r, i) {
|
|
1664
|
+
const s = Z("ErrorMessage"), f = Z("dashboard-data-selector"), c = Z("LoadingView");
|
|
1665
|
+
return h(), y("div", {
|
|
1658
1666
|
ref: "chartContainer",
|
|
1659
|
-
class:
|
|
1660
|
-
onMouseenter:
|
|
1661
|
-
onMouseleave:
|
|
1667
|
+
class: q(["chart-placeholder no-drag", { "chart-placeholder-edit-mode": e.editMode }]),
|
|
1668
|
+
onMouseenter: n[0] || (n[0] = (...a) => e.onChartMouseEnter && e.onChartMouseEnter(...a)),
|
|
1669
|
+
onMouseleave: n[1] || (n[1] = (...a) => e.onChartMouseLeave && e.onChartMouseLeave(...a))
|
|
1662
1670
|
}, [
|
|
1663
|
-
e.error && !e.loading ? (
|
|
1671
|
+
e.error && !e.loading ? (h(), _(s, {
|
|
1664
1672
|
key: 0,
|
|
1665
1673
|
compact: !0,
|
|
1666
1674
|
details: e.error,
|
|
1667
1675
|
query: e.query,
|
|
1668
1676
|
filters: e.filters
|
|
1669
|
-
}, null, 8, ["details", "query", "filters"])) : e.results && e.ready ? (
|
|
1677
|
+
}, null, 8, ["details", "query", "filters"])) : e.results && e.ready ? (h(), _(f, {
|
|
1670
1678
|
key: 1,
|
|
1671
1679
|
id: `${e.itemId}-${e.dashboardId}`,
|
|
1672
1680
|
headers: e.results.headers,
|
|
@@ -1677,7 +1685,7 @@ function Wn(e, o, n, l, r, i) {
|
|
|
1677
1685
|
onCellClick: e.handleDimensionClick,
|
|
1678
1686
|
onBackgroundClick: e.handleBackgroundClick
|
|
1679
1687
|
}, null, 8, ["id", "headers", "results", "containerHeight", "onCellClick", "onBackgroundClick"])) : R("", !0),
|
|
1680
|
-
e.loading && e.showLoading ? (
|
|
1688
|
+
e.loading && e.showLoading ? (h(), y("div", Ko, [
|
|
1681
1689
|
z(c, {
|
|
1682
1690
|
startTime: e.startTime,
|
|
1683
1691
|
text: "",
|
|
@@ -1686,25 +1694,25 @@ function Wn(e, o, n, l, r, i) {
|
|
|
1686
1694
|
])) : R("", !0)
|
|
1687
1695
|
], 34);
|
|
1688
1696
|
}
|
|
1689
|
-
const
|
|
1697
|
+
const Uo = /* @__PURE__ */ Y(Po, [["render", Wo], ["__scopeId", "data-v-9f88e03e"]]), jo = ["data-testid"], _o = ["data-testid"], Go = ["data-testid"], zo = ["data-testid"], Jo = {
|
|
1690
1698
|
key: 1,
|
|
1691
1699
|
class: "grid-item-header"
|
|
1692
|
-
},
|
|
1700
|
+
}, Yo = { class: "grid-item-header-left" }, Zo = {
|
|
1693
1701
|
key: 0,
|
|
1694
1702
|
class: "drag-handle-icon grid-item-drag-handle"
|
|
1695
|
-
},
|
|
1703
|
+
}, Xo = { class: "item-title-container no-drag" }, en = ["title"], tn = { class: "item-title-text" }, on = {
|
|
1696
1704
|
key: 0,
|
|
1697
1705
|
class: "mdi mdi-pencil-outline edit-indicator"
|
|
1698
|
-
},
|
|
1706
|
+
}, nn = ["id", "placeholder"], rn = { class: "grid-item-header-right" }, ln = {
|
|
1699
1707
|
key: 0,
|
|
1700
1708
|
class: "header-filters no-drag"
|
|
1701
|
-
},
|
|
1709
|
+
}, an = { class: "header-filter-chip" }, sn = { class: "filter-content" }, dn = { class: "filter-source" }, un = { class: "filter-value" }, cn = ["onClick"], mn = ["onClick", "title"], hn = { class: "header-filter-chip filter-overflow" }, fn = ["title"], vn = { class: "section-header-text" }, pn = ["id", "placeholder"], yn = ["data-testid"], gn = ["data-testid"], bn = ["data-testid"], Cn = ["data-testid", "title"], wn = {
|
|
1702
1710
|
key: 0,
|
|
1703
1711
|
class: "mdi mdi-filter-remove-outline icon"
|
|
1704
|
-
},
|
|
1712
|
+
}, kn = {
|
|
1705
1713
|
key: 1,
|
|
1706
1714
|
class: "mdi mdi-filter-outline icon"
|
|
1707
|
-
},
|
|
1715
|
+
}, Sn = ["data-testid"], En = ["data-testid"], Dn = /* @__PURE__ */ J({
|
|
1708
1716
|
__name: "DashboardGridItem",
|
|
1709
1717
|
props: {
|
|
1710
1718
|
dashboardId: {},
|
|
@@ -1716,150 +1724,160 @@ const Un = /* @__PURE__ */ Y(Pn, [["render", Wn], ["__scopeId", "data-v-9f88e03e
|
|
|
1716
1724
|
setItemData: { type: Function }
|
|
1717
1725
|
},
|
|
1718
1726
|
emits: ["edit-content", "update-dimensions", "dimension-click", "background-click", "remove-filter", "remove-item", "copy-item"],
|
|
1719
|
-
setup(e, { emit:
|
|
1720
|
-
const
|
|
1721
|
-
function v(
|
|
1722
|
-
return
|
|
1723
|
-
}
|
|
1724
|
-
function
|
|
1725
|
-
|
|
1726
|
-
|
|
1727
|
-
|
|
1728
|
-
|
|
1729
|
-
|
|
1730
|
-
|
|
1731
|
-
|
|
1732
|
-
|
|
1733
|
-
|
|
1727
|
+
setup(e, { emit: n }) {
|
|
1728
|
+
const o = e, l = n, r = S(!1), i = S(""), s = S(!1), f = S(!1), c = S(null), a = S(null);
|
|
1729
|
+
function v(K) {
|
|
1730
|
+
return K.replace(/'''/g, "'").replace("local.", "");
|
|
1731
|
+
}
|
|
1732
|
+
function w(K, A) {
|
|
1733
|
+
let N = v(K);
|
|
1734
|
+
if (A) {
|
|
1735
|
+
const ae = Object.keys(A).sort((oe, me) => me.length - oe.length);
|
|
1736
|
+
for (const oe of ae) {
|
|
1737
|
+
const me = A[oe], Fe = new RegExp(oe.replace(":", "\\:"), "g");
|
|
1738
|
+
N = N.replace(Fe, String(me));
|
|
1739
|
+
}
|
|
1740
|
+
}
|
|
1741
|
+
return N;
|
|
1742
|
+
}
|
|
1743
|
+
function b(K, A) {
|
|
1744
|
+
navigator.clipboard.writeText(w(K, A));
|
|
1745
|
+
}
|
|
1746
|
+
function I() {
|
|
1747
|
+
if (!o.editMode) return;
|
|
1748
|
+
const K = o.getItemData(o.item.i, o.dashboardId);
|
|
1749
|
+
s.value = !1, f.value = !1, r.value = !0, i.value = K.name, setTimeout(() => {
|
|
1750
|
+
const A = document.getElementById(`title-input-${o.item.i}`);
|
|
1751
|
+
A && A.focus();
|
|
1734
1752
|
}, 0);
|
|
1735
1753
|
}
|
|
1736
|
-
function
|
|
1754
|
+
function x() {
|
|
1737
1755
|
if (r.value) {
|
|
1738
|
-
const
|
|
1739
|
-
|
|
1756
|
+
const K = o.getItemData(o.item.i, o.dashboardId), A = i.value.trim() || K.name;
|
|
1757
|
+
o.setItemData(o.item.i, o.dashboardId, { name: A }), r.value = !1;
|
|
1740
1758
|
}
|
|
1741
1759
|
}
|
|
1742
|
-
function
|
|
1743
|
-
const
|
|
1744
|
-
|
|
1745
|
-
allowCrossFilter:
|
|
1760
|
+
function k() {
|
|
1761
|
+
const A = !o.getItemData(o.item.i, o.dashboardId).allowCrossFilter;
|
|
1762
|
+
o.setItemData(o.item.i, o.dashboardId, {
|
|
1763
|
+
allowCrossFilter: A
|
|
1746
1764
|
});
|
|
1747
1765
|
}
|
|
1748
|
-
function
|
|
1749
|
-
const
|
|
1750
|
-
|
|
1766
|
+
function M() {
|
|
1767
|
+
const K = o.item.h + 1;
|
|
1768
|
+
o.setItemData(o.item.i, o.dashboardId, {
|
|
1751
1769
|
dimensions: {
|
|
1752
|
-
width:
|
|
1753
|
-
height:
|
|
1770
|
+
width: o.item.w,
|
|
1771
|
+
height: K
|
|
1754
1772
|
}
|
|
1755
1773
|
});
|
|
1756
1774
|
}
|
|
1757
|
-
function
|
|
1758
|
-
const
|
|
1759
|
-
|
|
1775
|
+
function T() {
|
|
1776
|
+
const K = Math.max(1, o.item.h - 1);
|
|
1777
|
+
o.setItemData(o.item.i, o.dashboardId, {
|
|
1760
1778
|
dimensions: {
|
|
1761
|
-
width:
|
|
1762
|
-
height:
|
|
1779
|
+
width: o.item.w,
|
|
1780
|
+
height: K
|
|
1763
1781
|
}
|
|
1764
1782
|
});
|
|
1765
1783
|
}
|
|
1766
|
-
function
|
|
1784
|
+
function O() {
|
|
1767
1785
|
r.value = !1;
|
|
1768
1786
|
}
|
|
1769
|
-
function
|
|
1770
|
-
if (
|
|
1771
|
-
|
|
1787
|
+
function W() {
|
|
1788
|
+
if (D.value) {
|
|
1789
|
+
I();
|
|
1772
1790
|
return;
|
|
1773
1791
|
}
|
|
1774
|
-
l("edit-content",
|
|
1792
|
+
l("edit-content", o.item);
|
|
1775
1793
|
}
|
|
1776
|
-
function
|
|
1777
|
-
confirm(`Are you sure you want to remove "${
|
|
1794
|
+
function V() {
|
|
1795
|
+
confirm(`Are you sure you want to remove "${m.value.name}"?`) && l("remove-item", o.item.i);
|
|
1778
1796
|
}
|
|
1779
|
-
function
|
|
1780
|
-
l("copy-item",
|
|
1781
|
-
}
|
|
1782
|
-
function
|
|
1783
|
-
l("dimension-click",
|
|
1784
|
-
}
|
|
1785
|
-
function
|
|
1786
|
-
l("background-click",
|
|
1787
|
-
}
|
|
1788
|
-
function
|
|
1789
|
-
l("remove-filter",
|
|
1790
|
-
}
|
|
1791
|
-
const
|
|
1792
|
-
switch (
|
|
1793
|
-
case
|
|
1794
|
-
return
|
|
1795
|
-
case
|
|
1796
|
-
return
|
|
1797
|
-
case
|
|
1798
|
-
return
|
|
1799
|
-
case
|
|
1797
|
+
function $() {
|
|
1798
|
+
l("copy-item", o.item.i);
|
|
1799
|
+
}
|
|
1800
|
+
function g(K) {
|
|
1801
|
+
l("dimension-click", K);
|
|
1802
|
+
}
|
|
1803
|
+
function B() {
|
|
1804
|
+
l("background-click", o.item.i);
|
|
1805
|
+
}
|
|
1806
|
+
function E(K) {
|
|
1807
|
+
l("remove-filter", o.item.i, K);
|
|
1808
|
+
}
|
|
1809
|
+
const m = p(() => o.getItemData(o.item.i, o.dashboardId)), D = p(() => m.value.type === C.SECTION_HEADER), te = p(() => {
|
|
1810
|
+
switch (m.value.type) {
|
|
1811
|
+
case C.CHART:
|
|
1812
|
+
return Do;
|
|
1813
|
+
case C.TABLE:
|
|
1814
|
+
return Ao;
|
|
1815
|
+
case C.FILTER:
|
|
1816
|
+
return Uo;
|
|
1817
|
+
case C.SECTION_HEADER:
|
|
1800
1818
|
return null;
|
|
1801
|
-
case
|
|
1819
|
+
case C.MARKDOWN:
|
|
1802
1820
|
default:
|
|
1803
|
-
return $
|
|
1821
|
+
return $o;
|
|
1804
1822
|
}
|
|
1805
|
-
}),
|
|
1806
|
-
switch (
|
|
1807
|
-
case
|
|
1823
|
+
}), ne = p(() => {
|
|
1824
|
+
switch (m.value.type) {
|
|
1825
|
+
case C.CHART:
|
|
1808
1826
|
return "Chart Name";
|
|
1809
|
-
case
|
|
1827
|
+
case C.TABLE:
|
|
1810
1828
|
return "Table Name";
|
|
1811
|
-
case
|
|
1829
|
+
case C.FILTER:
|
|
1812
1830
|
return "Filter Name";
|
|
1813
|
-
case
|
|
1831
|
+
case C.SECTION_HEADER:
|
|
1814
1832
|
return "Section Header";
|
|
1815
|
-
case
|
|
1833
|
+
case C.MARKDOWN:
|
|
1816
1834
|
default:
|
|
1817
1835
|
return "Note Name";
|
|
1818
1836
|
}
|
|
1819
|
-
}),
|
|
1820
|
-
function
|
|
1821
|
-
var
|
|
1822
|
-
const
|
|
1823
|
-
if (!
|
|
1824
|
-
return { text:
|
|
1825
|
-
const
|
|
1826
|
-
if (!
|
|
1827
|
-
return { text:
|
|
1828
|
-
const
|
|
1829
|
-
return
|
|
1830
|
-
text:
|
|
1831
|
-
level:
|
|
1832
|
-
} : { text:
|
|
1833
|
-
}
|
|
1834
|
-
const
|
|
1835
|
-
function
|
|
1836
|
-
|
|
1837
|
-
}
|
|
1838
|
-
function
|
|
1837
|
+
}), U = p(() => [C.CHART, C.TABLE, C.MARKDOWN].includes(m.value.type)), ke = p(() => m.value.filters ? m.value.filters.length : 0), Se = p(() => (m.value.filters || []).slice(0, 2)), G = p(() => Math.max(0, ke.value - Se.value.length));
|
|
1838
|
+
function re(K, A) {
|
|
1839
|
+
var me;
|
|
1840
|
+
const N = K == null ? void 0 : K.trim();
|
|
1841
|
+
if (!N)
|
|
1842
|
+
return { text: A, level: 3 };
|
|
1843
|
+
const ae = N.match(/^(#{1,3})\s*(.+)$/);
|
|
1844
|
+
if (!ae)
|
|
1845
|
+
return { text: N, level: 3 };
|
|
1846
|
+
const oe = (me = ae[2]) == null ? void 0 : me.trim();
|
|
1847
|
+
return oe ? {
|
|
1848
|
+
text: oe,
|
|
1849
|
+
level: ae[1].length
|
|
1850
|
+
} : { text: N, level: 3 };
|
|
1851
|
+
}
|
|
1852
|
+
const le = p(() => re(m.value.name, ne.value)), X = p(() => le.value.text), De = p(() => `item-title-level-${le.value.level}`), ye = p(() => s.value && !r.value && !f.value);
|
|
1853
|
+
function Ae() {
|
|
1854
|
+
ye.value && (f.value = !0, s.value = !1);
|
|
1855
|
+
}
|
|
1856
|
+
function qe() {
|
|
1839
1857
|
s.value = !0, f.value = !1;
|
|
1840
1858
|
}
|
|
1841
|
-
function
|
|
1859
|
+
function Ie() {
|
|
1842
1860
|
s.value = !1, f.value = !1;
|
|
1843
1861
|
}
|
|
1844
|
-
return
|
|
1845
|
-
enabled: () =>
|
|
1862
|
+
return Ve([c, a], Ae, {
|
|
1863
|
+
enabled: () => ye.value,
|
|
1846
1864
|
eventName: "mousedown"
|
|
1847
|
-
}), (
|
|
1848
|
-
class:
|
|
1849
|
-
"grid-item-chart-style": [ie(
|
|
1865
|
+
}), (K, A) => (h(), y("div", {
|
|
1866
|
+
class: q(["grid-item-content", {
|
|
1867
|
+
"grid-item-chart-style": [ie(C).CHART, ie(C).TABLE, ie(C).FILTER].includes(
|
|
1850
1868
|
//@ts-ignore
|
|
1851
|
-
|
|
1869
|
+
m.value.type
|
|
1852
1870
|
),
|
|
1853
|
-
"grid-item-section-header-style":
|
|
1871
|
+
"grid-item-section-header-style": D.value,
|
|
1854
1872
|
"grid-item-edit-style": e.editMode
|
|
1855
1873
|
}]),
|
|
1856
1874
|
"data-testid": `dashboard-component-${e.item.i}`,
|
|
1857
|
-
onMouseenter:
|
|
1858
|
-
onMouseleave:
|
|
1875
|
+
onMouseenter: qe,
|
|
1876
|
+
onMouseleave: Ie
|
|
1859
1877
|
}, [
|
|
1860
|
-
e.editMode &&
|
|
1878
|
+
e.editMode && D.value ? (h(), y("div", {
|
|
1861
1879
|
key: 0,
|
|
1862
|
-
class:
|
|
1880
|
+
class: q(["dev-toolbar-shell", { "dev-toolbar-visible": ye.value }])
|
|
1863
1881
|
}, [
|
|
1864
1882
|
t("div", {
|
|
1865
1883
|
ref_key: "devToolbarRef",
|
|
@@ -1868,34 +1886,34 @@ const Un = /* @__PURE__ */ Y(Pn, [["render", Wn], ["__scopeId", "data-v-9f88e03e
|
|
|
1868
1886
|
"data-testid": "dashboard-item-header-controls"
|
|
1869
1887
|
}, [
|
|
1870
1888
|
t("button", {
|
|
1871
|
-
onClick:
|
|
1889
|
+
onClick: W,
|
|
1872
1890
|
class: "control-btn",
|
|
1873
1891
|
"data-testid": `edit-dashboard-item-content-${e.item.i}`,
|
|
1874
1892
|
title: "Edit title"
|
|
1875
|
-
}, [...
|
|
1893
|
+
}, [...A[2] || (A[2] = [
|
|
1876
1894
|
t("i", { class: "mdi mdi-pencil-outline icon" }, null, -1)
|
|
1877
|
-
])], 8,
|
|
1895
|
+
])], 8, _o),
|
|
1878
1896
|
t("button", {
|
|
1879
|
-
onClick:
|
|
1897
|
+
onClick: $,
|
|
1880
1898
|
class: "control-btn",
|
|
1881
1899
|
"data-testid": `copy-dashboard-item-${e.item.i}`,
|
|
1882
1900
|
title: "Copy item"
|
|
1883
|
-
}, [...
|
|
1901
|
+
}, [...A[3] || (A[3] = [
|
|
1884
1902
|
t("i", { class: "mdi mdi-content-copy icon" }, null, -1)
|
|
1885
|
-
])], 8,
|
|
1903
|
+
])], 8, Go),
|
|
1886
1904
|
t("button", {
|
|
1887
|
-
onClick:
|
|
1905
|
+
onClick: V,
|
|
1888
1906
|
class: "control-btn dashboard-remove-btn",
|
|
1889
1907
|
"data-testid": `remove-dashboard-item-${e.item.i}`,
|
|
1890
1908
|
title: "Remove item"
|
|
1891
|
-
}, [...
|
|
1909
|
+
}, [...A[4] || (A[4] = [
|
|
1892
1910
|
t("i", { class: "mdi mdi-delete-outline icon" }, null, -1)
|
|
1893
|
-
])], 8,
|
|
1911
|
+
])], 8, zo)
|
|
1894
1912
|
], 512)
|
|
1895
1913
|
], 2)) : R("", !0),
|
|
1896
|
-
|
|
1897
|
-
t("div",
|
|
1898
|
-
e.editMode ? (
|
|
1914
|
+
D.value ? R("", !0) : (h(), y("div", Jo, [
|
|
1915
|
+
t("div", Yo, [
|
|
1916
|
+
e.editMode ? (h(), y("div", Zo, [...A[5] || (A[5] = [
|
|
1899
1917
|
t("svg", {
|
|
1900
1918
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1901
1919
|
width: "16",
|
|
@@ -1928,99 +1946,114 @@ const Un = /* @__PURE__ */ Y(Pn, [["render", Wn], ["__scopeId", "data-v-9f88e03e
|
|
|
1928
1946
|
})
|
|
1929
1947
|
], -1)
|
|
1930
1948
|
])])) : R("", !0),
|
|
1931
|
-
t("div",
|
|
1932
|
-
r.value ?
|
|
1949
|
+
t("div", Xo, [
|
|
1950
|
+
r.value ? ce((h(), y("input", {
|
|
1933
1951
|
key: 1,
|
|
1934
1952
|
id: `title-input-${e.item.i}`,
|
|
1935
|
-
"onUpdate:modelValue":
|
|
1936
|
-
onBlur:
|
|
1953
|
+
"onUpdate:modelValue": A[0] || (A[0] = (N) => i.value = N),
|
|
1954
|
+
onBlur: x,
|
|
1937
1955
|
onKeyup: [
|
|
1938
|
-
|
|
1939
|
-
|
|
1956
|
+
ge(x, ["enter"]),
|
|
1957
|
+
ge(O, ["esc"])
|
|
1940
1958
|
],
|
|
1941
1959
|
class: "title-input",
|
|
1942
1960
|
type: "text",
|
|
1943
|
-
placeholder:
|
|
1944
|
-
}, null, 40,
|
|
1945
|
-
[
|
|
1946
|
-
]) : (
|
|
1961
|
+
placeholder: ne.value
|
|
1962
|
+
}, null, 40, nn)), [
|
|
1963
|
+
[pe, i.value]
|
|
1964
|
+
]) : (h(), y("div", {
|
|
1947
1965
|
key: 0,
|
|
1948
|
-
class:
|
|
1949
|
-
title:
|
|
1950
|
-
onClick:
|
|
1966
|
+
class: q(["item-title editable-title", [De.value, { "item-title-static": !e.editMode }]]),
|
|
1967
|
+
title: X.value,
|
|
1968
|
+
onClick: I
|
|
1951
1969
|
}, [
|
|
1952
|
-
t("span",
|
|
1953
|
-
e.editMode ? (
|
|
1954
|
-
], 10,
|
|
1970
|
+
t("span", tn, P(X.value), 1),
|
|
1971
|
+
e.editMode ? (h(), y("i", on)) : R("", !0)
|
|
1972
|
+
], 10, en))
|
|
1955
1973
|
])
|
|
1956
1974
|
]),
|
|
1957
|
-
t("div",
|
|
1958
|
-
|
|
1959
|
-
(
|
|
1960
|
-
key: `${
|
|
1961
|
-
|
|
1962
|
-
|
|
1963
|
-
},
|
|
1964
|
-
|
|
1965
|
-
t("
|
|
1966
|
-
|
|
1975
|
+
t("div", rn, [
|
|
1976
|
+
U.value && ke.value > 0 ? (h(), y("div", ln, [
|
|
1977
|
+
(h(!0), y(fe, null, we(Se.value, (N, ae) => (h(), _(be, {
|
|
1978
|
+
key: `${N.source}-${N.value}-${ae}`,
|
|
1979
|
+
content: w(N.value, N.parameters),
|
|
1980
|
+
position: "bottom"
|
|
1981
|
+
}, {
|
|
1982
|
+
default: ee(() => [
|
|
1983
|
+
t("div", an, [
|
|
1984
|
+
t("span", sn, [
|
|
1985
|
+
t("span", dn, P(N.source === "global" ? N.source : "cross") + ": ", 1),
|
|
1986
|
+
t("span", un, P(w(N.value, N.parameters)), 1)
|
|
1987
|
+
]),
|
|
1988
|
+
t("button", {
|
|
1989
|
+
class: "filter-copy-btn",
|
|
1990
|
+
onClick: Oe((oe) => b(N.value, N.parameters), ["stop"]),
|
|
1991
|
+
title: "Copy filter value"
|
|
1992
|
+
}, " ⎘ ", 8, cn),
|
|
1993
|
+
e.editMode && N.source !== "global" ? (h(), y("button", {
|
|
1994
|
+
key: 0,
|
|
1995
|
+
class: "filter-remove-btn",
|
|
1996
|
+
onClick: (oe) => E(N.source),
|
|
1997
|
+
title: `Remove ${N.source} filter`
|
|
1998
|
+
}, " x ", 8, mn)) : R("", !0)
|
|
1999
|
+
])
|
|
1967
2000
|
]),
|
|
1968
|
-
|
|
1969
|
-
|
|
1970
|
-
|
|
1971
|
-
onClick: (we) => B(P.source),
|
|
1972
|
-
title: `Remove ${P.source} filter`
|
|
1973
|
-
}, " x ", 8, co)) : R("", !0)
|
|
1974
|
-
], 8, lo))), 128)),
|
|
1975
|
-
ve.value > 0 ? (m(), y("div", {
|
|
2001
|
+
_: 2
|
|
2002
|
+
}, 1032, ["content"]))), 128)),
|
|
2003
|
+
G.value > 0 ? (h(), _(be, {
|
|
1976
2004
|
key: 0,
|
|
1977
|
-
|
|
1978
|
-
|
|
1979
|
-
},
|
|
2005
|
+
content: `${G.value} more filter(s)`,
|
|
2006
|
+
position: "bottom"
|
|
2007
|
+
}, {
|
|
2008
|
+
default: ee(() => [
|
|
2009
|
+
t("div", hn, "+" + P(G.value), 1)
|
|
2010
|
+
]),
|
|
2011
|
+
_: 1
|
|
2012
|
+
}, 8, ["content"])) : R("", !0)
|
|
1980
2013
|
])) : R("", !0)
|
|
1981
2014
|
])
|
|
1982
2015
|
])),
|
|
1983
2016
|
t("div", {
|
|
1984
|
-
class:
|
|
2017
|
+
class: q(["content-area", { "section-header-content": D.value }])
|
|
1985
2018
|
}, [
|
|
1986
|
-
|
|
1987
|
-
r.value ?
|
|
2019
|
+
D.value ? (h(), y(fe, { key: 0 }, [
|
|
2020
|
+
r.value ? ce((h(), y("input", {
|
|
1988
2021
|
key: 1,
|
|
1989
2022
|
id: `title-input-${e.item.i}`,
|
|
1990
|
-
"onUpdate:modelValue":
|
|
1991
|
-
onBlur:
|
|
2023
|
+
"onUpdate:modelValue": A[1] || (A[1] = (N) => i.value = N),
|
|
2024
|
+
onBlur: x,
|
|
1992
2025
|
onKeyup: [
|
|
1993
|
-
|
|
1994
|
-
|
|
2026
|
+
ge(x, ["enter"]),
|
|
2027
|
+
ge(O, ["esc"])
|
|
1995
2028
|
],
|
|
1996
2029
|
class: "title-input section-header-input no-drag",
|
|
1997
2030
|
type: "text",
|
|
1998
|
-
placeholder:
|
|
1999
|
-
}, null, 40,
|
|
2000
|
-
[
|
|
2001
|
-
]) : (
|
|
2031
|
+
placeholder: ne.value
|
|
2032
|
+
}, null, 40, pn)), [
|
|
2033
|
+
[pe, i.value]
|
|
2034
|
+
]) : (h(), y("div", {
|
|
2002
2035
|
key: 0,
|
|
2003
|
-
class:
|
|
2004
|
-
title:
|
|
2005
|
-
onClick:
|
|
2036
|
+
class: q(["section-header-display no-drag", [De.value, { "section-header-editable": e.editMode }]]),
|
|
2037
|
+
title: X.value,
|
|
2038
|
+
onClick: I
|
|
2006
2039
|
}, [
|
|
2007
|
-
t("span",
|
|
2008
|
-
], 10,
|
|
2009
|
-
], 64)) : (
|
|
2040
|
+
t("span", vn, P(X.value), 1)
|
|
2041
|
+
], 10, fn))
|
|
2042
|
+
], 64)) : (h(), _(it(te.value), {
|
|
2010
2043
|
key: 1,
|
|
2011
|
-
dashboardId:
|
|
2044
|
+
dashboardId: o.dashboardId,
|
|
2012
2045
|
itemId: e.item.i,
|
|
2013
2046
|
setItemData: e.setItemData,
|
|
2014
2047
|
getItemData: e.getItemData,
|
|
2015
2048
|
getDashboardQueryExecutor: e.getDashboardQueryExecutor,
|
|
2016
2049
|
editMode: e.editMode,
|
|
2017
|
-
symbols:
|
|
2018
|
-
onDimensionClick:
|
|
2019
|
-
onBackgroundClick:
|
|
2050
|
+
symbols: o.symbols || [],
|
|
2051
|
+
onDimensionClick: g,
|
|
2052
|
+
onBackgroundClick: B
|
|
2020
2053
|
}, null, 40, ["dashboardId", "itemId", "setItemData", "getItemData", "getDashboardQueryExecutor", "editMode", "symbols"])),
|
|
2021
|
-
e.editMode && !
|
|
2054
|
+
e.editMode && !D.value ? (h(), y("div", {
|
|
2022
2055
|
key: 2,
|
|
2023
|
-
class:
|
|
2056
|
+
class: q(["content-edit-overlay no-drag", { "content-edit-overlay-visible": ye.value }])
|
|
2024
2057
|
}, [
|
|
2025
2058
|
t("div", {
|
|
2026
2059
|
ref_key: "contentEditToolbarRef",
|
|
@@ -2029,103 +2062,103 @@ const Un = /* @__PURE__ */ Y(Pn, [["render", Wn], ["__scopeId", "data-v-9f88e03e
|
|
|
2029
2062
|
"data-testid": "dashboard-item-header-controls"
|
|
2030
2063
|
}, [
|
|
2031
2064
|
t("button", {
|
|
2032
|
-
onClick:
|
|
2065
|
+
onClick: M,
|
|
2033
2066
|
class: "control-btn",
|
|
2034
2067
|
"data-testid": `increase-height-item-${e.item.i}`,
|
|
2035
2068
|
title: "Increase height"
|
|
2036
|
-
}, [...
|
|
2069
|
+
}, [...A[6] || (A[6] = [
|
|
2037
2070
|
t("i", { class: "mdi mdi-plus icon" }, null, -1)
|
|
2038
|
-
])], 8,
|
|
2071
|
+
])], 8, yn),
|
|
2039
2072
|
t("button", {
|
|
2040
|
-
onClick:
|
|
2073
|
+
onClick: T,
|
|
2041
2074
|
class: "control-btn",
|
|
2042
2075
|
"data-testid": `decrease-height-item-${e.item.i}`,
|
|
2043
2076
|
title: "Decrease height"
|
|
2044
|
-
}, [...
|
|
2077
|
+
}, [...A[7] || (A[7] = [
|
|
2045
2078
|
t("i", { class: "mdi mdi-minus icon" }, null, -1)
|
|
2046
|
-
])], 8,
|
|
2079
|
+
])], 8, gn),
|
|
2047
2080
|
t("button", {
|
|
2048
|
-
onClick:
|
|
2081
|
+
onClick: W,
|
|
2049
2082
|
class: "control-btn",
|
|
2050
2083
|
"data-testid": `edit-dashboard-item-content-${e.item.i}`,
|
|
2051
2084
|
title: "Edit data"
|
|
2052
|
-
}, [...
|
|
2085
|
+
}, [...A[8] || (A[8] = [
|
|
2053
2086
|
t("i", { class: "mdi mdi-database-edit-outline icon" }, null, -1)
|
|
2054
|
-
])], 8,
|
|
2087
|
+
])], 8, bn),
|
|
2055
2088
|
t("button", {
|
|
2056
|
-
onClick:
|
|
2089
|
+
onClick: k,
|
|
2057
2090
|
class: "control-btn",
|
|
2058
2091
|
"data-testid": `toggle-crossfilter-item-content-${e.item.i}`,
|
|
2059
|
-
title:
|
|
2092
|
+
title: m.value.allowCrossFilter ? "Toggle cross-filtering OFF" : "Toggle cross-filtering ON"
|
|
2060
2093
|
}, [
|
|
2061
|
-
|
|
2062
|
-
], 8,
|
|
2094
|
+
m.value.allowCrossFilter ? (h(), y("i", wn)) : (h(), y("i", kn))
|
|
2095
|
+
], 8, Cn),
|
|
2063
2096
|
t("button", {
|
|
2064
|
-
onClick:
|
|
2097
|
+
onClick: $,
|
|
2065
2098
|
class: "control-btn",
|
|
2066
2099
|
"data-testid": `copy-dashboard-item-${e.item.i}`,
|
|
2067
2100
|
title: "Copy item"
|
|
2068
|
-
}, [...
|
|
2101
|
+
}, [...A[9] || (A[9] = [
|
|
2069
2102
|
t("i", { class: "mdi mdi-content-copy icon" }, null, -1)
|
|
2070
|
-
])], 8,
|
|
2103
|
+
])], 8, Sn),
|
|
2071
2104
|
t("button", {
|
|
2072
|
-
onClick:
|
|
2105
|
+
onClick: V,
|
|
2073
2106
|
class: "control-btn dashboard-remove-btn",
|
|
2074
2107
|
"data-testid": `remove-dashboard-item-${e.item.i}`,
|
|
2075
2108
|
title: "Remove item"
|
|
2076
|
-
}, [...
|
|
2109
|
+
}, [...A[10] || (A[10] = [
|
|
2077
2110
|
t("i", { class: "mdi mdi-delete-outline icon" }, null, -1)
|
|
2078
|
-
])], 8,
|
|
2111
|
+
])], 8, En)
|
|
2079
2112
|
], 512)
|
|
2080
2113
|
], 2)) : R("", !0)
|
|
2081
2114
|
], 2)
|
|
2082
|
-
], 42,
|
|
2115
|
+
], 42, jo));
|
|
2083
2116
|
}
|
|
2084
|
-
}),
|
|
2117
|
+
}), Ui = /* @__PURE__ */ Y(Dn, [["__scopeId", "data-v-9dbea91e"]]), In = { class: "add-item-content" }, Tn = {
|
|
2085
2118
|
class: "item-type-grid",
|
|
2086
2119
|
role: "radiogroup",
|
|
2087
2120
|
"aria-label": "Dashboard item type"
|
|
2088
|
-
},
|
|
2121
|
+
}, $n = ["data-testid"], Ln = ["value", "data-testid"], Mn = { class: "item-option-card" }, Rn = {
|
|
2089
2122
|
class: "item-option-icon",
|
|
2090
2123
|
"aria-hidden": "true"
|
|
2091
|
-
},
|
|
2124
|
+
}, An = { class: "item-option-text" }, qn = { class: "item-option-label" }, Fn = { class: "item-option-help" }, xn = /* @__PURE__ */ J({
|
|
2092
2125
|
__name: "DashboardAddItemModal",
|
|
2093
2126
|
props: {
|
|
2094
2127
|
show: { type: Boolean }
|
|
2095
2128
|
},
|
|
2096
2129
|
emits: ["add", "close"],
|
|
2097
|
-
setup(e, { emit:
|
|
2098
|
-
const
|
|
2130
|
+
setup(e, { emit: n }) {
|
|
2131
|
+
const o = n, l = S(C.CHART), r = [
|
|
2099
2132
|
{
|
|
2100
|
-
value:
|
|
2133
|
+
value: C.CHART,
|
|
2101
2134
|
label: "Chart",
|
|
2102
2135
|
description: "Visualize trends, comparisons, and distributions.",
|
|
2103
2136
|
icon: "mdi-chart-bar",
|
|
2104
2137
|
testId: "dashboard-add-item-type-chart"
|
|
2105
2138
|
},
|
|
2106
2139
|
{
|
|
2107
|
-
value:
|
|
2140
|
+
value: C.TABLE,
|
|
2108
2141
|
label: "Table",
|
|
2109
2142
|
description: "Show detailed rows and values in a grid.",
|
|
2110
2143
|
icon: "mdi-table-large",
|
|
2111
2144
|
testId: "dashboard-add-item-type-table"
|
|
2112
2145
|
},
|
|
2113
2146
|
{
|
|
2114
|
-
value:
|
|
2147
|
+
value: C.MARKDOWN,
|
|
2115
2148
|
label: "Markdown",
|
|
2116
2149
|
description: "Add notes, headings, or narrative context.",
|
|
2117
2150
|
icon: "mdi-text-box-outline",
|
|
2118
2151
|
testId: "dashboard-add-item-type-markdown"
|
|
2119
2152
|
},
|
|
2120
2153
|
{
|
|
2121
|
-
value:
|
|
2154
|
+
value: C.FILTER,
|
|
2122
2155
|
label: "Filter",
|
|
2123
2156
|
description: "Let viewers narrow the dashboard interactively.",
|
|
2124
2157
|
icon: "mdi-filter-variant",
|
|
2125
2158
|
testId: "dashboard-add-item-type-filter"
|
|
2126
2159
|
},
|
|
2127
2160
|
{
|
|
2128
|
-
value:
|
|
2161
|
+
value: C.SECTION_HEADER,
|
|
2129
2162
|
label: "Section Header",
|
|
2130
2163
|
description: "Break the dashboard into labeled sections.",
|
|
2131
2164
|
icon: "mdi-format-title",
|
|
@@ -2133,19 +2166,19 @@ const Un = /* @__PURE__ */ Y(Pn, [["render", Wn], ["__scopeId", "data-v-9f88e03e
|
|
|
2133
2166
|
}
|
|
2134
2167
|
];
|
|
2135
2168
|
function i() {
|
|
2136
|
-
|
|
2169
|
+
o("add", l.value);
|
|
2137
2170
|
}
|
|
2138
2171
|
function s() {
|
|
2139
|
-
|
|
2172
|
+
o("close");
|
|
2140
2173
|
}
|
|
2141
|
-
return (f, c) => (
|
|
2174
|
+
return (f, c) => (h(), _(Ye, {
|
|
2142
2175
|
show: e.show,
|
|
2143
2176
|
title: "Add New Item",
|
|
2144
2177
|
"max-width": "680px",
|
|
2145
2178
|
"test-id": "dashboard-add-item-modal",
|
|
2146
2179
|
onClose: s
|
|
2147
2180
|
}, {
|
|
2148
|
-
footer:
|
|
2181
|
+
footer: ee(() => [
|
|
2149
2182
|
t("button", {
|
|
2150
2183
|
class: "cancel-button",
|
|
2151
2184
|
onClick: s
|
|
@@ -2156,48 +2189,48 @@ const Un = /* @__PURE__ */ Y(Pn, [["render", Wn], ["__scopeId", "data-v-9f88e03e
|
|
|
2156
2189
|
"data-testid": "dashboard-add-item-confirm"
|
|
2157
2190
|
}, " Add Item ")
|
|
2158
2191
|
]),
|
|
2159
|
-
default:
|
|
2160
|
-
t("div",
|
|
2192
|
+
default: ee(() => [
|
|
2193
|
+
t("div", In, [
|
|
2161
2194
|
c[1] || (c[1] = t("p", { class: "add-item-description" }, "Choose the kind of block you want to add to the dashboard.", -1)),
|
|
2162
|
-
t("div",
|
|
2163
|
-
(
|
|
2195
|
+
t("div", Tn, [
|
|
2196
|
+
(h(), y(fe, null, we(r, (a) => t("label", {
|
|
2164
2197
|
key: a.value,
|
|
2165
|
-
class:
|
|
2198
|
+
class: q(["item-option", { selected: l.value === a.value }]),
|
|
2166
2199
|
"data-testid": `${a.testId}-option`
|
|
2167
2200
|
}, [
|
|
2168
|
-
|
|
2201
|
+
ce(t("input", {
|
|
2169
2202
|
"onUpdate:modelValue": c[0] || (c[0] = (v) => l.value = v),
|
|
2170
2203
|
class: "item-option-input",
|
|
2171
2204
|
type: "radio",
|
|
2172
2205
|
name: "dashboard-add-item-type",
|
|
2173
2206
|
value: a.value,
|
|
2174
2207
|
"data-testid": a.testId
|
|
2175
|
-
}, null, 8,
|
|
2208
|
+
}, null, 8, Ln), [
|
|
2176
2209
|
[rt, l.value]
|
|
2177
2210
|
]),
|
|
2178
|
-
t("span",
|
|
2179
|
-
t("span",
|
|
2211
|
+
t("span", Mn, [
|
|
2212
|
+
t("span", Rn, [
|
|
2180
2213
|
t("i", {
|
|
2181
|
-
class:
|
|
2214
|
+
class: q(["mdi", a.icon])
|
|
2182
2215
|
}, null, 2)
|
|
2183
2216
|
]),
|
|
2184
|
-
t("span",
|
|
2185
|
-
t("span",
|
|
2186
|
-
t("span",
|
|
2217
|
+
t("span", An, [
|
|
2218
|
+
t("span", qn, P(a.label), 1),
|
|
2219
|
+
t("span", Fn, P(a.description), 1)
|
|
2187
2220
|
])
|
|
2188
2221
|
])
|
|
2189
|
-
], 10,
|
|
2222
|
+
], 10, $n)), 64))
|
|
2190
2223
|
])
|
|
2191
2224
|
])
|
|
2192
2225
|
]),
|
|
2193
2226
|
_: 1
|
|
2194
2227
|
}, 8, ["show"]));
|
|
2195
2228
|
}
|
|
2196
|
-
}),
|
|
2197
|
-
function
|
|
2198
|
-
const
|
|
2199
|
-
|
|
2200
|
-
base:
|
|
2229
|
+
}), ji = /* @__PURE__ */ Y(xn, [["__scopeId", "data-v-ee048740"]]);
|
|
2230
|
+
function Hn(e = "dark") {
|
|
2231
|
+
const n = e === "light";
|
|
2232
|
+
$e.defineTheme("trilogyStudio", {
|
|
2233
|
+
base: n ? "vs" : "vs-dark",
|
|
2201
2234
|
inherit: !0,
|
|
2202
2235
|
rules: [
|
|
2203
2236
|
{ token: "comment", foreground: "#6A9955", fontStyle: "italic" },
|
|
@@ -2213,25 +2246,25 @@ function xo(e = "dark") {
|
|
|
2213
2246
|
{ token: "property", foreground: "#BFBFBF" }
|
|
2214
2247
|
],
|
|
2215
2248
|
colors: {
|
|
2216
|
-
"editor.background":
|
|
2217
|
-
"editor.foreground":
|
|
2218
|
-
"editorLineNumber.foreground":
|
|
2219
|
-
"editorLineNumber.activeForeground":
|
|
2220
|
-
"editorGutter.background":
|
|
2221
|
-
editorLineHighlightBackground:
|
|
2222
|
-
"editor.selectionBackground":
|
|
2223
|
-
"editor.inactiveSelectionBackground":
|
|
2224
|
-
"editorCursor.foreground":
|
|
2225
|
-
"editorCursor.background":
|
|
2226
|
-
"editorIndentGuide.background1":
|
|
2227
|
-
"editorIndentGuide.activeBackground1":
|
|
2228
|
-
"editorWhitespace.foreground":
|
|
2229
|
-
"editorWidget.background":
|
|
2230
|
-
"editorWidget.border":
|
|
2231
|
-
}
|
|
2232
|
-
}),
|
|
2249
|
+
"editor.background": n ? "#ffffff" : "#111318",
|
|
2250
|
+
"editor.foreground": n ? "#1f2937" : "#e5e7eb",
|
|
2251
|
+
"editorLineNumber.foreground": n ? "#94a3b8" : "#64748b",
|
|
2252
|
+
"editorLineNumber.activeForeground": n ? "#475569" : "#cbd5e1",
|
|
2253
|
+
"editorGutter.background": n ? "#ffffff" : "#111318",
|
|
2254
|
+
editorLineHighlightBackground: n ? "#f6f8fb" : "#181c22",
|
|
2255
|
+
"editor.selectionBackground": n ? "#dbeafe" : "#1d4ed833",
|
|
2256
|
+
"editor.inactiveSelectionBackground": n ? "#e2e8f0" : "#33415555",
|
|
2257
|
+
"editorCursor.foreground": n ? "#334155" : "#ffffff",
|
|
2258
|
+
"editorCursor.background": n ? "#ffffff" : "#111318",
|
|
2259
|
+
"editorIndentGuide.background1": n ? "#e2e8f0" : "#2a2f37",
|
|
2260
|
+
"editorIndentGuide.activeBackground1": n ? "#cbd5e1" : "#475569",
|
|
2261
|
+
"editorWhitespace.foreground": n ? "#cbd5e1" : "#334155",
|
|
2262
|
+
"editorWidget.background": n ? "#ffffff" : "#111318",
|
|
2263
|
+
"editorWidget.border": n ? "#d6dde6" : "#2a2f37"
|
|
2264
|
+
}
|
|
2265
|
+
}), $e.setTheme("trilogyStudio");
|
|
2233
2266
|
}
|
|
2234
|
-
function
|
|
2267
|
+
function On(e, n = {}) {
|
|
2235
2268
|
const l = { ...{
|
|
2236
2269
|
automaticLayout: !0,
|
|
2237
2270
|
autoClosingBrackets: "always",
|
|
@@ -2240,25 +2273,25 @@ function Ho(e, o = {}) {
|
|
|
2240
2273
|
acceptSuggestionOnEnter: "off",
|
|
2241
2274
|
tabCompletion: "on",
|
|
2242
2275
|
theme: "trilogyStudio"
|
|
2243
|
-
}, ...
|
|
2244
|
-
return
|
|
2276
|
+
}, ...n };
|
|
2277
|
+
return $e.create(e, l);
|
|
2245
2278
|
}
|
|
2246
|
-
function
|
|
2279
|
+
function _e(e, n = "") {
|
|
2247
2280
|
var r;
|
|
2248
|
-
if (!e) return
|
|
2249
|
-
const
|
|
2250
|
-
let l =
|
|
2251
|
-
return l || (l =
|
|
2281
|
+
if (!e) return n;
|
|
2282
|
+
const o = e.getSelection();
|
|
2283
|
+
let l = o && !(o.startColumn === o.endColumn && o.startLineNumber === o.endLineNumber) ? ((r = e.getModel()) == null ? void 0 : r.getValueInRange(o)) || "" : e.getValue();
|
|
2284
|
+
return l || (l = n), l;
|
|
2252
2285
|
}
|
|
2253
|
-
function
|
|
2254
|
-
const { onValidate:
|
|
2255
|
-
if (
|
|
2286
|
+
function Vn(e, n = {}) {
|
|
2287
|
+
const { onValidate: o, onRun: l, onSave: r } = n;
|
|
2288
|
+
if (o && e.addCommand(de.CtrlCmd | de.Shift | ve.KeyV, o), l && e.addCommand(de.CtrlCmd | ve.Enter, l), r && e.addCommand(de.CtrlCmd | ve.KeyS, r), e.addCommand(de.CtrlCmd | ve.KeyZ, () => {
|
|
2256
2289
|
e.trigger("ide", "undo", {});
|
|
2257
|
-
}),
|
|
2290
|
+
}), n.onContentChange) {
|
|
2258
2291
|
let i = null;
|
|
2259
2292
|
e.onDidChangeModelContent(() => {
|
|
2260
2293
|
var s;
|
|
2261
|
-
(s =
|
|
2294
|
+
(s = n.onContentChange) == null || s.call(n, e.getValue()), i && clearTimeout(i), i = setTimeout(() => {
|
|
2262
2295
|
var f;
|
|
2263
2296
|
e.hasTextFocus() && !((f = e.getSelection()) != null && f.isEmpty()) && e.trigger("completion", "editor.action.triggerSuggest", { auto: !0 });
|
|
2264
2297
|
}, 200);
|
|
@@ -2266,11 +2299,11 @@ function Vo(e, o = {}) {
|
|
|
2266
2299
|
}
|
|
2267
2300
|
}
|
|
2268
2301
|
let F = null;
|
|
2269
|
-
const
|
|
2302
|
+
const Qn = J({
|
|
2270
2303
|
name: "EnhancedEditor",
|
|
2271
2304
|
components: {
|
|
2272
|
-
SymbolsPane:
|
|
2273
|
-
LoadingView:
|
|
2305
|
+
SymbolsPane: Et,
|
|
2306
|
+
LoadingView: Me
|
|
2274
2307
|
},
|
|
2275
2308
|
props: {
|
|
2276
2309
|
onSave: {
|
|
@@ -2320,11 +2353,11 @@ const Oo = J({
|
|
|
2320
2353
|
};
|
|
2321
2354
|
},
|
|
2322
2355
|
setup() {
|
|
2323
|
-
const e = j("queryExecutionService"),
|
|
2356
|
+
const e = j("queryExecutionService"), n = j("connectionStore"), o = j("isMobile"), l = j("llmConnectionStore"), r = j("analyticsStore"), i = ut();
|
|
2324
2357
|
return {
|
|
2325
2358
|
queryExecutionService: e,
|
|
2326
|
-
connectionStore:
|
|
2327
|
-
isMobile:
|
|
2359
|
+
connectionStore: n,
|
|
2360
|
+
isMobile: o,
|
|
2328
2361
|
llmConnectionStore: l,
|
|
2329
2362
|
analyticsStore: r,
|
|
2330
2363
|
userSettingsStore: i
|
|
@@ -2351,12 +2384,12 @@ const Oo = J({
|
|
|
2351
2384
|
},
|
|
2352
2385
|
methods: {
|
|
2353
2386
|
getResolvedTheme() {
|
|
2354
|
-
var
|
|
2355
|
-
const e = this.theme === "light" || this.theme === "dark" ? this.theme : "",
|
|
2356
|
-
return (e ||
|
|
2387
|
+
var o;
|
|
2388
|
+
const e = this.theme === "light" || this.theme === "dark" ? this.theme : "", n = ((o = this.userSettingsStore) == null ? void 0 : o.settings.theme) || "";
|
|
2389
|
+
return (e || n || "dark") === "light" ? "light" : "dark";
|
|
2357
2390
|
},
|
|
2358
2391
|
applyEditorTheme() {
|
|
2359
|
-
|
|
2392
|
+
Hn(this.getResolvedTheme());
|
|
2360
2393
|
},
|
|
2361
2394
|
// New methods for panel management
|
|
2362
2395
|
togglePanel(e) {
|
|
@@ -2380,19 +2413,19 @@ const Oo = J({
|
|
|
2380
2413
|
}
|
|
2381
2414
|
},
|
|
2382
2415
|
createEditor() {
|
|
2383
|
-
this.applyEditorTheme(), F =
|
|
2416
|
+
this.applyEditorTheme(), F = On(this.$refs.editorElement, {
|
|
2384
2417
|
value: this.editor.contents || "",
|
|
2385
2418
|
language: this.editor.type === "sql" ? "sql" : "trilogy"
|
|
2386
|
-
}),
|
|
2419
|
+
}), Vn(F, {
|
|
2387
2420
|
onValidate: () => this.validateQuery(),
|
|
2388
2421
|
onRun: () => this.runQuery(),
|
|
2389
2422
|
onGenerateLLM: () => this.generateLLMQuery()
|
|
2390
2423
|
// Add LLM generation shortcut
|
|
2391
|
-
}), F.addCommand(
|
|
2424
|
+
}), F.addCommand(de.CtrlCmd | ve.Space, () => {
|
|
2392
2425
|
this.togglePanel("symbols");
|
|
2393
|
-
}), F.addCommand(
|
|
2426
|
+
}), F.addCommand(de.CtrlCmd | de.Shift | ve.Enter, () => {
|
|
2394
2427
|
this.generateLLMQuery();
|
|
2395
|
-
}), this.editor.type !== "sql" && (F.addCommand(
|
|
2428
|
+
}), this.editor.type !== "sql" && (F.addCommand(de.CtrlCmd | ve.KeyK, () => {
|
|
2396
2429
|
this.formatQuery();
|
|
2397
2430
|
}), F.addAction({
|
|
2398
2431
|
id: "trilogy.simple-editor.format-query",
|
|
@@ -2413,14 +2446,14 @@ const Oo = J({
|
|
|
2413
2446
|
},
|
|
2414
2447
|
insertSymbol(e) {
|
|
2415
2448
|
if (!F) return;
|
|
2416
|
-
const
|
|
2417
|
-
|
|
2449
|
+
const n = F.getPosition();
|
|
2450
|
+
n && e.insertText && (F.executeEdits("", [
|
|
2418
2451
|
{
|
|
2419
2452
|
range: new St(
|
|
2420
|
-
|
|
2421
|
-
|
|
2422
|
-
|
|
2423
|
-
|
|
2453
|
+
n.lineNumber,
|
|
2454
|
+
n.column,
|
|
2455
|
+
n.lineNumber,
|
|
2456
|
+
n.column
|
|
2424
2457
|
),
|
|
2425
2458
|
text: e.insertText
|
|
2426
2459
|
}
|
|
@@ -2428,23 +2461,23 @@ const Oo = J({
|
|
|
2428
2461
|
},
|
|
2429
2462
|
async validateQuery(e = !0) {
|
|
2430
2463
|
if (!F) return [];
|
|
2431
|
-
const
|
|
2464
|
+
const n = this.connectionStore, o = this.queryExecutionService;
|
|
2432
2465
|
try {
|
|
2433
2466
|
this.editor.setError(null);
|
|
2434
|
-
const l = F.getValue(), r =
|
|
2467
|
+
const l = F.getValue(), r = n.connections[this.editor.connection], i = {
|
|
2435
2468
|
text: l,
|
|
2436
2469
|
queryType: r ? r.query_type : "trilogy",
|
|
2437
2470
|
editorType: this.editor.type,
|
|
2438
2471
|
sources: [],
|
|
2439
2472
|
imports: this.imports,
|
|
2440
2473
|
extraContent: this.rootContent
|
|
2441
|
-
}, s = await
|
|
2474
|
+
}, s = await o.validateQuery(
|
|
2442
2475
|
this.editor.connection,
|
|
2443
2476
|
i
|
|
2444
2477
|
);
|
|
2445
2478
|
if (s && e) {
|
|
2446
2479
|
const f = F.getModel();
|
|
2447
|
-
f &&
|
|
2480
|
+
f && $e.setModelMarkers(f, "owner", s.data.items || []), s.data.completion_items && (this.editor.completionSymbols = s.data.completion_items);
|
|
2448
2481
|
}
|
|
2449
2482
|
return s ? s.data.imports : [];
|
|
2450
2483
|
} catch (l) {
|
|
@@ -2453,14 +2486,14 @@ const Oo = J({
|
|
|
2453
2486
|
},
|
|
2454
2487
|
async formatQuery() {
|
|
2455
2488
|
var r;
|
|
2456
|
-
const e = F,
|
|
2457
|
-
if (!
|
|
2458
|
-
let
|
|
2489
|
+
const e = F, n = _e(e, this.editor.contents);
|
|
2490
|
+
if (!n || !e) return;
|
|
2491
|
+
let o = (r = this.connectionStore) == null ? void 0 : r.connections[this.editor.connection], l = this.queryExecutionService;
|
|
2459
2492
|
if (l)
|
|
2460
2493
|
try {
|
|
2461
2494
|
const i = await l.formatQuery(
|
|
2462
|
-
|
|
2463
|
-
|
|
2495
|
+
n,
|
|
2496
|
+
o ? o.query_type : "",
|
|
2464
2497
|
this.editor.type,
|
|
2465
2498
|
this.imports,
|
|
2466
2499
|
this.rootContent
|
|
@@ -2477,13 +2510,13 @@ const Oo = J({
|
|
|
2477
2510
|
var r, i, s;
|
|
2478
2511
|
this.$emit("query-started"), this.editor.setError(null);
|
|
2479
2512
|
let e = !1;
|
|
2480
|
-
const
|
|
2513
|
+
const n = this.connectionStore, o = this.queryExecutionService, l = F;
|
|
2481
2514
|
if (!(this.editor.loading || !l))
|
|
2482
2515
|
try {
|
|
2483
2516
|
this.analyticsStore && this.analyticsStore.log("studio-query-execution", this.editor.type, !0), this.editor.loading = !0, this.lastOperation = null, this.editor.startTime = Date.now();
|
|
2484
|
-
const f =
|
|
2517
|
+
const f = n.connections[this.editor.connection], c = _e(l, this.editor.contents);
|
|
2485
2518
|
if (!c) {
|
|
2486
|
-
this.editor.results = new
|
|
2519
|
+
this.editor.results = new je(/* @__PURE__ */ new Map(), []), this.editor.loading = !1;
|
|
2487
2520
|
return;
|
|
2488
2521
|
}
|
|
2489
2522
|
const a = {
|
|
@@ -2492,26 +2525,26 @@ const Oo = J({
|
|
|
2492
2525
|
editorType: this.editor.type,
|
|
2493
2526
|
imports: this.imports,
|
|
2494
2527
|
extraContent: this.rootContent
|
|
2495
|
-
}, { resultPromise: v, cancellation:
|
|
2528
|
+
}, { resultPromise: v, cancellation: w } = await o.executeQuery(
|
|
2496
2529
|
this.editor.connection,
|
|
2497
2530
|
a,
|
|
2498
2531
|
// Progress callback for connection issues
|
|
2499
2532
|
() => {
|
|
2500
2533
|
},
|
|
2501
|
-
(
|
|
2502
|
-
!e &&
|
|
2534
|
+
(I) => {
|
|
2535
|
+
!e && I.error && (this.editor.loading = !1, I.message && this.editor.setError(I.message)), !e && I.running && (this.editor.error = null, this.editor.loading = !0);
|
|
2503
2536
|
}
|
|
2504
2537
|
);
|
|
2505
2538
|
this.editor.cancelCallback = () => {
|
|
2506
|
-
|
|
2539
|
+
w.isActive() && w.cancel(), this.editor.loading = !1, this.editor.cancelCallback = null;
|
|
2507
2540
|
};
|
|
2508
|
-
const
|
|
2541
|
+
const b = await v;
|
|
2509
2542
|
e = !0, this.lastOperation = {
|
|
2510
|
-
success:
|
|
2511
|
-
duration:
|
|
2512
|
-
rows: (r =
|
|
2543
|
+
success: b.success,
|
|
2544
|
+
duration: b.executionTime,
|
|
2545
|
+
rows: (r = b.results) != null && r.data ? (s = (i = b.results) == null ? void 0 : i.data) == null ? void 0 : s.length : void 0,
|
|
2513
2546
|
type: this.editor.type
|
|
2514
|
-
},
|
|
2547
|
+
}, b.success ? (this.editor.executed_contents = c, b.generatedSql && (this.editor.generated_sql = b.generatedSql), b.results && (this.editor.results = b.results, this.editor.duration = b.executionTime)) : b.error && (this.editor.executed_contents = c, this.editor.setError(b.error));
|
|
2515
2548
|
} catch (f) {
|
|
2516
2549
|
f instanceof Error && this.editor.setError(f.message || "Query execution failed"), this.lastOperation = {
|
|
2517
2550
|
success: !1,
|
|
@@ -2525,13 +2558,13 @@ const Oo = J({
|
|
|
2525
2558
|
// Add the LLM query generation method
|
|
2526
2559
|
async generateLLMQuery() {
|
|
2527
2560
|
if (this.editor.loading || !F) return;
|
|
2528
|
-
const e = this.llmConnectionStore,
|
|
2561
|
+
const e = this.llmConnectionStore, n = this.queryExecutionService, o = this.connectionStore;
|
|
2529
2562
|
if (!e) {
|
|
2530
2563
|
this.editor.setError("LLM connection store not available");
|
|
2531
2564
|
return;
|
|
2532
2565
|
}
|
|
2533
2566
|
try {
|
|
2534
|
-
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
|
|
2567
|
+
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 je(/* @__PURE__ */ new Map(), []), this.editor.setError(null);
|
|
2535
2568
|
const l = F.getValue();
|
|
2536
2569
|
if (await this.validateQuery(!1), !this.editor.completionSymbols || this.editor.completionSymbols.length === 0)
|
|
2537
2570
|
throw new Error("There are no imported concepts for LLM generation");
|
|
@@ -2541,7 +2574,7 @@ const Oo = J({
|
|
|
2541
2574
|
description: f.description,
|
|
2542
2575
|
calculation: f.calculation
|
|
2543
2576
|
})), i = async (f) => {
|
|
2544
|
-
const c =
|
|
2577
|
+
const c = o.connections[this.editor.connection], a = {
|
|
2545
2578
|
text: f,
|
|
2546
2579
|
queryType: c ? c.query_type : "",
|
|
2547
2580
|
editorType: this.editor.type,
|
|
@@ -2549,15 +2582,15 @@ const Oo = J({
|
|
|
2549
2582
|
extraContent: this.rootContent
|
|
2550
2583
|
};
|
|
2551
2584
|
try {
|
|
2552
|
-
const { resultPromise: v } = await
|
|
2585
|
+
const { resultPromise: v } = await n.executeQuery(
|
|
2553
2586
|
this.editor.connection,
|
|
2554
2587
|
a,
|
|
2555
2588
|
() => {
|
|
2556
2589
|
},
|
|
2557
2590
|
() => {
|
|
2558
2591
|
},
|
|
2559
|
-
(
|
|
2560
|
-
throw
|
|
2592
|
+
(w) => {
|
|
2593
|
+
throw w;
|
|
2561
2594
|
},
|
|
2562
2595
|
() => !0,
|
|
2563
2596
|
!0
|
|
@@ -2592,62 +2625,62 @@ const Oo = J({
|
|
|
2592
2625
|
return F ? F.getValue() : this.editor.contents || "";
|
|
2593
2626
|
}
|
|
2594
2627
|
}
|
|
2595
|
-
}),
|
|
2628
|
+
}), Bn = { class: "editor-container" }, Nn = { class: "menu-bar" }, Pn = { class: "menu-actions" }, Kn = { class: "editor-content" }, Wn = { class: "sidebar-panel" }, Un = { class: "be-sidebar-container" }, jn = { class: "be-sidebar-icons" }, _n = { class: "result-wrapper" }, Gn = {
|
|
2596
2629
|
key: 1,
|
|
2597
2630
|
class: "error-message"
|
|
2598
|
-
},
|
|
2631
|
+
}, zn = {
|
|
2599
2632
|
key: 2,
|
|
2600
2633
|
class: "results-summary",
|
|
2601
2634
|
"data-testid": "simple-editor-results"
|
|
2602
|
-
},
|
|
2635
|
+
}, Jn = { class: "results-details" }, Yn = {
|
|
2603
2636
|
key: 0,
|
|
2604
2637
|
class: "timing"
|
|
2605
|
-
},
|
|
2638
|
+
}, Zn = {
|
|
2606
2639
|
key: 1,
|
|
2607
2640
|
class: "row-count"
|
|
2608
|
-
},
|
|
2641
|
+
}, Xn = {
|
|
2609
2642
|
key: 2,
|
|
2610
2643
|
class: "operation-type"
|
|
2611
2644
|
};
|
|
2612
|
-
function
|
|
2613
|
-
const s =
|
|
2614
|
-
return
|
|
2615
|
-
t("div",
|
|
2616
|
-
t("div",
|
|
2645
|
+
function ei(e, n, o, l, r, i) {
|
|
2646
|
+
const s = Z("SymbolsPane"), f = Z("loading-view");
|
|
2647
|
+
return h(), y("div", Bn, [
|
|
2648
|
+
t("div", Nn, [
|
|
2649
|
+
t("div", Pn, [
|
|
2617
2650
|
t("button", {
|
|
2618
2651
|
class: "action-item",
|
|
2619
|
-
onClick:
|
|
2652
|
+
onClick: n[0] || (n[0] = (...c) => e.generateLLMQuery && e.generateLLMQuery(...c)),
|
|
2620
2653
|
title: "Generate query using AI",
|
|
2621
2654
|
"data-testid": "editor-generate-button"
|
|
2622
2655
|
}, " Generate "),
|
|
2623
|
-
e.editor.type !== "sql" ? (
|
|
2656
|
+
e.editor.type !== "sql" ? (h(), y("button", {
|
|
2624
2657
|
key: 0,
|
|
2625
2658
|
class: "action-item",
|
|
2626
|
-
onClick:
|
|
2659
|
+
onClick: n[1] || (n[1] = () => e.validateQuery())
|
|
2627
2660
|
}, " Parse ")) : R("", !0),
|
|
2628
|
-
e.editor.type !== "sql" ? (
|
|
2661
|
+
e.editor.type !== "sql" ? (h(), y("button", {
|
|
2629
2662
|
key: 1,
|
|
2630
2663
|
class: "action-item",
|
|
2631
|
-
onClick:
|
|
2664
|
+
onClick: n[2] || (n[2] = (...c) => e.formatQuery && e.formatQuery(...c)),
|
|
2632
2665
|
title: "Format query"
|
|
2633
2666
|
}, " Format ")) : R("", !0),
|
|
2634
2667
|
t("button", {
|
|
2635
|
-
onClick:
|
|
2636
|
-
class:
|
|
2668
|
+
onClick: n[3] || (n[3] = (c) => e.editor.loading ? e.cancelQuery() : e.runQuery()),
|
|
2669
|
+
class: q(["action-item", { "button-cancel": e.editor.loading, "button-run": !e.editor.loading }]),
|
|
2637
2670
|
"data-testid": "editor-run-button"
|
|
2638
|
-
},
|
|
2671
|
+
}, P(e.editor.loading ? "Cancel" : "Test"), 3)
|
|
2639
2672
|
])
|
|
2640
2673
|
]),
|
|
2641
|
-
t("div",
|
|
2674
|
+
t("div", Kn, [
|
|
2642
2675
|
t("div", {
|
|
2643
2676
|
ref: "editorElement",
|
|
2644
|
-
class:
|
|
2677
|
+
class: q(["editor-obj", {
|
|
2645
2678
|
"monaco-width-with-panel": e.isPanelVisible,
|
|
2646
2679
|
"monaco-width-no-panel": !e.isPanelVisible
|
|
2647
2680
|
}]),
|
|
2648
2681
|
"data-testid": "simple-editor-content"
|
|
2649
2682
|
}, null, 2),
|
|
2650
|
-
|
|
2683
|
+
ce(t("div", Wn, [
|
|
2651
2684
|
z(s, {
|
|
2652
2685
|
symbols: e.editor.completionSymbols || [],
|
|
2653
2686
|
onSelectSymbol: e.insertSymbol,
|
|
@@ -2656,38 +2689,38 @@ function Xo(e, o, n, l, r, i) {
|
|
|
2656
2689
|
], 512), [
|
|
2657
2690
|
[lt, e.isPanelVisible]
|
|
2658
2691
|
]),
|
|
2659
|
-
t("div",
|
|
2660
|
-
t("div",
|
|
2692
|
+
t("div", Un, [
|
|
2693
|
+
t("div", jn, [
|
|
2661
2694
|
t("button", {
|
|
2662
|
-
class:
|
|
2663
|
-
onClick:
|
|
2695
|
+
class: q(["sidebar-icon-button", { active: e.isPanelVisible }]),
|
|
2696
|
+
onClick: n[4] || (n[4] = (c) => e.togglePanel("symbols")),
|
|
2664
2697
|
title: "Symbols"
|
|
2665
|
-
}, [...
|
|
2698
|
+
}, [...n[5] || (n[5] = [
|
|
2666
2699
|
t("i", { class: "mdi mdi-tag-search-outline" }, null, -1)
|
|
2667
2700
|
])], 2)
|
|
2668
2701
|
])
|
|
2669
2702
|
])
|
|
2670
2703
|
]),
|
|
2671
|
-
t("div",
|
|
2672
|
-
e.editor.loading ? (
|
|
2704
|
+
t("div", _n, [
|
|
2705
|
+
e.editor.loading ? (h(), _(f, {
|
|
2673
2706
|
key: 0,
|
|
2674
2707
|
class: "loading-view",
|
|
2675
2708
|
text: "Loading...",
|
|
2676
2709
|
startTime: e.editor.startTime
|
|
2677
|
-
}, null, 8, ["startTime"])) : e.editor.error ? (
|
|
2710
|
+
}, null, 8, ["startTime"])) : e.editor.error ? (h(), y("div", Gn, P(e.editor.error), 1)) : e.lastOperation ? (h(), y("div", zn, [
|
|
2678
2711
|
t("div", {
|
|
2679
|
-
class:
|
|
2680
|
-
},
|
|
2681
|
-
t("div",
|
|
2682
|
-
e.lastOperation.duration ? (
|
|
2683
|
-
e.lastOperation.rows !== void 0 ? (
|
|
2684
|
-
e.lastOperation.type ? (
|
|
2712
|
+
class: q(["status-badge", e.lastOperation.success ? "success" : "error"])
|
|
2713
|
+
}, P(e.lastOperation.success ? "SUCCESS" : "FAILED"), 3),
|
|
2714
|
+
t("div", Jn, [
|
|
2715
|
+
e.lastOperation.duration ? (h(), y("div", Yn, P(e.lastOperation.duration) + "ms", 1)) : R("", !0),
|
|
2716
|
+
e.lastOperation.rows !== void 0 ? (h(), y("div", Zn, P(e.lastOperation.rows) + " " + P(e.lastOperation.rows === 1 ? "row" : "rows"), 1)) : R("", !0),
|
|
2717
|
+
e.lastOperation.type ? (h(), y("div", Xn, P(e.lastOperation.type), 1)) : R("", !0)
|
|
2685
2718
|
])
|
|
2686
2719
|
])) : R("", !0)
|
|
2687
2720
|
])
|
|
2688
2721
|
]);
|
|
2689
2722
|
}
|
|
2690
|
-
const
|
|
2723
|
+
const Ze = /* @__PURE__ */ Y(Qn, [["render", ei], ["__scopeId", "data-v-e4c72cff"]]), ti = { class: "editor-overlay" }, oi = { class: "editor-actions" }, ni = ["data-testid"], ii = /* @__PURE__ */ J({
|
|
2691
2724
|
__name: "DashboardEditorDialog",
|
|
2692
2725
|
props: {
|
|
2693
2726
|
initialWidth: {},
|
|
@@ -2698,39 +2731,39 @@ const Je = /* @__PURE__ */ Y(Oo, [["render", Xo], ["__scopeId", "data-v-e4c72cff
|
|
|
2698
2731
|
saveTestId: { default: "" }
|
|
2699
2732
|
},
|
|
2700
2733
|
emits: ["save", "cancel"],
|
|
2701
|
-
setup(e, { emit:
|
|
2702
|
-
const
|
|
2703
|
-
initialWidth:
|
|
2704
|
-
initialHeight:
|
|
2705
|
-
minWidth:
|
|
2706
|
-
minHeight:
|
|
2734
|
+
setup(e, { emit: n }) {
|
|
2735
|
+
const o = e, l = n, { editorElement: r, dialogStyle: i, startResize: s } = Dt(() => l("cancel"), {
|
|
2736
|
+
initialWidth: o.initialWidth,
|
|
2737
|
+
initialHeight: o.initialHeight,
|
|
2738
|
+
minWidth: o.minWidth,
|
|
2739
|
+
minHeight: o.minHeight
|
|
2707
2740
|
});
|
|
2708
|
-
return (f, c) => (
|
|
2741
|
+
return (f, c) => (h(), y("div", ti, [
|
|
2709
2742
|
t("div", {
|
|
2710
2743
|
ref_key: "editorElement",
|
|
2711
2744
|
ref: r,
|
|
2712
2745
|
class: "content-editor",
|
|
2713
|
-
style:
|
|
2746
|
+
style: Te(ie(i))
|
|
2714
2747
|
}, [
|
|
2715
|
-
|
|
2716
|
-
t("div",
|
|
2717
|
-
|
|
2748
|
+
Ke(f.$slots, "default", {}, void 0, !0),
|
|
2749
|
+
t("div", oi, [
|
|
2750
|
+
Ke(f.$slots, "actions", {}, () => [
|
|
2718
2751
|
t("button", {
|
|
2719
2752
|
class: "save-button",
|
|
2720
|
-
"data-testid":
|
|
2753
|
+
"data-testid": o.saveTestId || void 0,
|
|
2721
2754
|
onClick: c[0] || (c[0] = (a) => l("save"))
|
|
2722
|
-
},
|
|
2755
|
+
}, P(o.saveLabel), 9, ni),
|
|
2723
2756
|
t("button", {
|
|
2724
2757
|
class: "cancel-button",
|
|
2725
2758
|
onClick: c[1] || (c[1] = (a) => l("cancel"))
|
|
2726
2759
|
}, "Cancel")
|
|
2727
2760
|
], !0)
|
|
2728
2761
|
]),
|
|
2729
|
-
z(
|
|
2762
|
+
z(It, { onStartResize: ie(s) }, null, 8, ["onStartResize"])
|
|
2730
2763
|
], 4)
|
|
2731
2764
|
]));
|
|
2732
2765
|
}
|
|
2733
|
-
}),
|
|
2766
|
+
}), Xe = /* @__PURE__ */ Y(ii, [["__scopeId", "data-v-580721a8"]]), ri = { class: "editor-body" }, li = /* @__PURE__ */ J({
|
|
2734
2767
|
__name: "DashboardChartEditor",
|
|
2735
2768
|
props: {
|
|
2736
2769
|
content: {},
|
|
@@ -2741,25 +2774,25 @@ const Je = /* @__PURE__ */ Y(Oo, [["render", Xo], ["__scopeId", "data-v-e4c72cff
|
|
|
2741
2774
|
initialHeight: {}
|
|
2742
2775
|
},
|
|
2743
2776
|
emits: ["save", "cancel"],
|
|
2744
|
-
setup(e, { emit:
|
|
2745
|
-
const
|
|
2777
|
+
setup(e, { emit: n }) {
|
|
2778
|
+
const o = e, l = n, r = S(o.content), i = S(o.imports), s = S(null);
|
|
2746
2779
|
function f() {
|
|
2747
2780
|
s.value && l("save", s.value.getContent());
|
|
2748
2781
|
}
|
|
2749
2782
|
function c() {
|
|
2750
2783
|
l("cancel");
|
|
2751
2784
|
}
|
|
2752
|
-
return (a, v) => (
|
|
2753
|
-
initialWidth:
|
|
2754
|
-
initialHeight:
|
|
2785
|
+
return (a, v) => (h(), _(Xe, {
|
|
2786
|
+
initialWidth: o.initialWidth,
|
|
2787
|
+
initialHeight: o.initialHeight,
|
|
2755
2788
|
saveLabel: "Save Query",
|
|
2756
2789
|
saveTestId: "save-dashboard-chart",
|
|
2757
2790
|
onSave: f,
|
|
2758
2791
|
onCancel: c
|
|
2759
2792
|
}, {
|
|
2760
|
-
default:
|
|
2761
|
-
t("div",
|
|
2762
|
-
z(
|
|
2793
|
+
default: ee(() => [
|
|
2794
|
+
t("div", ri, [
|
|
2795
|
+
z(Ze, {
|
|
2763
2796
|
class: "editor-content",
|
|
2764
2797
|
initContent: r.value,
|
|
2765
2798
|
connectionName: e.connectionName,
|
|
@@ -2773,13 +2806,13 @@ const Je = /* @__PURE__ */ Y(Oo, [["render", Xo], ["__scopeId", "data-v-e4c72cff
|
|
|
2773
2806
|
_: 1
|
|
2774
2807
|
}, 8, ["initialWidth", "initialHeight"]));
|
|
2775
2808
|
}
|
|
2776
|
-
}),
|
|
2809
|
+
}), _i = /* @__PURE__ */ Y(li, [["__scopeId", "data-v-9717eaff"]]), ai = { class: "tab-header" }, si = { class: "editor-body" }, di = {
|
|
2777
2810
|
key: 0,
|
|
2778
2811
|
class: "tab-content"
|
|
2779
|
-
},
|
|
2812
|
+
}, ui = {
|
|
2780
2813
|
key: 1,
|
|
2781
2814
|
class: "tab-content"
|
|
2782
|
-
},
|
|
2815
|
+
}, ci = /* @__PURE__ */ J({
|
|
2783
2816
|
__name: "DashboardMarkdownEditor",
|
|
2784
2817
|
props: {
|
|
2785
2818
|
content: {},
|
|
@@ -2790,15 +2823,15 @@ const Je = /* @__PURE__ */ Y(Oo, [["render", Xo], ["__scopeId", "data-v-e4c72cff
|
|
|
2790
2823
|
initialHeight: {}
|
|
2791
2824
|
},
|
|
2792
2825
|
emits: ["save", "cancel"],
|
|
2793
|
-
setup(e, { emit:
|
|
2794
|
-
const
|
|
2795
|
-
|
|
2796
|
-
() =>
|
|
2826
|
+
setup(e, { emit: n }) {
|
|
2827
|
+
const o = e, l = n, r = p(() => typeof o.content == "string" ? { markdown: o.content, query: "" } : { markdown: o.content.markdown || "", query: o.content.query || "" }), i = S(r.value.markdown), s = S(r.value.query), f = S(o.imports), c = S(null), a = S("markdown");
|
|
2828
|
+
ue(
|
|
2829
|
+
() => o.content,
|
|
2797
2830
|
($) => {
|
|
2798
2831
|
const g = typeof $ == "string" ? { markdown: $, query: "" } : { markdown: $.markdown || "", query: $.query || "" };
|
|
2799
2832
|
i.value = g.markdown, s.value = g.query;
|
|
2800
2833
|
}
|
|
2801
|
-
),
|
|
2834
|
+
), ue(a, ($, g) => {
|
|
2802
2835
|
g === "query" && c.value && (s.value = c.value.getContent());
|
|
2803
2836
|
});
|
|
2804
2837
|
function v() {
|
|
@@ -2807,73 +2840,73 @@ const Je = /* @__PURE__ */ Y(Oo, [["render", Xo], ["__scopeId", "data-v-e4c72cff
|
|
|
2807
2840
|
query: s.value
|
|
2808
2841
|
});
|
|
2809
2842
|
}
|
|
2810
|
-
function
|
|
2843
|
+
function w() {
|
|
2811
2844
|
l("cancel");
|
|
2812
2845
|
}
|
|
2813
|
-
function
|
|
2846
|
+
function b($) {
|
|
2814
2847
|
a.value === "query" && c.value && (s.value = c.value.getContent()), a.value = $;
|
|
2815
2848
|
}
|
|
2816
|
-
function
|
|
2849
|
+
function I($, g = "") {
|
|
2817
2850
|
const B = document.querySelector(".markdown-editor");
|
|
2818
2851
|
if (!B) return;
|
|
2819
|
-
const
|
|
2820
|
-
i.value =
|
|
2821
|
-
B.focus(), B.setSelectionRange(
|
|
2852
|
+
const E = B.selectionStart, m = B.selectionEnd, D = i.value.substring(E, m), te = i.value.substring(0, E), ne = i.value.substring(m);
|
|
2853
|
+
i.value = te + $ + D + g + ne, setTimeout(() => {
|
|
2854
|
+
B.focus(), B.setSelectionRange(E + $.length, E + $.length + D.length);
|
|
2822
2855
|
}, 0);
|
|
2823
2856
|
}
|
|
2824
|
-
function
|
|
2825
|
-
|
|
2857
|
+
function x() {
|
|
2858
|
+
I("**", "**");
|
|
2826
2859
|
}
|
|
2827
2860
|
function k() {
|
|
2828
|
-
|
|
2861
|
+
I("*", "*");
|
|
2829
2862
|
}
|
|
2830
2863
|
function M() {
|
|
2831
|
-
|
|
2864
|
+
I("## ");
|
|
2832
2865
|
}
|
|
2833
2866
|
function T() {
|
|
2834
|
-
|
|
2867
|
+
I("- ");
|
|
2835
2868
|
}
|
|
2836
|
-
function
|
|
2837
|
-
|
|
2869
|
+
function O() {
|
|
2870
|
+
I("[", "](url)");
|
|
2838
2871
|
}
|
|
2839
|
-
function
|
|
2840
|
-
|
|
2872
|
+
function W() {
|
|
2873
|
+
I("{data[0].field_name}");
|
|
2841
2874
|
}
|
|
2842
|
-
function
|
|
2843
|
-
|
|
2875
|
+
function V() {
|
|
2876
|
+
I(`{{#each data}}
|
|
2844
2877
|
- {{field_name}}
|
|
2845
2878
|
{{/each}}`);
|
|
2846
2879
|
}
|
|
2847
|
-
return ($, g) => (
|
|
2848
|
-
initialWidth:
|
|
2849
|
-
initialHeight:
|
|
2880
|
+
return ($, g) => (h(), _(Xe, {
|
|
2881
|
+
initialWidth: o.initialWidth,
|
|
2882
|
+
initialHeight: o.initialHeight,
|
|
2850
2883
|
saveLabel: "Save Content",
|
|
2851
2884
|
saveTestId: "save-dashboard-markdown",
|
|
2852
2885
|
onSave: v,
|
|
2853
|
-
onCancel:
|
|
2886
|
+
onCancel: w
|
|
2854
2887
|
}, {
|
|
2855
|
-
default:
|
|
2856
|
-
t("div",
|
|
2888
|
+
default: ee(() => [
|
|
2889
|
+
t("div", ai, [
|
|
2857
2890
|
t("button", {
|
|
2858
|
-
onClick: g[0] || (g[0] = (B) =>
|
|
2859
|
-
class:
|
|
2891
|
+
onClick: g[0] || (g[0] = (B) => b("markdown")),
|
|
2892
|
+
class: q([{ active: a.value === "markdown" }, "tab-button"])
|
|
2860
2893
|
}, [...g[3] || (g[3] = [
|
|
2861
2894
|
t("i", { class: "mdi mdi-note-text-outline" }, null, -1),
|
|
2862
2895
|
t("span", null, "Markdown Template", -1)
|
|
2863
2896
|
])], 2),
|
|
2864
2897
|
t("button", {
|
|
2865
|
-
onClick: g[1] || (g[1] = (B) =>
|
|
2866
|
-
class:
|
|
2898
|
+
onClick: g[1] || (g[1] = (B) => b("query")),
|
|
2899
|
+
class: q([{ active: a.value === "query" }, "tab-button"])
|
|
2867
2900
|
}, [...g[4] || (g[4] = [
|
|
2868
2901
|
t("i", { class: "mdi mdi-magnify" }, null, -1),
|
|
2869
2902
|
t("span", null, "Data Query", -1)
|
|
2870
2903
|
])], 2)
|
|
2871
2904
|
]),
|
|
2872
|
-
t("div",
|
|
2873
|
-
a.value === "markdown" ? (
|
|
2905
|
+
t("div", si, [
|
|
2906
|
+
a.value === "markdown" ? (h(), y("div", di, [
|
|
2874
2907
|
t("div", { class: "markdown-toolbar" }, [
|
|
2875
2908
|
t("button", {
|
|
2876
|
-
onClick:
|
|
2909
|
+
onClick: x,
|
|
2877
2910
|
title: "Bold"
|
|
2878
2911
|
}, [...g[5] || (g[5] = [
|
|
2879
2912
|
t("strong", null, "B", -1)
|
|
@@ -2895,26 +2928,26 @@ const Je = /* @__PURE__ */ Y(Oo, [["render", Xo], ["__scopeId", "data-v-e4c72cff
|
|
|
2895
2928
|
t("i", { class: "mdi mdi-format-list-bulleted" }, null, -1)
|
|
2896
2929
|
])]),
|
|
2897
2930
|
t("button", {
|
|
2898
|
-
onClick:
|
|
2931
|
+
onClick: O,
|
|
2899
2932
|
title: "Link"
|
|
2900
2933
|
}, [...g[8] || (g[8] = [
|
|
2901
2934
|
t("i", { class: "mdi mdi-link-variant" }, null, -1)
|
|
2902
2935
|
])]),
|
|
2903
2936
|
g[10] || (g[10] = t("div", { class: "toolbar-separator" }, null, -1)),
|
|
2904
2937
|
t("button", {
|
|
2905
|
-
onClick:
|
|
2938
|
+
onClick: W,
|
|
2906
2939
|
title: "Insert data reference",
|
|
2907
2940
|
class: "data-button"
|
|
2908
2941
|
}, " {} "),
|
|
2909
2942
|
t("button", {
|
|
2910
|
-
onClick:
|
|
2943
|
+
onClick: V,
|
|
2911
2944
|
title: "Insert loop",
|
|
2912
2945
|
class: "data-button"
|
|
2913
2946
|
}, [...g[9] || (g[9] = [
|
|
2914
2947
|
t("i", { class: "mdi mdi-refresh" }, null, -1)
|
|
2915
2948
|
])])
|
|
2916
2949
|
]),
|
|
2917
|
-
|
|
2950
|
+
ce(t("textarea", {
|
|
2918
2951
|
"onUpdate:modelValue": g[2] || (g[2] = (B) => i.value = B),
|
|
2919
2952
|
placeholder: `Enter markdown content here...
|
|
2920
2953
|
|
|
@@ -2926,14 +2959,14 @@ Template examples:
|
|
|
2926
2959
|
- {{#each data limit=5}} {{field_name}} {{/each}} - Loop first 5`,
|
|
2927
2960
|
class: "markdown-editor"
|
|
2928
2961
|
}, null, 512), [
|
|
2929
|
-
[
|
|
2962
|
+
[pe, i.value]
|
|
2930
2963
|
])
|
|
2931
2964
|
])) : R("", !0),
|
|
2932
|
-
a.value === "query" ? (
|
|
2965
|
+
a.value === "query" ? (h(), y("div", ui, [
|
|
2933
2966
|
g[11] || (g[11] = t("div", { class: "query-help" }, [
|
|
2934
2967
|
t("p", null, " Write a query to fetch data for your markdown template. Leave empty if no data is needed. ")
|
|
2935
2968
|
], -1)),
|
|
2936
|
-
z(
|
|
2969
|
+
z(Ze, {
|
|
2937
2970
|
class: "editor-content",
|
|
2938
2971
|
initContent: s.value,
|
|
2939
2972
|
connectionName: e.connectionName,
|
|
@@ -2948,38 +2981,38 @@ Template examples:
|
|
|
2948
2981
|
_: 1
|
|
2949
2982
|
}, 8, ["initialWidth", "initialHeight"]));
|
|
2950
2983
|
}
|
|
2951
|
-
}), Gi = /* @__PURE__ */ Y(
|
|
2984
|
+
}), Gi = /* @__PURE__ */ Y(ci, [["__scopeId", "data-v-d2f32030"]]), mi = { class: "dashboard-setup" }, hi = { class: "setup-section" }, fi = {
|
|
2952
2985
|
key: 0,
|
|
2953
2986
|
class: "setup-section"
|
|
2954
|
-
},
|
|
2987
|
+
}, vi = { class: "action-row" }, pi = ["disabled"], yi = {
|
|
2955
2988
|
key: 0,
|
|
2956
2989
|
class: "error-message"
|
|
2957
|
-
},
|
|
2990
|
+
}, gi = { class: "setup-section" }, bi = { class: "templates-grid" }, Ci = ["onClick", "data-testid"], wi = { class: "template-icon" }, ki = { class: "template-info" }, Si = { class: "template-title" }, Ei = { class: "template-desc" }, Q = 20, zi = /* @__PURE__ */ J({
|
|
2958
2991
|
__name: "DashboardCTA",
|
|
2959
2992
|
props: {
|
|
2960
2993
|
dashboardId: {}
|
|
2961
2994
|
},
|
|
2962
2995
|
emits: ["template-selected", "description-updated"],
|
|
2963
|
-
setup(e, { emit:
|
|
2964
|
-
const
|
|
2996
|
+
setup(e, { emit: n }) {
|
|
2997
|
+
const o = j("dashboardStore"), l = j("editorStore"), r = j("llmConnectionStore"), i = j(
|
|
2965
2998
|
"queryExecutionService"
|
|
2966
2999
|
), s = j("saveDashboards");
|
|
2967
|
-
if (!
|
|
3000
|
+
if (!o || !r || !i || !s)
|
|
2968
3001
|
throw new Error("DashboardStore, LLMConnectionStore, or QueryExecutionService not provided");
|
|
2969
|
-
const f = e, c = p(() => r.activeConnection), a =
|
|
3002
|
+
const f = e, c = p(() => r.activeConnection), a = n, v = S(""), w = S(""), b = S(!1), I = S(""), x = S(null), k = Q / 4, M = [
|
|
2970
3003
|
{
|
|
2971
3004
|
id: "summary",
|
|
2972
3005
|
name: "Summary Dashboard",
|
|
2973
3006
|
description: "High-level metrics and KPIs with key visualizations",
|
|
2974
3007
|
icon: "mdi-view-dashboard",
|
|
2975
3008
|
layout: [
|
|
2976
|
-
{ i: "title", x: 0, y: 0, w: Q, h: 3, type:
|
|
2977
|
-
{ i: "kpi1", x: 0, y: 3, w: Q / 4, h: 4, type:
|
|
2978
|
-
{ i: "kpi2", x: k, y: 3, w: Q / 4, h: 4, type:
|
|
2979
|
-
{ i: "kpi3", x: k * 2, y: 3, w: Q / 4, h: 4, type:
|
|
2980
|
-
{ i: "kpi4", x: k * 3, y: 3, w: Q / 4, h: 4, type:
|
|
2981
|
-
{ i: "trend", x: 0, y: 7, w: Q / 2, h: 8, type:
|
|
2982
|
-
{ i: "breakdown", x: Q / 2, y: 7, w: Q / 2, h: 8, type:
|
|
3009
|
+
{ i: "title", x: 0, y: 0, w: Q, h: 3, type: C.MARKDOWN },
|
|
3010
|
+
{ i: "kpi1", x: 0, y: 3, w: Q / 4, h: 4, type: C.CHART },
|
|
3011
|
+
{ i: "kpi2", x: k, y: 3, w: Q / 4, h: 4, type: C.CHART },
|
|
3012
|
+
{ i: "kpi3", x: k * 2, y: 3, w: Q / 4, h: 4, type: C.CHART },
|
|
3013
|
+
{ i: "kpi4", x: k * 3, y: 3, w: Q / 4, h: 4, type: C.CHART },
|
|
3014
|
+
{ i: "trend", x: 0, y: 7, w: Q / 2, h: 8, type: C.CHART },
|
|
3015
|
+
{ i: "breakdown", x: Q / 2, y: 7, w: Q / 2, h: 8, type: C.CHART }
|
|
2983
3016
|
]
|
|
2984
3017
|
},
|
|
2985
3018
|
{
|
|
@@ -2988,11 +3021,11 @@ Template examples:
|
|
|
2988
3021
|
description: "Hierarchical data exploration with filtering capabilities",
|
|
2989
3022
|
icon: "mdi-magnify-expand",
|
|
2990
3023
|
layout: [
|
|
2991
|
-
{ i: "filters", x: 0, y: 0, w: Q, h: 3, type:
|
|
2992
|
-
{ i: "overview", x: 0, y: 3, w: Q, h: 5, type:
|
|
2993
|
-
{ i: "detail1", x: 0, y: 8, w: Q / 2, h: 8, type:
|
|
2994
|
-
{ i: "detail2", x: Q / 2, y: 10, w: Q / 2, h: 8, type:
|
|
2995
|
-
{ i: "datatable", x: 0, y: 20, w: Q, h: 8, type:
|
|
3024
|
+
{ i: "filters", x: 0, y: 0, w: Q, h: 3, type: C.MARKDOWN },
|
|
3025
|
+
{ i: "overview", x: 0, y: 3, w: Q, h: 5, type: C.CHART },
|
|
3026
|
+
{ i: "detail1", x: 0, y: 8, w: Q / 2, h: 8, type: C.CHART },
|
|
3027
|
+
{ i: "detail2", x: Q / 2, y: 10, w: Q / 2, h: 8, type: C.CHART },
|
|
3028
|
+
{ i: "datatable", x: 0, y: 20, w: Q, h: 8, type: C.TABLE }
|
|
2996
3029
|
]
|
|
2997
3030
|
},
|
|
2998
3031
|
{
|
|
@@ -3001,12 +3034,12 @@ Template examples:
|
|
|
3001
3034
|
description: "Side-by-side comparisons of metrics across dimensions",
|
|
3002
3035
|
icon: "mdi-compare",
|
|
3003
3036
|
layout: [
|
|
3004
|
-
{ i: "title", x: 0, y: 0, w: Q, h: 3, type:
|
|
3005
|
-
{ i: "compare1", x: 0, y: 3, w: Q / 2, h: 6, type:
|
|
3006
|
-
{ i: "compare2", x: Q / 2, y: 3, w: Q / 2, h: 6, type:
|
|
3007
|
-
{ i: "compare3", x: 0, y: 9, w: Q / 2, h: 6, type:
|
|
3008
|
-
{ i: "compare4", x: Q / 2, y: 9, w: Q / 2, h: 6, type:
|
|
3009
|
-
{ i: "summary", x: 0, y: 15, w: Q, h: 5, type:
|
|
3037
|
+
{ i: "title", x: 0, y: 0, w: Q, h: 3, type: C.MARKDOWN },
|
|
3038
|
+
{ i: "compare1", x: 0, y: 3, w: Q / 2, h: 6, type: C.CHART },
|
|
3039
|
+
{ i: "compare2", x: Q / 2, y: 3, w: Q / 2, h: 6, type: C.CHART },
|
|
3040
|
+
{ i: "compare3", x: 0, y: 9, w: Q / 2, h: 6, type: C.CHART },
|
|
3041
|
+
{ i: "compare4", x: Q / 2, y: 9, w: Q / 2, h: 6, type: C.CHART },
|
|
3042
|
+
{ i: "summary", x: 0, y: 15, w: Q, h: 5, type: C.MARKDOWN }
|
|
3010
3043
|
]
|
|
3011
3044
|
},
|
|
3012
3045
|
{
|
|
@@ -3015,12 +3048,12 @@ Template examples:
|
|
|
3015
3048
|
description: "Visualization of trends and patterns over time",
|
|
3016
3049
|
icon: "mdi-chart-timeline-variant",
|
|
3017
3050
|
layout: [
|
|
3018
|
-
{ i: "headline", x: 0, y: 0, w: Q, h: 3, type:
|
|
3019
|
-
{ i: "maintrend", x: 0, y: 3, w: Q, h: 8, type:
|
|
3020
|
-
{ i: "breakdown1", x: 0, y: 11, w: Q / 3, h: 6, type:
|
|
3021
|
-
{ i: "breakdown2", x: Q / 3, y: 11, w: Q / 3, h: 6, type:
|
|
3022
|
-
{ i: "breakdown3", x: Q / 3 * 2, y: 11, w: Q / 3, h: 6, type:
|
|
3023
|
-
{ i: "forecast", x: 0, y: 17, w: Q, h: 6, type:
|
|
3051
|
+
{ i: "headline", x: 0, y: 0, w: Q, h: 3, type: C.MARKDOWN },
|
|
3052
|
+
{ i: "maintrend", x: 0, y: 3, w: Q, h: 8, type: C.CHART },
|
|
3053
|
+
{ i: "breakdown1", x: 0, y: 11, w: Q / 3, h: 6, type: C.CHART },
|
|
3054
|
+
{ i: "breakdown2", x: Q / 3, y: 11, w: Q / 3, h: 6, type: C.CHART },
|
|
3055
|
+
{ i: "breakdown3", x: Q / 3 * 2, y: 11, w: Q / 3, h: 6, type: C.CHART },
|
|
3056
|
+
{ i: "forecast", x: 0, y: 17, w: Q, h: 6, type: C.CHART }
|
|
3024
3057
|
]
|
|
3025
3058
|
}
|
|
3026
3059
|
// {
|
|
@@ -3031,12 +3064,12 @@ Template examples:
|
|
|
3031
3064
|
// layout: []
|
|
3032
3065
|
// }
|
|
3033
3066
|
];
|
|
3034
|
-
function T(
|
|
3035
|
-
|
|
3036
|
-
const $ = M.find((g) => g.id ===
|
|
3067
|
+
function T(V) {
|
|
3068
|
+
x.value = V;
|
|
3069
|
+
const $ = M.find((g) => g.id === V);
|
|
3037
3070
|
if ($ && f.dashboardId) {
|
|
3038
3071
|
for (const g of $.layout)
|
|
3039
|
-
|
|
3072
|
+
o.addItemToDashboard(
|
|
3040
3073
|
f.dashboardId,
|
|
3041
3074
|
g.type,
|
|
3042
3075
|
g.x,
|
|
@@ -3044,120 +3077,120 @@ Template examples:
|
|
|
3044
3077
|
g.w,
|
|
3045
3078
|
g.h
|
|
3046
3079
|
);
|
|
3047
|
-
a("template-selected",
|
|
3080
|
+
a("template-selected", V);
|
|
3048
3081
|
}
|
|
3049
3082
|
}
|
|
3050
|
-
function
|
|
3051
|
-
f.dashboardId && v.value && (
|
|
3083
|
+
function O() {
|
|
3084
|
+
f.dashboardId && v.value && (o.updateDashboardDescription(f.dashboardId, v.value), a("description-updated", v.value));
|
|
3052
3085
|
}
|
|
3053
|
-
async function
|
|
3054
|
-
if (!
|
|
3055
|
-
|
|
3086
|
+
async function W() {
|
|
3087
|
+
if (!w.value.trim()) {
|
|
3088
|
+
I.value = "Please provide a prompt for the dashboard generation.";
|
|
3056
3089
|
return;
|
|
3057
3090
|
}
|
|
3058
3091
|
try {
|
|
3059
|
-
|
|
3060
|
-
const
|
|
3061
|
-
|
|
3092
|
+
b.value = !0, I.value = "";
|
|
3093
|
+
const V = await o.generatePromptSpec(
|
|
3094
|
+
w.value,
|
|
3062
3095
|
r,
|
|
3063
3096
|
i,
|
|
3064
3097
|
l
|
|
3065
3098
|
);
|
|
3066
|
-
console.log("Prompt spec generated:",
|
|
3099
|
+
console.log("Prompt spec generated:", V), V ? (await o.populateFromPromptSpec(
|
|
3067
3100
|
f.dashboardId,
|
|
3068
|
-
|
|
3101
|
+
V,
|
|
3069
3102
|
r,
|
|
3070
3103
|
i,
|
|
3071
3104
|
l
|
|
3072
|
-
), !v.value &&
|
|
3073
|
-
} catch (
|
|
3074
|
-
console.error("Error generating dashboard with LLM:",
|
|
3105
|
+
), !v.value && V.description && (v.value = V.description, O()), s()) : I.value = "Failed to generate dashboard specification.";
|
|
3106
|
+
} catch (V) {
|
|
3107
|
+
console.error("Error generating dashboard with LLM:", V), I.value = "An error occurred while generating the dashboard.";
|
|
3075
3108
|
} finally {
|
|
3076
|
-
|
|
3109
|
+
b.value = !1;
|
|
3077
3110
|
}
|
|
3078
3111
|
}
|
|
3079
|
-
return (
|
|
3112
|
+
return (V, $) => (h(), y("div", mi, [
|
|
3080
3113
|
$[7] || ($[7] = t("div", { class: "setup-header" }, [
|
|
3081
3114
|
t("h2", { class: "setup-title" }, "An Empty Dashboard"),
|
|
3082
3115
|
t("p", { class: "setup-subtitle" }, " Choose a template or start from scratch by using the 'add item' button to add charts, tables, and more. ")
|
|
3083
3116
|
], -1)),
|
|
3084
|
-
t("div",
|
|
3117
|
+
t("div", hi, [
|
|
3085
3118
|
$[3] || ($[3] = t("h3", { class: "section-title" }, "Description", -1)),
|
|
3086
|
-
|
|
3119
|
+
ce(t("textarea", {
|
|
3087
3120
|
"onUpdate:modelValue": $[0] || ($[0] = (g) => v.value = g),
|
|
3088
3121
|
placeholder: "What is this dashboard for? Add context to help viewers understand the data...",
|
|
3089
3122
|
rows: "3",
|
|
3090
3123
|
class: "description-input"
|
|
3091
3124
|
}, null, 512), [
|
|
3092
|
-
[
|
|
3125
|
+
[pe, v.value]
|
|
3093
3126
|
]),
|
|
3094
3127
|
t("button", {
|
|
3095
|
-
onClick:
|
|
3128
|
+
onClick: O,
|
|
3096
3129
|
class: "action-button save-button",
|
|
3097
3130
|
"data-testid": "dashboard-description-save"
|
|
3098
3131
|
}, [...$[2] || ($[2] = [
|
|
3099
3132
|
t("i", { class: "mdi mdi-content-save" }, null, -1),
|
|
3100
|
-
|
|
3133
|
+
Ce(" Save ", -1)
|
|
3101
3134
|
])])
|
|
3102
3135
|
]),
|
|
3103
|
-
c.value ? (
|
|
3136
|
+
c.value ? (h(), y("div", fi, [
|
|
3104
3137
|
$[4] || ($[4] = t("h3", { class: "section-title" }, "AI Copilot", -1)),
|
|
3105
3138
|
$[5] || ($[5] = t("p", { class: "section-desc" }, " Let AI help build your dashboard based on your data and description ", -1)),
|
|
3106
|
-
|
|
3107
|
-
"onUpdate:modelValue": $[1] || ($[1] = (g) =>
|
|
3139
|
+
ce(t("textarea", {
|
|
3140
|
+
"onUpdate:modelValue": $[1] || ($[1] = (g) => w.value = g),
|
|
3108
3141
|
placeholder: "Describe the dashboard you want to create. For example: 'Create a sales performance dashboard with monthly trends, regional breakdown, and top product metrics.'",
|
|
3109
3142
|
rows: "4",
|
|
3110
3143
|
class: "description-input",
|
|
3111
3144
|
"data-testid": "dashboard-prompt-input"
|
|
3112
3145
|
}, null, 512), [
|
|
3113
|
-
[
|
|
3146
|
+
[pe, w.value]
|
|
3114
3147
|
]),
|
|
3115
|
-
t("div",
|
|
3148
|
+
t("div", vi, [
|
|
3116
3149
|
t("button", {
|
|
3117
|
-
onClick:
|
|
3150
|
+
onClick: W,
|
|
3118
3151
|
class: "action-button llm-button",
|
|
3119
|
-
disabled:
|
|
3152
|
+
disabled: b.value || !w.value.trim(),
|
|
3120
3153
|
"data-testid": "generate-with-llm-button"
|
|
3121
3154
|
}, [
|
|
3122
3155
|
t("i", {
|
|
3123
|
-
class:
|
|
3156
|
+
class: q(["mdi", b.value ? "mdi-loading mdi-spin" : "mdi-creation"])
|
|
3124
3157
|
}, null, 2),
|
|
3125
|
-
|
|
3126
|
-
], 8,
|
|
3127
|
-
|
|
3158
|
+
Ce(" " + P(b.value ? "Generating..." : "Generate with AI"), 1)
|
|
3159
|
+
], 8, pi),
|
|
3160
|
+
I.value ? (h(), y("div", yi, P(I.value), 1)) : R("", !0)
|
|
3128
3161
|
])
|
|
3129
3162
|
])) : R("", !0),
|
|
3130
|
-
t("div",
|
|
3163
|
+
t("div", gi, [
|
|
3131
3164
|
$[6] || ($[6] = t("h3", { class: "section-title" }, "Templates", -1)),
|
|
3132
|
-
t("div",
|
|
3133
|
-
(
|
|
3165
|
+
t("div", bi, [
|
|
3166
|
+
(h(), y(fe, null, we(M, (g) => t("div", {
|
|
3134
3167
|
key: g.id,
|
|
3135
|
-
class:
|
|
3168
|
+
class: q(["template-card", { selected: x.value === g.id }]),
|
|
3136
3169
|
onClick: (B) => T(g.id),
|
|
3137
3170
|
"data-testid": `template-card-${g.id}`
|
|
3138
3171
|
}, [
|
|
3139
|
-
t("div",
|
|
3172
|
+
t("div", wi, [
|
|
3140
3173
|
t("i", {
|
|
3141
|
-
class:
|
|
3174
|
+
class: q(["mdi", g.icon])
|
|
3142
3175
|
}, null, 2)
|
|
3143
3176
|
]),
|
|
3144
|
-
t("div",
|
|
3145
|
-
t("h4",
|
|
3146
|
-
t("p",
|
|
3177
|
+
t("div", ki, [
|
|
3178
|
+
t("h4", Si, P(g.name), 1),
|
|
3179
|
+
t("p", Ei, P(g.description), 1)
|
|
3147
3180
|
])
|
|
3148
|
-
], 10,
|
|
3181
|
+
], 10, Ci)), 64))
|
|
3149
3182
|
])
|
|
3150
3183
|
])
|
|
3151
3184
|
]));
|
|
3152
3185
|
}
|
|
3153
3186
|
});
|
|
3154
|
-
function
|
|
3155
|
-
const r = ht(), i =
|
|
3187
|
+
function Ji(e, n, o, l) {
|
|
3188
|
+
const r = ht(), i = ze();
|
|
3156
3189
|
let s = j("queryExecutionService");
|
|
3157
|
-
const { setActiveDashboard: f } =
|
|
3190
|
+
const { setActiveDashboard: f } = Je();
|
|
3158
3191
|
if (!s)
|
|
3159
3192
|
throw new Error("QueryExecutionService not provided");
|
|
3160
|
-
const c = S(""), a = S(""), v = S(""),
|
|
3193
|
+
const c = S(""), a = S(""), v = S(""), w = S(null), b = S(null), I = S(!1), x = S(!1), k = S(!1), M = S([]), T = p(() => n.maxWidth || "100vw"), O = p(() => e.value ? e.value.layout : []), W = p(() => e.value ? [...e.value.layout].sort((u, L) => (u.y + u.y + u.h) / 2 - (L.y + L.y + L.h) / 2) : []), V = p(() => e.value ? e.value.connection : ""), $ = p(() => n.viewMode ? !1 : e.value ? e.value.state === "editing" : !1), g = p(() => e.value ? e.value.imports.map((u) => {
|
|
3161
3194
|
var L, d;
|
|
3162
3195
|
return {
|
|
3163
3196
|
alias: u.name,
|
|
@@ -3167,13 +3200,13 @@ function zi(e, o, n, l) {
|
|
|
3167
3200
|
}) : []);
|
|
3168
3201
|
function B(u) {
|
|
3169
3202
|
if (!(u != null && u.id)) return;
|
|
3170
|
-
u.state === "fullscreen" &&
|
|
3171
|
-
const L =
|
|
3172
|
-
(
|
|
3203
|
+
u.state === "fullscreen" && o.fullScreen(!0), r.setActiveDashboard(u.id), v.value = "", c.value = "", a.value = "", M.value = [], u.filter && (c.value = u.filter, a.value = u.filter);
|
|
3204
|
+
const L = N(u.id), d = Object.keys(u.gridItems).filter(
|
|
3205
|
+
(H) => u.gridItems[H].type !== C.SECTION_HEADER && !u.gridItems[H].results
|
|
3173
3206
|
);
|
|
3174
|
-
L == null || L.runBatch(d),
|
|
3207
|
+
L == null || L.runBatch(d), te();
|
|
3175
3208
|
}
|
|
3176
|
-
|
|
3209
|
+
ue(
|
|
3177
3210
|
() => {
|
|
3178
3211
|
var u;
|
|
3179
3212
|
return (u = e.value) == null ? void 0 : u.id;
|
|
@@ -3181,16 +3214,16 @@ function zi(e, o, n, l) {
|
|
|
3181
3214
|
(u, L) => {
|
|
3182
3215
|
u && u !== L && e.value && B(e.value);
|
|
3183
3216
|
}
|
|
3184
|
-
),
|
|
3217
|
+
), Ge(() => {
|
|
3185
3218
|
e.value && B(e.value);
|
|
3186
3219
|
const u = new ResizeObserver(() => {
|
|
3187
|
-
|
|
3188
|
-
}), L =
|
|
3220
|
+
o.triggerResize();
|
|
3221
|
+
}), L = n.isMobile ? ".mobile-container" : ".grid-container", d = document.querySelector(L);
|
|
3189
3222
|
d && u.observe(d);
|
|
3190
3223
|
}), at(() => {
|
|
3191
|
-
|
|
3224
|
+
w.value !== null && clearTimeout(w.value);
|
|
3192
3225
|
});
|
|
3193
|
-
async function
|
|
3226
|
+
async function E() {
|
|
3194
3227
|
var u;
|
|
3195
3228
|
if (e.value && e.value.id) {
|
|
3196
3229
|
c.value = "", a.value = "", v.value = "";
|
|
@@ -3198,13 +3231,13 @@ function zi(e, o, n, l) {
|
|
|
3198
3231
|
await ((u = r.getQueryExecutor(e.value.id)) == null ? void 0 : u.runBatch(L));
|
|
3199
3232
|
}
|
|
3200
3233
|
}
|
|
3201
|
-
async function
|
|
3234
|
+
async function m(u) {
|
|
3202
3235
|
var L;
|
|
3203
|
-
if (!u ||
|
|
3236
|
+
if (!u || Ue(u) === "") {
|
|
3204
3237
|
if (v.value = "", e.value && e.value.id) {
|
|
3205
3238
|
let d = r.updateDashboardFilter(
|
|
3206
3239
|
e.value.id,
|
|
3207
|
-
|
|
3240
|
+
Ue(u)
|
|
3208
3241
|
);
|
|
3209
3242
|
await ((L = r.getQueryExecutor(e.value.id)) == null ? void 0 : L.runBatch(d));
|
|
3210
3243
|
}
|
|
@@ -3219,12 +3252,12 @@ function zi(e, o, n, l) {
|
|
|
3219
3252
|
}).then(() => {
|
|
3220
3253
|
var d;
|
|
3221
3254
|
if (v.value = "", e.value && e.value.id) {
|
|
3222
|
-
let
|
|
3223
|
-
(d = r.getQueryExecutor(e.value.id)) == null || d.runBatch(
|
|
3255
|
+
let H = r.updateDashboardFilter(e.value.id, u);
|
|
3256
|
+
(d = r.getQueryExecutor(e.value.id)) == null || d.runBatch(H);
|
|
3224
3257
|
}
|
|
3225
3258
|
}).catch((d) => (v.value = d.message, !1))));
|
|
3226
3259
|
}
|
|
3227
|
-
const
|
|
3260
|
+
const D = async (u) => {
|
|
3228
3261
|
let L = u.replace(/^\s*where\s+/i, "");
|
|
3229
3262
|
if (e.value && e.value.id) {
|
|
3230
3263
|
let d = await (s == null ? void 0 : s.executeQuery(
|
|
@@ -3248,15 +3281,15 @@ function zi(e, o, n, l) {
|
|
|
3248
3281
|
));
|
|
3249
3282
|
if (!d)
|
|
3250
3283
|
throw new Error("No promises returned from query execution service");
|
|
3251
|
-
let
|
|
3252
|
-
if (!
|
|
3284
|
+
let H = await d.resultPromise;
|
|
3285
|
+
if (!H.success)
|
|
3253
3286
|
throw new Error(
|
|
3254
|
-
`Validation of "select 1 as test ${L}" resulted in ${
|
|
3287
|
+
`Validation of "select 1 as test ${L}" resulted in ${H.error}`
|
|
3255
3288
|
);
|
|
3256
3289
|
} else
|
|
3257
3290
|
throw new Error("Dashboard not found");
|
|
3258
3291
|
};
|
|
3259
|
-
async function
|
|
3292
|
+
async function te() {
|
|
3260
3293
|
if (e.value && e.value.id && s) {
|
|
3261
3294
|
let u = await r.populateCompletion(
|
|
3262
3295
|
e.value.id,
|
|
@@ -3266,58 +3299,58 @@ function zi(e, o, n, l) {
|
|
|
3266
3299
|
u && (M.value = u), v.value = "";
|
|
3267
3300
|
}
|
|
3268
3301
|
}
|
|
3269
|
-
async function
|
|
3270
|
-
e.value && e.value.id && (r.updateDashboardImports(e.value.id, u), await
|
|
3302
|
+
async function ne(u) {
|
|
3303
|
+
e.value && e.value.id && (r.updateDashboardImports(e.value.id, u), await te());
|
|
3271
3304
|
}
|
|
3272
3305
|
const U = (u) => {
|
|
3273
|
-
e.value && (r.setState(e.value.id, u),
|
|
3274
|
-
|
|
3306
|
+
e.value && (r.setState(e.value.id, u), We(() => {
|
|
3307
|
+
o.triggerResize();
|
|
3275
3308
|
}));
|
|
3276
|
-
},
|
|
3309
|
+
}, ke = (u) => {
|
|
3277
3310
|
e.value && e.value.id && r.updateDashboardLayout(e.value.id, u);
|
|
3278
3311
|
};
|
|
3279
|
-
function
|
|
3312
|
+
function Se() {
|
|
3280
3313
|
k.value = !0;
|
|
3281
3314
|
}
|
|
3282
|
-
function
|
|
3315
|
+
function G(u = C.CHART) {
|
|
3283
3316
|
if (!e.value || !e.value.id) return;
|
|
3284
|
-
const L = u ===
|
|
3285
|
-
k.value = !1,
|
|
3286
|
-
|
|
3317
|
+
const L = u === C.SECTION_HEADER ? r.addItemToDashboard(e.value.id, u, 0, 0, 20, 1) : r.addItemToDashboard(e.value.id, u);
|
|
3318
|
+
k.value = !1, We(() => {
|
|
3319
|
+
o.dimensionsUpdate(L);
|
|
3287
3320
|
});
|
|
3288
3321
|
}
|
|
3289
|
-
function
|
|
3322
|
+
function re(u) {
|
|
3290
3323
|
!e.value || !e.value.id || r.updateDashboardTitle(e.value.id, u);
|
|
3291
3324
|
}
|
|
3292
|
-
function
|
|
3325
|
+
function le() {
|
|
3293
3326
|
!e.value || !e.value.id || r.clearDashboardItems(e.value.id);
|
|
3294
3327
|
}
|
|
3295
|
-
function
|
|
3328
|
+
function X(u) {
|
|
3296
3329
|
!e.value || !e.value.id || r.removeItemFromDashboard(e.value.id, u);
|
|
3297
3330
|
}
|
|
3298
|
-
function
|
|
3331
|
+
function De(u) {
|
|
3299
3332
|
!e.value || !e.value.id || r.copyItemInDashboard(e.value.id, u);
|
|
3300
3333
|
}
|
|
3301
|
-
function
|
|
3334
|
+
function ye() {
|
|
3302
3335
|
k.value = !1;
|
|
3303
3336
|
}
|
|
3304
|
-
function
|
|
3305
|
-
if (
|
|
3337
|
+
function Ae(u) {
|
|
3338
|
+
if (b.value = u, !e.value || !e.value.id) return;
|
|
3306
3339
|
const d = e.value.gridItems[u.i];
|
|
3307
|
-
d && (d.type ===
|
|
3340
|
+
d && (d.type === C.CHART ? I.value = !0 : d.type === C.MARKDOWN ? x.value = !0 : d.type === C.TABLE || d.type === C.FILTER ? I.value = !0 : d.type === C.SECTION_HEADER && (b.value = null));
|
|
3308
3341
|
}
|
|
3309
|
-
function
|
|
3310
|
-
if (!e.value || !e.value.id || !
|
|
3311
|
-
const L =
|
|
3312
|
-
|
|
3342
|
+
function qe(u) {
|
|
3343
|
+
if (!e.value || !e.value.id || !b.value) return;
|
|
3344
|
+
const L = b.value.i;
|
|
3345
|
+
A(L, e.value.id, { content: u }), Ie();
|
|
3313
3346
|
}
|
|
3314
|
-
function
|
|
3315
|
-
|
|
3347
|
+
function Ie() {
|
|
3348
|
+
I.value = !1, x.value = !1, b.value = null;
|
|
3316
3349
|
}
|
|
3317
|
-
function
|
|
3350
|
+
function K(u, L) {
|
|
3318
3351
|
if (L && e.value && e.value.id !== L)
|
|
3319
3352
|
return {
|
|
3320
|
-
type:
|
|
3353
|
+
type: C.CHART,
|
|
3321
3354
|
content: "",
|
|
3322
3355
|
structured_content: { markdown: "", query: "" },
|
|
3323
3356
|
name: `Item ${u}`,
|
|
@@ -3331,7 +3364,7 @@ function zi(e, o, n, l) {
|
|
|
3331
3364
|
};
|
|
3332
3365
|
if (!e.value)
|
|
3333
3366
|
return {
|
|
3334
|
-
type:
|
|
3367
|
+
type: C.CHART,
|
|
3335
3368
|
content: "",
|
|
3336
3369
|
structured_content: { markdown: "", query: "" },
|
|
3337
3370
|
name: `Item ${u}`,
|
|
@@ -3346,7 +3379,7 @@ function zi(e, o, n, l) {
|
|
|
3346
3379
|
const d = e.value.gridItems[u];
|
|
3347
3380
|
if (!d)
|
|
3348
3381
|
return {
|
|
3349
|
-
type:
|
|
3382
|
+
type: C.CHART,
|
|
3350
3383
|
content: "",
|
|
3351
3384
|
structured_content: { markdown: "", query: "" },
|
|
3352
3385
|
name: `Item ${u}`,
|
|
@@ -3359,44 +3392,44 @@ function zi(e, o, n, l) {
|
|
|
3359
3392
|
connectionName: e.value.connection || "",
|
|
3360
3393
|
hasDrilldown: !1
|
|
3361
3394
|
};
|
|
3362
|
-
const
|
|
3363
|
-
let
|
|
3364
|
-
e.value.filter && (
|
|
3365
|
-
(
|
|
3366
|
-
var
|
|
3367
|
-
return
|
|
3395
|
+
const H = d.filters || [];
|
|
3396
|
+
let se = H;
|
|
3397
|
+
e.value.filter && (H.some(
|
|
3398
|
+
(Ne) => {
|
|
3399
|
+
var Pe;
|
|
3400
|
+
return Ne.source === "global" && Ne.value === ((Pe = e.value) == null ? void 0 : Pe.filter);
|
|
3368
3401
|
}
|
|
3369
|
-
) || (
|
|
3370
|
-
function
|
|
3371
|
-
return
|
|
3402
|
+
) || (se = [{ value: e.value.filter, source: "global" }, ...H]));
|
|
3403
|
+
function xe(Ee) {
|
|
3404
|
+
return Ee && typeof Ee == "object" && typeof Ee.markdown == "string" && typeof Ee.query == "string";
|
|
3372
3405
|
}
|
|
3373
|
-
let
|
|
3406
|
+
let He = !1, Qe = xe(d.content) ? d.content : {
|
|
3374
3407
|
markdown: d.type === "markdown" ? d.content : "",
|
|
3375
3408
|
query: d.type !== "markdown" ? d.content : ""
|
|
3376
3409
|
};
|
|
3377
|
-
d.drilldown && (
|
|
3410
|
+
d.drilldown && (He = !0, Qe = xe(d.drilldown) ? d.drilldown : {
|
|
3378
3411
|
markdown: d.type === "markdown" ? d.drilldown : "",
|
|
3379
3412
|
query: d.type !== "markdown" ? d.drilldown : ""
|
|
3380
3413
|
});
|
|
3381
|
-
let
|
|
3382
|
-
return
|
|
3414
|
+
let Be = d.chartConfig;
|
|
3415
|
+
return He && (Be = d.drilldownChartConfig || void 0), {
|
|
3383
3416
|
type: d.type,
|
|
3384
3417
|
// check if it's MarkdownData, and if so, extract markdown
|
|
3385
3418
|
//
|
|
3386
|
-
content:
|
|
3419
|
+
content: xe(d.content) ? d.content.markdown : d.content || "",
|
|
3387
3420
|
// display the drilldown of set
|
|
3388
|
-
structured_content:
|
|
3421
|
+
structured_content: Qe,
|
|
3389
3422
|
name: d.name,
|
|
3390
3423
|
allowCrossFilter: d.allowCrossFilter !== !1,
|
|
3391
3424
|
// Default to true if not explicitly false
|
|
3392
3425
|
width: d.width || 0,
|
|
3393
3426
|
height: d.height || 0,
|
|
3394
|
-
chartConfig:
|
|
3395
|
-
filters:
|
|
3427
|
+
chartConfig: Be,
|
|
3428
|
+
filters: se,
|
|
3396
3429
|
chartFilters: d.chartFilters || [],
|
|
3397
3430
|
conceptFilters: d.conceptFilters || [],
|
|
3398
3431
|
parameters: d.parameters || {},
|
|
3399
|
-
onRefresh:
|
|
3432
|
+
onRefresh: oe,
|
|
3400
3433
|
rootContent: g.value,
|
|
3401
3434
|
results: d.results || null,
|
|
3402
3435
|
connectionName: e.value.connection || "",
|
|
@@ -3405,10 +3438,10 @@ function zi(e, o, n, l) {
|
|
|
3405
3438
|
loading: d.loading || !1,
|
|
3406
3439
|
loadStartTime: d.loadStartTime || null,
|
|
3407
3440
|
// Include load start time if available
|
|
3408
|
-
hasDrilldown:
|
|
3441
|
+
hasDrilldown: He
|
|
3409
3442
|
};
|
|
3410
3443
|
}
|
|
3411
|
-
function
|
|
3444
|
+
function A(u, L, d) {
|
|
3412
3445
|
if (!e.value || !e.value.id) return;
|
|
3413
3446
|
if (!L || e.value.id !== L) {
|
|
3414
3447
|
console.warn(
|
|
@@ -3419,16 +3452,16 @@ function zi(e, o, n, l) {
|
|
|
3419
3452
|
);
|
|
3420
3453
|
return;
|
|
3421
3454
|
}
|
|
3422
|
-
const
|
|
3423
|
-
if (d.name && (
|
|
3455
|
+
const H = {};
|
|
3456
|
+
if (d.name && (H.name = d.name), d.chartConfig && (H.chartConfig = d.chartConfig), d.content && (H.content = d.content), d.dimensions && (H.layoutDimensions = {
|
|
3424
3457
|
w: d.dimensions.width,
|
|
3425
3458
|
h: d.dimensions.height
|
|
3426
|
-
}), d.width && d.height && (
|
|
3427
|
-
let
|
|
3428
|
-
|
|
3459
|
+
}), d.width && d.height && (H.width = d.width, H.height = d.height), d.loading !== void 0 && (H.loading = d.loading), d.results !== void 0 && (H.results = d.results), d.error !== void 0 && (H.error = d.error), d.drilldown !== void 0 && (H.drilldown = d.drilldown), d.drilldownChartConfig !== void 0 && (H.drilldownChartConfig = d.drilldownChartConfig), d.allowCrossFilter !== void 0 && (H.allowCrossFilter = d.allowCrossFilter), Object.keys(H).length > 0 && r.updateMultipleItemProperties(e.value.id, u, H), d.content) {
|
|
3460
|
+
let se = N(e.value.id);
|
|
3461
|
+
se == null || se.runSingle(u);
|
|
3429
3462
|
}
|
|
3430
3463
|
}
|
|
3431
|
-
function
|
|
3464
|
+
function N(u) {
|
|
3432
3465
|
if (!e.value || !e.value.id)
|
|
3433
3466
|
throw new Error("Dashboard not found or not initialized");
|
|
3434
3467
|
if (!s) throw new Error("Query execution service not found");
|
|
@@ -3437,45 +3470,49 @@ function zi(e, o, n, l) {
|
|
|
3437
3470
|
queryExecutionService: s,
|
|
3438
3471
|
connectionName: L.connection,
|
|
3439
3472
|
dashboardId: u,
|
|
3440
|
-
getDashboardData: (
|
|
3441
|
-
getItemData:
|
|
3442
|
-
setItemData:
|
|
3473
|
+
getDashboardData: (H) => r.dashboards[H],
|
|
3474
|
+
getItemData: K,
|
|
3475
|
+
setItemData: A
|
|
3443
3476
|
});
|
|
3444
3477
|
return d || console.warn("No query executor found for dashboard:", e.value.id), d;
|
|
3445
3478
|
}
|
|
3446
|
-
function
|
|
3447
|
-
var
|
|
3479
|
+
function ae(u) {
|
|
3480
|
+
var H;
|
|
3448
3481
|
const d = u.target.value;
|
|
3449
|
-
e.value && e.value.id && (r.updateDashboardConnection(e.value.id, d), (
|
|
3482
|
+
e.value && e.value.id && (r.updateDashboardConnection(e.value.id, d), (H = r.getQueryExecutor(e.value.id)) == null || H.setConnection(d));
|
|
3450
3483
|
}
|
|
3451
|
-
function
|
|
3484
|
+
function oe(u) {
|
|
3452
3485
|
var L, d;
|
|
3453
3486
|
if (e.value) {
|
|
3454
3487
|
if (u) {
|
|
3455
|
-
(L = r.getQueryExecutor(e.value.id)) == null || L.runSingle(u),
|
|
3488
|
+
(L = r.getQueryExecutor(e.value.id)) == null || L.runSingle(u), o.dimensionsUpdate(u);
|
|
3456
3489
|
return;
|
|
3457
3490
|
}
|
|
3458
3491
|
(d = r.getQueryExecutor(e.value.id)) == null || d.runBatch(Object.keys(e.value.gridItems));
|
|
3459
3492
|
}
|
|
3460
3493
|
}
|
|
3461
|
-
function
|
|
3462
|
-
var
|
|
3494
|
+
function me(u) {
|
|
3495
|
+
var se;
|
|
3463
3496
|
if (!e.value || !e.value.id) return;
|
|
3464
3497
|
const L = ft(M.value), d = vt(u.filters, L);
|
|
3465
3498
|
if (!d || Object.keys(d).length === 0) {
|
|
3466
|
-
console.log(
|
|
3499
|
+
console.log(
|
|
3500
|
+
"No valid filters to apply from cross-filter event, given ",
|
|
3501
|
+
u.filters,
|
|
3502
|
+
L
|
|
3503
|
+
);
|
|
3467
3504
|
return;
|
|
3468
3505
|
}
|
|
3469
|
-
let
|
|
3506
|
+
let H = r.updateItemCrossFilters(
|
|
3470
3507
|
e.value.id,
|
|
3471
3508
|
u.source,
|
|
3472
3509
|
d,
|
|
3473
3510
|
u.chart,
|
|
3474
3511
|
u.append ? "append" : "add"
|
|
3475
3512
|
);
|
|
3476
|
-
(
|
|
3513
|
+
(se = r.getQueryExecutor(e.value.id)) == null || se.runBatch(H);
|
|
3477
3514
|
}
|
|
3478
|
-
function
|
|
3515
|
+
function Fe(u, L) {
|
|
3479
3516
|
var d;
|
|
3480
3517
|
!e.value || !e.value.id || (r.removeItemCrossFilter(e.value.id, u, L), (d = r.getQueryExecutor(e.value.id)) == null || d.runSingle(u));
|
|
3481
3518
|
}
|
|
@@ -3491,58 +3528,58 @@ function zi(e, o, n, l) {
|
|
|
3491
3528
|
return {
|
|
3492
3529
|
// State
|
|
3493
3530
|
dashboard: e,
|
|
3494
|
-
layout:
|
|
3495
|
-
sortedLayout:
|
|
3531
|
+
layout: O,
|
|
3532
|
+
sortedLayout: W,
|
|
3496
3533
|
editMode: $,
|
|
3497
|
-
selectedConnection:
|
|
3534
|
+
selectedConnection: V,
|
|
3498
3535
|
filter: c,
|
|
3499
3536
|
filterError: v,
|
|
3500
3537
|
globalCompletion: M,
|
|
3501
3538
|
showAddItemModal: k,
|
|
3502
|
-
showQueryEditor:
|
|
3503
|
-
showMarkdownEditor:
|
|
3504
|
-
editingItem:
|
|
3539
|
+
showQueryEditor: I,
|
|
3540
|
+
showMarkdownEditor: x,
|
|
3541
|
+
editingItem: b,
|
|
3505
3542
|
dashboardMaxWidth: T,
|
|
3506
3543
|
rootContent: g,
|
|
3507
3544
|
// Methods
|
|
3508
|
-
handleFilterChange:
|
|
3509
|
-
handleFilterClear:
|
|
3510
|
-
handleImportChange:
|
|
3511
|
-
validateFilter:
|
|
3512
|
-
onConnectionChange:
|
|
3545
|
+
handleFilterChange: m,
|
|
3546
|
+
handleFilterClear: E,
|
|
3547
|
+
handleImportChange: ne,
|
|
3548
|
+
validateFilter: D,
|
|
3549
|
+
onConnectionChange: ae,
|
|
3513
3550
|
toggleMode: U,
|
|
3514
|
-
onLayoutUpdated:
|
|
3515
|
-
openAddItemModal:
|
|
3516
|
-
addItem:
|
|
3517
|
-
clearItems:
|
|
3518
|
-
removeItem:
|
|
3519
|
-
copyItem:
|
|
3520
|
-
closeAddModal:
|
|
3521
|
-
openEditor:
|
|
3522
|
-
saveContent:
|
|
3523
|
-
closeEditors:
|
|
3524
|
-
getDashboardQueryExecutor:
|
|
3525
|
-
getItemData:
|
|
3526
|
-
setItemData:
|
|
3527
|
-
handleRefresh:
|
|
3528
|
-
setCrossFilter:
|
|
3529
|
-
removeFilter:
|
|
3551
|
+
onLayoutUpdated: ke,
|
|
3552
|
+
openAddItemModal: Se,
|
|
3553
|
+
addItem: G,
|
|
3554
|
+
clearItems: le,
|
|
3555
|
+
removeItem: X,
|
|
3556
|
+
copyItem: De,
|
|
3557
|
+
closeAddModal: ye,
|
|
3558
|
+
openEditor: Ae,
|
|
3559
|
+
saveContent: qe,
|
|
3560
|
+
closeEditors: Ie,
|
|
3561
|
+
getDashboardQueryExecutor: N,
|
|
3562
|
+
getItemData: K,
|
|
3563
|
+
setItemData: A,
|
|
3564
|
+
handleRefresh: oe,
|
|
3565
|
+
setCrossFilter: me,
|
|
3566
|
+
removeFilter: Fe,
|
|
3530
3567
|
unSelect: et,
|
|
3531
3568
|
dashboardCreated: tt,
|
|
3532
|
-
updateTitle:
|
|
3569
|
+
updateTitle: re
|
|
3533
3570
|
};
|
|
3534
3571
|
}
|
|
3535
3572
|
export {
|
|
3536
|
-
|
|
3537
|
-
|
|
3573
|
+
_i as C,
|
|
3574
|
+
Wi as D,
|
|
3538
3575
|
Gi as M,
|
|
3539
|
-
|
|
3540
|
-
|
|
3541
|
-
|
|
3542
|
-
|
|
3543
|
-
|
|
3544
|
-
|
|
3545
|
-
$
|
|
3546
|
-
|
|
3547
|
-
|
|
3576
|
+
zi as _,
|
|
3577
|
+
Ui as a,
|
|
3578
|
+
ji as b,
|
|
3579
|
+
Do as c,
|
|
3580
|
+
Ao as d,
|
|
3581
|
+
Uo as e,
|
|
3582
|
+
$o as f,
|
|
3583
|
+
No as g,
|
|
3584
|
+
Ji as u
|
|
3548
3585
|
};
|