@burdenoff/microfe-bigconsole 2026.1012.8 → 2026.1013.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bigconsole/assistant/assistantRunStore.js +5 -5
- package/dist/bigconsole/assistant/createSandboxAssistantTransport.js +5 -5
- package/dist/bigconsole/components/DrilldownDashboardRenderer.d.ts +3 -0
- package/dist/bigconsole/components/DrilldownDashboardRenderer.js +106 -88
- package/dist/bigconsole/components/embed/widgets/ChartEmbed.js +1 -1
- package/dist/bigconsole/components/insights/GeneratedFormattingReview.d.ts +8 -0
- package/dist/bigconsole/components/insights/GeneratedFormattingReview.js +122 -0
- package/dist/bigconsole/components/preview/AiPreviewContent.d.ts +4 -2
- package/dist/bigconsole/components/preview/AiPreviewContent.js +121 -93
- package/dist/bigconsole/components/preview/AiPreviewPanel.js +103 -100
- package/dist/bigconsole/components/preview/confirmedPreviewWidgets.d.ts +5 -0
- package/dist/bigconsole/components/preview/confirmedPreviewWidgets.js +27 -0
- package/dist/bigconsole/components/widgets/gauge/CircularGauge.js +4 -6
- package/dist/bigconsole/pages/InsightsPage.js +325 -317
- package/dist/bigconsole/utils/quota.js +1 -1
- package/dist/node_modules/@e965/xlsx/xlsx.js +32 -32
- package/dist/node_modules/pdfjs-dist/build/pdf.js +17 -14
- package/package.json +30 -12
|
@@ -5,19 +5,20 @@ import { SECTION_FOCUS_RING as n } from "../components/common/sectionStyles.js";
|
|
|
5
5
|
import { Section as r, SectionStack as i } from "../components/common/Section.js";
|
|
6
6
|
import "../components/common/index.js";
|
|
7
7
|
import a from "../hooks/useBigConsoleAnalytics.js";
|
|
8
|
-
import { isNative as ee, nativeImpact as o, nativeNotify as
|
|
9
|
-
import { isInsightsDraftDirty as
|
|
8
|
+
import { isNative as ee, nativeImpact as o, nativeNotify as s } from "../../utils/nativeBridge.js";
|
|
9
|
+
import { isInsightsDraftDirty as te } from "../utils/insightsDraft.js";
|
|
10
|
+
import { GeneratedFormattingReview as ne, GenerationExecutionStatus as re } from "../components/insights/GeneratedFormattingReview.js";
|
|
10
11
|
/* empty css */
|
|
11
|
-
import { memo as
|
|
12
|
-
import { AlertCircle as
|
|
13
|
-
import { AuroraBackground as
|
|
14
|
-
import { useUnsavedChanges as
|
|
15
|
-
import { useI18n as
|
|
16
|
-
import { useMutation as
|
|
12
|
+
import { memo as c, useCallback as l, useEffect as ie, useState as u } from "react";
|
|
13
|
+
import { AlertCircle as ae, ArrowRight as d, Ban as oe, CheckCircle as f, Clock as p, Eye as se, History as ce, Lightbulb as le, Loader2 as m, RefreshCw as ue, Sparkles as h, Trash2 as de, Wand2 as g, X as fe, XCircle as _ } from "lucide-react";
|
|
14
|
+
import { AuroraBackground as pe, GlassCard as me, GradientText as he, IllustratedEmptyState as ge, PagePurpose as _e } from "@burdenoff/fe-libs/ui";
|
|
15
|
+
import { useUnsavedChanges as ve } from "@burdenoff/fe-libs/shared/hooks";
|
|
16
|
+
import { useI18n as v } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
17
|
+
import { useMutation as y, useQuery as ye } from "@apollo/client/react";
|
|
17
18
|
import { jsx as b, jsxs as x } from "react/jsx-runtime";
|
|
18
19
|
import { gql as S } from "@apollo/client";
|
|
19
20
|
//#region src/bigconsole/pages/InsightsPage.tsx
|
|
20
|
-
var
|
|
21
|
+
var be = S`
|
|
21
22
|
query ListPromptGenerations($status: PromptGenerationStatus, $first: Int) {
|
|
22
23
|
listPromptGenerations(status: $status, first: $first) {
|
|
23
24
|
edges {
|
|
@@ -29,6 +30,7 @@ var ve = S`
|
|
|
29
30
|
errorMessage
|
|
30
31
|
createdAt
|
|
31
32
|
completedAt
|
|
33
|
+
processingMetadata
|
|
32
34
|
generatedSpec {
|
|
33
35
|
name
|
|
34
36
|
description
|
|
@@ -49,6 +51,7 @@ var ve = S`
|
|
|
49
51
|
type
|
|
50
52
|
confidence
|
|
51
53
|
reasoning
|
|
54
|
+
config
|
|
52
55
|
}
|
|
53
56
|
}
|
|
54
57
|
}
|
|
@@ -57,7 +60,7 @@ var ve = S`
|
|
|
57
60
|
totalCount
|
|
58
61
|
}
|
|
59
62
|
}
|
|
60
|
-
`,
|
|
63
|
+
`, xe = S`
|
|
61
64
|
query GetPromptSuggestions($category: String, $limit: Int) {
|
|
62
65
|
getPromptSuggestions(category: $category, limit: $limit) {
|
|
63
66
|
id
|
|
@@ -68,7 +71,7 @@ var ve = S`
|
|
|
68
71
|
tags
|
|
69
72
|
}
|
|
70
73
|
}
|
|
71
|
-
`,
|
|
74
|
+
`, Se = S`
|
|
72
75
|
mutation GenerateDashboardFromPrompt($input: GenerateDashboardFromPromptInput!) {
|
|
73
76
|
generateDashboardFromPrompt(input: $input) {
|
|
74
77
|
id
|
|
@@ -76,24 +79,24 @@ var ve = S`
|
|
|
76
79
|
prompt
|
|
77
80
|
}
|
|
78
81
|
}
|
|
79
|
-
`,
|
|
82
|
+
`, Ce = S`
|
|
80
83
|
mutation CreateDashboardFromGeneration($input: CreateDashboardFromGenerationInput!) {
|
|
81
84
|
createDashboardFromGeneration(input: $input) {
|
|
82
85
|
id
|
|
83
86
|
}
|
|
84
87
|
}
|
|
85
|
-
`,
|
|
88
|
+
`, we = S`
|
|
86
89
|
mutation DeletePromptGeneration($generationId: ID!) {
|
|
87
90
|
deletePromptGeneration(generationId: $generationId)
|
|
88
91
|
}
|
|
89
|
-
`,
|
|
92
|
+
`, Te = S`
|
|
90
93
|
mutation CancelPromptGeneration($generationId: ID!) {
|
|
91
94
|
cancelPromptGeneration(generationId: $generationId) {
|
|
92
95
|
id
|
|
93
96
|
status
|
|
94
97
|
}
|
|
95
98
|
}
|
|
96
|
-
`,
|
|
99
|
+
`, Ee = S`
|
|
97
100
|
mutation RegenerateDashboard($input: RegenerateDashboardInput!) {
|
|
98
101
|
regenerateDashboard(input: $input) {
|
|
99
102
|
id
|
|
@@ -101,7 +104,7 @@ var ve = S`
|
|
|
101
104
|
prompt
|
|
102
105
|
}
|
|
103
106
|
}
|
|
104
|
-
`,
|
|
107
|
+
`, De = S`
|
|
105
108
|
mutation RefineGeneratedDashboard($input: RefineGeneratedDashboardInput!) {
|
|
106
109
|
refineGeneratedDashboard(input: $input) {
|
|
107
110
|
id
|
|
@@ -109,11 +112,11 @@ var ve = S`
|
|
|
109
112
|
prompt
|
|
110
113
|
}
|
|
111
114
|
}
|
|
112
|
-
`,
|
|
115
|
+
`, Oe = [
|
|
113
116
|
"PENDING",
|
|
114
117
|
"PROCESSING",
|
|
115
118
|
"GENERATING"
|
|
116
|
-
],
|
|
119
|
+
], ke = 12, Ae = 8, je = [
|
|
117
120
|
{
|
|
118
121
|
value: "MODERN",
|
|
119
122
|
label: "Modern"
|
|
@@ -134,7 +137,7 @@ var ve = S`
|
|
|
134
137
|
value: "VIBRANT",
|
|
135
138
|
label: "Vibrant"
|
|
136
139
|
}
|
|
137
|
-
],
|
|
140
|
+
], Me = [
|
|
138
141
|
{
|
|
139
142
|
value: "GRID",
|
|
140
143
|
label: "Grid"
|
|
@@ -159,13 +162,13 @@ var ve = S`
|
|
|
159
162
|
value: "THREE_COLUMN",
|
|
160
163
|
label: "Three column"
|
|
161
164
|
}
|
|
162
|
-
],
|
|
165
|
+
], Ne = [
|
|
163
166
|
6,
|
|
164
167
|
8,
|
|
165
168
|
12,
|
|
166
169
|
16,
|
|
167
170
|
24
|
|
168
|
-
],
|
|
171
|
+
], Pe = [
|
|
169
172
|
4,
|
|
170
173
|
6,
|
|
171
174
|
8,
|
|
@@ -194,12 +197,12 @@ var ve = S`
|
|
|
194
197
|
border: "1px solid transparent",
|
|
195
198
|
backgroundColor: "var(--color-action-primary-bg)",
|
|
196
199
|
color: "var(--color-action-primary-text)"
|
|
197
|
-
},
|
|
200
|
+
}, Fe = {
|
|
198
201
|
...C,
|
|
199
202
|
border: "1px solid var(--color-status-warning-border)",
|
|
200
203
|
backgroundColor: "transparent",
|
|
201
204
|
color: "var(--color-status-warning-text)"
|
|
202
|
-
},
|
|
205
|
+
}, Ie = {
|
|
203
206
|
...C,
|
|
204
207
|
minWidth: "var(--size-controlHeight-md)",
|
|
205
208
|
padding: "0 var(--space-controlGap)",
|
|
@@ -265,29 +268,29 @@ var A = {
|
|
|
265
268
|
border: "var(--color-border-subtle)"
|
|
266
269
|
}
|
|
267
270
|
};
|
|
268
|
-
function
|
|
271
|
+
function Le(e) {
|
|
269
272
|
let t = A[k(e)].text;
|
|
270
273
|
switch (e) {
|
|
271
|
-
case "COMPLETED": return /* @__PURE__ */ b(
|
|
274
|
+
case "COMPLETED": return /* @__PURE__ */ b(f, {
|
|
272
275
|
size: 14,
|
|
273
276
|
style: { color: t },
|
|
274
277
|
"aria-hidden": "true"
|
|
275
278
|
});
|
|
276
279
|
case "FAILED":
|
|
277
|
-
case "CANCELLED": return /* @__PURE__ */ b(
|
|
280
|
+
case "CANCELLED": return /* @__PURE__ */ b(_, {
|
|
278
281
|
size: 14,
|
|
279
282
|
style: { color: t },
|
|
280
283
|
"aria-hidden": "true"
|
|
281
284
|
});
|
|
282
285
|
case "PENDING":
|
|
283
286
|
case "PROCESSING":
|
|
284
|
-
case "GENERATING": return /* @__PURE__ */ b(
|
|
287
|
+
case "GENERATING": return /* @__PURE__ */ b(m, {
|
|
285
288
|
size: 14,
|
|
286
289
|
className: "animate-spin",
|
|
287
290
|
style: { color: t },
|
|
288
291
|
"aria-hidden": "true"
|
|
289
292
|
});
|
|
290
|
-
default: return /* @__PURE__ */ b(
|
|
293
|
+
default: return /* @__PURE__ */ b(p, {
|
|
291
294
|
size: 14,
|
|
292
295
|
style: { color: t },
|
|
293
296
|
"aria-hidden": "true"
|
|
@@ -305,8 +308,8 @@ function j(e, t) {
|
|
|
305
308
|
default: return e;
|
|
306
309
|
}
|
|
307
310
|
}
|
|
308
|
-
var
|
|
309
|
-
let { t } =
|
|
311
|
+
var Re = ({ status: e }) => {
|
|
312
|
+
let { t } = v(), n = A[k(e)];
|
|
310
313
|
return /* @__PURE__ */ x("span", {
|
|
311
314
|
"data-status": e,
|
|
312
315
|
style: {
|
|
@@ -315,10 +318,10 @@ var Ie = ({ status: e }) => {
|
|
|
315
318
|
backgroundColor: n.bg,
|
|
316
319
|
color: n.text
|
|
317
320
|
},
|
|
318
|
-
children: [
|
|
321
|
+
children: [Le(e), j(e, t)]
|
|
319
322
|
});
|
|
320
323
|
};
|
|
321
|
-
function
|
|
324
|
+
function ze(e) {
|
|
322
325
|
let t = A[e >= .8 ? "success" : e >= .5 ? "neutral" : "danger"];
|
|
323
326
|
return {
|
|
324
327
|
...O,
|
|
@@ -330,19 +333,19 @@ function Le(e) {
|
|
|
330
333
|
function M(e) {
|
|
331
334
|
return e.pages.reduce((e, t) => e + t.widgets.length, 0);
|
|
332
335
|
}
|
|
333
|
-
function
|
|
336
|
+
function Be(e) {
|
|
334
337
|
let t = e?.toUpperCase();
|
|
335
338
|
return t === "HIGH" || t === "MEDIUM" || t === "LOW" ? t : null;
|
|
336
339
|
}
|
|
337
|
-
var
|
|
340
|
+
var N = {
|
|
338
341
|
HIGH: "success",
|
|
339
342
|
MEDIUM: "neutral",
|
|
340
343
|
LOW: "danger"
|
|
341
344
|
};
|
|
342
|
-
function
|
|
345
|
+
function Ve(e) {
|
|
343
346
|
return { "--proposal-columns": Math.max(1, Math.min(24, Math.trunc(e))) };
|
|
344
347
|
}
|
|
345
|
-
function
|
|
348
|
+
function He(e, t) {
|
|
346
349
|
let n = Math.max(1, Math.min(24, Math.trunc(t))), r = Math.max(0, Math.min(n - 1, Math.trunc(e.x)));
|
|
347
350
|
return {
|
|
348
351
|
"--proposal-column": r + 1,
|
|
@@ -351,8 +354,8 @@ function Ve(e, t) {
|
|
|
351
354
|
"--proposal-height": Math.max(1, Math.min(24, Math.trunc(e.height)))
|
|
352
355
|
};
|
|
353
356
|
}
|
|
354
|
-
function
|
|
355
|
-
let t = A[
|
|
357
|
+
function Ue(e) {
|
|
358
|
+
let t = A[N[e]];
|
|
356
359
|
return {
|
|
357
360
|
...O,
|
|
358
361
|
padding: "0 var(--space-controlGap)",
|
|
@@ -364,173 +367,173 @@ function He(e) {
|
|
|
364
367
|
color: t.text
|
|
365
368
|
};
|
|
366
369
|
}
|
|
367
|
-
var
|
|
368
|
-
let { t:
|
|
369
|
-
|
|
370
|
+
var P = c(function() {
|
|
371
|
+
let { t: c } = v(), f = e(), p = a(), [_, S] = u(""), [C, k] = u("MODERN"), [A, Le] = u("GRID"), [j, N] = u(ke), [P, We] = u(Ae), [F, I] = u(!1), [Ge, L] = u(null), [R, Ke] = u(() => /* @__PURE__ */ new Set()), [z, B] = u(null), [V, H] = u(null), [U, W] = u("");
|
|
372
|
+
ve({
|
|
370
373
|
id: "insights-prompt",
|
|
371
|
-
label:
|
|
372
|
-
dirty:
|
|
373
|
-
promptText:
|
|
374
|
-
isGenerating:
|
|
375
|
-
refineOpen:
|
|
376
|
-
refineText:
|
|
377
|
-
refineBusy:
|
|
374
|
+
label: c("bigconsole.assistant.unsaved.insightsPrompt", "the dashboard description"),
|
|
375
|
+
dirty: te({
|
|
376
|
+
promptText: _,
|
|
377
|
+
isGenerating: F,
|
|
378
|
+
refineOpen: V !== null,
|
|
379
|
+
refineText: U,
|
|
380
|
+
refineBusy: V !== null && R.has(V.id)
|
|
378
381
|
})
|
|
379
382
|
});
|
|
380
|
-
let
|
|
381
|
-
|
|
382
|
-
}, []),
|
|
383
|
-
|
|
383
|
+
let G = l((e) => {
|
|
384
|
+
Ke((t) => new Set(t).add(e));
|
|
385
|
+
}, []), K = l((e) => {
|
|
386
|
+
Ke((t) => {
|
|
384
387
|
let n = new Set(t);
|
|
385
388
|
return n.delete(e), n;
|
|
386
389
|
});
|
|
387
|
-
}, []), { data:
|
|
390
|
+
}, []), { data: qe, loading: Je, error: q, refetch: J, startPolling: Ye, stopPolling: Y } = ye(be, {
|
|
388
391
|
variables: { first: 20 },
|
|
389
392
|
fetchPolicy: "cache-and-network"
|
|
390
|
-
}),
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
]),
|
|
397
|
-
if (!
|
|
393
|
+
}), X = qe?.listPromptGenerations?.edges?.some((e) => Oe.includes(e.node.status)) ?? !1, { data: Xe, error: Ze, refetch: Qe } = ye(xe, { variables: { limit: 6 } }), [$e] = y(Se), [et] = y(Ce), [tt] = y(we), [nt] = y(Te), [rt] = y(Ee), [it] = y(De), Z = qe?.listPromptGenerations?.edges?.map((e) => e.node) || [], at = Xe?.getPromptSuggestions || [];
|
|
394
|
+
ie(() => (X || F ? Ye(2e3) : Y(), () => Y()), [
|
|
395
|
+
X,
|
|
396
|
+
F,
|
|
397
|
+
Ye,
|
|
398
|
+
Y
|
|
399
|
+
]), ie(() => {
|
|
400
|
+
if (!z && !V) return;
|
|
398
401
|
let e = (e) => {
|
|
399
|
-
e.key === "Escape" && (
|
|
402
|
+
e.key === "Escape" && (B(null), H(null));
|
|
400
403
|
};
|
|
401
404
|
return window.addEventListener("keydown", e), () => window.removeEventListener("keydown", e);
|
|
402
|
-
}, [
|
|
403
|
-
let
|
|
404
|
-
if (!(!
|
|
405
|
-
if (
|
|
406
|
-
L(
|
|
405
|
+
}, [z, V]);
|
|
406
|
+
let ot = l(async () => {
|
|
407
|
+
if (!(!_.trim() || F)) {
|
|
408
|
+
if (_.length > 2e3) {
|
|
409
|
+
L(c("bigconsole.insights.error.promptTooLong", "Prompt is too long (max 2000 characters)."));
|
|
407
410
|
return;
|
|
408
411
|
}
|
|
409
|
-
L(null),
|
|
412
|
+
L(null), I(!0);
|
|
410
413
|
try {
|
|
411
|
-
|
|
412
|
-
let e = await
|
|
413
|
-
prompt:
|
|
414
|
+
p("bigconsole.ai.generate_clicked", { maxWidgets: P });
|
|
415
|
+
let e = await $e({ variables: { input: {
|
|
416
|
+
prompt: _.trim(),
|
|
414
417
|
styleType: C,
|
|
415
418
|
layoutType: A,
|
|
416
419
|
gridColumns: j,
|
|
417
|
-
maxWidgets:
|
|
420
|
+
maxWidgets: P
|
|
418
421
|
} } });
|
|
419
422
|
if (t(e, "command")) return;
|
|
420
423
|
let n = e.data?.generateDashboardFromPrompt?.id;
|
|
421
|
-
n &&
|
|
424
|
+
n && p("bigconsole.ai.dashboard_generated", {
|
|
422
425
|
generationId: n,
|
|
423
|
-
maxWidgets:
|
|
424
|
-
}), S(""),
|
|
426
|
+
maxWidgets: P
|
|
427
|
+
}), S(""), J();
|
|
425
428
|
} catch (e) {
|
|
426
429
|
if (t(e, "command")) return;
|
|
427
|
-
L(e instanceof Error ? e.message :
|
|
430
|
+
L(e instanceof Error ? e.message : c("bigconsole.insights.error.generateFailed", "Failed to generate dashboard"));
|
|
428
431
|
} finally {
|
|
429
|
-
|
|
432
|
+
I(!1);
|
|
430
433
|
}
|
|
431
434
|
}
|
|
432
435
|
}, [
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
436
|
+
p,
|
|
437
|
+
_,
|
|
438
|
+
F,
|
|
439
|
+
$e,
|
|
440
|
+
J,
|
|
438
441
|
C,
|
|
439
442
|
A,
|
|
440
443
|
j,
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
]),
|
|
444
|
+
P,
|
|
445
|
+
c
|
|
446
|
+
]), Q = l(async (e) => {
|
|
444
447
|
L(null);
|
|
445
448
|
try {
|
|
446
|
-
|
|
447
|
-
let n = await
|
|
449
|
+
p("bigconsole.ai.create_dashboard_clicked", { generationId: e });
|
|
450
|
+
let n = await et({ variables: { input: { generationId: e } } });
|
|
448
451
|
if (t(n, "project")) return;
|
|
449
452
|
let r = n.data?.createDashboardFromGeneration?.id;
|
|
450
|
-
r && (
|
|
453
|
+
r && (p("bigconsole.ai.dashboard_created", {
|
|
451
454
|
generationId: e,
|
|
452
455
|
dashboardId: r
|
|
453
|
-
}),
|
|
456
|
+
}), f(`/dashboards/${r}`));
|
|
454
457
|
} catch (e) {
|
|
455
458
|
if (t(e, "project")) return;
|
|
456
|
-
L(e instanceof Error ? e.message :
|
|
459
|
+
L(e instanceof Error ? e.message : c("bigconsole.insights.error.createFailed", "Failed to create dashboard"));
|
|
457
460
|
}
|
|
458
461
|
}, [
|
|
459
|
-
|
|
462
|
+
et,
|
|
463
|
+
p,
|
|
460
464
|
f,
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
]), at = c(async (e) => {
|
|
465
|
+
c
|
|
466
|
+
]), st = l(async (e) => {
|
|
464
467
|
L(null);
|
|
465
468
|
try {
|
|
466
|
-
await
|
|
469
|
+
await tt({ variables: { generationId: e } }), ee() && s("success"), J();
|
|
467
470
|
} catch (e) {
|
|
468
|
-
L(e instanceof Error ? e.message :
|
|
471
|
+
L(e instanceof Error ? e.message : c("bigconsole.insights.error.deleteFailed", "Failed to delete generation")), ee() && s("error");
|
|
469
472
|
}
|
|
470
473
|
}, [
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
]),
|
|
475
|
-
L(null),
|
|
474
|
+
tt,
|
|
475
|
+
J,
|
|
476
|
+
c
|
|
477
|
+
]), ct = l(async (e) => {
|
|
478
|
+
L(null), G(e);
|
|
476
479
|
try {
|
|
477
|
-
await
|
|
480
|
+
await nt({ variables: { generationId: e } }), J();
|
|
478
481
|
} catch (e) {
|
|
479
|
-
L(e instanceof Error ? e.message :
|
|
482
|
+
L(e instanceof Error ? e.message : c("bigconsole.insights.error.cancelFailed", "Failed to cancel generation"));
|
|
480
483
|
} finally {
|
|
481
|
-
|
|
484
|
+
K(e);
|
|
482
485
|
}
|
|
483
486
|
}, [
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
]),
|
|
488
|
-
L(null),
|
|
487
|
+
nt,
|
|
488
|
+
J,
|
|
489
|
+
c
|
|
490
|
+
]), lt = l(async (e) => {
|
|
491
|
+
L(null), G(e);
|
|
489
492
|
try {
|
|
490
|
-
if (t(await
|
|
491
|
-
|
|
493
|
+
if (t(await rt({ variables: { input: { generationId: e } } }), "command")) return;
|
|
494
|
+
J();
|
|
492
495
|
} catch (e) {
|
|
493
496
|
if (t(e, "command")) return;
|
|
494
|
-
L(e instanceof Error ? e.message :
|
|
497
|
+
L(e instanceof Error ? e.message : c("bigconsole.insights.error.regenerateFailed", "Failed to regenerate dashboard"));
|
|
495
498
|
} finally {
|
|
496
|
-
|
|
499
|
+
K(e);
|
|
497
500
|
}
|
|
498
501
|
}, [
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
]),
|
|
503
|
-
if (!
|
|
504
|
-
let e =
|
|
505
|
-
L(null),
|
|
502
|
+
rt,
|
|
503
|
+
J,
|
|
504
|
+
c
|
|
505
|
+
]), ut = l(async () => {
|
|
506
|
+
if (!V || !U.trim()) return;
|
|
507
|
+
let e = V.id;
|
|
508
|
+
L(null), G(e);
|
|
506
509
|
let n = !1;
|
|
507
510
|
try {
|
|
508
|
-
if (t(await
|
|
511
|
+
if (t(await it({ variables: { input: {
|
|
509
512
|
generationId: e,
|
|
510
|
-
refinementPrompt:
|
|
513
|
+
refinementPrompt: U.trim()
|
|
511
514
|
} } }), "command")) {
|
|
512
515
|
n = !0;
|
|
513
516
|
return;
|
|
514
517
|
}
|
|
515
|
-
n = !0,
|
|
518
|
+
n = !0, J();
|
|
516
519
|
} catch (e) {
|
|
517
520
|
if (t(e, "command")) {
|
|
518
521
|
n = !0;
|
|
519
522
|
return;
|
|
520
523
|
}
|
|
521
|
-
L(e instanceof Error ? e.message :
|
|
524
|
+
L(e instanceof Error ? e.message : c("bigconsole.insights.error.refineFailed", "Failed to refine generation"));
|
|
522
525
|
} finally {
|
|
523
|
-
n && (
|
|
526
|
+
n && (H(null), W("")), K(e);
|
|
524
527
|
}
|
|
525
528
|
}, [
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
]),
|
|
529
|
+
V,
|
|
530
|
+
U,
|
|
531
|
+
it,
|
|
532
|
+
J,
|
|
533
|
+
c
|
|
534
|
+
]), dt = l((e) => {
|
|
532
535
|
S(e);
|
|
533
|
-
}, []), $ =
|
|
536
|
+
}, []), $ = z?.generatedSpec;
|
|
534
537
|
return /* @__PURE__ */ x("div", {
|
|
535
538
|
"data-tour": "bigconsole-ai-insights",
|
|
536
539
|
className: "min-w-0",
|
|
@@ -538,7 +541,7 @@ var N = s(function() {
|
|
|
538
541
|
children: [
|
|
539
542
|
/* @__PURE__ */ x("header", {
|
|
540
543
|
className: "relative overflow-hidden border-b border-[var(--color-border-seam)] bg-[image:var(--gradient-gloss-card)]",
|
|
541
|
-
children: [/* @__PURE__ */ b(
|
|
544
|
+
children: [/* @__PURE__ */ b(pe, { intensity: "subtle" }), /* @__PURE__ */ b("div", {
|
|
542
545
|
style: { padding: "var(--space-pagePadding)" },
|
|
543
546
|
children: /* @__PURE__ */ x("div", {
|
|
544
547
|
style: {
|
|
@@ -559,7 +562,7 @@ var N = s(function() {
|
|
|
559
562
|
borderRadius: "var(--radius-card)",
|
|
560
563
|
backgroundColor: "var(--color-action-primary-bg)"
|
|
561
564
|
},
|
|
562
|
-
children: /* @__PURE__ */ b(
|
|
565
|
+
children: /* @__PURE__ */ b(h, { style: {
|
|
563
566
|
height: "var(--size-icon-lg)",
|
|
564
567
|
width: "var(--size-icon-lg)",
|
|
565
568
|
color: "var(--color-action-primary-text)"
|
|
@@ -568,10 +571,10 @@ var N = s(function() {
|
|
|
568
571
|
style: { minWidth: 0 },
|
|
569
572
|
children: [/* @__PURE__ */ b("h1", {
|
|
570
573
|
className: "m-0 text-2xl font-bold text-text-primary",
|
|
571
|
-
children: /* @__PURE__ */ b(
|
|
574
|
+
children: /* @__PURE__ */ b(he, { children: c("bigconsole.insights.header.title", "AI Insights") })
|
|
572
575
|
}), /* @__PURE__ */ b("p", {
|
|
573
576
|
className: "m-0 text-sm text-text-secondary",
|
|
574
|
-
children:
|
|
577
|
+
children: c("bigconsole.insights.header.subtitle", "Generate dashboards from natural language prompts")
|
|
575
578
|
})]
|
|
576
579
|
})]
|
|
577
580
|
})
|
|
@@ -579,50 +582,50 @@ var N = s(function() {
|
|
|
579
582
|
}),
|
|
580
583
|
/* @__PURE__ */ x("div", {
|
|
581
584
|
style: { padding: "var(--space-pagePadding)" },
|
|
582
|
-
children: [/* @__PURE__ */ b(
|
|
585
|
+
children: [/* @__PURE__ */ b(_e, {
|
|
583
586
|
className: "mb-[var(--space-sectionGap)]",
|
|
584
587
|
children: "Describe the dashboard you need in plain English and BigConsole proposes the pages, widgets and layout for it. Review the proposal, refine it in place, then create the real dashboard in one step — a generation is only a proposal until you accept it."
|
|
585
588
|
}), /* @__PURE__ */ x(i, { children: [
|
|
586
|
-
|
|
589
|
+
Ge && /* @__PURE__ */ b(r, {
|
|
587
590
|
headingLevel: 2,
|
|
588
591
|
tone: "danger",
|
|
589
592
|
padding: "compact",
|
|
590
593
|
title: "That request did not go through",
|
|
591
|
-
description:
|
|
592
|
-
icon: /* @__PURE__ */ b(
|
|
594
|
+
description: Ge,
|
|
595
|
+
icon: /* @__PURE__ */ b(ae, { className: "h-icon-sm w-icon-sm" }),
|
|
593
596
|
"data-testid": "insights-error",
|
|
594
597
|
actions: /* @__PURE__ */ b("button", {
|
|
595
598
|
type: "button",
|
|
596
599
|
onClick: () => L(null),
|
|
597
|
-
"aria-label":
|
|
600
|
+
"aria-label": c("bigconsole.insights.error.dismiss", "Dismiss error"),
|
|
598
601
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
599
602
|
style: w,
|
|
600
603
|
children: "Dismiss"
|
|
601
604
|
})
|
|
602
605
|
}),
|
|
603
|
-
(
|
|
606
|
+
(q || Ze) && /* @__PURE__ */ b("div", {
|
|
604
607
|
role: "alert",
|
|
605
608
|
children: /* @__PURE__ */ b(r, {
|
|
606
609
|
tone: "danger",
|
|
607
610
|
padding: "compact",
|
|
608
611
|
headingLevel: 2,
|
|
609
|
-
title:
|
|
610
|
-
description:
|
|
612
|
+
title: c("bigconsole.insights.error.loadFailed", "AI Insights could not be loaded"),
|
|
613
|
+
description: c("bigconsole.insights.error.loadFailedDescription", "Your saved generations and suggestions may be unavailable. Retry the failed request."),
|
|
611
614
|
"data-testid": "insights-load-error",
|
|
612
615
|
actions: /* @__PURE__ */ x("button", {
|
|
613
616
|
type: "button",
|
|
614
617
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
615
618
|
style: w,
|
|
616
619
|
onClick: () => {
|
|
617
|
-
|
|
620
|
+
q && J().catch(() => void 0), Ze && Qe().catch(() => void 0);
|
|
618
621
|
},
|
|
619
622
|
children: [
|
|
620
|
-
/* @__PURE__ */ b(
|
|
623
|
+
/* @__PURE__ */ b(ue, {
|
|
621
624
|
size: 14,
|
|
622
625
|
"aria-hidden": "true"
|
|
623
626
|
}),
|
|
624
627
|
" ",
|
|
625
|
-
|
|
628
|
+
c("bigconsole.insights.error.retry", "Retry")
|
|
626
629
|
]
|
|
627
630
|
})
|
|
628
631
|
})
|
|
@@ -633,7 +636,7 @@ var N = s(function() {
|
|
|
633
636
|
headingLevel: 2,
|
|
634
637
|
title: "Describe your dashboard",
|
|
635
638
|
description: "One or two sentences is enough — name the metrics, the breakdowns and who will read it.",
|
|
636
|
-
icon: /* @__PURE__ */ b(
|
|
639
|
+
icon: /* @__PURE__ */ b(h, { className: "h-icon-sm w-icon-sm" }),
|
|
637
640
|
"data-testid": "insights-prompt",
|
|
638
641
|
children: /* @__PURE__ */ x("div", {
|
|
639
642
|
style: {
|
|
@@ -650,13 +653,13 @@ var N = s(function() {
|
|
|
650
653
|
fontWeight: "var(--font-weight-medium)",
|
|
651
654
|
color: "var(--color-text-primary)"
|
|
652
655
|
},
|
|
653
|
-
children:
|
|
656
|
+
children: c("bigconsole.insights.prompt.label", "Your prompt")
|
|
654
657
|
}),
|
|
655
658
|
/* @__PURE__ */ b("textarea", {
|
|
656
659
|
id: "prompt-input",
|
|
657
|
-
value:
|
|
660
|
+
value: _,
|
|
658
661
|
onChange: (e) => S(e.target.value),
|
|
659
|
-
placeholder:
|
|
662
|
+
placeholder: c("bigconsole.insights.prompt.placeholder", "e.g., Create a sales dashboard showing revenue trends, top products, and regional performance"),
|
|
660
663
|
rows: 3,
|
|
661
664
|
maxLength: 2e3,
|
|
662
665
|
className: n,
|
|
@@ -672,12 +675,12 @@ var N = s(function() {
|
|
|
672
675
|
resize: "vertical"
|
|
673
676
|
},
|
|
674
677
|
onKeyDown: (e) => {
|
|
675
|
-
e.key === "Enter" && (e.metaKey || e.ctrlKey) && (e.preventDefault(),
|
|
678
|
+
e.key === "Enter" && (e.metaKey || e.ctrlKey) && (e.preventDefault(), ot());
|
|
676
679
|
}
|
|
677
680
|
}),
|
|
678
681
|
/* @__PURE__ */ x("div", {
|
|
679
682
|
role: "group",
|
|
680
|
-
"aria-label":
|
|
683
|
+
"aria-label": c("bigconsole.insights.prompt.optionsLabel", "Generation options"),
|
|
681
684
|
"data-testid": "insights-generation-options",
|
|
682
685
|
style: {
|
|
683
686
|
display: "grid",
|
|
@@ -688,14 +691,14 @@ var N = s(function() {
|
|
|
688
691
|
/* @__PURE__ */ x("div", { children: [/* @__PURE__ */ b("label", {
|
|
689
692
|
htmlFor: "prompt-style",
|
|
690
693
|
style: E,
|
|
691
|
-
children:
|
|
694
|
+
children: c("bigconsole.insights.prompt.style", "Style")
|
|
692
695
|
}), /* @__PURE__ */ b("select", {
|
|
693
696
|
id: "prompt-style",
|
|
694
697
|
value: C,
|
|
695
698
|
onChange: (e) => k(e.target.value),
|
|
696
699
|
className: n,
|
|
697
700
|
style: D,
|
|
698
|
-
children:
|
|
701
|
+
children: je.map((e) => /* @__PURE__ */ b("option", {
|
|
699
702
|
value: e.value,
|
|
700
703
|
children: e.label
|
|
701
704
|
}, e.value))
|
|
@@ -703,14 +706,14 @@ var N = s(function() {
|
|
|
703
706
|
/* @__PURE__ */ x("div", { children: [/* @__PURE__ */ b("label", {
|
|
704
707
|
htmlFor: "prompt-layout",
|
|
705
708
|
style: E,
|
|
706
|
-
children:
|
|
709
|
+
children: c("bigconsole.insights.prompt.layout", "Layout")
|
|
707
710
|
}), /* @__PURE__ */ b("select", {
|
|
708
711
|
id: "prompt-layout",
|
|
709
712
|
value: A,
|
|
710
|
-
onChange: (e) =>
|
|
713
|
+
onChange: (e) => Le(e.target.value),
|
|
711
714
|
className: n,
|
|
712
715
|
style: D,
|
|
713
|
-
children:
|
|
716
|
+
children: Me.map((e) => /* @__PURE__ */ b("option", {
|
|
714
717
|
value: e.value,
|
|
715
718
|
children: e.label
|
|
716
719
|
}, e.value))
|
|
@@ -718,14 +721,14 @@ var N = s(function() {
|
|
|
718
721
|
/* @__PURE__ */ x("div", { children: [/* @__PURE__ */ b("label", {
|
|
719
722
|
htmlFor: "prompt-columns",
|
|
720
723
|
style: E,
|
|
721
|
-
children:
|
|
724
|
+
children: c("bigconsole.insights.prompt.columns", "Columns")
|
|
722
725
|
}), /* @__PURE__ */ b("select", {
|
|
723
726
|
id: "prompt-columns",
|
|
724
727
|
value: j,
|
|
725
|
-
onChange: (e) =>
|
|
728
|
+
onChange: (e) => N(Number(e.target.value)),
|
|
726
729
|
className: n,
|
|
727
730
|
style: D,
|
|
728
|
-
children:
|
|
731
|
+
children: Ne.map((e) => /* @__PURE__ */ b("option", {
|
|
729
732
|
value: e,
|
|
730
733
|
children: e
|
|
731
734
|
}, e))
|
|
@@ -733,14 +736,14 @@ var N = s(function() {
|
|
|
733
736
|
/* @__PURE__ */ x("div", { children: [/* @__PURE__ */ b("label", {
|
|
734
737
|
htmlFor: "prompt-max-widgets",
|
|
735
738
|
style: E,
|
|
736
|
-
children:
|
|
739
|
+
children: c("bigconsole.insights.prompt.maxWidgets", "Max widgets")
|
|
737
740
|
}), /* @__PURE__ */ b("select", {
|
|
738
741
|
id: "prompt-max-widgets",
|
|
739
|
-
value:
|
|
740
|
-
onChange: (e) =>
|
|
742
|
+
value: P,
|
|
743
|
+
onChange: (e) => We(Number(e.target.value)),
|
|
741
744
|
className: n,
|
|
742
745
|
style: D,
|
|
743
|
-
children:
|
|
746
|
+
children: Pe.map((e) => /* @__PURE__ */ b("option", {
|
|
744
747
|
value: e,
|
|
745
748
|
children: e
|
|
746
749
|
}, e))
|
|
@@ -764,41 +767,41 @@ var N = s(function() {
|
|
|
764
767
|
color: "var(--color-text-muted)"
|
|
765
768
|
},
|
|
766
769
|
children: [
|
|
767
|
-
|
|
770
|
+
c("bigconsole.insights.prompt.hint", "Press Ctrl+Enter to generate"),
|
|
768
771
|
" · ",
|
|
769
|
-
|
|
772
|
+
_.length,
|
|
770
773
|
"/2000"
|
|
771
774
|
]
|
|
772
775
|
}), /* @__PURE__ */ x("button", {
|
|
773
776
|
type: "button",
|
|
774
|
-
onClick:
|
|
775
|
-
disabled: !
|
|
777
|
+
onClick: ot,
|
|
778
|
+
disabled: !_.trim() || F,
|
|
776
779
|
className: n,
|
|
777
780
|
style: {
|
|
778
781
|
...T,
|
|
779
782
|
marginLeft: "auto",
|
|
780
|
-
cursor: !
|
|
781
|
-
opacity: !
|
|
783
|
+
cursor: !_.trim() || F ? "not-allowed" : "pointer",
|
|
784
|
+
opacity: !_.trim() || F ? .5 : 1
|
|
782
785
|
},
|
|
783
|
-
children: [
|
|
786
|
+
children: [F ? /* @__PURE__ */ b(m, {
|
|
784
787
|
size: 16,
|
|
785
788
|
className: "animate-spin",
|
|
786
789
|
"aria-hidden": "true"
|
|
787
|
-
}) : /* @__PURE__ */ b(
|
|
790
|
+
}) : /* @__PURE__ */ b(h, {
|
|
788
791
|
size: 16,
|
|
789
792
|
"aria-hidden": "true"
|
|
790
|
-
}),
|
|
793
|
+
}), c("bigconsole.insights.prompt.generateButton", "Generate dashboard")]
|
|
791
794
|
})]
|
|
792
795
|
})
|
|
793
796
|
]
|
|
794
797
|
})
|
|
795
798
|
}),
|
|
796
|
-
|
|
799
|
+
at.length > 0 && /* @__PURE__ */ b(r, {
|
|
797
800
|
emphasis: "muted",
|
|
798
801
|
headingLevel: 2,
|
|
799
|
-
title:
|
|
802
|
+
title: c("bigconsole.insights.suggestions.heading", "Starting points"),
|
|
800
803
|
description: "Pick one to drop it into the prompt box above, then edit it before generating.",
|
|
801
|
-
icon: /* @__PURE__ */ b(
|
|
804
|
+
icon: /* @__PURE__ */ b(le, { className: "h-icon-sm w-icon-sm" }),
|
|
802
805
|
"data-testid": "insights-suggestions",
|
|
803
806
|
children: /* @__PURE__ */ b("div", {
|
|
804
807
|
style: {
|
|
@@ -806,9 +809,9 @@ var N = s(function() {
|
|
|
806
809
|
gridTemplateColumns: "repeat(auto-fill, minmax(min(260px, 100%), 1fr))",
|
|
807
810
|
gap: "var(--space-controlGap)"
|
|
808
811
|
},
|
|
809
|
-
children:
|
|
812
|
+
children: at.map((e) => /* @__PURE__ */ x("button", {
|
|
810
813
|
type: "button",
|
|
811
|
-
onClick: () =>
|
|
814
|
+
onClick: () => dt(e.prompt),
|
|
812
815
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
813
816
|
style: {
|
|
814
817
|
textAlign: "left",
|
|
@@ -860,19 +863,19 @@ var N = s(function() {
|
|
|
860
863
|
emphasis: "bare",
|
|
861
864
|
padding: "none",
|
|
862
865
|
headingLevel: 2,
|
|
863
|
-
title:
|
|
866
|
+
title: c("bigconsole.insights.generations.heading", "Recent generations"),
|
|
864
867
|
description: "Newest first. A generation stays a proposal until you create the dashboard from it.",
|
|
865
|
-
icon: /* @__PURE__ */ b(
|
|
866
|
-
meta:
|
|
868
|
+
icon: /* @__PURE__ */ b(ce, { className: "h-icon-sm w-icon-sm" }),
|
|
869
|
+
meta: Z.length > 0 ? /* @__PURE__ */ x("span", {
|
|
867
870
|
style: O,
|
|
868
871
|
children: [
|
|
869
|
-
|
|
872
|
+
Z.length,
|
|
870
873
|
" generation",
|
|
871
|
-
|
|
874
|
+
Z.length === 1 ? "" : "s"
|
|
872
875
|
]
|
|
873
876
|
}) : void 0,
|
|
874
877
|
"data-testid": "insights-generations",
|
|
875
|
-
children:
|
|
878
|
+
children: Je && Z.length === 0 ? /* @__PURE__ */ b(r, {
|
|
876
879
|
emphasis: "muted",
|
|
877
880
|
headingLevel: 3,
|
|
878
881
|
"aria-label": "Loading generations",
|
|
@@ -888,42 +891,42 @@ var N = s(function() {
|
|
|
888
891
|
gap: "var(--space-controlGap)",
|
|
889
892
|
color: "var(--color-text-muted)"
|
|
890
893
|
},
|
|
891
|
-
children: [/* @__PURE__ */ b(
|
|
894
|
+
children: [/* @__PURE__ */ b(m, {
|
|
892
895
|
size: 24,
|
|
893
896
|
className: "animate-spin",
|
|
894
897
|
"aria-hidden": "true"
|
|
895
898
|
}), /* @__PURE__ */ b("p", {
|
|
896
899
|
style: { fontSize: "var(--font-size-body-sm)" },
|
|
897
|
-
children:
|
|
900
|
+
children: c("bigconsole.insights.generations.loading", "Loading generations…")
|
|
898
901
|
})]
|
|
899
902
|
})
|
|
900
|
-
}) :
|
|
903
|
+
}) : Z.length === 0 && !F && !q ? /* @__PURE__ */ b(me, {
|
|
901
904
|
treatment: "insight",
|
|
902
905
|
className: "border-[var(--color-border-seam)]",
|
|
903
|
-
children: /* @__PURE__ */ b(
|
|
906
|
+
children: /* @__PURE__ */ b(ge, {
|
|
904
907
|
illustration: "onboarding",
|
|
905
|
-
title:
|
|
906
|
-
description:
|
|
908
|
+
title: c("bigconsole.insights.generations.emptyTitle", "No generations yet"),
|
|
909
|
+
description: c("bigconsole.insights.generations.emptyDescription", "Describe a dashboard above to get started")
|
|
907
910
|
})
|
|
908
911
|
}) : /* @__PURE__ */ x("div", {
|
|
909
912
|
className: "flex flex-col gap-list-gap",
|
|
910
|
-
children: [
|
|
913
|
+
children: [F && !X && /* @__PURE__ */ b(r, {
|
|
911
914
|
emphasis: "muted",
|
|
912
915
|
tone: "info",
|
|
913
916
|
padding: "compact",
|
|
914
917
|
headingLevel: 3,
|
|
915
918
|
title: "Sending your prompt…",
|
|
916
919
|
description: "The new generation appears here as soon as the backend accepts it.",
|
|
917
|
-
icon: /* @__PURE__ */ b(
|
|
920
|
+
icon: /* @__PURE__ */ b(m, { className: "h-icon-sm w-icon-sm animate-spin" }),
|
|
918
921
|
"data-testid": "insights-generation-pending"
|
|
919
|
-
}),
|
|
920
|
-
let t = e.generatedSpec, i = R.has(e.id), a =
|
|
922
|
+
}), Z.map((e) => {
|
|
923
|
+
let t = e.generatedSpec, i = R.has(e.id), a = Oe.includes(e.status);
|
|
921
924
|
return /* @__PURE__ */ x(r, {
|
|
922
925
|
emphasis: "standard",
|
|
923
926
|
padding: "compact",
|
|
924
927
|
headingLevel: 3,
|
|
925
|
-
title: t?.name || (a ?
|
|
926
|
-
meta: /* @__PURE__ */ b(
|
|
928
|
+
title: t?.name || (a ? c("bigconsole.insights.generations.generating", "Generating…") : "Untitled generation"),
|
|
929
|
+
meta: /* @__PURE__ */ b(Re, { status: e.status }),
|
|
927
930
|
description: e.prompt.length > 160 ? `${e.prompt.slice(0, 160)}…` : e.prompt,
|
|
928
931
|
"data-testid": "insights-generation-card",
|
|
929
932
|
bodyClassName: "flex flex-col gap-control-gap",
|
|
@@ -952,7 +955,7 @@ var N = s(function() {
|
|
|
952
955
|
]
|
|
953
956
|
}),
|
|
954
957
|
/* @__PURE__ */ x("span", {
|
|
955
|
-
style:
|
|
958
|
+
style: ze(t.overallConfidence),
|
|
956
959
|
children: [Math.round(t.overallConfidence * 100), "% confidence"]
|
|
957
960
|
})
|
|
958
961
|
]
|
|
@@ -963,7 +966,7 @@ var N = s(function() {
|
|
|
963
966
|
padding: "compact",
|
|
964
967
|
title: "Generation failed",
|
|
965
968
|
description: e.errorMessage,
|
|
966
|
-
icon: /* @__PURE__ */ b(
|
|
969
|
+
icon: /* @__PURE__ */ b(ae, { className: "h-icon-sm w-icon-sm" })
|
|
967
970
|
}),
|
|
968
971
|
/* @__PURE__ */ x("div", {
|
|
969
972
|
style: {
|
|
@@ -978,76 +981,76 @@ var N = s(function() {
|
|
|
978
981
|
a && /* @__PURE__ */ x("button", {
|
|
979
982
|
type: "button",
|
|
980
983
|
onClick: () => {
|
|
981
|
-
o("medium"),
|
|
984
|
+
o("medium"), ct(e.id);
|
|
982
985
|
},
|
|
983
986
|
disabled: i,
|
|
984
|
-
title:
|
|
987
|
+
title: c("bigconsole.insights.actions.cancelTitle", "Cancel generation"),
|
|
985
988
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
986
989
|
style: {
|
|
987
|
-
...
|
|
990
|
+
...Fe,
|
|
988
991
|
cursor: i ? "wait" : "pointer"
|
|
989
992
|
},
|
|
990
993
|
children: [
|
|
991
|
-
/* @__PURE__ */ b(
|
|
994
|
+
/* @__PURE__ */ b(oe, {
|
|
992
995
|
size: 14,
|
|
993
996
|
"aria-hidden": "true"
|
|
994
997
|
}),
|
|
995
998
|
" ",
|
|
996
|
-
|
|
999
|
+
c("bigconsole.insights.actions.cancel", "Cancel")
|
|
997
1000
|
]
|
|
998
1001
|
}),
|
|
999
1002
|
e.status === "COMPLETED" && t && /* @__PURE__ */ x("button", {
|
|
1000
1003
|
type: "button",
|
|
1001
|
-
onClick: () =>
|
|
1002
|
-
title:
|
|
1004
|
+
onClick: () => B(e),
|
|
1005
|
+
title: c("bigconsole.insights.actions.previewTitle", "Preview proposed layout"),
|
|
1003
1006
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
1004
1007
|
style: w,
|
|
1005
1008
|
children: [
|
|
1006
|
-
/* @__PURE__ */ b(
|
|
1009
|
+
/* @__PURE__ */ b(se, {
|
|
1007
1010
|
size: 14,
|
|
1008
1011
|
"aria-hidden": "true"
|
|
1009
1012
|
}),
|
|
1010
1013
|
" ",
|
|
1011
|
-
|
|
1014
|
+
c("bigconsole.insights.actions.preview", "Preview")
|
|
1012
1015
|
]
|
|
1013
1016
|
}),
|
|
1014
1017
|
e.status === "COMPLETED" && t && /* @__PURE__ */ x("button", {
|
|
1015
1018
|
type: "button",
|
|
1016
1019
|
onClick: () => {
|
|
1017
|
-
|
|
1020
|
+
H(e), W("");
|
|
1018
1021
|
},
|
|
1019
|
-
title:
|
|
1022
|
+
title: c("bigconsole.insights.actions.refineTitle", "Refine with instructions"),
|
|
1020
1023
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
1021
1024
|
style: w,
|
|
1022
1025
|
children: [
|
|
1023
|
-
/* @__PURE__ */ b(
|
|
1026
|
+
/* @__PURE__ */ b(g, {
|
|
1024
1027
|
size: 14,
|
|
1025
1028
|
"aria-hidden": "true"
|
|
1026
1029
|
}),
|
|
1027
1030
|
" ",
|
|
1028
|
-
|
|
1031
|
+
c("bigconsole.insights.actions.refine", "Refine")
|
|
1029
1032
|
]
|
|
1030
1033
|
}),
|
|
1031
1034
|
(e.status === "COMPLETED" || e.status === "FAILED" || e.status === "CANCELLED") && /* @__PURE__ */ x("button", {
|
|
1032
1035
|
type: "button",
|
|
1033
1036
|
onClick: () => {
|
|
1034
|
-
o("medium"),
|
|
1037
|
+
o("medium"), lt(e.id);
|
|
1035
1038
|
},
|
|
1036
1039
|
disabled: i,
|
|
1037
|
-
title:
|
|
1040
|
+
title: c("bigconsole.insights.actions.regenerateTitle", "Regenerate with the same prompt"),
|
|
1038
1041
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
1039
1042
|
style: {
|
|
1040
1043
|
...w,
|
|
1041
1044
|
cursor: i ? "wait" : "pointer"
|
|
1042
1045
|
},
|
|
1043
1046
|
children: [
|
|
1044
|
-
/* @__PURE__ */ b(
|
|
1047
|
+
/* @__PURE__ */ b(ue, {
|
|
1045
1048
|
size: 14,
|
|
1046
1049
|
className: i ? "animate-spin" : "",
|
|
1047
1050
|
"aria-hidden": "true"
|
|
1048
1051
|
}),
|
|
1049
1052
|
" ",
|
|
1050
|
-
|
|
1053
|
+
c("bigconsole.insights.actions.regenerate", "Regenerate")
|
|
1051
1054
|
]
|
|
1052
1055
|
}),
|
|
1053
1056
|
/* @__PURE__ */ x("div", {
|
|
@@ -1061,13 +1064,13 @@ var N = s(function() {
|
|
|
1061
1064
|
children: [
|
|
1062
1065
|
e.status === "COMPLETED" && !e.dashboardId && /* @__PURE__ */ x("button", {
|
|
1063
1066
|
type: "button",
|
|
1064
|
-
onClick: () =>
|
|
1067
|
+
onClick: () => Q(e.id),
|
|
1065
1068
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
1066
1069
|
style: T,
|
|
1067
1070
|
children: [
|
|
1068
|
-
|
|
1071
|
+
c("bigconsole.insights.actions.create", "Create dashboard"),
|
|
1069
1072
|
" ",
|
|
1070
|
-
/* @__PURE__ */ b(
|
|
1073
|
+
/* @__PURE__ */ b(d, {
|
|
1071
1074
|
size: 14,
|
|
1072
1075
|
"aria-hidden": "true"
|
|
1073
1076
|
})
|
|
@@ -1075,13 +1078,13 @@ var N = s(function() {
|
|
|
1075
1078
|
}),
|
|
1076
1079
|
e.dashboardId && /* @__PURE__ */ x("button", {
|
|
1077
1080
|
type: "button",
|
|
1078
|
-
onClick: () =>
|
|
1081
|
+
onClick: () => f(`/dashboards/${e.dashboardId ?? ""}`),
|
|
1079
1082
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
1080
1083
|
style: w,
|
|
1081
1084
|
children: [
|
|
1082
|
-
|
|
1085
|
+
c("bigconsole.insights.actions.viewDashboard", "View dashboard"),
|
|
1083
1086
|
" ",
|
|
1084
|
-
/* @__PURE__ */ b(
|
|
1087
|
+
/* @__PURE__ */ b(d, {
|
|
1085
1088
|
size: 14,
|
|
1086
1089
|
"aria-hidden": "true"
|
|
1087
1090
|
})
|
|
@@ -1090,13 +1093,13 @@ var N = s(function() {
|
|
|
1090
1093
|
/* @__PURE__ */ b("button", {
|
|
1091
1094
|
type: "button",
|
|
1092
1095
|
onClick: () => {
|
|
1093
|
-
o("medium"),
|
|
1096
|
+
o("medium"), st(e.id);
|
|
1094
1097
|
},
|
|
1095
|
-
title:
|
|
1096
|
-
"aria-label":
|
|
1098
|
+
title: c("bigconsole.insights.actions.deleteTitle", "Delete generation"),
|
|
1099
|
+
"aria-label": c("bigconsole.insights.actions.deleteTitle", "Delete generation"),
|
|
1097
1100
|
className: n,
|
|
1098
|
-
style:
|
|
1099
|
-
children: /* @__PURE__ */ b(
|
|
1101
|
+
style: Ie,
|
|
1102
|
+
children: /* @__PURE__ */ b(de, {
|
|
1100
1103
|
size: 14,
|
|
1101
1104
|
"aria-hidden": "true"
|
|
1102
1105
|
})
|
|
@@ -1112,11 +1115,11 @@ var N = s(function() {
|
|
|
1112
1115
|
})
|
|
1113
1116
|
] })]
|
|
1114
1117
|
}),
|
|
1115
|
-
|
|
1118
|
+
z && $ && /* @__PURE__ */ b("div", {
|
|
1116
1119
|
role: "dialog",
|
|
1117
1120
|
"aria-modal": "true",
|
|
1118
|
-
"aria-label":
|
|
1119
|
-
onClick: () =>
|
|
1121
|
+
"aria-label": c("bigconsole.insights.preview.ariaLabel", "Generation preview"),
|
|
1122
|
+
onClick: () => B(null),
|
|
1120
1123
|
style: {
|
|
1121
1124
|
position: "fixed",
|
|
1122
1125
|
inset: 0,
|
|
@@ -1169,14 +1172,14 @@ var N = s(function() {
|
|
|
1169
1172
|
})]
|
|
1170
1173
|
}), /* @__PURE__ */ b("button", {
|
|
1171
1174
|
type: "button",
|
|
1172
|
-
onClick: () =>
|
|
1173
|
-
"aria-label":
|
|
1175
|
+
onClick: () => B(null),
|
|
1176
|
+
"aria-label": c("bigconsole.insights.preview.close", "Close preview"),
|
|
1174
1177
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
1175
1178
|
style: {
|
|
1176
|
-
...
|
|
1179
|
+
...Ie,
|
|
1177
1180
|
color: "var(--color-text-muted)"
|
|
1178
1181
|
},
|
|
1179
|
-
children: /* @__PURE__ */ b(
|
|
1182
|
+
children: /* @__PURE__ */ b(fe, {
|
|
1180
1183
|
size: 18,
|
|
1181
1184
|
"aria-hidden": "true"
|
|
1182
1185
|
})
|
|
@@ -1217,11 +1220,12 @@ var N = s(function() {
|
|
|
1217
1220
|
]
|
|
1218
1221
|
}),
|
|
1219
1222
|
/* @__PURE__ */ x("span", {
|
|
1220
|
-
style:
|
|
1223
|
+
style: ze($.overallConfidence),
|
|
1221
1224
|
children: [Math.round($.overallConfidence * 100), "% confidence"]
|
|
1222
1225
|
})
|
|
1223
1226
|
]
|
|
1224
1227
|
}),
|
|
1228
|
+
/* @__PURE__ */ b(re, { metadata: z.processingMetadata }),
|
|
1225
1229
|
$.reasoning && /* @__PURE__ */ x("details", {
|
|
1226
1230
|
"data-testid": "preview-reasoning",
|
|
1227
1231
|
children: [/* @__PURE__ */ b("summary", {
|
|
@@ -1233,7 +1237,7 @@ var N = s(function() {
|
|
|
1233
1237
|
color: "var(--color-text-secondary)",
|
|
1234
1238
|
borderRadius: "var(--radius-button)"
|
|
1235
1239
|
},
|
|
1236
|
-
children:
|
|
1240
|
+
children: c("bigconsole.insights.preview.reasoningToggle", "Why these widgets?")
|
|
1237
1241
|
}), /* @__PURE__ */ b("p", {
|
|
1238
1242
|
style: {
|
|
1239
1243
|
marginTop: "var(--space-controlGap)",
|
|
@@ -1264,24 +1268,24 @@ var N = s(function() {
|
|
|
1264
1268
|
marginBottom: "var(--space-controlGap)"
|
|
1265
1269
|
},
|
|
1266
1270
|
children: [
|
|
1267
|
-
|
|
1271
|
+
c("bigconsole.insights.preview.proposedLayout", "Proposed layout"),
|
|
1268
1272
|
" · ",
|
|
1269
1273
|
e.gridColumns,
|
|
1270
1274
|
" ",
|
|
1271
|
-
|
|
1275
|
+
c("bigconsole.insights.preview.columns", "columns"),
|
|
1272
1276
|
" ·",
|
|
1273
1277
|
" ",
|
|
1274
1278
|
e.layout.toLowerCase().replaceAll("_", " ")
|
|
1275
1279
|
]
|
|
1276
1280
|
}), /* @__PURE__ */ b("div", {
|
|
1277
1281
|
className: "insights-proposal-grid",
|
|
1278
|
-
style:
|
|
1282
|
+
style: Ve(e.gridColumns),
|
|
1279
1283
|
children: e.widgets.map((t, n) => {
|
|
1280
|
-
let r =
|
|
1284
|
+
let r = Be(t.confidence);
|
|
1281
1285
|
return /* @__PURE__ */ x("div", {
|
|
1282
1286
|
className: "insights-proposal-widget",
|
|
1283
1287
|
style: {
|
|
1284
|
-
...
|
|
1288
|
+
...He(t.position, e.gridColumns),
|
|
1285
1289
|
display: "flex",
|
|
1286
1290
|
flexDirection: "column",
|
|
1287
1291
|
gap: "2px",
|
|
@@ -1290,49 +1294,53 @@ var N = s(function() {
|
|
|
1290
1294
|
backgroundColor: "var(--color-bg-surface)",
|
|
1291
1295
|
border: "1px solid var(--color-border-subtle)"
|
|
1292
1296
|
},
|
|
1293
|
-
children: [
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
|
|
1297
|
-
|
|
1298
|
-
|
|
1299
|
-
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
|
|
1315
|
-
|
|
1316
|
-
|
|
1317
|
-
|
|
1318
|
-
|
|
1319
|
-
|
|
1320
|
-
|
|
1321
|
-
|
|
1322
|
-
|
|
1323
|
-
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
|
|
1328
|
-
|
|
1329
|
-
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
|
|
1297
|
+
children: [
|
|
1298
|
+
/* @__PURE__ */ x("div", {
|
|
1299
|
+
style: {
|
|
1300
|
+
display: "flex",
|
|
1301
|
+
flexWrap: "wrap",
|
|
1302
|
+
alignItems: "center",
|
|
1303
|
+
gap: "var(--space-iconGap)"
|
|
1304
|
+
},
|
|
1305
|
+
children: [
|
|
1306
|
+
/* @__PURE__ */ b("span", {
|
|
1307
|
+
style: {
|
|
1308
|
+
fontSize: "var(--font-size-body-sm)",
|
|
1309
|
+
fontWeight: "var(--font-weight-medium)",
|
|
1310
|
+
color: "var(--color-text-primary)",
|
|
1311
|
+
minWidth: 0
|
|
1312
|
+
},
|
|
1313
|
+
children: t.title
|
|
1314
|
+
}),
|
|
1315
|
+
/* @__PURE__ */ b("span", {
|
|
1316
|
+
style: {
|
|
1317
|
+
fontSize: "var(--font-size-xs)",
|
|
1318
|
+
color: "var(--color-text-muted)"
|
|
1319
|
+
},
|
|
1320
|
+
"data-testid": "preview-widget-type",
|
|
1321
|
+
children: t.type
|
|
1322
|
+
}),
|
|
1323
|
+
r && /* @__PURE__ */ b("span", {
|
|
1324
|
+
style: {
|
|
1325
|
+
...Ue(r),
|
|
1326
|
+
marginLeft: "auto"
|
|
1327
|
+
},
|
|
1328
|
+
"data-testid": "preview-widget-confidence",
|
|
1329
|
+
children: r
|
|
1330
|
+
})
|
|
1331
|
+
]
|
|
1332
|
+
}),
|
|
1333
|
+
t.reasoning && /* @__PURE__ */ b("p", {
|
|
1334
|
+
style: {
|
|
1335
|
+
margin: 0,
|
|
1336
|
+
fontSize: "var(--font-size-xs)",
|
|
1337
|
+
lineHeight: "var(--font-lineHeight-normal)",
|
|
1338
|
+
color: "var(--color-text-muted)"
|
|
1339
|
+
},
|
|
1340
|
+
children: t.reasoning
|
|
1341
|
+
}),
|
|
1342
|
+
/* @__PURE__ */ b(ne, { config: t.config })
|
|
1343
|
+
]
|
|
1336
1344
|
}, n);
|
|
1337
1345
|
})
|
|
1338
1346
|
})]
|
|
@@ -1351,41 +1359,41 @@ var N = s(function() {
|
|
|
1351
1359
|
children: [
|
|
1352
1360
|
/* @__PURE__ */ b("button", {
|
|
1353
1361
|
type: "button",
|
|
1354
|
-
onClick: () =>
|
|
1362
|
+
onClick: () => B(null),
|
|
1355
1363
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
1356
1364
|
style: w,
|
|
1357
1365
|
children: "Close"
|
|
1358
1366
|
}),
|
|
1359
|
-
|
|
1367
|
+
z.status === "COMPLETED" && $ && /* @__PURE__ */ x("button", {
|
|
1360
1368
|
type: "button",
|
|
1361
1369
|
onClick: () => {
|
|
1362
|
-
let e =
|
|
1363
|
-
|
|
1370
|
+
let e = z;
|
|
1371
|
+
B(null), H(e), W("");
|
|
1364
1372
|
},
|
|
1365
|
-
title:
|
|
1373
|
+
title: c("bigconsole.insights.actions.refineTitle", "Refine with instructions"),
|
|
1366
1374
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
1367
1375
|
style: w,
|
|
1368
1376
|
children: [
|
|
1369
|
-
/* @__PURE__ */ b(
|
|
1377
|
+
/* @__PURE__ */ b(g, {
|
|
1370
1378
|
size: 14,
|
|
1371
1379
|
"aria-hidden": "true"
|
|
1372
1380
|
}),
|
|
1373
1381
|
" ",
|
|
1374
|
-
|
|
1382
|
+
c("bigconsole.insights.actions.refine", "Refine")
|
|
1375
1383
|
]
|
|
1376
1384
|
}),
|
|
1377
|
-
|
|
1385
|
+
z.status === "COMPLETED" && !z.dashboardId && /* @__PURE__ */ x("button", {
|
|
1378
1386
|
type: "button",
|
|
1379
1387
|
onClick: () => {
|
|
1380
|
-
let e =
|
|
1381
|
-
|
|
1388
|
+
let e = z.id;
|
|
1389
|
+
B(null), Q(e);
|
|
1382
1390
|
},
|
|
1383
1391
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
1384
1392
|
style: T,
|
|
1385
1393
|
children: [
|
|
1386
|
-
|
|
1394
|
+
c("bigconsole.insights.actions.create", "Create dashboard"),
|
|
1387
1395
|
" ",
|
|
1388
|
-
/* @__PURE__ */ b(
|
|
1396
|
+
/* @__PURE__ */ b(d, {
|
|
1389
1397
|
size: 14,
|
|
1390
1398
|
"aria-hidden": "true"
|
|
1391
1399
|
})
|
|
@@ -1396,11 +1404,11 @@ var N = s(function() {
|
|
|
1396
1404
|
]
|
|
1397
1405
|
})
|
|
1398
1406
|
}),
|
|
1399
|
-
|
|
1407
|
+
V && /* @__PURE__ */ b("div", {
|
|
1400
1408
|
role: "dialog",
|
|
1401
1409
|
"aria-modal": "true",
|
|
1402
|
-
"aria-label":
|
|
1403
|
-
onClick: () =>
|
|
1410
|
+
"aria-label": c("bigconsole.insights.refine.ariaLabel", "Refine generation"),
|
|
1411
|
+
onClick: () => H(null),
|
|
1404
1412
|
style: {
|
|
1405
1413
|
position: "fixed",
|
|
1406
1414
|
inset: 0,
|
|
@@ -1436,14 +1444,14 @@ var N = s(function() {
|
|
|
1436
1444
|
fontWeight: "var(--font-weight-semibold)",
|
|
1437
1445
|
color: "var(--color-text-primary)"
|
|
1438
1446
|
},
|
|
1439
|
-
children:
|
|
1447
|
+
children: c("bigconsole.insights.refine.heading", "Refine dashboard")
|
|
1440
1448
|
}), /* @__PURE__ */ b("p", {
|
|
1441
1449
|
style: {
|
|
1442
1450
|
fontSize: "var(--font-size-body-sm)",
|
|
1443
1451
|
color: "var(--color-text-secondary)",
|
|
1444
1452
|
marginTop: 2
|
|
1445
1453
|
},
|
|
1446
|
-
children:
|
|
1454
|
+
children: c("bigconsole.insights.refine.subtitle", "Describe what to change — the AI keeps the existing spec and applies your instructions.")
|
|
1447
1455
|
})]
|
|
1448
1456
|
}),
|
|
1449
1457
|
/* @__PURE__ */ x("div", {
|
|
@@ -1460,9 +1468,9 @@ var N = s(function() {
|
|
|
1460
1468
|
emphasis: "muted",
|
|
1461
1469
|
padding: "compact",
|
|
1462
1470
|
headingLevel: 3,
|
|
1463
|
-
title:
|
|
1464
|
-
description:
|
|
1465
|
-
icon: /* @__PURE__ */ b(
|
|
1471
|
+
title: V.generatedSpec?.name || "Current proposal",
|
|
1472
|
+
description: V.prompt.length > 240 ? `${V.prompt.slice(0, 240)}…` : V.prompt,
|
|
1473
|
+
icon: /* @__PURE__ */ b(h, { className: "h-icon-sm w-icon-sm" })
|
|
1466
1474
|
}), /* @__PURE__ */ x("div", {
|
|
1467
1475
|
style: {
|
|
1468
1476
|
display: "flex",
|
|
@@ -1480,11 +1488,11 @@ var N = s(function() {
|
|
|
1480
1488
|
children: "What should change?"
|
|
1481
1489
|
}), /* @__PURE__ */ b("textarea", {
|
|
1482
1490
|
id: "refine-input",
|
|
1483
|
-
value:
|
|
1484
|
-
onChange: (e) =>
|
|
1491
|
+
value: U,
|
|
1492
|
+
onChange: (e) => W(e.target.value),
|
|
1485
1493
|
maxLength: 2e3,
|
|
1486
1494
|
rows: 4,
|
|
1487
|
-
placeholder:
|
|
1495
|
+
placeholder: c("bigconsole.insights.refine.placeholder", "e.g., Add a revenue-by-region map and remove the duplicate KPI cards"),
|
|
1488
1496
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
1489
1497
|
style: {
|
|
1490
1498
|
width: "100%",
|
|
@@ -1511,28 +1519,28 @@ var N = s(function() {
|
|
|
1511
1519
|
},
|
|
1512
1520
|
children: [/* @__PURE__ */ b("button", {
|
|
1513
1521
|
type: "button",
|
|
1514
|
-
onClick: () =>
|
|
1522
|
+
onClick: () => H(null),
|
|
1515
1523
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
1516
1524
|
style: w,
|
|
1517
|
-
children:
|
|
1525
|
+
children: c("bigconsole.insights.actions.cancel", "Cancel")
|
|
1518
1526
|
}), /* @__PURE__ */ x("button", {
|
|
1519
1527
|
type: "button",
|
|
1520
|
-
onClick: () => void
|
|
1521
|
-
disabled: !
|
|
1528
|
+
onClick: () => void ut(),
|
|
1529
|
+
disabled: !U.trim() || R.has(V.id),
|
|
1522
1530
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
1523
1531
|
style: {
|
|
1524
1532
|
...T,
|
|
1525
|
-
cursor: !
|
|
1526
|
-
opacity:
|
|
1533
|
+
cursor: !U.trim() || R.has(V.id) ? "not-allowed" : "pointer",
|
|
1534
|
+
opacity: U.trim() ? 1 : .6
|
|
1527
1535
|
},
|
|
1528
|
-
children: [R.has(
|
|
1536
|
+
children: [R.has(V.id) ? /* @__PURE__ */ b(m, {
|
|
1529
1537
|
size: 14,
|
|
1530
1538
|
className: "animate-spin",
|
|
1531
1539
|
"aria-hidden": "true"
|
|
1532
|
-
}) : /* @__PURE__ */ b(
|
|
1540
|
+
}) : /* @__PURE__ */ b(g, {
|
|
1533
1541
|
size: 14,
|
|
1534
1542
|
"aria-hidden": "true"
|
|
1535
|
-
}),
|
|
1543
|
+
}), c("bigconsole.insights.refine.apply", "Apply refinement")]
|
|
1536
1544
|
})]
|
|
1537
1545
|
})
|
|
1538
1546
|
]
|
|
@@ -1542,4 +1550,4 @@ var N = s(function() {
|
|
|
1542
1550
|
});
|
|
1543
1551
|
});
|
|
1544
1552
|
//#endregion
|
|
1545
|
-
export {
|
|
1553
|
+
export { P as InsightsPage, P as default };
|