react-native-screen-transitions 2.4.2-beta.2 → 3.0.0-beta.0
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 +85 -71
- package/lib/commonjs/blank-stack/components/Overlay.js +128 -0
- package/lib/commonjs/blank-stack/components/Overlay.js.map +1 -0
- package/lib/commonjs/blank-stack/components/Screens.js +64 -0
- package/lib/commonjs/blank-stack/components/Screens.js.map +1 -0
- package/lib/commonjs/blank-stack/components/StackView.js +87 -0
- package/lib/commonjs/blank-stack/components/StackView.js.map +1 -0
- package/lib/commonjs/blank-stack/hooks/use-overlay-animation.js +77 -0
- package/lib/commonjs/blank-stack/hooks/use-overlay-animation.js.map +1 -0
- package/lib/commonjs/blank-stack/index.js +13 -0
- package/lib/commonjs/blank-stack/index.js.map +1 -0
- package/lib/commonjs/blank-stack/navigators/createBlankStackNavigator.js.map +1 -0
- package/lib/commonjs/blank-stack/types.js +6 -0
- package/lib/commonjs/blank-stack/types.js.map +1 -0
- package/lib/commonjs/blank-stack/utils/with-stack-navigation/_hooks/use-closing-route-keys.js +72 -0
- package/lib/commonjs/blank-stack/utils/with-stack-navigation/_hooks/use-closing-route-keys.js.map +1 -0
- package/lib/commonjs/blank-stack/utils/with-stack-navigation/_hooks/use-previous.js.map +1 -0
- package/lib/commonjs/blank-stack/utils/with-stack-navigation/_hooks/use-stack-navigation-state.js +196 -0
- package/lib/commonjs/blank-stack/utils/with-stack-navigation/_hooks/use-stack-navigation-state.js.map +1 -0
- package/lib/commonjs/blank-stack/utils/with-stack-navigation/_types.js.map +1 -0
- package/lib/commonjs/blank-stack/utils/with-stack-navigation/_utils/are-descriptors-equal.js.map +1 -0
- package/lib/commonjs/blank-stack/utils/with-stack-navigation/_utils/calculate-active-screens-limit.js.map +1 -0
- package/lib/commonjs/blank-stack/utils/with-stack-navigation/_utils/compose-descriptors.js +25 -0
- package/lib/commonjs/blank-stack/utils/with-stack-navigation/_utils/compose-descriptors.js.map +1 -0
- package/lib/commonjs/blank-stack/utils/with-stack-navigation/_utils/have-same-route-keys.js.map +1 -0
- package/lib/commonjs/blank-stack/utils/with-stack-navigation/_utils/routes-are-identical.js.map +1 -0
- package/lib/commonjs/blank-stack/utils/with-stack-navigation/index.js +66 -0
- package/lib/commonjs/blank-stack/utils/with-stack-navigation/index.js.map +1 -0
- package/lib/commonjs/native-stack/index.js +13 -0
- package/lib/commonjs/native-stack/index.js.map +1 -0
- package/lib/commonjs/native-stack/navigators/createNativeStackNavigator.js.map +1 -0
- package/lib/commonjs/native-stack/types.js +6 -0
- package/lib/commonjs/native-stack/types.js.map +1 -0
- package/lib/commonjs/native-stack/utils/debounce.js.map +1 -0
- package/lib/commonjs/native-stack/utils/getModalRoutesKeys.js.map +1 -0
- package/lib/commonjs/native-stack/utils/useAnimatedHeaderHeight.js.map +1 -0
- package/lib/commonjs/native-stack/utils/useDismissedRouteError.js.map +1 -0
- package/lib/commonjs/native-stack/utils/useInvalidPreventRemoveError.js.map +1 -0
- package/lib/commonjs/native-stack/views/FontProcessor.js.map +1 -0
- package/lib/commonjs/native-stack/views/FontProcessor.native.js.map +1 -0
- package/lib/commonjs/native-stack/views/FooterComponent.js.map +1 -0
- package/lib/commonjs/native-stack/views/NativeStackView.js.map +1 -0
- package/lib/commonjs/native-stack/views/NativeStackView.native.js +493 -0
- package/lib/commonjs/native-stack/views/NativeStackView.native.js.map +1 -0
- package/lib/commonjs/native-stack/views/useHeaderConfigProps.js.map +1 -0
- package/lib/commonjs/shared/components/controllers/screen-lifecycle.js +128 -0
- package/lib/commonjs/shared/components/controllers/screen-lifecycle.js.map +1 -0
- package/lib/commonjs/shared/components/create-transition-aware-component.js.map +1 -0
- package/lib/commonjs/shared/components/integrations/masked-view.js.map +1 -0
- package/lib/commonjs/shared/components/root-transition-aware.js.map +1 -0
- package/lib/commonjs/shared/configs/index.js +22 -0
- package/lib/commonjs/shared/configs/index.js.map +1 -0
- package/lib/commonjs/shared/configs/presets.js.map +1 -0
- package/lib/commonjs/shared/configs/specs.js.map +1 -0
- package/lib/commonjs/shared/constants.js.map +1 -0
- package/lib/commonjs/shared/hooks/animation/use-associated-style.js.map +1 -0
- package/lib/commonjs/shared/hooks/animation/use-screen-animation.js +118 -0
- package/lib/commonjs/shared/hooks/animation/use-screen-animation.js.map +1 -0
- package/lib/commonjs/shared/hooks/bounds/use-bound-registry.js +131 -0
- package/lib/commonjs/shared/hooks/bounds/use-bound-registry.js.map +1 -0
- package/lib/commonjs/shared/hooks/gestures/use-build-gestures.js +236 -0
- package/lib/commonjs/shared/hooks/gestures/use-build-gestures.js.map +1 -0
- package/lib/commonjs/shared/hooks/gestures/use-parent-gesture-registry.js.map +1 -0
- package/lib/commonjs/shared/hooks/gestures/use-scroll-registry.js.map +1 -0
- package/lib/commonjs/shared/hooks/use-shared-value-state.js +25 -0
- package/lib/commonjs/shared/hooks/use-shared-value-state.js.map +1 -0
- package/lib/commonjs/shared/hooks/use-stable-callback-value.js.map +1 -0
- package/lib/commonjs/shared/hooks/use-stable-callback.js.map +1 -0
- package/lib/commonjs/shared/index.js +33 -0
- package/lib/commonjs/shared/index.js.map +1 -0
- package/lib/commonjs/shared/providers/gestures.js.map +1 -0
- package/lib/commonjs/shared/providers/keys.js +34 -0
- package/lib/commonjs/shared/providers/keys.js.map +1 -0
- package/lib/commonjs/shared/providers/screen-transition-provider.js +34 -0
- package/lib/commonjs/shared/providers/screen-transition-provider.js.map +1 -0
- package/lib/commonjs/shared/providers/transition-styles.js +62 -0
- package/lib/commonjs/shared/providers/transition-styles.js.map +1 -0
- package/lib/commonjs/shared/providers/utils/create-provider.js +39 -0
- package/lib/commonjs/shared/providers/utils/create-provider.js.map +1 -0
- package/lib/commonjs/shared/stores/animation-store.js +39 -0
- package/lib/commonjs/shared/stores/animation-store.js.map +1 -0
- package/lib/commonjs/shared/stores/bound-store/_utils.js.map +1 -0
- package/lib/commonjs/shared/stores/bound-store/index.js +116 -0
- package/lib/commonjs/shared/stores/bound-store/index.js.map +1 -0
- package/lib/commonjs/shared/stores/gesture-store.js +39 -0
- package/lib/commonjs/shared/stores/gesture-store.js.map +1 -0
- package/lib/commonjs/shared/stores/navigator-dismiss-state.js.map +1 -0
- package/lib/commonjs/shared/stores/utils/reset-stores-for-screen.js +19 -0
- package/lib/commonjs/shared/stores/utils/reset-stores-for-screen.js.map +1 -0
- package/lib/commonjs/shared/types/animation.js.map +1 -0
- package/lib/commonjs/shared/types/bounds.js.map +1 -0
- package/lib/commonjs/shared/types/core.js.map +1 -0
- package/lib/commonjs/shared/types/gesture.js.map +1 -0
- package/lib/commonjs/shared/types/utils.js.map +1 -0
- package/lib/commonjs/shared/utils/animation/animate.js.map +1 -0
- package/lib/commonjs/shared/utils/animation/derivations.js +39 -0
- package/lib/commonjs/shared/utils/animation/derivations.js.map +1 -0
- package/lib/commonjs/shared/utils/animation/start-screen-transition.js.map +1 -0
- package/lib/commonjs/shared/utils/bounds/_types/builder.js.map +1 -0
- package/lib/commonjs/shared/utils/bounds/_types/geometry.js.map +1 -0
- package/lib/commonjs/shared/utils/bounds/_types/get-bounds.js.map +1 -0
- package/lib/commonjs/shared/utils/bounds/_utils/flatten-styles.js.map +1 -0
- package/lib/commonjs/shared/utils/bounds/_utils/geometry.js.map +1 -0
- package/lib/commonjs/shared/utils/bounds/_utils/get-bounds.js.map +1 -0
- package/lib/commonjs/shared/utils/bounds/_utils/is-bounds-equal.js +19 -0
- package/lib/commonjs/shared/utils/bounds/_utils/is-bounds-equal.js.map +1 -0
- package/lib/commonjs/shared/utils/bounds/_utils/style-composers.js.map +1 -0
- package/lib/commonjs/shared/utils/bounds/_utils/styles.js.map +1 -0
- package/lib/commonjs/shared/utils/bounds/constants.js.map +1 -0
- package/lib/commonjs/shared/utils/bounds/index.js.map +1 -0
- package/lib/commonjs/shared/utils/gesture/apply-offset-rules.js.map +1 -0
- package/lib/commonjs/shared/utils/gesture/check-gesture-activation.js.map +1 -0
- package/lib/commonjs/shared/utils/gesture/determine-dismissal.js.map +1 -0
- package/lib/commonjs/shared/utils/gesture/map-gesture-to-progress.js.map +1 -0
- package/lib/commonjs/shared/utils/gesture/reset-gesture-values.js.map +1 -0
- package/lib/commonjs/shared/utils/gesture/velocity.js.map +1 -0
- package/lib/commonjs/shared/utils/reanimated/version.js.map +1 -0
- package/lib/module/blank-stack/components/Overlay.js +124 -0
- package/lib/module/blank-stack/components/Overlay.js.map +1 -0
- package/lib/module/blank-stack/components/Screens.js +58 -0
- package/lib/module/blank-stack/components/Screens.js.map +1 -0
- package/lib/module/blank-stack/components/StackView.js +83 -0
- package/lib/module/blank-stack/components/StackView.js.map +1 -0
- package/lib/module/blank-stack/hooks/use-overlay-animation.js +73 -0
- package/lib/module/blank-stack/hooks/use-overlay-animation.js.map +1 -0
- package/lib/module/blank-stack/index.js +4 -0
- package/lib/module/blank-stack/index.js.map +1 -0
- package/lib/module/blank-stack/navigators/createBlankStackNavigator.js.map +1 -0
- package/lib/module/blank-stack/types.js +4 -0
- package/lib/module/blank-stack/types.js.map +1 -0
- package/lib/module/blank-stack/utils/with-stack-navigation/_hooks/use-closing-route-keys.js +66 -0
- package/lib/module/blank-stack/utils/with-stack-navigation/_hooks/use-closing-route-keys.js.map +1 -0
- package/lib/module/blank-stack/utils/with-stack-navigation/_hooks/use-previous.js.map +1 -0
- package/lib/module/blank-stack/utils/with-stack-navigation/_hooks/use-stack-navigation-state.js +190 -0
- package/lib/module/blank-stack/utils/with-stack-navigation/_hooks/use-stack-navigation-state.js.map +1 -0
- package/lib/module/blank-stack/utils/with-stack-navigation/_types.js.map +1 -0
- package/lib/module/blank-stack/utils/with-stack-navigation/_utils/are-descriptors-equal.js.map +1 -0
- package/lib/module/blank-stack/utils/with-stack-navigation/_utils/calculate-active-screens-limit.js.map +1 -0
- package/lib/module/blank-stack/utils/with-stack-navigation/_utils/compose-descriptors.js +20 -0
- package/lib/module/blank-stack/utils/with-stack-navigation/_utils/compose-descriptors.js.map +1 -0
- package/lib/module/blank-stack/utils/with-stack-navigation/_utils/have-same-route-keys.js.map +1 -0
- package/lib/module/blank-stack/utils/with-stack-navigation/_utils/routes-are-identical.js.map +1 -0
- package/lib/module/blank-stack/utils/with-stack-navigation/index.js +60 -0
- package/lib/module/blank-stack/utils/with-stack-navigation/index.js.map +1 -0
- package/lib/module/native-stack/index.js +4 -0
- package/lib/module/native-stack/index.js.map +1 -0
- package/lib/module/native-stack/navigators/createNativeStackNavigator.js.map +1 -0
- package/lib/module/native-stack/types.js +4 -0
- package/lib/module/native-stack/types.js.map +1 -0
- package/lib/module/native-stack/utils/debounce.js.map +1 -0
- package/lib/module/native-stack/utils/getModalRoutesKeys.js.map +1 -0
- package/lib/module/native-stack/utils/useAnimatedHeaderHeight.js.map +1 -0
- package/lib/module/native-stack/utils/useDismissedRouteError.js.map +1 -0
- package/lib/module/native-stack/utils/useInvalidPreventRemoveError.js.map +1 -0
- package/lib/module/native-stack/views/FontProcessor.js.map +1 -0
- package/lib/module/native-stack/views/FontProcessor.native.js.map +1 -0
- package/lib/module/native-stack/views/FooterComponent.js.map +1 -0
- package/lib/module/native-stack/views/NativeStackView.js.map +1 -0
- package/lib/module/native-stack/views/NativeStackView.native.js +488 -0
- package/lib/module/native-stack/views/NativeStackView.native.js.map +1 -0
- package/lib/module/native-stack/views/useHeaderConfigProps.js.map +1 -0
- package/lib/module/shared/components/controllers/screen-lifecycle.js +122 -0
- package/lib/module/shared/components/controllers/screen-lifecycle.js.map +1 -0
- package/lib/module/shared/components/create-transition-aware-component.js.map +1 -0
- package/lib/module/shared/components/integrations/masked-view.js.map +1 -0
- package/lib/module/shared/components/root-transition-aware.js.map +1 -0
- package/lib/module/shared/configs/index.js +18 -0
- package/lib/module/shared/configs/index.js.map +1 -0
- package/lib/module/shared/configs/presets.js.map +1 -0
- package/lib/module/shared/configs/specs.js.map +1 -0
- package/lib/module/shared/constants.js.map +1 -0
- package/lib/module/shared/hooks/animation/use-associated-style.js.map +1 -0
- package/lib/module/shared/hooks/animation/use-screen-animation.js +113 -0
- package/lib/module/shared/hooks/animation/use-screen-animation.js.map +1 -0
- package/lib/module/shared/hooks/bounds/use-bound-registry.js +125 -0
- package/lib/module/shared/hooks/bounds/use-bound-registry.js.map +1 -0
- package/lib/module/shared/hooks/gestures/use-build-gestures.js +230 -0
- package/lib/module/shared/hooks/gestures/use-build-gestures.js.map +1 -0
- package/lib/module/shared/hooks/gestures/use-parent-gesture-registry.js.map +1 -0
- package/lib/module/shared/hooks/gestures/use-scroll-registry.js.map +1 -0
- package/lib/module/shared/hooks/use-shared-value-state.js +22 -0
- package/lib/module/shared/hooks/use-shared-value-state.js.map +1 -0
- package/lib/module/shared/hooks/use-stable-callback-value.js.map +1 -0
- package/lib/module/shared/hooks/use-stable-callback.js.map +1 -0
- package/lib/module/shared/index.js +22 -0
- package/lib/module/shared/index.js.map +1 -0
- package/lib/module/shared/providers/gestures.js.map +1 -0
- package/lib/module/shared/providers/keys.js +29 -0
- package/lib/module/shared/providers/keys.js.map +1 -0
- package/lib/module/shared/providers/screen-transition-provider.js +30 -0
- package/lib/module/shared/providers/screen-transition-provider.js.map +1 -0
- package/lib/module/shared/providers/transition-styles.js +57 -0
- package/lib/module/shared/providers/transition-styles.js.map +1 -0
- package/lib/module/shared/providers/utils/create-provider.js +33 -0
- package/lib/module/shared/providers/utils/create-provider.js.map +1 -0
- package/lib/module/shared/stores/animation-store.js +33 -0
- package/lib/module/shared/stores/animation-store.js.map +1 -0
- package/lib/module/shared/stores/bound-store/_utils.js.map +1 -0
- package/lib/module/shared/stores/bound-store/index.js +112 -0
- package/lib/module/shared/stores/bound-store/index.js.map +1 -0
- package/lib/module/shared/stores/gesture-store.js +35 -0
- package/lib/module/shared/stores/gesture-store.js.map +1 -0
- package/lib/module/shared/stores/navigator-dismiss-state.js.map +1 -0
- package/lib/module/shared/stores/utils/reset-stores-for-screen.js +15 -0
- package/lib/module/shared/stores/utils/reset-stores-for-screen.js.map +1 -0
- package/lib/module/shared/types/animation.js.map +1 -0
- package/lib/module/shared/types/bounds.js.map +1 -0
- package/lib/module/shared/types/core.js.map +1 -0
- package/lib/module/shared/types/gesture.js.map +1 -0
- package/lib/module/shared/types/utils.js.map +1 -0
- package/lib/module/shared/utils/animation/animate.js.map +1 -0
- package/lib/module/shared/utils/animation/derivations.js +34 -0
- package/lib/module/shared/utils/animation/derivations.js.map +1 -0
- package/lib/module/shared/utils/animation/start-screen-transition.js.map +1 -0
- package/lib/module/shared/utils/bounds/_types/builder.js.map +1 -0
- package/lib/module/shared/utils/bounds/_types/geometry.js.map +1 -0
- package/lib/module/shared/utils/bounds/_types/get-bounds.js.map +1 -0
- package/lib/module/shared/utils/bounds/_utils/flatten-styles.js.map +1 -0
- package/lib/module/shared/utils/bounds/_utils/geometry.js.map +1 -0
- package/lib/module/shared/utils/bounds/_utils/get-bounds.js.map +1 -0
- package/lib/module/shared/utils/bounds/_utils/is-bounds-equal.js +14 -0
- package/lib/module/shared/utils/bounds/_utils/is-bounds-equal.js.map +1 -0
- package/lib/module/shared/utils/bounds/_utils/style-composers.js.map +1 -0
- package/lib/module/shared/utils/bounds/_utils/styles.js.map +1 -0
- package/lib/module/shared/utils/bounds/constants.js.map +1 -0
- package/lib/module/shared/utils/bounds/index.js.map +1 -0
- package/lib/module/shared/utils/gesture/apply-offset-rules.js.map +1 -0
- package/lib/module/shared/utils/gesture/check-gesture-activation.js.map +1 -0
- package/lib/module/shared/utils/gesture/determine-dismissal.js.map +1 -0
- package/lib/module/shared/utils/gesture/map-gesture-to-progress.js.map +1 -0
- package/lib/module/shared/utils/gesture/reset-gesture-values.js.map +1 -0
- package/lib/module/shared/utils/gesture/velocity.js.map +1 -0
- package/lib/module/shared/utils/reanimated/version.js.map +1 -0
- package/lib/typescript/blank-stack/components/Overlay.d.ts +5 -0
- package/lib/typescript/blank-stack/components/Overlay.d.ts.map +1 -0
- package/lib/typescript/blank-stack/components/Screens.d.ts.map +1 -0
- package/lib/typescript/blank-stack/components/StackView.d.ts.map +1 -0
- package/lib/typescript/blank-stack/hooks/use-overlay-animation.d.ts +12 -0
- package/lib/typescript/blank-stack/hooks/use-overlay-animation.d.ts.map +1 -0
- package/lib/typescript/blank-stack/index.d.ts +3 -0
- package/lib/typescript/blank-stack/index.d.ts.map +1 -0
- package/lib/typescript/blank-stack/navigators/createBlankStackNavigator.d.ts +16 -0
- package/lib/typescript/blank-stack/navigators/createBlankStackNavigator.d.ts.map +1 -0
- package/lib/typescript/blank-stack/types.d.ts +213 -0
- package/lib/typescript/blank-stack/types.d.ts.map +1 -0
- package/lib/typescript/blank-stack/utils/with-stack-navigation/_hooks/use-closing-route-keys.d.ts.map +1 -0
- package/lib/typescript/blank-stack/utils/with-stack-navigation/_hooks/use-previous.d.ts.map +1 -0
- package/lib/typescript/blank-stack/utils/with-stack-navigation/_hooks/use-stack-navigation-state.d.ts +20 -0
- package/lib/typescript/blank-stack/utils/with-stack-navigation/_hooks/use-stack-navigation-state.d.ts.map +1 -0
- package/lib/typescript/blank-stack/utils/with-stack-navigation/_types.d.ts +22 -0
- package/lib/typescript/blank-stack/utils/with-stack-navigation/_types.d.ts.map +1 -0
- package/lib/typescript/blank-stack/utils/with-stack-navigation/_utils/are-descriptors-equal.d.ts +3 -0
- package/lib/typescript/blank-stack/utils/with-stack-navigation/_utils/are-descriptors-equal.d.ts.map +1 -0
- package/lib/typescript/blank-stack/utils/with-stack-navigation/_utils/calculate-active-screens-limit.d.ts +4 -0
- package/lib/typescript/blank-stack/utils/with-stack-navigation/_utils/calculate-active-screens-limit.d.ts.map +1 -0
- package/lib/typescript/blank-stack/utils/with-stack-navigation/_utils/compose-descriptors.d.ts +4 -0
- package/lib/typescript/blank-stack/utils/with-stack-navigation/_utils/compose-descriptors.d.ts.map +1 -0
- package/lib/typescript/blank-stack/utils/with-stack-navigation/_utils/have-same-route-keys.d.ts.map +1 -0
- package/lib/typescript/blank-stack/utils/with-stack-navigation/_utils/routes-are-identical.d.ts.map +1 -0
- package/lib/typescript/blank-stack/utils/with-stack-navigation/index.d.ts.map +1 -0
- package/lib/typescript/native-stack/index.d.ts +3 -0
- package/lib/typescript/native-stack/index.d.ts.map +1 -0
- package/lib/typescript/native-stack/navigators/createNativeStackNavigator.d.ts +16 -0
- package/lib/typescript/native-stack/navigators/createNativeStackNavigator.d.ts.map +1 -0
- package/lib/typescript/native-stack/types.d.ts +651 -0
- package/lib/typescript/native-stack/types.d.ts.map +1 -0
- package/lib/typescript/native-stack/utils/debounce.d.ts.map +1 -0
- package/lib/typescript/native-stack/utils/getModalRoutesKeys.d.ts +4 -0
- package/lib/typescript/native-stack/utils/getModalRoutesKeys.d.ts.map +1 -0
- package/lib/typescript/native-stack/utils/useAnimatedHeaderHeight.d.ts.map +1 -0
- package/lib/typescript/native-stack/utils/useDismissedRouteError.d.ts.map +1 -0
- package/lib/typescript/native-stack/utils/useInvalidPreventRemoveError.d.ts +3 -0
- package/lib/typescript/native-stack/utils/useInvalidPreventRemoveError.d.ts.map +1 -0
- package/lib/typescript/native-stack/views/FontProcessor.d.ts.map +1 -0
- package/lib/typescript/native-stack/views/FontProcessor.native.d.ts.map +1 -0
- package/lib/typescript/native-stack/views/FooterComponent.d.ts.map +1 -0
- package/lib/typescript/native-stack/views/NativeStackView.d.ts +11 -0
- package/lib/typescript/native-stack/views/NativeStackView.d.ts.map +1 -0
- package/lib/typescript/native-stack/views/NativeStackView.native.d.ts +11 -0
- package/lib/typescript/native-stack/views/NativeStackView.native.d.ts.map +1 -0
- package/lib/typescript/native-stack/views/useHeaderConfigProps.d.ts +44 -0
- package/lib/typescript/native-stack/views/useHeaderConfigProps.d.ts.map +1 -0
- package/lib/typescript/shared/components/controllers/screen-lifecycle.d.ts +12 -0
- package/lib/typescript/shared/components/controllers/screen-lifecycle.d.ts.map +1 -0
- package/lib/typescript/shared/components/create-transition-aware-component.d.ts.map +1 -0
- package/lib/typescript/shared/components/integrations/masked-view.d.ts.map +1 -0
- package/lib/typescript/shared/components/root-transition-aware.d.ts.map +1 -0
- package/lib/typescript/shared/configs/index.d.ts +16 -0
- package/lib/typescript/shared/configs/index.d.ts.map +1 -0
- package/lib/typescript/shared/configs/presets.d.ts +12 -0
- package/lib/typescript/shared/configs/presets.d.ts.map +1 -0
- package/lib/typescript/shared/configs/specs.d.ts.map +1 -0
- package/lib/typescript/shared/constants.d.ts +57 -0
- package/lib/typescript/shared/constants.d.ts.map +1 -0
- package/lib/typescript/shared/hooks/animation/use-associated-style.d.ts.map +1 -0
- package/lib/typescript/shared/hooks/animation/use-screen-animation.d.ts +7 -0
- package/lib/typescript/shared/hooks/animation/use-screen-animation.d.ts.map +1 -0
- package/lib/typescript/shared/hooks/bounds/use-bound-registry.d.ts.map +1 -0
- package/lib/typescript/shared/hooks/gestures/use-build-gestures.d.ts.map +1 -0
- package/lib/typescript/shared/hooks/gestures/use-parent-gesture-registry.d.ts.map +1 -0
- package/lib/typescript/shared/hooks/gestures/use-scroll-registry.d.ts.map +1 -0
- package/lib/typescript/shared/hooks/use-shared-value-state.d.ts +7 -0
- package/lib/typescript/shared/hooks/use-shared-value-state.d.ts.map +1 -0
- package/lib/typescript/shared/hooks/use-stable-callback-value.d.ts.map +1 -0
- package/lib/typescript/shared/hooks/use-stable-callback.d.ts.map +1 -0
- package/lib/typescript/shared/index.d.ts +1323 -0
- package/lib/typescript/shared/index.d.ts.map +1 -0
- package/lib/typescript/shared/providers/gestures.d.ts.map +1 -0
- package/lib/typescript/shared/providers/keys.d.ts +18 -0
- package/lib/typescript/shared/providers/keys.d.ts.map +1 -0
- package/lib/typescript/shared/providers/screen-transition-provider.d.ts +14 -0
- package/lib/typescript/shared/providers/screen-transition-provider.d.ts.map +1 -0
- package/lib/typescript/shared/providers/transition-styles.d.ts +11 -0
- package/lib/typescript/shared/providers/transition-styles.d.ts.map +1 -0
- package/lib/typescript/shared/providers/utils/create-provider.d.ts +32 -0
- package/lib/typescript/shared/providers/utils/create-provider.d.ts.map +1 -0
- package/lib/typescript/shared/stores/animation-store.d.ts +17 -0
- package/lib/typescript/shared/stores/animation-store.d.ts.map +1 -0
- package/lib/typescript/shared/stores/bound-store/_utils.d.ts.map +1 -0
- package/lib/typescript/shared/stores/bound-store/index.d.ts +22 -0
- package/lib/typescript/shared/stores/bound-store/index.d.ts.map +1 -0
- package/lib/typescript/shared/stores/gesture-store.d.ts +23 -0
- package/lib/typescript/shared/stores/gesture-store.d.ts.map +1 -0
- package/lib/typescript/shared/stores/navigator-dismiss-state.d.ts.map +1 -0
- package/lib/typescript/shared/stores/utils/reset-stores-for-screen.d.ts +6 -0
- package/lib/typescript/shared/stores/utils/reset-stores-for-screen.d.ts.map +1 -0
- package/lib/typescript/shared/types/animation.d.ts +78 -0
- package/lib/typescript/shared/types/animation.d.ts.map +1 -0
- package/lib/typescript/shared/types/bounds.d.ts.map +1 -0
- package/lib/typescript/shared/types/core.d.ts +91 -0
- package/lib/typescript/shared/types/core.d.ts.map +1 -0
- package/lib/typescript/shared/types/gesture.d.ts.map +1 -0
- package/lib/typescript/shared/types/utils.d.ts.map +1 -0
- package/lib/typescript/shared/utils/animation/animate.d.ts.map +1 -0
- package/lib/typescript/shared/utils/animation/derivations.d.ts.map +1 -0
- package/lib/typescript/shared/utils/animation/start-screen-transition.d.ts +13 -0
- package/lib/typescript/shared/utils/animation/start-screen-transition.d.ts.map +1 -0
- package/lib/typescript/shared/utils/bounds/_types/builder.d.ts +118 -0
- package/lib/typescript/shared/utils/bounds/_types/builder.d.ts.map +1 -0
- package/lib/typescript/shared/utils/bounds/_types/geometry.d.ts.map +1 -0
- package/lib/typescript/shared/utils/bounds/_types/get-bounds.d.ts.map +1 -0
- package/lib/typescript/shared/utils/bounds/_utils/flatten-styles.d.ts.map +1 -0
- package/lib/typescript/shared/utils/bounds/_utils/geometry.d.ts +27 -0
- package/lib/typescript/shared/utils/bounds/_utils/geometry.d.ts.map +1 -0
- package/lib/typescript/shared/utils/bounds/_utils/get-bounds.d.ts.map +1 -0
- package/lib/typescript/shared/utils/bounds/_utils/is-bounds-equal.d.ts.map +1 -0
- package/lib/typescript/shared/utils/bounds/_utils/style-composers.d.ts.map +1 -0
- package/lib/typescript/shared/utils/bounds/_utils/styles.d.ts.map +1 -0
- package/lib/typescript/shared/utils/bounds/constants.d.ts +7 -0
- package/lib/typescript/shared/utils/bounds/constants.d.ts.map +1 -0
- package/lib/typescript/shared/utils/bounds/index.d.ts +13 -0
- package/lib/typescript/shared/utils/bounds/index.d.ts.map +1 -0
- package/lib/typescript/shared/utils/gesture/apply-offset-rules.d.ts +38 -0
- package/lib/typescript/shared/utils/gesture/apply-offset-rules.d.ts.map +1 -0
- package/lib/typescript/shared/utils/gesture/check-gesture-activation.d.ts +38 -0
- package/lib/typescript/shared/utils/gesture/check-gesture-activation.d.ts.map +1 -0
- package/lib/typescript/shared/utils/gesture/determine-dismissal.d.ts.map +1 -0
- package/lib/typescript/shared/utils/gesture/map-gesture-to-progress.d.ts.map +1 -0
- package/lib/typescript/shared/utils/gesture/reset-gesture-values.d.ts +16 -0
- package/lib/typescript/shared/utils/gesture/reset-gesture-values.d.ts.map +1 -0
- package/lib/typescript/shared/utils/gesture/velocity.d.ts +25 -0
- package/lib/typescript/shared/utils/gesture/velocity.d.ts.map +1 -0
- package/lib/typescript/shared/utils/reanimated/version.d.ts.map +1 -0
- package/package.json +37 -5
- package/src/blank-stack/components/Overlay.tsx +134 -0
- package/src/blank-stack/components/Screens.tsx +96 -0
- package/src/blank-stack/components/StackView.tsx +102 -0
- package/src/blank-stack/hooks/use-overlay-animation.tsx +101 -0
- package/src/blank-stack/index.ts +10 -0
- package/src/blank-stack/navigators/createBlankStackNavigator.tsx +111 -0
- package/src/blank-stack/types.ts +267 -0
- package/src/blank-stack/utils/with-stack-navigation/_hooks/use-closing-route-keys.tsx +71 -0
- package/src/blank-stack/utils/with-stack-navigation/_hooks/use-stack-navigation-state.tsx +267 -0
- package/src/blank-stack/utils/with-stack-navigation/_types.ts +35 -0
- package/src/blank-stack/utils/with-stack-navigation/_utils/are-descriptors-equal.ts +15 -0
- package/src/blank-stack/utils/with-stack-navigation/_utils/calculate-active-screens-limit.ts +29 -0
- package/src/blank-stack/utils/with-stack-navigation/_utils/compose-descriptors.ts +24 -0
- package/src/blank-stack/utils/with-stack-navigation/index.tsx +80 -0
- package/src/native-stack/index.ts +12 -0
- package/src/native-stack/navigators/createNativeStackNavigator.tsx +112 -0
- package/src/native-stack/types.ts +711 -0
- package/src/native-stack/utils/getModalRoutesKeys.ts +21 -0
- package/src/native-stack/utils/useInvalidPreventRemoveError.tsx +31 -0
- package/src/native-stack/views/NativeStackView.native.tsx +655 -0
- package/src/native-stack/views/NativeStackView.tsx +214 -0
- package/src/native-stack/views/useHeaderConfigProps.tsx +295 -0
- package/src/shared/__tests__/gesture.velocity.test.ts +139 -0
- package/src/shared/components/controllers/screen-lifecycle.tsx +139 -0
- package/src/shared/components/root-transition-aware.tsx +44 -0
- package/src/shared/configs/index.ts +26 -0
- package/src/shared/configs/presets.ts +628 -0
- package/src/shared/constants.ts +108 -0
- package/src/shared/hooks/animation/use-screen-animation.tsx +150 -0
- package/src/shared/hooks/bounds/use-bound-registry.tsx +153 -0
- package/src/shared/hooks/gestures/use-build-gestures.tsx +324 -0
- package/src/shared/hooks/use-shared-value-state.ts +28 -0
- package/src/shared/index.ts +21 -0
- package/src/shared/providers/keys.tsx +57 -0
- package/src/shared/providers/screen-transition-provider.tsx +41 -0
- package/src/shared/providers/transition-styles.tsx +72 -0
- package/src/shared/providers/utils/create-provider.ts +64 -0
- package/src/shared/stores/animation-store.ts +45 -0
- package/src/shared/stores/bound-store/index.ts +125 -0
- package/src/shared/stores/gesture-store.ts +60 -0
- package/src/shared/stores/utils/reset-stores-for-screen.ts +13 -0
- package/src/shared/types/animation.ts +90 -0
- package/src/shared/types/core.ts +97 -0
- package/src/shared/utils/animation/derivations.ts +40 -0
- package/src/shared/utils/animation/start-screen-transition.ts +61 -0
- package/src/shared/utils/bounds/_types/builder.ts +151 -0
- package/src/shared/utils/bounds/_utils/geometry.ts +166 -0
- package/src/shared/utils/bounds/_utils/is-bounds-equal.ts +24 -0
- package/src/shared/utils/bounds/constants.ts +40 -0
- package/src/shared/utils/bounds/index.ts +218 -0
- package/src/shared/utils/gesture/apply-offset-rules.ts +312 -0
- package/src/shared/utils/gesture/check-gesture-activation.ts +310 -0
- package/src/shared/utils/gesture/reset-gesture-values.ts +67 -0
- package/src/shared/utils/gesture/velocity.ts +143 -0
- package/lib/commonjs/__configs__/index.js +0 -22
- package/lib/commonjs/__configs__/index.js.map +0 -1
- package/lib/commonjs/__configs__/presets.js.map +0 -1
- package/lib/commonjs/__configs__/specs.js.map +0 -1
- package/lib/commonjs/components/controllers/screen-lifecycle.blank.js +0 -59
- package/lib/commonjs/components/controllers/screen-lifecycle.blank.js.map +0 -1
- package/lib/commonjs/components/controllers/screen-lifecycle.js +0 -71
- package/lib/commonjs/components/controllers/screen-lifecycle.js.map +0 -1
- package/lib/commonjs/components/create-transition-aware-component.js.map +0 -1
- package/lib/commonjs/components/integrations/masked-view.js.map +0 -1
- package/lib/commonjs/components/root-transition-aware.js.map +0 -1
- package/lib/commonjs/constants.js.map +0 -1
- package/lib/commonjs/hooks/animation/use-associated-style.js.map +0 -1
- package/lib/commonjs/hooks/animation/use-screen-animation.js +0 -120
- package/lib/commonjs/hooks/animation/use-screen-animation.js.map +0 -1
- package/lib/commonjs/hooks/bounds/use-bound-registry.js +0 -131
- package/lib/commonjs/hooks/bounds/use-bound-registry.js.map +0 -1
- package/lib/commonjs/hooks/gestures/use-build-gestures.js +0 -236
- package/lib/commonjs/hooks/gestures/use-build-gestures.js.map +0 -1
- package/lib/commonjs/hooks/gestures/use-parent-gesture-registry.js.map +0 -1
- package/lib/commonjs/hooks/gestures/use-scroll-registry.js.map +0 -1
- package/lib/commonjs/hooks/use-stable-callback-value.js.map +0 -1
- package/lib/commonjs/hooks/use-stable-callback.js.map +0 -1
- package/lib/commonjs/index.js +0 -47
- package/lib/commonjs/index.js.map +0 -1
- package/lib/commonjs/integrations/blank-stack/components/Header.js +0 -135
- package/lib/commonjs/integrations/blank-stack/components/Header.js.map +0 -1
- package/lib/commonjs/integrations/blank-stack/components/Screens.js +0 -64
- package/lib/commonjs/integrations/blank-stack/components/Screens.js.map +0 -1
- package/lib/commonjs/integrations/blank-stack/components/StackView.js +0 -85
- package/lib/commonjs/integrations/blank-stack/components/StackView.js.map +0 -1
- package/lib/commonjs/integrations/blank-stack/navigators/createBlankStackNavigator.js.map +0 -1
- package/lib/commonjs/integrations/blank-stack/providers/screen-transition-provider.js +0 -12
- package/lib/commonjs/integrations/blank-stack/providers/screen-transition-provider.js.map +0 -1
- package/lib/commonjs/integrations/blank-stack/utils/with-stack-navigation/_hooks/use-closing-route-keys.js +0 -66
- package/lib/commonjs/integrations/blank-stack/utils/with-stack-navigation/_hooks/use-closing-route-keys.js.map +0 -1
- package/lib/commonjs/integrations/blank-stack/utils/with-stack-navigation/_hooks/use-previous.js.map +0 -1
- package/lib/commonjs/integrations/blank-stack/utils/with-stack-navigation/_hooks/use-stack-navigation-state.js +0 -208
- package/lib/commonjs/integrations/blank-stack/utils/with-stack-navigation/_hooks/use-stack-navigation-state.js.map +0 -1
- package/lib/commonjs/integrations/blank-stack/utils/with-stack-navigation/_types.js.map +0 -1
- package/lib/commonjs/integrations/blank-stack/utils/with-stack-navigation/_utils/are-descriptors-equal.js.map +0 -1
- package/lib/commonjs/integrations/blank-stack/utils/with-stack-navigation/_utils/calculate-active-screens-limit.js.map +0 -1
- package/lib/commonjs/integrations/blank-stack/utils/with-stack-navigation/_utils/compose-descriptors.js +0 -15
- package/lib/commonjs/integrations/blank-stack/utils/with-stack-navigation/_utils/compose-descriptors.js.map +0 -1
- package/lib/commonjs/integrations/blank-stack/utils/with-stack-navigation/_utils/have-same-route-keys.js.map +0 -1
- package/lib/commonjs/integrations/blank-stack/utils/with-stack-navigation/_utils/routes-are-identical.js.map +0 -1
- package/lib/commonjs/integrations/blank-stack/utils/with-stack-navigation/index.js +0 -66
- package/lib/commonjs/integrations/blank-stack/utils/with-stack-navigation/index.js.map +0 -1
- package/lib/commonjs/integrations/native-stack/navigators/createNativeStackNavigator.js.map +0 -1
- package/lib/commonjs/integrations/native-stack/providers/screen-transition-provider.js +0 -10
- package/lib/commonjs/integrations/native-stack/providers/screen-transition-provider.js.map +0 -1
- package/lib/commonjs/integrations/native-stack/utils/debounce.js.map +0 -1
- package/lib/commonjs/integrations/native-stack/utils/getModalRoutesKeys.js.map +0 -1
- package/lib/commonjs/integrations/native-stack/utils/useAnimatedHeaderHeight.js.map +0 -1
- package/lib/commonjs/integrations/native-stack/utils/useDismissedRouteError.js.map +0 -1
- package/lib/commonjs/integrations/native-stack/utils/useInvalidPreventRemoveError.js.map +0 -1
- package/lib/commonjs/integrations/native-stack/views/FontProcessor.js.map +0 -1
- package/lib/commonjs/integrations/native-stack/views/FontProcessor.native.js.map +0 -1
- package/lib/commonjs/integrations/native-stack/views/FooterComponent.js.map +0 -1
- package/lib/commonjs/integrations/native-stack/views/NativeStackView.js.map +0 -1
- package/lib/commonjs/integrations/native-stack/views/NativeStackView.native.js +0 -488
- package/lib/commonjs/integrations/native-stack/views/NativeStackView.native.js.map +0 -1
- package/lib/commonjs/integrations/native-stack/views/useHeaderConfigProps.js.map +0 -1
- package/lib/commonjs/providers/create-screen-transition-provider.js +0 -38
- package/lib/commonjs/providers/create-screen-transition-provider.js.map +0 -1
- package/lib/commonjs/providers/gestures.js.map +0 -1
- package/lib/commonjs/providers/keys.js +0 -35
- package/lib/commonjs/providers/keys.js.map +0 -1
- package/lib/commonjs/providers/transition-styles.js +0 -63
- package/lib/commonjs/providers/transition-styles.js.map +0 -1
- package/lib/commonjs/stores/animations.js +0 -39
- package/lib/commonjs/stores/animations.js.map +0 -1
- package/lib/commonjs/stores/bounds/_utils.js.map +0 -1
- package/lib/commonjs/stores/bounds/index.js +0 -116
- package/lib/commonjs/stores/bounds/index.js.map +0 -1
- package/lib/commonjs/stores/gestures.js +0 -39
- package/lib/commonjs/stores/gestures.js.map +0 -1
- package/lib/commonjs/stores/navigator-dismiss-state.js.map +0 -1
- package/lib/commonjs/stores/utils/reset-stores-for-screen.js +0 -19
- package/lib/commonjs/stores/utils/reset-stores-for-screen.js.map +0 -1
- package/lib/commonjs/types/animation.js.map +0 -1
- package/lib/commonjs/types/blank-stack.navigator.js +0 -6
- package/lib/commonjs/types/blank-stack.navigator.js.map +0 -1
- package/lib/commonjs/types/bounds.js.map +0 -1
- package/lib/commonjs/types/core.js.map +0 -1
- package/lib/commonjs/types/gesture.js.map +0 -1
- package/lib/commonjs/types/native-stack.navigator.js +0 -6
- package/lib/commonjs/types/native-stack.navigator.js.map +0 -1
- package/lib/commonjs/types/utils.js.map +0 -1
- package/lib/commonjs/utils/animation/animate.js.map +0 -1
- package/lib/commonjs/utils/animation/derivations.js +0 -39
- package/lib/commonjs/utils/animation/derivations.js.map +0 -1
- package/lib/commonjs/utils/animation/start-screen-transition.js.map +0 -1
- package/lib/commonjs/utils/bounds/_types/builder.js.map +0 -1
- package/lib/commonjs/utils/bounds/_types/geometry.js.map +0 -1
- package/lib/commonjs/utils/bounds/_types/get-bounds.js.map +0 -1
- package/lib/commonjs/utils/bounds/_utils/flatten-styles.js.map +0 -1
- package/lib/commonjs/utils/bounds/_utils/geometry.js.map +0 -1
- package/lib/commonjs/utils/bounds/_utils/get-bounds.js.map +0 -1
- package/lib/commonjs/utils/bounds/_utils/is-bounds-equal.js +0 -19
- package/lib/commonjs/utils/bounds/_utils/is-bounds-equal.js.map +0 -1
- package/lib/commonjs/utils/bounds/_utils/style-composers.js.map +0 -1
- package/lib/commonjs/utils/bounds/_utils/styles.js.map +0 -1
- package/lib/commonjs/utils/bounds/constants.js.map +0 -1
- package/lib/commonjs/utils/bounds/index.js.map +0 -1
- package/lib/commonjs/utils/gesture/apply-offset-rules.js.map +0 -1
- package/lib/commonjs/utils/gesture/check-gesture-activation.js.map +0 -1
- package/lib/commonjs/utils/gesture/determine-dismissal.js.map +0 -1
- package/lib/commonjs/utils/gesture/map-gesture-to-progress.js.map +0 -1
- package/lib/commonjs/utils/gesture/reset-gesture-values.js.map +0 -1
- package/lib/commonjs/utils/gesture/velocity.js.map +0 -1
- package/lib/commonjs/utils/reanimated/version.js.map +0 -1
- package/lib/module/__configs__/index.js +0 -18
- package/lib/module/__configs__/index.js.map +0 -1
- package/lib/module/__configs__/presets.js.map +0 -1
- package/lib/module/__configs__/specs.js.map +0 -1
- package/lib/module/components/controllers/screen-lifecycle.blank.js +0 -53
- package/lib/module/components/controllers/screen-lifecycle.blank.js.map +0 -1
- package/lib/module/components/controllers/screen-lifecycle.js +0 -65
- package/lib/module/components/controllers/screen-lifecycle.js.map +0 -1
- package/lib/module/components/create-transition-aware-component.js.map +0 -1
- package/lib/module/components/integrations/masked-view.js.map +0 -1
- package/lib/module/components/root-transition-aware.js.map +0 -1
- package/lib/module/constants.js.map +0 -1
- package/lib/module/hooks/animation/use-associated-style.js.map +0 -1
- package/lib/module/hooks/animation/use-screen-animation.js +0 -115
- package/lib/module/hooks/animation/use-screen-animation.js.map +0 -1
- package/lib/module/hooks/bounds/use-bound-registry.js +0 -125
- package/lib/module/hooks/bounds/use-bound-registry.js.map +0 -1
- package/lib/module/hooks/gestures/use-build-gestures.js +0 -230
- package/lib/module/hooks/gestures/use-build-gestures.js.map +0 -1
- package/lib/module/hooks/gestures/use-parent-gesture-registry.js.map +0 -1
- package/lib/module/hooks/gestures/use-scroll-registry.js.map +0 -1
- package/lib/module/hooks/use-stable-callback-value.js.map +0 -1
- package/lib/module/hooks/use-stable-callback.js.map +0 -1
- package/lib/module/index.js +0 -24
- package/lib/module/index.js.map +0 -1
- package/lib/module/integrations/blank-stack/components/Header.js +0 -131
- package/lib/module/integrations/blank-stack/components/Header.js.map +0 -1
- package/lib/module/integrations/blank-stack/components/Screens.js +0 -58
- package/lib/module/integrations/blank-stack/components/Screens.js.map +0 -1
- package/lib/module/integrations/blank-stack/components/StackView.js +0 -81
- package/lib/module/integrations/blank-stack/components/StackView.js.map +0 -1
- package/lib/module/integrations/blank-stack/navigators/createBlankStackNavigator.js.map +0 -1
- package/lib/module/integrations/blank-stack/providers/screen-transition-provider.js +0 -8
- package/lib/module/integrations/blank-stack/providers/screen-transition-provider.js.map +0 -1
- package/lib/module/integrations/blank-stack/utils/with-stack-navigation/_hooks/use-closing-route-keys.js +0 -60
- package/lib/module/integrations/blank-stack/utils/with-stack-navigation/_hooks/use-closing-route-keys.js.map +0 -1
- package/lib/module/integrations/blank-stack/utils/with-stack-navigation/_hooks/use-previous.js.map +0 -1
- package/lib/module/integrations/blank-stack/utils/with-stack-navigation/_hooks/use-stack-navigation-state.js +0 -202
- package/lib/module/integrations/blank-stack/utils/with-stack-navigation/_hooks/use-stack-navigation-state.js.map +0 -1
- package/lib/module/integrations/blank-stack/utils/with-stack-navigation/_types.js.map +0 -1
- package/lib/module/integrations/blank-stack/utils/with-stack-navigation/_utils/are-descriptors-equal.js.map +0 -1
- package/lib/module/integrations/blank-stack/utils/with-stack-navigation/_utils/calculate-active-screens-limit.js.map +0 -1
- package/lib/module/integrations/blank-stack/utils/with-stack-navigation/_utils/compose-descriptors.js +0 -10
- package/lib/module/integrations/blank-stack/utils/with-stack-navigation/_utils/compose-descriptors.js.map +0 -1
- package/lib/module/integrations/blank-stack/utils/with-stack-navigation/_utils/have-same-route-keys.js.map +0 -1
- package/lib/module/integrations/blank-stack/utils/with-stack-navigation/_utils/routes-are-identical.js.map +0 -1
- package/lib/module/integrations/blank-stack/utils/with-stack-navigation/index.js +0 -60
- package/lib/module/integrations/blank-stack/utils/with-stack-navigation/index.js.map +0 -1
- package/lib/module/integrations/native-stack/navigators/createNativeStackNavigator.js.map +0 -1
- package/lib/module/integrations/native-stack/providers/screen-transition-provider.js +0 -6
- package/lib/module/integrations/native-stack/providers/screen-transition-provider.js.map +0 -1
- package/lib/module/integrations/native-stack/utils/debounce.js.map +0 -1
- package/lib/module/integrations/native-stack/utils/getModalRoutesKeys.js.map +0 -1
- package/lib/module/integrations/native-stack/utils/useAnimatedHeaderHeight.js.map +0 -1
- package/lib/module/integrations/native-stack/utils/useDismissedRouteError.js.map +0 -1
- package/lib/module/integrations/native-stack/utils/useInvalidPreventRemoveError.js.map +0 -1
- package/lib/module/integrations/native-stack/views/FontProcessor.js.map +0 -1
- package/lib/module/integrations/native-stack/views/FontProcessor.native.js.map +0 -1
- package/lib/module/integrations/native-stack/views/FooterComponent.js.map +0 -1
- package/lib/module/integrations/native-stack/views/NativeStackView.js.map +0 -1
- package/lib/module/integrations/native-stack/views/NativeStackView.native.js +0 -483
- package/lib/module/integrations/native-stack/views/NativeStackView.native.js.map +0 -1
- package/lib/module/integrations/native-stack/views/useHeaderConfigProps.js.map +0 -1
- package/lib/module/providers/create-screen-transition-provider.js +0 -34
- package/lib/module/providers/create-screen-transition-provider.js.map +0 -1
- package/lib/module/providers/gestures.js.map +0 -1
- package/lib/module/providers/keys.js +0 -29
- package/lib/module/providers/keys.js.map +0 -1
- package/lib/module/providers/transition-styles.js +0 -58
- package/lib/module/providers/transition-styles.js.map +0 -1
- package/lib/module/stores/animations.js +0 -33
- package/lib/module/stores/animations.js.map +0 -1
- package/lib/module/stores/bounds/_utils.js.map +0 -1
- package/lib/module/stores/bounds/index.js +0 -112
- package/lib/module/stores/bounds/index.js.map +0 -1
- package/lib/module/stores/gestures.js +0 -35
- package/lib/module/stores/gestures.js.map +0 -1
- package/lib/module/stores/navigator-dismiss-state.js.map +0 -1
- package/lib/module/stores/utils/reset-stores-for-screen.js +0 -15
- package/lib/module/stores/utils/reset-stores-for-screen.js.map +0 -1
- package/lib/module/types/animation.js.map +0 -1
- package/lib/module/types/blank-stack.navigator.js +0 -4
- package/lib/module/types/blank-stack.navigator.js.map +0 -1
- package/lib/module/types/bounds.js.map +0 -1
- package/lib/module/types/core.js.map +0 -1
- package/lib/module/types/gesture.js.map +0 -1
- package/lib/module/types/native-stack.navigator.js +0 -4
- package/lib/module/types/native-stack.navigator.js.map +0 -1
- package/lib/module/types/utils.js.map +0 -1
- package/lib/module/utils/animation/animate.js.map +0 -1
- package/lib/module/utils/animation/derivations.js +0 -34
- package/lib/module/utils/animation/derivations.js.map +0 -1
- package/lib/module/utils/animation/start-screen-transition.js.map +0 -1
- package/lib/module/utils/bounds/_types/builder.js.map +0 -1
- package/lib/module/utils/bounds/_types/geometry.js.map +0 -1
- package/lib/module/utils/bounds/_types/get-bounds.js.map +0 -1
- package/lib/module/utils/bounds/_utils/flatten-styles.js.map +0 -1
- package/lib/module/utils/bounds/_utils/geometry.js.map +0 -1
- package/lib/module/utils/bounds/_utils/get-bounds.js.map +0 -1
- package/lib/module/utils/bounds/_utils/is-bounds-equal.js +0 -14
- package/lib/module/utils/bounds/_utils/is-bounds-equal.js.map +0 -1
- package/lib/module/utils/bounds/_utils/style-composers.js.map +0 -1
- package/lib/module/utils/bounds/_utils/styles.js.map +0 -1
- package/lib/module/utils/bounds/constants.js.map +0 -1
- package/lib/module/utils/bounds/index.js.map +0 -1
- package/lib/module/utils/gesture/apply-offset-rules.js.map +0 -1
- package/lib/module/utils/gesture/check-gesture-activation.js.map +0 -1
- package/lib/module/utils/gesture/determine-dismissal.js.map +0 -1
- package/lib/module/utils/gesture/map-gesture-to-progress.js.map +0 -1
- package/lib/module/utils/gesture/reset-gesture-values.js.map +0 -1
- package/lib/module/utils/gesture/velocity.js.map +0 -1
- package/lib/module/utils/reanimated/version.js.map +0 -1
- package/lib/typescript/__configs__/index.d.ts +0 -16
- package/lib/typescript/__configs__/index.d.ts.map +0 -1
- package/lib/typescript/__configs__/presets.d.ts +0 -12
- package/lib/typescript/__configs__/presets.d.ts.map +0 -1
- package/lib/typescript/__configs__/specs.d.ts.map +0 -1
- package/lib/typescript/components/controllers/screen-lifecycle.blank.d.ts +0 -7
- package/lib/typescript/components/controllers/screen-lifecycle.blank.d.ts.map +0 -1
- package/lib/typescript/components/controllers/screen-lifecycle.d.ts +0 -6
- package/lib/typescript/components/controllers/screen-lifecycle.d.ts.map +0 -1
- package/lib/typescript/components/create-transition-aware-component.d.ts.map +0 -1
- package/lib/typescript/components/integrations/masked-view.d.ts.map +0 -1
- package/lib/typescript/components/root-transition-aware.d.ts.map +0 -1
- package/lib/typescript/constants.d.ts +0 -57
- package/lib/typescript/constants.d.ts.map +0 -1
- package/lib/typescript/hooks/animation/use-associated-style.d.ts.map +0 -1
- package/lib/typescript/hooks/animation/use-screen-animation.d.ts +0 -7
- package/lib/typescript/hooks/animation/use-screen-animation.d.ts.map +0 -1
- package/lib/typescript/hooks/bounds/use-bound-registry.d.ts.map +0 -1
- package/lib/typescript/hooks/gestures/use-build-gestures.d.ts.map +0 -1
- package/lib/typescript/hooks/gestures/use-parent-gesture-registry.d.ts.map +0 -1
- package/lib/typescript/hooks/gestures/use-scroll-registry.d.ts.map +0 -1
- package/lib/typescript/hooks/use-stable-callback-value.d.ts.map +0 -1
- package/lib/typescript/hooks/use-stable-callback.d.ts.map +0 -1
- package/lib/typescript/index.d.ts +0 -1327
- package/lib/typescript/index.d.ts.map +0 -1
- package/lib/typescript/integrations/blank-stack/components/Header.d.ts +0 -5
- package/lib/typescript/integrations/blank-stack/components/Header.d.ts.map +0 -1
- package/lib/typescript/integrations/blank-stack/components/Screens.d.ts.map +0 -1
- package/lib/typescript/integrations/blank-stack/components/StackView.d.ts.map +0 -1
- package/lib/typescript/integrations/blank-stack/navigators/createBlankStackNavigator.d.ts +0 -16
- package/lib/typescript/integrations/blank-stack/navigators/createBlankStackNavigator.d.ts.map +0 -1
- package/lib/typescript/integrations/blank-stack/providers/screen-transition-provider.d.ts +0 -8
- package/lib/typescript/integrations/blank-stack/providers/screen-transition-provider.d.ts.map +0 -1
- package/lib/typescript/integrations/blank-stack/utils/with-stack-navigation/_hooks/use-closing-route-keys.d.ts.map +0 -1
- package/lib/typescript/integrations/blank-stack/utils/with-stack-navigation/_hooks/use-previous.d.ts.map +0 -1
- package/lib/typescript/integrations/blank-stack/utils/with-stack-navigation/_hooks/use-stack-navigation-state.d.ts +0 -20
- package/lib/typescript/integrations/blank-stack/utils/with-stack-navigation/_hooks/use-stack-navigation-state.d.ts.map +0 -1
- package/lib/typescript/integrations/blank-stack/utils/with-stack-navigation/_types.d.ts +0 -22
- package/lib/typescript/integrations/blank-stack/utils/with-stack-navigation/_types.d.ts.map +0 -1
- package/lib/typescript/integrations/blank-stack/utils/with-stack-navigation/_utils/are-descriptors-equal.d.ts +0 -3
- package/lib/typescript/integrations/blank-stack/utils/with-stack-navigation/_utils/are-descriptors-equal.d.ts.map +0 -1
- package/lib/typescript/integrations/blank-stack/utils/with-stack-navigation/_utils/calculate-active-screens-limit.d.ts +0 -4
- package/lib/typescript/integrations/blank-stack/utils/with-stack-navigation/_utils/calculate-active-screens-limit.d.ts.map +0 -1
- package/lib/typescript/integrations/blank-stack/utils/with-stack-navigation/_utils/compose-descriptors.d.ts +0 -4
- package/lib/typescript/integrations/blank-stack/utils/with-stack-navigation/_utils/compose-descriptors.d.ts.map +0 -1
- package/lib/typescript/integrations/blank-stack/utils/with-stack-navigation/_utils/have-same-route-keys.d.ts.map +0 -1
- package/lib/typescript/integrations/blank-stack/utils/with-stack-navigation/_utils/routes-are-identical.d.ts.map +0 -1
- package/lib/typescript/integrations/blank-stack/utils/with-stack-navigation/index.d.ts.map +0 -1
- package/lib/typescript/integrations/native-stack/navigators/createNativeStackNavigator.d.ts +0 -16
- package/lib/typescript/integrations/native-stack/navigators/createNativeStackNavigator.d.ts.map +0 -1
- package/lib/typescript/integrations/native-stack/providers/screen-transition-provider.d.ts +0 -8
- package/lib/typescript/integrations/native-stack/providers/screen-transition-provider.d.ts.map +0 -1
- package/lib/typescript/integrations/native-stack/utils/debounce.d.ts.map +0 -1
- package/lib/typescript/integrations/native-stack/utils/getModalRoutesKeys.d.ts +0 -4
- package/lib/typescript/integrations/native-stack/utils/getModalRoutesKeys.d.ts.map +0 -1
- package/lib/typescript/integrations/native-stack/utils/useAnimatedHeaderHeight.d.ts.map +0 -1
- package/lib/typescript/integrations/native-stack/utils/useDismissedRouteError.d.ts.map +0 -1
- package/lib/typescript/integrations/native-stack/utils/useInvalidPreventRemoveError.d.ts +0 -3
- package/lib/typescript/integrations/native-stack/utils/useInvalidPreventRemoveError.d.ts.map +0 -1
- package/lib/typescript/integrations/native-stack/views/FontProcessor.d.ts.map +0 -1
- package/lib/typescript/integrations/native-stack/views/FontProcessor.native.d.ts.map +0 -1
- package/lib/typescript/integrations/native-stack/views/FooterComponent.d.ts.map +0 -1
- package/lib/typescript/integrations/native-stack/views/NativeStackView.d.ts +0 -11
- package/lib/typescript/integrations/native-stack/views/NativeStackView.d.ts.map +0 -1
- package/lib/typescript/integrations/native-stack/views/NativeStackView.native.d.ts +0 -11
- package/lib/typescript/integrations/native-stack/views/NativeStackView.native.d.ts.map +0 -1
- package/lib/typescript/integrations/native-stack/views/useHeaderConfigProps.d.ts +0 -44
- package/lib/typescript/integrations/native-stack/views/useHeaderConfigProps.d.ts.map +0 -1
- package/lib/typescript/providers/create-screen-transition-provider.d.ts +0 -18
- package/lib/typescript/providers/create-screen-transition-provider.d.ts.map +0 -1
- package/lib/typescript/providers/gestures.d.ts.map +0 -1
- package/lib/typescript/providers/keys.d.ts +0 -18
- package/lib/typescript/providers/keys.d.ts.map +0 -1
- package/lib/typescript/providers/transition-styles.d.ts +0 -12
- package/lib/typescript/providers/transition-styles.d.ts.map +0 -1
- package/lib/typescript/stores/animations.d.ts +0 -17
- package/lib/typescript/stores/animations.d.ts.map +0 -1
- package/lib/typescript/stores/bounds/_utils.d.ts.map +0 -1
- package/lib/typescript/stores/bounds/index.d.ts +0 -22
- package/lib/typescript/stores/bounds/index.d.ts.map +0 -1
- package/lib/typescript/stores/gestures.d.ts +0 -23
- package/lib/typescript/stores/gestures.d.ts.map +0 -1
- package/lib/typescript/stores/navigator-dismiss-state.d.ts.map +0 -1
- package/lib/typescript/stores/utils/reset-stores-for-screen.d.ts +0 -6
- package/lib/typescript/stores/utils/reset-stores-for-screen.d.ts.map +0 -1
- package/lib/typescript/types/animation.d.ts +0 -70
- package/lib/typescript/types/animation.d.ts.map +0 -1
- package/lib/typescript/types/blank-stack.navigator.d.ts +0 -214
- package/lib/typescript/types/blank-stack.navigator.d.ts.map +0 -1
- package/lib/typescript/types/bounds.d.ts.map +0 -1
- package/lib/typescript/types/core.d.ts +0 -47
- package/lib/typescript/types/core.d.ts.map +0 -1
- package/lib/typescript/types/gesture.d.ts.map +0 -1
- package/lib/typescript/types/native-stack.navigator.d.ts +0 -691
- package/lib/typescript/types/native-stack.navigator.d.ts.map +0 -1
- package/lib/typescript/types/utils.d.ts.map +0 -1
- package/lib/typescript/utils/animation/animate.d.ts.map +0 -1
- package/lib/typescript/utils/animation/derivations.d.ts.map +0 -1
- package/lib/typescript/utils/animation/start-screen-transition.d.ts +0 -13
- package/lib/typescript/utils/animation/start-screen-transition.d.ts.map +0 -1
- package/lib/typescript/utils/bounds/_types/builder.d.ts +0 -118
- package/lib/typescript/utils/bounds/_types/builder.d.ts.map +0 -1
- package/lib/typescript/utils/bounds/_types/geometry.d.ts.map +0 -1
- package/lib/typescript/utils/bounds/_types/get-bounds.d.ts.map +0 -1
- package/lib/typescript/utils/bounds/_utils/flatten-styles.d.ts.map +0 -1
- package/lib/typescript/utils/bounds/_utils/geometry.d.ts +0 -27
- package/lib/typescript/utils/bounds/_utils/geometry.d.ts.map +0 -1
- package/lib/typescript/utils/bounds/_utils/get-bounds.d.ts.map +0 -1
- package/lib/typescript/utils/bounds/_utils/is-bounds-equal.d.ts.map +0 -1
- package/lib/typescript/utils/bounds/_utils/style-composers.d.ts.map +0 -1
- package/lib/typescript/utils/bounds/_utils/styles.d.ts.map +0 -1
- package/lib/typescript/utils/bounds/constants.d.ts +0 -7
- package/lib/typescript/utils/bounds/constants.d.ts.map +0 -1
- package/lib/typescript/utils/bounds/index.d.ts +0 -13
- package/lib/typescript/utils/bounds/index.d.ts.map +0 -1
- package/lib/typescript/utils/gesture/apply-offset-rules.d.ts +0 -38
- package/lib/typescript/utils/gesture/apply-offset-rules.d.ts.map +0 -1
- package/lib/typescript/utils/gesture/check-gesture-activation.d.ts +0 -38
- package/lib/typescript/utils/gesture/check-gesture-activation.d.ts.map +0 -1
- package/lib/typescript/utils/gesture/determine-dismissal.d.ts.map +0 -1
- package/lib/typescript/utils/gesture/map-gesture-to-progress.d.ts.map +0 -1
- package/lib/typescript/utils/gesture/reset-gesture-values.d.ts +0 -16
- package/lib/typescript/utils/gesture/reset-gesture-values.d.ts.map +0 -1
- package/lib/typescript/utils/gesture/velocity.d.ts +0 -25
- package/lib/typescript/utils/gesture/velocity.d.ts.map +0 -1
- package/lib/typescript/utils/reanimated/version.d.ts.map +0 -1
- package/src/__configs__/index.ts +0 -26
- package/src/__configs__/presets.ts +0 -628
- package/src/__tests__/gesture.velocity.test.ts +0 -138
- package/src/components/controllers/screen-lifecycle.blank.ts +0 -62
- package/src/components/controllers/screen-lifecycle.tsx +0 -78
- package/src/components/root-transition-aware.tsx +0 -44
- package/src/constants.ts +0 -108
- package/src/hooks/animation/use-screen-animation.tsx +0 -157
- package/src/hooks/bounds/use-bound-registry.tsx +0 -159
- package/src/hooks/gestures/use-build-gestures.tsx +0 -324
- package/src/index.ts +0 -45
- package/src/integrations/blank-stack/components/Header.tsx +0 -141
- package/src/integrations/blank-stack/components/Screens.tsx +0 -96
- package/src/integrations/blank-stack/components/StackView.tsx +0 -100
- package/src/integrations/blank-stack/navigators/createBlankStackNavigator.tsx +0 -111
- package/src/integrations/blank-stack/providers/screen-transition-provider.tsx +0 -9
- package/src/integrations/blank-stack/utils/with-stack-navigation/_hooks/use-closing-route-keys.tsx +0 -62
- package/src/integrations/blank-stack/utils/with-stack-navigation/_hooks/use-stack-navigation-state.tsx +0 -280
- package/src/integrations/blank-stack/utils/with-stack-navigation/_types.ts +0 -35
- package/src/integrations/blank-stack/utils/with-stack-navigation/_utils/are-descriptors-equal.ts +0 -15
- package/src/integrations/blank-stack/utils/with-stack-navigation/_utils/calculate-active-screens-limit.ts +0 -29
- package/src/integrations/blank-stack/utils/with-stack-navigation/_utils/compose-descriptors.ts +0 -17
- package/src/integrations/blank-stack/utils/with-stack-navigation/index.tsx +0 -80
- package/src/integrations/native-stack/navigators/createNativeStackNavigator.tsx +0 -112
- package/src/integrations/native-stack/providers/screen-transition-provider.tsx +0 -8
- package/src/integrations/native-stack/utils/getModalRoutesKeys.ts +0 -21
- package/src/integrations/native-stack/utils/useInvalidPreventRemoveError.tsx +0 -31
- package/src/integrations/native-stack/views/NativeStackView.native.tsx +0 -650
- package/src/integrations/native-stack/views/NativeStackView.tsx +0 -214
- package/src/integrations/native-stack/views/useHeaderConfigProps.tsx +0 -295
- package/src/providers/create-screen-transition-provider.tsx +0 -55
- package/src/providers/keys.tsx +0 -50
- package/src/providers/transition-styles.tsx +0 -76
- package/src/stores/animations.ts +0 -45
- package/src/stores/bounds/index.ts +0 -125
- package/src/stores/gestures.ts +0 -60
- package/src/stores/utils/reset-stores-for-screen.ts +0 -13
- package/src/types/animation.ts +0 -81
- package/src/types/blank-stack.navigator.ts +0 -266
- package/src/types/core.ts +0 -50
- package/src/types/native-stack.navigator.ts +0 -753
- package/src/utils/animation/derivations.ts +0 -40
- package/src/utils/animation/start-screen-transition.ts +0 -61
- package/src/utils/bounds/_types/builder.ts +0 -151
- package/src/utils/bounds/_utils/geometry.ts +0 -166
- package/src/utils/bounds/_utils/is-bounds-equal.ts +0 -24
- package/src/utils/bounds/constants.ts +0 -40
- package/src/utils/bounds/index.ts +0 -219
- package/src/utils/gesture/apply-offset-rules.ts +0 -312
- package/src/utils/gesture/check-gesture-activation.ts +0 -310
- package/src/utils/gesture/reset-gesture-values.ts +0 -67
- package/src/utils/gesture/velocity.ts +0 -143
- /package/lib/commonjs/{integrations/blank-stack → blank-stack}/navigators/createBlankStackNavigator.js +0 -0
- /package/lib/commonjs/{integrations/blank-stack → blank-stack}/utils/with-stack-navigation/_hooks/use-previous.js +0 -0
- /package/lib/commonjs/{integrations/blank-stack → blank-stack}/utils/with-stack-navigation/_types.js +0 -0
- /package/lib/commonjs/{integrations/blank-stack → blank-stack}/utils/with-stack-navigation/_utils/are-descriptors-equal.js +0 -0
- /package/lib/commonjs/{integrations/blank-stack → blank-stack}/utils/with-stack-navigation/_utils/calculate-active-screens-limit.js +0 -0
- /package/lib/commonjs/{integrations/blank-stack → blank-stack}/utils/with-stack-navigation/_utils/have-same-route-keys.js +0 -0
- /package/lib/commonjs/{integrations/blank-stack → blank-stack}/utils/with-stack-navigation/_utils/routes-are-identical.js +0 -0
- /package/lib/commonjs/{integrations/native-stack → native-stack}/navigators/createNativeStackNavigator.js +0 -0
- /package/lib/commonjs/{integrations/native-stack → native-stack}/utils/debounce.js +0 -0
- /package/lib/commonjs/{integrations/native-stack → native-stack}/utils/getModalRoutesKeys.js +0 -0
- /package/lib/commonjs/{integrations/native-stack → native-stack}/utils/useAnimatedHeaderHeight.js +0 -0
- /package/lib/commonjs/{integrations/native-stack → native-stack}/utils/useDismissedRouteError.js +0 -0
- /package/lib/commonjs/{integrations/native-stack → native-stack}/utils/useInvalidPreventRemoveError.js +0 -0
- /package/lib/commonjs/{integrations/native-stack → native-stack}/views/FontProcessor.js +0 -0
- /package/lib/commonjs/{integrations/native-stack → native-stack}/views/FontProcessor.native.js +0 -0
- /package/lib/commonjs/{integrations/native-stack → native-stack}/views/FooterComponent.js +0 -0
- /package/lib/commonjs/{integrations/native-stack → native-stack}/views/NativeStackView.js +0 -0
- /package/lib/commonjs/{integrations/native-stack → native-stack}/views/useHeaderConfigProps.js +0 -0
- /package/lib/commonjs/{components → shared/components}/create-transition-aware-component.js +0 -0
- /package/lib/commonjs/{components → shared/components}/integrations/masked-view.js +0 -0
- /package/lib/commonjs/{components → shared/components}/root-transition-aware.js +0 -0
- /package/lib/commonjs/{__configs__ → shared/configs}/presets.js +0 -0
- /package/lib/commonjs/{__configs__ → shared/configs}/specs.js +0 -0
- /package/lib/commonjs/{constants.js → shared/constants.js} +0 -0
- /package/lib/commonjs/{hooks → shared/hooks}/animation/use-associated-style.js +0 -0
- /package/lib/commonjs/{hooks → shared/hooks}/gestures/use-parent-gesture-registry.js +0 -0
- /package/lib/commonjs/{hooks → shared/hooks}/gestures/use-scroll-registry.js +0 -0
- /package/lib/commonjs/{hooks → shared/hooks}/use-stable-callback-value.js +0 -0
- /package/lib/commonjs/{hooks → shared/hooks}/use-stable-callback.js +0 -0
- /package/lib/commonjs/{providers → shared/providers}/gestures.js +0 -0
- /package/lib/commonjs/{stores/bounds → shared/stores/bound-store}/_utils.js +0 -0
- /package/lib/commonjs/{stores → shared/stores}/navigator-dismiss-state.js +0 -0
- /package/lib/commonjs/{types → shared/types}/animation.js +0 -0
- /package/lib/commonjs/{types → shared/types}/bounds.js +0 -0
- /package/lib/commonjs/{types → shared/types}/core.js +0 -0
- /package/lib/commonjs/{types → shared/types}/gesture.js +0 -0
- /package/lib/commonjs/{types → shared/types}/utils.js +0 -0
- /package/lib/commonjs/{utils → shared/utils}/animation/animate.js +0 -0
- /package/lib/commonjs/{utils → shared/utils}/animation/start-screen-transition.js +0 -0
- /package/lib/commonjs/{utils → shared/utils}/bounds/_types/builder.js +0 -0
- /package/lib/commonjs/{utils → shared/utils}/bounds/_types/geometry.js +0 -0
- /package/lib/commonjs/{utils → shared/utils}/bounds/_types/get-bounds.js +0 -0
- /package/lib/commonjs/{utils → shared/utils}/bounds/_utils/flatten-styles.js +0 -0
- /package/lib/commonjs/{utils → shared/utils}/bounds/_utils/geometry.js +0 -0
- /package/lib/commonjs/{utils → shared/utils}/bounds/_utils/get-bounds.js +0 -0
- /package/lib/commonjs/{utils → shared/utils}/bounds/_utils/style-composers.js +0 -0
- /package/lib/commonjs/{utils → shared/utils}/bounds/_utils/styles.js +0 -0
- /package/lib/commonjs/{utils → shared/utils}/bounds/constants.js +0 -0
- /package/lib/commonjs/{utils → shared/utils}/bounds/index.js +0 -0
- /package/lib/commonjs/{utils → shared/utils}/gesture/apply-offset-rules.js +0 -0
- /package/lib/commonjs/{utils → shared/utils}/gesture/check-gesture-activation.js +0 -0
- /package/lib/commonjs/{utils → shared/utils}/gesture/determine-dismissal.js +0 -0
- /package/lib/commonjs/{utils → shared/utils}/gesture/map-gesture-to-progress.js +0 -0
- /package/lib/commonjs/{utils → shared/utils}/gesture/reset-gesture-values.js +0 -0
- /package/lib/commonjs/{utils → shared/utils}/gesture/velocity.js +0 -0
- /package/lib/commonjs/{utils → shared/utils}/reanimated/version.js +0 -0
- /package/lib/module/{integrations/blank-stack → blank-stack}/navigators/createBlankStackNavigator.js +0 -0
- /package/lib/module/{integrations/blank-stack → blank-stack}/utils/with-stack-navigation/_hooks/use-previous.js +0 -0
- /package/lib/module/{integrations/blank-stack → blank-stack}/utils/with-stack-navigation/_types.js +0 -0
- /package/lib/module/{integrations/blank-stack → blank-stack}/utils/with-stack-navigation/_utils/are-descriptors-equal.js +0 -0
- /package/lib/module/{integrations/blank-stack → blank-stack}/utils/with-stack-navigation/_utils/calculate-active-screens-limit.js +0 -0
- /package/lib/module/{integrations/blank-stack → blank-stack}/utils/with-stack-navigation/_utils/have-same-route-keys.js +0 -0
- /package/lib/module/{integrations/blank-stack → blank-stack}/utils/with-stack-navigation/_utils/routes-are-identical.js +0 -0
- /package/lib/module/{integrations/native-stack → native-stack}/navigators/createNativeStackNavigator.js +0 -0
- /package/lib/module/{integrations/native-stack → native-stack}/utils/debounce.js +0 -0
- /package/lib/module/{integrations/native-stack → native-stack}/utils/getModalRoutesKeys.js +0 -0
- /package/lib/module/{integrations/native-stack → native-stack}/utils/useAnimatedHeaderHeight.js +0 -0
- /package/lib/module/{integrations/native-stack → native-stack}/utils/useDismissedRouteError.js +0 -0
- /package/lib/module/{integrations/native-stack → native-stack}/utils/useInvalidPreventRemoveError.js +0 -0
- /package/lib/module/{integrations/native-stack → native-stack}/views/FontProcessor.js +0 -0
- /package/lib/module/{integrations/native-stack → native-stack}/views/FontProcessor.native.js +0 -0
- /package/lib/module/{integrations/native-stack → native-stack}/views/FooterComponent.js +0 -0
- /package/lib/module/{integrations/native-stack → native-stack}/views/NativeStackView.js +0 -0
- /package/lib/module/{integrations/native-stack → native-stack}/views/useHeaderConfigProps.js +0 -0
- /package/lib/module/{components → shared/components}/create-transition-aware-component.js +0 -0
- /package/lib/module/{components → shared/components}/integrations/masked-view.js +0 -0
- /package/lib/module/{components → shared/components}/root-transition-aware.js +0 -0
- /package/lib/module/{__configs__ → shared/configs}/presets.js +0 -0
- /package/lib/module/{__configs__ → shared/configs}/specs.js +0 -0
- /package/lib/module/{constants.js → shared/constants.js} +0 -0
- /package/lib/module/{hooks → shared/hooks}/animation/use-associated-style.js +0 -0
- /package/lib/module/{hooks → shared/hooks}/gestures/use-parent-gesture-registry.js +0 -0
- /package/lib/module/{hooks → shared/hooks}/gestures/use-scroll-registry.js +0 -0
- /package/lib/module/{hooks → shared/hooks}/use-stable-callback-value.js +0 -0
- /package/lib/module/{hooks → shared/hooks}/use-stable-callback.js +0 -0
- /package/lib/module/{providers → shared/providers}/gestures.js +0 -0
- /package/lib/module/{stores/bounds → shared/stores/bound-store}/_utils.js +0 -0
- /package/lib/module/{stores → shared/stores}/navigator-dismiss-state.js +0 -0
- /package/lib/module/{types → shared/types}/animation.js +0 -0
- /package/lib/module/{types → shared/types}/bounds.js +0 -0
- /package/lib/module/{types → shared/types}/core.js +0 -0
- /package/lib/module/{types → shared/types}/gesture.js +0 -0
- /package/lib/module/{types → shared/types}/utils.js +0 -0
- /package/lib/module/{utils → shared/utils}/animation/animate.js +0 -0
- /package/lib/module/{utils → shared/utils}/animation/start-screen-transition.js +0 -0
- /package/lib/module/{utils → shared/utils}/bounds/_types/builder.js +0 -0
- /package/lib/module/{utils → shared/utils}/bounds/_types/geometry.js +0 -0
- /package/lib/module/{utils → shared/utils}/bounds/_types/get-bounds.js +0 -0
- /package/lib/module/{utils → shared/utils}/bounds/_utils/flatten-styles.js +0 -0
- /package/lib/module/{utils → shared/utils}/bounds/_utils/geometry.js +0 -0
- /package/lib/module/{utils → shared/utils}/bounds/_utils/get-bounds.js +0 -0
- /package/lib/module/{utils → shared/utils}/bounds/_utils/style-composers.js +0 -0
- /package/lib/module/{utils → shared/utils}/bounds/_utils/styles.js +0 -0
- /package/lib/module/{utils → shared/utils}/bounds/constants.js +0 -0
- /package/lib/module/{utils → shared/utils}/bounds/index.js +0 -0
- /package/lib/module/{utils → shared/utils}/gesture/apply-offset-rules.js +0 -0
- /package/lib/module/{utils → shared/utils}/gesture/check-gesture-activation.js +0 -0
- /package/lib/module/{utils → shared/utils}/gesture/determine-dismissal.js +0 -0
- /package/lib/module/{utils → shared/utils}/gesture/map-gesture-to-progress.js +0 -0
- /package/lib/module/{utils → shared/utils}/gesture/reset-gesture-values.js +0 -0
- /package/lib/module/{utils → shared/utils}/gesture/velocity.js +0 -0
- /package/lib/module/{utils → shared/utils}/reanimated/version.js +0 -0
- /package/lib/typescript/{integrations/blank-stack → blank-stack}/components/Screens.d.ts +0 -0
- /package/lib/typescript/{integrations/blank-stack → blank-stack}/components/StackView.d.ts +0 -0
- /package/lib/typescript/{integrations/blank-stack → blank-stack}/utils/with-stack-navigation/_hooks/use-closing-route-keys.d.ts +0 -0
- /package/lib/typescript/{integrations/blank-stack → blank-stack}/utils/with-stack-navigation/_hooks/use-previous.d.ts +0 -0
- /package/lib/typescript/{integrations/blank-stack → blank-stack}/utils/with-stack-navigation/_utils/have-same-route-keys.d.ts +0 -0
- /package/lib/typescript/{integrations/blank-stack → blank-stack}/utils/with-stack-navigation/_utils/routes-are-identical.d.ts +0 -0
- /package/lib/typescript/{integrations/blank-stack → blank-stack}/utils/with-stack-navigation/index.d.ts +0 -0
- /package/lib/typescript/{integrations/native-stack → native-stack}/utils/debounce.d.ts +0 -0
- /package/lib/typescript/{integrations/native-stack → native-stack}/utils/useAnimatedHeaderHeight.d.ts +0 -0
- /package/lib/typescript/{integrations/native-stack → native-stack}/utils/useDismissedRouteError.d.ts +0 -0
- /package/lib/typescript/{integrations/native-stack → native-stack}/views/FontProcessor.d.ts +0 -0
- /package/lib/typescript/{integrations/native-stack → native-stack}/views/FontProcessor.native.d.ts +0 -0
- /package/lib/typescript/{integrations/native-stack → native-stack}/views/FooterComponent.d.ts +0 -0
- /package/lib/typescript/{components → shared/components}/create-transition-aware-component.d.ts +0 -0
- /package/lib/typescript/{components → shared/components}/integrations/masked-view.d.ts +0 -0
- /package/lib/typescript/{components → shared/components}/root-transition-aware.d.ts +0 -0
- /package/lib/typescript/{__configs__ → shared/configs}/specs.d.ts +0 -0
- /package/lib/typescript/{hooks → shared/hooks}/animation/use-associated-style.d.ts +0 -0
- /package/lib/typescript/{hooks → shared/hooks}/bounds/use-bound-registry.d.ts +0 -0
- /package/lib/typescript/{hooks → shared/hooks}/gestures/use-build-gestures.d.ts +0 -0
- /package/lib/typescript/{hooks → shared/hooks}/gestures/use-parent-gesture-registry.d.ts +0 -0
- /package/lib/typescript/{hooks → shared/hooks}/gestures/use-scroll-registry.d.ts +0 -0
- /package/lib/typescript/{hooks → shared/hooks}/use-stable-callback-value.d.ts +0 -0
- /package/lib/typescript/{hooks → shared/hooks}/use-stable-callback.d.ts +0 -0
- /package/lib/typescript/{providers → shared/providers}/gestures.d.ts +0 -0
- /package/lib/typescript/{stores/bounds → shared/stores/bound-store}/_utils.d.ts +0 -0
- /package/lib/typescript/{stores → shared/stores}/navigator-dismiss-state.d.ts +0 -0
- /package/lib/typescript/{types → shared/types}/bounds.d.ts +0 -0
- /package/lib/typescript/{types → shared/types}/gesture.d.ts +0 -0
- /package/lib/typescript/{types → shared/types}/utils.d.ts +0 -0
- /package/lib/typescript/{utils → shared/utils}/animation/animate.d.ts +0 -0
- /package/lib/typescript/{utils → shared/utils}/animation/derivations.d.ts +0 -0
- /package/lib/typescript/{utils → shared/utils}/bounds/_types/geometry.d.ts +0 -0
- /package/lib/typescript/{utils → shared/utils}/bounds/_types/get-bounds.d.ts +0 -0
- /package/lib/typescript/{utils → shared/utils}/bounds/_utils/flatten-styles.d.ts +0 -0
- /package/lib/typescript/{utils → shared/utils}/bounds/_utils/get-bounds.d.ts +0 -0
- /package/lib/typescript/{utils → shared/utils}/bounds/_utils/is-bounds-equal.d.ts +0 -0
- /package/lib/typescript/{utils → shared/utils}/bounds/_utils/style-composers.d.ts +0 -0
- /package/lib/typescript/{utils → shared/utils}/bounds/_utils/styles.d.ts +0 -0
- /package/lib/typescript/{utils → shared/utils}/gesture/determine-dismissal.d.ts +0 -0
- /package/lib/typescript/{utils → shared/utils}/gesture/map-gesture-to-progress.d.ts +0 -0
- /package/lib/typescript/{utils → shared/utils}/reanimated/version.d.ts +0 -0
- /package/src/{integrations/blank-stack → blank-stack}/utils/with-stack-navigation/_hooks/use-previous.tsx +0 -0
- /package/src/{integrations/blank-stack → blank-stack}/utils/with-stack-navigation/_utils/have-same-route-keys.ts +0 -0
- /package/src/{integrations/blank-stack → blank-stack}/utils/with-stack-navigation/_utils/routes-are-identical.ts +0 -0
- /package/src/{integrations/native-stack → native-stack}/utils/debounce.tsx +0 -0
- /package/src/{integrations/native-stack → native-stack}/utils/useAnimatedHeaderHeight.tsx +0 -0
- /package/src/{integrations/native-stack → native-stack}/utils/useDismissedRouteError.tsx +0 -0
- /package/src/{integrations/native-stack → native-stack}/views/FontProcessor.native.tsx +0 -0
- /package/src/{integrations/native-stack → native-stack}/views/FontProcessor.tsx +0 -0
- /package/src/{integrations/native-stack → native-stack}/views/FooterComponent.tsx +0 -0
- /package/src/{__tests__ → shared/__tests__}/bounds.store.test.ts +0 -0
- /package/src/{__tests__ → shared/__tests__}/determine-dismissal.test.ts +0 -0
- /package/src/{__tests__ → shared/__tests__}/geometry.test.ts +0 -0
- /package/src/{components → shared/components}/create-transition-aware-component.tsx +0 -0
- /package/src/{components → shared/components}/integrations/masked-view.tsx +0 -0
- /package/src/{__configs__ → shared/configs}/specs.ts +0 -0
- /package/src/{hooks → shared/hooks}/animation/use-associated-style.tsx +0 -0
- /package/src/{hooks → shared/hooks}/gestures/use-parent-gesture-registry.tsx +0 -0
- /package/src/{hooks → shared/hooks}/gestures/use-scroll-registry.tsx +0 -0
- /package/src/{hooks → shared/hooks}/use-stable-callback-value.tsx +0 -0
- /package/src/{hooks → shared/hooks}/use-stable-callback.tsx +0 -0
- /package/src/{providers → shared/providers}/gestures.tsx +0 -0
- /package/src/{stores/bounds → shared/stores/bound-store}/_utils.ts +0 -0
- /package/src/{stores → shared/stores}/navigator-dismiss-state.ts +0 -0
- /package/src/{types → shared/types}/bounds.ts +0 -0
- /package/src/{types → shared/types}/gesture.ts +0 -0
- /package/src/{types → shared/types}/utils.ts +0 -0
- /package/src/{utils → shared/utils}/animation/animate.ts +0 -0
- /package/src/{utils → shared/utils}/bounds/_types/geometry.ts +0 -0
- /package/src/{utils → shared/utils}/bounds/_types/get-bounds.ts +0 -0
- /package/src/{utils → shared/utils}/bounds/_utils/flatten-styles.ts +0 -0
- /package/src/{utils → shared/utils}/bounds/_utils/get-bounds.ts +0 -0
- /package/src/{utils → shared/utils}/bounds/_utils/style-composers.ts +0 -0
- /package/src/{utils → shared/utils}/bounds/_utils/styles.ts +0 -0
- /package/src/{utils → shared/utils}/gesture/determine-dismissal.ts +0 -0
- /package/src/{utils → shared/utils}/gesture/map-gesture-to-progress.ts +0 -0
- /package/src/{utils → shared/utils}/reanimated/version.ts +0 -0
|
@@ -1,96 +0,0 @@
|
|
|
1
|
-
import type { NavigationRoute, ParamListBase } from "@react-navigation/native";
|
|
2
|
-
import type * as React from "react";
|
|
3
|
-
import { StyleSheet } from "react-native";
|
|
4
|
-
import Animated, {
|
|
5
|
-
interpolate,
|
|
6
|
-
useAnimatedProps,
|
|
7
|
-
useDerivedValue,
|
|
8
|
-
useSharedValue,
|
|
9
|
-
} from "react-native-reanimated";
|
|
10
|
-
import { Screen as RNSScreen } from "react-native-screens";
|
|
11
|
-
import { Animations } from "../../../stores/animations";
|
|
12
|
-
|
|
13
|
-
interface ScreenProps {
|
|
14
|
-
routeKey: string;
|
|
15
|
-
index: number;
|
|
16
|
-
routes: NavigationRoute<ParamListBase, string>[];
|
|
17
|
-
isPreloaded: boolean;
|
|
18
|
-
children: React.ReactNode;
|
|
19
|
-
freezeOnBlur?: boolean;
|
|
20
|
-
shouldFreeze?: boolean;
|
|
21
|
-
activeScreensLimit: number;
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
const EPSILON = 1e-5;
|
|
25
|
-
|
|
26
|
-
const STATE_INACTIVE = 0;
|
|
27
|
-
const STATE_TRANSITIONING_OR_BELOW_TOP = 1;
|
|
28
|
-
const STATE_ON_TOP = 2;
|
|
29
|
-
|
|
30
|
-
const AnimatedScreen = Animated.createAnimatedComponent(RNSScreen);
|
|
31
|
-
|
|
32
|
-
export const Screen = ({
|
|
33
|
-
routeKey,
|
|
34
|
-
index,
|
|
35
|
-
routes,
|
|
36
|
-
isPreloaded,
|
|
37
|
-
activeScreensLimit,
|
|
38
|
-
children,
|
|
39
|
-
freezeOnBlur,
|
|
40
|
-
shouldFreeze,
|
|
41
|
-
}: ScreenProps) => {
|
|
42
|
-
const sceneProgress = Animations.getAnimation(routeKey, "progress");
|
|
43
|
-
const screenActivity = useSharedValue<0 | 1 | 2>(1);
|
|
44
|
-
|
|
45
|
-
useDerivedValue(() => {
|
|
46
|
-
if (!sceneProgress) {
|
|
47
|
-
screenActivity.value = STATE_TRANSITIONING_OR_BELOW_TOP;
|
|
48
|
-
return;
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
if (index < routes.length - activeScreensLimit - 1 || isPreloaded) {
|
|
52
|
-
screenActivity.value = STATE_INACTIVE;
|
|
53
|
-
} else {
|
|
54
|
-
const outputValue =
|
|
55
|
-
index === routes.length - 1
|
|
56
|
-
? STATE_ON_TOP
|
|
57
|
-
: index >= routes.length - activeScreensLimit
|
|
58
|
-
? STATE_TRANSITIONING_OR_BELOW_TOP
|
|
59
|
-
: STATE_INACTIVE;
|
|
60
|
-
|
|
61
|
-
const v = interpolate(
|
|
62
|
-
sceneProgress.value,
|
|
63
|
-
[0, 1 - EPSILON, 1],
|
|
64
|
-
[1, 1, outputValue],
|
|
65
|
-
"clamp",
|
|
66
|
-
);
|
|
67
|
-
|
|
68
|
-
const next =
|
|
69
|
-
(Math.trunc(v) as 0 | 1 | 2) ?? STATE_TRANSITIONING_OR_BELOW_TOP;
|
|
70
|
-
|
|
71
|
-
// avoid spamming JS thread
|
|
72
|
-
if (next !== screenActivity.value) {
|
|
73
|
-
screenActivity.value = next;
|
|
74
|
-
}
|
|
75
|
-
}
|
|
76
|
-
});
|
|
77
|
-
|
|
78
|
-
const animatedProps = useAnimatedProps(() => {
|
|
79
|
-
return {
|
|
80
|
-
activityState: screenActivity.value,
|
|
81
|
-
shouldFreeze: screenActivity.value === STATE_INACTIVE && shouldFreeze,
|
|
82
|
-
};
|
|
83
|
-
});
|
|
84
|
-
|
|
85
|
-
return (
|
|
86
|
-
<AnimatedScreen
|
|
87
|
-
enabled
|
|
88
|
-
style={StyleSheet.absoluteFill}
|
|
89
|
-
pointerEvents="box-none"
|
|
90
|
-
freezeOnBlur={freezeOnBlur}
|
|
91
|
-
animatedProps={animatedProps}
|
|
92
|
-
>
|
|
93
|
-
{children}
|
|
94
|
-
</AnimatedScreen>
|
|
95
|
-
);
|
|
96
|
-
};
|
|
@@ -1,100 +0,0 @@
|
|
|
1
|
-
import { SafeAreaProviderCompat } from "@react-navigation/elements";
|
|
2
|
-
import {
|
|
3
|
-
NavigationContext,
|
|
4
|
-
NavigationRouteContext,
|
|
5
|
-
} from "@react-navigation/native";
|
|
6
|
-
import { GestureHandlerRootView } from "react-native-gesture-handler";
|
|
7
|
-
import { ScreenContainer } from "react-native-screens";
|
|
8
|
-
import type { BlankStackDescriptor } from "../../../types/blank-stack.navigator";
|
|
9
|
-
import { withStackNavigationProvider } from "../utils/with-stack-navigation";
|
|
10
|
-
import { Header } from "./Header";
|
|
11
|
-
import { Screen } from "./Screens";
|
|
12
|
-
import { ScreenTransitionProvider } from "../providers/screen-transition-provider";
|
|
13
|
-
|
|
14
|
-
function isFabric() {
|
|
15
|
-
return "nativeFabricUIManager" in global;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
type SceneViewProps = {
|
|
19
|
-
descriptor: BlankStackDescriptor;
|
|
20
|
-
isFocused: boolean;
|
|
21
|
-
sceneIndex: number;
|
|
22
|
-
};
|
|
23
|
-
|
|
24
|
-
const SceneView = ({ descriptor }: SceneViewProps) => {
|
|
25
|
-
const { route, navigation, render } = descriptor;
|
|
26
|
-
|
|
27
|
-
return (
|
|
28
|
-
<NavigationContext.Provider value={navigation}>
|
|
29
|
-
<NavigationRouteContext.Provider value={route}>
|
|
30
|
-
{descriptor.options.headerMode === "screen" && <Header.Screen />}
|
|
31
|
-
{render()}
|
|
32
|
-
</NavigationRouteContext.Provider>
|
|
33
|
-
</NavigationContext.Provider>
|
|
34
|
-
);
|
|
35
|
-
};
|
|
36
|
-
|
|
37
|
-
export const StackView = withStackNavigationProvider(
|
|
38
|
-
({
|
|
39
|
-
activeScreensLimit,
|
|
40
|
-
descriptors,
|
|
41
|
-
focusedIndex,
|
|
42
|
-
routes,
|
|
43
|
-
scenes,
|
|
44
|
-
shouldShowFloatHeader,
|
|
45
|
-
}) => {
|
|
46
|
-
return (
|
|
47
|
-
<GestureHandlerRootView>
|
|
48
|
-
<SafeAreaProviderCompat>
|
|
49
|
-
{shouldShowFloatHeader ? <Header.Float /> : null}
|
|
50
|
-
<ScreenContainer style={{ flex: 1 }}>
|
|
51
|
-
{scenes.map((scene, sceneIndex) => {
|
|
52
|
-
const descriptor = scene.descriptor;
|
|
53
|
-
const route = scene.route;
|
|
54
|
-
const isFocused = focusedIndex === sceneIndex;
|
|
55
|
-
const isBelowFocused = focusedIndex - 1 === sceneIndex;
|
|
56
|
-
|
|
57
|
-
const previousDescriptor =
|
|
58
|
-
scenes[sceneIndex - 1]?.descriptor ?? undefined;
|
|
59
|
-
const nextDescriptor =
|
|
60
|
-
scenes[sceneIndex + 1]?.descriptor ?? undefined;
|
|
61
|
-
|
|
62
|
-
const isPreloaded = descriptors[route.key] === undefined;
|
|
63
|
-
|
|
64
|
-
// On Fabric, when screen is frozen, animated and reanimated values are not updated
|
|
65
|
-
// due to component being unmounted. To avoid this, we don't freeze the previous screen there
|
|
66
|
-
const shouldFreeze = isFabric()
|
|
67
|
-
? !isPreloaded && !isFocused && !isBelowFocused
|
|
68
|
-
: !isPreloaded && !isFocused;
|
|
69
|
-
return (
|
|
70
|
-
<Screen
|
|
71
|
-
key={route.key}
|
|
72
|
-
isPreloaded={isPreloaded}
|
|
73
|
-
index={sceneIndex}
|
|
74
|
-
activeScreensLimit={activeScreensLimit}
|
|
75
|
-
routeKey={route.key}
|
|
76
|
-
routes={routes}
|
|
77
|
-
shouldFreeze={shouldFreeze}
|
|
78
|
-
freezeOnBlur={descriptor.options.freezeOnBlur}
|
|
79
|
-
>
|
|
80
|
-
<ScreenTransitionProvider
|
|
81
|
-
previous={previousDescriptor}
|
|
82
|
-
current={descriptor}
|
|
83
|
-
next={nextDescriptor}
|
|
84
|
-
>
|
|
85
|
-
<SceneView
|
|
86
|
-
key={route.key}
|
|
87
|
-
isFocused={isFocused}
|
|
88
|
-
sceneIndex={sceneIndex}
|
|
89
|
-
descriptor={descriptor}
|
|
90
|
-
/>
|
|
91
|
-
</ScreenTransitionProvider>
|
|
92
|
-
</Screen>
|
|
93
|
-
);
|
|
94
|
-
})}
|
|
95
|
-
</ScreenContainer>
|
|
96
|
-
</SafeAreaProviderCompat>
|
|
97
|
-
</GestureHandlerRootView>
|
|
98
|
-
);
|
|
99
|
-
}
|
|
100
|
-
);
|
|
@@ -1,111 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
createNavigatorFactory,
|
|
3
|
-
type EventArg,
|
|
4
|
-
type NavigatorTypeBagBase,
|
|
5
|
-
type ParamListBase,
|
|
6
|
-
type StackActionHelpers,
|
|
7
|
-
StackActions,
|
|
8
|
-
type StackNavigationState,
|
|
9
|
-
StackRouter,
|
|
10
|
-
type StackRouterOptions,
|
|
11
|
-
type StaticConfig,
|
|
12
|
-
type TypedNavigator,
|
|
13
|
-
useNavigationBuilder,
|
|
14
|
-
} from "@react-navigation/native";
|
|
15
|
-
import * as React from "react";
|
|
16
|
-
import { StackView } from "../components/StackView";
|
|
17
|
-
import type {
|
|
18
|
-
BlankStackNavigationEventMap,
|
|
19
|
-
BlankStackNavigationOptions,
|
|
20
|
-
BlankStackNavigationProp,
|
|
21
|
-
BlankStackNavigatorProps,
|
|
22
|
-
} from "../../../types/blank-stack.navigator";
|
|
23
|
-
|
|
24
|
-
function BlankStackNavigator({
|
|
25
|
-
id,
|
|
26
|
-
initialRouteName,
|
|
27
|
-
children,
|
|
28
|
-
layout,
|
|
29
|
-
screenListeners,
|
|
30
|
-
screenOptions,
|
|
31
|
-
screenLayout,
|
|
32
|
-
...rest
|
|
33
|
-
}: BlankStackNavigatorProps) {
|
|
34
|
-
const { state, describe, descriptors, navigation, NavigationContent } =
|
|
35
|
-
useNavigationBuilder<
|
|
36
|
-
StackNavigationState<ParamListBase>,
|
|
37
|
-
StackRouterOptions,
|
|
38
|
-
StackActionHelpers<ParamListBase>,
|
|
39
|
-
BlankStackNavigationOptions,
|
|
40
|
-
BlankStackNavigationEventMap
|
|
41
|
-
>(StackRouter, {
|
|
42
|
-
id,
|
|
43
|
-
initialRouteName,
|
|
44
|
-
children,
|
|
45
|
-
layout,
|
|
46
|
-
screenListeners,
|
|
47
|
-
screenOptions,
|
|
48
|
-
screenLayout,
|
|
49
|
-
});
|
|
50
|
-
|
|
51
|
-
React.useEffect(
|
|
52
|
-
() =>
|
|
53
|
-
// @ts-expect-error: there may not be a tab navigator in parent
|
|
54
|
-
navigation?.addListener?.("tabPress", (e: any) => {
|
|
55
|
-
const isFocused = navigation.isFocused();
|
|
56
|
-
|
|
57
|
-
// Run the operation in the next frame so we're sure all listeners have been run
|
|
58
|
-
// This is necessary to know if preventDefault() has been called
|
|
59
|
-
requestAnimationFrame(() => {
|
|
60
|
-
if (
|
|
61
|
-
state.index > 0 &&
|
|
62
|
-
isFocused &&
|
|
63
|
-
!(e as EventArg<"tabPress", true>).defaultPrevented
|
|
64
|
-
) {
|
|
65
|
-
// When user taps on already focused tab and we're inside the tab,
|
|
66
|
-
// reset the stack to replicate native behaviour
|
|
67
|
-
navigation.dispatch({
|
|
68
|
-
...StackActions.popToTop(),
|
|
69
|
-
target: state.key,
|
|
70
|
-
});
|
|
71
|
-
}
|
|
72
|
-
});
|
|
73
|
-
}),
|
|
74
|
-
[navigation, state.index, state.key]
|
|
75
|
-
);
|
|
76
|
-
|
|
77
|
-
return (
|
|
78
|
-
<NavigationContent>
|
|
79
|
-
<StackView
|
|
80
|
-
{...rest}
|
|
81
|
-
state={state}
|
|
82
|
-
navigation={navigation}
|
|
83
|
-
descriptors={descriptors}
|
|
84
|
-
describe={describe}
|
|
85
|
-
/>
|
|
86
|
-
</NavigationContent>
|
|
87
|
-
);
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
export function createBlankStackNavigator<
|
|
91
|
-
const ParamList extends ParamListBase,
|
|
92
|
-
const NavigatorID extends string | undefined = undefined,
|
|
93
|
-
const TypeBag extends NavigatorTypeBagBase = {
|
|
94
|
-
ParamList: ParamList;
|
|
95
|
-
NavigatorID: NavigatorID;
|
|
96
|
-
State: StackNavigationState<ParamList>;
|
|
97
|
-
ScreenOptions: BlankStackNavigationOptions;
|
|
98
|
-
EventMap: BlankStackNavigationEventMap;
|
|
99
|
-
NavigationList: {
|
|
100
|
-
[RouteName in keyof ParamList]: BlankStackNavigationProp<
|
|
101
|
-
ParamList,
|
|
102
|
-
RouteName,
|
|
103
|
-
NavigatorID
|
|
104
|
-
>;
|
|
105
|
-
};
|
|
106
|
-
Navigator: typeof BlankStackNavigator;
|
|
107
|
-
},
|
|
108
|
-
const Config extends StaticConfig<TypeBag> = StaticConfig<TypeBag>
|
|
109
|
-
>(config?: Config): TypedNavigator<TypeBag, Config> {
|
|
110
|
-
return createNavigatorFactory(BlankStackNavigator)(config);
|
|
111
|
-
}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { ScreenLifecycleController } from "../../../components/controllers/screen-lifecycle.blank";
|
|
2
|
-
import { createScreenTransitionProvider } from "../../../providers/create-screen-transition-provider";
|
|
3
|
-
import type { BlankStackDescriptor } from "../../../types/blank-stack.navigator";
|
|
4
|
-
|
|
5
|
-
export const ScreenTransitionProvider =
|
|
6
|
-
createScreenTransitionProvider<BlankStackDescriptor>(
|
|
7
|
-
ScreenLifecycleController,
|
|
8
|
-
{ defaultEnableTransitions: true },
|
|
9
|
-
);
|
package/src/integrations/blank-stack/utils/with-stack-navigation/_hooks/use-closing-route-keys.tsx
DELETED
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
import { useRef } from "react";
|
|
2
|
-
import { useSharedValue } from "react-native-reanimated";
|
|
3
|
-
import useStableCallback from "../../../../../hooks/use-stable-callback";
|
|
4
|
-
|
|
5
|
-
export const useClosingRouteKeys = () => {
|
|
6
|
-
const keysRef = useRef<Set<string>>(new Set());
|
|
7
|
-
const shared = useSharedValue<string[]>([]);
|
|
8
|
-
|
|
9
|
-
const add = useStableCallback((key: string) => {
|
|
10
|
-
const keys = keysRef.current;
|
|
11
|
-
if (keys.has(key)) {
|
|
12
|
-
return;
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
keys.add(key);
|
|
16
|
-
shared.modify((prev) => {
|
|
17
|
-
"worklet";
|
|
18
|
-
if (!prev.includes(key)) {
|
|
19
|
-
prev.push(key);
|
|
20
|
-
}
|
|
21
|
-
return prev;
|
|
22
|
-
});
|
|
23
|
-
});
|
|
24
|
-
|
|
25
|
-
const remove = useStableCallback((key: string) => {
|
|
26
|
-
const keys = keysRef.current;
|
|
27
|
-
if (!keys.delete(key)) {
|
|
28
|
-
return;
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
shared.modify((prev) => {
|
|
32
|
-
"worklet";
|
|
33
|
-
const index = prev.indexOf(key);
|
|
34
|
-
if (index !== -1) {
|
|
35
|
-
prev.splice(index, 1);
|
|
36
|
-
}
|
|
37
|
-
return prev;
|
|
38
|
-
});
|
|
39
|
-
});
|
|
40
|
-
|
|
41
|
-
const clear = useStableCallback(() => {
|
|
42
|
-
const keys = keysRef.current;
|
|
43
|
-
if (!keys.size) {
|
|
44
|
-
return;
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
keys.clear();
|
|
48
|
-
shared.modify((prev) => {
|
|
49
|
-
"worklet";
|
|
50
|
-
prev.length = 0;
|
|
51
|
-
return prev;
|
|
52
|
-
});
|
|
53
|
-
});
|
|
54
|
-
|
|
55
|
-
return {
|
|
56
|
-
ref: keysRef,
|
|
57
|
-
shared,
|
|
58
|
-
add,
|
|
59
|
-
remove,
|
|
60
|
-
clear,
|
|
61
|
-
};
|
|
62
|
-
};
|
|
@@ -1,280 +0,0 @@
|
|
|
1
|
-
import { type Route, StackActions } from "@react-navigation/native";
|
|
2
|
-
import { useLayoutEffect, useState } from "react";
|
|
3
|
-
import useStableCallback from "../../../../../hooks/use-stable-callback";
|
|
4
|
-
import type { BlankStackDescriptorMap } from "../../../../../types/blank-stack.navigator";
|
|
5
|
-
import type { StackNavigationContextProps } from "../_types";
|
|
6
|
-
import { areDescriptorsEqual } from "../_utils/are-descriptors-equal";
|
|
7
|
-
import { composeDescriptors } from "../_utils/compose-descriptors";
|
|
8
|
-
import { haveSameRouteKeys } from "../_utils/have-same-route-keys";
|
|
9
|
-
import { routesAreIdentical } from "../_utils/routes-are-identical";
|
|
10
|
-
import { useClosingRouteKeys } from "./use-closing-route-keys";
|
|
11
|
-
import { usePrevious } from "./use-previous";
|
|
12
|
-
|
|
13
|
-
type SyncRoutesWithRemovedParams = {
|
|
14
|
-
prevRoutes: Route<string>[];
|
|
15
|
-
prevDescriptors: BlankStackDescriptorMap;
|
|
16
|
-
nextRoutes: Route<string>[];
|
|
17
|
-
nextDescriptors: BlankStackDescriptorMap;
|
|
18
|
-
closingRouteKeys: ReturnType<typeof useClosingRouteKeys>;
|
|
19
|
-
};
|
|
20
|
-
|
|
21
|
-
/**
|
|
22
|
-
* Aligns current routes with the latest route data while preserving references
|
|
23
|
-
* when possible for performance optimization
|
|
24
|
-
*/
|
|
25
|
-
const alignRoutesWithLatest = (
|
|
26
|
-
currentRoutes: Route<string>[],
|
|
27
|
-
currentDescriptors: BlankStackDescriptorMap,
|
|
28
|
-
nextRoutes: Route<string>[],
|
|
29
|
-
nextDescriptors: BlankStackDescriptorMap
|
|
30
|
-
) => {
|
|
31
|
-
// Early return for empty current routes
|
|
32
|
-
if (currentRoutes.length === 0) {
|
|
33
|
-
return {
|
|
34
|
-
routes: nextRoutes,
|
|
35
|
-
descriptors: composeDescriptors(
|
|
36
|
-
nextRoutes,
|
|
37
|
-
nextDescriptors,
|
|
38
|
-
currentDescriptors
|
|
39
|
-
),
|
|
40
|
-
};
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
// Create lookup map for efficient route finding
|
|
44
|
-
const nextRouteLookup = new Map<string, Route<string>>();
|
|
45
|
-
for (const route of nextRoutes) {
|
|
46
|
-
nextRouteLookup.set(route.key, route);
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
// Track if any changes occurred
|
|
50
|
-
let didChange = currentRoutes.length !== nextRoutes.length;
|
|
51
|
-
|
|
52
|
-
// Align routes, updating references where needed
|
|
53
|
-
const alignedRoutes = currentRoutes.map((route) => {
|
|
54
|
-
const nextRoute = nextRouteLookup.get(route.key);
|
|
55
|
-
|
|
56
|
-
if (!nextRoute) {
|
|
57
|
-
return route; // Keep current route if not in next
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
if (nextRoute !== route) {
|
|
61
|
-
didChange = true;
|
|
62
|
-
return nextRoute; // Update to new route reference
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
return route; // Keep current route reference
|
|
66
|
-
});
|
|
67
|
-
|
|
68
|
-
// Only create new array if changes occurred
|
|
69
|
-
const routesResult = didChange ? alignedRoutes : currentRoutes;
|
|
70
|
-
|
|
71
|
-
return {
|
|
72
|
-
routes: routesResult,
|
|
73
|
-
descriptors: composeDescriptors(
|
|
74
|
-
routesResult,
|
|
75
|
-
nextDescriptors,
|
|
76
|
-
currentDescriptors
|
|
77
|
-
),
|
|
78
|
-
};
|
|
79
|
-
};
|
|
80
|
-
|
|
81
|
-
/**
|
|
82
|
-
* Synchronizes routes while handling removed routes that may still be animating out.
|
|
83
|
-
* This manages the complex logic of keeping closing routes visible during transitions.
|
|
84
|
-
*/
|
|
85
|
-
const syncRoutesWithRemoved = ({
|
|
86
|
-
prevRoutes,
|
|
87
|
-
prevDescriptors,
|
|
88
|
-
nextRoutes,
|
|
89
|
-
nextDescriptors,
|
|
90
|
-
closingRouteKeys,
|
|
91
|
-
}: SyncRoutesWithRemovedParams) => {
|
|
92
|
-
if (nextRoutes.length === 0) {
|
|
93
|
-
closingRouteKeys.clear();
|
|
94
|
-
return {
|
|
95
|
-
routes: nextRoutes,
|
|
96
|
-
descriptors: {},
|
|
97
|
-
};
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
// Start with next routes, will mutate if needed
|
|
101
|
-
let derivedRoutes: Route<string>[] = nextRoutes;
|
|
102
|
-
let mutated = false;
|
|
103
|
-
|
|
104
|
-
// Helper to ensure we're working with a mutable copy
|
|
105
|
-
const ensureMutable = () => {
|
|
106
|
-
if (!mutated) {
|
|
107
|
-
derivedRoutes = derivedRoutes.slice();
|
|
108
|
-
mutated = true;
|
|
109
|
-
}
|
|
110
|
-
};
|
|
111
|
-
|
|
112
|
-
// Get focused (last) routes for comparison
|
|
113
|
-
const previousFocusedRoute = prevRoutes[prevRoutes.length - 1];
|
|
114
|
-
const nextFocusedRoute = nextRoutes[nextRoutes.length - 1];
|
|
115
|
-
|
|
116
|
-
// Handle focus changes between routes
|
|
117
|
-
if (
|
|
118
|
-
previousFocusedRoute &&
|
|
119
|
-
nextFocusedRoute &&
|
|
120
|
-
previousFocusedRoute.key !== nextFocusedRoute.key
|
|
121
|
-
) {
|
|
122
|
-
const nextRouteWasPresent = prevRoutes.some(
|
|
123
|
-
(route) => route.key === nextFocusedRoute.key
|
|
124
|
-
);
|
|
125
|
-
const previousRouteStillPresent = nextRoutes.some(
|
|
126
|
-
(route) => route.key === previousFocusedRoute.key
|
|
127
|
-
);
|
|
128
|
-
|
|
129
|
-
if (nextRouteWasPresent && !previousRouteStillPresent) {
|
|
130
|
-
// Previous route was removed, mark as closing
|
|
131
|
-
closingRouteKeys.add(previousFocusedRoute.key);
|
|
132
|
-
|
|
133
|
-
ensureMutable();
|
|
134
|
-
derivedRoutes.push(previousFocusedRoute);
|
|
135
|
-
} else {
|
|
136
|
-
// Next route is now active, not closing
|
|
137
|
-
closingRouteKeys.remove(nextFocusedRoute.key);
|
|
138
|
-
|
|
139
|
-
if (!previousRouteStillPresent) {
|
|
140
|
-
// Previous route needs to be inserted for transition
|
|
141
|
-
closingRouteKeys.remove(previousFocusedRoute.key);
|
|
142
|
-
|
|
143
|
-
ensureMutable();
|
|
144
|
-
const insertIndex = Math.max(derivedRoutes.length - 1, 0);
|
|
145
|
-
derivedRoutes.splice(insertIndex, 0, previousFocusedRoute);
|
|
146
|
-
}
|
|
147
|
-
}
|
|
148
|
-
} else if (nextFocusedRoute) {
|
|
149
|
-
// Same focused route, ensure it's not marked as closing
|
|
150
|
-
closingRouteKeys.remove(nextFocusedRoute.key);
|
|
151
|
-
}
|
|
152
|
-
|
|
153
|
-
// Clean up closing keys that are no longer in the route list
|
|
154
|
-
const activeKeys = new Set(derivedRoutes.map((route) => route.key));
|
|
155
|
-
for (const key of Array.from(closingRouteKeys.ref.current)) {
|
|
156
|
-
if (!activeKeys.has(key)) {
|
|
157
|
-
closingRouteKeys.remove(key);
|
|
158
|
-
}
|
|
159
|
-
}
|
|
160
|
-
|
|
161
|
-
const routesResult = mutated ? derivedRoutes : nextRoutes;
|
|
162
|
-
|
|
163
|
-
return {
|
|
164
|
-
routes: routesResult,
|
|
165
|
-
descriptors: composeDescriptors(
|
|
166
|
-
routesResult,
|
|
167
|
-
nextDescriptors,
|
|
168
|
-
prevDescriptors
|
|
169
|
-
),
|
|
170
|
-
};
|
|
171
|
-
};
|
|
172
|
-
|
|
173
|
-
export const useStackNavigationState = (props: StackNavigationContextProps) => {
|
|
174
|
-
const previousRoutes = usePrevious(props.state.routes) ?? [];
|
|
175
|
-
const closingRouteKeys = useClosingRouteKeys();
|
|
176
|
-
|
|
177
|
-
const [localState, setLocalState] = useState(() => ({
|
|
178
|
-
routes: props.state.routes,
|
|
179
|
-
descriptors: props.descriptors,
|
|
180
|
-
}));
|
|
181
|
-
|
|
182
|
-
useLayoutEffect(() => {
|
|
183
|
-
const nextRoutesSnapshot = props.state.routes;
|
|
184
|
-
const previousRoutesSnapshot = previousRoutes;
|
|
185
|
-
|
|
186
|
-
setLocalState((current) => {
|
|
187
|
-
const routeKeysUnchanged = haveSameRouteKeys(
|
|
188
|
-
previousRoutesSnapshot,
|
|
189
|
-
nextRoutesSnapshot
|
|
190
|
-
);
|
|
191
|
-
|
|
192
|
-
let derivedRoutes: Route<string>[];
|
|
193
|
-
let derivedDescriptors: BlankStackDescriptorMap;
|
|
194
|
-
|
|
195
|
-
if (routeKeysUnchanged) {
|
|
196
|
-
const result = alignRoutesWithLatest(
|
|
197
|
-
current.routes,
|
|
198
|
-
current.descriptors,
|
|
199
|
-
nextRoutesSnapshot,
|
|
200
|
-
props.descriptors
|
|
201
|
-
);
|
|
202
|
-
|
|
203
|
-
derivedRoutes = result.routes;
|
|
204
|
-
derivedDescriptors = result.descriptors;
|
|
205
|
-
} else {
|
|
206
|
-
const fallbackRoutes =
|
|
207
|
-
previousRoutesSnapshot.length > 0
|
|
208
|
-
? previousRoutesSnapshot
|
|
209
|
-
: current.routes;
|
|
210
|
-
|
|
211
|
-
const result = syncRoutesWithRemoved({
|
|
212
|
-
prevRoutes: fallbackRoutes,
|
|
213
|
-
prevDescriptors: current.descriptors,
|
|
214
|
-
nextRoutes: nextRoutesSnapshot,
|
|
215
|
-
nextDescriptors: props.descriptors,
|
|
216
|
-
closingRouteKeys,
|
|
217
|
-
});
|
|
218
|
-
|
|
219
|
-
derivedRoutes = result.routes;
|
|
220
|
-
derivedDescriptors = result.descriptors;
|
|
221
|
-
}
|
|
222
|
-
|
|
223
|
-
const routesChanged = !routesAreIdentical(current.routes, derivedRoutes);
|
|
224
|
-
const descriptorsChanged = !areDescriptorsEqual(
|
|
225
|
-
current.descriptors,
|
|
226
|
-
derivedDescriptors
|
|
227
|
-
);
|
|
228
|
-
|
|
229
|
-
if (!routesChanged && !descriptorsChanged) {
|
|
230
|
-
return current;
|
|
231
|
-
}
|
|
232
|
-
|
|
233
|
-
return {
|
|
234
|
-
routes: routesChanged ? derivedRoutes : current.routes,
|
|
235
|
-
descriptors: descriptorsChanged
|
|
236
|
-
? derivedDescriptors
|
|
237
|
-
: current.descriptors,
|
|
238
|
-
};
|
|
239
|
-
});
|
|
240
|
-
}, [props.state.routes, props.descriptors, previousRoutes, closingRouteKeys]);
|
|
241
|
-
|
|
242
|
-
const handleCloseRoute = useStableCallback(
|
|
243
|
-
({ route }: { route: Route<string> }) => {
|
|
244
|
-
if (props.state.routes.some((r) => r.key === route.key)) {
|
|
245
|
-
props.navigation.dispatch({
|
|
246
|
-
...StackActions.pop(),
|
|
247
|
-
source: route.key,
|
|
248
|
-
target: props.state.key,
|
|
249
|
-
});
|
|
250
|
-
return;
|
|
251
|
-
}
|
|
252
|
-
|
|
253
|
-
closingRouteKeys.remove(route.key);
|
|
254
|
-
|
|
255
|
-
setLocalState((current) => {
|
|
256
|
-
if (!current.routes.some((candidate) => candidate.key === route.key)) {
|
|
257
|
-
return current;
|
|
258
|
-
}
|
|
259
|
-
|
|
260
|
-
const nextRoutes = current.routes.filter(
|
|
261
|
-
(candidate) => candidate.key !== route.key
|
|
262
|
-
);
|
|
263
|
-
|
|
264
|
-
const nextDescriptors = { ...current.descriptors };
|
|
265
|
-
delete nextDescriptors[route.key];
|
|
266
|
-
|
|
267
|
-
return {
|
|
268
|
-
routes: nextRoutes,
|
|
269
|
-
descriptors: nextDescriptors,
|
|
270
|
-
};
|
|
271
|
-
});
|
|
272
|
-
}
|
|
273
|
-
);
|
|
274
|
-
|
|
275
|
-
return {
|
|
276
|
-
state: localState,
|
|
277
|
-
handleCloseRoute,
|
|
278
|
-
closingRouteKeys,
|
|
279
|
-
};
|
|
280
|
-
};
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
NavigationRoute,
|
|
3
|
-
ParamListBase,
|
|
4
|
-
Route,
|
|
5
|
-
RouteProp,
|
|
6
|
-
StackNavigationState,
|
|
7
|
-
} from "@react-navigation/native";
|
|
8
|
-
import type { SharedValue } from "react-native-reanimated";
|
|
9
|
-
import type {
|
|
10
|
-
BlankStackDescriptor,
|
|
11
|
-
BlankStackDescriptorMap,
|
|
12
|
-
BlankStackNavigationHelpers,
|
|
13
|
-
BlankStackScene,
|
|
14
|
-
} from "../../../../types/blank-stack.navigator";
|
|
15
|
-
|
|
16
|
-
export interface StackNavigationContextValue {
|
|
17
|
-
routes: NavigationRoute<ParamListBase, string>[];
|
|
18
|
-
descriptors: BlankStackDescriptorMap;
|
|
19
|
-
scenes: BlankStackScene[];
|
|
20
|
-
activeScreensLimit: number;
|
|
21
|
-
closingRouteKeysShared: SharedValue<string[]>;
|
|
22
|
-
handleCloseRoute: (payload: { route: Route<string> }) => void;
|
|
23
|
-
shouldShowFloatHeader: boolean;
|
|
24
|
-
focusedIndex: number;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
export interface StackNavigationContextProps {
|
|
28
|
-
state: StackNavigationState<ParamListBase>;
|
|
29
|
-
navigation: BlankStackNavigationHelpers;
|
|
30
|
-
descriptors: BlankStackDescriptorMap;
|
|
31
|
-
describe: (
|
|
32
|
-
route: RouteProp<ParamListBase>,
|
|
33
|
-
placeholder: boolean
|
|
34
|
-
) => BlankStackDescriptor;
|
|
35
|
-
}
|