@hzblj/kara-components 0.6.0 → 0.8.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 (291) hide show
  1. package/CHANGELOG.md +91 -0
  2. package/README.md +31 -3
  3. package/lib/module/atoms/activity-indicator/activity-indicator.android.js +42 -0
  4. package/lib/module/atoms/activity-indicator/activity-indicator.android.js.map +1 -0
  5. package/lib/module/atoms/activity-indicator/activity-indicator.ios.js +19 -0
  6. package/lib/module/atoms/activity-indicator/activity-indicator.ios.js.map +1 -0
  7. package/lib/module/atoms/activity-indicator/activity-indicator.types.js +4 -0
  8. package/lib/module/atoms/activity-indicator/activity-indicator.types.js.map +1 -0
  9. package/lib/module/atoms/activity-indicator/index.js +2 -1
  10. package/lib/module/atoms/activity-indicator/index.js.map +1 -1
  11. package/lib/module/atoms/avatar/avatar.js +2 -4
  12. package/lib/module/atoms/avatar/avatar.js.map +1 -1
  13. package/lib/module/atoms/blur-view/blur-view.android.js +100 -0
  14. package/lib/module/atoms/blur-view/blur-view.android.js.map +1 -0
  15. package/lib/module/atoms/blur-view/blur-view.ios.js +43 -0
  16. package/lib/module/atoms/blur-view/blur-view.ios.js.map +1 -0
  17. package/lib/module/atoms/blur-view/blur-view.types.js +4 -0
  18. package/lib/module/atoms/blur-view/blur-view.types.js.map +1 -0
  19. package/lib/module/atoms/blur-view/index.js +5 -0
  20. package/lib/module/atoms/blur-view/index.js.map +1 -0
  21. package/lib/module/atoms/checkbox/checkbox.android.js +7 -3
  22. package/lib/module/atoms/checkbox/checkbox.android.js.map +1 -1
  23. package/lib/module/atoms/date-picker/date-picker.ios.js +32 -11
  24. package/lib/module/atoms/date-picker/date-picker.ios.js.map +1 -1
  25. package/lib/module/atoms/glass-view/glass-view.android.js +36 -5
  26. package/lib/module/atoms/glass-view/glass-view.android.js.map +1 -1
  27. package/lib/module/atoms/image/image.js +13 -6
  28. package/lib/module/atoms/image/image.js.map +1 -1
  29. package/lib/module/atoms/image/image.types.js +4 -0
  30. package/lib/module/atoms/image/image.types.js.map +1 -0
  31. package/lib/module/atoms/image/index.js +1 -0
  32. package/lib/module/atoms/image/index.js.map +1 -1
  33. package/lib/module/atoms/index.js +1 -1
  34. package/lib/module/atoms/index.js.map +1 -1
  35. package/lib/module/atoms/island/island.android.js +6 -2
  36. package/lib/module/atoms/island/island.android.js.map +1 -1
  37. package/lib/module/atoms/island/island.ios.js +5 -2
  38. package/lib/module/atoms/island/island.ios.js.map +1 -1
  39. package/lib/module/atoms/pressable/pressable.js +38 -6
  40. package/lib/module/atoms/pressable/pressable.js.map +1 -1
  41. package/lib/module/atoms/rn-flat-list/rn-flat-list.js +10 -9
  42. package/lib/module/atoms/rn-flat-list/rn-flat-list.js.map +1 -1
  43. package/lib/module/atoms/rn-section-list/rn-section-list.js +5 -8
  44. package/lib/module/atoms/rn-section-list/rn-section-list.js.map +1 -1
  45. package/lib/module/atoms/rn-text/rn-text.js +5 -2
  46. package/lib/module/atoms/rn-text/rn-text.js.map +1 -1
  47. package/lib/module/atoms/segmented-control/index.js +1 -1
  48. package/lib/module/atoms/segmented-control/index.js.map +1 -1
  49. package/lib/module/atoms/segmented-control/segmented-control.android.js +74 -0
  50. package/lib/module/atoms/segmented-control/segmented-control.android.js.map +1 -0
  51. package/lib/module/atoms/segmented-control/segmented-control.ios.js +44 -0
  52. package/lib/module/atoms/segmented-control/segmented-control.ios.js.map +1 -0
  53. package/lib/module/atoms/skeleton/skeleton.js +5 -5
  54. package/lib/module/atoms/skeleton/skeleton.js.map +1 -1
  55. package/lib/module/atoms/switch/switch.android.js +4 -1
  56. package/lib/module/atoms/switch/switch.android.js.map +1 -1
  57. package/lib/module/atoms/text/text.android.js +5 -2
  58. package/lib/module/atoms/text/text.android.js.map +1 -1
  59. package/lib/module/atoms/text/text.ios.js +14 -3
  60. package/lib/module/atoms/text/text.ios.js.map +1 -1
  61. package/lib/module/molecules/collapsible/collapsible.android.js +37 -7
  62. package/lib/module/molecules/collapsible/collapsible.android.js.map +1 -1
  63. package/lib/module/molecules/navigation-bar/navigation-bar.android.js +2 -8
  64. package/lib/module/molecules/navigation-bar/navigation-bar.android.js.map +1 -1
  65. package/lib/module/molecules/pager/pager.android.js +5 -4
  66. package/lib/module/molecules/pager/pager.android.js.map +1 -1
  67. package/lib/module/molecules/scroll-edge-container/scroll-edge-container.android.js +114 -11
  68. package/lib/module/molecules/scroll-edge-container/scroll-edge-container.android.js.map +1 -1
  69. package/lib/module/molecules/search-bar/search-bar.js +15 -2
  70. package/lib/module/molecules/search-bar/search-bar.js.map +1 -1
  71. package/lib/module/molecules/stepper/stepper.ios.js +45 -8
  72. package/lib/module/molecules/stepper/stepper.ios.js.map +1 -1
  73. package/lib/module/molecules/tooltip/tooltip.android.js +16 -5
  74. package/lib/module/molecules/tooltip/tooltip.android.js.map +1 -1
  75. package/lib/module/organisms/action-sheet/action-sheet.android.js +41 -20
  76. package/lib/module/organisms/action-sheet/action-sheet.android.js.map +1 -1
  77. package/lib/module/organisms/action-sheet/action-sheet.ios.js +24 -8
  78. package/lib/module/organisms/action-sheet/action-sheet.ios.js.map +1 -1
  79. package/lib/module/organisms/alert/alert.ios.js +15 -2
  80. package/lib/module/organisms/alert/alert.ios.js.map +1 -1
  81. package/lib/module/organisms/form/form.android.js +22 -9
  82. package/lib/module/organisms/form/form.android.js.map +1 -1
  83. package/lib/module/organisms/swipe-actions/swipe-actions.android.js +125 -11
  84. package/lib/module/organisms/swipe-actions/swipe-actions.android.js.map +1 -1
  85. package/lib/module/organisms/swipe-actions/swipe-actions.ios.js +46 -18
  86. package/lib/module/organisms/swipe-actions/swipe-actions.ios.js.map +1 -1
  87. package/lib/module/ripple-clip.js +9 -1
  88. package/lib/module/ripple-clip.js.map +1 -1
  89. package/lib/module/templates/screen/screen.android.js +31 -10
  90. package/lib/module/templates/screen/screen.android.js.map +1 -1
  91. package/lib/typescript/atoms/activity-indicator/activity-indicator.d.ts +1 -3
  92. package/lib/typescript/atoms/activity-indicator/activity-indicator.ios.d.ts +3 -0
  93. package/lib/typescript/atoms/activity-indicator/activity-indicator.types.d.ts +17 -0
  94. package/lib/typescript/atoms/activity-indicator/index.d.ts +1 -0
  95. package/lib/typescript/atoms/avatar/avatar.types.d.ts +5 -0
  96. package/lib/typescript/atoms/badge/badge.types.d.ts +3 -0
  97. package/lib/typescript/atoms/blur-view/blur-view.d.ts +1 -0
  98. package/lib/typescript/atoms/blur-view/blur-view.ios.d.ts +3 -0
  99. package/lib/typescript/atoms/blur-view/blur-view.types.d.ts +31 -0
  100. package/lib/typescript/atoms/blur-view/index.d.ts +2 -0
  101. package/lib/typescript/atoms/box/a-box.d.ts +1 -1
  102. package/lib/typescript/atoms/button/button.types.d.ts +12 -0
  103. package/lib/typescript/atoms/card/card.types.d.ts +6 -0
  104. package/lib/typescript/atoms/checkbox/checkbox.types.d.ts +5 -0
  105. package/lib/typescript/atoms/chip/chip.types.d.ts +5 -0
  106. package/lib/typescript/atoms/color-picker/color-picker.types.d.ts +4 -0
  107. package/lib/typescript/atoms/date-picker/date-picker.ios.d.ts +6 -1
  108. package/lib/typescript/atoms/date-picker/date-picker.types.d.ts +14 -0
  109. package/lib/typescript/atoms/divider/divider.types.d.ts +3 -0
  110. package/lib/typescript/atoms/fab/fab.types.d.ts +7 -0
  111. package/lib/typescript/atoms/glass-view/glass-view.types.d.ts +13 -5
  112. package/lib/typescript/atoms/h-stack/h-stack.types.d.ts +6 -0
  113. package/lib/typescript/atoms/icon/icon.types.d.ts +8 -0
  114. package/lib/typescript/atoms/icon-button/icon-button.types.d.ts +5 -0
  115. package/lib/typescript/atoms/image/image.d.ts +12 -4
  116. package/lib/typescript/atoms/image/image.types.d.ts +4 -0
  117. package/lib/typescript/atoms/image/index.d.ts +1 -0
  118. package/lib/typescript/atoms/index.d.ts +1 -1
  119. package/lib/typescript/atoms/island/island.types.d.ts +10 -2
  120. package/lib/typescript/atoms/list/list.types.d.ts +2 -0
  121. package/lib/typescript/atoms/picker/picker.types.d.ts +12 -0
  122. package/lib/typescript/atoms/pressable/pressable.types.d.ts +10 -0
  123. package/lib/typescript/atoms/progress/progress.types.d.ts +6 -0
  124. package/lib/typescript/atoms/rn-flat-list/rn-flat-list.d.ts +5 -8
  125. package/lib/typescript/atoms/rn-flat-list/rn-flat-list.types.d.ts +3 -1
  126. package/lib/typescript/atoms/rn-scroll-view/rn-scroll-view.types.d.ts +4 -0
  127. package/lib/typescript/atoms/rn-section-list/rn-section-list.d.ts +2 -8
  128. package/lib/typescript/atoms/rn-section-list/rn-section-list.types.d.ts +3 -1
  129. package/lib/typescript/atoms/rn-text/rn-text.types.d.ts +10 -1
  130. package/lib/typescript/atoms/rn-view/rn-view.types.d.ts +2 -0
  131. package/lib/typescript/atoms/scroll-view/scroll-view.types.d.ts +4 -0
  132. package/lib/typescript/atoms/segmented-control/segmented-control.d.ts +1 -6
  133. package/lib/typescript/atoms/segmented-control/segmented-control.ios.d.ts +7 -0
  134. package/lib/typescript/atoms/segmented-control/segmented-control.types.d.ts +13 -0
  135. package/lib/typescript/atoms/skeleton/skeleton.types.d.ts +11 -2
  136. package/lib/typescript/atoms/slider/slider.types.d.ts +7 -0
  137. package/lib/typescript/atoms/spacer/spacer.types.d.ts +3 -0
  138. package/lib/typescript/atoms/surface/surface.types.d.ts +7 -0
  139. package/lib/typescript/atoms/switch/switch.types.d.ts +8 -0
  140. package/lib/typescript/atoms/text/text.types.d.ts +18 -1
  141. package/lib/typescript/atoms/text-field/text-field.types.d.ts +12 -0
  142. package/lib/typescript/atoms/v-stack/v-stack.types.d.ts +9 -0
  143. package/lib/typescript/atoms/z-stack/z-stack.types.d.ts +8 -0
  144. package/lib/typescript/molecules/collapsible/collapsible.types.d.ts +8 -0
  145. package/lib/typescript/molecules/empty-state/empty-state.types.d.ts +5 -0
  146. package/lib/typescript/molecules/label/label.types.d.ts +6 -0
  147. package/lib/typescript/molecules/labeled-content/labeled-content.types.d.ts +6 -0
  148. package/lib/typescript/molecules/link/link.types.d.ts +6 -0
  149. package/lib/typescript/molecules/list-item/list-item.types.d.ts +9 -0
  150. package/lib/typescript/molecules/navigation-bar/navigation-bar.types.d.ts +8 -0
  151. package/lib/typescript/molecules/pager/pager.types.d.ts +2 -0
  152. package/lib/typescript/molecules/radio-group/radio-group.types.d.ts +10 -0
  153. package/lib/typescript/molecules/rn-list-item/rn-list-item.types.d.ts +1 -1
  154. package/lib/typescript/molecules/rn-tooltip/rn-tooltip.types.d.ts +11 -0
  155. package/lib/typescript/molecules/scroll-edge-container/scroll-edge-container.types.d.ts +7 -2
  156. package/lib/typescript/molecules/search-bar/search-bar.types.d.ts +8 -0
  157. package/lib/typescript/molecules/stepper/stepper.ios.d.ts +5 -0
  158. package/lib/typescript/molecules/stepper/stepper.types.d.ts +10 -0
  159. package/lib/typescript/molecules/tooltip/tooltip.types.d.ts +12 -0
  160. package/lib/typescript/organisms/action-sheet/action-sheet.types.d.ts +8 -0
  161. package/lib/typescript/organisms/alert/alert.types.d.ts +11 -0
  162. package/lib/typescript/organisms/context-menu/context-menu.types.d.ts +4 -0
  163. package/lib/typescript/organisms/fab-menu/fab-menu.types.d.ts +2 -0
  164. package/lib/typescript/organisms/form/form.types.d.ts +6 -0
  165. package/lib/typescript/organisms/menu/menu.types.d.ts +17 -0
  166. package/lib/typescript/organisms/sheet/sheet.types.d.ts +19 -0
  167. package/lib/typescript/organisms/snackbar/snackbar.types.d.ts +8 -0
  168. package/lib/typescript/organisms/swipe-actions/swipe-actions.types.d.ts +36 -13
  169. package/lib/typescript/templates/screen/screen.types.d.ts +9 -0
  170. package/package.json +5 -7
  171. package/src/atoms/activity-indicator/activity-indicator.android.tsx +32 -0
  172. package/src/atoms/activity-indicator/activity-indicator.ios.tsx +15 -0
  173. package/src/atoms/activity-indicator/activity-indicator.types.ts +20 -0
  174. package/src/atoms/activity-indicator/index.ts +1 -0
  175. package/src/atoms/avatar/avatar.tsx +1 -1
  176. package/src/atoms/avatar/avatar.types.ts +5 -0
  177. package/src/atoms/badge/badge.types.ts +3 -0
  178. package/src/atoms/blur-view/blur-view.android.tsx +68 -0
  179. package/src/atoms/blur-view/blur-view.ios.tsx +37 -0
  180. package/src/atoms/blur-view/blur-view.types.ts +34 -0
  181. package/src/atoms/blur-view/index.ts +2 -0
  182. package/src/atoms/button/button.types.ts +12 -0
  183. package/src/atoms/card/card.types.ts +6 -0
  184. package/src/atoms/checkbox/checkbox.android.tsx +7 -3
  185. package/src/atoms/checkbox/checkbox.types.ts +5 -0
  186. package/src/atoms/chip/chip.types.ts +5 -0
  187. package/src/atoms/color-picker/color-picker.types.ts +4 -0
  188. package/src/atoms/date-picker/date-picker.ios.tsx +33 -13
  189. package/src/atoms/date-picker/date-picker.types.ts +14 -0
  190. package/src/atoms/divider/divider.types.ts +3 -0
  191. package/src/atoms/fab/fab.types.ts +7 -0
  192. package/src/atoms/glass-view/glass-view.android.tsx +41 -3
  193. package/src/atoms/glass-view/glass-view.types.ts +13 -5
  194. package/src/atoms/h-stack/h-stack.types.ts +6 -0
  195. package/src/atoms/icon/icon.types.ts +8 -0
  196. package/src/atoms/icon-button/icon-button.types.ts +5 -0
  197. package/src/atoms/image/image.tsx +11 -12
  198. package/src/atoms/image/image.types.ts +6 -0
  199. package/src/atoms/image/index.ts +1 -0
  200. package/src/atoms/index.ts +1 -1
  201. package/src/atoms/island/island.android.tsx +10 -2
  202. package/src/atoms/island/island.ios.tsx +4 -2
  203. package/src/atoms/island/island.types.ts +10 -2
  204. package/src/atoms/list/list.types.ts +2 -0
  205. package/src/atoms/picker/picker.types.ts +12 -0
  206. package/src/atoms/pressable/pressable.tsx +46 -6
  207. package/src/atoms/pressable/pressable.types.ts +10 -0
  208. package/src/atoms/progress/progress.types.ts +6 -0
  209. package/src/atoms/rn-flat-list/rn-flat-list.tsx +8 -8
  210. package/src/atoms/rn-flat-list/rn-flat-list.types.ts +3 -1
  211. package/src/atoms/rn-scroll-view/rn-scroll-view.types.ts +4 -0
  212. package/src/atoms/rn-section-list/rn-section-list.tsx +5 -8
  213. package/src/atoms/rn-section-list/rn-section-list.types.ts +3 -1
  214. package/src/atoms/rn-text/rn-text.tsx +6 -3
  215. package/src/atoms/rn-text/rn-text.types.ts +15 -5
  216. package/src/atoms/rn-view/rn-view.types.ts +2 -0
  217. package/src/atoms/scroll-view/scroll-view.types.ts +4 -0
  218. package/src/atoms/segmented-control/segmented-control.android.tsx +79 -0
  219. package/src/atoms/segmented-control/segmented-control.ios.tsx +47 -0
  220. package/src/atoms/segmented-control/segmented-control.types.ts +13 -0
  221. package/src/atoms/skeleton/skeleton.tsx +4 -4
  222. package/src/atoms/skeleton/skeleton.types.ts +11 -2
  223. package/src/atoms/slider/slider.types.ts +7 -0
  224. package/src/atoms/spacer/spacer.types.ts +3 -0
  225. package/src/atoms/surface/surface.types.ts +7 -0
  226. package/src/atoms/switch/switch.android.tsx +4 -1
  227. package/src/atoms/switch/switch.types.ts +8 -0
  228. package/src/atoms/text/text.android.tsx +7 -1
  229. package/src/atoms/text/text.ios.tsx +14 -3
  230. package/src/atoms/text/text.types.ts +18 -1
  231. package/src/atoms/text-field/text-field.types.ts +12 -0
  232. package/src/atoms/v-stack/v-stack.types.ts +9 -0
  233. package/src/atoms/z-stack/z-stack.types.ts +8 -0
  234. package/src/molecules/collapsible/collapsible.android.tsx +47 -7
  235. package/src/molecules/collapsible/collapsible.types.ts +8 -0
  236. package/src/molecules/empty-state/empty-state.types.ts +5 -0
  237. package/src/molecules/label/label.types.ts +6 -0
  238. package/src/molecules/labeled-content/labeled-content.types.ts +6 -0
  239. package/src/molecules/link/link.types.ts +6 -0
  240. package/src/molecules/list-item/list-item.types.ts +9 -0
  241. package/src/molecules/navigation-bar/navigation-bar.android.tsx +1 -6
  242. package/src/molecules/navigation-bar/navigation-bar.types.ts +8 -0
  243. package/src/molecules/pager/pager.android.tsx +4 -1
  244. package/src/molecules/pager/pager.types.ts +2 -0
  245. package/src/molecules/radio-group/radio-group.types.ts +10 -0
  246. package/src/molecules/rn-list-item/rn-list-item.types.ts +1 -1
  247. package/src/molecules/rn-tooltip/rn-tooltip.types.ts +11 -0
  248. package/src/molecules/scroll-edge-container/scroll-edge-container.android.tsx +103 -10
  249. package/src/molecules/scroll-edge-container/scroll-edge-container.types.ts +7 -2
  250. package/src/molecules/search-bar/search-bar.tsx +9 -2
  251. package/src/molecules/search-bar/search-bar.types.ts +8 -0
  252. package/src/molecules/stepper/stepper.ios.tsx +37 -1
  253. package/src/molecules/stepper/stepper.types.ts +10 -0
  254. package/src/molecules/tooltip/tooltip.android.tsx +17 -9
  255. package/src/molecules/tooltip/tooltip.types.ts +12 -0
  256. package/src/organisms/action-sheet/action-sheet.android.tsx +37 -19
  257. package/src/organisms/action-sheet/action-sheet.ios.tsx +22 -9
  258. package/src/organisms/action-sheet/action-sheet.types.ts +8 -0
  259. package/src/organisms/alert/alert.ios.tsx +11 -1
  260. package/src/organisms/alert/alert.types.ts +11 -0
  261. package/src/organisms/context-menu/context-menu.types.ts +4 -0
  262. package/src/organisms/fab-menu/fab-menu.types.ts +2 -0
  263. package/src/organisms/form/form.android.tsx +15 -7
  264. package/src/organisms/form/form.types.ts +6 -0
  265. package/src/organisms/menu/menu.types.ts +17 -0
  266. package/src/organisms/sheet/sheet.types.ts +19 -0
  267. package/src/organisms/snackbar/snackbar.types.ts +8 -0
  268. package/src/organisms/swipe-actions/swipe-actions.android.tsx +129 -9
  269. package/src/organisms/swipe-actions/swipe-actions.ios.tsx +45 -11
  270. package/src/organisms/swipe-actions/swipe-actions.types.ts +37 -14
  271. package/src/ripple-clip.ts +10 -1
  272. package/src/templates/screen/screen.android.tsx +33 -12
  273. package/src/templates/screen/screen.types.ts +9 -0
  274. package/lib/module/atoms/activity-indicator/activity-indicator.js +0 -14
  275. package/lib/module/atoms/activity-indicator/activity-indicator.js.map +0 -1
  276. package/lib/module/atoms/flash-list/flash-list.js +0 -31
  277. package/lib/module/atoms/flash-list/flash-list.js.map +0 -1
  278. package/lib/module/atoms/flash-list/flash-list.types.js +0 -4
  279. package/lib/module/atoms/flash-list/flash-list.types.js.map +0 -1
  280. package/lib/module/atoms/flash-list/index.js +0 -5
  281. package/lib/module/atoms/flash-list/index.js.map +0 -1
  282. package/lib/module/atoms/segmented-control/segmented-control.js +0 -40
  283. package/lib/module/atoms/segmented-control/segmented-control.js.map +0 -1
  284. package/lib/typescript/atoms/flash-list/flash-list.d.ts +0 -8
  285. package/lib/typescript/atoms/flash-list/flash-list.types.d.ts +0 -18
  286. package/lib/typescript/atoms/flash-list/index.d.ts +0 -2
  287. package/src/atoms/activity-indicator/activity-indicator.tsx +0 -9
  288. package/src/atoms/flash-list/flash-list.tsx +0 -28
  289. package/src/atoms/flash-list/flash-list.types.ts +0 -20
  290. package/src/atoms/flash-list/index.ts +0 -2
  291. package/src/atoms/segmented-control/segmented-control.tsx +0 -47
@@ -1,9 +1,18 @@
1
+ import type { ResponsiveViewSx } from '@hzblj/kara-sx';
1
2
  import type { ColorToken, TextVariant } from '@hzblj/kara-theme';
2
3
  import type { ReactNode } from 'react';
3
4
  import type { TextProps as RNTextProps } from 'react-native';
4
- export type RnTextProps = Omit<RNTextProps, 'style'> & {
5
+ /**
6
+ * React Native's `Text` in a theme typography variant — the React Native tier, for text outside a native host. It takes
7
+ * `Box`'s `sx` surface for its own box — margins, flex, padding, a background — all but `align`, which here aligns the
8
+ * lines.
9
+ */
10
+ export type RnTextProps = Omit<RNTextProps, 'style'> & Omit<ResponsiveViewSx, 'align'> & {
11
+ /** Horizontal alignment, as React Native's `textAlign`. */
5
12
  align?: 'center' | 'left' | 'right';
13
+ /** The text's colour. `content.primary` by default. */
6
14
  color?: ColorToken;
15
+ /** The typography variant. `body` by default. */
7
16
  variant?: TextVariant;
8
17
  };
9
18
  export type RnTextComponent = (props: RnTextProps) => ReactNode;
@@ -1,4 +1,5 @@
1
1
  import type { ReactElement, ReactNode } from 'react';
2
+ /** Carries a React Native view into a SwiftUI or Compose tree — `@expo/ui`'s `RNHostView` on both platforms. */
2
3
  export type RnViewProps = {
3
4
  /**
4
5
  * A single React Native *view*. It may not contain React Native text: a bare string becomes a
@@ -14,6 +15,7 @@ export type RnViewProps = {
14
15
  * intrinsic size and would otherwise stretch to fill the SwiftUI parent.
15
16
  */
16
17
  matchContents?: boolean;
18
+ /** Not forwarded on either platform — give the child its own `testID`. */
17
19
  testID?: string;
18
20
  };
19
21
  export type RnViewComponent = (props: RnViewProps) => ReactNode;
@@ -7,7 +7,9 @@ export type ScrollViewAxis = 'horizontal' | 'vertical';
7
7
  * like React Native's `contentContainerStyle` padding and scrolls with the content.
8
8
  */
9
9
  export type ScrollViewProps = ResponsiveSx & {
10
+ /** The scroll direction. `vertical` by default. */
10
11
  axis?: ScrollViewAxis;
12
+ /** Laid out in a stack along `axis`. */
11
13
  children?: ReactNode;
12
14
  /**
13
15
  * Enables pull-to-refresh. Async on purpose: the spinner runs until the promise settles, which is
@@ -19,7 +21,9 @@ export type ScrollViewProps = ResponsiveSx & {
19
21
  onRefresh?: () => Promise<void>;
20
22
  /** iOS only — Compose exposes no indicator toggle, so Android always shows the native one. */
21
23
  showsIndicators?: boolean;
24
+ /** The space between children. */
22
25
  spacing?: SpaceSize;
26
+ /** Test identifier, forwarded to the native view. */
23
27
  testID?: string;
24
28
  };
25
29
  export type ScrollViewComponent = (props: ScrollViewProps) => ReactNode;
@@ -1,6 +1 @@
1
- import type { SegmentedControlComponent } from './segmented-control.types';
2
- /**
3
- * `UISegmentedControl` on iOS, Material's single-choice segmented buttons on Android. A new segment plays `selection`
4
- * on Android, whose buttons play nothing of their own; iOS 26's control already gives its own feedback.
5
- */
6
- export declare const SegmentedControl: SegmentedControlComponent;
1
+ export * from './segmented-control.ios';
@@ -0,0 +1,7 @@
1
+ import type { SegmentedControlComponent } from './segmented-control.types';
2
+ /**
3
+ * kara's own `UISegmentedControl`, with the pill in the accent and white text on it — the system control tints only the
4
+ * pill, and SwiftUI's segmented picker not even that. A plain `UIView` in React Native layout: it needs no host, takes
5
+ * the width it is given and UIKit's height. UIKit plays the control's own feedback.
6
+ */
7
+ export declare const SegmentedControl: SegmentedControlComponent;
@@ -1,9 +1,22 @@
1
1
  import type { ReactNode } from 'react';
2
+ /**
3
+ * A row of mutually exclusive segments, the selected one in the accent — kara's own `UISegmentedControl` on iOS,
4
+ * Material's single-choice segmented buttons on Android. It needs no `Screen` or `Island`: iOS is a plain view, Android
5
+ * brings its own host. It takes the width it is given; the height is the platform's.
6
+ */
2
7
  export type SegmentedControlProps = {
8
+ /** Stops the user changing the segment, and dims the control. */
3
9
  disabled?: boolean;
10
+ /**
11
+ * Called with the index and label of the segment the user picked — never for a tap on the one already selected.
12
+ * Android plays `selection`; iOS's control plays its own feedback.
13
+ */
4
14
  onChange?: (index: number, value: string) => void;
15
+ /** The selected segment. Controlled: pass back what `onChange` reports. */
5
16
  selectedIndex: number;
17
+ /** Test identifier, on the whole control — reach a segment by its label. */
6
18
  testID?: string;
19
+ /** The segments' labels, in order. */
7
20
  values: string[];
8
21
  };
9
22
  export type SegmentedControlComponent = (props: SegmentedControlProps) => ReactNode;
@@ -1,9 +1,18 @@
1
+ import type { SxDimension } from '@hzblj/kara-sx';
1
2
  import type { RadiiSize } from '@hzblj/kara-theme';
2
3
  import type { ReactNode } from 'react';
4
+ /**
5
+ * A loading placeholder that pulses in `fill.quaternary` — a React Native view, so it needs no host. Sized with the
6
+ * `sx` names: `w`, `h`, `borderRadius`.
7
+ */
3
8
  export type SkeletonProps = {
9
+ /** The corner radius. `small` by default. */
4
10
  borderRadius?: RadiiSize;
5
- height: number;
11
+ /** In points. */
12
+ h: number;
13
+ /** Test identifier, forwarded to the view. */
6
14
  testID?: string;
7
- width?: number;
15
+ /** In points, or a percentage of the row (`60%` for a line that ends early). Unset, it fills the row. */
16
+ w?: SxDimension;
8
17
  };
9
18
  export type SkeletonComponent = (props: SkeletonProps) => ReactNode;
@@ -1,10 +1,17 @@
1
1
  import type { ReactNode } from 'react';
2
+ /** SwiftUI `Slider` / Compose's Material `Slider`, tinted `fill.accent.primary`. */
2
3
  export type SliderProps = {
4
+ /** Stops the user moving the thumb, and dims the slider. */
3
5
  disabled?: boolean;
6
+ /** The upper end. `1` by default. */
4
7
  max?: number;
8
+ /** The lower end. `0` by default. */
5
9
  min?: number;
10
+ /** Called with the new value as the thumb moves. */
6
11
  onValueChange?: (value: number) => void;
12
+ /** The increment between stops; leave it unset for a continuous slider. On Android every stop plays a `tick`. */
7
13
  step?: number;
14
+ /** Between `min` and `max`. Controlled: pass back what `onValueChange` reports. */
8
15
  value: number;
9
16
  };
10
17
  export type SliderComponent = (props: SliderProps) => ReactNode;
@@ -1,7 +1,10 @@
1
1
  import type { SpaceSize } from '@hzblj/kara-theme';
2
2
  import type { ReactNode } from 'react';
3
+ /** Takes up the free space in a stack — SwiftUI `Spacer` / Compose `Spacer` with `weight(1)`. */
3
4
  export type SpacerProps = {
5
+ /** The least room it takes. iOS holds it along the stack's axis; Android as a minimum height only. */
4
6
  min?: SpaceSize;
7
+ /** iOS: forwarded to the native view. Android ignores it. */
5
8
  testID?: string;
6
9
  };
7
10
  export type SpacerComponent = (props: SpacerProps) => ReactNode;
@@ -1,8 +1,15 @@
1
1
  import type { ResponsiveSx } from '@hzblj/kara-sx';
2
2
  import type { ReactNode } from 'react';
3
+ /**
4
+ * A container padded `s16` and rounded `large` unless told otherwise — a SwiftUI `VStack` on iOS, Material's
5
+ * `Surface` around a `Column` on Android.
6
+ */
3
7
  export type SurfaceProps = ResponsiveSx & {
8
+ /** Stacked vertically, from the leading edge. */
4
9
  children?: ReactNode;
10
+ /** iOS wraps the content in a `GlassEffectContainer`; Android raises it to a tonal elevation of `3`. */
5
11
  glass?: boolean;
12
+ /** Test identifier, forwarded to the native view. */
6
13
  testID?: string;
7
14
  };
8
15
  export type SurfaceComponent = (props: SurfaceProps) => ReactNode;
@@ -1,8 +1,16 @@
1
1
  import type { ReactNode } from 'react';
2
+ /** SwiftUI `Toggle` / Compose `Switch`, tinted `fill.accent.primary`. */
2
3
  export type SwitchProps = {
4
+ /** Stops the user flipping it, and dims it. */
3
5
  disabled?: boolean;
6
+ /**
7
+ * Shown beside the switch. On Android it makes a full-width row — label at the start, switch at the end — that
8
+ * toggles wherever it is tapped.
9
+ */
4
10
  label?: string;
11
+ /** Called with the new value when the user flips it. On Android a flip plays `toggleOn` / `toggleOff`. */
5
12
  onValueChange?: (value: boolean) => void;
13
+ /** Whether it is on. Controlled: pass back what `onValueChange` reports. */
6
14
  value: boolean;
7
15
  };
8
16
  export type SwitchComponent = (props: SwitchProps) => ReactNode;
@@ -1,16 +1,33 @@
1
+ import type { ResponsiveSx } from '@hzblj/kara-sx';
1
2
  import type { ColorToken, TextVariant } from '@hzblj/kara-theme';
2
3
  import type { ReactNode } from 'react';
3
4
  export type TextAlign = 'center' | 'left' | 'right';
4
5
  export type TextDecoration = 'none' | 'strikethrough' | 'underline';
5
6
  export type TextTransform = 'lowercase' | 'uppercase';
6
- export type TextProps = {
7
+ /**
8
+ * SwiftUI `Text` / Compose `Text` in a theme typography variant — a native atom; outside a host, use `RnText`. It takes
9
+ * the native `sx` surface too: padding, a frame (`wide` lines it up by `align`), a background, and the `ios` bucket's
10
+ * `contentTransition`, `animation` and `monospacedDigit` for a number that changes in place.
11
+ */
12
+ export type TextProps = ResponsiveSx & {
13
+ /**
14
+ * How its lines align. iOS reads `left` and `right` as leading and trailing, so they flip in a right-to-left
15
+ * layout; Android keeps them as they are.
16
+ */
7
17
  align?: TextAlign;
18
+ /** The text. */
8
19
  children?: ReactNode;
20
+ /** The text's colour. `content.primary` by default. */
9
21
  color?: ColorToken;
22
+ /** An underline or a strikethrough. */
10
23
  decoration?: TextDecoration;
24
+ /** The most lines it wraps to. iOS truncates the last with an ellipsis; Android clips it. */
11
25
  numberOfLines?: number;
26
+ /** Test identifier, forwarded to the native view. */
12
27
  testID?: string;
28
+ /** Upper- or lower-cases the text. Android applies it only when `children` is a plain string. */
13
29
  transform?: TextTransform;
30
+ /** The typography variant. `body` by default. */
14
31
  variant?: TextVariant;
15
32
  };
16
33
  export type TextComponent = (props: TextProps) => ReactNode;
@@ -1,12 +1,24 @@
1
1
  import type { ReactNode } from 'react';
2
+ /**
3
+ * An uncontrolled text field with an optional label above it — SwiftUI `TextField` (`SecureField` when `secure`) /
4
+ * Compose `OutlinedTextField`.
5
+ */
2
6
  export type TextFieldProps = {
7
+ /** The text it starts with. Read once, on mount — the field is uncontrolled. */
3
8
  defaultValue?: string;
9
+ /** Stops editing and dims the field. On iOS it outranks `error`. */
4
10
  disabled?: boolean;
11
+ /** Marks the field invalid: a destructive outline and label. */
5
12
  error?: boolean;
13
+ /** Shown above the field, in `labelMedium`. */
6
14
  label?: string;
15
+ /** Wraps the text and grows the field to fit it. iOS ignores it when `secure`. */
7
16
  multiline?: boolean;
17
+ /** Called with the whole text after every change. */
8
18
  onChangeText?: (text: string) => void;
19
+ /** Masks the text, for a password. */
9
20
  secure?: boolean;
21
+ /** iOS: forwarded to the native field. Android ignores it. */
10
22
  testID?: string;
11
23
  };
12
24
  export type TextFieldComponent = (props: TextFieldProps) => ReactNode;
@@ -2,11 +2,20 @@ import type { ResponsiveSx } from '@hzblj/kara-sx';
2
2
  import type { SpaceSize } from '@hzblj/kara-theme';
3
3
  import type { ReactNode } from 'react';
4
4
  export type VStackAlign = 'center' | 'end' | 'start';
5
+ /** Stacks its children top to bottom — SwiftUI `VStack` / Compose `Column`. */
5
6
  export type VStackProps = ResponsiveSx & {
7
+ /** The children's horizontal alignment. `start` by default. */
6
8
  align?: VStackAlign;
9
+ /** Laid out top to bottom, `spacing` apart. */
7
10
  children?: ReactNode;
11
+ /**
12
+ * Makes the whole stack pressable. iOS adds a tap gesture with no press feedback; Android a `clickable` whose ripple
13
+ * fills the stack's shape.
14
+ */
8
15
  onPress?: () => void;
16
+ /** The space between children. */
9
17
  spacing?: SpaceSize;
18
+ /** Test identifier, forwarded to the native view. */
10
19
  testID?: string;
11
20
  };
12
21
  export type VStackComponent = (props: VStackProps) => ReactNode;
@@ -1,10 +1,18 @@
1
1
  import type { ResponsiveSx } from '@hzblj/kara-sx';
2
2
  import type { ReactNode } from 'react';
3
3
  export type ZStackAlign = 'bottom' | 'center' | 'top';
4
+ /** Layers its children on one another — SwiftUI `ZStack` / Compose `Box`. */
4
5
  export type ZStackProps = ResponsiveSx & {
6
+ /** Where the children sit vertically; they are always centred horizontally. `center` by default. */
5
7
  align?: ZStackAlign;
8
+ /** Drawn in order, the last on top. */
6
9
  children?: ReactNode;
10
+ /**
11
+ * Makes the whole stack pressable. iOS adds a tap gesture with no press feedback; Android a `clickable` whose ripple
12
+ * fills the stack's shape.
13
+ */
7
14
  onPress?: () => void;
15
+ /** Test identifier, forwarded to the native view. */
8
16
  testID?: string;
9
17
  };
10
18
  export type ZStackComponent = (props: ZStackProps) => ReactNode;
@@ -1,8 +1,16 @@
1
1
  import type { ReactNode } from 'react';
2
+ /**
3
+ * A row that shows and hides its content: SwiftUI's `DisclosureGroup` on iOS; on Android a pressable row with a
4
+ * chevron over an animated reveal. A native atom — it renders inside `<Screen>` or `<Island>`.
5
+ */
2
6
  export type CollapsibleProps = {
7
+ /** Shown while `expanded`. */
3
8
  children: ReactNode;
9
+ /** Whether the content is shown. Update it from `onExpandedChange`. */
4
10
  expanded: boolean;
11
+ /** The row's text. */
5
12
  label: string;
13
+ /** The user pressed the row; it passes the state the row asks for. */
6
14
  onExpandedChange: (expanded: boolean) => void;
7
15
  };
8
16
  export type CollapsibleComponent = (props: CollapsibleProps) => ReactNode;
@@ -5,10 +5,15 @@ import type { IconName } from '../../atoms/icon';
5
5
  * `action` takes a `Button` so the state can offer a way out.
6
6
  */
7
7
  export type EmptyStateProps = {
8
+ /** Under the text — a `Button`, say. */
8
9
  action?: ReactNode;
10
+ /** A second line under the title, in the secondary colour. */
9
11
  description?: string;
12
+ /** One of the app's icons, large and muted above the title. */
10
13
  icon?: IconName;
14
+ /** Test identifier, forwarded to the native view. */
11
15
  testID?: string;
16
+ /** The headline. */
12
17
  title: string;
13
18
  };
14
19
  export type EmptyStateComponent = (props: EmptyStateProps) => ReactNode;
@@ -6,11 +6,17 @@ import type { IconName } from '../../atoms/icon';
6
6
  * header. For a full tappable row with a subtitle and chevron, use `ListItem`.
7
7
  */
8
8
  export type LabelProps = {
9
+ /** Colours the icon and the title alike. `content.primary` by default. */
9
10
  color?: ColorToken;
11
+ /** One of the app's icons, before the title. */
10
12
  icon: IconName;
13
+ /** The icon's size. `s20` by default. */
11
14
  iconSize?: SpaceSize;
15
+ /** Test identifier, forwarded to the native view. */
12
16
  testID?: string;
17
+ /** The text beside the icon. */
13
18
  title: string;
19
+ /** The title's text style. `body` by default. */
14
20
  variant?: TextVariant;
15
21
  };
16
22
  export type LabelComponent = (props: LabelProps) => ReactNode;
@@ -6,13 +6,19 @@ import type { IconName } from '../../atoms/icon';
6
6
  * Pass `children` instead of `value` when the trailing side is a control rather than text.
7
7
  */
8
8
  export type LabeledContentProps = {
9
+ /** The trailing side when it is a control, in place of `value`. */
9
10
  children?: ReactNode;
11
+ /** One of the app's icons, before the label, in the secondary colour. */
10
12
  icon?: IconName;
13
+ /** The leading text. */
11
14
  label: string;
15
+ /** Makes the row pressable and adds a chevron on the trailing edge. */
12
16
  onPress?: () => void;
13
17
  /** Horizontal padding inside the row — inside its press area too, so Android's ripple reaches the card's edges. */
14
18
  px?: SpaceSize;
19
+ /** Test identifier, forwarded to the native view. */
15
20
  testID?: string;
21
+ /** The trailing text, in the secondary colour. Ignored when `children` is given. */
16
22
  value?: string;
17
23
  };
18
24
  export type LabeledContentComponent = (props: LabeledContentProps) => ReactNode;
@@ -3,11 +3,17 @@ import type { ReactNode } from 'react';
3
3
  import type { IconName } from '../../atoms/icon';
4
4
  /** Opens an external URL in the platform browser or the app that claims the scheme. */
5
5
  export type LinkProps = {
6
+ /** Colours the label and the icon. `content.accent` by default. */
6
7
  color?: ColorToken;
8
+ /** One of the app's icons, before the label. */
7
9
  icon?: IconName;
10
+ /** The link's text. */
8
11
  label: string;
12
+ /** Test identifier, forwarded to the native view. */
9
13
  testID?: string;
14
+ /** Opened through React Native's `Linking` on press. A URL nothing can open fails silently. */
10
15
  url: string;
16
+ /** The label's text style. `body` by default. */
11
17
  variant?: TextVariant;
12
18
  };
13
19
  export type LinkComponent = (props: LinkProps) => ReactNode;
@@ -1,16 +1,25 @@
1
1
  import type { SpaceSize } from '@hzblj/kara-theme';
2
2
  import type { ReactNode } from 'react';
3
3
  import type { IconName } from '../../atoms/icon';
4
+ /**
5
+ * A row with an optional icon, a title and subtitle, and a chevron when it can be pressed. A native atom — it renders
6
+ * inside `<Screen>` or `<Island>`; `RnListItem` is the same row without a host.
7
+ */
4
8
  export type ListItemProps = {
9
+ /** One of the app's icons, before the title, in the secondary colour. */
5
10
  icon?: IconName;
11
+ /** Makes the row pressable and adds a chevron on the trailing edge. */
6
12
  onPress?: () => void;
7
13
  /**
8
14
  * Horizontal padding inside the row — inside its press area too, so Android's ripple reaches the card's edges. For
9
15
  * rows in a card of your own; a `List` insets its rows by itself.
10
16
  */
11
17
  px?: SpaceSize;
18
+ /** A second line under the title, smaller and in the secondary colour. */
12
19
  subtitle?: string;
20
+ /** Test identifier, forwarded to the row's view. */
13
21
  testID?: string;
22
+ /** The row's main text. */
14
23
  title: string;
15
24
  };
16
25
  export type ListItemComponent = (props: ListItemProps) => ReactNode;
@@ -1,6 +1,7 @@
1
1
  import type { ReactNode, Ref } from 'react';
2
2
  import type { IconName } from '../../atoms/icon';
3
3
  type NavigationBarItemBase = {
4
+ /** Called when the item is pressed. */
4
5
  onPress: () => void;
5
6
  /**
6
7
  * iOS 26: neighbouring items on one side share a glass capsule; this gives the item its own. A close next to
@@ -29,10 +30,15 @@ export type NavigationBarSearchRef = {
29
30
  };
30
31
  /** A search field in place of the title — iOS only for now; Android keeps the title. */
31
32
  export type NavigationBarSearch = {
33
+ /** Every edit of the field's text. */
32
34
  onChangeText: (text: string) => void;
35
+ /** The field gained or lost focus. */
33
36
  onFocusChange?: (focused: boolean) => void;
37
+ /** Shown while the field is empty. */
34
38
  placeholder: string;
39
+ /** Imperative `clear`. */
35
40
  ref?: Ref<NavigationBarSearchRef>;
41
+ /** Test identifier, forwarded to the native search field. */
36
42
  testID?: string;
37
43
  };
38
44
  export type NavigationBarTitleAlignment = 'center' | 'leading';
@@ -50,7 +56,9 @@ export type NavigationBarProps = {
50
56
  leadingItems?: NavigationBarItem[];
51
57
  /** Replaces the title with a search field (iOS). */
52
58
  search?: NavigationBarSearch;
59
+ /** Test identifier, forwarded to the native bar. iOS only — Android ignores it. */
53
60
  testID?: string;
61
+ /** The bar's title. */
54
62
  title?: string;
55
63
  /** `center` by default — iOS's own; `leading` is Material's top app bar. */
56
64
  titleAlignment?: NavigationBarTitleAlignment;
@@ -10,6 +10,7 @@ import type { ReactNode } from 'react';
10
10
  * ceremony would buy nothing.
11
11
  */
12
12
  export type PagerProps = {
13
+ /** The pages, one per child, in order. */
13
14
  children?: ReactNode;
14
15
  /**
15
16
  * Page dots. iOS draws SwiftUI's own, over the bottom edge; Compose has no built-in indicator, so
@@ -27,6 +28,7 @@ export type PagerProps = {
27
28
  * content down with the swipe, so iOS always stays swipeable.
28
29
  */
29
30
  scrollEnabled?: boolean;
31
+ /** Test identifier, forwarded to the native view. */
30
32
  testID?: string;
31
33
  };
32
34
  export type PagerComponent = (props: PagerProps) => ReactNode;
@@ -1,11 +1,21 @@
1
1
  import type { ReactNode } from 'react';
2
+ /** One choice of a `RadioGroup`. */
2
3
  export type RadioOption = {
4
+ /** The option's text. */
3
5
  label: string;
6
+ /** Identifies the option to `value` and `onValueChange`, and keys its row — keep it unique. */
4
7
  value: string;
5
8
  };
9
+ /**
10
+ * A single choice from a list: rows with a checkmark on the selected one on iOS, Material radio buttons on Android. A
11
+ * native atom — it renders inside `<Screen>` or `<Island>`.
12
+ */
6
13
  export type RadioGroupProps = {
14
+ /** The user pressed an option; it passes that option's `value`. */
7
15
  onValueChange?: (value: string) => void;
16
+ /** The choices, top to bottom. */
8
17
  options: RadioOption[];
18
+ /** The selected option's `value`. Update it from `onValueChange`. */
9
19
  value: string;
10
20
  };
11
21
  export type RadioGroupComponent = (props: RadioGroupProps) => ReactNode;
@@ -2,7 +2,7 @@ import type { ReactNode } from 'react';
2
2
  import type { ListItemProps } from '../list-item';
3
3
  /**
4
4
  * `ListItem`'s row in the React Native tier — plain views, no host. For lists long enough that a native host per row
5
- * would cost too much to mount (a navigation list, a FlashList of rows), with the platform's own press feedback: a
5
+ * would cost too much to mount (a navigation list, an `RnFlatList` of rows), with the platform's own press feedback: a
6
6
  * ripple across the whole row on Android, a highlight on iOS. In a rounded card, give the card `overflow="hidden"`:
7
7
  * Android draws the ripple as the row's foreground, which only a parent's clip keeps inside rounded corners.
8
8
  */
@@ -1,7 +1,10 @@
1
1
  import type { ReactElement, ReactNode } from 'react';
2
2
  export type RnTooltipActionVariant = 'link' | 'primary' | 'secondary';
3
+ /** A button in an `RnTooltip`. */
3
4
  export type RnTooltipAction = {
5
+ /** The button's text. */
4
6
  label: string;
7
+ /** Called on press. The tooltip stays up — turn `visible` off here if the action should close it. */
5
8
  onPress: () => void;
6
9
  /** `link` by default — an underlined text. `primary`/`secondary` are small filled/outlined buttons. */
7
10
  variant?: RnTooltipActionVariant;
@@ -14,6 +17,7 @@ export type RnTooltipDismissReason = 'anchorHidden' | 'outside';
14
17
  * Native tier, unlike `Tooltip`, whose anchor is a native view inside a host.
15
18
  */
16
19
  export type RnTooltipProps = {
20
+ /** A row of buttons under the text, in order. */
17
21
  actions?: RnTooltipAction[];
18
22
  /** Which end of the bubble the actions sit at. `end` by default. */
19
23
  actionsAlignment?: 'end' | 'start';
@@ -27,11 +31,18 @@ export type RnTooltipProps = {
27
31
  };
28
32
  /** The anchor — a single React Native view. */
29
33
  children: ReactElement;
34
+ /** The body text, under the title. */
30
35
  message?: string;
36
+ /**
37
+ * Asks for the tooltip to close, with the reason — turn `visible` off. On Android any touch outside asks, the start
38
+ * of a scroll included; iOS keeps the tooltip through a scroll.
39
+ */
31
40
  onDismiss: (reason: RnTooltipDismissReason) => void;
32
41
  /** The appear animation finished. */
33
42
  onShown?: () => void;
43
+ /** The heading line, above the message. */
34
44
  title?: string;
45
+ /** Shows the tooltip while true. It never hides itself. */
35
46
  visible: boolean;
36
47
  };
37
48
  export type RnTooltipComponent = (props: RnTooltipProps) => ReactNode;
@@ -3,8 +3,10 @@ import type { ResponsiveViewSx } from '@hzblj/kara-sx';
3
3
  import type { ReactElement, ReactNode } from 'react';
4
4
  export type { ScrollEdgeEffect, ScrollEdgeScrollableProps } from '@hzblj/kara-native/swift-ui';
5
5
  /**
6
- * Bars over one React Native scroll view, with the iOS 26 scroll edge effect under them — the system's progressive
7
- * blur where content scrolls past a bar. The React Native tier: it needs no host.
6
+ * Bars over one React Native scroll view, with each platform's scroll edge under them — on iOS 26 the system's
7
+ * progressive blur where content scrolls past a bar; on Android a Material top app bar's behaviour, the bars stacked
8
+ * around the scroll view and filling with `surface.secondary` once content scrolls under them. The React Native tier:
9
+ * it needs no host.
8
10
  *
9
11
  * A screen-level container: wrap the screen's scroll view with it. Mounted inside a cell of a virtualized list on iOS
10
12
  * it draws only its bottom bar — the hosted scroll view and the top bar stay blank.
@@ -15,12 +17,15 @@ export type ScrollEdgeContainerProps = ResponsiveViewSx & {
15
17
  * content begins below the top bar and scrolls under it. On by default.
16
18
  */
17
19
  automaticInsets?: boolean;
20
+ /** Laid over the scroll view's bottom edge on iOS; stacked below it on Android, filled while content continues below. */
18
21
  bottomBar?: ReactNode;
19
22
  /** Exactly one React Native scroll view — `RnScrollView`, `RnFlatList`, `RnSectionList`. */
20
23
  children: ReactElement<ScrollEdgeScrollableProps>;
21
24
  /** iOS 26: how hard the edge cuts. `soft` by default. */
22
25
  effect?: ScrollEdgeEffect;
26
+ /** Test identifier, forwarded to the container view. */
23
27
  testID?: string;
28
+ /** Laid over the scroll view's top edge on iOS; stacked above it on Android, filled once content scrolls under it. */
24
29
  topBar?: ReactNode;
25
30
  };
26
31
  export type ScrollEdgeContainerComponent = (props: ScrollEdgeContainerProps) => ReactNode;
@@ -1,8 +1,16 @@
1
1
  import type { ReactNode } from 'react';
2
+ /**
3
+ * A search field drawn the same on both platforms — a rounded box with a magnifier, a `TextInput` and a clear button
4
+ * while there is text. The React Native tier: it needs no host.
5
+ */
2
6
  export type SearchBarProps = {
7
+ /** Every edit, and `''` when the clear button is pressed. */
3
8
  onChangeText?: (text: string) => void;
9
+ /** Shown while the field is empty. `Search` by default. */
4
10
  placeholder?: string;
11
+ /** Test identifier, put on the field's container view rather than on the `TextInput`. */
5
12
  testID?: string;
13
+ /** The field's text. Controlled — pass back what `onChangeText` reports. */
6
14
  value: string;
7
15
  };
8
16
  export type SearchBarComponent = (props: SearchBarProps) => ReactNode;
@@ -1,2 +1,7 @@
1
1
  import type { StepperComponent } from './stepper.types';
2
+ /**
3
+ * SwiftUI's `Stepper` at the end of a row, the label leading and the value just before the control — the way iOS's own
4
+ * settings show a stepped value. The value rolls to the next one (`numericText`), up or down with the change, in
5
+ * monospaced digits so the row does not jump.
6
+ */
2
7
  export declare const Stepper: StepperComponent;
@@ -1,10 +1,20 @@
1
1
  import type { ReactNode } from 'react';
2
+ /**
3
+ * A number with minus and plus buttons beside a label: SwiftUI's `Stepper` on iOS; on Android the label, the value and
4
+ * two icon buttons in a row. A native atom — it renders inside `<Screen>` or `<Island>`.
5
+ */
2
6
  export type StepperProps = {
7
+ /** The leading text. The value is shown too — before the control on iOS, between the buttons on Android. */
3
8
  label: string;
9
+ /** The highest value. When unset, Android has no upper limit and iOS stops at `100`. */
4
10
  max?: number;
11
+ /** The lowest value. When unset, Android has no lower limit and iOS stops at `0`. */
5
12
  min?: number;
13
+ /** A button was pressed; it passes the new value, kept within `min` and `max`. */
6
14
  onValueChange: (value: number) => void;
15
+ /** How much one press adds or takes away. `1` by default. */
7
16
  step?: number;
17
+ /** The current value. Update it from `onValueChange`. iOS's native stepper counts in whole numbers. */
8
18
  value: number;
9
19
  };
10
20
  export type StepperComponent = (props: StepperProps) => ReactNode;
@@ -1,8 +1,20 @@
1
1
  import type { ReactNode } from 'react';
2
+ /**
3
+ * A short text tip on a native view, shown while `visible` — a SwiftUI popover from `children` on iOS, Material's plain
4
+ * tooltip centred above them on Android. A native atom — it renders inside `<Screen>` or `<Island>`; `RnTooltip`
5
+ * anchors to a React Native view.
6
+ */
2
7
  export type TooltipProps = {
8
+ /** The anchor — a native view. */
3
9
  children: ReactNode;
10
+ /** The tip. */
4
11
  text: string;
12
+ /** Shows the tip while true. Controlled: nothing opens it but this — wire a long press to it if you want one. */
5
13
  visible: boolean;
14
+ /**
15
+ * The user dismissed the tip — turn `visible` off. iOS: a tap outside the popover. Android: any touch outside it, the
16
+ * start of a scroll included, or the anchor scrolling out of the window.
17
+ */
6
18
  onDismiss: () => void;
7
19
  };
8
20
  export type TooltipComponent = (props: TooltipProps) => ReactNode;