one 1.1.298 → 1.1.299
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/cjs/vite/replaceLoader.js +7 -1
- package/dist/cjs/vite/replaceLoader.js.map +1 -1
- package/dist/cjs/vite/replaceLoader.native.js +7 -1
- package/dist/cjs/vite/replaceLoader.native.js.map +1 -1
- package/dist/esm/Root.native.js +110 -104
- package/dist/esm/Root.native.js.map +6 -1
- package/dist/esm/Route.native.js +12 -10
- package/dist/esm/Route.native.js.map +6 -1
- package/dist/esm/cleanUrl.native.js +12 -13
- package/dist/esm/cleanUrl.native.js.map +6 -1
- package/dist/esm/cli/label-process.native.js +5 -4
- package/dist/esm/cli/label-process.native.js.map +6 -1
- package/dist/esm/cli/main.native.js +8 -13
- package/dist/esm/cli/main.native.js.map +6 -1
- package/dist/esm/cli/prebuild.native.js +5 -5
- package/dist/esm/cli/prebuild.native.js.map +6 -1
- package/dist/esm/cli/run.native.js +21 -28
- package/dist/esm/cli/run.native.js.map +6 -1
- package/dist/esm/cli.native.js +119 -148
- package/dist/esm/cli.native.js.map +6 -1
- package/dist/esm/clientLoaderResolver.native.js +9 -6
- package/dist/esm/clientLoaderResolver.native.js.map +6 -1
- package/dist/esm/config.native.js +12 -11
- package/dist/esm/config.native.js.map +6 -1
- package/dist/esm/constants.native.js +7 -5
- package/dist/esm/constants.native.js.map +6 -1
- package/dist/esm/createApp.native.js +13 -9
- package/dist/esm/createApp.native.js.map +6 -1
- package/dist/esm/createHandleRequest.native.js +55 -64
- package/dist/esm/createHandleRequest.native.js.map +6 -1
- package/dist/esm/createRoute.native.js +16 -16
- package/dist/esm/createRoute.native.js.map +6 -1
- package/dist/esm/fallbackViews/Sitemap.native.js +6 -3
- package/dist/esm/fallbackViews/Sitemap.native.js.map +6 -1
- package/dist/esm/fallbackViews/Unmatched.native.js +5 -3
- package/dist/esm/fallbackViews/Unmatched.native.js.map +6 -1
- package/dist/esm/fork/NavigationContainer.native.js +24 -31
- package/dist/esm/fork/NavigationContainer.native.js.map +6 -1
- package/dist/esm/fork/createMemoryHistory.native.js +99 -115
- package/dist/esm/fork/createMemoryHistory.native.js.map +6 -1
- package/dist/esm/fork/extractPathFromURL.native.js +16 -15
- package/dist/esm/fork/extractPathFromURL.native.js.map +6 -1
- package/dist/esm/fork/findFocusedRoute.native.js +6 -5
- package/dist/esm/fork/findFocusedRoute.native.js.map +6 -1
- package/dist/esm/fork/getPathFromState.native.js +127 -140
- package/dist/esm/fork/getPathFromState.native.js.map +6 -1
- package/dist/esm/fork/getStateFromPath.native.js +292 -288
- package/dist/esm/fork/getStateFromPath.native.js.map +6 -1
- package/dist/esm/fork/useLinking.native.js +70 -61
- package/dist/esm/fork/useLinking.native.js.map +6 -1
- package/dist/esm/fork/validatePathConfig.native.js +15 -9
- package/dist/esm/fork/validatePathConfig.native.js.map +6 -1
- package/dist/esm/getLinkingConfig.native.js +11 -6
- package/dist/esm/getLinkingConfig.native.js.map +6 -1
- package/dist/esm/getReactNavigationConfig.native.js +28 -20
- package/dist/esm/getReactNavigationConfig.native.js.map +6 -1
- package/dist/esm/getRoutes.native.js +249 -229
- package/dist/esm/getRoutes.native.js.map +6 -1
- package/dist/esm/getURL.native.js +4 -4
- package/dist/esm/getURL.native.js.map +6 -1
- package/dist/esm/head/Head.android.js +5 -3
- package/dist/esm/head/Head.android.js.map +6 -1
- package/dist/esm/head/Head.ios.js +144 -132
- package/dist/esm/head/Head.ios.js.map +6 -1
- package/dist/esm/head/Head.native.js +7 -7
- package/dist/esm/head/Head.native.js.map +6 -1
- package/dist/esm/head/HeadModule.native.js +6 -6
- package/dist/esm/head/HeadModule.native.js.map +6 -1
- package/dist/esm/head/index.native.js +2 -2
- package/dist/esm/head/index.native.js.map +6 -1
- package/dist/esm/head/types.native.js +1 -2
- package/dist/esm/head/types.native.js.map +6 -1
- package/dist/esm/head/url.native.js +10 -8
- package/dist/esm/head/url.native.js.map +6 -1
- package/dist/esm/hooks.native.js +53 -34
- package/dist/esm/hooks.native.js.map +6 -1
- package/dist/esm/imperative-api.native.js +9 -6
- package/dist/esm/imperative-api.native.js.map +6 -1
- package/dist/esm/import-mode/index.android.js +4 -3
- package/dist/esm/import-mode/index.android.js.map +6 -1
- package/dist/esm/import-mode/index.ios.js +4 -3
- package/dist/esm/import-mode/index.ios.js.map +6 -1
- package/dist/esm/import-mode/index.native.js +3 -1
- package/dist/esm/import-mode/index.native.js.map +6 -1
- package/dist/esm/index.native.js +65 -27
- package/dist/esm/index.native.js.map +6 -1
- package/dist/esm/interfaces/router.native.js +4 -2
- package/dist/esm/interfaces/router.native.js.map +6 -1
- package/dist/esm/layouts/Drawer.native.js +7 -6
- package/dist/esm/layouts/Drawer.native.js.map +6 -1
- package/dist/esm/layouts/Stack.native.js +7 -6
- package/dist/esm/layouts/Stack.native.js.map +6 -1
- package/dist/esm/layouts/Tabs.native.js +42 -39
- package/dist/esm/layouts/Tabs.native.js.map +6 -1
- package/dist/esm/layouts/withLayoutContext.native.js +51 -48
- package/dist/esm/layouts/withLayoutContext.native.js.map +6 -1
- package/dist/esm/link/Link.native.js +62 -53
- package/dist/esm/link/Link.native.js.map +6 -1
- package/dist/esm/link/Redirect.native.js +8 -9
- package/dist/esm/link/Redirect.native.js.map +6 -1
- package/dist/esm/link/href.native.js +28 -27
- package/dist/esm/link/href.native.js.map +6 -1
- package/dist/esm/link/linking.native.js +51 -40
- package/dist/esm/link/linking.native.js.map +6 -1
- package/dist/esm/link/path.native.js +28 -19
- package/dist/esm/link/path.native.js.map +6 -1
- package/dist/esm/link/useLinkTo.native.js +22 -20
- package/dist/esm/link/useLinkTo.native.js.map +6 -1
- package/dist/esm/link/useLoadedNavigation.native.js +30 -23
- package/dist/esm/link/useLoadedNavigation.native.js.map +6 -1
- package/dist/esm/matchers.native.js +16 -3
- package/dist/esm/matchers.native.js.map +6 -1
- package/dist/esm/platform.native.js +4 -2
- package/dist/esm/platform.native.js.map +6 -1
- package/dist/esm/polyfills-mobile.native.js +4 -5
- package/dist/esm/polyfills-mobile.native.js.map +6 -1
- package/dist/esm/polyfills-server.native.js +1 -1
- package/dist/esm/polyfills-server.native.js.map +6 -1
- package/dist/esm/render.native.js +3 -1
- package/dist/esm/render.native.js.map +6 -1
- package/dist/esm/router/RouterStore.native.js +1 -2
- package/dist/esm/router/RouterStore.native.js.map +6 -1
- package/dist/esm/router/constants.native.js +4 -2
- package/dist/esm/router/constants.native.js.map +6 -1
- package/dist/esm/router/getNormalizedStatePath.native.js +18 -17
- package/dist/esm/router/getNormalizedStatePath.native.js.map +6 -1
- package/dist/esm/router/lastAction.native.js +10 -9
- package/dist/esm/router/lastAction.native.js.map +6 -1
- package/dist/esm/router/router.native.js +135 -114
- package/dist/esm/router/router.native.js.map +6 -1
- package/dist/esm/router/serverLocationContext.native.js +4 -2
- package/dist/esm/router/serverLocationContext.native.js.map +6 -1
- package/dist/esm/router/useInitializeOneRouter.native.js +8 -5
- package/dist/esm/router/useInitializeOneRouter.native.js.map +6 -1
- package/dist/esm/serve.native.js +77 -104
- package/dist/esm/serve.native.js.map +6 -1
- package/dist/esm/server/createRoutesManifest.native.js +14 -11
- package/dist/esm/server/createRoutesManifest.native.js.map +6 -1
- package/dist/esm/server/getServerManifest.native.js +61 -67
- package/dist/esm/server/getServerManifest.native.js.map +6 -1
- package/dist/esm/server-render.native.js +9 -10
- package/dist/esm/server-render.native.js.map +6 -1
- package/dist/esm/sortRoutes.native.js +27 -17
- package/dist/esm/sortRoutes.native.js.map +6 -1
- package/dist/esm/typed-routes/generateRouteTypes.native.js +10 -11
- package/dist/esm/typed-routes/generateRouteTypes.native.js.map +6 -1
- package/dist/esm/typed-routes/getTypedRoutesDeclarationFile.native.js +38 -37
- package/dist/esm/typed-routes/getTypedRoutesDeclarationFile.native.js.map +6 -1
- package/dist/esm/types.native.js +1 -2
- package/dist/esm/types.native.js.map +6 -1
- package/dist/esm/useFocusEffect.native.js +25 -22
- package/dist/esm/useFocusEffect.native.js.map +6 -1
- package/dist/esm/useLoader.native.js +50 -50
- package/dist/esm/useLoader.native.js.map +6 -1
- package/dist/esm/useNavigation.native.js +23 -19
- package/dist/esm/useNavigation.native.js.map +6 -1
- package/dist/esm/useScreens.native.js +143 -160
- package/dist/esm/useScreens.native.js.map +6 -1
- package/dist/esm/useViteRoutes.native.js +25 -28
- package/dist/esm/useViteRoutes.native.js.map +6 -1
- package/dist/esm/utils/assertIsReady.native.js +6 -3
- package/dist/esm/utils/assertIsReady.native.js.map +6 -1
- package/dist/esm/utils/dynamicImport.native.js +5 -3
- package/dist/esm/utils/dynamicImport.native.js.map +6 -1
- package/dist/esm/utils/existsAsync.native.js +6 -4
- package/dist/esm/utils/existsAsync.native.js.map +6 -1
- package/dist/esm/utils/getPageExport.native.js +12 -11
- package/dist/esm/utils/getPageExport.native.js.map +6 -1
- package/dist/esm/utils/globDir.native.js +5 -3
- package/dist/esm/utils/globDir.native.js.map +6 -1
- package/dist/esm/utils/hashString.native.js +4 -2
- package/dist/esm/utils/hashString.native.js.map +6 -1
- package/dist/esm/utils/isResponse.native.js +4 -2
- package/dist/esm/utils/isResponse.native.js.map +6 -1
- package/dist/esm/utils/isStatus.native.js +4 -2
- package/dist/esm/utils/isStatus.native.js.map +6 -1
- package/dist/esm/utils/promiseWithResolvers.native.js +7 -7
- package/dist/esm/utils/promiseWithResolvers.native.js.map +6 -1
- package/dist/esm/utils/rand.native.js +5 -3
- package/dist/esm/utils/rand.native.js.map +6 -1
- package/dist/esm/utils/redirect.native.js +7 -5
- package/dist/esm/utils/redirect.native.js.map +6 -1
- package/dist/esm/utils/removeSearch.native.js +4 -2
- package/dist/esm/utils/removeSearch.native.js.map +6 -1
- package/dist/esm/utils/removeUndefined.native.js +6 -3
- package/dist/esm/utils/removeUndefined.native.js.map +6 -1
- package/dist/esm/utils/requireResolve.native.js +4 -2
- package/dist/esm/utils/requireResolve.native.js.map +6 -1
- package/dist/esm/utils/url.native.js +6 -2
- package/dist/esm/utils/url.native.js.map +6 -1
- package/dist/esm/utils/weakKey.native.js +11 -10
- package/dist/esm/utils/weakKey.native.js.map +6 -1
- package/dist/esm/utils/weakMemo.native.js +8 -8
- package/dist/esm/utils/weakMemo.native.js.map +6 -1
- package/dist/esm/views/EmptyRoute.native.js +5 -3
- package/dist/esm/views/EmptyRoute.native.js.map +6 -1
- package/dist/esm/views/ErrorBoundary.native.js +5 -8
- package/dist/esm/views/ErrorBoundary.native.js.map +6 -1
- package/dist/esm/views/LoadProgressBar.native.js +58 -57
- package/dist/esm/views/LoadProgressBar.native.js.map +6 -1
- package/dist/esm/views/Navigator.native.js +54 -71
- package/dist/esm/views/Navigator.native.js.map +6 -1
- package/dist/esm/views/PreloadLinks.native.js +3 -1
- package/dist/esm/views/PreloadLinks.native.js.map +6 -1
- package/dist/esm/views/RootErrorBoundary.native.js +39 -29
- package/dist/esm/views/RootErrorBoundary.native.js.map +6 -1
- package/dist/esm/views/Screen.native.js +12 -12
- package/dist/esm/views/Screen.native.js.map +6 -1
- package/dist/esm/views/ScrollRestoration.native.js +27 -27
- package/dist/esm/views/ScrollRestoration.native.js.map +6 -1
- package/dist/esm/views/Try.native.js +40 -37
- package/dist/esm/views/Try.native.js.map +6 -1
- package/dist/esm/vite/build.native.js +260 -295
- package/dist/esm/vite/build.native.js.map +6 -1
- package/dist/esm/vite/clientTreeShakePlugin.native.js +34 -33
- package/dist/esm/vite/clientTreeShakePlugin.native.js.map +6 -1
- package/dist/esm/vite/constants.native.js +6 -4
- package/dist/esm/vite/constants.native.js.map +6 -1
- package/dist/esm/vite/createFileSystemRouter.native.js +99 -130
- package/dist/esm/vite/createFileSystemRouter.native.js.map +6 -1
- package/dist/esm/vite/customNodeExternals.native.js +9 -10
- package/dist/esm/vite/customNodeExternals.native.js.map +6 -1
- package/dist/esm/vite/ensureTsConfig.native.js +7 -5
- package/dist/esm/vite/ensureTsConfig.native.js.map +6 -1
- package/dist/esm/vite/findDepsToOptimize.native.js +27 -19
- package/dist/esm/vite/findDepsToOptimize.native.js.map +6 -1
- package/dist/esm/vite/fixDependenciesPlugin.native.js +5 -3
- package/dist/esm/vite/fixDependenciesPlugin.native.js.map +6 -1
- package/dist/esm/vite/generateTypesForRoutes.native.js +9 -9
- package/dist/esm/vite/generateTypesForRoutes.native.js.map +6 -1
- package/dist/esm/vite/getManifest.native.js +6 -4
- package/dist/esm/vite/getManifest.native.js.map +6 -1
- package/dist/esm/vite/headers.native.js +11 -5
- package/dist/esm/vite/headers.native.js.map +6 -1
- package/dist/esm/vite/loadEnv.native.js +7 -6
- package/dist/esm/vite/loadEnv.native.js.map +6 -1
- package/dist/esm/vite/makePluginWebOnly.native.js +9 -5
- package/dist/esm/vite/makePluginWebOnly.native.js.map +6 -1
- package/dist/esm/vite/one.native.js +142 -127
- package/dist/esm/vite/one.native.js.map +6 -1
- package/dist/esm/vite/removeReactNativeWebAnimatedPlugin.native.js +14 -11
- package/dist/esm/vite/removeReactNativeWebAnimatedPlugin.native.js.map +6 -1
- package/dist/esm/vite/replaceLoader.js +7 -1
- package/dist/esm/vite/replaceLoader.js.map +1 -1
- package/dist/esm/vite/replaceLoader.mjs +5 -1
- package/dist/esm/vite/replaceLoader.mjs.map +1 -1
- package/dist/esm/vite/replaceLoader.native.js +13 -10
- package/dist/esm/vite/replaceLoader.native.js.map +6 -1
- package/dist/esm/vite/resolveAPIRequest.native.js +44 -47
- package/dist/esm/vite/resolveAPIRequest.native.js.map +6 -1
- package/dist/esm/vite/server.native.js +5 -4
- package/dist/esm/vite/server.native.js.map +6 -1
- package/dist/esm/vite/types.native.js +1 -2
- package/dist/esm/vite/types.native.js.map +6 -1
- package/dist/esm/vite/virtualEntryPlugin.native.js +21 -16
- package/dist/esm/vite/virtualEntryPlugin.native.js.map +6 -1
- package/dist/esm/vite/vitePluginSsrCss.native.js +61 -50
- package/dist/esm/vite/vitePluginSsrCss.native.js.map +6 -1
- package/dist/esm/vite.native.js +19 -10
- package/dist/esm/vite.native.js.map +6 -1
- package/dist/esm/zero/getQueryKey.native.js +5 -3
- package/dist/esm/zero/getQueryKey.native.js.map +6 -1
- package/dist/esm/zero/isZeroQuery.native.js +4 -2
- package/dist/esm/zero/isZeroQuery.native.js.map +6 -1
- package/dist/esm/zero/resolveQuery.native.js +9 -8
- package/dist/esm/zero/resolveQuery.native.js.map +6 -1
- package/dist/esm/zero/subscribeToQuery.native.js +5 -3
- package/dist/esm/zero/subscribeToQuery.native.js.map +6 -1
- package/dist/esm/zero/types.native.js +1 -2
- package/dist/esm/zero/types.native.js.map +6 -1
- package/dist/esm/zero/useQuery.native.js +12 -12
- package/dist/esm/zero/useQuery.native.js.map +6 -1
- package/dist/esm/zero/useQueryZero.native.js +24 -20
- package/dist/esm/zero/useQueryZero.native.js.map +6 -1
- package/dist/esm/zero.native.js +9 -5
- package/dist/esm/zero.native.js.map +6 -1
- package/package.json +7 -7
- package/src/vite/replaceLoader.ts +7 -1
- package/types/vite/replaceLoader.d.ts.map +1 -1
@@ -1,32 +1,20 @@
|
|
1
1
|
"use client";
|
2
|
-
|
3
2
|
import { jsx as _jsx } from "react/jsx-runtime";
|
4
3
|
import { StackRouter, useNavigationBuilder } from "@react-navigation/native";
|
5
4
|
import * as React from "react";
|
6
|
-
import { useContextKey } from "../Route
|
7
|
-
import { useFilterScreenChildren } from "../layouts/withLayoutContext
|
8
|
-
import { useSortedScreens } from "../useScreens
|
9
|
-
import { Screen } from "./Screen
|
5
|
+
import { useContextKey } from "../Route";
|
6
|
+
import { useFilterScreenChildren } from "../layouts/withLayoutContext";
|
7
|
+
import { useSortedScreens } from "../useScreens";
|
8
|
+
import { Screen } from "./Screen";
|
10
9
|
import { SafeAreaView } from "react-native-safe-area-context";
|
11
|
-
var NavigatorContext = /* @__PURE__ */React.createContext(null);
|
10
|
+
var NavigatorContext = /* @__PURE__ */ React.createContext(null);
|
12
11
|
process.env.NODE_ENV !== "production" && (NavigatorContext.displayName = "NavigatorContext");
|
13
12
|
function Navigator(param) {
|
14
|
-
var {
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
} = param,
|
20
|
-
contextKey = useContextKey(),
|
21
|
-
{
|
22
|
-
screens,
|
23
|
-
children: otherSlot
|
24
|
-
} = useFilterScreenChildren(children, {
|
25
|
-
isCustomNavigator: !0,
|
26
|
-
contextKey
|
27
|
-
}),
|
28
|
-
sorted = useSortedScreens(screens ?? []);
|
29
|
-
return sorted.length ? /* @__PURE__ */_jsx(QualifiedNavigator, {
|
13
|
+
var { initialRouteName, screenOptions, children, router } = param, contextKey = useContextKey(), { screens, children: otherSlot } = useFilterScreenChildren(children, {
|
14
|
+
isCustomNavigator: !0,
|
15
|
+
contextKey
|
16
|
+
}), sorted = useSortedScreens(screens ?? []);
|
17
|
+
return sorted.length ? /* @__PURE__ */ _jsx(QualifiedNavigator, {
|
30
18
|
initialRouteName,
|
31
19
|
screenOptions,
|
32
20
|
screens: sorted,
|
@@ -36,84 +24,79 @@ function Navigator(param) {
|
|
36
24
|
}) : (console.warn(`Navigator at "${contextKey}" has no children.`), null);
|
37
25
|
}
|
38
26
|
function QualifiedNavigator(param) {
|
39
|
-
var {
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
27
|
+
var { initialRouteName, screenOptions, children, screens, contextKey, router = StackRouter } = param, { state, navigation, descriptors, NavigationContent } = useNavigationBuilder(router, {
|
28
|
+
// Used for getting the parent with navigation.getParent('/normalized/path')
|
29
|
+
id: contextKey,
|
30
|
+
children: screens,
|
31
|
+
screenOptions,
|
32
|
+
initialRouteName
|
33
|
+
}), value = React.useMemo(function() {
|
34
|
+
return {
|
44
35
|
contextKey,
|
45
|
-
router = StackRouter
|
46
|
-
} = param,
|
47
|
-
{
|
48
36
|
state,
|
49
37
|
navigation,
|
50
38
|
descriptors,
|
51
|
-
|
52
|
-
}
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
contextKey,
|
62
|
-
state,
|
63
|
-
navigation,
|
64
|
-
descriptors,
|
65
|
-
router
|
66
|
-
};
|
67
|
-
}, [contextKey, state, navigation, descriptors, router]);
|
68
|
-
return /* @__PURE__ */_jsx(NavigatorContext.Provider, {
|
39
|
+
router
|
40
|
+
};
|
41
|
+
}, [
|
42
|
+
contextKey,
|
43
|
+
state,
|
44
|
+
navigation,
|
45
|
+
descriptors,
|
46
|
+
router
|
47
|
+
]);
|
48
|
+
return /* @__PURE__ */ _jsx(NavigatorContext.Provider, {
|
69
49
|
value,
|
70
|
-
children: /* @__PURE__ */_jsx(NavigationContent, {
|
50
|
+
children: /* @__PURE__ */ _jsx(NavigationContent, {
|
71
51
|
children
|
72
52
|
})
|
73
53
|
});
|
74
54
|
}
|
75
55
|
function useNavigatorContext() {
|
76
56
|
var context = React.useContext(NavigatorContext);
|
77
|
-
if (!context)
|
57
|
+
if (!context)
|
58
|
+
throw new Error("useNavigatorContext must be used within a <Navigator />");
|
78
59
|
return context;
|
79
60
|
}
|
80
61
|
function useSlot() {
|
81
|
-
var _descriptors_current_key,
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
} = context,
|
87
|
-
current = state.routes.find(function (route, i) {
|
88
|
-
return state.index === i;
|
89
|
-
});
|
90
|
-
if (!current) return null;
|
62
|
+
var _descriptors_current_key, context = useNavigatorContext(), { state, descriptors } = context, current = state.routes.find(function(route, i) {
|
63
|
+
return state.index === i;
|
64
|
+
});
|
65
|
+
if (!current)
|
66
|
+
return null;
|
91
67
|
var _descriptors_current_key_render;
|
92
68
|
return (_descriptors_current_key_render = (_descriptors_current_key = descriptors[current.key]) === null || _descriptors_current_key === void 0 ? void 0 : _descriptors_current_key.render()) !== null && _descriptors_current_key_render !== void 0 ? _descriptors_current_key_render : null;
|
93
69
|
}
|
94
|
-
var Slot = /* @__PURE__ */React.memo(function
|
95
|
-
var contextKey = useContextKey(),
|
96
|
-
|
97
|
-
return context?.contextKey !== contextKey ? /* @__PURE__ */_jsx(Navigator, {
|
70
|
+
var Slot = /* @__PURE__ */ React.memo(function(props) {
|
71
|
+
var contextKey = useContextKey(), context = React.useContext(NavigatorContext);
|
72
|
+
return context?.contextKey !== contextKey ? /* @__PURE__ */ _jsx(Navigator, {
|
98
73
|
...props,
|
99
|
-
children: /* @__PURE__ */_jsx(QualifiedSlot, {})
|
100
|
-
}) : /* @__PURE__ */_jsx(QualifiedSlot, {});
|
74
|
+
children: /* @__PURE__ */ _jsx(QualifiedSlot, {})
|
75
|
+
}) : /* @__PURE__ */ _jsx(QualifiedSlot, {});
|
101
76
|
});
|
102
77
|
function QualifiedSlot() {
|
103
78
|
return useSlot();
|
104
79
|
}
|
105
80
|
function DefaultNavigator() {
|
106
|
-
return /* @__PURE__ */_jsx(SafeAreaView, {
|
81
|
+
return /* @__PURE__ */ _jsx(SafeAreaView, {
|
107
82
|
style: {
|
108
83
|
flex: 1
|
109
84
|
},
|
110
|
-
children: /* @__PURE__ */_jsx(Navigator, {
|
111
|
-
children: /* @__PURE__ */_jsx(QualifiedSlot, {})
|
85
|
+
children: /* @__PURE__ */ _jsx(Navigator, {
|
86
|
+
children: /* @__PURE__ */ _jsx(QualifiedSlot, {})
|
112
87
|
})
|
113
88
|
});
|
114
89
|
}
|
115
90
|
Navigator.Slot = Slot;
|
116
91
|
Navigator.useContext = useNavigatorContext;
|
117
92
|
Navigator.Screen = Screen;
|
118
|
-
export {
|
119
|
-
|
93
|
+
export {
|
94
|
+
DefaultNavigator,
|
95
|
+
Navigator,
|
96
|
+
NavigatorContext,
|
97
|
+
QualifiedSlot,
|
98
|
+
Slot,
|
99
|
+
useNavigatorContext,
|
100
|
+
useSlot
|
101
|
+
};
|
102
|
+
//# sourceMappingURL=Navigator.js.map
|
@@ -1 +1,6 @@
|
|
1
|
-
{
|
1
|
+
{
|
2
|
+
"version": 3,
|
3
|
+
"sources": ["../../../src/views/Users/n8/one/packages/one/src/views/Navigator.tsx"],
|
4
|
+
"mappings": ";;AAGA,SAASA,aAAaC,4BAAgD;AACtE,YAAYC,WAAW;AAEvB,SAASC,qBAAqB;AAC9B,SAASC,+BAA+B;AACxC,SAASC,wBAAwB;AACjC,SAASC,cAAc;AACvB,SAASC,oBAAoB;AAKtB,IAAMC,mBAAmBN,sBAAMO,cAM5B,IAAA;AAENC,QAAQC,IAAIC,aAAa,iBAC3BJ,iBAAiBK,cAAc;AAW1B,SAASC,UAAU,OAAqE;MAArE,EAAEC,kBAAkBC,eAAeC,UAAUC,OAAM,IAAnD,OAClBC,aAAahB,cAAAA,GAGb,EAAEiB,SAASH,UAAUI,UAAS,IAAKjB,wBAAwBa,UAAU;IACzEK,mBAAmB;IACnBH;EACF,CAAA,GAEMI,SAASlB,iBAAiBe,WAAW,CAAA,CAAE;AAE7C,SAAKG,OAAOC,SAMV,qBAACC,oBAAAA;IACCV;IACAC;IACAI,SAASG;IACTJ;IACAD;cAECG;QAZHK,QAAQC,KAAK,iBAAiBR,UAAAA,oBAA8B,GACrD;AAcX;AAEA,SAASM,mBAAmB,OAO0C;MAP1C,EAC1BV,kBACAC,eACAC,UACAG,SACAD,YACAD,SAASlB,YAAW,IANM,OAQpB,EAAE4B,OAAOC,YAAYC,aAAaC,kBAAiB,IAAK9B,qBAAqBiB,QAAQ;;IAEzFc,IAAIb;IACJF,UAAUG;IACVJ;IACAD;EACF,CAAA,GAEMkB,QAAQ/B,MAAMgC,QAAQ,WAAA;AAC1B,WAAO;MACLf;MACAS;MACAC;MACAC;MACAZ;IACF;EACF,GAAG;IAACC;IAAYS;IAAOC;IAAYC;IAAaZ;GAAO;AAEvD,SACE,qBAACV,iBAAiB2B,UAAQ;IAACF;cACzB,qBAACF,mBAAAA;;;;AAGP;AAEO,SAASK,sBAAAA;AACd,MAAMC,UAAUnC,MAAMoC,WAAW9B,gBAAAA;AACjC,MAAI,CAAC6B;AACH,UAAM,IAAIE,MAAM,yDAAA;AAElB,SAAOF;AACT;AAEO,SAASG,UAAAA;MAaPV,0BAZDO,UAAUD,oBAAAA,GAEV,EAAER,OAAOE,YAAW,IAAKO,SAEzBI,UAAUb,MAAMc,OAAOC,KAAK,SAACC,OAAOC,GAAAA;AACxC,WAAOjB,MAAMkB,UAAUD;EACzB,CAAA;AAEA,MAAI,CAACJ;AACH,WAAO;MAGFX;AAAP,UAAOA,mCAAAA,2BAAAA,YAAYW,QAAQM,GAAG,OAAC,QAAxBjB,6BAAAA,SAAAA,SAAAA,yBAA0BkB,OAAM,OAAA,QAAhClB,oCAAAA,SAAAA,kCAAsC;AAC/C;AAGO,IAAMmB,OAAO/C,sBAAMgD,KAAK,SAAcC,OAAuC;AAClF,MAAMhC,aAAahB,cAAAA,GACbkC,UAAUnC,MAAMoC,WAAW9B,gBAAAA;AAGjC,SAAI6B,SAASlB,eAAeA,aAGxB,qBAACL,WAAAA;IAAW,GAAGqC;cACb,qBAACC,eAAAA,CAAAA,CAAAA;OAKA,qBAACA,eAAAA,CAAAA,CAAAA;AACV,CAAA;AAEO,SAASA,gBAAAA;AACd,SAAOZ,QAAAA;AACT;AAEO,SAASa,mBAAAA;AACd,SACE,qBAAC9C,cAAAA;IAAa+C,OAAO;MAAEC,MAAM;IAAE;cAC7B,qBAACzC,WAAAA;gBACC,qBAACsC,eAAAA,CAAAA,CAAAA;;;AAIT;AAEAtC,UAAUmC,OAAOA;AACjBnC,UAAUwB,aAAaF;AAGvBtB,UAAUR,SAASA;",
|
5
|
+
"names": ["StackRouter", "useNavigationBuilder", "React", "useContextKey", "useFilterScreenChildren", "useSortedScreens", "Screen", "SafeAreaView", "NavigatorContext", "createContext", "process", "env", "NODE_ENV", "displayName", "Navigator", "initialRouteName", "screenOptions", "children", "router", "contextKey", "screens", "otherSlot", "isCustomNavigator", "sorted", "length", "QualifiedNavigator", "console", "warn", "state", "navigation", "descriptors", "NavigationContent", "id", "value", "useMemo", "Provider", "useNavigatorContext", "context", "useContext", "Error", "useSlot", "current", "routes", "find", "route", "i", "index", "key", "render", "Slot", "memo", "props", "QualifiedSlot", "DefaultNavigator", "style", "flex"]
|
6
|
+
}
|
@@ -1 +1,6 @@
|
|
1
|
-
{
|
1
|
+
{
|
2
|
+
"version": 3,
|
3
|
+
"sources": ["../../../src/views/Users/n8/one/packages/one/src/views/PreloadLinks.native.tsx"],
|
4
|
+
"mappings": "AAAO,SAASA,eAAAA;AACd,SAAO;AACT;",
|
5
|
+
"names": ["PreloadLinks"]
|
6
|
+
}
|
@@ -1,13 +1,15 @@
|
|
1
1
|
import React from "react";
|
2
2
|
function _assert_this_initialized(self) {
|
3
|
-
if (self === void 0)
|
3
|
+
if (self === void 0)
|
4
|
+
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
4
5
|
return self;
|
5
6
|
}
|
6
7
|
function _call_super(_this, derived, args) {
|
7
8
|
return derived = _get_prototype_of(derived), _possible_constructor_return(_this, _is_native_reflect_construct() ? Reflect.construct(derived, args || [], _get_prototype_of(_this).constructor) : derived.apply(_this, args));
|
8
9
|
}
|
9
10
|
function _class_call_check(instance, Constructor) {
|
10
|
-
if (!(instance instanceof Constructor))
|
11
|
+
if (!(instance instanceof Constructor))
|
12
|
+
throw new TypeError("Cannot call a class as a function");
|
11
13
|
}
|
12
14
|
function _defineProperties(target, props) {
|
13
15
|
for (var i = 0; i < props.length; i++) {
|
@@ -27,12 +29,13 @@ function _define_property(obj, key, value) {
|
|
27
29
|
}) : obj[key] = value, obj;
|
28
30
|
}
|
29
31
|
function _get_prototype_of(o) {
|
30
|
-
return _get_prototype_of = Object.setPrototypeOf ? Object.getPrototypeOf : function
|
32
|
+
return _get_prototype_of = Object.setPrototypeOf ? Object.getPrototypeOf : function(o2) {
|
31
33
|
return o2.__proto__ || Object.getPrototypeOf(o2);
|
32
34
|
}, _get_prototype_of(o);
|
33
35
|
}
|
34
36
|
function _inherits(subClass, superClass) {
|
35
|
-
if (typeof superClass != "function" && superClass !== null)
|
37
|
+
if (typeof superClass != "function" && superClass !== null)
|
38
|
+
throw new TypeError("Super expression must either be null or a function");
|
36
39
|
subClass.prototype = Object.create(superClass && superClass.prototype, {
|
37
40
|
constructor: {
|
38
41
|
value: subClass,
|
@@ -45,26 +48,26 @@ function _possible_constructor_return(self, call) {
|
|
45
48
|
return call && (_type_of(call) === "object" || typeof call == "function") ? call : _assert_this_initialized(self);
|
46
49
|
}
|
47
50
|
function _set_prototype_of(o, p) {
|
48
|
-
return _set_prototype_of = Object.setPrototypeOf || function
|
51
|
+
return _set_prototype_of = Object.setPrototypeOf || function(o2, p2) {
|
49
52
|
return o2.__proto__ = p2, o2;
|
50
53
|
}, _set_prototype_of(o, p);
|
51
54
|
}
|
52
55
|
function _type_of(obj) {
|
53
56
|
"@swc/helpers - typeof";
|
54
|
-
|
55
57
|
return obj && typeof Symbol < "u" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
56
58
|
}
|
57
59
|
function _is_native_reflect_construct() {
|
58
60
|
try {
|
59
|
-
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function
|
60
|
-
|
61
|
-
|
61
|
+
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
62
|
+
}));
|
63
|
+
} catch {
|
64
|
+
}
|
65
|
+
return (_is_native_reflect_construct = function() {
|
62
66
|
return !!result;
|
63
67
|
})();
|
64
68
|
}
|
65
|
-
var RootErrorBoundary = /* @__PURE__ */function
|
69
|
+
var RootErrorBoundary = /* @__PURE__ */ function(_React_Component) {
|
66
70
|
"use strict";
|
67
|
-
|
68
71
|
_inherits(RootErrorBoundary2, _React_Component);
|
69
72
|
function RootErrorBoundary2() {
|
70
73
|
_class_call_check(this, RootErrorBoundary2);
|
@@ -73,30 +76,37 @@ var RootErrorBoundary = /* @__PURE__ */function (_React_Component) {
|
|
73
76
|
hasError: !1
|
74
77
|
}), _this;
|
75
78
|
}
|
76
|
-
return _create_class(RootErrorBoundary2, [
|
77
|
-
|
78
|
-
|
79
|
-
|
79
|
+
return _create_class(RootErrorBoundary2, [
|
80
|
+
{
|
81
|
+
key: "componentDidCatch",
|
82
|
+
value: function(error, info) {
|
83
|
+
console.error(`RootErrorBoundary.error:
|
80
84
|
${printError(error)}
|
81
85
|
${info.componentStack}`);
|
86
|
+
}
|
87
|
+
},
|
88
|
+
{
|
89
|
+
key: "render",
|
90
|
+
value: function() {
|
91
|
+
return this.state.hasError ? null : this.props.children;
|
92
|
+
}
|
82
93
|
}
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
return console.error("RootErrorBoundary.error", error), {
|
92
|
-
hasError: !0
|
93
|
-
};
|
94
|
+
], [
|
95
|
+
{
|
96
|
+
key: "getDerivedStateFromError",
|
97
|
+
value: function(error) {
|
98
|
+
return console.error("RootErrorBoundary.error", error), {
|
99
|
+
hasError: !0
|
100
|
+
};
|
101
|
+
}
|
94
102
|
}
|
95
|
-
|
103
|
+
]), RootErrorBoundary2;
|
96
104
|
}(React.Component);
|
97
105
|
function printError(err) {
|
98
106
|
return `${err instanceof Error ? `${err.message}
|
99
107
|
${err.stack}` : err}`;
|
100
108
|
}
|
101
|
-
export {
|
102
|
-
|
109
|
+
export {
|
110
|
+
RootErrorBoundary
|
111
|
+
};
|
112
|
+
//# sourceMappingURL=RootErrorBoundary.js.map
|
@@ -1 +1,6 @@
|
|
1
|
-
{
|
1
|
+
{
|
2
|
+
"version": 3,
|
3
|
+
"sources": ["../../../src/views/Users/n8/one/packages/one/src/views/RootErrorBoundary.tsx"],
|
4
|
+
"mappings": "AAAA,OAAOA,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEX,IAAMC,oBAAN,yBAAA,kBAAA;;YAAMA,oBAAAA,gBAAAA;WAAAA,qBAAAA;4BAAAA,kBAAAA;;qCAAAA,oBAAAA,SAAAA,GACXC,iBAAAA,OAAAA,SAAQ;MAAEC,UAAU;IAAM,CAAA;;uBADfF,oBAAAA;;MASXG,KAAAA;aAAAA,SAAkBC,OAAOC,MAAI;AAM3BC,gBAAQF,MAAM;EAA6BG,WAAWH,KAAAA,CAAAA;EAAWC,KAAKG,cAAc,EAAE;MACxF;;;MAEAC,KAAAA;aAAAA,WAAAA;AACE,eAAI,KAAKR,MAAMC,WAEN,OAGF,KAAKQ,MAAMC;MACpB;;;;MAtBOC,KAAAA;aAAP,SAAgCR,OAAK;AACnCE,uBAAQF,MAAM,2BAA2BA,KAAAA,GAElC;UAAEF,UAAU;QAAK;MAC1B;;MAPWF;EAA0BD,MAAMc,SAAS;AA4BtD,SAASN,WAAWO,KAAG;AACrB,SAAO,GAAGA,eAAeC,QAAQ,GAAGD,IAAIE,OAAO;EAAKF,IAAIG,KAAK,KAAKH,GAAAA;AACpE;",
|
5
|
+
"names": ["React", "RootErrorBoundary", "state", "hasError", "componentDidCatch", "error", "info", "console", "printError", "componentStack", "render", "props", "children", "getDerivedStateFromError", "Component", "err", "Error", "message", "stack"]
|
6
|
+
}
|
@@ -1,17 +1,17 @@
|
|
1
1
|
import { useIsomorphicLayoutEffect } from "@vxrn/use-isomorphic-layout-effect";
|
2
|
-
import { useNavigation } from "../useNavigation
|
2
|
+
import { useNavigation } from "../useNavigation";
|
3
3
|
function Screen(param) {
|
4
|
-
var {
|
5
|
-
|
6
|
-
|
7
|
-
} = param,
|
8
|
-
navigation = useNavigation(name);
|
9
|
-
return useIsomorphicLayoutEffect(function () {
|
10
|
-
options &&
|
11
|
-
// React Navigation will infinitely loop in some cases if an empty object is passed to setOptions.
|
4
|
+
var { name, options } = param, navigation = useNavigation(name);
|
5
|
+
return useIsomorphicLayoutEffect(function() {
|
6
|
+
options && // React Navigation will infinitely loop in some cases if an empty object is passed to setOptions.
|
12
7
|
// https://github.com/expo/router/issues/452
|
13
8
|
Object.keys(options).length && navigation.setOptions(options);
|
14
|
-
}, [
|
9
|
+
}, [
|
10
|
+
navigation,
|
11
|
+
options
|
12
|
+
]), null;
|
15
13
|
}
|
16
|
-
export {
|
17
|
-
|
14
|
+
export {
|
15
|
+
Screen
|
16
|
+
};
|
17
|
+
//# sourceMappingURL=Screen.js.map
|
@@ -1 +1,6 @@
|
|
1
|
-
{
|
1
|
+
{
|
2
|
+
"version": 3,
|
3
|
+
"sources": ["../../../src/views/Users/n8/one/packages/one/src/views/Screen.tsx"],
|
4
|
+
"mappings": "AAAA,SAASA,iCAAiC;AAC1C,SAASC,qBAAqB;AAgBvB,SAASC,OAAyC,OAAwC;MAAxC,EAAEC,MAAMC,QAAO,IAAf,OACjDC,aAAaJ,cAAcE,IAAAA;AAEjCH,mCAA0B,WAAA;AACxB,IACEI;;IAGAE,OAAOC,KAAKH,OAAAA,EAASI,UAErBH,WAAWI,WAAWL,OAAAA;EAE1B,GAAG;IAACC;IAAYD;GAAQ,GAEjB;AACT;",
|
5
|
+
"names": ["useIsomorphicLayoutEffect", "useNavigation", "Screen", "name", "options", "navigation", "Object", "keys", "length", "setOptions"]
|
6
|
+
}
|
@@ -1,16 +1,13 @@
|
|
1
1
|
import { useEffect } from "react";
|
2
|
-
import { setLastAction } from "../router/lastAction
|
3
|
-
import { subscribeToLoadingState, subscribeToRootState } from "../router/router
|
4
|
-
var KEY = "one-sr",
|
5
|
-
|
6
|
-
|
7
|
-
},
|
8
|
-
isFirstLoad = !0;
|
2
|
+
import { setLastAction } from "../router/lastAction";
|
3
|
+
import { subscribeToLoadingState, subscribeToRootState } from "../router/router";
|
4
|
+
var KEY = "one-sr", getState = function() {
|
5
|
+
return JSON.parse(sessionStorage.getItem(KEY) || "{}");
|
6
|
+
}, isFirstLoad = !0;
|
9
7
|
function restorePosition() {
|
10
8
|
try {
|
11
|
-
var positions = getState(),
|
12
|
-
|
13
|
-
typeof saved == "number" && setTimeout(function () {
|
9
|
+
var positions = getState(), saved = positions[window.location.pathname];
|
10
|
+
typeof saved == "number" && setTimeout(function() {
|
14
11
|
window.scrollTo(0, saved);
|
15
12
|
});
|
16
13
|
} catch (error) {
|
@@ -28,31 +25,34 @@ function configure(props) {
|
|
28
25
|
if (!(typeof window > "u" || !window.addEventListener)) {
|
29
26
|
disable?.();
|
30
27
|
var popStateController = new AbortController();
|
31
|
-
window.addEventListener("popstate", function
|
28
|
+
window.addEventListener("popstate", function() {
|
32
29
|
didPop = !0, setLastAction();
|
33
30
|
}, {
|
34
31
|
signal: popStateController.signal
|
35
32
|
});
|
36
|
-
var disposeOnLoadState = subscribeToLoadingState(function
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
return disable = function () {
|
33
|
+
var disposeOnLoadState = subscribeToLoadingState(function(state) {
|
34
|
+
state === "loading" && rememberScrollPosition();
|
35
|
+
}), disposeOnRootState = subscribeToRootState(function(state) {
|
36
|
+
var _state_linkOptions;
|
37
|
+
if (isFirstLoad) {
|
38
|
+
isFirstLoad = !1;
|
39
|
+
return;
|
40
|
+
}
|
41
|
+
((_state_linkOptions = state.linkOptions) === null || _state_linkOptions === void 0 ? void 0 : _state_linkOptions.scroll) !== !1 && (didPop ? props.disable !== "restore" && restorePosition() : window.scrollTo(0, 0));
|
42
|
+
});
|
43
|
+
return disable = function() {
|
48
44
|
popStateController.abort(), disposeOnLoadState(), disposeOnRootState();
|
49
45
|
}, disable;
|
50
46
|
}
|
51
47
|
}
|
52
48
|
function ScrollRestoration(props) {
|
53
|
-
return useEffect(function
|
49
|
+
return useEffect(function() {
|
54
50
|
return configure(props);
|
55
|
-
}, [
|
51
|
+
}, [
|
52
|
+
props.disable
|
53
|
+
]), null;
|
56
54
|
}
|
57
|
-
export {
|
58
|
-
|
55
|
+
export {
|
56
|
+
ScrollRestoration
|
57
|
+
};
|
58
|
+
//# sourceMappingURL=ScrollRestoration.js.map
|
@@ -1 +1,6 @@
|
|
1
|
-
{
|
1
|
+
{
|
2
|
+
"version": 3,
|
3
|
+
"sources": ["../../../src/views/Users/n8/one/packages/one/src/views/ScrollRestoration.tsx"],
|
4
|
+
"mappings": "AAAA,SAASA,iBAAiB;AAC1B,SAASC,qBAAqB;AAC9B,SAASC,yBAAyBC,4BAA4B;AAE9D,IAAMC,MAAM,UAENC,WAAW,WAAA;SAAMC,KAAKC,MAAMC,eAAeC,QAAQL,GAAAA,KAAQ,IAAA;GAG7DM,cAAc;AAElB,SAASC,kBAAAA;AACP,MAAI;AACF,QAAMC,YAAYP,SAAAA,GACZQ,QAAQD,UAAUE,OAAOC,SAASC,QAAQ;AAChD,IAAI,OAAOH,SAAU,YACnBI,WAAW,WAAA;AACTH,aAAOI,SAAS,GAAGL,KAAAA;IACrB,CAAA;EAEJ,SAASM,OAAO;AACdC,YAAQD,MAAM,mCAAmCA,KAAAA,GACjDX,eAAea,WAAWjB,GAAAA;EAC5B;AACF;AAEA,IAAIkB,SAAS;AAEb,SAASC,yBAAAA;AACPD,WAAS;AACT,MAAME,QAAQnB,SAAAA;AACdmB,QAAMV,OAAOC,SAASC,QAAQ,IAAIF,OAAOW,SACzCjB,eAAekB,QAAQtB,KAAKE,KAAKqB,UAAUH,KAAAA,CAAAA;AAC7C;AAMA,IAAII,UAA+B;AAEnC,SAASC,UAAUC,OAA6B;AAC9C,MAAI,SAAOhB,SAAW,OAAe,CAACA,OAAOiB,mBAI7CH;IAAAA,UAAAA;AAEA,QAAMI,qBAAqB,IAAIC,gBAAAA;AAE/BnB,WAAOiB,iBACL,YACA,WAAA;AACET,eAAS,IACTrB,cAAAA;IACF,GACA;MACEiC,QAAQF,mBAAmBE;IAC7B,CAAA;AAGF,QAAMC,qBAAqBjC,wBAAwB,SAACsB,OAAAA;AAClD,MAAIA,UAAU,aACZD,uBAAAA;IAEJ,CAAA,GAEMa,qBAAqBjC,qBAAqB,SAACqB,OAAAA;UAM3CA;AALJ,UAAId,aAAa;AACfA,sBAAc;AACd;MACF;AAEA,QAAIc,qBAAAA,MAAMa,iBAAW,QAAjBb,uBAAAA,SAAAA,SAAAA,mBAAmBc,YAAW,OAI9BhB,SACEQ,MAAMF,YAAY,aAEpBjB,gBAAAA,IAIFG,OAAOI,SAAS,GAAG,CAAA;IAEvB,CAAA;AAEAU,qBAAU,WAAA;AACRI,yBAAmBO,MAAK,GACxBJ,mBAAAA,GACAC,mBAAAA;IACF,GAEOR;;AACT;AAEO,SAASY,kBAAkBV,OAA6B;AAC7D9B,mBAAU,WAAA;AACR,WAAO6B,UAAUC,KAAAA;EACnB,GAAG;IAACA,MAAMF;GAAQ,GAEX;AACT;",
|
5
|
+
"names": ["useEffect", "setLastAction", "subscribeToLoadingState", "subscribeToRootState", "KEY", "getState", "JSON", "parse", "sessionStorage", "getItem", "isFirstLoad", "restorePosition", "positions", "saved", "window", "location", "pathname", "setTimeout", "scrollTo", "error", "console", "removeItem", "didPop", "rememberScrollPosition", "state", "scrollY", "setItem", "stringify", "disable", "configure", "props", "addEventListener", "popStateController", "AbortController", "signal", "disposeOnLoadState", "disposeOnRootState", "linkOptions", "scroll", "abort", "ScrollRestoration"]
|
6
|
+
}
|
@@ -1,14 +1,16 @@
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
2
2
|
import React from "react";
|
3
3
|
function _assert_this_initialized(self) {
|
4
|
-
if (self === void 0)
|
4
|
+
if (self === void 0)
|
5
|
+
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
5
6
|
return self;
|
6
7
|
}
|
7
8
|
function _call_super(_this, derived, args) {
|
8
9
|
return derived = _get_prototype_of(derived), _possible_constructor_return(_this, _is_native_reflect_construct() ? Reflect.construct(derived, args || [], _get_prototype_of(_this).constructor) : derived.apply(_this, args));
|
9
10
|
}
|
10
11
|
function _class_call_check(instance, Constructor) {
|
11
|
-
if (!(instance instanceof Constructor))
|
12
|
+
if (!(instance instanceof Constructor))
|
13
|
+
throw new TypeError("Cannot call a class as a function");
|
12
14
|
}
|
13
15
|
function _defineProperties(target, props) {
|
14
16
|
for (var i = 0; i < props.length; i++) {
|
@@ -28,12 +30,13 @@ function _define_property(obj, key, value) {
|
|
28
30
|
}) : obj[key] = value, obj;
|
29
31
|
}
|
30
32
|
function _get_prototype_of(o) {
|
31
|
-
return _get_prototype_of = Object.setPrototypeOf ? Object.getPrototypeOf : function
|
33
|
+
return _get_prototype_of = Object.setPrototypeOf ? Object.getPrototypeOf : function(o2) {
|
32
34
|
return o2.__proto__ || Object.getPrototypeOf(o2);
|
33
35
|
}, _get_prototype_of(o);
|
34
36
|
}
|
35
37
|
function _inherits(subClass, superClass) {
|
36
|
-
if (typeof superClass != "function" && superClass !== null)
|
38
|
+
if (typeof superClass != "function" && superClass !== null)
|
39
|
+
throw new TypeError("Super expression must either be null or a function");
|
37
40
|
subClass.prototype = Object.create(superClass && superClass.prototype, {
|
38
41
|
constructor: {
|
39
42
|
value: subClass,
|
@@ -46,65 +49,65 @@ function _possible_constructor_return(self, call) {
|
|
46
49
|
return call && (_type_of(call) === "object" || typeof call == "function") ? call : _assert_this_initialized(self);
|
47
50
|
}
|
48
51
|
function _set_prototype_of(o, p) {
|
49
|
-
return _set_prototype_of = Object.setPrototypeOf || function
|
52
|
+
return _set_prototype_of = Object.setPrototypeOf || function(o2, p2) {
|
50
53
|
return o2.__proto__ = p2, o2;
|
51
54
|
}, _set_prototype_of(o, p);
|
52
55
|
}
|
53
56
|
function _type_of(obj) {
|
54
57
|
"@swc/helpers - typeof";
|
55
|
-
|
56
58
|
return obj && typeof Symbol < "u" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
57
59
|
}
|
58
60
|
function _is_native_reflect_construct() {
|
59
61
|
try {
|
60
|
-
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function
|
61
|
-
|
62
|
-
|
62
|
+
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
63
|
+
}));
|
64
|
+
} catch {
|
65
|
+
}
|
66
|
+
return (_is_native_reflect_construct = function() {
|
63
67
|
return !!result;
|
64
68
|
})();
|
65
69
|
}
|
66
|
-
var Try = /* @__PURE__ */function
|
70
|
+
var Try = /* @__PURE__ */ function(_React_Component) {
|
67
71
|
"use strict";
|
68
|
-
|
69
72
|
_inherits(Try2, _React_Component);
|
70
73
|
function Try2() {
|
71
74
|
_class_call_check(this, Try2);
|
72
75
|
var _this;
|
73
76
|
return _this = _call_super(this, Try2, arguments), _define_property(_this, "state", {
|
74
77
|
error: void 0
|
75
|
-
}), _define_property(_this, "retry", function
|
76
|
-
return new Promise(function
|
78
|
+
}), _define_property(_this, "retry", function() {
|
79
|
+
return new Promise(function(resolve) {
|
77
80
|
_this.setState({
|
78
81
|
error: void 0
|
79
|
-
}, function
|
82
|
+
}, function() {
|
80
83
|
resolve();
|
81
84
|
});
|
82
85
|
});
|
83
86
|
}), _this;
|
84
87
|
}
|
85
|
-
return _create_class(Try2, [
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
return error ? /* @__PURE__ */_jsx(ErrorBoundary, {
|
96
|
-
error,
|
97
|
-
retry: this.retry
|
98
|
-
}) : children;
|
88
|
+
return _create_class(Try2, [
|
89
|
+
{
|
90
|
+
key: "render",
|
91
|
+
value: function() {
|
92
|
+
var { error } = this.state, { catch: ErrorBoundary, children } = this.props;
|
93
|
+
return error ? /* @__PURE__ */ _jsx(ErrorBoundary, {
|
94
|
+
error,
|
95
|
+
retry: this.retry
|
96
|
+
}) : children;
|
97
|
+
}
|
99
98
|
}
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
99
|
+
], [
|
100
|
+
{
|
101
|
+
key: "getDerivedStateFromError",
|
102
|
+
value: function(error) {
|
103
|
+
return {
|
104
|
+
error
|
105
|
+
};
|
106
|
+
}
|
106
107
|
}
|
107
|
-
|
108
|
+
]), Try2;
|
108
109
|
}(React.Component);
|
109
|
-
export {
|
110
|
-
|
110
|
+
export {
|
111
|
+
Try
|
112
|
+
};
|
113
|
+
//# sourceMappingURL=Try.js.map
|
@@ -1 +1,6 @@
|
|
1
|
-
{
|
1
|
+
{
|
2
|
+
"version": 3,
|
3
|
+
"sources": ["../../../src/views/Users/n8/one/packages/one/src/views/Try.tsx"],
|
4
|
+
"mappings": ";AAAA,OAAOA,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAWX,IAAMC,MAAN,yBAAA,kBAAA;;YAAMA,MAAAA,gBAAAA;WAAAA,OAAAA;4BAAAA,IAAAA;;qCAAAA,MAAAA,SAAAA,GAOXC,iBAAAA,OAAAA,SAAQ;MAAEC,OAAOC;IAAU,CAAA,GAS3BC,iBAAAA,OAAAA,SAAQ,WAAA;AACN,aAAO,IAAIC,QAAc,SAACC,SAAAA;AACxB,cAAKC,SAAS;UAAEL,OAAOC;QAAU,GAAG,WAAA;AAClCG,kBAAAA;QACF,CAAA;MACF,CAAA;IACF,CAAA;;uBAtBWN,MAAAA;;MAwBXQ,KAAAA;aAAAA,WAAAA;AACE,YAAM,EAAEN,MAAK,IAAK,KAAKD,OACjB,EAAEQ,OAAOC,eAAeC,SAAQ,IAAK,KAAKC;AAChD,eAAKV,QAGE,qBAACQ,eAAAA;UAAcR;UAAcE,OAAO,KAAKA;aAFvCO;MAGX;;;;MAtBOE,KAAAA;aAAP,SAAgCX,OAAY;AAI1C,eAAO;UAAEA;QAAM;MACjB;;MAdWF;EAAYD,MAAMe,SAAS;",
|
5
|
+
"names": ["React", "Try", "state", "error", "undefined", "retry", "Promise", "resolve", "setState", "render", "catch", "ErrorBoundary", "children", "props", "getDerivedStateFromError", "Component"]
|
6
|
+
}
|