react-native-screen-transitions 4.0.0-alpha.6 → 4.0.0-alpha.7
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/components/boundary/components/boundary-lifecycle.js +36 -0
- package/lib/commonjs/components/boundary/components/boundary-lifecycle.js.map +1 -0
- package/lib/commonjs/components/boundary/components/boundary-target.js +1 -0
- package/lib/commonjs/components/boundary/components/boundary-target.js.map +1 -1
- package/lib/commonjs/components/boundary/create-boundary-component.js +1 -0
- package/lib/commonjs/components/boundary/create-boundary-component.js.map +1 -1
- package/lib/commonjs/components/boundary/hooks/lifecycles/use-initial-destination-measurement.js +1 -13
- package/lib/commonjs/components/boundary/hooks/lifecycles/use-initial-destination-measurement.js.map +1 -1
- package/lib/commonjs/components/boundary/hooks/lifecycles/use-refresh-boundary.js +9 -2
- package/lib/commonjs/components/boundary/hooks/lifecycles/use-refresh-boundary.js.map +1 -1
- package/lib/commonjs/components/boundary/hooks/use-boundary-measurement.js +3 -2
- package/lib/commonjs/components/boundary/hooks/use-boundary-measurement.js.map +1 -1
- package/lib/commonjs/components/boundary/hooks/use-measurer.js +9 -2
- package/lib/commonjs/components/boundary/hooks/use-measurer.js.map +1 -1
- package/lib/commonjs/components/boundary/portal/components/boundary-portal/components/host.js +5 -12
- package/lib/commonjs/components/boundary/portal/components/boundary-portal/components/host.js.map +1 -1
- package/lib/commonjs/components/boundary/portal/components/boundary-portal/components/portal-boundary-host.js +25 -43
- package/lib/commonjs/components/boundary/portal/components/boundary-portal/components/portal-boundary-host.js.map +1 -1
- package/lib/commonjs/components/boundary/portal/components/boundary-portal/helpers/local-measurement.js +13 -0
- package/lib/commonjs/components/boundary/portal/components/boundary-portal/helpers/local-measurement.js.map +1 -0
- package/lib/commonjs/components/boundary/portal/components/boundary-portal/helpers/offset-style.js +8 -31
- package/lib/commonjs/components/boundary/portal/components/boundary-portal/helpers/offset-style.js.map +1 -1
- package/lib/commonjs/components/boundary/portal/components/boundary-portal/hooks/use-active-portal-boundary-host.js +14 -19
- package/lib/commonjs/components/boundary/portal/components/boundary-portal/hooks/use-active-portal-boundary-host.js.map +1 -1
- package/lib/commonjs/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.js +3 -1
- package/lib/commonjs/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.js.map +1 -1
- package/lib/commonjs/components/boundary/portal/components/boundary-portal/hooks/use-host-measurement.js +19 -48
- package/lib/commonjs/components/boundary/portal/components/boundary-portal/hooks/use-host-measurement.js.map +1 -1
- package/lib/commonjs/components/boundary/portal/components/boundary-portal/index.js +6 -2
- package/lib/commonjs/components/boundary/portal/components/boundary-portal/index.js.map +1 -1
- package/lib/commonjs/components/boundary/portal/components/boundary-portal/stores/portal-boundary-host.store.js +1 -1
- package/lib/commonjs/components/boundary/portal/components/boundary-portal/stores/portal-boundary-host.store.js.map +1 -1
- package/lib/commonjs/components/boundary/providers/boundary-root.provider.js +19 -17
- package/lib/commonjs/components/boundary/providers/boundary-root.provider.js.map +1 -1
- package/lib/commonjs/components/boundary/utils/refresh-signals.js +19 -5
- package/lib/commonjs/components/boundary/utils/refresh-signals.js.map +1 -1
- package/lib/commonjs/components/screen-container/layers/backdrop.js +11 -7
- package/lib/commonjs/components/screen-container/layers/backdrop.js.map +1 -1
- package/lib/commonjs/components/screen-lifecycle/hooks/helpers/close-interception-rules.js +32 -0
- package/lib/commonjs/components/screen-lifecycle/hooks/helpers/close-interception-rules.js.map +1 -0
- package/lib/commonjs/components/screen-lifecycle/hooks/use-close-completion.js +27 -0
- package/lib/commonjs/components/screen-lifecycle/hooks/use-close-completion.js.map +1 -0
- package/lib/commonjs/components/screen-lifecycle/hooks/use-close-transition-intent.js +61 -86
- package/lib/commonjs/components/screen-lifecycle/hooks/use-close-transition-intent.js.map +1 -1
- package/lib/commonjs/components/screen-lifecycle/hooks/use-transition-start-controller.js +1 -5
- package/lib/commonjs/components/screen-lifecycle/hooks/use-transition-start-controller.js.map +1 -1
- package/lib/commonjs/components/screen-lifecycle/index.js +9 -6
- package/lib/commonjs/components/screen-lifecycle/index.js.map +1 -1
- package/lib/commonjs/hooks/navigation/use-navigation-helpers.js +30 -13
- package/lib/commonjs/hooks/navigation/use-navigation-helpers.js.map +1 -1
- package/lib/commonjs/providers/helpers/measured-bounds-writes.js +1 -2
- package/lib/commonjs/providers/helpers/measured-bounds-writes.js.map +1 -1
- package/lib/commonjs/providers/screen/gestures/hooks/use-screen-gesture-config.js +9 -2
- package/lib/commonjs/providers/screen/gestures/hooks/use-screen-gesture-config.js.map +1 -1
- package/lib/commonjs/providers/screen/gestures/pan/behavior/pan-lifecycle.js +4 -5
- package/lib/commonjs/providers/screen/gestures/pan/behavior/pan-lifecycle.js.map +1 -1
- package/lib/commonjs/providers/screen/gestures/pan/behavior/use-pan-behavior.js +2 -3
- package/lib/commonjs/providers/screen/gestures/pan/behavior/use-pan-behavior.js.map +1 -1
- package/lib/commonjs/providers/screen/gestures/pinch/behavior/pinch-lifecycle.js +4 -5
- package/lib/commonjs/providers/screen/gestures/pinch/behavior/pinch-lifecycle.js.map +1 -1
- package/lib/commonjs/providers/screen/gestures/pinch/behavior/use-pinch-behavior.js +2 -3
- package/lib/commonjs/providers/screen/gestures/pinch/behavior/use-pinch-behavior.js.map +1 -1
- package/lib/commonjs/providers/screen/gestures/shared/policy.js +9 -5
- package/lib/commonjs/providers/screen/gestures/shared/policy.js.map +1 -1
- package/lib/commonjs/providers/stack/blank-stack-state/blank-stack-controller.js +7 -9
- package/lib/commonjs/providers/stack/blank-stack-state/blank-stack-controller.js.map +1 -1
- package/lib/commonjs/stores/bounds/internals/links.js +1 -1
- package/lib/commonjs/stores/bounds/internals/links.js.map +1 -1
- package/lib/commonjs/stores/system.store.js +1 -2
- package/lib/commonjs/stores/system.store.js.map +1 -1
- package/lib/commonjs/utils/animation/animate-to-progress.js +0 -22
- package/lib/commonjs/utils/animation/animate-to-progress.js.map +1 -1
- package/lib/commonjs/utils/navigation/close-action-replay.js +22 -0
- package/lib/commonjs/utils/navigation/close-action-replay.js.map +1 -0
- package/lib/module/components/boundary/components/boundary-lifecycle.js +32 -0
- package/lib/module/components/boundary/components/boundary-lifecycle.js.map +1 -0
- package/lib/module/components/boundary/components/boundary-target.js +1 -0
- package/lib/module/components/boundary/components/boundary-target.js.map +1 -1
- package/lib/module/components/boundary/create-boundary-component.js +1 -0
- package/lib/module/components/boundary/create-boundary-component.js.map +1 -1
- package/lib/module/components/boundary/hooks/lifecycles/use-initial-destination-measurement.js +1 -13
- package/lib/module/components/boundary/hooks/lifecycles/use-initial-destination-measurement.js.map +1 -1
- package/lib/module/components/boundary/hooks/lifecycles/use-refresh-boundary.js +9 -2
- package/lib/module/components/boundary/hooks/lifecycles/use-refresh-boundary.js.map +1 -1
- package/lib/module/components/boundary/hooks/use-boundary-measurement.js +3 -2
- package/lib/module/components/boundary/hooks/use-boundary-measurement.js.map +1 -1
- package/lib/module/components/boundary/hooks/use-measurer.js +9 -2
- package/lib/module/components/boundary/hooks/use-measurer.js.map +1 -1
- package/lib/module/components/boundary/portal/components/boundary-portal/components/host.js +5 -12
- package/lib/module/components/boundary/portal/components/boundary-portal/components/host.js.map +1 -1
- package/lib/module/components/boundary/portal/components/boundary-portal/components/portal-boundary-host.js +27 -45
- package/lib/module/components/boundary/portal/components/boundary-portal/components/portal-boundary-host.js.map +1 -1
- package/lib/module/components/boundary/portal/components/boundary-portal/helpers/local-measurement.js +8 -0
- package/lib/module/components/boundary/portal/components/boundary-portal/helpers/local-measurement.js.map +1 -0
- package/lib/module/components/boundary/portal/components/boundary-portal/helpers/offset-style.js +8 -32
- package/lib/module/components/boundary/portal/components/boundary-portal/helpers/offset-style.js.map +1 -1
- package/lib/module/components/boundary/portal/components/boundary-portal/hooks/use-active-portal-boundary-host.js +15 -20
- package/lib/module/components/boundary/portal/components/boundary-portal/hooks/use-active-portal-boundary-host.js.map +1 -1
- package/lib/module/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.js +3 -1
- package/lib/module/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.js.map +1 -1
- package/lib/module/components/boundary/portal/components/boundary-portal/hooks/use-host-measurement.js +19 -48
- package/lib/module/components/boundary/portal/components/boundary-portal/hooks/use-host-measurement.js.map +1 -1
- package/lib/module/components/boundary/portal/components/boundary-portal/index.js +6 -2
- package/lib/module/components/boundary/portal/components/boundary-portal/index.js.map +1 -1
- package/lib/module/components/boundary/portal/components/boundary-portal/stores/portal-boundary-host.store.js +1 -1
- package/lib/module/components/boundary/portal/components/boundary-portal/stores/portal-boundary-host.store.js.map +1 -1
- package/lib/module/components/boundary/providers/boundary-root.provider.js +20 -18
- package/lib/module/components/boundary/providers/boundary-root.provider.js.map +1 -1
- package/lib/module/components/boundary/utils/refresh-signals.js +19 -5
- package/lib/module/components/boundary/utils/refresh-signals.js.map +1 -1
- package/lib/module/components/screen-container/layers/backdrop.js +12 -8
- package/lib/module/components/screen-container/layers/backdrop.js.map +1 -1
- package/lib/module/components/screen-lifecycle/hooks/helpers/close-interception-rules.js +26 -0
- package/lib/module/components/screen-lifecycle/hooks/helpers/close-interception-rules.js.map +1 -0
- package/lib/module/components/screen-lifecycle/hooks/use-close-completion.js +22 -0
- package/lib/module/components/screen-lifecycle/hooks/use-close-completion.js.map +1 -0
- package/lib/module/components/screen-lifecycle/hooks/use-close-transition-intent.js +61 -85
- package/lib/module/components/screen-lifecycle/hooks/use-close-transition-intent.js.map +1 -1
- package/lib/module/components/screen-lifecycle/hooks/use-transition-start-controller.js +1 -5
- package/lib/module/components/screen-lifecycle/hooks/use-transition-start-controller.js.map +1 -1
- package/lib/module/components/screen-lifecycle/index.js +9 -6
- package/lib/module/components/screen-lifecycle/index.js.map +1 -1
- package/lib/module/hooks/navigation/use-navigation-helpers.js +30 -13
- package/lib/module/hooks/navigation/use-navigation-helpers.js.map +1 -1
- package/lib/module/providers/helpers/measured-bounds-writes.js +1 -2
- package/lib/module/providers/helpers/measured-bounds-writes.js.map +1 -1
- package/lib/module/providers/screen/gestures/hooks/use-screen-gesture-config.js +9 -2
- package/lib/module/providers/screen/gestures/hooks/use-screen-gesture-config.js.map +1 -1
- package/lib/module/providers/screen/gestures/pan/behavior/pan-lifecycle.js +4 -5
- package/lib/module/providers/screen/gestures/pan/behavior/pan-lifecycle.js.map +1 -1
- package/lib/module/providers/screen/gestures/pan/behavior/use-pan-behavior.js +2 -3
- package/lib/module/providers/screen/gestures/pan/behavior/use-pan-behavior.js.map +1 -1
- package/lib/module/providers/screen/gestures/pinch/behavior/pinch-lifecycle.js +4 -5
- package/lib/module/providers/screen/gestures/pinch/behavior/pinch-lifecycle.js.map +1 -1
- package/lib/module/providers/screen/gestures/pinch/behavior/use-pinch-behavior.js +2 -3
- package/lib/module/providers/screen/gestures/pinch/behavior/use-pinch-behavior.js.map +1 -1
- package/lib/module/providers/screen/gestures/shared/policy.js +9 -5
- package/lib/module/providers/screen/gestures/shared/policy.js.map +1 -1
- package/lib/module/providers/stack/blank-stack-state/blank-stack-controller.js +7 -9
- package/lib/module/providers/stack/blank-stack-state/blank-stack-controller.js.map +1 -1
- package/lib/module/stores/bounds/internals/links.js +1 -1
- package/lib/module/stores/bounds/internals/links.js.map +1 -1
- package/lib/module/stores/system.store.js +1 -2
- package/lib/module/stores/system.store.js.map +1 -1
- package/lib/module/utils/animation/animate-to-progress.js +0 -22
- package/lib/module/utils/animation/animate-to-progress.js.map +1 -1
- package/lib/module/utils/navigation/close-action-replay.js +16 -0
- package/lib/module/utils/navigation/close-action-replay.js.map +1 -0
- package/lib/typescript/components/boundary/components/boundary-lifecycle.d.ts +18 -0
- package/lib/typescript/components/boundary/components/boundary-lifecycle.d.ts.map +1 -0
- package/lib/typescript/components/boundary/components/boundary-target.d.ts.map +1 -1
- package/lib/typescript/components/boundary/create-boundary-component.d.ts.map +1 -1
- package/lib/typescript/components/boundary/hooks/lifecycles/use-initial-destination-measurement.d.ts +1 -2
- package/lib/typescript/components/boundary/hooks/lifecycles/use-initial-destination-measurement.d.ts.map +1 -1
- package/lib/typescript/components/boundary/hooks/lifecycles/use-refresh-boundary.d.ts.map +1 -1
- package/lib/typescript/components/boundary/hooks/use-boundary-measurement.d.ts +3 -2
- package/lib/typescript/components/boundary/hooks/use-boundary-measurement.d.ts.map +1 -1
- package/lib/typescript/components/boundary/hooks/use-measurer.d.ts +3 -2
- package/lib/typescript/components/boundary/hooks/use-measurer.d.ts.map +1 -1
- package/lib/typescript/components/boundary/portal/components/boundary-portal/components/host.d.ts.map +1 -1
- package/lib/typescript/components/boundary/portal/components/boundary-portal/components/portal-boundary-host.d.ts +5 -1
- package/lib/typescript/components/boundary/portal/components/boundary-portal/components/portal-boundary-host.d.ts.map +1 -1
- package/lib/typescript/components/boundary/portal/components/boundary-portal/helpers/local-measurement.d.ts +4 -0
- package/lib/typescript/components/boundary/portal/components/boundary-portal/helpers/local-measurement.d.ts.map +1 -0
- package/lib/typescript/components/boundary/portal/components/boundary-portal/helpers/offset-style.d.ts +4 -17
- package/lib/typescript/components/boundary/portal/components/boundary-portal/helpers/offset-style.d.ts.map +1 -1
- package/lib/typescript/components/boundary/portal/components/boundary-portal/hooks/use-active-portal-boundary-host.d.ts +3 -1
- package/lib/typescript/components/boundary/portal/components/boundary-portal/hooks/use-active-portal-boundary-host.d.ts.map +1 -1
- package/lib/typescript/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.d.ts +3 -1
- package/lib/typescript/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.d.ts.map +1 -1
- package/lib/typescript/components/boundary/portal/components/boundary-portal/hooks/use-host-measurement.d.ts +5 -9
- package/lib/typescript/components/boundary/portal/components/boundary-portal/hooks/use-host-measurement.d.ts.map +1 -1
- package/lib/typescript/components/boundary/portal/components/boundary-portal/index.d.ts +3 -1
- package/lib/typescript/components/boundary/portal/components/boundary-portal/index.d.ts.map +1 -1
- package/lib/typescript/components/boundary/portal/components/boundary-portal/stores/portal-boundary-host.store.d.ts +2 -1
- package/lib/typescript/components/boundary/portal/components/boundary-portal/stores/portal-boundary-host.store.d.ts.map +1 -1
- package/lib/typescript/components/boundary/providers/boundary-root.provider.d.ts +2 -1
- package/lib/typescript/components/boundary/providers/boundary-root.provider.d.ts.map +1 -1
- package/lib/typescript/components/boundary/types.d.ts +6 -0
- package/lib/typescript/components/boundary/types.d.ts.map +1 -1
- package/lib/typescript/components/boundary/utils/refresh-signals.d.ts +1 -0
- package/lib/typescript/components/boundary/utils/refresh-signals.d.ts.map +1 -1
- package/lib/typescript/components/screen-container/layers/backdrop.d.ts.map +1 -1
- package/lib/typescript/components/screen-lifecycle/hooks/helpers/close-interception-rules.d.ts +28 -0
- package/lib/typescript/components/screen-lifecycle/hooks/helpers/close-interception-rules.d.ts.map +1 -0
- package/lib/typescript/components/screen-lifecycle/hooks/use-close-completion.d.ts +7 -0
- package/lib/typescript/components/screen-lifecycle/hooks/use-close-completion.d.ts.map +1 -0
- package/lib/typescript/components/screen-lifecycle/hooks/use-close-transition-intent.d.ts +2 -7
- package/lib/typescript/components/screen-lifecycle/hooks/use-close-transition-intent.d.ts.map +1 -1
- package/lib/typescript/components/screen-lifecycle/hooks/use-transition-start-controller.d.ts +1 -3
- package/lib/typescript/components/screen-lifecycle/hooks/use-transition-start-controller.d.ts.map +1 -1
- package/lib/typescript/components/screen-lifecycle/index.d.ts.map +1 -1
- package/lib/typescript/hooks/navigation/use-navigation-helpers.d.ts +1 -0
- package/lib/typescript/hooks/navigation/use-navigation-helpers.d.ts.map +1 -1
- package/lib/typescript/providers/screen/gestures/hooks/use-screen-gesture-config.d.ts.map +1 -1
- package/lib/typescript/providers/screen/gestures/pan/behavior/pan-lifecycle.d.ts +1 -1
- package/lib/typescript/providers/screen/gestures/pan/behavior/pan-lifecycle.d.ts.map +1 -1
- package/lib/typescript/providers/screen/gestures/pan/behavior/use-pan-behavior.d.ts.map +1 -1
- package/lib/typescript/providers/screen/gestures/pinch/behavior/pinch-lifecycle.d.ts +1 -1
- package/lib/typescript/providers/screen/gestures/pinch/behavior/pinch-lifecycle.d.ts.map +1 -1
- package/lib/typescript/providers/screen/gestures/pinch/behavior/use-pinch-behavior.d.ts.map +1 -1
- package/lib/typescript/providers/screen/gestures/shared/policy.d.ts +2 -1
- package/lib/typescript/providers/screen/gestures/shared/policy.d.ts.map +1 -1
- package/lib/typescript/providers/screen/gestures/types.d.ts +2 -0
- package/lib/typescript/providers/screen/gestures/types.d.ts.map +1 -1
- package/lib/typescript/providers/stack/blank-stack-state/blank-stack-controller.d.ts.map +1 -1
- package/lib/typescript/stores/system.store.d.ts +1 -2
- package/lib/typescript/stores/system.store.d.ts.map +1 -1
- package/lib/typescript/utils/animation/animate-to-progress.d.ts +1 -2
- package/lib/typescript/utils/animation/animate-to-progress.d.ts.map +1 -1
- package/lib/typescript/utils/navigation/close-action-replay.d.ts +4 -0
- package/lib/typescript/utils/navigation/close-action-replay.d.ts.map +1 -0
- package/package.json +1 -1
- package/src/components/boundary/components/boundary-lifecycle.tsx +53 -0
- package/src/components/boundary/components/boundary-target.tsx +1 -0
- package/src/components/boundary/create-boundary-component.tsx +1 -0
- package/src/components/boundary/hooks/lifecycles/use-initial-destination-measurement.ts +0 -14
- package/src/components/boundary/hooks/lifecycles/use-refresh-boundary.ts +13 -2
- package/src/components/boundary/hooks/use-boundary-measurement.ts +7 -2
- package/src/components/boundary/hooks/use-measurer.ts +11 -1
- package/src/components/boundary/portal/components/boundary-portal/components/host.tsx +13 -11
- package/src/components/boundary/portal/components/boundary-portal/components/portal-boundary-host.tsx +44 -55
- package/src/components/boundary/portal/components/boundary-portal/helpers/local-measurement.ts +10 -0
- package/src/components/boundary/portal/components/boundary-portal/helpers/offset-style.ts +11 -55
- package/src/components/boundary/portal/components/boundary-portal/hooks/use-active-portal-boundary-host.ts +20 -24
- package/src/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.ts +6 -0
- package/src/components/boundary/portal/components/boundary-portal/hooks/use-host-measurement.ts +20 -68
- package/src/components/boundary/portal/components/boundary-portal/index.tsx +19 -3
- package/src/components/boundary/portal/components/boundary-portal/stores/portal-boundary-host.store.ts +3 -2
- package/src/components/boundary/providers/boundary-root.provider.tsx +29 -20
- package/src/components/boundary/types.ts +9 -0
- package/src/components/boundary/utils/refresh-signals.ts +39 -6
- package/src/components/screen-container/layers/backdrop.tsx +11 -7
- package/src/components/screen-lifecycle/hooks/helpers/close-interception-rules.ts +66 -0
- package/src/components/screen-lifecycle/hooks/use-close-completion.ts +25 -0
- package/src/components/screen-lifecycle/hooks/use-close-transition-intent.ts +68 -108
- package/src/components/screen-lifecycle/hooks/use-transition-start-controller.ts +0 -12
- package/src/components/screen-lifecycle/index.tsx +8 -4
- package/src/hooks/navigation/use-navigation-helpers.ts +40 -12
- package/src/providers/helpers/measured-bounds-writes.ts +1 -1
- package/src/providers/screen/gestures/hooks/use-screen-gesture-config.ts +9 -1
- package/src/providers/screen/gestures/pan/behavior/pan-lifecycle.ts +4 -6
- package/src/providers/screen/gestures/pan/behavior/use-pan-behavior.ts +1 -3
- package/src/providers/screen/gestures/pinch/behavior/pinch-lifecycle.ts +4 -6
- package/src/providers/screen/gestures/pinch/behavior/use-pinch-behavior.ts +2 -8
- package/src/providers/screen/gestures/shared/policy.ts +17 -6
- package/src/providers/screen/gestures/types.ts +2 -0
- package/src/providers/stack/blank-stack-state/blank-stack-controller.ts +7 -7
- package/src/stores/bounds/internals/links.ts +1 -1
- package/src/stores/system.store.ts +1 -2
- package/src/utils/animation/animate-to-progress.ts +0 -23
- package/src/utils/navigation/close-action-replay.ts +25 -0
- package/lib/commonjs/components/boundary/portal/components/boundary-portal/helpers/active-pair.js +0 -30
- package/lib/commonjs/components/boundary/portal/components/boundary-portal/helpers/active-pair.js.map +0 -1
- package/lib/commonjs/components/boundary/portal/components/boundary-portal/stores/host-bounds.store.js +0 -47
- package/lib/commonjs/components/boundary/portal/components/boundary-portal/stores/host-bounds.store.js.map +0 -1
- package/lib/module/components/boundary/portal/components/boundary-portal/helpers/active-pair.js +0 -25
- package/lib/module/components/boundary/portal/components/boundary-portal/helpers/active-pair.js.map +0 -1
- package/lib/module/components/boundary/portal/components/boundary-portal/stores/host-bounds.store.js +0 -40
- package/lib/module/components/boundary/portal/components/boundary-portal/stores/host-bounds.store.js.map +0 -1
- package/lib/typescript/components/boundary/portal/components/boundary-portal/helpers/active-pair.d.ts +0 -9
- package/lib/typescript/components/boundary/portal/components/boundary-portal/helpers/active-pair.d.ts.map +0 -1
- package/lib/typescript/components/boundary/portal/components/boundary-portal/stores/host-bounds.store.d.ts +0 -9
- package/lib/typescript/components/boundary/portal/components/boundary-portal/stores/host-bounds.store.d.ts.map +0 -1
- package/src/components/boundary/portal/components/boundary-portal/helpers/active-pair.ts +0 -36
- package/src/components/boundary/portal/components/boundary-portal/stores/host-bounds.store.ts +0 -45
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["memo","useDescriptorsStore","useBoundaryMeasurement","BoundaryLifecycle","boundTag","config","currentScreenKey","enabled","escapeClipping","handoff","localMeasurement","measuredRef","style","hasConfiguredInterpolator","s","derivations","runtimeEnabled"],"sourceRoot":"../../../../../src","sources":["components/boundary/components/boundary-lifecycle.tsx"],"mappings":";;AAAA,SAASA,IAAI,QAAQ,OAAO;AAG5B,SAASC,mBAAmB,QAAQ,uCAAuC;AAE3E,SAASC,sBAAsB,QAAQ,mCAAmC;AAkB1E,OAAO,MAAMC,iBAAiB,gBAAGH,IAAI,CAAC,SAASG,iBAAiBA,CAAC;EAChEC,QAAQ;EACRC,MAAM;EACNC,gBAAgB;EAChBC,OAAO;EACPC,cAAc;EACdC,OAAO;EACPC,gBAAgB;EAChBC,WAAW;EACXC;AACuB,CAAC,EAAE;EAC1B,MAAMC,yBAAyB,GAAGZ,mBAAmB,CACnDa,CAAC,IAAKA,CAAC,CAACC,WAAW,CAACF,yBACtB,CAAC;EAEDX,sBAAsB,CAAC;IACtBE,QAAQ;IACRG,OAAO;IACPS,cAAc,EAAET,OAAO,IAAIM,yBAAyB;IACpDP,gBAAgB;IAChBK,WAAW;IACXC,KAAK;IACLH,OAAO;IACPD,cAAc;IACdE,gBAAgB;IAChBL;EACD,CAAC,CAAC;EAEF,OAAO,IAAI;AACZ,CAAC,CAAC","ignoreList":[]}
|
|
@@ -36,6 +36,7 @@ const BoundaryTargetInner = props => {
|
|
|
36
36
|
return /*#__PURE__*/_jsx(BoundaryPortal, {
|
|
37
37
|
boundaryId: boundaryId ?? "",
|
|
38
38
|
enabled: shouldEscapeTargetToScreenHost,
|
|
39
|
+
localMeasurement: rootContext?.localMeasurement,
|
|
39
40
|
placeholderRef: measurementRef,
|
|
40
41
|
children: /*#__PURE__*/_jsx(Animated.View, {
|
|
41
42
|
...rest,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["memo","useLayoutEffect","Animated","useComposedSlotStyles","useSlotLayoutStyles","logger","BoundaryContentPortal","BoundaryContentPortalHost","BoundaryPortal","TARGET_OUTSIDE_ROOT_WARNING","useBoundaryRootStore","jsx","_jsx","BOUNDARY_TARGET_ACTIVE_PROP","BoundaryTargetInner","props","active","children","pointerEvents","style","rest","rootContext","boundaryId","boundTag","tag","isActiveTarget","portalRuntime","handoffEnabled","shouldEscapeTargetToScreenHost","escapeClipping","shouldApplyAssociatedStyleInline","shouldApplyPortalLayoutStyle","associatedTargetStyles","portalLayoutStyle","measurementRef","undefined","__DEV__","warn","enabled","placeholderRef","View","ref","collapsable","screenKey","currentScreenKey","BoundaryTarget"],"sourceRoot":"../../../../../src","sources":["components/boundary/components/boundary-target.tsx"],"mappings":";;AACA,SAASA,IAAI,EAAEC,eAAe,QAAQ,OAAO;AAC7C,OAAOC,QAAQ,MAAM,yBAAyB;AAC9C,SACCC,qBAAqB,EACrBC,mBAAmB,QACb,kCAAkC;AACzC,SAASC,MAAM,QAAQ,uBAAuB;AAC9C,SACCC,qBAAqB,EACrBC,yBAAyB,QACnB,8CAA8C;AACrD,SAASC,cAAc,QAAQ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W,CAAC,CAAC;EAEjB,oBACCT,IAAA,CAACJ,cAAc;IACdc,UAAU,EAAEA,UAAU,IAAI,EAAG;IAC7BgB,OAAO,EAAEV,8BAA+B;IACxCW,cAAc,
|
|
1
|
+
{"version":3,"names":["memo","useLayoutEffect","Animated","useComposedSlotStyles","useSlotLayoutStyles","logger","BoundaryContentPortal","BoundaryContentPortalHost","BoundaryPortal","TARGET_OUTSIDE_ROOT_WARNING","useBoundaryRootStore","jsx","_jsx","BOUNDARY_TARGET_ACTIVE_PROP","BoundaryTargetInner","props","active","children","pointerEvents","style","rest","rootContext","boundaryId","boundTag","tag","isActiveTarget","portalRuntime","handoffEnabled","shouldEscapeTargetToScreenHost","escapeClipping","shouldApplyAssociatedStyleInline","shouldApplyPortalLayoutStyle","associatedTargetStyles","portalLayoutStyle","measurementRef","undefined","__DEV__","warn","enabled","localMeasurement","placeholderRef","View","ref","collapsable","screenKey","currentScreenKey","BoundaryTarget"],"sourceRoot":"../../../../../src","sources":["components/boundary/components/boundary-target.tsx"],"mappings":";;AACA,SAASA,IAAI,EAAEC,eAAe,QAAQ,OAAO;AAC7C,OAAOC,QAAQ,MAAM,yBAAyB;AAC9C,SACCC,qBAAqB,EACrBC,mBAAmB,QACb,kCAAkC;AACzC,SAASC,MAAM,QAAQ,uBAAuB;AAC9C,SACCC,qBAAqB,EACrBC,yBAAyB,QACnB,8CAA8C;AACrD,SAASC,cAAc,QAAQ,sCAAsC;AACrE,SACCC,2BAA2B,EAC3BC,oBAAoB,QACd,qCAAqC;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAS7C,OAAO,MAAMC,2BAA2B,GAAG,wBAAiC;AAK5E,MAAMC,mBAAmB,GAAIC,KAAkC,IAAK;EACnE,MAAM;IACL,CAACF,2BAA2B,GAAGG,MAAM;IACrCC,QAAQ;IACRC,aAAa;IACbC,KAAK;IACL,GAAGC;EACJ,CAAC,GAAGL,KAAK;EACT,MAAMM,WAAW,GAAGX,oBAAoB,CAAC,CAAC;EA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jEf,KAAK,EAAE,CACNA,KAAK,EACLW,gCAAgC,GAAGE,sBAAsB,GAAGG,SAAS,EACrEJ,4BAA4B,GAAGE,iBAAiB,GAAGE,SAAS,CAC3D;MACFQ,WAAW,EAAE,KAAM;MAAA1B,QAAA,eAEnBL,IAAA,CAACL,yBAAyB;QACzBe,UAAU,EAAEA,UAAU,IAAI,EAAG;QAC7BgB,OAAO,EAAEX,cAAe;QACxBiB,SAAS,EAAEvB,WAAW,EAAEwB,gBAAgB,IAAI,EAAG;QAAA5B,QAAA,eAE/CL,IAAA,CAACN,qBAAqB;UACrBgB,UAAU,EAAEA,UAAW;UACvBgB,OAAO,EAAEX,cAAe;UAAAV,QAAA,EAEvBA;QAAQ,CACa;MAAC,CACE;IAAC,CACd;EAAC,CACD,CAAC;AAEnB,CAAC;AAED,OAAO,MAAM6B,cAAc,gBAAG9C,IAAI,CACjCc,mBACD,CAAoD","ignoreList":[]}
|
|
@@ -57,6 +57,7 @@ export function createBoundaryComponent(Wrapped, options = {}) {
|
|
|
57
57
|
children: root => /*#__PURE__*/_jsx(BoundaryPortal, {
|
|
58
58
|
boundaryId: root.boundTag.tag,
|
|
59
59
|
enabled: root.shouldRenderBoundaryRootThroughPortal,
|
|
60
|
+
localMeasurement: root.localMeasurement,
|
|
60
61
|
placeholderRef: root.measurementRef,
|
|
61
62
|
children: /*#__PURE__*/_jsx(AnimatedComponent, {
|
|
62
63
|
...rest,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["cloneElement","forwardRef","memo","useMemo","Animated","BOUNDARY_TARGET_ACTIVE_PROP","BoundaryTarget","BoundaryContentPortalHost","BoundaryPortal","BoundaryRootProvider","resolveBoundaryTarget","jsx","_jsx","createBoundaryComponent","Wrapped","options","alreadyAnimated","AnimatedComponent","createAnimatedComponent","Inner","props","forwardedRef","enabled","group","id","anchor","scaleMode","target","method","style","handoff","escapeClipping","children","rest","targetResolution","isTarget","element","type","mapTarget","selected","targetStyle","config","hasTarget","targetCount","root","boundaryId","boundTag","tag","shouldRenderBoundaryRootThroughPortal","placeholderRef","measurementRef","ref","attachedStyle","collapsable","shouldRenderHandoffHost","screenKey","currentScreenKey"],"sourceRoot":"../../../../src","sources":["components/boundary/create-boundary-component.tsx"],"mappings":";;AAAA,SAECA,YAAY,EACZC,UAAU,EACVC,IAAI,EACJC,OAAO,QACD,OAAO;AACd,OAAOC,QAAQ,MAAM,yBAAyB;AAC9C,SACCC,2BAA2B,EAC3BC,cAAc,QACR,8BAA8B;AACrC,SAASC,yBAAyB,QAAQ,6CAA6C;AACvF,SAASC,cAAc,QAAQ,qCAAqC;AACpE,SAASC,oBAAoB,QAAQ,oCAAoC;AAEzE,SAASC,qBAAqB,QAAQ,iCAAiC;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAMxE,OAAO,SAASC,uBAAuBA,CACtCC,OAAyB,EACzBC,OAAuC,GAAG,CAAC,CAAC,EAC3C;EACD,MAAM;IAAEC,eAAe,GAAG;EAAM,CAAC,GAAGD,OAAO;EAC3C,MAAME,iBAAiB,GAAGD,eAAe,GACtCF,OAAO,GACPV,QAAQ,CAACc,uBAAuB,CAACJ,OAAO,CAAC;EAE5C,MAAMK,KAAK,gBAAGlB,UAAU,CAGtB,CAACmB,KAAK,EAAEC,YAAY,KAAK;IAC1B,MAAM;MACLC,OAAO,GAAG,IAAI;MACdC,KAAK;MACLC,EAAE;MACFC,MAAM;MACNC,SAAS;MACTC,MAAM;MACNC,MAAM;MACNC,KAAK;MACLC,OAAO;MACPC,cAAc;MACdC,QAAQ;MACR,GAAGC;IACJ,CAAC,GAAGb,KAAY;IAChB,MAAMc,gBAAgB,GAAG/B,OAAO,CAAC,MAAM;MACtC,OAAOO,qBAAqB,CAACsB,QAAQ,EAAE;QACtCG,QAAQ,EAAGC,OAAO,IAAKA,OAAO,CAACC,IAAI,KAAK/B,cAAc;QACtDgC,SAAS,EAAEA,CAACF,OAAO,EAAEG,QAAQ,kBAC5BvC,YAAY,CAACoC,OAAO,EAAE;UACrB,CAAC/B,2BAA2B,GAAGkC;QAChC,CAAQ;MACV,CAAC,CAAC;IACH,CAAC,EAAE,CAACP,QAAQ,CAAC,CAAC;IACd,MAAMQ,WAAW,GAChBN,gBAAgB,CAACP,MAAM,EAAEP,KAAK,EAC5BS,KAAK;IAER,oBACCjB,IAAA,CAACH,oBAAoB;MACpBgC,MAAM,EAAE;QAAEhB,MAAM;QAAEC,SAAS;QAAEC,MAAM;QAAEC;MAAO,CAAE;MAC9CN,OAAO,EAAEA,OAAQ;MACjBS,cAAc,EAAEA,cAAe;MAC/BV,YAAY,EAAEA,YAAa;MAC3BE,KAAK,EAAEA,KAAM;MACbO,OAAO,EAAEA,OAAQ;MACjBY,SAAS,EAAER,gBAAgB,CAACP,MAAM,KAAK,IAAK;MAC5CH,EAAE,EAAEA,EAAG;MACPK,KAAK,EAAEA,KAAM;MACbc,WAAW,EAAET,gBAAgB,CAACS,WAAY;MAC1CH,WAAW,EAAEA,WAAY;MAAAR,QAAA,EAEvBY,IAAI,iBACLhC,IAAA,CAACJ,cAAc;QACdqC,UAAU,EAAED,IAAI,CAACE,QAAQ,CAACC,GAAI;QAC9BzB,OAAO,EAAEsB,IAAI,CAACI,qCAAsC;QACpDC,
|
|
1
|
+
{"version":3,"names":["cloneElement","forwardRef","memo","useMemo","Animated","BOUNDARY_TARGET_ACTIVE_PROP","BoundaryTarget","BoundaryContentPortalHost","BoundaryPortal","BoundaryRootProvider","resolveBoundaryTarget","jsx","_jsx","createBoundaryComponent","Wrapped","options","alreadyAnimated","AnimatedComponent","createAnimatedComponent","Inner","props","forwardedRef","enabled","group","id","anchor","scaleMode","target","method","style","handoff","escapeClipping","children","rest","targetResolution","isTarget","element","type","mapTarget","selected","targetStyle","config","hasTarget","targetCount","root","boundaryId","boundTag","tag","shouldRenderBoundaryRootThroughPortal","localMeasurement","placeholderRef","measurementRef","ref","attachedStyle","collapsable","shouldRenderHandoffHost","screenKey","currentScreenKey"],"sourceRoot":"../../../../src","sources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CAAC;AAMnB","ignoreList":[]}
|
package/lib/module/components/boundary/hooks/lifecycles/use-initial-destination-measurement.js
CHANGED
|
@@ -26,7 +26,6 @@ const MAX_HANDSHAKE_RETRIES = 20;
|
|
|
26
26
|
export const useInitialDestinationMeasurement = ({
|
|
27
27
|
boundTag,
|
|
28
28
|
enabled,
|
|
29
|
-
escapeClipping,
|
|
30
29
|
measureBoundary
|
|
31
30
|
}) => {
|
|
32
31
|
const {
|
|
@@ -89,16 +88,11 @@ export const useInitialDestinationMeasurement = ({
|
|
|
89
88
|
}
|
|
90
89
|
scheduleOnUI(claimLifecycleStartBlock);
|
|
91
90
|
return () => {
|
|
92
|
-
if (escapeClipping) {
|
|
93
|
-
// The portal host owns the release after this boundary hands off.
|
|
94
|
-
return;
|
|
95
|
-
}
|
|
96
|
-
|
|
97
91
|
// This is an abandonment fallback, not a second release. Run it on the UI
|
|
98
92
|
// runtime so it serializes with the handshake's guarded release.
|
|
99
93
|
scheduleOnUI(releaseLifecycleStartBlock);
|
|
100
94
|
};
|
|
101
|
-
}, [claimLifecycleStartBlock,
|
|
95
|
+
}, [claimLifecycleStartBlock, canReceiveDestination, releaseLifecycleStartBlock]);
|
|
102
96
|
useAnimatedReaction(() => {
|
|
103
97
|
"worklet";
|
|
104
98
|
|
|
@@ -158,12 +152,6 @@ export const useInitialDestinationMeasurement = ({
|
|
|
158
152
|
cancelAnimation(retryToken);
|
|
159
153
|
handshakeRetries.set(0);
|
|
160
154
|
hasFinishedInitialMeasurement.set(1);
|
|
161
|
-
if (escapeClipping) {
|
|
162
|
-
// Screen-level escape has a second readiness phase after destination
|
|
163
|
-
// matching: the host must commit before the transition starts, or
|
|
164
|
-
// the payload can disappear for a frame.
|
|
165
|
-
return;
|
|
166
|
-
}
|
|
167
155
|
releaseLifecycleStartBlock();
|
|
168
156
|
return;
|
|
169
157
|
}
|
package/lib/module/components/boundary/hooks/lifecycles/use-initial-destination-measurement.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["useCallback","useLayoutEffect","useMemo","cancelAnimation","useAnimatedReaction","useSharedValue","withDelay","withTiming","scheduleOnUI","useStack","useDescriptorsStore","AnimationStore","createScreenPairKey","getSourceScreenKeyFromPairKey","getEntry","getMatchingSourceScreenKey","getLink","pairs","SystemStore","logger","getInitialDestinationMeasurementSignal","HANDSHAKE_RETRY_DELAY_MS","MAX_HANDSHAKE_RETRIES","useInitialDestinationMeasurement","boundTag","enabled","
|
|
1
|
+
{"version":3,"names":["useCallback","useLayoutEffect","useMemo","cancelAnimation","useAnimatedReaction","useSharedValue","withDelay","withTiming","scheduleOnUI","useStack","useDescriptorsStore","AnimationStore","createScreenPairKey","getSourceScreenKeyFromPairKey","getEntry","getMatchingSourceScreenKey","getLink","pairs","SystemStore","logger","getInitialDestinationMeasurementSignal","HANDSHAKE_RETRY_DELAY_MS","MAX_HANDSHAKE_RETRIES","useInitialDestinationMeasurement","boundTag","enabled","measureBoundary","tag","linkKey","group","currentScreenKey","s","derivations","nextScreenKey","destinationPairKey","destinationEnabled","canReceiveDestination","preferredSourceScreenKey","undefined","stackScenes","store","scenes","closingSourceScreenKeys","filter","scene","activity","map","route","key","progress","getValue","actions","blockLifecycleStart","unblockLifecycleStart","getBag","isBlockingLifecycleStart","retryToken","handshakeRetries","hasGivenUp","hasFinishedInitialMeasurement","releaseLifecycleStartBlock","get","set","claimLifecycleStartBlock","retryTick","sourceScreenKey","pairKey","signal","linkId","destinationPresent","sourcePresent","linkState","action","next","previous","measurePairKey","previousMeasurePairKey","previousAction","previousRetryTick","shouldHandleSignal","type","link","linkComplete","source","destination","warn","duration"],"sourceRoot":"../../../../../../src","sources":["components/boundary/hooks/lifecycles/use-initial-destination-measurement.ts"],"mappings":";;AAAA,SAASA,WAAW,EAAEC,eAAe,EAAEC,OAAO,QAAQ,OAAO;AAC7D,SACCC,eAAe,EACfC,mBAAmB,EACnBC,cAAc,EACdC,SAAS,EACTC,UAAU,QACJ,yBAAyB;AAChC,SAAS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AAa;QACnBd,OAAO,EAAES;MACV,CAAC,CAAC;IACH;IAEA,MAAMM,IAAI,GAAGN,cAAc,GAAG3D,OAAO,CAAC2D,cAAc,EAAE/C,OAAO,CAAC,GAAG,IAAI;IACrE,MAAMsD,YAAY,GAAG,CAAC,CAACD,IAAI,EAAEE,MAAM,IAAI,CAAC,CAACF,IAAI,CAACG,WAAW;IAEzD,IAAIF,YAAY,IAAIV,MAAM,KAAK,UAAU,EAAE;MAC1CrE,eAAe,CAACqD,UAAU,CAAC;MAC3BC,gBAAgB,CAACK,GAAG,CAAC,CAAC,CAAC;MACvBH,6BAA6B,CAACG,GAAG,CAAC,CAAC,CAAC;MACpCF,0BAA0B,CAAC,CAAC;MAC5B;IACD;IAEA,IAAIH,gBAAgB,CAACI,GAAG,CAAC,CAAC,IAAIvC,qBAAqB,EAAE;MACpDoC,UAAU,CAACI,GAAG,CAAC,CAAC,CAAC;MACjBF,0BAA0B,CAAC,CAAC;MAC5BzC,MAAM,CAACkE,IAAI,CACV,aAAazD,OAAO,2DAA2DN,qBAAqB,oGACrG,CAAC;MACD;IACD;;IAEA;IACA;IACAmC,gBAAgB,CAACK,GAAG,CAACL,gBAAgB,CAACI,GAAG,CAAC,CAAC,GAAG,CAAC,CAAC;IAChD1D,eAAe,CAACqD,UAAU,CAAC;IAC3BA,UAAU,CAACM,GAAG,CACbxD,SAAS,CACRe,wBAAwB,EACxBd,UAAU,CAACiD,UAAU,CAACK,GAAG,CAAC,CAAC,GAAG,CAAC,EAAE;MAAEyB,QAAQ,EAAE;IAAE,CAAC,CACjD,CACD,CAAC;EACF,CACD,CAAC;AACF,CAAC","ignoreList":[]}
|
|
@@ -21,12 +21,18 @@ export const useRefreshBoundary = ({
|
|
|
21
21
|
// Destination-side boundaries have no next screen, so they refresh from self.
|
|
22
22
|
const refreshScreenKey = nextScreenKey ?? currentScreenKey;
|
|
23
23
|
const refreshWillAnimate = AnimationStore.getValue(refreshScreenKey, "willAnimate");
|
|
24
|
+
const refreshSettled = AnimationStore.getValue(refreshScreenKey, "progressSettled");
|
|
24
25
|
const refreshClosing = AnimationStore.getValue(refreshScreenKey, "closing");
|
|
25
26
|
useAnimatedReaction(() => {
|
|
26
27
|
"worklet";
|
|
27
28
|
|
|
28
|
-
|
|
29
|
-
|
|
29
|
+
if (!enabled) return null;
|
|
30
|
+
const shouldRefresh = !!refreshWillAnimate.get();
|
|
31
|
+
const settled = !!refreshSettled.get();
|
|
32
|
+
// A group's active member can change while the transition is settled
|
|
33
|
+
// (for example, paging a destination gallery). Let that member publish
|
|
34
|
+
// fresh bounds even though there is no willAnimate lifecycle pulse yet.
|
|
35
|
+
if (!shouldRefresh && (!group || !settled)) {
|
|
30
36
|
return null;
|
|
31
37
|
}
|
|
32
38
|
const sourcePairKey = getPairKeyForSource(boundTag.tag, currentScreenKey) ?? undefined;
|
|
@@ -39,6 +45,7 @@ export const useRefreshBoundary = ({
|
|
|
39
45
|
linkId: linkKey,
|
|
40
46
|
group,
|
|
41
47
|
shouldRefresh,
|
|
48
|
+
settled,
|
|
42
49
|
closing: !!refreshClosing.get(),
|
|
43
50
|
linkState: pairs.get()
|
|
44
51
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["useAnimatedReaction","useDescriptorsStore","AnimationStore","getPairKeyForDestination","getPairKeyForSource","pairs","getRefreshBoundarySignal","useRefreshBoundary","enabled","boundTag","measureBoundary","linkKey","group","currentScreenKey","s","derivations","nextScreenKey","refreshScreenKey","refreshWillAnimate","getValue","refreshClosing","shouldRefresh","get","sourcePairKey","tag","undefined","destinationPairKey","linkId","closing","linkState","refreshSignal","prevRefreshSignal","signal","type","pairKey"],"sourceRoot":"../../../../../../src","sources":["components/boundary/hooks/lifecycles/use-refresh-boundary.ts"],"mappings":";;AAAA,SAASA,mBAAmB,QAAQ,yBAAyB;AAC7D,SAASC,mBAAmB,QAAQ,0CAA0C;AAC9E,SAASC,cAAc,QAAQ,oCAAoC;AACnE,SACCC,wBAAwB,EACxBC,mBAAmB,QACb,2CAA2C;AAClD,SAASC,KAAK,QAAQ,2CAA2C;AAGjE,SAASC,wBAAwB,QAAQ,6BAA6B;AAQtE,OAAO,MAAMC,kBAAkB,GAAGA,CAAC;EAClCC,OAAO;EACPC,QAAQ;EACRC;AACyB,CAAC,KAAK;EAC/B,MAAM;IAAEC,OAAO;IAAEC;EAAM,CAAC,GAAGH,QAAQ;EACnC,MAAMI,gBAAgB,GAAGZ,mBAAmB,CAC1Ca,CAAC,IAAKA,CAAC,CAACC,WAAW,CAACF,gBACtB,CAAC;EACD,MAAMG,aAAa,GAAGf,mBAAmB,CAAEa,CAAC,IAAKA,CAAC,CAACC,WAAW,CAACC,aAAa,CAAC;EAC7E;EACA;EACA,MAAMC,gBAAgB,GAAGD,aAAa,IAAIH,gBAAgB;EAC1D,MAAMK,kBAAkB,GAAGhB,cAAc,CAACiB,QAAQ,CACjDF,gBAAgB,EAChB,aACD,CAAC;EACD,MAAMG,cAAc,GAAGlB,cAAc,CAACiB,QAAQ,CAACF,gBAAgB,EAAE,SAAS,CAAC;EAE3EjB,mBAAmB,CAClB,MAAM;IACL,SAAS;;IAET,
|
|
1
|
+
{"version":3,"names":["useAnimatedReaction","useDescriptorsStore","AnimationStore","getPairKeyForDestination","getPairKeyForSource","pairs","getRefreshBoundarySignal","useRefreshBoundary","enabled","boundTag","measureBoundary","linkKey","group","currentScreenKey","s","derivations","nextScreenKey","refreshScreenKey","refreshWillAnimate","getValue","refreshSettled","refreshClosing","shouldRefresh","get","settled","sourcePairKey","tag","undefined","destinationPairKey","linkId","closing","linkState","refreshSignal","prevRefreshSignal","signal","type","pairKey"],"sourceRoot":"../../../../../../src","sources":["components/boundary/hooks/lifecycles/use-refresh-boundary.ts"],"mappings":";;AAAA,SAASA,mBAAmB,QAAQ,yBAAyB;AAC7D,SAASC,mBAAmB,QAAQ,0CAA0C;AAC9E,SAASC,cAAc,QAAQ,oCAAoC;AACnE,SACCC,wBAAwB,EACxBC,mBAAmB,QACb,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,gBAAgB,CAAC,IAAIc,SAAS;IAEtE,OAAOrB,wBAAwB,CAAC;MAC/BE,OAAO;MACPK,gBAAgB;MAChBY,aAAa;MACbG,kBAAkB;MAClBC,MAAM,EAAElB,OAAO;MACfC,KAAK;MACLU,aAAa;MACbE,OAAO;MACPM,OAAO,EAAE,CAAC,CAACT,cAAc,CAACE,GAAG,CAAC,CAAC;MAC/BQ,SAAS,EAAE1B,KAAK,CAACkB,GAAG,CAAC;IACtB,CAAC,CAAC;EACH,CAAC,EACD,CAACS,aAAa,EAAEC,iBAAiB,KAAK;IACrC,SAAS;;IAET,IACC,CAACD,aAAa,IACdA,aAAa,CAACE,MAAM,KAAKD,iBAAiB,EAAEC,MAAM,EACjD;MACD;IACD;IAEAxB,eAAe,CAAC;MACfyB,IAAI,EAAEH,aAAa,CAACG,IAAI;MACxBC,OAAO,EAAEJ,aAAa,CAACI;IACxB,CAAC,CAAC;EACH,CACD,CAAC;AACF,CAAC","ignoreList":[]}
|
|
@@ -21,6 +21,7 @@ export const useBoundaryMeasurement = ({
|
|
|
21
21
|
style,
|
|
22
22
|
handoff,
|
|
23
23
|
escapeClipping,
|
|
24
|
+
localMeasurement,
|
|
24
25
|
config
|
|
25
26
|
}) => {
|
|
26
27
|
const {
|
|
@@ -43,7 +44,8 @@ export const useBoundaryMeasurement = ({
|
|
|
43
44
|
preparedStyles,
|
|
44
45
|
measuredAnimatedRef: measuredRef,
|
|
45
46
|
handoff,
|
|
46
|
-
escapeClipping
|
|
47
|
+
escapeClipping,
|
|
48
|
+
localMeasurement
|
|
47
49
|
});
|
|
48
50
|
|
|
49
51
|
// Presence and source capture must not depend on this screen owning an
|
|
@@ -65,7 +67,6 @@ export const useBoundaryMeasurement = ({
|
|
|
65
67
|
useInitialDestinationMeasurement({
|
|
66
68
|
boundTag,
|
|
67
69
|
enabled: runtimeEnabled,
|
|
68
|
-
escapeClipping,
|
|
69
70
|
measureBoundary
|
|
70
71
|
});
|
|
71
72
|
useRefreshBoundary({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["useMemo","prepareStyleForBounds","useBoundaryPresence","useInitialDestinationMeasurement","useInitialSourceMeasurement","useRefreshBoundary","useMeasurer","useBoundaryMeasurement","boundTag","enabled","runtimeEnabled","currentScreenKey","measuredRef","style","handoff","escapeClipping","config","anchor","scaleMode","target","method","boundaryConfig","preparedStyles","measureBoundary","measuredAnimatedRef"],"sourceRoot":"../../../../../src","sources":["components/boundary/hooks/use-boundary-measurement.ts"],"mappings":";;AAAA,SAASA,OAAO,QAAQ,OAAO;AAI/B,SAASC,qBAAqB,QAAQ,6CAA6C;
|
|
1
|
+
{"version":3,"names":["useMemo","prepareStyleForBounds","useBoundaryPresence","useInitialDestinationMeasurement","useInitialSourceMeasurement","useRefreshBoundary","useMeasurer","useBoundaryMeasurement","boundTag","enabled","runtimeEnabled","currentScreenKey","measuredRef","style","handoff","escapeClipping","localMeasurement","config","anchor","scaleMode","target","method","boundaryConfig","preparedStyles","measureBoundary","measuredAnimatedRef"],"sourceRoot":"../../../../../src","sources":["components/boundary/hooks/use-boundary-measurement.ts"],"mappings":";;AAAA,SAASA,OAAO,QAAQ,OAAO;AAI/B,SAASC,qBAAqB,QAAQ,6CAA6C;AAKnF,SAASC,mBAAmB,QAAQ,oCAAoC;AACxE,SAASC,gCAAgC,QAAQ,kDAAkD;AACnG,SAASC,2BAA2B,QAAQ,6CAA6C;AACzF,SAASC,kBAAkB,QAAQ,mCAAmC;AACtE,SAASC,WAAW,QAAQ,gBAAgB;AAmB5C;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMC,sBAAsB,GAAGA,CAAC;EACtCC,QAAQ;EACRC,OAAO;EACPC,cAAc;EACdC,gBAAgB;EAChBC,WAAW;EACXC,KAAK;EACLC,OAAO;EACPC,cAAc;EACdC,gBAAgB;EAChBC;AAC6B,CAAC,KAAK;EACnC,MAAM;IAAEC,MAAM;IAAEC,SAAS;IAAEC,MAAM;IAAEC;EAAO,CAAC,GAAGJ,MAAM;EACpD,MAAMK,cAAc,GAAGtB,OAAO,CAC7B,OAAO;IAAEkB,MAAM;IAAEC,SAAS;IAAEC,MAAM;IAAEC;EAAO,CAAC,CAAC,EAC7C,CAACH,MAAM,EAAEC,SAAS,EAAEC,MAAM,EAAEC,MAAM,CACnC,CAAC;EAED,MAAME,cAAc,GAAGvB,OAAO,CAAC,MAAMC,qBAAqB,CAACY,KAAK,CAAC,EAAE,CAACA,KAAK,CAAC,CAAC;EAE3E,MAAMW,eAAe,GAAGlB,WAAW,CAAC;IACnCG,OAAO;IACPD,QAAQ;IACRG,gBAAgB;IAChBY,cAAc;IACdE,mBAAmB,EAAEb,WAAW;IAChCE,OAAO;IACPC,cAAc;IACdC;EACD,CAAC,CAAC;;EAEF;EACA;EACA;EACAd,mBAAmB,CAAC;IACnBO,OAAO;IACPD,QAAQ;IACRG,gBAAgB;IAChBW,cAAc;IACdR,OAAO;IACPC;EACD,CAAC,CAAC;EAEFX,2BAA2B,CAAC;IAC3BK,OAAO;IACPe,eAAe;IACfhB;EACD,CAAC,CAAC;EAEFL,gCAAgC,CAAC;IAChCK,QAAQ;IACRC,OAAO,EAAEC,cAAc;IACvBc;EACD,CAAC,CAAC;EAEFnB,kBAAkB,CAAC;IAClBI,OAAO,EAAEC,cAAc;IACvBF,QAAQ;IACRgB;EACD,CAAC,CAAC;AACH,CAAC","ignoreList":[]}
|
|
@@ -15,7 +15,8 @@ export const useMeasurer = ({
|
|
|
15
15
|
preparedStyles,
|
|
16
16
|
measuredAnimatedRef,
|
|
17
17
|
handoff,
|
|
18
|
-
escapeClipping
|
|
18
|
+
escapeClipping,
|
|
19
|
+
localMeasurement
|
|
19
20
|
}) => {
|
|
20
21
|
const {
|
|
21
22
|
width: viewportWidth,
|
|
@@ -40,6 +41,12 @@ export const useMeasurer = ({
|
|
|
40
41
|
viewportWidth,
|
|
41
42
|
viewportHeight
|
|
42
43
|
});
|
|
44
|
+
if (escapeClipping && target.type === "source") {
|
|
45
|
+
localMeasurement.set({
|
|
46
|
+
bounds: measured,
|
|
47
|
+
pairKey: target.pairKey
|
|
48
|
+
});
|
|
49
|
+
}
|
|
43
50
|
|
|
44
51
|
/**
|
|
45
52
|
* - Destination Pass -
|
|
@@ -63,6 +70,6 @@ export const useMeasurer = ({
|
|
|
63
70
|
handoff,
|
|
64
71
|
escapeClipping
|
|
65
72
|
});
|
|
66
|
-
}, [enabled, boundTag, currentScreenKey, preparedStyles, measuredAnimatedRef, handoff, escapeClipping, viewportWidth, viewportHeight, scrollState, scrollMetadata, pendingLifecycleStartBlockCount, visibilityBlocked]);
|
|
73
|
+
}, [enabled, boundTag, currentScreenKey, preparedStyles, measuredAnimatedRef, handoff, escapeClipping, localMeasurement, viewportWidth, viewportHeight, scrollState, scrollMetadata, pendingLifecycleStartBlockCount, visibilityBlocked]);
|
|
67
74
|
};
|
|
68
75
|
//# sourceMappingURL=use-measurer.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["useCallback","useWindowDimensions","applyMeasuredBoundsWrites","useScreenSlots","ScrollStore","SystemStore","getVisibilityBlockOffset","attachScrollSnapshotToMeasuredBounds","correctMeasuredBoundsForVisibilityGate","isMeasurementInViewport","measureWithOverscrollAwareness","useMeasurer","enabled","boundTag","currentScreenKey","preparedStyles","measuredAnimatedRef","handoff","escapeClipping","width","viewportWidth","height","viewportHeight","scrollState","getValue","scrollMetadata","pendingLifecycleStartBlockCount","visibilityBlocked","target","measured","get","correctedMeasured","visibilityBlockOffset","shouldGuardDestinationViewport","group","viewportAllowsDestinationWrite","
|
|
1
|
+
{"version":3,"names":["useCallback","useWindowDimensions","applyMeasuredBoundsWrites","useScreenSlots","ScrollStore","SystemStore","getVisibilityBlockOffset","attachScrollSnapshotToMeasuredBounds","correctMeasuredBoundsForVisibilityGate","isMeasurementInViewport","measureWithOverscrollAwareness","useMeasurer","enabled","boundTag","currentScreenKey","preparedStyles","measuredAnimatedRef","handoff","escapeClipping","localMeasurement","width","viewportWidth","height","viewportHeight","scrollState","getValue","scrollMetadata","pendingLifecycleStartBlockCount","visibilityBlocked","target","measured","get","correctedMeasured","visibilityBlockOffset","type","set","bounds","pairKey","shouldGuardDestinationViewport","group","viewportAllowsDestinationWrite","measuredWithScroll","entryTag","tag","linkId","linkKey","linkWrite"],"sourceRoot":"../../../../../src","sources":["components/boundary/hooks/use-measurer.ts"],"mappings":";;AAAA,SAASA,WAAW,QAAQ,OAAO;AAEnC,SAASC,mBAAmB,QAAQ,cAAc;AAElD,SAASC,yBAAyB,QAAQ,mDAAmD;AAC7F,SAASC,cAAc,QAAQ,kCAAkC;AAEjE,SAASC,WAAW,QAAQ,8BAA8B;AAC1D,SAASC,WAAW,QAAQ,8BAA8B;AAC1D,SAASC,wBAAwB,QAAQ,wCAAwC;AAEjF,SACCC,oCAAoC,EACpCC,sCAAsC,EACtCC,uBAAuB,EACvBC,8BAA8B,QACxB,0BAA0B;AAajC,OAAO,MAAMC,WAAW,GAAGA,CAAC;EAC3BC,OAAO;EACPC,QAAQ;EACRC,gBAAgB;EAChBC,cAAc;EACdC,mBAAmB;EACnBC,OAAO;EACPC,cAAc;EACdC;AACkB,CAAC,KAAsB;EACzC,MAAM;IAAEC,KAAK,EAAEC,aAAa;IAAEC,MAAM,EAAEC;EAAe,CAAC,GACrDtB,mBAAmB,CAAC,CAAC;EAEtB,MAAMuB,WAAW,GAAGpB,WAAW,CAACqB,QAAQ,CAACX,gBAAgB,EAAE,cAAc,CAAC;EAC1E,MAAMY,cAAc,GAAGtB,WAAW,CAACqB,QAAQ,CAACX,gBAAgB,EAAE,UAAU,CAAC;EACzE,MAAMa,+BAA+B,GAAGtB,WAAW,CAACoB,QAAQ,CAC3DX,gBAAgB,EAChB,iCACD,CAAC;EACD,MAAM;IAAEc;EAAkB,CAAC,GAAGzB,cAAc,CAAC,CAAC;EAE9C,OAAOH,WAAW,CAChB6B,MAAM,IAAK;IACX,SAAS;;IACT,IAAI,CAACjB,OAAO,EAAE;IAEd,MAAMkB,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CN,OAAO,EACPC,QAAQ,EACRC,gBAAgB,EAChBC,cAAc,EACdC,mBAAmB,EACnBC,OAAO,EACPC,cAAc,EACdC,gBAAgB,EAChBE,aAAa,EACbE,cAAc,EACdC,WAAW,EACXE,cAAc,EACdC,+BAA+B,EAC/BC,iBAAiB,CAEnB,CAAC;AACF,CAAC","ignoreList":[]}
|
|
@@ -4,7 +4,6 @@ import { memo, useLayoutEffect, useRef } from "react";
|
|
|
4
4
|
import { StyleSheet, useWindowDimensions, View } from "react-native";
|
|
5
5
|
import Animated from "react-native-reanimated";
|
|
6
6
|
import { useDescriptorsStore } from "../../../../../../providers/screen/descriptors";
|
|
7
|
-
import { useScreenSlots } from "../../../../../../providers/screen/styles";
|
|
8
7
|
import { PORTAL_POINTER_EVENTS } from "../../../teleport";
|
|
9
8
|
import { useHostMeasurement } from "../hooks/use-host-measurement";
|
|
10
9
|
import { registerHost, unregisterHost } from "../stores/host-registry.store";
|
|
@@ -22,23 +21,14 @@ function HostImpl({
|
|
|
22
21
|
generatedHostKeyRef.current = `${screenKey}-host-${nextHostId++}`;
|
|
23
22
|
}
|
|
24
23
|
const hostKey = fallback ? screenKey : generatedHostKeyRef.current;
|
|
25
|
-
const capturesScroll = !fallback;
|
|
26
24
|
const activeBoundaryHosts = useActivePortalBoundaryHosts(hostKey);
|
|
27
|
-
const {
|
|
28
|
-
visibilityBlocked
|
|
29
|
-
} = useScreenSlots();
|
|
30
25
|
const {
|
|
31
26
|
height: viewportHeight,
|
|
32
27
|
width: viewportWidth
|
|
33
28
|
} = useWindowDimensions();
|
|
29
|
+
const measurementKey = activeBoundaryHosts.length ? activeBoundaryHosts.map(host => host.portalHostName).join("|") : null;
|
|
34
30
|
const measurement = useHostMeasurement({
|
|
35
|
-
|
|
36
|
-
enabled: activeBoundaryHosts.length > 0,
|
|
37
|
-
hostKey,
|
|
38
|
-
screenKey,
|
|
39
|
-
visibilityBlocked,
|
|
40
|
-
viewportHeight,
|
|
41
|
-
viewportWidth
|
|
31
|
+
measurementKey
|
|
42
32
|
});
|
|
43
33
|
useLayoutEffect(() => {
|
|
44
34
|
registerHost({
|
|
@@ -58,6 +48,9 @@ function HostImpl({
|
|
|
58
48
|
}],
|
|
59
49
|
children: /*#__PURE__*/_jsx(PortalBoundaryHost, {
|
|
60
50
|
host: host,
|
|
51
|
+
hostBounds: measurement.hostBounds,
|
|
52
|
+
hostMeasurementKey: measurementKey,
|
|
53
|
+
measuredHostKey: measurement.measuredKey,
|
|
61
54
|
style: StyleSheet.absoluteFill
|
|
62
55
|
})
|
|
63
56
|
}, host.portalHostName));
|
package/lib/module/components/boundary/portal/components/boundary-portal/components/host.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["memo","useLayoutEffect","useRef","StyleSheet","useWindowDimensions","View","Animated","useDescriptorsStore","
|
|
1
|
+
{"version":3,"names":["memo","useLayoutEffect","useRef","StyleSheet","useWindowDimensions","View","Animated","useDescriptorsStore","PORTAL_POINTER_EVENTS","useHostMeasurement","registerHost","unregisterHost","useActivePortalBoundaryHosts","PortalBoundaryHost","jsx","_jsx","nextHostId","HostImpl","fallback","style","screenKey","s","derivations","currentScreenKey","generatedHostKeyRef","current","hostKey","activeBoundaryHosts","height","viewportHeight","width","viewportWidth","measurementKey","length","map","host","portalHostName","join","measurement","boundaryHosts","pointerEvents","styles","boundaryHostViewport","children","hostBounds","hostMeasurementKey","measuredHostKey","measuredKey","absoluteFill","ref","hostRef","collapsable","Host","props","ScreenFallbackHost","create","elevation","left","overflow","position","top","zIndex"],"sourceRoot":"../../../../../../../../src","sources":["components/boundary/portal/components/boundary-portal/components/host.tsx"],"mappings":";;AAAA,SAASA,IAAI,EAAEC,eAAe,EAAEC,MAAM,QAAQ,OAAO;AACrD,SAECC,UAAU,EACVC,mBAAmB,EACnBC,IAAI,QAEE,cAAc;AACrB,OAAOC,QAAQ,MAAM,yBAAyB;AAC9C,SAASC,mBAAmB,QAAQ,gDAAgD;AACpF,SAASC,qBAA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,MAAMuB,MAAM,GAAGtC,UAAU,CAACoD,MAAM,CAAC;EAChCpB,IAAI,EAAE;IACLqB,SAAS,EAAE,MAAM;IACjBC,IAAI,EAAE,CAAC;IACPC,QAAQ,EAAE,SAAS;IACnBC,QAAQ,EAAE,UAAU;IACpBC,GAAG,EAAE,CAAC;IACNC,MAAM,EAAE;EACT,CAAC;EACDnB,oBAAoB,EAAE;IACrBe,IAAI,EAAE,CAAC;IACPC,QAAQ,EAAE,SAAS;IACnBC,QAAQ,EAAE,UAAU;IACpBC,GAAG,EAAE;EACN;AACD,CAAC,CAAC","ignoreList":[]}
|
|
@@ -1,78 +1,60 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
import { memo
|
|
3
|
+
import { memo } from "react";
|
|
4
4
|
import { I18nManager, StyleSheet } from "react-native";
|
|
5
|
-
import Animated, {
|
|
5
|
+
import Animated, { useAnimatedReaction, useAnimatedStyle } from "react-native-reanimated";
|
|
6
6
|
import { NO_STYLES } from "../../../../../../constants";
|
|
7
7
|
import { composeSlotStyleWithLocalTransform } from "../../../../../../providers/screen/styles/helpers/compose-slot-style";
|
|
8
|
-
import { getLink } from "../../../../../../stores/bounds/internals/links";
|
|
9
|
-
import { SystemStore } from "../../../../../../stores/system.store";
|
|
10
8
|
import { NativePortalHost, PORTAL_POINTER_EVENTS } from "../../../teleport";
|
|
9
|
+
import { resolveBoundaryLocalMeasurement } from "../helpers/local-measurement";
|
|
11
10
|
import { resolvePortalOffsetStyle } from "../helpers/offset-style";
|
|
12
|
-
import { getPortalHostBounds } from "../stores/host-bounds.store";
|
|
13
11
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
14
12
|
const AnimatedPortalBoundaryHost = NativePortalHost ? Animated.createAnimatedComponent(NativePortalHost) : null;
|
|
13
|
+
const getCurrentBoundaryBounds = host => {
|
|
14
|
+
"worklet";
|
|
15
|
+
|
|
16
|
+
return resolveBoundaryLocalMeasurement(host.localMeasurement.get(), host.pairKey);
|
|
17
|
+
};
|
|
15
18
|
export const PortalBoundaryHost = /*#__PURE__*/memo(function PortalBoundaryHost({
|
|
16
19
|
host,
|
|
20
|
+
hostBounds,
|
|
21
|
+
hostMeasurementKey,
|
|
22
|
+
measuredHostKey,
|
|
17
23
|
style
|
|
18
24
|
}) {
|
|
19
|
-
|
|
20
|
-
const {
|
|
21
|
-
unblockLifecycleStart
|
|
22
|
-
} = SystemStore.getBag(host.screenKey).actions;
|
|
23
|
-
const handleFrame = useCallback(() => {
|
|
25
|
+
useAnimatedReaction(() => {
|
|
24
26
|
"worklet";
|
|
25
27
|
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
const hasSlot = host.slotsMap.get()[host.boundaryId] !== undefined;
|
|
33
|
-
const hasGeometry = hasSource && hasHostBounds && hasSlot;
|
|
34
|
-
if (!hasGeometry) {
|
|
35
|
-
geometryReadyFrames.set(0);
|
|
36
|
-
return;
|
|
37
|
-
}
|
|
38
|
-
if (geometryReadyFrames.get() === 0) {
|
|
39
|
-
// Give the source frame, host offset, and slot style one UI frame to
|
|
40
|
-
// reach native before Teleport targets this receiver.
|
|
41
|
-
geometryReadyFrames.set(1);
|
|
42
|
-
return;
|
|
28
|
+
return getCurrentBoundaryBounds(host) !== null && hostBounds.get() !== null && !!hostMeasurementKey && measuredHostKey.get() === hostMeasurementKey;
|
|
29
|
+
}, ready => {
|
|
30
|
+
"worklet";
|
|
31
|
+
|
|
32
|
+
if (ready) {
|
|
33
|
+
host.portalHostReady.set(true);
|
|
43
34
|
}
|
|
44
|
-
|
|
45
|
-
unblockLifecycleStart();
|
|
46
|
-
}, [geometryReadyFrames, host, unblockLifecycleStart]);
|
|
47
|
-
useFrameCallback(handleFrame, true);
|
|
35
|
+
});
|
|
48
36
|
const hostStyle = useAnimatedStyle(() => {
|
|
49
37
|
"worklet";
|
|
50
38
|
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
const link = getLink(host.pairKey, host.boundaryId);
|
|
54
|
-
if (!link?.source) {
|
|
39
|
+
const boundaryBounds = getCurrentBoundaryBounds(host);
|
|
40
|
+
if (!boundaryBounds) {
|
|
55
41
|
return NO_STYLES;
|
|
56
42
|
}
|
|
57
|
-
const sourceBounds = link.source.bounds;
|
|
58
|
-
const isCrossScreenPortal = link.source.screenKey !== host.screenKey;
|
|
59
43
|
return resolvePortalOffsetStyle({
|
|
60
|
-
bounds:
|
|
61
|
-
|
|
62
|
-
placement: isCrossScreenPortal ? "cross-screen" : "same-screen"
|
|
44
|
+
bounds: boundaryBounds,
|
|
45
|
+
hostBounds: hostBounds.get()
|
|
63
46
|
});
|
|
64
47
|
});
|
|
65
48
|
const contentFrameStyle = useAnimatedStyle(() => {
|
|
66
49
|
"worklet";
|
|
67
50
|
|
|
68
|
-
const
|
|
69
|
-
if (!
|
|
51
|
+
const boundaryBounds = getCurrentBoundaryBounds(host);
|
|
52
|
+
if (!boundaryBounds) {
|
|
70
53
|
return NO_STYLES;
|
|
71
54
|
}
|
|
72
|
-
const sourceBounds = link.source.bounds;
|
|
73
55
|
return {
|
|
74
|
-
height:
|
|
75
|
-
width:
|
|
56
|
+
height: boundaryBounds.height,
|
|
57
|
+
width: boundaryBounds.width
|
|
76
58
|
};
|
|
77
59
|
});
|
|
78
60
|
const slotStyle = useAnimatedStyle(() => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["memo","
|
|
1
|
+
{"version":3,"names":["memo","I18nManager","StyleSheet","Animated","useAnimatedReaction","useAnimatedStyle","NO_STYLES","composeSlotStyleWithLocalTransform","NativePortalHost","PORTAL_POINTER_EVENTS","resolveBoundaryLocalMeasurement","resolvePortalOffsetStyle","jsx","_jsx","AnimatedPortalBoundaryHost","createAnimatedComponent","getCurrentBoundaryBounds","host","localMeasurement","get","pairKey","PortalBoundaryHost","hostBounds","hostMeasurementKey","measuredHostKey","style","ready","portalHostReady","set","hostStyle","boundaryBounds","bounds","contentFrameStyle","height","width","slotStyle","slot","slotsMap","boundaryId","undefined","boundsLocalTransform","View","pointerEvents","collapsable","children","name","portalHostName","styles","content","create","isRTL","end","position","top","left"],"sourceRoot":"../../../../../../../../src","sources":["components/boundary/portal/components/boundary-portal/components/portal-boundary-host.tsx"],"mappings":";;AAAA,SAASA,IAAI,QAAQ,OAAO;AAC5B,SACCC,WAAW,EAEXC,UAAU,QAEJ,cAAc;AACrB,OAAOC,QAAQ,IAGdC,mBAAmB,EACnBC,gBAAgB,QACV,yBAAyB;AAChC,SAASC,SAAS,QAAQ,6BAA6B;AACvD,SAASC,kCAAkC,QAAQ,sEAAsE;AACzH,SAASC,gBAAgB,EAAEC,qBAAqB,QAAQ,mBAAmB;AAC3E,SAASC,+BAA+B,QAAQ,8BAA8B;AAC9E,SAASC,wBAAwB,QAAQ,yBAAyB;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAGnE,MAAMC,0BAA0B,GAAGN,gBAAgB,GAChDL,QAAQ,CAACY,uBAAuB,CAACP,gBAAgB,CAAC,GAClD,IAAI;AAEP,MAAMQ,wBAAwB,GAAIC,IAA8B,IAAK;EACpE,SAAS;;EACT,OAAOP,+BAA+B,CACrCO,IAAI,CAACC,gBAAgB,CAACC,GAAG,CAAC,CAAC,EAC3BF,IAAI,CAACG,OACN,CAAC;AACF,CAAC;AAUD,OAAO,MAAMC,kBAAkB,gBAAGrB,IAAI,CAAC,SAASqB,kBAAkBA,CAAC;EAClEJ,IAAI;EACJK,UAAU;EACVC,kBAAkB;EAClBC,eAAe;EACfC;AACwB,CAAC,EAAE;EAC3BrB,mBAAmB,CAClB,MAAM;IACL,SAAS;;IACT,OACCY,wBAAwB,CAACC,IAAI,CAAC,KAAK,IAAI,IACvCK,UAAU,CAACH,GAAG,CAAC,CAAC,KAAK,IAAI,IACzB,CAAC,CAACI,kBAAkB,IACpBC,eAAe,CAACL,GAAG,CAAC,CAAC,KAAKI,kBAAkB;EAE9C,CAAC,EACAG,KAAK,IAAK;IACV,SAAS;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B,IAAA,CAACC,0BAA0B;MAC1B+B,IAAI,EAAE5B,IAAI,CAAC6B,cAAe;MAC1BJ,aAAa,EAAEjC,qBAAsB;MACrCgB,KAAK,EAAE,CAACsB,MAAM,CAACC,OAAO,EAAEhB,iBAAiB,EAAEG,SAAS;IAAE,CACtD;EAAC,CACY,CAAC;AAElB,CAAC,CAAC;;AAEF;AACA;AACA;AACA;AACA,MAAMY,MAAM,GAAG7C,UAAU,CAAC+C,MAAM,CAAC;EAChCD,OAAO,EAAE/C,WAAW,CAACiD,KAAK,GACvB;IACAC,GAAG,EAAE,CAAC;IACNC,QAAQ,EAAE,UAAU;IACpBC,GAAG,EAAE;EACN,CAAC,GACA;IACAC,IAAI,EAAE,CAAC;IACPF,QAAQ,EAAE,UAAU;IACpBC,GAAG,EAAE;EACN;AACH,CAAC,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["resolveBoundaryLocalMeasurement","measurement","pairKey","bounds"],"sourceRoot":"../../../../../../../../src","sources":["components/boundary/portal/components/boundary-portal/helpers/local-measurement.ts"],"mappings":";;AAGA,OAAO,MAAMA,+BAA+B,GAAGA,CAC9CC,WAA4C,EAC5CC,OAAsB,KAClB;EACJ,SAAS;;EACT,OAAOD,WAAW,EAAEC,OAAO,KAAKA,OAAO,GAAGD,WAAW,CAACE,MAAM,GAAG,IAAI;AACpE,CAAC","ignoreList":[]}
|
package/lib/module/components/boundary/portal/components/boundary-portal/helpers/offset-style.js
CHANGED
|
@@ -1,45 +1,21 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
import { getClampedScrollAxisDelta } from "../../../../../../stores/scroll.store";
|
|
4
|
-
import { getPortalHostBounds } from "../stores/host-bounds.store";
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* The two portal coordinate cases we support:
|
|
8
|
-
*
|
|
9
|
-
* - same-screen: source and host live on the same screen; re-base the stored
|
|
10
|
-
* host frame onto the source measurement's scroll snapshot.
|
|
11
|
-
* - cross-screen: source and host live on different screens; the host is the
|
|
12
|
-
* replacement coordinate space, so destination scroll is inherited naturally
|
|
13
|
-
* from host placement instead of manually propagated.
|
|
14
|
-
*/
|
|
15
|
-
|
|
16
3
|
export const resolvePortalOffsetStyle = ({
|
|
17
4
|
bounds,
|
|
18
|
-
|
|
19
|
-
placement
|
|
5
|
+
hostBounds
|
|
20
6
|
}) => {
|
|
21
7
|
"worklet";
|
|
22
8
|
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
// Cross-screen hosts are the chosen replacement coordinate space, so their
|
|
29
|
-
// destination scroll is represented by where the host itself is mounted.
|
|
30
|
-
const alignHostToBoundsScroll = placement === "same-screen";
|
|
31
|
-
const hostSnapshotDeltaX = alignHostToBoundsScroll ? getClampedScrollAxisDelta(boundsScrollSnapshot, hostBoundsScrollSnapshot, "horizontal") : 0;
|
|
32
|
-
const hostSnapshotDeltaY = alignHostToBoundsScroll ? getClampedScrollAxisDelta(boundsScrollSnapshot, hostBoundsScrollSnapshot, "vertical") : 0;
|
|
33
|
-
|
|
34
|
-
// Without registered host bounds the host frame is the origin, so the source
|
|
35
|
-
// page position becomes the offset directly.
|
|
36
|
-
const adjustedHostPageX = hostBounds ? hostBounds.pageX - hostSnapshotDeltaX : 0;
|
|
37
|
-
const adjustedHostPageY = hostBounds ? hostBounds.pageY - hostSnapshotDeltaY : 0;
|
|
9
|
+
// Both values are measured in page coordinates. Subtracting the host origin
|
|
10
|
+
// gives the boundary's local position inside that host, independent of which
|
|
11
|
+
// scroll container owns either view.
|
|
12
|
+
const hostPageX = hostBounds?.pageX ?? 0;
|
|
13
|
+
const hostPageY = hostBounds?.pageY ?? 0;
|
|
38
14
|
return {
|
|
39
15
|
transform: [{
|
|
40
|
-
translateY: bounds.pageY -
|
|
16
|
+
translateY: bounds.pageY - hostPageY
|
|
41
17
|
}, {
|
|
42
|
-
translateX: bounds.pageX -
|
|
18
|
+
translateX: bounds.pageX - hostPageX
|
|
43
19
|
}]
|
|
44
20
|
};
|
|
45
21
|
};
|
package/lib/module/components/boundary/portal/components/boundary-portal/helpers/offset-style.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["
|
|
1
|
+
{"version":3,"names":["resolvePortalOffsetStyle","bounds","hostBounds","hostPageX","pageX","hostPageY","pageY","transform","translateY","translateX"],"sourceRoot":"../../../../../../../../src","sources":["components/boundary/portal/components/boundary-portal/helpers/offset-style.ts"],"mappings":";;AAOA,OAAO,MAAMA,wBAAwB,GAAGA,CAAC;EACxCC,MAAM;EACNC;AAC+B,CAAC,KAAiB;EACjD,SAAS;;EACT;EACA;EACA;EACA,MAAMC,SAAS,GAAGD,UAAU,EAAEE,KAAK,IAAI,CAAC;EACxC,MAAMC,SAAS,GAAGH,UAAU,EAAEI,KAAK,IAAI,CAAC;EAExC,OAAO;IACNC,SAAS,EAAE,CACV;MAAEC,UAAU,EAAEP,MAAM,CAACK,KAAK,GAAGD;IAAU,CAAC,EACxC;MAAEI,UAAU,EAAER,MAAM,CAACG,KAAK,GAAGD;IAAU,CAAC;EAE1C,CAAC;AACF,CAAC","ignoreList":[]}
|