react-native-screen-transitions 3.11.2 → 3.12.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.
Files changed (457) hide show
  1. package/lib/commonjs/blank-stack/components/stack-view.js +1 -2
  2. package/lib/commonjs/blank-stack/components/stack-view.js.map +1 -1
  3. package/lib/commonjs/component-stack/components/stack-view.js +1 -2
  4. package/lib/commonjs/component-stack/components/stack-view.js.map +1 -1
  5. package/lib/commonjs/native-stack/views/NativeStackView.native.js +3 -4
  6. package/lib/commonjs/native-stack/views/NativeStackView.native.js.map +1 -1
  7. package/lib/commonjs/shared/adapters/with-screen-transitions/stack-layout.js +1 -1
  8. package/lib/commonjs/shared/adapters/with-screen-transitions/stack-layout.js.map +1 -1
  9. package/lib/commonjs/shared/components/boundary/components/boundary-lifecycle.js +36 -0
  10. package/lib/commonjs/shared/components/boundary/components/boundary-lifecycle.js.map +1 -0
  11. package/lib/commonjs/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.js +1 -13
  12. package/lib/commonjs/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.js.map +1 -1
  13. package/lib/commonjs/shared/components/boundary/hooks/lifecycles/use-refresh-boundary.js +9 -2
  14. package/lib/commonjs/shared/components/boundary/hooks/lifecycles/use-refresh-boundary.js.map +1 -1
  15. package/lib/commonjs/shared/components/boundary/hooks/use-boundary-measurement.js +3 -2
  16. package/lib/commonjs/shared/components/boundary/hooks/use-boundary-measurement.js.map +1 -1
  17. package/lib/commonjs/shared/components/boundary/hooks/use-measurer.js +9 -2
  18. package/lib/commonjs/shared/components/boundary/hooks/use-measurer.js.map +1 -1
  19. package/lib/commonjs/shared/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.js +7 -4
  20. package/lib/commonjs/shared/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.js.map +1 -1
  21. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/components/host.js +5 -12
  22. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/components/host.js.map +1 -1
  23. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/components/portal-boundary-host.js +25 -43
  24. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/components/portal-boundary-host.js.map +1 -1
  25. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/helpers/local-measurement.js +13 -0
  26. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/helpers/local-measurement.js.map +1 -0
  27. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/helpers/offset-style.js +8 -31
  28. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/helpers/offset-style.js.map +1 -1
  29. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/hooks/use-active-portal-boundary-host.js +14 -19
  30. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/hooks/use-active-portal-boundary-host.js.map +1 -1
  31. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.js +8 -0
  32. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.js.map +1 -1
  33. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/hooks/use-host-measurement.js +19 -47
  34. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/hooks/use-host-measurement.js.map +1 -1
  35. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/index.js.map +1 -1
  36. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/stores/portal-boundary-host.store.js +1 -1
  37. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/stores/portal-boundary-host.store.js.map +1 -1
  38. package/lib/commonjs/shared/components/boundary/providers/boundary-root.provider.js +19 -17
  39. package/lib/commonjs/shared/components/boundary/providers/boundary-root.provider.js.map +1 -1
  40. package/lib/commonjs/shared/components/boundary/utils/refresh-signals.js +19 -5
  41. package/lib/commonjs/shared/components/boundary/utils/refresh-signals.js.map +1 -1
  42. package/lib/commonjs/shared/components/overlay/helpers/create-overlay-interpolator-frame.js +30 -0
  43. package/lib/commonjs/shared/components/overlay/helpers/create-overlay-interpolator-frame.js.map +1 -0
  44. package/lib/commonjs/shared/components/overlay/helpers/get-active-overlay.js +40 -22
  45. package/lib/commonjs/shared/components/overlay/helpers/get-active-overlay.js.map +1 -1
  46. package/lib/commonjs/shared/components/overlay/helpers/retain-ready-overlay-resources.js +21 -0
  47. package/lib/commonjs/shared/components/overlay/helpers/retain-ready-overlay-resources.js.map +1 -0
  48. package/lib/commonjs/shared/components/overlay/helpers/run-overlay-slot-interpolator.js +41 -0
  49. package/lib/commonjs/shared/components/overlay/helpers/run-overlay-slot-interpolator.js.map +1 -0
  50. package/lib/commonjs/shared/components/overlay/hooks/use-overlay-slot.js +85 -0
  51. package/lib/commonjs/shared/components/overlay/hooks/use-overlay-slot.js.map +1 -0
  52. package/lib/commonjs/shared/components/overlay/variations/float-overlay.js +14 -65
  53. package/lib/commonjs/shared/components/overlay/variations/float-overlay.js.map +1 -1
  54. package/lib/commonjs/shared/components/overlay/variations/overlay-host.js +89 -16
  55. package/lib/commonjs/shared/components/overlay/variations/overlay-host.js.map +1 -1
  56. package/lib/commonjs/shared/components/screen-container/layers/backdrop.js +11 -7
  57. package/lib/commonjs/shared/components/screen-container/layers/backdrop.js.map +1 -1
  58. package/lib/commonjs/shared/components/screen-lifecycle/hooks/helpers/close-interception-rules.js +31 -0
  59. package/lib/commonjs/shared/components/screen-lifecycle/hooks/helpers/close-interception-rules.js.map +1 -0
  60. package/lib/commonjs/shared/components/screen-lifecycle/hooks/use-close-completion.js +26 -0
  61. package/lib/commonjs/shared/components/screen-lifecycle/hooks/use-close-completion.js.map +1 -0
  62. package/lib/commonjs/shared/components/screen-lifecycle/hooks/use-close-transition-intent.js +64 -87
  63. package/lib/commonjs/shared/components/screen-lifecycle/hooks/use-close-transition-intent.js.map +1 -1
  64. package/lib/commonjs/shared/components/screen-lifecycle/hooks/use-transition-start-controller.js +1 -5
  65. package/lib/commonjs/shared/components/screen-lifecycle/hooks/use-transition-start-controller.js.map +1 -1
  66. package/lib/commonjs/shared/components/screen-lifecycle/index.js +9 -6
  67. package/lib/commonjs/shared/components/screen-lifecycle/index.js.map +1 -1
  68. package/lib/commonjs/shared/hooks/navigation/use-navigation-helpers.js +28 -6
  69. package/lib/commonjs/shared/hooks/navigation/use-navigation-helpers.js.map +1 -1
  70. package/lib/commonjs/shared/providers/helpers/measured-bounds-writes.js +1 -2
  71. package/lib/commonjs/shared/providers/helpers/measured-bounds-writes.js.map +1 -1
  72. package/lib/commonjs/shared/providers/screen/animation/animation.provider.js +10 -7
  73. package/lib/commonjs/shared/providers/screen/animation/animation.provider.js.map +1 -1
  74. package/lib/commonjs/shared/providers/screen/animation/helpers/accessors/use-build-transition-accessor.js +6 -8
  75. package/lib/commonjs/shared/providers/screen/animation/helpers/accessors/use-build-transition-accessor.js.map +1 -1
  76. package/lib/commonjs/shared/providers/screen/animation/use-screen-animation.js +8 -2
  77. package/lib/commonjs/shared/providers/screen/animation/use-screen-animation.js.map +1 -1
  78. package/lib/commonjs/shared/providers/screen/gestures/gestures.provider.js +9 -5
  79. package/lib/commonjs/shared/providers/screen/gestures/gestures.provider.js.map +1 -1
  80. package/lib/commonjs/shared/providers/screen/gestures/hooks/use-screen-gesture-config.js +10 -5
  81. package/lib/commonjs/shared/providers/screen/gestures/hooks/use-screen-gesture-config.js.map +1 -1
  82. package/lib/commonjs/shared/providers/screen/gestures/ownership/{use-walk-up-and-register-shadowing-claims.js → gesture-ownership-bridge.js} +36 -50
  83. package/lib/commonjs/shared/providers/screen/gestures/ownership/gesture-ownership-bridge.js.map +1 -0
  84. package/lib/commonjs/shared/providers/screen/gestures/pan/behavior/pan-lifecycle.js +4 -5
  85. package/lib/commonjs/shared/providers/screen/gestures/pan/behavior/pan-lifecycle.js.map +1 -1
  86. package/lib/commonjs/shared/providers/screen/gestures/pan/behavior/use-pan-behavior.js +2 -3
  87. package/lib/commonjs/shared/providers/screen/gestures/pan/behavior/use-pan-behavior.js.map +1 -1
  88. package/lib/commonjs/shared/providers/screen/gestures/pinch/behavior/pinch-lifecycle.js +4 -5
  89. package/lib/commonjs/shared/providers/screen/gestures/pinch/behavior/pinch-lifecycle.js.map +1 -1
  90. package/lib/commonjs/shared/providers/screen/gestures/pinch/behavior/use-pinch-behavior.js +2 -3
  91. package/lib/commonjs/shared/providers/screen/gestures/pinch/behavior/use-pinch-behavior.js.map +1 -1
  92. package/lib/commonjs/shared/providers/screen/gestures/shared/policy.js +9 -5
  93. package/lib/commonjs/shared/providers/screen/gestures/shared/policy.js.map +1 -1
  94. package/lib/commonjs/shared/providers/screen/styles/constants.js +1 -0
  95. package/lib/commonjs/shared/providers/screen/styles/constants.js.map +1 -1
  96. package/lib/commonjs/shared/providers/screen/styles/helpers/transition-visual-state.js +20 -1
  97. package/lib/commonjs/shared/providers/screen/styles/helpers/transition-visual-state.js.map +1 -1
  98. package/lib/commonjs/shared/providers/screen/styles/hooks/slot-resolvers.js +14 -15
  99. package/lib/commonjs/shared/providers/screen/styles/hooks/slot-resolvers.js.map +1 -1
  100. package/lib/commonjs/shared/providers/screen/styles/hooks/use-interpolated-style-maps.js +34 -11
  101. package/lib/commonjs/shared/providers/screen/styles/hooks/use-interpolated-style-maps.js.map +1 -1
  102. package/lib/commonjs/shared/providers/screen/styles/slot.provider.js +18 -29
  103. package/lib/commonjs/shared/providers/screen/styles/slot.provider.js.map +1 -1
  104. package/lib/commonjs/shared/providers/stack/blank-stack-state/blank-stack-controller.js +5 -1
  105. package/lib/commonjs/shared/providers/stack/blank-stack-state/blank-stack-controller.js.map +1 -1
  106. package/lib/commonjs/shared/providers/stack/blank-stack-state/helpers/resolve-presented-index.js +18 -0
  107. package/lib/commonjs/shared/providers/stack/blank-stack-state/helpers/resolve-presented-index.js.map +1 -0
  108. package/lib/commonjs/shared/providers/stack/blank-stack.provider.js +2 -1
  109. package/lib/commonjs/shared/providers/stack/blank-stack.provider.js.map +1 -1
  110. package/lib/commonjs/shared/stores/bounds/internals/links.js +1 -1
  111. package/lib/commonjs/shared/stores/bounds/internals/links.js.map +1 -1
  112. package/lib/commonjs/shared/stores/system.store.js +1 -2
  113. package/lib/commonjs/shared/stores/system.store.js.map +1 -1
  114. package/lib/commonjs/shared/utils/animation/animate-to-progress.js +0 -22
  115. package/lib/commonjs/shared/utils/animation/animate-to-progress.js.map +1 -1
  116. package/lib/commonjs/shared/utils/create-provider.js +119 -10
  117. package/lib/commonjs/shared/utils/create-provider.js.map +1 -1
  118. package/lib/commonjs/shared/utils/navigation/close-action-replay.js +22 -0
  119. package/lib/commonjs/shared/utils/navigation/close-action-replay.js.map +1 -0
  120. package/lib/module/blank-stack/components/stack-view.js +1 -2
  121. package/lib/module/blank-stack/components/stack-view.js.map +1 -1
  122. package/lib/module/component-stack/components/stack-view.js +1 -2
  123. package/lib/module/component-stack/components/stack-view.js.map +1 -1
  124. package/lib/module/native-stack/views/NativeStackView.native.js +3 -4
  125. package/lib/module/native-stack/views/NativeStackView.native.js.map +1 -1
  126. package/lib/module/shared/adapters/with-screen-transitions/stack-layout.js +1 -1
  127. package/lib/module/shared/adapters/with-screen-transitions/stack-layout.js.map +1 -1
  128. package/lib/module/shared/components/boundary/components/boundary-lifecycle.js +32 -0
  129. package/lib/module/shared/components/boundary/components/boundary-lifecycle.js.map +1 -0
  130. package/lib/module/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.js +1 -13
  131. package/lib/module/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.js.map +1 -1
  132. package/lib/module/shared/components/boundary/hooks/lifecycles/use-refresh-boundary.js +9 -2
  133. package/lib/module/shared/components/boundary/hooks/lifecycles/use-refresh-boundary.js.map +1 -1
  134. package/lib/module/shared/components/boundary/hooks/use-boundary-measurement.js +3 -2
  135. package/lib/module/shared/components/boundary/hooks/use-boundary-measurement.js.map +1 -1
  136. package/lib/module/shared/components/boundary/hooks/use-measurer.js +9 -2
  137. package/lib/module/shared/components/boundary/hooks/use-measurer.js.map +1 -1
  138. package/lib/module/shared/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.js +7 -4
  139. package/lib/module/shared/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.js.map +1 -1
  140. package/lib/module/shared/components/boundary/portal/components/boundary-portal/components/host.js +5 -12
  141. package/lib/module/shared/components/boundary/portal/components/boundary-portal/components/host.js.map +1 -1
  142. package/lib/module/shared/components/boundary/portal/components/boundary-portal/components/portal-boundary-host.js +27 -45
  143. package/lib/module/shared/components/boundary/portal/components/boundary-portal/components/portal-boundary-host.js.map +1 -1
  144. package/lib/module/shared/components/boundary/portal/components/boundary-portal/helpers/local-measurement.js +8 -0
  145. package/lib/module/shared/components/boundary/portal/components/boundary-portal/helpers/local-measurement.js.map +1 -0
  146. package/lib/module/shared/components/boundary/portal/components/boundary-portal/helpers/offset-style.js +8 -32
  147. package/lib/module/shared/components/boundary/portal/components/boundary-portal/helpers/offset-style.js.map +1 -1
  148. package/lib/module/shared/components/boundary/portal/components/boundary-portal/hooks/use-active-portal-boundary-host.js +15 -20
  149. package/lib/module/shared/components/boundary/portal/components/boundary-portal/hooks/use-active-portal-boundary-host.js.map +1 -1
  150. package/lib/module/shared/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.js +8 -0
  151. package/lib/module/shared/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.js.map +1 -1
  152. package/lib/module/shared/components/boundary/portal/components/boundary-portal/hooks/use-host-measurement.js +20 -48
  153. package/lib/module/shared/components/boundary/portal/components/boundary-portal/hooks/use-host-measurement.js.map +1 -1
  154. package/lib/module/shared/components/boundary/portal/components/boundary-portal/index.js.map +1 -1
  155. package/lib/module/shared/components/boundary/portal/components/boundary-portal/stores/portal-boundary-host.store.js +1 -1
  156. package/lib/module/shared/components/boundary/portal/components/boundary-portal/stores/portal-boundary-host.store.js.map +1 -1
  157. package/lib/module/shared/components/boundary/providers/boundary-root.provider.js +20 -18
  158. package/lib/module/shared/components/boundary/providers/boundary-root.provider.js.map +1 -1
  159. package/lib/module/shared/components/boundary/utils/refresh-signals.js +19 -5
  160. package/lib/module/shared/components/boundary/utils/refresh-signals.js.map +1 -1
  161. package/lib/module/shared/components/overlay/helpers/create-overlay-interpolator-frame.js +25 -0
  162. package/lib/module/shared/components/overlay/helpers/create-overlay-interpolator-frame.js.map +1 -0
  163. package/lib/module/shared/components/overlay/helpers/get-active-overlay.js +37 -21
  164. package/lib/module/shared/components/overlay/helpers/get-active-overlay.js.map +1 -1
  165. package/lib/module/shared/components/overlay/helpers/retain-ready-overlay-resources.js +17 -0
  166. package/lib/module/shared/components/overlay/helpers/retain-ready-overlay-resources.js.map +1 -0
  167. package/lib/module/shared/components/overlay/helpers/run-overlay-slot-interpolator.js +36 -0
  168. package/lib/module/shared/components/overlay/helpers/run-overlay-slot-interpolator.js.map +1 -0
  169. package/lib/module/shared/components/overlay/hooks/use-overlay-slot.js +80 -0
  170. package/lib/module/shared/components/overlay/hooks/use-overlay-slot.js.map +1 -0
  171. package/lib/module/shared/components/overlay/variations/float-overlay.js +15 -66
  172. package/lib/module/shared/components/overlay/variations/float-overlay.js.map +1 -1
  173. package/lib/module/shared/components/overlay/variations/overlay-host.js +90 -18
  174. package/lib/module/shared/components/overlay/variations/overlay-host.js.map +1 -1
  175. package/lib/module/shared/components/screen-container/layers/backdrop.js +12 -8
  176. package/lib/module/shared/components/screen-container/layers/backdrop.js.map +1 -1
  177. package/lib/module/shared/components/screen-lifecycle/hooks/helpers/close-interception-rules.js +25 -0
  178. package/lib/module/shared/components/screen-lifecycle/hooks/helpers/close-interception-rules.js.map +1 -0
  179. package/lib/module/shared/components/screen-lifecycle/hooks/use-close-completion.js +21 -0
  180. package/lib/module/shared/components/screen-lifecycle/hooks/use-close-completion.js.map +1 -0
  181. package/lib/module/shared/components/screen-lifecycle/hooks/use-close-transition-intent.js +64 -86
  182. package/lib/module/shared/components/screen-lifecycle/hooks/use-close-transition-intent.js.map +1 -1
  183. package/lib/module/shared/components/screen-lifecycle/hooks/use-transition-start-controller.js +1 -5
  184. package/lib/module/shared/components/screen-lifecycle/hooks/use-transition-start-controller.js.map +1 -1
  185. package/lib/module/shared/components/screen-lifecycle/index.js +9 -6
  186. package/lib/module/shared/components/screen-lifecycle/index.js.map +1 -1
  187. package/lib/module/shared/hooks/navigation/use-navigation-helpers.js +29 -7
  188. package/lib/module/shared/hooks/navigation/use-navigation-helpers.js.map +1 -1
  189. package/lib/module/shared/providers/helpers/measured-bounds-writes.js +1 -2
  190. package/lib/module/shared/providers/helpers/measured-bounds-writes.js.map +1 -1
  191. package/lib/module/shared/providers/screen/animation/animation.provider.js +10 -7
  192. package/lib/module/shared/providers/screen/animation/animation.provider.js.map +1 -1
  193. package/lib/module/shared/providers/screen/animation/helpers/accessors/use-build-transition-accessor.js +6 -8
  194. package/lib/module/shared/providers/screen/animation/helpers/accessors/use-build-transition-accessor.js.map +1 -1
  195. package/lib/module/shared/providers/screen/animation/use-screen-animation.js +8 -2
  196. package/lib/module/shared/providers/screen/animation/use-screen-animation.js.map +1 -1
  197. package/lib/module/shared/providers/screen/gestures/gestures.provider.js +10 -6
  198. package/lib/module/shared/providers/screen/gestures/gestures.provider.js.map +1 -1
  199. package/lib/module/shared/providers/screen/gestures/hooks/use-screen-gesture-config.js +10 -5
  200. package/lib/module/shared/providers/screen/gestures/hooks/use-screen-gesture-config.js.map +1 -1
  201. package/lib/module/shared/providers/screen/gestures/ownership/{use-walk-up-and-register-shadowing-claims.js → gesture-ownership-bridge.js} +35 -49
  202. package/lib/module/shared/providers/screen/gestures/ownership/gesture-ownership-bridge.js.map +1 -0
  203. package/lib/module/shared/providers/screen/gestures/pan/behavior/pan-lifecycle.js +4 -5
  204. package/lib/module/shared/providers/screen/gestures/pan/behavior/pan-lifecycle.js.map +1 -1
  205. package/lib/module/shared/providers/screen/gestures/pan/behavior/use-pan-behavior.js +2 -3
  206. package/lib/module/shared/providers/screen/gestures/pan/behavior/use-pan-behavior.js.map +1 -1
  207. package/lib/module/shared/providers/screen/gestures/pinch/behavior/pinch-lifecycle.js +4 -5
  208. package/lib/module/shared/providers/screen/gestures/pinch/behavior/pinch-lifecycle.js.map +1 -1
  209. package/lib/module/shared/providers/screen/gestures/pinch/behavior/use-pinch-behavior.js +2 -3
  210. package/lib/module/shared/providers/screen/gestures/pinch/behavior/use-pinch-behavior.js.map +1 -1
  211. package/lib/module/shared/providers/screen/gestures/shared/policy.js +9 -5
  212. package/lib/module/shared/providers/screen/gestures/shared/policy.js.map +1 -1
  213. package/lib/module/shared/providers/screen/styles/constants.js +1 -0
  214. package/lib/module/shared/providers/screen/styles/constants.js.map +1 -1
  215. package/lib/module/shared/providers/screen/styles/helpers/transition-visual-state.js +18 -0
  216. package/lib/module/shared/providers/screen/styles/helpers/transition-visual-state.js.map +1 -1
  217. package/lib/module/shared/providers/screen/styles/hooks/slot-resolvers.js +14 -15
  218. package/lib/module/shared/providers/screen/styles/hooks/slot-resolvers.js.map +1 -1
  219. package/lib/module/shared/providers/screen/styles/hooks/use-interpolated-style-maps.js +35 -12
  220. package/lib/module/shared/providers/screen/styles/hooks/use-interpolated-style-maps.js.map +1 -1
  221. package/lib/module/shared/providers/screen/styles/slot.provider.js +19 -30
  222. package/lib/module/shared/providers/screen/styles/slot.provider.js.map +1 -1
  223. package/lib/module/shared/providers/stack/blank-stack-state/blank-stack-controller.js +5 -1
  224. package/lib/module/shared/providers/stack/blank-stack-state/blank-stack-controller.js.map +1 -1
  225. package/lib/module/shared/providers/stack/blank-stack-state/helpers/resolve-presented-index.js +14 -0
  226. package/lib/module/shared/providers/stack/blank-stack-state/helpers/resolve-presented-index.js.map +1 -0
  227. package/lib/module/shared/providers/stack/blank-stack.provider.js +2 -1
  228. package/lib/module/shared/providers/stack/blank-stack.provider.js.map +1 -1
  229. package/lib/module/shared/stores/bounds/internals/links.js +1 -1
  230. package/lib/module/shared/stores/bounds/internals/links.js.map +1 -1
  231. package/lib/module/shared/stores/system.store.js +1 -2
  232. package/lib/module/shared/stores/system.store.js.map +1 -1
  233. package/lib/module/shared/types/animation.types.js.map +1 -1
  234. package/lib/module/shared/utils/animation/animate-to-progress.js +0 -22
  235. package/lib/module/shared/utils/animation/animate-to-progress.js.map +1 -1
  236. package/lib/module/shared/utils/create-provider.js +119 -10
  237. package/lib/module/shared/utils/create-provider.js.map +1 -1
  238. package/lib/module/shared/utils/navigation/close-action-replay.js +16 -0
  239. package/lib/module/shared/utils/navigation/close-action-replay.js.map +1 -0
  240. package/lib/typescript/blank-stack/components/stack-view.d.ts.map +1 -1
  241. package/lib/typescript/blank-stack/types.d.ts +1 -1
  242. package/lib/typescript/blank-stack/types.d.ts.map +1 -1
  243. package/lib/typescript/component-stack/components/stack-view.d.ts.map +1 -1
  244. package/lib/typescript/component-stack/types.d.ts +1 -1
  245. package/lib/typescript/component-stack/types.d.ts.map +1 -1
  246. package/lib/typescript/native-stack/types.d.ts +1 -1
  247. package/lib/typescript/native-stack/types.d.ts.map +1 -1
  248. package/lib/typescript/native-stack/views/NativeStackView.native.d.ts.map +1 -1
  249. package/lib/typescript/shared/components/boundary/components/boundary-lifecycle.d.ts +18 -0
  250. package/lib/typescript/shared/components/boundary/components/boundary-lifecycle.d.ts.map +1 -0
  251. package/lib/typescript/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.d.ts +1 -2
  252. package/lib/typescript/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.d.ts.map +1 -1
  253. package/lib/typescript/shared/components/boundary/hooks/lifecycles/use-refresh-boundary.d.ts.map +1 -1
  254. package/lib/typescript/shared/components/boundary/hooks/use-boundary-measurement.d.ts +3 -2
  255. package/lib/typescript/shared/components/boundary/hooks/use-boundary-measurement.d.ts.map +1 -1
  256. package/lib/typescript/shared/components/boundary/hooks/use-measurer.d.ts +3 -2
  257. package/lib/typescript/shared/components/boundary/hooks/use-measurer.d.ts.map +1 -1
  258. package/lib/typescript/shared/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.d.ts.map +1 -1
  259. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/components/host.d.ts.map +1 -1
  260. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/components/portal-boundary-host.d.ts +5 -1
  261. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/components/portal-boundary-host.d.ts.map +1 -1
  262. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/helpers/local-measurement.d.ts +4 -0
  263. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/helpers/local-measurement.d.ts.map +1 -0
  264. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/helpers/offset-style.d.ts +4 -17
  265. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/helpers/offset-style.d.ts.map +1 -1
  266. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/hooks/use-active-portal-boundary-host.d.ts +3 -1
  267. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/hooks/use-active-portal-boundary-host.d.ts.map +1 -1
  268. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.d.ts.map +1 -1
  269. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/hooks/use-host-measurement.d.ts +5 -9
  270. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/hooks/use-host-measurement.d.ts.map +1 -1
  271. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/stores/portal-boundary-host.store.d.ts +2 -1
  272. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/stores/portal-boundary-host.store.d.ts.map +1 -1
  273. package/lib/typescript/shared/components/boundary/providers/boundary-root.provider.d.ts +2 -1
  274. package/lib/typescript/shared/components/boundary/providers/boundary-root.provider.d.ts.map +1 -1
  275. package/lib/typescript/shared/components/boundary/types.d.ts +6 -0
  276. package/lib/typescript/shared/components/boundary/types.d.ts.map +1 -1
  277. package/lib/typescript/shared/components/boundary/utils/refresh-signals.d.ts +1 -0
  278. package/lib/typescript/shared/components/boundary/utils/refresh-signals.d.ts.map +1 -1
  279. package/lib/typescript/shared/components/overlay/helpers/create-overlay-interpolator-frame.d.ts +7 -0
  280. package/lib/typescript/shared/components/overlay/helpers/create-overlay-interpolator-frame.d.ts.map +1 -0
  281. package/lib/typescript/shared/components/overlay/helpers/get-active-overlay.d.ts +17 -7
  282. package/lib/typescript/shared/components/overlay/helpers/get-active-overlay.d.ts.map +1 -1
  283. package/lib/typescript/shared/components/overlay/helpers/retain-ready-overlay-resources.d.ts +11 -0
  284. package/lib/typescript/shared/components/overlay/helpers/retain-ready-overlay-resources.d.ts.map +1 -0
  285. package/lib/typescript/shared/components/overlay/helpers/run-overlay-slot-interpolator.d.ts +8 -0
  286. package/lib/typescript/shared/components/overlay/helpers/run-overlay-slot-interpolator.d.ts.map +1 -0
  287. package/lib/typescript/shared/components/overlay/hooks/use-overlay-slot.d.ts +15 -0
  288. package/lib/typescript/shared/components/overlay/hooks/use-overlay-slot.d.ts.map +1 -0
  289. package/lib/typescript/shared/components/overlay/variations/float-overlay.d.ts +1 -1
  290. package/lib/typescript/shared/components/overlay/variations/float-overlay.d.ts.map +1 -1
  291. package/lib/typescript/shared/components/overlay/variations/overlay-host.d.ts +7 -6
  292. package/lib/typescript/shared/components/overlay/variations/overlay-host.d.ts.map +1 -1
  293. package/lib/typescript/shared/components/screen-container/layers/backdrop.d.ts.map +1 -1
  294. package/lib/typescript/shared/components/screen-lifecycle/hooks/helpers/close-interception-rules.d.ts +27 -0
  295. package/lib/typescript/shared/components/screen-lifecycle/hooks/helpers/close-interception-rules.d.ts.map +1 -0
  296. package/lib/typescript/shared/components/screen-lifecycle/hooks/use-close-completion.d.ts +7 -0
  297. package/lib/typescript/shared/components/screen-lifecycle/hooks/use-close-completion.d.ts.map +1 -0
  298. package/lib/typescript/shared/components/screen-lifecycle/hooks/use-close-transition-intent.d.ts +2 -7
  299. package/lib/typescript/shared/components/screen-lifecycle/hooks/use-close-transition-intent.d.ts.map +1 -1
  300. package/lib/typescript/shared/components/screen-lifecycle/hooks/use-transition-start-controller.d.ts +1 -3
  301. package/lib/typescript/shared/components/screen-lifecycle/hooks/use-transition-start-controller.d.ts.map +1 -1
  302. package/lib/typescript/shared/components/screen-lifecycle/index.d.ts.map +1 -1
  303. package/lib/typescript/shared/hooks/navigation/use-navigation-helpers.d.ts +1 -0
  304. package/lib/typescript/shared/hooks/navigation/use-navigation-helpers.d.ts.map +1 -1
  305. package/lib/typescript/shared/index.d.ts +12 -12
  306. package/lib/typescript/shared/index.d.ts.map +1 -1
  307. package/lib/typescript/shared/providers/screen/animation/animation.provider.d.ts +4 -0
  308. package/lib/typescript/shared/providers/screen/animation/animation.provider.d.ts.map +1 -1
  309. package/lib/typescript/shared/providers/screen/animation/helpers/accessors/use-build-transition-accessor.d.ts +4 -1
  310. package/lib/typescript/shared/providers/screen/animation/helpers/accessors/use-build-transition-accessor.d.ts.map +1 -1
  311. package/lib/typescript/shared/providers/screen/animation/use-screen-animation.d.ts.map +1 -1
  312. package/lib/typescript/shared/providers/screen/gestures/gestures.provider.d.ts.map +1 -1
  313. package/lib/typescript/shared/providers/screen/gestures/hooks/use-screen-gesture-config.d.ts +2 -2
  314. package/lib/typescript/shared/providers/screen/gestures/hooks/use-screen-gesture-config.d.ts.map +1 -1
  315. package/lib/typescript/shared/providers/screen/gestures/ownership/gesture-ownership-bridge.d.ts +3 -0
  316. package/lib/typescript/shared/providers/screen/gestures/ownership/gesture-ownership-bridge.d.ts.map +1 -0
  317. package/lib/typescript/shared/providers/screen/gestures/pan/behavior/pan-lifecycle.d.ts +1 -1
  318. package/lib/typescript/shared/providers/screen/gestures/pan/behavior/pan-lifecycle.d.ts.map +1 -1
  319. package/lib/typescript/shared/providers/screen/gestures/pan/behavior/use-pan-behavior.d.ts.map +1 -1
  320. package/lib/typescript/shared/providers/screen/gestures/pinch/behavior/pinch-lifecycle.d.ts +1 -1
  321. package/lib/typescript/shared/providers/screen/gestures/pinch/behavior/pinch-lifecycle.d.ts.map +1 -1
  322. package/lib/typescript/shared/providers/screen/gestures/pinch/behavior/use-pinch-behavior.d.ts.map +1 -1
  323. package/lib/typescript/shared/providers/screen/gestures/shared/policy.d.ts +2 -1
  324. package/lib/typescript/shared/providers/screen/gestures/shared/policy.d.ts.map +1 -1
  325. package/lib/typescript/shared/providers/screen/gestures/types.d.ts +2 -0
  326. package/lib/typescript/shared/providers/screen/gestures/types.d.ts.map +1 -1
  327. package/lib/typescript/shared/providers/screen/styles/constants.d.ts.map +1 -1
  328. package/lib/typescript/shared/providers/screen/styles/helpers/transition-visual-state.d.ts +7 -0
  329. package/lib/typescript/shared/providers/screen/styles/helpers/transition-visual-state.d.ts.map +1 -1
  330. package/lib/typescript/shared/providers/screen/styles/hooks/slot-resolvers.d.ts.map +1 -1
  331. package/lib/typescript/shared/providers/screen/styles/hooks/use-interpolated-style-maps.d.ts +1 -1
  332. package/lib/typescript/shared/providers/screen/styles/hooks/use-interpolated-style-maps.d.ts.map +1 -1
  333. package/lib/typescript/shared/providers/screen/styles/slot.provider.d.ts +5 -5
  334. package/lib/typescript/shared/providers/screen/styles/slot.provider.d.ts.map +1 -1
  335. package/lib/typescript/shared/providers/stack/blank-stack-state/blank-stack-controller.d.ts.map +1 -1
  336. package/lib/typescript/shared/providers/stack/blank-stack-state/helpers/resolve-presented-index.d.ts +3 -0
  337. package/lib/typescript/shared/providers/stack/blank-stack-state/helpers/resolve-presented-index.d.ts.map +1 -0
  338. package/lib/typescript/shared/providers/stack/blank-stack.provider.d.ts.map +1 -1
  339. package/lib/typescript/shared/stores/system.store.d.ts +1 -2
  340. package/lib/typescript/shared/stores/system.store.d.ts.map +1 -1
  341. package/lib/typescript/shared/types/animation.types.d.ts +8 -0
  342. package/lib/typescript/shared/types/animation.types.d.ts.map +1 -1
  343. package/lib/typescript/shared/types/index.d.ts +1 -1
  344. package/lib/typescript/shared/types/index.d.ts.map +1 -1
  345. package/lib/typescript/shared/types/overlay.types.d.ts +26 -11
  346. package/lib/typescript/shared/types/overlay.types.d.ts.map +1 -1
  347. package/lib/typescript/shared/types/screen.types.d.ts +2 -2
  348. package/lib/typescript/shared/types/screen.types.d.ts.map +1 -1
  349. package/lib/typescript/shared/utils/animation/animate-to-progress.d.ts +2 -3
  350. package/lib/typescript/shared/utils/animation/animate-to-progress.d.ts.map +1 -1
  351. package/lib/typescript/shared/utils/create-provider.d.ts +21 -6
  352. package/lib/typescript/shared/utils/create-provider.d.ts.map +1 -1
  353. package/lib/typescript/shared/utils/navigation/close-action-replay.d.ts +4 -0
  354. package/lib/typescript/shared/utils/navigation/close-action-replay.d.ts.map +1 -0
  355. package/package.json +1 -1
  356. package/src/blank-stack/components/stack-view.tsx +1 -4
  357. package/src/blank-stack/types.ts +8 -2
  358. package/src/component-stack/components/stack-view.tsx +1 -4
  359. package/src/component-stack/types.ts +8 -2
  360. package/src/native-stack/types.ts +8 -2
  361. package/src/native-stack/views/NativeStackView.native.tsx +6 -10
  362. package/src/shared/adapters/with-screen-transitions/stack-layout.tsx +1 -1
  363. package/src/shared/components/boundary/components/boundary-lifecycle.tsx +53 -0
  364. package/src/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.ts +0 -14
  365. package/src/shared/components/boundary/hooks/lifecycles/use-refresh-boundary.ts +13 -2
  366. package/src/shared/components/boundary/hooks/use-boundary-measurement.ts +7 -2
  367. package/src/shared/components/boundary/hooks/use-measurer.ts +11 -1
  368. package/src/shared/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.ts +9 -4
  369. package/src/shared/components/boundary/portal/components/boundary-portal/components/host.tsx +13 -11
  370. package/src/shared/components/boundary/portal/components/boundary-portal/components/portal-boundary-host.tsx +44 -55
  371. package/src/shared/components/boundary/portal/components/boundary-portal/helpers/local-measurement.ts +10 -0
  372. package/src/shared/components/boundary/portal/components/boundary-portal/helpers/offset-style.ts +11 -55
  373. package/src/shared/components/boundary/portal/components/boundary-portal/hooks/use-active-portal-boundary-host.ts +20 -24
  374. package/src/shared/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.ts +11 -0
  375. package/src/shared/components/boundary/portal/components/boundary-portal/hooks/use-host-measurement.ts +20 -67
  376. package/src/shared/components/boundary/portal/components/boundary-portal/index.tsx +1 -0
  377. package/src/shared/components/boundary/portal/components/boundary-portal/stores/portal-boundary-host.store.ts +3 -2
  378. package/src/shared/components/boundary/providers/boundary-root.provider.tsx +29 -20
  379. package/src/shared/components/boundary/types.ts +9 -0
  380. package/src/shared/components/boundary/utils/refresh-signals.ts +39 -6
  381. package/src/shared/components/overlay/helpers/create-overlay-interpolator-frame.ts +29 -0
  382. package/src/shared/components/overlay/helpers/get-active-overlay.ts +62 -20
  383. package/src/shared/components/overlay/helpers/retain-ready-overlay-resources.ts +38 -0
  384. package/src/shared/components/overlay/helpers/run-overlay-slot-interpolator.ts +48 -0
  385. package/src/shared/components/overlay/hooks/use-overlay-slot.ts +103 -0
  386. package/src/shared/components/overlay/variations/float-overlay.tsx +22 -64
  387. package/src/shared/components/overlay/variations/overlay-host.tsx +135 -28
  388. package/src/shared/components/screen-container/layers/backdrop.tsx +11 -7
  389. package/src/shared/components/screen-lifecycle/hooks/helpers/close-interception-rules.ts +64 -0
  390. package/src/shared/components/screen-lifecycle/hooks/use-close-completion.ts +28 -0
  391. package/src/shared/components/screen-lifecycle/hooks/use-close-transition-intent.ts +72 -109
  392. package/src/shared/components/screen-lifecycle/hooks/use-transition-start-controller.ts +0 -12
  393. package/src/shared/components/screen-lifecycle/index.tsx +8 -4
  394. package/src/shared/hooks/navigation/use-navigation-helpers.ts +39 -7
  395. package/src/shared/index.ts +1 -0
  396. package/src/shared/providers/helpers/measured-bounds-writes.ts +1 -1
  397. package/src/shared/providers/screen/animation/animation.provider.tsx +24 -11
  398. package/src/shared/providers/screen/animation/helpers/accessors/use-build-transition-accessor.ts +15 -9
  399. package/src/shared/providers/screen/animation/use-screen-animation.tsx +12 -2
  400. package/src/shared/providers/screen/gestures/gestures.provider.tsx +18 -7
  401. package/src/shared/providers/screen/gestures/hooks/use-screen-gesture-config.ts +13 -5
  402. package/src/shared/providers/screen/gestures/ownership/{use-walk-up-and-register-shadowing-claims.ts → gesture-ownership-bridge.tsx} +44 -54
  403. package/src/shared/providers/screen/gestures/pan/behavior/pan-lifecycle.ts +4 -6
  404. package/src/shared/providers/screen/gestures/pan/behavior/use-pan-behavior.ts +1 -3
  405. package/src/shared/providers/screen/gestures/pinch/behavior/pinch-lifecycle.ts +4 -6
  406. package/src/shared/providers/screen/gestures/pinch/behavior/use-pinch-behavior.ts +2 -8
  407. package/src/shared/providers/screen/gestures/shared/policy.ts +17 -6
  408. package/src/shared/providers/screen/gestures/types.ts +2 -0
  409. package/src/shared/providers/screen/styles/constants.ts +1 -0
  410. package/src/shared/providers/screen/styles/helpers/transition-visual-state.ts +26 -0
  411. package/src/shared/providers/screen/styles/hooks/slot-resolvers.tsx +17 -5
  412. package/src/shared/providers/screen/styles/hooks/use-interpolated-style-maps.tsx +51 -12
  413. package/src/shared/providers/screen/styles/slot.provider.tsx +46 -70
  414. package/src/shared/providers/stack/blank-stack-state/blank-stack-controller.ts +5 -1
  415. package/src/shared/providers/stack/blank-stack-state/helpers/resolve-presented-index.ts +22 -0
  416. package/src/shared/providers/stack/blank-stack.provider.tsx +6 -1
  417. package/src/shared/stores/bounds/internals/links.ts +1 -1
  418. package/src/shared/stores/system.store.ts +1 -2
  419. package/src/shared/types/animation.types.ts +8 -0
  420. package/src/shared/types/index.ts +1 -1
  421. package/src/shared/types/overlay.types.ts +41 -14
  422. package/src/shared/types/screen.types.ts +2 -2
  423. package/src/shared/utils/animation/animate-to-progress.ts +1 -22
  424. package/src/shared/utils/create-provider.tsx +221 -19
  425. package/src/shared/utils/navigation/close-action-replay.ts +25 -0
  426. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/helpers/active-pair.js +0 -30
  427. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/helpers/active-pair.js.map +0 -1
  428. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/stores/host-bounds.store.js +0 -47
  429. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/stores/host-bounds.store.js.map +0 -1
  430. package/lib/commonjs/shared/providers/screen/gestures/ownership/use-walk-up-and-register-shadowing-claims.js.map +0 -1
  431. package/lib/commonjs/shared/providers/screen/styles/components/floating-overlay-layer.js +0 -28
  432. package/lib/commonjs/shared/providers/screen/styles/components/floating-overlay-layer.js.map +0 -1
  433. package/lib/commonjs/shared/providers/screen/styles/stores/slot-references.store.js +0 -53
  434. package/lib/commonjs/shared/providers/screen/styles/stores/slot-references.store.js.map +0 -1
  435. package/lib/module/shared/components/boundary/portal/components/boundary-portal/helpers/active-pair.js +0 -25
  436. package/lib/module/shared/components/boundary/portal/components/boundary-portal/helpers/active-pair.js.map +0 -1
  437. package/lib/module/shared/components/boundary/portal/components/boundary-portal/stores/host-bounds.store.js +0 -40
  438. package/lib/module/shared/components/boundary/portal/components/boundary-portal/stores/host-bounds.store.js.map +0 -1
  439. package/lib/module/shared/providers/screen/gestures/ownership/use-walk-up-and-register-shadowing-claims.js.map +0 -1
  440. package/lib/module/shared/providers/screen/styles/components/floating-overlay-layer.js +0 -24
  441. package/lib/module/shared/providers/screen/styles/components/floating-overlay-layer.js.map +0 -1
  442. package/lib/module/shared/providers/screen/styles/stores/slot-references.store.js +0 -47
  443. package/lib/module/shared/providers/screen/styles/stores/slot-references.store.js.map +0 -1
  444. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/helpers/active-pair.d.ts +0 -9
  445. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/helpers/active-pair.d.ts.map +0 -1
  446. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/stores/host-bounds.store.d.ts +0 -9
  447. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/stores/host-bounds.store.d.ts.map +0 -1
  448. package/lib/typescript/shared/providers/screen/gestures/ownership/use-walk-up-and-register-shadowing-claims.d.ts +0 -14
  449. package/lib/typescript/shared/providers/screen/gestures/ownership/use-walk-up-and-register-shadowing-claims.d.ts.map +0 -1
  450. package/lib/typescript/shared/providers/screen/styles/components/floating-overlay-layer.d.ts +0 -7
  451. package/lib/typescript/shared/providers/screen/styles/components/floating-overlay-layer.d.ts.map +0 -1
  452. package/lib/typescript/shared/providers/screen/styles/stores/slot-references.store.d.ts +0 -6
  453. package/lib/typescript/shared/providers/screen/styles/stores/slot-references.store.d.ts.map +0 -1
  454. package/src/shared/components/boundary/portal/components/boundary-portal/helpers/active-pair.ts +0 -36
  455. package/src/shared/components/boundary/portal/components/boundary-portal/stores/host-bounds.store.ts +0 -45
  456. package/src/shared/providers/screen/styles/components/floating-overlay-layer.tsx +0 -29
  457. package/src/shared/providers/screen/styles/stores/slot-references.store.ts +0 -72
@@ -2,53 +2,160 @@ import {
2
2
  NavigationContext,
3
3
  NavigationRouteContext,
4
4
  } from "@react-navigation/native";
5
- import { memo, useMemo } from "react";
6
- import { Animated, StyleSheet, View } from "react-native";
7
- import { useDerivedValue } from "react-native-reanimated";
8
- import type { StackScene } from "../../../hooks/navigation/use-stack";
9
- import { useScreenAnimation } from "../../../providers/screen/animation";
10
- import type { BaseDescriptor } from "../../../providers/screen/descriptors";
5
+ import { memo, useMemo, useRef } from "react";
6
+ import { StyleSheet, View } from "react-native";
7
+ import Animated, { useDerivedValue } from "react-native-reanimated";
8
+ import { snapDescriptorToIndex } from "../../../animation/snap-to";
9
+ import { useStack } from "../../../hooks/navigation/use-stack";
10
+ import { useScreenAnimationStore } from "../../../providers/screen/animation";
11
+ import type { ScreenAnimationContextValue } from "../../../providers/screen/animation/animation.provider";
12
+ import {
13
+ type ScreenSlotContextValue,
14
+ useScreenSlots,
15
+ } from "../../../providers/screen/styles/slot.provider";
16
+ import type { OverlayProps } from "../../../types/overlay.types";
11
17
  import type {
12
- OverlayProps,
13
- OverlayScreenState,
14
- } from "../../../types/overlay.types";
18
+ FloatOverlayActivity,
19
+ FloatOverlayEntry,
20
+ } from "../helpers/get-active-overlay";
21
+ import {
22
+ type ReadyOverlayResources,
23
+ retainReadyOverlayResources,
24
+ } from "../helpers/retain-ready-overlay-resources";
25
+ import { useOverlaySlot } from "../hooks/use-overlay-slot";
15
26
 
16
27
  type OverlayHostProps = {
17
- scene: StackScene;
18
- overlayScreenState: OverlayScreenState<BaseDescriptor["navigation"]>;
28
+ scene: FloatOverlayEntry["scene"];
29
+ driverScene: FloatOverlayEntry["scene"];
30
+ previousOverlayScene?: FloatOverlayEntry["scene"];
31
+ activity: FloatOverlayActivity;
32
+ layerIndex: number;
19
33
  };
20
34
 
21
35
  export const OverlayHost = memo(function OverlayHost({
22
36
  scene,
23
- overlayScreenState,
37
+ driverScene,
38
+ previousOverlayScene,
39
+ activity,
40
+ layerIndex,
24
41
  }: OverlayHostProps) {
25
- const OverlayComponent = scene.descriptor.options.overlay;
42
+ const overlayAnimationStore = useScreenAnimationStore(scene.route.key);
43
+ const driverAnimationStore = useScreenAnimationStore(driverScene.route.key);
44
+ const previousOverlayAnimationStore = useScreenAnimationStore(
45
+ previousOverlayScene?.route.key ?? scene.route.key,
46
+ );
47
+ const driverSlots = useScreenSlots(driverScene.route.key);
48
+ const overlayComponentRef = useRef(scene.descriptor.options.overlay);
49
+ const OverlayComponent = overlayComponentRef.current;
50
+ const readyResourcesRef = useRef<ReadyOverlayResources | null>(null);
51
+ readyResourcesRef.current = retainReadyOverlayResources(
52
+ readyResourcesRef.current,
53
+ overlayAnimationStore,
54
+ driverScene,
55
+ driverAnimationStore,
56
+ driverSlots,
57
+ );
58
+ const readyResources = readyResourcesRef.current;
59
+
60
+ if (!OverlayComponent || !readyResources) {
61
+ return null;
62
+ }
63
+
64
+ return (
65
+ <ReadyOverlayHost
66
+ scene={scene}
67
+ driverScene={readyResources.driverScene}
68
+ activity={activity}
69
+ layerIndex={layerIndex}
70
+ overlayAnimationStore={readyResources.overlayAnimationStore}
71
+ driverAnimationStore={readyResources.driverAnimationStore}
72
+ previousOverlayAnimationStore={
73
+ previousOverlayScene ? previousOverlayAnimationStore : undefined
74
+ }
75
+ driverSlots={readyResources.driverSlots}
76
+ OverlayComponent={OverlayComponent}
77
+ />
78
+ );
79
+ });
80
+
81
+ type ReadyOverlayHostProps = OverlayHostProps & {
82
+ overlayAnimationStore: ScreenAnimationContextValue;
83
+ driverAnimationStore: ScreenAnimationContextValue;
84
+ previousOverlayAnimationStore?: ScreenAnimationContextValue | null;
85
+ driverSlots: ScreenSlotContextValue;
86
+ OverlayComponent: NonNullable<
87
+ FloatOverlayEntry["scene"]["descriptor"]["options"]["overlay"]
88
+ >;
89
+ };
26
90
 
27
- const screenAnimation = useScreenAnimation();
91
+ function ReadyOverlayHost({
92
+ scene,
93
+ driverScene,
94
+ activity,
95
+ layerIndex,
96
+ overlayAnimationStore,
97
+ driverAnimationStore,
98
+ previousOverlayAnimationStore,
99
+ driverSlots,
100
+ OverlayComponent,
101
+ }: ReadyOverlayHostProps) {
102
+ const { scenes, focusedIndex, routeKeys, routes } = useStack();
103
+ const descriptor = scene.descriptor;
104
+ const focusedScene = scenes[focusedIndex] ?? scenes[scenes.length - 1];
105
+ const focusedDescriptor = focusedScene?.descriptor;
106
+ const { animatedProps, animatedStyle } = useOverlaySlot({
107
+ overlayAnimationStore,
108
+ driverAnimationStore,
109
+ previousOverlayAnimationStore: previousOverlayAnimationStore ?? undefined,
110
+ driverInterpolator: driverScene.descriptor.options.screenStyleInterpolator,
111
+ interpolatorReady: driverSlots.interpolatorReady,
112
+ isIncoming: scene.route.key === driverScene.route.key,
113
+ });
28
114
  const relativeProgress = useDerivedValue(() => {
29
115
  "worklet";
30
- return screenAnimation.get().stackProgress;
116
+ overlayAnimationStore.screenInterpolatorPropsRevision.get();
117
+ return overlayAnimationStore.screenInterpolatorProps.get().stackProgress;
31
118
  });
32
119
 
33
- const overlayProps: OverlayProps<BaseDescriptor["navigation"]> = useMemo(
120
+ const overlayProps: OverlayProps = useMemo(
34
121
  () => ({
35
- ...overlayScreenState,
122
+ route: scene.route,
123
+ index: routeKeys.indexOf(scene.route.key),
124
+ options: focusedDescriptor?.options ?? {},
125
+ routes,
126
+ focusedRoute: focusedScene?.route ?? scene.route,
127
+ focusedIndex,
128
+ meta: focusedDescriptor?.options?.meta,
129
+ navigation: scene.descriptor.navigation,
130
+ snapTo: (index: number) => {
131
+ snapDescriptorToIndex(scene.descriptor, index);
132
+ },
36
133
  progress: relativeProgress,
37
134
  }),
38
- [relativeProgress, overlayScreenState],
135
+ [
136
+ scene,
137
+ focusedDescriptor?.options,
138
+ focusedIndex,
139
+ focusedScene?.route,
140
+ relativeProgress,
141
+ routeKeys,
142
+ routes,
143
+ ],
39
144
  );
40
-
41
- if (!OverlayComponent) {
42
- return null;
43
- }
44
-
45
145
  return (
46
146
  <Animated.View
47
- pointerEvents="box-none"
48
- style={[styles.container, styles.floating, StyleSheet.absoluteFill]}
147
+ animatedProps={animatedProps}
148
+ pointerEvents={activity === "active" ? "box-none" : "none"}
149
+ style={[
150
+ styles.container,
151
+ styles.floating,
152
+ StyleSheet.absoluteFill,
153
+ { zIndex: 1000 + layerIndex },
154
+ animatedStyle,
155
+ ]}
49
156
  >
50
- <NavigationContext.Provider value={scene.descriptor.navigation as any}>
51
- <NavigationRouteContext.Provider value={scene.route}>
157
+ <NavigationContext.Provider value={descriptor.navigation as any}>
158
+ <NavigationRouteContext.Provider value={descriptor.route}>
52
159
  <View
53
160
  pointerEvents="box-none"
54
161
  style={[StyleSheet.absoluteFill, styles.overlay]}
@@ -59,7 +166,7 @@ export const OverlayHost = memo(function OverlayHost({
59
166
  </NavigationContext.Provider>
60
167
  </Animated.View>
61
168
  );
62
- });
169
+ }
63
170
 
64
171
  const styles = StyleSheet.create({
65
172
  overlay: {
@@ -1,6 +1,6 @@
1
1
  import { type ComponentType, memo, useCallback, useMemo } from "react";
2
2
  import { Pressable, StyleSheet } from "react-native";
3
- import Animated, { runOnUI } from "react-native-reanimated";
3
+ import Animated, { runOnJS, runOnUI } from "react-native-reanimated";
4
4
  import { DefaultSnapSpec } from "../../../configs/specs";
5
5
  import { useNavigationHelpers } from "../../../hooks/navigation/use-navigation-helpers";
6
6
  import { useDescriptorsStore } from "../../../providers/screen/descriptors";
@@ -23,7 +23,7 @@ export const BackdropLayer = memo(function BackdropLayer({
23
23
  backdropBehavior: BackdropBehavior;
24
24
  isBackdropActive: boolean;
25
25
  }) {
26
- const { dismissScreen } = useNavigationHelpers();
26
+ const { isRemovePrevented, requestDismiss } = useNavigationHelpers();
27
27
 
28
28
  const routeKey = useDescriptorsStore(
29
29
  (store) => store.derivations.currentScreenKey,
@@ -34,9 +34,10 @@ export const BackdropLayer = memo(function BackdropLayer({
34
34
  const rawSnapPoints = useDescriptorsStore(
35
35
  (store) => store.options.snapPoints,
36
36
  );
37
- const canDismiss = useDescriptorsStore(
37
+ const isGestureDismissEnabled = useDescriptorsStore(
38
38
  (store) => store.options.gestureEnabled !== false,
39
39
  );
40
+ const canDismiss = isGestureDismissEnabled && !isRemovePrevented;
40
41
  const transitionSpec = useDescriptorsStore(
41
42
  (store) => store.options.transitionSpec,
42
43
  );
@@ -56,14 +57,14 @@ export const BackdropLayer = memo(function BackdropLayer({
56
57
 
57
58
  const handleBackdropPress = useCallback(() => {
58
59
  if (backdropBehavior === "dismiss") {
59
- dismissScreen();
60
+ requestDismiss();
60
61
  return;
61
62
  }
62
63
 
63
64
  if (backdropBehavior === "collapse") {
64
65
  // No snap points → fallback to dismiss
65
66
  if (!rawSnapPoints || rawSnapPoints.length === 0) {
66
- dismissScreen();
67
+ requestDismiss();
67
68
  return;
68
69
  }
69
70
 
@@ -108,8 +109,11 @@ export const BackdropLayer = memo(function BackdropLayer({
108
109
  animations,
109
110
  targetProgress,
110
111
  animationProgress,
111
- onAnimationFinish: shouldDismiss ? dismissScreen : undefined,
112
112
  });
113
+
114
+ if (shouldDismiss) {
115
+ runOnJS(requestDismiss)();
116
+ }
113
117
  })();
114
118
  }
115
119
  }, [
@@ -121,7 +125,7 @@ export const BackdropLayer = memo(function BackdropLayer({
121
125
  rawSnapPoints,
122
126
  canDismiss,
123
127
  transitionSpec,
124
- dismissScreen,
128
+ requestDismiss,
125
129
  routeKey,
126
130
  ]);
127
131
 
@@ -0,0 +1,64 @@
1
+ interface CloseInterceptionState {
2
+ enabled: boolean;
3
+ ownsAction: boolean;
4
+ ancestorDismissing: boolean;
5
+ routeIndex: number;
6
+ focusedIndex: number;
7
+ }
8
+
9
+ interface NavigationRouteLike {
10
+ key: string;
11
+ state?: NavigationStateLike;
12
+ }
13
+
14
+ interface NavigationStateLike {
15
+ key?: string;
16
+ routes: NavigationRouteLike[];
17
+ }
18
+
19
+ interface NavigationActionLike {
20
+ source?: unknown;
21
+ target?: unknown;
22
+ }
23
+
24
+ const containsRouteKey = (
25
+ routes: NavigationRouteLike[],
26
+ routeKey: string,
27
+ ): boolean =>
28
+ routes.some(
29
+ (route) =>
30
+ route.key === routeKey ||
31
+ (route.state ? containsRouteKey(route.state.routes, routeKey) : false),
32
+ );
33
+
34
+ export const doesNavigatorOwnCloseAction = ({
35
+ state,
36
+ action,
37
+ }: {
38
+ state: NavigationStateLike;
39
+ action: NavigationActionLike;
40
+ }): boolean => {
41
+ if (typeof action.target === "string") {
42
+ return action.target === state.key;
43
+ }
44
+
45
+ if (typeof action.source === "string") {
46
+ return containsRouteKey(state.routes, action.source);
47
+ }
48
+
49
+ return true;
50
+ };
51
+
52
+ /** Only the focused removable route owns a stack close transition. */
53
+ export const shouldInterceptClose = ({
54
+ enabled,
55
+ ownsAction,
56
+ ancestorDismissing,
57
+ routeIndex,
58
+ focusedIndex,
59
+ }: CloseInterceptionState) =>
60
+ enabled &&
61
+ ownsAction &&
62
+ !ancestorDismissing &&
63
+ routeIndex > 0 &&
64
+ routeIndex === focusedIndex;
@@ -0,0 +1,28 @@
1
+ import {
2
+ runOnJS,
3
+ type SharedValue,
4
+ useAnimatedReaction,
5
+ } from "react-native-reanimated";
6
+
7
+ export const useCloseCompletion = ({
8
+ closing,
9
+ animationProgress,
10
+ onComplete,
11
+ }: {
12
+ closing: SharedValue<number>;
13
+ animationProgress: SharedValue<number>;
14
+ onComplete: () => void;
15
+ }) => {
16
+ useAnimatedReaction(
17
+ () => {
18
+ "worklet";
19
+ return !!closing.get() && animationProgress.get() <= 0;
20
+ },
21
+ (complete, previouslyComplete) => {
22
+ "worklet";
23
+ if (complete && !previouslyComplete) {
24
+ runOnJS(onComplete)();
25
+ }
26
+ },
27
+ );
28
+ };
@@ -1,6 +1,7 @@
1
- /** biome-ignore-all lint/correctness/useHookAtTopLevel: STACK_TYPE is stable per navigator */
2
1
  import { useLayoutEffect, useMemo, useRef } from "react";
2
+ import { useNavigationHelpers } from "../../../hooks/navigation/use-navigation-helpers";
3
3
  import useStableCallback from "../../../hooks/use-stable-callback";
4
+ import { hasTransitionsEnabled } from "../../../providers/screen/animation/helpers/has-transitions-enabled";
4
5
  import {
5
6
  type BaseDescriptor,
6
7
  useDescriptorsStore,
@@ -8,68 +9,34 @@ import {
8
9
  import { useBlankStackStore } from "../../../providers/stack/blank-stack.provider";
9
10
  import { useStackCoreStore } from "../../../providers/stack/core.provider";
10
11
  import { GestureStore } from "../../../stores/gesture.store";
11
- import {
12
- LifecycleTransitionRequestKind,
13
- type SystemStoreActions,
14
- type SystemStoreMap,
15
- } from "../../../stores/system.store";
16
12
  import { StackType } from "../../../types/stack.types";
13
+ import {
14
+ dispatchCloseAction,
15
+ isCloseActionReplay,
16
+ } from "../../../utils/navigation/close-action-replay";
17
+ import {
18
+ doesNavigatorOwnCloseAction,
19
+ shouldInterceptClose,
20
+ } from "./helpers/close-interception-rules";
17
21
  import { resetStoresForScreen } from "./helpers/reset-stores-for-screen";
18
22
 
19
- interface CloseHookParams {
20
- current: BaseDescriptor;
21
- requestLifecycleTransition: SystemStoreActions["requestLifecycleTransition"];
22
- resetStores: () => void;
23
- }
24
-
25
- const useBlankStackClose = ({
26
- current,
27
- requestLifecycleTransition,
28
- resetStores,
29
- }: CloseHookParams) => {
23
+ export function useCloseTransitionIntent(current: BaseDescriptor): {
24
+ completeClose: () => void;
25
+ } {
26
+ const routeKey = current.route.key;
27
+ const { STACK_TYPE: stackType, TRANSITIONS_ALWAYS_ON: transitionsAlwaysOn } =
28
+ useStackCoreStore((store) => store.flags);
30
29
  const handleCloseRoute = useBlankStackStore(
31
30
  (store) => store?.handleCloseRoute,
32
31
  );
33
- const isClosing = useBlankStackStore(
34
- (store) => store?.scenesByKey[current.route.key]?.activity === "closing",
32
+ const isBlankStackClosing = useBlankStackStore(
33
+ (store) => store?.scenesByKey[routeKey]?.activity === "closing",
35
34
  );
36
-
37
- useLayoutEffect(() => {
38
- if (!isClosing) {
39
- return;
40
- }
41
-
42
- requestLifecycleTransition(
43
- LifecycleTransitionRequestKind.BlankStackClose,
44
- 0,
45
- );
46
- }, [isClosing, requestLifecycleTransition]);
47
-
48
- const handleBlankStackCloseEnd = useStableCallback((finished: boolean) => {
49
- if (!finished) return;
50
- if (!handleCloseRoute) {
51
- throw new Error("Blank stack close handler was not found.");
52
- }
53
- handleCloseRoute({ route: current.route });
54
- requestAnimationFrame(() => {
55
- resetStores();
56
- });
57
- });
58
-
59
- return { handleBlankStackCloseEnd };
60
- };
61
-
62
- /**
63
- * Native stack close - listens to beforeRemove navigation event.
64
- */
65
- const useNativeStackClose = ({
66
- current,
67
- requestLifecycleTransition,
68
- resetStores,
69
- }: CloseHookParams) => {
70
- const parentScreenKey = useDescriptorsStore(
71
- (store) => store.derivations.parentScreenKey,
35
+ const ancestorKeys = useDescriptorsStore(
36
+ (store) => store.derivations.ancestorKeys,
72
37
  );
38
+ const parentScreenKey = ancestorKeys[0];
39
+ const { dismissScreen, requestDismiss } = useNavigationHelpers();
73
40
  const pendingActionRef = useRef<any>(null);
74
41
 
75
42
  const nearestAncestorDismissing = useMemo(() => {
@@ -78,76 +45,72 @@ const useNativeStackClose = ({
78
45
  return GestureStore.peekBag(parentScreenKey)?.dismissing ?? null;
79
46
  }, [parentScreenKey]);
80
47
 
81
- const handleNativeCloseEnd = useStableCallback((finished: boolean) => {
82
- if (!finished || !pendingActionRef.current) {
83
- pendingActionRef.current = null;
84
- return;
48
+ useLayoutEffect(() => {
49
+ if (isBlankStackClosing) {
50
+ requestDismiss();
85
51
  }
52
+ }, [isBlankStackClosing, requestDismiss]);
86
53
 
87
- current.navigation.dispatch(pendingActionRef.current);
54
+ const completeClose = useStableCallback(() => {
55
+ const pendingAction = pendingActionRef.current;
88
56
  pendingActionRef.current = null;
89
- requestAnimationFrame(() => {
90
- resetStores();
91
- });
57
+
58
+ if (pendingAction) {
59
+ dispatchCloseAction(pendingAction, (action) => {
60
+ current.navigation.dispatch(action);
61
+ });
62
+ } else if (stackType !== StackType.NATIVE && handleCloseRoute) {
63
+ handleCloseRoute({ route: current.route });
64
+ } else {
65
+ dismissScreen();
66
+ }
67
+
68
+ resetStoresForScreen(routeKey);
92
69
  });
93
70
 
94
- const handleBeforeRemove = useStableCallback((e: any) => {
95
- const options = current.options as { enableTransitions?: boolean };
96
- const isEnabled = options.enableTransitions;
97
- const navigation = current.navigation;
98
- const routeKey = current.route.key;
99
- const state = navigation.getState();
71
+ const handleBeforeRemove = useStableCallback((event: any) => {
72
+ if (isCloseActionReplay(event.data.action)) {
73
+ return;
74
+ }
75
+
76
+ const state = current.navigation.getState();
100
77
  const routeIndex = state.routes.findIndex(
101
78
  (route) => route.key === routeKey,
102
79
  );
103
- const isFirstScreen = routeIndex <= 0;
80
+ const action = event.data.action;
81
+ const ownsAction = doesNavigatorOwnCloseAction({
82
+ state,
83
+ action,
84
+ });
85
+ const shouldIntercept = shouldInterceptClose({
86
+ enabled: hasTransitionsEnabled(current.options, transitionsAlwaysOn),
87
+ ownsAction,
88
+ ancestorDismissing: !!nearestAncestorDismissing?.get(),
89
+ routeIndex,
90
+ focusedIndex: state.index,
91
+ });
92
+
93
+ if (!shouldIntercept) {
94
+ return;
95
+ }
104
96
 
105
- if (!isEnabled || nearestAncestorDismissing?.get() || isFirstScreen) {
106
- resetStores();
97
+ pendingActionRef.current ??= event.data.action;
98
+ if (!requestDismiss()) {
99
+ pendingActionRef.current = null;
107
100
  return;
108
101
  }
109
102
 
110
- e.preventDefault();
111
- pendingActionRef.current = e.data.action;
112
- requestLifecycleTransition(LifecycleTransitionRequestKind.NativeClose, 0);
103
+ event.preventDefault();
113
104
  });
114
105
 
115
106
  // biome-ignore lint/correctness/useExhaustiveDependencies: navigation listener should only rebind when the navigator instance changes
116
107
  useLayoutEffect(() => {
117
- return current.navigation.addListener?.("beforeRemove", handleBeforeRemove);
118
- }, [current.navigation]);
119
-
120
- return { handleNativeCloseEnd };
121
- };
122
-
123
- /**
124
- * Handles close transition intent and returns finish callbacks for cleanup.
125
- */
126
- export function useCloseTransitionIntent(
127
- current: BaseDescriptor,
128
- system: SystemStoreMap,
129
- ): {
130
- handleBlankStackCloseEnd?: (finished: boolean) => void;
131
- handleNativeCloseEnd?: (finished: boolean) => void;
132
- } {
133
- const routeKey = current.route.key;
134
- const stackType = useStackCoreStore((store) => store.flags.STACK_TYPE);
135
- const isNativeStack = stackType === StackType.NATIVE;
136
- const { requestLifecycleTransition } = system.actions;
137
-
138
- const resetStores = useStableCallback(() => {
139
- resetStoresForScreen(routeKey);
140
- });
141
-
142
- const closeParams: CloseHookParams = {
143
- current,
144
- requestLifecycleTransition,
145
- resetStores,
146
- };
108
+ if (stackType !== StackType.NATIVE) {
109
+ return;
110
+ }
147
111
 
148
- if (isNativeStack) {
149
- return useNativeStackClose(closeParams);
150
- }
112
+ return current.navigation.addListener?.("beforeRemove", handleBeforeRemove);
113
+ }, [current.navigation, stackType]);
151
114
 
152
- return useBlankStackClose(closeParams);
115
+ return { completeClose };
153
116
  }
@@ -12,14 +12,10 @@ export const useTransitionStartController = ({
12
12
  current,
13
13
  animations,
14
14
  system,
15
- onBlankStackCloseFinish,
16
- onNativeCloseFinish,
17
15
  }: {
18
16
  current: BaseDescriptor;
19
17
  animations: AnimationStoreMap;
20
18
  system: SystemStoreMap;
21
- onBlankStackCloseFinish?: (finished: boolean) => void;
22
- onNativeCloseFinish?: (finished: boolean) => void;
23
19
  }) => {
24
20
  const {
25
21
  targetProgress,
@@ -53,13 +49,6 @@ export const useTransitionStartController = ({
53
49
  return;
54
50
  }
55
51
 
56
- const onAnimationFinish =
57
- kind === LifecycleTransitionRequestKind.BlankStackClose
58
- ? onBlankStackCloseFinish
59
- : kind === LifecycleTransitionRequestKind.NativeClose
60
- ? onNativeCloseFinish
61
- : undefined;
62
-
63
52
  animateToProgress({
64
53
  target,
65
54
  spec: transitionSpec,
@@ -69,7 +58,6 @@ export const useTransitionStartController = ({
69
58
  animations,
70
59
  targetProgress,
71
60
  animationProgress,
72
- onAnimationFinish,
73
61
  isDragging,
74
62
  });
75
63
 
@@ -2,6 +2,7 @@ import { useDescriptorsStore } from "../../providers/screen/descriptors";
2
2
  import { AnimationStore } from "../../stores/animation.store";
3
3
  import { SystemStore } from "../../stores/system.store";
4
4
  import { useScreenHistory } from "./hooks/history/use-screen-history";
5
+ import { useCloseCompletion } from "./hooks/use-close-completion";
5
6
  import { useCloseTransitionIntent } from "./hooks/use-close-transition-intent";
6
7
  import { useOpenTransitionIntent } from "./hooks/use-open-transition-intent";
7
8
  import { useTransitionStartController } from "./hooks/use-transition-start-controller";
@@ -21,8 +22,7 @@ export const ScreenLifecycle = ({ children }: Props) => {
21
22
  const animations = AnimationStore.getBag(current.route.key);
22
23
  const system = SystemStore.getBag(current.route.key);
23
24
 
24
- const { handleBlankStackCloseEnd, handleNativeCloseEnd } =
25
- useCloseTransitionIntent(current, system);
25
+ const { completeClose } = useCloseTransitionIntent(current);
26
26
 
27
27
  useOpenTransitionIntent(current, animations, system);
28
28
 
@@ -30,8 +30,12 @@ export const ScreenLifecycle = ({ children }: Props) => {
30
30
  current,
31
31
  animations,
32
32
  system,
33
- onBlankStackCloseFinish: handleBlankStackCloseEnd,
34
- onNativeCloseFinish: handleNativeCloseEnd,
33
+ });
34
+
35
+ useCloseCompletion({
36
+ closing: animations.closing,
37
+ animationProgress: system.animationProgress,
38
+ onComplete: completeClose,
35
39
  });
36
40
 
37
41
  useScreenHistory(current, previous, animations);