react-native-screen-transitions 2.4.2 → 3.0.0-beta.1
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 +140 -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 +68 -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 +16 -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 +6 -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 +15 -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 +23 -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 +14 -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 +13 -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.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 +136 -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 +63 -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 +11 -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 +4 -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 +10 -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 +19 -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 +9 -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 +8 -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.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 +15 -0
- package/lib/typescript/blank-stack/components/Screens.d.ts.map +1 -0
- package/lib/typescript/blank-stack/components/StackView.d.ts +2 -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 +217 -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 +8 -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 +2 -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 +3 -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 +3 -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 +6 -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.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 +1324 -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.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 +87 -67
- package/src/blank-stack/components/Overlay.tsx +149 -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 +272 -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-previous.tsx +11 -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/_utils/have-same-route-keys.ts +12 -0
- package/src/blank-stack/utils/with-stack-navigation/_utils/routes-are-identical.ts +11 -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/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 +26 -0
- package/src/shared/providers/keys.tsx +57 -0
- package/src/shared/providers/screen-transition-provider.tsx +41 -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.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 -118
- 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 -40
- package/lib/commonjs/index.js.map +0 -1
- package/lib/commonjs/integrations/native-stack/navigators/createNativeStackNavigator.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/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/screen-transition-provider.js +0 -34
- package/lib/commonjs/providers/screen-transition-provider.js.map +0 -1
- 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/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/navigator.js +0 -6
- package/lib/commonjs/types/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.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 -113
- 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 -23
- package/lib/module/index.js.map +0 -1
- package/lib/module/integrations/native-stack/navigators/createNativeStackNavigator.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/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/screen-transition-provider.js +0 -30
- package/lib/module/providers/screen-transition-provider.js.map +0 -1
- 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/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/navigator.js +0 -4
- package/lib/module/types/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.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.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 -1325
- package/lib/typescript/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/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/gestures.d.ts.map +0 -1
- package/lib/typescript/providers/keys.d.ts +0 -16
- package/lib/typescript/providers/keys.d.ts.map +0 -1
- package/lib/typescript/providers/screen-transition-provider.d.ts +0 -11
- package/lib/typescript/providers/screen-transition-provider.d.ts.map +0 -1
- 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/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/navigator.d.ts +0 -691
- package/lib/typescript/types/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.tsx +0 -78
- package/src/constants.ts +0 -108
- package/src/hooks/animation/use-screen-animation.tsx +0 -151
- 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 -34
- package/src/integrations/native-stack/navigators/createNativeStackNavigator.tsx +0 -112
- 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/keys.tsx +0 -38
- package/src/providers/screen-transition-provider.tsx +0 -33
- 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/core.ts +0 -50
- package/src/types/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/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/{providers → shared/providers}/transition-styles.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/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/{providers → shared/providers}/transition-styles.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/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}/animation/use-screen-animation.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/{providers → shared/providers}/transition-styles.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/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/{components → shared/components}/root-transition-aware.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/{providers → shared/providers}/transition-styles.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,650 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
getDefaultHeaderHeight,
|
|
3
|
-
getHeaderTitle,
|
|
4
|
-
HeaderBackContext,
|
|
5
|
-
HeaderHeightContext,
|
|
6
|
-
HeaderShownContext,
|
|
7
|
-
SafeAreaProviderCompat,
|
|
8
|
-
useFrameSize,
|
|
9
|
-
} from "@react-navigation/elements";
|
|
10
|
-
import {
|
|
11
|
-
NavigationContext,
|
|
12
|
-
NavigationRouteContext,
|
|
13
|
-
type ParamListBase,
|
|
14
|
-
type RouteProp,
|
|
15
|
-
StackActions,
|
|
16
|
-
type StackNavigationState,
|
|
17
|
-
usePreventRemoveContext,
|
|
18
|
-
useTheme,
|
|
19
|
-
} from "@react-navigation/native";
|
|
20
|
-
import * as React from "react";
|
|
21
|
-
import {
|
|
22
|
-
Animated,
|
|
23
|
-
Platform,
|
|
24
|
-
StatusBar,
|
|
25
|
-
StyleSheet,
|
|
26
|
-
useAnimatedValue,
|
|
27
|
-
View,
|
|
28
|
-
} from "react-native";
|
|
29
|
-
import { useSafeAreaInsets } from "react-native-safe-area-context";
|
|
30
|
-
import {
|
|
31
|
-
type ScreenProps,
|
|
32
|
-
ScreenStack,
|
|
33
|
-
ScreenStackItem,
|
|
34
|
-
} from "react-native-screens";
|
|
35
|
-
import { ScreenTransitionProvider } from "../../../providers/screen-transition-provider";
|
|
36
|
-
import type {
|
|
37
|
-
NativeStackDescriptor,
|
|
38
|
-
NativeStackDescriptorMap,
|
|
39
|
-
NativeStackNavigationHelpers,
|
|
40
|
-
} from "../../../types/navigator";
|
|
41
|
-
import { debounce } from "../utils/debounce";
|
|
42
|
-
import { getModalRouteKeys } from "../utils/getModalRoutesKeys";
|
|
43
|
-
import { AnimatedHeaderHeightContext } from "../utils/useAnimatedHeaderHeight";
|
|
44
|
-
import { useDismissedRouteError } from "../utils/useDismissedRouteError";
|
|
45
|
-
import { useInvalidPreventRemoveError } from "../utils/useInvalidPreventRemoveError";
|
|
46
|
-
import { useHeaderConfigProps } from "./useHeaderConfigProps";
|
|
47
|
-
|
|
48
|
-
const ANDROID_DEFAULT_HEADER_HEIGHT = 56;
|
|
49
|
-
|
|
50
|
-
function isFabric() {
|
|
51
|
-
return "nativeFabricUIManager" in global;
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
type SceneViewProps = {
|
|
55
|
-
index: number;
|
|
56
|
-
focused: boolean;
|
|
57
|
-
shouldFreeze: boolean;
|
|
58
|
-
descriptor: NativeStackDescriptor;
|
|
59
|
-
previousDescriptor?: NativeStackDescriptor;
|
|
60
|
-
nextDescriptor?: NativeStackDescriptor;
|
|
61
|
-
isPresentationModal?: boolean;
|
|
62
|
-
isPreloaded?: boolean;
|
|
63
|
-
onWillDisappear: () => void;
|
|
64
|
-
onWillAppear: () => void;
|
|
65
|
-
onAppear: () => void;
|
|
66
|
-
onDisappear: () => void;
|
|
67
|
-
onDismissed: ScreenProps["onDismissed"];
|
|
68
|
-
onHeaderBackButtonClicked: ScreenProps["onHeaderBackButtonClicked"];
|
|
69
|
-
onNativeDismissCancelled: ScreenProps["onDismissed"];
|
|
70
|
-
onGestureCancel: ScreenProps["onGestureCancel"];
|
|
71
|
-
onSheetDetentChanged: ScreenProps["onSheetDetentChanged"];
|
|
72
|
-
};
|
|
73
|
-
|
|
74
|
-
const useNativeDriver = Platform.OS !== "web";
|
|
75
|
-
|
|
76
|
-
const SceneView = ({
|
|
77
|
-
index,
|
|
78
|
-
focused,
|
|
79
|
-
shouldFreeze,
|
|
80
|
-
descriptor,
|
|
81
|
-
previousDescriptor,
|
|
82
|
-
nextDescriptor,
|
|
83
|
-
isPresentationModal,
|
|
84
|
-
isPreloaded,
|
|
85
|
-
onWillDisappear,
|
|
86
|
-
onWillAppear,
|
|
87
|
-
onAppear,
|
|
88
|
-
onDisappear,
|
|
89
|
-
onDismissed,
|
|
90
|
-
onHeaderBackButtonClicked,
|
|
91
|
-
onNativeDismissCancelled,
|
|
92
|
-
onGestureCancel,
|
|
93
|
-
onSheetDetentChanged,
|
|
94
|
-
}: SceneViewProps) => {
|
|
95
|
-
const { route, navigation, options, render } = descriptor;
|
|
96
|
-
|
|
97
|
-
let {
|
|
98
|
-
animation,
|
|
99
|
-
animationMatchesGesture,
|
|
100
|
-
presentation = isPresentationModal ? "modal" : "card",
|
|
101
|
-
fullScreenGestureEnabled,
|
|
102
|
-
} = options;
|
|
103
|
-
|
|
104
|
-
const {
|
|
105
|
-
animationDuration,
|
|
106
|
-
animationTypeForReplace = "push",
|
|
107
|
-
fullScreenGestureShadowEnabled = true,
|
|
108
|
-
nativeGestureEnabled,
|
|
109
|
-
nativeGestureDirection = presentation === "card"
|
|
110
|
-
? "horizontal"
|
|
111
|
-
: "vertical",
|
|
112
|
-
nativeGestureResponseDistance,
|
|
113
|
-
header,
|
|
114
|
-
headerBackButtonMenuEnabled,
|
|
115
|
-
headerShown,
|
|
116
|
-
headerBackground,
|
|
117
|
-
headerTransparent,
|
|
118
|
-
autoHideHomeIndicator,
|
|
119
|
-
keyboardHandlingEnabled,
|
|
120
|
-
navigationBarColor,
|
|
121
|
-
navigationBarTranslucent,
|
|
122
|
-
navigationBarHidden,
|
|
123
|
-
orientation,
|
|
124
|
-
sheetAllowedDetents = [1.0],
|
|
125
|
-
sheetLargestUndimmedDetentIndex = -1,
|
|
126
|
-
sheetGrabberVisible = false,
|
|
127
|
-
sheetCornerRadius = -1.0,
|
|
128
|
-
sheetElevation = 24,
|
|
129
|
-
sheetExpandsWhenScrolledToEdge = true,
|
|
130
|
-
sheetInitialDetentIndex = 0,
|
|
131
|
-
statusBarAnimation,
|
|
132
|
-
statusBarHidden,
|
|
133
|
-
statusBarStyle,
|
|
134
|
-
statusBarTranslucent,
|
|
135
|
-
statusBarBackgroundColor,
|
|
136
|
-
unstable_sheetFooter,
|
|
137
|
-
freezeOnBlur,
|
|
138
|
-
contentStyle,
|
|
139
|
-
enableTransitions,
|
|
140
|
-
} = options;
|
|
141
|
-
|
|
142
|
-
if (nativeGestureDirection === "vertical" && Platform.OS === "ios") {
|
|
143
|
-
// for `vertical` direction to work, we need to set `fullScreenGestureEnabled` to `true`
|
|
144
|
-
// so the screen can be dismissed from any point on screen.
|
|
145
|
-
// `animationMatchesGesture` needs to be set to `true` so the `animation` set by user can be used,
|
|
146
|
-
// otherwise `simple_push` will be used.
|
|
147
|
-
// Also, the default animation for this direction seems to be `slide_from_bottom`.
|
|
148
|
-
if (fullScreenGestureEnabled === undefined) {
|
|
149
|
-
fullScreenGestureEnabled = true;
|
|
150
|
-
}
|
|
151
|
-
|
|
152
|
-
if (animationMatchesGesture === undefined) {
|
|
153
|
-
animationMatchesGesture = true;
|
|
154
|
-
}
|
|
155
|
-
|
|
156
|
-
if (animation === undefined) {
|
|
157
|
-
animation = "slide_from_bottom";
|
|
158
|
-
}
|
|
159
|
-
}
|
|
160
|
-
|
|
161
|
-
// workaround for rn-screens where gestureDirection has to be set on both
|
|
162
|
-
// current and previous screen - software-mansion/react-native-screens/pull/1509
|
|
163
|
-
const nextGestureDirection = nextDescriptor?.options.nativeGestureDirection;
|
|
164
|
-
const gestureDirectionOverride =
|
|
165
|
-
nextGestureDirection != null
|
|
166
|
-
? nextGestureDirection
|
|
167
|
-
: nativeGestureDirection;
|
|
168
|
-
|
|
169
|
-
if (index === 0) {
|
|
170
|
-
// first screen should always be treated as `card`, it resolves problems with no header animation
|
|
171
|
-
// for navigator with first screen as `modal` and the next as `card`
|
|
172
|
-
presentation = "card";
|
|
173
|
-
}
|
|
174
|
-
|
|
175
|
-
const { colors } = useTheme();
|
|
176
|
-
const insets = useSafeAreaInsets();
|
|
177
|
-
|
|
178
|
-
// `modal` and `formSheet` presentations do not take whole screen, so should not take the inset.
|
|
179
|
-
const isModal = presentation === "modal" || presentation === "formSheet";
|
|
180
|
-
|
|
181
|
-
// Modals are fullscreen in landscape only on iPhone
|
|
182
|
-
const isIPhone = Platform.OS === "ios" && !(Platform.isPad || Platform.isTV);
|
|
183
|
-
|
|
184
|
-
const isParentHeaderShown = React.useContext(HeaderShownContext);
|
|
185
|
-
const parentHeaderHeight = React.useContext(HeaderHeightContext);
|
|
186
|
-
const parentHeaderBack = React.useContext(HeaderBackContext);
|
|
187
|
-
|
|
188
|
-
const isLandscape = useFrameSize((frame) => frame.width > frame.height);
|
|
189
|
-
|
|
190
|
-
const topInset =
|
|
191
|
-
isParentHeaderShown ||
|
|
192
|
-
(Platform.OS === "ios" && isModal) ||
|
|
193
|
-
(isIPhone && isLandscape)
|
|
194
|
-
? 0
|
|
195
|
-
: insets.top;
|
|
196
|
-
|
|
197
|
-
const defaultHeaderHeight = useFrameSize((frame) =>
|
|
198
|
-
Platform.select({
|
|
199
|
-
// FIXME: Currently screens isn't using Material 3
|
|
200
|
-
// So our `getDefaultHeaderHeight` doesn't return the correct value
|
|
201
|
-
// So we hardcode the value here for now until screens is updated
|
|
202
|
-
android: ANDROID_DEFAULT_HEADER_HEIGHT + topInset,
|
|
203
|
-
default: getDefaultHeaderHeight(frame, isModal, topInset),
|
|
204
|
-
}),
|
|
205
|
-
);
|
|
206
|
-
|
|
207
|
-
const { preventedRoutes } = usePreventRemoveContext();
|
|
208
|
-
|
|
209
|
-
const [headerHeight, setHeaderHeight] = React.useState(defaultHeaderHeight);
|
|
210
|
-
|
|
211
|
-
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
212
|
-
const setHeaderHeightDebounced = React.useCallback(
|
|
213
|
-
// Debounce the header height updates to avoid excessive re-renders
|
|
214
|
-
debounce(setHeaderHeight, 100),
|
|
215
|
-
[],
|
|
216
|
-
);
|
|
217
|
-
|
|
218
|
-
const hasCustomHeader = header != null;
|
|
219
|
-
|
|
220
|
-
let headerHeightCorrectionOffset = 0;
|
|
221
|
-
|
|
222
|
-
if (Platform.OS === "android" && !hasCustomHeader) {
|
|
223
|
-
const statusBarHeight = StatusBar.currentHeight ?? 0;
|
|
224
|
-
|
|
225
|
-
// FIXME: On Android, the native header height is not correctly calculated
|
|
226
|
-
// It includes status bar height even if statusbar is not translucent
|
|
227
|
-
// And the statusbar value itself doesn't match the actual status bar height
|
|
228
|
-
// So we subtract the bogus status bar height and add the actual top inset
|
|
229
|
-
headerHeightCorrectionOffset = -statusBarHeight + topInset;
|
|
230
|
-
}
|
|
231
|
-
|
|
232
|
-
const rawAnimatedHeaderHeight = useAnimatedValue(defaultHeaderHeight);
|
|
233
|
-
const animatedHeaderHeight = React.useMemo(
|
|
234
|
-
() =>
|
|
235
|
-
Animated.add<number>(
|
|
236
|
-
rawAnimatedHeaderHeight,
|
|
237
|
-
headerHeightCorrectionOffset,
|
|
238
|
-
),
|
|
239
|
-
[headerHeightCorrectionOffset, rawAnimatedHeaderHeight],
|
|
240
|
-
);
|
|
241
|
-
|
|
242
|
-
// During the very first render topInset is > 0 when running
|
|
243
|
-
// in non edge-to-edge mode on Android, while on every consecutive render
|
|
244
|
-
// topInset === 0, causing header content to jump, as we add padding on the first frame,
|
|
245
|
-
// just to remove it in next one. To prevent this, when statusBarTranslucent is set,
|
|
246
|
-
// we apply additional padding in header only if its true.
|
|
247
|
-
// For more details see: https://github.com/react-navigation/react-navigation/pull/12014
|
|
248
|
-
const headerTopInsetEnabled =
|
|
249
|
-
typeof statusBarTranslucent === "boolean"
|
|
250
|
-
? statusBarTranslucent
|
|
251
|
-
: topInset !== 0;
|
|
252
|
-
|
|
253
|
-
const canGoBack = previousDescriptor != null || parentHeaderBack != null;
|
|
254
|
-
const backTitle = previousDescriptor
|
|
255
|
-
? getHeaderTitle(previousDescriptor.options, previousDescriptor.route.name)
|
|
256
|
-
: parentHeaderBack?.title;
|
|
257
|
-
|
|
258
|
-
const headerBack = React.useMemo(() => {
|
|
259
|
-
if (canGoBack) {
|
|
260
|
-
return {
|
|
261
|
-
href: undefined, // No href needed for native
|
|
262
|
-
title: backTitle,
|
|
263
|
-
};
|
|
264
|
-
}
|
|
265
|
-
|
|
266
|
-
return undefined;
|
|
267
|
-
}, [canGoBack, backTitle]);
|
|
268
|
-
|
|
269
|
-
const isRemovePrevented = preventedRoutes[route.key]?.preventRemove;
|
|
270
|
-
|
|
271
|
-
const modifiedPresentation = enableTransitions
|
|
272
|
-
? "containedTransparentModal"
|
|
273
|
-
: presentation === "card"
|
|
274
|
-
? "push"
|
|
275
|
-
: presentation;
|
|
276
|
-
const modifiedAnimation = enableTransitions ? "none" : animation;
|
|
277
|
-
const modifiedHeaderShown =
|
|
278
|
-
enableTransitions || header !== undefined ? false : headerShown;
|
|
279
|
-
|
|
280
|
-
const headerConfig = useHeaderConfigProps({
|
|
281
|
-
...options,
|
|
282
|
-
route,
|
|
283
|
-
headerBackButtonMenuEnabled:
|
|
284
|
-
isRemovePrevented !== undefined
|
|
285
|
-
? !isRemovePrevented
|
|
286
|
-
: headerBackButtonMenuEnabled,
|
|
287
|
-
headerBackTitle:
|
|
288
|
-
options.headerBackTitle !== undefined
|
|
289
|
-
? options.headerBackTitle
|
|
290
|
-
: undefined,
|
|
291
|
-
headerHeight,
|
|
292
|
-
headerShown: modifiedHeaderShown,
|
|
293
|
-
headerTopInsetEnabled,
|
|
294
|
-
headerBack,
|
|
295
|
-
});
|
|
296
|
-
|
|
297
|
-
return (
|
|
298
|
-
<NavigationContext.Provider value={navigation}>
|
|
299
|
-
<NavigationRouteContext.Provider value={route}>
|
|
300
|
-
<ScreenStackItem
|
|
301
|
-
key={route.key}
|
|
302
|
-
screenId={route.key}
|
|
303
|
-
activityState={isPreloaded ? 0 : 2}
|
|
304
|
-
style={StyleSheet.absoluteFill}
|
|
305
|
-
aria-hidden={!focused}
|
|
306
|
-
customAnimationOnSwipe={animationMatchesGesture}
|
|
307
|
-
fullScreenSwipeEnabled={fullScreenGestureEnabled}
|
|
308
|
-
fullScreenSwipeShadowEnabled={fullScreenGestureShadowEnabled}
|
|
309
|
-
freezeOnBlur={freezeOnBlur}
|
|
310
|
-
gestureEnabled={
|
|
311
|
-
Platform.OS === "android"
|
|
312
|
-
? // This prop enables handling of system back gestures on Android
|
|
313
|
-
// Since we handle them in JS side, we disable this
|
|
314
|
-
false
|
|
315
|
-
: nativeGestureEnabled
|
|
316
|
-
}
|
|
317
|
-
homeIndicatorHidden={autoHideHomeIndicator}
|
|
318
|
-
hideKeyboardOnSwipe={keyboardHandlingEnabled}
|
|
319
|
-
navigationBarColor={navigationBarColor}
|
|
320
|
-
navigationBarTranslucent={navigationBarTranslucent}
|
|
321
|
-
navigationBarHidden={navigationBarHidden}
|
|
322
|
-
replaceAnimation={animationTypeForReplace}
|
|
323
|
-
stackPresentation={modifiedPresentation}
|
|
324
|
-
stackAnimation={modifiedAnimation}
|
|
325
|
-
screenOrientation={orientation}
|
|
326
|
-
sheetAllowedDetents={sheetAllowedDetents}
|
|
327
|
-
sheetLargestUndimmedDetentIndex={sheetLargestUndimmedDetentIndex}
|
|
328
|
-
sheetGrabberVisible={sheetGrabberVisible}
|
|
329
|
-
sheetInitialDetentIndex={sheetInitialDetentIndex}
|
|
330
|
-
sheetCornerRadius={sheetCornerRadius}
|
|
331
|
-
sheetElevation={sheetElevation}
|
|
332
|
-
sheetExpandsWhenScrolledToEdge={sheetExpandsWhenScrolledToEdge}
|
|
333
|
-
statusBarAnimation={statusBarAnimation}
|
|
334
|
-
statusBarHidden={statusBarHidden}
|
|
335
|
-
statusBarStyle={statusBarStyle}
|
|
336
|
-
statusBarColor={statusBarBackgroundColor}
|
|
337
|
-
statusBarTranslucent={statusBarTranslucent}
|
|
338
|
-
swipeDirection={gestureDirectionOverride}
|
|
339
|
-
transitionDuration={animationDuration}
|
|
340
|
-
onWillAppear={onWillAppear}
|
|
341
|
-
onWillDisappear={onWillDisappear}
|
|
342
|
-
onAppear={onAppear}
|
|
343
|
-
onDisappear={onDisappear}
|
|
344
|
-
onDismissed={onDismissed}
|
|
345
|
-
onGestureCancel={onGestureCancel}
|
|
346
|
-
onSheetDetentChanged={onSheetDetentChanged}
|
|
347
|
-
gestureResponseDistance={nativeGestureResponseDistance}
|
|
348
|
-
nativeBackButtonDismissalEnabled={false} // on Android
|
|
349
|
-
onHeaderBackButtonClicked={onHeaderBackButtonClicked}
|
|
350
|
-
preventNativeDismiss={isRemovePrevented} // on iOS
|
|
351
|
-
onNativeDismissCancelled={onNativeDismissCancelled}
|
|
352
|
-
// Unfortunately, because of the bug that exists on Fabric, where native event drivers
|
|
353
|
-
// for Animated objects are being created after the first notifications about the header height
|
|
354
|
-
// from the native side, `onHeaderHeightChange` event does not notify
|
|
355
|
-
// `animatedHeaderHeight` about initial values on appearing screens at the moment.
|
|
356
|
-
onHeaderHeightChange={Animated.event(
|
|
357
|
-
[
|
|
358
|
-
{
|
|
359
|
-
nativeEvent: {
|
|
360
|
-
headerHeight: rawAnimatedHeaderHeight,
|
|
361
|
-
},
|
|
362
|
-
},
|
|
363
|
-
],
|
|
364
|
-
{
|
|
365
|
-
useNativeDriver,
|
|
366
|
-
listener: (e) => {
|
|
367
|
-
if (hasCustomHeader) {
|
|
368
|
-
// If we have a custom header, don't use native header height
|
|
369
|
-
return;
|
|
370
|
-
}
|
|
371
|
-
|
|
372
|
-
if (
|
|
373
|
-
Platform.OS === "android" &&
|
|
374
|
-
(options.headerBackground != null ||
|
|
375
|
-
options.headerTransparent)
|
|
376
|
-
) {
|
|
377
|
-
// FIXME: On Android, we get 0 if the header is translucent
|
|
378
|
-
// So we set a default height in that case
|
|
379
|
-
setHeaderHeight(ANDROID_DEFAULT_HEADER_HEIGHT + topInset);
|
|
380
|
-
return;
|
|
381
|
-
}
|
|
382
|
-
|
|
383
|
-
if (
|
|
384
|
-
e.nativeEvent &&
|
|
385
|
-
typeof e.nativeEvent === "object" &&
|
|
386
|
-
"headerHeight" in e.nativeEvent &&
|
|
387
|
-
typeof e.nativeEvent.headerHeight === "number"
|
|
388
|
-
) {
|
|
389
|
-
const headerHeight =
|
|
390
|
-
e.nativeEvent.headerHeight + headerHeightCorrectionOffset;
|
|
391
|
-
|
|
392
|
-
// Only debounce if header has large title or search bar
|
|
393
|
-
// As it's the only case where the header height can change frequently
|
|
394
|
-
const doesHeaderAnimate =
|
|
395
|
-
Platform.OS === "ios" &&
|
|
396
|
-
(options.headerLargeTitle ||
|
|
397
|
-
options.headerSearchBarOptions);
|
|
398
|
-
|
|
399
|
-
if (doesHeaderAnimate) {
|
|
400
|
-
setHeaderHeightDebounced(headerHeight);
|
|
401
|
-
} else {
|
|
402
|
-
setHeaderHeight(headerHeight);
|
|
403
|
-
}
|
|
404
|
-
}
|
|
405
|
-
},
|
|
406
|
-
},
|
|
407
|
-
)}
|
|
408
|
-
contentStyle={[
|
|
409
|
-
modifiedPresentation !== "transparentModal" &&
|
|
410
|
-
modifiedPresentation !== "containedTransparentModal" && {
|
|
411
|
-
backgroundColor: colors.background,
|
|
412
|
-
},
|
|
413
|
-
contentStyle,
|
|
414
|
-
]}
|
|
415
|
-
headerConfig={headerConfig}
|
|
416
|
-
unstable_sheetFooter={unstable_sheetFooter}
|
|
417
|
-
// When ts-expect-error is added, it affects all the props below it
|
|
418
|
-
// So we keep any props that need it at the end
|
|
419
|
-
// Otherwise invalid props may not be caught by TypeScript
|
|
420
|
-
shouldFreeze={shouldFreeze}
|
|
421
|
-
>
|
|
422
|
-
<AnimatedHeaderHeightContext.Provider value={animatedHeaderHeight}>
|
|
423
|
-
<HeaderHeightContext.Provider
|
|
424
|
-
value={
|
|
425
|
-
headerShown !== false ? headerHeight : (parentHeaderHeight ?? 0)
|
|
426
|
-
}
|
|
427
|
-
>
|
|
428
|
-
{headerBackground != null ? (
|
|
429
|
-
/**
|
|
430
|
-
* To show a custom header background, we render it at the top of the screen below the header
|
|
431
|
-
* The header also needs to be positioned absolutely (with `translucent` style)
|
|
432
|
-
*/
|
|
433
|
-
<View
|
|
434
|
-
style={[
|
|
435
|
-
styles.background,
|
|
436
|
-
headerTransparent ? styles.translucent : null,
|
|
437
|
-
{ height: headerHeight },
|
|
438
|
-
]}
|
|
439
|
-
>
|
|
440
|
-
{headerBackground()}
|
|
441
|
-
</View>
|
|
442
|
-
) : null}
|
|
443
|
-
{header != null && headerShown !== false ? (
|
|
444
|
-
<View
|
|
445
|
-
onLayout={(e) => {
|
|
446
|
-
const headerHeight = e.nativeEvent.layout.height;
|
|
447
|
-
|
|
448
|
-
setHeaderHeight(headerHeight);
|
|
449
|
-
rawAnimatedHeaderHeight.setValue(headerHeight);
|
|
450
|
-
}}
|
|
451
|
-
style={[
|
|
452
|
-
styles.header,
|
|
453
|
-
headerTransparent ? styles.absolute : null,
|
|
454
|
-
]}
|
|
455
|
-
>
|
|
456
|
-
{header({
|
|
457
|
-
back: headerBack,
|
|
458
|
-
options,
|
|
459
|
-
route,
|
|
460
|
-
navigation,
|
|
461
|
-
})}
|
|
462
|
-
</View>
|
|
463
|
-
) : null}
|
|
464
|
-
<HeaderShownContext.Provider
|
|
465
|
-
value={isParentHeaderShown || headerShown !== false}
|
|
466
|
-
>
|
|
467
|
-
<HeaderBackContext.Provider value={headerBack}>
|
|
468
|
-
<ScreenTransitionProvider
|
|
469
|
-
previous={previousDescriptor}
|
|
470
|
-
current={descriptor}
|
|
471
|
-
next={nextDescriptor}
|
|
472
|
-
>
|
|
473
|
-
{render()}
|
|
474
|
-
</ScreenTransitionProvider>
|
|
475
|
-
</HeaderBackContext.Provider>
|
|
476
|
-
</HeaderShownContext.Provider>
|
|
477
|
-
</HeaderHeightContext.Provider>
|
|
478
|
-
</AnimatedHeaderHeightContext.Provider>
|
|
479
|
-
</ScreenStackItem>
|
|
480
|
-
</NavigationRouteContext.Provider>
|
|
481
|
-
</NavigationContext.Provider>
|
|
482
|
-
);
|
|
483
|
-
};
|
|
484
|
-
|
|
485
|
-
type Props = {
|
|
486
|
-
state: StackNavigationState<ParamListBase>;
|
|
487
|
-
navigation: NativeStackNavigationHelpers;
|
|
488
|
-
descriptors: NativeStackDescriptorMap;
|
|
489
|
-
describe: (
|
|
490
|
-
route: RouteProp<ParamListBase>,
|
|
491
|
-
placeholder: boolean,
|
|
492
|
-
) => NativeStackDescriptor;
|
|
493
|
-
};
|
|
494
|
-
|
|
495
|
-
export function NativeStackView({
|
|
496
|
-
state,
|
|
497
|
-
navigation,
|
|
498
|
-
descriptors,
|
|
499
|
-
describe,
|
|
500
|
-
}: Props) {
|
|
501
|
-
const { setNextDismissedKey } = useDismissedRouteError(state);
|
|
502
|
-
|
|
503
|
-
useInvalidPreventRemoveError(descriptors);
|
|
504
|
-
|
|
505
|
-
const modalRouteKeys = getModalRouteKeys(state.routes, descriptors);
|
|
506
|
-
|
|
507
|
-
const preloadedDescriptors =
|
|
508
|
-
state.preloadedRoutes.reduce<NativeStackDescriptorMap>((acc, route) => {
|
|
509
|
-
acc[route.key] = acc[route.key] || describe(route, true);
|
|
510
|
-
return acc;
|
|
511
|
-
}, {});
|
|
512
|
-
|
|
513
|
-
return (
|
|
514
|
-
<SafeAreaProviderCompat>
|
|
515
|
-
<ScreenStack style={styles.container}>
|
|
516
|
-
{state.routes.concat(state.preloadedRoutes).map((route, index) => {
|
|
517
|
-
const descriptor =
|
|
518
|
-
descriptors[route.key] ?? preloadedDescriptors[route.key];
|
|
519
|
-
const isFocused = state.index === index;
|
|
520
|
-
const isBelowFocused = state.index - 1 === index;
|
|
521
|
-
const previousKey = state.routes[index - 1]?.key;
|
|
522
|
-
const nextKey = state.routes[index + 1]?.key;
|
|
523
|
-
const previousDescriptor = previousKey
|
|
524
|
-
? descriptors[previousKey]
|
|
525
|
-
: undefined;
|
|
526
|
-
const nextDescriptor = nextKey ? descriptors[nextKey] : undefined;
|
|
527
|
-
|
|
528
|
-
const isModal = modalRouteKeys.includes(route.key);
|
|
529
|
-
|
|
530
|
-
const isPreloaded =
|
|
531
|
-
preloadedDescriptors[route.key] !== undefined &&
|
|
532
|
-
descriptors[route.key] === undefined;
|
|
533
|
-
|
|
534
|
-
// On Fabric, when screen is frozen, animated and reanimated values are not updated
|
|
535
|
-
// due to component being unmounted. To avoid this, we don't freeze the previous screen there
|
|
536
|
-
const shouldFreeze = isFabric()
|
|
537
|
-
? !isPreloaded && !isFocused && !isBelowFocused
|
|
538
|
-
: !isPreloaded && !isFocused;
|
|
539
|
-
|
|
540
|
-
return (
|
|
541
|
-
<SceneView
|
|
542
|
-
key={route.key}
|
|
543
|
-
index={index}
|
|
544
|
-
focused={isFocused}
|
|
545
|
-
shouldFreeze={shouldFreeze}
|
|
546
|
-
descriptor={descriptor}
|
|
547
|
-
previousDescriptor={previousDescriptor}
|
|
548
|
-
nextDescriptor={nextDescriptor}
|
|
549
|
-
isPresentationModal={isModal}
|
|
550
|
-
isPreloaded={isPreloaded}
|
|
551
|
-
onWillDisappear={() => {
|
|
552
|
-
navigation.emit({
|
|
553
|
-
type: "transitionStart",
|
|
554
|
-
data: { closing: true },
|
|
555
|
-
target: route.key,
|
|
556
|
-
});
|
|
557
|
-
}}
|
|
558
|
-
onWillAppear={() => {
|
|
559
|
-
navigation.emit({
|
|
560
|
-
type: "transitionStart",
|
|
561
|
-
data: { closing: false },
|
|
562
|
-
target: route.key,
|
|
563
|
-
});
|
|
564
|
-
}}
|
|
565
|
-
onAppear={() => {
|
|
566
|
-
navigation.emit({
|
|
567
|
-
type: "transitionEnd",
|
|
568
|
-
data: { closing: false },
|
|
569
|
-
target: route.key,
|
|
570
|
-
});
|
|
571
|
-
}}
|
|
572
|
-
onDisappear={() => {
|
|
573
|
-
navigation.emit({
|
|
574
|
-
type: "transitionEnd",
|
|
575
|
-
data: { closing: true },
|
|
576
|
-
target: route.key,
|
|
577
|
-
});
|
|
578
|
-
}}
|
|
579
|
-
onDismissed={(event) => {
|
|
580
|
-
navigation.dispatch({
|
|
581
|
-
...StackActions.pop(event.nativeEvent.dismissCount),
|
|
582
|
-
source: route.key,
|
|
583
|
-
target: state.key,
|
|
584
|
-
});
|
|
585
|
-
|
|
586
|
-
setNextDismissedKey(route.key);
|
|
587
|
-
}}
|
|
588
|
-
onHeaderBackButtonClicked={() => {
|
|
589
|
-
navigation.dispatch({
|
|
590
|
-
...StackActions.pop(),
|
|
591
|
-
source: route.key,
|
|
592
|
-
target: state.key,
|
|
593
|
-
});
|
|
594
|
-
}}
|
|
595
|
-
onNativeDismissCancelled={(event) => {
|
|
596
|
-
navigation.dispatch({
|
|
597
|
-
...StackActions.pop(event.nativeEvent.dismissCount),
|
|
598
|
-
source: route.key,
|
|
599
|
-
target: state.key,
|
|
600
|
-
});
|
|
601
|
-
}}
|
|
602
|
-
onGestureCancel={() => {
|
|
603
|
-
navigation.emit({
|
|
604
|
-
type: "gestureCancel",
|
|
605
|
-
target: route.key,
|
|
606
|
-
});
|
|
607
|
-
}}
|
|
608
|
-
onSheetDetentChanged={(event) => {
|
|
609
|
-
navigation.emit({
|
|
610
|
-
type: "sheetDetentChange",
|
|
611
|
-
target: route.key,
|
|
612
|
-
data: {
|
|
613
|
-
index: event.nativeEvent.index,
|
|
614
|
-
stable: event.nativeEvent.isStable,
|
|
615
|
-
},
|
|
616
|
-
});
|
|
617
|
-
}}
|
|
618
|
-
/>
|
|
619
|
-
);
|
|
620
|
-
})}
|
|
621
|
-
</ScreenStack>
|
|
622
|
-
</SafeAreaProviderCompat>
|
|
623
|
-
);
|
|
624
|
-
}
|
|
625
|
-
|
|
626
|
-
const styles = StyleSheet.create({
|
|
627
|
-
container: {
|
|
628
|
-
flex: 1,
|
|
629
|
-
},
|
|
630
|
-
header: {
|
|
631
|
-
zIndex: 1,
|
|
632
|
-
},
|
|
633
|
-
absolute: {
|
|
634
|
-
position: "absolute",
|
|
635
|
-
top: 0,
|
|
636
|
-
start: 0,
|
|
637
|
-
end: 0,
|
|
638
|
-
},
|
|
639
|
-
translucent: {
|
|
640
|
-
position: "absolute",
|
|
641
|
-
top: 0,
|
|
642
|
-
start: 0,
|
|
643
|
-
end: 0,
|
|
644
|
-
zIndex: 1,
|
|
645
|
-
elevation: 1,
|
|
646
|
-
},
|
|
647
|
-
background: {
|
|
648
|
-
overflow: "hidden",
|
|
649
|
-
},
|
|
650
|
-
});
|