zudoku 0.0.0-f3858d6 → 0.0.0-f3f6db5
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/README.md +121 -0
- package/client.d.ts +7 -0
- package/dist/app/demo.js +1 -4
- package/dist/app/demo.js.map +1 -1
- package/dist/app/entry.client.d.ts +1 -0
- package/dist/app/entry.client.js +14 -1
- package/dist/app/entry.client.js.map +1 -1
- package/dist/app/entry.server.d.ts +1 -0
- package/dist/app/entry.server.js +8 -8
- package/dist/app/entry.server.js.map +1 -1
- package/dist/app/main.d.ts +3 -3
- package/dist/app/main.js +25 -15
- package/dist/app/main.js.map +1 -1
- package/dist/app/sentry.d.ts +3 -0
- package/dist/app/sentry.js +19 -0
- package/dist/app/sentry.js.map +1 -0
- package/dist/app/standalone.js +1 -4
- package/dist/app/standalone.js.map +1 -1
- package/dist/app/tailwind.d.ts +2 -1
- package/dist/app/tailwind.js +64 -52
- package/dist/app/tailwind.js.map +1 -1
- package/dist/cli/cli.js +1 -4
- package/dist/cli/cli.js.map +1 -1
- package/dist/cli/cmds/build.js +1 -0
- 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/common/logger.js +9 -0
- package/dist/cli/common/logger.js.map +1 -1
- package/dist/cli/common/outdated.js +2 -1
- package/dist/cli/common/outdated.js.map +1 -1
- package/dist/cli/dev/handler.d.ts +1 -0
- package/dist/cli/dev/handler.js +3 -3
- package/dist/cli/dev/handler.js.map +1 -1
- package/dist/codegen.d.ts +3 -0
- package/dist/codegen.js +45 -0
- package/dist/codegen.js.map +1 -0
- package/dist/config/common.d.ts +8 -0
- package/dist/config/common.js +2 -0
- package/dist/config/common.js.map +1 -0
- package/dist/config/config.d.ts +4 -2
- package/dist/config/loader.d.ts +20 -0
- package/dist/config/loader.js +154 -0
- package/dist/config/loader.js.map +1 -0
- package/dist/config/validators/InputSidebarSchema.d.ts +46 -15
- package/dist/config/validators/InputSidebarSchema.js +8 -28
- package/dist/config/validators/InputSidebarSchema.js.map +1 -1
- package/dist/config/validators/SidebarSchema.d.ts +24 -1
- package/dist/config/validators/SidebarSchema.js +77 -37
- package/dist/config/validators/SidebarSchema.js.map +1 -1
- package/dist/config/validators/common.d.ts +5034 -0
- package/dist/config/validators/common.js +287 -0
- package/dist/config/validators/common.js.map +1 -0
- package/dist/config/validators/icon-types.d.ts +1 -0
- package/dist/config/validators/icon-types.js +2 -0
- package/dist/config/validators/icon-types.js.map +1 -0
- package/dist/config/validators/validate.d.ts +867 -460
- package/dist/config/validators/validate.js +12 -214
- package/dist/config/validators/validate.js.map +1 -1
- package/dist/index.d.ts +3 -3
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/lib/authentication/AuthenticationPlugin.d.ts +4 -2
- package/dist/lib/authentication/AuthenticationPlugin.js +3 -0
- package/dist/lib/authentication/AuthenticationPlugin.js.map +1 -1
- package/dist/lib/authentication/authentication.d.ts +3 -3
- package/dist/lib/authentication/components/CallbackHandler.js +21 -31
- 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/hook.d.ts +5 -4
- package/dist/lib/authentication/hook.js +1 -3
- package/dist/lib/authentication/hook.js.map +1 -1
- package/dist/lib/authentication/providers/auth0.js +13 -12
- package/dist/lib/authentication/providers/auth0.js.map +1 -1
- package/dist/lib/authentication/providers/clerk.js +29 -6
- package/dist/lib/authentication/providers/clerk.js.map +1 -1
- package/dist/lib/authentication/providers/openid.d.ts +8 -2
- package/dist/lib/authentication/providers/openid.js +31 -35
- package/dist/lib/authentication/providers/openid.js.map +1 -1
- package/dist/lib/authentication/state.d.ts +25 -4
- package/dist/lib/authentication/state.js +28 -3
- package/dist/lib/authentication/state.js.map +1 -1
- package/dist/lib/authentication/use-broadcast/shared.d.ts +48 -0
- package/dist/lib/authentication/use-broadcast/shared.js +243 -0
- package/dist/lib/authentication/use-broadcast/shared.js.map +1 -0
- package/dist/lib/authentication/use-broadcast/useBroadcast.d.ts +24 -0
- package/dist/lib/authentication/use-broadcast/useBroadcast.js +106 -0
- package/dist/lib/authentication/use-broadcast/useBroadcast.js.map +1 -0
- 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 +12 -0
- package/dist/lib/components/Autocomplete.js +47 -0
- package/dist/lib/components/Autocomplete.js.map +1 -0
- package/dist/lib/components/Bootstrap.d.ts +4 -3
- package/dist/lib/components/Bootstrap.js +12 -6
- package/dist/lib/components/Bootstrap.js.map +1 -1
- package/dist/lib/components/ClientOnly.d.ts +4 -2
- package/dist/lib/components/ClientOnly.js +1 -1
- package/dist/lib/components/ClientOnly.js.map +1 -1
- package/dist/lib/components/DeveloperHint.js +2 -1
- package/dist/lib/components/DeveloperHint.js.map +1 -1
- package/dist/lib/components/Header.js +21 -14
- package/dist/lib/components/Header.js.map +1 -1
- package/dist/lib/components/Heading.d.ts +4 -4
- package/dist/lib/components/Heading.js +1 -1
- package/dist/lib/components/Heading.js.map +1 -1
- package/dist/lib/components/Layout.js +14 -5
- package/dist/lib/components/Layout.js.map +1 -1
- package/dist/lib/components/Markdown.d.ts +2 -2
- package/dist/lib/components/Markdown.js +4 -2
- package/dist/lib/components/Markdown.js.map +1 -1
- package/dist/lib/components/MobileTopNavigation.js +8 -6
- package/dist/lib/components/MobileTopNavigation.js.map +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 +25 -0
- package/dist/lib/components/PathRenderer.js.map +1 -0
- package/dist/lib/components/ReactMarkdown.d.ts +29 -0
- package/dist/lib/components/ReactMarkdown.js +182 -0
- package/dist/lib/components/ReactMarkdown.js.map +1 -0
- package/dist/lib/components/Search.d.ts +3 -1
- package/dist/lib/components/Search.js +3 -3
- package/dist/lib/components/Search.js.map +1 -1
- package/dist/lib/components/SlotletProvider.d.ts +8 -3
- package/dist/lib/components/SlotletProvider.js +3 -5
- package/dist/lib/components/SlotletProvider.js.map +1 -1
- 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/SyntaxHighlight.d.ts +2 -1
- package/dist/lib/components/SyntaxHighlight.js +20 -17
- package/dist/lib/components/SyntaxHighlight.js.map +1 -1
- package/dist/lib/components/ThemeSwitch.d.ts +1 -0
- package/dist/lib/components/ThemeSwitch.js +13 -0
- package/dist/lib/components/ThemeSwitch.js.map +1 -0
- package/dist/lib/components/TopNavigation.d.ts +5 -0
- package/dist/lib/components/TopNavigation.js +22 -8
- package/dist/lib/components/TopNavigation.js.map +1 -1
- package/dist/lib/components/{DevPortal.d.ts → Zudoku.d.ts} +3 -3
- package/dist/lib/components/{DevPortal.js → Zudoku.js} +14 -15
- package/dist/lib/components/Zudoku.js.map +1 -0
- 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/ViewportAnchorContext.js +16 -4
- package/dist/lib/components/context/ViewportAnchorContext.js.map +1 -1
- package/dist/lib/components/context/ZudokuContext.d.ts +7 -6
- package/dist/lib/components/context/ZudokuContext.js +11 -15
- package/dist/lib/components/context/ZudokuContext.js.map +1 -1
- package/dist/lib/components/context/ZudokuProvider.d.ts +2 -2
- package/dist/lib/components/context/ZudokuProvider.js.map +1 -1
- package/dist/lib/components/index.d.ts +46 -17
- package/dist/lib/components/index.js +21 -6
- package/dist/lib/components/index.js.map +1 -1
- package/dist/lib/components/navigation/Sidebar.d.ts +3 -1
- package/dist/lib/components/navigation/Sidebar.js +2 -2
- package/dist/lib/components/navigation/Sidebar.js.map +1 -1
- package/dist/lib/components/navigation/SidebarBadge.d.ts +4 -3
- package/dist/lib/components/navigation/SidebarBadge.js +11 -11
- package/dist/lib/components/navigation/SidebarBadge.js.map +1 -1
- package/dist/lib/components/navigation/SidebarCategory.d.ts +2 -2
- package/dist/lib/components/navigation/SidebarCategory.js +20 -8
- package/dist/lib/components/navigation/SidebarCategory.js.map +1 -1
- package/dist/lib/components/navigation/SidebarItem.d.ts +2 -4
- package/dist/lib/components/navigation/SidebarItem.js +13 -11
- 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 +3 -3
- 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 +28 -0
- package/dist/lib/core/RouteGuard.js.map +1 -0
- package/dist/lib/core/{DevPortalContext.d.ts → ZudokuContext.d.ts} +8 -10
- package/dist/lib/core/{DevPortalContext.js → ZudokuContext.js} +11 -14
- package/dist/lib/core/ZudokuContext.js.map +1 -0
- package/dist/lib/core/plugins.d.ts +17 -13
- package/dist/lib/core/plugins.js.map +1 -1
- package/dist/lib/errors/ErrorAlert.d.ts +1 -1
- package/dist/lib/errors/ErrorAlert.js +8 -3
- package/dist/lib/errors/ErrorAlert.js.map +1 -1
- package/dist/lib/errors/RouterError.js +1 -1
- package/dist/lib/errors/RouterError.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 +4 -0
- package/dist/lib/oas/graphql/index.js +81 -49
- 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.d.ts +2 -2
- package/dist/lib/oas/parser/upgrade/index.js +19 -20
- package/dist/lib/oas/parser/upgrade/index.js.map +1 -1
- package/dist/lib/plugins/api-catalog/Catalog.d.ts +2 -0
- package/dist/lib/plugins/api-catalog/Catalog.js +36 -0
- package/dist/lib/plugins/api-catalog/Catalog.js.map +1 -0
- package/dist/lib/plugins/api-catalog/index.d.ts +30 -0
- package/dist/lib/plugins/api-catalog/index.js +15 -0
- package/dist/lib/plugins/api-catalog/index.js.map +1 -0
- package/dist/lib/plugins/api-keys/CreateApiKey.js +2 -2
- 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 +9 -9
- package/dist/lib/plugins/api-keys/index.js +3 -0
- package/dist/lib/plugins/api-keys/index.js.map +1 -1
- package/dist/lib/plugins/custom-pages/CustomPage.d.ts +2 -0
- package/dist/lib/plugins/custom-pages/CustomPage.js +11 -0
- package/dist/lib/plugins/custom-pages/CustomPage.js.map +1 -0
- package/dist/lib/plugins/custom-pages/index.d.ts +9 -7
- package/dist/lib/plugins/custom-pages/index.js +3 -4
- package/dist/lib/plugins/custom-pages/index.js.map +1 -1
- package/dist/lib/plugins/markdown/MdxPage.d.ts +9 -1
- package/dist/lib/plugins/markdown/MdxPage.js +22 -3
- package/dist/lib/plugins/markdown/MdxPage.js.map +1 -1
- package/dist/lib/plugins/markdown/index.d.ts +5 -3
- package/dist/lib/plugins/markdown/index.js +1 -1
- package/dist/lib/plugins/markdown/index.js.map +1 -1
- package/dist/lib/plugins/markdown/resolver.js.map +1 -1
- package/dist/lib/plugins/openapi/CollapsibleCode.d.ts +5 -0
- package/dist/lib/plugins/openapi/CollapsibleCode.js +25 -0
- package/dist/lib/plugins/openapi/CollapsibleCode.js.map +1 -0
- package/dist/lib/plugins/openapi/ColorizedParam.d.ts +10 -2
- package/dist/lib/plugins/openapi/ColorizedParam.js +29 -14
- package/dist/lib/plugins/openapi/ColorizedParam.js.map +1 -1
- package/dist/lib/plugins/openapi/Endpoint.js +10 -12
- package/dist/lib/plugins/openapi/Endpoint.js.map +1 -1
- package/dist/lib/plugins/openapi/OpenApiRoute.d.ts +9 -0
- package/dist/lib/plugins/openapi/OpenApiRoute.js +25 -0
- package/dist/lib/plugins/openapi/OpenApiRoute.js.map +1 -0
- package/dist/lib/plugins/openapi/OperationList.d.ts +5 -2
- package/dist/lib/plugins/openapi/OperationList.js +60 -31
- package/dist/lib/plugins/openapi/OperationList.js.map +1 -1
- package/dist/lib/plugins/openapi/OperationListItem.d.ts +2 -1
- package/dist/lib/plugins/openapi/OperationListItem.js +14 -4
- package/dist/lib/plugins/openapi/OperationListItem.js.map +1 -1
- package/dist/lib/plugins/openapi/ParameterListItem.js +7 -1
- package/dist/lib/plugins/openapi/ParameterListItem.js.map +1 -1
- package/dist/lib/plugins/openapi/PlaygroundDialogWrapper.d.ts +3 -1
- package/dist/lib/plugins/openapi/PlaygroundDialogWrapper.js +5 -2
- 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 -9
- package/dist/lib/plugins/openapi/RequestBodySidecarBox.js.map +1 -1
- package/dist/lib/plugins/openapi/ResponsesSidecarBox.js +7 -6
- package/dist/lib/plugins/openapi/ResponsesSidecarBox.js.map +1 -1
- package/dist/lib/plugins/openapi/Sidecar.d.ts +1 -1
- package/dist/lib/plugins/openapi/Sidecar.js +50 -60
- 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 +8 -0
- package/dist/lib/plugins/openapi/client/GraphQLClient.js +43 -0
- package/dist/lib/plugins/openapi/client/GraphQLClient.js.map +1 -0
- package/dist/lib/plugins/openapi/client/GraphQLContext.d.ts +7 -0
- package/dist/lib/plugins/openapi/client/GraphQLContext.js +5 -0
- package/dist/lib/plugins/openapi/client/GraphQLContext.js.map +1 -0
- package/dist/lib/plugins/openapi/client/createServer.d.ts +3 -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 +5 -0
- package/dist/lib/plugins/openapi/client/useCreateQuery.js +13 -0
- package/dist/lib/plugins/openapi/client/useCreateQuery.js.map +1 -0
- package/dist/lib/plugins/openapi/context.d.ts +3 -3
- package/dist/lib/plugins/openapi/graphql/fragment-masking.d.ts +3 -3
- package/dist/lib/plugins/openapi/graphql/fragment-masking.js +3 -4
- package/dist/lib/plugins/openapi/graphql/fragment-masking.js.map +1 -1
- package/dist/lib/plugins/openapi/graphql/gql.d.ts +6 -48
- package/dist/lib/plugins/openapi/graphql/gql.js +6 -3
- package/dist/lib/plugins/openapi/graphql/gql.js.map +1 -1
- package/dist/lib/plugins/openapi/graphql/graphql.d.ts +79 -32
- package/dist/lib/plugins/openapi/graphql/graphql.js +199 -662
- package/dist/lib/plugins/openapi/graphql/graphql.js.map +1 -1
- package/dist/lib/plugins/openapi/index.d.ts +4 -3
- package/dist/lib/plugins/openapi/index.js +111 -86
- package/dist/lib/plugins/openapi/index.js.map +1 -1
- package/dist/lib/plugins/openapi/interfaces.d.ts +27 -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.js +67 -4
- package/dist/lib/plugins/openapi/playground/Headers.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/ParamsGrid.d.ts +5 -0
- package/dist/lib/plugins/openapi/playground/ParamsGrid.js +4 -0
- package/dist/lib/plugins/openapi/playground/ParamsGrid.js.map +1 -0
- package/dist/lib/plugins/openapi/playground/PathParams.js +4 -7
- package/dist/lib/plugins/openapi/playground/PathParams.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/Playground.d.ts +21 -1
- package/dist/lib/plugins/openapi/playground/Playground.js +62 -53
- package/dist/lib/plugins/openapi/playground/Playground.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/PlaygroundDialog.js +2 -2
- package/dist/lib/plugins/openapi/playground/PlaygroundDialog.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/QueryParams.js +20 -14
- 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.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 +7 -0
- package/dist/lib/plugins/openapi/post-processors/removeExtensions.js +16 -0
- package/dist/lib/plugins/openapi/post-processors/removeExtensions.js.map +1 -0
- package/dist/lib/plugins/openapi/post-processors/removeExtensions.test.d.ts +1 -0
- package/dist/lib/plugins/openapi/post-processors/removeExtensions.test.js +174 -0
- package/dist/lib/plugins/openapi/post-processors/removeExtensions.test.js.map +1 -0
- 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/post-processors/removePaths.d.ts +11 -0
- package/dist/lib/plugins/openapi/post-processors/removePaths.js +33 -0
- package/dist/lib/plugins/openapi/post-processors/removePaths.js.map +1 -0
- package/dist/lib/plugins/openapi/post-processors/removePaths.test.d.ts +1 -0
- package/dist/lib/plugins/openapi/post-processors/removePaths.test.js +104 -0
- package/dist/lib/plugins/openapi/post-processors/removePaths.test.js.map +1 -0
- package/dist/lib/plugins/openapi/post-processors/traverse.d.ts +1 -0
- package/dist/lib/plugins/openapi/post-processors/traverse.js +2 -0
- package/dist/lib/plugins/openapi/post-processors/traverse.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 +3 -2
- 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/generateSchemaExample.d.ts +0 -1
- package/dist/lib/plugins/openapi/util/generateSchemaExample.js +36 -39
- package/dist/lib/plugins/openapi/util/generateSchemaExample.js.map +1 -1
- 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.d.ts +4 -7
- package/dist/lib/plugins/redirect/index.js +2 -2
- package/dist/lib/plugins/redirect/index.js.map +1 -1
- package/dist/lib/plugins/search-inkeep/index.d.ts +24 -5
- package/dist/lib/plugins/search-inkeep/index.js +41 -5
- package/dist/lib/plugins/search-inkeep/index.js.map +1 -1
- package/dist/lib/plugins/search-inkeep/inkeep.d.ts +3 -4
- package/dist/lib/plugins/search-inkeep/inkeep.js.map +1 -1
- package/dist/lib/ui/Accordion.d.ts +7 -0
- package/dist/lib/ui/Accordion.js +14 -0
- package/dist/lib/ui/Accordion.js.map +1 -0
- package/dist/lib/ui/ActionButton.d.ts +4 -0
- package/dist/lib/ui/ActionButton.js +10 -0
- package/dist/lib/ui/ActionButton.js.map +1 -0
- package/dist/lib/ui/Alert.d.ts +8 -0
- package/dist/lib/ui/Alert.js +23 -0
- package/dist/lib/ui/Alert.js.map +1 -0
- package/dist/lib/ui/AlertDialog.d.ts +20 -0
- package/dist/lib/ui/AlertDialog.js +27 -0
- package/dist/lib/ui/AlertDialog.js.map +1 -0
- package/dist/lib/ui/AspectRatio.d.ts +3 -0
- package/dist/lib/ui/AspectRatio.js +4 -0
- package/dist/lib/ui/AspectRatio.js.map +1 -0
- package/dist/lib/ui/Badge.d.ts +9 -0
- package/dist/lib/ui/Badge.js +22 -0
- package/dist/lib/ui/Badge.js.map +1 -0
- package/dist/lib/ui/Breadcrumb.d.ts +19 -0
- package/dist/lib/ui/Breadcrumb.js +24 -0
- package/dist/lib/ui/Breadcrumb.js.map +1 -0
- package/dist/lib/ui/Button.d.ts +2 -3
- package/dist/lib/ui/Button.js +1 -1
- package/dist/lib/ui/Button.js.map +1 -1
- package/dist/lib/ui/Card.js +1 -1
- package/dist/lib/ui/Card.js.map +1 -1
- package/dist/lib/ui/Carousel.d.ts +18 -0
- package/dist/lib/ui/Carousel.js +99 -0
- package/dist/lib/ui/Carousel.js.map +1 -0
- package/dist/lib/ui/Checkbox.d.ts +10 -0
- package/dist/lib/ui/Checkbox.js +21 -0
- package/dist/lib/ui/Checkbox.js.map +1 -0
- package/dist/lib/ui/Collapsible.d.ts +5 -0
- package/dist/lib/ui/Collapsible.js +6 -0
- package/dist/lib/ui/Collapsible.js.map +1 -0
- package/dist/lib/ui/Command.d.ts +88 -0
- package/dist/lib/ui/Command.js +35 -0
- package/dist/lib/ui/Command.js.map +1 -0
- package/dist/lib/{components → ui}/Dialog.js +2 -2
- package/dist/lib/ui/Dialog.js.map +1 -0
- package/dist/lib/ui/Form.d.ts +23 -0
- package/dist/lib/ui/Form.js +63 -0
- package/dist/lib/ui/Form.js.map +1 -0
- package/dist/lib/ui/HoverCard.d.ts +6 -0
- package/dist/lib/ui/HoverCard.js +10 -0
- package/dist/lib/ui/HoverCard.js.map +1 -0
- package/dist/lib/ui/Label.d.ts +5 -0
- package/dist/lib/ui/Label.js +10 -0
- package/dist/lib/ui/Label.js.map +1 -0
- package/dist/lib/ui/Pagination.d.ts +28 -0
- package/dist/lib/ui/Pagination.js +24 -0
- package/dist/lib/ui/Pagination.js.map +1 -0
- package/dist/lib/ui/Popover.d.ts +6 -0
- package/dist/lib/ui/Popover.js +10 -0
- package/dist/lib/ui/Popover.js.map +1 -0
- package/dist/lib/ui/Progress.d.ts +4 -0
- package/dist/lib/ui/Progress.js +8 -0
- package/dist/lib/ui/Progress.js.map +1 -0
- package/dist/lib/ui/RadioGroup.d.ts +5 -0
- package/dist/lib/ui/RadioGroup.js +15 -0
- package/dist/lib/ui/RadioGroup.js.map +1 -0
- package/dist/lib/ui/ScrollArea.d.ts +5 -0
- package/dist/lib/ui/ScrollArea.js +12 -0
- package/dist/lib/ui/ScrollArea.js.map +1 -0
- package/dist/lib/{components → ui}/Select.js +2 -2
- package/dist/lib/ui/Select.js.map +1 -0
- package/dist/lib/ui/Skeleton.d.ts +2 -0
- package/dist/lib/ui/Skeleton.js +7 -0
- package/dist/lib/ui/Skeleton.js.map +1 -0
- package/dist/lib/ui/Slider.d.ts +4 -0
- package/dist/lib/ui/Slider.js +8 -0
- package/dist/lib/ui/Slider.js.map +1 -0
- package/dist/lib/ui/Switch.d.ts +4 -0
- package/dist/lib/ui/Switch.js +8 -0
- package/dist/lib/ui/Switch.js.map +1 -0
- package/dist/lib/ui/Textarea.d.ts +4 -0
- package/dist/lib/ui/Textarea.js +9 -0
- package/dist/lib/ui/Textarea.js.map +1 -0
- package/dist/lib/ui/Toggle.d.ts +12 -0
- package/dist/lib/ui/Toggle.js +26 -0
- package/dist/lib/ui/Toggle.js.map +1 -0
- package/dist/lib/ui/ToggleGroup.d.ts +12 -0
- package/dist/lib/ui/ToggleGroup.js +21 -0
- package/dist/lib/ui/ToggleGroup.js.map +1 -0
- package/dist/lib/ui/Tooltip.d.ts +7 -0
- package/dist/lib/ui/Tooltip.js +11 -0
- package/dist/lib/ui/Tooltip.js.map +1 -0
- package/dist/lib/util/MdxComponents.d.ts +19 -20
- package/dist/lib/util/MdxComponents.js +3 -5
- package/dist/lib/util/MdxComponents.js.map +1 -1
- package/dist/lib/util/createVariantComponent.d.ts +2 -2
- package/dist/lib/util/invariant.d.ts +9 -0
- package/dist/lib/util/invariant.js +7 -3
- package/dist/lib/util/invariant.js.map +1 -1
- 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/traverse.d.ts +9 -0
- package/dist/lib/util/traverse.js +22 -0
- package/dist/lib/util/traverse.js.map +1 -0
- package/dist/lib/util/useExposedProps.d.ts +2 -0
- package/dist/lib/util/useExposedProps.js +9 -0
- package/dist/lib/util/useExposedProps.js.map +1 -0
- package/dist/lib/util/useIsomorphicLayoutEffect.d.ts +3 -0
- package/dist/lib/util/useIsomorphicLayoutEffect.js +4 -0
- package/dist/lib/util/useIsomorphicLayoutEffect.js.map +1 -0
- package/dist/lib/util/useOnScreen.d.ts +4 -0
- package/dist/lib/util/useOnScreen.js +19 -0
- package/dist/lib/util/useOnScreen.js.map +1 -0
- package/dist/lib/util/useScrollToAnchor.d.ts +1 -0
- package/dist/lib/util/useScrollToAnchor.js +27 -16
- package/dist/lib/util/useScrollToAnchor.js.map +1 -1
- package/dist/lib/util/useScrollToTop.js +1 -1
- 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 +28 -10
- package/dist/vite/build.js.map +1 -1
- package/dist/vite/config.d.ts +6 -10
- package/dist/vite/config.js +100 -83
- package/dist/vite/config.js.map +1 -1
- package/dist/vite/config.test.js +11 -5
- 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 +1 -0
- package/dist/vite/dev-server.js +27 -7
- package/dist/vite/dev-server.js.map +1 -1
- package/dist/vite/html.js +0 -2
- package/dist/vite/html.js.map +1 -1
- package/dist/vite/output.d.ts +101 -0
- package/dist/vite/output.js +62 -0
- package/dist/vite/output.js.map +1 -0
- package/dist/vite/plugin-api.d.ts +1 -1
- package/dist/vite/plugin-api.js +162 -22
- package/dist/vite/plugin-api.js.map +1 -1
- package/dist/vite/plugin-auth.js +4 -1
- package/dist/vite/plugin-auth.js.map +1 -1
- package/dist/vite/plugin-component.js +16 -11
- package/dist/vite/plugin-component.js.map +1 -1
- package/dist/vite/plugin-config-reload.d.ts +1 -2
- package/dist/vite/plugin-config-reload.js +0 -2
- package/dist/vite/plugin-config-reload.js.map +1 -1
- package/dist/vite/plugin-config.d.ts +2 -3
- package/dist/vite/plugin-config.js +22 -3
- package/dist/vite/plugin-config.js.map +1 -1
- package/dist/vite/plugin-docs.js +13 -2
- package/dist/vite/plugin-docs.js.map +1 -1
- package/dist/vite/plugin-docs.test.js +15 -23
- package/dist/vite/plugin-docs.test.js.map +1 -1
- package/dist/vite/plugin-frontmatter.d.ts +2 -1
- package/dist/vite/plugin-frontmatter.js +27 -24
- package/dist/vite/plugin-frontmatter.js.map +1 -1
- package/dist/vite/plugin-mdx.d.ts +0 -6
- package/dist/vite/plugin-mdx.js +85 -6
- package/dist/vite/plugin-mdx.js.map +1 -1
- package/dist/vite/plugin-search.d.ts +3 -0
- package/dist/vite/plugin-search.js +26 -0
- package/dist/vite/plugin-search.js.map +1 -0
- package/dist/vite/plugin-sidebar.js +4 -6
- package/dist/vite/plugin-sidebar.js.map +1 -1
- package/dist/vite/{plugin-custom-css.d.ts → plugin-theme-css.d.ts} +2 -2
- package/dist/vite/plugin-theme-css.js +114 -0
- package/dist/vite/plugin-theme-css.js.map +1 -0
- package/dist/vite/plugin.d.ts +1 -2
- package/dist/vite/plugin.js +10 -6
- package/dist/vite/plugin.js.map +1 -1
- package/dist/vite/prerender.d.ts +3 -2
- package/dist/vite/prerender.js +7 -6
- package/dist/vite/prerender.js.map +1 -1
- package/dist/vite/remarkStaticGeneration.d.ts +3 -0
- package/dist/vite/remarkStaticGeneration.js +125 -0
- package/dist/vite/remarkStaticGeneration.js.map +1 -0
- package/dist/vite/sitemap.d.ts +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 +7 -0
- package/dist/zuplo/env.js +12 -0
- package/dist/zuplo/env.js.map +1 -0
- 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 +3 -0
- package/dist/zuplo/with-zuplo.js +9 -0
- package/dist/zuplo/with-zuplo.js.map +1 -0
- package/lib/AuthenticationPlugin-Du8cLBSr.js +58 -0
- package/lib/AuthenticationPlugin-Du8cLBSr.js.map +1 -0
- package/lib/CategoryHeading-MYL1u_6K.js +10 -0
- package/lib/{CategoryHeading-C7VfgpFZ.js.map → CategoryHeading-MYL1u_6K.js.map} +1 -1
- package/lib/ClientOnly-E7hGysn1.js +11 -0
- package/lib/ClientOnly-E7hGysn1.js.map +1 -0
- package/lib/Markdown-Cyrx_JrO.js +15212 -0
- package/lib/Markdown-Cyrx_JrO.js.map +1 -0
- package/lib/MdxPage-BuG8Tuwc.js +193 -0
- package/lib/MdxPage-BuG8Tuwc.js.map +1 -0
- package/lib/OpenApiRoute-UrC_t0e5.js +36 -0
- package/lib/OpenApiRoute-UrC_t0e5.js.map +1 -0
- package/lib/OperationList-CDt1xdc4.js +5169 -0
- package/lib/OperationList-CDt1xdc4.js.map +1 -0
- package/lib/Select-CnCZ4WhS.js +223 -0
- package/lib/Select-CnCZ4WhS.js.map +1 -0
- package/lib/SlotletProvider-mQiPDQIH.js +221 -0
- package/lib/SlotletProvider-mQiPDQIH.js.map +1 -0
- package/lib/Spinner-BlzrEEk1.js +51 -0
- package/lib/Spinner-BlzrEEk1.js.map +1 -0
- package/lib/SyntaxHighlight-B0L4SC_N.js +2986 -0
- package/lib/SyntaxHighlight-B0L4SC_N.js.map +1 -0
- package/lib/ZudokuContext-BTUJPpQl.js +1229 -0
- package/lib/ZudokuContext-BTUJPpQl.js.map +1 -0
- package/lib/_commonjsHelpers-BkfeUUK-.js +29 -0
- package/lib/_commonjsHelpers-BkfeUUK-.js.map +1 -0
- package/lib/chunk-SYFQ2XB5-BPvC-soB.js +1821 -0
- package/lib/chunk-SYFQ2XB5-BPvC-soB.js.map +1 -0
- package/lib/circular-DxaIIlWD.js +15409 -0
- package/lib/circular-DxaIIlWD.js.map +1 -0
- package/lib/cn-qaFjX9_3.js +2279 -0
- package/lib/cn-qaFjX9_3.js.map +1 -0
- package/lib/context-rwLGh-6_.js +22 -0
- package/lib/context-rwLGh-6_.js.map +1 -0
- package/lib/createServer-CjNktZzL.js +12603 -0
- package/lib/createServer-CjNktZzL.js.map +1 -0
- package/lib/hook-FT3SJLe_.js +227 -0
- package/lib/hook-FT3SJLe_.js.map +1 -0
- package/lib/index-B7mqiOei.js +509 -0
- package/lib/index-B7mqiOei.js.map +1 -0
- package/lib/{index-D06ATMgg.js → index-CjJS0l4l.js} +2 -2
- package/lib/{index-D06ATMgg.js.map → index-CjJS0l4l.js.map} +1 -1
- package/lib/index-Djenk2Hj.js +36 -0
- package/lib/index-Djenk2Hj.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-Eb1oiHbM.js +1997 -0
- package/lib/index-Eb1oiHbM.js.map +1 -0
- package/lib/index.esm-9-TF9KQB.js +692 -0
- package/lib/index.esm-9-TF9KQB.js.map +1 -0
- package/lib/index.esm-CrSoEshU.js +1207 -0
- package/lib/index.esm-CrSoEshU.js.map +1 -0
- package/lib/invariant-Caa8-XvF.js +26 -0
- package/lib/invariant-Caa8-XvF.js.map +1 -0
- package/lib/joinUrl-nLx9pD-Z.js +20 -0
- package/lib/joinUrl-nLx9pD-Z.js.map +1 -0
- package/lib/jsx-runtime-Bdg6XQ1m.js +446 -0
- package/lib/jsx-runtime-Bdg6XQ1m.js.map +1 -0
- package/lib/post-processors/removeExtensions.js +11 -0
- package/lib/post-processors/removeExtensions.js.map +1 -0
- package/lib/post-processors/removeParameters.js +48 -0
- package/lib/post-processors/removeParameters.js.map +1 -0
- package/lib/post-processors/removePaths.js +28 -0
- package/lib/post-processors/removePaths.js.map +1 -0
- package/lib/post-processors/traverse.js +15 -0
- package/lib/post-processors/traverse.js.map +1 -0
- 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/state-mM7uaXTW.js +202 -0
- package/lib/state-mM7uaXTW.js.map +1 -0
- package/lib/ui/Accordion.js +47 -0
- package/lib/ui/Accordion.js.map +1 -0
- package/lib/ui/ActionButton.js +24 -0
- package/lib/ui/ActionButton.js.map +1 -0
- package/lib/ui/Alert.js +51 -0
- package/lib/ui/Alert.js.map +1 -0
- package/lib/ui/AlertDialog.js +114 -0
- package/lib/ui/AlertDialog.js.map +1 -0
- package/lib/ui/AspectRatio.js +6 -0
- package/lib/ui/AspectRatio.js.map +1 -0
- package/lib/ui/Badge.js +28 -0
- package/lib/ui/Badge.js.map +1 -0
- package/lib/ui/Breadcrumb.js +94 -0
- package/lib/ui/Breadcrumb.js.map +1 -0
- package/lib/ui/Button.js +49 -0
- package/lib/ui/Button.js.map +1 -0
- package/lib/ui/Callout.js +77 -0
- package/lib/ui/Callout.js.map +1 -0
- package/lib/ui/Card.js +62 -0
- package/lib/ui/Card.js.map +1 -0
- package/lib/ui/Carousel.js +1416 -0
- package/lib/ui/Carousel.js.map +1 -0
- package/lib/ui/Checkbox.js +39 -0
- package/lib/ui/Checkbox.js.map +1 -0
- package/lib/ui/Collapsible.js +8 -0
- package/lib/ui/Collapsible.js.map +1 -0
- package/lib/ui/Command.js +129 -0
- package/lib/ui/Command.js.map +1 -0
- package/lib/ui/Dialog.js +101 -0
- package/lib/ui/Dialog.js.map +1 -0
- package/lib/ui/Drawer.js +1154 -0
- package/lib/ui/Drawer.js.map +1 -0
- package/lib/ui/DropdownMenu.js +145 -0
- package/lib/ui/DropdownMenu.js.map +1 -0
- package/lib/ui/Form.js +95 -0
- package/lib/ui/Form.js.map +1 -0
- package/lib/ui/HoverCard.js +24 -0
- package/lib/ui/HoverCard.js.map +1 -0
- package/lib/ui/Input.js +22 -0
- package/lib/ui/Input.js.map +1 -0
- package/lib/ui/Label.js +20 -0
- package/lib/ui/Label.js.map +1 -0
- package/lib/ui/Pagination.js +106 -0
- package/lib/ui/Pagination.js.map +1 -0
- package/lib/ui/Popover.js +24 -0
- package/lib/ui/Popover.js.map +1 -0
- package/lib/ui/Progress.js +27 -0
- package/lib/ui/Progress.js.map +1 -0
- package/lib/ui/RadioGroup.js +32 -0
- package/lib/ui/RadioGroup.js.map +1 -0
- package/lib/ui/ScrollArea.js +39 -0
- package/lib/ui/ScrollArea.js.map +1 -0
- package/lib/ui/Select.js +122 -0
- package/lib/ui/Select.js.map +1 -0
- package/lib/ui/Skeleton.js +18 -0
- package/lib/ui/Skeleton.js.map +1 -0
- package/lib/ui/Slider.js +24 -0
- package/lib/ui/Slider.js.map +1 -0
- package/lib/ui/Switch.js +28 -0
- package/lib/ui/Switch.js.map +1 -0
- package/lib/ui/Tabs.js +47 -0
- package/lib/ui/Tabs.js.map +1 -0
- package/lib/ui/Textarea.js +21 -0
- package/lib/ui/Textarea.js.map +1 -0
- package/lib/ui/Toggle.js +38 -0
- package/lib/ui/Toggle.js.map +1 -0
- package/lib/ui/ToggleGroup.js +42 -0
- package/lib/ui/ToggleGroup.js.map +1 -0
- package/lib/ui/Tooltip.js +24 -0
- package/lib/ui/Tooltip.js.map +1 -0
- package/lib/useExposedProps-BLKFBylA.js +9 -0
- package/lib/useExposedProps-BLKFBylA.js.map +1 -0
- package/lib/useScrollToAnchor-BZsGmBng.js +284 -0
- package/lib/useScrollToAnchor-BZsGmBng.js.map +1 -0
- package/lib/zudoku.auth-auth0.js +24 -20
- package/lib/zudoku.auth-auth0.js.map +1 -1
- package/lib/zudoku.auth-clerk.js +79 -51
- package/lib/zudoku.auth-clerk.js.map +1 -1
- package/lib/zudoku.auth-openid.js +610 -617
- package/lib/zudoku.auth-openid.js.map +1 -1
- package/lib/zudoku.components.js +1009 -3237
- package/lib/zudoku.components.js.map +1 -1
- package/lib/zudoku.plugin-api-catalog.js +123 -0
- package/lib/zudoku.plugin-api-catalog.js.map +1 -0
- package/lib/zudoku.plugin-api-keys.js +72 -78
- package/lib/zudoku.plugin-api-keys.js.map +1 -1
- package/lib/zudoku.plugin-custom-pages.js +17 -8
- package/lib/zudoku.plugin-custom-pages.js.map +1 -1
- package/lib/zudoku.plugin-markdown.js +16 -15
- package/lib/zudoku.plugin-markdown.js.map +1 -1
- package/lib/zudoku.plugin-openapi.js +8 -11
- package/lib/zudoku.plugin-openapi.js.map +1 -1
- package/lib/zudoku.plugin-redirect.js +2 -2
- package/lib/zudoku.plugin-redirect.js.map +1 -1
- package/lib/zudoku.plugin-search-inkeep.js +53 -28
- package/lib/zudoku.plugin-search-inkeep.js.map +1 -1
- package/package.json +120 -70
- package/src/app/demo.tsx +1 -5
- package/src/app/entry.client.tsx +16 -1
- package/src/app/entry.server.tsx +62 -55
- package/src/app/main.css +58 -46
- package/src/app/main.tsx +38 -18
- package/src/app/sentry.ts +24 -0
- package/src/app/standalone.tsx +1 -5
- package/src/app/tailwind.ts +67 -52
- package/src/lib/authentication/AuthenticationPlugin.tsx +4 -1
- package/src/lib/authentication/authentication.ts +3 -3
- package/src/lib/authentication/components/CallbackHandler.tsx +20 -51
- package/src/lib/authentication/components/SignIn.tsx +1 -1
- package/src/lib/authentication/components/SignOut.tsx +3 -2
- package/src/lib/authentication/hook.ts +1 -3
- package/src/lib/authentication/providers/auth0.tsx +17 -14
- package/src/lib/authentication/providers/clerk.tsx +38 -7
- package/src/lib/authentication/providers/openid.tsx +41 -40
- package/src/lib/authentication/state.ts +50 -9
- package/{LICENSE.md → src/lib/authentication/use-broadcast/LICENSE.md} +2 -2
- package/src/lib/authentication/use-broadcast/shared.ts +372 -0
- package/src/lib/authentication/use-broadcast/useBroadcast.ts +146 -0
- package/src/lib/components/AnchorLink.tsx +6 -3
- package/src/lib/components/Autocomplete.tsx +111 -0
- package/src/lib/components/Bootstrap.tsx +36 -16
- package/src/lib/components/ClientOnly.tsx +6 -3
- package/src/lib/components/DeveloperHint.tsx +6 -1
- package/src/lib/components/Header.tsx +89 -50
- package/src/lib/components/Heading.tsx +13 -13
- package/src/lib/components/Layout.tsx +55 -38
- package/src/lib/components/Markdown.tsx +15 -16
- package/src/lib/components/MobileTopNavigation.tsx +30 -27
- package/src/lib/components/NotFoundPage.tsx +1 -1
- package/src/lib/components/PathRenderer.tsx +59 -0
- package/src/lib/components/ReactMarkdown.license.txt +21 -0
- package/src/lib/components/ReactMarkdown.tsx +264 -0
- package/src/lib/components/Search.tsx +4 -4
- package/src/lib/components/SlotletProvider.tsx +16 -7
- package/src/lib/components/StatusPage.tsx +91 -0
- package/src/lib/components/SyntaxHighlight.tsx +99 -50
- package/src/lib/components/ThemeSwitch.tsx +26 -0
- package/src/lib/components/TopNavigation.tsx +41 -20
- package/src/lib/components/Zudoku.tsx +108 -0
- package/src/lib/components/cache.ts +15 -0
- package/src/lib/components/context/ViewportAnchorContext.tsx +20 -6
- package/src/lib/components/context/ZudokuContext.ts +15 -18
- package/src/lib/components/context/ZudokuProvider.tsx +2 -2
- package/src/lib/components/index.ts +27 -6
- package/src/lib/components/navigation/Sidebar.tsx +20 -10
- package/src/lib/components/navigation/SidebarBadge.tsx +13 -11
- package/src/lib/components/navigation/SidebarCategory.tsx +52 -44
- package/src/lib/components/navigation/SidebarItem.tsx +24 -28
- package/src/lib/components/navigation/SidebarWrapper.tsx +3 -2
- package/src/lib/components/navigation/utils.ts +3 -3
- package/src/lib/core/RouteGuard.tsx +35 -0
- package/src/lib/core/{DevPortalContext.ts → ZudokuContext.ts} +13 -20
- package/src/lib/core/plugins.ts +17 -17
- package/src/lib/errors/ErrorAlert.tsx +20 -6
- package/src/lib/errors/RouterError.tsx +1 -1
- package/src/lib/oas/graphql/circular.ts +50 -0
- package/src/lib/oas/graphql/index.ts +113 -69
- package/src/lib/oas/parser/dereference/index.ts +8 -4
- package/src/lib/oas/parser/upgrade/index.ts +22 -28
- package/src/lib/plugins/api-catalog/Catalog.tsx +123 -0
- package/src/lib/plugins/api-catalog/index.tsx +64 -0
- package/src/lib/plugins/api-keys/CreateApiKey.tsx +3 -3
- 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 +13 -10
- package/src/lib/plugins/custom-pages/CustomPage.tsx +18 -0
- package/src/lib/plugins/custom-pages/index.tsx +14 -12
- package/src/lib/plugins/markdown/MdxPage.tsx +46 -10
- package/src/lib/plugins/markdown/index.tsx +7 -4
- package/src/lib/plugins/markdown/resolver.ts +2 -4
- package/src/lib/plugins/openapi/CollapsibleCode.tsx +83 -0
- package/src/lib/plugins/openapi/ColorizedParam.tsx +49 -23
- package/src/lib/plugins/openapi/Endpoint.tsx +10 -15
- package/src/lib/plugins/openapi/OpenApiRoute.tsx +51 -0
- package/src/lib/plugins/openapi/OperationList.tsx +116 -54
- package/src/lib/plugins/openapi/OperationListItem.tsx +39 -5
- package/src/lib/plugins/openapi/ParameterListItem.tsx +36 -31
- package/src/lib/plugins/openapi/PlaygroundDialogWrapper.tsx +7 -0
- package/src/lib/plugins/openapi/RequestBodySidecarBox.tsx +15 -33
- package/src/lib/plugins/openapi/ResponsesSidecarBox.tsx +46 -58
- package/src/lib/plugins/openapi/Sidecar.tsx +105 -107
- package/src/lib/plugins/openapi/SidecarBox.tsx +4 -16
- package/src/lib/plugins/openapi/SidecarExamples.tsx +163 -0
- package/src/lib/plugins/openapi/client/GraphQLClient.tsx +65 -0
- package/src/lib/plugins/openapi/client/GraphQLContext.tsx +16 -0
- package/src/lib/plugins/openapi/client/createServer.ts +8 -2
- package/src/lib/plugins/openapi/client/useCreateQuery.ts +18 -0
- package/src/lib/plugins/openapi/context.tsx +2 -2
- package/src/lib/plugins/openapi/graphql/fragment-masking.ts +11 -18
- package/src/lib/plugins/openapi/graphql/gql.ts +19 -28
- package/src/lib/plugins/openapi/graphql/graphql.ts +284 -690
- package/src/lib/plugins/openapi/index.tsx +147 -109
- package/src/lib/plugins/openapi/interfaces.ts +32 -2
- package/src/lib/plugins/openapi/playground/ExamplesDropdown.tsx +54 -0
- package/src/lib/plugins/openapi/playground/Headers.tsx +137 -39
- package/src/lib/plugins/openapi/playground/ParamsGrid.tsx +8 -0
- package/src/lib/plugins/openapi/playground/PathParams.tsx +30 -61
- package/src/lib/plugins/openapi/playground/Playground.tsx +257 -211
- package/src/lib/plugins/openapi/playground/PlaygroundDialog.tsx +3 -3
- package/src/lib/plugins/openapi/playground/QueryParams.tsx +77 -80
- 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 +202 -0
- package/src/lib/plugins/openapi/post-processors/removeExtensions.ts +27 -0
- 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/post-processors/removePaths.test.ts +126 -0
- package/src/lib/plugins/openapi/post-processors/removePaths.ts +55 -0
- package/src/lib/plugins/openapi/post-processors/traverse.ts +1 -0
- package/src/lib/plugins/openapi/schema/{SchemaComponents.tsx → SchemaPropertyItem.tsx} +34 -9
- package/src/lib/plugins/openapi/schema/SchemaView.tsx +9 -3
- package/src/lib/plugins/openapi/schema/utils.ts +4 -0
- package/src/lib/plugins/openapi/util/generateSchemaExample.ts +44 -43
- 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 +6 -10
- package/src/lib/plugins/search-inkeep/index.tsx +80 -25
- package/src/lib/plugins/search-inkeep/inkeep.ts +3 -9
- package/src/lib/ui/Accordion.tsx +56 -0
- package/src/lib/ui/ActionButton.tsx +28 -0
- package/src/lib/ui/{Note.tsx → Alert.tsx} +11 -10
- package/src/lib/ui/AlertDialog.tsx +139 -0
- package/src/lib/ui/AspectRatio.tsx +5 -0
- package/src/lib/ui/Badge.tsx +37 -0
- package/src/lib/ui/Breadcrumb.tsx +115 -0
- package/src/lib/ui/Button.tsx +1 -1
- package/src/lib/ui/Card.tsx +1 -1
- package/src/lib/ui/Carousel.tsx +260 -0
- package/src/lib/ui/Checkbox.tsx +45 -0
- package/src/lib/ui/Collapsible.tsx +9 -0
- package/src/lib/ui/Command.tsx +171 -0
- package/src/lib/{components → ui}/Dialog.tsx +4 -3
- package/src/lib/ui/Form.tsx +177 -0
- package/src/lib/ui/HoverCard.tsx +27 -0
- package/src/lib/ui/Label.tsx +24 -0
- package/src/lib/ui/Pagination.tsx +117 -0
- package/src/lib/ui/Popover.tsx +29 -0
- package/src/lib/ui/Progress.tsx +26 -0
- package/src/lib/ui/RadioGroup.tsx +42 -0
- package/src/lib/ui/ScrollArea.tsx +46 -0
- package/src/lib/{components → ui}/Select.tsx +1 -1
- package/src/lib/ui/Skeleton.tsx +15 -0
- package/src/lib/ui/Slider.tsx +26 -0
- package/src/lib/ui/Switch.tsx +27 -0
- package/src/lib/ui/Textarea.tsx +23 -0
- package/src/lib/ui/Toggle.tsx +43 -0
- package/src/lib/ui/ToggleGroup.tsx +59 -0
- package/src/lib/ui/Tooltip.tsx +28 -0
- package/src/lib/util/MdxComponents.tsx +5 -10
- package/src/lib/util/createVariantComponent.tsx +2 -2
- package/src/lib/util/invariant.ts +15 -3
- package/src/lib/util/joinUrl.test.ts +62 -0
- package/src/lib/util/joinUrl.ts +57 -0
- package/src/lib/util/traverse.ts +35 -0
- package/src/lib/util/useExposedProps.tsx +16 -0
- package/src/lib/util/useIsomorphicLayoutEffect.ts +5 -0
- package/src/lib/util/useOnScreen.ts +32 -0
- package/src/lib/util/useScrollToAnchor.ts +33 -16
- package/src/lib/util/useScrollToTop.ts +1 -1
- package/dist/internal.d.ts +0 -1
- package/dist/internal.js +0 -2
- package/dist/internal.js.map +0 -1
- package/dist/lib/components/DevPortal.js.map +0 -1
- package/dist/lib/components/Dialog.js.map +0 -1
- package/dist/lib/components/Select.js.map +0 -1
- package/dist/lib/components/context/ThemeContext.d.ts +0 -2
- package/dist/lib/components/context/ThemeContext.js +0 -7
- package/dist/lib/components/context/ThemeContext.js.map +0 -1
- package/dist/lib/components/context/ThemeProvider.d.ts +0 -4
- package/dist/lib/components/context/ThemeProvider.js +0 -23
- package/dist/lib/components/context/ThemeProvider.js.map +0 -1
- package/dist/lib/core/DevPortalContext.js.map +0 -1
- package/dist/lib/plugins/openapi/Route.d.ts +0 -6
- package/dist/lib/plugins/openapi/Route.js +0 -8
- package/dist/lib/plugins/openapi/Route.js.map +0 -1
- package/dist/lib/plugins/openapi/client/createMemoryClient.d.ts +0 -12
- package/dist/lib/plugins/openapi/client/createMemoryClient.js +0 -46
- package/dist/lib/plugins/openapi/client/createMemoryClient.js.map +0 -1
- package/dist/lib/plugins/openapi/client/createWorkerClient.d.ts +0 -10
- package/dist/lib/plugins/openapi/client/createWorkerClient.js +0 -61
- package/dist/lib/plugins/openapi/client/createWorkerClient.js.map +0 -1
- package/dist/lib/plugins/openapi/client/interfaces.d.ts +0 -4
- package/dist/lib/plugins/openapi/client/interfaces.js +0 -2
- package/dist/lib/plugins/openapi/client/interfaces.js.map +0 -1
- package/dist/lib/plugins/openapi/client/worker.js +0 -20
- 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 -2
- package/dist/lib/plugins/openapi-worker.js.map +0 -1
- package/dist/lib/plugins/search-inkeep/InkeepCustomTrigger.d.ts +0 -2
- package/dist/lib/plugins/search-inkeep/InkeepCustomTrigger.js +0 -3
- package/dist/lib/plugins/search-inkeep/InkeepCustomTrigger.js.map +0 -1
- package/dist/lib/themeToggle.d.ts +0 -1
- package/dist/lib/themeToggle.js +0 -7
- package/dist/lib/themeToggle.js.map +0 -1
- package/dist/lib/ui/Note.d.ts +0 -8
- package/dist/lib/ui/Note.js +0 -23
- package/dist/lib/ui/Note.js.map +0 -1
- package/dist/lib/util/createWaitForNotify.d.ts +0 -1
- package/dist/lib/util/createWaitForNotify.js +0 -15
- package/dist/lib/util/createWaitForNotify.js.map +0 -1
- package/dist/vite/plugin-custom-css.js +0 -55
- package/dist/vite/plugin-custom-css.js.map +0 -1
- package/dist/vite/plugin-html-transform.d.ts +0 -2
- package/dist/vite/plugin-html-transform.js +0 -15
- package/dist/vite/plugin-html-transform.js.map +0 -1
- package/lib/AnchorLink-DovtSBJk.js +0 -705
- package/lib/AnchorLink-DovtSBJk.js.map +0 -1
- package/lib/AuthenticationPlugin-Cnqy9csQ.js +0 -55
- package/lib/AuthenticationPlugin-Cnqy9csQ.js.map +0 -1
- package/lib/CategoryHeading-C7VfgpFZ.js +0 -10
- package/lib/DeveloperHint-CNyuFROc.js +0 -16
- package/lib/DeveloperHint-CNyuFROc.js.map +0 -1
- package/lib/ErrorPage-CUz-Zzmx.js +0 -16
- package/lib/ErrorPage-CUz-Zzmx.js.map +0 -1
- package/lib/InkeepCustomTrigger-CE5-K5ex.js +0 -6
- package/lib/InkeepCustomTrigger-CE5-K5ex.js.map +0 -1
- package/lib/Input-x-t53FyR.js +0 -2229
- package/lib/Input-x-t53FyR.js.map +0 -1
- package/lib/Markdown-C-0TaxoY.js +0 -20441
- package/lib/Markdown-C-0TaxoY.js.map +0 -1
- package/lib/MdxPage-C5I9c7R1.js +0 -173
- package/lib/MdxPage-C5I9c7R1.js.map +0 -1
- package/lib/OperationList-qsBOguHS.js +0 -601
- package/lib/OperationList-qsBOguHS.js.map +0 -1
- package/lib/Route-DlKvXPAO.js +0 -13
- package/lib/Route-DlKvXPAO.js.map +0 -1
- package/lib/SidebarBadge-DaA0-bFW.js +0 -503
- package/lib/SidebarBadge-DaA0-bFW.js.map +0 -1
- package/lib/SlotletProvider-BGEs7yyu.js +0 -240
- package/lib/SlotletProvider-BGEs7yyu.js.map +0 -1
- package/lib/Spinner-3cQDBVGr.js +0 -7
- package/lib/Spinner-3cQDBVGr.js.map +0 -1
- package/lib/ZudokuContext-DSipF8sq.js +0 -1222
- package/lib/ZudokuContext-DSipF8sq.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-DaFlmuyf.js +0 -18111
- package/lib/assets/worker-DaFlmuyf.js.map +0 -1
- package/lib/index-BIl-R3aH.js +0 -5952
- package/lib/index-BIl-R3aH.js.map +0 -1
- package/lib/index-CKmSo0py.js +0 -124
- package/lib/index-CKmSo0py.js.map +0 -1
- package/lib/index-CkwDvuPt.js.map +0 -1
- package/lib/index-DJqnphbT.js +0 -35
- package/lib/index-DJqnphbT.js.map +0 -1
- package/lib/index-Dssw7Gff.js +0 -2867
- package/lib/index-Dssw7Gff.js.map +0 -1
- package/lib/index-SrtqdZ3j.js +0 -1781
- package/lib/index-SrtqdZ3j.js.map +0 -1
- package/lib/jsx-runtime-B6kdoens.js +0 -635
- package/lib/jsx-runtime-B6kdoens.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-markup-templating-DZrrEs0A.js +0 -62
- package/lib/prism-markup-templating-DZrrEs0A.js.map +0 -1
- package/lib/prism-php.min-o7FpoMP_.js +0 -11
- package/lib/prism-php.min-o7FpoMP_.js.map +0 -1
- package/lib/prism-ruby.min-C7LwcKyz.js +0 -10
- package/lib/prism-typescript.min-oSVeWCAd.js +0 -6
- package/lib/router-Oe6YmY6B.js +0 -3024
- package/lib/router-Oe6YmY6B.js.map +0 -1
- package/lib/state-CsuHT8ZO.js +0 -183
- package/lib/state-CsuHT8ZO.js.map +0 -1
- package/lib/urql-core-KJnLL26g.js +0 -1455
- package/lib/urql-core-KJnLL26g.js.map +0 -1
- package/lib/zudoku.openapi-worker.js +0 -16255
- package/lib/zudoku.openapi-worker.js.map +0 -1
- package/src/lib/components/DevPortal.tsx +0 -111
- package/src/lib/components/context/ThemeContext.tsx +0 -8
- package/src/lib/components/context/ThemeProvider.tsx +0 -27
- package/src/lib/plugins/openapi/Route.tsx +0 -20
- package/src/lib/plugins/openapi/client/createMemoryClient.ts +0 -51
- package/src/lib/plugins/openapi/client/createWorkerClient.ts +0 -75
- package/src/lib/plugins/openapi/client/interfaces.ts +0 -5
- package/src/lib/plugins/openapi/client/worker.ts +0 -30
- package/src/lib/plugins/openapi/playground/ResponseTab.tsx +0 -76
- package/src/lib/plugins/openapi-worker.ts +0 -1
- package/src/lib/plugins/search-inkeep/InkeepCustomTrigger.tsx +0 -3
- package/src/lib/themeToggle.ts +0 -7
- package/src/lib/util/createWaitForNotify.ts +0 -18
- /package/dist/lib/plugins/openapi/{client/worker.d.ts → playground/result-panel/convertToTypes.test.d.ts} +0 -0
- /package/dist/lib/plugins/openapi/schema/{SchemaComponents.d.ts → SchemaPropertyItem.d.ts} +0 -0
- /package/dist/lib/{components → ui}/Dialog.d.ts +0 -0
- /package/dist/lib/{components → ui}/Select.d.ts +0 -0
|
@@ -1,167 +1,168 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
import { j as
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
(function(t) {
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
1
|
+
var Je = Object.defineProperty;
|
|
2
|
+
var Oe = (t, e, n) => e in t ? Je(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n;
|
|
3
|
+
var b = (t, e, n) => Oe(t, typeof e != "symbol" ? e + "" : e, n);
|
|
4
|
+
import { j as G } from "./jsx-runtime-Bdg6XQ1m.js";
|
|
5
|
+
import { g as ze } from "./_commonjsHelpers-BkfeUUK-.js";
|
|
6
|
+
import { C as De } from "./ClientOnly-E7hGysn1.js";
|
|
7
|
+
import { j as ae } from "./joinUrl-nLx9pD-Z.js";
|
|
8
|
+
import { A as Ne } from "./AuthenticationPlugin-Du8cLBSr.js";
|
|
9
|
+
import { u as Ke } from "./ZudokuContext-BTUJPpQl.js";
|
|
10
|
+
import { f as We } from "./chunk-SYFQ2XB5-BPvC-soB.js";
|
|
11
|
+
import { Z as He } from "./invariant-Caa8-XvF.js";
|
|
12
|
+
import { u as x } from "./state-mM7uaXTW.js";
|
|
13
|
+
var N = { exports: {} }, $e = N.exports, se;
|
|
14
|
+
function Fe() {
|
|
15
|
+
return se || (se = 1, function(t) {
|
|
16
|
+
(function(e, n) {
|
|
17
|
+
t.exports ? t.exports = n() : e.log = n();
|
|
18
|
+
})($e, function() {
|
|
19
|
+
var e = function() {
|
|
20
|
+
}, n = "undefined", o = typeof window !== n && typeof window.navigator !== n && /Trident\/|MSIE /.test(window.navigator.userAgent), a = [
|
|
21
|
+
"trace",
|
|
22
|
+
"debug",
|
|
23
|
+
"info",
|
|
24
|
+
"warn",
|
|
25
|
+
"error"
|
|
26
|
+
], r = {}, i = null;
|
|
27
|
+
function c(l, m) {
|
|
28
|
+
var u = l[m];
|
|
29
|
+
if (typeof u.bind == "function")
|
|
30
|
+
return u.bind(l);
|
|
31
|
+
try {
|
|
32
|
+
return Function.prototype.bind.call(u, l);
|
|
33
|
+
} catch {
|
|
34
|
+
return function() {
|
|
35
|
+
return Function.prototype.apply.apply(u, [l, arguments]);
|
|
36
|
+
};
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
function h() {
|
|
40
|
+
console.log && (console.log.apply ? console.log.apply(console, arguments) : Function.prototype.apply.apply(console.log, [console, arguments])), console.trace && console.trace();
|
|
41
|
+
}
|
|
42
|
+
function _(l) {
|
|
43
|
+
return l === "debug" && (l = "log"), typeof console === n ? !1 : l === "trace" && o ? h : console[l] !== void 0 ? c(console, l) : console.log !== void 0 ? c(console, "log") : e;
|
|
44
|
+
}
|
|
45
|
+
function p() {
|
|
46
|
+
for (var l = this.getLevel(), m = 0; m < a.length; m++) {
|
|
47
|
+
var u = a[m];
|
|
48
|
+
this[u] = m < l ? e : this.methodFactory(u, l, this.name);
|
|
49
|
+
}
|
|
50
|
+
if (this.log = this.debug, typeof console === n && l < this.levels.SILENT)
|
|
51
|
+
return "No console available for logging";
|
|
52
|
+
}
|
|
53
|
+
function y(l) {
|
|
34
54
|
return function() {
|
|
35
|
-
|
|
55
|
+
typeof console !== n && (p.call(this), this[l].apply(this, arguments));
|
|
36
56
|
};
|
|
37
57
|
}
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
console.log && (console.log.apply ? console.log.apply(console, arguments) : Function.prototype.apply.apply(console.log, [console, arguments])), console.trace && console.trace();
|
|
41
|
-
}
|
|
42
|
-
function b(l) {
|
|
43
|
-
return l === "debug" && (l = "log"), typeof console === r ? !1 : l === "trace" && o ? p : console[l] !== void 0 ? c(console, l) : console.log !== void 0 ? c(console, "log") : e;
|
|
44
|
-
}
|
|
45
|
-
function f() {
|
|
46
|
-
for (var l = this.getLevel(), g = 0; g < s.length; g++) {
|
|
47
|
-
var u = s[g];
|
|
48
|
-
this[u] = g < l ? e : this.methodFactory(u, l, this.name);
|
|
58
|
+
function T(l, m, u) {
|
|
59
|
+
return _(l) || y.apply(this, arguments);
|
|
49
60
|
}
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
var m = (s[d] || "silent").toUpperCase();
|
|
66
|
-
if (!(typeof window === r || !S)) {
|
|
67
|
-
try {
|
|
68
|
-
window.localStorage[S] = m;
|
|
69
|
-
return;
|
|
70
|
-
} catch {
|
|
71
|
-
}
|
|
72
|
-
try {
|
|
73
|
-
window.document.cookie = encodeURIComponent(S) + "=" + m + ";";
|
|
74
|
-
} catch {
|
|
61
|
+
function f(l, m) {
|
|
62
|
+
var u = this, O, M, R, v = "loglevel";
|
|
63
|
+
typeof l == "string" ? v += ":" + l : typeof l == "symbol" && (v = void 0);
|
|
64
|
+
function Le(d) {
|
|
65
|
+
var g = (a[d] || "silent").toUpperCase();
|
|
66
|
+
if (!(typeof window === n || !v)) {
|
|
67
|
+
try {
|
|
68
|
+
window.localStorage[v] = g;
|
|
69
|
+
return;
|
|
70
|
+
} catch {
|
|
71
|
+
}
|
|
72
|
+
try {
|
|
73
|
+
window.document.cookie = encodeURIComponent(v) + "=" + g + ";";
|
|
74
|
+
} catch {
|
|
75
|
+
}
|
|
75
76
|
}
|
|
76
77
|
}
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
if (!(typeof window === r || !S)) {
|
|
81
|
-
try {
|
|
82
|
-
d = window.localStorage[S];
|
|
83
|
-
} catch {
|
|
84
|
-
}
|
|
85
|
-
if (typeof d === r)
|
|
78
|
+
function re() {
|
|
79
|
+
var d;
|
|
80
|
+
if (!(typeof window === n || !v)) {
|
|
86
81
|
try {
|
|
87
|
-
|
|
88
|
-
ie !== -1 && (d = /^([^;]+)/.exec(
|
|
89
|
-
m.slice(ie + z.length + 1)
|
|
90
|
-
)[1]);
|
|
82
|
+
d = window.localStorage[v];
|
|
91
83
|
} catch {
|
|
92
84
|
}
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
85
|
+
if (typeof d === n)
|
|
86
|
+
try {
|
|
87
|
+
var g = window.document.cookie, z = encodeURIComponent(v), ie = g.indexOf(z + "=");
|
|
88
|
+
ie !== -1 && (d = /^([^;]+)/.exec(
|
|
89
|
+
g.slice(ie + z.length + 1)
|
|
90
|
+
)[1]);
|
|
91
|
+
} catch {
|
|
92
|
+
}
|
|
93
|
+
return u.levels[d] === void 0 && (d = void 0), d;
|
|
101
94
|
}
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
95
|
+
}
|
|
96
|
+
function je() {
|
|
97
|
+
if (!(typeof window === n || !v)) {
|
|
98
|
+
try {
|
|
99
|
+
window.localStorage.removeItem(v);
|
|
100
|
+
} catch {
|
|
101
|
+
}
|
|
102
|
+
try {
|
|
103
|
+
window.document.cookie = encodeURIComponent(v) + "=; expires=Thu, 01 Jan 1970 00:00:00 UTC";
|
|
104
|
+
} catch {
|
|
105
|
+
}
|
|
105
106
|
}
|
|
106
107
|
}
|
|
108
|
+
function U(d) {
|
|
109
|
+
var g = d;
|
|
110
|
+
if (typeof g == "string" && u.levels[g.toUpperCase()] !== void 0 && (g = u.levels[g.toUpperCase()]), typeof g == "number" && g >= 0 && g <= u.levels.SILENT)
|
|
111
|
+
return g;
|
|
112
|
+
throw new TypeError("log.setLevel() called with invalid level: " + d);
|
|
113
|
+
}
|
|
114
|
+
u.name = l, u.levels = {
|
|
115
|
+
TRACE: 0,
|
|
116
|
+
DEBUG: 1,
|
|
117
|
+
INFO: 2,
|
|
118
|
+
WARN: 3,
|
|
119
|
+
ERROR: 4,
|
|
120
|
+
SILENT: 5
|
|
121
|
+
}, u.methodFactory = m || T, u.getLevel = function() {
|
|
122
|
+
return R ?? M ?? O;
|
|
123
|
+
}, u.setLevel = function(d, g) {
|
|
124
|
+
return R = U(d), g !== !1 && Le(R), p.call(u);
|
|
125
|
+
}, u.setDefaultLevel = function(d) {
|
|
126
|
+
M = U(d), re() || u.setLevel(d, !1);
|
|
127
|
+
}, u.resetLevel = function() {
|
|
128
|
+
R = null, je(), p.call(u);
|
|
129
|
+
}, u.enableAll = function(d) {
|
|
130
|
+
u.setLevel(u.levels.TRACE, d);
|
|
131
|
+
}, u.disableAll = function(d) {
|
|
132
|
+
u.setLevel(u.levels.SILENT, d);
|
|
133
|
+
}, u.rebuild = function() {
|
|
134
|
+
if (i !== u && (O = U(i.getLevel())), p.call(u), i === u)
|
|
135
|
+
for (var d in r)
|
|
136
|
+
r[d].rebuild();
|
|
137
|
+
}, O = U(
|
|
138
|
+
i ? i.getLevel() : "WARN"
|
|
139
|
+
);
|
|
140
|
+
var oe = re();
|
|
141
|
+
oe != null && (R = U(oe)), p.call(u);
|
|
107
142
|
}
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
}, u.disableAll = function(d) {
|
|
132
|
-
u.setLevel(u.levels.SILENT, d);
|
|
133
|
-
}, u.rebuild = function() {
|
|
134
|
-
if (i !== u && (O = x(i.getLevel())), f.call(u), i === u)
|
|
135
|
-
for (var d in n)
|
|
136
|
-
n[d].rebuild();
|
|
137
|
-
}, O = x(
|
|
138
|
-
i ? i.getLevel() : "WARN"
|
|
139
|
-
);
|
|
140
|
-
var oe = ne();
|
|
141
|
-
oe != null && (P = x(oe)), f.call(u);
|
|
142
|
-
}
|
|
143
|
-
i = new h(), i.getLogger = function(g) {
|
|
144
|
-
if (typeof g != "symbol" && typeof g != "string" || g === "")
|
|
145
|
-
throw new TypeError("You must supply a name when creating a logger.");
|
|
146
|
-
var u = n[g];
|
|
147
|
-
return u || (u = n[g] = new h(
|
|
148
|
-
g,
|
|
149
|
-
i.methodFactory
|
|
150
|
-
)), u;
|
|
151
|
-
};
|
|
152
|
-
var J = typeof window !== r ? window.log : void 0;
|
|
153
|
-
return i.noConflict = function() {
|
|
154
|
-
return typeof window !== r && window.log === i && (window.log = J), i;
|
|
155
|
-
}, i.getLoggers = function() {
|
|
156
|
-
return n;
|
|
157
|
-
}, i.default = i, i;
|
|
158
|
-
});
|
|
159
|
-
})(pe);
|
|
160
|
-
var Be = pe.exports;
|
|
161
|
-
const K = /* @__PURE__ */ Oe(Be);
|
|
162
|
-
let Y;
|
|
163
|
-
var D, fe;
|
|
164
|
-
(typeof navigator > "u" || !((fe = (D = navigator.userAgent) == null ? void 0 : D.startsWith) != null && fe.call(D, "Mozilla/5.0 "))) && (Y = "oauth4webapi/v2.17.0");
|
|
143
|
+
i = new f(), i.getLogger = function(m) {
|
|
144
|
+
if (typeof m != "symbol" && typeof m != "string" || m === "")
|
|
145
|
+
throw new TypeError("You must supply a name when creating a logger.");
|
|
146
|
+
var u = r[m];
|
|
147
|
+
return u || (u = r[m] = new f(
|
|
148
|
+
m,
|
|
149
|
+
i.methodFactory
|
|
150
|
+
)), u;
|
|
151
|
+
};
|
|
152
|
+
var J = typeof window !== n ? window.log : void 0;
|
|
153
|
+
return i.noConflict = function() {
|
|
154
|
+
return typeof window !== n && window.log === i && (window.log = J), i;
|
|
155
|
+
}, i.getLoggers = function() {
|
|
156
|
+
return r;
|
|
157
|
+
}, i.default = i, i;
|
|
158
|
+
});
|
|
159
|
+
}(N)), N.exports;
|
|
160
|
+
}
|
|
161
|
+
var Me = Fe();
|
|
162
|
+
const ce = /* @__PURE__ */ ze(Me);
|
|
163
|
+
let Z;
|
|
164
|
+
var D, me;
|
|
165
|
+
(typeof navigator > "u" || !((me = (D = navigator.userAgent) == null ? void 0 : D.startsWith) != null && me.call(D, "Mozilla/5.0 "))) && (Z = "oauth4webapi/v2.17.0");
|
|
165
166
|
function Q(t, e) {
|
|
166
167
|
if (t == null)
|
|
167
168
|
return !1;
|
|
@@ -171,92 +172,92 @@ function Q(t, e) {
|
|
|
171
172
|
return !1;
|
|
172
173
|
}
|
|
173
174
|
}
|
|
174
|
-
const
|
|
175
|
-
function
|
|
176
|
-
return typeof t == "string" ?
|
|
175
|
+
const W = Symbol(), qe = Symbol(), X = Symbol(), ge = Symbol(), Be = Symbol(), Ve = Symbol(), Ge = new TextEncoder(), Ze = new TextDecoder();
|
|
176
|
+
function E(t) {
|
|
177
|
+
return typeof t == "string" ? Ge.encode(t) : Ze.decode(t);
|
|
177
178
|
}
|
|
178
|
-
const
|
|
179
|
-
function
|
|
179
|
+
const ue = 32768;
|
|
180
|
+
function Ye(t) {
|
|
180
181
|
t instanceof ArrayBuffer && (t = new Uint8Array(t));
|
|
181
182
|
const e = [];
|
|
182
|
-
for (let
|
|
183
|
-
e.push(String.fromCharCode.apply(null, t.subarray(
|
|
183
|
+
for (let n = 0; n < t.byteLength; n += ue)
|
|
184
|
+
e.push(String.fromCharCode.apply(null, t.subarray(n, n + ue)));
|
|
184
185
|
return btoa(e.join("")).replace(/=/g, "").replace(/\+/g, "-").replace(/\//g, "_");
|
|
185
186
|
}
|
|
186
|
-
function
|
|
187
|
+
function Qe(t) {
|
|
187
188
|
try {
|
|
188
|
-
const e = atob(t.replace(/-/g, "+").replace(/_/g, "/").replace(/\s/g, "")),
|
|
189
|
+
const e = atob(t.replace(/-/g, "+").replace(/_/g, "/").replace(/\s/g, "")), n = new Uint8Array(e.length);
|
|
189
190
|
for (let o = 0; o < e.length; o++)
|
|
190
|
-
|
|
191
|
-
return
|
|
191
|
+
n[o] = e.charCodeAt(o);
|
|
192
|
+
return n;
|
|
192
193
|
} catch (e) {
|
|
193
|
-
throw new
|
|
194
|
+
throw new s("The input to be decoded is not correctly encoded.", { cause: e });
|
|
194
195
|
}
|
|
195
196
|
}
|
|
196
|
-
function
|
|
197
|
-
return typeof t == "string" ?
|
|
197
|
+
function A(t) {
|
|
198
|
+
return typeof t == "string" ? Qe(t) : Ye(t);
|
|
198
199
|
}
|
|
199
|
-
class
|
|
200
|
+
class Xe {
|
|
200
201
|
constructor(e) {
|
|
201
202
|
this.cache = /* @__PURE__ */ new Map(), this._cache = /* @__PURE__ */ new Map(), this.maxSize = e;
|
|
202
203
|
}
|
|
203
204
|
get(e) {
|
|
204
|
-
let
|
|
205
|
-
if (
|
|
206
|
-
return
|
|
207
|
-
if (
|
|
208
|
-
return this.update(e,
|
|
205
|
+
let n = this.cache.get(e);
|
|
206
|
+
if (n)
|
|
207
|
+
return n;
|
|
208
|
+
if (n = this._cache.get(e))
|
|
209
|
+
return this.update(e, n), n;
|
|
209
210
|
}
|
|
210
211
|
has(e) {
|
|
211
212
|
return this.cache.has(e) || this._cache.has(e);
|
|
212
213
|
}
|
|
213
|
-
set(e,
|
|
214
|
-
return this.cache.has(e) ? this.cache.set(e,
|
|
214
|
+
set(e, n) {
|
|
215
|
+
return this.cache.has(e) ? this.cache.set(e, n) : this.update(e, n), this;
|
|
215
216
|
}
|
|
216
217
|
delete(e) {
|
|
217
218
|
return this.cache.has(e) ? this.cache.delete(e) : this._cache.has(e) ? this._cache.delete(e) : !1;
|
|
218
219
|
}
|
|
219
|
-
update(e,
|
|
220
|
-
this.cache.set(e,
|
|
220
|
+
update(e, n) {
|
|
221
|
+
this.cache.set(e, n), this.cache.size >= this.maxSize && (this._cache = this.cache, this.cache = /* @__PURE__ */ new Map());
|
|
221
222
|
}
|
|
222
223
|
}
|
|
223
|
-
class
|
|
224
|
+
class S extends Error {
|
|
224
225
|
constructor(e) {
|
|
225
|
-
var
|
|
226
|
-
super(e ?? "operation not supported"), this.name = this.constructor.name, (
|
|
226
|
+
var n;
|
|
227
|
+
super(e ?? "operation not supported"), this.name = this.constructor.name, (n = Error.captureStackTrace) == null || n.call(Error, this, this.constructor);
|
|
227
228
|
}
|
|
228
229
|
}
|
|
229
|
-
class
|
|
230
|
-
constructor(e,
|
|
230
|
+
class et extends Error {
|
|
231
|
+
constructor(e, n) {
|
|
231
232
|
var o;
|
|
232
|
-
super(e,
|
|
233
|
+
super(e, n), this.name = this.constructor.name, (o = Error.captureStackTrace) == null || o.call(Error, this, this.constructor);
|
|
233
234
|
}
|
|
234
235
|
}
|
|
235
|
-
const
|
|
236
|
-
function
|
|
236
|
+
const s = et, ye = new Xe(100);
|
|
237
|
+
function be(t) {
|
|
237
238
|
return t instanceof CryptoKey;
|
|
238
239
|
}
|
|
239
|
-
function
|
|
240
|
-
return
|
|
240
|
+
function _e(t) {
|
|
241
|
+
return be(t) && t.type === "private";
|
|
241
242
|
}
|
|
242
|
-
function
|
|
243
|
-
return
|
|
243
|
+
function tt(t) {
|
|
244
|
+
return be(t) && t.type === "public";
|
|
244
245
|
}
|
|
245
246
|
function ee(t) {
|
|
246
247
|
try {
|
|
247
248
|
const e = t.headers.get("dpop-nonce");
|
|
248
|
-
e &&
|
|
249
|
+
e && ye.set(new URL(t.url).origin, e);
|
|
249
250
|
} catch {
|
|
250
251
|
}
|
|
251
252
|
return t;
|
|
252
253
|
}
|
|
253
|
-
function
|
|
254
|
+
function C(t) {
|
|
254
255
|
return !(t === null || typeof t != "object" || Array.isArray(t));
|
|
255
256
|
}
|
|
256
|
-
function
|
|
257
|
+
function H(t) {
|
|
257
258
|
Q(t, Headers) && (t = Object.fromEntries(t.entries()));
|
|
258
259
|
const e = new Headers(t);
|
|
259
|
-
if (
|
|
260
|
+
if (Z && !e.has("user-agent") && e.set("user-agent", Z), e.has("authorization"))
|
|
260
261
|
throw new TypeError('"options.headers" must not include the "authorization" header name');
|
|
261
262
|
if (e.has("dpop"))
|
|
262
263
|
throw new TypeError('"options.headers" must not include the "dpop" header name');
|
|
@@ -272,20 +273,20 @@ async function nt(t, e) {
|
|
|
272
273
|
throw new TypeError('"issuerIdentifier" must be an instance of URL');
|
|
273
274
|
if (t.protocol !== "https:" && t.protocol !== "http:")
|
|
274
275
|
throw new TypeError('"issuer.protocol" must be "https:" or "http:"');
|
|
275
|
-
const
|
|
276
|
+
const n = new URL(t.href);
|
|
276
277
|
switch (e == null ? void 0 : e.algorithm) {
|
|
277
278
|
case void 0:
|
|
278
279
|
case "oidc":
|
|
279
|
-
|
|
280
|
+
n.pathname = `${n.pathname}/.well-known/openid-configuration`.replace("//", "/");
|
|
280
281
|
break;
|
|
281
282
|
case "oauth2":
|
|
282
|
-
|
|
283
|
+
n.pathname === "/" ? n.pathname = ".well-known/oauth-authorization-server" : n.pathname = `.well-known/oauth-authorization-server/${n.pathname}`.replace("//", "/");
|
|
283
284
|
break;
|
|
284
285
|
default:
|
|
285
286
|
throw new TypeError('"options.algorithm" must be "oidc" (default), or "oauth2"');
|
|
286
287
|
}
|
|
287
|
-
const o =
|
|
288
|
-
return o.set("accept", "application/json"), ((e == null ? void 0 : e[X]) || fetch)(
|
|
288
|
+
const o = H(e == null ? void 0 : e.headers);
|
|
289
|
+
return o.set("accept", "application/json"), ((e == null ? void 0 : e[X]) || fetch)(n.href, {
|
|
289
290
|
headers: Object.fromEntries(o.entries()),
|
|
290
291
|
method: "GET",
|
|
291
292
|
redirect: "manual",
|
|
@@ -295,43 +296,43 @@ async function nt(t, e) {
|
|
|
295
296
|
function w(t) {
|
|
296
297
|
return typeof t == "string" && t.length !== 0;
|
|
297
298
|
}
|
|
298
|
-
async function
|
|
299
|
+
async function rt(t, e) {
|
|
299
300
|
if (!(t instanceof URL))
|
|
300
301
|
throw new TypeError('"expectedIssuer" must be an instance of URL');
|
|
301
302
|
if (!Q(e, Response))
|
|
302
303
|
throw new TypeError('"response" must be an instance of Response');
|
|
303
304
|
if (e.status !== 200)
|
|
304
|
-
throw new
|
|
305
|
-
|
|
306
|
-
let
|
|
305
|
+
throw new s('"response" is not a conform Authorization Server Metadata response');
|
|
306
|
+
ne(e);
|
|
307
|
+
let n;
|
|
307
308
|
try {
|
|
308
|
-
|
|
309
|
+
n = await e.json();
|
|
309
310
|
} catch (o) {
|
|
310
|
-
throw new
|
|
311
|
+
throw new s('failed to parse "response" body as JSON', { cause: o });
|
|
311
312
|
}
|
|
312
|
-
if (!
|
|
313
|
-
throw new
|
|
314
|
-
if (!w(
|
|
315
|
-
throw new
|
|
316
|
-
if (new URL(
|
|
317
|
-
throw new
|
|
318
|
-
return
|
|
313
|
+
if (!C(n))
|
|
314
|
+
throw new s('"response" body must be a top level object');
|
|
315
|
+
if (!w(n.issuer))
|
|
316
|
+
throw new s('"response" body "issuer" property must be a non-empty string');
|
|
317
|
+
if (new URL(n.issuer).href !== t.href)
|
|
318
|
+
throw new s('"response" body "issuer" does not match "expectedIssuer"');
|
|
319
|
+
return n;
|
|
319
320
|
}
|
|
320
|
-
function
|
|
321
|
-
return
|
|
321
|
+
function $() {
|
|
322
|
+
return A(crypto.getRandomValues(new Uint8Array(32)));
|
|
322
323
|
}
|
|
323
|
-
function
|
|
324
|
-
return
|
|
324
|
+
function ot() {
|
|
325
|
+
return $();
|
|
325
326
|
}
|
|
326
|
-
function
|
|
327
|
-
return
|
|
327
|
+
function it() {
|
|
328
|
+
return $();
|
|
328
329
|
}
|
|
329
330
|
async function at(t) {
|
|
330
331
|
if (!w(t))
|
|
331
332
|
throw new TypeError('"codeVerifier" must be a non-empty string');
|
|
332
|
-
return
|
|
333
|
+
return A(await crypto.subtle.digest("SHA-256", E(t)));
|
|
333
334
|
}
|
|
334
|
-
function
|
|
335
|
+
function st(t) {
|
|
335
336
|
if (t instanceof CryptoKey)
|
|
336
337
|
return { key: t };
|
|
337
338
|
if (!((t == null ? void 0 : t.key) instanceof CryptoKey))
|
|
@@ -341,17 +342,17 @@ function ct(t) {
|
|
|
341
342
|
return {
|
|
342
343
|
key: t.key,
|
|
343
344
|
kid: t.kid,
|
|
344
|
-
modifyAssertion: t[
|
|
345
|
+
modifyAssertion: t[ge]
|
|
345
346
|
};
|
|
346
347
|
}
|
|
347
|
-
function
|
|
348
|
+
function le(t) {
|
|
348
349
|
return encodeURIComponent(t).replace(/%20/g, "+");
|
|
349
350
|
}
|
|
350
|
-
function
|
|
351
|
-
const
|
|
352
|
-
return `Basic ${btoa(`${
|
|
351
|
+
function ct(t, e) {
|
|
352
|
+
const n = le(t), o = le(e);
|
|
353
|
+
return `Basic ${btoa(`${n}:${o}`)}`;
|
|
353
354
|
}
|
|
354
|
-
function
|
|
355
|
+
function ut(t) {
|
|
355
356
|
switch (t.algorithm.hash.name) {
|
|
356
357
|
case "SHA-256":
|
|
357
358
|
return "PS256";
|
|
@@ -360,10 +361,10 @@ function lt(t) {
|
|
|
360
361
|
case "SHA-512":
|
|
361
362
|
return "PS512";
|
|
362
363
|
default:
|
|
363
|
-
throw new
|
|
364
|
+
throw new S("unsupported RsaHashedKeyAlgorithm hash name");
|
|
364
365
|
}
|
|
365
366
|
}
|
|
366
|
-
function
|
|
367
|
+
function lt(t) {
|
|
367
368
|
switch (t.algorithm.hash.name) {
|
|
368
369
|
case "SHA-256":
|
|
369
370
|
return "RS256";
|
|
@@ -372,10 +373,10 @@ function dt(t) {
|
|
|
372
373
|
case "SHA-512":
|
|
373
374
|
return "RS512";
|
|
374
375
|
default:
|
|
375
|
-
throw new
|
|
376
|
+
throw new S("unsupported RsaHashedKeyAlgorithm hash name");
|
|
376
377
|
}
|
|
377
378
|
}
|
|
378
|
-
function
|
|
379
|
+
function dt(t) {
|
|
379
380
|
switch (t.algorithm.namedCurve) {
|
|
380
381
|
case "P-256":
|
|
381
382
|
return "ES256";
|
|
@@ -384,66 +385,66 @@ function ht(t) {
|
|
|
384
385
|
case "P-521":
|
|
385
386
|
return "ES512";
|
|
386
387
|
default:
|
|
387
|
-
throw new
|
|
388
|
+
throw new S("unsupported EcKeyAlgorithm namedCurve");
|
|
388
389
|
}
|
|
389
390
|
}
|
|
390
|
-
function
|
|
391
|
+
function ve(t) {
|
|
391
392
|
switch (t.algorithm.name) {
|
|
392
393
|
case "RSA-PSS":
|
|
393
|
-
return
|
|
394
|
+
return ut(t);
|
|
394
395
|
case "RSASSA-PKCS1-v1_5":
|
|
395
|
-
return
|
|
396
|
+
return lt(t);
|
|
396
397
|
case "ECDSA":
|
|
397
|
-
return
|
|
398
|
+
return dt(t);
|
|
398
399
|
case "Ed25519":
|
|
399
400
|
case "Ed448":
|
|
400
401
|
return "EdDSA";
|
|
401
402
|
default:
|
|
402
|
-
throw new
|
|
403
|
+
throw new S("unsupported CryptoKey algorithm name");
|
|
403
404
|
}
|
|
404
405
|
}
|
|
405
|
-
function
|
|
406
|
-
const e = t == null ? void 0 : t[
|
|
406
|
+
function L(t) {
|
|
407
|
+
const e = t == null ? void 0 : t[W];
|
|
407
408
|
return typeof e == "number" && Number.isFinite(e) ? e : 0;
|
|
408
409
|
}
|
|
409
|
-
function
|
|
410
|
+
function Se(t) {
|
|
410
411
|
const e = t == null ? void 0 : t[qe];
|
|
411
412
|
return typeof e == "number" && Number.isFinite(e) && Math.sign(e) !== -1 ? e : 30;
|
|
412
413
|
}
|
|
413
|
-
function
|
|
414
|
+
function F() {
|
|
414
415
|
return Math.floor(Date.now() / 1e3);
|
|
415
416
|
}
|
|
416
|
-
function
|
|
417
|
-
const
|
|
417
|
+
function ht(t, e) {
|
|
418
|
+
const n = F() + L(e);
|
|
418
419
|
return {
|
|
419
|
-
jti:
|
|
420
|
+
jti: $(),
|
|
420
421
|
aud: [t.issuer, t.token_endpoint],
|
|
421
|
-
exp:
|
|
422
|
-
iat:
|
|
423
|
-
nbf:
|
|
422
|
+
exp: n + 60,
|
|
423
|
+
iat: n,
|
|
424
|
+
nbf: n,
|
|
424
425
|
iss: e.client_id,
|
|
425
426
|
sub: e.client_id
|
|
426
427
|
};
|
|
427
428
|
}
|
|
428
|
-
async function
|
|
429
|
-
const
|
|
430
|
-
return
|
|
429
|
+
async function ft(t, e, n, o, a) {
|
|
430
|
+
const r = { alg: ve(n), kid: o }, i = ht(t, e);
|
|
431
|
+
return a == null || a(r, i), Te(r, i, n);
|
|
431
432
|
}
|
|
432
|
-
function
|
|
433
|
+
function j(t) {
|
|
433
434
|
if (typeof t != "object" || t === null)
|
|
434
435
|
throw new TypeError('"as" must be an object');
|
|
435
436
|
if (!w(t.issuer))
|
|
436
437
|
throw new TypeError('"as.issuer" property must be a non-empty string');
|
|
437
438
|
return !0;
|
|
438
439
|
}
|
|
439
|
-
function
|
|
440
|
+
function I(t) {
|
|
440
441
|
if (typeof t != "object" || t === null)
|
|
441
442
|
throw new TypeError('"client" must be an object');
|
|
442
443
|
if (!w(t.client_id))
|
|
443
444
|
throw new TypeError('"client.client_id" property must be a non-empty string');
|
|
444
445
|
return !0;
|
|
445
446
|
}
|
|
446
|
-
function
|
|
447
|
+
function de(t) {
|
|
447
448
|
if (!w(t))
|
|
448
449
|
throw new TypeError('"client.client_secret" property must be a non-empty string');
|
|
449
450
|
return t;
|
|
@@ -452,227 +453,227 @@ function q(t, e) {
|
|
|
452
453
|
if (e !== void 0)
|
|
453
454
|
throw new TypeError(`"options.clientPrivateKey" property must not be provided when ${t} client authentication method is used.`);
|
|
454
455
|
}
|
|
455
|
-
function
|
|
456
|
+
function he(t, e) {
|
|
456
457
|
if (e !== void 0)
|
|
457
458
|
throw new TypeError(`"client.client_secret" property must not be provided when ${t} client authentication method is used.`);
|
|
458
459
|
}
|
|
459
|
-
async function
|
|
460
|
-
switch (
|
|
460
|
+
async function pt(t, e, n, o, a) {
|
|
461
|
+
switch (n.delete("client_secret"), n.delete("client_assertion_type"), n.delete("client_assertion"), e.token_endpoint_auth_method) {
|
|
461
462
|
case void 0:
|
|
462
463
|
case "client_secret_basic": {
|
|
463
|
-
q("client_secret_basic",
|
|
464
|
+
q("client_secret_basic", a), o.set("authorization", ct(e.client_id, de(e.client_secret)));
|
|
464
465
|
break;
|
|
465
466
|
}
|
|
466
467
|
case "client_secret_post": {
|
|
467
|
-
q("client_secret_post",
|
|
468
|
+
q("client_secret_post", a), n.set("client_id", e.client_id), n.set("client_secret", de(e.client_secret));
|
|
468
469
|
break;
|
|
469
470
|
}
|
|
470
471
|
case "private_key_jwt": {
|
|
471
|
-
if (
|
|
472
|
+
if (he("private_key_jwt", e.client_secret), a === void 0)
|
|
472
473
|
throw new TypeError('"options.clientPrivateKey" must be provided when "client.token_endpoint_auth_method" is "private_key_jwt"');
|
|
473
|
-
const { key:
|
|
474
|
-
if (!
|
|
474
|
+
const { key: r, kid: i, modifyAssertion: c } = st(a);
|
|
475
|
+
if (!_e(r))
|
|
475
476
|
throw new TypeError('"options.clientPrivateKey.key" must be a private CryptoKey');
|
|
476
|
-
|
|
477
|
+
n.set("client_id", e.client_id), n.set("client_assertion_type", "urn:ietf:params:oauth:client-assertion-type:jwt-bearer"), n.set("client_assertion", await ft(t, e, r, i, c));
|
|
477
478
|
break;
|
|
478
479
|
}
|
|
479
480
|
case "tls_client_auth":
|
|
480
481
|
case "self_signed_tls_client_auth":
|
|
481
482
|
case "none": {
|
|
482
|
-
|
|
483
|
+
he(e.token_endpoint_auth_method, e.client_secret), q(e.token_endpoint_auth_method, a), n.set("client_id", e.client_id);
|
|
483
484
|
break;
|
|
484
485
|
}
|
|
485
486
|
default:
|
|
486
|
-
throw new
|
|
487
|
+
throw new S("unsupported client token_endpoint_auth_method");
|
|
487
488
|
}
|
|
488
489
|
}
|
|
489
|
-
async function
|
|
490
|
-
if (!
|
|
490
|
+
async function Te(t, e, n) {
|
|
491
|
+
if (!n.usages.includes("sign"))
|
|
491
492
|
throw new TypeError('CryptoKey instances used for signing assertions must include "sign" in their "usages"');
|
|
492
|
-
const o = `${E(
|
|
493
|
-
return `${o}.${
|
|
493
|
+
const o = `${A(E(JSON.stringify(t)))}.${A(E(JSON.stringify(e)))}`, a = A(await crypto.subtle.sign(xe(n), n, E(o)));
|
|
494
|
+
return `${o}.${a}`;
|
|
494
495
|
}
|
|
495
|
-
async function
|
|
496
|
+
async function wt(t, e, n, o, a, r) {
|
|
496
497
|
var T;
|
|
497
|
-
const { privateKey: i, publicKey: c, nonce:
|
|
498
|
-
if (!
|
|
498
|
+
const { privateKey: i, publicKey: c, nonce: h = ye.get(n.origin) } = e;
|
|
499
|
+
if (!_e(i))
|
|
499
500
|
throw new TypeError('"DPoP.privateKey" must be a private CryptoKey');
|
|
500
|
-
if (!
|
|
501
|
+
if (!tt(c))
|
|
501
502
|
throw new TypeError('"DPoP.publicKey" must be a public CryptoKey');
|
|
502
|
-
if (
|
|
503
|
+
if (h !== void 0 && !w(h))
|
|
503
504
|
throw new TypeError('"DPoP.nonce" must be a non-empty string or undefined');
|
|
504
505
|
if (!c.extractable)
|
|
505
506
|
throw new TypeError('"DPoP.publicKey.extractable" must be true');
|
|
506
|
-
const
|
|
507
|
-
alg:
|
|
507
|
+
const _ = F() + a, p = {
|
|
508
|
+
alg: ve(i),
|
|
508
509
|
typ: "dpop+jwt",
|
|
509
|
-
jwk: await
|
|
510
|
+
jwk: await gt(c)
|
|
510
511
|
}, y = {
|
|
511
|
-
iat:
|
|
512
|
-
jti:
|
|
512
|
+
iat: _,
|
|
513
|
+
jti: $(),
|
|
513
514
|
htm: o,
|
|
514
|
-
nonce:
|
|
515
|
-
htu: `${
|
|
516
|
-
ath:
|
|
515
|
+
nonce: h,
|
|
516
|
+
htu: `${n.origin}${n.pathname}`,
|
|
517
|
+
ath: r ? A(await crypto.subtle.digest("SHA-256", E(r))) : void 0
|
|
517
518
|
};
|
|
518
|
-
(T = e[
|
|
519
|
+
(T = e[ge]) == null || T.call(e, p, y), t.set("dpop", await Te(p, y, i));
|
|
519
520
|
}
|
|
520
|
-
let
|
|
521
|
+
let K;
|
|
521
522
|
async function mt(t) {
|
|
522
|
-
const { kty: e, e:
|
|
523
|
-
return
|
|
523
|
+
const { kty: e, e: n, n: o, x: a, y: r, crv: i } = await crypto.subtle.exportKey("jwk", t), c = { kty: e, e: n, n: o, x: a, y: r, crv: i };
|
|
524
|
+
return K.set(t, c), c;
|
|
524
525
|
}
|
|
525
|
-
async function
|
|
526
|
-
return
|
|
526
|
+
async function gt(t) {
|
|
527
|
+
return K || (K = /* @__PURE__ */ new WeakMap()), K.get(t) || mt(t);
|
|
527
528
|
}
|
|
528
|
-
function
|
|
529
|
+
function fe(t, e, n) {
|
|
529
530
|
if (typeof t != "string")
|
|
530
|
-
throw
|
|
531
|
+
throw n ? new TypeError(`"as.mtls_endpoint_aliases.${e}" must be a string`) : new TypeError(`"as.${e}" must be a string`);
|
|
531
532
|
return new URL(t);
|
|
532
533
|
}
|
|
533
|
-
function
|
|
534
|
-
return
|
|
534
|
+
function ke(t, e, n = !1) {
|
|
535
|
+
return n && t.mtls_endpoint_aliases && e in t.mtls_endpoint_aliases ? fe(t.mtls_endpoint_aliases[e], e, n) : fe(t[e], e, n);
|
|
535
536
|
}
|
|
536
|
-
function
|
|
537
|
-
return !!(t.use_mtls_endpoint_aliases || e != null && e[
|
|
537
|
+
function Ae(t, e) {
|
|
538
|
+
return !!(t.use_mtls_endpoint_aliases || e != null && e[Ve]);
|
|
538
539
|
}
|
|
539
|
-
function
|
|
540
|
+
function Y(t) {
|
|
540
541
|
const e = t;
|
|
541
542
|
return typeof e != "object" || Array.isArray(e) || e === null ? !1 : e.error !== void 0;
|
|
542
543
|
}
|
|
543
|
-
async function
|
|
544
|
+
async function yt(t, e, n, o, a, r) {
|
|
544
545
|
if (!w(t))
|
|
545
546
|
throw new TypeError('"accessToken" must be a non-empty string');
|
|
546
|
-
if (!(
|
|
547
|
+
if (!(n instanceof URL))
|
|
547
548
|
throw new TypeError('"url" must be an instance of URL');
|
|
548
|
-
return o =
|
|
549
|
-
body:
|
|
549
|
+
return o = H(o), (r == null ? void 0 : r.DPoP) === void 0 ? o.set("authorization", `Bearer ${t}`) : (await wt(o, r.DPoP, n, e.toUpperCase(), L({ [W]: r == null ? void 0 : r[W] }), t), o.set("authorization", `DPoP ${t}`)), ((r == null ? void 0 : r[X]) || fetch)(n.href, {
|
|
550
|
+
body: a,
|
|
550
551
|
headers: Object.fromEntries(o.entries()),
|
|
551
552
|
method: e,
|
|
552
553
|
redirect: "manual",
|
|
553
|
-
signal:
|
|
554
|
+
signal: r != null && r.signal ? te(r.signal) : null
|
|
554
555
|
}).then(ee);
|
|
555
556
|
}
|
|
556
|
-
async function bt(t, e,
|
|
557
|
-
|
|
558
|
-
const
|
|
559
|
-
return e.userinfo_signed_response_alg ?
|
|
557
|
+
async function bt(t, e, n, o) {
|
|
558
|
+
j(t), I(e);
|
|
559
|
+
const a = ke(t, "userinfo_endpoint", Ae(e, o)), r = H(o == null ? void 0 : o.headers);
|
|
560
|
+
return e.userinfo_signed_response_alg ? r.set("accept", "application/jwt") : (r.set("accept", "application/json"), r.append("accept", "application/jwt")), yt(n, "GET", a, r, null, {
|
|
560
561
|
...o,
|
|
561
|
-
[
|
|
562
|
+
[W]: L(e)
|
|
562
563
|
});
|
|
563
564
|
}
|
|
564
|
-
async function
|
|
565
|
-
return await
|
|
566
|
-
body:
|
|
567
|
-
headers: Object.fromEntries(
|
|
568
|
-
method:
|
|
565
|
+
async function _t(t, e, n, o, a, r, i) {
|
|
566
|
+
return await pt(t, e, a, r, i == null ? void 0 : i.clientPrivateKey), r.set("content-type", "application/x-www-form-urlencoded;charset=UTF-8"), ((i == null ? void 0 : i[X]) || fetch)(o.href, {
|
|
567
|
+
body: a,
|
|
568
|
+
headers: Object.fromEntries(r.entries()),
|
|
569
|
+
method: n,
|
|
569
570
|
redirect: "manual",
|
|
570
571
|
signal: i != null && i.signal ? te(i.signal) : null
|
|
571
572
|
}).then(ee);
|
|
572
573
|
}
|
|
573
|
-
async function
|
|
574
|
-
const
|
|
575
|
-
o.set("grant_type",
|
|
576
|
-
const i =
|
|
577
|
-
return i.set("accept", "application/json"),
|
|
574
|
+
async function Ee(t, e, n, o, a) {
|
|
575
|
+
const r = ke(t, "token_endpoint", Ae(e, a));
|
|
576
|
+
o.set("grant_type", n);
|
|
577
|
+
const i = H(a == null ? void 0 : a.headers);
|
|
578
|
+
return i.set("accept", "application/json"), _t(t, e, "POST", r, o, i, a);
|
|
578
579
|
}
|
|
579
|
-
async function vt(t, e,
|
|
580
|
-
if (
|
|
580
|
+
async function vt(t, e, n, o) {
|
|
581
|
+
if (j(t), I(e), !w(n))
|
|
581
582
|
throw new TypeError('"refreshToken" must be a non-empty string');
|
|
582
|
-
const
|
|
583
|
-
return
|
|
583
|
+
const a = new URLSearchParams(o == null ? void 0 : o.additionalParameters);
|
|
584
|
+
return a.set("refresh_token", n), Ee(t, e, "refresh_token", a, o);
|
|
584
585
|
}
|
|
585
|
-
const
|
|
586
|
-
function
|
|
586
|
+
const Re = /* @__PURE__ */ new WeakMap();
|
|
587
|
+
function St(t) {
|
|
587
588
|
if (!t.id_token)
|
|
588
589
|
return;
|
|
589
|
-
const e =
|
|
590
|
+
const e = Re.get(t);
|
|
590
591
|
if (!e)
|
|
591
592
|
throw new TypeError('"ref" was already garbage collected or did not resolve from the proper sources');
|
|
592
593
|
return e[0];
|
|
593
594
|
}
|
|
594
|
-
async function
|
|
595
|
-
if (
|
|
595
|
+
async function Pe(t, e, n, o = !1, a = !1) {
|
|
596
|
+
if (j(t), I(e), !Q(n, Response))
|
|
596
597
|
throw new TypeError('"response" must be an instance of Response');
|
|
597
|
-
if (
|
|
598
|
+
if (n.status !== 200) {
|
|
598
599
|
let i;
|
|
599
|
-
if (i = await
|
|
600
|
+
if (i = await Lt(n))
|
|
600
601
|
return i;
|
|
601
|
-
throw new
|
|
602
|
+
throw new s('"response" is not a conform Token Endpoint response');
|
|
602
603
|
}
|
|
603
|
-
|
|
604
|
-
let
|
|
604
|
+
ne(n);
|
|
605
|
+
let r;
|
|
605
606
|
try {
|
|
606
|
-
|
|
607
|
+
r = await n.json();
|
|
607
608
|
} catch (i) {
|
|
608
|
-
throw new
|
|
609
|
+
throw new s('failed to parse "response" body as JSON', { cause: i });
|
|
609
610
|
}
|
|
610
|
-
if (!
|
|
611
|
-
throw new
|
|
612
|
-
if (!w(
|
|
613
|
-
throw new
|
|
614
|
-
if (!w(
|
|
615
|
-
throw new
|
|
616
|
-
if (
|
|
617
|
-
throw new
|
|
618
|
-
if (
|
|
619
|
-
throw new
|
|
620
|
-
if (!
|
|
621
|
-
throw new
|
|
622
|
-
if (
|
|
623
|
-
throw new
|
|
611
|
+
if (!C(r))
|
|
612
|
+
throw new s('"response" body must be a top level object');
|
|
613
|
+
if (!w(r.access_token))
|
|
614
|
+
throw new s('"response" body "access_token" property must be a non-empty string');
|
|
615
|
+
if (!w(r.token_type))
|
|
616
|
+
throw new s('"response" body "token_type" property must be a non-empty string');
|
|
617
|
+
if (r.token_type = r.token_type.toLowerCase(), r.token_type !== "dpop" && r.token_type !== "bearer")
|
|
618
|
+
throw new S("unsupported `token_type` value");
|
|
619
|
+
if (r.expires_in !== void 0 && (typeof r.expires_in != "number" || r.expires_in <= 0))
|
|
620
|
+
throw new s('"response" body "expires_in" property must be a positive number');
|
|
621
|
+
if (!a && r.refresh_token !== void 0 && !w(r.refresh_token))
|
|
622
|
+
throw new s('"response" body "refresh_token" property must be a non-empty string');
|
|
623
|
+
if (r.scope !== void 0 && typeof r.scope != "string")
|
|
624
|
+
throw new s('"response" body "scope" property must be a string');
|
|
624
625
|
if (!o) {
|
|
625
|
-
if (
|
|
626
|
-
throw new
|
|
627
|
-
if (
|
|
628
|
-
const { claims: i, jwt: c } = await
|
|
626
|
+
if (r.id_token !== void 0 && !w(r.id_token))
|
|
627
|
+
throw new s('"response" body "id_token" property must be a non-empty string');
|
|
628
|
+
if (r.id_token) {
|
|
629
|
+
const { claims: i, jwt: c } = await Jt(r.id_token, Ot.bind(void 0, e.id_token_signed_response_alg, t.id_token_signing_alg_values_supported), Ce, L(e), Se(e), e[Be]).then(Ut.bind(void 0, ["aud", "exp", "iat", "iss", "sub"])).then(At.bind(void 0, t.issuer)).then(kt.bind(void 0, e.client_id));
|
|
629
630
|
if (Array.isArray(i.aud) && i.aud.length !== 1) {
|
|
630
631
|
if (i.azp === void 0)
|
|
631
|
-
throw new
|
|
632
|
+
throw new s('ID Token "aud" (audience) claim includes additional untrusted audiences');
|
|
632
633
|
if (i.azp !== e.client_id)
|
|
633
|
-
throw new
|
|
634
|
+
throw new s('unexpected ID Token "azp" (authorized party) claim value');
|
|
634
635
|
}
|
|
635
636
|
if (i.auth_time !== void 0 && (!Number.isFinite(i.auth_time) || Math.sign(i.auth_time) !== 1))
|
|
636
|
-
throw new
|
|
637
|
-
|
|
637
|
+
throw new s('ID Token "auth_time" (authentication time) must be a positive number');
|
|
638
|
+
Re.set(r, [i, c]);
|
|
638
639
|
}
|
|
639
640
|
}
|
|
640
|
-
return
|
|
641
|
+
return r;
|
|
641
642
|
}
|
|
642
|
-
async function
|
|
643
|
-
return
|
|
643
|
+
async function Tt(t, e, n) {
|
|
644
|
+
return Pe(t, e, n);
|
|
644
645
|
}
|
|
645
|
-
function
|
|
646
|
+
function kt(t, e) {
|
|
646
647
|
if (Array.isArray(e.claims.aud)) {
|
|
647
648
|
if (!e.claims.aud.includes(t))
|
|
648
|
-
throw new
|
|
649
|
+
throw new s('unexpected JWT "aud" (audience) claim value');
|
|
649
650
|
} else if (e.claims.aud !== t)
|
|
650
|
-
throw new
|
|
651
|
+
throw new s('unexpected JWT "aud" (audience) claim value');
|
|
651
652
|
return e;
|
|
652
653
|
}
|
|
653
654
|
function At(t, e) {
|
|
654
655
|
if (e.claims.iss !== t)
|
|
655
|
-
throw new
|
|
656
|
+
throw new s('unexpected JWT "iss" (issuer) claim value');
|
|
656
657
|
return e;
|
|
657
658
|
}
|
|
658
|
-
const
|
|
659
|
-
function
|
|
660
|
-
return
|
|
659
|
+
const Ue = /* @__PURE__ */ new WeakSet();
|
|
660
|
+
function Et(t) {
|
|
661
|
+
return Ue.add(t), t;
|
|
661
662
|
}
|
|
662
|
-
async function
|
|
663
|
-
if (
|
|
663
|
+
async function Rt(t, e, n, o, a, r) {
|
|
664
|
+
if (j(t), I(e), !Ue.has(n))
|
|
664
665
|
throw new TypeError('"callbackParameters" must be an instance of URLSearchParams obtained from "validateAuthResponse()", or "validateJwtAuthResponse()');
|
|
665
666
|
if (!w(o))
|
|
666
667
|
throw new TypeError('"redirectUri" must be a non-empty string');
|
|
667
|
-
if (!w(
|
|
668
|
+
if (!w(a))
|
|
668
669
|
throw new TypeError('"codeVerifier" must be a non-empty string');
|
|
669
|
-
const i = k(
|
|
670
|
+
const i = k(n, "code");
|
|
670
671
|
if (!i)
|
|
671
|
-
throw new
|
|
672
|
-
const c = new URLSearchParams(
|
|
673
|
-
return c.set("redirect_uri", o), c.set("code_verifier",
|
|
672
|
+
throw new s('no authorization code in "callbackParameters"');
|
|
673
|
+
const c = new URLSearchParams(r == null ? void 0 : r.additionalParameters);
|
|
674
|
+
return c.set("redirect_uri", o), c.set("code_verifier", a), c.set("code", i), Ee(t, e, "authorization_code", c, r);
|
|
674
675
|
}
|
|
675
|
-
const
|
|
676
|
+
const Pt = {
|
|
676
677
|
aud: "audience",
|
|
677
678
|
c_hash: "code hash",
|
|
678
679
|
client_id: "client id",
|
|
@@ -688,64 +689,64 @@ const Ut = {
|
|
|
688
689
|
htu: "http uri",
|
|
689
690
|
cnf: "confirmation"
|
|
690
691
|
};
|
|
691
|
-
function
|
|
692
|
-
for (const
|
|
693
|
-
if (e.claims[
|
|
694
|
-
throw new
|
|
692
|
+
function Ut(t, e) {
|
|
693
|
+
for (const n of t)
|
|
694
|
+
if (e.claims[n] === void 0)
|
|
695
|
+
throw new s(`JWT "${n}" (${Pt[n]}) claim missing`);
|
|
695
696
|
return e;
|
|
696
697
|
}
|
|
697
|
-
const
|
|
698
|
-
async function Ct(t, e,
|
|
699
|
-
const
|
|
700
|
-
if (
|
|
701
|
-
return
|
|
702
|
-
if (!w(
|
|
703
|
-
throw new
|
|
704
|
-
|
|
705
|
-
const i =
|
|
706
|
-
if ((e.require_auth_time ||
|
|
707
|
-
throw new
|
|
708
|
-
if (
|
|
709
|
-
if (typeof
|
|
698
|
+
const xt = Symbol(), B = Symbol();
|
|
699
|
+
async function Ct(t, e, n, o, a) {
|
|
700
|
+
const r = await Pe(t, e, n);
|
|
701
|
+
if (Y(r))
|
|
702
|
+
return r;
|
|
703
|
+
if (!w(r.id_token))
|
|
704
|
+
throw new s('"response" body "id_token" property must be a non-empty string');
|
|
705
|
+
a ?? (a = e.default_max_age ?? B);
|
|
706
|
+
const i = St(r);
|
|
707
|
+
if ((e.require_auth_time || a !== B) && i.auth_time === void 0)
|
|
708
|
+
throw new s('ID Token "auth_time" (authentication time) claim missing');
|
|
709
|
+
if (a !== B) {
|
|
710
|
+
if (typeof a != "number" || a < 0)
|
|
710
711
|
throw new TypeError('"maxAge" must be a non-negative number');
|
|
711
|
-
const c =
|
|
712
|
-
if (i.auth_time +
|
|
713
|
-
throw new
|
|
712
|
+
const c = F() + L(e), h = Se(e);
|
|
713
|
+
if (i.auth_time + a < c - h)
|
|
714
|
+
throw new s("too much time has elapsed since the last End-User authentication");
|
|
714
715
|
}
|
|
715
716
|
switch (o) {
|
|
716
717
|
case void 0:
|
|
717
|
-
case
|
|
718
|
+
case xt:
|
|
718
719
|
if (i.nonce !== void 0)
|
|
719
|
-
throw new
|
|
720
|
+
throw new s('unexpected ID Token "nonce" claim value');
|
|
720
721
|
break;
|
|
721
722
|
default:
|
|
722
723
|
if (!w(o))
|
|
723
724
|
throw new TypeError('"expectedNonce" must be a non-empty string');
|
|
724
725
|
if (i.nonce === void 0)
|
|
725
|
-
throw new
|
|
726
|
+
throw new s('ID Token "nonce" claim missing');
|
|
726
727
|
if (i.nonce !== o)
|
|
727
|
-
throw new
|
|
728
|
+
throw new s('unexpected ID Token "nonce" claim value');
|
|
728
729
|
}
|
|
729
|
-
return
|
|
730
|
+
return r;
|
|
730
731
|
}
|
|
731
|
-
function
|
|
732
|
+
function ne(t) {
|
|
732
733
|
if (t.bodyUsed)
|
|
733
734
|
throw new TypeError('"response" body has been used already');
|
|
734
735
|
}
|
|
735
|
-
async function
|
|
736
|
+
async function Lt(t) {
|
|
736
737
|
if (t.status > 399 && t.status < 500) {
|
|
737
|
-
|
|
738
|
+
ne(t);
|
|
738
739
|
try {
|
|
739
740
|
const e = await t.json();
|
|
740
|
-
if (
|
|
741
|
+
if (C(e) && typeof e.error == "string" && e.error.length)
|
|
741
742
|
return e.error_description !== void 0 && typeof e.error_description != "string" && delete e.error_description, e.error_uri !== void 0 && typeof e.error_uri != "string" && delete e.error_uri, e.algs !== void 0 && typeof e.algs != "string" && delete e.algs, e.scope !== void 0 && typeof e.scope != "string" && delete e.scope, e;
|
|
742
743
|
} catch {
|
|
743
744
|
}
|
|
744
745
|
}
|
|
745
746
|
}
|
|
746
|
-
function
|
|
747
|
+
function pe(t) {
|
|
747
748
|
if (typeof t.modulusLength != "number" || t.modulusLength < 2048)
|
|
748
|
-
throw new
|
|
749
|
+
throw new s(`${t.name} modulusLength must be at least 2048 bits`);
|
|
749
750
|
}
|
|
750
751
|
function jt(t) {
|
|
751
752
|
switch (t) {
|
|
@@ -756,10 +757,10 @@ function jt(t) {
|
|
|
756
757
|
case "P-521":
|
|
757
758
|
return "SHA-512";
|
|
758
759
|
default:
|
|
759
|
-
throw new
|
|
760
|
+
throw new S();
|
|
760
761
|
}
|
|
761
762
|
}
|
|
762
|
-
function
|
|
763
|
+
function xe(t) {
|
|
763
764
|
switch (t.algorithm.name) {
|
|
764
765
|
case "ECDSA":
|
|
765
766
|
return {
|
|
@@ -767,7 +768,7 @@ function Pe(t) {
|
|
|
767
768
|
hash: jt(t.algorithm.namedCurve)
|
|
768
769
|
};
|
|
769
770
|
case "RSA-PSS":
|
|
770
|
-
switch (
|
|
771
|
+
switch (pe(t.algorithm), t.algorithm.hash.name) {
|
|
771
772
|
case "SHA-256":
|
|
772
773
|
case "SHA-384":
|
|
773
774
|
case "SHA-512":
|
|
@@ -776,245 +777,244 @@ function Pe(t) {
|
|
|
776
777
|
saltLength: parseInt(t.algorithm.hash.name.slice(-3), 10) >> 3
|
|
777
778
|
};
|
|
778
779
|
default:
|
|
779
|
-
throw new
|
|
780
|
+
throw new S();
|
|
780
781
|
}
|
|
781
782
|
case "RSASSA-PKCS1-v1_5":
|
|
782
|
-
return
|
|
783
|
+
return pe(t.algorithm), t.algorithm.name;
|
|
783
784
|
case "Ed448":
|
|
784
785
|
case "Ed25519":
|
|
785
786
|
return t.algorithm.name;
|
|
786
787
|
}
|
|
787
|
-
throw new
|
|
788
|
-
}
|
|
789
|
-
const
|
|
790
|
-
async function
|
|
791
|
-
const
|
|
792
|
-
if (!await crypto.subtle.verify(
|
|
793
|
-
throw new
|
|
794
|
-
}
|
|
795
|
-
async function
|
|
796
|
-
let { 0: i, 1: c, 2:
|
|
797
|
-
if (
|
|
798
|
-
if (
|
|
799
|
-
t = await
|
|
788
|
+
throw new S();
|
|
789
|
+
}
|
|
790
|
+
const Ce = Symbol();
|
|
791
|
+
async function It(t, e, n, o) {
|
|
792
|
+
const a = `${t}.${e}`;
|
|
793
|
+
if (!await crypto.subtle.verify(xe(n), n, o, E(a)))
|
|
794
|
+
throw new s("JWT signature verification failed");
|
|
795
|
+
}
|
|
796
|
+
async function Jt(t, e, n, o, a, r) {
|
|
797
|
+
let { 0: i, 1: c, 2: h, length: _ } = t.split(".");
|
|
798
|
+
if (_ === 5)
|
|
799
|
+
if (r !== void 0)
|
|
800
|
+
t = await r(t), { 0: i, 1: c, 2: h, length: _ } = t.split(".");
|
|
800
801
|
else
|
|
801
|
-
throw new
|
|
802
|
-
if (
|
|
803
|
-
throw new
|
|
804
|
-
let
|
|
802
|
+
throw new S("JWE structure JWTs are not supported");
|
|
803
|
+
if (_ !== 3)
|
|
804
|
+
throw new s("Invalid JWT");
|
|
805
|
+
let p;
|
|
805
806
|
try {
|
|
806
|
-
|
|
807
|
+
p = JSON.parse(E(A(i)));
|
|
807
808
|
} catch (l) {
|
|
808
|
-
throw new
|
|
809
|
+
throw new s("failed to parse JWT Header body as base64url encoded JSON", { cause: l });
|
|
809
810
|
}
|
|
810
|
-
if (!
|
|
811
|
-
throw new
|
|
812
|
-
if (e(
|
|
813
|
-
throw new
|
|
814
|
-
const y =
|
|
811
|
+
if (!C(p))
|
|
812
|
+
throw new s("JWT Header must be a top level object");
|
|
813
|
+
if (e(p), p.crit !== void 0)
|
|
814
|
+
throw new s('unexpected JWT "crit" header parameter');
|
|
815
|
+
const y = A(h);
|
|
815
816
|
let T;
|
|
816
|
-
|
|
817
|
-
let
|
|
817
|
+
n !== Ce && (T = await n(p), await It(i, c, T, y));
|
|
818
|
+
let f;
|
|
818
819
|
try {
|
|
819
|
-
|
|
820
|
+
f = JSON.parse(E(A(c)));
|
|
820
821
|
} catch (l) {
|
|
821
|
-
throw new
|
|
822
|
+
throw new s("failed to parse JWT Payload body as base64url encoded JSON", { cause: l });
|
|
822
823
|
}
|
|
823
|
-
if (!
|
|
824
|
-
throw new
|
|
825
|
-
const J =
|
|
826
|
-
if (
|
|
827
|
-
if (typeof
|
|
828
|
-
throw new
|
|
829
|
-
if (
|
|
830
|
-
throw new
|
|
824
|
+
if (!C(f))
|
|
825
|
+
throw new s("JWT Payload must be a top level object");
|
|
826
|
+
const J = F() + o;
|
|
827
|
+
if (f.exp !== void 0) {
|
|
828
|
+
if (typeof f.exp != "number")
|
|
829
|
+
throw new s('unexpected JWT "exp" (expiration time) claim type');
|
|
830
|
+
if (f.exp <= J - a)
|
|
831
|
+
throw new s('unexpected JWT "exp" (expiration time) claim value, timestamp is <= now()');
|
|
831
832
|
}
|
|
832
|
-
if (
|
|
833
|
-
throw new
|
|
834
|
-
if (
|
|
835
|
-
throw new
|
|
836
|
-
if (
|
|
837
|
-
if (typeof
|
|
838
|
-
throw new
|
|
839
|
-
if (
|
|
840
|
-
throw new
|
|
833
|
+
if (f.iat !== void 0 && typeof f.iat != "number")
|
|
834
|
+
throw new s('unexpected JWT "iat" (issued at) claim type');
|
|
835
|
+
if (f.iss !== void 0 && typeof f.iss != "string")
|
|
836
|
+
throw new s('unexpected JWT "iss" (issuer) claim type');
|
|
837
|
+
if (f.nbf !== void 0) {
|
|
838
|
+
if (typeof f.nbf != "number")
|
|
839
|
+
throw new s('unexpected JWT "nbf" (not before) claim type');
|
|
840
|
+
if (f.nbf > J + a)
|
|
841
|
+
throw new s('unexpected JWT "nbf" (not before) claim value, timestamp is > now()');
|
|
841
842
|
}
|
|
842
|
-
if (
|
|
843
|
-
throw new
|
|
844
|
-
return { header:
|
|
843
|
+
if (f.aud !== void 0 && typeof f.aud != "string" && !Array.isArray(f.aud))
|
|
844
|
+
throw new s('unexpected JWT "aud" (audience) claim type');
|
|
845
|
+
return { header: p, claims: f, signature: y, key: T, jwt: t };
|
|
845
846
|
}
|
|
846
|
-
function
|
|
847
|
+
function Ot(t, e, n) {
|
|
847
848
|
if (t !== void 0) {
|
|
848
|
-
if (
|
|
849
|
-
throw new
|
|
849
|
+
if (n.alg !== t)
|
|
850
|
+
throw new s('unexpected JWT "alg" header parameter');
|
|
850
851
|
return;
|
|
851
852
|
}
|
|
852
853
|
if (Array.isArray(e)) {
|
|
853
|
-
if (!e.includes(
|
|
854
|
-
throw new
|
|
854
|
+
if (!e.includes(n.alg))
|
|
855
|
+
throw new s('unexpected JWT "alg" header parameter');
|
|
855
856
|
return;
|
|
856
857
|
}
|
|
857
|
-
if (
|
|
858
|
-
throw new
|
|
858
|
+
if (n.alg !== "RS256")
|
|
859
|
+
throw new s('unexpected JWT "alg" header parameter');
|
|
859
860
|
}
|
|
860
861
|
function k(t, e) {
|
|
861
|
-
const { 0:
|
|
862
|
+
const { 0: n, length: o } = t.getAll(e);
|
|
862
863
|
if (o > 1)
|
|
863
|
-
throw new
|
|
864
|
-
return
|
|
864
|
+
throw new s(`"${e}" parameter must be provided only once`);
|
|
865
|
+
return n;
|
|
865
866
|
}
|
|
866
|
-
const
|
|
867
|
-
function
|
|
868
|
-
if (
|
|
867
|
+
const zt = Symbol(), Dt = Symbol();
|
|
868
|
+
function Nt(t, e, n, o) {
|
|
869
|
+
if (j(t), I(e), n instanceof URL && (n = n.searchParams), !(n instanceof URLSearchParams))
|
|
869
870
|
throw new TypeError('"parameters" must be an instance of URLSearchParams, or URL');
|
|
870
|
-
if (k(
|
|
871
|
-
throw new
|
|
872
|
-
const
|
|
873
|
-
if (!
|
|
874
|
-
throw new
|
|
875
|
-
if (
|
|
876
|
-
throw new
|
|
871
|
+
if (k(n, "response"))
|
|
872
|
+
throw new s('"parameters" contains a JARM response, use validateJwtAuthResponse() instead of validateAuthResponse()');
|
|
873
|
+
const a = k(n, "iss"), r = k(n, "state");
|
|
874
|
+
if (!a && t.authorization_response_iss_parameter_supported)
|
|
875
|
+
throw new s('response parameter "iss" (issuer) missing');
|
|
876
|
+
if (a && a !== t.issuer)
|
|
877
|
+
throw new s('unexpected "iss" (issuer) response parameter value');
|
|
877
878
|
switch (o) {
|
|
878
879
|
case void 0:
|
|
879
880
|
case Dt:
|
|
880
|
-
if (
|
|
881
|
-
throw new
|
|
881
|
+
if (r !== void 0)
|
|
882
|
+
throw new s('unexpected "state" response parameter encountered');
|
|
882
883
|
break;
|
|
883
|
-
case
|
|
884
|
+
case zt:
|
|
884
885
|
break;
|
|
885
886
|
default:
|
|
886
887
|
if (!w(o))
|
|
887
|
-
throw new
|
|
888
|
-
if (
|
|
889
|
-
throw new
|
|
890
|
-
if (
|
|
891
|
-
throw new
|
|
888
|
+
throw new s('"expectedState" must be a non-empty string');
|
|
889
|
+
if (r === void 0)
|
|
890
|
+
throw new s('response parameter "state" missing');
|
|
891
|
+
if (r !== o)
|
|
892
|
+
throw new s('unexpected "state" response parameter value');
|
|
892
893
|
}
|
|
893
|
-
const i = k(
|
|
894
|
+
const i = k(n, "error");
|
|
894
895
|
if (i)
|
|
895
896
|
return {
|
|
896
897
|
error: i,
|
|
897
|
-
error_description: k(
|
|
898
|
-
error_uri: k(
|
|
898
|
+
error_description: k(n, "error_description"),
|
|
899
|
+
error_uri: k(n, "error_uri")
|
|
899
900
|
};
|
|
900
|
-
const c = k(
|
|
901
|
-
if (c !== void 0 ||
|
|
902
|
-
throw new
|
|
903
|
-
return
|
|
901
|
+
const c = k(n, "id_token"), h = k(n, "token");
|
|
902
|
+
if (c !== void 0 || h !== void 0)
|
|
903
|
+
throw new S("implicit and hybrid flows are not supported");
|
|
904
|
+
return Et(new URLSearchParams(n));
|
|
904
905
|
}
|
|
905
|
-
function
|
|
906
|
+
function Kt({
|
|
906
907
|
handleCallback: t
|
|
907
908
|
}) {
|
|
908
|
-
const
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
|
|
921
|
-
/* @__PURE__ */ A.jsx(We, { className: "mb-4", children: "Check the configuration of your authorization provider and ensure all settings such as the callback URL are configured correctly." }),
|
|
922
|
-
"An error occurred while authorizing the user.",
|
|
923
|
-
/* @__PURE__ */ A.jsx(Fe, { code: e.toString(), language: "plain" })
|
|
924
|
-
] })
|
|
909
|
+
const e = Ke({
|
|
910
|
+
retry: !1,
|
|
911
|
+
queryKey: ["oauth-callback"],
|
|
912
|
+
queryFn: async () => {
|
|
913
|
+
try {
|
|
914
|
+
return await t();
|
|
915
|
+
} catch (n) {
|
|
916
|
+
throw new He("Could not validate user", {
|
|
917
|
+
cause: n,
|
|
918
|
+
title: "Authentication Error",
|
|
919
|
+
developerHint: "Check the configuration of your authorization provider and ensure all settings such as the callback URL are configured correctly."
|
|
920
|
+
});
|
|
921
|
+
}
|
|
925
922
|
}
|
|
926
|
-
|
|
923
|
+
});
|
|
924
|
+
return /* @__PURE__ */ G.jsx(We, { to: e.data });
|
|
927
925
|
}
|
|
928
|
-
class
|
|
926
|
+
class P extends Error {
|
|
929
927
|
}
|
|
930
|
-
class
|
|
931
|
-
constructor(e,
|
|
932
|
-
super(e, o), this.error =
|
|
928
|
+
class we extends P {
|
|
929
|
+
constructor(e, n, o) {
|
|
930
|
+
super(e, o), this.error = n;
|
|
933
931
|
}
|
|
934
932
|
}
|
|
935
|
-
const
|
|
936
|
-
class
|
|
937
|
-
constructor(e,
|
|
938
|
-
super(), this.callbackUrlPath = e, this.handleCallback =
|
|
933
|
+
const V = "code-verifier";
|
|
934
|
+
class Wt extends Ne {
|
|
935
|
+
constructor(e, n) {
|
|
936
|
+
super(), this.callbackUrlPath = e, this.handleCallback = n;
|
|
939
937
|
}
|
|
940
938
|
getRoutes() {
|
|
941
939
|
return [
|
|
942
940
|
...super.getRoutes(),
|
|
943
941
|
{
|
|
944
942
|
path: this.callbackUrlPath,
|
|
945
|
-
element: /* @__PURE__ */
|
|
943
|
+
element: /* @__PURE__ */ G.jsx(De, { children: /* @__PURE__ */ G.jsx(Kt, { handleCallback: this.handleCallback }) })
|
|
946
944
|
}
|
|
947
945
|
];
|
|
948
946
|
}
|
|
949
947
|
}
|
|
950
|
-
class
|
|
948
|
+
class Ht {
|
|
951
949
|
constructor({
|
|
952
950
|
issuer: e,
|
|
953
|
-
audience:
|
|
951
|
+
audience: n,
|
|
954
952
|
clientId: o,
|
|
955
|
-
redirectToAfterSignUp:
|
|
956
|
-
redirectToAfterSignIn:
|
|
957
|
-
redirectToAfterSignOut: i
|
|
953
|
+
redirectToAfterSignUp: a,
|
|
954
|
+
redirectToAfterSignIn: r,
|
|
955
|
+
redirectToAfterSignOut: i,
|
|
956
|
+
basePath: c
|
|
958
957
|
}) {
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
962
|
-
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
958
|
+
b(this, "client");
|
|
959
|
+
b(this, "issuer");
|
|
960
|
+
b(this, "authorizationServer");
|
|
961
|
+
b(this, "callbackUrlPath");
|
|
962
|
+
b(this, "logoutRedirectUrlPath");
|
|
963
|
+
b(this, "onAuthorizationUrl");
|
|
964
|
+
b(this, "redirectToAfterSignUp");
|
|
965
|
+
b(this, "redirectToAfterSignIn");
|
|
966
|
+
b(this, "redirectToAfterSignOut");
|
|
967
|
+
b(this, "audience");
|
|
968
|
+
b(this, "signOut", async () => {
|
|
969
|
+
x.setState({
|
|
971
970
|
isAuthenticated: !1,
|
|
972
971
|
isPending: !1,
|
|
973
|
-
profile: void 0
|
|
974
|
-
|
|
975
|
-
|
|
972
|
+
profile: void 0,
|
|
973
|
+
providerData: void 0
|
|
974
|
+
});
|
|
975
|
+
const e = await this.getAuthServer(), n = new URL(
|
|
976
976
|
window.location.origin + this.redirectToAfterSignOut
|
|
977
977
|
);
|
|
978
|
-
|
|
978
|
+
n.pathname = this.logoutRedirectUrlPath;
|
|
979
979
|
let o;
|
|
980
980
|
e.end_session_endpoint ? (o = new URL(e.end_session_endpoint), o.searchParams.set(
|
|
981
981
|
"post_logout_redirect_uri",
|
|
982
|
-
|
|
983
|
-
)) : o =
|
|
982
|
+
n.toString()
|
|
983
|
+
)) : o = n;
|
|
984
984
|
});
|
|
985
|
-
|
|
986
|
-
const e = new URL(window.location.href),
|
|
987
|
-
if (sessionStorage.removeItem(
|
|
988
|
-
throw new
|
|
989
|
-
const
|
|
990
|
-
|
|
985
|
+
b(this, "handleCallback", async () => {
|
|
986
|
+
const e = new URL(window.location.href), n = e.searchParams.get("state"), o = sessionStorage.getItem(V);
|
|
987
|
+
if (sessionStorage.removeItem(V), !o)
|
|
988
|
+
throw new P("No code verifier found in state.");
|
|
989
|
+
const a = await this.getAuthServer(), r = Nt(
|
|
990
|
+
a,
|
|
991
991
|
this.client,
|
|
992
992
|
e.searchParams,
|
|
993
|
-
|
|
993
|
+
n ?? void 0
|
|
994
994
|
);
|
|
995
|
-
if (
|
|
996
|
-
throw
|
|
995
|
+
if (Y(r))
|
|
996
|
+
throw ce.error("Error validating OAuth response", r), new we(
|
|
997
997
|
"Error validating OAuth response",
|
|
998
|
-
|
|
998
|
+
r
|
|
999
999
|
);
|
|
1000
1000
|
const i = new URL(e);
|
|
1001
|
-
i.pathname = this.
|
|
1002
|
-
const c = await
|
|
1003
|
-
|
|
1001
|
+
i.pathname = this.callbackUrlPath, i.search = "";
|
|
1002
|
+
const c = await Rt(
|
|
1003
|
+
a,
|
|
1004
1004
|
this.client,
|
|
1005
|
-
|
|
1005
|
+
r,
|
|
1006
1006
|
i.toString(),
|
|
1007
1007
|
o
|
|
1008
|
-
),
|
|
1009
|
-
|
|
1008
|
+
), h = await Ct(
|
|
1009
|
+
a,
|
|
1010
1010
|
this.client,
|
|
1011
1011
|
c
|
|
1012
1012
|
);
|
|
1013
|
-
this.setTokensFromResponse(
|
|
1014
|
-
const
|
|
1015
|
-
|
|
1013
|
+
this.setTokensFromResponse(h);
|
|
1014
|
+
const _ = await this.getAccessToken(), y = await (await bt(
|
|
1015
|
+
a,
|
|
1016
1016
|
this.client,
|
|
1017
|
-
|
|
1017
|
+
_
|
|
1018
1018
|
)).json(), T = {
|
|
1019
1019
|
sub: y.sub,
|
|
1020
1020
|
email: y.email,
|
|
@@ -1022,28 +1022,27 @@ class $t {
|
|
|
1022
1022
|
emailVerified: y.email_verified ?? !1,
|
|
1023
1023
|
pictureUrl: y.picture
|
|
1024
1024
|
};
|
|
1025
|
-
|
|
1025
|
+
x.setState({
|
|
1026
1026
|
isAuthenticated: !0,
|
|
1027
1027
|
isPending: !1,
|
|
1028
1028
|
profile: T
|
|
1029
|
-
})
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
);
|
|
1033
|
-
const h = sessionStorage.getItem("redirect-to") ?? "/";
|
|
1034
|
-
return sessionStorage.removeItem("redirect-to"), h;
|
|
1029
|
+
});
|
|
1030
|
+
const f = sessionStorage.getItem("redirect-to") ?? "/";
|
|
1031
|
+
return sessionStorage.removeItem("redirect-to"), f;
|
|
1035
1032
|
});
|
|
1036
1033
|
this.client = {
|
|
1037
1034
|
client_id: o,
|
|
1038
1035
|
token_endpoint_auth_method: "none"
|
|
1039
|
-
}, this.audience =
|
|
1036
|
+
}, this.audience = n, this.issuer = e, this.callbackUrlPath = ae(c, "/oauth/callback");
|
|
1037
|
+
const h = ae(c, "/");
|
|
1038
|
+
this.logoutRedirectUrlPath = h, this.redirectToAfterSignUp = a ?? h, this.redirectToAfterSignIn = r ?? h, this.redirectToAfterSignOut = i ?? h;
|
|
1040
1039
|
}
|
|
1041
1040
|
async getAuthServer() {
|
|
1042
1041
|
if (!this.authorizationServer) {
|
|
1043
|
-
const e = new URL(this.issuer),
|
|
1044
|
-
this.authorizationServer = await
|
|
1042
|
+
const e = new URL(this.issuer), n = await nt(e);
|
|
1043
|
+
this.authorizationServer = await rt(
|
|
1045
1044
|
e,
|
|
1046
|
-
|
|
1045
|
+
n
|
|
1047
1046
|
);
|
|
1048
1047
|
}
|
|
1049
1048
|
return this.authorizationServer;
|
|
@@ -1053,17 +1052,20 @@ class $t {
|
|
|
1053
1052
|
* @param response
|
|
1054
1053
|
*/
|
|
1055
1054
|
setTokensFromResponse(e) {
|
|
1056
|
-
if (
|
|
1057
|
-
throw
|
|
1055
|
+
if (Y(e))
|
|
1056
|
+
throw ce.error("Bad Token Response", e), new we("Bad Token Response", e);
|
|
1058
1057
|
if (!e.expires_in)
|
|
1059
|
-
throw new
|
|
1060
|
-
const
|
|
1058
|
+
throw new P("No expires_in in response");
|
|
1059
|
+
const n = {
|
|
1061
1060
|
accessToken: e.access_token,
|
|
1062
1061
|
refreshToken: e.refresh_token,
|
|
1062
|
+
idToken: e.id_token,
|
|
1063
1063
|
expiresOn: new Date(Date.now() + e.expires_in * 1e3),
|
|
1064
1064
|
tokenType: e.token_type
|
|
1065
1065
|
};
|
|
1066
|
-
|
|
1066
|
+
x.setState({
|
|
1067
|
+
providerData: n
|
|
1068
|
+
});
|
|
1067
1069
|
}
|
|
1068
1070
|
async signUp({ redirectTo: e } = {}) {
|
|
1069
1071
|
return this.authorize({
|
|
@@ -1078,75 +1080,66 @@ class $t {
|
|
|
1078
1080
|
}
|
|
1079
1081
|
async authorize({
|
|
1080
1082
|
redirectTo: e,
|
|
1081
|
-
isSignUp:
|
|
1083
|
+
isSignUp: n = !1
|
|
1082
1084
|
}) {
|
|
1083
|
-
var
|
|
1084
|
-
const o = "S256",
|
|
1085
|
-
if (!
|
|
1086
|
-
throw new
|
|
1087
|
-
const
|
|
1088
|
-
sessionStorage.setItem(
|
|
1085
|
+
var _, p;
|
|
1086
|
+
const o = "S256", a = await this.getAuthServer();
|
|
1087
|
+
if (!a.authorization_endpoint)
|
|
1088
|
+
throw new P("No authorization endpoint");
|
|
1089
|
+
const r = ot(), i = await at(r);
|
|
1090
|
+
sessionStorage.setItem(V, r);
|
|
1089
1091
|
const c = new URL(
|
|
1090
|
-
|
|
1092
|
+
a.authorization_endpoint
|
|
1091
1093
|
);
|
|
1092
1094
|
sessionStorage.setItem("redirect-to", e);
|
|
1093
|
-
const
|
|
1094
|
-
if (
|
|
1095
|
+
const h = new URL(window.location.origin);
|
|
1096
|
+
if (h.pathname = this.callbackUrlPath, h.search = "", c.searchParams.set("client_id", this.client.client_id), c.searchParams.set("redirect_uri", h.toString()), c.searchParams.set("response_type", "code"), c.searchParams.set("scope", "openid profile email"), c.searchParams.set("code_challenge", i), c.searchParams.set(
|
|
1095
1097
|
"code_challenge_method",
|
|
1096
1098
|
o
|
|
1097
|
-
), this.audience && c.searchParams.set("audience", this.audience), (
|
|
1098
|
-
isSignIn: !
|
|
1099
|
-
isSignUp:
|
|
1100
|
-
}), ((
|
|
1101
|
-
const y =
|
|
1099
|
+
), this.audience && c.searchParams.set("audience", this.audience), (_ = this.onAuthorizationUrl) == null || _.call(this, c, {
|
|
1100
|
+
isSignIn: !n,
|
|
1101
|
+
isSignUp: n
|
|
1102
|
+
}), ((p = a.code_challenge_methods_supported) == null ? void 0 : p.includes("S256")) !== !0) {
|
|
1103
|
+
const y = it();
|
|
1102
1104
|
c.searchParams.set("state", y);
|
|
1103
1105
|
}
|
|
1104
1106
|
location.href = c.href;
|
|
1105
1107
|
}
|
|
1106
1108
|
async getAccessToken() {
|
|
1107
|
-
const e = await this.getAuthServer(),
|
|
1108
|
-
if (!
|
|
1109
|
-
throw new
|
|
1110
|
-
const o =
|
|
1111
|
-
if (o.expiresOn < /* @__PURE__ */ new Date()) {
|
|
1109
|
+
const e = await this.getAuthServer(), { providerData: n } = x.getState();
|
|
1110
|
+
if (!n)
|
|
1111
|
+
throw new P("User is not authenticated");
|
|
1112
|
+
const o = n;
|
|
1113
|
+
if (new Date(o.expiresOn) < /* @__PURE__ */ new Date()) {
|
|
1112
1114
|
if (!o.refreshToken)
|
|
1113
|
-
return
|
|
1114
|
-
|
|
1115
|
+
return x.setState({
|
|
1116
|
+
isAuthenticated: !1,
|
|
1117
|
+
isPending: !1,
|
|
1118
|
+
profile: null,
|
|
1119
|
+
providerData: null
|
|
1120
|
+
}), "";
|
|
1121
|
+
const a = await vt(
|
|
1115
1122
|
e,
|
|
1116
1123
|
this.client,
|
|
1117
1124
|
o.refreshToken
|
|
1118
|
-
),
|
|
1125
|
+
), r = await Tt(
|
|
1119
1126
|
e,
|
|
1120
1127
|
this.client,
|
|
1121
|
-
|
|
1128
|
+
a
|
|
1122
1129
|
);
|
|
1123
|
-
if (!
|
|
1124
|
-
throw new
|
|
1125
|
-
return this.setTokensFromResponse(
|
|
1130
|
+
if (!r.access_token)
|
|
1131
|
+
throw new P("No access token in response");
|
|
1132
|
+
return this.setTokensFromResponse(r), r.access_token.toString();
|
|
1126
1133
|
} else
|
|
1127
1134
|
return o.accessToken;
|
|
1128
1135
|
}
|
|
1129
|
-
pageLoad() {
|
|
1130
|
-
const e = sessionStorage.getItem("profile-state");
|
|
1131
|
-
if (e)
|
|
1132
|
-
try {
|
|
1133
|
-
const r = JSON.parse(e);
|
|
1134
|
-
N.setState({
|
|
1135
|
-
isAuthenticated: !0,
|
|
1136
|
-
isPending: !1,
|
|
1137
|
-
profile: r
|
|
1138
|
-
});
|
|
1139
|
-
} catch (r) {
|
|
1140
|
-
K.error("Error parsing auth state", r);
|
|
1141
|
-
}
|
|
1142
|
-
}
|
|
1143
1136
|
getAuthenticationPlugin() {
|
|
1144
|
-
return new
|
|
1137
|
+
return new Wt(this.callbackUrlPath, this.handleCallback);
|
|
1145
1138
|
}
|
|
1146
1139
|
}
|
|
1147
|
-
const
|
|
1140
|
+
const Xt = (t) => new Ht(t);
|
|
1148
1141
|
export {
|
|
1149
|
-
|
|
1150
|
-
|
|
1142
|
+
Ht as OpenIDAuthenticationProvider,
|
|
1143
|
+
Xt as default
|
|
1151
1144
|
};
|
|
1152
1145
|
//# sourceMappingURL=zudoku.auth-openid.js.map
|