zudoku 0.52.2 → 0.53.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/app/demo.js +2 -2
- package/dist/app/demo.js.map +1 -1
- package/dist/app/main.js +4 -4
- package/dist/app/standalone.js +3 -3
- package/dist/app/standalone.js.map +1 -1
- package/dist/config/validators/validate.d.ts +2 -2
- package/dist/config/validators/validate.js +3 -3
- package/dist/config/validators/validate.js.map +1 -1
- package/dist/flat-config.d.ts +325 -0
- package/dist/lib/components/Banner.js +1 -1
- package/dist/lib/components/Banner.js.map +1 -1
- package/dist/lib/components/Footer.js +1 -1
- package/dist/lib/components/Footer.js.map +1 -1
- package/dist/lib/components/Header.js +10 -10
- package/dist/lib/components/Header.js.map +1 -1
- package/dist/lib/components/Main.js +1 -1
- package/dist/lib/components/MobileTopNavigation.js +1 -1
- package/dist/lib/components/navigation/NavigationWrapper.js +1 -1
- package/dist/lib/core/ZudokuContext.d.ts +4 -4
- package/dist/lib/core/ZudokuContext.js +2 -2
- package/dist/vite/build.js +1 -1
- package/dist/vite/dev-server.js +1 -1
- package/lib/{MdxPage-Glqk-5sb.js → MdxPage-swXPJ0gf.js} +2 -2
- package/lib/{MdxPage-Glqk-5sb.js.map → MdxPage-swXPJ0gf.js.map} +1 -1
- package/lib/{OasProvider-Cks7Ky_-.js → OasProvider-CDAM3TB1.js} +2 -2
- package/lib/{OasProvider-Cks7Ky_-.js.map → OasProvider-CDAM3TB1.js.map} +1 -1
- package/lib/{OperationList-BP3gUFCx.js → OperationList-C9Hb9ql8.js} +5 -5
- package/lib/{OperationList-BP3gUFCx.js.map → OperationList-C9Hb9ql8.js.map} +1 -1
- package/lib/{Pagination-D2xTtsFG.js → Pagination-VGlgeCmS.js} +2 -2
- package/lib/{Pagination-D2xTtsFG.js.map → Pagination-VGlgeCmS.js.map} +1 -1
- package/lib/{SchemaList-BQOuyEO7.js → SchemaList-BAbh1BXO.js} +3 -3
- package/lib/{SchemaList-BQOuyEO7.js.map → SchemaList-BAbh1BXO.js.map} +1 -1
- package/lib/{SchemaView-C6fqo8Th.js → SchemaView-C2Io712T.js} +3 -3
- package/lib/{SchemaView-C6fqo8Th.js.map → SchemaView-C2Io712T.js.map} +1 -1
- package/lib/{SignUp-M9Jz4SXJ.js → SignUp-5RUdVhnq.js} +2 -2
- package/lib/{SignUp-M9Jz4SXJ.js.map → SignUp-5RUdVhnq.js.map} +1 -1
- package/lib/{circular-BNp-4wdn.js → circular-B42RaanD.js} +2 -2
- package/lib/{circular-BNp-4wdn.js.map → circular-B42RaanD.js.map} +1 -1
- package/lib/{createServer-D7OPYwXA.js → createServer-BKFsRuuk.js} +3 -3
- package/lib/{createServer-D7OPYwXA.js.map → createServer-BKFsRuuk.js.map} +1 -1
- package/lib/{errors-C473PjdR.js → errors-CF2X_x5o.js} +3 -3
- package/lib/{errors-C473PjdR.js.map → errors-CF2X_x5o.js.map} +1 -1
- package/lib/{index-BLRAtPoq.js → index-B6Re5_cx.js} +7 -7
- package/lib/{index-BLRAtPoq.js.map → index-B6Re5_cx.js.map} +1 -1
- package/lib/{index-Chtnw-sn.js → index-CLy1XyH0.js} +13 -13
- package/lib/{index-Chtnw-sn.js.map → index-CLy1XyH0.js.map} +1 -1
- package/lib/zudoku.auth-azureb2c.js +1 -1
- package/lib/zudoku.auth-clerk.js +1 -1
- package/lib/zudoku.auth-openid.js +1 -1
- package/lib/zudoku.components.js +1 -1
- package/lib/zudoku.plugin-api-catalog.js +1 -1
- package/lib/zudoku.plugin-markdown.js +1 -1
- package/lib/zudoku.plugin-openapi.js +1 -1
- package/package.json +1 -1
- package/src/app/demo.tsx +2 -2
- package/src/app/main.tsx +4 -4
- package/src/app/standalone.tsx +3 -3
- package/src/lib/components/Banner.tsx +1 -1
- package/src/lib/components/Footer.tsx +1 -1
- package/src/lib/components/Header.tsx +15 -17
- package/src/lib/components/Main.tsx +1 -1
- package/src/lib/components/MobileTopNavigation.tsx +2 -2
- package/src/lib/components/navigation/NavigationWrapper.tsx +1 -1
- package/src/lib/core/ZudokuContext.ts +5 -5
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { j as o } from "./jsx-runtime-C5mzlN2N.js";
|
|
2
2
|
import { LogOutIcon as n } from "lucide-react";
|
|
3
|
-
import { S as s, a as u, b as i } from "./SignUp-
|
|
3
|
+
import { S as s, a as u, b as i } from "./SignUp-5RUdVhnq.js";
|
|
4
4
|
import { c as l, j as c } from "./hook-Bd0yS8M0.js";
|
|
5
5
|
import { N as h } from "./chunk-DQRVZFIR-DHK7_Ilc.js";
|
|
6
|
-
import { u as m } from "./index-
|
|
6
|
+
import { u as m } from "./index-CLy1XyH0.js";
|
|
7
7
|
import { Z as p } from "./invariant-DAFpPywt.js";
|
|
8
8
|
class C {
|
|
9
9
|
getRoutes() {
|
|
@@ -75,4 +75,4 @@ export {
|
|
|
75
75
|
w as O,
|
|
76
76
|
E as a
|
|
77
77
|
};
|
|
78
|
-
//# sourceMappingURL=errors-
|
|
78
|
+
//# sourceMappingURL=errors-CF2X_x5o.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"errors-
|
|
1
|
+
{"version":3,"file":"errors-CF2X_x5o.js","sources":["../src/lib/authentication/AuthenticationPlugin.tsx","../src/lib/util/url.ts","../src/lib/authentication/components/CallbackHandler.tsx","../src/lib/authentication/errors.ts"],"sourcesContent":["import { LogOutIcon } from \"lucide-react\";\nimport {\n type CommonPlugin,\n type NavigationPlugin,\n type ProfileMenuPlugin,\n} from \"../core/plugins.js\";\nimport { SignIn } from \"./components/SignIn.js\";\nimport { SignOut } from \"./components/SignOut.js\";\nimport { SignUp } from \"./components/SignUp.js\";\n\ntype PluginInterface = NavigationPlugin & CommonPlugin & ProfileMenuPlugin;\n\nexport class CoreAuthenticationPlugin implements PluginInterface {\n getRoutes() {\n return [\n {\n path: \"/signout\",\n element: <SignOut />,\n },\n {\n path: \"/signin\",\n element: <SignIn />,\n },\n {\n path: \"/signup\",\n element: <SignUp />,\n },\n ];\n }\n\n getProfileMenuItems() {\n return [\n {\n label: \"Logout\",\n path: \"/signout\",\n category: \"bottom\",\n icon: LogOutIcon,\n } as const,\n ];\n }\n}\n","/**\n * Normalizes a redirect URL by removing the origin and optionally the root path\n */\nexport function normalizeRedirectUrl(\n redirectTo: string,\n origin: string,\n basePath: string = \"/\",\n): string {\n if (!redirectTo.startsWith(origin)) {\n return redirectTo;\n }\n\n if (basePath !== \"/\" && redirectTo.startsWith(origin + basePath)) {\n return redirectTo.slice(origin.length + basePath.length);\n }\n\n return redirectTo.slice(origin.length);\n}\n","import { useSuspenseQuery } from \"@tanstack/react-query\";\nimport { Navigate } from \"react-router\";\nimport { useZudoku } from \"zudoku/components\";\nimport { ZudokuError } from \"../../util/invariant.js\";\nimport { joinUrl } from \"../../util/joinUrl.js\";\nimport { normalizeRedirectUrl } from \"../../util/url.js\";\n\nexport function CallbackHandler({\n handleCallback,\n}: {\n handleCallback: () => Promise<string>;\n}) {\n const { options } = useZudoku();\n const executeCallback = useSuspenseQuery({\n retry: false,\n queryKey: [\"oauth-callback\"],\n queryFn: async () => {\n try {\n return joinUrl(\n normalizeRedirectUrl(\n await handleCallback(),\n window.location.origin,\n options.basePath,\n ),\n );\n } catch (error) {\n throw new ZudokuError(\"Could not validate user\", {\n cause: error,\n title: \"Authentication Error\",\n developerHint:\n \"Check the configuration of your authorization provider and ensure all settings such as the callback URL are configured correctly.\",\n });\n }\n },\n });\n\n return <Navigate to={executeCallback.data} replace />;\n}\n","export class AuthorizationError extends Error {}\n\ninterface OAuthError {\n readonly error: string;\n readonly error_description?: string;\n readonly error_uri?: string;\n readonly algs?: string;\n readonly scope?: string;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n readonly [parameter: string]: any | undefined;\n}\n\nexport class OAuthAuthorizationError extends AuthorizationError {\n constructor(\n message: string,\n public error: OAuthError,\n options?: ErrorOptions,\n ) {\n super(message, options);\n }\n}\n"],"names":["CoreAuthenticationPlugin","SignOut","SignIn","SignUp","LogOutIcon","normalizeRedirectUrl","redirectTo","origin","basePath","CallbackHandler","handleCallback","options","useZudoku","executeCallback","useSuspenseQuery","joinUrl","error","ZudokuError","Navigate","AuthorizationError","OAuthAuthorizationError","message"],"mappings":";;;;;;;AAYO,MAAMA,EAAoD;AAAA,EAC/D,YAAY;AACH,WAAA;AAAA,MACL;AAAA,QACE,MAAM;AAAA,QACN,+BAAUC,GAAQ,CAAA,CAAA;AAAA,MACpB;AAAA,MACA;AAAA,QACE,MAAM;AAAA,QACN,+BAAUC,GAAO,CAAA,CAAA;AAAA,MACnB;AAAA,MACA;AAAA,QACE,MAAM;AAAA,QACN,+BAAUC,GAAO,CAAA,CAAA;AAAA,MAAA;AAAA,IAErB;AAAA,EAAA;AAAA,EAGF,sBAAsB;AACb,WAAA;AAAA,MACL;AAAA,QACE,OAAO;AAAA,QACP,MAAM;AAAA,QACN,UAAU;AAAA,QACV,MAAMC;AAAA,MAAA;AAAA,IAEV;AAAA,EAAA;AAEJ;ACrCO,SAASC,EACdC,GACAC,GACAC,IAAmB,KACX;AACR,SAAKF,EAAW,WAAWC,CAAM,IAI7BC,MAAa,OAAOF,EAAW,WAAWC,IAASC,CAAQ,IACtDF,EAAW,MAAMC,EAAO,SAASC,EAAS,MAAM,IAGlDF,EAAW,MAAMC,EAAO,MAAM,IAP5BD;AAQX;ACVO,SAASG,EAAgB;AAAA,EAC9B,gBAAAC;AACF,GAEG;AACK,QAAA,EAAE,SAAAC,EAAQ,IAAIC,EAAU,GACxBC,IAAkBC,EAAiB;AAAA,IACvC,OAAO;AAAA,IACP,UAAU,CAAC,gBAAgB;AAAA,IAC3B,SAAS,YAAY;AACf,UAAA;AACK,eAAAC;AAAA,UACLV;AAAA,YACE,MAAMK,EAAe;AAAA,YACrB,OAAO,SAAS;AAAA,YAChBC,EAAQ;AAAA,UAAA;AAAA,QAEZ;AAAA,eACOK,GAAO;AACR,cAAA,IAAIC,EAAY,2BAA2B;AAAA,UAC/C,OAAOD;AAAA,UACP,OAAO;AAAA,UACP,eACE;AAAA,QAAA,CACH;AAAA,MAAA;AAAA,IACH;AAAA,EACF,CACD;AAED,+BAAQE,GAAS,EAAA,IAAIL,EAAgB,MAAM,SAAO,IAAC;AACrD;ACrCO,MAAMM,UAA2B,MAAM;AAAC;AAYxC,MAAMC,UAAgCD,EAAmB;AAAA,EAC9D,YACEE,GACOL,GACPL,GACA;AACA,UAAMU,GAASV,CAAO,GAHf,KAAA,QAAAK;AAAA,EAAA;AAKX;"}
|
|
@@ -8,7 +8,7 @@ import * as w from "react";
|
|
|
8
8
|
import { createContext as jt, use as Kn, useRef as L, useEffect as z, useMemo as Nt, useState as k, useCallback as wt, Fragment as K, useLayoutEffect as es, useTransition as ts, useContext as ns } from "react";
|
|
9
9
|
import { VisuallyHidden as ss } from "@radix-ui/react-visually-hidden";
|
|
10
10
|
import { D as Ee, a as ke, b as De, d as Ct, f as St, e as rs } from "./Dialog-CiIdyz6a.js";
|
|
11
|
-
import { S as as, a as os } from "./index-
|
|
11
|
+
import { S as as, a as os } from "./index-CLy1XyH0.js";
|
|
12
12
|
import { A as is, a as cs, b as ls, u as ds } from "./Alert-CT_ViLrJ.js";
|
|
13
13
|
import { u as oe, a as ze, C as F, b as us, F as ms } from "./index.esm-Cp4wkyud.js";
|
|
14
14
|
import { B as I } from "./Button-BE9IVkWV.js";
|
|
@@ -43,7 +43,7 @@ class Os {
|
|
|
43
43
|
constructor(t) {
|
|
44
44
|
this.config = t;
|
|
45
45
|
}
|
|
46
|
-
#e = async () => (Ne || (Ne = import("./createServer-
|
|
46
|
+
#e = async () => (Ne || (Ne = import("./createServer-BKFsRuuk.js").then(
|
|
47
47
|
(t) => t.createServer(this.config)
|
|
48
48
|
)), Ne);
|
|
49
49
|
#t = async (t) => this.config.server ? fetch(this.config.server, t) : (await this.#e()).fetch("http://localhost/graphql", t);
|
|
@@ -3191,7 +3191,7 @@ const na = (e) => Object.entries({
|
|
|
3191
3191
|
}, ft = (e) => ({
|
|
3192
3192
|
path: e.routePath,
|
|
3193
3193
|
async lazy() {
|
|
3194
|
-
const { OasProvider: t } = await import("./OasProvider-
|
|
3194
|
+
const { OasProvider: t } = await import("./OasProvider-CDAM3TB1.js");
|
|
3195
3195
|
return {
|
|
3196
3196
|
element: /* @__PURE__ */ n.jsx(
|
|
3197
3197
|
t,
|
|
@@ -3212,7 +3212,7 @@ const na = (e) => Object.entries({
|
|
|
3212
3212
|
}) => ({
|
|
3213
3213
|
path: e,
|
|
3214
3214
|
async lazy() {
|
|
3215
|
-
const { OperationList: a } = await import("./OperationList-
|
|
3215
|
+
const { OperationList: a } = await import("./OperationList-C9Hb9ql8.js");
|
|
3216
3216
|
return { element: /* @__PURE__ */ n.jsx(a, { tag: t, untagged: s }) };
|
|
3217
3217
|
}
|
|
3218
3218
|
}), ha = ({
|
|
@@ -3234,7 +3234,7 @@ const na = (e) => Object.entries({
|
|
|
3234
3234
|
}, fa = ({ path: e }) => ({
|
|
3235
3235
|
path: e,
|
|
3236
3236
|
async lazy() {
|
|
3237
|
-
const { OperationList: t } = await import("./OperationList-
|
|
3237
|
+
const { OperationList: t } = await import("./OperationList-C9Hb9ql8.js");
|
|
3238
3238
|
return {
|
|
3239
3239
|
element: /* @__PURE__ */ n.jsx(
|
|
3240
3240
|
ha,
|
|
@@ -3255,7 +3255,7 @@ const na = (e) => Object.entries({
|
|
|
3255
3255
|
{
|
|
3256
3256
|
path: E(e, "~schemas"),
|
|
3257
3257
|
lazy: async () => {
|
|
3258
|
-
const { SchemaList: t } = await import("./SchemaList-
|
|
3258
|
+
const { SchemaList: t } = await import("./SchemaList-BAbh1BXO.js");
|
|
3259
3259
|
return { element: /* @__PURE__ */ n.jsx(t, {}) };
|
|
3260
3260
|
}
|
|
3261
3261
|
}
|
|
@@ -3466,4 +3466,4 @@ export {
|
|
|
3466
3466
|
Ps as y,
|
|
3467
3467
|
Ga as z
|
|
3468
3468
|
};
|
|
3469
|
-
//# sourceMappingURL=index-
|
|
3469
|
+
//# sourceMappingURL=index-B6Re5_cx.js.map
|