@burdenoff/microfe-bigconsole 2026.1004.2 → 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.
Files changed (150) hide show
  1. package/dist/bigconsole/BigConsoleRoutes.d.ts +1 -1
  2. package/dist/bigconsole/BigConsoleRoutes.d.ts.map +1 -1
  3. package/dist/bigconsole/BigConsoleRoutes.js +15 -1
  4. package/dist/bigconsole/BigConsoleRoutes.js.map +1 -1
  5. package/dist/bigconsole/components/DrilldownModal.d.ts.map +1 -1
  6. package/dist/bigconsole/components/DrilldownModal.js +54 -53
  7. package/dist/bigconsole/components/DrilldownModal.js.map +1 -1
  8. package/dist/bigconsole/components/builder/inspector/DataBindingSection.d.ts +3 -1
  9. package/dist/bigconsole/components/builder/inspector/DataBindingSection.d.ts.map +1 -1
  10. package/dist/bigconsole/components/builder/inspector/DataBindingSection.js +40 -39
  11. package/dist/bigconsole/components/builder/inspector/DataBindingSection.js.map +1 -1
  12. package/dist/bigconsole/components/dashboard/DashboardCanvas.d.ts.map +1 -1
  13. package/dist/bigconsole/components/dashboard/DashboardCanvas.js +184 -177
  14. package/dist/bigconsole/components/dashboard/DashboardCanvas.js.map +1 -1
  15. package/dist/bigconsole/components/dashboard/DashboardGrid.d.ts.map +1 -1
  16. package/dist/bigconsole/components/dashboard/DashboardGrid.js +40 -22
  17. package/dist/bigconsole/components/dashboard/DashboardGrid.js.map +1 -1
  18. package/dist/bigconsole/components/dashboard/ExportDashboardDialog.d.ts.map +1 -1
  19. package/dist/bigconsole/components/dashboard/ExportDashboardDialog.js +31 -25
  20. package/dist/bigconsole/components/dashboard/ExportDashboardDialog.js.map +1 -1
  21. package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterEditor.d.ts +1 -1
  22. package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterEditor.d.ts.map +1 -1
  23. package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterEditor.js +115 -80
  24. package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterEditor.js.map +1 -1
  25. package/dist/bigconsole/components/dashboard/GlobalFiltersBar/GlobalFiltersBar.d.ts.map +1 -1
  26. package/dist/bigconsole/components/dashboard/GlobalFiltersBar/GlobalFiltersBar.js +177 -146
  27. package/dist/bigconsole/components/dashboard/GlobalFiltersBar/GlobalFiltersBar.js.map +1 -1
  28. package/dist/bigconsole/components/dashboard/ShareDialog/ShareDialog.d.ts +1 -1
  29. package/dist/bigconsole/components/dashboard/ShareDialog/ShareDialog.d.ts.map +1 -1
  30. package/dist/bigconsole/components/dashboard/ShareDialog/ShareDialog.js +375 -325
  31. package/dist/bigconsole/components/dashboard/ShareDialog/ShareDialog.js.map +1 -1
  32. package/dist/bigconsole/components/datasink/CacheTTLSelector.d.ts.map +1 -1
  33. package/dist/bigconsole/components/datasink/CacheTTLSelector.js +7 -1
  34. package/dist/bigconsole/components/datasink/CacheTTLSelector.js.map +1 -1
  35. package/dist/bigconsole/components/parser/ParserSelector.d.ts +3 -1
  36. package/dist/bigconsole/components/parser/ParserSelector.d.ts.map +1 -1
  37. package/dist/bigconsole/components/parser/ParserSelector.js +94 -94
  38. package/dist/bigconsole/components/parser/ParserSelector.js.map +1 -1
  39. package/dist/bigconsole/components/pipeline/PipelineCard.d.ts.map +1 -1
  40. package/dist/bigconsole/components/pipeline/PipelineCard.js +111 -89
  41. package/dist/bigconsole/components/pipeline/PipelineCard.js.map +1 -1
  42. package/dist/bigconsole/components/pipeline/PipelineScopePicker.d.ts +8 -0
  43. package/dist/bigconsole/components/pipeline/PipelineScopePicker.d.ts.map +1 -0
  44. package/dist/bigconsole/components/pipeline/PipelineScopePicker.js +52 -0
  45. package/dist/bigconsole/components/pipeline/PipelineScopePicker.js.map +1 -0
  46. package/dist/bigconsole/components/widgets/PropertiesPanel.d.ts.map +1 -1
  47. package/dist/bigconsole/components/widgets/PropertiesPanel.js +257 -221
  48. package/dist/bigconsole/components/widgets/PropertiesPanel.js.map +1 -1
  49. package/dist/bigconsole/components/widgets/WidgetHeader.d.ts +1 -0
  50. package/dist/bigconsole/components/widgets/WidgetHeader.d.ts.map +1 -1
  51. package/dist/bigconsole/components/widgets/WidgetHeader.js +29 -29
  52. package/dist/bigconsole/components/widgets/WidgetHeader.js.map +1 -1
  53. package/dist/bigconsole/components/widgets/WidgetWrapper.d.ts +2 -0
  54. package/dist/bigconsole/components/widgets/WidgetWrapper.d.ts.map +1 -1
  55. package/dist/bigconsole/components/widgets/WidgetWrapper.js +247 -239
  56. package/dist/bigconsole/components/widgets/WidgetWrapper.js.map +1 -1
  57. package/dist/bigconsole/components/widgets/metric-card/MetricCardWidget.d.ts.map +1 -1
  58. package/dist/bigconsole/components/widgets/metric-card/MetricCardWidget.js +6 -4
  59. package/dist/bigconsole/components/widgets/metric-card/MetricCardWidget.js.map +1 -1
  60. package/dist/bigconsole/components/widgets/states/EmptyState.d.ts +1 -0
  61. package/dist/bigconsole/components/widgets/states/EmptyState.d.ts.map +1 -1
  62. package/dist/bigconsole/components/widgets/states/EmptyState.js +4 -4
  63. package/dist/bigconsole/components/widgets/states/EmptyState.js.map +1 -1
  64. package/dist/bigconsole/components/workflow/WorkflowDesignPreview.d.ts +7 -0
  65. package/dist/bigconsole/components/workflow/WorkflowDesignPreview.d.ts.map +1 -0
  66. package/dist/bigconsole/components/workflow/WorkflowDesignPreview.js +94 -0
  67. package/dist/bigconsole/components/workflow/WorkflowDesignPreview.js.map +1 -0
  68. package/dist/bigconsole/components/workflow/WorkflowSinkLinkForm.d.ts +7 -0
  69. package/dist/bigconsole/components/workflow/WorkflowSinkLinkForm.d.ts.map +1 -0
  70. package/dist/bigconsole/components/workflow/WorkflowSinkLinkForm.js +101 -0
  71. package/dist/bigconsole/components/workflow/WorkflowSinkLinkForm.js.map +1 -0
  72. package/dist/bigconsole/hooks/useBigConsoleSettings.d.ts +16 -0
  73. package/dist/bigconsole/hooks/useBigConsoleSettings.d.ts.map +1 -0
  74. package/dist/bigconsole/hooks/useBigConsoleSettings.js +57 -0
  75. package/dist/bigconsole/hooks/useBigConsoleSettings.js.map +1 -0
  76. package/dist/bigconsole/hooks/useDashboardOperations.d.ts.map +1 -1
  77. package/dist/bigconsole/hooks/useDashboardOperations.js +102 -79
  78. package/dist/bigconsole/hooks/useDashboardOperations.js.map +1 -1
  79. package/dist/bigconsole/hooks/useExportDashboard.d.ts +3 -1
  80. package/dist/bigconsole/hooks/useExportDashboard.d.ts.map +1 -1
  81. package/dist/bigconsole/hooks/useExportDashboard.js +23 -13
  82. package/dist/bigconsole/hooks/useExportDashboard.js.map +1 -1
  83. package/dist/bigconsole/hooks/useFilterUrlSync.d.ts +18 -0
  84. package/dist/bigconsole/hooks/useFilterUrlSync.d.ts.map +1 -1
  85. package/dist/bigconsole/hooks/useFilterUrlSync.js +87 -57
  86. package/dist/bigconsole/hooks/useFilterUrlSync.js.map +1 -1
  87. package/dist/bigconsole/hooks/useGlobalFilters.d.ts.map +1 -1
  88. package/dist/bigconsole/hooks/useGlobalFilters.js +39 -29
  89. package/dist/bigconsole/hooks/useGlobalFilters.js.map +1 -1
  90. package/dist/bigconsole/hooks/usePageOperations.d.ts.map +1 -1
  91. package/dist/bigconsole/hooks/usePageOperations.js +1 -0
  92. package/dist/bigconsole/hooks/usePageOperations.js.map +1 -1
  93. package/dist/bigconsole/hooks/usePipelineOperations.d.ts.map +1 -1
  94. package/dist/bigconsole/hooks/usePipelineOperations.js +114 -112
  95. package/dist/bigconsole/hooks/usePipelineOperations.js.map +1 -1
  96. package/dist/bigconsole/hooks/useShareRecipients.d.ts +22 -0
  97. package/dist/bigconsole/hooks/useShareRecipients.d.ts.map +1 -0
  98. package/dist/bigconsole/hooks/useShareRecipients.js +198 -0
  99. package/dist/bigconsole/hooks/useShareRecipients.js.map +1 -0
  100. package/dist/bigconsole/pages/DashboardBuilderPage.d.ts.map +1 -1
  101. package/dist/bigconsole/pages/DashboardBuilderPage.js +198 -193
  102. package/dist/bigconsole/pages/DashboardBuilderPage.js.map +1 -1
  103. package/dist/bigconsole/pages/DashboardViewPage.d.ts.map +1 -1
  104. package/dist/bigconsole/pages/DashboardViewPage.js +171 -167
  105. package/dist/bigconsole/pages/DashboardViewPage.js.map +1 -1
  106. package/dist/bigconsole/pages/DashboardsPage.d.ts.map +1 -1
  107. package/dist/bigconsole/pages/DashboardsPage.js +313 -266
  108. package/dist/bigconsole/pages/DashboardsPage.js.map +1 -1
  109. package/dist/bigconsole/pages/DataSinkBuilderPage.d.ts.map +1 -1
  110. package/dist/bigconsole/pages/DataSinkBuilderPage.js +84 -79
  111. package/dist/bigconsole/pages/DataSinkBuilderPage.js.map +1 -1
  112. package/dist/bigconsole/pages/DataSinkViewPage.d.ts.map +1 -1
  113. package/dist/bigconsole/pages/DataSinkViewPage.js +267 -257
  114. package/dist/bigconsole/pages/DataSinkViewPage.js.map +1 -1
  115. package/dist/bigconsole/pages/InsightsPage.d.ts.map +1 -1
  116. package/dist/bigconsole/pages/InsightsPage.js +465 -402
  117. package/dist/bigconsole/pages/InsightsPage.js.map +1 -1
  118. package/dist/bigconsole/pages/PipelineBuilderPage.d.ts.map +1 -1
  119. package/dist/bigconsole/pages/PipelineBuilderPage.js +169 -157
  120. package/dist/bigconsole/pages/PipelineBuilderPage.js.map +1 -1
  121. package/dist/bigconsole/pages/PipelineViewPage.d.ts.map +1 -1
  122. package/dist/bigconsole/pages/PipelineViewPage.js +370 -230
  123. package/dist/bigconsole/pages/PipelineViewPage.js.map +1 -1
  124. package/dist/bigconsole/pages/PipelinesPage.d.ts.map +1 -1
  125. package/dist/bigconsole/pages/PipelinesPage.js +181 -151
  126. package/dist/bigconsole/pages/PipelinesPage.js.map +1 -1
  127. package/dist/bigconsole/pages/SettingsPage.d.ts.map +1 -1
  128. package/dist/bigconsole/pages/SettingsPage.js +188 -208
  129. package/dist/bigconsole/pages/SettingsPage.js.map +1 -1
  130. package/dist/bigconsole/pages/WidgetDemoPage.d.ts.map +1 -1
  131. package/dist/bigconsole/pages/WidgetDemoPage.js +134 -117
  132. package/dist/bigconsole/pages/WidgetDemoPage.js.map +1 -1
  133. package/dist/bigconsole/pages/WorkflowViewPage.d.ts.map +1 -1
  134. package/dist/bigconsole/pages/WorkflowViewPage.js +315 -267
  135. package/dist/bigconsole/pages/WorkflowViewPage.js.map +1 -1
  136. package/dist/bigconsole/pages/WorkflowsPage.d.ts.map +1 -1
  137. package/dist/bigconsole/pages/WorkflowsPage.js +4 -3
  138. package/dist/bigconsole/pages/WorkflowsPage.js.map +1 -1
  139. package/dist/bigconsole/types/index.d.ts +4 -0
  140. package/dist/bigconsole/types/index.d.ts.map +1 -1
  141. package/dist/generated/wspace-operations.d.ts +148 -0
  142. package/dist/generated/wspace-operations.d.ts.map +1 -1
  143. package/dist/generated/wspace-operations.js +172 -133
  144. package/dist/generated/wspace-operations.js.map +1 -1
  145. package/dist/generated/wspace-types.d.ts +21 -0
  146. package/dist/generated/wspace-types.d.ts.map +1 -1
  147. package/dist/generated/wspace-types.js.map +1 -1
  148. package/dist/microfe-bigconsole.css +1 -1
  149. package/dist/translations/en.d.ts.map +1 -1
  150. package/package.json +3 -3
@@ -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 s } from "../../utils/nativeBridge.js";
9
- import { memo as c, useCallback as l, useEffect as u, useState as d } from "react";
10
- import { AlertCircle as f, ArrowRight as p, Ban as te, CheckCircle as m, Clock as h, Eye as ne, History as re, Lightbulb as ie, Loader2 as g, RefreshCw as ae, Sparkles as _, Trash2 as oe, Wand2 as v, X as se, XCircle as y } from "lucide-react";
11
- import { AuroraBackground as ce, GlassCard as le, GradientText as ue, IllustratedEmptyState as de, PagePurpose as fe } from "@burdenoff/fe-libs/ui";
12
- import { useMutation as b, useQuery as pe } from "@apollo/client/react";
13
- import { jsx as x, jsxs as S } from "react/jsx-runtime";
14
- import { gql as C } from "@apollo/client";
15
- import { useI18n as w } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
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 me = C`
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
- `, he = C`
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
- `, ge = C`
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
- `, _e = C`
77
+ `, ve = S`
69
78
  mutation CreateDashboardFromGeneration($input: CreateDashboardFromGenerationInput!) {
70
79
  createDashboardFromGeneration(input: $input) {
71
80
  id
72
81
  }
73
82
  }
74
- `, ve = C`
83
+ `, ye = S`
75
84
  mutation DeletePromptGeneration($generationId: ID!) {
76
85
  deletePromptGeneration(generationId: $generationId)
77
86
  }
78
- `, ye = C`
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
- `, be = C`
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
- `, xe = C`
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
- `, Se = [
110
+ `, Ce = [
102
111
  "PENDING",
103
112
  "PROCESSING",
104
113
  "GENERATING"
105
- ], Ce = 12, we = 8, Te = [
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
- ], Ee = [
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
- ], De = [
160
+ ], Oe = [
152
161
  6,
153
162
  8,
154
163
  12,
155
164
  16,
156
165
  24
157
- ], Oe = [
166
+ ], ke = [
158
167
  4,
159
168
  6,
160
169
  8,
161
170
  12,
162
171
  16,
163
172
  24
164
- ], T = {
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
- }, E = {
177
- ...T,
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
- }, D = {
182
- ...T,
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
- }, ke = {
187
- ...T,
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
- }, O = {
192
- ...T,
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
- }, k = {
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
- }, A = {
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
- }, j = {
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 M(e) {
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 N = {
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 Ae(e) {
258
- let t = N[M(e)].text;
266
+ function je(e) {
267
+ let t = M[j(e)].text;
259
268
  switch (e) {
260
- case "COMPLETED": return /* @__PURE__ */ x(m, {
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__ */ x(y, {
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__ */ x(g, {
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__ */ x(h, {
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 P(e, t) {
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 je = ({ status: e }) => {
298
- let { t } = w(), n = N[M(e)];
299
- return /* @__PURE__ */ S("span", {
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
- ...j,
311
+ ...A,
303
312
  border: `1px solid ${n.border}`,
304
313
  backgroundColor: n.bg,
305
314
  color: n.text
306
315
  },
307
- children: [Ae(e), P(e, t)]
316
+ children: [je(e), N(e, t)]
308
317
  });
309
318
  };
310
- function Me(e) {
311
- let t = N[e >= .8 ? "success" : e >= .5 ? "neutral" : "danger"];
319
+ function Ne(e) {
320
+ let t = M[e >= .8 ? "success" : e >= .5 ? "neutral" : "danger"];
312
321
  return {
313
- ...j,
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 F(e) {
328
+ function P(e) {
320
329
  return e.pages.reduce((e, t) => e + t.widgets.length, 0);
321
330
  }
322
- function Ne(e) {
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 Pe = {
335
+ var Fe = {
327
336
  HIGH: "success",
328
337
  MEDIUM: "neutral",
329
338
  LOW: "danger"
330
339
  };
331
- function Fe(e) {
332
- let t = N[Pe[e]];
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
- ...j,
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 I = c(function() {
345
- let { t: c } = w(), m = e(), h = a(), [y, C] = d(""), [T, M] = d("MODERN"), [N, Ae] = d("GRID"), [P, Pe] = d(Ce), [I, Ie] = d(we), [L, Le] = d(!1), [Re, R] = d(null), [z, ze] = d(() => /* @__PURE__ */ new Set()), [B, V] = d(null), [H, U] = d(null), [W, G] = d(""), K = l((e) => {
346
- ze((t) => new Set(t).add(e));
347
- }, []), q = l((e) => {
348
- ze((t) => {
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: Be, loading: Ve, refetch: J, startPolling: He, stopPolling: Y } = pe(me, {
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 = Be?.listPromptGenerations?.edges?.some((e) => Se.includes(e.node.status)) ?? !1, { data: Ue } = pe(he, { variables: { limit: 6 } }), [We] = b(ge), [Ge] = b(_e), [Ke] = b(ve), [qe] = b(ye), [Je] = b(be), [Ye] = b(xe), Z = Be?.listPromptGenerations?.edges?.map((e) => e.node) || [], Xe = Ue?.getPromptSuggestions || [];
356
- u(() => (X || L ? He(2e3) : Y(), () => Y()), [
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
- L,
359
- He,
379
+ I,
380
+ Ge,
360
381
  Y
361
- ]), u(() => {
362
- if (!B && !H) return;
382
+ ]), l(() => {
383
+ if (!z && !V) return;
363
384
  let e = (e) => {
364
- e.key === "Escape" && (V(null), U(null));
385
+ e.key === "Escape" && (B(null), H(null));
365
386
  };
366
387
  return window.addEventListener("keydown", e), () => window.removeEventListener("keydown", e);
367
- }, [B, H]);
368
- let Ze = l(async () => {
369
- if (!(!y.trim() || L)) {
370
- if (y.length > 2e3) {
371
- R(c("bigconsole.insights.error.promptTooLong", "Prompt is too long (max 2000 characters)."));
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
- R(null), Le(!0);
395
+ L(null), Be(!0);
375
396
  try {
376
- h("bigconsole.ai.generate_clicked", { maxWidgets: I });
377
- let e = await We({ variables: { input: {
378
- prompt: y.trim(),
379
- styleType: T,
380
- layoutType: N,
381
- gridColumns: P,
382
- maxWidgets: I
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 && h("bigconsole.ai.dashboard_generated", {
407
+ n && m("bigconsole.ai.dashboard_generated", {
387
408
  generationId: n,
388
- maxWidgets: I
389
- }), C(""), J();
409
+ maxWidgets: F
410
+ }), S(""), J();
390
411
  } catch (e) {
391
412
  if (t(e, "command")) return;
392
- R(e instanceof Error ? e.message : c("bigconsole.insights.error.generateFailed", "Failed to generate dashboard"));
413
+ L(e instanceof Error ? e.message : s("bigconsole.insights.error.generateFailed", "Failed to generate dashboard"));
393
414
  } finally {
394
- Le(!1);
415
+ Be(!1);
395
416
  }
396
417
  }
397
418
  }, [
398
- h,
399
- y,
400
- L,
401
- We,
419
+ m,
420
+ v,
421
+ I,
422
+ Ye,
402
423
  J,
403
- T,
424
+ w,
425
+ M,
404
426
  N,
405
- P,
406
- I,
407
- c
408
- ]), Q = l(async (e) => {
409
- R(null);
427
+ F,
428
+ s
429
+ ]), Q = c(async (e) => {
430
+ L(null);
410
431
  try {
411
- h("bigconsole.ai.create_dashboard_clicked", { generationId: e });
412
- let n = await Ge({ variables: { input: { generationId: e } } });
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 && (h("bigconsole.ai.dashboard_created", {
436
+ r && (m("bigconsole.ai.dashboard_created", {
416
437
  generationId: e,
417
438
  dashboardId: r
418
- }), m(`/dashboards/${r}`));
439
+ }), p(`/dashboards/${r}`));
419
440
  } catch (e) {
420
441
  if (t(e, "project")) return;
421
- R(e instanceof Error ? e.message : c("bigconsole.insights.error.createFailed", "Failed to create dashboard"));
442
+ L(e instanceof Error ? e.message : s("bigconsole.insights.error.createFailed", "Failed to create dashboard"));
422
443
  }
423
444
  }, [
424
- Ge,
425
- h,
445
+ Xe,
426
446
  m,
427
- c
428
- ]), Qe = l(async (e) => {
429
- R(null);
447
+ p,
448
+ s
449
+ ]), rt = c(async (e) => {
450
+ L(null);
430
451
  try {
431
- await Ke({ variables: { generationId: e } }), ee() && s("success"), J();
452
+ await Ze({ variables: { generationId: e } }), ee() && te("success"), J();
432
453
  } catch (e) {
433
- R(e instanceof Error ? e.message : c("bigconsole.insights.error.deleteFailed", "Failed to delete generation")), ee() && s("error");
454
+ L(e instanceof Error ? e.message : s("bigconsole.insights.error.deleteFailed", "Failed to delete generation")), ee() && te("error");
434
455
  }
435
456
  }, [
436
- Ke,
457
+ Ze,
437
458
  J,
438
- c
439
- ]), $e = l(async (e) => {
440
- R(null), K(e);
459
+ s
460
+ ]), it = c(async (e) => {
461
+ L(null), G(e);
441
462
  try {
442
- await qe({ variables: { generationId: e } }), J();
463
+ await Qe({ variables: { generationId: e } }), J();
443
464
  } catch (e) {
444
- R(e instanceof Error ? e.message : c("bigconsole.insights.error.cancelFailed", "Failed to cancel generation"));
465
+ L(e instanceof Error ? e.message : s("bigconsole.insights.error.cancelFailed", "Failed to cancel generation"));
445
466
  } finally {
446
- q(e);
467
+ K(e);
447
468
  }
448
469
  }, [
449
- qe,
470
+ Qe,
450
471
  J,
451
- c
452
- ]), et = l(async (e) => {
453
- R(null), K(e);
472
+ s
473
+ ]), at = c(async (e) => {
474
+ L(null), G(e);
454
475
  try {
455
- if (t(await Je({ variables: { input: { generationId: e } } }), "command")) return;
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
- R(e instanceof Error ? e.message : c("bigconsole.insights.error.regenerateFailed", "Failed to regenerate dashboard"));
480
+ L(e instanceof Error ? e.message : s("bigconsole.insights.error.regenerateFailed", "Failed to regenerate dashboard"));
460
481
  } finally {
461
- q(e);
482
+ K(e);
462
483
  }
463
484
  }, [
464
- Je,
485
+ $e,
465
486
  J,
466
- c
467
- ]), tt = l(async () => {
468
- if (!H || !W.trim()) return;
469
- let e = H.id;
470
- R(null), K(e);
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 Ye({ variables: { input: {
494
+ if (t(await et({ variables: { input: {
474
495
  generationId: e,
475
- refinementPrompt: W.trim()
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
- R(e instanceof Error ? e.message : c("bigconsole.insights.error.refineFailed", "Failed to refine generation"));
507
+ L(e instanceof Error ? e.message : s("bigconsole.insights.error.refineFailed", "Failed to refine generation"));
487
508
  } finally {
488
- n && (U(null), G("")), q(e);
509
+ n && (H(null), W("")), K(e);
489
510
  }
490
511
  }, [
491
- H,
492
- W,
493
- Ye,
512
+ V,
513
+ U,
514
+ et,
494
515
  J,
495
- c
496
- ]), nt = l((e) => {
497
- C(e);
498
- }, []), $ = B?.generatedSpec;
499
- return /* @__PURE__ */ S("div", {
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__ */ S("header", {
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__ */ x(ce, { intensity: "subtle" }), /* @__PURE__ */ x("div", {
527
+ children: [/* @__PURE__ */ b(le, { intensity: "subtle" }), /* @__PURE__ */ b("div", {
507
528
  style: { padding: "var(--space-pagePadding)" },
508
- children: /* @__PURE__ */ S("div", {
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__ */ x("div", {
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__ */ x(_, { style: {
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__ */ S("div", {
553
+ }), /* @__PURE__ */ x("div", {
533
554
  style: { minWidth: 0 },
534
- children: [/* @__PURE__ */ x("h1", {
555
+ children: [/* @__PURE__ */ b("h1", {
535
556
  className: "m-0 text-2xl font-bold text-text-primary",
536
- children: /* @__PURE__ */ x(ue, { children: c("bigconsole.insights.header.title", "AI Insights") })
537
- }), /* @__PURE__ */ x("p", {
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: c("bigconsole.insights.header.subtitle", "Generate dashboards from natural language prompts")
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__ */ S("div", {
566
+ /* @__PURE__ */ x("div", {
546
567
  style: { padding: "var(--space-pagePadding)" },
547
- children: [/* @__PURE__ */ x(fe, {
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__ */ S(i, { children: [
551
- Re && /* @__PURE__ */ x(r, {
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: Re,
557
- icon: /* @__PURE__ */ x(f, { className: "h-icon-sm w-icon-sm" }),
577
+ description: Ve,
578
+ icon: /* @__PURE__ */ b(d, { className: "h-icon-sm w-icon-sm" }),
558
579
  "data-testid": "insights-error",
559
- actions: /* @__PURE__ */ x("button", {
580
+ actions: /* @__PURE__ */ b("button", {
560
581
  type: "button",
561
- onClick: () => R(null),
562
- "aria-label": c("bigconsole.insights.error.dismiss", "Dismiss error"),
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: E,
585
+ style: T,
565
586
  children: "Dismiss"
566
587
  })
567
588
  }),
568
- /* @__PURE__ */ x(r, {
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__ */ x(_, { className: "h-icon-sm w-icon-sm" }),
622
+ icon: /* @__PURE__ */ b(g, { className: "h-icon-sm w-icon-sm" }),
575
623
  "data-testid": "insights-prompt",
576
- children: /* @__PURE__ */ S("div", {
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__ */ x("label", {
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: c("bigconsole.insights.prompt.label", "Your prompt")
639
+ children: s("bigconsole.insights.prompt.label", "Your prompt")
592
640
  }),
593
- /* @__PURE__ */ x("textarea", {
641
+ /* @__PURE__ */ b("textarea", {
594
642
  id: "prompt-input",
595
- value: y,
596
- onChange: (e) => C(e.target.value),
597
- placeholder: c("bigconsole.insights.prompt.placeholder", "e.g., Create a sales dashboard showing revenue trends, top products, and regional performance"),
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) && Ze();
661
+ e.key === "Enter" && (e.metaKey || e.ctrlKey) && (e.preventDefault(), nt());
614
662
  }
615
663
  }),
616
- /* @__PURE__ */ S("div", {
664
+ /* @__PURE__ */ x("div", {
617
665
  role: "group",
618
- "aria-label": c("bigconsole.insights.prompt.optionsLabel", "Generation options"),
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__ */ S("div", { children: [/* @__PURE__ */ x("label", {
674
+ /* @__PURE__ */ x("div", { children: [/* @__PURE__ */ b("label", {
627
675
  htmlFor: "prompt-style",
628
- style: k,
629
- children: c("bigconsole.insights.prompt.style", "Style")
630
- }), /* @__PURE__ */ x("select", {
676
+ style: O,
677
+ children: s("bigconsole.insights.prompt.style", "Style")
678
+ }), /* @__PURE__ */ b("select", {
631
679
  id: "prompt-style",
632
- value: T,
633
- onChange: (e) => M(e.target.value),
680
+ value: w,
681
+ onChange: (e) => j(e.target.value),
634
682
  className: n,
635
- style: A,
636
- children: Te.map((e) => /* @__PURE__ */ x("option", {
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__ */ S("div", { children: [/* @__PURE__ */ x("label", {
689
+ /* @__PURE__ */ x("div", { children: [/* @__PURE__ */ b("label", {
642
690
  htmlFor: "prompt-layout",
643
- style: k,
644
- children: c("bigconsole.insights.prompt.layout", "Layout")
645
- }), /* @__PURE__ */ x("select", {
691
+ style: O,
692
+ children: s("bigconsole.insights.prompt.layout", "Layout")
693
+ }), /* @__PURE__ */ b("select", {
646
694
  id: "prompt-layout",
647
- value: N,
648
- onChange: (e) => Ae(e.target.value),
695
+ value: M,
696
+ onChange: (e) => je(e.target.value),
649
697
  className: n,
650
- style: A,
651
- children: Ee.map((e) => /* @__PURE__ */ x("option", {
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__ */ S("div", { children: [/* @__PURE__ */ x("label", {
704
+ /* @__PURE__ */ x("div", { children: [/* @__PURE__ */ b("label", {
657
705
  htmlFor: "prompt-columns",
658
- style: k,
659
- children: c("bigconsole.insights.prompt.columns", "Columns")
660
- }), /* @__PURE__ */ x("select", {
706
+ style: O,
707
+ children: s("bigconsole.insights.prompt.columns", "Columns")
708
+ }), /* @__PURE__ */ b("select", {
661
709
  id: "prompt-columns",
662
- value: P,
663
- onChange: (e) => Pe(Number(e.target.value)),
710
+ value: N,
711
+ onChange: (e) => Fe(Number(e.target.value)),
664
712
  className: n,
665
- style: A,
666
- children: De.map((e) => /* @__PURE__ */ x("option", {
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__ */ S("div", { children: [/* @__PURE__ */ x("label", {
719
+ /* @__PURE__ */ x("div", { children: [/* @__PURE__ */ b("label", {
672
720
  htmlFor: "prompt-max-widgets",
673
- style: k,
674
- children: c("bigconsole.insights.prompt.maxWidgets", "Max widgets")
675
- }), /* @__PURE__ */ x("select", {
721
+ style: O,
722
+ children: s("bigconsole.insights.prompt.maxWidgets", "Max widgets")
723
+ }), /* @__PURE__ */ b("select", {
676
724
  id: "prompt-max-widgets",
677
- value: I,
678
- onChange: (e) => Ie(Number(e.target.value)),
725
+ value: F,
726
+ onChange: (e) => ze(Number(e.target.value)),
679
727
  className: n,
680
- style: A,
681
- children: Oe.map((e) => /* @__PURE__ */ x("option", {
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__ */ S("div", {
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__ */ S("span", {
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
- c("bigconsole.insights.prompt.hint", "Press Ctrl+Enter to generate"),
753
+ s("bigconsole.insights.prompt.hint", "Press Ctrl+Enter to generate"),
706
754
  " · ",
707
- y.length,
755
+ v.length,
708
756
  "/2000"
709
757
  ]
710
- }), /* @__PURE__ */ S("button", {
758
+ }), /* @__PURE__ */ x("button", {
711
759
  type: "button",
712
- onClick: Ze,
713
- disabled: !y.trim() || L,
760
+ onClick: nt,
761
+ disabled: !v.trim() || I,
714
762
  className: n,
715
763
  style: {
716
- ...D,
764
+ ...E,
717
765
  marginLeft: "auto",
718
- cursor: !y.trim() || L ? "not-allowed" : "pointer",
719
- opacity: !y.trim() || L ? .5 : 1
766
+ cursor: !v.trim() || I ? "not-allowed" : "pointer",
767
+ opacity: !v.trim() || I ? .5 : 1
720
768
  },
721
- children: [L ? /* @__PURE__ */ x(g, {
769
+ children: [I ? /* @__PURE__ */ b(h, {
722
770
  size: 16,
723
771
  className: "animate-spin",
724
772
  "aria-hidden": "true"
725
- }) : /* @__PURE__ */ x(_, {
773
+ }) : /* @__PURE__ */ b(g, {
726
774
  size: 16,
727
775
  "aria-hidden": "true"
728
- }), c("bigconsole.insights.prompt.generateButton", "Generate dashboard")]
776
+ }), s("bigconsole.insights.prompt.generateButton", "Generate dashboard")]
729
777
  })]
730
778
  })
731
779
  ]
732
780
  })
733
781
  }),
734
- Xe.length > 0 && /* @__PURE__ */ x(r, {
782
+ tt.length > 0 && /* @__PURE__ */ b(r, {
735
783
  emphasis: "muted",
736
784
  headingLevel: 2,
737
- title: c("bigconsole.insights.suggestions.heading", "Starting points"),
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__ */ x(ie, { className: "h-icon-sm w-icon-sm" }),
787
+ icon: /* @__PURE__ */ b(ae, { className: "h-icon-sm w-icon-sm" }),
740
788
  "data-testid": "insights-suggestions",
741
- children: /* @__PURE__ */ x("div", {
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: Xe.map((e) => /* @__PURE__ */ S("button", {
795
+ children: tt.map((e) => /* @__PURE__ */ x("button", {
748
796
  type: "button",
749
- onClick: () => nt(e.prompt),
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__ */ x("span", {
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__ */ x("span", {
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__ */ x("span", {
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__ */ x("span", {
789
- style: j,
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__ */ x(r, {
845
+ /* @__PURE__ */ b(r, {
798
846
  emphasis: "bare",
799
847
  padding: "none",
800
848
  headingLevel: 2,
801
- title: c("bigconsole.insights.generations.heading", "Recent generations"),
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__ */ x(re, { className: "h-icon-sm w-icon-sm" }),
804
- meta: Z.length > 0 ? /* @__PURE__ */ S("span", {
805
- style: j,
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: Ve && Z.length === 0 ? /* @__PURE__ */ x(r, {
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__ */ S("div", {
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__ */ x(g, {
877
+ children: [/* @__PURE__ */ b(h, {
830
878
  size: 24,
831
879
  className: "animate-spin",
832
880
  "aria-hidden": "true"
833
- }), /* @__PURE__ */ x("p", {
881
+ }), /* @__PURE__ */ b("p", {
834
882
  style: { fontSize: "var(--font-size-body-sm)" },
835
- children: c("bigconsole.insights.generations.loading", "Loading generations…")
883
+ children: s("bigconsole.insights.generations.loading", "Loading generations…")
836
884
  })]
837
885
  })
838
- }) : Z.length === 0 && !L ? /* @__PURE__ */ x(le, {
886
+ }) : Z.length === 0 && !I && !q ? /* @__PURE__ */ b(ue, {
839
887
  treatment: "insight",
840
888
  className: "border-[var(--color-border-seam)]",
841
- children: /* @__PURE__ */ x(de, {
889
+ children: /* @__PURE__ */ b(fe, {
842
890
  illustration: "onboarding",
843
- title: c("bigconsole.insights.generations.emptyTitle", "No generations yet"),
844
- description: c("bigconsole.insights.generations.emptyDescription", "Describe a dashboard above to get started")
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__ */ S("div", {
894
+ }) : /* @__PURE__ */ x("div", {
847
895
  className: "flex flex-col gap-list-gap",
848
- children: [L && !X && /* @__PURE__ */ x(r, {
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__ */ x(g, { className: "h-icon-sm w-icon-sm animate-spin" }),
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 = z.has(e.id), a = Se.includes(e.status);
859
- return /* @__PURE__ */ S(r, {
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 ? c("bigconsole.insights.generations.generating", "Generating…") : "Untitled generation"),
864
- meta: /* @__PURE__ */ x(je, { status: e.status }),
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__ */ S("div", {
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__ */ S("span", {
877
- style: j,
924
+ /* @__PURE__ */ x("span", {
925
+ style: A,
878
926
  children: [
879
- F(t),
927
+ P(t),
880
928
  " widget",
881
- F(t) === 1 ? "" : "s"
929
+ P(t) === 1 ? "" : "s"
882
930
  ]
883
931
  }),
884
- /* @__PURE__ */ S("span", {
885
- style: j,
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__ */ S("span", {
893
- style: Me(t.overallConfidence),
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__ */ x(r, {
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__ */ x(f, { className: "h-icon-sm w-icon-sm" })
952
+ icon: /* @__PURE__ */ b(d, { className: "h-icon-sm w-icon-sm" })
905
953
  }),
906
- /* @__PURE__ */ S("div", {
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__ */ S("button", {
964
+ a && /* @__PURE__ */ x("button", {
917
965
  type: "button",
918
966
  onClick: () => {
919
- o("medium"), $e(e.id);
967
+ o("medium"), it(e.id);
920
968
  },
921
969
  disabled: i,
922
- title: c("bigconsole.insights.actions.cancelTitle", "Cancel generation"),
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
- ...ke,
973
+ ...Ae,
926
974
  cursor: i ? "wait" : "pointer"
927
975
  },
928
976
  children: [
929
- /* @__PURE__ */ x(te, {
977
+ /* @__PURE__ */ b(ne, {
930
978
  size: 14,
931
979
  "aria-hidden": "true"
932
980
  }),
933
981
  " ",
934
- c("bigconsole.insights.actions.cancel", "Cancel")
982
+ s("bigconsole.insights.actions.cancel", "Cancel")
935
983
  ]
936
984
  }),
937
- e.status === "COMPLETED" && t && /* @__PURE__ */ S("button", {
985
+ e.status === "COMPLETED" && t && /* @__PURE__ */ x("button", {
938
986
  type: "button",
939
- onClick: () => V(e),
940
- title: c("bigconsole.insights.actions.previewTitle", "Preview proposed layout"),
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: E,
990
+ style: T,
943
991
  children: [
944
- /* @__PURE__ */ x(ne, {
992
+ /* @__PURE__ */ b(re, {
945
993
  size: 14,
946
994
  "aria-hidden": "true"
947
995
  }),
948
996
  " ",
949
- c("bigconsole.insights.actions.preview", "Preview")
997
+ s("bigconsole.insights.actions.preview", "Preview")
950
998
  ]
951
999
  }),
952
- e.status === "COMPLETED" && t && /* @__PURE__ */ S("button", {
1000
+ e.status === "COMPLETED" && t && /* @__PURE__ */ x("button", {
953
1001
  type: "button",
954
1002
  onClick: () => {
955
- U(e), G("");
1003
+ H(e), W("");
956
1004
  },
957
- title: c("bigconsole.insights.actions.refineTitle", "Refine with instructions"),
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: E,
1007
+ style: T,
960
1008
  children: [
961
- /* @__PURE__ */ x(v, {
1009
+ /* @__PURE__ */ b(_, {
962
1010
  size: 14,
963
1011
  "aria-hidden": "true"
964
1012
  }),
965
1013
  " ",
966
- c("bigconsole.insights.actions.refine", "Refine")
1014
+ s("bigconsole.insights.actions.refine", "Refine")
967
1015
  ]
968
1016
  }),
969
- (e.status === "COMPLETED" || e.status === "FAILED" || e.status === "CANCELLED") && /* @__PURE__ */ S("button", {
1017
+ (e.status === "COMPLETED" || e.status === "FAILED" || e.status === "CANCELLED") && /* @__PURE__ */ x("button", {
970
1018
  type: "button",
971
1019
  onClick: () => {
972
- o("medium"), et(e.id);
1020
+ o("medium"), at(e.id);
973
1021
  },
974
1022
  disabled: i,
975
- title: c("bigconsole.insights.actions.regenerateTitle", "Regenerate with the same prompt"),
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
- ...E,
1026
+ ...T,
979
1027
  cursor: i ? "wait" : "pointer"
980
1028
  },
981
1029
  children: [
982
- /* @__PURE__ */ x(ae, {
1030
+ /* @__PURE__ */ b(oe, {
983
1031
  size: 14,
984
1032
  className: i ? "animate-spin" : "",
985
1033
  "aria-hidden": "true"
986
1034
  }),
987
1035
  " ",
988
- c("bigconsole.insights.actions.regenerate", "Regenerate")
1036
+ s("bigconsole.insights.actions.regenerate", "Regenerate")
989
1037
  ]
990
1038
  }),
991
- /* @__PURE__ */ S("div", {
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__ */ S("button", {
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: D,
1052
+ style: E,
1005
1053
  children: [
1006
- c("bigconsole.insights.actions.create", "Create dashboard"),
1054
+ s("bigconsole.insights.actions.create", "Create dashboard"),
1007
1055
  " ",
1008
- /* @__PURE__ */ x(p, {
1056
+ /* @__PURE__ */ b(f, {
1009
1057
  size: 14,
1010
1058
  "aria-hidden": "true"
1011
1059
  })
1012
1060
  ]
1013
1061
  }),
1014
- e.dashboardId && /* @__PURE__ */ S("button", {
1062
+ e.dashboardId && /* @__PURE__ */ x("button", {
1015
1063
  type: "button",
1016
- onClick: () => m(`/dashboards/${e.dashboardId ?? ""}`),
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: E,
1066
+ style: T,
1019
1067
  children: [
1020
- c("bigconsole.insights.actions.viewDashboard", "View dashboard"),
1068
+ s("bigconsole.insights.actions.viewDashboard", "View dashboard"),
1021
1069
  " ",
1022
- /* @__PURE__ */ x(p, {
1070
+ /* @__PURE__ */ b(f, {
1023
1071
  size: 14,
1024
1072
  "aria-hidden": "true"
1025
1073
  })
1026
1074
  ]
1027
1075
  }),
1028
- /* @__PURE__ */ x("button", {
1076
+ /* @__PURE__ */ b("button", {
1029
1077
  type: "button",
1030
1078
  onClick: () => {
1031
- o("medium"), Qe(e.id);
1079
+ o("medium"), rt(e.id);
1032
1080
  },
1033
- title: c("bigconsole.insights.actions.deleteTitle", "Delete generation"),
1034
- "aria-label": c("bigconsole.insights.actions.deleteTitle", "Delete generation"),
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: O,
1037
- children: /* @__PURE__ */ x(oe, {
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
- B && $ && /* @__PURE__ */ x("div", {
1101
+ z && $ && /* @__PURE__ */ b("div", {
1054
1102
  role: "dialog",
1055
1103
  "aria-modal": "true",
1056
- "aria-label": c("bigconsole.insights.preview.ariaLabel", "Generation preview"),
1057
- onClick: () => V(null),
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__ */ S("div", {
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__ */ S("div", {
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__ */ S("div", {
1139
+ children: [/* @__PURE__ */ x("div", {
1092
1140
  style: { minWidth: 0 },
1093
- children: [/* @__PURE__ */ x("h2", {
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__ */ x("p", {
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__ */ x("button", {
1156
+ }), /* @__PURE__ */ b("button", {
1109
1157
  type: "button",
1110
- onClick: () => V(null),
1111
- "aria-label": c("bigconsole.insights.preview.close", "Close preview"),
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
- ...O,
1162
+ ...D,
1115
1163
  color: "var(--color-text-muted)"
1116
1164
  },
1117
- children: /* @__PURE__ */ x(se, {
1165
+ children: /* @__PURE__ */ b(ce, {
1118
1166
  size: 18,
1119
1167
  "aria-hidden": "true"
1120
1168
  })
1121
1169
  })]
1122
1170
  }),
1123
- /* @__PURE__ */ S("div", {
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__ */ S("div", {
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__ */ S("span", {
1142
- style: j,
1189
+ /* @__PURE__ */ x("span", {
1190
+ style: A,
1143
1191
  children: [
1144
- F($),
1192
+ P($),
1145
1193
  " widget",
1146
- F($) === 1 ? "" : "s"
1194
+ P($) === 1 ? "" : "s"
1147
1195
  ]
1148
1196
  }),
1149
- /* @__PURE__ */ S("span", {
1150
- style: j,
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__ */ S("span", {
1158
- style: Me($.overallConfidence),
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__ */ S("details", {
1211
+ $.reasoning && /* @__PURE__ */ x("details", {
1164
1212
  "data-testid": "preview-reasoning",
1165
- children: [/* @__PURE__ */ x("summary", {
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: c("bigconsole.insights.preview.reasoningToggle", "Why these widgets?")
1175
- }), /* @__PURE__ */ x("p", {
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__ */ S("span", {
1191
- style: j,
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("div", {
1246
+ children: [/* @__PURE__ */ x("p", {
1199
1247
  style: {
1200
- display: "flex",
1201
- flexDirection: "column",
1202
- gap: "var(--space-controlGap)"
1248
+ fontSize: "var(--font-size-body-sm)",
1249
+ color: "var(--color-text-secondary)",
1250
+ marginBottom: "var(--space-controlGap)"
1203
1251
  },
1204
- children: e.widgets.map((e, t) => {
1205
- let n = Ne(e.confidence);
1206
- return /* @__PURE__ */ S("div", {
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__ */ S("div", {
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__ */ x("span", {
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: e.title
1294
+ children: t.title
1232
1295
  }),
1233
- /* @__PURE__ */ x("span", {
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: e.type
1302
+ children: t.type
1240
1303
  }),
1241
- n && /* @__PURE__ */ x("span", {
1304
+ r && /* @__PURE__ */ b("span", {
1242
1305
  style: {
1243
- ...Fe(n),
1306
+ ...Re(r),
1244
1307
  marginLeft: "auto"
1245
1308
  },
1246
1309
  "data-testid": "preview-widget-confidence",
1247
- children: n
1310
+ children: r
1248
1311
  })
1249
1312
  ]
1250
- }), e.reasoning && /* @__PURE__ */ x("p", {
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: e.reasoning
1320
+ children: t.reasoning
1258
1321
  })]
1259
- }, t);
1322
+ }, n);
1260
1323
  })
1261
- })
1324
+ })]
1262
1325
  }, t))
1263
1326
  ]
1264
1327
  }),
1265
- /* @__PURE__ */ S("div", {
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__ */ x("button", {
1338
+ /* @__PURE__ */ b("button", {
1276
1339
  type: "button",
1277
- onClick: () => V(null),
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: E,
1342
+ style: T,
1280
1343
  children: "Close"
1281
1344
  }),
1282
- B.status === "COMPLETED" && $ && /* @__PURE__ */ S("button", {
1345
+ z.status === "COMPLETED" && $ && /* @__PURE__ */ x("button", {
1283
1346
  type: "button",
1284
1347
  onClick: () => {
1285
- let e = B;
1286
- V(null), U(e), G("");
1348
+ let e = z;
1349
+ B(null), H(e), W("");
1287
1350
  },
1288
- title: c("bigconsole.insights.actions.refineTitle", "Refine with instructions"),
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: E,
1353
+ style: T,
1291
1354
  children: [
1292
- /* @__PURE__ */ x(v, {
1355
+ /* @__PURE__ */ b(_, {
1293
1356
  size: 14,
1294
1357
  "aria-hidden": "true"
1295
1358
  }),
1296
1359
  " ",
1297
- c("bigconsole.insights.actions.refine", "Refine")
1360
+ s("bigconsole.insights.actions.refine", "Refine")
1298
1361
  ]
1299
1362
  }),
1300
- B.status === "COMPLETED" && !B.dashboardId && /* @__PURE__ */ S("button", {
1363
+ z.status === "COMPLETED" && !z.dashboardId && /* @__PURE__ */ x("button", {
1301
1364
  type: "button",
1302
1365
  onClick: () => {
1303
- let e = B.id;
1304
- V(null), Q(e);
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: D,
1370
+ style: E,
1308
1371
  children: [
1309
- c("bigconsole.insights.actions.create", "Create dashboard"),
1372
+ s("bigconsole.insights.actions.create", "Create dashboard"),
1310
1373
  " ",
1311
- /* @__PURE__ */ x(p, {
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
- H && /* @__PURE__ */ x("div", {
1385
+ V && /* @__PURE__ */ b("div", {
1323
1386
  role: "dialog",
1324
1387
  "aria-modal": "true",
1325
- "aria-label": c("bigconsole.insights.refine.ariaLabel", "Refine generation"),
1326
- onClick: () => U(null),
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__ */ S("div", {
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__ */ S("div", {
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__ */ x("h2", {
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: c("bigconsole.insights.refine.heading", "Refine dashboard")
1363
- }), /* @__PURE__ */ x("p", {
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: c("bigconsole.insights.refine.subtitle", "Describe what to change — the AI keeps the existing spec and applies your instructions.")
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__ */ S("div", {
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__ */ x(r, {
1445
+ children: [/* @__PURE__ */ b(r, {
1383
1446
  emphasis: "muted",
1384
1447
  padding: "compact",
1385
1448
  headingLevel: 3,
1386
- title: H.generatedSpec?.name || "Current proposal",
1387
- description: H.prompt.length > 240 ? `${H.prompt.slice(0, 240)}…` : H.prompt,
1388
- icon: /* @__PURE__ */ x(_, { className: "h-icon-sm w-icon-sm" })
1389
- }), /* @__PURE__ */ S("div", {
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__ */ x("label", {
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__ */ x("textarea", {
1467
+ }), /* @__PURE__ */ b("textarea", {
1405
1468
  id: "refine-input",
1406
- value: W,
1407
- onChange: (e) => G(e.target.value),
1469
+ value: U,
1470
+ onChange: (e) => W(e.target.value),
1408
1471
  maxLength: 2e3,
1409
1472
  rows: 4,
1410
- placeholder: c("bigconsole.insights.refine.placeholder", "e.g., Add a revenue-by-region map and remove the duplicate KPI cards"),
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__ */ S("div", {
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__ */ x("button", {
1498
+ children: [/* @__PURE__ */ b("button", {
1436
1499
  type: "button",
1437
- onClick: () => U(null),
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: E,
1440
- children: c("bigconsole.insights.actions.cancel", "Cancel")
1441
- }), /* @__PURE__ */ S("button", {
1502
+ style: T,
1503
+ children: s("bigconsole.insights.actions.cancel", "Cancel")
1504
+ }), /* @__PURE__ */ x("button", {
1442
1505
  type: "button",
1443
- onClick: () => void tt(),
1444
- disabled: !W.trim() || z.has(H.id),
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
- ...D,
1448
- cursor: !W.trim() || z.has(H.id) ? "not-allowed" : "pointer",
1449
- opacity: W.trim() ? 1 : .6
1510
+ ...E,
1511
+ cursor: !U.trim() || R.has(V.id) ? "not-allowed" : "pointer",
1512
+ opacity: U.trim() ? 1 : .6
1450
1513
  },
1451
- children: [z.has(H.id) ? /* @__PURE__ */ x(g, {
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__ */ x(v, {
1518
+ }) : /* @__PURE__ */ b(_, {
1456
1519
  size: 14,
1457
1520
  "aria-hidden": "true"
1458
- }), c("bigconsole.insights.refine.apply", "Apply refinement")]
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 { I as InsightsPage, I as default };
1531
+ export { F as InsightsPage, F as default };
1469
1532
 
1470
1533
  //# sourceMappingURL=InsightsPage.js.map