@burdenoff/microfe-bigconsole 2026.1029.4 → 2026.1030.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/components/dashboard/CreateDashboardDialog.js +450 -413
- package/dist/bigconsole/components/dashboard/QuotaLimitNotice.d.ts +9 -0
- package/dist/bigconsole/components/dashboard/QuotaLimitNotice.js +59 -0
- package/dist/bigconsole/hooks/mutationInputEnums.d.ts +1 -1
- package/dist/bigconsole/hooks/mutationInputEnums.js +1 -1
- package/dist/bigconsole/hooks/useDashboardOperations.d.ts +1 -0
- package/dist/bigconsole/hooks/useDashboardOperations.js +1 -2
- package/dist/bigconsole/hooks/useEventLogs.js +1 -1
- package/dist/bigconsole/hooks/useWidgetActions.js +1 -1
- package/dist/bigconsole/pages/DashboardsPage.js +391 -390
- package/dist/bigconsole/providers/BigConsoleQuotaProvider.d.ts +13 -0
- package/dist/bigconsole/providers/BigConsoleQuotaProvider.js +55 -49
- package/dist/bigconsole/utils/quota.d.ts +21 -0
- package/dist/bigconsole/utils/quota.js +20 -9
- package/dist/generated/wspace-operations.d.ts +417 -425
- package/dist/generated/wspace-operations.js +19 -19
- package/dist/generated/wspace-types.d.ts +698 -737
- package/dist/generated/wspace-types.js +10 -10
- package/dist/translations/en.d.ts +1 -1
- package/package.json +1 -1
|
@@ -1,33 +1,33 @@
|
|
|
1
1
|
import { useBigConsoleNavigate as e } from "../context/BigConsoleContext.js";
|
|
2
2
|
import "../context/index.js";
|
|
3
|
-
import {
|
|
4
|
-
import { Section as
|
|
5
|
-
import { SortBySelect as
|
|
3
|
+
import { isBigConsoleQuotaError as t, reportBigConsoleQuotaError as n } from "../utils/quota.js";
|
|
4
|
+
import { Section as r, SectionStack as i } from "../components/common/Section.js";
|
|
5
|
+
import { SortBySelect as a } from "../components/common/SortBySelect.js";
|
|
6
6
|
import "../components/common/index.js";
|
|
7
|
-
import
|
|
7
|
+
import o from "../hooks/useDashboardOperations.js";
|
|
8
8
|
import "../hooks/index.js";
|
|
9
|
-
import { BIGCONSOLE_PERMISSIONS as
|
|
10
|
-
import { useTr as
|
|
11
|
-
import
|
|
12
|
-
import c, { useDashboardStatusLabel as
|
|
13
|
-
import { isNative as l, nativeConfirm as
|
|
14
|
-
import
|
|
15
|
-
import { LIST_SORT_COPY as
|
|
16
|
-
import { dashboardsListControls as
|
|
17
|
-
import { selectDashboards as
|
|
18
|
-
import { resolveCreateParam as
|
|
19
|
-
import { memo as
|
|
20
|
-
import { useSearchParams as
|
|
21
|
-
import { AccessDenied as
|
|
22
|
-
import { usePermissions as
|
|
23
|
-
import { Calendar as
|
|
24
|
-
import { AuroraBackground as
|
|
25
|
-
import { jsx as
|
|
26
|
-
import { useAssistantPageControls as
|
|
9
|
+
import { BIGCONSOLE_PERMISSIONS as s } from "../../constants/permissions.js";
|
|
10
|
+
import { useTr as ee } from "../../shared/hooks/useTr.js";
|
|
11
|
+
import te from "../components/dashboard/CreateDashboardDialog.js";
|
|
12
|
+
import c, { useDashboardStatusLabel as ne } from "../components/dashboard/DashboardStatusPill.js";
|
|
13
|
+
import { isNative as l, nativeConfirm as re, nativeImpact as ie, nativeNotify as u } from "../../utils/nativeBridge.js";
|
|
14
|
+
import ae from "../components/dashboard/ImportDashboardDialog.js";
|
|
15
|
+
import { LIST_SORT_COPY as oe, listSortOptions as se } from "../utils/listSort.js";
|
|
16
|
+
import { dashboardsListControls as ce } from "../assistant/pageControls.js";
|
|
17
|
+
import { selectDashboards as le } from "../utils/dashboardList.js";
|
|
18
|
+
import { resolveCreateParam as ue, withoutCreateParam as de } from "../utils/createDialogParam.js";
|
|
19
|
+
import { memo as d, useCallback as f, useEffect as p, useMemo as m, useState as h } from "react";
|
|
20
|
+
import { useSearchParams as fe } from "react-router";
|
|
21
|
+
import { AccessDenied as pe, PermissionButton as g } from "@burdenoff/fe-libs/shared/components";
|
|
22
|
+
import { usePermissions as me } from "@burdenoff/fe-libs/shared/providers/shell";
|
|
23
|
+
import { Calendar as he, ChevronLeft as ge, ChevronRight as _e, Copy as ve, FileText as ye, Layers as be, LayoutDashboard as _, LayoutGrid as xe, List as Se, Pencil as Ce, Plus as we, Search as Te, Trash2 as Ee, Upload as De } from "lucide-react";
|
|
24
|
+
import { AuroraBackground as v, Badge as y, Button as b, CTAOverflowMenu as x, Card as Oe, CardContent as ke, GlassCard as Ae, GradientText as S, IllustratedEmptyState as je, Input as Me, PagePurpose as Ne, Spinner as C } from "@burdenoff/fe-libs/ui";
|
|
25
|
+
import { jsx as w, jsxs as T } from "react/jsx-runtime";
|
|
26
|
+
import { useAssistantPageControls as Pe } from "@burdenoff/fe-libs/shared/assistant/appControls/useAssistantControl";
|
|
27
27
|
//#region src/bigconsole/pages/DashboardsPage.tsx
|
|
28
|
-
var
|
|
29
|
-
function
|
|
30
|
-
if (t <=
|
|
28
|
+
var E = "bf-bigconsole-dashboards-view", D = 12, O = 7;
|
|
29
|
+
function Fe(e, t) {
|
|
30
|
+
if (t <= O) return Array.from({ length: t }, (e, t) => t + 1);
|
|
31
31
|
let n = new Set([
|
|
32
32
|
1,
|
|
33
33
|
t,
|
|
@@ -39,12 +39,12 @@ function Ne(e, t) {
|
|
|
39
39
|
t > 0 && e - r[t - 1] > 1 && i.push(null), i.push(e);
|
|
40
40
|
}), i;
|
|
41
41
|
}
|
|
42
|
-
var
|
|
43
|
-
return /* @__PURE__ */
|
|
42
|
+
var Ie = d(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onCreate: i, onImport: a, canCreate: o, canImport: s }) {
|
|
43
|
+
return /* @__PURE__ */ T("div", {
|
|
44
44
|
className: "relative overflow-hidden border-b border-[var(--color-border-seam)] bg-[image:var(--gradient-gloss-card)]",
|
|
45
|
-
children: [/* @__PURE__ */
|
|
45
|
+
children: [/* @__PURE__ */ w(v, { intensity: "subtle" }), /* @__PURE__ */ w("div", {
|
|
46
46
|
style: { padding: "var(--space-pagePadding)" },
|
|
47
|
-
children: /* @__PURE__ */
|
|
47
|
+
children: /* @__PURE__ */ T("div", {
|
|
48
48
|
style: {
|
|
49
49
|
display: "flex",
|
|
50
50
|
alignItems: "center",
|
|
@@ -52,14 +52,14 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
52
52
|
flexWrap: "wrap",
|
|
53
53
|
gap: "var(--space-formGap)"
|
|
54
54
|
},
|
|
55
|
-
children: [/* @__PURE__ */
|
|
55
|
+
children: [/* @__PURE__ */ T("div", {
|
|
56
56
|
style: {
|
|
57
57
|
display: "flex",
|
|
58
58
|
alignItems: "center",
|
|
59
59
|
gap: "var(--space-formGap)",
|
|
60
60
|
minWidth: 0
|
|
61
61
|
},
|
|
62
|
-
children: [/* @__PURE__ */
|
|
62
|
+
children: [/* @__PURE__ */ w("div", {
|
|
63
63
|
style: {
|
|
64
64
|
display: "flex",
|
|
65
65
|
height: "var(--size-controlHeight-lg)",
|
|
@@ -70,22 +70,22 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
70
70
|
borderRadius: "var(--radius-card)",
|
|
71
71
|
backgroundColor: "var(--color-action-primary-bg)"
|
|
72
72
|
},
|
|
73
|
-
children: /* @__PURE__ */
|
|
73
|
+
children: /* @__PURE__ */ w(_, { style: {
|
|
74
74
|
height: "var(--size-icon-lg)",
|
|
75
75
|
width: "var(--size-icon-lg)",
|
|
76
76
|
color: "var(--color-action-primary-text)"
|
|
77
77
|
} })
|
|
78
|
-
}), /* @__PURE__ */
|
|
78
|
+
}), /* @__PURE__ */ T("div", {
|
|
79
79
|
style: { minWidth: 0 },
|
|
80
|
-
children: [/* @__PURE__ */
|
|
80
|
+
children: [/* @__PURE__ */ w("h1", {
|
|
81
81
|
style: {
|
|
82
82
|
fontSize: "var(--font-size-heading-h4)",
|
|
83
83
|
fontWeight: "var(--font-weight-bold)",
|
|
84
84
|
margin: 0,
|
|
85
85
|
color: "var(--color-text-primary)"
|
|
86
86
|
},
|
|
87
|
-
children: /* @__PURE__ */
|
|
88
|
-
}), /* @__PURE__ */
|
|
87
|
+
children: /* @__PURE__ */ w(S, { children: e })
|
|
88
|
+
}), /* @__PURE__ */ w("p", {
|
|
89
89
|
style: {
|
|
90
90
|
fontSize: "var(--font-size-body-sm)",
|
|
91
91
|
color: "var(--color-text-secondary)",
|
|
@@ -94,14 +94,14 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
94
94
|
children: t
|
|
95
95
|
})]
|
|
96
96
|
})]
|
|
97
|
-
}), /* @__PURE__ */
|
|
97
|
+
}), /* @__PURE__ */ w("div", {
|
|
98
98
|
"data-tour": "bigconsole-dashboard-create",
|
|
99
|
-
children: /* @__PURE__ */
|
|
99
|
+
children: /* @__PURE__ */ w(x, {
|
|
100
100
|
primary: {
|
|
101
101
|
label: n,
|
|
102
102
|
onSelect: i,
|
|
103
103
|
disabled: !o,
|
|
104
|
-
icon: /* @__PURE__ */
|
|
104
|
+
icon: /* @__PURE__ */ w(we, { style: {
|
|
105
105
|
marginRight: "var(--space-iconGap)",
|
|
106
106
|
height: "var(--size-icon-sm)",
|
|
107
107
|
width: "var(--size-icon-sm)"
|
|
@@ -111,7 +111,7 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
111
111
|
label: r,
|
|
112
112
|
onSelect: a,
|
|
113
113
|
disabled: !s,
|
|
114
|
-
icon: /* @__PURE__ */
|
|
114
|
+
icon: /* @__PURE__ */ w(De, { style: {
|
|
115
115
|
height: "var(--size-icon-sm)",
|
|
116
116
|
width: "var(--size-icon-sm)"
|
|
117
117
|
} })
|
|
@@ -121,240 +121,241 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
121
121
|
})
|
|
122
122
|
})]
|
|
123
123
|
});
|
|
124
|
-
}),
|
|
125
|
-
let
|
|
124
|
+
}), k = d(function() {
|
|
125
|
+
let d = e(), v = ee(), [x, S] = h(""), [O, k] = h(""), [A, Le] = h(""), [j, Re] = h("default"), [M, N] = h(1), [ze, P] = h(!1), [F, Be] = h(!1), [Ve, He] = h(!1), [I, Ue] = h(() => {
|
|
126
126
|
try {
|
|
127
|
-
return window.localStorage.getItem(
|
|
127
|
+
return window.localStorage.getItem(E) === "list" ? "list" : "grid";
|
|
128
128
|
} catch {
|
|
129
129
|
return "grid";
|
|
130
130
|
}
|
|
131
|
-
}),
|
|
132
|
-
|
|
131
|
+
}), We = f((e) => {
|
|
132
|
+
Ue(e);
|
|
133
133
|
try {
|
|
134
|
-
window.localStorage.setItem(
|
|
134
|
+
window.localStorage.setItem(E, e);
|
|
135
135
|
} catch {}
|
|
136
|
-
}, []), { loading:
|
|
137
|
-
|
|
138
|
-
let e =
|
|
139
|
-
permissionsLoading:
|
|
140
|
-
canRead:
|
|
141
|
-
canCreate:
|
|
136
|
+
}, []), { loading: L, error: R, dashboards: z, createDashboard: Ge, deleteDashboard: Ke, cloneDashboard: qe, refetch: B } = o(), { hasPermission: V, isLoading: H } = me(), U = V(s.DASHBOARD_READ), W = V(s.DASHBOARD_CREATE), Je = V(s.DASHBOARD_IMPORT), [G, Ye] = fe();
|
|
137
|
+
p(() => {
|
|
138
|
+
let e = ue(G, {
|
|
139
|
+
permissionsLoading: H,
|
|
140
|
+
canRead: U,
|
|
141
|
+
canCreate: W
|
|
142
142
|
});
|
|
143
|
-
e === "none" || e === "wait" || (e === "open" &&
|
|
143
|
+
e === "none" || e === "wait" || (e === "open" && P(!0), Ye(de(G), { replace: !0 }));
|
|
144
144
|
}, [
|
|
145
|
-
|
|
146
|
-
|
|
145
|
+
G,
|
|
146
|
+
Ye,
|
|
147
|
+
H,
|
|
147
148
|
U,
|
|
148
|
-
W
|
|
149
|
-
G
|
|
149
|
+
W
|
|
150
150
|
]);
|
|
151
|
-
let
|
|
152
|
-
search:
|
|
153
|
-
category:
|
|
154
|
-
status:
|
|
155
|
-
sort:
|
|
156
|
-
page:
|
|
157
|
-
pageSize:
|
|
158
|
-
}),
|
|
159
|
-
|
|
160
|
-
|
|
151
|
+
let K = m(() => Array.from(new Set(z.flatMap((e) => e.category ? [e.category] : []))).sort(), [z]), { filtered: q, totalPages: J, pageItems: Y } = le(z, {
|
|
152
|
+
search: x,
|
|
153
|
+
category: O,
|
|
154
|
+
status: A,
|
|
155
|
+
sort: j,
|
|
156
|
+
page: M,
|
|
157
|
+
pageSize: D
|
|
158
|
+
}), Xe = (Math.min(M, J) - 1) * D;
|
|
159
|
+
p(() => {
|
|
160
|
+
N(1);
|
|
161
161
|
}, [
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
]),
|
|
168
|
-
|
|
169
|
-
}, [
|
|
170
|
-
let
|
|
171
|
-
|
|
172
|
-
}, []),
|
|
173
|
-
|
|
174
|
-
}, [
|
|
175
|
-
|
|
176
|
-
}, []),
|
|
177
|
-
|
|
178
|
-
}, []),
|
|
179
|
-
|
|
180
|
-
}, [
|
|
181
|
-
|
|
182
|
-
}, [
|
|
183
|
-
|
|
162
|
+
x,
|
|
163
|
+
I,
|
|
164
|
+
O,
|
|
165
|
+
A,
|
|
166
|
+
j
|
|
167
|
+
]), p(() => {
|
|
168
|
+
M > J && N(J);
|
|
169
|
+
}, [M, J]);
|
|
170
|
+
let Ze = f(() => {
|
|
171
|
+
N((e) => Math.max(1, e - 1));
|
|
172
|
+
}, []), Qe = f(() => {
|
|
173
|
+
N((e) => Math.min(J, e + 1));
|
|
174
|
+
}, [J]), $e = f((e) => {
|
|
175
|
+
N(e);
|
|
176
|
+
}, []), et = f(() => {
|
|
177
|
+
P(!0);
|
|
178
|
+
}, []), tt = f(({ dashboardId: e }) => {
|
|
179
|
+
B(), d(`/dashboards/${e}`);
|
|
180
|
+
}, [B, d]), nt = f(() => {
|
|
181
|
+
F || P(!1);
|
|
182
|
+
}, [F]), rt = f(async (e) => {
|
|
183
|
+
Be(!0);
|
|
184
184
|
try {
|
|
185
|
-
let t = await
|
|
185
|
+
let t = await Ge({
|
|
186
186
|
name: e.name,
|
|
187
187
|
description: e.description,
|
|
188
188
|
category: e.category,
|
|
189
189
|
tags: e.tags
|
|
190
190
|
});
|
|
191
|
-
|
|
191
|
+
if (!t) throw Error(v("bigconsole.dashboards.createDialog.error.createFailed", "Failed to create dashboard. Please try again."));
|
|
192
|
+
P(!1), d(`/dashboards/${t.id}/builder`);
|
|
192
193
|
} catch (e) {
|
|
193
|
-
|
|
194
|
-
F(!1);
|
|
195
|
-
return;
|
|
196
|
-
}
|
|
197
|
-
throw console.error("Failed to create dashboard:", e), l() && d("error"), e;
|
|
194
|
+
throw t(e) || console.error("Failed to create dashboard:", e), l() && u("error"), e;
|
|
198
195
|
} finally {
|
|
199
|
-
|
|
196
|
+
Be(!1);
|
|
200
197
|
}
|
|
201
|
-
}, [
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
198
|
+
}, [
|
|
199
|
+
Ge,
|
|
200
|
+
d,
|
|
201
|
+
v
|
|
202
|
+
]), X = f((e) => {
|
|
203
|
+
d(`/dashboards/${e}`);
|
|
204
|
+
}, [d]), Z = f((e, t) => {
|
|
205
|
+
t.stopPropagation(), d(`/dashboards/${e}/builder`);
|
|
206
|
+
}, [d]), it = f(async (e, t) => {
|
|
206
207
|
t.stopPropagation();
|
|
207
|
-
let n =
|
|
208
|
+
let n = v("bigconsole.dashboards.confirmDelete", "Are you sure you want to delete this dashboard?"), r = await re({
|
|
208
209
|
title: "Delete dashboard?",
|
|
209
210
|
message: n,
|
|
210
211
|
okButtonTitle: "Delete",
|
|
211
212
|
cancelButtonTitle: "Cancel"
|
|
212
213
|
});
|
|
213
214
|
if (r === null ? window.confirm(n) : r) {
|
|
214
|
-
|
|
215
|
+
ie("medium");
|
|
215
216
|
try {
|
|
216
|
-
await
|
|
217
|
+
await Ke(e), l() && u("success");
|
|
217
218
|
} catch (e) {
|
|
218
|
-
throw l() &&
|
|
219
|
+
throw l() && u("error"), e;
|
|
219
220
|
}
|
|
220
221
|
}
|
|
221
|
-
}, [
|
|
222
|
+
}, [Ke, v]), at = f(async (e, t, r) => {
|
|
222
223
|
r.stopPropagation();
|
|
223
|
-
let i =
|
|
224
|
+
let i = v("bigconsole.dashboards.clone.defaultSuffix", "{{sourceName}} (Copy)", { sourceName: t }), a = window.prompt(v("bigconsole.dashboards.clone.namePrompt", "Name for the cloned dashboard:"), i);
|
|
224
225
|
if (!(!a || !a.trim())) {
|
|
225
|
-
|
|
226
|
+
ie("medium");
|
|
226
227
|
try {
|
|
227
|
-
let t = await
|
|
228
|
-
t && (l() &&
|
|
228
|
+
let t = await qe(e, a.trim());
|
|
229
|
+
t && (l() && u("success"), d(`/dashboards/${t.id}`));
|
|
229
230
|
} catch (e) {
|
|
230
|
-
if (
|
|
231
|
-
throw l() &&
|
|
231
|
+
if (n(e, "project")) return;
|
|
232
|
+
throw l() && u("error"), e;
|
|
232
233
|
}
|
|
233
234
|
}
|
|
234
235
|
}, [
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
]),
|
|
239
|
-
|
|
240
|
-
}, []),
|
|
241
|
-
|
|
242
|
-
}, []),
|
|
243
|
-
|
|
244
|
-
}, [
|
|
236
|
+
qe,
|
|
237
|
+
d,
|
|
238
|
+
v
|
|
239
|
+
]), ot = f(() => {
|
|
240
|
+
He(!0);
|
|
241
|
+
}, []), st = f(() => {
|
|
242
|
+
He(!1);
|
|
243
|
+
}, []), ct = f((e, t) => {
|
|
244
|
+
B();
|
|
245
|
+
}, [B]), lt = (e) => {
|
|
245
246
|
let t = new Date(e), n = /* @__PURE__ */ new Date(), r = n.getTime() - t.getTime(), i = Math.floor(r / 6e4), a = Math.floor(r / 36e5), o = Math.floor(r / 864e5);
|
|
246
|
-
return i < 1 ?
|
|
247
|
+
return i < 1 ? v("bigconsole.dashboards.time.justNow", "Just now") : i < 60 ? `${i}${v("bigconsole.dashboards.time.minutesAgoSuffix", "m ago")}` : a < 24 ? `${a}${v("bigconsole.dashboards.time.hoursAgoSuffix", "h ago")}` : o < 7 ? `${o}${v("bigconsole.dashboards.time.daysAgoSuffix", "d ago")}` : new Intl.DateTimeFormat("en-US", {
|
|
247
248
|
month: "short",
|
|
248
249
|
day: "numeric",
|
|
249
250
|
year: t.getFullYear() === n.getFullYear() ? void 0 : "numeric"
|
|
250
251
|
}).format(t);
|
|
251
|
-
}, Q =
|
|
252
|
+
}, Q = ne(), $ = m(() => Array.from(new Set(z.map((e) => e.status).filter((e) => e !== void 0))).sort().map((e) => ({
|
|
252
253
|
value: e,
|
|
253
254
|
label: Q(e)
|
|
254
|
-
})), [
|
|
255
|
-
|
|
256
|
-
tr:
|
|
257
|
-
categories:
|
|
255
|
+
})), [z, Q]), ut = m(() => se(v, !0), [v]);
|
|
256
|
+
Pe(m(() => !H && U && !R ? ce({
|
|
257
|
+
tr: v,
|
|
258
|
+
categories: K,
|
|
258
259
|
statuses: $,
|
|
259
|
-
category:
|
|
260
|
-
status:
|
|
261
|
-
setCategory:
|
|
262
|
-
setStatus:
|
|
263
|
-
setSearch:
|
|
264
|
-
sort:
|
|
265
|
-
setSort:
|
|
260
|
+
category: O,
|
|
261
|
+
status: A,
|
|
262
|
+
setCategory: k,
|
|
263
|
+
setStatus: Le,
|
|
264
|
+
setSearch: S,
|
|
265
|
+
sort: j,
|
|
266
|
+
setSort: Re
|
|
266
267
|
}) : null, [
|
|
267
|
-
|
|
268
|
+
v,
|
|
269
|
+
H,
|
|
268
270
|
U,
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
q,
|
|
271
|
+
R,
|
|
272
|
+
K,
|
|
272
273
|
$,
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
274
|
+
O,
|
|
275
|
+
A,
|
|
276
|
+
j
|
|
276
277
|
]));
|
|
277
|
-
let
|
|
278
|
-
title:
|
|
279
|
-
subtitle:
|
|
280
|
-
createLabel:
|
|
281
|
-
importLabel:
|
|
282
|
-
onCreate:
|
|
283
|
-
onImport:
|
|
284
|
-
canCreate:
|
|
285
|
-
canImport:
|
|
278
|
+
let dt = (e) => e.widgetCount ?? 0, ft = (e) => e.pageCount || 0, pt = /* @__PURE__ */ w(Ie, {
|
|
279
|
+
title: v("bigconsole.dashboards.title", "Dashboards"),
|
|
280
|
+
subtitle: v("bigconsole.dashboards.subtitle", "Create and manage your analytics dashboards"),
|
|
281
|
+
createLabel: v("bigconsole.dashboards.actions.create", "Create Dashboard"),
|
|
282
|
+
importLabel: v("bigconsole.dashboards.actions.import", "Import"),
|
|
283
|
+
onCreate: et,
|
|
284
|
+
onImport: ot,
|
|
285
|
+
canCreate: W,
|
|
286
|
+
canImport: Je
|
|
286
287
|
});
|
|
287
|
-
if (
|
|
288
|
+
if (H) return /* @__PURE__ */ w("div", {
|
|
288
289
|
style: {
|
|
289
290
|
display: "flex",
|
|
290
291
|
alignItems: "center",
|
|
291
292
|
justifyContent: "center",
|
|
292
293
|
padding: "80px 0"
|
|
293
294
|
},
|
|
294
|
-
children: /* @__PURE__ */
|
|
295
|
+
children: /* @__PURE__ */ w(C, { style: {
|
|
295
296
|
height: "var(--size-icon-xl)",
|
|
296
297
|
width: "var(--size-icon-xl)"
|
|
297
298
|
} })
|
|
298
299
|
});
|
|
299
|
-
if (!
|
|
300
|
-
title:
|
|
301
|
-
description:
|
|
300
|
+
if (!U) return /* @__PURE__ */ w(pe, {
|
|
301
|
+
title: v("bigconsole.dashboards.accessDenied.title", "Access Denied"),
|
|
302
|
+
description: v("bigconsole.dashboards.accessDenied.description", "You don't have permission to view dashboards.")
|
|
302
303
|
});
|
|
303
|
-
if (
|
|
304
|
+
if (R) return /* @__PURE__ */ T("div", {
|
|
304
305
|
"data-tour": "bigconsole-dashboards-list",
|
|
305
306
|
style: {
|
|
306
307
|
minHeight: "100vh",
|
|
307
308
|
backgroundColor: "var(--color-bg-canvas)"
|
|
308
309
|
},
|
|
309
|
-
children: [
|
|
310
|
+
children: [pt, /* @__PURE__ */ w("div", {
|
|
310
311
|
style: { padding: "var(--space-pagePadding)" },
|
|
311
|
-
children: /* @__PURE__ */
|
|
312
|
+
children: /* @__PURE__ */ w(r, {
|
|
312
313
|
headingLevel: 2,
|
|
313
314
|
tone: "danger",
|
|
314
|
-
title:
|
|
315
|
-
description:
|
|
315
|
+
title: v("bigconsole.dashboards.error.title", "Error loading dashboards"),
|
|
316
|
+
description: R.message,
|
|
316
317
|
"data-testid": "dashboards-error",
|
|
317
|
-
actions: /* @__PURE__ */
|
|
318
|
+
actions: /* @__PURE__ */ w(b, {
|
|
318
319
|
size: "sm",
|
|
319
|
-
onClick: () =>
|
|
320
|
-
children:
|
|
320
|
+
onClick: () => B(),
|
|
321
|
+
children: v("bigconsole.dashboards.error.retry", "Retry")
|
|
321
322
|
})
|
|
322
323
|
})
|
|
323
324
|
})]
|
|
324
325
|
});
|
|
325
|
-
let
|
|
326
|
-
return /* @__PURE__ */
|
|
326
|
+
let mt = q.length;
|
|
327
|
+
return /* @__PURE__ */ T("div", {
|
|
327
328
|
"data-tour": "bigconsole-dashboards-list",
|
|
328
329
|
style: {
|
|
329
330
|
minHeight: "100vh",
|
|
330
331
|
backgroundColor: "var(--color-bg-canvas)"
|
|
331
332
|
},
|
|
332
333
|
children: [
|
|
333
|
-
|
|
334
|
-
/* @__PURE__ */
|
|
334
|
+
pt,
|
|
335
|
+
/* @__PURE__ */ w("div", {
|
|
335
336
|
style: { padding: "var(--space-pagePadding)" },
|
|
336
|
-
children: /* @__PURE__ */
|
|
337
|
+
children: /* @__PURE__ */ T(i, { children: [/* @__PURE__ */ w(r, {
|
|
337
338
|
emphasis: "muted",
|
|
338
339
|
padding: "compact",
|
|
339
|
-
"aria-label":
|
|
340
|
-
children: /* @__PURE__ */
|
|
340
|
+
"aria-label": v("bigconsole.dashboards.about", "About dashboards"),
|
|
341
|
+
children: /* @__PURE__ */ w(Ne, {
|
|
341
342
|
className: "max-w-[80ch]",
|
|
342
343
|
children: "Dashboards are live, shareable views built from widgets that query your data sinks — charts, tables, metrics, and drill-downs in one place. Compose a board to monitor a system, share KPIs with your team, or explore data interactively."
|
|
343
344
|
})
|
|
344
|
-
}), /* @__PURE__ */
|
|
345
|
+
}), /* @__PURE__ */ T(r, {
|
|
345
346
|
headingLevel: 2,
|
|
346
347
|
emphasis: "primary",
|
|
347
348
|
"data-testid": "dashboards-results",
|
|
348
|
-
title:
|
|
349
|
-
description:
|
|
350
|
-
meta: /* @__PURE__ */
|
|
349
|
+
title: v("bigconsole.dashboards.results.title", "Your dashboards"),
|
|
350
|
+
description: v("bigconsole.dashboards.results.description", "Open a board to view it, or use the card actions to edit, duplicate or delete."),
|
|
351
|
+
meta: /* @__PURE__ */ w(y, {
|
|
351
352
|
variant: "secondary",
|
|
352
|
-
"aria-label":
|
|
353
|
-
children:
|
|
353
|
+
"aria-label": v("bigconsole.dashboards.results.count", `${mt} dashboards`),
|
|
354
|
+
children: mt
|
|
354
355
|
}),
|
|
355
|
-
actions: /* @__PURE__ */
|
|
356
|
+
actions: /* @__PURE__ */ T("div", {
|
|
356
357
|
role: "group",
|
|
357
|
-
"aria-label":
|
|
358
|
+
"aria-label": v("bigconsole.dashboards.view.label", "Result layout"),
|
|
358
359
|
style: {
|
|
359
360
|
display: "flex",
|
|
360
361
|
alignItems: "center",
|
|
@@ -363,37 +364,37 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
363
364
|
borderRadius: "var(--radius-button)",
|
|
364
365
|
backgroundColor: "var(--color-bg-sunken)"
|
|
365
366
|
},
|
|
366
|
-
children: [/* @__PURE__ */
|
|
367
|
-
variant:
|
|
367
|
+
children: [/* @__PURE__ */ w(b, {
|
|
368
|
+
variant: I === "grid" ? "default" : "ghost",
|
|
368
369
|
size: "sm",
|
|
369
|
-
onClick: () =>
|
|
370
|
-
"aria-label":
|
|
371
|
-
"aria-pressed":
|
|
372
|
-
title:
|
|
370
|
+
onClick: () => We("grid"),
|
|
371
|
+
"aria-label": v("bigconsole.dashboards.view.grid", "Grid view"),
|
|
372
|
+
"aria-pressed": I === "grid",
|
|
373
|
+
title: v("bigconsole.dashboards.view.grid", "Grid view"),
|
|
373
374
|
style: {
|
|
374
375
|
height: "var(--size-controlHeight-md)",
|
|
375
376
|
width: "var(--size-controlHeight-md)",
|
|
376
377
|
padding: 0,
|
|
377
378
|
borderRadius: "var(--radius-button)"
|
|
378
379
|
},
|
|
379
|
-
children: /* @__PURE__ */
|
|
380
|
+
children: /* @__PURE__ */ w(xe, { style: {
|
|
380
381
|
height: "var(--size-icon-sm)",
|
|
381
382
|
width: "var(--size-icon-sm)"
|
|
382
383
|
} })
|
|
383
|
-
}), /* @__PURE__ */
|
|
384
|
-
variant:
|
|
384
|
+
}), /* @__PURE__ */ w(b, {
|
|
385
|
+
variant: I === "list" ? "default" : "ghost",
|
|
385
386
|
size: "sm",
|
|
386
|
-
onClick: () =>
|
|
387
|
-
"aria-label":
|
|
388
|
-
"aria-pressed":
|
|
389
|
-
title:
|
|
387
|
+
onClick: () => We("list"),
|
|
388
|
+
"aria-label": v("bigconsole.dashboards.view.list", "List view"),
|
|
389
|
+
"aria-pressed": I === "list",
|
|
390
|
+
title: v("bigconsole.dashboards.view.list", "List view"),
|
|
390
391
|
style: {
|
|
391
392
|
height: "var(--size-controlHeight-md)",
|
|
392
393
|
width: "var(--size-controlHeight-md)",
|
|
393
394
|
padding: 0,
|
|
394
395
|
borderRadius: "var(--radius-button)"
|
|
395
396
|
},
|
|
396
|
-
children: /* @__PURE__ */
|
|
397
|
+
children: /* @__PURE__ */ w(Se, { style: {
|
|
397
398
|
height: "var(--size-icon-sm)",
|
|
398
399
|
width: "var(--size-icon-sm)"
|
|
399
400
|
} })
|
|
@@ -401,13 +402,13 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
401
402
|
}),
|
|
402
403
|
bodyClassName: "flex flex-col gap-form-gap",
|
|
403
404
|
children: [
|
|
404
|
-
/* @__PURE__ */
|
|
405
|
+
/* @__PURE__ */ T("div", {
|
|
405
406
|
style: {
|
|
406
407
|
position: "relative",
|
|
407
408
|
width: "100%",
|
|
408
409
|
maxWidth: "420px"
|
|
409
410
|
},
|
|
410
|
-
children: [/* @__PURE__ */
|
|
411
|
+
children: [/* @__PURE__ */ w(Te, {
|
|
411
412
|
"aria-hidden": "true",
|
|
412
413
|
style: {
|
|
413
414
|
position: "absolute",
|
|
@@ -418,98 +419,98 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
418
419
|
width: "var(--size-icon-sm)",
|
|
419
420
|
color: "var(--color-text-muted)"
|
|
420
421
|
}
|
|
421
|
-
}), /* @__PURE__ */
|
|
422
|
+
}), /* @__PURE__ */ w(Me, {
|
|
422
423
|
type: "search",
|
|
423
|
-
"aria-label":
|
|
424
|
-
placeholder:
|
|
425
|
-
value:
|
|
426
|
-
onChange: (e) =>
|
|
424
|
+
"aria-label": v("bigconsole.dashboards.search.placeholder", "Search dashboards..."),
|
|
425
|
+
placeholder: v("bigconsole.dashboards.search.placeholder", "Search dashboards..."),
|
|
426
|
+
value: x,
|
|
427
|
+
onChange: (e) => S(e.target.value),
|
|
427
428
|
style: {
|
|
428
429
|
paddingLeft: "var(--size-controlHeight-md)",
|
|
429
430
|
height: "var(--size-controlHeight-md)"
|
|
430
431
|
}
|
|
431
432
|
})]
|
|
432
433
|
}),
|
|
433
|
-
/* @__PURE__ */
|
|
434
|
+
/* @__PURE__ */ T("div", {
|
|
434
435
|
className: "flex flex-wrap gap-control-gap",
|
|
435
436
|
children: [
|
|
436
|
-
/* @__PURE__ */
|
|
437
|
-
"aria-label":
|
|
438
|
-
value:
|
|
439
|
-
onChange: (e) =>
|
|
437
|
+
/* @__PURE__ */ T("select", {
|
|
438
|
+
"aria-label": v("bigconsole.dashboards.filters.category", "Category"),
|
|
439
|
+
value: O,
|
|
440
|
+
onChange: (e) => k(e.target.value),
|
|
440
441
|
className: "min-w-0 max-w-full rounded-button border border-border-subtle bg-bg-surface p-2 text-sm text-text-primary",
|
|
441
|
-
children: [/* @__PURE__ */
|
|
442
|
+
children: [/* @__PURE__ */ w("option", {
|
|
442
443
|
value: "",
|
|
443
|
-
children:
|
|
444
|
-
}),
|
|
444
|
+
children: v("bigconsole.dashboards.filters.allCategories", "All categories")
|
|
445
|
+
}), K.map((e) => /* @__PURE__ */ w("option", {
|
|
445
446
|
value: e,
|
|
446
447
|
children: e
|
|
447
448
|
}, e))]
|
|
448
449
|
}),
|
|
449
|
-
/* @__PURE__ */
|
|
450
|
-
"aria-label":
|
|
451
|
-
value:
|
|
452
|
-
onChange: (e) =>
|
|
450
|
+
/* @__PURE__ */ T("select", {
|
|
451
|
+
"aria-label": v("bigconsole.dashboards.filters.status", "Status"),
|
|
452
|
+
value: A,
|
|
453
|
+
onChange: (e) => Le(e.target.value),
|
|
453
454
|
className: "min-w-0 max-w-full rounded-button border border-border-subtle bg-bg-surface p-2 text-sm text-text-primary",
|
|
454
|
-
children: [/* @__PURE__ */
|
|
455
|
+
children: [/* @__PURE__ */ w("option", {
|
|
455
456
|
value: "",
|
|
456
|
-
children:
|
|
457
|
-
}), $.map((e) => /* @__PURE__ */
|
|
457
|
+
children: v("bigconsole.dashboards.filters.allStatuses", "All statuses")
|
|
458
|
+
}), $.map((e) => /* @__PURE__ */ w("option", {
|
|
458
459
|
value: e.value,
|
|
459
460
|
children: e.label
|
|
460
461
|
}, e.value))]
|
|
461
462
|
}),
|
|
462
|
-
/* @__PURE__ */
|
|
463
|
-
label:
|
|
464
|
-
value:
|
|
465
|
-
options:
|
|
466
|
-
onChange:
|
|
463
|
+
/* @__PURE__ */ w(a, {
|
|
464
|
+
label: v(oe.label.key, oe.label.en),
|
|
465
|
+
value: j,
|
|
466
|
+
options: ut,
|
|
467
|
+
onChange: Re
|
|
467
468
|
})
|
|
468
469
|
]
|
|
469
470
|
}),
|
|
470
|
-
|
|
471
|
+
L && z.length === 0 && /* @__PURE__ */ w("div", {
|
|
471
472
|
style: {
|
|
472
473
|
display: "flex",
|
|
473
474
|
alignItems: "center",
|
|
474
475
|
justifyContent: "center",
|
|
475
476
|
padding: "80px 0"
|
|
476
477
|
},
|
|
477
|
-
children: /* @__PURE__ */
|
|
478
|
+
children: /* @__PURE__ */ T("div", {
|
|
478
479
|
style: { textAlign: "center" },
|
|
479
|
-
children: [/* @__PURE__ */
|
|
480
|
+
children: [/* @__PURE__ */ w(C, { style: {
|
|
480
481
|
height: "var(--size-icon-xl)",
|
|
481
482
|
width: "var(--size-icon-xl)",
|
|
482
483
|
margin: "0 auto var(--space-formGap)"
|
|
483
|
-
} }), /* @__PURE__ */
|
|
484
|
+
} }), /* @__PURE__ */ w("p", {
|
|
484
485
|
style: {
|
|
485
486
|
fontSize: "var(--font-size-body-sm)",
|
|
486
487
|
color: "var(--color-text-muted)"
|
|
487
488
|
},
|
|
488
|
-
children:
|
|
489
|
+
children: v("bigconsole.dashboards.loading", "Loading dashboards...")
|
|
489
490
|
})]
|
|
490
491
|
})
|
|
491
492
|
}),
|
|
492
|
-
!
|
|
493
|
+
!L && I === "grid" && q.length > 0 && /* @__PURE__ */ w("div", {
|
|
493
494
|
style: {
|
|
494
495
|
display: "grid",
|
|
495
496
|
gridTemplateColumns: "repeat(auto-fill, minmax(min(320px, 100%), 1fr))",
|
|
496
497
|
gap: "var(--space-formGap)"
|
|
497
498
|
},
|
|
498
|
-
children:
|
|
499
|
-
onClick: () =>
|
|
499
|
+
children: Y.map((e) => /* @__PURE__ */ w(Oe, {
|
|
500
|
+
onClick: () => X(e.id),
|
|
500
501
|
style: { cursor: "pointer" },
|
|
501
502
|
className: "motion-safe:transition-[box-shadow,border-color] hover:border-[var(--color-border-hover)] hover:shadow-[var(--shadow-elevation-2)]",
|
|
502
|
-
children: /* @__PURE__ */
|
|
503
|
+
children: /* @__PURE__ */ T(ke, {
|
|
503
504
|
style: { padding: "var(--space-cardPadding)" },
|
|
504
505
|
children: [
|
|
505
|
-
/* @__PURE__ */
|
|
506
|
+
/* @__PURE__ */ T("div", {
|
|
506
507
|
style: {
|
|
507
508
|
display: "flex",
|
|
508
509
|
alignItems: "center",
|
|
509
510
|
gap: "var(--space-controlGap)",
|
|
510
511
|
marginBottom: "var(--space-formGap)"
|
|
511
512
|
},
|
|
512
|
-
children: [/* @__PURE__ */
|
|
513
|
+
children: [/* @__PURE__ */ w("div", {
|
|
513
514
|
style: {
|
|
514
515
|
display: "flex",
|
|
515
516
|
height: "var(--size-controlHeight-lg)",
|
|
@@ -520,7 +521,7 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
520
521
|
borderRadius: "var(--radius-button)",
|
|
521
522
|
backgroundColor: "var(--color-bg-accentSubtle)"
|
|
522
523
|
},
|
|
523
|
-
children: /* @__PURE__ */
|
|
524
|
+
children: /* @__PURE__ */ w(_, {
|
|
524
525
|
"aria-hidden": "true",
|
|
525
526
|
style: {
|
|
526
527
|
height: "var(--size-icon-md)",
|
|
@@ -528,12 +529,12 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
528
529
|
color: "var(--color-action-primary-bg)"
|
|
529
530
|
}
|
|
530
531
|
})
|
|
531
|
-
}), /* @__PURE__ */
|
|
532
|
+
}), /* @__PURE__ */ T("div", {
|
|
532
533
|
style: {
|
|
533
534
|
flex: 1,
|
|
534
535
|
minWidth: 0
|
|
535
536
|
},
|
|
536
|
-
children: [/* @__PURE__ */
|
|
537
|
+
children: [/* @__PURE__ */ w("h3", {
|
|
537
538
|
style: {
|
|
538
539
|
fontWeight: "var(--font-weight-bold)",
|
|
539
540
|
fontSize: "var(--font-size-body-md)",
|
|
@@ -543,15 +544,15 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
543
544
|
textOverflow: "ellipsis",
|
|
544
545
|
whiteSpace: "nowrap"
|
|
545
546
|
},
|
|
546
|
-
children: /* @__PURE__ */
|
|
547
|
+
children: /* @__PURE__ */ w("button", {
|
|
547
548
|
type: "button",
|
|
548
549
|
className: "max-w-full truncate text-left hover:underline focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]",
|
|
549
550
|
onClick: (t) => {
|
|
550
|
-
t.stopPropagation(),
|
|
551
|
+
t.stopPropagation(), X(e.id);
|
|
551
552
|
},
|
|
552
553
|
children: e.name
|
|
553
554
|
})
|
|
554
|
-
}), /* @__PURE__ */
|
|
555
|
+
}), /* @__PURE__ */ T("div", {
|
|
555
556
|
style: {
|
|
556
557
|
display: "flex",
|
|
557
558
|
alignItems: "center",
|
|
@@ -559,7 +560,7 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
559
560
|
flexWrap: "wrap",
|
|
560
561
|
marginTop: "var(--space-controlGap)"
|
|
561
562
|
},
|
|
562
|
-
children: [e.category && /* @__PURE__ */
|
|
563
|
+
children: [e.category && /* @__PURE__ */ w(y, {
|
|
563
564
|
variant: "secondary",
|
|
564
565
|
style: {
|
|
565
566
|
fontSize: "10px",
|
|
@@ -567,14 +568,14 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
567
568
|
textTransform: "uppercase"
|
|
568
569
|
},
|
|
569
570
|
children: e.category
|
|
570
|
-
}), e.status && /* @__PURE__ */
|
|
571
|
+
}), e.status && /* @__PURE__ */ w(c, {
|
|
571
572
|
status: e.status,
|
|
572
573
|
label: Q(e.status)
|
|
573
574
|
})]
|
|
574
575
|
})]
|
|
575
576
|
})]
|
|
576
577
|
}),
|
|
577
|
-
/* @__PURE__ */
|
|
578
|
+
/* @__PURE__ */ w("p", {
|
|
578
579
|
style: {
|
|
579
580
|
fontSize: "var(--font-size-body-sm)",
|
|
580
581
|
lineHeight: "var(--font-lineHeight-normal)",
|
|
@@ -586,9 +587,9 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
586
587
|
WebkitBoxOrient: "vertical",
|
|
587
588
|
overflow: "hidden"
|
|
588
589
|
},
|
|
589
|
-
children: e.description ||
|
|
590
|
+
children: e.description || v("bigconsole.dashboards.card.noDescription", "No description provided")
|
|
590
591
|
}),
|
|
591
|
-
/* @__PURE__ */
|
|
592
|
+
/* @__PURE__ */ T("div", {
|
|
592
593
|
style: {
|
|
593
594
|
display: "flex",
|
|
594
595
|
alignItems: "center",
|
|
@@ -599,72 +600,72 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
599
600
|
borderRadius: "var(--radius-button)"
|
|
600
601
|
},
|
|
601
602
|
children: [
|
|
602
|
-
/* @__PURE__ */
|
|
603
|
+
/* @__PURE__ */ T("div", {
|
|
603
604
|
style: {
|
|
604
605
|
display: "flex",
|
|
605
606
|
alignItems: "center",
|
|
606
607
|
gap: "var(--space-iconGap)"
|
|
607
608
|
},
|
|
608
609
|
children: [
|
|
609
|
-
/* @__PURE__ */
|
|
610
|
+
/* @__PURE__ */ w(be, { style: {
|
|
610
611
|
height: "var(--size-icon-sm)",
|
|
611
612
|
width: "var(--size-icon-sm)",
|
|
612
613
|
color: "var(--color-action-primary-bg)"
|
|
613
614
|
} }),
|
|
614
|
-
/* @__PURE__ */
|
|
615
|
+
/* @__PURE__ */ w("span", {
|
|
615
616
|
style: {
|
|
616
617
|
fontSize: "var(--font-size-body-sm)",
|
|
617
618
|
fontWeight: "var(--font-weight-semibold)",
|
|
618
619
|
color: "var(--color-text-primary)"
|
|
619
620
|
},
|
|
620
|
-
children:
|
|
621
|
+
children: ft(e)
|
|
621
622
|
}),
|
|
622
|
-
/* @__PURE__ */
|
|
623
|
+
/* @__PURE__ */ w("span", {
|
|
623
624
|
style: {
|
|
624
625
|
fontSize: "var(--font-size-body-sm)",
|
|
625
626
|
color: "var(--color-text-muted)"
|
|
626
627
|
},
|
|
627
|
-
children:
|
|
628
|
+
children: v("bigconsole.dashboards.card.pages", "pages")
|
|
628
629
|
})
|
|
629
630
|
]
|
|
630
631
|
}),
|
|
631
|
-
/* @__PURE__ */
|
|
632
|
+
/* @__PURE__ */ w("div", { style: {
|
|
632
633
|
width: "1px",
|
|
633
634
|
height: "var(--size-icon-sm)",
|
|
634
635
|
backgroundColor: "var(--color-border-subtle)"
|
|
635
636
|
} }),
|
|
636
|
-
/* @__PURE__ */
|
|
637
|
+
/* @__PURE__ */ T("div", {
|
|
637
638
|
style: {
|
|
638
639
|
display: "flex",
|
|
639
640
|
alignItems: "center",
|
|
640
641
|
gap: "var(--space-iconGap)"
|
|
641
642
|
},
|
|
642
643
|
children: [
|
|
643
|
-
/* @__PURE__ */
|
|
644
|
+
/* @__PURE__ */ w(ye, { style: {
|
|
644
645
|
height: "var(--size-icon-sm)",
|
|
645
646
|
width: "var(--size-icon-sm)",
|
|
646
647
|
color: "var(--color-action-primary-bg)"
|
|
647
648
|
} }),
|
|
648
|
-
/* @__PURE__ */
|
|
649
|
+
/* @__PURE__ */ w("span", {
|
|
649
650
|
style: {
|
|
650
651
|
fontSize: "var(--font-size-body-sm)",
|
|
651
652
|
fontWeight: "var(--font-weight-semibold)",
|
|
652
653
|
color: "var(--color-text-primary)"
|
|
653
654
|
},
|
|
654
|
-
children:
|
|
655
|
+
children: dt(e)
|
|
655
656
|
}),
|
|
656
|
-
/* @__PURE__ */
|
|
657
|
+
/* @__PURE__ */ w("span", {
|
|
657
658
|
style: {
|
|
658
659
|
fontSize: "var(--font-size-body-sm)",
|
|
659
660
|
color: "var(--color-text-muted)"
|
|
660
661
|
},
|
|
661
|
-
children:
|
|
662
|
+
children: v("bigconsole.dashboards.card.widgets", "widgets")
|
|
662
663
|
})
|
|
663
664
|
]
|
|
664
665
|
})
|
|
665
666
|
]
|
|
666
667
|
}),
|
|
667
|
-
/* @__PURE__ */
|
|
668
|
+
/* @__PURE__ */ T("div", {
|
|
668
669
|
style: {
|
|
669
670
|
display: "flex",
|
|
670
671
|
alignItems: "center",
|
|
@@ -674,78 +675,78 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
674
675
|
paddingTop: "var(--space-controlGap)",
|
|
675
676
|
borderTop: "1px solid var(--color-border-subtle)"
|
|
676
677
|
},
|
|
677
|
-
children: [/* @__PURE__ */
|
|
678
|
+
children: [/* @__PURE__ */ T("div", {
|
|
678
679
|
style: {
|
|
679
680
|
display: "flex",
|
|
680
681
|
alignItems: "center",
|
|
681
682
|
gap: "var(--space-iconGap)"
|
|
682
683
|
},
|
|
683
|
-
children: [/* @__PURE__ */
|
|
684
|
+
children: [/* @__PURE__ */ w(he, { style: {
|
|
684
685
|
height: "var(--size-icon-sm)",
|
|
685
686
|
width: "var(--size-icon-sm)",
|
|
686
687
|
color: "var(--color-text-muted)"
|
|
687
|
-
} }), /* @__PURE__ */
|
|
688
|
+
} }), /* @__PURE__ */ w("span", {
|
|
688
689
|
style: {
|
|
689
690
|
fontSize: "var(--font-size-body-sm)",
|
|
690
691
|
fontWeight: "var(--font-weight-medium)",
|
|
691
692
|
color: "var(--color-text-muted)"
|
|
692
693
|
},
|
|
693
|
-
children:
|
|
694
|
+
children: lt(e.updatedAt)
|
|
694
695
|
})]
|
|
695
|
-
}), /* @__PURE__ */
|
|
696
|
+
}), /* @__PURE__ */ T("div", {
|
|
696
697
|
style: {
|
|
697
698
|
display: "flex",
|
|
698
699
|
alignItems: "center",
|
|
699
700
|
gap: "var(--space-controlGap)"
|
|
700
701
|
},
|
|
701
702
|
children: [
|
|
702
|
-
/* @__PURE__ */
|
|
703
|
-
permission:
|
|
703
|
+
/* @__PURE__ */ w(g, {
|
|
704
|
+
permission: s.DASHBOARD_UPDATE,
|
|
704
705
|
deniedBehavior: "hide",
|
|
705
|
-
children: /* @__PURE__ */
|
|
706
|
+
children: /* @__PURE__ */ w(b, {
|
|
706
707
|
variant: "ghost",
|
|
707
708
|
size: "sm",
|
|
708
|
-
onClick: (t) =>
|
|
709
|
+
onClick: (t) => Z(e.id, t),
|
|
709
710
|
style: {
|
|
710
711
|
height: "var(--size-controlHeight-md)",
|
|
711
712
|
width: "var(--size-controlHeight-md)",
|
|
712
713
|
padding: 0,
|
|
713
714
|
borderRadius: "var(--radius-button)"
|
|
714
715
|
},
|
|
715
|
-
title:
|
|
716
|
-
children: /* @__PURE__ */
|
|
716
|
+
title: v("bigconsole.dashboards.actions.editTitle", "Edit Dashboard"),
|
|
717
|
+
children: /* @__PURE__ */ w(Ce, { style: {
|
|
717
718
|
height: "var(--size-icon-sm)",
|
|
718
719
|
width: "var(--size-icon-sm)"
|
|
719
720
|
} })
|
|
720
721
|
})
|
|
721
722
|
}),
|
|
722
|
-
/* @__PURE__ */
|
|
723
|
-
permission:
|
|
723
|
+
/* @__PURE__ */ w(g, {
|
|
724
|
+
permission: s.DASHBOARD_CREATE,
|
|
724
725
|
deniedBehavior: "hide",
|
|
725
|
-
children: /* @__PURE__ */
|
|
726
|
+
children: /* @__PURE__ */ w(b, {
|
|
726
727
|
variant: "ghost",
|
|
727
728
|
size: "sm",
|
|
728
|
-
onClick: (t) =>
|
|
729
|
+
onClick: (t) => at(e.id, e.name, t),
|
|
729
730
|
style: {
|
|
730
731
|
height: "var(--size-controlHeight-md)",
|
|
731
732
|
width: "var(--size-controlHeight-md)",
|
|
732
733
|
padding: 0,
|
|
733
734
|
borderRadius: "var(--radius-button)"
|
|
734
735
|
},
|
|
735
|
-
title:
|
|
736
|
-
children: /* @__PURE__ */
|
|
736
|
+
title: v("bigconsole.dashboards.actions.cloneTitle", "Clone Dashboard"),
|
|
737
|
+
children: /* @__PURE__ */ w(ve, { style: {
|
|
737
738
|
height: "var(--size-icon-sm)",
|
|
738
739
|
width: "var(--size-icon-sm)"
|
|
739
740
|
} })
|
|
740
741
|
})
|
|
741
742
|
}),
|
|
742
|
-
/* @__PURE__ */
|
|
743
|
-
permission:
|
|
743
|
+
/* @__PURE__ */ w(g, {
|
|
744
|
+
permission: s.DASHBOARD_DELETE,
|
|
744
745
|
deniedBehavior: "hide",
|
|
745
|
-
children: /* @__PURE__ */
|
|
746
|
+
children: /* @__PURE__ */ w(b, {
|
|
746
747
|
variant: "ghost",
|
|
747
748
|
size: "sm",
|
|
748
|
-
onClick: (t) =>
|
|
749
|
+
onClick: (t) => it(e.id, t),
|
|
749
750
|
style: {
|
|
750
751
|
height: "var(--size-controlHeight-md)",
|
|
751
752
|
width: "var(--size-controlHeight-md)",
|
|
@@ -753,8 +754,8 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
753
754
|
borderRadius: "var(--radius-button)"
|
|
754
755
|
},
|
|
755
756
|
className: "hover:text-status-error-text hover:bg-status-error-bg/10",
|
|
756
|
-
title:
|
|
757
|
-
children: /* @__PURE__ */
|
|
757
|
+
title: v("bigconsole.dashboards.actions.deleteTitle", "Delete Dashboard"),
|
|
758
|
+
children: /* @__PURE__ */ w(Ee, { style: {
|
|
758
759
|
height: "var(--size-icon-sm)",
|
|
759
760
|
width: "var(--size-icon-sm)"
|
|
760
761
|
} })
|
|
@@ -767,19 +768,19 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
767
768
|
})
|
|
768
769
|
}, e.id))
|
|
769
770
|
}),
|
|
770
|
-
!
|
|
771
|
+
!L && I === "list" && q.length > 0 && /* @__PURE__ */ w("div", {
|
|
771
772
|
style: {
|
|
772
773
|
display: "flex",
|
|
773
774
|
flexDirection: "column",
|
|
774
775
|
gap: "var(--space-controlGap)"
|
|
775
776
|
},
|
|
776
|
-
children:
|
|
777
|
-
onClick: () =>
|
|
777
|
+
children: Y.map((e) => /* @__PURE__ */ w(Oe, {
|
|
778
|
+
onClick: () => X(e.id),
|
|
778
779
|
style: { cursor: "pointer" },
|
|
779
780
|
className: "motion-safe:transition-[box-shadow,border-color] hover:border-[var(--color-border-hover)] hover:shadow-[var(--shadow-elevation-2)]",
|
|
780
|
-
children: /* @__PURE__ */
|
|
781
|
+
children: /* @__PURE__ */ w(ke, {
|
|
781
782
|
style: { padding: "var(--space-cardPadding)" },
|
|
782
|
-
children: /* @__PURE__ */
|
|
783
|
+
children: /* @__PURE__ */ T("div", {
|
|
783
784
|
style: {
|
|
784
785
|
display: "flex",
|
|
785
786
|
alignItems: "center",
|
|
@@ -787,7 +788,7 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
787
788
|
flexWrap: "wrap"
|
|
788
789
|
},
|
|
789
790
|
children: [
|
|
790
|
-
/* @__PURE__ */
|
|
791
|
+
/* @__PURE__ */ w("div", {
|
|
791
792
|
style: {
|
|
792
793
|
display: "flex",
|
|
793
794
|
height: "var(--size-controlHeight-lg)",
|
|
@@ -798,7 +799,7 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
798
799
|
borderRadius: "var(--radius-button)",
|
|
799
800
|
backgroundColor: "var(--color-bg-accentSubtle)"
|
|
800
801
|
},
|
|
801
|
-
children: /* @__PURE__ */
|
|
802
|
+
children: /* @__PURE__ */ w(_, {
|
|
802
803
|
"aria-hidden": "true",
|
|
803
804
|
style: {
|
|
804
805
|
height: "var(--size-icon-md)",
|
|
@@ -807,12 +808,12 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
807
808
|
}
|
|
808
809
|
})
|
|
809
810
|
}),
|
|
810
|
-
/* @__PURE__ */
|
|
811
|
+
/* @__PURE__ */ T("div", {
|
|
811
812
|
style: {
|
|
812
813
|
flex: "1 1 12rem",
|
|
813
814
|
minWidth: 0
|
|
814
815
|
},
|
|
815
|
-
children: [/* @__PURE__ */
|
|
816
|
+
children: [/* @__PURE__ */ T("div", {
|
|
816
817
|
style: {
|
|
817
818
|
display: "flex",
|
|
818
819
|
alignItems: "center",
|
|
@@ -820,7 +821,7 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
820
821
|
flexWrap: "wrap"
|
|
821
822
|
},
|
|
822
823
|
children: [
|
|
823
|
-
/* @__PURE__ */
|
|
824
|
+
/* @__PURE__ */ w("h3", {
|
|
824
825
|
style: {
|
|
825
826
|
fontWeight: "var(--font-weight-bold)",
|
|
826
827
|
fontSize: "var(--font-size-body-md)",
|
|
@@ -831,16 +832,16 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
831
832
|
whiteSpace: "nowrap",
|
|
832
833
|
maxWidth: "100%"
|
|
833
834
|
},
|
|
834
|
-
children: /* @__PURE__ */
|
|
835
|
+
children: /* @__PURE__ */ w("button", {
|
|
835
836
|
type: "button",
|
|
836
837
|
className: "max-w-full truncate text-left hover:underline focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]",
|
|
837
838
|
onClick: (t) => {
|
|
838
|
-
t.stopPropagation(),
|
|
839
|
+
t.stopPropagation(), X(e.id);
|
|
839
840
|
},
|
|
840
841
|
children: e.name
|
|
841
842
|
})
|
|
842
843
|
}),
|
|
843
|
-
e.category && /* @__PURE__ */
|
|
844
|
+
e.category && /* @__PURE__ */ w(y, {
|
|
844
845
|
variant: "secondary",
|
|
845
846
|
style: {
|
|
846
847
|
fontSize: "10px",
|
|
@@ -849,12 +850,12 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
849
850
|
},
|
|
850
851
|
children: e.category
|
|
851
852
|
}),
|
|
852
|
-
e.status && /* @__PURE__ */
|
|
853
|
+
e.status && /* @__PURE__ */ w(c, {
|
|
853
854
|
status: e.status,
|
|
854
855
|
label: Q(e.status)
|
|
855
856
|
})
|
|
856
857
|
]
|
|
857
|
-
}), /* @__PURE__ */
|
|
858
|
+
}), /* @__PURE__ */ w("p", {
|
|
858
859
|
style: {
|
|
859
860
|
fontSize: "var(--font-size-body-sm)",
|
|
860
861
|
lineHeight: "var(--font-lineHeight-normal)",
|
|
@@ -864,10 +865,10 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
864
865
|
textOverflow: "ellipsis",
|
|
865
866
|
whiteSpace: "nowrap"
|
|
866
867
|
},
|
|
867
|
-
children: e.description ||
|
|
868
|
+
children: e.description || v("bigconsole.dashboards.card.noDescription", "No description provided")
|
|
868
869
|
})]
|
|
869
870
|
}),
|
|
870
|
-
/* @__PURE__ */
|
|
871
|
+
/* @__PURE__ */ T("div", {
|
|
871
872
|
style: {
|
|
872
873
|
display: "flex",
|
|
873
874
|
alignItems: "center",
|
|
@@ -875,139 +876,139 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
875
876
|
flexWrap: "wrap"
|
|
876
877
|
},
|
|
877
878
|
children: [
|
|
878
|
-
/* @__PURE__ */
|
|
879
|
+
/* @__PURE__ */ T("div", {
|
|
879
880
|
style: {
|
|
880
881
|
display: "flex",
|
|
881
882
|
alignItems: "center",
|
|
882
883
|
gap: "var(--space-iconGap)"
|
|
883
884
|
},
|
|
884
885
|
children: [
|
|
885
|
-
/* @__PURE__ */
|
|
886
|
+
/* @__PURE__ */ w(be, { style: {
|
|
886
887
|
height: "var(--size-icon-sm)",
|
|
887
888
|
width: "var(--size-icon-sm)",
|
|
888
889
|
color: "var(--color-action-primary-bg)"
|
|
889
890
|
} }),
|
|
890
|
-
/* @__PURE__ */
|
|
891
|
+
/* @__PURE__ */ w("span", {
|
|
891
892
|
style: {
|
|
892
893
|
fontSize: "var(--font-size-body-sm)",
|
|
893
894
|
fontWeight: "var(--font-weight-semibold)",
|
|
894
895
|
color: "var(--color-text-primary)"
|
|
895
896
|
},
|
|
896
|
-
children:
|
|
897
|
+
children: ft(e)
|
|
897
898
|
}),
|
|
898
|
-
/* @__PURE__ */
|
|
899
|
+
/* @__PURE__ */ w("span", {
|
|
899
900
|
style: {
|
|
900
901
|
fontSize: "var(--font-size-body-sm)",
|
|
901
902
|
color: "var(--color-text-muted)"
|
|
902
903
|
},
|
|
903
|
-
children:
|
|
904
|
+
children: v("bigconsole.dashboards.card.pages", "pages")
|
|
904
905
|
})
|
|
905
906
|
]
|
|
906
907
|
}),
|
|
907
|
-
/* @__PURE__ */
|
|
908
|
+
/* @__PURE__ */ T("div", {
|
|
908
909
|
style: {
|
|
909
910
|
display: "flex",
|
|
910
911
|
alignItems: "center",
|
|
911
912
|
gap: "var(--space-iconGap)"
|
|
912
913
|
},
|
|
913
914
|
children: [
|
|
914
|
-
/* @__PURE__ */
|
|
915
|
+
/* @__PURE__ */ w(ye, { style: {
|
|
915
916
|
height: "var(--size-icon-sm)",
|
|
916
917
|
width: "var(--size-icon-sm)",
|
|
917
918
|
color: "var(--color-action-primary-bg)"
|
|
918
919
|
} }),
|
|
919
|
-
/* @__PURE__ */
|
|
920
|
+
/* @__PURE__ */ w("span", {
|
|
920
921
|
style: {
|
|
921
922
|
fontSize: "var(--font-size-body-sm)",
|
|
922
923
|
fontWeight: "var(--font-weight-semibold)",
|
|
923
924
|
color: "var(--color-text-primary)"
|
|
924
925
|
},
|
|
925
|
-
children:
|
|
926
|
+
children: dt(e)
|
|
926
927
|
}),
|
|
927
|
-
/* @__PURE__ */
|
|
928
|
+
/* @__PURE__ */ w("span", {
|
|
928
929
|
style: {
|
|
929
930
|
fontSize: "var(--font-size-body-sm)",
|
|
930
931
|
color: "var(--color-text-muted)"
|
|
931
932
|
},
|
|
932
|
-
children:
|
|
933
|
+
children: v("bigconsole.dashboards.card.widgets", "widgets")
|
|
933
934
|
})
|
|
934
935
|
]
|
|
935
936
|
}),
|
|
936
|
-
/* @__PURE__ */
|
|
937
|
+
/* @__PURE__ */ T("div", {
|
|
937
938
|
style: {
|
|
938
939
|
display: "flex",
|
|
939
940
|
alignItems: "center",
|
|
940
941
|
gap: "var(--space-iconGap)"
|
|
941
942
|
},
|
|
942
|
-
children: [/* @__PURE__ */
|
|
943
|
+
children: [/* @__PURE__ */ w(he, { style: {
|
|
943
944
|
height: "var(--size-icon-sm)",
|
|
944
945
|
width: "var(--size-icon-sm)",
|
|
945
946
|
color: "var(--color-text-muted)"
|
|
946
|
-
} }), /* @__PURE__ */
|
|
947
|
+
} }), /* @__PURE__ */ w("span", {
|
|
947
948
|
style: {
|
|
948
949
|
fontSize: "var(--font-size-body-sm)",
|
|
949
950
|
fontWeight: "var(--font-weight-medium)",
|
|
950
951
|
color: "var(--color-text-muted)"
|
|
951
952
|
},
|
|
952
|
-
children:
|
|
953
|
+
children: lt(e.updatedAt)
|
|
953
954
|
})]
|
|
954
955
|
})
|
|
955
956
|
]
|
|
956
957
|
}),
|
|
957
|
-
/* @__PURE__ */
|
|
958
|
+
/* @__PURE__ */ T("div", {
|
|
958
959
|
style: {
|
|
959
960
|
display: "flex",
|
|
960
961
|
alignItems: "center",
|
|
961
962
|
gap: "var(--space-controlGap)"
|
|
962
963
|
},
|
|
963
964
|
children: [
|
|
964
|
-
/* @__PURE__ */
|
|
965
|
-
permission:
|
|
965
|
+
/* @__PURE__ */ w(g, {
|
|
966
|
+
permission: s.DASHBOARD_UPDATE,
|
|
966
967
|
deniedBehavior: "hide",
|
|
967
|
-
children: /* @__PURE__ */
|
|
968
|
+
children: /* @__PURE__ */ w(b, {
|
|
968
969
|
variant: "ghost",
|
|
969
970
|
size: "sm",
|
|
970
|
-
onClick: (t) =>
|
|
971
|
+
onClick: (t) => Z(e.id, t),
|
|
971
972
|
style: {
|
|
972
973
|
height: "var(--size-controlHeight-md)",
|
|
973
974
|
width: "var(--size-controlHeight-md)",
|
|
974
975
|
padding: 0,
|
|
975
976
|
borderRadius: "var(--radius-button)"
|
|
976
977
|
},
|
|
977
|
-
title:
|
|
978
|
-
children: /* @__PURE__ */
|
|
978
|
+
title: v("bigconsole.dashboards.actions.editTitle", "Edit Dashboard"),
|
|
979
|
+
children: /* @__PURE__ */ w(Ce, { style: {
|
|
979
980
|
height: "var(--size-icon-sm)",
|
|
980
981
|
width: "var(--size-icon-sm)"
|
|
981
982
|
} })
|
|
982
983
|
})
|
|
983
984
|
}),
|
|
984
|
-
/* @__PURE__ */
|
|
985
|
-
permission:
|
|
985
|
+
/* @__PURE__ */ w(g, {
|
|
986
|
+
permission: s.DASHBOARD_CREATE,
|
|
986
987
|
deniedBehavior: "hide",
|
|
987
|
-
children: /* @__PURE__ */
|
|
988
|
+
children: /* @__PURE__ */ w(b, {
|
|
988
989
|
variant: "ghost",
|
|
989
990
|
size: "sm",
|
|
990
|
-
onClick: (t) =>
|
|
991
|
+
onClick: (t) => at(e.id, e.name, t),
|
|
991
992
|
style: {
|
|
992
993
|
height: "var(--size-controlHeight-md)",
|
|
993
994
|
width: "var(--size-controlHeight-md)",
|
|
994
995
|
padding: 0,
|
|
995
996
|
borderRadius: "var(--radius-button)"
|
|
996
997
|
},
|
|
997
|
-
title:
|
|
998
|
-
children: /* @__PURE__ */
|
|
998
|
+
title: v("bigconsole.dashboards.actions.cloneTitle", "Clone Dashboard"),
|
|
999
|
+
children: /* @__PURE__ */ w(ve, { style: {
|
|
999
1000
|
height: "var(--size-icon-sm)",
|
|
1000
1001
|
width: "var(--size-icon-sm)"
|
|
1001
1002
|
} })
|
|
1002
1003
|
})
|
|
1003
1004
|
}),
|
|
1004
|
-
/* @__PURE__ */
|
|
1005
|
-
permission:
|
|
1005
|
+
/* @__PURE__ */ w(g, {
|
|
1006
|
+
permission: s.DASHBOARD_DELETE,
|
|
1006
1007
|
deniedBehavior: "hide",
|
|
1007
|
-
children: /* @__PURE__ */
|
|
1008
|
+
children: /* @__PURE__ */ w(b, {
|
|
1008
1009
|
variant: "ghost",
|
|
1009
1010
|
size: "sm",
|
|
1010
|
-
onClick: (t) =>
|
|
1011
|
+
onClick: (t) => it(e.id, t),
|
|
1011
1012
|
style: {
|
|
1012
1013
|
height: "var(--size-controlHeight-md)",
|
|
1013
1014
|
width: "var(--size-controlHeight-md)",
|
|
@@ -1015,8 +1016,8 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
1015
1016
|
borderRadius: "var(--radius-button)"
|
|
1016
1017
|
},
|
|
1017
1018
|
className: "hover:text-status-error-text hover:bg-status-error-bg/10",
|
|
1018
|
-
title:
|
|
1019
|
-
children: /* @__PURE__ */
|
|
1019
|
+
title: v("bigconsole.dashboards.actions.deleteTitle", "Delete Dashboard"),
|
|
1020
|
+
children: /* @__PURE__ */ w(Ee, { style: {
|
|
1020
1021
|
height: "var(--size-icon-sm)",
|
|
1021
1022
|
width: "var(--size-icon-sm)"
|
|
1022
1023
|
} })
|
|
@@ -1029,56 +1030,56 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
1029
1030
|
})
|
|
1030
1031
|
}, e.id))
|
|
1031
1032
|
}),
|
|
1032
|
-
!
|
|
1033
|
+
!L && q.length > 0 && /* @__PURE__ */ w("p", {
|
|
1033
1034
|
"data-testid": "dashboards-range",
|
|
1034
1035
|
style: {
|
|
1035
1036
|
margin: 0,
|
|
1036
1037
|
fontSize: "var(--font-size-body-sm)",
|
|
1037
1038
|
color: "var(--color-text-muted)"
|
|
1038
1039
|
},
|
|
1039
|
-
children:
|
|
1040
|
-
from:
|
|
1041
|
-
to:
|
|
1042
|
-
total:
|
|
1040
|
+
children: v("bigconsole.dashboards.pagination.range", "Showing {{from}}–{{to}} of {{total}} dashboards", {
|
|
1041
|
+
from: Xe + 1,
|
|
1042
|
+
to: Xe + Y.length,
|
|
1043
|
+
total: q.length
|
|
1043
1044
|
})
|
|
1044
1045
|
}),
|
|
1045
|
-
!
|
|
1046
|
-
"aria-label":
|
|
1046
|
+
!L && q.length > D && /* @__PURE__ */ T("nav", {
|
|
1047
|
+
"aria-label": v("bigconsole.dashboards.pagination.label", "Dashboard pages"),
|
|
1047
1048
|
className: "flex flex-wrap items-center justify-center gap-control-gap border-t border-[var(--color-border-subtle)] pt-control-gap",
|
|
1048
1049
|
children: [
|
|
1049
|
-
/* @__PURE__ */
|
|
1050
|
+
/* @__PURE__ */ T(b, {
|
|
1050
1051
|
variant: "outline",
|
|
1051
1052
|
size: "sm",
|
|
1052
|
-
onClick:
|
|
1053
|
-
disabled:
|
|
1054
|
-
"aria-label":
|
|
1053
|
+
onClick: Ze,
|
|
1054
|
+
disabled: M <= 1,
|
|
1055
|
+
"aria-label": v("bigconsole.dashboards.pagination.previous", "Previous"),
|
|
1055
1056
|
style: { minHeight: "var(--size-controlHeight-md)" },
|
|
1056
|
-
children: [/* @__PURE__ */
|
|
1057
|
+
children: [/* @__PURE__ */ w(ge, { style: {
|
|
1057
1058
|
marginRight: "var(--space-iconGap)",
|
|
1058
1059
|
height: "var(--size-icon-sm)",
|
|
1059
1060
|
width: "var(--size-icon-sm)"
|
|
1060
|
-
} }),
|
|
1061
|
+
} }), v("bigconsole.dashboards.pagination.previous", "Previous")]
|
|
1061
1062
|
}),
|
|
1062
|
-
/* @__PURE__ */
|
|
1063
|
+
/* @__PURE__ */ w("div", {
|
|
1063
1064
|
style: {
|
|
1064
1065
|
display: "flex",
|
|
1065
1066
|
alignItems: "center",
|
|
1066
1067
|
gap: "var(--space-iconGap)",
|
|
1067
1068
|
flexWrap: "wrap"
|
|
1068
1069
|
},
|
|
1069
|
-
children:
|
|
1070
|
+
children: Fe(M, J).map((e, t) => e === null ? /* @__PURE__ */ w("span", {
|
|
1070
1071
|
"aria-hidden": "true",
|
|
1071
1072
|
style: {
|
|
1072
1073
|
color: "var(--color-text-muted)",
|
|
1073
1074
|
padding: "0 var(--space-iconGap)"
|
|
1074
1075
|
},
|
|
1075
1076
|
children: "…"
|
|
1076
|
-
}, `gap-${t}`) : /* @__PURE__ */
|
|
1077
|
-
variant: e ===
|
|
1077
|
+
}, `gap-${t}`) : /* @__PURE__ */ w(b, {
|
|
1078
|
+
variant: e === M ? "default" : "ghost",
|
|
1078
1079
|
size: "sm",
|
|
1079
|
-
onClick: () =>
|
|
1080
|
-
"aria-current": e ===
|
|
1081
|
-
"aria-label":
|
|
1080
|
+
onClick: () => $e(e),
|
|
1081
|
+
"aria-current": e === M ? "page" : void 0,
|
|
1082
|
+
"aria-label": v("bigconsole.dashboards.pagination.page", `Page ${e}`),
|
|
1082
1083
|
style: {
|
|
1083
1084
|
minWidth: "var(--size-controlHeight-md)",
|
|
1084
1085
|
height: "var(--size-controlHeight-md)",
|
|
@@ -1088,67 +1089,67 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
1088
1089
|
children: e
|
|
1089
1090
|
}, e))
|
|
1090
1091
|
}),
|
|
1091
|
-
/* @__PURE__ */
|
|
1092
|
+
/* @__PURE__ */ T(b, {
|
|
1092
1093
|
variant: "outline",
|
|
1093
1094
|
size: "sm",
|
|
1094
|
-
onClick:
|
|
1095
|
-
disabled:
|
|
1096
|
-
"aria-label":
|
|
1095
|
+
onClick: Qe,
|
|
1096
|
+
disabled: M >= J,
|
|
1097
|
+
"aria-label": v("bigconsole.dashboards.pagination.next", "Next"),
|
|
1097
1098
|
style: { minHeight: "var(--size-controlHeight-md)" },
|
|
1098
|
-
children: [
|
|
1099
|
+
children: [v("bigconsole.dashboards.pagination.next", "Next"), /* @__PURE__ */ w(_e, { style: {
|
|
1099
1100
|
marginLeft: "var(--space-iconGap)",
|
|
1100
1101
|
height: "var(--size-icon-sm)",
|
|
1101
1102
|
width: "var(--size-icon-sm)"
|
|
1102
1103
|
} })]
|
|
1103
1104
|
}),
|
|
1104
|
-
/* @__PURE__ */
|
|
1105
|
+
/* @__PURE__ */ w("span", {
|
|
1105
1106
|
style: {
|
|
1106
1107
|
fontSize: "var(--font-size-body-sm)",
|
|
1107
1108
|
color: "var(--color-text-muted)"
|
|
1108
1109
|
},
|
|
1109
|
-
children:
|
|
1110
|
-
currentPage:
|
|
1111
|
-
totalPages:
|
|
1110
|
+
children: v("bigconsole.dashboards.pagination.pageOf", "Page {{currentPage}} of {{totalPages}}", {
|
|
1111
|
+
currentPage: M,
|
|
1112
|
+
totalPages: J
|
|
1112
1113
|
})
|
|
1113
1114
|
})
|
|
1114
1115
|
]
|
|
1115
1116
|
}),
|
|
1116
|
-
!
|
|
1117
|
+
!L && q.length === 0 && /* @__PURE__ */ w(Ae, {
|
|
1117
1118
|
treatment: "insight",
|
|
1118
1119
|
className: "border-[var(--color-border-seam)]",
|
|
1119
|
-
children: /* @__PURE__ */
|
|
1120
|
-
illustration:
|
|
1121
|
-
title:
|
|
1122
|
-
description:
|
|
1123
|
-
action:
|
|
1120
|
+
children: /* @__PURE__ */ w(je, {
|
|
1121
|
+
illustration: x ? "empty-search" : "empty-data",
|
|
1122
|
+
title: x ? v("bigconsole.dashboards.empty.filteredTitle", "No dashboards found") : v("bigconsole.dashboards.empty.title", "No dashboards yet"),
|
|
1123
|
+
description: x ? v("bigconsole.dashboards.empty.filteredDescription", "Try adjusting your search terms") : v("bigconsole.dashboards.empty.description", "Get started by creating your first dashboard to visualize your data"),
|
|
1124
|
+
action: x ? void 0 : /* @__PURE__ */ T("div", {
|
|
1124
1125
|
style: {
|
|
1125
1126
|
display: "flex",
|
|
1126
1127
|
gap: "var(--space-controlGap)",
|
|
1127
1128
|
flexWrap: "wrap",
|
|
1128
1129
|
justifyContent: "center"
|
|
1129
1130
|
},
|
|
1130
|
-
children: [/* @__PURE__ */
|
|
1131
|
-
permission:
|
|
1131
|
+
children: [/* @__PURE__ */ w(g, {
|
|
1132
|
+
permission: s.DASHBOARD_CREATE,
|
|
1132
1133
|
deniedBehavior: "hide",
|
|
1133
|
-
children: /* @__PURE__ */
|
|
1134
|
-
onClick:
|
|
1135
|
-
children: [/* @__PURE__ */
|
|
1134
|
+
children: /* @__PURE__ */ T(b, {
|
|
1135
|
+
onClick: et,
|
|
1136
|
+
children: [/* @__PURE__ */ w(we, { style: {
|
|
1136
1137
|
marginRight: "var(--space-iconGap)",
|
|
1137
1138
|
height: "var(--size-icon-sm)",
|
|
1138
1139
|
width: "var(--size-icon-sm)"
|
|
1139
|
-
} }),
|
|
1140
|
+
} }), v("bigconsole.dashboards.actions.create", "Create Dashboard")]
|
|
1140
1141
|
})
|
|
1141
|
-
}), /* @__PURE__ */
|
|
1142
|
-
permission:
|
|
1142
|
+
}), /* @__PURE__ */ w(g, {
|
|
1143
|
+
permission: s.DASHBOARD_IMPORT,
|
|
1143
1144
|
deniedBehavior: "hide",
|
|
1144
|
-
children: /* @__PURE__ */
|
|
1145
|
+
children: /* @__PURE__ */ T(b, {
|
|
1145
1146
|
variant: "outline",
|
|
1146
|
-
onClick:
|
|
1147
|
-
children: [/* @__PURE__ */
|
|
1147
|
+
onClick: ot,
|
|
1148
|
+
children: [/* @__PURE__ */ w(De, { style: {
|
|
1148
1149
|
marginRight: "var(--space-iconGap)",
|
|
1149
1150
|
height: "var(--size-icon-sm)",
|
|
1150
1151
|
width: "var(--size-icon-sm)"
|
|
1151
|
-
} }),
|
|
1152
|
+
} }), v("bigconsole.dashboards.actions.importDashboard", "Import Dashboard")]
|
|
1152
1153
|
})
|
|
1153
1154
|
})]
|
|
1154
1155
|
})
|
|
@@ -1157,20 +1158,20 @@ var Pe = f(function({ title: e, subtitle: t, createLabel: n, importLabel: r, onC
|
|
|
1157
1158
|
]
|
|
1158
1159
|
})] })
|
|
1159
1160
|
}),
|
|
1160
|
-
/* @__PURE__ */
|
|
1161
|
-
isOpen: Le,
|
|
1162
|
-
isCreating: I,
|
|
1163
|
-
onClose: et,
|
|
1164
|
-
onCreate: tt,
|
|
1165
|
-
onTemplateInstalled: $e
|
|
1166
|
-
}),
|
|
1167
|
-
/* @__PURE__ */ T(re, {
|
|
1161
|
+
/* @__PURE__ */ w(te, {
|
|
1168
1162
|
isOpen: ze,
|
|
1169
|
-
|
|
1170
|
-
|
|
1163
|
+
isCreating: F,
|
|
1164
|
+
onClose: nt,
|
|
1165
|
+
onCreate: rt,
|
|
1166
|
+
onTemplateInstalled: tt
|
|
1167
|
+
}),
|
|
1168
|
+
/* @__PURE__ */ w(ae, {
|
|
1169
|
+
isOpen: Ve,
|
|
1170
|
+
onClose: st,
|
|
1171
|
+
onSuccess: ct
|
|
1171
1172
|
})
|
|
1172
1173
|
]
|
|
1173
1174
|
});
|
|
1174
1175
|
});
|
|
1175
1176
|
//#endregion
|
|
1176
|
-
export {
|
|
1177
|
+
export { k as DashboardsPage, k as default };
|