zudoku 0.31.2 → 0.32.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli/common/utils/ports.d.ts +1 -1
- package/dist/cli/common/utils/ports.js +16 -15
- package/dist/cli/common/utils/ports.js.map +1 -1
- package/dist/cli/dev/handler.js +9 -12
- package/dist/cli/dev/handler.js.map +1 -1
- package/dist/config/validators/common.d.ts +90 -0
- package/dist/config/validators/common.js +8 -0
- package/dist/config/validators/common.js.map +1 -1
- package/dist/config/validators/validate.d.ts +38 -0
- package/dist/lib/MissingIcon.d.ts +2 -0
- package/dist/lib/MissingIcon.js +7 -0
- package/dist/lib/MissingIcon.js.map +1 -0
- package/dist/lib/core/ZudokuContext.d.ts +1 -1
- package/dist/lib/core/plugins.d.ts +2 -0
- package/dist/lib/core/plugins.js +2 -0
- package/dist/lib/core/plugins.js.map +1 -1
- package/dist/lib/icons.d.ts +1 -0
- package/dist/lib/icons.js +1 -0
- package/dist/lib/icons.js.map +1 -1
- package/dist/lib/oas/graphql/index.js +3 -2
- package/dist/lib/oas/graphql/index.js.map +1 -1
- package/dist/lib/plugins/api-keys/index.d.ts +1 -0
- package/dist/lib/plugins/api-keys/index.js +1 -0
- package/dist/lib/plugins/api-keys/index.js.map +1 -1
- package/dist/lib/plugins/openapi/{OpenApiRoute.d.ts → OasProvider.d.ts} +1 -2
- package/dist/lib/plugins/openapi/OasProvider.js +29 -0
- package/dist/lib/plugins/openapi/OasProvider.js.map +1 -0
- package/dist/lib/plugins/openapi/PlaygroundDialogWrapper.d.ts +1 -1
- package/dist/lib/plugins/openapi/Sidecar.js +1 -1
- package/dist/lib/plugins/openapi/Sidecar.js.map +1 -1
- package/dist/lib/plugins/openapi/index.d.ts +8 -0
- package/dist/lib/plugins/openapi/index.js +46 -113
- package/dist/lib/plugins/openapi/index.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/Playground.d.ts +1 -1
- package/dist/lib/plugins/openapi/playground/Playground.js +5 -5
- package/dist/lib/plugins/openapi/playground/Playground.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/result-panel/RequestTab.js +1 -1
- package/dist/lib/plugins/openapi/playground/result-panel/RequestTab.js.map +1 -1
- package/dist/lib/plugins/openapi/util/createSidebarCategory.d.ts +9 -0
- package/dist/lib/plugins/openapi/util/createSidebarCategory.js +25 -0
- package/dist/lib/plugins/openapi/util/createSidebarCategory.js.map +1 -0
- package/dist/lib/plugins/openapi/util/getRoutes.d.ts +10 -0
- package/dist/lib/plugins/openapi/util/getRoutes.js +74 -0
- package/dist/lib/plugins/openapi/util/getRoutes.js.map +1 -0
- package/dist/lib/plugins/openapi/util/methodColorMap.d.ts +2 -0
- package/dist/lib/plugins/openapi/util/methodColorMap.js +10 -0
- package/dist/lib/plugins/openapi/util/methodColorMap.js.map +1 -0
- package/dist/vite/build.js +20 -14
- package/dist/vite/build.js.map +1 -1
- package/dist/vite/config.js +2 -6
- package/dist/vite/config.js.map +1 -1
- package/dist/vite/dev-server.d.ts +4 -2
- package/dist/vite/dev-server.js +30 -8
- package/dist/vite/dev-server.js.map +1 -1
- package/dist/vite/error-handler.d.ts +1 -1
- package/dist/vite/error-handler.js +1 -1
- package/dist/vite/error-handler.js.map +1 -1
- package/dist/vite/output.d.ts +14 -2
- package/dist/vite/output.js +12 -14
- package/dist/vite/output.js.map +1 -1
- package/dist/vite/plugin-api-keys.js +2 -2
- package/dist/vite/plugin-api-keys.js.map +1 -1
- package/dist/vite/plugin-sidebar.js +17 -2
- package/dist/vite/plugin-sidebar.js.map +1 -1
- package/dist/vite/prerender/FileWritingResponse.d.ts +7 -3
- package/dist/vite/prerender/FileWritingResponse.js +15 -9
- package/dist/vite/prerender/FileWritingResponse.js.map +1 -1
- package/dist/vite/prerender/prerender.d.ts +10 -2
- package/dist/vite/prerender/prerender.js +5 -4
- package/dist/vite/prerender/prerender.js.map +1 -1
- package/dist/vite/prerender/worker.d.ts +3 -1
- package/dist/vite/prerender/worker.js +11 -4
- package/dist/vite/prerender/worker.js.map +1 -1
- package/lib/{AuthenticationPlugin-DjnQ5hs7.js → AuthenticationPlugin-_YVa673u.js} +2 -2
- package/lib/{AuthenticationPlugin-DjnQ5hs7.js.map → AuthenticationPlugin-_YVa673u.js.map} +1 -1
- package/lib/{MdxPage-ZX2oquWw.js → MdxPage-GM1T5jmO.js} +3 -3
- package/lib/{MdxPage-ZX2oquWw.js.map → MdxPage-GM1T5jmO.js.map} +1 -1
- package/lib/OasProvider-IS9wBrb7.js +34 -0
- package/lib/OasProvider-IS9wBrb7.js.map +1 -0
- package/lib/{OperationList-c72qPMtm.js → OperationList-BTmRbbXk.js} +4 -5
- package/lib/{OperationList-c72qPMtm.js.map → OperationList-BTmRbbXk.js.map} +1 -1
- package/lib/{Select-NSz0gku6.js → Select-D9CKL33X.js} +3 -3
- package/lib/{Select-NSz0gku6.js.map → Select-D9CKL33X.js.map} +1 -1
- package/lib/{createServer-ZDNGmPfQ.js → createServer-DSQiPwjN.js} +2 -5
- package/lib/{createServer-ZDNGmPfQ.js.map → createServer-DSQiPwjN.js.map} +1 -1
- package/lib/{hook-Dnj3SwPC.js → hook-C_t2ISLC.js} +22 -22
- package/lib/{hook-Dnj3SwPC.js.map → hook-C_t2ISLC.js.map} +1 -1
- package/lib/{index-CZjcfK-H.js → index-BANyVRgL.js} +806 -771
- package/lib/index-BANyVRgL.js.map +1 -0
- package/lib/{mutation-ByGtmi0-.js → mutation-Cm3O9f3X.js} +2 -2
- package/lib/{mutation-ByGtmi0-.js.map → mutation-Cm3O9f3X.js.map} +1 -1
- package/lib/{useScrollToAnchor-DkVfWsxe.js → useScrollToAnchor-BGEcH3HM.js} +2 -2
- package/lib/{useScrollToAnchor-DkVfWsxe.js.map → useScrollToAnchor-BGEcH3HM.js.map} +1 -1
- package/lib/zudoku.auth-auth0.js +1 -1
- package/lib/zudoku.auth-clerk.js +2 -2
- package/lib/zudoku.auth-openid.js +2 -2
- package/lib/zudoku.components.js +141 -140
- package/lib/zudoku.components.js.map +1 -1
- package/lib/zudoku.icons.js +10 -0
- package/lib/zudoku.icons.js.map +1 -1
- package/lib/zudoku.plugin-api-catalog.js +1 -1
- package/lib/zudoku.plugin-api-keys.js +10 -9
- package/lib/zudoku.plugin-api-keys.js.map +1 -1
- package/lib/zudoku.plugin-markdown.js +1 -1
- package/lib/zudoku.plugin-openapi.js +4 -3
- package/lib/zudoku.plugins.js +13 -0
- package/lib/zudoku.plugins.js.map +1 -0
- package/package.json +5 -1
- package/src/lib/MissingIcon.tsx +22 -0
- package/src/lib/core/ZudokuContext.ts +1 -1
- package/src/lib/core/plugins.ts +8 -0
- package/src/lib/icons.ts +1 -0
- package/src/lib/oas/graphql/index.ts +3 -2
- package/src/lib/plugins/api-keys/index.tsx +3 -0
- package/src/lib/plugins/openapi/OasProvider.tsx +51 -0
- package/src/lib/plugins/openapi/PlaygroundDialogWrapper.tsx +1 -1
- package/src/lib/plugins/openapi/Sidecar.tsx +0 -1
- package/src/lib/plugins/openapi/index.tsx +80 -143
- package/src/lib/plugins/openapi/playground/Playground.tsx +26 -24
- package/src/lib/plugins/openapi/playground/result-panel/RequestTab.tsx +1 -1
- package/src/lib/plugins/openapi/util/createSidebarCategory.tsx +39 -0
- package/src/lib/plugins/openapi/util/getRoutes.tsx +123 -0
- package/src/lib/plugins/openapi/util/methodColorMap.tsx +11 -0
- package/dist/lib/plugins/openapi/OpenApiRoute.js +0 -25
- package/dist/lib/plugins/openapi/OpenApiRoute.js.map +0 -1
- package/lib/OpenApiRoute-BP9kzG5k.js +0 -36
- package/lib/OpenApiRoute-BP9kzG5k.js.map +0 -1
- package/lib/index-CZjcfK-H.js.map +0 -1
- package/src/lib/plugins/openapi/OpenApiRoute.tsx +0 -51
package/lib/zudoku.components.js
CHANGED
|
@@ -15,37 +15,38 @@ var G = (t, e, r, n) => ({
|
|
|
15
15
|
});
|
|
16
16
|
import { a as Re, H as oe } from "./index.esm-9-TF9KQB.js";
|
|
17
17
|
import { u as le, m as ut, O as ce, R as dt, S as ht, h as ue, f as ft, L as de } from "./chunk-SYFQ2XB5-QijJrSf0.js";
|
|
18
|
-
import { S as Fe,
|
|
18
|
+
import { S as Fe, m as Be, Q as gt, n as w, o as ve, p as be, q as M, r as mt, t as pt, v as xt, w as yt, x as je, y as we, z as vt, h as Pe, A as ke, B as bt, e as jt, k as z, i as A, C as He, D as ze, E as wt, j as ne, a as Pt, Z as kt, F as Ct, G as St } from "./hook-C_t2ISLC.js";
|
|
19
19
|
import { j as s } from "./jsx-runtime-Bdg6XQ1m.js";
|
|
20
20
|
import * as U from "react";
|
|
21
|
-
import Nt, { useRef as ee, useEffect as
|
|
21
|
+
import Nt, { useRef as ee, useEffect as I, createContext as he, StrictMode as Le, useState as L, useCallback as Dt, Suspense as fe, memo as Ke, forwardRef as Mt, Component as Ot, createElement as Ce, useMemo as te, useContext as At, Fragment as Et } from "react";
|
|
22
22
|
import { Z as $e } from "./invariant-Caa8-XvF.js";
|
|
23
|
-
import { E as Ue, S as D, a as qt, R as
|
|
24
|
-
import { Button as
|
|
23
|
+
import { E as Ue, S as D, a as qt, R as Tt } from "./SlotletProvider-D0mFmGJu.js";
|
|
24
|
+
import { Button as It } from "./ui/Button.js";
|
|
25
25
|
import { Callout as Qt } from "./ui/Callout.js";
|
|
26
|
-
import { M as Rt } from "./mutation-
|
|
26
|
+
import { M as Rt } from "./mutation-Cm3O9f3X.js";
|
|
27
27
|
import * as Ft from "react-dom";
|
|
28
28
|
import { C as ge } from "./ClientOnly-E7hGysn1.js";
|
|
29
|
-
import { CircleXIcon as
|
|
29
|
+
import { CircleXIcon as Bt, SearchIcon as Ht, SunIcon as zt, MoonIcon as Lt, MenuIcon as Kt, PanelLeftIcon as $t } from "lucide-react";
|
|
30
30
|
import { Drawer as Ze, DrawerTrigger as Ye, DrawerContent as Ve, DrawerTitle as Xe } from "./ui/Drawer.js";
|
|
31
31
|
import { c as Q } from "./cn-qaFjX9_3.js";
|
|
32
|
-
import { s as Ut, S as
|
|
32
|
+
import { s as Ut, S as Se, a as Zt, M as Yt, u as Vt } from "./useScrollToAnchor-BGEcH3HM.js";
|
|
33
33
|
import { u as Xt, P as Gt, H as _t, a as Wt, V as Jt, M as er } from "./Markdown-8mv9nhGd.js";
|
|
34
34
|
import { B as ae, S as Ge } from "./Spinner-BlzrEEk1.js";
|
|
35
|
-
import {
|
|
35
|
+
import { isSearchPlugin as tr, isProfileMenuPlugin as rr, isNavigationPlugin as sr, needsInitialization as nr, isApiIdentityPlugin as ar, isMdxProviderPlugin as ir, hasHead as or } from "./zudoku.plugins.js";
|
|
36
|
+
import { DropdownMenu as lr, DropdownMenuTrigger as cr, DropdownMenuContent as ur, DropdownMenuLabel as dr, DropdownMenuSeparator as re, DropdownMenuSub as hr, DropdownMenuSubTrigger as fr, DropdownMenuPortal as gr, DropdownMenuSubContent as mr, DropdownMenuItem as pr } from "./ui/DropdownMenu.js";
|
|
36
37
|
import { j as Ne } from "./joinUrl-nLx9pD-Z.js";
|
|
37
38
|
import { VisuallyHidden as _e } from "@radix-ui/react-visually-hidden";
|
|
38
|
-
import { z as
|
|
39
|
-
import { a as
|
|
40
|
-
import { C as
|
|
41
|
-
var N,
|
|
39
|
+
import { z as xr, J as yr } from "./SyntaxHighlight-B0L4SC_N.js";
|
|
40
|
+
import { a as vr } from "./index-Djenk2Hj.js";
|
|
41
|
+
import { C as br } from "./CategoryHeading-MYL1u_6K.js";
|
|
42
|
+
var N, Te, jr = (Te = class extends Fe {
|
|
42
43
|
constructor(e = {}) {
|
|
43
44
|
super();
|
|
44
45
|
j(this, N);
|
|
45
46
|
this.config = e, y(this, N, /* @__PURE__ */ new Map());
|
|
46
47
|
}
|
|
47
48
|
build(e, r, n) {
|
|
48
|
-
const a = r.queryKey, o = r.queryHash ??
|
|
49
|
+
const a = r.queryKey, o = r.queryHash ?? Be(a, r);
|
|
49
50
|
let i = this.get(o);
|
|
50
51
|
return i || (i = new gt({
|
|
51
52
|
cache: this,
|
|
@@ -110,13 +111,13 @@ var N, Ie, gr = (Ie = class extends Fe {
|
|
|
110
111
|
});
|
|
111
112
|
});
|
|
112
113
|
}
|
|
113
|
-
}, N = new WeakMap(),
|
|
114
|
+
}, N = new WeakMap(), Te), O, C, Y, Ie, wr = (Ie = class extends Fe {
|
|
114
115
|
constructor(e = {}) {
|
|
115
116
|
super();
|
|
116
117
|
j(this, O);
|
|
117
|
-
j(this,
|
|
118
|
+
j(this, C);
|
|
118
119
|
j(this, Y);
|
|
119
|
-
this.config = e, y(this, O, /* @__PURE__ */ new Set()), y(this,
|
|
120
|
+
this.config = e, y(this, O, /* @__PURE__ */ new Set()), y(this, C, /* @__PURE__ */ new Map()), y(this, Y, 0);
|
|
120
121
|
}
|
|
121
122
|
build(e, r, n) {
|
|
122
123
|
const a = new Rt({
|
|
@@ -131,8 +132,8 @@ var N, Ie, gr = (Ie = class extends Fe {
|
|
|
131
132
|
l(this, O).add(e);
|
|
132
133
|
const r = _(e);
|
|
133
134
|
if (typeof r == "string") {
|
|
134
|
-
const n = l(this,
|
|
135
|
-
n ? n.push(e) : l(this,
|
|
135
|
+
const n = l(this, C).get(r);
|
|
136
|
+
n ? n.push(e) : l(this, C).set(r, [e]);
|
|
136
137
|
}
|
|
137
138
|
this.notify({ type: "added", mutation: e });
|
|
138
139
|
}
|
|
@@ -140,12 +141,12 @@ var N, Ie, gr = (Ie = class extends Fe {
|
|
|
140
141
|
if (l(this, O).delete(e)) {
|
|
141
142
|
const r = _(e);
|
|
142
143
|
if (typeof r == "string") {
|
|
143
|
-
const n = l(this,
|
|
144
|
+
const n = l(this, C).get(r);
|
|
144
145
|
if (n)
|
|
145
146
|
if (n.length > 1) {
|
|
146
147
|
const a = n.indexOf(e);
|
|
147
148
|
a !== -1 && n.splice(a, 1);
|
|
148
|
-
} else n[0] === e && l(this,
|
|
149
|
+
} else n[0] === e && l(this, C).delete(r);
|
|
149
150
|
}
|
|
150
151
|
}
|
|
151
152
|
this.notify({ type: "removed", mutation: e });
|
|
@@ -153,7 +154,7 @@ var N, Ie, gr = (Ie = class extends Fe {
|
|
|
153
154
|
canRun(e) {
|
|
154
155
|
const r = _(e);
|
|
155
156
|
if (typeof r == "string") {
|
|
156
|
-
const n = l(this,
|
|
157
|
+
const n = l(this, C).get(r), a = n == null ? void 0 : n.find(
|
|
157
158
|
(o) => o.state.status === "pending"
|
|
158
159
|
);
|
|
159
160
|
return !a || a === e;
|
|
@@ -164,7 +165,7 @@ var N, Ie, gr = (Ie = class extends Fe {
|
|
|
164
165
|
var n;
|
|
165
166
|
const r = _(e);
|
|
166
167
|
if (typeof r == "string") {
|
|
167
|
-
const a = (n = l(this,
|
|
168
|
+
const a = (n = l(this, C).get(r)) == null ? void 0 : n.find((o) => o !== e && o.state.isPaused);
|
|
168
169
|
return (a == null ? void 0 : a.continue()) ?? Promise.resolve();
|
|
169
170
|
} else
|
|
170
171
|
return Promise.resolve();
|
|
@@ -173,7 +174,7 @@ var N, Ie, gr = (Ie = class extends Fe {
|
|
|
173
174
|
w.batch(() => {
|
|
174
175
|
l(this, O).forEach((e) => {
|
|
175
176
|
this.notify({ type: "removed", mutation: e });
|
|
176
|
-
}), l(this, O).clear(), l(this,
|
|
177
|
+
}), l(this, O).clear(), l(this, C).clear();
|
|
177
178
|
});
|
|
178
179
|
}
|
|
179
180
|
getAll() {
|
|
@@ -203,7 +204,7 @@ var N, Ie, gr = (Ie = class extends Fe {
|
|
|
203
204
|
)
|
|
204
205
|
);
|
|
205
206
|
}
|
|
206
|
-
}, O = new WeakMap(),
|
|
207
|
+
}, O = new WeakMap(), C = new WeakMap(), Y = new WeakMap(), Ie);
|
|
207
208
|
function _(t) {
|
|
208
209
|
var e;
|
|
209
210
|
return (e = t.options.scope) == null ? void 0 : e.id;
|
|
@@ -216,53 +217,53 @@ function De(t) {
|
|
|
216
217
|
let u = { pages: [], pageParams: [] }, d = 0;
|
|
217
218
|
const c = async () => {
|
|
218
219
|
let m = !1;
|
|
219
|
-
const
|
|
220
|
+
const k = (b) => {
|
|
220
221
|
Object.defineProperty(b, "signal", {
|
|
221
222
|
enumerable: !0,
|
|
222
223
|
get: () => (e.signal.aborted ? m = !0 : e.signal.addEventListener("abort", () => {
|
|
223
224
|
m = !0;
|
|
224
225
|
}), e.signal)
|
|
225
226
|
});
|
|
226
|
-
}, V = mt(e.options, e.fetchOptions), K = async (b,
|
|
227
|
+
}, V = mt(e.options, e.fetchOptions), K = async (b, S, $) => {
|
|
227
228
|
if (m)
|
|
228
229
|
return Promise.reject();
|
|
229
|
-
if (
|
|
230
|
+
if (S == null && b.pages.length)
|
|
230
231
|
return Promise.resolve(b);
|
|
231
232
|
const X = {
|
|
232
233
|
queryKey: e.queryKey,
|
|
233
|
-
pageParam:
|
|
234
|
+
pageParam: S,
|
|
234
235
|
direction: $ ? "backward" : "forward",
|
|
235
236
|
meta: e.options.meta
|
|
236
237
|
};
|
|
237
|
-
|
|
238
|
+
k(X);
|
|
238
239
|
const ot = await V(
|
|
239
240
|
X
|
|
240
241
|
), { maxPages: me } = e.options, pe = $ ? pt : xt;
|
|
241
242
|
return {
|
|
242
243
|
pages: pe(b.pages, ot, me),
|
|
243
|
-
pageParams: pe(b.pageParams,
|
|
244
|
+
pageParams: pe(b.pageParams, S, me)
|
|
244
245
|
};
|
|
245
246
|
};
|
|
246
247
|
if (a && o.length) {
|
|
247
|
-
const b = a === "backward",
|
|
248
|
+
const b = a === "backward", S = b ? Pr : Me, $ = {
|
|
248
249
|
pages: o,
|
|
249
250
|
pageParams: i
|
|
250
|
-
}, X =
|
|
251
|
+
}, X = S(n, $);
|
|
251
252
|
u = await K($, X, b);
|
|
252
253
|
} else {
|
|
253
254
|
const b = t ?? o.length;
|
|
254
255
|
do {
|
|
255
|
-
const
|
|
256
|
-
if (d > 0 &&
|
|
256
|
+
const S = d === 0 ? i[0] ?? n.initialPageParam : Me(n, u);
|
|
257
|
+
if (d > 0 && S == null)
|
|
257
258
|
break;
|
|
258
|
-
u = await K(u,
|
|
259
|
+
u = await K(u, S), d++;
|
|
259
260
|
} while (d < b);
|
|
260
261
|
}
|
|
261
262
|
return u;
|
|
262
263
|
};
|
|
263
264
|
e.options.persister ? e.fetchFn = () => {
|
|
264
|
-
var m,
|
|
265
|
-
return (
|
|
265
|
+
var m, k;
|
|
266
|
+
return (k = (m = e.options).persister) == null ? void 0 : k.call(
|
|
266
267
|
m,
|
|
267
268
|
c,
|
|
268
269
|
{
|
|
@@ -285,32 +286,32 @@ function Me(t, { pages: e, pageParams: r }) {
|
|
|
285
286
|
r
|
|
286
287
|
) : void 0;
|
|
287
288
|
}
|
|
288
|
-
function
|
|
289
|
+
function Pr(t, { pages: e, pageParams: r }) {
|
|
289
290
|
var n;
|
|
290
291
|
return e.length > 0 ? (n = t.getPreviousPageParam) == null ? void 0 : n.call(t, e[0], e, r[0], r) : void 0;
|
|
291
292
|
}
|
|
292
|
-
var p, E, q, R, F,
|
|
293
|
+
var p, E, q, R, F, T, B, H, Qe, kr = (Qe = class {
|
|
293
294
|
constructor(t = {}) {
|
|
294
295
|
j(this, p);
|
|
295
296
|
j(this, E);
|
|
296
297
|
j(this, q);
|
|
297
298
|
j(this, R);
|
|
298
299
|
j(this, F);
|
|
299
|
-
j(this,
|
|
300
|
+
j(this, T);
|
|
301
|
+
j(this, B);
|
|
300
302
|
j(this, H);
|
|
301
|
-
|
|
302
|
-
y(this, p, t.queryCache || new gr()), y(this, E, t.mutationCache || new mr()), y(this, q, t.defaultOptions || {}), y(this, R, /* @__PURE__ */ new Map()), y(this, F, /* @__PURE__ */ new Map()), y(this, I, 0);
|
|
303
|
+
y(this, p, t.queryCache || new jr()), y(this, E, t.mutationCache || new wr()), y(this, q, t.defaultOptions || {}), y(this, R, /* @__PURE__ */ new Map()), y(this, F, /* @__PURE__ */ new Map()), y(this, T, 0);
|
|
303
304
|
}
|
|
304
305
|
mount() {
|
|
305
|
-
G(this,
|
|
306
|
+
G(this, T)._++, l(this, T) === 1 && (y(this, B, yt.subscribe(async (t) => {
|
|
306
307
|
t && (await this.resumePausedMutations(), l(this, p).onFocus());
|
|
307
|
-
})), y(this,
|
|
308
|
+
})), y(this, H, je.subscribe(async (t) => {
|
|
308
309
|
t && (await this.resumePausedMutations(), l(this, p).onOnline());
|
|
309
310
|
})));
|
|
310
311
|
}
|
|
311
312
|
unmount() {
|
|
312
313
|
var t, e;
|
|
313
|
-
G(this,
|
|
314
|
+
G(this, T)._--, l(this, T) === 0 && ((t = l(this, B)) == null || t.call(this), y(this, B, void 0), (e = l(this, H)) == null || e.call(this), y(this, H, void 0));
|
|
314
315
|
}
|
|
315
316
|
isFetching(t) {
|
|
316
317
|
return l(this, p).findAll({ ...t, fetchStatus: "fetching" }).length;
|
|
@@ -447,7 +448,7 @@ var p, E, q, R, F, I, H, z, Qe, xr = (Qe = class {
|
|
|
447
448
|
getQueryDefaults(t) {
|
|
448
449
|
const e = [...l(this, R).values()], r = {};
|
|
449
450
|
return e.forEach((n) => {
|
|
450
|
-
|
|
451
|
+
ke(t, n.queryKey) && Object.assign(r, n.defaultOptions);
|
|
451
452
|
}), r;
|
|
452
453
|
}
|
|
453
454
|
setMutationDefaults(t, e) {
|
|
@@ -460,7 +461,7 @@ var p, E, q, R, F, I, H, z, Qe, xr = (Qe = class {
|
|
|
460
461
|
const e = [...l(this, F).values()];
|
|
461
462
|
let r = {};
|
|
462
463
|
return e.forEach((n) => {
|
|
463
|
-
|
|
464
|
+
ke(t, n.mutationKey) && (r = { ...r, ...n.defaultOptions });
|
|
464
465
|
}), r;
|
|
465
466
|
}
|
|
466
467
|
defaultQueryOptions(t) {
|
|
@@ -472,7 +473,7 @@ var p, E, q, R, F, I, H, z, Qe, xr = (Qe = class {
|
|
|
472
473
|
...t,
|
|
473
474
|
_defaulted: !0
|
|
474
475
|
};
|
|
475
|
-
return e.queryHash || (e.queryHash =
|
|
476
|
+
return e.queryHash || (e.queryHash = Be(
|
|
476
477
|
e.queryKey,
|
|
477
478
|
e
|
|
478
479
|
)), e.refetchOnReconnect === void 0 && (e.refetchOnReconnect = e.networkMode !== "always"), e.throwOnError === void 0 && (e.throwOnError = !!e.suspense), !e.networkMode && e.persister && (e.networkMode = "offlineFirst"), e.queryFn === bt && (e.enabled = !1), e;
|
|
@@ -488,15 +489,15 @@ var p, E, q, R, F, I, H, z, Qe, xr = (Qe = class {
|
|
|
488
489
|
clear() {
|
|
489
490
|
l(this, p).clear(), l(this, E).clear();
|
|
490
491
|
}
|
|
491
|
-
}, p = new WeakMap(), E = new WeakMap(), q = new WeakMap(), R = new WeakMap(), F = new WeakMap(),
|
|
492
|
-
function
|
|
492
|
+
}, p = new WeakMap(), E = new WeakMap(), q = new WeakMap(), R = new WeakMap(), F = new WeakMap(), T = new WeakMap(), B = new WeakMap(), H = new WeakMap(), Qe);
|
|
493
|
+
function Cr(t) {
|
|
493
494
|
return t;
|
|
494
495
|
}
|
|
495
496
|
function Oe(t, e, r) {
|
|
496
497
|
var d, c;
|
|
497
498
|
if (typeof e != "object" || e === null)
|
|
498
499
|
return;
|
|
499
|
-
const n = t.getMutationCache(), a = t.getQueryCache(), o = ((d = r == null ? void 0 : r.defaultOptions) == null ? void 0 : d.deserializeData) ?? ((c = t.getDefaultOptions().hydrate) == null ? void 0 : c.deserializeData) ??
|
|
500
|
+
const n = t.getMutationCache(), a = t.getQueryCache(), o = ((d = r == null ? void 0 : r.defaultOptions) == null ? void 0 : d.deserializeData) ?? ((c = t.getDefaultOptions().hydrate) == null ? void 0 : c.deserializeData) ?? Cr, i = e.mutations || [], u = e.queries || [];
|
|
500
501
|
i.forEach(({ state: g, ...f }) => {
|
|
501
502
|
var h, x;
|
|
502
503
|
n.build(
|
|
@@ -511,13 +512,13 @@ function Oe(t, e, r) {
|
|
|
511
512
|
}), u.forEach(({ queryKey: g, state: f, queryHash: h, meta: x, promise: v }) => {
|
|
512
513
|
var V, K;
|
|
513
514
|
let m = a.get(h);
|
|
514
|
-
const
|
|
515
|
+
const k = f.data === void 0 ? f.data : o(f.data);
|
|
515
516
|
if (m) {
|
|
516
517
|
if (m.state.dataUpdatedAt < f.dataUpdatedAt) {
|
|
517
|
-
const { fetchStatus: b, ...
|
|
518
|
+
const { fetchStatus: b, ...S } = f;
|
|
518
519
|
m.setState({
|
|
519
|
-
...
|
|
520
|
-
data:
|
|
520
|
+
...S,
|
|
521
|
+
data: k
|
|
521
522
|
});
|
|
522
523
|
}
|
|
523
524
|
} else
|
|
@@ -534,7 +535,7 @@ function Oe(t, e, r) {
|
|
|
534
535
|
// query being stuck in fetching state upon hydration
|
|
535
536
|
{
|
|
536
537
|
...f,
|
|
537
|
-
data:
|
|
538
|
+
data: k,
|
|
538
539
|
fetchStatus: "idle"
|
|
539
540
|
}
|
|
540
541
|
);
|
|
@@ -544,7 +545,7 @@ function Oe(t, e, r) {
|
|
|
544
545
|
}
|
|
545
546
|
});
|
|
546
547
|
}
|
|
547
|
-
var
|
|
548
|
+
var Sr = ({
|
|
548
549
|
children: t,
|
|
549
550
|
options: e = {},
|
|
550
551
|
state: r,
|
|
@@ -562,7 +563,7 @@ var vr = ({
|
|
|
562
563
|
g.push(h);
|
|
563
564
|
else {
|
|
564
565
|
const v = h.state.dataUpdatedAt > x.state.dataUpdatedAt, m = o == null ? void 0 : o.find(
|
|
565
|
-
(
|
|
566
|
+
(k) => k.queryHash === h.queryHash
|
|
566
567
|
);
|
|
567
568
|
v && (!m || h.state.dataUpdatedAt > m.state.dataUpdatedAt) && f.push(h);
|
|
568
569
|
}
|
|
@@ -575,17 +576,17 @@ var vr = ({
|
|
|
575
576
|
o && (Oe(a, { queries: o }, u.current), i(void 0));
|
|
576
577
|
}, [a, o]), t;
|
|
577
578
|
};
|
|
578
|
-
const
|
|
579
|
+
const Nr = (t) => {
|
|
579
580
|
const e = ee(t);
|
|
580
|
-
return e.current = t,
|
|
581
|
+
return e.current = t, I(() => {
|
|
581
582
|
e.current = t;
|
|
582
583
|
}, [t]), e;
|
|
583
|
-
},
|
|
584
|
+
}, Dr = () => {
|
|
584
585
|
var o;
|
|
585
|
-
const t =
|
|
586
|
+
const t = z(), e = A(), r = le(), n = Nr(r.pathname), a = (o = e.options.protectedRoutes) == null ? void 0 : o.some(
|
|
586
587
|
(i) => ut({ path: i, end: !0 }, r.pathname)
|
|
587
588
|
);
|
|
588
|
-
if (
|
|
589
|
+
if (I(() => {
|
|
589
590
|
var i;
|
|
590
591
|
a && !t.isAuthenticated && ((i = e.authentication) == null || i.signIn({
|
|
591
592
|
redirectTo: n.current
|
|
@@ -599,7 +600,7 @@ const br = (t) => {
|
|
|
599
600
|
});
|
|
600
601
|
return /* @__PURE__ */ s.jsx(ce, {});
|
|
601
602
|
};
|
|
602
|
-
function
|
|
603
|
+
function Mr({ error: t }) {
|
|
603
604
|
return /* @__PURE__ */ s.jsx(Ue, { error: t });
|
|
604
605
|
}
|
|
605
606
|
/**
|
|
@@ -612,30 +613,30 @@ function wr({ error: t }) {
|
|
|
612
613
|
*
|
|
613
614
|
* @license MIT
|
|
614
615
|
*/
|
|
615
|
-
function
|
|
616
|
+
function Or(t) {
|
|
616
617
|
return /* @__PURE__ */ U.createElement(dt, { flushSync: Ft.flushSync, ...t });
|
|
617
618
|
}
|
|
618
|
-
const ie = he({ stagger: !1 }),
|
|
619
|
+
const ie = he({ stagger: !1 }), Ar = new kr({
|
|
619
620
|
defaultOptions: {
|
|
620
621
|
queries: {
|
|
621
622
|
staleTime: 1e3 * 60 * 5
|
|
622
623
|
}
|
|
623
624
|
}
|
|
624
|
-
}),
|
|
625
|
+
}), Er = ({
|
|
625
626
|
router: t,
|
|
626
627
|
hydrate: e = !1
|
|
627
|
-
}) => /* @__PURE__ */ s.jsx(Le, { children: /* @__PURE__ */ s.jsx(
|
|
628
|
+
}) => /* @__PURE__ */ s.jsx(Le, { children: /* @__PURE__ */ s.jsx(He, { client: Ar, children: /* @__PURE__ */ s.jsx(Sr, { state: e ? window.DATA : void 0, children: /* @__PURE__ */ s.jsx(Re, { children: /* @__PURE__ */ s.jsx(ie.Provider, { value: { stagger: !e }, children: /* @__PURE__ */ s.jsx(Or, { router: t }) }) }) }) }) }), qr = ({
|
|
628
629
|
router: t,
|
|
629
630
|
context: e,
|
|
630
631
|
queryClient: r,
|
|
631
632
|
helmetContext: n
|
|
632
|
-
}) => /* @__PURE__ */ s.jsx(Le, { children: /* @__PURE__ */ s.jsx(
|
|
633
|
-
var Z = { exports: {} },
|
|
634
|
-
function
|
|
633
|
+
}) => /* @__PURE__ */ s.jsx(Le, { children: /* @__PURE__ */ s.jsx(He, { client: r, children: /* @__PURE__ */ s.jsx(Re, { context: n, children: /* @__PURE__ */ s.jsx(ht, { router: t, context: e }) }) }) });
|
|
634
|
+
var Z = { exports: {} }, Tr = Z.exports, Ae;
|
|
635
|
+
function Ir() {
|
|
635
636
|
return Ae || (Ae = 1, function(t, e) {
|
|
636
637
|
(function(r, n) {
|
|
637
638
|
n(e, Nt);
|
|
638
|
-
})(
|
|
639
|
+
})(Tr, function(r, n) {
|
|
639
640
|
const a = {
|
|
640
641
|
delay: 500,
|
|
641
642
|
minDuration: 200,
|
|
@@ -669,15 +670,15 @@ function Dr() {
|
|
|
669
670
|
});
|
|
670
671
|
}(Z, Z.exports)), Z.exports;
|
|
671
672
|
}
|
|
672
|
-
var
|
|
673
|
-
const
|
|
673
|
+
var Qr = Ir();
|
|
674
|
+
const Rr = () => {
|
|
674
675
|
const t = le(), e = ee(t.pathname);
|
|
675
|
-
|
|
676
|
+
I(() => {
|
|
676
677
|
const r = e.current !== t.pathname, n = t.hash !== "";
|
|
677
678
|
r && !n && window.scrollTo(0, 0), e.current = t.pathname;
|
|
678
679
|
}, [t.pathname, t.hash]);
|
|
679
680
|
};
|
|
680
|
-
function
|
|
681
|
+
function Fr({
|
|
681
682
|
className: t,
|
|
682
683
|
...e
|
|
683
684
|
}) {
|
|
@@ -689,13 +690,13 @@ function Ar({
|
|
|
689
690
|
}
|
|
690
691
|
);
|
|
691
692
|
}
|
|
692
|
-
const
|
|
693
|
+
const Ee = {
|
|
693
694
|
info: "bg-blue-500",
|
|
694
695
|
note: "bg-gray-500",
|
|
695
696
|
tip: "bg-green-600",
|
|
696
697
|
caution: "bg-orange-500",
|
|
697
698
|
danger: "bg-rose-500"
|
|
698
|
-
},
|
|
699
|
+
}, Br = () => {
|
|
699
700
|
const { page: t } = A(), [e, r] = L(!0);
|
|
700
701
|
if (!(t != null && t.banner) || !e)
|
|
701
702
|
return /* @__PURE__ */ s.jsx("style", { children: ":root { --banner-height: 0px; }" });
|
|
@@ -716,7 +717,7 @@ const Er = (t) => "getProfileMenuItems" in t && typeof t.getProfileMenuItems ==
|
|
|
716
717
|
type: "button",
|
|
717
718
|
className: "md:absolute md:right-4 -m-1.5 p-1.5 hover:bg-accent-foreground/10 rounded-md",
|
|
718
719
|
onClick: () => r(!1),
|
|
719
|
-
children: /* @__PURE__ */ s.jsx(
|
|
720
|
+
children: /* @__PURE__ */ s.jsx(Bt, { size: 16 })
|
|
720
721
|
}
|
|
721
722
|
)
|
|
722
723
|
]
|
|
@@ -724,7 +725,7 @@ const Er = (t) => "getProfileMenuItems" in t && typeof t.getProfileMenuItems ==
|
|
|
724
725
|
);
|
|
725
726
|
}, We = ({ className: t }) => {
|
|
726
727
|
const e = A(), [r, n] = L(!1), a = Dt(() => n(!1), []);
|
|
727
|
-
|
|
728
|
+
I(() => {
|
|
728
729
|
if (r)
|
|
729
730
|
return;
|
|
730
731
|
function i(u) {
|
|
@@ -734,7 +735,7 @@ const Er = (t) => "getProfileMenuItems" in t && typeof t.getProfileMenuItems ==
|
|
|
734
735
|
window.removeEventListener("keydown", i);
|
|
735
736
|
};
|
|
736
737
|
}, [r, n]);
|
|
737
|
-
const o = e.plugins.find(
|
|
738
|
+
const o = e.plugins.find(tr);
|
|
738
739
|
return o ? /* @__PURE__ */ s.jsxs("div", { className: t, children: [
|
|
739
740
|
/* @__PURE__ */ s.jsxs(
|
|
740
741
|
"button",
|
|
@@ -744,7 +745,7 @@ const Er = (t) => "getProfileMenuItems" in t && typeof t.getProfileMenuItems ==
|
|
|
744
745
|
className: "flex items-center border border-input hover:bg-accent hover:text-accent-foreground p-4 relative h-8 justify-start rounded-lg bg-background text-sm text-muted-foreground shadow-none w-full sm:w-72",
|
|
745
746
|
children: [
|
|
746
747
|
/* @__PURE__ */ s.jsxs("div", { className: "flex items-center gap-2 flex-grow", children: [
|
|
747
|
-
/* @__PURE__ */ s.jsx(
|
|
748
|
+
/* @__PURE__ */ s.jsx(Ht, { size: 14 }),
|
|
748
749
|
"Search"
|
|
749
750
|
] }),
|
|
750
751
|
/* @__PURE__ */ s.jsx("kbd", { className: "absolute right-[0.3rem] top-[0.3rem] hidden h-5 select-none items-center gap-1 rounded border bg-muted px-1.5 font-mono text-[11px] font-medium opacity-100 sm:flex", children: "⌘K" })
|
|
@@ -757,7 +758,7 @@ const Er = (t) => "getProfileMenuItems" in t && typeof t.getProfileMenuItems ==
|
|
|
757
758
|
}) })
|
|
758
759
|
] }) : null;
|
|
759
760
|
}, Je = () => {
|
|
760
|
-
const { resolvedTheme: t, setTheme: e } =
|
|
761
|
+
const { resolvedTheme: t, setTheme: e } = xr();
|
|
761
762
|
return /* @__PURE__ */ s.jsx(ge, { fallback: /* @__PURE__ */ s.jsx(ae, { variant: "ghost", size: "icon" }), children: /* @__PURE__ */ s.jsxs(
|
|
762
763
|
"button",
|
|
763
764
|
{
|
|
@@ -774,7 +775,7 @@ const Er = (t) => "getProfileMenuItems" in t && typeof t.getProfileMenuItems ==
|
|
|
774
775
|
t === "light" && "border-border bg-muted/50",
|
|
775
776
|
t === "dark" && "group-hover:[&>svg>path]:scale-110 group-hover:[&>svg>path]:-translate-x-[1px] group-hover:[&>svg>path]:-translate-y-[1px] group-hover:rotate-[15deg] "
|
|
776
777
|
),
|
|
777
|
-
children: /* @__PURE__ */ s.jsx(
|
|
778
|
+
children: /* @__PURE__ */ s.jsx(zt, { size: 16 })
|
|
778
779
|
}
|
|
779
780
|
),
|
|
780
781
|
/* @__PURE__ */ s.jsx(
|
|
@@ -791,8 +792,8 @@ const Er = (t) => "getProfileMenuItems" in t && typeof t.getProfileMenuItems ==
|
|
|
791
792
|
]
|
|
792
793
|
}
|
|
793
794
|
) });
|
|
794
|
-
}, et = (t) => (e) => e.display === "auth" && t || e.display === "anon" && !t || !e.display || e.display === "always",
|
|
795
|
-
const { topNavigation: t } = A(), { isAuthenticated: e } =
|
|
795
|
+
}, et = (t) => (e) => e.display === "auth" && t || e.display === "anon" && !t || !e.display || e.display === "always", Hr = () => {
|
|
796
|
+
const { topNavigation: t } = A(), { isAuthenticated: e } = z();
|
|
796
797
|
return t.length <= 1 ? /* @__PURE__ */ s.jsx("style", { children: ":root { --top-nav-height: 0px; }" }) : /* @__PURE__ */ s.jsx(fe, { children: /* @__PURE__ */ s.jsx("nav", { className: "hidden lg:block text-sm px-12 h-[--top-nav-height]", children: /* @__PURE__ */ s.jsx("ul", { className: "flex flex-row items-center gap-8", children: t.filter(et(e)).map((r) => /* @__PURE__ */ s.jsx("li", { children: /* @__PURE__ */ s.jsx(tt, { ...r }) }, r.id)) }) }) });
|
|
797
798
|
}, tt = ({
|
|
798
799
|
id: t,
|
|
@@ -800,7 +801,7 @@ const Er = (t) => "getProfileMenuItems" in t && typeof t.getProfileMenuItems ==
|
|
|
800
801
|
default: r
|
|
801
802
|
}) => {
|
|
802
803
|
var c;
|
|
803
|
-
const { sidebars: n } = A(), a = n[t], o =
|
|
804
|
+
const { sidebars: n } = A(), a = n[t], o = ze(), i = !!ue().location, u = ((c = o.topNavItem) == null ? void 0 : c.id) === t && !i, d = r ?? (a ? wt(a, (g) => {
|
|
804
805
|
if (g.type === "doc") return ne(g.id);
|
|
805
806
|
}) : ne(t));
|
|
806
807
|
if (!d)
|
|
@@ -813,7 +814,7 @@ const Er = (t) => "getProfileMenuItems" in t && typeof t.getProfileMenuItems ==
|
|
|
813
814
|
/* @__PURE__ */ s.jsx(
|
|
814
815
|
ft,
|
|
815
816
|
{
|
|
816
|
-
className: ({ isPending: g }) =>
|
|
817
|
+
className: ({ isPending: g }) => vr(
|
|
817
818
|
"block lg:py-3.5 font-medium -mb-px",
|
|
818
819
|
u || g ? "border-primary text-foreground" : "border-transparent text-foreground/75 hover:text-foreground hover:border-accent-foreground/25"
|
|
819
820
|
),
|
|
@@ -822,8 +823,8 @@ const Er = (t) => "getProfileMenuItems" in t && typeof t.getProfileMenuItems ==
|
|
|
822
823
|
}
|
|
823
824
|
)
|
|
824
825
|
);
|
|
825
|
-
},
|
|
826
|
-
const { topNavigation: t } = A(), { isAuthenticated: e } =
|
|
826
|
+
}, zr = () => {
|
|
827
|
+
const { topNavigation: t } = A(), { isAuthenticated: e } = z(), [r, n] = L(!1);
|
|
827
828
|
return /* @__PURE__ */ s.jsxs(
|
|
828
829
|
Ze,
|
|
829
830
|
{
|
|
@@ -850,19 +851,19 @@ const Er = (t) => "getProfileMenuItems" in t && typeof t.getProfileMenuItems ==
|
|
|
850
851
|
]
|
|
851
852
|
}
|
|
852
853
|
);
|
|
853
|
-
}, J = ({ item: t }) => t.children ? /* @__PURE__ */ s.jsxs(
|
|
854
|
-
/* @__PURE__ */ s.jsx(
|
|
855
|
-
/* @__PURE__ */ s.jsx(
|
|
854
|
+
}, J = ({ item: t }) => t.children ? /* @__PURE__ */ s.jsxs(hr, { children: [
|
|
855
|
+
/* @__PURE__ */ s.jsx(fr, { children: t.label }),
|
|
856
|
+
/* @__PURE__ */ s.jsx(gr, { children: /* @__PURE__ */ s.jsx(mr, { children: t.children.map((e, r) => (
|
|
856
857
|
// eslint-disable-next-line react/no-array-index-key
|
|
857
858
|
/* @__PURE__ */ s.jsx(J, { item: e }, r)
|
|
858
859
|
)) }) })
|
|
859
|
-
] }, t.label) : /* @__PURE__ */ s.jsx(de, { to: t.path ?? "", children: /* @__PURE__ */ s.jsxs(
|
|
860
|
+
] }, t.label) : /* @__PURE__ */ s.jsx(de, { to: t.path ?? "", children: /* @__PURE__ */ s.jsxs(pr, { className: "flex gap-2", children: [
|
|
860
861
|
t.icon && /* @__PURE__ */ s.jsx(t.icon, { size: 16, strokeWidth: 1, absoluteStrokeWidth: !0 }),
|
|
861
862
|
t.label
|
|
862
863
|
] }, t.label) }), rt = Ke(function() {
|
|
863
|
-
const e =
|
|
864
|
+
const e = z(), { isAuthenticated: r, profile: n, isAuthEnabled: a } = z(), o = A(), { page: i, plugins: u } = o, d = u.filter((c) => rr(c)).flatMap((c) => c.getProfileMenuItems(o)).sort((c) => c.weight ?? 0);
|
|
864
865
|
return /* @__PURE__ */ s.jsxs("header", { className: "sticky lg:top-0 z-10 bg-background/80 backdrop-blur w-full", children: [
|
|
865
|
-
/* @__PURE__ */ s.jsx(
|
|
866
|
+
/* @__PURE__ */ s.jsx(Br, {}),
|
|
866
867
|
/* @__PURE__ */ s.jsx("div", { className: "border-b", children: /* @__PURE__ */ s.jsxs("div", { className: "max-w-screen-2xl border-l border-r mx-auto grid grid-cols-[1fr_auto] lg:grid-cols-[calc(var(--side-nav-width))_1fr] lg:gap-12 items-center px-4 lg:px-12 h-[--top-header-height]", children: [
|
|
867
868
|
/* @__PURE__ */ s.jsx("div", { className: "flex", children: /* @__PURE__ */ s.jsx(de, { to: "/", children: /* @__PURE__ */ s.jsxs("div", { className: "flex items-center gap-3.5", children: [
|
|
868
869
|
(i == null ? void 0 : i.logo) && /* @__PURE__ */ s.jsxs(s.Fragment, { children: [
|
|
@@ -897,17 +898,17 @@ const Er = (t) => "getProfileMenuItems" in t && typeof t.getProfileMenuItems ==
|
|
|
897
898
|
] }) }) }),
|
|
898
899
|
/* @__PURE__ */ s.jsxs("div", { className: "grid grid-cols-1 lg:grid-cols-[--sidecar-grid-cols] items-center gap-8", children: [
|
|
899
900
|
/* @__PURE__ */ s.jsx("div", { className: "w-full justify-center hidden lg:flex", children: /* @__PURE__ */ s.jsx(We, {}) }),
|
|
900
|
-
/* @__PURE__ */ s.jsx(
|
|
901
|
+
/* @__PURE__ */ s.jsx(zr, {}),
|
|
901
902
|
/* @__PURE__ */ s.jsxs("div", { className: "hidden lg:flex items-center justify-self-end text-sm gap-2", children: [
|
|
902
903
|
/* @__PURE__ */ s.jsx(D, { name: "head-navigation-start" }),
|
|
903
904
|
a && /* @__PURE__ */ s.jsx(
|
|
904
905
|
ge,
|
|
905
906
|
{
|
|
906
|
-
fallback: /* @__PURE__ */ s.jsx(
|
|
907
|
-
children: r ? Object.values(d).length > 0 && /* @__PURE__ */ s.jsxs(
|
|
908
|
-
/* @__PURE__ */ s.jsx(
|
|
909
|
-
/* @__PURE__ */ s.jsxs(
|
|
910
|
-
/* @__PURE__ */ s.jsxs(
|
|
907
|
+
fallback: /* @__PURE__ */ s.jsx(Fr, { className: "rounded h-5 w-24 mr-4" }),
|
|
908
|
+
children: r ? Object.values(d).length > 0 && /* @__PURE__ */ s.jsxs(lr, { modal: !1, children: [
|
|
909
|
+
/* @__PURE__ */ s.jsx(cr, { asChild: !0, children: /* @__PURE__ */ s.jsx(ae, { variant: "ghost", children: n != null && n.name ? `${n.name}` : "My Account" }) }),
|
|
910
|
+
/* @__PURE__ */ s.jsxs(ur, { className: "w-56", children: [
|
|
911
|
+
/* @__PURE__ */ s.jsxs(dr, { children: [
|
|
911
912
|
n != null && n.name ? `${n.name}` : "My Account",
|
|
912
913
|
(n == null ? void 0 : n.email) && /* @__PURE__ */ s.jsx("div", { className: "font-normal text-muted-foreground", children: n.email })
|
|
913
914
|
] }),
|
|
@@ -932,7 +933,7 @@ const Er = (t) => "getProfileMenuItems" in t && typeof t.getProfileMenuItems ==
|
|
|
932
933
|
] }) }),
|
|
933
934
|
/* @__PURE__ */ s.jsx("div", { className: "border-b", children: /* @__PURE__ */ s.jsxs("div", { className: "max-w-screen-2xl mx-auto border-l border-r", children: [
|
|
934
935
|
/* @__PURE__ */ s.jsx(D, { name: "top-navigation-before" }),
|
|
935
|
-
/* @__PURE__ */ s.jsx(
|
|
936
|
+
/* @__PURE__ */ s.jsx(Hr, {}),
|
|
936
937
|
/* @__PURE__ */ s.jsx(D, { name: "top-navigation-after" })
|
|
937
938
|
] }) })
|
|
938
939
|
] });
|
|
@@ -955,8 +956,8 @@ st.displayName = "SidebarWrapper";
|
|
|
955
956
|
const Lr = ({
|
|
956
957
|
onRequestClose: t
|
|
957
958
|
}) => {
|
|
958
|
-
const e = ee(null), r =
|
|
959
|
-
return
|
|
959
|
+
const e = ee(null), r = ze();
|
|
960
|
+
return I(() => {
|
|
960
961
|
var a;
|
|
961
962
|
const n = (a = e.current) == null ? void 0 : a.querySelector('[aria-current="page"]');
|
|
962
963
|
Ut(n ?? null);
|
|
@@ -968,7 +969,7 @@ const Lr = ({
|
|
|
968
969
|
pushMainContent: r.sidebar.length > 0,
|
|
969
970
|
children: [
|
|
970
971
|
/* @__PURE__ */ s.jsx(D, { name: "zudoku-before-navigation" }),
|
|
971
|
-
r.sidebar.map((n) => /* @__PURE__ */ s.jsx(
|
|
972
|
+
r.sidebar.map((n) => /* @__PURE__ */ s.jsx(Se, { item: n }, n.label)),
|
|
972
973
|
/* @__PURE__ */ s.jsx(D, { name: "zudoku-after-navigation" })
|
|
973
974
|
]
|
|
974
975
|
}
|
|
@@ -981,7 +982,7 @@ const Lr = ({
|
|
|
981
982
|
children: /* @__PURE__ */ s.jsxs("div", { className: "p-4 overflow-y-auto overscroll-none", children: [
|
|
982
983
|
/* @__PURE__ */ s.jsx(_e, { children: /* @__PURE__ */ s.jsx(Xe, { children: "Sidebar" }) }),
|
|
983
984
|
r.sidebar.map((n) => /* @__PURE__ */ s.jsx(
|
|
984
|
-
|
|
985
|
+
Se,
|
|
985
986
|
{
|
|
986
987
|
item: n,
|
|
987
988
|
onRequestClose: t
|
|
@@ -994,15 +995,15 @@ const Lr = ({
|
|
|
994
995
|
] });
|
|
995
996
|
}, qe = () => /* @__PURE__ */ s.jsx("main", { className: "grid h-[calc(100vh-var(--header-height))] place-items-center", children: /* @__PURE__ */ s.jsx(Ge, {}) }), Kr = ({ children: t }) => {
|
|
996
997
|
const e = le(), { setActiveAnchor: r } = Xt(), { meta: n, authentication: a } = A();
|
|
997
|
-
Zt(),
|
|
998
|
+
Zt(), Rr();
|
|
998
999
|
const o = ee(e.pathname);
|
|
999
|
-
|
|
1000
|
+
I(() => {
|
|
1000
1001
|
var g;
|
|
1001
1002
|
(g = a == null ? void 0 : a.onPageLoad) == null || g.call(a);
|
|
1002
|
-
}, [a]),
|
|
1003
|
+
}, [a]), I(() => {
|
|
1003
1004
|
e.pathname !== o.current && r(""), o.current = e.pathname;
|
|
1004
1005
|
}, [e.pathname, r]);
|
|
1005
|
-
const i = !!ue().location, u =
|
|
1006
|
+
const i = !!ue().location, u = Qr.useSpinDelay(i, {
|
|
1006
1007
|
delay: 300,
|
|
1007
1008
|
minDuration: 500
|
|
1008
1009
|
}), [d, c] = L(!1);
|
|
@@ -1062,7 +1063,7 @@ const Lr = ({
|
|
|
1062
1063
|
message: e,
|
|
1063
1064
|
category: r
|
|
1064
1065
|
}) => /* @__PURE__ */ s.jsxs("div", { className: Gt + " h-full pt-[--padding-content-top]", children: [
|
|
1065
|
-
r && /* @__PURE__ */ s.jsx(
|
|
1066
|
+
r && /* @__PURE__ */ s.jsx(br, { children: r }),
|
|
1066
1067
|
t && /* @__PURE__ */ s.jsx(_t, { level: 1, className: "flex gap-3.5 items-center", children: t }),
|
|
1067
1068
|
/* @__PURE__ */ s.jsx("p", { children: e })
|
|
1068
1069
|
] }), Ur = (t) => {
|
|
@@ -1203,13 +1204,13 @@ class Vr extends Ot {
|
|
|
1203
1204
|
if (typeof r == "function")
|
|
1204
1205
|
u = r(d);
|
|
1205
1206
|
else if (n)
|
|
1206
|
-
u =
|
|
1207
|
+
u = Ce(n, d);
|
|
1207
1208
|
else if (a !== void 0)
|
|
1208
1209
|
u = a;
|
|
1209
1210
|
else
|
|
1210
1211
|
throw i;
|
|
1211
1212
|
}
|
|
1212
|
-
return
|
|
1213
|
+
return Ce(Yr.Provider, {
|
|
1213
1214
|
value: {
|
|
1214
1215
|
didCatch: o,
|
|
1215
1216
|
error: i,
|
|
@@ -1233,14 +1234,14 @@ class Gr {
|
|
|
1233
1234
|
P(this, "navigationPlugins");
|
|
1234
1235
|
P(this, "initialize", async () => {
|
|
1235
1236
|
await Promise.all(
|
|
1236
|
-
this.plugins.filter(
|
|
1237
|
+
this.plugins.filter(nr).map((e) => {
|
|
1237
1238
|
var r;
|
|
1238
1239
|
return (r = e.initialize) == null ? void 0 : r.call(e, this);
|
|
1239
1240
|
})
|
|
1240
1241
|
);
|
|
1241
1242
|
});
|
|
1242
1243
|
P(this, "getApiIdentities", async () => (await Promise.all(
|
|
1243
|
-
this.plugins.filter(
|
|
1244
|
+
this.plugins.filter(ar).map((r) => r.getIdentities(this))
|
|
1244
1245
|
)).flat());
|
|
1245
1246
|
P(this, "getPluginSidebar", async (e) => (await Promise.all(
|
|
1246
1247
|
this.navigationPlugins.map(
|
|
@@ -1256,7 +1257,7 @@ class Gr {
|
|
|
1256
1257
|
const r = await this.authentication.getAccessToken();
|
|
1257
1258
|
return e.headers.set("Authorization", `Bearer ${r}`), e;
|
|
1258
1259
|
});
|
|
1259
|
-
this.options = e, this.plugins = e.plugins ?? [], this.topNavigation = e.topNavigation ?? [], this.sidebars = e.sidebars ?? {}, this.navigationPlugins = this.plugins.filter(
|
|
1260
|
+
this.options = e, this.plugins = e.plugins ?? [], this.topNavigation = e.topNavigation ?? [], this.sidebars = e.sidebars ?? {}, this.navigationPlugins = this.plugins.filter(sr), this.authentication = e.authentication, this.meta = e.metadata, this.page = e.page;
|
|
1260
1261
|
}
|
|
1261
1262
|
}
|
|
1262
1263
|
function _r({ error: t, resetErrorBoundary: e }) {
|
|
@@ -1272,7 +1273,7 @@ const nt = {
|
|
|
1272
1273
|
}) => (Pt({
|
|
1273
1274
|
queryFn: async () => (await e.initialize(), !0),
|
|
1274
1275
|
queryKey: ["zudoku-initialize"]
|
|
1275
|
-
}), /* @__PURE__ */ s.jsx(
|
|
1276
|
+
}), /* @__PURE__ */ s.jsx(kt.Provider, { value: e, children: t })), at = Ke(
|
|
1276
1277
|
({ children: t, ...e }) => {
|
|
1277
1278
|
var f, h;
|
|
1278
1279
|
const r = te(
|
|
@@ -1281,10 +1282,10 @@ const nt = {
|
|
|
1281
1282
|
), n = te(() => {
|
|
1282
1283
|
var v;
|
|
1283
1284
|
return {
|
|
1284
|
-
...(e.plugins ?? []).filter(
|
|
1285
|
+
...(e.plugins ?? []).filter(ir).flatMap(
|
|
1285
1286
|
(m) => m.getMdxComponents ? [m.getMdxComponents()] : []
|
|
1286
1287
|
).reduce(
|
|
1287
|
-
(m,
|
|
1288
|
+
(m, k) => ({ ...m, ...k }),
|
|
1288
1289
|
{}
|
|
1289
1290
|
),
|
|
1290
1291
|
...Wt,
|
|
@@ -1294,43 +1295,43 @@ const nt = {
|
|
|
1294
1295
|
() => o ? { stagger: !0 } : { stagger: a },
|
|
1295
1296
|
[a, o]
|
|
1296
1297
|
), d = ue();
|
|
1297
|
-
|
|
1298
|
+
I(() => {
|
|
1298
1299
|
o || i(!0);
|
|
1299
1300
|
}, [o, d.location]);
|
|
1300
|
-
const [c] = L(() => new Gr(e)), g = (h = e.plugins) == null ? void 0 : h.filter(
|
|
1301
|
+
const [c] = L(() => new Gr(e)), g = (h = e.plugins) == null ? void 0 : h.filter(or).map((x, v) => {
|
|
1301
1302
|
var m;
|
|
1302
1303
|
return /* @__PURE__ */ s.jsx(Et, { children: (m = x.getHead) == null ? void 0 : m.call(x) }, v);
|
|
1303
1304
|
});
|
|
1304
1305
|
return /* @__PURE__ */ s.jsxs(s.Fragment, { children: [
|
|
1305
1306
|
/* @__PURE__ */ s.jsx(oe, { children: g }),
|
|
1306
|
-
/* @__PURE__ */ s.jsx(ie.Provider, { value: u, children: /* @__PURE__ */ s.jsx(es, { context: c, children: /* @__PURE__ */ s.jsx(Yt, { components: n, children: /* @__PURE__ */ s.jsx(
|
|
1307
|
+
/* @__PURE__ */ s.jsx(ie.Provider, { value: u, children: /* @__PURE__ */ s.jsx(es, { context: c, children: /* @__PURE__ */ s.jsx(Yt, { components: n, children: /* @__PURE__ */ s.jsx(yr, { attribute: "class", disableTransitionOnChange: !0, children: /* @__PURE__ */ s.jsx(Jr, { value: r, children: /* @__PURE__ */ s.jsx(qt, { slotlets: e.slotlets, children: /* @__PURE__ */ s.jsx(Jt, { children: t ?? /* @__PURE__ */ s.jsx(ce, {}) }) }) }) }) }) }) })
|
|
1307
1308
|
] });
|
|
1308
1309
|
}
|
|
1309
1310
|
);
|
|
1310
1311
|
at.displayName = "ZudokoInner";
|
|
1311
1312
|
const it = (t) => /* @__PURE__ */ s.jsx(Vr, { FallbackComponent: _r, children: /* @__PURE__ */ s.jsx(at, { ...t }) });
|
|
1312
1313
|
it.displayName = "Zudoku";
|
|
1313
|
-
const Ss = Vt,
|
|
1314
|
+
const Ss = Vt, Ns = Kr, Ds = Tt, Ms = Mr, Os = Er, As = qr, Es = Dr, qs = oe, Ts = A, Is = z, Qs = Ct, Rs = St, Fs = it, Bs = Zr, Hs = Qt, zs = er, Ls = Ge, Ks = ge, $s = It, Us = de;
|
|
1314
1315
|
export {
|
|
1315
|
-
|
|
1316
|
-
|
|
1317
|
-
|
|
1318
|
-
|
|
1316
|
+
Os as Bootstrap,
|
|
1317
|
+
As as BootstrapStatic,
|
|
1318
|
+
$s as Button,
|
|
1319
|
+
Rs as CACHE_KEYS,
|
|
1319
1320
|
Hs as Callout,
|
|
1320
|
-
|
|
1321
|
-
|
|
1322
|
-
|
|
1323
|
-
|
|
1321
|
+
Ks as ClientOnly,
|
|
1322
|
+
qs as Head,
|
|
1323
|
+
Ns as Layout,
|
|
1324
|
+
Us as Link,
|
|
1324
1325
|
zs as Markdown,
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
|
|
1328
|
-
|
|
1329
|
-
|
|
1330
|
-
|
|
1326
|
+
Es as RouteGuard,
|
|
1327
|
+
Ds as RouterError,
|
|
1328
|
+
Ms as ServerError,
|
|
1329
|
+
Ls as Spinner,
|
|
1330
|
+
Bs as StatusPage,
|
|
1331
|
+
Fs as Zudoku,
|
|
1331
1332
|
Is as useAuth,
|
|
1332
|
-
|
|
1333
|
+
Qs as useCache,
|
|
1333
1334
|
Ss as useMDXComponents,
|
|
1334
|
-
|
|
1335
|
+
Ts as useZudoku
|
|
1335
1336
|
};
|
|
1336
1337
|
//# sourceMappingURL=zudoku.components.js.map
|