@burdenoff/microfe-bigconsole 2026.929.2 → 2026.930.2
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/bigconsole/assistant/assistantRunPersistence.js +111 -0
- package/dist/bigconsole/assistant/assistantRunPersistence.js.map +1 -0
- package/dist/bigconsole/assistant/assistantRunStore.js +87 -48
- package/dist/bigconsole/assistant/assistantRunStore.js.map +1 -1
- package/dist/bigconsole/assistant/previewController.js +19 -50
- package/dist/bigconsole/assistant/previewController.js.map +1 -1
- package/dist/bigconsole/assistant/useAssistantRunWorkspace.js +14 -0
- package/dist/bigconsole/assistant/useAssistantRunWorkspace.js.map +1 -0
- package/dist/bigconsole/components/DrilldownDashboardRenderer.js +74 -50
- package/dist/bigconsole/components/DrilldownDashboardRenderer.js.map +1 -1
- package/dist/bigconsole/components/dashboard/DrilldownBreadcrumb.js +9 -4
- package/dist/bigconsole/components/dashboard/DrilldownBreadcrumb.js.map +1 -1
- package/dist/bigconsole/components/embed/ReadOnlyDashboardRenderer.js +68 -40
- package/dist/bigconsole/components/embed/ReadOnlyDashboardRenderer.js.map +1 -1
- package/dist/bigconsole/components/embed/drilldown.js +26 -0
- package/dist/bigconsole/components/embed/drilldown.js.map +1 -0
- package/dist/bigconsole/components/embed/index.js +4 -3
- package/dist/bigconsole/components/embed/types.js.map +1 -1
- package/dist/bigconsole/components/preview/AiPreviewMiniPanel.js +32 -30
- package/dist/bigconsole/components/preview/AiPreviewMiniPanel.js.map +1 -1
- package/dist/bigconsole/components/preview/AiPreviewPanel.js +38 -36
- package/dist/bigconsole/components/preview/AiPreviewPanel.js.map +1 -1
- package/dist/bigconsole/components/preview/previewShared.js +1 -1
- package/dist/bigconsole/components/preview/previewShared.js.map +1 -1
- package/dist/bigconsole/components/widgets/DrilldownConfigPanel.js +307 -233
- package/dist/bigconsole/components/widgets/DrilldownConfigPanel.js.map +1 -1
- package/dist/bigconsole/components/widgets/PropertiesPanel.js +230 -220
- package/dist/bigconsole/components/widgets/PropertiesPanel.js.map +1 -1
- package/dist/bigconsole/components/widgets/WidgetWrapper.js +18 -19
- package/dist/bigconsole/components/widgets/WidgetWrapper.js.map +1 -1
- package/dist/bigconsole/context/BigConsoleContext.js +4 -1
- package/dist/bigconsole/context/BigConsoleContext.js.map +1 -1
- package/dist/bigconsole/hooks/useActivePage.js +25 -0
- package/dist/bigconsole/hooks/useActivePage.js.map +1 -0
- package/dist/bigconsole/hooks/useDrilldown.js +118 -71
- package/dist/bigconsole/hooks/useDrilldown.js.map +1 -1
- package/dist/bigconsole/hooks/useDrilldownOperations.js +32 -26
- package/dist/bigconsole/hooks/useDrilldownOperations.js.map +1 -1
- package/dist/bigconsole/hooks/useFilterUrlSync.js +1 -1
- package/dist/bigconsole/hooks/useFilterUrlSync.js.map +1 -1
- package/dist/bigconsole/pages/DashboardBuilderPage.js +190 -185
- package/dist/bigconsole/pages/DashboardBuilderPage.js.map +1 -1
- package/dist/bigconsole/pages/DashboardViewPage.js +224 -217
- package/dist/bigconsole/pages/DashboardViewPage.js.map +1 -1
- package/dist/generated/wspace-operations.js +132 -86
- package/dist/generated/wspace-operations.js.map +1 -1
- package/dist/generated/wspace-types.js.map +1 -1
- package/package.json +3 -3
- package/dist/bigconsole/assistant/useAssistantPanelShowsPreview.js +0 -25
- package/dist/bigconsole/assistant/useAssistantPanelShowsPreview.js.map +0 -1
|
@@ -6,64 +6,66 @@ import "../context/index.js";
|
|
|
6
6
|
import { Section as r } from "../components/common/Section.js";
|
|
7
7
|
import "../components/common/index.js";
|
|
8
8
|
import i from "../hooks/useWidgetOperations.js";
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import
|
|
9
|
+
import ee from "../hooks/useDashboardOperations.js";
|
|
10
|
+
import te from "../hooks/useActivePage.js";
|
|
11
|
+
import ne from "../hooks/useFilterUrlSync.js";
|
|
12
|
+
import re from "../hooks/usePageOperations.js";
|
|
12
13
|
import "../hooks/index.js";
|
|
13
|
-
import { BIGCONSOLE_PERMISSIONS as
|
|
14
|
-
import
|
|
15
|
-
import
|
|
16
|
-
import
|
|
17
|
-
import
|
|
18
|
-
import
|
|
14
|
+
import { BIGCONSOLE_PERMISSIONS as a } from "../../constants/permissions.js";
|
|
15
|
+
import ie from "../components/dashboard/DashboardCanvas.js";
|
|
16
|
+
import ae from "../components/dashboard/LiveCanvasToggle.js";
|
|
17
|
+
import o from "../components/dashboard/ExportDashboardDialog.js";
|
|
18
|
+
import oe from "../components/dashboard/DrilldownBreadcrumb.js";
|
|
19
|
+
import se from "../components/dashboard/PublishToStoreDialog.js";
|
|
19
20
|
import "../components/dashboard/index.js";
|
|
20
|
-
import { memo as
|
|
21
|
-
import { useParams as
|
|
22
|
-
import { AccessDenied as
|
|
23
|
-
import { usePermissions as
|
|
24
|
-
import { ArrowLeft as
|
|
25
|
-
import { Button as
|
|
26
|
-
import { Fragment as
|
|
27
|
-
import { useI18n as
|
|
21
|
+
import { memo as s, useCallback as c, useEffect as l, useRef as ce, useState as u } from "react";
|
|
22
|
+
import { useLocation as le, useParams as d } from "react-router";
|
|
23
|
+
import { AccessDenied as f } from "@burdenoff/fe-libs/shared/components";
|
|
24
|
+
import { usePermissions as p } from "@burdenoff/fe-libs/shared/providers/shell";
|
|
25
|
+
import { ArrowLeft as m } from "lucide-react";
|
|
26
|
+
import { Button as h, IllustratedEmptyState as ue } from "@burdenoff/fe-libs/ui";
|
|
27
|
+
import { Fragment as g, jsx as _, jsxs as v } from "react/jsx-runtime";
|
|
28
|
+
import { useI18n as de } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
28
29
|
//#region src/bigconsole/pages/DashboardViewPage.tsx
|
|
29
|
-
var
|
|
30
|
-
let { dashboardId:
|
|
31
|
-
|
|
32
|
-
if (!
|
|
33
|
-
|
|
30
|
+
var y = s(function() {
|
|
31
|
+
let { dashboardId: s } = d(), y = n(), { t: b } = de(), { hasPermission: x, isLoading: fe } = p(), pe = x(a.DASHBOARD_READ), me = x(a.DASHBOARD_UPDATE), he = x(a.DASHBOARD_EXPORT), ge = x(a.DASHBOARD_PUBLISH), [_e, S] = u(!1), [ve, C] = u(!1), [ye, w] = u(!1), [T, be] = u(!1), { isInDrilldown: E, getContextFromUrl: D, getDrilldownMetadata: O } = ne(), k = t((e) => e.currentDashboard), A = t((e) => e.setCurrentDashboard), j = t((e) => e.setGlobalFilterValue), M = t((e) => e.clearAllGlobalFilters), N = e((e) => e.widgets), xe = le(), { activePageId: P, setActivePage: F } = te(k?.id === s ? k?.pages : void 0), I = e((e) => e.clipboardWidgetId), L = e((e) => e.clipboardAction), R = e((e) => e.clearClipboard), z = e((e) => e.selectWidget), { loading: Se, error: B, fetchDashboard: V, updateDashboard: H } = ee(), { createWidget: U, deleteWidget: W, duplicateWidget: G, batchUpdatePositions: K, refetch: q } = i(P || void 0, s), { createPage: J, updatePage: Y, deletePage: X, reorderPages: Z } = re();
|
|
32
|
+
l(() => {
|
|
33
|
+
if (!s) {
|
|
34
|
+
y("/dashboards");
|
|
34
35
|
return;
|
|
35
36
|
}
|
|
36
|
-
return
|
|
37
|
-
e
|
|
37
|
+
return M(), C(!1), V(s).then((e) => {
|
|
38
|
+
e || C(!0);
|
|
38
39
|
}), () => {
|
|
39
|
-
|
|
40
|
+
A(null), M(), C(!1);
|
|
40
41
|
};
|
|
41
42
|
}, [
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
]),
|
|
48
|
-
if (!
|
|
49
|
-
let e =
|
|
43
|
+
s,
|
|
44
|
+
y,
|
|
45
|
+
V,
|
|
46
|
+
A,
|
|
47
|
+
M
|
|
48
|
+
]), l(() => {
|
|
49
|
+
if (!E) return;
|
|
50
|
+
let e = D(), t = O();
|
|
50
51
|
Object.entries(e).forEach(([e, t]) => {
|
|
51
|
-
|
|
52
|
-
}), t.depth > 0 && (
|
|
52
|
+
j(`ctx_${e}`, t);
|
|
53
|
+
}), t.depth > 0 && (j("__drilldown_depth", t.depth), j("__drilldown_parent", t.parent), j("__drilldown_path", t.path)), Object.keys(e).length > 0 && console.debug("[DashboardViewPage] Loaded drilldown context:", {
|
|
53
54
|
context: e,
|
|
54
55
|
metadata: t
|
|
55
56
|
});
|
|
56
57
|
}, [
|
|
58
|
+
E,
|
|
57
59
|
D,
|
|
58
60
|
O,
|
|
59
|
-
|
|
60
|
-
|
|
61
|
+
j,
|
|
62
|
+
xe.search
|
|
61
63
|
]);
|
|
62
|
-
let
|
|
63
|
-
|
|
64
|
-
if (!
|
|
64
|
+
let Q = ce(q);
|
|
65
|
+
Q.current = q, l(() => {
|
|
66
|
+
if (!T || !s) return;
|
|
65
67
|
let e = () => {
|
|
66
|
-
typeof document < "u" && document.visibilityState !== "visible" || t.getState().viewMode !== "edit" && (
|
|
68
|
+
typeof document < "u" && document.visibilityState !== "visible" || t.getState().viewMode !== "edit" && (V(s, { silent: !0 }), Q.current());
|
|
67
69
|
};
|
|
68
70
|
e();
|
|
69
71
|
let n = window.setInterval(e, 3500), r = () => {
|
|
@@ -73,60 +75,60 @@ var v = l(function() {
|
|
|
73
75
|
window.clearInterval(n), document.removeEventListener("visibilitychange", r);
|
|
74
76
|
};
|
|
75
77
|
}, [
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
78
|
+
T,
|
|
79
|
+
s,
|
|
80
|
+
V
|
|
79
81
|
]);
|
|
80
|
-
let
|
|
81
|
-
if (
|
|
82
|
-
|
|
82
|
+
let Ce = c(async () => {
|
|
83
|
+
if (s) {
|
|
84
|
+
S(!0);
|
|
83
85
|
try {
|
|
84
|
-
let e = Array.from(
|
|
85
|
-
e.length > 0 && await
|
|
86
|
+
let e = Array.from(N.values());
|
|
87
|
+
e.length > 0 && await K(e.map((e) => ({
|
|
86
88
|
id: e.id,
|
|
87
89
|
position: e.position
|
|
88
|
-
}))),
|
|
89
|
-
id:
|
|
90
|
-
name:
|
|
91
|
-
description:
|
|
90
|
+
}))), k && await H({
|
|
91
|
+
id: s,
|
|
92
|
+
name: k.name,
|
|
93
|
+
description: k.description
|
|
92
94
|
});
|
|
93
95
|
} catch {} finally {
|
|
94
|
-
|
|
96
|
+
S(!1);
|
|
95
97
|
}
|
|
96
98
|
}
|
|
97
99
|
}, [
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
]),
|
|
104
|
-
|
|
105
|
-
}, [
|
|
106
|
-
|
|
107
|
-
}, []),
|
|
108
|
-
let e =
|
|
109
|
-
if (!
|
|
110
|
-
let t =
|
|
100
|
+
s,
|
|
101
|
+
N,
|
|
102
|
+
k,
|
|
103
|
+
K,
|
|
104
|
+
H
|
|
105
|
+
]), we = c(() => {
|
|
106
|
+
y("/dashboards");
|
|
107
|
+
}, [y]), Te = c((e) => {
|
|
108
|
+
F(e);
|
|
109
|
+
}, [F]), Ee = c(async () => {
|
|
110
|
+
let e = P || k?.pages?.[0]?.id;
|
|
111
|
+
if (!I || !s || !e) return;
|
|
112
|
+
let t = N.get(I);
|
|
111
113
|
if (!t) {
|
|
112
|
-
|
|
114
|
+
R();
|
|
113
115
|
return;
|
|
114
116
|
}
|
|
115
117
|
let n = {
|
|
116
118
|
x: 0,
|
|
117
|
-
y: Array.from(
|
|
119
|
+
y: Array.from(N.values()).reduce((e, t) => {
|
|
118
120
|
let n = (t.positionY ?? 0) + (t.positionHeight ?? 4);
|
|
119
121
|
return Math.max(e, n);
|
|
120
122
|
}, 0),
|
|
121
123
|
width: t.positionWidth ?? 4,
|
|
122
124
|
height: t.positionHeight ?? 4
|
|
123
|
-
}, r =
|
|
125
|
+
}, r = L === "copy" ? b("bigconsole.dashboards.view.widgetCopyTitle", "{{title}} (Copy)", { title: t.title }) : t.title, i = null;
|
|
124
126
|
try {
|
|
125
|
-
i = await
|
|
127
|
+
i = await G(I, n, r);
|
|
126
128
|
} catch {}
|
|
127
|
-
i ||= await
|
|
129
|
+
i ||= await U({
|
|
128
130
|
pageId: e,
|
|
129
|
-
dashboardId:
|
|
131
|
+
dashboardId: s,
|
|
130
132
|
type: t.type,
|
|
131
133
|
title: r,
|
|
132
134
|
description: t.description,
|
|
@@ -138,248 +140,253 @@ var v = l(function() {
|
|
|
138
140
|
position: n,
|
|
139
141
|
refreshInterval: t.refreshInterval ?? void 0,
|
|
140
142
|
metadata: t.metadata
|
|
141
|
-
}), i && (
|
|
143
|
+
}), i && (z(i.id), L === "cut" && await W(I)), R();
|
|
142
144
|
}, [
|
|
143
|
-
F,
|
|
144
145
|
I,
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
A,
|
|
146
|
+
L,
|
|
147
|
+
s,
|
|
148
148
|
P,
|
|
149
|
-
|
|
150
|
-
|
|
149
|
+
k,
|
|
150
|
+
N,
|
|
151
|
+
G,
|
|
151
152
|
U,
|
|
153
|
+
W,
|
|
154
|
+
z,
|
|
152
155
|
R,
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
name: y("bigconsole.dashboards.view.pageName", "Page {{count}}", { count: (A.pages?.length || 0) + 1 })
|
|
156
|
+
b
|
|
157
|
+
]), De = c(() => {
|
|
158
|
+
w(!0);
|
|
159
|
+
}, []), [Oe, $] = u(!1), ke = c(() => {
|
|
160
|
+
$(!0);
|
|
161
|
+
}, []), Ae = c(() => {
|
|
162
|
+
$(!1);
|
|
163
|
+
}, []), je = c(() => {
|
|
164
|
+
w(!1);
|
|
165
|
+
}, []), Me = c(async () => {
|
|
166
|
+
if (!k || !s) return;
|
|
167
|
+
let e = await J({
|
|
168
|
+
dashboardId: s,
|
|
169
|
+
name: b("bigconsole.dashboards.view.pageName", "Page {{count}}", { count: (k.pages?.length || 0) + 1 })
|
|
168
170
|
});
|
|
169
|
-
e && (
|
|
170
|
-
...
|
|
171
|
-
pages: [...
|
|
172
|
-
}),
|
|
171
|
+
e && (A({
|
|
172
|
+
...k,
|
|
173
|
+
pages: [...k.pages || [], e]
|
|
174
|
+
}), F(e.id));
|
|
173
175
|
}, [
|
|
176
|
+
k,
|
|
177
|
+
s,
|
|
174
178
|
A,
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
A && await J({
|
|
179
|
+
J,
|
|
180
|
+
F,
|
|
181
|
+
b
|
|
182
|
+
]), Ne = c(async (e, t) => {
|
|
183
|
+
k && await Y({
|
|
181
184
|
id: e,
|
|
182
185
|
name: t
|
|
183
|
-
}) &&
|
|
184
|
-
...
|
|
185
|
-
pages:
|
|
186
|
+
}) && A({
|
|
187
|
+
...k,
|
|
188
|
+
pages: k.pages?.map((n) => n.id === e ? {
|
|
186
189
|
...n,
|
|
187
190
|
name: t
|
|
188
191
|
} : n)
|
|
189
192
|
});
|
|
190
193
|
}, [
|
|
194
|
+
k,
|
|
191
195
|
A,
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
let t = A.pages?.find((t) => t.id === e);
|
|
196
|
+
Y
|
|
197
|
+
]), Pe = c(async (e) => {
|
|
198
|
+
if (!k || !s) return;
|
|
199
|
+
let t = k.pages?.find((t) => t.id === e);
|
|
197
200
|
if (!t) return;
|
|
198
|
-
let n = await
|
|
199
|
-
dashboardId:
|
|
200
|
-
name:
|
|
201
|
+
let n = await J({
|
|
202
|
+
dashboardId: s,
|
|
203
|
+
name: b("bigconsole.dashboards.view.pageCopyName", "{{name}} (Copy)", { name: t.name ?? "" })
|
|
201
204
|
});
|
|
202
|
-
n && (
|
|
203
|
-
...
|
|
204
|
-
pages: [...
|
|
205
|
-
}),
|
|
205
|
+
n && (A({
|
|
206
|
+
...k,
|
|
207
|
+
pages: [...k.pages || [], n]
|
|
208
|
+
}), F(n.id));
|
|
206
209
|
}, [
|
|
210
|
+
k,
|
|
211
|
+
s,
|
|
207
212
|
A,
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
let t = A.pages?.filter((t) => t.id !== e).map((e, t) => ({
|
|
213
|
+
J,
|
|
214
|
+
F,
|
|
215
|
+
b
|
|
216
|
+
]), Fe = c(async (e) => {
|
|
217
|
+
if (!(!k || (k.pages?.length || 0) <= 1) && await X(e)) {
|
|
218
|
+
let t = k.pages?.filter((t) => t.id !== e).map((e, t) => ({
|
|
215
219
|
...e,
|
|
216
220
|
order: t
|
|
217
221
|
}));
|
|
218
|
-
|
|
219
|
-
...
|
|
222
|
+
A({
|
|
223
|
+
...k,
|
|
220
224
|
pages: t
|
|
221
|
-
})
|
|
225
|
+
});
|
|
226
|
+
let n = t?.[0]?.id;
|
|
227
|
+
P === e && n && F(n, { replace: !0 });
|
|
222
228
|
}
|
|
223
229
|
}, [
|
|
230
|
+
k,
|
|
224
231
|
A,
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
]),
|
|
229
|
-
!
|
|
230
|
-
...
|
|
232
|
+
P,
|
|
233
|
+
X,
|
|
234
|
+
F
|
|
235
|
+
]), Ie = c(async (e) => {
|
|
236
|
+
!k || !s || (A({
|
|
237
|
+
...k,
|
|
231
238
|
pages: e.map((e, t) => ({
|
|
232
239
|
...e,
|
|
233
240
|
order: t
|
|
234
241
|
}))
|
|
235
|
-
}), await
|
|
242
|
+
}), await Z(s, e.map((e) => e.id)));
|
|
236
243
|
}, [
|
|
244
|
+
k,
|
|
245
|
+
s,
|
|
237
246
|
A,
|
|
238
|
-
|
|
239
|
-
j,
|
|
240
|
-
X
|
|
247
|
+
Z
|
|
241
248
|
]);
|
|
242
|
-
return
|
|
249
|
+
return fe ? /* @__PURE__ */ _("div", {
|
|
243
250
|
className: "flex items-center justify-center h-full",
|
|
244
|
-
children: /* @__PURE__ */
|
|
245
|
-
}) :
|
|
251
|
+
children: /* @__PURE__ */ _("div", { className: "animate-spin w-8 h-8 border-4 border-action-primary-bg border-t-transparent rounded-full" })
|
|
252
|
+
}) : pe ? B ? /* @__PURE__ */ _("div", {
|
|
246
253
|
className: "flex h-full flex-col items-center justify-center",
|
|
247
254
|
style: { padding: "var(--space-pagePadding)" },
|
|
248
|
-
children: /* @__PURE__ */
|
|
255
|
+
children: /* @__PURE__ */ _(r, {
|
|
249
256
|
headingLevel: 2,
|
|
250
257
|
tone: "danger",
|
|
251
|
-
title:
|
|
252
|
-
description: /* @__PURE__ */
|
|
258
|
+
title: b("bigconsole.dashboards.view.errorTitle", "Error loading dashboard"),
|
|
259
|
+
description: /* @__PURE__ */ _("span", {
|
|
253
260
|
className: "break-words",
|
|
254
|
-
children:
|
|
261
|
+
children: B.message
|
|
255
262
|
}),
|
|
256
263
|
className: "w-full max-w-md",
|
|
257
264
|
"data-testid": "dashboard-view-error",
|
|
258
|
-
actions: /* @__PURE__ */
|
|
265
|
+
actions: /* @__PURE__ */ v(g, { children: [/* @__PURE__ */ _(h, {
|
|
259
266
|
size: "sm",
|
|
260
|
-
onClick: () =>
|
|
261
|
-
children:
|
|
262
|
-
}), /* @__PURE__ */
|
|
267
|
+
onClick: () => V(s),
|
|
268
|
+
children: b("bigconsole.dashboards.view.retry", "Retry")
|
|
269
|
+
}), /* @__PURE__ */ _(h, {
|
|
263
270
|
size: "sm",
|
|
264
271
|
variant: "outline",
|
|
265
|
-
onClick: () =>
|
|
266
|
-
children:
|
|
272
|
+
onClick: () => y("/dashboards"),
|
|
273
|
+
children: b("bigconsole.dashboards.view.backToDashboards", "Back to Dashboards")
|
|
267
274
|
})] })
|
|
268
275
|
})
|
|
269
|
-
}) :
|
|
276
|
+
}) : ve ? /* @__PURE__ */ _("div", {
|
|
270
277
|
className: "flex flex-col items-center justify-center h-full",
|
|
271
278
|
style: { padding: "var(--space-pagePadding)" },
|
|
272
|
-
children: /* @__PURE__ */
|
|
279
|
+
children: /* @__PURE__ */ _(ue, {
|
|
273
280
|
illustration: "empty-data",
|
|
274
|
-
title:
|
|
275
|
-
description: /* @__PURE__ */
|
|
281
|
+
title: b("bigconsole.dashboards.view.notFoundTitle", "Dashboard not found"),
|
|
282
|
+
description: /* @__PURE__ */ v(g, { children: [b("bigconsole.dashboards.view.notFoundDescription", "The dashboard you're looking for doesn't exist or has been deleted."), /* @__PURE__ */ _("span", {
|
|
276
283
|
className: "mt-2 block font-mono text-xs text-text-muted break-all",
|
|
277
|
-
children:
|
|
284
|
+
children: b("bigconsole.dashboards.view.idLabel", "ID: {{id}}", { id: s ?? "" })
|
|
278
285
|
})] }),
|
|
279
|
-
action: /* @__PURE__ */
|
|
280
|
-
onClick: () =>
|
|
281
|
-
children:
|
|
286
|
+
action: /* @__PURE__ */ _(h, {
|
|
287
|
+
onClick: () => y("/dashboards"),
|
|
288
|
+
children: b("bigconsole.dashboards.view.backToDashboards", "Back to Dashboards")
|
|
282
289
|
})
|
|
283
290
|
})
|
|
284
|
-
}) :
|
|
291
|
+
}) : Se || !k ? /* @__PURE__ */ _("div", {
|
|
285
292
|
className: "flex items-center justify-center h-full",
|
|
286
293
|
role: "status",
|
|
287
294
|
"aria-live": "polite",
|
|
288
|
-
children: /* @__PURE__ */
|
|
295
|
+
children: /* @__PURE__ */ v("div", {
|
|
289
296
|
className: "flex flex-col items-center gap-4",
|
|
290
|
-
children: [/* @__PURE__ */
|
|
297
|
+
children: [/* @__PURE__ */ _("div", { className: "animate-spin w-8 h-8 border-4 border-action-primary-bg border-t-transparent rounded-full" }), /* @__PURE__ */ _("p", {
|
|
291
298
|
className: "text-sm text-text-secondary",
|
|
292
|
-
children:
|
|
299
|
+
children: b("bigconsole.dashboards.view.loading", "Loading dashboard...")
|
|
293
300
|
})]
|
|
294
301
|
})
|
|
295
|
-
}) : /* @__PURE__ */
|
|
302
|
+
}) : /* @__PURE__ */ v("div", {
|
|
296
303
|
className: "h-full flex flex-col overflow-hidden",
|
|
297
304
|
children: [
|
|
298
|
-
/* @__PURE__ */
|
|
305
|
+
/* @__PURE__ */ _(r, {
|
|
299
306
|
emphasis: "bare",
|
|
300
307
|
padding: "none",
|
|
301
308
|
"data-testid": "dashboard-route-header",
|
|
302
309
|
"aria-label": "Dashboard",
|
|
303
310
|
className: "flex-shrink-0 border-b border-[var(--color-border-subtle)] bg-bg-surface px-3 py-2",
|
|
304
311
|
headerClassName: "",
|
|
305
|
-
header: /* @__PURE__ */
|
|
312
|
+
header: /* @__PURE__ */ v("div", {
|
|
306
313
|
className: "flex flex-wrap items-center gap-control-gap",
|
|
307
314
|
children: [
|
|
308
|
-
/* @__PURE__ */
|
|
309
|
-
onClick:
|
|
315
|
+
/* @__PURE__ */ v(h, {
|
|
316
|
+
onClick: we,
|
|
310
317
|
variant: "ghost",
|
|
311
318
|
size: "sm",
|
|
312
|
-
title:
|
|
313
|
-
"aria-label":
|
|
319
|
+
title: b("bigconsole.dashboards.view.backToDashboards", "Back to Dashboards"),
|
|
320
|
+
"aria-label": b("bigconsole.dashboards.view.backToDashboards", "Back to Dashboards"),
|
|
314
321
|
className: "flex-shrink-0",
|
|
315
|
-
children: [/* @__PURE__ */
|
|
322
|
+
children: [/* @__PURE__ */ _(m, { className: "w-4 h-4 mr-2" }), b("bigconsole.dashboards.view.back", "Back")]
|
|
316
323
|
}),
|
|
317
|
-
/* @__PURE__ */
|
|
324
|
+
/* @__PURE__ */ _("h1", {
|
|
318
325
|
className: "min-w-0 flex-1 truncate text-sm font-semibold text-text-primary",
|
|
319
|
-
title:
|
|
320
|
-
children:
|
|
326
|
+
title: k.name,
|
|
327
|
+
children: k.name
|
|
321
328
|
}),
|
|
322
|
-
/* @__PURE__ */
|
|
329
|
+
/* @__PURE__ */ _("div", {
|
|
323
330
|
className: "flex-shrink-0",
|
|
324
|
-
children: /* @__PURE__ */
|
|
325
|
-
isLive:
|
|
326
|
-
onToggle: () =>
|
|
331
|
+
children: /* @__PURE__ */ _(ae, {
|
|
332
|
+
isLive: T,
|
|
333
|
+
onToggle: () => be((e) => !e)
|
|
327
334
|
})
|
|
328
335
|
})
|
|
329
336
|
]
|
|
330
337
|
})
|
|
331
338
|
}),
|
|
332
|
-
|
|
333
|
-
currentDashboardId:
|
|
334
|
-
currentDashboardName:
|
|
339
|
+
E && /* @__PURE__ */ _(oe, {
|
|
340
|
+
currentDashboardId: k.id,
|
|
341
|
+
currentDashboardName: k.name,
|
|
335
342
|
basePath: "/bigconsole/dashboards"
|
|
336
343
|
}),
|
|
337
|
-
/* @__PURE__ */
|
|
344
|
+
/* @__PURE__ */ _("div", {
|
|
338
345
|
className: "flex-1 min-w-0 overflow-hidden",
|
|
339
|
-
children: /* @__PURE__ */
|
|
340
|
-
dashboardId:
|
|
341
|
-
pageId:
|
|
342
|
-
title:
|
|
343
|
-
onPaste:
|
|
344
|
-
onSave:
|
|
345
|
-
isSaving:
|
|
346
|
-
onExport:
|
|
347
|
-
onPublishTemplate:
|
|
348
|
-
pages: (
|
|
346
|
+
children: /* @__PURE__ */ _(ie, {
|
|
347
|
+
dashboardId: k.id,
|
|
348
|
+
pageId: P || k.pages?.[0]?.id,
|
|
349
|
+
title: k.name,
|
|
350
|
+
onPaste: Ee,
|
|
351
|
+
onSave: me ? Ce : void 0,
|
|
352
|
+
isSaving: _e,
|
|
353
|
+
onExport: he ? De : void 0,
|
|
354
|
+
onPublishTemplate: ge ? ke : void 0,
|
|
355
|
+
pages: (k.pages || []).map((e, t) => ({
|
|
349
356
|
id: e.id,
|
|
350
|
-
name: e.name ||
|
|
357
|
+
name: e.name || b("bigconsole.dashboards.view.pageName", "Page {{count}}", { count: t + 1 }),
|
|
351
358
|
order: e.order ?? 0
|
|
352
359
|
})),
|
|
353
|
-
activePageId:
|
|
354
|
-
onPageChange:
|
|
355
|
-
onPageAdd:
|
|
356
|
-
onPageRename:
|
|
357
|
-
onPageDuplicate:
|
|
358
|
-
onPageDelete:
|
|
359
|
-
onPagesReorder:
|
|
360
|
+
activePageId: P || k.pages?.[0]?.id,
|
|
361
|
+
onPageChange: Te,
|
|
362
|
+
onPageAdd: Me,
|
|
363
|
+
onPageRename: Ne,
|
|
364
|
+
onPageDuplicate: Pe,
|
|
365
|
+
onPageDelete: Fe,
|
|
366
|
+
onPagesReorder: Ie,
|
|
360
367
|
showPageTabs: !0
|
|
361
368
|
})
|
|
362
369
|
}),
|
|
363
|
-
/* @__PURE__ */
|
|
364
|
-
isOpen:
|
|
365
|
-
dashboardId:
|
|
366
|
-
dashboardName:
|
|
367
|
-
onClose:
|
|
370
|
+
/* @__PURE__ */ _(o, {
|
|
371
|
+
isOpen: ye,
|
|
372
|
+
dashboardId: k.id,
|
|
373
|
+
dashboardName: k.name,
|
|
374
|
+
onClose: je
|
|
368
375
|
}),
|
|
369
|
-
/* @__PURE__ */
|
|
370
|
-
isOpen:
|
|
371
|
-
dashboardId:
|
|
372
|
-
dashboardName:
|
|
373
|
-
dashboardDescription:
|
|
374
|
-
onClose:
|
|
376
|
+
/* @__PURE__ */ _(se, {
|
|
377
|
+
isOpen: Oe,
|
|
378
|
+
dashboardId: k.id,
|
|
379
|
+
dashboardName: k.name,
|
|
380
|
+
dashboardDescription: k.description,
|
|
381
|
+
onClose: Ae
|
|
375
382
|
})
|
|
376
383
|
]
|
|
377
|
-
}) : /* @__PURE__ */
|
|
378
|
-
title:
|
|
379
|
-
description:
|
|
384
|
+
}) : /* @__PURE__ */ _(f, {
|
|
385
|
+
title: b("bigconsole.dashboards.view.accessDeniedTitle", "Access Denied"),
|
|
386
|
+
description: b("bigconsole.dashboards.view.accessDeniedDescription", "You don't have permission to view this dashboard.")
|
|
380
387
|
});
|
|
381
388
|
});
|
|
382
389
|
//#endregion
|
|
383
|
-
export {
|
|
390
|
+
export { y as DashboardViewPage, y as default };
|
|
384
391
|
|
|
385
392
|
//# sourceMappingURL=DashboardViewPage.js.map
|