one 1.1.320 → 1.1.321
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/cjs/Root.js +182 -0
- package/dist/cjs/Route.js +45 -0
- package/dist/cjs/cleanUrl.js +41 -0
- package/dist/cjs/cli/label-process.js +25 -0
- package/dist/cjs/cli/main.js +46 -0
- package/dist/cjs/cli/patch.js +34 -0
- package/dist/cjs/cli/prebuild.js +34 -0
- package/dist/cjs/cli/run.js +52 -0
- package/dist/cjs/cli/runAndroid.js +34 -0
- package/dist/cjs/cli/runIos.js +34 -0
- package/dist/cjs/cli.js +220 -0
- package/dist/cjs/clientLoaderResolver.js +32 -0
- package/dist/cjs/config.js +27 -0
- package/dist/cjs/constants.js +28 -0
- package/dist/cjs/createApp.js +46 -0
- package/dist/cjs/createHandleRequest.js +138 -0
- package/dist/cjs/createRoute.js +37 -0
- package/dist/cjs/fallbackViews/Sitemap.js +82 -0
- package/dist/cjs/fallbackViews/Unmatched.js +58 -0
- package/dist/cjs/fork/NavigationContainer.js +85 -0
- package/dist/cjs/fork/createMemoryHistory.js +100 -0
- package/dist/cjs/fork/extractPathFromURL.js +62 -0
- package/dist/cjs/fork/findFocusedRoute.js +26 -0
- package/dist/cjs/fork/getPathFromState.js +265 -0
- package/dist/cjs/fork/getStateFromPath.js +381 -0
- package/dist/cjs/fork/useLinking.js +182 -0
- package/dist/cjs/fork/validatePathConfig.js +46 -0
- package/dist/cjs/getLinkingConfig.js +59 -0
- package/dist/cjs/getReactNavigationConfig.js +69 -0
- package/dist/cjs/getRoutes.js +294 -0
- package/dist/cjs/getURL.js +24 -0
- package/dist/cjs/head/Head.js +23 -0
- package/dist/cjs/head/HeadModule.js +22 -0
- package/dist/cjs/head/index.js +15 -0
- package/dist/cjs/head/types.js +14 -0
- package/dist/cjs/head/url.js +52 -0
- package/dist/cjs/hooks.js +99 -0
- package/dist/cjs/imperative-api.js +45 -0
- package/dist/cjs/import-mode/index.js +21 -0
- package/dist/cjs/import-mode/index.web.js +21 -0
- package/dist/cjs/index.js +65 -0
- package/dist/cjs/interfaces/router.js +23 -0
- package/dist/cjs/layouts/Drawer.js +24 -0
- package/dist/cjs/layouts/Stack.js +24 -0
- package/dist/cjs/layouts/Tabs.js +52 -0
- package/dist/cjs/layouts/withLayoutContext.js +77 -0
- package/dist/cjs/link/Link.js +98 -0
- package/dist/cjs/link/Redirect.js +31 -0
- package/dist/cjs/link/href.js +50 -0
- package/dist/cjs/link/linking.js +82 -0
- package/dist/cjs/link/path.js +65 -0
- package/dist/cjs/link/useLinkTo.js +42 -0
- package/dist/cjs/link/useLoadedNavigation.js +50 -0
- package/dist/cjs/matchers.js +68 -0
- package/dist/cjs/platform.js +21 -0
- package/dist/cjs/polyfills-mobile.js +26 -0
- package/dist/cjs/polyfills-server.js +23 -0
- package/dist/cjs/render.js +44 -0
- package/dist/cjs/router/RouterStore.js +14 -0
- package/dist/cjs/router/getNormalizedStatePath.js +50 -0
- package/dist/cjs/router/lastAction.js +25 -0
- package/dist/cjs/router/router.js +345 -0
- package/dist/cjs/router/serverLocationContext.js +22 -0
- package/dist/cjs/router/useInitializeOneRouter.js +43 -0
- package/dist/cjs/serve.js +184 -0
- package/dist/cjs/server/createRoutesManifest.js +40 -0
- package/dist/cjs/server/getServerManifest.js +109 -0
- package/dist/cjs/server-render.js +42 -0
- package/dist/cjs/sortRoutes.js +64 -0
- package/dist/cjs/typed-routes/generateRouteTypes.js +33 -0
- package/dist/cjs/typed-routes/getTypedRoutesDeclarationFile.js +83 -0
- package/dist/cjs/types.js +14 -0
- package/dist/cjs/useFocusEffect.js +79 -0
- package/dist/cjs/useLoader.js +97 -0
- package/dist/cjs/useNavigation.js +60 -0
- package/dist/cjs/useScreens.js +176 -0
- package/dist/cjs/useViteRoutes.js +77 -0
- package/dist/cjs/utils/assertIsReady.js +26 -0
- package/dist/cjs/utils/dynamicImport.js +24 -0
- package/dist/cjs/utils/existsAsync.js +28 -0
- package/dist/cjs/utils/getPageExport.js +38 -0
- package/dist/cjs/utils/globDir.js +37 -0
- package/dist/cjs/utils/hashString.js +32 -0
- package/dist/cjs/utils/isResponse.js +23 -0
- package/dist/cjs/utils/isStatus.js +23 -0
- package/dist/cjs/utils/promiseWithResolvers.js +26 -0
- package/dist/cjs/utils/rand.js +21 -0
- package/dist/cjs/utils/redirect.js +28 -0
- package/dist/cjs/utils/removeSearch.js +23 -0
- package/dist/cjs/utils/removeUndefined.js +26 -0
- package/dist/cjs/utils/url.js +31 -0
- package/dist/cjs/utils/weakKey.js +24 -0
- package/dist/cjs/utils/weakMemo.js +30 -0
- package/dist/cjs/views/EmptyRoute.js +25 -0
- package/dist/cjs/views/ErrorBoundary.js +33 -0
- package/dist/cjs/views/LoadProgressBar.js +83 -0
- package/dist/cjs/views/Navigator.js +101 -0
- package/dist/cjs/views/PreloadLinks.js +42 -0
- package/dist/cjs/views/RootErrorBoundary.js +47 -0
- package/dist/cjs/views/Screen.js +29 -0
- package/dist/cjs/views/ScrollRestoration.js +70 -0
- package/dist/cjs/views/Try.js +44 -0
- package/dist/cjs/vite/build.js +377 -0
- package/dist/cjs/vite/clientTreeShakePlugin.js +76 -0
- package/dist/cjs/vite/constants.js +22 -0
- package/dist/cjs/vite/createFileSystemRouter.cjs +2 -1
- package/dist/cjs/vite/createFileSystemRouter.js +244 -0
- package/dist/cjs/vite/createFileSystemRouter.js.map +6 -0
- package/dist/cjs/vite/createFileSystemRouter.native.js +2 -1
- package/dist/cjs/vite/createFileSystemRouter.native.js.map +2 -2
- package/dist/cjs/vite/customNodeExternals.js +52 -0
- package/dist/cjs/vite/ensureTsConfig.js +66 -0
- package/dist/cjs/vite/findDepsToOptimize.js +66 -0
- package/dist/cjs/vite/fixDependenciesPlugin.js +43 -0
- package/dist/cjs/vite/generateTypesForRoutes.js +36 -0
- package/dist/cjs/vite/getManifest.js +27 -0
- package/dist/cjs/vite/headers.js +39 -0
- package/dist/cjs/vite/makePluginWebOnly.js +27 -0
- package/dist/cjs/vite/one.js +290 -0
- package/dist/cjs/vite/removeReactNativeWebAnimatedPlugin.js +50 -0
- package/dist/cjs/vite/replaceLoader.js +34 -0
- package/dist/cjs/vite/resolveAPIRequest.js +71 -0
- package/dist/cjs/vite/server.js +16 -0
- package/dist/cjs/vite/types.js +14 -0
- package/dist/cjs/vite/virtualEntryPlugin.js +67 -0
- package/dist/cjs/vite/vitePluginSsrCss.js +130 -0
- package/dist/cjs/vite.cjs +2 -0
- package/dist/cjs/vite.js +29 -0
- package/dist/cjs/vite.js.map +6 -0
- package/dist/cjs/vite.native.js +3 -1
- package/dist/cjs/vite.native.js.map +1 -1
- package/dist/cjs/zero/getQueryKey.js +24 -0
- package/dist/cjs/zero/isZeroQuery.js +23 -0
- package/dist/cjs/zero/resolveQuery.js +38 -0
- package/dist/cjs/zero/subscribeToQuery.js +28 -0
- package/dist/cjs/zero/types.js +14 -0
- package/dist/cjs/zero/useQuery.js +47 -0
- package/dist/cjs/zero/useQueryZero.js +38 -0
- package/dist/cjs/zero.js +23 -0
- package/dist/esm/vite/createFileSystemRouter.js +2 -1
- package/dist/esm/vite/createFileSystemRouter.js.map +1 -1
- package/dist/esm/vite/createFileSystemRouter.mjs +2 -1
- package/dist/esm/vite/createFileSystemRouter.mjs.map +1 -1
- package/dist/esm/vite/createFileSystemRouter.native.js +2 -1
- package/dist/esm/vite/createFileSystemRouter.native.js.map +2 -2
- package/dist/esm/vite.js +2 -0
- package/dist/esm/vite.js.map +1 -1
- package/dist/esm/vite.mjs +2 -1
- package/dist/esm/vite.mjs.map +1 -1
- package/dist/esm/vite.native.js +2 -0
- package/dist/esm/vite.native.js.map +2 -2
- package/package.json +8 -8
- package/src/vite/createFileSystemRouter.tsx +1 -1
- package/src/vite.ts +1 -0
- package/types/vite.d.ts +1 -0
- package/types/vite.d.ts.map +1 -1
- package/dist/cjs/createApp.native.cjs +0 -38
- package/dist/cjs/createApp.native.cjs.map +0 -6
- package/dist/cjs/fork/NavigationContainer.native.cjs +0 -103
- package/dist/cjs/fork/NavigationContainer.native.cjs.map +0 -6
- package/dist/cjs/fork/useLinking.native.cjs +0 -126
- package/dist/cjs/fork/useLinking.native.cjs.map +0 -6
- package/dist/cjs/getURL.native.cjs +0 -48
- package/dist/cjs/getURL.native.cjs.map +0 -6
- package/dist/cjs/head/Head.android.cjs +0 -28
- package/dist/cjs/head/Head.android.cjs.map +0 -6
- package/dist/cjs/head/Head.ios.cjs +0 -210
- package/dist/cjs/head/Head.ios.cjs.map +0 -6
- package/dist/cjs/import-mode/index.android.cjs +0 -26
- package/dist/cjs/import-mode/index.android.cjs.map +0 -6
- package/dist/cjs/import-mode/index.ios.cjs +0 -26
- package/dist/cjs/import-mode/index.ios.cjs.map +0 -6
- package/dist/cjs/import-mode/index.native.cjs +0 -26
- package/dist/cjs/import-mode/index.native.cjs.map +0 -6
- package/dist/cjs/render.native.cjs +0 -28
- package/dist/cjs/render.native.cjs.map +0 -6
- package/dist/cjs/views/PreloadLinks.native.cjs +0 -28
- package/dist/cjs/views/PreloadLinks.native.cjs.map +0 -6
- package/dist/cjs/vite/createFileSystemRouter.cjs.map +0 -6
- package/dist/cjs/vite/headers.native.cjs +0 -32
- package/dist/cjs/vite/headers.native.cjs.map +0 -6
- package/dist/cjs/vite.cjs.map +0 -6
- /package/dist/cjs/{Root.cjs.map → Root.js.map} +0 -0
- /package/dist/cjs/{Route.cjs.map → Route.js.map} +0 -0
- /package/dist/cjs/{cleanUrl.cjs.map → cleanUrl.js.map} +0 -0
- /package/dist/cjs/cli/{label-process.cjs.map → label-process.js.map} +0 -0
- /package/dist/cjs/cli/{main.cjs.map → main.js.map} +0 -0
- /package/dist/cjs/cli/{patch.cjs.map → patch.js.map} +0 -0
- /package/dist/cjs/cli/{prebuild.cjs.map → prebuild.js.map} +0 -0
- /package/dist/cjs/cli/{run.cjs.map → run.js.map} +0 -0
- /package/dist/cjs/cli/{runAndroid.cjs.map → runAndroid.js.map} +0 -0
- /package/dist/cjs/cli/{runIos.cjs.map → runIos.js.map} +0 -0
- /package/dist/cjs/{cli.cjs.map → cli.js.map} +0 -0
- /package/dist/cjs/{clientLoaderResolver.cjs.map → clientLoaderResolver.js.map} +0 -0
- /package/dist/cjs/{config.cjs.map → config.js.map} +0 -0
- /package/dist/cjs/{constants.cjs.map → constants.js.map} +0 -0
- /package/dist/cjs/{createApp.cjs.map → createApp.js.map} +0 -0
- /package/dist/cjs/{createHandleRequest.cjs.map → createHandleRequest.js.map} +0 -0
- /package/dist/cjs/{createRoute.cjs.map → createRoute.js.map} +0 -0
- /package/dist/cjs/fallbackViews/{Sitemap.cjs.map → Sitemap.js.map} +0 -0
- /package/dist/cjs/fallbackViews/{Unmatched.cjs.map → Unmatched.js.map} +0 -0
- /package/dist/cjs/fork/{NavigationContainer.cjs.map → NavigationContainer.js.map} +0 -0
- /package/dist/cjs/fork/{createMemoryHistory.cjs.map → createMemoryHistory.js.map} +0 -0
- /package/dist/cjs/fork/{extractPathFromURL.cjs.map → extractPathFromURL.js.map} +0 -0
- /package/dist/cjs/fork/{findFocusedRoute.cjs.map → findFocusedRoute.js.map} +0 -0
- /package/dist/cjs/fork/{getPathFromState.cjs.map → getPathFromState.js.map} +0 -0
- /package/dist/cjs/fork/{getStateFromPath.cjs.map → getStateFromPath.js.map} +0 -0
- /package/dist/cjs/fork/{useLinking.cjs.map → useLinking.js.map} +0 -0
- /package/dist/cjs/fork/{validatePathConfig.cjs.map → validatePathConfig.js.map} +0 -0
- /package/dist/cjs/{getLinkingConfig.cjs.map → getLinkingConfig.js.map} +0 -0
- /package/dist/cjs/{getReactNavigationConfig.cjs.map → getReactNavigationConfig.js.map} +0 -0
- /package/dist/cjs/{getRoutes.cjs.map → getRoutes.js.map} +0 -0
- /package/dist/cjs/{getURL.cjs.map → getURL.js.map} +0 -0
- /package/dist/cjs/head/{Head.cjs.map → Head.js.map} +0 -0
- /package/dist/cjs/head/{HeadModule.cjs.map → HeadModule.js.map} +0 -0
- /package/dist/cjs/head/{index.cjs.map → index.js.map} +0 -0
- /package/dist/cjs/head/{types.cjs.map → types.js.map} +0 -0
- /package/dist/cjs/head/{url.cjs.map → url.js.map} +0 -0
- /package/dist/cjs/{hooks.cjs.map → hooks.js.map} +0 -0
- /package/dist/cjs/{imperative-api.cjs.map → imperative-api.js.map} +0 -0
- /package/dist/cjs/import-mode/{index.cjs.map → index.js.map} +0 -0
- /package/dist/cjs/import-mode/{index.web.cjs.map → index.web.js.map} +0 -0
- /package/dist/cjs/{index.cjs.map → index.js.map} +0 -0
- /package/dist/cjs/interfaces/{router.cjs.map → router.js.map} +0 -0
- /package/dist/cjs/layouts/{Drawer.cjs.map → Drawer.js.map} +0 -0
- /package/dist/cjs/layouts/{Stack.cjs.map → Stack.js.map} +0 -0
- /package/dist/cjs/layouts/{Tabs.cjs.map → Tabs.js.map} +0 -0
- /package/dist/cjs/layouts/{withLayoutContext.cjs.map → withLayoutContext.js.map} +0 -0
- /package/dist/cjs/link/{Link.cjs.map → Link.js.map} +0 -0
- /package/dist/cjs/link/{Redirect.cjs.map → Redirect.js.map} +0 -0
- /package/dist/cjs/link/{href.cjs.map → href.js.map} +0 -0
- /package/dist/cjs/link/{linking.cjs.map → linking.js.map} +0 -0
- /package/dist/cjs/link/{path.cjs.map → path.js.map} +0 -0
- /package/dist/cjs/link/{useLinkTo.cjs.map → useLinkTo.js.map} +0 -0
- /package/dist/cjs/link/{useLoadedNavigation.cjs.map → useLoadedNavigation.js.map} +0 -0
- /package/dist/cjs/{matchers.cjs.map → matchers.js.map} +0 -0
- /package/dist/cjs/{platform.cjs.map → platform.js.map} +0 -0
- /package/dist/cjs/{polyfills-mobile.cjs.map → polyfills-mobile.js.map} +0 -0
- /package/dist/cjs/{polyfills-server.cjs.map → polyfills-server.js.map} +0 -0
- /package/dist/cjs/{render.cjs.map → render.js.map} +0 -0
- /package/dist/cjs/router/{RouterStore.cjs.map → RouterStore.js.map} +0 -0
- /package/dist/cjs/router/{getNormalizedStatePath.cjs.map → getNormalizedStatePath.js.map} +0 -0
- /package/dist/cjs/router/{lastAction.cjs.map → lastAction.js.map} +0 -0
- /package/dist/cjs/router/{router.cjs.map → router.js.map} +0 -0
- /package/dist/cjs/router/{serverLocationContext.cjs.map → serverLocationContext.js.map} +0 -0
- /package/dist/cjs/router/{useInitializeOneRouter.cjs.map → useInitializeOneRouter.js.map} +0 -0
- /package/dist/cjs/{serve.cjs.map → serve.js.map} +0 -0
- /package/dist/cjs/server/{createRoutesManifest.cjs.map → createRoutesManifest.js.map} +0 -0
- /package/dist/cjs/server/{getServerManifest.cjs.map → getServerManifest.js.map} +0 -0
- /package/dist/cjs/{server-render.cjs.map → server-render.js.map} +0 -0
- /package/dist/cjs/{sortRoutes.cjs.map → sortRoutes.js.map} +0 -0
- /package/dist/cjs/typed-routes/{generateRouteTypes.cjs.map → generateRouteTypes.js.map} +0 -0
- /package/dist/cjs/typed-routes/{getTypedRoutesDeclarationFile.cjs.map → getTypedRoutesDeclarationFile.js.map} +0 -0
- /package/dist/cjs/{types.cjs.map → types.js.map} +0 -0
- /package/dist/cjs/{useFocusEffect.cjs.map → useFocusEffect.js.map} +0 -0
- /package/dist/cjs/{useLoader.cjs.map → useLoader.js.map} +0 -0
- /package/dist/cjs/{useNavigation.cjs.map → useNavigation.js.map} +0 -0
- /package/dist/cjs/{useScreens.cjs.map → useScreens.js.map} +0 -0
- /package/dist/cjs/{useViteRoutes.cjs.map → useViteRoutes.js.map} +0 -0
- /package/dist/cjs/utils/{assertIsReady.cjs.map → assertIsReady.js.map} +0 -0
- /package/dist/cjs/utils/{dynamicImport.cjs.map → dynamicImport.js.map} +0 -0
- /package/dist/cjs/utils/{existsAsync.cjs.map → existsAsync.js.map} +0 -0
- /package/dist/cjs/utils/{getPageExport.cjs.map → getPageExport.js.map} +0 -0
- /package/dist/cjs/utils/{globDir.cjs.map → globDir.js.map} +0 -0
- /package/dist/cjs/utils/{hashString.cjs.map → hashString.js.map} +0 -0
- /package/dist/cjs/utils/{isResponse.cjs.map → isResponse.js.map} +0 -0
- /package/dist/cjs/utils/{isStatus.cjs.map → isStatus.js.map} +0 -0
- /package/dist/cjs/utils/{promiseWithResolvers.cjs.map → promiseWithResolvers.js.map} +0 -0
- /package/dist/cjs/utils/{rand.cjs.map → rand.js.map} +0 -0
- /package/dist/cjs/utils/{redirect.cjs.map → redirect.js.map} +0 -0
- /package/dist/cjs/utils/{removeSearch.cjs.map → removeSearch.js.map} +0 -0
- /package/dist/cjs/utils/{removeUndefined.cjs.map → removeUndefined.js.map} +0 -0
- /package/dist/cjs/utils/{url.cjs.map → url.js.map} +0 -0
- /package/dist/cjs/utils/{weakKey.cjs.map → weakKey.js.map} +0 -0
- /package/dist/cjs/utils/{weakMemo.cjs.map → weakMemo.js.map} +0 -0
- /package/dist/cjs/views/{EmptyRoute.cjs.map → EmptyRoute.js.map} +0 -0
- /package/dist/cjs/views/{ErrorBoundary.cjs.map → ErrorBoundary.js.map} +0 -0
- /package/dist/cjs/views/{LoadProgressBar.cjs.map → LoadProgressBar.js.map} +0 -0
- /package/dist/cjs/views/{Navigator.cjs.map → Navigator.js.map} +0 -0
- /package/dist/cjs/views/{PreloadLinks.cjs.map → PreloadLinks.js.map} +0 -0
- /package/dist/cjs/views/{RootErrorBoundary.cjs.map → RootErrorBoundary.js.map} +0 -0
- /package/dist/cjs/views/{Screen.cjs.map → Screen.js.map} +0 -0
- /package/dist/cjs/views/{ScrollRestoration.cjs.map → ScrollRestoration.js.map} +0 -0
- /package/dist/cjs/views/{Try.cjs.map → Try.js.map} +0 -0
- /package/dist/cjs/vite/{build.cjs.map → build.js.map} +0 -0
- /package/dist/cjs/vite/{clientTreeShakePlugin.cjs.map → clientTreeShakePlugin.js.map} +0 -0
- /package/dist/cjs/vite/{constants.cjs.map → constants.js.map} +0 -0
- /package/dist/cjs/vite/{customNodeExternals.cjs.map → customNodeExternals.js.map} +0 -0
- /package/dist/cjs/vite/{ensureTsConfig.cjs.map → ensureTsConfig.js.map} +0 -0
- /package/dist/cjs/vite/{findDepsToOptimize.cjs.map → findDepsToOptimize.js.map} +0 -0
- /package/dist/cjs/vite/{fixDependenciesPlugin.cjs.map → fixDependenciesPlugin.js.map} +0 -0
- /package/dist/cjs/vite/{generateTypesForRoutes.cjs.map → generateTypesForRoutes.js.map} +0 -0
- /package/dist/cjs/vite/{getManifest.cjs.map → getManifest.js.map} +0 -0
- /package/dist/cjs/vite/{headers.cjs.map → headers.js.map} +0 -0
- /package/dist/cjs/vite/{makePluginWebOnly.cjs.map → makePluginWebOnly.js.map} +0 -0
- /package/dist/cjs/vite/{one.cjs.map → one.js.map} +0 -0
- /package/dist/cjs/vite/{removeReactNativeWebAnimatedPlugin.cjs.map → removeReactNativeWebAnimatedPlugin.js.map} +0 -0
- /package/dist/cjs/vite/{replaceLoader.cjs.map → replaceLoader.js.map} +0 -0
- /package/dist/cjs/vite/{resolveAPIRequest.cjs.map → resolveAPIRequest.js.map} +0 -0
- /package/dist/cjs/vite/{server.cjs.map → server.js.map} +0 -0
- /package/dist/cjs/vite/{types.cjs.map → types.js.map} +0 -0
- /package/dist/cjs/vite/{virtualEntryPlugin.cjs.map → virtualEntryPlugin.js.map} +0 -0
- /package/dist/cjs/vite/{vitePluginSsrCss.cjs.map → vitePluginSsrCss.js.map} +0 -0
- /package/dist/cjs/zero/{getQueryKey.cjs.map → getQueryKey.js.map} +0 -0
- /package/dist/cjs/zero/{isZeroQuery.cjs.map → isZeroQuery.js.map} +0 -0
- /package/dist/cjs/zero/{resolveQuery.cjs.map → resolveQuery.js.map} +0 -0
- /package/dist/cjs/zero/{subscribeToQuery.cjs.map → subscribeToQuery.js.map} +0 -0
- /package/dist/cjs/zero/{types.cjs.map → types.js.map} +0 -0
- /package/dist/cjs/zero/{useQuery.cjs.map → useQuery.js.map} +0 -0
- /package/dist/cjs/zero/{useQueryZero.cjs.map → useQueryZero.js.map} +0 -0
- /package/dist/cjs/{zero.cjs.map → zero.js.map} +0 -0
@@ -0,0 +1,24 @@
|
|
1
|
+
var __defProp = Object.defineProperty;
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
5
|
+
var __export = (target, all) => {
|
6
|
+
for (var name in all)
|
7
|
+
__defProp(target, name, { get: all[name], enumerable: !0 });
|
8
|
+
}, __copyProps = (to, from, except, desc) => {
|
9
|
+
if (from && typeof from == "object" || typeof from == "function")
|
10
|
+
for (let key of __getOwnPropNames(from))
|
11
|
+
!__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
12
|
+
return to;
|
13
|
+
};
|
14
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
|
15
|
+
var weakKey_exports = {};
|
16
|
+
__export(weakKey_exports, {
|
17
|
+
weakKey: () => weakKey
|
18
|
+
});
|
19
|
+
module.exports = __toCommonJS(weakKey_exports);
|
20
|
+
const w = /* @__PURE__ */ new WeakMap(), weakKey = (item) => w.get(item) ?? (() => {
|
21
|
+
const k = `${Math.random()}`;
|
22
|
+
return w.set(item, k), k;
|
23
|
+
})();
|
24
|
+
//# sourceMappingURL=weakKey.js.map
|
@@ -0,0 +1,30 @@
|
|
1
|
+
var __defProp = Object.defineProperty;
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
5
|
+
var __export = (target, all) => {
|
6
|
+
for (var name in all)
|
7
|
+
__defProp(target, name, { get: all[name], enumerable: !0 });
|
8
|
+
}, __copyProps = (to, from, except, desc) => {
|
9
|
+
if (from && typeof from == "object" || typeof from == "function")
|
10
|
+
for (let key of __getOwnPropNames(from))
|
11
|
+
!__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
12
|
+
return to;
|
13
|
+
};
|
14
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
|
15
|
+
var weakMemo_exports = {};
|
16
|
+
__export(weakMemo_exports, {
|
17
|
+
weakMemoObject: () => weakMemoObject
|
18
|
+
});
|
19
|
+
module.exports = __toCommonJS(weakMemo_exports);
|
20
|
+
const cache = /* @__PURE__ */ new WeakMap();
|
21
|
+
function weakMemoObject(obj) {
|
22
|
+
if (!cache.has(obj)) {
|
23
|
+
const memoizedObj = {};
|
24
|
+
for (const key of Object.keys(obj))
|
25
|
+
cache.has(obj[key]) || cache.set(obj[key], obj[key]), memoizedObj[key] = cache.get(obj[key]);
|
26
|
+
cache.set(obj, memoizedObj);
|
27
|
+
}
|
28
|
+
return cache.get(obj);
|
29
|
+
}
|
30
|
+
//# sourceMappingURL=weakMemo.js.map
|
@@ -0,0 +1,25 @@
|
|
1
|
+
var __defProp = Object.defineProperty;
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
5
|
+
var __export = (target, all) => {
|
6
|
+
for (var name in all)
|
7
|
+
__defProp(target, name, { get: all[name], enumerable: !0 });
|
8
|
+
}, __copyProps = (to, from, except, desc) => {
|
9
|
+
if (from && typeof from == "object" || typeof from == "function")
|
10
|
+
for (let key of __getOwnPropNames(from))
|
11
|
+
!__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
12
|
+
return to;
|
13
|
+
};
|
14
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
|
15
|
+
var EmptyRoute_exports = {};
|
16
|
+
__export(EmptyRoute_exports, {
|
17
|
+
EmptyRoute: () => EmptyRoute
|
18
|
+
});
|
19
|
+
module.exports = __toCommonJS(EmptyRoute_exports);
|
20
|
+
var import_Route = require("../Route");
|
21
|
+
function EmptyRoute() {
|
22
|
+
const route = (0, import_Route.useRouteNode)();
|
23
|
+
return null;
|
24
|
+
}
|
25
|
+
//# sourceMappingURL=EmptyRoute.js.map
|
@@ -0,0 +1,33 @@
|
|
1
|
+
var __create = Object.create;
|
2
|
+
var __defProp = Object.defineProperty;
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
5
|
+
var __getProtoOf = Object.getPrototypeOf, __hasOwnProp = Object.prototype.hasOwnProperty;
|
6
|
+
var __export = (target, all) => {
|
7
|
+
for (var name in all)
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: !0 });
|
9
|
+
}, __copyProps = (to, from, except, desc) => {
|
10
|
+
if (from && typeof from == "object" || typeof from == "function")
|
11
|
+
for (let key of __getOwnPropNames(from))
|
12
|
+
!__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
13
|
+
return to;
|
14
|
+
};
|
15
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
16
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
17
|
+
// file that has been converted to a CommonJS file using a Babel-
|
18
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
19
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
20
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: !0 }) : target,
|
21
|
+
mod
|
22
|
+
)), __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
|
23
|
+
var ErrorBoundary_exports = {};
|
24
|
+
__export(ErrorBoundary_exports, {
|
25
|
+
ErrorBoundary: () => ErrorBoundary
|
26
|
+
});
|
27
|
+
module.exports = __toCommonJS(ErrorBoundary_exports);
|
28
|
+
var import_bottom_tabs = require("@react-navigation/bottom-tabs"), import_react = __toESM(require("react"), 1), import_react_native = require("react-native-web"), import_react_native_safe_area_context = require("react-native-safe-area-context");
|
29
|
+
function ErrorBoundary({ error, retry }) {
|
30
|
+
const Wrapper = import_react.default.useContext(import_bottom_tabs.BottomTabBarHeightContext) ? import_react_native.View : import_react_native_safe_area_context.SafeAreaView;
|
31
|
+
return console.error("error", error), null;
|
32
|
+
}
|
33
|
+
//# sourceMappingURL=ErrorBoundary.js.map
|
@@ -0,0 +1,83 @@
|
|
1
|
+
var __defProp = Object.defineProperty;
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
5
|
+
var __export = (target, all) => {
|
6
|
+
for (var name in all)
|
7
|
+
__defProp(target, name, { get: all[name], enumerable: !0 });
|
8
|
+
}, __copyProps = (to, from, except, desc) => {
|
9
|
+
if (from && typeof from == "object" || typeof from == "function")
|
10
|
+
for (let key of __getOwnPropNames(from))
|
11
|
+
!__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
12
|
+
return to;
|
13
|
+
};
|
14
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
|
15
|
+
var LoadProgressBar_exports = {};
|
16
|
+
__export(LoadProgressBar_exports, {
|
17
|
+
LoadProgressBar: () => LoadProgressBar
|
18
|
+
});
|
19
|
+
module.exports = __toCommonJS(LoadProgressBar_exports);
|
20
|
+
var import_react = require("react"), import_react_native = require("react-native-web"), import_imperative_api = require("../imperative-api"), import_jsx_runtime = require("react/jsx-runtime");
|
21
|
+
const LoadProgressBar = ({
|
22
|
+
startDelay = 500,
|
23
|
+
finishDelay = 50,
|
24
|
+
initialPercent = 20,
|
25
|
+
updateInterval = 300,
|
26
|
+
sporadicness = 3,
|
27
|
+
...props
|
28
|
+
}) => {
|
29
|
+
const [loaded, setLoaded] = (0, import_react.useState)(0), [width, setWidth] = (0, import_react.useState)(0);
|
30
|
+
return (0, import_react.useEffect)(() => {
|
31
|
+
let loadInterval;
|
32
|
+
const dispose = import_imperative_api.router.onLoadState((state) => {
|
33
|
+
switch (clearTimeout(loadInterval), state) {
|
34
|
+
case "loading": {
|
35
|
+
loadInterval = setTimeout(() => {
|
36
|
+
setLoaded(initialPercent);
|
37
|
+
let intervalCount = 0;
|
38
|
+
loadInterval = setInterval(() => {
|
39
|
+
intervalCount++, intervalCount % sporadicness !== 0 && setLoaded((prev) => {
|
40
|
+
const increment = (100 - prev) * (prev > 80 ? 0.05 : 0.1) * Math.random();
|
41
|
+
return Math.min(prev + increment, 100);
|
42
|
+
});
|
43
|
+
}, updateInterval);
|
44
|
+
}, startDelay);
|
45
|
+
break;
|
46
|
+
}
|
47
|
+
case "loaded": {
|
48
|
+
setLoaded(100), clearInterval(loadInterval), setTimeout(() => {
|
49
|
+
setLoaded(0);
|
50
|
+
}, finishDelay);
|
51
|
+
break;
|
52
|
+
}
|
53
|
+
}
|
54
|
+
});
|
55
|
+
return () => {
|
56
|
+
dispose(), clearInterval(loadInterval);
|
57
|
+
};
|
58
|
+
}, [finishDelay, initialPercent, sporadicness, startDelay, updateInterval]), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
59
|
+
import_react_native.View,
|
60
|
+
{
|
61
|
+
...props,
|
62
|
+
onLayout: (e) => {
|
63
|
+
setWidth(e.nativeEvent.layout.width), props.onLayout?.(e);
|
64
|
+
},
|
65
|
+
style: [
|
66
|
+
{
|
67
|
+
display: loaded === 0 ? "none" : "flex",
|
68
|
+
height: 1,
|
69
|
+
position: "absolute",
|
70
|
+
top: 0,
|
71
|
+
left: 0,
|
72
|
+
right: 0,
|
73
|
+
backgroundColor: "rgba(60, 100, 200, 0.65)",
|
74
|
+
width: "100%",
|
75
|
+
transform: [{ translateX: -(1 - loaded * 0.01) * width }],
|
76
|
+
zIndex: Number.MAX_SAFE_INTEGER
|
77
|
+
},
|
78
|
+
props.style
|
79
|
+
]
|
80
|
+
}
|
81
|
+
);
|
82
|
+
};
|
83
|
+
//# sourceMappingURL=LoadProgressBar.js.map
|
@@ -0,0 +1,101 @@
|
|
1
|
+
"use client";
|
2
|
+
var __create = Object.create;
|
3
|
+
var __defProp = Object.defineProperty;
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
6
|
+
var __getProtoOf = Object.getPrototypeOf, __hasOwnProp = Object.prototype.hasOwnProperty;
|
7
|
+
var __export = (target, all) => {
|
8
|
+
for (var name in all)
|
9
|
+
__defProp(target, name, { get: all[name], enumerable: !0 });
|
10
|
+
}, __copyProps = (to, from, except, desc) => {
|
11
|
+
if (from && typeof from == "object" || typeof from == "function")
|
12
|
+
for (let key of __getOwnPropNames(from))
|
13
|
+
!__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
14
|
+
return to;
|
15
|
+
};
|
16
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
17
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
18
|
+
// file that has been converted to a CommonJS file using a Babel-
|
19
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
20
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
21
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: !0 }) : target,
|
22
|
+
mod
|
23
|
+
)), __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
|
24
|
+
var Navigator_exports = {};
|
25
|
+
__export(Navigator_exports, {
|
26
|
+
DefaultNavigator: () => DefaultNavigator,
|
27
|
+
Navigator: () => Navigator,
|
28
|
+
NavigatorContext: () => NavigatorContext,
|
29
|
+
QualifiedSlot: () => QualifiedSlot,
|
30
|
+
Slot: () => Slot,
|
31
|
+
useNavigatorContext: () => useNavigatorContext,
|
32
|
+
useSlot: () => useSlot
|
33
|
+
});
|
34
|
+
module.exports = __toCommonJS(Navigator_exports);
|
35
|
+
var import_native = require("@react-navigation/native"), React = __toESM(require("react"), 1), import_Route = require("../Route"), import_withLayoutContext = require("../layouts/withLayoutContext"), import_useScreens = require("../useScreens"), import_Screen = require("./Screen"), import_react_native_safe_area_context = require("react-native-safe-area-context"), import_jsx_runtime = require("react/jsx-runtime");
|
36
|
+
const NavigatorContext = React.createContext(null);
|
37
|
+
process.env.NODE_ENV !== "production" && (NavigatorContext.displayName = "NavigatorContext");
|
38
|
+
function Navigator({ initialRouteName, screenOptions, children, router }) {
|
39
|
+
const contextKey = (0, import_Route.useContextKey)(), { screens, children: otherSlot } = (0, import_withLayoutContext.useFilterScreenChildren)(children, {
|
40
|
+
isCustomNavigator: !0,
|
41
|
+
contextKey
|
42
|
+
}), sorted = (0, import_useScreens.useSortedScreens)(screens ?? []);
|
43
|
+
return sorted.length ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
44
|
+
QualifiedNavigator,
|
45
|
+
{
|
46
|
+
initialRouteName,
|
47
|
+
screenOptions,
|
48
|
+
screens: sorted,
|
49
|
+
contextKey,
|
50
|
+
router,
|
51
|
+
children: otherSlot
|
52
|
+
}
|
53
|
+
) : (console.warn(`Navigator at "${contextKey}" has no children.`), null);
|
54
|
+
}
|
55
|
+
function QualifiedNavigator({
|
56
|
+
initialRouteName,
|
57
|
+
screenOptions,
|
58
|
+
children,
|
59
|
+
screens,
|
60
|
+
contextKey,
|
61
|
+
router = import_native.StackRouter
|
62
|
+
}) {
|
63
|
+
const { state, navigation, descriptors, NavigationContent } = (0, import_native.useNavigationBuilder)(router, {
|
64
|
+
// Used for getting the parent with navigation.getParent('/normalized/path')
|
65
|
+
id: contextKey,
|
66
|
+
children: screens,
|
67
|
+
screenOptions,
|
68
|
+
initialRouteName
|
69
|
+
}), value = React.useMemo(() => ({
|
70
|
+
contextKey,
|
71
|
+
state,
|
72
|
+
navigation,
|
73
|
+
descriptors,
|
74
|
+
router
|
75
|
+
}), [contextKey, state, navigation, descriptors, router]);
|
76
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(NavigatorContext.Provider, { value, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(NavigationContent, { children }) });
|
77
|
+
}
|
78
|
+
function useNavigatorContext() {
|
79
|
+
const context = React.useContext(NavigatorContext);
|
80
|
+
if (!context)
|
81
|
+
throw new Error("useNavigatorContext must be used within a <Navigator />");
|
82
|
+
return context;
|
83
|
+
}
|
84
|
+
function useSlot() {
|
85
|
+
const context = useNavigatorContext(), { state, descriptors } = context, current = state.routes.find((route, i) => state.index === i);
|
86
|
+
return current ? descriptors[current.key]?.render() ?? null : null;
|
87
|
+
}
|
88
|
+
const Slot = React.memo(function(props) {
|
89
|
+
const contextKey = (0, import_Route.useContextKey)();
|
90
|
+
return React.useContext(NavigatorContext)?.contextKey !== contextKey ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Navigator, { ...props, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(QualifiedSlot, {}) }) : /* @__PURE__ */ (0, import_jsx_runtime.jsx)(QualifiedSlot, {});
|
91
|
+
});
|
92
|
+
function QualifiedSlot() {
|
93
|
+
return useSlot();
|
94
|
+
}
|
95
|
+
function DefaultNavigator() {
|
96
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_react_native_safe_area_context.SafeAreaView, { style: { flex: 1 }, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Navigator, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(QualifiedSlot, {}) }) });
|
97
|
+
}
|
98
|
+
Navigator.Slot = Slot;
|
99
|
+
Navigator.useContext = useNavigatorContext;
|
100
|
+
Navigator.Screen = import_Screen.Screen;
|
101
|
+
//# sourceMappingURL=Navigator.js.map
|
@@ -0,0 +1,42 @@
|
|
1
|
+
var __defProp = Object.defineProperty;
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
5
|
+
var __export = (target, all) => {
|
6
|
+
for (var name in all)
|
7
|
+
__defProp(target, name, { get: all[name], enumerable: !0 });
|
8
|
+
}, __copyProps = (to, from, except, desc) => {
|
9
|
+
if (from && typeof from == "object" || typeof from == "function")
|
10
|
+
for (let key of __getOwnPropNames(from))
|
11
|
+
!__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
12
|
+
return to;
|
13
|
+
};
|
14
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
|
15
|
+
var PreloadLinks_exports = {};
|
16
|
+
__export(PreloadLinks_exports, {
|
17
|
+
PreloadLinks: () => PreloadLinks
|
18
|
+
});
|
19
|
+
module.exports = __toCommonJS(PreloadLinks_exports);
|
20
|
+
var import_react = require("react"), import_router = require("../router/router"), import_getURL = require("../getURL");
|
21
|
+
const import_meta = {};
|
22
|
+
function PreloadLinks() {
|
23
|
+
return typeof window < "u" && import_meta.env.PROD && (0, import_react.useEffect)(() => {
|
24
|
+
const url = (0, import_getURL.getURL)(), controller = new AbortController();
|
25
|
+
return document.addEventListener(
|
26
|
+
"mouseover",
|
27
|
+
(e) => {
|
28
|
+
let target = e.target;
|
29
|
+
if (!(target instanceof HTMLElement) || (target = target instanceof HTMLAnchorElement ? target : target.closest("a"), !(target instanceof HTMLAnchorElement))) return;
|
30
|
+
const href = target.getAttribute("href");
|
31
|
+
(href?.[0] === "/" || href?.[0].startsWith(url)) && (0, import_router.preloadRoute)(href.replace(url, ""));
|
32
|
+
},
|
33
|
+
{
|
34
|
+
passive: !0,
|
35
|
+
signal: controller.signal
|
36
|
+
}
|
37
|
+
), () => {
|
38
|
+
controller.abort();
|
39
|
+
};
|
40
|
+
}, []), null;
|
41
|
+
}
|
42
|
+
//# sourceMappingURL=PreloadLinks.js.map
|
@@ -0,0 +1,47 @@
|
|
1
|
+
var __create = Object.create;
|
2
|
+
var __defProp = Object.defineProperty;
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
5
|
+
var __getProtoOf = Object.getPrototypeOf, __hasOwnProp = Object.prototype.hasOwnProperty;
|
6
|
+
var __export = (target, all) => {
|
7
|
+
for (var name in all)
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: !0 });
|
9
|
+
}, __copyProps = (to, from, except, desc) => {
|
10
|
+
if (from && typeof from == "object" || typeof from == "function")
|
11
|
+
for (let key of __getOwnPropNames(from))
|
12
|
+
!__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
13
|
+
return to;
|
14
|
+
};
|
15
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
16
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
17
|
+
// file that has been converted to a CommonJS file using a Babel-
|
18
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
19
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
20
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: !0 }) : target,
|
21
|
+
mod
|
22
|
+
)), __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
|
23
|
+
var RootErrorBoundary_exports = {};
|
24
|
+
__export(RootErrorBoundary_exports, {
|
25
|
+
RootErrorBoundary: () => RootErrorBoundary
|
26
|
+
});
|
27
|
+
module.exports = __toCommonJS(RootErrorBoundary_exports);
|
28
|
+
var import_react = __toESM(require("react"), 1);
|
29
|
+
class RootErrorBoundary extends import_react.default.Component {
|
30
|
+
state = { hasError: !1 };
|
31
|
+
static getDerivedStateFromError(error) {
|
32
|
+
return console.error("RootErrorBoundary.error", error), { hasError: !0 };
|
33
|
+
}
|
34
|
+
componentDidCatch(error, info) {
|
35
|
+
console.error(`RootErrorBoundary.error:
|
36
|
+
${printError(error)}
|
37
|
+
${info.componentStack}`);
|
38
|
+
}
|
39
|
+
render() {
|
40
|
+
return this.state.hasError ? null : this.props.children;
|
41
|
+
}
|
42
|
+
}
|
43
|
+
function printError(err) {
|
44
|
+
return `${err instanceof Error ? `${err.message}
|
45
|
+
${err.stack}` : err}`;
|
46
|
+
}
|
47
|
+
//# sourceMappingURL=RootErrorBoundary.js.map
|
@@ -0,0 +1,29 @@
|
|
1
|
+
var __defProp = Object.defineProperty;
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
5
|
+
var __export = (target, all) => {
|
6
|
+
for (var name in all)
|
7
|
+
__defProp(target, name, { get: all[name], enumerable: !0 });
|
8
|
+
}, __copyProps = (to, from, except, desc) => {
|
9
|
+
if (from && typeof from == "object" || typeof from == "function")
|
10
|
+
for (let key of __getOwnPropNames(from))
|
11
|
+
!__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
12
|
+
return to;
|
13
|
+
};
|
14
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
|
15
|
+
var Screen_exports = {};
|
16
|
+
__export(Screen_exports, {
|
17
|
+
Screen: () => Screen
|
18
|
+
});
|
19
|
+
module.exports = __toCommonJS(Screen_exports);
|
20
|
+
var import_use_isomorphic_layout_effect = require("@vxrn/use-isomorphic-layout-effect"), import_useNavigation = require("../useNavigation");
|
21
|
+
function Screen({ name, options }) {
|
22
|
+
const navigation = (0, import_useNavigation.useNavigation)(name);
|
23
|
+
return (0, import_use_isomorphic_layout_effect.useIsomorphicLayoutEffect)(() => {
|
24
|
+
options && // React Navigation will infinitely loop in some cases if an empty object is passed to setOptions.
|
25
|
+
// https://github.com/expo/router/issues/452
|
26
|
+
Object.keys(options).length && navigation.setOptions(options);
|
27
|
+
}, [navigation, options]), null;
|
28
|
+
}
|
29
|
+
//# sourceMappingURL=Screen.js.map
|
@@ -0,0 +1,70 @@
|
|
1
|
+
var __defProp = Object.defineProperty;
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
5
|
+
var __export = (target, all) => {
|
6
|
+
for (var name in all)
|
7
|
+
__defProp(target, name, { get: all[name], enumerable: !0 });
|
8
|
+
}, __copyProps = (to, from, except, desc) => {
|
9
|
+
if (from && typeof from == "object" || typeof from == "function")
|
10
|
+
for (let key of __getOwnPropNames(from))
|
11
|
+
!__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
12
|
+
return to;
|
13
|
+
};
|
14
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
|
15
|
+
var ScrollRestoration_exports = {};
|
16
|
+
__export(ScrollRestoration_exports, {
|
17
|
+
ScrollRestoration: () => ScrollRestoration
|
18
|
+
});
|
19
|
+
module.exports = __toCommonJS(ScrollRestoration_exports);
|
20
|
+
var import_react = require("react"), import_lastAction = require("../router/lastAction"), import_router = require("../router/router");
|
21
|
+
const KEY = "one-sr", getState = () => JSON.parse(sessionStorage.getItem(KEY) || "{}");
|
22
|
+
let isFirstLoad = !0;
|
23
|
+
function restorePosition() {
|
24
|
+
try {
|
25
|
+
const saved = getState()[window.location.pathname];
|
26
|
+
typeof saved == "number" && setTimeout(() => {
|
27
|
+
window.scrollTo(0, saved);
|
28
|
+
});
|
29
|
+
} catch (error) {
|
30
|
+
console.error("Error restoring scroll position", error), sessionStorage.removeItem(KEY);
|
31
|
+
}
|
32
|
+
}
|
33
|
+
let didPop = !1;
|
34
|
+
function rememberScrollPosition() {
|
35
|
+
didPop = !1;
|
36
|
+
const state = getState();
|
37
|
+
state[window.location.pathname] = window.scrollY, sessionStorage.setItem(KEY, JSON.stringify(state));
|
38
|
+
}
|
39
|
+
let disable = null;
|
40
|
+
function configure(props) {
|
41
|
+
if (typeof window > "u" || !window.addEventListener)
|
42
|
+
return;
|
43
|
+
disable?.();
|
44
|
+
const popStateController = new AbortController();
|
45
|
+
window.addEventListener(
|
46
|
+
"popstate",
|
47
|
+
() => {
|
48
|
+
didPop = !0, (0, import_lastAction.setLastAction)();
|
49
|
+
},
|
50
|
+
{
|
51
|
+
signal: popStateController.signal
|
52
|
+
}
|
53
|
+
);
|
54
|
+
const disposeOnLoadState = (0, import_router.subscribeToLoadingState)((state) => {
|
55
|
+
state === "loading" && rememberScrollPosition();
|
56
|
+
}), disposeOnRootState = (0, import_router.subscribeToRootState)((state) => {
|
57
|
+
if (isFirstLoad) {
|
58
|
+
isFirstLoad = !1;
|
59
|
+
return;
|
60
|
+
}
|
61
|
+
state.linkOptions?.scroll !== !1 && (didPop ? props.disable !== "restore" && restorePosition() : window.scrollTo(0, 0));
|
62
|
+
});
|
63
|
+
return disable = () => {
|
64
|
+
popStateController.abort(), disposeOnLoadState(), disposeOnRootState();
|
65
|
+
}, disable;
|
66
|
+
}
|
67
|
+
function ScrollRestoration(props) {
|
68
|
+
return (0, import_react.useEffect)(() => configure(props), [props.disable]), null;
|
69
|
+
}
|
70
|
+
//# sourceMappingURL=ScrollRestoration.js.map
|
@@ -0,0 +1,44 @@
|
|
1
|
+
var __create = Object.create;
|
2
|
+
var __defProp = Object.defineProperty;
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
5
|
+
var __getProtoOf = Object.getPrototypeOf, __hasOwnProp = Object.prototype.hasOwnProperty;
|
6
|
+
var __export = (target, all) => {
|
7
|
+
for (var name in all)
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: !0 });
|
9
|
+
}, __copyProps = (to, from, except, desc) => {
|
10
|
+
if (from && typeof from == "object" || typeof from == "function")
|
11
|
+
for (let key of __getOwnPropNames(from))
|
12
|
+
!__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
13
|
+
return to;
|
14
|
+
};
|
15
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
16
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
17
|
+
// file that has been converted to a CommonJS file using a Babel-
|
18
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
19
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
20
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: !0 }) : target,
|
21
|
+
mod
|
22
|
+
)), __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
|
23
|
+
var Try_exports = {};
|
24
|
+
__export(Try_exports, {
|
25
|
+
Try: () => Try
|
26
|
+
});
|
27
|
+
module.exports = __toCommonJS(Try_exports);
|
28
|
+
var import_react = __toESM(require("react"), 1), import_jsx_runtime = require("react/jsx-runtime");
|
29
|
+
class Try extends import_react.default.Component {
|
30
|
+
state = { error: void 0 };
|
31
|
+
static getDerivedStateFromError(error) {
|
32
|
+
return { error };
|
33
|
+
}
|
34
|
+
retry = () => new Promise((resolve) => {
|
35
|
+
this.setState({ error: void 0 }, () => {
|
36
|
+
resolve();
|
37
|
+
});
|
38
|
+
});
|
39
|
+
render() {
|
40
|
+
const { error } = this.state, { catch: ErrorBoundary, children } = this.props;
|
41
|
+
return error ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ErrorBoundary, { error, retry: this.retry }) : children;
|
42
|
+
}
|
43
|
+
}
|
44
|
+
//# sourceMappingURL=Try.js.map
|