@ankhorage/zora 28.7.2 → 28.7.4

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 (519) hide show
  1. package/CHANGELOG.md +13 -0
  2. package/README.md +1 -1
  3. package/dist/features/carousel/Carousel.d.ts.map +1 -1
  4. package/dist/features/carousel/Carousel.js +22 -4
  5. package/dist/features/carousel/Carousel.js.map +1 -1
  6. package/dist/features/form/select/adapters/inbound/Select.web.d.ts.map +1 -1
  7. package/dist/features/form/select/adapters/inbound/Select.web.js +4 -1
  8. package/dist/features/form/select/adapters/inbound/Select.web.js.map +1 -1
  9. package/dist/features/form/select/composition/SelectOptionsList.d.ts +9 -0
  10. package/dist/features/form/select/composition/SelectOptionsList.d.ts.map +1 -0
  11. package/dist/features/form/select/composition/SelectOptionsList.js +17 -0
  12. package/dist/features/form/select/composition/SelectOptionsList.js.map +1 -0
  13. package/dist/features/layout/adapters/inbound/ZoraWebStyleSheet.d.ts +6 -1
  14. package/dist/features/layout/adapters/inbound/ZoraWebStyleSheet.d.ts.map +1 -1
  15. package/dist/features/layout/adapters/inbound/ZoraWebStyleSheet.js +4 -3
  16. package/dist/features/layout/adapters/inbound/ZoraWebStyleSheet.js.map +1 -1
  17. package/package.json +2 -2
  18. package/src/features/carousel/Carousel.tsx +27 -5
  19. package/src/features/form/select/adapters/inbound/Select.web.tsx +13 -10
  20. package/src/features/form/select/composition/SelectOptionsList.tsx +29 -0
  21. package/src/features/layout/adapters/inbound/ZoraWebStyleSheet.tsx +4 -5
  22. package/src/webPackageExports.test.ts +40 -0
  23. package/web-dist/authoring/index.d.ts +2 -2
  24. package/web-dist/authoring/index.js +132 -23545
  25. package/web-dist/chunks/{Accordion-nh0cs9hq.js → Accordion-0g45tq8n.js} +1 -43
  26. package/web-dist/chunks/{Accordion-rhjddvkh.js → Accordion-0zk0xp73.js} +26 -27
  27. package/web-dist/chunks/{Accordion-arr9ayv0.js → Accordion-25v2vczc.js} +12 -18
  28. package/web-dist/chunks/{Accordion-mpb070cf.js → Accordion-2berhsg5.js} +27 -33
  29. package/web-dist/chunks/Accordion-2ej7s27r.js +18 -0
  30. package/web-dist/chunks/{Accordion-tdrk9cyn.js → Accordion-2jcas7qq.js} +8 -8
  31. package/web-dist/chunks/{Accordion-ar8qe05j.js → Accordion-3xfqmr1r.js} +4 -4
  32. package/web-dist/chunks/Accordion-457amtv7.js +4721 -0
  33. package/web-dist/chunks/{Accordion-8skz71ct.js → Accordion-6gc0jw1n.js} +25 -30
  34. package/web-dist/chunks/{Accordion-ytf9ba8v.js → Accordion-73p2mg3h.js} +10 -10
  35. package/web-dist/chunks/Accordion-778fjjsh.js +117 -0
  36. package/web-dist/chunks/Accordion-7ayxbm7k.js +20 -0
  37. package/web-dist/chunks/{Accordion-kcspvk6q.js → Accordion-7pgh8q4h.js} +9 -11
  38. package/web-dist/chunks/Accordion-9dq115tn.js +99 -0
  39. package/web-dist/chunks/Accordion-casb2ndy.js +171 -0
  40. package/web-dist/chunks/{Accordion-9d38cgqj.js → Accordion-cwx73cjc.js} +4 -1426
  41. package/web-dist/chunks/{Accordion-1fz55hk4.js → Accordion-d15mjc4n.js} +5 -4
  42. package/web-dist/chunks/Accordion-dcjzxzv3.js +103 -0
  43. package/web-dist/chunks/{Accordion-htvmkx8s.js → Accordion-dv5c27w4.js} +105 -41
  44. package/web-dist/chunks/Accordion-e6ettgh0.js +219 -0
  45. package/web-dist/chunks/Accordion-e8tapf5a.js +22 -0
  46. package/web-dist/chunks/{Accordion-yrac5a7m.js → Accordion-fkftnxgw.js} +7 -17
  47. package/web-dist/chunks/Accordion-fsdgssfq.js +20 -0
  48. package/web-dist/chunks/{Accordion-jtgh2tep.js → Accordion-g5pvs1aa.js} +24 -30
  49. package/web-dist/chunks/Accordion-gnkzvj03.js +40 -0
  50. package/web-dist/chunks/Accordion-hadw5304.js +78 -0
  51. package/web-dist/chunks/{Accordion-1g91we37.js → Accordion-hg4db1sk.js} +48 -205
  52. package/web-dist/chunks/Accordion-k9n1yse4.js +234 -0
  53. package/web-dist/chunks/{Accordion-0spfxhpg.js → Accordion-m3tq2vcc.js} +22 -28
  54. package/web-dist/chunks/{Accordion-2ad57stc.js → Accordion-mw8zh0vs.js} +12 -12
  55. package/web-dist/chunks/{Accordion-5mga7hty.js → Accordion-pr1tv6jx.js} +3 -5
  56. package/web-dist/chunks/{Accordion-zd15byha.js → Accordion-pvcdvh3w.js} +2 -2
  57. package/web-dist/chunks/{Accordion-0egwarcs.js → Accordion-q8ymmar7.js} +8 -8
  58. package/web-dist/chunks/{Accordion-19aegsx2.js → Accordion-qwftammh.js} +21 -22
  59. package/web-dist/chunks/{Accordion-d5sz8vaq.js → Accordion-r8swmfjm.js} +5 -7
  60. package/web-dist/chunks/{Accordion-bexwrnfh.js → Accordion-rp9cjtpg.js} +28 -34
  61. package/web-dist/chunks/{Accordion-qjxx43r1.js → Accordion-rsw5jt7m.js} +40 -48
  62. package/web-dist/chunks/Accordion-se0pee16.js +213 -0
  63. package/web-dist/chunks/{Accordion-3zzzw7a8.js → Accordion-t9w365ke.js} +3 -5
  64. package/web-dist/chunks/Accordion-tb0vc91c.js +203 -0
  65. package/web-dist/chunks/{Accordion-3cpkxpdg.js → Accordion-tj4fe6wk.js} +5 -5
  66. package/web-dist/chunks/{Accordion-agt9vt85.js → Accordion-v3bmbnfh.js} +13 -13
  67. package/web-dist/chunks/{Accordion-516n2cx4.js → Accordion-vbz1mjm6.js} +43 -168
  68. package/web-dist/chunks/{Accordion-9dk62zn9.js → Accordion-vdzyhtyd.js} +66 -48
  69. package/web-dist/chunks/{Accordion-9m5asd8r.js → Accordion-vtbs98r4.js} +9 -15
  70. package/web-dist/chunks/Accordion-vwqf8kn1.js +70 -0
  71. package/web-dist/chunks/{Accordion-gs838h0n.js → Accordion-w2kx944a.js} +8 -10
  72. package/web-dist/chunks/Accordion-wbf7gqrm.js +136 -0
  73. package/web-dist/chunks/{Accordion-b1y5mjac.js → Accordion-x1ze1wvk.js} +1 -4
  74. package/web-dist/chunks/{Accordion-8t6vh482.js → Accordion-xhkphta6.js} +15 -21
  75. package/web-dist/chunks/Accordion-xqkkfwkm.js +61 -0
  76. package/web-dist/chunks/{Accordion-77514sk9.js → Accordion-yca8r7kx.js} +6 -6
  77. package/web-dist/chunks/{Accordion-tk8zf9ff.js → Accordion-zhgty1ae.js} +10 -35
  78. package/web-dist/chunks/{Accordion-78astqx3.js → Accordion-zmrbktd8.js} +100 -170
  79. package/web-dist/chunks/{RichTextClient-7qqj2dpw.js → RichTextClient-w75r2x97.js} +19 -31
  80. package/web-dist/chunks/{Video.native-6142s9f7.js → Video.native-bb9g33nd.js} +22 -32
  81. package/web-dist/chunks/{index-n6p0wdvg.js → index-m1y984nz.js} +547 -241
  82. package/web-dist/components/accordion/Accordion.dependency-0.d.ts +1 -1
  83. package/web-dist/components/accordion/Accordion.js +8 -14
  84. package/web-dist/components/accordion/Accordion.types-0.d.ts +1 -1
  85. package/web-dist/components/accordion-item/AccordionItem.dependency-0.d.ts +1 -1
  86. package/web-dist/components/accordion-item/AccordionItem.js +8 -14
  87. package/web-dist/components/accordion-item/AccordionItem.types-0.d.ts +1 -1
  88. package/web-dist/components/activity-indicator/ActivityIndicator.js +3 -4
  89. package/web-dist/components/app-bar/AppBar.dependency-0.d.ts +1 -1
  90. package/web-dist/components/app-bar/AppBar.dependency-2.d.ts +1 -1
  91. package/web-dist/components/app-bar/AppBar.js +10 -27
  92. package/web-dist/components/app-bar/AppBar.types-0.d.ts +1 -1
  93. package/web-dist/components/app-header/AppHeader.dependency-0.d.ts +1 -1
  94. package/web-dist/components/app-header/AppHeader.dependency-1.d.ts +1 -1
  95. package/web-dist/components/app-header/AppHeader.dependency-3.d.ts +1 -1
  96. package/web-dist/components/app-header/AppHeader.js +10 -27
  97. package/web-dist/components/app-shell/AppShell.dependency-0.d.ts +1 -1
  98. package/web-dist/components/app-shell/AppShell.js +3 -8
  99. package/web-dist/components/audio/Audio.dependency-0.d.ts +1 -1
  100. package/web-dist/components/audio/Audio.js +17 -28
  101. package/web-dist/components/auth-screen/AuthScreen.dependency-0.d.ts +1 -1
  102. package/web-dist/components/auth-screen/AuthScreen.dependency-3.d.ts +1 -1
  103. package/web-dist/components/auth-screen/AuthScreen.dependency-4.d.ts +1 -1
  104. package/web-dist/components/auth-screen/AuthScreen.js +13 -25
  105. package/web-dist/components/auth-screen/AuthScreen.types-0.d.ts +1 -1
  106. package/web-dist/components/avatar/Avatar.dependency-0.d.ts +1 -1
  107. package/web-dist/components/avatar/Avatar.dependency-2.d.ts +1 -1
  108. package/web-dist/components/avatar/Avatar.js +8 -14
  109. package/web-dist/components/avatar/Avatar.types-0.d.ts +1 -1
  110. package/web-dist/components/avatar-group/AvatarGroup.dependency-1.d.ts +1 -1
  111. package/web-dist/components/avatar-group/AvatarGroup.dependency-3.d.ts +1 -1
  112. package/web-dist/components/avatar-group/AvatarGroup.js +8 -14
  113. package/web-dist/components/avatar-group/AvatarGroup.types-0.d.ts +1 -1
  114. package/web-dist/components/badge/Badge.dependency-0.d.ts +1 -1
  115. package/web-dist/components/badge/Badge.dependency-2.d.ts +1 -1
  116. package/web-dist/components/badge/Badge.dependency-3.d.ts +1 -1
  117. package/web-dist/components/badge/Badge.js +3 -10
  118. package/web-dist/components/badge/Badge.types-0.d.ts +1 -1
  119. package/web-dist/components/barcode-scanner-view/BarcodeScannerView.dependency-0.d.ts +1 -1
  120. package/web-dist/components/barcode-scanner-view/BarcodeScannerView.js +13 -25
  121. package/web-dist/components/bottom-sheet/BottomSheet.dependency-0.d.ts +1 -1
  122. package/web-dist/components/bottom-sheet/BottomSheet.js +5 -13
  123. package/web-dist/components/bottom-sheet-flat-list/BottomSheetFlatList.d.ts +1 -1
  124. package/web-dist/components/bottom-sheet-flat-list/BottomSheetFlatList.js +5 -13
  125. package/web-dist/components/bottom-sheet-scroll-view/BottomSheetScrollView.d.ts +1 -1
  126. package/web-dist/components/bottom-sheet-scroll-view/BottomSheetScrollView.js +5 -13
  127. package/web-dist/components/bottom-sheet-section-list/BottomSheetSectionList.d.ts +1 -1
  128. package/web-dist/components/bottom-sheet-section-list/BottomSheetSectionList.js +5 -13
  129. package/web-dist/components/bottom-sheet-view/BottomSheetView.d.ts +1 -1
  130. package/web-dist/components/bottom-sheet-view/BottomSheetView.js +5 -13
  131. package/web-dist/components/bottom-sheet-virtualized-list/BottomSheetVirtualizedList.d.ts +1 -1
  132. package/web-dist/components/bottom-sheet-virtualized-list/BottomSheetVirtualizedList.js +5 -13
  133. package/web-dist/components/breadcrumbs/Breadcrumbs.dependency-0.d.ts +1 -1
  134. package/web-dist/components/breadcrumbs/Breadcrumbs.js +17 -27
  135. package/web-dist/components/breadcrumbs/Breadcrumbs.types-0.d.ts +1 -1
  136. package/web-dist/components/button/Button.dependency-0.d.ts +1 -1
  137. package/web-dist/components/button/Button.dependency-2.d.ts +1 -1
  138. package/web-dist/components/button/Button.dependency-3.d.ts +1 -1
  139. package/web-dist/components/button/Button.js +8 -18
  140. package/web-dist/components/button/Button.types-0.d.ts +1 -1
  141. package/web-dist/components/button-group/ButtonGroup.dependency-0.d.ts +1 -1
  142. package/web-dist/components/button-group/ButtonGroup.dependency-2.d.ts +1 -1
  143. package/web-dist/components/button-group/ButtonGroup.js +6 -16
  144. package/web-dist/components/calendar/Calendar.dependency-0.d.ts +1 -1
  145. package/web-dist/components/calendar/Calendar.js +9 -19
  146. package/web-dist/components/camera-permission-view/CameraPermissionView.dependency-0.d.ts +1 -1
  147. package/web-dist/components/camera-permission-view/CameraPermissionView.dependency-2.d.ts +1 -1
  148. package/web-dist/components/camera-permission-view/CameraPermissionView.dependency-3.d.ts +1 -1
  149. package/web-dist/components/camera-permission-view/CameraPermissionView.dependency-4.d.ts +1 -1
  150. package/web-dist/components/camera-permission-view/CameraPermissionView.js +13 -25
  151. package/web-dist/components/card/Card.dependency-0.d.ts +1 -1
  152. package/web-dist/components/card/Card.js +12 -24
  153. package/web-dist/components/card/Card.types-0.d.ts +1 -1
  154. package/web-dist/components/card-back/CardBack.dependency-0.d.ts +1 -1
  155. package/web-dist/components/card-back/CardBack.js +5 -6
  156. package/web-dist/components/card-hand/CardHand.dependency-0.d.ts +1 -1
  157. package/web-dist/components/card-hand/CardHand.js +5 -6
  158. package/web-dist/components/carousel/Carousel.js +58 -49
  159. package/web-dist/components/chat-list-item/ChatListItem.dependency-1.d.ts +1 -1
  160. package/web-dist/components/chat-list-item/ChatListItem.dependency-3.d.ts +1 -1
  161. package/web-dist/components/chat-list-item/ChatListItem.js +10 -19
  162. package/web-dist/components/checkbox/Checkbox.dependency-0.d.ts +1 -1
  163. package/web-dist/components/checkbox/Checkbox.js +7 -17
  164. package/web-dist/components/checkbox/Checkbox.types-0.d.ts +1 -1
  165. package/web-dist/components/checkbox-group/CheckboxGroup.dependency-0.d.ts +1 -1
  166. package/web-dist/components/checkbox-group/CheckboxGroup.js +7 -17
  167. package/web-dist/components/checkbox-group/CheckboxGroup.types-0.d.ts +1 -1
  168. package/web-dist/components/chess-board/ChessBoard.dependency-0.d.ts +1 -1
  169. package/web-dist/components/chess-board/ChessBoard.js +5 -7
  170. package/web-dist/components/chip/Chip.dependency-0.d.ts +1 -1
  171. package/web-dist/components/chip/Chip.dependency-2.d.ts +1 -1
  172. package/web-dist/components/chip/Chip.dependency-3.d.ts +1 -1
  173. package/web-dist/components/chip/Chip.js +8 -15
  174. package/web-dist/components/chip/Chip.types-0.d.ts +1 -1
  175. package/web-dist/components/chip-group/ChipGroup.dependency-0.d.ts +1 -1
  176. package/web-dist/components/chip-group/ChipGroup.dependency-2.d.ts +1 -1
  177. package/web-dist/components/chip-group/ChipGroup.dependency-3.d.ts +1 -1
  178. package/web-dist/components/chip-group/ChipGroup.js +8 -15
  179. package/web-dist/components/chip-group/ChipGroup.types-0.d.ts +1 -1
  180. package/web-dist/components/collection-editor/CollectionEditor.dependency-0.d.ts +1 -1
  181. package/web-dist/components/collection-editor/CollectionEditor.js +19 -31
  182. package/web-dist/components/color-hue-scale/ColorHueScale.dependency-0.d.ts +1 -1
  183. package/web-dist/components/color-hue-scale/ColorHueScale.js +19 -35
  184. package/web-dist/components/color-picker/ColorPicker.dependency-0.d.ts +1 -1
  185. package/web-dist/components/color-picker/ColorPicker.js +19 -35
  186. package/web-dist/components/color-tone/ColorTone.dependency-0.d.ts +1 -1
  187. package/web-dist/components/color-tone/ColorTone.js +19 -35
  188. package/web-dist/components/color-wheel/ColorWheel.dependency-0.d.ts +1 -1
  189. package/web-dist/components/color-wheel/ColorWheel.js +19 -35
  190. package/web-dist/components/content-rail/ContentRail.dependency-0.d.ts +1 -1
  191. package/web-dist/components/content-rail/ContentRail.js +23 -35
  192. package/web-dist/components/data-table/DataTable.dependency-0.d.ts +1 -1
  193. package/web-dist/components/data-table/DataTable.dependency-2.d.ts +1 -1
  194. package/web-dist/components/data-table/DataTable.js +67 -101
  195. package/web-dist/components/data-table/DataTable.types-0.d.ts +1 -1
  196. package/web-dist/components/date-picker/DatePicker.dependency-0.d.ts +1 -1
  197. package/web-dist/components/date-picker/DatePicker.js +16 -32
  198. package/web-dist/components/dialog/Dialog.dependency-0.d.ts +1 -1
  199. package/web-dist/components/dialog/Dialog.js +7 -18
  200. package/web-dist/components/divider/Divider.dependency-0.d.ts +1 -1
  201. package/web-dist/components/divider/Divider.js +3 -8
  202. package/web-dist/components/divider/Divider.types-0.d.ts +1 -1
  203. package/web-dist/components/empty-state/EmptyState.dependency-0.d.ts +1 -1
  204. package/web-dist/components/empty-state/EmptyState.dependency-2.d.ts +1 -1
  205. package/web-dist/components/empty-state/EmptyState.dependency-3.d.ts +1 -1
  206. package/web-dist/components/empty-state/EmptyState.js +13 -25
  207. package/web-dist/components/explorer/Explorer.dependency-0.d.ts +1 -1
  208. package/web-dist/components/explorer/Explorer.js +10 -16
  209. package/web-dist/components/field/Field.dependency-0.d.ts +1 -1
  210. package/web-dist/components/field/Field.dependency-1.d.ts +1 -1
  211. package/web-dist/components/field/Field.js +7 -15
  212. package/web-dist/components/file-explorer/FileExplorer.dependency-0.d.ts +1 -1
  213. package/web-dist/components/file-explorer/FileExplorer.js +10 -16
  214. package/web-dist/components/flat-list/FlatList.dependency-0.d.ts +1 -1
  215. package/web-dist/components/flat-list/FlatList.js +8 -17
  216. package/web-dist/components/forgot-password-form/ForgotPasswordForm.dependency-0.d.ts +1 -1
  217. package/web-dist/components/forgot-password-form/ForgotPasswordForm.dependency-3.d.ts +1 -1
  218. package/web-dist/components/forgot-password-form/ForgotPasswordForm.dependency-4.d.ts +1 -1
  219. package/web-dist/components/forgot-password-form/ForgotPasswordForm.js +13 -25
  220. package/web-dist/components/form/Form.dependency-0.d.ts +1 -1
  221. package/web-dist/components/form/Form.js +9 -20
  222. package/web-dist/components/form-actions/FormActions.dependency-0.d.ts +1 -1
  223. package/web-dist/components/form-actions/FormActions.js +9 -20
  224. package/web-dist/components/form-error/FormError.dependency-0.d.ts +1 -1
  225. package/web-dist/components/form-error/FormError.js +9 -20
  226. package/web-dist/components/game/Game.dependency-0.d.ts +1 -1
  227. package/web-dist/components/game/Game.js +4 -10
  228. package/web-dist/components/game-entity/GameEntity.dependency-0.d.ts +1 -1
  229. package/web-dist/components/game-entity/GameEntity.js +4 -10
  230. package/web-dist/components/game-field/GameField.dependency-0.d.ts +1 -1
  231. package/web-dist/components/game-field/GameField.js +4 -10
  232. package/web-dist/components/game-input-zone/GameInputZone.dependency-0.d.ts +1 -1
  233. package/web-dist/components/game-input-zone/GameInputZone.js +4 -10
  234. package/web-dist/components/game-measurement-probe/GameMeasurementProbe.dependency-0.d.ts +1 -1
  235. package/web-dist/components/game-measurement-probe/GameMeasurementProbe.js +4 -10
  236. package/web-dist/components/game-overlay/GameOverlay.dependency-0.d.ts +1 -1
  237. package/web-dist/components/game-overlay/GameOverlay.js +4 -10
  238. package/web-dist/components/gradient/Gradient.dependency-0.d.ts +1 -1
  239. package/web-dist/components/gradient/Gradient.dependency-2.d.ts +1 -1
  240. package/web-dist/components/gradient/Gradient.js +4 -9
  241. package/web-dist/components/gradient-renderer-provider/GradientRendererProvider.js +4 -9
  242. package/web-dist/components/graph-view/GraphView.js +3 -5
  243. package/web-dist/components/grid/Grid.dependency-0.d.ts +1 -1
  244. package/web-dist/components/grid/Grid.js +3 -8
  245. package/web-dist/components/grid/Grid.types-0.d.ts +1 -1
  246. package/web-dist/components/grid-interactions/GridInteractions.dependency-0.d.ts +1 -1
  247. package/web-dist/components/grid-interactions/GridInteractions.js +2 -8
  248. package/web-dist/components/grid-line-overlay/GridLineOverlay.dependency-0.d.ts +1 -1
  249. package/web-dist/components/grid-line-overlay/GridLineOverlay.js +4 -6
  250. package/web-dist/components/grid-ruler/GridRuler.dependency-0.d.ts +1 -1
  251. package/web-dist/components/grid-ruler/GridRuler.js +4 -6
  252. package/web-dist/components/grid-view/GridView.dependency-0.d.ts +1 -1
  253. package/web-dist/components/grid-view/GridView.js +1 -2
  254. package/web-dist/components/heading/Heading.dependency-0.d.ts +1 -1
  255. package/web-dist/components/heading/Heading.dependency-2.d.ts +1 -1
  256. package/web-dist/components/heading/Heading.js +5 -8
  257. package/web-dist/components/heading/Heading.types-0.d.ts +1 -1
  258. package/web-dist/components/hero/Hero.dependency-0.d.ts +1 -1
  259. package/web-dist/components/hero/Hero.dependency-2.d.ts +1 -1
  260. package/web-dist/components/hero/Hero.dependency-3.d.ts +1 -1
  261. package/web-dist/components/hero/Hero.js +20 -32
  262. package/web-dist/components/icon/Icon.dependency-0.d.ts +1 -1
  263. package/web-dist/components/icon/Icon.js +3 -7
  264. package/web-dist/components/icon/Icon.types-0.d.ts +1 -1
  265. package/web-dist/components/icon-button/IconButton.dependency-0.d.ts +1 -1
  266. package/web-dist/components/icon-button/IconButton.dependency-2.d.ts +1 -1
  267. package/web-dist/components/icon-button/IconButton.dependency-3.d.ts +1 -1
  268. package/web-dist/components/icon-button/IconButton.dependency-4.d.ts +1 -1
  269. package/web-dist/components/icon-button/IconButton.js +6 -16
  270. package/web-dist/components/icon-button/IconButton.types-0.d.ts +1 -1
  271. package/web-dist/components/image/Image.dependency-0.d.ts +1 -1
  272. package/web-dist/components/image/Image.js +6 -12
  273. package/web-dist/components/image/Image.types-0.d.ts +1 -1
  274. package/web-dist/components/keyboard-avoiding-view/KeyboardAvoidingView.dependency-0.d.ts +1 -1
  275. package/web-dist/components/keyboard-avoiding-view/KeyboardAvoidingView.js +3 -5
  276. package/web-dist/components/keyboard-avoiding-view/KeyboardAvoidingView.types-0.d.ts +1 -1
  277. package/web-dist/components/link/Link.dependency-0.d.ts +1 -1
  278. package/web-dist/components/link/Link.dependency-3.d.ts +1 -1
  279. package/web-dist/components/link/Link.js +9 -12
  280. package/web-dist/components/link/Link.types-0.d.ts +1 -1
  281. package/web-dist/components/list/List.dependency-0.d.ts +1 -1
  282. package/web-dist/components/list/List.js +8 -17
  283. package/web-dist/components/list/List.types-0.d.ts +1 -1
  284. package/web-dist/components/list-item/ListItem.dependency-0.d.ts +1 -1
  285. package/web-dist/components/list-item/ListItem.js +8 -17
  286. package/web-dist/components/list-item/ListItem.types-0.d.ts +1 -1
  287. package/web-dist/components/list-section/ListSection.dependency-0.d.ts +1 -1
  288. package/web-dist/components/list-section/ListSection.js +8 -17
  289. package/web-dist/components/list-section/ListSection.types-0.d.ts +1 -1
  290. package/web-dist/components/master-detail/MasterDetail.dependency-0.d.ts +1 -1
  291. package/web-dist/components/master-detail/MasterDetail.js +4 -17
  292. package/web-dist/components/matrix-grid/MatrixGrid.dependency-0.d.ts +1 -1
  293. package/web-dist/components/matrix-grid/MatrixGrid.js +14 -23
  294. package/web-dist/components/media-card/MediaCard.dependency-0.d.ts +1 -1
  295. package/web-dist/components/media-card/MediaCard.js +12 -24
  296. package/web-dist/components/media-explorer/MediaExplorer.dependency-0.d.ts +1 -1
  297. package/web-dist/components/media-explorer/MediaExplorer.js +10 -16
  298. package/web-dist/components/message-bubble/MessageBubble.dependency-1.d.ts +1 -1
  299. package/web-dist/components/message-bubble/MessageBubble.dependency-3.d.ts +1 -1
  300. package/web-dist/components/message-bubble/MessageBubble.js +10 -19
  301. package/web-dist/components/metric-card/MetricCard.dependency-0.d.ts +1 -1
  302. package/web-dist/components/metric-card/MetricCard.dependency-3.d.ts +1 -1
  303. package/web-dist/components/metric-card/MetricCard.js +12 -24
  304. package/web-dist/components/metric-card/MetricCard.types-0.d.ts +1 -1
  305. package/web-dist/components/missing-element/MissingElement.dependency-0.d.ts +1 -1
  306. package/web-dist/components/missing-element/MissingElement.js +15 -27
  307. package/web-dist/components/o-auth-provider-button/OAuthProviderButton.dependency-0.d.ts +1 -1
  308. package/web-dist/components/o-auth-provider-button/OAuthProviderButton.dependency-2.d.ts +1 -1
  309. package/web-dist/components/o-auth-provider-button/OAuthProviderButton.dependency-3.d.ts +1 -1
  310. package/web-dist/components/o-auth-provider-button/OAuthProviderButton.dependency-4.d.ts +1 -1
  311. package/web-dist/components/o-auth-provider-button/OAuthProviderButton.js +13 -25
  312. package/web-dist/components/o-auth-provider-button/OAuthProviderButton.types-0.d.ts +1 -1
  313. package/web-dist/components/o-auth-provider-list/OAuthProviderList.dependency-0.d.ts +1 -1
  314. package/web-dist/components/o-auth-provider-list/OAuthProviderList.dependency-2.d.ts +1 -1
  315. package/web-dist/components/o-auth-provider-list/OAuthProviderList.dependency-3.d.ts +1 -1
  316. package/web-dist/components/o-auth-provider-list/OAuthProviderList.dependency-4.d.ts +1 -1
  317. package/web-dist/components/o-auth-provider-list/OAuthProviderList.js +13 -25
  318. package/web-dist/components/o-auth-provider-list/OAuthProviderList.types-0.d.ts +1 -1
  319. package/web-dist/components/opening-book/OpeningBook.dependency-0.d.ts +1 -1
  320. package/web-dist/components/opening-book/OpeningBook.js +5 -7
  321. package/web-dist/components/otp-form/OtpForm.dependency-0.d.ts +1 -1
  322. package/web-dist/components/otp-form/OtpForm.dependency-3.d.ts +1 -1
  323. package/web-dist/components/otp-form/OtpForm.dependency-4.d.ts +1 -1
  324. package/web-dist/components/otp-form/OtpForm.js +13 -25
  325. package/web-dist/components/pagination/Pagination.dependency-0.d.ts +1 -1
  326. package/web-dist/components/pagination/Pagination.js +16 -26
  327. package/web-dist/components/palette-item/PaletteItem.dependency-0.d.ts +1 -1
  328. package/web-dist/components/palette-item/PaletteItem.js +17 -29
  329. package/web-dist/components/palette-item/PaletteItem.types-0.d.ts +1 -1
  330. package/web-dist/components/playing-card/PlayingCard.dependency-0.d.ts +1 -1
  331. package/web-dist/components/playing-card/PlayingCard.js +5 -6
  332. package/web-dist/components/poker-training-table/PokerTrainingTable.dependency-0.d.ts +1 -1
  333. package/web-dist/components/poker-training-table/PokerTrainingTable.js +5 -6
  334. package/web-dist/components/popover/Popover.dependency-0.d.ts +1 -1
  335. package/web-dist/components/popover/Popover.js +4 -10
  336. package/web-dist/components/popover/Popover.types-0.d.ts +1 -1
  337. package/web-dist/components/popover-menu/PopoverMenu.dependency-0.d.ts +1 -1
  338. package/web-dist/components/popover-menu/PopoverMenu.js +6 -21
  339. package/web-dist/components/popover-menu/PopoverMenu.types-0.d.ts +1 -1
  340. package/web-dist/components/post-card/PostCard.dependency-1.d.ts +1 -1
  341. package/web-dist/components/post-card/PostCard.dependency-4.d.ts +1 -1
  342. package/web-dist/components/post-card/PostCard.js +12 -24
  343. package/web-dist/components/post-card/PostCard.types-0.d.ts +1 -1
  344. package/web-dist/components/product-card/ProductCard.dependency-0.d.ts +1 -1
  345. package/web-dist/components/product-card/ProductCard.js +12 -24
  346. package/web-dist/components/progress/Progress.dependency-0.d.ts +1 -1
  347. package/web-dist/components/progress/Progress.dependency-2.d.ts +1 -1
  348. package/web-dist/components/progress/Progress.dependency-3.d.ts +1 -1
  349. package/web-dist/components/progress/Progress.js +7 -12
  350. package/web-dist/components/progress-ring/ProgressRing.dependency-0.d.ts +1 -1
  351. package/web-dist/components/progress-ring/ProgressRing.dependency-2.d.ts +1 -1
  352. package/web-dist/components/progress-ring/ProgressRing.js +7 -12
  353. package/web-dist/components/radio/Radio.dependency-0.d.ts +1 -1
  354. package/web-dist/components/radio/Radio.js +8 -19
  355. package/web-dist/components/radio/Radio.types-0.d.ts +1 -1
  356. package/web-dist/components/radio-group/RadioGroup.dependency-0.d.ts +1 -1
  357. package/web-dist/components/radio-group/RadioGroup.dependency-2.d.ts +1 -1
  358. package/web-dist/components/radio-group/RadioGroup.js +8 -19
  359. package/web-dist/components/radio-group/RadioGroup.types-0.d.ts +1 -1
  360. package/web-dist/components/rating/Rating.dependency-0.d.ts +1 -1
  361. package/web-dist/components/rating/Rating.dependency-2.d.ts +1 -1
  362. package/web-dist/components/rating/Rating.dependency-3.d.ts +1 -1
  363. package/web-dist/components/rating/Rating.js +7 -13
  364. package/web-dist/components/reader/Reader.dependency-0.d.ts +1 -1
  365. package/web-dist/components/reader/Reader.js +25 -45
  366. package/web-dist/components/rich-text/RichText.dependency-0.d.ts +1 -1
  367. package/web-dist/components/rich-text/RichText.js +5 -6
  368. package/web-dist/components/scan-overlay/ScanOverlay.dependency-0.d.ts +1 -1
  369. package/web-dist/components/scan-overlay/ScanOverlay.js +13 -25
  370. package/web-dist/components/screen/Screen.dependency-0.d.ts +1 -1
  371. package/web-dist/components/screen/Screen.js +3 -8
  372. package/web-dist/components/screen-section/ScreenSection.dependency-0.d.ts +1 -1
  373. package/web-dist/components/screen-section/ScreenSection.js +7 -12
  374. package/web-dist/components/scroll-view/ScrollView.dependency-0.d.ts +1 -1
  375. package/web-dist/components/scroll-view/ScrollView.js +3 -8
  376. package/web-dist/components/scroll-view/ScrollView.types-0.d.ts +1 -1
  377. package/web-dist/components/search-input/SearchInput.dependency-0.d.ts +1 -1
  378. package/web-dist/components/search-input/SearchInput.dependency-2.d.ts +1 -1
  379. package/web-dist/components/search-input/SearchInput.js +8 -18
  380. package/web-dist/components/section-header/SectionHeader.dependency-0.d.ts +1 -1
  381. package/web-dist/components/section-header/SectionHeader.js +7 -12
  382. package/web-dist/components/section-list/SectionList.dependency-0.d.ts +1 -1
  383. package/web-dist/components/section-list/SectionList.js +8 -17
  384. package/web-dist/components/select/Select.dependency-0.d.ts +1 -1
  385. package/web-dist/components/select/Select.dependency-2.d.ts +1 -1
  386. package/web-dist/components/select/Select.js +13 -28
  387. package/web-dist/components/select/Select.types-0.d.ts +1 -1
  388. package/web-dist/components/selectable-item/SelectableItem.dependency-0.d.ts +1 -1
  389. package/web-dist/components/selectable-item/SelectableItem.js +3 -5
  390. package/web-dist/components/selectable-item/SelectableItem.types-0.d.ts +1 -1
  391. package/web-dist/components/selection-provider/SelectionProvider.js +3 -5
  392. package/web-dist/components/selection-provider/SelectionProvider.types-0.d.ts +1 -1
  393. package/web-dist/components/sign-in-form/SignInForm.dependency-0.d.ts +1 -1
  394. package/web-dist/components/sign-in-form/SignInForm.dependency-3.d.ts +1 -1
  395. package/web-dist/components/sign-in-form/SignInForm.dependency-4.d.ts +1 -1
  396. package/web-dist/components/sign-in-form/SignInForm.js +13 -25
  397. package/web-dist/components/sign-up-form/SignUpForm.dependency-0.d.ts +1 -1
  398. package/web-dist/components/sign-up-form/SignUpForm.dependency-3.d.ts +1 -1
  399. package/web-dist/components/sign-up-form/SignUpForm.dependency-4.d.ts +1 -1
  400. package/web-dist/components/sign-up-form/SignUpForm.js +13 -25
  401. package/web-dist/components/skeleton/Skeleton.dependency-0.d.ts +1 -1
  402. package/web-dist/components/skeleton/Skeleton.dependency-2.d.ts +1 -1
  403. package/web-dist/components/skeleton/Skeleton.js +15 -27
  404. package/web-dist/components/skeleton-card/SkeletonCard.dependency-0.d.ts +1 -1
  405. package/web-dist/components/skeleton-card/SkeletonCard.js +15 -27
  406. package/web-dist/components/skeleton-list/SkeletonList.dependency-0.d.ts +1 -1
  407. package/web-dist/components/skeleton-list/SkeletonList.js +15 -27
  408. package/web-dist/components/skeleton-text/SkeletonText.dependency-0.d.ts +1 -1
  409. package/web-dist/components/skeleton-text/SkeletonText.dependency-2.d.ts +1 -1
  410. package/web-dist/components/skeleton-text/SkeletonText.js +15 -27
  411. package/web-dist/components/spatial-grid/SpatialGrid.dependency-0.d.ts +1 -1
  412. package/web-dist/components/spatial-grid/SpatialGrid.js +4 -10
  413. package/web-dist/components/surface/Surface.dependency-0.d.ts +1 -1
  414. package/web-dist/components/surface/Surface.js +3 -10
  415. package/web-dist/components/surface/Surface.types-0.d.ts +1 -1
  416. package/web-dist/components/switch/Switch.dependency-0.d.ts +1 -1
  417. package/web-dist/components/switch/Switch.js +7 -121
  418. package/web-dist/components/switch/Switch.types-0.d.ts +1 -1
  419. package/web-dist/components/tab/Tab.dependency-0.d.ts +1 -1
  420. package/web-dist/components/tab/Tab.js +3 -12
  421. package/web-dist/components/tab/Tab.types-0.d.ts +1 -1
  422. package/web-dist/components/tab-list/TabList.dependency-0.d.ts +1 -1
  423. package/web-dist/components/tab-list/TabList.js +3 -12
  424. package/web-dist/components/tab-list/TabList.types-0.d.ts +1 -1
  425. package/web-dist/components/tab-panel/TabPanel.dependency-0.d.ts +1 -1
  426. package/web-dist/components/tab-panel/TabPanel.js +3 -12
  427. package/web-dist/components/tab-panel/TabPanel.types-0.d.ts +1 -1
  428. package/web-dist/components/tabletop-table/TabletopTable.dependency-0.d.ts +1 -1
  429. package/web-dist/components/tabletop-table/TabletopTable.js +5 -6
  430. package/web-dist/components/tabs/Tabs.dependency-0.d.ts +1 -1
  431. package/web-dist/components/tabs/Tabs.js +3 -12
  432. package/web-dist/components/tabs/Tabs.types-0.d.ts +1 -1
  433. package/web-dist/components/text/Text.dependency-0.d.ts +1 -1
  434. package/web-dist/components/text/Text.dependency-2.d.ts +1 -1
  435. package/web-dist/components/text/Text.js +7 -10
  436. package/web-dist/components/text/Text.types-0.d.ts +1 -1
  437. package/web-dist/components/text-input/TextInput.dependency-0.d.ts +1 -1
  438. package/web-dist/components/text-input/TextInput.dependency-2.d.ts +1 -1
  439. package/web-dist/components/text-input/TextInput.js +9 -19
  440. package/web-dist/components/text-input/TextInput.types-0.d.ts +1 -1
  441. package/web-dist/components/theme-mode-toggle/ThemeModeToggle.dependency-0.d.ts +1 -1
  442. package/web-dist/components/theme-mode-toggle/ThemeModeToggle.dependency-2.d.ts +1 -1
  443. package/web-dist/components/theme-mode-toggle/ThemeModeToggle.dependency-3.d.ts +1 -1
  444. package/web-dist/components/theme-mode-toggle/ThemeModeToggle.dependency-4.d.ts +1 -1
  445. package/web-dist/components/theme-mode-toggle/ThemeModeToggle.dependency-5.d.ts +1 -1
  446. package/web-dist/components/theme-mode-toggle/ThemeModeToggle.js +8 -18
  447. package/web-dist/components/tile-grid/TileGrid.dependency-0.d.ts +1 -1
  448. package/web-dist/components/tile-grid/TileGrid.js +1 -2
  449. package/web-dist/components/time-grid/TimeGrid.dependency-0.d.ts +1 -1
  450. package/web-dist/components/time-grid/TimeGrid.js +6 -12
  451. package/web-dist/components/time-picker/TimePicker.dependency-0.d.ts +1 -1
  452. package/web-dist/components/time-picker/TimePicker.js +18 -39
  453. package/web-dist/components/timeline/Timeline.dependency-0.d.ts +1 -1
  454. package/web-dist/components/timeline/Timeline.dependency-2.d.ts +1 -1
  455. package/web-dist/components/timeline/Timeline.dependency-4.d.ts +1 -1
  456. package/web-dist/components/timeline/Timeline.js +15 -21
  457. package/web-dist/components/timeline/Timeline.types-0.d.ts +1 -1
  458. package/web-dist/components/toast/Toast.dependency-0.d.ts +1 -1
  459. package/web-dist/components/toast/Toast.js +3 -14
  460. package/web-dist/components/toast/Toast.types-0.d.ts +1 -1
  461. package/web-dist/components/toast-provider/ToastProvider.js +3 -14
  462. package/web-dist/components/toast-provider/ToastProvider.types-0.d.ts +1 -1
  463. package/web-dist/components/toolbar/Toolbar.dependency-0.d.ts +1 -1
  464. package/web-dist/components/toolbar/Toolbar.js +13 -25
  465. package/web-dist/components/tree-item/TreeItem.dependency-0.d.ts +1 -1
  466. package/web-dist/components/tree-item/TreeItem.js +16 -32
  467. package/web-dist/components/tree-item/TreeItem.types-0.d.ts +1 -1
  468. package/web-dist/components/tree-view/TreeView.js +1 -1
  469. package/web-dist/components/uploader/Uploader.dependency-0.d.ts +1 -1
  470. package/web-dist/components/uploader/Uploader.js +28 -44
  471. package/web-dist/components/video/Video.dependency-0.d.ts +1 -1
  472. package/web-dist/components/video/Video.dependency-2.d.ts +1 -1
  473. package/web-dist/components/video/Video.js +11 -17
  474. package/web-dist/components/view/View.dependency-0.d.ts +1 -1
  475. package/web-dist/components/view/View.js +3 -8
  476. package/web-dist/components/view/View.types-0.d.ts +1 -1
  477. package/web-dist/components/zora-web-style-sheet/ZoraWebStyleSheet.d.ts +6 -1
  478. package/web-dist/components/zora-web-style-sheet/ZoraWebStyleSheet.js +3 -8
  479. package/web-dist/manifest.json +1104 -2714
  480. package/web-dist/runtime/ZoraProvider.js +19 -178
  481. package/web-dist/chunks/Accordion-0dj1r7w3.js +0 -13528
  482. package/web-dist/chunks/Accordion-224snqz3.js +0 -89
  483. package/web-dist/chunks/Accordion-23k6n6zk.js +0 -278
  484. package/web-dist/chunks/Accordion-2yat0x6x.js +0 -188
  485. package/web-dist/chunks/Accordion-4mg3epm9.js +0 -405
  486. package/web-dist/chunks/Accordion-4qrva6ye.js +0 -15
  487. package/web-dist/chunks/Accordion-4yrszsvs.js +0 -273
  488. package/web-dist/chunks/Accordion-5z75befg.js +0 -69
  489. package/web-dist/chunks/Accordion-61e19g3e.js +0 -1
  490. package/web-dist/chunks/Accordion-6a2hscrx.js +0 -50
  491. package/web-dist/chunks/Accordion-6zb9d92y.js +0 -87
  492. package/web-dist/chunks/Accordion-76b0qz8y.js +0 -41
  493. package/web-dist/chunks/Accordion-7nn4r909.js +0 -81
  494. package/web-dist/chunks/Accordion-7v6mrp8n.js +0 -311
  495. package/web-dist/chunks/Accordion-9b4bsxwe.js +0 -46
  496. package/web-dist/chunks/Accordion-9tgvr155.js +0 -9575
  497. package/web-dist/chunks/Accordion-a5fsrv3x.js +0 -198
  498. package/web-dist/chunks/Accordion-akwd4brm.js +0 -397
  499. package/web-dist/chunks/Accordion-c6edgxay.js +0 -1
  500. package/web-dist/chunks/Accordion-chdbfcm6.js +0 -93
  501. package/web-dist/chunks/Accordion-eqvdv7tt.js +0 -1
  502. package/web-dist/chunks/Accordion-fre84yaq.js +0 -12
  503. package/web-dist/chunks/Accordion-j1zerr6z.js +0 -389
  504. package/web-dist/chunks/Accordion-khfjh10v.js +0 -82
  505. package/web-dist/chunks/Accordion-ktscjwa2.js +0 -213
  506. package/web-dist/chunks/Accordion-mnac2z83.js +0 -21
  507. package/web-dist/chunks/Accordion-mnxf855g.js +0 -121
  508. package/web-dist/chunks/Accordion-mrstcjcm.js +0 -28
  509. package/web-dist/chunks/Accordion-mx7nkg85.js +0 -34
  510. package/web-dist/chunks/Accordion-pdjhezmz.js +0 -43
  511. package/web-dist/chunks/Accordion-q8a423pk.js +0 -379
  512. package/web-dist/chunks/Accordion-qjxbf8nt.js +0 -150
  513. package/web-dist/chunks/Accordion-sfvqf4fz.js +0 -1299
  514. package/web-dist/chunks/Accordion-sj30964p.js +0 -1350
  515. package/web-dist/chunks/Accordion-vx8bjm5k.js +0 -263
  516. package/web-dist/chunks/Accordion-wgc67k1g.js +0 -93
  517. package/web-dist/chunks/Accordion-ww4f12ty.js +0 -200
  518. package/web-dist/chunks/Accordion-xgpzh4wq.js +0 -18061
  519. package/web-dist/chunks/Accordion-xhxv2v0g.js +0 -196
package/CHANGELOG.md CHANGED
@@ -1,5 +1,18 @@
1
1
  # Changelog
2
2
 
3
+ ## 28.7.4
4
+
5
+ ### Patch Changes
6
+
7
+ - 99bf9ce: Render the React Native Web stylesheet with hydration-stable markup while preserving live rule insertion.
8
+
9
+ ## 28.7.3
10
+
11
+ ### Patch Changes
12
+
13
+ - 9e40f10: Keep web Select options in a viewport-bounded scroll container so wheel scrolling, pointer input and selection work inside Dialog and Popover.
14
+ - 9e40f10: Use the published `@ankhorage/surface/web` and consumer `react-native-web` contracts for browser artifacts.
15
+
3
16
  ## 28.7.2
4
17
 
5
18
  ### Patch Changes
package/README.md CHANGED
@@ -3,7 +3,7 @@
3
3
 
4
4
  # ZORA
5
5
 
6
- ![license: MIT](././paradox/badges/license.svg) ![npm: v28.7.2](././paradox/badges/npm.svg) ![runtime: bun](././paradox/badges/runtime.svg) ![typescript: strict](././paradox/badges/typescript.svg) ![eslint: checked](././paradox/badges/eslint.svg) ![prettier: checked](././paradox/badges/prettier.svg) ![build: checked](././paradox/badges/build.svg) ![tests: configured](././paradox/badges/tests.svg) ![paradox: warnings](././paradox/badges/docs.svg)
6
+ ![license: MIT](././paradox/badges/license.svg) ![npm: v28.7.4](././paradox/badges/npm.svg) ![runtime: bun](././paradox/badges/runtime.svg) ![typescript: strict](././paradox/badges/typescript.svg) ![eslint: checked](././paradox/badges/eslint.svg) ![prettier: checked](././paradox/badges/prettier.svg) ![build: checked](././paradox/badges/build.svg) ![tests: configured](././paradox/badges/tests.svg) ![paradox: warnings](././paradox/badges/docs.svg)
7
7
 
8
8
  Provides opinionated React Native and React Native Web UI components, theme primitives, registries, and reader surfaces built on @ankhorage/surface.
9
9
 
@@ -1 +1 @@
1
- {"version":3,"file":"Carousel.d.ts","sourceRoot":"","sources":["../../../src/features/carousel/Carousel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,KAAK,EAAE,aAAa,EAAqC,MAAM,sBAAsB,CAAC;AAI7F;;;GAGG;AACH,wBAAgB,QAAQ,CAAC,EACvB,MAAM,EACN,KAAK,EACL,YAAY,EACZ,aAAa,EACb,QAAQ,EACR,MAAM,EACN,IAAI,EACJ,UAAU,EACV,UAAmB,EACnB,eAAsB,EACtB,cAAoB,EACpB,YAAmB,EACnB,cAAsB,EACtB,aAAa,EACb,YAAmB,EACnB,cAAkB,EAClB,kBAAkB,EAClB,sBAAsB,EACtB,kBAAkB,EAClB,sBAAsB,EACtB,UAAkB,EAClB,cAAsB,EACtB,aAAgC,EAChC,SAAwB,EACxB,YAAY,EACZ,sBAAsB,EACtB,aAAa,EACb,oBAAoB,EACpB,sBAAsB,EACtB,eAAe,EACf,UAAoB,EACpB,UAAU,EACV,KAAK,EACL,WAAW,EACX,MAAM,GACP,EAAE,aAAa,4BAuJf"}
1
+ {"version":3,"file":"Carousel.d.ts","sourceRoot":"","sources":["../../../src/features/carousel/Carousel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,KAAK,EAAE,aAAa,EAAqC,MAAM,sBAAsB,CAAC;AAI7F;;;GAGG;AACH,wBAAgB,QAAQ,CAAC,EACvB,MAAM,EACN,KAAK,EACL,YAAY,EACZ,aAAa,EACb,QAAQ,EACR,MAAM,EACN,IAAI,EACJ,UAAU,EACV,UAAmB,EACnB,eAAsB,EACtB,cAAoB,EACpB,YAAmB,EACnB,cAAsB,EACtB,aAAa,EACb,YAAmB,EACnB,cAAkB,EAClB,kBAAkB,EAClB,sBAAsB,EACtB,kBAAkB,EAClB,sBAAsB,EACtB,UAAkB,EAClB,cAAsB,EACtB,aAAgC,EAChC,SAAwB,EACxB,YAAY,EACZ,sBAAsB,EACtB,aAAa,EACb,oBAAoB,EACpB,sBAAsB,EACtB,eAAe,EACf,UAAoB,EACpB,UAAU,EACV,KAAK,EACL,WAAW,EACX,MAAM,GACP,EAAE,aAAa,4BA6Kf"}
@@ -13,6 +13,7 @@ export function Carousel({ slides, index, defaultIndex, onIndexChange, autoPlay,
13
13
  const initialSlide = slides.at(initialIndex);
14
14
  const [mountedSlideKeys, setMountedSlideKeys] = React.useState(() => initialSlide ? new Set([initialSlide.key]) : new Set());
15
15
  const [readySlideKeys, setReadySlideKeys] = React.useState(() => new Set());
16
+ const [completedSlideKeys, setCompletedSlideKeys] = React.useState(() => new Set());
16
17
  const { activeIndex, controlledWithoutHandler, direction, loop: enabledLoop, navigate, progress, shouldReduceMotion, } = useCarouselPlayback({
17
18
  slides,
18
19
  index,
@@ -41,13 +42,30 @@ export function Carousel({ slides, index, defaultIndex, onIndexChange, autoPlay,
41
42
  transitionStateRef.current = { activeSlideKey, nextSlideKey, readySlideKeys };
42
43
  }, [activeSlideKey, nextSlideKey, readySlideKeys]);
43
44
  // Stable identity: layers run animations from effects, so a changing callback would restart them.
44
- const completeTransition = React.useCallback((completedSlideKey) => {
45
+ const completeTransition = React.useCallback((completedSlideKey, immediate) => {
45
46
  const { activeSlideKey: currentKey, nextSlideKey: currentNextKey, readySlideKeys: ready, } = transitionStateRef.current;
46
47
  if (!currentKey || completedSlideKey !== currentKey)
47
48
  return;
49
+ if (!immediate && !ready.has(currentKey)) {
50
+ setCompletedSlideKeys((current) => ensureMountedSlide(current, currentKey));
51
+ return;
52
+ }
48
53
  const transitionRetentionKeys = [currentKey, currentNextKey].filter((slideKey) => slideKey !== undefined);
49
54
  setMountedSlideKeys((current) => new Set(transitionRetentionKeys.filter((slideKey) => slideKey === currentKey || current.has(slideKey) || ready.has(currentKey))));
55
+ setCompletedSlideKeys((current) => {
56
+ if (!current.has(currentKey))
57
+ return current;
58
+ return new Set([...current].filter((slideKey) => slideKey !== currentKey));
59
+ });
50
60
  }, []);
61
+ React.useLayoutEffect(() => {
62
+ if (!activeSlideKey ||
63
+ !completedSlideKeys.has(activeSlideKey) ||
64
+ !readySlideKeys.has(activeSlideKey)) {
65
+ return;
66
+ }
67
+ completeTransition(activeSlideKey, false);
68
+ }, [activeSlideKey, completedSlideKeys, completeTransition, readySlideKeys]);
51
69
  if (slides.length === 0)
52
70
  return null;
53
71
  const canPrevious = enabledLoop || activeIndex > 0;
@@ -88,7 +106,7 @@ function CarouselLayer({ slide, slideIndex, active, animate, animateOnMount, dir
88
106
  scale.setValue(1);
89
107
  offset.setValue(0);
90
108
  if (active)
91
- onTransitionComplete(slide.key);
109
+ onTransitionComplete(slide.key, true);
92
110
  return;
93
111
  }
94
112
  if (transition === 'slide') {
@@ -112,7 +130,7 @@ function CarouselLayer({ slide, slideIndex, active, animate, animateOnMount, dir
112
130
  }),
113
131
  ]).start(({ finished }) => {
114
132
  if (active && finished)
115
- onTransitionComplete(slide.key);
133
+ onTransitionComplete(slide.key, false);
116
134
  });
117
135
  }
118
136
  else if (active) {
@@ -133,7 +151,7 @@ function CarouselLayer({ slide, slideIndex, active, animate, animateOnMount, dir
133
151
  }),
134
152
  ]).start(({ finished }) => {
135
153
  if (finished)
136
- onTransitionComplete(slide.key);
154
+ onTransitionComplete(slide.key, false);
137
155
  });
138
156
  }
139
157
  else {
@@ -1 +1 @@
1
- {"version":3,"file":"Carousel.js","sourceRoot":"","sources":["../../../src/features/carousel/Carousel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,KAAK,EAAE,SAAS,EAAE,UAAU,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AAG1F,OAAO,EAAE,YAAY,EAAE,MAAM,mCAAmC,CAAC;AACjE,OAAO,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAE5D;;;GAGG;AACH,MAAM,UAAU,QAAQ,CAAC,EACvB,MAAM,EACN,KAAK,EACL,YAAY,EACZ,aAAa,EACb,QAAQ,EACR,MAAM,EACN,IAAI,EACJ,UAAU,EACV,UAAU,GAAG,MAAM,EACnB,eAAe,GAAG,IAAI,EACtB,cAAc,GAAG,GAAG,EACpB,YAAY,GAAG,IAAI,EACnB,cAAc,GAAG,KAAK,EACtB,aAAa,EACb,YAAY,GAAG,IAAI,EACnB,cAAc,GAAG,CAAC,EAClB,kBAAkB,EAClB,sBAAsB,EACtB,kBAAkB,EAClB,sBAAsB,EACtB,UAAU,GAAG,KAAK,EAClB,cAAc,GAAG,KAAK,EACtB,aAAa,GAAG,gBAAgB,EAChC,SAAS,GAAG,YAAY,EACxB,YAAY,EACZ,sBAAsB,EACtB,aAAa,EACb,oBAAoB,EACpB,sBAAsB,EACtB,eAAe,EACf,UAAU,GAAG,OAAO,EACpB,UAAU,EACV,KAAK,EACL,WAAW,EACX,MAAM,GACQ;IACd,MAAM,EAAE,KAAK,EAAE,GAAG,YAAY,EAAE,CAAC;IACjC,MAAM,CAAC,KAAK,EAAE,QAAQ,CAAC,GAAG,KAAK,CAAC,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,EAAE,QAAQ;QACxB,UAAU,EAAE,QAAQ;KACrB;IACD,SAAS,EAAE,EAAE,MAAM,EAAE,CAAC,EAAE,YAAY,EAAE,CAAC,EAAE;IACzC,QAAQ,EAAE,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,EAAE,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,QAAQ,EAAE,QAAQ,EAAE;CACrF,CAAC,CAAC","sourcesContent":["import React from 'react';\nimport { Animated, Easing, Image, Pressable, StyleSheet, Text, View } from 'react-native';\n\nimport type { CarouselProps, CarouselSlide, CarouselTransition } from '../../types/carousel';\nimport { useZoraTheme } from '../theme/composition/useZoraTheme';\nimport { useCarouselPlayback } from './useCarouselPlayback';\n\n/***\n * Present images, arbitrary React content, or both as a cross-platform slideshow.\n * A published web artifact exposes the same API without consumer source imports.\n */\nexport function Carousel({\n slides,\n index,\n defaultIndex,\n onIndexChange,\n autoPlay,\n paused,\n loop,\n intervalMs,\n transition = 'fade',\n enterDurationMs = 1200,\n exitDurationMs = 800,\n initialScale = 1.06,\n animateOnMount = false,\n reducedMotion,\n showProgress = true,\n progressHeight = 4,\n progressTrackColor,\n progressIndicatorColor,\n progressTrackStyle,\n progressIndicatorStyle,\n showArrows = false,\n showIndicators = false,\n previousLabel = 'Previous slide',\n nextLabel = 'Next slide',\n controlColor,\n controlBackgroundColor,\n controlsStyle,\n activeIndicatorColor,\n inactiveIndicatorColor,\n indicatorsStyle,\n resizeMode = 'cover',\n imageStyle,\n style,\n renderImage,\n testID,\n}: CarouselProps) {\n const { theme } = useZoraTheme();\n const [width, setWidth] = React.useState(0);\n const initialIndex = normalizeSlideIndex(index ?? defaultIndex ?? 0, slides.length);\n const initialSlide = slides.at(initialIndex);\n const [mountedSlideKeys, setMountedSlideKeys] = React.useState<ReadonlySet<string>>(() =>\n initialSlide ? new Set([initialSlide.key]) : new Set(),\n );\n const [readySlideKeys, setReadySlideKeys] = React.useState<ReadonlySet<string>>(() => new Set());\n const {\n activeIndex,\n controlledWithoutHandler,\n direction,\n loop: enabledLoop,\n navigate,\n progress,\n shouldReduceMotion,\n } = useCarouselPlayback({\n slides,\n index,\n defaultIndex,\n onIndexChange,\n autoPlay,\n paused,\n loop,\n intervalMs,\n reducedMotion,\n });\n\n const activeSlide = slides.at(activeIndex);\n const nextIndex = getNextSlideIndex(activeIndex, slides.length, enabledLoop);\n const nextSlide = nextIndex === undefined ? undefined : slides.at(nextIndex);\n const activeSlideKey = activeSlide?.key;\n const nextSlideKey = nextSlide?.key;\n const mountedKeys = ensureMountedSlide(\n ensureMountedSlide(mountedSlideKeys, activeSlideKey),\n getPreloadedSlideKey(activeSlideKey, nextSlideKey, readySlideKeys),\n );\n\n const markSlideLoaded = React.useCallback(\n (slideKey: string) => {\n setReadySlideKeys((current) => ensureMountedSlide(current, slideKey));\n if (slideKey === activeSlideKey) {\n setMountedSlideKeys((current) => ensureMountedSlide(current, nextSlideKey));\n }\n },\n [activeSlideKey, nextSlideKey],\n );\n\n const transitionStateRef = React.useRef({ activeSlideKey, nextSlideKey, readySlideKeys });\n React.useLayoutEffect(() => {\n transitionStateRef.current = { activeSlideKey, nextSlideKey, readySlideKeys };\n }, [activeSlideKey, nextSlideKey, readySlideKeys]);\n\n // Stable identity: layers run animations from effects, so a changing callback would restart them.\n const completeTransition = React.useCallback((completedSlideKey: string) => {\n const {\n activeSlideKey: currentKey,\n nextSlideKey: currentNextKey,\n readySlideKeys: ready,\n } = transitionStateRef.current;\n if (!currentKey || completedSlideKey !== currentKey) return;\n const transitionRetentionKeys = [currentKey, currentNextKey].filter(\n (slideKey): slideKey is string => slideKey !== undefined,\n );\n setMountedSlideKeys(\n (current) =>\n new Set(\n transitionRetentionKeys.filter(\n (slideKey) => slideKey === currentKey || current.has(slideKey) || ready.has(currentKey),\n ),\n ),\n );\n }, []);\n\n if (slides.length === 0) return null;\n\n const canPrevious = enabledLoop || activeIndex > 0;\n const canNext = enabledLoop || activeIndex < slides.length - 1;\n const markerColor = activeIndicatorColor ?? theme.colors.primary;\n const idleMarkerColor = inactiveIndicatorColor ?? theme.semantics.neutral.divider;\n\n return (\n <View\n onLayout={(event) => setWidth(event.nativeEvent.layout.width)}\n testID={testID}\n style={[{ position: 'relative', overflow: 'hidden', width: '100%', height: '100%' }, style]}\n >\n {slides.flatMap((slide, slideIndex) =>\n mountedKeys.has(slide.key)\n ? [\n <CarouselLayer\n key={slide.key}\n active={activeIndex === slideIndex}\n animate={slides.length > 1}\n animateOnMount={animateOnMount || activeIndex !== initialIndex}\n direction={direction}\n enterDurationMs={enterDurationMs}\n exitDurationMs={exitDurationMs}\n imageStyle={imageStyle}\n initialScale={initialScale}\n onImageLoad={() => markSlideLoaded(slide.key)}\n onTransitionComplete={completeTransition}\n reducedMotion={shouldReduceMotion}\n renderImage={renderImage}\n resizeMode={resizeMode}\n slide={slide}\n slideIndex={slideIndex}\n transition={transition}\n width={width}\n />,\n ]\n : [],\n )}\n <CarouselControls\n activeIndex={activeIndex}\n canNext={canNext}\n canPrevious={canPrevious}\n controlBackgroundColor={controlBackgroundColor ?? theme.semantics.surface.raised}\n controlColor={controlColor ?? theme.semantics.content.default}\n controlledWithoutHandler={controlledWithoutHandler}\n controlsStyle={controlsStyle}\n navigate={navigate}\n nextLabel={nextLabel}\n previousLabel={previousLabel}\n show={showArrows && slides.length > 1}\n testID={testID}\n />\n <CarouselIndicators\n activeIndex={activeIndex}\n activeColor={markerColor}\n controlledWithoutHandler={controlledWithoutHandler}\n idleColor={idleMarkerColor}\n indicatorsStyle={indicatorsStyle}\n navigate={navigate}\n show={showIndicators && slides.length > 1}\n slides={slides}\n testID={testID}\n />\n <CarouselProgress\n height={progressHeight}\n indicatorColor={progressIndicatorColor ?? theme.colors.primary}\n indicatorStyle={progressIndicatorStyle}\n progress={progress}\n show={showProgress && slides.length > 1}\n testID={testID}\n trackColor={progressTrackColor ?? theme.semantics.neutral.divider}\n trackStyle={progressTrackStyle}\n />\n </View>\n );\n}\n\ninterface CarouselLayerProps {\n readonly enterDurationMs?: CarouselProps['enterDurationMs'];\n readonly exitDurationMs?: CarouselProps['exitDurationMs'];\n readonly imageStyle: CarouselProps['imageStyle'];\n readonly initialScale?: CarouselProps['initialScale'];\n readonly onImageLoad: () => void;\n readonly onTransitionComplete: (slideKey: string) => void;\n readonly renderImage: CarouselProps['renderImage'];\n readonly resizeMode: CarouselProps['resizeMode'];\n readonly slide: CarouselSlide;\n readonly slideIndex: number;\n readonly active: boolean;\n readonly animate: boolean;\n readonly animateOnMount: boolean;\n readonly direction: 1 | -1;\n readonly width: number;\n readonly transition: CarouselTransition;\n readonly reducedMotion: boolean;\n}\n\n/*** Keep departing slides mounted for an animated overlap without unmounting content. */\nfunction CarouselLayer({\n slide,\n slideIndex,\n active,\n animate,\n animateOnMount,\n direction,\n enterDurationMs = 1200,\n exitDurationMs = 800,\n initialScale = 1.06,\n onImageLoad,\n onTransitionComplete,\n reducedMotion,\n renderImage,\n resizeMode,\n imageStyle,\n transition,\n width,\n}: CarouselLayerProps) {\n const [opacity] = React.useState(() => new Animated.Value(active && !animateOnMount ? 1 : 0));\n const [scale] = React.useState(\n () => new Animated.Value(active && animateOnMount ? initialScale : 1),\n );\n const [offset] = React.useState(() => new Animated.Value(0));\n const hasMounted = React.useRef(false);\n const widthRef = React.useRef(width);\n\n React.useEffect(() => {\n widthRef.current = width;\n }, [width]);\n\n React.useEffect(() => {\n const firstRender = !hasMounted.current;\n hasMounted.current = true;\n if (firstRender && !animateOnMount) return;\n opacity.stopAnimation();\n scale.stopAnimation();\n offset.stopAnimation();\n if (!animate || reducedMotion || transition === 'none') {\n opacity.setValue(active ? 1 : 0);\n scale.setValue(1);\n offset.setValue(0);\n if (active) onTransitionComplete(slide.key);\n return;\n }\n if (transition === 'slide') {\n scale.setValue(1);\n if (active) {\n offset.setValue(direction * widthRef.current);\n opacity.setValue(1);\n }\n Animated.parallel([\n Animated.timing(offset, {\n toValue: active ? 0 : -direction * widthRef.current,\n duration: Math.max(0, active ? enterDurationMs : exitDurationMs),\n easing: Easing.bezier(0.4, 0, 0.2, 1),\n useNativeDriver: true,\n }),\n Animated.timing(opacity, {\n toValue: active ? 1 : 0,\n duration: Math.max(0, active ? enterDurationMs : exitDurationMs),\n easing: Easing.linear,\n useNativeDriver: true,\n }),\n ]).start(({ finished }) => {\n if (active && finished) onTransitionComplete(slide.key);\n });\n } else if (active) {\n opacity.setValue(0);\n scale.setValue(initialScale);\n Animated.parallel([\n Animated.timing(opacity, {\n toValue: 1,\n duration: Math.max(0, enterDurationMs),\n easing: Easing.bezier(0.4, 0, 0.2, 1),\n useNativeDriver: true,\n }),\n Animated.timing(scale, {\n toValue: 1,\n duration: Math.max(0, enterDurationMs),\n easing: Easing.bezier(0.4, 0, 0.2, 1),\n useNativeDriver: true,\n }),\n ]).start(({ finished }) => {\n if (finished) onTransitionComplete(slide.key);\n });\n } else {\n Animated.timing(opacity, {\n toValue: 0,\n duration: Math.max(0, exitDurationMs),\n easing: Easing.bezier(0.4, 0, 0.2, 1),\n useNativeDriver: true,\n }).start();\n }\n return () => {\n opacity.stopAnimation();\n scale.stopAnimation();\n offset.stopAnimation();\n };\n }, [\n active,\n animate,\n animateOnMount,\n direction,\n enterDurationMs,\n exitDurationMs,\n initialScale,\n offset,\n opacity,\n reducedMotion,\n scale,\n transition,\n onTransitionComplete,\n slide.key,\n ]);\n\n return (\n <Animated.View\n accessibilityElementsHidden={!active}\n importantForAccessibility={active ? 'auto' : 'no-hide-descendants'}\n pointerEvents={active ? 'auto' : 'none'}\n style={[StyleSheet.absoluteFill, { opacity, transform: [{ scale }, { translateX: offset }] }]}\n >\n {slide.source !== undefined ? (\n renderImage ? (\n renderCarouselImage(renderImage(slide, slideIndex), onImageLoad)\n ) : (\n <Image\n accessibilityLabel={slide.alt}\n accessible={Boolean(slide.alt)}\n resizeMode={resizeMode}\n source={typeof slide.source === 'string' ? { uri: slide.source } : slide.source}\n style={[StyleSheet.absoluteFill, imageStyle]}\n onLoad={onImageLoad}\n />\n )\n ) : null}\n {slide.content}\n </Animated.View>\n );\n}\n\n/*** Retain consumer image behavior while observing readiness for adjacent-slide preloading. */\nfunction renderCarouselImage(image: React.ReactNode, onImageLoad: () => void): React.ReactNode {\n if (!React.isValidElement<{ onLoad?: (event: unknown) => void }>(image)) return image;\n const existingOnLoad = image.props.onLoad;\n return React.cloneElement(image, {\n onLoad: (event: unknown) => {\n existingOnLoad?.(event);\n onImageLoad();\n },\n });\n}\n\n/*** Return an immutable mounted-key set containing one requested slide. */\nfunction ensureMountedSlide(mountedSlideKeys: ReadonlySet<string>, slideKey: string | undefined) {\n if (!slideKey || mountedSlideKeys.has(slideKey)) return mountedSlideKeys;\n return new Set([...mountedSlideKeys, slideKey]);\n}\n\n/*** Return the next slide key only after the active slide image is ready. */\nfunction getPreloadedSlideKey(\n activeSlideKey: string | undefined,\n nextSlideKey: string | undefined,\n readySlideKeys: ReadonlySet<string>,\n) {\n if (!activeSlideKey || !readySlideKeys.has(activeSlideKey)) return undefined;\n return nextSlideKey;\n}\n\n/*** Resolve the slide to preload without wrapping when looping is disabled. */\nfunction getNextSlideIndex(index: number, length: number, loop: boolean): number | undefined {\n if (length < 2 || (!loop && index === length - 1)) return undefined;\n return (index + 1) % length;\n}\n\n/*** Clamp the initial server-rendered slide to the available slide collection. */\nfunction normalizeSlideIndex(index: number, length: number): number {\n if (length === 0) return 0;\n return Math.min(Math.max(Math.trunc(index), 0), length - 1);\n}\n\ninterface CarouselNavigationProps {\n readonly activeIndex: number;\n readonly navigate: (index: number, direction: 1 | -1) => void;\n readonly controlledWithoutHandler: boolean;\n readonly testID: CarouselProps['testID'];\n}\n\ninterface CarouselControlsProps extends CarouselNavigationProps {\n readonly show: boolean;\n readonly canPrevious: boolean;\n readonly canNext: boolean;\n readonly previousLabel: string;\n readonly nextLabel: string;\n readonly controlColor: string;\n readonly controlBackgroundColor: string;\n readonly controlsStyle: CarouselProps['controlsStyle'];\n}\n\n/*** Render optional previous/next buttons without coupling the slide content to navigation. */\nfunction CarouselControls({\n activeIndex,\n canNext,\n canPrevious,\n controlBackgroundColor,\n controlColor,\n controlledWithoutHandler,\n controlsStyle,\n navigate,\n nextLabel,\n previousLabel,\n show,\n testID,\n}: CarouselControlsProps) {\n if (!show) return null;\n const buttonStyle = [styles.control, { backgroundColor: controlBackgroundColor }];\n const labelStyle = { color: controlColor, fontSize: 30 };\n return (\n <View pointerEvents=\"box-none\" style={[styles.controls, controlsStyle]}>\n <Pressable\n accessibilityLabel={previousLabel}\n accessibilityRole=\"button\"\n disabled={!canPrevious || controlledWithoutHandler}\n onPress={() => navigate(activeIndex - 1, -1)}\n style={buttonStyle}\n testID={testID ? `${testID}-previous` : undefined}\n >\n <Text style={labelStyle}>{'‹'}</Text>\n </Pressable>\n <Pressable\n accessibilityLabel={nextLabel}\n accessibilityRole=\"button\"\n disabled={!canNext || controlledWithoutHandler}\n onPress={() => navigate(activeIndex + 1, 1)}\n style={buttonStyle}\n testID={testID ? `${testID}-next` : undefined}\n >\n <Text style={labelStyle}>{'›'}</Text>\n </Pressable>\n </View>\n );\n}\n\ninterface CarouselIndicatorsProps extends CarouselNavigationProps {\n readonly show: boolean;\n readonly slides: CarouselProps['slides'];\n readonly activeColor: string;\n readonly idleColor: string;\n readonly indicatorsStyle: CarouselProps['indicatorsStyle'];\n}\n\n/*** Render accessible selection dots for the currently controlled slide. */\nfunction CarouselIndicators({\n activeIndex,\n activeColor,\n controlledWithoutHandler,\n idleColor,\n indicatorsStyle,\n navigate,\n show,\n slides,\n testID,\n}: CarouselIndicatorsProps) {\n if (!show) return null;\n return (\n <View pointerEvents=\"box-none\" style={[styles.indicators, indicatorsStyle]}>\n {slides.map((slide, slideIndex) => (\n <Pressable\n key={slide.key}\n accessibilityLabel={`Go to slide ${slideIndex + 1} of ${slides.length}`}\n accessibilityRole=\"button\"\n accessibilityState={{ selected: slideIndex === activeIndex }}\n disabled={controlledWithoutHandler}\n onPress={() => navigate(slideIndex, slideIndex < activeIndex ? -1 : 1)}\n style={[\n styles.indicator,\n {\n backgroundColor: slideIndex === activeIndex ? activeColor : idleColor,\n width: slideIndex === activeIndex ? 24 : 8,\n },\n ]}\n testID={testID ? `${testID}-indicator-${slideIndex}` : undefined}\n />\n ))}\n </View>\n );\n}\n\ninterface CarouselProgressProps {\n readonly show: boolean;\n readonly height: number;\n readonly trackColor: string;\n readonly indicatorColor: string;\n readonly trackStyle: CarouselProps['progressTrackStyle'];\n readonly indicatorStyle: CarouselProps['progressIndicatorStyle'];\n readonly progress: Animated.Value;\n readonly testID: CarouselProps['testID'];\n}\n\n/*** Render an optional linear autoplay timer without adding any required UI to slides. */\nfunction CarouselProgress({\n height,\n indicatorColor,\n indicatorStyle,\n progress,\n show,\n testID,\n trackColor,\n trackStyle,\n}: CarouselProgressProps) {\n if (!show) return null;\n return (\n <View\n pointerEvents=\"none\"\n style={[styles.progress, { height, backgroundColor: trackColor }, trackStyle]}\n testID={testID ? `${testID}-progress` : undefined}\n >\n <Animated.View\n style={[\n {\n height: '100%',\n width: '100%',\n transformOrigin: 'left center',\n transform: [{ scaleX: progress }],\n backgroundColor: indicatorColor,\n },\n indicatorStyle,\n ]}\n />\n </View>\n );\n}\n\nconst styles = StyleSheet.create({\n controls: {\n position: 'absolute',\n top: 0,\n bottom: 0,\n left: 14,\n right: 14,\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'center',\n },\n control: {\n width: 44,\n height: 44,\n borderRadius: 22,\n justifyContent: 'center',\n alignItems: 'center',\n },\n indicators: {\n position: 'absolute',\n bottom: 24,\n left: 0,\n right: 0,\n flexDirection: 'row',\n gap: 10,\n justifyContent: 'center',\n alignItems: 'center',\n },\n indicator: { height: 8, borderRadius: 8 },\n progress: { position: 'absolute', bottom: 0, left: 0, right: 0, overflow: 'hidden' },\n});\n"]}
1
+ {"version":3,"file":"Carousel.js","sourceRoot":"","sources":["../../../src/features/carousel/Carousel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,C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a;gBAC9B,SAAS,EAAE,CAAC,EAAE,MAAM,EAAE,QAAQ,EAAE,CAAC;gBACjC,eAAe,EAAE,cAAc;aAChC;YACD,cAAc;SACf,CAAC,EAEN;IAAA,EAAE,IAAI,CAAC,CACR,CAAC;AACJ,CAAC;AAED,MAAM,MAAM,GAAG,UAAU,CAAC,MAAM,CAAC;IAC/B,QAAQ,EAAE;QACR,QAAQ,EAAE,UAAU;QACpB,GAAG,EAAE,CAAC;QACN,MAAM,EAAE,CAAC;QACT,IAAI,EAAE,EAAE;QACR,KAAK,EAAE,EAAE;QACT,aAAa,EAAE,KAAK;QACpB,cAAc,EAAE,eAAe;QAC/B,UAAU,EAAE,QAAQ;KACrB;IACD,OAAO,EAAE;QACP,KAAK,EAAE,EAAE;QACT,MAAM,EAAE,EAAE;QACV,YAAY,EAAE,EAAE;QAChB,cAAc,EAAE,QAAQ;QACxB,UAAU,EAAE,QAAQ;KACrB;IACD,UAAU,EAAE;QACV,QAAQ,EAAE,UAAU;QACpB,MAAM,EAAE,EAAE;QACV,IAAI,EAAE,CAAC;QACP,KAAK,EAAE,CAAC;QACR,aAAa,EAAE,KAAK;QACpB,GAAG,EAAE,EAAE;QACP,cAAc,EAAE,QAAQ;QACxB,UAAU,EAAE,QAAQ;KACrB;IACD,SAAS,EAAE,EAAE,MAAM,EAAE,CAAC,EAAE,YAAY,EAAE,CAAC,EAAE;IACzC,QAAQ,EAAE,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,EAAE,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,QAAQ,EAAE,QAAQ,EAAE;CACrF,CAAC,CAAC","sourcesContent":["import React from 'react';\nimport { Animated, Easing, Image, Pressable, StyleSheet, Text, View } from 'react-native';\n\nimport type { CarouselProps, CarouselSlide, CarouselTransition } from '../../types/carousel';\nimport { useZoraTheme } from '../theme/composition/useZoraTheme';\nimport { useCarouselPlayback } from './useCarouselPlayback';\n\n/***\n * Present images, arbitrary React content, or both as a cross-platform slideshow.\n * A published web artifact exposes the same API without consumer source imports.\n */\nexport function Carousel({\n slides,\n index,\n defaultIndex,\n onIndexChange,\n autoPlay,\n paused,\n loop,\n intervalMs,\n transition = 'fade',\n enterDurationMs = 1200,\n exitDurationMs = 800,\n initialScale = 1.06,\n animateOnMount = false,\n reducedMotion,\n showProgress = true,\n progressHeight = 4,\n progressTrackColor,\n progressIndicatorColor,\n progressTrackStyle,\n progressIndicatorStyle,\n showArrows = false,\n showIndicators = false,\n previousLabel = 'Previous slide',\n nextLabel = 'Next slide',\n controlColor,\n controlBackgroundColor,\n controlsStyle,\n activeIndicatorColor,\n inactiveIndicatorColor,\n indicatorsStyle,\n resizeMode = 'cover',\n imageStyle,\n style,\n renderImage,\n testID,\n}: CarouselProps) {\n const { theme } = useZoraTheme();\n const [width, setWidth] = React.useState(0);\n const initialIndex = normalizeSlideIndex(index ?? defaultIndex ?? 0, slides.length);\n const initialSlide = slides.at(initialIndex);\n const [mountedSlideKeys, setMountedSlideKeys] = React.useState<ReadonlySet<string>>(() =>\n initialSlide ? new Set([initialSlide.key]) : new Set(),\n );\n const [readySlideKeys, setReadySlideKeys] = React.useState<ReadonlySet<string>>(() => new Set());\n const [completedSlideKeys, setCompletedSlideKeys] = React.useState<ReadonlySet<string>>(\n () => new Set(),\n );\n const {\n activeIndex,\n controlledWithoutHandler,\n direction,\n loop: enabledLoop,\n navigate,\n progress,\n shouldReduceMotion,\n } = useCarouselPlayback({\n slides,\n index,\n defaultIndex,\n onIndexChange,\n autoPlay,\n paused,\n loop,\n intervalMs,\n reducedMotion,\n });\n\n const activeSlide = slides.at(activeIndex);\n const nextIndex = getNextSlideIndex(activeIndex, slides.length, enabledLoop);\n const nextSlide = nextIndex === undefined ? undefined : slides.at(nextIndex);\n const activeSlideKey = activeSlide?.key;\n const nextSlideKey = nextSlide?.key;\n const mountedKeys = ensureMountedSlide(\n ensureMountedSlide(mountedSlideKeys, activeSlideKey),\n getPreloadedSlideKey(activeSlideKey, nextSlideKey, readySlideKeys),\n );\n\n const markSlideLoaded = React.useCallback(\n (slideKey: string) => {\n setReadySlideKeys((current) => ensureMountedSlide(current, slideKey));\n if (slideKey === activeSlideKey) {\n setMountedSlideKeys((current) => ensureMountedSlide(current, nextSlideKey));\n }\n },\n [activeSlideKey, nextSlideKey],\n );\n\n const transitionStateRef = React.useRef({ activeSlideKey, nextSlideKey, readySlideKeys });\n React.useLayoutEffect(() => {\n transitionStateRef.current = { activeSlideKey, nextSlideKey, readySlideKeys };\n }, [activeSlideKey, nextSlideKey, readySlideKeys]);\n\n // Stable identity: layers run animations from effects, so a changing callback would restart them.\n const completeTransition = React.useCallback((completedSlideKey: string, immediate: boolean) => {\n const {\n activeSlideKey: currentKey,\n nextSlideKey: currentNextKey,\n readySlideKeys: ready,\n } = transitionStateRef.current;\n if (!currentKey || completedSlideKey !== currentKey) return;\n if (!immediate && !ready.has(currentKey)) {\n setCompletedSlideKeys((current) => ensureMountedSlide(current, currentKey));\n return;\n }\n const transitionRetentionKeys = [currentKey, currentNextKey].filter(\n (slideKey): slideKey is string => slideKey !== undefined,\n );\n setMountedSlideKeys(\n (current) =>\n new Set(\n transitionRetentionKeys.filter(\n (slideKey) => slideKey === currentKey || current.has(slideKey) || ready.has(currentKey),\n ),\n ),\n );\n setCompletedSlideKeys((current) => {\n if (!current.has(currentKey)) return current;\n return new Set([...current].filter((slideKey) => slideKey !== currentKey));\n });\n }, []);\n\n React.useLayoutEffect(() => {\n if (\n !activeSlideKey ||\n !completedSlideKeys.has(activeSlideKey) ||\n !readySlideKeys.has(activeSlideKey)\n ) {\n return;\n }\n completeTransition(activeSlideKey, false);\n }, [activeSlideKey, completedSlideKeys, completeTransition, readySlideKeys]);\n\n if (slides.length === 0) return null;\n\n const canPrevious = enabledLoop || activeIndex > 0;\n const canNext = enabledLoop || activeIndex < slides.length - 1;\n const markerColor = activeIndicatorColor ?? theme.colors.primary;\n const idleMarkerColor = inactiveIndicatorColor ?? theme.semantics.neutral.divider;\n\n return (\n <View\n onLayout={(event) => setWidth(event.nativeEvent.layout.width)}\n testID={testID}\n style={[{ position: 'relative', overflow: 'hidden', width: '100%', height: '100%' }, style]}\n >\n {slides.flatMap((slide, slideIndex) =>\n mountedKeys.has(slide.key)\n ? [\n <CarouselLayer\n key={slide.key}\n active={activeIndex === slideIndex}\n animate={slides.length > 1}\n animateOnMount={animateOnMount || activeIndex !== initialIndex}\n direction={direction}\n enterDurationMs={enterDurationMs}\n exitDurationMs={exitDurationMs}\n imageStyle={imageStyle}\n initialScale={initialScale}\n onImageLoad={() => markSlideLoaded(slide.key)}\n onTransitionComplete={completeTransition}\n reducedMotion={shouldReduceMotion}\n renderImage={renderImage}\n resizeMode={resizeMode}\n slide={slide}\n slideIndex={slideIndex}\n transition={transition}\n width={width}\n />,\n ]\n : [],\n )}\n <CarouselControls\n activeIndex={activeIndex}\n canNext={canNext}\n canPrevious={canPrevious}\n controlBackgroundColor={controlBackgroundColor ?? theme.semantics.surface.raised}\n controlColor={controlColor ?? theme.semantics.content.default}\n controlledWithoutHandler={controlledWithoutHandler}\n controlsStyle={controlsStyle}\n navigate={navigate}\n nextLabel={nextLabel}\n previousLabel={previousLabel}\n show={showArrows && slides.length > 1}\n testID={testID}\n />\n <CarouselIndicators\n activeIndex={activeIndex}\n activeColor={markerColor}\n controlledWithoutHandler={controlledWithoutHandler}\n idleColor={idleMarkerColor}\n indicatorsStyle={indicatorsStyle}\n navigate={navigate}\n show={showIndicators && slides.length > 1}\n slides={slides}\n testID={testID}\n />\n <CarouselProgress\n height={progressHeight}\n indicatorColor={progressIndicatorColor ?? theme.colors.primary}\n indicatorStyle={progressIndicatorStyle}\n progress={progress}\n show={showProgress && slides.length > 1}\n testID={testID}\n trackColor={progressTrackColor ?? theme.semantics.neutral.divider}\n trackStyle={progressTrackStyle}\n />\n </View>\n );\n}\n\ninterface CarouselLayerProps {\n readonly enterDurationMs?: CarouselProps['enterDurationMs'];\n readonly exitDurationMs?: CarouselProps['exitDurationMs'];\n readonly imageStyle: CarouselProps['imageStyle'];\n readonly initialScale?: CarouselProps['initialScale'];\n readonly onImageLoad: () => void;\n readonly onTransitionComplete: (slideKey: string, immediate: boolean) => void;\n readonly renderImage: CarouselProps['renderImage'];\n readonly resizeMode: CarouselProps['resizeMode'];\n readonly slide: CarouselSlide;\n readonly slideIndex: number;\n readonly active: boolean;\n readonly animate: boolean;\n readonly animateOnMount: boolean;\n readonly direction: 1 | -1;\n readonly width: number;\n readonly transition: CarouselTransition;\n readonly reducedMotion: boolean;\n}\n\n/*** Keep departing slides mounted for an animated overlap without unmounting content. */\nfunction CarouselLayer({\n slide,\n slideIndex,\n active,\n animate,\n animateOnMount,\n direction,\n enterDurationMs = 1200,\n exitDurationMs = 800,\n initialScale = 1.06,\n onImageLoad,\n onTransitionComplete,\n reducedMotion,\n renderImage,\n resizeMode,\n imageStyle,\n transition,\n width,\n}: CarouselLayerProps) {\n const [opacity] = React.useState(() => new Animated.Value(active && !animateOnMount ? 1 : 0));\n const [scale] = React.useState(\n () => new Animated.Value(active && animateOnMount ? initialScale : 1),\n );\n const [offset] = React.useState(() => new Animated.Value(0));\n const hasMounted = React.useRef(false);\n const widthRef = React.useRef(width);\n\n React.useEffect(() => {\n widthRef.current = width;\n }, [width]);\n\n React.useEffect(() => {\n const firstRender = !hasMounted.current;\n hasMounted.current = true;\n if (firstRender && !animateOnMount) return;\n opacity.stopAnimation();\n scale.stopAnimation();\n offset.stopAnimation();\n if (!animate || reducedMotion || transition === 'none') {\n opacity.setValue(active ? 1 : 0);\n scale.setValue(1);\n offset.setValue(0);\n if (active) onTransitionComplete(slide.key, true);\n return;\n }\n if (transition === 'slide') {\n scale.setValue(1);\n if (active) {\n offset.setValue(direction * widthRef.current);\n opacity.setValue(1);\n }\n Animated.parallel([\n Animated.timing(offset, {\n toValue: active ? 0 : -direction * widthRef.current,\n duration: Math.max(0, active ? enterDurationMs : exitDurationMs),\n easing: Easing.bezier(0.4, 0, 0.2, 1),\n useNativeDriver: true,\n }),\n Animated.timing(opacity, {\n toValue: active ? 1 : 0,\n duration: Math.max(0, active ? enterDurationMs : exitDurationMs),\n easing: Easing.linear,\n useNativeDriver: true,\n }),\n ]).start(({ finished }) => {\n if (active && finished) onTransitionComplete(slide.key, false);\n });\n } else if (active) {\n opacity.setValue(0);\n scale.setValue(initialScale);\n Animated.parallel([\n Animated.timing(opacity, {\n toValue: 1,\n duration: Math.max(0, enterDurationMs),\n easing: Easing.bezier(0.4, 0, 0.2, 1),\n useNativeDriver: true,\n }),\n Animated.timing(scale, {\n toValue: 1,\n duration: Math.max(0, enterDurationMs),\n easing: Easing.bezier(0.4, 0, 0.2, 1),\n useNativeDriver: true,\n }),\n ]).start(({ finished }) => {\n if (finished) onTransitionComplete(slide.key, false);\n });\n } else {\n Animated.timing(opacity, {\n toValue: 0,\n duration: Math.max(0, exitDurationMs),\n easing: Easing.bezier(0.4, 0, 0.2, 1),\n useNativeDriver: true,\n }).start();\n }\n return () => {\n opacity.stopAnimation();\n scale.stopAnimation();\n offset.stopAnimation();\n };\n }, [\n active,\n animate,\n animateOnMount,\n direction,\n enterDurationMs,\n exitDurationMs,\n initialScale,\n offset,\n opacity,\n reducedMotion,\n scale,\n transition,\n onTransitionComplete,\n slide.key,\n ]);\n\n return (\n <Animated.View\n accessibilityElementsHidden={!active}\n importantForAccessibility={active ? 'auto' : 'no-hide-descendants'}\n pointerEvents={active ? 'auto' : 'none'}\n style={[StyleSheet.absoluteFill, { opacity, transform: [{ scale }, { translateX: offset }] }]}\n >\n {slide.source !== undefined ? (\n renderImage ? (\n renderCarouselImage(renderImage(slide, slideIndex), onImageLoad)\n ) : (\n <Image\n accessibilityLabel={slide.alt}\n accessible={Boolean(slide.alt)}\n resizeMode={resizeMode}\n source={typeof slide.source === 'string' ? { uri: slide.source } : slide.source}\n style={[StyleSheet.absoluteFill, imageStyle]}\n onLoad={onImageLoad}\n />\n )\n ) : null}\n {slide.content}\n </Animated.View>\n );\n}\n\n/*** Retain consumer image behavior while observing readiness for adjacent-slide preloading. */\nfunction renderCarouselImage(image: React.ReactNode, onImageLoad: () => void): React.ReactNode {\n if (!React.isValidElement<{ onLoad?: (event: unknown) => void }>(image)) return image;\n const existingOnLoad = image.props.onLoad;\n return React.cloneElement(image, {\n onLoad: (event: unknown) => {\n existingOnLoad?.(event);\n onImageLoad();\n },\n });\n}\n\n/*** Return an immutable mounted-key set containing one requested slide. */\nfunction ensureMountedSlide(mountedSlideKeys: ReadonlySet<string>, slideKey: string | undefined) {\n if (!slideKey || mountedSlideKeys.has(slideKey)) return mountedSlideKeys;\n return new Set([...mountedSlideKeys, slideKey]);\n}\n\n/*** Return the next slide key only after the active slide image is ready. */\nfunction getPreloadedSlideKey(\n activeSlideKey: string | undefined,\n nextSlideKey: string | undefined,\n readySlideKeys: ReadonlySet<string>,\n) {\n if (!activeSlideKey || !readySlideKeys.has(activeSlideKey)) return undefined;\n return nextSlideKey;\n}\n\n/*** Resolve the slide to preload without wrapping when looping is disabled. */\nfunction getNextSlideIndex(index: number, length: number, loop: boolean): number | undefined {\n if (length < 2 || (!loop && index === length - 1)) return undefined;\n return (index + 1) % length;\n}\n\n/*** Clamp the initial server-rendered slide to the available slide collection. */\nfunction normalizeSlideIndex(index: number, length: number): number {\n if (length === 0) return 0;\n return Math.min(Math.max(Math.trunc(index), 0), length - 1);\n}\n\ninterface CarouselNavigationProps {\n readonly activeIndex: number;\n readonly navigate: (index: number, direction: 1 | -1) => void;\n readonly controlledWithoutHandler: boolean;\n readonly testID: CarouselProps['testID'];\n}\n\ninterface CarouselControlsProps extends CarouselNavigationProps {\n readonly show: boolean;\n readonly canPrevious: boolean;\n readonly canNext: boolean;\n readonly previousLabel: string;\n readonly nextLabel: string;\n readonly controlColor: string;\n readonly controlBackgroundColor: string;\n readonly controlsStyle: CarouselProps['controlsStyle'];\n}\n\n/*** Render optional previous/next buttons without coupling the slide content to navigation. */\nfunction CarouselControls({\n activeIndex,\n canNext,\n canPrevious,\n controlBackgroundColor,\n controlColor,\n controlledWithoutHandler,\n controlsStyle,\n navigate,\n nextLabel,\n previousLabel,\n show,\n testID,\n}: CarouselControlsProps) {\n if (!show) return null;\n const buttonStyle = [styles.control, { backgroundColor: controlBackgroundColor }];\n const labelStyle = { color: controlColor, fontSize: 30 };\n return (\n <View pointerEvents=\"box-none\" style={[styles.controls, controlsStyle]}>\n <Pressable\n accessibilityLabel={previousLabel}\n accessibilityRole=\"button\"\n disabled={!canPrevious || controlledWithoutHandler}\n onPress={() => navigate(activeIndex - 1, -1)}\n style={buttonStyle}\n testID={testID ? `${testID}-previous` : undefined}\n >\n <Text style={labelStyle}>{'‹'}</Text>\n </Pressable>\n <Pressable\n accessibilityLabel={nextLabel}\n accessibilityRole=\"button\"\n disabled={!canNext || controlledWithoutHandler}\n onPress={() => navigate(activeIndex + 1, 1)}\n style={buttonStyle}\n testID={testID ? `${testID}-next` : undefined}\n >\n <Text style={labelStyle}>{'›'}</Text>\n </Pressable>\n </View>\n );\n}\n\ninterface CarouselIndicatorsProps extends CarouselNavigationProps {\n readonly show: boolean;\n readonly slides: CarouselProps['slides'];\n readonly activeColor: string;\n readonly idleColor: string;\n readonly indicatorsStyle: CarouselProps['indicatorsStyle'];\n}\n\n/*** Render accessible selection dots for the currently controlled slide. */\nfunction CarouselIndicators({\n activeIndex,\n activeColor,\n controlledWithoutHandler,\n idleColor,\n indicatorsStyle,\n navigate,\n show,\n slides,\n testID,\n}: CarouselIndicatorsProps) {\n if (!show) return null;\n return (\n <View pointerEvents=\"box-none\" style={[styles.indicators, indicatorsStyle]}>\n {slides.map((slide, slideIndex) => (\n <Pressable\n key={slide.key}\n accessibilityLabel={`Go to slide ${slideIndex + 1} of ${slides.length}`}\n accessibilityRole=\"button\"\n accessibilityState={{ selected: slideIndex === activeIndex }}\n disabled={controlledWithoutHandler}\n onPress={() => navigate(slideIndex, slideIndex < activeIndex ? -1 : 1)}\n style={[\n styles.indicator,\n {\n backgroundColor: slideIndex === activeIndex ? activeColor : idleColor,\n width: slideIndex === activeIndex ? 24 : 8,\n },\n ]}\n testID={testID ? `${testID}-indicator-${slideIndex}` : undefined}\n />\n ))}\n </View>\n );\n}\n\ninterface CarouselProgressProps {\n readonly show: boolean;\n readonly height: number;\n readonly trackColor: string;\n readonly indicatorColor: string;\n readonly trackStyle: CarouselProps['progressTrackStyle'];\n readonly indicatorStyle: CarouselProps['progressIndicatorStyle'];\n readonly progress: Animated.Value;\n readonly testID: CarouselProps['testID'];\n}\n\n/*** Render an optional linear autoplay timer without adding any required UI to slides. */\nfunction CarouselProgress({\n height,\n indicatorColor,\n indicatorStyle,\n progress,\n show,\n testID,\n trackColor,\n trackStyle,\n}: CarouselProgressProps) {\n if (!show) return null;\n return (\n <View\n pointerEvents=\"none\"\n style={[styles.progress, { height, backgroundColor: trackColor }, trackStyle]}\n testID={testID ? `${testID}-progress` : undefined}\n >\n <Animated.View\n style={[\n {\n height: '100%',\n width: '100%',\n transformOrigin: 'left center',\n transform: [{ scaleX: progress }],\n backgroundColor: indicatorColor,\n },\n indicatorStyle,\n ]}\n />\n </View>\n );\n}\n\nconst styles = StyleSheet.create({\n controls: {\n position: 'absolute',\n top: 0,\n bottom: 0,\n left: 14,\n right: 14,\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'center',\n },\n control: {\n width: 44,\n height: 44,\n borderRadius: 22,\n justifyContent: 'center',\n alignItems: 'center',\n },\n indicators: {\n position: 'absolute',\n bottom: 24,\n left: 0,\n right: 0,\n flexDirection: 'row',\n gap: 10,\n justifyContent: 'center',\n alignItems: 'center',\n },\n indicator: { height: 8, borderRadius: 8 },\n progress: { position: 'absolute', bottom: 0, left: 0, right: 0, overflow: 'hidden' },\n});\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"Select.web.d.ts","sourceRoot":"","sources":["../../../../../../src/features/form/select/adapters/inbound/Select.web.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,6BAA6B,CAAC;AAU/D,iEAAiE;AACjE,eAAO,MAAM,MAAM,GAGE,MAAM,SAAS,MAAM,mEAHW,CAAC"}
1
+ {"version":3,"file":"Select.web.d.ts","sourceRoot":"","sources":["../../../../../../src/features/form/select/adapters/inbound/Select.web.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,6BAA6B,CAAC;AAW/D,iEAAiE;AACjE,eAAO,MAAM,MAAM,GAGE,MAAM,SAAS,MAAM,mEAHW,CAAC"}
@@ -5,6 +5,7 @@ import { Surface } from '../../../../surface/public.js';
5
5
  import { withZoraThemeScope } from '../../../../theme/adapters/inbound/withZoraThemeScope.js';
6
6
  import { SelectField } from '../../composition/SelectField.js';
7
7
  import { SelectOptionRow } from '../../composition/SelectOptionRow.js';
8
+ import { SelectOptionsList } from '../../composition/SelectOptionsList.js';
8
9
  import { SelectSearchInput } from '../../composition/SelectSearchInput.js';
9
10
  import { SelectTrigger } from '../../composition/SelectTrigger.js';
10
11
  import { useSelectController } from '../../composition/useSelectController.js';
@@ -24,7 +25,9 @@ function SelectInner({ themeId: _themeId, mode: _mode, ...props }) {
24
25
  <Surface variant="raised">
25
26
  <View gap="xs" p="xs">
26
27
  <SelectSearchInput onSearchChange={search} props={props} searchValue={searchValue}/>
27
- {visibleOptions.map((option) => (<SelectOptionRow interactionPolicy={interactionPolicy} key={option.value} onSelect={selectAndClose} option={option} selected={value === option.value} testID={testID}/>))}
28
+ <SelectOptionsList searchable={props.searchable}>
29
+ {visibleOptions.map((option) => (<SelectOptionRow interactionPolicy={interactionPolicy} key={option.value} onSelect={selectAndClose} option={option} selected={value === option.value} testID={testID}/>))}
30
+ </SelectOptionsList>
28
31
  </View>
29
32
  </Surface>
30
33
  </Popover>
@@ -1 +1 @@
1
- {"version":3,"file":"Select.web.js","sourceRoot":"","sources":["../../../../../../src/features/form/select/adapters/inbound/Select.web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OAAO,CACX;MAAA,EAAE,OAAO,CACX;IAAA,EAAE,WAAW,CAAC,CACf,CAAC;AACJ,CAAC","sourcesContent":["import { Popover } from '@ankhorage/surface';\nimport React from 'react';\n\nimport type { SelectProps } from '../../../../../types/select';\nimport { View } from '../../../../layout/public';\nimport { Surface } from '../../../../surface/public';\nimport { withZoraThemeScope } from '../../../../theme/adapters/inbound/withZoraThemeScope';\nimport { SelectField } from '../../composition/SelectField';\nimport { SelectOptionRow } from '../../composition/SelectOptionRow';\nimport { SelectSearchInput } from '../../composition/SelectSearchInput';\nimport { SelectTrigger } from '../../composition/SelectTrigger';\nimport { useSelectController } from '../../composition/useSelectController';\n\n/*** Renders Select with anchored Popover presentation on web. */\nexport const Select = withZoraThemeScope(SelectInner);\n\n/*** Connects shared Select state and controls to the web Popover host. */\nfunction SelectInner<TValue extends string = string>({\n themeId: _themeId,\n mode: _mode,\n ...props\n}: SelectProps<TValue>) {\n const [open, setOpen] = React.useState(false);\n const { search, searchValue, select, selectedOption, value, visibleOptions } =\n useSelectController(props);\n const { interactionPolicy, testID } = props;\n\n const selectAndClose = React.useCallback(\n (nextValue: TValue) => {\n select(nextValue);\n setOpen(false);\n },\n [select],\n );\n\n return (\n <SelectField props={props}>\n <Popover\n anchor={({ toggle }) => (\n <SelectTrigger\n displayLabel={selectedOption?.label}\n leadingMedia={selectedOption?.leadingMedia}\n onPress={toggle}\n props={props}\n />\n )}\n interactionPolicy={props.interactionPolicy}\n onOpenChange={setOpen}\n open={open}\n placement=\"bottom-start\"\n testID={testID ? `${testID}-popover` : undefined}\n >\n <Surface variant=\"raised\">\n <View gap=\"xs\" p=\"xs\">\n <SelectSearchInput onSearchChange={search} props={props} searchValue={searchValue} />\n {visibleOptions.map((option) => (\n <SelectOptionRow\n interactionPolicy={interactionPolicy}\n key={option.value}\n onSelect={selectAndClose}\n option={option}\n selected={value === option.value}\n testID={testID}\n />\n ))}\n </View>\n </Surface>\n </Popover>\n </SelectField>\n );\n}\n"]}
1
+ {"version":3,"file":"Select.web.js","sourceRoot":"","sources":["../../../../../../src/features/form/select/adapters/inbound/Select.web.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,oBAAoB,CAAC;AAC7C,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,EAAE,IAAI,EAAE,MAAM,2BAA2B,CAAC;AACjD,OAAO,EAAE,OAAO,EAAE,MAAM,4BAA4B,CAAC;AACrD,OAAO,EAAE,kBAAkB,EAAE,MAAM,uDAAuD,CAAC;AAC3F,OAAO,EAAE,WAAW,EAAE,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAE,eAAe,EAAE,MAAM,mCAAmC,CAAC;AACpE,OAAO,EAAE,iBAAiB,EAAE,MAAM,qCAAqC,CAAC;AACxE,OAAO,EAAE,iBAAiB,EAAE,MAAM,qCAAqC,CAAC;AACxE,OAAO,EAAE,aAAa,EAAE,MAAM,iCAAiC,CAAC;AAChE,OAAO,EAAE,mBAAmB,EAAE,MAAM,uCAAuC,CAAC;AAE5E,iEAAiE;AACjE,MAAM,CAAC,MAAM,MAAM,GAAG,kBAAkB,CAAC,WAAW,CAAC,CAAC;AAEtD,0EAA0E;AAC1E,SAAS,WAAW,CAAiC,EACnD,OAAO,EAAE,QAAQ,EACjB,IAAI,EAAE,KAAK,EACX,GAAG,KAAK,EACY;IACpB,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,GAAG,KAAK,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC;IAC9C,MAAM,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,EAAE,cAAc,EAAE,KAAK,EAAE,cAAc,EAAE,GAC1E,mBAAmB,CAAC,KAAK,CAAC,CAAC;IAC7B,MAAM,EAAE,iBAAiB,EAAE,MAAM,EAAE,GAAG,KAAK,CAAC;IAE5C,MAAM,cAAc,GAAG,KAAK,CAAC,WAAW,CACtC,CAAC,SAAiB,EAAE,EAAE;QACpB,MAAM,CAAC,SAAS,CAAC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c,CAAC,CACzB,MAAM,CAAC,CAAC,MAAM,CAAC,CACf,QAAQ,CAAC,CAAC,KAAK,KAAK,MAAM,CAAC,KAAK,CAAC,CACjC,MAAM,CAAC,CAAC,MAAM,CAAC,EACf,CACH,CAAC,CACJ;YAAA,EAAE,iBAAiB,CACrB;UAAA,EAAE,IAAI,CACR;QAAA,EAAE,OAAO,CACX;MAAA,EAAE,OAAO,CACX;IAAA,EAAE,WAAW,CAAC,CACf,CAAC;AACJ,CAAC","sourcesContent":["import { Popover } from '@ankhorage/surface';\nimport React from 'react';\n\nimport type { SelectProps } from '../../../../../types/select';\nimport { View } from '../../../../layout/public';\nimport { Surface } from '../../../../surface/public';\nimport { withZoraThemeScope } from '../../../../theme/adapters/inbound/withZoraThemeScope';\nimport { SelectField } from '../../composition/SelectField';\nimport { SelectOptionRow } from '../../composition/SelectOptionRow';\nimport { SelectOptionsList } from '../../composition/SelectOptionsList';\nimport { SelectSearchInput } from '../../composition/SelectSearchInput';\nimport { SelectTrigger } from '../../composition/SelectTrigger';\nimport { useSelectController } from '../../composition/useSelectController';\n\n/*** Renders Select with anchored Popover presentation on web. */\nexport const Select = withZoraThemeScope(SelectInner);\n\n/*** Connects shared Select state and controls to the web Popover host. */\nfunction SelectInner<TValue extends string = string>({\n themeId: _themeId,\n mode: _mode,\n ...props\n}: SelectProps<TValue>) {\n const [open, setOpen] = React.useState(false);\n const { search, searchValue, select, selectedOption, value, visibleOptions } =\n useSelectController(props);\n const { interactionPolicy, testID } = props;\n\n const selectAndClose = React.useCallback(\n (nextValue: TValue) => {\n select(nextValue);\n setOpen(false);\n },\n [select],\n );\n\n return (\n <SelectField props={props}>\n <Popover\n anchor={({ toggle }) => (\n <SelectTrigger\n displayLabel={selectedOption?.label}\n leadingMedia={selectedOption?.leadingMedia}\n onPress={toggle}\n props={props}\n />\n )}\n interactionPolicy={props.interactionPolicy}\n onOpenChange={setOpen}\n open={open}\n placement=\"bottom-start\"\n testID={testID ? `${testID}-popover` : undefined}\n >\n <Surface variant=\"raised\">\n <View gap=\"xs\" p=\"xs\">\n <SelectSearchInput onSearchChange={search} props={props} searchValue={searchValue} />\n <SelectOptionsList searchable={props.searchable}>\n {visibleOptions.map((option) => (\n <SelectOptionRow\n interactionPolicy={interactionPolicy}\n key={option.value}\n onSelect={selectAndClose}\n option={option}\n selected={value === option.value}\n testID={testID}\n />\n ))}\n </SelectOptionsList>\n </View>\n </Surface>\n </Popover>\n </SelectField>\n );\n}\n"]}
@@ -0,0 +1,9 @@
1
+ import type React from 'react';
2
+ /*** Renders Select options in a viewport-bounded scroll container so wheel, pointer and selection work inside any overlay host. */
3
+ export declare function SelectOptionsList({ children, searchable }: SelectOptionsListProps): React.JSX.Element;
4
+ interface SelectOptionsListProps {
5
+ readonly children: React.ReactNode;
6
+ readonly searchable: boolean | undefined;
7
+ }
8
+ export {};
9
+ //# sourceMappingURL=SelectOptionsList.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SelectOptionsList.d.ts","sourceRoot":"","sources":["../../../../../src/features/form/select/composition/SelectOptionsList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAW/B,mIAAmI;AACnI,wBAAgB,iBAAiB,CAAC,EAAE,QAAQ,EAAE,UAAU,EAAE,EAAE,sBAAsB,qBAWjF;AAED,UAAU,sBAAsB;IAC9B,QAAQ,CAAC,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IACnC,QAAQ,CAAC,UAAU,EAAE,OAAO,GAAG,SAAS,CAAC;CAC1C"}
@@ -0,0 +1,17 @@
1
+ import { useWindowDimensions } from 'react-native';
2
+ import { ScrollView, View } from '../../../layout/public.js';
3
+ // Anchored popovers keep a viewport edge gap on both sides and Select adds its surface padding.
4
+ const OPTIONS_LIST_VIEWPORT_MARGIN = 32;
5
+ // The optional search control occupies the popover above the list.
6
+ const OPTIONS_LIST_SEARCH_ALLOWANCE = 56;
7
+ const OPTIONS_LIST_MIN_HEIGHT = 120;
8
+ /*** Renders Select options in a viewport-bounded scroll container so wheel, pointer and selection work inside any overlay host. */
9
+ export function SelectOptionsList({ children, searchable }) {
10
+ const { height: viewportHeight } = useWindowDimensions();
11
+ const reservedHeight = OPTIONS_LIST_VIEWPORT_MARGIN + (searchable ? OPTIONS_LIST_SEARCH_ALLOWANCE : 0);
12
+ const maxHeight = Math.max(OPTIONS_LIST_MIN_HEIGHT, viewportHeight - reservedHeight);
13
+ return (<ScrollView maxHeight={maxHeight}>
14
+ <View gap="xs">{children}</View>
15
+ </ScrollView>);
16
+ }
17
+ //# sourceMappingURL=SelectOptionsList.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SelectOptionsList.js","sourceRoot":"","sources":["../../../../../src/features/form/select/composition/SelectOptionsList.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,mBAAmB,EAAE,MAAM,cAAc,CAAC;AAEnD,OAAO,EAAE,UAAU,EAAE,IAAI,EAAE,MAAM,wBAAwB,CAAC;AAE1D,gGAAgG;AAChG,MAAM,4BAA4B,GAAG,EAAE,CAAC;AACxC,mEAAmE;AACnE,MAAM,6BAA6B,GAAG,EAAE,CAAC;AACzC,MAAM,uBAAuB,GAAG,GAAG,CAAC;AAEpC,mIAAmI;AACnI,MAAM,UAAU,iBAAiB,CAAC,EAAE,QAAQ,EAAE,UAAU,EAA0B;IAChF,MAAM,EAAE,MAAM,EAAE,cAAc,EAAE,GAAG,mBAAmB,EAAE,CAAC;IACzD,MAAM,cAAc,GAClB,4BAA4B,GAAG,CAAC,UAAU,CAAC,CAAC,CAAC,6BAA6B,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;IAClF,MAAM,SAAS,GAAG,IAAI,CAAC,GAAG,CAAC,uBAAuB,EAAE,cAAc,GAAG,cAAc,CAAC,CAAC;IAErF,OAAO,CACL,CAAC,UAAU,CAAC,SAAS,CAAC,CAAC,SAAS,CAAC,CAC/B;MAAA,CAAC,IAAI,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,QAAQ,CAAC,EAAE,IAAI,CACjC;IAAA,EAAE,UAAU,CAAC,CACd,CAAC;AACJ,CAAC","sourcesContent":["import type React from 'react';\nimport { useWindowDimensions } from 'react-native';\n\nimport { ScrollView, View } from '../../../layout/public';\n\n// Anchored popovers keep a viewport edge gap on both sides and Select adds its surface padding.\nconst OPTIONS_LIST_VIEWPORT_MARGIN = 32;\n// The optional search control occupies the popover above the list.\nconst OPTIONS_LIST_SEARCH_ALLOWANCE = 56;\nconst OPTIONS_LIST_MIN_HEIGHT = 120;\n\n/*** Renders Select options in a viewport-bounded scroll container so wheel, pointer and selection work inside any overlay host. */\nexport function SelectOptionsList({ children, searchable }: SelectOptionsListProps) {\n const { height: viewportHeight } = useWindowDimensions();\n const reservedHeight =\n OPTIONS_LIST_VIEWPORT_MARGIN + (searchable ? OPTIONS_LIST_SEARCH_ALLOWANCE : 0);\n const maxHeight = Math.max(OPTIONS_LIST_MIN_HEIGHT, viewportHeight - reservedHeight);\n\n return (\n <ScrollView maxHeight={maxHeight}>\n <View gap=\"xs\">{children}</View>\n </ScrollView>\n );\n}\n\ninterface SelectOptionsListProps {\n readonly children: React.ReactNode;\n readonly searchable: boolean | undefined;\n}\n"]}
@@ -1,4 +1,9 @@
1
1
  import React from 'react';
2
2
  /*** Hoists the React Native Web styles required by a server-rendered ZORA application. */
3
- export declare function ZoraWebStyleSheet(): React.JSX.Element | null;
3
+ export declare function ZoraWebStyleSheet(): React.DetailedReactHTMLElement<{
4
+ dangerouslySetInnerHTML: {
5
+ __html: string;
6
+ };
7
+ id: string;
8
+ }, HTMLElement> | null;
4
9
  //# sourceMappingURL=ZoraWebStyleSheet.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ZoraWebStyleSheet.d.ts","sourceRoot":"","sources":["../../../../../src/features/layout/adapters/inbound/ZoraWebStyleSheet.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAQ1B,0FAA0F;AAC1F,wBAAgB,iBAAiB,6BAShC"}
1
+ {"version":3,"file":"ZoraWebStyleSheet.d.ts","sourceRoot":"","sources":["../../../../../src/features/layout/adapters/inbound/ZoraWebStyleSheet.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAQ1B,0FAA0F;AAC1F,wBAAgB,iBAAiB;;;;;uBAQhC"}
@@ -5,9 +5,10 @@ export function ZoraWebStyleSheet() {
5
5
  const sheet = getReactNativeWebStyleSheet();
6
6
  if (sheet === null)
7
7
  return null;
8
- return (<style id={sheet.id} precedence="react-native-web">
9
- {sheet.textContent}
10
- </style>);
8
+ return React.createElement('style', {
9
+ dangerouslySetInnerHTML: { __html: sheet.textContent },
10
+ id: sheet.id,
11
+ });
11
12
  }
12
13
  /*** Reads React Native Web's public stylesheet without changing native rendering. */
13
14
  function getReactNativeWebStyleSheet() {
@@ -1 +1 @@
1
- {"version":3,"file":"ZoraWebStyleSheet.js","sourceRoot":"","sources":["../../../../../src/features/layout/adapters/inbound/ZoraWebStyleSheet.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAOpD,0FAA0F;AAC1F,MAAM,UAAU,iBAAiB;IAC/B,MAAM,KAAK,GAAG,2BAA2B,EAAE,CAAC;IAC5C,IAAI,KAAK,KAAK,IAAI;QAAE,OAAO,IAAI,CAAC;IAEhC,OAAO,CACL,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC,UAAU,CAAC,kBAAkB,CAChD;MAAA,CAAC,KAAK,CAAC,WAAW,CACpB;IAAA,EAAE,KAAK,CAAC,CACT,CAAC;AACJ,CAAC;AAED,qFAAqF;AACrF,SAAS,2BAA2B;IAClC,IAAI,QAAQ,CAAC,EAAE,KAAK,KAAK,IAAI,CAAC,CAAC,UAAU,IAAI,UAAU,CAAC;QAAE,OAAO,IAAI,CAAC;IAEtE,OAAQ,UAAU,CAAC,QAA2C,EAAE,CAAC;AACnE,CAAC","sourcesContent":["import React from 'react';\nimport { Platform, StyleSheet } from 'react-native';\n\ntype ReactNativeWebStyleSheet = Readonly<{\n id: string;\n textContent: string;\n}>;\n\n/*** Hoists the React Native Web styles required by a server-rendered ZORA application. */\nexport function ZoraWebStyleSheet() {\n const sheet = getReactNativeWebStyleSheet();\n if (sheet === null) return null;\n\n return (\n <style id={sheet.id} precedence=\"react-native-web\">\n {sheet.textContent}\n </style>\n );\n}\n\n/*** Reads React Native Web's public stylesheet without changing native rendering. */\nfunction getReactNativeWebStyleSheet(): ReactNativeWebStyleSheet | null {\n if (Platform.OS !== 'web' || !('getSheet' in StyleSheet)) return null;\n\n return (StyleSheet.getSheet as () => ReactNativeWebStyleSheet)();\n}\n"]}
1
+ {"version":3,"file":"ZoraWebStyleSheet.js","sourceRoot":"","sources":["../../../../../src/features/layout/adapters/inbound/ZoraWebStyleSheet.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAOpD,0FAA0F;AAC1F,MAAM,UAAU,iBAAiB;IAC/B,MAAM,KAAK,GAAG,2BAA2B,EAAE,CAAC;IAC5C,IAAI,KAAK,KAAK,IAAI;QAAE,OAAO,IAAI,CAAC;IAEhC,OAAO,KAAK,CAAC,aAAa,CAAC,OAAO,EAAE;QAClC,uBAAuB,EAAE,EAAE,MAAM,EAAE,KAAK,CAAC,WAAW,EAAE;QACtD,EAAE,EAAE,KAAK,CAAC,EAAE;KACb,CAAC,CAAC;AACL,CAAC;AAED,qFAAqF;AACrF,SAAS,2BAA2B;IAClC,IAAI,QAAQ,CAAC,EAAE,KAAK,KAAK,IAAI,CAAC,CAAC,UAAU,IAAI,UAAU,CAAC;QAAE,OAAO,IAAI,CAAC;IAEtE,OAAQ,UAAU,CAAC,QAA2C,EAAE,CAAC;AACnE,CAAC","sourcesContent":["import React from 'react';\nimport { Platform, StyleSheet } from 'react-native';\n\ntype ReactNativeWebStyleSheet = Readonly<{\n id: string;\n textContent: string;\n}>;\n\n/*** Hoists the React Native Web styles required by a server-rendered ZORA application. */\nexport function ZoraWebStyleSheet() {\n const sheet = getReactNativeWebStyleSheet();\n if (sheet === null) return null;\n\n return React.createElement('style', {\n dangerouslySetInnerHTML: { __html: sheet.textContent },\n id: sheet.id,\n });\n}\n\n/*** Reads React Native Web's public stylesheet without changing native rendering. */\nfunction getReactNativeWebStyleSheet(): ReactNativeWebStyleSheet | null {\n if (Platform.OS !== 'web' || !('getSheet' in StyleSheet)) return null;\n\n return (StyleSheet.getSheet as () => ReactNativeWebStyleSheet)();\n}\n"]}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@ankhorage/zora",
3
3
  "type": "module",
4
- "version": "28.7.2",
4
+ "version": "28.7.4",
5
5
  "description": "Opinionated React Native and React Native Web UI kit built on @ankhorage/surface.",
6
6
  "homepage": "https://github.com/ankhorage/zora#readme",
7
7
  "bugs": {
@@ -193,7 +193,7 @@
193
193
  "version-packages": "ankhorage-changeset version"
194
194
  },
195
195
  "devDependencies": {
196
- "@ankhorage/devtools": "^2.12.19",
196
+ "@ankhorage/devtools": "^2.12.20",
197
197
  "@ankhorage/paradox": "^0.6.2",
198
198
  "@react-native-vector-icons/fontawesome": "^14.0.0",
199
199
  "@react-native-vector-icons/fontawesome5": "^14.0.0",
@@ -54,6 +54,9 @@ export function Carousel({
54
54
  initialSlide ? new Set([initialSlide.key]) : new Set(),
55
55
  );
56
56
  const [readySlideKeys, setReadySlideKeys] = React.useState<ReadonlySet<string>>(() => new Set());
57
+ const [completedSlideKeys, setCompletedSlideKeys] = React.useState<ReadonlySet<string>>(
58
+ () => new Set(),
59
+ );
57
60
  const {
58
61
  activeIndex,
59
62
  controlledWithoutHandler,
@@ -100,13 +103,17 @@ export function Carousel({
100
103
  }, [activeSlideKey, nextSlideKey, readySlideKeys]);
101
104
 
102
105
  // Stable identity: layers run animations from effects, so a changing callback would restart them.
103
- const completeTransition = React.useCallback((completedSlideKey: string) => {
106
+ const completeTransition = React.useCallback((completedSlideKey: string, immediate: boolean) => {
104
107
  const {
105
108
  activeSlideKey: currentKey,
106
109
  nextSlideKey: currentNextKey,
107
110
  readySlideKeys: ready,
108
111
  } = transitionStateRef.current;
109
112
  if (!currentKey || completedSlideKey !== currentKey) return;
113
+ if (!immediate && !ready.has(currentKey)) {
114
+ setCompletedSlideKeys((current) => ensureMountedSlide(current, currentKey));
115
+ return;
116
+ }
110
117
  const transitionRetentionKeys = [currentKey, currentNextKey].filter(
111
118
  (slideKey): slideKey is string => slideKey !== undefined,
112
119
  );
@@ -118,8 +125,23 @@ export function Carousel({
118
125
  ),
119
126
  ),
120
127
  );
128
+ setCompletedSlideKeys((current) => {
129
+ if (!current.has(currentKey)) return current;
130
+ return new Set([...current].filter((slideKey) => slideKey !== currentKey));
131
+ });
121
132
  }, []);
122
133
 
134
+ React.useLayoutEffect(() => {
135
+ if (
136
+ !activeSlideKey ||
137
+ !completedSlideKeys.has(activeSlideKey) ||
138
+ !readySlideKeys.has(activeSlideKey)
139
+ ) {
140
+ return;
141
+ }
142
+ completeTransition(activeSlideKey, false);
143
+ }, [activeSlideKey, completedSlideKeys, completeTransition, readySlideKeys]);
144
+
123
145
  if (slides.length === 0) return null;
124
146
 
125
147
  const canPrevious = enabledLoop || activeIndex > 0;
@@ -204,7 +226,7 @@ interface CarouselLayerProps {
204
226
  readonly imageStyle: CarouselProps['imageStyle'];
205
227
  readonly initialScale?: CarouselProps['initialScale'];
206
228
  readonly onImageLoad: () => void;
207
- readonly onTransitionComplete: (slideKey: string) => void;
229
+ readonly onTransitionComplete: (slideKey: string, immediate: boolean) => void;
208
230
  readonly renderImage: CarouselProps['renderImage'];
209
231
  readonly resizeMode: CarouselProps['resizeMode'];
210
232
  readonly slide: CarouselSlide;
@@ -261,7 +283,7 @@ function CarouselLayer({
261
283
  opacity.setValue(active ? 1 : 0);
262
284
  scale.setValue(1);
263
285
  offset.setValue(0);
264
- if (active) onTransitionComplete(slide.key);
286
+ if (active) onTransitionComplete(slide.key, true);
265
287
  return;
266
288
  }
267
289
  if (transition === 'slide') {
@@ -284,7 +306,7 @@ function CarouselLayer({
284
306
  useNativeDriver: true,
285
307
  }),
286
308
  ]).start(({ finished }) => {
287
- if (active && finished) onTransitionComplete(slide.key);
309
+ if (active && finished) onTransitionComplete(slide.key, false);
288
310
  });
289
311
  } else if (active) {
290
312
  opacity.setValue(0);
@@ -303,7 +325,7 @@ function CarouselLayer({
303
325
  useNativeDriver: true,
304
326
  }),
305
327
  ]).start(({ finished }) => {
306
- if (finished) onTransitionComplete(slide.key);
328
+ if (finished) onTransitionComplete(slide.key, false);
307
329
  });
308
330
  } else {
309
331
  Animated.timing(opacity, {
@@ -7,6 +7,7 @@ import { Surface } from '../../../../surface/public';
7
7
  import { withZoraThemeScope } from '../../../../theme/adapters/inbound/withZoraThemeScope';
8
8
  import { SelectField } from '../../composition/SelectField';
9
9
  import { SelectOptionRow } from '../../composition/SelectOptionRow';
10
+ import { SelectOptionsList } from '../../composition/SelectOptionsList';
10
11
  import { SelectSearchInput } from '../../composition/SelectSearchInput';
11
12
  import { SelectTrigger } from '../../composition/SelectTrigger';
12
13
  import { useSelectController } from '../../composition/useSelectController';
@@ -53,16 +54,18 @@ function SelectInner<TValue extends string = string>({
53
54
  <Surface variant="raised">
54
55
  <View gap="xs" p="xs">
55
56
  <SelectSearchInput onSearchChange={search} props={props} searchValue={searchValue} />
56
- {visibleOptions.map((option) => (
57
- <SelectOptionRow
58
- interactionPolicy={interactionPolicy}
59
- key={option.value}
60
- onSelect={selectAndClose}
61
- option={option}
62
- selected={value === option.value}
63
- testID={testID}
64
- />
65
- ))}
57
+ <SelectOptionsList searchable={props.searchable}>
58
+ {visibleOptions.map((option) => (
59
+ <SelectOptionRow
60
+ interactionPolicy={interactionPolicy}
61
+ key={option.value}
62
+ onSelect={selectAndClose}
63
+ option={option}
64
+ selected={value === option.value}
65
+ testID={testID}
66
+ />
67
+ ))}
68
+ </SelectOptionsList>
66
69
  </View>
67
70
  </Surface>
68
71
  </Popover>
@@ -0,0 +1,29 @@
1
+ import type React from 'react';
2
+ import { useWindowDimensions } from 'react-native';
3
+
4
+ import { ScrollView, View } from '../../../layout/public';
5
+
6
+ // Anchored popovers keep a viewport edge gap on both sides and Select adds its surface padding.
7
+ const OPTIONS_LIST_VIEWPORT_MARGIN = 32;
8
+ // The optional search control occupies the popover above the list.
9
+ const OPTIONS_LIST_SEARCH_ALLOWANCE = 56;
10
+ const OPTIONS_LIST_MIN_HEIGHT = 120;
11
+
12
+ /*** Renders Select options in a viewport-bounded scroll container so wheel, pointer and selection work inside any overlay host. */
13
+ export function SelectOptionsList({ children, searchable }: SelectOptionsListProps) {
14
+ const { height: viewportHeight } = useWindowDimensions();
15
+ const reservedHeight =
16
+ OPTIONS_LIST_VIEWPORT_MARGIN + (searchable ? OPTIONS_LIST_SEARCH_ALLOWANCE : 0);
17
+ const maxHeight = Math.max(OPTIONS_LIST_MIN_HEIGHT, viewportHeight - reservedHeight);
18
+
19
+ return (
20
+ <ScrollView maxHeight={maxHeight}>
21
+ <View gap="xs">{children}</View>
22
+ </ScrollView>
23
+ );
24
+ }
25
+
26
+ interface SelectOptionsListProps {
27
+ readonly children: React.ReactNode;
28
+ readonly searchable: boolean | undefined;
29
+ }
@@ -11,11 +11,10 @@ export function ZoraWebStyleSheet() {
11
11
  const sheet = getReactNativeWebStyleSheet();
12
12
  if (sheet === null) return null;
13
13
 
14
- return (
15
- <style id={sheet.id} precedence="react-native-web">
16
- {sheet.textContent}
17
- </style>
18
- );
14
+ return React.createElement('style', {
15
+ dangerouslySetInnerHTML: { __html: sheet.textContent },
16
+ id: sheet.id,
17
+ });
19
18
  }
20
19
 
21
20
  /*** Reads React Native Web's public stylesheet without changing native rendering. */