react-native-screen-transitions 3.4.0-alpha.0 → 3.4.0-alpha.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 +65 -2
- package/lib/commonjs/shared/animation/snap-to.js +5 -1
- package/lib/commonjs/shared/animation/snap-to.js.map +1 -1
- package/lib/commonjs/shared/components/create-boundary-component/utils/build-boundary-match-key.js +5 -10
- package/lib/commonjs/shared/components/create-boundary-component/utils/build-boundary-match-key.js.map +1 -1
- package/lib/commonjs/shared/components/overlay/helpers/get-active-overlay.js +2 -2
- package/lib/commonjs/shared/components/overlay/helpers/get-active-overlay.js.map +1 -1
- package/lib/commonjs/shared/components/overlay/index.js +1 -3
- package/lib/commonjs/shared/components/overlay/index.js.map +1 -1
- package/lib/commonjs/shared/components/overlay/variations/overlay-host.js +2 -16
- package/lib/commonjs/shared/components/overlay/variations/overlay-host.js.map +1 -1
- package/lib/commonjs/shared/components/scene-view.js +2 -4
- package/lib/commonjs/shared/components/scene-view.js.map +1 -1
- package/lib/commonjs/shared/components/screen-container/layers/backdrop.js +9 -6
- package/lib/commonjs/shared/components/screen-container/layers/backdrop.js.map +1 -1
- package/lib/commonjs/shared/components/screen-container/layers/content.js +47 -55
- package/lib/commonjs/shared/components/screen-container/layers/content.js.map +1 -1
- package/lib/commonjs/shared/components/screen-container/layers/maybe-masked-navigation-container.js +77 -0
- package/lib/commonjs/shared/components/screen-container/layers/maybe-masked-navigation-container.js.map +1 -0
- package/lib/commonjs/shared/components/screen-lifecycle/hooks/use-close-transition/index.js.map +1 -1
- package/lib/commonjs/shared/components/screen-lifecycle/hooks/use-open-transition.js +17 -4
- package/lib/commonjs/shared/components/screen-lifecycle/hooks/use-open-transition.js.map +1 -1
- package/lib/commonjs/shared/constants.js +6 -2
- package/lib/commonjs/shared/constants.js.map +1 -1
- package/lib/commonjs/shared/hooks/gestures/resolve-screen-gesture-target.js +49 -0
- package/lib/commonjs/shared/hooks/gestures/resolve-screen-gesture-target.js.map +1 -0
- package/lib/commonjs/shared/hooks/gestures/types.js +2 -0
- package/lib/commonjs/shared/hooks/gestures/types.js.map +1 -0
- package/lib/commonjs/shared/hooks/gestures/use-screen-gesture.js +7 -3
- package/lib/commonjs/shared/hooks/gestures/use-screen-gesture.js.map +1 -1
- package/lib/commonjs/shared/hooks/navigation/use-stack.js.map +1 -1
- package/lib/commonjs/shared/index.js +15 -3
- package/lib/commonjs/shared/index.js.map +1 -1
- package/lib/commonjs/shared/providers/gestures/handlers/use-handlers.js +55 -18
- package/lib/commonjs/shared/providers/gestures/handlers/use-handlers.js.map +1 -1
- package/lib/commonjs/shared/providers/gestures/helpers/gesture-snap-points.js +44 -0
- package/lib/commonjs/shared/providers/gestures/helpers/gesture-snap-points.js.map +1 -0
- package/lib/commonjs/shared/providers/screen/animation/animation.provider.js +31 -17
- package/lib/commonjs/shared/providers/screen/animation/animation.provider.js.map +1 -1
- package/lib/commonjs/shared/providers/screen/animation/helpers/derivations.js +1 -9
- package/lib/commonjs/shared/providers/screen/animation/helpers/derivations.js.map +1 -1
- package/lib/commonjs/shared/providers/screen/animation/helpers/pipeline.js +11 -6
- package/lib/commonjs/shared/providers/screen/animation/helpers/pipeline.js.map +1 -1
- package/lib/commonjs/shared/providers/screen/animation/helpers/resolve-screen-animation-target.js +33 -0
- package/lib/commonjs/shared/providers/screen/animation/helpers/resolve-screen-animation-target.js.map +1 -0
- package/lib/commonjs/shared/providers/screen/animation/types.js +2 -0
- package/lib/commonjs/shared/providers/screen/animation/types.js.map +1 -0
- package/lib/commonjs/shared/providers/screen/animation/use-screen-animation.js +9 -3
- package/lib/commonjs/shared/providers/screen/animation/use-screen-animation.js.map +1 -1
- package/lib/commonjs/shared/providers/stack/direct.provider.js +1 -1
- package/lib/commonjs/shared/providers/stack/direct.provider.js.map +1 -1
- package/lib/commonjs/shared/providers/stack/helpers/use-processed-routes.js +1 -1
- package/lib/commonjs/shared/providers/stack/helpers/use-processed-routes.js.map +1 -1
- package/lib/commonjs/shared/stores/animation.store.js +8 -2
- package/lib/commonjs/shared/stores/animation.store.js.map +1 -1
- package/lib/commonjs/shared/stores/bounds/internals/resolver.js +7 -0
- package/lib/commonjs/shared/stores/bounds/internals/resolver.js.map +1 -1
- package/lib/commonjs/shared/utils/animation/animate-to-progress.js +6 -0
- package/lib/commonjs/shared/utils/animation/animate-to-progress.js.map +1 -1
- package/lib/commonjs/shared/utils/bounds/helpers/compute-bounds-styles.js +24 -9
- package/lib/commonjs/shared/utils/bounds/helpers/compute-bounds-styles.js.map +1 -1
- package/lib/commonjs/shared/utils/bounds/helpers/geometry.js +3 -2
- package/lib/commonjs/shared/utils/bounds/helpers/geometry.js.map +1 -1
- package/lib/commonjs/shared/utils/bounds/helpers/interpolators.js +3 -2
- package/lib/commonjs/shared/utils/bounds/helpers/interpolators.js.map +1 -1
- package/lib/commonjs/shared/utils/bounds/helpers/link-accessor.js +2 -2
- package/lib/commonjs/shared/utils/bounds/helpers/link-accessor.js.map +1 -1
- package/lib/commonjs/shared/utils/bounds/helpers/resolve-bound-tag.js +6 -5
- package/lib/commonjs/shared/utils/bounds/helpers/resolve-bound-tag.js.map +1 -1
- package/lib/commonjs/shared/utils/bounds/helpers/style-composers.js +4 -3
- package/lib/commonjs/shared/utils/bounds/helpers/style-composers.js.map +1 -1
- package/lib/commonjs/shared/utils/bounds/index.js +3 -3
- package/lib/commonjs/shared/utils/bounds/index.js.map +1 -1
- package/lib/commonjs/shared/utils/bounds/zoom/accessor.js +54 -0
- package/lib/commonjs/shared/utils/bounds/zoom/accessor.js.map +1 -0
- package/lib/commonjs/shared/utils/bounds/zoom/build.js +541 -0
- package/lib/commonjs/shared/utils/bounds/zoom/build.js.map +1 -0
- package/lib/commonjs/shared/utils/bounds/zoom/config.js +118 -0
- package/lib/commonjs/shared/utils/bounds/zoom/config.js.map +1 -0
- package/lib/commonjs/shared/utils/bounds/zoom/index.js +20 -0
- package/lib/commonjs/shared/utils/bounds/zoom/index.js.map +1 -0
- package/lib/commonjs/shared/utils/bounds/zoom/types.js.map +1 -0
- package/lib/commonjs/shared/utils/gesture/validate-snap-points.js +11 -5
- package/lib/commonjs/shared/utils/gesture/validate-snap-points.js.map +1 -1
- package/lib/commonjs/shared/utils/overlay/visibility.js +2 -9
- package/lib/commonjs/shared/utils/overlay/visibility.js.map +1 -1
- package/lib/module/shared/animation/snap-to.js +5 -1
- package/lib/module/shared/animation/snap-to.js.map +1 -1
- package/lib/module/shared/components/create-boundary-component/utils/build-boundary-match-key.js +5 -10
- package/lib/module/shared/components/create-boundary-component/utils/build-boundary-match-key.js.map +1 -1
- package/lib/module/shared/components/overlay/helpers/get-active-overlay.js +3 -3
- package/lib/module/shared/components/overlay/helpers/get-active-overlay.js.map +1 -1
- package/lib/module/shared/components/overlay/index.js +1 -3
- package/lib/module/shared/components/overlay/index.js.map +1 -1
- package/lib/module/shared/components/overlay/variations/overlay-host.js +3 -17
- package/lib/module/shared/components/overlay/variations/overlay-host.js.map +1 -1
- package/lib/module/shared/components/scene-view.js +3 -5
- package/lib/module/shared/components/scene-view.js.map +1 -1
- package/lib/module/shared/components/screen-container/layers/backdrop.js +9 -6
- package/lib/module/shared/components/screen-container/layers/backdrop.js.map +1 -1
- package/lib/module/shared/components/screen-container/layers/content.js +52 -60
- package/lib/module/shared/components/screen-container/layers/content.js.map +1 -1
- package/lib/module/shared/components/screen-container/layers/maybe-masked-navigation-container.js +72 -0
- package/lib/module/shared/components/screen-container/layers/maybe-masked-navigation-container.js.map +1 -0
- package/lib/module/shared/components/screen-lifecycle/hooks/use-close-transition/index.js.map +1 -1
- package/lib/module/shared/components/screen-lifecycle/hooks/use-open-transition.js +17 -4
- package/lib/module/shared/components/screen-lifecycle/hooks/use-open-transition.js.map +1 -1
- package/lib/module/shared/constants.js +6 -2
- package/lib/module/shared/constants.js.map +1 -1
- package/lib/module/shared/hooks/gestures/resolve-screen-gesture-target.js +45 -0
- package/lib/module/shared/hooks/gestures/resolve-screen-gesture-target.js.map +1 -0
- package/lib/module/shared/hooks/gestures/types.js +2 -0
- package/lib/module/shared/hooks/gestures/types.js.map +1 -0
- package/lib/module/shared/hooks/gestures/use-screen-gesture.js +7 -4
- package/lib/module/shared/hooks/gestures/use-screen-gesture.js.map +1 -1
- package/lib/module/shared/hooks/navigation/use-stack.js.map +1 -1
- package/lib/module/shared/index.js +1 -2
- package/lib/module/shared/index.js.map +1 -1
- package/lib/module/shared/providers/gestures/handlers/use-handlers.js +55 -18
- package/lib/module/shared/providers/gestures/handlers/use-handlers.js.map +1 -1
- package/lib/module/shared/providers/gestures/helpers/gesture-snap-points.js +38 -0
- package/lib/module/shared/providers/gestures/helpers/gesture-snap-points.js.map +1 -0
- package/lib/module/shared/providers/screen/animation/animation.provider.js +30 -15
- package/lib/module/shared/providers/screen/animation/animation.provider.js.map +1 -1
- package/lib/module/shared/providers/screen/animation/helpers/derivations.js +1 -9
- package/lib/module/shared/providers/screen/animation/helpers/derivations.js.map +1 -1
- package/lib/module/shared/providers/screen/animation/helpers/pipeline.js +11 -6
- package/lib/module/shared/providers/screen/animation/helpers/pipeline.js.map +1 -1
- package/lib/module/shared/providers/screen/animation/helpers/resolve-screen-animation-target.js +29 -0
- package/lib/module/shared/providers/screen/animation/helpers/resolve-screen-animation-target.js.map +1 -0
- package/lib/module/shared/providers/screen/animation/index.js.map +1 -1
- package/lib/module/shared/providers/screen/animation/types.js +2 -0
- package/lib/module/shared/providers/screen/animation/types.js.map +1 -0
- package/lib/module/shared/providers/screen/animation/use-screen-animation.js +9 -3
- package/lib/module/shared/providers/screen/animation/use-screen-animation.js.map +1 -1
- package/lib/module/shared/providers/stack/direct.provider.js +2 -2
- package/lib/module/shared/providers/stack/direct.provider.js.map +1 -1
- package/lib/module/shared/providers/stack/helpers/use-processed-routes.js +2 -2
- package/lib/module/shared/providers/stack/helpers/use-processed-routes.js.map +1 -1
- package/lib/module/shared/stores/animation.store.js +8 -2
- package/lib/module/shared/stores/animation.store.js.map +1 -1
- package/lib/module/shared/stores/bounds/internals/resolver.js +7 -0
- package/lib/module/shared/stores/bounds/internals/resolver.js.map +1 -1
- package/lib/module/shared/utils/animation/animate-to-progress.js +6 -0
- package/lib/module/shared/utils/animation/animate-to-progress.js.map +1 -1
- package/lib/module/shared/utils/bounds/helpers/compute-bounds-styles.js +24 -9
- package/lib/module/shared/utils/bounds/helpers/compute-bounds-styles.js.map +1 -1
- package/lib/module/shared/utils/bounds/helpers/geometry.js +3 -2
- package/lib/module/shared/utils/bounds/helpers/geometry.js.map +1 -1
- package/lib/module/shared/utils/bounds/helpers/interpolators.js +3 -2
- package/lib/module/shared/utils/bounds/helpers/interpolators.js.map +1 -1
- package/lib/module/shared/utils/bounds/helpers/link-accessor.js +2 -2
- package/lib/module/shared/utils/bounds/helpers/link-accessor.js.map +1 -1
- package/lib/module/shared/utils/bounds/helpers/resolve-bound-tag.js +6 -5
- package/lib/module/shared/utils/bounds/helpers/resolve-bound-tag.js.map +1 -1
- package/lib/module/shared/utils/bounds/helpers/style-composers.js +4 -3
- package/lib/module/shared/utils/bounds/helpers/style-composers.js.map +1 -1
- package/lib/module/shared/utils/bounds/index.js +3 -3
- package/lib/module/shared/utils/bounds/index.js.map +1 -1
- package/lib/module/shared/utils/bounds/zoom/accessor.js +49 -0
- package/lib/module/shared/utils/bounds/zoom/accessor.js.map +1 -0
- package/lib/module/shared/utils/bounds/zoom/build.js +536 -0
- package/lib/module/shared/utils/bounds/zoom/build.js.map +1 -0
- package/lib/module/shared/utils/bounds/zoom/config.js +112 -0
- package/lib/module/shared/utils/bounds/zoom/config.js.map +1 -0
- package/lib/module/shared/utils/bounds/zoom/index.js +5 -0
- package/lib/module/shared/utils/bounds/zoom/index.js.map +1 -0
- package/lib/module/shared/utils/bounds/zoom/types.js.map +1 -0
- package/lib/module/shared/utils/gesture/validate-snap-points.js +11 -5
- package/lib/module/shared/utils/gesture/validate-snap-points.js.map +1 -1
- package/lib/module/shared/utils/overlay/visibility.js +1 -7
- package/lib/module/shared/utils/overlay/visibility.js.map +1 -1
- package/lib/typescript/shared/animation/snap-to.d.ts.map +1 -1
- package/lib/typescript/shared/components/create-boundary-component/utils/build-boundary-match-key.d.ts +0 -1
- package/lib/typescript/shared/components/create-boundary-component/utils/build-boundary-match-key.d.ts.map +1 -1
- package/lib/typescript/shared/components/overlay/helpers/get-active-overlay.d.ts +1 -1
- package/lib/typescript/shared/components/overlay/index.d.ts +0 -2
- package/lib/typescript/shared/components/overlay/index.d.ts.map +1 -1
- package/lib/typescript/shared/components/overlay/variations/overlay-host.d.ts.map +1 -1
- package/lib/typescript/shared/components/scene-view.d.ts.map +1 -1
- package/lib/typescript/shared/components/screen-container/layers/backdrop.d.ts.map +1 -1
- package/lib/typescript/shared/components/screen-container/layers/content.d.ts.map +1 -1
- package/lib/typescript/shared/components/screen-container/layers/maybe-masked-navigation-container.d.ts +7 -0
- package/lib/typescript/shared/components/screen-container/layers/maybe-masked-navigation-container.d.ts.map +1 -0
- package/lib/typescript/shared/components/screen-lifecycle/hooks/use-close-transition/index.d.ts.map +1 -1
- package/lib/typescript/shared/components/screen-lifecycle/hooks/use-open-transition.d.ts.map +1 -1
- package/lib/typescript/shared/constants.d.ts +3 -0
- package/lib/typescript/shared/constants.d.ts.map +1 -1
- package/lib/typescript/shared/hooks/gestures/resolve-screen-gesture-target.d.ts +10 -0
- package/lib/typescript/shared/hooks/gestures/resolve-screen-gesture-target.d.ts.map +1 -0
- package/lib/typescript/shared/hooks/gestures/types.d.ts +4 -0
- package/lib/typescript/shared/hooks/gestures/types.d.ts.map +1 -0
- package/lib/typescript/shared/hooks/gestures/use-screen-gesture.d.ts +4 -2
- package/lib/typescript/shared/hooks/gestures/use-screen-gesture.d.ts.map +1 -1
- package/lib/typescript/shared/hooks/navigation/use-stack.d.ts +1 -2
- package/lib/typescript/shared/hooks/navigation/use-stack.d.ts.map +1 -1
- package/lib/typescript/shared/index.d.ts +16 -17
- package/lib/typescript/shared/index.d.ts.map +1 -1
- package/lib/typescript/shared/providers/gestures/handlers/use-handlers.d.ts.map +1 -1
- package/lib/typescript/shared/providers/gestures/helpers/gesture-snap-points.d.ts +18 -0
- package/lib/typescript/shared/providers/gestures/helpers/gesture-snap-points.d.ts.map +1 -0
- package/lib/typescript/shared/providers/screen/animation/animation.provider.d.ts +6 -3
- package/lib/typescript/shared/providers/screen/animation/animation.provider.d.ts.map +1 -1
- package/lib/typescript/shared/providers/screen/animation/helpers/derivations.d.ts +0 -2
- package/lib/typescript/shared/providers/screen/animation/helpers/derivations.d.ts.map +1 -1
- package/lib/typescript/shared/providers/screen/animation/helpers/pipeline.d.ts.map +1 -1
- package/lib/typescript/shared/providers/screen/animation/helpers/resolve-screen-animation-target.d.ts +11 -0
- package/lib/typescript/shared/providers/screen/animation/helpers/resolve-screen-animation-target.d.ts.map +1 -0
- package/lib/typescript/shared/providers/screen/animation/index.d.ts +1 -1
- package/lib/typescript/shared/providers/screen/animation/index.d.ts.map +1 -1
- package/lib/typescript/shared/providers/screen/animation/types.d.ts +4 -0
- package/lib/typescript/shared/providers/screen/animation/types.d.ts.map +1 -0
- package/lib/typescript/shared/providers/screen/animation/use-screen-animation.d.ts +5 -1
- package/lib/typescript/shared/providers/screen/animation/use-screen-animation.d.ts.map +1 -1
- package/lib/typescript/shared/providers/stack/direct.provider.d.ts.map +1 -1
- package/lib/typescript/shared/stores/animation.store.d.ts +4 -0
- package/lib/typescript/shared/stores/animation.store.d.ts.map +1 -1
- package/lib/typescript/shared/stores/bounds/internals/resolver.d.ts.map +1 -1
- package/lib/typescript/shared/stores/bounds/types.d.ts +2 -0
- package/lib/typescript/shared/stores/bounds/types.d.ts.map +1 -1
- package/lib/typescript/shared/types/animation.types.d.ts +26 -51
- package/lib/typescript/shared/types/animation.types.d.ts.map +1 -1
- package/lib/typescript/shared/types/bounds.types.d.ts +46 -9
- package/lib/typescript/shared/types/bounds.types.d.ts.map +1 -1
- package/lib/typescript/shared/types/index.d.ts +3 -3
- package/lib/typescript/shared/types/index.d.ts.map +1 -1
- package/lib/typescript/shared/types/overlay.types.d.ts +1 -22
- package/lib/typescript/shared/types/overlay.types.d.ts.map +1 -1
- package/lib/typescript/shared/types/screen.types.d.ts +16 -15
- package/lib/typescript/shared/types/screen.types.d.ts.map +1 -1
- package/lib/typescript/shared/utils/animation/animate-to-progress.d.ts.map +1 -1
- package/lib/typescript/shared/utils/bounds/helpers/build-bounds-options.d.ts +2 -2
- package/lib/typescript/shared/utils/bounds/helpers/build-bounds-options.d.ts.map +1 -1
- package/lib/typescript/shared/utils/bounds/helpers/compute-bounds-styles.d.ts.map +1 -1
- package/lib/typescript/shared/utils/bounds/helpers/geometry.d.ts +3 -2
- package/lib/typescript/shared/utils/bounds/helpers/geometry.d.ts.map +1 -1
- package/lib/typescript/shared/utils/bounds/helpers/interpolators.d.ts +3 -2
- package/lib/typescript/shared/utils/bounds/helpers/interpolators.d.ts.map +1 -1
- package/lib/typescript/shared/utils/bounds/helpers/link-accessor.d.ts +3 -2
- package/lib/typescript/shared/utils/bounds/helpers/link-accessor.d.ts.map +1 -1
- package/lib/typescript/shared/utils/bounds/helpers/resolve-bound-tag.d.ts +2 -1
- package/lib/typescript/shared/utils/bounds/helpers/resolve-bound-tag.d.ts.map +1 -1
- package/lib/typescript/shared/utils/bounds/helpers/style-composers.d.ts +4 -3
- package/lib/typescript/shared/utils/bounds/helpers/style-composers.d.ts.map +1 -1
- package/lib/typescript/shared/utils/bounds/index.d.ts.map +1 -1
- package/lib/typescript/shared/utils/bounds/types/options.d.ts +5 -4
- package/lib/typescript/shared/utils/bounds/types/options.d.ts.map +1 -1
- package/lib/typescript/shared/utils/bounds/zoom/accessor.d.ts +17 -0
- package/lib/typescript/shared/utils/bounds/zoom/accessor.d.ts.map +1 -0
- package/lib/typescript/shared/utils/bounds/zoom/build.d.ts +4 -0
- package/lib/typescript/shared/utils/bounds/zoom/build.d.ts.map +1 -0
- package/lib/typescript/shared/utils/bounds/zoom/config.d.ts +43 -0
- package/lib/typescript/shared/utils/bounds/zoom/config.d.ts.map +1 -0
- package/lib/typescript/shared/utils/bounds/zoom/index.d.ts +3 -0
- package/lib/typescript/shared/utils/bounds/zoom/index.d.ts.map +1 -0
- package/lib/typescript/shared/utils/bounds/zoom/types.d.ts +17 -0
- package/lib/typescript/shared/utils/bounds/zoom/types.d.ts.map +1 -0
- package/lib/typescript/shared/utils/gesture/validate-snap-points.d.ts +5 -3
- package/lib/typescript/shared/utils/gesture/validate-snap-points.d.ts.map +1 -1
- package/lib/typescript/shared/utils/overlay/visibility.d.ts +1 -4
- package/lib/typescript/shared/utils/overlay/visibility.d.ts.map +1 -1
- package/package.json +2 -2
- package/src/shared/animation/snap-to.ts +12 -1
- package/src/shared/components/create-boundary-component/utils/build-boundary-match-key.ts +2 -14
- package/src/shared/components/overlay/helpers/get-active-overlay.ts +3 -3
- package/src/shared/components/overlay/index.ts +0 -2
- package/src/shared/components/overlay/variations/overlay-host.tsx +2 -16
- package/src/shared/components/scene-view.tsx +0 -3
- package/src/shared/components/screen-container/layers/backdrop.tsx +25 -6
- package/src/shared/components/screen-container/layers/content.tsx +80 -77
- package/src/shared/components/screen-container/layers/maybe-masked-navigation-container.tsx +93 -0
- package/src/shared/components/screen-lifecycle/hooks/use-close-transition/index.ts +1 -2
- package/src/shared/components/screen-lifecycle/hooks/use-open-transition.ts +20 -6
- package/src/shared/constants.ts +6 -2
- package/src/shared/hooks/gestures/resolve-screen-gesture-target.ts +66 -0
- package/src/shared/hooks/gestures/types.ts +5 -0
- package/src/shared/hooks/gestures/use-screen-gesture.ts +10 -3
- package/src/shared/hooks/navigation/use-stack.tsx +1 -2
- package/src/shared/index.ts +14 -16
- package/src/shared/providers/gestures/handlers/use-handlers.ts +67 -24
- package/src/shared/providers/gestures/helpers/gesture-snap-points.ts +72 -0
- package/src/shared/providers/screen/animation/animation.provider.tsx +46 -10
- package/src/shared/providers/screen/animation/helpers/derivations.ts +0 -8
- package/src/shared/providers/screen/animation/helpers/pipeline.ts +26 -5
- package/src/shared/providers/screen/animation/helpers/resolve-screen-animation-target.ts +44 -0
- package/src/shared/providers/screen/animation/index.tsx +4 -1
- package/src/shared/providers/screen/animation/types.ts +5 -0
- package/src/shared/providers/screen/animation/use-screen-animation.tsx +16 -3
- package/src/shared/providers/stack/direct.provider.tsx +2 -5
- package/src/shared/providers/stack/helpers/use-processed-routes.ts +2 -2
- package/src/shared/stores/animation.store.ts +13 -1
- package/src/shared/stores/bounds/internals/resolver.ts +13 -1
- package/src/shared/stores/bounds/types.ts +2 -0
- package/src/shared/types/animation.types.ts +25 -58
- package/src/shared/types/bounds.types.ts +30 -10
- package/src/shared/types/index.ts +2 -15
- package/src/shared/types/overlay.types.ts +1 -28
- package/src/shared/types/screen.types.ts +17 -16
- package/src/shared/utils/animation/animate-to-progress.ts +7 -0
- package/src/shared/utils/bounds/helpers/build-bounds-options.ts +2 -2
- package/src/shared/utils/bounds/helpers/compute-bounds-styles.ts +34 -8
- package/src/shared/utils/bounds/helpers/geometry.ts +3 -2
- package/src/shared/utils/bounds/helpers/interpolators.ts +8 -6
- package/src/shared/utils/bounds/helpers/link-accessor.ts +10 -6
- package/src/shared/utils/bounds/helpers/resolve-bound-tag.ts +9 -6
- package/src/shared/utils/bounds/helpers/style-composers.ts +4 -3
- package/src/shared/utils/bounds/index.ts +6 -8
- package/src/shared/utils/bounds/types/options.ts +6 -4
- package/src/shared/utils/bounds/zoom/accessor.ts +69 -0
- package/src/shared/utils/bounds/zoom/build.ts +705 -0
- package/src/shared/utils/bounds/zoom/config.ts +179 -0
- package/src/shared/utils/bounds/zoom/index.ts +2 -0
- package/src/shared/utils/bounds/zoom/types.ts +22 -0
- package/src/shared/utils/gesture/validate-snap-points.ts +20 -8
- package/src/shared/utils/overlay/visibility.ts +1 -16
- package/lib/commonjs/shared/components/overlay/variations/screen-overlay.js +0 -64
- package/lib/commonjs/shared/components/overlay/variations/screen-overlay.js.map +0 -1
- package/lib/commonjs/shared/utils/bounds/helpers/math.js +0 -132
- package/lib/commonjs/shared/utils/bounds/helpers/math.js.map +0 -1
- package/lib/commonjs/shared/utils/bounds/helpers/navigation-accessor.js +0 -45
- package/lib/commonjs/shared/utils/bounds/helpers/navigation-accessor.js.map +0 -1
- package/lib/commonjs/shared/utils/bounds/sugar/navigation/helpers.js +0 -60
- package/lib/commonjs/shared/utils/bounds/sugar/navigation/helpers.js.map +0 -1
- package/lib/commonjs/shared/utils/bounds/sugar/navigation/index.js +0 -20
- package/lib/commonjs/shared/utils/bounds/sugar/navigation/index.js.map +0 -1
- package/lib/commonjs/shared/utils/bounds/sugar/navigation/types.js.map +0 -1
- package/lib/commonjs/shared/utils/bounds/sugar/navigation/zoom.js +0 -295
- package/lib/commonjs/shared/utils/bounds/sugar/navigation/zoom.js.map +0 -1
- package/lib/module/shared/components/overlay/variations/screen-overlay.js +0 -61
- package/lib/module/shared/components/overlay/variations/screen-overlay.js.map +0 -1
- package/lib/module/shared/utils/bounds/helpers/math.js +0 -115
- package/lib/module/shared/utils/bounds/helpers/math.js.map +0 -1
- package/lib/module/shared/utils/bounds/helpers/navigation-accessor.js +0 -40
- package/lib/module/shared/utils/bounds/helpers/navigation-accessor.js.map +0 -1
- package/lib/module/shared/utils/bounds/sugar/navigation/helpers.js +0 -54
- package/lib/module/shared/utils/bounds/sugar/navigation/helpers.js.map +0 -1
- package/lib/module/shared/utils/bounds/sugar/navigation/index.js +0 -15
- package/lib/module/shared/utils/bounds/sugar/navigation/index.js.map +0 -1
- package/lib/module/shared/utils/bounds/sugar/navigation/types.js.map +0 -1
- package/lib/module/shared/utils/bounds/sugar/navigation/zoom.js +0 -290
- package/lib/module/shared/utils/bounds/sugar/navigation/zoom.js.map +0 -1
- package/lib/typescript/shared/components/overlay/variations/screen-overlay.d.ts +0 -10
- package/lib/typescript/shared/components/overlay/variations/screen-overlay.d.ts.map +0 -1
- package/lib/typescript/shared/utils/bounds/helpers/math.d.ts +0 -38
- package/lib/typescript/shared/utils/bounds/helpers/math.d.ts.map +0 -1
- package/lib/typescript/shared/utils/bounds/helpers/navigation-accessor.d.ts +0 -16
- package/lib/typescript/shared/utils/bounds/helpers/navigation-accessor.d.ts.map +0 -1
- package/lib/typescript/shared/utils/bounds/sugar/navigation/helpers.d.ts +0 -17
- package/lib/typescript/shared/utils/bounds/sugar/navigation/helpers.d.ts.map +0 -1
- package/lib/typescript/shared/utils/bounds/sugar/navigation/index.d.ts +0 -3
- package/lib/typescript/shared/utils/bounds/sugar/navigation/index.d.ts.map +0 -1
- package/lib/typescript/shared/utils/bounds/sugar/navigation/types.d.ts +0 -18
- package/lib/typescript/shared/utils/bounds/sugar/navigation/types.d.ts.map +0 -1
- package/lib/typescript/shared/utils/bounds/sugar/navigation/zoom.d.ts +0 -4
- package/lib/typescript/shared/utils/bounds/sugar/navigation/zoom.d.ts.map +0 -1
- package/src/shared/components/overlay/variations/screen-overlay.tsx +0 -68
- package/src/shared/utils/bounds/helpers/math.ts +0 -161
- package/src/shared/utils/bounds/helpers/navigation-accessor.ts +0 -61
- package/src/shared/utils/bounds/sugar/navigation/helpers.ts +0 -74
- package/src/shared/utils/bounds/sugar/navigation/index.ts +0 -14
- package/src/shared/utils/bounds/sugar/navigation/types.ts +0 -26
- package/src/shared/utils/bounds/sugar/navigation/zoom.ts +0 -348
- /package/lib/commonjs/shared/utils/bounds/{sugar/navigation → zoom}/types.js +0 -0
- /package/lib/module/shared/utils/bounds/{sugar/navigation → zoom}/types.js +0 -0
|
@@ -1,295 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.buildZoomNavigationStyles = void 0;
|
|
7
|
-
var _reactNativeReanimated = require("react-native-reanimated");
|
|
8
|
-
var _constants = require("../../../../constants");
|
|
9
|
-
var _bounds = require("../../../../stores/bounds");
|
|
10
|
-
var _interpolate = require("../../helpers/interpolate");
|
|
11
|
-
var _math = require("../../helpers/math");
|
|
12
|
-
var _helpers = require("./helpers");
|
|
13
|
-
const DRAG_RESISTANCE = 0.4;
|
|
14
|
-
const DIRECTIONAL_DRAG_SCALE_OUTPUT = [1, 0.25];
|
|
15
|
-
const IDENTITY_DRAG_SCALE_OUTPUT = [1, 1];
|
|
16
|
-
const getZoomContentTarget = ({
|
|
17
|
-
explicitTarget,
|
|
18
|
-
resolvedTag,
|
|
19
|
-
currentRouteKey,
|
|
20
|
-
previousRouteKey,
|
|
21
|
-
nextRouteKey,
|
|
22
|
-
entering,
|
|
23
|
-
screenLayout,
|
|
24
|
-
anchor
|
|
25
|
-
}) => {
|
|
26
|
-
"worklet";
|
|
27
|
-
|
|
28
|
-
if (explicitTarget !== undefined) return explicitTarget;
|
|
29
|
-
const resolvedPair = _bounds.BoundStore.resolveTransitionPair(resolvedTag, {
|
|
30
|
-
currentScreenKey: currentRouteKey,
|
|
31
|
-
previousScreenKey: previousRouteKey,
|
|
32
|
-
nextScreenKey: nextRouteKey,
|
|
33
|
-
entering
|
|
34
|
-
});
|
|
35
|
-
const sourceBounds = resolvedPair.sourceBounds;
|
|
36
|
-
const screenWidth = screenLayout.width;
|
|
37
|
-
if (!sourceBounds || sourceBounds.width <= 0 || screenWidth <= 0) {
|
|
38
|
-
return "fullscreen";
|
|
39
|
-
}
|
|
40
|
-
const height = sourceBounds.height / sourceBounds.width * screenWidth;
|
|
41
|
-
let horizontalAnchor;
|
|
42
|
-
switch (anchor) {
|
|
43
|
-
case "topLeading":
|
|
44
|
-
case "leading":
|
|
45
|
-
case "bottomLeading":
|
|
46
|
-
horizontalAnchor = "leading";
|
|
47
|
-
break;
|
|
48
|
-
case "topTrailing":
|
|
49
|
-
case "trailing":
|
|
50
|
-
case "bottomTrailing":
|
|
51
|
-
horizontalAnchor = "trailing";
|
|
52
|
-
break;
|
|
53
|
-
default:
|
|
54
|
-
horizontalAnchor = "center";
|
|
55
|
-
break;
|
|
56
|
-
}
|
|
57
|
-
let verticalAnchor;
|
|
58
|
-
switch (anchor) {
|
|
59
|
-
case "topLeading":
|
|
60
|
-
case "top":
|
|
61
|
-
case "topTrailing":
|
|
62
|
-
verticalAnchor = "top";
|
|
63
|
-
break;
|
|
64
|
-
case "bottomLeading":
|
|
65
|
-
case "bottom":
|
|
66
|
-
case "bottomTrailing":
|
|
67
|
-
verticalAnchor = "bottom";
|
|
68
|
-
break;
|
|
69
|
-
default:
|
|
70
|
-
verticalAnchor = "center";
|
|
71
|
-
break;
|
|
72
|
-
}
|
|
73
|
-
const x = horizontalAnchor === "leading" ? 0 : horizontalAnchor === "trailing" ? screenLayout.width - screenWidth : (screenLayout.width - screenWidth) / 2;
|
|
74
|
-
const y = verticalAnchor === "top" ? 0 : verticalAnchor === "bottom" ? screenLayout.height - height : (screenLayout.height - height) / 2;
|
|
75
|
-
return {
|
|
76
|
-
x,
|
|
77
|
-
y,
|
|
78
|
-
pageX: x,
|
|
79
|
-
pageY: y,
|
|
80
|
-
width: screenWidth,
|
|
81
|
-
height
|
|
82
|
-
};
|
|
83
|
-
};
|
|
84
|
-
const buildZoomNavigationStyles = ({
|
|
85
|
-
id,
|
|
86
|
-
group,
|
|
87
|
-
navigationOptions,
|
|
88
|
-
props,
|
|
89
|
-
resolveTag,
|
|
90
|
-
computeRaw
|
|
91
|
-
}) => {
|
|
92
|
-
"worklet";
|
|
93
|
-
|
|
94
|
-
const focused = props.focused;
|
|
95
|
-
const progress = props.progress;
|
|
96
|
-
const currentRouteKey = props.current?.route.key;
|
|
97
|
-
const previousRouteKey = props.previous?.route.key;
|
|
98
|
-
const nextRouteKey = props.next?.route.key;
|
|
99
|
-
const entering = !props.next;
|
|
100
|
-
const screenLayout = props.layouts.screen;
|
|
101
|
-
const normX = props.active.gesture.normX;
|
|
102
|
-
const normY = props.active.gesture.normY;
|
|
103
|
-
const initialDirection = props.active.gesture.direction;
|
|
104
|
-
const xScaleOutput = initialDirection === "horizontal" ? DIRECTIONAL_DRAG_SCALE_OUTPUT : IDENTITY_DRAG_SCALE_OUTPUT;
|
|
105
|
-
const yScaleOutput = initialDirection === "vertical" ? DIRECTIONAL_DRAG_SCALE_OUTPUT : IDENTITY_DRAG_SCALE_OUTPUT;
|
|
106
|
-
const dragX = (0, _math.normalizedToTranslation)({
|
|
107
|
-
normalized: normX,
|
|
108
|
-
dimension: screenLayout.width,
|
|
109
|
-
resistance: DRAG_RESISTANCE
|
|
110
|
-
});
|
|
111
|
-
const dragY = (0, _math.normalizedToTranslation)({
|
|
112
|
-
normalized: normY,
|
|
113
|
-
dimension: screenLayout.height,
|
|
114
|
-
resistance: DRAG_RESISTANCE
|
|
115
|
-
});
|
|
116
|
-
const dragXScale = (0, _math.normalizedToScale)({
|
|
117
|
-
normalized: normX,
|
|
118
|
-
outputRange: xScaleOutput,
|
|
119
|
-
exponent: 2
|
|
120
|
-
});
|
|
121
|
-
const dragYScale = (0, _math.normalizedToScale)({
|
|
122
|
-
normalized: normY,
|
|
123
|
-
outputRange: yScaleOutput,
|
|
124
|
-
exponent: 2
|
|
125
|
-
});
|
|
126
|
-
const dragScale = (0, _math.combineScales)(dragXScale, dragYScale);
|
|
127
|
-
const resolvedConfig = (0, _helpers.resolveNavigationConfig)({
|
|
128
|
-
id,
|
|
129
|
-
group,
|
|
130
|
-
navigationOptions,
|
|
131
|
-
currentRouteKey,
|
|
132
|
-
resolveTag,
|
|
133
|
-
defaultAnchor: "top"
|
|
134
|
-
});
|
|
135
|
-
if (!resolvedConfig) return _constants.NO_STYLES;
|
|
136
|
-
const {
|
|
137
|
-
resolvedTag,
|
|
138
|
-
sharedOptions,
|
|
139
|
-
explicitTarget
|
|
140
|
-
} = resolvedConfig;
|
|
141
|
-
if (focused) {
|
|
142
|
-
const contentTarget = getZoomContentTarget({
|
|
143
|
-
explicitTarget,
|
|
144
|
-
resolvedTag,
|
|
145
|
-
currentRouteKey,
|
|
146
|
-
previousRouteKey,
|
|
147
|
-
nextRouteKey,
|
|
148
|
-
entering,
|
|
149
|
-
screenLayout,
|
|
150
|
-
anchor: sharedOptions.anchor
|
|
151
|
-
});
|
|
152
|
-
const contentRaw = computeRaw({
|
|
153
|
-
...sharedOptions,
|
|
154
|
-
method: "content",
|
|
155
|
-
target: contentTarget
|
|
156
|
-
});
|
|
157
|
-
const maskRaw = computeRaw({
|
|
158
|
-
...sharedOptions,
|
|
159
|
-
method: "size",
|
|
160
|
-
space: "absolute",
|
|
161
|
-
target: "fullscreen"
|
|
162
|
-
});
|
|
163
|
-
const focusedFade = props.active?.closing ? (0, _reactNativeReanimated.interpolate)(progress, [0.6, 1], [0, 1], "clamp") : (0, _reactNativeReanimated.interpolate)(progress, [0, 0.5], [0, 1], "clamp");
|
|
164
|
-
const maskWidth = Math.max(1, (0, _helpers.toNumber)(maskRaw.width));
|
|
165
|
-
const maskHeight = Math.max(1, (0, _helpers.toNumber)(maskRaw.height));
|
|
166
|
-
const contentTranslateX = (0, _helpers.toNumber)(contentRaw.translateX) + dragX;
|
|
167
|
-
const contentTranslateY = (0, _helpers.toNumber)(contentRaw.translateY) + dragY;
|
|
168
|
-
const contentScale = (0, _helpers.toNumber)(contentRaw.scale, 1) * dragScale;
|
|
169
|
-
const maskTranslateX = (0, _helpers.toNumber)(maskRaw.translateX) + dragX;
|
|
170
|
-
const maskTranslateY = (0, _helpers.toNumber)(maskRaw.translateY) + dragY;
|
|
171
|
-
return {
|
|
172
|
-
[_constants.NAVIGATION_CONTAINER_STYLE_ID]: {
|
|
173
|
-
style: {
|
|
174
|
-
opacity: focusedFade,
|
|
175
|
-
transform: [{
|
|
176
|
-
translateX: contentTranslateX
|
|
177
|
-
}, {
|
|
178
|
-
translateY: contentTranslateY
|
|
179
|
-
}, {
|
|
180
|
-
scale: contentScale
|
|
181
|
-
}]
|
|
182
|
-
}
|
|
183
|
-
},
|
|
184
|
-
[_constants.NAVIGATION_MASK_STYLE_ID]: {
|
|
185
|
-
style: {
|
|
186
|
-
width: maskWidth,
|
|
187
|
-
height: maskHeight,
|
|
188
|
-
transform: [{
|
|
189
|
-
translateX: maskTranslateX
|
|
190
|
-
}, {
|
|
191
|
-
translateY: maskTranslateY
|
|
192
|
-
}, {
|
|
193
|
-
scale: dragScale
|
|
194
|
-
}],
|
|
195
|
-
borderRadius: 12
|
|
196
|
-
}
|
|
197
|
-
},
|
|
198
|
-
// Signal the destination boundary to stay visible during the transition.
|
|
199
|
-
// Without this, useAssociatedStyles enters "waiting-first-style" mode
|
|
200
|
-
// (opacity: 0) because it detects previous-screen evidence but never
|
|
201
|
-
// receives a resolved style for this tag.
|
|
202
|
-
[resolvedTag]: {
|
|
203
|
-
style: {
|
|
204
|
-
opacity: 1
|
|
205
|
-
}
|
|
206
|
-
}
|
|
207
|
-
};
|
|
208
|
-
}
|
|
209
|
-
const unfocusedFade = props.active?.closing ? (0, _reactNativeReanimated.interpolate)(progress, [1.6, 2], [1, 0], "clamp") : (0, _reactNativeReanimated.interpolate)(progress, [1, 1.5], [1, 0], "clamp");
|
|
210
|
-
const unfocusedScale = (0, _interpolate.interpolateClamped)(progress, [1, 2], [1, 0.95]);
|
|
211
|
-
const isUnfocusedIdle = props.active.settled === 1;
|
|
212
|
-
const elementTarget = sharedOptions.scaleMode === "match" ? "fullscreen" : getZoomContentTarget({
|
|
213
|
-
explicitTarget,
|
|
214
|
-
resolvedTag,
|
|
215
|
-
currentRouteKey,
|
|
216
|
-
previousRouteKey,
|
|
217
|
-
nextRouteKey,
|
|
218
|
-
entering,
|
|
219
|
-
screenLayout,
|
|
220
|
-
anchor: sharedOptions.anchor
|
|
221
|
-
});
|
|
222
|
-
const elementRaw = computeRaw({
|
|
223
|
-
...sharedOptions,
|
|
224
|
-
method: "transform",
|
|
225
|
-
space: "relative",
|
|
226
|
-
target: elementTarget
|
|
227
|
-
});
|
|
228
|
-
|
|
229
|
-
// Keep compensation tied to the element target's center. In `scaleMode: "match"`
|
|
230
|
-
// this target is fullscreen, so the center offset should resolve to zero.
|
|
231
|
-
const elementCenterY = typeof elementTarget === "object" ? elementTarget.pageY + elementTarget.height / 2 : screenLayout.height / 2;
|
|
232
|
-
const scaleShiftY = (0, _math.computeCenterScaleShift)({
|
|
233
|
-
center: elementCenterY,
|
|
234
|
-
containerCenter: screenLayout.height / 2,
|
|
235
|
-
scale: dragScale
|
|
236
|
-
});
|
|
237
|
-
const compensatedGestureX = (0, _math.composeCompensatedTranslation)({
|
|
238
|
-
gesture: dragX,
|
|
239
|
-
parentScale: unfocusedScale,
|
|
240
|
-
epsilon: _constants.EPSILON
|
|
241
|
-
});
|
|
242
|
-
// dragY is measured in screen space and must be unscaled by the parent
|
|
243
|
-
// content shrink, while scaleShiftY is already in the parent's local space.
|
|
244
|
-
const compensatedGestureY = (0, _math.composeCompensatedTranslation)({
|
|
245
|
-
gesture: dragY,
|
|
246
|
-
parentScale: unfocusedScale,
|
|
247
|
-
centerShift: scaleShiftY,
|
|
248
|
-
epsilon: _constants.EPSILON
|
|
249
|
-
});
|
|
250
|
-
const elementTranslateX = (0, _helpers.toNumber)(elementRaw.translateX) + compensatedGestureX;
|
|
251
|
-
const elementTranslateY = (0, _helpers.toNumber)(elementRaw.translateY) + compensatedGestureY;
|
|
252
|
-
const elementScaleX = (0, _helpers.toNumber)(elementRaw.scaleX, 1) * dragScale;
|
|
253
|
-
const elementScaleY = (0, _helpers.toNumber)(elementRaw.scaleY, 1) * dragScale;
|
|
254
|
-
const resolvedElementStyle = isUnfocusedIdle ? {
|
|
255
|
-
transform: [{
|
|
256
|
-
translateX: 0
|
|
257
|
-
}, {
|
|
258
|
-
translateY: 0
|
|
259
|
-
}, {
|
|
260
|
-
scaleX: 1
|
|
261
|
-
}, {
|
|
262
|
-
scaleY: 1
|
|
263
|
-
}],
|
|
264
|
-
opacity: 0,
|
|
265
|
-
zIndex: 0,
|
|
266
|
-
elevation: 0
|
|
267
|
-
} : {
|
|
268
|
-
transform: [{
|
|
269
|
-
translateX: elementTranslateX
|
|
270
|
-
}, {
|
|
271
|
-
translateY: elementTranslateY
|
|
272
|
-
}, {
|
|
273
|
-
scaleX: elementScaleX
|
|
274
|
-
}, {
|
|
275
|
-
scaleY: elementScaleY
|
|
276
|
-
}],
|
|
277
|
-
opacity: unfocusedFade,
|
|
278
|
-
zIndex: 9999,
|
|
279
|
-
elevation: 9999
|
|
280
|
-
};
|
|
281
|
-
return {
|
|
282
|
-
content: {
|
|
283
|
-
style: {
|
|
284
|
-
transform: [{
|
|
285
|
-
scale: unfocusedScale
|
|
286
|
-
}]
|
|
287
|
-
}
|
|
288
|
-
},
|
|
289
|
-
[resolvedTag]: {
|
|
290
|
-
style: resolvedElementStyle
|
|
291
|
-
}
|
|
292
|
-
};
|
|
293
|
-
};
|
|
294
|
-
exports.buildZoomNavigationStyles = buildZoomNavigationStyles;
|
|
295
|
-
//# sourceMappingURL=zoom.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"names":["_reactNativeReanimated","require","_constants","_bounds","_interpolate","_math","_helpers","DRAG_RESISTANCE","DIRECTIONAL_DRAG_SCALE_OUTPUT","IDENTITY_DRAG_SCALE_OUTPUT","getZoomContentTarget","explicitTarget","resolvedTag","currentRouteKey","previousRouteKey","nextRouteKey","entering","screenLayout","anchor","undefined","resolvedPair","BoundStore","resolveTransitionPair","currentScreenKey","previousScreenKey","nextScreenKey","sourceBounds","screenWidth","width","height","horizontalAnchor","verticalAnchor","x","y","pageX","pageY","buildZoomNavigationStyles","id","group","navigationOptions","props","resolveTag","computeRaw","focused","progress","current","route","key","previous","next","layouts","screen","normX","active","gesture","normY","initialDirection","direction","xScaleOutput","yScaleOutput","dragX","normalizedToTranslation","normalized","dimension","resistance","dragY","dragXScale","normalizedToScale","outputRange","exponent","dragYScale","dragScale","combineScales","resolvedConfig","resolveNavigationConfig","defaultAnchor","NO_STYLES","sharedOptions","contentTarget","contentRaw","method","target","maskRaw","space","focusedFade","closing","interpolate","maskWidth","Math","max","toNumber","maskHeight","contentTranslateX","translateX","contentTranslateY","translateY","contentScale","scale","maskTranslateX","maskTranslateY","NAVIGATION_CONTAINER_STYLE_ID","style","opacity","transform","NAVIGATION_MASK_STYLE_ID","borderRadius","unfocusedFade","unfocusedScale","interpolateClamped","isUnfocusedIdle","settled","elementTarget","scaleMode","elementRaw","elementCenterY","scaleShiftY","computeCenterScaleShift","center","containerCenter","compensatedGestureX","composeCompensatedTranslation","parentScale","epsilon","EPSILON","compensatedGestureY","centerShift","elementTranslateX","elementTranslateY","elementScaleX","scaleX","elementScaleY","scaleY","resolvedElementStyle","zIndex","elevation","content","exports"],"sourceRoot":"../../../../../../../src","sources":["shared/utils/bounds/sugar/navigation/zoom.ts"],"mappings":";;;;;;AAAA,IAAAA,sBAAA,GAAAC,OAAA;AACA,IAAAC,UAAA,GAAAD,OAAA;AAMA,IAAAE,OAAA,GAAAF,OAAA;AAGA,IAAAG,YAAA,GAAAH,OAAA;AACA,IAAAI,KAAA,GAAAJ,OAAA;AAQA,IAAAK,QAAA,GAAAL,OAAA;AAGA,MAAMM,eAAe,GAAG,GAAG;AAC3B,MAAMC,6BAA6B,GAAG,CAAC,CAAC,EAAE,IAAI,CAAU;AACxD,MAAMC,0BAA0B,GAAG,CAAC,CAAC,EAAE,CAAC,CAAU;AAElD,MAAMC,oBAAoB,GAAGA,CAAC;EAC7BC,cAAc;EACdC,WAAW;EACXC,eAAe;EACfC,gBAAgB;EAChBC,YAAY;EACZC,QAAQ;EACRC,YAAY;EACZC;AAUD,CAAC,KAAK;EACL,SAAS;;EACT,IAAIP,cAAc,KAAKQ,SAAS,EAAE,OAAOR,cAAc;EAEvD,MAAMS,YAAY,GAAGC,kBAAU,CAACC,qBAAqB,CAACV,WAAW,EAAE;IAClEW,gBAAgB,EAAEV,eAAe;IACjCW,iBAAiB,EAAEV,gBAAgB;IACnCW,aAAa,EAAEV,YAAY;IAC3BC;EACD,CAAC,CAAC;EACF,MAAMU,YAAY,GAAGN,YAAY,CAACM,YAAY;EAC9C,MAAMC,WAAW,GAAGV,YAAY,CAACW,KAAK;EAEtC,IAAI,CAACF,YAAY,IAAIA,YAAY,CAACE,KAAK,IAAI,CAAC,IAAID,WA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,GACA;IACA/B,SAAS,EAAE,CACV;MAAEV,UAAU,EAAEiC;IAAkB,CAAC,EACjC;MAAE/B,UAAU,EAAEgC;IAAkB,CAAC,EACjC;MAAEE,MAAM,EAAED;IAAc,CAAC,EACzB;MAAEG,MAAM,EAAED;IAAc,CAAC,CACzB;IACD5B,OAAO,EAAEI,aAAa;IACtB2B,MAAM,EAAE,IAAI;IACZC,SAAS,EAAE;EACZ,CAAC;EAEH,OAAO;IACNC,OAAO,EAAE;MACRlC,KAAK,EAAE;QACNE,SAAS,EAAE,CAAC;UAAEN,KAAK,EAAEU;QAAe,CAAC;MACtC;IACD,CAAC;IACD,CAAC/F,WAAW,GAAG;MACdyF,KAAK,EAAE+B;IACR;EACD,CAAC;AACF,CAAC;AAACI,OAAA,CAAApG,yBAAA,GAAAA,yBAAA","ignoreList":[]}
|
|
@@ -1,61 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
import { useMemo } from "react";
|
|
4
|
-
import { snapDescriptorToIndex } from "../../../animation/snap-to";
|
|
5
|
-
import { useOptimisticFocusedIndex } from "../../../hooks/navigation/use-optimistic-focused-index";
|
|
6
|
-
import { useStack } from "../../../hooks/navigation/use-stack";
|
|
7
|
-
import { useDescriptors } from "../../../providers/screen/descriptors";
|
|
8
|
-
import { isScreenOverlayVisible } from "../../../utils/overlay/visibility";
|
|
9
|
-
import { OverlayHost } from "./overlay-host";
|
|
10
|
-
|
|
11
|
-
/**
|
|
12
|
-
* Screen overlay component that renders per-screen.
|
|
13
|
-
* Gets current descriptor from keys context.
|
|
14
|
-
*
|
|
15
|
-
* @deprecated Screen overlays are deprecated. For per-screen overlays, render an
|
|
16
|
-
* absolute-positioned view directly in your screen component and use `useScreenAnimation()`
|
|
17
|
-
* to access animation values. This component will be removed in a future version.
|
|
18
|
-
*/
|
|
19
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
20
|
-
export function ScreenOverlay() {
|
|
21
|
-
const {
|
|
22
|
-
current
|
|
23
|
-
} = useDescriptors();
|
|
24
|
-
const {
|
|
25
|
-
flags,
|
|
26
|
-
routes,
|
|
27
|
-
optimisticFocusedIndex,
|
|
28
|
-
routeKeys
|
|
29
|
-
} = useStack();
|
|
30
|
-
const focusedIndex = useOptimisticFocusedIndex(optimisticFocusedIndex, routeKeys.length);
|
|
31
|
-
const options = current.options;
|
|
32
|
-
const scene = useMemo(() => ({
|
|
33
|
-
descriptor: current,
|
|
34
|
-
route: current.route
|
|
35
|
-
}), [current]);
|
|
36
|
-
const overlayScreenState = useMemo(() => ({
|
|
37
|
-
index: routeKeys.indexOf(current.route.key),
|
|
38
|
-
options: current.options,
|
|
39
|
-
routes,
|
|
40
|
-
focusedRoute: routes[focusedIndex] ?? current.route,
|
|
41
|
-
focusedIndex,
|
|
42
|
-
meta: current.options?.meta,
|
|
43
|
-
navigation: current.navigation,
|
|
44
|
-
snapTo: index => {
|
|
45
|
-
snapDescriptorToIndex(current, index);
|
|
46
|
-
}
|
|
47
|
-
}), [current, routeKeys, routes, focusedIndex]);
|
|
48
|
-
|
|
49
|
-
// Skip screens without enableTransitions (native-stack only)
|
|
50
|
-
if (!flags.TRANSITIONS_ALWAYS_ON && !options.enableTransitions) {
|
|
51
|
-
return null;
|
|
52
|
-
}
|
|
53
|
-
if (!isScreenOverlayVisible(options)) {
|
|
54
|
-
return null;
|
|
55
|
-
}
|
|
56
|
-
return /*#__PURE__*/_jsx(OverlayHost, {
|
|
57
|
-
scene: scene,
|
|
58
|
-
overlayScreenState: overlayScreenState
|
|
59
|
-
});
|
|
60
|
-
}
|
|
61
|
-
//# sourceMappingURL=screen-overlay.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"names":["useMemo","snapDescriptorToIndex","useOptimisticFocusedIndex","useStack","useDescriptors","isScreenOverlayVisible","OverlayHost","jsx","_jsx","ScreenOverlay","current","flags","routes","optimisticFocusedIndex","routeKeys","focusedIndex","length","options","scene","descriptor","route","overlayScreenState","index","indexOf","key","focusedRoute","meta","navigation","snapTo","TRANSITIONS_ALWAYS_ON","enableTransitions"],"sourceRoot":"../../../../../../src","sources":["shared/components/overlay/variations/screen-overlay.tsx"],"mappings":";;AAAA,SAASA,OAAO,QAAQ,OAAO;AAC/B,SAASC,qBAAqB,QAAQ,4BAA4B;AAClE,SAASC,yBAAyB,QAAQ,wDAAwD;AAClG,SAGCC,QAAQ,QACF,qCAAqC;AAC5C,SAASC,cAAc,QAAQ,uCAAuC;AAEtE,SAASC,sBAAsB,QAAQ,mCAAmC;AAC1E,SAASC,WAAW,QAAQ,gBAAgB;;AAE5C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAPA,SAAAC,GAAA,IAAAC,IAAA;AAQA,OAAO,SAASC,aAAaA,CAAA,EAAG;EAC/B,MAAM;IAAEC;EAAQ,CAAC,GAAGN,cAAc,CAAkB,CAAC;EACrD,MAAM;IAAEO,KAAK;IAAEC,MAAM;IAAEC,sBAAsB;IAAEC;EAAU,CAAC,GAAGX,QAAQ,CAAC,CAAC;EACvE,MAAMY,YAAY,GAAGb,yBAAyB,CAC7CW,sBAAsB,EACtBC,SAAS,CAACE,MACX,CAAC;EAED,MAAMC,OAAO,GAAGP,OAAO,CAACO,OAAO;EAE/B,MAAMC,KAAK,GAAGlB,OAAO,CACpB,OAAO;IACNmB,UAAU,EAAET,OAAO;IACnBU,KAAK,EAAEV,OAAO,CAACU;EAChB,CAAC,CAAC,EACF,CAACV,OAAO,CACT,CAAC;EAED,MAAMW,kBAAkB,GAAGrB,OAAO,CAGjC,OAAO;IACNsB,KAAK,EAAER,SAAS,CAACS,OAAO,CAACb,OAAO,CAACU,KAAK,CAACI,GAAG,CAAC;IAC3CP,OAAO,EAAEP,OAAO,CAACO,OAAO;IACxBL,MAAM;IACNa,YAAY,EAAEb,MAAM,CAACG,YAAY,CAAC,IAAIL,OAAO,CAACU,KAAK;IACnDL,YAAY;IACZW,IAAI,EAAEhB,OAAO,CAACO,OAAO,EAAES,IAAI;IAC3BC,UAAU,EAAEjB,OAAO,CAACiB,UAAU;IAC9BC,MAAM,EAAGN,KAAa,IAAK;MAC1BrB,qBAAqB,CAACS,OAAO,EAAEY,KAAK,CAAC;IACtC;EACD,CAAC,CAAC,EACF,CAACZ,OAAO,EAAEI,SAAS,EAAEF,MAAM,EAAEG,YAAY,CAC1C,CAAC;;EAED;EACA,IAAI,CAACJ,KAAK,CAACkB,qBAAqB,IAAI,CAACZ,OAAO,CAACa,iBAAiB,EAAE;IAC/D,OAAO,IAAI;EACZ;EAEA,IAAI,CAACzB,sBAAsB,CAACY,OAAO,CAAC,EAAE;IACrC,OAAO,IAAI;EACZ;EAEA,oBAAOT,IAAA,CAACF,WAAW;IAACY,KAAK,EAAEA,KAAM;IAACG,kBAAkB,EAAEA;EAAmB,CAAE,CAAC;AAC7E","ignoreList":[]}
|
|
@@ -1,115 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
export const clamp = (value, min, max) => {
|
|
4
|
-
"worklet";
|
|
5
|
-
|
|
6
|
-
const lower = min < max ? min : max;
|
|
7
|
-
const upper = max > min ? max : min;
|
|
8
|
-
if (value < lower) return lower;
|
|
9
|
-
if (value > upper) return upper;
|
|
10
|
-
return value;
|
|
11
|
-
};
|
|
12
|
-
export const clamp01 = value => {
|
|
13
|
-
"worklet";
|
|
14
|
-
|
|
15
|
-
return clamp(value, 0, 1);
|
|
16
|
-
};
|
|
17
|
-
export const lerp = (from, to, t) => {
|
|
18
|
-
"worklet";
|
|
19
|
-
|
|
20
|
-
return from + (to - from) * t;
|
|
21
|
-
};
|
|
22
|
-
export const safeDivide = (numerator, denominator, fallback = 0) => {
|
|
23
|
-
"worklet";
|
|
24
|
-
|
|
25
|
-
if (denominator === 0) return fallback;
|
|
26
|
-
return numerator / denominator;
|
|
27
|
-
};
|
|
28
|
-
export const inverseLerp = (value, inMin, inMax) => {
|
|
29
|
-
"worklet";
|
|
30
|
-
|
|
31
|
-
return safeDivide(value - inMin, inMax - inMin, 0);
|
|
32
|
-
};
|
|
33
|
-
export const mapRangeClamped = (value, inMin, inMax, outMin, outMax) => {
|
|
34
|
-
"worklet";
|
|
35
|
-
|
|
36
|
-
const t = clamp01(inverseLerp(value, inMin, inMax));
|
|
37
|
-
return lerp(outMin, outMax, t);
|
|
38
|
-
};
|
|
39
|
-
export const applyPowerCurve = (value, exponent) => {
|
|
40
|
-
"worklet";
|
|
41
|
-
|
|
42
|
-
const safeExponent = exponent > 0 ? exponent : 1;
|
|
43
|
-
const magnitude = Math.abs(value) ** safeExponent;
|
|
44
|
-
return value < 0 ? -magnitude : magnitude;
|
|
45
|
-
};
|
|
46
|
-
export const normalizedToTranslation = ({
|
|
47
|
-
normalized,
|
|
48
|
-
dimension,
|
|
49
|
-
resistance
|
|
50
|
-
}) => {
|
|
51
|
-
"worklet";
|
|
52
|
-
|
|
53
|
-
const distance = Math.max(0, dimension) * resistance;
|
|
54
|
-
return mapRangeClamped(normalized, -1, 1, -distance, distance);
|
|
55
|
-
};
|
|
56
|
-
export const normalizedToScale = ({
|
|
57
|
-
normalized,
|
|
58
|
-
outputRange,
|
|
59
|
-
exponent = 1,
|
|
60
|
-
positiveOnly = true
|
|
61
|
-
}) => {
|
|
62
|
-
"worklet";
|
|
63
|
-
|
|
64
|
-
const [outputStart, outputEnd] = outputRange;
|
|
65
|
-
const raw = positiveOnly ? mapRangeClamped(normalized, 0, 1, outputStart, outputEnd) : mapRangeClamped(normalized, -1, 1, outputStart, outputEnd);
|
|
66
|
-
return applyPowerCurve(raw, exponent);
|
|
67
|
-
};
|
|
68
|
-
export const combineScales = (scaleX, scaleY, mode = "multiply") => {
|
|
69
|
-
"worklet";
|
|
70
|
-
|
|
71
|
-
switch (mode) {
|
|
72
|
-
case "average":
|
|
73
|
-
return (scaleX + scaleY) / 2;
|
|
74
|
-
case "max":
|
|
75
|
-
return Math.max(scaleX, scaleY);
|
|
76
|
-
case "min":
|
|
77
|
-
return Math.min(scaleX, scaleY);
|
|
78
|
-
default:
|
|
79
|
-
return scaleX * scaleY;
|
|
80
|
-
}
|
|
81
|
-
};
|
|
82
|
-
export const computeCenterScaleShift = ({
|
|
83
|
-
center,
|
|
84
|
-
containerCenter,
|
|
85
|
-
scale
|
|
86
|
-
}) => {
|
|
87
|
-
"worklet";
|
|
88
|
-
|
|
89
|
-
return (center - containerCenter) * (scale - 1);
|
|
90
|
-
};
|
|
91
|
-
export const compensateTranslationForParentScale = ({
|
|
92
|
-
translation,
|
|
93
|
-
parentScale,
|
|
94
|
-
epsilon
|
|
95
|
-
}) => {
|
|
96
|
-
"worklet";
|
|
97
|
-
|
|
98
|
-
const safeParentScale = Math.max(parentScale, epsilon);
|
|
99
|
-
return safeDivide(translation, safeParentScale, translation);
|
|
100
|
-
};
|
|
101
|
-
export const composeCompensatedTranslation = ({
|
|
102
|
-
gesture,
|
|
103
|
-
parentScale,
|
|
104
|
-
centerShift = 0,
|
|
105
|
-
epsilon
|
|
106
|
-
}) => {
|
|
107
|
-
"worklet";
|
|
108
|
-
|
|
109
|
-
return compensateTranslationForParentScale({
|
|
110
|
-
translation: gesture,
|
|
111
|
-
parentScale,
|
|
112
|
-
epsilon
|
|
113
|
-
}) + centerShift;
|
|
114
|
-
};
|
|
115
|
-
//# sourceMappingURL=math.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"names":["clamp","value","min","max","lower","upper","clamp01","lerp","from","to","t","safeDivide","numerator","denominator","fallback","inverseLerp","inMin","inMax","mapRangeClamped","outMin","outMax","applyPowerCurve","exponent","safeExponent","magnitude","Math","abs","normalizedToTranslation","normalized","dimension","resistance","distance","normalizedToScale","outputRange","positiveOnly","outputStart","outputEnd","raw","combineScales","scaleX","scaleY","mode","computeCenterScaleShift","center","containerCenter","scale","compensateTranslationForParentScale","translation","parentScale","epsilon","safeParentScale","composeCompensatedTranslation","gesture","centerShift"],"sourceRoot":"../../../../../../src","sources":["shared/utils/bounds/helpers/math.ts"],"mappings":";;AAEA,OAAO,MAA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C,IAAuB,GAAG,UAAU,KACxB;EACZ,SAAS;;EAET,QAAQA,IAAI;IACX,KAAK,SAAS;MACb,OAAO,CAACF,MAAM,GAAGC,MAAM,IAAI,CAAC;IAC7B,KAAK,KAAK;MACT,OAAOf,IAAI,CAACtB,GAAG,CAACoC,MAAM,EAAEC,MAAM,CAAC;IAChC,KAAK,KAAK;MACT,OAAOf,IAAI,CAACvB,GAAG,CAACqC,MAAM,EAAEC,MAAM,CAAC;IAChC;MACC,OAAOD,MAAM,GAAGC,MAAM;EACxB;AACD,CAAC;AAED,OAAO,MAAME,uBAAuB,GAAGA,CAAC;EACvCC,MAAM;EACNC,eAAe;EACfC;AAKD,CAAC,KAAa;EACb,SAAS;;EACT,OAAO,CAACF,MAAM,GAAGC,eAAe,KAAKC,KAAK,GAAG,CAAC,CAAC;AAChD,CAAC;AAED,OAAO,MAAMC,mCAAmC,GAAGA,CAAC;EACnDC,WAAW;EACXC,WAAW;EACXC;AAKD,CAAC,KAAa;EACb,SAAS;;EACT,MAAMC,eAAe,GAAGzB,IAAI,CAACtB,GAAG,CAAC6C,WAAW,EAAEC,OAAO,CAAC;EACtD,OAAOtC,UAAU,CAACoC,WAAW,EAAEG,eAAe,EAAEH,WAAW,CAAC;AAC7D,CAAC;AAED,OAAO,MAAMI,6BAA6B,GAAGA,CAAC;EAC7CC,OAAO;EACPJ,WAAW;EACXK,WAAW,GAAG,CAAC;EACfJ;AAMD,CAAC,KAAa;EACb,SAAS;;EACT,OACCH,mCAAmC,CAAC;IACnCC,WAAW,EAAEK,OAAO;IACpBJ,WAAW;IACXC;EACD,CAAC,CAAC,GAAGI,WAAW;AAElB,CAAC","ignoreList":[]}
|
|
@@ -1,40 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
import { buildNavigationStyles } from "../sugar/navigation";
|
|
4
|
-
export const createNavigationAccessor = ({
|
|
5
|
-
id,
|
|
6
|
-
group,
|
|
7
|
-
getProps,
|
|
8
|
-
resolveBoundTag,
|
|
9
|
-
computeRaw,
|
|
10
|
-
zoomBaseOptions
|
|
11
|
-
}) => {
|
|
12
|
-
"worklet";
|
|
13
|
-
|
|
14
|
-
const resolvedId = id ?? "";
|
|
15
|
-
const computeNavigationPresetStyles = (preset, navigationOptions) => {
|
|
16
|
-
"worklet";
|
|
17
|
-
|
|
18
|
-
const frameProps = getProps();
|
|
19
|
-
return buildNavigationStyles({
|
|
20
|
-
id: resolvedId,
|
|
21
|
-
group,
|
|
22
|
-
preset,
|
|
23
|
-
navigationOptions,
|
|
24
|
-
props: frameProps,
|
|
25
|
-
resolveTag: resolveBoundTag,
|
|
26
|
-
computeRaw: overrides => computeRaw({
|
|
27
|
-
...(overrides ?? {}),
|
|
28
|
-
raw: true
|
|
29
|
-
}, frameProps)
|
|
30
|
-
});
|
|
31
|
-
};
|
|
32
|
-
return {
|
|
33
|
-
zoom: () => {
|
|
34
|
-
"worklet";
|
|
35
|
-
|
|
36
|
-
return computeNavigationPresetStyles("zoom", zoomBaseOptions);
|
|
37
|
-
}
|
|
38
|
-
};
|
|
39
|
-
};
|
|
40
|
-
//# sourceMappingURL=navigation-accessor.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"names":["buildNavigationStyles","createNavigationAccessor","id","group","getProps","resolveBoundTag","computeRaw","zoomBaseOptions","resolvedId","computeNavigationPresetStyles","preset","navigationOptions","frameProps","props","resolveTag","overrides","raw","zoom"],"sourceRoot":"../../../../../../src","sources":["shared/utils/bounds/helpers/navigation-accessor.ts"],"mappings":";;AAEA,SAASA,qBAAqB,QAAQ,qBAAqB;AAgB3D,OAAO,MAAMC,wBAAwB,GAAGA,CAAC;EACxCC,EAAE;EACFC,KAAK;EACLC,QAAQ;EACRC,eAAe;EACfC,UAAU;EACVC;AACyB,CAAC,KAAK;EAC/B,SAAS;;EAET,MAAMC,UAAU,GAAGN,EAAE,IAAI,EAAE;EAE3B,MAAMO,6BAA6B,GAAGA,CACrCC,MAAc,EACdC,iBAA2C,KACvC;IACJ,SAAS;;IACT,MAAMC,UAAU,GAAGR,QAAQ,CAAC,CAAC;IAC7B,OAAOJ,qBAAqB,CAAC;MAC5BE,EAAE,EAAEM,UAAU;MACdL,KAAK;MACLO,MAAM;MACNC,iBAAiB;MACjBE,KAAK,EAAED,UAAU;MACjBE,UAAU,EAAET,eAAe;MAC3BC,UAAU,EAAGS,SAAS,IACrBT,UAAU,CACT;QACC,IAAIS,SAAS,IAAI,CAAC,CAAC,CAAC;QACpBC,GAAG,EAAE;MACN,CAAC,EACDJ,UACD;IACF,CAAC,CAAC;EACH,CAAC;EAED,OAAO;IACNK,IAAI,EAAEA,CAAA,KAAM;MACX,SAAS;;MACT,OAAOR,6BAA6B,CAAC,MAAM,EAAEF,eAAe,CAAC;IAC9D;EACD,CAAC;AACF,CAAC","ignoreList":[]}
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
import { BoundStore } from "../../../../stores/bounds";
|
|
4
|
-
export const toNumber = (value, fallback = 0) => {
|
|
5
|
-
"worklet";
|
|
6
|
-
|
|
7
|
-
return typeof value === "number" ? value : fallback;
|
|
8
|
-
};
|
|
9
|
-
export const resolveNavigationConfig = ({
|
|
10
|
-
id,
|
|
11
|
-
group,
|
|
12
|
-
navigationOptions,
|
|
13
|
-
currentRouteKey,
|
|
14
|
-
resolveTag,
|
|
15
|
-
defaultAnchor
|
|
16
|
-
}) => {
|
|
17
|
-
"worklet";
|
|
18
|
-
|
|
19
|
-
const resolvedTag = resolveTag({
|
|
20
|
-
id,
|
|
21
|
-
group
|
|
22
|
-
});
|
|
23
|
-
if (!resolvedTag) return null;
|
|
24
|
-
|
|
25
|
-
// Try direct boundary config for the current screen first.
|
|
26
|
-
const boundaryConfig = currentRouteKey ? BoundStore.getBoundaryConfig(resolvedTag, currentRouteKey) : null;
|
|
27
|
-
|
|
28
|
-
// Fallback: when the current screen has no Boundary (e.g. a zoom detail
|
|
29
|
-
// screen without a destination element), inherit config from the link's
|
|
30
|
-
// source screen so that props like scaleMode propagate to both sides.
|
|
31
|
-
let effectiveConfig = boundaryConfig;
|
|
32
|
-
if (!effectiveConfig) {
|
|
33
|
-
// For no-destination navigation zoom, the focused route won't appear in
|
|
34
|
-
// a completed link yet. Fall back to the latest unscoped link so source
|
|
35
|
-
// boundary defaults (anchor/scaleMode/target) still propagate.
|
|
36
|
-
const scopedLink = currentRouteKey ? BoundStore.getActiveLink(resolvedTag, currentRouteKey) : null;
|
|
37
|
-
const link = scopedLink ?? BoundStore.getActiveLink(resolvedTag);
|
|
38
|
-
if (link?.source) {
|
|
39
|
-
effectiveConfig = BoundStore.getBoundaryConfig(resolvedTag, link.source.screenKey);
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
const sharedOptions = {
|
|
43
|
-
...(navigationOptions ?? {}),
|
|
44
|
-
anchor: navigationOptions?.anchor ?? effectiveConfig?.anchor ?? defaultAnchor,
|
|
45
|
-
scaleMode: navigationOptions?.scaleMode ?? effectiveConfig?.scaleMode ?? "uniform"
|
|
46
|
-
};
|
|
47
|
-
const explicitTarget = navigationOptions?.target ?? effectiveConfig?.target;
|
|
48
|
-
return {
|
|
49
|
-
resolvedTag,
|
|
50
|
-
sharedOptions,
|
|
51
|
-
explicitTarget
|
|
52
|
-
};
|
|
53
|
-
};
|
|
54
|
-
//# sourceMappingURL=helpers.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"names":["BoundStore","toNumber","value","fallback","resolveNavigationConfig","id","group","navigationOptions","currentRouteKey","resolveTag","defaultAnchor","resolvedTag","boundaryConfig","getBoundaryConfig","effectiveConfig","scopedLink","getActiveLink","link","source","screenKey","sharedOptions","anchor","scaleMode","explicitTarget","target"],"sourceRoot":"../../../../../../../src","sources":["shared/utils/bounds/sugar/navigation/helpers.ts"],"mappings":";;AAAA,SAASA,UAAU,QAAQ,2BAA2B;AAKtD,OAAO,MAAMC,QAAQ,GAAGA,CAACC,KAAc,E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EAE3E,OAAO;IACNb,WAAW;IACXS,aAAa;IACbG;EACD,CAAC;AACF,CAAC","ignoreList":[]}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
import { NO_STYLES } from "../../../../constants";
|
|
4
|
-
import { buildZoomNavigationStyles } from "./zoom";
|
|
5
|
-
export const buildNavigationStyles = params => {
|
|
6
|
-
"worklet";
|
|
7
|
-
|
|
8
|
-
switch (params.preset) {
|
|
9
|
-
case "zoom":
|
|
10
|
-
return buildZoomNavigationStyles(params);
|
|
11
|
-
default:
|
|
12
|
-
return NO_STYLES;
|
|
13
|
-
}
|
|
14
|
-
};
|
|
15
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"names":["NO_STYLES","buildZoomNavigationStyles","buildNavigationStyles","params","preset"],"sourceRoot":"../../../../../../../src","sources":["shared/utils/bounds/sugar/navigation/index.ts"],"mappings":";;AAAA,SAASA,SAAS,QAAQ,uBAAuB;AAEjD,SAASC,yBAAyB,QAAQ,QAAQ;AAElD,OAAO,MAAMC,qBAAqB,GAAIC,MAAmC,IAAK;EAC7E,SAAS;;EAET,QAAQA,MAAM,CAACC,MAAM;IACpB,KAAK,MAAM;MACV,OAAOH,yBAAyB,CAACE,MAAM,CAAC;IACzC;MACC,OAAOH,SAAS;EAClB;AACD,CAAC","ignoreList":[]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"names":[],"sourceRoot":"../../../../../../../src","sources":["shared/utils/bounds/sugar/navigation/types.ts"],"mappings":"","ignoreList":[]}
|