@burdenoff/microfe-bigconsole 2026.1118.1 → 2026.1118.3
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/components/reconcile/reconcileAgentTool.d.ts +139 -0
- package/dist/bigconsole/components/reconcile/reconcileAgentTool.js +135 -0
- package/dist/bigconsole/components/reconcile/reconcileModel.d.ts +18 -3
- package/dist/bigconsole/components/reconcile/reconcileModel.js +69 -61
- package/dist/bigconsole/components/reconcile/useReconcileAgentTool.d.ts +10 -0
- package/dist/bigconsole/components/reconcile/useReconcileAgentTool.js +136 -0
- package/dist/bigconsole/pages/DashboardViewPage.js +231 -230
- package/dist/bigconsole/proactive/actions.js +10 -10
- package/dist/node_modules/zod/v4/classic/schemas.js +301 -229
- package/dist/node_modules/zod/v4/core/api.js +168 -106
- package/dist/node_modules/zod/v4/core/checks.js +145 -43
- package/dist/node_modules/zod/v4/core/json-schema-processors.js +36 -26
- package/dist/node_modules/zod/v4/core/regexes.js +2 -2
- package/dist/node_modules/zod/v4/core/schemas.js +172 -154
- package/dist/node_modules/zod/v4/core/util.js +94 -90
- package/package.json +4 -4
|
@@ -5,40 +5,41 @@ import "../context/index.js";
|
|
|
5
5
|
import { useBigConsoleBasePath as r, useBigConsoleNavigate as i } from "../context/BigConsoleContext.js";
|
|
6
6
|
import "../components/dashboard/index.js";
|
|
7
7
|
import { Section as a } from "../components/common/Section.js";
|
|
8
|
+
import { useReconcileAgentTool as o } from "../components/reconcile/useReconcileAgentTool.js";
|
|
9
|
+
import s from "../hooks/useWidgetOperations.js";
|
|
10
|
+
import ee from "../hooks/useDashboardOperations.js";
|
|
8
11
|
import "../components/common/index.js";
|
|
9
|
-
import o from "../hooks/useWidgetOperations.js";
|
|
10
|
-
import s from "../hooks/useDashboardOperations.js";
|
|
11
12
|
import "../components/narrative/index.js";
|
|
13
|
+
import te from "../hooks/usePageOperations.js";
|
|
12
14
|
import "../store/index.js";
|
|
13
|
-
import ee from "../hooks/usePageOperations.js";
|
|
14
15
|
import "../hooks/index.js";
|
|
15
|
-
import
|
|
16
|
-
import
|
|
17
|
-
import { dashboardPageTabs as ie } from "../assistant/pageControls.js";
|
|
16
|
+
import ne, { parseUrlToGlobalFilterValues as re } from "../hooks/useFilterUrlSync.js";
|
|
17
|
+
import ie from "../hooks/useActivePage.js";
|
|
18
18
|
import { DashboardCanvas as ae } from "../components/dashboard/DashboardCanvas.js";
|
|
19
|
-
import {
|
|
19
|
+
import { dashboardPageTabs as oe } from "../assistant/pageControls.js";
|
|
20
20
|
import { LiveCanvasToggle as se } from "../components/dashboard/LiveCanvasToggle.js";
|
|
21
21
|
import { ExportDashboardDialog as ce } from "../components/dashboard/ExportDashboardDialog.js";
|
|
22
22
|
import { DrilldownBreadcrumb as le } from "../components/dashboard/DrilldownBreadcrumb.js";
|
|
23
23
|
import { PublishToStoreDialog as ue } from "../components/dashboard/PublishToStoreDialog.js";
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
26
|
-
import {
|
|
27
|
-
import {
|
|
28
|
-
import {
|
|
29
|
-
import {
|
|
24
|
+
import { loadBigConsoleSettings as de } from "../hooks/useBigConsoleSettings.js";
|
|
25
|
+
import { LIVE_STRUCTURE_POLL_MS as fe, isLiveDataRefreshDue as pe } from "../utils/liveBoardRefresh.js";
|
|
26
|
+
import { registerBreadcrumbName as me, unregisterBreadcrumbName as he } from "../utils/breadcrumbRegistry.js";
|
|
27
|
+
import { DigestPanel as ge } from "../components/narrative/DigestPanel.js";
|
|
28
|
+
import { GetWidgetDocument as _e } from "../../generated/wspace-operations.js";
|
|
29
|
+
import { dashboardSuggestAnchorProps as ve } from "../proactive/entities.js";
|
|
30
|
+
import { memo as c, useCallback as l, useEffect as u, useMemo as d, useRef as ye, useState as f } from "react";
|
|
30
31
|
import { useLocation as be, useParams as xe } from "react-router";
|
|
31
32
|
import { AccessDenied as Se } from "@burdenoff/fe-libs/shared/components";
|
|
32
33
|
import { usePermissions as Ce } from "@burdenoff/fe-libs/shared/providers/shell";
|
|
33
34
|
import { ArrowLeft as we, Sparkles as Te } from "lucide-react";
|
|
34
|
-
import { Button as
|
|
35
|
+
import { Button as p, IllustratedEmptyState as Ee } from "@burdenoff/fe-libs/ui";
|
|
35
36
|
import { useI18n as De } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
36
37
|
import { useApolloClient as Oe } from "@apollo/client/react";
|
|
37
|
-
import { Fragment as
|
|
38
|
+
import { Fragment as m, jsx as h, jsxs as g } from "react/jsx-runtime";
|
|
38
39
|
import { useAssistantPageControls as ke } from "@burdenoff/fe-libs/shared/assistant/appControls/useAssistantControl";
|
|
39
40
|
// src/bigconsole/pages/DashboardViewPage.tsx
|
|
40
|
-
var
|
|
41
|
-
let { dashboardId: c } = xe(),
|
|
41
|
+
var _ = c(function() {
|
|
42
|
+
let { dashboardId: c } = xe(), _ = i(), Ae = r(), { t: v } = De(), y = Oe(), { hasPermission: b, isLoading: x } = Ce(), S = b(n.DASHBOARD_READ), je = b(n.DASHBOARD_UPDATE), Me = b(n.DASHBOARD_EXPORT), Ne = b(n.DASHBOARD_PUBLISH), [Pe, Fe] = f(!1), [C, w] = f(!1), [Ie, T] = f(!1), [E, Le] = f(!1), [D, Re] = f(!1), { isInDrilldown: O, getContextFromUrl: ze, getDrilldownMetadata: Be } = ne(), k = t((e) => e.currentDashboard), A = t((e) => e.setCurrentDashboard), j = t((e) => e.setGlobalFilterValue), M = t((e) => e.clearAllGlobalFilters), N = t((e) => e.setGlobalFilterValues), P = e((e) => e.widgets), Ve = be(), { activePageId: F, setActivePage: I } = ie(k?.id === c ? k?.pages : void 0), L = e((e) => e.clipboardWidgetId), R = e((e) => e.clipboardAction), z = e((e) => e.clearClipboard), B = e((e) => e.selectWidget), { loading: V, error: H, fetchDashboard: U, updateDashboard: W } = ee(), { createWidget: G, deleteWidget: K, duplicateWidget: q, batchUpdatePositions: J, refetch: He } = s(F || void 0, c), { createPage: Y, updatePage: Ue, deletePage: We, duplicatePage: Ge, reorderPages: Ke } = te(), qe = l((e) => {
|
|
42
43
|
let t = e?.parentElement;
|
|
43
44
|
if (!e || !t) return;
|
|
44
45
|
let n = t;
|
|
@@ -58,97 +59,97 @@ var g = c(function() {
|
|
|
58
59
|
};
|
|
59
60
|
}, []);
|
|
60
61
|
u(() => {
|
|
61
|
-
if (!c)
|
|
62
|
-
else return
|
|
63
|
-
e ||
|
|
62
|
+
if (!c) _("/dashboards");
|
|
63
|
+
else return N(re(window.location.search, "filter_")), w(!1), U(c).then((e) => {
|
|
64
|
+
e || w(!0);
|
|
64
65
|
}), () => {
|
|
65
|
-
|
|
66
|
+
A(null), M(), w(!1);
|
|
66
67
|
};
|
|
67
68
|
}, [
|
|
68
69
|
c,
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
70
|
+
_,
|
|
71
|
+
U,
|
|
72
|
+
A,
|
|
73
|
+
M,
|
|
74
|
+
N
|
|
74
75
|
]), u(() => {
|
|
75
|
-
if (!
|
|
76
|
-
let e =
|
|
76
|
+
if (!O) return;
|
|
77
|
+
let e = ze(), t = Be();
|
|
77
78
|
Object.entries(e).forEach(([e, t]) => {
|
|
78
|
-
|
|
79
|
-
}), t.depth > 0 && (
|
|
79
|
+
j(`ctx_${e}`, t);
|
|
80
|
+
}), t.depth > 0 && (j("__drilldown_depth", t.depth), j("__drilldown_parent", t.parent), j("__drilldown_path", t.path)), Object.keys(e).length;
|
|
80
81
|
}, [
|
|
81
|
-
|
|
82
|
+
O,
|
|
83
|
+
ze,
|
|
82
84
|
Be,
|
|
83
|
-
|
|
84
|
-
A,
|
|
85
|
+
j,
|
|
85
86
|
Ve.search
|
|
86
87
|
]);
|
|
87
|
-
let
|
|
88
|
-
|
|
89
|
-
if (!
|
|
88
|
+
let Je = ye(He);
|
|
89
|
+
Je.current = He, u(() => {
|
|
90
|
+
if (!E || !c) return;
|
|
90
91
|
let e = null, n = () => {
|
|
91
92
|
if (typeof document < "u" && document.visibilityState !== "visible" || t.getState().viewMode === "edit") return;
|
|
92
|
-
|
|
93
|
+
U(c, { silent: !0 }), Je.current();
|
|
93
94
|
let n = Date.now();
|
|
94
|
-
|
|
95
|
+
pe(e, n) && (e = n, y.refetchQueries({ include: [_e] }).catch((e) => {
|
|
95
96
|
console.warn("[DashboardViewPage] Live widget data refresh failed", e);
|
|
96
97
|
}));
|
|
97
98
|
};
|
|
98
99
|
n();
|
|
99
|
-
let r = window.setInterval(n,
|
|
100
|
+
let r = window.setInterval(n, fe), i = () => {
|
|
100
101
|
document.visibilityState === "visible" && (e = null, n());
|
|
101
102
|
};
|
|
102
103
|
return document.addEventListener("visibilitychange", i), () => {
|
|
103
104
|
window.clearInterval(r), document.removeEventListener("visibilitychange", i);
|
|
104
105
|
};
|
|
105
106
|
}, [
|
|
106
|
-
|
|
107
|
+
E,
|
|
107
108
|
c,
|
|
108
|
-
|
|
109
|
-
|
|
109
|
+
U,
|
|
110
|
+
y
|
|
110
111
|
]);
|
|
111
|
-
let
|
|
112
|
+
let Ye = l(async () => {
|
|
112
113
|
if (c) {
|
|
113
|
-
|
|
114
|
+
Fe(!0);
|
|
114
115
|
try {
|
|
115
|
-
let e = Array.from(
|
|
116
|
+
let e = Array.from(P.values());
|
|
116
117
|
if (e.length > 0) {
|
|
117
118
|
let t = e.map((e) => ({
|
|
118
119
|
id: e.id,
|
|
119
120
|
position: e.position
|
|
120
121
|
}));
|
|
121
|
-
await
|
|
122
|
+
await J(t);
|
|
122
123
|
}
|
|
123
|
-
|
|
124
|
+
k && await W({
|
|
124
125
|
id: c,
|
|
125
|
-
name:
|
|
126
|
-
description:
|
|
126
|
+
name: k.name,
|
|
127
|
+
description: k.description
|
|
127
128
|
});
|
|
128
129
|
} catch {} finally {
|
|
129
|
-
|
|
130
|
+
Fe(!1);
|
|
130
131
|
}
|
|
131
132
|
}
|
|
132
133
|
}, [
|
|
133
134
|
c,
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
]),
|
|
139
|
-
|
|
140
|
-
}, [
|
|
141
|
-
|
|
142
|
-
}, [
|
|
135
|
+
P,
|
|
136
|
+
k,
|
|
137
|
+
J,
|
|
138
|
+
W
|
|
139
|
+
]), Xe = l(() => {
|
|
140
|
+
_("/dashboards");
|
|
141
|
+
}, [_]), X = l((e) => {
|
|
142
|
+
I(e);
|
|
143
|
+
}, [I]), Z = d(() => (k?.pages || []).map((e, t) => ({
|
|
143
144
|
id: e.id,
|
|
144
|
-
name: e.name ||
|
|
145
|
+
name: e.name || v("bigconsole.dashboards.view.pageName", "Page {{count}}", { count: t + 1 }),
|
|
145
146
|
order: e.order ?? 0
|
|
146
|
-
})), [
|
|
147
|
+
})), [k?.pages, v]), Q = k && k.id === c ? k.name : null, $ = F || k?.pages?.[0]?.id || null;
|
|
147
148
|
u(() => {
|
|
148
|
-
if (c && Q) return
|
|
149
|
+
if (c && Q) return me(c, Q), () => he(c);
|
|
149
150
|
}, [c, Q]);
|
|
150
|
-
let
|
|
151
|
-
dashboardName: Q ||
|
|
151
|
+
let Ze = d(() => !x && S && !H && !C && !V && Q !== null ? oe({
|
|
152
|
+
dashboardName: Q || v("bigconsole.dashboards.title", "Dashboards"),
|
|
152
153
|
tabs: Z.map((e) => ({
|
|
153
154
|
id: e.id,
|
|
154
155
|
label: e.name
|
|
@@ -156,39 +157,39 @@ var g = c(function() {
|
|
|
156
157
|
current: $,
|
|
157
158
|
select: X
|
|
158
159
|
}) : null, [
|
|
159
|
-
|
|
160
|
-
b,
|
|
161
|
-
V,
|
|
160
|
+
x,
|
|
162
161
|
S,
|
|
163
|
-
|
|
162
|
+
H,
|
|
163
|
+
C,
|
|
164
|
+
V,
|
|
164
165
|
Q,
|
|
165
166
|
Z,
|
|
166
167
|
$,
|
|
167
168
|
X,
|
|
168
|
-
|
|
169
|
+
v
|
|
169
170
|
]);
|
|
170
|
-
ke(
|
|
171
|
-
let
|
|
172
|
-
let e =
|
|
173
|
-
if (!
|
|
174
|
-
let t =
|
|
171
|
+
ke(Ze), o();
|
|
172
|
+
let Qe = l(async () => {
|
|
173
|
+
let e = F || k?.pages?.[0]?.id;
|
|
174
|
+
if (!L || !c || !e) return;
|
|
175
|
+
let t = P.get(L);
|
|
175
176
|
if (!t) {
|
|
176
|
-
|
|
177
|
+
z();
|
|
177
178
|
return;
|
|
178
179
|
}
|
|
179
180
|
let n = {
|
|
180
181
|
x: 0,
|
|
181
|
-
y: Array.from(
|
|
182
|
+
y: Array.from(P.values()).reduce((e, t) => {
|
|
182
183
|
let n = (t.positionY ?? 0) + (t.positionHeight ?? 4);
|
|
183
184
|
return Math.max(e, n);
|
|
184
185
|
}, 0),
|
|
185
|
-
width: Math.min(t.positionWidth ?? 4,
|
|
186
|
+
width: Math.min(t.positionWidth ?? 4, k?.pages.find((t) => t.id === e)?.gridColumns ?? 12),
|
|
186
187
|
height: t.positionHeight ?? 4
|
|
187
|
-
}, r =
|
|
188
|
+
}, r = R === "copy" ? v("bigconsole.dashboards.view.widgetCopyTitle", "{{title}} (Copy)", { title: t.title }) : t.title, i = null;
|
|
188
189
|
try {
|
|
189
|
-
i = await
|
|
190
|
+
i = await q(L, n, r);
|
|
190
191
|
} catch {}
|
|
191
|
-
i ||= await
|
|
192
|
+
i ||= await G({
|
|
192
193
|
pageId: e,
|
|
193
194
|
dashboardId: c,
|
|
194
195
|
type: t.type,
|
|
@@ -202,271 +203,271 @@ var g = c(function() {
|
|
|
202
203
|
position: n,
|
|
203
204
|
refreshInterval: t.refreshInterval ?? void 0,
|
|
204
205
|
metadata: t.metadata
|
|
205
|
-
}), i && (
|
|
206
|
+
}), i && (B(i.id), R === "cut" && await K(L)), z();
|
|
206
207
|
}, [
|
|
207
|
-
I,
|
|
208
208
|
L,
|
|
209
|
+
R,
|
|
209
210
|
c,
|
|
211
|
+
F,
|
|
212
|
+
k,
|
|
210
213
|
P,
|
|
211
|
-
|
|
212
|
-
N,
|
|
213
|
-
K,
|
|
214
|
-
W,
|
|
214
|
+
q,
|
|
215
215
|
G,
|
|
216
|
+
K,
|
|
217
|
+
B,
|
|
216
218
|
z,
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
et(!0);
|
|
223
|
-
}, []), nt = l(() => {
|
|
224
|
-
et(!1);
|
|
219
|
+
v
|
|
220
|
+
]), $e = l(() => {
|
|
221
|
+
T(!0);
|
|
222
|
+
}, []), [et, tt] = f(!1), nt = l(() => {
|
|
223
|
+
tt(!0);
|
|
225
224
|
}, []), rt = l(() => {
|
|
226
|
-
|
|
227
|
-
}, []), it = l(
|
|
228
|
-
|
|
229
|
-
|
|
225
|
+
tt(!1);
|
|
226
|
+
}, []), it = l(() => {
|
|
227
|
+
T(!1);
|
|
228
|
+
}, []), at = l(async () => {
|
|
229
|
+
if (!k || !c) return;
|
|
230
|
+
let e = (k.pages?.length || 0) + 1, t = v("bigconsole.dashboards.view.pageName", "Page {{count}}", { count: e }), n = await Y({
|
|
230
231
|
dashboardId: c,
|
|
231
232
|
name: t,
|
|
232
|
-
gridColumns:
|
|
233
|
+
gridColumns: de().defaultGridColumns
|
|
233
234
|
});
|
|
234
|
-
n && (
|
|
235
|
-
...
|
|
236
|
-
pages: [...
|
|
237
|
-
}),
|
|
235
|
+
n && (A({
|
|
236
|
+
...k,
|
|
237
|
+
pages: [...k.pages || [], n]
|
|
238
|
+
}), I(n.id));
|
|
238
239
|
}, [
|
|
239
|
-
O,
|
|
240
|
-
c,
|
|
241
240
|
k,
|
|
241
|
+
c,
|
|
242
|
+
A,
|
|
242
243
|
Y,
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
]),
|
|
246
|
-
|
|
244
|
+
I,
|
|
245
|
+
v
|
|
246
|
+
]), ot = l(async (e, t) => {
|
|
247
|
+
k && await Ue({
|
|
247
248
|
id: e,
|
|
248
249
|
name: t
|
|
249
|
-
}) &&
|
|
250
|
-
...
|
|
251
|
-
pages:
|
|
250
|
+
}) && A({
|
|
251
|
+
...k,
|
|
252
|
+
pages: k.pages?.map((n) => n.id === e ? {
|
|
252
253
|
...n,
|
|
253
254
|
name: t
|
|
254
255
|
} : n)
|
|
255
256
|
});
|
|
256
257
|
}, [
|
|
257
|
-
O,
|
|
258
258
|
k,
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
259
|
+
A,
|
|
260
|
+
Ue
|
|
261
|
+
]), st = l(async (e) => {
|
|
262
|
+
if (!k || !c) return;
|
|
263
|
+
let t = k.pages?.find((t) => t.id === e);
|
|
263
264
|
if (!t) return;
|
|
264
|
-
let n = await
|
|
265
|
-
n && (
|
|
266
|
-
...
|
|
267
|
-
pages: [...
|
|
268
|
-
}),
|
|
265
|
+
let n = await Ge(e, v("bigconsole.dashboards.view.pageCopyName", "{{name}} (Copy)", { name: t.name ?? "" }));
|
|
266
|
+
n && (A({
|
|
267
|
+
...k,
|
|
268
|
+
pages: [...k.pages || [], n]
|
|
269
|
+
}), I(n.id));
|
|
269
270
|
}, [
|
|
270
|
-
O,
|
|
271
|
-
c,
|
|
272
271
|
k,
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
272
|
+
c,
|
|
273
|
+
A,
|
|
274
|
+
Ge,
|
|
275
|
+
I,
|
|
276
|
+
v
|
|
277
|
+
]), ct = l(async (e) => {
|
|
278
|
+
if (!(!k || (k.pages?.length || 0) <= 1) && await We(e)) {
|
|
279
|
+
let t = k.pages?.filter((t) => t.id !== e).map((e, t) => ({
|
|
279
280
|
...e,
|
|
280
281
|
order: t
|
|
281
282
|
}));
|
|
282
|
-
|
|
283
|
-
...
|
|
283
|
+
A({
|
|
284
|
+
...k,
|
|
284
285
|
pages: t
|
|
285
286
|
});
|
|
286
287
|
let n = t?.[0]?.id;
|
|
287
|
-
|
|
288
|
+
F === e && n && I(n, { replace: !0 });
|
|
288
289
|
}
|
|
289
290
|
}, [
|
|
290
|
-
O,
|
|
291
291
|
k,
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
k
|
|
298
|
-
|
|
292
|
+
A,
|
|
293
|
+
F,
|
|
294
|
+
We,
|
|
295
|
+
I
|
|
296
|
+
]), lt = l(async (e) => {
|
|
297
|
+
if (!k || !c) return;
|
|
298
|
+
A({
|
|
299
|
+
...k,
|
|
299
300
|
pages: e.map((e, t) => ({
|
|
300
301
|
...e,
|
|
301
302
|
order: t
|
|
302
303
|
}))
|
|
303
304
|
});
|
|
304
305
|
let t = e.map((e) => e.id);
|
|
305
|
-
await
|
|
306
|
+
await Ke(c, t);
|
|
306
307
|
}, [
|
|
307
|
-
O,
|
|
308
|
-
c,
|
|
309
308
|
k,
|
|
310
|
-
|
|
309
|
+
c,
|
|
310
|
+
A,
|
|
311
|
+
Ke
|
|
311
312
|
]);
|
|
312
|
-
return
|
|
313
|
+
return x ? /* @__PURE__ */ h("div", {
|
|
313
314
|
className: "flex items-center justify-center h-full",
|
|
314
|
-
children: /* @__PURE__ */
|
|
315
|
-
}) :
|
|
315
|
+
children: /* @__PURE__ */ h("div", { className: "animate-spin w-8 h-8 border-4 border-action-primary-bg border-t-transparent rounded-full" })
|
|
316
|
+
}) : S ? H ? /* @__PURE__ */ h("div", {
|
|
316
317
|
className: "flex h-full flex-col items-center justify-center",
|
|
317
318
|
style: { padding: "var(--space-pagePadding)" },
|
|
318
|
-
children: /* @__PURE__ */
|
|
319
|
+
children: /* @__PURE__ */ h(a, {
|
|
319
320
|
headingLevel: 2,
|
|
320
321
|
tone: "danger",
|
|
321
|
-
title:
|
|
322
|
-
description: /* @__PURE__ */
|
|
322
|
+
title: v("bigconsole.dashboards.view.errorTitle", "Error loading dashboard"),
|
|
323
|
+
description: /* @__PURE__ */ h("span", {
|
|
323
324
|
className: "break-words",
|
|
324
|
-
children:
|
|
325
|
+
children: H.message
|
|
325
326
|
}),
|
|
326
327
|
className: "w-full max-w-md",
|
|
327
328
|
"data-testid": "dashboard-view-error",
|
|
328
|
-
actions: /* @__PURE__ */
|
|
329
|
+
actions: /* @__PURE__ */ g(m, { children: [/* @__PURE__ */ h(p, {
|
|
329
330
|
size: "sm",
|
|
330
|
-
onClick: () =>
|
|
331
|
-
children:
|
|
332
|
-
}), /* @__PURE__ */
|
|
331
|
+
onClick: () => U(c),
|
|
332
|
+
children: v("bigconsole.dashboards.view.retry", "Retry")
|
|
333
|
+
}), /* @__PURE__ */ h(p, {
|
|
333
334
|
size: "sm",
|
|
334
335
|
variant: "outline",
|
|
335
|
-
onClick: () =>
|
|
336
|
-
children:
|
|
336
|
+
onClick: () => _("/dashboards"),
|
|
337
|
+
children: v("bigconsole.dashboards.view.backToDashboards", "Back to Dashboards")
|
|
337
338
|
})] })
|
|
338
339
|
})
|
|
339
|
-
}) :
|
|
340
|
+
}) : C ? /* @__PURE__ */ h("div", {
|
|
340
341
|
className: "flex flex-col items-center justify-center h-full",
|
|
341
342
|
style: { padding: "var(--space-pagePadding)" },
|
|
342
|
-
children: /* @__PURE__ */
|
|
343
|
+
children: /* @__PURE__ */ h(Ee, {
|
|
343
344
|
illustration: "empty-data",
|
|
344
|
-
title:
|
|
345
|
-
description: /* @__PURE__ */
|
|
345
|
+
title: v("bigconsole.dashboards.view.notFoundTitle", "Dashboard not found"),
|
|
346
|
+
description: /* @__PURE__ */ g(m, { children: [v("bigconsole.dashboards.view.notFoundDescription", "The dashboard you're looking for doesn't exist or has been deleted."), /* @__PURE__ */ h("span", {
|
|
346
347
|
className: "mt-2 block font-mono text-xs text-text-muted break-all",
|
|
347
|
-
children:
|
|
348
|
+
children: v("bigconsole.dashboards.view.idLabel", "ID: {{id}}", { id: c ?? "" })
|
|
348
349
|
})] }),
|
|
349
|
-
action: /* @__PURE__ */
|
|
350
|
-
onClick: () =>
|
|
351
|
-
children:
|
|
350
|
+
action: /* @__PURE__ */ h(p, {
|
|
351
|
+
onClick: () => _("/dashboards"),
|
|
352
|
+
children: v("bigconsole.dashboards.view.backToDashboards", "Back to Dashboards")
|
|
352
353
|
})
|
|
353
354
|
})
|
|
354
|
-
}) :
|
|
355
|
+
}) : V || !k ? /* @__PURE__ */ h("div", {
|
|
355
356
|
className: "flex items-center justify-center h-full",
|
|
356
357
|
role: "status",
|
|
357
358
|
"aria-live": "polite",
|
|
358
|
-
children: /* @__PURE__ */
|
|
359
|
+
children: /* @__PURE__ */ g("div", {
|
|
359
360
|
className: "flex flex-col items-center gap-4",
|
|
360
|
-
children: [/* @__PURE__ */
|
|
361
|
+
children: [/* @__PURE__ */ h("div", { className: "animate-spin w-8 h-8 border-4 border-action-primary-bg border-t-transparent rounded-full" }), /* @__PURE__ */ h("p", {
|
|
361
362
|
className: "text-sm text-text-secondary",
|
|
362
|
-
children:
|
|
363
|
+
children: v("bigconsole.dashboards.view.loading", "Loading dashboard...")
|
|
363
364
|
})]
|
|
364
365
|
})
|
|
365
|
-
}) : /* @__PURE__ */
|
|
366
|
-
ref:
|
|
366
|
+
}) : /* @__PURE__ */ g("div", {
|
|
367
|
+
ref: qe,
|
|
367
368
|
className: "h-full flex flex-col overflow-hidden",
|
|
368
369
|
children: [
|
|
369
|
-
/* @__PURE__ */
|
|
370
|
+
/* @__PURE__ */ h(a, {
|
|
370
371
|
emphasis: "bare",
|
|
371
372
|
padding: "none",
|
|
372
373
|
"data-testid": "dashboard-route-header",
|
|
373
374
|
"aria-label": "Dashboard",
|
|
374
375
|
className: "flex-shrink-0 border-b border-[var(--color-border-subtle)] bg-bg-surface px-3 py-2",
|
|
375
376
|
headerClassName: "",
|
|
376
|
-
header: /* @__PURE__ */
|
|
377
|
+
header: /* @__PURE__ */ g("div", {
|
|
377
378
|
className: "flex flex-wrap items-center gap-control-gap",
|
|
378
379
|
children: [
|
|
379
|
-
/* @__PURE__ */
|
|
380
|
-
onClick:
|
|
380
|
+
/* @__PURE__ */ g(p, {
|
|
381
|
+
onClick: Xe,
|
|
381
382
|
variant: "ghost",
|
|
382
383
|
size: "sm",
|
|
383
|
-
title:
|
|
384
|
-
"aria-label":
|
|
384
|
+
title: v("bigconsole.dashboards.view.backToDashboards", "Back to Dashboards"),
|
|
385
|
+
"aria-label": v("bigconsole.dashboards.view.backToDashboards", "Back to Dashboards"),
|
|
385
386
|
className: "flex-shrink-0",
|
|
386
|
-
children: [/* @__PURE__ */
|
|
387
|
+
children: [/* @__PURE__ */ h(we, { className: "w-4 h-4 mr-2" }), v("bigconsole.dashboards.view.back", "Back")]
|
|
387
388
|
}),
|
|
388
|
-
/* @__PURE__ */
|
|
389
|
+
/* @__PURE__ */ h("h1", {
|
|
389
390
|
className: "min-w-0 flex-1 truncate text-sm font-semibold text-text-primary",
|
|
390
|
-
title:
|
|
391
|
-
...
|
|
392
|
-
children:
|
|
391
|
+
title: k.name,
|
|
392
|
+
...ve(k.id),
|
|
393
|
+
children: k.name
|
|
393
394
|
}),
|
|
394
|
-
/* @__PURE__ */
|
|
395
|
+
/* @__PURE__ */ h("div", {
|
|
395
396
|
className: "flex-shrink-0",
|
|
396
|
-
children: /* @__PURE__ */
|
|
397
|
-
isLive:
|
|
397
|
+
children: /* @__PURE__ */ h(se, {
|
|
398
|
+
isLive: E,
|
|
398
399
|
onToggle: () => Le((e) => !e)
|
|
399
400
|
})
|
|
400
401
|
}),
|
|
401
|
-
/* @__PURE__ */
|
|
402
|
+
/* @__PURE__ */ h("div", {
|
|
402
403
|
className: "flex-shrink-0",
|
|
403
|
-
children: /* @__PURE__ */
|
|
404
|
-
onClick: () =>
|
|
404
|
+
children: /* @__PURE__ */ g(p, {
|
|
405
|
+
onClick: () => Re((e) => !e),
|
|
405
406
|
variant: "ghost",
|
|
406
407
|
size: "sm",
|
|
407
|
-
"aria-pressed":
|
|
408
|
-
title:
|
|
409
|
-
"aria-label":
|
|
410
|
-
children: [/* @__PURE__ */
|
|
408
|
+
"aria-pressed": D,
|
|
409
|
+
title: v("bigconsole.dashboards.view.digest", "Console digest"),
|
|
410
|
+
"aria-label": v("bigconsole.dashboards.view.digest", "Console digest"),
|
|
411
|
+
children: [/* @__PURE__ */ h(Te, { className: "w-4 h-4 mr-2" }), v("bigconsole.dashboards.view.digest", "Digest")]
|
|
411
412
|
})
|
|
412
413
|
})
|
|
413
414
|
]
|
|
414
415
|
})
|
|
415
416
|
}),
|
|
416
|
-
|
|
417
|
+
D && k && /* @__PURE__ */ h("div", {
|
|
417
418
|
className: "flex-shrink-0 border-b border-[var(--color-border-subtle)] bg-bg-surface px-3 py-2 sm:px-4",
|
|
418
|
-
children: /* @__PURE__ */
|
|
419
|
+
children: /* @__PURE__ */ h("div", {
|
|
419
420
|
className: "mx-auto max-w-3xl",
|
|
420
|
-
children: /* @__PURE__ */
|
|
421
|
-
dashboardId:
|
|
422
|
-
onClose: () =>
|
|
421
|
+
children: /* @__PURE__ */ h(ge, {
|
|
422
|
+
dashboardId: k.id,
|
|
423
|
+
onClose: () => Re(!1)
|
|
423
424
|
})
|
|
424
425
|
})
|
|
425
426
|
}),
|
|
426
|
-
|
|
427
|
-
currentDashboardId:
|
|
428
|
-
currentDashboardName:
|
|
427
|
+
O && /* @__PURE__ */ h(le, {
|
|
428
|
+
currentDashboardId: k.id,
|
|
429
|
+
currentDashboardName: k.name,
|
|
429
430
|
basePath: `${Ae}/dashboards`
|
|
430
431
|
}),
|
|
431
|
-
/* @__PURE__ */
|
|
432
|
+
/* @__PURE__ */ h("div", {
|
|
432
433
|
className: "flex-1 min-w-0 overflow-hidden",
|
|
433
|
-
children: /* @__PURE__ */
|
|
434
|
-
dashboardId:
|
|
435
|
-
pageId:
|
|
436
|
-
title:
|
|
437
|
-
onPaste:
|
|
438
|
-
onSave:
|
|
439
|
-
isSaving:
|
|
440
|
-
onExport:
|
|
441
|
-
onPublishTemplate:
|
|
434
|
+
children: /* @__PURE__ */ h(ae, {
|
|
435
|
+
dashboardId: k.id,
|
|
436
|
+
pageId: F || k.pages?.[0]?.id,
|
|
437
|
+
title: k.name,
|
|
438
|
+
onPaste: Qe,
|
|
439
|
+
onSave: je ? Ye : void 0,
|
|
440
|
+
isSaving: Pe,
|
|
441
|
+
onExport: Me ? $e : void 0,
|
|
442
|
+
onPublishTemplate: Ne ? nt : void 0,
|
|
442
443
|
pages: Z,
|
|
443
444
|
activePageId: $ ?? void 0,
|
|
444
445
|
onPageChange: X,
|
|
445
|
-
onPageAdd:
|
|
446
|
-
onPageRename:
|
|
447
|
-
onPageDuplicate:
|
|
448
|
-
onPageDelete:
|
|
449
|
-
onPagesReorder:
|
|
446
|
+
onPageAdd: at,
|
|
447
|
+
onPageRename: ot,
|
|
448
|
+
onPageDuplicate: st,
|
|
449
|
+
onPageDelete: ct,
|
|
450
|
+
onPagesReorder: lt,
|
|
450
451
|
showPageTabs: !0
|
|
451
452
|
})
|
|
452
453
|
}),
|
|
453
|
-
/* @__PURE__ */
|
|
454
|
+
/* @__PURE__ */ h(ce, {
|
|
454
455
|
isOpen: Ie,
|
|
455
|
-
dashboardId:
|
|
456
|
-
dashboardName:
|
|
457
|
-
onClose:
|
|
456
|
+
dashboardId: k.id,
|
|
457
|
+
dashboardName: k.name,
|
|
458
|
+
onClose: it
|
|
458
459
|
}),
|
|
459
|
-
/* @__PURE__ */
|
|
460
|
-
isOpen:
|
|
461
|
-
dashboardId:
|
|
462
|
-
dashboardName:
|
|
463
|
-
dashboardDescription:
|
|
464
|
-
onClose:
|
|
460
|
+
/* @__PURE__ */ h(ue, {
|
|
461
|
+
isOpen: et,
|
|
462
|
+
dashboardId: k.id,
|
|
463
|
+
dashboardName: k.name,
|
|
464
|
+
dashboardDescription: k.description,
|
|
465
|
+
onClose: rt
|
|
465
466
|
})
|
|
466
467
|
]
|
|
467
|
-
}) : /* @__PURE__ */
|
|
468
|
-
title:
|
|
469
|
-
description:
|
|
468
|
+
}) : /* @__PURE__ */ h(Se, {
|
|
469
|
+
title: v("bigconsole.dashboards.view.accessDeniedTitle", "Access Denied"),
|
|
470
|
+
description: v("bigconsole.dashboards.view.accessDeniedDescription", "You don't have permission to view this dashboard.")
|
|
470
471
|
});
|
|
471
472
|
});
|
|
472
|
-
export {
|
|
473
|
+
export { _ as DashboardViewPage, _ as default };
|