react-native-screen-transitions 3.4.0-alpha.1 → 3.4.0-alpha.3
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 +11 -1109
- package/lib/commonjs/blank-stack/navigators/create-blank-stack-navigator.js +69 -2
- package/lib/commonjs/blank-stack/navigators/create-blank-stack-navigator.js.map +1 -1
- package/lib/commonjs/component-stack/navigators/create-component-stack-navigator.js +9 -0
- package/lib/commonjs/component-stack/navigators/create-component-stack-navigator.js.map +1 -1
- package/lib/commonjs/shared/components/create-boundary-component/hooks/helpers/measurement-rules.js +195 -0
- package/lib/commonjs/shared/components/create-boundary-component/hooks/helpers/measurement-rules.js.map +1 -0
- package/lib/commonjs/shared/components/create-boundary-component/hooks/use-auto-source-measurement.js +7 -14
- package/lib/commonjs/shared/components/create-boundary-component/hooks/use-auto-source-measurement.js.map +1 -1
- package/lib/commonjs/shared/components/create-boundary-component/hooks/use-boundary-measure-and-store.js +19 -18
- package/lib/commonjs/shared/components/create-boundary-component/hooks/use-boundary-measure-and-store.js.map +1 -1
- package/lib/commonjs/shared/components/create-boundary-component/hooks/use-deferred-measurement-trigger.js +54 -0
- package/lib/commonjs/shared/components/create-boundary-component/hooks/use-deferred-measurement-trigger.js.map +1 -0
- package/lib/commonjs/shared/components/create-boundary-component/hooks/use-group-active-measurement.js +40 -8
- package/lib/commonjs/shared/components/create-boundary-component/hooks/use-group-active-measurement.js.map +1 -1
- package/lib/commonjs/shared/components/create-boundary-component/hooks/use-group-active-source-measurement.js +72 -0
- package/lib/commonjs/shared/components/create-boundary-component/hooks/use-group-active-source-measurement.js.map +1 -0
- package/lib/commonjs/shared/components/create-boundary-component/hooks/use-initial-layout-handler.js +16 -7
- package/lib/commonjs/shared/components/create-boundary-component/hooks/use-initial-layout-handler.js.map +1 -1
- package/lib/commonjs/shared/components/create-boundary-component/hooks/use-pending-destination-measurement.js +7 -4
- package/lib/commonjs/shared/components/create-boundary-component/hooks/use-pending-destination-measurement.js.map +1 -1
- package/lib/commonjs/shared/components/create-boundary-component/hooks/use-pending-destination-retry-measurement.js +14 -15
- package/lib/commonjs/shared/components/create-boundary-component/hooks/use-pending-destination-retry-measurement.js.map +1 -1
- package/lib/commonjs/shared/components/create-boundary-component/hooks/use-scroll-settled-measurement.js +27 -9
- package/lib/commonjs/shared/components/create-boundary-component/hooks/use-scroll-settled-measurement.js.map +1 -1
- package/lib/commonjs/shared/components/create-boundary-component/index.js +23 -10
- package/lib/commonjs/shared/components/create-boundary-component/index.js.map +1 -1
- package/lib/commonjs/shared/components/create-transition-aware-component.js +4 -4
- package/lib/commonjs/shared/components/create-transition-aware-component.js.map +1 -1
- package/lib/commonjs/shared/components/native-screen-container.js +12 -6
- package/lib/commonjs/shared/components/native-screen-container.js.map +1 -1
- package/lib/commonjs/shared/components/native-screen.js +35 -8
- package/lib/commonjs/shared/components/native-screen.js.map +1 -1
- package/lib/commonjs/shared/components/screen-container/deferred-visibility-host.js +43 -0
- package/lib/commonjs/shared/components/screen-container/deferred-visibility-host.js.map +1 -0
- package/lib/commonjs/shared/components/screen-container/hooks/use-content-layout.js +60 -0
- package/lib/commonjs/shared/components/screen-container/hooks/use-content-layout.js.map +1 -0
- package/lib/commonjs/shared/components/screen-container/index.js +7 -4
- package/lib/commonjs/shared/components/screen-container/index.js.map +1 -1
- package/lib/commonjs/shared/components/screen-container/layers/content.js +32 -48
- 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 +9 -20
- package/lib/commonjs/shared/components/screen-container/layers/maybe-masked-navigation-container.js.map +1 -1
- package/lib/commonjs/shared/configs/presets.js +6 -6
- package/lib/commonjs/shared/configs/presets.js.map +1 -1
- package/lib/commonjs/shared/constants.js +10 -4
- package/lib/commonjs/shared/constants.js.map +1 -1
- package/lib/commonjs/shared/hooks/animation/use-associated-style.js +9 -34
- package/lib/commonjs/shared/hooks/animation/use-associated-style.js.map +1 -1
- package/lib/commonjs/shared/index.js +4 -10
- package/lib/commonjs/shared/index.js.map +1 -1
- package/lib/commonjs/shared/providers/gestures/handlers/use-handlers.js +6 -7
- package/lib/commonjs/shared/providers/gestures/handlers/use-handlers.js.map +1 -1
- package/lib/commonjs/shared/providers/gestures/helpers/gesture-activation.js +11 -6
- package/lib/commonjs/shared/providers/gestures/helpers/gesture-activation.js.map +1 -1
- package/lib/commonjs/shared/providers/layout-anchor.provider.js +4 -6
- package/lib/commonjs/shared/providers/layout-anchor.provider.js.map +1 -1
- package/lib/commonjs/shared/providers/screen/animation/helpers/pipeline.js +14 -7
- package/lib/commonjs/shared/providers/screen/animation/helpers/pipeline.js.map +1 -1
- package/lib/commonjs/shared/providers/screen/helpers/resolve-interpolated-style-output.js +36 -0
- package/lib/commonjs/shared/providers/screen/helpers/resolve-interpolated-style-output.js.map +1 -0
- package/lib/commonjs/shared/providers/screen/styles.provider.js +31 -10
- package/lib/commonjs/shared/providers/screen/styles.provider.js.map +1 -1
- package/lib/commonjs/shared/providers/stack/core.provider.js +14 -21
- package/lib/commonjs/shared/providers/stack/core.provider.js.map +1 -1
- package/lib/commonjs/shared/stores/animation.store.js +3 -1
- package/lib/commonjs/shared/stores/animation.store.js.map +1 -1
- package/lib/commonjs/shared/stores/bounds/internals/presence.js.map +1 -1
- package/lib/commonjs/shared/utils/bounds/helpers/compute-bounds-styles.js +16 -7
- package/lib/commonjs/shared/utils/bounds/helpers/compute-bounds-styles.js.map +1 -1
- package/lib/commonjs/shared/utils/bounds/helpers/resolve-bound-tag.js +0 -5
- package/lib/commonjs/shared/utils/bounds/helpers/resolve-bound-tag.js.map +1 -1
- package/lib/commonjs/shared/utils/bounds/index.js +10 -0
- package/lib/commonjs/shared/utils/bounds/index.js.map +1 -1
- package/lib/commonjs/shared/utils/bounds/types/frame-props.js +6 -0
- package/lib/commonjs/shared/utils/bounds/types/frame-props.js.map +1 -0
- package/lib/commonjs/shared/utils/bounds/zoom/build.js +34 -31
- package/lib/commonjs/shared/utils/bounds/zoom/build.js.map +1 -1
- package/lib/commonjs/shared/utils/resolve-screen-transition-options.js +25 -0
- package/lib/commonjs/shared/utils/resolve-screen-transition-options.js.map +1 -0
- package/lib/module/blank-stack/navigators/create-blank-stack-navigator.js +69 -3
- package/lib/module/blank-stack/navigators/create-blank-stack-navigator.js.map +1 -1
- package/lib/module/component-stack/navigators/create-component-stack-navigator.js +9 -0
- package/lib/module/component-stack/navigators/create-component-stack-navigator.js.map +1 -1
- package/lib/module/shared/components/create-boundary-component/hooks/helpers/measurement-rules.js +182 -0
- package/lib/module/shared/components/create-boundary-component/hooks/helpers/measurement-rules.js.map +1 -0
- package/lib/module/shared/components/create-boundary-component/hooks/use-auto-source-measurement.js +7 -14
- package/lib/module/shared/components/create-boundary-component/hooks/use-auto-source-measurement.js.map +1 -1
- package/lib/module/shared/components/create-boundary-component/hooks/use-boundary-measure-and-store.js +19 -18
- package/lib/module/shared/components/create-boundary-component/hooks/use-boundary-measure-and-store.js.map +1 -1
- package/lib/module/shared/components/create-boundary-component/hooks/use-deferred-measurement-trigger.js +49 -0
- package/lib/module/shared/components/create-boundary-component/hooks/use-deferred-measurement-trigger.js.map +1 -0
- package/lib/module/shared/components/create-boundary-component/hooks/use-group-active-measurement.js +41 -8
- package/lib/module/shared/components/create-boundary-component/hooks/use-group-active-measurement.js.map +1 -1
- package/lib/module/shared/components/create-boundary-component/hooks/use-group-active-source-measurement.js +67 -0
- package/lib/module/shared/components/create-boundary-component/hooks/use-group-active-source-measurement.js.map +1 -0
- package/lib/module/shared/components/create-boundary-component/hooks/use-initial-layout-handler.js +16 -7
- package/lib/module/shared/components/create-boundary-component/hooks/use-initial-layout-handler.js.map +1 -1
- package/lib/module/shared/components/create-boundary-component/hooks/use-pending-destination-measurement.js +7 -4
- package/lib/module/shared/components/create-boundary-component/hooks/use-pending-destination-measurement.js.map +1 -1
- package/lib/module/shared/components/create-boundary-component/hooks/use-pending-destination-retry-measurement.js +14 -15
- package/lib/module/shared/components/create-boundary-component/hooks/use-pending-destination-retry-measurement.js.map +1 -1
- package/lib/module/shared/components/create-boundary-component/hooks/use-scroll-settled-measurement.js +27 -9
- package/lib/module/shared/components/create-boundary-component/hooks/use-scroll-settled-measurement.js.map +1 -1
- package/lib/module/shared/components/create-boundary-component/index.js +23 -10
- package/lib/module/shared/components/create-boundary-component/index.js.map +1 -1
- package/lib/module/shared/components/create-transition-aware-component.js +4 -4
- package/lib/module/shared/components/create-transition-aware-component.js.map +1 -1
- package/lib/module/shared/components/native-screen-container.js +12 -6
- package/lib/module/shared/components/native-screen-container.js.map +1 -1
- package/lib/module/shared/components/native-screen.js +35 -8
- package/lib/module/shared/components/native-screen.js.map +1 -1
- package/lib/module/shared/components/screen-container/deferred-visibility-host.js +38 -0
- package/lib/module/shared/components/screen-container/deferred-visibility-host.js.map +1 -0
- package/lib/module/shared/components/screen-container/hooks/use-content-layout.js +56 -0
- package/lib/module/shared/components/screen-container/hooks/use-content-layout.js.map +1 -0
- package/lib/module/shared/components/screen-container/index.js +7 -4
- package/lib/module/shared/components/screen-container/index.js.map +1 -1
- package/lib/module/shared/components/screen-container/layers/content.js +37 -53
- 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 +10 -21
- package/lib/module/shared/components/screen-container/layers/maybe-masked-navigation-container.js.map +1 -1
- package/lib/module/shared/configs/presets.js +7 -7
- package/lib/module/shared/configs/presets.js.map +1 -1
- package/lib/module/shared/constants.js +9 -3
- package/lib/module/shared/constants.js.map +1 -1
- package/lib/module/shared/hooks/animation/use-associated-style.js +10 -35
- package/lib/module/shared/hooks/animation/use-associated-style.js.map +1 -1
- package/lib/module/shared/index.js +1 -1
- package/lib/module/shared/index.js.map +1 -1
- package/lib/module/shared/providers/gestures/handlers/use-handlers.js +6 -7
- package/lib/module/shared/providers/gestures/handlers/use-handlers.js.map +1 -1
- package/lib/module/shared/providers/gestures/helpers/gesture-activation.js +11 -6
- package/lib/module/shared/providers/gestures/helpers/gesture-activation.js.map +1 -1
- package/lib/module/shared/providers/layout-anchor.provider.js +4 -6
- package/lib/module/shared/providers/layout-anchor.provider.js.map +1 -1
- package/lib/module/shared/providers/screen/animation/helpers/pipeline.js +14 -7
- package/lib/module/shared/providers/screen/animation/helpers/pipeline.js.map +1 -1
- package/lib/module/shared/providers/screen/helpers/resolve-interpolated-style-output.js +31 -0
- package/lib/module/shared/providers/screen/helpers/resolve-interpolated-style-output.js.map +1 -0
- package/lib/module/shared/providers/screen/styles.provider.js +30 -11
- package/lib/module/shared/providers/screen/styles.provider.js.map +1 -1
- package/lib/module/shared/providers/stack/core.provider.js +14 -21
- package/lib/module/shared/providers/stack/core.provider.js.map +1 -1
- package/lib/module/shared/stores/animation.store.js +3 -1
- package/lib/module/shared/stores/animation.store.js.map +1 -1
- package/lib/module/shared/stores/bounds/internals/presence.js.map +1 -1
- package/lib/module/shared/utils/bounds/helpers/compute-bounds-styles.js +17 -8
- package/lib/module/shared/utils/bounds/helpers/compute-bounds-styles.js.map +1 -1
- package/lib/module/shared/utils/bounds/helpers/resolve-bound-tag.js +0 -5
- package/lib/module/shared/utils/bounds/helpers/resolve-bound-tag.js.map +1 -1
- package/lib/module/shared/utils/bounds/index.js +10 -0
- package/lib/module/shared/utils/bounds/index.js.map +1 -1
- package/lib/module/shared/utils/bounds/types/frame-props.js +4 -0
- package/lib/module/shared/utils/bounds/types/frame-props.js.map +1 -0
- package/lib/module/shared/utils/bounds/zoom/build.js +35 -32
- package/lib/module/shared/utils/bounds/zoom/build.js.map +1 -1
- package/lib/module/shared/utils/resolve-screen-transition-options.js +19 -0
- package/lib/module/shared/utils/resolve-screen-transition-options.js.map +1 -0
- package/lib/typescript/blank-stack/index.d.ts +1 -1
- package/lib/typescript/blank-stack/index.d.ts.map +1 -1
- package/lib/typescript/blank-stack/navigators/create-blank-stack-navigator.d.ts +29 -4
- package/lib/typescript/blank-stack/navigators/create-blank-stack-navigator.d.ts.map +1 -1
- package/lib/typescript/blank-stack/types.d.ts +33 -4
- package/lib/typescript/blank-stack/types.d.ts.map +1 -1
- package/lib/typescript/component-stack/navigators/create-component-stack-navigator.d.ts +8 -0
- package/lib/typescript/component-stack/navigators/create-component-stack-navigator.d.ts.map +1 -1
- package/lib/typescript/shared/components/create-boundary-component/hooks/helpers/measurement-rules.d.ts +81 -0
- package/lib/typescript/shared/components/create-boundary-component/hooks/helpers/measurement-rules.d.ts.map +1 -0
- package/lib/typescript/shared/components/create-boundary-component/hooks/use-auto-source-measurement.d.ts.map +1 -1
- package/lib/typescript/shared/components/create-boundary-component/hooks/use-boundary-measure-and-store.d.ts +2 -3
- package/lib/typescript/shared/components/create-boundary-component/hooks/use-boundary-measure-and-store.d.ts.map +1 -1
- package/lib/typescript/shared/components/create-boundary-component/hooks/use-deferred-measurement-trigger.d.ts +11 -0
- package/lib/typescript/shared/components/create-boundary-component/hooks/use-deferred-measurement-trigger.d.ts.map +1 -0
- package/lib/typescript/shared/components/create-boundary-component/hooks/use-group-active-measurement.d.ts +2 -2
- package/lib/typescript/shared/components/create-boundary-component/hooks/use-group-active-measurement.d.ts.map +1 -1
- package/lib/typescript/shared/components/create-boundary-component/hooks/use-group-active-source-measurement.d.ts +11 -0
- package/lib/typescript/shared/components/create-boundary-component/hooks/use-group-active-source-measurement.d.ts.map +1 -0
- package/lib/typescript/shared/components/create-boundary-component/hooks/use-initial-layout-handler.d.ts.map +1 -1
- package/lib/typescript/shared/components/create-boundary-component/hooks/use-pending-destination-measurement.d.ts.map +1 -1
- package/lib/typescript/shared/components/create-boundary-component/hooks/use-pending-destination-retry-measurement.d.ts +3 -3
- package/lib/typescript/shared/components/create-boundary-component/hooks/use-pending-destination-retry-measurement.d.ts.map +1 -1
- package/lib/typescript/shared/components/create-boundary-component/hooks/use-scroll-settled-measurement.d.ts +2 -2
- package/lib/typescript/shared/components/create-boundary-component/hooks/use-scroll-settled-measurement.d.ts.map +1 -1
- package/lib/typescript/shared/components/create-boundary-component/index.d.ts +5 -3
- package/lib/typescript/shared/components/create-boundary-component/index.d.ts.map +1 -1
- package/lib/typescript/shared/components/create-boundary-component/types.d.ts +2 -4
- package/lib/typescript/shared/components/create-boundary-component/types.d.ts.map +1 -1
- package/lib/typescript/shared/components/create-transition-aware-component.d.ts +1 -0
- package/lib/typescript/shared/components/create-transition-aware-component.d.ts.map +1 -1
- package/lib/typescript/shared/components/native-screen-container.d.ts.map +1 -1
- package/lib/typescript/shared/components/native-screen.d.ts.map +1 -1
- package/lib/typescript/shared/components/screen-container/deferred-visibility-host.d.ts +13 -0
- package/lib/typescript/shared/components/screen-container/deferred-visibility-host.d.ts.map +1 -0
- package/lib/typescript/shared/components/screen-container/hooks/use-content-layout.d.ts +3 -0
- package/lib/typescript/shared/components/screen-container/hooks/use-content-layout.d.ts.map +1 -0
- package/lib/typescript/shared/components/screen-container/index.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 +3 -1
- package/lib/typescript/shared/components/screen-container/layers/maybe-masked-navigation-container.d.ts.map +1 -1
- package/lib/typescript/shared/configs/index.d.ts.map +1 -1
- package/lib/typescript/shared/constants.d.ts +9 -3
- package/lib/typescript/shared/constants.d.ts.map +1 -1
- package/lib/typescript/shared/hooks/animation/use-associated-style.d.ts +5 -11
- package/lib/typescript/shared/hooks/animation/use-associated-style.d.ts.map +1 -1
- package/lib/typescript/shared/index.d.ts +1 -2
- package/lib/typescript/shared/index.d.ts.map +1 -1
- package/lib/typescript/shared/providers/gestures/handlers/use-handlers.d.ts +1 -1
- package/lib/typescript/shared/providers/gestures/handlers/use-handlers.d.ts.map +1 -1
- package/lib/typescript/shared/providers/gestures/helpers/gesture-activation.d.ts.map +1 -1
- package/lib/typescript/shared/providers/layout-anchor.provider.d.ts +1 -1
- package/lib/typescript/shared/providers/layout-anchor.provider.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/helpers/resolve-interpolated-style-output.d.ts +10 -0
- package/lib/typescript/shared/providers/screen/helpers/resolve-interpolated-style-output.d.ts.map +1 -0
- package/lib/typescript/shared/providers/screen/styles.provider.d.ts +4 -2
- package/lib/typescript/shared/providers/screen/styles.provider.d.ts.map +1 -1
- package/lib/typescript/shared/providers/stack/core.provider.d.ts +2 -0
- package/lib/typescript/shared/providers/stack/core.provider.d.ts.map +1 -1
- package/lib/typescript/shared/stores/animation.store.d.ts +5 -3
- package/lib/typescript/shared/stores/animation.store.d.ts.map +1 -1
- package/lib/typescript/shared/stores/bounds/internals/presence.d.ts.map +1 -1
- package/lib/typescript/shared/types/animation.types.d.ts +13 -1
- package/lib/typescript/shared/types/animation.types.d.ts.map +1 -1
- package/lib/typescript/shared/types/screen.types.d.ts +51 -22
- package/lib/typescript/shared/types/screen.types.d.ts.map +1 -1
- package/lib/typescript/shared/utils/bounds/helpers/compute-bounds-styles.d.ts +11 -1
- package/lib/typescript/shared/utils/bounds/helpers/compute-bounds-styles.d.ts.map +1 -1
- package/lib/typescript/shared/utils/bounds/helpers/resolve-bound-tag.d.ts.map +1 -1
- package/lib/typescript/shared/utils/bounds/index.d.ts +2 -2
- package/lib/typescript/shared/utils/bounds/index.d.ts.map +1 -1
- package/lib/typescript/shared/utils/bounds/types/frame-props.d.ts +5 -0
- package/lib/typescript/shared/utils/bounds/types/frame-props.d.ts.map +1 -0
- package/lib/typescript/shared/utils/bounds/zoom/accessor.d.ts +4 -4
- package/lib/typescript/shared/utils/bounds/zoom/accessor.d.ts.map +1 -1
- package/lib/typescript/shared/utils/bounds/zoom/build.d.ts +2 -2
- package/lib/typescript/shared/utils/bounds/zoom/build.d.ts.map +1 -1
- package/lib/typescript/shared/utils/bounds/zoom/types.d.ts +3 -3
- package/lib/typescript/shared/utils/bounds/zoom/types.d.ts.map +1 -1
- package/lib/typescript/shared/utils/resolve-screen-transition-options.d.ts +5 -0
- package/lib/typescript/shared/utils/resolve-screen-transition-options.d.ts.map +1 -0
- package/package.json +2 -1
- package/src/blank-stack/index.ts +1 -0
- package/src/blank-stack/navigators/create-blank-stack-navigator.tsx +138 -19
- package/src/blank-stack/types.ts +33 -5
- package/src/component-stack/navigators/create-component-stack-navigator.tsx +8 -0
- package/src/shared/components/create-boundary-component/hooks/helpers/measurement-rules.ts +258 -0
- package/src/shared/components/create-boundary-component/hooks/use-auto-source-measurement.ts +7 -17
- package/src/shared/components/create-boundary-component/hooks/use-boundary-measure-and-store.ts +38 -28
- package/src/shared/components/create-boundary-component/hooks/use-deferred-measurement-trigger.ts +58 -0
- package/src/shared/components/create-boundary-component/hooks/use-group-active-measurement.ts +41 -10
- package/src/shared/components/create-boundary-component/hooks/use-group-active-source-measurement.ts +82 -0
- package/src/shared/components/create-boundary-component/hooks/use-initial-layout-handler.ts +24 -12
- package/src/shared/components/create-boundary-component/hooks/use-pending-destination-measurement.ts +11 -9
- package/src/shared/components/create-boundary-component/hooks/use-pending-destination-retry-measurement.ts +29 -26
- package/src/shared/components/create-boundary-component/hooks/use-scroll-settled-measurement.ts +26 -17
- package/src/shared/components/create-boundary-component/index.tsx +25 -7
- package/src/shared/components/create-boundary-component/types.ts +8 -4
- package/src/shared/components/create-transition-aware-component.tsx +5 -3
- package/src/shared/components/native-screen-container.tsx +11 -3
- package/src/shared/components/native-screen.tsx +65 -20
- package/src/shared/components/screen-container/deferred-visibility-host.tsx +37 -0
- package/src/shared/components/screen-container/hooks/use-content-layout.ts +82 -0
- package/src/shared/components/screen-container/index.tsx +5 -2
- package/src/shared/components/screen-container/layers/content.tsx +53 -80
- package/src/shared/components/screen-container/layers/maybe-masked-navigation-container.tsx +12 -27
- package/src/shared/configs/presets.ts +10 -10
- package/src/shared/constants.ts +5 -3
- package/src/shared/hooks/animation/use-associated-style.ts +10 -54
- package/src/shared/index.ts +2 -3
- package/src/shared/providers/gestures/handlers/use-handlers.ts +8 -5
- package/src/shared/providers/gestures/helpers/gesture-activation.ts +11 -6
- package/src/shared/providers/layout-anchor.provider.tsx +2 -5
- package/src/shared/providers/register-bounds.provider.tsx +1 -1
- package/src/shared/providers/screen/animation/helpers/pipeline.ts +24 -8
- package/src/shared/providers/screen/helpers/resolve-interpolated-style-output.ts +41 -0
- package/src/shared/providers/screen/styles.provider.tsx +95 -72
- package/src/shared/providers/stack/core.provider.tsx +27 -14
- package/src/shared/stores/animation.store.ts +11 -7
- package/src/shared/stores/bounds/internals/presence.ts +3 -1
- package/src/shared/types/animation.types.ts +13 -1
- package/src/shared/types/screen.types.ts +55 -22
- package/src/shared/utils/bounds/helpers/compute-bounds-styles.ts +17 -3
- package/src/shared/utils/bounds/helpers/resolve-bound-tag.ts +0 -6
- package/src/shared/utils/bounds/index.ts +16 -5
- package/src/shared/utils/bounds/types/frame-props.ts +5 -0
- package/src/shared/utils/bounds/zoom/accessor.ts +3 -3
- package/src/shared/utils/bounds/zoom/build.ts +46 -32
- package/src/shared/utils/bounds/zoom/types.ts +3 -3
- package/src/shared/utils/resolve-screen-transition-options.ts +37 -0
- package/lib/commonjs/shared/providers/viewport.provider.js +0 -33
- package/lib/commonjs/shared/providers/viewport.provider.js.map +0 -1
- package/lib/module/shared/providers/viewport.provider.js +0 -27
- package/lib/module/shared/providers/viewport.provider.js.map +0 -1
- package/lib/typescript/shared/providers/viewport.provider.d.ts +0 -13
- package/lib/typescript/shared/providers/viewport.provider.d.ts.map +0 -1
- package/src/shared/providers/viewport.provider.tsx +0 -39
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_reactNative","require","_reactNativeScreens","_useStack","_jsxRuntime","NativeScreenContainer","children","flags","DISABLE_NATIVE_SCREENS","useStack","jsx","ScreenContainer","style","styles","container","View","exports","StyleSheet","create","flex"],"sourceRoot":"../../../../src","sources":["shared/components/native-screen-container.tsx"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AACA,IAAAC,mBAAA,GAAAD,OAAA;AACA,IAAAE,SAAA,GAAAF,OAAA;AAAyD,IAAAG,WAAA,GAAAH,OAAA;AAMlD,MAAMI,qBAAqB,GAAGA,CAAC;EAAEC;AAAgB,CAAC,KAAK;EAC7D,MAAM;IACLC,KAAK,EAAE;
|
|
1
|
+
{"version":3,"names":["_reactNative","require","_reactNativeScreens","_useStack","_jsxRuntime","NativeScreenContainer","children","flags","DISABLE_NATIVE_SCREENS","DISABLE_NATIVE_SCREEN_CONTAINER","useStack","jsx","ScreenContainer","style","styles","container","View","collapsable","exports","StyleSheet","create","flex"],"sourceRoot":"../../../../src","sources":["shared/components/native-screen-container.tsx"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AACA,IAAAC,mBAAA,GAAAD,OAAA;AACA,IAAAE,SAAA,GAAAF,OAAA;AAAyD,IAAAG,WAAA,GAAAH,OAAA;AAMlD,MAAMI,qBAAqB,GAAGA,CAAC;EAAEC;AAAgB,CAAC,KAAK;EAC7D,MAAM;IACLC,KAAK,EAAE;MACNC,sBAAsB,GAAG,KAAK;MAC9BC,+BAA+B,GAAG;IACnC;EACD,CAAC,GAAG,IAAAC,kBAAQ,EAAC,CAAC;EACd,IAAI,CAACF,sBAAsB,IAAI,CAACC,+BAA+B,EAAE;IAChE,oBACC,IAAAL,WAAA,CAAAO,GAAA,EAACT,mBAAA,CAAAU,eAAe;MAACC,KAAK,EAAEC,MAAM,CAACC,SAAU;MAAAT,QAAA,EAAEA;IAAQ,CAAkB,CAAC;EAExE;EACA;IAAA;IACC;IACA,IAAAF,WAAA,CAAAO,GAAA,EAACX,YAAA,CAAAgB,IAAI;MAACC,WAAW,EAAE,KAAM;MAACJ,KAAK,EAAEC,MAAM,CAACC,SAAU;MAAAT,QAAA,EAChDA;IAAQ,CACJ;EAAC;AAET,CAAC;AAACY,OAAA,CAAAb,qBAAA,GAAAA,qBAAA;AAEF,MAAMS,MAAM,GAAGK,uBAAU,CAACC,MAAM,CAAC;EAChCL,SAAS,EAAE;IACVM,IAAI,EAAE;EACP;AACD,CAAC,CAAC","ignoreList":[]}
|
|
@@ -44,24 +44,37 @@ const NativeScreen = ({
|
|
|
44
44
|
backdropBehaviors
|
|
45
45
|
} = (0, _managed.useManagedStackContext)();
|
|
46
46
|
const routesLength = routes.length;
|
|
47
|
+
const topIndex = routesLength - 1;
|
|
48
|
+
const topRouteKey = routes[topIndex]?.key ?? routeKey;
|
|
47
49
|
const screenRef = (0, _reactNativeReanimated.useAnimatedRef)();
|
|
48
|
-
const sceneProgress = _animation.AnimationStore.getRouteAnimation(routeKey, "progress");
|
|
49
50
|
const sceneClosing = _animation.AnimationStore.getRouteAnimation(routeKey, "closing");
|
|
51
|
+
const topSceneProgress = _animation.AnimationStore.getRouteAnimation(topRouteKey, "progress");
|
|
52
|
+
const topSceneClosing = _animation.AnimationStore.getRouteAnimation(topRouteKey, "closing");
|
|
50
53
|
const screenActivity = (0, _reactNativeReanimated.useSharedValue)(ScreenActivity.TRANSITIONING_OR_BELOW_TOP);
|
|
51
54
|
(0, _reactNativeReanimated.useDerivedValue)(() => {
|
|
52
|
-
if (!
|
|
55
|
+
if (!topSceneProgress) {
|
|
53
56
|
screenActivity.set(ScreenActivity.TRANSITIONING_OR_BELOW_TOP);
|
|
54
57
|
return;
|
|
55
58
|
}
|
|
56
59
|
if (index < routesLength - activeScreensLimit - 1 || isPreloaded) {
|
|
57
60
|
screenActivity.set(ScreenActivity.INACTIVE);
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
61
|
+
return;
|
|
62
|
+
}
|
|
63
|
+
const focusedIndex = optimisticFocusedIndex.value;
|
|
64
|
+
const topIsClosing = topSceneClosing.get() > 0 && focusedIndex >= 0 && focusedIndex < topIndex;
|
|
65
|
+
if (topIsClosing) {
|
|
66
|
+
const postCloseActiveStart = Math.max(0, focusedIndex - activeScreensLimit + 1);
|
|
67
|
+
const next = index === topIndex ? ScreenActivity.ON_TOP : index > focusedIndex || index >= postCloseActiveStart ? ScreenActivity.TRANSITIONING_OR_BELOW_TOP : ScreenActivity.INACTIVE;
|
|
62
68
|
if (next !== screenActivity.get()) {
|
|
63
69
|
screenActivity.set(next);
|
|
64
70
|
}
|
|
71
|
+
return;
|
|
72
|
+
}
|
|
73
|
+
const outputValue = index === topIndex ? ScreenActivity.ON_TOP : index >= routesLength - activeScreensLimit ? ScreenActivity.TRANSITIONING_OR_BELOW_TOP : ScreenActivity.INACTIVE;
|
|
74
|
+
const v = (0, _reactNativeReanimated.interpolate)(topSceneProgress.get(), [0, 1 - _constants.EPSILON, 1], [1, 1, outputValue], _reactNativeReanimated.Extrapolation.CLAMP);
|
|
75
|
+
const next = Math.trunc(v) ?? ScreenActivity.TRANSITIONING_OR_BELOW_TOP;
|
|
76
|
+
if (next !== screenActivity.get()) {
|
|
77
|
+
screenActivity.set(next);
|
|
65
78
|
}
|
|
66
79
|
});
|
|
67
80
|
const animatedProps = (0, _reactNativeReanimated.useAnimatedProps)(() => {
|
|
@@ -92,8 +105,22 @@ const NativeScreen = ({
|
|
|
92
105
|
pointerEvents
|
|
93
106
|
};
|
|
94
107
|
});
|
|
95
|
-
|
|
96
|
-
|
|
108
|
+
if (DISABLE_NATIVE_SCREENS) {
|
|
109
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeReanimated.default.View, {
|
|
110
|
+
ref: screenRef
|
|
111
|
+
// Keep a native boundary per screen when falling back to plain views.
|
|
112
|
+
// Android release builds can otherwise flatten sibling screens together.
|
|
113
|
+
,
|
|
114
|
+
collapsable: false,
|
|
115
|
+
style: _reactNative.StyleSheet.absoluteFill,
|
|
116
|
+
animatedProps: animatedProps,
|
|
117
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_layoutAnchor.LayoutAnchorProvider, {
|
|
118
|
+
anchorRef: screenRef,
|
|
119
|
+
children: children
|
|
120
|
+
})
|
|
121
|
+
});
|
|
122
|
+
}
|
|
123
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(AnimatedNativeScreen, {
|
|
97
124
|
enabled: true,
|
|
98
125
|
ref: screenRef,
|
|
99
126
|
style: _reactNative.StyleSheet.absoluteFill,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_reactNative","require","_reactNativeReanimated","_interopRequireWildcard","_reactNativeScreens","_constants","_useStack","_layoutAnchor","_managed","_animation","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","PASSTHROUGH","ScreenActivity","POINT_NONE","POINT_BOX_NONE","AnimatedNativeScreen","Animated","createAnimatedComponent","RNSScreen","NativeScreen","routeKey","index","isPreloaded","children","freezeOnBlur","shouldFreeze","flags","DISABLE_NATIVE_SCREENS","routes","optimisticFocusedIndex","useStack","activeScreensLimit","backdropBehaviors","useManagedStackContext","routesLength","length","screenRef","useAnimatedRef","
|
|
1
|
+
{"version":3,"names":["_reactNative","require","_reactNativeReanimated","_interopRequireWildcard","_reactNativeScreens","_constants","_useStack","_layoutAnchor","_managed","_animation","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","PASSTHROUGH","ScreenActivity","POINT_NONE","POINT_BOX_NONE","AnimatedNativeScreen","Animated","createAnimatedComponent","RNSScreen","NativeScreen","routeKey","index","isPreloaded","children","freezeOnBlur","shouldFreeze","flags","DISABLE_NATIVE_SCREENS","routes","optimisticFocusedIndex","useStack","activeScreensLimit","backdropBehaviors","useManagedStackContext","routesLength","length","topIndex","topRouteKey","key","screenRef","useAnimatedRef","sceneClosing","AnimationStore","getRouteAnimation","topSceneProgress","topSceneClosing","screenActivity","useSharedValue","TRANSITIONING_OR_BELOW_TOP","useDerivedValue","INACTIVE","focusedIndex","value","topIsClosing","postCloseActiveStart","Math","max","next","ON_TOP","outputValue","v","interpolate","EPSILON","Extrapolation","CLAMP","trunc","animatedProps","useAnimatedProps","activity","isClosing","activeIndex","isActive","activeBackdrop","activeAllowsPassthrough","isAllowedPassthroughBelow","pointerEvents","activityState","jsx","View","ref","collapsable","style","StyleSheet","absoluteFill","LayoutAnchorProvider","anchorRef","enabled","exports"],"sourceRoot":"../../../../src","sources":["shared/components/native-screen.tsx"],"mappings":";;;;;;AACA,IAAAA,YAAA,GAAAC,OAAA;AACA,IAAAC,sBAAA,GAAAC,uBAAA,CAAAF,OAAA;AAQA,IAAAG,mBAAA,GAAAH,OAAA;AACA,IAAAI,UAAA,GAAAJ,OAAA;AACA,IAAAK,SAAA,GAAAL,OAAA;AACA,IAAAM,aAAA,GAAAN,OAAA;AACA,IAAAO,QAAA,GAAAP,OAAA;AACA,IAAAQ,UAAA,GAAAR,OAAA;AAA2D,IAAAS,WAAA,GAAAT,OAAA;AAAA,SAAAE,wBAAAQ,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAV,uBAAA,YAAAA,CAAAQ,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,EAAAV,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,SAAAQ,CAAA,MAAAF,CAAA,GAAAL,CAAA,GAAAG,CAAA,GAAAD,CAAA,QAAAG,CAAA,CAAAK,GAAA,CAAAX,CAAA,UAAAM,CAAA,CAAAM,GAAA,CAAAZ,CAAA,GAAAM,CAAA,CAAAO,GAAA,CAAAb,CAAA,EAAAQ,CAAA,gBAAAP,CAAA,IAAAD,CAAA,gBAAAC,CAAA,OAAAa,cAAA,CAAAC,IAAA,CAAAf,CAAA,EAAAC,CAAA,OAAAM,CAAA,IAAAD,CAAA,GAAAU,MAAA,CAAAC,cAAA,KAAAD,MAAA,CAAAE,wBAAA,CAAAlB,CAAA,E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AQ,IAAIzB,YAAY;QAClEkD;MACD,CAAC;IACF;IAEA,OAAO;MACNA;IACD,CAAC;EACF,CAAC,CAAC;EAEF,IAAIhD,sBAAsB,EAAE;IAC3B,oBACC,IAAApC,WAAA,CAAAsF,GAAA,EAAC9F,sBAAA,CAAAmB,OAAQ,CAAC4E,IAAI;MACbC,GAAG,EAAExC;MACL;MACA;MAAA;MACAyC,WAAW,EAAE,KAAM;MACnBC,KAAK,EAAEC,uBAAU,CAACC,YAAa;MAC/BjB,aAAa,EAAEA,aAAc;MAAA3C,QAAA,eAE7B,IAAAhC,WAAA,CAAAsF,GAAA,EAACzF,aAAA,CAAAgG,oBAAoB;QAACC,SAAS,EAAE9C,SAAU;QAAAhB,QAAA,EACzCA;MAAQ,CACY;IAAC,CACT,CAAC;EAElB;EAEA,oBACC,IAAAhC,WAAA,CAAAsF,GAAA,EAAC9D,oBAAoB;IACpBuE,OAAO;IACPP,GAAG,EAAExC,SAAU;IACf0C,KAAK,EAAEC,uBAAU,CAACC,YAAa;IAC/B3D,YAAY,EAAEA,YAAa;IAC3B0C,aAAa,EAAEA,aAAc;IAAA3C,QAAA,eAE7B,IAAAhC,WAAA,CAAAsF,GAAA,EAACzF,aAAA,CAAAgG,oBAAoB;MAACC,SAAS,EAAE9C,SAAU;MAAAhB,QAAA,EACzCA;IAAQ,CACY;EAAC,CACF,CAAC;AAEzB,CAAC;AAACgE,OAAA,CAAApE,YAAA,GAAAA,YAAA","ignoreList":[]}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.DeferredVisibilityHost = void 0;
|
|
7
|
+
var _react = require("react");
|
|
8
|
+
var _reactNative = require("react-native");
|
|
9
|
+
var _reactNativeReanimated = _interopRequireWildcard(require("react-native-reanimated"));
|
|
10
|
+
var _constants = require("../../constants");
|
|
11
|
+
var _styles = require("../../providers/screen/styles.provider");
|
|
12
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
13
|
+
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
|
|
14
|
+
/**
|
|
15
|
+
* Hides the full screen visual subtree while an interpolator explicitly reports
|
|
16
|
+
* that it is not safe to reveal yet.
|
|
17
|
+
*
|
|
18
|
+
* This sits above backdrop/content/mask/surface so a deferred transition does
|
|
19
|
+
* not leak raw first-paint UI from nested layers.
|
|
20
|
+
*/
|
|
21
|
+
const DeferredVisibilityHost = exports.DeferredVisibilityHost = /*#__PURE__*/(0, _react.memo)(({
|
|
22
|
+
children
|
|
23
|
+
}) => {
|
|
24
|
+
const {
|
|
25
|
+
resolutionMode
|
|
26
|
+
} = (0, _styles.useScreenStyles)();
|
|
27
|
+
const animatedStyle = (0, _reactNativeReanimated.useAnimatedStyle)(() => {
|
|
28
|
+
"worklet";
|
|
29
|
+
|
|
30
|
+
return resolutionMode.value === "deferred" ? _constants.HIDDEN_STYLE : _constants.NO_STYLES;
|
|
31
|
+
});
|
|
32
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeReanimated.default.View, {
|
|
33
|
+
collapsable: false,
|
|
34
|
+
style: [styles.host, animatedStyle],
|
|
35
|
+
children: children
|
|
36
|
+
});
|
|
37
|
+
});
|
|
38
|
+
const styles = _reactNative.StyleSheet.create({
|
|
39
|
+
host: {
|
|
40
|
+
flex: 1
|
|
41
|
+
}
|
|
42
|
+
});
|
|
43
|
+
//# sourceMappingURL=deferred-visibility-host.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","require","_reactNative","_reactNativeReanimated","_interopRequireWildcard","_constants","_styles","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","DeferredVisibilityHost","exports","memo","children","resolutionMode","useScreenStyles","animatedStyle","useAnimatedStyle","value","HIDDEN_STYLE","NO_STYLES","jsx","View","collapsable","style","styles","host","StyleSheet","create","flex"],"sourceRoot":"../../../../../src","sources":["shared/components/screen-container/deferred-visibility-host.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,sBAAA,GAAAC,uBAAA,CAAAH,OAAA;AACA,IAAAI,UAAA,GAAAJ,OAAA;AACA,IAAAK,OAAA,GAAAL,OAAA;AAAyE,IAAAM,WAAA,GAAAN,OAAA;AAAA,SAAAG,wBAAAI,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAN,uBAAA,YAAAA,CAAAI,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,EAAAV,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,SAAAQ,CAAA,MAAAF,CAAA,GAAAL,CAAA,GAAAG,CAAA,GAAAD,CAAA,QAAAG,CAAA,CAAAK,GAAA,CAAAX,CAAA,UAAAM,CAAA,CAAAM,GAAA,CAAAZ,CAAA,GAAAM,CAAA,CAAAO,GAAA,CAAAb,CAAA,EAAAQ,CAAA,gBAAAP,CAAA,IAAAD,CAAA,gBAAAC,CAAA,OAAAa,cAAA,CAAAC,IAAA,CAAAf,CAAA,EAAAC,CAAA,OAAAM,CAAA,IAAAD,CAAA,GAAAU,MAAA,CAAAC,cAAA,KAAAD,MAAA,CAAAE,wBAAA,CAAAlB,CAAA,EAAAC,CAAA,OAAAM,CAAA,CAAAK,GAAA,IAAAL,CAAA,CAAAM,GAAA,IAAAP,CAAA,CAAAE,CAAA,EAAAP,CAAA,EAAAM,CAAA,IAAAC,CAAA,CAAAP,CAAA,IAAAD,CAAA,CAAAC,CAAA,WAAAO,CAAA,KAAAR,CAAA,EAAAC,CAAA;AAMzE;AACA;AACA;AACA;AACA;AACA;AACA;AACO,MAAMkB,sBAAsB,GAAAC,OAAA,CAAAD,sBAAA,gBAAG,IAAAE,WAAI,EAAC,CAAC;EAAEC;AAAgB,CAAC,KAAK;EACnE,MAAM;IAAEC;EAAe,CAAC,GAAG,IAAAC,uBAAe,EAAC,CAAC;EAE5C,MAAMC,aAAa,GAAG,IAAAC,uCAAgB,EAAC,MAAM;IAC5C,SAAS;;IACT,OAAOH,cAAc,CAACI,KAAK,KAAK,UAAU,GAAGC,uBAAY,GAAGC,oBAAS;EACtE,CAAC,CAAC;EAEF,oBACC,IAAA9B,WAAA,CAAA+B,GAAA,EAACnC,sBAAA,CAAAe,OAAQ,CAACqB,IAAI;IAACC,WAAW,EAAE,KAAM;IAACC,KAAK,EAAE,CAACC,MAAM,CAACC,IAAI,EAAEV,aAAa,CAAE;IAAAH,QAAA,EACrEA;EAAQ,CACK,CAAC;AAElB,CAAC,CAAC;AAEF,MAAMY,MAAM,GAAGE,uBAAU,CAACC,MAAM,CAAC;EAChCF,IAAI,EAAE;IACLG,IAAI,EAAE;EACP;AACD,CAAC,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.useContentLayout = useContentLayout;
|
|
7
|
+
var _react = require("react");
|
|
8
|
+
var _reactNative = require("react-native");
|
|
9
|
+
var _reactNativeReanimated = require("react-native-reanimated");
|
|
10
|
+
var _descriptors = require("../../../providers/screen/descriptors");
|
|
11
|
+
var _animation = require("../../../stores/animation.store");
|
|
12
|
+
var _animateToProgress = require("../../../utils/animation/animate-to-progress");
|
|
13
|
+
function useContentLayout() {
|
|
14
|
+
const {
|
|
15
|
+
current
|
|
16
|
+
} = (0, _descriptors.useDescriptors)();
|
|
17
|
+
const {
|
|
18
|
+
isFirstKey
|
|
19
|
+
} = (0, _descriptors.useDescriptorDerivations)();
|
|
20
|
+
const {
|
|
21
|
+
height: screenHeight
|
|
22
|
+
} = (0, _reactNative.useWindowDimensions)();
|
|
23
|
+
const routeKey = current.route.key;
|
|
24
|
+
const animations = _animation.AnimationStore.getRouteAnimations(routeKey);
|
|
25
|
+
const autoSnapPointValue = _animation.AnimationStore.getAnimation(routeKey, "autoSnapPoint");
|
|
26
|
+
const contentLayoutValue = _animation.AnimationStore.getAnimation(routeKey, "contentLayout");
|
|
27
|
+
return (0, _react.useCallback)(event => {
|
|
28
|
+
const {
|
|
29
|
+
width,
|
|
30
|
+
height
|
|
31
|
+
} = event.nativeEvent.layout;
|
|
32
|
+
if (width <= 0 || height <= 0) return;
|
|
33
|
+
const fraction = Math.min(height / screenHeight, 1);
|
|
34
|
+
const transitionSpec = current.options.transitionSpec;
|
|
35
|
+
(0, _reactNativeReanimated.runOnUI)((nextWidth, nextHeight, nextFraction, isInitialScreen, spec) => {
|
|
36
|
+
"worklet";
|
|
37
|
+
|
|
38
|
+
contentLayoutValue.value = {
|
|
39
|
+
width: nextWidth,
|
|
40
|
+
height: nextHeight
|
|
41
|
+
};
|
|
42
|
+
const isFirstMeasurement = autoSnapPointValue.value <= 0;
|
|
43
|
+
autoSnapPointValue.value = nextFraction;
|
|
44
|
+
if (!isFirstMeasurement || animations.progress.value !== 0 || animations.animating.value !== 0) {
|
|
45
|
+
return;
|
|
46
|
+
}
|
|
47
|
+
if (isInitialScreen) {
|
|
48
|
+
animations.targetProgress.value = nextFraction;
|
|
49
|
+
animations.progress.value = nextFraction;
|
|
50
|
+
return;
|
|
51
|
+
}
|
|
52
|
+
(0, _animateToProgress.animateToProgress)({
|
|
53
|
+
target: nextFraction,
|
|
54
|
+
spec,
|
|
55
|
+
animations
|
|
56
|
+
});
|
|
57
|
+
})(width, height, fraction, isFirstKey, transitionSpec);
|
|
58
|
+
}, [animations, autoSnapPointValue, contentLayoutValue, current.options.transitionSpec, isFirstKey, screenHeight]);
|
|
59
|
+
}
|
|
60
|
+
//# sourceMappingURL=use-content-layout.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","require","_reactNative","_reactNativeReanimated","_descriptors","_animation","_animateToProgress","useContentLayout","current","useDescriptors","isFirstKey","useDescriptorDerivations","height","screenHeight","useWindowDimensions","routeKey","route","key","animations","AnimationStore","getRouteAnimations","autoSnapPointValue","getAnimation","contentLayoutValue","useCallback","event","width","nativeEvent","layout","fraction","Math","min","transitionSpec","options","runOnUI","nextWidth","nextHeight","nextFraction","isInitialScreen","spec","value","isFirstMeasurement","progress","animating","targetProgress","animateToProgress","target"],"sourceRoot":"../../../../../../src","sources":["shared/components/screen-container/hooks/use-content-layout.ts"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,sBAAA,GAAAF,OAAA;AACA,IAAAG,YAAA,GAAAH,OAAA;AAIA,IAAAI,UAAA,GAAAJ,OAAA;AACA,IAAAK,kBAAA,GAAAL,OAAA;AAEO,SAASM,gBAAgBA,CAAA,EAAG;EAClC,MAAM;IAAEC;EAAQ,CAAC,GAAG,IAAAC,2BAAc,EAAC,CAAC;EACpC,MAAM;IAAEC;EAAW,CAAC,GAAG,IAAAC,qCAAwB,EAAC,CAAC;EACjD,MAAM;IAAEC,MAAM,EAAEC;EAAa,CAAC,GAAG,IAAAC,gCAAmB,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GH,YAAY;QACxC;MACD;MAEA,IAAAQ,oCAAiB,EAAC;QACjBC,MAAM,EAAET,YAAY;QACpBE,IAAI;QACJrB;MACD,CAAC,CAAC;IACH,CACD,CAAC,CAACQ,KAAK,EAAEd,MAAM,EAAEiB,QAAQ,EAAEnB,UAAU,EAAEsB,cAAc,CAAC;EACvD,CAAC,EACD,CACCd,UAAU,EACVG,kBAAkB,EAClBE,kBAAkB,EAClBf,OAAO,CAACyB,OAAO,CAACD,cAAc,EAC9BtB,UAAU,EACVG,YAAY,CAEd,CAAC;AACF","ignoreList":[]}
|
|
@@ -6,6 +6,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
exports.ScreenContainer = void 0;
|
|
7
7
|
var _react = require("react");
|
|
8
8
|
var _reactNative = require("react-native");
|
|
9
|
+
var _deferredVisibilityHost = require("./deferred-visibility-host");
|
|
9
10
|
var _useBackdropPointerEvents = require("./hooks/use-backdrop-pointer-events");
|
|
10
11
|
var _backdrop = require("./layers/backdrop");
|
|
11
12
|
var _content = require("./layers/content");
|
|
@@ -16,12 +17,14 @@ const ScreenContainer = exports.ScreenContainer = /*#__PURE__*/(0, _react.memo)(
|
|
|
16
17
|
const {
|
|
17
18
|
pointerEvents
|
|
18
19
|
} = (0, _useBackdropPointerEvents.useBackdropPointerEvents)();
|
|
19
|
-
return /*#__PURE__*/(0, _jsxRuntime.
|
|
20
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
20
21
|
style: styles.container,
|
|
21
22
|
pointerEvents: pointerEvents,
|
|
22
|
-
children:
|
|
23
|
-
children:
|
|
24
|
-
|
|
23
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsxs)(_deferredVisibilityHost.DeferredVisibilityHost, {
|
|
24
|
+
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_backdrop.BackdropLayer, {}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_content.ContentLayer, {
|
|
25
|
+
children: children
|
|
26
|
+
})]
|
|
27
|
+
})
|
|
25
28
|
});
|
|
26
29
|
});
|
|
27
30
|
const styles = _reactNative.StyleSheet.create({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_react","require","_reactNative","_useBackdropPointerEvents","_backdrop","_content","_jsxRuntime","ScreenContainer","exports","memo","children","pointerEvents","useBackdropPointerEvents","
|
|
1
|
+
{"version":3,"names":["_react","require","_reactNative","_deferredVisibilityHost","_useBackdropPointerEvents","_backdrop","_content","_jsxRuntime","ScreenContainer","exports","memo","children","pointerEvents","useBackdropPointerEvents","jsx","View","style","styles","container","jsxs","DeferredVisibilityHost","BackdropLayer","ContentLayer","StyleSheet","create","flex"],"sourceRoot":"../../../../../src","sources":["shared/components/screen-container/index.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,uBAAA,GAAAF,OAAA;AACA,IAAAG,yBAAA,GAAAH,OAAA;AACA,IAAAI,SAAA,GAAAJ,OAAA;AACA,IAAAK,QAAA,GAAAL,OAAA;AAAgD,IAAAM,WAAA,GAAAN,OAAA;AAMzC,MAAMO,eAAe,GAAAC,OAAA,CAAAD,eAAA,gBAAG,IAAAE,WAAI,EAAC,CAAC;EAAEC;AAAgB,CAAC,KAAK;EAC5D,MAAM;IAAEC;EAAc,CAAC,GAAG,IAAAC,kDAAwB,EAAC,CAAC;EAEpD,oBACC,IAAAN,WAAA,CAAAO,GAAA,EAACZ,YAAA,CAAAa,IAAI;IAACC,KAAK,EAAEC,MAAM,CAACC,SAAU;IAACN,aAAa,EAAEA,aAAc;IAAAD,QAAA,eAC3D,IAAAJ,WAAA,CAAAY,IAAA,EAAChB,uBAAA,CAAAiB,sBAAsB;MAAAT,QAAA,gBACtB,IAAAJ,WAAA,CAAAO,GAAA,EAACT,SAAA,CAAAgB,aAAa,IAAE,CAAC,eACjB,IAAAd,WAAA,CAAAO,GAAA,EAACR,QAAA,CAAAgB,YAAY;QAAAX,QAAA,EAAEA;MAAQ,CAAe,CAAC;IAAA,CAChB;EAAC,CACpB,CAAC;AAET,CAAC,CAAC;AAEF,MAAMM,MAAM,GAAGM,uBAAU,CAACC,MAAM,CAAC;EAChCN,SAAS,EAAE;IACVO,IAAI,EAAE;EACP;AACD,CAAC,CAAC","ignoreList":[]}
|
|
@@ -12,9 +12,9 @@ var _constants = require("../../../constants");
|
|
|
12
12
|
var _gestures = require("../../../providers/gestures");
|
|
13
13
|
var _descriptors = require("../../../providers/screen/descriptors");
|
|
14
14
|
var _styles = require("../../../providers/screen/styles.provider");
|
|
15
|
-
var
|
|
16
|
-
var _animateToProgress = require("../../../utils/animation/animate-to-progress");
|
|
15
|
+
var _resolveScreenTransitionOptions = require("../../../utils/resolve-screen-transition-options");
|
|
17
16
|
var _useBackdropPointerEvents = require("../hooks/use-backdrop-pointer-events");
|
|
17
|
+
var _useContentLayout = require("../hooks/use-content-layout");
|
|
18
18
|
var _maybeMaskedNavigationContainer = require("./maybe-masked-navigation-container");
|
|
19
19
|
var _surfaceContainer = require("./surface-container");
|
|
20
20
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
@@ -30,81 +30,65 @@ const ContentLayer = exports.ContentLayer = /*#__PURE__*/(0, _react.memo)(({
|
|
|
30
30
|
const {
|
|
31
31
|
current
|
|
32
32
|
} = (0, _descriptors.useDescriptors)();
|
|
33
|
-
const {
|
|
34
|
-
isFirstKey
|
|
35
|
-
} = (0, _descriptors.useDescriptorDerivations)();
|
|
36
33
|
const {
|
|
37
34
|
pointerEvents,
|
|
38
35
|
isBackdropActive
|
|
39
36
|
} = (0, _useBackdropPointerEvents.useBackdropPointerEvents)();
|
|
40
37
|
const gestureContext = (0, _gestures.useGestureContext)();
|
|
41
|
-
const
|
|
42
|
-
height: screenHeight
|
|
43
|
-
} = (0, _reactNative.useWindowDimensions)();
|
|
44
|
-
const isNavigationMaskEnabled = !!current.options.maskEnabled;
|
|
38
|
+
const isNavigationMaskEnabled = (0, _resolveScreenTransitionOptions.resolveNavigationMaskEnabled)(current.options);
|
|
45
39
|
const contentPointerEvents = isBackdropActive ? "box-none" : pointerEvents;
|
|
46
|
-
const routeKey = current.route.key;
|
|
47
|
-
const animations = _animation.AnimationStore.getRouteAnimations(routeKey);
|
|
48
|
-
const autoSnapPointValue = _animation.AnimationStore.getAnimation(routeKey, "autoSnapPoint");
|
|
49
40
|
const hasAutoSnapPoint = current.options.snapPoints?.includes("auto") ?? false;
|
|
41
|
+
const handleContentLayout = (0, _useContentLayout.useContentLayout)();
|
|
50
42
|
const animatedContentStyle = (0, _reactNativeReanimated.useAnimatedStyle)(() => {
|
|
51
43
|
"worklet";
|
|
52
44
|
|
|
53
45
|
return stylesMap.value.content?.style || _constants.NO_STYLES;
|
|
54
46
|
});
|
|
47
|
+
const animatedNavigationContainerStyle = (0, _reactNativeReanimated.useAnimatedStyle)(() => {
|
|
48
|
+
"worklet";
|
|
49
|
+
|
|
50
|
+
return stylesMap.value[_constants.NAVIGATION_MASK_CONTAINER_STYLE_ID]?.style || _constants.NO_STYLES;
|
|
51
|
+
});
|
|
55
52
|
const animatedContentProps = (0, _reactNativeReanimated.useAnimatedProps)(() => {
|
|
56
53
|
"worklet";
|
|
57
54
|
|
|
58
55
|
return stylesMap.value.content?.props ?? _constants.NO_PROPS;
|
|
59
56
|
});
|
|
60
|
-
const
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
target: nextFraction,
|
|
80
|
-
spec,
|
|
81
|
-
animations
|
|
82
|
-
});
|
|
83
|
-
})(fraction, isFirstKey, transitionSpec);
|
|
84
|
-
}, [animations, autoSnapPointValue, current.options.transitionSpec, isFirstKey, screenHeight]);
|
|
57
|
+
const surfaceChildren = /*#__PURE__*/(0, _jsxRuntime.jsx)(_surfaceContainer.SurfaceContainer, {
|
|
58
|
+
pointerEvents: contentPointerEvents,
|
|
59
|
+
children: hasAutoSnapPoint ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
60
|
+
collapsable: false,
|
|
61
|
+
onLayout: handleContentLayout,
|
|
62
|
+
children: children
|
|
63
|
+
}) : children
|
|
64
|
+
});
|
|
65
|
+
const navigationContainer = /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeReanimated.default.View, {
|
|
66
|
+
style: [styles.navigationContainer, animatedNavigationContainerStyle],
|
|
67
|
+
pointerEvents: contentPointerEvents,
|
|
68
|
+
collapsable: false,
|
|
69
|
+
children: surfaceChildren
|
|
70
|
+
});
|
|
71
|
+
const navigationScopedChildren = isNavigationMaskEnabled ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_maybeMaskedNavigationContainer.MaybeMaskedNavigationContainer, {
|
|
72
|
+
pointerEvents: contentPointerEvents,
|
|
73
|
+
enabled: isNavigationMaskEnabled,
|
|
74
|
+
children: navigationContainer
|
|
75
|
+
}) : navigationContainer;
|
|
85
76
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeGestureHandler.GestureDetector, {
|
|
86
77
|
gesture: gestureContext.panGesture,
|
|
87
78
|
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeReanimated.default.View, {
|
|
88
79
|
style: [styles.content, animatedContentStyle],
|
|
89
80
|
animatedProps: animatedContentProps,
|
|
90
81
|
pointerEvents: contentPointerEvents,
|
|
91
|
-
children:
|
|
92
|
-
enabled: isNavigationMaskEnabled,
|
|
93
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_surfaceContainer.SurfaceContainer, {
|
|
94
|
-
pointerEvents: contentPointerEvents,
|
|
95
|
-
children: hasAutoSnapPoint ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
96
|
-
collapsable: false,
|
|
97
|
-
onLayout: handleContentLayout,
|
|
98
|
-
children: children
|
|
99
|
-
}) : children
|
|
100
|
-
})
|
|
101
|
-
})
|
|
82
|
+
children: navigationScopedChildren
|
|
102
83
|
})
|
|
103
84
|
});
|
|
104
85
|
});
|
|
105
86
|
const styles = _reactNative.StyleSheet.create({
|
|
106
87
|
content: {
|
|
107
88
|
flex: 1
|
|
89
|
+
},
|
|
90
|
+
navigationContainer: {
|
|
91
|
+
flex: 1
|
|
108
92
|
}
|
|
109
93
|
});
|
|
110
94
|
//# sourceMappingURL=content.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_react","require","_reactNative","_reactNativeGestureHandler","_reactNativeReanimated","_interopRequireWildcard","_constants","_gestures","_descriptors","_styles","
|
|
1
|
+
{"version":3,"names":["_react","require","_reactNative","_reactNativeGestureHandler","_reactNativeReanimated","_interopRequireWildcard","_constants","_gestures","_descriptors","_styles","_resolveScreenTransitionOptions","_useBackdropPointerEvents","_useContentLayout","_maybeMaskedNavigationContainer","_surfaceContainer","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","ContentLayer","exports","memo","children","stylesMap","useScreenStyles","current","useDescriptors","pointerEvents","isBackdropActive","useBackdropPointerEvents","gestureContext","useGestureContext","isNavigationMaskEnabled","resolveNavigationMaskEnabled","options","contentPointerEvents","hasAutoSnapPoint","snapPoints","includes","handleContentLayout","useContentLayout","animatedContentStyle","useAnimatedStyle","value","content","style","NO_STYLES","animatedNavigationContainerStyle","NAVIGATION_MASK_CONTAINER_STYLE_ID","animatedContentProps","useAnimatedProps","props","NO_PROPS","surfaceChildren","jsx","SurfaceContainer","View","collapsable","onLayout","navigationContainer","styles","navigationScopedChildren","MaybeMaskedNavigationContainer","enabled","GestureDetector","gesture","panGesture","animatedProps","StyleSheet","create","flex"],"sourceRoot":"../../../../../../src","sources":["shared/components/screen-container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;MAC9C0B,aAAa,EAAElB,oBAAqB;MACpCtB,aAAa,EAAEQ,oBAAqB;MAAAb,QAAA,EAEnCuC;IAAwB,CACX;EAAC,CACA,CAAC;AAEpB,CAAC,CAAC;AAEF,MAAMD,MAAM,GAAGQ,uBAAU,CAACC,MAAM,CAAC;EAChCzB,OAAO,EAAE;IACR0B,IAAI,EAAE;EACP,CAAC;EACDX,mBAAmB,EAAE;IACpBW,IAAI,EAAE;EACP;AACD,CAAC,CAAC","ignoreList":[]}
|
package/lib/commonjs/shared/components/screen-container/layers/maybe-masked-navigation-container.js
CHANGED
|
@@ -21,46 +21,38 @@ try {
|
|
|
21
21
|
let hasWarnedMissingMaskedView = false;
|
|
22
22
|
const MaybeMaskedNavigationContainer = exports.MaybeMaskedNavigationContainer = /*#__PURE__*/(0, _react.memo)(({
|
|
23
23
|
enabled,
|
|
24
|
-
children
|
|
24
|
+
children,
|
|
25
|
+
pointerEvents
|
|
25
26
|
}) => {
|
|
26
27
|
const {
|
|
27
28
|
stylesMap
|
|
28
29
|
} = (0, _styles.useScreenStyles)();
|
|
29
|
-
const animatedNavigationContainerStyle = (0, _reactNativeReanimated.useAnimatedStyle)(() => {
|
|
30
|
-
"worklet";
|
|
31
|
-
|
|
32
|
-
return stylesMap.value[_constants.NAVIGATION_CONTAINER_STYLE_ID]?.style || _constants.NO_STYLES;
|
|
33
|
-
});
|
|
34
30
|
const animatedNavigationMaskStyle = (0, _reactNativeReanimated.useAnimatedStyle)(() => {
|
|
35
31
|
"worklet";
|
|
36
32
|
|
|
37
|
-
return stylesMap.value[_constants.
|
|
33
|
+
return stylesMap.value[_constants.NAVIGATION_MASK_ELEMENT_STYLE_ID]?.style || _constants.NO_STYLES;
|
|
38
34
|
});
|
|
39
35
|
(0, _react.useEffect)(() => {
|
|
40
36
|
if (!enabled) return;
|
|
41
37
|
if (LazyMaskedView !== _reactNative.View) return;
|
|
42
38
|
if (hasWarnedMissingMaskedView) return;
|
|
43
39
|
hasWarnedMissingMaskedView = true;
|
|
44
|
-
_logger.logger.warn("
|
|
40
|
+
_logger.logger.warn("navigationMaskEnabled requires @react-native-masked-view/masked-view. Install it to enable navigation bounds masking.");
|
|
45
41
|
}, [enabled]);
|
|
46
42
|
if (!enabled) return children;
|
|
47
43
|
if (LazyMaskedView === _reactNative.View) {
|
|
48
|
-
return
|
|
49
|
-
style: [styles.navigationContainer, animatedNavigationContainerStyle],
|
|
50
|
-
children: children
|
|
51
|
-
});
|
|
44
|
+
return children;
|
|
52
45
|
}
|
|
53
46
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(LazyMaskedView, {
|
|
54
47
|
style: styles.navigationMaskedRoot
|
|
55
48
|
// @ts-expect-error masked-view package types are too strict here
|
|
56
49
|
,
|
|
57
50
|
maskElement: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeReanimated.default.View, {
|
|
58
|
-
style: [styles.navigationMaskElement, animatedNavigationMaskStyle]
|
|
51
|
+
style: [styles.navigationMaskElement, animatedNavigationMaskStyle],
|
|
52
|
+
pointerEvents: "none"
|
|
59
53
|
}),
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
children: children
|
|
63
|
-
})
|
|
54
|
+
pointerEvents: pointerEvents,
|
|
55
|
+
children: children
|
|
64
56
|
});
|
|
65
57
|
});
|
|
66
58
|
const styles = _reactNative.StyleSheet.create({
|
|
@@ -69,9 +61,6 @@ const styles = _reactNative.StyleSheet.create({
|
|
|
69
61
|
},
|
|
70
62
|
navigationMaskElement: {
|
|
71
63
|
backgroundColor: "white"
|
|
72
|
-
},
|
|
73
|
-
navigationContainer: {
|
|
74
|
-
flex: 1
|
|
75
64
|
}
|
|
76
65
|
});
|
|
77
66
|
//# sourceMappingURL=maybe-masked-navigation-container.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_react","require","_reactNative","_reactNativeReanimated","_interopRequireWildcard","_constants","_styles","_logger","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","LazyMaskedView","View","_","hasWarnedMissingMaskedView","MaybeMaskedNavigationContainer","exports","memo","enabled","children","stylesMap","useScreenStyles","
|
|
1
|
+
{"version":3,"names":["_react","require","_reactNative","_reactNativeReanimated","_interopRequireWildcard","_constants","_styles","_logger","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","LazyMaskedView","View","_","hasWarnedMissingMaskedView","MaybeMaskedNavigationContainer","exports","memo","enabled","children","pointerEvents","stylesMap","useScreenStyles","animatedNavigationMaskStyle","useAnimatedStyle","value","NAVIGATION_MASK_ELEMENT_STYLE_ID","style","NO_STYLES","useEffect","logger","warn","jsx","styles","navigationMaskedRoot","maskElement","navigationMaskElement","StyleSheet","create","flex","backgroundColor"],"sourceRoot":"../../../../../../src","sources":["shared/components/screen-container/layers/maybe-masked-navigation-container.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,sBAAA,GAAAC,uBAAA,CAAAH,OAAA;AACA,IAAAI,UAAA,GAAAJ,OAAA;AAIA,IAAAK,OAAA,GAAAL,OAAA;AACA,IAAAM,OAAA,GAAAN,OAAA;AAA+C,IAAAO,WAAA,GAAAP,OAAA;AAAA,SAAAG,wBAAAK,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAP,uBAAA,YAAAA,CAAAK,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,EAAAV,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,SAAAQ,CAAA,MAA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,iBAAI,EAAE;IAC7B,IAAIE,0BAA0B,EAAE;IAEhCA,0BAA0B,GAAG,IAAI;IACjCgB,cAAM,CAACC,IAAI,CACV,uHACD,CAAC;EACF,CAAC,EAAE,CAACb,OAAO,CAAC,CAAC;EACb,IAAI,CAACA,OAAO,EAAE,OAAOC,QAAQ;EAE7B,IAAIR,cAAc,KAAKC,iBAAI,EAAE;IAC5B,OAAOO,QAAQ;EAChB;EAEA,oBACC,IAAA5B,WAAA,CAAAyC,GAAA,EAACrB,cAAc;IACdgB,KAAK,EAAEM,MAAM,CAACC;IACd;IAAA;IACAC,WAAW,eACV,IAAA5C,WAAA,CAAAyC,GAAA,EAAC9C,sBAAA,CAAAgB,OAAQ,CAACU,IAAI;MACbe,KAAK,EAAE,CAACM,MAAM,CAACG,qBAAqB,EAAEb,2BAA2B,CAAE;MACnEH,aAAa,EAAC;IAAM,CACpB,CACD;IACDA,aAAa,EAAEA,aAAc;IAAAD,QAAA,EAE5BA;EAAQ,CACM,CAAC;AAEnB,CACD,CAAC;AAED,MAAMc,MAAM,GAAGI,uBAAU,CAACC,MAAM,CAAC;EAChCJ,oBAAoB,EAAE;IACrBK,IAAI,EAAE;EACP,CAAC;EACDH,qBAAqB,EAAE;IACtBI,eAAe,EAAE;EAClB;AACD,CAAC,CAAC","ignoreList":[]}
|
|
@@ -263,8 +263,8 @@ const SharedIGImage = ({
|
|
|
263
263
|
|
|
264
264
|
// Extract raw style values from bounds result (legacy format)
|
|
265
265
|
const sourceStyle = navigationStyles[sharedBoundTag];
|
|
266
|
-
const containerStyle = navigationStyles[_constants.
|
|
267
|
-
const maskStyle = navigationStyles[_constants.
|
|
266
|
+
const containerStyle = navigationStyles[_constants.NAVIGATION_MASK_CONTAINER_STYLE_ID];
|
|
267
|
+
const maskStyle = navigationStyles[_constants.NAVIGATION_MASK_ELEMENT_STYLE_ID];
|
|
268
268
|
|
|
269
269
|
// Normalize bounds result to new slot format for spreading
|
|
270
270
|
const normalizedNav = (0, _normalizeInterpolatedStyle.normalizeInterpolatedStyle)(navigationStyles).result;
|
|
@@ -290,7 +290,7 @@ const SharedIGImage = ({
|
|
|
290
290
|
}]
|
|
291
291
|
}
|
|
292
292
|
},
|
|
293
|
-
[_constants.
|
|
293
|
+
[_constants.NAVIGATION_MASK_CONTAINER_STYLE_ID]: containerStyle ? {
|
|
294
294
|
style: {
|
|
295
295
|
...containerStyle,
|
|
296
296
|
transform: [...(containerStyle.transform ?? []), {
|
|
@@ -300,7 +300,7 @@ const SharedIGImage = ({
|
|
|
300
300
|
}]
|
|
301
301
|
}
|
|
302
302
|
} : undefined,
|
|
303
|
-
[_constants.
|
|
303
|
+
[_constants.NAVIGATION_MASK_ELEMENT_STYLE_ID]: maskStyle ? {
|
|
304
304
|
style: {
|
|
305
305
|
...maskStyle,
|
|
306
306
|
borderRadius: (0, _reactNativeReanimated.interpolate)(progress, [0, 1], [0, 24])
|
|
@@ -572,7 +572,7 @@ const SharedXImage = ({
|
|
|
572
572
|
const navigationStyles = bounds({
|
|
573
573
|
id: sharedBoundTag
|
|
574
574
|
}).navigation.zoom();
|
|
575
|
-
const maskStyle = navigationStyles[_constants.
|
|
575
|
+
const maskStyle = navigationStyles[_constants.NAVIGATION_MASK_ELEMENT_STYLE_ID];
|
|
576
576
|
|
|
577
577
|
// Normalize bounds result to new slot format for spreading
|
|
578
578
|
const normalizedNav = (0, _normalizeInterpolatedStyle.normalizeInterpolatedStyle)(navigationStyles).result;
|
|
@@ -582,7 +582,7 @@ const SharedXImage = ({
|
|
|
582
582
|
const borderRadius = (0, _reactNativeReanimated.interpolate)(current.progress, [0, 1], [12, 0]);
|
|
583
583
|
return {
|
|
584
584
|
...normalizedNav,
|
|
585
|
-
[_constants.
|
|
585
|
+
[_constants.NAVIGATION_MASK_ELEMENT_STYLE_ID]: maskStyle ? {
|
|
586
586
|
style: {
|
|
587
587
|
...maskStyle,
|
|
588
588
|
borderRadius
|