@burdenoff/microfe-bigconsole 2026.924.2 → 2026.924.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bigconsole/BigConsoleRoutes.js +137 -138
- package/dist/bigconsole/BigConsoleRoutes.js.map +1 -1
- package/dist/bigconsole/assistant/previewController.js +10 -10
- package/dist/bigconsole/components/DrilldownDashboardRenderer.js +17 -17
- package/dist/bigconsole/components/builder/inspector/DataBindingSection.js +32 -32
- package/dist/bigconsole/components/dashboard/CreateDashboardDialog.js +52 -52
- package/dist/bigconsole/components/dashboard/CreateDashboardDialog.js.map +1 -1
- package/dist/bigconsole/components/dashboard/DashboardCanvas.js +7 -7
- package/dist/bigconsole/components/dashboard/DashboardStatusPill.js +53 -0
- package/dist/bigconsole/components/dashboard/DashboardStatusPill.js.map +1 -0
- package/dist/bigconsole/components/dashboard/DashboardToolbar.js +60 -60
- package/dist/bigconsole/components/dashboard/DrilldownBreadcrumb.js +21 -21
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterChip.js +30 -30
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterEditor.js +36 -36
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterPresetSelector.js +34 -34
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/GlobalFiltersBar.js +38 -38
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/GlobalFiltersBar.js.map +1 -1
- package/dist/bigconsole/components/dashboard/ImportDashboardDialog.js +121 -121
- package/dist/bigconsole/components/dashboard/ImportDashboardDialog.js.map +1 -1
- package/dist/bigconsole/components/dashboard/PublishToStoreDialog.js +22 -22
- package/dist/bigconsole/components/dashboard/SavedViewsDropdown/SavedViewsDropdown.js +46 -46
- package/dist/bigconsole/components/dashboard/ShareDialog/EmbedTab.js +53 -53
- package/dist/bigconsole/components/dashboard/TemplatePicker/TemplatePicker.js +1 -1
- package/dist/bigconsole/components/dashboard/WidgetPalette.js +47 -47
- package/dist/bigconsole/components/dashboard/index.js +1 -0
- package/dist/bigconsole/components/datasink/CacheTTLSelector.js +35 -35
- package/dist/bigconsole/components/datasink/DataSinkDeleteDialog.js +18 -18
- package/dist/bigconsole/components/datasink/DataSinkRefreshDialog.js +20 -20
- package/dist/bigconsole/components/datasink/DataSinkStatusBadge.js +30 -29
- package/dist/bigconsole/components/datasink/DataSinkStatusBadge.js.map +1 -1
- package/dist/bigconsole/components/datasink/ImportDataGuideDialog.js +48 -48
- package/dist/bigconsole/components/datasink/ImportDataSinkDialog.js +103 -103
- package/dist/bigconsole/components/datasink/ImportDataSinkDialog.js.map +1 -1
- package/dist/bigconsole/components/datasink/RefreshTypeSelector.js +35 -35
- package/dist/bigconsole/components/overview/DashboardGuide.js +214 -0
- package/dist/bigconsole/components/overview/DashboardGuide.js.map +1 -0
- package/dist/bigconsole/components/overview/DataHealthCard.js +97 -0
- package/dist/bigconsole/components/overview/DataHealthCard.js.map +1 -0
- package/dist/bigconsole/components/overview/OverviewQuickActions.js +32 -0
- package/dist/bigconsole/components/overview/OverviewQuickActions.js.map +1 -0
- package/dist/bigconsole/components/overview/OverviewStatCard.js +57 -0
- package/dist/bigconsole/components/overview/OverviewStatCard.js.map +1 -0
- package/dist/bigconsole/components/overview/RecentDashboardsPanel.js +107 -0
- package/dist/bigconsole/components/overview/RecentDashboardsPanel.js.map +1 -0
- package/dist/bigconsole/components/overview/dashboardGuideSteps.js +119 -0
- package/dist/bigconsole/components/overview/dashboardGuideSteps.js.map +1 -0
- package/dist/bigconsole/components/overview/index.js +8 -0
- package/dist/bigconsole/components/overview/overviewModel.js +119 -0
- package/dist/bigconsole/components/overview/overviewModel.js.map +1 -0
- package/dist/bigconsole/components/overview/useOverviewData.js +48 -0
- package/dist/bigconsole/components/overview/useOverviewData.js.map +1 -0
- package/dist/bigconsole/components/parser/DataSinkSelector.js +40 -40
- package/dist/bigconsole/components/parser/ImportParserDialog.js +127 -127
- package/dist/bigconsole/components/parser/ImportParserDialog.js.map +1 -1
- package/dist/bigconsole/components/parser/ParserSelector.js +51 -51
- package/dist/bigconsole/components/preview/AiPreviewContent.js +5 -5
- package/dist/bigconsole/components/preview/AiPreviewMiniPanel.js +33 -33
- package/dist/bigconsole/components/preview/AiPreviewPanel.js +38 -38
- package/dist/bigconsole/components/widgets/ActionConfigDialog.js +13 -13
- package/dist/bigconsole/components/widgets/DrilldownConfigPanel.js +70 -70
- package/dist/bigconsole/components/widgets/PropertiesPanel.js +28 -28
- package/dist/bigconsole/components/widgets/calendar/CalendarWidget.js +25 -25
- package/dist/bigconsole/components/widgets/chart/ChartConfig.js +48 -48
- package/dist/bigconsole/components/widgets/comments/WidgetComments.js +46 -46
- package/dist/bigconsole/components/widgets/event-logs/EventLogViewer.js +61 -61
- package/dist/bigconsole/components/widgets/form/FormWidget.js +36 -36
- package/dist/bigconsole/components/widgets/gauge/GaugeConfig.js +42 -42
- package/dist/bigconsole/components/widgets/heatmap/HeatmapConfig.js +25 -25
- package/dist/bigconsole/components/widgets/kanban/KanbanWidget.js +21 -21
- package/dist/bigconsole/components/widgets/list/ListConfig.js +30 -30
- package/dist/bigconsole/components/widgets/metric-card/MetricCardConfig.js +38 -38
- package/dist/bigconsole/components/widgets/metric-card/SparklineChart.js +9 -9
- package/dist/bigconsole/components/widgets/metric-card/TrendIndicator.js +9 -9
- package/dist/bigconsole/components/widgets/pivot-table/PivotTableWidget.js +49 -49
- package/dist/bigconsole/components/widgets/progress/ProgressConfig.js +39 -39
- package/dist/bigconsole/components/widgets/table/TableConfig.js +73 -73
- package/dist/bigconsole/components/widgets/webhook-config/WebhookConfigPanel.js +64 -64
- package/dist/bigconsole/customWidget/CustomWidgetBuilderSheet.js +10 -10
- package/dist/bigconsole/customWidget/CustomWidgetProposalPanel.js +68 -68
- package/dist/bigconsole/customWidget/CustomWidgetProposalPanel.js.map +1 -1
- package/dist/bigconsole/pages/AdminPage.js +136 -136
- package/dist/bigconsole/pages/DashboardBuilderPage.js +10 -10
- package/dist/bigconsole/pages/DashboardViewPage.js +61 -61
- package/dist/bigconsole/pages/DashboardViewPage.js.map +1 -1
- package/dist/bigconsole/pages/DashboardsPage.js +327 -348
- package/dist/bigconsole/pages/DashboardsPage.js.map +1 -1
- package/dist/bigconsole/pages/DataParsersPage.js +5 -5
- package/dist/bigconsole/pages/DataSinkBuilderPage.js +10 -10
- package/dist/bigconsole/pages/DataSinkBuilderPage.js.map +1 -1
- package/dist/bigconsole/pages/DataSinkViewPage.js +83 -83
- package/dist/bigconsole/pages/DataSinkViewPage.js.map +1 -1
- package/dist/bigconsole/pages/DataSinksPage.js +11 -11
- package/dist/bigconsole/pages/DataSourcesPage.js +5 -5
- package/dist/bigconsole/pages/InsightsPage.js +315 -315
- package/dist/bigconsole/pages/InsightsPage.js.map +1 -1
- package/dist/bigconsole/pages/OverviewPage.js +244 -0
- package/dist/bigconsole/pages/OverviewPage.js.map +1 -0
- package/dist/bigconsole/pages/ParserBuilderPage.js +5 -5
- package/dist/bigconsole/pages/ParserViewPage.js +98 -98
- package/dist/bigconsole/pages/ParserViewPage.js.map +1 -1
- package/dist/bigconsole/pages/PipelineBuilderPage.js +8 -8
- package/dist/bigconsole/pages/PipelineViewPage.js +46 -46
- package/dist/bigconsole/pages/PipelineViewPage.js.map +1 -1
- package/dist/bigconsole/pages/PipelinesPage.js +80 -80
- package/dist/bigconsole/pages/PipelinesPage.js.map +1 -1
- package/dist/bigconsole/pages/SettingsPage.js +70 -70
- package/dist/bigconsole/pages/WidgetDemoPage.js +42 -42
- package/dist/bigconsole/pages/WorkflowViewPage.js +200 -200
- package/dist/bigconsole/pages/WorkflowViewPage.js.map +1 -1
- package/dist/bigconsole/pages/WorkflowsPage.js +78 -78
- package/dist/bigconsole/pages/WorkflowsPage.js.map +1 -1
- package/dist/bigconsole/renderers/adapters/AdaptiveCardRenderer.js +34 -34
- package/dist/bigconsole/renderers/adapters/BlockKitRenderer.js +79 -79
- package/dist/bigconsole/renderers/adapters/CustomRenderer.js +46 -46
- package/dist/bigconsole/utils/createDialogParam.js +14 -0
- package/dist/bigconsole/utils/createDialogParam.js.map +1 -0
- package/dist/generated/global-operations.js +1 -1
- package/dist/generated/wspace-operations.js +285 -222
- package/dist/generated/wspace-operations.js.map +1 -1
- package/dist/shared/hooks/useTr.js +10 -7
- package/dist/shared/hooks/useTr.js.map +1 -1
- package/package.json +1 -1
- package/dist/bigconsole/pages/HomePage.js +0 -318
- package/dist/bigconsole/pages/HomePage.js.map +0 -1
|
@@ -1,37 +1,37 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import "../common/index.js";
|
|
3
|
-
import { useBigConsoleNavigate as t } from "../../context/BigConsoleContext.js";
|
|
1
|
+
import { useBigConsoleNavigate as e } from "../../context/BigConsoleContext.js";
|
|
4
2
|
import "../../context/index.js";
|
|
5
|
-
import { useAssistantPanelShowsPreview as
|
|
6
|
-
import { PREVIEW_STEPS as
|
|
3
|
+
import { useAssistantPanelShowsPreview as t } from "../../assistant/useAssistantPanelShowsPreview.js";
|
|
4
|
+
import { PREVIEW_STEPS as n, useAssistantRunStore as r } from "../../assistant/assistantRunStore.js";
|
|
5
|
+
import { Section as i } from "../common/Section.js";
|
|
6
|
+
import "../common/index.js";
|
|
7
7
|
import { DOCK_CLEARANCE as a, PreviewMeta as o, STEP_LABEL as s, formatAgo as c, previewLabels as l } from "./previewShared.js";
|
|
8
8
|
import { DashboardContent as u, DataSinkContent as d, ParserContent as f, WidgetsContent as p } from "./AiPreviewContent.js";
|
|
9
9
|
import { useEffect as m, useRef as h, useState as g } from "react";
|
|
10
10
|
import { ArrowUpRight as _, Loader2 as v, Sparkles as y, X as b } from "lucide-react";
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
11
|
+
import { Button as x } from "@burdenoff/fe-libs/ui";
|
|
12
|
+
import { jsx as S, jsxs as C } from "react/jsx-runtime";
|
|
13
|
+
import { AssistantEntityPreview as w } from "@burdenoff/fe-libs/shared/assistant";
|
|
14
|
+
import { useI18n as T } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
15
15
|
//#region src/bigconsole/components/preview/AiPreviewPanel.tsx
|
|
16
16
|
function E({ children: e }) {
|
|
17
|
-
return /* @__PURE__ */
|
|
17
|
+
return /* @__PURE__ */ S("div", {
|
|
18
18
|
className: "min-w-0 overflow-y-auto p-3",
|
|
19
19
|
style: { maxHeight: "min(440px, 60vh)" },
|
|
20
20
|
children: e
|
|
21
21
|
});
|
|
22
22
|
}
|
|
23
23
|
function D({ onOpen: e }) {
|
|
24
|
-
let { t } =
|
|
25
|
-
return /* @__PURE__ */
|
|
24
|
+
let { t } = T();
|
|
25
|
+
return /* @__PURE__ */ C(x, {
|
|
26
26
|
size: "sm",
|
|
27
27
|
variant: "outline",
|
|
28
28
|
onClick: e,
|
|
29
29
|
"data-testid": "ai-preview-open-entity",
|
|
30
|
-
children: [t("bigconsole.widget.aiPreview.open", "Open"), /* @__PURE__ */
|
|
30
|
+
children: [t("bigconsole.widget.aiPreview.open", "Open"), /* @__PURE__ */ S(_, { className: "ml-1 size-3.5" })]
|
|
31
31
|
});
|
|
32
32
|
}
|
|
33
33
|
function O() {
|
|
34
|
-
let { t: _ } =
|
|
34
|
+
let { t: _ } = T(), O = t(), k = e(), A = r((e) => e.isRunning), j = r((e) => e.previewOpen), M = r((e) => e.hasRun), N = r((e) => e.steps), P = r((e) => e.entityIds), F = r((e) => e.caption), I = r((e) => e.error), L = r((e) => e.updatedAt), R = r((e) => e.openPreview), z = r((e) => e.closePreview), B = r((e) => e.setRichMounted);
|
|
35
35
|
m(() => (B(!0), () => {
|
|
36
36
|
B(!1);
|
|
37
37
|
}), [B]);
|
|
@@ -39,25 +39,25 @@ function O() {
|
|
|
39
39
|
if (m(() => {
|
|
40
40
|
A && !U.current && H((e) => e + 1), U.current = A;
|
|
41
41
|
}, [A]), !M || O) return null;
|
|
42
|
-
if (!j) return /* @__PURE__ */
|
|
42
|
+
if (!j) return /* @__PURE__ */ C("div", {
|
|
43
43
|
className: "flex flex-wrap items-center justify-end gap-control-gap px-4 pt-3 md:px-6",
|
|
44
44
|
style: { marginRight: a },
|
|
45
|
-
children: [/* @__PURE__ */
|
|
45
|
+
children: [/* @__PURE__ */ S("span", {
|
|
46
46
|
className: "text-xs text-text-muted",
|
|
47
47
|
children: A ? _("bigconsole.widget.aiPreview.buildRunning", "AI build running") : _("bigconsole.widget.aiPreview.buildFinished", "AI build finished")
|
|
48
|
-
}), /* @__PURE__ */
|
|
48
|
+
}), /* @__PURE__ */ C(x, {
|
|
49
49
|
size: "sm",
|
|
50
50
|
variant: "outline",
|
|
51
51
|
onClick: R,
|
|
52
52
|
"data-testid": "ai-preview-open",
|
|
53
53
|
children: [
|
|
54
|
-
/* @__PURE__ */
|
|
54
|
+
/* @__PURE__ */ S(y, { className: "mr-1.5 size-4" }),
|
|
55
55
|
_("bigconsole.widget.aiPreview.previewButton", "Preview"),
|
|
56
|
-
A ? /* @__PURE__ */
|
|
56
|
+
A ? /* @__PURE__ */ S(v, { className: "ml-1.5 size-3.5 animate-spin" }) : null
|
|
57
57
|
]
|
|
58
58
|
})]
|
|
59
59
|
});
|
|
60
|
-
let W = P.dashboard, G =
|
|
60
|
+
let W = P.dashboard, G = n.map((e) => ({
|
|
61
61
|
id: e,
|
|
62
62
|
label: _(s[e].key, s[e].fallback),
|
|
63
63
|
status: N[e]
|
|
@@ -65,14 +65,14 @@ function O() {
|
|
|
65
65
|
{
|
|
66
66
|
id: "datasink",
|
|
67
67
|
label: _("bigconsole.widget.aiPreview.tab.dataSink", "Data Sink"),
|
|
68
|
-
render: () => /* @__PURE__ */
|
|
68
|
+
render: () => /* @__PURE__ */ S(E, { children: /* @__PURE__ */ S(i, {
|
|
69
69
|
emphasis: "standard",
|
|
70
70
|
padding: "compact",
|
|
71
71
|
headingLevel: 3,
|
|
72
72
|
title: _("bigconsole.widget.aiPreview.dataSinkRows", "Data sink rows"),
|
|
73
73
|
description: _("bigconsole.widget.aiPreview.dataSinkRowsHint", "The rows the assistant just landed, straight from the sink."),
|
|
74
|
-
actions: P.datasink ? /* @__PURE__ */
|
|
75
|
-
children: /* @__PURE__ */
|
|
74
|
+
actions: P.datasink ? /* @__PURE__ */ S(D, { onOpen: () => k(`/datasinks/${P.datasink}`) }) : void 0,
|
|
75
|
+
children: /* @__PURE__ */ S(d, {
|
|
76
76
|
id: P.datasink,
|
|
77
77
|
live: A
|
|
78
78
|
})
|
|
@@ -81,27 +81,27 @@ function O() {
|
|
|
81
81
|
{
|
|
82
82
|
id: "dashboard",
|
|
83
83
|
label: _("bigconsole.widget.aiPreview.tab.dashboard", "Dashboard"),
|
|
84
|
-
render: () => /* @__PURE__ */
|
|
84
|
+
render: () => /* @__PURE__ */ S(E, { children: /* @__PURE__ */ S(i, {
|
|
85
85
|
emphasis: "standard",
|
|
86
86
|
padding: "compact",
|
|
87
87
|
headingLevel: 3,
|
|
88
88
|
title: _("bigconsole.widget.aiPreview.tab.dashboard", "Dashboard"),
|
|
89
89
|
description: _("bigconsole.widget.aiPreview.dashboardHint", "The live board, rendered exactly as the real page renders it."),
|
|
90
|
-
actions: W ? /* @__PURE__ */
|
|
91
|
-
children: /* @__PURE__ */
|
|
90
|
+
actions: W ? /* @__PURE__ */ S(D, { onOpen: () => k(`/dashboards/${W}`) }) : void 0,
|
|
91
|
+
children: /* @__PURE__ */ S(u, { dashboardId: W })
|
|
92
92
|
}) })
|
|
93
93
|
},
|
|
94
94
|
{
|
|
95
95
|
id: "parser",
|
|
96
96
|
label: _("bigconsole.widget.aiPreview.tab.parser", "Parser"),
|
|
97
|
-
render: () => /* @__PURE__ */
|
|
97
|
+
render: () => /* @__PURE__ */ S(E, { children: /* @__PURE__ */ S(i, {
|
|
98
98
|
emphasis: "standard",
|
|
99
99
|
padding: "compact",
|
|
100
100
|
headingLevel: 3,
|
|
101
101
|
title: _("bigconsole.widget.aiPreview.parserOutput", "Parser output"),
|
|
102
102
|
description: _("bigconsole.widget.aiPreview.parserOutputHint", "The rows after the parser's transform, so you can check the shape."),
|
|
103
|
-
actions: P.parser ? /* @__PURE__ */
|
|
104
|
-
children: /* @__PURE__ */
|
|
103
|
+
actions: P.parser ? /* @__PURE__ */ S(D, { onOpen: () => k(`/parsers/${P.parser}`) }) : void 0,
|
|
104
|
+
children: /* @__PURE__ */ S(f, {
|
|
105
105
|
parserId: P.parser,
|
|
106
106
|
live: A
|
|
107
107
|
})
|
|
@@ -110,28 +110,28 @@ function O() {
|
|
|
110
110
|
{
|
|
111
111
|
id: "widget",
|
|
112
112
|
label: _("bigconsole.widget.aiPreview.tab.widget", "Widget"),
|
|
113
|
-
render: () => /* @__PURE__ */
|
|
113
|
+
render: () => /* @__PURE__ */ S(E, { children: /* @__PURE__ */ S(i, {
|
|
114
114
|
emphasis: "standard",
|
|
115
115
|
padding: "compact",
|
|
116
116
|
headingLevel: 3,
|
|
117
117
|
title: _("bigconsole.widget.aiPreview.widgets", "Widgets"),
|
|
118
118
|
description: _("bigconsole.widget.aiPreview.widgetsHint", "Every widget on the new dashboard, rendered live."),
|
|
119
|
-
actions: W ? /* @__PURE__ */
|
|
120
|
-
children: /* @__PURE__ */
|
|
119
|
+
actions: W ? /* @__PURE__ */ S(D, { onOpen: () => k(`/dashboards/${W}`) }) : void 0,
|
|
120
|
+
children: /* @__PURE__ */ S(p, {
|
|
121
121
|
dashboardId: W,
|
|
122
122
|
live: A
|
|
123
123
|
})
|
|
124
124
|
}) })
|
|
125
125
|
}
|
|
126
126
|
];
|
|
127
|
-
return /* @__PURE__ */
|
|
127
|
+
return /* @__PURE__ */ C("div", {
|
|
128
128
|
"data-testid": "ai-preview-panel",
|
|
129
129
|
style: { paddingRight: a },
|
|
130
130
|
className: "mx-4 mt-3 min-w-0 md:mx-6",
|
|
131
|
-
children: [/* @__PURE__ */
|
|
131
|
+
children: [/* @__PURE__ */ S("h2", {
|
|
132
132
|
className: "sr-only",
|
|
133
133
|
children: _("bigconsole.widget.aiPreview.title", "AI Preview")
|
|
134
|
-
}), /* @__PURE__ */
|
|
134
|
+
}), /* @__PURE__ */ S(w, {
|
|
135
135
|
title: _("bigconsole.widget.aiPreview.title", "AI Preview"),
|
|
136
136
|
runKey: String(V),
|
|
137
137
|
steps: G,
|
|
@@ -139,20 +139,20 @@ function O() {
|
|
|
139
139
|
follow: "produced",
|
|
140
140
|
caption: A ? F || _("bigconsole.widget.aiPreview.working", "Working…") : _("bigconsole.widget.aiPreview.done", "Done"),
|
|
141
141
|
error: I,
|
|
142
|
-
meta: /* @__PURE__ */
|
|
142
|
+
meta: /* @__PURE__ */ S(o, {
|
|
143
143
|
state: A ? "running" : I ? "stopped" : "idle",
|
|
144
144
|
stateLabel: A ? _("bigconsole.widget.aiPreview.live", "Live") : I ? _("bigconsole.widget.aiPreview.stopped", "Stopped") : null,
|
|
145
145
|
updatedLabel: _("bigconsole.widget.aiPreview.updated", "updated"),
|
|
146
146
|
updatedAt: L,
|
|
147
147
|
ago: (e) => c(e, _)
|
|
148
148
|
}),
|
|
149
|
-
headerActions: /* @__PURE__ */
|
|
149
|
+
headerActions: /* @__PURE__ */ S(x, {
|
|
150
150
|
size: "sm",
|
|
151
151
|
variant: "ghost",
|
|
152
152
|
onClick: z,
|
|
153
153
|
"aria-label": _("bigconsole.widget.aiPreview.closeAriaLabel", "Close preview"),
|
|
154
154
|
"data-testid": "ai-preview-close",
|
|
155
|
-
children: /* @__PURE__ */
|
|
155
|
+
children: /* @__PURE__ */ S(b, { className: "size-4" })
|
|
156
156
|
}),
|
|
157
157
|
labels: l(_)
|
|
158
158
|
})]
|
|
@@ -4,9 +4,9 @@ import { BIGCONSOLE_PERMISSIONS as t } from "../../../constants/permissions.js";
|
|
|
4
4
|
import { memo as n, useCallback as r, useEffect as ee, useMemo as i, useRef as te, useState as a } from "react";
|
|
5
5
|
import { PermissionButton as ne } from "@burdenoff/fe-libs/shared/components";
|
|
6
6
|
import { ChevronDown as re, ChevronRight as ie, Pencil as ae, Plus as oe, Zap as se } from "lucide-react";
|
|
7
|
-
import {
|
|
8
|
-
import { Button as le, Checkbox as o, Dialog as ue, DialogContent as de, DialogDescription as fe, DialogFooter as pe, DialogHeader as me, DialogTitle as he, Input as s, Select as c, SelectContent as l, SelectItem as u, SelectTrigger as d, SelectValue as f, Spinner as ge, Textarea as _e } from "@burdenoff/fe-libs/ui";
|
|
7
|
+
import { Button as ce, Checkbox as o, Dialog as le, DialogContent as ue, DialogDescription as de, DialogFooter as fe, DialogHeader as pe, DialogTitle as me, Input as s, Select as c, SelectContent as l, SelectItem as u, SelectTrigger as d, SelectValue as f, Spinner as he, Textarea as ge } from "@burdenoff/fe-libs/ui";
|
|
9
8
|
import { jsx as p, jsxs as m } from "react/jsx-runtime";
|
|
9
|
+
import { useI18n as _e } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
10
10
|
//#region src/bigconsole/components/widgets/ActionConfigDialog.tsx
|
|
11
11
|
var ve = [
|
|
12
12
|
"POST",
|
|
@@ -78,7 +78,7 @@ var g = {
|
|
|
78
78
|
boxShadow: "var(--shadow-elevation-3)",
|
|
79
79
|
borderRadius: "var(--radius-button)"
|
|
80
80
|
}, y = n(function({ isOpen: n, action: y, initialWebhook: b, isLoading: x = !1, saveError: Se, onClose: Ce, onSave: we }) {
|
|
81
|
-
let { t: S } =
|
|
81
|
+
let { t: S } = _e(), C = !!y, Te = te(null), w = te(!1), [T, E] = a(""), [D, O] = a(""), [k, A] = a(!1), [j, M] = a("PRIMARY"), [N, Ee] = a(""), [P, F] = a("WEBHOOK"), [I, L] = a(""), [R, z] = a("POST"), [B, V] = a(!1), [H, U] = a(!1), [W, De] = a(!1), [G, K] = a(!1), [q, J] = a(() => S("bigconsole.widget.actions.confirm.defaultTitle", "Confirm Action")), [Oe, Y] = a(() => S("bigconsole.widget.actions.confirm.defaultMessage", "Are you sure you want to proceed?")), [ke, X] = a(() => S("bigconsole.widget.actions.confirm.defaultConfirmLabel", "Confirm")), [Ae, Z] = a(() => S("bigconsole.widget.actions.confirm.defaultCancelLabel", "Cancel")), [Q, $] = a(null), je = i(() => [{
|
|
82
82
|
value: "WEBHOOK",
|
|
83
83
|
label: S("bigconsole.widget.actions.outcome.webhook.label", "Call a webhook / my API"),
|
|
84
84
|
hint: S("bigconsole.widget.actions.outcome.webhook.hint", "Sends an HTTP request to the URL below every time the button is clicked.")
|
|
@@ -210,16 +210,16 @@ var g = {
|
|
|
210
210
|
we,
|
|
211
211
|
S
|
|
212
212
|
]), Ie = (e) => Me.find((t) => t.value === e)?.color || "var(--color-action-primary-bg)", Le = je.find((e) => e.value === P);
|
|
213
|
-
return /* @__PURE__ */ p(
|
|
213
|
+
return /* @__PURE__ */ p(le, {
|
|
214
214
|
open: n,
|
|
215
215
|
onOpenChange: (e) => !e && !x && Ce(),
|
|
216
|
-
children: /* @__PURE__ */ m(
|
|
216
|
+
children: /* @__PURE__ */ m(ue, {
|
|
217
217
|
style: {
|
|
218
218
|
width: "min(500px, calc(100vw - 2rem))",
|
|
219
219
|
maxWidth: "calc(100vw - 2rem)",
|
|
220
220
|
padding: 0
|
|
221
221
|
},
|
|
222
|
-
children: [/* @__PURE__ */ p(
|
|
222
|
+
children: [/* @__PURE__ */ p(pe, {
|
|
223
223
|
style: { padding: "var(--space-cardPadding) var(--space-cardPadding) 0" },
|
|
224
224
|
children: /* @__PURE__ */ m("div", {
|
|
225
225
|
style: {
|
|
@@ -245,7 +245,7 @@ var g = {
|
|
|
245
245
|
width: "var(--size-icon-lg)",
|
|
246
246
|
color: "var(--color-action-primary-text)"
|
|
247
247
|
} })
|
|
248
|
-
}), /* @__PURE__ */ m("div", { children: [/* @__PURE__ */ p(
|
|
248
|
+
}), /* @__PURE__ */ m("div", { children: [/* @__PURE__ */ p(me, {
|
|
249
249
|
style: {
|
|
250
250
|
fontSize: "var(--font-size-body-md)",
|
|
251
251
|
fontWeight: "var(--font-weight-bold)",
|
|
@@ -253,7 +253,7 @@ var g = {
|
|
|
253
253
|
margin: 0
|
|
254
254
|
},
|
|
255
255
|
children: C ? S("bigconsole.widget.actions.header.editTitle", "Edit Button") : S("bigconsole.widget.actions.header.addTitle", "Add Button")
|
|
256
|
-
}), /* @__PURE__ */ p(
|
|
256
|
+
}), /* @__PURE__ */ p(de, {
|
|
257
257
|
style: {
|
|
258
258
|
fontSize: "var(--font-size-body-sm)",
|
|
259
259
|
color: "var(--color-text-secondary)",
|
|
@@ -588,7 +588,7 @@ var g = {
|
|
|
588
588
|
marginBottom: "var(--space-controlGap)"
|
|
589
589
|
},
|
|
590
590
|
children: S("bigconsole.widget.actions.confirm.messageLabel", "Message")
|
|
591
|
-
}), /* @__PURE__ */ p(
|
|
591
|
+
}), /* @__PURE__ */ p(ge, {
|
|
592
592
|
value: Oe,
|
|
593
593
|
onChange: (e) => Y(e.target.value),
|
|
594
594
|
rows: 2,
|
|
@@ -765,7 +765,7 @@ var g = {
|
|
|
765
765
|
})]
|
|
766
766
|
})
|
|
767
767
|
]
|
|
768
|
-
}), /* @__PURE__ */ m(
|
|
768
|
+
}), /* @__PURE__ */ m(fe, {
|
|
769
769
|
style: {
|
|
770
770
|
padding: "var(--space-formGap) var(--space-pagePadding)",
|
|
771
771
|
borderTop: "1px solid var(--color-border-subtle)",
|
|
@@ -774,7 +774,7 @@ var g = {
|
|
|
774
774
|
justifyContent: "flex-end",
|
|
775
775
|
gap: "var(--space-controlGap)"
|
|
776
776
|
},
|
|
777
|
-
children: [/* @__PURE__ */ p(
|
|
777
|
+
children: [/* @__PURE__ */ p(ce, {
|
|
778
778
|
type: "button",
|
|
779
779
|
variant: "outline",
|
|
780
780
|
onClick: Ce,
|
|
@@ -784,7 +784,7 @@ var g = {
|
|
|
784
784
|
}), /* @__PURE__ */ p(ne, {
|
|
785
785
|
permission: C ? t.WIDGET_ACTION_UPDATE : t.WIDGET_ACTION_CREATE,
|
|
786
786
|
deniedBehavior: "disable",
|
|
787
|
-
children: /* @__PURE__ */ p(
|
|
787
|
+
children: /* @__PURE__ */ p(ce, {
|
|
788
788
|
type: "submit",
|
|
789
789
|
disabled: x || !T.trim(),
|
|
790
790
|
style: {
|
|
@@ -797,7 +797,7 @@ var g = {
|
|
|
797
797
|
alignItems: "center",
|
|
798
798
|
gap: "var(--space-iconGap)"
|
|
799
799
|
},
|
|
800
|
-
children: [/* @__PURE__ */ p(
|
|
800
|
+
children: [/* @__PURE__ */ p(he, { style: {
|
|
801
801
|
height: "var(--size-icon-sm)",
|
|
802
802
|
width: "var(--size-icon-sm)"
|
|
803
803
|
} }), S("bigconsole.widget.actions.footer.saving", "Saving...")]
|