react-native-screen-transitions 3.11.3 → 3.13.0-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/commonjs/blank-stack/components/stack-view.js +1 -2
- package/lib/commonjs/blank-stack/components/stack-view.js.map +1 -1
- package/lib/commonjs/component-stack/components/stack-view.js +1 -2
- package/lib/commonjs/component-stack/components/stack-view.js.map +1 -1
- package/lib/commonjs/native-stack/views/NativeStackView.native.js +2 -3
- package/lib/commonjs/native-stack/views/NativeStackView.native.js.map +1 -1
- package/lib/commonjs/shared/adapters/with-screen-transitions/stack-layout.js +1 -1
- package/lib/commonjs/shared/adapters/with-screen-transitions/stack-layout.js.map +1 -1
- package/lib/commonjs/shared/components/activity/variants/activity-screen.js +1 -1
- package/lib/commonjs/shared/components/activity/variants/activity-screen.js.map +1 -1
- package/lib/commonjs/shared/components/boundary/components/boundary-lifecycle.js +0 -3
- package/lib/commonjs/shared/components/boundary/components/boundary-lifecycle.js.map +1 -1
- package/lib/commonjs/shared/components/boundary/hooks/lifecycles/use-boundary-measurement-request.js +69 -0
- package/lib/commonjs/shared/components/boundary/hooks/lifecycles/use-boundary-measurement-request.js.map +1 -0
- package/lib/commonjs/shared/components/boundary/hooks/lifecycles/use-boundary-presence.js +11 -10
- package/lib/commonjs/shared/components/boundary/hooks/lifecycles/use-boundary-presence.js.map +1 -1
- package/lib/commonjs/shared/components/boundary/hooks/use-boundary-measurement.js +3 -19
- package/lib/commonjs/shared/components/boundary/hooks/use-boundary-measurement.js.map +1 -1
- package/lib/commonjs/shared/components/boundary/hooks/use-measurer.js +6 -16
- package/lib/commonjs/shared/components/boundary/hooks/use-measurer.js.map +1 -1
- package/lib/commonjs/shared/components/boundary/portal/components/boundary-content-portal/helpers/active-handoff-receiver.js +27 -1
- package/lib/commonjs/shared/components/boundary/portal/components/boundary-content-portal/helpers/active-handoff-receiver.js.map +1 -1
- package/lib/commonjs/shared/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.js +32 -11
- package/lib/commonjs/shared/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.js.map +1 -1
- package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/components/portal-boundary-host.js +8 -1
- package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/components/portal-boundary-host.js.map +1 -1
- package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/helpers/attachment.js +19 -0
- package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/helpers/attachment.js.map +1 -0
- package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/helpers/host-readiness.js +18 -0
- package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/helpers/host-readiness.js.map +1 -0
- package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/helpers/local-measurement.js +22 -1
- package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/helpers/local-measurement.js.map +1 -1
- package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/hooks/use-active-portal-boundary-host.js +10 -10
- package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/hooks/use-active-portal-boundary-host.js.map +1 -1
- package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.js +18 -6
- package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.js.map +1 -1
- package/lib/commonjs/shared/components/overlay/helpers/create-overlay-interpolator-frame.js +30 -0
- package/lib/commonjs/shared/components/overlay/helpers/create-overlay-interpolator-frame.js.map +1 -0
- package/lib/commonjs/shared/components/overlay/helpers/get-active-overlay.js +40 -22
- package/lib/commonjs/shared/components/overlay/helpers/get-active-overlay.js.map +1 -1
- package/lib/commonjs/shared/components/overlay/helpers/retain-ready-overlay-resources.js +21 -0
- package/lib/commonjs/shared/components/overlay/helpers/retain-ready-overlay-resources.js.map +1 -0
- package/lib/commonjs/shared/components/overlay/helpers/run-overlay-slot-interpolator.js +41 -0
- package/lib/commonjs/shared/components/overlay/helpers/run-overlay-slot-interpolator.js.map +1 -0
- package/lib/commonjs/shared/components/overlay/hooks/use-overlay-slot.js +85 -0
- package/lib/commonjs/shared/components/overlay/hooks/use-overlay-slot.js.map +1 -0
- package/lib/commonjs/shared/components/overlay/variations/float-overlay.js +14 -65
- package/lib/commonjs/shared/components/overlay/variations/float-overlay.js.map +1 -1
- package/lib/commonjs/shared/components/overlay/variations/overlay-host.js +89 -16
- package/lib/commonjs/shared/components/overlay/variations/overlay-host.js.map +1 -1
- package/lib/commonjs/shared/components/screen-lifecycle/hooks/use-close-transition-intent.js +4 -1
- package/lib/commonjs/shared/components/screen-lifecycle/hooks/use-close-transition-intent.js.map +1 -1
- package/lib/commonjs/shared/providers/helpers/measured-bounds-writes.js +4 -0
- package/lib/commonjs/shared/providers/helpers/measured-bounds-writes.js.map +1 -1
- package/lib/commonjs/shared/providers/screen/animation/animation.provider.js +14 -8
- package/lib/commonjs/shared/providers/screen/animation/animation.provider.js.map +1 -1
- package/lib/commonjs/shared/providers/screen/animation/helpers/accessors/use-build-transition-accessor.js +6 -8
- package/lib/commonjs/shared/providers/screen/animation/helpers/accessors/use-build-transition-accessor.js.map +1 -1
- package/lib/commonjs/shared/providers/screen/animation/helpers/hydrate-transition-state/index.js +5 -1
- package/lib/commonjs/shared/providers/screen/animation/helpers/hydrate-transition-state/index.js.map +1 -1
- package/lib/commonjs/shared/providers/screen/animation/helpers/interpolator-participation.js +9 -0
- package/lib/commonjs/shared/providers/screen/animation/helpers/interpolator-participation.js.map +1 -0
- package/lib/commonjs/shared/providers/screen/animation/helpers/pipeline.js +13 -2
- package/lib/commonjs/shared/providers/screen/animation/helpers/pipeline.js.map +1 -1
- package/lib/commonjs/shared/providers/screen/animation/use-screen-animation.js +8 -2
- package/lib/commonjs/shared/providers/screen/animation/use-screen-animation.js.map +1 -1
- package/lib/commonjs/shared/providers/screen/descriptors/descriptors.provider.js +40 -8
- package/lib/commonjs/shared/providers/screen/descriptors/descriptors.provider.js.map +1 -1
- package/lib/commonjs/shared/providers/screen/descriptors/helpers/derive-descriptor-derivations.js +2 -0
- package/lib/commonjs/shared/providers/screen/descriptors/helpers/derive-descriptor-derivations.js.map +1 -1
- package/lib/commonjs/shared/providers/screen/descriptors/helpers/derive-structural-ancestor-keys.js +12 -0
- package/lib/commonjs/shared/providers/screen/descriptors/helpers/derive-structural-ancestor-keys.js.map +1 -0
- package/lib/commonjs/shared/providers/screen/gestures/gestures.provider.js +9 -5
- package/lib/commonjs/shared/providers/screen/gestures/gestures.provider.js.map +1 -1
- package/lib/commonjs/shared/providers/screen/gestures/hooks/use-screen-gesture-config.js +1 -3
- package/lib/commonjs/shared/providers/screen/gestures/hooks/use-screen-gesture-config.js.map +1 -1
- package/lib/commonjs/shared/providers/screen/gestures/ownership/{use-walk-up-and-register-shadowing-claims.js → gesture-ownership-bridge.js} +36 -50
- package/lib/commonjs/shared/providers/screen/gestures/ownership/gesture-ownership-bridge.js.map +1 -0
- package/lib/commonjs/shared/providers/screen/gestures/pan/behavior/pan-lifecycle.js +1 -0
- package/lib/commonjs/shared/providers/screen/gestures/pan/behavior/pan-lifecycle.js.map +1 -1
- package/lib/commonjs/shared/providers/screen/gestures/pan/behavior/pan-release.js +9 -2
- package/lib/commonjs/shared/providers/screen/gestures/pan/behavior/pan-release.js.map +1 -1
- package/lib/commonjs/shared/providers/screen/gestures/pan/behavior/use-pan-behavior.js +1 -0
- package/lib/commonjs/shared/providers/screen/gestures/pan/behavior/use-pan-behavior.js.map +1 -1
- package/lib/commonjs/shared/providers/screen/styles/constants.js +3 -1
- package/lib/commonjs/shared/providers/screen/styles/constants.js.map +1 -1
- package/lib/commonjs/shared/providers/screen/styles/helpers/transition-visual-state.js +20 -1
- package/lib/commonjs/shared/providers/screen/styles/helpers/transition-visual-state.js.map +1 -1
- package/lib/commonjs/shared/providers/screen/styles/helpers/visibility-block-ownership.js +19 -0
- package/lib/commonjs/shared/providers/screen/styles/helpers/visibility-block-ownership.js.map +1 -0
- package/lib/commonjs/shared/providers/screen/styles/hooks/slot-resolvers.js +14 -15
- package/lib/commonjs/shared/providers/screen/styles/hooks/slot-resolvers.js.map +1 -1
- package/lib/commonjs/shared/providers/screen/styles/hooks/use-interpolated-style-maps.js +34 -11
- package/lib/commonjs/shared/providers/screen/styles/hooks/use-interpolated-style-maps.js.map +1 -1
- package/lib/commonjs/shared/providers/screen/styles/hooks/use-maybe-block-visibility.js +35 -15
- package/lib/commonjs/shared/providers/screen/styles/hooks/use-maybe-block-visibility.js.map +1 -1
- package/lib/commonjs/shared/providers/screen/styles/slot.provider.js +31 -33
- package/lib/commonjs/shared/providers/screen/styles/slot.provider.js.map +1 -1
- package/lib/commonjs/shared/providers/stack/blank-stack-state/helpers/resolve-presented-index.js +18 -0
- package/lib/commonjs/shared/providers/stack/blank-stack-state/helpers/resolve-presented-index.js.map +1 -0
- package/lib/commonjs/shared/providers/stack/blank-stack.provider.js +2 -1
- package/lib/commonjs/shared/providers/stack/blank-stack.provider.js.map +1 -1
- package/lib/commonjs/shared/stores/bounds/helpers/link-pairs.helpers.js +11 -1
- package/lib/commonjs/shared/stores/bounds/helpers/link-pairs.helpers.js.map +1 -1
- package/lib/commonjs/shared/stores/bounds/internals/clear.js +6 -0
- package/lib/commonjs/shared/stores/bounds/internals/clear.js.map +1 -1
- package/lib/commonjs/shared/stores/bounds/internals/coordinator.js +298 -0
- package/lib/commonjs/shared/stores/bounds/internals/coordinator.js.map +1 -0
- package/lib/commonjs/shared/stores/bounds/internals/entries.js +0 -27
- package/lib/commonjs/shared/stores/bounds/internals/entries.js.map +1 -1
- package/lib/commonjs/shared/stores/bounds/internals/links.js +22 -32
- package/lib/commonjs/shared/stores/bounds/internals/links.js.map +1 -1
- package/lib/commonjs/shared/stores/bounds/internals/screen-graph.js +45 -0
- package/lib/commonjs/shared/stores/bounds/internals/screen-graph.js.map +1 -0
- package/lib/commonjs/shared/stores/bounds/internals/state.js +4 -1
- package/lib/commonjs/shared/stores/bounds/internals/state.js.map +1 -1
- package/lib/commonjs/shared/utils/bounds/helpers/create-bounds-accessor-core.js +7 -3
- package/lib/commonjs/shared/utils/bounds/helpers/create-bounds-accessor-core.js.map +1 -1
- package/lib/commonjs/shared/utils/bounds/helpers/create-link-accessor.js +11 -0
- package/lib/commonjs/shared/utils/bounds/helpers/create-link-accessor.js.map +1 -1
- package/lib/commonjs/shared/utils/bounds/helpers/prepare-bound-styles.js +6 -2
- package/lib/commonjs/shared/utils/bounds/helpers/prepare-bound-styles.js.map +1 -1
- package/lib/commonjs/shared/utils/bounds/helpers/resolve-bounds-pair-key.js.map +1 -1
- package/lib/commonjs/shared/utils/bounds/helpers/styles/compute.js +11 -5
- package/lib/commonjs/shared/utils/bounds/helpers/styles/compute.js.map +1 -1
- package/lib/commonjs/shared/utils/create-provider.js +119 -10
- package/lib/commonjs/shared/utils/create-provider.js.map +1 -1
- package/lib/module/blank-stack/components/stack-view.js +1 -2
- package/lib/module/blank-stack/components/stack-view.js.map +1 -1
- package/lib/module/component-stack/components/stack-view.js +1 -2
- package/lib/module/component-stack/components/stack-view.js.map +1 -1
- package/lib/module/native-stack/views/NativeStackView.native.js +2 -3
- package/lib/module/native-stack/views/NativeStackView.native.js.map +1 -1
- package/lib/module/shared/adapters/with-screen-transitions/stack-layout.js +1 -1
- package/lib/module/shared/adapters/with-screen-transitions/stack-layout.js.map +1 -1
- package/lib/module/shared/components/activity/variants/activity-screen.js +1 -1
- package/lib/module/shared/components/activity/variants/activity-screen.js.map +1 -1
- package/lib/module/shared/components/boundary/components/boundary-lifecycle.js +0 -3
- package/lib/module/shared/components/boundary/components/boundary-lifecycle.js.map +1 -1
- package/lib/module/shared/components/boundary/hooks/lifecycles/use-boundary-measurement-request.js +64 -0
- package/lib/module/shared/components/boundary/hooks/lifecycles/use-boundary-measurement-request.js.map +1 -0
- package/lib/module/shared/components/boundary/hooks/lifecycles/use-boundary-presence.js +11 -10
- package/lib/module/shared/components/boundary/hooks/lifecycles/use-boundary-presence.js.map +1 -1
- package/lib/module/shared/components/boundary/hooks/use-boundary-measurement.js +3 -19
- package/lib/module/shared/components/boundary/hooks/use-boundary-measurement.js.map +1 -1
- package/lib/module/shared/components/boundary/hooks/use-measurer.js +6 -16
- package/lib/module/shared/components/boundary/hooks/use-measurer.js.map +1 -1
- package/lib/module/shared/components/boundary/portal/components/boundary-content-portal/helpers/active-handoff-receiver.js +24 -0
- package/lib/module/shared/components/boundary/portal/components/boundary-content-portal/helpers/active-handoff-receiver.js.map +1 -1
- package/lib/module/shared/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.js +33 -12
- package/lib/module/shared/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.js.map +1 -1
- package/lib/module/shared/components/boundary/portal/components/boundary-portal/components/portal-boundary-host.js +8 -1
- package/lib/module/shared/components/boundary/portal/components/boundary-portal/components/portal-boundary-host.js.map +1 -1
- package/lib/module/shared/components/boundary/portal/components/boundary-portal/helpers/attachment.js +14 -0
- package/lib/module/shared/components/boundary/portal/components/boundary-portal/helpers/attachment.js.map +1 -0
- package/lib/module/shared/components/boundary/portal/components/boundary-portal/helpers/host-readiness.js +13 -0
- package/lib/module/shared/components/boundary/portal/components/boundary-portal/helpers/host-readiness.js.map +1 -0
- package/lib/module/shared/components/boundary/portal/components/boundary-portal/helpers/local-measurement.js +19 -0
- package/lib/module/shared/components/boundary/portal/components/boundary-portal/helpers/local-measurement.js.map +1 -1
- package/lib/module/shared/components/boundary/portal/components/boundary-portal/hooks/use-active-portal-boundary-host.js +10 -10
- package/lib/module/shared/components/boundary/portal/components/boundary-portal/hooks/use-active-portal-boundary-host.js.map +1 -1
- package/lib/module/shared/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.js +18 -6
- package/lib/module/shared/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.js.map +1 -1
- package/lib/module/shared/components/overlay/helpers/create-overlay-interpolator-frame.js +25 -0
- package/lib/module/shared/components/overlay/helpers/create-overlay-interpolator-frame.js.map +1 -0
- package/lib/module/shared/components/overlay/helpers/get-active-overlay.js +37 -21
- package/lib/module/shared/components/overlay/helpers/get-active-overlay.js.map +1 -1
- package/lib/module/shared/components/overlay/helpers/retain-ready-overlay-resources.js +17 -0
- package/lib/module/shared/components/overlay/helpers/retain-ready-overlay-resources.js.map +1 -0
- package/lib/module/shared/components/overlay/helpers/run-overlay-slot-interpolator.js +36 -0
- package/lib/module/shared/components/overlay/helpers/run-overlay-slot-interpolator.js.map +1 -0
- package/lib/module/shared/components/overlay/hooks/use-overlay-slot.js +80 -0
- package/lib/module/shared/components/overlay/hooks/use-overlay-slot.js.map +1 -0
- package/lib/module/shared/components/overlay/variations/float-overlay.js +15 -66
- package/lib/module/shared/components/overlay/variations/float-overlay.js.map +1 -1
- package/lib/module/shared/components/overlay/variations/overlay-host.js +90 -18
- package/lib/module/shared/components/overlay/variations/overlay-host.js.map +1 -1
- package/lib/module/shared/components/screen-lifecycle/hooks/use-close-transition-intent.js +4 -1
- package/lib/module/shared/components/screen-lifecycle/hooks/use-close-transition-intent.js.map +1 -1
- package/lib/module/shared/providers/helpers/measured-bounds-writes.js +4 -0
- package/lib/module/shared/providers/helpers/measured-bounds-writes.js.map +1 -1
- package/lib/module/shared/providers/screen/animation/animation.provider.js +14 -8
- package/lib/module/shared/providers/screen/animation/animation.provider.js.map +1 -1
- package/lib/module/shared/providers/screen/animation/helpers/accessors/use-build-transition-accessor.js +6 -8
- package/lib/module/shared/providers/screen/animation/helpers/accessors/use-build-transition-accessor.js.map +1 -1
- package/lib/module/shared/providers/screen/animation/helpers/hydrate-transition-state/index.js +5 -1
- package/lib/module/shared/providers/screen/animation/helpers/hydrate-transition-state/index.js.map +1 -1
- package/lib/module/shared/providers/screen/animation/helpers/interpolator-participation.js +4 -0
- package/lib/module/shared/providers/screen/animation/helpers/interpolator-participation.js.map +1 -0
- package/lib/module/shared/providers/screen/animation/helpers/pipeline.js +13 -2
- package/lib/module/shared/providers/screen/animation/helpers/pipeline.js.map +1 -1
- package/lib/module/shared/providers/screen/animation/use-screen-animation.js +8 -2
- package/lib/module/shared/providers/screen/animation/use-screen-animation.js.map +1 -1
- package/lib/module/shared/providers/screen/descriptors/descriptors.provider.js +41 -9
- package/lib/module/shared/providers/screen/descriptors/descriptors.provider.js.map +1 -1
- package/lib/module/shared/providers/screen/descriptors/helpers/derive-descriptor-derivations.js +2 -0
- package/lib/module/shared/providers/screen/descriptors/helpers/derive-descriptor-derivations.js.map +1 -1
- package/lib/module/shared/providers/screen/descriptors/helpers/derive-structural-ancestor-keys.js +7 -0
- package/lib/module/shared/providers/screen/descriptors/helpers/derive-structural-ancestor-keys.js.map +1 -0
- package/lib/module/shared/providers/screen/gestures/gestures.provider.js +10 -6
- package/lib/module/shared/providers/screen/gestures/gestures.provider.js.map +1 -1
- package/lib/module/shared/providers/screen/gestures/hooks/use-screen-gesture-config.js +1 -3
- package/lib/module/shared/providers/screen/gestures/hooks/use-screen-gesture-config.js.map +1 -1
- package/lib/module/shared/providers/screen/gestures/ownership/{use-walk-up-and-register-shadowing-claims.js → gesture-ownership-bridge.js} +35 -49
- package/lib/module/shared/providers/screen/gestures/ownership/gesture-ownership-bridge.js.map +1 -0
- package/lib/module/shared/providers/screen/gestures/pan/behavior/pan-lifecycle.js +1 -0
- package/lib/module/shared/providers/screen/gestures/pan/behavior/pan-lifecycle.js.map +1 -1
- package/lib/module/shared/providers/screen/gestures/pan/behavior/pan-release.js +9 -2
- package/lib/module/shared/providers/screen/gestures/pan/behavior/pan-release.js.map +1 -1
- package/lib/module/shared/providers/screen/gestures/pan/behavior/use-pan-behavior.js +1 -0
- package/lib/module/shared/providers/screen/gestures/pan/behavior/use-pan-behavior.js.map +1 -1
- package/lib/module/shared/providers/screen/styles/constants.js +3 -1
- package/lib/module/shared/providers/screen/styles/constants.js.map +1 -1
- package/lib/module/shared/providers/screen/styles/helpers/transition-visual-state.js +18 -0
- package/lib/module/shared/providers/screen/styles/helpers/transition-visual-state.js.map +1 -1
- package/lib/module/shared/providers/screen/styles/helpers/visibility-block-ownership.js +14 -0
- package/lib/module/shared/providers/screen/styles/helpers/visibility-block-ownership.js.map +1 -0
- package/lib/module/shared/providers/screen/styles/hooks/slot-resolvers.js +14 -15
- package/lib/module/shared/providers/screen/styles/hooks/slot-resolvers.js.map +1 -1
- package/lib/module/shared/providers/screen/styles/hooks/use-interpolated-style-maps.js +35 -12
- package/lib/module/shared/providers/screen/styles/hooks/use-interpolated-style-maps.js.map +1 -1
- package/lib/module/shared/providers/screen/styles/hooks/use-maybe-block-visibility.js +35 -15
- package/lib/module/shared/providers/screen/styles/hooks/use-maybe-block-visibility.js.map +1 -1
- package/lib/module/shared/providers/screen/styles/slot.provider.js +30 -33
- package/lib/module/shared/providers/screen/styles/slot.provider.js.map +1 -1
- package/lib/module/shared/providers/stack/blank-stack-state/helpers/resolve-presented-index.js +14 -0
- package/lib/module/shared/providers/stack/blank-stack-state/helpers/resolve-presented-index.js.map +1 -0
- package/lib/module/shared/providers/stack/blank-stack.provider.js +2 -1
- package/lib/module/shared/providers/stack/blank-stack.provider.js.map +1 -1
- package/lib/module/shared/stores/bounds/helpers/link-pairs.helpers.js +9 -0
- package/lib/module/shared/stores/bounds/helpers/link-pairs.helpers.js.map +1 -1
- package/lib/module/shared/stores/bounds/internals/clear.js +7 -1
- package/lib/module/shared/stores/bounds/internals/clear.js.map +1 -1
- package/lib/module/shared/stores/bounds/internals/coordinator.js +286 -0
- package/lib/module/shared/stores/bounds/internals/coordinator.js.map +1 -0
- package/lib/module/shared/stores/bounds/internals/entries.js +1 -27
- package/lib/module/shared/stores/bounds/internals/entries.js.map +1 -1
- package/lib/module/shared/stores/bounds/internals/links.js +24 -32
- package/lib/module/shared/stores/bounds/internals/links.js.map +1 -1
- package/lib/module/shared/stores/bounds/internals/screen-graph.js +39 -0
- package/lib/module/shared/stores/bounds/internals/screen-graph.js.map +1 -0
- package/lib/module/shared/stores/bounds/internals/state.js +3 -0
- package/lib/module/shared/stores/bounds/internals/state.js.map +1 -1
- package/lib/module/shared/types/animation.types.js.map +1 -1
- package/lib/module/shared/utils/bounds/helpers/create-bounds-accessor-core.js +7 -3
- package/lib/module/shared/utils/bounds/helpers/create-bounds-accessor-core.js.map +1 -1
- package/lib/module/shared/utils/bounds/helpers/create-link-accessor.js +11 -0
- package/lib/module/shared/utils/bounds/helpers/create-link-accessor.js.map +1 -1
- package/lib/module/shared/utils/bounds/helpers/prepare-bound-styles.js +6 -2
- package/lib/module/shared/utils/bounds/helpers/prepare-bound-styles.js.map +1 -1
- package/lib/module/shared/utils/bounds/helpers/resolve-bounds-pair-key.js.map +1 -1
- package/lib/module/shared/utils/bounds/helpers/styles/compute.js +11 -5
- package/lib/module/shared/utils/bounds/helpers/styles/compute.js.map +1 -1
- package/lib/module/shared/utils/create-provider.js +119 -10
- package/lib/module/shared/utils/create-provider.js.map +1 -1
- package/lib/typescript/blank-stack/components/stack-view.d.ts.map +1 -1
- package/lib/typescript/blank-stack/types.d.ts +1 -1
- package/lib/typescript/blank-stack/types.d.ts.map +1 -1
- package/lib/typescript/component-stack/components/stack-view.d.ts.map +1 -1
- package/lib/typescript/component-stack/types.d.ts +1 -1
- package/lib/typescript/component-stack/types.d.ts.map +1 -1
- package/lib/typescript/native-stack/types.d.ts +1 -1
- package/lib/typescript/native-stack/types.d.ts.map +1 -1
- package/lib/typescript/native-stack/views/NativeStackView.native.d.ts.map +1 -1
- package/lib/typescript/native-stack/views/useHeaderConfigProps.d.ts +1 -1
- package/lib/typescript/shared/components/boundary/components/boundary-lifecycle.d.ts.map +1 -1
- package/lib/typescript/shared/components/boundary/hooks/lifecycles/{use-initial-source-measurement.d.ts → use-boundary-measurement-request.d.ts} +4 -3
- package/lib/typescript/shared/components/boundary/hooks/lifecycles/use-boundary-measurement-request.d.ts.map +1 -0
- package/lib/typescript/shared/components/boundary/hooks/lifecycles/use-boundary-presence.d.ts.map +1 -1
- package/lib/typescript/shared/components/boundary/hooks/use-boundary-measurement.d.ts +1 -3
- package/lib/typescript/shared/components/boundary/hooks/use-boundary-measurement.d.ts.map +1 -1
- package/lib/typescript/shared/components/boundary/hooks/use-measurer.d.ts.map +1 -1
- package/lib/typescript/shared/components/boundary/portal/components/boundary-content-portal/helpers/active-handoff-receiver.d.ts +12 -0
- package/lib/typescript/shared/components/boundary/portal/components/boundary-content-portal/helpers/active-handoff-receiver.d.ts.map +1 -1
- package/lib/typescript/shared/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.d.ts.map +1 -1
- package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/components/portal-boundary-host.d.ts.map +1 -1
- package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/helpers/attachment.d.ts +8 -0
- package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/helpers/attachment.d.ts.map +1 -0
- package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/helpers/host-readiness.d.ts +6 -0
- package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/helpers/host-readiness.d.ts.map +1 -0
- package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/helpers/local-measurement.d.ts +4 -1
- package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/helpers/local-measurement.d.ts.map +1 -1
- package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/hooks/use-active-portal-boundary-host.d.ts +2 -3
- package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/hooks/use-active-portal-boundary-host.d.ts.map +1 -1
- package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.d.ts.map +1 -1
- package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/hooks/use-placeholder-styles.d.ts +2 -2
- package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/stores/portal-boundary-host.store.d.ts +1 -1
- package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/stores/portal-boundary-host.store.d.ts.map +1 -1
- package/lib/typescript/shared/components/boundary/types.d.ts +1 -1
- package/lib/typescript/shared/components/boundary/types.d.ts.map +1 -1
- package/lib/typescript/shared/components/create-transition-aware-component.d.ts +5 -6
- package/lib/typescript/shared/components/create-transition-aware-component.d.ts.map +1 -1
- package/lib/typescript/shared/components/overlay/helpers/create-overlay-interpolator-frame.d.ts +7 -0
- package/lib/typescript/shared/components/overlay/helpers/create-overlay-interpolator-frame.d.ts.map +1 -0
- package/lib/typescript/shared/components/overlay/helpers/get-active-overlay.d.ts +17 -7
- package/lib/typescript/shared/components/overlay/helpers/get-active-overlay.d.ts.map +1 -1
- package/lib/typescript/shared/components/overlay/helpers/retain-ready-overlay-resources.d.ts +11 -0
- package/lib/typescript/shared/components/overlay/helpers/retain-ready-overlay-resources.d.ts.map +1 -0
- package/lib/typescript/shared/components/overlay/helpers/run-overlay-slot-interpolator.d.ts +8 -0
- package/lib/typescript/shared/components/overlay/helpers/run-overlay-slot-interpolator.d.ts.map +1 -0
- package/lib/typescript/shared/components/overlay/hooks/use-overlay-slot.d.ts +15 -0
- package/lib/typescript/shared/components/overlay/hooks/use-overlay-slot.d.ts.map +1 -0
- package/lib/typescript/shared/components/overlay/variations/float-overlay.d.ts +1 -1
- package/lib/typescript/shared/components/overlay/variations/float-overlay.d.ts.map +1 -1
- package/lib/typescript/shared/components/overlay/variations/overlay-host.d.ts +7 -6
- package/lib/typescript/shared/components/overlay/variations/overlay-host.d.ts.map +1 -1
- package/lib/typescript/shared/components/screen-lifecycle/hooks/use-close-transition-intent.d.ts.map +1 -1
- package/lib/typescript/shared/index.d.ts +658 -710
- package/lib/typescript/shared/index.d.ts.map +1 -1
- package/lib/typescript/shared/providers/helpers/measured-bounds-writes.d.ts.map +1 -1
- package/lib/typescript/shared/providers/screen/animation/animation.provider.d.ts +4 -0
- package/lib/typescript/shared/providers/screen/animation/animation.provider.d.ts.map +1 -1
- package/lib/typescript/shared/providers/screen/animation/helpers/accessors/use-build-transition-accessor.d.ts +4 -1
- package/lib/typescript/shared/providers/screen/animation/helpers/accessors/use-build-transition-accessor.d.ts.map +1 -1
- package/lib/typescript/shared/providers/screen/animation/helpers/hydrate-transition-state/index.d.ts.map +1 -1
- package/lib/typescript/shared/providers/screen/animation/helpers/interpolator-participation.d.ts +3 -0
- package/lib/typescript/shared/providers/screen/animation/helpers/interpolator-participation.d.ts.map +1 -0
- package/lib/typescript/shared/providers/screen/animation/helpers/pipeline.d.ts +2 -1
- package/lib/typescript/shared/providers/screen/animation/helpers/pipeline.d.ts.map +1 -1
- package/lib/typescript/shared/providers/screen/animation/use-screen-animation.d.ts.map +1 -1
- package/lib/typescript/shared/providers/screen/descriptors/descriptors.provider.d.ts.map +1 -1
- package/lib/typescript/shared/providers/screen/descriptors/helpers/derive-descriptor-derivations.d.ts +4 -0
- package/lib/typescript/shared/providers/screen/descriptors/helpers/derive-descriptor-derivations.d.ts.map +1 -1
- package/lib/typescript/shared/providers/screen/descriptors/helpers/derive-structural-ancestor-keys.d.ts +5 -0
- package/lib/typescript/shared/providers/screen/descriptors/helpers/derive-structural-ancestor-keys.d.ts.map +1 -0
- package/lib/typescript/shared/providers/screen/gestures/gestures.provider.d.ts.map +1 -1
- package/lib/typescript/shared/providers/screen/gestures/hooks/use-screen-gesture-config.d.ts +2 -2
- package/lib/typescript/shared/providers/screen/gestures/hooks/use-screen-gesture-config.d.ts.map +1 -1
- package/lib/typescript/shared/providers/screen/gestures/ownership/gesture-ownership-bridge.d.ts +3 -0
- package/lib/typescript/shared/providers/screen/gestures/ownership/gesture-ownership-bridge.d.ts.map +1 -0
- package/lib/typescript/shared/providers/screen/gestures/pan/behavior/pan-lifecycle.d.ts.map +1 -1
- package/lib/typescript/shared/providers/screen/gestures/pan/behavior/pan-release.d.ts.map +1 -1
- package/lib/typescript/shared/providers/screen/gestures/pan/behavior/use-pan-behavior.d.ts.map +1 -1
- package/lib/typescript/shared/providers/screen/gestures/types.d.ts +1 -0
- package/lib/typescript/shared/providers/screen/gestures/types.d.ts.map +1 -1
- package/lib/typescript/shared/providers/screen/styles/constants.d.ts.map +1 -1
- package/lib/typescript/shared/providers/screen/styles/helpers/transition-visual-state.d.ts +7 -0
- package/lib/typescript/shared/providers/screen/styles/helpers/transition-visual-state.d.ts.map +1 -1
- package/lib/typescript/shared/providers/screen/styles/helpers/visibility-block-ownership.d.ts +10 -0
- package/lib/typescript/shared/providers/screen/styles/helpers/visibility-block-ownership.d.ts.map +1 -0
- package/lib/typescript/shared/providers/screen/styles/hooks/slot-resolvers.d.ts +4 -4
- package/lib/typescript/shared/providers/screen/styles/hooks/slot-resolvers.d.ts.map +1 -1
- package/lib/typescript/shared/providers/screen/styles/hooks/use-interpolated-style-maps.d.ts +1 -1
- package/lib/typescript/shared/providers/screen/styles/hooks/use-interpolated-style-maps.d.ts.map +1 -1
- package/lib/typescript/shared/providers/screen/styles/hooks/use-maybe-block-visibility.d.ts +10 -4
- package/lib/typescript/shared/providers/screen/styles/hooks/use-maybe-block-visibility.d.ts.map +1 -1
- package/lib/typescript/shared/providers/screen/styles/slot.provider.d.ts +6 -5
- package/lib/typescript/shared/providers/screen/styles/slot.provider.d.ts.map +1 -1
- package/lib/typescript/shared/providers/stack/blank-stack-state/helpers/resolve-presented-index.d.ts +3 -0
- package/lib/typescript/shared/providers/stack/blank-stack-state/helpers/resolve-presented-index.d.ts.map +1 -0
- package/lib/typescript/shared/providers/stack/blank-stack.provider.d.ts.map +1 -1
- package/lib/typescript/shared/stores/bounds/helpers/link-pairs.helpers.d.ts +1 -0
- package/lib/typescript/shared/stores/bounds/helpers/link-pairs.helpers.d.ts.map +1 -1
- package/lib/typescript/shared/stores/bounds/internals/clear.d.ts.map +1 -1
- package/lib/typescript/shared/stores/bounds/internals/coordinator.d.ts +36 -0
- package/lib/typescript/shared/stores/bounds/internals/coordinator.d.ts.map +1 -0
- package/lib/typescript/shared/stores/bounds/internals/entries.d.ts +1 -2
- package/lib/typescript/shared/stores/bounds/internals/entries.d.ts.map +1 -1
- package/lib/typescript/shared/stores/bounds/internals/links.d.ts +1 -3
- package/lib/typescript/shared/stores/bounds/internals/links.d.ts.map +1 -1
- package/lib/typescript/shared/stores/bounds/internals/screen-graph.d.ts +5 -0
- package/lib/typescript/shared/stores/bounds/internals/screen-graph.d.ts.map +1 -0
- package/lib/typescript/shared/stores/bounds/internals/state.d.ts +3 -1
- package/lib/typescript/shared/stores/bounds/internals/state.d.ts.map +1 -1
- package/lib/typescript/shared/stores/bounds/types.d.ts +13 -1
- package/lib/typescript/shared/stores/bounds/types.d.ts.map +1 -1
- package/lib/typescript/shared/types/animation.types.d.ts +8 -0
- package/lib/typescript/shared/types/animation.types.d.ts.map +1 -1
- package/lib/typescript/shared/types/index.d.ts +1 -1
- package/lib/typescript/shared/types/index.d.ts.map +1 -1
- package/lib/typescript/shared/types/overlay.types.d.ts +26 -11
- package/lib/typescript/shared/types/overlay.types.d.ts.map +1 -1
- package/lib/typescript/shared/types/screen.types.d.ts +11 -2
- package/lib/typescript/shared/types/screen.types.d.ts.map +1 -1
- package/lib/typescript/shared/utils/bounds/helpers/create-bounds-accessor-core.d.ts.map +1 -1
- package/lib/typescript/shared/utils/bounds/helpers/create-link-accessor.d.ts.map +1 -1
- package/lib/typescript/shared/utils/bounds/helpers/prepare-bound-styles.d.ts.map +1 -1
- package/lib/typescript/shared/utils/bounds/helpers/resolve-bounds-pair-key.d.ts.map +1 -1
- package/lib/typescript/shared/utils/bounds/helpers/styles/compute.d.ts.map +1 -1
- package/lib/typescript/shared/utils/create-provider.d.ts +21 -6
- package/lib/typescript/shared/utils/create-provider.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/blank-stack/components/stack-view.tsx +1 -4
- package/src/blank-stack/types.ts +8 -2
- package/src/component-stack/components/stack-view.tsx +1 -4
- package/src/component-stack/types.ts +8 -2
- package/src/native-stack/types.ts +8 -2
- package/src/native-stack/views/NativeStackView.native.tsx +3 -9
- package/src/shared/adapters/with-screen-transitions/stack-layout.tsx +1 -1
- package/src/shared/components/activity/variants/activity-screen.tsx +1 -1
- package/src/shared/components/boundary/components/boundary-lifecycle.tsx +0 -6
- package/src/shared/components/boundary/hooks/lifecycles/use-boundary-measurement-request.ts +102 -0
- package/src/shared/components/boundary/hooks/lifecycles/use-boundary-presence.ts +20 -11
- package/src/shared/components/boundary/hooks/use-boundary-measurement.ts +3 -22
- package/src/shared/components/boundary/hooks/use-measurer.ts +5 -20
- package/src/shared/components/boundary/portal/components/boundary-content-portal/helpers/active-handoff-receiver.ts +40 -0
- package/src/shared/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.ts +75 -22
- package/src/shared/components/boundary/portal/components/boundary-portal/components/portal-boundary-host.tsx +10 -1
- package/src/shared/components/boundary/portal/components/boundary-portal/helpers/attachment.ts +19 -0
- package/src/shared/components/boundary/portal/components/boundary-portal/helpers/host-readiness.ts +14 -0
- package/src/shared/components/boundary/portal/components/boundary-portal/helpers/local-measurement.ts +36 -1
- package/src/shared/components/boundary/portal/components/boundary-portal/hooks/use-active-portal-boundary-host.ts +22 -13
- package/src/shared/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.ts +26 -9
- package/src/shared/components/boundary/portal/components/boundary-portal/stores/portal-boundary-host.store.ts +1 -1
- package/src/shared/components/boundary/types.ts +1 -1
- package/src/shared/components/overlay/helpers/create-overlay-interpolator-frame.ts +29 -0
- package/src/shared/components/overlay/helpers/get-active-overlay.ts +62 -20
- package/src/shared/components/overlay/helpers/retain-ready-overlay-resources.ts +38 -0
- package/src/shared/components/overlay/helpers/run-overlay-slot-interpolator.ts +48 -0
- package/src/shared/components/overlay/hooks/use-overlay-slot.ts +103 -0
- package/src/shared/components/overlay/variations/float-overlay.tsx +22 -64
- package/src/shared/components/overlay/variations/overlay-host.tsx +135 -28
- package/src/shared/components/screen-lifecycle/hooks/use-close-transition-intent.ts +5 -1
- package/src/shared/index.ts +1 -0
- package/src/shared/providers/helpers/measured-bounds-writes.ts +5 -0
- package/src/shared/providers/screen/animation/animation.provider.tsx +31 -12
- package/src/shared/providers/screen/animation/helpers/accessors/use-build-transition-accessor.ts +15 -9
- package/src/shared/providers/screen/animation/helpers/hydrate-transition-state/index.ts +18 -3
- package/src/shared/providers/screen/animation/helpers/interpolator-participation.ts +6 -0
- package/src/shared/providers/screen/animation/helpers/pipeline.ts +54 -32
- package/src/shared/providers/screen/animation/use-screen-animation.tsx +12 -2
- package/src/shared/providers/screen/descriptors/descriptors.provider.tsx +80 -14
- package/src/shared/providers/screen/descriptors/helpers/derive-descriptor-derivations.ts +6 -0
- package/src/shared/providers/screen/descriptors/helpers/derive-structural-ancestor-keys.ts +13 -0
- package/src/shared/providers/screen/gestures/gestures.provider.tsx +18 -7
- package/src/shared/providers/screen/gestures/hooks/use-screen-gesture-config.ts +4 -4
- package/src/shared/providers/screen/gestures/ownership/{use-walk-up-and-register-shadowing-claims.ts → gesture-ownership-bridge.tsx} +44 -54
- package/src/shared/providers/screen/gestures/pan/behavior/pan-lifecycle.ts +1 -0
- package/src/shared/providers/screen/gestures/pan/behavior/pan-release.ts +12 -2
- package/src/shared/providers/screen/gestures/pan/behavior/use-pan-behavior.ts +1 -0
- package/src/shared/providers/screen/gestures/types.ts +1 -0
- package/src/shared/providers/screen/styles/constants.ts +2 -0
- package/src/shared/providers/screen/styles/helpers/transition-visual-state.ts +26 -0
- package/src/shared/providers/screen/styles/helpers/visibility-block-ownership.ts +16 -0
- package/src/shared/providers/screen/styles/hooks/slot-resolvers.tsx +17 -5
- package/src/shared/providers/screen/styles/hooks/use-interpolated-style-maps.tsx +51 -12
- package/src/shared/providers/screen/styles/hooks/use-maybe-block-visibility.tsx +40 -15
- package/src/shared/providers/screen/styles/slot.provider.tsx +60 -70
- package/src/shared/providers/stack/blank-stack-state/helpers/resolve-presented-index.ts +22 -0
- package/src/shared/providers/stack/blank-stack.provider.tsx +6 -1
- package/src/shared/stores/bounds/helpers/link-pairs.helpers.ts +12 -0
- package/src/shared/stores/bounds/internals/clear.ts +12 -1
- package/src/shared/stores/bounds/internals/coordinator.ts +403 -0
- package/src/shared/stores/bounds/internals/entries.ts +1 -38
- package/src/shared/stores/bounds/internals/links.ts +28 -38
- package/src/shared/stores/bounds/internals/screen-graph.ts +45 -0
- package/src/shared/stores/bounds/internals/state.ts +10 -1
- package/src/shared/stores/bounds/types.ts +19 -1
- package/src/shared/types/animation.types.ts +8 -0
- package/src/shared/types/index.ts +1 -1
- package/src/shared/types/overlay.types.ts +41 -14
- package/src/shared/types/screen.types.ts +12 -2
- package/src/shared/utils/bounds/helpers/create-bounds-accessor-core.ts +8 -3
- package/src/shared/utils/bounds/helpers/create-link-accessor.ts +11 -0
- package/src/shared/utils/bounds/helpers/prepare-bound-styles.ts +3 -2
- package/src/shared/utils/bounds/helpers/resolve-bounds-pair-key.ts +0 -1
- package/src/shared/utils/bounds/helpers/styles/compute.ts +12 -5
- package/src/shared/utils/create-provider.tsx +221 -19
- package/lib/commonjs/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.js +0 -177
- package/lib/commonjs/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.js.map +0 -1
- package/lib/commonjs/shared/components/boundary/hooks/lifecycles/use-initial-source-measurement.js +0 -49
- package/lib/commonjs/shared/components/boundary/hooks/lifecycles/use-initial-source-measurement.js.map +0 -1
- package/lib/commonjs/shared/components/boundary/hooks/lifecycles/use-refresh-boundary.js +0 -69
- package/lib/commonjs/shared/components/boundary/hooks/lifecycles/use-refresh-boundary.js.map +0 -1
- package/lib/commonjs/shared/components/boundary/utils/destination-signals.js +0 -68
- package/lib/commonjs/shared/components/boundary/utils/destination-signals.js.map +0 -1
- package/lib/commonjs/shared/components/boundary/utils/refresh-signals.js +0 -97
- package/lib/commonjs/shared/components/boundary/utils/refresh-signals.js.map +0 -1
- package/lib/commonjs/shared/components/boundary/utils/source-signals.js +0 -43
- package/lib/commonjs/shared/components/boundary/utils/source-signals.js.map +0 -1
- package/lib/commonjs/shared/providers/screen/descriptors/helpers/get-ancestor-keys.js +0 -29
- package/lib/commonjs/shared/providers/screen/descriptors/helpers/get-ancestor-keys.js.map +0 -1
- package/lib/commonjs/shared/providers/screen/gestures/ownership/use-walk-up-and-register-shadowing-claims.js.map +0 -1
- package/lib/commonjs/shared/providers/screen/styles/components/floating-overlay-layer.js +0 -28
- package/lib/commonjs/shared/providers/screen/styles/components/floating-overlay-layer.js.map +0 -1
- package/lib/commonjs/shared/providers/screen/styles/stores/slot-references.store.js +0 -53
- package/lib/commonjs/shared/providers/screen/styles/stores/slot-references.store.js.map +0 -1
- package/lib/module/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.js +0 -173
- package/lib/module/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.js.map +0 -1
- package/lib/module/shared/components/boundary/hooks/lifecycles/use-initial-source-measurement.js +0 -44
- package/lib/module/shared/components/boundary/hooks/lifecycles/use-initial-source-measurement.js.map +0 -1
- package/lib/module/shared/components/boundary/hooks/lifecycles/use-refresh-boundary.js +0 -64
- package/lib/module/shared/components/boundary/hooks/lifecycles/use-refresh-boundary.js.map +0 -1
- package/lib/module/shared/components/boundary/utils/destination-signals.js +0 -63
- package/lib/module/shared/components/boundary/utils/destination-signals.js.map +0 -1
- package/lib/module/shared/components/boundary/utils/refresh-signals.js +0 -92
- package/lib/module/shared/components/boundary/utils/refresh-signals.js.map +0 -1
- package/lib/module/shared/components/boundary/utils/source-signals.js +0 -38
- package/lib/module/shared/components/boundary/utils/source-signals.js.map +0 -1
- package/lib/module/shared/providers/screen/descriptors/helpers/get-ancestor-keys.js +0 -25
- package/lib/module/shared/providers/screen/descriptors/helpers/get-ancestor-keys.js.map +0 -1
- package/lib/module/shared/providers/screen/gestures/ownership/use-walk-up-and-register-shadowing-claims.js.map +0 -1
- package/lib/module/shared/providers/screen/styles/components/floating-overlay-layer.js +0 -24
- package/lib/module/shared/providers/screen/styles/components/floating-overlay-layer.js.map +0 -1
- package/lib/module/shared/providers/screen/styles/stores/slot-references.store.js +0 -47
- package/lib/module/shared/providers/screen/styles/stores/slot-references.store.js.map +0 -1
- package/lib/typescript/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.d.ts +0 -10
- package/lib/typescript/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.d.ts.map +0 -1
- package/lib/typescript/shared/components/boundary/hooks/lifecycles/use-initial-source-measurement.d.ts.map +0 -1
- package/lib/typescript/shared/components/boundary/hooks/lifecycles/use-refresh-boundary.d.ts +0 -10
- package/lib/typescript/shared/components/boundary/hooks/lifecycles/use-refresh-boundary.d.ts.map +0 -1
- package/lib/typescript/shared/components/boundary/utils/destination-signals.d.ts +0 -16
- package/lib/typescript/shared/components/boundary/utils/destination-signals.d.ts.map +0 -1
- package/lib/typescript/shared/components/boundary/utils/refresh-signals.d.ts +0 -19
- package/lib/typescript/shared/components/boundary/utils/refresh-signals.d.ts.map +0 -1
- package/lib/typescript/shared/components/boundary/utils/source-signals.d.ts +0 -14
- package/lib/typescript/shared/components/boundary/utils/source-signals.d.ts.map +0 -1
- package/lib/typescript/shared/providers/screen/descriptors/helpers/get-ancestor-keys.d.ts +0 -6
- package/lib/typescript/shared/providers/screen/descriptors/helpers/get-ancestor-keys.d.ts.map +0 -1
- package/lib/typescript/shared/providers/screen/gestures/ownership/use-walk-up-and-register-shadowing-claims.d.ts +0 -14
- package/lib/typescript/shared/providers/screen/gestures/ownership/use-walk-up-and-register-shadowing-claims.d.ts.map +0 -1
- package/lib/typescript/shared/providers/screen/styles/components/floating-overlay-layer.d.ts +0 -7
- package/lib/typescript/shared/providers/screen/styles/components/floating-overlay-layer.d.ts.map +0 -1
- package/lib/typescript/shared/providers/screen/styles/stores/slot-references.store.d.ts +0 -6
- package/lib/typescript/shared/providers/screen/styles/stores/slot-references.store.d.ts.map +0 -1
- package/src/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.ts +0 -267
- package/src/shared/components/boundary/hooks/lifecycles/use-initial-source-measurement.ts +0 -51
- package/src/shared/components/boundary/hooks/lifecycles/use-refresh-boundary.ts +0 -90
- package/src/shared/components/boundary/utils/destination-signals.ts +0 -75
- package/src/shared/components/boundary/utils/refresh-signals.ts +0 -164
- package/src/shared/components/boundary/utils/source-signals.ts +0 -51
- package/src/shared/providers/screen/descriptors/helpers/get-ancestor-keys.ts +0 -28
- package/src/shared/providers/screen/styles/components/floating-overlay-layer.tsx +0 -29
- package/src/shared/providers/screen/styles/stores/slot-references.store.ts +0 -72
|
@@ -2,6 +2,7 @@ import { type ReactNode, useCallback, useLayoutEffect, useMemo } from "react";
|
|
|
2
2
|
import { useSharedValue } from "react-native-reanimated";
|
|
3
3
|
import { createBoundsAccessor } from "../../../utils/bounds";
|
|
4
4
|
import createProvider from "../../../utils/create-provider";
|
|
5
|
+
import { useDescriptorsStore } from "../descriptors";
|
|
5
6
|
import { useScreenAnimationPipeline } from "./helpers/pipeline";
|
|
6
7
|
import type {
|
|
7
8
|
RegisterScreenAnimationDescendant,
|
|
@@ -25,33 +26,49 @@ export type ScreenAnimationContextValue = ReturnType<
|
|
|
25
26
|
};
|
|
26
27
|
|
|
27
28
|
export type ScreenAnimationContextResult = {
|
|
29
|
+
key: string;
|
|
28
30
|
value: ScreenAnimationContextValue;
|
|
29
31
|
};
|
|
30
32
|
|
|
31
33
|
export const { ScreenAnimationProvider, useScreenAnimationStore } =
|
|
32
34
|
createProvider("ScreenAnimation", {
|
|
33
35
|
guarded: true,
|
|
36
|
+
global: true,
|
|
34
37
|
})<Props, ScreenAnimationContextValue>(
|
|
35
38
|
(_props, { useParentStore }): ScreenAnimationContextResult => {
|
|
36
|
-
const
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
const
|
|
40
|
-
parentContext?.
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
const
|
|
46
|
-
parentContext?.
|
|
39
|
+
const currentScreenKey = useDescriptorsStore(
|
|
40
|
+
(store) => store.derivations.currentScreenKey,
|
|
41
|
+
);
|
|
42
|
+
const parentScreenInterpolatorProps = useParentStore(
|
|
43
|
+
(parentContext) => parentContext?.screenInterpolatorProps,
|
|
44
|
+
);
|
|
45
|
+
const parentScreenInterpolatorPropsRevision = useParentStore(
|
|
46
|
+
(parentContext) => parentContext?.screenInterpolatorPropsRevision,
|
|
47
|
+
);
|
|
48
|
+
const parentAncestorScreenAnimationSources = useParentStore(
|
|
49
|
+
(parentContext) => parentContext?.ancestorScreenAnimationSources,
|
|
50
|
+
);
|
|
51
|
+
const parentRegisterDescendantScreenAnimationSource = useParentStore(
|
|
52
|
+
(parentContext) =>
|
|
53
|
+
parentContext?.registerDescendantScreenAnimationSource,
|
|
54
|
+
);
|
|
55
|
+
const parentAncestorDescendantScreenAnimationRegistrars = useParentStore(
|
|
56
|
+
(parentContext) =>
|
|
57
|
+
parentContext?.ancestorDescendantScreenAnimationRegistrars,
|
|
58
|
+
);
|
|
59
|
+
|
|
60
|
+
const parentInterpolatorUpdatesEnabled = useParentStore(
|
|
61
|
+
(parentContext) => parentContext?.interpolatorUpdatesEnabled,
|
|
62
|
+
);
|
|
47
63
|
|
|
48
64
|
const {
|
|
65
|
+
interpolatorUpdatesEnabled,
|
|
49
66
|
screenInterpolatorProps,
|
|
50
67
|
screenInterpolatorPropsRevision,
|
|
51
68
|
selectedInterpolatorOptions,
|
|
52
69
|
nextInterpolator,
|
|
53
70
|
currentInterpolator,
|
|
54
|
-
} = useScreenAnimationPipeline();
|
|
71
|
+
} = useScreenAnimationPipeline(parentInterpolatorUpdatesEnabled ?? true);
|
|
55
72
|
|
|
56
73
|
const selfScreenAnimationSource = useMemo<ScreenAnimationSource>(
|
|
57
74
|
() => ({
|
|
@@ -192,7 +209,9 @@ export const { ScreenAnimationProvider, useScreenAnimationStore } =
|
|
|
192
209
|
]);
|
|
193
210
|
|
|
194
211
|
return {
|
|
212
|
+
key: currentScreenKey,
|
|
195
213
|
value: {
|
|
214
|
+
interpolatorUpdatesEnabled,
|
|
196
215
|
screenInterpolatorProps,
|
|
197
216
|
screenInterpolatorPropsRevision,
|
|
198
217
|
selectedInterpolatorOptions,
|
package/src/shared/providers/screen/animation/helpers/accessors/use-build-transition-accessor.ts
CHANGED
|
@@ -4,7 +4,7 @@ import type {
|
|
|
4
4
|
ScreenTransitionTarget,
|
|
5
5
|
} from "../../../../../types/animation.types";
|
|
6
6
|
import { createBoundsAccessor } from "../../../../../utils/bounds";
|
|
7
|
-
import {
|
|
7
|
+
import type { ScreenAnimationContextValue } from "../../animation.provider";
|
|
8
8
|
import type {
|
|
9
9
|
ScreenAnimationDescendantSources,
|
|
10
10
|
ScreenAnimationSource,
|
|
@@ -15,6 +15,14 @@ type TransitionSourceIndex = number;
|
|
|
15
15
|
|
|
16
16
|
export type TransitionAccessorSource = ScreenAnimationTransitionSource;
|
|
17
17
|
|
|
18
|
+
type TransitionAccessorStore = Pick<
|
|
19
|
+
ScreenAnimationContextValue,
|
|
20
|
+
| "screenInterpolatorProps"
|
|
21
|
+
| "screenInterpolatorPropsRevision"
|
|
22
|
+
| "ancestorScreenAnimationSources"
|
|
23
|
+
| "descendantScreenAnimationSources"
|
|
24
|
+
>;
|
|
25
|
+
|
|
18
26
|
const resolveTargetIndex = (
|
|
19
27
|
target: ScreenTransitionTarget | undefined,
|
|
20
28
|
currentIndex: TransitionSourceIndex,
|
|
@@ -118,14 +126,12 @@ const buildSourceBoundsAccessor = (source: ScreenAnimationSource) => {
|
|
|
118
126
|
});
|
|
119
127
|
};
|
|
120
128
|
|
|
121
|
-
export const useBuildTransitionAccessor = (
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
} = useScreenAnimationStore();
|
|
128
|
-
|
|
129
|
+
export const useBuildTransitionAccessor = ({
|
|
130
|
+
screenInterpolatorProps,
|
|
131
|
+
screenInterpolatorPropsRevision,
|
|
132
|
+
ancestorScreenAnimationSources,
|
|
133
|
+
descendantScreenAnimationSources,
|
|
134
|
+
}: TransitionAccessorStore) => {
|
|
129
135
|
return useMemo(() => {
|
|
130
136
|
const selfSource = {
|
|
131
137
|
screenInterpolatorProps,
|
|
@@ -210,14 +210,29 @@ export const hydrateTransitionState = (
|
|
|
210
210
|
const resolvedAutoSnap =
|
|
211
211
|
s.hasAutoSnapPoint && autoSnapPoint > 0 ? autoSnapPoint : null;
|
|
212
212
|
|
|
213
|
+
const targetProgress = s.targetProgress.get();
|
|
214
|
+
const lockedSnapPoint = s.gesture.internal.lockedSnapPoint.get();
|
|
215
|
+
|
|
216
|
+
const isSettlingToLockedSnapPoint =
|
|
217
|
+
out.gesture.settling && targetProgress === lockedSnapPoint;
|
|
218
|
+
|
|
219
|
+
const isLockedGestureLifecycle =
|
|
220
|
+
options.gestureSnapLocked &&
|
|
221
|
+
lockedSnapPoint !== null &&
|
|
222
|
+
(out.gesture.dragging ||
|
|
223
|
+
isSettlingToLockedSnapPoint ||
|
|
224
|
+
out.gesture.dismissing);
|
|
225
|
+
|
|
226
|
+
const animatedSnapProgress = isLockedGestureLifecycle
|
|
227
|
+
? lockedSnapPoint
|
|
228
|
+
: out.progress;
|
|
229
|
+
|
|
213
230
|
out.animatedSnapIndex = computeAnimatedSnapIndex(
|
|
214
|
-
|
|
231
|
+
animatedSnapProgress,
|
|
215
232
|
s.sortedNumericSnapPoints,
|
|
216
233
|
resolvedAutoSnap,
|
|
217
234
|
);
|
|
218
235
|
|
|
219
|
-
const targetProgress = s.targetProgress.get();
|
|
220
|
-
|
|
221
236
|
out.snapIndex = computeTargetSnapIndex(
|
|
222
237
|
targetProgress,
|
|
223
238
|
s.sortedNumericSnapPoints,
|
|
@@ -23,6 +23,7 @@ import { buildScreenTransitionOptions } from "./build-screen-transition-options"
|
|
|
23
23
|
import { updateDerivations } from "./derivations";
|
|
24
24
|
import { hasTransitionsEnabled } from "./has-transitions-enabled";
|
|
25
25
|
import { hydrateTransitionState } from "./hydrate-transition-state";
|
|
26
|
+
import { shouldUpdateScreenInterpolator } from "./interpolator-participation";
|
|
26
27
|
import type { SelectedInterpolatorOptions } from "./selected-interpolator-options";
|
|
27
28
|
import { resolveStackProgress } from "./stack-progress";
|
|
28
29
|
import { useBuildTransitionState } from "./use-build-transition-state";
|
|
@@ -34,6 +35,7 @@ export type ScreenInterpolatorFrame = Omit<
|
|
|
34
35
|
>;
|
|
35
36
|
|
|
36
37
|
interface ScreenAnimationPipeline {
|
|
38
|
+
interpolatorUpdatesEnabled: boolean;
|
|
37
39
|
screenInterpolatorProps: SharedValue<ScreenInterpolatorFrame>;
|
|
38
40
|
screenInterpolatorPropsRevision: DerivedValue<number>;
|
|
39
41
|
selectedInterpolatorOptions: SharedValue<SelectedInterpolatorOptions>;
|
|
@@ -273,7 +275,9 @@ const hydrateInterpolatorFrame = <TFrame extends ScreenInterpolatorFrame>({
|
|
|
273
275
|
return frame;
|
|
274
276
|
};
|
|
275
277
|
|
|
276
|
-
export function useScreenAnimationPipeline(
|
|
278
|
+
export function useScreenAnimationPipeline(
|
|
279
|
+
parentInterpolatorUpdatesEnabled = true,
|
|
280
|
+
): ScreenAnimationPipeline {
|
|
277
281
|
const transitionsAlwaysOn = useStack(
|
|
278
282
|
(stack) => stack.flags.TRANSITIONS_ALWAYS_ON,
|
|
279
283
|
);
|
|
@@ -283,6 +287,16 @@ export function useScreenAnimationPipeline(): ScreenAnimationPipeline {
|
|
|
283
287
|
const currDescriptor = useDescriptorsStore((store) => store.current);
|
|
284
288
|
const nextDescriptor = useDescriptorsStore((store) => store.next);
|
|
285
289
|
const prevDescriptor = useDescriptorsStore((store) => store.previous);
|
|
290
|
+
const currentActivity = useStack((stack) => {
|
|
291
|
+
const routeIndex = stack.routeKeys.indexOf(currDescriptor.route.key);
|
|
292
|
+
return stack.scenes[routeIndex]?.activity;
|
|
293
|
+
});
|
|
294
|
+
const interpolatorUpdatesEnabled =
|
|
295
|
+
parentInterpolatorUpdatesEnabled &&
|
|
296
|
+
shouldUpdateScreenInterpolator(
|
|
297
|
+
currentActivity ?? "active",
|
|
298
|
+
currDescriptor.options.experimental_updateInactiveInterpolators === true,
|
|
299
|
+
);
|
|
286
300
|
|
|
287
301
|
const currentAnimation = useBuildTransitionState(currDescriptor);
|
|
288
302
|
const nextAnimation = useBuildTransitionState(nextDescriptor);
|
|
@@ -312,42 +326,50 @@ export function useScreenAnimationPipeline(): ScreenAnimationPipeline {
|
|
|
312
326
|
});
|
|
313
327
|
|
|
314
328
|
const propsRevisionState = useSharedValue({ value: 0 });
|
|
315
|
-
const screenInterpolatorPropsRevision = useDerivedValue<number>(
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
329
|
+
const screenInterpolatorPropsRevision = useDerivedValue<number>(
|
|
330
|
+
interpolatorUpdatesEnabled
|
|
331
|
+
? () => {
|
|
332
|
+
"worklet";
|
|
333
|
+
screenInterpolatorProps.modify((frame) => {
|
|
334
|
+
"worklet";
|
|
335
|
+
const interpolatorOptions = selectedInterpolatorOptions.get();
|
|
336
|
+
return hydrateInterpolatorFrame({
|
|
337
|
+
frame,
|
|
338
|
+
dimensions,
|
|
339
|
+
insets,
|
|
340
|
+
currentAnimation,
|
|
341
|
+
nextAnimation,
|
|
342
|
+
prevAnimation,
|
|
343
|
+
nextHasTransitions,
|
|
344
|
+
interpolatorOptions,
|
|
345
|
+
});
|
|
346
|
+
}, false);
|
|
347
|
+
|
|
348
|
+
// Critical reactive dependency for `screenInterpolatorProps`.
|
|
349
|
+
//
|
|
350
|
+
// `screenInterpolatorProps` is mutated in place to avoid allocating a large
|
|
351
|
+
// interpolator frame every tick. Consumers must read this revision before
|
|
352
|
+
// reading `screenInterpolatorProps`, otherwise Reanimated may not subscribe
|
|
353
|
+
// to frame updates and can observe stale transition state.
|
|
354
|
+
propsRevisionState.modify((revision) => {
|
|
355
|
+
"worklet";
|
|
356
|
+
revision.value += 1;
|
|
357
|
+
return revision;
|
|
358
|
+
}, false);
|
|
359
|
+
|
|
360
|
+
return propsRevisionState.get().value;
|
|
361
|
+
}
|
|
362
|
+
: () => {
|
|
363
|
+
"worklet";
|
|
364
|
+
return propsRevisionState.get().value;
|
|
365
|
+
},
|
|
366
|
+
);
|
|
346
367
|
|
|
347
368
|
const nextInterpolator = nextDescriptor?.options.screenStyleInterpolator;
|
|
348
369
|
const currentInterpolator = currDescriptor?.options.screenStyleInterpolator;
|
|
349
370
|
|
|
350
371
|
return {
|
|
372
|
+
interpolatorUpdatesEnabled,
|
|
351
373
|
screenInterpolatorProps,
|
|
352
374
|
screenInterpolatorPropsRevision,
|
|
353
375
|
selectedInterpolatorOptions,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { useRoute } from "@react-navigation/native";
|
|
1
2
|
import { type DerivedValue, useDerivedValue } from "react-native-reanimated";
|
|
2
3
|
import type {
|
|
3
4
|
ScreenInterpolationProps,
|
|
@@ -33,12 +34,21 @@ export function useScreenAnimation(
|
|
|
33
34
|
):
|
|
34
35
|
| DerivedValue<ScreenInterpolationProps>
|
|
35
36
|
| DerivedValue<ScreenInterpolationProps | null> {
|
|
37
|
+
const route = useRoute();
|
|
38
|
+
const screenAnimationStore = useScreenAnimationStore(route.key);
|
|
39
|
+
|
|
40
|
+
if (!screenAnimationStore) {
|
|
41
|
+
throw new Error(
|
|
42
|
+
`ScreenAnimation store for route "${route.key}" was not found`,
|
|
43
|
+
);
|
|
44
|
+
}
|
|
45
|
+
|
|
36
46
|
const {
|
|
37
47
|
screenInterpolatorPropsRevision,
|
|
38
48
|
ancestorScreenAnimationSources,
|
|
39
49
|
descendantScreenAnimationSources,
|
|
40
|
-
} =
|
|
41
|
-
const transition = useBuildTransitionAccessor();
|
|
50
|
+
} = screenAnimationStore;
|
|
51
|
+
const transition = useBuildTransitionAccessor(screenAnimationStore);
|
|
42
52
|
const transitionTarget = normalizeScreenAnimationTarget(
|
|
43
53
|
target,
|
|
44
54
|
ancestorScreenAnimationSources.length,
|
|
@@ -1,12 +1,18 @@
|
|
|
1
1
|
import type { ReactNode } from "react";
|
|
2
|
-
import { useMemo } from "react";
|
|
2
|
+
import { useLayoutEffect, useMemo } from "react";
|
|
3
|
+
import { runOnUI } from "react-native-reanimated";
|
|
3
4
|
import { useScreenTransitionsAdapterOptionalContext } from "../../../adapters/with-screen-transitions/context";
|
|
4
5
|
import { useBlankStackStore } from "../../../providers/stack/blank-stack.provider";
|
|
6
|
+
import {
|
|
7
|
+
registerScreen,
|
|
8
|
+
unregisterScreen,
|
|
9
|
+
} from "../../../stores/bounds/internals/coordinator";
|
|
10
|
+
import { SystemStore } from "../../../stores/system.store";
|
|
5
11
|
import type { BaseStackDescriptor } from "../../../types/stack.types";
|
|
6
12
|
import createProvider from "../../../utils/create-provider";
|
|
7
13
|
import type { DescriptorDerivations } from "./helpers/derive-descriptor-derivations";
|
|
8
14
|
import { deriveDescriptorDerivations } from "./helpers/derive-descriptor-derivations";
|
|
9
|
-
import {
|
|
15
|
+
import { deriveStructuralAncestorKeys } from "./helpers/derive-structural-ancestor-keys";
|
|
10
16
|
|
|
11
17
|
/**
|
|
12
18
|
* Base descriptor interface - minimal contract for all stack types.
|
|
@@ -45,7 +51,19 @@ export const { DescriptorsProvider, useDescriptorsStore } = createProvider(
|
|
|
45
51
|
"Descriptors",
|
|
46
52
|
{ guarded: true },
|
|
47
53
|
)<DescriptorsProviderProps, DescriptorStoreValue<BaseDescriptor>>(
|
|
48
|
-
({ previous, current, next, routeKey, children }) => {
|
|
54
|
+
({ previous, current, next, routeKey, children }, { useParentStore }) => {
|
|
55
|
+
const parentScreenKey = useParentStore(
|
|
56
|
+
(store) => store?.derivations.currentScreenKey,
|
|
57
|
+
);
|
|
58
|
+
const parentAncestorKeys = useParentStore(
|
|
59
|
+
(store) => store?.derivations.ancestorKeys,
|
|
60
|
+
);
|
|
61
|
+
const parentTransitionSourcePairKey = useParentStore(
|
|
62
|
+
(store) => store?.derivations.transitionSourcePairKey,
|
|
63
|
+
);
|
|
64
|
+
const parentTransitionDestinationScreenKey = useParentStore(
|
|
65
|
+
(store) => store?.derivations.transitionDestinationScreenKey,
|
|
66
|
+
);
|
|
49
67
|
const blankStackCurrent = useBlankStackStore((store) =>
|
|
50
68
|
routeKey ? store?.scenesByKey[routeKey]?.descriptor : undefined,
|
|
51
69
|
);
|
|
@@ -85,20 +103,68 @@ export const { DescriptorsProvider, useDescriptorsStore } = createProvider(
|
|
|
85
103
|
);
|
|
86
104
|
|
|
87
105
|
const ancestorKeys = useMemo(
|
|
88
|
-
() =>
|
|
89
|
-
|
|
106
|
+
() =>
|
|
107
|
+
deriveStructuralAncestorKeys(
|
|
108
|
+
parentScreenKey
|
|
109
|
+
? {
|
|
110
|
+
currentScreenKey: parentScreenKey,
|
|
111
|
+
ancestorKeys: parentAncestorKeys ?? [],
|
|
112
|
+
}
|
|
113
|
+
: null,
|
|
114
|
+
),
|
|
115
|
+
[parentAncestorKeys, parentScreenKey],
|
|
90
116
|
);
|
|
91
117
|
|
|
92
|
-
const derivations = useMemo(
|
|
93
|
-
(
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
118
|
+
const derivations = useMemo(() => {
|
|
119
|
+
const localDerivations = deriveDescriptorDerivations({
|
|
120
|
+
previous: resolvedPrevious,
|
|
121
|
+
current: resolvedCurrent,
|
|
122
|
+
next: resolvedNext,
|
|
123
|
+
ancestorKeys,
|
|
124
|
+
});
|
|
125
|
+
|
|
126
|
+
return {
|
|
127
|
+
...localDerivations,
|
|
128
|
+
transitionSourcePairKey:
|
|
129
|
+
localDerivations.sourcePairKey ?? parentTransitionSourcePairKey,
|
|
130
|
+
transitionDestinationScreenKey:
|
|
131
|
+
localDerivations.nextScreenKey ??
|
|
132
|
+
parentTransitionDestinationScreenKey,
|
|
133
|
+
};
|
|
134
|
+
}, [
|
|
135
|
+
resolvedPrevious,
|
|
136
|
+
resolvedCurrent,
|
|
137
|
+
resolvedNext,
|
|
138
|
+
ancestorKeys,
|
|
139
|
+
parentTransitionSourcePairKey,
|
|
140
|
+
parentTransitionDestinationScreenKey,
|
|
141
|
+
]);
|
|
142
|
+
const animationProgress = SystemStore.getValue(
|
|
143
|
+
derivations.currentScreenKey,
|
|
144
|
+
"animationProgress",
|
|
101
145
|
);
|
|
146
|
+
const pendingLifecycleStartBlockCount = SystemStore.getValue(
|
|
147
|
+
derivations.currentScreenKey,
|
|
148
|
+
"pendingLifecycleStartBlockCount",
|
|
149
|
+
);
|
|
150
|
+
|
|
151
|
+
useLayoutEffect(() => {
|
|
152
|
+
runOnUI(registerScreen)({
|
|
153
|
+
screenKey: derivations.currentScreenKey,
|
|
154
|
+
parentScreenKey: derivations.parentScreenKey,
|
|
155
|
+
animationProgress,
|
|
156
|
+
pendingLifecycleStartBlockCount,
|
|
157
|
+
});
|
|
158
|
+
|
|
159
|
+
return () => {
|
|
160
|
+
runOnUI(unregisterScreen)(derivations.currentScreenKey);
|
|
161
|
+
};
|
|
162
|
+
}, [
|
|
163
|
+
animationProgress,
|
|
164
|
+
derivations.currentScreenKey,
|
|
165
|
+
derivations.parentScreenKey,
|
|
166
|
+
pendingLifecycleStartBlockCount,
|
|
167
|
+
]);
|
|
102
168
|
|
|
103
169
|
return {
|
|
104
170
|
value: {
|
|
@@ -7,6 +7,10 @@ export interface DescriptorDerivations {
|
|
|
7
7
|
currentScreenKey: string;
|
|
8
8
|
nextScreenKey?: string;
|
|
9
9
|
sourcePairKey?: ScreenPairKey;
|
|
10
|
+
/** Nearest source pair owned by this screen or one of its ancestors. */
|
|
11
|
+
transitionSourcePairKey?: ScreenPairKey;
|
|
12
|
+
/** Destination root for the nearest source pair. */
|
|
13
|
+
transitionDestinationScreenKey?: string;
|
|
10
14
|
destinationPairKey?: ScreenPairKey;
|
|
11
15
|
parentScreenKey?: string;
|
|
12
16
|
isFirstKey: boolean;
|
|
@@ -52,6 +56,8 @@ export function deriveDescriptorDerivations({
|
|
|
52
56
|
currentScreenKey,
|
|
53
57
|
nextScreenKey,
|
|
54
58
|
sourcePairKey,
|
|
59
|
+
transitionSourcePairKey: sourcePairKey,
|
|
60
|
+
transitionDestinationScreenKey: nextScreenKey,
|
|
55
61
|
destinationPairKey,
|
|
56
62
|
parentScreenKey: ancestorKeys[0],
|
|
57
63
|
isFirstKey,
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { DescriptorDerivationsContextValue } from "../descriptors.provider";
|
|
2
|
+
|
|
3
|
+
type ParentDescriptorState = Pick<
|
|
4
|
+
DescriptorDerivationsContextValue,
|
|
5
|
+
"currentScreenKey" | "ancestorKeys"
|
|
6
|
+
>;
|
|
7
|
+
|
|
8
|
+
export const deriveStructuralAncestorKeys = (
|
|
9
|
+
parent: ParentDescriptorState | null,
|
|
10
|
+
): string[] => {
|
|
11
|
+
if (!parent) return [];
|
|
12
|
+
return [parent.currentScreenKey, ...parent.ancestorKeys];
|
|
13
|
+
};
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { useMemo } from "react";
|
|
1
|
+
import { Fragment, useMemo } from "react";
|
|
2
2
|
import { Gesture } from "react-native-gesture-handler";
|
|
3
3
|
import { useSharedValue } from "react-native-reanimated";
|
|
4
4
|
import { ScrollStore } from "../../../stores/scroll.store";
|
|
5
5
|
import createProvider from "../../../utils/create-provider";
|
|
6
6
|
import { useDescriptorsStore } from "../descriptors";
|
|
7
7
|
import { useScreenGestureConfig } from "./hooks/use-screen-gesture-config";
|
|
8
|
-
import {
|
|
8
|
+
import { GestureOwnershipBridge } from "./ownership/gesture-ownership-bridge";
|
|
9
9
|
import { useBuildPanGesture } from "./pan/use-build-pan-gesture";
|
|
10
10
|
import { useBuildPinchGesture } from "./pinch/use-build-pinch-gesture";
|
|
11
11
|
import {
|
|
@@ -28,11 +28,16 @@ export const { ScreenGestureProvider, useScreenGestureStore: useGestureStore } =
|
|
|
28
28
|
{ children },
|
|
29
29
|
{ useParentStore },
|
|
30
30
|
): { value: GestureContextType; children: React.ReactNode } => {
|
|
31
|
-
const gestureContext = useParentStore();
|
|
32
|
-
const gestureConfig = useScreenGestureConfig();
|
|
33
31
|
const currentScreenKey = useDescriptorsStore(
|
|
34
32
|
(store) => store.derivations.currentScreenKey,
|
|
35
33
|
);
|
|
34
|
+
const isTopMostScreen = useDescriptorsStore(
|
|
35
|
+
(store) => store.derivations.isTopMostScreen,
|
|
36
|
+
);
|
|
37
|
+
const gestureContext = useParentStore((parentContext) =>
|
|
38
|
+
isTopMostScreen ? parentContext : null,
|
|
39
|
+
);
|
|
40
|
+
const gestureConfig = useScreenGestureConfig(gestureContext);
|
|
36
41
|
|
|
37
42
|
const scrollState = ScrollStore.getValue(
|
|
38
43
|
currentScreenKey,
|
|
@@ -89,13 +94,19 @@ export const { ScreenGestureProvider, useScreenGestureStore: useGestureStore } =
|
|
|
89
94
|
],
|
|
90
95
|
);
|
|
91
96
|
|
|
92
|
-
|
|
93
|
-
|
|
97
|
+
const content = useMemo(
|
|
98
|
+
() => (
|
|
99
|
+
<Fragment>
|
|
100
|
+
<GestureOwnershipBridge />
|
|
101
|
+
{children}
|
|
102
|
+
</Fragment>
|
|
103
|
+
),
|
|
104
|
+
[children],
|
|
94
105
|
);
|
|
95
106
|
|
|
96
107
|
return {
|
|
97
108
|
value,
|
|
98
|
-
children,
|
|
109
|
+
children: content,
|
|
99
110
|
};
|
|
100
111
|
},
|
|
101
112
|
);
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { usePreventRemoveContext } from "@react-navigation/native";
|
|
2
2
|
import { useMemo } from "react";
|
|
3
3
|
import { useDescriptorsStore } from "../../descriptors";
|
|
4
|
-
import { useGestureStore } from "../gestures.provider";
|
|
5
4
|
import { resolveScreenGestureConfig } from "../shared/policy";
|
|
6
|
-
import type { ScreenGestureConfig } from "../types";
|
|
5
|
+
import type { GestureContextType, ScreenGestureConfig } from "../types";
|
|
7
6
|
|
|
8
|
-
export function useScreenGestureConfig(
|
|
9
|
-
|
|
7
|
+
export function useScreenGestureConfig(
|
|
8
|
+
gestureContext: GestureContextType | null,
|
|
9
|
+
): ScreenGestureConfig {
|
|
10
10
|
const options = useDescriptorsStore((store) => store.options);
|
|
11
11
|
const isFirstKey = useDescriptorsStore(
|
|
12
12
|
(store) => store.derivations.isFirstKey,
|