zudoku 0.0.0-z3809aef2 → 0.0.0-z63644134
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/loader.js +3 -1
- package/dist/config/loader.js.map +1 -1
- package/dist/config/validators/InputNavigationSchema.d.ts +119 -119
- package/dist/config/validators/ProtectedRoutesSchema.d.ts +1 -1
- package/dist/config/validators/validate.d.ts +7 -7
- package/dist/flat-config.d.ts +25 -25
- package/dist/lib/components/Heading.d.ts +1 -1
- package/dist/lib/components/index.d.ts +18 -74
- package/dist/lib/components/index.js +19 -36
- package/dist/lib/components/index.js.map +1 -1
- package/dist/lib/core/plugins.d.ts +11 -1
- package/dist/lib/core/plugins.js +1 -0
- package/dist/lib/core/plugins.js.map +1 -1
- package/dist/lib/core/transform-config.d.ts +2 -0
- package/dist/lib/core/transform-config.js +22 -0
- package/dist/lib/core/transform-config.js.map +1 -0
- package/dist/lib/hooks/index.d.ts +7 -30
- package/dist/lib/hooks/index.js +7 -15
- package/dist/lib/hooks/index.js.map +1 -1
- package/dist/lib/oas/graphql/circular.d.ts +1 -1
- package/dist/lib/oas/graphql/circular.js +18 -35
- package/dist/lib/oas/graphql/circular.js.map +1 -1
- package/dist/lib/oas/graphql/circular.test.js +33 -2
- package/dist/lib/oas/graphql/circular.test.js.map +1 -1
- package/dist/lib/oas/parser/index.js +14 -5
- package/dist/lib/oas/parser/index.js.map +1 -1
- package/dist/lib/ui/Command.d.ts +3 -3
- package/dist/lib/util/flattenAllOf.d.ts +0 -2
- package/dist/lib/util/flattenAllOf.js +0 -46
- package/dist/lib/util/flattenAllOf.js.map +1 -1
- package/dist/lib/util/flattenAllOf.test.js +2 -1
- package/dist/lib/util/flattenAllOf.test.js.map +1 -1
- package/dist/lib/util/flattenAllOfProcessor.d.ts +2 -0
- package/dist/lib/util/flattenAllOfProcessor.js +48 -0
- package/dist/lib/util/flattenAllOfProcessor.js.map +1 -0
- package/dist/lib/util/readFrontmatter.js +2 -1
- package/dist/lib/util/readFrontmatter.js.map +1 -1
- package/dist/vite/api/SchemaManager.js +1 -1
- package/dist/vite/api/SchemaManager.js.map +1 -1
- package/dist/vite/api/SchemaManager.test.js +1 -1
- package/dist/vite/api/SchemaManager.test.js.map +1 -1
- package/dist/vite/build.js +91 -73
- package/dist/vite/build.js.map +1 -1
- package/dist/vite/mdx/remark-inject-filepath.js +5 -1
- package/dist/vite/mdx/remark-inject-filepath.js.map +1 -1
- package/dist/vite/mdx/remark-link-rewrite.js +3 -2
- package/dist/vite/mdx/remark-link-rewrite.js.map +1 -1
- package/dist/vite/plugin-docs.js +9 -7
- package/dist/vite/plugin-docs.js.map +1 -1
- package/dist/vite/plugin-markdown-export.js +4 -2
- package/dist/vite/plugin-markdown-export.js.map +1 -1
- package/lib/{ClaudeLogo-DHxJUhN_.js → ClaudeLogo-C6q-Xn_l.js} +26 -22
- package/lib/{ClaudeLogo-DHxJUhN_.js.map → ClaudeLogo-C6q-Xn_l.js.map} +1 -1
- package/lib/{MdxPage-CD36PJ17.js → MdxPage-B1G4W1TK.js} +8 -8
- package/lib/{MdxPage-CD36PJ17.js.map → MdxPage-B1G4W1TK.js.map} +1 -1
- package/lib/{Mermaid-Koc3z8mU.js → Mermaid-B1xNo-pf.js} +3 -2
- package/lib/{Mermaid-Koc3z8mU.js.map → Mermaid-B1xNo-pf.js.map} +1 -1
- package/lib/{OAuthErrorPage-4mN5DA86.js → OAuthErrorPage-01Ke086W.js} +20 -18
- package/lib/{OAuthErrorPage-4mN5DA86.js.map → OAuthErrorPage-01Ke086W.js.map} +1 -1
- package/lib/{OasProvider-D-4BX8P3.js → OasProvider-oHPiMJZg.js} +3 -3
- package/lib/{OasProvider-D-4BX8P3.js.map → OasProvider-oHPiMJZg.js.map} +1 -1
- package/lib/{OperationList-BOu9Qd_k.js → OperationList-CZ4OK8Pm.js} +948 -945
- package/lib/OperationList-CZ4OK8Pm.js.map +1 -0
- package/lib/{RouteGuard--A04ESy8.js → RouteGuard-B1lCR0C_.js} +5 -5
- package/lib/{RouteGuard--A04ESy8.js.map → RouteGuard-B1lCR0C_.js.map} +1 -1
- package/lib/{SchemaList-B167Xmbd.js → SchemaList-DoQFkJgM.js} +7 -7
- package/lib/{SchemaList-B167Xmbd.js.map → SchemaList-DoQFkJgM.js.map} +1 -1
- package/lib/{SchemaView-Dx9gtne2.js → SchemaView-D2k6ZJck.js} +3 -3
- package/lib/{SchemaView-Dx9gtne2.js.map → SchemaView-D2k6ZJck.js.map} +1 -1
- package/lib/{SignUp-DRvN-8cq.js → SignUp-8kDBaLbO.js} +31 -26
- package/lib/{SignUp-DRvN-8cq.js.map → SignUp-8kDBaLbO.js.map} +1 -1
- package/lib/{SyntaxHighlight-klTH8c6-.js → SyntaxHighlight-hZOFnYl0.js} +6 -5
- package/lib/SyntaxHighlight-hZOFnYl0.js.map +1 -0
- package/lib/{Toc-PbuF-u9x.js → Toc-qEIii_-W.js} +2 -2
- package/lib/{Toc-PbuF-u9x.js.map → Toc-qEIii_-W.js.map} +1 -1
- package/lib/{index-BDsEwofZ.js → Zudoku-DUsdmPME.js} +2250 -2268
- package/lib/Zudoku-DUsdmPME.js.map +1 -0
- package/lib/{ZudokuContext-BZB1TWdT.js → ZudokuContext-BBI06sOx.js} +5 -5
- package/lib/{ZudokuContext-BZB1TWdT.js.map → ZudokuContext-BBI06sOx.js.map} +1 -1
- package/lib/{circular-B5aq06Lb.js → circular-D9tSKG2c.js} +1327 -1346
- package/lib/{circular-B5aq06Lb.js.map → circular-D9tSKG2c.js.map} +1 -1
- package/lib/createServer-BprC4n85.js +13036 -0
- package/lib/createServer-BprC4n85.js.map +1 -0
- package/lib/{errors-rWHkzVTd.js → errors-7hgPDs1h.js} +3 -3
- package/lib/{errors-rWHkzVTd.js.map → errors-7hgPDs1h.js.map} +1 -1
- package/lib/{firebase-BmGU1FuD.js → firebase-Dwn-2ju-.js} +13 -13
- package/lib/firebase-Dwn-2ju-.js.map +1 -0
- package/lib/{hook-BGlHBdET.js → hook-ZEd1Es7D.js} +2 -2
- package/lib/{hook-BGlHBdET.js.map → hook-ZEd1Es7D.js.map} +1 -1
- package/lib/{index-BcAudYNw.js → index-CyIW9rHv.js} +463 -461
- package/lib/{index-BcAudYNw.js.map → index-CyIW9rHv.js.map} +1 -1
- package/lib/index-DAWHN3cH.js +86 -0
- package/lib/index-DAWHN3cH.js.map +1 -0
- package/lib/{index-DRBOFufT.js → index-Dxdhrp-I.js} +2 -2
- package/lib/{index-DRBOFufT.js.map → index-Dxdhrp-I.js.map} +1 -1
- package/lib/{index.esm-B_0dvNjB.js → index.esm-Ca5zvoff.js} +20 -20
- package/lib/{index.esm-B_0dvNjB.js.map → index.esm-Ca5zvoff.js.map} +1 -1
- package/lib/{index.esm-Cx8B1YJQ.js → index.esm-DG4KaDKR.js} +2 -2
- package/lib/index.esm-DG4KaDKR.js.map +1 -0
- package/lib/{invariant-BJAl77rw.js → invariant-B_t_F2s_.js} +3 -3
- package/lib/{invariant-BJAl77rw.js.map → invariant-B_t_F2s_.js.map} +1 -1
- package/lib/ui/SyntaxHighlight.js +3 -3
- package/lib/useExposedProps-CzTDfXfq.js +30 -0
- package/lib/useExposedProps-CzTDfXfq.js.map +1 -0
- package/lib/zudoku.__internal.js +1492 -1030
- package/lib/zudoku.__internal.js.map +1 -1
- package/lib/zudoku.auth-auth0.js +1 -1
- package/lib/zudoku.auth-azureb2c.js +4 -4
- package/lib/zudoku.auth-clerk.js +2 -2
- package/lib/zudoku.auth-firebase.js +5 -5
- package/lib/zudoku.auth-openid.js +5 -5
- package/lib/zudoku.auth-supabase.js +4 -4
- package/lib/zudoku.components.js +31 -29
- package/lib/zudoku.components.js.map +1 -1
- package/lib/zudoku.hooks.js +24 -11
- package/lib/zudoku.hooks.js.map +1 -1
- package/lib/zudoku.mermaid.js +4 -3
- package/lib/zudoku.mermaid.js.map +1 -1
- package/lib/zudoku.plugin-api-catalog.js +36 -32
- package/lib/zudoku.plugin-api-catalog.js.map +1 -1
- package/lib/zudoku.plugin-api-keys.js +131 -130
- package/lib/zudoku.plugin-api-keys.js.map +1 -1
- package/lib/zudoku.plugin-custom-pages.js +1 -1
- package/lib/zudoku.plugin-markdown.js +1 -1
- package/lib/zudoku.plugin-openapi.js +2 -2
- package/lib/zudoku.plugin-search-pagefind.js +2 -2
- package/lib/zudoku.plugins.js +9 -8
- package/lib/zudoku.plugins.js.map +1 -1
- package/package.json +12 -10
- package/src/lib/components/index.ts +19 -39
- package/src/lib/core/plugins.ts +21 -1
- package/src/lib/core/transform-config.ts +29 -0
- package/src/lib/hooks/index.ts +7 -16
- package/src/lib/oas/graphql/circular.test.ts +37 -2
- package/src/lib/oas/graphql/circular.ts +25 -51
- package/src/lib/oas/parser/index.ts +17 -6
- package/src/lib/util/flattenAllOf.test.ts +2 -1
- package/src/lib/util/flattenAllOf.ts +0 -57
- package/src/lib/util/flattenAllOfProcessor.ts +58 -0
- package/src/lib/util/readFrontmatter.ts +2 -1
- package/src/shiki/langs/c3.js +1 -0
- package/src/shiki/langs/gn.js +1 -0
- package/src/shiki/langs/moonbit.js +1 -0
- package/src/zuplo/enrich-with-zuplo-mcp.ts +168 -0
- package/src/zuplo/enrich-with-zuplo.ts +254 -0
- package/src/zuplo/policy-types.ts +46 -0
- package/src/zuplo/with-zuplo-processors.ts +35 -0
- package/src/zuplo/with-zuplo.ts +14 -0
- package/lib/OperationList-BOu9Qd_k.js.map +0 -1
- package/lib/SyntaxHighlight-klTH8c6-.js.map +0 -1
- package/lib/___vite-browser-external_commonjs-proxy-BttVsNON.js +0 -9
- package/lib/___vite-browser-external_commonjs-proxy-BttVsNON.js.map +0 -1
- package/lib/createServer-CasZ-UG7.js +0 -16693
- package/lib/createServer-CasZ-UG7.js.map +0 -1
- package/lib/firebase-BmGU1FuD.js.map +0 -1
- package/lib/index-BDsEwofZ.js.map +0 -1
- package/lib/index-DBjOT2H1.js +0 -133
- package/lib/index-DBjOT2H1.js.map +0 -1
- package/lib/index.esm-Cx8B1YJQ.js.map +0 -1
|
@@ -9,5 +9,5 @@ type ProtectedRouteCallback = (c: CallbackContext) => boolean;
|
|
|
9
9
|
export type ProtectedRoutesInput = z.input<typeof ProtectedRoutesInputSchema>;
|
|
10
10
|
export type ProtectedRoutes = z.output<typeof ProtectedRoutesInputSchema>;
|
|
11
11
|
export declare const ProtectedRoutesInputSchema: z.ZodOptional<z.ZodUnion<readonly [z.ZodArray<z.ZodString>, z.ZodRecord<z.ZodString, z.ZodCustom<ProtectedRouteCallback, ProtectedRouteCallback>>]>>;
|
|
12
|
-
export declare const ProtectedRoutesSchema: z.ZodPipe<z.ZodOptional<z.ZodUnion<readonly [z.ZodArray<z.ZodString>, z.ZodRecord<z.ZodString, z.ZodCustom<ProtectedRouteCallback, ProtectedRouteCallback>>]>>, z.ZodTransform<Record<string, (c: CallbackContext) => boolean> | undefined, Record<string, ProtectedRouteCallback> |
|
|
12
|
+
export declare const ProtectedRoutesSchema: z.ZodPipe<z.ZodOptional<z.ZodUnion<readonly [z.ZodArray<z.ZodString>, z.ZodRecord<z.ZodString, z.ZodCustom<ProtectedRouteCallback, ProtectedRouteCallback>>]>>, z.ZodTransform<Record<string, (c: CallbackContext) => boolean> | undefined, string[] | Record<string, ProtectedRouteCallback> | undefined>>;
|
|
13
13
|
export {};
|
|
@@ -171,8 +171,8 @@ export declare const FooterSocialSchema: z.ZodObject<{
|
|
|
171
171
|
export declare const FooterSchema: z.ZodOptional<z.ZodObject<{
|
|
172
172
|
columns: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
173
173
|
position: z.ZodOptional<z.ZodEnum<{
|
|
174
|
-
center: "center";
|
|
175
174
|
end: "end";
|
|
175
|
+
center: "center";
|
|
176
176
|
start: "start";
|
|
177
177
|
}>>;
|
|
178
178
|
title: z.ZodString;
|
|
@@ -212,8 +212,8 @@ export declare const FooterSchema: z.ZodOptional<z.ZodObject<{
|
|
|
212
212
|
href: z.ZodOptional<z.ZodString>;
|
|
213
213
|
}, z.core.$strip>>;
|
|
214
214
|
position: z.ZodOptional<z.ZodEnum<{
|
|
215
|
-
center: "center";
|
|
216
215
|
end: "end";
|
|
216
|
+
center: "center";
|
|
217
217
|
start: "start";
|
|
218
218
|
}>>;
|
|
219
219
|
}, z.core.$strip>>;
|
|
@@ -283,10 +283,10 @@ declare const AuthenticationSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
283
283
|
github: "github";
|
|
284
284
|
phone: "phone";
|
|
285
285
|
twitter: "twitter";
|
|
286
|
+
password: "password";
|
|
286
287
|
google: "google";
|
|
287
288
|
microsoft: "microsoft";
|
|
288
289
|
yahoo: "yahoo";
|
|
289
|
-
password: "password";
|
|
290
290
|
}>>>;
|
|
291
291
|
redirectToAfterSignUp: z.ZodOptional<z.ZodString>;
|
|
292
292
|
redirectToAfterSignIn: z.ZodOptional<z.ZodString>;
|
|
@@ -398,7 +398,7 @@ export declare const ZudokuConfig: z.ZodObject<{
|
|
|
398
398
|
remarkPlugins?: Options["remarkPlugins"];
|
|
399
399
|
rehypePlugins?: Options["rehypePlugins"];
|
|
400
400
|
}>>;
|
|
401
|
-
protectedRoutes: z.ZodOptional<z.ZodPipe<z.ZodOptional<z.ZodUnion<readonly [z.ZodArray<z.ZodString>, z.ZodRecord<z.ZodString, z.ZodCustom<(c: import("./ProtectedRoutesSchema.js").CallbackContext) => boolean, (c: import("./ProtectedRoutesSchema.js").CallbackContext) => boolean>>]>>, z.ZodTransform<Record<string, (c: import("./ProtectedRoutesSchema.js").CallbackContext) => boolean> | undefined, Record<string, (c: import("./ProtectedRoutesSchema.js").CallbackContext) => boolean> |
|
|
401
|
+
protectedRoutes: z.ZodOptional<z.ZodPipe<z.ZodOptional<z.ZodUnion<readonly [z.ZodArray<z.ZodString>, z.ZodRecord<z.ZodString, z.ZodCustom<(c: import("./ProtectedRoutesSchema.js").CallbackContext) => boolean, (c: import("./ProtectedRoutesSchema.js").CallbackContext) => boolean>>]>>, z.ZodTransform<Record<string, (c: import("./ProtectedRoutesSchema.js").CallbackContext) => boolean> | undefined, string[] | Record<string, (c: import("./ProtectedRoutesSchema.js").CallbackContext) => boolean> | undefined>>>;
|
|
402
402
|
basePath: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
403
403
|
canonicalUrlOrigin: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
404
404
|
cdnUrl: z.ZodOptional<z.ZodOptional<z.ZodOptional<z.ZodPipe<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
@@ -442,8 +442,8 @@ export declare const ZudokuConfig: z.ZodObject<{
|
|
|
442
442
|
footer: z.ZodOptional<z.ZodOptional<z.ZodObject<{
|
|
443
443
|
columns: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
444
444
|
position: z.ZodOptional<z.ZodEnum<{
|
|
445
|
-
center: "center";
|
|
446
445
|
end: "end";
|
|
446
|
+
center: "center";
|
|
447
447
|
start: "start";
|
|
448
448
|
}>>;
|
|
449
449
|
title: z.ZodString;
|
|
@@ -483,8 +483,8 @@ export declare const ZudokuConfig: z.ZodObject<{
|
|
|
483
483
|
href: z.ZodOptional<z.ZodString>;
|
|
484
484
|
}, z.core.$strip>>;
|
|
485
485
|
position: z.ZodOptional<z.ZodEnum<{
|
|
486
|
-
center: "center";
|
|
487
486
|
end: "end";
|
|
487
|
+
center: "center";
|
|
488
488
|
start: "start";
|
|
489
489
|
}>>;
|
|
490
490
|
}, z.core.$strip>>>;
|
|
@@ -674,10 +674,10 @@ export declare const ZudokuConfig: z.ZodObject<{
|
|
|
674
674
|
github: "github";
|
|
675
675
|
phone: "phone";
|
|
676
676
|
twitter: "twitter";
|
|
677
|
+
password: "password";
|
|
677
678
|
google: "google";
|
|
678
679
|
microsoft: "microsoft";
|
|
679
680
|
yahoo: "yahoo";
|
|
680
|
-
password: "password";
|
|
681
681
|
}>>>;
|
|
682
682
|
redirectToAfterSignUp: z.ZodOptional<z.ZodString>;
|
|
683
683
|
redirectToAfterSignIn: z.ZodOptional<z.ZodString>;
|
package/dist/flat-config.d.ts
CHANGED
|
@@ -44,31 +44,31 @@ export type _Schema6 = (("Inter" | "Roboto" | "Open Sans" | "Poppins" | "Montser
|
|
|
44
44
|
url: string
|
|
45
45
|
fontFamily?: string
|
|
46
46
|
})
|
|
47
|
-
export type
|
|
47
|
+
export type _Schema11 = ({
|
|
48
48
|
type: "url"
|
|
49
|
-
input: (string |
|
|
50
|
-
server?:
|
|
51
|
-
path?:
|
|
52
|
-
categories?:
|
|
53
|
-
options?:
|
|
49
|
+
input: (string | _Schema12[])
|
|
50
|
+
server?: _Schema13
|
|
51
|
+
path?: _Schema14
|
|
52
|
+
categories?: _Schema15
|
|
53
|
+
options?: _Schema17
|
|
54
54
|
} | {
|
|
55
55
|
type: "file"
|
|
56
|
-
input: (string | (string |
|
|
57
|
-
server?:
|
|
58
|
-
path?:
|
|
59
|
-
categories?:
|
|
60
|
-
options?:
|
|
56
|
+
input: (string | (string | _Schema12)[])
|
|
57
|
+
server?: _Schema13
|
|
58
|
+
path?: _Schema14
|
|
59
|
+
categories?: _Schema15
|
|
60
|
+
options?: _Schema17
|
|
61
61
|
} | {
|
|
62
62
|
type: "raw"
|
|
63
63
|
input: string
|
|
64
|
-
server?:
|
|
65
|
-
path?:
|
|
66
|
-
categories?:
|
|
67
|
-
options?:
|
|
64
|
+
server?: _Schema13
|
|
65
|
+
path?: _Schema14
|
|
66
|
+
categories?: _Schema15
|
|
67
|
+
options?: _Schema17
|
|
68
68
|
})
|
|
69
|
-
export type
|
|
70
|
-
export type
|
|
71
|
-
export type
|
|
69
|
+
export type _Schema13 = string
|
|
70
|
+
export type _Schema14 = string
|
|
71
|
+
export type _Schema15 = {
|
|
72
72
|
label: string
|
|
73
73
|
tags: string[]
|
|
74
74
|
}[]
|
|
@@ -156,7 +156,7 @@ export interface FlatZudokuConfig {
|
|
|
156
156
|
noDefaultTheme?: boolean
|
|
157
157
|
}
|
|
158
158
|
syntaxHighlighting?: {
|
|
159
|
-
languages?: ("abap" | "actionscript-3" | "ada" | "angular-html" | "angular-ts" | "apache" | "apex" | "apl" | "applescript" | "ara" | "asciidoc" | "asm" | "astro" | "awk" | "ballerina" | "bat" | "beancount" | "berry" | "bibtex" | "bicep" | "blade" | "bsl" | "c" | "cadence" | "cairo" | "clarity" | "clojure" | "cmake" | "cobol" | "codeowners" | "codeql" | "coffee" | "common-lisp" | "coq" | "cpp" | "crystal" | "csharp" | "css" | "csv" | "cue" | "cypher" | "d" | "dart" | "dax" | "desktop" | "diff" | "docker" | "dotenv" | "dream-maker" | "edge" | "elixir" | "elm" | "emacs-lisp" | "erb" | "erlang" | "fennel" | "fish" | "fluent" | "fortran-fixed-form" | "fortran-free-form" | "fsharp" | "gdresource" | "gdscript" | "gdshader" | "genie" | "gherkin" | "git-commit" | "git-rebase" | "gleam" | "glimmer-js" | "glimmer-ts" | "glsl" | "gnuplot" | "go" | "graphql" | "groovy" | "hack" | "haml" | "handlebars" | "haskell" | "haxe" | "hcl" | "hjson" | "hlsl" | "html" | "html-derivative" | "http" | "hurl" | "hxml" | "hy" | "imba" | "ini" | "java" | "javascript" | "jinja" | "jison" | "json" | "json5" | "jsonc" | "jsonl" | "jsonnet" | "jssm" | "jsx" | "julia" | "kdl" | "kotlin" | "kusto" | "latex" | "lean" | "less" | "liquid" | "llvm" | "log" | "logo" | "lua" | "luau" | "make" | "markdown" | "marko" | "matlab" | "mdc" | "mdx" | "mermaid" | "mipsasm" | "mojo" | "move" | "narrat" | "nextflow" | "nginx" | "nim" | "nix" | "nushell" | "objective-c" | "objective-cpp" | "ocaml" | "openscad" | "pascal" | "perl" | "php" | "pkl" | "plsql" | "po" | "polar" | "postcss" | "powerquery" | "powershell" | "prisma" | "prolog" | "proto" | "pug" | "puppet" | "purescript" | "python" | "qml" | "qmldir" | "qss" | "r" | "racket" | "raku" | "razor" | "reg" | "regexp" | "rel" | "riscv" | "rosmsg" | "rst" | "ruby" | "rust" | "sas" | "sass" | "scala" | "scheme" | "scss" | "sdbl" | "shaderlab" | "shellscript" | "shellsession" | "smalltalk" | "solidity" | "soy" | "sparql" | "splunk" | "sql" | "ssh-config" | "stata" | "stylus" | "svelte" | "swift" | "system-verilog" | "systemd" | "talonscript" | "tasl" | "tcl" | "templ" | "terraform" | "tex" | "toml" | "ts-tags" | "tsv" | "tsx" | "turtle" | "twig" | "typescript" | "typespec" | "typst" | "v" | "vala" | "vb" | "verilog" | "vhdl" | "viml" | "vue" | "vue-html" | "vue-vine" | "vyper" | "wasm" | "wenyan" | "wgsl" | "wikitext" | "wit" | "wolfram" | "xml" | "xsl" | "yaml" | "zenscript" | "zig" | "adoc" | "batch" | "be" | "1c" | "cdc" | "clj" | "ql" | "coffeescript" | "lisp" | "c++" | "c#" | "cs" | "cql" | "dockerfile" | "elisp" | "erl" | "ftl" | "f" | "for" | "f77" | "f90" | "f95" | "f03" | "f08" | "f18" | "f#" | "fs" | "gjs" | "gts" | "gql" | "hbs" | "hs" | "properties" | "js" | "cjs" | "mjs" | "fsl" | "jl" | "kt" | "kts" | "kql" | "lean4" | "makefile" | "md" | "mmd" | "mips" | "nar" | "nf" | "nu" | "objc" | "scad" | "pot" | "potx" | "ps" | "ps1" | "protobuf" | "jade" | "py" | "perl6" | "regex" | "rb" | "rs" | "1c-query" | "shader" | "bash" | "sh" | "shell" | "zsh" | "console" | "closure-templates" | "spl" | "styl" | "talon" | "tf" | "tfvars" | "lit" | "ts" | "cts" | "mts" | "tsp" | "typ" | "cmd" | "vim" | "vimscript" | "vy" | "文言" | "mediawiki" | "wiki" | "wl" | "yml")[]
|
|
159
|
+
languages?: ("abap" | "actionscript-3" | "ada" | "angular-html" | "angular-ts" | "apache" | "apex" | "apl" | "applescript" | "ara" | "asciidoc" | "asm" | "astro" | "awk" | "ballerina" | "bat" | "beancount" | "berry" | "bibtex" | "bicep" | "blade" | "bsl" | "c" | "c3" | "cadence" | "cairo" | "clarity" | "clojure" | "cmake" | "cobol" | "codeowners" | "codeql" | "coffee" | "common-lisp" | "coq" | "cpp" | "crystal" | "csharp" | "css" | "csv" | "cue" | "cypher" | "d" | "dart" | "dax" | "desktop" | "diff" | "docker" | "dotenv" | "dream-maker" | "edge" | "elixir" | "elm" | "emacs-lisp" | "erb" | "erlang" | "fennel" | "fish" | "fluent" | "fortran-fixed-form" | "fortran-free-form" | "fsharp" | "gdresource" | "gdscript" | "gdshader" | "genie" | "gherkin" | "git-commit" | "git-rebase" | "gleam" | "glimmer-js" | "glimmer-ts" | "glsl" | "gn" | "gnuplot" | "go" | "graphql" | "groovy" | "hack" | "haml" | "handlebars" | "haskell" | "haxe" | "hcl" | "hjson" | "hlsl" | "html" | "html-derivative" | "http" | "hurl" | "hxml" | "hy" | "imba" | "ini" | "java" | "javascript" | "jinja" | "jison" | "json" | "json5" | "jsonc" | "jsonl" | "jsonnet" | "jssm" | "jsx" | "julia" | "kdl" | "kotlin" | "kusto" | "latex" | "lean" | "less" | "liquid" | "llvm" | "log" | "logo" | "lua" | "luau" | "make" | "markdown" | "marko" | "matlab" | "mdc" | "mdx" | "mermaid" | "mipsasm" | "mojo" | "moonbit" | "move" | "narrat" | "nextflow" | "nginx" | "nim" | "nix" | "nushell" | "objective-c" | "objective-cpp" | "ocaml" | "openscad" | "pascal" | "perl" | "php" | "pkl" | "plsql" | "po" | "polar" | "postcss" | "powerquery" | "powershell" | "prisma" | "prolog" | "proto" | "pug" | "puppet" | "purescript" | "python" | "qml" | "qmldir" | "qss" | "r" | "racket" | "raku" | "razor" | "reg" | "regexp" | "rel" | "riscv" | "rosmsg" | "rst" | "ruby" | "rust" | "sas" | "sass" | "scala" | "scheme" | "scss" | "sdbl" | "shaderlab" | "shellscript" | "shellsession" | "smalltalk" | "solidity" | "soy" | "sparql" | "splunk" | "sql" | "ssh-config" | "stata" | "stylus" | "svelte" | "swift" | "system-verilog" | "systemd" | "talonscript" | "tasl" | "tcl" | "templ" | "terraform" | "tex" | "toml" | "ts-tags" | "tsv" | "tsx" | "turtle" | "twig" | "typescript" | "typespec" | "typst" | "v" | "vala" | "vb" | "verilog" | "vhdl" | "viml" | "vue" | "vue-html" | "vue-vine" | "vyper" | "wasm" | "wenyan" | "wgsl" | "wikitext" | "wit" | "wolfram" | "xml" | "xsl" | "yaml" | "zenscript" | "zig" | "adoc" | "batch" | "be" | "1c" | "cdc" | "clj" | "ql" | "coffeescript" | "lisp" | "c++" | "c#" | "cs" | "cql" | "dockerfile" | "elisp" | "erl" | "ftl" | "f" | "for" | "f77" | "f90" | "f95" | "f03" | "f08" | "f18" | "f#" | "fs" | "gjs" | "gts" | "gql" | "hbs" | "hs" | "properties" | "js" | "cjs" | "mjs" | "fsl" | "jl" | "kt" | "kts" | "kql" | "lean4" | "makefile" | "md" | "mmd" | "mips" | "mbt" | "mbti" | "nar" | "nf" | "nu" | "objc" | "scad" | "pot" | "potx" | "ps" | "ps1" | "protobuf" | "jade" | "py" | "perl6" | "regex" | "rb" | "rs" | "1c-query" | "shader" | "bash" | "sh" | "shell" | "zsh" | "console" | "closure-templates" | "spl" | "styl" | "talon" | "tf" | "tfvars" | "lit" | "ts" | "cts" | "mts" | "tsp" | "typ" | "cmd" | "vim" | "vimscript" | "vy" | "文言" | "mediawiki" | "wiki" | "wl" | "yml")[]
|
|
160
160
|
themes?: {
|
|
161
161
|
light: ("andromeeda" | "aurora-x" | "ayu-dark" | "catppuccin-frappe" | "catppuccin-latte" | "catppuccin-macchiato" | "catppuccin-mocha" | "dark-plus" | "dracula" | "dracula-soft" | "everforest-dark" | "everforest-light" | "github-dark" | "github-dark-default" | "github-dark-dimmed" | "github-dark-high-contrast" | "github-light" | "github-light-default" | "github-light-high-contrast" | "gruvbox-dark-hard" | "gruvbox-dark-medium" | "gruvbox-dark-soft" | "gruvbox-light-hard" | "gruvbox-light-medium" | "gruvbox-light-soft" | "houston" | "kanagawa-dragon" | "kanagawa-lotus" | "kanagawa-wave" | "laserwave" | "light-plus" | "material-theme" | "material-theme-darker" | "material-theme-lighter" | "material-theme-ocean" | "material-theme-palenight" | "min-dark" | "min-light" | "monokai" | "night-owl" | "nord" | "one-dark-pro" | "one-light" | "plastic" | "poimandres" | "red" | "rose-pine" | "rose-pine-dawn" | "rose-pine-moon" | "slack-dark" | "slack-ochin" | "snazzy-light" | "solarized-dark" | "solarized-light" | "synthwave-84" | "tokyo-night" | "vesper" | "vitesse-black" | "vitesse-dark" | "vitesse-light")
|
|
162
162
|
dark: ("andromeeda" | "aurora-x" | "ayu-dark" | "catppuccin-frappe" | "catppuccin-latte" | "catppuccin-macchiato" | "catppuccin-mocha" | "dark-plus" | "dracula" | "dracula-soft" | "everforest-dark" | "everforest-light" | "github-dark" | "github-dark-default" | "github-dark-dimmed" | "github-dark-high-contrast" | "github-light" | "github-light-default" | "github-light-high-contrast" | "gruvbox-dark-hard" | "gruvbox-dark-medium" | "gruvbox-dark-soft" | "gruvbox-light-hard" | "gruvbox-light-medium" | "gruvbox-light-soft" | "houston" | "kanagawa-dragon" | "kanagawa-lotus" | "kanagawa-wave" | "laserwave" | "light-plus" | "material-theme" | "material-theme-darker" | "material-theme-lighter" | "material-theme-ocean" | "material-theme-palenight" | "min-dark" | "min-light" | "monokai" | "night-owl" | "nord" | "one-dark-pro" | "one-light" | "plastic" | "poimandres" | "red" | "rose-pine" | "rose-pine-dawn" | "rose-pine-moon" | "slack-dark" | "slack-ochin" | "snazzy-light" | "solarized-dark" | "solarized-light" | "synthwave-84" | "tokyo-night" | "vesper" | "vitesse-black" | "vitesse-dark" | "vitesse-light")
|
|
@@ -293,8 +293,8 @@ export interface FlatZudokuConfig {
|
|
|
293
293
|
includeProtected?: boolean
|
|
294
294
|
}
|
|
295
295
|
}
|
|
296
|
-
apis?: (
|
|
297
|
-
catalogs?: (
|
|
296
|
+
apis?: (_Schema11 | _Schema11[])
|
|
297
|
+
catalogs?: (_Schema18 | _Schema18[])
|
|
298
298
|
apiKeys?: {
|
|
299
299
|
enabled: boolean
|
|
300
300
|
getConsumers?: unknown
|
|
@@ -317,7 +317,7 @@ export interface FlatZudokuConfig {
|
|
|
317
317
|
}
|
|
318
318
|
enableStatusPages?: boolean
|
|
319
319
|
defaults?: {
|
|
320
|
-
apis:
|
|
320
|
+
apis: _Schema17
|
|
321
321
|
examplesLanguage?: string
|
|
322
322
|
}
|
|
323
323
|
}
|
|
@@ -358,12 +358,12 @@ export interface _Schema5 {
|
|
|
358
358
|
ring?: string
|
|
359
359
|
radius?: string
|
|
360
360
|
}
|
|
361
|
-
export interface
|
|
361
|
+
export interface _Schema12 {
|
|
362
362
|
path: string
|
|
363
363
|
input: string
|
|
364
364
|
label?: string
|
|
365
365
|
}
|
|
366
|
-
export interface
|
|
366
|
+
export interface _Schema17 {
|
|
367
367
|
examplesLanguage?: string
|
|
368
368
|
supportedLanguages?: {
|
|
369
369
|
value: string
|
|
@@ -380,7 +380,7 @@ export interface _Schema13 {
|
|
|
380
380
|
transformExamples?: unknown
|
|
381
381
|
generateCodeSnippet?: unknown
|
|
382
382
|
}
|
|
383
|
-
export interface
|
|
383
|
+
export interface _Schema18 {
|
|
384
384
|
path: string
|
|
385
385
|
label: string
|
|
386
386
|
items?: string[]
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type VariantProps } from "class-variance-authority";
|
|
2
2
|
import type { HTMLAttributes, ReactNode } from "react";
|
|
3
3
|
declare const heading: (props?: ({
|
|
4
|
-
level?:
|
|
4
|
+
level?: 2 | 1 | 3 | 4 | 5 | 6 | null | undefined;
|
|
5
5
|
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
6
6
|
export type HeadingProps = HTMLAttributes<HTMLHeadingElement> & VariantProps<typeof heading> & {
|
|
7
7
|
children: ReactNode;
|
|
@@ -1,79 +1,23 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
export
|
|
5
|
-
export
|
|
6
|
-
export
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
}
|
|
13
|
-
export
|
|
14
|
-
content: string;
|
|
15
|
-
className?: string;
|
|
16
|
-
components?: import("react-markdown").Components;
|
|
17
|
-
}) => import("react/jsx-runtime").JSX.Element>;
|
|
18
|
-
export declare const Spinner: ({ size }: {
|
|
19
|
-
size?: number;
|
|
20
|
-
}) => import("react/jsx-runtime").JSX.Element;
|
|
21
|
-
export declare const ClientOnly: (props: {
|
|
22
|
-
children: import("react").ReactNode;
|
|
23
|
-
fallback?: import("react").ReactNode;
|
|
24
|
-
}) => import("react").ReactNode;
|
|
25
|
-
export declare const Button: import("react").ForwardRefExoticComponent<import("../ui/Button.js").ButtonProps & import("react").RefAttributes<HTMLButtonElement>>;
|
|
26
|
-
export declare const Link: import("react").ForwardRefExoticComponent<import("react-router").LinkProps & import("react").RefAttributes<HTMLAnchorElement>>;
|
|
27
|
-
export declare const Zudoku: {
|
|
28
|
-
(props: import("../core/ZudokuContext.js").ZudokuContextOptions): import("react/jsx-runtime").JSX.Element;
|
|
29
|
-
displayName: string;
|
|
30
|
-
};
|
|
31
|
-
export declare const Typography: ({ children, className, }: {
|
|
32
|
-
children: React.ReactNode;
|
|
33
|
-
className?: string;
|
|
34
|
-
}) => import("react/jsx-runtime").JSX.Element;
|
|
35
|
-
export declare const Slot: {
|
|
36
|
-
Source: ({ name, children, type, }: {
|
|
37
|
-
name: import("./Slot.js").SlotName;
|
|
38
|
-
type?: "prepend" | "replace" | "append";
|
|
39
|
-
children: import("./context/SlotProvider.js").SlotType;
|
|
40
|
-
}) => null;
|
|
41
|
-
Target: ({ name, fallback }: {
|
|
42
|
-
name: string;
|
|
43
|
-
fallback?: import("react").ReactNode;
|
|
44
|
-
}) => string | number | bigint | boolean | import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>> | Iterable<import("react").ReactNode> | Promise<string | number | bigint | boolean | import("react").ReactPortal | import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>> | Iterable<import("react").ReactNode> | null | undefined> | import("react/jsx-runtime").JSX.Element[] | null | undefined;
|
|
45
|
-
};
|
|
46
|
-
export declare const ZudokuError: typeof ZudokuErrorImport;
|
|
1
|
+
export { Helmet as Head } from "@zudoku/react-helmet-async";
|
|
2
|
+
export { Link } from "react-router";
|
|
3
|
+
export { Button } from "../ui/Button.js";
|
|
4
|
+
export { Callout } from "../ui/Callout.js";
|
|
5
|
+
export { ZudokuError } from "../util/invariant.js";
|
|
6
|
+
export { ClientOnly } from "./ClientOnly.js";
|
|
7
|
+
export { Heading } from "./Heading.js";
|
|
8
|
+
export { Markdown } from "./Markdown.js";
|
|
9
|
+
export { Search } from "./Search.js";
|
|
10
|
+
export { Slot } from "./Slot.js";
|
|
11
|
+
export { Spinner } from "./Spinner.js";
|
|
12
|
+
export { Typography } from "./Typography.js";
|
|
13
|
+
export { Zudoku } from "./Zudoku.js";
|
|
47
14
|
/** @deprecated Import from `zudoku/hooks` instead */
|
|
48
|
-
export
|
|
15
|
+
export { useMDXComponents } from "@mdx-js/react";
|
|
49
16
|
/** @deprecated Import from `zudoku/hooks` instead */
|
|
50
|
-
export
|
|
17
|
+
export { useTheme } from "next-themes";
|
|
51
18
|
/** @deprecated Import from `zudoku/hooks` instead */
|
|
52
|
-
export
|
|
53
|
-
login: (options?: import("../authentication/authentication.js").AuthActionOptions) => Promise<void>;
|
|
54
|
-
logout: () => Promise<void>;
|
|
55
|
-
signup: (options?: import("../authentication/authentication.js").AuthActionOptions) => Promise<void>;
|
|
56
|
-
supportsEmailVerification: boolean;
|
|
57
|
-
requestEmailVerification: (options?: import("../authentication/authentication.js").AuthActionOptions) => Promise<void>;
|
|
58
|
-
isAuthenticated: boolean;
|
|
59
|
-
isPending: boolean;
|
|
60
|
-
profile: import("../authentication/state.js").UserProfile | null;
|
|
61
|
-
providerData: unknown;
|
|
62
|
-
setAuthenticationPending: () => void;
|
|
63
|
-
setLoggedOut: () => void;
|
|
64
|
-
setLoggedIn: ({ profile, providerData, }: {
|
|
65
|
-
profile: import("../authentication/state.js").UserProfile;
|
|
66
|
-
providerData: unknown;
|
|
67
|
-
}) => void;
|
|
68
|
-
isAuthEnabled: boolean;
|
|
69
|
-
};
|
|
19
|
+
export { useAuth } from "../authentication/hook.js";
|
|
70
20
|
/** @deprecated Import from `zudoku/hooks` instead */
|
|
71
|
-
export
|
|
72
|
-
invalidateCache: (key: "API_IDENTITIES") => Promise<void>;
|
|
73
|
-
};
|
|
21
|
+
export { CACHE_KEYS, useCache } from "./cache.js";
|
|
74
22
|
/** @deprecated Import from `zudoku/hooks` instead */
|
|
75
|
-
export
|
|
76
|
-
API_IDENTITIES: string[];
|
|
77
|
-
}>;
|
|
78
|
-
/** @deprecated Import from `zudoku/hooks` instead */
|
|
79
|
-
export declare const useTheme: () => import("next-themes").UseThemeProps;
|
|
23
|
+
export { useZudoku } from "./context/ZudokuContext.js";
|
|
@@ -1,42 +1,25 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
import { Spinner as SpinnerImport } from "./Spinner.js";
|
|
16
|
-
import { Typography as TypographyImport } from "./Typography.js";
|
|
17
|
-
import { Zudoku as ZudokuImport } from "./Zudoku.js";
|
|
18
|
-
export const Head = /*@__PURE__*/ Helmet;
|
|
19
|
-
export const Heading = /*@__PURE__*/ HeadingImport;
|
|
20
|
-
export const Callout = /*@__PURE__*/ CalloutImport;
|
|
21
|
-
export const Markdown = /*@__PURE__*/ MarkdownImport;
|
|
22
|
-
export const Spinner = /*@__PURE__*/ SpinnerImport;
|
|
23
|
-
export const ClientOnly = /*@__PURE__*/ ClientOnlyImport;
|
|
24
|
-
export const Button = /*@__PURE__*/ ButtonImport;
|
|
25
|
-
export const Link = /*@__PURE__*/ LinkImport;
|
|
26
|
-
export const Zudoku = /*@__PURE__*/ ZudokuImport;
|
|
27
|
-
export const Typography = /*@__PURE__*/ TypographyImport;
|
|
28
|
-
export const Slot = /*@__PURE__*/ SlotImport;
|
|
29
|
-
export const ZudokuError = /*@__PURE__*/ ZudokuErrorImport;
|
|
1
|
+
export { Helmet as Head } from "@zudoku/react-helmet-async";
|
|
2
|
+
export { Link } from "react-router";
|
|
3
|
+
export { Button } from "../ui/Button.js";
|
|
4
|
+
export { Callout } from "../ui/Callout.js";
|
|
5
|
+
export { ZudokuError } from "../util/invariant.js";
|
|
6
|
+
export { ClientOnly } from "./ClientOnly.js";
|
|
7
|
+
export { Heading } from "./Heading.js";
|
|
8
|
+
export { Markdown } from "./Markdown.js";
|
|
9
|
+
export { Search } from "./Search.js";
|
|
10
|
+
export { Slot } from "./Slot.js";
|
|
11
|
+
export { Spinner } from "./Spinner.js";
|
|
12
|
+
export { Typography } from "./Typography.js";
|
|
13
|
+
export { Zudoku } from "./Zudoku.js";
|
|
14
|
+
//
|
|
30
15
|
/** @deprecated Import from `zudoku/hooks` instead */
|
|
31
|
-
export
|
|
16
|
+
export { useMDXComponents } from "@mdx-js/react";
|
|
32
17
|
/** @deprecated Import from `zudoku/hooks` instead */
|
|
33
|
-
export
|
|
18
|
+
export { useTheme } from "next-themes";
|
|
34
19
|
/** @deprecated Import from `zudoku/hooks` instead */
|
|
35
|
-
export
|
|
20
|
+
export { useAuth } from "../authentication/hook.js";
|
|
36
21
|
/** @deprecated Import from `zudoku/hooks` instead */
|
|
37
|
-
export
|
|
22
|
+
export { CACHE_KEYS, useCache } from "./cache.js";
|
|
38
23
|
/** @deprecated Import from `zudoku/hooks` instead */
|
|
39
|
-
export
|
|
40
|
-
/** @deprecated Import from `zudoku/hooks` instead */
|
|
41
|
-
export const useTheme = /*@__PURE__*/ useThemeImport;
|
|
24
|
+
export { useZudoku } from "./context/ZudokuContext.js";
|
|
42
25
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/lib/components/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/lib/components/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,IAAI,IAAI,EAAE,MAAM,4BAA4B,CAAC;AAC5D,OAAO,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AACpC,OAAO,EAAE,MAAM,EAAE,MAAM,iBAAiB,CAAC;AACzC,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAC3C,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AACnD,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AACzC,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AACjC,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAErC,EAAE;AAEF,qDAAqD;AACrD,OAAO,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AACjD,qDAAqD;AACrD,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,qDAAqD;AACrD,OAAO,EAAE,OAAO,EAAE,MAAM,2BAA2B,CAAC;AACpD,qDAAqD;AACrD,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAClD,qDAAqD;AACrD,OAAO,EAAE,SAAS,EAAE,MAAM,4BAA4B,CAAC"}
|
|
@@ -3,10 +3,11 @@ import type { ReactNode } from "react";
|
|
|
3
3
|
import type { Location, RouteObject } from "react-router";
|
|
4
4
|
import type { Navigation } from "../../config/validators/NavigationSchema.js";
|
|
5
5
|
import type { ProtectedRoutesInput } from "../../config/validators/ProtectedRoutesSchema.js";
|
|
6
|
+
import type { ZudokuConfig } from "../../config/validators/validate.js";
|
|
6
7
|
import type { AuthenticationPlugin } from "../authentication/authentication.js";
|
|
7
8
|
import type { MdxComponentsType } from "../util/MdxComponents.js";
|
|
8
9
|
import type { ApiIdentity, ZudokuContext, ZudokuEvents } from "./ZudokuContext.js";
|
|
9
|
-
export type ZudokuPlugin = CommonPlugin | ProfileMenuPlugin | NavigationPlugin | ApiIdentityPlugin | SearchProviderPlugin | EventConsumerPlugin | AuthenticationPlugin;
|
|
10
|
+
export type ZudokuPlugin = CommonPlugin | ProfileMenuPlugin | NavigationPlugin | ApiIdentityPlugin | SearchProviderPlugin | EventConsumerPlugin | AuthenticationPlugin | TransformConfigPlugin;
|
|
10
11
|
export type { AuthenticationPlugin, RouteObject };
|
|
11
12
|
export interface NavigationPlugin {
|
|
12
13
|
getRoutes: () => RouteObject[];
|
|
@@ -35,6 +36,14 @@ export type ProfileNavigationItem = {
|
|
|
35
36
|
children?: ProfileNavigationItem[];
|
|
36
37
|
icon?: LucideIcon;
|
|
37
38
|
};
|
|
39
|
+
export interface ConfigHookContext {
|
|
40
|
+
mode: typeof process.env.ZUDOKU_ENV;
|
|
41
|
+
rootDir: string;
|
|
42
|
+
configPath: string;
|
|
43
|
+
}
|
|
44
|
+
export interface TransformConfigPlugin {
|
|
45
|
+
transformConfig?: (config: ZudokuConfig, ctx: ConfigHookContext) => Partial<ZudokuConfig> | void | Promise<Partial<ZudokuConfig> | void>;
|
|
46
|
+
}
|
|
38
47
|
export interface CommonPlugin {
|
|
39
48
|
initialize?: (context: ZudokuContext) => Promise<void | boolean> | void | boolean;
|
|
40
49
|
getHead?: (args: {
|
|
@@ -56,3 +65,4 @@ export declare const needsInitialization: (obj: ZudokuPlugin) => obj is CommonPl
|
|
|
56
65
|
export declare const hasHead: (obj: ZudokuPlugin) => obj is CommonPlugin;
|
|
57
66
|
export declare const isMdxProviderPlugin: (obj: ZudokuPlugin) => obj is CommonPlugin;
|
|
58
67
|
export declare const isApiIdentityPlugin: (obj: ZudokuPlugin) => obj is ApiIdentityPlugin;
|
|
68
|
+
export declare const isTransformConfigPlugin: (obj: ZudokuPlugin) => obj is TransformConfigPlugin;
|
package/dist/lib/core/plugins.js
CHANGED
|
@@ -9,4 +9,5 @@ export const needsInitialization = (obj) => "initialize" in obj && typeof obj.in
|
|
|
9
9
|
export const hasHead = (obj) => "getHead" in obj && typeof obj.getHead === "function";
|
|
10
10
|
export const isMdxProviderPlugin = (obj) => "getMdxComponents" in obj && typeof obj.getMdxComponents === "function";
|
|
11
11
|
export const isApiIdentityPlugin = (obj) => "getIdentities" in obj && typeof obj.getIdentities === "function";
|
|
12
|
+
export const isTransformConfigPlugin = (obj) => "transformConfig" in obj && typeof obj.transformConfig === "function";
|
|
12
13
|
//# sourceMappingURL=plugins.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plugins.js","sourceRoot":"","sources":["../../../src/lib/core/plugins.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"plugins.js","sourceRoot":"","sources":["../../../src/lib/core/plugins.ts"],"names":[],"mappings":"AAgCA,MAAM,CAAC,MAAM,uBAAuB,GAAG,CACrC,MAAyB,EACN,EAAE,CAAC,MAAM,CAAC;AAE/B,MAAM,CAAC,MAAM,uBAAuB,GAAG,CACrC,MAAyB,EACN,EAAE,CAAC,MAAM,CAAC;AAmD/B,MAAM,CAAC,MAAM,qBAAqB,GAAG,CACnC,GAAiB,EACW,EAAE,CAC9B,QAAQ,IAAI,GAAG,IAAI,OAAO,GAAG,CAAC,MAAM,KAAK,QAAQ,CAAC;AAEpD,MAAM,CAAC,MAAM,mBAAmB,GAAG,CACjC,GAAiB,EACS,EAAE,CAC5B,qBAAqB,IAAI,GAAG,IAAI,OAAO,GAAG,CAAC,mBAAmB,KAAK,UAAU,CAAC;AAEhF,MAAM,CAAC,MAAM,kBAAkB,GAAG,CAChC,GAAiB,EACQ,EAAE,CAC3B,WAAW,IAAI,GAAG,IAAI,OAAO,GAAG,CAAC,SAAS,KAAK,UAAU,CAAC;AAE5D,MAAM,CAAC,MAAM,sBAAsB,GAAG,CACpC,GAAiB,EACY,EAAE,CAC/B,QAAQ,IAAI,GAAG,IAAI,OAAO,GAAG,CAAC,MAAM,KAAK,UAAU,CAAC;AAEtD,MAAM,CAAC,MAAM,cAAc,GAAG,CAC5B,GAAiB,EACY,EAAE,CAC/B,cAAc,IAAI,GAAG,IAAI,OAAO,GAAG,CAAC,YAAY,KAAK,UAAU,CAAC;AAElE,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC,GAAiB,EAAuB,EAAE,CAC5E,YAAY,IAAI,GAAG,IAAI,OAAO,GAAG,CAAC,UAAU,KAAK,UAAU,CAAC;AAE9D,MAAM,CAAC,MAAM,OAAO,GAAG,CAAC,GAAiB,EAAuB,EAAE,CAChE,SAAS,IAAI,GAAG,IAAI,OAAO,GAAG,CAAC,OAAO,KAAK,UAAU,CAAC;AAExD,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC,GAAiB,EAAuB,EAAE,CAC5E,kBAAkB,IAAI,GAAG,IAAI,OAAO,GAAG,CAAC,gBAAgB,KAAK,UAAU,CAAC;AAE1E,MAAM,CAAC,MAAM,mBAAmB,GAAG,CACjC,GAAiB,EACS,EAAE,CAC5B,eAAe,IAAI,GAAG,IAAI,OAAO,GAAG,CAAC,aAAa,KAAK,UAAU,CAAC;AAEpE,MAAM,CAAC,MAAM,uBAAuB,GAAG,CACrC,GAAiB,EACa,EAAE,CAChC,iBAAiB,IAAI,GAAG,IAAI,OAAO,GAAG,CAAC,eAAe,KAAK,UAAU,CAAC"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import createDeepmerge from "@fastify/deepmerge";
|
|
2
|
+
import { isTransformConfigPlugin } from "./plugins.js";
|
|
3
|
+
const mergeConfig = createDeepmerge({
|
|
4
|
+
mergeArray: (opt) => (_, source) => opt.clone(source),
|
|
5
|
+
});
|
|
6
|
+
export const runTransformConfigHooks = async (config) => {
|
|
7
|
+
const ctx = {
|
|
8
|
+
mode: config.__meta.mode,
|
|
9
|
+
rootDir: config.__meta.rootDir,
|
|
10
|
+
configPath: config.__meta.configPath,
|
|
11
|
+
};
|
|
12
|
+
const plugins = config.plugins ?? [];
|
|
13
|
+
let result = config;
|
|
14
|
+
for (const plugin of plugins.filter(isTransformConfigPlugin)) {
|
|
15
|
+
const partial = await plugin.transformConfig?.(result, ctx);
|
|
16
|
+
if (!partial)
|
|
17
|
+
continue;
|
|
18
|
+
result = mergeConfig(result, partial);
|
|
19
|
+
}
|
|
20
|
+
return result;
|
|
21
|
+
};
|
|
22
|
+
//# sourceMappingURL=transform-config.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"transform-config.js","sourceRoot":"","sources":["../../../src/lib/core/transform-config.ts"],"names":[],"mappings":"AAAA,OAAO,eAAe,MAAM,oBAAoB,CAAC;AAEjD,OAAO,EAA0B,uBAAuB,EAAE,MAAM,cAAc,CAAC;AAE/E,MAAM,WAAW,GAAG,eAAe,CAAC;IAClC,UAAU,EAAE,CAAC,GAAG,EAAE,EAAE,CAAC,CAAC,CAAC,EAAE,MAAM,EAAE,EAAE,CAAC,GAAG,CAAC,KAAK,CAAC,MAAM,CAAC;CACtD,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,uBAAuB,GAAG,KAAK,EAC1C,MAAsB,EACG,EAAE;IAC3B,MAAM,GAAG,GAAG;QACV,IAAI,EAAE,MAAM,CAAC,MAAM,CAAC,IAAI;QACxB,OAAO,EAAE,MAAM,CAAC,MAAM,CAAC,OAAO;QAC9B,UAAU,EAAE,MAAM,CAAC,MAAM,CAAC,UAAU;KACT,CAAC;IAC9B,MAAM,OAAO,GAAG,MAAM,CAAC,OAAO,IAAI,EAAE,CAAC;IAErC,IAAI,MAAM,GAAG,MAAM,CAAC;IAEpB,KAAK,MAAM,MAAM,IAAI,OAAO,CAAC,MAAM,CAAC,uBAAuB,CAAC,EAAE,CAAC;QAC7D,MAAM,OAAO,GAAG,MAAM,MAAM,CAAC,eAAe,EAAE,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;QAC5D,IAAI,CAAC,OAAO;YAAE,SAAS;QAEvB,MAAM,GAAG,WAAW,CAAC,MAAM,EAAE,OAAO,CAAmB,CAAC;IAC1D,CAAC;IAED,OAAO,MAAM,CAAC;AAChB,CAAC,CAAC"}
|
|
@@ -1,30 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
export
|
|
5
|
-
export
|
|
6
|
-
export
|
|
7
|
-
export
|
|
8
|
-
export declare const useAuth: () => {
|
|
9
|
-
login: (options?: import("../authentication/authentication.js").AuthActionOptions) => Promise<void>;
|
|
10
|
-
logout: () => Promise<void>;
|
|
11
|
-
signup: (options?: import("../authentication/authentication.js").AuthActionOptions) => Promise<void>;
|
|
12
|
-
supportsEmailVerification: boolean;
|
|
13
|
-
requestEmailVerification: (options?: import("../authentication/authentication.js").AuthActionOptions) => Promise<void>;
|
|
14
|
-
isAuthenticated: boolean;
|
|
15
|
-
isPending: boolean;
|
|
16
|
-
profile: import("../authentication/state.js").UserProfile | null;
|
|
17
|
-
providerData: unknown;
|
|
18
|
-
setAuthenticationPending: () => void;
|
|
19
|
-
setLoggedOut: () => void;
|
|
20
|
-
setLoggedIn: ({ profile, providerData, }: {
|
|
21
|
-
profile: import("../authentication/state.js").UserProfile;
|
|
22
|
-
providerData: unknown;
|
|
23
|
-
}) => void;
|
|
24
|
-
isAuthEnabled: boolean;
|
|
25
|
-
};
|
|
26
|
-
export declare const useZudoku: () => import("../core/ZudokuContext.js").ZudokuContext;
|
|
27
|
-
export declare const useCache: () => {
|
|
28
|
-
invalidateCache: (key: "API_IDENTITIES") => Promise<void>;
|
|
29
|
-
};
|
|
30
|
-
export { CACHE_KEYS };
|
|
1
|
+
export { useMDXComponents } from "@mdx-js/react";
|
|
2
|
+
export { useTheme } from "next-themes";
|
|
3
|
+
export { useAuth } from "../authentication/hook.js";
|
|
4
|
+
export { CACHE_KEYS, useCache } from "../components/cache.js";
|
|
5
|
+
export { useZudoku } from "../components/context/ZudokuContext.js";
|
|
6
|
+
export { useExposedProps } from "../util/useExposedProps.js";
|
|
7
|
+
export { useEvent } from "./useEvent.js";
|
package/dist/lib/hooks/index.js
CHANGED
|
@@ -1,16 +1,8 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
export const useEvent = /*@__PURE__*/ useEventImport;
|
|
9
|
-
export const useTheme = /*@__PURE__*/ useThemeImport;
|
|
10
|
-
export const useExposedProps = /*@__PURE__*/ useExposedPropsImport;
|
|
11
|
-
export const useMDXComponents = /*@__PURE__*/ useMDXComponentsImport;
|
|
12
|
-
export const useAuth = /*@__PURE__*/ useAuthImport;
|
|
13
|
-
export const useZudoku = /*@__PURE__*/ useZudokuImport;
|
|
14
|
-
export const useCache = /*@__PURE__*/ useCacheImport;
|
|
15
|
-
export { CACHE_KEYS };
|
|
1
|
+
export { useMDXComponents } from "@mdx-js/react";
|
|
2
|
+
export { useTheme } from "next-themes";
|
|
3
|
+
export { useAuth } from "../authentication/hook.js";
|
|
4
|
+
export { CACHE_KEYS, useCache } from "../components/cache.js";
|
|
5
|
+
export { useZudoku } from "../components/context/ZudokuContext.js";
|
|
6
|
+
export { useExposedProps } from "../util/useExposedProps.js";
|
|
7
|
+
export { useEvent } from "./useEvent.js";
|
|
16
8
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/lib/hooks/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/lib/hooks/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AACjD,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EAAE,OAAO,EAAE,MAAM,2BAA2B,CAAC;AACpD,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAC9D,OAAO,EAAE,SAAS,EAAE,MAAM,wCAAwC,CAAC;AACnE,OAAO,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAC;AAC7D,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { GraphQLScalarType } from "graphql/index.js";
|
|
2
2
|
export declare const CIRCULAR_REF = "$[Circular Reference]";
|
|
3
3
|
export declare const SCHEMA_REF_PREFIX = "$ref:";
|
|
4
|
-
export declare const handleCircularRefs: (obj: any,
|
|
4
|
+
export declare const handleCircularRefs: (obj: any, currentPath?: WeakSet<WeakKey>, refs?: WeakMap<WeakKey, any>, path?: string[], currentRefPaths?: Set<string>) => any;
|
|
5
5
|
export declare const GraphQLJSONSchema: GraphQLScalarType<unknown, unknown>;
|