@burdenoff/microfe-bigconsole 2026.1004.3 → 2026.1004.4
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/BigConsoleRoutes.d.ts +1 -1
- package/dist/bigconsole/BigConsoleRoutes.d.ts.map +1 -1
- package/dist/bigconsole/BigConsoleRoutes.js +15 -1
- package/dist/bigconsole/BigConsoleRoutes.js.map +1 -1
- package/dist/bigconsole/components/DrilldownModal.d.ts.map +1 -1
- package/dist/bigconsole/components/DrilldownModal.js +54 -53
- package/dist/bigconsole/components/DrilldownModal.js.map +1 -1
- package/dist/bigconsole/components/builder/inspector/DataBindingSection.d.ts +3 -1
- package/dist/bigconsole/components/builder/inspector/DataBindingSection.d.ts.map +1 -1
- package/dist/bigconsole/components/builder/inspector/DataBindingSection.js +40 -39
- package/dist/bigconsole/components/builder/inspector/DataBindingSection.js.map +1 -1
- package/dist/bigconsole/components/dashboard/DashboardCanvas.d.ts.map +1 -1
- package/dist/bigconsole/components/dashboard/DashboardCanvas.js +184 -177
- package/dist/bigconsole/components/dashboard/DashboardCanvas.js.map +1 -1
- package/dist/bigconsole/components/dashboard/DashboardGrid.d.ts.map +1 -1
- package/dist/bigconsole/components/dashboard/DashboardGrid.js +40 -22
- package/dist/bigconsole/components/dashboard/DashboardGrid.js.map +1 -1
- package/dist/bigconsole/components/dashboard/ExportDashboardDialog.d.ts.map +1 -1
- package/dist/bigconsole/components/dashboard/ExportDashboardDialog.js +31 -25
- package/dist/bigconsole/components/dashboard/ExportDashboardDialog.js.map +1 -1
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterEditor.d.ts +1 -1
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterEditor.d.ts.map +1 -1
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterEditor.js +115 -80
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterEditor.js.map +1 -1
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/GlobalFiltersBar.d.ts.map +1 -1
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/GlobalFiltersBar.js +177 -146
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/GlobalFiltersBar.js.map +1 -1
- package/dist/bigconsole/components/dashboard/ShareDialog/ShareDialog.d.ts +1 -1
- package/dist/bigconsole/components/dashboard/ShareDialog/ShareDialog.d.ts.map +1 -1
- package/dist/bigconsole/components/dashboard/ShareDialog/ShareDialog.js +375 -325
- package/dist/bigconsole/components/dashboard/ShareDialog/ShareDialog.js.map +1 -1
- package/dist/bigconsole/components/datasink/CacheTTLSelector.d.ts.map +1 -1
- package/dist/bigconsole/components/datasink/CacheTTLSelector.js +7 -1
- package/dist/bigconsole/components/datasink/CacheTTLSelector.js.map +1 -1
- package/dist/bigconsole/components/parser/ParserSelector.d.ts +3 -1
- package/dist/bigconsole/components/parser/ParserSelector.d.ts.map +1 -1
- package/dist/bigconsole/components/parser/ParserSelector.js +94 -94
- package/dist/bigconsole/components/parser/ParserSelector.js.map +1 -1
- package/dist/bigconsole/components/pipeline/PipelineCard.d.ts.map +1 -1
- package/dist/bigconsole/components/pipeline/PipelineCard.js +111 -89
- package/dist/bigconsole/components/pipeline/PipelineCard.js.map +1 -1
- package/dist/bigconsole/components/pipeline/PipelineScopePicker.d.ts +8 -0
- package/dist/bigconsole/components/pipeline/PipelineScopePicker.d.ts.map +1 -0
- package/dist/bigconsole/components/pipeline/PipelineScopePicker.js +52 -0
- package/dist/bigconsole/components/pipeline/PipelineScopePicker.js.map +1 -0
- package/dist/bigconsole/components/widgets/PropertiesPanel.d.ts.map +1 -1
- package/dist/bigconsole/components/widgets/PropertiesPanel.js +257 -221
- package/dist/bigconsole/components/widgets/PropertiesPanel.js.map +1 -1
- package/dist/bigconsole/components/widgets/WidgetHeader.d.ts +1 -0
- package/dist/bigconsole/components/widgets/WidgetHeader.d.ts.map +1 -1
- package/dist/bigconsole/components/widgets/WidgetHeader.js +29 -29
- package/dist/bigconsole/components/widgets/WidgetHeader.js.map +1 -1
- package/dist/bigconsole/components/widgets/WidgetWrapper.d.ts +2 -0
- package/dist/bigconsole/components/widgets/WidgetWrapper.d.ts.map +1 -1
- package/dist/bigconsole/components/widgets/WidgetWrapper.js +247 -239
- package/dist/bigconsole/components/widgets/WidgetWrapper.js.map +1 -1
- package/dist/bigconsole/components/widgets/metric-card/MetricCardWidget.d.ts.map +1 -1
- package/dist/bigconsole/components/widgets/metric-card/MetricCardWidget.js +6 -4
- package/dist/bigconsole/components/widgets/metric-card/MetricCardWidget.js.map +1 -1
- package/dist/bigconsole/components/widgets/states/EmptyState.d.ts +1 -0
- package/dist/bigconsole/components/widgets/states/EmptyState.d.ts.map +1 -1
- package/dist/bigconsole/components/widgets/states/EmptyState.js +4 -4
- package/dist/bigconsole/components/widgets/states/EmptyState.js.map +1 -1
- package/dist/bigconsole/components/workflow/WorkflowDesignPreview.d.ts +7 -0
- package/dist/bigconsole/components/workflow/WorkflowDesignPreview.d.ts.map +1 -0
- package/dist/bigconsole/components/workflow/WorkflowDesignPreview.js +94 -0
- package/dist/bigconsole/components/workflow/WorkflowDesignPreview.js.map +1 -0
- package/dist/bigconsole/components/workflow/WorkflowSinkLinkForm.d.ts +7 -0
- package/dist/bigconsole/components/workflow/WorkflowSinkLinkForm.d.ts.map +1 -0
- package/dist/bigconsole/components/workflow/WorkflowSinkLinkForm.js +101 -0
- package/dist/bigconsole/components/workflow/WorkflowSinkLinkForm.js.map +1 -0
- package/dist/bigconsole/hooks/useBigConsoleSettings.d.ts +16 -0
- package/dist/bigconsole/hooks/useBigConsoleSettings.d.ts.map +1 -0
- package/dist/bigconsole/hooks/useBigConsoleSettings.js +57 -0
- package/dist/bigconsole/hooks/useBigConsoleSettings.js.map +1 -0
- package/dist/bigconsole/hooks/useDashboardOperations.d.ts.map +1 -1
- package/dist/bigconsole/hooks/useDashboardOperations.js +102 -79
- package/dist/bigconsole/hooks/useDashboardOperations.js.map +1 -1
- package/dist/bigconsole/hooks/useExportDashboard.d.ts +3 -1
- package/dist/bigconsole/hooks/useExportDashboard.d.ts.map +1 -1
- package/dist/bigconsole/hooks/useExportDashboard.js +23 -13
- package/dist/bigconsole/hooks/useExportDashboard.js.map +1 -1
- package/dist/bigconsole/hooks/useFilterUrlSync.d.ts +18 -0
- package/dist/bigconsole/hooks/useFilterUrlSync.d.ts.map +1 -1
- package/dist/bigconsole/hooks/useFilterUrlSync.js +87 -57
- package/dist/bigconsole/hooks/useFilterUrlSync.js.map +1 -1
- package/dist/bigconsole/hooks/useGlobalFilters.d.ts.map +1 -1
- package/dist/bigconsole/hooks/useGlobalFilters.js +39 -29
- package/dist/bigconsole/hooks/useGlobalFilters.js.map +1 -1
- package/dist/bigconsole/hooks/usePageOperations.d.ts.map +1 -1
- package/dist/bigconsole/hooks/usePageOperations.js +1 -0
- package/dist/bigconsole/hooks/usePageOperations.js.map +1 -1
- package/dist/bigconsole/hooks/usePipelineOperations.d.ts.map +1 -1
- package/dist/bigconsole/hooks/usePipelineOperations.js +114 -112
- package/dist/bigconsole/hooks/usePipelineOperations.js.map +1 -1
- package/dist/bigconsole/hooks/useShareRecipients.d.ts +22 -0
- package/dist/bigconsole/hooks/useShareRecipients.d.ts.map +1 -0
- package/dist/bigconsole/hooks/useShareRecipients.js +198 -0
- package/dist/bigconsole/hooks/useShareRecipients.js.map +1 -0
- package/dist/bigconsole/pages/DashboardBuilderPage.d.ts.map +1 -1
- package/dist/bigconsole/pages/DashboardBuilderPage.js +198 -193
- package/dist/bigconsole/pages/DashboardBuilderPage.js.map +1 -1
- package/dist/bigconsole/pages/DashboardViewPage.d.ts.map +1 -1
- package/dist/bigconsole/pages/DashboardViewPage.js +171 -167
- package/dist/bigconsole/pages/DashboardViewPage.js.map +1 -1
- package/dist/bigconsole/pages/DashboardsPage.d.ts.map +1 -1
- package/dist/bigconsole/pages/DashboardsPage.js +313 -266
- package/dist/bigconsole/pages/DashboardsPage.js.map +1 -1
- package/dist/bigconsole/pages/DataSinkBuilderPage.d.ts.map +1 -1
- package/dist/bigconsole/pages/DataSinkBuilderPage.js +84 -79
- package/dist/bigconsole/pages/DataSinkBuilderPage.js.map +1 -1
- package/dist/bigconsole/pages/DataSinkViewPage.d.ts.map +1 -1
- package/dist/bigconsole/pages/DataSinkViewPage.js +267 -257
- package/dist/bigconsole/pages/DataSinkViewPage.js.map +1 -1
- package/dist/bigconsole/pages/InsightsPage.d.ts.map +1 -1
- package/dist/bigconsole/pages/InsightsPage.js +465 -402
- package/dist/bigconsole/pages/InsightsPage.js.map +1 -1
- package/dist/bigconsole/pages/PipelineBuilderPage.d.ts.map +1 -1
- package/dist/bigconsole/pages/PipelineBuilderPage.js +169 -157
- package/dist/bigconsole/pages/PipelineBuilderPage.js.map +1 -1
- package/dist/bigconsole/pages/PipelineViewPage.d.ts.map +1 -1
- package/dist/bigconsole/pages/PipelineViewPage.js +370 -230
- package/dist/bigconsole/pages/PipelineViewPage.js.map +1 -1
- package/dist/bigconsole/pages/PipelinesPage.d.ts.map +1 -1
- package/dist/bigconsole/pages/PipelinesPage.js +181 -151
- package/dist/bigconsole/pages/PipelinesPage.js.map +1 -1
- package/dist/bigconsole/pages/SettingsPage.d.ts.map +1 -1
- package/dist/bigconsole/pages/SettingsPage.js +188 -208
- package/dist/bigconsole/pages/SettingsPage.js.map +1 -1
- package/dist/bigconsole/pages/WidgetDemoPage.d.ts.map +1 -1
- package/dist/bigconsole/pages/WidgetDemoPage.js +134 -117
- package/dist/bigconsole/pages/WidgetDemoPage.js.map +1 -1
- package/dist/bigconsole/pages/WorkflowViewPage.d.ts.map +1 -1
- package/dist/bigconsole/pages/WorkflowViewPage.js +315 -267
- package/dist/bigconsole/pages/WorkflowViewPage.js.map +1 -1
- package/dist/bigconsole/pages/WorkflowsPage.d.ts.map +1 -1
- package/dist/bigconsole/pages/WorkflowsPage.js +4 -3
- package/dist/bigconsole/pages/WorkflowsPage.js.map +1 -1
- package/dist/bigconsole/types/index.d.ts +4 -0
- package/dist/bigconsole/types/index.d.ts.map +1 -1
- package/dist/generated/wspace-operations.d.ts +148 -0
- package/dist/generated/wspace-operations.d.ts.map +1 -1
- package/dist/generated/wspace-operations.js +172 -133
- package/dist/generated/wspace-operations.js.map +1 -1
- package/dist/generated/wspace-types.d.ts +21 -0
- package/dist/generated/wspace-types.d.ts.map +1 -1
- package/dist/generated/wspace-types.js.map +1 -1
- package/dist/microfe-bigconsole.css +1 -1
- package/dist/translations/en.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -5,16 +5,17 @@ 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
|
-
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
8
|
+
import { isNative as ee, nativeImpact as o, nativeNotify as te } from "../../utils/nativeBridge.js";
|
|
9
|
+
/* empty css */
|
|
10
|
+
import { memo as s, useCallback as c, useEffect as l, useState as u } from "react";
|
|
11
|
+
import { AlertCircle as d, ArrowRight as f, Ban as ne, CheckCircle as p, Clock as m, Eye as re, History as ie, Lightbulb as ae, Loader2 as h, RefreshCw as oe, Sparkles as g, Trash2 as se, Wand2 as _, X as ce, XCircle as v } from "lucide-react";
|
|
12
|
+
import { AuroraBackground as le, GlassCard as ue, GradientText as de, IllustratedEmptyState as fe, PagePurpose as pe } from "@burdenoff/fe-libs/ui";
|
|
13
|
+
import { useMutation as y, useQuery as me } from "@apollo/client/react";
|
|
14
|
+
import { jsx as b, jsxs as x } from "react/jsx-runtime";
|
|
15
|
+
import { gql as S } from "@apollo/client";
|
|
16
|
+
import { useI18n as C } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
16
17
|
//#region src/bigconsole/pages/InsightsPage.tsx
|
|
17
|
-
var
|
|
18
|
+
var he = S`
|
|
18
19
|
query ListPromptGenerations($status: PromptGenerationStatus, $first: Int) {
|
|
19
20
|
listPromptGenerations(status: $status, first: $first) {
|
|
20
21
|
edges {
|
|
@@ -33,7 +34,15 @@ var me = C`
|
|
|
33
34
|
reasoning
|
|
34
35
|
pages {
|
|
35
36
|
name
|
|
37
|
+
layout
|
|
38
|
+
gridColumns
|
|
36
39
|
widgets {
|
|
40
|
+
position {
|
|
41
|
+
x
|
|
42
|
+
y
|
|
43
|
+
width
|
|
44
|
+
height
|
|
45
|
+
}
|
|
37
46
|
title
|
|
38
47
|
type
|
|
39
48
|
confidence
|
|
@@ -46,7 +55,7 @@ var me = C`
|
|
|
46
55
|
totalCount
|
|
47
56
|
}
|
|
48
57
|
}
|
|
49
|
-
`,
|
|
58
|
+
`, ge = S`
|
|
50
59
|
query GetPromptSuggestions($category: String, $limit: Int) {
|
|
51
60
|
getPromptSuggestions(category: $category, limit: $limit) {
|
|
52
61
|
id
|
|
@@ -57,7 +66,7 @@ var me = C`
|
|
|
57
66
|
tags
|
|
58
67
|
}
|
|
59
68
|
}
|
|
60
|
-
`,
|
|
69
|
+
`, _e = S`
|
|
61
70
|
mutation GenerateDashboardFromPrompt($input: GenerateDashboardFromPromptInput!) {
|
|
62
71
|
generateDashboardFromPrompt(input: $input) {
|
|
63
72
|
id
|
|
@@ -65,24 +74,24 @@ var me = C`
|
|
|
65
74
|
prompt
|
|
66
75
|
}
|
|
67
76
|
}
|
|
68
|
-
`,
|
|
77
|
+
`, ve = S`
|
|
69
78
|
mutation CreateDashboardFromGeneration($input: CreateDashboardFromGenerationInput!) {
|
|
70
79
|
createDashboardFromGeneration(input: $input) {
|
|
71
80
|
id
|
|
72
81
|
}
|
|
73
82
|
}
|
|
74
|
-
`,
|
|
83
|
+
`, ye = S`
|
|
75
84
|
mutation DeletePromptGeneration($generationId: ID!) {
|
|
76
85
|
deletePromptGeneration(generationId: $generationId)
|
|
77
86
|
}
|
|
78
|
-
`,
|
|
87
|
+
`, be = S`
|
|
79
88
|
mutation CancelPromptGeneration($generationId: ID!) {
|
|
80
89
|
cancelPromptGeneration(generationId: $generationId) {
|
|
81
90
|
id
|
|
82
91
|
status
|
|
83
92
|
}
|
|
84
93
|
}
|
|
85
|
-
`,
|
|
94
|
+
`, xe = S`
|
|
86
95
|
mutation RegenerateDashboard($input: RegenerateDashboardInput!) {
|
|
87
96
|
regenerateDashboard(input: $input) {
|
|
88
97
|
id
|
|
@@ -90,7 +99,7 @@ var me = C`
|
|
|
90
99
|
prompt
|
|
91
100
|
}
|
|
92
101
|
}
|
|
93
|
-
`,
|
|
102
|
+
`, Se = S`
|
|
94
103
|
mutation RefineGeneratedDashboard($input: RefineGeneratedDashboardInput!) {
|
|
95
104
|
refineGeneratedDashboard(input: $input) {
|
|
96
105
|
id
|
|
@@ -98,11 +107,11 @@ var me = C`
|
|
|
98
107
|
prompt
|
|
99
108
|
}
|
|
100
109
|
}
|
|
101
|
-
`,
|
|
110
|
+
`, Ce = [
|
|
102
111
|
"PENDING",
|
|
103
112
|
"PROCESSING",
|
|
104
113
|
"GENERATING"
|
|
105
|
-
],
|
|
114
|
+
], we = 12, Te = 8, Ee = [
|
|
106
115
|
{
|
|
107
116
|
value: "MODERN",
|
|
108
117
|
label: "Modern"
|
|
@@ -123,7 +132,7 @@ var me = C`
|
|
|
123
132
|
value: "VIBRANT",
|
|
124
133
|
label: "Vibrant"
|
|
125
134
|
}
|
|
126
|
-
],
|
|
135
|
+
], De = [
|
|
127
136
|
{
|
|
128
137
|
value: "GRID",
|
|
129
138
|
label: "Grid"
|
|
@@ -148,20 +157,20 @@ var me = C`
|
|
|
148
157
|
value: "THREE_COLUMN",
|
|
149
158
|
label: "Three column"
|
|
150
159
|
}
|
|
151
|
-
],
|
|
160
|
+
], Oe = [
|
|
152
161
|
6,
|
|
153
162
|
8,
|
|
154
163
|
12,
|
|
155
164
|
16,
|
|
156
165
|
24
|
|
157
|
-
],
|
|
166
|
+
], ke = [
|
|
158
167
|
4,
|
|
159
168
|
6,
|
|
160
169
|
8,
|
|
161
170
|
12,
|
|
162
171
|
16,
|
|
163
172
|
24
|
|
164
|
-
],
|
|
173
|
+
], w = {
|
|
165
174
|
display: "inline-flex",
|
|
166
175
|
alignItems: "center",
|
|
167
176
|
justifyContent: "center",
|
|
@@ -173,35 +182,35 @@ var me = C`
|
|
|
173
182
|
fontWeight: "var(--font-weight-medium)",
|
|
174
183
|
lineHeight: 1.2,
|
|
175
184
|
cursor: "pointer"
|
|
176
|
-
},
|
|
177
|
-
...
|
|
185
|
+
}, T = {
|
|
186
|
+
...w,
|
|
178
187
|
border: "1px solid var(--color-border-default)",
|
|
179
188
|
backgroundColor: "transparent",
|
|
180
189
|
color: "var(--color-text-primary)"
|
|
181
|
-
},
|
|
182
|
-
...
|
|
190
|
+
}, E = {
|
|
191
|
+
...w,
|
|
183
192
|
border: "1px solid transparent",
|
|
184
193
|
backgroundColor: "var(--color-action-primary-bg)",
|
|
185
194
|
color: "var(--color-action-primary-text)"
|
|
186
|
-
},
|
|
187
|
-
...
|
|
195
|
+
}, Ae = {
|
|
196
|
+
...w,
|
|
188
197
|
border: "1px solid var(--color-status-warning-border)",
|
|
189
198
|
backgroundColor: "transparent",
|
|
190
199
|
color: "var(--color-status-warning-text)"
|
|
191
|
-
},
|
|
192
|
-
...
|
|
200
|
+
}, D = {
|
|
201
|
+
...w,
|
|
193
202
|
minWidth: "var(--size-controlHeight-md)",
|
|
194
203
|
padding: "0 var(--space-controlGap)",
|
|
195
204
|
border: "1px solid var(--color-border-default)",
|
|
196
205
|
backgroundColor: "transparent",
|
|
197
206
|
color: "var(--color-status-error-text)"
|
|
198
|
-
},
|
|
207
|
+
}, O = {
|
|
199
208
|
display: "block",
|
|
200
209
|
marginBottom: "2px",
|
|
201
210
|
fontSize: "var(--font-size-body-sm)",
|
|
202
211
|
fontWeight: "var(--font-weight-medium)",
|
|
203
212
|
color: "var(--color-text-secondary)"
|
|
204
|
-
},
|
|
213
|
+
}, k = {
|
|
205
214
|
width: "100%",
|
|
206
215
|
minHeight: "var(--size-controlHeight-md)",
|
|
207
216
|
padding: "0 var(--space-controlGap)",
|
|
@@ -210,7 +219,7 @@ var me = C`
|
|
|
210
219
|
backgroundColor: "var(--color-bg-canvas)",
|
|
211
220
|
color: "var(--color-text-primary)",
|
|
212
221
|
fontSize: "var(--font-size-body-sm)"
|
|
213
|
-
},
|
|
222
|
+
}, A = {
|
|
214
223
|
display: "inline-flex",
|
|
215
224
|
alignItems: "center",
|
|
216
225
|
gap: "var(--space-iconGap)",
|
|
@@ -222,7 +231,7 @@ var me = C`
|
|
|
222
231
|
backgroundColor: "var(--color-bg-sunken)",
|
|
223
232
|
color: "var(--color-text-secondary)"
|
|
224
233
|
};
|
|
225
|
-
function
|
|
234
|
+
function j(e) {
|
|
226
235
|
switch (e) {
|
|
227
236
|
case "COMPLETED": return "success";
|
|
228
237
|
case "FAILED": return "danger";
|
|
@@ -232,7 +241,7 @@ function M(e) {
|
|
|
232
241
|
default: return "neutral";
|
|
233
242
|
}
|
|
234
243
|
}
|
|
235
|
-
var
|
|
244
|
+
var M = {
|
|
236
245
|
success: {
|
|
237
246
|
text: "var(--color-status-success-text)",
|
|
238
247
|
bg: "var(--color-status-success-bgSubtle)",
|
|
@@ -254,36 +263,36 @@ var N = {
|
|
|
254
263
|
border: "var(--color-border-subtle)"
|
|
255
264
|
}
|
|
256
265
|
};
|
|
257
|
-
function
|
|
258
|
-
let t =
|
|
266
|
+
function je(e) {
|
|
267
|
+
let t = M[j(e)].text;
|
|
259
268
|
switch (e) {
|
|
260
|
-
case "COMPLETED": return /* @__PURE__ */
|
|
269
|
+
case "COMPLETED": return /* @__PURE__ */ b(p, {
|
|
261
270
|
size: 14,
|
|
262
271
|
style: { color: t },
|
|
263
272
|
"aria-hidden": "true"
|
|
264
273
|
});
|
|
265
274
|
case "FAILED":
|
|
266
|
-
case "CANCELLED": return /* @__PURE__ */
|
|
275
|
+
case "CANCELLED": return /* @__PURE__ */ b(v, {
|
|
267
276
|
size: 14,
|
|
268
277
|
style: { color: t },
|
|
269
278
|
"aria-hidden": "true"
|
|
270
279
|
});
|
|
271
280
|
case "PENDING":
|
|
272
281
|
case "PROCESSING":
|
|
273
|
-
case "GENERATING": return /* @__PURE__ */
|
|
282
|
+
case "GENERATING": return /* @__PURE__ */ b(h, {
|
|
274
283
|
size: 14,
|
|
275
284
|
className: "animate-spin",
|
|
276
285
|
style: { color: t },
|
|
277
286
|
"aria-hidden": "true"
|
|
278
287
|
});
|
|
279
|
-
default: return /* @__PURE__ */
|
|
288
|
+
default: return /* @__PURE__ */ b(m, {
|
|
280
289
|
size: 14,
|
|
281
290
|
style: { color: t },
|
|
282
291
|
"aria-hidden": "true"
|
|
283
292
|
});
|
|
284
293
|
}
|
|
285
294
|
}
|
|
286
|
-
function
|
|
295
|
+
function N(e, t) {
|
|
287
296
|
switch (e) {
|
|
288
297
|
case "COMPLETED": return t("bigconsole.insights.status.completed", "Completed");
|
|
289
298
|
case "FAILED": return t("bigconsole.insights.status.failed", "Failed");
|
|
@@ -294,44 +303,56 @@ function P(e, t) {
|
|
|
294
303
|
default: return e;
|
|
295
304
|
}
|
|
296
305
|
}
|
|
297
|
-
var
|
|
298
|
-
let { t } =
|
|
299
|
-
return /* @__PURE__ */
|
|
306
|
+
var Me = ({ status: e }) => {
|
|
307
|
+
let { t } = C(), n = M[j(e)];
|
|
308
|
+
return /* @__PURE__ */ x("span", {
|
|
300
309
|
"data-status": e,
|
|
301
310
|
style: {
|
|
302
|
-
...
|
|
311
|
+
...A,
|
|
303
312
|
border: `1px solid ${n.border}`,
|
|
304
313
|
backgroundColor: n.bg,
|
|
305
314
|
color: n.text
|
|
306
315
|
},
|
|
307
|
-
children: [
|
|
316
|
+
children: [je(e), N(e, t)]
|
|
308
317
|
});
|
|
309
318
|
};
|
|
310
|
-
function
|
|
311
|
-
let t =
|
|
319
|
+
function Ne(e) {
|
|
320
|
+
let t = M[e >= .8 ? "success" : e >= .5 ? "neutral" : "danger"];
|
|
312
321
|
return {
|
|
313
|
-
...
|
|
322
|
+
...A,
|
|
314
323
|
border: `1px solid ${t.border}`,
|
|
315
324
|
backgroundColor: t.bg,
|
|
316
325
|
color: t.text
|
|
317
326
|
};
|
|
318
327
|
}
|
|
319
|
-
function
|
|
328
|
+
function P(e) {
|
|
320
329
|
return e.pages.reduce((e, t) => e + t.widgets.length, 0);
|
|
321
330
|
}
|
|
322
|
-
function
|
|
331
|
+
function Pe(e) {
|
|
323
332
|
let t = e?.toUpperCase();
|
|
324
333
|
return t === "HIGH" || t === "MEDIUM" || t === "LOW" ? t : null;
|
|
325
334
|
}
|
|
326
|
-
var
|
|
335
|
+
var Fe = {
|
|
327
336
|
HIGH: "success",
|
|
328
337
|
MEDIUM: "neutral",
|
|
329
338
|
LOW: "danger"
|
|
330
339
|
};
|
|
331
|
-
function
|
|
332
|
-
|
|
340
|
+
function Ie(e) {
|
|
341
|
+
return { "--proposal-columns": Math.max(1, Math.min(24, Math.trunc(e))) };
|
|
342
|
+
}
|
|
343
|
+
function Le(e, t) {
|
|
344
|
+
let n = Math.max(1, Math.min(24, Math.trunc(t))), r = Math.max(0, Math.min(n - 1, Math.trunc(e.x)));
|
|
345
|
+
return {
|
|
346
|
+
"--proposal-column": r + 1,
|
|
347
|
+
"--proposal-width": Math.max(1, Math.min(n - r, Math.trunc(e.width))),
|
|
348
|
+
"--proposal-row": Math.max(1, Math.min(100, Math.trunc(e.y) + 1)),
|
|
349
|
+
"--proposal-height": Math.max(1, Math.min(24, Math.trunc(e.height)))
|
|
350
|
+
};
|
|
351
|
+
}
|
|
352
|
+
function Re(e) {
|
|
353
|
+
let t = M[Fe[e]];
|
|
333
354
|
return {
|
|
334
|
-
...
|
|
355
|
+
...A,
|
|
335
356
|
padding: "0 var(--space-controlGap)",
|
|
336
357
|
fontSize: "var(--font-size-xs)",
|
|
337
358
|
fontWeight: "var(--font-weight-semibold)",
|
|
@@ -341,138 +362,138 @@ function Fe(e) {
|
|
|
341
362
|
color: t.text
|
|
342
363
|
};
|
|
343
364
|
}
|
|
344
|
-
var
|
|
345
|
-
let { t:
|
|
346
|
-
|
|
347
|
-
}, []),
|
|
348
|
-
|
|
365
|
+
var F = s(function() {
|
|
366
|
+
let { t: s } = C(), p = e(), m = a(), [v, S] = u(""), [w, j] = u("MODERN"), [M, je] = u("GRID"), [N, Fe] = u(we), [F, ze] = u(Te), [I, Be] = u(!1), [Ve, L] = u(null), [R, He] = u(() => /* @__PURE__ */ new Set()), [z, B] = u(null), [V, H] = u(null), [U, W] = u(""), G = c((e) => {
|
|
367
|
+
He((t) => new Set(t).add(e));
|
|
368
|
+
}, []), K = c((e) => {
|
|
369
|
+
He((t) => {
|
|
349
370
|
let n = new Set(t);
|
|
350
371
|
return n.delete(e), n;
|
|
351
372
|
});
|
|
352
|
-
}, []), { data:
|
|
373
|
+
}, []), { data: Ue, loading: We, error: q, refetch: J, startPolling: Ge, stopPolling: Y } = me(he, {
|
|
353
374
|
variables: { first: 20 },
|
|
354
375
|
fetchPolicy: "cache-and-network"
|
|
355
|
-
}), X =
|
|
356
|
-
|
|
376
|
+
}), X = Ue?.listPromptGenerations?.edges?.some((e) => Ce.includes(e.node.status)) ?? !1, { data: Ke, error: qe, refetch: Je } = me(ge, { variables: { limit: 6 } }), [Ye] = y(_e), [Xe] = y(ve), [Ze] = y(ye), [Qe] = y(be), [$e] = y(xe), [et] = y(Se), Z = Ue?.listPromptGenerations?.edges?.map((e) => e.node) || [], tt = Ke?.getPromptSuggestions || [];
|
|
377
|
+
l(() => (X || I ? Ge(2e3) : Y(), () => Y()), [
|
|
357
378
|
X,
|
|
358
|
-
|
|
359
|
-
|
|
379
|
+
I,
|
|
380
|
+
Ge,
|
|
360
381
|
Y
|
|
361
|
-
]),
|
|
362
|
-
if (!
|
|
382
|
+
]), l(() => {
|
|
383
|
+
if (!z && !V) return;
|
|
363
384
|
let e = (e) => {
|
|
364
|
-
e.key === "Escape" && (
|
|
385
|
+
e.key === "Escape" && (B(null), H(null));
|
|
365
386
|
};
|
|
366
387
|
return window.addEventListener("keydown", e), () => window.removeEventListener("keydown", e);
|
|
367
|
-
}, [
|
|
368
|
-
let
|
|
369
|
-
if (!(!
|
|
370
|
-
if (
|
|
371
|
-
|
|
388
|
+
}, [z, V]);
|
|
389
|
+
let nt = c(async () => {
|
|
390
|
+
if (!(!v.trim() || I)) {
|
|
391
|
+
if (v.length > 2e3) {
|
|
392
|
+
L(s("bigconsole.insights.error.promptTooLong", "Prompt is too long (max 2000 characters)."));
|
|
372
393
|
return;
|
|
373
394
|
}
|
|
374
|
-
|
|
395
|
+
L(null), Be(!0);
|
|
375
396
|
try {
|
|
376
|
-
|
|
377
|
-
let e = await
|
|
378
|
-
prompt:
|
|
379
|
-
styleType:
|
|
380
|
-
layoutType:
|
|
381
|
-
gridColumns:
|
|
382
|
-
maxWidgets:
|
|
397
|
+
m("bigconsole.ai.generate_clicked", { maxWidgets: F });
|
|
398
|
+
let e = await Ye({ variables: { input: {
|
|
399
|
+
prompt: v.trim(),
|
|
400
|
+
styleType: w,
|
|
401
|
+
layoutType: M,
|
|
402
|
+
gridColumns: N,
|
|
403
|
+
maxWidgets: F
|
|
383
404
|
} } });
|
|
384
405
|
if (t(e, "command")) return;
|
|
385
406
|
let n = e.data?.generateDashboardFromPrompt?.id;
|
|
386
|
-
n &&
|
|
407
|
+
n && m("bigconsole.ai.dashboard_generated", {
|
|
387
408
|
generationId: n,
|
|
388
|
-
maxWidgets:
|
|
389
|
-
}),
|
|
409
|
+
maxWidgets: F
|
|
410
|
+
}), S(""), J();
|
|
390
411
|
} catch (e) {
|
|
391
412
|
if (t(e, "command")) return;
|
|
392
|
-
|
|
413
|
+
L(e instanceof Error ? e.message : s("bigconsole.insights.error.generateFailed", "Failed to generate dashboard"));
|
|
393
414
|
} finally {
|
|
394
|
-
|
|
415
|
+
Be(!1);
|
|
395
416
|
}
|
|
396
417
|
}
|
|
397
418
|
}, [
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
419
|
+
m,
|
|
420
|
+
v,
|
|
421
|
+
I,
|
|
422
|
+
Ye,
|
|
402
423
|
J,
|
|
403
|
-
|
|
424
|
+
w,
|
|
425
|
+
M,
|
|
404
426
|
N,
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
R(null);
|
|
427
|
+
F,
|
|
428
|
+
s
|
|
429
|
+
]), Q = c(async (e) => {
|
|
430
|
+
L(null);
|
|
410
431
|
try {
|
|
411
|
-
|
|
412
|
-
let n = await
|
|
432
|
+
m("bigconsole.ai.create_dashboard_clicked", { generationId: e });
|
|
433
|
+
let n = await Xe({ variables: { input: { generationId: e } } });
|
|
413
434
|
if (t(n, "project")) return;
|
|
414
435
|
let r = n.data?.createDashboardFromGeneration?.id;
|
|
415
|
-
r && (
|
|
436
|
+
r && (m("bigconsole.ai.dashboard_created", {
|
|
416
437
|
generationId: e,
|
|
417
438
|
dashboardId: r
|
|
418
|
-
}),
|
|
439
|
+
}), p(`/dashboards/${r}`));
|
|
419
440
|
} catch (e) {
|
|
420
441
|
if (t(e, "project")) return;
|
|
421
|
-
|
|
442
|
+
L(e instanceof Error ? e.message : s("bigconsole.insights.error.createFailed", "Failed to create dashboard"));
|
|
422
443
|
}
|
|
423
444
|
}, [
|
|
424
|
-
|
|
425
|
-
h,
|
|
445
|
+
Xe,
|
|
426
446
|
m,
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
447
|
+
p,
|
|
448
|
+
s
|
|
449
|
+
]), rt = c(async (e) => {
|
|
450
|
+
L(null);
|
|
430
451
|
try {
|
|
431
|
-
await
|
|
452
|
+
await Ze({ variables: { generationId: e } }), ee() && te("success"), J();
|
|
432
453
|
} catch (e) {
|
|
433
|
-
|
|
454
|
+
L(e instanceof Error ? e.message : s("bigconsole.insights.error.deleteFailed", "Failed to delete generation")), ee() && te("error");
|
|
434
455
|
}
|
|
435
456
|
}, [
|
|
436
|
-
|
|
457
|
+
Ze,
|
|
437
458
|
J,
|
|
438
|
-
|
|
439
|
-
]),
|
|
440
|
-
|
|
459
|
+
s
|
|
460
|
+
]), it = c(async (e) => {
|
|
461
|
+
L(null), G(e);
|
|
441
462
|
try {
|
|
442
|
-
await
|
|
463
|
+
await Qe({ variables: { generationId: e } }), J();
|
|
443
464
|
} catch (e) {
|
|
444
|
-
|
|
465
|
+
L(e instanceof Error ? e.message : s("bigconsole.insights.error.cancelFailed", "Failed to cancel generation"));
|
|
445
466
|
} finally {
|
|
446
|
-
|
|
467
|
+
K(e);
|
|
447
468
|
}
|
|
448
469
|
}, [
|
|
449
|
-
|
|
470
|
+
Qe,
|
|
450
471
|
J,
|
|
451
|
-
|
|
452
|
-
]),
|
|
453
|
-
|
|
472
|
+
s
|
|
473
|
+
]), at = c(async (e) => {
|
|
474
|
+
L(null), G(e);
|
|
454
475
|
try {
|
|
455
|
-
if (t(await
|
|
476
|
+
if (t(await $e({ variables: { input: { generationId: e } } }), "command")) return;
|
|
456
477
|
J();
|
|
457
478
|
} catch (e) {
|
|
458
479
|
if (t(e, "command")) return;
|
|
459
|
-
|
|
480
|
+
L(e instanceof Error ? e.message : s("bigconsole.insights.error.regenerateFailed", "Failed to regenerate dashboard"));
|
|
460
481
|
} finally {
|
|
461
|
-
|
|
482
|
+
K(e);
|
|
462
483
|
}
|
|
463
484
|
}, [
|
|
464
|
-
|
|
485
|
+
$e,
|
|
465
486
|
J,
|
|
466
|
-
|
|
467
|
-
]),
|
|
468
|
-
if (!
|
|
469
|
-
let e =
|
|
470
|
-
|
|
487
|
+
s
|
|
488
|
+
]), ot = c(async () => {
|
|
489
|
+
if (!V || !U.trim()) return;
|
|
490
|
+
let e = V.id;
|
|
491
|
+
L(null), G(e);
|
|
471
492
|
let n = !1;
|
|
472
493
|
try {
|
|
473
|
-
if (t(await
|
|
494
|
+
if (t(await et({ variables: { input: {
|
|
474
495
|
generationId: e,
|
|
475
|
-
refinementPrompt:
|
|
496
|
+
refinementPrompt: U.trim()
|
|
476
497
|
} } }), "command")) {
|
|
477
498
|
n = !0;
|
|
478
499
|
return;
|
|
@@ -483,29 +504,29 @@ var I = c(function() {
|
|
|
483
504
|
n = !0;
|
|
484
505
|
return;
|
|
485
506
|
}
|
|
486
|
-
|
|
507
|
+
L(e instanceof Error ? e.message : s("bigconsole.insights.error.refineFailed", "Failed to refine generation"));
|
|
487
508
|
} finally {
|
|
488
|
-
n && (
|
|
509
|
+
n && (H(null), W("")), K(e);
|
|
489
510
|
}
|
|
490
511
|
}, [
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
512
|
+
V,
|
|
513
|
+
U,
|
|
514
|
+
et,
|
|
494
515
|
J,
|
|
495
|
-
|
|
496
|
-
]),
|
|
497
|
-
|
|
498
|
-
}, []), $ =
|
|
499
|
-
return /* @__PURE__ */
|
|
516
|
+
s
|
|
517
|
+
]), st = c((e) => {
|
|
518
|
+
S(e);
|
|
519
|
+
}, []), $ = z?.generatedSpec;
|
|
520
|
+
return /* @__PURE__ */ x("div", {
|
|
500
521
|
"data-tour": "bigconsole-ai-insights",
|
|
501
522
|
className: "min-w-0",
|
|
502
523
|
style: { backgroundColor: "var(--color-bg-canvas)" },
|
|
503
524
|
children: [
|
|
504
|
-
/* @__PURE__ */
|
|
525
|
+
/* @__PURE__ */ x("header", {
|
|
505
526
|
className: "relative overflow-hidden border-b border-[var(--color-border-seam)] bg-[image:var(--gradient-gloss-card)]",
|
|
506
|
-
children: [/* @__PURE__ */
|
|
527
|
+
children: [/* @__PURE__ */ b(le, { intensity: "subtle" }), /* @__PURE__ */ b("div", {
|
|
507
528
|
style: { padding: "var(--space-pagePadding)" },
|
|
508
|
-
children: /* @__PURE__ */
|
|
529
|
+
children: /* @__PURE__ */ x("div", {
|
|
509
530
|
style: {
|
|
510
531
|
display: "flex",
|
|
511
532
|
alignItems: "center",
|
|
@@ -513,7 +534,7 @@ var I = c(function() {
|
|
|
513
534
|
flexWrap: "wrap",
|
|
514
535
|
minWidth: 0
|
|
515
536
|
},
|
|
516
|
-
children: [/* @__PURE__ */
|
|
537
|
+
children: [/* @__PURE__ */ b("div", {
|
|
517
538
|
style: {
|
|
518
539
|
display: "flex",
|
|
519
540
|
height: "var(--size-controlHeight-lg)",
|
|
@@ -524,63 +545,90 @@ var I = c(function() {
|
|
|
524
545
|
borderRadius: "var(--radius-card)",
|
|
525
546
|
backgroundColor: "var(--color-action-primary-bg)"
|
|
526
547
|
},
|
|
527
|
-
children: /* @__PURE__ */
|
|
548
|
+
children: /* @__PURE__ */ b(g, { style: {
|
|
528
549
|
height: "var(--size-icon-lg)",
|
|
529
550
|
width: "var(--size-icon-lg)",
|
|
530
551
|
color: "var(--color-action-primary-text)"
|
|
531
552
|
} })
|
|
532
|
-
}), /* @__PURE__ */
|
|
553
|
+
}), /* @__PURE__ */ x("div", {
|
|
533
554
|
style: { minWidth: 0 },
|
|
534
|
-
children: [/* @__PURE__ */
|
|
555
|
+
children: [/* @__PURE__ */ b("h1", {
|
|
535
556
|
className: "m-0 text-2xl font-bold text-text-primary",
|
|
536
|
-
children: /* @__PURE__ */
|
|
537
|
-
}), /* @__PURE__ */
|
|
557
|
+
children: /* @__PURE__ */ b(de, { children: s("bigconsole.insights.header.title", "AI Insights") })
|
|
558
|
+
}), /* @__PURE__ */ b("p", {
|
|
538
559
|
className: "m-0 text-sm text-text-secondary",
|
|
539
|
-
children:
|
|
560
|
+
children: s("bigconsole.insights.header.subtitle", "Generate dashboards from natural language prompts")
|
|
540
561
|
})]
|
|
541
562
|
})]
|
|
542
563
|
})
|
|
543
564
|
})]
|
|
544
565
|
}),
|
|
545
|
-
/* @__PURE__ */
|
|
566
|
+
/* @__PURE__ */ x("div", {
|
|
546
567
|
style: { padding: "var(--space-pagePadding)" },
|
|
547
|
-
children: [/* @__PURE__ */
|
|
568
|
+
children: [/* @__PURE__ */ b(pe, {
|
|
548
569
|
className: "mb-[var(--space-sectionGap)]",
|
|
549
570
|
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."
|
|
550
|
-
}), /* @__PURE__ */
|
|
551
|
-
|
|
571
|
+
}), /* @__PURE__ */ x(i, { children: [
|
|
572
|
+
Ve && /* @__PURE__ */ b(r, {
|
|
552
573
|
headingLevel: 2,
|
|
553
574
|
tone: "danger",
|
|
554
575
|
padding: "compact",
|
|
555
576
|
title: "That request did not go through",
|
|
556
|
-
description:
|
|
557
|
-
icon: /* @__PURE__ */
|
|
577
|
+
description: Ve,
|
|
578
|
+
icon: /* @__PURE__ */ b(d, { className: "h-icon-sm w-icon-sm" }),
|
|
558
579
|
"data-testid": "insights-error",
|
|
559
|
-
actions: /* @__PURE__ */
|
|
580
|
+
actions: /* @__PURE__ */ b("button", {
|
|
560
581
|
type: "button",
|
|
561
|
-
onClick: () =>
|
|
562
|
-
"aria-label":
|
|
582
|
+
onClick: () => L(null),
|
|
583
|
+
"aria-label": s("bigconsole.insights.error.dismiss", "Dismiss error"),
|
|
563
584
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
564
|
-
style:
|
|
585
|
+
style: T,
|
|
565
586
|
children: "Dismiss"
|
|
566
587
|
})
|
|
567
588
|
}),
|
|
568
|
-
/* @__PURE__ */
|
|
589
|
+
(q || qe) && /* @__PURE__ */ b("div", {
|
|
590
|
+
role: "alert",
|
|
591
|
+
children: /* @__PURE__ */ b(r, {
|
|
592
|
+
tone: "danger",
|
|
593
|
+
padding: "compact",
|
|
594
|
+
headingLevel: 2,
|
|
595
|
+
title: s("bigconsole.insights.error.loadFailed", "AI Insights could not be loaded"),
|
|
596
|
+
description: s("bigconsole.insights.error.loadFailedDescription", "Your saved generations and suggestions may be unavailable. Retry the failed request."),
|
|
597
|
+
"data-testid": "insights-load-error",
|
|
598
|
+
actions: /* @__PURE__ */ x("button", {
|
|
599
|
+
type: "button",
|
|
600
|
+
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
601
|
+
style: T,
|
|
602
|
+
onClick: () => {
|
|
603
|
+
q && J().catch(() => void 0), qe && Je().catch(() => void 0);
|
|
604
|
+
},
|
|
605
|
+
children: [
|
|
606
|
+
/* @__PURE__ */ b(oe, {
|
|
607
|
+
size: 14,
|
|
608
|
+
"aria-hidden": "true"
|
|
609
|
+
}),
|
|
610
|
+
" ",
|
|
611
|
+
s("bigconsole.insights.error.retry", "Retry")
|
|
612
|
+
]
|
|
613
|
+
})
|
|
614
|
+
})
|
|
615
|
+
}),
|
|
616
|
+
/* @__PURE__ */ b(r, {
|
|
569
617
|
id: "insights-prompt",
|
|
570
618
|
emphasis: "primary",
|
|
571
619
|
headingLevel: 2,
|
|
572
620
|
title: "Describe your dashboard",
|
|
573
621
|
description: "One or two sentences is enough — name the metrics, the breakdowns and who will read it.",
|
|
574
|
-
icon: /* @__PURE__ */
|
|
622
|
+
icon: /* @__PURE__ */ b(g, { className: "h-icon-sm w-icon-sm" }),
|
|
575
623
|
"data-testid": "insights-prompt",
|
|
576
|
-
children: /* @__PURE__ */
|
|
624
|
+
children: /* @__PURE__ */ x("div", {
|
|
577
625
|
style: {
|
|
578
626
|
display: "flex",
|
|
579
627
|
flexDirection: "column",
|
|
580
628
|
gap: "var(--space-controlGap)"
|
|
581
629
|
},
|
|
582
630
|
children: [
|
|
583
|
-
/* @__PURE__ */
|
|
631
|
+
/* @__PURE__ */ b("label", {
|
|
584
632
|
htmlFor: "prompt-input",
|
|
585
633
|
style: {
|
|
586
634
|
display: "block",
|
|
@@ -588,13 +636,13 @@ var I = c(function() {
|
|
|
588
636
|
fontWeight: "var(--font-weight-medium)",
|
|
589
637
|
color: "var(--color-text-primary)"
|
|
590
638
|
},
|
|
591
|
-
children:
|
|
639
|
+
children: s("bigconsole.insights.prompt.label", "Your prompt")
|
|
592
640
|
}),
|
|
593
|
-
/* @__PURE__ */
|
|
641
|
+
/* @__PURE__ */ b("textarea", {
|
|
594
642
|
id: "prompt-input",
|
|
595
|
-
value:
|
|
596
|
-
onChange: (e) =>
|
|
597
|
-
placeholder:
|
|
643
|
+
value: v,
|
|
644
|
+
onChange: (e) => S(e.target.value),
|
|
645
|
+
placeholder: s("bigconsole.insights.prompt.placeholder", "e.g., Create a sales dashboard showing revenue trends, top products, and regional performance"),
|
|
598
646
|
rows: 3,
|
|
599
647
|
maxLength: 2e3,
|
|
600
648
|
className: n,
|
|
@@ -610,12 +658,12 @@ var I = c(function() {
|
|
|
610
658
|
resize: "vertical"
|
|
611
659
|
},
|
|
612
660
|
onKeyDown: (e) => {
|
|
613
|
-
e.key === "Enter" && (e.metaKey || e.ctrlKey) &&
|
|
661
|
+
e.key === "Enter" && (e.metaKey || e.ctrlKey) && (e.preventDefault(), nt());
|
|
614
662
|
}
|
|
615
663
|
}),
|
|
616
|
-
/* @__PURE__ */
|
|
664
|
+
/* @__PURE__ */ x("div", {
|
|
617
665
|
role: "group",
|
|
618
|
-
"aria-label":
|
|
666
|
+
"aria-label": s("bigconsole.insights.prompt.optionsLabel", "Generation options"),
|
|
619
667
|
"data-testid": "insights-generation-options",
|
|
620
668
|
style: {
|
|
621
669
|
display: "grid",
|
|
@@ -623,69 +671,69 @@ var I = c(function() {
|
|
|
623
671
|
gap: "var(--space-controlGap)"
|
|
624
672
|
},
|
|
625
673
|
children: [
|
|
626
|
-
/* @__PURE__ */
|
|
674
|
+
/* @__PURE__ */ x("div", { children: [/* @__PURE__ */ b("label", {
|
|
627
675
|
htmlFor: "prompt-style",
|
|
628
|
-
style:
|
|
629
|
-
children:
|
|
630
|
-
}), /* @__PURE__ */
|
|
676
|
+
style: O,
|
|
677
|
+
children: s("bigconsole.insights.prompt.style", "Style")
|
|
678
|
+
}), /* @__PURE__ */ b("select", {
|
|
631
679
|
id: "prompt-style",
|
|
632
|
-
value:
|
|
633
|
-
onChange: (e) =>
|
|
680
|
+
value: w,
|
|
681
|
+
onChange: (e) => j(e.target.value),
|
|
634
682
|
className: n,
|
|
635
|
-
style:
|
|
636
|
-
children:
|
|
683
|
+
style: k,
|
|
684
|
+
children: Ee.map((e) => /* @__PURE__ */ b("option", {
|
|
637
685
|
value: e.value,
|
|
638
686
|
children: e.label
|
|
639
687
|
}, e.value))
|
|
640
688
|
})] }),
|
|
641
|
-
/* @__PURE__ */
|
|
689
|
+
/* @__PURE__ */ x("div", { children: [/* @__PURE__ */ b("label", {
|
|
642
690
|
htmlFor: "prompt-layout",
|
|
643
|
-
style:
|
|
644
|
-
children:
|
|
645
|
-
}), /* @__PURE__ */
|
|
691
|
+
style: O,
|
|
692
|
+
children: s("bigconsole.insights.prompt.layout", "Layout")
|
|
693
|
+
}), /* @__PURE__ */ b("select", {
|
|
646
694
|
id: "prompt-layout",
|
|
647
|
-
value:
|
|
648
|
-
onChange: (e) =>
|
|
695
|
+
value: M,
|
|
696
|
+
onChange: (e) => je(e.target.value),
|
|
649
697
|
className: n,
|
|
650
|
-
style:
|
|
651
|
-
children:
|
|
698
|
+
style: k,
|
|
699
|
+
children: De.map((e) => /* @__PURE__ */ b("option", {
|
|
652
700
|
value: e.value,
|
|
653
701
|
children: e.label
|
|
654
702
|
}, e.value))
|
|
655
703
|
})] }),
|
|
656
|
-
/* @__PURE__ */
|
|
704
|
+
/* @__PURE__ */ x("div", { children: [/* @__PURE__ */ b("label", {
|
|
657
705
|
htmlFor: "prompt-columns",
|
|
658
|
-
style:
|
|
659
|
-
children:
|
|
660
|
-
}), /* @__PURE__ */
|
|
706
|
+
style: O,
|
|
707
|
+
children: s("bigconsole.insights.prompt.columns", "Columns")
|
|
708
|
+
}), /* @__PURE__ */ b("select", {
|
|
661
709
|
id: "prompt-columns",
|
|
662
|
-
value:
|
|
663
|
-
onChange: (e) =>
|
|
710
|
+
value: N,
|
|
711
|
+
onChange: (e) => Fe(Number(e.target.value)),
|
|
664
712
|
className: n,
|
|
665
|
-
style:
|
|
666
|
-
children:
|
|
713
|
+
style: k,
|
|
714
|
+
children: Oe.map((e) => /* @__PURE__ */ b("option", {
|
|
667
715
|
value: e,
|
|
668
716
|
children: e
|
|
669
717
|
}, e))
|
|
670
718
|
})] }),
|
|
671
|
-
/* @__PURE__ */
|
|
719
|
+
/* @__PURE__ */ x("div", { children: [/* @__PURE__ */ b("label", {
|
|
672
720
|
htmlFor: "prompt-max-widgets",
|
|
673
|
-
style:
|
|
674
|
-
children:
|
|
675
|
-
}), /* @__PURE__ */
|
|
721
|
+
style: O,
|
|
722
|
+
children: s("bigconsole.insights.prompt.maxWidgets", "Max widgets")
|
|
723
|
+
}), /* @__PURE__ */ b("select", {
|
|
676
724
|
id: "prompt-max-widgets",
|
|
677
|
-
value:
|
|
678
|
-
onChange: (e) =>
|
|
725
|
+
value: F,
|
|
726
|
+
onChange: (e) => ze(Number(e.target.value)),
|
|
679
727
|
className: n,
|
|
680
|
-
style:
|
|
681
|
-
children:
|
|
728
|
+
style: k,
|
|
729
|
+
children: ke.map((e) => /* @__PURE__ */ b("option", {
|
|
682
730
|
value: e,
|
|
683
731
|
children: e
|
|
684
732
|
}, e))
|
|
685
733
|
})] })
|
|
686
734
|
]
|
|
687
735
|
}),
|
|
688
|
-
/* @__PURE__ */
|
|
736
|
+
/* @__PURE__ */ x("div", {
|
|
689
737
|
style: {
|
|
690
738
|
display: "flex",
|
|
691
739
|
alignItems: "center",
|
|
@@ -694,7 +742,7 @@ var I = c(function() {
|
|
|
694
742
|
borderTop: "1px solid var(--color-border-subtle)",
|
|
695
743
|
paddingTop: "var(--space-controlGap)"
|
|
696
744
|
},
|
|
697
|
-
children: [/* @__PURE__ */
|
|
745
|
+
children: [/* @__PURE__ */ x("span", {
|
|
698
746
|
style: {
|
|
699
747
|
flex: "1 1 12rem",
|
|
700
748
|
minWidth: 0,
|
|
@@ -702,51 +750,51 @@ var I = c(function() {
|
|
|
702
750
|
color: "var(--color-text-muted)"
|
|
703
751
|
},
|
|
704
752
|
children: [
|
|
705
|
-
|
|
753
|
+
s("bigconsole.insights.prompt.hint", "Press Ctrl+Enter to generate"),
|
|
706
754
|
" · ",
|
|
707
|
-
|
|
755
|
+
v.length,
|
|
708
756
|
"/2000"
|
|
709
757
|
]
|
|
710
|
-
}), /* @__PURE__ */
|
|
758
|
+
}), /* @__PURE__ */ x("button", {
|
|
711
759
|
type: "button",
|
|
712
|
-
onClick:
|
|
713
|
-
disabled: !
|
|
760
|
+
onClick: nt,
|
|
761
|
+
disabled: !v.trim() || I,
|
|
714
762
|
className: n,
|
|
715
763
|
style: {
|
|
716
|
-
...
|
|
764
|
+
...E,
|
|
717
765
|
marginLeft: "auto",
|
|
718
|
-
cursor: !
|
|
719
|
-
opacity: !
|
|
766
|
+
cursor: !v.trim() || I ? "not-allowed" : "pointer",
|
|
767
|
+
opacity: !v.trim() || I ? .5 : 1
|
|
720
768
|
},
|
|
721
|
-
children: [
|
|
769
|
+
children: [I ? /* @__PURE__ */ b(h, {
|
|
722
770
|
size: 16,
|
|
723
771
|
className: "animate-spin",
|
|
724
772
|
"aria-hidden": "true"
|
|
725
|
-
}) : /* @__PURE__ */
|
|
773
|
+
}) : /* @__PURE__ */ b(g, {
|
|
726
774
|
size: 16,
|
|
727
775
|
"aria-hidden": "true"
|
|
728
|
-
}),
|
|
776
|
+
}), s("bigconsole.insights.prompt.generateButton", "Generate dashboard")]
|
|
729
777
|
})]
|
|
730
778
|
})
|
|
731
779
|
]
|
|
732
780
|
})
|
|
733
781
|
}),
|
|
734
|
-
|
|
782
|
+
tt.length > 0 && /* @__PURE__ */ b(r, {
|
|
735
783
|
emphasis: "muted",
|
|
736
784
|
headingLevel: 2,
|
|
737
|
-
title:
|
|
785
|
+
title: s("bigconsole.insights.suggestions.heading", "Starting points"),
|
|
738
786
|
description: "Pick one to drop it into the prompt box above, then edit it before generating.",
|
|
739
|
-
icon: /* @__PURE__ */
|
|
787
|
+
icon: /* @__PURE__ */ b(ae, { className: "h-icon-sm w-icon-sm" }),
|
|
740
788
|
"data-testid": "insights-suggestions",
|
|
741
|
-
children: /* @__PURE__ */
|
|
789
|
+
children: /* @__PURE__ */ b("div", {
|
|
742
790
|
style: {
|
|
743
791
|
display: "grid",
|
|
744
792
|
gridTemplateColumns: "repeat(auto-fill, minmax(min(260px, 100%), 1fr))",
|
|
745
793
|
gap: "var(--space-controlGap)"
|
|
746
794
|
},
|
|
747
|
-
children:
|
|
795
|
+
children: tt.map((e) => /* @__PURE__ */ x("button", {
|
|
748
796
|
type: "button",
|
|
749
|
-
onClick: () =>
|
|
797
|
+
onClick: () => st(e.prompt),
|
|
750
798
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
751
799
|
style: {
|
|
752
800
|
textAlign: "left",
|
|
@@ -759,7 +807,7 @@ var I = c(function() {
|
|
|
759
807
|
cursor: "pointer"
|
|
760
808
|
},
|
|
761
809
|
children: [
|
|
762
|
-
/* @__PURE__ */
|
|
810
|
+
/* @__PURE__ */ b("span", {
|
|
763
811
|
style: {
|
|
764
812
|
display: "block",
|
|
765
813
|
fontWeight: "var(--font-weight-medium)",
|
|
@@ -769,7 +817,7 @@ var I = c(function() {
|
|
|
769
817
|
},
|
|
770
818
|
children: e.title
|
|
771
819
|
}),
|
|
772
|
-
/* @__PURE__ */
|
|
820
|
+
/* @__PURE__ */ b("span", {
|
|
773
821
|
style: {
|
|
774
822
|
display: "block",
|
|
775
823
|
fontSize: "var(--font-size-body-sm)",
|
|
@@ -778,15 +826,15 @@ var I = c(function() {
|
|
|
778
826
|
},
|
|
779
827
|
children: e.exampleDescription || e.prompt
|
|
780
828
|
}),
|
|
781
|
-
e.tags.length > 0 && /* @__PURE__ */
|
|
829
|
+
e.tags.length > 0 && /* @__PURE__ */ b("span", {
|
|
782
830
|
style: {
|
|
783
831
|
display: "flex",
|
|
784
832
|
gap: "var(--space-iconGap)",
|
|
785
833
|
marginTop: "var(--space-controlGap)",
|
|
786
834
|
flexWrap: "wrap"
|
|
787
835
|
},
|
|
788
|
-
children: e.tags.slice(0, 3).map((e) => /* @__PURE__ */
|
|
789
|
-
style:
|
|
836
|
+
children: e.tags.slice(0, 3).map((e) => /* @__PURE__ */ b("span", {
|
|
837
|
+
style: A,
|
|
790
838
|
children: e
|
|
791
839
|
}, e))
|
|
792
840
|
})
|
|
@@ -794,15 +842,15 @@ var I = c(function() {
|
|
|
794
842
|
}, e.id))
|
|
795
843
|
})
|
|
796
844
|
}),
|
|
797
|
-
/* @__PURE__ */
|
|
845
|
+
/* @__PURE__ */ b(r, {
|
|
798
846
|
emphasis: "bare",
|
|
799
847
|
padding: "none",
|
|
800
848
|
headingLevel: 2,
|
|
801
|
-
title:
|
|
849
|
+
title: s("bigconsole.insights.generations.heading", "Recent generations"),
|
|
802
850
|
description: "Newest first. A generation stays a proposal until you create the dashboard from it.",
|
|
803
|
-
icon: /* @__PURE__ */
|
|
804
|
-
meta: Z.length > 0 ? /* @__PURE__ */
|
|
805
|
-
style:
|
|
851
|
+
icon: /* @__PURE__ */ b(ie, { className: "h-icon-sm w-icon-sm" }),
|
|
852
|
+
meta: Z.length > 0 ? /* @__PURE__ */ x("span", {
|
|
853
|
+
style: A,
|
|
806
854
|
children: [
|
|
807
855
|
Z.length,
|
|
808
856
|
" generation",
|
|
@@ -810,13 +858,13 @@ var I = c(function() {
|
|
|
810
858
|
]
|
|
811
859
|
}) : void 0,
|
|
812
860
|
"data-testid": "insights-generations",
|
|
813
|
-
children:
|
|
861
|
+
children: We && Z.length === 0 ? /* @__PURE__ */ b(r, {
|
|
814
862
|
emphasis: "muted",
|
|
815
863
|
headingLevel: 3,
|
|
816
864
|
"aria-label": "Loading generations",
|
|
817
865
|
className: "min-h-[10rem]",
|
|
818
866
|
"data-testid": "insights-generations-loading",
|
|
819
|
-
children: /* @__PURE__ */
|
|
867
|
+
children: /* @__PURE__ */ x("div", {
|
|
820
868
|
style: {
|
|
821
869
|
display: "flex",
|
|
822
870
|
minHeight: "8rem",
|
|
@@ -826,84 +874,84 @@ var I = c(function() {
|
|
|
826
874
|
gap: "var(--space-controlGap)",
|
|
827
875
|
color: "var(--color-text-muted)"
|
|
828
876
|
},
|
|
829
|
-
children: [/* @__PURE__ */
|
|
877
|
+
children: [/* @__PURE__ */ b(h, {
|
|
830
878
|
size: 24,
|
|
831
879
|
className: "animate-spin",
|
|
832
880
|
"aria-hidden": "true"
|
|
833
|
-
}), /* @__PURE__ */
|
|
881
|
+
}), /* @__PURE__ */ b("p", {
|
|
834
882
|
style: { fontSize: "var(--font-size-body-sm)" },
|
|
835
|
-
children:
|
|
883
|
+
children: s("bigconsole.insights.generations.loading", "Loading generations…")
|
|
836
884
|
})]
|
|
837
885
|
})
|
|
838
|
-
}) : Z.length === 0 && !
|
|
886
|
+
}) : Z.length === 0 && !I && !q ? /* @__PURE__ */ b(ue, {
|
|
839
887
|
treatment: "insight",
|
|
840
888
|
className: "border-[var(--color-border-seam)]",
|
|
841
|
-
children: /* @__PURE__ */
|
|
889
|
+
children: /* @__PURE__ */ b(fe, {
|
|
842
890
|
illustration: "onboarding",
|
|
843
|
-
title:
|
|
844
|
-
description:
|
|
891
|
+
title: s("bigconsole.insights.generations.emptyTitle", "No generations yet"),
|
|
892
|
+
description: s("bigconsole.insights.generations.emptyDescription", "Describe a dashboard above to get started")
|
|
845
893
|
})
|
|
846
|
-
}) : /* @__PURE__ */
|
|
894
|
+
}) : /* @__PURE__ */ x("div", {
|
|
847
895
|
className: "flex flex-col gap-list-gap",
|
|
848
|
-
children: [
|
|
896
|
+
children: [I && !X && /* @__PURE__ */ b(r, {
|
|
849
897
|
emphasis: "muted",
|
|
850
898
|
tone: "info",
|
|
851
899
|
padding: "compact",
|
|
852
900
|
headingLevel: 3,
|
|
853
901
|
title: "Sending your prompt…",
|
|
854
902
|
description: "The new generation appears here as soon as the backend accepts it.",
|
|
855
|
-
icon: /* @__PURE__ */
|
|
903
|
+
icon: /* @__PURE__ */ b(h, { className: "h-icon-sm w-icon-sm animate-spin" }),
|
|
856
904
|
"data-testid": "insights-generation-pending"
|
|
857
905
|
}), Z.map((e) => {
|
|
858
|
-
let t = e.generatedSpec, i =
|
|
859
|
-
return /* @__PURE__ */
|
|
906
|
+
let t = e.generatedSpec, i = R.has(e.id), a = Ce.includes(e.status);
|
|
907
|
+
return /* @__PURE__ */ x(r, {
|
|
860
908
|
emphasis: "standard",
|
|
861
909
|
padding: "compact",
|
|
862
910
|
headingLevel: 3,
|
|
863
|
-
title: t?.name || (a ?
|
|
864
|
-
meta: /* @__PURE__ */
|
|
911
|
+
title: t?.name || (a ? s("bigconsole.insights.generations.generating", "Generating…") : "Untitled generation"),
|
|
912
|
+
meta: /* @__PURE__ */ b(Me, { status: e.status }),
|
|
865
913
|
description: e.prompt.length > 160 ? `${e.prompt.slice(0, 160)}…` : e.prompt,
|
|
866
914
|
"data-testid": "insights-generation-card",
|
|
867
915
|
bodyClassName: "flex flex-col gap-control-gap",
|
|
868
916
|
children: [
|
|
869
|
-
t && /* @__PURE__ */
|
|
917
|
+
t && /* @__PURE__ */ x("div", {
|
|
870
918
|
style: {
|
|
871
919
|
display: "flex",
|
|
872
920
|
flexWrap: "wrap",
|
|
873
921
|
gap: "var(--space-iconGap)"
|
|
874
922
|
},
|
|
875
923
|
children: [
|
|
876
|
-
/* @__PURE__ */
|
|
877
|
-
style:
|
|
924
|
+
/* @__PURE__ */ x("span", {
|
|
925
|
+
style: A,
|
|
878
926
|
children: [
|
|
879
|
-
|
|
927
|
+
P(t),
|
|
880
928
|
" widget",
|
|
881
|
-
|
|
929
|
+
P(t) === 1 ? "" : "s"
|
|
882
930
|
]
|
|
883
931
|
}),
|
|
884
|
-
/* @__PURE__ */
|
|
885
|
-
style:
|
|
932
|
+
/* @__PURE__ */ x("span", {
|
|
933
|
+
style: A,
|
|
886
934
|
children: [
|
|
887
935
|
t.pages.length,
|
|
888
936
|
" page",
|
|
889
937
|
t.pages.length === 1 ? "" : "s"
|
|
890
938
|
]
|
|
891
939
|
}),
|
|
892
|
-
/* @__PURE__ */
|
|
893
|
-
style:
|
|
940
|
+
/* @__PURE__ */ x("span", {
|
|
941
|
+
style: Ne(t.overallConfidence),
|
|
894
942
|
children: [Math.round(t.overallConfidence * 100), "% confidence"]
|
|
895
943
|
})
|
|
896
944
|
]
|
|
897
945
|
}),
|
|
898
|
-
e.errorMessage && /* @__PURE__ */
|
|
946
|
+
e.errorMessage && /* @__PURE__ */ b(r, {
|
|
899
947
|
headingLevel: 4,
|
|
900
948
|
tone: "danger",
|
|
901
949
|
padding: "compact",
|
|
902
950
|
title: "Generation failed",
|
|
903
951
|
description: e.errorMessage,
|
|
904
|
-
icon: /* @__PURE__ */
|
|
952
|
+
icon: /* @__PURE__ */ b(d, { className: "h-icon-sm w-icon-sm" })
|
|
905
953
|
}),
|
|
906
|
-
/* @__PURE__ */
|
|
954
|
+
/* @__PURE__ */ x("div", {
|
|
907
955
|
style: {
|
|
908
956
|
display: "flex",
|
|
909
957
|
flexWrap: "wrap",
|
|
@@ -913,82 +961,82 @@ var I = c(function() {
|
|
|
913
961
|
paddingTop: "var(--space-controlGap)"
|
|
914
962
|
},
|
|
915
963
|
children: [
|
|
916
|
-
a && /* @__PURE__ */
|
|
964
|
+
a && /* @__PURE__ */ x("button", {
|
|
917
965
|
type: "button",
|
|
918
966
|
onClick: () => {
|
|
919
|
-
o("medium"),
|
|
967
|
+
o("medium"), it(e.id);
|
|
920
968
|
},
|
|
921
969
|
disabled: i,
|
|
922
|
-
title:
|
|
970
|
+
title: s("bigconsole.insights.actions.cancelTitle", "Cancel generation"),
|
|
923
971
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
924
972
|
style: {
|
|
925
|
-
...
|
|
973
|
+
...Ae,
|
|
926
974
|
cursor: i ? "wait" : "pointer"
|
|
927
975
|
},
|
|
928
976
|
children: [
|
|
929
|
-
/* @__PURE__ */
|
|
977
|
+
/* @__PURE__ */ b(ne, {
|
|
930
978
|
size: 14,
|
|
931
979
|
"aria-hidden": "true"
|
|
932
980
|
}),
|
|
933
981
|
" ",
|
|
934
|
-
|
|
982
|
+
s("bigconsole.insights.actions.cancel", "Cancel")
|
|
935
983
|
]
|
|
936
984
|
}),
|
|
937
|
-
e.status === "COMPLETED" && t && /* @__PURE__ */
|
|
985
|
+
e.status === "COMPLETED" && t && /* @__PURE__ */ x("button", {
|
|
938
986
|
type: "button",
|
|
939
|
-
onClick: () =>
|
|
940
|
-
title:
|
|
987
|
+
onClick: () => B(e),
|
|
988
|
+
title: s("bigconsole.insights.actions.previewTitle", "Preview proposed layout"),
|
|
941
989
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
942
|
-
style:
|
|
990
|
+
style: T,
|
|
943
991
|
children: [
|
|
944
|
-
/* @__PURE__ */
|
|
992
|
+
/* @__PURE__ */ b(re, {
|
|
945
993
|
size: 14,
|
|
946
994
|
"aria-hidden": "true"
|
|
947
995
|
}),
|
|
948
996
|
" ",
|
|
949
|
-
|
|
997
|
+
s("bigconsole.insights.actions.preview", "Preview")
|
|
950
998
|
]
|
|
951
999
|
}),
|
|
952
|
-
e.status === "COMPLETED" && t && /* @__PURE__ */
|
|
1000
|
+
e.status === "COMPLETED" && t && /* @__PURE__ */ x("button", {
|
|
953
1001
|
type: "button",
|
|
954
1002
|
onClick: () => {
|
|
955
|
-
|
|
1003
|
+
H(e), W("");
|
|
956
1004
|
},
|
|
957
|
-
title:
|
|
1005
|
+
title: s("bigconsole.insights.actions.refineTitle", "Refine with instructions"),
|
|
958
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",
|
|
959
|
-
style:
|
|
1007
|
+
style: T,
|
|
960
1008
|
children: [
|
|
961
|
-
/* @__PURE__ */
|
|
1009
|
+
/* @__PURE__ */ b(_, {
|
|
962
1010
|
size: 14,
|
|
963
1011
|
"aria-hidden": "true"
|
|
964
1012
|
}),
|
|
965
1013
|
" ",
|
|
966
|
-
|
|
1014
|
+
s("bigconsole.insights.actions.refine", "Refine")
|
|
967
1015
|
]
|
|
968
1016
|
}),
|
|
969
|
-
(e.status === "COMPLETED" || e.status === "FAILED" || e.status === "CANCELLED") && /* @__PURE__ */
|
|
1017
|
+
(e.status === "COMPLETED" || e.status === "FAILED" || e.status === "CANCELLED") && /* @__PURE__ */ x("button", {
|
|
970
1018
|
type: "button",
|
|
971
1019
|
onClick: () => {
|
|
972
|
-
o("medium"),
|
|
1020
|
+
o("medium"), at(e.id);
|
|
973
1021
|
},
|
|
974
1022
|
disabled: i,
|
|
975
|
-
title:
|
|
1023
|
+
title: s("bigconsole.insights.actions.regenerateTitle", "Regenerate with the same prompt"),
|
|
976
1024
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
977
1025
|
style: {
|
|
978
|
-
...
|
|
1026
|
+
...T,
|
|
979
1027
|
cursor: i ? "wait" : "pointer"
|
|
980
1028
|
},
|
|
981
1029
|
children: [
|
|
982
|
-
/* @__PURE__ */
|
|
1030
|
+
/* @__PURE__ */ b(oe, {
|
|
983
1031
|
size: 14,
|
|
984
1032
|
className: i ? "animate-spin" : "",
|
|
985
1033
|
"aria-hidden": "true"
|
|
986
1034
|
}),
|
|
987
1035
|
" ",
|
|
988
|
-
|
|
1036
|
+
s("bigconsole.insights.actions.regenerate", "Regenerate")
|
|
989
1037
|
]
|
|
990
1038
|
}),
|
|
991
|
-
/* @__PURE__ */
|
|
1039
|
+
/* @__PURE__ */ x("div", {
|
|
992
1040
|
style: {
|
|
993
1041
|
display: "flex",
|
|
994
1042
|
flexWrap: "wrap",
|
|
@@ -997,44 +1045,44 @@ var I = c(function() {
|
|
|
997
1045
|
marginLeft: "auto"
|
|
998
1046
|
},
|
|
999
1047
|
children: [
|
|
1000
|
-
e.status === "COMPLETED" && !e.dashboardId && /* @__PURE__ */
|
|
1048
|
+
e.status === "COMPLETED" && !e.dashboardId && /* @__PURE__ */ x("button", {
|
|
1001
1049
|
type: "button",
|
|
1002
1050
|
onClick: () => Q(e.id),
|
|
1003
1051
|
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
|
-
style:
|
|
1052
|
+
style: E,
|
|
1005
1053
|
children: [
|
|
1006
|
-
|
|
1054
|
+
s("bigconsole.insights.actions.create", "Create dashboard"),
|
|
1007
1055
|
" ",
|
|
1008
|
-
/* @__PURE__ */
|
|
1056
|
+
/* @__PURE__ */ b(f, {
|
|
1009
1057
|
size: 14,
|
|
1010
1058
|
"aria-hidden": "true"
|
|
1011
1059
|
})
|
|
1012
1060
|
]
|
|
1013
1061
|
}),
|
|
1014
|
-
e.dashboardId && /* @__PURE__ */
|
|
1062
|
+
e.dashboardId && /* @__PURE__ */ x("button", {
|
|
1015
1063
|
type: "button",
|
|
1016
|
-
onClick: () =>
|
|
1064
|
+
onClick: () => p(`/dashboards/${e.dashboardId ?? ""}`),
|
|
1017
1065
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
1018
|
-
style:
|
|
1066
|
+
style: T,
|
|
1019
1067
|
children: [
|
|
1020
|
-
|
|
1068
|
+
s("bigconsole.insights.actions.viewDashboard", "View dashboard"),
|
|
1021
1069
|
" ",
|
|
1022
|
-
/* @__PURE__ */
|
|
1070
|
+
/* @__PURE__ */ b(f, {
|
|
1023
1071
|
size: 14,
|
|
1024
1072
|
"aria-hidden": "true"
|
|
1025
1073
|
})
|
|
1026
1074
|
]
|
|
1027
1075
|
}),
|
|
1028
|
-
/* @__PURE__ */
|
|
1076
|
+
/* @__PURE__ */ b("button", {
|
|
1029
1077
|
type: "button",
|
|
1030
1078
|
onClick: () => {
|
|
1031
|
-
o("medium"),
|
|
1079
|
+
o("medium"), rt(e.id);
|
|
1032
1080
|
},
|
|
1033
|
-
title:
|
|
1034
|
-
"aria-label":
|
|
1081
|
+
title: s("bigconsole.insights.actions.deleteTitle", "Delete generation"),
|
|
1082
|
+
"aria-label": s("bigconsole.insights.actions.deleteTitle", "Delete generation"),
|
|
1035
1083
|
className: n,
|
|
1036
|
-
style:
|
|
1037
|
-
children: /* @__PURE__ */
|
|
1084
|
+
style: D,
|
|
1085
|
+
children: /* @__PURE__ */ b(se, {
|
|
1038
1086
|
size: 14,
|
|
1039
1087
|
"aria-hidden": "true"
|
|
1040
1088
|
})
|
|
@@ -1050,11 +1098,11 @@ var I = c(function() {
|
|
|
1050
1098
|
})
|
|
1051
1099
|
] })]
|
|
1052
1100
|
}),
|
|
1053
|
-
|
|
1101
|
+
z && $ && /* @__PURE__ */ b("div", {
|
|
1054
1102
|
role: "dialog",
|
|
1055
1103
|
"aria-modal": "true",
|
|
1056
|
-
"aria-label":
|
|
1057
|
-
onClick: () =>
|
|
1104
|
+
"aria-label": s("bigconsole.insights.preview.ariaLabel", "Generation preview"),
|
|
1105
|
+
onClick: () => B(null),
|
|
1058
1106
|
style: {
|
|
1059
1107
|
position: "fixed",
|
|
1060
1108
|
inset: 0,
|
|
@@ -1065,7 +1113,7 @@ var I = c(function() {
|
|
|
1065
1113
|
justifyContent: "center",
|
|
1066
1114
|
padding: "var(--space-pagePadding)"
|
|
1067
1115
|
},
|
|
1068
|
-
children: /* @__PURE__ */
|
|
1116
|
+
children: /* @__PURE__ */ x("div", {
|
|
1069
1117
|
onClick: (e) => e.stopPropagation(),
|
|
1070
1118
|
style: {
|
|
1071
1119
|
display: "flex",
|
|
@@ -1079,7 +1127,7 @@ var I = c(function() {
|
|
|
1079
1127
|
boxShadow: "var(--shadow-elevation-3)"
|
|
1080
1128
|
},
|
|
1081
1129
|
children: [
|
|
1082
|
-
/* @__PURE__ */
|
|
1130
|
+
/* @__PURE__ */ x("div", {
|
|
1083
1131
|
style: {
|
|
1084
1132
|
display: "flex",
|
|
1085
1133
|
justifyContent: "space-between",
|
|
@@ -1088,16 +1136,16 @@ var I = c(function() {
|
|
|
1088
1136
|
padding: "var(--space-cardPadding)",
|
|
1089
1137
|
borderBottom: "1px solid var(--color-border-subtle)"
|
|
1090
1138
|
},
|
|
1091
|
-
children: [/* @__PURE__ */
|
|
1139
|
+
children: [/* @__PURE__ */ x("div", {
|
|
1092
1140
|
style: { minWidth: 0 },
|
|
1093
|
-
children: [/* @__PURE__ */
|
|
1141
|
+
children: [/* @__PURE__ */ b("h2", {
|
|
1094
1142
|
style: {
|
|
1095
1143
|
fontSize: "var(--font-size-heading-h4)",
|
|
1096
1144
|
fontWeight: "var(--font-weight-semibold)",
|
|
1097
1145
|
color: "var(--color-text-primary)"
|
|
1098
1146
|
},
|
|
1099
1147
|
children: $.name
|
|
1100
|
-
}), $.description && /* @__PURE__ */
|
|
1148
|
+
}), $.description && /* @__PURE__ */ b("p", {
|
|
1101
1149
|
style: {
|
|
1102
1150
|
fontSize: "var(--font-size-body-sm)",
|
|
1103
1151
|
color: "var(--color-text-secondary)",
|
|
@@ -1105,22 +1153,22 @@ var I = c(function() {
|
|
|
1105
1153
|
},
|
|
1106
1154
|
children: $.description
|
|
1107
1155
|
})]
|
|
1108
|
-
}), /* @__PURE__ */
|
|
1156
|
+
}), /* @__PURE__ */ b("button", {
|
|
1109
1157
|
type: "button",
|
|
1110
|
-
onClick: () =>
|
|
1111
|
-
"aria-label":
|
|
1158
|
+
onClick: () => B(null),
|
|
1159
|
+
"aria-label": s("bigconsole.insights.preview.close", "Close preview"),
|
|
1112
1160
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
1113
1161
|
style: {
|
|
1114
|
-
...
|
|
1162
|
+
...D,
|
|
1115
1163
|
color: "var(--color-text-muted)"
|
|
1116
1164
|
},
|
|
1117
|
-
children: /* @__PURE__ */
|
|
1165
|
+
children: /* @__PURE__ */ b(ce, {
|
|
1118
1166
|
size: 18,
|
|
1119
1167
|
"aria-hidden": "true"
|
|
1120
1168
|
})
|
|
1121
1169
|
})]
|
|
1122
1170
|
}),
|
|
1123
|
-
/* @__PURE__ */
|
|
1171
|
+
/* @__PURE__ */ x("div", {
|
|
1124
1172
|
style: {
|
|
1125
1173
|
flex: "1 1 auto",
|
|
1126
1174
|
minHeight: 0,
|
|
@@ -1131,38 +1179,38 @@ var I = c(function() {
|
|
|
1131
1179
|
gap: "var(--space-controlGap)"
|
|
1132
1180
|
},
|
|
1133
1181
|
children: [
|
|
1134
|
-
/* @__PURE__ */
|
|
1182
|
+
/* @__PURE__ */ x("div", {
|
|
1135
1183
|
style: {
|
|
1136
1184
|
display: "flex",
|
|
1137
1185
|
flexWrap: "wrap",
|
|
1138
1186
|
gap: "var(--space-iconGap)"
|
|
1139
1187
|
},
|
|
1140
1188
|
children: [
|
|
1141
|
-
/* @__PURE__ */
|
|
1142
|
-
style:
|
|
1189
|
+
/* @__PURE__ */ x("span", {
|
|
1190
|
+
style: A,
|
|
1143
1191
|
children: [
|
|
1144
|
-
|
|
1192
|
+
P($),
|
|
1145
1193
|
" widget",
|
|
1146
|
-
|
|
1194
|
+
P($) === 1 ? "" : "s"
|
|
1147
1195
|
]
|
|
1148
1196
|
}),
|
|
1149
|
-
/* @__PURE__ */
|
|
1150
|
-
style:
|
|
1197
|
+
/* @__PURE__ */ x("span", {
|
|
1198
|
+
style: A,
|
|
1151
1199
|
children: [
|
|
1152
1200
|
$.pages.length,
|
|
1153
1201
|
" page",
|
|
1154
1202
|
$.pages.length === 1 ? "" : "s"
|
|
1155
1203
|
]
|
|
1156
1204
|
}),
|
|
1157
|
-
/* @__PURE__ */
|
|
1158
|
-
style:
|
|
1205
|
+
/* @__PURE__ */ x("span", {
|
|
1206
|
+
style: Ne($.overallConfidence),
|
|
1159
1207
|
children: [Math.round($.overallConfidence * 100), "% confidence"]
|
|
1160
1208
|
})
|
|
1161
1209
|
]
|
|
1162
1210
|
}),
|
|
1163
|
-
$.reasoning && /* @__PURE__ */
|
|
1211
|
+
$.reasoning && /* @__PURE__ */ x("details", {
|
|
1164
1212
|
"data-testid": "preview-reasoning",
|
|
1165
|
-
children: [/* @__PURE__ */
|
|
1213
|
+
children: [/* @__PURE__ */ b("summary", {
|
|
1166
1214
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
1167
1215
|
style: {
|
|
1168
1216
|
cursor: "pointer",
|
|
@@ -1171,8 +1219,8 @@ var I = c(function() {
|
|
|
1171
1219
|
color: "var(--color-text-secondary)",
|
|
1172
1220
|
borderRadius: "var(--radius-button)"
|
|
1173
1221
|
},
|
|
1174
|
-
children:
|
|
1175
|
-
}), /* @__PURE__ */
|
|
1222
|
+
children: s("bigconsole.insights.preview.reasoningToggle", "Why these widgets?")
|
|
1223
|
+
}), /* @__PURE__ */ b("p", {
|
|
1176
1224
|
style: {
|
|
1177
1225
|
marginTop: "var(--space-controlGap)",
|
|
1178
1226
|
fontSize: "var(--font-size-body-sm)",
|
|
@@ -1187,24 +1235,39 @@ var I = c(function() {
|
|
|
1187
1235
|
padding: "compact",
|
|
1188
1236
|
headingLevel: 3,
|
|
1189
1237
|
title: e.name,
|
|
1190
|
-
meta: /* @__PURE__ */
|
|
1191
|
-
style:
|
|
1238
|
+
meta: /* @__PURE__ */ x("span", {
|
|
1239
|
+
style: A,
|
|
1192
1240
|
children: [
|
|
1193
1241
|
e.widgets.length,
|
|
1194
1242
|
" widget",
|
|
1195
1243
|
e.widgets.length === 1 ? "" : "s"
|
|
1196
1244
|
]
|
|
1197
1245
|
}),
|
|
1198
|
-
children: /* @__PURE__ */ x("
|
|
1246
|
+
children: [/* @__PURE__ */ x("p", {
|
|
1199
1247
|
style: {
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
|
|
1248
|
+
fontSize: "var(--font-size-body-sm)",
|
|
1249
|
+
color: "var(--color-text-secondary)",
|
|
1250
|
+
marginBottom: "var(--space-controlGap)"
|
|
1203
1251
|
},
|
|
1204
|
-
children:
|
|
1205
|
-
|
|
1206
|
-
|
|
1252
|
+
children: [
|
|
1253
|
+
s("bigconsole.insights.preview.proposedLayout", "Proposed layout"),
|
|
1254
|
+
" · ",
|
|
1255
|
+
e.gridColumns,
|
|
1256
|
+
" ",
|
|
1257
|
+
s("bigconsole.insights.preview.columns", "columns"),
|
|
1258
|
+
" ·",
|
|
1259
|
+
" ",
|
|
1260
|
+
e.layout.toLowerCase().replaceAll("_", " ")
|
|
1261
|
+
]
|
|
1262
|
+
}), /* @__PURE__ */ b("div", {
|
|
1263
|
+
className: "insights-proposal-grid",
|
|
1264
|
+
style: Ie(e.gridColumns),
|
|
1265
|
+
children: e.widgets.map((t, n) => {
|
|
1266
|
+
let r = Pe(t.confidence);
|
|
1267
|
+
return /* @__PURE__ */ x("div", {
|
|
1268
|
+
className: "insights-proposal-widget",
|
|
1207
1269
|
style: {
|
|
1270
|
+
...Le(t.position, e.gridColumns),
|
|
1208
1271
|
display: "flex",
|
|
1209
1272
|
flexDirection: "column",
|
|
1210
1273
|
gap: "2px",
|
|
@@ -1213,7 +1276,7 @@ var I = c(function() {
|
|
|
1213
1276
|
backgroundColor: "var(--color-bg-surface)",
|
|
1214
1277
|
border: "1px solid var(--color-border-subtle)"
|
|
1215
1278
|
},
|
|
1216
|
-
children: [/* @__PURE__ */
|
|
1279
|
+
children: [/* @__PURE__ */ x("div", {
|
|
1217
1280
|
style: {
|
|
1218
1281
|
display: "flex",
|
|
1219
1282
|
flexWrap: "wrap",
|
|
@@ -1221,48 +1284,48 @@ var I = c(function() {
|
|
|
1221
1284
|
gap: "var(--space-iconGap)"
|
|
1222
1285
|
},
|
|
1223
1286
|
children: [
|
|
1224
|
-
/* @__PURE__ */
|
|
1287
|
+
/* @__PURE__ */ b("span", {
|
|
1225
1288
|
style: {
|
|
1226
1289
|
fontSize: "var(--font-size-body-sm)",
|
|
1227
1290
|
fontWeight: "var(--font-weight-medium)",
|
|
1228
1291
|
color: "var(--color-text-primary)",
|
|
1229
1292
|
minWidth: 0
|
|
1230
1293
|
},
|
|
1231
|
-
children:
|
|
1294
|
+
children: t.title
|
|
1232
1295
|
}),
|
|
1233
|
-
/* @__PURE__ */
|
|
1296
|
+
/* @__PURE__ */ b("span", {
|
|
1234
1297
|
style: {
|
|
1235
1298
|
fontSize: "var(--font-size-xs)",
|
|
1236
1299
|
color: "var(--color-text-muted)"
|
|
1237
1300
|
},
|
|
1238
1301
|
"data-testid": "preview-widget-type",
|
|
1239
|
-
children:
|
|
1302
|
+
children: t.type
|
|
1240
1303
|
}),
|
|
1241
|
-
|
|
1304
|
+
r && /* @__PURE__ */ b("span", {
|
|
1242
1305
|
style: {
|
|
1243
|
-
...
|
|
1306
|
+
...Re(r),
|
|
1244
1307
|
marginLeft: "auto"
|
|
1245
1308
|
},
|
|
1246
1309
|
"data-testid": "preview-widget-confidence",
|
|
1247
|
-
children:
|
|
1310
|
+
children: r
|
|
1248
1311
|
})
|
|
1249
1312
|
]
|
|
1250
|
-
}),
|
|
1313
|
+
}), t.reasoning && /* @__PURE__ */ b("p", {
|
|
1251
1314
|
style: {
|
|
1252
1315
|
margin: 0,
|
|
1253
1316
|
fontSize: "var(--font-size-xs)",
|
|
1254
1317
|
lineHeight: "var(--font-lineHeight-normal)",
|
|
1255
1318
|
color: "var(--color-text-muted)"
|
|
1256
1319
|
},
|
|
1257
|
-
children:
|
|
1320
|
+
children: t.reasoning
|
|
1258
1321
|
})]
|
|
1259
|
-
},
|
|
1322
|
+
}, n);
|
|
1260
1323
|
})
|
|
1261
|
-
})
|
|
1324
|
+
})]
|
|
1262
1325
|
}, t))
|
|
1263
1326
|
]
|
|
1264
1327
|
}),
|
|
1265
|
-
/* @__PURE__ */
|
|
1328
|
+
/* @__PURE__ */ x("div", {
|
|
1266
1329
|
style: {
|
|
1267
1330
|
display: "flex",
|
|
1268
1331
|
justifyContent: "flex-end",
|
|
@@ -1272,43 +1335,43 @@ var I = c(function() {
|
|
|
1272
1335
|
borderTop: "1px solid var(--color-border-subtle)"
|
|
1273
1336
|
},
|
|
1274
1337
|
children: [
|
|
1275
|
-
/* @__PURE__ */
|
|
1338
|
+
/* @__PURE__ */ b("button", {
|
|
1276
1339
|
type: "button",
|
|
1277
|
-
onClick: () =>
|
|
1340
|
+
onClick: () => B(null),
|
|
1278
1341
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
1279
|
-
style:
|
|
1342
|
+
style: T,
|
|
1280
1343
|
children: "Close"
|
|
1281
1344
|
}),
|
|
1282
|
-
|
|
1345
|
+
z.status === "COMPLETED" && $ && /* @__PURE__ */ x("button", {
|
|
1283
1346
|
type: "button",
|
|
1284
1347
|
onClick: () => {
|
|
1285
|
-
let e =
|
|
1286
|
-
|
|
1348
|
+
let e = z;
|
|
1349
|
+
B(null), H(e), W("");
|
|
1287
1350
|
},
|
|
1288
|
-
title:
|
|
1351
|
+
title: s("bigconsole.insights.actions.refineTitle", "Refine with instructions"),
|
|
1289
1352
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
1290
|
-
style:
|
|
1353
|
+
style: T,
|
|
1291
1354
|
children: [
|
|
1292
|
-
/* @__PURE__ */
|
|
1355
|
+
/* @__PURE__ */ b(_, {
|
|
1293
1356
|
size: 14,
|
|
1294
1357
|
"aria-hidden": "true"
|
|
1295
1358
|
}),
|
|
1296
1359
|
" ",
|
|
1297
|
-
|
|
1360
|
+
s("bigconsole.insights.actions.refine", "Refine")
|
|
1298
1361
|
]
|
|
1299
1362
|
}),
|
|
1300
|
-
|
|
1363
|
+
z.status === "COMPLETED" && !z.dashboardId && /* @__PURE__ */ x("button", {
|
|
1301
1364
|
type: "button",
|
|
1302
1365
|
onClick: () => {
|
|
1303
|
-
let e =
|
|
1304
|
-
|
|
1366
|
+
let e = z.id;
|
|
1367
|
+
B(null), Q(e);
|
|
1305
1368
|
},
|
|
1306
1369
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
1307
|
-
style:
|
|
1370
|
+
style: E,
|
|
1308
1371
|
children: [
|
|
1309
|
-
|
|
1372
|
+
s("bigconsole.insights.actions.create", "Create dashboard"),
|
|
1310
1373
|
" ",
|
|
1311
|
-
/* @__PURE__ */
|
|
1374
|
+
/* @__PURE__ */ b(f, {
|
|
1312
1375
|
size: 14,
|
|
1313
1376
|
"aria-hidden": "true"
|
|
1314
1377
|
})
|
|
@@ -1319,11 +1382,11 @@ var I = c(function() {
|
|
|
1319
1382
|
]
|
|
1320
1383
|
})
|
|
1321
1384
|
}),
|
|
1322
|
-
|
|
1385
|
+
V && /* @__PURE__ */ b("div", {
|
|
1323
1386
|
role: "dialog",
|
|
1324
1387
|
"aria-modal": "true",
|
|
1325
|
-
"aria-label":
|
|
1326
|
-
onClick: () =>
|
|
1388
|
+
"aria-label": s("bigconsole.insights.refine.ariaLabel", "Refine generation"),
|
|
1389
|
+
onClick: () => H(null),
|
|
1327
1390
|
style: {
|
|
1328
1391
|
position: "fixed",
|
|
1329
1392
|
inset: 0,
|
|
@@ -1334,7 +1397,7 @@ var I = c(function() {
|
|
|
1334
1397
|
justifyContent: "center",
|
|
1335
1398
|
padding: "var(--space-pagePadding)"
|
|
1336
1399
|
},
|
|
1337
|
-
children: /* @__PURE__ */
|
|
1400
|
+
children: /* @__PURE__ */ x("div", {
|
|
1338
1401
|
onClick: (e) => e.stopPropagation(),
|
|
1339
1402
|
style: {
|
|
1340
1403
|
display: "flex",
|
|
@@ -1348,28 +1411,28 @@ var I = c(function() {
|
|
|
1348
1411
|
boxShadow: "var(--shadow-elevation-3)"
|
|
1349
1412
|
},
|
|
1350
1413
|
children: [
|
|
1351
|
-
/* @__PURE__ */
|
|
1414
|
+
/* @__PURE__ */ x("div", {
|
|
1352
1415
|
style: {
|
|
1353
1416
|
padding: "var(--space-cardPadding)",
|
|
1354
1417
|
borderBottom: "1px solid var(--color-border-subtle)"
|
|
1355
1418
|
},
|
|
1356
|
-
children: [/* @__PURE__ */
|
|
1419
|
+
children: [/* @__PURE__ */ b("h2", {
|
|
1357
1420
|
style: {
|
|
1358
1421
|
fontSize: "var(--font-size-heading-h4)",
|
|
1359
1422
|
fontWeight: "var(--font-weight-semibold)",
|
|
1360
1423
|
color: "var(--color-text-primary)"
|
|
1361
1424
|
},
|
|
1362
|
-
children:
|
|
1363
|
-
}), /* @__PURE__ */
|
|
1425
|
+
children: s("bigconsole.insights.refine.heading", "Refine dashboard")
|
|
1426
|
+
}), /* @__PURE__ */ b("p", {
|
|
1364
1427
|
style: {
|
|
1365
1428
|
fontSize: "var(--font-size-body-sm)",
|
|
1366
1429
|
color: "var(--color-text-secondary)",
|
|
1367
1430
|
marginTop: 2
|
|
1368
1431
|
},
|
|
1369
|
-
children:
|
|
1432
|
+
children: s("bigconsole.insights.refine.subtitle", "Describe what to change — the AI keeps the existing spec and applies your instructions.")
|
|
1370
1433
|
})]
|
|
1371
1434
|
}),
|
|
1372
|
-
/* @__PURE__ */
|
|
1435
|
+
/* @__PURE__ */ x("div", {
|
|
1373
1436
|
style: {
|
|
1374
1437
|
flex: "1 1 auto",
|
|
1375
1438
|
minHeight: 0,
|
|
@@ -1379,20 +1442,20 @@ var I = c(function() {
|
|
|
1379
1442
|
flexDirection: "column",
|
|
1380
1443
|
gap: "var(--space-controlGap)"
|
|
1381
1444
|
},
|
|
1382
|
-
children: [/* @__PURE__ */
|
|
1445
|
+
children: [/* @__PURE__ */ b(r, {
|
|
1383
1446
|
emphasis: "muted",
|
|
1384
1447
|
padding: "compact",
|
|
1385
1448
|
headingLevel: 3,
|
|
1386
|
-
title:
|
|
1387
|
-
description:
|
|
1388
|
-
icon: /* @__PURE__ */
|
|
1389
|
-
}), /* @__PURE__ */
|
|
1449
|
+
title: V.generatedSpec?.name || "Current proposal",
|
|
1450
|
+
description: V.prompt.length > 240 ? `${V.prompt.slice(0, 240)}…` : V.prompt,
|
|
1451
|
+
icon: /* @__PURE__ */ b(g, { className: "h-icon-sm w-icon-sm" })
|
|
1452
|
+
}), /* @__PURE__ */ x("div", {
|
|
1390
1453
|
style: {
|
|
1391
1454
|
display: "flex",
|
|
1392
1455
|
flexDirection: "column",
|
|
1393
1456
|
gap: "var(--space-controlGap)"
|
|
1394
1457
|
},
|
|
1395
|
-
children: [/* @__PURE__ */
|
|
1458
|
+
children: [/* @__PURE__ */ b("label", {
|
|
1396
1459
|
htmlFor: "refine-input",
|
|
1397
1460
|
style: {
|
|
1398
1461
|
display: "block",
|
|
@@ -1401,13 +1464,13 @@ var I = c(function() {
|
|
|
1401
1464
|
color: "var(--color-text-primary)"
|
|
1402
1465
|
},
|
|
1403
1466
|
children: "What should change?"
|
|
1404
|
-
}), /* @__PURE__ */
|
|
1467
|
+
}), /* @__PURE__ */ b("textarea", {
|
|
1405
1468
|
id: "refine-input",
|
|
1406
|
-
value:
|
|
1407
|
-
onChange: (e) =>
|
|
1469
|
+
value: U,
|
|
1470
|
+
onChange: (e) => W(e.target.value),
|
|
1408
1471
|
maxLength: 2e3,
|
|
1409
1472
|
rows: 4,
|
|
1410
|
-
placeholder:
|
|
1473
|
+
placeholder: s("bigconsole.insights.refine.placeholder", "e.g., Add a revenue-by-region map and remove the duplicate KPI cards"),
|
|
1411
1474
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
1412
1475
|
style: {
|
|
1413
1476
|
width: "100%",
|
|
@@ -1423,7 +1486,7 @@ var I = c(function() {
|
|
|
1423
1486
|
})]
|
|
1424
1487
|
})]
|
|
1425
1488
|
}),
|
|
1426
|
-
/* @__PURE__ */
|
|
1489
|
+
/* @__PURE__ */ x("div", {
|
|
1427
1490
|
style: {
|
|
1428
1491
|
display: "flex",
|
|
1429
1492
|
justifyContent: "flex-end",
|
|
@@ -1432,30 +1495,30 @@ var I = c(function() {
|
|
|
1432
1495
|
padding: "var(--space-cardPadding)",
|
|
1433
1496
|
borderTop: "1px solid var(--color-border-subtle)"
|
|
1434
1497
|
},
|
|
1435
|
-
children: [/* @__PURE__ */
|
|
1498
|
+
children: [/* @__PURE__ */ b("button", {
|
|
1436
1499
|
type: "button",
|
|
1437
|
-
onClick: () =>
|
|
1500
|
+
onClick: () => H(null),
|
|
1438
1501
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
1439
|
-
style:
|
|
1440
|
-
children:
|
|
1441
|
-
}), /* @__PURE__ */
|
|
1502
|
+
style: T,
|
|
1503
|
+
children: s("bigconsole.insights.actions.cancel", "Cancel")
|
|
1504
|
+
}), /* @__PURE__ */ x("button", {
|
|
1442
1505
|
type: "button",
|
|
1443
|
-
onClick: () => void
|
|
1444
|
-
disabled: !
|
|
1506
|
+
onClick: () => void ot(),
|
|
1507
|
+
disabled: !U.trim() || R.has(V.id),
|
|
1445
1508
|
className: "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
1446
1509
|
style: {
|
|
1447
|
-
...
|
|
1448
|
-
cursor: !
|
|
1449
|
-
opacity:
|
|
1510
|
+
...E,
|
|
1511
|
+
cursor: !U.trim() || R.has(V.id) ? "not-allowed" : "pointer",
|
|
1512
|
+
opacity: U.trim() ? 1 : .6
|
|
1450
1513
|
},
|
|
1451
|
-
children: [
|
|
1514
|
+
children: [R.has(V.id) ? /* @__PURE__ */ b(h, {
|
|
1452
1515
|
size: 14,
|
|
1453
1516
|
className: "animate-spin",
|
|
1454
1517
|
"aria-hidden": "true"
|
|
1455
|
-
}) : /* @__PURE__ */
|
|
1518
|
+
}) : /* @__PURE__ */ b(_, {
|
|
1456
1519
|
size: 14,
|
|
1457
1520
|
"aria-hidden": "true"
|
|
1458
|
-
}),
|
|
1521
|
+
}), s("bigconsole.insights.refine.apply", "Apply refinement")]
|
|
1459
1522
|
})]
|
|
1460
1523
|
})
|
|
1461
1524
|
]
|
|
@@ -1465,6 +1528,6 @@ var I = c(function() {
|
|
|
1465
1528
|
});
|
|
1466
1529
|
});
|
|
1467
1530
|
//#endregion
|
|
1468
|
-
export {
|
|
1531
|
+
export { F as InsightsPage, F as default };
|
|
1469
1532
|
|
|
1470
1533
|
//# sourceMappingURL=InsightsPage.js.map
|