@burdenoff/microfe-bigconsole 2026.925.1 → 2026.925.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/ShareDialog/EmbedTab.js +142 -145
- package/dist/bigconsole/components/dashboard/ShareDialog/EmbedTab.js.map +1 -1
- package/dist/bigconsole/components/embed/ReadOnlyDashboardRenderer.js +5 -5
- package/dist/bigconsole/components/embed/ReadOnlyDashboardRenderer.js.map +1 -1
- package/dist/bigconsole/components/embed/types.js.map +1 -1
- package/dist/bigconsole/hooks/useDashboardEmbedPolicy.js +2 -4
- package/dist/bigconsole/hooks/useDashboardEmbedPolicy.js.map +1 -1
- package/dist/generated/wspace-operations.js +0 -1
- package/dist/generated/wspace-operations.js.map +1 -1
- package/package.json +1 -1
|
@@ -10,13 +10,13 @@ var f = [
|
|
|
10
10
|
"dark",
|
|
11
11
|
"auto"
|
|
12
12
|
];
|
|
13
|
-
function
|
|
13
|
+
function ee(e, t) {
|
|
14
14
|
return t === "light" ? e : e.replace(/(?<=\s)src="([^"]*)"/, (e, n) => {
|
|
15
15
|
let r = n.indexOf("#"), i = r === -1 ? n : n.slice(0, r), a = r === -1 ? "" : n.slice(r);
|
|
16
16
|
return `src="${i}${i.includes("?") ? "&" : "?"}theme=${t}${a}"`;
|
|
17
17
|
});
|
|
18
18
|
}
|
|
19
|
-
function
|
|
19
|
+
function te(e) {
|
|
20
20
|
let t = e.trim();
|
|
21
21
|
if (!t) return null;
|
|
22
22
|
try {
|
|
@@ -26,98 +26,96 @@ function m(e) {
|
|
|
26
26
|
return null;
|
|
27
27
|
}
|
|
28
28
|
}
|
|
29
|
-
function
|
|
30
|
-
let { t:
|
|
29
|
+
function p({ dashboardId: p, colors: m }) {
|
|
30
|
+
let { t: h } = d(), { policy: g, secret: _, loading: v, error: y, fetchPolicy: b, publishToWeb: x, applyPresentation: ne, setAllowedOrigins: S, rotateKey: C, unpublish: w } = t(), { hasPermission: T } = s(), E = T(e.DASHBOARD_MANAGE_EMBED), [D, O] = o(""), [k, A] = o([]), [j, M] = o(!1), [N, P] = o(!1), [F, I] = o("light"), [L, R] = o(!1), [z, B] = o(!1), [V, H] = o(null), U = a(null), W = a(null);
|
|
31
31
|
r(() => {
|
|
32
|
-
|
|
33
|
-
}, [
|
|
34
|
-
!
|
|
35
|
-
}, [
|
|
36
|
-
|
|
32
|
+
p && b(p);
|
|
33
|
+
}, [p, b]), r(() => {
|
|
34
|
+
!g || U.current === g.id || (U.current = g.id, I(n(g.presentationTheme)), R(g.showDashboardTitle));
|
|
35
|
+
}, [g]), r(() => () => {
|
|
36
|
+
W.current && clearTimeout(W.current);
|
|
37
37
|
}, []);
|
|
38
|
-
let
|
|
39
|
-
|
|
40
|
-
let e =
|
|
38
|
+
let G = g?.status === "ACTIVE", K = G ? g?.allowedParentOrigins ?? [] : k, q = i(() => _?.iframeSnippet ? ee(_.iframeSnippet, F) : null, [_, F]), J = () => {
|
|
39
|
+
H(null);
|
|
40
|
+
let e = te(D);
|
|
41
41
|
if (!e) {
|
|
42
|
-
|
|
42
|
+
H(h("bigconsole.dashboards.embed.error.invalidOrigin", "Enter a valid https origin, e.g. https://example.com"));
|
|
43
43
|
return;
|
|
44
44
|
}
|
|
45
|
-
if (
|
|
46
|
-
|
|
45
|
+
if (K.includes(e)) {
|
|
46
|
+
O("");
|
|
47
47
|
return;
|
|
48
48
|
}
|
|
49
|
-
|
|
50
|
-
},
|
|
51
|
-
|
|
52
|
-
},
|
|
53
|
-
if (
|
|
54
|
-
|
|
49
|
+
G && g ? S(g.id, [...K, e]) : A((t) => [...t, e]), O("");
|
|
50
|
+
}, Y = (e) => {
|
|
51
|
+
G && g ? S(g.id, K.filter((t) => t !== e)) : A((t) => t.filter((t) => t !== e));
|
|
52
|
+
}, X = async () => {
|
|
53
|
+
if (H(null), k.length === 0) {
|
|
54
|
+
H(h("bigconsole.dashboards.embed.error.noDomains", "Add at least one allowed website domain before publishing."));
|
|
55
55
|
return;
|
|
56
56
|
}
|
|
57
|
-
if (!
|
|
58
|
-
|
|
57
|
+
if (!j) {
|
|
58
|
+
H(h("bigconsole.dashboards.embed.error.notAttested", "Please confirm this dashboard is safe to be public."));
|
|
59
59
|
return;
|
|
60
60
|
}
|
|
61
|
-
await
|
|
61
|
+
await x(p, k, !0, {
|
|
62
62
|
theme: F,
|
|
63
|
-
showTitle: L
|
|
64
|
-
showBranding: z
|
|
63
|
+
showTitle: L
|
|
65
64
|
});
|
|
66
|
-
},
|
|
67
|
-
|
|
65
|
+
}, re = async () => {
|
|
66
|
+
g && (H(null), await ne(g.id, {
|
|
68
67
|
theme: F,
|
|
69
|
-
showTitle: L
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
}, oe = async (e) => {
|
|
68
|
+
showTitle: L
|
|
69
|
+
}) && (B(!0), W.current && clearTimeout(W.current), W.current = setTimeout(() => B(!1), 1500)));
|
|
70
|
+
}, ie = async (e) => {
|
|
73
71
|
try {
|
|
74
72
|
await navigator.clipboard.writeText(e), P(!0), setTimeout(() => P(!1), 1500);
|
|
75
73
|
} catch {
|
|
76
|
-
|
|
74
|
+
H(h("bigconsole.dashboards.embed.error.copyFailed", "Could not copy — select and copy manually."));
|
|
77
75
|
}
|
|
78
|
-
},
|
|
76
|
+
}, Z = {
|
|
79
77
|
padding: "8px 14px",
|
|
80
78
|
borderRadius: "8px",
|
|
81
79
|
border: "none",
|
|
82
|
-
background:
|
|
80
|
+
background: m.actionPrimaryBg,
|
|
83
81
|
color: "#fff",
|
|
84
82
|
fontSize: "13px",
|
|
85
83
|
fontWeight: 600,
|
|
86
84
|
cursor: "pointer"
|
|
87
|
-
},
|
|
85
|
+
}, Q = {
|
|
88
86
|
padding: "8px 14px",
|
|
89
87
|
borderRadius: "8px",
|
|
90
|
-
border: `1px solid ${
|
|
88
|
+
border: `1px solid ${m.borderDefault}`,
|
|
91
89
|
background: "transparent",
|
|
92
|
-
color:
|
|
90
|
+
color: m.textPrimary,
|
|
93
91
|
fontSize: "13px",
|
|
94
92
|
cursor: "pointer"
|
|
95
|
-
},
|
|
93
|
+
}, ae = {
|
|
96
94
|
flex: 1,
|
|
97
95
|
padding: "8px 10px",
|
|
98
96
|
borderRadius: "8px",
|
|
99
|
-
border: `1px solid ${
|
|
100
|
-
background:
|
|
101
|
-
color:
|
|
97
|
+
border: `1px solid ${m.borderDefault}`,
|
|
98
|
+
background: m.bgSecondary,
|
|
99
|
+
color: m.textPrimary,
|
|
102
100
|
fontSize: "13px"
|
|
103
|
-
},
|
|
101
|
+
}, oe = {
|
|
104
102
|
padding: "4px 8px",
|
|
105
103
|
borderRadius: "6px",
|
|
106
|
-
border: `1px solid ${
|
|
107
|
-
background:
|
|
108
|
-
color:
|
|
104
|
+
border: `1px solid ${m.borderDefault}`,
|
|
105
|
+
background: m.bgSecondary,
|
|
106
|
+
color: m.textPrimary,
|
|
109
107
|
fontSize: "12px",
|
|
110
108
|
cursor: "pointer"
|
|
111
|
-
},
|
|
109
|
+
}, se = {
|
|
112
110
|
display: "flex",
|
|
113
111
|
gap: "8px",
|
|
114
112
|
alignItems: "flex-start",
|
|
115
113
|
fontSize: "12px",
|
|
116
|
-
color:
|
|
117
|
-
},
|
|
114
|
+
color: m.textSecondary
|
|
115
|
+
}, ce = i(() => f.map((e) => ({
|
|
118
116
|
value: e,
|
|
119
|
-
label: e === "light" ?
|
|
120
|
-
})), [
|
|
117
|
+
label: e === "light" ? h("bigconsole.dashboards.embed.theme.option.light", "Light") : e === "dark" ? h("bigconsole.dashboards.embed.theme.option.dark", "Dark") : h("bigconsole.dashboards.embed.theme.option.auto", "Auto (match viewer)")
|
|
118
|
+
})), [h]), $ = /* @__PURE__ */ u("div", {
|
|
121
119
|
style: {
|
|
122
120
|
display: "flex",
|
|
123
121
|
flexDirection: "column",
|
|
@@ -134,37 +132,36 @@ function h({ dashboardId: h, colors: g }) {
|
|
|
134
132
|
children: [/* @__PURE__ */ l("span", {
|
|
135
133
|
style: {
|
|
136
134
|
fontSize: "12px",
|
|
137
|
-
color:
|
|
135
|
+
color: m.textSecondary
|
|
138
136
|
},
|
|
139
|
-
children:
|
|
137
|
+
children: h("bigconsole.dashboards.embed.theme.label", "Theme")
|
|
140
138
|
}), /* @__PURE__ */ l("select", {
|
|
141
139
|
value: F,
|
|
142
140
|
onChange: (e) => {
|
|
143
141
|
let t = e.target.value;
|
|
144
142
|
(t === "light" || t === "dark" || t === "auto") && I(t);
|
|
145
143
|
},
|
|
146
|
-
style:
|
|
147
|
-
children:
|
|
144
|
+
style: oe,
|
|
145
|
+
children: ce.map((e) => /* @__PURE__ */ l("option", {
|
|
148
146
|
value: e.value,
|
|
149
147
|
children: e.label
|
|
150
148
|
}, e.value))
|
|
151
149
|
})]
|
|
152
150
|
}),
|
|
153
151
|
/* @__PURE__ */ u("label", {
|
|
154
|
-
style:
|
|
152
|
+
style: se,
|
|
155
153
|
children: [/* @__PURE__ */ l("input", {
|
|
156
154
|
type: "checkbox",
|
|
157
155
|
checked: L,
|
|
158
156
|
onChange: (e) => R(e.target.checked)
|
|
159
|
-
}), /* @__PURE__ */ l("span", { children:
|
|
157
|
+
}), /* @__PURE__ */ l("span", { children: h("bigconsole.dashboards.embed.presentation.showTitle", "Show the dashboard title as a header") })]
|
|
160
158
|
}),
|
|
161
|
-
/* @__PURE__ */
|
|
162
|
-
style:
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
}), /* @__PURE__ */ l("span", { children: _("bigconsole.dashboards.embed.presentation.showBranding", "Show a subtle “Powered by BigConsole” footer") })]
|
|
159
|
+
/* @__PURE__ */ l("div", {
|
|
160
|
+
style: {
|
|
161
|
+
fontSize: "11px",
|
|
162
|
+
color: m.textTertiary
|
|
163
|
+
},
|
|
164
|
+
children: h("bigconsole.dashboards.embed.presentation.brandingNote", "Embeds always carry a “Powered by BigConsole” footer.")
|
|
168
165
|
})
|
|
169
166
|
]
|
|
170
167
|
});
|
|
@@ -178,23 +175,23 @@ function h({ dashboardId: h, colors: g }) {
|
|
|
178
175
|
justifyContent: "space-between",
|
|
179
176
|
padding: "12px 14px",
|
|
180
177
|
borderRadius: "10px",
|
|
181
|
-
background:
|
|
178
|
+
background: m.bgSecondary,
|
|
182
179
|
marginBottom: "16px"
|
|
183
180
|
},
|
|
184
181
|
children: [/* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("div", {
|
|
185
182
|
style: {
|
|
186
183
|
fontSize: "14px",
|
|
187
184
|
fontWeight: 600,
|
|
188
|
-
color:
|
|
185
|
+
color: m.textPrimary
|
|
189
186
|
},
|
|
190
|
-
children:
|
|
187
|
+
children: h("bigconsole.dashboards.embed.heading", "Publish to the web")
|
|
191
188
|
}), /* @__PURE__ */ l("div", {
|
|
192
189
|
style: {
|
|
193
190
|
fontSize: "12px",
|
|
194
|
-
color:
|
|
191
|
+
color: m.textSecondary,
|
|
195
192
|
marginTop: "2px"
|
|
196
193
|
},
|
|
197
|
-
children:
|
|
194
|
+
children: G ? h("bigconsole.dashboards.embed.status.liveDescription", "This dashboard is live. Anyone with the link on an allowed website sees its live data.") : h("bigconsole.dashboards.embed.status.privateDescription", "Embed this dashboard on your website. Viewers see live data — no login required.")
|
|
198
195
|
})] }), /* @__PURE__ */ l("span", {
|
|
199
196
|
style: {
|
|
200
197
|
fontSize: "11px",
|
|
@@ -202,9 +199,9 @@ function h({ dashboardId: h, colors: g }) {
|
|
|
202
199
|
padding: "3px 8px",
|
|
203
200
|
borderRadius: "999px",
|
|
204
201
|
color: "#fff",
|
|
205
|
-
background:
|
|
202
|
+
background: G ? m.statusSuccessBg : m.textTertiary
|
|
206
203
|
},
|
|
207
|
-
children:
|
|
204
|
+
children: G ? h("bigconsole.dashboards.embed.badge.published", "PUBLISHED") : h("bigconsole.dashboards.embed.badge.private", "PRIVATE")
|
|
208
205
|
})]
|
|
209
206
|
}),
|
|
210
207
|
/* @__PURE__ */ u("div", {
|
|
@@ -214,10 +211,10 @@ function h({ dashboardId: h, colors: g }) {
|
|
|
214
211
|
style: {
|
|
215
212
|
fontSize: "12px",
|
|
216
213
|
fontWeight: 600,
|
|
217
|
-
color:
|
|
214
|
+
color: m.textSecondary,
|
|
218
215
|
marginBottom: "6px"
|
|
219
216
|
},
|
|
220
|
-
children:
|
|
217
|
+
children: h("bigconsole.dashboards.embed.domains.label", "Allowed website domains")
|
|
221
218
|
}),
|
|
222
219
|
/* @__PURE__ */ u("div", {
|
|
223
220
|
style: {
|
|
@@ -226,75 +223,75 @@ function h({ dashboardId: h, colors: g }) {
|
|
|
226
223
|
marginBottom: "8px"
|
|
227
224
|
},
|
|
228
225
|
children: [/* @__PURE__ */ l("input", {
|
|
229
|
-
style:
|
|
230
|
-
placeholder:
|
|
231
|
-
value:
|
|
232
|
-
onChange: (e) =>
|
|
226
|
+
style: ae,
|
|
227
|
+
placeholder: h("bigconsole.dashboards.embed.domains.placeholder", "https://yoursite.com"),
|
|
228
|
+
value: D,
|
|
229
|
+
onChange: (e) => O(e.target.value),
|
|
233
230
|
onKeyDown: (e) => {
|
|
234
|
-
e.key === "Enter" &&
|
|
231
|
+
e.key === "Enter" && J();
|
|
235
232
|
}
|
|
236
233
|
}), /* @__PURE__ */ l("button", {
|
|
237
|
-
style:
|
|
238
|
-
onClick:
|
|
234
|
+
style: Q,
|
|
235
|
+
onClick: J,
|
|
239
236
|
type: "button",
|
|
240
|
-
disabled: !
|
|
241
|
-
children:
|
|
237
|
+
disabled: !E,
|
|
238
|
+
children: h("bigconsole.dashboards.embed.domains.add", "Add")
|
|
242
239
|
})]
|
|
243
240
|
}),
|
|
244
|
-
|
|
241
|
+
K.length === 0 ? /* @__PURE__ */ l("div", {
|
|
245
242
|
style: {
|
|
246
243
|
fontSize: "12px",
|
|
247
|
-
color:
|
|
244
|
+
color: m.textTertiary
|
|
248
245
|
},
|
|
249
|
-
children:
|
|
246
|
+
children: h("bigconsole.dashboards.embed.domains.empty", "No domains yet. Only listed https domains may frame this dashboard.")
|
|
250
247
|
}) : /* @__PURE__ */ l("div", {
|
|
251
248
|
style: {
|
|
252
249
|
display: "flex",
|
|
253
250
|
flexDirection: "column",
|
|
254
251
|
gap: "6px"
|
|
255
252
|
},
|
|
256
|
-
children:
|
|
253
|
+
children: K.map((e) => /* @__PURE__ */ u("div", {
|
|
257
254
|
style: {
|
|
258
255
|
display: "flex",
|
|
259
256
|
alignItems: "center",
|
|
260
257
|
justifyContent: "space-between",
|
|
261
258
|
padding: "6px 10px",
|
|
262
259
|
borderRadius: "8px",
|
|
263
|
-
background:
|
|
260
|
+
background: m.bgTertiary
|
|
264
261
|
},
|
|
265
262
|
children: [/* @__PURE__ */ l("span", {
|
|
266
263
|
style: {
|
|
267
264
|
fontSize: "13px",
|
|
268
|
-
color:
|
|
265
|
+
color: m.textPrimary
|
|
269
266
|
},
|
|
270
267
|
children: e
|
|
271
|
-
}),
|
|
268
|
+
}), E && /* @__PURE__ */ l("button", {
|
|
272
269
|
style: {
|
|
273
|
-
...
|
|
270
|
+
...Q,
|
|
274
271
|
padding: "2px 8px",
|
|
275
|
-
color:
|
|
272
|
+
color: m.statusErrorText
|
|
276
273
|
},
|
|
277
|
-
onClick: () =>
|
|
274
|
+
onClick: () => Y(e),
|
|
278
275
|
type: "button",
|
|
279
|
-
children:
|
|
276
|
+
children: h("bigconsole.dashboards.embed.domains.remove", "Remove")
|
|
280
277
|
})]
|
|
281
278
|
}, e))
|
|
282
279
|
})
|
|
283
280
|
]
|
|
284
281
|
}),
|
|
285
|
-
!
|
|
282
|
+
!G && /* @__PURE__ */ u("div", {
|
|
286
283
|
style: { marginBottom: "16px" },
|
|
287
284
|
children: [/* @__PURE__ */ l("div", {
|
|
288
285
|
style: {
|
|
289
286
|
fontSize: "12px",
|
|
290
287
|
fontWeight: 600,
|
|
291
|
-
color:
|
|
288
|
+
color: m.textSecondary,
|
|
292
289
|
marginBottom: "8px"
|
|
293
290
|
},
|
|
294
|
-
children:
|
|
291
|
+
children: h("bigconsole.dashboards.embed.presentation.heading", "Presentation")
|
|
295
292
|
}), $]
|
|
296
293
|
}),
|
|
297
|
-
!
|
|
294
|
+
!G && /* @__PURE__ */ u("div", {
|
|
298
295
|
style: { marginBottom: "8px" },
|
|
299
296
|
children: [/* @__PURE__ */ u("label", {
|
|
300
297
|
style: {
|
|
@@ -305,25 +302,25 @@ function h({ dashboardId: h, colors: g }) {
|
|
|
305
302
|
},
|
|
306
303
|
children: [/* @__PURE__ */ l("input", {
|
|
307
304
|
type: "checkbox",
|
|
308
|
-
checked:
|
|
309
|
-
onChange: (e) =>
|
|
305
|
+
checked: j,
|
|
306
|
+
onChange: (e) => M(e.target.checked)
|
|
310
307
|
}), /* @__PURE__ */ l("span", {
|
|
311
308
|
style: {
|
|
312
309
|
fontSize: "12px",
|
|
313
|
-
color:
|
|
310
|
+
color: m.textSecondary
|
|
314
311
|
},
|
|
315
|
-
children:
|
|
312
|
+
children: h("bigconsole.dashboards.embed.attestation", "I understand this makes the dashboard’s live data visible to anyone with the link, and I confirm it is safe to be public.")
|
|
316
313
|
})]
|
|
317
314
|
}), /* @__PURE__ */ l("button", {
|
|
318
|
-
style:
|
|
319
|
-
onClick:
|
|
320
|
-
disabled:
|
|
315
|
+
style: Z,
|
|
316
|
+
onClick: X,
|
|
317
|
+
disabled: v || !E,
|
|
321
318
|
type: "button",
|
|
322
|
-
children:
|
|
319
|
+
children: v ? h("bigconsole.dashboards.embed.publishing", "Publishing…") : h("bigconsole.dashboards.embed.publish", "Publish to web")
|
|
323
320
|
})]
|
|
324
321
|
}),
|
|
325
|
-
|
|
326
|
-
|
|
322
|
+
G && /* @__PURE__ */ u(c, { children: [
|
|
323
|
+
q ? /* @__PURE__ */ u("div", {
|
|
327
324
|
style: { marginBottom: "16px" },
|
|
328
325
|
children: [
|
|
329
326
|
/* @__PURE__ */ l("div", {
|
|
@@ -332,22 +329,22 @@ function h({ dashboardId: h, colors: g }) {
|
|
|
332
329
|
style: {
|
|
333
330
|
fontSize: "12px",
|
|
334
331
|
fontWeight: 600,
|
|
335
|
-
color:
|
|
332
|
+
color: m.textSecondary
|
|
336
333
|
},
|
|
337
|
-
children:
|
|
334
|
+
children: h("bigconsole.dashboards.embed.snippet.label", "Embed snippet")
|
|
338
335
|
})
|
|
339
336
|
}),
|
|
340
337
|
/* @__PURE__ */ l("textarea", {
|
|
341
338
|
readOnly: !0,
|
|
342
|
-
value:
|
|
339
|
+
value: q,
|
|
343
340
|
style: {
|
|
344
341
|
width: "100%",
|
|
345
342
|
minHeight: "96px",
|
|
346
343
|
padding: "10px",
|
|
347
344
|
borderRadius: "8px",
|
|
348
|
-
border: `1px solid ${
|
|
349
|
-
background:
|
|
350
|
-
color:
|
|
345
|
+
border: `1px solid ${m.borderDefault}`,
|
|
346
|
+
background: m.bgSecondary,
|
|
347
|
+
color: m.textPrimary,
|
|
351
348
|
fontFamily: "monospace",
|
|
352
349
|
fontSize: "12px",
|
|
353
350
|
resize: "vertical"
|
|
@@ -355,24 +352,24 @@ function h({ dashboardId: h, colors: g }) {
|
|
|
355
352
|
}),
|
|
356
353
|
/* @__PURE__ */ l("button", {
|
|
357
354
|
style: {
|
|
358
|
-
...
|
|
355
|
+
...Q,
|
|
359
356
|
marginTop: "8px"
|
|
360
357
|
},
|
|
361
|
-
onClick: () =>
|
|
358
|
+
onClick: () => ie(q),
|
|
362
359
|
type: "button",
|
|
363
|
-
children:
|
|
360
|
+
children: N ? h("bigconsole.dashboards.embed.snippet.copied", "Copied ✓") : h("bigconsole.dashboards.embed.snippet.copy", "Copy snippet")
|
|
364
361
|
})
|
|
365
362
|
]
|
|
366
363
|
}) : /* @__PURE__ */ l("div", {
|
|
367
364
|
style: {
|
|
368
365
|
fontSize: "12px",
|
|
369
|
-
color:
|
|
370
|
-
background:
|
|
366
|
+
color: m.textSecondary,
|
|
367
|
+
background: m.bgSecondary,
|
|
371
368
|
borderRadius: "8px",
|
|
372
369
|
padding: "10px 12px",
|
|
373
370
|
marginBottom: "16px"
|
|
374
371
|
},
|
|
375
|
-
children:
|
|
372
|
+
children: h("bigconsole.dashboards.embed.snippet.alreadyActive", "The embed link is already active. For security the snippet (which contains the secret key) is only shown once at publish time — use {{rotateLabel}} to generate a fresh snippet.", { rotateLabel: h("bigconsole.dashboards.embed.rotate", "Rotate link") })
|
|
376
373
|
}),
|
|
377
374
|
/* @__PURE__ */ u("div", {
|
|
378
375
|
style: { marginBottom: "16px" },
|
|
@@ -381,10 +378,10 @@ function h({ dashboardId: h, colors: g }) {
|
|
|
381
378
|
style: {
|
|
382
379
|
fontSize: "12px",
|
|
383
380
|
fontWeight: 600,
|
|
384
|
-
color:
|
|
381
|
+
color: m.textSecondary,
|
|
385
382
|
marginBottom: "8px"
|
|
386
383
|
},
|
|
387
|
-
children:
|
|
384
|
+
children: h("bigconsole.dashboards.embed.presentation.heading", "Presentation")
|
|
388
385
|
}),
|
|
389
386
|
$,
|
|
390
387
|
/* @__PURE__ */ u("div", {
|
|
@@ -395,67 +392,67 @@ function h({ dashboardId: h, colors: g }) {
|
|
|
395
392
|
marginTop: "10px"
|
|
396
393
|
},
|
|
397
394
|
children: [/* @__PURE__ */ l("button", {
|
|
398
|
-
style:
|
|
399
|
-
onClick:
|
|
400
|
-
disabled:
|
|
395
|
+
style: Q,
|
|
396
|
+
onClick: re,
|
|
397
|
+
disabled: v || !E,
|
|
401
398
|
type: "button",
|
|
402
|
-
children:
|
|
403
|
-
}),
|
|
399
|
+
children: v ? h("bigconsole.dashboards.embed.applying", "Applying…") : h("bigconsole.dashboards.embed.apply", "Apply changes")
|
|
400
|
+
}), z && /* @__PURE__ */ l("span", {
|
|
404
401
|
style: {
|
|
405
402
|
fontSize: "12px",
|
|
406
|
-
color:
|
|
403
|
+
color: m.textTertiary
|
|
407
404
|
},
|
|
408
|
-
children:
|
|
405
|
+
children: h("bigconsole.dashboards.embed.updated", "Updated ✓")
|
|
409
406
|
})]
|
|
410
407
|
}),
|
|
411
408
|
/* @__PURE__ */ l("div", {
|
|
412
409
|
style: {
|
|
413
410
|
fontSize: "11px",
|
|
414
|
-
color:
|
|
411
|
+
color: m.textTertiary,
|
|
415
412
|
marginTop: "6px"
|
|
416
413
|
},
|
|
417
|
-
children:
|
|
414
|
+
children: h("bigconsole.dashboards.embed.presentation.applyHelp", "Changes apply to live embeds within a few seconds — no re-publish needed, and the embed link stays the same.")
|
|
418
415
|
})
|
|
419
416
|
]
|
|
420
417
|
}),
|
|
421
|
-
|
|
418
|
+
E && /* @__PURE__ */ u("div", {
|
|
422
419
|
style: {
|
|
423
420
|
display: "flex",
|
|
424
421
|
gap: "8px"
|
|
425
422
|
},
|
|
426
423
|
children: [/* @__PURE__ */ l("button", {
|
|
427
|
-
style:
|
|
428
|
-
onClick: () =>
|
|
429
|
-
disabled:
|
|
424
|
+
style: Q,
|
|
425
|
+
onClick: () => g && C(g.id),
|
|
426
|
+
disabled: v,
|
|
430
427
|
type: "button",
|
|
431
|
-
children:
|
|
428
|
+
children: h("bigconsole.dashboards.embed.rotate", "Rotate link")
|
|
432
429
|
}), /* @__PURE__ */ l("button", {
|
|
433
430
|
style: {
|
|
434
|
-
...
|
|
435
|
-
color:
|
|
436
|
-
borderColor:
|
|
431
|
+
...Q,
|
|
432
|
+
color: m.statusErrorText,
|
|
433
|
+
borderColor: m.statusErrorText
|
|
437
434
|
},
|
|
438
435
|
onClick: () => {
|
|
439
|
-
|
|
436
|
+
g && window.confirm(h("bigconsole.dashboards.embed.unpublishConfirm", "Unpublish this dashboard? The embed will stop working immediately for anyone using the link.")) && w(g.id);
|
|
440
437
|
},
|
|
441
|
-
disabled:
|
|
438
|
+
disabled: v,
|
|
442
439
|
type: "button",
|
|
443
|
-
children:
|
|
440
|
+
children: h("bigconsole.dashboards.embed.unpublish", "Unpublish")
|
|
444
441
|
})]
|
|
445
442
|
})
|
|
446
443
|
] }),
|
|
447
|
-
(
|
|
444
|
+
(V || y) && /* @__PURE__ */ l("div", {
|
|
448
445
|
style: {
|
|
449
446
|
marginTop: "12px",
|
|
450
447
|
fontSize: "12px",
|
|
451
|
-
color:
|
|
448
|
+
color: m.statusErrorText
|
|
452
449
|
},
|
|
453
|
-
children:
|
|
450
|
+
children: V ?? y?.message
|
|
454
451
|
})
|
|
455
452
|
]
|
|
456
453
|
});
|
|
457
454
|
}
|
|
458
455
|
//#endregion
|
|
459
|
-
export {
|
|
456
|
+
export { p as default };
|
|
460
457
|
|
|
461
458
|
//# sourceMappingURL=EmbedTab.js.map
|