react-native-screen-transitions 3.9.0-alpha.2 → 3.9.0-beta.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (475) hide show
  1. package/lib/commonjs/shared/components/boundary/components/boundary-target.js +14 -9
  2. package/lib/commonjs/shared/components/boundary/components/boundary-target.js.map +1 -1
  3. package/lib/commonjs/shared/components/boundary/create-boundary-component.js +66 -28
  4. package/lib/commonjs/shared/components/boundary/create-boundary-component.js.map +1 -1
  5. package/lib/commonjs/shared/components/boundary/hooks/{use-boundary-presence.js → lifecycles/use-boundary-presence.js} +8 -4
  6. package/lib/commonjs/shared/components/boundary/hooks/lifecycles/use-boundary-presence.js.map +1 -0
  7. package/lib/commonjs/shared/components/boundary/hooks/{use-initial-destination-measurement.js → lifecycles/use-initial-destination-measurement.js} +27 -10
  8. package/lib/commonjs/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.js.map +1 -0
  9. package/lib/commonjs/shared/components/boundary/hooks/{use-initial-source-measurement.js → lifecycles/use-initial-source-measurement.js} +5 -7
  10. package/lib/commonjs/shared/components/boundary/hooks/lifecycles/use-initial-source-measurement.js.map +1 -0
  11. package/lib/commonjs/shared/components/boundary/hooks/{use-refresh-boundary.js → lifecycles/use-refresh-boundary.js} +4 -4
  12. package/lib/commonjs/shared/components/boundary/hooks/lifecycles/use-refresh-boundary.js.map +1 -0
  13. package/lib/commonjs/shared/components/boundary/hooks/use-boundary-measurement.js +14 -35
  14. package/lib/commonjs/shared/components/boundary/hooks/use-boundary-measurement.js.map +1 -1
  15. package/lib/commonjs/shared/components/boundary/hooks/use-measurer.js +5 -6
  16. package/lib/commonjs/shared/components/boundary/hooks/use-measurer.js.map +1 -1
  17. package/lib/commonjs/shared/components/boundary/index.js +26 -29
  18. package/lib/commonjs/shared/components/boundary/index.js.map +1 -1
  19. package/lib/commonjs/shared/components/boundary/portal/components/boundary-local-portal-host.js +58 -0
  20. package/lib/commonjs/shared/components/boundary/portal/components/boundary-local-portal-host.js.map +1 -0
  21. package/lib/commonjs/shared/components/boundary/portal/components/host.js +20 -4
  22. package/lib/commonjs/shared/components/boundary/portal/components/host.js.map +1 -1
  23. package/lib/commonjs/shared/components/boundary/portal/components/portal-boundary-host.js +78 -27
  24. package/lib/commonjs/shared/components/boundary/portal/components/portal-boundary-host.js.map +1 -1
  25. package/lib/commonjs/shared/components/boundary/portal/components/portal.js +195 -121
  26. package/lib/commonjs/shared/components/boundary/portal/components/portal.js.map +1 -1
  27. package/lib/commonjs/shared/components/boundary/portal/hooks/use-host-measurement.js +14 -2
  28. package/lib/commonjs/shared/components/boundary/portal/hooks/use-host-measurement.js.map +1 -1
  29. package/lib/commonjs/shared/components/boundary/portal/hooks/use-placeholder-styles.js +57 -0
  30. package/lib/commonjs/shared/components/boundary/portal/hooks/use-placeholder-styles.js.map +1 -0
  31. package/lib/commonjs/shared/components/boundary/portal/stores/host-registry.store.js +5 -44
  32. package/lib/commonjs/shared/components/boundary/portal/stores/host-registry.store.js.map +1 -1
  33. package/lib/commonjs/shared/components/boundary/portal/stores/portal-boundary-host.store.js +37 -5
  34. package/lib/commonjs/shared/components/boundary/portal/stores/portal-boundary-host.store.js.map +1 -1
  35. package/lib/commonjs/shared/components/boundary/portal/teleport.js +15 -2
  36. package/lib/commonjs/shared/components/boundary/portal/teleport.js.map +1 -1
  37. package/lib/commonjs/shared/components/boundary/portal/utils/has-local-slot.js +18 -0
  38. package/lib/commonjs/shared/components/boundary/portal/utils/has-local-slot.js.map +1 -0
  39. package/lib/commonjs/shared/components/boundary/portal/utils/naming.js +10 -3
  40. package/lib/commonjs/shared/components/boundary/portal/utils/naming.js.map +1 -1
  41. package/lib/commonjs/shared/components/boundary/portal/utils/offset-style.js +28 -48
  42. package/lib/commonjs/shared/components/boundary/portal/utils/offset-style.js.map +1 -1
  43. package/lib/commonjs/shared/components/boundary/portal/utils/ownership.js +254 -0
  44. package/lib/commonjs/shared/components/boundary/portal/utils/ownership.js.map +1 -0
  45. package/lib/commonjs/shared/components/boundary/portal/utils/resolve-portal.js +38 -0
  46. package/lib/commonjs/shared/components/boundary/portal/utils/resolve-portal.js.map +1 -0
  47. package/lib/commonjs/shared/components/boundary/portal/utils/shallow-equal.js +29 -0
  48. package/lib/commonjs/shared/components/boundary/portal/utils/shallow-equal.js.map +1 -0
  49. package/lib/commonjs/shared/components/boundary/portal/utils/teleport-control.js +10 -1
  50. package/lib/commonjs/shared/components/boundary/portal/utils/teleport-control.js.map +1 -1
  51. package/lib/commonjs/shared/components/boundary/portal/utils/visible-host.js +25 -0
  52. package/lib/commonjs/shared/components/boundary/portal/utils/visible-host.js.map +1 -0
  53. package/lib/commonjs/shared/components/boundary/providers/boundary-root.provider.js +6 -7
  54. package/lib/commonjs/shared/components/boundary/providers/boundary-root.provider.js.map +1 -1
  55. package/lib/commonjs/shared/components/boundary/utils/destination-signals.js +1 -22
  56. package/lib/commonjs/shared/components/boundary/utils/destination-signals.js.map +1 -1
  57. package/lib/commonjs/shared/components/boundary/utils/refresh-signals.js +0 -21
  58. package/lib/commonjs/shared/components/boundary/utils/refresh-signals.js.map +1 -1
  59. package/lib/commonjs/shared/components/boundary/utils/source-signals.js +4 -9
  60. package/lib/commonjs/shared/components/boundary/utils/source-signals.js.map +1 -1
  61. package/lib/commonjs/shared/components/masked-view.js +5 -0
  62. package/lib/commonjs/shared/components/masked-view.js.map +1 -1
  63. package/lib/commonjs/shared/components/screen-container/layers/backdrop.js +18 -8
  64. package/lib/commonjs/shared/components/screen-container/layers/backdrop.js.map +1 -1
  65. package/lib/commonjs/shared/components/screen-container/layers/content.js +34 -16
  66. package/lib/commonjs/shared/components/screen-container/layers/content.js.map +1 -1
  67. package/lib/commonjs/shared/components/screen-container/layers/render-component.js +10 -0
  68. package/lib/commonjs/shared/components/screen-container/layers/render-component.js.map +1 -0
  69. package/lib/commonjs/shared/components/screen-container/layers/surface-container.js +5 -3
  70. package/lib/commonjs/shared/components/screen-container/layers/surface-container.js.map +1 -1
  71. package/lib/commonjs/shared/index.js +4 -0
  72. package/lib/commonjs/shared/index.js.map +1 -1
  73. package/lib/commonjs/shared/providers/helpers/measured-bounds-writes.js +6 -3
  74. package/lib/commonjs/shared/providers/helpers/measured-bounds-writes.js.map +1 -1
  75. package/lib/commonjs/shared/providers/register-bounds.provider.js +6 -0
  76. package/lib/commonjs/shared/providers/register-bounds.provider.js.map +1 -1
  77. package/lib/commonjs/shared/providers/screen/animation/helpers/derivations.js +1 -0
  78. package/lib/commonjs/shared/providers/screen/animation/helpers/derivations.js.map +1 -1
  79. package/lib/commonjs/shared/providers/screen/animation/helpers/pipeline.js +1 -0
  80. package/lib/commonjs/shared/providers/screen/animation/helpers/pipeline.js.map +1 -1
  81. package/lib/commonjs/shared/providers/screen/styles/helpers/compose-slot-style.js +95 -0
  82. package/lib/commonjs/shared/providers/screen/styles/helpers/compose-slot-style.js.map +1 -0
  83. package/lib/commonjs/shared/providers/screen/styles/helpers/normalize-slots.js +30 -9
  84. package/lib/commonjs/shared/providers/screen/styles/helpers/normalize-slots.js.map +1 -1
  85. package/lib/commonjs/shared/providers/screen/styles/helpers/resolve-slot-styles/index.js +9 -3
  86. package/lib/commonjs/shared/providers/screen/styles/helpers/resolve-slot-styles/index.js.map +1 -1
  87. package/lib/commonjs/shared/providers/screen/styles/helpers/resolve-slot-styles/materialize-slot.js +2 -0
  88. package/lib/commonjs/shared/providers/screen/styles/helpers/resolve-slot-styles/materialize-slot.js.map +1 -1
  89. package/lib/commonjs/shared/providers/screen/styles/hooks/slot-resolvers.js +96 -0
  90. package/lib/commonjs/shared/providers/screen/styles/hooks/slot-resolvers.js.map +1 -0
  91. package/lib/commonjs/shared/providers/screen/styles/hooks/use-interpolated-style-maps.js +16 -3
  92. package/lib/commonjs/shared/providers/screen/styles/hooks/use-interpolated-style-maps.js.map +1 -1
  93. package/lib/commonjs/shared/providers/screen/styles/index.js +16 -3
  94. package/lib/commonjs/shared/providers/screen/styles/index.js.map +1 -1
  95. package/lib/commonjs/shared/providers/screen/styles/slot.provider.js +22 -51
  96. package/lib/commonjs/shared/providers/screen/styles/slot.provider.js.map +1 -1
  97. package/lib/commonjs/shared/providers/screen/styles/stores/slot-references.store.js +53 -0
  98. package/lib/commonjs/shared/providers/screen/styles/stores/slot-references.store.js.map +1 -0
  99. package/lib/commonjs/shared/stores/bounds/helpers/link-pairs.helpers.js +22 -2
  100. package/lib/commonjs/shared/stores/bounds/helpers/link-pairs.helpers.js.map +1 -1
  101. package/lib/commonjs/shared/stores/bounds/internals/entries.js +11 -4
  102. package/lib/commonjs/shared/stores/bounds/internals/entries.js.map +1 -1
  103. package/lib/commonjs/shared/stores/bounds/internals/links.js +134 -51
  104. package/lib/commonjs/shared/stores/bounds/internals/links.js.map +1 -1
  105. package/lib/commonjs/shared/stores/bounds/internals/resolver.js +1 -3
  106. package/lib/commonjs/shared/stores/bounds/internals/resolver.js.map +1 -1
  107. package/lib/commonjs/shared/stores/system.store.js +5 -0
  108. package/lib/commonjs/shared/stores/system.store.js.map +1 -1
  109. package/lib/commonjs/shared/utils/bounds/helpers/styles/compute.js +10 -69
  110. package/lib/commonjs/shared/utils/bounds/helpers/styles/compute.js.map +1 -1
  111. package/lib/commonjs/shared/utils/bounds/helpers/styles/local-transform.js +59 -0
  112. package/lib/commonjs/shared/utils/bounds/helpers/styles/local-transform.js.map +1 -0
  113. package/lib/module/shared/components/boundary/components/boundary-target.js +12 -7
  114. package/lib/module/shared/components/boundary/components/boundary-target.js.map +1 -1
  115. package/lib/module/shared/components/boundary/create-boundary-component.js +67 -29
  116. package/lib/module/shared/components/boundary/create-boundary-component.js.map +1 -1
  117. package/lib/module/shared/components/boundary/hooks/{use-boundary-presence.js → lifecycles/use-boundary-presence.js} +8 -4
  118. package/lib/module/shared/components/boundary/hooks/lifecycles/use-boundary-presence.js.map +1 -0
  119. package/lib/module/shared/components/boundary/hooks/{use-initial-destination-measurement.js → lifecycles/use-initial-destination-measurement.js} +27 -10
  120. package/lib/module/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.js.map +1 -0
  121. package/lib/module/shared/components/boundary/hooks/{use-initial-source-measurement.js → lifecycles/use-initial-source-measurement.js} +5 -7
  122. package/lib/module/shared/components/boundary/hooks/lifecycles/use-initial-source-measurement.js.map +1 -0
  123. package/lib/module/shared/components/boundary/hooks/{use-refresh-boundary.js → lifecycles/use-refresh-boundary.js} +4 -4
  124. package/lib/module/shared/components/boundary/hooks/lifecycles/use-refresh-boundary.js.map +1 -0
  125. package/lib/module/shared/components/boundary/hooks/use-boundary-measurement.js +15 -36
  126. package/lib/module/shared/components/boundary/hooks/use-boundary-measurement.js.map +1 -1
  127. package/lib/module/shared/components/boundary/hooks/use-measurer.js +5 -6
  128. package/lib/module/shared/components/boundary/hooks/use-measurer.js.map +1 -1
  129. package/lib/module/shared/components/boundary/index.js +26 -29
  130. package/lib/module/shared/components/boundary/index.js.map +1 -1
  131. package/lib/module/shared/components/boundary/portal/components/boundary-local-portal-host.js +53 -0
  132. package/lib/module/shared/components/boundary/portal/components/boundary-local-portal-host.js.map +1 -0
  133. package/lib/module/shared/components/boundary/portal/components/host.js +21 -5
  134. package/lib/module/shared/components/boundary/portal/components/host.js.map +1 -1
  135. package/lib/module/shared/components/boundary/portal/components/portal-boundary-host.js +79 -28
  136. package/lib/module/shared/components/boundary/portal/components/portal-boundary-host.js.map +1 -1
  137. package/lib/module/shared/components/boundary/portal/components/portal.js +201 -127
  138. package/lib/module/shared/components/boundary/portal/components/portal.js.map +1 -1
  139. package/lib/module/shared/components/boundary/portal/hooks/use-host-measurement.js +15 -3
  140. package/lib/module/shared/components/boundary/portal/hooks/use-host-measurement.js.map +1 -1
  141. package/lib/module/shared/components/boundary/portal/hooks/use-placeholder-styles.js +52 -0
  142. package/lib/module/shared/components/boundary/portal/hooks/use-placeholder-styles.js.map +1 -0
  143. package/lib/module/shared/components/boundary/portal/stores/host-registry.store.js +4 -41
  144. package/lib/module/shared/components/boundary/portal/stores/host-registry.store.js.map +1 -1
  145. package/lib/module/shared/components/boundary/portal/stores/portal-boundary-host.store.js +35 -4
  146. package/lib/module/shared/components/boundary/portal/stores/portal-boundary-host.store.js.map +1 -1
  147. package/lib/module/shared/components/boundary/portal/teleport.js +16 -2
  148. package/lib/module/shared/components/boundary/portal/teleport.js.map +1 -1
  149. package/lib/module/shared/components/boundary/portal/utils/has-local-slot.js +13 -0
  150. package/lib/module/shared/components/boundary/portal/utils/has-local-slot.js.map +1 -0
  151. package/lib/module/shared/components/boundary/portal/utils/naming.js +8 -2
  152. package/lib/module/shared/components/boundary/portal/utils/naming.js.map +1 -1
  153. package/lib/module/shared/components/boundary/portal/utils/offset-style.js +29 -48
  154. package/lib/module/shared/components/boundary/portal/utils/offset-style.js.map +1 -1
  155. package/lib/module/shared/components/boundary/portal/utils/ownership.js +246 -0
  156. package/lib/module/shared/components/boundary/portal/utils/ownership.js.map +1 -0
  157. package/lib/module/shared/components/boundary/portal/utils/resolve-portal.js +33 -0
  158. package/lib/module/shared/components/boundary/portal/utils/resolve-portal.js.map +1 -0
  159. package/lib/module/shared/components/boundary/portal/utils/shallow-equal.js +24 -0
  160. package/lib/module/shared/components/boundary/portal/utils/shallow-equal.js.map +1 -0
  161. package/lib/module/shared/components/boundary/portal/utils/teleport-control.js +8 -0
  162. package/lib/module/shared/components/boundary/portal/utils/teleport-control.js.map +1 -1
  163. package/lib/module/shared/components/boundary/portal/utils/visible-host.js +20 -0
  164. package/lib/module/shared/components/boundary/portal/utils/visible-host.js.map +1 -0
  165. package/lib/module/shared/components/boundary/providers/boundary-root.provider.js +6 -7
  166. package/lib/module/shared/components/boundary/providers/boundary-root.provider.js.map +1 -1
  167. package/lib/module/shared/components/boundary/utils/destination-signals.js +2 -23
  168. package/lib/module/shared/components/boundary/utils/destination-signals.js.map +1 -1
  169. package/lib/module/shared/components/boundary/utils/refresh-signals.js +0 -21
  170. package/lib/module/shared/components/boundary/utils/refresh-signals.js.map +1 -1
  171. package/lib/module/shared/components/boundary/utils/source-signals.js +4 -9
  172. package/lib/module/shared/components/boundary/utils/source-signals.js.map +1 -1
  173. package/lib/module/shared/components/masked-view.js +5 -0
  174. package/lib/module/shared/components/masked-view.js.map +1 -1
  175. package/lib/module/shared/components/screen-container/layers/backdrop.js +19 -9
  176. package/lib/module/shared/components/screen-container/layers/backdrop.js.map +1 -1
  177. package/lib/module/shared/components/screen-container/layers/content.js +35 -17
  178. package/lib/module/shared/components/screen-container/layers/content.js.map +1 -1
  179. package/lib/module/shared/components/screen-container/layers/render-component.js +6 -0
  180. package/lib/module/shared/components/screen-container/layers/render-component.js.map +1 -0
  181. package/lib/module/shared/components/screen-container/layers/surface-container.js +5 -3
  182. package/lib/module/shared/components/screen-container/layers/surface-container.js.map +1 -1
  183. package/lib/module/shared/index.js +4 -0
  184. package/lib/module/shared/index.js.map +1 -1
  185. package/lib/module/shared/providers/helpers/measured-bounds-writes.js +6 -3
  186. package/lib/module/shared/providers/helpers/measured-bounds-writes.js.map +1 -1
  187. package/lib/module/shared/providers/register-bounds.provider.js +6 -0
  188. package/lib/module/shared/providers/register-bounds.provider.js.map +1 -1
  189. package/lib/module/shared/providers/screen/animation/helpers/derivations.js +1 -0
  190. package/lib/module/shared/providers/screen/animation/helpers/derivations.js.map +1 -1
  191. package/lib/module/shared/providers/screen/animation/helpers/pipeline.js +1 -0
  192. package/lib/module/shared/providers/screen/animation/helpers/pipeline.js.map +1 -1
  193. package/lib/module/shared/providers/screen/styles/helpers/compose-slot-style.js +89 -0
  194. package/lib/module/shared/providers/screen/styles/helpers/compose-slot-style.js.map +1 -0
  195. package/lib/module/shared/providers/screen/styles/helpers/normalize-slots.js +30 -9
  196. package/lib/module/shared/providers/screen/styles/helpers/normalize-slots.js.map +1 -1
  197. package/lib/module/shared/providers/screen/styles/helpers/resolve-slot-styles/index.js +9 -3
  198. package/lib/module/shared/providers/screen/styles/helpers/resolve-slot-styles/index.js.map +1 -1
  199. package/lib/module/shared/providers/screen/styles/helpers/resolve-slot-styles/materialize-slot.js +2 -0
  200. package/lib/module/shared/providers/screen/styles/helpers/resolve-slot-styles/materialize-slot.js.map +1 -1
  201. package/lib/module/shared/providers/screen/styles/hooks/slot-resolvers.js +87 -0
  202. package/lib/module/shared/providers/screen/styles/hooks/slot-resolvers.js.map +1 -0
  203. package/lib/module/shared/providers/screen/styles/hooks/use-interpolated-style-maps.js +16 -3
  204. package/lib/module/shared/providers/screen/styles/hooks/use-interpolated-style-maps.js.map +1 -1
  205. package/lib/module/shared/providers/screen/styles/index.js +2 -1
  206. package/lib/module/shared/providers/screen/styles/index.js.map +1 -1
  207. package/lib/module/shared/providers/screen/styles/slot.provider.js +22 -47
  208. package/lib/module/shared/providers/screen/styles/slot.provider.js.map +1 -1
  209. package/lib/module/shared/providers/screen/styles/stores/slot-references.store.js +47 -0
  210. package/lib/module/shared/providers/screen/styles/stores/slot-references.store.js.map +1 -0
  211. package/lib/module/shared/stores/bounds/helpers/link-pairs.helpers.js +19 -1
  212. package/lib/module/shared/stores/bounds/helpers/link-pairs.helpers.js.map +1 -1
  213. package/lib/module/shared/stores/bounds/internals/entries.js +11 -4
  214. package/lib/module/shared/stores/bounds/internals/entries.js.map +1 -1
  215. package/lib/module/shared/stores/bounds/internals/links.js +135 -53
  216. package/lib/module/shared/stores/bounds/internals/links.js.map +1 -1
  217. package/lib/module/shared/stores/bounds/internals/resolver.js +1 -3
  218. package/lib/module/shared/stores/bounds/internals/resolver.js.map +1 -1
  219. package/lib/module/shared/stores/system.store.js +5 -0
  220. package/lib/module/shared/stores/system.store.js.map +1 -1
  221. package/lib/module/shared/types/animation.types.js.map +1 -1
  222. package/lib/module/shared/utils/bounds/helpers/styles/compute.js +10 -69
  223. package/lib/module/shared/utils/bounds/helpers/styles/compute.js.map +1 -1
  224. package/lib/module/shared/utils/bounds/helpers/styles/local-transform.js +52 -0
  225. package/lib/module/shared/utils/bounds/helpers/styles/local-transform.js.map +1 -0
  226. package/lib/typescript/blank-stack/navigators/create-blank-stack-navigator.d.ts +1 -2
  227. package/lib/typescript/blank-stack/navigators/create-blank-stack-navigator.d.ts.map +1 -1
  228. package/lib/typescript/component-stack/components/component-screen.d.ts +1 -1
  229. package/lib/typescript/component-stack/components/component-screen.d.ts.map +1 -1
  230. package/lib/typescript/component-stack/navigators/create-component-stack-navigator.d.ts +1 -2
  231. package/lib/typescript/component-stack/navigators/create-component-stack-navigator.d.ts.map +1 -1
  232. package/lib/typescript/component-stack/types.d.ts +26 -0
  233. package/lib/typescript/component-stack/types.d.ts.map +1 -1
  234. package/lib/typescript/native-stack/navigators/createNativeStackNavigator.d.ts +1 -1
  235. package/lib/typescript/native-stack/navigators/createNativeStackNavigator.d.ts.map +1 -1
  236. package/lib/typescript/native-stack/views/NativeStackView.d.ts +1 -2
  237. package/lib/typescript/native-stack/views/NativeStackView.d.ts.map +1 -1
  238. package/lib/typescript/native-stack/views/useHeaderConfigProps.d.ts +2 -2
  239. package/lib/typescript/shared/adapters/with-screen-transitions/context.d.ts +1 -1
  240. package/lib/typescript/shared/adapters/with-screen-transitions/context.d.ts.map +1 -1
  241. package/lib/typescript/shared/adapters/with-screen-transitions/stack-layout.d.ts +1 -1
  242. package/lib/typescript/shared/adapters/with-screen-transitions/stack-layout.d.ts.map +1 -1
  243. package/lib/typescript/shared/components/activity/variants/activity-container.d.ts +1 -1
  244. package/lib/typescript/shared/components/activity/variants/activity-container.d.ts.map +1 -1
  245. package/lib/typescript/shared/components/activity/variants/activity-screen.d.ts +1 -1
  246. package/lib/typescript/shared/components/activity/variants/activity-screen.d.ts.map +1 -1
  247. package/lib/typescript/shared/components/boundary/components/boundary-target.d.ts +1 -1
  248. package/lib/typescript/shared/components/boundary/components/boundary-target.d.ts.map +1 -1
  249. package/lib/typescript/shared/components/boundary/create-boundary-component.d.ts +0 -1
  250. package/lib/typescript/shared/components/boundary/create-boundary-component.d.ts.map +1 -1
  251. package/lib/typescript/shared/components/boundary/hooks/lifecycles/use-boundary-presence.d.ts +11 -0
  252. package/lib/typescript/shared/components/boundary/hooks/lifecycles/use-boundary-presence.d.ts.map +1 -0
  253. package/lib/typescript/shared/components/boundary/hooks/{use-initial-destination-measurement.d.ts → lifecycles/use-initial-destination-measurement.d.ts} +2 -2
  254. package/lib/typescript/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.d.ts.map +1 -0
  255. package/lib/typescript/shared/components/boundary/hooks/lifecycles/use-initial-source-measurement.d.ts +8 -0
  256. package/lib/typescript/shared/components/boundary/hooks/lifecycles/use-initial-source-measurement.d.ts.map +1 -0
  257. package/lib/typescript/shared/components/boundary/hooks/{use-refresh-boundary.d.ts → lifecycles/use-refresh-boundary.d.ts} +2 -2
  258. package/lib/typescript/shared/components/boundary/hooks/lifecycles/use-refresh-boundary.d.ts.map +1 -0
  259. package/lib/typescript/shared/components/boundary/hooks/use-boundary-measurement.d.ts +5 -9
  260. package/lib/typescript/shared/components/boundary/hooks/use-boundary-measurement.d.ts.map +1 -1
  261. package/lib/typescript/shared/components/boundary/hooks/use-measurer.d.ts +4 -3
  262. package/lib/typescript/shared/components/boundary/hooks/use-measurer.d.ts.map +1 -1
  263. package/lib/typescript/shared/components/boundary/index.d.ts +35 -24
  264. package/lib/typescript/shared/components/boundary/index.d.ts.map +1 -1
  265. package/lib/typescript/shared/components/boundary/portal/components/boundary-local-portal-host.d.ts +8 -0
  266. package/lib/typescript/shared/components/boundary/portal/components/boundary-local-portal-host.d.ts.map +1 -0
  267. package/lib/typescript/shared/components/boundary/portal/components/host.d.ts +2 -2
  268. package/lib/typescript/shared/components/boundary/portal/components/host.d.ts.map +1 -1
  269. package/lib/typescript/shared/components/boundary/portal/components/portal-boundary-host.d.ts +2 -2
  270. package/lib/typescript/shared/components/boundary/portal/components/portal-boundary-host.d.ts.map +1 -1
  271. package/lib/typescript/shared/components/boundary/portal/components/portal-provider.d.ts +1 -1
  272. package/lib/typescript/shared/components/boundary/portal/components/portal-provider.d.ts.map +1 -1
  273. package/lib/typescript/shared/components/boundary/portal/components/portal.d.ts +4 -3
  274. package/lib/typescript/shared/components/boundary/portal/components/portal.d.ts.map +1 -1
  275. package/lib/typescript/shared/components/boundary/portal/hooks/use-host-measurement.d.ts.map +1 -1
  276. package/lib/typescript/shared/components/boundary/portal/hooks/use-placeholder-styles.d.ts +17 -0
  277. package/lib/typescript/shared/components/boundary/portal/hooks/use-placeholder-styles.d.ts.map +1 -0
  278. package/lib/typescript/shared/components/boundary/portal/stores/host-registry.store.d.ts +0 -7
  279. package/lib/typescript/shared/components/boundary/portal/stores/host-registry.store.d.ts.map +1 -1
  280. package/lib/typescript/shared/components/boundary/portal/stores/portal-boundary-host.store.d.ts +16 -1
  281. package/lib/typescript/shared/components/boundary/portal/stores/portal-boundary-host.store.d.ts.map +1 -1
  282. package/lib/typescript/shared/components/boundary/portal/teleport.d.ts +1 -1
  283. package/lib/typescript/shared/components/boundary/portal/teleport.d.ts.map +1 -1
  284. package/lib/typescript/shared/components/boundary/portal/utils/has-local-slot.d.ts +3 -0
  285. package/lib/typescript/shared/components/boundary/portal/utils/has-local-slot.d.ts.map +1 -0
  286. package/lib/typescript/shared/components/boundary/portal/utils/naming.d.ts +2 -1
  287. package/lib/typescript/shared/components/boundary/portal/utils/naming.d.ts.map +1 -1
  288. package/lib/typescript/shared/components/boundary/portal/utils/offset-style.d.ts +23 -30
  289. package/lib/typescript/shared/components/boundary/portal/utils/offset-style.d.ts.map +1 -1
  290. package/lib/typescript/shared/components/boundary/portal/utils/ownership.d.ts +35 -0
  291. package/lib/typescript/shared/components/boundary/portal/utils/ownership.d.ts.map +1 -0
  292. package/lib/typescript/shared/components/boundary/portal/utils/resolve-portal.d.ts +12 -0
  293. package/lib/typescript/shared/components/boundary/portal/utils/resolve-portal.d.ts.map +1 -0
  294. package/lib/typescript/shared/components/boundary/portal/utils/shallow-equal.d.ts +8 -0
  295. package/lib/typescript/shared/components/boundary/portal/utils/shallow-equal.d.ts.map +1 -0
  296. package/lib/typescript/shared/components/boundary/portal/utils/teleport-control.d.ts +4 -0
  297. package/lib/typescript/shared/components/boundary/portal/utils/teleport-control.d.ts.map +1 -1
  298. package/lib/typescript/shared/components/boundary/portal/utils/visible-host.d.ts +8 -0
  299. package/lib/typescript/shared/components/boundary/portal/utils/visible-host.d.ts.map +1 -0
  300. package/lib/typescript/shared/components/boundary/providers/boundary-root.provider.d.ts +7 -12
  301. package/lib/typescript/shared/components/boundary/providers/boundary-root.provider.d.ts.map +1 -1
  302. package/lib/typescript/shared/components/boundary/types.d.ts +9 -36
  303. package/lib/typescript/shared/components/boundary/types.d.ts.map +1 -1
  304. package/lib/typescript/shared/components/boundary/utils/destination-signals.d.ts.map +1 -1
  305. package/lib/typescript/shared/components/boundary/utils/refresh-signals.d.ts.map +1 -1
  306. package/lib/typescript/shared/components/boundary/utils/source-signals.d.ts +0 -1
  307. package/lib/typescript/shared/components/boundary/utils/source-signals.d.ts.map +1 -1
  308. package/lib/typescript/shared/components/create-transition-aware-component.d.ts +6 -5
  309. package/lib/typescript/shared/components/create-transition-aware-component.d.ts.map +1 -1
  310. package/lib/typescript/shared/components/masked-view.d.ts +5 -1
  311. package/lib/typescript/shared/components/masked-view.d.ts.map +1 -1
  312. package/lib/typescript/shared/components/overlay/variations/float-overlay.d.ts +1 -1
  313. package/lib/typescript/shared/components/overlay/variations/float-overlay.d.ts.map +1 -1
  314. package/lib/typescript/shared/components/overlay/variations/overlay-host.d.ts +1 -1
  315. package/lib/typescript/shared/components/overlay/variations/overlay-host.d.ts.map +1 -1
  316. package/lib/typescript/shared/components/scene-view.d.ts +1 -1
  317. package/lib/typescript/shared/components/scene-view.d.ts.map +1 -1
  318. package/lib/typescript/shared/components/screen-container/index.d.ts +1 -1
  319. package/lib/typescript/shared/components/screen-container/index.d.ts.map +1 -1
  320. package/lib/typescript/shared/components/screen-container/layers/backdrop.d.ts +1 -1
  321. package/lib/typescript/shared/components/screen-container/layers/backdrop.d.ts.map +1 -1
  322. package/lib/typescript/shared/components/screen-container/layers/content.d.ts +1 -1
  323. package/lib/typescript/shared/components/screen-container/layers/content.d.ts.map +1 -1
  324. package/lib/typescript/shared/components/screen-container/layers/maybe-masked-navigation-container.d.ts +1 -1
  325. package/lib/typescript/shared/components/screen-container/layers/maybe-masked-navigation-container.d.ts.map +1 -1
  326. package/lib/typescript/shared/components/screen-container/layers/render-component.d.ts +3 -0
  327. package/lib/typescript/shared/components/screen-container/layers/render-component.d.ts.map +1 -0
  328. package/lib/typescript/shared/components/screen-container/layers/surface-container.d.ts +1 -1
  329. package/lib/typescript/shared/components/screen-container/layers/surface-container.d.ts.map +1 -1
  330. package/lib/typescript/shared/hooks/navigation/use-stack.d.ts +1 -1
  331. package/lib/typescript/shared/hooks/navigation/use-stack.d.ts.map +1 -1
  332. package/lib/typescript/shared/index.d.ts +731 -683
  333. package/lib/typescript/shared/index.d.ts.map +1 -1
  334. package/lib/typescript/shared/providers/helpers/measured-bounds-writes.d.ts +3 -3
  335. package/lib/typescript/shared/providers/helpers/measured-bounds-writes.d.ts.map +1 -1
  336. package/lib/typescript/shared/providers/register-bounds.provider.d.ts.map +1 -1
  337. package/lib/typescript/shared/providers/screen/animation/helpers/derivations.d.ts +1 -0
  338. package/lib/typescript/shared/providers/screen/animation/helpers/derivations.d.ts.map +1 -1
  339. package/lib/typescript/shared/providers/screen/animation/helpers/pipeline.d.ts.map +1 -1
  340. package/lib/typescript/shared/providers/screen/descriptors/descriptors.provider.d.ts +1 -1
  341. package/lib/typescript/shared/providers/screen/descriptors/descriptors.provider.d.ts.map +1 -1
  342. package/lib/typescript/shared/providers/screen/screen-composer.d.ts +1 -1
  343. package/lib/typescript/shared/providers/screen/screen-composer.d.ts.map +1 -1
  344. package/lib/typescript/shared/providers/screen/styles/components/floating-overlay-layer.d.ts +1 -1
  345. package/lib/typescript/shared/providers/screen/styles/components/floating-overlay-layer.d.ts.map +1 -1
  346. package/lib/typescript/shared/providers/screen/styles/helpers/compose-slot-style.d.ts +4 -0
  347. package/lib/typescript/shared/providers/screen/styles/helpers/compose-slot-style.d.ts.map +1 -0
  348. package/lib/typescript/shared/providers/screen/styles/helpers/normalize-slots.d.ts.map +1 -1
  349. package/lib/typescript/shared/providers/screen/styles/helpers/resolve-slot-styles/index.d.ts.map +1 -1
  350. package/lib/typescript/shared/providers/screen/styles/helpers/resolve-slot-styles/materialize-slot.d.ts +2 -1
  351. package/lib/typescript/shared/providers/screen/styles/helpers/resolve-slot-styles/materialize-slot.d.ts.map +1 -1
  352. package/lib/typescript/shared/providers/screen/styles/hooks/slot-resolvers.d.ts +11 -0
  353. package/lib/typescript/shared/providers/screen/styles/hooks/slot-resolvers.d.ts.map +1 -0
  354. package/lib/typescript/shared/providers/screen/styles/hooks/use-interpolated-style-maps.d.ts +4 -1
  355. package/lib/typescript/shared/providers/screen/styles/hooks/use-interpolated-style-maps.d.ts.map +1 -1
  356. package/lib/typescript/shared/providers/screen/styles/hooks/use-maybe-block-visibility.d.ts +3 -3
  357. package/lib/typescript/shared/providers/screen/styles/index.d.ts +2 -1
  358. package/lib/typescript/shared/providers/screen/styles/index.d.ts.map +1 -1
  359. package/lib/typescript/shared/providers/screen/styles/slot.provider.d.ts +5 -10
  360. package/lib/typescript/shared/providers/screen/styles/slot.provider.d.ts.map +1 -1
  361. package/lib/typescript/shared/providers/screen/styles/stores/slot-references.store.d.ts +6 -0
  362. package/lib/typescript/shared/providers/screen/styles/stores/slot-references.store.d.ts.map +1 -0
  363. package/lib/typescript/shared/stores/bounds/helpers/link-pairs.helpers.d.ts +2 -0
  364. package/lib/typescript/shared/stores/bounds/helpers/link-pairs.helpers.d.ts.map +1 -1
  365. package/lib/typescript/shared/stores/bounds/internals/entries.d.ts.map +1 -1
  366. package/lib/typescript/shared/stores/bounds/internals/links.d.ts +4 -3
  367. package/lib/typescript/shared/stores/bounds/internals/links.d.ts.map +1 -1
  368. package/lib/typescript/shared/stores/bounds/internals/resolver.d.ts.map +1 -1
  369. package/lib/typescript/shared/stores/bounds/types.d.ts +9 -20
  370. package/lib/typescript/shared/stores/bounds/types.d.ts.map +1 -1
  371. package/lib/typescript/shared/stores/system.store.d.ts +1 -0
  372. package/lib/typescript/shared/stores/system.store.d.ts.map +1 -1
  373. package/lib/typescript/shared/types/animation.types.d.ts +7 -1
  374. package/lib/typescript/shared/types/animation.types.d.ts.map +1 -1
  375. package/lib/typescript/shared/types/index.d.ts +1 -1
  376. package/lib/typescript/shared/types/index.d.ts.map +1 -1
  377. package/lib/typescript/shared/types/screen.types.d.ts +99 -4
  378. package/lib/typescript/shared/types/screen.types.d.ts.map +1 -1
  379. package/lib/typescript/shared/utils/bounds/helpers/styles/compute.d.ts.map +1 -1
  380. package/lib/typescript/shared/utils/bounds/helpers/styles/local-transform.d.ts +6 -0
  381. package/lib/typescript/shared/utils/bounds/helpers/styles/local-transform.d.ts.map +1 -0
  382. package/lib/typescript/shared/utils/bounds/types/options.d.ts +2 -0
  383. package/lib/typescript/shared/utils/bounds/types/options.d.ts.map +1 -1
  384. package/package.json +1 -1
  385. package/src/component-stack/types.ts +26 -0
  386. package/src/shared/components/boundary/components/boundary-target.tsx +21 -7
  387. package/src/shared/components/boundary/create-boundary-component.tsx +92 -28
  388. package/src/shared/components/boundary/hooks/{use-boundary-presence.ts → lifecycles/use-boundary-presence.ts} +16 -5
  389. package/src/shared/components/boundary/hooks/{use-initial-destination-measurement.ts → lifecycles/use-initial-destination-measurement.ts} +40 -13
  390. package/src/shared/components/boundary/hooks/{use-initial-source-measurement.ts → lifecycles/use-initial-source-measurement.ts} +7 -9
  391. package/src/shared/components/boundary/hooks/{use-refresh-boundary.ts → lifecycles/use-refresh-boundary.ts} +6 -6
  392. package/src/shared/components/boundary/hooks/use-boundary-measurement.ts +15 -45
  393. package/src/shared/components/boundary/hooks/use-measurer.ts +9 -14
  394. package/src/shared/components/boundary/index.tsx +55 -29
  395. package/src/shared/components/boundary/portal/components/boundary-local-portal-host.tsx +66 -0
  396. package/src/shared/components/boundary/portal/components/host.tsx +20 -5
  397. package/src/shared/components/boundary/portal/components/portal-boundary-host.tsx +112 -46
  398. package/src/shared/components/boundary/portal/components/portal.tsx +263 -134
  399. package/src/shared/components/boundary/portal/hooks/use-host-measurement.ts +23 -2
  400. package/src/shared/components/boundary/portal/hooks/use-placeholder-styles.ts +55 -0
  401. package/src/shared/components/boundary/portal/stores/host-registry.store.ts +4 -51
  402. package/src/shared/components/boundary/portal/stores/portal-boundary-host.store.ts +59 -6
  403. package/src/shared/components/boundary/portal/teleport.ts +28 -3
  404. package/src/shared/components/boundary/portal/utils/has-local-slot.ts +16 -0
  405. package/src/shared/components/boundary/portal/utils/naming.ts +11 -1
  406. package/src/shared/components/boundary/portal/utils/offset-style.ts +42 -137
  407. package/src/shared/components/boundary/portal/utils/ownership.ts +371 -0
  408. package/src/shared/components/boundary/portal/utils/resolve-portal.ts +50 -0
  409. package/src/shared/components/boundary/portal/utils/shallow-equal.ts +25 -0
  410. package/src/shared/components/boundary/portal/utils/teleport-control.ts +12 -0
  411. package/src/shared/components/boundary/portal/utils/visible-host.ts +24 -0
  412. package/src/shared/components/boundary/providers/boundary-root.provider.tsx +9 -18
  413. package/src/shared/components/boundary/types.ts +9 -39
  414. package/src/shared/components/boundary/utils/destination-signals.ts +1 -32
  415. package/src/shared/components/boundary/utils/refresh-signals.ts +0 -41
  416. package/src/shared/components/boundary/utils/source-signals.ts +5 -17
  417. package/src/shared/components/masked-view.tsx +4 -0
  418. package/src/shared/components/screen-container/layers/backdrop.tsx +31 -10
  419. package/src/shared/components/screen-container/layers/content.tsx +61 -22
  420. package/src/shared/components/screen-container/layers/render-component.ts +9 -0
  421. package/src/shared/components/screen-container/layers/surface-container.tsx +5 -4
  422. package/src/shared/index.ts +9 -5
  423. package/src/shared/providers/helpers/measured-bounds-writes.ts +6 -11
  424. package/src/shared/providers/register-bounds.provider.tsx +5 -0
  425. package/src/shared/providers/screen/animation/helpers/derivations.ts +3 -0
  426. package/src/shared/providers/screen/animation/helpers/pipeline.ts +1 -0
  427. package/src/shared/providers/screen/styles/helpers/compose-slot-style.ts +129 -0
  428. package/src/shared/providers/screen/styles/helpers/normalize-slots.ts +45 -8
  429. package/src/shared/providers/screen/styles/helpers/resolve-slot-styles/index.ts +14 -2
  430. package/src/shared/providers/screen/styles/helpers/resolve-slot-styles/materialize-slot.ts +3 -0
  431. package/src/shared/providers/screen/styles/hooks/slot-resolvers.tsx +111 -0
  432. package/src/shared/providers/screen/styles/hooks/use-interpolated-style-maps.tsx +21 -3
  433. package/src/shared/providers/screen/styles/index.tsx +8 -3
  434. package/src/shared/providers/screen/styles/slot.provider.tsx +36 -54
  435. package/src/shared/providers/screen/styles/stores/slot-references.store.ts +71 -0
  436. package/src/shared/stores/bounds/helpers/link-pairs.helpers.ts +24 -1
  437. package/src/shared/stores/bounds/internals/entries.ts +13 -5
  438. package/src/shared/stores/bounds/internals/links.ts +167 -85
  439. package/src/shared/stores/bounds/internals/resolver.ts +0 -2
  440. package/src/shared/stores/bounds/types.ts +10 -22
  441. package/src/shared/stores/system.store.ts +6 -0
  442. package/src/shared/types/animation.types.ts +8 -1
  443. package/src/shared/types/index.ts +5 -0
  444. package/src/shared/types/screen.types.ts +111 -4
  445. package/src/shared/utils/bounds/helpers/styles/compute.ts +22 -124
  446. package/src/shared/utils/bounds/helpers/styles/local-transform.ts +86 -0
  447. package/src/shared/utils/bounds/types/options.ts +2 -0
  448. package/lib/commonjs/shared/components/boundary/hooks/use-boundary-presence.js.map +0 -1
  449. package/lib/commonjs/shared/components/boundary/hooks/use-initial-destination-measurement.js.map +0 -1
  450. package/lib/commonjs/shared/components/boundary/hooks/use-initial-source-measurement.js.map +0 -1
  451. package/lib/commonjs/shared/components/boundary/hooks/use-refresh-boundary.js.map +0 -1
  452. package/lib/commonjs/shared/components/boundary/portal/resolve-portal.js +0 -36
  453. package/lib/commonjs/shared/components/boundary/portal/resolve-portal.js.map +0 -1
  454. package/lib/commonjs/shared/components/boundary/portal/utils/attachment.js +0 -40
  455. package/lib/commonjs/shared/components/boundary/portal/utils/attachment.js.map +0 -1
  456. package/lib/module/shared/components/boundary/hooks/use-boundary-presence.js.map +0 -1
  457. package/lib/module/shared/components/boundary/hooks/use-initial-destination-measurement.js.map +0 -1
  458. package/lib/module/shared/components/boundary/hooks/use-initial-source-measurement.js.map +0 -1
  459. package/lib/module/shared/components/boundary/hooks/use-refresh-boundary.js.map +0 -1
  460. package/lib/module/shared/components/boundary/portal/resolve-portal.js +0 -31
  461. package/lib/module/shared/components/boundary/portal/resolve-portal.js.map +0 -1
  462. package/lib/module/shared/components/boundary/portal/utils/attachment.js +0 -35
  463. package/lib/module/shared/components/boundary/portal/utils/attachment.js.map +0 -1
  464. package/lib/typescript/shared/components/boundary/hooks/use-boundary-presence.d.ts +0 -9
  465. package/lib/typescript/shared/components/boundary/hooks/use-boundary-presence.d.ts.map +0 -1
  466. package/lib/typescript/shared/components/boundary/hooks/use-initial-destination-measurement.d.ts.map +0 -1
  467. package/lib/typescript/shared/components/boundary/hooks/use-initial-source-measurement.d.ts +0 -9
  468. package/lib/typescript/shared/components/boundary/hooks/use-initial-source-measurement.d.ts.map +0 -1
  469. package/lib/typescript/shared/components/boundary/hooks/use-refresh-boundary.d.ts.map +0 -1
  470. package/lib/typescript/shared/components/boundary/portal/resolve-portal.d.ts +0 -14
  471. package/lib/typescript/shared/components/boundary/portal/resolve-portal.d.ts.map +0 -1
  472. package/lib/typescript/shared/components/boundary/portal/utils/attachment.d.ts +0 -21
  473. package/lib/typescript/shared/components/boundary/portal/utils/attachment.d.ts.map +0 -1
  474. package/src/shared/components/boundary/portal/resolve-portal.ts +0 -40
  475. package/src/shared/components/boundary/portal/utils/attachment.ts +0 -48
@@ -6,7 +6,8 @@ Object.defineProperty(exports, "__esModule", {
6
6
  exports.BoundaryTarget = void 0;
7
7
  var _react = require("react");
8
8
  var _reactNativeReanimated = _interopRequireWildcard(require("react-native-reanimated"));
9
- var _styles = require("../../../utils/bounds/helpers/styles/styles");
9
+ var _styles = require("../../../providers/screen/styles");
10
+ var _styles2 = require("../../../utils/bounds/helpers/styles/styles");
10
11
  var _logger = require("../../../utils/logger");
11
12
  var _portal = require("../portal/components/portal");
12
13
  var _boundaryRoot = require("../providers/boundary-root.provider");
@@ -23,12 +24,15 @@ const BoundaryTarget = exports.BoundaryTarget = /*#__PURE__*/(0, _react.memo)(fu
23
24
  const registerTargetRef = rootContext?.registerTargetRef;
24
25
  const unregisterTargetRef = rootContext?.unregisterTargetRef;
25
26
  const isActiveTarget = rootContext?.activeTargetRef === targetAnimatedRef;
26
- const preparedStyles = (0, _react.useMemo)(() => (0, _styles.prepareStyleForBounds)(style), [style]);
27
- // Portal'd content can be teleported into another screen's host; measuring
28
- // it there would capture its CURRENT (destination) position as the source
29
- // bounds. The portal placeholder keeps the layout slot at home, so it is
30
- // the truthful measurement surface whenever a portal is configured.
31
- const measurementRef = rootContext?.portal ? placeholderAnimatedRef : targetAnimatedRef;
27
+ const portalRuntime = rootContext?.portalRuntime;
28
+ const shouldApplyAssociatedStyleInline = isActiveTarget && portalRuntime?.enabled !== true;
29
+ const shouldApplyPortalLayoutStyle = isActiveTarget && portalRuntime?.enabled === true;
30
+ const associatedTargetStyles = (0, _styles.useComposedSlotStyles)(rootContext?.boundTag.tag, style);
31
+ const portalLayoutStyle = (0, _styles.useSlotLayoutStyles)(rootContext?.boundTag.tag);
32
+ const preparedStyles = (0, _react.useMemo)(() => (0, _styles2.prepareStyleForBounds)(style), [style]);
33
+ // Teleported content can render outside its layout slot. The placeholder is
34
+ // the truthful measurement surface whenever runtime portal behavior is active.
35
+ const measurementRef = portalRuntime?.enabled ? placeholderAnimatedRef : targetAnimatedRef;
32
36
  (0, _react.useLayoutEffect)(() => {
33
37
  if (!registerTargetRef || !unregisterTargetRef) {
34
38
  if (__DEV__) {
@@ -43,12 +47,13 @@ const BoundaryTarget = exports.BoundaryTarget = /*#__PURE__*/(0, _react.memo)(fu
43
47
  }, [registerTargetRef, unregisterTargetRef, targetAnimatedRef, preparedStyles, measurementRef]);
44
48
  return /*#__PURE__*/(0, _jsxRuntime.jsx)(_portal.Portal, {
45
49
  id: rootContext?.boundTag.tag,
46
- mode: rootContext?.portal,
50
+ handoff: portalRuntime?.handoff,
51
+ escapeClipping: portalRuntime?.escapeClipping,
47
52
  placeholderRef: placeholderAnimatedRef,
48
53
  children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeReanimated.default.View, {
49
54
  ...rest,
50
55
  ref: targetAnimatedRef,
51
- style: [style, isActiveTarget ? rootContext.associatedTargetStyles : undefined],
56
+ style: [style, shouldApplyAssociatedStyleInline ? associatedTargetStyles : undefined, shouldApplyPortalLayoutStyle ? portalLayoutStyle : undefined],
52
57
  collapsable: false
53
58
  })
54
59
  });
@@ -1 +1 @@
1
- {"version":3,"names":["_react","require","_reactNativeReanimated","_interopRequireWildcard","_styles","_logger","_portal","_boundaryRoot","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","BoundaryTarget","exports","memo","props","style","rest","targetAnimatedRef","useAnimatedRef","placeholderAnimatedRef","rootContext","useBoundaryRootContext","registerTargetRef","unregisterTargetRef","isActiveTarget","activeTargetRef","preparedStyles","useMemo","prepareStyleForBounds","measurementRef","portal","useLayoutEffect","__DEV__","logger","warn","TARGET_OUTSIDE_ROOT_WARNING","jsx","Portal","id","boundTag","tag","mode","placeholderRef","children","View","ref","associatedTargetStyles","undefined","collapsable"],"sourceRoot":"../../../../../../src","sources":["shared/components/boundary/components/boundary-target.tsx"],"mappings":";;;;;;AACA,IAAAA,MAAA,GAAAC,OAAA;AAEA,IAAAC,sBAAA,GAAAC,uBAAA,CAAAF,OAAA;AACA,IAAAG,OAAA,GAAAH,OAAA;AACA,IAAAI,OAAA,GAAAJ,OAAA;AACA,IAAAK,OAAA,GAAAL,OAAA;AACA,IAAAM,aAAA,GAAAN,OAAA;AAG6C,IAAAO,WAAA,GAAAP,OAAA;AAAA,SAAAE,wBAAAM,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CA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CAAC;AAEX,CAAC,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["_react","require","_reactNativeReanimated","_interopRequireWildcard","_styles","_styles2","_logger","_portal","_boundaryRoot","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","BoundaryTarget","exports","memo","props","style","rest","targetAnimatedRef","useAnimatedRef","placeholderAnimatedRef","rootContext","useBoundaryRootContext","registerTargetRef","unregisterTargetRef","isActiveTarget","activeTargetRef","portalRuntime","shouldApplyAssociatedStyleInline","enabled","shouldApplyPortalLayoutStyle","associatedTargetStyles","useComposedSlotStyles","boundTag","tag","portalLayoutStyle","useSlotLayoutStyles","preparedStyles","useMemo","prepareStyleForBounds","measurementRef","useLayoutEffect","__DEV__","logger","warn","TARGET_OUTSIDE_ROOT_WARNING","jsx","Portal","id","handoff","escapeClipping","placeholderRef","children","View","ref","undefined","collapsable"],"sourceRoot":"../../../../../../src","sources":["shared/components/boundary/components/boundary-target.tsx"],"mappings":";;;;;;AACA,IAAAA,MAAA,GAAAC,OAAA;AAEA,IAAAC,sBAAA,GAAAC,uBAAA,CAAAF,OAAA;AACA,IAAAG,OAAA,GAAAH,OAAA;AAIA,IAAAI,QAAA,GAAAJ,OAAA;AACA,IAAAK,OAAA,GAAAL,OAAA;AACA,IAAAM,OAAA,GAAAN,OAAA;AACA,IAAAO,aAAA,GAAAP,OAAA;AAG6C,IAAAQ,WAAA,GAAAR,OAAA;AAAA,SAAAE,wBAAAO,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAT,uBAAA,YAAAA,CAAAO,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,EAAAV,CA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AACkD,IAAI;MAAA,GACTpC,IAAI;MACRqC,GAAG,EAAEpC,iBAAkB;MACvBF,KAAK,EAAE,CACNA,KAAK,EACLY,gCAAgC,GAAGG,sBAAsB,GAAGwB,SAAS,EACrEzB,4BAA4B,GAAGK,iBAAiB,GAAGoB,SAAS,CAC3D;MACFC,WAAW,EAAE;IAAM,CACnB;EAAC,CACK,CAAC;AAEX,CAAC,CAAC","ignoreList":[]}
@@ -5,19 +5,29 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.createBoundaryComponent = createBoundaryComponent;
7
7
  var _react = require("react");
8
- var _reactNativeReanimated = _interopRequireDefault(require("react-native-reanimated"));
8
+ var _reactNativeReanimated = _interopRequireWildcard(require("react-native-reanimated"));
9
9
  var _descriptors = require("../../providers/screen/descriptors");
10
10
  var _styles = require("../../providers/screen/styles");
11
11
  var _linkPairs = require("../../stores/bounds/helpers/link-pairs.helpers");
12
12
  var _useBoundaryMeasurement = require("./hooks/use-boundary-measurement");
13
- var _resolvePortal = require("./portal/resolve-portal");
13
+ var _boundaryLocalPortalHost = require("./portal/components/boundary-local-portal-host");
14
+ var _portal = require("./portal/components/portal");
15
+ var _resolvePortal = require("./portal/utils/resolve-portal");
14
16
  var _boundaryRoot = require("./providers/boundary-root.provider");
15
17
  var _jsxRuntime = require("react/jsx-runtime");
16
- function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
18
+ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
19
+ const hasRenderableChildren = children => {
20
+ if (children === null || children === undefined || typeof children === "boolean") {
21
+ return false;
22
+ }
23
+ if (Array.isArray(children)) {
24
+ return children.some(hasRenderableChildren);
25
+ }
26
+ return true;
27
+ };
17
28
  function createBoundaryComponent(Wrapped, options = {}) {
18
29
  const {
19
- alreadyAnimated = false,
20
- shouldAutoMeasure = false
30
+ alreadyAnimated = false
21
31
  } = options;
22
32
  const AnimatedComponent = alreadyAnimated ? Wrapped : _reactNativeReanimated.default.createAnimatedComponent(Wrapped);
23
33
  const Inner = /*#__PURE__*/(0, _react.forwardRef)((props, forwardedRef) => {
@@ -31,19 +41,26 @@ function createBoundaryComponent(Wrapped, options = {}) {
31
41
  method,
32
42
  style,
33
43
  onPress,
34
- portal: portalProp,
44
+ handoff,
45
+ escapeClipping,
46
+ children,
35
47
  ...rest
36
48
  } = props;
37
49
  const boundTag = (0, _react.useMemo)(() => (0, _linkPairs.createBoundTag)(String(id), group), [id, group]);
38
- const portal = (0, _resolvePortal.resolveBoundaryPortal)(portalProp);
50
+ const portalRuntime = (0, _resolvePortal.resolveBoundaryPortal)({
51
+ handoff,
52
+ escapeClipping
53
+ });
39
54
  const currentScreenKey = (0, _descriptors.useDescriptorsStore)(s => s.derivations.currentScreenKey);
40
55
  const hasConfiguredInterpolator = (0, _descriptors.useDescriptorsStore)(s => s.derivations.hasConfiguredInterpolator);
41
56
  const runtimeEnabled = enabled && hasConfiguredInterpolator;
42
57
  // Associated slot styles attach whenever the boundary is enabled,
43
58
  // independent of whether an interpolator is configured for this transition.
44
59
  const shouldAttachAssociatedStyles = enabled;
45
- const associatedStyles = (0, _styles.useSlotStyles)(boundTag.tag);
60
+ const canPortalRoot = portalRuntime.enabled && hasRenderableChildren(children);
61
+ const associatedStyles = (0, _styles.useComposedSlotStyles)(boundTag.tag, style);
46
62
  const associatedStackingStyles = (0, _styles.useSlotStackingStyles)(boundTag.tag);
63
+ const rootPlaceholderRef = (0, _reactNativeReanimated.useAnimatedRef)();
47
64
  const {
48
65
  ref,
49
66
  contextValue,
@@ -52,12 +69,10 @@ function createBoundaryComponent(Wrapped, options = {}) {
52
69
  targetPreparedStyles
53
70
  } = (0, _boundaryRoot.useBoundaryRootState)({
54
71
  boundTag,
55
- portal,
56
- associatedTargetStyles: shouldAttachAssociatedStyles ? associatedStyles : undefined
72
+ portalRuntime,
73
+ rootMeasurementRef: canPortalRoot ? rootPlaceholderRef : undefined
57
74
  });
58
- const {
59
- onPress: resolvedOnPress
60
- } = (0, _useBoundaryMeasurement.useBoundaryMeasurement)({
75
+ (0, _useBoundaryMeasurement.useBoundaryMeasurement)({
61
76
  boundTag,
62
77
  enabled,
63
78
  runtimeEnabled,
@@ -65,35 +80,58 @@ function createBoundaryComponent(Wrapped, options = {}) {
65
80
  measuredRef,
66
81
  style,
67
82
  targetPreparedStyles,
68
- portal,
69
- shouldAutoMeasure,
83
+ handoff: portalRuntime.handoff,
84
+ escapeClipping: portalRuntime.escapeClipping,
70
85
  config: {
71
86
  anchor,
72
87
  scaleMode,
73
88
  target,
74
89
  method
75
- },
76
- onPress
90
+ }
77
91
  });
78
92
  (0, _react.useImperativeHandle)(forwardedRef, () => ref.current, [ref]);
79
-
93
+ const shouldPortalRoot = canPortalRoot && !hasActiveTarget;
80
94
  // A nested active target takes the full associated style, so the root keeps
81
- // only its stacking context; otherwise the root wears the full style.
82
- const attachedStyle = shouldAttachAssociatedStyles ? hasActiveTarget ? associatedStackingStyles : associatedStyles : undefined;
95
+ // only its stacking context. Without a nested target, a portal'd root is the
96
+ // target, so its associated style is applied through the portal host instead
97
+ // of inline on the teleported element.
98
+ // Host-only handoff receivers still need the associated style: their local
99
+ // portal host is absolute-filled inside this root, so the root is the visual
100
+ // frame that animates the received payload.
101
+ const attachedStyle = shouldAttachAssociatedStyles ? hasActiveTarget ? associatedStackingStyles : shouldPortalRoot ? undefined : associatedStyles : undefined;
102
+ const pressProps = typeof onPress === "function" ? {
103
+ onPress
104
+ } : undefined;
105
+ const localPortalHost = /*#__PURE__*/(0, _jsxRuntime.jsx)(_boundaryLocalPortalHost.BoundaryLocalPortalHost, {
106
+ boundaryId: boundTag.tag,
107
+ enabled: enabled && portalRuntime.handoff,
108
+ screenKey: currentScreenKey
109
+ });
110
+ const canInjectLocalPortalHost = typeof children !== "function";
111
+ const renderBoundaryRoot = extraChildren => /*#__PURE__*/(0, _jsxRuntime.jsxs)(AnimatedComponent, {
112
+ ...rest,
113
+ ...pressProps,
114
+ ref: ref,
115
+ style: [style, attachedStyle],
116
+ collapsable: false,
117
+ children: [children, canInjectLocalPortalHost ? extraChildren : null]
118
+ });
119
+ const boundaryRoot = renderBoundaryRoot(shouldPortalRoot ? undefined : localPortalHost);
83
120
  return /*#__PURE__*/(0, _jsxRuntime.jsx)(_boundaryRoot.BoundaryRootProvider, {
84
121
  value: contextValue,
85
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(AnimatedComponent, {
86
- ...rest,
87
- ref: ref,
88
- style: [style, attachedStyle],
89
- onPress: resolvedOnPress,
90
- collapsable: false
91
- })
122
+ children: shouldPortalRoot ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_portal.Portal, {
123
+ id: boundTag.tag,
124
+ handoff: portalRuntime.handoff,
125
+ escapeClipping: portalRuntime.escapeClipping,
126
+ placeholderRef: rootPlaceholderRef,
127
+ placeholderChildren: portalRuntime.handoff ? localPortalHost : undefined,
128
+ children: boundaryRoot
129
+ }) : boundaryRoot
92
130
  });
93
131
  });
94
132
 
95
133
  // The HOC's runtime identity (animated + memoized forwardRef) is not
96
134
  // expressible against the public boundary props, so assert it here.
97
- return /*#__PURE__*/(0, _react.memo)(_reactNativeReanimated.default.createAnimatedComponent(Inner));
135
+ return /*#__PURE__*/(0, _react.memo)(Inner);
98
136
  }
99
137
  //# sourceMappingURL=create-boundary-component.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["_react","require","_reactNativeReanimated","_interopRequireDefault","_descriptors","_styles","_linkPairs","_useBoundaryMeasurement","_resolvePortal","_boundaryRoot","_jsxRuntime","e","__esModule","default","createBoundaryComponent","Wrapped","options","alreadyAnimated","shouldAutoMeasure","AnimatedComponent","Animated","createAnimatedComponent","Inner","forwardRef","props","forwardedRef","enabled","group","id","anchor","scaleMode","target","method","style","onPress","portal","portalProp","rest","boundTag","useMemo","createBoundTag","String","resolveBoundaryPortal","currentScreenKey","useDescriptorsStore","s","derivations","hasConfiguredInterpolator","runtimeEnabled","shouldAttachAssociatedStyles","associatedStyles","useSlotStyles","tag","associatedStackingStyles","useSlotStackingStyles","ref","contextValue","measuredRef","hasActiveTarget","targetPreparedStyles","useBoundaryRootState","associatedTargetStyles","undefined","resolvedOnPress","useBoundaryMeasurement","config","useImperativeHandle","current","attachedStyle","jsx","BoundaryRootProvider","value","children","collapsable","memo"],"sourceRoot":"../../../../../src","sources":["shared/components/boundary/create-boundary-component.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AAOA,IAAAC,sBAAA,GAAAC,sBAAA,CAAAF,OAAA;AACA,IAAAG,YAAA,GAAAH,OAAA;AACA,IAAAI,OAAA,GAAAJ,OAAA;AAIA,IAAAK,UAAA,GAAAL,OAAA;AACA,IAAAM,uBAAA,GAAAN,OAAA;AACA,IAAAO,cAAA,GAAAP,OAAA;AACA,IAAAQ,aAAA,GAAAR,OAAA;AAG4C,IAAAS,WAAA,GAAAT,OAAA;AAAA,SAAAE,uBAAAQ,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAQrC,SAASG,uBAAuBA,CACtCC,OAAyB,EACzBC,OAAuC,GAAG,CAAC,CAAC,EAC3C;EACD,MAAM;IAAEC,eAAe,GAAG,KAAK;IAAEC,iBAAiB,GAAG;EAAM,CAAC,GAAGF,OAAO;EACtE,MAAMG,iBAAiB,GAAGF,eAAe,GACtCF,OAAO,GACPK,8BAAQ,CAACC,uBAAuB,CAACN,OAAO,CAAC;EAE5C,MAAMO,KAAK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AAO;MACPsB,cAAc;MACdL,gBAAgB;MAChBc,WAAW;MACXxB,KAAK;MACL0B,oBAAoB;MACpBxB,MAAM;MACNjB,iBAAiB;MACjB+C,MAAM,EAAE;QAAEpC,MAAM;QAAEC,SAAS;QAAEC,MAAM;QAAEC;MAAO,CAAC;MAC7CE;IACD,CAAC,CAAC;IAEF,IAAAgC,0BAAmB,EAACzC,YAAY,EAAE,MAAM8B,GAAG,CAACY,OAAc,EAAE,CAACZ,GAAG,CAAC,CAAC;;IAElE;IACA;IACA,MAAMa,aAAa,GAAGnB,4BAA4B,GAC/CS,eAAe,GACdL,wBAAwB,GACxBH,gBAAgB,GACjBY,SAAS;IAEZ,oBACC,IAAApD,WAAA,CAAA2D,GAAA,EAAC5D,aAAA,CAAA6D,oBAAoB;MAACC,KAAK,EAAEf,YAAa;MAAAgB,QAAA,eACzC,IAAA9D,WAAA,CAAA2D,GAAA,EAAClD,iBAAiB;QAAA,GACbkB,IAAI;QACRkB,GAAG,EAAEA,GAAI;QACTtB,KAAK,EAAE,CAACA,KAAK,EAAEmC,aAAa,CAAE;QAC9BlC,OAAO,EAAE6B,eAAgB;QACzBU,WAAW,EAAE;MAAM,CACnB;IAAC,CACmB,CAAC;EAEzB,CAAC,CAAC;;EAEF;EACA;EACA,oBAAO,IAAAC,WAAI,EACVtD,8BAAQ,CAACC,uBAAuB,CAACC,KAAK,CACvC,CAAC;AAMF","ignoreList":[]}
1
+ {"version":3,"names":["_react","require","_reactNativeReanimated","_interopRequireWildcard","_descriptors","_styles","_linkPairs","_useBoundaryMeasurement","_boundaryLocalPortalHost","_portal","_resolvePortal","_boundaryRoot","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","hasRenderableChildren","children","undefined","Array","isArray","some","createBoundaryComponent","Wrapped","options","alreadyAnimated","AnimatedComponent","Animated","createAnimatedComponent","Inner","forwardRef","props","forwardedRef","enabled","group","id","anchor","scaleMode","target","method","style","onPress","handoff","escapeClipping","rest","boundTag","useMemo","createBoundTag","String","portalRuntime","resolveBoundaryPortal","currentScreenKey","useDescriptorsStore","s","derivations","hasConfiguredInterpolator","runtimeEnabled","shouldAttachAssociatedStyles","canPortalRoot","associatedStyles","useComposedSlotStyles","tag","associatedStackingStyles","useSlotStackingStyles","rootPlaceholderRef","useAnimatedRef","ref","contextValue","measuredRef","hasActiveTarget","targetPreparedStyles","useBoundaryRootState","rootMeasurementRef","useBoundaryMeasurement","config","useImperativeHandle","current","shouldPortalRoot","attachedStyle","pressProps","localPortalHost","jsx","BoundaryLocalPortalHost","boundaryId","screenKey","canInjectLocalPortalHost","renderBoundaryRoot","extraChildren","jsxs","collapsable","boundaryRoot","BoundaryRootProvider","value","Portal","placeholderRef","placeholderChildren","memo"],"sourceRoot":"../../../../../src","sources":["shared/components/boundary/create-boundary-component.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AASA,IAAAC,sBAAA,GAAAC,uBAAA,CAAAF,OAAA;AACA,IAAAG,YAAA,GAAAH,OAAA;AACA,IAAAI,OAAA,GAAAJ,OAAA;AAIA,IAAAK,UAAA,GAAAL,OAAA;AACA,IAAAM,uBAAA,GAAAN,OAAA;AACA,IAAAO,wBAAA,GAAAP,OAAA;AACA,IAAAQ,OAAA,GAAAR,OAAA;AACA,IAAAS,cAAA,GAAAT,OAAA;AACA,IAAAU,aAAA,GAAAV,OAAA;AAG4C,IAAAW,WAAA,GAAAX,OAAA;AAAA,SAAAE,wBAAAU,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAZ,uBAAA,YAAAA,CAAAU,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,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1B,KAAK,EAAE,CAACA,KAAK,EAAEsC,aAAa,CAAE;MAC9BW,WAAW,EAAE,KAAM;MAAAxE,QAAA,GAElBA,QAAQ,EACRoE,wBAAwB,GAAGE,aAAa,GAAG,IAAI;IAAA,CAC9B,CACnB;IACD,MAAMG,YAAY,GAAGJ,kBAAkB,CACtCT,gBAAgB,GAAG3D,SAAS,GAAG8D,eAChC,CAAC;IAED,oBACC,IAAApF,WAAA,CAAAqF,GAAA,EAACtF,aAAA,CAAAgG,oBAAoB;MAACC,KAAK,EAAEzB,YAAa;MAAAlD,QAAA,EACxC4D,gBAAgB,gBAChB,IAAAjF,WAAA,CAAAqF,GAAA,EAACxF,OAAA,CAAAoG,MAAM;QACN1D,EAAE,EAAEU,QAAQ,CAACgB,GAAI;QACjBnB,OAAO,EAAEO,aAAa,CAACP,OAAQ;QAC/BC,cAAc,EAAEM,aAAa,CAACN,cAAe;QAC7CmD,cAAc,EAAE9B,kBAAmB;QACnC+B,mBAAmB,EAClB9C,aAAa,CAACP,OAAO,GAAGsC,eAAe,GAAG9D,SAC1C;QAAAD,QAAA,EAEAyE;MAAY,CACN,CAAC,GAETA;IACA,CACoB,CAAC;EAEzB,CAAC,CAAC;;EAEF;EACA;EACA,oBAAO,IAAAM,WAAI,EAACnE,KAAK,CAAC;AAMnB","ignoreList":[]}
@@ -6,13 +6,15 @@ Object.defineProperty(exports, "__esModule", {
6
6
  exports.useBoundaryPresence = void 0;
7
7
  var _react = require("react");
8
8
  var _reactNativeReanimated = require("react-native-reanimated");
9
- var _entries = require("../../../stores/bounds/internals/entries");
9
+ var _entries = require("../../../../stores/bounds/internals/entries");
10
10
  const useBoundaryPresence = params => {
11
11
  const {
12
12
  enabled,
13
13
  boundTag,
14
14
  currentScreenKey,
15
- boundaryConfig
15
+ boundaryConfig,
16
+ handoff,
17
+ escapeClipping
16
18
  } = params;
17
19
  const {
18
20
  tag
@@ -20,12 +22,14 @@ const useBoundaryPresence = params => {
20
22
  (0, _react.useLayoutEffect)(() => {
21
23
  if (!enabled) return;
22
24
  (0, _reactNativeReanimated.runOnUI)(_entries.setEntry)(tag, currentScreenKey, {
23
- boundaryConfig
25
+ boundaryConfig,
26
+ handoff: handoff ? true : null,
27
+ escapeClipping: escapeClipping ? true : null
24
28
  });
25
29
  return () => {
26
30
  (0, _reactNativeReanimated.runOnUI)(_entries.removeEntry)(tag, currentScreenKey);
27
31
  };
28
- }, [enabled, tag, currentScreenKey, boundaryConfig]);
32
+ }, [enabled, tag, currentScreenKey, boundaryConfig, handoff, escapeClipping]);
29
33
  };
30
34
  exports.useBoundaryPresence = useBoundaryPresence;
31
35
  //# sourceMappingURL=use-boundary-presence.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_react","require","_reactNativeReanimated","_entries","useBoundaryPresence","params","enabled","boundTag","currentScreenKey","boundaryConfig","handoff","escapeClipping","tag","useLayoutEffect","runOnUI","setEntry","removeEntry","exports"],"sourceRoot":"../../../../../../../src","sources":["shared/components/boundary/hooks/lifecycles/use-boundary-presence.ts"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AACA,IAAAC,sBAAA,GAAAD,OAAA;AACA,IAAAE,QAAA,GAAAF,OAAA;AAOO,MAAMG,mBAAmB,GAAIC,MAOnC,IAAK;EACL,MAAM;IACLC,OAAO;IACPC,QAAQ;IACRC,gBAAgB;IAChBC,cAAc;IACdC,OAAO;IACPC;EACD,CAAC,GAAGN,MAAM;EACV,MAAM;IAAEO;EAAI,CAAC,GAAGL,QAAQ;EAExB,IAAAM,sBAAe,EAAC,MAAM;IACrB,IAAI,CAACP,OAAO,EAAE;IAEd,IAAAQ,8BAAO,EAACC,iBAAQ,CAAC,CAACH,GAAG,EAAEJ,gBAAgB,EAAE;MACxCC,cAAc;MACdC,OAAO,EAAEA,OAAO,GAAG,IAAI,GAAG,IAAI;MAC9BC,cAAc,EAAEA,cAAc,GAAG,IAAI,GAAG;IACzC,CAAC,CAAC;IAEF,OAAO,MAAM;MACZ,IAAAG,8BAAO,EAACE,oBAAW,CAAC,CAACJ,GAAG,EAAEJ,gBAAgB,CAAC;IAC5C,CAAC;EACF,CAAC,EAAE,CAACF,OAAO,EAAEM,GAAG,EAAEJ,gBAAgB,EAAEC,cAAc,EAAEC,OAAO,EAAEC,cAAc,CAAC,CAAC;AAC9E,CAAC;AAACM,OAAA,CAAAb,mBAAA,GAAAA,mBAAA","ignoreList":[]}
@@ -5,13 +5,16 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.useInitialDestinationMeasurement = void 0;
7
7
  var _reactNativeReanimated = require("react-native-reanimated");
8
- var _descriptors = require("../../../providers/screen/descriptors");
9
- var _animation = require("../../../stores/animation.store");
10
- var _links = require("../../../stores/bounds/internals/links");
11
- var _state = require("../../../stores/bounds/internals/state");
12
- var _system = require("../../../stores/system.store");
13
- var _logger = require("../../../utils/logger");
14
- var _destinationSignals = require("../utils/destination-signals");
8
+ var _descriptors = require("../../../../providers/screen/descriptors");
9
+ var _animation = require("../../../../stores/animation.store");
10
+ var _linkPairs = require("../../../../stores/bounds/helpers/link-pairs.helpers");
11
+ var _entries = require("../../../../stores/bounds/internals/entries");
12
+ var _links = require("../../../../stores/bounds/internals/links");
13
+ var _state = require("../../../../stores/bounds/internals/state");
14
+ var _system = require("../../../../stores/system.store");
15
+ var _logger = require("../../../../utils/logger");
16
+ var _ownership = require("../../portal/utils/ownership");
17
+ var _destinationSignals = require("../../utils/destination-signals");
15
18
  const VIEWPORT_RETRY_DELAY_MS = 100;
16
19
  /**
17
20
  * A destination that keeps failing its measurement guards must not hold the
@@ -25,6 +28,7 @@ const useInitialDestinationMeasurement = ({
25
28
  measureBoundary
26
29
  }) => {
27
30
  const {
31
+ tag,
28
32
  linkKey,
29
33
  group
30
34
  } = boundTag;
@@ -77,9 +81,6 @@ const useInitialDestinationMeasurement = ({
77
81
  "worklet";
78
82
 
79
83
  if (!measurePairKey) {
80
- releaseLifecycleStartBlock();
81
- viewportRetries.set(0);
82
- hasGivenUp.set(0);
83
84
  return;
84
85
  }
85
86
  const previousMeasurePairKey = previous?.[0];
@@ -101,6 +102,22 @@ const useInitialDestinationMeasurement = ({
101
102
  });
102
103
  const destinationAttached = (0, _links.getDestination)(measurePairKey, linkKey) !== null;
103
104
  if (destinationAttached) {
105
+ const linkState = _state.pairs.get();
106
+ const link = (0, _links.getLink)(measurePairKey, linkKey);
107
+ const sourceScreenKey = (0, _linkPairs.getSourceScreenKeyFromPairKey)(measurePairKey);
108
+ const sourceEntry = (0, _entries.getEntry)(tag, sourceScreenKey);
109
+ const sourceEntryUsesDestinationEscapeHost = sourceEntry?.handoff === true && sourceEntry.escapeClipping === true;
110
+ const shouldWaitForEscapeClippingHost = (0, _ownership.usesEscapeClippingHost)(link) || sourceEntryUsesDestinationEscapeHost || (0, _ownership.hasHandoffEscapeContinuation)({
111
+ linkKey,
112
+ linkState,
113
+ sourceScreenKey
114
+ });
115
+ if (shouldWaitForEscapeClippingHost) {
116
+ // Screen-level escape has a second readiness phase after destination
117
+ // measurement: the host must commit before the transition starts, or
118
+ // the payload can disappear for a frame.
119
+ return;
120
+ }
104
121
  releaseLifecycleStartBlock();
105
122
  viewportRetries.set(0);
106
123
  return;
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_reactNativeReanimated","require","_descriptors","_animation","_linkPairs","_entries","_links","_state","_system","_logger","_ownership","_destinationSignals","VIEWPORT_RETRY_DELAY_MS","MAX_VIEWPORT_RETRIES","useInitialDestinationMeasurement","boundTag","enabled","measureBoundary","tag","linkKey","group","currentScreenKey","useDescriptorsStore","s","derivations","nextScreenKey","destinationPairKey","ancestorDestinationPairKey","destinationEnabled","progress","AnimationStore","getValue","pendingLifecycleRequestKind","actions","blockLifecycleStart","unblockLifecycleStart","SystemStore","getBag","isBlockingLifecycleStart","useSharedValue","retryToken","viewportRetries","hasGivenUp","releaseLifecycleStartBlock","cancelAnimation","get","set","useAnimatedReaction","retryTick","hasPendingOpenRequest","LifecycleTransitionRequestKind","Open","isWaitingForOpenToStart","measurePairKey","getInitialDestinationMeasurePairKey","linkId","linkState","pairs","undefined","previous","previousMeasurePairKey","previousRetryTick","shouldAttemptMeasure","type","pairKey","destinationAttached","getDestination","link","getLink","sourceScreenKey","getSourceScreenKeyFromPairKey","sourceEntry","getEntry","sourceEntryUsesDestinationEscapeHost","handoff","escapeClipping","shouldWaitForEscapeClippingHost","usesEscapeClippingHost","hasHandoffEscapeContinuation","logger","warn","withDelay","withTiming","duration","exports"],"sourceRoot":"../../../../../../../src","sources":["shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.ts"],"mappings":";;;;;;AAAA,IAAAA,sBAAA,GAAAC,OAAA;AAOA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,UAAA,GAAAF,OAAA;AACA,IAAAG,UAAA,GAAAH,OAAA;AACA,IAAAI,QAAA,GAAAJ,OAAA;AACA,IAAAK,MAAA,GAAAL,OAAA;AAIA,IAAAM,MAAA,GAAAN,OAAA;AAEA,IAAAO,OAAA,GAAAP,OAAA;AAIA,IAAAQ,OAAA,GAAAR,OAAA;AACA,IAAAS,UAAA,GAAAT,OAAA;AAKA,IAAAU,mBAAA,GAAAV,OAAA;AAEA,MAAMW,uBAAuB,GAAG,GAAG;AACnC;AACA;AACA;AACA;AACA;AACA,MAAMC,oBAAoB,GAAG,EAAE;AAQxB,MAAMC,gCAAgC,GAAGA,CAAC;EAChDC,QAAQ;EACRC,OAAO;EACPC;AACuC,CAAC,KAAK;EAC7C,MAAM;IAAEC,GAAG;IAAEC,OAAO;IAAEC;EAAM,CAAC,GAAGL,QAAQ;EACxC,MAAMM,gBAAgB,GAAG,IAAAC,gCAAmB,EAC1CC,CAAC,IAAKA,CAAC,CAACC,WAAW,CAACH,gBACtB,CAAC;EACD,MAAMI,aAAa,GAAG,IAAAH,gCAAmB,EAAEC,CAAC,IAAKA,CAAC,CAACC,WAAW,CAACC,aAAa,CAAC;EAC7E,MAAMC,kBAAkB,GAAG,IAAAJ,gCAAmB,E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__esModule", {
5
5
  });
6
6
  exports.useInitialSourceMeasurement = void 0;
7
7
  var _reactNativeReanimated = require("react-native-reanimated");
8
- var _descriptors = require("../../../providers/screen/descriptors");
9
- var _state = require("../../../stores/bounds/internals/state");
10
- var _sourceSignals = require("../utils/source-signals");
8
+ var _descriptors = require("../../../../providers/screen/descriptors");
9
+ var _state = require("../../../../stores/bounds/internals/state");
10
+ var _sourceSignals = require("../../utils/source-signals");
11
11
  const useInitialSourceMeasurement = params => {
12
12
  const {
13
13
  enabled,
14
14
  measureBoundary,
15
- boundTag,
16
- shouldAutoMeasure
15
+ boundTag
17
16
  } = params;
18
17
  const sourcePairKey = (0, _descriptors.useDescriptorsStore)(s => s.derivations.sourcePairKey);
19
18
  const lastSourceCaptureSignal = (0, _reactNativeReanimated.useSharedValue)(null);
@@ -25,8 +24,7 @@ const useInitialSourceMeasurement = params => {
25
24
  sourcePairKey,
26
25
  linkId: boundTag.linkKey,
27
26
  group: boundTag.group,
28
- shouldAutoMeasure,
29
- linkState: shouldAutoMeasure && sourcePairKey ? _state.pairs.get() : undefined
27
+ linkState: sourcePairKey ? _state.pairs.get() : undefined
30
28
  });
31
29
  }, captureSignal => {
32
30
  "worklet";
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_reactNativeReanimated","require","_descriptors","_state","_sourceSignals","useInitialSourceMeasurement","params","enabled","measureBoundary","boundTag","sourcePairKey","useDescriptorsStore","s","derivations","lastSourceCaptureSignal","useSharedValue","useAnimatedReaction","getInitialSourceCaptureSignal","linkId","linkKey","group","linkState","pairs","get","undefined","captureSignal","set","signal","type","pairKey","exports"],"sourceRoot":"../../../../../../../src","sources":["shared/components/boundary/hooks/lifecycles/use-initial-source-measurement.ts"],"mappings":";;;;;;AAAA,IAAAA,sBAAA,GAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,MAAA,GAAAF,OAAA;AAGA,IAAAG,cAAA,GAAAH,OAAA;AAEO,MAAMI,2BAA2B,GAAIC,MAI3C,IAAK;EACL,MAAM;IAAEC,OAAO;IAAEC,eAAe;IAAEC;EAAS,CAAC,GAAGH,MAAM;EACrD,MAAMI,aAAa,GAAG,IAAAC,gCAAmB,EAAEC,CAAC,IAAKA,CAAC,CAACC,WAAW,CAACH,aAAa,CAAC;EAC7E,MAAMI,uBAAuB,GAAG,IAAAC,qCAAc,EAAgB,IAAI,CAAC;EAEnE,IAAAC,0CAAmB,EAClB,MAAM;IACL,SAAS;;IACT,OAAO,IAAAC,4CAA6B,EAAC;MACpCV,OAAO;MACPG,aAAa;MACbQ,MAAM,EAAET,QAAQ,CAACU,OAAO;MACxBC,KAAK,EAAEX,QAAQ,CAACW,KAAK;MACrBC,SAAS,EAAEX,aAAa,GAAGY,YAAK,CAACC,GAAG,CAAC,CAAC,GAAGC;IAC1C,CAAC,CAAC;EACH,CAAC,EACAC,aAAa,IAAK;IAClB,SAAS;;IACT,IAAI,CAAClB,OAAO,IAAI,CAACkB,aAAa,EAAE;MAC/BX,uBAAuB,CAACY,GAAG,CAAC,IAAI,CAAC;MACjC;IACD;IAEA,IAAIZ,uBAAuB,CAACS,GAAG,CAAC,CAAC,KAAKE,aAAa,CAACE,MAAM,EAAE;MAC3D;IACD;IAEAb,uBAAuB,CAACY,GAAG,CAACD,aAAa,CAACE,MAAM,CAAC;IACjDnB,eAAe,CAAC;MACfoB,IAAI,EAAE,QAAQ;MACdC,OAAO,EAAEJ,aAAa,CAACI;IACxB,CAAC,CAAC;EACH,CACD,CAAC;AACF,CAAC;AAACC,OAAA,CAAAzB,2BAAA,GAAAA,2BAAA","ignoreList":[]}
@@ -5,10 +5,10 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.useRefreshBoundary = void 0;
7
7
  var _reactNativeReanimated = require("react-native-reanimated");
8
- var _descriptors = require("../../../providers/screen/descriptors");
9
- var _animation = require("../../../stores/animation.store");
10
- var _state = require("../../../stores/bounds/internals/state");
11
- var _refreshSignals = require("../utils/refresh-signals");
8
+ var _descriptors = require("../../../../providers/screen/descriptors");
9
+ var _animation = require("../../../../stores/animation.store");
10
+ var _state = require("../../../../stores/bounds/internals/state");
11
+ var _refreshSignals = require("../../utils/refresh-signals");
12
12
  const useRefreshBoundary = ({
13
13
  enabled,
14
14
  boundTag,
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_reactNativeReanimated","require","_descriptors","_animation","_state","_refreshSignals","useRefreshBoundary","enabled","boundTag","measureBoundary","linkKey","group","currentScreenKey","useDescriptorsStore","s","derivations","nextScreenKey","sourcePairKey","destinationPairKey","ancestorDestinationPairKey","refreshScreenKey","refreshWillAnimate","AnimationStore","getValue","refreshClosing","refreshEntering","refreshAnimating","refreshProgress","useAnimatedReaction","getRefreshBoundarySignal","linkId","shouldRefresh","get","closing","entering","animating","progress","linkState","pairs","refreshSignal","prevRefreshSignal","signal","type","pairKey","exports"],"sourceRoot":"../../../../../../../src","sources":["shared/components/boundary/hooks/lifecycles/use-refresh-boundary.ts"],"mappings":";;;;;;AAAA,IAAAA,sBAAA,GAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,UAAA,GAAAF,OAAA;AACA,IAAAG,MAAA,GAAAH,OAAA;AAGA,IAAAI,eAAA,GAAAJ,OAAA;AAQO,MAAMK,kBAAkB,GAAGA,CAAC;EAClCC,OAAO;EACPC,QAAQ;EACRC;AACyB,CAAC,KAAK;EAC/B,MAAM;IAAEC,OAAO;IAAEC;EAAM,CAAC,GAAGH,QAAQ;EACnC,MAAMI,gBAAgB,GAAG,IAAAC,gCAAmB,EAC1CC,CAAC,IAAKA,CAAC,CAACC,WAAW,CAACH,gBACtB,CAAC;EACD,MAAMI,aAAa,GAAG,IAAAH,gCAAmB,EAAEC,CAAC,IAAKA,CAAC,CAACC,WAAW,CAACC,aAAa,CAAC;EAC7E,MAAMC,aAAa,GAAG,IAAAJ,gCAAmB,EAAEC,CAAC,IAAKA,CAAC,CAACC,WAAW,CAACE,aAAa,CAAC;EAC7E,MAA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AC;EACH,CAAC,EACD,CAACO,aAAa,EAAEC,iBAAiB,KAAK;IACrC,SAAS;;IAET,IACC,CAACD,aAAa,IACdA,aAAa,CAACE,MAAM,KAAKD,iBAAiB,EAAEC,MAAM,EACjD;MACD;IACD;IAEAhC,eAAe,CAAC;MACfiC,IAAI,EAAEH,aAAa,CAACG,IAAI;MACxBC,OAAO,EAAEJ,aAAa,CAACI;IACxB,CAAC,CAAC;EACH,CACD,CAAC;AACF,CAAC;AAACC,OAAA,CAAAtC,kBAAA,GAAAA,kBAAA","ignoreList":[]}
@@ -5,20 +5,16 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.useBoundaryMeasurement = void 0;
7
7
  var _react = require("react");
8
- var _reactNativeReanimated = require("react-native-reanimated");
9
- var _linkPairs = require("../../../stores/bounds/helpers/link-pairs.helpers");
10
8
  var _styles = require("../../../utils/bounds/helpers/styles/styles");
11
- var _resolvePortal = require("../portal/resolve-portal");
12
- var _useBoundaryPresence = require("./use-boundary-presence");
13
- var _useInitialDestinationMeasurement = require("./use-initial-destination-measurement");
14
- var _useInitialSourceMeasurement = require("./use-initial-source-measurement");
9
+ var _useBoundaryPresence = require("./lifecycles/use-boundary-presence");
10
+ var _useInitialDestinationMeasurement = require("./lifecycles/use-initial-destination-measurement");
11
+ var _useInitialSourceMeasurement = require("./lifecycles/use-initial-source-measurement");
12
+ var _useRefreshBoundary = require("./lifecycles/use-refresh-boundary");
15
13
  var _useMeasurer = require("./use-measurer");
16
- var _useRefreshBoundary = require("./use-refresh-boundary");
17
14
  /**
18
15
  * Owns the full measurement lifecycle for a boundary: builds the measurer,
19
16
  * registers presence, runs the initial source/destination + refresh reactions,
20
- * and returns the press-priority `onPress`. The component never touches the
21
- * measurer itself.
17
+ * and keeps the component itself away from the measurer.
22
18
  */
23
19
  const useBoundaryMeasurement = ({
24
20
  boundTag,
@@ -28,10 +24,9 @@ const useBoundaryMeasurement = ({
28
24
  measuredRef,
29
25
  style,
30
26
  targetPreparedStyles,
31
- portal,
32
- shouldAutoMeasure,
33
- config,
34
- onPress
27
+ handoff,
28
+ escapeClipping,
29
+ config
35
30
  }) => {
36
31
  const {
37
32
  anchor,
@@ -47,14 +42,14 @@ const useBoundaryMeasurement = ({
47
42
  }), [anchor, scaleMode, target, method]);
48
43
  const rootPreparedStyles = (0, _react.useMemo)(() => (0, _styles.prepareStyleForBounds)(style), [style]);
49
44
  const preparedStyles = targetPreparedStyles ?? rootPreparedStyles;
50
- const portalHost = (0, _resolvePortal.resolvePortalHost)(portal);
51
45
  const measureBoundary = (0, _useMeasurer.useMeasurer)({
52
46
  enabled,
53
47
  boundTag,
54
48
  currentScreenKey,
55
49
  preparedStyles,
56
50
  measuredAnimatedRef: measuredRef,
57
- portalHost
51
+ handoff,
52
+ escapeClipping
58
53
  });
59
54
 
60
55
  // Register/unregister this boundary in the presence map so source/destination
@@ -63,17 +58,14 @@ const useBoundaryMeasurement = ({
63
58
  enabled: runtimeEnabled,
64
59
  boundTag,
65
60
  currentScreenKey,
66
- boundaryConfig
61
+ boundaryConfig,
62
+ handoff,
63
+ escapeClipping
67
64
  });
68
-
69
- // Passive auto-measurement only applies to non-pressable boundaries; pressable
70
- // ones capture their source on press (see handlePress below).
71
- const shouldPassivelyMeasureSource = shouldAutoMeasure && typeof onPress !== "function";
72
65
  (0, _useInitialSourceMeasurement.useInitialSourceMeasurement)({
73
66
  enabled: runtimeEnabled,
74
67
  measureBoundary,
75
- boundTag,
76
- shouldAutoMeasure: shouldPassivelyMeasureSource
68
+ boundTag
77
69
  });
78
70
  (0, _useInitialDestinationMeasurement.useInitialDestinationMeasurement)({
79
71
  boundTag,
@@ -85,19 +77,6 @@ const useBoundaryMeasurement = ({
85
77
  boundTag,
86
78
  measureBoundary
87
79
  });
88
- const handlePress = (0, _react.useCallback)((...args) => {
89
- // Press path has priority: capture source before user onPress/navigation.
90
- (0, _reactNativeReanimated.runOnUI)(measureBoundary)({
91
- type: "source",
92
- pairKey: (0, _linkPairs.createPendingPairKey)(currentScreenKey)
93
- });
94
- if (typeof onPress === "function") {
95
- onPress(...args);
96
- }
97
- }, [measureBoundary, onPress, currentScreenKey]);
98
- return {
99
- onPress: typeof onPress === "function" ? handlePress : undefined
100
- };
101
80
  };
102
81
  exports.useBoundaryMeasurement = useBoundaryMeasurement;
103
82
  //# sourceMappingURL=use-boundary-measurement.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["_react","require","_reactNativeReanimated","_linkPairs","_styles","_resolvePortal","_useBoundaryPresence","_useInitialDestinationMeasurement","_useInitialSourceMeasurement","_useMeasurer","_useRefreshBoundary","useBoundaryMeasurement","boundTag","enabled","runtimeEnabled","currentScreenKey","measuredRef","style","targetPreparedStyles","portal","shouldAutoMeasure","config","onPress","anchor","scaleMode","target","method","boundaryConfig","useMemo","rootPreparedStyles","prepareStyleForBounds","preparedStyles","portalHost","resolvePortalHost","measureBoundary","useMeasurer","measuredAnimatedRef","useBoundaryPresence","shouldPassivelyMeasureSource","useInitialSourceMeasurement","useInitialDestinationMeasurement","useRefreshBoundary","handlePress","useCallback","args","runOnUI","type","pairKey","createPendingPairKey","undefined","exports"],"sourceRoot":"../../../../../../src","sources":["shared/components/boundary/hooks/use-boundary-measurement.ts"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AAGA,IAAAC,sBAAA,GAAAD,OAAA;AACA,IAAAE,UAAA,GAAAF,OAAA;AAEA,IAAAG,OAAA,GAAAH,OAAA;AACA,IAAAI,cAAA,GAAAJ,OAAA;AAEA,IAAAK,oBAAA,GAAAL,OAAA;AACA,IAAAM,iCAAA,GAAAN,OAAA;AACA,IAAAO,4BAAA,GAAAP,OAAA;AACA,IAAAQ,YAAA,GAAAR,OAAA;AACA,IAAAS,mBAAA,GAAAT,OAAA;AAoBA;AACA;AACA;AACA;AACA;AACA;AACO,MAAMU,sBAAsB,GAAGA,CAAC;EACtCC,QAAQ;EACRC,OAAO;EACPC,cAAc;EACdC,gBAAgB;EAChBC,WAAW;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AQ;IACRsB;EACD,CAAC,CAAC;EAEF,MAAMQ,WAAW,GAAG,IAAAC,kBAAW,EAC9B,CAAC,GAAGC,IAAe,KAAK;IACvB;IACA,IAAAC,8BAAO,EAACX,eAAe,CAAC,CAAC;MACxBY,IAAI,EAAE,QAAQ;MACdC,OAAO,EAAE,IAAAC,+BAAoB,EAACjC,gBAAgB;IAC/C,CAAC,CAAC;IAEF,IAAI,OAAOO,OAAO,KAAK,UAAU,EAAE;MAClCA,OAAO,CAAC,GAAGsB,IAAI,CAAC;IACjB;EACD,CAAC,EACD,CAACV,eAAe,EAAEZ,OAAO,EAAEP,gBAAgB,CAC5C,CAAC;EAED,OAAO;IACNO,OAAO,EAAE,OAAOA,OAAO,KAAK,UAAU,GAAGoB,WAAW,GAAGO;EACxD,CAAC;AACF,CAAC;AAACC,OAAA,CAAAvC,sBAAA,GAAAA,sBAAA","ignoreList":[]}
1
+ {"version":3,"names":["_react","require","_styles","_useBoundaryPresence","_useInitialDestinationMeasurement","_useInitialSourceMeasurement","_useRefreshBoundary","_useMeasurer","useBoundaryMeasurement","boundTag","enabled","runtimeEnabled","currentScreenKey","measuredRef","style","targetPreparedStyles","handoff","escapeClipping","config","anchor","scaleMode","target","method","boundaryConfig","useMemo","rootPreparedStyles","prepareStyleForBounds","preparedStyles","measureBoundary","useMeasurer","measuredAnimatedRef","useBoundaryPresence","useInitialSourceMeasurement","useInitialDestinationMeasurement","useRefreshBoundary","exports"],"sourceRoot":"../../../../../../src","sources":["shared/components/boundary/hooks/use-boundary-measurement.ts"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AAIA,IAAAC,OAAA,GAAAD,OAAA;AAEA,IAAAE,oBAAA,GAAAF,OAAA;AACA,IAAAG,iCAAA,GAAAH,OAAA;AACA,IAAAI,4BAAA,GAAAJ,OAAA;AACA,IAAAK,mBAAA,GAAAL,OAAA;AACA,IAAAM,YAAA,GAAAN,OAAA;AAmBA;AACA;AACA;AACA;AACA;AACO,MA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B,sBAAA,GAAAA,sBAAA","ignoreList":[]}
@@ -11,7 +11,6 @@ var _measuredBoundsWrites = require("../../../providers/helpers/measured-bounds-
11
11
  var _origin = require("../../../providers/screen/origin.provider");
12
12
  var _scroll = require("../../../stores/scroll.store");
13
13
  var _system = require("../../../stores/system.store");
14
- var _hostRegistry = require("../portal/stores/host-registry.store");
15
14
  var _measuredBounds = require("../utils/measured-bounds");
16
15
  const useMeasurer = ({
17
16
  enabled,
@@ -19,7 +18,8 @@ const useMeasurer = ({
19
18
  currentScreenKey,
20
19
  preparedStyles,
21
20
  measuredAnimatedRef,
22
- portalHost
21
+ handoff,
22
+ escapeClipping
23
23
  }) => {
24
24
  const {
25
25
  width: viewportWidth,
@@ -51,7 +51,6 @@ const useMeasurer = ({
51
51
  const viewportAllowsDestinationWrite = target.type !== "destination" || !shouldGuardDestinationViewport || (0, _measuredBounds.isMeasurementInViewport)(normalizedMeasured, viewportWidth, viewportHeight);
52
52
  if (!viewportAllowsDestinationWrite) return;
53
53
  const measuredWithScroll = (0, _measuredBounds.attachScrollSnapshotToMeasuredBounds)(normalizedMeasured, scrollMetadata.get());
54
- const sourceHost = target.type === "source" ? (0, _hostRegistry.getActiveScrollHost)(currentScreenKey) ?? undefined : undefined;
55
54
  (0, _measuredBoundsWrites.applyMeasuredBoundsWrites)({
56
55
  entryTag: boundTag.tag,
57
56
  linkId: boundTag.linkKey,
@@ -60,10 +59,10 @@ const useMeasurer = ({
60
59
  measured: measuredWithScroll,
61
60
  preparedStyles,
62
61
  linkWrite: target,
63
- portalHost,
64
- sourceHost
62
+ handoff,
63
+ escapeClipping
65
64
  });
66
- }, [enabled, boundTag, currentScreenKey, preparedStyles, measuredAnimatedRef, portalHost, viewportWidth, viewportHeight, scrollState, scrollMetadata, pendingLifecycleStartBlockCount, originRef]);
65
+ }, [enabled, boundTag, currentScreenKey, preparedStyles, measuredAnimatedRef, handoff, escapeClipping, viewportWidth, viewportHeight, scrollState, scrollMetadata, pendingLifecycleStartBlockCount, originRef]);
67
66
  };
68
67
  exports.useMeasurer = useMeasurer;
69
68
  //# sourceMappingURL=use-measurer.js.map