zudoku 0.3.0-dev.55 → 0.3.0-dev.56
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/config/validators/validate.d.ts +12 -12
- package/dist/lib/components/DeveloperHint.d.ts +5 -0
- package/dist/lib/components/DeveloperHint.js +10 -0
- package/dist/lib/components/DeveloperHint.js.map +1 -0
- package/dist/lib/components/NotFoundPage.js +2 -2
- package/dist/lib/components/NotFoundPage.js.map +1 -1
- package/dist/lib/plugins/api-keys/ProtectedRoute.d.ts +1 -0
- package/dist/lib/plugins/api-keys/ProtectedRoute.js +14 -0
- package/dist/lib/plugins/api-keys/ProtectedRoute.js.map +1 -0
- package/dist/lib/plugins/api-keys/index.js +2 -12
- package/dist/lib/plugins/api-keys/index.js.map +1 -1
- package/dist/lib/plugins/openapi/OperationList.js +2 -2
- package/dist/lib/plugins/openapi/OperationList.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/PlaygroundDialog.js +3 -3
- package/dist/lib/plugins/openapi/playground/PlaygroundDialog.js.map +1 -1
- package/lib/AnchorLink-GNsUeGSX.js +705 -0
- package/lib/{AnchorLink-BaXHjhF-.js.map → AnchorLink-GNsUeGSX.js.map} +1 -1
- package/lib/Button-DpHMZvVs.js +4571 -0
- package/lib/Button-DpHMZvVs.js.map +1 -0
- package/lib/DevPortalProvider-Do9oJqme.js +1081 -0
- package/lib/{DevPortalProvider-GjdO0Xr-.js.map → DevPortalProvider-Do9oJqme.js.map} +1 -1
- package/lib/Markdown-DtLFdxD1.js +15031 -0
- package/lib/Markdown-DtLFdxD1.js.map +1 -0
- package/lib/MdxPage-CbwYRKf5.js +190 -0
- package/lib/{MdxPage-Dlujuj-J.js.map → MdxPage-CbwYRKf5.js.map} +1 -1
- package/lib/OperationList-DpR4KzIJ.js +5570 -0
- package/lib/OperationList-DpR4KzIJ.js.map +1 -0
- package/lib/Route-C1LyvITr.js +13 -0
- package/lib/{Route-CR6TEwVC.js.map → Route-C1LyvITr.js.map} +1 -1
- package/lib/Spinner-Bhbs5aPI.js +182 -0
- package/lib/Spinner-Bhbs5aPI.js.map +1 -0
- package/lib/_commonjsHelpers-BVfed4GL.js +29 -0
- package/lib/_commonjsHelpers-BVfed4GL.js.map +1 -0
- package/lib/assets/index-BPdJm2ty.js +4765 -0
- package/lib/assets/{index-CpIig0AX.js.map → index-BPdJm2ty.js.map} +1 -1
- package/lib/assets/worker-BjPv-hjP.js +14897 -0
- package/lib/assets/{worker-B5k2aBV9.js.map → worker-BjPv-hjP.js.map} +1 -1
- package/lib/context-_fYfJFgk.js +14 -0
- package/lib/{context-BoN_3uxi.js.map → context-_fYfJFgk.js.map} +1 -1
- package/lib/hook-Biq3zYel.js +92 -0
- package/lib/hook-Biq3zYel.js.map +1 -0
- package/lib/{index-Dih8IAqw.js → index-DZ910ttL.js} +83 -103
- package/lib/{index-Dih8IAqw.js.map → index-DZ910ttL.js.map} +1 -1
- package/lib/index-gsAuUwQh.js +418 -0
- package/lib/index-gsAuUwQh.js.map +1 -0
- package/lib/index-pI9JkN46.js +4765 -0
- package/lib/{index-Bn03IPZt.js.map → index-pI9JkN46.js.map} +1 -1
- package/lib/jsx-runtime-CJZJivg2.js +1526 -0
- package/lib/{jsx-runtime-DvZ6OKMM.js.map → jsx-runtime-CJZJivg2.js.map} +1 -1
- package/lib/prism-bash.min-DadFsM4Z.js +7 -0
- package/lib/{prism-bash.min-BtBk0onv.js.map → prism-bash.min-DadFsM4Z.js.map} +1 -1
- package/lib/prism-csharp.min-Yizuc34Y.js +35 -0
- package/lib/{prism-csharp.min-Cv7D49bv.js.map → prism-csharp.min-Yizuc34Y.js.map} +1 -1
- package/lib/prism-java.min-d5iT_mOd.js +7 -0
- package/lib/{prism-java.min-tNK-JX6x.js.map → prism-java.min-d5iT_mOd.js.map} +1 -1
- package/lib/prism-json.min-B1GJqK1k.js +2 -0
- package/lib/{prism-json.min-Cdtv-CME.js.map → prism-json.min-B1GJqK1k.js.map} +1 -1
- package/lib/prism-markup-templating-DZrrEs0A.js +62 -0
- package/lib/{prism-markup-templating-iotg2sCU.js.map → prism-markup-templating-DZrrEs0A.js.map} +1 -1
- package/lib/prism-objectivec.min-BXSWqpJJ.js +2 -0
- package/lib/{prism-objectivec.min-CY4WGixz.js.map → prism-objectivec.min-BXSWqpJJ.js.map} +1 -1
- package/lib/prism-php.min-o7FpoMP_.js +11 -0
- package/lib/{prism-php.min-T6sIVgED.js.map → prism-php.min-o7FpoMP_.js.map} +1 -1
- package/lib/prism-ruby.min-C7LwcKyz.js +10 -0
- package/lib/{prism-ruby.min-B-2KAa4y.js.map → prism-ruby.min-C7LwcKyz.js.map} +1 -1
- package/lib/router-CBw2vqJE.js +2973 -0
- package/lib/{router-ButO1QyY.js.map → router-CBw2vqJE.js.map} +1 -1
- package/lib/slugify-CiPVjteN.js +28 -0
- package/lib/{slugify-CmS97Vy8.js.map → slugify-CiPVjteN.js.map} +1 -1
- package/lib/state-DKdaQzvh.js +288 -0
- package/lib/{state-CmGfNKhR.js.map → state-DKdaQzvh.js.map} +1 -1
- package/lib/urql-DMlBWUKL.js +1592 -0
- package/lib/{urql-DtVKPBx_.js.map → urql-DMlBWUKL.js.map} +1 -1
- package/lib/util-_jwUlTBU.js +41 -0
- package/lib/{util-B5KX4h4M.js.map → util-_jwUlTBU.js.map} +1 -1
- package/lib/zudoku.auth-auth0.js +18 -24
- package/lib/zudoku.auth-auth0.js.map +1 -1
- package/lib/zudoku.auth-clerk.js +34 -43
- package/lib/zudoku.auth-clerk.js.map +1 -1
- package/lib/zudoku.auth-openid.js +734 -1121
- package/lib/zudoku.auth-openid.js.map +1 -1
- package/lib/zudoku.components.js +822 -1076
- package/lib/zudoku.components.js.map +1 -1
- package/lib/zudoku.openapi-worker.js +9691 -13786
- package/lib/zudoku.openapi-worker.js.map +1 -1
- package/lib/zudoku.plugin-api-keys.js +171 -208
- package/lib/zudoku.plugin-api-keys.js.map +1 -1
- package/lib/zudoku.plugin-markdown.js +33 -41
- package/lib/zudoku.plugin-markdown.js.map +1 -1
- package/lib/zudoku.plugin-openapi.js +6 -6
- package/lib/zudoku.plugin-redirect.js +8 -10
- package/lib/zudoku.plugin-redirect.js.map +1 -1
- package/package.json +1 -1
- package/src/lib/components/DeveloperHint.tsx +25 -0
- package/src/lib/components/NotFoundPage.tsx +8 -14
- package/src/lib/plugins/api-keys/ProtectedRoute.tsx +29 -0
- package/src/lib/plugins/api-keys/index.tsx +2 -21
- package/src/lib/plugins/openapi/OperationList.tsx +5 -8
- package/src/lib/plugins/openapi/playground/PlaygroundDialog.tsx +3 -5
- package/lib/AnchorLink-BaXHjhF-.js +0 -989
- package/lib/Combination-BfufJFkX.js +0 -1365
- package/lib/Combination-BfufJFkX.js.map +0 -1
- package/lib/DevPortalProvider-GjdO0Xr-.js +0 -1610
- package/lib/Markdown-B8nPVql1.js +0 -19708
- package/lib/Markdown-B8nPVql1.js.map +0 -1
- package/lib/MdxPage-Dlujuj-J.js +0 -223
- package/lib/OperationList-krPgt6sE.js +0 -8041
- package/lib/OperationList-krPgt6sE.js.map +0 -1
- package/lib/Playground-DOHxca0P.js +0 -539
- package/lib/Playground-DOHxca0P.js.map +0 -1
- package/lib/Route-CR6TEwVC.js +0 -13
- package/lib/Select-Boi_pe3L.js +0 -5298
- package/lib/Select-Boi_pe3L.js.map +0 -1
- package/lib/Spinner-oU0QJmi_.js +0 -16
- package/lib/Spinner-oU0QJmi_.js.map +0 -1
- package/lib/_commonjsHelpers-BxmBWJD2.js +0 -34
- package/lib/_commonjsHelpers-BxmBWJD2.js.map +0 -1
- package/lib/assets/index-CpIig0AX.js +0 -6341
- package/lib/assets/worker-B5k2aBV9.js +0 -18921
- package/lib/context-BoN_3uxi.js +0 -17
- package/lib/hook-CIuFuyBT.js +0 -90
- package/lib/hook-CIuFuyBT.js.map +0 -1
- package/lib/index-BL1P4Gqq.js +0 -280
- package/lib/index-BL1P4Gqq.js.map +0 -1
- package/lib/index-Bn03IPZt.js +0 -6341
- package/lib/index-FprhHF51.js +0 -253
- package/lib/index-FprhHF51.js.map +0 -1
- package/lib/jsx-runtime-DvZ6OKMM.js +0 -2110
- package/lib/mutation-DWY9x2Uc.js +0 -250
- package/lib/mutation-DWY9x2Uc.js.map +0 -1
- package/lib/prism-bash.min-BtBk0onv.js +0 -7
- package/lib/prism-csharp.min-Cv7D49bv.js +0 -30
- package/lib/prism-java.min-tNK-JX6x.js +0 -7
- package/lib/prism-json.min-Cdtv-CME.js +0 -2
- package/lib/prism-markup-templating-iotg2sCU.js +0 -94
- package/lib/prism-objectivec.min-CY4WGixz.js +0 -2
- package/lib/prism-php.min-T6sIVgED.js +0 -11
- package/lib/prism-ruby.min-B-2KAa4y.js +0 -8
- package/lib/router-ButO1QyY.js +0 -4062
- package/lib/slugify-CmS97Vy8.js +0 -50
- package/lib/state-CmGfNKhR.js +0 -436
- package/lib/urql-DtVKPBx_.js +0 -2567
- package/lib/util-B5KX4h4M.js +0 -55
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { createContext as e, useContext as r } from "react";
|
|
2
|
+
const t = e(
|
|
3
|
+
void 0
|
|
4
|
+
), n = t.Provider, i = () => {
|
|
5
|
+
const o = r(t);
|
|
6
|
+
if (!o)
|
|
7
|
+
throw new Error("useOasConfig must be used within a OasConfigProvider");
|
|
8
|
+
return o.config;
|
|
9
|
+
};
|
|
10
|
+
export {
|
|
11
|
+
n as O,
|
|
12
|
+
i as u
|
|
13
|
+
};
|
|
14
|
+
//# sourceMappingURL=context-_fYfJFgk.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"context-
|
|
1
|
+
{"version":3,"file":"context-_fYfJFgk.js","sources":["../src/lib/plugins/openapi/context.tsx"],"sourcesContent":["import { createContext, useContext } from \"react\";\nimport { OasPluginConfig } from \"./interfaces.js\";\n\nconst OasContext = createContext<{ config: OasPluginConfig } | undefined>(\n undefined,\n);\n\nexport const OasConfigProvider = OasContext.Provider;\n\nexport const useOasConfig = () => {\n const ctx = useContext(OasContext);\n if (!ctx) {\n throw new Error(\"useOasConfig must be used within a OasConfigProvider\");\n }\n return ctx.config;\n};\n"],"names":["OasContext","createContext","OasConfigProvider","useOasConfig","ctx","useContext"],"mappings":";AAGA,MAAMA,IAAaC;AAAA,EACjB;AACF,GAEaC,IAAoBF,EAAW,UAE/BG,IAAe,MAAM;AAC1B,QAAAC,IAAMC,EAAWL,CAAU;AACjC,MAAI,CAACI;AACG,UAAA,IAAI,MAAM,sDAAsD;AAExE,SAAOA,EAAI;AACb;"}
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
import { b as a, j as t, c as o } from "./jsx-runtime-CJZJivg2.js";
|
|
2
|
+
import { c as i, P as r, g as l, H as c, L as d } from "./Markdown-DtLFdxD1.js";
|
|
3
|
+
import { D as m } from "./index-gsAuUwQh.js";
|
|
4
|
+
import { i as x } from "./router-CBw2vqJE.js";
|
|
5
|
+
import { u } from "./DevPortalProvider-Do9oJqme.js";
|
|
6
|
+
import { u as h } from "./state-DKdaQzvh.js";
|
|
7
|
+
/**
|
|
8
|
+
* @license lucide-react v0.378.0 - ISC
|
|
9
|
+
*
|
|
10
|
+
* This source code is licensed under the ISC license.
|
|
11
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
12
|
+
*/
|
|
13
|
+
const p = i("Unlink", [
|
|
14
|
+
[
|
|
15
|
+
"path",
|
|
16
|
+
{
|
|
17
|
+
d: "m18.84 12.25 1.72-1.71h-.02a5.004 5.004 0 0 0-.12-7.07 5.006 5.006 0 0 0-6.95 0l-1.72 1.71",
|
|
18
|
+
key: "yqzxt4"
|
|
19
|
+
}
|
|
20
|
+
],
|
|
21
|
+
[
|
|
22
|
+
"path",
|
|
23
|
+
{
|
|
24
|
+
d: "m5.17 11.75-1.71 1.71a5.004 5.004 0 0 0 .12 7.07 5.006 5.006 0 0 0 6.95 0l1.71-1.71",
|
|
25
|
+
key: "4qinb0"
|
|
26
|
+
}
|
|
27
|
+
],
|
|
28
|
+
["line", { x1: "8", x2: "8", y1: "2", y2: "5", key: "1041cp" }],
|
|
29
|
+
["line", { x1: "2", x2: "5", y1: "8", y2: "8", key: "14m1p5" }],
|
|
30
|
+
["line", { x1: "16", x2: "16", y1: "19", y2: "22", key: "rzdirn" }],
|
|
31
|
+
["line", { x1: "19", x2: "22", y1: "16", y2: "16", key: "ox905f" }]
|
|
32
|
+
]), g = () => {
|
|
33
|
+
const e = a();
|
|
34
|
+
return /* @__PURE__ */ t.jsxs("div", { className: r + " h-full pt-[--padding-content-top]", children: [
|
|
35
|
+
/* @__PURE__ */ t.jsx(l, { children: "404" }),
|
|
36
|
+
/* @__PURE__ */ t.jsxs(c, { level: 1, className: "flex gap-3.5 items-center", children: [
|
|
37
|
+
"Page not found",
|
|
38
|
+
/* @__PURE__ */ t.jsx(p, { size: 24 })
|
|
39
|
+
] }),
|
|
40
|
+
/* @__PURE__ */ t.jsxs(m, { children: [
|
|
41
|
+
"Start by adding a file at",
|
|
42
|
+
" ",
|
|
43
|
+
/* @__PURE__ */ t.jsxs("code", { children: [
|
|
44
|
+
"{PROJECT_ROOT}",
|
|
45
|
+
"/",
|
|
46
|
+
e["*"],
|
|
47
|
+
".mdx"
|
|
48
|
+
] }),
|
|
49
|
+
" ",
|
|
50
|
+
"and add some content to make this error go away."
|
|
51
|
+
] }),
|
|
52
|
+
/* @__PURE__ */ t.jsx("p", { children: "It seems that the page you are looking for does not exist or may have been moved. Please check the URL for any typos or use the navigation menu to find the correct page." }),
|
|
53
|
+
/* @__PURE__ */ t.jsx(d, { to: "/", children: "Go back home" })
|
|
54
|
+
] });
|
|
55
|
+
};
|
|
56
|
+
function f({ error: e }) {
|
|
57
|
+
const s = (e == null ? void 0 : e.message) ?? "Something went wrong", n = e == null ? void 0 : e.stack;
|
|
58
|
+
return /* @__PURE__ */ t.jsx("div", { className: "flex h-screen max-h-screen min-h-full items-center justify-center bg-primary-background px-4 py-16 lg:px-8", children: /* @__PURE__ */ t.jsxs("div", { className: "mx-auto max-w-[85%] sm:max-w-[50%]", children: [
|
|
59
|
+
/* @__PURE__ */ t.jsx("h1", { className: "text-4xl font-bold tracking-tight text-h1-text sm:text-5xl", children: "Something went wrong" }),
|
|
60
|
+
/* @__PURE__ */ t.jsx("p", { className: "mt-5 text-h1-text", children: s }),
|
|
61
|
+
n ? /* @__PURE__ */ t.jsx("pre", { className: "mt-5 max-h-[400px] w-full overflow-scroll rounded-md border border-input-border bg-input-background p-3 text-property-name-text text-red-700", children: n }) : null
|
|
62
|
+
] }) });
|
|
63
|
+
}
|
|
64
|
+
function E() {
|
|
65
|
+
const e = o();
|
|
66
|
+
return x(e) && e.status === 404 ? /* @__PURE__ */ t.jsx(g, {}) : /* @__PURE__ */ t.jsx(f, { error: e });
|
|
67
|
+
}
|
|
68
|
+
const P = () => {
|
|
69
|
+
const { authentication: e } = u(), s = h(), n = typeof e < "u";
|
|
70
|
+
return {
|
|
71
|
+
isAuthEnabled: n,
|
|
72
|
+
isPending: s.isPending,
|
|
73
|
+
profile: s.profile,
|
|
74
|
+
isAuthenticated: s.profile,
|
|
75
|
+
login: async () => {
|
|
76
|
+
if (!n)
|
|
77
|
+
throw new Error("Authentication is not enabled.");
|
|
78
|
+
await e.login();
|
|
79
|
+
},
|
|
80
|
+
logout: async () => {
|
|
81
|
+
if (!n)
|
|
82
|
+
throw new Error("Authentication is not enabled.");
|
|
83
|
+
await e.logout(), window.location.href = "/";
|
|
84
|
+
}
|
|
85
|
+
};
|
|
86
|
+
};
|
|
87
|
+
export {
|
|
88
|
+
f as E,
|
|
89
|
+
E as R,
|
|
90
|
+
P as u
|
|
91
|
+
};
|
|
92
|
+
//# sourceMappingURL=hook-Biq3zYel.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"hook-Biq3zYel.js","sources":["../../../node_modules/.pnpm/lucide-react@0.378.0_react@18.3.1/node_modules/lucide-react/dist/esm/icons/unlink.js","../src/lib/components/NotFoundPage.tsx","../src/lib/errors/ErrorAlert.tsx","../src/lib/errors/RouterError.tsx","../src/lib/authentication/hook.ts"],"sourcesContent":["/**\n * @license lucide-react v0.378.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst Unlink = createLucideIcon(\"Unlink\", [\n [\n \"path\",\n {\n d: \"m18.84 12.25 1.72-1.71h-.02a5.004 5.004 0 0 0-.12-7.07 5.006 5.006 0 0 0-6.95 0l-1.72 1.71\",\n key: \"yqzxt4\"\n }\n ],\n [\n \"path\",\n {\n d: \"m5.17 11.75-1.71 1.71a5.004 5.004 0 0 0 .12 7.07 5.006 5.006 0 0 0 6.95 0l1.71-1.71\",\n key: \"4qinb0\"\n }\n ],\n [\"line\", { x1: \"8\", x2: \"8\", y1: \"2\", y2: \"5\", key: \"1041cp\" }],\n [\"line\", { x1: \"2\", x2: \"5\", y1: \"8\", y2: \"8\", key: \"14m1p5\" }],\n [\"line\", { x1: \"16\", x2: \"16\", y1: \"19\", y2: \"22\", key: \"rzdirn\" }],\n [\"line\", { x1: \"19\", x2: \"22\", y1: \"16\", y2: \"16\", key: \"ox905f\" }]\n]);\n\nexport { Unlink as default };\n//# sourceMappingURL=unlink.js.map\n","import { UnlinkIcon } from \"lucide-react\";\nimport { Link, useParams } from \"react-router-dom\";\nimport { CategoryHeading } from \"./CategoryHeading.js\";\nimport { DeveloperHint } from \"./DeveloperHint.js\";\nimport { Heading } from \"./Heading.js\";\nimport { ProseClasses } from \"./Markdown.js\";\n\nexport const NotFoundPage = () => {\n const params = useParams();\n\n return (\n <div className={ProseClasses + \" h-full pt-[--padding-content-top]\"}>\n <CategoryHeading>404</CategoryHeading>\n <Heading level={1} className=\"flex gap-3.5 items-center\">\n Page not found\n <UnlinkIcon size={24} />\n </Heading>\n <DeveloperHint>\n Start by adding a file at{\" \"}\n <code>\n {\"{PROJECT_ROOT}\"}/{params[\"*\"]}.mdx\n </code>{\" \"}\n and add some content to make this error go away.\n </DeveloperHint>\n <p>\n It seems that the page you are looking for does not exist or may have\n been moved. Please check the URL for any typos or use the navigation\n menu to find the correct page.\n </p>\n <Link to=\"/\">Go back home</Link>\n </div>\n );\n};\n","// eslint-disable-next-line @typescript-eslint/no-explicit-any\nexport function ErrorAlert({ error }: { error: any }) {\n const message = error?.message ?? \"Something went wrong\";\n const stack = error?.stack;\n\n return (\n <div className=\"flex h-screen max-h-screen min-h-full items-center justify-center bg-primary-background px-4 py-16 lg:px-8\">\n <div className=\"mx-auto max-w-[85%] sm:max-w-[50%]\">\n <h1 className=\"text-4xl font-bold tracking-tight text-h1-text sm:text-5xl\">\n Something went wrong\n </h1>\n <p className=\"mt-5 text-h1-text\">{message}</p>\n {stack ? (\n <pre className=\"mt-5 max-h-[400px] w-full overflow-scroll rounded-md border border-input-border bg-input-background p-3 text-property-name-text text-red-700\">\n {stack}\n </pre>\n ) : null}\n </div>\n </div>\n );\n}\n","import { isRouteErrorResponse, useRouteError } from \"react-router-dom\";\nimport { NotFoundPage } from \"../components/NotFoundPage.js\";\nimport { ErrorAlert } from \"./ErrorAlert.js\";\n\nexport function RouterError() {\n const error = useRouteError();\n\n if (isRouteErrorResponse(error) && error.status === 404) {\n return <NotFoundPage />;\n }\n\n return <ErrorAlert error={error} />;\n}\n","import { useDevPortal } from \"../components/context/DevPortalProvider.js\";\nimport { useAuthState } from \"./state.js\";\n\nexport const useAuth = () => {\n const { authentication } = useDevPortal();\n const authState = useAuthState();\n const isAuthEnabled = typeof authentication !== \"undefined\";\n\n return {\n isAuthEnabled,\n isPending: authState.isPending,\n profile: authState.profile,\n isAuthenticated: authState.profile,\n\n login: async () => {\n if (!isAuthEnabled) {\n throw new Error(\"Authentication is not enabled.\");\n }\n // TODO: Should handle errors/state\n await authentication.login();\n },\n\n logout: async () => {\n if (!isAuthEnabled) {\n throw new Error(\"Authentication is not enabled.\");\n }\n // TODO: Should handle errors/state\n await authentication.logout();\n\n // Redirect to home\n window.location.href = \"/\";\n },\n };\n};\n"],"names":["Unlink","createLucideIcon","NotFoundPage","params","useParams","jsxs","ProseClasses","jsx","CategoryHeading","Heading","UnlinkIcon","DeveloperHint","Link","ErrorAlert","error","message","stack","RouterError","useRouteError","isRouteErrorResponse","useAuth","authentication","useDevPortal","authState","useAuthState","isAuthEnabled"],"mappings":"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","x_google_ignoreList":[0]}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { j as
|
|
2
|
-
import { e as
|
|
3
|
-
import { C as
|
|
4
|
-
import { createClient } from "zudoku/openapi-worker";
|
|
5
|
-
import { m as
|
|
6
|
-
const
|
|
1
|
+
import { j as n, c as k } from "./jsx-runtime-CJZJivg2.js";
|
|
2
|
+
import { e as r, P as o, g as u, H as c, L as p, S as v } from "./Markdown-DtLFdxD1.js";
|
|
3
|
+
import { C as N, c as y, f as F } from "./urql-DMlBWUKL.js";
|
|
4
|
+
import { createClient as S } from "zudoku/openapi-worker";
|
|
5
|
+
import { m as g } from "./router-CBw2vqJE.js";
|
|
6
|
+
const I = {
|
|
7
7
|
get: "text-green-600",
|
|
8
8
|
post: "text-sky-600",
|
|
9
9
|
put: "text-yellow-600",
|
|
@@ -12,8 +12,7 @@ const MethodTextColorMap = {
|
|
|
12
12
|
options: "text-indigo-600",
|
|
13
13
|
head: "text-gray-600",
|
|
14
14
|
trace: "text-gray-600"
|
|
15
|
-
}
|
|
16
|
-
const MethodColorMap = {
|
|
15
|
+
}, h = {
|
|
17
16
|
get: "bg-green-400 dark:bg-green-800",
|
|
18
17
|
post: "bg-sky-400 dark:bg-sky-800",
|
|
19
18
|
put: "bg-yellow-400 dark:bg-yellow-800",
|
|
@@ -22,20 +21,16 @@ const MethodColorMap = {
|
|
|
22
21
|
options: "bg-indigo-400 dark:bg-indigo-600",
|
|
23
22
|
head: "bg-gray-400 dark:bg-gray-600",
|
|
24
23
|
trace: "bg-gray-400 dark:bg-gray-600"
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
}
|
|
36
|
-
);
|
|
37
|
-
};
|
|
38
|
-
const OperationsFragmentFragmentDoc = {
|
|
24
|
+
}, b = ({ method: e }) => /* @__PURE__ */ n.jsx(
|
|
25
|
+
"span",
|
|
26
|
+
{
|
|
27
|
+
className: r(
|
|
28
|
+
"mt-0.5 flex items-center duration-200 transition-opacity text-center uppercase font-mono text-[0.65rem] font-bold rounded text-background dark:text-zinc-50 h-4 px-1",
|
|
29
|
+
h[e]
|
|
30
|
+
),
|
|
31
|
+
children: e
|
|
32
|
+
}
|
|
33
|
+
), x = {
|
|
39
34
|
kind: "Document",
|
|
40
35
|
definitions: [
|
|
41
36
|
{
|
|
@@ -180,8 +175,7 @@ const OperationsFragmentFragmentDoc = {
|
|
|
180
175
|
}
|
|
181
176
|
}
|
|
182
177
|
]
|
|
183
|
-
}
|
|
184
|
-
const GetServerQueryDocument = {
|
|
178
|
+
}, f = {
|
|
185
179
|
kind: "Document",
|
|
186
180
|
definitions: [
|
|
187
181
|
{
|
|
@@ -247,8 +241,7 @@ const GetServerQueryDocument = {
|
|
|
247
241
|
}
|
|
248
242
|
}
|
|
249
243
|
]
|
|
250
|
-
}
|
|
251
|
-
const AllOperationsDocument = {
|
|
244
|
+
}, T = {
|
|
252
245
|
kind: "Document",
|
|
253
246
|
definitions: [
|
|
254
247
|
{
|
|
@@ -492,8 +485,7 @@ const AllOperationsDocument = {
|
|
|
492
485
|
}
|
|
493
486
|
}
|
|
494
487
|
]
|
|
495
|
-
}
|
|
496
|
-
const GetCategoriesDocument = {
|
|
488
|
+
}, O = {
|
|
497
489
|
kind: "Document",
|
|
498
490
|
definitions: [
|
|
499
491
|
{
|
|
@@ -609,29 +601,25 @@ const GetCategoriesDocument = {
|
|
|
609
601
|
}
|
|
610
602
|
}
|
|
611
603
|
]
|
|
604
|
+
}, D = {
|
|
605
|
+
"\n query getServerQuery($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n url\n }\n }\n": f,
|
|
606
|
+
"\n fragment OperationsFragment on OperationItem {\n slug\n summary\n method\n description\n operationId\n contentTypes\n path\n parameters {\n name\n in\n description\n required\n schema\n style\n examples {\n name\n description\n externalValue\n value\n summary\n }\n }\n requestBody {\n content {\n mediaType\n encoding {\n name\n }\n schema\n }\n description\n required\n }\n responses {\n statusCode\n links\n description\n content {\n mediaType\n encoding {\n name\n }\n schema\n }\n }\n }\n": x,
|
|
607
|
+
"\n query AllOperations($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n description\n title\n url\n version\n tags {\n name\n description\n operations {\n slug\n ...OperationsFragment\n }\n }\n }\n }\n": T,
|
|
608
|
+
"\n query GetCategories($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n tags {\n __typename\n name\n operations {\n __typename\n slug\n deprecated\n method\n summary\n operationId\n path\n }\n }\n }\n }\n": O
|
|
612
609
|
};
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
"\n fragment OperationsFragment on OperationItem {\n slug\n summary\n method\n description\n operationId\n contentTypes\n path\n parameters {\n name\n in\n description\n required\n schema\n style\n examples {\n name\n description\n externalValue\n value\n summary\n }\n }\n requestBody {\n content {\n mediaType\n encoding {\n name\n }\n schema\n }\n description\n required\n }\n responses {\n statusCode\n links\n description\n content {\n mediaType\n encoding {\n name\n }\n schema\n }\n }\n }\n": OperationsFragmentFragmentDoc,
|
|
616
|
-
"\n query AllOperations($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n description\n title\n url\n version\n tags {\n name\n description\n operations {\n slug\n ...OperationsFragment\n }\n }\n }\n }\n": AllOperationsDocument,
|
|
617
|
-
"\n query GetCategories($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n tags {\n __typename\n name\n operations {\n __typename\n slug\n deprecated\n method\n summary\n operationId\n path\n }\n }\n }\n }\n": GetCategoriesDocument
|
|
618
|
-
};
|
|
619
|
-
function graphql(source) {
|
|
620
|
-
return documents[source] ?? {};
|
|
610
|
+
function V(e) {
|
|
611
|
+
return D[e] ?? {};
|
|
621
612
|
}
|
|
622
|
-
const
|
|
623
|
-
title = "An error occurred",
|
|
624
|
-
message,
|
|
625
|
-
category
|
|
626
|
-
}) => {
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
] });
|
|
633
|
-
};
|
|
634
|
-
const GetCategoriesQuery = graphql(`
|
|
613
|
+
const j = ({
|
|
614
|
+
title: e = "An error occurred",
|
|
615
|
+
message: d,
|
|
616
|
+
category: t
|
|
617
|
+
}) => /* @__PURE__ */ n.jsxs("div", { className: o + " h-full pt-[--padding-content-top]", children: [
|
|
618
|
+
t && /* @__PURE__ */ n.jsx(u, { children: t }),
|
|
619
|
+
e && /* @__PURE__ */ n.jsx(c, { level: 1, className: "flex gap-3.5 items-center", children: e }),
|
|
620
|
+
/* @__PURE__ */ n.jsx("p", { children: d }),
|
|
621
|
+
/* @__PURE__ */ n.jsx(p, { to: "/", children: "Go back home" })
|
|
622
|
+
] }), q = V(`
|
|
635
623
|
query GetCategories($input: JSON!, $type: SchemaType!) {
|
|
636
624
|
schema(input: $input, type: $type) {
|
|
637
625
|
tags {
|
|
@@ -649,84 +637,76 @@ const GetCategoriesQuery = graphql(`
|
|
|
649
637
|
}
|
|
650
638
|
}
|
|
651
639
|
}
|
|
652
|
-
`)
|
|
653
|
-
const
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
const client = config.server ? new Client({
|
|
661
|
-
url: config.server,
|
|
662
|
-
exchanges: [cacheExchange, fetchExchange]
|
|
663
|
-
}) : createClient({ useMemoryClient: config.inMemory ?? false });
|
|
640
|
+
`), C = () => {
|
|
641
|
+
const e = k(), d = e instanceof Error ? /* @__PURE__ */ n.jsx(v, { code: e.message }) : "An unknown error occurred";
|
|
642
|
+
return /* @__PURE__ */ n.jsx(j, { category: "Error", title: "An error occurred", message: d });
|
|
643
|
+
}, M = (e) => {
|
|
644
|
+
const d = e.path ?? "/reference", t = e.server ? new N({
|
|
645
|
+
url: e.server,
|
|
646
|
+
exchanges: [y, F]
|
|
647
|
+
}) : S({ useMemoryClient: e.inMemory ?? !1 });
|
|
664
648
|
return {
|
|
665
649
|
getHead: () => {
|
|
666
|
-
if (
|
|
667
|
-
return /* @__PURE__ */
|
|
650
|
+
if (e.type === "url")
|
|
651
|
+
return /* @__PURE__ */ n.jsx(
|
|
668
652
|
"link",
|
|
669
653
|
{
|
|
670
654
|
rel: "preload",
|
|
671
|
-
href:
|
|
655
|
+
href: e.input,
|
|
672
656
|
as: "fetch",
|
|
673
657
|
crossOrigin: "anonymous"
|
|
674
658
|
}
|
|
675
659
|
);
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx("link", { rel: "preconnect", href: config.server });
|
|
679
|
-
}
|
|
660
|
+
if (e.server)
|
|
661
|
+
return /* @__PURE__ */ n.jsx("link", { rel: "preconnect", href: e.server });
|
|
680
662
|
},
|
|
681
|
-
getNavigation: async (
|
|
682
|
-
if (!
|
|
663
|
+
getNavigation: async (i) => {
|
|
664
|
+
if (!g({ path: d, end: !1 }, i))
|
|
683
665
|
return [];
|
|
684
|
-
}
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
type: config.type
|
|
666
|
+
const { data: m } = await t.query(q, {
|
|
667
|
+
input: e.input,
|
|
668
|
+
type: e.type
|
|
688
669
|
});
|
|
689
|
-
if (!
|
|
690
|
-
const
|
|
691
|
-
path,
|
|
692
|
-
label:
|
|
693
|
-
collapsible:
|
|
694
|
-
children:
|
|
695
|
-
path: `#${
|
|
696
|
-
muted: !!
|
|
697
|
-
title:
|
|
698
|
-
label: /* @__PURE__ */
|
|
699
|
-
/* @__PURE__ */
|
|
700
|
-
/* @__PURE__ */
|
|
670
|
+
if (!m) return [];
|
|
671
|
+
const s = m.schema.tags.filter((l) => l.operations.length > 0).map((l) => ({
|
|
672
|
+
path: i,
|
|
673
|
+
label: l.name ?? "",
|
|
674
|
+
collapsible: !1,
|
|
675
|
+
children: l.operations.map((a) => ({
|
|
676
|
+
path: `#${a.slug}`,
|
|
677
|
+
muted: !!a.deprecated,
|
|
678
|
+
title: a.summary ?? a.path,
|
|
679
|
+
label: /* @__PURE__ */ n.jsxs("div", { className: "flex flex-1 min-w-0 justify-between gap-2", children: [
|
|
680
|
+
/* @__PURE__ */ n.jsx("span", { className: "truncate", children: a.summary ?? a.path }),
|
|
681
|
+
/* @__PURE__ */ n.jsx(b, { method: a.method })
|
|
701
682
|
] })
|
|
702
683
|
}))
|
|
703
684
|
}));
|
|
704
|
-
|
|
705
|
-
path,
|
|
685
|
+
return s.unshift({
|
|
686
|
+
path: i,
|
|
706
687
|
label: "Overview",
|
|
707
|
-
collapsible:
|
|
688
|
+
collapsible: !1,
|
|
708
689
|
children: [{ path: "#description", label: "Description" }]
|
|
709
|
-
});
|
|
710
|
-
return categories;
|
|
690
|
+
}), s;
|
|
711
691
|
},
|
|
712
692
|
getRoutes: () => [
|
|
713
693
|
{
|
|
714
694
|
async lazy() {
|
|
715
|
-
const { OpenApiRoute } = await import("./Route-
|
|
695
|
+
const { OpenApiRoute: i } = await import("./Route-C1LyvITr.js");
|
|
716
696
|
return {
|
|
717
|
-
element: /* @__PURE__ */
|
|
697
|
+
element: /* @__PURE__ */ n.jsx(i, { client: t, config: e })
|
|
718
698
|
};
|
|
719
699
|
},
|
|
720
|
-
errorElement: /* @__PURE__ */
|
|
700
|
+
errorElement: /* @__PURE__ */ n.jsx(C, {}),
|
|
721
701
|
children: [
|
|
722
702
|
{
|
|
723
|
-
path:
|
|
703
|
+
path: d,
|
|
724
704
|
children: [
|
|
725
705
|
{
|
|
726
|
-
index:
|
|
706
|
+
index: !0,
|
|
727
707
|
async lazy() {
|
|
728
|
-
const { OperationList } = await import("./OperationList-
|
|
729
|
-
return { element: /* @__PURE__ */
|
|
708
|
+
const { OperationList: i } = await import("./OperationList-DpR4KzIJ.js");
|
|
709
|
+
return { element: /* @__PURE__ */ n.jsx(i, {}) };
|
|
730
710
|
}
|
|
731
711
|
}
|
|
732
712
|
]
|
|
@@ -737,9 +717,9 @@ const openApiPlugin = (config) => {
|
|
|
737
717
|
};
|
|
738
718
|
};
|
|
739
719
|
export {
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
|
|
720
|
+
j as E,
|
|
721
|
+
I as M,
|
|
722
|
+
V as g,
|
|
723
|
+
M as o
|
|
744
724
|
};
|
|
745
|
-
//# sourceMappingURL=index-
|
|
725
|
+
//# sourceMappingURL=index-DZ910ttL.js.map
|