@burdenoff/microfe-bigconsole 2026.1010.12 → 2026.1012.1
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/README.md +19 -0
- package/dist/bigconsole/BigConsoleRoot.js +88 -82
- package/dist/bigconsole/BigConsoleRoutes.js +163 -136
- package/dist/bigconsole/assistant/assistantProduct.js +1 -4
- package/dist/bigconsole/assistant/pageContext.d.ts +0 -14
- package/dist/bigconsole/assistant/pageContext.js +1 -6
- package/dist/bigconsole/assistant/recordAdapters.js +26 -27
- package/dist/bigconsole/components/builder/inspector/DataBindingSection.js +31 -31
- package/dist/bigconsole/components/common/index.d.ts +0 -1
- package/dist/bigconsole/components/common/index.js +0 -1
- package/dist/bigconsole/components/dashboard/CreateDashboardDialog.js +44 -44
- package/dist/bigconsole/components/dashboard/DashboardCanvas.js +36 -36
- package/dist/bigconsole/components/dashboard/DashboardToolbar.js +59 -59
- package/dist/bigconsole/components/dashboard/DrilldownBreadcrumb.js +58 -57
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterChip.js +30 -30
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterEditor.js +41 -41
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/FilterPresetSelector.js +34 -34
- package/dist/bigconsole/components/dashboard/GlobalFiltersBar/GlobalFiltersBar.js +34 -34
- package/dist/bigconsole/components/dashboard/ImportDashboardDialog.js +110 -110
- package/dist/bigconsole/components/dashboard/PublishToStoreDialog.js +21 -21
- package/dist/bigconsole/components/dashboard/SavedViewsDropdown/SavedViewsDropdown.js +46 -46
- package/dist/bigconsole/components/dashboard/ShareDialog/EmbedTab.js +164 -173
- package/dist/bigconsole/components/dashboard/ShareDialog/ShareDialog.js +101 -101
- package/dist/bigconsole/components/dashboard/TemplateInstallOptions.js +31 -31
- package/dist/bigconsole/components/dashboard/TemplateLayoutPreview.js +15 -15
- package/dist/bigconsole/components/dashboard/TemplatePicker/TemplatePicker.js +1 -1
- package/dist/bigconsole/components/dashboard/WidgetPalette.js +165 -163
- package/dist/bigconsole/components/datasink/AlertExecutionHistory.js +37 -37
- package/dist/bigconsole/components/datasink/AlertRuleEditor.js +66 -66
- package/dist/bigconsole/components/datasink/CacheTTLSelector.js +35 -35
- package/dist/bigconsole/components/datasink/DataSinkCard.js +50 -51
- package/dist/bigconsole/components/datasink/DataSinkDeleteDialog.js +18 -18
- package/dist/bigconsole/components/datasink/DataSinkRefreshDialog.js +20 -20
- package/dist/bigconsole/components/datasink/ImportDataGuideDialog.js +47 -47
- package/dist/bigconsole/components/datasink/ImportDataSinkDialog.js +91 -91
- package/dist/bigconsole/components/datasink/RefreshTypeSelector.js +35 -35
- package/dist/bigconsole/components/parser/DataSinkSelector.js +40 -40
- package/dist/bigconsole/components/parser/ImportParserDialog.js +120 -120
- package/dist/bigconsole/components/parser/ParserSelector.js +51 -51
- package/dist/bigconsole/components/pipeline/PipelineScopePicker.js +10 -10
- package/dist/bigconsole/components/preview/AiPreviewMiniPanel.js +76 -77
- package/dist/bigconsole/components/preview/AiPreviewPanel.js +95 -96
- package/dist/bigconsole/components/widgets/ActionConfigDialog.js +4 -4
- package/dist/bigconsole/components/widgets/DrilldownConfigPanel.js +93 -93
- package/dist/bigconsole/components/widgets/PropertiesPanel.js +499 -507
- package/dist/bigconsole/components/widgets/WidgetRegistry.js +0 -1
- package/dist/bigconsole/components/widgets/calendar/CalendarWidget.js +4 -4
- 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/custom/CustomWidget.js +73 -131
- 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/iframe-widget/IframeWidget.d.ts +28 -9
- package/dist/bigconsole/components/widgets/iframe-widget/IframeWidget.js +115 -42
- package/dist/bigconsole/components/widgets/iframe-widget/framePolicy.d.ts +20 -0
- package/dist/bigconsole/components/widgets/iframe-widget/framePolicy.js +10 -0
- package/dist/bigconsole/components/widgets/iframe-widget/index.d.ts +2 -1
- package/dist/bigconsole/components/widgets/iframe-widget/index.js +3 -2
- package/dist/bigconsole/components/widgets/kanban/KanbanWidget.js +4 -4
- 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/text-widget/TextWidget.js +110 -27
- package/dist/bigconsole/components/widgets/text-widget/textData.d.ts +6 -0
- package/dist/bigconsole/components/widgets/text-widget/textData.js +17 -14
- package/dist/bigconsole/components/widgets/webhook-config/WebhookConfigPanel.js +64 -64
- package/dist/bigconsole/components/workflow/WorkflowOpenGuard.js +15 -15
- package/dist/bigconsole/components/workflow/WorkflowSinkLinkForm.js +15 -15
- package/dist/bigconsole/context/BigConsoleContext.d.ts +10 -0
- package/dist/bigconsole/context/BigConsoleContext.js +47 -30
- package/dist/bigconsole/context/index.d.ts +1 -1
- package/dist/bigconsole/customWidget/CustomWidgetBuilderSheet.js +58 -49
- package/dist/bigconsole/customWidget/CustomWidgetProposalPanel.js +74 -72
- package/dist/bigconsole/customWidget/proposalPreview.d.ts +5 -0
- package/dist/bigconsole/customWidget/proposalPreview.js +31 -0
- package/dist/bigconsole/hooks/useDataSinkAlerts.d.ts +0 -23
- package/dist/bigconsole/hooks/useDataSinkAlerts.js +113 -138
- package/dist/bigconsole/hooks/useDataSinkOperations.d.ts +7 -0
- package/dist/bigconsole/hooks/useDataSinkOperations.js +109 -98
- package/dist/bigconsole/hooks/useDataSinkSubscription.js +0 -1
- package/dist/bigconsole/hooks/useDrilldown.js +68 -67
- package/dist/bigconsole/hooks/useExportDataSink.js +1 -1
- package/dist/bigconsole/hooks/useGlobalFilters.js +3 -3
- package/dist/bigconsole/hooks/useImportDataSink.js +102 -90
- package/dist/bigconsole/pages/AdminPage.js +130 -130
- package/dist/bigconsole/pages/DashboardBuilderPage.js +60 -72
- package/dist/bigconsole/pages/DashboardViewPage.js +235 -258
- package/dist/bigconsole/pages/DashboardsPage.js +221 -269
- package/dist/bigconsole/pages/DataParsersPage.js +157 -180
- package/dist/bigconsole/pages/DataSinkAlertsPage.js +55 -62
- package/dist/bigconsole/pages/DataSinkBuilderPage.js +318 -295
- package/dist/bigconsole/pages/DataSinkViewPage.js +256 -255
- package/dist/bigconsole/pages/DataSinksPage.js +216 -251
- package/dist/bigconsole/pages/DataSourcesPage.js +5 -5
- package/dist/bigconsole/pages/InsightsPage.js +265 -279
- package/dist/bigconsole/pages/OverviewPage.js +47 -47
- package/dist/bigconsole/pages/ParserBuilderPage.js +213 -229
- package/dist/bigconsole/pages/ParserViewPage.js +97 -97
- package/dist/bigconsole/pages/PipelineBuilderPage.js +214 -256
- package/dist/bigconsole/pages/PipelineViewPage.js +146 -146
- package/dist/bigconsole/pages/PipelinesPage.js +88 -107
- package/dist/bigconsole/pages/SettingsPage.js +173 -179
- package/dist/bigconsole/pages/WidgetDemoPage.js +42 -42
- package/dist/bigconsole/pages/WorkflowViewPage.js +1 -1
- package/dist/bigconsole/pages/WorkflowsPage.js +141 -141
- package/dist/bigconsole/providers/BigConsoleQuotaProvider.js +12 -12
- package/dist/bigconsole/renderers/adapters/AdaptiveCardRenderer.js +235 -122
- package/dist/bigconsole/renderers/adapters/BlockKitRenderer.d.ts +6 -1
- package/dist/bigconsole/renderers/adapters/BlockKitRenderer.js +151 -151
- package/dist/bigconsole/renderers/adapters/CustomRenderer.js +46 -46
- package/dist/bigconsole/renderers/adapters/adaptiveCardContent.d.ts +29 -0
- package/dist/bigconsole/renderers/adapters/adaptiveCardContent.js +51 -0
- package/dist/bigconsole/store/widgetStore.d.ts +0 -12
- package/dist/bigconsole/store/widgetStore.js +1 -3
- package/dist/bigconsole/types/index.d.ts +17 -2
- package/dist/bigconsole/utils/backendError.d.ts +0 -18
- package/dist/bigconsole/utils/dataSinkPayload.d.ts +48 -0
- package/dist/bigconsole/utils/dataSinkPayload.js +38 -0
- package/dist/bigconsole/utils/index.d.ts +2 -0
- package/dist/bigconsole/utils/safeUrl.d.ts +79 -0
- package/dist/bigconsole/utils/safeUrl.js +93 -0
- package/dist/bigconsole/utils/sanitizeHtml.d.ts +16 -0
- package/dist/bigconsole/utils/sanitizeHtml.js +67 -0
- package/dist/bigconsole/workflowOpen.js +14 -15
- package/dist/generated/wspace-operations.d.ts +138 -8
- package/dist/generated/wspace-operations.js +281 -240
- package/dist/node_modules/dompurify/dist/purify.es.js +800 -0
- package/package.json +9 -5
- package/dist/bigconsole/assistant/displayCopy.d.ts +0 -32
- package/dist/bigconsole/assistant/pageControls.d.ts +0 -81
- package/dist/bigconsole/assistant/pageControls.js +0 -169
- package/dist/bigconsole/assistant/previewControl.d.ts +0 -16
- package/dist/bigconsole/assistant/previewControl.js +0 -10
- package/dist/bigconsole/assistant/usePreviewControl.d.ts +0 -2
- package/dist/bigconsole/assistant/usePreviewControl.js +0 -20
- package/dist/bigconsole/components/common/SortBySelect.d.ts +0 -11
- package/dist/bigconsole/components/common/SortBySelect.js +0 -29
- package/dist/bigconsole/constants/backendErrors.js +0 -94
- package/dist/bigconsole/hooks/useDashboardLayoutBaseline.d.ts +0 -14
- package/dist/bigconsole/hooks/useDashboardLayoutBaseline.js +0 -32
- package/dist/bigconsole/utils/backendError.js +0 -42
- package/dist/bigconsole/utils/dashboardList.d.ts +0 -28
- package/dist/bigconsole/utils/dashboardList.js +0 -15
- package/dist/bigconsole/utils/dataSinkList.d.ts +0 -15
- package/dist/bigconsole/utils/dataSinkList.js +0 -15
- package/dist/bigconsole/utils/formDirty.d.ts +0 -82
- package/dist/bigconsole/utils/formDirty.js +0 -21
- package/dist/bigconsole/utils/insightsDraft.d.ts +0 -29
- package/dist/bigconsole/utils/insightsDraft.js +0 -8
- package/dist/bigconsole/utils/layoutBaseline.d.ts +0 -130
- package/dist/bigconsole/utils/layoutBaseline.js +0 -96
- package/dist/bigconsole/utils/listSort.d.ts +0 -80
- package/dist/bigconsole/utils/listSort.js +0 -85
- package/dist/bigconsole/utils/widgetFormDirty.d.ts +0 -16
- package/dist/bigconsole/utils/widgetFormDirty.js +0 -13
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import e from "../../../hooks/useEventWebhooks.js";
|
|
2
2
|
import { memo as t, useCallback as n, useState as r } from "react";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
3
|
+
import { Fragment as i, jsx as a, jsxs as o } from "react/jsx-runtime";
|
|
4
|
+
import { useI18n as s } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
5
5
|
//#region src/bigconsole/components/widgets/webhook-config/WebhookConfigPanel.tsx
|
|
6
6
|
var c = {
|
|
7
7
|
container: {
|
|
@@ -229,43 +229,43 @@ var c = {
|
|
|
229
229
|
color: "var(--color-text-placeholder)",
|
|
230
230
|
marginTop: "4px"
|
|
231
231
|
}
|
|
232
|
-
}, l = t(function({ webhook: e, dashboardId: t, widgetId: n, onSave:
|
|
233
|
-
let { t: d } =
|
|
234
|
-
return /* @__PURE__ */
|
|
232
|
+
}, l = t(function({ webhook: e, dashboardId: t, widgetId: n, onSave: i, onCancel: l, loading: u }) {
|
|
233
|
+
let { t: d } = s(), [f, p] = r(e?.eventPattern || "widget:*:clicked"), [m, h] = r(e?.webhookUrl || ""), [g, _] = r(e?.method || "POST"), [v, y] = r(e?.headers ? JSON.stringify(e.headers, null, 2) : "");
|
|
234
|
+
return /* @__PURE__ */ o("form", {
|
|
235
235
|
style: c.form,
|
|
236
236
|
onSubmit: async (r) => {
|
|
237
237
|
r.preventDefault();
|
|
238
|
-
let
|
|
238
|
+
let a;
|
|
239
239
|
if (v.trim()) try {
|
|
240
|
-
|
|
240
|
+
a = JSON.parse(v);
|
|
241
241
|
} catch {
|
|
242
242
|
alert(d("bigconsole.widget.webhookConfig.invalidJson", "Invalid JSON in headers field"));
|
|
243
243
|
return;
|
|
244
244
|
}
|
|
245
|
-
e ? await
|
|
245
|
+
e ? await i({
|
|
246
246
|
id: e.id,
|
|
247
247
|
eventPattern: f,
|
|
248
248
|
webhookUrl: m,
|
|
249
249
|
method: g,
|
|
250
|
-
headers:
|
|
251
|
-
}) : await
|
|
250
|
+
headers: a || null
|
|
251
|
+
}) : await i({
|
|
252
252
|
dashboardId: t,
|
|
253
253
|
widgetId: n,
|
|
254
254
|
eventPattern: f,
|
|
255
255
|
webhookUrl: m,
|
|
256
256
|
method: g,
|
|
257
|
-
headers:
|
|
257
|
+
headers: a
|
|
258
258
|
});
|
|
259
259
|
},
|
|
260
260
|
children: [
|
|
261
|
-
/* @__PURE__ */
|
|
261
|
+
/* @__PURE__ */ o("div", {
|
|
262
262
|
style: c.formGroup,
|
|
263
263
|
children: [
|
|
264
|
-
/* @__PURE__ */
|
|
264
|
+
/* @__PURE__ */ a("label", {
|
|
265
265
|
style: c.label,
|
|
266
266
|
children: d("bigconsole.widget.webhookConfig.eventPatternLabel", "Event Pattern *")
|
|
267
267
|
}),
|
|
268
|
-
/* @__PURE__ */
|
|
268
|
+
/* @__PURE__ */ a("input", {
|
|
269
269
|
type: "text",
|
|
270
270
|
value: f,
|
|
271
271
|
onChange: (e) => p(e.target.value),
|
|
@@ -273,18 +273,18 @@ var c = {
|
|
|
273
273
|
style: c.input,
|
|
274
274
|
required: !0
|
|
275
275
|
}),
|
|
276
|
-
/* @__PURE__ */
|
|
276
|
+
/* @__PURE__ */ a("p", {
|
|
277
277
|
style: c.helpText,
|
|
278
278
|
children: d("bigconsole.widget.webhookConfig.eventPatternHelp", "Use * as wildcard. Examples: widget:*:clicked, *:submit, button:save:*")
|
|
279
279
|
})
|
|
280
280
|
]
|
|
281
281
|
}),
|
|
282
|
-
/* @__PURE__ */
|
|
282
|
+
/* @__PURE__ */ o("div", {
|
|
283
283
|
style: c.formGroup,
|
|
284
|
-
children: [/* @__PURE__ */
|
|
284
|
+
children: [/* @__PURE__ */ a("label", {
|
|
285
285
|
style: c.label,
|
|
286
286
|
children: d("bigconsole.widget.webhookConfig.webhookUrlLabel", "Webhook URL *")
|
|
287
|
-
}), /* @__PURE__ */
|
|
287
|
+
}), /* @__PURE__ */ a("input", {
|
|
288
288
|
type: "url",
|
|
289
289
|
value: m,
|
|
290
290
|
onChange: (e) => h(e.target.value),
|
|
@@ -293,59 +293,59 @@ var c = {
|
|
|
293
293
|
required: !0
|
|
294
294
|
})]
|
|
295
295
|
}),
|
|
296
|
-
/* @__PURE__ */
|
|
296
|
+
/* @__PURE__ */ o("div", {
|
|
297
297
|
style: c.formGroup,
|
|
298
|
-
children: [/* @__PURE__ */
|
|
298
|
+
children: [/* @__PURE__ */ a("label", {
|
|
299
299
|
style: c.label,
|
|
300
300
|
children: d("bigconsole.widget.webhookConfig.httpMethodLabel", "HTTP Method")
|
|
301
|
-
}), /* @__PURE__ */
|
|
301
|
+
}), /* @__PURE__ */ o("select", {
|
|
302
302
|
value: g,
|
|
303
303
|
onChange: (e) => _(e.target.value),
|
|
304
304
|
style: c.select,
|
|
305
305
|
children: [
|
|
306
|
-
/* @__PURE__ */
|
|
306
|
+
/* @__PURE__ */ a("option", {
|
|
307
307
|
value: "POST",
|
|
308
308
|
children: "POST"
|
|
309
309
|
}),
|
|
310
|
-
/* @__PURE__ */
|
|
310
|
+
/* @__PURE__ */ a("option", {
|
|
311
311
|
value: "PUT",
|
|
312
312
|
children: "PUT"
|
|
313
313
|
}),
|
|
314
|
-
/* @__PURE__ */
|
|
314
|
+
/* @__PURE__ */ a("option", {
|
|
315
315
|
value: "PATCH",
|
|
316
316
|
children: "PATCH"
|
|
317
317
|
}),
|
|
318
|
-
/* @__PURE__ */
|
|
318
|
+
/* @__PURE__ */ a("option", {
|
|
319
319
|
value: "GET",
|
|
320
320
|
children: "GET"
|
|
321
321
|
}),
|
|
322
|
-
/* @__PURE__ */
|
|
322
|
+
/* @__PURE__ */ a("option", {
|
|
323
323
|
value: "DELETE",
|
|
324
324
|
children: "DELETE"
|
|
325
325
|
})
|
|
326
326
|
]
|
|
327
327
|
})]
|
|
328
328
|
}),
|
|
329
|
-
/* @__PURE__ */
|
|
329
|
+
/* @__PURE__ */ o("div", {
|
|
330
330
|
style: c.formGroup,
|
|
331
|
-
children: [/* @__PURE__ */
|
|
331
|
+
children: [/* @__PURE__ */ a("label", {
|
|
332
332
|
style: c.label,
|
|
333
333
|
children: d("bigconsole.widget.webhookConfig.customHeadersLabel", "Custom Headers (JSON)")
|
|
334
|
-
}), /* @__PURE__ */
|
|
334
|
+
}), /* @__PURE__ */ a("textarea", {
|
|
335
335
|
value: v,
|
|
336
336
|
onChange: (e) => y(e.target.value),
|
|
337
337
|
placeholder: "{\n \"Authorization\": \"Bearer your-token\"\n}",
|
|
338
338
|
style: c.textarea
|
|
339
339
|
})]
|
|
340
340
|
}),
|
|
341
|
-
/* @__PURE__ */
|
|
341
|
+
/* @__PURE__ */ o("div", {
|
|
342
342
|
style: c.formActions,
|
|
343
|
-
children: [/* @__PURE__ */
|
|
343
|
+
children: [/* @__PURE__ */ a("button", {
|
|
344
344
|
type: "button",
|
|
345
345
|
onClick: l,
|
|
346
346
|
style: c.cancelButton,
|
|
347
347
|
children: d("bigconsole.widget.webhookConfig.cancel", "Cancel")
|
|
348
|
-
}), /* @__PURE__ */
|
|
348
|
+
}), /* @__PURE__ */ a("button", {
|
|
349
349
|
type: "submit",
|
|
350
350
|
disabled: u,
|
|
351
351
|
style: c.saveButton,
|
|
@@ -355,18 +355,18 @@ var c = {
|
|
|
355
355
|
]
|
|
356
356
|
});
|
|
357
357
|
}), u = t(function({ webhook: e, onEdit: t, onDelete: n, onToggle: r, onTest: l, testResult: u, testing: d }) {
|
|
358
|
-
let { t: f } =
|
|
359
|
-
return /* @__PURE__ */
|
|
358
|
+
let { t: f } = s();
|
|
359
|
+
return /* @__PURE__ */ o("div", {
|
|
360
360
|
style: c.webhookCard,
|
|
361
361
|
children: [
|
|
362
|
-
/* @__PURE__ */
|
|
362
|
+
/* @__PURE__ */ a("div", {
|
|
363
363
|
style: c.webhookHeader,
|
|
364
|
-
children: /* @__PURE__ */
|
|
364
|
+
children: /* @__PURE__ */ o("div", {
|
|
365
365
|
style: c.webhookTitle,
|
|
366
|
-
children: [/* @__PURE__ */
|
|
366
|
+
children: [/* @__PURE__ */ a("span", {
|
|
367
367
|
style: c.webhookName,
|
|
368
368
|
children: e.eventPattern
|
|
369
|
-
}), /* @__PURE__ */
|
|
369
|
+
}), /* @__PURE__ */ a("span", {
|
|
370
370
|
style: {
|
|
371
371
|
...c.statusBadge,
|
|
372
372
|
...e.isActive ? c.activeBadge : c.inactiveBadge
|
|
@@ -375,33 +375,33 @@ var c = {
|
|
|
375
375
|
})]
|
|
376
376
|
})
|
|
377
377
|
}),
|
|
378
|
-
/* @__PURE__ */
|
|
378
|
+
/* @__PURE__ */ o("div", {
|
|
379
379
|
style: c.webhookDetails,
|
|
380
380
|
children: [
|
|
381
381
|
f("bigconsole.widget.webhookConfig.methodLabel", "Method:"),
|
|
382
382
|
" ",
|
|
383
|
-
/* @__PURE__ */
|
|
383
|
+
/* @__PURE__ */ a("strong", { children: e.method })
|
|
384
384
|
]
|
|
385
385
|
}),
|
|
386
|
-
/* @__PURE__ */
|
|
386
|
+
/* @__PURE__ */ a("div", {
|
|
387
387
|
style: c.webhookUrl,
|
|
388
388
|
children: e.webhookUrl
|
|
389
389
|
}),
|
|
390
|
-
u && /* @__PURE__ */
|
|
390
|
+
u && /* @__PURE__ */ a("div", {
|
|
391
391
|
role: "status",
|
|
392
392
|
style: {
|
|
393
393
|
...c.testResult,
|
|
394
394
|
...u.success ? c.testSuccess : c.testFailure
|
|
395
395
|
},
|
|
396
|
-
children: u.success ? /* @__PURE__ */
|
|
396
|
+
children: u.success ? /* @__PURE__ */ a(i, { children: f("bigconsole.widget.webhookConfig.testSuccess", "Test successful! Status: {{statusCode}}, Latency: {{latencyMs}}ms", {
|
|
397
397
|
statusCode: u.statusCode ?? "",
|
|
398
398
|
latencyMs: u.latencyMs ?? ""
|
|
399
|
-
}) }) : /* @__PURE__ */
|
|
399
|
+
}) }) : /* @__PURE__ */ a(i, { children: f("bigconsole.widget.webhookConfig.testFailure", "Test failed: {{error}}", { error: u.errorMessage || f("bigconsole.widget.webhookConfig.unknownError", "Unknown error") }) })
|
|
400
400
|
}),
|
|
401
|
-
/* @__PURE__ */
|
|
401
|
+
/* @__PURE__ */ o("div", {
|
|
402
402
|
style: c.webhookActions,
|
|
403
403
|
children: [
|
|
404
|
-
/* @__PURE__ */
|
|
404
|
+
/* @__PURE__ */ a("button", {
|
|
405
405
|
onClick: t,
|
|
406
406
|
style: {
|
|
407
407
|
...c.actionButton,
|
|
@@ -409,7 +409,7 @@ var c = {
|
|
|
409
409
|
},
|
|
410
410
|
children: f("bigconsole.widget.webhookConfig.edit", "Edit")
|
|
411
411
|
}),
|
|
412
|
-
/* @__PURE__ */
|
|
412
|
+
/* @__PURE__ */ a("button", {
|
|
413
413
|
onClick: l,
|
|
414
414
|
disabled: d,
|
|
415
415
|
style: {
|
|
@@ -418,7 +418,7 @@ var c = {
|
|
|
418
418
|
},
|
|
419
419
|
children: d ? f("bigconsole.widget.webhookConfig.testing", "Testing...") : f("bigconsole.widget.webhookConfig.test", "Test")
|
|
420
420
|
}),
|
|
421
|
-
/* @__PURE__ */
|
|
421
|
+
/* @__PURE__ */ a("button", {
|
|
422
422
|
onClick: r,
|
|
423
423
|
style: {
|
|
424
424
|
...c.actionButton,
|
|
@@ -426,7 +426,7 @@ var c = {
|
|
|
426
426
|
},
|
|
427
427
|
children: e.isActive ? f("bigconsole.widget.webhookConfig.disable", "Disable") : f("bigconsole.widget.webhookConfig.enable", "Enable")
|
|
428
428
|
}),
|
|
429
|
-
/* @__PURE__ */
|
|
429
|
+
/* @__PURE__ */ a("button", {
|
|
430
430
|
onClick: n,
|
|
431
431
|
style: {
|
|
432
432
|
...c.actionButton,
|
|
@@ -438,10 +438,10 @@ var c = {
|
|
|
438
438
|
})
|
|
439
439
|
]
|
|
440
440
|
});
|
|
441
|
-
}), d = t(function({ dashboardId: t, widgetId:
|
|
442
|
-
let { t: p } =
|
|
441
|
+
}), d = t(function({ dashboardId: t, widgetId: i, onWebhookCreated: d, onWebhookDeleted: f }) {
|
|
442
|
+
let { t: p } = s(), [m, h] = r(!1), [g, _] = r(null), [v, y] = r({}), [b, x] = r(null), { webhooks: S, loading: C, createWebhook: w, updateWebhook: T, deleteWebhook: E, toggleWebhook: D, testWebhook: O } = e({
|
|
443
443
|
dashboardId: t,
|
|
444
|
-
widgetId:
|
|
444
|
+
widgetId: i
|
|
445
445
|
}), k = n(async (e) => {
|
|
446
446
|
if ("id" in e) await T(e) && (_(null), h(!1));
|
|
447
447
|
else {
|
|
@@ -472,50 +472,50 @@ var c = {
|
|
|
472
472
|
}, []), P = n(() => {
|
|
473
473
|
h(!1), _(null);
|
|
474
474
|
}, []);
|
|
475
|
-
return /* @__PURE__ */
|
|
475
|
+
return /* @__PURE__ */ o("div", {
|
|
476
476
|
style: c.container,
|
|
477
477
|
"data-testid": "webhook-config-panel",
|
|
478
478
|
children: [
|
|
479
|
-
!m && /* @__PURE__ */
|
|
479
|
+
!m && /* @__PURE__ */ a("div", {
|
|
480
480
|
style: c.header,
|
|
481
|
-
children: /* @__PURE__ */
|
|
481
|
+
children: /* @__PURE__ */ a("button", {
|
|
482
482
|
type: "button",
|
|
483
483
|
onClick: () => h(!0),
|
|
484
484
|
style: c.addButton,
|
|
485
485
|
children: p("bigconsole.widget.webhookConfig.addWebhook", "+ Add Webhook")
|
|
486
486
|
})
|
|
487
487
|
}),
|
|
488
|
-
m && /* @__PURE__ */
|
|
488
|
+
m && /* @__PURE__ */ a(l, {
|
|
489
489
|
webhook: g || void 0,
|
|
490
490
|
dashboardId: t,
|
|
491
|
-
widgetId:
|
|
491
|
+
widgetId: i,
|
|
492
492
|
onSave: k,
|
|
493
493
|
onCancel: P,
|
|
494
494
|
loading: C
|
|
495
495
|
}),
|
|
496
|
-
C && S.length === 0 ? /* @__PURE__ */
|
|
496
|
+
C && S.length === 0 ? /* @__PURE__ */ a("div", {
|
|
497
497
|
style: c.emptyState,
|
|
498
498
|
role: "status",
|
|
499
|
-
children: /* @__PURE__ */
|
|
499
|
+
children: /* @__PURE__ */ a("p", {
|
|
500
500
|
style: c.emptyTitle,
|
|
501
501
|
children: p("bigconsole.widget.webhookConfig.loading", "Loading...")
|
|
502
502
|
})
|
|
503
|
-
}) : S.length === 0 ? /* @__PURE__ */
|
|
503
|
+
}) : S.length === 0 ? /* @__PURE__ */ o("div", {
|
|
504
504
|
style: c.emptyState,
|
|
505
505
|
role: "status",
|
|
506
|
-
children: [/* @__PURE__ */
|
|
506
|
+
children: [/* @__PURE__ */ a("p", {
|
|
507
507
|
style: c.emptyTitle,
|
|
508
508
|
children: p("bigconsole.widget.webhookConfig.noWebhooks", "No webhooks configured")
|
|
509
|
-
}), /* @__PURE__ */
|
|
509
|
+
}), /* @__PURE__ */ a("p", {
|
|
510
510
|
style: {
|
|
511
511
|
fontSize: "var(--font-size-body-sm)",
|
|
512
512
|
marginTop: "8px"
|
|
513
513
|
},
|
|
514
514
|
children: p("bigconsole.widget.webhookConfig.noWebhooksHelp", "Add a webhook to receive events when actions are triggered.")
|
|
515
515
|
})]
|
|
516
|
-
}) : /* @__PURE__ */
|
|
516
|
+
}) : /* @__PURE__ */ a("div", {
|
|
517
517
|
style: c.webhookList,
|
|
518
|
-
children: S.map((e) => /* @__PURE__ */
|
|
518
|
+
children: S.map((e) => /* @__PURE__ */ a(u, {
|
|
519
519
|
webhook: e,
|
|
520
520
|
onEdit: () => N(e),
|
|
521
521
|
onDelete: () => A(e.id),
|
|
@@ -4,12 +4,12 @@ import { decideWorkflowOpenView as t, isCreateIntent as n, toLookupClient as r,
|
|
|
4
4
|
import { memo as a, useEffect as o, useState as s } from "react";
|
|
5
5
|
import { useLocation as c } from "react-router";
|
|
6
6
|
import { Spinner as l } from "@burdenoff/fe-libs/ui";
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
7
|
+
import { useApolloClient as u } from "@apollo/client/react";
|
|
8
|
+
import { Fragment as d, jsx as f, jsxs as p } from "react/jsx-runtime";
|
|
9
|
+
import { useI18n as m } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
10
10
|
//#region src/bigconsole/components/workflow/WorkflowOpenGuard.tsx
|
|
11
11
|
var h = a(function({ workflowKey: a, children: h }) {
|
|
12
|
-
let { t: g } =
|
|
12
|
+
let { t: g } = m(), _ = e(), v = u(), y = n(c().state), [b, x] = s(null), [S, C] = s(null), [w, T] = s(null), [E, D] = s(0);
|
|
13
13
|
o(() => {
|
|
14
14
|
if (!a) return;
|
|
15
15
|
if (y) {
|
|
@@ -37,50 +37,50 @@ var h = a(function({ workflowKey: a, children: h }) {
|
|
|
37
37
|
absentKey: S,
|
|
38
38
|
failedKey: w
|
|
39
39
|
});
|
|
40
|
-
return O === "builder" ? /* @__PURE__ */
|
|
40
|
+
return O === "builder" ? /* @__PURE__ */ f(d, { children: h }) : O === "not-found" ? /* @__PURE__ */ p("div", {
|
|
41
41
|
className: "p-6 flex flex-col items-center justify-center min-h-[400px] text-center gap-4",
|
|
42
42
|
role: "alert",
|
|
43
43
|
children: [
|
|
44
|
-
/* @__PURE__ */
|
|
44
|
+
/* @__PURE__ */ f("p", {
|
|
45
45
|
className: "text-base font-medium text-text-primary",
|
|
46
46
|
children: g("bigconsole.workflows.builder.notFoundTitle", "Workflow not found")
|
|
47
47
|
}),
|
|
48
|
-
/* @__PURE__ */
|
|
48
|
+
/* @__PURE__ */ f("p", {
|
|
49
49
|
className: "text-sm text-text-secondary",
|
|
50
50
|
children: g("bigconsole.workflows.builder.notFoundDescription", "No workflow with this key exists in this workspace. Nothing was created.")
|
|
51
51
|
}),
|
|
52
|
-
/* @__PURE__ */
|
|
52
|
+
/* @__PURE__ */ f("button", {
|
|
53
53
|
type: "button",
|
|
54
54
|
onClick: () => _("/workflows"),
|
|
55
55
|
className: "px-4 py-2 text-sm font-medium text-text-primary bg-bg-sunken hover:bg-border-default rounded-md transition-colors",
|
|
56
56
|
children: g("bigconsole.workflows.view.backToWorkflows", "Back to Workflows")
|
|
57
57
|
})
|
|
58
58
|
]
|
|
59
|
-
}) : O === "failed" ? /* @__PURE__ */
|
|
59
|
+
}) : O === "failed" ? /* @__PURE__ */ p("div", {
|
|
60
60
|
className: "p-6 flex flex-col items-center justify-center min-h-[400px] text-center gap-4",
|
|
61
61
|
role: "alert",
|
|
62
|
-
children: [/* @__PURE__ */
|
|
62
|
+
children: [/* @__PURE__ */ f("p", {
|
|
63
63
|
className: "text-sm text-text-secondary",
|
|
64
64
|
children: g("bigconsole.workflows.builder.loadFailed", "Couldn't load this workflow. Please try again.")
|
|
65
|
-
}), /* @__PURE__ */
|
|
65
|
+
}), /* @__PURE__ */ p("div", {
|
|
66
66
|
className: "flex items-center gap-2",
|
|
67
|
-
children: [/* @__PURE__ */
|
|
67
|
+
children: [/* @__PURE__ */ f("button", {
|
|
68
68
|
type: "button",
|
|
69
69
|
onClick: () => {
|
|
70
70
|
T(null), D((e) => e + 1);
|
|
71
71
|
},
|
|
72
72
|
className: "px-4 py-2 text-sm font-medium text-action-primary-fg bg-action-primary-bg hover:bg-action-primary-bgHover rounded-md transition-colors",
|
|
73
73
|
children: g("bigconsole.workflows.actions.tryAgain", "Try Again")
|
|
74
|
-
}), /* @__PURE__ */
|
|
74
|
+
}), /* @__PURE__ */ f("button", {
|
|
75
75
|
type: "button",
|
|
76
76
|
onClick: () => _("/workflows"),
|
|
77
77
|
className: "px-4 py-2 text-sm font-medium text-text-primary bg-bg-sunken hover:bg-border-default rounded-md transition-colors",
|
|
78
78
|
children: g("bigconsole.workflows.view.backToWorkflows", "Back to Workflows")
|
|
79
79
|
})]
|
|
80
80
|
})]
|
|
81
|
-
}) : /* @__PURE__ */
|
|
81
|
+
}) : /* @__PURE__ */ f("div", {
|
|
82
82
|
className: "flex items-center justify-center min-h-[400px]",
|
|
83
|
-
children: /* @__PURE__ */
|
|
83
|
+
children: /* @__PURE__ */ f(l, { className: "h-8 w-8" })
|
|
84
84
|
});
|
|
85
85
|
});
|
|
86
86
|
//#endregion
|
|
@@ -4,11 +4,11 @@ import "../common/index.js";
|
|
|
4
4
|
import n from "../../hooks/useDataSinkOperations.js";
|
|
5
5
|
import { useState as r } from "react";
|
|
6
6
|
import { Button as i } from "@burdenoff/fe-libs/ui";
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
7
|
+
import { jsx as a, jsxs as o } from "react/jsx-runtime";
|
|
8
|
+
import { useI18n as s } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
9
9
|
//#region src/bigconsole/components/workflow/WorkflowSinkLinkForm.tsx
|
|
10
10
|
function c({ workflowId: c, linkedSinkIds: l, onLinked: u }) {
|
|
11
|
-
let { t: d } =
|
|
11
|
+
let { t: d } = s(), { dataSinks: f, loading: p, error: m } = n(), { linkDataSink: h } = e({ skipFetch: !0 }), [g, _] = r(""), [v, y] = r(0), [b, x] = r(""), [S, C] = r(!1), [w, T] = r(null), E = f.filter((e) => e.isActive && !l.includes(e.id)), D = async (e) => {
|
|
12
12
|
if (e.preventDefault(), !E.some((e) => e.key === g) || S) return;
|
|
13
13
|
let t;
|
|
14
14
|
if (b.trim()) try {
|
|
@@ -34,30 +34,30 @@ function c({ workflowId: c, linkedSinkIds: l, onLinked: u }) {
|
|
|
34
34
|
C(!1);
|
|
35
35
|
}
|
|
36
36
|
}, O = `w-full min-w-0 rounded-input border border-[var(--color-border-subtle)] bg-bg-canvas px-3 py-2 text-sm text-text-primary ${t}`;
|
|
37
|
-
return /* @__PURE__ */
|
|
37
|
+
return /* @__PURE__ */ o("form", {
|
|
38
38
|
onSubmit: D,
|
|
39
39
|
className: "mb-form-gap flex min-w-0 flex-col gap-form-gap rounded-card border border-[var(--color-border-subtle)] bg-bg-sunken p-3",
|
|
40
40
|
children: [
|
|
41
|
-
/* @__PURE__ */
|
|
41
|
+
/* @__PURE__ */ o("label", {
|
|
42
42
|
className: "block text-sm font-medium text-text-primary",
|
|
43
|
-
children: [d("bigconsole.workflows.links.sinkLabel", "Data sink"), /* @__PURE__ */
|
|
43
|
+
children: [d("bigconsole.workflows.links.sinkLabel", "Data sink"), /* @__PURE__ */ o("select", {
|
|
44
44
|
value: g,
|
|
45
45
|
onChange: (e) => _(e.target.value),
|
|
46
46
|
disabled: p || S,
|
|
47
47
|
required: !0,
|
|
48
48
|
className: O,
|
|
49
|
-
children: [/* @__PURE__ */
|
|
49
|
+
children: [/* @__PURE__ */ a("option", {
|
|
50
50
|
value: "",
|
|
51
51
|
children: d("bigconsole.workflows.links.selectSink", "Select a data sink")
|
|
52
|
-
}), E.map((e) => /* @__PURE__ */
|
|
52
|
+
}), E.map((e) => /* @__PURE__ */ a("option", {
|
|
53
53
|
value: e.key,
|
|
54
54
|
children: e.name || e.key
|
|
55
55
|
}, e.id))]
|
|
56
56
|
})]
|
|
57
57
|
}),
|
|
58
|
-
/* @__PURE__ */
|
|
58
|
+
/* @__PURE__ */ o("label", {
|
|
59
59
|
className: "block text-sm font-medium text-text-primary",
|
|
60
|
-
children: [d("bigconsole.workflows.links.priorityLabel", "Priority"), /* @__PURE__ */
|
|
60
|
+
children: [d("bigconsole.workflows.links.priorityLabel", "Priority"), /* @__PURE__ */ a("input", {
|
|
61
61
|
type: "number",
|
|
62
62
|
min: 0,
|
|
63
63
|
step: 1,
|
|
@@ -67,9 +67,9 @@ function c({ workflowId: c, linkedSinkIds: l, onLinked: u }) {
|
|
|
67
67
|
className: O
|
|
68
68
|
})]
|
|
69
69
|
}),
|
|
70
|
-
/* @__PURE__ */
|
|
70
|
+
/* @__PURE__ */ o("label", {
|
|
71
71
|
className: "block text-sm font-medium text-text-primary",
|
|
72
|
-
children: [d("bigconsole.workflows.links.mappingLabel", "Data mapping (optional JSON)"), /* @__PURE__ */
|
|
72
|
+
children: [d("bigconsole.workflows.links.mappingLabel", "Data mapping (optional JSON)"), /* @__PURE__ */ a("textarea", {
|
|
73
73
|
value: b,
|
|
74
74
|
onChange: (e) => x(e.target.value),
|
|
75
75
|
disabled: S,
|
|
@@ -77,16 +77,16 @@ function c({ workflowId: c, linkedSinkIds: l, onLinked: u }) {
|
|
|
77
77
|
className: `${O} resize-y font-mono`
|
|
78
78
|
})]
|
|
79
79
|
}),
|
|
80
|
-
!p && !m && E.length === 0 && /* @__PURE__ */
|
|
80
|
+
!p && !m && E.length === 0 && /* @__PURE__ */ a("p", {
|
|
81
81
|
className: "text-sm text-text-secondary",
|
|
82
82
|
children: d("bigconsole.workflows.links.noAvailable", "No unlinked active data sinks are available in this workspace.")
|
|
83
83
|
}),
|
|
84
|
-
(m || w) && /* @__PURE__ */
|
|
84
|
+
(m || w) && /* @__PURE__ */ a("p", {
|
|
85
85
|
role: "alert",
|
|
86
86
|
className: "text-sm text-status-error-text",
|
|
87
87
|
children: w || d("bigconsole.workflows.links.loadError", "Data sinks could not be loaded. Close and reopen the form to retry.")
|
|
88
88
|
}),
|
|
89
|
-
/* @__PURE__ */
|
|
89
|
+
/* @__PURE__ */ a(i, {
|
|
90
90
|
type: "submit",
|
|
91
91
|
disabled: !g || S || p,
|
|
92
92
|
className: "w-full sm:w-auto",
|
|
@@ -9,6 +9,9 @@ interface BigConsoleContextValue {
|
|
|
9
9
|
tenantId?: string;
|
|
10
10
|
apiGatewayUrl: string;
|
|
11
11
|
authToken: string;
|
|
12
|
+
/** Exact https origins iframe widgets may embed; empty means any https origin. */
|
|
13
|
+
iframeAllowedOrigins: readonly string[];
|
|
14
|
+
dashboardOnly: boolean;
|
|
12
15
|
}
|
|
13
16
|
interface BigConsoleProviderProps {
|
|
14
17
|
children: ReactNode;
|
|
@@ -16,6 +19,12 @@ interface BigConsoleProviderProps {
|
|
|
16
19
|
}
|
|
17
20
|
export declare function BigConsoleProvider({ children, props }: BigConsoleProviderProps): import("react").JSX.Element;
|
|
18
21
|
export declare function useBigConsole(): BigConsoleContextValue;
|
|
22
|
+
/**
|
|
23
|
+
* Like {@link useBigConsole}, but returns `null` instead of throwing when
|
|
24
|
+
* rendered outside a BigConsoleProvider (e.g. a widget rendered by a public
|
|
25
|
+
* component such as DrilldownModal in a host that does not mount the root).
|
|
26
|
+
*/
|
|
27
|
+
export declare function useOptionalBigConsole(): BigConsoleContextValue | null;
|
|
19
28
|
/**
|
|
20
29
|
* Hook for basePath-aware navigation.
|
|
21
30
|
* Returns a navigate function that automatically prepends basePath.
|
|
@@ -25,5 +34,6 @@ export declare function useBigConsole(): BigConsoleContextValue;
|
|
|
25
34
|
* provider. Needed to build absolute URLs for new-tab links (BOFF-7625).
|
|
26
35
|
*/
|
|
27
36
|
export declare function useBigConsoleBasePath(): string;
|
|
37
|
+
export declare function useBigConsoleDashboardOnly(): boolean;
|
|
28
38
|
export declare function useBigConsoleNavigate(): (path: string) => void;
|
|
29
39
|
export {};
|
|
@@ -1,54 +1,71 @@
|
|
|
1
1
|
import { createContext as e, useCallback as t, useContext as n, useMemo as r } from "react";
|
|
2
2
|
import { jsx as i } from "react/jsx-runtime";
|
|
3
3
|
//#region src/bigconsole/context/BigConsoleContext.tsx
|
|
4
|
-
var a =
|
|
5
|
-
function o(
|
|
6
|
-
let
|
|
7
|
-
|
|
8
|
-
|
|
4
|
+
var a = [];
|
|
5
|
+
function o(e) {
|
|
6
|
+
let t = JSON.parse(e);
|
|
7
|
+
if (!Array.isArray(t)) return a;
|
|
8
|
+
let n = t.filter((e) => typeof e == "string");
|
|
9
|
+
return n.length > 0 ? n : a;
|
|
10
|
+
}
|
|
11
|
+
var s = e(null);
|
|
12
|
+
function c({ children: e, props: n }) {
|
|
13
|
+
let { basePath: c = "", navigate: l, currentUser: u, workspaceId: d, tenantId: f, apiGatewayUrl: p, authToken: m, iframeAllowedOrigins: h } = n, g = JSON.stringify(h ?? a), _ = r(() => o(g), [g]), v = c.endsWith("/") ? c.slice(0, -1) : c, y = t((e) => {
|
|
14
|
+
if (!v || v === "/") {
|
|
15
|
+
l(e);
|
|
9
16
|
return;
|
|
10
17
|
}
|
|
11
|
-
if (e.startsWith(
|
|
12
|
-
|
|
18
|
+
if (e.startsWith(v)) {
|
|
19
|
+
l(e);
|
|
13
20
|
return;
|
|
14
21
|
}
|
|
15
|
-
|
|
16
|
-
}, [
|
|
17
|
-
basePath:
|
|
18
|
-
navigate:
|
|
19
|
-
currentUser:
|
|
20
|
-
workspaceId:
|
|
21
|
-
tenantId:
|
|
22
|
-
apiGatewayUrl:
|
|
23
|
-
authToken:
|
|
22
|
+
l(e.startsWith("/") ? `${v}${e}` : `${v}/${e}`);
|
|
23
|
+
}, [v, l]), b = r(() => ({
|
|
24
|
+
basePath: v,
|
|
25
|
+
navigate: y,
|
|
26
|
+
currentUser: u,
|
|
27
|
+
workspaceId: d,
|
|
28
|
+
tenantId: f,
|
|
29
|
+
apiGatewayUrl: p || "",
|
|
30
|
+
authToken: m || "",
|
|
31
|
+
iframeAllowedOrigins: _,
|
|
32
|
+
dashboardOnly: n.dashboardOnly ?? !1
|
|
24
33
|
}), [
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
c,
|
|
28
|
-
l,
|
|
34
|
+
v,
|
|
35
|
+
y,
|
|
29
36
|
u,
|
|
30
37
|
d,
|
|
31
|
-
f
|
|
38
|
+
f,
|
|
39
|
+
p,
|
|
40
|
+
m,
|
|
41
|
+
_,
|
|
42
|
+
n.dashboardOnly
|
|
32
43
|
]);
|
|
33
|
-
return /* @__PURE__ */ i(
|
|
34
|
-
value:
|
|
44
|
+
return /* @__PURE__ */ i(s.Provider, {
|
|
45
|
+
value: b,
|
|
35
46
|
children: e
|
|
36
47
|
});
|
|
37
48
|
}
|
|
38
|
-
function
|
|
39
|
-
let e = n(
|
|
49
|
+
function l() {
|
|
50
|
+
let e = n(s);
|
|
40
51
|
if (!e) throw Error("useBigConsole must be used within a BigConsoleProvider");
|
|
41
52
|
return e;
|
|
42
53
|
}
|
|
43
|
-
function
|
|
44
|
-
return n(
|
|
54
|
+
function u() {
|
|
55
|
+
return n(s);
|
|
45
56
|
}
|
|
46
|
-
function
|
|
47
|
-
|
|
57
|
+
function d() {
|
|
58
|
+
return n(s)?.basePath ?? "";
|
|
59
|
+
}
|
|
60
|
+
function f() {
|
|
61
|
+
return n(s)?.dashboardOnly ?? !1;
|
|
62
|
+
}
|
|
63
|
+
function p() {
|
|
64
|
+
let e = n(s), r = t((e) => {
|
|
48
65
|
let t = window.location.pathname.match(/^(\/bigconsole)/), n = t ? t[1] : "", r = e;
|
|
49
66
|
n && !e.startsWith(n) && (r = e.startsWith("/") ? `${n}${e}` : `${n}/${e}`), window.location.href = r;
|
|
50
67
|
}, []);
|
|
51
68
|
return e?.navigate ?? r;
|
|
52
69
|
}
|
|
53
70
|
//#endregion
|
|
54
|
-
export {
|
|
71
|
+
export { c as BigConsoleProvider, l as useBigConsole, d as useBigConsoleBasePath, f as useBigConsoleDashboardOnly, p as useBigConsoleNavigate, u as useOptionalBigConsole };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { BigConsoleProvider, useBigConsole, useBigConsoleBasePath, useBigConsoleNavigate } from './BigConsoleContext';
|
|
1
|
+
export { BigConsoleProvider, useBigConsole, useBigConsoleBasePath, useBigConsoleDashboardOnly, useBigConsoleNavigate, useOptionalBigConsole, } from './BigConsoleContext';
|