react-native-screen-transitions 3.9.0-beta.1 → 3.9.0-beta.2

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 (330) hide show
  1. package/lib/commonjs/shared/adapters/with-screen-transitions/index.js +20 -4
  2. package/lib/commonjs/shared/adapters/with-screen-transitions/index.js.map +1 -1
  3. package/lib/commonjs/shared/animation/transition-blocking.js +71 -0
  4. package/lib/commonjs/shared/animation/transition-blocking.js.map +1 -0
  5. package/lib/commonjs/shared/components/boundary/components/boundary-target.js +30 -30
  6. package/lib/commonjs/shared/components/boundary/components/boundary-target.js.map +1 -1
  7. package/lib/commonjs/shared/components/boundary/create-boundary-component.js +30 -95
  8. package/lib/commonjs/shared/components/boundary/create-boundary-component.js.map +1 -1
  9. package/lib/commonjs/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.js +68 -51
  10. package/lib/commonjs/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.js.map +1 -1
  11. package/lib/commonjs/shared/components/boundary/hooks/use-boundary-measurement.js +1 -0
  12. package/lib/commonjs/shared/components/boundary/hooks/use-boundary-measurement.js.map +1 -1
  13. package/lib/commonjs/shared/components/boundary/hooks/use-measurer.js +14 -2
  14. package/lib/commonjs/shared/components/boundary/hooks/use-measurer.js.map +1 -1
  15. package/lib/commonjs/shared/components/boundary/hooks/use-register-target.js +32 -0
  16. package/lib/commonjs/shared/components/boundary/hooks/use-register-target.js.map +1 -0
  17. package/lib/commonjs/shared/components/boundary/index.js +1 -1
  18. package/lib/commonjs/shared/components/boundary/portal/components/boundary-content-portal/components/host.js +40 -0
  19. package/lib/commonjs/shared/components/boundary/portal/components/boundary-content-portal/components/host.js.map +1 -0
  20. package/lib/commonjs/shared/components/boundary/portal/components/boundary-content-portal/helpers/host-name.js +14 -0
  21. package/lib/commonjs/shared/components/boundary/portal/components/boundary-content-portal/helpers/host-name.js.map +1 -0
  22. package/lib/commonjs/shared/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.js +194 -0
  23. package/lib/commonjs/shared/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.js.map +1 -0
  24. package/lib/commonjs/shared/components/boundary/portal/components/boundary-content-portal/index.js +44 -0
  25. package/lib/commonjs/shared/components/boundary/portal/components/boundary-content-portal/index.js.map +1 -0
  26. package/lib/commonjs/shared/components/boundary/portal/components/{host.js → boundary-portal/components/host.js} +17 -16
  27. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/components/host.js.map +1 -0
  28. package/lib/commonjs/shared/components/boundary/portal/components/{portal-boundary-host.js → boundary-portal/components/portal-boundary-host.js} +11 -11
  29. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/components/portal-boundary-host.js.map +1 -0
  30. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/components/portal-slot.js +52 -0
  31. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/components/portal-slot.js.map +1 -0
  32. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/helpers/has-local-slot.js.map +1 -0
  33. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/helpers/host-name.js +14 -0
  34. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/helpers/host-name.js.map +1 -0
  35. package/lib/commonjs/shared/components/boundary/portal/{utils → components/boundary-portal/helpers}/offset-style.js +1 -1
  36. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/helpers/offset-style.js.map +1 -0
  37. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.js +184 -0
  38. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.js.map +1 -0
  39. package/lib/commonjs/shared/components/boundary/portal/{hooks → components/boundary-portal/hooks}/use-host-measurement.js +23 -5
  40. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/hooks/use-host-measurement.js.map +1 -0
  41. package/lib/commonjs/shared/components/boundary/portal/{hooks → components/boundary-portal/hooks}/use-placeholder-styles.js +3 -6
  42. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/hooks/use-placeholder-styles.js.map +1 -0
  43. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/index.js +33 -0
  44. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/index.js.map +1 -0
  45. package/lib/commonjs/shared/components/boundary/portal/{stores → components/boundary-portal/stores}/host-bounds.store.js +1 -1
  46. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/stores/host-bounds.store.js.map +1 -0
  47. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/stores/host-registry.store.js.map +1 -0
  48. package/lib/commonjs/shared/components/boundary/portal/{stores → components/boundary-portal/stores}/portal-boundary-host.store.js +7 -12
  49. package/lib/commonjs/shared/components/boundary/portal/components/boundary-portal/stores/portal-boundary-host.store.js.map +1 -0
  50. package/lib/commonjs/shared/components/boundary/portal/index.js +1 -8
  51. package/lib/commonjs/shared/components/boundary/portal/index.js.map +1 -1
  52. package/lib/commonjs/shared/components/boundary/portal/teleport.js +2 -2
  53. package/lib/commonjs/shared/components/boundary/portal/utils/naming.js +1 -15
  54. package/lib/commonjs/shared/components/boundary/portal/utils/naming.js.map +1 -1
  55. package/lib/commonjs/shared/components/boundary/portal/utils/ownership.js +19 -56
  56. package/lib/commonjs/shared/components/boundary/portal/utils/ownership.js.map +1 -1
  57. package/lib/commonjs/shared/components/boundary/providers/boundary-root.provider.js +77 -23
  58. package/lib/commonjs/shared/components/boundary/providers/boundary-root.provider.js.map +1 -1
  59. package/lib/commonjs/shared/components/boundary/utils/destination-signals.js +41 -12
  60. package/lib/commonjs/shared/components/boundary/utils/destination-signals.js.map +1 -1
  61. package/lib/commonjs/shared/components/boundary/utils/measured-bounds.js +36 -1
  62. package/lib/commonjs/shared/components/boundary/utils/measured-bounds.js.map +1 -1
  63. package/lib/commonjs/shared/components/screen-container/layers/content.js +1 -1
  64. package/lib/commonjs/shared/configs/presets.js +2 -2
  65. package/lib/commonjs/shared/configs/presets.js.map +1 -1
  66. package/lib/commonjs/shared/index.js +13 -0
  67. package/lib/commonjs/shared/index.js.map +1 -1
  68. package/lib/commonjs/shared/providers/screen/styles/hooks/use-maybe-block-visibility.js +2 -1
  69. package/lib/commonjs/shared/providers/screen/styles/hooks/use-maybe-block-visibility.js.map +1 -1
  70. package/lib/commonjs/shared/providers/screen/styles/slot.provider.js +5 -3
  71. package/lib/commonjs/shared/providers/screen/styles/slot.provider.js.map +1 -1
  72. package/lib/commonjs/shared/providers/screen/styles/stores/slot-references.store.js +1 -1
  73. package/lib/commonjs/shared/providers/screen/styles/stores/slot-references.store.js.map +1 -1
  74. package/lib/commonjs/shared/stores/system.store.js +10 -2
  75. package/lib/commonjs/shared/stores/system.store.js.map +1 -1
  76. package/lib/commonjs/shared/utils/bounds/helpers/create-bounds-accessor-core.js +15 -9
  77. package/lib/commonjs/shared/utils/bounds/helpers/create-bounds-accessor-core.js.map +1 -1
  78. package/lib/commonjs/shared/utils/bounds/navigation/reveal/build.js +2 -2
  79. package/lib/commonjs/shared/utils/bounds/navigation/reveal/build.js.map +1 -1
  80. package/lib/commonjs/shared/utils/bounds/navigation/zoom/build.js +3 -3
  81. package/lib/commonjs/shared/utils/bounds/navigation/zoom/build.js.map +1 -1
  82. package/lib/module/shared/adapters/with-screen-transitions/index.js +19 -5
  83. package/lib/module/shared/adapters/with-screen-transitions/index.js.map +1 -1
  84. package/lib/module/shared/animation/transition-blocking.js +66 -0
  85. package/lib/module/shared/animation/transition-blocking.js.map +1 -0
  86. package/lib/module/shared/components/boundary/components/boundary-target.js +32 -32
  87. package/lib/module/shared/components/boundary/components/boundary-target.js.map +1 -1
  88. package/lib/module/shared/components/boundary/create-boundary-component.js +32 -97
  89. package/lib/module/shared/components/boundary/create-boundary-component.js.map +1 -1
  90. package/lib/module/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.js +72 -55
  91. package/lib/module/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.js.map +1 -1
  92. package/lib/module/shared/components/boundary/hooks/use-boundary-measurement.js +1 -0
  93. package/lib/module/shared/components/boundary/hooks/use-boundary-measurement.js.map +1 -1
  94. package/lib/module/shared/components/boundary/hooks/use-measurer.js +15 -3
  95. package/lib/module/shared/components/boundary/hooks/use-measurer.js.map +1 -1
  96. package/lib/module/shared/components/boundary/hooks/use-register-target.js +27 -0
  97. package/lib/module/shared/components/boundary/hooks/use-register-target.js.map +1 -0
  98. package/lib/module/shared/components/boundary/index.js +1 -1
  99. package/lib/module/shared/components/boundary/portal/components/boundary-content-portal/components/host.js +35 -0
  100. package/lib/module/shared/components/boundary/portal/components/boundary-content-portal/components/host.js.map +1 -0
  101. package/lib/module/shared/components/boundary/portal/components/boundary-content-portal/helpers/host-name.js +9 -0
  102. package/lib/module/shared/components/boundary/portal/components/boundary-content-portal/helpers/host-name.js.map +1 -0
  103. package/lib/module/shared/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.js +189 -0
  104. package/lib/module/shared/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.js.map +1 -0
  105. package/lib/module/shared/components/boundary/portal/components/boundary-content-portal/index.js +33 -0
  106. package/lib/module/shared/components/boundary/portal/components/boundary-content-portal/index.js.map +1 -0
  107. package/lib/module/shared/components/boundary/portal/components/{host.js → boundary-portal/components/host.js} +17 -16
  108. package/lib/module/shared/components/boundary/portal/components/boundary-portal/components/host.js.map +1 -0
  109. package/lib/module/shared/components/boundary/portal/components/{portal-boundary-host.js → boundary-portal/components/portal-boundary-host.js} +11 -11
  110. package/lib/module/shared/components/boundary/portal/components/boundary-portal/components/portal-boundary-host.js.map +1 -0
  111. package/lib/module/shared/components/boundary/portal/components/boundary-portal/components/portal-slot.js +47 -0
  112. package/lib/module/shared/components/boundary/portal/components/boundary-portal/components/portal-slot.js.map +1 -0
  113. package/lib/module/shared/components/boundary/portal/components/boundary-portal/helpers/has-local-slot.js.map +1 -0
  114. package/lib/module/shared/components/boundary/portal/components/boundary-portal/helpers/host-name.js +9 -0
  115. package/lib/module/shared/components/boundary/portal/components/boundary-portal/helpers/host-name.js.map +1 -0
  116. package/lib/module/shared/components/boundary/portal/{utils → components/boundary-portal/helpers}/offset-style.js +1 -1
  117. package/lib/module/shared/components/boundary/portal/components/boundary-portal/helpers/offset-style.js.map +1 -0
  118. package/lib/module/shared/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.js +179 -0
  119. package/lib/module/shared/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.js.map +1 -0
  120. package/lib/module/shared/components/boundary/portal/{hooks → components/boundary-portal/hooks}/use-host-measurement.js +23 -5
  121. package/lib/module/shared/components/boundary/portal/components/boundary-portal/hooks/use-host-measurement.js.map +1 -0
  122. package/lib/module/shared/components/boundary/portal/{hooks → components/boundary-portal/hooks}/use-placeholder-styles.js +3 -6
  123. package/lib/module/shared/components/boundary/portal/components/boundary-portal/hooks/use-placeholder-styles.js.map +1 -0
  124. package/lib/module/shared/components/boundary/portal/components/boundary-portal/index.js +29 -0
  125. package/lib/module/shared/components/boundary/portal/components/boundary-portal/index.js.map +1 -0
  126. package/lib/module/shared/components/boundary/portal/{stores → components/boundary-portal/stores}/host-bounds.store.js +1 -1
  127. package/lib/module/shared/components/boundary/portal/components/boundary-portal/stores/host-bounds.store.js.map +1 -0
  128. package/lib/module/shared/components/boundary/portal/components/boundary-portal/stores/host-registry.store.js.map +1 -0
  129. package/lib/module/shared/components/boundary/portal/{stores → components/boundary-portal/stores}/portal-boundary-host.store.js +5 -10
  130. package/lib/module/shared/components/boundary/portal/components/boundary-portal/stores/portal-boundary-host.store.js.map +1 -0
  131. package/lib/module/shared/components/boundary/portal/index.js +1 -2
  132. package/lib/module/shared/components/boundary/portal/index.js.map +1 -1
  133. package/lib/module/shared/components/boundary/portal/teleport.js +2 -2
  134. package/lib/module/shared/components/boundary/portal/utils/naming.js +0 -12
  135. package/lib/module/shared/components/boundary/portal/utils/naming.js.map +1 -1
  136. package/lib/module/shared/components/boundary/portal/utils/ownership.js +16 -52
  137. package/lib/module/shared/components/boundary/portal/utils/ownership.js.map +1 -1
  138. package/lib/module/shared/components/boundary/providers/boundary-root.provider.js +74 -20
  139. package/lib/module/shared/components/boundary/providers/boundary-root.provider.js.map +1 -1
  140. package/lib/module/shared/components/boundary/utils/destination-signals.js +39 -10
  141. package/lib/module/shared/components/boundary/utils/destination-signals.js.map +1 -1
  142. package/lib/module/shared/components/boundary/utils/measured-bounds.js +34 -0
  143. package/lib/module/shared/components/boundary/utils/measured-bounds.js.map +1 -1
  144. package/lib/module/shared/components/screen-container/layers/content.js +1 -1
  145. package/lib/module/shared/components/screen-container/layers/content.js.map +1 -1
  146. package/lib/module/shared/configs/presets.js +2 -2
  147. package/lib/module/shared/configs/presets.js.map +1 -1
  148. package/lib/module/shared/index.js +1 -0
  149. package/lib/module/shared/index.js.map +1 -1
  150. package/lib/module/shared/providers/screen/styles/hooks/use-maybe-block-visibility.js +2 -1
  151. package/lib/module/shared/providers/screen/styles/hooks/use-maybe-block-visibility.js.map +1 -1
  152. package/lib/module/shared/providers/screen/styles/slot.provider.js +5 -3
  153. package/lib/module/shared/providers/screen/styles/slot.provider.js.map +1 -1
  154. package/lib/module/shared/providers/screen/styles/stores/slot-references.store.js +1 -1
  155. package/lib/module/shared/providers/screen/styles/stores/slot-references.store.js.map +1 -1
  156. package/lib/module/shared/stores/system.store.js +10 -2
  157. package/lib/module/shared/stores/system.store.js.map +1 -1
  158. package/lib/module/shared/utils/bounds/helpers/create-bounds-accessor-core.js +15 -9
  159. package/lib/module/shared/utils/bounds/helpers/create-bounds-accessor-core.js.map +1 -1
  160. package/lib/module/shared/utils/bounds/navigation/reveal/build.js +2 -2
  161. package/lib/module/shared/utils/bounds/navigation/reveal/build.js.map +1 -1
  162. package/lib/module/shared/utils/bounds/navigation/zoom/build.js +3 -3
  163. package/lib/module/shared/utils/bounds/navigation/zoom/build.js.map +1 -1
  164. package/lib/typescript/shared/adapters/with-screen-transitions/index.d.ts +4 -1
  165. package/lib/typescript/shared/adapters/with-screen-transitions/index.d.ts.map +1 -1
  166. package/lib/typescript/shared/animation/transition-blocking.d.ts +33 -0
  167. package/lib/typescript/shared/animation/transition-blocking.d.ts.map +1 -0
  168. package/lib/typescript/shared/components/boundary/components/boundary-target.d.ts.map +1 -1
  169. package/lib/typescript/shared/components/boundary/create-boundary-component.d.ts.map +1 -1
  170. package/lib/typescript/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.d.ts +2 -1
  171. package/lib/typescript/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.d.ts.map +1 -1
  172. package/lib/typescript/shared/components/boundary/hooks/use-boundary-measurement.d.ts.map +1 -1
  173. package/lib/typescript/shared/components/boundary/hooks/use-measurer.d.ts.map +1 -1
  174. package/lib/typescript/shared/components/boundary/hooks/use-register-target.d.ts +10 -0
  175. package/lib/typescript/shared/components/boundary/hooks/use-register-target.d.ts.map +1 -0
  176. package/lib/typescript/shared/components/boundary/index.d.ts +2 -2
  177. package/lib/typescript/shared/components/boundary/portal/components/boundary-content-portal/components/host.d.ts +10 -0
  178. package/lib/typescript/shared/components/boundary/portal/components/boundary-content-portal/components/host.d.ts.map +1 -0
  179. package/lib/typescript/shared/components/boundary/portal/components/boundary-content-portal/helpers/host-name.d.ts +2 -0
  180. package/lib/typescript/shared/components/boundary/portal/components/boundary-content-portal/helpers/host-name.d.ts.map +1 -0
  181. package/lib/typescript/shared/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.d.ts +12 -0
  182. package/lib/typescript/shared/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.d.ts.map +1 -0
  183. package/lib/typescript/shared/components/boundary/portal/components/boundary-content-portal/index.d.ts +11 -0
  184. package/lib/typescript/shared/components/boundary/portal/components/boundary-content-portal/index.d.ts.map +1 -0
  185. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/components/host.d.ts.map +1 -0
  186. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/components/portal-boundary-host.d.ts.map +1 -0
  187. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/components/portal-slot.d.ts +14 -0
  188. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/components/portal-slot.d.ts.map +1 -0
  189. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/helpers/has-local-slot.d.ts +3 -0
  190. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/helpers/has-local-slot.d.ts.map +1 -0
  191. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/helpers/host-name.d.ts +2 -0
  192. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/helpers/host-name.d.ts.map +1 -0
  193. package/lib/typescript/shared/components/boundary/portal/{utils → components/boundary-portal/helpers}/offset-style.d.ts +1 -1
  194. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/helpers/offset-style.d.ts.map +1 -0
  195. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.d.ts +12 -0
  196. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.d.ts.map +1 -0
  197. package/lib/typescript/shared/components/boundary/portal/{hooks → components/boundary-portal/hooks}/use-host-measurement.d.ts +5 -1
  198. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/hooks/use-host-measurement.d.ts.map +1 -0
  199. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/hooks/use-placeholder-styles.d.ts +12 -0
  200. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/hooks/use-placeholder-styles.d.ts.map +1 -0
  201. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/index.d.ts +13 -0
  202. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/index.d.ts.map +1 -0
  203. package/lib/typescript/shared/components/boundary/portal/{stores → components/boundary-portal/stores}/host-bounds.store.d.ts +1 -1
  204. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/stores/host-bounds.store.d.ts.map +1 -0
  205. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/stores/host-registry.store.d.ts.map +1 -0
  206. package/lib/typescript/shared/components/boundary/portal/{stores → components/boundary-portal/stores}/portal-boundary-host.store.d.ts +3 -3
  207. package/lib/typescript/shared/components/boundary/portal/components/boundary-portal/stores/portal-boundary-host.store.d.ts.map +1 -0
  208. package/lib/typescript/shared/components/boundary/portal/index.d.ts +1 -2
  209. package/lib/typescript/shared/components/boundary/portal/index.d.ts.map +1 -1
  210. package/lib/typescript/shared/components/boundary/portal/utils/naming.d.ts +0 -2
  211. package/lib/typescript/shared/components/boundary/portal/utils/naming.d.ts.map +1 -1
  212. package/lib/typescript/shared/components/boundary/portal/utils/ownership.d.ts +9 -10
  213. package/lib/typescript/shared/components/boundary/portal/utils/ownership.d.ts.map +1 -1
  214. package/lib/typescript/shared/components/boundary/providers/boundary-root.provider.d.ts +21 -21
  215. package/lib/typescript/shared/components/boundary/providers/boundary-root.provider.d.ts.map +1 -1
  216. package/lib/typescript/shared/components/boundary/utils/destination-signals.d.ts +9 -2
  217. package/lib/typescript/shared/components/boundary/utils/destination-signals.d.ts.map +1 -1
  218. package/lib/typescript/shared/components/boundary/utils/measured-bounds.d.ts +8 -0
  219. package/lib/typescript/shared/components/boundary/utils/measured-bounds.d.ts.map +1 -1
  220. package/lib/typescript/shared/index.d.ts +1 -0
  221. package/lib/typescript/shared/index.d.ts.map +1 -1
  222. package/lib/typescript/shared/providers/screen/styles/hooks/use-maybe-block-visibility.d.ts +1 -0
  223. package/lib/typescript/shared/providers/screen/styles/hooks/use-maybe-block-visibility.d.ts.map +1 -1
  224. package/lib/typescript/shared/providers/screen/styles/slot.provider.d.ts +1 -0
  225. package/lib/typescript/shared/providers/screen/styles/slot.provider.d.ts.map +1 -1
  226. package/lib/typescript/shared/providers/screen/styles/stores/slot-references.store.d.ts.map +1 -1
  227. package/lib/typescript/shared/stores/system.store.d.ts.map +1 -1
  228. package/lib/typescript/shared/types/animation.types.d.ts +3 -3
  229. package/lib/typescript/shared/types/bounds.types.d.ts +7 -2
  230. package/lib/typescript/shared/types/bounds.types.d.ts.map +1 -1
  231. package/lib/typescript/shared/utils/bounds/helpers/create-bounds-accessor-core.d.ts.map +1 -1
  232. package/lib/typescript/shared/utils/bounds/types/options.d.ts +6 -2
  233. package/lib/typescript/shared/utils/bounds/types/options.d.ts.map +1 -1
  234. package/package.json +1 -1
  235. package/src/shared/adapters/with-screen-transitions/index.tsx +30 -9
  236. package/src/shared/animation/transition-blocking.ts +79 -0
  237. package/src/shared/components/boundary/components/boundary-target.tsx +43 -50
  238. package/src/shared/components/boundary/create-boundary-component.tsx +35 -150
  239. package/src/shared/components/boundary/hooks/lifecycles/use-initial-destination-measurement.ts +103 -81
  240. package/src/shared/components/boundary/hooks/use-boundary-measurement.ts +1 -0
  241. package/src/shared/components/boundary/hooks/use-measurer.ts +12 -4
  242. package/src/shared/components/boundary/hooks/use-register-target.ts +43 -0
  243. package/src/shared/components/boundary/index.tsx +2 -2
  244. package/src/shared/components/boundary/portal/components/boundary-content-portal/components/host.tsx +48 -0
  245. package/src/shared/components/boundary/portal/components/boundary-content-portal/helpers/host-name.ts +9 -0
  246. package/src/shared/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.ts +274 -0
  247. package/src/shared/components/boundary/portal/components/boundary-content-portal/index.tsx +59 -0
  248. package/src/shared/components/boundary/portal/components/{host.tsx → boundary-portal/components/host.tsx} +14 -15
  249. package/src/shared/components/boundary/portal/components/{portal-boundary-host.tsx → boundary-portal/components/portal-boundary-host.tsx} +12 -12
  250. package/src/shared/components/boundary/portal/components/boundary-portal/components/portal-slot.tsx +80 -0
  251. package/src/shared/components/boundary/portal/{utils → components/boundary-portal/helpers}/has-local-slot.ts +1 -1
  252. package/src/shared/components/boundary/portal/components/boundary-portal/helpers/host-name.ts +10 -0
  253. package/src/shared/components/boundary/portal/{utils → components/boundary-portal/helpers}/offset-style.ts +2 -2
  254. package/src/shared/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.ts +250 -0
  255. package/src/shared/components/boundary/portal/{hooks → components/boundary-portal/hooks}/use-host-measurement.ts +38 -8
  256. package/src/shared/components/boundary/portal/{hooks → components/boundary-portal/hooks}/use-placeholder-styles.ts +4 -15
  257. package/src/shared/components/boundary/portal/components/boundary-portal/index.tsx +38 -0
  258. package/src/shared/components/boundary/portal/{stores → components/boundary-portal/stores}/host-bounds.store.ts +2 -2
  259. package/src/shared/components/boundary/portal/{stores → components/boundary-portal/stores}/portal-boundary-host.store.ts +10 -15
  260. package/src/shared/components/boundary/portal/index.ts +1 -2
  261. package/src/shared/components/boundary/portal/teleport.ts +2 -2
  262. package/src/shared/components/boundary/portal/utils/naming.ts +0 -19
  263. package/src/shared/components/boundary/portal/utils/ownership.ts +32 -88
  264. package/src/shared/components/boundary/providers/boundary-root.provider.tsx +198 -78
  265. package/src/shared/components/boundary/utils/destination-signals.ts +38 -14
  266. package/src/shared/components/boundary/utils/measured-bounds.ts +48 -0
  267. package/src/shared/components/screen-container/layers/content.tsx +1 -1
  268. package/src/shared/configs/presets.ts +2 -2
  269. package/src/shared/index.ts +4 -0
  270. package/src/shared/providers/screen/styles/hooks/use-maybe-block-visibility.tsx +1 -0
  271. package/src/shared/providers/screen/styles/slot.provider.tsx +4 -2
  272. package/src/shared/providers/screen/styles/stores/slot-references.store.ts +2 -1
  273. package/src/shared/stores/system.store.ts +10 -4
  274. package/src/shared/types/animation.types.ts +3 -3
  275. package/src/shared/types/bounds.types.ts +9 -2
  276. package/src/shared/utils/bounds/helpers/create-bounds-accessor-core.ts +18 -11
  277. package/src/shared/utils/bounds/navigation/reveal/build.ts +2 -2
  278. package/src/shared/utils/bounds/navigation/zoom/build.ts +3 -3
  279. package/src/shared/utils/bounds/types/options.ts +9 -2
  280. package/lib/commonjs/shared/components/boundary/portal/components/boundary-local-portal-host.js +0 -58
  281. package/lib/commonjs/shared/components/boundary/portal/components/boundary-local-portal-host.js.map +0 -1
  282. package/lib/commonjs/shared/components/boundary/portal/components/host.js.map +0 -1
  283. package/lib/commonjs/shared/components/boundary/portal/components/portal-boundary-host.js.map +0 -1
  284. package/lib/commonjs/shared/components/boundary/portal/components/portal.js +0 -272
  285. package/lib/commonjs/shared/components/boundary/portal/components/portal.js.map +0 -1
  286. package/lib/commonjs/shared/components/boundary/portal/hooks/use-host-measurement.js.map +0 -1
  287. package/lib/commonjs/shared/components/boundary/portal/hooks/use-placeholder-styles.js.map +0 -1
  288. package/lib/commonjs/shared/components/boundary/portal/stores/host-bounds.store.js.map +0 -1
  289. package/lib/commonjs/shared/components/boundary/portal/stores/host-registry.store.js.map +0 -1
  290. package/lib/commonjs/shared/components/boundary/portal/stores/portal-boundary-host.store.js.map +0 -1
  291. package/lib/commonjs/shared/components/boundary/portal/utils/has-local-slot.js.map +0 -1
  292. package/lib/commonjs/shared/components/boundary/portal/utils/offset-style.js.map +0 -1
  293. package/lib/module/shared/components/boundary/portal/components/boundary-local-portal-host.js +0 -53
  294. package/lib/module/shared/components/boundary/portal/components/boundary-local-portal-host.js.map +0 -1
  295. package/lib/module/shared/components/boundary/portal/components/host.js.map +0 -1
  296. package/lib/module/shared/components/boundary/portal/components/portal-boundary-host.js.map +0 -1
  297. package/lib/module/shared/components/boundary/portal/components/portal.js +0 -267
  298. package/lib/module/shared/components/boundary/portal/components/portal.js.map +0 -1
  299. package/lib/module/shared/components/boundary/portal/hooks/use-host-measurement.js.map +0 -1
  300. package/lib/module/shared/components/boundary/portal/hooks/use-placeholder-styles.js.map +0 -1
  301. package/lib/module/shared/components/boundary/portal/stores/host-bounds.store.js.map +0 -1
  302. package/lib/module/shared/components/boundary/portal/stores/host-registry.store.js.map +0 -1
  303. package/lib/module/shared/components/boundary/portal/stores/portal-boundary-host.store.js.map +0 -1
  304. package/lib/module/shared/components/boundary/portal/utils/has-local-slot.js.map +0 -1
  305. package/lib/module/shared/components/boundary/portal/utils/offset-style.js.map +0 -1
  306. package/lib/typescript/shared/components/boundary/portal/components/boundary-local-portal-host.d.ts +0 -8
  307. package/lib/typescript/shared/components/boundary/portal/components/boundary-local-portal-host.d.ts.map +0 -1
  308. package/lib/typescript/shared/components/boundary/portal/components/host.d.ts.map +0 -1
  309. package/lib/typescript/shared/components/boundary/portal/components/portal-boundary-host.d.ts.map +0 -1
  310. package/lib/typescript/shared/components/boundary/portal/components/portal.d.ts +0 -20
  311. package/lib/typescript/shared/components/boundary/portal/components/portal.d.ts.map +0 -1
  312. package/lib/typescript/shared/components/boundary/portal/hooks/use-host-measurement.d.ts.map +0 -1
  313. package/lib/typescript/shared/components/boundary/portal/hooks/use-placeholder-styles.d.ts +0 -17
  314. package/lib/typescript/shared/components/boundary/portal/hooks/use-placeholder-styles.d.ts.map +0 -1
  315. package/lib/typescript/shared/components/boundary/portal/stores/host-bounds.store.d.ts.map +0 -1
  316. package/lib/typescript/shared/components/boundary/portal/stores/host-registry.store.d.ts.map +0 -1
  317. package/lib/typescript/shared/components/boundary/portal/stores/portal-boundary-host.store.d.ts.map +0 -1
  318. package/lib/typescript/shared/components/boundary/portal/utils/has-local-slot.d.ts +0 -3
  319. package/lib/typescript/shared/components/boundary/portal/utils/has-local-slot.d.ts.map +0 -1
  320. package/lib/typescript/shared/components/boundary/portal/utils/offset-style.d.ts.map +0 -1
  321. package/src/shared/components/boundary/portal/components/boundary-local-portal-host.tsx +0 -66
  322. package/src/shared/components/boundary/portal/components/portal.tsx +0 -412
  323. /package/lib/commonjs/shared/components/boundary/portal/{utils → components/boundary-portal/helpers}/has-local-slot.js +0 -0
  324. /package/lib/commonjs/shared/components/boundary/portal/{stores → components/boundary-portal/stores}/host-registry.store.js +0 -0
  325. /package/lib/module/shared/components/boundary/portal/{utils → components/boundary-portal/helpers}/has-local-slot.js +0 -0
  326. /package/lib/module/shared/components/boundary/portal/{stores → components/boundary-portal/stores}/host-registry.store.js +0 -0
  327. /package/lib/typescript/shared/components/boundary/portal/components/{host.d.ts → boundary-portal/components/host.d.ts} +0 -0
  328. /package/lib/typescript/shared/components/boundary/portal/components/{portal-boundary-host.d.ts → boundary-portal/components/portal-boundary-host.d.ts} +0 -0
  329. /package/lib/typescript/shared/components/boundary/portal/{stores → components/boundary-portal/stores}/host-registry.store.d.ts +0 -0
  330. /package/src/shared/components/boundary/portal/{stores → components/boundary-portal/stores}/host-registry.store.ts +0 -0
@@ -0,0 +1 @@
1
+ {"version":3,"names":["makeMutable","cloneScrollMetadataState","portalHostBounds","getPortalHostBounds","hostKey","get","setPortalHostBounds","bounds","nextBounds","scroll","set","state","clearPortalHostBounds","nextState"],"sourceRoot":"../../../../../../../../../src","sources":["shared/components/boundary/portal/components/boundary-portal/stores/host-bounds.store.ts"],"mappings":";;AAAA,SAAkCA,WAAW,QAAQ,yBAAyB;AAC9E,SAASC,wBAAwB,QAAQ,uCAAuC;AAShF,MAAMC,gBAAgB,GAAGF,WAAW,CAAwB,CAAC,CAAC,CAAC;AAE/D,OAAO,MAAMG,mBAAmB,GAAIC,OAAe,IAAK;EACvD,SAAS;;EACT,OAAOF,gBAAgB,CAACG,GAAG,CAAC,CAAC,CAACD,OAAO,CAAC,IAAI,IAAI;AAC/C,CAAC;AAED,OAAO,MAAME,mBAAmB,GAAGA,CAClCF,OAAe,EACfG,MAAwB,KACpB;EACJ,SAAS;;EACT,MAAMC,UAA4B,GAAG;IACpC,GAAGD,MAAM;IACTE,MAAM,EAAER,wBAAwB,CAACM,MAAM,CAACE,MAAM;EAC/C,CAAC;EAEDP,gBAAgB,CAACQ,GAAG,CAAEC,KAAK,IAAK;IAC/B,SAAS;;IACT,OAAO;MACN,GAAGA,KAAK;MACR,CAACP,OAAO,GAAGI;IACZ,CAAC;EACF,CAAC,CAAC;AACH,CAAC;AAED,OAAO,MAAMI,qBAAqB,GAAIR,OAAe,IAAK;EACzD,SAAS;;EACTF,gBAAgB,CAACQ,GAAG,CAAEC,KAAK,IAAK;IAC/B,SAAS;;IACT,MAAME,SAAgC,GAAG;MAAE,GAAGF;IAAM,CAAC;IACrD,OAAOE,SAAS,CAACT,OAAO,CAAC;IACzB,OAAOS,SAAS;EACjB,CAAC,CAAC;AACH,CAAC","ignoreList":[]}
@@ -0,0 +1 @@
1
+ {"version":3,"names":["useSyncExternalStore","EMPTY_SNAPSHOT","listeners","Set","hostStacks","Map","snapshot","getActiveHostFromStack","screenKey","stack","length","index","host","fallback","hostKey","buildSnapshot","nextSnapshot","emit","listener","subscribe","add","delete","registerHost","registration","get","previousActiveHostKey","nextStack","filter","unshift","push","set","unregisterHost","getActiveHostKey","useActiveHostKey","undefined","resetHostRegistry","clear"],"sourceRoot":"../../../../../../../../../src","sources":["shared/components/boundary/portal/components/boundary-portal/stores/host-registry.store.ts"],"mappings":";;AAAA,SAASA,oBAAoB,QAAQ,OAAO;AAW5C,MAAMC,cAAoC,GAAG,CAAC,CAAC;AAE/C,MAAMC,SAAS,GAAG,IAAIC,GAAG,CAAa,CAAC;AACvC,MAAMC,UAAU,GAAG,IAAIC,GAAG,CAA6B,CAAC;AAExD,IAAIC,QAA8B,GAAGL,cAAc;;AAEnD;AACA;AACA;AACA;AACA;AACA;AACA,MAAMM,sBAAsB,GAAGA,CAC9BC,SAAiB,EACjBC,KAAqC,KACjC;EACJ,IAAI,CAACA,KAAK,IAAIA,KAAK,CAACC,MAAM,KAAK,CAAC,EAAE;IACjC,OAAOF,SAAS;EACjB;EAEA,KAAK,IAAIG,KAAK,GAAGF,KAAK,CAACC,MAAM,GAAG,CAAC,EAAEC,KAAK,IAAI,CAAC,EAAEA,KAAK,EAAE,EAAE;IACvD,MAAMC,IAAI,GAAGH,KAAK,CAACE,KAAK,CAAC;IACzB,IAAI,CAACC,IAAI,CAACC,QAAQ,EAAE;MACnB,OAAOD,IAAI,CAACE,OAAO;IACpB;EACD;EAEA,OAAOL,KAAK,CAAC,CAAC,CAAC,EAAEK,OAAO,IAAIN,SAAS;AACtC,CAAC;AAED,MAAMO,aAAa,GAAGA,CAAA,KAA4B;EAC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T,IAAI,CAAC,CAAC;AACP,CAAC;AAED,OAAO,MAAMc,cAAc,GAAGA,CAACvB,SAAiB,EAAEM,OAAe,KAAK;EACrE,MAAML,KAAK,GAAGL,UAAU,CAACoB,GAAG,CAAChB,SAAS,CAAC;EACvC,IAAI,CAACC,KAAK,EAAE;IACX;EACD;EAEA,MAAMgB,qBAAqB,GAAGlB,sBAAsB,CAACC,SAAS,EAAEC,KAAK,CAAC;EACtE,MAAMiB,SAAS,GAAGjB,KAAK,CAACkB,MAAM,CAAEf,IAAI,IAAKA,IAAI,CAACE,OAAO,KAAKA,OAAO,CAAC;EAElE,IAAIY,SAAS,CAAChB,MAAM,KAAK,CAAC,EAAE;IAC3BN,UAAU,CAACiB,MAAM,CAACb,SAAS,CAAC;EAC7B,CAAC,MAAM;IACNJ,UAAU,CAAC0B,GAAG,CAACtB,SAAS,EAAEkB,SAAS,CAAC;EACrC;EAEA,IAAID,qBAAqB,KAAKlB,sBAAsB,CAACC,SAAS,EAAEkB,SAAS,CAAC,EAAE;IAC3E;EACD;EAEAT,IAAI,CAAC,CAAC;AACP,CAAC;AAED,OAAO,MAAMe,gBAAgB,GAAIxB,SAAiB,IAAK;EACtD,OAAOF,QAAQ,CAACE,SAAS,CAAC,IAAIA,SAAS;AACxC,CAAC;AAED,OAAO,MAAMyB,gBAAgB,GAAIzB,SAAyB,IAAK;EAC9D,OAAOR,oBAAoB,CAC1BmB,SAAS,EACT,MAAOX,SAAS,GAAGwB,gBAAgB,CAACxB,SAAS,CAAC,GAAG0B,SAAU,EAC3D,MAAMA,SACP,CAAC;AACF,CAAC;AAED,OAAO,MAAMC,iBAAiB,GAAGA,CAAA,KAAM;EACtC/B,UAAU,CAACgC,KAAK,CAAC,CAAC;EAClB9B,QAAQ,GAAGL,cAAc;EACzBgB,IAAI,CAAC,CAAC;AACP,CAAC","ignoreList":[]}
@@ -35,16 +35,8 @@ export const mountPortalBoundaryHost = host => {
35
35
  activeBoundaryHosts.set(host.portalHostName, host);
36
36
  emit();
37
37
  };
38
- export const unmountPortalBoundaryHost = boundaryId => {
39
- let didDelete = false;
40
- for (const [hostEntryKey, host] of activeBoundaryHosts) {
41
- if (host.boundaryId !== boundaryId) {
42
- continue;
43
- }
44
- activeBoundaryHosts.delete(hostEntryKey);
45
- didDelete = true;
46
- }
47
- if (!didDelete) {
38
+ export const unmountPortalBoundaryHostByName = portalHostName => {
39
+ if (!portalHostName || !activeBoundaryHosts.delete(portalHostName)) {
48
40
  return;
49
41
  }
50
42
  emit();
@@ -59,6 +51,9 @@ export const dropStalePortalBoundaryHosts = ({
59
51
  boundaryId,
60
52
  keepPortalHostName
61
53
  }) => {
54
+ if (!activeBoundaryHosts.has(keepPortalHostName)) {
55
+ return;
56
+ }
62
57
  let didDelete = false;
63
58
  for (const [hostEntryKey, host] of activeBoundaryHosts) {
64
59
  if (host.boundaryId !== boundaryId || host.portalHostName === keepPortalHostName) {
@@ -0,0 +1 @@
1
+ {"version":3,"names":["useSyncExternalStore","EMPTY_HOSTS","listeners","Set","activeBoundaryHosts","Map","snapshot","hostsByScope","buildSnapshot","host","values","hosts","hostKey","push","emit","listener","isSameHost","a","b","boundaryId","escapeClipping","localStylesMaps","pairKey","portalHostName","screenKey","slotsMap","mountPortalBoundaryHost","previous","get","set","unmountPortalBoundaryHostByName","delete","dropStalePortalBoundaryHosts","keepPortalHostName","has","didDelete","hostEntryKey","subscribe","add","useActivePortalBoundaryHosts"],"sourceRoot":"../../../../../../../../../src","sources":["shared/components/boundary/portal/components/boundary-portal/stores/portal-boundary-host.store.ts"],"mappings":";;AAAA,SAASA,oBAAoB,QAAQ,OAAO;AAoB5C,MAAMC,WAAuC,GAAG,EAAE;AAElD,MAAMC,SAAS,GAAG,IAAIC,GAAG,CAAa,CAAC;AACvC,MAAMC,mBAAmB,GAAG,IAAIC,GAAG,CAAmC,CAAC;AAEvE,IAAIC,QAAwB,GAAG;EAC9BC,YAAY,EAAE,CAAC;AAChB,CAAC;AAED,MAAMC,aAAa,GAAG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use strict";
2
2
 
3
- export { Host } from "./components/host";
4
- export { Portal } from "./components/portal";
3
+ export { Host } from "./components/boundary-portal/components/host";
5
4
  export { PortalProvider } from "./components/portal-provider";
6
5
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["Host","Portal","PortalProvider"],"sourceRoot":"../../../../../../src","sources":["shared/components/boundary/portal/index.ts"],"mappings":";;AAAA,SAASA,IAAI,QAAQ,mBAAmB;AACxC,SAASC,MAAM,QAAQ,qBAAqB;AAC5C,SAASC,cAAc,QAAQ,8BAA8B","ignoreList":[]}
1
+ {"version":3,"names":["Host","PortalProvider"],"sourceRoot":"../../../../../../src","sources":["shared/components/boundary/portal/index.ts"],"mappings":";;AAAA,SAASA,IAAI,QAAQ,8CAA8C;AACnE,SAASC,cAAc,QAAQ,8BAA8B","ignoreList":[]}
@@ -7,8 +7,8 @@ import { createElement } from "react";
7
7
  * try/catch so Metro treats it as an optional dependency — an absent module no
8
8
  * longer fails the bundle, it throws at runtime and the catch swallows it.
9
9
  *
10
- * When teleport is missing, `portal`-enabled boundaries degrade to inline
11
- * rendering; everything else keeps working.
10
+ * When teleport is missing, handoff and escapeClipping boundaries degrade to
11
+ * inline rendering; everything else keeps working.
12
12
  */
13
13
  let mod = null;
14
14
  let managerMod = null;
@@ -1,16 +1,4 @@
1
1
  "use strict";
2
2
 
3
3
  export const PORTAL_HOST_NAME_RESET_VALUE = null;
4
- const PORTAL_HOST_NAME_SUFFIX = "-portal-host";
5
- const BOUNDARY_LOCAL_PORTAL_HOST_NAME_SUFFIX = "-boundary-local-portal-host";
6
- export const createPortalBoundaryHostName = (hostKey, boundaryId, pairKey) => {
7
- "worklet";
8
-
9
- return `${hostKey}-${pairKey ? `${pairKey}-` : ""}${boundaryId}${PORTAL_HOST_NAME_SUFFIX}`;
10
- };
11
- export const createBoundaryLocalPortalHostName = (screenKey, boundaryId) => {
12
- "worklet";
13
-
14
- return `${screenKey}-${boundaryId}${BOUNDARY_LOCAL_PORTAL_HOST_NAME_SUFFIX}`;
15
- };
16
4
  //# sourceMappingURL=naming.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["PORTAL_HOST_NAME_RESET_VALUE","PORTAL_HOST_NAME_SUFFIX","BOUNDARY_LOCAL_PORTAL_HOST_NAME_SUFFIX","createPortalBoundaryHostName","hostKey","boundaryId","pairKey","createBoundaryLocalPortalHostName","screenKey"],"sourceRoot":"../../../../../../../src","sources":["shared/components/boundary/portal/utils/naming.ts"],"mappings":";;AAAA,OAAO,MAAMA,4BAA4B,GAAG,IAAI;AAChD,MAAMC,uBAAuB,GAAG,cAAc;AAC9C,MAAMC,sCAAsC,GAAG,6BAA6B;AAE5E,OAAO,MAAMC,4BAA4B,GAAGA,CAC3CC,OAAe,EACfC,UAAkB,EAClBC,OAAuB,KACnB;EACJ,SAAS;;EACT,OAAO,GAAGF,OAAO,IAAIE,OAAO,GAAG,GAAGA,OAAO,GAAG,GAAG,EAAE,GAAGD,UAAU,GAAGJ,uBAAuB,EAAE;AAC3F,CAAC;AAED,OAAO,MAAMM,iCAAiC,GAAGA,CAChDC,SAAiB,EACjBH,UAAkB,KACd;EACJ,SAAS;;EACT,OAAO,GAAGG,SAAS,IAAIH,UAAU,GAAGH,sCAAsC,EAAE;AAC7E,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["PORTAL_HOST_NAME_RESET_VALUE"],"sourceRoot":"../../../../../../../src","sources":["shared/components/boundary/portal/utils/naming.ts"],"mappings":";;AAAA,OAAO,MAAMA,4BAA4B,GAAG,IAAI","ignoreList":[]}
@@ -1,6 +1,18 @@
1
1
  "use strict";
2
2
 
3
3
  import { getDestinationScreenKeyFromPairKey, getLinkKeyFromTag, getLink as getPairLink, getSourceScreenKeyFromPairKey } from "../../../../stores/bounds/helpers/link-pairs.helpers";
4
+ export const isHandoffHostClosingComplete = ({
5
+ closing,
6
+ progressAnimating,
7
+ progressSettled,
8
+ willAnimate
9
+ }) => {
10
+ "worklet";
11
+
12
+ // A close request marks `closing` before its animation starts. Springs can
13
+ // also enter their settle-distance threshold before their final frame.
14
+ return !!closing && willAnimate === 0 && progressSettled === 1 && progressAnimating === 0;
15
+ };
4
16
  const hasSeenScreenKey = (screenKeys, screenKey) => {
5
17
  "worklet";
6
18
 
@@ -11,11 +23,6 @@ const hasSeenScreenKey = (screenKeys, screenKey) => {
11
23
  }
12
24
  return false;
13
25
  };
14
- export const usesEscapeClippingHost = link => {
15
- "worklet";
16
-
17
- return link?.source?.handoff === true && link.source.escapeClipping === true;
18
- };
19
26
  const isReturningToPreviousSourceHost = ({
20
27
  hostScreenKey,
21
28
  ownerPairKey,
@@ -28,7 +35,7 @@ const isReturningToPreviousSourceHost = ({
28
35
  const ownerDestinationScreenKey = getDestinationScreenKeyFromPairKey(ownerPairKey);
29
36
  return previousDestinationScreenKey !== "" && ownerDestinationScreenKey !== "" && previousDestinationScreenKey !== previousSourceScreenKey && ownerDestinationScreenKey === previousSourceScreenKey && hostScreenKey === previousSourceScreenKey;
30
37
  };
31
- export const canSwitchBoundaryLocalHandoffImmediately = ({
38
+ export const canSwitchHandoffHostImmediately = ({
32
39
  hostScreenKey,
33
40
  ownerPairKey,
34
41
  previousOwnerPairKey
@@ -64,7 +71,7 @@ const isActiveHandoffLink = ({
64
71
  const activeId = pairsState[pairKey]?.groups?.[link.group]?.activeId;
65
72
  return !activeId || activeId === linkKey;
66
73
  };
67
- const resolveBoundaryLocalStyleOwnerScreenKey = ({
74
+ const resolveHandoffStyleOwnerScreenKey = ({
68
75
  hostScreenKey,
69
76
  isSettledHostReady,
70
77
  settledHostScreenKey,
@@ -100,7 +107,6 @@ const clearSignal = sourcePairKey => {
100
107
  export const resolveBoundaryPortalOwnership = ({
101
108
  boundaryId,
102
109
  currentScreenKey,
103
- escapeClipping,
104
110
  handoff,
105
111
  isSettledHostClosingComplete = false,
106
112
  isSettledHostReady = false,
@@ -133,7 +139,6 @@ export const resolveBoundaryPortalOwnership = ({
133
139
  }
134
140
  let hostScreenKey = link.destination.screenKey;
135
141
  let ownerPairKey = sourcePairKey;
136
- let previousOwnerPairKey = null;
137
142
  const seenScreenKeys = [getSourceScreenKeyFromPairKey(sourcePairKey), hostScreenKey];
138
143
  const pairKeys = Object.keys(pairsState);
139
144
  for (let hop = 0; hop < pairKeys.length; hop++) {
@@ -165,7 +170,6 @@ export const resolveBoundaryPortalOwnership = ({
165
170
  continue;
166
171
  }
167
172
  const nextHostScreenKey = candidate.destination.screenKey;
168
- previousOwnerPairKey = ownerPairKey;
169
173
  ownerPairKey = candidatePairKey;
170
174
  hostScreenKey = nextHostScreenKey;
171
175
  if (hasSeenScreenKey(seenScreenKeys, nextHostScreenKey)) {
@@ -187,12 +191,10 @@ export const resolveBoundaryPortalOwnership = ({
187
191
  }
188
192
  break;
189
193
  }
190
- const ownerLink = getPairLink(pairsState, ownerPairKey, linkKey);
191
- const ownerUsesEscapeClipping = ownerLink?.source?.escapeClipping ?? escapeClipping;
192
- if (!ownerUsesEscapeClipping && isSettledHostClosingComplete && settledHostScreenKey === hostScreenKey && previousOwnerPairKey) {
194
+ if (isSettledHostClosingComplete && settledHostScreenKey === hostScreenKey) {
193
195
  hostScreenKey = getSourceScreenKeyFromPairKey(ownerPairKey);
194
196
  }
195
- const ownerScreenKey = ownerUsesEscapeClipping ? getSourceScreenKeyFromPairKey(ownerPairKey) : resolveBoundaryLocalStyleOwnerScreenKey({
197
+ const ownerScreenKey = resolveHandoffStyleOwnerScreenKey({
196
198
  hostScreenKey,
197
199
  isSettledHostReady,
198
200
  settledHostScreenKey,
@@ -205,42 +207,4 @@ export const resolveBoundaryPortalOwnership = ({
205
207
  status: "complete"
206
208
  };
207
209
  };
208
- export const hasHandoffEscapeContinuation = ({
209
- linkKey,
210
- linkState,
211
- sourceScreenKey
212
- }) => {
213
- "worklet";
214
-
215
- const pairKeys = Object.keys(linkState);
216
- const visitedScreenKeys = [];
217
- let cursorScreenKey = sourceScreenKey;
218
- for (let hop = 0; hop < pairKeys.length; hop++) {
219
- if (hasSeenScreenKey(visitedScreenKeys, cursorScreenKey)) {
220
- return false;
221
- }
222
- visitedScreenKeys.push(cursorScreenKey);
223
- let previousScreenKey = null;
224
- for (let index = 0; index < pairKeys.length; index++) {
225
- const candidatePairKey = pairKeys[index];
226
- const link = candidatePairKey ? linkState[candidatePairKey]?.links?.[linkKey] : null;
227
- if (!link?.source || !link.destination || link.destination.screenKey !== cursorScreenKey) {
228
- continue;
229
- }
230
- if (usesEscapeClippingHost(link)) {
231
- return true;
232
- }
233
- if (!link.source.handoff) {
234
- return false;
235
- }
236
- previousScreenKey = link.source.screenKey;
237
- break;
238
- }
239
- if (!previousScreenKey) {
240
- return false;
241
- }
242
- cursorScreenKey = previousScreenKey;
243
- }
244
- return false;
245
- };
246
210
  //# sourceMappingURL=ownership.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["getDestinationScreenKeyFromPairKey","getLinkKeyFromTag","getLink","getPairLink","getSourceScreenKeyFromPairKey","hasSeenScreenKey","screenKeys","screenKey","index","length","usesEscapeClippingHost","link","source","handoff","escapeClipping","isReturningToPreviousSourceHost","hostScreenKey","ownerPairKey","previousOwnerPairKey","previousSourceScreenKey","previousDestinationScreenKey","ownerDestinationScreenKey","canSwitchBoundaryLocalHandoffImmediately","isActiveHandoffLink","linkKey","pairKey","pairsState","group","activeId","groups","resolveBoundaryLocalStyleOwnerScreenKey","isSettledHostReady","settledHostScreenKey","sourceScreenKey","pendingSignal","sourcePairKey","ownerScreenKey","status","clearSignal","resolveBoundaryPortalOwnership","boundaryId","currentScreenKey","isSettledHostClosingComplete","destination","seenScreenKeys","pairKeys","Object","keys","hop","didAdvance","hasPendingNextHop","didHitVisitedScreen","candidatePairKey","candidate","nextHostScreenKey","push","ownerLink","ownerUsesEscapeClipping","hasHandoffEscapeContinuation","linkState","visitedScreenKeys","cursorScreenKey","previousScreenKey","links"],"sourceRoot":"../../../../../../../src","sources":["shared/components/boundary/portal/utils/ownership.ts"],"mappings":";;AAAA,SACCA,kCAAkC,EAClCC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AAgB,CAAC,EAAEW,KAAK,GAAGvC,OAAO,CAAC,GAC7C,IAAI;MAEP,IACC,CAACb,IAAI,EAAEC,MAAM,IACb,CAACD,IAAI,CAACgC,WAAW,IACjBhC,IAAI,CAACgC,WAAW,CAACpC,SAAS,KAAKsD,eAAe,EAC7C;QACD;MACD;MAEA,IAAInD,sBAAsB,CAACC,IAAI,CAAC,EAAE;QACjC,OAAO,IAAI;MACZ;MAEA,IAAI,CAACA,IAAI,CAACC,MAAM,CAACC,OAAO,EAAE;QACzB,OAAO,KAAK;MACb;MAEAiD,iBAAiB,GAAGnD,IAAI,CAACC,MAAM,CAACL,SAAS;MACzC;IACD;IAEA,IAAI,CAACuD,iBAAiB,EAAE;MACvB,OAAO,KAAK;IACb;IAEAD,eAAe,GAAGC,iBAAiB;EACpC;EAEA,OAAO,KAAK;AACb,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["getDestinationScreenKeyFromPairKey","getLinkKeyFromTag","getLink","getPairLink","getSourceScreenKeyFromPairKey","isHandoffHostClosingComplete","closing","progressAnimating","progressSettled","willAnimate","hasSeenScreenKey","screenKeys","screenKey","index","length","isReturningToPreviousSourceHost","hostScreenKey","ownerPairKey","previousOwnerPairKey","previousSourceScreenKey","previousDestinationScreenKey","ownerDestinationScreenKey","canSwitchHandoffHostImmediately","isActiveHandoffLink","link","linkKey","pairKey","pairsState","group","activeId","groups","resolveHandoffStyleOwnerScreenKey","isSettledHostReady","settledHostScreenKey","sourceScreenKey","pendingSignal","sourcePairKey","ownerScreenKey","status","clearSignal","resolveBoundaryPortalOwnership","boundaryId","currentScreenKey","handoff","isSettledHostClosingComplete","destination","seenScreenKeys","pairKeys","Object","keys","hop","didAdvance","hasPendingNextHop","didHitVisitedScreen","candidatePairKey","candidate","source","nextHostScreenKey","push"],"sourceRoot":"../../../../../../../src","sources":["shared/components/boundary/portal/utils/ownership.ts"],"mappings":";;AAAA,SACCA,kCAAkC,EAClCC,iBAAiB,EACjBC,OAAO,IAAIC,WA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AiC,CAAC;IACxDf,aAAa;IACbgB,kBAAkB;IAClBC,oBAAoB;IACpBC,eAAe,EAAE9B,6BAA6B,CAACa,YAAY;EAC5D,CAAC,CAAC;EAEF,OAAO;IACND,aAAa;IACbC,YAAY;IACZoB,cAAc;IACdC,MAAM,EAAE;EACT,CAAC;AACF,CAAC","ignoreList":[]}
@@ -1,25 +1,50 @@
1
1
  "use strict";
2
2
 
3
- import { useCallback, useMemo, useState } from "react";
3
+ import { useCallback, useImperativeHandle, useMemo, useState } from "react";
4
4
  import { useAnimatedRef } from "react-native-reanimated";
5
+ import { useDescriptorsStore } from "../../../providers/screen/descriptors";
6
+ import { useComposedSlotStyles, useSlotStackingStyles } from "../../../providers/screen/styles";
7
+ import { createBoundTag } from "../../../stores/bounds/helpers/link-pairs.helpers";
5
8
  import createProvider from "../../../utils/create-provider";
6
9
  import { logger } from "../../../utils/logger";
10
+ import { useBoundaryMeasurement } from "../hooks/use-boundary-measurement";
11
+ import { resolveBoundaryPortal } from "../portal/utils/resolve-portal";
7
12
  // logger.warn prepends the library prefix.
8
13
  const MULTIPLE_TARGETS_WARNING = "Multiple Boundary.Target elements were rendered under the same boundary root. The first registered target will be measured.";
9
14
  export const TARGET_OUTSIDE_ROOT_WARNING = "Boundary.Target must be rendered inside Transition.Boundary or a component created by createBoundaryComponent.";
10
15
  export const {
11
16
  BoundaryRootProvider,
12
- useBoundaryRootContext
17
+ useBoundaryRootContext,
18
+ useBoundaryRootStore
13
19
  } = createProvider("BoundaryRoot", {
14
20
  guarded: false
15
- })(props => props);
16
- export const useBoundaryRootState = params => {
17
- const {
18
- boundTag,
19
- portalRuntime,
20
- rootMeasurementRef
21
- } = params;
21
+ })(({
22
+ children,
23
+ config,
24
+ enabled = true,
25
+ escapeClipping,
26
+ forwardedRef,
27
+ group,
28
+ handoff,
29
+ id,
30
+ style
31
+ }) => {
32
+ const boundTag = useMemo(() => createBoundTag(String(id), group), [id, group]);
33
+ const portalRuntime = resolveBoundaryPortal({
34
+ handoff,
35
+ escapeClipping
36
+ });
37
+ const currentScreenKey = useDescriptorsStore(s => s.derivations.currentScreenKey);
38
+ const hasConfiguredInterpolator = useDescriptorsStore(s => s.derivations.hasConfiguredInterpolator);
39
+ const runtimeEnabled = enabled && hasConfiguredInterpolator;
40
+ // Associated slot styles attach whenever the boundary is enabled,
41
+ // independent of whether an interpolator is configured for this transition.
42
+ const shouldAttachAssociatedStyles = enabled;
43
+ const shouldEscapeBoundaryRootToScreenHost = portalRuntime.escapeClipping;
44
+ const associatedStyles = useComposedSlotStyles(boundTag.tag, style);
45
+ const associatedStackingStyles = useSlotStackingStyles(boundTag.tag);
22
46
  const rootRef = useAnimatedRef();
47
+ const rootEscapePlaceholderRef = useAnimatedRef();
23
48
  const [targetEntry, setTargetEntry] = useState(null);
24
49
  const registerTargetRef = useCallback((targetRef, preparedStyles, measurementRef) => {
25
50
  setTargetEntry(prev => {
@@ -39,19 +64,48 @@ export const useBoundaryRootState = params => {
39
64
  const unregisterTargetRef = useCallback(targetRef => {
40
65
  setTargetEntry(prev => prev?.ref === targetRef ? null : prev);
41
66
  }, []);
42
- const contextValue = useMemo(() => ({
43
- registerTargetRef,
44
- unregisterTargetRef,
67
+ const rootMeasurementRef = shouldEscapeBoundaryRootToScreenHost ? rootEscapePlaceholderRef : rootRef;
68
+ const measuredRef = targetEntry?.measurementRef ?? rootMeasurementRef;
69
+ const hasActiveTarget = targetEntry !== null;
70
+ const targetPreparedStyles = targetEntry?.preparedStyles;
71
+ useImperativeHandle(forwardedRef, () => rootRef.current, [rootRef]);
72
+ useBoundaryMeasurement({
73
+ boundTag,
74
+ enabled,
75
+ runtimeEnabled,
76
+ currentScreenKey,
77
+ measuredRef,
78
+ style,
79
+ targetPreparedStyles,
80
+ handoff: portalRuntime.handoff,
81
+ escapeClipping: portalRuntime.escapeClipping,
82
+ config
83
+ });
84
+ const shouldRenderBoundaryRootThroughPortal = shouldEscapeBoundaryRootToScreenHost && !hasActiveTarget;
85
+ // A nested active target takes the full associated style, so the root keeps
86
+ // only its stacking context. Root-owned escape-clipping moves the root
87
+ // through a screen host, so its associated style is applied through the
88
+ // host instead of inline on the escaped element.
89
+ // Host-only handoff receivers still need the associated style: their
90
+ // handoff host is absolute-filled inside this root, so the root is the
91
+ // visual frame that animates the received payload.
92
+ const attachedStyle = shouldAttachAssociatedStyles ? hasActiveTarget ? associatedStackingStyles : shouldRenderBoundaryRootThroughPortal ? undefined : associatedStyles : undefined;
93
+ const value = useMemo(() => ({
94
+ attachedStyle,
45
95
  activeTargetRef: targetEntry?.ref ?? null,
46
96
  boundTag,
47
- portalRuntime
48
- }), [registerTargetRef, unregisterTargetRef, targetEntry, boundTag, portalRuntime]);
49
- return {
97
+ currentScreenKey,
98
+ portalRuntime,
99
+ registerTargetRef,
50
100
  ref: rootRef,
51
- contextValue,
52
- hasActiveTarget: targetEntry !== null,
53
- measuredRef: targetEntry?.measurementRef ?? rootMeasurementRef ?? rootRef,
54
- targetPreparedStyles: targetEntry?.preparedStyles
101
+ rootEscapePlaceholderRef,
102
+ shouldRenderBoundaryRootThroughPortal,
103
+ shouldRenderHandoffHost: enabled && portalRuntime.handoff,
104
+ unregisterTargetRef
105
+ }), [attachedStyle, boundTag, currentScreenKey, enabled, portalRuntime, registerTargetRef, rootRef, rootEscapePlaceholderRef, shouldRenderBoundaryRootThroughPortal, targetEntry, unregisterTargetRef]);
106
+ return {
107
+ value,
108
+ children: children(value)
55
109
  };
56
- };
110
+ });
57
111
  //# sourceMappingURL=boundary-root.provider.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["useCallback","useMemo","useState","useAnimatedRef","createProvider","logger","MULTIPLE_TARGETS_WARNING","TARGET_OUTSIDE_ROOT_WARNING","BoundaryRootProvider","useBoundaryRootContext","guarded","props","useBoundaryRootState","params","boundTag","portalRuntime","rootMeasurementRef","rootRef","targetEntry","setTargetEntry","registerTargetRef","targetRef","preparedStyles","measurementRef","prev","ref","__DEV__","warnOnce","unregisterTargetRef","contextValue","activeTargetRef","hasActiveTarget","measuredRef","targetPreparedStyles"],"sourceRoot":"../../../../../../src","sources":["shared/components/boundary/providers/boundary-root.provider.tsx"],"mappings":";;AAAA,SAAyBA,WAAW,EAAEC,OAAO,EAAEC,QAAQ,QAAQ,OAAO;AAGtE,SAASC,cAAc,QAAQ,yBAAyB;AAExD,OAAOC,cAAc,MAAM,gCAAgC;AAC3D,SAASC,MAAM,QAAQ,uBAAuB;AAsB9C;AACA,MAAMC,wBAAwB,GAC7B,6HAA6H;AAE9H,OAAO,MAAMC,2BAA2B,GACvC,gHAAgH;AAOjH,OAAO,MAAM;EAAEC,oBAAoB;EAAEC;AAAuB,CAAC,GAAGL,cAAc,CAC7E,cAAc,EACd;EAAEM,OAAO,EAAE;AAAM,CAClB,CAAC,CAA+CC,KAAK,IAAKA,KAAK,CAAC;AAEhE,OAAO,MAAMC,oBAAoB,GAAIC,MAIpC,IAAK;EACL,MAAM;IAAEC,QAAQ;IAAEC,aAAa;IAAEC;EAAmB,CAAC,GAAGH,MAAM;EAC9D,MAAMI,OAAO,GAAGd,cAAc,CAAO,CAAC;EACtC,MAAM,CAACe,WAAW,EAAEC,cAAc,CAAC,GAAGjB,QAAQ,CAC7C,IACD,CAAC;EAED,MAAMkB,iBAAiB,GAAGpB,WAAW,CACpC,CACCqB,SAA4B,EAC5BC,cAA0B,EAC1BC,cAAkC,KAC9B;IACJJ,cAAc,CAAEK,IAAI,IAAK;MACxB,IAAIA,IAAI,EAAEC,GAAG,KAAKJ,SAAS,EAAE;QAC5B,OAAOG,IAAI;MACZ;MAEA,IAAIE,OAAO,IAAIF,IAAI,KAAK,IAAI,EAAE;QAC7BnB,MAAM,CAACsB,QAAQ,CACd,2BAA2B,EAC3BrB,wBACD,CAAC;MACF;MAEA,OACCkB,IAAI,IAAI;QACPC,GAAG,EAAEJ,SAAS;QACdE,cAAc,EAAEA,cAAc,IAAIF,SAAS;QAC3CC;MACD,CAAC;IAEH,CAAC,CAAC;EACH,CAAC,EACD,EACD,CAAC;EAED,MAAMM,mBAAmB,GAAG5B,WAAW,CAAEqB,SAA4B,IAAK;IACzEF,cAAc,CAAEK,IAAI,IAAMA,IAAI,EAAEC,GAAG,KAAKJ,SAAS,GAAG,IAAI,GAAGG,IAAK,CAAC;EAClE,CAAC,EAAE,EAAE,CAAC;EAEN,MAAMK,YAAY,GAAG5B,OAAO,CAC3B,OAAO;IACNmB,iBAAiB;IACjBQ,mBAAmB;IACnBE,eAAe,EAAEZ,WAAW,EAAEO,GAAG,IAAI,IAAI;IACzCX,QAAQ;IACRC;EACD,CAAC,CAAC,EACF,CACCK,iBAAiB,EACjBQ,mBAAmB,EACnBV,WAAW,EACXJ,QAAQ,EACRC,aAAa,CAEf,CAAC;EAED,OAAO;IACNU,GAAG,EAAER,OAAO;IACZY,YAAY;IACZE,eAAe,EAAEb,WAAW,KAAK,IAAI;IACrCc,WAAW,EAAEd,WAAW,EAAEK,cAAc,IAAIP,kBAAkB,IAAIC,OAAO;IACzEgB,oBAAoB,EAAEf,WAAW,EAAEI;EACpC,CAAC;AACF,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["useCallback","useImperativeHandle","useMemo","useState","useAnimatedRef","useDescriptorsStore","useComposedSlotStyles","useSlotStackingStyles","createBoundTag","createProvider","logger","useBoundaryMeasurement","resolveBoundaryPortal","MULTIPLE_TARGETS_WARNING","TARGET_OUTSIDE_ROOT_WARNING","BoundaryRootProvider","useBoundaryRootContext","useBoundaryRootStore","guarded","children","config","enabled","escapeClipping","forwardedRef","group","handoff","id","style","boundTag","String","portalRuntime","currentScreenKey","s","derivations","hasConfiguredInterpolator","runtimeEnabled","shouldAttachAssociatedStyles","shouldEscapeBoundaryRootToScreenHost","associatedStyles","tag","associatedStackingStyles","rootRef","rootEscapePlaceholderRef","targetEntry","setTargetEntry","registerTargetRef","targetRef","preparedStyles","measurementRef","prev","ref","__DEV__","warnOnce","unregisterTargetRef","rootMeasurementRef","measuredRef","hasActiveTarget","targetPreparedStyles","current","shouldRenderBoundaryRootThroughPortal","attachedStyle","undefined","value","activeTargetRef","shouldRenderHandoffHost"],"sourceRoot":"../../../../../../src","sources":["shared/components/boundary/providers/boundary-root.provider.tsx"],"mappings":";;AAAA,SAGCA,WAAW,EACXC,mBAAmB,EACnBC,OAAO,EACPC,QAAQ,QACF,OAAO;AAGd,SAASC,cAAc,QAAQ,yBAAyB;AACxD,SAASC,mBAAmB,QAAQ,uCAAuC;AAC3E,SACCC,qBAAqB,EACrBC,qBAAqB,QACf,kCAAkC;AACzC,SAASC,cAAc,QAAQ,mDAAmD;AAElF,OAAOC,cAAc,MAAM,gCAAgC;AAC3D,SAASC,MAAM,QAAQ,uBAAuB;AAC9C,SAASC,sBAAsB,QAAQ,mCAAmC;AAC1E,SAECC,qBAAqB,QACf,gCAAgC;AA0BvC;AACA,MAAMC,wBAAwB,GAC7B,6HAA6H;AAE9H,OAAO,MAAMC,2BAA2B,GACvC,gHAAgH;AAwBjH,OAAO,MAAM;EACZC,oBAAoB;EACpBC,sBAAsB;EACtBC;AACD,CAAC,GAAGR,cAAc,CAAC,cAAc,EAAE;EAAES,OAAO,EAAE;AAAM,CAAC,CAAC,CAIrD,CAAC;EACAC,QAAQ;EACRC,MAAM;EACNC,OAAO,GAAG,IAAI;EACdC,cAAc;EACdC,YAAY;EACZC,KAAK;EACLC,OAAO;EACPC,EAAE;EACFC;AACD,CAAC,KAAK;EACL,MAAMC,QAAQ,GAAG1B,OAAO,CACvB,MAAMM,cAAc,CAACqB,MAAM,CAACH,EAAE,CAAC,EAAEF,KAAK,CAAC,EACvC,CAACE,EAAE,EAAEF,KAAK,CACX,CAAC;EACD,MAAMM,aAAa,GAAGlB,qBAAqB,CAAC;IAC3Ca,OAAO;IACPH;EACD,CAAC,CAAC;EAEF,MAAMS,gBAAgB,GAAG1B,mBAAmB,CAC1C2B,CAAC,IAAKA,CAAC,CAACC,WAAW,CAACF,gBACtB,CAAC;EACD,MAAMG,yBAAyB,GAAG7B,mBAAmB,CACnD2B,CAAC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Q,EAAEA,QAAQ,CAAC2C,KAAK;EACzB,CAAC;AACF,CACD,CAAC","ignoreList":[]}
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
 
3
3
  import { getActiveGroupId, getLinkKeyFromTag } from "../../../stores/bounds/helpers/link-pairs.helpers";
4
- export const getInitialDestinationMeasurePairKey = params => {
4
+ export const getInitialDestinationMeasurementSignal = params => {
5
5
  "worklet";
6
6
 
7
7
  const {
@@ -10,21 +10,50 @@ export const getInitialDestinationMeasurePairKey = params => {
10
10
  ancestorDestinationPairKey,
11
11
  linkId,
12
12
  group,
13
+ destinationPresent,
14
+ sourcePresent,
13
15
  linkState
14
16
  } = params;
15
- const measurePairKey = destinationPairKey ?? ancestorDestinationPairKey;
16
- if (!enabled || !measurePairKey) {
17
+ const pairKey = destinationPairKey ?? ancestorDestinationPairKey;
18
+ if (!enabled || !pairKey) {
17
19
  return null;
18
20
  }
19
- const linkKey = getLinkKeyFromTag(linkId);
20
- const hasDestination = linkState?.[measurePairKey]?.links?.[linkKey]?.destination;
21
- if (hasDestination) {
22
- return null;
21
+ if (!destinationPresent) {
22
+ return {
23
+ pairKey,
24
+ action: "wait"
25
+ };
23
26
  }
24
- const activeGroupId = group && linkState ? getActiveGroupId(linkState, measurePairKey, group) : null;
27
+ if (!sourcePresent) {
28
+ return {
29
+ pairKey,
30
+ action: "release"
31
+ };
32
+ }
33
+ const linkKey = getLinkKeyFromTag(linkId);
34
+ const activeGroupId = group && linkState ? getActiveGroupId(linkState, pairKey, group) : null;
25
35
  if (activeGroupId && activeGroupId !== linkKey) {
26
- return null;
36
+ return {
37
+ pairKey,
38
+ action: "release"
39
+ };
40
+ }
41
+ const link = linkState?.[pairKey]?.links?.[linkKey];
42
+ if (!link?.destination) {
43
+ return {
44
+ pairKey,
45
+ action: "measure"
46
+ };
47
+ }
48
+ if (!link.source) {
49
+ return {
50
+ pairKey,
51
+ action: "wait"
52
+ };
27
53
  }
28
- return measurePairKey;
54
+ return {
55
+ pairKey,
56
+ action: "complete"
57
+ };
29
58
  };
30
59
  //# sourceMappingURL=destination-signals.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["getActiveGroupId","getLinkKeyFromTag","getInitialDestinationMeasurePairKey","params","enabled","destinationPairKey","ancestorDestinationPairKey","linkId","group","linkState","measurePairKey","linkKey","hasDestination","links","destination","activeGroupId"],"sourceRoot":"../../../../../../src","sources":["shared/components/boundary/utils/destination-signals.ts"],"mappings":";;AAAA,SACCA,gBAAgB,EAChBC,iBAAiB,QACX,mDAAmD;AAM1D,OAAO,MAAMC,mCAAmC,GAAIC,MAOnD,IAA2B;EAC3B,SAAS;;EACT,MAAM;IACLC,OAAO;IACPC,kBAAkB;IAClBC,0BAA0B;IAC1BC,MAAM;IACNC,KAAK;IACLC;EACD,CAAC,GAAGN,MAAM;EACV,MAAMO,cAAc,GAAGL,kBAAkB,IAAIC,0BAA0B;EAEvE,IAAI,CAACF,OAAO,IAAI,CAACM,cAAc,EAAE;IAChC,OAAO,IAAI;EACZ;EAEA,MAAMC,OAAO,GAAGV,iBAAiB,CAACM,MAAM,CAAC;EACzC,MAAMK,cAAc,GACnBH,SAAS,GAAGC,cAAc,CAAC,EAAEG,KAAK,GAAGF,OAAO,CAAC,EAAEG,WAAW;EAE3D,IAAIF,cAAc,EAAE;IACnB,OAAO,IAAI;EACZ;EAEA,MAAMG,aAAa,GAClBP,KAAK,IAAIC,SAAS,GACfT,gBAAgB,CAACS,SAAS,EAAEC,cAAc,EAAEF,KAAK,CAAC,GAClD,IAAI;EAER,IAAIO,aAAa,IAAIA,aAAa,KAAKJ,OAAO,EAAE;IAC/C,OAAO,IAAI;EACZ;EAEA,OAAOD,cAAc;AACtB,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["getActiveGroupId","getLinkKeyFromTag","getInitialDestinationMeasurementSignal","params","enabled","destinationPairKey","ancestorDestinationPairKey","linkId","group","destinationPresent","sourcePresent","linkState","pairKey","action","linkKey","activeGroupId","link","links","destination","source"],"sourceRoot":"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,EAAE;EAAW,CAAC;AACvC,CAAC","ignoreList":[]}
@@ -53,6 +53,40 @@ export const isMeasurementInViewport = (measured, viewportWidth, viewportHeight)
53
53
  const centerY = measured.pageY + measured.height / 2;
54
54
  return centerX >= -toleranceX && centerX <= viewportWidth + toleranceX && centerY >= -toleranceY && centerY <= viewportHeight + toleranceY;
55
55
  };
56
+ export const normalizeMeasuredBoundsWithVisibilityGate = ({
57
+ measured,
58
+ origin,
59
+ visibilityBlocked,
60
+ visibilityBlockOffset,
61
+ viewportWidth,
62
+ viewportHeight
63
+ }) => {
64
+ "worklet";
65
+
66
+ const normalized = normalizeMeasuredBoundsToOrigin(measured, origin);
67
+ if (!visibilityBlocked || visibilityBlockOffset <= 0 || isMeasurementInViewport(normalized, viewportWidth, viewportHeight)) {
68
+ return normalized;
69
+ }
70
+
71
+ // Fabric can expose the visibility transform to one native measurement one
72
+ // frame before the other. Prefer normal origin-relative coordinates, then
73
+ // test either side of that known frame skew while the gate is active.
74
+ const measuredAhead = {
75
+ ...normalized,
76
+ pageY: normalized.pageY - visibilityBlockOffset
77
+ };
78
+ if (isMeasurementInViewport(measuredAhead, viewportWidth, viewportHeight)) {
79
+ return measuredAhead;
80
+ }
81
+ const originAhead = {
82
+ ...normalized,
83
+ pageY: normalized.pageY + visibilityBlockOffset
84
+ };
85
+ if (isMeasurementInViewport(originAhead, viewportWidth, viewportHeight)) {
86
+ return originAhead;
87
+ }
88
+ return normalized;
89
+ };
56
90
  export const measureWithOverscrollAwareness = (ref, scrollState) => {
57
91
  "worklet";
58
92
 
@@ -1 +1 @@
1
- {"version":3,"names":["measure","clampScrollAxisOffset","cloneScrollMetadataState","SCROLL_MEASUREMENT_EPSILON","getOverscrollDelta","axisState","clampedOffset","delta","offset","Math","abs","adjustedMeasuredBoundsForOverscrollDeltas","measured","scrollState","deltaX","horizontal","deltaY","vertical","x","y","pageX","pageY","normalizeMeasuredBoundsToOrigin","origin","isMeasurementInViewport","viewportWidth","viewportHeight","width","height","toleranceX","toleranceY","centerX","centerY","measureWithOverscrollAwareness","ref","attachScrollSnapshotToMeasuredBounds","scroll"],"sourceRoot":"../../../../../../src","sources":["shared/components/boundary/utils/measured-bounds.ts"],"mappings":";;AACA,SAGCA,OAAO,QACD,yBAAyB;AAChC,SACCC,qBAAqB,EACrBC,wBAAwB,QAClB,8BAA8B;AAOrC,MAAMC,0BAA0B,GAAG,CAAC;AAMpC,MAAMC,kBAAkB,GACvBC,SAAoD,IACxC;EACZ,SAAS;;EACT,MAAMC,aAAa,GAAGL,qBAAqB,CAACI,SAAS,CAAC;EACtD,IAAI,CAACA,SAAS,IAAIC,aAAa,KAAK,IAAI,EAAE;IACzC,OAAO,CAAC;EACT;EAEA,MAAMC,KAAK,GAAGF,SAAS,CAACG,MAAM,GAAGF,aAAa;EAE9C,OAAOG,IAAI,CAACC,GAAG,CAACH,KAAK,CAAC,GAAGJ,0BAA0B,GAAGI,KAAK,GAAG,CAAC;AAChE,CAAC;AAED,OAAO,MAAMI,yCAAyC,GAAGA,CACxDC,QAA4B,EAC5BC,WAA4D,KACpC;EACxB,SAAS;;EAET,IAAI,CAACA,WAAW,EAAE;IACjB,OAAOD,QAAQ;EAChB;EAEA,MAAME,MAAM,GAAGV,kBAAkB,CAACS,WAAW,CAACE,UAAU,CAAC;EACzD,MAAMC,MAAM,GAAGZ,kBAAkB,CAACS,WAAW,CAACI,QAAQ,CAAC;EAEvD,IAAIH,MAAM,KAAK,CAAC,IAAIE,MAAM,KAAK,CAAC,EAAE;IACjC,OAAOJ,QAAQ;EAChB;EAEA,OAAO;IACN,GAAGA,QAAQ;IACXM,CAAC,EAAEN,QAAQ,CAACM,CAAC,GAAGJ,MAAM;IACtBK,CAAC,EAAEP,QAAQ,CAACO,CAAC,GAAGH,MAAM;IACtBI,KAAK,EAAER,QAAQ,CAACQ,KAAK,GAAGN,MAAM;IAC9BO,KAAK,EAAET,QAAQ,CAACS,KAAK,GAAGL;EACzB,CAAC;AACF,CAAC;AAED,OAAO,MA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GAAGxB,QAAQ;IACXwB,MAAM,EAAElC,wBAAwB,CAACkC,MAAM;EACxC,CAAC;AACF,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["measure","clampScrollAxisOffset","cloneScrollMetadataState","SCROLL_MEASUREMENT_EPSILON","getOverscrollDelta","axisState","clampedOffset","delta","offset","Math","abs","adjustedMeasuredBoundsForOverscrollDeltas","measured","scrollState","deltaX","horizontal","deltaY","vertical","x","y","pageX","pageY","normalizeMeasuredBoundsToOrigin","origin","isMeasurementInViewport","viewportWidth","viewportHeight","width","height","toleranceX","toleranceY","centerX","centerY","normalizeMeasuredBoundsWithVisibilityGate","visibilityBlocked","visibilityBlockOffset","normalized","measuredAhead","originAhead","measureWithOverscrollAwareness","ref","attachScrollSnapshotToMeasuredBounds","scroll"],"sourceRoot":"../../../../../../src","sources":["shared/components/boundary/utils/measured-bounds.ts"],"mappings":";;AACA,SAGCA,OAAO,QACD,yBAAyB;AAChC,SACCC,qBAAqB,EACrBC,wBAAwB,QAClB,8BAA8B;AAOrC,MAAMC,0BAA0B,GAAG,CAAC;AAMpC,MAAMC,kBAAkB,GACvBC,SAAoD,IACxC;EACZ,SAAS;;EACT,MAAMC,aAAa,GAAGL,qBAAqB,CAACI,SAAS,CAAC;EACtD,IAAI,CAACA,SAAS,IAAIC,aAAa,KAAK,IAAI,EAAE;IACzC,OAAO,CAAC;EACT;EAEA,MAAMC,KAAK,GAAGF,SAAS,CAACG,MAAM,GAAGF,aAAa;EAE9C,OAAOG,IAAI,CAACC,GAAG,CAACH,KAAK,CAAC,GAAGJ,0BAA0B,GAAGI,KAAK,GAAG,CAAC;AAChE,CAAC;AAED,OAAO,MAAMI,yCAAyC,GAAGA,CACxDC,QAA4B,EAC5BC,WAA4D,KACpC;EACxB,SAAS;;EAET,IAAI,CAACA,WAAW,EAAE;IACjB,OAAOD,QAAQ;EAChB;EAEA,MAAME,MAAM,GAAGV,kBAAkB,CAACS,WAAW,CAACE,UAAU,CAAC;EACzD,MAAMC,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9B,QAAQ;IACX8B,MAAM,EAAExC,wBAAwB,CAACwC,MAAM;EACxC,CAAC;AACF,CAAC","ignoreList":[]}
@@ -9,7 +9,7 @@ import { useDescriptors } from "../../../providers/screen/descriptors";
9
9
  import { useGestureContext } from "../../../providers/screen/gestures";
10
10
  import { OriginProvider } from "../../../providers/screen/origin.provider";
11
11
  import { useSlotProps, useSlotStyles } from "../../../providers/screen/styles";
12
- import { ScreenFallbackHost } from "../../boundary/portal/components/host";
12
+ import { ScreenFallbackHost } from "../../boundary/portal/components/boundary-portal/components/host";
13
13
  import { useContentLayout } from "../hooks/use-content-layout";
14
14
  import { MaybeMaskedNavigationContainer } from "./maybe-masked-navigation-container";
15
15
  import { usesLayerRenderProps } from "./render-component";
@@ -1 +1 @@
1
- {"version":3,"names":["memo","useMemo","StyleSheet","View","GestureDetector","Animated","useDescriptors","useGestureContext","OriginProvider","useSlotProps","useSlotStyles","ScreenFallbackHost","useContentLayout","MaybeMaskedNavigationContainer","usesLayerRenderProps","SurfaceContainer","jsx","_jsx","jsxs","_jsxs","ContentLayer","children","pointerEvents","isBackdropActive","current","gestureContext","ContentComponent","options","contentComponent","isNavigationMaskEnabled","navigationMaskEnabled","contentPointerEvents","AnimatedContentComponent","createAnimatedComponent","hasAutoSnapPoint","snapPoints","includes","handleContentLayout","animatedContentStyle","animatedContentProps","contentStyles","styles","content","contentProps","contentChildren","enabled","collapsable","onLayout","gesture","detectorGesture","style","animatedProps","props","create","flex"],"sourceRoot":"../../../../../../src","sources":["shared/components/screen-container/layers/content.tsx"],"mappings":";;AAAA;AACA,SAA6BA,IAAI,EAAEC,OAAO,QAAQ,OAAO;AACzD,SAASC,UAAU,EAAEC,IAAI,QAAQ,cAAc;AAC/C,SAASC,eAAe,QAAQ,8BAA8B;AAC9D,OAAOC,QAAQ,MAAM,yBAAyB;AAC9C,SAASC,cAAc,QAAQ,uCAAuC;AACtE,SAASC,iBAAiB,QAAQ,oCAAoC;AACtE,SAASC,cAAc,QAAQ,2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O,EAAE;IACRY,IAAI,EAAE;EACP;AACD,CAAC,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["memo","useMemo","StyleSheet","View","GestureDetector","Animated","useDescriptors","useGestureContext","OriginProvider","useSlotProps","useSlotStyles","ScreenFallbackHost","useContentLayout","MaybeMaskedNavigationContainer","usesLayerRenderProps","SurfaceContainer","jsx","_jsx","jsxs","_jsxs","ContentLayer","children","pointerEvents","isBackdropActive","current","gestureContext","ContentComponent","options","contentComponent","isNavigationMaskEnabled","navigationMaskEnabled","contentPointerEvents","AnimatedContentComponent","createAnimatedComponent","hasAutoSnapPoint","snapPoints","includes","handleContentLayout","animatedContentStyle","animatedContentProps","contentStyles","styles","content","contentProps","contentChildren","enabled","collapsable","onLayout","gesture","detectorGesture","style","animatedProps","props","create","flex"],"sourceRoot":"../../../../../../src","sources":["shared/components/screen-container/layers/content.tsx"],"mappings":";;AAAA;AACA,SAA6BA,IAAI,EAAEC,OAAO,QAAQ,OAAO;AACzD,SAASC,UAAU,EAAEC,IAAI,QAAQ,cAAc;AAC/C,SAASC,eAAe,QAAQ,8BAA8B;AAC9D,OAAOC,QAAQ,MAAM,yBAAyB;AAC9C,SAASC,cAAc,QAAQ,uCAAuC;AACtE,SAASC,iBAAiB,QAAQ,oCAAoC;AACtE,SAASC,cAAc,QAAQ,2CAA2C;AAC1E,SAASC,YAAY,EAAEC,aAAa,QAAQ,kCAAkC;AAE9E,SAASC,kBAAkB,QAAQ,kEAAkE;AACrG,SAASC,gBAAgB,QAAQ,6BAA6B;AAC9D,SAASC,8BAA8B,QAAQ,qCAAqC;AACpF,SAASC,oBAAoB,QAAQ,oBAAoB;AACzD,SAASC,gBAAgB,QAAQ,qBAAqB;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAQvD,OAAO,MAAMC,YAAY,gBAAGpB,IAAI,CAC/B,CAAC;EAAEqB,QAAQ;EAAEC,aAAa;EAAEC;AAAwB,CAAC,KAAK;EACzD,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B;UAAAhB,QAAA,EACtDA;QAAQ,CACJ,CAAC,GAEPA,QACA,eACDJ,IAAA,CAACN,kBAAkB,IAAE,CAAC;MAAA,CACP;IAAC,CACA;EAAC,CACY,CAChC;EAED,oBACCM,IAAA,CAACb,eAAe;IAAC4C,OAAO,EAAEvB,cAAc,CAAEwB,eAAgB;IAAA5B,QAAA,EACxDW,wBAAwB,gBACxBf,IAAA,CAACe,wBAAwB;MACxBkB,KAAK,EAAEV,aAAc;MACrBW,aAAa,EAAEZ,oBAAqB;MACpCjB,aAAa,EAAES,oBAAqB;MAAAV,QAAA,EAEnCuB;IAAe,CACS,CAAC,GACxBlB,gBAAgB,gBACnBT,IAAA,CAACS,gBAAgB;MAChBe,MAAM,EAAED,aAAc;MACtBY,KAAK,EAAET,YAAa;MACpBrB,aAAa,EAAES,oBAAqB;MAAAV,QAAA,EAEnCuB;IAAe,CACC,CAAC,gBAEnB3B,IAAA,CAACZ,QAAQ,CAACF,IAAI;MACb+C,KAAK,EAAEV,aAAc;MACrBW,aAAa,EAAEZ,oBAAqB;MACpCjB,aAAa,EAAES,oBAAqB;MAAAV,QAAA,EAEnCuB;IAAe,CACF;EACf,CACe,CAAC;AAEpB,CACD,CAAC;AAED,MAAMH,MAAM,GAAGvC,UAAU,CAACmD,MAAM,CAAC;EAChCX,OAAO,EAAE;IACRY,IAAI,EAAE;EACP;AACD,CAAC,CAAC","ignoreList":[]}
@@ -381,7 +381,7 @@ export const SharedAppleMusic = ({
381
381
  const dragYScale = interpolate(normY, [0, 1], yScaleOuput);
382
382
  const boundValues = bounds({
383
383
  id: sharedBoundTag
384
- }).math({
384
+ }).values({
385
385
  method: focused ? "content" : "transform",
386
386
  anchor: "top",
387
387
  scaleMode: "uniform"
@@ -396,7 +396,7 @@ export const SharedAppleMusic = ({
396
396
  if (focused) {
397
397
  const maskedValues = bounds({
398
398
  id: sharedBoundTag
399
- }).math({
399
+ }).values({
400
400
  space: "absolute",
401
401
  method: "size",
402
402
  target: "fullscreen"