react-native-screen-transitions 4.0.0-alpha.8 → 4.0.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 (308) hide show
  1. package/README.md +6 -11
  2. package/lib/commonjs/components/boundary/create-boundary-component.js +5 -1
  3. package/lib/commonjs/components/boundary/create-boundary-component.js.map +1 -1
  4. package/lib/commonjs/components/boundary/portal/components/boundary-content-portal/helpers/active-handoff-receiver.js +53 -1
  5. package/lib/commonjs/components/boundary/portal/components/boundary-content-portal/helpers/active-handoff-receiver.js.map +1 -1
  6. package/lib/commonjs/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.js +43 -8
  7. package/lib/commonjs/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.js.map +1 -1
  8. package/lib/commonjs/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.js +2 -3
  9. package/lib/commonjs/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.js.map +1 -1
  10. package/lib/commonjs/components/boundary/portal/teleport.js +1 -13
  11. package/lib/commonjs/components/boundary/portal/teleport.js.map +1 -1
  12. package/lib/commonjs/components/boundary/utils/source-signals.js +6 -4
  13. package/lib/commonjs/components/boundary/utils/source-signals.js.map +1 -1
  14. package/lib/commonjs/components/overlay/helpers/get-active-overlay.js +3 -24
  15. package/lib/commonjs/components/overlay/helpers/get-active-overlay.js.map +1 -1
  16. package/lib/commonjs/components/overlay/helpers/retain-ready-overlay-resources.js +4 -3
  17. package/lib/commonjs/components/overlay/helpers/retain-ready-overlay-resources.js.map +1 -1
  18. package/lib/commonjs/components/overlay/hooks/use-overlay-slot.js +1 -2
  19. package/lib/commonjs/components/overlay/hooks/use-overlay-slot.js.map +1 -1
  20. package/lib/commonjs/components/overlay/variations/float-overlay.js +0 -2
  21. package/lib/commonjs/components/overlay/variations/float-overlay.js.map +1 -1
  22. package/lib/commonjs/components/overlay/variations/overlay-host.js +18 -15
  23. package/lib/commonjs/components/overlay/variations/overlay-host.js.map +1 -1
  24. package/lib/commonjs/components/screen-container/layers/content.js +10 -5
  25. package/lib/commonjs/components/screen-container/layers/content.js.map +1 -1
  26. package/lib/commonjs/components/screen-container/layers/surface.js +50 -0
  27. package/lib/commonjs/components/screen-container/layers/surface.js.map +1 -0
  28. package/lib/commonjs/components/stack-view.js +7 -29
  29. package/lib/commonjs/components/stack-view.js.map +1 -1
  30. package/lib/commonjs/configs/index.js +1 -4
  31. package/lib/commonjs/configs/index.js.map +1 -1
  32. package/lib/commonjs/configs/presets.js +1 -384
  33. package/lib/commonjs/configs/presets.js.map +1 -1
  34. package/lib/commonjs/constants.js +2 -1
  35. package/lib/commonjs/constants.js.map +1 -1
  36. package/lib/commonjs/navigators/create-blank-stack-navigator.js +7 -67
  37. package/lib/commonjs/navigators/create-blank-stack-navigator.js.map +1 -1
  38. package/lib/commonjs/navigators/expo-router/index.js +1 -18
  39. package/lib/commonjs/navigators/expo-router/index.js.map +1 -1
  40. package/lib/commonjs/navigators/react-navigation/index.js +1 -3
  41. package/lib/commonjs/navigators/react-navigation/index.js.map +1 -1
  42. package/lib/commonjs/providers/screen/animation/animation.provider.js +6 -1
  43. package/lib/commonjs/providers/screen/animation/animation.provider.js.map +1 -1
  44. package/lib/commonjs/providers/screen/animation/helpers/build-screen-transition-options.js +1 -0
  45. package/lib/commonjs/providers/screen/animation/helpers/build-screen-transition-options.js.map +1 -1
  46. package/lib/commonjs/providers/screen/animation/helpers/hydrate-transition-state/gesture-progress.js +20 -5
  47. package/lib/commonjs/providers/screen/animation/helpers/hydrate-transition-state/gesture-progress.js.map +1 -1
  48. package/lib/commonjs/providers/screen/animation/helpers/hydrate-transition-state/index.js +16 -1
  49. package/lib/commonjs/providers/screen/animation/helpers/hydrate-transition-state/index.js.map +1 -1
  50. package/lib/commonjs/providers/screen/animation/helpers/selected-interpolator-options.js +1 -1
  51. package/lib/commonjs/providers/screen/animation/helpers/selected-interpolator-options.js.map +1 -1
  52. package/lib/commonjs/providers/screen/animation/use-screen-animation.js +1 -8
  53. package/lib/commonjs/providers/screen/animation/use-screen-animation.js.map +1 -1
  54. package/lib/commonjs/providers/screen/gestures/pan/behavior/pan-release.js +28 -6
  55. package/lib/commonjs/providers/screen/gestures/pan/behavior/pan-release.js.map +1 -1
  56. package/lib/commonjs/providers/screen/gestures/pinch/behavior/pinch-release.js +26 -6
  57. package/lib/commonjs/providers/screen/gestures/pinch/behavior/pinch-release.js.map +1 -1
  58. package/lib/commonjs/providers/screen/gestures/shared/policy.js +1 -0
  59. package/lib/commonjs/providers/screen/gestures/shared/policy.js.map +1 -1
  60. package/lib/commonjs/providers/screen/gestures/shared/snap-points.js +71 -1
  61. package/lib/commonjs/providers/screen/gestures/shared/snap-points.js.map +1 -1
  62. package/lib/commonjs/providers/screen/options/helpers.js +8 -1
  63. package/lib/commonjs/providers/screen/options/helpers.js.map +1 -1
  64. package/lib/commonjs/providers/screen/styles/constants.js +4 -1
  65. package/lib/commonjs/providers/screen/styles/constants.js.map +1 -1
  66. package/lib/commonjs/providers/screen/styles/hooks/slot-resolvers.js +1 -9
  67. package/lib/commonjs/providers/screen/styles/hooks/slot-resolvers.js.map +1 -1
  68. package/lib/commonjs/providers/screen/styles/slot.provider.js +3 -1
  69. package/lib/commonjs/providers/screen/styles/slot.provider.js.map +1 -1
  70. package/lib/commonjs/providers/stack/blank-stack-state/helpers/build-blank-stack-state.js +10 -4
  71. package/lib/commonjs/providers/stack/blank-stack-state/helpers/build-blank-stack-state.js.map +1 -1
  72. package/lib/commonjs/providers/stack/blank-stack-state/helpers/derive-blank-stack-state.js +4 -3
  73. package/lib/commonjs/providers/stack/blank-stack-state/helpers/derive-blank-stack-state.js.map +1 -1
  74. package/lib/commonjs/providers/stack/blank-stack-state/helpers/reconcile-blank-stack-routes.js.map +1 -1
  75. package/lib/commonjs/providers/stack/blank-stack-state/helpers/state-equality.js +9 -2
  76. package/lib/commonjs/providers/stack/blank-stack-state/helpers/state-equality.js.map +1 -1
  77. package/lib/commonjs/utils/create-provider.js +14 -3
  78. package/lib/commonjs/utils/create-provider.js.map +1 -1
  79. package/lib/module/components/boundary/create-boundary-component.js +6 -2
  80. package/lib/module/components/boundary/create-boundary-component.js.map +1 -1
  81. package/lib/module/components/boundary/portal/components/boundary-content-portal/helpers/active-handoff-receiver.js +50 -0
  82. package/lib/module/components/boundary/portal/components/boundary-content-portal/helpers/active-handoff-receiver.js.map +1 -1
  83. package/lib/module/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.js +44 -9
  84. package/lib/module/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.js.map +1 -1
  85. package/lib/module/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.js +2 -3
  86. package/lib/module/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.js.map +1 -1
  87. package/lib/module/components/boundary/portal/teleport.js +1 -14
  88. package/lib/module/components/boundary/portal/teleport.js.map +1 -1
  89. package/lib/module/components/boundary/utils/source-signals.js +6 -4
  90. package/lib/module/components/boundary/utils/source-signals.js.map +1 -1
  91. package/lib/module/components/overlay/helpers/get-active-overlay.js +3 -24
  92. package/lib/module/components/overlay/helpers/get-active-overlay.js.map +1 -1
  93. package/lib/module/components/overlay/helpers/retain-ready-overlay-resources.js +4 -3
  94. package/lib/module/components/overlay/helpers/retain-ready-overlay-resources.js.map +1 -1
  95. package/lib/module/components/overlay/hooks/use-overlay-slot.js +1 -2
  96. package/lib/module/components/overlay/hooks/use-overlay-slot.js.map +1 -1
  97. package/lib/module/components/overlay/variations/float-overlay.js +0 -2
  98. package/lib/module/components/overlay/variations/float-overlay.js.map +1 -1
  99. package/lib/module/components/overlay/variations/overlay-host.js +19 -16
  100. package/lib/module/components/overlay/variations/overlay-host.js.map +1 -1
  101. package/lib/module/components/screen-container/layers/content.js +10 -5
  102. package/lib/module/components/screen-container/layers/content.js.map +1 -1
  103. package/lib/module/components/screen-container/layers/surface.js +45 -0
  104. package/lib/module/components/screen-container/layers/surface.js.map +1 -0
  105. package/lib/module/components/stack-view.js +7 -29
  106. package/lib/module/components/stack-view.js.map +1 -1
  107. package/lib/module/configs/index.js +2 -5
  108. package/lib/module/configs/index.js.map +1 -1
  109. package/lib/module/configs/presets.js +0 -380
  110. package/lib/module/configs/presets.js.map +1 -1
  111. package/lib/module/constants.js +1 -0
  112. package/lib/module/constants.js.map +1 -1
  113. package/lib/module/navigators/create-blank-stack-navigator.js +7 -66
  114. package/lib/module/navigators/create-blank-stack-navigator.js.map +1 -1
  115. package/lib/module/navigators/expo-router/index.js +1 -18
  116. package/lib/module/navigators/expo-router/index.js.map +1 -1
  117. package/lib/module/navigators/react-navigation/index.js +1 -3
  118. package/lib/module/navigators/react-navigation/index.js.map +1 -1
  119. package/lib/module/providers/screen/animation/animation.provider.js +4 -0
  120. package/lib/module/providers/screen/animation/animation.provider.js.map +1 -1
  121. package/lib/module/providers/screen/animation/helpers/build-screen-transition-options.js +1 -0
  122. package/lib/module/providers/screen/animation/helpers/build-screen-transition-options.js.map +1 -1
  123. package/lib/module/providers/screen/animation/helpers/hydrate-transition-state/gesture-progress.js +20 -5
  124. package/lib/module/providers/screen/animation/helpers/hydrate-transition-state/gesture-progress.js.map +1 -1
  125. package/lib/module/providers/screen/animation/helpers/hydrate-transition-state/index.js +16 -1
  126. package/lib/module/providers/screen/animation/helpers/hydrate-transition-state/index.js.map +1 -1
  127. package/lib/module/providers/screen/animation/helpers/selected-interpolator-options.js +1 -1
  128. package/lib/module/providers/screen/animation/helpers/selected-interpolator-options.js.map +1 -1
  129. package/lib/module/providers/screen/animation/use-screen-animation.js +2 -9
  130. package/lib/module/providers/screen/animation/use-screen-animation.js.map +1 -1
  131. package/lib/module/providers/screen/gestures/pan/behavior/pan-release.js +29 -7
  132. package/lib/module/providers/screen/gestures/pan/behavior/pan-release.js.map +1 -1
  133. package/lib/module/providers/screen/gestures/pinch/behavior/pinch-release.js +27 -7
  134. package/lib/module/providers/screen/gestures/pinch/behavior/pinch-release.js.map +1 -1
  135. package/lib/module/providers/screen/gestures/shared/policy.js +2 -1
  136. package/lib/module/providers/screen/gestures/shared/policy.js.map +1 -1
  137. package/lib/module/providers/screen/gestures/shared/snap-points.js +66 -0
  138. package/lib/module/providers/screen/gestures/shared/snap-points.js.map +1 -1
  139. package/lib/module/providers/screen/options/helpers.js +9 -2
  140. package/lib/module/providers/screen/options/helpers.js.map +1 -1
  141. package/lib/module/providers/screen/styles/constants.js +4 -1
  142. package/lib/module/providers/screen/styles/constants.js.map +1 -1
  143. package/lib/module/providers/screen/styles/hooks/slot-resolvers.js +2 -10
  144. package/lib/module/providers/screen/styles/hooks/slot-resolvers.js.map +1 -1
  145. package/lib/module/providers/screen/styles/slot.provider.js +1 -0
  146. package/lib/module/providers/screen/styles/slot.provider.js.map +1 -1
  147. package/lib/module/providers/stack/blank-stack-state/helpers/build-blank-stack-state.js +11 -5
  148. package/lib/module/providers/stack/blank-stack-state/helpers/build-blank-stack-state.js.map +1 -1
  149. package/lib/module/providers/stack/blank-stack-state/helpers/derive-blank-stack-state.js +5 -4
  150. package/lib/module/providers/stack/blank-stack-state/helpers/derive-blank-stack-state.js.map +1 -1
  151. package/lib/module/providers/stack/blank-stack-state/helpers/reconcile-blank-stack-routes.js.map +1 -1
  152. package/lib/module/providers/stack/blank-stack-state/helpers/state-equality.js +7 -1
  153. package/lib/module/providers/stack/blank-stack-state/helpers/state-equality.js.map +1 -1
  154. package/lib/module/types/animation.types.js +10 -0
  155. package/lib/module/types/animation.types.js.map +1 -1
  156. package/lib/module/utils/create-provider.js +14 -3
  157. package/lib/module/utils/create-provider.js.map +1 -1
  158. package/lib/typescript/components/boundary/create-boundary-component.d.ts.map +1 -1
  159. package/lib/typescript/components/boundary/portal/components/boundary-content-portal/helpers/active-handoff-receiver.d.ts +20 -1
  160. package/lib/typescript/components/boundary/portal/components/boundary-content-portal/helpers/active-handoff-receiver.d.ts.map +1 -1
  161. package/lib/typescript/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.d.ts.map +1 -1
  162. package/lib/typescript/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.d.ts.map +1 -1
  163. package/lib/typescript/components/boundary/portal/teleport.d.ts +1 -1
  164. package/lib/typescript/components/boundary/portal/teleport.d.ts.map +1 -1
  165. package/lib/typescript/components/boundary/utils/source-signals.d.ts.map +1 -1
  166. package/lib/typescript/components/overlay/helpers/get-active-overlay.d.ts +2 -8
  167. package/lib/typescript/components/overlay/helpers/get-active-overlay.d.ts.map +1 -1
  168. package/lib/typescript/components/overlay/helpers/retain-ready-overlay-resources.d.ts +2 -1
  169. package/lib/typescript/components/overlay/helpers/retain-ready-overlay-resources.d.ts.map +1 -1
  170. package/lib/typescript/components/overlay/hooks/use-overlay-slot.d.ts.map +1 -1
  171. package/lib/typescript/components/overlay/variations/float-overlay.d.ts.map +1 -1
  172. package/lib/typescript/components/overlay/variations/overlay-host.d.ts +2 -3
  173. package/lib/typescript/components/overlay/variations/overlay-host.d.ts.map +1 -1
  174. package/lib/typescript/components/screen-container/layers/content.d.ts.map +1 -1
  175. package/lib/typescript/components/screen-container/layers/surface.d.ts +7 -0
  176. package/lib/typescript/components/screen-container/layers/surface.d.ts.map +1 -0
  177. package/lib/typescript/components/stack-view.d.ts +1 -1
  178. package/lib/typescript/components/stack-view.d.ts.map +1 -1
  179. package/lib/typescript/configs/index.d.ts +0 -9
  180. package/lib/typescript/configs/index.d.ts.map +1 -1
  181. package/lib/typescript/configs/presets.d.ts +0 -9
  182. package/lib/typescript/configs/presets.d.ts.map +1 -1
  183. package/lib/typescript/constants.d.ts +2 -1
  184. package/lib/typescript/constants.d.ts.map +1 -1
  185. package/lib/typescript/index.d.ts +1 -10
  186. package/lib/typescript/index.d.ts.map +1 -1
  187. package/lib/typescript/navigators/create-blank-stack-navigator.d.ts +2 -4
  188. package/lib/typescript/navigators/create-blank-stack-navigator.d.ts.map +1 -1
  189. package/lib/typescript/navigators/expo-router/index.d.ts +3 -3
  190. package/lib/typescript/navigators/expo-router/index.d.ts.map +1 -1
  191. package/lib/typescript/navigators/react-navigation/index.d.ts +1 -1
  192. package/lib/typescript/navigators/react-navigation/index.d.ts.map +1 -1
  193. package/lib/typescript/providers/screen/animation/animation.provider.d.ts +10 -1
  194. package/lib/typescript/providers/screen/animation/animation.provider.d.ts.map +1 -1
  195. package/lib/typescript/providers/screen/animation/helpers/build-screen-transition-options.d.ts.map +1 -1
  196. package/lib/typescript/providers/screen/animation/helpers/hydrate-transition-state/gesture-progress.d.ts +2 -1
  197. package/lib/typescript/providers/screen/animation/helpers/hydrate-transition-state/gesture-progress.d.ts.map +1 -1
  198. package/lib/typescript/providers/screen/animation/helpers/hydrate-transition-state/index.d.ts.map +1 -1
  199. package/lib/typescript/providers/screen/animation/helpers/selected-interpolator-options.d.ts.map +1 -1
  200. package/lib/typescript/providers/screen/animation/use-screen-animation.d.ts.map +1 -1
  201. package/lib/typescript/providers/screen/gestures/pan/behavior/pan-release.d.ts.map +1 -1
  202. package/lib/typescript/providers/screen/gestures/pinch/behavior/pinch-release.d.ts.map +1 -1
  203. package/lib/typescript/providers/screen/gestures/shared/policy.d.ts +2 -1
  204. package/lib/typescript/providers/screen/gestures/shared/policy.d.ts.map +1 -1
  205. package/lib/typescript/providers/screen/gestures/shared/snap-points.d.ts +11 -0
  206. package/lib/typescript/providers/screen/gestures/shared/snap-points.d.ts.map +1 -1
  207. package/lib/typescript/providers/screen/gestures/types.d.ts +2 -0
  208. package/lib/typescript/providers/screen/gestures/types.d.ts.map +1 -1
  209. package/lib/typescript/providers/screen/options/helpers.d.ts.map +1 -1
  210. package/lib/typescript/providers/screen/options/types.d.ts +1 -0
  211. package/lib/typescript/providers/screen/options/types.d.ts.map +1 -1
  212. package/lib/typescript/providers/screen/styles/constants.d.ts.map +1 -1
  213. package/lib/typescript/providers/screen/styles/hooks/slot-resolvers.d.ts.map +1 -1
  214. package/lib/typescript/providers/screen/styles/slot.provider.d.ts +11 -2
  215. package/lib/typescript/providers/screen/styles/slot.provider.d.ts.map +1 -1
  216. package/lib/typescript/providers/stack/blank-stack-state/helpers/build-blank-stack-state.d.ts +3 -3
  217. package/lib/typescript/providers/stack/blank-stack-state/helpers/build-blank-stack-state.d.ts.map +1 -1
  218. package/lib/typescript/providers/stack/blank-stack-state/helpers/derive-blank-stack-state.d.ts.map +1 -1
  219. package/lib/typescript/providers/stack/blank-stack-state/helpers/reconcile-blank-stack-routes.d.ts +3 -2
  220. package/lib/typescript/providers/stack/blank-stack-state/helpers/reconcile-blank-stack-routes.d.ts.map +1 -1
  221. package/lib/typescript/providers/stack/blank-stack-state/helpers/state-equality.d.ts +4 -4
  222. package/lib/typescript/providers/stack/blank-stack-state/helpers/state-equality.d.ts.map +1 -1
  223. package/lib/typescript/providers/stack/blank-stack-state/helpers/types.d.ts +6 -5
  224. package/lib/typescript/providers/stack/blank-stack-state/helpers/types.d.ts.map +1 -1
  225. package/lib/typescript/providers/stack/blank-stack.provider.d.ts +3 -1
  226. package/lib/typescript/providers/stack/blank-stack.provider.d.ts.map +1 -1
  227. package/lib/typescript/types/animation.types.d.ts +16 -12
  228. package/lib/typescript/types/animation.types.d.ts.map +1 -1
  229. package/lib/typescript/types/blank-stack.types.d.ts +2 -23
  230. package/lib/typescript/types/blank-stack.types.d.ts.map +1 -1
  231. package/lib/typescript/types/index.d.ts +2 -2
  232. package/lib/typescript/types/index.d.ts.map +1 -1
  233. package/lib/typescript/types/providers/blank-stack-provider.types.d.ts +8 -6
  234. package/lib/typescript/types/providers/blank-stack-provider.types.d.ts.map +1 -1
  235. package/lib/typescript/types/screen.types.d.ts +50 -0
  236. package/lib/typescript/types/screen.types.d.ts.map +1 -1
  237. package/lib/typescript/utils/create-provider.d.ts +4 -1
  238. package/lib/typescript/utils/create-provider.d.ts.map +1 -1
  239. package/package.json +3 -8
  240. package/src/components/boundary/create-boundary-component.tsx +10 -2
  241. package/src/components/boundary/portal/components/boundary-content-portal/helpers/active-handoff-receiver.ts +89 -0
  242. package/src/components/boundary/portal/components/boundary-content-portal/hooks/use-boundary-content-portal-attachment.ts +97 -14
  243. package/src/components/boundary/portal/components/boundary-portal/hooks/use-boundary-portal-attachment.ts +2 -6
  244. package/src/components/boundary/portal/teleport.ts +2 -23
  245. package/src/components/boundary/utils/source-signals.ts +6 -4
  246. package/src/components/overlay/helpers/get-active-overlay.ts +4 -36
  247. package/src/components/overlay/helpers/retain-ready-overlay-resources.ts +10 -1
  248. package/src/components/overlay/hooks/use-overlay-slot.ts +1 -5
  249. package/src/components/overlay/variations/float-overlay.tsx +9 -12
  250. package/src/components/overlay/variations/overlay-host.tsx +24 -22
  251. package/src/components/screen-container/layers/content.tsx +12 -7
  252. package/src/components/screen-container/layers/surface.tsx +65 -0
  253. package/src/components/stack-view.tsx +8 -39
  254. package/src/configs/index.ts +0 -6
  255. package/src/configs/presets.ts +0 -447
  256. package/src/constants.ts +2 -0
  257. package/src/index.ts +4 -1
  258. package/src/navigators/create-blank-stack-navigator.tsx +16 -124
  259. package/src/navigators/expo-router/index.tsx +0 -23
  260. package/src/navigators/react-navigation/index.tsx +0 -3
  261. package/src/providers/screen/animation/animation.provider.tsx +60 -54
  262. package/src/providers/screen/animation/helpers/build-screen-transition-options.ts +1 -0
  263. package/src/providers/screen/animation/helpers/hydrate-transition-state/gesture-progress.ts +26 -0
  264. package/src/providers/screen/animation/helpers/hydrate-transition-state/index.ts +20 -0
  265. package/src/providers/screen/animation/helpers/selected-interpolator-options.ts +1 -0
  266. package/src/providers/screen/animation/use-screen-animation.tsx +2 -14
  267. package/src/providers/screen/gestures/pan/behavior/pan-release.ts +46 -7
  268. package/src/providers/screen/gestures/pinch/behavior/pinch-release.ts +45 -4
  269. package/src/providers/screen/gestures/shared/policy.ts +4 -0
  270. package/src/providers/screen/gestures/shared/snap-points.ts +87 -0
  271. package/src/providers/screen/gestures/types.ts +2 -0
  272. package/src/providers/screen/options/helpers.ts +18 -0
  273. package/src/providers/screen/options/types.ts +1 -0
  274. package/src/providers/screen/styles/constants.ts +2 -1
  275. package/src/providers/screen/styles/hooks/slot-resolvers.tsx +2 -17
  276. package/src/providers/screen/styles/slot.provider.tsx +2 -1
  277. package/src/providers/stack/blank-stack-state/helpers/build-blank-stack-state.ts +30 -12
  278. package/src/providers/stack/blank-stack-state/helpers/derive-blank-stack-state.ts +11 -3
  279. package/src/providers/stack/blank-stack-state/helpers/reconcile-blank-stack-routes.ts +2 -2
  280. package/src/providers/stack/blank-stack-state/helpers/state-equality.ts +27 -16
  281. package/src/providers/stack/blank-stack-state/helpers/types.ts +9 -4
  282. package/src/types/animation.types.ts +16 -13
  283. package/src/types/blank-stack.types.ts +1 -29
  284. package/src/types/index.ts +4 -1
  285. package/src/types/providers/blank-stack-provider.types.ts +14 -11
  286. package/src/types/screen.types.ts +57 -0
  287. package/src/utils/create-provider.tsx +22 -4
  288. package/lib/commonjs/components/boundary/portal/utils/teleport-control.js +0 -16
  289. package/lib/commonjs/components/boundary/portal/utils/teleport-control.js.map +0 -1
  290. package/lib/commonjs/providers/navigation/navigation-host.provider.js +0 -56
  291. package/lib/commonjs/providers/navigation/navigation-host.provider.js.map +0 -1
  292. package/lib/commonjs/providers/navigation/react-navigation-host.js +0 -23
  293. package/lib/commonjs/providers/navigation/react-navigation-host.js.map +0 -1
  294. package/lib/module/components/boundary/portal/utils/teleport-control.js +0 -11
  295. package/lib/module/components/boundary/portal/utils/teleport-control.js.map +0 -1
  296. package/lib/module/providers/navigation/navigation-host.provider.js +0 -50
  297. package/lib/module/providers/navigation/navigation-host.provider.js.map +0 -1
  298. package/lib/module/providers/navigation/react-navigation-host.js +0 -19
  299. package/lib/module/providers/navigation/react-navigation-host.js.map +0 -1
  300. package/lib/typescript/components/boundary/portal/utils/teleport-control.d.ts +0 -3
  301. package/lib/typescript/components/boundary/portal/utils/teleport-control.d.ts.map +0 -1
  302. package/lib/typescript/providers/navigation/navigation-host.provider.d.ts +0 -21
  303. package/lib/typescript/providers/navigation/navigation-host.provider.d.ts.map +0 -1
  304. package/lib/typescript/providers/navigation/react-navigation-host.d.ts +0 -3
  305. package/lib/typescript/providers/navigation/react-navigation-host.d.ts.map +0 -1
  306. package/src/components/boundary/portal/utils/teleport-control.ts +0 -13
  307. package/src/providers/navigation/navigation-host.provider.tsx +0 -75
  308. package/src/providers/navigation/react-navigation-host.tsx +0 -24
@@ -1,19 +1,11 @@
1
- import { Platform } from "react-native";
2
1
  import {
3
2
  Extrapolation,
4
3
  interpolate,
5
4
  interpolateColor,
6
5
  } from "react-native-reanimated";
7
- import {
8
- NAVIGATION_MASK_CONTAINER_STYLE_ID,
9
- NAVIGATION_MASK_ELEMENT_STYLE_ID,
10
- } from "../constants";
11
6
  import type { ScreenTransitionConfig } from "../types/screen.types";
12
- import { normalizeInterpolatedStyle } from "../utils/normalize-interpolated-style";
13
7
  import { DefaultSpec } from "./specs";
14
8
 
15
- const platform = Platform.OS;
16
-
17
9
  export const SlideFromTop = (
18
10
  config: Partial<ScreenTransitionConfig> = {},
19
11
  ): ScreenTransitionConfig => {
@@ -235,442 +227,3 @@ export const ElasticCard = (
235
227
  ...config,
236
228
  };
237
229
  };
238
-
239
- export const SharedIGImage = ({
240
- id,
241
- ...config
242
- }: Partial<ScreenTransitionConfig> & {
243
- id: string;
244
- }): ScreenTransitionConfig => {
245
- return {
246
- gestureEnabled: true,
247
- gestureDirection: ["vertical", "horizontal"],
248
- enableTransitions: true,
249
- screenStyleInterpolator: ({
250
- current,
251
- layouts: {
252
- screen: { height, width },
253
- },
254
- bounds,
255
- progress,
256
- focused,
257
- active,
258
- }) => {
259
- "worklet";
260
-
261
- const normX = active.gesture.handoff.normX;
262
- const normY = active.gesture.handoff.normY;
263
-
264
- const dragX = interpolate(
265
- normX,
266
- [-1, 0, 1],
267
- [-width * 0.7, 0, width * 0.7],
268
- "clamp",
269
- );
270
- const dragY = interpolate(
271
- normY,
272
- [-1, 0, 1],
273
- [-height * 0.4, 0, height * 0.4],
274
- "clamp",
275
- );
276
- const dragXScale = interpolate(normX, [0, 1], [1, 0.8]);
277
- const dragYScale = interpolate(normY, [0, 1], [1, 0.8]);
278
-
279
- const navigationStyles =
280
- bounds({
281
- id,
282
- }).navigation.zoom() ?? {};
283
-
284
- // Read the bound-specific slots before normalizing the full result.
285
- const sourceStyle = navigationStyles[id] as
286
- | Record<string, unknown>
287
- | undefined;
288
- const containerStyle = navigationStyles[
289
- NAVIGATION_MASK_CONTAINER_STYLE_ID
290
- ] as Record<string, unknown> | undefined;
291
- const maskStyle = navigationStyles[NAVIGATION_MASK_ELEMENT_STYLE_ID] as
292
- | Record<string, unknown>
293
- | undefined;
294
-
295
- const normalizedNav = normalizeInterpolatedStyle(
296
- navigationStyles as Record<string, any>,
297
- );
298
-
299
- if (focused) {
300
- return {
301
- ...normalizedNav,
302
- backdrop: {
303
- style: {
304
- backgroundColor: "black",
305
- opacity: interpolate(progress, [0, 1], [0, 0.5]),
306
- },
307
- },
308
- content: {
309
- style: {
310
- transform: [
311
- { translateX: dragX },
312
- { translateY: dragY },
313
- { scale: dragXScale },
314
- { scale: dragYScale },
315
- ],
316
- },
317
- },
318
- [NAVIGATION_MASK_CONTAINER_STYLE_ID]: containerStyle
319
- ? {
320
- style: {
321
- ...containerStyle,
322
- transform: [
323
- ...(((containerStyle.transform as any[]) ?? []) as any[]),
324
- { translateX: dragX * 0.2 },
325
- { translateY: dragY * 0.2 },
326
- ],
327
- },
328
- }
329
- : undefined,
330
- [NAVIGATION_MASK_ELEMENT_STYLE_ID]: maskStyle
331
- ? {
332
- style: {
333
- ...maskStyle,
334
- borderRadius: interpolate(progress, [0, 1], [0, 24]),
335
- },
336
- }
337
- : undefined,
338
- };
339
- }
340
-
341
- return {
342
- ...normalizedNav,
343
- content: {
344
- style: {
345
- ...(normalizedNav.content?.style ?? {}),
346
- pointerEvents: current.gesture.dismissing ? "none" : "auto",
347
- },
348
- },
349
- [id]: {
350
- style: {
351
- ...(sourceStyle ?? {}),
352
- transform: [
353
- { translateX: dragX || 0 },
354
- { translateY: dragY || 0 },
355
- ...(((sourceStyle?.transform as any[]) ?? []) as any[]),
356
- { scale: dragXScale },
357
- { scale: dragYScale },
358
- ],
359
- },
360
- },
361
- };
362
- },
363
- transitionSpec: {
364
- open: {
365
- stiffness: 1500,
366
- damping: 1000,
367
- mass: 3,
368
- overshootClamping: true,
369
- //@ts-expect-error
370
- restSpeedThreshold: 0.02,
371
- },
372
- close: {
373
- stiffness: 1500,
374
- damping: 1000,
375
- mass: 3,
376
- overshootClamping: true,
377
- //@ts-expect-error
378
- restSpeedThreshold: 0.02,
379
- },
380
- },
381
- ...config,
382
- };
383
- };
384
-
385
- export const SharedAppleMusic = ({
386
- id,
387
- ...config
388
- }: Partial<ScreenTransitionConfig> & {
389
- id: string;
390
- }): ScreenTransitionConfig => {
391
- return {
392
- enableTransitions: true,
393
- gestureEnabled: true,
394
- gestureDirection: ["vertical", "horizontal"],
395
- screenStyleInterpolator: ({
396
- bounds,
397
- focused,
398
- progress,
399
- layouts: { screen },
400
- current,
401
- active,
402
- }) => {
403
- "worklet";
404
-
405
- const normX = active.gesture.handoff.normX;
406
- const normY = active.gesture.handoff.normY;
407
- const initialGesture = active.gesture.handoff.active;
408
-
409
- /**
410
- * ===============================
411
- * Animations for both bounds
412
- * ===============================
413
- */
414
- const xResistance = initialGesture === "horizontal" ? 0.7 : 0.4;
415
- const yResistance = initialGesture === "vertical" ? 0.7 : 0.4;
416
-
417
- const xScaleOuput = initialGesture === "horizontal" ? [1, 0.5] : [1, 1];
418
- const yScaleOuput = initialGesture === "vertical" ? [1, 0.5] : [1, 1];
419
-
420
- const dragX = interpolate(
421
- normX,
422
- [-1, 0, 1],
423
- [-screen.width * xResistance, 0, screen.width * xResistance],
424
- "clamp",
425
- );
426
- const dragY = interpolate(
427
- normY,
428
- [-1, 0, 1],
429
- [-screen.height * yResistance, 0, screen.height * yResistance],
430
- "clamp",
431
- );
432
- const dragXScale = interpolate(normX, [0, 1], xScaleOuput);
433
- const dragYScale = interpolate(normY, [0, 1], yScaleOuput);
434
-
435
- const boundValues = bounds({ id }).values({
436
- method: focused ? "content" : "transform",
437
- anchor: "top",
438
- scaleMode: "uniform",
439
- });
440
-
441
- const opacity = interpolate(
442
- progress,
443
- [0, 0.25, 1.25, 2],
444
- [0, 1, 1, 0],
445
- "clamp",
446
- );
447
-
448
- /**
449
- * ===============================
450
- * Focused specific animations
451
- * ===============================
452
- */
453
- if (focused) {
454
- const maskedValues = bounds({ id }).values({
455
- space: "absolute",
456
- method: "size",
457
- target: "fullscreen",
458
- });
459
-
460
- // Apple Music style drop shadow that increases with drag magnitude
461
- const dragMagnitude = Math.max(Math.abs(normX), Math.abs(normY));
462
- const shadowOpacity = interpolate(
463
- dragMagnitude,
464
- [0, 1],
465
- [0, 0.25],
466
- "clamp",
467
- );
468
- const shadowRadius = interpolate(
469
- dragMagnitude,
470
- [0, 1],
471
- [0, 24],
472
- "clamp",
473
- );
474
- const shadowOffsetY = interpolate(
475
- dragMagnitude,
476
- [0, 1],
477
- [0, 20],
478
- "clamp",
479
- );
480
- const elevation = interpolate(dragMagnitude, [0, 1], [0, 24], "clamp");
481
-
482
- const IOSShadowStyle = {
483
- shadowColor: "#000",
484
- shadowOpacity,
485
- shadowRadius,
486
- shadowOffset: { width: 0, height: shadowOffsetY },
487
- };
488
-
489
- const AndroidShadowStyle = {
490
- elevation,
491
- shadowColor: "#000",
492
- };
493
-
494
- return {
495
- content: {
496
- style: {
497
- pointerEvents: current.animating ? "none" : "auto",
498
- transform: [
499
- { translateX: dragX || 0 },
500
- { translateY: dragY || 0 },
501
- { scale: dragXScale },
502
- { scale: dragYScale },
503
- ],
504
- opacity,
505
- ...(platform === "ios" ? IOSShadowStyle : AndroidShadowStyle),
506
- },
507
- },
508
- _ROOT_CONTAINER: {
509
- style: {
510
- transform: [
511
- { translateX: boundValues.translateX || 0 },
512
- { translateY: boundValues.translateY || 0 },
513
- //@ts-expect-error
514
- { scale: boundValues.scale || 1 },
515
- ],
516
- },
517
- },
518
- _ROOT_MASKED: {
519
- style: {
520
- width: maskedValues.width,
521
- height: maskedValues.height,
522
- transform: [
523
- { translateX: maskedValues.translateX || 0 },
524
- { translateY: maskedValues.translateY || 0 },
525
- ],
526
- borderRadius: interpolate(progress, [0, 1], [0, 24]),
527
- },
528
- },
529
- };
530
- }
531
-
532
- /**
533
- * ===============================
534
- * Unfocused specific animations
535
- * ===============================
536
- */
537
-
538
- const scaledBoundTranslateX = (boundValues.translateX || 0) * dragXScale;
539
- const scaledBoundTranslateY = (boundValues.translateY || 0) * dragYScale;
540
- const scaledBoundScaleX = (boundValues.scaleX || 1) * dragXScale;
541
- const scaledBoundScaleY = (boundValues.scaleY || 1) * dragYScale;
542
-
543
- const contentScale = interpolate(progress, [1, 2], [1, 0.9], "clamp");
544
-
545
- return {
546
- [id]: {
547
- style: {
548
- transform: [
549
- { translateX: dragX || 0 },
550
- { translateY: dragY || 0 },
551
- { translateX: scaledBoundTranslateX },
552
- { translateY: scaledBoundTranslateY },
553
- { scale: dragXScale },
554
- { scale: dragYScale },
555
- { scaleX: scaledBoundScaleX },
556
- { scaleY: scaledBoundScaleY },
557
- ],
558
- opacity,
559
- zIndex: current.animating ? 999 : -1,
560
- position: "relative",
561
- },
562
- },
563
- content: {
564
- style: {
565
- transform: [{ scale: contentScale }],
566
- },
567
- },
568
- };
569
- },
570
- transitionSpec: {
571
- open: {
572
- stiffness: 1000,
573
- damping: 500,
574
- mass: 3,
575
- overshootClamping: true,
576
- //@ts-expect-error - Should not lead to any issues
577
- restSpeedThreshold: 0.02,
578
- },
579
- close: {
580
- stiffness: 600,
581
- damping: 60,
582
- mass: 4,
583
- overshootClamping: false,
584
- //@ts-expect-error - Should not lead to any issues
585
- restSpeedThreshold: 0.02,
586
- restDisplacementThreshold: 0.002,
587
- },
588
- },
589
- ...config,
590
- };
591
- };
592
-
593
- export const SharedXImage = ({
594
- id,
595
- ...config
596
- }: Partial<ScreenTransitionConfig> & {
597
- id: string;
598
- }): ScreenTransitionConfig => {
599
- return {
600
- //@ts-expect-error - Should not lead to any issues
601
- enableTransitions: true,
602
- gestureEnabled: true,
603
- gestureDirection: ["vertical", "vertical-inverted"],
604
- screenStyleInterpolator: ({
605
- focused,
606
- bounds,
607
- current,
608
- layouts: { screen },
609
- progress,
610
- }) => {
611
- "worklet";
612
-
613
- if (!focused) return {};
614
-
615
- const navigationStyles =
616
- bounds({
617
- id,
618
- }).navigation.zoom() ?? {};
619
- const maskStyle = navigationStyles[NAVIGATION_MASK_ELEMENT_STYLE_ID] as
620
- | Record<string, unknown>
621
- | undefined;
622
-
623
- const normalizedNav = normalizeInterpolatedStyle(
624
- navigationStyles as Record<string, any>,
625
- );
626
-
627
- const dragY = interpolate(
628
- current.gesture.normY,
629
- [-1, 0, 1],
630
- [-screen.height, 0, screen.height],
631
- );
632
-
633
- const contentY = interpolate(
634
- progress,
635
- [0, 1],
636
- [dragY >= 0 ? screen.height : -screen.height, 0],
637
- );
638
-
639
- const overlayClr = interpolateColor(
640
- current.progress - Math.abs(current.gesture.normY),
641
- [0, 1],
642
- ["rgba(0,0,0,0)", "rgba(0,0,0,1)"],
643
- );
644
-
645
- const borderRadius = interpolate(current.progress, [0, 1], [12, 0]);
646
-
647
- return {
648
- ...normalizedNav,
649
- [NAVIGATION_MASK_ELEMENT_STYLE_ID]: maskStyle
650
- ? {
651
- style: {
652
- ...maskStyle,
653
- borderRadius,
654
- },
655
- }
656
- : undefined,
657
- content: {
658
- style: {
659
- transform: [{ translateY: contentY }, { translateY: dragY }],
660
- pointerEvents: current.animating ? "none" : "auto",
661
- },
662
- },
663
- backdrop: {
664
- style: {
665
- backgroundColor: overlayClr,
666
- },
667
- },
668
- };
669
- },
670
- transitionSpec: {
671
- open: DefaultSpec,
672
- close: DefaultSpec,
673
- },
674
- ...config,
675
- };
676
- };
package/src/constants.ts CHANGED
@@ -10,6 +10,7 @@ import type {
10
10
  GestureTracking,
11
11
  Layout,
12
12
  SheetScrollGestureBehavior,
13
+ SheetSnapBehavior,
13
14
  } from "./types/screen.types";
14
15
  import type { BaseStackRoute } from "./types/stack.types";
15
16
 
@@ -167,6 +168,7 @@ export const DEFAULT_GESTURE_RELEASE_VELOCITY_SCALE = 1;
167
168
  export const DEFAULT_GESTURE_DIRECTION = "horizontal";
168
169
  export const DEFAULT_GESTURE_TRACKING: GestureTracking = "auto";
169
170
  export const DEFAULT_GESTURE_SNAP_LOCKED = false;
171
+ export const DEFAULT_SHEET_SNAP_BEHAVIOR: SheetSnapBehavior = "continuous";
170
172
  export const DEFAULT_GESTURE_ACTIVATION_AREA: ActivationArea = "screen";
171
173
  export const DEFAULT_SHEET_SCROLL_GESTURE_BEHAVIOR: SheetScrollGestureBehavior =
172
174
  "expand-and-collapse";
package/src/index.ts CHANGED
@@ -50,7 +50,7 @@ export {
50
50
  export type {
51
51
  AnimatedViewStyle,
52
52
  AnimationConfig,
53
- BoundaryTeleportControl,
53
+ BoundaryHandoffTarget,
54
54
  BoundsMotion,
55
55
  BoundsMotionFrame,
56
56
  BoundsMotionTransform,
@@ -73,6 +73,8 @@ export type {
73
73
  ScreenInterpolationProps,
74
74
  ScreenLayerComponentProps,
75
75
  ScreenStyleInterpolator,
76
+ ScreenSurfaceComponent,
77
+ ScreenSurfaceComponentProps,
76
78
  ScreenTransitionAccessor,
77
79
  ScreenTransitionConfig,
78
80
  ScreenTransitionDepthTarget,
@@ -81,6 +83,7 @@ export type {
81
83
  ScrollGestureAxisState,
82
84
  ScrollGestureState,
83
85
  ScrollMetadataState,
86
+ SheetSnapBehavior,
84
87
  TransitionInterpolatedStyle,
85
88
  TransitionSlotProps,
86
89
  TransitionSlotStyle,
@@ -1,19 +1,6 @@
1
- import * as React from "react";
2
- import {
3
- createStandardNavigator,
4
- type NavigatorDescriptor,
5
- } from "standard-navigation";
1
+ import { createStandardNavigator } from "standard-navigation";
6
2
  import { StackView } from "../components/stack-view";
7
- import {
8
- type NavigationHostContextValue,
9
- NavigationHostProvider,
10
- } from "../providers/navigation/navigation-host.provider";
11
- import type {
12
- BlankStackDescriptor,
13
- BlankStackFactoryOptions,
14
- BlankStackNavigationHelpers,
15
- BlankStackNavigationOptions,
16
- } from "../types/blank-stack.types";
3
+ import type { BlankStackNavigationOptions } from "../types/blank-stack.types";
17
4
  import type {
18
5
  BaseStackNavigation,
19
6
  BaseStackRoute,
@@ -22,122 +9,27 @@ import type {
22
9
 
23
10
  export type BlankStackStandardEventMap = {};
24
11
 
25
- export type BlankStackStandardNavigatorProps = BlankStackFactoryOptions & {
12
+ export type BlankStackStandardNavigatorProps = {
26
13
  navigationState?: BaseStackState<BaseStackRoute>;
27
14
  navigation?: BaseStackNavigation;
28
- navigationHost?: NavigationHostContextValue;
29
- };
30
-
31
- type StandardDescriptor = NavigatorDescriptor<BlankStackNavigationOptions> & {
32
- navigation?: BaseStackNavigation;
33
- route?: BaseStackRoute;
34
15
  };
35
16
 
36
- type StandardDescriptorMap = Record<string, StandardDescriptor>;
37
- type BlankStackDescriptorMap = Record<string, BlankStackDescriptor>;
38
-
39
- function createDescriptorMap({
40
- routes,
41
- descriptors,
42
- navigation,
43
- }: {
44
- routes: BaseStackRoute[];
45
- descriptors: StandardDescriptorMap;
46
- navigation: BaseStackNavigation;
47
- }): BlankStackDescriptorMap {
48
- const result: BlankStackDescriptorMap = {};
49
-
50
- for (const route of routes) {
51
- const descriptor = descriptors[route.key];
52
-
53
- if (!descriptor) {
54
- continue;
55
- }
56
-
57
- result[route.key] = {
58
- route: descriptor.route ?? route,
59
- navigation: (descriptor.navigation ??
60
- navigation) as BlankStackDescriptor["navigation"],
61
- options: descriptor.options,
62
- render: () => descriptor.render() as React.JSX.Element,
63
- };
64
- }
65
-
66
- return result;
67
- }
68
-
69
17
  export const BlankStackNavigator = createStandardNavigator<
70
18
  BlankStackNavigationOptions,
71
19
  BlankStackStandardEventMap,
72
20
  BlankStackStandardNavigatorProps
73
- >(
74
- ({
75
- actions,
76
- descriptors,
77
- state,
78
- navigation,
79
- navigationHost,
80
- navigationState,
81
- }) => {
82
- const stackState = navigationState ?? {
83
- key: "blank-stack",
84
- index: state.index,
85
- routes: state.routes as BaseStackRoute[],
86
- };
87
- const stackStateRef = React.useRef(stackState);
88
- stackStateRef.current = stackState;
89
-
90
- const fallbackNavigation = React.useMemo<BaseStackNavigation>(
91
- () => ({
92
- getState: () => stackStateRef.current,
93
- dispatch: (action) => {
94
- if (action?.type === "GO_BACK" || action?.type === "POP") {
95
- actions.back();
96
- return;
97
- }
98
-
99
- const name = action?.payload?.name;
100
- if (action?.type === "NAVIGATE" && typeof name === "string") {
101
- actions.navigate(name, action.payload.params);
102
- }
103
- },
104
- }),
105
- [actions],
106
- );
107
- const stackNavigation = navigation ?? fallbackNavigation;
108
- const stackDescriptors = React.useMemo(
109
- () =>
110
- createDescriptorMap({
111
- routes: stackState.routes,
112
- descriptors,
113
- navigation: stackNavigation,
114
- }),
115
- [descriptors, stackNavigation, stackState.routes],
116
- );
117
- const describe = React.useCallback(
118
- (route: BlankStackDescriptor["route"]) => {
119
- const descriptor = stackDescriptors[route.key];
120
-
121
- if (!descriptor) {
122
- throw new Error(
123
- `BlankStack could not find a descriptor for route "${route.key}".`,
124
- );
125
- }
126
-
127
- return descriptor;
128
- },
129
- [stackDescriptors],
21
+ >(({ descriptors, navigation, navigationState }) => {
22
+ if (!navigationState || !navigation) {
23
+ throw new Error(
24
+ "BlankStack requires navigation state and helpers from its integration.",
130
25
  );
26
+ }
131
27
 
132
- return (
133
- <NavigationHostProvider value={navigationHost}>
134
- <StackView
135
- state={stackState}
136
- navigation={stackNavigation as BlankStackNavigationHelpers}
137
- descriptors={stackDescriptors}
138
- describe={describe}
139
- />
140
- </NavigationHostProvider>
141
- );
142
- },
143
- );
28
+ return (
29
+ <StackView
30
+ state={navigationState}
31
+ navigation={navigation}
32
+ descriptors={descriptors}
33
+ />
34
+ );
35
+ });
@@ -4,11 +4,6 @@ import {
4
4
  type StackRouterOptions,
5
5
  unstable_integrateWithRouter,
6
6
  } from "expo-router";
7
- import {
8
- NavigationContext,
9
- NavigationRouteContext,
10
- } from "expo-router/react-navigation";
11
- import type { NavigationScreenProviderComponent } from "../../providers/navigation/navigation-host.provider";
12
7
  import type { BlankStackNavigationOptions } from "../../types/blank-stack.types";
13
8
  import {
14
9
  BlankStackNavigator,
@@ -18,22 +13,6 @@ import {
18
13
 
19
14
  type BlankStackExpoRouterParamList = Record<string, object | undefined>;
20
15
 
21
- const ExpoRouterScreenProvider: NavigationScreenProviderComponent = ({
22
- children,
23
- navigation,
24
- route,
25
- }) => (
26
- <NavigationContext.Provider value={navigation as never}>
27
- <NavigationRouteContext.Provider value={route as never}>
28
- {children}
29
- </NavigationRouteContext.Provider>
30
- </NavigationContext.Provider>
31
- );
32
-
33
- const expoRouterNavigationHost = {
34
- ScreenProvider: ExpoRouterScreenProvider,
35
- };
36
-
37
16
  export const BlankStack = unstable_integrateWithRouter<
38
17
  BlankStackNavigationOptions,
39
18
  StackNavigationState<BlankStackExpoRouterParamList>,
@@ -44,14 +23,12 @@ export const BlankStack = unstable_integrateWithRouter<
44
23
  createProps: ({ state, navigation }) => ({
45
24
  navigationState: state,
46
25
  navigation,
47
- navigationHost: expoRouterNavigationHost,
48
26
  }),
49
27
  });
50
28
 
51
29
  export const BlankStackScreen = BlankStack.Screen;
52
30
 
53
31
  export type {
54
- BlankStackFactoryOptions,
55
32
  BlankStackNavigationEventMap,
56
33
  BlankStackNavigationOptions,
57
34
  BlankStackNavigationProp,