@burdenoff/microfe-bigconsole 2026.805.3 → 2026.812.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (247) hide show
  1. package/dist/bigconsole/components/DrilldownDashboardRenderer.js +118 -106
  2. package/dist/bigconsole/components/DrilldownDashboardRenderer.js.map +1 -1
  3. package/dist/bigconsole/components/DrilldownModal.js +54 -50
  4. package/dist/bigconsole/components/DrilldownModal.js.map +1 -1
  5. package/dist/bigconsole/components/builder/BuilderCanvas.js +2 -2
  6. package/dist/bigconsole/components/builder/BuilderCanvas.js.map +1 -1
  7. package/dist/bigconsole/components/builder/BuilderTopbar.js +3 -3
  8. package/dist/bigconsole/components/builder/BuilderTopbar.js.map +1 -1
  9. package/dist/bigconsole/components/builder/inspector/AdvancedSection.js +24 -25
  10. package/dist/bigconsole/components/builder/inspector/AdvancedSection.js.map +1 -1
  11. package/dist/bigconsole/components/builder/inspector/AppearanceSection.js +40 -29
  12. package/dist/bigconsole/components/builder/inspector/AppearanceSection.js.map +1 -1
  13. package/dist/bigconsole/components/builder/inspector/DataBindingSection.js +135 -97
  14. package/dist/bigconsole/components/builder/inspector/DataBindingSection.js.map +1 -1
  15. package/dist/bigconsole/components/builder/inspector/GeneralSection.js +58 -44
  16. package/dist/bigconsole/components/builder/inspector/GeneralSection.js.map +1 -1
  17. package/dist/bigconsole/components/common/Section.js +70 -0
  18. package/dist/bigconsole/components/common/Section.js.map +1 -0
  19. package/dist/bigconsole/components/common/index.js +2 -0
  20. package/dist/bigconsole/components/common/sectionStyles.js +42 -0
  21. package/dist/bigconsole/components/common/sectionStyles.js.map +1 -0
  22. package/dist/bigconsole/components/dashboard/CreateDashboardDialog.js +209 -193
  23. package/dist/bigconsole/components/dashboard/CreateDashboardDialog.js.map +1 -1
  24. package/dist/bigconsole/components/dashboard/DashboardCanvas.js +213 -231
  25. package/dist/bigconsole/components/dashboard/DashboardCanvas.js.map +1 -1
  26. package/dist/bigconsole/components/dashboard/DashboardGrid.js +12 -18
  27. package/dist/bigconsole/components/dashboard/DashboardGrid.js.map +1 -1
  28. package/dist/bigconsole/components/dashboard/DashboardToolbar.js +109 -102
  29. package/dist/bigconsole/components/dashboard/DashboardToolbar.js.map +1 -1
  30. package/dist/bigconsole/components/dashboard/DrilldownBreadcrumb.js +81 -70
  31. package/dist/bigconsole/components/dashboard/DrilldownBreadcrumb.js.map +1 -1
  32. package/dist/bigconsole/components/dashboard/ExportDashboardDialog.js +125 -159
  33. package/dist/bigconsole/components/dashboard/ExportDashboardDialog.js.map +1 -1
  34. package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterChip.js +25 -23
  35. package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterChip.js.map +1 -1
  36. package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterEditor.js +3 -3
  37. package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterEditor.js.map +1 -1
  38. package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterPresetSelector.js +5 -3
  39. package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterPresetSelector.js.map +1 -1
  40. package/dist/bigconsole/components/dashboard/GlobalFiltersBar/GlobalFiltersBar.js +170 -284
  41. package/dist/bigconsole/components/dashboard/GlobalFiltersBar/GlobalFiltersBar.js.map +1 -1
  42. package/dist/bigconsole/components/dashboard/ImportDashboardDialog.js +147 -151
  43. package/dist/bigconsole/components/dashboard/ImportDashboardDialog.js.map +1 -1
  44. package/dist/bigconsole/components/dashboard/LiveBoardBanner.js +45 -53
  45. package/dist/bigconsole/components/dashboard/LiveBoardBanner.js.map +1 -1
  46. package/dist/bigconsole/components/dashboard/PageTabsManager/PageTabsManager.js +157 -148
  47. package/dist/bigconsole/components/dashboard/PageTabsManager/PageTabsManager.js.map +1 -1
  48. package/dist/bigconsole/components/dashboard/SavedViewsDropdown/SavedViewsDropdown.js +17 -8
  49. package/dist/bigconsole/components/dashboard/SavedViewsDropdown/SavedViewsDropdown.js.map +1 -1
  50. package/dist/bigconsole/components/dashboard/ShareDialog/ShareDialog.js +101 -95
  51. package/dist/bigconsole/components/dashboard/ShareDialog/ShareDialog.js.map +1 -1
  52. package/dist/bigconsole/components/dashboard/StoreTemplatePicker.js +20 -18
  53. package/dist/bigconsole/components/dashboard/StoreTemplatePicker.js.map +1 -1
  54. package/dist/bigconsole/components/dashboard/TemplateSetupBanner.js +26 -58
  55. package/dist/bigconsole/components/dashboard/TemplateSetupBanner.js.map +1 -1
  56. package/dist/bigconsole/components/dashboard/WidgetPalette.js +307 -231
  57. package/dist/bigconsole/components/dashboard/WidgetPalette.js.map +1 -1
  58. package/dist/bigconsole/components/datasink/CacheTTLSelector.js +29 -29
  59. package/dist/bigconsole/components/datasink/CacheTTLSelector.js.map +1 -1
  60. package/dist/bigconsole/components/datasink/DataSinkCard.js +78 -79
  61. package/dist/bigconsole/components/datasink/DataSinkCard.js.map +1 -1
  62. package/dist/bigconsole/components/datasink/DataSinkDataViewer.js +33 -34
  63. package/dist/bigconsole/components/datasink/DataSinkDataViewer.js.map +1 -1
  64. package/dist/bigconsole/components/datasink/DataSinkDeleteDialog.js +79 -56
  65. package/dist/bigconsole/components/datasink/DataSinkDeleteDialog.js.map +1 -1
  66. package/dist/bigconsole/components/datasink/DataSinkRefreshDialog.js +75 -65
  67. package/dist/bigconsole/components/datasink/DataSinkRefreshDialog.js.map +1 -1
  68. package/dist/bigconsole/components/datasink/DataSinkStatusBadge.js +1 -1
  69. package/dist/bigconsole/components/datasink/DataSinkStatusBadge.js.map +1 -1
  70. package/dist/bigconsole/components/datasink/DataSinkTableViewer.js +20 -19
  71. package/dist/bigconsole/components/datasink/DataSinkTableViewer.js.map +1 -1
  72. package/dist/bigconsole/components/datasink/ExportDataSinkDialog.js +127 -171
  73. package/dist/bigconsole/components/datasink/ExportDataSinkDialog.js.map +1 -1
  74. package/dist/bigconsole/components/datasink/ImportDataSinkDialog.js +263 -243
  75. package/dist/bigconsole/components/datasink/ImportDataSinkDialog.js.map +1 -1
  76. package/dist/bigconsole/components/datasink/LinkedParsersPanel.js +65 -66
  77. package/dist/bigconsole/components/datasink/LinkedParsersPanel.js.map +1 -1
  78. package/dist/bigconsole/components/datasink/LinkedWorkflowsPanel.js +121 -127
  79. package/dist/bigconsole/components/datasink/LinkedWorkflowsPanel.js.map +1 -1
  80. package/dist/bigconsole/components/datasink/RefreshTypeSelector.js +33 -26
  81. package/dist/bigconsole/components/datasink/RefreshTypeSelector.js.map +1 -1
  82. package/dist/bigconsole/components/datasink/SetupStateBadge.js +3 -3
  83. package/dist/bigconsole/components/datasink/SetupStateBadge.js.map +1 -1
  84. package/dist/bigconsole/components/datasink/WorkflowStatusPanel.js +95 -95
  85. package/dist/bigconsole/components/datasink/WorkflowStatusPanel.js.map +1 -1
  86. package/dist/bigconsole/components/parser/DataSinkSelector.js +154 -123
  87. package/dist/bigconsole/components/parser/DataSinkSelector.js.map +1 -1
  88. package/dist/bigconsole/components/parser/ExpressionEditor.js +3 -3
  89. package/dist/bigconsole/components/parser/ExpressionEditor.js.map +1 -1
  90. package/dist/bigconsole/components/parser/ImportParserDialog.js +235 -275
  91. package/dist/bigconsole/components/parser/ImportParserDialog.js.map +1 -1
  92. package/dist/bigconsole/components/parser/ParserCard.js +133 -114
  93. package/dist/bigconsole/components/parser/ParserCard.js.map +1 -1
  94. package/dist/bigconsole/components/parser/ParserSelector.js +191 -174
  95. package/dist/bigconsole/components/parser/ParserSelector.js.map +1 -1
  96. package/dist/bigconsole/components/parser/ParserStatusBadge.js +2 -2
  97. package/dist/bigconsole/components/parser/ParserStatusBadge.js.map +1 -1
  98. package/dist/bigconsole/components/parser/ParserTypeBadge.js +4 -4
  99. package/dist/bigconsole/components/parser/ParserTypeBadge.js.map +1 -1
  100. package/dist/bigconsole/components/pipeline/PipelineCard.js +134 -89
  101. package/dist/bigconsole/components/pipeline/PipelineCard.js.map +1 -1
  102. package/dist/bigconsole/components/pipeline/PipelineDeleteDialog.js +77 -64
  103. package/dist/bigconsole/components/pipeline/PipelineDeleteDialog.js.map +1 -1
  104. package/dist/bigconsole/components/pipeline/PipelineStatusBadge.js +7 -10
  105. package/dist/bigconsole/components/pipeline/PipelineStatusBadge.js.map +1 -1
  106. package/dist/bigconsole/components/preview/AiPreviewContent.js +31 -32
  107. package/dist/bigconsole/components/preview/AiPreviewContent.js.map +1 -1
  108. package/dist/bigconsole/components/preview/AiPreviewMiniPanel.js +152 -106
  109. package/dist/bigconsole/components/preview/AiPreviewMiniPanel.js.map +1 -1
  110. package/dist/bigconsole/components/preview/AiPreviewPanel.js +193 -152
  111. package/dist/bigconsole/components/preview/AiPreviewPanel.js.map +1 -1
  112. package/dist/bigconsole/components/preview/previewShared.js +41 -23
  113. package/dist/bigconsole/components/preview/previewShared.js.map +1 -1
  114. package/dist/bigconsole/components/widgets/ActionConfigDialog.js +342 -308
  115. package/dist/bigconsole/components/widgets/ActionConfigDialog.js.map +1 -1
  116. package/dist/bigconsole/components/widgets/DrilldownConfigPanel.js +262 -238
  117. package/dist/bigconsole/components/widgets/DrilldownConfigPanel.js.map +1 -1
  118. package/dist/bigconsole/components/widgets/PropertiesPanel.js +783 -867
  119. package/dist/bigconsole/components/widgets/PropertiesPanel.js.map +1 -1
  120. package/dist/bigconsole/components/widgets/WidgetErrorBoundary.js +7 -5
  121. package/dist/bigconsole/components/widgets/WidgetErrorBoundary.js.map +1 -1
  122. package/dist/bigconsole/components/widgets/WidgetHeader.js +7 -8
  123. package/dist/bigconsole/components/widgets/WidgetHeader.js.map +1 -1
  124. package/dist/bigconsole/components/widgets/WidgetRegistry.js +4 -4
  125. package/dist/bigconsole/components/widgets/WidgetRegistry.js.map +1 -1
  126. package/dist/bigconsole/components/widgets/WidgetWrapper.js +8 -7
  127. package/dist/bigconsole/components/widgets/WidgetWrapper.js.map +1 -1
  128. package/dist/bigconsole/components/widgets/adaptive-card/AdaptiveCardWidget.js +1 -1
  129. package/dist/bigconsole/components/widgets/adaptive-card/AdaptiveCardWidget.js.map +1 -1
  130. package/dist/bigconsole/components/widgets/calendar/CalendarWidget.js +2 -2
  131. package/dist/bigconsole/components/widgets/calendar/CalendarWidget.js.map +1 -1
  132. package/dist/bigconsole/components/widgets/chart/ChartConfig.js +11 -5
  133. package/dist/bigconsole/components/widgets/chart/ChartConfig.js.map +1 -1
  134. package/dist/bigconsole/components/widgets/comments/WidgetComments.js +19 -15
  135. package/dist/bigconsole/components/widgets/comments/WidgetComments.js.map +1 -1
  136. package/dist/bigconsole/components/widgets/event-logs/EventLogViewer.js +154 -102
  137. package/dist/bigconsole/components/widgets/event-logs/EventLogViewer.js.map +1 -1
  138. package/dist/bigconsole/components/widgets/gauge/CircularGauge.js +36 -32
  139. package/dist/bigconsole/components/widgets/gauge/CircularGauge.js.map +1 -1
  140. package/dist/bigconsole/components/widgets/gauge/GaugeConfig.js +85 -60
  141. package/dist/bigconsole/components/widgets/gauge/GaugeConfig.js.map +1 -1
  142. package/dist/bigconsole/components/widgets/gauge/GaugeWidget.js +64 -35
  143. package/dist/bigconsole/components/widgets/gauge/GaugeWidget.js.map +1 -1
  144. package/dist/bigconsole/components/widgets/gauge/LinearGauge.js +46 -45
  145. package/dist/bigconsole/components/widgets/gauge/LinearGauge.js.map +1 -1
  146. package/dist/bigconsole/components/widgets/heatmap/HeatmapConfig.js +35 -24
  147. package/dist/bigconsole/components/widgets/heatmap/HeatmapConfig.js.map +1 -1
  148. package/dist/bigconsole/components/widgets/iframe-widget/IframeWidget.js +2 -2
  149. package/dist/bigconsole/components/widgets/iframe-widget/IframeWidget.js.map +1 -1
  150. package/dist/bigconsole/components/widgets/kanban/KanbanWidget.js +4 -4
  151. package/dist/bigconsole/components/widgets/kanban/KanbanWidget.js.map +1 -1
  152. package/dist/bigconsole/components/widgets/kpi-comparison/KPIComparisonWidget.js +153 -90
  153. package/dist/bigconsole/components/widgets/kpi-comparison/KPIComparisonWidget.js.map +1 -1
  154. package/dist/bigconsole/components/widgets/list/ListConfig.js +8 -2
  155. package/dist/bigconsole/components/widgets/list/ListConfig.js.map +1 -1
  156. package/dist/bigconsole/components/widgets/list/ListItem.js +1 -1
  157. package/dist/bigconsole/components/widgets/list/ListItem.js.map +1 -1
  158. package/dist/bigconsole/components/widgets/map-widget/MapWidget.js +1 -1
  159. package/dist/bigconsole/components/widgets/map-widget/MapWidget.js.map +1 -1
  160. package/dist/bigconsole/components/widgets/metric-card/MetricCardConfig.js +14 -4
  161. package/dist/bigconsole/components/widgets/metric-card/MetricCardConfig.js.map +1 -1
  162. package/dist/bigconsole/components/widgets/metric-card/MetricCardWidget.js +112 -89
  163. package/dist/bigconsole/components/widgets/metric-card/MetricCardWidget.js.map +1 -1
  164. package/dist/bigconsole/components/widgets/metric-card/SparklineChart.js +21 -13
  165. package/dist/bigconsole/components/widgets/metric-card/SparklineChart.js.map +1 -1
  166. package/dist/bigconsole/components/widgets/metric-card/index.js +4 -4
  167. package/dist/bigconsole/components/widgets/pivot-table/PivotTableWidget.js +3 -3
  168. package/dist/bigconsole/components/widgets/pivot-table/PivotTableWidget.js.map +1 -1
  169. package/dist/bigconsole/components/widgets/progress/ProgressConfig.js +34 -25
  170. package/dist/bigconsole/components/widgets/progress/ProgressConfig.js.map +1 -1
  171. package/dist/bigconsole/components/widgets/progress/ProgressWidget.js +129 -114
  172. package/dist/bigconsole/components/widgets/progress/ProgressWidget.js.map +1 -1
  173. package/dist/bigconsole/components/widgets/retention/RetentionWidget.js +3 -3
  174. package/dist/bigconsole/components/widgets/retention/RetentionWidget.js.map +1 -1
  175. package/dist/bigconsole/components/widgets/states/EmptyState.js +6 -4
  176. package/dist/bigconsole/components/widgets/states/EmptyState.js.map +1 -1
  177. package/dist/bigconsole/components/widgets/states/ErrorState.js +7 -5
  178. package/dist/bigconsole/components/widgets/states/ErrorState.js.map +1 -1
  179. package/dist/bigconsole/components/widgets/states/LoadingState.js +5 -4
  180. package/dist/bigconsole/components/widgets/states/LoadingState.js.map +1 -1
  181. package/dist/bigconsole/components/widgets/table/TableConfig.js +10 -4
  182. package/dist/bigconsole/components/widgets/table/TableConfig.js.map +1 -1
  183. package/dist/bigconsole/components/widgets/table/TableHeader.js +1 -1
  184. package/dist/bigconsole/components/widgets/table/TableHeader.js.map +1 -1
  185. package/dist/bigconsole/components/widgets/table/TableWidget.js +1 -1
  186. package/dist/bigconsole/components/widgets/table/TableWidget.js.map +1 -1
  187. package/dist/bigconsole/components/widgets/text-widget/TextWidget.js +1 -1
  188. package/dist/bigconsole/components/widgets/text-widget/TextWidget.js.map +1 -1
  189. package/dist/bigconsole/components/widgets/timeline/TimelineWidget.js +3 -3
  190. package/dist/bigconsole/components/widgets/timeline/TimelineWidget.js.map +1 -1
  191. package/dist/bigconsole/components/widgets/utils/conditionalFormat.js +2 -2
  192. package/dist/bigconsole/components/widgets/utils/conditionalFormat.js.map +1 -1
  193. package/dist/bigconsole/components/widgets/utils/targetProgress.js +13 -0
  194. package/dist/bigconsole/components/widgets/utils/targetProgress.js.map +1 -0
  195. package/dist/bigconsole/components/widgets/webhook-config/WebhookConfigPanel.js +112 -85
  196. package/dist/bigconsole/components/widgets/webhook-config/WebhookConfigPanel.js.map +1 -1
  197. package/dist/bigconsole/components/widgets/widget-actions/WidgetActions.js +28 -20
  198. package/dist/bigconsole/components/widgets/widget-actions/WidgetActions.js.map +1 -1
  199. package/dist/bigconsole/components/workflow/WorkflowCard.js +92 -77
  200. package/dist/bigconsole/components/workflow/WorkflowCard.js.map +1 -1
  201. package/dist/bigconsole/components/workflow/WorkflowDeleteDialog.js +70 -51
  202. package/dist/bigconsole/components/workflow/WorkflowDeleteDialog.js.map +1 -1
  203. package/dist/bigconsole/components/workflow/WorkflowStatusBadge.js +16 -17
  204. package/dist/bigconsole/components/workflow/WorkflowStatusBadge.js.map +1 -1
  205. package/dist/bigconsole/customWidget/CustomWidgetBuilderSheet.js +6 -4
  206. package/dist/bigconsole/customWidget/CustomWidgetBuilderSheet.js.map +1 -1
  207. package/dist/bigconsole/customWidget/CustomWidgetProposalPanel.js +360 -338
  208. package/dist/bigconsole/customWidget/CustomWidgetProposalPanel.js.map +1 -1
  209. package/dist/bigconsole/hooks/useModalFocusTrap.js +53 -0
  210. package/dist/bigconsole/hooks/useModalFocusTrap.js.map +1 -0
  211. package/dist/bigconsole/pages/DashboardBuilderPage.js +209 -203
  212. package/dist/bigconsole/pages/DashboardBuilderPage.js.map +1 -1
  213. package/dist/bigconsole/pages/DashboardViewPage.js +126 -120
  214. package/dist/bigconsole/pages/DashboardViewPage.js.map +1 -1
  215. package/dist/bigconsole/pages/DashboardsPage.js +838 -800
  216. package/dist/bigconsole/pages/DashboardsPage.js.map +1 -1
  217. package/dist/bigconsole/pages/DataParsersPage.js +263 -315
  218. package/dist/bigconsole/pages/DataParsersPage.js.map +1 -1
  219. package/dist/bigconsole/pages/DataSinkBuilderPage.js +301 -341
  220. package/dist/bigconsole/pages/DataSinkBuilderPage.js.map +1 -1
  221. package/dist/bigconsole/pages/DataSinkViewPage.js +346 -339
  222. package/dist/bigconsole/pages/DataSinkViewPage.js.map +1 -1
  223. package/dist/bigconsole/pages/DataSinksPage.js +356 -458
  224. package/dist/bigconsole/pages/DataSinksPage.js.map +1 -1
  225. package/dist/bigconsole/pages/DataSourcesPage.js +7 -2
  226. package/dist/bigconsole/pages/DataSourcesPage.js.map +1 -1
  227. package/dist/bigconsole/pages/HomePage.js +186 -193
  228. package/dist/bigconsole/pages/HomePage.js.map +1 -1
  229. package/dist/bigconsole/pages/InsightsPage.js +887 -740
  230. package/dist/bigconsole/pages/InsightsPage.js.map +1 -1
  231. package/dist/bigconsole/pages/ParserBuilderPage.js +679 -637
  232. package/dist/bigconsole/pages/ParserBuilderPage.js.map +1 -1
  233. package/dist/bigconsole/pages/ParserViewPage.js +368 -342
  234. package/dist/bigconsole/pages/ParserViewPage.js.map +1 -1
  235. package/dist/bigconsole/pages/PipelineBuilderPage.js +537 -444
  236. package/dist/bigconsole/pages/PipelineBuilderPage.js.map +1 -1
  237. package/dist/bigconsole/pages/PipelineViewPage.js +412 -377
  238. package/dist/bigconsole/pages/PipelineViewPage.js.map +1 -1
  239. package/dist/bigconsole/pages/PipelinesPage.js +248 -298
  240. package/dist/bigconsole/pages/PipelinesPage.js.map +1 -1
  241. package/dist/bigconsole/pages/WidgetDemoPage.js +251 -153
  242. package/dist/bigconsole/pages/WidgetDemoPage.js.map +1 -1
  243. package/dist/bigconsole/pages/WorkflowViewPage.js +381 -371
  244. package/dist/bigconsole/pages/WorkflowViewPage.js.map +1 -1
  245. package/dist/bigconsole/pages/WorkflowsPage.js +171 -286
  246. package/dist/bigconsole/pages/WorkflowsPage.js.map +1 -1
  247. package/package.json +1 -1
@@ -1,187 +1,193 @@
1
- import e from "../../hooks/useImportParser.js";
1
+ import { Section as e } from "../common/Section.js";
2
+ import "../common/index.js";
3
+ import t from "../../hooks/useImportParser.js";
2
4
  import "../../hooks/index.js";
3
- import { memo as t, useCallback as n, useEffect as r, useRef as i, useState as a } from "react";
4
- import { ArrowLeft as o, Check as s, FileJson as c, Info as l, RefreshCw as u, Upload as d, XCircle as f } from "lucide-react";
5
- import { useI18n as ee } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
6
- import { Badge as p, Button as m, Card as h, CardContent as g, Dialog as _, DialogContent as v, DialogDescription as y, DialogFooter as b, DialogHeader as x, DialogTitle as S, Input as C, Label as w, Spinner as T } from "@burdenoff/fe-libs/ui";
7
- import { Fragment as E, jsx as D, jsxs as O } from "react/jsx-runtime";
5
+ import { memo as n, useCallback as r, useEffect as i, useRef as a, useState as o } from "react";
6
+ import { ArrowLeft as s, Check as c, FileJson as ee, Info as l, RefreshCw as u, Upload as d, XCircle as f } from "lucide-react";
7
+ import { useI18n as p } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
8
+ import { Badge as m, Button as h, Input as g, Label as _, ResponsiveDialog as v, ResponsiveDialogContent as te, ResponsiveDialogDescription as y, ResponsiveDialogFooter as b, ResponsiveDialogHeader as x, ResponsiveDialogTitle as S, Spinner as C } from "@burdenoff/fe-libs/ui";
9
+ import { Fragment as w, jsx as T, jsxs as E } from "react/jsx-runtime";
8
10
  //#region src/bigconsole/components/parser/ImportParserDialog.tsx
9
- var k = t(function({ isOpen: t, onClose: k, consoleId: A, onSuccess: j }) {
10
- let { t: M } = ee(), [N, P] = a("select"), [, F] = a(null), [I, L] = a(null), [R, z] = a(""), [B, V] = a(""), [H, U] = a(""), W = i(null), { loading: G, error: K, validationResult: q, importResult: J, validateImport: Y, importParser: X, extractParserId: te, clearState: Z } = e();
11
- r(() => {
12
- t && (P("select"), F(null), L(null), z(""), V(""), U(""), Z());
13
- }, [t, Z]);
14
- let ne = n(async (e) => {
11
+ var D = "flex flex-wrap items-center justify-between gap-x-2 gap-y-0.5", O = n(function({ isOpen: n, onClose: O, consoleId: k, onSuccess: A }) {
12
+ let { t: j } = p(), [M, N] = o("select"), [, P] = o(null), [F, I] = o(null), [L, R] = o(""), [z, B] = o(""), [V, H] = o(""), U = a(null), { loading: W, error: G, validationResult: K, importResult: q, validateImport: J, importParser: Y, extractParserId: X, clearState: Z } = t();
13
+ i(() => {
14
+ n && (N("select"), P(null), I(null), R(""), B(""), H(""), Z());
15
+ }, [n, Z]);
16
+ let ne = r(async (e) => {
15
17
  let t = e.target.files?.[0];
16
18
  if (!t) return;
17
19
  if (!t.name.endsWith(".json")) {
18
- alert(M("bigconsole.parsers.import.selectJsonFile", "Please select a JSON file"));
20
+ alert(j("bigconsole.parsers.import.selectJsonFile", "Please select a JSON file"));
19
21
  return;
20
22
  }
21
- F(t);
23
+ P(t);
22
24
  let n = new FileReader();
23
25
  n.onload = async (e) => {
24
26
  let t = e.target?.result;
25
- L(t);
26
- let n = Y(t);
27
- n.isValid && n.parserInfo ? (P("preview"), z(n.parserInfo.name || ""), V(n.parserInfo.inputSinkKey || ""), U(n.parserInfo.outputKey || "")) : P("preview");
27
+ I(t);
28
+ let n = J(t);
29
+ n.isValid && n.parserInfo ? (N("preview"), R(n.parserInfo.name || ""), B(n.parserInfo.inputSinkKey || ""), H(n.parserInfo.outputKey || "")) : N("preview");
28
30
  }, n.onerror = () => {
29
- alert(M("bigconsole.parsers.import.readFileFailed", "Failed to read file"));
31
+ alert(j("bigconsole.parsers.import.readFileFailed", "Failed to read file"));
30
32
  }, n.readAsText(t);
31
- }, [Y, M]), re = n((e) => {
33
+ }, [J, j]), re = r((e) => {
32
34
  e.preventDefault();
33
35
  let t = e.dataTransfer.files?.[0];
34
36
  if (t) {
35
37
  let e = new DataTransfer();
36
- e.items.add(t), W.current && (W.current.files = e.files, W.current.dispatchEvent(new Event("change", { bubbles: !0 })));
38
+ e.items.add(t), U.current && (U.current.files = e.files, U.current.dispatchEvent(new Event("change", { bubbles: !0 })));
37
39
  }
38
- }, []), ie = n(async () => {
39
- if (!I) return;
40
- P("importing");
41
- let e = await X(I, {
42
- consoleId: A,
43
- name: R.trim() || void 0,
44
- inputSinkKey: B.trim() || void 0,
45
- outputKey: H.trim() || void 0
40
+ }, []), ie = r(async () => {
41
+ if (!F) return;
42
+ N("importing");
43
+ let e = await Y(F, {
44
+ consoleId: k,
45
+ name: L.trim() || void 0,
46
+ inputSinkKey: z.trim() || void 0,
47
+ outputKey: V.trim() || void 0
46
48
  });
47
- e?.success && e.parser ? (P("complete"), j?.(e.parser.id, e.parser.name, e.originalUpdated ?? !1)) : P("preview");
49
+ e?.success && e.parser ? (N("complete"), A?.(e.parser.id, e.parser.name, e.originalUpdated ?? !1)) : N("preview");
48
50
  }, [
49
- I,
50
- A,
51
- R,
52
- B,
53
- H,
54
- X,
55
- j
56
- ]), Q = !G && N !== "importing", $ = I ? te(I) : null;
57
- return /* @__PURE__ */ D(_, {
58
- open: t,
59
- onOpenChange: (e) => !e && Q && k(),
60
- children: /* @__PURE__ */ O(v, {
51
+ F,
52
+ k,
53
+ L,
54
+ z,
55
+ V,
56
+ Y,
57
+ A
58
+ ]), Q = !W && M !== "importing", $ = F ? X(F) : null;
59
+ return /* @__PURE__ */ T(v, {
60
+ open: n,
61
+ onOpenChange: (e) => !e && Q && O(),
62
+ children: /* @__PURE__ */ E(te, {
61
63
  className: "sm:max-w-lg max-h-[85vh] flex flex-col",
62
64
  children: [
63
- /* @__PURE__ */ O(x, { children: [/* @__PURE__ */ O("div", {
65
+ /* @__PURE__ */ E(x, { children: [/* @__PURE__ */ E("div", {
64
66
  className: "flex items-center gap-3",
65
- children: [/* @__PURE__ */ D("div", {
66
- className: "flex size-10 items-center justify-center rounded-lg bg-action-primary-bg/10",
67
- children: /* @__PURE__ */ D(d, { className: "size-5 text-primary" })
68
- }), /* @__PURE__ */ D(S, { children: M("bigconsole.parsers.import.title", "Import Parser") })]
69
- }), /* @__PURE__ */ D(y, { children: M("bigconsole.parsers.import.description", "Upload a Parser export file to restore it into this workspace.") })] }),
70
- /* @__PURE__ */ O("div", {
67
+ children: [/* @__PURE__ */ T("div", {
68
+ className: "flex size-10 shrink-0 items-center justify-center rounded-lg bg-action-primary-bg/10",
69
+ children: /* @__PURE__ */ T(d, { className: "size-5 text-action-primary-bg" })
70
+ }), /* @__PURE__ */ T(S, { children: j("bigconsole.parsers.import.title", "Import Parser") })]
71
+ }), /* @__PURE__ */ T(y, { children: j("bigconsole.parsers.import.description", "Upload a Parser export file to restore it into this workspace.") })] }),
72
+ /* @__PURE__ */ E("div", {
71
73
  className: "flex-1 overflow-y-auto py-4 space-y-4",
72
74
  children: [
73
- N === "select" && /* @__PURE__ */ O("div", {
75
+ M === "select" && /* @__PURE__ */ E("div", {
74
76
  onDragOver: (e) => e.preventDefault(),
75
77
  onDrop: re,
76
- className: "border-2 border-dashed rounded-lg p-8 text-center hover:border-primary transition-colors",
78
+ className: "rounded-card border-2 border-dashed border-[var(--color-border-subtle)] bg-bg-sunken p-6 text-center hover:border-action-primary-bg motion-safe:transition-colors sm:p-8",
77
79
  children: [
78
- /* @__PURE__ */ D(c, { className: "size-12 mx-auto text-text-secondary mb-4" }),
79
- /* @__PURE__ */ D("p", {
80
+ /* @__PURE__ */ T(ee, { className: "size-12 mx-auto text-text-secondary mb-4" }),
81
+ /* @__PURE__ */ T("p", {
80
82
  className: "text-sm mb-2",
81
- children: M("bigconsole.parsers.import.dropzoneTitle", "Drag and drop a parser export file here")
83
+ children: j("bigconsole.parsers.import.dropzoneTitle", "Drag and drop a parser export file here")
82
84
  }),
83
- /* @__PURE__ */ D("p", {
85
+ /* @__PURE__ */ T("p", {
84
86
  className: "text-xs text-text-secondary mb-4",
85
- children: M("bigconsole.parsers.import.or", "or")
87
+ children: j("bigconsole.parsers.import.or", "or")
86
88
  }),
87
- /* @__PURE__ */ D("input", {
88
- ref: W,
89
+ /* @__PURE__ */ T("input", {
90
+ ref: U,
89
91
  type: "file",
90
92
  accept: ".json",
91
93
  onChange: ne,
92
94
  className: "hidden"
93
95
  }),
94
- /* @__PURE__ */ D(m, {
95
- onClick: () => W.current?.click(),
96
- disabled: G,
97
- children: M("bigconsole.parsers.import.browseFiles", "Browse Files")
96
+ /* @__PURE__ */ T(h, {
97
+ onClick: () => U.current?.click(),
98
+ disabled: W,
99
+ children: j("bigconsole.parsers.import.browseFiles", "Browse Files")
98
100
  }),
99
- /* @__PURE__ */ D("p", {
101
+ /* @__PURE__ */ T("p", {
100
102
  className: "text-xs text-text-secondary mt-4",
101
- children: M("bigconsole.parsers.import.supportedHint", "Only .json files exported from BigConsole are supported")
103
+ children: j("bigconsole.parsers.import.supportedHint", "Only .json files exported from BigConsole are supported")
102
104
  })
103
105
  ]
104
106
  }),
105
- (N === "preview" || N === "importing") && q && /* @__PURE__ */ O(E, { children: [
106
- q.parserInfo && /* @__PURE__ */ D(h, { children: /* @__PURE__ */ O(g, {
107
- className: "p-4 space-y-2",
107
+ (M === "preview" || M === "importing") && K && /* @__PURE__ */ E(w, { children: [
108
+ K.parserInfo && /* @__PURE__ */ E(e, {
109
+ emphasis: "muted",
110
+ padding: "compact",
111
+ headingLevel: 3,
112
+ title: "Parser in this file",
113
+ bodyClassName: "space-y-2",
114
+ "data-testid": "import-parser-summary",
108
115
  children: [
109
- /* @__PURE__ */ O("div", {
110
- className: "flex items-center justify-between",
111
- children: [/* @__PURE__ */ D("span", {
116
+ /* @__PURE__ */ E("div", {
117
+ className: D,
118
+ children: [/* @__PURE__ */ T("span", {
112
119
  className: "text-sm text-text-secondary",
113
- children: M("bigconsole.parsers.import.fieldParser", "Parser")
114
- }), /* @__PURE__ */ D("span", {
115
- className: "text-sm font-medium",
116
- children: q.parserInfo.name
120
+ children: j("bigconsole.parsers.import.fieldParser", "Parser")
121
+ }), /* @__PURE__ */ T("span", {
122
+ className: "min-w-0 break-words text-sm font-medium text-text-primary",
123
+ children: K.parserInfo.name
117
124
  })]
118
125
  }),
119
- /* @__PURE__ */ O("div", {
120
- className: "flex items-center justify-between",
121
- children: [/* @__PURE__ */ D("span", {
126
+ /* @__PURE__ */ E("div", {
127
+ className: D,
128
+ children: [/* @__PURE__ */ T("span", {
122
129
  className: "text-sm text-text-secondary",
123
- children: M("bigconsole.parsers.import.fieldType", "Type")
124
- }), /* @__PURE__ */ D(p, {
130
+ children: j("bigconsole.parsers.import.fieldType", "Type")
131
+ }), /* @__PURE__ */ T(m, {
125
132
  variant: "secondary",
126
- children: q.parserInfo.type
133
+ children: K.parserInfo.type
127
134
  })]
128
135
  }),
129
- /* @__PURE__ */ O("div", {
130
- className: "flex items-center justify-between",
131
- children: [/* @__PURE__ */ D("span", {
136
+ /* @__PURE__ */ E("div", {
137
+ className: D,
138
+ children: [/* @__PURE__ */ T("span", {
132
139
  className: "text-sm text-text-secondary",
133
- children: M("bigconsole.parsers.import.fieldInputSink", "Input Sink")
134
- }), /* @__PURE__ */ D("span", {
135
- className: "text-xs font-mono",
136
- children: q.parserInfo.inputSinkKey
140
+ children: j("bigconsole.parsers.import.fieldInputSink", "Input Sink")
141
+ }), /* @__PURE__ */ T("span", {
142
+ className: "min-w-0 break-all font-mono text-xs text-text-primary",
143
+ children: K.parserInfo.inputSinkKey
137
144
  })]
138
145
  }),
139
- /* @__PURE__ */ O("div", {
140
- className: "flex items-center justify-between",
141
- children: [/* @__PURE__ */ D("span", {
146
+ /* @__PURE__ */ E("div", {
147
+ className: D,
148
+ children: [/* @__PURE__ */ T("span", {
142
149
  className: "text-sm text-text-secondary",
143
- children: M("bigconsole.parsers.import.fieldOutputKey", "Output Key")
144
- }), /* @__PURE__ */ D("span", {
145
- className: "text-xs font-mono",
146
- children: q.parserInfo.outputKey
150
+ children: j("bigconsole.parsers.import.fieldOutputKey", "Output Key")
151
+ }), /* @__PURE__ */ T("span", {
152
+ className: "min-w-0 break-all font-mono text-xs text-text-primary",
153
+ children: K.parserInfo.outputKey
147
154
  })]
148
155
  }),
149
- q.parserInfo.exportedFrom && /* @__PURE__ */ O("div", {
150
- className: "flex items-center justify-between",
151
- children: [/* @__PURE__ */ D("span", {
156
+ K.parserInfo.exportedFrom && /* @__PURE__ */ E("div", {
157
+ className: D,
158
+ children: [/* @__PURE__ */ T("span", {
152
159
  className: "text-sm text-text-secondary",
153
- children: M("bigconsole.parsers.import.fieldSourceId", "Source ID")
154
- }), /* @__PURE__ */ D("span", {
155
- className: "text-xs text-text-secondary font-mono truncate max-w-[180px]",
156
- children: q.parserInfo.exportedFrom
160
+ children: j("bigconsole.parsers.import.fieldSourceId", "Source ID")
161
+ }), /* @__PURE__ */ T("span", {
162
+ className: "min-w-0 max-w-full truncate font-mono text-xs text-text-secondary sm:max-w-[180px]",
163
+ children: K.parserInfo.exportedFrom
157
164
  })]
158
165
  }),
159
- /* @__PURE__ */ O("div", {
160
- className: "flex items-center justify-between",
161
- children: [/* @__PURE__ */ D("span", {
166
+ /* @__PURE__ */ E("div", {
167
+ className: D,
168
+ children: [/* @__PURE__ */ T("span", {
162
169
  className: "text-sm text-text-secondary",
163
- children: M("bigconsole.parsers.import.fieldSchemaVersion", "Schema Version")
164
- }), /* @__PURE__ */ D("span", {
170
+ children: j("bigconsole.parsers.import.fieldSchemaVersion", "Schema Version")
171
+ }), /* @__PURE__ */ T("span", {
165
172
  className: "text-xs text-text-secondary",
166
- children: q.parserInfo.schemaVersion
173
+ children: K.parserInfo.schemaVersion
167
174
  })]
168
175
  })
169
176
  ]
170
- }) }),
171
- q.errors.length > 0 && /* @__PURE__ */ D(h, {
172
- className: "border-status-error-border/50 bg-status-error-bg/5",
173
- children: /* @__PURE__ */ O(g, {
174
- className: "p-3",
175
- children: [/* @__PURE__ */ O("div", {
176
- className: "flex items-center gap-2 mb-2",
177
- children: [/* @__PURE__ */ D(f, { className: "size-4 text-status-error-text" }), /* @__PURE__ */ D("span", {
178
- className: "text-sm font-medium text-status-error-text",
179
- children: M("bigconsole.parsers.import.errorsCount", "Errors ({{count}})", { count: q.errors.length })
180
- })]
181
- }), /* @__PURE__ */ D("ul", {
182
- className: "text-xs text-status-error-text space-y-1",
183
- children: q.errors.map((e, t) => /* @__PURE__ */ O("li", { children: [
184
- /* @__PURE__ */ O("span", {
177
+ }),
178
+ K.errors.length > 0 && /* @__PURE__ */ T(e, {
179
+ tone: "danger",
180
+ padding: "compact",
181
+ headingLevel: 3,
182
+ title: j("bigconsole.parsers.import.errorsCount", "Errors ({{count}})", { count: K.errors.length }),
183
+ icon: /* @__PURE__ */ T(f, { className: "size-4 text-[var(--color-status-error-text)]" }),
184
+ "data-testid": "import-validation-errors",
185
+ children: /* @__PURE__ */ T("ul", {
186
+ className: "space-y-1 text-xs text-status-error-text",
187
+ children: K.errors.map((e, t) => /* @__PURE__ */ E("li", {
188
+ className: "break-words",
189
+ children: [
190
+ /* @__PURE__ */ E("span", {
185
191
  className: "font-mono",
186
192
  children: [
187
193
  "[",
@@ -191,213 +197,167 @@ var k = t(function({ isOpen: t, onClose: k, consoleId: A, onSuccess: j }) {
191
197
  }),
192
198
  " ",
193
199
  e.message
194
- ] }, t))
195
- })]
200
+ ]
201
+ }, t))
196
202
  })
197
203
  }),
198
- q.isValid && /* @__PURE__ */ O("div", {
199
- className: "space-y-4",
204
+ K.isValid && /* @__PURE__ */ E(e, {
205
+ headingLevel: 3,
206
+ title: j("bigconsole.parsers.import.optionsHeading", "Import Options"),
207
+ description: "Override the imported names before creating the parser.",
208
+ bodyClassName: "space-y-4",
209
+ "data-testid": "import-parser-options",
200
210
  children: [
201
- /* @__PURE__ */ D("p", {
202
- className: "text-sm font-medium",
203
- children: M("bigconsole.parsers.import.optionsHeading", "Import Options")
204
- }),
205
- /* @__PURE__ */ D(h, {
206
- className: "border-blue-500/50 bg-blue-500/5",
207
- children: /* @__PURE__ */ D(g, {
208
- className: "p-3",
209
- children: /* @__PURE__ */ O("div", {
210
- className: "flex items-start gap-2",
211
- children: [/* @__PURE__ */ D(l, { className: "size-4 text-blue-600 mt-0.5 shrink-0" }), /* @__PURE__ */ D("div", {
212
- className: "text-xs text-blue-700 dark:text-blue-400",
213
- children: $ ? /* @__PURE__ */ O(E, { children: [
214
- /* @__PURE__ */ D("p", {
215
- className: "font-medium mb-1",
216
- children: M("bigconsole.parsers.import.checkExistingTitle", "Import will check for existing parser")
217
- }),
218
- /* @__PURE__ */ O("p", { children: [
219
- M("bigconsole.parsers.import.ifOriginalExistsPrefix", "If the original parser (ID:"),
220
- " ",
221
- /* @__PURE__ */ O("code", {
222
- className: "font-mono bg-blue-200/50 px-1 rounded",
223
- children: [$.slice(0, 8), "..."]
224
- }),
225
- M("bigconsole.parsers.import.ifOriginalExistsSuffix", ") exists:")
226
- ] }),
227
- /* @__PURE__ */ O("ul", {
228
- className: "list-disc list-inside mt-1 space-y-0.5",
229
- children: [/* @__PURE__ */ D("li", { children: M("bigconsole.parsers.import.withChanges", "With changes → Update the existing parser") }), /* @__PURE__ */ D("li", { children: M("bigconsole.parsers.import.noChanges", "No changes → Show \"already exists\" message") })]
230
- }),
231
- /* @__PURE__ */ D("p", {
232
- className: "mt-1",
233
- children: M("bigconsole.parsers.import.ifOriginalMissing", "If original doesn't exist → Create a new parser")
234
- })
235
- ] }) : /* @__PURE__ */ O(E, { children: [/* @__PURE__ */ D("p", {
236
- className: "font-medium mb-1",
237
- children: M("bigconsole.parsers.import.newParserTitle", "A new parser will be created")
238
- }), /* @__PURE__ */ D("p", { children: M("bigconsole.parsers.import.newParserBody", "Import as a new parser with the specified configuration.") })] })
239
- })]
240
- })
211
+ /* @__PURE__ */ T(e, {
212
+ tone: "info",
213
+ padding: "compact",
214
+ headingLevel: 4,
215
+ title: $ ? j("bigconsole.parsers.import.checkExistingTitle", "Import will check for existing parser") : j("bigconsole.parsers.import.newParserTitle", "A new parser will be created"),
216
+ icon: /* @__PURE__ */ T(l, { className: "size-4 text-[var(--color-status-info-text)]" }),
217
+ children: /* @__PURE__ */ T("div", {
218
+ className: "text-xs text-text-secondary",
219
+ children: $ ? /* @__PURE__ */ E(w, { children: [
220
+ /* @__PURE__ */ E("p", { children: [
221
+ j("bigconsole.parsers.import.ifOriginalExistsPrefix", "If the original parser (ID:"),
222
+ " ",
223
+ /* @__PURE__ */ E("code", {
224
+ className: "rounded bg-bg-sunken px-1 font-mono",
225
+ children: [$.slice(0, 8), "..."]
226
+ }),
227
+ j("bigconsole.parsers.import.ifOriginalExistsSuffix", ") exists:")
228
+ ] }),
229
+ /* @__PURE__ */ E("ul", {
230
+ className: "list-disc list-inside mt-1 space-y-0.5",
231
+ children: [/* @__PURE__ */ T("li", { children: j("bigconsole.parsers.import.withChanges", "With changes → Update the existing parser") }), /* @__PURE__ */ T("li", { children: j("bigconsole.parsers.import.noChanges", "No changes → Show \"already exists\" message") })]
232
+ }),
233
+ /* @__PURE__ */ T("p", {
234
+ className: "mt-1",
235
+ children: j("bigconsole.parsers.import.ifOriginalMissing", "If original doesn't exist → Create a new parser")
236
+ })
237
+ ] }) : /* @__PURE__ */ T("p", { children: j("bigconsole.parsers.import.newParserBody", "Import as a new parser with the specified configuration.") })
241
238
  })
242
239
  }),
243
- /* @__PURE__ */ O("div", {
240
+ /* @__PURE__ */ E("div", {
244
241
  className: "space-y-2",
245
- children: [/* @__PURE__ */ D(w, {
242
+ children: [/* @__PURE__ */ T(_, {
246
243
  htmlFor: "import-name",
247
- children: M("bigconsole.parsers.import.parserNameLabel", "Parser Name")
248
- }), /* @__PURE__ */ D(C, {
244
+ children: j("bigconsole.parsers.import.parserNameLabel", "Parser Name")
245
+ }), /* @__PURE__ */ T(g, {
249
246
  id: "import-name",
250
247
  type: "text",
251
- value: R,
252
- onChange: (e) => z(e.target.value),
253
- placeholder: q.parserInfo?.name || M("bigconsole.parsers.import.parserNamePlaceholder", "Parser name"),
254
- disabled: N === "importing"
248
+ value: L,
249
+ onChange: (e) => R(e.target.value),
250
+ placeholder: K.parserInfo?.name || j("bigconsole.parsers.import.parserNamePlaceholder", "Parser name"),
251
+ disabled: M === "importing"
255
252
  })]
256
253
  }),
257
- /* @__PURE__ */ O("div", {
254
+ /* @__PURE__ */ E("div", {
258
255
  className: "space-y-2",
259
256
  children: [
260
- /* @__PURE__ */ D(w, {
257
+ /* @__PURE__ */ T(_, {
261
258
  htmlFor: "import-input-sink",
262
- children: M("bigconsole.parsers.import.inputSinkKeyLabel", "Input Sink Key")
259
+ children: j("bigconsole.parsers.import.inputSinkKeyLabel", "Input Sink Key")
263
260
  }),
264
- /* @__PURE__ */ D(C, {
261
+ /* @__PURE__ */ T(g, {
265
262
  id: "import-input-sink",
266
263
  type: "text",
267
- value: B,
268
- onChange: (e) => V(e.target.value),
269
- placeholder: q.parserInfo?.inputSinkKey || M("bigconsole.parsers.import.inputSinkKeyPlaceholder", "Input sink key"),
270
- disabled: N === "importing"
264
+ value: z,
265
+ onChange: (e) => B(e.target.value),
266
+ placeholder: K.parserInfo?.inputSinkKey || j("bigconsole.parsers.import.inputSinkKeyPlaceholder", "Input sink key"),
267
+ disabled: M === "importing"
271
268
  }),
272
- /* @__PURE__ */ D("p", {
269
+ /* @__PURE__ */ T("p", {
273
270
  className: "text-xs text-text-secondary",
274
- children: M("bigconsole.parsers.import.inputSinkKeyHelp", "The DataSink key to read input data from.")
271
+ children: j("bigconsole.parsers.import.inputSinkKeyHelp", "The DataSink key to read input data from.")
275
272
  })
276
273
  ]
277
274
  }),
278
- /* @__PURE__ */ O("div", {
275
+ /* @__PURE__ */ E("div", {
279
276
  className: "space-y-2",
280
277
  children: [
281
- /* @__PURE__ */ D(w, {
278
+ /* @__PURE__ */ T(_, {
282
279
  htmlFor: "import-output-key",
283
- children: M("bigconsole.parsers.import.outputKeyLabel", "Output Key")
280
+ children: j("bigconsole.parsers.import.outputKeyLabel", "Output Key")
284
281
  }),
285
- /* @__PURE__ */ D(C, {
282
+ /* @__PURE__ */ T(g, {
286
283
  id: "import-output-key",
287
284
  type: "text",
288
- value: H,
289
- onChange: (e) => U(e.target.value),
290
- placeholder: q.parserInfo?.outputKey || M("bigconsole.parsers.import.outputKeyPlaceholder", "Output key"),
291
- disabled: N === "importing"
285
+ value: V,
286
+ onChange: (e) => H(e.target.value),
287
+ placeholder: K.parserInfo?.outputKey || j("bigconsole.parsers.import.outputKeyPlaceholder", "Output key"),
288
+ disabled: M === "importing"
292
289
  }),
293
- /* @__PURE__ */ D("p", {
290
+ /* @__PURE__ */ T("p", {
294
291
  className: "text-xs text-text-secondary",
295
- children: M("bigconsole.parsers.import.outputKeyHelp", "The key to store parsed output data under.")
292
+ children: j("bigconsole.parsers.import.outputKeyHelp", "The key to store parsed output data under.")
296
293
  })
297
294
  ]
298
295
  })
299
296
  ]
300
297
  })
301
298
  ] }),
302
- N === "complete" && J?.success && /* @__PURE__ */ O("div", {
303
- className: "text-center py-6",
304
- children: [
305
- J.alreadyExists && /* @__PURE__ */ O(E, { children: [
306
- /* @__PURE__ */ D("div", {
307
- className: "size-16 mx-auto mb-4 rounded-full bg-blue-100 dark:bg-blue-900/30 flex items-center justify-center",
308
- children: /* @__PURE__ */ D(l, { className: "size-8 text-blue-600" })
309
- }),
310
- /* @__PURE__ */ D("h3", {
311
- className: "text-lg font-medium mb-2",
312
- children: M("bigconsole.parsers.import.alreadyExistsTitle", "Parser Already Exists")
313
- }),
314
- /* @__PURE__ */ D("p", {
315
- className: "text-sm text-text-secondary mb-4",
316
- children: M("bigconsole.parsers.import.alreadyExistsBody", "Parser \"{{name}}\" already exists with the same data. No changes were made.", { name: J.parser?.name ?? "" })
317
- })
318
- ] }),
319
- J.originalUpdated && !J.alreadyExists && /* @__PURE__ */ O(E, { children: [
320
- /* @__PURE__ */ D("div", {
321
- className: "size-16 mx-auto mb-4 rounded-full bg-green-100 dark:bg-green-900/30 flex items-center justify-center",
322
- children: /* @__PURE__ */ D(u, { className: "size-8 text-green-600" })
323
- }),
324
- /* @__PURE__ */ D("h3", {
325
- className: "text-lg font-medium mb-2",
326
- children: M("bigconsole.parsers.import.updatedTitle", "Parser Updated!")
327
- }),
328
- /* @__PURE__ */ D("p", {
329
- className: "text-sm text-text-secondary mb-4",
330
- children: M("bigconsole.parsers.import.updatedBody", "Parser \"{{name}}\" has been updated with the imported data.", { name: J.parser?.name ?? "" })
331
- })
332
- ] }),
333
- !J.originalUpdated && !J.alreadyExists && /* @__PURE__ */ O(E, { children: [
334
- /* @__PURE__ */ D("div", {
335
- className: "size-16 mx-auto mb-4 rounded-full bg-green-100 dark:bg-green-900/30 flex items-center justify-center",
336
- children: /* @__PURE__ */ D(s, { className: "size-8 text-green-600" })
337
- }),
338
- /* @__PURE__ */ D("h3", {
339
- className: "text-lg font-medium mb-2",
340
- children: M("bigconsole.parsers.import.createdTitle", "Import Successful!")
341
- }),
342
- /* @__PURE__ */ D("p", {
343
- className: "text-sm text-text-secondary mb-4",
344
- children: M("bigconsole.parsers.import.createdBody", "Parser \"{{name}}\" has been created.", { name: J.parser?.name ?? "" })
345
- })
346
- ] })
347
- ]
299
+ M === "complete" && q?.success && /* @__PURE__ */ T(e, {
300
+ tone: q.alreadyExists ? "info" : "success",
301
+ headingLevel: 3,
302
+ title: q.alreadyExists ? j("bigconsole.parsers.import.alreadyExistsTitle", "Parser Already Exists") : q.originalUpdated ? j("bigconsole.parsers.import.updatedTitle", "Parser Updated!") : j("bigconsole.parsers.import.createdTitle", "Import Successful!"),
303
+ icon: q.alreadyExists ? /* @__PURE__ */ T(l, { className: "size-5 text-[var(--color-status-info-text)]" }) : q.originalUpdated ? /* @__PURE__ */ T(u, { className: "size-5 text-[var(--color-status-success-text)]" }) : /* @__PURE__ */ T(c, { className: "size-5 text-[var(--color-status-success-text)]" }),
304
+ description: q.alreadyExists ? j("bigconsole.parsers.import.alreadyExistsBody", "Parser \"{{name}}\" already exists with the same data. No changes were made.", { name: q.parser?.name ?? "" }) : q.originalUpdated ? j("bigconsole.parsers.import.updatedBody", "Parser \"{{name}}\" has been updated with the imported data.", { name: q.parser?.name ?? "" }) : j("bigconsole.parsers.import.createdBody", "Parser \"{{name}}\" has been created.", { name: q.parser?.name ?? "" }),
305
+ "data-testid": "import-parser-outcome"
348
306
  }),
349
- K && /* @__PURE__ */ D(h, {
350
- className: "border-status-error-border/50 bg-status-error-bg/5",
351
- children: /* @__PURE__ */ D(g, {
352
- className: "p-3",
353
- children: /* @__PURE__ */ D("p", {
354
- className: "text-sm text-status-error-text",
355
- children: K.message
356
- })
307
+ G && /* @__PURE__ */ T(e, {
308
+ tone: "danger",
309
+ padding: "compact",
310
+ headingLevel: 3,
311
+ title: "Import failed",
312
+ "data-testid": "import-parser-error",
313
+ children: /* @__PURE__ */ T("p", {
314
+ className: "break-words text-sm text-status-error-text",
315
+ children: G.message
357
316
  })
358
317
  }),
359
- J && !J.success && J.errorMessage && /* @__PURE__ */ D(h, {
360
- className: "border-status-error-border/50 bg-status-error-bg/5",
361
- children: /* @__PURE__ */ D(g, {
362
- className: "p-3",
363
- children: /* @__PURE__ */ D("p", {
364
- className: "text-sm text-status-error-text",
365
- children: J.errorMessage
366
- })
318
+ q && !q.success && q.errorMessage && /* @__PURE__ */ T(e, {
319
+ tone: "danger",
320
+ padding: "compact",
321
+ headingLevel: 3,
322
+ title: "Import failed",
323
+ "data-testid": "import-parser-result-error",
324
+ children: /* @__PURE__ */ T("p", {
325
+ className: "break-words text-sm text-status-error-text",
326
+ children: q.errorMessage
367
327
  })
368
328
  })
369
329
  ]
370
330
  }),
371
- /* @__PURE__ */ O(b, {
372
- className: "flex-row justify-between sm:justify-between",
373
- children: [/* @__PURE__ */ D("div", { children: N === "preview" && /* @__PURE__ */ O(m, {
331
+ /* @__PURE__ */ E(b, {
332
+ className: "flex flex-col-reverse gap-2 sm:flex-row sm:justify-between",
333
+ children: [/* @__PURE__ */ T("div", { children: M === "preview" && /* @__PURE__ */ E(h, {
374
334
  variant: "ghost",
375
335
  onClick: () => {
376
- P("select"), F(null), L(null), Z();
336
+ N("select"), P(null), I(null), Z();
377
337
  },
378
- disabled: G,
379
- children: [/* @__PURE__ */ D(o, { className: "size-4" }), M("bigconsole.parsers.import.back", "Back")]
380
- }) }), /* @__PURE__ */ O("div", {
381
- className: "flex items-center gap-2",
338
+ disabled: W,
339
+ children: [/* @__PURE__ */ T(s, { className: "size-4" }), j("bigconsole.parsers.import.back", "Back")]
340
+ }) }), /* @__PURE__ */ E("div", {
341
+ className: "flex flex-wrap items-center gap-2",
382
342
  children: [
383
- N !== "complete" && /* @__PURE__ */ D(m, {
343
+ M !== "complete" && /* @__PURE__ */ T(h, {
384
344
  variant: "outline",
385
- onClick: k,
345
+ onClick: O,
386
346
  disabled: !Q,
387
- children: M("bigconsole.parsers.import.cancel", "Cancel")
347
+ children: j("bigconsole.parsers.import.cancel", "Cancel")
388
348
  }),
389
- N === "preview" && q?.isValid && /* @__PURE__ */ O(m, {
349
+ M === "preview" && K?.isValid && /* @__PURE__ */ E(h, {
390
350
  onClick: ie,
391
- disabled: G,
392
- children: [/* @__PURE__ */ D(d, { className: "size-4" }), M("bigconsole.parsers.import.importButton", "Import Parser")]
351
+ disabled: W,
352
+ children: [/* @__PURE__ */ T(d, { className: "size-4" }), j("bigconsole.parsers.import.importButton", "Import Parser")]
393
353
  }),
394
- N === "importing" && /* @__PURE__ */ O("div", {
354
+ M === "importing" && /* @__PURE__ */ E("div", {
395
355
  className: "flex items-center gap-2 text-sm text-text-secondary",
396
- children: [/* @__PURE__ */ D(T, { className: "size-4" }), M("bigconsole.parsers.import.importing", "Importing...")]
356
+ children: [/* @__PURE__ */ T(C, { className: "size-4" }), j("bigconsole.parsers.import.importing", "Importing...")]
397
357
  }),
398
- N === "complete" && /* @__PURE__ */ D(m, {
399
- onClick: k,
400
- children: M("bigconsole.parsers.import.done", "Done")
358
+ M === "complete" && /* @__PURE__ */ T(h, {
359
+ onClick: O,
360
+ children: j("bigconsole.parsers.import.done", "Done")
401
361
  })
402
362
  ]
403
363
  })]
@@ -407,6 +367,6 @@ var k = t(function({ isOpen: t, onClose: k, consoleId: A, onSuccess: j }) {
407
367
  });
408
368
  });
409
369
  //#endregion
410
- export { k as default };
370
+ export { O as default };
411
371
 
412
372
  //# sourceMappingURL=ImportParserDialog.js.map