@plumile/backoffice-react 0.1.115 → 0.1.117
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/lib/esm/auth/authRefreshNotice.css.js +1 -0
- package/lib/esm/components/backoffice/billing/BackofficeBillingUsageChart.js +60 -0
- package/lib/esm/components/backoffice/billing/BackofficeBillingUsageChart.js.map +1 -0
- package/lib/esm/components/backoffice/billing/backofficeBillingUsageChart.css.js +7 -0
- package/lib/esm/components/backoffice/billing/backofficeBillingUsageChart.css.js.map +1 -0
- package/lib/esm/components/backoffice/columns/buildDataTableColumns.js +6 -6
- package/lib/esm/components/backoffice/detail/BackofficeDetailFlagTag.css.js +0 -1
- package/lib/esm/components/backoffice/layout/buildSidebarSections.js +154 -135
- package/lib/esm/components/backoffice/layout/buildSidebarSections.js.map +1 -1
- package/lib/esm/components/backoffice/layout/sidebarUtils.js +24 -21
- package/lib/esm/components/backoffice/layout/sidebarUtils.js.map +1 -1
- package/lib/esm/components/backoffice/links/resolveBackofficeLink.js +62 -54
- package/lib/esm/components/backoffice/links/resolveBackofficeLink.js.map +1 -1
- package/lib/esm/components/backoffice/links/resolveBackofficeTargetIcon.js +1 -1
- package/lib/esm/components/backoffice/links/resolveBackofficeTargetIcon.js.map +1 -1
- package/lib/esm/components/backoffice/scaffolds/BackofficeEntityListScaffold.js +271 -263
- package/lib/esm/components/backoffice/scaffolds/BackofficeEntityListScaffold.js.map +1 -1
- package/lib/esm/components/backoffice/scaffolds/backofficeEntityListScaffold.css.js +2 -2
- package/lib/esm/components/backoffice/scaffolds/backofficeEntityListScaffold.css.js.map +1 -1
- package/lib/esm/components/backoffice/scaffolds/backofficeListScrollMode.js +6 -0
- package/lib/esm/components/backoffice/scaffolds/backofficeListScrollMode.js.map +1 -0
- package/lib/esm/index.js +75 -74
- package/lib/esm/pages/BackofficeDashboardPage.helpers.js +1 -0
- package/lib/esm/pages/BackofficeDashboardPage.helpers.js.map +1 -1
- package/lib/esm/pages/BackofficeDashboardPage.js +181 -154
- package/lib/esm/pages/BackofficeDashboardPage.js.map +1 -1
- package/lib/esm/pages/BackofficeEntityDetailPage.js +12 -12
- package/lib/esm/pages/BackofficeLayoutPage.js +134 -129
- package/lib/esm/pages/BackofficeLayoutPage.js.map +1 -1
- package/lib/esm/provider/BackofficeConfigContext.js.map +1 -1
- package/lib/esm/provider/BackofficeProvider.js +126 -121
- package/lib/esm/provider/BackofficeProvider.js.map +1 -1
- package/lib/esm/provider/dashboardRegistrations.js +17 -0
- package/lib/esm/provider/dashboardRegistrations.js.map +1 -0
- package/lib/esm/router/createBackofficeRoutes.js +148 -131
- package/lib/esm/router/createBackofficeRoutes.js.map +1 -1
- package/lib/types/components/backoffice/billing/BackofficeBillingUsageChart.d.ts +25 -0
- package/lib/types/components/backoffice/billing/BackofficeBillingUsageChart.d.ts.map +1 -0
- package/lib/types/components/backoffice/billing/BackofficeBillingUsageChart.stories.d.ts +41 -0
- package/lib/types/components/backoffice/billing/BackofficeBillingUsageChart.stories.d.ts.map +1 -0
- package/lib/types/components/backoffice/billing/backofficeBillingUsageChart.css.d.ts +4 -0
- package/lib/types/components/backoffice/billing/backofficeBillingUsageChart.css.d.ts.map +1 -0
- package/lib/types/components/backoffice/layout/buildSidebarSections.d.ts +2 -1
- package/lib/types/components/backoffice/layout/buildSidebarSections.d.ts.map +1 -1
- package/lib/types/components/backoffice/layout/sidebarUtils.d.ts +1 -0
- package/lib/types/components/backoffice/layout/sidebarUtils.d.ts.map +1 -1
- package/lib/types/components/backoffice/links/resolveBackofficeLink.d.ts.map +1 -1
- package/lib/types/components/backoffice/links/types.d.ts +1 -0
- package/lib/types/components/backoffice/links/types.d.ts.map +1 -1
- package/lib/types/components/backoffice/scaffolds/BackofficeEntityListScaffold.d.ts.map +1 -1
- package/lib/types/components/backoffice/scaffolds/backofficeEntityListScaffold.css.d.ts +1 -0
- package/lib/types/components/backoffice/scaffolds/backofficeEntityListScaffold.css.d.ts.map +1 -1
- package/lib/types/components/backoffice/scaffolds/backofficeListScrollMode.d.ts +2 -0
- package/lib/types/components/backoffice/scaffolds/backofficeListScrollMode.d.ts.map +1 -0
- package/lib/types/index.d.ts +2 -1
- package/lib/types/index.d.ts.map +1 -1
- package/lib/types/pages/BackofficeDashboardPage.d.ts +5 -1
- package/lib/types/pages/BackofficeDashboardPage.d.ts.map +1 -1
- package/lib/types/pages/BackofficeDashboardPage.helpers.d.ts.map +1 -1
- package/lib/types/pages/BackofficeDashboardPage.stories.d.ts +9 -0
- package/lib/types/pages/BackofficeDashboardPage.stories.d.ts.map +1 -0
- package/lib/types/pages/BackofficeLayoutPage.d.ts.map +1 -1
- package/lib/types/provider/BackofficeConfigContext.d.ts +2 -1
- package/lib/types/provider/BackofficeConfigContext.d.ts.map +1 -1
- package/lib/types/provider/BackofficeProvider.d.ts.map +1 -1
- package/lib/types/provider/dashboardRegistrations.d.ts +4 -0
- package/lib/types/provider/dashboardRegistrations.d.ts.map +1 -0
- package/lib/types/provider/types.d.ts +8 -1
- package/lib/types/provider/types.d.ts.map +1 -1
- package/lib/types/router/createBackofficeRoutes.d.ts +8 -2
- package/lib/types/router/createBackofficeRoutes.d.ts.map +1 -1
- package/package.json +13 -13
|
@@ -1,46 +1,47 @@
|
|
|
1
1
|
import { buildEntityGroupLookup as e, resolveSidebarGroups as t, resolveSidebarHubEntries as n } from "../components/backoffice/layout/sidebarUtils.js";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import s from "
|
|
6
|
-
import
|
|
7
|
-
import l from "@plumile/
|
|
8
|
-
import
|
|
9
|
-
import {
|
|
2
|
+
import { validateBackofficeDashboardRegistrations as r } from "../provider/dashboardRegistrations.js";
|
|
3
|
+
import { useContext as i, useEffect as a } from "react";
|
|
4
|
+
import { jsx as o } from "react/jsx-runtime";
|
|
5
|
+
import * as s from "react-relay";
|
|
6
|
+
import c from "@plumile/router/routing/RoutingContext.js";
|
|
7
|
+
import { BACKOFFICE_LIST_DEFAULTS as l } from "@plumile/backoffice-core/constants.js";
|
|
8
|
+
import u from "@plumile/router/errors/HttpRedirect.js";
|
|
9
|
+
import { getResourcePage as d } from "@plumile/router/ResourcePage.js";
|
|
10
|
+
import { r as f } from "@plumile/router/tools.js";
|
|
10
11
|
//#region src/router/createBackofficeRoutes.tsx
|
|
11
|
-
var { loadQuery:
|
|
12
|
-
let t =
|
|
13
|
-
return
|
|
12
|
+
var { loadQuery: p, usePreloadedQuery: m } = s, h = d("WrapperPage", async () => ({ default: (await import("@plumile/ui/pages/WrapperPage.js")).WrapperPage })), g = d("BackofficeLayoutPage", async () => import("../pages/BackofficeLayoutPage.js")), _ = d("BackofficeEntityListPage", async () => import("../pages/BackofficeEntityListPage.js")), v = d("BackofficeEntityDetailPage", async () => import("../pages/BackofficeEntityDetailPage.js")), y = d("BackofficeEntityDetailLayoutPage", async () => import("../pages/BackofficeEntityDetailLayoutPage.js")), b = d("BackofficeEntityDetailUnknownPageRedirect", async () => import("../pages/BackofficeEntityDetailUnknownPageRedirect.js")), x = d("BackofficeDashboardPage", async () => import("../pages/BackofficeDashboardPage.js")), S = d("BackofficeHubPage", async () => import("../pages/BackofficeHubPage.js")), C = d("BackofficeLoginPage", async () => import("../pages/BackofficeLoginPage.js")), w = d("BackofficePasswordResetRequestPage", async () => import("../pages/BackofficePasswordResetRequestPage.js")), T = d("BackofficePasswordResetCompletePage", async () => import("../pages/BackofficePasswordResetCompletePage.js")), E = d("BackofficeVerifyEmailPage", async () => import("../pages/BackofficeVerifyEmailPage.js")), D = d("BackofficeAcceptInvitationPage", async () => import("../pages/BackofficeAcceptInvitationPage.js")), O = ({ loginRedirectPath: e }) => {
|
|
13
|
+
let t = i(c);
|
|
14
|
+
return a(() => {
|
|
14
15
|
t?.history.set({ pathname: e });
|
|
15
16
|
}, [e, t]), null;
|
|
16
|
-
},
|
|
17
|
+
}, k = ({ children: e, Component: t, preparedLayout: n, permissionsQuery: r, activeGroupId: i }) => /* @__PURE__ */ o(t, {
|
|
17
18
|
permissionsQuery: r,
|
|
18
19
|
prepared: n?.permissionsQuery ?? null,
|
|
19
20
|
authStatus: null,
|
|
20
21
|
activeGroupId: i,
|
|
21
22
|
children: e
|
|
22
|
-
}),
|
|
23
|
-
let l =
|
|
24
|
-
return l?.isLoggedIn === !0 ? /* @__PURE__ */
|
|
23
|
+
}), A = ({ children: e, Component: t, preparedLayout: n, permissionsQuery: r, activeGroupId: i, authStatusQuery: a, authStatusPrepared: s, loginRedirectPath: c }) => {
|
|
24
|
+
let l = m(a, s);
|
|
25
|
+
return l?.isLoggedIn === !0 ? /* @__PURE__ */ o(t, {
|
|
25
26
|
permissionsQuery: r,
|
|
26
27
|
prepared: n?.permissionsQuery ?? null,
|
|
27
28
|
authStatus: l,
|
|
28
29
|
activeGroupId: i,
|
|
29
30
|
children: e
|
|
30
|
-
}) : /* @__PURE__ */
|
|
31
|
-
},
|
|
31
|
+
}) : /* @__PURE__ */ o(O, { loginRedirectPath: c });
|
|
32
|
+
}, j = (e) => {
|
|
32
33
|
let t = e.trim();
|
|
33
34
|
return t === "" || t === "/" ? "" : t.replace(/^\/+|\/+$/g, "");
|
|
34
|
-
},
|
|
35
|
+
}, M = (e) => {
|
|
35
36
|
let t = e.trim();
|
|
36
37
|
return t === "" ? "/" : `/${t}`.replace(/\/+/g, "/");
|
|
37
|
-
},
|
|
38
|
+
}, N = (e, t) => {
|
|
38
39
|
let n = t.replace(/^\/+|\/+$/g, "");
|
|
39
40
|
return e === "" ? n : n === "" ? e : `${e}/${n}`;
|
|
40
|
-
},
|
|
41
|
-
let n =
|
|
41
|
+
}, P = (e, t) => M(N(e, t)), F = (e, t) => {
|
|
42
|
+
let n = M(e), r = t === "" ? "" : `/${t}`;
|
|
42
43
|
return r !== "" && n.startsWith(r) ? n.slice(r.length).replace(/^\/+/, "") : n.replace(/^\/+/, "");
|
|
43
|
-
},
|
|
44
|
+
}, I = (e, t) => {
|
|
44
45
|
if (e?.routes == null) return null;
|
|
45
46
|
for (let n = e.routes.length - 1; n >= 0; --n) {
|
|
46
47
|
let r = e.routes[n];
|
|
@@ -50,7 +51,7 @@ var { loadQuery: f, usePreloadedQuery: p } = o, m = u("WrapperPage", async () =>
|
|
|
50
51
|
}
|
|
51
52
|
}
|
|
52
53
|
return null;
|
|
53
|
-
},
|
|
54
|
+
}, L = (e) => {
|
|
54
55
|
let t = new URLSearchParams();
|
|
55
56
|
return Object.entries(e).forEach(([e, n]) => {
|
|
56
57
|
if (n != null) {
|
|
@@ -63,55 +64,69 @@ var { loadQuery: f, usePreloadedQuery: p } = o, m = u("WrapperPage", async () =>
|
|
|
63
64
|
t.set(e, String(n));
|
|
64
65
|
}
|
|
65
66
|
}), t;
|
|
66
|
-
},
|
|
67
|
-
function
|
|
68
|
-
let { basePath:
|
|
69
|
-
|
|
70
|
-
|
|
67
|
+
}, R = f;
|
|
68
|
+
function z(i) {
|
|
69
|
+
let { basePath: a, entityManifest: s, entityRegistry: c, sidebar: d, auth: f, dashboard: m } = i, O = r(i.dashboards), M = j(a), z = N(M, "login"), B = N(M, "login/reset"), ee = N(M, "login/reset/complete"), V = N(M, "verify-email"), H = N(M, "accept-invitation"), U = P(M, "login"), W = t(s, d), te = n(W, d), ne = e(W, d), G = /* @__PURE__ */ new Map();
|
|
70
|
+
ne.forEach((e, t) => {
|
|
71
|
+
G.set(t, e.groupId);
|
|
71
72
|
});
|
|
72
|
-
let
|
|
73
|
-
let t = await
|
|
73
|
+
let K = /* @__PURE__ */ new WeakMap(), q = /* @__PURE__ */ new WeakMap(), J = d?.permissionsQuery, Y = async ({ context: e }) => {
|
|
74
|
+
let t = await f.session.load();
|
|
74
75
|
return {
|
|
75
|
-
permissionsQuery:
|
|
76
|
-
authStatusQuery: t.authStatusQuery == null ? null :
|
|
76
|
+
permissionsQuery: J == null ? null : p(e.relayEnvironment, J, {}),
|
|
77
|
+
authStatusQuery: t.authStatusQuery == null ? null : p(e.relayEnvironment, t.authStatusQuery, {}, { fetchPolicy: "network-only" })
|
|
77
78
|
};
|
|
78
|
-
},
|
|
79
|
+
}, X = async () => m == null ? null : {
|
|
80
|
+
dashboardId: "dashboard",
|
|
81
|
+
config: await m.load()
|
|
82
|
+
}, Z = ({ prepared: e, Component: t }) => t == null ? null : /* @__PURE__ */ o(t, { prepared: e }), re = R({
|
|
79
83
|
path: "",
|
|
80
|
-
resourcePage:
|
|
81
|
-
prepare:
|
|
82
|
-
render:
|
|
83
|
-
}),
|
|
84
|
+
resourcePage: x,
|
|
85
|
+
prepare: X,
|
|
86
|
+
render: Z
|
|
87
|
+
}), ie = R({
|
|
84
88
|
path: "dashboard",
|
|
85
|
-
resourcePage:
|
|
86
|
-
prepare:
|
|
87
|
-
render:
|
|
88
|
-
}),
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
89
|
+
resourcePage: x,
|
|
90
|
+
prepare: X,
|
|
91
|
+
render: Z
|
|
92
|
+
}), Q = O.map((e) => R({
|
|
93
|
+
path: `dashboard/${e.id}`,
|
|
94
|
+
resourcePage: x,
|
|
95
|
+
prepare: async () => {
|
|
96
|
+
let t = await e.module.load();
|
|
97
|
+
return {
|
|
98
|
+
dashboardId: e.id,
|
|
99
|
+
config: t
|
|
100
|
+
};
|
|
101
|
+
},
|
|
102
|
+
render: Z
|
|
103
|
+
})), ae = Object.values(s).filter((e) => e.kind === "list-detail"), oe = te.map((e) => {
|
|
104
|
+
let t = R({
|
|
105
|
+
path: F(e.hub.href, M),
|
|
106
|
+
resourcePage: S,
|
|
92
107
|
prepare: () => ({
|
|
93
108
|
hubId: e.hub.id,
|
|
94
109
|
hub: e.hub
|
|
95
110
|
}),
|
|
96
|
-
render: ({ prepared: e, Component: t }) => t == null ? null : /* @__PURE__ */
|
|
111
|
+
render: ({ prepared: e, Component: t }) => t == null ? null : /* @__PURE__ */ o(t, { prepared: e })
|
|
97
112
|
});
|
|
98
|
-
return e.groupId != null &&
|
|
99
|
-
}),
|
|
100
|
-
let t = e.routes.list, n =
|
|
113
|
+
return e.groupId != null && q.set(t, e.groupId), t;
|
|
114
|
+
}), se = ae.map((e) => {
|
|
115
|
+
let t = e.routes.list, n = F(t, M), r = [];
|
|
101
116
|
if (e.hasList) {
|
|
102
|
-
let t =
|
|
117
|
+
let t = R({
|
|
103
118
|
path: "",
|
|
104
|
-
resourcePage:
|
|
119
|
+
resourcePage: _,
|
|
105
120
|
prepareSearchBehavior: "path",
|
|
106
121
|
prepare: async ({ context: t, query: n }) => {
|
|
107
|
-
let { config: r } = await
|
|
122
|
+
let { config: r } = await c.loadListEntity(e.id), { list: i, listUrlCodec: a, listDefaults: o } = r;
|
|
108
123
|
if (a == null || o == null) throw Error(`Backoffice entity ${e.id} does not expose a list configuration.`);
|
|
109
|
-
let
|
|
124
|
+
let s = L(n), u = a.parse(s), { pageSize: d } = l, f = {
|
|
110
125
|
where: u.where,
|
|
111
126
|
sort: u.sort ?? o.sort,
|
|
112
127
|
count: d,
|
|
113
128
|
cursor: null
|
|
114
|
-
}, m = i.buildQueryVariables(
|
|
129
|
+
}, m = i.buildQueryVariables(f), h = p(t.relayEnvironment, i.query, m);
|
|
115
130
|
return {
|
|
116
131
|
entityId: e.id,
|
|
117
132
|
entityManifest: e,
|
|
@@ -122,20 +137,20 @@ function R(r) {
|
|
|
122
137
|
render: ({ prepared: e, Component: t }) => {
|
|
123
138
|
if (t == null) return null;
|
|
124
139
|
let n = e;
|
|
125
|
-
return /* @__PURE__ */
|
|
140
|
+
return /* @__PURE__ */ o(t, {
|
|
126
141
|
entityManifest: n.entityManifest,
|
|
127
142
|
config: n.entityConfig,
|
|
128
143
|
prepared: n
|
|
129
144
|
});
|
|
130
145
|
}
|
|
131
146
|
});
|
|
132
|
-
|
|
147
|
+
K.set(t, e.id), r.push(t);
|
|
133
148
|
}
|
|
134
|
-
let i =
|
|
149
|
+
let i = R({
|
|
135
150
|
path: ":id",
|
|
136
|
-
resourcePage:
|
|
151
|
+
resourcePage: y,
|
|
137
152
|
prepare: async ({ context: t, variables: n }) => {
|
|
138
|
-
let { config: r } = await
|
|
153
|
+
let { config: r } = await c.loadDetailLayoutEntity(e.id), i = String(n.id ?? ""), a = r.layoutPage.buildVariables == null ? { variables: { id: i } } : r.layoutPage.buildVariables({ id: i }), o = p(t.relayEnvironment, r.layoutPage.query, a.variables);
|
|
139
154
|
return {
|
|
140
155
|
entityId: e.id,
|
|
141
156
|
entityManifest: e,
|
|
@@ -147,7 +162,7 @@ function R(r) {
|
|
|
147
162
|
render: ({ children: e, prepared: t, Component: n }) => {
|
|
148
163
|
if (n == null) return null;
|
|
149
164
|
let r = t;
|
|
150
|
-
return /* @__PURE__ */
|
|
165
|
+
return /* @__PURE__ */ o(n, {
|
|
151
166
|
entityManifest: r.entityManifest,
|
|
152
167
|
config: r.entityConfig,
|
|
153
168
|
prepared: r,
|
|
@@ -155,9 +170,9 @@ function R(r) {
|
|
|
155
170
|
});
|
|
156
171
|
},
|
|
157
172
|
children: [
|
|
158
|
-
|
|
173
|
+
R({
|
|
159
174
|
path: "",
|
|
160
|
-
resourcePage:
|
|
175
|
+
resourcePage: h,
|
|
161
176
|
prepare: ({ variables: t }) => {
|
|
162
177
|
let n = String(t.id ?? "").trim();
|
|
163
178
|
return { redirectTo: n === "" ? null : e.routes.detailPage(n, e.defaultDetailPageId ?? "overview") };
|
|
@@ -165,14 +180,14 @@ function R(r) {
|
|
|
165
180
|
render: ({ prepared: e }) => {
|
|
166
181
|
let t = e.redirectTo ?? null;
|
|
167
182
|
if (t == null) return null;
|
|
168
|
-
throw new
|
|
183
|
+
throw new u(t);
|
|
169
184
|
}
|
|
170
185
|
}),
|
|
171
|
-
...(e.detailPages ?? []).map((t) =>
|
|
186
|
+
...(e.detailPages ?? []).map((t) => R({
|
|
172
187
|
path: t.pathSegment,
|
|
173
|
-
resourcePage:
|
|
188
|
+
resourcePage: v,
|
|
174
189
|
prepare: async ({ context: n, variables: r }) => {
|
|
175
|
-
let i = String(r.id ?? ""), a = await
|
|
190
|
+
let i = String(r.id ?? ""), a = await c.loadDetailPageEntity(e.id, t.id), o = a.config.page.buildVariables == null ? { variables: { id: i } } : a.config.page.buildVariables({ id: i }), s = p(n.relayEnvironment, a.config.page.query, o.variables);
|
|
176
191
|
return {
|
|
177
192
|
entityId: e.id,
|
|
178
193
|
entityManifest: e,
|
|
@@ -180,7 +195,7 @@ function R(r) {
|
|
|
180
195
|
detailId: o.detailId,
|
|
181
196
|
id: i,
|
|
182
197
|
pageConfig: a.config,
|
|
183
|
-
pageQuery:
|
|
198
|
+
pageQuery: s,
|
|
184
199
|
pageId: t.id,
|
|
185
200
|
pagePath: t.pathSegment
|
|
186
201
|
};
|
|
@@ -188,18 +203,18 @@ function R(r) {
|
|
|
188
203
|
render: ({ prepared: e, Component: t }) => {
|
|
189
204
|
if (t == null) return null;
|
|
190
205
|
let n = e;
|
|
191
|
-
return /* @__PURE__ */
|
|
206
|
+
return /* @__PURE__ */ o(t, {
|
|
192
207
|
entityManifest: n.entityManifest,
|
|
193
208
|
config: n.entityConfig,
|
|
194
209
|
prepared: n
|
|
195
210
|
});
|
|
196
211
|
}
|
|
197
212
|
})),
|
|
198
|
-
|
|
213
|
+
R({
|
|
199
214
|
path: ":pagePath",
|
|
200
|
-
resourcePage:
|
|
215
|
+
resourcePage: b,
|
|
201
216
|
prepare: async ({ variables: t }) => {
|
|
202
|
-
let n = await
|
|
217
|
+
let n = await c.loadDetailLayoutEntity(e.id), r = String(t.id ?? ""), i = String(t.pagePath ?? "");
|
|
203
218
|
return {
|
|
204
219
|
entityManifest: e,
|
|
205
220
|
entityConfig: n.config,
|
|
@@ -210,7 +225,7 @@ function R(r) {
|
|
|
210
225
|
render: ({ prepared: e, Component: t }) => {
|
|
211
226
|
if (t == null) return null;
|
|
212
227
|
let n = e;
|
|
213
|
-
return /* @__PURE__ */
|
|
228
|
+
return /* @__PURE__ */ o(t, {
|
|
214
229
|
entityManifest: n.entityManifest,
|
|
215
230
|
config: n.entityConfig,
|
|
216
231
|
prepared: n
|
|
@@ -219,17 +234,17 @@ function R(r) {
|
|
|
219
234
|
})
|
|
220
235
|
]
|
|
221
236
|
});
|
|
222
|
-
return
|
|
237
|
+
return K.set(i, e.id), r.push(i), R({
|
|
223
238
|
path: n,
|
|
224
239
|
children: r,
|
|
225
|
-
resourcePage:
|
|
240
|
+
resourcePage: h
|
|
226
241
|
});
|
|
227
|
-
}),
|
|
228
|
-
let t =
|
|
229
|
-
path:
|
|
230
|
-
resourcePage:
|
|
242
|
+
}), ce = Object.values(s).filter((e) => e.kind === "tool").map((e) => {
|
|
243
|
+
let t = R({
|
|
244
|
+
path: F(e.routes.list, M),
|
|
245
|
+
resourcePage: i.toolsOperationPage ?? null,
|
|
231
246
|
prepare: async () => {
|
|
232
|
-
let t = await
|
|
247
|
+
let t = await c.loadToolEntity(e.id);
|
|
233
248
|
return {
|
|
234
249
|
entityId: e.id,
|
|
235
250
|
entityManifest: e,
|
|
@@ -239,93 +254,95 @@ function R(r) {
|
|
|
239
254
|
render: ({ prepared: e, Component: t }) => {
|
|
240
255
|
if (t == null) return null;
|
|
241
256
|
let n = e;
|
|
242
|
-
return /* @__PURE__ */
|
|
257
|
+
return /* @__PURE__ */ o(t, {
|
|
243
258
|
entityManifest: n.entityManifest,
|
|
244
259
|
operation: n.entityConfig.tool.operation,
|
|
245
260
|
toolId: n.entityConfig.id
|
|
246
261
|
});
|
|
247
262
|
}
|
|
248
263
|
});
|
|
249
|
-
return
|
|
250
|
-
}),
|
|
251
|
-
path:
|
|
252
|
-
resourcePage:
|
|
264
|
+
return K.set(t, e.id), t;
|
|
265
|
+
}), le = R({
|
|
266
|
+
path: M,
|
|
267
|
+
resourcePage: g,
|
|
253
268
|
prepareSearchBehavior: "path",
|
|
254
|
-
prepare:
|
|
269
|
+
prepare: Y,
|
|
255
270
|
render: ({ children: e, prepared: t, route: n, Component: r }) => {
|
|
256
271
|
if (r == null) return null;
|
|
257
|
-
let i = t,
|
|
258
|
-
return l != null && i?.authStatusQuery != null ? /* @__PURE__ */
|
|
272
|
+
let i = t, a = I(n, K), s = a == null ? I(n, q) : G.get(a) ?? null, c = r, l = f.session.get()?.authStatusQuery ?? null;
|
|
273
|
+
return l != null && i?.authStatusQuery != null ? /* @__PURE__ */ o(A, {
|
|
259
274
|
Component: c,
|
|
260
275
|
preparedLayout: i,
|
|
261
|
-
permissionsQuery:
|
|
276
|
+
permissionsQuery: d?.permissionsQuery,
|
|
262
277
|
activeGroupId: s,
|
|
263
278
|
authStatusQuery: l,
|
|
264
279
|
authStatusPrepared: i.authStatusQuery,
|
|
265
|
-
loginRedirectPath:
|
|
280
|
+
loginRedirectPath: U,
|
|
266
281
|
children: e
|
|
267
|
-
}) : /* @__PURE__ */
|
|
282
|
+
}) : /* @__PURE__ */ o(k, {
|
|
268
283
|
Component: c,
|
|
269
284
|
preparedLayout: i,
|
|
270
|
-
permissionsQuery:
|
|
285
|
+
permissionsQuery: d?.permissionsQuery,
|
|
271
286
|
activeGroupId: s,
|
|
272
287
|
children: e
|
|
273
288
|
});
|
|
274
289
|
},
|
|
275
290
|
children: [
|
|
276
|
-
|
|
277
|
-
...
|
|
278
|
-
...
|
|
279
|
-
...
|
|
280
|
-
Q
|
|
291
|
+
re,
|
|
292
|
+
...oe,
|
|
293
|
+
...se,
|
|
294
|
+
...ce,
|
|
295
|
+
...Q,
|
|
296
|
+
ie
|
|
281
297
|
]
|
|
282
298
|
}), $ = [
|
|
283
|
-
|
|
284
|
-
path:
|
|
285
|
-
resourcePage:
|
|
299
|
+
R({
|
|
300
|
+
path: z,
|
|
301
|
+
resourcePage: C,
|
|
286
302
|
prepare: async ({ context: e }) => {
|
|
287
|
-
let t = await
|
|
288
|
-
return { query:
|
|
303
|
+
let t = await f.login.load();
|
|
304
|
+
return { query: p(e.relayEnvironment, t.loginQuery, {}) };
|
|
289
305
|
},
|
|
290
|
-
render: ({ prepared: e, Component: t }) => t == null ? null : /* @__PURE__ */
|
|
291
|
-
}),
|
|
292
|
-
L({
|
|
293
|
-
path: R,
|
|
294
|
-
resourcePage: C,
|
|
295
|
-
prepare: async () => (await d.passwordResetRequest.load(), null),
|
|
296
|
-
render: ({ Component: e }) => e == null ? null : /* @__PURE__ */ a(e, {})
|
|
306
|
+
render: ({ prepared: e, Component: t }) => t == null ? null : /* @__PURE__ */ o(t, { prepared: e })
|
|
297
307
|
}),
|
|
298
|
-
|
|
299
|
-
path:
|
|
308
|
+
R({
|
|
309
|
+
path: B,
|
|
300
310
|
resourcePage: w,
|
|
301
|
-
prepare: async () => (await
|
|
302
|
-
render: ({ Component: e }) => e == null ? null : /* @__PURE__ */
|
|
311
|
+
prepare: async () => (await f.passwordResetRequest.load(), null),
|
|
312
|
+
render: ({ Component: e }) => e == null ? null : /* @__PURE__ */ o(e, {})
|
|
303
313
|
}),
|
|
304
|
-
|
|
305
|
-
path:
|
|
314
|
+
R({
|
|
315
|
+
path: ee,
|
|
306
316
|
resourcePage: T,
|
|
307
|
-
prepare: async () => (await
|
|
308
|
-
render: ({ Component: e }) => e == null ? null : /* @__PURE__ */
|
|
317
|
+
prepare: async () => (await f.passwordResetComplete.load(), null),
|
|
318
|
+
render: ({ Component: e }) => e == null ? null : /* @__PURE__ */ o(e, {})
|
|
319
|
+
}),
|
|
320
|
+
R({
|
|
321
|
+
path: V,
|
|
322
|
+
resourcePage: E,
|
|
323
|
+
prepare: async () => (await f.verifyEmail.load(), null),
|
|
324
|
+
render: ({ Component: e }) => e == null ? null : /* @__PURE__ */ o(e, {})
|
|
309
325
|
})
|
|
310
326
|
];
|
|
311
|
-
return (
|
|
312
|
-
path:
|
|
313
|
-
resourcePage:
|
|
314
|
-
prepare: async () => (await
|
|
315
|
-
render: ({ Component: e }) => e == null ? null : /* @__PURE__ */
|
|
316
|
-
})), $.push(
|
|
327
|
+
return (f.hasAcceptInvitation === !0 || f.acceptInvitation != null) && $.push(R({
|
|
328
|
+
path: H,
|
|
329
|
+
resourcePage: D,
|
|
330
|
+
prepare: async () => (await f.acceptInvitation?.load(), null),
|
|
331
|
+
render: ({ Component: e }) => e == null ? null : /* @__PURE__ */ o(e, {})
|
|
332
|
+
})), $.push(le), $;
|
|
317
333
|
}
|
|
318
|
-
var
|
|
319
|
-
normalizeBaseSegment:
|
|
320
|
-
normalizePath:
|
|
321
|
-
buildScopedPath:
|
|
322
|
-
buildScopedAbsolutePath:
|
|
323
|
-
buildRelativePath:
|
|
324
|
-
resolveActiveEntityIdFromRoute:
|
|
325
|
-
toSearchParams:
|
|
326
|
-
|
|
334
|
+
var B = {
|
|
335
|
+
normalizeBaseSegment: j,
|
|
336
|
+
normalizePath: M,
|
|
337
|
+
buildScopedPath: N,
|
|
338
|
+
buildScopedAbsolutePath: P,
|
|
339
|
+
buildRelativePath: F,
|
|
340
|
+
resolveActiveEntityIdFromRoute: I,
|
|
341
|
+
toSearchParams: L,
|
|
342
|
+
validateBackofficeDashboardRegistrations: r,
|
|
343
|
+
BackofficeLayoutRouteWithAuthStatus: A
|
|
327
344
|
};
|
|
328
345
|
//#endregion
|
|
329
|
-
export {
|
|
346
|
+
export { D as BackofficeAcceptInvitationPageResource, x as BackofficeDashboardPageResource, y as BackofficeEntityDetailLayoutPageResource, v as BackofficeEntityDetailPageResource, b as BackofficeEntityDetailUnknownPageRedirectResource, _ as BackofficeEntityListPageResource, S as BackofficeHubPageResource, g as BackofficeLayoutPageResource, C as BackofficeLoginPageResource, T as BackofficePasswordResetCompletePageResource, w as BackofficePasswordResetRequestPageResource, E as BackofficeVerifyEmailPageResource, h as WrapperPageResource, B as __test, z as createBackofficeRoutes, z as default };
|
|
330
347
|
|
|
331
348
|
//# sourceMappingURL=createBackofficeRoutes.js.map
|