@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.
- package/dist/bigconsole/components/DrilldownDashboardRenderer.js +118 -106
- package/dist/bigconsole/components/DrilldownDashboardRenderer.js.map +1 -1
- package/dist/bigconsole/components/DrilldownModal.js +54 -50
- package/dist/bigconsole/components/DrilldownModal.js.map +1 -1
- package/dist/bigconsole/components/builder/BuilderCanvas.js +2 -2
- package/dist/bigconsole/components/builder/BuilderCanvas.js.map +1 -1
- package/dist/bigconsole/components/builder/BuilderTopbar.js +3 -3
- package/dist/bigconsole/components/builder/BuilderTopbar.js.map +1 -1
- package/dist/bigconsole/components/builder/inspector/AdvancedSection.js +24 -25
- package/dist/bigconsole/components/builder/inspector/AdvancedSection.js.map +1 -1
- package/dist/bigconsole/components/builder/inspector/AppearanceSection.js +40 -29
- package/dist/bigconsole/components/builder/inspector/AppearanceSection.js.map +1 -1
- package/dist/bigconsole/components/builder/inspector/DataBindingSection.js +135 -97
- package/dist/bigconsole/components/builder/inspector/DataBindingSection.js.map +1 -1
- package/dist/bigconsole/components/builder/inspector/GeneralSection.js +58 -44
- package/dist/bigconsole/components/builder/inspector/GeneralSection.js.map +1 -1
- package/dist/bigconsole/components/common/Section.js +70 -0
- package/dist/bigconsole/components/common/Section.js.map +1 -0
- package/dist/bigconsole/components/common/index.js +2 -0
- package/dist/bigconsole/components/common/sectionStyles.js +42 -0
- package/dist/bigconsole/components/common/sectionStyles.js.map +1 -0
- package/dist/bigconsole/components/dashboard/CreateDashboardDialog.js +209 -193
- package/dist/bigconsole/components/dashboard/CreateDashboardDialog.js.map +1 -1
- package/dist/bigconsole/components/dashboard/DashboardCanvas.js +213 -231
- package/dist/bigconsole/components/dashboard/DashboardCanvas.js.map +1 -1
- package/dist/bigconsole/components/dashboard/DashboardGrid.js +12 -18
- package/dist/bigconsole/components/dashboard/DashboardGrid.js.map +1 -1
- package/dist/bigconsole/components/dashboard/DashboardToolbar.js +109 -102
- package/dist/bigconsole/components/dashboard/DashboardToolbar.js.map +1 -1
- package/dist/bigconsole/components/dashboard/DrilldownBreadcrumb.js +81 -70
- package/dist/bigconsole/components/dashboard/DrilldownBreadcrumb.js.map +1 -1
- package/dist/bigconsole/components/dashboard/ExportDashboardDialog.js +125 -159
- package/dist/bigconsole/components/dashboard/ExportDashboardDialog.js.map +1 -1
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterChip.js +25 -23
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterChip.js.map +1 -1
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterEditor.js +3 -3
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterEditor.js.map +1 -1
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterPresetSelector.js +5 -3
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterPresetSelector.js.map +1 -1
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/GlobalFiltersBar.js +170 -284
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/GlobalFiltersBar.js.map +1 -1
- package/dist/bigconsole/components/dashboard/ImportDashboardDialog.js +147 -151
- package/dist/bigconsole/components/dashboard/ImportDashboardDialog.js.map +1 -1
- package/dist/bigconsole/components/dashboard/LiveBoardBanner.js +45 -53
- package/dist/bigconsole/components/dashboard/LiveBoardBanner.js.map +1 -1
- package/dist/bigconsole/components/dashboard/PageTabsManager/PageTabsManager.js +157 -148
- package/dist/bigconsole/components/dashboard/PageTabsManager/PageTabsManager.js.map +1 -1
- package/dist/bigconsole/components/dashboard/SavedViewsDropdown/SavedViewsDropdown.js +17 -8
- package/dist/bigconsole/components/dashboard/SavedViewsDropdown/SavedViewsDropdown.js.map +1 -1
- package/dist/bigconsole/components/dashboard/ShareDialog/ShareDialog.js +101 -95
- package/dist/bigconsole/components/dashboard/ShareDialog/ShareDialog.js.map +1 -1
- package/dist/bigconsole/components/dashboard/StoreTemplatePicker.js +20 -18
- package/dist/bigconsole/components/dashboard/StoreTemplatePicker.js.map +1 -1
- package/dist/bigconsole/components/dashboard/TemplateSetupBanner.js +26 -58
- package/dist/bigconsole/components/dashboard/TemplateSetupBanner.js.map +1 -1
- package/dist/bigconsole/components/dashboard/WidgetPalette.js +307 -231
- package/dist/bigconsole/components/dashboard/WidgetPalette.js.map +1 -1
- package/dist/bigconsole/components/datasink/CacheTTLSelector.js +29 -29
- package/dist/bigconsole/components/datasink/CacheTTLSelector.js.map +1 -1
- package/dist/bigconsole/components/datasink/DataSinkCard.js +78 -79
- package/dist/bigconsole/components/datasink/DataSinkCard.js.map +1 -1
- package/dist/bigconsole/components/datasink/DataSinkDataViewer.js +33 -34
- package/dist/bigconsole/components/datasink/DataSinkDataViewer.js.map +1 -1
- package/dist/bigconsole/components/datasink/DataSinkDeleteDialog.js +79 -56
- package/dist/bigconsole/components/datasink/DataSinkDeleteDialog.js.map +1 -1
- package/dist/bigconsole/components/datasink/DataSinkRefreshDialog.js +75 -65
- package/dist/bigconsole/components/datasink/DataSinkRefreshDialog.js.map +1 -1
- package/dist/bigconsole/components/datasink/DataSinkStatusBadge.js +1 -1
- package/dist/bigconsole/components/datasink/DataSinkStatusBadge.js.map +1 -1
- package/dist/bigconsole/components/datasink/DataSinkTableViewer.js +20 -19
- package/dist/bigconsole/components/datasink/DataSinkTableViewer.js.map +1 -1
- package/dist/bigconsole/components/datasink/ExportDataSinkDialog.js +127 -171
- package/dist/bigconsole/components/datasink/ExportDataSinkDialog.js.map +1 -1
- package/dist/bigconsole/components/datasink/ImportDataSinkDialog.js +263 -243
- package/dist/bigconsole/components/datasink/ImportDataSinkDialog.js.map +1 -1
- package/dist/bigconsole/components/datasink/LinkedParsersPanel.js +65 -66
- package/dist/bigconsole/components/datasink/LinkedParsersPanel.js.map +1 -1
- package/dist/bigconsole/components/datasink/LinkedWorkflowsPanel.js +121 -127
- package/dist/bigconsole/components/datasink/LinkedWorkflowsPanel.js.map +1 -1
- package/dist/bigconsole/components/datasink/RefreshTypeSelector.js +33 -26
- package/dist/bigconsole/components/datasink/RefreshTypeSelector.js.map +1 -1
- package/dist/bigconsole/components/datasink/SetupStateBadge.js +3 -3
- package/dist/bigconsole/components/datasink/SetupStateBadge.js.map +1 -1
- package/dist/bigconsole/components/datasink/WorkflowStatusPanel.js +95 -95
- package/dist/bigconsole/components/datasink/WorkflowStatusPanel.js.map +1 -1
- package/dist/bigconsole/components/parser/DataSinkSelector.js +154 -123
- package/dist/bigconsole/components/parser/DataSinkSelector.js.map +1 -1
- package/dist/bigconsole/components/parser/ExpressionEditor.js +3 -3
- package/dist/bigconsole/components/parser/ExpressionEditor.js.map +1 -1
- package/dist/bigconsole/components/parser/ImportParserDialog.js +235 -275
- package/dist/bigconsole/components/parser/ImportParserDialog.js.map +1 -1
- package/dist/bigconsole/components/parser/ParserCard.js +133 -114
- package/dist/bigconsole/components/parser/ParserCard.js.map +1 -1
- package/dist/bigconsole/components/parser/ParserSelector.js +191 -174
- package/dist/bigconsole/components/parser/ParserSelector.js.map +1 -1
- package/dist/bigconsole/components/parser/ParserStatusBadge.js +2 -2
- package/dist/bigconsole/components/parser/ParserStatusBadge.js.map +1 -1
- package/dist/bigconsole/components/parser/ParserTypeBadge.js +4 -4
- package/dist/bigconsole/components/parser/ParserTypeBadge.js.map +1 -1
- package/dist/bigconsole/components/pipeline/PipelineCard.js +134 -89
- package/dist/bigconsole/components/pipeline/PipelineCard.js.map +1 -1
- package/dist/bigconsole/components/pipeline/PipelineDeleteDialog.js +77 -64
- package/dist/bigconsole/components/pipeline/PipelineDeleteDialog.js.map +1 -1
- package/dist/bigconsole/components/pipeline/PipelineStatusBadge.js +7 -10
- package/dist/bigconsole/components/pipeline/PipelineStatusBadge.js.map +1 -1
- package/dist/bigconsole/components/preview/AiPreviewContent.js +31 -32
- package/dist/bigconsole/components/preview/AiPreviewContent.js.map +1 -1
- package/dist/bigconsole/components/preview/AiPreviewMiniPanel.js +152 -106
- package/dist/bigconsole/components/preview/AiPreviewMiniPanel.js.map +1 -1
- package/dist/bigconsole/components/preview/AiPreviewPanel.js +193 -152
- package/dist/bigconsole/components/preview/AiPreviewPanel.js.map +1 -1
- package/dist/bigconsole/components/preview/previewShared.js +41 -23
- package/dist/bigconsole/components/preview/previewShared.js.map +1 -1
- package/dist/bigconsole/components/widgets/ActionConfigDialog.js +342 -308
- package/dist/bigconsole/components/widgets/ActionConfigDialog.js.map +1 -1
- package/dist/bigconsole/components/widgets/DrilldownConfigPanel.js +262 -238
- package/dist/bigconsole/components/widgets/DrilldownConfigPanel.js.map +1 -1
- package/dist/bigconsole/components/widgets/PropertiesPanel.js +783 -867
- package/dist/bigconsole/components/widgets/PropertiesPanel.js.map +1 -1
- package/dist/bigconsole/components/widgets/WidgetErrorBoundary.js +7 -5
- package/dist/bigconsole/components/widgets/WidgetErrorBoundary.js.map +1 -1
- package/dist/bigconsole/components/widgets/WidgetHeader.js +7 -8
- package/dist/bigconsole/components/widgets/WidgetHeader.js.map +1 -1
- package/dist/bigconsole/components/widgets/WidgetRegistry.js +4 -4
- package/dist/bigconsole/components/widgets/WidgetRegistry.js.map +1 -1
- package/dist/bigconsole/components/widgets/WidgetWrapper.js +8 -7
- package/dist/bigconsole/components/widgets/WidgetWrapper.js.map +1 -1
- package/dist/bigconsole/components/widgets/adaptive-card/AdaptiveCardWidget.js +1 -1
- package/dist/bigconsole/components/widgets/adaptive-card/AdaptiveCardWidget.js.map +1 -1
- package/dist/bigconsole/components/widgets/calendar/CalendarWidget.js +2 -2
- package/dist/bigconsole/components/widgets/calendar/CalendarWidget.js.map +1 -1
- package/dist/bigconsole/components/widgets/chart/ChartConfig.js +11 -5
- package/dist/bigconsole/components/widgets/chart/ChartConfig.js.map +1 -1
- package/dist/bigconsole/components/widgets/comments/WidgetComments.js +19 -15
- package/dist/bigconsole/components/widgets/comments/WidgetComments.js.map +1 -1
- package/dist/bigconsole/components/widgets/event-logs/EventLogViewer.js +154 -102
- package/dist/bigconsole/components/widgets/event-logs/EventLogViewer.js.map +1 -1
- package/dist/bigconsole/components/widgets/gauge/CircularGauge.js +36 -32
- package/dist/bigconsole/components/widgets/gauge/CircularGauge.js.map +1 -1
- package/dist/bigconsole/components/widgets/gauge/GaugeConfig.js +85 -60
- package/dist/bigconsole/components/widgets/gauge/GaugeConfig.js.map +1 -1
- package/dist/bigconsole/components/widgets/gauge/GaugeWidget.js +64 -35
- package/dist/bigconsole/components/widgets/gauge/GaugeWidget.js.map +1 -1
- package/dist/bigconsole/components/widgets/gauge/LinearGauge.js +46 -45
- package/dist/bigconsole/components/widgets/gauge/LinearGauge.js.map +1 -1
- package/dist/bigconsole/components/widgets/heatmap/HeatmapConfig.js +35 -24
- package/dist/bigconsole/components/widgets/heatmap/HeatmapConfig.js.map +1 -1
- package/dist/bigconsole/components/widgets/iframe-widget/IframeWidget.js +2 -2
- package/dist/bigconsole/components/widgets/iframe-widget/IframeWidget.js.map +1 -1
- package/dist/bigconsole/components/widgets/kanban/KanbanWidget.js +4 -4
- package/dist/bigconsole/components/widgets/kanban/KanbanWidget.js.map +1 -1
- package/dist/bigconsole/components/widgets/kpi-comparison/KPIComparisonWidget.js +153 -90
- package/dist/bigconsole/components/widgets/kpi-comparison/KPIComparisonWidget.js.map +1 -1
- package/dist/bigconsole/components/widgets/list/ListConfig.js +8 -2
- package/dist/bigconsole/components/widgets/list/ListConfig.js.map +1 -1
- package/dist/bigconsole/components/widgets/list/ListItem.js +1 -1
- package/dist/bigconsole/components/widgets/list/ListItem.js.map +1 -1
- package/dist/bigconsole/components/widgets/map-widget/MapWidget.js +1 -1
- package/dist/bigconsole/components/widgets/map-widget/MapWidget.js.map +1 -1
- package/dist/bigconsole/components/widgets/metric-card/MetricCardConfig.js +14 -4
- package/dist/bigconsole/components/widgets/metric-card/MetricCardConfig.js.map +1 -1
- package/dist/bigconsole/components/widgets/metric-card/MetricCardWidget.js +112 -89
- package/dist/bigconsole/components/widgets/metric-card/MetricCardWidget.js.map +1 -1
- package/dist/bigconsole/components/widgets/metric-card/SparklineChart.js +21 -13
- package/dist/bigconsole/components/widgets/metric-card/SparklineChart.js.map +1 -1
- package/dist/bigconsole/components/widgets/metric-card/index.js +4 -4
- package/dist/bigconsole/components/widgets/pivot-table/PivotTableWidget.js +3 -3
- package/dist/bigconsole/components/widgets/pivot-table/PivotTableWidget.js.map +1 -1
- package/dist/bigconsole/components/widgets/progress/ProgressConfig.js +34 -25
- package/dist/bigconsole/components/widgets/progress/ProgressConfig.js.map +1 -1
- package/dist/bigconsole/components/widgets/progress/ProgressWidget.js +129 -114
- package/dist/bigconsole/components/widgets/progress/ProgressWidget.js.map +1 -1
- package/dist/bigconsole/components/widgets/retention/RetentionWidget.js +3 -3
- package/dist/bigconsole/components/widgets/retention/RetentionWidget.js.map +1 -1
- package/dist/bigconsole/components/widgets/states/EmptyState.js +6 -4
- package/dist/bigconsole/components/widgets/states/EmptyState.js.map +1 -1
- package/dist/bigconsole/components/widgets/states/ErrorState.js +7 -5
- package/dist/bigconsole/components/widgets/states/ErrorState.js.map +1 -1
- package/dist/bigconsole/components/widgets/states/LoadingState.js +5 -4
- package/dist/bigconsole/components/widgets/states/LoadingState.js.map +1 -1
- package/dist/bigconsole/components/widgets/table/TableConfig.js +10 -4
- package/dist/bigconsole/components/widgets/table/TableConfig.js.map +1 -1
- package/dist/bigconsole/components/widgets/table/TableHeader.js +1 -1
- package/dist/bigconsole/components/widgets/table/TableHeader.js.map +1 -1
- package/dist/bigconsole/components/widgets/table/TableWidget.js +1 -1
- package/dist/bigconsole/components/widgets/table/TableWidget.js.map +1 -1
- package/dist/bigconsole/components/widgets/text-widget/TextWidget.js +1 -1
- package/dist/bigconsole/components/widgets/text-widget/TextWidget.js.map +1 -1
- package/dist/bigconsole/components/widgets/timeline/TimelineWidget.js +3 -3
- package/dist/bigconsole/components/widgets/timeline/TimelineWidget.js.map +1 -1
- package/dist/bigconsole/components/widgets/utils/conditionalFormat.js +2 -2
- package/dist/bigconsole/components/widgets/utils/conditionalFormat.js.map +1 -1
- package/dist/bigconsole/components/widgets/utils/targetProgress.js +13 -0
- package/dist/bigconsole/components/widgets/utils/targetProgress.js.map +1 -0
- package/dist/bigconsole/components/widgets/webhook-config/WebhookConfigPanel.js +112 -85
- package/dist/bigconsole/components/widgets/webhook-config/WebhookConfigPanel.js.map +1 -1
- package/dist/bigconsole/components/widgets/widget-actions/WidgetActions.js +28 -20
- package/dist/bigconsole/components/widgets/widget-actions/WidgetActions.js.map +1 -1
- package/dist/bigconsole/components/workflow/WorkflowCard.js +92 -77
- package/dist/bigconsole/components/workflow/WorkflowCard.js.map +1 -1
- package/dist/bigconsole/components/workflow/WorkflowDeleteDialog.js +70 -51
- package/dist/bigconsole/components/workflow/WorkflowDeleteDialog.js.map +1 -1
- package/dist/bigconsole/components/workflow/WorkflowStatusBadge.js +16 -17
- package/dist/bigconsole/components/workflow/WorkflowStatusBadge.js.map +1 -1
- package/dist/bigconsole/customWidget/CustomWidgetBuilderSheet.js +6 -4
- package/dist/bigconsole/customWidget/CustomWidgetBuilderSheet.js.map +1 -1
- package/dist/bigconsole/customWidget/CustomWidgetProposalPanel.js +360 -338
- package/dist/bigconsole/customWidget/CustomWidgetProposalPanel.js.map +1 -1
- package/dist/bigconsole/hooks/useModalFocusTrap.js +53 -0
- package/dist/bigconsole/hooks/useModalFocusTrap.js.map +1 -0
- package/dist/bigconsole/pages/DashboardBuilderPage.js +209 -203
- package/dist/bigconsole/pages/DashboardBuilderPage.js.map +1 -1
- package/dist/bigconsole/pages/DashboardViewPage.js +126 -120
- package/dist/bigconsole/pages/DashboardViewPage.js.map +1 -1
- package/dist/bigconsole/pages/DashboardsPage.js +838 -800
- package/dist/bigconsole/pages/DashboardsPage.js.map +1 -1
- package/dist/bigconsole/pages/DataParsersPage.js +263 -315
- package/dist/bigconsole/pages/DataParsersPage.js.map +1 -1
- package/dist/bigconsole/pages/DataSinkBuilderPage.js +301 -341
- package/dist/bigconsole/pages/DataSinkBuilderPage.js.map +1 -1
- package/dist/bigconsole/pages/DataSinkViewPage.js +346 -339
- package/dist/bigconsole/pages/DataSinkViewPage.js.map +1 -1
- package/dist/bigconsole/pages/DataSinksPage.js +356 -458
- package/dist/bigconsole/pages/DataSinksPage.js.map +1 -1
- package/dist/bigconsole/pages/DataSourcesPage.js +7 -2
- package/dist/bigconsole/pages/DataSourcesPage.js.map +1 -1
- package/dist/bigconsole/pages/HomePage.js +186 -193
- package/dist/bigconsole/pages/HomePage.js.map +1 -1
- package/dist/bigconsole/pages/InsightsPage.js +887 -740
- package/dist/bigconsole/pages/InsightsPage.js.map +1 -1
- package/dist/bigconsole/pages/ParserBuilderPage.js +679 -637
- package/dist/bigconsole/pages/ParserBuilderPage.js.map +1 -1
- package/dist/bigconsole/pages/ParserViewPage.js +368 -342
- package/dist/bigconsole/pages/ParserViewPage.js.map +1 -1
- package/dist/bigconsole/pages/PipelineBuilderPage.js +537 -444
- package/dist/bigconsole/pages/PipelineBuilderPage.js.map +1 -1
- package/dist/bigconsole/pages/PipelineViewPage.js +412 -377
- package/dist/bigconsole/pages/PipelineViewPage.js.map +1 -1
- package/dist/bigconsole/pages/PipelinesPage.js +248 -298
- package/dist/bigconsole/pages/PipelinesPage.js.map +1 -1
- package/dist/bigconsole/pages/WidgetDemoPage.js +251 -153
- package/dist/bigconsole/pages/WidgetDemoPage.js.map +1 -1
- package/dist/bigconsole/pages/WorkflowViewPage.js +381 -371
- package/dist/bigconsole/pages/WorkflowViewPage.js.map +1 -1
- package/dist/bigconsole/pages/WorkflowsPage.js +171 -286
- package/dist/bigconsole/pages/WorkflowsPage.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,187 +1,193 @@
|
|
|
1
|
-
import e from "
|
|
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
|
|
4
|
-
import { ArrowLeft as
|
|
5
|
-
import { useI18n as
|
|
6
|
-
import { Badge as
|
|
7
|
-
import { Fragment as
|
|
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
|
|
10
|
-
let { t:
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
}, [
|
|
14
|
-
let ne =
|
|
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(
|
|
20
|
+
alert(j("bigconsole.parsers.import.selectJsonFile", "Please select a JSON file"));
|
|
19
21
|
return;
|
|
20
22
|
}
|
|
21
|
-
|
|
23
|
+
P(t);
|
|
22
24
|
let n = new FileReader();
|
|
23
25
|
n.onload = async (e) => {
|
|
24
26
|
let t = e.target?.result;
|
|
25
|
-
|
|
26
|
-
let n =
|
|
27
|
-
n.isValid && n.parserInfo ? (
|
|
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(
|
|
31
|
+
alert(j("bigconsole.parsers.import.readFileFailed", "Failed to read file"));
|
|
30
32
|
}, n.readAsText(t);
|
|
31
|
-
}, [
|
|
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),
|
|
38
|
+
e.items.add(t), U.current && (U.current.files = e.files, U.current.dispatchEvent(new Event("change", { bubbles: !0 })));
|
|
37
39
|
}
|
|
38
|
-
}, []), ie =
|
|
39
|
-
if (!
|
|
40
|
-
|
|
41
|
-
let e = await
|
|
42
|
-
consoleId:
|
|
43
|
-
name:
|
|
44
|
-
inputSinkKey:
|
|
45
|
-
outputKey:
|
|
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 ? (
|
|
49
|
+
e?.success && e.parser ? (N("complete"), A?.(e.parser.id, e.parser.name, e.originalUpdated ?? !1)) : N("preview");
|
|
48
50
|
}, [
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
]), Q = !
|
|
57
|
-
return /* @__PURE__ */
|
|
58
|
-
open:
|
|
59
|
-
onOpenChange: (e) => !e && Q &&
|
|
60
|
-
children: /* @__PURE__ */
|
|
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__ */
|
|
65
|
+
/* @__PURE__ */ E(x, { children: [/* @__PURE__ */ E("div", {
|
|
64
66
|
className: "flex items-center gap-3",
|
|
65
|
-
children: [/* @__PURE__ */
|
|
66
|
-
className: "flex size-10 items-center justify-center rounded-lg bg-action-primary-bg/10",
|
|
67
|
-
children: /* @__PURE__ */
|
|
68
|
-
}), /* @__PURE__ */
|
|
69
|
-
}), /* @__PURE__ */
|
|
70
|
-
/* @__PURE__ */
|
|
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
|
-
|
|
75
|
+
M === "select" && /* @__PURE__ */ E("div", {
|
|
74
76
|
onDragOver: (e) => e.preventDefault(),
|
|
75
77
|
onDrop: re,
|
|
76
|
-
className: "border-2 border-dashed
|
|
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__ */
|
|
79
|
-
/* @__PURE__ */
|
|
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:
|
|
83
|
+
children: j("bigconsole.parsers.import.dropzoneTitle", "Drag and drop a parser export file here")
|
|
82
84
|
}),
|
|
83
|
-
/* @__PURE__ */
|
|
85
|
+
/* @__PURE__ */ T("p", {
|
|
84
86
|
className: "text-xs text-text-secondary mb-4",
|
|
85
|
-
children:
|
|
87
|
+
children: j("bigconsole.parsers.import.or", "or")
|
|
86
88
|
}),
|
|
87
|
-
/* @__PURE__ */
|
|
88
|
-
ref:
|
|
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__ */
|
|
95
|
-
onClick: () =>
|
|
96
|
-
disabled:
|
|
97
|
-
children:
|
|
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__ */
|
|
101
|
+
/* @__PURE__ */ T("p", {
|
|
100
102
|
className: "text-xs text-text-secondary mt-4",
|
|
101
|
-
children:
|
|
103
|
+
children: j("bigconsole.parsers.import.supportedHint", "Only .json files exported from BigConsole are supported")
|
|
102
104
|
})
|
|
103
105
|
]
|
|
104
106
|
}),
|
|
105
|
-
(
|
|
106
|
-
|
|
107
|
-
|
|
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__ */
|
|
110
|
-
className:
|
|
111
|
-
children: [/* @__PURE__ */
|
|
116
|
+
/* @__PURE__ */ E("div", {
|
|
117
|
+
className: D,
|
|
118
|
+
children: [/* @__PURE__ */ T("span", {
|
|
112
119
|
className: "text-sm text-text-secondary",
|
|
113
|
-
children:
|
|
114
|
-
}), /* @__PURE__ */
|
|
115
|
-
className: "text-sm font-medium",
|
|
116
|
-
children:
|
|
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__ */
|
|
120
|
-
className:
|
|
121
|
-
children: [/* @__PURE__ */
|
|
126
|
+
/* @__PURE__ */ E("div", {
|
|
127
|
+
className: D,
|
|
128
|
+
children: [/* @__PURE__ */ T("span", {
|
|
122
129
|
className: "text-sm text-text-secondary",
|
|
123
|
-
children:
|
|
124
|
-
}), /* @__PURE__ */
|
|
130
|
+
children: j("bigconsole.parsers.import.fieldType", "Type")
|
|
131
|
+
}), /* @__PURE__ */ T(m, {
|
|
125
132
|
variant: "secondary",
|
|
126
|
-
children:
|
|
133
|
+
children: K.parserInfo.type
|
|
127
134
|
})]
|
|
128
135
|
}),
|
|
129
|
-
/* @__PURE__ */
|
|
130
|
-
className:
|
|
131
|
-
children: [/* @__PURE__ */
|
|
136
|
+
/* @__PURE__ */ E("div", {
|
|
137
|
+
className: D,
|
|
138
|
+
children: [/* @__PURE__ */ T("span", {
|
|
132
139
|
className: "text-sm text-text-secondary",
|
|
133
|
-
children:
|
|
134
|
-
}), /* @__PURE__ */
|
|
135
|
-
className: "text-xs
|
|
136
|
-
children:
|
|
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__ */
|
|
140
|
-
className:
|
|
141
|
-
children: [/* @__PURE__ */
|
|
146
|
+
/* @__PURE__ */ E("div", {
|
|
147
|
+
className: D,
|
|
148
|
+
children: [/* @__PURE__ */ T("span", {
|
|
142
149
|
className: "text-sm text-text-secondary",
|
|
143
|
-
children:
|
|
144
|
-
}), /* @__PURE__ */
|
|
145
|
-
className: "text-xs
|
|
146
|
-
children:
|
|
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
|
-
|
|
150
|
-
className:
|
|
151
|
-
children: [/* @__PURE__ */
|
|
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:
|
|
154
|
-
}), /* @__PURE__ */
|
|
155
|
-
className: "text-xs text-text-secondary
|
|
156
|
-
children:
|
|
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__ */
|
|
160
|
-
className:
|
|
161
|
-
children: [/* @__PURE__ */
|
|
166
|
+
/* @__PURE__ */ E("div", {
|
|
167
|
+
className: D,
|
|
168
|
+
children: [/* @__PURE__ */ T("span", {
|
|
162
169
|
className: "text-sm text-text-secondary",
|
|
163
|
-
children:
|
|
164
|
-
}), /* @__PURE__ */
|
|
170
|
+
children: j("bigconsole.parsers.import.fieldSchemaVersion", "Schema Version")
|
|
171
|
+
}), /* @__PURE__ */ T("span", {
|
|
165
172
|
className: "text-xs text-text-secondary",
|
|
166
|
-
children:
|
|
173
|
+
children: K.parserInfo.schemaVersion
|
|
167
174
|
})]
|
|
168
175
|
})
|
|
169
176
|
]
|
|
170
|
-
})
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
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
|
-
]
|
|
195
|
-
})
|
|
200
|
+
]
|
|
201
|
+
}, t))
|
|
196
202
|
})
|
|
197
203
|
}),
|
|
198
|
-
|
|
199
|
-
|
|
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__ */
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
className: "
|
|
207
|
-
children: /* @__PURE__ */
|
|
208
|
-
className: "
|
|
209
|
-
children: /* @__PURE__ */
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
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__ */
|
|
240
|
+
/* @__PURE__ */ E("div", {
|
|
244
241
|
className: "space-y-2",
|
|
245
|
-
children: [/* @__PURE__ */
|
|
242
|
+
children: [/* @__PURE__ */ T(_, {
|
|
246
243
|
htmlFor: "import-name",
|
|
247
|
-
children:
|
|
248
|
-
}), /* @__PURE__ */
|
|
244
|
+
children: j("bigconsole.parsers.import.parserNameLabel", "Parser Name")
|
|
245
|
+
}), /* @__PURE__ */ T(g, {
|
|
249
246
|
id: "import-name",
|
|
250
247
|
type: "text",
|
|
251
|
-
value:
|
|
252
|
-
onChange: (e) =>
|
|
253
|
-
placeholder:
|
|
254
|
-
disabled:
|
|
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__ */
|
|
254
|
+
/* @__PURE__ */ E("div", {
|
|
258
255
|
className: "space-y-2",
|
|
259
256
|
children: [
|
|
260
|
-
/* @__PURE__ */
|
|
257
|
+
/* @__PURE__ */ T(_, {
|
|
261
258
|
htmlFor: "import-input-sink",
|
|
262
|
-
children:
|
|
259
|
+
children: j("bigconsole.parsers.import.inputSinkKeyLabel", "Input Sink Key")
|
|
263
260
|
}),
|
|
264
|
-
/* @__PURE__ */
|
|
261
|
+
/* @__PURE__ */ T(g, {
|
|
265
262
|
id: "import-input-sink",
|
|
266
263
|
type: "text",
|
|
267
|
-
value:
|
|
268
|
-
onChange: (e) =>
|
|
269
|
-
placeholder:
|
|
270
|
-
disabled:
|
|
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__ */
|
|
269
|
+
/* @__PURE__ */ T("p", {
|
|
273
270
|
className: "text-xs text-text-secondary",
|
|
274
|
-
children:
|
|
271
|
+
children: j("bigconsole.parsers.import.inputSinkKeyHelp", "The DataSink key to read input data from.")
|
|
275
272
|
})
|
|
276
273
|
]
|
|
277
274
|
}),
|
|
278
|
-
/* @__PURE__ */
|
|
275
|
+
/* @__PURE__ */ E("div", {
|
|
279
276
|
className: "space-y-2",
|
|
280
277
|
children: [
|
|
281
|
-
/* @__PURE__ */
|
|
278
|
+
/* @__PURE__ */ T(_, {
|
|
282
279
|
htmlFor: "import-output-key",
|
|
283
|
-
children:
|
|
280
|
+
children: j("bigconsole.parsers.import.outputKeyLabel", "Output Key")
|
|
284
281
|
}),
|
|
285
|
-
/* @__PURE__ */
|
|
282
|
+
/* @__PURE__ */ T(g, {
|
|
286
283
|
id: "import-output-key",
|
|
287
284
|
type: "text",
|
|
288
|
-
value:
|
|
289
|
-
onChange: (e) =>
|
|
290
|
-
placeholder:
|
|
291
|
-
disabled:
|
|
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__ */
|
|
290
|
+
/* @__PURE__ */ T("p", {
|
|
294
291
|
className: "text-xs text-text-secondary",
|
|
295
|
-
children:
|
|
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
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
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
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
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
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
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__ */
|
|
372
|
-
className: "flex-
|
|
373
|
-
children: [/* @__PURE__ */
|
|
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
|
-
|
|
336
|
+
N("select"), P(null), I(null), Z();
|
|
377
337
|
},
|
|
378
|
-
disabled:
|
|
379
|
-
children: [/* @__PURE__ */
|
|
380
|
-
}) }), /* @__PURE__ */
|
|
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
|
-
|
|
343
|
+
M !== "complete" && /* @__PURE__ */ T(h, {
|
|
384
344
|
variant: "outline",
|
|
385
|
-
onClick:
|
|
345
|
+
onClick: O,
|
|
386
346
|
disabled: !Q,
|
|
387
|
-
children:
|
|
347
|
+
children: j("bigconsole.parsers.import.cancel", "Cancel")
|
|
388
348
|
}),
|
|
389
|
-
|
|
349
|
+
M === "preview" && K?.isValid && /* @__PURE__ */ E(h, {
|
|
390
350
|
onClick: ie,
|
|
391
|
-
disabled:
|
|
392
|
-
children: [/* @__PURE__ */
|
|
351
|
+
disabled: W,
|
|
352
|
+
children: [/* @__PURE__ */ T(d, { className: "size-4" }), j("bigconsole.parsers.import.importButton", "Import Parser")]
|
|
393
353
|
}),
|
|
394
|
-
|
|
354
|
+
M === "importing" && /* @__PURE__ */ E("div", {
|
|
395
355
|
className: "flex items-center gap-2 text-sm text-text-secondary",
|
|
396
|
-
children: [/* @__PURE__ */
|
|
356
|
+
children: [/* @__PURE__ */ T(C, { className: "size-4" }), j("bigconsole.parsers.import.importing", "Importing...")]
|
|
397
357
|
}),
|
|
398
|
-
|
|
399
|
-
onClick:
|
|
400
|
-
children:
|
|
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 {
|
|
370
|
+
export { O as default };
|
|
411
371
|
|
|
412
372
|
//# sourceMappingURL=ImportParserDialog.js.map
|