@ankhorage/zora 27.7.1 → 27.9.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (300) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/README.md +2 -2
  3. package/dist/capabilities/index.js +50 -1
  4. package/dist/capabilities/index.js.map +6 -5
  5. package/dist/constants/authoring.d.ts +4 -3
  6. package/dist/constants/authoring.d.ts.map +1 -1
  7. package/dist/constants/authoring.js +2 -0
  8. package/dist/constants/authoring.js.map +1 -1
  9. package/dist/features/accordion/accordionItemMeta.d.ts +1 -1
  10. package/dist/features/bottom-sheet/bottomSheetMeta.d.ts +1 -1
  11. package/dist/features/card/cardMeta.d.ts +1 -1
  12. package/dist/features/card/mediaCardMeta.d.ts +1 -1
  13. package/dist/features/card/postCardMeta.d.ts +1 -1
  14. package/dist/features/carousel/Carousel.d.ts +8 -0
  15. package/dist/features/carousel/Carousel.d.ts.map +1 -0
  16. package/dist/features/carousel/Carousel.js +203 -0
  17. package/dist/features/carousel/Carousel.js.map +1 -0
  18. package/dist/features/carousel/public.d.ts +3 -0
  19. package/dist/features/carousel/public.d.ts.map +1 -0
  20. package/dist/features/carousel/public.js +2 -0
  21. package/dist/features/carousel/public.js.map +1 -0
  22. package/dist/features/carousel/useCarouselPlayback.d.ts +15 -0
  23. package/dist/features/carousel/useCarouselPlayback.d.ts.map +1 -0
  24. package/dist/features/carousel/useCarouselPlayback.js +74 -0
  25. package/dist/features/carousel/useCarouselPlayback.js.map +1 -0
  26. package/dist/features/chat/messageBubbleMeta.d.ts +1 -1
  27. package/dist/features/dialog/dialogMeta.d.ts +2 -2
  28. package/dist/features/gradient/gradientMeta.d.ts +1 -1
  29. package/dist/features/keyboard-avoiding-view/keyboardAvoidingViewMeta.d.ts +1 -1
  30. package/dist/features/layout/adapters/inbound/Screen.d.ts.map +1 -1
  31. package/dist/features/layout/adapters/inbound/Screen.js +1 -1
  32. package/dist/features/layout/adapters/inbound/Screen.js.map +1 -1
  33. package/dist/features/layout/gridMeta.d.ts +1 -1
  34. package/dist/features/layout/screenMeta.d.ts +1 -1
  35. package/dist/features/layout/scrollViewMeta.d.ts +1 -1
  36. package/dist/features/layout/viewMeta.d.ts +1 -1
  37. package/dist/features/list/flatListMeta.d.ts +1 -1
  38. package/dist/features/list/sectionListMeta.d.ts +1 -1
  39. package/dist/features/master-detail/adapters/inbound/MasterDetail.d.ts +5 -0
  40. package/dist/features/master-detail/adapters/inbound/MasterDetail.d.ts.map +1 -0
  41. package/dist/features/master-detail/adapters/inbound/MasterDetail.js +39 -0
  42. package/dist/features/master-detail/adapters/inbound/MasterDetail.js.map +1 -0
  43. package/dist/features/master-detail/application/resolveMasterDetailPresentation.d.ts +6 -0
  44. package/dist/features/master-detail/application/resolveMasterDetailPresentation.d.ts.map +1 -0
  45. package/dist/features/master-detail/application/resolveMasterDetailPresentation.js +7 -0
  46. package/dist/features/master-detail/application/resolveMasterDetailPresentation.js.map +1 -0
  47. package/dist/features/master-detail/masterDetailMeta.d.ts +52 -0
  48. package/dist/features/master-detail/masterDetailMeta.d.ts.map +1 -0
  49. package/dist/features/master-detail/masterDetailMeta.js +47 -0
  50. package/dist/features/master-detail/masterDetailMeta.js.map +1 -0
  51. package/dist/features/master-detail/public.d.ts +3 -0
  52. package/dist/features/master-detail/public.d.ts.map +1 -0
  53. package/dist/features/master-detail/public.js +2 -0
  54. package/dist/features/master-detail/public.js.map +1 -0
  55. package/dist/features/reader/meta.d.ts +2 -2
  56. package/dist/features/registry/ZORA_BASE_COMPONENT_REGISTRY.d.ts.map +1 -1
  57. package/dist/features/registry/ZORA_BASE_COMPONENT_REGISTRY.js +2 -0
  58. package/dist/features/registry/ZORA_BASE_COMPONENT_REGISTRY.js.map +1 -1
  59. package/dist/features/registry/bindableComponentMeta.d.ts +2 -2
  60. package/dist/features/registry/componentMeta.d.ts.map +1 -1
  61. package/dist/features/registry/componentMeta.js +2 -0
  62. package/dist/features/registry/componentMeta.js.map +1 -1
  63. package/dist/features/scanner/meta.d.ts +2 -2
  64. package/dist/features/section/screenSectionMeta.d.ts +1 -1
  65. package/dist/features/surface/surfaceMeta.d.ts +1 -1
  66. package/dist/features/tabs/tabPanelMeta.d.ts +1 -1
  67. package/dist/index.d.ts +4 -0
  68. package/dist/index.d.ts.map +1 -1
  69. package/dist/index.js +2 -0
  70. package/dist/index.js.map +1 -1
  71. package/dist/readerFree.d.ts +2 -0
  72. package/dist/readerFree.d.ts.map +1 -1
  73. package/dist/readerFree.js +1 -0
  74. package/dist/readerFree.js.map +1 -1
  75. package/dist/types/carousel.d.ts +52 -0
  76. package/dist/types/carousel.d.ts.map +1 -0
  77. package/dist/types/carousel.js +2 -0
  78. package/dist/types/carousel.js.map +1 -0
  79. package/dist/types/master-detail.d.ts +21 -0
  80. package/dist/types/master-detail.d.ts.map +1 -0
  81. package/dist/types/master-detail.js +2 -0
  82. package/dist/types/master-detail.js.map +1 -0
  83. package/package.json +1 -1
  84. package/src/constants/authoring.ts +2 -0
  85. package/src/features/carousel/Carousel.test.ts +66 -0
  86. package/src/features/carousel/Carousel.tsx +470 -0
  87. package/src/features/carousel/public.ts +2 -0
  88. package/src/features/carousel/useCarouselPlayback.ts +103 -0
  89. package/src/features/layout/adapters/inbound/Screen.tsx +3 -0
  90. package/src/features/master-detail/adapters/inbound/MasterDetail.runtime.test.tsx +121 -0
  91. package/src/features/master-detail/adapters/inbound/MasterDetail.tsx +75 -0
  92. package/src/features/master-detail/application/resolveMasterDetailPresentation.test.ts +18 -0
  93. package/src/features/master-detail/application/resolveMasterDetailPresentation.ts +15 -0
  94. package/src/features/master-detail/masterDetailMeta.ts +49 -0
  95. package/src/features/master-detail/public.ts +7 -0
  96. package/src/features/registry/ZORA_BASE_COMPONENT_REGISTRY.ts +2 -0
  97. package/src/features/registry/componentMeta.test.ts +16 -0
  98. package/src/features/registry/componentMeta.ts +2 -0
  99. package/src/features/registry/featureManifest.test.ts +2 -0
  100. package/src/index.ts +9 -0
  101. package/src/readerFree.ts +7 -0
  102. package/src/types/carousel.ts +60 -0
  103. package/src/types/master-detail.ts +25 -0
  104. package/web-dist/chunks/{Accordion-p2f0e4pn.js → Accordion-0bgzetnd.js} +6 -6
  105. package/web-dist/chunks/{Accordion-wvghkwxx.js → Accordion-0yn2b3ha.js} +9 -9
  106. package/web-dist/chunks/{Accordion-9d3rd7ne.js → Accordion-19zt3dyq.js} +1 -1
  107. package/web-dist/chunks/{Accordion-sxzts6bj.js → Accordion-1k7pyxdd.js} +2 -2
  108. package/web-dist/chunks/{Accordion-ew2cebyd.js → Accordion-1mjn0atk.js} +4 -4
  109. package/web-dist/chunks/{Accordion-ms1y70gq.js → Accordion-6qesggn9.js} +4 -4
  110. package/web-dist/chunks/{Accordion-e8dg1z2s.js → Accordion-6y42ws4p.js} +2 -2
  111. package/web-dist/chunks/{Accordion-jh94mg56.js → Accordion-70hh6g1f.js} +9 -9
  112. package/web-dist/chunks/{Accordion-wx0jp5cn.js → Accordion-7qb7741m.js} +7 -7
  113. package/web-dist/chunks/{Accordion-rwc34cn2.js → Accordion-818avkay.js} +5 -5
  114. package/web-dist/chunks/{Accordion-t2cvrn0r.js → Accordion-8ahdjt13.js} +8 -8
  115. package/web-dist/chunks/{Accordion-j6bs1yfn.js → Accordion-8vw4k0s6.js} +2 -2
  116. package/web-dist/chunks/{Accordion-m3xb7z7j.js → Accordion-8y13469y.js} +8 -8
  117. package/web-dist/chunks/{Accordion-4kmh6s2k.js → Accordion-91v243pz.js} +2 -2
  118. package/web-dist/chunks/{Accordion-8vcs6nz6.js → Accordion-9cpm8x92.js} +1 -1
  119. package/web-dist/chunks/{Accordion-vq8zrnwh.js → Accordion-9kkfz7s8.js} +4 -4
  120. package/web-dist/chunks/{Accordion-6jsea4e0.js → Accordion-ajgffs75.js} +8 -8
  121. package/web-dist/chunks/{Accordion-hf4nfkn0.js → Accordion-bednnpzh.js} +13 -13
  122. package/web-dist/chunks/{Accordion-c44m1q0m.js → Accordion-ctcxh9pk.js} +3 -3
  123. package/web-dist/chunks/{Accordion-fbehwpr1.js → Accordion-dnfrzbpb.js} +7 -7
  124. package/web-dist/chunks/{Accordion-f2n2zz1x.js → Accordion-ea0ag7wf.js} +6 -6
  125. package/web-dist/chunks/{Accordion-260pyaxy.js → Accordion-g45xga4b.js} +5 -5
  126. package/web-dist/chunks/{Accordion-yb4as6wc.js → Accordion-gjeaevge.js} +5 -5
  127. package/web-dist/chunks/{Accordion-7788ybcs.js → Accordion-grtf75xt.js} +4 -4
  128. package/web-dist/chunks/{Accordion-9hcbf56f.js → Accordion-h4928ex8.js} +2 -2
  129. package/web-dist/chunks/{Accordion-mrhkw8n6.js → Accordion-hqg1zbxk.js} +6 -4
  130. package/web-dist/chunks/{Accordion-gysa24fk.js → Accordion-j5wsx41j.js} +1 -1
  131. package/web-dist/chunks/{Accordion-yrzm02g2.js → Accordion-jmhn8mm5.js} +5 -5
  132. package/web-dist/chunks/{Accordion-252dr90x.js → Accordion-jsapannb.js} +4 -4
  133. package/web-dist/chunks/{Accordion-b4yr6yq3.js → Accordion-jsdjgfn2.js} +2 -2
  134. package/web-dist/chunks/{Accordion-8ac6dkcs.js → Accordion-k058095e.js} +1 -1
  135. package/web-dist/chunks/Accordion-kcx57mk5.js +39 -0
  136. package/web-dist/chunks/{Accordion-5z8pbn4z.js → Accordion-nbje2ywp.js} +3 -3
  137. package/web-dist/chunks/{Accordion-tpd1vvy9.js → Accordion-ng79nxzz.js} +1 -38
  138. package/web-dist/chunks/{Accordion-7mnan4q4.js → Accordion-qw6tzn3f.js} +6 -6
  139. package/web-dist/chunks/{Accordion-w0prbwy0.js → Accordion-qx45gtx9.js} +8 -8
  140. package/web-dist/chunks/{Accordion-rcs75kj4.js → Accordion-r6gwemh9.js} +3 -3
  141. package/web-dist/chunks/{Accordion-s9nbkzky.js → Accordion-rt4jfq2r.js} +2 -2
  142. package/web-dist/chunks/{Accordion-r86ce0wj.js → Accordion-t11cptjk.js} +4 -4
  143. package/web-dist/chunks/{Accordion-jx9tc6p1.js → Accordion-th8pkeqc.js} +4 -4
  144. package/web-dist/chunks/{Accordion-tnt1txfq.js → Accordion-tkxddb2c.js} +4 -4
  145. package/web-dist/chunks/{Accordion-5pbvgvqc.js → Accordion-tnq8bt8v.js} +2 -2
  146. package/web-dist/chunks/{Accordion-nnhznqgf.js → Accordion-ttjyk97v.js} +2 -2
  147. package/web-dist/chunks/{Accordion-r6zvzrkd.js → Accordion-v21vz0cg.js} +7 -4
  148. package/web-dist/chunks/{Accordion-0j4xzcwz.js → Accordion-vdqc8rxv.js} +3 -3
  149. package/web-dist/chunks/{Accordion-a8k3cvj0.js → Accordion-w1ag7sr4.js} +2 -2
  150. package/web-dist/chunks/{Accordion-vzgpdtr2.js → Accordion-wdby2v5r.js} +1 -1
  151. package/web-dist/chunks/{Accordion-zj4wnm3e.js → Accordion-wgc67k1g.js} +1 -1
  152. package/web-dist/chunks/{Accordion-p7mxkxhs.js → Accordion-x3em7tpd.js} +9 -9
  153. package/web-dist/chunks/{Accordion-mpebzjby.js → Accordion-xb2nj0q6.js} +4 -4
  154. package/web-dist/chunks/{Accordion-001ymezm.js → Accordion-y524ph0g.js} +1 -1
  155. package/web-dist/chunks/{Accordion-np16p9mh.js → Accordion-zexve9d3.js} +4 -4
  156. package/web-dist/chunks/{Accordion-4c7hqeg3.js → Accordion-zvpkhqb7.js} +2 -2
  157. package/web-dist/chunks/{Accordion-kcca65d8.js → Accordion-zxergnck.js} +5 -5
  158. package/web-dist/chunks/{Accordion-hh48jjhk.js → Accordion-zyah4pvq.js} +7 -7
  159. package/web-dist/chunks/{Accordion-8j7t77tf.js → Accordion-zymf1mp8.js} +5 -5
  160. package/web-dist/components/accordion/Accordion.js +12 -11
  161. package/web-dist/components/accordion-item/AccordionItem.js +12 -11
  162. package/web-dist/components/activity-indicator/ActivityIndicator.js +4 -3
  163. package/web-dist/components/app-bar/AppBar.js +18 -17
  164. package/web-dist/components/app-header/AppHeader.js +18 -17
  165. package/web-dist/components/app-shell/AppShell.js +6 -5
  166. package/web-dist/components/auth-screen/AuthScreen.js +23 -22
  167. package/web-dist/components/avatar/Avatar.js +12 -11
  168. package/web-dist/components/avatar-group/AvatarGroup.js +12 -11
  169. package/web-dist/components/badge/Badge.js +7 -6
  170. package/web-dist/components/barcode-scanner-view/BarcodeScannerView.js +21 -20
  171. package/web-dist/components/bottom-sheet/BottomSheet.js +8 -7
  172. package/web-dist/components/bottom-sheet-flat-list/BottomSheetFlatList.js +8 -7
  173. package/web-dist/components/bottom-sheet-scroll-view/BottomSheetScrollView.js +8 -7
  174. package/web-dist/components/bottom-sheet-section-list/BottomSheetSectionList.js +8 -7
  175. package/web-dist/components/bottom-sheet-view/BottomSheetView.js +8 -7
  176. package/web-dist/components/bottom-sheet-virtualized-list/BottomSheetVirtualizedList.js +8 -7
  177. package/web-dist/components/breadcrumbs/Breadcrumbs.js +15 -14
  178. package/web-dist/components/button/Button.js +13 -12
  179. package/web-dist/components/button-group/ButtonGroup.js +13 -12
  180. package/web-dist/components/calendar/Calendar.js +15 -14
  181. package/web-dist/components/camera-permission-view/CameraPermissionView.js +21 -20
  182. package/web-dist/components/card/Card.js +20 -19
  183. package/web-dist/components/card-back/CardBack.js +5 -4
  184. package/web-dist/components/card-hand/CardHand.js +5 -4
  185. package/web-dist/components/carousel/Carousel.d.ts +10 -0
  186. package/web-dist/components/carousel/Carousel.js +483 -0
  187. package/web-dist/components/carousel/Carousel.types-0.d.ts +55 -0
  188. package/web-dist/components/carousel/index.d.ts +2 -0
  189. package/web-dist/components/carousel/index.js +2 -0
  190. package/web-dist/components/chat-list-item/ChatListItem.js +16 -15
  191. package/web-dist/components/checkbox/Checkbox.js +12 -11
  192. package/web-dist/components/checkbox-group/CheckboxGroup.js +12 -11
  193. package/web-dist/components/chess-board/ChessBoard.js +5 -4
  194. package/web-dist/components/chip/Chip.js +13 -12
  195. package/web-dist/components/chip-group/ChipGroup.js +13 -12
  196. package/web-dist/components/collection-editor/CollectionEditor.js +20 -19
  197. package/web-dist/components/color-hue-scale/ColorHueScale.js +16 -15
  198. package/web-dist/components/color-picker/ColorPicker.js +16 -15
  199. package/web-dist/components/color-tone/ColorTone.js +16 -15
  200. package/web-dist/components/color-wheel/ColorWheel.js +16 -15
  201. package/web-dist/components/content-rail/ContentRail.js +14 -13
  202. package/web-dist/components/data-table/DataTable.js +26 -25
  203. package/web-dist/components/date-picker/DatePicker.js +19 -18
  204. package/web-dist/components/dialog/Dialog.js +11 -10
  205. package/web-dist/components/divider/Divider.js +6 -5
  206. package/web-dist/components/empty-state/EmptyState.js +21 -20
  207. package/web-dist/components/explorer/Explorer.js +13 -12
  208. package/web-dist/components/field/Field.js +12 -11
  209. package/web-dist/components/file-explorer/FileExplorer.js +13 -12
  210. package/web-dist/components/flat-list/FlatList.js +13 -12
  211. package/web-dist/components/forgot-password-form/ForgotPasswordForm.js +23 -22
  212. package/web-dist/components/form/Form.js +17 -16
  213. package/web-dist/components/form-actions/FormActions.js +17 -16
  214. package/web-dist/components/form-error/FormError.js +17 -16
  215. package/web-dist/components/game/Game.js +7 -6
  216. package/web-dist/components/game-entity/GameEntity.js +7 -6
  217. package/web-dist/components/game-field/GameField.js +7 -6
  218. package/web-dist/components/game-input-zone/GameInputZone.js +7 -6
  219. package/web-dist/components/game-measurement-probe/GameMeasurementProbe.js +7 -6
  220. package/web-dist/components/game-overlay/GameOverlay.js +7 -6
  221. package/web-dist/components/gradient/Gradient.js +7 -6
  222. package/web-dist/components/gradient-renderer-provider/GradientRendererProvider.js +7 -6
  223. package/web-dist/components/grid/Grid.js +6 -5
  224. package/web-dist/components/grid-line-overlay/GridLineOverlay.js +5 -4
  225. package/web-dist/components/grid-ruler/GridRuler.js +5 -4
  226. package/web-dist/components/heading/Heading.js +7 -6
  227. package/web-dist/components/hero/Hero.js +20 -19
  228. package/web-dist/components/icon/Icon.js +5 -4
  229. package/web-dist/components/icon-button/IconButton.js +13 -12
  230. package/web-dist/components/image/Image.js +10 -9
  231. package/web-dist/components/keyboard-avoiding-view/KeyboardAvoidingView.js +4 -3
  232. package/web-dist/components/list/List.js +13 -12
  233. package/web-dist/components/list-item/ListItem.js +13 -12
  234. package/web-dist/components/list-section/ListSection.js +13 -12
  235. package/web-dist/components/master-detail/MasterDetail.d.ts +7 -0
  236. package/web-dist/components/master-detail/MasterDetail.dependency-0.d.ts +27 -0
  237. package/web-dist/components/master-detail/MasterDetail.dependency-1.d.ts +3 -0
  238. package/web-dist/components/master-detail/MasterDetail.js +110 -0
  239. package/web-dist/components/master-detail/MasterDetail.types-0.d.ts +25 -0
  240. package/web-dist/components/master-detail/index.d.ts +2 -0
  241. package/web-dist/components/master-detail/index.js +2 -0
  242. package/web-dist/components/matrix-grid/MatrixGrid.js +5 -4
  243. package/web-dist/components/media-card/MediaCard.js +20 -19
  244. package/web-dist/components/media-explorer/MediaExplorer.js +13 -12
  245. package/web-dist/components/message-bubble/MessageBubble.js +16 -15
  246. package/web-dist/components/metric-card/MetricCard.js +20 -19
  247. package/web-dist/components/missing-element/MissingElement.js +11 -10
  248. package/web-dist/components/o-auth-provider-button/OAuthProviderButton.js +23 -22
  249. package/web-dist/components/o-auth-provider-list/OAuthProviderList.js +23 -22
  250. package/web-dist/components/opening-book/OpeningBook.js +5 -4
  251. package/web-dist/components/otp-form/OtpForm.js +23 -22
  252. package/web-dist/components/pagination/Pagination.js +14 -13
  253. package/web-dist/components/palette-item/PaletteItem.js +20 -19
  254. package/web-dist/components/playing-card/PlayingCard.js +5 -4
  255. package/web-dist/components/poker-training-table/PokerTrainingTable.js +5 -4
  256. package/web-dist/components/popover-menu/PopoverMenu.js +12 -11
  257. package/web-dist/components/post-card/PostCard.js +20 -19
  258. package/web-dist/components/product-card/ProductCard.js +20 -19
  259. package/web-dist/components/progress/Progress.js +10 -9
  260. package/web-dist/components/progress-ring/ProgressRing.js +10 -9
  261. package/web-dist/components/radio/Radio.js +14 -13
  262. package/web-dist/components/radio-group/RadioGroup.js +14 -13
  263. package/web-dist/components/rating/Rating.js +9 -8
  264. package/web-dist/components/reader/Reader.js +21 -20
  265. package/web-dist/components/scan-overlay/ScanOverlay.js +21 -20
  266. package/web-dist/components/screen/Screen.js +6 -5
  267. package/web-dist/components/screen-section/ScreenSection.js +10 -9
  268. package/web-dist/components/scroll-view/ScrollView.js +6 -5
  269. package/web-dist/components/search-input/SearchInput.js +15 -14
  270. package/web-dist/components/section-header/SectionHeader.js +10 -9
  271. package/web-dist/components/section-list/SectionList.js +13 -12
  272. package/web-dist/components/select/Select.js +16 -15
  273. package/web-dist/components/selectable-item/SelectableItem.js +4 -3
  274. package/web-dist/components/selection-provider/SelectionProvider.js +4 -3
  275. package/web-dist/components/sign-in-form/SignInForm.js +23 -22
  276. package/web-dist/components/sign-up-form/SignUpForm.js +23 -22
  277. package/web-dist/components/skeleton/Skeleton.js +23 -22
  278. package/web-dist/components/skeleton-card/SkeletonCard.js +23 -22
  279. package/web-dist/components/skeleton-list/SkeletonList.js +23 -22
  280. package/web-dist/components/skeleton-text/SkeletonText.js +23 -22
  281. package/web-dist/components/surface/Surface.js +7 -6
  282. package/web-dist/components/switch/Switch.js +7 -6
  283. package/web-dist/components/tab/Tab.js +7 -6
  284. package/web-dist/components/tab-list/TabList.js +7 -6
  285. package/web-dist/components/tab-panel/TabPanel.js +7 -6
  286. package/web-dist/components/tabletop-table/TabletopTable.js +5 -4
  287. package/web-dist/components/tabs/Tabs.js +7 -6
  288. package/web-dist/components/text/Text.js +7 -6
  289. package/web-dist/components/text-input/TextInput.js +15 -14
  290. package/web-dist/components/theme-mode-toggle/ThemeModeToggle.js +13 -12
  291. package/web-dist/components/time-picker/TimePicker.js +18 -17
  292. package/web-dist/components/timeline/Timeline.js +12 -11
  293. package/web-dist/components/toast/Toast.js +9 -8
  294. package/web-dist/components/toast-provider/ToastProvider.js +9 -8
  295. package/web-dist/components/toolbar/Toolbar.js +20 -19
  296. package/web-dist/components/tree-item/TreeItem.js +18 -17
  297. package/web-dist/components/uploader/Uploader.js +23 -22
  298. package/web-dist/components/view/View.js +6 -5
  299. package/web-dist/manifest.json +1787 -1617
  300. package/web-dist/runtime/ZoraProvider.js +12 -10
@@ -0,0 +1,66 @@
1
+ import { Carousel, type CarouselProps } from '@ankhorage/zora/web/carousel';
2
+ import { ZoraProvider } from '@ankhorage/zora/web/runtime';
3
+ import { expect, test } from 'bun:test';
4
+ import React from 'react';
5
+ import { renderToStaticMarkup } from 'react-dom/server';
6
+
7
+ /*** Render the published browser facade inside its real theme provider. */
8
+ function renderCarousel(props: CarouselProps): string {
9
+ return renderToStaticMarkup(
10
+ React.createElement(ZoraProvider, undefined, React.createElement(Carousel, props)),
11
+ );
12
+ }
13
+
14
+ test('renders no slides or progress with an empty collection', () => {
15
+ const html = renderCarousel({ slides: [] });
16
+ expect(html).not.toContain('<img');
17
+ expect(html).not.toContain('progress');
18
+ });
19
+
20
+ test('renders images through the consumer renderer without a Next.js dependency', () => {
21
+ const html = renderCarousel({
22
+ slides: [{ key: 'one', source: '/original.jpg', alt: 'Image' }],
23
+ renderImage: (slide) =>
24
+ React.createElement('img', {
25
+ src: typeof slide.source === 'string' ? slide.source : '',
26
+ alt: '',
27
+ }),
28
+ testID: 'carousel',
29
+ });
30
+ expect(html).toContain('/original.jpg');
31
+ expect(html).not.toContain('carousel-progress');
32
+ });
33
+
34
+ test('supports arbitrary React content without requiring image sources', () => {
35
+ const html = renderCarousel({
36
+ slides: [
37
+ { key: 'one', content: React.createElement('span', undefined, 'Discover your next idea') },
38
+ { key: 'two', content: React.createElement('span', undefined, 'Create what matters') },
39
+ ],
40
+ transition: 'none',
41
+ });
42
+ expect(html).toContain('Discover your next idea');
43
+ expect(html).toContain('Create what matters');
44
+ });
45
+
46
+ test('renders configurable accessible arrows, indicators and progress', () => {
47
+ const slides = [
48
+ { key: 'one', source: '/one.jpg' },
49
+ { key: 'two', source: '/two.jpg' },
50
+ ];
51
+ const html = renderCarousel({
52
+ slides,
53
+ showArrows: true,
54
+ showIndicators: true,
55
+ testID: 'carousel',
56
+ });
57
+ expect(html).toContain('carousel-previous');
58
+ expect(html).toContain('carousel-next');
59
+ expect(html).toContain('carousel-indicator-0');
60
+ expect(html).toContain('carousel-indicator-1');
61
+ expect(html).toContain('carousel-progress');
62
+ expect(html).toContain('Go to slide 1 of 2');
63
+ const minimal = renderCarousel({ slides, showProgress: false });
64
+ expect(minimal).not.toContain('progress');
65
+ expect(minimal).not.toContain('indicator-0');
66
+ });
@@ -0,0 +1,470 @@
1
+ import React from 'react';
2
+ import { Animated, Easing, Image, Pressable, StyleSheet, Text, View } from 'react-native';
3
+
4
+ import type { CarouselProps, CarouselSlide, CarouselTransition } from '../../types/carousel';
5
+ import { useZoraTheme } from '../theme/composition/useZoraTheme';
6
+ import { useCarouselPlayback } from './useCarouselPlayback';
7
+
8
+ /***
9
+ * Present images, arbitrary React content, or both as a cross-platform slideshow.
10
+ * A published web artifact exposes the same API without consumer source imports.
11
+ */
12
+ export function Carousel({
13
+ slides,
14
+ index,
15
+ defaultIndex,
16
+ onIndexChange,
17
+ autoPlay,
18
+ paused,
19
+ loop,
20
+ intervalMs,
21
+ transition = 'fade',
22
+ enterDurationMs = 1200,
23
+ exitDurationMs = 800,
24
+ initialScale = 1.06,
25
+ animateOnMount = false,
26
+ reducedMotion,
27
+ showProgress = true,
28
+ progressHeight = 4,
29
+ progressTrackColor,
30
+ progressIndicatorColor,
31
+ progressTrackStyle,
32
+ progressIndicatorStyle,
33
+ showArrows = false,
34
+ showIndicators = false,
35
+ previousLabel = 'Previous slide',
36
+ nextLabel = 'Next slide',
37
+ controlColor,
38
+ controlBackgroundColor,
39
+ controlsStyle,
40
+ activeIndicatorColor,
41
+ inactiveIndicatorColor,
42
+ indicatorsStyle,
43
+ resizeMode = 'cover',
44
+ imageStyle,
45
+ style,
46
+ renderImage,
47
+ testID,
48
+ }: CarouselProps) {
49
+ const { theme } = useZoraTheme();
50
+ const [width, setWidth] = React.useState(0);
51
+ const {
52
+ activeIndex,
53
+ controlledWithoutHandler,
54
+ direction,
55
+ loop: enabledLoop,
56
+ navigate,
57
+ progress,
58
+ shouldReduceMotion,
59
+ } = useCarouselPlayback({
60
+ slides,
61
+ index,
62
+ defaultIndex,
63
+ onIndexChange,
64
+ autoPlay,
65
+ paused,
66
+ loop,
67
+ intervalMs,
68
+ reducedMotion,
69
+ });
70
+
71
+ if (slides.length === 0) return null;
72
+
73
+ const canPrevious = enabledLoop || activeIndex > 0;
74
+ const canNext = enabledLoop || activeIndex < slides.length - 1;
75
+ const markerColor = activeIndicatorColor ?? theme.colors.primary;
76
+ const idleMarkerColor = inactiveIndicatorColor ?? theme.semantics.neutral.divider;
77
+
78
+ return (
79
+ <View
80
+ onLayout={(event) => setWidth(event.nativeEvent.layout.width)}
81
+ testID={testID}
82
+ style={[{ position: 'relative', overflow: 'hidden', width: '100%', height: '100%' }, style]}
83
+ >
84
+ {slides.map((slide, slideIndex) => (
85
+ <CarouselLayer
86
+ key={slide.key}
87
+ active={activeIndex === slideIndex}
88
+ animate={slides.length > 1}
89
+ animateOnMount={animateOnMount}
90
+ direction={direction}
91
+ enterDurationMs={enterDurationMs}
92
+ exitDurationMs={exitDurationMs}
93
+ imageStyle={imageStyle}
94
+ initialScale={initialScale}
95
+ reducedMotion={shouldReduceMotion}
96
+ renderImage={renderImage}
97
+ resizeMode={resizeMode}
98
+ slide={slide}
99
+ slideIndex={slideIndex}
100
+ transition={transition}
101
+ width={width}
102
+ />
103
+ ))}
104
+ <CarouselControls
105
+ activeIndex={activeIndex}
106
+ canNext={canNext}
107
+ canPrevious={canPrevious}
108
+ controlBackgroundColor={controlBackgroundColor ?? theme.semantics.surface.raised}
109
+ controlColor={controlColor ?? theme.semantics.content.default}
110
+ controlledWithoutHandler={controlledWithoutHandler}
111
+ controlsStyle={controlsStyle}
112
+ navigate={navigate}
113
+ nextLabel={nextLabel}
114
+ previousLabel={previousLabel}
115
+ show={showArrows && slides.length > 1}
116
+ testID={testID}
117
+ />
118
+ <CarouselIndicators
119
+ activeIndex={activeIndex}
120
+ activeColor={markerColor}
121
+ controlledWithoutHandler={controlledWithoutHandler}
122
+ idleColor={idleMarkerColor}
123
+ indicatorsStyle={indicatorsStyle}
124
+ navigate={navigate}
125
+ show={showIndicators && slides.length > 1}
126
+ slides={slides}
127
+ testID={testID}
128
+ />
129
+ <CarouselProgress
130
+ height={progressHeight}
131
+ indicatorColor={progressIndicatorColor ?? theme.colors.primary}
132
+ indicatorStyle={progressIndicatorStyle}
133
+ progress={progress}
134
+ show={showProgress && slides.length > 1}
135
+ testID={testID}
136
+ trackColor={progressTrackColor ?? theme.semantics.neutral.divider}
137
+ trackStyle={progressTrackStyle}
138
+ />
139
+ </View>
140
+ );
141
+ }
142
+
143
+ interface CarouselLayerProps {
144
+ readonly enterDurationMs?: CarouselProps['enterDurationMs'];
145
+ readonly exitDurationMs?: CarouselProps['exitDurationMs'];
146
+ readonly imageStyle: CarouselProps['imageStyle'];
147
+ readonly initialScale?: CarouselProps['initialScale'];
148
+ readonly renderImage: CarouselProps['renderImage'];
149
+ readonly resizeMode: CarouselProps['resizeMode'];
150
+ readonly slide: CarouselSlide;
151
+ readonly slideIndex: number;
152
+ readonly active: boolean;
153
+ readonly animate: boolean;
154
+ readonly animateOnMount: boolean;
155
+ readonly direction: 1 | -1;
156
+ readonly width: number;
157
+ readonly transition: CarouselTransition;
158
+ readonly reducedMotion: boolean;
159
+ }
160
+
161
+ /*** Keep departing slides mounted for an animated overlap without unmounting content. */
162
+ function CarouselLayer({
163
+ slide,
164
+ slideIndex,
165
+ active,
166
+ animate,
167
+ animateOnMount,
168
+ direction,
169
+ enterDurationMs = 1200,
170
+ exitDurationMs = 800,
171
+ initialScale = 1.06,
172
+ reducedMotion,
173
+ renderImage,
174
+ resizeMode,
175
+ imageStyle,
176
+ transition,
177
+ width,
178
+ }: CarouselLayerProps) {
179
+ const [opacity] = React.useState(() => new Animated.Value(active && !animateOnMount ? 1 : 0));
180
+ const [scale] = React.useState(
181
+ () => new Animated.Value(active && animateOnMount ? initialScale : 1),
182
+ );
183
+ const [offset] = React.useState(() => new Animated.Value(0));
184
+ const hasMounted = React.useRef(false);
185
+
186
+ React.useEffect(() => {
187
+ const firstRender = !hasMounted.current;
188
+ hasMounted.current = true;
189
+ if (firstRender && !animateOnMount) return;
190
+ opacity.stopAnimation();
191
+ scale.stopAnimation();
192
+ offset.stopAnimation();
193
+ if (!animate || reducedMotion || transition === 'none') {
194
+ opacity.setValue(active ? 1 : 0);
195
+ scale.setValue(1);
196
+ offset.setValue(0);
197
+ return;
198
+ }
199
+ if (transition === 'slide') {
200
+ scale.setValue(1);
201
+ if (active) {
202
+ offset.setValue(direction * width);
203
+ opacity.setValue(1);
204
+ }
205
+ Animated.parallel([
206
+ Animated.timing(offset, {
207
+ toValue: active ? 0 : -direction * width,
208
+ duration: Math.max(0, active ? enterDurationMs : exitDurationMs),
209
+ easing: Easing.bezier(0.4, 0, 0.2, 1),
210
+ useNativeDriver: true,
211
+ }),
212
+ Animated.timing(opacity, {
213
+ toValue: active ? 1 : 0,
214
+ duration: Math.max(0, active ? enterDurationMs : exitDurationMs),
215
+ easing: Easing.linear,
216
+ useNativeDriver: true,
217
+ }),
218
+ ]).start();
219
+ } else if (active) {
220
+ opacity.setValue(0);
221
+ scale.setValue(initialScale);
222
+ Animated.parallel([
223
+ Animated.timing(opacity, {
224
+ toValue: 1,
225
+ duration: Math.max(0, enterDurationMs),
226
+ easing: Easing.bezier(0.4, 0, 0.2, 1),
227
+ useNativeDriver: true,
228
+ }),
229
+ Animated.timing(scale, {
230
+ toValue: 1,
231
+ duration: Math.max(0, enterDurationMs),
232
+ easing: Easing.bezier(0.4, 0, 0.2, 1),
233
+ useNativeDriver: true,
234
+ }),
235
+ ]).start();
236
+ } else {
237
+ Animated.timing(opacity, {
238
+ toValue: 0,
239
+ duration: Math.max(0, exitDurationMs),
240
+ easing: Easing.bezier(0.4, 0, 0.2, 1),
241
+ useNativeDriver: true,
242
+ }).start();
243
+ }
244
+ return () => {
245
+ opacity.stopAnimation();
246
+ scale.stopAnimation();
247
+ offset.stopAnimation();
248
+ };
249
+ }, [
250
+ active,
251
+ animate,
252
+ animateOnMount,
253
+ direction,
254
+ enterDurationMs,
255
+ exitDurationMs,
256
+ initialScale,
257
+ offset,
258
+ opacity,
259
+ reducedMotion,
260
+ scale,
261
+ transition,
262
+ width,
263
+ ]);
264
+
265
+ return (
266
+ <Animated.View
267
+ accessibilityElementsHidden={!active}
268
+ importantForAccessibility={active ? 'auto' : 'no-hide-descendants'}
269
+ pointerEvents={active ? 'auto' : 'none'}
270
+ style={[StyleSheet.absoluteFill, { opacity, transform: [{ scale }, { translateX: offset }] }]}
271
+ >
272
+ {slide.source !== undefined ? (
273
+ renderImage ? (
274
+ renderImage(slide, slideIndex)
275
+ ) : (
276
+ <Image
277
+ accessibilityLabel={slide.alt}
278
+ accessible={Boolean(slide.alt)}
279
+ resizeMode={resizeMode}
280
+ source={typeof slide.source === 'string' ? { uri: slide.source } : slide.source}
281
+ style={[StyleSheet.absoluteFill, imageStyle]}
282
+ />
283
+ )
284
+ ) : null}
285
+ {slide.content}
286
+ </Animated.View>
287
+ );
288
+ }
289
+
290
+ interface CarouselNavigationProps {
291
+ readonly activeIndex: number;
292
+ readonly navigate: (index: number, direction: 1 | -1) => void;
293
+ readonly controlledWithoutHandler: boolean;
294
+ readonly testID: CarouselProps['testID'];
295
+ }
296
+
297
+ interface CarouselControlsProps extends CarouselNavigationProps {
298
+ readonly show: boolean;
299
+ readonly canPrevious: boolean;
300
+ readonly canNext: boolean;
301
+ readonly previousLabel: string;
302
+ readonly nextLabel: string;
303
+ readonly controlColor: string;
304
+ readonly controlBackgroundColor: string;
305
+ readonly controlsStyle: CarouselProps['controlsStyle'];
306
+ }
307
+
308
+ /*** Render optional previous/next buttons without coupling the slide content to navigation. */
309
+ function CarouselControls({
310
+ activeIndex,
311
+ canNext,
312
+ canPrevious,
313
+ controlBackgroundColor,
314
+ controlColor,
315
+ controlledWithoutHandler,
316
+ controlsStyle,
317
+ navigate,
318
+ nextLabel,
319
+ previousLabel,
320
+ show,
321
+ testID,
322
+ }: CarouselControlsProps) {
323
+ if (!show) return null;
324
+ const buttonStyle = [styles.control, { backgroundColor: controlBackgroundColor }];
325
+ const labelStyle = { color: controlColor, fontSize: 30 };
326
+ return (
327
+ <View pointerEvents="box-none" style={[styles.controls, controlsStyle]}>
328
+ <Pressable
329
+ accessibilityLabel={previousLabel}
330
+ accessibilityRole="button"
331
+ disabled={!canPrevious || controlledWithoutHandler}
332
+ onPress={() => navigate(activeIndex - 1, -1)}
333
+ style={buttonStyle}
334
+ testID={testID ? `${testID}-previous` : undefined}
335
+ >
336
+ <Text style={labelStyle}>{'‹'}</Text>
337
+ </Pressable>
338
+ <Pressable
339
+ accessibilityLabel={nextLabel}
340
+ accessibilityRole="button"
341
+ disabled={!canNext || controlledWithoutHandler}
342
+ onPress={() => navigate(activeIndex + 1, 1)}
343
+ style={buttonStyle}
344
+ testID={testID ? `${testID}-next` : undefined}
345
+ >
346
+ <Text style={labelStyle}>{'›'}</Text>
347
+ </Pressable>
348
+ </View>
349
+ );
350
+ }
351
+
352
+ interface CarouselIndicatorsProps extends CarouselNavigationProps {
353
+ readonly show: boolean;
354
+ readonly slides: CarouselProps['slides'];
355
+ readonly activeColor: string;
356
+ readonly idleColor: string;
357
+ readonly indicatorsStyle: CarouselProps['indicatorsStyle'];
358
+ }
359
+
360
+ /*** Render accessible selection dots for the currently controlled slide. */
361
+ function CarouselIndicators({
362
+ activeIndex,
363
+ activeColor,
364
+ controlledWithoutHandler,
365
+ idleColor,
366
+ indicatorsStyle,
367
+ navigate,
368
+ show,
369
+ slides,
370
+ testID,
371
+ }: CarouselIndicatorsProps) {
372
+ if (!show) return null;
373
+ return (
374
+ <View pointerEvents="box-none" style={[styles.indicators, indicatorsStyle]}>
375
+ {slides.map((slide, slideIndex) => (
376
+ <Pressable
377
+ key={slide.key}
378
+ accessibilityLabel={`Go to slide ${slideIndex + 1} of ${slides.length}`}
379
+ accessibilityRole="button"
380
+ accessibilityState={{ selected: slideIndex === activeIndex }}
381
+ disabled={controlledWithoutHandler}
382
+ onPress={() => navigate(slideIndex, slideIndex < activeIndex ? -1 : 1)}
383
+ style={[
384
+ styles.indicator,
385
+ {
386
+ backgroundColor: slideIndex === activeIndex ? activeColor : idleColor,
387
+ width: slideIndex === activeIndex ? 24 : 8,
388
+ },
389
+ ]}
390
+ testID={testID ? `${testID}-indicator-${slideIndex}` : undefined}
391
+ />
392
+ ))}
393
+ </View>
394
+ );
395
+ }
396
+
397
+ interface CarouselProgressProps {
398
+ readonly show: boolean;
399
+ readonly height: number;
400
+ readonly trackColor: string;
401
+ readonly indicatorColor: string;
402
+ readonly trackStyle: CarouselProps['progressTrackStyle'];
403
+ readonly indicatorStyle: CarouselProps['progressIndicatorStyle'];
404
+ readonly progress: Animated.Value;
405
+ readonly testID: CarouselProps['testID'];
406
+ }
407
+
408
+ /*** Render an optional linear autoplay timer without adding any required UI to slides. */
409
+ function CarouselProgress({
410
+ height,
411
+ indicatorColor,
412
+ indicatorStyle,
413
+ progress,
414
+ show,
415
+ testID,
416
+ trackColor,
417
+ trackStyle,
418
+ }: CarouselProgressProps) {
419
+ if (!show) return null;
420
+ return (
421
+ <View
422
+ pointerEvents="none"
423
+ style={[styles.progress, { height, backgroundColor: trackColor }, trackStyle]}
424
+ testID={testID ? `${testID}-progress` : undefined}
425
+ >
426
+ <Animated.View
427
+ style={[
428
+ {
429
+ height: '100%',
430
+ width: progress.interpolate({ inputRange: [0, 1], outputRange: ['0%', '100%'] }),
431
+ backgroundColor: indicatorColor,
432
+ },
433
+ indicatorStyle,
434
+ ]}
435
+ />
436
+ </View>
437
+ );
438
+ }
439
+
440
+ const styles = StyleSheet.create({
441
+ controls: {
442
+ position: 'absolute',
443
+ top: 0,
444
+ bottom: 0,
445
+ left: 14,
446
+ right: 14,
447
+ flexDirection: 'row',
448
+ justifyContent: 'space-between',
449
+ alignItems: 'center',
450
+ },
451
+ control: {
452
+ width: 44,
453
+ height: 44,
454
+ borderRadius: 22,
455
+ justifyContent: 'center',
456
+ alignItems: 'center',
457
+ },
458
+ indicators: {
459
+ position: 'absolute',
460
+ bottom: 24,
461
+ left: 0,
462
+ right: 0,
463
+ flexDirection: 'row',
464
+ gap: 10,
465
+ justifyContent: 'center',
466
+ alignItems: 'center',
467
+ },
468
+ indicator: { height: 8, borderRadius: 8 },
469
+ progress: { position: 'absolute', bottom: 0, left: 0, right: 0, overflow: 'hidden' },
470
+ });
@@ -0,0 +1,2 @@
1
+ export type { CarouselProps, CarouselSlide, CarouselTransition } from '../../types/carousel';
2
+ export { Carousel } from './Carousel';
@@ -0,0 +1,103 @@
1
+ import React from 'react';
2
+ import { AccessibilityInfo, Animated, Easing } from 'react-native';
3
+
4
+ import type { CarouselProps } from '../../types/carousel';
5
+
6
+ /*** Own controlled/uncontrolled slide navigation, autoplay, and progress lifecycle. */
7
+ export function useCarouselPlayback({
8
+ slides,
9
+ index,
10
+ defaultIndex = 0,
11
+ onIndexChange,
12
+ autoPlay = true,
13
+ paused = false,
14
+ loop = true,
15
+ intervalMs = 6000,
16
+ reducedMotion,
17
+ }: CarouselPlaybackOptions) {
18
+ const [uncontrolledIndex, setUncontrolledIndex] = React.useState(defaultIndex);
19
+ const [direction, setDirection] = React.useState<1 | -1>(1);
20
+ const [progress] = React.useState(() => new Animated.Value(0));
21
+ const systemReducedMotion = useSystemReducedMotion();
22
+ const shouldReduceMotion = reducedMotion ?? systemReducedMotion;
23
+ const activeIndex = normalizeIndex(index ?? uncontrolledIndex, slides.length);
24
+ const duration = Math.max(1, intervalMs);
25
+ const controlledWithoutHandler = index !== undefined && onIndexChange === undefined;
26
+ const canAdvance = loop || activeIndex < slides.length - 1;
27
+ const shouldPlay =
28
+ autoPlay && !paused && slides.length > 1 && canAdvance && !controlledWithoutHandler;
29
+
30
+ const navigate = React.useCallback(
31
+ (target: number, nextDirection: 1 | -1) => {
32
+ if (slides.length < 2 || controlledWithoutHandler) return;
33
+ const next = loop
34
+ ? (target + slides.length) % slides.length
35
+ : normalizeIndex(target, slides.length);
36
+ if (next === activeIndex) return;
37
+ setDirection(nextDirection);
38
+ if (index === undefined) setUncontrolledIndex(next);
39
+ onIndexChange?.(next);
40
+ },
41
+ [activeIndex, controlledWithoutHandler, index, loop, onIndexChange, slides.length],
42
+ );
43
+
44
+ React.useEffect(() => {
45
+ if (!shouldPlay) return;
46
+ const timeout = setTimeout(() => navigate(activeIndex + 1, 1), duration);
47
+ return () => clearTimeout(timeout);
48
+ }, [activeIndex, duration, navigate, shouldPlay]);
49
+
50
+ React.useEffect(() => {
51
+ progress.stopAnimation();
52
+ progress.setValue(0);
53
+ if (!shouldPlay || shouldReduceMotion) return;
54
+ const animation = Animated.timing(progress, {
55
+ toValue: 1,
56
+ duration,
57
+ easing: Easing.linear,
58
+ useNativeDriver: false,
59
+ });
60
+ animation.start();
61
+ return () => animation.stop();
62
+ }, [activeIndex, duration, progress, shouldPlay, shouldReduceMotion]);
63
+
64
+ return {
65
+ activeIndex,
66
+ controlledWithoutHandler,
67
+ direction,
68
+ loop,
69
+ navigate,
70
+ progress,
71
+ shouldReduceMotion,
72
+ } as const;
73
+ }
74
+
75
+ type CarouselPlaybackOptions = Pick<
76
+ CarouselProps,
77
+ | 'slides'
78
+ | 'index'
79
+ | 'defaultIndex'
80
+ | 'onIndexChange'
81
+ | 'autoPlay'
82
+ | 'paused'
83
+ | 'loop'
84
+ | 'intervalMs'
85
+ | 'reducedMotion'
86
+ >;
87
+
88
+ /*** Clamp a controlled index whenever the consumer changes the slide collection. */
89
+ function normalizeIndex(value: number, count: number): number {
90
+ if (count <= 0 || !Number.isFinite(value)) return 0;
91
+ return Math.min(Math.max(Math.trunc(value), 0), count - 1);
92
+ }
93
+
94
+ /*** Observe reduced-motion preferences without adding browser-only imports. */
95
+ function useSystemReducedMotion(): boolean {
96
+ const [reduced, setReduced] = React.useState(false);
97
+ React.useEffect(() => {
98
+ void AccessibilityInfo.isReduceMotionEnabled().then(setReduced);
99
+ const listener = AccessibilityInfo.addEventListener('reduceMotionChanged', setReduced);
100
+ return () => listener.remove();
101
+ }, []);
102
+ return reduced;
103
+ }
@@ -19,8 +19,11 @@ function ScreenInner({
19
19
  const content = (
20
20
  <View
21
21
  alignSelf="center"
22
+ flex={scroll ? undefined : 1}
22
23
  gap="l"
23
24
  maxWidth={resolvePageMaxWidth(width)}
25
+ minHeight={scroll ? undefined : 0}
26
+ minWidth={scroll ? undefined : 0}
24
27
  px={{ base: 16, md: 24, lg: 32 }}
25
28
  py="xl"
26
29
  testID={testID}