zudoku 0.0.0-e5be921 → 0.0.0-e614aaa
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/cli.js +3 -0
- package/dist/app/demo.js +1 -2
- package/dist/app/demo.js.map +1 -1
- package/dist/app/entry.client.d.ts +5 -0
- package/dist/app/entry.client.js +2 -15
- package/dist/app/entry.client.js.map +1 -1
- package/dist/app/entry.server.d.ts +1 -1
- package/dist/app/entry.server.js +1 -2
- package/dist/app/entry.server.js.map +1 -1
- package/dist/app/main.d.ts +2 -2
- package/dist/app/main.js +19 -9
- package/dist/app/main.js.map +1 -1
- package/dist/app/sentry.js +1 -1
- package/dist/app/sentry.js.map +1 -1
- package/dist/app/standalone.js +1 -2
- package/dist/app/standalone.js.map +1 -1
- package/dist/app/tailwind.js +6 -0
- package/dist/app/tailwind.js.map +1 -1
- package/dist/cli/build/handler.d.ts +1 -3
- package/dist/cli/build/handler.js +7 -0
- package/dist/cli/build/handler.js.map +1 -1
- package/dist/cli/cli.js +5 -0
- package/dist/cli/cli.js.map +1 -1
- package/dist/cli/cmds/build.d.ts +11 -3
- package/dist/cli/cmds/build.js +21 -13
- package/dist/cli/cmds/build.js.map +1 -1
- package/dist/cli/cmds/dev.js +5 -0
- package/dist/cli/cmds/dev.js.map +1 -1
- package/dist/cli/cmds/preview.d.ts +16 -0
- package/dist/cli/cmds/preview.js +25 -0
- package/dist/cli/cmds/preview.js.map +1 -0
- package/dist/cli/common/output.js.map +1 -1
- 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.d.ts +1 -0
- package/dist/cli/dev/handler.js +14 -12
- package/dist/cli/dev/handler.js.map +1 -1
- package/dist/cli/preview/handler.d.ts +3 -0
- package/dist/cli/preview/handler.js +37 -0
- package/dist/cli/preview/handler.js.map +1 -0
- package/dist/config/common.d.ts +5 -2
- package/dist/config/config.d.ts +3 -7
- package/dist/config/loader.d.ts +4 -4
- package/dist/config/loader.js +11 -5
- package/dist/config/loader.js.map +1 -1
- package/dist/config/validators/InputSidebarSchema.d.ts +32 -17
- package/dist/config/validators/InputSidebarSchema.js +11 -1
- package/dist/config/validators/InputSidebarSchema.js.map +1 -1
- package/dist/config/validators/common.d.ts +821 -194
- package/dist/config/validators/common.js +71 -16
- package/dist/config/validators/common.js.map +1 -1
- package/dist/config/validators/icon-types.d.ts +1 -1
- package/dist/config/validators/validate.d.ts +378 -131
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- 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/authentication/components/CallbackHandler.js +1 -1
- package/dist/lib/authentication/components/CallbackHandler.js.map +1 -1
- package/dist/lib/authentication/components/SignIn.js +1 -1
- package/dist/lib/authentication/components/SignIn.js.map +1 -1
- package/dist/lib/authentication/components/SignOut.js +2 -2
- package/dist/lib/authentication/components/SignOut.js.map +1 -1
- package/dist/lib/authentication/providers/auth0.d.ts +2 -2
- package/dist/lib/authentication/providers/auth0.js +2 -1
- package/dist/lib/authentication/providers/auth0.js.map +1 -1
- package/dist/lib/authentication/providers/clerk.js +35 -12
- package/dist/lib/authentication/providers/clerk.js.map +1 -1
- package/dist/lib/authentication/providers/openid.d.ts +11 -3
- package/dist/lib/authentication/providers/openid.js +17 -9
- package/dist/lib/authentication/providers/openid.js.map +1 -1
- package/dist/lib/authentication/state.d.ts +9 -0
- package/dist/lib/authentication/state.js +19 -2
- package/dist/lib/authentication/state.js.map +1 -1
- package/dist/lib/components/AnchorLink.d.ts +1 -1
- package/dist/lib/components/AnchorLink.js +6 -3
- package/dist/lib/components/AnchorLink.js.map +1 -1
- package/dist/lib/components/Autocomplete.d.ts +13 -0
- package/dist/lib/components/Autocomplete.js +47 -0
- package/dist/lib/components/Autocomplete.js.map +1 -0
- package/dist/lib/components/Banner.js +1 -1
- package/dist/lib/components/Banner.js.map +1 -1
- package/dist/lib/components/Bootstrap.d.ts +1 -2
- package/dist/lib/components/Bootstrap.js +3 -3
- package/dist/lib/components/Bootstrap.js.map +1 -1
- package/dist/lib/components/Header.js +15 -15
- package/dist/lib/components/Header.js.map +1 -1
- package/dist/lib/components/Heading.d.ts +2 -2
- package/dist/lib/components/Layout.js +2 -2
- package/dist/lib/components/Layout.js.map +1 -1
- package/dist/lib/components/Markdown.d.ts +2 -2
- package/dist/lib/components/Markdown.js +3 -1
- package/dist/lib/components/Markdown.js.map +1 -1
- package/dist/lib/components/MobileTopNavigation.js +1 -1
- package/dist/lib/components/NotFoundPage.js +1 -1
- package/dist/lib/components/NotFoundPage.js.map +1 -1
- package/dist/lib/components/PathRenderer.d.ts +11 -0
- package/dist/lib/components/PathRenderer.js +28 -0
- package/dist/lib/components/PathRenderer.js.map +1 -0
- package/dist/lib/components/SlotletProvider.d.ts +2 -2
- package/dist/lib/components/StatusPage.d.ts +7 -0
- package/dist/lib/components/StatusPage.js +71 -0
- package/dist/lib/components/StatusPage.js.map +1 -0
- package/dist/lib/components/ThemeSwitch.js +8 -5
- package/dist/lib/components/ThemeSwitch.js.map +1 -1
- package/dist/lib/components/TopNavigation.js +5 -4
- package/dist/lib/components/TopNavigation.js.map +1 -1
- package/dist/lib/components/Zudoku.d.ts +1 -1
- package/dist/lib/components/Zudoku.js +8 -7
- package/dist/lib/components/Zudoku.js.map +1 -1
- package/dist/lib/components/cache.d.ts +6 -0
- package/dist/lib/components/cache.js +13 -0
- package/dist/lib/components/cache.js.map +1 -0
- package/dist/lib/components/context/RouterEventsEmitter.d.ts +1 -0
- package/dist/lib/components/context/RouterEventsEmitter.js +17 -0
- package/dist/lib/components/context/RouterEventsEmitter.js.map +1 -0
- package/dist/lib/components/context/ViewportAnchorContext.js +16 -4
- package/dist/lib/components/context/ViewportAnchorContext.js.map +1 -1
- package/dist/lib/components/context/ZudokuContext.d.ts +1 -1
- package/dist/lib/components/context/ZudokuContext.js +11 -4
- package/dist/lib/components/context/ZudokuContext.js.map +1 -1
- package/dist/lib/components/index.d.ts +32 -15
- package/dist/lib/components/index.js +17 -4
- package/dist/lib/components/index.js.map +1 -1
- package/dist/lib/components/navigation/Sidebar.js +7 -2
- package/dist/lib/components/navigation/Sidebar.js.map +1 -1
- package/dist/lib/components/navigation/SidebarBadge.d.ts +6 -3
- package/dist/lib/components/navigation/SidebarBadge.js +13 -11
- package/dist/lib/components/navigation/SidebarBadge.js.map +1 -1
- package/dist/lib/components/navigation/SidebarCategory.js +18 -16
- package/dist/lib/components/navigation/SidebarCategory.js.map +1 -1
- package/dist/lib/components/navigation/SidebarItem.js +4 -3
- package/dist/lib/components/navigation/SidebarItem.js.map +1 -1
- package/dist/lib/components/navigation/SidebarWrapper.js +1 -1
- package/dist/lib/components/navigation/SidebarWrapper.js.map +1 -1
- package/dist/lib/components/navigation/utils.js +1 -1
- package/dist/lib/components/navigation/utils.js.map +1 -1
- package/dist/lib/core/RouteGuard.d.ts +1 -0
- package/dist/lib/core/RouteGuard.js +45 -0
- package/dist/lib/core/RouteGuard.js.map +1 -0
- package/dist/lib/core/ZudokuContext.d.ts +15 -3
- package/dist/lib/core/ZudokuContext.js +26 -8
- package/dist/lib/core/ZudokuContext.js.map +1 -1
- package/dist/lib/core/plugins.d.ts +13 -7
- package/dist/lib/core/plugins.js +3 -0
- package/dist/lib/core/plugins.js.map +1 -1
- package/dist/lib/errors/RouterError.js +1 -1
- package/dist/lib/errors/RouterError.js.map +1 -1
- package/dist/lib/hooks/index.d.ts +3 -0
- package/dist/lib/hooks/index.js +5 -0
- package/dist/lib/hooks/index.js.map +1 -0
- package/dist/lib/hooks/useEvent.d.ts +11 -0
- package/dist/lib/hooks/useEvent.js +19 -0
- package/dist/lib/hooks/useEvent.js.map +1 -0
- package/dist/lib/hooks/useEvent.test.d.ts +1 -0
- package/dist/lib/hooks/useEvent.test.js +100 -0
- package/dist/lib/hooks/useEvent.test.js.map +1 -0
- 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/circular.d.ts +3 -0
- package/dist/lib/oas/graphql/circular.js +38 -0
- package/dist/lib/oas/graphql/circular.js.map +1 -0
- package/dist/lib/oas/graphql/index.d.ts +11 -0
- package/dist/lib/oas/graphql/index.js +93 -59
- package/dist/lib/oas/graphql/index.js.map +1 -1
- package/dist/lib/oas/parser/dereference/index.js +6 -3
- package/dist/lib/oas/parser/dereference/index.js.map +1 -1
- package/dist/lib/oas/parser/upgrade/index.js +19 -4
- package/dist/lib/oas/parser/upgrade/index.js.map +1 -1
- package/dist/lib/plugins/api-catalog/Catalog.d.ts +3 -5
- package/dist/lib/plugins/api-catalog/Catalog.js +23 -26
- package/dist/lib/plugins/api-catalog/Catalog.js.map +1 -1
- package/dist/lib/plugins/api-catalog/index.d.ts +9 -1
- package/dist/lib/plugins/api-catalog/index.js +37 -8
- package/dist/lib/plugins/api-catalog/index.js.map +1 -1
- package/dist/lib/plugins/api-keys/CreateApiKey.js +8 -4
- package/dist/lib/plugins/api-keys/CreateApiKey.js.map +1 -1
- package/dist/lib/plugins/api-keys/ProtectedRoute.js +1 -1
- package/dist/lib/plugins/api-keys/ProtectedRoute.js.map +1 -1
- package/dist/lib/plugins/api-keys/SettingsApiKeys.js +1 -1
- package/dist/lib/plugins/api-keys/SettingsApiKeys.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/markdown/MdxPage.js +8 -2
- package/dist/lib/plugins/markdown/MdxPage.js.map +1 -1
- package/dist/lib/plugins/markdown/index.d.ts +1 -0
- package/dist/lib/plugins/markdown/index.js.map +1 -1
- package/dist/lib/plugins/markdown/resolver.d.ts +0 -6
- package/dist/lib/plugins/markdown/resolver.js +0 -29
- package/dist/lib/plugins/markdown/resolver.js.map +1 -1
- package/dist/lib/plugins/openapi/CollapsibleCode.js +2 -1
- package/dist/lib/plugins/openapi/CollapsibleCode.js.map +1 -1
- package/dist/lib/plugins/openapi/ColorizedParam.d.ts +10 -2
- package/dist/lib/plugins/openapi/ColorizedParam.js +18 -7
- package/dist/lib/plugins/openapi/ColorizedParam.js.map +1 -1
- package/dist/lib/plugins/openapi/Endpoint.d.ts +1 -1
- package/dist/lib/plugins/openapi/Endpoint.js +8 -7
- package/dist/lib/plugins/openapi/Endpoint.js.map +1 -1
- package/dist/lib/plugins/openapi/OasProvider.d.ts +8 -0
- package/dist/lib/plugins/openapi/OasProvider.js +29 -0
- package/dist/lib/plugins/openapi/OasProvider.js.map +1 -0
- package/dist/lib/plugins/openapi/OperationList.d.ts +5 -2
- package/dist/lib/plugins/openapi/OperationList.js +39 -49
- package/dist/lib/plugins/openapi/OperationList.js.map +1 -1
- package/dist/lib/plugins/openapi/OperationListItem.d.ts +4 -2
- package/dist/lib/plugins/openapi/OperationListItem.js +16 -5
- package/dist/lib/plugins/openapi/OperationListItem.js.map +1 -1
- package/dist/lib/plugins/openapi/ParameterList.d.ts +2 -1
- package/dist/lib/plugins/openapi/ParameterList.js +3 -2
- package/dist/lib/plugins/openapi/ParameterList.js.map +1 -1
- package/dist/lib/plugins/openapi/ParameterListItem.js +3 -2
- package/dist/lib/plugins/openapi/ParameterListItem.js.map +1 -1
- package/dist/lib/plugins/openapi/PlaygroundDialogWrapper.d.ts +4 -2
- package/dist/lib/plugins/openapi/PlaygroundDialogWrapper.js +10 -3
- package/dist/lib/plugins/openapi/PlaygroundDialogWrapper.js.map +1 -1
- package/dist/lib/plugins/openapi/RequestBodySidecarBox.d.ts +3 -4
- package/dist/lib/plugins/openapi/RequestBodySidecarBox.js +5 -13
- package/dist/lib/plugins/openapi/RequestBodySidecarBox.js.map +1 -1
- package/dist/lib/plugins/openapi/ResponsesSidecarBox.js +7 -13
- package/dist/lib/plugins/openapi/ResponsesSidecarBox.js.map +1 -1
- package/dist/lib/plugins/openapi/Sidecar.js +22 -34
- package/dist/lib/plugins/openapi/Sidecar.js.map +1 -1
- package/dist/lib/plugins/openapi/SidecarBox.js +4 -4
- package/dist/lib/plugins/openapi/SidecarBox.js.map +1 -1
- package/dist/lib/plugins/openapi/SidecarExamples.d.ts +9 -0
- package/dist/lib/plugins/openapi/SidecarExamples.js +68 -0
- package/dist/lib/plugins/openapi/SidecarExamples.js.map +1 -0
- package/dist/lib/plugins/openapi/client/GraphQLClient.d.ts +1 -1
- package/dist/lib/plugins/openapi/client/GraphQLClient.js +22 -93
- package/dist/lib/plugins/openapi/client/GraphQLClient.js.map +1 -1
- package/dist/lib/plugins/openapi/client/createServer.d.ts +2 -1
- package/dist/lib/plugins/openapi/client/createServer.js +5 -2
- package/dist/lib/plugins/openapi/client/createServer.js.map +1 -1
- package/dist/lib/plugins/openapi/client/useCreateQuery.d.ts +1 -1
- package/dist/lib/plugins/openapi/client/useCreateQuery.js +2 -4
- package/dist/lib/plugins/openapi/client/useCreateQuery.js.map +1 -1
- package/dist/lib/plugins/openapi/context.d.ts +3 -3
- package/dist/lib/plugins/openapi/graphql/gql.d.ts +6 -2
- package/dist/lib/plugins/openapi/graphql/gql.js +3 -13
- package/dist/lib/plugins/openapi/graphql/gql.js.map +1 -1
- package/dist/lib/plugins/openapi/graphql/graphql.d.ts +66 -29
- package/dist/lib/plugins/openapi/graphql/graphql.js +33 -15
- package/dist/lib/plugins/openapi/graphql/graphql.js.map +1 -1
- package/dist/lib/plugins/openapi/index.d.ts +10 -1
- package/dist/lib/plugins/openapi/index.js +84 -84
- package/dist/lib/plugins/openapi/index.js.map +1 -1
- package/dist/lib/plugins/openapi/interfaces.d.ts +29 -2
- package/dist/lib/plugins/openapi/playground/ExamplesDropdown.d.ts +6 -0
- package/dist/lib/plugins/openapi/playground/ExamplesDropdown.js +12 -0
- package/dist/lib/plugins/openapi/playground/ExamplesDropdown.js.map +1 -0
- package/dist/lib/plugins/openapi/playground/Headers.d.ts +4 -4
- package/dist/lib/plugins/openapi/playground/Headers.js +84 -5
- package/dist/lib/plugins/openapi/playground/Headers.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/ParamsGrid.d.ts +9 -0
- package/dist/lib/plugins/openapi/playground/ParamsGrid.js +5 -0
- package/dist/lib/plugins/openapi/playground/ParamsGrid.js.map +1 -0
- package/dist/lib/plugins/openapi/playground/PathParams.d.ts +3 -2
- package/dist/lib/plugins/openapi/playground/PathParams.js +5 -7
- package/dist/lib/plugins/openapi/playground/PathParams.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/Playground.d.ts +26 -2
- package/dist/lib/plugins/openapi/playground/Playground.js +64 -56
- package/dist/lib/plugins/openapi/playground/Playground.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/PlaygroundDialog.js +1 -1
- package/dist/lib/plugins/openapi/playground/PlaygroundDialog.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/QueryParams.js +24 -18
- package/dist/lib/plugins/openapi/playground/QueryParams.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/SubmitButton.d.ts +7 -0
- package/dist/lib/plugins/openapi/playground/SubmitButton.js +22 -0
- package/dist/lib/plugins/openapi/playground/SubmitButton.js.map +1 -0
- package/dist/lib/plugins/openapi/playground/result-panel/RequestTab.d.ts +7 -0
- package/dist/lib/plugins/openapi/playground/result-panel/RequestTab.js +11 -0
- package/dist/lib/plugins/openapi/playground/result-panel/RequestTab.js.map +1 -0
- package/dist/lib/plugins/openapi/playground/result-panel/ResponseTab.d.ts +8 -0
- package/dist/lib/plugins/openapi/playground/result-panel/ResponseTab.js +95 -0
- package/dist/lib/plugins/openapi/playground/result-panel/ResponseTab.js.map +1 -0
- package/dist/lib/plugins/openapi/playground/result-panel/ResultPanel.d.ts +7 -0
- package/dist/lib/plugins/openapi/playground/result-panel/ResultPanel.js +16 -0
- package/dist/lib/plugins/openapi/playground/result-panel/ResultPanel.js.map +1 -0
- package/dist/lib/plugins/openapi/playground/result-panel/convertToTypes.d.ts +10 -0
- package/dist/lib/plugins/openapi/playground/result-panel/convertToTypes.js +32 -0
- package/dist/lib/plugins/openapi/playground/result-panel/convertToTypes.js.map +1 -0
- package/dist/lib/plugins/openapi/playground/result-panel/convertToTypes.test.d.ts +1 -0
- package/dist/lib/plugins/openapi/playground/result-panel/convertToTypes.test.js +56 -0
- package/dist/lib/plugins/openapi/playground/result-panel/convertToTypes.test.js.map +1 -0
- package/dist/lib/plugins/openapi/post-processors/removeExtensions.d.ts +2 -1
- package/dist/lib/plugins/openapi/post-processors/removeExtensions.js +5 -3
- package/dist/lib/plugins/openapi/post-processors/removeExtensions.js.map +1 -1
- package/dist/lib/plugins/openapi/post-processors/removeExtensions.test.js +49 -0
- package/dist/lib/plugins/openapi/post-processors/removeExtensions.test.js.map +1 -1
- package/dist/lib/plugins/openapi/post-processors/removeParameters.d.ts +10 -0
- package/dist/lib/plugins/openapi/post-processors/removeParameters.js +66 -0
- package/dist/lib/plugins/openapi/post-processors/removeParameters.js.map +1 -0
- package/dist/lib/plugins/openapi/post-processors/removeParameters.test.d.ts +1 -0
- package/dist/lib/plugins/openapi/post-processors/removeParameters.test.js +131 -0
- package/dist/lib/plugins/openapi/post-processors/removeParameters.test.js.map +1 -0
- package/dist/lib/plugins/openapi/schema/SchemaPropertyItem.js +37 -0
- package/dist/lib/plugins/openapi/schema/SchemaPropertyItem.js.map +1 -0
- package/dist/lib/plugins/openapi/schema/SchemaView.js +1 -1
- package/dist/lib/plugins/openapi/schema/SchemaView.js.map +1 -1
- package/dist/lib/plugins/openapi/schema/utils.d.ts +1 -0
- package/dist/lib/plugins/openapi/schema/utils.js +2 -0
- package/dist/lib/plugins/openapi/schema/utils.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/generateSchemaExample.js +19 -11
- package/dist/lib/plugins/openapi/util/generateSchemaExample.js.map +1 -1
- 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/lib/plugins/openapi/util/methodToColor.d.ts +20 -0
- package/dist/lib/plugins/openapi/util/methodToColor.js +24 -0
- package/dist/lib/plugins/openapi/util/methodToColor.js.map +1 -0
- package/dist/lib/plugins/openapi/util/sanitizeMarkdownForMetatag.d.ts +1 -0
- package/dist/lib/plugins/openapi/util/sanitizeMarkdownForMetatag.js +27 -0
- package/dist/lib/plugins/openapi/util/sanitizeMarkdownForMetatag.js.map +1 -0
- package/dist/lib/plugins/redirect/index.js +1 -1
- package/dist/lib/plugins/redirect/index.js.map +1 -1
- package/dist/lib/plugins/search-inkeep/index.js +21 -7
- package/dist/lib/plugins/search-inkeep/index.js.map +1 -1
- package/dist/lib/plugins/search-pagefind/PagefindSearch.d.ts +6 -0
- package/dist/lib/plugins/search-pagefind/PagefindSearch.js +67 -0
- package/dist/lib/plugins/search-pagefind/PagefindSearch.js.map +1 -0
- package/dist/lib/plugins/search-pagefind/ResultList.d.ts +7 -0
- package/dist/lib/plugins/search-pagefind/ResultList.js +30 -0
- package/dist/lib/plugins/search-pagefind/ResultList.js.map +1 -0
- package/dist/lib/plugins/search-pagefind/get-results.d.ts +3 -0
- package/dist/lib/plugins/search-pagefind/get-results.js +37 -0
- package/dist/lib/plugins/search-pagefind/get-results.js.map +1 -0
- package/dist/lib/plugins/search-pagefind/index.d.ts +6 -0
- package/dist/lib/plugins/search-pagefind/index.js +9 -0
- package/dist/lib/plugins/search-pagefind/index.js.map +1 -0
- package/dist/lib/plugins/search-pagefind/types.d.ts +85 -0
- package/dist/lib/plugins/search-pagefind/types.js +2 -0
- package/dist/lib/plugins/search-pagefind/types.js.map +1 -0
- package/dist/lib/ui/Badge.d.ts +1 -1
- package/dist/lib/ui/Badge.js +2 -1
- package/dist/lib/ui/Badge.js.map +1 -1
- package/dist/lib/ui/Button.d.ts +1 -1
- package/dist/lib/ui/Card.js +1 -1
- package/dist/lib/ui/Card.js.map +1 -1
- package/dist/lib/ui/Checkbox.d.ts +8 -2
- package/dist/lib/ui/Checkbox.js +13 -1
- package/dist/lib/ui/Checkbox.js.map +1 -1
- package/dist/lib/ui/Command.d.ts +17 -3
- package/dist/lib/ui/Command.js +7 -3
- package/dist/lib/ui/Command.js.map +1 -1
- package/dist/lib/ui/Input.d.ts +1 -2
- package/dist/lib/ui/Input.js.map +1 -1
- package/dist/lib/ui/Select.js +2 -2
- package/dist/lib/ui/Select.js.map +1 -1
- package/dist/lib/ui/Stepper.d.ts +4 -0
- package/dist/lib/ui/Stepper.js +7 -0
- package/dist/lib/ui/Stepper.js.map +1 -0
- package/dist/lib/ui/SyntaxHighlight.d.ts +14 -0
- package/dist/lib/{components → ui}/SyntaxHighlight.js +9 -6
- package/dist/lib/ui/SyntaxHighlight.js.map +1 -0
- package/dist/lib/ui/util.d.ts +2 -0
- package/dist/lib/ui/util.js +3 -0
- package/dist/lib/ui/util.js.map +1 -0
- package/dist/lib/util/MdxComponents.d.ts +19 -17
- package/dist/lib/util/MdxComponents.js +7 -6
- package/dist/lib/util/MdxComponents.js.map +1 -1
- package/dist/lib/util/createVariantComponent.d.ts +2 -2
- package/dist/lib/util/joinUrl.d.ts +1 -0
- package/dist/lib/util/joinUrl.js +40 -0
- package/dist/lib/util/joinUrl.js.map +1 -0
- package/dist/lib/util/joinUrl.test.d.ts +1 -0
- package/dist/lib/util/joinUrl.test.js +43 -0
- package/dist/lib/util/joinUrl.test.js.map +1 -0
- package/dist/lib/util/scrollIntoViewIfNeeded.d.ts +1 -0
- package/dist/lib/util/scrollIntoViewIfNeeded.js +14 -0
- package/dist/lib/util/scrollIntoViewIfNeeded.js.map +1 -0
- package/dist/lib/util/traverse.d.ts +8 -1
- package/dist/lib/util/traverse.js +7 -3
- package/dist/lib/util/traverse.js.map +1 -1
- package/dist/lib/util/useExposedProps.js +1 -1
- package/dist/lib/util/useExposedProps.js.map +1 -1
- package/dist/lib/util/useLatest.d.ts +1 -0
- package/dist/lib/util/useLatest.js +15 -0
- package/dist/lib/util/useLatest.js.map +1 -0
- package/dist/lib/util/useOnScreen.d.ts +1 -1
- package/dist/lib/util/useScrollToAnchor.d.ts +1 -0
- package/dist/lib/util/useScrollToAnchor.js +26 -29
- package/dist/lib/util/useScrollToAnchor.js.map +1 -1
- package/dist/lib/util/useScrollToTop.js +7 -5
- package/dist/lib/util/useScrollToTop.js.map +1 -1
- package/dist/vite/api/schema-codegen.d.ts +12 -0
- package/dist/vite/api/schema-codegen.js +62 -0
- package/dist/vite/api/schema-codegen.js.map +1 -0
- package/dist/vite/api/schema-codegen.test.d.ts +1 -0
- package/dist/vite/api/schema-codegen.test.js +247 -0
- package/dist/vite/api/schema-codegen.test.js.map +1 -0
- package/dist/vite/build.js +41 -25
- package/dist/vite/build.js.map +1 -1
- package/dist/vite/config.d.ts +2 -5
- package/dist/vite/config.js +69 -61
- package/dist/vite/config.js.map +1 -1
- package/dist/vite/config.test.js +5 -1
- package/dist/vite/config.test.js.map +1 -1
- package/dist/vite/css/collect.d.ts +2 -0
- package/dist/vite/css/collect.js +27 -0
- package/dist/vite/css/collect.js.map +1 -0
- package/dist/vite/css/plugin.d.ts +5 -0
- package/dist/vite/css/plugin.js +79 -0
- package/dist/vite/css/plugin.js.map +1 -0
- package/dist/vite/dev-server.d.ts +5 -2
- package/dist/vite/dev-server.js +52 -11
- 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/pagefind.d.ts +4 -0
- package/dist/vite/pagefind.js +15 -0
- package/dist/vite/pagefind.js.map +1 -0
- package/dist/vite/plugin-api-keys.d.ts +2 -2
- package/dist/vite/plugin-api-keys.js +5 -5
- package/dist/vite/plugin-api-keys.js.map +1 -1
- package/dist/vite/plugin-api.d.ts +2 -2
- package/dist/vite/plugin-api.js +175 -59
- package/dist/vite/plugin-api.js.map +1 -1
- package/dist/vite/plugin-auth.d.ts +2 -2
- package/dist/vite/plugin-auth.js +7 -4
- package/dist/vite/plugin-auth.js.map +1 -1
- package/dist/vite/plugin-component.d.ts +2 -2
- package/dist/vite/plugin-component.js +7 -3
- package/dist/vite/plugin-component.js.map +1 -1
- package/dist/vite/plugin-config-reload.d.ts +4 -3
- package/dist/vite/plugin-config-reload.js +11 -5
- package/dist/vite/plugin-config-reload.js.map +1 -1
- package/dist/vite/plugin-config.d.ts +2 -2
- package/dist/vite/plugin-config.js +9 -5
- package/dist/vite/plugin-config.js.map +1 -1
- package/dist/vite/plugin-custom-pages.d.ts +2 -2
- package/dist/vite/plugin-custom-pages.js +3 -3
- package/dist/vite/plugin-custom-pages.js.map +1 -1
- package/dist/vite/plugin-docs.d.ts +2 -2
- package/dist/vite/plugin-docs.js +5 -5
- package/dist/vite/plugin-docs.js.map +1 -1
- package/dist/vite/plugin-frontmatter.d.ts +2 -2
- package/dist/vite/plugin-frontmatter.js +5 -4
- package/dist/vite/plugin-frontmatter.js.map +1 -1
- package/dist/vite/plugin-mdx.d.ts +2 -2
- package/dist/vite/plugin-mdx.js +34 -16
- package/dist/vite/plugin-mdx.js.map +1 -1
- package/dist/vite/plugin-redirect.d.ts +2 -2
- package/dist/vite/plugin-redirect.js +3 -3
- package/dist/vite/plugin-redirect.js.map +1 -1
- package/dist/vite/plugin-search.d.ts +2 -2
- package/dist/vite/plugin-search.js +5 -1
- package/dist/vite/plugin-search.js.map +1 -1
- package/dist/vite/plugin-sidebar.d.ts +2 -2
- package/dist/vite/plugin-sidebar.js +13 -4
- package/dist/vite/plugin-sidebar.js.map +1 -1
- package/dist/vite/plugin-theme-css.d.ts +2 -2
- package/dist/vite/plugin-theme-css.js +57 -2
- package/dist/vite/plugin-theme-css.js.map +1 -1
- package/dist/vite/plugin.d.ts +2 -2
- package/dist/vite/plugin.js +4 -0
- package/dist/vite/plugin.js.map +1 -1
- package/dist/vite/{prerender.d.ts → prerender/FileWritingResponse.d.ts} +8 -9
- package/dist/vite/prerender/FileWritingResponse.js +51 -0
- package/dist/vite/prerender/FileWritingResponse.js.map +1 -0
- package/dist/vite/prerender/prerender.d.ts +14 -0
- package/dist/vite/prerender/prerender.js +84 -0
- package/dist/vite/prerender/prerender.js.map +1 -0
- package/dist/vite/prerender/worker.d.ts +13 -0
- package/dist/vite/prerender/worker.js +32 -0
- package/dist/vite/prerender/worker.js.map +1 -0
- package/dist/vite/reporter.d.ts +3 -0
- package/dist/vite/reporter.js +33 -0
- package/dist/vite/reporter.js.map +1 -0
- package/dist/vite/sitemap.js +2 -1
- package/dist/vite/sitemap.js.map +1 -1
- package/dist/zuplo/enrich-with-zuplo.d.ts +5 -0
- package/dist/zuplo/enrich-with-zuplo.js +184 -0
- package/dist/zuplo/enrich-with-zuplo.js.map +1 -0
- package/dist/zuplo/env.d.ts +1 -0
- package/dist/zuplo/env.js +3 -0
- package/dist/zuplo/env.js.map +1 -1
- package/dist/zuplo/policy-types.d.ts +33 -0
- package/dist/zuplo/policy-types.js +8 -0
- package/dist/zuplo/policy-types.js.map +1 -0
- package/dist/zuplo/with-zuplo-processors.d.ts +3 -0
- package/dist/zuplo/with-zuplo-processors.js +26 -0
- package/dist/zuplo/with-zuplo-processors.js.map +1 -0
- package/dist/zuplo/with-zuplo.d.ts +1 -1
- package/dist/zuplo/with-zuplo.js +7 -26
- package/dist/zuplo/with-zuplo.js.map +1 -1
- package/lib/AuthenticationPlugin-CiO1FM6Q.js +58 -0
- package/lib/AuthenticationPlugin-CiO1FM6Q.js.map +1 -0
- package/lib/{CategoryHeading-Bb9dqxD3.js → CategoryHeading-DpB47wvk.js} +3 -3
- package/lib/{CategoryHeading-Bb9dqxD3.js.map → CategoryHeading-DpB47wvk.js.map} +1 -1
- package/lib/ClientOnly-E7hGysn1.js.map +1 -1
- package/lib/{Dialog-k70Qfukb.js → Dialog-DIKGQxQc.js} +36 -20
- package/lib/{Dialog-k70Qfukb.js.map → Dialog-DIKGQxQc.js.map} +1 -1
- package/lib/{Markdown-CRsmPPfY.js → Markdown-DePfm7oQ.js} +5972 -5888
- package/lib/Markdown-DePfm7oQ.js.map +1 -0
- package/lib/MdxPage-BN6l6zXL.js +201 -0
- package/lib/MdxPage-BN6l6zXL.js.map +1 -0
- package/lib/OasProvider-BSuptFK-.js +34 -0
- package/lib/OasProvider-BSuptFK-.js.map +1 -0
- package/lib/OperationList-DOcfDmJP.js +5217 -0
- package/lib/OperationList-DOcfDmJP.js.map +1 -0
- package/lib/{Select-O9ZM3ZgX.js → Select-Dqtcn53H.js} +49 -49
- package/lib/Select-Dqtcn53H.js.map +1 -0
- package/lib/SlotletProvider-DdtIOUi6.js +221 -0
- package/lib/SlotletProvider-DdtIOUi6.js.map +1 -0
- package/lib/{Button-jK0EsymC.js → Spinner-1KrEmx1V.js} +17 -14
- package/lib/Spinner-1KrEmx1V.js.map +1 -0
- package/lib/chunk-IR6S3I6Y-D_3UmFIn.js +1821 -0
- package/lib/chunk-IR6S3I6Y-D_3UmFIn.js.map +1 -0
- package/lib/circular-v7K6lDDh.js +15409 -0
- package/lib/circular-v7K6lDDh.js.map +1 -0
- package/lib/{cn-BmFQLtkS.js → cn-qaFjX9_3.js} +2 -2
- package/lib/cn-qaFjX9_3.js.map +1 -0
- package/lib/{context-D1nXWxm7.js → context-DLCwaMXN.js} +2 -2
- package/lib/context-DLCwaMXN.js.map +1 -0
- package/lib/createServer-DmusVVsi.js +12728 -0
- package/lib/createServer-DmusVVsi.js.map +1 -0
- package/lib/hook-CN__aZIt.js +1464 -0
- package/lib/hook-CN__aZIt.js.map +1 -0
- package/lib/index-BTbP6Lgf.js +2103 -0
- package/lib/index-BTbP6Lgf.js.map +1 -0
- package/lib/index-CPNSgwSb.js +36 -0
- package/lib/index-CPNSgwSb.js.map +1 -0
- package/lib/{index-CkwDvuPt.js → index-Dl3Yl0yb.js} +303 -286
- package/lib/index-Dl3Yl0yb.js.map +1 -0
- package/lib/index-DwT-v3zK.js +86 -0
- package/lib/index-DwT-v3zK.js.map +1 -0
- package/lib/index-LNp6rxyU.js.map +1 -1
- package/lib/index-gQD2h1wX.js +447 -0
- package/lib/index-gQD2h1wX.js.map +1 -0
- package/lib/index.esm--gIChbWs.js +1207 -0
- package/lib/index.esm--gIChbWs.js.map +1 -0
- package/lib/index.esm-CQHE3GEU.js +691 -0
- package/lib/{index.esm-Bm8pj-bc.js.map → index.esm-CQHE3GEU.js.map} +1 -1
- package/lib/invariant-Caa8-XvF.js.map +1 -1
- package/lib/joinUrl-10po2Jdj.js +20 -0
- package/lib/joinUrl-10po2Jdj.js.map +1 -0
- package/lib/jsx-runtime-CYK1ROHF.js +446 -0
- package/lib/jsx-runtime-CYK1ROHF.js.map +1 -0
- package/lib/{hook-hEqe7fPB.js → mutation-EclmI0is.js} +39 -58
- package/lib/mutation-EclmI0is.js.map +1 -0
- package/lib/objectEntries-yMIkr2mI.js +5 -0
- package/lib/objectEntries-yMIkr2mI.js.map +1 -0
- package/lib/post-processors/removeExtensions.js +7 -7
- package/lib/post-processors/removeExtensions.js.map +1 -1
- package/lib/post-processors/removeParameters.js +48 -0
- package/lib/post-processors/removeParameters.js.map +1 -0
- package/lib/post-processors/removePaths.js.map +1 -1
- package/lib/post-processors/traverse.js +11 -8
- package/lib/post-processors/traverse.js.map +1 -1
- package/lib/{prism-bash.min-DadFsM4Z.js → prism-bash.min-HHIMdNJ_.js} +4 -4
- package/lib/{prism-bash.min-DadFsM4Z.js.map → prism-bash.min-HHIMdNJ_.js.map} +1 -1
- package/lib/prism-csharp.min-bQAo2pmx.js +63 -0
- package/lib/{prism-csharp.min-Yizuc34Y.js.map → prism-csharp.min-bQAo2pmx.js.map} +1 -1
- package/lib/prism-java.min-BpvsOuIa.js +35 -0
- package/lib/{prism-java.min-d5iT_mOd.js.map → prism-java.min-BpvsOuIa.js.map} +1 -1
- package/lib/{prism-markdown.min-F3U-vPBi.js → prism-markdown.min-C0Qn0m-5.js} +30 -30
- package/lib/{prism-markdown.min-F3U-vPBi.js.map → prism-markdown.min-C0Qn0m-5.js.map} +1 -1
- package/lib/prism-markup-BNGj0Tvm.js.map +1 -1
- package/lib/prism-ruby.min-Dx9KO9ds.js +38 -0
- package/lib/{prism-ruby.min-C7LwcKyz.js.map → prism-ruby.min-Dx9KO9ds.js.map} +1 -1
- package/lib/prism-typescript.min-CD7H2IYQ.js +34 -0
- package/lib/{prism-typescript.min-oSVeWCAd.js.map → prism-typescript.min-CD7H2IYQ.js.map} +1 -1
- package/lib/ui/Accordion.js +2 -2
- package/lib/ui/Accordion.js.map +1 -1
- package/lib/ui/ActionButton.js +10 -11
- package/lib/ui/ActionButton.js.map +1 -1
- package/lib/ui/Alert.js +3 -3
- package/lib/ui/Alert.js.map +1 -1
- package/lib/ui/AlertDialog.js +2 -2
- package/lib/ui/AlertDialog.js.map +1 -1
- package/lib/ui/Badge.js +5 -4
- package/lib/ui/Badge.js.map +1 -1
- package/lib/ui/Breadcrumb.js +5 -5
- package/lib/ui/Breadcrumb.js.map +1 -1
- package/lib/ui/Button.js +3 -3
- package/lib/ui/Button.js.map +1 -1
- package/lib/ui/Callout.js +5 -5
- package/lib/ui/Callout.js.map +1 -1
- package/lib/ui/Card.js +9 -9
- package/lib/ui/Card.js.map +1 -1
- package/lib/ui/Carousel.js +408 -402
- package/lib/ui/Carousel.js.map +1 -1
- package/lib/ui/Checkbox.js +26 -15
- package/lib/ui/Checkbox.js.map +1 -1
- package/lib/ui/Command.js +114 -508
- package/lib/ui/Command.js.map +1 -1
- package/lib/ui/Dialog.js +2 -2
- package/lib/ui/Dialog.js.map +1 -1
- package/lib/ui/Drawer.js +357 -378
- package/lib/ui/Drawer.js.map +1 -1
- package/lib/ui/DropdownMenu.js +2 -2
- package/lib/ui/DropdownMenu.js.map +1 -1
- package/lib/ui/Form.js +6 -6
- package/lib/ui/Form.js.map +1 -1
- package/lib/ui/HoverCard.js +2 -2
- package/lib/ui/Input.js +2 -2
- package/lib/ui/Input.js.map +1 -1
- package/lib/ui/Label.js +3 -3
- package/lib/ui/Pagination.js +5 -5
- package/lib/ui/Pagination.js.map +1 -1
- package/lib/ui/Popover.js +2 -2
- package/lib/ui/Popover.js.map +1 -1
- package/lib/ui/Progress.js +2 -2
- package/lib/ui/Progress.js.map +1 -1
- package/lib/ui/RadioGroup.js +2 -2
- package/lib/ui/RadioGroup.js.map +1 -1
- package/lib/ui/ScrollArea.js +2 -2
- package/lib/ui/ScrollArea.js.map +1 -1
- package/lib/ui/Select.js +4 -4
- package/lib/ui/Select.js.map +1 -1
- package/lib/ui/Skeleton.js +2 -2
- package/lib/ui/Skeleton.js.map +1 -1
- package/lib/ui/Slider.js +2 -2
- package/lib/ui/Stepper.js +6 -0
- package/lib/ui/Stepper.js.map +1 -0
- package/lib/ui/Switch.js +2 -2
- package/lib/ui/Switch.js.map +1 -1
- package/lib/{SyntaxHighlight-C31iouiO.js → ui/SyntaxHighlight.js} +460 -536
- package/lib/ui/SyntaxHighlight.js.map +1 -0
- package/lib/ui/Tabs.js +2 -2
- package/lib/ui/Textarea.js +2 -2
- package/lib/ui/Textarea.js.map +1 -1
- package/lib/ui/Toggle.js +3 -3
- package/lib/ui/Toggle.js.map +1 -1
- package/lib/ui/ToggleGroup.js +2 -2
- package/lib/ui/ToggleGroup.js.map +1 -1
- package/lib/ui/Tooltip.js +2 -2
- package/lib/ui/util.js +6 -0
- package/lib/ui/util.js.map +1 -0
- package/lib/useExposedProps-RIvey2Oy.js +9 -0
- package/lib/useExposedProps-RIvey2Oy.js.map +1 -0
- package/lib/useScrollToAnchor-RyqO3lj4.js +290 -0
- package/lib/useScrollToAnchor-RyqO3lj4.js.map +1 -0
- package/lib/zudoku.auth-auth0.js +19 -20
- package/lib/zudoku.auth-auth0.js.map +1 -1
- package/lib/zudoku.auth-clerk.js +81 -53
- package/lib/zudoku.auth-clerk.js.map +1 -1
- package/lib/zudoku.auth-openid.js +379 -410
- package/lib/zudoku.auth-openid.js.map +1 -1
- package/lib/zudoku.components.js +1003 -1263
- package/lib/zudoku.components.js.map +1 -1
- package/lib/zudoku.css +1 -0
- package/lib/zudoku.hooks.js +19 -0
- package/lib/zudoku.hooks.js.map +1 -0
- package/lib/zudoku.icons.js +10 -0
- package/lib/zudoku.icons.js.map +1 -1
- package/lib/zudoku.plugin-api-catalog.js +109 -109
- package/lib/zudoku.plugin-api-catalog.js.map +1 -1
- package/lib/zudoku.plugin-api-keys.js +108 -107
- package/lib/zudoku.plugin-api-keys.js.map +1 -1
- package/lib/zudoku.plugin-custom-pages.js +4 -4
- package/lib/zudoku.plugin-custom-pages.js.map +1 -1
- package/lib/zudoku.plugin-markdown.js +23 -44
- package/lib/zudoku.plugin-markdown.js.map +1 -1
- package/lib/zudoku.plugin-openapi.js +8 -6
- package/lib/zudoku.plugin-openapi.js.map +1 -1
- package/lib/zudoku.plugin-redirect.js +1 -1
- package/lib/zudoku.plugin-redirect.js.map +1 -1
- package/lib/zudoku.plugin-search-inkeep.js +34 -26
- package/lib/zudoku.plugin-search-inkeep.js.map +1 -1
- package/lib/zudoku.plugins.js +14 -0
- package/lib/zudoku.plugins.js.map +1 -0
- package/package.json +104 -89
- package/src/app/demo-cdn.html +31 -31
- package/src/app/demo.tsx +1 -2
- package/src/app/entry.client.tsx +9 -15
- package/src/app/entry.server.tsx +3 -3
- package/src/app/main.css +59 -45
- package/src/app/main.tsx +33 -10
- package/src/app/sentry.ts +1 -1
- package/src/app/standalone.tsx +1 -2
- package/src/app/tailwind.ts +6 -0
- package/src/lib/MissingIcon.tsx +22 -0
- package/src/lib/authentication/components/CallbackHandler.tsx +1 -1
- package/src/lib/authentication/components/SignIn.tsx +1 -1
- package/src/lib/authentication/components/SignOut.tsx +3 -2
- package/src/lib/authentication/providers/auth0.tsx +4 -6
- package/src/lib/authentication/providers/clerk.tsx +48 -13
- package/src/lib/authentication/providers/openid.tsx +32 -15
- package/src/lib/authentication/state.ts +26 -2
- package/src/lib/components/AnchorLink.tsx +6 -3
- package/src/lib/components/Autocomplete.tsx +113 -0
- package/src/lib/components/Banner.tsx +1 -0
- package/src/lib/components/Bootstrap.tsx +4 -6
- package/src/lib/components/Header.tsx +14 -10
- package/src/lib/components/Heading.tsx +1 -1
- package/src/lib/components/Layout.tsx +4 -3
- package/src/lib/components/Markdown.tsx +14 -15
- package/src/lib/components/MobileTopNavigation.tsx +1 -1
- package/src/lib/components/NotFoundPage.tsx +1 -1
- package/src/lib/components/PathRenderer.tsx +61 -0
- package/src/lib/components/SlotletProvider.tsx +1 -1
- package/src/lib/components/StatusPage.tsx +91 -0
- package/src/lib/components/ThemeSwitch.tsx +29 -9
- package/src/lib/components/TopNavigation.tsx +15 -11
- package/src/lib/components/Zudoku.tsx +10 -6
- package/src/lib/components/cache.ts +15 -0
- package/src/lib/components/context/RouterEventsEmitter.tsx +19 -0
- package/src/lib/components/context/ViewportAnchorContext.tsx +20 -6
- package/src/lib/components/context/ZudokuContext.ts +17 -4
- package/src/lib/components/index.ts +22 -5
- package/src/lib/components/navigation/Sidebar.tsx +8 -2
- package/src/lib/components/navigation/SidebarBadge.tsx +17 -12
- package/src/lib/components/navigation/SidebarCategory.tsx +46 -47
- package/src/lib/components/navigation/SidebarItem.tsx +4 -2
- package/src/lib/components/navigation/SidebarWrapper.tsx +3 -2
- package/src/lib/components/navigation/utils.ts +1 -1
- package/src/lib/core/RouteGuard.tsx +73 -0
- package/src/lib/core/ZudokuContext.ts +41 -9
- package/src/lib/core/plugins.ts +27 -9
- package/src/lib/errors/RouterError.tsx +1 -1
- package/src/lib/hooks/index.ts +5 -0
- package/src/lib/hooks/useEvent.test.tsx +149 -0
- package/src/lib/hooks/useEvent.ts +41 -0
- package/src/lib/icons.ts +1 -0
- package/src/lib/oas/graphql/circular.ts +50 -0
- package/src/lib/oas/graphql/index.ts +135 -92
- package/src/lib/oas/parser/dereference/index.ts +8 -4
- package/src/lib/oas/parser/upgrade/index.ts +21 -5
- package/src/lib/plugins/api-catalog/Catalog.tsx +62 -110
- package/src/lib/plugins/api-catalog/index.tsx +69 -9
- package/src/lib/plugins/api-keys/CreateApiKey.tsx +8 -4
- package/src/lib/plugins/api-keys/ProtectedRoute.tsx +1 -1
- package/src/lib/plugins/api-keys/SettingsApiKeys.tsx +1 -1
- package/src/lib/plugins/api-keys/index.tsx +4 -1
- package/src/lib/plugins/custom-pages/index.tsx +1 -1
- package/src/lib/plugins/markdown/MdxPage.tsx +15 -3
- package/src/lib/plugins/markdown/index.tsx +2 -1
- package/src/lib/plugins/markdown/resolver.ts +0 -33
- package/src/lib/plugins/openapi/CollapsibleCode.tsx +10 -7
- package/src/lib/plugins/openapi/ColorizedParam.tsx +29 -12
- package/src/lib/plugins/openapi/Endpoint.tsx +14 -12
- package/src/lib/plugins/openapi/OasProvider.tsx +51 -0
- package/src/lib/plugins/openapi/OperationList.tsx +106 -67
- package/src/lib/plugins/openapi/OperationListItem.tsx +48 -6
- package/src/lib/plugins/openapi/ParameterList.tsx +4 -0
- package/src/lib/plugins/openapi/ParameterListItem.tsx +7 -8
- package/src/lib/plugins/openapi/PlaygroundDialogWrapper.tsx +14 -2
- package/src/lib/plugins/openapi/RequestBodySidecarBox.tsx +15 -38
- package/src/lib/plugins/openapi/ResponsesSidecarBox.tsx +46 -63
- package/src/lib/plugins/openapi/Sidecar.tsx +44 -60
- package/src/lib/plugins/openapi/SidecarBox.tsx +4 -16
- package/src/lib/plugins/openapi/SidecarExamples.tsx +162 -0
- package/src/lib/plugins/openapi/client/GraphQLClient.tsx +28 -120
- package/src/lib/plugins/openapi/client/createServer.ts +6 -2
- package/src/lib/plugins/openapi/client/useCreateQuery.ts +2 -5
- package/src/lib/plugins/openapi/context.tsx +2 -2
- package/src/lib/plugins/openapi/graphql/gql.ts +21 -5
- package/src/lib/plugins/openapi/graphql/graphql.ts +92 -45
- package/src/lib/plugins/openapi/index.tsx +130 -97
- package/src/lib/plugins/openapi/interfaces.ts +27 -2
- package/src/lib/plugins/openapi/playground/ExamplesDropdown.tsx +54 -0
- package/src/lib/plugins/openapi/playground/Headers.tsx +166 -36
- package/src/lib/plugins/openapi/playground/ParamsGrid.tsx +13 -0
- package/src/lib/plugins/openapi/playground/PathParams.tsx +39 -65
- package/src/lib/plugins/openapi/playground/Playground.tsx +288 -235
- package/src/lib/plugins/openapi/playground/PlaygroundDialog.tsx +6 -3
- package/src/lib/plugins/openapi/playground/QueryParams.tsx +87 -88
- package/src/lib/plugins/openapi/playground/SubmitButton.tsx +75 -0
- package/src/lib/plugins/openapi/playground/result-panel/RequestTab.tsx +73 -0
- package/src/lib/plugins/openapi/playground/result-panel/ResponseTab.tsx +210 -0
- package/src/lib/plugins/openapi/playground/result-panel/ResultPanel.tsx +101 -0
- package/src/lib/plugins/openapi/playground/result-panel/convertToTypes.test.ts +64 -0
- package/src/lib/plugins/openapi/playground/result-panel/convertToTypes.ts +36 -0
- package/src/lib/plugins/openapi/post-processors/removeExtensions.test.ts +58 -0
- package/src/lib/plugins/openapi/post-processors/removeExtensions.ts +7 -4
- package/src/lib/plugins/openapi/post-processors/removeParameters.test.ts +148 -0
- package/src/lib/plugins/openapi/post-processors/removeParameters.ts +101 -0
- package/src/lib/plugins/openapi/schema/{SchemaComponents.tsx → SchemaPropertyItem.tsx} +34 -9
- package/src/lib/plugins/openapi/schema/SchemaView.tsx +4 -1
- package/src/lib/plugins/openapi/schema/utils.ts +4 -0
- package/src/lib/plugins/openapi/util/createSidebarCategory.tsx +39 -0
- package/src/lib/plugins/openapi/util/generateSchemaExample.ts +26 -11
- package/src/lib/plugins/openapi/util/getRoutes.tsx +123 -0
- package/src/lib/plugins/openapi/util/methodColorMap.tsx +11 -0
- package/src/lib/plugins/openapi/util/methodToColor.ts +27 -0
- package/src/lib/plugins/openapi/util/sanitizeMarkdownForMetatag.tsx +32 -0
- package/src/lib/plugins/redirect/index.tsx +1 -1
- package/src/lib/plugins/search-inkeep/index.tsx +27 -8
- package/src/lib/plugins/search-pagefind/PagefindSearch.tsx +139 -0
- package/src/lib/plugins/search-pagefind/ResultList.tsx +98 -0
- package/src/lib/plugins/search-pagefind/get-results.tsx +54 -0
- package/src/lib/plugins/search-pagefind/index.tsx +21 -0
- package/src/lib/plugins/search-pagefind/types.ts +118 -0
- package/src/lib/ui/Badge.tsx +2 -1
- package/src/lib/ui/Card.tsx +1 -1
- package/src/lib/ui/Checkbox.tsx +24 -7
- package/src/lib/ui/Command.tsx +45 -3
- package/src/lib/ui/Input.tsx +1 -2
- package/src/lib/ui/Select.tsx +1 -1
- package/src/lib/ui/Stepper.css +43 -0
- package/src/lib/ui/Stepper.tsx +8 -0
- package/src/lib/{components → ui}/SyntaxHighlight.tsx +37 -8
- package/src/lib/ui/util.tsx +3 -0
- package/src/lib/util/MdxComponents.tsx +8 -6
- package/src/lib/util/createVariantComponent.tsx +2 -2
- package/src/lib/util/joinUrl.test.ts +62 -0
- package/src/lib/util/joinUrl.ts +57 -0
- package/src/lib/util/scrollIntoViewIfNeeded.ts +18 -0
- package/src/lib/util/traverse.ts +15 -5
- package/src/lib/util/useExposedProps.tsx +1 -1
- package/src/lib/util/useLatest.ts +18 -0
- package/src/lib/util/useScrollToAnchor.ts +33 -34
- package/src/lib/util/useScrollToTop.ts +9 -4
- package/dist/lib/components/SyntaxHighlight.d.ts +0 -11
- package/dist/lib/components/SyntaxHighlight.js.map +0 -1
- package/dist/lib/plugins/openapi/Route.d.ts +0 -6
- package/dist/lib/plugins/openapi/Route.js +0 -6
- package/dist/lib/plugins/openapi/Route.js.map +0 -1
- package/dist/lib/plugins/openapi/client/worker.d.ts +0 -4
- package/dist/lib/plugins/openapi/client/worker.js +0 -29
- package/dist/lib/plugins/openapi/client/worker.js.map +0 -1
- package/dist/lib/plugins/openapi/playground/ResponseTab.d.ts +0 -4
- package/dist/lib/plugins/openapi/playground/ResponseTab.js +0 -42
- package/dist/lib/plugins/openapi/playground/ResponseTab.js.map +0 -1
- package/dist/lib/plugins/openapi/schema/SchemaComponents.js +0 -28
- package/dist/lib/plugins/openapi/schema/SchemaComponents.js.map +0 -1
- package/dist/lib/plugins/openapi-worker.d.ts +0 -1
- package/dist/lib/plugins/openapi-worker.js +0 -8
- package/dist/lib/plugins/openapi-worker.js.map +0 -1
- package/dist/vite/prerender.js +0 -89
- package/dist/vite/prerender.js.map +0 -1
- package/lib/AnchorLink-BR0MvI7n.js +0 -35
- package/lib/AnchorLink-BR0MvI7n.js.map +0 -1
- package/lib/AuthenticationPlugin-D0Em0SwR.js +0 -59
- package/lib/AuthenticationPlugin-D0Em0SwR.js.map +0 -1
- package/lib/Button-jK0EsymC.js.map +0 -1
- package/lib/Markdown-CRsmPPfY.js.map +0 -1
- package/lib/MdxPage-Wp8QU0-q.js +0 -188
- package/lib/MdxPage-Wp8QU0-q.js.map +0 -1
- package/lib/OperationList-u8xHU9-b.js +0 -4706
- package/lib/OperationList-u8xHU9-b.js.map +0 -1
- package/lib/Route-DlG_HTMu.js +0 -11
- package/lib/Route-DlG_HTMu.js.map +0 -1
- package/lib/Select-O9ZM3ZgX.js.map +0 -1
- package/lib/SidebarBadge-DxFJcJ6V.js +0 -51
- package/lib/SidebarBadge-DxFJcJ6V.js.map +0 -1
- package/lib/SlotletProvider-BgvYIPQe.js +0 -252
- package/lib/SlotletProvider-BgvYIPQe.js.map +0 -1
- package/lib/Spinner-3cQDBVGr.js +0 -7
- package/lib/Spinner-3cQDBVGr.js.map +0 -1
- package/lib/SyntaxHighlight-C31iouiO.js.map +0 -1
- package/lib/__vite-browser-external-BYRIRx8p.js +0 -9
- package/lib/__vite-browser-external-BYRIRx8p.js.map +0 -1
- package/lib/assets/index-B_Jk_Yzp.js +0 -4820
- package/lib/assets/index-B_Jk_Yzp.js.map +0 -1
- package/lib/assets/worker-C_2va8B8.js +0 -18200
- package/lib/assets/worker-C_2va8B8.js.map +0 -1
- package/lib/cn-BmFQLtkS.js.map +0 -1
- package/lib/context-D1nXWxm7.js.map +0 -1
- package/lib/createServer-BCAHdrpE.js +0 -15302
- package/lib/createServer-BCAHdrpE.js.map +0 -1
- package/lib/hook-hEqe7fPB.js.map +0 -1
- package/lib/index-BuAyrJe3.js +0 -46
- package/lib/index-BuAyrJe3.js.map +0 -1
- package/lib/index-CkwDvuPt.js.map +0 -1
- package/lib/index-CmdLGbbk.js +0 -1279
- package/lib/index-CmdLGbbk.js.map +0 -1
- package/lib/index-Czzd9rjU.js +0 -899
- package/lib/index-Czzd9rjU.js.map +0 -1
- package/lib/index-Yn8c3UWE.js +0 -921
- package/lib/index-Yn8c3UWE.js.map +0 -1
- package/lib/index.esm-Bm8pj-bc.js +0 -675
- package/lib/index.esm-C5mr_sKO.js +0 -1193
- package/lib/index.esm-C5mr_sKO.js.map +0 -1
- package/lib/jsx-runtime-B6kdoens.js +0 -635
- package/lib/jsx-runtime-B6kdoens.js.map +0 -1
- package/lib/object_hash-CvlLgU-M.js +0 -785
- package/lib/object_hash-CvlLgU-M.js.map +0 -1
- package/lib/prism-csharp.min-Yizuc34Y.js +0 -35
- package/lib/prism-java.min-d5iT_mOd.js +0 -7
- package/lib/prism-ruby.min-C7LwcKyz.js +0 -10
- package/lib/prism-typescript.min-oSVeWCAd.js +0 -6
- package/lib/router-lfyopgBI.js +0 -3024
- package/lib/router-lfyopgBI.js.map +0 -1
- package/lib/state-tsXBLONe.js +0 -203
- package/lib/state-tsXBLONe.js.map +0 -1
- package/lib/useExposedProps-CTPtylCV.js +0 -10
- package/lib/useExposedProps-CTPtylCV.js.map +0 -1
- package/lib/utils-DcpDOncX.js +0 -1218
- package/lib/utils-DcpDOncX.js.map +0 -1
- package/lib/zudoku.openapi-worker.js +0 -15
- package/lib/zudoku.openapi-worker.js.map +0 -1
- package/src/lib/plugins/openapi/Route.tsx +0 -19
- package/src/lib/plugins/openapi/client/worker.ts +0 -44
- package/src/lib/plugins/openapi/playground/ResponseTab.tsx +0 -76
- package/src/lib/plugins/openapi-worker.ts +0 -11
- /package/dist/lib/plugins/openapi/schema/{SchemaComponents.d.ts → SchemaPropertyItem.d.ts} +0 -0
|
@@ -12,17 +12,27 @@ import * as types from "./graphql.js";
|
|
|
12
12
|
* Therefore it is highly recommended to use the babel or swc plugin for production.
|
|
13
13
|
* Learn more about it here: https://the-guild.dev/graphql/codegen/plugins/presets/preset-client#reducing-bundle-size
|
|
14
14
|
*/
|
|
15
|
-
|
|
15
|
+
type Documents = {
|
|
16
|
+
"\n query ServersQuery($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n url\n servers {\n url\n }\n }\n }\n": typeof types.ServersQueryDocument;
|
|
17
|
+
"\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 examples {\n name\n description\n externalValue\n value\n summary\n }\n schema\n }\n description\n required\n }\n responses {\n statusCode\n links\n description\n content {\n examples {\n name\n description\n externalValue\n value\n summary\n }\n mediaType\n encoding {\n name\n }\n schema\n }\n }\n }\n": typeof types.OperationsFragmentFragmentDoc;
|
|
18
|
+
"\n query AllOperations(\n $input: JSON!\n $type: SchemaType!\n $tag: String\n $untagged: Boolean\n ) {\n schema(input: $input, type: $type) {\n servers {\n url\n }\n description\n summary\n title\n url\n version\n tags(name: $tag) {\n name\n description\n }\n operations(tag: $tag, untagged: $untagged) {\n slug\n ...OperationsFragment\n }\n }\n }\n": typeof types.AllOperationsDocument;
|
|
19
|
+
"\n query getServerQuery($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n url\n servers {\n url\n }\n }\n }\n": typeof types.GetServerQueryDocument;
|
|
20
|
+
"\n query GetCategories($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n url\n tags {\n name\n }\n }\n }\n": typeof types.GetCategoriesDocument;
|
|
21
|
+
"\n query GetOperations($input: JSON!, $type: SchemaType!, $tag: String) {\n schema(input: $input, type: $type) {\n operations(tag: $tag) {\n slug\n deprecated\n method\n summary\n operationId\n path\n tags {\n name\n }\n }\n untagged: operations(untagged: true) {\n slug\n deprecated\n method\n summary\n operationId\n path\n }\n }\n }\n": typeof types.GetOperationsDocument;
|
|
22
|
+
};
|
|
23
|
+
const documents: Documents = {
|
|
16
24
|
"\n query ServersQuery($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n url\n servers {\n url\n }\n }\n }\n":
|
|
17
25
|
types.ServersQueryDocument,
|
|
18
26
|
"\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 examples {\n name\n description\n externalValue\n value\n summary\n }\n schema\n }\n description\n required\n }\n responses {\n statusCode\n links\n description\n content {\n examples {\n name\n description\n externalValue\n value\n summary\n }\n mediaType\n encoding {\n name\n }\n schema\n }\n }\n }\n":
|
|
19
27
|
types.OperationsFragmentFragmentDoc,
|
|
20
|
-
"\n query AllOperations($input: JSON
|
|
28
|
+
"\n query AllOperations(\n $input: JSON!\n $type: SchemaType!\n $tag: String\n $untagged: Boolean\n ) {\n schema(input: $input, type: $type) {\n servers {\n url\n }\n description\n summary\n title\n url\n version\n tags(name: $tag) {\n name\n description\n }\n operations(tag: $tag, untagged: $untagged) {\n slug\n ...OperationsFragment\n }\n }\n }\n":
|
|
21
29
|
types.AllOperationsDocument,
|
|
22
30
|
"\n query getServerQuery($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n url\n servers {\n url\n }\n }\n }\n":
|
|
23
31
|
types.GetServerQueryDocument,
|
|
24
|
-
"\n query GetCategories($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n url\n tags {\n
|
|
32
|
+
"\n query GetCategories($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n url\n tags {\n name\n }\n }\n }\n":
|
|
25
33
|
types.GetCategoriesDocument,
|
|
34
|
+
"\n query GetOperations($input: JSON!, $type: SchemaType!, $tag: String) {\n schema(input: $input, type: $type) {\n operations(tag: $tag) {\n slug\n deprecated\n method\n summary\n operationId\n path\n tags {\n name\n }\n }\n untagged: operations(untagged: true) {\n slug\n deprecated\n method\n summary\n operationId\n path\n }\n }\n }\n":
|
|
35
|
+
types.GetOperationsDocument,
|
|
26
36
|
};
|
|
27
37
|
|
|
28
38
|
/**
|
|
@@ -41,7 +51,7 @@ export function graphql(
|
|
|
41
51
|
* The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.
|
|
42
52
|
*/
|
|
43
53
|
export function graphql(
|
|
44
|
-
source: "\n query AllOperations($input: JSON
|
|
54
|
+
source: "\n query AllOperations(\n $input: JSON!\n $type: SchemaType!\n $tag: String\n $untagged: Boolean\n ) {\n schema(input: $input, type: $type) {\n servers {\n url\n }\n description\n summary\n title\n url\n version\n tags(name: $tag) {\n name\n description\n }\n operations(tag: $tag, untagged: $untagged) {\n slug\n ...OperationsFragment\n }\n }\n }\n",
|
|
45
55
|
): typeof import("./graphql.js").AllOperationsDocument;
|
|
46
56
|
/**
|
|
47
57
|
* The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.
|
|
@@ -53,8 +63,14 @@ export function graphql(
|
|
|
53
63
|
* The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.
|
|
54
64
|
*/
|
|
55
65
|
export function graphql(
|
|
56
|
-
source: "\n query GetCategories($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n url\n tags {\n
|
|
66
|
+
source: "\n query GetCategories($input: JSON!, $type: SchemaType!) {\n schema(input: $input, type: $type) {\n url\n tags {\n name\n }\n }\n }\n",
|
|
57
67
|
): typeof import("./graphql.js").GetCategoriesDocument;
|
|
68
|
+
/**
|
|
69
|
+
* The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.
|
|
70
|
+
*/
|
|
71
|
+
export function graphql(
|
|
72
|
+
source: "\n query GetOperations($input: JSON!, $type: SchemaType!, $tag: String) {\n schema(input: $input, type: $type) {\n operations(tag: $tag) {\n slug\n deprecated\n method\n summary\n operationId\n path\n tags {\n name\n }\n }\n untagged: operations(untagged: true) {\n slug\n deprecated\n method\n summary\n operationId\n path\n }\n }\n }\n",
|
|
73
|
+
): typeof import("./graphql.js").GetOperationsDocument;
|
|
58
74
|
|
|
59
75
|
export function graphql(source: string) {
|
|
60
76
|
return (documents as any)[source] ?? {};
|
|
@@ -31,6 +31,8 @@ export type Scalars = {
|
|
|
31
31
|
JSON: { input: any; output: any };
|
|
32
32
|
/** The `JSONObject` scalar type represents JSON objects as specified by [ECMA-404](http://www.ecma-international.org/publications/files/ECMA-ST/ECMA-404.pdf). */
|
|
33
33
|
JSONObject: { input: any; output: any };
|
|
34
|
+
/** OpenAPI schema scalar type that handles circular references */
|
|
35
|
+
JSONSchema: { input: any; output: any };
|
|
34
36
|
};
|
|
35
37
|
|
|
36
38
|
export type EncodingItem = {
|
|
@@ -57,7 +59,7 @@ export type MediaTypeObject = {
|
|
|
57
59
|
encoding?: Maybe<Array<EncodingItem>>;
|
|
58
60
|
examples?: Maybe<Array<ExampleItem>>;
|
|
59
61
|
mediaType: Scalars["String"]["output"];
|
|
60
|
-
schema?: Maybe<Scalars["
|
|
62
|
+
schema?: Maybe<Scalars["JSONSchema"]["output"]>;
|
|
61
63
|
};
|
|
62
64
|
|
|
63
65
|
export type OperationItem = {
|
|
@@ -89,7 +91,7 @@ export type ParameterItem = {
|
|
|
89
91
|
in: ParameterIn;
|
|
90
92
|
name: Scalars["String"]["output"];
|
|
91
93
|
required?: Maybe<Scalars["Boolean"]["output"]>;
|
|
92
|
-
schema?: Maybe<Scalars["
|
|
94
|
+
schema?: Maybe<Scalars["JSONSchema"]["output"]>;
|
|
93
95
|
style?: Maybe<Scalars["String"]["output"]>;
|
|
94
96
|
};
|
|
95
97
|
|
|
@@ -132,11 +134,11 @@ export type Schema = {
|
|
|
132
134
|
operations: Array<OperationItem>;
|
|
133
135
|
paths: Array<PathItem>;
|
|
134
136
|
servers: Array<Server>;
|
|
137
|
+
summary?: Maybe<Scalars["String"]["output"]>;
|
|
135
138
|
tags: Array<SchemaTag>;
|
|
136
139
|
title: Scalars["String"]["output"];
|
|
137
|
-
url
|
|
140
|
+
url?: Maybe<Scalars["String"]["output"]>;
|
|
138
141
|
version: Scalars["String"]["output"];
|
|
139
|
-
summary?: Maybe<Scalars["String"]["output"]>;
|
|
140
142
|
};
|
|
141
143
|
|
|
142
144
|
export type SchemaOperationsArgs = {
|
|
@@ -144,6 +146,7 @@ export type SchemaOperationsArgs = {
|
|
|
144
146
|
operationId?: InputMaybe<Scalars["String"]["input"]>;
|
|
145
147
|
path?: InputMaybe<Scalars["String"]["input"]>;
|
|
146
148
|
tag?: InputMaybe<Scalars["String"]["input"]>;
|
|
149
|
+
untagged?: InputMaybe<Scalars["Boolean"]["input"]>;
|
|
147
150
|
};
|
|
148
151
|
|
|
149
152
|
export type SchemaTagsArgs = {
|
|
@@ -153,7 +156,7 @@ export type SchemaTagsArgs = {
|
|
|
153
156
|
export type SchemaTag = {
|
|
154
157
|
__typename?: "SchemaTag";
|
|
155
158
|
description?: Maybe<Scalars["String"]["output"]>;
|
|
156
|
-
name
|
|
159
|
+
name: Scalars["String"]["output"];
|
|
157
160
|
operations: Array<OperationItem>;
|
|
158
161
|
};
|
|
159
162
|
|
|
@@ -180,7 +183,7 @@ export type ServersQueryQuery = {
|
|
|
180
183
|
__typename?: "Query";
|
|
181
184
|
schema: {
|
|
182
185
|
__typename?: "Schema";
|
|
183
|
-
url
|
|
186
|
+
url?: string | null;
|
|
184
187
|
servers: Array<{ __typename?: "Server"; url: string }>;
|
|
185
188
|
};
|
|
186
189
|
};
|
|
@@ -255,6 +258,8 @@ export type OperationsFragmentFragment = {
|
|
|
255
258
|
export type AllOperationsQueryVariables = Exact<{
|
|
256
259
|
input: Scalars["JSON"]["input"];
|
|
257
260
|
type: SchemaType;
|
|
261
|
+
tag?: InputMaybe<Scalars["String"]["input"]>;
|
|
262
|
+
untagged?: InputMaybe<Scalars["Boolean"]["input"]>;
|
|
258
263
|
}>;
|
|
259
264
|
|
|
260
265
|
export type AllOperationsQuery = {
|
|
@@ -264,20 +269,21 @@ export type AllOperationsQuery = {
|
|
|
264
269
|
description?: string | null;
|
|
265
270
|
summary?: string | null;
|
|
266
271
|
title: string;
|
|
267
|
-
url
|
|
272
|
+
url?: string | null;
|
|
268
273
|
version: string;
|
|
274
|
+
servers: Array<{ __typename?: "Server"; url: string }>;
|
|
269
275
|
tags: Array<{
|
|
270
276
|
__typename?: "SchemaTag";
|
|
271
|
-
name
|
|
277
|
+
name: string;
|
|
272
278
|
description?: string | null;
|
|
273
|
-
operations: Array<
|
|
274
|
-
{ __typename?: "OperationItem"; slug: string } & {
|
|
275
|
-
" $fragmentRefs"?: {
|
|
276
|
-
OperationsFragmentFragment: OperationsFragmentFragment;
|
|
277
|
-
};
|
|
278
|
-
}
|
|
279
|
-
>;
|
|
280
279
|
}>;
|
|
280
|
+
operations: Array<
|
|
281
|
+
{ __typename?: "OperationItem"; slug: string } & {
|
|
282
|
+
" $fragmentRefs"?: {
|
|
283
|
+
OperationsFragmentFragment: OperationsFragmentFragment;
|
|
284
|
+
};
|
|
285
|
+
}
|
|
286
|
+
>;
|
|
281
287
|
};
|
|
282
288
|
};
|
|
283
289
|
|
|
@@ -290,7 +296,7 @@ export type GetServerQueryQuery = {
|
|
|
290
296
|
__typename?: "Query";
|
|
291
297
|
schema: {
|
|
292
298
|
__typename?: "Schema";
|
|
293
|
-
url
|
|
299
|
+
url?: string | null;
|
|
294
300
|
servers: Array<{ __typename?: "Server"; url: string }>;
|
|
295
301
|
};
|
|
296
302
|
};
|
|
@@ -304,19 +310,39 @@ export type GetCategoriesQuery = {
|
|
|
304
310
|
__typename?: "Query";
|
|
305
311
|
schema: {
|
|
306
312
|
__typename?: "Schema";
|
|
307
|
-
url
|
|
308
|
-
tags: Array<{
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
313
|
+
url?: string | null;
|
|
314
|
+
tags: Array<{ __typename?: "SchemaTag"; name: string }>;
|
|
315
|
+
};
|
|
316
|
+
};
|
|
317
|
+
|
|
318
|
+
export type GetOperationsQueryVariables = Exact<{
|
|
319
|
+
input: Scalars["JSON"]["input"];
|
|
320
|
+
type: SchemaType;
|
|
321
|
+
tag?: InputMaybe<Scalars["String"]["input"]>;
|
|
322
|
+
}>;
|
|
323
|
+
|
|
324
|
+
export type GetOperationsQuery = {
|
|
325
|
+
__typename?: "Query";
|
|
326
|
+
schema: {
|
|
327
|
+
__typename?: "Schema";
|
|
328
|
+
operations: Array<{
|
|
329
|
+
__typename?: "OperationItem";
|
|
330
|
+
slug: string;
|
|
331
|
+
deprecated?: boolean | null;
|
|
332
|
+
method: string;
|
|
333
|
+
summary?: string | null;
|
|
334
|
+
operationId?: string | null;
|
|
335
|
+
path: string;
|
|
336
|
+
tags?: Array<{ __typename?: "TagItem"; name: string }> | null;
|
|
337
|
+
}>;
|
|
338
|
+
untagged: Array<{
|
|
339
|
+
__typename?: "OperationItem";
|
|
340
|
+
slug: string;
|
|
341
|
+
deprecated?: boolean | null;
|
|
342
|
+
method: string;
|
|
343
|
+
summary?: string | null;
|
|
344
|
+
operationId?: string | null;
|
|
345
|
+
path: string;
|
|
320
346
|
}>;
|
|
321
347
|
};
|
|
322
348
|
};
|
|
@@ -418,20 +444,23 @@ export const ServersQueryDocument = new TypedDocumentString(`
|
|
|
418
444
|
ServersQueryQueryVariables
|
|
419
445
|
>;
|
|
420
446
|
export const AllOperationsDocument = new TypedDocumentString(`
|
|
421
|
-
query AllOperations($input: JSON!, $type: SchemaType
|
|
447
|
+
query AllOperations($input: JSON!, $type: SchemaType!, $tag: String, $untagged: Boolean) {
|
|
422
448
|
schema(input: $input, type: $type) {
|
|
449
|
+
servers {
|
|
450
|
+
url
|
|
451
|
+
}
|
|
423
452
|
description
|
|
424
453
|
summary
|
|
425
454
|
title
|
|
426
455
|
url
|
|
427
456
|
version
|
|
428
|
-
tags {
|
|
457
|
+
tags(name: $tag) {
|
|
429
458
|
name
|
|
430
459
|
description
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
460
|
+
}
|
|
461
|
+
operations(tag: $tag, untagged: $untagged) {
|
|
462
|
+
slug
|
|
463
|
+
...OperationsFragment
|
|
435
464
|
}
|
|
436
465
|
}
|
|
437
466
|
}
|
|
@@ -517,17 +546,7 @@ export const GetCategoriesDocument = new TypedDocumentString(`
|
|
|
517
546
|
schema(input: $input, type: $type) {
|
|
518
547
|
url
|
|
519
548
|
tags {
|
|
520
|
-
__typename
|
|
521
549
|
name
|
|
522
|
-
operations {
|
|
523
|
-
__typename
|
|
524
|
-
slug
|
|
525
|
-
deprecated
|
|
526
|
-
method
|
|
527
|
-
summary
|
|
528
|
-
operationId
|
|
529
|
-
path
|
|
530
|
-
}
|
|
531
550
|
}
|
|
532
551
|
}
|
|
533
552
|
}
|
|
@@ -535,3 +554,31 @@ export const GetCategoriesDocument = new TypedDocumentString(`
|
|
|
535
554
|
GetCategoriesQuery,
|
|
536
555
|
GetCategoriesQueryVariables
|
|
537
556
|
>;
|
|
557
|
+
export const GetOperationsDocument = new TypedDocumentString(`
|
|
558
|
+
query GetOperations($input: JSON!, $type: SchemaType!, $tag: String) {
|
|
559
|
+
schema(input: $input, type: $type) {
|
|
560
|
+
operations(tag: $tag) {
|
|
561
|
+
slug
|
|
562
|
+
deprecated
|
|
563
|
+
method
|
|
564
|
+
summary
|
|
565
|
+
operationId
|
|
566
|
+
path
|
|
567
|
+
tags {
|
|
568
|
+
name
|
|
569
|
+
}
|
|
570
|
+
}
|
|
571
|
+
untagged: operations(untagged: true) {
|
|
572
|
+
slug
|
|
573
|
+
deprecated
|
|
574
|
+
method
|
|
575
|
+
summary
|
|
576
|
+
operationId
|
|
577
|
+
path
|
|
578
|
+
}
|
|
579
|
+
}
|
|
580
|
+
}
|
|
581
|
+
`) as unknown as TypedDocumentString<
|
|
582
|
+
GetOperationsQuery,
|
|
583
|
+
GetOperationsQueryVariables
|
|
584
|
+
>;
|
|
@@ -1,57 +1,70 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
import { graphql } from "./graphql/index.js";
|
|
4
|
-
|
|
5
|
-
import { useQuery } from "@tanstack/react-query";
|
|
1
|
+
import type { ResultOf } from "@graphql-typed-document-node/core";
|
|
2
|
+
import slugify from "@sindresorhus/slugify";
|
|
6
3
|
import { CirclePlayIcon, LogInIcon } from "lucide-react";
|
|
7
|
-
import
|
|
4
|
+
import { ReactNode } from "react";
|
|
5
|
+
import { matchPath } from "react-router";
|
|
8
6
|
import { useAuth } from "../../authentication/hook.js";
|
|
9
|
-
import {
|
|
7
|
+
import { type ZudokuPlugin } from "../../core/plugins.js";
|
|
8
|
+
import type { SchemaImports } from "../../oas/graphql/index.js";
|
|
10
9
|
import { Button } from "../../ui/Button.js";
|
|
11
|
-
import {
|
|
10
|
+
import { joinUrl } from "../../util/joinUrl.js";
|
|
12
11
|
import { GraphQLClient } from "./client/GraphQLClient.js";
|
|
12
|
+
import { graphql } from "./graphql/index.js";
|
|
13
13
|
import { OasPluginConfig } from "./interfaces.js";
|
|
14
14
|
import type { PlaygroundContentProps } from "./playground/Playground.js";
|
|
15
15
|
import { PlaygroundDialog } from "./playground/PlaygroundDialog.js";
|
|
16
|
+
import { createSidebarCategory } from "./util/createSidebarCategory.js";
|
|
17
|
+
import { getRoutes, getVersions } from "./util/getRoutes.js";
|
|
16
18
|
|
|
17
19
|
const GetCategoriesQuery = graphql(`
|
|
18
20
|
query GetCategories($input: JSON!, $type: SchemaType!) {
|
|
19
21
|
schema(input: $input, type: $type) {
|
|
20
22
|
url
|
|
21
23
|
tags {
|
|
22
|
-
__typename
|
|
23
24
|
name
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
`);
|
|
29
|
+
|
|
30
|
+
const GetOperationsQuery = graphql(`
|
|
31
|
+
query GetOperations($input: JSON!, $type: SchemaType!, $tag: String) {
|
|
32
|
+
schema(input: $input, type: $type) {
|
|
33
|
+
operations(tag: $tag) {
|
|
34
|
+
slug
|
|
35
|
+
deprecated
|
|
36
|
+
method
|
|
37
|
+
summary
|
|
38
|
+
operationId
|
|
39
|
+
path
|
|
40
|
+
tags {
|
|
41
|
+
name
|
|
32
42
|
}
|
|
33
43
|
}
|
|
44
|
+
untagged: operations(untagged: true) {
|
|
45
|
+
slug
|
|
46
|
+
deprecated
|
|
47
|
+
method
|
|
48
|
+
summary
|
|
49
|
+
operationId
|
|
50
|
+
path
|
|
51
|
+
}
|
|
34
52
|
}
|
|
35
53
|
}
|
|
36
54
|
`);
|
|
37
55
|
|
|
38
|
-
type
|
|
56
|
+
export type OperationResult = ResultOf<
|
|
57
|
+
typeof GetOperationsQuery
|
|
58
|
+
>["schema"]["operations"][number];
|
|
39
59
|
|
|
40
|
-
|
|
41
|
-
get: "green",
|
|
42
|
-
post: "blue",
|
|
43
|
-
put: "yellow",
|
|
44
|
-
delete: "red",
|
|
45
|
-
patch: "purple",
|
|
46
|
-
options: "gray",
|
|
47
|
-
head: "gray",
|
|
48
|
-
};
|
|
60
|
+
type InternalOasPluginConfig = { schemaImports?: SchemaImports };
|
|
49
61
|
|
|
50
62
|
export type OpenApiPluginOptions = OasPluginConfig & InternalOasPluginConfig;
|
|
51
63
|
|
|
52
|
-
export const
|
|
53
|
-
const basePath = joinPath(config.navigationId ?? "/reference");
|
|
64
|
+
export const UNTAGGED_PATH = "~endpoints";
|
|
54
65
|
|
|
66
|
+
export const openApiPlugin = (config: OpenApiPluginOptions): ZudokuPlugin => {
|
|
67
|
+
const basePath = joinUrl(config.navigationId ?? "/reference");
|
|
55
68
|
const client = new GraphQLClient(config);
|
|
56
69
|
|
|
57
70
|
return {
|
|
@@ -77,19 +90,19 @@ export const openApiPlugin = (config: OpenApiPluginOptions): ZudokuPlugin => {
|
|
|
77
90
|
server,
|
|
78
91
|
method,
|
|
79
92
|
url,
|
|
93
|
+
children,
|
|
80
94
|
...props
|
|
81
|
-
}: Partial<PlaygroundContentProps> & {
|
|
95
|
+
}: Partial<PlaygroundContentProps> & { children: ReactNode } & Pick<
|
|
96
|
+
PlaygroundContentProps,
|
|
97
|
+
"server"
|
|
98
|
+
> & {
|
|
99
|
+
requireAuth: boolean;
|
|
100
|
+
}) => {
|
|
82
101
|
const auth = useAuth();
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
type: config.type,
|
|
88
|
-
input: config.input,
|
|
89
|
-
}),
|
|
90
|
-
enabled: !server,
|
|
91
|
-
queryKey: ["playground-server"],
|
|
92
|
-
});
|
|
102
|
+
|
|
103
|
+
if (!server) {
|
|
104
|
+
throw new Error("Server is required");
|
|
105
|
+
}
|
|
93
106
|
|
|
94
107
|
if (requireAuth && !auth.isAuthenticated) {
|
|
95
108
|
return (
|
|
@@ -107,13 +120,15 @@ export const openApiPlugin = (config: OpenApiPluginOptions): ZudokuPlugin => {
|
|
|
107
120
|
<PlaygroundDialog
|
|
108
121
|
url={url ?? "/"}
|
|
109
122
|
method={method ?? "get"}
|
|
110
|
-
server={
|
|
111
|
-
server ?? serverQuery.data?.schema.url ?? "https://example.com"
|
|
112
|
-
}
|
|
123
|
+
server={server}
|
|
113
124
|
{...props}
|
|
114
125
|
>
|
|
115
126
|
<Button className="gap-2 items-center" variant="outline">
|
|
116
|
-
|
|
127
|
+
{children ?? (
|
|
128
|
+
<>
|
|
129
|
+
Open in Playground <CirclePlayIcon size={16} />
|
|
130
|
+
</>
|
|
131
|
+
)}
|
|
117
132
|
</Button>
|
|
118
133
|
</PlaygroundDialog>
|
|
119
134
|
);
|
|
@@ -124,67 +139,85 @@ export const openApiPlugin = (config: OpenApiPluginOptions): ZudokuPlugin => {
|
|
|
124
139
|
return [];
|
|
125
140
|
}
|
|
126
141
|
|
|
142
|
+
const match = matchPath(
|
|
143
|
+
{ path: `${basePath}/:version?/:tag`, end: true },
|
|
144
|
+
path,
|
|
145
|
+
);
|
|
146
|
+
|
|
127
147
|
try {
|
|
128
|
-
const
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
148
|
+
const versionParam = match?.params.version;
|
|
149
|
+
const version = versionParam ?? getVersions(config).at(0);
|
|
150
|
+
const type = config.type;
|
|
151
|
+
const input =
|
|
152
|
+
config.type === "file" ? config.input[version!] : config.input;
|
|
153
|
+
|
|
154
|
+
const collapsible = config.loadTags === true || config.type === "url";
|
|
155
|
+
const collapsed = !config.loadTags && config.type !== "url";
|
|
132
156
|
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
157
|
+
// find tag name by slug in config.tagPages
|
|
158
|
+
const tagName = config.tagPages?.find(
|
|
159
|
+
(tag) => slugify(tag) === match?.params.tag,
|
|
160
|
+
);
|
|
161
|
+
|
|
162
|
+
const [tagData, operationsData] = await Promise.all([
|
|
163
|
+
client.fetch(GetCategoriesQuery, { type, input }),
|
|
164
|
+
client.fetch(GetOperationsQuery, {
|
|
165
|
+
type,
|
|
166
|
+
input,
|
|
167
|
+
tag: !config.loadTags ? tagName : undefined,
|
|
168
|
+
}),
|
|
169
|
+
]);
|
|
170
|
+
|
|
171
|
+
const categories = tagData.schema.tags.flatMap((tag) => {
|
|
172
|
+
const categoryPath = joinUrl(
|
|
173
|
+
basePath,
|
|
174
|
+
versionParam,
|
|
175
|
+
slugify(tag.name),
|
|
176
|
+
);
|
|
177
|
+
|
|
178
|
+
const operations = operationsData.schema.operations.filter(
|
|
179
|
+
(operation) =>
|
|
180
|
+
operation.tags?.length !== 0 &&
|
|
181
|
+
operation.tags?.map((t) => t.name).includes(tag.name),
|
|
182
|
+
);
|
|
183
|
+
|
|
184
|
+
// skip empty categories
|
|
185
|
+
if (config.loadTags && operations.length === 0) {
|
|
186
|
+
return [];
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
return createSidebarCategory({
|
|
190
|
+
label: tag.name,
|
|
191
|
+
path: categoryPath,
|
|
192
|
+
operations:
|
|
193
|
+
match?.params.tag !== UNTAGGED_PATH || config.loadTags
|
|
194
|
+
? operations
|
|
195
|
+
: [],
|
|
196
|
+
collapsible,
|
|
197
|
+
collapsed,
|
|
198
|
+
});
|
|
155
199
|
});
|
|
156
200
|
|
|
201
|
+
if (operationsData.schema.untagged.length > 0) {
|
|
202
|
+
categories.push(
|
|
203
|
+
createSidebarCategory({
|
|
204
|
+
label: "Other endpoints",
|
|
205
|
+
path: joinUrl(basePath, versionParam, UNTAGGED_PATH),
|
|
206
|
+
operations:
|
|
207
|
+
match?.params.tag === UNTAGGED_PATH || config.loadTags
|
|
208
|
+
? operationsData.schema.untagged
|
|
209
|
+
: [],
|
|
210
|
+
collapsible,
|
|
211
|
+
collapsed,
|
|
212
|
+
}),
|
|
213
|
+
);
|
|
214
|
+
}
|
|
215
|
+
|
|
157
216
|
return categories;
|
|
158
217
|
} catch {
|
|
159
218
|
return [];
|
|
160
219
|
}
|
|
161
220
|
},
|
|
162
|
-
getRoutes: () =>
|
|
163
|
-
[
|
|
164
|
-
{
|
|
165
|
-
async lazy() {
|
|
166
|
-
const { OpenApiRoute } = await import("./Route.js");
|
|
167
|
-
return {
|
|
168
|
-
element: <OpenApiRoute client={client} config={config} />,
|
|
169
|
-
};
|
|
170
|
-
},
|
|
171
|
-
children: [
|
|
172
|
-
{
|
|
173
|
-
path: basePath,
|
|
174
|
-
children: [
|
|
175
|
-
{
|
|
176
|
-
index: true,
|
|
177
|
-
async lazy() {
|
|
178
|
-
const { OperationList } = await import(
|
|
179
|
-
"./OperationList.js"
|
|
180
|
-
);
|
|
181
|
-
return { element: <OperationList /> };
|
|
182
|
-
},
|
|
183
|
-
},
|
|
184
|
-
],
|
|
185
|
-
},
|
|
186
|
-
],
|
|
187
|
-
},
|
|
188
|
-
] satisfies RouteObject[],
|
|
221
|
+
getRoutes: () => getRoutes({ basePath, config, client }),
|
|
189
222
|
};
|
|
190
223
|
};
|
|
@@ -1,10 +1,35 @@
|
|
|
1
|
+
type DynamicInput = () => Promise<unknown>;
|
|
2
|
+
|
|
1
3
|
type OasSource =
|
|
2
4
|
| { type: "url"; input: string }
|
|
3
|
-
| { type: "file"; input:
|
|
5
|
+
| { type: "file"; input: { [version: string]: DynamicInput } }
|
|
6
|
+
| { type: "raw"; input: string };
|
|
7
|
+
|
|
8
|
+
export type ContextOasSource =
|
|
9
|
+
| { type: "url"; input: string }
|
|
10
|
+
| { type: "file"; input: DynamicInput }
|
|
4
11
|
| { type: "raw"; input: string };
|
|
5
12
|
|
|
6
13
|
export type OasPluginConfig = {
|
|
7
14
|
server?: string;
|
|
8
15
|
navigationId?: string;
|
|
9
16
|
skipPreload?: boolean;
|
|
10
|
-
|
|
17
|
+
tagPages?: Array<string>;
|
|
18
|
+
loadTags?: boolean;
|
|
19
|
+
} & OasPluginConfigOptions &
|
|
20
|
+
OasSource;
|
|
21
|
+
|
|
22
|
+
export type OasPluginConfigOptions = {
|
|
23
|
+
options?: {
|
|
24
|
+
examplesDefaultLanguage?: string;
|
|
25
|
+
};
|
|
26
|
+
};
|
|
27
|
+
|
|
28
|
+
export type OasPluginContext = {
|
|
29
|
+
server?: string;
|
|
30
|
+
navigationId?: string;
|
|
31
|
+
skipPreload?: boolean;
|
|
32
|
+
version?: string;
|
|
33
|
+
versions: Record<string, string>;
|
|
34
|
+
} & ContextOasSource &
|
|
35
|
+
OasPluginConfigOptions;
|