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