zudoku 0.0.0-f3f6db5 → 0.0.0-f40ea27
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 +1 -1
- package/cli.js +9 -0
- package/dist/app/ZuploBuildConfig.d.ts +45 -0
- package/dist/app/ZuploBuildConfig.js +29 -0
- package/dist/app/ZuploBuildConfig.js.map +1 -0
- package/dist/app/demo.js +6 -5
- package/dist/app/demo.js.map +1 -1
- package/dist/app/entry.client.d.ts +5 -2
- package/dist/app/entry.client.js +37 -2
- package/dist/app/entry.client.js.map +1 -1
- package/dist/app/entry.server.d.ts +8 -8
- package/dist/app/entry.server.js +12 -10
- package/dist/app/entry.server.js.map +1 -1
- package/dist/app/env.d.ts +33 -0
- package/dist/app/env.js +37 -0
- package/dist/app/env.js.map +1 -0
- package/dist/app/main.d.ts +1 -0
- package/dist/app/main.js +33 -38
- package/dist/app/main.js.map +1 -1
- package/dist/app/standalone.js +7 -6
- package/dist/app/standalone.js.map +1 -1
- package/dist/cli/build/handler.d.ts +1 -3
- package/dist/cli/build/handler.js +9 -1
- package/dist/cli/build/handler.js.map +1 -1
- package/dist/cli/cli.js +17 -1
- package/dist/cli/cli.js.map +1 -1
- package/dist/cli/cmds/build.d.ts +11 -3
- package/dist/cli/cmds/build.js +20 -13
- package/dist/cli/cmds/build.js.map +1 -1
- package/dist/cli/cmds/dev.d.ts +1 -1
- package/dist/cli/cmds/dev.js.map +1 -1
- package/dist/cli/cmds/preview.d.ts +16 -0
- package/dist/cli/cmds/preview.js +25 -0
- package/dist/cli/cmds/preview.js.map +1 -0
- package/dist/cli/common/machine-id/lib.js +1 -0
- package/dist/cli/common/machine-id/lib.js.map +1 -1
- package/dist/cli/common/output.js.map +1 -1
- package/dist/cli/common/utils/ports.d.ts +1 -1
- package/dist/cli/common/utils/ports.js +16 -15
- package/dist/cli/common/utils/ports.js.map +1 -1
- package/dist/cli/dev/handler.js +15 -12
- package/dist/cli/dev/handler.js.map +1 -1
- package/dist/cli/preview/handler.d.ts +3 -0
- package/dist/cli/preview/handler.js +35 -0
- package/dist/cli/preview/handler.js.map +1 -0
- package/dist/config/config.d.ts +27 -14
- package/dist/config/file-exists.d.ts +1 -0
- package/dist/config/file-exists.js +5 -0
- package/dist/config/file-exists.js.map +1 -0
- package/dist/config/loader.d.ts +19 -18
- package/dist/config/loader.js +107 -117
- package/dist/config/loader.js.map +1 -1
- package/dist/config/validators/BuildSchema.d.ts +36 -0
- package/dist/config/validators/BuildSchema.js +20 -0
- package/dist/config/validators/BuildSchema.js.map +1 -0
- package/dist/config/validators/InputNavigationSchema.d.ts +7369 -0
- package/dist/config/validators/InputNavigationSchema.js +74 -0
- package/dist/config/validators/InputNavigationSchema.js.map +1 -0
- package/dist/config/validators/InputNavigationSchema.test-d.js +146 -0
- package/dist/config/validators/InputNavigationSchema.test-d.js.map +1 -0
- package/dist/config/validators/NavigationSchema.d.ts +44 -0
- package/dist/config/validators/NavigationSchema.js +95 -0
- package/dist/config/validators/NavigationSchema.js.map +1 -0
- package/dist/config/validators/icon-types.d.ts +2 -1
- package/dist/config/validators/icon-types.js +1813 -1
- package/dist/config/validators/icon-types.js.map +1 -1
- package/dist/config/validators/validate.d.ts +642 -1875
- package/dist/config/validators/validate.js +423 -15
- package/dist/config/validators/validate.js.map +1 -1
- package/dist/config/validators/validate.test.js +78 -0
- package/dist/config/validators/validate.test.js.map +1 -0
- package/dist/flat-config.d.ts +325 -0
- package/dist/index.d.ts +8 -4
- package/dist/index.js +4 -0
- package/dist/index.js.map +1 -1
- package/dist/lib/MissingIcon.d.ts +2 -0
- package/dist/lib/MissingIcon.js +7 -0
- package/dist/lib/MissingIcon.js.map +1 -0
- package/dist/lib/auth/issuer.d.ts +2 -0
- package/dist/lib/auth/issuer.js +37 -0
- package/dist/lib/auth/issuer.js.map +1 -0
- package/dist/lib/auth/issuer.test.js +94 -0
- package/dist/lib/auth/issuer.test.js.map +1 -0
- package/dist/lib/authentication/AuthenticationPlugin.d.ts +2 -2
- package/dist/lib/authentication/AuthenticationPlugin.js +1 -1
- package/dist/lib/authentication/AuthenticationPlugin.js.map +1 -1
- package/dist/lib/authentication/authentication.d.ts +3 -4
- package/dist/lib/authentication/components/CallbackHandler.js +6 -2
- package/dist/lib/authentication/components/CallbackHandler.js.map +1 -1
- package/dist/lib/authentication/components/SignIn.d.ts +1 -1
- package/dist/lib/authentication/components/SignIn.js +5 -2
- package/dist/lib/authentication/components/SignIn.js.map +1 -1
- package/dist/lib/authentication/components/SignUp.d.ts +1 -1
- package/dist/lib/authentication/components/SignUp.js +4 -1
- package/dist/lib/authentication/components/SignUp.js.map +1 -1
- package/dist/lib/authentication/hook.d.ts +7 -0
- package/dist/lib/authentication/hook.js +11 -1
- package/dist/lib/authentication/hook.js.map +1 -1
- package/dist/lib/authentication/providers/auth0.d.ts +2 -2
- package/dist/lib/authentication/providers/auth0.js +3 -2
- package/dist/lib/authentication/providers/auth0.js.map +1 -1
- package/dist/lib/authentication/providers/azureb2c.d.ts +28 -0
- package/dist/lib/authentication/providers/azureb2c.js +145 -0
- package/dist/lib/authentication/providers/azureb2c.js.map +1 -0
- package/dist/lib/authentication/providers/clerk.d.ts +2 -2
- package/dist/lib/authentication/providers/clerk.js +92 -55
- package/dist/lib/authentication/providers/clerk.js.map +1 -1
- package/dist/lib/authentication/providers/openid.d.ts +16 -19
- package/dist/lib/authentication/providers/openid.js +78 -43
- package/dist/lib/authentication/providers/openid.js.map +1 -1
- package/dist/lib/authentication/providers/supabase.d.ts +4 -0
- package/dist/lib/authentication/providers/supabase.js +108 -0
- package/dist/lib/authentication/providers/supabase.js.map +1 -0
- package/dist/lib/authentication/state.d.ts +6 -22
- package/dist/lib/authentication/state.js +28 -13
- package/dist/lib/authentication/state.js.map +1 -1
- package/dist/lib/components/AnchorLink.d.ts +2 -2
- package/dist/lib/components/AnchorLink.js +5 -4
- package/dist/lib/components/AnchorLink.js.map +1 -1
- package/dist/lib/components/Autocomplete.d.ts +4 -3
- package/dist/lib/components/Autocomplete.js +5 -5
- package/dist/lib/components/Autocomplete.js.map +1 -1
- package/dist/lib/components/Banner.js +2 -2
- package/dist/lib/components/Banner.js.map +1 -1
- package/dist/lib/components/Bootstrap.d.ts +2 -1
- package/dist/lib/components/Bootstrap.js +3 -2
- package/dist/lib/components/Bootstrap.js.map +1 -1
- package/dist/lib/components/BuildCheck.d.ts +4 -0
- package/dist/lib/components/BuildCheck.js +38 -0
- package/dist/lib/components/BuildCheck.js.map +1 -0
- package/dist/lib/components/ErrorPage.js +2 -2
- package/dist/lib/components/ErrorPage.js.map +1 -1
- package/dist/lib/components/Footer.d.ts +1 -0
- package/dist/lib/components/Footer.js +32 -0
- package/dist/lib/components/Footer.js.map +1 -0
- package/dist/lib/components/Framed.d.ts +7 -0
- package/dist/lib/components/Framed.js +26 -0
- package/dist/lib/components/Framed.js.map +1 -0
- package/dist/lib/components/Header.js +25 -16
- package/dist/lib/components/Header.js.map +1 -1
- package/dist/lib/components/Heading.d.ts +9 -5
- package/dist/lib/components/Heading.js +7 -2
- package/dist/lib/components/Heading.js.map +1 -1
- package/dist/lib/components/InlineCode.d.ts +2 -1
- package/dist/lib/components/InlineCode.js +2 -9
- package/dist/lib/components/InlineCode.js.map +1 -1
- package/dist/lib/components/Layout.js +9 -29
- package/dist/lib/components/Layout.js.map +1 -1
- package/dist/lib/components/Main.d.ts +2 -0
- package/dist/lib/components/Main.js +18 -0
- package/dist/lib/components/Main.js.map +1 -0
- package/dist/lib/components/Markdown.d.ts +3 -2
- package/dist/lib/components/Markdown.js +14 -16
- package/dist/lib/components/Markdown.js.map +1 -1
- package/dist/lib/components/MobileTopNavigation.js +8 -3
- package/dist/lib/components/MobileTopNavigation.js.map +1 -1
- package/dist/lib/components/NotFoundPage.js +2 -2
- package/dist/lib/components/NotFoundPage.js.map +1 -1
- package/dist/lib/components/PageProgress.d.ts +1 -0
- package/dist/lib/components/PageProgress.js +20 -0
- package/dist/lib/components/PageProgress.js.map +1 -0
- package/dist/lib/components/Pagination.d.ts +11 -0
- package/dist/lib/components/Pagination.js +10 -0
- package/dist/lib/components/Pagination.js.map +1 -0
- package/dist/lib/components/PathRenderer.js +23 -20
- package/dist/lib/components/PathRenderer.js.map +1 -1
- package/dist/lib/components/Search.js +7 -1
- package/dist/lib/components/Search.js.map +1 -1
- package/dist/lib/components/Slot.d.ts +17 -0
- package/dist/lib/components/Slot.js +24 -0
- package/dist/lib/components/Slot.js.map +1 -0
- package/dist/lib/components/Slot.test.js +168 -0
- package/dist/lib/components/Slot.test.js.map +1 -0
- package/dist/lib/components/ThemeSwitch.js +8 -5
- package/dist/lib/components/ThemeSwitch.js.map +1 -1
- package/dist/lib/components/TopNavigation.d.ts +2 -5
- package/dist/lib/components/TopNavigation.js +48 -41
- package/dist/lib/components/TopNavigation.js.map +1 -1
- package/dist/lib/components/Typography.d.ts +5 -0
- package/dist/lib/components/Typography.js +8 -0
- package/dist/lib/components/Typography.js.map +1 -0
- package/dist/lib/components/Zudoku.d.ts +1 -1
- package/dist/lib/components/Zudoku.js +14 -9
- package/dist/lib/components/Zudoku.js.map +1 -1
- package/dist/lib/components/cache.d.ts +7 -0
- package/dist/lib/components/cache.js +7 -0
- package/dist/lib/components/cache.js.map +1 -1
- package/dist/lib/components/context/BypassProtectedRoutesContext.d.ts +1 -0
- package/dist/lib/components/context/BypassProtectedRoutesContext.js +3 -0
- package/dist/lib/components/context/BypassProtectedRoutesContext.js.map +1 -0
- package/dist/lib/components/context/RouterEventsEmitter.d.ts +1 -0
- package/dist/lib/components/context/RouterEventsEmitter.js +17 -0
- package/dist/lib/components/context/RouterEventsEmitter.js.map +1 -0
- package/dist/lib/components/context/SlotProvider.d.ts +26 -0
- package/dist/lib/components/context/SlotProvider.js +83 -0
- package/dist/lib/components/context/SlotProvider.js.map +1 -0
- package/dist/lib/components/context/ViewportAnchorContext.d.ts +2 -4
- package/dist/lib/components/context/ViewportAnchorContext.js +13 -19
- package/dist/lib/components/context/ViewportAnchorContext.js.map +1 -1
- package/dist/lib/components/context/ZudokuContext.d.ts +4 -8
- package/dist/lib/components/context/ZudokuContext.js +50 -21
- package/dist/lib/components/context/ZudokuContext.js.map +1 -1
- package/dist/lib/components/context/ZudokuProvider.d.ts +1 -1
- package/dist/lib/components/context/ZudokuProvider.js +2 -1
- package/dist/lib/components/context/ZudokuProvider.js.map +1 -1
- package/dist/lib/components/index.d.ts +54 -25
- package/dist/lib/components/index.js +20 -6
- package/dist/lib/components/index.js.map +1 -1
- package/dist/lib/components/navigation/Navigation.d.ts +5 -0
- package/dist/lib/components/navigation/Navigation.js +12 -0
- package/dist/lib/components/navigation/Navigation.js.map +1 -0
- package/dist/lib/components/navigation/NavigationBadge.d.ts +26 -0
- package/dist/lib/components/navigation/NavigationBadge.js +26 -0
- package/dist/lib/components/navigation/NavigationBadge.js.map +1 -0
- package/dist/lib/components/navigation/NavigationCategory.d.ts +5 -0
- package/dist/lib/components/navigation/NavigationCategory.js +61 -0
- package/dist/lib/components/navigation/NavigationCategory.js.map +1 -0
- package/dist/lib/components/navigation/NavigationItem.d.ts +6 -0
- package/dist/lib/components/navigation/NavigationItem.js +47 -0
- package/dist/lib/components/navigation/NavigationItem.js.map +1 -0
- package/dist/lib/components/navigation/NavigationWrapper.d.ts +7 -0
- package/dist/lib/components/navigation/NavigationWrapper.js +21 -0
- package/dist/lib/components/navigation/NavigationWrapper.js.map +1 -0
- package/dist/lib/components/navigation/PoweredByZudoku.d.ts +3 -0
- package/dist/lib/components/navigation/PoweredByZudoku.js +7 -0
- package/dist/lib/components/navigation/PoweredByZudoku.js.map +1 -0
- package/dist/lib/components/navigation/Toc.js +46 -0
- package/dist/lib/components/navigation/Toc.js.map +1 -0
- package/dist/lib/components/navigation/ZudokuLogo.d.ts +6 -0
- package/dist/lib/components/navigation/ZudokuLogo.js +5 -0
- package/dist/lib/components/navigation/ZudokuLogo.js.map +1 -0
- package/dist/lib/components/navigation/ZuploLogo.d.ts +3 -0
- package/dist/lib/components/navigation/ZuploLogo.js +4 -0
- package/dist/lib/components/navigation/ZuploLogo.js.map +1 -0
- package/dist/lib/components/navigation/utils.d.ts +12 -6
- package/dist/lib/components/navigation/utils.js +46 -18
- package/dist/lib/components/navigation/utils.js.map +1 -1
- package/dist/lib/core/RouteGuard.d.ts +2 -1
- package/dist/lib/core/RouteGuard.js +35 -11
- package/dist/lib/core/RouteGuard.js.map +1 -1
- package/dist/lib/core/ZudokuContext.d.ts +58 -21
- package/dist/lib/core/ZudokuContext.js +39 -17
- package/dist/lib/core/ZudokuContext.js.map +1 -1
- package/dist/lib/core/plugins.d.ts +22 -9
- package/dist/lib/core/plugins.js +4 -0
- package/dist/lib/core/plugins.js.map +1 -1
- package/dist/lib/errors/ErrorAlert.js +5 -1
- package/dist/lib/errors/ErrorAlert.js.map +1 -1
- package/dist/lib/hooks/index.d.ts +28 -0
- package/dist/lib/hooks/index.js +16 -0
- package/dist/lib/hooks/index.js.map +1 -0
- package/dist/lib/hooks/useEvent.d.ts +11 -0
- package/dist/lib/hooks/useEvent.js +19 -0
- package/dist/lib/hooks/useEvent.js.map +1 -0
- package/dist/lib/hooks/useEvent.test.js +102 -0
- package/dist/lib/hooks/useEvent.test.js.map +1 -0
- package/dist/lib/hooks/useHotkey.d.ts +4 -0
- package/dist/lib/hooks/useHotkey.js +58 -0
- package/dist/lib/hooks/useHotkey.js.map +1 -0
- package/dist/lib/icons.d.ts +1 -0
- package/dist/lib/icons.js +1 -0
- package/dist/lib/icons.js.map +1 -1
- package/dist/lib/oas/graphql/circular.js +23 -18
- package/dist/lib/oas/graphql/circular.js.map +1 -1
- package/dist/lib/oas/graphql/index.d.ts +24 -4
- package/dist/lib/oas/graphql/index.js +163 -48
- package/dist/lib/oas/graphql/index.js.map +1 -1
- package/dist/lib/oas/parser/dereference/index.js +2 -0
- package/dist/lib/oas/parser/dereference/index.js.map +1 -1
- package/dist/lib/oas/parser/index.d.ts +8 -3
- package/dist/lib/oas/parser/index.js +7 -23
- package/dist/lib/oas/parser/index.js.map +1 -1
- package/dist/lib/oas/parser/upgrade/index.d.ts +1 -0
- package/dist/lib/oas/parser/upgrade/index.js +76 -23
- package/dist/lib/oas/parser/upgrade/index.js.map +1 -1
- package/dist/lib/plugins/api-catalog/Catalog.d.ts +4 -2
- package/dist/lib/plugins/api-catalog/Catalog.js +16 -26
- package/dist/lib/plugins/api-catalog/Catalog.js.map +1 -1
- package/dist/lib/plugins/api-catalog/index.d.ts +7 -6
- package/dist/lib/plugins/api-catalog/index.js +39 -8
- package/dist/lib/plugins/api-catalog/index.js.map +1 -1
- package/dist/lib/plugins/api-keys/CreateApiKey.d.ts +3 -2
- package/dist/lib/plugins/api-keys/CreateApiKey.js +15 -7
- package/dist/lib/plugins/api-keys/CreateApiKey.js.map +1 -1
- package/dist/lib/plugins/api-keys/SettingsApiKeys.d.ts +1 -1
- package/dist/lib/plugins/api-keys/SettingsApiKeys.js +150 -27
- package/dist/lib/plugins/api-keys/SettingsApiKeys.js.map +1 -1
- package/dist/lib/plugins/api-keys/index.d.ts +21 -11
- package/dist/lib/plugins/api-keys/index.js +67 -32
- package/dist/lib/plugins/api-keys/index.js.map +1 -1
- package/dist/lib/plugins/custom-pages/index.d.ts +4 -6
- package/dist/lib/plugins/custom-pages/index.js +15 -10
- package/dist/lib/plugins/custom-pages/index.js.map +1 -1
- package/dist/lib/plugins/markdown/MdxPage.d.ts +2 -3
- package/dist/lib/plugins/markdown/MdxPage.js +30 -17
- package/dist/lib/plugins/markdown/MdxPage.js.map +1 -1
- package/dist/lib/plugins/markdown/index.d.ts +11 -3
- package/dist/lib/plugins/markdown/index.js +9 -26
- package/dist/lib/plugins/markdown/index.js.map +1 -1
- package/dist/lib/plugins/openapi/CollapsibleCode.js +1 -1
- package/dist/lib/plugins/openapi/CollapsibleCode.js.map +1 -1
- package/dist/lib/plugins/openapi/ColorizedParam.js +1 -1
- package/dist/lib/plugins/openapi/ColorizedParam.js.map +1 -1
- package/dist/lib/plugins/openapi/Endpoint.js +6 -7
- package/dist/lib/plugins/openapi/Endpoint.js.map +1 -1
- package/dist/lib/plugins/openapi/OasProvider.d.ts +8 -0
- package/dist/lib/plugins/openapi/OasProvider.js +29 -0
- package/dist/lib/plugins/openapi/OasProvider.js.map +1 -0
- package/dist/lib/plugins/openapi/OperationList.d.ts +1 -1
- package/dist/lib/plugins/openapi/OperationList.js +76 -26
- package/dist/lib/plugins/openapi/OperationList.js.map +1 -1
- package/dist/lib/plugins/openapi/OperationListItem.d.ts +3 -2
- package/dist/lib/plugins/openapi/OperationListItem.js +11 -15
- package/dist/lib/plugins/openapi/OperationListItem.js.map +1 -1
- package/dist/lib/plugins/openapi/ParamInfos.d.ts +6 -0
- package/dist/lib/plugins/openapi/ParamInfos.js +45 -0
- package/dist/lib/plugins/openapi/ParamInfos.js.map +1 -0
- package/dist/lib/plugins/openapi/ParameterList.d.ts +2 -1
- package/dist/lib/plugins/openapi/ParameterList.js +3 -2
- package/dist/lib/plugins/openapi/ParameterList.js.map +1 -1
- package/dist/lib/plugins/openapi/ParameterListItem.js +16 -4
- package/dist/lib/plugins/openapi/ParameterListItem.js.map +1 -1
- package/dist/lib/plugins/openapi/PlaygroundDialogWrapper.d.ts +2 -2
- package/dist/lib/plugins/openapi/PlaygroundDialogWrapper.js +14 -4
- package/dist/lib/plugins/openapi/PlaygroundDialogWrapper.js.map +1 -1
- package/dist/lib/plugins/openapi/ResponsesSidecarBox.d.ts +2 -4
- package/dist/lib/plugins/openapi/ResponsesSidecarBox.js +1 -4
- package/dist/lib/plugins/openapi/ResponsesSidecarBox.js.map +1 -1
- package/dist/lib/plugins/openapi/SchemaList.d.ts +1 -0
- package/dist/lib/plugins/openapi/SchemaList.js +52 -0
- package/dist/lib/plugins/openapi/SchemaList.js.map +1 -0
- package/dist/lib/plugins/openapi/Sidecar.js +48 -69
- package/dist/lib/plugins/openapi/Sidecar.js.map +1 -1
- package/dist/lib/plugins/openapi/SidecarExamples.js +10 -2
- package/dist/lib/plugins/openapi/SidecarExamples.js.map +1 -1
- package/dist/lib/plugins/openapi/SimpleSelect.js +1 -1
- package/dist/lib/plugins/openapi/SimpleSelect.js.map +1 -1
- package/dist/lib/plugins/openapi/client/GraphQLClient.d.ts +1 -1
- package/dist/lib/plugins/openapi/client/GraphQLClient.js +1 -1
- package/dist/lib/plugins/openapi/client/GraphQLClient.js.map +1 -1
- package/dist/lib/plugins/openapi/client/useCreateQuery.d.ts +11 -2
- package/dist/lib/plugins/openapi/client/useCreateQuery.js +14 -7
- package/dist/lib/plugins/openapi/client/useCreateQuery.js.map +1 -1
- package/dist/lib/plugins/openapi/components/ConstValue.d.ts +5 -0
- package/dist/lib/plugins/openapi/components/ConstValue.js +6 -0
- package/dist/lib/plugins/openapi/components/ConstValue.js.map +1 -0
- package/dist/lib/plugins/openapi/components/EnumValues.d.ts +5 -0
- package/dist/lib/plugins/openapi/components/EnumValues.js +15 -0
- package/dist/lib/plugins/openapi/components/EnumValues.js.map +1 -0
- package/dist/lib/plugins/openapi/components/ResponseContent.d.ts +12 -0
- package/dist/lib/plugins/openapi/components/ResponseContent.js +21 -0
- package/dist/lib/plugins/openapi/components/ResponseContent.js.map +1 -0
- package/dist/lib/plugins/openapi/components/SelectOnClick.d.ts +5 -0
- package/dist/lib/plugins/openapi/components/SelectOnClick.js +16 -0
- package/dist/lib/plugins/openapi/components/SelectOnClick.js.map +1 -0
- package/dist/lib/plugins/openapi/graphql/gql.d.ts +9 -5
- package/dist/lib/plugins/openapi/graphql/gql.js +5 -15
- package/dist/lib/plugins/openapi/graphql/gql.js.map +1 -1
- package/dist/lib/plugins/openapi/graphql/graphql.d.ts +110 -41
- package/dist/lib/plugins/openapi/graphql/graphql.js +63 -24
- package/dist/lib/plugins/openapi/graphql/graphql.js.map +1 -1
- package/dist/lib/plugins/openapi/index.d.ts +10 -8
- package/dist/lib/plugins/openapi/index.js +65 -120
- package/dist/lib/plugins/openapi/index.js.map +1 -1
- package/dist/lib/plugins/openapi/interfaces.d.ts +41 -12
- package/dist/lib/plugins/openapi/playground/BodyPanel.d.ts +5 -0
- package/dist/lib/plugins/openapi/playground/BodyPanel.js +26 -0
- package/dist/lib/plugins/openapi/playground/BodyPanel.js.map +1 -0
- package/dist/lib/plugins/openapi/playground/CollapsibleHeader.d.ts +8 -0
- package/dist/lib/plugins/openapi/playground/CollapsibleHeader.js +11 -0
- package/dist/lib/plugins/openapi/playground/CollapsibleHeader.js.map +1 -0
- package/dist/lib/plugins/openapi/playground/ExamplesDropdown.d.ts +2 -2
- package/dist/lib/plugins/openapi/playground/ExamplesDropdown.js +2 -5
- package/dist/lib/plugins/openapi/playground/ExamplesDropdown.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/Headers.d.ts +5 -4
- package/dist/lib/plugins/openapi/playground/Headers.js +68 -30
- package/dist/lib/plugins/openapi/playground/Headers.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/IdentityDialog.d.ts +11 -0
- package/dist/lib/plugins/openapi/playground/IdentityDialog.js +15 -0
- package/dist/lib/plugins/openapi/playground/IdentityDialog.js.map +1 -0
- package/dist/lib/plugins/openapi/playground/IdentitySelector.d.ts +7 -0
- package/dist/lib/plugins/openapi/playground/IdentitySelector.js +7 -0
- package/dist/lib/plugins/openapi/playground/IdentitySelector.js.map +1 -0
- package/dist/lib/plugins/openapi/playground/InlineInput.js +1 -1
- package/dist/lib/plugins/openapi/playground/InlineInput.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/ParamsGrid.d.ts +4 -0
- package/dist/lib/plugins/openapi/playground/ParamsGrid.js +2 -1
- package/dist/lib/plugins/openapi/playground/ParamsGrid.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/PathParams.d.ts +3 -2
- package/dist/lib/plugins/openapi/playground/PathParams.js +5 -5
- package/dist/lib/plugins/openapi/playground/PathParams.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/Playground.d.ts +13 -3
- package/dist/lib/plugins/openapi/playground/Playground.js +150 -76
- package/dist/lib/plugins/openapi/playground/Playground.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/PlaygroundDialog.js +1 -1
- package/dist/lib/plugins/openapi/playground/PlaygroundDialog.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/QueryParams.d.ts +3 -3
- package/dist/lib/plugins/openapi/playground/QueryParams.js +41 -26
- package/dist/lib/plugins/openapi/playground/QueryParams.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/RequestLoginDialog.d.ts +7 -0
- package/dist/lib/plugins/openapi/playground/RequestLoginDialog.js +8 -0
- package/dist/lib/plugins/openapi/playground/RequestLoginDialog.js.map +1 -0
- package/dist/lib/plugins/openapi/playground/Spinner.d.ts +2 -0
- package/dist/lib/plugins/openapi/playground/Spinner.js +63 -0
- package/dist/lib/plugins/openapi/playground/Spinner.js.map +1 -0
- package/dist/lib/plugins/openapi/playground/fileUtils.d.ts +2 -0
- package/dist/lib/plugins/openapi/playground/fileUtils.js +22 -0
- package/dist/lib/plugins/openapi/playground/fileUtils.js.map +1 -0
- package/dist/lib/plugins/openapi/playground/rememberedIdentity.d.ts +17 -0
- package/dist/lib/plugins/openapi/playground/rememberedIdentity.js +11 -0
- package/dist/lib/plugins/openapi/playground/rememberedIdentity.js.map +1 -0
- package/dist/lib/plugins/openapi/playground/request-panel/UrlPath.d.ts +3 -0
- package/dist/lib/plugins/openapi/playground/request-panel/UrlPath.js +13 -0
- package/dist/lib/plugins/openapi/playground/request-panel/UrlPath.js.map +1 -0
- package/dist/lib/plugins/openapi/playground/request-panel/UrlQueryParams.d.ts +1 -0
- package/dist/lib/plugins/openapi/playground/request-panel/UrlQueryParams.js +12 -0
- package/dist/lib/plugins/openapi/playground/request-panel/UrlQueryParams.js.map +1 -0
- package/dist/lib/plugins/openapi/playground/result-panel/Highlight.d.ts +12 -0
- package/dist/lib/plugins/openapi/playground/result-panel/Highlight.js +11 -0
- package/dist/lib/plugins/openapi/playground/result-panel/Highlight.js.map +1 -0
- package/dist/lib/plugins/openapi/playground/result-panel/ResponseStatusBar.d.ts +8 -0
- package/dist/lib/plugins/openapi/playground/result-panel/ResponseStatusBar.js +69 -0
- package/dist/lib/plugins/openapi/playground/result-panel/ResponseStatusBar.js.map +1 -0
- package/dist/lib/plugins/openapi/playground/result-panel/ResponseTab.d.ts +10 -4
- package/dist/lib/plugins/openapi/playground/result-panel/ResponseTab.js +41 -33
- package/dist/lib/plugins/openapi/playground/result-panel/ResponseTab.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/result-panel/ResultPanel.d.ts +9 -5
- package/dist/lib/plugins/openapi/playground/result-panel/ResultPanel.js +9 -10
- package/dist/lib/plugins/openapi/playground/result-panel/ResultPanel.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/useRememberSkipLoginDialog.d.ts +16 -0
- package/dist/lib/plugins/openapi/playground/useRememberSkipLoginDialog.js +10 -0
- package/dist/lib/plugins/openapi/playground/useRememberSkipLoginDialog.js.map +1 -0
- package/dist/lib/plugins/openapi/processors/removeExtensions.d.ts +8 -0
- package/dist/lib/plugins/openapi/processors/removeExtensions.js +16 -0
- package/dist/lib/plugins/openapi/processors/removeExtensions.js.map +1 -0
- package/dist/lib/plugins/openapi/processors/removeExtensions.test.d.ts +1 -0
- package/dist/lib/plugins/openapi/processors/removeExtensions.test.js +194 -0
- package/dist/lib/plugins/openapi/processors/removeExtensions.test.js.map +1 -0
- package/dist/lib/plugins/openapi/processors/removeParameters.d.ts +12 -0
- package/dist/lib/plugins/openapi/processors/removeParameters.js +66 -0
- package/dist/lib/plugins/openapi/processors/removeParameters.js.map +1 -0
- package/dist/lib/plugins/openapi/processors/removeParameters.test.d.ts +1 -0
- package/dist/lib/plugins/openapi/processors/removeParameters.test.js +159 -0
- package/dist/lib/plugins/openapi/processors/removeParameters.test.js.map +1 -0
- package/dist/lib/plugins/openapi/processors/removePaths.d.ts +13 -0
- package/dist/lib/plugins/openapi/processors/removePaths.js +33 -0
- package/dist/lib/plugins/openapi/processors/removePaths.js.map +1 -0
- package/dist/lib/plugins/openapi/processors/removePaths.test.d.ts +1 -0
- package/dist/lib/plugins/openapi/processors/removePaths.test.js +144 -0
- package/dist/lib/plugins/openapi/processors/removePaths.test.js.map +1 -0
- package/dist/lib/plugins/openapi/processors/traverse.js.map +1 -0
- package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroup.d.ts +1 -2
- package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroup.js +2 -2
- package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroup.js.map +1 -1
- package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupConnector.d.ts +2 -1
- package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupConnector.js +2 -2
- package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupConnector.js.map +1 -1
- package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupItem.d.ts +0 -1
- package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupItem.js +1 -1
- package/dist/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupItem.js.map +1 -1
- package/dist/lib/plugins/openapi/schema/SchemaExampleAndDefault.d.ts +4 -0
- package/dist/lib/plugins/openapi/schema/SchemaExampleAndDefault.js +15 -0
- package/dist/lib/plugins/openapi/schema/SchemaExampleAndDefault.js.map +1 -0
- package/dist/lib/plugins/openapi/schema/SchemaPropertyItem.d.ts +2 -4
- package/dist/lib/plugins/openapi/schema/SchemaPropertyItem.js +25 -18
- package/dist/lib/plugins/openapi/schema/SchemaPropertyItem.js.map +1 -1
- package/dist/lib/plugins/openapi/schema/SchemaView.d.ts +2 -2
- package/dist/lib/plugins/openapi/schema/SchemaView.js +39 -51
- package/dist/lib/plugins/openapi/schema/SchemaView.js.map +1 -1
- package/dist/lib/plugins/openapi/schema/utils.d.ts +7 -1
- package/dist/lib/plugins/openapi/schema/utils.js +15 -5
- package/dist/lib/plugins/openapi/schema/utils.js.map +1 -1
- package/dist/lib/plugins/openapi/state.d.ts +25 -0
- package/dist/lib/plugins/openapi/state.js +18 -0
- package/dist/lib/plugins/openapi/state.js.map +1 -0
- package/dist/lib/plugins/openapi/util/createHttpSnippet.d.ts +11 -0
- package/dist/lib/plugins/openapi/util/createHttpSnippet.js +89 -0
- package/dist/lib/plugins/openapi/util/createHttpSnippet.js.map +1 -0
- package/dist/lib/plugins/openapi/util/createNavigationCategory.d.ts +9 -0
- package/dist/lib/plugins/openapi/util/createNavigationCategory.js +24 -0
- package/dist/lib/plugins/openapi/util/createNavigationCategory.js.map +1 -0
- package/dist/lib/plugins/openapi/util/generateSchemaExample.d.ts +1 -1
- package/dist/lib/plugins/openapi/util/generateSchemaExample.js +44 -0
- package/dist/lib/plugins/openapi/util/generateSchemaExample.js.map +1 -1
- package/dist/lib/plugins/openapi/util/getRoutes.d.ts +10 -0
- package/dist/lib/plugins/openapi/util/getRoutes.js +117 -0
- package/dist/lib/plugins/openapi/util/getRoutes.js.map +1 -0
- package/dist/lib/plugins/openapi/util/methodColorMap.d.ts +2 -0
- package/dist/lib/plugins/openapi/util/methodColorMap.js +10 -0
- package/dist/lib/plugins/openapi/util/methodColorMap.js.map +1 -0
- package/dist/lib/plugins/redirect/index.d.ts +1 -1
- package/dist/lib/plugins/search-pagefind/PagefindSearch.d.ts +6 -0
- package/dist/lib/plugins/search-pagefind/PagefindSearch.js +80 -0
- package/dist/lib/plugins/search-pagefind/PagefindSearch.js.map +1 -0
- package/dist/lib/plugins/search-pagefind/ResultList.d.ts +8 -0
- package/dist/lib/plugins/search-pagefind/ResultList.js +32 -0
- package/dist/lib/plugins/search-pagefind/ResultList.js.map +1 -0
- package/dist/lib/plugins/search-pagefind/get-results.d.ts +10 -0
- package/dist/lib/plugins/search-pagefind/get-results.js +42 -0
- package/dist/lib/plugins/search-pagefind/get-results.js.map +1 -0
- package/dist/lib/plugins/search-pagefind/index.d.ts +6 -0
- package/dist/lib/plugins/search-pagefind/index.js +9 -0
- package/dist/lib/plugins/search-pagefind/index.js.map +1 -0
- package/dist/lib/plugins/search-pagefind/types.d.ts +85 -0
- package/dist/lib/plugins/search-pagefind/types.js +2 -0
- package/dist/lib/plugins/search-pagefind/types.js.map +1 -0
- package/dist/lib/shiki.d.ts +31 -0
- package/dist/lib/shiki.js +101 -0
- package/dist/lib/shiki.js.map +1 -0
- package/dist/lib/ui/Alert.d.ts +5 -4
- package/dist/lib/ui/Alert.js +12 -10
- package/dist/lib/ui/Alert.js.map +1 -1
- package/dist/lib/ui/Badge.d.ts +2 -2
- package/dist/lib/ui/Badge.js +1 -1
- package/dist/lib/ui/Badge.js.map +1 -1
- package/dist/lib/ui/Button.d.ts +3 -3
- package/dist/lib/ui/Button.js +9 -6
- package/dist/lib/ui/Button.js.map +1 -1
- package/dist/lib/ui/Callout.d.ts +2 -1
- package/dist/lib/ui/Callout.js +3 -2
- package/dist/lib/ui/Callout.js.map +1 -1
- package/dist/lib/ui/Card.js +1 -1
- package/dist/lib/ui/Checkbox.d.ts +2 -8
- package/dist/lib/ui/Checkbox.js +1 -13
- package/dist/lib/ui/Checkbox.js.map +1 -1
- package/dist/lib/ui/CodeBlock.d.ts +15 -0
- package/dist/lib/ui/CodeBlock.js +17 -0
- package/dist/lib/ui/CodeBlock.js.map +1 -0
- package/dist/lib/ui/Command.d.ts +8 -2
- package/dist/lib/ui/Command.js +5 -5
- package/dist/lib/ui/Command.js.map +1 -1
- package/dist/lib/ui/Dialog.d.ts +3 -1
- package/dist/lib/ui/Dialog.js +2 -2
- package/dist/lib/ui/Dialog.js.map +1 -1
- package/dist/lib/ui/DropdownMenu.js +4 -4
- package/dist/lib/ui/DropdownMenu.js.map +1 -1
- package/dist/lib/ui/EmbeddedCodeBlock.d.ts +15 -0
- package/dist/lib/ui/EmbeddedCodeBlock.js +18 -0
- package/dist/lib/ui/EmbeddedCodeBlock.js.map +1 -0
- package/dist/lib/ui/Form.d.ts +1 -1
- package/dist/lib/ui/HoverCard.js +1 -1
- package/dist/lib/ui/HoverCard.js.map +1 -1
- package/dist/lib/ui/Input.d.ts +1 -2
- package/dist/lib/ui/Input.js +1 -1
- package/dist/lib/ui/Input.js.map +1 -1
- package/dist/lib/ui/Popover.js +1 -1
- package/dist/lib/ui/Popover.js.map +1 -1
- package/dist/lib/ui/RadioGroup.js +1 -1
- package/dist/lib/ui/RadioGroup.js.map +1 -1
- package/dist/lib/ui/Select.js +2 -2
- package/dist/lib/ui/Select.js.map +1 -1
- package/dist/lib/ui/Slider.js +1 -1
- package/dist/lib/ui/Slider.js.map +1 -1
- package/dist/lib/ui/Stepper.d.ts +3 -0
- package/dist/lib/ui/Stepper.js +7 -0
- package/dist/lib/ui/Stepper.js.map +1 -0
- package/dist/lib/ui/Switch.js +1 -1
- package/dist/lib/ui/Switch.js.map +1 -1
- package/dist/lib/ui/SyntaxHighlight.d.ts +12 -0
- package/dist/lib/ui/SyntaxHighlight.js +15 -0
- package/dist/lib/ui/SyntaxHighlight.js.map +1 -0
- package/dist/lib/ui/Tabs.js +2 -2
- package/dist/lib/ui/Tabs.js.map +1 -1
- package/dist/lib/ui/Textarea.js +1 -1
- package/dist/lib/ui/Textarea.js.map +1 -1
- package/dist/lib/ui/Toggle.js +1 -1
- package/dist/lib/ui/Toggle.js.map +1 -1
- package/dist/lib/ui/Tooltip.d.ts +2 -1
- package/dist/lib/ui/Tooltip.js +2 -1
- package/dist/lib/ui/Tooltip.js.map +1 -1
- package/dist/lib/ui/util.d.ts +2 -0
- package/dist/lib/ui/util.js +3 -0
- package/dist/lib/ui/util.js.map +1 -0
- package/dist/lib/util/MdxComponents.d.ts +22 -4
- package/dist/lib/util/MdxComponents.js +21 -15
- package/dist/lib/util/MdxComponents.js.map +1 -1
- package/dist/lib/util/detectOS.d.ts +1 -0
- package/dist/lib/util/detectOS.js +11 -0
- package/dist/lib/util/detectOS.js.map +1 -0
- package/dist/lib/util/ensureArray.d.ts +1 -0
- package/dist/lib/util/ensureArray.js +2 -0
- package/dist/lib/util/ensureArray.js.map +1 -0
- package/dist/lib/util/humanFileSize.d.ts +6 -0
- package/dist/lib/util/humanFileSize.js +14 -0
- package/dist/lib/util/humanFileSize.js.map +1 -0
- package/dist/lib/util/humanFileSize.test.d.ts +1 -0
- package/dist/lib/util/humanFileSize.test.js +22 -0
- package/dist/lib/util/humanFileSize.test.js.map +1 -0
- package/dist/lib/util/joinPath.d.ts +3 -0
- package/dist/lib/util/joinPath.js +3 -0
- package/dist/lib/util/joinPath.js.map +1 -1
- package/dist/lib/util/os.d.ts +2 -0
- package/dist/lib/util/os.js +21 -0
- package/dist/lib/util/os.js.map +1 -0
- package/dist/lib/util/scrollIntoViewIfNeeded.d.ts +1 -0
- package/dist/lib/util/scrollIntoViewIfNeeded.js +14 -0
- package/dist/lib/util/scrollIntoViewIfNeeded.js.map +1 -0
- package/dist/lib/util/traverse.d.ts +3 -9
- package/dist/lib/util/traverse.js +7 -6
- package/dist/lib/util/traverse.js.map +1 -1
- package/dist/lib/util/types.d.ts +7 -0
- package/dist/lib/util/types.js +2 -0
- package/dist/lib/util/types.js.map +1 -0
- package/dist/lib/util/url.d.ts +4 -0
- package/dist/lib/util/url.js +13 -0
- package/dist/lib/util/url.js.map +1 -0
- package/dist/lib/util/url.test.d.ts +1 -0
- package/dist/lib/util/url.test.js +26 -0
- package/dist/lib/util/url.test.js.map +1 -0
- package/dist/lib/util/useCopyToClipboard.d.ts +1 -0
- package/dist/lib/util/useCopyToClipboard.js +11 -0
- package/dist/lib/util/useCopyToClipboard.js.map +1 -0
- package/dist/lib/util/useExposedProps.d.ts +8 -1
- package/dist/lib/util/useExposedProps.js.map +1 -1
- package/dist/lib/util/useLatest.d.ts +1 -0
- package/dist/lib/util/useLatest.js +15 -0
- package/dist/lib/util/useLatest.js.map +1 -0
- package/dist/lib/util/useOnScreen.d.ts +3 -2
- package/dist/lib/util/useOnScreen.js +3 -3
- package/dist/lib/util/useOnScreen.js.map +1 -1
- package/dist/lib/util/useScrollToAnchor.js +28 -34
- package/dist/lib/util/useScrollToAnchor.js.map +1 -1
- package/dist/lib/util/useScrollToTop.js +6 -4
- package/dist/lib/util/useScrollToTop.js.map +1 -1
- package/dist/vite/api/SchemaManager.d.ts +36 -0
- package/dist/vite/api/SchemaManager.js +141 -0
- package/dist/vite/api/SchemaManager.js.map +1 -0
- package/dist/vite/api/SchemaManager.test.d.ts +1 -0
- package/dist/vite/api/SchemaManager.test.js +106 -0
- package/dist/vite/api/SchemaManager.test.js.map +1 -0
- package/dist/vite/api/schema-codegen.d.ts +1 -1
- package/dist/vite/api/schema-codegen.js +73 -19
- package/dist/vite/api/schema-codegen.js.map +1 -1
- package/dist/vite/api/schema-codegen.test.js +148 -0
- package/dist/vite/api/schema-codegen.test.js.map +1 -1
- package/dist/vite/build.js +42 -22
- package/dist/vite/build.js.map +1 -1
- package/dist/vite/config.d.ts +2 -12
- package/dist/vite/config.js +101 -150
- package/dist/vite/config.js.map +1 -1
- package/dist/vite/config.test.js +2 -2
- package/dist/vite/config.test.js.map +1 -1
- package/dist/vite/create-pagefind-index.d.ts +4 -0
- package/dist/vite/create-pagefind-index.js +12 -0
- package/dist/vite/create-pagefind-index.js.map +1 -0
- package/dist/vite/css/plugin.d.ts +1 -2
- package/dist/vite/css/plugin.js +14 -2
- package/dist/vite/css/plugin.js.map +1 -1
- package/dist/vite/dev-server.d.ts +4 -3
- package/dist/vite/dev-server.js +53 -22
- package/dist/vite/dev-server.js.map +1 -1
- package/dist/vite/error-handler.d.ts +1 -1
- package/dist/vite/error-handler.js +1 -1
- package/dist/vite/error-handler.js.map +1 -1
- package/dist/vite/html.d.ts +7 -3
- package/dist/vite/html.js +15 -9
- package/dist/vite/html.js.map +1 -1
- package/dist/vite/mdx/remark-last-modified.d.ts +3 -0
- package/dist/vite/mdx/remark-last-modified.js +56 -0
- package/dist/vite/mdx/remark-last-modified.js.map +1 -0
- package/dist/vite/mdx/utils.d.ts +2 -0
- package/dist/vite/mdx/utils.js +31 -0
- package/dist/vite/mdx/utils.js.map +1 -0
- package/dist/vite/output.d.ts +14 -2
- package/dist/vite/output.js +12 -14
- package/dist/vite/output.js.map +1 -1
- package/dist/vite/plugin-api-keys.d.ts +1 -2
- package/dist/vite/plugin-api-keys.js +13 -7
- package/dist/vite/plugin-api-keys.js.map +1 -1
- package/dist/vite/plugin-api.d.ts +1 -2
- package/dist/vite/plugin-api.js +136 -162
- package/dist/vite/plugin-api.js.map +1 -1
- package/dist/vite/plugin-auth.d.ts +1 -2
- package/dist/vite/plugin-auth.js +6 -5
- package/dist/vite/plugin-auth.js.map +1 -1
- package/dist/vite/plugin-component.d.ts +1 -2
- package/dist/vite/plugin-component.js +10 -4
- package/dist/vite/plugin-component.js.map +1 -1
- package/dist/vite/plugin-config-reload.d.ts +3 -3
- package/dist/vite/plugin-config-reload.js +31 -23
- package/dist/vite/plugin-config-reload.js.map +1 -1
- package/dist/vite/plugin-config.d.ts +1 -2
- package/dist/vite/plugin-config.js +11 -6
- package/dist/vite/plugin-config.js.map +1 -1
- package/dist/vite/plugin-custom-pages.d.ts +1 -2
- package/dist/vite/plugin-custom-pages.js +7 -6
- package/dist/vite/plugin-custom-pages.js.map +1 -1
- package/dist/vite/plugin-docs.d.ts +2 -3
- package/dist/vite/plugin-docs.js +66 -46
- package/dist/vite/plugin-docs.js.map +1 -1
- package/dist/vite/plugin-frontmatter.d.ts +1 -2
- package/dist/vite/plugin-frontmatter.js +13 -7
- package/dist/vite/plugin-frontmatter.js.map +1 -1
- package/dist/vite/plugin-mdx.d.ts +1 -2
- package/dist/vite/plugin-mdx.js +49 -64
- package/dist/vite/plugin-mdx.js.map +1 -1
- package/dist/vite/plugin-navigation.d.ts +4 -0
- package/dist/vite/plugin-navigation.js +64 -0
- package/dist/vite/plugin-navigation.js.map +1 -0
- package/dist/vite/plugin-redirect.d.ts +1 -2
- package/dist/vite/plugin-redirect.js +6 -5
- package/dist/vite/plugin-redirect.js.map +1 -1
- package/dist/vite/plugin-search.d.ts +1 -2
- package/dist/vite/plugin-search.js +8 -3
- package/dist/vite/plugin-search.js.map +1 -1
- package/dist/vite/plugin-shiki-register.d.ts +2 -0
- package/dist/vite/plugin-shiki-register.js +39 -0
- package/dist/vite/plugin-shiki-register.js.map +1 -0
- package/dist/vite/plugin-theme.d.ts +8 -0
- package/dist/vite/plugin-theme.js +235 -0
- package/dist/vite/plugin-theme.js.map +1 -0
- package/dist/vite/plugin-theme.test.d.ts +1 -0
- package/dist/vite/plugin-theme.test.js +291 -0
- package/dist/vite/plugin-theme.test.js.map +1 -0
- package/dist/vite/plugin.d.ts +1 -2
- package/dist/vite/plugin.js +23 -22
- package/dist/vite/plugin.js.map +1 -1
- package/dist/vite/prerender/FileWritingResponse.d.ts +25 -0
- package/dist/vite/prerender/FileWritingResponse.js +51 -0
- package/dist/vite/prerender/FileWritingResponse.js.map +1 -0
- package/dist/vite/prerender/InMemoryResponse.d.ts +16 -0
- package/dist/vite/prerender/InMemoryResponse.js +32 -0
- package/dist/vite/prerender/InMemoryResponse.js.map +1 -0
- package/dist/vite/prerender/PrerenderResponse.d.ts +10 -0
- package/dist/vite/prerender/PrerenderResponse.js +2 -0
- package/dist/vite/prerender/PrerenderResponse.js.map +1 -0
- package/dist/vite/prerender/prerender.d.ts +15 -0
- package/dist/vite/prerender/prerender.js +109 -0
- package/dist/vite/prerender/prerender.js.map +1 -0
- package/dist/vite/prerender/worker.d.ts +13 -0
- package/dist/vite/prerender/worker.js +59 -0
- package/dist/vite/prerender/worker.js.map +1 -0
- package/dist/vite/reporter.d.ts +3 -0
- package/dist/vite/reporter.js +33 -0
- package/dist/vite/reporter.js.map +1 -0
- package/dist/vite/shadcn-registry.d.ts +45 -0
- package/dist/vite/shadcn-registry.js +29 -0
- package/dist/vite/shadcn-registry.js.map +1 -0
- package/dist/vite/sitemap.d.ts +1 -1
- package/dist/vite/sitemap.js +2 -1
- package/dist/vite/sitemap.js.map +1 -1
- package/dist/zuplo/enrich-with-zuplo.d.ts +3 -3
- package/dist/zuplo/enrich-with-zuplo.js +18 -17
- package/dist/zuplo/enrich-with-zuplo.js.map +1 -1
- package/dist/zuplo/with-zuplo-processors.d.ts +2 -2
- package/dist/zuplo/with-zuplo-processors.js +7 -7
- package/dist/zuplo/with-zuplo-processors.js.map +1 -1
- package/dist/zuplo/with-zuplo.d.ts +5 -2
- package/dist/zuplo/with-zuplo.js +6 -5
- package/dist/zuplo/with-zuplo.js.map +1 -1
- package/lib/Alert-CT_ViLrJ.js +161 -0
- package/lib/Alert-CT_ViLrJ.js.map +1 -0
- package/lib/Button-BE9IVkWV.js +51 -0
- package/lib/Button-BE9IVkWV.js.map +1 -0
- package/lib/Card-DPhGbYUM.js +61 -0
- package/lib/Card-DPhGbYUM.js.map +1 -0
- package/lib/CodeBlock-DAKxs_Tu.js +85 -0
- package/lib/CodeBlock-DAKxs_Tu.js.map +1 -0
- package/lib/Command-xsbs2uhf.js +140 -0
- package/lib/Command-xsbs2uhf.js.map +1 -0
- package/lib/Dialog-CiIdyz6a.js +99 -0
- package/lib/Dialog-CiIdyz6a.js.map +1 -0
- package/lib/Drawer-BzkOKwgC.js +1133 -0
- package/lib/Drawer-BzkOKwgC.js.map +1 -0
- package/lib/MdxPage-swXPJ0gf.js +110 -0
- package/lib/MdxPage-swXPJ0gf.js.map +1 -0
- package/lib/OasProvider-CDAM3TB1.js +35 -0
- package/lib/OasProvider-CDAM3TB1.js.map +1 -0
- package/lib/OperationList-C9Hb9ql8.js +5166 -0
- package/lib/OperationList-C9Hb9ql8.js.map +1 -0
- package/lib/Pagination-VGlgeCmS.js +36 -0
- package/lib/Pagination-VGlgeCmS.js.map +1 -0
- package/lib/RouteGuard-CbKd7_9h.js +737 -0
- package/lib/RouteGuard-CbKd7_9h.js.map +1 -0
- package/lib/SchemaList-BAbh1BXO.js +149 -0
- package/lib/SchemaList-BAbh1BXO.js.map +1 -0
- package/lib/SchemaView-C2Io712T.js +366 -0
- package/lib/SchemaView-C2Io712T.js.map +1 -0
- package/lib/SignUp-5RUdVhnq.js +63 -0
- package/lib/SignUp-5RUdVhnq.js.map +1 -0
- package/lib/Slot-DwZlQ-vX.js +15735 -0
- package/lib/Slot-DwZlQ-vX.js.map +1 -0
- package/lib/Spinner-mNLZ6awP.js +7 -0
- package/lib/Spinner-mNLZ6awP.js.map +1 -0
- package/lib/SyntaxHighlight-CrjhGEwT.js +10306 -0
- package/lib/SyntaxHighlight-CrjhGEwT.js.map +1 -0
- package/lib/Toc-WCmwFkX-.js +92 -0
- package/lib/Toc-WCmwFkX-.js.map +1 -0
- package/lib/chunk-DQRVZFIR-DHK7_Ilc.js +1839 -0
- package/lib/chunk-DQRVZFIR-DHK7_Ilc.js.map +1 -0
- package/lib/circular-B42RaanD.js +14934 -0
- package/lib/circular-B42RaanD.js.map +1 -0
- package/lib/clerk-BDZ31hjU.js +25190 -0
- package/lib/clerk-BDZ31hjU.js.map +1 -0
- package/lib/clsx-OuTLNxxd.js +17 -0
- package/lib/clsx-OuTLNxxd.js.map +1 -0
- package/lib/cn-wvCW-ho6.js +2731 -0
- package/lib/cn-wvCW-ho6.js.map +1 -0
- package/lib/createServer-BKFsRuuk.js +12659 -0
- package/lib/createServer-BKFsRuuk.js.map +1 -0
- package/lib/errors-CF2X_x5o.js +78 -0
- package/lib/errors-CF2X_x5o.js.map +1 -0
- package/lib/hook-Bd0yS8M0.js +1503 -0
- package/lib/hook-Bd0yS8M0.js.map +1 -0
- package/lib/index-B6Re5_cx.js +3469 -0
- package/lib/index-B6Re5_cx.js.map +1 -0
- package/lib/index-CLy1XyH0.js +3919 -0
- package/lib/index-CLy1XyH0.js.map +1 -0
- package/lib/index-CcV90rin.js +2094 -0
- package/lib/index-CcV90rin.js.map +1 -0
- package/lib/index-ClhS5TxS.js +107 -0
- package/lib/index-ClhS5TxS.js.map +1 -0
- package/lib/index-CrcNWbel.js +316 -0
- package/lib/index-CrcNWbel.js.map +1 -0
- package/lib/index-DI5SPFK9.js +36 -0
- package/lib/index-DI5SPFK9.js.map +1 -0
- package/lib/index-DmNq2fbN.js +4827 -0
- package/lib/index-DmNq2fbN.js.map +1 -0
- package/lib/index.esm-Cp4wkyud.js +1236 -0
- package/lib/index.esm-Cp4wkyud.js.map +1 -0
- package/lib/invariant-DAFpPywt.js +48 -0
- package/lib/invariant-DAFpPywt.js.map +1 -0
- package/lib/jsx-runtime-C5mzlN2N.js +285 -0
- package/lib/jsx-runtime-C5mzlN2N.js.map +1 -0
- package/lib/processors/removeExtensions.js +11 -0
- package/lib/processors/removeExtensions.js.map +1 -0
- package/lib/processors/removeParameters.js +47 -0
- package/lib/processors/removeParameters.js.map +1 -0
- package/lib/processors/removePaths.js +28 -0
- package/lib/processors/removePaths.js.map +1 -0
- package/lib/processors/traverse.js +17 -0
- package/lib/processors/traverse.js.map +1 -0
- package/lib/ui/Accordion.js +2 -2
- package/lib/ui/ActionButton.js +11 -10
- package/lib/ui/ActionButton.js.map +1 -1
- package/lib/ui/Alert.js +55 -39
- package/lib/ui/Alert.js.map +1 -1
- package/lib/ui/AlertDialog.js +2 -2
- package/lib/ui/Badge.js +4 -4
- package/lib/ui/Badge.js.map +1 -1
- package/lib/ui/Breadcrumb.js +5 -5
- package/lib/ui/Button.js +22 -19
- package/lib/ui/Button.js.map +1 -1
- package/lib/ui/Callout.js +40 -20
- package/lib/ui/Callout.js.map +1 -1
- package/lib/ui/Card.js +9 -9
- package/lib/ui/Card.js.map +1 -1
- package/lib/ui/Carousel.js +348 -348
- package/lib/ui/Carousel.js.map +1 -1
- package/lib/ui/Checkbox.js +16 -26
- package/lib/ui/Checkbox.js.map +1 -1
- package/lib/ui/CodeBlock.js +9 -0
- package/lib/ui/CodeBlock.js.map +1 -0
- package/lib/ui/Command.js +102 -75
- package/lib/ui/Command.js.map +1 -1
- package/lib/ui/Dialog.js +41 -41
- package/lib/ui/Dialog.js.map +1 -1
- package/lib/ui/Drawer.js +14 -1151
- package/lib/ui/Drawer.js.map +1 -1
- package/lib/ui/DropdownMenu.js +35 -35
- package/lib/ui/DropdownMenu.js.map +1 -1
- package/lib/ui/EmbeddedCodeBlock.js +80 -0
- package/lib/ui/EmbeddedCodeBlock.js.map +1 -0
- package/lib/ui/Form.js +6 -6
- package/lib/ui/HoverCard.js +6 -6
- package/lib/ui/HoverCard.js.map +1 -1
- package/lib/ui/Input.js +3 -3
- package/lib/ui/Input.js.map +1 -1
- package/lib/ui/Label.js +3 -3
- package/lib/ui/Pagination.js +11 -11
- package/lib/ui/Popover.js +3 -3
- package/lib/ui/Popover.js.map +1 -1
- package/lib/ui/Progress.js +2 -2
- package/lib/ui/RadioGroup.js +11 -11
- package/lib/ui/RadioGroup.js.map +1 -1
- package/lib/ui/ScrollArea.js +2 -2
- package/lib/ui/Select.js +32 -32
- package/lib/ui/Select.js.map +1 -1
- package/lib/ui/Skeleton.js +2 -2
- package/lib/ui/Slider.js +6 -6
- package/lib/ui/Slider.js.map +1 -1
- package/lib/ui/Stepper.js +6 -0
- package/lib/ui/Stepper.js.map +1 -0
- package/lib/ui/Switch.js +6 -6
- package/lib/ui/Switch.js.map +1 -1
- package/lib/ui/SyntaxHighlight.js +11 -0
- package/lib/ui/SyntaxHighlight.js.map +1 -0
- package/lib/ui/Tabs.js +17 -17
- package/lib/ui/Tabs.js.map +1 -1
- package/lib/ui/Textarea.js +6 -6
- package/lib/ui/Textarea.js.map +1 -1
- package/lib/ui/Toggle.js +8 -8
- package/lib/ui/Toggle.js.map +1 -1
- package/lib/ui/ToggleGroup.js +2 -2
- package/lib/ui/Tooltip.js +15 -8
- package/lib/ui/Tooltip.js.map +1 -1
- package/lib/ui/util.js +6 -0
- package/lib/ui/util.js.map +1 -0
- package/lib/useExposedProps-BIYjecPD.js +9 -0
- package/lib/useExposedProps-BIYjecPD.js.map +1 -0
- package/lib/zudoku.auth-auth0.js +34 -36
- package/lib/zudoku.auth-auth0.js.map +1 -1
- package/lib/zudoku.auth-azureb2c.js +9974 -0
- package/lib/zudoku.auth-azureb2c.js.map +1 -0
- package/lib/zudoku.auth-clerk.js +104 -84
- package/lib/zudoku.auth-clerk.js.map +1 -1
- package/lib/zudoku.auth-openid.js +503 -543
- package/lib/zudoku.auth-openid.js.map +1 -1
- package/lib/zudoku.components.js +33 -1215
- package/lib/zudoku.components.js.map +1 -1
- package/lib/zudoku.hooks.js +27 -0
- package/lib/zudoku.hooks.js.map +1 -0
- package/lib/zudoku.icons.js +10 -0
- package/lib/zudoku.icons.js.map +1 -1
- package/lib/zudoku.plugin-api-catalog.js +108 -114
- package/lib/zudoku.plugin-api-catalog.js.map +1 -1
- package/lib/zudoku.plugin-api-keys.js +542 -205
- package/lib/zudoku.plugin-api-keys.js.map +1 -1
- package/lib/zudoku.plugin-custom-pages.js +12 -18
- package/lib/zudoku.plugin-custom-pages.js.map +1 -1
- package/lib/zudoku.plugin-markdown.js +20 -94
- package/lib/zudoku.plugin-markdown.js.map +1 -1
- package/lib/zudoku.plugin-openapi.js +7 -7
- package/lib/zudoku.plugin-openapi.js.map +1 -1
- package/lib/zudoku.plugin-redirect.js +1 -1
- package/lib/zudoku.plugin-redirect.js.map +1 -1
- package/lib/zudoku.plugin-search-inkeep.js +25 -26
- package/lib/zudoku.plugin-search-inkeep.js.map +1 -1
- package/lib/zudoku.plugin-search-pagefind.js +320 -0
- package/lib/zudoku.plugin-search-pagefind.js.map +1 -0
- package/lib/zudoku.plugins.js +15 -0
- package/lib/zudoku.plugins.js.map +1 -0
- package/package.json +148 -90
- package/src/app/ZuploBuildConfig.ts +33 -0
- package/src/app/defaultTheme.css +73 -0
- package/src/app/demo-cdn.html +31 -31
- package/src/app/demo.html +1 -1
- package/src/app/demo.tsx +6 -5
- package/src/app/entry.client.tsx +51 -2
- package/src/app/entry.server.tsx +23 -15
- package/src/app/env.ts +43 -0
- package/src/app/font.geist.css +73 -0
- package/src/app/main.css +156 -143
- package/src/app/main.tsx +49 -41
- package/src/app/standalone.tsx +7 -6
- package/src/lib/MissingIcon.tsx +22 -0
- package/src/lib/auth/issuer.test.ts +120 -0
- package/src/lib/auth/issuer.ts +41 -0
- package/src/lib/authentication/AuthenticationPlugin.tsx +4 -4
- package/src/lib/authentication/authentication.ts +4 -5
- package/src/lib/authentication/components/CallbackHandler.tsx +12 -2
- package/src/lib/authentication/components/SignIn.tsx +35 -2
- package/src/lib/authentication/components/SignUp.tsx +35 -1
- package/src/lib/authentication/hook.ts +12 -1
- package/src/lib/authentication/providers/auth0.tsx +12 -5
- package/src/lib/authentication/providers/azureb2c.tsx +196 -0
- package/src/lib/authentication/providers/clerk.tsx +105 -62
- package/src/lib/authentication/providers/openid.tsx +112 -57
- package/src/lib/authentication/providers/supabase.tsx +150 -0
- package/src/lib/authentication/state.ts +46 -26
- package/src/lib/components/AnchorLink.tsx +9 -7
- package/src/lib/components/Autocomplete.tsx +9 -6
- package/src/lib/components/Banner.tsx +4 -3
- package/src/lib/components/Bootstrap.tsx +13 -6
- package/src/lib/components/BuildCheck.tsx +75 -0
- package/src/lib/components/ErrorPage.tsx +3 -3
- package/src/lib/components/Footer.tsx +136 -0
- package/src/lib/components/Framed.tsx +51 -0
- package/src/lib/components/Header.tsx +47 -43
- package/src/lib/components/Heading.tsx +18 -10
- package/src/lib/components/InlineCode.tsx +13 -16
- package/src/lib/components/Layout.tsx +30 -71
- package/src/lib/components/Main.tsx +51 -0
- package/src/lib/components/Markdown.tsx +40 -27
- package/src/lib/components/MobileTopNavigation.tsx +35 -20
- package/src/lib/components/NotFoundPage.tsx +3 -3
- package/src/lib/components/PageProgress.tsx +28 -0
- package/src/lib/components/Pagination.tsx +44 -0
- package/src/lib/components/PathRenderer.tsx +6 -4
- package/src/lib/components/Search.tsx +15 -4
- package/src/lib/components/Slot.test.tsx +465 -0
- package/src/lib/components/Slot.tsx +64 -0
- package/src/lib/components/ThemeSwitch.tsx +28 -8
- package/src/lib/components/TopNavigation.tsx +71 -65
- package/src/lib/components/Typography.tsx +14 -0
- package/src/lib/components/Zudoku.tsx +27 -16
- package/src/lib/components/cache.ts +8 -0
- package/src/lib/components/context/BypassProtectedRoutesContext.ts +3 -0
- package/src/lib/components/context/RouterEventsEmitter.tsx +19 -0
- package/src/lib/components/context/SlotProvider.tsx +149 -0
- package/src/lib/components/context/ViewportAnchorContext.tsx +14 -30
- package/src/lib/components/context/ZudokuContext.ts +62 -25
- package/src/lib/components/context/ZudokuProvider.tsx +3 -2
- package/src/lib/components/index.ts +21 -9
- package/src/lib/components/navigation/Navigation.tsx +50 -0
- package/src/lib/components/navigation/NavigationBadge.tsx +48 -0
- package/src/lib/components/navigation/NavigationCategory.tsx +146 -0
- package/src/lib/components/navigation/NavigationItem.tsx +151 -0
- package/src/lib/components/navigation/NavigationWrapper.tsx +46 -0
- package/src/lib/components/navigation/PoweredByZudoku.tsx +33 -0
- package/src/lib/components/navigation/Toc.tsx +126 -0
- package/src/lib/components/navigation/ZudokuLogo.tsx +25 -0
- package/src/lib/components/navigation/ZuploLogo.tsx +14 -0
- package/src/lib/components/navigation/utils.ts +63 -28
- package/src/lib/core/RouteGuard.tsx +73 -12
- package/src/lib/core/ZudokuContext.ts +94 -31
- package/src/lib/core/plugins.ts +39 -9
- package/src/lib/errors/ErrorAlert.tsx +19 -18
- package/src/lib/hooks/index.ts +16 -0
- package/src/lib/hooks/useEvent.test.tsx +151 -0
- package/src/lib/hooks/useEvent.ts +41 -0
- package/src/lib/hooks/useHotkey.ts +70 -0
- package/src/lib/icons.ts +1 -0
- package/src/lib/oas/graphql/circular.ts +27 -19
- package/src/lib/oas/graphql/index.ts +223 -73
- package/src/lib/oas/parser/dereference/index.ts +2 -0
- package/src/lib/oas/parser/index.ts +14 -30
- package/src/lib/oas/parser/upgrade/index.ts +97 -26
- package/src/lib/plugins/api-catalog/Catalog.tsx +50 -100
- package/src/lib/plugins/api-catalog/index.tsx +72 -21
- package/src/lib/plugins/api-keys/CreateApiKey.tsx +61 -45
- package/src/lib/plugins/api-keys/SettingsApiKeys.tsx +459 -115
- package/src/lib/plugins/api-keys/index.tsx +134 -58
- package/src/lib/plugins/custom-pages/index.tsx +21 -16
- package/src/lib/plugins/markdown/MdxPage.tsx +84 -62
- package/src/lib/plugins/markdown/index.tsx +29 -42
- package/src/lib/plugins/openapi/CollapsibleCode.tsx +8 -5
- package/src/lib/plugins/openapi/ColorizedParam.tsx +3 -3
- package/src/lib/plugins/openapi/Endpoint.tsx +11 -9
- package/src/lib/plugins/openapi/OasProvider.tsx +51 -0
- package/src/lib/plugins/openapi/OperationList.tsx +189 -91
- package/src/lib/plugins/openapi/OperationListItem.tsx +106 -111
- package/src/lib/plugins/openapi/ParamInfos.tsx +90 -0
- package/src/lib/plugins/openapi/ParameterList.tsx +4 -0
- package/src/lib/plugins/openapi/ParameterListItem.tsx +71 -23
- package/src/lib/plugins/openapi/PlaygroundDialogWrapper.tsx +23 -5
- package/src/lib/plugins/openapi/ResponsesSidecarBox.tsx +5 -16
- package/src/lib/plugins/openapi/SchemaList.tsx +157 -0
- package/src/lib/plugins/openapi/Sidecar.tsx +63 -79
- package/src/lib/plugins/openapi/SidecarExamples.tsx +10 -4
- package/src/lib/plugins/openapi/SimpleSelect.tsx +1 -1
- package/src/lib/plugins/openapi/client/GraphQLClient.tsx +1 -1
- package/src/lib/plugins/openapi/client/useCreateQuery.ts +34 -7
- package/src/lib/plugins/openapi/components/ConstValue.tsx +24 -0
- package/src/lib/plugins/openapi/components/EnumValues.tsx +58 -0
- package/src/lib/plugins/openapi/components/ResponseContent.tsx +104 -0
- package/src/lib/plugins/openapi/components/SelectOnClick.tsx +29 -0
- package/src/lib/plugins/openapi/graphql/gql.ts +34 -17
- package/src/lib/plugins/openapi/graphql/graphql.ts +175 -65
- package/src/lib/plugins/openapi/index.tsx +92 -153
- package/src/lib/plugins/openapi/interfaces.ts +50 -25
- package/src/lib/plugins/openapi/playground/BodyPanel.tsx +55 -0
- package/src/lib/plugins/openapi/playground/CollapsibleHeader.tsx +47 -0
- package/src/lib/plugins/openapi/playground/ExamplesDropdown.tsx +37 -32
- package/src/lib/plugins/openapi/playground/Headers.tsx +235 -102
- package/src/lib/plugins/openapi/playground/IdentityDialog.tsx +75 -0
- package/src/lib/plugins/openapi/playground/IdentitySelector.tsx +38 -0
- package/src/lib/plugins/openapi/playground/InlineInput.tsx +1 -1
- package/src/lib/plugins/openapi/playground/ParamsGrid.tsx +6 -1
- package/src/lib/plugins/openapi/playground/PathParams.tsx +19 -14
- package/src/lib/plugins/openapi/playground/Playground.tsx +347 -281
- package/src/lib/plugins/openapi/playground/PlaygroundDialog.tsx +7 -3
- package/src/lib/plugins/openapi/playground/QueryParams.tsx +144 -97
- package/src/lib/plugins/openapi/playground/RequestLoginDialog.tsx +51 -0
- package/src/lib/plugins/openapi/playground/Spinner.tsx +87 -0
- package/src/lib/plugins/openapi/playground/fileUtils.ts +32 -0
- package/src/lib/plugins/openapi/playground/rememberedIdentity.ts +26 -0
- package/src/lib/plugins/openapi/playground/request-panel/UrlPath.tsx +31 -0
- package/src/lib/plugins/openapi/playground/request-panel/UrlQueryParams.tsx +25 -0
- package/src/lib/plugins/openapi/playground/result-panel/Highlight.tsx +26 -0
- package/src/lib/plugins/openapi/playground/result-panel/ResponseStatusBar.tsx +115 -0
- package/src/lib/plugins/openapi/playground/result-panel/ResponseTab.tsx +150 -89
- package/src/lib/plugins/openapi/playground/result-panel/ResultPanel.tsx +79 -78
- package/src/lib/plugins/openapi/playground/useRememberSkipLoginDialog.tsx +20 -0
- package/src/lib/plugins/openapi/processors/removeExtensions.test.ts +222 -0
- package/src/lib/plugins/openapi/processors/removeExtensions.ts +29 -0
- package/src/lib/plugins/openapi/processors/removeParameters.test.ts +182 -0
- package/src/lib/plugins/openapi/processors/removeParameters.ts +103 -0
- package/src/lib/plugins/openapi/processors/removePaths.test.ts +167 -0
- package/src/lib/plugins/openapi/processors/removePaths.ts +57 -0
- package/src/lib/plugins/openapi/schema/LogicalGroup/LogicalGroup.tsx +1 -8
- package/src/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupConnector.tsx +3 -0
- package/src/lib/plugins/openapi/schema/LogicalGroup/LogicalGroupItem.tsx +6 -3
- package/src/lib/plugins/openapi/schema/SchemaExampleAndDefault.tsx +39 -0
- package/src/lib/plugins/openapi/schema/SchemaPropertyItem.tsx +71 -63
- package/src/lib/plugins/openapi/schema/SchemaView.tsx +99 -143
- package/src/lib/plugins/openapi/schema/utils.ts +30 -6
- package/src/lib/plugins/openapi/state.ts +36 -0
- package/src/lib/plugins/openapi/util/createHttpSnippet.ts +107 -0
- package/src/lib/plugins/openapi/util/createNavigationCategory.tsx +38 -0
- package/src/lib/plugins/openapi/util/generateSchemaExample.ts +51 -1
- package/src/lib/plugins/openapi/util/getRoutes.tsx +198 -0
- package/src/lib/plugins/openapi/util/methodColorMap.tsx +11 -0
- package/src/lib/plugins/redirect/index.tsx +1 -1
- package/src/lib/plugins/search-pagefind/PagefindSearch.tsx +164 -0
- package/src/lib/plugins/search-pagefind/ResultList.tsx +105 -0
- package/src/lib/plugins/search-pagefind/get-results.tsx +75 -0
- package/src/lib/plugins/search-pagefind/index.tsx +21 -0
- package/src/lib/plugins/search-pagefind/types.ts +118 -0
- package/src/lib/shiki.ts +132 -0
- package/src/lib/ui/Alert.tsx +44 -38
- package/src/lib/ui/Badge.tsx +2 -2
- package/src/lib/ui/Button.tsx +12 -7
- package/src/lib/ui/Callout.tsx +30 -10
- package/src/lib/ui/Card.tsx +1 -1
- package/src/lib/ui/Checkbox.tsx +8 -24
- package/src/lib/ui/CodeBlock.tsx +88 -0
- package/src/lib/ui/Command.tsx +29 -7
- package/src/lib/ui/Dialog.tsx +11 -7
- package/src/lib/ui/DropdownMenu.tsx +4 -4
- package/src/lib/ui/EmbeddedCodeBlock.tsx +94 -0
- package/src/lib/ui/HoverCard.tsx +1 -1
- package/src/lib/ui/Input.tsx +2 -3
- package/src/lib/ui/Popover.tsx +1 -1
- package/src/lib/ui/RadioGroup.tsx +1 -1
- package/src/lib/ui/Select.tsx +3 -3
- package/src/lib/ui/Slider.tsx +1 -1
- package/src/lib/ui/Stepper.tsx +8 -0
- package/src/lib/ui/Switch.tsx +1 -1
- package/src/lib/ui/SyntaxHighlight.tsx +35 -0
- package/src/lib/ui/Tabs.tsx +2 -2
- package/src/lib/ui/Textarea.tsx +1 -1
- package/src/lib/ui/Toggle.tsx +1 -1
- package/src/lib/ui/Tooltip.tsx +16 -1
- package/src/lib/ui/util.tsx +3 -0
- package/src/lib/util/MdxComponents.tsx +49 -20
- package/src/lib/util/detectOS.ts +9 -0
- package/src/lib/util/ensureArray.ts +3 -0
- package/src/lib/util/humanFileSize.test.ts +24 -0
- package/src/lib/util/humanFileSize.ts +16 -0
- package/src/lib/util/joinPath.tsx +3 -0
- package/src/lib/util/os.ts +18 -0
- package/src/lib/util/scrollIntoViewIfNeeded.ts +18 -0
- package/src/lib/util/traverse.ts +12 -13
- package/src/lib/util/types.ts +7 -0
- package/src/lib/util/url.test.ts +51 -0
- package/src/lib/util/url.ts +18 -0
- package/src/lib/util/useCopyToClipboard.ts +17 -0
- package/src/lib/util/useExposedProps.tsx +12 -1
- package/src/lib/util/useLatest.ts +18 -0
- package/src/lib/util/useOnScreen.ts +6 -4
- package/src/lib/util/useScrollToAnchor.ts +32 -40
- package/src/lib/util/useScrollToTop.ts +8 -3
- package/src/shiki/langs/abap.js +1 -0
- package/src/shiki/langs/actionscript-3.js +1 -0
- package/src/shiki/langs/ada.js +1 -0
- package/src/shiki/langs/angular-expression.js +1 -0
- package/src/shiki/langs/angular-html.js +1 -0
- package/src/shiki/langs/angular-inline-style.js +1 -0
- package/src/shiki/langs/angular-inline-template.js +1 -0
- package/src/shiki/langs/angular-let-declaration.js +1 -0
- package/src/shiki/langs/angular-template-blocks.js +1 -0
- package/src/shiki/langs/angular-template.js +1 -0
- package/src/shiki/langs/angular-ts.js +1 -0
- package/src/shiki/langs/apache.js +1 -0
- package/src/shiki/langs/apex.js +1 -0
- package/src/shiki/langs/apl.js +1 -0
- package/src/shiki/langs/applescript.js +1 -0
- package/src/shiki/langs/ara.js +1 -0
- package/src/shiki/langs/asciidoc.js +1 -0
- package/src/shiki/langs/asm.js +1 -0
- package/src/shiki/langs/astro.js +1 -0
- package/src/shiki/langs/awk.js +1 -0
- package/src/shiki/langs/ballerina.js +1 -0
- package/src/shiki/langs/bat.js +1 -0
- package/src/shiki/langs/beancount.js +1 -0
- package/src/shiki/langs/berry.js +1 -0
- package/src/shiki/langs/bibtex.js +1 -0
- package/src/shiki/langs/bicep.js +1 -0
- package/src/shiki/langs/blade.js +1 -0
- package/src/shiki/langs/bsl.js +1 -0
- package/src/shiki/langs/c.js +1 -0
- package/src/shiki/langs/cadence.js +1 -0
- package/src/shiki/langs/cairo.js +1 -0
- package/src/shiki/langs/clarity.js +1 -0
- package/src/shiki/langs/clojure.js +1 -0
- package/src/shiki/langs/cmake.js +1 -0
- package/src/shiki/langs/cobol.js +1 -0
- package/src/shiki/langs/codeowners.js +1 -0
- package/src/shiki/langs/codeql.js +1 -0
- package/src/shiki/langs/coffee.js +1 -0
- package/src/shiki/langs/common-lisp.js +1 -0
- package/src/shiki/langs/coq.js +1 -0
- package/src/shiki/langs/cpp-macro.js +1 -0
- package/src/shiki/langs/cpp.js +1 -0
- package/src/shiki/langs/crystal.js +1 -0
- package/src/shiki/langs/csharp.js +1 -0
- package/src/shiki/langs/css.js +1 -0
- package/src/shiki/langs/csv.js +1 -0
- package/src/shiki/langs/cue.js +1 -0
- package/src/shiki/langs/cypher.js +1 -0
- package/src/shiki/langs/d.js +1 -0
- package/src/shiki/langs/dart.js +1 -0
- package/src/shiki/langs/dax.js +1 -0
- package/src/shiki/langs/desktop.js +1 -0
- package/src/shiki/langs/diff.js +1 -0
- package/src/shiki/langs/docker.js +1 -0
- package/src/shiki/langs/dotenv.js +1 -0
- package/src/shiki/langs/dream-maker.js +1 -0
- package/src/shiki/langs/edge.js +1 -0
- package/src/shiki/langs/elixir.js +1 -0
- package/src/shiki/langs/elm.js +1 -0
- package/src/shiki/langs/emacs-lisp.js +1 -0
- package/src/shiki/langs/erb.js +1 -0
- package/src/shiki/langs/erlang.js +1 -0
- package/src/shiki/langs/es-tag-css.js +1 -0
- package/src/shiki/langs/es-tag-glsl.js +1 -0
- package/src/shiki/langs/es-tag-html.js +1 -0
- package/src/shiki/langs/es-tag-sql.js +1 -0
- package/src/shiki/langs/es-tag-xml.js +1 -0
- package/src/shiki/langs/fennel.js +1 -0
- package/src/shiki/langs/fish.js +1 -0
- package/src/shiki/langs/fluent.js +1 -0
- package/src/shiki/langs/fortran-fixed-form.js +1 -0
- package/src/shiki/langs/fortran-free-form.js +1 -0
- package/src/shiki/langs/fsharp.js +1 -0
- package/src/shiki/langs/gdresource.js +1 -0
- package/src/shiki/langs/gdscript.js +1 -0
- package/src/shiki/langs/gdshader.js +1 -0
- package/src/shiki/langs/genie.js +1 -0
- package/src/shiki/langs/gherkin.js +1 -0
- package/src/shiki/langs/git-commit.js +1 -0
- package/src/shiki/langs/git-rebase.js +1 -0
- package/src/shiki/langs/gleam.js +1 -0
- package/src/shiki/langs/glimmer-js.js +1 -0
- package/src/shiki/langs/glimmer-ts.js +1 -0
- package/src/shiki/langs/glsl.js +1 -0
- package/src/shiki/langs/gnuplot.js +1 -0
- package/src/shiki/langs/go.js +1 -0
- package/src/shiki/langs/graphql.js +1 -0
- package/src/shiki/langs/groovy.js +1 -0
- package/src/shiki/langs/hack.js +1 -0
- package/src/shiki/langs/haml.js +1 -0
- package/src/shiki/langs/handlebars.js +1 -0
- package/src/shiki/langs/haskell.js +1 -0
- package/src/shiki/langs/haxe.js +1 -0
- package/src/shiki/langs/hcl.js +1 -0
- package/src/shiki/langs/hjson.js +1 -0
- package/src/shiki/langs/hlsl.js +1 -0
- package/src/shiki/langs/html-derivative.js +1 -0
- package/src/shiki/langs/html.js +1 -0
- package/src/shiki/langs/http.js +1 -0
- package/src/shiki/langs/hxml.js +1 -0
- package/src/shiki/langs/hy.js +1 -0
- package/src/shiki/langs/imba.js +1 -0
- package/src/shiki/langs/ini.js +1 -0
- package/src/shiki/langs/java.js +1 -0
- package/src/shiki/langs/javascript.js +1 -0
- package/src/shiki/langs/jinja-html.js +1 -0
- package/src/shiki/langs/jinja.js +1 -0
- package/src/shiki/langs/jison.js +1 -0
- package/src/shiki/langs/json.js +1 -0
- package/src/shiki/langs/json5.js +1 -0
- package/src/shiki/langs/jsonc.js +1 -0
- package/src/shiki/langs/jsonl.js +1 -0
- package/src/shiki/langs/jsonnet.js +1 -0
- package/src/shiki/langs/jssm.js +1 -0
- package/src/shiki/langs/jsx.js +1 -0
- package/src/shiki/langs/julia.js +1 -0
- package/src/shiki/langs/kotlin.js +1 -0
- package/src/shiki/langs/kusto.js +1 -0
- package/src/shiki/langs/latex.js +1 -0
- package/src/shiki/langs/lean.js +1 -0
- package/src/shiki/langs/less.js +1 -0
- package/src/shiki/langs/liquid.js +1 -0
- package/src/shiki/langs/llvm.js +1 -0
- package/src/shiki/langs/log.js +1 -0
- package/src/shiki/langs/logo.js +1 -0
- package/src/shiki/langs/lua.js +1 -0
- package/src/shiki/langs/luau.js +1 -0
- package/src/shiki/langs/make.js +1 -0
- package/src/shiki/langs/markdown-vue.js +1 -0
- package/src/shiki/langs/markdown.js +1 -0
- package/src/shiki/langs/marko.js +1 -0
- package/src/shiki/langs/matlab.js +1 -0
- package/src/shiki/langs/mdc.js +1 -0
- package/src/shiki/langs/mdx.js +1 -0
- package/src/shiki/langs/mermaid.js +1 -0
- package/src/shiki/langs/mipsasm.js +1 -0
- package/src/shiki/langs/mojo.js +1 -0
- package/src/shiki/langs/move.js +1 -0
- package/src/shiki/langs/narrat.js +1 -0
- package/src/shiki/langs/nextflow.js +1 -0
- package/src/shiki/langs/nginx.js +1 -0
- package/src/shiki/langs/nim.js +1 -0
- package/src/shiki/langs/nix.js +1 -0
- package/src/shiki/langs/nushell.js +1 -0
- package/src/shiki/langs/objective-c.js +1 -0
- package/src/shiki/langs/objective-cpp.js +1 -0
- package/src/shiki/langs/ocaml.js +1 -0
- package/src/shiki/langs/pascal.js +1 -0
- package/src/shiki/langs/perl.js +1 -0
- package/src/shiki/langs/php.js +1 -0
- package/src/shiki/langs/plsql.js +1 -0
- package/src/shiki/langs/po.js +1 -0
- package/src/shiki/langs/polar.js +1 -0
- package/src/shiki/langs/postcss.js +1 -0
- package/src/shiki/langs/powerquery.js +1 -0
- package/src/shiki/langs/powershell.js +1 -0
- package/src/shiki/langs/prisma.js +1 -0
- package/src/shiki/langs/prolog.js +1 -0
- package/src/shiki/langs/proto.js +1 -0
- package/src/shiki/langs/pug.js +1 -0
- package/src/shiki/langs/puppet.js +1 -0
- package/src/shiki/langs/purescript.js +1 -0
- package/src/shiki/langs/python.js +1 -0
- package/src/shiki/langs/qml.js +1 -0
- package/src/shiki/langs/qmldir.js +1 -0
- package/src/shiki/langs/qss.js +1 -0
- package/src/shiki/langs/r.js +1 -0
- package/src/shiki/langs/racket.js +1 -0
- package/src/shiki/langs/raku.js +1 -0
- package/src/shiki/langs/razor.js +1 -0
- package/src/shiki/langs/reg.js +1 -0
- package/src/shiki/langs/regexp.js +1 -0
- package/src/shiki/langs/rel.js +1 -0
- package/src/shiki/langs/riscv.js +1 -0
- package/src/shiki/langs/rst.js +1 -0
- package/src/shiki/langs/ruby.js +1 -0
- package/src/shiki/langs/rust.js +1 -0
- package/src/shiki/langs/sas.js +1 -0
- package/src/shiki/langs/sass.js +1 -0
- package/src/shiki/langs/scala.js +1 -0
- package/src/shiki/langs/scheme.js +1 -0
- package/src/shiki/langs/scss.js +1 -0
- package/src/shiki/langs/sdbl.js +1 -0
- package/src/shiki/langs/shaderlab.js +1 -0
- package/src/shiki/langs/shellscript.js +1 -0
- package/src/shiki/langs/shellsession.js +1 -0
- package/src/shiki/langs/smalltalk.js +1 -0
- package/src/shiki/langs/solidity.js +1 -0
- package/src/shiki/langs/soy.js +1 -0
- package/src/shiki/langs/sparql.js +1 -0
- package/src/shiki/langs/splunk.js +1 -0
- package/src/shiki/langs/sql.js +1 -0
- package/src/shiki/langs/ssh-config.js +1 -0
- package/src/shiki/langs/stata.js +1 -0
- package/src/shiki/langs/stylus.js +1 -0
- package/src/shiki/langs/svelte.js +1 -0
- package/src/shiki/langs/swift.js +1 -0
- package/src/shiki/langs/system-verilog.js +1 -0
- package/src/shiki/langs/systemd.js +1 -0
- package/src/shiki/langs/talonscript.js +1 -0
- package/src/shiki/langs/tasl.js +1 -0
- package/src/shiki/langs/tcl.js +1 -0
- package/src/shiki/langs/templ.js +1 -0
- package/src/shiki/langs/terraform.js +1 -0
- package/src/shiki/langs/tex.js +1 -0
- package/src/shiki/langs/toml.js +1 -0
- package/src/shiki/langs/ts-tags.js +1 -0
- package/src/shiki/langs/tsv.js +1 -0
- package/src/shiki/langs/tsx.js +1 -0
- package/src/shiki/langs/turtle.js +1 -0
- package/src/shiki/langs/twig.js +1 -0
- package/src/shiki/langs/typescript.js +1 -0
- package/src/shiki/langs/typespec.js +1 -0
- package/src/shiki/langs/typst.js +1 -0
- package/src/shiki/langs/v.js +1 -0
- package/src/shiki/langs/vala.js +1 -0
- package/src/shiki/langs/vb.js +1 -0
- package/src/shiki/langs/verilog.js +1 -0
- package/src/shiki/langs/vhdl.js +1 -0
- package/src/shiki/langs/viml.js +1 -0
- package/src/shiki/langs/vue-directives.js +1 -0
- package/src/shiki/langs/vue-html.js +1 -0
- package/src/shiki/langs/vue-interpolations.js +1 -0
- package/src/shiki/langs/vue-sfc-style-variable-injection.js +1 -0
- package/src/shiki/langs/vue.js +1 -0
- package/src/shiki/langs/vyper.js +1 -0
- package/src/shiki/langs/wasm.js +1 -0
- package/src/shiki/langs/wenyan.js +1 -0
- package/src/shiki/langs/wgsl.js +1 -0
- package/src/shiki/langs/wikitext.js +1 -0
- package/src/shiki/langs/wit.js +1 -0
- package/src/shiki/langs/wolfram.js +1 -0
- package/src/shiki/langs/xml.js +1 -0
- package/src/shiki/langs/xsl.js +1 -0
- package/src/shiki/langs/yaml.js +1 -0
- package/src/shiki/langs/zenscript.js +1 -0
- package/src/shiki/langs/zig.js +1 -0
- package/src/shiki/themes/andromeeda.js +1 -0
- package/src/shiki/themes/aurora-x.js +1 -0
- package/src/shiki/themes/ayu-dark.js +1 -0
- package/src/shiki/themes/catppuccin-frappe.js +1 -0
- package/src/shiki/themes/catppuccin-latte.js +1 -0
- package/src/shiki/themes/catppuccin-macchiato.js +1 -0
- package/src/shiki/themes/catppuccin-mocha.js +1 -0
- package/src/shiki/themes/dark-plus.js +1 -0
- package/src/shiki/themes/dracula-soft.js +1 -0
- package/src/shiki/themes/dracula.js +1 -0
- package/src/shiki/themes/everforest-dark.js +1 -0
- package/src/shiki/themes/everforest-light.js +1 -0
- package/src/shiki/themes/github-dark-default.js +1 -0
- package/src/shiki/themes/github-dark-dimmed.js +1 -0
- package/src/shiki/themes/github-dark-high-contrast.js +1 -0
- package/src/shiki/themes/github-dark.js +1 -0
- package/src/shiki/themes/github-light-default.js +1 -0
- package/src/shiki/themes/github-light-high-contrast.js +1 -0
- package/src/shiki/themes/github-light.js +1 -0
- package/src/shiki/themes/gruvbox-dark-hard.js +1 -0
- package/src/shiki/themes/gruvbox-dark-medium.js +1 -0
- package/src/shiki/themes/gruvbox-dark-soft.js +1 -0
- package/src/shiki/themes/gruvbox-light-hard.js +1 -0
- package/src/shiki/themes/gruvbox-light-medium.js +1 -0
- package/src/shiki/themes/gruvbox-light-soft.js +1 -0
- package/src/shiki/themes/houston.js +1 -0
- package/src/shiki/themes/kanagawa-dragon.js +1 -0
- package/src/shiki/themes/kanagawa-lotus.js +1 -0
- package/src/shiki/themes/kanagawa-wave.js +1 -0
- package/src/shiki/themes/laserwave.js +1 -0
- package/src/shiki/themes/light-plus.js +1 -0
- package/src/shiki/themes/material-theme-darker.js +1 -0
- package/src/shiki/themes/material-theme-lighter.js +1 -0
- package/src/shiki/themes/material-theme-ocean.js +1 -0
- package/src/shiki/themes/material-theme-palenight.js +1 -0
- package/src/shiki/themes/material-theme.js +1 -0
- package/src/shiki/themes/min-dark.js +1 -0
- package/src/shiki/themes/min-light.js +1 -0
- package/src/shiki/themes/monokai.js +1 -0
- package/src/shiki/themes/night-owl.js +1 -0
- package/src/shiki/themes/nord.js +1 -0
- package/src/shiki/themes/one-dark-pro.js +1 -0
- package/src/shiki/themes/one-light.js +1 -0
- package/src/shiki/themes/plastic.js +1 -0
- package/src/shiki/themes/poimandres.js +1 -0
- package/src/shiki/themes/red.js +1 -0
- package/src/shiki/themes/rose-pine-dawn.js +1 -0
- package/src/shiki/themes/rose-pine-moon.js +1 -0
- package/src/shiki/themes/rose-pine.js +1 -0
- package/src/shiki/themes/slack-dark.js +1 -0
- package/src/shiki/themes/slack-ochin.js +1 -0
- package/src/shiki/themes/snazzy-light.js +1 -0
- package/src/shiki/themes/solarized-dark.js +1 -0
- package/src/shiki/themes/solarized-light.js +1 -0
- package/src/shiki/themes/synthwave-84.js +1 -0
- package/src/shiki/themes/tokyo-night.js +1 -0
- package/src/shiki/themes/vesper.js +1 -0
- package/src/shiki/themes/vitesse-black.js +1 -0
- package/src/shiki/themes/vitesse-dark.js +1 -0
- package/src/shiki/themes/vitesse-light.js +1 -0
- package/client.d.ts +0 -8
- package/dist/app/tailwind.d.ts +0 -4
- package/dist/app/tailwind.js +0 -77
- package/dist/app/tailwind.js.map +0 -1
- package/dist/config/common.d.ts +0 -8
- package/dist/config/common.js +0 -2
- package/dist/config/common.js.map +0 -1
- package/dist/config/validators/InputSidebarSchema.d.ts +0 -217
- package/dist/config/validators/InputSidebarSchema.js +0 -53
- package/dist/config/validators/InputSidebarSchema.js.map +0 -1
- package/dist/config/validators/SidebarSchema.d.ts +0 -46
- package/dist/config/validators/SidebarSchema.js +0 -118
- package/dist/config/validators/SidebarSchema.js.map +0 -1
- package/dist/config/validators/common.d.ts +0 -5034
- package/dist/config/validators/common.js +0 -287
- package/dist/config/validators/common.js.map +0 -1
- package/dist/lib/components/SlotletProvider.d.ts +0 -17
- package/dist/lib/components/SlotletProvider.js +0 -18
- package/dist/lib/components/SlotletProvider.js.map +0 -1
- package/dist/lib/components/SyntaxHighlight.d.ts +0 -12
- package/dist/lib/components/SyntaxHighlight.js +0 -53
- package/dist/lib/components/SyntaxHighlight.js.map +0 -1
- package/dist/lib/components/context/PluginSystem.js +0 -2
- package/dist/lib/components/context/PluginSystem.js.map +0 -1
- package/dist/lib/components/navigation/Sidebar.d.ts +0 -3
- package/dist/lib/components/navigation/Sidebar.js +0 -14
- package/dist/lib/components/navigation/Sidebar.js.map +0 -1
- package/dist/lib/components/navigation/SidebarBadge.d.ts +0 -24
- package/dist/lib/components/navigation/SidebarBadge.js +0 -24
- package/dist/lib/components/navigation/SidebarBadge.js.map +0 -1
- package/dist/lib/components/navigation/SidebarCategory.d.ts +0 -5
- package/dist/lib/components/navigation/SidebarCategory.js +0 -51
- package/dist/lib/components/navigation/SidebarCategory.js.map +0 -1
- package/dist/lib/components/navigation/SidebarItem.d.ts +0 -10
- package/dist/lib/components/navigation/SidebarItem.js +0 -43
- package/dist/lib/components/navigation/SidebarItem.js.map +0 -1
- package/dist/lib/components/navigation/SidebarWrapper.d.ts +0 -6
- package/dist/lib/components/navigation/SidebarWrapper.js +0 -6
- package/dist/lib/components/navigation/SidebarWrapper.js.map +0 -1
- package/dist/lib/plugins/custom-pages/CustomPage.d.ts +0 -2
- package/dist/lib/plugins/custom-pages/CustomPage.js +0 -11
- package/dist/lib/plugins/custom-pages/CustomPage.js.map +0 -1
- package/dist/lib/plugins/markdown/Toc.js +0 -48
- package/dist/lib/plugins/markdown/Toc.js.map +0 -1
- package/dist/lib/plugins/markdown/resolver.d.ts +0 -38
- package/dist/lib/plugins/markdown/resolver.js +0 -75
- package/dist/lib/plugins/markdown/resolver.js.map +0 -1
- package/dist/lib/plugins/openapi/OpenApiRoute.d.ts +0 -9
- package/dist/lib/plugins/openapi/OpenApiRoute.js +0 -25
- package/dist/lib/plugins/openapi/OpenApiRoute.js.map +0 -1
- package/dist/lib/plugins/openapi/playground/SubmitButton.d.ts +0 -7
- package/dist/lib/plugins/openapi/playground/SubmitButton.js +0 -22
- package/dist/lib/plugins/openapi/playground/SubmitButton.js.map +0 -1
- package/dist/lib/plugins/openapi/playground/UrlDisplay.d.ts +0 -4
- package/dist/lib/plugins/openapi/playground/UrlDisplay.js +0 -22
- package/dist/lib/plugins/openapi/playground/UrlDisplay.js.map +0 -1
- package/dist/lib/plugins/openapi/playground/result-panel/RequestTab.d.ts +0 -7
- package/dist/lib/plugins/openapi/playground/result-panel/RequestTab.js +0 -11
- package/dist/lib/plugins/openapi/playground/result-panel/RequestTab.js.map +0 -1
- package/dist/lib/plugins/openapi/post-processors/removeExtensions.d.ts +0 -7
- package/dist/lib/plugins/openapi/post-processors/removeExtensions.js +0 -16
- package/dist/lib/plugins/openapi/post-processors/removeExtensions.js.map +0 -1
- package/dist/lib/plugins/openapi/post-processors/removeExtensions.test.js +0 -174
- package/dist/lib/plugins/openapi/post-processors/removeExtensions.test.js.map +0 -1
- package/dist/lib/plugins/openapi/post-processors/removeParameters.d.ts +0 -10
- package/dist/lib/plugins/openapi/post-processors/removeParameters.js +0 -66
- package/dist/lib/plugins/openapi/post-processors/removeParameters.js.map +0 -1
- package/dist/lib/plugins/openapi/post-processors/removeParameters.test.js +0 -131
- package/dist/lib/plugins/openapi/post-processors/removeParameters.test.js.map +0 -1
- package/dist/lib/plugins/openapi/post-processors/removePaths.d.ts +0 -11
- package/dist/lib/plugins/openapi/post-processors/removePaths.js +0 -33
- package/dist/lib/plugins/openapi/post-processors/removePaths.js.map +0 -1
- package/dist/lib/plugins/openapi/post-processors/removePaths.test.js +0 -104
- package/dist/lib/plugins/openapi/post-processors/removePaths.test.js.map +0 -1
- package/dist/lib/plugins/openapi/post-processors/traverse.js.map +0 -1
- package/dist/vite/plugin-docs.test.js +0 -22
- package/dist/vite/plugin-docs.test.js.map +0 -1
- package/dist/vite/plugin-sidebar.d.ts +0 -3
- package/dist/vite/plugin-sidebar.js +0 -47
- package/dist/vite/plugin-sidebar.js.map +0 -1
- package/dist/vite/plugin-theme-css.d.ts +0 -6
- package/dist/vite/plugin-theme-css.js +0 -114
- package/dist/vite/plugin-theme-css.js.map +0 -1
- package/dist/vite/prerender.d.ts +0 -22
- package/dist/vite/prerender.js +0 -89
- package/dist/vite/prerender.js.map +0 -1
- package/dist/zuplo/env.d.ts +0 -7
- package/dist/zuplo/env.js +0 -12
- package/dist/zuplo/env.js.map +0 -1
- package/lib/AuthenticationPlugin-Du8cLBSr.js +0 -58
- package/lib/AuthenticationPlugin-Du8cLBSr.js.map +0 -1
- package/lib/CategoryHeading-MYL1u_6K.js +0 -10
- package/lib/CategoryHeading-MYL1u_6K.js.map +0 -1
- package/lib/Markdown-Cyrx_JrO.js +0 -15212
- package/lib/Markdown-Cyrx_JrO.js.map +0 -1
- package/lib/MdxPage-BuG8Tuwc.js +0 -193
- package/lib/MdxPage-BuG8Tuwc.js.map +0 -1
- package/lib/OpenApiRoute-UrC_t0e5.js +0 -36
- package/lib/OpenApiRoute-UrC_t0e5.js.map +0 -1
- package/lib/OperationList-CDt1xdc4.js +0 -5169
- package/lib/OperationList-CDt1xdc4.js.map +0 -1
- package/lib/Select-CnCZ4WhS.js +0 -223
- package/lib/Select-CnCZ4WhS.js.map +0 -1
- package/lib/SlotletProvider-mQiPDQIH.js +0 -221
- package/lib/SlotletProvider-mQiPDQIH.js.map +0 -1
- package/lib/Spinner-BlzrEEk1.js +0 -51
- package/lib/Spinner-BlzrEEk1.js.map +0 -1
- package/lib/SyntaxHighlight-B0L4SC_N.js +0 -2986
- package/lib/SyntaxHighlight-B0L4SC_N.js.map +0 -1
- package/lib/ZudokuContext-BTUJPpQl.js +0 -1229
- package/lib/ZudokuContext-BTUJPpQl.js.map +0 -1
- package/lib/__vite-browser-external-BYRIRx8p.js +0 -9
- package/lib/__vite-browser-external-BYRIRx8p.js.map +0 -1
- package/lib/_commonjsHelpers-BkfeUUK-.js +0 -29
- package/lib/_commonjsHelpers-BkfeUUK-.js.map +0 -1
- package/lib/chunk-SYFQ2XB5-BPvC-soB.js +0 -1821
- package/lib/chunk-SYFQ2XB5-BPvC-soB.js.map +0 -1
- package/lib/circular-DxaIIlWD.js +0 -15409
- package/lib/circular-DxaIIlWD.js.map +0 -1
- package/lib/cn-qaFjX9_3.js +0 -2279
- package/lib/cn-qaFjX9_3.js.map +0 -1
- package/lib/context-rwLGh-6_.js +0 -22
- package/lib/context-rwLGh-6_.js.map +0 -1
- package/lib/createServer-CjNktZzL.js +0 -12603
- package/lib/createServer-CjNktZzL.js.map +0 -1
- package/lib/hook-FT3SJLe_.js +0 -227
- package/lib/hook-FT3SJLe_.js.map +0 -1
- package/lib/index-B7mqiOei.js +0 -509
- package/lib/index-B7mqiOei.js.map +0 -1
- package/lib/index-CjJS0l4l.js +0 -2094
- package/lib/index-CjJS0l4l.js.map +0 -1
- package/lib/index-Djenk2Hj.js +0 -36
- package/lib/index-Djenk2Hj.js.map +0 -1
- package/lib/index-Dl3Yl0yb.js +0 -4837
- package/lib/index-Dl3Yl0yb.js.map +0 -1
- package/lib/index-Eb1oiHbM.js +0 -1997
- package/lib/index-Eb1oiHbM.js.map +0 -1
- package/lib/index.esm-9-TF9KQB.js +0 -692
- package/lib/index.esm-9-TF9KQB.js.map +0 -1
- package/lib/index.esm-CrSoEshU.js +0 -1207
- package/lib/index.esm-CrSoEshU.js.map +0 -1
- package/lib/invariant-Caa8-XvF.js +0 -26
- package/lib/invariant-Caa8-XvF.js.map +0 -1
- package/lib/joinUrl-nLx9pD-Z.js +0 -20
- package/lib/joinUrl-nLx9pD-Z.js.map +0 -1
- package/lib/jsx-runtime-Bdg6XQ1m.js +0 -446
- package/lib/jsx-runtime-Bdg6XQ1m.js.map +0 -1
- package/lib/post-processors/removeExtensions.js +0 -11
- package/lib/post-processors/removeExtensions.js.map +0 -1
- package/lib/post-processors/removeParameters.js +0 -48
- package/lib/post-processors/removeParameters.js.map +0 -1
- package/lib/post-processors/removePaths.js +0 -28
- package/lib/post-processors/removePaths.js.map +0 -1
- package/lib/post-processors/traverse.js +0 -15
- package/lib/post-processors/traverse.js.map +0 -1
- package/lib/prism-bash.min-HHIMdNJ_.js +0 -7
- package/lib/prism-bash.min-HHIMdNJ_.js.map +0 -1
- package/lib/prism-csharp.min-bQAo2pmx.js +0 -63
- package/lib/prism-csharp.min-bQAo2pmx.js.map +0 -1
- package/lib/prism-java.min-BpvsOuIa.js +0 -35
- package/lib/prism-java.min-BpvsOuIa.js.map +0 -1
- package/lib/prism-javascript.min-CEqHqgbm.js +0 -9
- package/lib/prism-javascript.min-CEqHqgbm.js.map +0 -1
- package/lib/prism-json.min-B1GJqK1k.js +0 -2
- package/lib/prism-json.min-B1GJqK1k.js.map +0 -1
- package/lib/prism-markdown.min-C0Qn0m-5.js +0 -61
- package/lib/prism-markdown.min-C0Qn0m-5.js.map +0 -1
- package/lib/prism-markup-BNGj0Tvm.js +0 -174
- package/lib/prism-markup-BNGj0Tvm.js.map +0 -1
- package/lib/prism-objectivec.min-BXSWqpJJ.js +0 -2
- package/lib/prism-objectivec.min-BXSWqpJJ.js.map +0 -1
- package/lib/prism-ruby.min-Dx9KO9ds.js +0 -38
- package/lib/prism-ruby.min-Dx9KO9ds.js.map +0 -1
- package/lib/prism-typescript.min-CD7H2IYQ.js +0 -34
- package/lib/prism-typescript.min-CD7H2IYQ.js.map +0 -1
- package/lib/state-mM7uaXTW.js +0 -202
- package/lib/state-mM7uaXTW.js.map +0 -1
- package/lib/useExposedProps-BLKFBylA.js +0 -9
- package/lib/useExposedProps-BLKFBylA.js.map +0 -1
- package/lib/useScrollToAnchor-BZsGmBng.js +0 -284
- package/lib/useScrollToAnchor-BZsGmBng.js.map +0 -1
- package/src/app/tailwind.ts +0 -83
- package/src/lib/components/SlotletProvider.tsx +0 -55
- package/src/lib/components/SyntaxHighlight.tsx +0 -171
- package/src/lib/components/context/PluginSystem.ts +0 -0
- package/src/lib/components/navigation/Sidebar.tsx +0 -49
- package/src/lib/components/navigation/SidebarBadge.tsx +0 -45
- package/src/lib/components/navigation/SidebarCategory.tsx +0 -137
- package/src/lib/components/navigation/SidebarItem.tsx +0 -124
- package/src/lib/components/navigation/SidebarWrapper.tsx +0 -27
- package/src/lib/plugins/custom-pages/CustomPage.tsx +0 -18
- package/src/lib/plugins/markdown/Toc.tsx +0 -135
- package/src/lib/plugins/markdown/resolver.ts +0 -90
- package/src/lib/plugins/openapi/OpenApiRoute.tsx +0 -51
- package/src/lib/plugins/openapi/playground/SubmitButton.tsx +0 -75
- package/src/lib/plugins/openapi/playground/UrlDisplay.tsx +0 -32
- package/src/lib/plugins/openapi/playground/result-panel/RequestTab.tsx +0 -73
- package/src/lib/plugins/openapi/post-processors/removeExtensions.test.ts +0 -202
- package/src/lib/plugins/openapi/post-processors/removeExtensions.ts +0 -27
- package/src/lib/plugins/openapi/post-processors/removeParameters.test.ts +0 -148
- package/src/lib/plugins/openapi/post-processors/removeParameters.ts +0 -101
- package/src/lib/plugins/openapi/post-processors/removePaths.test.ts +0 -126
- package/src/lib/plugins/openapi/post-processors/removePaths.ts +0 -55
- /package/dist/{lib/components/context/PluginSystem.d.ts → config/validators/InputNavigationSchema.test-d.d.ts} +0 -0
- /package/dist/{lib/plugins/openapi/post-processors/removeExtensions.test.d.ts → config/validators/validate.test.d.ts} +0 -0
- /package/dist/lib/{plugins/openapi/post-processors/removeParameters.test.d.ts → auth/issuer.test.d.ts} +0 -0
- /package/dist/lib/{plugins/openapi/post-processors/removePaths.test.d.ts → components/Slot.test.d.ts} +0 -0
- /package/dist/lib/{plugins/markdown → components/navigation}/Toc.d.ts +0 -0
- /package/dist/{vite/plugin-docs.test.d.ts → lib/hooks/useEvent.test.d.ts} +0 -0
- /package/dist/lib/plugins/openapi/{post-processors → processors}/traverse.d.ts +0 -0
- /package/dist/lib/plugins/openapi/{post-processors → processors}/traverse.js +0 -0
- /package/src/lib/plugins/openapi/{post-processors → processors}/traverse.ts +0 -0
package/lib/ui/Drawer.js
CHANGED
|
@@ -1,1154 +1,17 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import { c as oe } from "../cn-qaFjX9_3.js";
|
|
6
|
-
function Tt(e) {
|
|
7
|
-
if (typeof document > "u") return;
|
|
8
|
-
let n = document.head || document.getElementsByTagName("head")[0], t = document.createElement("style");
|
|
9
|
-
t.type = "text/css", n.appendChild(t), t.styleSheet ? t.styleSheet.cssText = e : t.appendChild(document.createTextNode(e));
|
|
10
|
-
}
|
|
11
|
-
const qe = r.createContext({
|
|
12
|
-
drawerRef: {
|
|
13
|
-
current: null
|
|
14
|
-
},
|
|
15
|
-
overlayRef: {
|
|
16
|
-
current: null
|
|
17
|
-
},
|
|
18
|
-
onPress: () => {
|
|
19
|
-
},
|
|
20
|
-
onRelease: () => {
|
|
21
|
-
},
|
|
22
|
-
onDrag: () => {
|
|
23
|
-
},
|
|
24
|
-
onNestedDrag: () => {
|
|
25
|
-
},
|
|
26
|
-
onNestedOpenChange: () => {
|
|
27
|
-
},
|
|
28
|
-
onNestedRelease: () => {
|
|
29
|
-
},
|
|
30
|
-
openProp: void 0,
|
|
31
|
-
dismissible: !1,
|
|
32
|
-
isOpen: !1,
|
|
33
|
-
isDragging: !1,
|
|
34
|
-
keyboardIsOpen: {
|
|
35
|
-
current: !1
|
|
36
|
-
},
|
|
37
|
-
snapPointsOffset: null,
|
|
38
|
-
snapPoints: null,
|
|
39
|
-
handleOnly: !1,
|
|
40
|
-
modal: !1,
|
|
41
|
-
shouldFade: !1,
|
|
42
|
-
activeSnapPoint: null,
|
|
43
|
-
onOpenChange: () => {
|
|
44
|
-
},
|
|
45
|
-
setActiveSnapPoint: () => {
|
|
46
|
-
},
|
|
47
|
-
closeDrawer: () => {
|
|
48
|
-
},
|
|
49
|
-
direction: "bottom",
|
|
50
|
-
shouldAnimate: {
|
|
51
|
-
current: !0
|
|
52
|
-
},
|
|
53
|
-
shouldScaleBackground: !1,
|
|
54
|
-
setBackgroundColorOnScale: !0,
|
|
55
|
-
noBodyStyles: !1,
|
|
56
|
-
container: null,
|
|
57
|
-
autoFocus: !1
|
|
58
|
-
}), ie = () => {
|
|
59
|
-
const e = r.useContext(qe);
|
|
60
|
-
if (!e)
|
|
61
|
-
throw new Error("useDrawerContext must be used within a Drawer.Root");
|
|
62
|
-
return e;
|
|
63
|
-
};
|
|
64
|
-
Tt(`[data-vaul-drawer]{touch-action:none;will-change:transform;transition:transform .5s cubic-bezier(.32, .72, 0, 1);animation-duration:.5s;animation-timing-function:cubic-bezier(0.32,0.72,0,1)}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=bottom][data-state=open]{animation-name:slideFromBottom}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=bottom][data-state=closed]{animation-name:slideToBottom}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=top][data-state=open]{animation-name:slideFromTop}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=top][data-state=closed]{animation-name:slideToTop}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=left][data-state=open]{animation-name:slideFromLeft}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=left][data-state=closed]{animation-name:slideToLeft}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=right][data-state=open]{animation-name:slideFromRight}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=right][data-state=closed]{animation-name:slideToRight}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=bottom]{transform:translate3d(0,var(--initial-transform,100%),0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=top]{transform:translate3d(0,calc(var(--initial-transform,100%) * -1),0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=left]{transform:translate3d(calc(var(--initial-transform,100%) * -1),0,0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=right]{transform:translate3d(var(--initial-transform,100%),0,0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=top]{transform:translate3d(0,var(--snap-point-height,0),0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=bottom]{transform:translate3d(0,var(--snap-point-height,0),0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=left]{transform:translate3d(var(--snap-point-height,0),0,0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=right]{transform:translate3d(var(--snap-point-height,0),0,0)}[data-vaul-overlay][data-vaul-snap-points=false]{animation-duration:.5s;animation-timing-function:cubic-bezier(0.32,0.72,0,1)}[data-vaul-overlay][data-vaul-snap-points=false][data-state=open]{animation-name:fadeIn}[data-vaul-overlay][data-state=closed]{animation-name:fadeOut}[data-vaul-animate=false]{animation:none!important}[data-vaul-overlay][data-vaul-snap-points=true]{opacity:0;transition:opacity .5s cubic-bezier(.32, .72, 0, 1)}[data-vaul-overlay][data-vaul-snap-points=true]{opacity:1}[data-vaul-drawer]:not([data-vaul-custom-container=true])::after{content:'';position:absolute;background:inherit;background-color:inherit}[data-vaul-drawer][data-vaul-drawer-direction=top]::after{top:initial;bottom:100%;left:0;right:0;height:200%}[data-vaul-drawer][data-vaul-drawer-direction=bottom]::after{top:100%;bottom:initial;left:0;right:0;height:200%}[data-vaul-drawer][data-vaul-drawer-direction=left]::after{left:initial;right:100%;top:0;bottom:0;width:200%}[data-vaul-drawer][data-vaul-drawer-direction=right]::after{left:100%;right:initial;top:0;bottom:0;width:200%}[data-vaul-overlay][data-vaul-snap-points=true]:not([data-vaul-snap-points-overlay=true]):not(
|
|
65
|
-
[data-state=closed]
|
|
66
|
-
){opacity:0}[data-vaul-overlay][data-vaul-snap-points-overlay=true]{opacity:1}[data-vaul-handle]{display:block;position:relative;opacity:.7;background:#e2e2e4;margin-left:auto;margin-right:auto;height:5px;width:32px;border-radius:1rem;touch-action:pan-y}[data-vaul-handle]:active,[data-vaul-handle]:hover{opacity:1}[data-vaul-handle-hitarea]{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);width:max(100%,2.75rem);height:max(100%,2.75rem);touch-action:inherit}@media (hover:hover) and (pointer:fine){[data-vaul-drawer]{user-select:none}}@media (pointer:fine){[data-vaul-handle-hitarea]:{width:100%;height:100%}}@keyframes fadeIn{from{opacity:0}to{opacity:1}}@keyframes fadeOut{to{opacity:0}}@keyframes slideFromBottom{from{transform:translate3d(0,var(--initial-transform,100%),0)}to{transform:translate3d(0,0,0)}}@keyframes slideToBottom{to{transform:translate3d(0,var(--initial-transform,100%),0)}}@keyframes slideFromTop{from{transform:translate3d(0,calc(var(--initial-transform,100%) * -1),0)}to{transform:translate3d(0,0,0)}}@keyframes slideToTop{to{transform:translate3d(0,calc(var(--initial-transform,100%) * -1),0)}}@keyframes slideFromLeft{from{transform:translate3d(calc(var(--initial-transform,100%) * -1),0,0)}to{transform:translate3d(0,0,0)}}@keyframes slideToLeft{to{transform:translate3d(calc(var(--initial-transform,100%) * -1),0,0)}}@keyframes slideFromRight{from{transform:translate3d(var(--initial-transform,100%),0,0)}to{transform:translate3d(0,0,0)}}@keyframes slideToRight{to{transform:translate3d(var(--initial-transform,100%),0,0)}}`);
|
|
67
|
-
function Et() {
|
|
68
|
-
const e = navigator.userAgent;
|
|
69
|
-
return typeof window < "u" && (/Firefox/.test(e) && /Mobile/.test(e) || // Android Firefox
|
|
70
|
-
/FxiOS/.test(e));
|
|
71
|
-
}
|
|
72
|
-
function xt() {
|
|
73
|
-
return Me(/^Mac/);
|
|
74
|
-
}
|
|
75
|
-
function Ot() {
|
|
76
|
-
return Me(/^iPhone/);
|
|
77
|
-
}
|
|
78
|
-
function We() {
|
|
79
|
-
return /^((?!chrome|android).)*safari/i.test(navigator.userAgent);
|
|
80
|
-
}
|
|
81
|
-
function Ct() {
|
|
82
|
-
return Me(/^iPad/) || // iPadOS 13 lies and says it's a Mac, but we can distinguish by detecting touch support.
|
|
83
|
-
xt() && navigator.maxTouchPoints > 1;
|
|
84
|
-
}
|
|
85
|
-
function Xe() {
|
|
86
|
-
return Ot() || Ct();
|
|
87
|
-
}
|
|
88
|
-
function Me(e) {
|
|
89
|
-
return typeof window < "u" && window.navigator != null ? e.test(window.navigator.platform) : void 0;
|
|
90
|
-
}
|
|
91
|
-
const $t = 24, At = typeof window < "u" ? Rt : Dt;
|
|
92
|
-
function ze(...e) {
|
|
93
|
-
return (...n) => {
|
|
94
|
-
for (let t of e)
|
|
95
|
-
typeof t == "function" && t(...n);
|
|
96
|
-
};
|
|
97
|
-
}
|
|
98
|
-
const xe = typeof document < "u" && window.visualViewport;
|
|
99
|
-
function Ve(e) {
|
|
100
|
-
let n = window.getComputedStyle(e);
|
|
101
|
-
return /(auto|scroll)/.test(n.overflow + n.overflowX + n.overflowY);
|
|
102
|
-
}
|
|
103
|
-
function Ke(e) {
|
|
104
|
-
for (Ve(e) && (e = e.parentElement); e && !Ve(e); )
|
|
105
|
-
e = e.parentElement;
|
|
106
|
-
return e || document.scrollingElement || document.documentElement;
|
|
107
|
-
}
|
|
108
|
-
const Nt = /* @__PURE__ */ new Set([
|
|
109
|
-
"checkbox",
|
|
110
|
-
"radio",
|
|
111
|
-
"range",
|
|
112
|
-
"color",
|
|
113
|
-
"file",
|
|
114
|
-
"image",
|
|
115
|
-
"button",
|
|
116
|
-
"submit",
|
|
117
|
-
"reset"
|
|
118
|
-
]);
|
|
119
|
-
let ve = 0, Oe;
|
|
120
|
-
function Mt(e = {}) {
|
|
121
|
-
let { isDisabled: n } = e;
|
|
122
|
-
At(() => {
|
|
123
|
-
if (!n)
|
|
124
|
-
return ve++, ve === 1 && Xe() && (Oe = Pt()), () => {
|
|
125
|
-
ve--, ve === 0 && (Oe == null || Oe());
|
|
126
|
-
};
|
|
127
|
-
}, [
|
|
128
|
-
n
|
|
129
|
-
]);
|
|
130
|
-
}
|
|
131
|
-
function Pt() {
|
|
132
|
-
let e, n = 0, t = (m) => {
|
|
133
|
-
e = Ke(m.target), !(e === document.documentElement && e === document.body) && (n = m.changedTouches[0].pageY);
|
|
134
|
-
}, a = (m) => {
|
|
135
|
-
if (!e || e === document.documentElement || e === document.body) {
|
|
136
|
-
m.preventDefault();
|
|
137
|
-
return;
|
|
138
|
-
}
|
|
139
|
-
let p = m.changedTouches[0].pageY, B = e.scrollTop, k = e.scrollHeight - e.clientHeight;
|
|
140
|
-
k !== 0 && ((B <= 0 && p > n || B >= k && p < n) && m.preventDefault(), n = p);
|
|
141
|
-
}, i = (m) => {
|
|
142
|
-
let p = m.target;
|
|
143
|
-
Ae(p) && p !== document.activeElement && (m.preventDefault(), p.style.transform = "translateY(-2000px)", p.focus(), requestAnimationFrame(() => {
|
|
144
|
-
p.style.transform = "";
|
|
145
|
-
}));
|
|
146
|
-
}, o = (m) => {
|
|
147
|
-
let p = m.target;
|
|
148
|
-
Ae(p) && (p.style.transform = "translateY(-2000px)", requestAnimationFrame(() => {
|
|
149
|
-
p.style.transform = "", xe && (xe.height < window.innerHeight ? requestAnimationFrame(() => {
|
|
150
|
-
Ye(p);
|
|
151
|
-
}) : xe.addEventListener("resize", () => Ye(p), {
|
|
152
|
-
once: !0
|
|
153
|
-
}));
|
|
154
|
-
}));
|
|
155
|
-
}, g = () => {
|
|
156
|
-
window.scrollTo(0, 0);
|
|
157
|
-
}, u = window.pageXOffset, b = window.pageYOffset, T = ze(It(document.documentElement, "paddingRight", `${window.innerWidth - document.documentElement.clientWidth}px`));
|
|
158
|
-
window.scrollTo(0, 0);
|
|
159
|
-
let h = ze(fe(document, "touchstart", t, {
|
|
160
|
-
passive: !1,
|
|
161
|
-
capture: !0
|
|
162
|
-
}), fe(document, "touchmove", a, {
|
|
163
|
-
passive: !1,
|
|
164
|
-
capture: !0
|
|
165
|
-
}), fe(document, "touchend", i, {
|
|
166
|
-
passive: !1,
|
|
167
|
-
capture: !0
|
|
168
|
-
}), fe(document, "focus", o, !0), fe(window, "scroll", g));
|
|
169
|
-
return () => {
|
|
170
|
-
T(), h(), window.scrollTo(u, b);
|
|
171
|
-
};
|
|
172
|
-
}
|
|
173
|
-
function It(e, n, t) {
|
|
174
|
-
let a = e.style[n];
|
|
175
|
-
return e.style[n] = t, () => {
|
|
176
|
-
e.style[n] = a;
|
|
177
|
-
};
|
|
178
|
-
}
|
|
179
|
-
function fe(e, n, t, a) {
|
|
180
|
-
return e.addEventListener(n, t, a), () => {
|
|
181
|
-
e.removeEventListener(n, t, a);
|
|
182
|
-
};
|
|
183
|
-
}
|
|
184
|
-
function Ye(e) {
|
|
185
|
-
let n = document.scrollingElement || document.documentElement;
|
|
186
|
-
for (; e && e !== n; ) {
|
|
187
|
-
let t = Ke(e);
|
|
188
|
-
if (t !== document.documentElement && t !== document.body && t !== e) {
|
|
189
|
-
let a = t.getBoundingClientRect().top, i = e.getBoundingClientRect().top, o = e.getBoundingClientRect().bottom;
|
|
190
|
-
const g = t.getBoundingClientRect().bottom + $t;
|
|
191
|
-
o > g && (t.scrollTop += i - a);
|
|
192
|
-
}
|
|
193
|
-
e = t.parentElement;
|
|
194
|
-
}
|
|
195
|
-
}
|
|
196
|
-
function Ae(e) {
|
|
197
|
-
return e instanceof HTMLInputElement && !Nt.has(e.type) || e instanceof HTMLTextAreaElement || e instanceof HTMLElement && e.isContentEditable;
|
|
198
|
-
}
|
|
199
|
-
function _t(e, n) {
|
|
200
|
-
typeof e == "function" ? e(n) : e != null && (e.current = n);
|
|
201
|
-
}
|
|
202
|
-
function Ht(...e) {
|
|
203
|
-
return (n) => e.forEach((t) => _t(t, n));
|
|
204
|
-
}
|
|
205
|
-
function Ge(...e) {
|
|
206
|
-
return pe.useCallback(Ht(...e), e);
|
|
207
|
-
}
|
|
208
|
-
const Je = /* @__PURE__ */ new WeakMap();
|
|
209
|
-
function $(e, n, t = !1) {
|
|
210
|
-
if (!e || !(e instanceof HTMLElement)) return;
|
|
211
|
-
let a = {};
|
|
212
|
-
Object.entries(n).forEach(([i, o]) => {
|
|
213
|
-
if (i.startsWith("--")) {
|
|
214
|
-
e.style.setProperty(i, o);
|
|
215
|
-
return;
|
|
216
|
-
}
|
|
217
|
-
a[i] = e.style[i], e.style[i] = o;
|
|
218
|
-
}), !t && Je.set(e, a);
|
|
219
|
-
}
|
|
220
|
-
function kt(e, n) {
|
|
221
|
-
if (!e || !(e instanceof HTMLElement)) return;
|
|
222
|
-
let t = Je.get(e);
|
|
223
|
-
t && (e.style[n] = t[n]);
|
|
224
|
-
}
|
|
225
|
-
const C = (e) => {
|
|
226
|
-
switch (e) {
|
|
227
|
-
case "top":
|
|
228
|
-
case "bottom":
|
|
229
|
-
return !0;
|
|
230
|
-
case "left":
|
|
231
|
-
case "right":
|
|
232
|
-
return !1;
|
|
233
|
-
default:
|
|
234
|
-
return e;
|
|
235
|
-
}
|
|
236
|
-
};
|
|
237
|
-
function ye(e, n) {
|
|
238
|
-
if (!e)
|
|
239
|
-
return null;
|
|
240
|
-
const t = window.getComputedStyle(e), a = (
|
|
241
|
-
// @ts-ignore
|
|
242
|
-
t.transform || t.webkitTransform || t.mozTransform
|
|
243
|
-
);
|
|
244
|
-
let i = a.match(/^matrix3d\((.+)\)$/);
|
|
245
|
-
return i ? parseFloat(i[1].split(", ")[C(n) ? 13 : 12]) : (i = a.match(/^matrix\((.+)\)$/), i ? parseFloat(i[1].split(", ")[C(n) ? 5 : 4]) : null);
|
|
246
|
-
}
|
|
247
|
-
function Lt(e) {
|
|
248
|
-
return 8 * (Math.log(e + 1) - 2);
|
|
249
|
-
}
|
|
250
|
-
function Ce(e, n) {
|
|
251
|
-
if (!e) return () => {
|
|
252
|
-
};
|
|
253
|
-
const t = e.style.cssText;
|
|
254
|
-
return Object.assign(e.style, n), () => {
|
|
255
|
-
e.style.cssText = t;
|
|
256
|
-
};
|
|
257
|
-
}
|
|
258
|
-
function Bt(...e) {
|
|
259
|
-
return (...n) => {
|
|
260
|
-
for (const t of e)
|
|
261
|
-
typeof t == "function" && t(...n);
|
|
262
|
-
};
|
|
263
|
-
}
|
|
264
|
-
const x = {
|
|
265
|
-
DURATION: 0.5,
|
|
266
|
-
EASE: [
|
|
267
|
-
0.32,
|
|
268
|
-
0.72,
|
|
269
|
-
0,
|
|
270
|
-
1
|
|
271
|
-
]
|
|
272
|
-
}, Qe = 0.4, Ft = 0.25, Ut = 100, Ze = 8, be = 16, Ne = 26, $e = "vaul-dragging";
|
|
273
|
-
function et(e) {
|
|
274
|
-
const n = r.useRef(e);
|
|
275
|
-
return r.useEffect(() => {
|
|
276
|
-
n.current = e;
|
|
277
|
-
}), r.useMemo(() => (...t) => n.current == null ? void 0 : n.current.call(n, ...t), []);
|
|
278
|
-
}
|
|
279
|
-
function jt({ defaultProp: e, onChange: n }) {
|
|
280
|
-
const t = r.useState(e), [a] = t, i = r.useRef(a), o = et(n);
|
|
281
|
-
return r.useEffect(() => {
|
|
282
|
-
i.current !== a && (o(a), i.current = a);
|
|
283
|
-
}, [
|
|
284
|
-
a,
|
|
285
|
-
i,
|
|
286
|
-
o
|
|
287
|
-
]), t;
|
|
288
|
-
}
|
|
289
|
-
function tt({ prop: e, defaultProp: n, onChange: t = () => {
|
|
290
|
-
} }) {
|
|
291
|
-
const [a, i] = jt({
|
|
292
|
-
defaultProp: n,
|
|
293
|
-
onChange: t
|
|
294
|
-
}), o = e !== void 0, g = o ? e : a, u = et(t), b = r.useCallback((T) => {
|
|
295
|
-
if (o) {
|
|
296
|
-
const m = typeof T == "function" ? T(e) : T;
|
|
297
|
-
m !== e && u(m);
|
|
298
|
-
} else
|
|
299
|
-
i(T);
|
|
300
|
-
}, [
|
|
301
|
-
o,
|
|
302
|
-
e,
|
|
303
|
-
i,
|
|
304
|
-
u
|
|
305
|
-
]);
|
|
306
|
-
return [
|
|
307
|
-
g,
|
|
308
|
-
b
|
|
309
|
-
];
|
|
310
|
-
}
|
|
311
|
-
function Wt({ activeSnapPointProp: e, setActiveSnapPointProp: n, snapPoints: t, drawerRef: a, overlayRef: i, fadeFromIndex: o, onSnapPointChange: g, direction: u = "bottom", container: b, snapToSequentialPoint: T }) {
|
|
312
|
-
const [h, m] = tt({
|
|
313
|
-
prop: e,
|
|
314
|
-
defaultProp: t == null ? void 0 : t[0],
|
|
315
|
-
onChange: n
|
|
316
|
-
}), [p, B] = r.useState(typeof window < "u" ? {
|
|
317
|
-
innerWidth: window.innerWidth,
|
|
318
|
-
innerHeight: window.innerHeight
|
|
319
|
-
} : void 0);
|
|
320
|
-
r.useEffect(() => {
|
|
321
|
-
function c() {
|
|
322
|
-
B({
|
|
323
|
-
innerWidth: window.innerWidth,
|
|
324
|
-
innerHeight: window.innerHeight
|
|
325
|
-
});
|
|
326
|
-
}
|
|
327
|
-
return window.addEventListener("resize", c), () => window.removeEventListener("resize", c);
|
|
328
|
-
}, []);
|
|
329
|
-
const k = r.useMemo(() => h === (t == null ? void 0 : t[t.length - 1]) || null, [
|
|
330
|
-
t,
|
|
331
|
-
h
|
|
332
|
-
]), E = r.useMemo(() => {
|
|
333
|
-
var c;
|
|
334
|
-
return (c = t == null ? void 0 : t.findIndex((S) => S === h)) != null ? c : null;
|
|
335
|
-
}, [
|
|
336
|
-
t,
|
|
337
|
-
h
|
|
338
|
-
]), F = t && t.length > 0 && (o || o === 0) && !Number.isNaN(o) && t[o] === h || !t, w = r.useMemo(() => {
|
|
339
|
-
const c = b ? {
|
|
340
|
-
width: b.getBoundingClientRect().width,
|
|
341
|
-
height: b.getBoundingClientRect().height
|
|
342
|
-
} : typeof window < "u" ? {
|
|
343
|
-
width: window.innerWidth,
|
|
344
|
-
height: window.innerHeight
|
|
345
|
-
} : {
|
|
346
|
-
width: 0,
|
|
347
|
-
height: 0
|
|
348
|
-
};
|
|
349
|
-
var S;
|
|
350
|
-
return (S = t == null ? void 0 : t.map((y) => {
|
|
351
|
-
const I = typeof y == "string";
|
|
352
|
-
let M = 0;
|
|
353
|
-
if (I && (M = parseInt(y, 10)), C(u)) {
|
|
354
|
-
const l = I ? M : p ? y * c.height : 0;
|
|
355
|
-
return p ? u === "bottom" ? c.height - l : -c.height + l : l;
|
|
356
|
-
}
|
|
357
|
-
const j = I ? M : p ? y * c.width : 0;
|
|
358
|
-
return p ? u === "right" ? c.width - j : -c.width + j : j;
|
|
359
|
-
})) != null ? S : [];
|
|
360
|
-
}, [
|
|
361
|
-
t,
|
|
362
|
-
p,
|
|
363
|
-
b
|
|
364
|
-
]), N = r.useMemo(() => E !== null ? w == null ? void 0 : w[E] : null, [
|
|
365
|
-
w,
|
|
366
|
-
E
|
|
367
|
-
]), A = r.useCallback((c) => {
|
|
368
|
-
var S;
|
|
369
|
-
const y = (S = w == null ? void 0 : w.findIndex((I) => I === c)) != null ? S : null;
|
|
370
|
-
g(y), $(a.current, {
|
|
371
|
-
transition: `transform ${x.DURATION}s cubic-bezier(${x.EASE.join(",")})`,
|
|
372
|
-
transform: C(u) ? `translate3d(0, ${c}px, 0)` : `translate3d(${c}px, 0, 0)`
|
|
373
|
-
}), w && y !== w.length - 1 && o !== void 0 && y !== o && y < o ? $(i.current, {
|
|
374
|
-
transition: `opacity ${x.DURATION}s cubic-bezier(${x.EASE.join(",")})`,
|
|
375
|
-
opacity: "0"
|
|
376
|
-
}) : $(i.current, {
|
|
377
|
-
transition: `opacity ${x.DURATION}s cubic-bezier(${x.EASE.join(",")})`,
|
|
378
|
-
opacity: "1"
|
|
379
|
-
}), m(t == null ? void 0 : t[Math.max(y, 0)]);
|
|
380
|
-
}, [
|
|
381
|
-
a.current,
|
|
382
|
-
t,
|
|
383
|
-
w,
|
|
384
|
-
o,
|
|
385
|
-
i,
|
|
386
|
-
m
|
|
387
|
-
]);
|
|
388
|
-
r.useEffect(() => {
|
|
389
|
-
if (h || e) {
|
|
390
|
-
var c;
|
|
391
|
-
const S = (c = t == null ? void 0 : t.findIndex((y) => y === e || y === h)) != null ? c : -1;
|
|
392
|
-
w && S !== -1 && typeof w[S] == "number" && A(w[S]);
|
|
393
|
-
}
|
|
394
|
-
}, [
|
|
395
|
-
h,
|
|
396
|
-
e,
|
|
397
|
-
t,
|
|
398
|
-
w,
|
|
399
|
-
A
|
|
400
|
-
]);
|
|
401
|
-
function d({ draggedDistance: c, closeDrawer: S, velocity: y, dismissible: I }) {
|
|
402
|
-
if (o === void 0) return;
|
|
403
|
-
const M = u === "bottom" || u === "right" ? (N ?? 0) - c : (N ?? 0) + c, j = E === o - 1, l = E === 0, U = c > 0;
|
|
404
|
-
if (j && $(i.current, {
|
|
405
|
-
transition: `opacity ${x.DURATION}s cubic-bezier(${x.EASE.join(",")})`
|
|
406
|
-
}), !T && y > 2 && !U) {
|
|
407
|
-
I ? S() : A(w[0]);
|
|
408
|
-
return;
|
|
409
|
-
}
|
|
410
|
-
if (!T && y > 2 && U && w && t) {
|
|
411
|
-
A(w[t.length - 1]);
|
|
412
|
-
return;
|
|
413
|
-
}
|
|
414
|
-
const _ = w == null ? void 0 : w.reduce((P, K) => typeof P != "number" || typeof K != "number" ? P : Math.abs(K - M) < Math.abs(P - M) ? K : P), W = C(u) ? window.innerHeight : window.innerWidth;
|
|
415
|
-
if (y > Qe && Math.abs(c) < W * 0.4) {
|
|
416
|
-
const P = U ? 1 : -1;
|
|
417
|
-
if (P > 0 && k && t) {
|
|
418
|
-
A(w[t.length - 1]);
|
|
419
|
-
return;
|
|
420
|
-
}
|
|
421
|
-
if (l && P < 0 && I && S(), E === null) return;
|
|
422
|
-
A(w[E + P]);
|
|
423
|
-
return;
|
|
424
|
-
}
|
|
425
|
-
A(_);
|
|
426
|
-
}
|
|
427
|
-
function Y({ draggedDistance: c }) {
|
|
428
|
-
if (N === null) return;
|
|
429
|
-
const S = u === "bottom" || u === "right" ? N - c : N + c;
|
|
430
|
-
(u === "bottom" || u === "right") && S < w[w.length - 1] || (u === "top" || u === "left") && S > w[w.length - 1] || $(a.current, {
|
|
431
|
-
transform: C(u) ? `translate3d(0, ${S}px, 0)` : `translate3d(${S}px, 0, 0)`
|
|
432
|
-
});
|
|
433
|
-
}
|
|
434
|
-
function ee(c, S) {
|
|
435
|
-
if (!t || typeof E != "number" || !w || o === void 0) return null;
|
|
436
|
-
const y = E === o - 1;
|
|
437
|
-
if (E >= o && S)
|
|
438
|
-
return 0;
|
|
439
|
-
if (y && !S) return 1;
|
|
440
|
-
if (!F && !y) return null;
|
|
441
|
-
const M = y ? E + 1 : E - 1, j = y ? w[M] - w[M - 1] : w[M + 1] - w[M], l = c / Math.abs(j);
|
|
442
|
-
return y ? 1 - l : l;
|
|
443
|
-
}
|
|
444
|
-
return {
|
|
445
|
-
isLastSnapPoint: k,
|
|
446
|
-
activeSnapPoint: h,
|
|
447
|
-
shouldFade: F,
|
|
448
|
-
getPercentageDragged: ee,
|
|
449
|
-
setActiveSnapPoint: m,
|
|
450
|
-
activeSnapPointIndex: E,
|
|
451
|
-
onRelease: d,
|
|
452
|
-
onDrag: Y,
|
|
453
|
-
snapPointsOffset: w
|
|
454
|
-
};
|
|
455
|
-
}
|
|
456
|
-
const zt = () => () => {
|
|
457
|
-
};
|
|
458
|
-
function Vt() {
|
|
459
|
-
const { direction: e, isOpen: n, shouldScaleBackground: t, setBackgroundColorOnScale: a, noBodyStyles: i } = ie(), o = r.useRef(null), g = St(() => document.body.style.backgroundColor, []);
|
|
460
|
-
function u() {
|
|
461
|
-
return (window.innerWidth - Ne) / window.innerWidth;
|
|
462
|
-
}
|
|
463
|
-
r.useEffect(() => {
|
|
464
|
-
if (n && t) {
|
|
465
|
-
o.current && clearTimeout(o.current);
|
|
466
|
-
const b = document.querySelector("[data-vaul-drawer-wrapper]") || document.querySelector("[vaul-drawer-wrapper]");
|
|
467
|
-
if (!b) return;
|
|
468
|
-
Bt(a && !i ? Ce(document.body, {
|
|
469
|
-
background: "black"
|
|
470
|
-
}) : zt, Ce(b, {
|
|
471
|
-
transformOrigin: C(e) ? "top" : "left",
|
|
472
|
-
transitionProperty: "transform, border-radius",
|
|
473
|
-
transitionDuration: `${x.DURATION}s`,
|
|
474
|
-
transitionTimingFunction: `cubic-bezier(${x.EASE.join(",")})`
|
|
475
|
-
}));
|
|
476
|
-
const T = Ce(b, {
|
|
477
|
-
borderRadius: `${Ze}px`,
|
|
478
|
-
overflow: "hidden",
|
|
479
|
-
...C(e) ? {
|
|
480
|
-
transform: `scale(${u()}) translate3d(0, calc(env(safe-area-inset-top) + 14px), 0)`
|
|
481
|
-
} : {
|
|
482
|
-
transform: `scale(${u()}) translate3d(calc(env(safe-area-inset-top) + 14px), 0, 0)`
|
|
483
|
-
}
|
|
484
|
-
});
|
|
485
|
-
return () => {
|
|
486
|
-
T(), o.current = window.setTimeout(() => {
|
|
487
|
-
g ? document.body.style.background = g : document.body.style.removeProperty("background");
|
|
488
|
-
}, x.DURATION * 1e3);
|
|
489
|
-
};
|
|
490
|
-
}
|
|
491
|
-
}, [
|
|
492
|
-
n,
|
|
493
|
-
t,
|
|
494
|
-
g
|
|
495
|
-
]);
|
|
496
|
-
}
|
|
497
|
-
let me = null;
|
|
498
|
-
function Yt({ isOpen: e, modal: n, nested: t, hasBeenOpened: a, preventScrollRestoration: i, noBodyStyles: o }) {
|
|
499
|
-
const [g, u] = r.useState(() => typeof window < "u" ? window.location.href : ""), b = r.useRef(0), T = r.useCallback(() => {
|
|
500
|
-
if (We() && me === null && e && !o) {
|
|
501
|
-
me = {
|
|
502
|
-
position: document.body.style.position,
|
|
503
|
-
top: document.body.style.top,
|
|
504
|
-
left: document.body.style.left,
|
|
505
|
-
height: document.body.style.height,
|
|
506
|
-
right: "unset"
|
|
507
|
-
};
|
|
508
|
-
const { scrollX: m, innerHeight: p } = window;
|
|
509
|
-
document.body.style.setProperty("position", "fixed", "important"), Object.assign(document.body.style, {
|
|
510
|
-
top: `${-b.current}px`,
|
|
511
|
-
left: `${-m}px`,
|
|
512
|
-
right: "0px",
|
|
513
|
-
height: "auto"
|
|
514
|
-
}), window.setTimeout(() => window.requestAnimationFrame(() => {
|
|
515
|
-
const B = p - window.innerHeight;
|
|
516
|
-
B && b.current >= p && (document.body.style.top = `${-(b.current + B)}px`);
|
|
517
|
-
}), 300);
|
|
518
|
-
}
|
|
519
|
-
}, [
|
|
520
|
-
e
|
|
521
|
-
]), h = r.useCallback(() => {
|
|
522
|
-
if (We() && me !== null && !o) {
|
|
523
|
-
const m = -parseInt(document.body.style.top, 10), p = -parseInt(document.body.style.left, 10);
|
|
524
|
-
Object.assign(document.body.style, me), window.requestAnimationFrame(() => {
|
|
525
|
-
if (i && g !== window.location.href) {
|
|
526
|
-
u(window.location.href);
|
|
527
|
-
return;
|
|
528
|
-
}
|
|
529
|
-
window.scrollTo(p, m);
|
|
530
|
-
}), me = null;
|
|
531
|
-
}
|
|
532
|
-
}, [
|
|
533
|
-
g
|
|
534
|
-
]);
|
|
535
|
-
return r.useEffect(() => {
|
|
536
|
-
function m() {
|
|
537
|
-
b.current = window.scrollY;
|
|
538
|
-
}
|
|
539
|
-
return m(), window.addEventListener("scroll", m), () => {
|
|
540
|
-
window.removeEventListener("scroll", m);
|
|
541
|
-
};
|
|
542
|
-
}, []), r.useEffect(() => {
|
|
543
|
-
if (n)
|
|
544
|
-
return () => {
|
|
545
|
-
typeof document > "u" || document.querySelector("[data-vaul-drawer]") || h();
|
|
546
|
-
};
|
|
547
|
-
}, [
|
|
548
|
-
n,
|
|
549
|
-
h
|
|
550
|
-
]), r.useEffect(() => {
|
|
551
|
-
t || !a || (e ? (!window.matchMedia("(display-mode: standalone)").matches && T(), n || window.setTimeout(() => {
|
|
552
|
-
h();
|
|
553
|
-
}, 500)) : h());
|
|
554
|
-
}, [
|
|
555
|
-
e,
|
|
556
|
-
a,
|
|
557
|
-
g,
|
|
558
|
-
n,
|
|
559
|
-
t,
|
|
560
|
-
T,
|
|
561
|
-
h
|
|
562
|
-
]), {
|
|
563
|
-
restorePositionSetting: h
|
|
564
|
-
};
|
|
565
|
-
}
|
|
566
|
-
function nt({ open: e, onOpenChange: n, children: t, onDrag: a, onRelease: i, snapPoints: o, shouldScaleBackground: g = !1, setBackgroundColorOnScale: u = !0, closeThreshold: b = Ft, scrollLockTimeout: T = Ut, dismissible: h = !0, handleOnly: m = !1, fadeFromIndex: p = o && o.length - 1, activeSnapPoint: B, setActiveSnapPoint: k, fixed: E, modal: F = !0, onClose: w, nested: N, noBodyStyles: A = !1, direction: d = "bottom", defaultOpen: Y = !1, disablePreventScroll: ee = !0, snapToSequentialPoint: c = !1, preventScrollRestoration: S = !1, repositionInputs: y = !0, onAnimationEnd: I, container: M, autoFocus: j = !1 }) {
|
|
567
|
-
var l, U;
|
|
568
|
-
const [_ = !1, W] = tt({
|
|
569
|
-
defaultProp: Y,
|
|
570
|
-
prop: e,
|
|
571
|
-
onChange: (s) => {
|
|
572
|
-
n == null || n(s), !s && !N && mt(), setTimeout(() => {
|
|
573
|
-
I == null || I(s);
|
|
574
|
-
}, x.DURATION * 1e3), s && !F && typeof window < "u" && window.requestAnimationFrame(() => {
|
|
575
|
-
document.body.style.pointerEvents = "auto";
|
|
576
|
-
}), s || (document.body.style.pointerEvents = "auto");
|
|
577
|
-
}
|
|
578
|
-
}), [P, K] = r.useState(!1), [G, se] = r.useState(!1), [st, Pe] = r.useState(!1), ne = r.useRef(null), we = r.useRef(null), Se = r.useRef(null), Re = r.useRef(null), le = r.useRef(null), ue = r.useRef(!1), De = r.useRef(null), Te = r.useRef(0), re = r.useRef(!1), Ie = r.useRef(!Y), _e = r.useRef(0), f = r.useRef(null), He = r.useRef(((l = f.current) == null ? void 0 : l.getBoundingClientRect().height) || 0), ke = r.useRef(((U = f.current) == null ? void 0 : U.getBoundingClientRect().width) || 0), Ee = r.useRef(0), lt = r.useCallback((s) => {
|
|
579
|
-
o && s === ce.length - 1 && (we.current = /* @__PURE__ */ new Date());
|
|
580
|
-
}, []), { activeSnapPoint: ut, activeSnapPointIndex: ae, setActiveSnapPoint: Le, onRelease: ct, snapPointsOffset: ce, onDrag: dt, shouldFade: Be, getPercentageDragged: ft } = Wt({
|
|
581
|
-
snapPoints: o,
|
|
582
|
-
activeSnapPointProp: B,
|
|
583
|
-
setActiveSnapPointProp: k,
|
|
584
|
-
drawerRef: f,
|
|
585
|
-
fadeFromIndex: p,
|
|
586
|
-
overlayRef: ne,
|
|
587
|
-
onSnapPointChange: lt,
|
|
588
|
-
direction: d,
|
|
589
|
-
container: M,
|
|
590
|
-
snapToSequentialPoint: c
|
|
591
|
-
});
|
|
592
|
-
Mt({
|
|
593
|
-
isDisabled: !_ || G || !F || st || !P || !y || !ee
|
|
594
|
-
});
|
|
595
|
-
const { restorePositionSetting: mt } = Yt({
|
|
596
|
-
isOpen: _,
|
|
597
|
-
modal: F,
|
|
598
|
-
nested: N ?? !1,
|
|
599
|
-
hasBeenOpened: P,
|
|
600
|
-
preventScrollRestoration: S,
|
|
601
|
-
noBodyStyles: A
|
|
602
|
-
});
|
|
603
|
-
function he() {
|
|
604
|
-
return (window.innerWidth - Ne) / window.innerWidth;
|
|
605
|
-
}
|
|
606
|
-
function pt(s) {
|
|
607
|
-
var R, D;
|
|
608
|
-
!h && !o || f.current && !f.current.contains(s.target) || (He.current = ((R = f.current) == null ? void 0 : R.getBoundingClientRect().height) || 0, ke.current = ((D = f.current) == null ? void 0 : D.getBoundingClientRect().width) || 0, se(!0), Se.current = /* @__PURE__ */ new Date(), Xe() && window.addEventListener("touchend", () => ue.current = !1, {
|
|
609
|
-
once: !0
|
|
610
|
-
}), s.target.setPointerCapture(s.pointerId), Te.current = C(d) ? s.pageY : s.pageX);
|
|
611
|
-
}
|
|
612
|
-
function Fe(s, R) {
|
|
613
|
-
var D;
|
|
614
|
-
let v = s;
|
|
615
|
-
const O = (D = window.getSelection()) == null ? void 0 : D.toString(), L = f.current ? ye(f.current, d) : null, H = /* @__PURE__ */ new Date();
|
|
616
|
-
if (v.tagName === "SELECT" || v.hasAttribute("data-vaul-no-drag") || v.closest("[data-vaul-no-drag]"))
|
|
617
|
-
return !1;
|
|
618
|
-
if (d === "right" || d === "left")
|
|
619
|
-
return !0;
|
|
620
|
-
if (we.current && H.getTime() - we.current.getTime() < 500)
|
|
621
|
-
return !1;
|
|
622
|
-
if (L !== null && (d === "bottom" ? L > 0 : L < 0))
|
|
623
|
-
return !0;
|
|
624
|
-
if (O && O.length > 0)
|
|
625
|
-
return !1;
|
|
626
|
-
if (le.current && H.getTime() - le.current.getTime() < T && L === 0 || R)
|
|
627
|
-
return le.current = H, !1;
|
|
628
|
-
for (; v; ) {
|
|
629
|
-
if (v.scrollHeight > v.clientHeight) {
|
|
630
|
-
if (v.scrollTop !== 0)
|
|
631
|
-
return le.current = /* @__PURE__ */ new Date(), !1;
|
|
632
|
-
if (v.getAttribute("role") === "dialog")
|
|
633
|
-
return !0;
|
|
634
|
-
}
|
|
635
|
-
v = v.parentNode;
|
|
636
|
-
}
|
|
637
|
-
return !0;
|
|
638
|
-
}
|
|
639
|
-
function wt(s) {
|
|
640
|
-
if (f.current && G) {
|
|
641
|
-
const R = d === "bottom" || d === "right" ? 1 : -1, D = (Te.current - (C(d) ? s.pageY : s.pageX)) * R, v = D > 0, O = o && !h && !v;
|
|
642
|
-
if (O && ae === 0) return;
|
|
643
|
-
const L = Math.abs(D), H = document.querySelector("[data-vaul-drawer-wrapper]"), J = d === "bottom" || d === "top" ? He.current : ke.current;
|
|
644
|
-
let z = L / J;
|
|
645
|
-
const te = ft(L, v);
|
|
646
|
-
if (te !== null && (z = te), O && z >= 1 || !ue.current && !Fe(s.target, v)) return;
|
|
647
|
-
if (f.current.classList.add($e), ue.current = !0, $(f.current, {
|
|
648
|
-
transition: "none"
|
|
649
|
-
}), $(ne.current, {
|
|
650
|
-
transition: "none"
|
|
651
|
-
}), o && dt({
|
|
652
|
-
draggedDistance: D
|
|
653
|
-
}), v && !o) {
|
|
654
|
-
const q = Lt(D), ge = Math.min(q * -1, 0) * R;
|
|
655
|
-
$(f.current, {
|
|
656
|
-
transform: C(d) ? `translate3d(0, ${ge}px, 0)` : `translate3d(${ge}px, 0, 0)`
|
|
657
|
-
});
|
|
658
|
-
return;
|
|
659
|
-
}
|
|
660
|
-
const Q = 1 - z;
|
|
661
|
-
if ((Be || p && ae === p - 1) && (a == null || a(s, z), $(ne.current, {
|
|
662
|
-
opacity: `${Q}`,
|
|
663
|
-
transition: "none"
|
|
664
|
-
}, !0)), H && ne.current && g) {
|
|
665
|
-
const q = Math.min(he() + z * (1 - he()), 1), ge = 8 - z * 8, je = Math.max(0, 14 - z * 14);
|
|
666
|
-
$(H, {
|
|
667
|
-
borderRadius: `${ge}px`,
|
|
668
|
-
transform: C(d) ? `scale(${q}) translate3d(0, ${je}px, 0)` : `scale(${q}) translate3d(${je}px, 0, 0)`,
|
|
669
|
-
transition: "none"
|
|
670
|
-
}, !0);
|
|
671
|
-
}
|
|
672
|
-
if (!o) {
|
|
673
|
-
const q = L * R;
|
|
674
|
-
$(f.current, {
|
|
675
|
-
transform: C(d) ? `translate3d(0, ${q}px, 0)` : `translate3d(${q}px, 0, 0)`
|
|
676
|
-
});
|
|
677
|
-
}
|
|
678
|
-
}
|
|
679
|
-
}
|
|
680
|
-
r.useEffect(() => {
|
|
681
|
-
window.requestAnimationFrame(() => {
|
|
682
|
-
Ie.current = !0;
|
|
683
|
-
});
|
|
684
|
-
}, []), r.useEffect(() => {
|
|
685
|
-
var s;
|
|
686
|
-
function R() {
|
|
687
|
-
if (!f.current || !y) return;
|
|
688
|
-
const D = document.activeElement;
|
|
689
|
-
if (Ae(D) || re.current) {
|
|
690
|
-
var v;
|
|
691
|
-
const O = ((v = window.visualViewport) == null ? void 0 : v.height) || 0, L = window.innerHeight;
|
|
692
|
-
let H = L - O;
|
|
693
|
-
const J = f.current.getBoundingClientRect().height || 0, z = J > L * 0.8;
|
|
694
|
-
Ee.current || (Ee.current = J);
|
|
695
|
-
const te = f.current.getBoundingClientRect().top;
|
|
696
|
-
if (Math.abs(_e.current - H) > 60 && (re.current = !re.current), o && o.length > 0 && ce && ae) {
|
|
697
|
-
const Q = ce[ae] || 0;
|
|
698
|
-
H += Q;
|
|
699
|
-
}
|
|
700
|
-
if (_e.current = H, J > O || re.current) {
|
|
701
|
-
const Q = f.current.getBoundingClientRect().height;
|
|
702
|
-
let q = Q;
|
|
703
|
-
Q > O && (q = O - (z ? te : Ne)), E ? f.current.style.height = `${Q - Math.max(H, 0)}px` : f.current.style.height = `${Math.max(q, O - te)}px`;
|
|
704
|
-
} else Et() || (f.current.style.height = `${Ee.current}px`);
|
|
705
|
-
o && o.length > 0 && !re.current ? f.current.style.bottom = "0px" : f.current.style.bottom = `${Math.max(H, 0)}px`;
|
|
706
|
-
}
|
|
707
|
-
}
|
|
708
|
-
return (s = window.visualViewport) == null || s.addEventListener("resize", R), () => {
|
|
709
|
-
var D;
|
|
710
|
-
return (D = window.visualViewport) == null ? void 0 : D.removeEventListener("resize", R);
|
|
711
|
-
};
|
|
712
|
-
}, [
|
|
713
|
-
ae,
|
|
714
|
-
o,
|
|
715
|
-
ce
|
|
716
|
-
]);
|
|
717
|
-
function de(s) {
|
|
718
|
-
ht(), w == null || w(), s || W(!1), setTimeout(() => {
|
|
719
|
-
o && Le(o[0]);
|
|
720
|
-
}, x.DURATION * 1e3);
|
|
721
|
-
}
|
|
722
|
-
function Ue() {
|
|
723
|
-
if (!f.current) return;
|
|
724
|
-
const s = document.querySelector("[data-vaul-drawer-wrapper]"), R = ye(f.current, d);
|
|
725
|
-
$(f.current, {
|
|
726
|
-
transform: "translate3d(0, 0, 0)",
|
|
727
|
-
transition: `transform ${x.DURATION}s cubic-bezier(${x.EASE.join(",")})`
|
|
728
|
-
}), $(ne.current, {
|
|
729
|
-
transition: `opacity ${x.DURATION}s cubic-bezier(${x.EASE.join(",")})`,
|
|
730
|
-
opacity: "1"
|
|
731
|
-
}), g && R && R > 0 && _ && $(s, {
|
|
732
|
-
borderRadius: `${Ze}px`,
|
|
733
|
-
overflow: "hidden",
|
|
734
|
-
...C(d) ? {
|
|
735
|
-
transform: `scale(${he()}) translate3d(0, calc(env(safe-area-inset-top) + 14px), 0)`,
|
|
736
|
-
transformOrigin: "top"
|
|
737
|
-
} : {
|
|
738
|
-
transform: `scale(${he()}) translate3d(calc(env(safe-area-inset-top) + 14px), 0, 0)`,
|
|
739
|
-
transformOrigin: "left"
|
|
740
|
-
},
|
|
741
|
-
transitionProperty: "transform, border-radius",
|
|
742
|
-
transitionDuration: `${x.DURATION}s`,
|
|
743
|
-
transitionTimingFunction: `cubic-bezier(${x.EASE.join(",")})`
|
|
744
|
-
}, !0);
|
|
745
|
-
}
|
|
746
|
-
function ht() {
|
|
747
|
-
!G || !f.current || (f.current.classList.remove($e), ue.current = !1, se(!1), Re.current = /* @__PURE__ */ new Date());
|
|
748
|
-
}
|
|
749
|
-
function gt(s) {
|
|
750
|
-
if (!G || !f.current) return;
|
|
751
|
-
f.current.classList.remove($e), ue.current = !1, se(!1), Re.current = /* @__PURE__ */ new Date();
|
|
752
|
-
const R = ye(f.current, d);
|
|
753
|
-
if (!s || !Fe(s.target, !1) || !R || Number.isNaN(R) || Se.current === null) return;
|
|
754
|
-
const D = Re.current.getTime() - Se.current.getTime(), v = Te.current - (C(d) ? s.pageY : s.pageX), O = Math.abs(v) / D;
|
|
755
|
-
if (O > 0.05 && (Pe(!0), setTimeout(() => {
|
|
756
|
-
Pe(!1);
|
|
757
|
-
}, 200)), o) {
|
|
758
|
-
ct({
|
|
759
|
-
draggedDistance: v * (d === "bottom" || d === "right" ? 1 : -1),
|
|
760
|
-
closeDrawer: de,
|
|
761
|
-
velocity: O,
|
|
762
|
-
dismissible: h
|
|
763
|
-
}), i == null || i(s, !0);
|
|
764
|
-
return;
|
|
765
|
-
}
|
|
766
|
-
if (d === "bottom" || d === "right" ? v > 0 : v < 0) {
|
|
767
|
-
Ue(), i == null || i(s, !0);
|
|
768
|
-
return;
|
|
769
|
-
}
|
|
770
|
-
if (O > Qe) {
|
|
771
|
-
de(), i == null || i(s, !1);
|
|
772
|
-
return;
|
|
773
|
-
}
|
|
774
|
-
var L;
|
|
775
|
-
const H = Math.min((L = f.current.getBoundingClientRect().height) != null ? L : 0, window.innerHeight);
|
|
776
|
-
var J;
|
|
777
|
-
const z = Math.min((J = f.current.getBoundingClientRect().width) != null ? J : 0, window.innerWidth), te = d === "left" || d === "right";
|
|
778
|
-
if (Math.abs(R) >= (te ? z : H) * b) {
|
|
779
|
-
de(), i == null || i(s, !1);
|
|
780
|
-
return;
|
|
781
|
-
}
|
|
782
|
-
i == null || i(s, !0), Ue();
|
|
783
|
-
}
|
|
784
|
-
r.useEffect(() => (_ && ($(document.documentElement, {
|
|
785
|
-
scrollBehavior: "auto"
|
|
786
|
-
}), we.current = /* @__PURE__ */ new Date()), () => {
|
|
787
|
-
kt(document.documentElement, "scrollBehavior");
|
|
788
|
-
}), [
|
|
789
|
-
_
|
|
790
|
-
]);
|
|
791
|
-
function vt(s) {
|
|
792
|
-
const R = s ? (window.innerWidth - be) / window.innerWidth : 1, D = s ? -16 : 0;
|
|
793
|
-
De.current && window.clearTimeout(De.current), $(f.current, {
|
|
794
|
-
transition: `transform ${x.DURATION}s cubic-bezier(${x.EASE.join(",")})`,
|
|
795
|
-
transform: C(d) ? `scale(${R}) translate3d(0, ${D}px, 0)` : `scale(${R}) translate3d(${D}px, 0, 0)`
|
|
796
|
-
}), !s && f.current && (De.current = setTimeout(() => {
|
|
797
|
-
const v = ye(f.current, d);
|
|
798
|
-
$(f.current, {
|
|
799
|
-
transition: "none",
|
|
800
|
-
transform: C(d) ? `translate3d(0, ${v}px, 0)` : `translate3d(${v}px, 0, 0)`
|
|
801
|
-
});
|
|
802
|
-
}, 500));
|
|
803
|
-
}
|
|
804
|
-
function yt(s, R) {
|
|
805
|
-
if (R < 0) return;
|
|
806
|
-
const D = (window.innerWidth - be) / window.innerWidth, v = D + R * (1 - D), O = -16 + R * be;
|
|
807
|
-
$(f.current, {
|
|
808
|
-
transform: C(d) ? `scale(${v}) translate3d(0, ${O}px, 0)` : `scale(${v}) translate3d(${O}px, 0, 0)`,
|
|
809
|
-
transition: "none"
|
|
810
|
-
});
|
|
811
|
-
}
|
|
812
|
-
function bt(s, R) {
|
|
813
|
-
const D = C(d) ? window.innerHeight : window.innerWidth, v = R ? (D - be) / D : 1, O = R ? -16 : 0;
|
|
814
|
-
R && $(f.current, {
|
|
815
|
-
transition: `transform ${x.DURATION}s cubic-bezier(${x.EASE.join(",")})`,
|
|
816
|
-
transform: C(d) ? `scale(${v}) translate3d(0, ${O}px, 0)` : `scale(${v}) translate3d(${O}px, 0, 0)`
|
|
817
|
-
});
|
|
818
|
-
}
|
|
819
|
-
return r.useEffect(() => {
|
|
820
|
-
F || window.requestAnimationFrame(() => {
|
|
821
|
-
document.body.style.pointerEvents = "auto";
|
|
822
|
-
});
|
|
823
|
-
}, [
|
|
824
|
-
F
|
|
825
|
-
]), /* @__PURE__ */ r.createElement(Z.Root, {
|
|
826
|
-
defaultOpen: Y,
|
|
827
|
-
onOpenChange: (s) => {
|
|
828
|
-
!h && !s || (s ? K(!0) : de(!0), W(s));
|
|
829
|
-
},
|
|
830
|
-
open: _
|
|
831
|
-
}, /* @__PURE__ */ r.createElement(qe.Provider, {
|
|
832
|
-
value: {
|
|
833
|
-
activeSnapPoint: ut,
|
|
834
|
-
snapPoints: o,
|
|
835
|
-
setActiveSnapPoint: Le,
|
|
836
|
-
drawerRef: f,
|
|
837
|
-
overlayRef: ne,
|
|
838
|
-
onOpenChange: n,
|
|
839
|
-
onPress: pt,
|
|
840
|
-
onRelease: gt,
|
|
841
|
-
onDrag: wt,
|
|
842
|
-
dismissible: h,
|
|
843
|
-
shouldAnimate: Ie,
|
|
844
|
-
handleOnly: m,
|
|
845
|
-
isOpen: _,
|
|
846
|
-
isDragging: G,
|
|
847
|
-
shouldFade: Be,
|
|
848
|
-
closeDrawer: de,
|
|
849
|
-
onNestedDrag: yt,
|
|
850
|
-
onNestedOpenChange: vt,
|
|
851
|
-
onNestedRelease: bt,
|
|
852
|
-
keyboardIsOpen: re,
|
|
853
|
-
modal: F,
|
|
854
|
-
snapPointsOffset: ce,
|
|
855
|
-
activeSnapPointIndex: ae,
|
|
856
|
-
direction: d,
|
|
857
|
-
shouldScaleBackground: g,
|
|
858
|
-
setBackgroundColorOnScale: u,
|
|
859
|
-
noBodyStyles: A,
|
|
860
|
-
container: M,
|
|
861
|
-
autoFocus: j
|
|
862
|
-
}
|
|
863
|
-
}, t));
|
|
864
|
-
}
|
|
865
|
-
const rt = /* @__PURE__ */ r.forwardRef(function({ ...e }, n) {
|
|
866
|
-
const { overlayRef: t, snapPoints: a, onRelease: i, shouldFade: o, isOpen: g, modal: u, shouldAnimate: b } = ie(), T = Ge(n, t), h = a && a.length > 0;
|
|
867
|
-
if (!u)
|
|
868
|
-
return null;
|
|
869
|
-
const m = r.useCallback((p) => i(p), [
|
|
870
|
-
i
|
|
871
|
-
]);
|
|
872
|
-
return /* @__PURE__ */ r.createElement(Z.Overlay, {
|
|
873
|
-
onMouseUp: m,
|
|
874
|
-
ref: T,
|
|
875
|
-
"data-vaul-overlay": "",
|
|
876
|
-
"data-vaul-snap-points": g && h ? "true" : "false",
|
|
877
|
-
"data-vaul-snap-points-overlay": g && o ? "true" : "false",
|
|
878
|
-
"data-vaul-animate": b != null && b.current ? "true" : "false",
|
|
879
|
-
...e
|
|
880
|
-
});
|
|
881
|
-
});
|
|
882
|
-
rt.displayName = "Drawer.Overlay";
|
|
883
|
-
const at = /* @__PURE__ */ r.forwardRef(function({ onPointerDownOutside: e, style: n, onOpenAutoFocus: t, ...a }, i) {
|
|
884
|
-
const { drawerRef: o, onPress: g, onRelease: u, onDrag: b, keyboardIsOpen: T, snapPointsOffset: h, activeSnapPointIndex: m, modal: p, isOpen: B, direction: k, snapPoints: E, container: F, handleOnly: w, shouldAnimate: N, autoFocus: A } = ie(), [d, Y] = r.useState(!1), ee = Ge(i, o), c = r.useRef(null), S = r.useRef(null), y = r.useRef(!1), I = E && E.length > 0;
|
|
885
|
-
Vt();
|
|
886
|
-
const M = (l, U, _ = 0) => {
|
|
887
|
-
if (y.current) return !0;
|
|
888
|
-
const W = Math.abs(l.y), P = Math.abs(l.x), K = P > W, G = [
|
|
889
|
-
"bottom",
|
|
890
|
-
"right"
|
|
891
|
-
].includes(U) ? 1 : -1;
|
|
892
|
-
if (U === "left" || U === "right") {
|
|
893
|
-
if (!(l.x * G < 0) && P >= 0 && P <= _)
|
|
894
|
-
return K;
|
|
895
|
-
} else if (!(l.y * G < 0) && W >= 0 && W <= _)
|
|
896
|
-
return !K;
|
|
897
|
-
return y.current = !0, !0;
|
|
898
|
-
};
|
|
899
|
-
r.useEffect(() => {
|
|
900
|
-
I && window.requestAnimationFrame(() => {
|
|
901
|
-
Y(!0);
|
|
902
|
-
});
|
|
903
|
-
}, []);
|
|
904
|
-
function j(l) {
|
|
905
|
-
c.current = null, y.current = !1, u(l);
|
|
906
|
-
}
|
|
907
|
-
return /* @__PURE__ */ r.createElement(Z.Content, {
|
|
908
|
-
"data-vaul-drawer-direction": k,
|
|
909
|
-
"data-vaul-drawer": "",
|
|
910
|
-
"data-vaul-delayed-snap-points": d ? "true" : "false",
|
|
911
|
-
"data-vaul-snap-points": B && I ? "true" : "false",
|
|
912
|
-
"data-vaul-custom-container": F ? "true" : "false",
|
|
913
|
-
"data-vaul-animate": N != null && N.current ? "true" : "false",
|
|
914
|
-
...a,
|
|
915
|
-
ref: ee,
|
|
916
|
-
style: h && h.length > 0 ? {
|
|
917
|
-
"--snap-point-height": `${h[m ?? 0]}px`,
|
|
918
|
-
...n
|
|
919
|
-
} : n,
|
|
920
|
-
onPointerDown: (l) => {
|
|
921
|
-
w || (a.onPointerDown == null || a.onPointerDown.call(a, l), c.current = {
|
|
922
|
-
x: l.pageX,
|
|
923
|
-
y: l.pageY
|
|
924
|
-
}, g(l));
|
|
925
|
-
},
|
|
926
|
-
onOpenAutoFocus: (l) => {
|
|
927
|
-
t == null || t(l), A || l.preventDefault();
|
|
928
|
-
},
|
|
929
|
-
onPointerDownOutside: (l) => {
|
|
930
|
-
if (e == null || e(l), !p || l.defaultPrevented) {
|
|
931
|
-
l.preventDefault();
|
|
932
|
-
return;
|
|
933
|
-
}
|
|
934
|
-
T.current && (T.current = !1);
|
|
935
|
-
},
|
|
936
|
-
onFocusOutside: (l) => {
|
|
937
|
-
if (!p) {
|
|
938
|
-
l.preventDefault();
|
|
939
|
-
return;
|
|
940
|
-
}
|
|
941
|
-
},
|
|
942
|
-
onPointerMove: (l) => {
|
|
943
|
-
if (S.current = l, w || (a.onPointerMove == null || a.onPointerMove.call(a, l), !c.current)) return;
|
|
944
|
-
const U = l.pageY - c.current.y, _ = l.pageX - c.current.x, W = l.pointerType === "touch" ? 10 : 2;
|
|
945
|
-
M({
|
|
946
|
-
x: _,
|
|
947
|
-
y: U
|
|
948
|
-
}, k, W) ? b(l) : (Math.abs(_) > W || Math.abs(U) > W) && (c.current = null);
|
|
949
|
-
},
|
|
950
|
-
onPointerUp: (l) => {
|
|
951
|
-
a.onPointerUp == null || a.onPointerUp.call(a, l), c.current = null, y.current = !1, u(l);
|
|
952
|
-
},
|
|
953
|
-
onPointerOut: (l) => {
|
|
954
|
-
a.onPointerOut == null || a.onPointerOut.call(a, l), j(S.current);
|
|
955
|
-
},
|
|
956
|
-
onContextMenu: (l) => {
|
|
957
|
-
a.onContextMenu == null || a.onContextMenu.call(a, l), S.current && j(S.current);
|
|
958
|
-
}
|
|
959
|
-
});
|
|
960
|
-
});
|
|
961
|
-
at.displayName = "Drawer.Content";
|
|
962
|
-
const qt = 250, Xt = 120, ot = /* @__PURE__ */ r.forwardRef(function({ preventCycle: e = !1, children: n, ...t }, a) {
|
|
963
|
-
const { closeDrawer: i, isDragging: o, snapPoints: g, activeSnapPoint: u, setActiveSnapPoint: b, dismissible: T, handleOnly: h, isOpen: m, onPress: p, onDrag: B } = ie(), k = r.useRef(null), E = r.useRef(!1);
|
|
964
|
-
function F() {
|
|
965
|
-
if (E.current) {
|
|
966
|
-
A();
|
|
967
|
-
return;
|
|
968
|
-
}
|
|
969
|
-
window.setTimeout(() => {
|
|
970
|
-
w();
|
|
971
|
-
}, Xt);
|
|
972
|
-
}
|
|
973
|
-
function w() {
|
|
974
|
-
if (o || e || E.current) {
|
|
975
|
-
A();
|
|
976
|
-
return;
|
|
977
|
-
}
|
|
978
|
-
if (A(), !g || g.length === 0) {
|
|
979
|
-
T || i();
|
|
980
|
-
return;
|
|
981
|
-
}
|
|
982
|
-
if (u === g[g.length - 1] && T) {
|
|
983
|
-
i();
|
|
984
|
-
return;
|
|
985
|
-
}
|
|
986
|
-
const Y = g.findIndex((c) => c === u);
|
|
987
|
-
if (Y === -1) return;
|
|
988
|
-
const ee = g[Y + 1];
|
|
989
|
-
b(ee);
|
|
990
|
-
}
|
|
991
|
-
function N() {
|
|
992
|
-
k.current = window.setTimeout(() => {
|
|
993
|
-
E.current = !0;
|
|
994
|
-
}, qt);
|
|
995
|
-
}
|
|
996
|
-
function A() {
|
|
997
|
-
k.current && window.clearTimeout(k.current), E.current = !1;
|
|
998
|
-
}
|
|
999
|
-
return /* @__PURE__ */ r.createElement("div", {
|
|
1000
|
-
onClick: F,
|
|
1001
|
-
onPointerCancel: A,
|
|
1002
|
-
onPointerDown: (d) => {
|
|
1003
|
-
h && p(d), N();
|
|
1004
|
-
},
|
|
1005
|
-
onPointerMove: (d) => {
|
|
1006
|
-
h && B(d);
|
|
1007
|
-
},
|
|
1008
|
-
// onPointerUp is already handled by the content component
|
|
1009
|
-
ref: a,
|
|
1010
|
-
"data-vaul-drawer-visible": m ? "true" : "false",
|
|
1011
|
-
"data-vaul-handle": "",
|
|
1012
|
-
"aria-hidden": "true",
|
|
1013
|
-
...t
|
|
1014
|
-
}, /* @__PURE__ */ r.createElement("span", {
|
|
1015
|
-
"data-vaul-handle-hitarea": "",
|
|
1016
|
-
"aria-hidden": "true"
|
|
1017
|
-
}, n));
|
|
1018
|
-
});
|
|
1019
|
-
ot.displayName = "Drawer.Handle";
|
|
1020
|
-
function Kt({ onDrag: e, onOpenChange: n, open: t, ...a }) {
|
|
1021
|
-
const { onNestedDrag: i, onNestedOpenChange: o, onNestedRelease: g } = ie();
|
|
1022
|
-
if (!i)
|
|
1023
|
-
throw new Error("Drawer.NestedRoot must be placed in another drawer");
|
|
1024
|
-
return /* @__PURE__ */ r.createElement(nt, {
|
|
1025
|
-
nested: !0,
|
|
1026
|
-
open: t,
|
|
1027
|
-
onClose: () => {
|
|
1028
|
-
o(!1);
|
|
1029
|
-
},
|
|
1030
|
-
onDrag: (u, b) => {
|
|
1031
|
-
i(u, b), e == null || e(u, b);
|
|
1032
|
-
},
|
|
1033
|
-
onOpenChange: (u) => {
|
|
1034
|
-
u && o(u), n == null || n(u);
|
|
1035
|
-
},
|
|
1036
|
-
onRelease: g,
|
|
1037
|
-
...a
|
|
1038
|
-
});
|
|
1039
|
-
}
|
|
1040
|
-
function Gt(e) {
|
|
1041
|
-
const n = ie(), { container: t = n.container, ...a } = e;
|
|
1042
|
-
return /* @__PURE__ */ r.createElement(Z.Portal, {
|
|
1043
|
-
container: t,
|
|
1044
|
-
...a
|
|
1045
|
-
});
|
|
1046
|
-
}
|
|
1047
|
-
const V = {
|
|
1048
|
-
Root: nt,
|
|
1049
|
-
NestedRoot: Kt,
|
|
1050
|
-
Content: at,
|
|
1051
|
-
Overlay: rt,
|
|
1052
|
-
Trigger: Z.Trigger,
|
|
1053
|
-
Portal: Gt,
|
|
1054
|
-
Handle: ot,
|
|
1055
|
-
Close: Z.Close,
|
|
1056
|
-
Title: Z.Title,
|
|
1057
|
-
Description: Z.Description
|
|
1058
|
-
}, Jt = ({
|
|
1059
|
-
shouldScaleBackground: e = !0,
|
|
1060
|
-
...n
|
|
1061
|
-
}) => /* @__PURE__ */ X.jsx(
|
|
1062
|
-
V.Root,
|
|
1063
|
-
{
|
|
1064
|
-
shouldScaleBackground: e,
|
|
1065
|
-
...n
|
|
1066
|
-
}
|
|
1067
|
-
);
|
|
1068
|
-
Jt.displayName = "Drawer";
|
|
1069
|
-
const ln = V.Trigger, Qt = V.Portal, un = V.Close, it = pe.forwardRef(({ className: e, ...n }, t) => /* @__PURE__ */ X.jsx(
|
|
1070
|
-
V.Overlay,
|
|
1071
|
-
{
|
|
1072
|
-
ref: t,
|
|
1073
|
-
className: oe("fixed inset-0 z-50 bg-black/80", e),
|
|
1074
|
-
...n
|
|
1075
|
-
}
|
|
1076
|
-
));
|
|
1077
|
-
it.displayName = V.Overlay.displayName;
|
|
1078
|
-
const Zt = pe.forwardRef(
|
|
1079
|
-
({ className: e, children: n, hideBar: t = !0, ...a }, i) => /* @__PURE__ */ X.jsxs(Qt, { children: [
|
|
1080
|
-
/* @__PURE__ */ X.jsx(it, {}),
|
|
1081
|
-
/* @__PURE__ */ X.jsxs(
|
|
1082
|
-
V.Content,
|
|
1083
|
-
{
|
|
1084
|
-
ref: i,
|
|
1085
|
-
className: oe(
|
|
1086
|
-
"fixed inset-x-0 bottom-0 z-50 mt-24 flex h-auto flex-col rounded-t-[10px] border bg-background",
|
|
1087
|
-
e
|
|
1088
|
-
),
|
|
1089
|
-
...a,
|
|
1090
|
-
children: [
|
|
1091
|
-
!t && /* @__PURE__ */ X.jsx("div", { className: "mx-auto mt-4 h-2 w-[100px] rounded-full bg-muted" }),
|
|
1092
|
-
n
|
|
1093
|
-
]
|
|
1094
|
-
}
|
|
1095
|
-
)
|
|
1096
|
-
] })
|
|
1097
|
-
);
|
|
1098
|
-
Zt.displayName = "DrawerContent";
|
|
1099
|
-
const en = ({
|
|
1100
|
-
className: e,
|
|
1101
|
-
...n
|
|
1102
|
-
}) => /* @__PURE__ */ X.jsx(
|
|
1103
|
-
"div",
|
|
1104
|
-
{
|
|
1105
|
-
className: oe("grid gap-1.5 p-4 text-center sm:text-left", e),
|
|
1106
|
-
...n
|
|
1107
|
-
}
|
|
1108
|
-
);
|
|
1109
|
-
en.displayName = "DrawerHeader";
|
|
1110
|
-
const tn = ({
|
|
1111
|
-
className: e,
|
|
1112
|
-
...n
|
|
1113
|
-
}) => /* @__PURE__ */ X.jsx(
|
|
1114
|
-
"div",
|
|
1115
|
-
{
|
|
1116
|
-
className: oe("mt-auto flex flex-col gap-2 p-4", e),
|
|
1117
|
-
...n
|
|
1118
|
-
}
|
|
1119
|
-
);
|
|
1120
|
-
tn.displayName = "DrawerFooter";
|
|
1121
|
-
const nn = pe.forwardRef(({ className: e, ...n }, t) => /* @__PURE__ */ X.jsx(
|
|
1122
|
-
V.Title,
|
|
1123
|
-
{
|
|
1124
|
-
ref: t,
|
|
1125
|
-
className: oe(
|
|
1126
|
-
"text-lg font-semibold leading-none tracking-tight",
|
|
1127
|
-
e
|
|
1128
|
-
),
|
|
1129
|
-
...n
|
|
1130
|
-
}
|
|
1131
|
-
));
|
|
1132
|
-
nn.displayName = V.Title.displayName;
|
|
1133
|
-
const rn = pe.forwardRef(({ className: e, ...n }, t) => /* @__PURE__ */ X.jsx(
|
|
1134
|
-
V.Description,
|
|
1135
|
-
{
|
|
1136
|
-
ref: t,
|
|
1137
|
-
className: oe("text-sm text-muted-foreground", e),
|
|
1138
|
-
...n
|
|
1139
|
-
}
|
|
1140
|
-
));
|
|
1141
|
-
rn.displayName = V.Description.displayName;
|
|
1
|
+
import "../jsx-runtime-C5mzlN2N.js";
|
|
2
|
+
import "react";
|
|
3
|
+
import { D as o, e as t, b as w, f as i, g as p, h as l, i as m, j as g, c as n, a as c } from "../Drawer-BzkOKwgC.js";
|
|
4
|
+
import "../cn-wvCW-ho6.js";
|
|
1142
5
|
export {
|
|
1143
|
-
|
|
1144
|
-
|
|
1145
|
-
|
|
1146
|
-
|
|
1147
|
-
|
|
1148
|
-
|
|
1149
|
-
|
|
1150
|
-
|
|
1151
|
-
|
|
1152
|
-
|
|
6
|
+
o as Drawer,
|
|
7
|
+
t as DrawerClose,
|
|
8
|
+
w as DrawerContent,
|
|
9
|
+
i as DrawerDescription,
|
|
10
|
+
p as DrawerFooter,
|
|
11
|
+
l as DrawerHeader,
|
|
12
|
+
m as DrawerOverlay,
|
|
13
|
+
g as DrawerPortal,
|
|
14
|
+
n as DrawerTitle,
|
|
15
|
+
c as DrawerTrigger
|
|
1153
16
|
};
|
|
1154
17
|
//# sourceMappingURL=Drawer.js.map
|