@burdenoff/microfe-bigconsole 2026.805.2 → 2026.805.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/components/builder/inspector/DataBindingSection.js +109 -113
- package/dist/bigconsole/components/builder/inspector/DataBindingSection.js.map +1 -1
- package/dist/bigconsole/components/dashboard/CreateDashboardDialog.js +115 -113
- package/dist/bigconsole/components/dashboard/CreateDashboardDialog.js.map +1 -1
- package/dist/bigconsole/components/dashboard/DashboardCanvas.js +71 -62
- package/dist/bigconsole/components/dashboard/DashboardCanvas.js.map +1 -1
- package/dist/bigconsole/components/dashboard/DashboardToolbar.js +90 -89
- package/dist/bigconsole/components/dashboard/DashboardToolbar.js.map +1 -1
- package/dist/bigconsole/components/dashboard/DrilldownBreadcrumb.js +56 -54
- package/dist/bigconsole/components/dashboard/DrilldownBreadcrumb.js.map +1 -1
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterChip.js +126 -125
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterChip.js.map +1 -1
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterEditor.js +151 -150
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterEditor.js.map +1 -1
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterPresetSelector.js +77 -76
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterPresetSelector.js.map +1 -1
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/GlobalFiltersBar.js +97 -96
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/GlobalFiltersBar.js.map +1 -1
- package/dist/bigconsole/components/dashboard/ImportDashboardDialog.js +172 -191
- package/dist/bigconsole/components/dashboard/ImportDashboardDialog.js.map +1 -1
- package/dist/bigconsole/components/dashboard/PublishToStoreDialog.js +75 -83
- package/dist/bigconsole/components/dashboard/PublishToStoreDialog.js.map +1 -1
- package/dist/bigconsole/components/dashboard/SavedViewsDropdown/SavedViewsDropdown.js +151 -154
- package/dist/bigconsole/components/dashboard/SavedViewsDropdown/SavedViewsDropdown.js.map +1 -1
- package/dist/bigconsole/components/dashboard/ShareDialog/EmbedTab.js +181 -190
- package/dist/bigconsole/components/dashboard/ShareDialog/EmbedTab.js.map +1 -1
- package/dist/bigconsole/components/dashboard/TemplatePicker/TemplatePicker.js +1 -0
- package/dist/bigconsole/components/dashboard/WidgetPalette.js +110 -108
- package/dist/bigconsole/components/dashboard/WidgetPalette.js.map +1 -1
- package/dist/bigconsole/components/datasink/CacheTTLSelector.js +102 -103
- package/dist/bigconsole/components/datasink/CacheTTLSelector.js.map +1 -1
- package/dist/bigconsole/components/datasink/DataSinkDeleteDialog.js +36 -41
- package/dist/bigconsole/components/datasink/DataSinkDeleteDialog.js.map +1 -1
- package/dist/bigconsole/components/datasink/DataSinkRefreshDialog.js +38 -37
- package/dist/bigconsole/components/datasink/DataSinkRefreshDialog.js.map +1 -1
- package/dist/bigconsole/components/datasink/ImportDataGuideDialog.js +113 -117
- package/dist/bigconsole/components/datasink/ImportDataGuideDialog.js.map +1 -1
- package/dist/bigconsole/components/datasink/ImportDataSinkDialog.js +182 -197
- package/dist/bigconsole/components/datasink/ImportDataSinkDialog.js.map +1 -1
- package/dist/bigconsole/components/datasink/RefreshTypeSelector.js +166 -168
- package/dist/bigconsole/components/datasink/RefreshTypeSelector.js.map +1 -1
- package/dist/bigconsole/components/parser/DataSinkSelector.js +87 -86
- package/dist/bigconsole/components/parser/DataSinkSelector.js.map +1 -1
- package/dist/bigconsole/components/parser/ImportParserDialog.js +196 -211
- package/dist/bigconsole/components/parser/ImportParserDialog.js.map +1 -1
- package/dist/bigconsole/components/parser/ParserSelector.js +130 -128
- package/dist/bigconsole/components/parser/ParserSelector.js.map +1 -1
- package/dist/bigconsole/components/preview/AiPreviewMiniPanel.js +66 -63
- package/dist/bigconsole/components/preview/AiPreviewMiniPanel.js.map +1 -1
- package/dist/bigconsole/components/preview/AiPreviewPanel.js +95 -91
- package/dist/bigconsole/components/preview/AiPreviewPanel.js.map +1 -1
- package/dist/bigconsole/components/widgets/ActionConfigDialog.js +222 -215
- package/dist/bigconsole/components/widgets/ActionConfigDialog.js.map +1 -1
- package/dist/bigconsole/components/widgets/DrilldownConfigPanel.js +149 -145
- package/dist/bigconsole/components/widgets/DrilldownConfigPanel.js.map +1 -1
- package/dist/bigconsole/components/widgets/PropertiesPanel.js +504 -470
- package/dist/bigconsole/components/widgets/PropertiesPanel.js.map +1 -1
- package/dist/bigconsole/components/widgets/calendar/CalendarWidget.js +44 -47
- package/dist/bigconsole/components/widgets/calendar/CalendarWidget.js.map +1 -1
- package/dist/bigconsole/components/widgets/chart/ChartConfig.js +143 -142
- package/dist/bigconsole/components/widgets/chart/ChartConfig.js.map +1 -1
- package/dist/bigconsole/components/widgets/comments/WidgetComments.js +101 -88
- package/dist/bigconsole/components/widgets/comments/WidgetComments.js.map +1 -1
- package/dist/bigconsole/components/widgets/event-logs/EventLogViewer.js +135 -134
- package/dist/bigconsole/components/widgets/event-logs/EventLogViewer.js.map +1 -1
- package/dist/bigconsole/components/widgets/form/FormWidget.js +167 -159
- package/dist/bigconsole/components/widgets/form/FormWidget.js.map +1 -1
- package/dist/bigconsole/components/widgets/gauge/GaugeConfig.js +69 -68
- package/dist/bigconsole/components/widgets/gauge/GaugeConfig.js.map +1 -1
- package/dist/bigconsole/components/widgets/heatmap/HeatmapConfig.js +64 -72
- package/dist/bigconsole/components/widgets/heatmap/HeatmapConfig.js.map +1 -1
- package/dist/bigconsole/components/widgets/kanban/KanbanWidget.js +60 -59
- package/dist/bigconsole/components/widgets/kanban/KanbanWidget.js.map +1 -1
- package/dist/bigconsole/components/widgets/list/ListConfig.js +57 -56
- package/dist/bigconsole/components/widgets/list/ListConfig.js.map +1 -1
- package/dist/bigconsole/components/widgets/metric-card/MetricCardConfig.js +70 -69
- package/dist/bigconsole/components/widgets/metric-card/MetricCardConfig.js.map +1 -1
- package/dist/bigconsole/components/widgets/metric-card/SparklineChart.js +35 -34
- package/dist/bigconsole/components/widgets/metric-card/SparklineChart.js.map +1 -1
- package/dist/bigconsole/components/widgets/metric-card/TrendIndicator.js +20 -19
- package/dist/bigconsole/components/widgets/metric-card/TrendIndicator.js.map +1 -1
- package/dist/bigconsole/components/widgets/pivot-table/PivotTableWidget.js +178 -177
- package/dist/bigconsole/components/widgets/pivot-table/PivotTableWidget.js.map +1 -1
- package/dist/bigconsole/components/widgets/progress/ProgressConfig.js +76 -75
- package/dist/bigconsole/components/widgets/progress/ProgressConfig.js.map +1 -1
- package/dist/bigconsole/components/widgets/table/TableConfig.js +183 -168
- package/dist/bigconsole/components/widgets/table/TableConfig.js.map +1 -1
- package/dist/bigconsole/components/widgets/webhook-config/WebhookConfigPanel.js +187 -180
- package/dist/bigconsole/components/widgets/webhook-config/WebhookConfigPanel.js.map +1 -1
- package/dist/bigconsole/customWidget/CustomWidgetBuilderSheet.js +40 -38
- package/dist/bigconsole/customWidget/CustomWidgetBuilderSheet.js.map +1 -1
- package/dist/bigconsole/customWidget/CustomWidgetProposalPanel.js +150 -148
- package/dist/bigconsole/customWidget/CustomWidgetProposalPanel.js.map +1 -1
- package/dist/bigconsole/pages/DashboardBuilderPage.js +181 -176
- package/dist/bigconsole/pages/DashboardBuilderPage.js.map +1 -1
- package/dist/bigconsole/pages/DashboardViewPage.js +196 -192
- package/dist/bigconsole/pages/DashboardViewPage.js.map +1 -1
- package/dist/bigconsole/pages/DashboardsPage.js +223 -219
- package/dist/bigconsole/pages/DashboardsPage.js.map +1 -1
- package/dist/bigconsole/pages/DataParsersPage.js +167 -170
- package/dist/bigconsole/pages/DataParsersPage.js.map +1 -1
- package/dist/bigconsole/pages/DataSinkBuilderPage.js +204 -189
- package/dist/bigconsole/pages/DataSinkBuilderPage.js.map +1 -1
- package/dist/bigconsole/pages/DataSinkViewPage.js +175 -169
- package/dist/bigconsole/pages/DataSinkViewPage.js.map +1 -1
- package/dist/bigconsole/pages/DataSourcesPage.js +8 -7
- package/dist/bigconsole/pages/DataSourcesPage.js.map +1 -1
- package/dist/bigconsole/pages/InsightsPage.js +238 -208
- package/dist/bigconsole/pages/InsightsPage.js.map +1 -1
- package/dist/bigconsole/pages/ParserBuilderPage.js +464 -412
- package/dist/bigconsole/pages/ParserBuilderPage.js.map +1 -1
- package/dist/bigconsole/pages/ParserViewPage.js +92 -90
- package/dist/bigconsole/pages/ParserViewPage.js.map +1 -1
- package/dist/bigconsole/pages/PipelineBuilderPage.js +221 -194
- package/dist/bigconsole/pages/PipelineBuilderPage.js.map +1 -1
- package/dist/bigconsole/pages/PipelineViewPage.js +181 -184
- package/dist/bigconsole/pages/PipelineViewPage.js.map +1 -1
- package/dist/bigconsole/pages/PipelinesPage.js +128 -127
- package/dist/bigconsole/pages/PipelinesPage.js.map +1 -1
- package/dist/bigconsole/pages/SettingsPage.js +177 -172
- package/dist/bigconsole/pages/SettingsPage.js.map +1 -1
- package/dist/bigconsole/pages/WidgetDemoPage.js +121 -83
- package/dist/bigconsole/pages/WidgetDemoPage.js.map +1 -1
- package/dist/bigconsole/pages/WorkflowViewPage.js +199 -193
- package/dist/bigconsole/pages/WorkflowViewPage.js.map +1 -1
- package/dist/bigconsole/pages/WorkflowsPage.js +129 -128
- package/dist/bigconsole/pages/WorkflowsPage.js.map +1 -1
- package/dist/bigconsole/renderers/adapters/AdaptiveCardRenderer.js +111 -109
- package/dist/bigconsole/renderers/adapters/AdaptiveCardRenderer.js.map +1 -1
- package/dist/bigconsole/renderers/adapters/BlockKitRenderer.js +127 -126
- package/dist/bigconsole/renderers/adapters/BlockKitRenderer.js.map +1 -1
- package/dist/bigconsole/renderers/adapters/CustomRenderer.js +103 -103
- package/dist/bigconsole/renderers/adapters/CustomRenderer.js.map +1 -1
- package/package.json +2 -1
|
@@ -20,75 +20,96 @@ import { AppearanceSection as ce } from "../builder/inspector/AppearanceSection.
|
|
|
20
20
|
import { GeneralSection as le } from "../builder/inspector/GeneralSection.js";
|
|
21
21
|
import { DataBindingSection as ue } from "../builder/inspector/DataBindingSection.js";
|
|
22
22
|
import "../builder/inspector/index.js";
|
|
23
|
-
import { memo as
|
|
24
|
-
import { Check as p, ChevronDown as pe, ChevronUp as me, ExternalLink as
|
|
25
|
-
import {
|
|
26
|
-
import {
|
|
23
|
+
import { memo as de, useCallback as l, useEffect as u, useMemo as d, useRef as fe, useState as f } from "react";
|
|
24
|
+
import { Check as p, ChevronDown as pe, ChevronUp as me, ExternalLink as he, Info as ge, Pencil as _e, Plus as ve, Trash2 as ye, X as be } from "lucide-react";
|
|
25
|
+
import { useI18n as xe } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
26
|
+
import { Button as m, Card as Se, CardContent as Ce, Input as h, Label as g, Select as we, SelectContent as Te, SelectItem as _, SelectTrigger as Ee, SelectValue as De, Sheet as Oe, SheetContent as ke, SheetDescription as Ae, SheetHeader as je, SheetTitle as Me, Spinner as v, Tabs as Ne, TabsContent as y, TabsList as Pe, TabsTrigger as b, Textarea as x } from "@burdenoff/fe-libs/ui";
|
|
27
|
+
import { Fragment as Fe, jsx as S, jsxs as C } from "react/jsx-runtime";
|
|
27
28
|
//#region src/bigconsole/components/widgets/PropertiesPanel.tsx
|
|
28
|
-
var
|
|
29
|
+
var Ie = [
|
|
29
30
|
{
|
|
30
31
|
value: "BIGCONSOLE",
|
|
32
|
+
labelKey: "bigconsole.widget.properties.renderer.bigconsole.label",
|
|
31
33
|
label: "BigConsole Native",
|
|
34
|
+
descriptionKey: "bigconsole.widget.properties.renderer.bigconsole.description",
|
|
32
35
|
description: "Full-featured native widgets"
|
|
33
36
|
},
|
|
34
37
|
{
|
|
35
38
|
value: "ADAPTIVE_CARD",
|
|
39
|
+
labelKey: "bigconsole.widget.properties.renderer.adaptiveCard.label",
|
|
36
40
|
label: "Adaptive Cards",
|
|
41
|
+
descriptionKey: "bigconsole.widget.properties.renderer.adaptiveCard.description",
|
|
37
42
|
description: "Microsoft Teams/Outlook format"
|
|
38
43
|
},
|
|
39
44
|
{
|
|
40
45
|
value: "BLOCKKIT",
|
|
46
|
+
labelKey: "bigconsole.widget.properties.renderer.blockKit.label",
|
|
41
47
|
label: "Block Kit",
|
|
48
|
+
descriptionKey: "bigconsole.widget.properties.renderer.blockKit.description",
|
|
42
49
|
description: "Slack format"
|
|
43
50
|
},
|
|
44
51
|
{
|
|
45
52
|
value: "CUSTOM",
|
|
53
|
+
labelKey: "bigconsole.widget.properties.renderer.custom.label",
|
|
46
54
|
label: "Custom",
|
|
55
|
+
descriptionKey: "bigconsole.widget.properties.renderer.custom.description",
|
|
47
56
|
description: "Custom React component"
|
|
48
57
|
}
|
|
49
|
-
],
|
|
58
|
+
], Le = [
|
|
50
59
|
{
|
|
51
60
|
value: "DATASINK",
|
|
61
|
+
labelKey: "bigconsole.widget.properties.dataSourceType.datasink.label",
|
|
52
62
|
label: "DataSink",
|
|
63
|
+
descriptionKey: "bigconsole.widget.properties.dataSourceType.datasink.description",
|
|
53
64
|
description: "Use data from BigConsole DataSinks"
|
|
54
65
|
},
|
|
55
66
|
{
|
|
56
67
|
value: "REST_API",
|
|
68
|
+
labelKey: "bigconsole.widget.properties.dataSourceType.restApi.label",
|
|
57
69
|
label: "REST API",
|
|
70
|
+
descriptionKey: "bigconsole.widget.properties.dataSourceType.restApi.description",
|
|
58
71
|
description: "Fetch data from REST endpoints"
|
|
59
72
|
},
|
|
60
73
|
{
|
|
61
74
|
value: "GRAPHQL",
|
|
75
|
+
labelKey: "bigconsole.widget.properties.dataSourceType.graphql.label",
|
|
62
76
|
label: "GraphQL",
|
|
77
|
+
descriptionKey: "bigconsole.widget.properties.dataSourceType.graphql.description",
|
|
63
78
|
description: "Query data using GraphQL"
|
|
64
79
|
},
|
|
65
80
|
{
|
|
66
81
|
value: "SQL",
|
|
82
|
+
labelKey: "bigconsole.widget.properties.dataSourceType.sql.label",
|
|
67
83
|
label: "SQL Database",
|
|
84
|
+
descriptionKey: "bigconsole.widget.properties.dataSourceType.sql.description",
|
|
68
85
|
description: "Query SQL databases directly"
|
|
69
86
|
},
|
|
70
87
|
{
|
|
71
88
|
value: "WEBSOCKET",
|
|
89
|
+
labelKey: "bigconsole.widget.properties.dataSourceType.websocket.label",
|
|
72
90
|
label: "WebSocket",
|
|
91
|
+
descriptionKey: "bigconsole.widget.properties.dataSourceType.websocket.description",
|
|
73
92
|
description: "Real-time data streaming"
|
|
74
93
|
},
|
|
75
94
|
{
|
|
76
95
|
value: "MOCK",
|
|
96
|
+
labelKey: "bigconsole.widget.properties.dataSourceType.mock.label",
|
|
77
97
|
label: "Sample JSON",
|
|
98
|
+
descriptionKey: "bigconsole.widget.properties.dataSourceType.mock.description",
|
|
78
99
|
description: "Manually enter sample JSON data"
|
|
79
100
|
}
|
|
80
101
|
];
|
|
81
|
-
function
|
|
102
|
+
function Re(e) {
|
|
82
103
|
return `widget:${e.toLowerCase().replace(/\s+/g, "_")}:clicked`;
|
|
83
104
|
}
|
|
84
|
-
var
|
|
105
|
+
var ze = {
|
|
85
106
|
PRIMARY: "bg-action-primary",
|
|
86
107
|
SECONDARY: "bg-muted-foreground",
|
|
87
108
|
SUCCESS: "bg-status-success-bg",
|
|
88
109
|
WARNING: "bg-status-warning-bg",
|
|
89
110
|
DANGER: "bg-status-error-bg"
|
|
90
111
|
};
|
|
91
|
-
function
|
|
112
|
+
function Be(e) {
|
|
92
113
|
if (!e) return {};
|
|
93
114
|
let t = Array.isArray(e) ? e[0] : e;
|
|
94
115
|
if (!t || typeof t != "object") return {};
|
|
@@ -132,75 +153,75 @@ function Ie(e) {
|
|
|
132
153
|
xAxisField: a
|
|
133
154
|
};
|
|
134
155
|
}
|
|
135
|
-
var
|
|
136
|
-
let
|
|
137
|
-
|
|
156
|
+
var Ve = de(function({ widget: e, onSave: t }) {
|
|
157
|
+
let { t: n } = xe(), [r, i] = f(""), [a, o] = f(null), s = fe(!1);
|
|
158
|
+
u(() => {
|
|
138
159
|
try {
|
|
139
|
-
|
|
160
|
+
i(e.template && typeof e.template == "object" ? JSON.stringify(e.template, null, 2) : ""), o(null), s.current = !0;
|
|
140
161
|
} catch {
|
|
141
|
-
|
|
162
|
+
i("");
|
|
142
163
|
}
|
|
143
164
|
}, [e.id, e.template]);
|
|
144
|
-
let
|
|
165
|
+
let c = l((e) => {
|
|
145
166
|
let n = e.target.value;
|
|
146
|
-
if (
|
|
167
|
+
if (i(n), n.trim() === "") o(null), t({});
|
|
147
168
|
else try {
|
|
148
169
|
let e = JSON.parse(n);
|
|
149
|
-
|
|
170
|
+
o(null), t(e);
|
|
150
171
|
} catch (e) {
|
|
151
|
-
|
|
172
|
+
o(e.message);
|
|
152
173
|
}
|
|
153
|
-
}, [t]),
|
|
174
|
+
}, [t]), ee = l(() => {
|
|
154
175
|
try {
|
|
155
|
-
let e = JSON.parse(
|
|
156
|
-
|
|
176
|
+
let e = JSON.parse(r);
|
|
177
|
+
i(JSON.stringify(e, null, 2)), o(null), t(e);
|
|
157
178
|
} catch (e) {
|
|
158
|
-
|
|
179
|
+
o(e.message);
|
|
159
180
|
}
|
|
160
|
-
}, [
|
|
161
|
-
return /* @__PURE__ */
|
|
181
|
+
}, [r, t]);
|
|
182
|
+
return /* @__PURE__ */ C("div", {
|
|
162
183
|
style: {
|
|
163
184
|
paddingTop: "var(--space-formGap)",
|
|
164
185
|
borderTop: "1px solid var(--color-border)"
|
|
165
186
|
},
|
|
166
187
|
children: [
|
|
167
|
-
/* @__PURE__ */
|
|
188
|
+
/* @__PURE__ */ C("div", {
|
|
168
189
|
style: {
|
|
169
190
|
display: "flex",
|
|
170
191
|
alignItems: "center",
|
|
171
192
|
justifyContent: "space-between",
|
|
172
193
|
marginBottom: "var(--space-controlGap)"
|
|
173
194
|
},
|
|
174
|
-
children: [/* @__PURE__ */
|
|
195
|
+
children: [/* @__PURE__ */ S("label", {
|
|
175
196
|
style: {
|
|
176
197
|
fontSize: "var(--font-size-body-sm)",
|
|
177
198
|
fontWeight: "var(--font-weight-semibold)",
|
|
178
199
|
color: "var(--color-text-primary)"
|
|
179
200
|
},
|
|
180
|
-
children: "Template (JSON)"
|
|
181
|
-
}),
|
|
201
|
+
children: n("bigconsole.widget.properties.template.label", "Template (JSON)")
|
|
202
|
+
}), a && /* @__PURE__ */ S("span", {
|
|
182
203
|
style: {
|
|
183
204
|
fontSize: "var(--font-size-body-sm)",
|
|
184
205
|
color: "var(--color-status-error-text)",
|
|
185
206
|
fontWeight: "var(--font-weight-medium)"
|
|
186
207
|
},
|
|
187
|
-
children: "Invalid JSON"
|
|
208
|
+
children: n("bigconsole.widget.properties.template.invalidJson", "Invalid JSON")
|
|
188
209
|
})]
|
|
189
210
|
}),
|
|
190
|
-
/* @__PURE__ */
|
|
191
|
-
value:
|
|
192
|
-
onChange:
|
|
211
|
+
/* @__PURE__ */ S(x, {
|
|
212
|
+
value: r,
|
|
213
|
+
onChange: c,
|
|
193
214
|
spellCheck: !1,
|
|
194
|
-
placeholder:
|
|
215
|
+
placeholder: n("bigconsole.widget.properties.template.placeholder", "Enter {{renderer}} template JSON...", { renderer: e.renderer ?? "" }),
|
|
195
216
|
style: {
|
|
196
217
|
fontFamily: "var(--font-family-mono)",
|
|
197
218
|
fontSize: "var(--font-size-body-sm)",
|
|
198
219
|
minHeight: "180px",
|
|
199
|
-
borderColor:
|
|
220
|
+
borderColor: a ? "var(--color-status-error-border)" : void 0,
|
|
200
221
|
resize: "vertical"
|
|
201
222
|
}
|
|
202
223
|
}),
|
|
203
|
-
|
|
224
|
+
a && /* @__PURE__ */ S("p", {
|
|
204
225
|
style: {
|
|
205
226
|
fontSize: "var(--font-size-body-sm)",
|
|
206
227
|
color: "var(--color-status-error-text)",
|
|
@@ -209,26 +230,26 @@ var Le = l(function({ widget: e, onSave: t }) {
|
|
|
209
230
|
borderRadius: "var(--radius-button)",
|
|
210
231
|
marginTop: "var(--space-controlGap)"
|
|
211
232
|
},
|
|
212
|
-
children:
|
|
233
|
+
children: a
|
|
213
234
|
}),
|
|
214
|
-
/* @__PURE__ */
|
|
235
|
+
/* @__PURE__ */ C("div", {
|
|
215
236
|
style: {
|
|
216
237
|
display: "flex",
|
|
217
238
|
alignItems: "center",
|
|
218
239
|
gap: "var(--space-controlGap)",
|
|
219
240
|
marginTop: "var(--space-controlGap)"
|
|
220
241
|
},
|
|
221
|
-
children: [/* @__PURE__ */
|
|
242
|
+
children: [/* @__PURE__ */ S(m, {
|
|
222
243
|
variant: "outline",
|
|
223
244
|
size: "sm",
|
|
224
|
-
onClick:
|
|
225
|
-
disabled: !!
|
|
245
|
+
onClick: ee,
|
|
246
|
+
disabled: !!a || r.trim() === "",
|
|
226
247
|
style: {
|
|
227
248
|
height: "var(--size-controlHeight-sm)",
|
|
228
249
|
fontWeight: "var(--font-weight-semibold)"
|
|
229
250
|
},
|
|
230
|
-
children: "Format"
|
|
231
|
-
}), !
|
|
251
|
+
children: n("bigconsole.widget.properties.template.format", "Format")
|
|
252
|
+
}), !a && r.trim() !== "" && /* @__PURE__ */ C("span", {
|
|
232
253
|
style: {
|
|
233
254
|
fontSize: "var(--font-size-body-sm)",
|
|
234
255
|
color: "var(--color-status-success-text)",
|
|
@@ -236,13 +257,13 @@ var Le = l(function({ widget: e, onSave: t }) {
|
|
|
236
257
|
alignItems: "center",
|
|
237
258
|
gap: "4px"
|
|
238
259
|
},
|
|
239
|
-
children: [/* @__PURE__ */
|
|
260
|
+
children: [/* @__PURE__ */ S(p, { style: {
|
|
240
261
|
width: "12px",
|
|
241
262
|
height: "12px"
|
|
242
|
-
} }), "Valid JSON"]
|
|
263
|
+
} }), n("bigconsole.widget.properties.template.validJson", "Valid JSON")]
|
|
243
264
|
})]
|
|
244
265
|
}),
|
|
245
|
-
/* @__PURE__ */
|
|
266
|
+
/* @__PURE__ */ C("div", {
|
|
246
267
|
style: {
|
|
247
268
|
display: "flex",
|
|
248
269
|
alignItems: "center",
|
|
@@ -254,11 +275,11 @@ var Le = l(function({ widget: e, onSave: t }) {
|
|
|
254
275
|
borderTop: "1px solid var(--color-border)"
|
|
255
276
|
},
|
|
256
277
|
children: [
|
|
257
|
-
/* @__PURE__ */
|
|
278
|
+
/* @__PURE__ */ S("span", {
|
|
258
279
|
style: { fontWeight: "var(--font-weight-medium)" },
|
|
259
|
-
children: "Ctrl+S to save"
|
|
280
|
+
children: n("bigconsole.widget.properties.template.ctrlSToSave", "Ctrl+S to save")
|
|
260
281
|
}),
|
|
261
|
-
e.renderer === "ADAPTIVE_CARD" && /* @__PURE__ */
|
|
282
|
+
e.renderer === "ADAPTIVE_CARD" && /* @__PURE__ */ C("a", {
|
|
262
283
|
href: "https://adaptivecards.io/designer/",
|
|
263
284
|
target: "_blank",
|
|
264
285
|
rel: "noopener noreferrer",
|
|
@@ -271,12 +292,12 @@ var Le = l(function({ widget: e, onSave: t }) {
|
|
|
271
292
|
fontWeight: "var(--font-weight-medium)",
|
|
272
293
|
textDecoration: "none"
|
|
273
294
|
},
|
|
274
|
-
children: ["Designer", /* @__PURE__ */
|
|
295
|
+
children: [n("bigconsole.widget.properties.template.designer", "Designer"), /* @__PURE__ */ S(he, { style: {
|
|
275
296
|
height: "var(--size-icon-sm)",
|
|
276
297
|
width: "var(--size-icon-sm)"
|
|
277
298
|
} })]
|
|
278
299
|
}),
|
|
279
|
-
e.renderer === "BLOCKKIT" && /* @__PURE__ */
|
|
300
|
+
e.renderer === "BLOCKKIT" && /* @__PURE__ */ C("a", {
|
|
280
301
|
href: "https://app.slack.com/block-kit-builder",
|
|
281
302
|
target: "_blank",
|
|
282
303
|
rel: "noopener noreferrer",
|
|
@@ -289,7 +310,7 @@ var Le = l(function({ widget: e, onSave: t }) {
|
|
|
289
310
|
fontWeight: "var(--font-weight-medium)",
|
|
290
311
|
textDecoration: "none"
|
|
291
312
|
},
|
|
292
|
-
children: ["Block Kit Builder", /* @__PURE__ */
|
|
313
|
+
children: [n("bigconsole.widget.properties.template.blockKitBuilder", "Block Kit Builder"), /* @__PURE__ */ S(he, { style: {
|
|
293
314
|
height: "var(--size-icon-sm)",
|
|
294
315
|
width: "var(--size-icon-sm)"
|
|
295
316
|
} })]
|
|
@@ -299,7 +320,7 @@ var Le = l(function({ widget: e, onSave: t }) {
|
|
|
299
320
|
]
|
|
300
321
|
});
|
|
301
322
|
});
|
|
302
|
-
function
|
|
323
|
+
function He(e) {
|
|
303
324
|
let t = e, n = c({
|
|
304
325
|
dataSinkId: t.dataSinkId,
|
|
305
326
|
parserId: t.parserId,
|
|
@@ -327,252 +348,255 @@ function Re(e) {
|
|
|
327
348
|
} : void 0
|
|
328
349
|
};
|
|
329
350
|
}
|
|
330
|
-
var
|
|
331
|
-
let [
|
|
332
|
-
|
|
333
|
-
if (!
|
|
334
|
-
|
|
351
|
+
var w = de(function({ isOpen: de, onClose: he }) {
|
|
352
|
+
let { t: w } = xe(), [Ue, We] = f("general"), [T, E] = f("idle"), [D, O] = f(null), [k, A] = f(!1), j = e((e) => e.selectedWidgetId), Ge = e((e) => e.widgets), M = e((e) => e.updateWidget), N = j ? Ge.get(j) : void 0, P = fe(null), F = fe({});
|
|
353
|
+
u(() => {
|
|
354
|
+
if (!j) {
|
|
355
|
+
P.current = null, O(null), A(!1), E("idle");
|
|
335
356
|
return;
|
|
336
357
|
}
|
|
337
|
-
let e =
|
|
338
|
-
if (
|
|
339
|
-
if (
|
|
340
|
-
|
|
341
|
-
} else
|
|
358
|
+
let e = P.current !== j;
|
|
359
|
+
if (P.current = j, N) {
|
|
360
|
+
if (k && !e) return;
|
|
361
|
+
O(He(N)), F.current = N.config || {}, A(!1), E("idle");
|
|
362
|
+
} else O(null), A(!1), E("idle");
|
|
342
363
|
}, [
|
|
364
|
+
j,
|
|
343
365
|
N,
|
|
344
|
-
|
|
345
|
-
j
|
|
366
|
+
k
|
|
346
367
|
]);
|
|
347
|
-
let { updateWidget:
|
|
348
|
-
consoleId:
|
|
368
|
+
let { updateWidget: Ke } = n(N?.pageId, N?.dashboardId, { skipFetch: !0 }), { createDrilldown: qe, updateDrilldown: Je, deleteDrilldown: Ye } = r(), { dataSinks: I } = o({ skipFetch: !1 }), [Xe, L] = f(null), { executeParser: Ze } = s({
|
|
369
|
+
consoleId: N?.dashboardId,
|
|
349
370
|
skipFetch: !0
|
|
350
|
-
}), [
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
}, [
|
|
354
|
-
let { actions:
|
|
355
|
-
widgetId:
|
|
356
|
-
skipFetch: !
|
|
357
|
-
}), G =
|
|
358
|
-
let n =
|
|
359
|
-
return e.find((e) => e.widgetId ===
|
|
360
|
-
}, [
|
|
361
|
-
if (!
|
|
362
|
-
let n =
|
|
363
|
-
return !r &&
|
|
371
|
+
}), [Qe, R] = f(!1), [$e, z] = f(void 0), [et, B] = f(!1), [tt, V] = f(null);
|
|
372
|
+
u(() => {
|
|
373
|
+
z(void 0), B(!1), V(null), R(!1);
|
|
374
|
+
}, [j]);
|
|
375
|
+
let { actions: H, loading: nt, createAction: rt, updateAction: it, deleteAction: at, reorderActions: U } = i(j || void 0), { webhooks: ot, loading: st, createWebhook: ct, updateWebhook: lt, deleteWebhook: W, refetch: ut } = a({
|
|
376
|
+
widgetId: j || void 0,
|
|
377
|
+
skipFetch: !j
|
|
378
|
+
}), G = l((e, t) => {
|
|
379
|
+
let n = Re(t);
|
|
380
|
+
return e.find((e) => e.widgetId === j && e.eventPattern === n) ?? null;
|
|
381
|
+
}, [j]), K = l((e) => G(ot, e), [G, ot]), dt = l(async (e, t) => {
|
|
382
|
+
if (!j || t === void 0) return !0;
|
|
383
|
+
let n = Re(e), r = K(e);
|
|
384
|
+
return !r && st && (r = G((await ut())?.data?.listEventWebhookMappings ?? [], e)), t && t.url ? r ? await lt({
|
|
364
385
|
id: r.id,
|
|
365
386
|
eventPattern: n,
|
|
366
387
|
webhookUrl: t.url,
|
|
367
388
|
method: t.method,
|
|
368
389
|
isActive: !0
|
|
369
|
-
}) !== null : await
|
|
370
|
-
widgetId:
|
|
390
|
+
}) !== null : await ct({
|
|
391
|
+
widgetId: j,
|
|
371
392
|
eventPattern: n,
|
|
372
393
|
webhookUrl: t.url,
|
|
373
394
|
method: t.method
|
|
374
395
|
}) !== null : t === null && r ? W(r.id) : !0;
|
|
375
396
|
}, [
|
|
376
|
-
|
|
397
|
+
j,
|
|
377
398
|
K,
|
|
378
|
-
at,
|
|
379
|
-
ct,
|
|
380
|
-
G,
|
|
381
|
-
ot,
|
|
382
399
|
st,
|
|
400
|
+
ut,
|
|
401
|
+
G,
|
|
402
|
+
ct,
|
|
403
|
+
lt,
|
|
383
404
|
W
|
|
384
|
-
]), [
|
|
405
|
+
]), [ft, q] = f(!1), [J, Y] = f(void 0), [pt, mt] = f(!1), [ht, X] = f(void 0), [gt, Z] = f(null), _t = d(() => {
|
|
385
406
|
if (!J) return null;
|
|
386
407
|
let e = K(J.name);
|
|
387
408
|
return e ? {
|
|
388
409
|
url: e.webhookUrl,
|
|
389
410
|
method: e.method
|
|
390
411
|
} : null;
|
|
391
|
-
}, [J, K]),
|
|
412
|
+
}, [J, K]), vt = ht === void 0 ? _t : ht, yt = d(() => {
|
|
392
413
|
let e = /* @__PURE__ */ new Map();
|
|
393
|
-
for (let t of
|
|
414
|
+
for (let t of H) {
|
|
394
415
|
let n = K(t.name);
|
|
395
416
|
n && e.set(t.name, n);
|
|
396
417
|
}
|
|
397
418
|
return e;
|
|
398
|
-
}, [
|
|
419
|
+
}, [H, K]), bt = l(() => {
|
|
399
420
|
X(void 0), Z(null), Y(void 0), q(!0);
|
|
400
|
-
}, []),
|
|
421
|
+
}, []), xt = l((e) => {
|
|
401
422
|
X(void 0), Z(null), Y(e), q(!0);
|
|
402
|
-
}, []),
|
|
403
|
-
if (
|
|
404
|
-
|
|
423
|
+
}, []), St = l(async (e, t) => {
|
|
424
|
+
if (j) {
|
|
425
|
+
mt(!0), Z(null);
|
|
405
426
|
try {
|
|
406
427
|
let n = "id" in e && !!e.id, r = null;
|
|
407
|
-
if (r = n ? await
|
|
408
|
-
let e = [...
|
|
428
|
+
if (r = n ? await it(e) : await rt(e), r) {
|
|
429
|
+
let e = [...H];
|
|
409
430
|
if (n) {
|
|
410
431
|
let t = e.findIndex((e) => e.id === r?.id);
|
|
411
432
|
t >= 0 && (e[t] = r);
|
|
412
433
|
} else e.push(r);
|
|
413
|
-
if (
|
|
414
|
-
X(t), Z(t ? "The button was saved, but its webhook could not be saved. Check the URL and try again." : "The button was saved, but its old webhook could not be removed. Try again."), Y(r);
|
|
434
|
+
if (M(j, { actions: e.sort((e, t) => e.order - t.order) }), !await dt(r.name, t)) {
|
|
435
|
+
X(t), Z(t ? w("bigconsole.widget.properties.action.webhookSaveFailed", "The button was saved, but its webhook could not be saved. Check the URL and try again.") : w("bigconsole.widget.properties.action.webhookRemoveFailed", "The button was saved, but its old webhook could not be removed. Try again.")), Y(r);
|
|
415
436
|
return;
|
|
416
437
|
}
|
|
417
438
|
X(void 0), Z(null), q(!1), Y(void 0);
|
|
418
439
|
}
|
|
419
440
|
} catch (e) {
|
|
420
|
-
console.warn("Failed to save widget action:", e), Z(e instanceof Error ? e.message : "Could not save the button. Please try again.");
|
|
441
|
+
console.warn("Failed to save widget action:", e), Z(e instanceof Error ? e.message : w("bigconsole.widget.properties.action.saveFailed", "Could not save the button. Please try again."));
|
|
421
442
|
} finally {
|
|
422
|
-
|
|
443
|
+
mt(!1);
|
|
423
444
|
}
|
|
424
445
|
}
|
|
425
446
|
}, [
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
447
|
+
j,
|
|
448
|
+
H,
|
|
449
|
+
rt,
|
|
450
|
+
it,
|
|
451
|
+
M,
|
|
452
|
+
dt,
|
|
453
|
+
w
|
|
454
|
+
]), Ct = l(async (e) => {
|
|
455
|
+
if (j && window.confirm(w("bigconsole.widget.properties.action.deleteConfirm", "Are you sure you want to delete this action?"))) {
|
|
456
|
+
let t = H.find((t) => t.id === e);
|
|
457
|
+
if (await at(e) && (M(j, { actions: H.filter((t) => t.id !== e) }), t)) {
|
|
436
458
|
let e = K(t.name);
|
|
437
459
|
e && await W(e.id);
|
|
438
460
|
}
|
|
439
461
|
}
|
|
440
462
|
}, [
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
463
|
+
j,
|
|
464
|
+
H,
|
|
465
|
+
at,
|
|
466
|
+
M,
|
|
445
467
|
K,
|
|
446
|
-
W
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
468
|
+
W,
|
|
469
|
+
w
|
|
470
|
+
]), wt = l(async (e) => {
|
|
471
|
+
if (!j || e === 0) return;
|
|
472
|
+
let t = [...H].sort((e, t) => e.order - t.order), n = t.map((e) => e.id);
|
|
473
|
+
[n[e - 1], n[e]] = [n[e], n[e - 1]], await U(n) && M(j, { actions: t.map((e, t) => ({
|
|
451
474
|
...e,
|
|
452
475
|
order: n.indexOf(e.id)
|
|
453
476
|
})).sort((e, t) => e.order - t.order) });
|
|
454
477
|
}, [
|
|
455
|
-
|
|
456
|
-
|
|
478
|
+
j,
|
|
479
|
+
H,
|
|
457
480
|
U,
|
|
458
|
-
|
|
459
|
-
]),
|
|
460
|
-
if (!
|
|
461
|
-
let t = [...
|
|
481
|
+
M
|
|
482
|
+
]), Tt = l(async (e) => {
|
|
483
|
+
if (!j) return;
|
|
484
|
+
let t = [...H].sort((e, t) => e.order - t.order);
|
|
462
485
|
if (e === t.length - 1) return;
|
|
463
486
|
let n = t.map((e) => e.id);
|
|
464
|
-
[n[e], n[e + 1]] = [n[e + 1], n[e]], await U(n) &&
|
|
487
|
+
[n[e], n[e + 1]] = [n[e + 1], n[e]], await U(n) && M(j, { actions: t.map((e, t) => ({
|
|
465
488
|
...e,
|
|
466
489
|
order: n.indexOf(e.id)
|
|
467
490
|
})).sort((e, t) => e.order - t.order) });
|
|
468
491
|
}, [
|
|
469
|
-
|
|
470
|
-
|
|
492
|
+
j,
|
|
493
|
+
H,
|
|
471
494
|
U,
|
|
472
|
-
|
|
495
|
+
M
|
|
473
496
|
]);
|
|
474
|
-
|
|
475
|
-
|
|
497
|
+
u(() => {
|
|
498
|
+
j && H.length >= 0 && !nt && M(j, { actions: H });
|
|
476
499
|
}, [
|
|
477
|
-
|
|
478
|
-
V,
|
|
500
|
+
j,
|
|
479
501
|
H,
|
|
480
|
-
|
|
502
|
+
nt,
|
|
503
|
+
M
|
|
481
504
|
]);
|
|
482
|
-
let Q =
|
|
483
|
-
|
|
505
|
+
let Q = l((e, t) => {
|
|
506
|
+
O((n) => n && {
|
|
484
507
|
...n,
|
|
485
508
|
[e]: t
|
|
486
|
-
}),
|
|
487
|
-
}, []), $ =
|
|
488
|
-
|
|
509
|
+
}), A(!0);
|
|
510
|
+
}, []), $ = l((e) => {
|
|
511
|
+
O((t) => t && {
|
|
489
512
|
...t,
|
|
490
513
|
config: e
|
|
491
|
-
}),
|
|
514
|
+
}), A(!0);
|
|
492
515
|
}, []);
|
|
493
|
-
|
|
494
|
-
if (
|
|
495
|
-
let e =
|
|
496
|
-
e &&
|
|
497
|
-
} else
|
|
498
|
-
}, [
|
|
499
|
-
let
|
|
500
|
-
if (
|
|
501
|
-
let t =
|
|
502
|
-
t && (Q("dataSinkId", t.id),
|
|
516
|
+
u(() => {
|
|
517
|
+
if (D?.dataSinkId && I.length > 0) {
|
|
518
|
+
let e = I.find((e) => e.id === D.dataSinkId);
|
|
519
|
+
e && L(e.key);
|
|
520
|
+
} else L(null);
|
|
521
|
+
}, [D?.dataSinkId, I]);
|
|
522
|
+
let Et = l((e) => {
|
|
523
|
+
if (z(void 0), B(!1), V(null), L(e), e) {
|
|
524
|
+
let t = I.find((t) => t.key === e);
|
|
525
|
+
t && (Q("dataSinkId", t.id), O((t) => t && {
|
|
503
526
|
...t,
|
|
504
527
|
config: {
|
|
505
528
|
...t.config,
|
|
506
529
|
dataSinkKey: e
|
|
507
530
|
}
|
|
508
|
-
}),
|
|
509
|
-
} else Q("dataSinkId", void 0),
|
|
531
|
+
}), A(!0));
|
|
532
|
+
} else Q("dataSinkId", void 0), O((e) => e && {
|
|
510
533
|
...e,
|
|
511
534
|
config: {
|
|
512
535
|
...e.config,
|
|
513
536
|
dataSinkKey: void 0
|
|
514
537
|
},
|
|
515
538
|
parserId: void 0
|
|
516
|
-
}),
|
|
517
|
-
}, [
|
|
518
|
-
if (Q("parserId", e || void 0),
|
|
519
|
-
|
|
539
|
+
}), A(!0);
|
|
540
|
+
}, [I, Q]), Dt = l(async (e) => {
|
|
541
|
+
if (Q("parserId", e || void 0), z(void 0), B(!1), V(null), e && N) {
|
|
542
|
+
R(!0);
|
|
520
543
|
try {
|
|
521
|
-
let t = await
|
|
544
|
+
let t = await Ze(e);
|
|
522
545
|
if (t?.success) {
|
|
523
|
-
|
|
524
|
-
let e =
|
|
525
|
-
(e.labelField || e.valueField) && (
|
|
546
|
+
z(t.output), B(!0);
|
|
547
|
+
let e = Be(t.output);
|
|
548
|
+
(e.labelField || e.valueField) && (O((t) => {
|
|
526
549
|
if (!t) return t;
|
|
527
550
|
let n = t.config || {}, r = { ...n };
|
|
528
551
|
return e.labelField && !n.labelField && (r.labelField = e.labelField), e.valueField && !n.valueField && (r.valueField = e.valueField), e.xAxisField && !n.xAxisField && (r.xAxisField = e.xAxisField), {
|
|
529
552
|
...t,
|
|
530
553
|
config: r
|
|
531
554
|
};
|
|
532
|
-
}),
|
|
533
|
-
} else
|
|
555
|
+
}), A(!0));
|
|
556
|
+
} else B(!0), V(t?.error || w("bigconsole.widget.properties.parser.previewFailed", "The parser could not produce a preview."));
|
|
534
557
|
} catch (e) {
|
|
535
|
-
|
|
558
|
+
B(!0), V(e instanceof Error ? e.message : w("bigconsole.widget.properties.parser.previewFailed", "The parser could not produce a preview.")), console.warn("Failed to auto-detect parser fields:", e);
|
|
536
559
|
} finally {
|
|
537
|
-
|
|
560
|
+
R(!1);
|
|
538
561
|
}
|
|
539
562
|
}
|
|
540
563
|
}, [
|
|
541
564
|
Q,
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
565
|
+
Ze,
|
|
566
|
+
N,
|
|
567
|
+
w
|
|
568
|
+
]), Ot = l(async () => {
|
|
569
|
+
if (!(!N || !D)) {
|
|
570
|
+
E("saving");
|
|
547
571
|
try {
|
|
548
572
|
let t = {
|
|
549
|
-
...
|
|
550
|
-
description:
|
|
551
|
-
}, n = te(e.getState().widgets.get(
|
|
552
|
-
dataSinkId:
|
|
553
|
-
parserId:
|
|
573
|
+
...N.metadata || {},
|
|
574
|
+
description: D.description || ""
|
|
575
|
+
}, n = te(e.getState().widgets.get(N.id)?.config ?? {}, F.current, D.config), r = ne(c({
|
|
576
|
+
dataSinkId: D.dataSinkId,
|
|
577
|
+
parserId: D.parserId,
|
|
554
578
|
config: {
|
|
555
579
|
...n,
|
|
556
580
|
binding: void 0
|
|
557
581
|
}
|
|
558
|
-
}), n), i = await
|
|
559
|
-
id:
|
|
560
|
-
title:
|
|
561
|
-
renderer:
|
|
562
|
-
template:
|
|
582
|
+
}), n), i = await Ke({
|
|
583
|
+
id: N.id,
|
|
584
|
+
title: D.title,
|
|
585
|
+
renderer: D.renderer,
|
|
586
|
+
template: D.template,
|
|
563
587
|
config: r.config,
|
|
564
|
-
refreshInterval:
|
|
588
|
+
refreshInterval: D.refreshInterval,
|
|
565
589
|
dataSinkId: r.dataSinkId,
|
|
566
|
-
datasetId:
|
|
590
|
+
datasetId: D.datasetId,
|
|
567
591
|
parserId: r.parserId,
|
|
568
|
-
parserRules:
|
|
592
|
+
parserRules: D.parserRules,
|
|
569
593
|
metadata: t
|
|
570
|
-
}), a =
|
|
571
|
-
if (
|
|
572
|
-
let { enabled: e, targetDashboardId: t, navigationMode: n, parameterMapping: r, passGlobalFilters: i, maxDepth: o, openIn: s } =
|
|
573
|
-
if (
|
|
574
|
-
let c = await
|
|
575
|
-
id:
|
|
594
|
+
}), a = N.drilldown;
|
|
595
|
+
if (D.drilldownConfig) {
|
|
596
|
+
let { enabled: e, targetDashboardId: t, navigationMode: n, parameterMapping: r, passGlobalFilters: i, maxDepth: o, openIn: s } = D.drilldownConfig;
|
|
597
|
+
if (N.drilldown?.id) {
|
|
598
|
+
let c = await Je({
|
|
599
|
+
id: N.drilldown.id,
|
|
576
600
|
targetDashboardId: t,
|
|
577
601
|
parameterMapping: r,
|
|
578
602
|
navigationMode: n,
|
|
@@ -583,8 +607,8 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
583
607
|
});
|
|
584
608
|
c && (a = c);
|
|
585
609
|
} else if (t) {
|
|
586
|
-
let c = await
|
|
587
|
-
sourceWidgetId:
|
|
610
|
+
let c = await qe({
|
|
611
|
+
sourceWidgetId: N.id,
|
|
588
612
|
targetDashboardId: t,
|
|
589
613
|
parameterMapping: r || {},
|
|
590
614
|
navigationMode: n,
|
|
@@ -597,48 +621,55 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
597
621
|
enabled: e
|
|
598
622
|
});
|
|
599
623
|
}
|
|
600
|
-
} else
|
|
601
|
-
i ? (
|
|
602
|
-
title:
|
|
603
|
-
description:
|
|
604
|
-
renderer:
|
|
605
|
-
template:
|
|
624
|
+
} else N.drilldown?.id && !D.drilldownConfig && (await Ye(N.drilldown.id), a = void 0);
|
|
625
|
+
i ? (M(N.id, {
|
|
626
|
+
title: D.title,
|
|
627
|
+
description: D.description,
|
|
628
|
+
renderer: D.renderer,
|
|
629
|
+
template: D.template,
|
|
606
630
|
config: r.config,
|
|
607
|
-
refreshInterval:
|
|
631
|
+
refreshInterval: D.refreshInterval,
|
|
608
632
|
dataSinkId: r.dataSinkId,
|
|
609
|
-
datasetId:
|
|
633
|
+
datasetId: D.datasetId,
|
|
610
634
|
parserId: r.parserId,
|
|
611
|
-
parserRules:
|
|
635
|
+
parserRules: D.parserRules,
|
|
612
636
|
drilldown: a,
|
|
613
637
|
updatedAt: (/* @__PURE__ */ new Date()).toISOString()
|
|
614
|
-
}),
|
|
638
|
+
}), E("saved"), A(!1), setTimeout(() => E("idle"), 2e3)) : E("error");
|
|
615
639
|
} catch {
|
|
616
|
-
|
|
640
|
+
E("error");
|
|
617
641
|
}
|
|
618
642
|
}
|
|
619
643
|
}, [
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
]),
|
|
628
|
-
|
|
629
|
-
}, [
|
|
644
|
+
N,
|
|
645
|
+
D,
|
|
646
|
+
Ke,
|
|
647
|
+
M,
|
|
648
|
+
qe,
|
|
649
|
+
Je,
|
|
650
|
+
Ye
|
|
651
|
+
]), kt = l(() => {
|
|
652
|
+
N && (O(He(N)), F.current = N.config || {}, A(!1), E("idle"));
|
|
653
|
+
}, [N]), At = l((e) => {
|
|
630
654
|
$(e);
|
|
631
|
-
}, [$]),
|
|
632
|
-
|
|
655
|
+
}, [$]), jt = l((e) => {
|
|
656
|
+
O((t) => t && {
|
|
633
657
|
...t,
|
|
634
658
|
drilldownConfig: e
|
|
635
|
-
}),
|
|
636
|
-
}, []),
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
659
|
+
}), A(!0);
|
|
660
|
+
}, []), Mt = N ? t(N.type) : null, Nt = d(() => Ie.map((e) => ({
|
|
661
|
+
value: e.value,
|
|
662
|
+
label: w(e.labelKey, e.label),
|
|
663
|
+
description: w(e.descriptionKey, e.description)
|
|
664
|
+
})), [w]), Pt = d(() => Le.map((e) => ({
|
|
665
|
+
value: e.value,
|
|
666
|
+
label: w(e.labelKey, e.label)
|
|
667
|
+
})), [w]);
|
|
668
|
+
return /* @__PURE__ */ S(Oe, {
|
|
669
|
+
open: de,
|
|
670
|
+
onOpenChange: (e) => !e && he(),
|
|
640
671
|
modal: !1,
|
|
641
|
-
children: /* @__PURE__ */
|
|
672
|
+
children: /* @__PURE__ */ C(ke, {
|
|
642
673
|
style: {
|
|
643
674
|
width: "420px",
|
|
644
675
|
maxWidth: "90vw",
|
|
@@ -649,20 +680,20 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
649
680
|
overflow: "hidden"
|
|
650
681
|
},
|
|
651
682
|
children: [
|
|
652
|
-
/* @__PURE__ */
|
|
683
|
+
/* @__PURE__ */ S(je, {
|
|
653
684
|
style: {
|
|
654
685
|
padding: "var(--space-cardPadding)",
|
|
655
686
|
borderBottom: "1px solid var(--color-border)",
|
|
656
687
|
backgroundColor: "var(--color-bg-surface)",
|
|
657
688
|
flexShrink: 0
|
|
658
689
|
},
|
|
659
|
-
children: /* @__PURE__ */
|
|
690
|
+
children: /* @__PURE__ */ C("div", {
|
|
660
691
|
style: {
|
|
661
692
|
display: "flex",
|
|
662
693
|
alignItems: "center",
|
|
663
694
|
gap: "var(--space-controlGap)"
|
|
664
695
|
},
|
|
665
|
-
children: [/* @__PURE__ */
|
|
696
|
+
children: [/* @__PURE__ */ S("div", {
|
|
666
697
|
style: {
|
|
667
698
|
display: "flex",
|
|
668
699
|
height: "var(--size-controlHeight-lg)",
|
|
@@ -674,62 +705,62 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
674
705
|
boxShadow: "var(--shadow-elevation-2)",
|
|
675
706
|
flexShrink: 0
|
|
676
707
|
},
|
|
677
|
-
children: /* @__PURE__ */
|
|
708
|
+
children: /* @__PURE__ */ S(ge, { style: {
|
|
678
709
|
height: "var(--size-icon-md)",
|
|
679
710
|
width: "var(--size-icon-md)",
|
|
680
711
|
color: "var(--color-action-primary-text)"
|
|
681
712
|
} })
|
|
682
|
-
}), /* @__PURE__ */
|
|
713
|
+
}), /* @__PURE__ */ C("div", {
|
|
683
714
|
style: {
|
|
684
715
|
flex: 1,
|
|
685
716
|
minWidth: 0
|
|
686
717
|
},
|
|
687
|
-
children: [/* @__PURE__ */
|
|
718
|
+
children: [/* @__PURE__ */ C("div", {
|
|
688
719
|
style: {
|
|
689
720
|
display: "flex",
|
|
690
721
|
alignItems: "center",
|
|
691
722
|
gap: "var(--space-iconGap)"
|
|
692
723
|
},
|
|
693
724
|
children: [
|
|
694
|
-
/* @__PURE__ */
|
|
725
|
+
/* @__PURE__ */ S(Me, {
|
|
695
726
|
style: {
|
|
696
727
|
fontSize: "var(--font-size-body-md)",
|
|
697
728
|
fontWeight: "var(--font-weight-bold)",
|
|
698
729
|
color: "var(--color-text-primary)",
|
|
699
730
|
margin: 0
|
|
700
731
|
},
|
|
701
|
-
children:
|
|
732
|
+
children: N ? w("bigconsole.widget.properties.header.widgetProperties", "Widget Properties") : w("bigconsole.widget.properties.header.properties", "Properties")
|
|
702
733
|
}),
|
|
703
|
-
|
|
734
|
+
T === "saving" && /* @__PURE__ */ S(v, { style: {
|
|
704
735
|
height: "var(--size-icon-sm)",
|
|
705
736
|
width: "var(--size-icon-sm)"
|
|
706
737
|
} }),
|
|
707
|
-
|
|
738
|
+
T === "saved" && /* @__PURE__ */ S(p, { style: {
|
|
708
739
|
height: "var(--size-icon-sm)",
|
|
709
740
|
width: "var(--size-icon-sm)",
|
|
710
741
|
color: "var(--color-status-success-bg)"
|
|
711
742
|
} }),
|
|
712
|
-
|
|
743
|
+
T === "error" && /* @__PURE__ */ S(be, { style: {
|
|
713
744
|
height: "var(--size-icon-sm)",
|
|
714
745
|
width: "var(--size-icon-sm)",
|
|
715
746
|
color: "var(--color-status-error-bg)"
|
|
716
747
|
} })
|
|
717
748
|
]
|
|
718
|
-
}),
|
|
749
|
+
}), Mt && /* @__PURE__ */ S(Ae, {
|
|
719
750
|
style: {
|
|
720
751
|
fontSize: "var(--font-size-body-sm)",
|
|
721
752
|
color: "var(--color-text-secondary)",
|
|
722
753
|
margin: "var(--space-controlGap) 0 0 0",
|
|
723
754
|
fontWeight: "var(--font-weight-medium)"
|
|
724
755
|
},
|
|
725
|
-
children:
|
|
756
|
+
children: Mt.name
|
|
726
757
|
})]
|
|
727
758
|
})]
|
|
728
759
|
})
|
|
729
760
|
}),
|
|
730
|
-
|
|
731
|
-
value:
|
|
732
|
-
onValueChange: (e) =>
|
|
761
|
+
N ? /* @__PURE__ */ C(Ne, {
|
|
762
|
+
value: Ue,
|
|
763
|
+
onValueChange: (e) => We(e),
|
|
733
764
|
style: {
|
|
734
765
|
flex: 1,
|
|
735
766
|
display: "flex",
|
|
@@ -737,7 +768,7 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
737
768
|
minHeight: 0,
|
|
738
769
|
overflow: "hidden"
|
|
739
770
|
},
|
|
740
|
-
children: [/* @__PURE__ */
|
|
771
|
+
children: [/* @__PURE__ */ C(Pe, {
|
|
741
772
|
style: {
|
|
742
773
|
width: "100%",
|
|
743
774
|
display: "flex",
|
|
@@ -752,7 +783,7 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
752
783
|
overflowX: "auto"
|
|
753
784
|
},
|
|
754
785
|
children: [
|
|
755
|
-
/* @__PURE__ */
|
|
786
|
+
/* @__PURE__ */ S(b, {
|
|
756
787
|
value: "general",
|
|
757
788
|
style: {
|
|
758
789
|
fontWeight: "var(--font-weight-semibold)",
|
|
@@ -760,9 +791,9 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
760
791
|
padding: "6px 8px",
|
|
761
792
|
flexShrink: 0
|
|
762
793
|
},
|
|
763
|
-
children: "General"
|
|
794
|
+
children: w("bigconsole.widget.properties.tab.general", "General")
|
|
764
795
|
}),
|
|
765
|
-
/* @__PURE__ */
|
|
796
|
+
/* @__PURE__ */ S(b, {
|
|
766
797
|
value: "data",
|
|
767
798
|
style: {
|
|
768
799
|
fontWeight: "var(--font-weight-semibold)",
|
|
@@ -770,9 +801,9 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
770
801
|
padding: "6px 8px",
|
|
771
802
|
flexShrink: 0
|
|
772
803
|
},
|
|
773
|
-
children: "Data"
|
|
804
|
+
children: w("bigconsole.widget.properties.tab.data", "Data")
|
|
774
805
|
}),
|
|
775
|
-
/* @__PURE__ */
|
|
806
|
+
/* @__PURE__ */ S(b, {
|
|
776
807
|
value: "advanced",
|
|
777
808
|
style: {
|
|
778
809
|
fontWeight: "var(--font-weight-semibold)",
|
|
@@ -780,9 +811,9 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
780
811
|
padding: "6px 8px",
|
|
781
812
|
flexShrink: 0
|
|
782
813
|
},
|
|
783
|
-
children: "Advanced"
|
|
814
|
+
children: w("bigconsole.widget.properties.tab.advanced", "Advanced")
|
|
784
815
|
}),
|
|
785
|
-
/* @__PURE__ */
|
|
816
|
+
/* @__PURE__ */ S(b, {
|
|
786
817
|
value: "appearance",
|
|
787
818
|
style: {
|
|
788
819
|
fontWeight: "var(--font-weight-semibold)",
|
|
@@ -790,10 +821,10 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
790
821
|
padding: "6px 8px",
|
|
791
822
|
flexShrink: 0
|
|
792
823
|
},
|
|
793
|
-
children: "Style"
|
|
824
|
+
children: w("bigconsole.widget.properties.tab.style", "Style")
|
|
794
825
|
})
|
|
795
826
|
]
|
|
796
|
-
}), /* @__PURE__ */
|
|
827
|
+
}), /* @__PURE__ */ C("div", {
|
|
797
828
|
style: {
|
|
798
829
|
flex: 1,
|
|
799
830
|
overflow: "auto",
|
|
@@ -801,83 +832,83 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
801
832
|
minHeight: 0
|
|
802
833
|
},
|
|
803
834
|
children: [
|
|
804
|
-
/* @__PURE__ */
|
|
835
|
+
/* @__PURE__ */ S(y, {
|
|
805
836
|
value: "general",
|
|
806
837
|
className: "mt-0",
|
|
807
|
-
children:
|
|
838
|
+
children: D && /* @__PURE__ */ S("div", {
|
|
808
839
|
style: {
|
|
809
840
|
display: "flex",
|
|
810
841
|
flexDirection: "column",
|
|
811
842
|
gap: "var(--space-formGap)"
|
|
812
843
|
},
|
|
813
|
-
children: /* @__PURE__ */
|
|
814
|
-
title:
|
|
815
|
-
description:
|
|
816
|
-
refreshInterval:
|
|
844
|
+
children: /* @__PURE__ */ S(le, {
|
|
845
|
+
title: D.title,
|
|
846
|
+
description: D.description,
|
|
847
|
+
refreshInterval: D.refreshInterval,
|
|
817
848
|
onTitleChange: (e) => Q("title", e),
|
|
818
849
|
onDescriptionChange: (e) => Q("description", e),
|
|
819
850
|
onRefreshIntervalChange: (e) => Q("refreshInterval", e)
|
|
820
851
|
})
|
|
821
852
|
})
|
|
822
853
|
}),
|
|
823
|
-
/* @__PURE__ */
|
|
854
|
+
/* @__PURE__ */ S(y, {
|
|
824
855
|
value: "data",
|
|
825
856
|
className: "mt-0 space-y-4",
|
|
826
|
-
children:
|
|
857
|
+
children: D && /* @__PURE__ */ C(Fe, { children: [
|
|
827
858
|
(() => {
|
|
828
859
|
let e = c({
|
|
829
|
-
dataSinkId:
|
|
830
|
-
parserId:
|
|
860
|
+
dataSinkId: D.dataSinkId,
|
|
861
|
+
parserId: D.parserId,
|
|
831
862
|
config: {
|
|
832
|
-
...
|
|
863
|
+
...D.config,
|
|
833
864
|
binding: void 0
|
|
834
865
|
}
|
|
835
866
|
}), t = ee({
|
|
836
867
|
binding: e,
|
|
837
|
-
loading:
|
|
838
|
-
error:
|
|
839
|
-
preview:
|
|
840
|
-
previewComplete:
|
|
868
|
+
loading: Qe,
|
|
869
|
+
error: tt,
|
|
870
|
+
preview: $e,
|
|
871
|
+
previewComplete: et
|
|
841
872
|
});
|
|
842
|
-
return /* @__PURE__ */
|
|
843
|
-
consoleId:
|
|
873
|
+
return /* @__PURE__ */ S(ue, {
|
|
874
|
+
consoleId: N?.dashboardId || "",
|
|
844
875
|
binding: e,
|
|
845
|
-
dataSinkKey:
|
|
846
|
-
dataPath: typeof
|
|
876
|
+
dataSinkKey: Xe,
|
|
877
|
+
dataPath: typeof D.config.dataPath == "string" ? D.config.dataPath : void 0,
|
|
847
878
|
status: t.status,
|
|
848
879
|
missingFields: t.missingFields,
|
|
849
|
-
preview:
|
|
850
|
-
error:
|
|
851
|
-
onDataSinkChange:
|
|
852
|
-
onParserChange:
|
|
880
|
+
preview: $e,
|
|
881
|
+
error: tt,
|
|
882
|
+
onDataSinkChange: Et,
|
|
883
|
+
onParserChange: Dt,
|
|
853
884
|
onDataPathChange: (e) => $({
|
|
854
|
-
...
|
|
885
|
+
...D.config,
|
|
855
886
|
dataPath: e
|
|
856
887
|
})
|
|
857
888
|
});
|
|
858
889
|
})(),
|
|
859
|
-
/* @__PURE__ */
|
|
890
|
+
/* @__PURE__ */ S("div", {
|
|
860
891
|
className: "border-t border-border-subtle pt-4",
|
|
861
|
-
children: /* @__PURE__ */
|
|
892
|
+
children: /* @__PURE__ */ S(g, {
|
|
862
893
|
className: "text-xs text-text-secondary uppercase tracking-wide",
|
|
863
|
-
children: "Alternative Data Sources"
|
|
894
|
+
children: w("bigconsole.widget.properties.data.alternativeSources", "Alternative Data Sources")
|
|
864
895
|
})
|
|
865
896
|
}),
|
|
866
|
-
/* @__PURE__ */
|
|
897
|
+
/* @__PURE__ */ C("div", {
|
|
867
898
|
className: "space-y-2",
|
|
868
|
-
children: [/* @__PURE__ */
|
|
869
|
-
value:
|
|
899
|
+
children: [/* @__PURE__ */ S(g, { children: w("bigconsole.widget.properties.data.sourceTypeLabel", "Data Source Type") }), /* @__PURE__ */ C(we, {
|
|
900
|
+
value: D.config?.dataSourceType || "",
|
|
870
901
|
onValueChange: (e) => $({
|
|
871
|
-
...
|
|
902
|
+
...D.config,
|
|
872
903
|
dataSourceType: e || void 0
|
|
873
904
|
}),
|
|
874
|
-
children: [/* @__PURE__ */
|
|
905
|
+
children: [/* @__PURE__ */ S(Ee, {
|
|
875
906
|
style: {
|
|
876
907
|
height: "var(--size-controlHeight-md)",
|
|
877
908
|
fontSize: "var(--font-size-body-sm)"
|
|
878
909
|
},
|
|
879
|
-
children: /* @__PURE__ */
|
|
880
|
-
}), /* @__PURE__ */
|
|
910
|
+
children: /* @__PURE__ */ S(De, { placeholder: w("bigconsole.widget.properties.data.selectTypePlaceholder", "Select type...") })
|
|
911
|
+
}), /* @__PURE__ */ S(Te, {
|
|
881
912
|
position: "popper",
|
|
882
913
|
side: "bottom",
|
|
883
914
|
sideOffset: 4,
|
|
@@ -890,56 +921,56 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
890
921
|
boxShadow: "var(--shadow-elevation-3)",
|
|
891
922
|
borderRadius: "var(--radius-button)"
|
|
892
923
|
},
|
|
893
|
-
children:
|
|
924
|
+
children: Pt.map((e) => /* @__PURE__ */ S(_, {
|
|
894
925
|
value: e.value,
|
|
895
926
|
children: e.label
|
|
896
927
|
}, e.value))
|
|
897
928
|
})]
|
|
898
929
|
})]
|
|
899
930
|
}),
|
|
900
|
-
|
|
931
|
+
D.config?.dataSourceType === "REST_API" && /* @__PURE__ */ C("div", {
|
|
901
932
|
className: "space-y-3",
|
|
902
933
|
children: [
|
|
903
|
-
/* @__PURE__ */
|
|
934
|
+
/* @__PURE__ */ C("div", {
|
|
904
935
|
className: "space-y-2",
|
|
905
|
-
children: [/* @__PURE__ */
|
|
906
|
-
value:
|
|
936
|
+
children: [/* @__PURE__ */ S(g, { children: w("bigconsole.widget.properties.rest.endpointUrlLabel", "Endpoint URL *") }), /* @__PURE__ */ S(h, {
|
|
937
|
+
value: D.config?.endpointUrl || "",
|
|
907
938
|
onChange: (e) => $({
|
|
908
|
-
...
|
|
939
|
+
...D.config,
|
|
909
940
|
endpointUrl: e.target.value || void 0
|
|
910
941
|
}),
|
|
911
942
|
placeholder: "https://api.example.com/data"
|
|
912
943
|
})]
|
|
913
944
|
}),
|
|
914
|
-
/* @__PURE__ */
|
|
945
|
+
/* @__PURE__ */ C("div", {
|
|
915
946
|
className: "space-y-2",
|
|
916
|
-
children: [/* @__PURE__ */
|
|
917
|
-
value:
|
|
947
|
+
children: [/* @__PURE__ */ S(g, { children: w("bigconsole.widget.properties.rest.httpMethodLabel", "HTTP Method") }), /* @__PURE__ */ C(we, {
|
|
948
|
+
value: D.config?.httpMethod || "GET",
|
|
918
949
|
onValueChange: (e) => $({
|
|
919
|
-
...
|
|
950
|
+
...D.config,
|
|
920
951
|
httpMethod: e
|
|
921
952
|
}),
|
|
922
|
-
children: [/* @__PURE__ */
|
|
953
|
+
children: [/* @__PURE__ */ S(Ee, {
|
|
923
954
|
style: { height: "var(--size-controlHeight-md)" },
|
|
924
|
-
children: /* @__PURE__ */
|
|
925
|
-
}), /* @__PURE__ */
|
|
955
|
+
children: /* @__PURE__ */ S(De, {})
|
|
956
|
+
}), /* @__PURE__ */ C(Te, {
|
|
926
957
|
position: "popper",
|
|
927
958
|
side: "bottom",
|
|
928
959
|
sideOffset: 4,
|
|
929
960
|
children: [
|
|
930
|
-
/* @__PURE__ */
|
|
961
|
+
/* @__PURE__ */ S(_, {
|
|
931
962
|
value: "GET",
|
|
932
963
|
children: "GET"
|
|
933
964
|
}),
|
|
934
|
-
/* @__PURE__ */
|
|
965
|
+
/* @__PURE__ */ S(_, {
|
|
935
966
|
value: "POST",
|
|
936
967
|
children: "POST"
|
|
937
968
|
}),
|
|
938
|
-
/* @__PURE__ */
|
|
969
|
+
/* @__PURE__ */ S(_, {
|
|
939
970
|
value: "PUT",
|
|
940
971
|
children: "PUT"
|
|
941
972
|
}),
|
|
942
|
-
/* @__PURE__ */
|
|
973
|
+
/* @__PURE__ */ S(_, {
|
|
943
974
|
value: "DELETE",
|
|
944
975
|
children: "DELETE"
|
|
945
976
|
})
|
|
@@ -947,12 +978,12 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
947
978
|
})]
|
|
948
979
|
})]
|
|
949
980
|
}),
|
|
950
|
-
/* @__PURE__ */
|
|
981
|
+
/* @__PURE__ */ C("div", {
|
|
951
982
|
className: "space-y-2",
|
|
952
|
-
children: [/* @__PURE__ */
|
|
953
|
-
value:
|
|
983
|
+
children: [/* @__PURE__ */ S(g, { children: w("bigconsole.widget.properties.rest.headersLabel", "Headers (JSON)") }), /* @__PURE__ */ S(x, {
|
|
984
|
+
value: D.config?.headers || "",
|
|
954
985
|
onChange: (e) => $({
|
|
955
|
-
...
|
|
986
|
+
...D.config,
|
|
956
987
|
headers: e.target.value || void 0
|
|
957
988
|
}),
|
|
958
989
|
rows: 3,
|
|
@@ -960,60 +991,60 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
960
991
|
className: "font-mono text-xs"
|
|
961
992
|
})]
|
|
962
993
|
}),
|
|
963
|
-
/* @__PURE__ */
|
|
994
|
+
/* @__PURE__ */ C("div", {
|
|
964
995
|
className: "space-y-2",
|
|
965
|
-
children: [/* @__PURE__ */
|
|
966
|
-
value:
|
|
996
|
+
children: [/* @__PURE__ */ S(g, { children: w("bigconsole.widget.properties.rest.authenticationLabel", "Authentication") }), /* @__PURE__ */ C(we, {
|
|
997
|
+
value: D.config?.authType || "none",
|
|
967
998
|
onValueChange: (e) => $({
|
|
968
|
-
...
|
|
999
|
+
...D.config,
|
|
969
1000
|
authType: e
|
|
970
1001
|
}),
|
|
971
|
-
children: [/* @__PURE__ */
|
|
1002
|
+
children: [/* @__PURE__ */ S(Ee, {
|
|
972
1003
|
style: { height: "var(--size-controlHeight-md)" },
|
|
973
|
-
children: /* @__PURE__ */
|
|
974
|
-
}), /* @__PURE__ */
|
|
1004
|
+
children: /* @__PURE__ */ S(De, {})
|
|
1005
|
+
}), /* @__PURE__ */ C(Te, {
|
|
975
1006
|
position: "popper",
|
|
976
1007
|
side: "bottom",
|
|
977
1008
|
sideOffset: 4,
|
|
978
1009
|
children: [
|
|
979
|
-
/* @__PURE__ */
|
|
1010
|
+
/* @__PURE__ */ S(_, {
|
|
980
1011
|
value: "none",
|
|
981
|
-
children: "None"
|
|
1012
|
+
children: w("bigconsole.widget.properties.rest.authNone", "None")
|
|
982
1013
|
}),
|
|
983
|
-
/* @__PURE__ */
|
|
1014
|
+
/* @__PURE__ */ S(_, {
|
|
984
1015
|
value: "api_key",
|
|
985
|
-
children: "API Key"
|
|
1016
|
+
children: w("bigconsole.widget.properties.rest.authApiKey", "API Key")
|
|
986
1017
|
}),
|
|
987
|
-
/* @__PURE__ */
|
|
1018
|
+
/* @__PURE__ */ S(_, {
|
|
988
1019
|
value: "bearer",
|
|
989
|
-
children: "Bearer Token"
|
|
1020
|
+
children: w("bigconsole.widget.properties.rest.authBearer", "Bearer Token")
|
|
990
1021
|
}),
|
|
991
|
-
/* @__PURE__ */
|
|
1022
|
+
/* @__PURE__ */ S(_, {
|
|
992
1023
|
value: "basic",
|
|
993
|
-
children: "Basic Auth"
|
|
1024
|
+
children: w("bigconsole.widget.properties.rest.authBasic", "Basic Auth")
|
|
994
1025
|
})
|
|
995
1026
|
]
|
|
996
1027
|
})]
|
|
997
1028
|
})]
|
|
998
1029
|
}),
|
|
999
|
-
!!(
|
|
1030
|
+
!!(D.config?.authType && D.config.authType !== "none") && /* @__PURE__ */ C("div", {
|
|
1000
1031
|
className: "space-y-2",
|
|
1001
|
-
children: [/* @__PURE__ */
|
|
1032
|
+
children: [/* @__PURE__ */ S(g, { children: String(D.config.authType) === "basic" ? w("bigconsole.widget.properties.rest.credentialsLabel", "Credentials (user:pass)") : w("bigconsole.widget.properties.rest.tokenKeyLabel", "Token/Key") }), /* @__PURE__ */ S(h, {
|
|
1002
1033
|
type: "password",
|
|
1003
|
-
value:
|
|
1034
|
+
value: D.config?.authValue || "",
|
|
1004
1035
|
onChange: (e) => $({
|
|
1005
|
-
...
|
|
1036
|
+
...D.config,
|
|
1006
1037
|
authValue: e.target.value || void 0
|
|
1007
1038
|
}),
|
|
1008
|
-
placeholder:
|
|
1039
|
+
placeholder: D.config.authType === "basic" ? w("bigconsole.widget.properties.rest.credentialsPlaceholder", "username:password") : w("bigconsole.widget.properties.rest.tokenKeyPlaceholder", "Enter token or API key")
|
|
1009
1040
|
})]
|
|
1010
1041
|
}),
|
|
1011
|
-
(
|
|
1042
|
+
(D.config?.httpMethod === "POST" || D.config?.httpMethod === "PUT") && /* @__PURE__ */ C("div", {
|
|
1012
1043
|
className: "space-y-2",
|
|
1013
|
-
children: [/* @__PURE__ */
|
|
1014
|
-
value:
|
|
1044
|
+
children: [/* @__PURE__ */ S(g, { children: w("bigconsole.widget.properties.rest.requestBodyLabel", "Request Body (JSON)") }), /* @__PURE__ */ S(x, {
|
|
1045
|
+
value: D.config?.requestBody || "",
|
|
1015
1046
|
onChange: (e) => $({
|
|
1016
|
-
...
|
|
1047
|
+
...D.config,
|
|
1017
1048
|
requestBody: e.target.value || void 0
|
|
1018
1049
|
}),
|
|
1019
1050
|
rows: 4,
|
|
@@ -1021,46 +1052,46 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
1021
1052
|
className: "font-mono text-xs"
|
|
1022
1053
|
})]
|
|
1023
1054
|
}),
|
|
1024
|
-
/* @__PURE__ */
|
|
1055
|
+
/* @__PURE__ */ C("div", {
|
|
1025
1056
|
className: "space-y-2",
|
|
1026
1057
|
children: [
|
|
1027
|
-
/* @__PURE__ */
|
|
1028
|
-
/* @__PURE__ */
|
|
1029
|
-
value:
|
|
1058
|
+
/* @__PURE__ */ S(g, { children: w("bigconsole.widget.properties.dataPath.label", "Data Path (optional)") }),
|
|
1059
|
+
/* @__PURE__ */ S(h, {
|
|
1060
|
+
value: D.config?.dataPath || "",
|
|
1030
1061
|
onChange: (e) => $({
|
|
1031
|
-
...
|
|
1062
|
+
...D.config,
|
|
1032
1063
|
dataPath: e.target.value || void 0
|
|
1033
1064
|
}),
|
|
1034
1065
|
placeholder: "$.data.items or .data.items"
|
|
1035
1066
|
}),
|
|
1036
|
-
/* @__PURE__ */
|
|
1067
|
+
/* @__PURE__ */ S("p", {
|
|
1037
1068
|
className: "text-xs text-text-secondary",
|
|
1038
|
-
children: "JSONPath or dot notation to extract data from response"
|
|
1069
|
+
children: w("bigconsole.widget.properties.dataPath.restHelp", "JSONPath or dot notation to extract data from response")
|
|
1039
1070
|
})
|
|
1040
1071
|
]
|
|
1041
1072
|
})
|
|
1042
1073
|
]
|
|
1043
1074
|
}),
|
|
1044
|
-
|
|
1075
|
+
D.config?.dataSourceType === "GRAPHQL" && /* @__PURE__ */ C("div", {
|
|
1045
1076
|
className: "space-y-3",
|
|
1046
1077
|
children: [
|
|
1047
|
-
/* @__PURE__ */
|
|
1078
|
+
/* @__PURE__ */ C("div", {
|
|
1048
1079
|
className: "space-y-2",
|
|
1049
|
-
children: [/* @__PURE__ */
|
|
1050
|
-
value:
|
|
1080
|
+
children: [/* @__PURE__ */ S(g, { children: w("bigconsole.widget.properties.graphql.endpointLabel", "GraphQL Endpoint *") }), /* @__PURE__ */ S(h, {
|
|
1081
|
+
value: D.config?.graphqlEndpoint || "",
|
|
1051
1082
|
onChange: (e) => $({
|
|
1052
|
-
...
|
|
1083
|
+
...D.config,
|
|
1053
1084
|
graphqlEndpoint: e.target.value || void 0
|
|
1054
1085
|
}),
|
|
1055
1086
|
placeholder: "https://api.example.com/graphql"
|
|
1056
1087
|
})]
|
|
1057
1088
|
}),
|
|
1058
|
-
/* @__PURE__ */
|
|
1089
|
+
/* @__PURE__ */ C("div", {
|
|
1059
1090
|
className: "space-y-2",
|
|
1060
|
-
children: [/* @__PURE__ */
|
|
1061
|
-
value:
|
|
1091
|
+
children: [/* @__PURE__ */ S(g, { children: w("bigconsole.widget.properties.graphql.queryLabel", "Query *") }), /* @__PURE__ */ S(x, {
|
|
1092
|
+
value: D.config?.graphqlQuery || "",
|
|
1062
1093
|
onChange: (e) => $({
|
|
1063
|
-
...
|
|
1094
|
+
...D.config,
|
|
1064
1095
|
graphqlQuery: e.target.value || void 0
|
|
1065
1096
|
}),
|
|
1066
1097
|
rows: 6,
|
|
@@ -1068,12 +1099,12 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
1068
1099
|
className: "font-mono text-xs"
|
|
1069
1100
|
})]
|
|
1070
1101
|
}),
|
|
1071
|
-
/* @__PURE__ */
|
|
1102
|
+
/* @__PURE__ */ C("div", {
|
|
1072
1103
|
className: "space-y-2",
|
|
1073
|
-
children: [/* @__PURE__ */
|
|
1074
|
-
value:
|
|
1104
|
+
children: [/* @__PURE__ */ S(g, { children: w("bigconsole.widget.properties.graphql.variablesLabel", "Variables (JSON, optional)") }), /* @__PURE__ */ S(x, {
|
|
1105
|
+
value: D.config?.graphqlVariables || "",
|
|
1075
1106
|
onChange: (e) => $({
|
|
1076
|
-
...
|
|
1107
|
+
...D.config,
|
|
1077
1108
|
graphqlVariables: e.target.value || void 0
|
|
1078
1109
|
}),
|
|
1079
1110
|
rows: 3,
|
|
@@ -1081,12 +1112,12 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
1081
1112
|
className: "font-mono text-xs"
|
|
1082
1113
|
})]
|
|
1083
1114
|
}),
|
|
1084
|
-
/* @__PURE__ */
|
|
1115
|
+
/* @__PURE__ */ C("div", {
|
|
1085
1116
|
className: "space-y-2",
|
|
1086
|
-
children: [/* @__PURE__ */
|
|
1087
|
-
value:
|
|
1117
|
+
children: [/* @__PURE__ */ S(g, { children: w("bigconsole.widget.properties.graphql.headersLabel", "Headers (JSON, optional)") }), /* @__PURE__ */ S(x, {
|
|
1118
|
+
value: D.config?.headers || "",
|
|
1088
1119
|
onChange: (e) => $({
|
|
1089
|
-
...
|
|
1120
|
+
...D.config,
|
|
1090
1121
|
headers: e.target.value || void 0
|
|
1091
1122
|
}),
|
|
1092
1123
|
rows: 2,
|
|
@@ -1094,32 +1125,32 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
1094
1125
|
className: "font-mono text-xs"
|
|
1095
1126
|
})]
|
|
1096
1127
|
}),
|
|
1097
|
-
/* @__PURE__ */
|
|
1128
|
+
/* @__PURE__ */ C("div", {
|
|
1098
1129
|
className: "space-y-2",
|
|
1099
1130
|
children: [
|
|
1100
|
-
/* @__PURE__ */
|
|
1101
|
-
/* @__PURE__ */
|
|
1102
|
-
value:
|
|
1131
|
+
/* @__PURE__ */ S(g, { children: w("bigconsole.widget.properties.dataPath.label", "Data Path (optional)") }),
|
|
1132
|
+
/* @__PURE__ */ S(h, {
|
|
1133
|
+
value: D.config?.dataPath || "",
|
|
1103
1134
|
onChange: (e) => $({
|
|
1104
|
-
...
|
|
1135
|
+
...D.config,
|
|
1105
1136
|
dataPath: e.target.value || void 0
|
|
1106
1137
|
}),
|
|
1107
1138
|
placeholder: ".data.items"
|
|
1108
1139
|
}),
|
|
1109
|
-
/* @__PURE__ */
|
|
1140
|
+
/* @__PURE__ */ S("p", {
|
|
1110
1141
|
className: "text-xs text-text-secondary",
|
|
1111
|
-
children: "Path to extract data from GraphQL response"
|
|
1142
|
+
children: w("bigconsole.widget.properties.dataPath.graphqlHelp", "Path to extract data from GraphQL response")
|
|
1112
1143
|
})
|
|
1113
1144
|
]
|
|
1114
1145
|
})
|
|
1115
1146
|
]
|
|
1116
1147
|
}),
|
|
1117
|
-
|
|
1148
|
+
D.config?.dataSourceType === "MOCK" && /* @__PURE__ */ C("div", {
|
|
1118
1149
|
className: "space-y-2",
|
|
1119
|
-
children: [/* @__PURE__ */
|
|
1120
|
-
value:
|
|
1150
|
+
children: [/* @__PURE__ */ S(g, { children: w("bigconsole.widget.properties.mock.sampleDataLabel", "Sample Data (JSON)") }), /* @__PURE__ */ S(x, {
|
|
1151
|
+
value: D.config?.mockData || "",
|
|
1121
1152
|
onChange: (e) => $({
|
|
1122
|
-
...
|
|
1153
|
+
...D.config,
|
|
1123
1154
|
mockData: e.target.value || void 0
|
|
1124
1155
|
}),
|
|
1125
1156
|
rows: 5,
|
|
@@ -1129,99 +1160,102 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
1129
1160
|
})
|
|
1130
1161
|
] })
|
|
1131
1162
|
}),
|
|
1132
|
-
/* @__PURE__ */
|
|
1163
|
+
/* @__PURE__ */ C(y, {
|
|
1133
1164
|
value: "advanced",
|
|
1134
1165
|
className: "mt-0 space-y-6",
|
|
1135
1166
|
children: [
|
|
1136
|
-
|
|
1137
|
-
renderer:
|
|
1138
|
-
rendererOptions:
|
|
1167
|
+
D && /* @__PURE__ */ S(se, {
|
|
1168
|
+
renderer: D.renderer,
|
|
1169
|
+
rendererOptions: Nt,
|
|
1139
1170
|
onRendererChange: (e) => {
|
|
1140
1171
|
Q("renderer", e), e === "BIGCONSOLE" && Q("template", void 0);
|
|
1141
1172
|
},
|
|
1142
|
-
templateEditor:
|
|
1173
|
+
templateEditor: D.renderer === "BIGCONSOLE" ? void 0 : /* @__PURE__ */ S(Ve, {
|
|
1143
1174
|
widget: {
|
|
1144
|
-
...
|
|
1145
|
-
template:
|
|
1146
|
-
renderer:
|
|
1175
|
+
...N,
|
|
1176
|
+
template: D.template,
|
|
1177
|
+
renderer: D.renderer
|
|
1147
1178
|
},
|
|
1148
1179
|
onSave: (e) => Q("template", e)
|
|
1149
1180
|
})
|
|
1150
1181
|
}),
|
|
1151
|
-
/* @__PURE__ */
|
|
1182
|
+
/* @__PURE__ */ C("section", {
|
|
1152
1183
|
className: "space-y-4 border-t border-border-default pt-4",
|
|
1153
|
-
children: [/* @__PURE__ */
|
|
1184
|
+
children: [/* @__PURE__ */ C("div", {
|
|
1154
1185
|
className: "flex items-center justify-between",
|
|
1155
|
-
children: [/* @__PURE__ */
|
|
1186
|
+
children: [/* @__PURE__ */ C("div", { children: [/* @__PURE__ */ S("h3", {
|
|
1156
1187
|
className: "text-sm font-medium",
|
|
1157
|
-
children: "Widget Actions"
|
|
1158
|
-
}), /* @__PURE__ */
|
|
1188
|
+
children: w("bigconsole.widget.properties.actions.heading", "Widget Actions")
|
|
1189
|
+
}), /* @__PURE__ */ S("p", {
|
|
1159
1190
|
className: "text-xs text-text-secondary",
|
|
1160
|
-
children: "Configure buttons on this widget"
|
|
1161
|
-
})] }), /* @__PURE__ */
|
|
1191
|
+
children: w("bigconsole.widget.properties.actions.subheading", "Configure buttons on this widget")
|
|
1192
|
+
})] }), /* @__PURE__ */ C(m, {
|
|
1162
1193
|
size: "sm",
|
|
1163
|
-
onClick:
|
|
1164
|
-
children: [/* @__PURE__ */
|
|
1194
|
+
onClick: bt,
|
|
1195
|
+
children: [/* @__PURE__ */ S(ve, { className: "size-4" }), w("bigconsole.widget.properties.actions.add", "Add")]
|
|
1165
1196
|
})]
|
|
1166
|
-
}),
|
|
1197
|
+
}), nt ? /* @__PURE__ */ S("div", {
|
|
1167
1198
|
className: "flex justify-center py-8",
|
|
1168
|
-
children: /* @__PURE__ */
|
|
1169
|
-
}) :
|
|
1199
|
+
children: /* @__PURE__ */ S(v, { className: "size-6" })
|
|
1200
|
+
}) : H.length === 0 ? /* @__PURE__ */ C("div", {
|
|
1170
1201
|
className: "py-8 text-center",
|
|
1171
|
-
children: [/* @__PURE__ */
|
|
1202
|
+
children: [/* @__PURE__ */ S(ge, { className: "size-10 mx-auto mb-2 text-text-secondary/50" }), /* @__PURE__ */ S("p", {
|
|
1172
1203
|
className: "text-sm text-text-secondary",
|
|
1173
|
-
children: "No actions configured"
|
|
1204
|
+
children: w("bigconsole.widget.properties.actions.empty", "No actions configured")
|
|
1174
1205
|
})]
|
|
1175
|
-
}) : /* @__PURE__ */
|
|
1206
|
+
}) : /* @__PURE__ */ S("div", {
|
|
1176
1207
|
className: "space-y-2",
|
|
1177
|
-
children: [...
|
|
1208
|
+
children: [...H].sort((e, t) => e.order - t.order).map((e, t) => /* @__PURE__ */ S(Se, {
|
|
1178
1209
|
className: e.disabled ? "opacity-60" : "",
|
|
1179
|
-
children: /* @__PURE__ */
|
|
1210
|
+
children: /* @__PURE__ */ C(Ce, {
|
|
1180
1211
|
className: "p-3 flex items-center gap-2",
|
|
1181
1212
|
children: [
|
|
1182
|
-
/* @__PURE__ */
|
|
1213
|
+
/* @__PURE__ */ C("div", {
|
|
1183
1214
|
className: "flex flex-col gap-0.5",
|
|
1184
|
-
children: [/* @__PURE__ */
|
|
1215
|
+
children: [/* @__PURE__ */ S(m, {
|
|
1185
1216
|
variant: "ghost",
|
|
1186
1217
|
size: "icon-sm",
|
|
1187
|
-
onClick: () =>
|
|
1218
|
+
onClick: () => wt(t),
|
|
1188
1219
|
disabled: t === 0,
|
|
1189
1220
|
className: "h-5 w-5",
|
|
1190
|
-
children: /* @__PURE__ */
|
|
1191
|
-
}), /* @__PURE__ */
|
|
1221
|
+
children: /* @__PURE__ */ S(me, { className: "size-3" })
|
|
1222
|
+
}), /* @__PURE__ */ S(m, {
|
|
1192
1223
|
variant: "ghost",
|
|
1193
1224
|
size: "icon-sm",
|
|
1194
|
-
onClick: () =>
|
|
1195
|
-
disabled: t ===
|
|
1225
|
+
onClick: () => Tt(t),
|
|
1226
|
+
disabled: t === H.length - 1,
|
|
1196
1227
|
className: "h-5 w-5",
|
|
1197
|
-
children: /* @__PURE__ */
|
|
1228
|
+
children: /* @__PURE__ */ S(pe, { className: "size-3" })
|
|
1198
1229
|
})]
|
|
1199
1230
|
}),
|
|
1200
|
-
/* @__PURE__ */
|
|
1231
|
+
/* @__PURE__ */ C("div", {
|
|
1201
1232
|
className: "flex-1 min-w-0",
|
|
1202
|
-
children: [/* @__PURE__ */
|
|
1233
|
+
children: [/* @__PURE__ */ C("div", {
|
|
1203
1234
|
className: "flex items-center gap-2",
|
|
1204
|
-
children: [/* @__PURE__ */
|
|
1235
|
+
children: [/* @__PURE__ */ S("span", { className: `size-2 rounded-full ${ze[e.style] || "bg-muted-foreground"}` }), /* @__PURE__ */ S("span", {
|
|
1205
1236
|
className: "text-sm font-medium truncate",
|
|
1206
1237
|
children: e.label
|
|
1207
1238
|
})]
|
|
1208
|
-
}), /* @__PURE__ */
|
|
1239
|
+
}), /* @__PURE__ */ S("p", {
|
|
1209
1240
|
className: "text-xs text-text-secondary truncate",
|
|
1210
|
-
children:
|
|
1241
|
+
children: yt.has(e.name) ? w("bigconsole.widget.properties.actions.webhookSummary", "→ {{method}} {{url}}", {
|
|
1242
|
+
method: yt.get(e.name)?.method ?? "",
|
|
1243
|
+
url: yt.get(e.name)?.webhookUrl ?? ""
|
|
1244
|
+
}) : w("bigconsole.widget.properties.actions.emitsEvent", "Emits an event")
|
|
1211
1245
|
})]
|
|
1212
1246
|
}),
|
|
1213
|
-
/* @__PURE__ */
|
|
1247
|
+
/* @__PURE__ */ C("div", {
|
|
1214
1248
|
className: "flex gap-1",
|
|
1215
|
-
children: [/* @__PURE__ */
|
|
1249
|
+
children: [/* @__PURE__ */ S(m, {
|
|
1216
1250
|
variant: "ghost",
|
|
1217
1251
|
size: "icon-sm",
|
|
1218
|
-
onClick: () =>
|
|
1219
|
-
children: /* @__PURE__ */
|
|
1220
|
-
}), /* @__PURE__ */
|
|
1252
|
+
onClick: () => xt(e),
|
|
1253
|
+
children: /* @__PURE__ */ S(_e, { className: "size-4" })
|
|
1254
|
+
}), /* @__PURE__ */ S(m, {
|
|
1221
1255
|
variant: "ghost",
|
|
1222
1256
|
size: "icon-sm",
|
|
1223
|
-
onClick: () =>
|
|
1224
|
-
children: /* @__PURE__ */
|
|
1257
|
+
onClick: () => Ct(e.id),
|
|
1258
|
+
children: /* @__PURE__ */ S(ye, { className: "size-4" })
|
|
1225
1259
|
})]
|
|
1226
1260
|
})
|
|
1227
1261
|
]
|
|
@@ -1229,61 +1263,61 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
1229
1263
|
}, e.id))
|
|
1230
1264
|
})]
|
|
1231
1265
|
}),
|
|
1232
|
-
/* @__PURE__ */
|
|
1266
|
+
/* @__PURE__ */ C("section", {
|
|
1233
1267
|
className: "space-y-3 border-t border-border-default pt-4",
|
|
1234
|
-
children: [/* @__PURE__ */
|
|
1268
|
+
children: [/* @__PURE__ */ S("h3", {
|
|
1235
1269
|
className: "text-sm font-semibold text-text-primary",
|
|
1236
|
-
children: "Drilldown"
|
|
1237
|
-
}), /* @__PURE__ */
|
|
1238
|
-
widget:
|
|
1239
|
-
onChange:
|
|
1270
|
+
children: w("bigconsole.widget.properties.section.drilldown", "Drilldown")
|
|
1271
|
+
}), /* @__PURE__ */ S(oe, {
|
|
1272
|
+
widget: N,
|
|
1273
|
+
onChange: jt
|
|
1240
1274
|
})]
|
|
1241
1275
|
}),
|
|
1242
|
-
/* @__PURE__ */
|
|
1276
|
+
/* @__PURE__ */ C("section", {
|
|
1243
1277
|
className: "space-y-3 border-t border-border-default pt-4",
|
|
1244
|
-
children: [/* @__PURE__ */
|
|
1278
|
+
children: [/* @__PURE__ */ S("h3", {
|
|
1245
1279
|
className: "text-sm font-semibold text-text-primary",
|
|
1246
|
-
children: "Webhooks"
|
|
1247
|
-
}), /* @__PURE__ */
|
|
1248
|
-
dashboardId:
|
|
1249
|
-
widgetId:
|
|
1280
|
+
children: w("bigconsole.widget.properties.section.webhooks", "Webhooks")
|
|
1281
|
+
}), /* @__PURE__ */ S(ie, {
|
|
1282
|
+
dashboardId: N.dashboardId,
|
|
1283
|
+
widgetId: N.id
|
|
1250
1284
|
})]
|
|
1251
1285
|
}),
|
|
1252
|
-
/* @__PURE__ */
|
|
1286
|
+
/* @__PURE__ */ C("section", {
|
|
1253
1287
|
className: "space-y-3 border-t border-border-default pt-4",
|
|
1254
|
-
children: [/* @__PURE__ */
|
|
1288
|
+
children: [/* @__PURE__ */ S("h3", {
|
|
1255
1289
|
className: "text-sm font-semibold text-text-primary",
|
|
1256
|
-
children: "Events"
|
|
1257
|
-
}), /* @__PURE__ */
|
|
1258
|
-
dashboardId:
|
|
1259
|
-
widgetId:
|
|
1290
|
+
children: w("bigconsole.widget.properties.section.events", "Events")
|
|
1291
|
+
}), /* @__PURE__ */ S(ae, {
|
|
1292
|
+
dashboardId: N.dashboardId,
|
|
1293
|
+
widgetId: N.id,
|
|
1260
1294
|
maxHeight: "calc(100vh - 350px)"
|
|
1261
1295
|
})]
|
|
1262
1296
|
})
|
|
1263
1297
|
]
|
|
1264
1298
|
}),
|
|
1265
|
-
/* @__PURE__ */
|
|
1299
|
+
/* @__PURE__ */ S(y, {
|
|
1266
1300
|
value: "appearance",
|
|
1267
1301
|
className: "mt-0",
|
|
1268
|
-
children:
|
|
1269
|
-
widgetType:
|
|
1270
|
-
config:
|
|
1271
|
-
onChange:
|
|
1302
|
+
children: D && /* @__PURE__ */ S(ce, {
|
|
1303
|
+
widgetType: N.type,
|
|
1304
|
+
config: D.config || {},
|
|
1305
|
+
onChange: At
|
|
1272
1306
|
})
|
|
1273
1307
|
})
|
|
1274
1308
|
]
|
|
1275
1309
|
})]
|
|
1276
|
-
}) : /* @__PURE__ */
|
|
1310
|
+
}) : /* @__PURE__ */ S("div", {
|
|
1277
1311
|
className: "flex-1 flex items-center justify-center p-4",
|
|
1278
|
-
children: /* @__PURE__ */
|
|
1312
|
+
children: /* @__PURE__ */ C("div", {
|
|
1279
1313
|
className: "text-center",
|
|
1280
|
-
children: [/* @__PURE__ */
|
|
1314
|
+
children: [/* @__PURE__ */ S(ge, { className: "size-12 mx-auto mb-3 text-text-secondary" }), /* @__PURE__ */ S("p", {
|
|
1281
1315
|
className: "text-sm text-text-secondary",
|
|
1282
|
-
children: "Select a widget to edit"
|
|
1316
|
+
children: w("bigconsole.widget.properties.emptyState", "Select a widget to edit")
|
|
1283
1317
|
})]
|
|
1284
1318
|
})
|
|
1285
1319
|
}),
|
|
1286
|
-
|
|
1320
|
+
N && /* @__PURE__ */ C("div", {
|
|
1287
1321
|
style: {
|
|
1288
1322
|
padding: "var(--space-cardPadding)",
|
|
1289
1323
|
borderTop: "1px solid var(--color-border)",
|
|
@@ -1291,7 +1325,7 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
1291
1325
|
flexShrink: 0
|
|
1292
1326
|
},
|
|
1293
1327
|
children: [
|
|
1294
|
-
|
|
1328
|
+
k && /* @__PURE__ */ C("div", {
|
|
1295
1329
|
style: {
|
|
1296
1330
|
display: "flex",
|
|
1297
1331
|
alignItems: "center",
|
|
@@ -1302,22 +1336,22 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
1302
1336
|
borderRadius: "var(--radius-button)",
|
|
1303
1337
|
border: "1px solid var(--color-status-warning-border, rgba(251, 191, 36, 0.3))"
|
|
1304
1338
|
},
|
|
1305
|
-
children: [/* @__PURE__ */
|
|
1339
|
+
children: [/* @__PURE__ */ S("div", { style: {
|
|
1306
1340
|
width: "8px",
|
|
1307
1341
|
height: "8px",
|
|
1308
1342
|
borderRadius: "50%",
|
|
1309
1343
|
backgroundColor: "var(--color-status-warning-bg)",
|
|
1310
1344
|
flexShrink: 0
|
|
1311
|
-
} }), /* @__PURE__ */
|
|
1345
|
+
} }), /* @__PURE__ */ S("span", {
|
|
1312
1346
|
style: {
|
|
1313
1347
|
fontSize: "var(--font-size-body-sm)",
|
|
1314
1348
|
color: "var(--color-status-warning-text, #92400e)",
|
|
1315
1349
|
fontWeight: "var(--font-weight-medium)"
|
|
1316
1350
|
},
|
|
1317
|
-
children: "You have unsaved changes"
|
|
1351
|
+
children: w("bigconsole.widget.properties.footer.unsavedChanges", "You have unsaved changes")
|
|
1318
1352
|
})]
|
|
1319
1353
|
}),
|
|
1320
|
-
|
|
1354
|
+
T === "saved" && !k && /* @__PURE__ */ C("div", {
|
|
1321
1355
|
style: {
|
|
1322
1356
|
display: "flex",
|
|
1323
1357
|
alignItems: "center",
|
|
@@ -1328,21 +1362,21 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
1328
1362
|
borderRadius: "var(--radius-button)",
|
|
1329
1363
|
border: "1px solid var(--color-status-success-border, rgba(34, 197, 94, 0.3))"
|
|
1330
1364
|
},
|
|
1331
|
-
children: [/* @__PURE__ */
|
|
1365
|
+
children: [/* @__PURE__ */ S(p, { style: {
|
|
1332
1366
|
width: "var(--size-icon-sm)",
|
|
1333
1367
|
height: "var(--size-icon-sm)",
|
|
1334
1368
|
color: "var(--color-status-success-text)",
|
|
1335
1369
|
flexShrink: 0
|
|
1336
|
-
} }), /* @__PURE__ */
|
|
1370
|
+
} }), /* @__PURE__ */ S("span", {
|
|
1337
1371
|
style: {
|
|
1338
1372
|
fontSize: "var(--font-size-body-sm)",
|
|
1339
1373
|
color: "var(--color-status-success-text)",
|
|
1340
1374
|
fontWeight: "var(--font-weight-medium)"
|
|
1341
1375
|
},
|
|
1342
|
-
children: "All changes saved"
|
|
1376
|
+
children: w("bigconsole.widget.properties.footer.allSaved", "All changes saved")
|
|
1343
1377
|
})]
|
|
1344
1378
|
}),
|
|
1345
|
-
|
|
1379
|
+
T === "error" && /* @__PURE__ */ C("div", {
|
|
1346
1380
|
style: {
|
|
1347
1381
|
display: "flex",
|
|
1348
1382
|
alignItems: "center",
|
|
@@ -1353,87 +1387,87 @@ var ze = l(function({ isOpen: l, onClose: m }) {
|
|
|
1353
1387
|
borderRadius: "var(--radius-button)",
|
|
1354
1388
|
border: "1px solid var(--color-status-error-border)"
|
|
1355
1389
|
},
|
|
1356
|
-
children: [/* @__PURE__ */
|
|
1390
|
+
children: [/* @__PURE__ */ S(be, { style: {
|
|
1357
1391
|
width: "var(--size-icon-sm)",
|
|
1358
1392
|
height: "var(--size-icon-sm)",
|
|
1359
1393
|
color: "var(--color-status-error-text)",
|
|
1360
1394
|
flexShrink: 0
|
|
1361
|
-
} }), /* @__PURE__ */
|
|
1395
|
+
} }), /* @__PURE__ */ S("span", {
|
|
1362
1396
|
style: {
|
|
1363
1397
|
fontSize: "var(--font-size-body-sm)",
|
|
1364
1398
|
color: "var(--color-status-error-text)",
|
|
1365
1399
|
fontWeight: "var(--font-weight-medium)"
|
|
1366
1400
|
},
|
|
1367
|
-
children: "Failed to save changes"
|
|
1401
|
+
children: w("bigconsole.widget.properties.footer.saveFailed", "Failed to save changes")
|
|
1368
1402
|
})]
|
|
1369
1403
|
}),
|
|
1370
|
-
/* @__PURE__ */
|
|
1404
|
+
/* @__PURE__ */ C("div", {
|
|
1371
1405
|
style: {
|
|
1372
1406
|
display: "flex",
|
|
1373
1407
|
gap: "var(--space-controlGap)"
|
|
1374
1408
|
},
|
|
1375
|
-
children: [/* @__PURE__ */
|
|
1376
|
-
onClick:
|
|
1377
|
-
disabled:
|
|
1409
|
+
children: [/* @__PURE__ */ S(m, {
|
|
1410
|
+
onClick: Ot,
|
|
1411
|
+
disabled: T === "saving" || !k,
|
|
1378
1412
|
style: {
|
|
1379
1413
|
flex: 1,
|
|
1380
1414
|
height: "var(--size-controlHeight-md)",
|
|
1381
|
-
backgroundColor:
|
|
1382
|
-
opacity:
|
|
1415
|
+
backgroundColor: k ? "var(--color-action-primary-bg)" : void 0,
|
|
1416
|
+
opacity: k ? 1 : .5
|
|
1383
1417
|
},
|
|
1384
|
-
children:
|
|
1418
|
+
children: T === "saving" ? /* @__PURE__ */ C("span", {
|
|
1385
1419
|
style: {
|
|
1386
1420
|
display: "flex",
|
|
1387
1421
|
alignItems: "center",
|
|
1388
1422
|
gap: "var(--space-iconGap)"
|
|
1389
1423
|
},
|
|
1390
|
-
children: [/* @__PURE__ */
|
|
1424
|
+
children: [/* @__PURE__ */ S(v, { style: {
|
|
1391
1425
|
width: "var(--size-icon-sm)",
|
|
1392
1426
|
height: "var(--size-icon-sm)"
|
|
1393
|
-
} }), "Saving..."]
|
|
1394
|
-
}) : /* @__PURE__ */
|
|
1427
|
+
} }), w("bigconsole.widget.properties.footer.saving", "Saving...")]
|
|
1428
|
+
}) : /* @__PURE__ */ C("span", {
|
|
1395
1429
|
style: {
|
|
1396
1430
|
display: "flex",
|
|
1397
1431
|
alignItems: "center",
|
|
1398
1432
|
gap: "var(--space-iconGap)"
|
|
1399
1433
|
},
|
|
1400
|
-
children: [/* @__PURE__ */
|
|
1434
|
+
children: [/* @__PURE__ */ S(p, { style: {
|
|
1401
1435
|
width: "var(--size-icon-sm)",
|
|
1402
1436
|
height: "var(--size-icon-sm)"
|
|
1403
|
-
} }), "Save Changes"]
|
|
1437
|
+
} }), w("bigconsole.widget.properties.footer.saveChanges", "Save Changes")]
|
|
1404
1438
|
})
|
|
1405
|
-
}), /* @__PURE__ */
|
|
1439
|
+
}), /* @__PURE__ */ C(m, {
|
|
1406
1440
|
variant: "outline",
|
|
1407
|
-
onClick:
|
|
1408
|
-
disabled:
|
|
1441
|
+
onClick: kt,
|
|
1442
|
+
disabled: T === "saving" || !k,
|
|
1409
1443
|
style: {
|
|
1410
1444
|
height: "var(--size-controlHeight-md)",
|
|
1411
|
-
opacity:
|
|
1445
|
+
opacity: k ? 1 : .5
|
|
1412
1446
|
},
|
|
1413
|
-
children: [/* @__PURE__ */
|
|
1447
|
+
children: [/* @__PURE__ */ S(be, { style: {
|
|
1414
1448
|
width: "var(--size-icon-sm)",
|
|
1415
1449
|
height: "var(--size-icon-sm)"
|
|
1416
|
-
} }), "Discard"]
|
|
1450
|
+
} }), w("bigconsole.widget.properties.footer.discard", "Discard")]
|
|
1417
1451
|
})]
|
|
1418
1452
|
})
|
|
1419
1453
|
]
|
|
1420
1454
|
}),
|
|
1421
|
-
/* @__PURE__ */
|
|
1422
|
-
isOpen:
|
|
1455
|
+
/* @__PURE__ */ S(re, {
|
|
1456
|
+
isOpen: ft,
|
|
1423
1457
|
action: J,
|
|
1424
|
-
initialWebhook:
|
|
1425
|
-
isLoading:
|
|
1426
|
-
saveError:
|
|
1458
|
+
initialWebhook: vt,
|
|
1459
|
+
isLoading: pt,
|
|
1460
|
+
saveError: gt,
|
|
1427
1461
|
onClose: () => {
|
|
1428
1462
|
q(!1), Y(void 0), X(void 0), Z(null);
|
|
1429
1463
|
},
|
|
1430
|
-
onSave:
|
|
1464
|
+
onSave: St
|
|
1431
1465
|
})
|
|
1432
1466
|
]
|
|
1433
1467
|
})
|
|
1434
1468
|
});
|
|
1435
1469
|
});
|
|
1436
1470
|
//#endregion
|
|
1437
|
-
export {
|
|
1471
|
+
export { w as default };
|
|
1438
1472
|
|
|
1439
1473
|
//# sourceMappingURL=PropertiesPanel.js.map
|