@burdenoff/microfe-workflows 2026.1110.1 → 2026.1112.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 +25 -1
- package/dist/WorkflowsRoutes.d.ts +0 -10
- package/dist/WorkflowsRoutes.js +115 -107
- package/dist/constants/permissions.d.ts +2 -2
- package/dist/constants/permissions.js +1 -1
- package/dist/index.d.ts +2 -6
- package/dist/providers/ManagedAiAuthorityBridge.js +1 -1
- package/dist/providers/WorkflowsProvider.js +1 -1
- package/dist/routePreload.d.ts +46 -0
- package/dist/routePreload.js +66 -0
- package/dist/test-support/moduleMocks.d.ts +3 -1
- package/dist/workflows.js +4 -4
- package/package.json +7 -3
package/README.md
CHANGED
|
@@ -51,12 +51,36 @@ Routes are relative to `basePath`:
|
|
|
51
51
|
- `new`: new workflow builder
|
|
52
52
|
- `workflow/:id/:version`: existing workflow builder
|
|
53
53
|
- `runs` and `runs/:runId`: current user's product-scoped runs
|
|
54
|
-
- `insights`, `templates`, `nodes`, `settings
|
|
54
|
+
- `insights`, `templates`, `nodes`, `settings` and the other pages listed in
|
|
55
|
+
`WORKFLOWS_ROUTE_PAGES` (`src/routePreload.ts`): shared SDK pages
|
|
55
56
|
- any unknown path redirects to `list`
|
|
56
57
|
|
|
57
58
|
Product-specific bot or application bindings use the workspace gateway and
|
|
58
59
|
navigate to these routes; they do not own SDK configuration.
|
|
59
60
|
|
|
61
|
+
### Loading only the route's page
|
|
62
|
+
|
|
63
|
+
Every route renders its page from `@burdenoff/fluidgrids-fe-sdk/workflow-pages`,
|
|
64
|
+
where each page is its own lazy module, so a route loads only its own page. On a
|
|
65
|
+
cold load the route renders only after the shell's own code and session check;
|
|
66
|
+
a shell that knows the address at boot can start the page's code earlier from
|
|
67
|
+
the light `./route-preload` subpath (it imports only the SDK's page loaders):
|
|
68
|
+
|
|
69
|
+
```ts
|
|
70
|
+
import { preloadWorkflowsRoute } from '@burdenoff/microfe-workflows/route-preload';
|
|
71
|
+
|
|
72
|
+
preloadWorkflowsRoute(window.location.pathname, '/workflows');
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
Once a page other than the builder has settled, the routes warm the builder's
|
|
76
|
+
code in an idle period, so opening a workflow does not wait for it.
|
|
77
|
+
|
|
78
|
+
The main entry exports `WorkflowsRoot`, the redirect rules, the plugin, the
|
|
79
|
+
route table and the module's config and translations. It no longer re-exports
|
|
80
|
+
SDK components, hooks or pages: a static re-export from the SDK's main barrel
|
|
81
|
+
loaded every SDK page with `WorkflowsRoot`. Import those from
|
|
82
|
+
`@burdenoff/fluidgrids-fe-sdk` directly.
|
|
83
|
+
|
|
60
84
|
## Development
|
|
61
85
|
|
|
62
86
|
Run `bun install` and `bun run sanity` to validate lint, formatting, types, unit
|
|
@@ -1,11 +1 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Internal router for the Workflows microfrontend.
|
|
3
|
-
* Uses relative paths - parent route handles base path (/workflows/*).
|
|
4
|
-
*
|
|
5
|
-
* Workflows is a core module — all pages are always available.
|
|
6
|
-
*
|
|
7
|
-
* NOTE: /credentials and /oauth/callback routes have been removed.
|
|
8
|
-
* Connection management is now handled by microfe-integrations at /integrations/connections.
|
|
9
|
-
* OAuth callbacks are handled by the integrations service REST endpoint.
|
|
10
|
-
*/
|
|
11
1
|
export declare function WorkflowsRoutes(): React.JSX.Element;
|
package/dist/WorkflowsRoutes.js
CHANGED
|
@@ -1,39 +1,41 @@
|
|
|
1
1
|
import { useWorkflowsTranslation as e } from "./i18n.js";
|
|
2
2
|
import { WORKFLOW_PERMISSIONS as t } from "./constants/permissions.js";
|
|
3
3
|
import { RouteTransition as n } from "./components/RouteTransition.js";
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
4
|
+
import { scheduleWorkflowPagePreload as r, workflowsRoutePage as i } from "./routePreload.js";
|
|
5
|
+
import { Suspense as a, useEffect as o } from "react";
|
|
6
|
+
import { AccessDenied as s, PermissionGate as c } from "@burdenoff/fe-libs/shared/components";
|
|
7
|
+
import { GlassCard as l } from "@burdenoff/fe-libs/ui";
|
|
8
|
+
import { useFluidGridsFlagsSettled as u, useSelfHostedWorkersEnabled as d } from "@burdenoff/fluidgrids-fe-sdk/workflow-host";
|
|
9
|
+
import { jsx as f, jsxs as p } from "react/jsx-runtime";
|
|
10
|
+
import { Navigate as m, Route as h, Routes as g, useLocation as _, useParams as v } from "react-router";
|
|
11
|
+
import { AiStudioPage as y, ApprovalInboxPage as b, DataSinkDashboardPage as x, DataTablesPage as S, ErrorAnalyticsPage as C, ExecutionDetailPage as w, ExecutionsListPage as T, HistoryPage as E, InsightsPage as D, NodesPage as O, RunnersPage as k, SettingsPage as A, TaskQueuesPage as j, TemplatePreview as M, TemplatesPage as N, VariablesPage as P, WorkflowBuilderPage as F, WorkflowSearchRedirect as I, WorkflowsList as L } from "@burdenoff/fluidgrids-fe-sdk/workflow-pages";
|
|
10
12
|
// src/WorkflowsRoutes.tsx
|
|
11
|
-
function
|
|
13
|
+
function R() {
|
|
12
14
|
let t = e();
|
|
13
|
-
return /* @__PURE__ */
|
|
15
|
+
return /* @__PURE__ */ p("div", {
|
|
14
16
|
className: "mx-auto flex w-full max-w-6xl flex-col gap-6 px-4 py-6 sm:px-6",
|
|
15
17
|
role: "status",
|
|
16
18
|
"aria-live": "polite",
|
|
17
19
|
"aria-busy": "true",
|
|
18
20
|
"aria-label": t("workflows.routes.loading.ariaLabel", "Loading workflow page"),
|
|
19
21
|
children: [
|
|
20
|
-
/* @__PURE__ */
|
|
22
|
+
/* @__PURE__ */ p("div", {
|
|
21
23
|
className: "flex flex-col gap-3",
|
|
22
|
-
children: [/* @__PURE__ */
|
|
24
|
+
children: [/* @__PURE__ */ f("div", { className: "h-7 w-48 rounded-md bg-muted/60 motion-safe:animate-vc-shimmer" }), /* @__PURE__ */ f("div", { className: "h-4 w-72 max-w-full rounded bg-muted/40 motion-safe:animate-vc-shimmer" })]
|
|
23
25
|
}),
|
|
24
|
-
/* @__PURE__ */
|
|
26
|
+
/* @__PURE__ */ f("div", {
|
|
25
27
|
className: "grid grid-cols-1 gap-4 sm:grid-cols-2 lg:grid-cols-3",
|
|
26
28
|
children: [
|
|
27
29
|
0,
|
|
28
30
|
1,
|
|
29
31
|
2
|
|
30
|
-
].map((e) => /* @__PURE__ */
|
|
32
|
+
].map((e) => /* @__PURE__ */ p(l, {
|
|
31
33
|
treatment: "metric",
|
|
32
34
|
className: "flex flex-col gap-3 border-border-seam p-5",
|
|
33
|
-
children: [/* @__PURE__ */
|
|
35
|
+
children: [/* @__PURE__ */ f("div", { className: "h-3 w-20 rounded bg-muted/50 motion-safe:animate-vc-shimmer" }), /* @__PURE__ */ f("div", { className: "h-8 w-24 rounded-md bg-muted/60 motion-safe:animate-vc-shimmer" })]
|
|
34
36
|
}, e))
|
|
35
37
|
}),
|
|
36
|
-
/* @__PURE__ */
|
|
38
|
+
/* @__PURE__ */ f(l, {
|
|
37
39
|
treatment: "glass",
|
|
38
40
|
className: "flex flex-col gap-4 border-border-seam p-6",
|
|
39
41
|
children: [
|
|
@@ -41,214 +43,220 @@ function F() {
|
|
|
41
43
|
1,
|
|
42
44
|
2,
|
|
43
45
|
3
|
|
44
|
-
].map((e) => /* @__PURE__ */
|
|
46
|
+
].map((e) => /* @__PURE__ */ p("div", {
|
|
45
47
|
className: "flex items-center gap-4",
|
|
46
|
-
children: [/* @__PURE__ */
|
|
48
|
+
children: [/* @__PURE__ */ f("div", { className: "h-10 w-10 shrink-0 rounded-full bg-muted/50 motion-safe:animate-vc-shimmer" }), /* @__PURE__ */ p("div", {
|
|
47
49
|
className: "flex flex-1 flex-col gap-2",
|
|
48
|
-
children: [/* @__PURE__ */
|
|
50
|
+
children: [/* @__PURE__ */ f("div", { className: "h-4 w-1/3 rounded bg-muted/50 motion-safe:animate-vc-shimmer" }), /* @__PURE__ */ f("div", { className: "h-3 w-2/3 rounded bg-muted/30 motion-safe:animate-vc-shimmer" })]
|
|
49
51
|
})]
|
|
50
52
|
}, e))
|
|
51
53
|
}),
|
|
52
|
-
/* @__PURE__ */
|
|
54
|
+
/* @__PURE__ */ f("p", {
|
|
53
55
|
className: "text-center text-sm text-text-secondary",
|
|
54
56
|
children: t("workflows.routes.loading.message", "Loading workflow page...")
|
|
55
57
|
})
|
|
56
58
|
]
|
|
57
59
|
});
|
|
58
60
|
}
|
|
59
|
-
function
|
|
60
|
-
let { runId: e } =
|
|
61
|
-
return /* @__PURE__ */
|
|
61
|
+
function z() {
|
|
62
|
+
let { runId: e } = v();
|
|
63
|
+
return /* @__PURE__ */ f(m, {
|
|
62
64
|
to: `../runs/${e}`,
|
|
63
65
|
replace: !0
|
|
64
66
|
});
|
|
65
67
|
}
|
|
66
|
-
function
|
|
67
|
-
let { pathname: e } =
|
|
68
|
-
return /* @__PURE__ */
|
|
68
|
+
function B() {
|
|
69
|
+
let { pathname: e } = _(), t = v()["*"] ?? "", n = t && e.endsWith(t) ? e.slice(0, -t.length) : e, r = n.endsWith("/") ? n : `${n}/`;
|
|
70
|
+
return /* @__PURE__ */ f(m, {
|
|
69
71
|
to: `${r}list`,
|
|
70
72
|
replace: !0
|
|
71
73
|
});
|
|
72
74
|
}
|
|
73
|
-
function
|
|
74
|
-
let e =
|
|
75
|
-
return !e && !n ? /* @__PURE__ */
|
|
75
|
+
function V() {
|
|
76
|
+
let e = d(), n = u();
|
|
77
|
+
return !e && !n ? /* @__PURE__ */ f(R, {}) : e ? /* @__PURE__ */ f(c, {
|
|
76
78
|
permission: t.TASK_QUEUE_READ,
|
|
77
|
-
fallback: /* @__PURE__ */
|
|
78
|
-
children: /* @__PURE__ */
|
|
79
|
-
}) : /* @__PURE__ */
|
|
79
|
+
fallback: /* @__PURE__ */ f(s, {}),
|
|
80
|
+
children: /* @__PURE__ */ f(j, {})
|
|
81
|
+
}) : /* @__PURE__ */ f(m, {
|
|
80
82
|
to: "../list",
|
|
81
83
|
replace: !0
|
|
82
84
|
});
|
|
83
85
|
}
|
|
84
|
-
function
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
86
|
+
function H() {
|
|
87
|
+
let { pathname: e } = _(), t = v()["*"] ?? "", n = t && e.endsWith(t) ? e.slice(0, -t.length) : e, a = i(e, n) === "WorkflowBuilderPage";
|
|
88
|
+
o(() => {
|
|
89
|
+
if (!a) return r("WorkflowBuilderPage");
|
|
90
|
+
}, [a]);
|
|
91
|
+
}
|
|
92
|
+
function U() {
|
|
93
|
+
return H(), /* @__PURE__ */ f(a, {
|
|
94
|
+
fallback: /* @__PURE__ */ f(R, {}),
|
|
95
|
+
children: /* @__PURE__ */ p(g, { children: [
|
|
96
|
+
/* @__PURE__ */ f(h, {
|
|
89
97
|
index: !0,
|
|
90
|
-
element: /* @__PURE__ */
|
|
98
|
+
element: /* @__PURE__ */ f(m, {
|
|
91
99
|
to: "list",
|
|
92
100
|
replace: !0
|
|
93
101
|
})
|
|
94
102
|
}),
|
|
95
|
-
/* @__PURE__ */
|
|
103
|
+
/* @__PURE__ */ f(h, {
|
|
96
104
|
path: "list",
|
|
97
|
-
element: /* @__PURE__ */
|
|
105
|
+
element: /* @__PURE__ */ f(n, { children: /* @__PURE__ */ f(L, {}) })
|
|
98
106
|
}),
|
|
99
|
-
/* @__PURE__ */
|
|
107
|
+
/* @__PURE__ */ f(h, {
|
|
100
108
|
path: "new",
|
|
101
|
-
element: /* @__PURE__ */
|
|
109
|
+
element: /* @__PURE__ */ f(n, {
|
|
102
110
|
kind: "canvas",
|
|
103
|
-
children: /* @__PURE__ */
|
|
111
|
+
children: /* @__PURE__ */ f(F, {})
|
|
104
112
|
})
|
|
105
113
|
}),
|
|
106
|
-
/* @__PURE__ */
|
|
114
|
+
/* @__PURE__ */ f(h, {
|
|
107
115
|
path: "workflow/:id/:version",
|
|
108
|
-
element: /* @__PURE__ */
|
|
116
|
+
element: /* @__PURE__ */ f(n, {
|
|
109
117
|
kind: "canvas",
|
|
110
|
-
children: /* @__PURE__ */
|
|
118
|
+
children: /* @__PURE__ */ f(F, {})
|
|
111
119
|
})
|
|
112
120
|
}),
|
|
113
|
-
/* @__PURE__ */
|
|
121
|
+
/* @__PURE__ */ f(h, {
|
|
114
122
|
path: "builder",
|
|
115
|
-
element: /* @__PURE__ */
|
|
123
|
+
element: /* @__PURE__ */ f(m, {
|
|
116
124
|
to: "../new",
|
|
117
125
|
replace: !0
|
|
118
126
|
})
|
|
119
127
|
}),
|
|
120
|
-
/* @__PURE__ */
|
|
128
|
+
/* @__PURE__ */ f(h, {
|
|
121
129
|
path: "builder/:id/:version",
|
|
122
|
-
element: /* @__PURE__ */
|
|
130
|
+
element: /* @__PURE__ */ f(n, {
|
|
123
131
|
kind: "canvas",
|
|
124
|
-
children: /* @__PURE__ */
|
|
132
|
+
children: /* @__PURE__ */ f(F, {})
|
|
125
133
|
})
|
|
126
134
|
}),
|
|
127
|
-
/* @__PURE__ */
|
|
135
|
+
/* @__PURE__ */ f(h, {
|
|
128
136
|
path: "resolve/:id",
|
|
129
|
-
element: /* @__PURE__ */
|
|
137
|
+
element: /* @__PURE__ */ f(I, {})
|
|
130
138
|
}),
|
|
131
|
-
/* @__PURE__ */
|
|
139
|
+
/* @__PURE__ */ f(h, {
|
|
132
140
|
path: "runs",
|
|
133
|
-
element: /* @__PURE__ */
|
|
141
|
+
element: /* @__PURE__ */ f(n, { children: /* @__PURE__ */ f(T, {}) })
|
|
134
142
|
}),
|
|
135
|
-
/* @__PURE__ */
|
|
143
|
+
/* @__PURE__ */ f(h, {
|
|
136
144
|
path: "runs/:runId",
|
|
137
|
-
element: /* @__PURE__ */
|
|
145
|
+
element: /* @__PURE__ */ f(n, { children: /* @__PURE__ */ f(w, {}) })
|
|
138
146
|
}),
|
|
139
|
-
/* @__PURE__ */
|
|
147
|
+
/* @__PURE__ */ f(h, {
|
|
140
148
|
path: "ai-studio",
|
|
141
|
-
element: /* @__PURE__ */
|
|
149
|
+
element: /* @__PURE__ */ f(n, { children: /* @__PURE__ */ f(y, {}) })
|
|
142
150
|
}),
|
|
143
|
-
/* @__PURE__ */
|
|
151
|
+
/* @__PURE__ */ f(h, {
|
|
144
152
|
path: "insights",
|
|
145
|
-
element: /* @__PURE__ */
|
|
153
|
+
element: /* @__PURE__ */ f(n, { children: /* @__PURE__ */ f(D, {}) })
|
|
146
154
|
}),
|
|
147
|
-
/* @__PURE__ */
|
|
155
|
+
/* @__PURE__ */ f(h, {
|
|
148
156
|
path: "insights/errors",
|
|
149
|
-
element: /* @__PURE__ */
|
|
157
|
+
element: /* @__PURE__ */ f(n, { children: /* @__PURE__ */ f(C, {}) })
|
|
150
158
|
}),
|
|
151
|
-
/* @__PURE__ */
|
|
159
|
+
/* @__PURE__ */ f(h, {
|
|
152
160
|
path: "data-sinks",
|
|
153
|
-
element: /* @__PURE__ */
|
|
161
|
+
element: /* @__PURE__ */ f(n, { children: /* @__PURE__ */ f(x, {}) })
|
|
154
162
|
}),
|
|
155
|
-
/* @__PURE__ */
|
|
163
|
+
/* @__PURE__ */ f(h, {
|
|
156
164
|
path: "data-tables",
|
|
157
|
-
element: /* @__PURE__ */
|
|
165
|
+
element: /* @__PURE__ */ f(n, { children: /* @__PURE__ */ f(S, {}) })
|
|
158
166
|
}),
|
|
159
|
-
/* @__PURE__ */
|
|
167
|
+
/* @__PURE__ */ f(h, {
|
|
160
168
|
path: "approvals",
|
|
161
|
-
element: /* @__PURE__ */
|
|
169
|
+
element: /* @__PURE__ */ f(n, { children: /* @__PURE__ */ f(c, {
|
|
162
170
|
permission: t.WORKFLOW_RUN_READ,
|
|
163
|
-
fallback: /* @__PURE__ */
|
|
164
|
-
children: /* @__PURE__ */
|
|
171
|
+
fallback: /* @__PURE__ */ f(s, {}),
|
|
172
|
+
children: /* @__PURE__ */ f(b, {})
|
|
165
173
|
}) })
|
|
166
174
|
}),
|
|
167
|
-
/* @__PURE__ */
|
|
175
|
+
/* @__PURE__ */ f(h, {
|
|
168
176
|
path: "history",
|
|
169
|
-
element: /* @__PURE__ */
|
|
177
|
+
element: /* @__PURE__ */ f(n, { children: /* @__PURE__ */ f(E, {}) })
|
|
170
178
|
}),
|
|
171
|
-
/* @__PURE__ */
|
|
179
|
+
/* @__PURE__ */ f(h, {
|
|
172
180
|
path: "templates",
|
|
173
|
-
element: /* @__PURE__ */
|
|
181
|
+
element: /* @__PURE__ */ f(n, { children: /* @__PURE__ */ f(N, {}) })
|
|
174
182
|
}),
|
|
175
|
-
/* @__PURE__ */
|
|
183
|
+
/* @__PURE__ */ f(h, {
|
|
176
184
|
path: "templates/:productId/preview",
|
|
177
|
-
element: /* @__PURE__ */
|
|
185
|
+
element: /* @__PURE__ */ f(n, {
|
|
178
186
|
kind: "canvas",
|
|
179
|
-
children: /* @__PURE__ */
|
|
187
|
+
children: /* @__PURE__ */ f(M, {})
|
|
180
188
|
})
|
|
181
189
|
}),
|
|
182
|
-
/* @__PURE__ */
|
|
190
|
+
/* @__PURE__ */ f(h, {
|
|
183
191
|
path: "nodes",
|
|
184
|
-
element: /* @__PURE__ */
|
|
192
|
+
element: /* @__PURE__ */ f(n, { children: /* @__PURE__ */ f(O, {}) })
|
|
185
193
|
}),
|
|
186
|
-
/* @__PURE__ */
|
|
194
|
+
/* @__PURE__ */ f(h, {
|
|
187
195
|
path: "settings",
|
|
188
|
-
element: /* @__PURE__ */
|
|
196
|
+
element: /* @__PURE__ */ f(n, { children: /* @__PURE__ */ f(c, {
|
|
189
197
|
permission: t.SYSTEM_CONFIG_READ,
|
|
190
|
-
fallback: /* @__PURE__ */
|
|
191
|
-
children: /* @__PURE__ */
|
|
198
|
+
fallback: /* @__PURE__ */ f(s, {}),
|
|
199
|
+
children: /* @__PURE__ */ f(A, {})
|
|
192
200
|
}) })
|
|
193
201
|
}),
|
|
194
|
-
/* @__PURE__ */
|
|
202
|
+
/* @__PURE__ */ f(h, {
|
|
195
203
|
path: "settings/:workflowKey",
|
|
196
|
-
element: /* @__PURE__ */
|
|
204
|
+
element: /* @__PURE__ */ f(n, { children: /* @__PURE__ */ f(c, {
|
|
197
205
|
permission: t.SYSTEM_CONFIG_READ,
|
|
198
|
-
fallback: /* @__PURE__ */
|
|
199
|
-
children: /* @__PURE__ */
|
|
206
|
+
fallback: /* @__PURE__ */ f(s, {}),
|
|
207
|
+
children: /* @__PURE__ */ f(A, {})
|
|
200
208
|
}) })
|
|
201
209
|
}),
|
|
202
|
-
/* @__PURE__ */
|
|
210
|
+
/* @__PURE__ */ f(h, {
|
|
203
211
|
path: "variables",
|
|
204
|
-
element: /* @__PURE__ */
|
|
212
|
+
element: /* @__PURE__ */ f(n, { children: /* @__PURE__ */ f(c, {
|
|
205
213
|
permission: t.VARIABLE_READ,
|
|
206
|
-
fallback: /* @__PURE__ */
|
|
207
|
-
children: /* @__PURE__ */
|
|
214
|
+
fallback: /* @__PURE__ */ f(s, {}),
|
|
215
|
+
children: /* @__PURE__ */ f(P, {})
|
|
208
216
|
}) })
|
|
209
217
|
}),
|
|
210
|
-
/* @__PURE__ */
|
|
218
|
+
/* @__PURE__ */ f(h, {
|
|
211
219
|
path: "runners",
|
|
212
|
-
element: /* @__PURE__ */
|
|
220
|
+
element: /* @__PURE__ */ f(n, { children: /* @__PURE__ */ f(c, {
|
|
213
221
|
permission: t.SANDBOX_READ,
|
|
214
|
-
fallback: /* @__PURE__ */
|
|
215
|
-
children: /* @__PURE__ */
|
|
222
|
+
fallback: /* @__PURE__ */ f(s, {}),
|
|
223
|
+
children: /* @__PURE__ */ f(k, {})
|
|
216
224
|
}) })
|
|
217
225
|
}),
|
|
218
|
-
/* @__PURE__ */
|
|
226
|
+
/* @__PURE__ */ f(h, {
|
|
219
227
|
path: "task-queues",
|
|
220
|
-
element: /* @__PURE__ */
|
|
228
|
+
element: /* @__PURE__ */ f(n, { children: /* @__PURE__ */ f(V, {}) })
|
|
221
229
|
}),
|
|
222
|
-
/* @__PURE__ */
|
|
230
|
+
/* @__PURE__ */ f(h, {
|
|
223
231
|
path: "executions",
|
|
224
|
-
element: /* @__PURE__ */
|
|
232
|
+
element: /* @__PURE__ */ f(m, {
|
|
225
233
|
to: "../runs",
|
|
226
234
|
replace: !0
|
|
227
235
|
})
|
|
228
236
|
}),
|
|
229
|
-
/* @__PURE__ */
|
|
237
|
+
/* @__PURE__ */ f(h, {
|
|
230
238
|
path: "executions/:runId",
|
|
231
|
-
element: /* @__PURE__ */
|
|
239
|
+
element: /* @__PURE__ */ f(z, {})
|
|
232
240
|
}),
|
|
233
|
-
/* @__PURE__ */
|
|
241
|
+
/* @__PURE__ */ f(h, {
|
|
234
242
|
path: "credentials",
|
|
235
|
-
element: /* @__PURE__ */
|
|
243
|
+
element: /* @__PURE__ */ f(m, {
|
|
236
244
|
to: "/integrations/connections",
|
|
237
245
|
replace: !0
|
|
238
246
|
})
|
|
239
247
|
}),
|
|
240
|
-
/* @__PURE__ */
|
|
248
|
+
/* @__PURE__ */ f(h, {
|
|
241
249
|
path: "oauth/callback",
|
|
242
|
-
element: /* @__PURE__ */
|
|
250
|
+
element: /* @__PURE__ */ f(m, {
|
|
243
251
|
to: "/integrations/connections",
|
|
244
252
|
replace: !0
|
|
245
253
|
})
|
|
246
254
|
}),
|
|
247
|
-
/* @__PURE__ */
|
|
255
|
+
/* @__PURE__ */ f(h, {
|
|
248
256
|
path: "*",
|
|
249
|
-
element: /* @__PURE__ */
|
|
257
|
+
element: /* @__PURE__ */ f(B, {})
|
|
250
258
|
})
|
|
251
259
|
] })
|
|
252
260
|
});
|
|
253
261
|
}
|
|
254
|
-
export {
|
|
262
|
+
export { U as WorkflowsRoutes };
|
|
@@ -6,5 +6,5 @@
|
|
|
6
6
|
* pairs). Use with the fe-libs usePermissions hook:
|
|
7
7
|
* hasPermission(WORKFLOW_PERMISSIONS.WORKFLOW_CREATE)
|
|
8
8
|
*/
|
|
9
|
-
export { FLUIDGRIDS_PERMISSIONS as WORKFLOW_PERMISSIONS } from '@burdenoff/fluidgrids-fe-sdk';
|
|
10
|
-
export type { FluidGridsPermission as WorkflowPermission } from '@burdenoff/fluidgrids-fe-sdk';
|
|
9
|
+
export { FLUIDGRIDS_PERMISSIONS as WORKFLOW_PERMISSIONS } from '@burdenoff/fluidgrids-fe-sdk/workflow-host';
|
|
10
|
+
export type { FluidGridsPermission as WorkflowPermission } from '@burdenoff/fluidgrids-fe-sdk/workflow-host';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { FLUIDGRIDS_PERMISSIONS as WORKFLOW_PERMISSIONS } from "@burdenoff/fluidgrids-fe-sdk";
|
|
1
|
+
export { FLUIDGRIDS_PERMISSIONS as WORKFLOW_PERMISSIONS } from "@burdenoff/fluidgrids-fe-sdk/workflow-host";
|
package/dist/index.d.ts
CHANGED
|
@@ -3,12 +3,8 @@ export type { WorkflowsRootProps } from './WorkflowsRoot';
|
|
|
3
3
|
export { workflowsSwitchRedirectRules } from './switchRedirectRules';
|
|
4
4
|
export { fluidGridsPlugin, createFluidGridsPlugin, FLUIDGRIDS_PLUGIN_ID, FLUIDGRIDS_PLUGIN_COMMANDS, FLUIDGRIDS_ASSISTANT_TOGGLE_EVENT, } from './plugin';
|
|
5
5
|
export type { FluidGridsPluginOptions } from './plugin';
|
|
6
|
+
export { WORKFLOWS_ROUTE_PAGES, workflowsRoutePage, preloadWorkflowsRoute, scheduleWorkflowPagePreload, } from './routePreload';
|
|
6
7
|
export { config, setWorkflowsConfig, resetWorkflowsConfig } from './config';
|
|
7
8
|
export type { WorkflowsConfig } from './config';
|
|
8
9
|
export { enTranslations } from './translations/en';
|
|
9
|
-
export {
|
|
10
|
-
export type { WorkflowBuilderProps as EmbeddableWorkflowBuilderProps, WorkflowBuilderCoreProps as EmbeddableWorkflowBuilderCoreProps, FluidGridsProviderProps as EmbeddableWorkflowProviderProps, FluidGridsRootProps as EmbeddableWorkflowRootProps, FluidGridsClientConfig as EmbeddableClientConfig, FluidGridsConfig as EmbeddableConfig, WorkflowDefinition, WorkflowData, FlowNode, FlowEdge, NodeManifest, } from '@burdenoff/fluidgrids-fe-sdk';
|
|
11
|
-
export { useNodeEndpoints, useNodeEndpoint, useNodeManifest, useLazyNodeManifest, fetchAllNodesWithManifests, useWorkflowDefinitions, useWorkflowDefinition, useLazyWorkflowDefinition, useWorkflowVersions, useCreateWorkflow, useUpdateWorkflow, useCreateWorkflowVersion, useDeleteWorkflow, useDuplicateWorkflow, useTriggerWorkflow, useWorkflowRuns, useWorkflowRun, useDashboardSummary, setFluidGridsClient, getFluidGridsClient, getFluidGridsClientSafe, isFluidGridsClientReady, waitForFluidGridsClient, resetFluidGridsClient, } from '@burdenoff/fluidgrids-fe-sdk';
|
|
12
|
-
export { ExecutionsListPage, ExecutionDetailPage, HistoryPage, NodesPage, SettingsPage, TemplatesPage, TemplatePreview, WorkflowBuilderPage, WorkflowSearchRedirect, WorkflowsList, } from '@burdenoff/fluidgrids-fe-sdk';
|
|
13
|
-
export { FLUIDGRIDS_FLAGS, useFluidGridsFlag } from '@burdenoff/fluidgrids-fe-sdk';
|
|
14
|
-
export type { FluidGridsFlagKey } from '@burdenoff/fluidgrids-fe-sdk';
|
|
10
|
+
export type { WorkflowBuilderProps as EmbeddableWorkflowBuilderProps, WorkflowBuilderCoreProps as EmbeddableWorkflowBuilderCoreProps, FluidGridsProviderProps as EmbeddableWorkflowProviderProps, FluidGridsRootProps as EmbeddableWorkflowRootProps, FluidGridsClientConfig as EmbeddableClientConfig, FluidGridsConfig as EmbeddableConfig, WorkflowDefinition, WorkflowData, FlowNode, FlowEdge, NodeManifest, FluidGridsFlagKey, } from '@burdenoff/fluidgrids-fe-sdk';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { useMemo as e } from "react";
|
|
2
|
-
import { ManagedAiPolicyAuthorityProvider as t } from "@burdenoff/fluidgrids-fe-sdk";
|
|
2
|
+
import { ManagedAiPolicyAuthorityProvider as t } from "@burdenoff/fluidgrids-fe-sdk/workflow-host";
|
|
3
3
|
import { jsx as n } from "react/jsx-runtime";
|
|
4
4
|
// src/providers/ManagedAiAuthorityBridge.tsx
|
|
5
5
|
function r({ currentUser: r, tenantId: i, organizationId: a, workspaceId: o, projectId: s, apiGatewayUrl: c, authToken: l, workspaceToken: u, children: d }) {
|
|
@@ -4,7 +4,7 @@ import { WorkspaceRequiredGuidance as n } from "./WorkspaceRequiredGuidance.js";
|
|
|
4
4
|
import { ManagedAiAuthorityBridge as r } from "./ManagedAiAuthorityBridge.js";
|
|
5
5
|
import { createContext as i, useEffect as a, useState as o, useSyncExternalStore as s } from "react";
|
|
6
6
|
import { GlassCard as c } from "@burdenoff/fe-libs/ui";
|
|
7
|
-
import { FluidGridsPermissionsProvider as l, FluidGridsTranslationProvider as u,
|
|
7
|
+
import { FluidGridsPermissionsProvider as l, FluidGridsTranslationProvider as u, refreshNodeRegistry as d, resetFluidGridsClient as f, resetFluidGridsConfig as p, resetFluidGridsExecutionState as m, resetGlobalStoreClient as h, setFluidGridsClient as g, setFluidGridsConfig as _, setGlobalStoreClient as v } from "@burdenoff/fluidgrids-fe-sdk/workflow-host";
|
|
8
8
|
import { useGatewayClient as y } from "@burdenoff/fe-libs/shared/graphql";
|
|
9
9
|
import { PermissionProvider as b, usePermissions as x } from "@burdenoff/fe-libs/shared/providers/shell";
|
|
10
10
|
import { jsx as S, jsxs as C } from "react/jsx-runtime";
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import { WorkflowPageName } from '@burdenoff/fluidgrids-fe-sdk/workflow-pages';
|
|
2
|
+
/**
|
|
3
|
+
* Which FluidGrids page each Workflows route renders (BOFF-11826).
|
|
4
|
+
*
|
|
5
|
+
* Every page is its own lazy module (`@burdenoff/fluidgrids-fe-sdk/workflow-pages`),
|
|
6
|
+
* so a route loads only its own page. On a cold load the route renders only
|
|
7
|
+
* after the shell's own code and session check, so a shell that knows the
|
|
8
|
+
* address at boot starts the page's code with {@link preloadWorkflowsRoute}
|
|
9
|
+
* instead of waiting for the route. The paths are relative to where the shell
|
|
10
|
+
* mounts `WorkflowsRoot`; `WorkflowsRoutes` renders exactly these pages (its
|
|
11
|
+
* tests check every entry). Redirects and the index route are not listed: the
|
|
12
|
+
* index sends the visitor to `list`.
|
|
13
|
+
*/
|
|
14
|
+
export declare const WORKFLOWS_ROUTE_PAGES: ReadonlyArray<readonly [path: string, page: WorkflowPageName]>;
|
|
15
|
+
/**
|
|
16
|
+
* The page a Workflows address renders, or null when the address is not under
|
|
17
|
+
* `basePath` or is a redirect. The index (`basePath` itself) renders the list.
|
|
18
|
+
*
|
|
19
|
+
* @param basePath where the shell mounts `WorkflowsRoot` (default `/workflows`).
|
|
20
|
+
*/
|
|
21
|
+
export declare function workflowsRoutePage(pathname: string, basePath?: string): WorkflowPageName | null;
|
|
22
|
+
/**
|
|
23
|
+
* Starts loading the page a Workflows address renders, without rendering it.
|
|
24
|
+
* The route then renders from the same load. Returns the page it started, or
|
|
25
|
+
* null when the address renders none. Best effort: a failed load is left to
|
|
26
|
+
* the route's own load, which retries and reports it.
|
|
27
|
+
*/
|
|
28
|
+
export declare function preloadWorkflowsRoute(pathname: string, basePath?: string): WorkflowPageName | null;
|
|
29
|
+
/**
|
|
30
|
+
* How long after the window's `load` event a background page load waits
|
|
31
|
+
* before it looks for an idle period (the shell's assistant warm-up waits the
|
|
32
|
+
* same, BOFF-11585).
|
|
33
|
+
*/
|
|
34
|
+
export declare const WORKFLOW_PAGE_SETTLE_MS = 3000;
|
|
35
|
+
/**
|
|
36
|
+
* Loads a page's code in the background once the current page has settled: at
|
|
37
|
+
* the first idle period at least `settleMs` after the window's `load` event.
|
|
38
|
+
* The Workflows routes warm the builder this way, so opening a workflow from
|
|
39
|
+
* the list (or a run, a template, AI Studio) does not wait for the builder's
|
|
40
|
+
* code, and the warm-up never competes with the current page's first load.
|
|
41
|
+
* Returns a cancel function.
|
|
42
|
+
*/
|
|
43
|
+
export declare function scheduleWorkflowPagePreload(page: WorkflowPageName, { settleMs, idleTimeoutMs }?: {
|
|
44
|
+
settleMs?: number | undefined;
|
|
45
|
+
idleTimeoutMs?: number | undefined;
|
|
46
|
+
}): () => void;
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import { matchPath as e } from "react-router";
|
|
2
|
+
import { preloadWorkflowPage as t } from "@burdenoff/fluidgrids-fe-sdk/workflow-pages";
|
|
3
|
+
// src/routePreload.ts
|
|
4
|
+
var n = [
|
|
5
|
+
["list", "WorkflowsList"],
|
|
6
|
+
["new", "WorkflowBuilderPage"],
|
|
7
|
+
["workflow/:id/:version", "WorkflowBuilderPage"],
|
|
8
|
+
["builder/:id/:version", "WorkflowBuilderPage"],
|
|
9
|
+
["resolve/:id", "WorkflowSearchRedirect"],
|
|
10
|
+
["runs", "ExecutionsListPage"],
|
|
11
|
+
["runs/:runId", "ExecutionDetailPage"],
|
|
12
|
+
["ai-studio", "AiStudioPage"],
|
|
13
|
+
["insights", "InsightsPage"],
|
|
14
|
+
["insights/errors", "ErrorAnalyticsPage"],
|
|
15
|
+
["data-sinks", "DataSinkDashboardPage"],
|
|
16
|
+
["data-tables", "DataTablesPage"],
|
|
17
|
+
["approvals", "ApprovalInboxPage"],
|
|
18
|
+
["history", "HistoryPage"],
|
|
19
|
+
["templates", "TemplatesPage"],
|
|
20
|
+
["templates/:productId/preview", "TemplatePreview"],
|
|
21
|
+
["nodes", "NodesPage"],
|
|
22
|
+
["settings", "SettingsPage"],
|
|
23
|
+
["settings/:workflowKey", "SettingsPage"],
|
|
24
|
+
["variables", "VariablesPage"],
|
|
25
|
+
["runners", "RunnersPage"],
|
|
26
|
+
["task-queues", "TaskQueuesPage"]
|
|
27
|
+
];
|
|
28
|
+
function r(t, r = "/workflows") {
|
|
29
|
+
let i = r.replace(/\/+$/, "");
|
|
30
|
+
if (t !== i && !t.startsWith(`${i}/`)) return null;
|
|
31
|
+
let a = t.slice(i.length).replace(/^\/+/, "").replace(/\/+$/, "");
|
|
32
|
+
if (a === "") return "WorkflowsList";
|
|
33
|
+
for (let [t, r] of n) if (e({
|
|
34
|
+
path: `/${t}`,
|
|
35
|
+
end: !0
|
|
36
|
+
}, `/${a}`)) return r;
|
|
37
|
+
return null;
|
|
38
|
+
}
|
|
39
|
+
function i(e, n = "/workflows") {
|
|
40
|
+
let i = r(e, n);
|
|
41
|
+
return i && t(i), i;
|
|
42
|
+
}
|
|
43
|
+
var a = 3e3;
|
|
44
|
+
function o(e, { settleMs: n = a, idleTimeoutMs: r = 1e4 } = {}) {
|
|
45
|
+
if (typeof window > "u" || typeof document > "u") return () => {};
|
|
46
|
+
let i = !1, o = () => {}, s = () => {
|
|
47
|
+
i || t(e);
|
|
48
|
+
}, c = () => {
|
|
49
|
+
if (i) return;
|
|
50
|
+
if (typeof window.requestIdleCallback == "function") {
|
|
51
|
+
let e = window.requestIdleCallback(s, { timeout: r });
|
|
52
|
+
o = () => window.cancelIdleCallback(e);
|
|
53
|
+
return;
|
|
54
|
+
}
|
|
55
|
+
let e = setTimeout(s, 0);
|
|
56
|
+
o = () => clearTimeout(e);
|
|
57
|
+
}, l = () => {
|
|
58
|
+
if (i) return;
|
|
59
|
+
let e = setTimeout(c, n);
|
|
60
|
+
o = () => clearTimeout(e);
|
|
61
|
+
};
|
|
62
|
+
return document.readyState === "complete" ? l() : (window.addEventListener("load", l, { once: !0 }), o = () => window.removeEventListener("load", l)), () => {
|
|
63
|
+
i = !0, o();
|
|
64
|
+
};
|
|
65
|
+
}
|
|
66
|
+
export { n as WORKFLOWS_ROUTE_PAGES, a as WORKFLOW_PAGE_SETTLE_MS, i as preloadWorkflowsRoute, o as scheduleWorkflowPagePreload, r as workflowsRoutePage };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ManagedAiRequestScope } from '@burdenoff/fluidgrids-fe-sdk';
|
|
1
|
+
import { ManagedAiRequestScope } from '@burdenoff/fluidgrids-fe-sdk/workflow-host';
|
|
2
2
|
export declare const mockState: {
|
|
3
3
|
granted: Set<string>;
|
|
4
4
|
managedAiScopes: Array<ManagedAiRequestScope | null>;
|
|
@@ -21,6 +21,8 @@ export declare const mockState: {
|
|
|
21
21
|
fn: string;
|
|
22
22
|
args: unknown[];
|
|
23
23
|
}>;
|
|
24
|
+
/** Every page a component under test started loading early, in call order. */
|
|
25
|
+
preloads: string[];
|
|
24
26
|
};
|
|
25
27
|
export declare const SDK_PAGES: readonly ["AiStudioPage", "ApprovalInboxPage", "DataSinkDashboardPage", "DataTablesPage", "ErrorAnalyticsPage", "ExecutionsListPage", "ExecutionDetailPage", "HistoryPage", "InsightsPage", "NodesPage", "RunnersPage", "SettingsPage", "TaskQueuesPage", "TemplatesPage", "TemplatePreview", "VariablesPage", "WorkflowBuilderPage", "WorkflowSearchRedirect", "WorkflowsList"];
|
|
26
28
|
export declare function installModuleMocks(): Promise<void>;
|
package/dist/workflows.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { WorkflowsRoot as e } from "./WorkflowsRoot.js";
|
|
2
2
|
import { workflowsSwitchRedirectRules as t } from "./switchRedirectRules.js";
|
|
3
3
|
import { FLUIDGRIDS_ASSISTANT_TOGGLE_EVENT as n, FLUIDGRIDS_PLUGIN_COMMANDS as r, FLUIDGRIDS_PLUGIN_ID as i, createFluidGridsPlugin as a, fluidGridsPlugin as o } from "./plugin.js";
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
export {
|
|
4
|
+
import { WORKFLOWS_ROUTE_PAGES as s, preloadWorkflowsRoute as c, scheduleWorkflowPagePreload as l, workflowsRoutePage as u } from "./routePreload.js";
|
|
5
|
+
import { config as d, resetWorkflowsConfig as f, setWorkflowsConfig as p } from "./config/index.js";
|
|
6
|
+
import { enTranslations as m } from "./translations/en.js";
|
|
7
|
+
export { n as FLUIDGRIDS_ASSISTANT_TOGGLE_EVENT, r as FLUIDGRIDS_PLUGIN_COMMANDS, i as FLUIDGRIDS_PLUGIN_ID, s as WORKFLOWS_ROUTE_PAGES, e as WorkflowsRoot, d as config, a as createFluidGridsPlugin, m as enTranslations, o as fluidGridsPlugin, c as preloadWorkflowsRoute, f as resetWorkflowsConfig, l as scheduleWorkflowPagePreload, p as setWorkflowsConfig, u as workflowsRoutePage, t as workflowsSwitchRedirectRules };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@burdenoff/microfe-workflows",
|
|
3
|
-
"version": "2026.
|
|
3
|
+
"version": "2026.1112.1",
|
|
4
4
|
"description": "Workflows microfrontend for Burdenoff products - thin shell over @burdenoff/fluidgrids-fe-sdk",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": {
|
|
@@ -15,6 +15,10 @@
|
|
|
15
15
|
"./plugin": {
|
|
16
16
|
"types": "./dist/plugin.d.ts",
|
|
17
17
|
"import": "./dist/plugin.js"
|
|
18
|
+
},
|
|
19
|
+
"./route-preload": {
|
|
20
|
+
"types": "./dist/routePreload.d.ts",
|
|
21
|
+
"import": "./dist/routePreload.js"
|
|
18
22
|
}
|
|
19
23
|
},
|
|
20
24
|
"scripts": {
|
|
@@ -51,7 +55,7 @@
|
|
|
51
55
|
"react-router": "^8.5.1"
|
|
52
56
|
},
|
|
53
57
|
"devDependencies": {
|
|
54
|
-
"@burdenoff/fluidgrids-fe-sdk": "2026.
|
|
58
|
+
"@burdenoff/fluidgrids-fe-sdk": "2026.1111.17",
|
|
55
59
|
"@burdenoff/toolchain": "2026.1107.14",
|
|
56
60
|
"@types/bun": "^1.4.4",
|
|
57
61
|
"@types/node": "^24.19.2",
|
|
@@ -71,7 +75,7 @@
|
|
|
71
75
|
"vite": "8.3.5"
|
|
72
76
|
},
|
|
73
77
|
"peerDependencies": {
|
|
74
|
-
"@burdenoff/fluidgrids-fe-sdk": "2026.
|
|
78
|
+
"@burdenoff/fluidgrids-fe-sdk": "2026.1111.17",
|
|
75
79
|
"framer-motion": "^12.0.0",
|
|
76
80
|
"react": "^19.0.0",
|
|
77
81
|
"react-dom": "^19.0.0"
|