@draftbit/core 49.5.2-ff55cf.2 → 49.5.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (552) hide show
  1. package/lib/commonjs/Provider.js +1 -1
  2. package/lib/commonjs/components/AccordionGroup.js +1 -1
  3. package/lib/commonjs/components/BottomSheet/BottomSheet.js +1 -1
  4. package/lib/commonjs/components/Button.js +1 -1
  5. package/lib/commonjs/components/Checkbox/Checkbox.js +1 -1
  6. package/lib/commonjs/components/Checkbox/CheckboxRow.js +1 -1
  7. package/lib/commonjs/components/DatePicker/DatePicker.js +1 -1
  8. package/lib/commonjs/components/DatePicker/DatePickerComponent.web.js +1 -1
  9. package/lib/commonjs/components/DeckSwiper/DeckSwiperCard.js +1 -1
  10. package/lib/commonjs/components/Divider.js +1 -1
  11. package/lib/commonjs/components/Elevation.js +1 -1
  12. package/lib/commonjs/components/IconButton.js +1 -1
  13. package/lib/commonjs/components/MediaPlayer/AudioPlayer/AudioPlayerWithInterface.js +1 -1
  14. package/lib/commonjs/components/MediaPlayer/AudioPlayer/index.js +1 -1
  15. package/lib/commonjs/components/Picker/NativePicker.js +1 -1
  16. package/lib/commonjs/components/Picker/dropdown/DropDownModalPicker.js +1 -1
  17. package/lib/commonjs/components/Picker/dropdown/DropDownPicker.js +1 -1
  18. package/lib/commonjs/components/Picker/dropdown/MultiSelectPicker.js +1 -1
  19. package/lib/commonjs/components/Picker/index.js +1 -1
  20. package/lib/commonjs/components/PinInput/PinInput.js +1 -1
  21. package/lib/commonjs/components/PinInput/PinInputText.js +1 -1
  22. package/lib/commonjs/components/Portal/Portal.js +1 -1
  23. package/lib/commonjs/components/Progress/CircularProgress/CircularProgress.js +1 -1
  24. package/lib/commonjs/components/Progress/CircularProgress/index.js +1 -1
  25. package/lib/commonjs/components/Progress/LinearProgress/LinearProgress.js +1 -1
  26. package/lib/commonjs/components/Progress/LinearProgress/index.js +1 -1
  27. package/lib/commonjs/components/ProgressIndicator.js +1 -1
  28. package/lib/commonjs/components/RadioButton/RadioButtonRow.js +1 -1
  29. package/lib/commonjs/components/Row.js +1 -1
  30. package/lib/commonjs/components/ScreenContainer.js +1 -1
  31. package/lib/commonjs/components/SectionList/SectionHeader.js +1 -1
  32. package/lib/commonjs/components/SectionList/SectionList.js +1 -1
  33. package/lib/commonjs/components/SimpleStyleScrollables/SimpleStyleFlashList.js +1 -1
  34. package/lib/commonjs/components/SimpleStyleScrollables/SimpleStyleFlatList.js +1 -1
  35. package/lib/commonjs/components/SimpleStyleScrollables/SimpleStyleKeyboardAwareScrollView.js +1 -1
  36. package/lib/commonjs/components/SimpleStyleScrollables/SimpleStyleMasonryFlashList.js +1 -1
  37. package/lib/commonjs/components/SimpleStyleScrollables/SimpleStyleScrollView.js +1 -1
  38. package/lib/commonjs/components/SimpleStyleScrollables/SimpleStyleSectionList.js +1 -1
  39. package/lib/commonjs/components/SimpleStyleScrollables/SimpleStyleSwipeableList.js +1 -1
  40. package/lib/commonjs/components/Slider.js +1 -1
  41. package/lib/commonjs/components/StarRating.js +1 -1
  42. package/lib/commonjs/components/Stepper.js +1 -1
  43. package/lib/commonjs/components/Surface.js +1 -1
  44. package/lib/commonjs/components/SwipeableItem/SwipeableItem.js +1 -1
  45. package/lib/commonjs/components/SwipeableItem/SwipeableList.js +1 -1
  46. package/lib/commonjs/components/Swiper/Swiper.js +1 -1
  47. package/lib/commonjs/components/Switch.js +1 -1
  48. package/lib/commonjs/components/TabView/TabView.js +1 -1
  49. package/lib/commonjs/components/Table/Table.js +1 -1
  50. package/lib/commonjs/components/Table/TableRow.js +1 -1
  51. package/lib/commonjs/components/Text.js +1 -1
  52. package/lib/commonjs/components/TextField.js +1 -1
  53. package/lib/commonjs/components/TextInput.js +1 -1
  54. package/lib/commonjs/components/Typography.js +1 -1
  55. package/lib/commonjs/deprecated-components/AccordionItem.js +1 -1
  56. package/lib/commonjs/deprecated-components/AvatarEdit.js +1 -1
  57. package/lib/commonjs/deprecated-components/Banner.js +1 -1
  58. package/lib/commonjs/deprecated-components/Card.js +1 -1
  59. package/lib/commonjs/deprecated-components/Container.js +1 -1
  60. package/lib/commonjs/deprecated-components/DeprecatedButton.js +1 -1
  61. package/lib/commonjs/deprecated-components/DeprecatedCardWrapper.js +1 -1
  62. package/lib/commonjs/deprecated-components/DeprecatedFAB.js +1 -1
  63. package/lib/commonjs/deprecated-components/FAB.js +1 -1
  64. package/lib/commonjs/deprecated-components/FieldSearchBarFull.js +1 -1
  65. package/lib/commonjs/deprecated-components/ProgressCircle.js +1 -1
  66. package/lib/commonjs/deprecated-components/RadioButtonFieldGroup.js +1 -1
  67. package/lib/commonjs/deprecated-components/RowBodyIcon.js +1 -1
  68. package/lib/commonjs/deprecated-components/RowHeadlineImageCaption.js +1 -1
  69. package/lib/commonjs/deprecated-components/RowHeadlineImageIcon.js +1 -1
  70. package/lib/commonjs/deprecated-components/ToggleButton.js +1 -1
  71. package/lib/commonjs/index.js +1 -1
  72. package/lib/commonjs/styles/DarkTheme.js +1 -0
  73. package/lib/commonjs/styles/DefaultTheme.js +1 -0
  74. package/lib/commonjs/styles/fonts.js +1 -0
  75. package/lib/commonjs/styles/overlay.js +1 -0
  76. package/lib/commonjs/styles/shadow.js +1 -0
  77. package/lib/commonjs/theming.js +1 -0
  78. package/lib/typescript/src/Provider.d.ts +5 -7
  79. package/lib/typescript/src/Provider.js +4 -4
  80. package/lib/typescript/src/Provider.js.map +1 -1
  81. package/lib/typescript/src/components/AccordionGroup.d.ts +5 -3
  82. package/lib/typescript/src/components/AccordionGroup.js +3 -3
  83. package/lib/typescript/src/components/AccordionGroup.js.map +1 -1
  84. package/lib/typescript/src/components/BottomSheet/BottomSheet.d.ts +5 -3
  85. package/lib/typescript/src/components/BottomSheet/BottomSheet.js +4 -4
  86. package/lib/typescript/src/components/BottomSheet/BottomSheet.js.map +1 -1
  87. package/lib/typescript/src/components/Button.js +6 -8
  88. package/lib/typescript/src/components/Button.js.map +1 -1
  89. package/lib/typescript/src/components/Checkbox/Checkbox.js +3 -3
  90. package/lib/typescript/src/components/Checkbox/Checkbox.js.map +1 -1
  91. package/lib/typescript/src/components/Checkbox/CheckboxRow.d.ts +2 -4
  92. package/lib/typescript/src/components/Checkbox/CheckboxRow.js +6 -7
  93. package/lib/typescript/src/components/Checkbox/CheckboxRow.js.map +1 -1
  94. package/lib/typescript/src/components/DatePicker/DatePicker.d.ts +5 -3
  95. package/lib/typescript/src/components/DatePicker/DatePicker.js +23 -24
  96. package/lib/typescript/src/components/DatePicker/DatePicker.js.map +1 -1
  97. package/lib/typescript/src/components/DatePicker/DatePickerComponent.web.d.ts +5010 -4
  98. package/lib/typescript/src/components/DatePicker/DatePickerComponent.web.js +6 -8
  99. package/lib/typescript/src/components/DatePicker/DatePickerComponent.web.js.map +1 -1
  100. package/lib/typescript/src/components/DatePicker/DatePickerComponentType.d.ts +2 -2
  101. package/lib/typescript/src/components/DeckSwiper/DeckSwiperCard.d.ts +5 -3
  102. package/lib/typescript/src/components/DeckSwiper/DeckSwiperCard.js +3 -3
  103. package/lib/typescript/src/components/DeckSwiper/DeckSwiperCard.js.map +1 -1
  104. package/lib/typescript/src/components/Divider.d.ts +5 -3
  105. package/lib/typescript/src/components/Divider.js +2 -2
  106. package/lib/typescript/src/components/Divider.js.map +1 -1
  107. package/lib/typescript/src/components/Elevation.d.ts +5 -3
  108. package/lib/typescript/src/components/Elevation.js +4 -3
  109. package/lib/typescript/src/components/Elevation.js.map +1 -1
  110. package/lib/typescript/src/components/FormRow.d.ts +2 -1
  111. package/lib/typescript/src/components/FormRow.js.map +1 -1
  112. package/lib/typescript/src/components/IconButton.d.ts +5 -3
  113. package/lib/typescript/src/components/IconButton.js +2 -2
  114. package/lib/typescript/src/components/IconButton.js.map +1 -1
  115. package/lib/typescript/src/components/MediaPlayer/AudioPlayer/AudioPlayerCommon.d.ts +2 -0
  116. package/lib/typescript/src/components/MediaPlayer/AudioPlayer/AudioPlayerWithInterface.d.ts +4 -5
  117. package/lib/typescript/src/components/MediaPlayer/AudioPlayer/AudioPlayerWithInterface.js +13 -10
  118. package/lib/typescript/src/components/MediaPlayer/AudioPlayer/AudioPlayerWithInterface.js.map +1 -1
  119. package/lib/typescript/src/components/MediaPlayer/AudioPlayer/index.d.ts +4 -2
  120. package/lib/typescript/src/components/MediaPlayer/AudioPlayer/index.js +3 -1
  121. package/lib/typescript/src/components/MediaPlayer/AudioPlayer/index.js.map +1 -1
  122. package/lib/typescript/src/components/Picker/NativePicker.d.ts +3 -1
  123. package/lib/typescript/src/components/Picker/NativePicker.js +2 -5
  124. package/lib/typescript/src/components/Picker/NativePicker.js.map +1 -1
  125. package/lib/typescript/src/components/Picker/PickerCommon.d.ts +2 -2
  126. package/lib/typescript/src/components/Picker/dropdown/DropDownModalPicker.d.ts +3 -1
  127. package/lib/typescript/src/components/Picker/dropdown/DropDownModalPicker.js +2 -2
  128. package/lib/typescript/src/components/Picker/dropdown/DropDownModalPicker.js.map +1 -1
  129. package/lib/typescript/src/components/Picker/dropdown/DropDownPicker.d.ts +3 -1
  130. package/lib/typescript/src/components/Picker/dropdown/DropDownPicker.js +2 -2
  131. package/lib/typescript/src/components/Picker/dropdown/DropDownPicker.js.map +1 -1
  132. package/lib/typescript/src/components/Picker/dropdown/MultiSelectPicker.d.ts +3 -1
  133. package/lib/typescript/src/components/Picker/dropdown/MultiSelectPicker.js +1 -1
  134. package/lib/typescript/src/components/Picker/dropdown/MultiSelectPicker.js.map +1 -1
  135. package/lib/typescript/src/components/Picker/index.d.ts +3 -1
  136. package/lib/typescript/src/components/Picker/index.js +1 -1
  137. package/lib/typescript/src/components/Picker/index.js.map +1 -1
  138. package/lib/typescript/src/components/PinInput/PinInput.d.ts +5 -3
  139. package/lib/typescript/src/components/PinInput/PinInput.js +4 -4
  140. package/lib/typescript/src/components/PinInput/PinInput.js.map +1 -1
  141. package/lib/typescript/src/components/PinInput/PinInputText.d.ts +5 -3
  142. package/lib/typescript/src/components/PinInput/PinInputText.js +2 -2
  143. package/lib/typescript/src/components/PinInput/PinInputText.js.map +1 -1
  144. package/lib/typescript/src/components/Portal/Portal.d.ts +9 -1
  145. package/lib/typescript/src/components/Portal/Portal.js +5 -3
  146. package/lib/typescript/src/components/Portal/Portal.js.map +1 -1
  147. package/lib/typescript/src/components/Progress/CircularProgress/CircularProgress.js +1 -1
  148. package/lib/typescript/src/components/Progress/CircularProgress/CircularProgress.js.map +1 -1
  149. package/lib/typescript/src/components/Progress/CircularProgress/index.d.ts +3 -1
  150. package/lib/typescript/src/components/Progress/CircularProgress/index.js +1 -1
  151. package/lib/typescript/src/components/Progress/CircularProgress/index.js.map +1 -1
  152. package/lib/typescript/src/components/Progress/LinearProgress/LinearProgress.js +1 -1
  153. package/lib/typescript/src/components/Progress/LinearProgress/LinearProgress.js.map +1 -1
  154. package/lib/typescript/src/components/Progress/LinearProgress/index.d.ts +3 -1
  155. package/lib/typescript/src/components/Progress/LinearProgress/index.js +1 -1
  156. package/lib/typescript/src/components/Progress/LinearProgress/index.js.map +1 -1
  157. package/lib/typescript/src/components/Progress/ProgressCommon.d.ts +2 -2
  158. package/lib/typescript/src/components/ProgressIndicator.d.ts +13 -10
  159. package/lib/typescript/src/components/ProgressIndicator.js +1 -1
  160. package/lib/typescript/src/components/ProgressIndicator.js.map +1 -1
  161. package/lib/typescript/src/components/RadioButton/RadioButtonGroup.d.ts +2 -2
  162. package/lib/typescript/src/components/RadioButton/RadioButtonRow.d.ts +2 -4
  163. package/lib/typescript/src/components/RadioButton/RadioButtonRow.js +3 -4
  164. package/lib/typescript/src/components/RadioButton/RadioButtonRow.js.map +1 -1
  165. package/lib/typescript/src/components/Row.d.ts +5 -3
  166. package/lib/typescript/src/components/Row.js +1 -1
  167. package/lib/typescript/src/components/Row.js.map +1 -1
  168. package/lib/typescript/src/components/ScreenContainer.d.ts +6 -3
  169. package/lib/typescript/src/components/ScreenContainer.js +2 -3
  170. package/lib/typescript/src/components/ScreenContainer.js.map +1 -1
  171. package/lib/typescript/src/components/SectionList/SectionHeader.d.ts +5 -3
  172. package/lib/typescript/src/components/SectionList/SectionHeader.js +3 -3
  173. package/lib/typescript/src/components/SectionList/SectionHeader.js.map +1 -1
  174. package/lib/typescript/src/components/SectionList/SectionList.d.ts +6 -4
  175. package/lib/typescript/src/components/SectionList/SectionList.js +4 -4
  176. package/lib/typescript/src/components/SectionList/SectionList.js.map +1 -1
  177. package/lib/typescript/src/components/SimpleStyleScrollables/SimpleStyleFlashList.d.ts +2 -1
  178. package/lib/typescript/src/components/SimpleStyleScrollables/SimpleStyleFlashList.js +3 -3
  179. package/lib/typescript/src/components/SimpleStyleScrollables/SimpleStyleFlashList.js.map +1 -1
  180. package/lib/typescript/src/components/SimpleStyleScrollables/SimpleStyleFlatList.d.ts +2 -1
  181. package/lib/typescript/src/components/SimpleStyleScrollables/SimpleStyleFlatList.js +3 -3
  182. package/lib/typescript/src/components/SimpleStyleScrollables/SimpleStyleFlatList.js.map +1 -1
  183. package/lib/typescript/src/components/SimpleStyleScrollables/SimpleStyleKeyboardAwareScrollView.d.ts +2 -1
  184. package/lib/typescript/src/components/SimpleStyleScrollables/SimpleStyleKeyboardAwareScrollView.js +3 -3
  185. package/lib/typescript/src/components/SimpleStyleScrollables/SimpleStyleKeyboardAwareScrollView.js.map +1 -1
  186. package/lib/typescript/src/components/SimpleStyleScrollables/SimpleStyleMasonryFlashList.d.ts +2 -2
  187. package/lib/typescript/src/components/SimpleStyleScrollables/SimpleStyleMasonryFlashList.js +3 -3
  188. package/lib/typescript/src/components/SimpleStyleScrollables/SimpleStyleMasonryFlashList.js.map +1 -1
  189. package/lib/typescript/src/components/SimpleStyleScrollables/SimpleStyleScrollView.d.ts +2 -1
  190. package/lib/typescript/src/components/SimpleStyleScrollables/SimpleStyleScrollView.js +3 -3
  191. package/lib/typescript/src/components/SimpleStyleScrollables/SimpleStyleScrollView.js.map +1 -1
  192. package/lib/typescript/src/components/SimpleStyleScrollables/SimpleStyleSectionList.d.ts +6 -2
  193. package/lib/typescript/src/components/SimpleStyleScrollables/SimpleStyleSectionList.js +3 -3
  194. package/lib/typescript/src/components/SimpleStyleScrollables/SimpleStyleSectionList.js.map +1 -1
  195. package/lib/typescript/src/components/SimpleStyleScrollables/SimpleStyleSwipeableList.d.ts +6 -2
  196. package/lib/typescript/src/components/SimpleStyleScrollables/SimpleStyleSwipeableList.js +3 -3
  197. package/lib/typescript/src/components/SimpleStyleScrollables/SimpleStyleSwipeableList.js.map +1 -1
  198. package/lib/typescript/src/components/Slider.d.ts +6 -3
  199. package/lib/typescript/src/components/Slider.js +6 -6
  200. package/lib/typescript/src/components/Slider.js.map +1 -1
  201. package/lib/typescript/src/components/StarRating.d.ts +5 -3
  202. package/lib/typescript/src/components/StarRating.js +1 -1
  203. package/lib/typescript/src/components/StarRating.js.map +1 -1
  204. package/lib/typescript/src/components/Stepper.d.ts +5 -3
  205. package/lib/typescript/src/components/Stepper.js +2 -3
  206. package/lib/typescript/src/components/Stepper.js.map +1 -1
  207. package/lib/typescript/src/components/Surface.d.ts +5 -3
  208. package/lib/typescript/src/components/Surface.js +10 -3
  209. package/lib/typescript/src/components/Surface.js.map +1 -1
  210. package/lib/typescript/src/components/SwipeableItem/SwipeableItem.d.ts +5 -3
  211. package/lib/typescript/src/components/SwipeableItem/SwipeableItem.js +5 -10
  212. package/lib/typescript/src/components/SwipeableItem/SwipeableItem.js.map +1 -1
  213. package/lib/typescript/src/components/SwipeableItem/SwipeableList.d.ts +3 -3
  214. package/lib/typescript/src/components/SwipeableItem/SwipeableList.js +4 -4
  215. package/lib/typescript/src/components/SwipeableItem/SwipeableList.js.map +1 -1
  216. package/lib/typescript/src/components/Swiper/Swiper.d.ts +2 -4
  217. package/lib/typescript/src/components/Swiper/Swiper.js +2 -3
  218. package/lib/typescript/src/components/Swiper/Swiper.js.map +1 -1
  219. package/lib/typescript/src/components/Switch.d.ts +24 -7
  220. package/lib/typescript/src/components/Switch.js +4 -3
  221. package/lib/typescript/src/components/Switch.js.map +1 -1
  222. package/lib/typescript/src/components/TabView/TabView.d.ts +7 -3
  223. package/lib/typescript/src/components/TabView/TabView.js +21 -6
  224. package/lib/typescript/src/components/TabView/TabView.js.map +1 -1
  225. package/lib/typescript/src/components/Table/Table.d.ts +5 -3
  226. package/lib/typescript/src/components/Table/Table.js +2 -2
  227. package/lib/typescript/src/components/Table/Table.js.map +1 -1
  228. package/lib/typescript/src/components/Table/TableRow.d.ts +5 -3
  229. package/lib/typescript/src/components/Table/TableRow.js +2 -4
  230. package/lib/typescript/src/components/Table/TableRow.js.map +1 -1
  231. package/lib/typescript/src/components/Text.d.ts +9 -3
  232. package/lib/typescript/src/components/Text.js +2 -2
  233. package/lib/typescript/src/components/Text.js.map +1 -1
  234. package/lib/typescript/src/components/TextField.d.ts +41 -4
  235. package/lib/typescript/src/components/TextField.js +20 -22
  236. package/lib/typescript/src/components/TextField.js.map +1 -1
  237. package/lib/typescript/src/components/TextInput.js +0 -3
  238. package/lib/typescript/src/components/TextInput.js.map +1 -1
  239. package/lib/typescript/src/components/Typography.d.ts +11 -5
  240. package/lib/typescript/src/components/Typography.js +4 -4
  241. package/lib/typescript/src/components/Typography.js.map +1 -1
  242. package/lib/typescript/src/deprecated-components/AccordionItem.d.ts +5 -3
  243. package/lib/typescript/src/deprecated-components/AccordionItem.js +2 -2
  244. package/lib/typescript/src/deprecated-components/AccordionItem.js.map +1 -1
  245. package/lib/typescript/src/deprecated-components/AvatarEdit.d.ts +5 -3
  246. package/lib/typescript/src/deprecated-components/AvatarEdit.js +4 -4
  247. package/lib/typescript/src/deprecated-components/AvatarEdit.js.map +1 -1
  248. package/lib/typescript/src/deprecated-components/Banner.d.ts +5 -3
  249. package/lib/typescript/src/deprecated-components/Banner.js +5 -4
  250. package/lib/typescript/src/deprecated-components/Banner.js.map +1 -1
  251. package/lib/typescript/src/deprecated-components/Card.d.ts +18 -6
  252. package/lib/typescript/src/deprecated-components/Card.js +3 -3
  253. package/lib/typescript/src/deprecated-components/Card.js.map +1 -1
  254. package/lib/typescript/src/deprecated-components/CheckboxGroup.d.ts +2 -2
  255. package/lib/typescript/src/deprecated-components/Container.d.ts +5 -3
  256. package/lib/typescript/src/deprecated-components/Container.js +1 -1
  257. package/lib/typescript/src/deprecated-components/Container.js.map +1 -1
  258. package/lib/typescript/src/deprecated-components/DeprecatedButton.d.ts +5 -3
  259. package/lib/typescript/src/deprecated-components/DeprecatedButton.js +8 -8
  260. package/lib/typescript/src/deprecated-components/DeprecatedButton.js.map +1 -1
  261. package/lib/typescript/src/deprecated-components/DeprecatedCardWrapper.d.ts +5 -3
  262. package/lib/typescript/src/deprecated-components/DeprecatedCardWrapper.js +1 -1
  263. package/lib/typescript/src/deprecated-components/DeprecatedCardWrapper.js.map +1 -1
  264. package/lib/typescript/src/deprecated-components/DeprecatedFAB.d.ts +5 -3
  265. package/lib/typescript/src/deprecated-components/DeprecatedFAB.js +8 -8
  266. package/lib/typescript/src/deprecated-components/DeprecatedFAB.js.map +1 -1
  267. package/lib/typescript/src/deprecated-components/FAB.d.ts +8 -3
  268. package/lib/typescript/src/deprecated-components/FAB.js +2 -2
  269. package/lib/typescript/src/deprecated-components/FAB.js.map +1 -1
  270. package/lib/typescript/src/deprecated-components/FieldSearchBarFull.d.ts +5 -3
  271. package/lib/typescript/src/deprecated-components/FieldSearchBarFull.js +4 -4
  272. package/lib/typescript/src/deprecated-components/FieldSearchBarFull.js.map +1 -1
  273. package/lib/typescript/src/deprecated-components/ProgressCircle.d.ts +8 -5
  274. package/lib/typescript/src/deprecated-components/ProgressCircle.js +3 -3
  275. package/lib/typescript/src/deprecated-components/ProgressCircle.js.map +1 -1
  276. package/lib/typescript/src/deprecated-components/RadioButtonFieldGroup.d.ts +3 -1
  277. package/lib/typescript/src/deprecated-components/RadioButtonFieldGroup.js +1 -1
  278. package/lib/typescript/src/deprecated-components/RadioButtonFieldGroup.js.map +1 -1
  279. package/lib/typescript/src/deprecated-components/RowBodyIcon.d.ts +5 -3
  280. package/lib/typescript/src/deprecated-components/RowBodyIcon.js +2 -2
  281. package/lib/typescript/src/deprecated-components/RowBodyIcon.js.map +1 -1
  282. package/lib/typescript/src/deprecated-components/RowHeadlineImageCaption.d.ts +5 -3
  283. package/lib/typescript/src/deprecated-components/RowHeadlineImageCaption.js +3 -3
  284. package/lib/typescript/src/deprecated-components/RowHeadlineImageCaption.js.map +1 -1
  285. package/lib/typescript/src/deprecated-components/RowHeadlineImageIcon.d.ts +5 -3
  286. package/lib/typescript/src/deprecated-components/RowHeadlineImageIcon.js +3 -3
  287. package/lib/typescript/src/deprecated-components/RowHeadlineImageIcon.js.map +1 -1
  288. package/lib/typescript/src/deprecated-components/ToggleButton.d.ts +9 -6
  289. package/lib/typescript/src/deprecated-components/ToggleButton.js +5 -5
  290. package/lib/typescript/src/deprecated-components/ToggleButton.js.map +1 -1
  291. package/lib/typescript/src/index.d.ts +2 -0
  292. package/lib/typescript/src/index.js +2 -0
  293. package/lib/typescript/src/index.js.map +1 -1
  294. package/lib/typescript/src/styles/DarkTheme.d.ts +3 -0
  295. package/lib/typescript/src/styles/DarkTheme.js +27 -0
  296. package/lib/typescript/src/styles/DarkTheme.js.map +1 -0
  297. package/lib/typescript/src/styles/DefaultTheme.d.ts +1670 -0
  298. package/lib/typescript/src/styles/DefaultTheme.js +112 -0
  299. package/lib/typescript/src/styles/DefaultTheme.js.map +1 -0
  300. package/lib/typescript/src/styles/fonts.d.ts +5 -0
  301. package/lib/typescript/src/styles/fonts.js +63 -0
  302. package/lib/typescript/src/styles/fonts.js.map +1 -0
  303. package/lib/typescript/src/styles/overlay.d.ts +2 -0
  304. package/lib/typescript/src/styles/overlay.js +61 -0
  305. package/lib/typescript/src/styles/overlay.js.map +1 -0
  306. package/lib/typescript/src/styles/shadow.d.ts +23 -0
  307. package/lib/typescript/src/styles/shadow.js +52 -0
  308. package/lib/typescript/src/styles/shadow.js.map +1 -0
  309. package/lib/typescript/src/theming.d.ts +8 -0
  310. package/lib/typescript/src/theming.js +4 -0
  311. package/lib/typescript/src/theming.js.map +1 -0
  312. package/lib/typescript/tsconfig.tsbuildinfo +1 -1
  313. package/package.json +5 -4
  314. package/src/Provider.js +4 -4
  315. package/src/Provider.js.map +1 -1
  316. package/src/Provider.tsx +12 -15
  317. package/src/components/AccordionGroup.js +3 -3
  318. package/src/components/AccordionGroup.js.map +1 -1
  319. package/src/components/AccordionGroup.tsx +5 -5
  320. package/src/components/BottomSheet/BottomSheet.js +4 -4
  321. package/src/components/BottomSheet/BottomSheet.js.map +1 -1
  322. package/src/components/BottomSheet/BottomSheet.tsx +7 -7
  323. package/src/components/Button.js +6 -8
  324. package/src/components/Button.js.map +1 -1
  325. package/src/components/Button.tsx +10 -10
  326. package/src/components/Checkbox/Checkbox.js +3 -3
  327. package/src/components/Checkbox/Checkbox.js.map +1 -1
  328. package/src/components/Checkbox/Checkbox.tsx +3 -3
  329. package/src/components/Checkbox/CheckboxRow.js +6 -7
  330. package/src/components/Checkbox/CheckboxRow.js.map +1 -1
  331. package/src/components/Checkbox/CheckboxRow.tsx +5 -12
  332. package/src/components/DatePicker/DatePicker.js +23 -24
  333. package/src/components/DatePicker/DatePicker.js.map +1 -1
  334. package/src/components/DatePicker/DatePicker.tsx +24 -25
  335. package/src/components/DatePicker/DatePickerComponent.web.js +6 -8
  336. package/src/components/DatePicker/DatePickerComponent.web.js.map +1 -1
  337. package/src/components/DatePicker/DatePickerComponent.web.tsx +8 -15
  338. package/src/components/DatePicker/DatePickerComponentType.ts +3 -2
  339. package/src/components/DeckSwiper/DeckSwiperCard.js +3 -3
  340. package/src/components/DeckSwiper/DeckSwiperCard.js.map +1 -1
  341. package/src/components/DeckSwiper/DeckSwiperCard.tsx +5 -5
  342. package/src/components/Divider.js +2 -2
  343. package/src/components/Divider.js.map +1 -1
  344. package/src/components/Divider.tsx +4 -4
  345. package/src/components/Elevation.js +4 -3
  346. package/src/components/Elevation.js.map +1 -1
  347. package/src/components/Elevation.tsx +6 -5
  348. package/src/components/FormRow.js.map +1 -1
  349. package/src/components/FormRow.tsx +2 -1
  350. package/src/components/IconButton.js +2 -2
  351. package/src/components/IconButton.js.map +1 -1
  352. package/src/components/IconButton.tsx +4 -4
  353. package/src/components/MediaPlayer/AudioPlayer/AudioPlayerCommon.ts +2 -0
  354. package/src/components/MediaPlayer/AudioPlayer/AudioPlayerWithInterface.js +13 -10
  355. package/src/components/MediaPlayer/AudioPlayer/AudioPlayerWithInterface.js.map +1 -1
  356. package/src/components/MediaPlayer/AudioPlayer/AudioPlayerWithInterface.tsx +19 -19
  357. package/src/components/MediaPlayer/AudioPlayer/index.js +3 -1
  358. package/src/components/MediaPlayer/AudioPlayer/index.js.map +1 -1
  359. package/src/components/MediaPlayer/AudioPlayer/index.tsx +3 -1
  360. package/src/components/Picker/NativePicker.js +2 -5
  361. package/src/components/Picker/NativePicker.js.map +1 -1
  362. package/src/components/Picker/NativePicker.tsx +2 -5
  363. package/src/components/Picker/PickerCommon.ts +2 -2
  364. package/src/components/Picker/dropdown/DropDownModalPicker.js +2 -2
  365. package/src/components/Picker/dropdown/DropDownModalPicker.js.map +1 -1
  366. package/src/components/Picker/dropdown/DropDownModalPicker.tsx +5 -5
  367. package/src/components/Picker/dropdown/DropDownPicker.js +2 -2
  368. package/src/components/Picker/dropdown/DropDownPicker.js.map +1 -1
  369. package/src/components/Picker/dropdown/DropDownPicker.tsx +5 -5
  370. package/src/components/Picker/dropdown/MultiSelectPicker.js +1 -1
  371. package/src/components/Picker/dropdown/MultiSelectPicker.js.map +1 -1
  372. package/src/components/Picker/dropdown/MultiSelectPicker.tsx +1 -1
  373. package/src/components/Picker/index.js +1 -1
  374. package/src/components/Picker/index.js.map +1 -1
  375. package/src/components/Picker/index.tsx +1 -1
  376. package/src/components/PinInput/PinInput.js +4 -4
  377. package/src/components/PinInput/PinInput.js.map +1 -1
  378. package/src/components/PinInput/PinInput.tsx +6 -6
  379. package/src/components/PinInput/PinInputText.js +2 -2
  380. package/src/components/PinInput/PinInputText.js.map +1 -1
  381. package/src/components/PinInput/PinInputText.tsx +4 -4
  382. package/src/components/Portal/Portal.js +5 -3
  383. package/src/components/Portal/Portal.js.map +1 -1
  384. package/src/components/Portal/Portal.tsx +10 -3
  385. package/src/components/Progress/CircularProgress/CircularProgress.js +1 -1
  386. package/src/components/Progress/CircularProgress/CircularProgress.js.map +1 -1
  387. package/src/components/Progress/CircularProgress/CircularProgress.tsx +2 -2
  388. package/src/components/Progress/CircularProgress/index.js +1 -1
  389. package/src/components/Progress/CircularProgress/index.js.map +1 -1
  390. package/src/components/Progress/CircularProgress/index.tsx +1 -1
  391. package/src/components/Progress/LinearProgress/LinearProgress.js +1 -1
  392. package/src/components/Progress/LinearProgress/LinearProgress.js.map +1 -1
  393. package/src/components/Progress/LinearProgress/LinearProgress.tsx +2 -2
  394. package/src/components/Progress/LinearProgress/index.js +1 -1
  395. package/src/components/Progress/LinearProgress/index.js.map +1 -1
  396. package/src/components/Progress/LinearProgress/index.tsx +1 -1
  397. package/src/components/Progress/ProgressCommon.ts +2 -2
  398. package/src/components/ProgressIndicator.js +1 -1
  399. package/src/components/ProgressIndicator.js.map +1 -1
  400. package/src/components/ProgressIndicator.tsx +11 -10
  401. package/src/components/RadioButton/RadioButtonGroup.tsx +2 -2
  402. package/src/components/RadioButton/RadioButtonRow.js +3 -4
  403. package/src/components/RadioButton/RadioButtonRow.js.map +1 -1
  404. package/src/components/RadioButton/RadioButtonRow.tsx +2 -9
  405. package/src/components/Row.js +1 -1
  406. package/src/components/Row.js.map +1 -1
  407. package/src/components/Row.tsx +3 -3
  408. package/src/components/ScreenContainer.js +2 -3
  409. package/src/components/ScreenContainer.js.map +1 -1
  410. package/src/components/ScreenContainer.tsx +4 -5
  411. package/src/components/SectionList/SectionHeader.js +3 -3
  412. package/src/components/SectionList/SectionHeader.js.map +1 -1
  413. package/src/components/SectionList/SectionHeader.tsx +5 -5
  414. package/src/components/SectionList/SectionList.js +4 -4
  415. package/src/components/SectionList/SectionList.js.map +1 -1
  416. package/src/components/SectionList/SectionList.tsx +152 -145
  417. package/src/components/SimpleStyleScrollables/SimpleStyleFlashList.js +3 -3
  418. package/src/components/SimpleStyleScrollables/SimpleStyleFlashList.js.map +1 -1
  419. package/src/components/SimpleStyleScrollables/SimpleStyleFlashList.tsx +22 -16
  420. package/src/components/SimpleStyleScrollables/SimpleStyleFlatList.js +3 -3
  421. package/src/components/SimpleStyleScrollables/SimpleStyleFlatList.js.map +1 -1
  422. package/src/components/SimpleStyleScrollables/SimpleStyleFlatList.tsx +22 -16
  423. package/src/components/SimpleStyleScrollables/SimpleStyleKeyboardAwareScrollView.js +3 -3
  424. package/src/components/SimpleStyleScrollables/SimpleStyleKeyboardAwareScrollView.js.map +1 -1
  425. package/src/components/SimpleStyleScrollables/SimpleStyleKeyboardAwareScrollView.tsx +20 -13
  426. package/src/components/SimpleStyleScrollables/SimpleStyleMasonryFlashList.js +3 -3
  427. package/src/components/SimpleStyleScrollables/SimpleStyleMasonryFlashList.js.map +1 -1
  428. package/src/components/SimpleStyleScrollables/SimpleStyleMasonryFlashList.tsx +27 -17
  429. package/src/components/SimpleStyleScrollables/SimpleStyleScrollView.js +3 -3
  430. package/src/components/SimpleStyleScrollables/SimpleStyleScrollView.js.map +1 -1
  431. package/src/components/SimpleStyleScrollables/SimpleStyleScrollView.tsx +20 -13
  432. package/src/components/SimpleStyleScrollables/SimpleStyleSectionList.js +3 -3
  433. package/src/components/SimpleStyleScrollables/SimpleStyleSectionList.js.map +1 -1
  434. package/src/components/SimpleStyleScrollables/SimpleStyleSectionList.tsx +28 -20
  435. package/src/components/SimpleStyleScrollables/SimpleStyleSwipeableList.js +3 -3
  436. package/src/components/SimpleStyleScrollables/SimpleStyleSwipeableList.js.map +1 -1
  437. package/src/components/SimpleStyleScrollables/SimpleStyleSwipeableList.tsx +28 -20
  438. package/src/components/Slider.js +6 -6
  439. package/src/components/Slider.js.map +1 -1
  440. package/src/components/Slider.tsx +8 -8
  441. package/src/components/StarRating.js +1 -1
  442. package/src/components/StarRating.js.map +1 -1
  443. package/src/components/StarRating.tsx +3 -3
  444. package/src/components/Stepper.js +2 -3
  445. package/src/components/Stepper.js.map +1 -1
  446. package/src/components/Stepper.tsx +4 -5
  447. package/src/components/Surface.js +10 -3
  448. package/src/components/Surface.js.map +1 -1
  449. package/src/components/Surface.tsx +12 -5
  450. package/src/components/SwipeableItem/SwipeableItem.js +5 -10
  451. package/src/components/SwipeableItem/SwipeableItem.js.map +1 -1
  452. package/src/components/SwipeableItem/SwipeableItem.tsx +7 -13
  453. package/src/components/SwipeableItem/SwipeableList.js +4 -4
  454. package/src/components/SwipeableItem/SwipeableList.js.map +1 -1
  455. package/src/components/SwipeableItem/SwipeableList.tsx +47 -32
  456. package/src/components/Swiper/Swiper.js +2 -3
  457. package/src/components/Swiper/Swiper.js.map +1 -1
  458. package/src/components/Swiper/Swiper.tsx +3 -6
  459. package/src/components/Switch.js +4 -3
  460. package/src/components/Switch.js.map +1 -1
  461. package/src/components/Switch.tsx +7 -7
  462. package/src/components/TabView/TabView.js +21 -6
  463. package/src/components/TabView/TabView.js.map +1 -1
  464. package/src/components/TabView/TabView.tsx +26 -7
  465. package/src/components/Table/Table.js +2 -2
  466. package/src/components/Table/Table.js.map +1 -1
  467. package/src/components/Table/Table.tsx +4 -4
  468. package/src/components/Table/TableRow.js +2 -4
  469. package/src/components/Table/TableRow.js.map +1 -1
  470. package/src/components/Table/TableRow.tsx +4 -6
  471. package/src/components/Text.js +2 -2
  472. package/src/components/Text.js.map +1 -1
  473. package/src/components/Text.tsx +4 -4
  474. package/src/components/TextField.js +20 -22
  475. package/src/components/TextField.js.map +1 -1
  476. package/src/components/TextField.tsx +23 -26
  477. package/src/components/TextInput.js +0 -3
  478. package/src/components/TextInput.js.map +1 -1
  479. package/src/components/TextInput.tsx +0 -3
  480. package/src/components/Typography.js +4 -4
  481. package/src/components/Typography.js.map +1 -1
  482. package/src/components/Typography.tsx +6 -6
  483. package/src/deprecated-components/AccordionItem.js +2 -2
  484. package/src/deprecated-components/AccordionItem.js.map +1 -1
  485. package/src/deprecated-components/AccordionItem.tsx +4 -4
  486. package/src/deprecated-components/AvatarEdit.js +4 -4
  487. package/src/deprecated-components/AvatarEdit.js.map +1 -1
  488. package/src/deprecated-components/AvatarEdit.tsx +6 -6
  489. package/src/deprecated-components/Banner.js +5 -4
  490. package/src/deprecated-components/Banner.js.map +1 -1
  491. package/src/deprecated-components/Banner.tsx +10 -6
  492. package/src/deprecated-components/Card.js +3 -3
  493. package/src/deprecated-components/Card.js.map +1 -1
  494. package/src/deprecated-components/Card.tsx +6 -10
  495. package/src/deprecated-components/CheckboxGroup.tsx +2 -2
  496. package/src/deprecated-components/Container.js +1 -1
  497. package/src/deprecated-components/Container.js.map +1 -1
  498. package/src/deprecated-components/Container.tsx +3 -3
  499. package/src/deprecated-components/DeprecatedButton.js +8 -8
  500. package/src/deprecated-components/DeprecatedButton.js.map +1 -1
  501. package/src/deprecated-components/DeprecatedButton.tsx +10 -10
  502. package/src/deprecated-components/DeprecatedCardWrapper.js +1 -1
  503. package/src/deprecated-components/DeprecatedCardWrapper.js.map +1 -1
  504. package/src/deprecated-components/DeprecatedCardWrapper.tsx +3 -3
  505. package/src/deprecated-components/DeprecatedFAB.js +8 -8
  506. package/src/deprecated-components/DeprecatedFAB.js.map +1 -1
  507. package/src/deprecated-components/DeprecatedFAB.tsx +10 -10
  508. package/src/deprecated-components/FAB.js +2 -2
  509. package/src/deprecated-components/FAB.js.map +1 -1
  510. package/src/deprecated-components/FAB.tsx +4 -4
  511. package/src/deprecated-components/FieldSearchBarFull.js +4 -4
  512. package/src/deprecated-components/FieldSearchBarFull.js.map +1 -1
  513. package/src/deprecated-components/FieldSearchBarFull.tsx +6 -6
  514. package/src/deprecated-components/ProgressCircle.js +3 -3
  515. package/src/deprecated-components/ProgressCircle.js.map +1 -1
  516. package/src/deprecated-components/ProgressCircle.tsx +8 -7
  517. package/src/deprecated-components/RadioButtonFieldGroup.js +1 -1
  518. package/src/deprecated-components/RadioButtonFieldGroup.js.map +1 -1
  519. package/src/deprecated-components/RadioButtonFieldGroup.tsx +1 -1
  520. package/src/deprecated-components/RowBodyIcon.js +2 -2
  521. package/src/deprecated-components/RowBodyIcon.js.map +1 -1
  522. package/src/deprecated-components/RowBodyIcon.tsx +6 -6
  523. package/src/deprecated-components/RowHeadlineImageCaption.js +3 -3
  524. package/src/deprecated-components/RowHeadlineImageCaption.js.map +1 -1
  525. package/src/deprecated-components/RowHeadlineImageCaption.tsx +6 -6
  526. package/src/deprecated-components/RowHeadlineImageIcon.js +3 -3
  527. package/src/deprecated-components/RowHeadlineImageIcon.js.map +1 -1
  528. package/src/deprecated-components/RowHeadlineImageIcon.tsx +6 -6
  529. package/src/deprecated-components/ToggleButton.js +5 -5
  530. package/src/deprecated-components/ToggleButton.js.map +1 -1
  531. package/src/deprecated-components/ToggleButton.tsx +11 -12
  532. package/src/index.js +2 -0
  533. package/src/index.js.map +1 -1
  534. package/src/index.tsx +2 -0
  535. package/src/styles/DarkTheme.js +27 -0
  536. package/src/styles/DarkTheme.js.map +1 -0
  537. package/src/styles/DarkTheme.tsx +30 -0
  538. package/src/styles/DefaultTheme.js +112 -0
  539. package/src/styles/DefaultTheme.js.map +1 -0
  540. package/src/styles/DefaultTheme.tsx +114 -0
  541. package/src/styles/fonts.js +63 -0
  542. package/src/styles/fonts.js.map +1 -0
  543. package/src/styles/fonts.tsx +67 -0
  544. package/src/styles/overlay.js +61 -0
  545. package/src/styles/overlay.js.map +1 -0
  546. package/src/styles/overlay.tsx +69 -0
  547. package/src/styles/shadow.js +52 -0
  548. package/src/styles/shadow.js.map +1 -0
  549. package/src/styles/shadow.tsx +55 -0
  550. package/src/theming.js +4 -0
  551. package/src/theming.js.map +1 -0
  552. package/src/theming.tsx +6 -0
@@ -1,13 +1,15 @@
1
1
  import React from "react";
2
2
  import { StyleProp, ViewStyle } from "react-native";
3
- import type { ReadTheme } from "@draftbit/theme";
3
+ import type { Theme } from "../../styles/DefaultTheme";
4
4
  interface SectionHeaderProps {
5
5
  style?: StyleProp<ViewStyle>;
6
6
  }
7
7
  declare const SectionHeader: React.FC<React.PropsWithChildren<SectionHeaderProps>>;
8
8
  interface DefaultSectionHeaderProps {
9
9
  title: string;
10
- theme: ReadTheme;
10
+ theme: Theme;
11
11
  }
12
- export declare const DefaultSectionHeader: React.ComponentType<Omit<DefaultSectionHeaderProps, "theme">>;
12
+ export declare const DefaultSectionHeader: React.ComponentType<import("@draftbit/react-theme-provider").$Without<DefaultSectionHeaderProps, "theme"> & {
13
+ theme?: import("@draftbit/react-theme-provider").$DeepPartial<any> | undefined;
14
+ }> & import("@draftbit/react-theme-provider/typings/hoist-non-react-statics").NonReactStatics<React.ComponentType<DefaultSectionHeaderProps> & (({ title, theme }: DefaultSectionHeaderProps) => React.JSX.Element), {}>;
13
15
  export default SectionHeader;
@@ -1,11 +1,11 @@
1
1
  import React from "react";
2
2
  import { View, Text } from "react-native";
3
- import { withTheme } from "@draftbit/theme";
3
+ import { withTheme } from "../../theming";
4
4
  const SectionHeader = ({ style, children, }) => React.createElement(View, { style: [style] }, children);
5
5
  export const DefaultSectionHeader = withTheme(({ title, theme }) => {
6
6
  return (React.createElement(Text, { testID: "default-section-header", style: {
7
- color: theme.colors.background.brand,
8
- backgroundColor: theme.colors.branding.primary,
7
+ color: theme.colors.background,
8
+ backgroundColor: theme.colors.primary,
9
9
  fontSize: 16,
10
10
  padding: 10,
11
11
  } }, title));
@@ -1 +1 @@
1
- {"version":3,"file":"SectionHeader.js","sourceRoot":"","sources":["../../../../../src/components/SectionList/SectionHeader.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,IAAI,EAAwB,IAAI,EAAE,MAAM,cAAc,CAAC;AAChE,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAO5C,MAAM,aAAa,GAA0D,CAAC,EAC5E,KAAK,EACL,QAAQ,GACT,EAAE,EAAE,CAAC,oBAAC,IAAI,IAAC,KAAK,EAA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,CAAC,CACF,CAAC;AAEF,eAAe,aAAa,CAAC"}
@@ -1,6 +1,6 @@
1
1
  import React from "react";
2
- import { FlashListProps } from "@shopify/flash-list";
3
- import { FlatListProps } from "react-native";
2
+ import { FlashListProps, FlashList } from "@shopify/flash-list";
3
+ import { FlatListProps, FlatList } from "react-native";
4
4
  declare type ListComponentType = "FlatList" | "FlashList";
5
5
  interface AdditionalSectionListProps<T> {
6
6
  sectionKey: string;
@@ -16,7 +16,9 @@ interface AdditionalSectionListProps<T> {
16
16
  export declare type FlatListSectionListProps<T> = Omit<FlatListProps<T>, "renderItem"> & AdditionalSectionListProps<T>;
17
17
  export declare type FlashListSectionListProps<T> = Omit<FlashListProps<T>, "renderItem"> & AdditionalSectionListProps<T>;
18
18
  export declare const DEFAULT_SECTION = "Uncategorized";
19
- declare const SectionList: <T extends {
19
+ declare const SectionList: React.ForwardRefExoticComponent<(FlatListSectionListProps<{
20
20
  [key: string]: any;
21
- }>({ sectionKey, stickyHeader, listComponent, data: dataProp, renderItem: renderItemProp, keyExtractor: keyExtractorProp, ...rest }: FlatListSectionListProps<T> | FlashListSectionListProps<T>) => React.JSX.Element;
21
+ }> | FlashListSectionListProps<{
22
+ [key: string]: any;
23
+ }>) & React.RefAttributes<FlatList<any> | FlashList<any>>>;
22
24
  export default SectionList;
@@ -4,7 +4,7 @@ import { FlatList } from "react-native";
4
4
  import SectionHeader, { DefaultSectionHeader } from "./SectionHeader";
5
5
  import { flattenReactFragments } from "../../utilities";
6
6
  export const DEFAULT_SECTION = "Uncategorized";
7
- const SectionList = ({ sectionKey, stickyHeader = false, listComponent = "FlatList", data: dataProp, renderItem: renderItemProp, keyExtractor: keyExtractorProp, ...rest }) => {
7
+ const SectionList = React.forwardRef(({ sectionKey, stickyHeader = false, listComponent = "FlatList", data: dataProp, renderItem: renderItemProp, keyExtractor: keyExtractorProp, ...rest }, ref) => {
8
8
  const data = React.useMemo(() => (Array.isArray(dataProp) ? dataProp : []), [dataProp]);
9
9
  const dataWithSections = React.useMemo(() => {
10
10
  var _a;
@@ -102,10 +102,10 @@ const SectionList = ({ sectionKey, stickyHeader = false, listComponent = "FlatLi
102
102
  };
103
103
  switch (listComponent) {
104
104
  case "FlatList":
105
- return (React.createElement(FlatList, { stickyHeaderIndices: sectionHeaderIndicies, ...rest, data: dataWithSections, renderItem: renderItem, keyExtractor: keyExtractor }));
105
+ return (React.createElement(FlatList, { ref: ref, stickyHeaderIndices: sectionHeaderIndicies, ...rest, data: dataWithSections, renderItem: renderItem, keyExtractor: keyExtractor }));
106
106
  case "FlashList":
107
- return (React.createElement(FlashList, { stickyHeaderIndices: sectionHeaderIndicies, ...rest, data: dataWithSections, renderItem: renderItem, keyExtractor: keyExtractor }));
107
+ return (React.createElement(FlashList, { ref: ref, stickyHeaderIndices: sectionHeaderIndicies, ...rest, data: dataWithSections, renderItem: renderItem, keyExtractor: keyExtractor }));
108
108
  }
109
- };
109
+ });
110
110
  export default SectionList;
111
111
  //# sourceMappingURL=SectionList.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SectionList.js","sourceRoot":"","sources":["../../../../../src/components/SectionList/SectionList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAkB,SAAS,EAAE,MAAM,qBAAqB,CAAC;AAChE,OAAO,EAAiB,QAAQ,EAAE,MAAM,cAAc,CAAC;AACvD,OAAO,aAAa,EAAE,EAAE,oBAAoB,EAAE,MAAM,iBAAiB,CAAC;AACtE,OAAO,EAAE,qBAAqB,EAAE,MAAM,iBAAiB,CAAC;AAqCxD,MAAM,CAAC,MAAM,eAAe,GAAG,eAAe,CAAC;AAE/C,MAAM,WAAW,GAAG,CAAmC,EACrD,UAAU,EACV,YAAY,GAAG,KAAK,EACpB,aAAa,GAAG,UAAU,EAC1B,IAAI,EAAE,QAAQ,EACd,UAAU,EAAE,cAAc,EAC1B,YAAY,EAAE,gBAAgB,EAC9B,GAAG,IAAI,EACoD,EAAE,EAAE;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AE,KAAK,CAAC,KAAI,KAAK,CAAC,QAAQ,EAAE,CAAC;aACjE;SACF;IACH,CAAC,CAAC;IAEF,QAAQ,aAAa,EAAE;QACrB,KAAK,UAAU;YACb,OAAO,CACL,oBAAC,QAAQ,IACP,mBAAmB,EAAE,qBAAqB,KACrC,IAA0C,EAC/C,IAAI,EAAE,gBAAgB,EACtB,UAAU,EAAE,UAAU,EACtB,YAAY,EAAE,YAAY,GAC1B,CACH,CAAC;QACJ,KAAK,WAAW;YACd,OAAO,CACL,oBAAC,SAAS,IACR,mBAAmB,EAAE,qBAAqB,KACrC,IAA2C,EAChD,IAAI,EAAE,gBAAgB,EACtB,UAAU,EAAE,UAAU,EACtB,YAAY,EAAE,YAAY,GAC1B,CACH,CAAC;KACL;AACH,CAAC,CAAC;AAEF,eAAe,WAAW,CAAC"}
1
+ {"version":3,"file":"SectionList.js","sourceRoot":"","sources":["../../../../../src/components/SectionList/SectionList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAkB,SAAS,EAAE,MAAM,qBAAqB,CAAC;AAChE,OAAO,EAAiB,QAAQ,EAAE,MAAM,cAAc,CAAC;AACvD,OAAO,aAAa,EAAE,EAAE,oBAAoB,EAAE,MAAM,iBAAiB,CAAC;AACtE,OAAO,EAAE,qBAAqB,EAAE,MAAM,iBAAiB,CAAC;AAqCxD,MAAM,CAAC,MAAM,eAAe,GAAG,eAAe,CAAC;AAE/C,MAAM,WAAW,GAAG,KAAK,CAAC,UAAU,CAClC,CACE,EACE,UAAU,EACV,YAAY,GAAG,KAAK,EACpB,aAAa,GAAG,UAAU,EAC1B,IAAI,EAAE,QAAQ,EACd,UAAU,EAAE,cAAc,EAC1B,YAAY,EAAE,gBAAgB,EAC9B,GAAG,IAAI,EACoD,EAC7D,GAAyC,EACzC,EAAE;IACF,MAAM,IAAI,GAAG,KAAK,CAAC,OAAO,CACxB,GAAG,EAAE,CAAC,CAAC,KAAK,CAAC,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,QAAQ,aAAa,EAAE;QACrB,KAAK,UAAU;YACb,OAAO,CACL,oBAAC,QAAQ,IACP,GAAG,EAAE,GAA0B,EAC/B,mBAAmB,EAAE,qBAAqB,KACrC,IAA0C,EAC/C,IAAI,EAAE,gBAAgB,EACtB,UAAU,EAAE,UAAU,EACtB,YAAY,EAAE,YAAY,GAC1B,CACH,CAAC;QACJ,KAAK,WAAW;YACd,OAAO,CACL,oBAAC,SAAS,IACR,GAAG,EAAE,GAA+C,EACpD,mBAAmB,EAAE,qBAAqB,KACrC,IAA2C,EAChD,IAAI,EAAE,gBAAgB,EACtB,UAAU,EAAE,UAAU,EACtB,YAAY,EAAE,YAAY,GAC1B,CACH,CAAC;KACL;AACH,CAAC,CACF,CAAC;AAEF,eAAe,WAAW,CAAC"}
@@ -1,8 +1,9 @@
1
1
  import React from "react";
2
+ import { FlashList } from "@shopify/flash-list";
2
3
  import type { FlashListProps } from "@shopify/flash-list";
3
4
  /**
4
5
  * A FlashList wrapper that takes a single `style` prop and internally extracts
5
6
  * the appropriate style keys into the `contentContainerStyle`
6
7
  */
7
- declare const SimpleStyleFlashList: <T extends unknown>({ style: styleProp, data, ...rest }: Omit<FlashListProps<T>, "contentContainerStyle">) => React.JSX.Element;
8
+ declare const SimpleStyleFlashList: React.ForwardRefExoticComponent<Omit<FlashListProps<unknown>, "contentContainerStyle"> & React.RefAttributes<FlashList<any>>>;
8
9
  export default SimpleStyleFlashList;
@@ -5,9 +5,9 @@ import useSplitContentContainerStyles from "./useSplitContentContainerStyles";
5
5
  * A FlashList wrapper that takes a single `style` prop and internally extracts
6
6
  * the appropriate style keys into the `contentContainerStyle`
7
7
  */
8
- const SimpleStyleFlashList = ({ style: styleProp, data, ...rest }) => {
8
+ const SimpleStyleFlashList = React.forwardRef(({ style: styleProp, data, ...rest }, ref) => {
9
9
  const { style, contentContainerStyle } = useSplitContentContainerStyles(styleProp);
10
- return (React.createElement(FlashList, { style: style, contentContainerStyle: contentContainerStyle, data: data, ...rest }));
11
- };
10
+ return (React.createElement(FlashList, { ref: ref, style: style, contentContainerStyle: contentContainerStyle, data: data, ...rest }));
11
+ });
12
12
  export default SimpleStyleFlashList;
13
13
  //# sourceMappingURL=SimpleStyleFlashList.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SimpleStyleFlashList.js","sourceRoot":"","sources":["../../../../../src/components/SimpleStyleScrollables/SimpleStyleFlashList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAC;AAEhD,OAAO,8BAA8B,MAAM,kCAAkC,CAAC;AAE9E;;;GAGG;AACH,MAAM,oBAAoB,GAAG,CAAgB,EAC3C,KAAK,EAAE,SAAS,EAChB,IAAI,EACJ,GAAG,IAAI,EAC0C,EAAE,EAAE;IACrD,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GACpC,8BAA8B,CAAC,SAAS,CAAC,CAAC;IAE5C,OAAO,CACL,oBAAC,SAAS,IACR,KAAK,EAAE,KAAK,EACZ,qBAAqB,EAAE,qBAAqC,EAC5D,IAAI,EAAE,IAAI,KACN,IAAI,GACR,CACH,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,oBAAoB,CAAC"}
1
+ {"version":3,"file":"SimpleStyleFlashList.js","sourceRoot":"","sources":["../../../../../src/components/SimpleStyleScrollables/SimpleStyleFlashList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAC;AAEhD,OAAO,8BAA8B,MAAM,kCAAkC,CAAC;AAE9E;;;GAGG;AACH,MAAM,oBAAoB,GAAG,KAAK,CAAC,UAAU,CAC3C,CACE,EACE,KAAK,EAAE,SAAS,EAChB,IAAI,EACJ,GAAG,IAAI,EAC0C,EACnD,GAA8B,EAC9B,EAAE;IACF,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GACpC,8BAA8B,CAAC,SAAS,CAAC,CAAC;IAE5C,OAAO,CACL,oBAAC,SAAS,IACR,GAAG,EAAE,GAAG,EACR,KAAK,EAAE,KAAK,EACZ,qBAAqB,EAAE,qBAAqC,EAC5D,IAAI,EAAE,IAAI,KACN,IAAI,GACR,CACH,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,eAAe,oBAAoB,CAAC"}
@@ -1,8 +1,9 @@
1
1
  import React from "react";
2
+ import { FlatList } from "react-native";
2
3
  import type { FlatListProps } from "react-native";
3
4
  /**
4
5
  * A FlatList wrapper that takes a single `style` prop and internally extracts
5
6
  * the appropriate style keys into the `contentContainerStyle`
6
7
  */
7
- declare const SimpleStyleFlatList: <T extends unknown>({ style: styleProp, data, ...rest }: Omit<FlatListProps<T>, "contentContainerStyle">) => React.JSX.Element;
8
+ declare const SimpleStyleFlatList: React.ForwardRefExoticComponent<Omit<FlatListProps<unknown>, "contentContainerStyle"> & React.RefAttributes<FlatList<any>>>;
8
9
  export default SimpleStyleFlatList;
@@ -5,9 +5,9 @@ import useSplitContentContainerStyles from "./useSplitContentContainerStyles";
5
5
  * A FlatList wrapper that takes a single `style` prop and internally extracts
6
6
  * the appropriate style keys into the `contentContainerStyle`
7
7
  */
8
- const SimpleStyleFlatList = ({ style: styleProp, data, ...rest }) => {
8
+ const SimpleStyleFlatList = React.forwardRef(({ style: styleProp, data, ...rest }, ref) => {
9
9
  const { style, contentContainerStyle } = useSplitContentContainerStyles(styleProp);
10
- return (React.createElement(FlatList, { style: style, contentContainerStyle: contentContainerStyle, data: data, ...rest }));
11
- };
10
+ return (React.createElement(FlatList, { ref: ref, style: style, contentContainerStyle: contentContainerStyle, data: data, ...rest }));
11
+ });
12
12
  export default SimpleStyleFlatList;
13
13
  //# sourceMappingURL=SimpleStyleFlatList.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SimpleStyleFlatList.js","sourceRoot":"","sources":["../../../../../src/components/SimpleStyleScrollables/SimpleStyleFlatList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AAExC,OAAO,8BAA8B,MAAM,kCAAkC,CAAC;AAE9E;;;GAGG;AACH,MAAM,mBAAmB,GAAG,CAAgB,EAC1C,KAAK,EAAE,SAAS,EAChB,IAAI,EACJ,GAAG,IAAI,EACyC,EAAE,EAAE;IACpD,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GACpC,8BAA8B,CAAC,SAAS,CAAC,CAAC;IAE5C,OAAO,CACL,oBAAC,QAAQ,IACP,KAAK,EAAE,KAAK,EACZ,qBAAqB,EAAE,qBAAqB,EAC5C,IAAI,EAAE,IAAI,KACN,IAAI,GACR,CACH,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,mBAAmB,CAAC"}
1
+ {"version":3,"file":"SimpleStyleFlatList.js","sourceRoot":"","sources":["../../../../../src/components/SimpleStyleScrollables/SimpleStyleFlatList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AAExC,OAAO,8BAA8B,MAAM,kCAAkC,CAAC;AAE9E;;;GAGG;AACH,MAAM,mBAAmB,GAAG,KAAK,CAAC,UAAU,CAC1C,CACE,EACE,KAAK,EAAE,SAAS,EAChB,IAAI,EACJ,GAAG,IAAI,EACyC,EAClD,GAAwB,EACxB,EAAE;IACF,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GACpC,8BAA8B,CAAC,SAAS,CAAC,CAAC;IAE5C,OAAO,CACL,oBAAC,QAAQ,IACP,GAAG,EAAE,GAAG,EACR,KAAK,EAAE,KAAK,EACZ,qBAAqB,EAAE,qBAAqB,EAC5C,IAAI,EAAE,IAAI,KACN,IAAI,GACR,CACH,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,eAAe,mBAAmB,CAAC"}
@@ -1,8 +1,9 @@
1
1
  import React from "react";
2
+ import { KeyboardAwareScrollView } from "react-native-keyboard-aware-scroll-view";
2
3
  import type { KeyboardAwareScrollViewProps } from "react-native-keyboard-aware-scroll-view";
3
4
  /**
4
5
  * A KeyboardAwareScrollView wrapper that takes a single `style` prop and internally extracts
5
6
  * the appropriate style keys into the `contentContainerStyle`
6
7
  */
7
- declare const SimpleStyleKeyboardAwareScrollView: React.FC<Omit<KeyboardAwareScrollViewProps, "contentContainerStyle">>;
8
+ declare const SimpleStyleKeyboardAwareScrollView: React.ForwardRefExoticComponent<Omit<KeyboardAwareScrollViewProps, "contentContainerStyle"> & React.RefAttributes<KeyboardAwareScrollView>>;
8
9
  export default SimpleStyleKeyboardAwareScrollView;
@@ -5,9 +5,9 @@ import useSplitContentContainerStyles from "./useSplitContentContainerStyles";
5
5
  * A KeyboardAwareScrollView wrapper that takes a single `style` prop and internally extracts
6
6
  * the appropriate style keys into the `contentContainerStyle`
7
7
  */
8
- const SimpleStyleKeyboardAwareScrollView = ({ style: styleProp, ...rest }) => {
8
+ const SimpleStyleKeyboardAwareScrollView = React.forwardRef(({ style: styleProp, ...rest }, ref) => {
9
9
  const { style, contentContainerStyle } = useSplitContentContainerStyles(styleProp);
10
- return (React.createElement(KeyboardAwareScrollView, { style: style, contentContainerStyle: contentContainerStyle, ...rest }));
11
- };
10
+ return (React.createElement(KeyboardAwareScrollView, { ref: ref, style: style, contentContainerStyle: contentContainerStyle, ...rest }));
11
+ });
12
12
  export default SimpleStyleKeyboardAwareScrollView;
13
13
  //# sourceMappingURL=SimpleStyleKeyboardAwareScrollView.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SimpleStyleKeyboardAwareScrollView.js","sourceRoot":"","sources":["../../../../../src/components/SimpleStyleScrollables/SimpleStyleKeyboardAwareScrollView.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,uBAAuB,EAAE,MAAM,yCAAyC,CAAC;AAElF,OAAO,8BAA8B,MAAM,kCAAkC,CAAC;AAE9E;;;GAGG;AACH,MAAM,kCAAkC,GAEpC,CAAC,EAAE,KAAK,EAAE,SAAS,EAAE,GAAG,IAAI,EAAE,EAAE,EAAE;IACpC,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GACpC,8BAA8B,CAAC,SAAS,CAAC,CAAC;IAE5C,OAAO,CACL,oBAAC,uBAAuB,IACtB,KAAK,EAAE,KAAK,EACZ,qBAAqB,EAAE,qBAAqB,KACxC,IAAI,GACR,CACH,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,kCAAkC,CAAC"}
1
+ {"version":3,"file":"SimpleStyleKeyboardAwareScrollView.js","sourceRoot":"","sources":["../../../../../src/components/SimpleStyleScrollables/SimpleStyleKeyboardAwareScrollView.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,uBAAuB,EAAE,MAAM,yCAAyC,CAAC;AAElF,OAAO,8BAA8B,MAAM,kCAAkC,CAAC;AAE9E;;;GAGG;AACH,MAAM,kCAAkC,GAAG,KAAK,CAAC,UAAU,CACzD,CACE,EACE,KAAK,EAAE,SAAS,EAChB,GAAG,IAAI,EACqD,EAC9D,GAAuC,EACvC,EAAE;IACF,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GACpC,8BAA8B,CAAC,SAAS,CAAC,CAAC;IAE5C,OAAO,CACL,oBAAC,uBAAuB,IACtB,GAAG,EAAE,GAAG,EACR,KAAK,EAAE,KAAK,EACZ,qBAAqB,EAAE,qBAAqB,KACxC,IAAI,GACR,CACH,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,eAAe,kCAAkC,CAAC"}
@@ -1,8 +1,8 @@
1
1
  import React from "react";
2
- import type { MasonryFlashListProps } from "@shopify/flash-list";
2
+ import type { MasonryFlashListProps, MasonryFlashListRef } from "@shopify/flash-list";
3
3
  /**
4
4
  * A MasonryFlashList wrapper that takes a single `style` prop and internally extracts
5
5
  * the appropriate style keys into the `contentContainerStyle`
6
6
  */
7
- declare const SimpleStyleMasonryFlashList: <T extends unknown>({ style: styleProp, data, ...rest }: Omit<MasonryFlashListProps<T>, "contentContainerStyle">) => React.JSX.Element;
7
+ declare const SimpleStyleMasonryFlashList: React.ForwardRefExoticComponent<Omit<MasonryFlashListProps<unknown>, "contentContainerStyle"> & React.RefAttributes<MasonryFlashListRef<any>>>;
8
8
  export default SimpleStyleMasonryFlashList;
@@ -5,9 +5,9 @@ import useSplitContentContainerStyles from "./useSplitContentContainerStyles";
5
5
  * A MasonryFlashList wrapper that takes a single `style` prop and internally extracts
6
6
  * the appropriate style keys into the `contentContainerStyle`
7
7
  */
8
- const SimpleStyleMasonryFlashList = ({ style: styleProp, data, ...rest }) => {
8
+ const SimpleStyleMasonryFlashList = React.forwardRef(({ style: styleProp, data, ...rest }, ref) => {
9
9
  const { style, contentContainerStyle } = useSplitContentContainerStyles(styleProp);
10
- return (React.createElement(MasonryFlashList, { style: style, contentContainerStyle: contentContainerStyle, data: data, ...rest }));
11
- };
10
+ return (React.createElement(MasonryFlashList, { ref: ref, style: style, contentContainerStyle: contentContainerStyle, data: data, ...rest }));
11
+ });
12
12
  export default SimpleStyleMasonryFlashList;
13
13
  //# sourceMappingURL=SimpleStyleMasonryFlashList.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SimpleStyleMasonryFlashList.js","sourceRoot":"","sources":["../../../../../src/components/SimpleStyleScrollables/SimpleStyleMasonryFlashList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAEvD,OAAO,8BAA8B,MAAM,kCAAkC,CAAC;AAE9E;;;GAGG;AACH,MAAM,2BAA2B,GAAG,CAAgB,EAClD,KAAK,EAAE,SAAS,EAChB,IAAI,EACJ,GAAG,IAAI,EACiD,EAAE,EAAE;IAC5D,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GACpC,8BAA8B,CAAC,SAAS,CAAC,CAAC;IAE5C,OAAO,CACL,oBAAC,gBAAgB,IACf,KAAK,EAAE,KAAK,EACZ,qBAAqB,EAAE,qBAAqC,EAC5D,IAAI,EAAE,IAAI,KACN,IAAI,GACR,CACH,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,2BAA2B,CAAC"}
1
+ {"version":3,"file":"SimpleStyleMasonryFlashList.js","sourceRoot":"","sources":["../../../../../src/components/SimpleStyleScrollables/SimpleStyleMasonryFlashList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAMvD,OAAO,8BAA8B,MAAM,kCAAkC,CAAC;AAE9E;;;GAGG;AACH,MAAM,2BAA2B,GAAG,KAAK,CAAC,UAAU,CAClD,CACE,EACE,KAAK,EAAE,SAAS,EAChB,IAAI,EACJ,GAAG,IAAI,EACiD,EAC1D,GAAwC,EACxC,EAAE;IACF,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GACpC,8BAA8B,CAAC,SAAS,CAAC,CAAC;IAE5C,OAAO,CACL,oBAAC,gBAAgB,IACf,GAAG,EAAE,GAAU,EACf,KAAK,EAAE,KAAK,EACZ,qBAAqB,EAAE,qBAAqC,EAC5D,IAAI,EAAE,IAAI,KACN,IAAI,GACR,CACH,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,eAAe,2BAA2B,CAAC"}
@@ -1,8 +1,9 @@
1
1
  import React from "react";
2
+ import { ScrollView } from "react-native";
2
3
  import type { ScrollViewProps } from "react-native";
3
4
  /**
4
5
  * A ScrollView wrapper that takes a single `style` prop and internally extracts
5
6
  * the appropriate style keys into the `contentContainerStyle`
6
7
  */
7
- declare const SimpleStyleScrollView: React.FC<Omit<ScrollViewProps, "contentContainerStyle">>;
8
+ declare const SimpleStyleScrollView: React.ForwardRefExoticComponent<Omit<ScrollViewProps, "contentContainerStyle"> & React.RefAttributes<ScrollView>>;
8
9
  export default SimpleStyleScrollView;
@@ -5,9 +5,9 @@ import useSplitContentContainerStyles from "./useSplitContentContainerStyles";
5
5
  * A ScrollView wrapper that takes a single `style` prop and internally extracts
6
6
  * the appropriate style keys into the `contentContainerStyle`
7
7
  */
8
- const SimpleStyleScrollView = ({ style: styleProp, ...rest }) => {
8
+ const SimpleStyleScrollView = React.forwardRef(({ style: styleProp, ...rest }, ref) => {
9
9
  const { style, contentContainerStyle } = useSplitContentContainerStyles(styleProp);
10
- return (React.createElement(ScrollView, { style: style, contentContainerStyle: contentContainerStyle, ...rest }));
11
- };
10
+ return (React.createElement(ScrollView, { ref: ref, style: style, contentContainerStyle: contentContainerStyle, ...rest }));
11
+ });
12
12
  export default SimpleStyleScrollView;
13
13
  //# sourceMappingURL=SimpleStyleScrollView.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SimpleStyleScrollView.js","sourceRoot":"","sources":["../../../../../src/components/SimpleStyleScrollables/SimpleStyleScrollView.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAE1C,OAAO,8BAA8B,MAAM,kCAAkC,CAAC;AAE9E;;;GAGG;AACH,MAAM,qBAAqB,GAEvB,CAAC,EAAE,KAAK,EAAE,SAAS,EAAE,GAAG,IAAI,EAAE,EAAE,EAAE;IACpC,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GACpC,8BAA8B,CAAC,SAAS,CAAC,CAAC;IAE5C,OAAO,CACL,oBAAC,UAAU,IACT,KAAK,EAAE,KAAK,EACZ,qBAAqB,EAAE,qBAAqB,KACxC,IAAI,GACR,CACH,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,qBAAqB,CAAC"}
1
+ {"version":3,"file":"SimpleStyleScrollView.js","sourceRoot":"","sources":["../../../../../src/components/SimpleStyleScrollables/SimpleStyleScrollView.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAE1C,OAAO,8BAA8B,MAAM,kCAAkC,CAAC;AAE9E;;;GAGG;AACH,MAAM,qBAAqB,GAAG,KAAK,CAAC,UAAU,CAC5C,CACE,EACE,KAAK,EAAE,SAAS,EAChB,GAAG,IAAI,EACwC,EACjD,GAA0B,EAC1B,EAAE;IACF,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GACpC,8BAA8B,CAAC,SAAS,CAAC,CAAC;IAE5C,OAAO,CACL,oBAAC,UAAU,IACT,GAAG,EAAE,GAAG,EACR,KAAK,EAAE,KAAK,EACZ,qBAAqB,EAAE,qBAAqB,KACxC,IAAI,GACR,CACH,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,eAAe,qBAAqB,CAAC"}
@@ -1,10 +1,14 @@
1
1
  import React from "react";
2
2
  import type { FlatListSectionListProps, FlashListSectionListProps } from "../SectionList";
3
+ import { FlatList } from "react-native-gesture-handler";
4
+ import { FlashList } from "@shopify/flash-list";
3
5
  /**
4
6
  * A SectionList wrapper that takes a single `style` prop and internally extracts
5
7
  * the appropriate style keys into the `contentContainerStyle`
6
8
  */
7
- declare const SimpleStyleSectionList: <T extends {
9
+ declare const SimpleStyleSectionList: React.ForwardRefExoticComponent<Omit<FlatListSectionListProps<{
8
10
  [key: string]: any;
9
- }>({ style: styleProp, data, ...rest }: Omit<FlatListSectionListProps<T> | FlashListSectionListProps<T>, "contentContainerStyle">) => React.JSX.Element;
11
+ }> | FlashListSectionListProps<{
12
+ [key: string]: any;
13
+ }>, "contentContainerStyle"> & React.RefAttributes<FlashList<any> | FlatList<any>>>;
10
14
  export default SimpleStyleSectionList;
@@ -5,11 +5,11 @@ import useSplitContentContainerStyles from "./useSplitContentContainerStyles";
5
5
  * A SectionList wrapper that takes a single `style` prop and internally extracts
6
6
  * the appropriate style keys into the `contentContainerStyle`
7
7
  */
8
- const SimpleStyleSectionList = ({ style: styleProp, data, ...rest }) => {
8
+ const SimpleStyleSectionList = React.forwardRef(({ style: styleProp, data, ...rest }, ref) => {
9
9
  const { style, contentContainerStyle } = useSplitContentContainerStyles(styleProp);
10
10
  return (
11
11
  //@ts-ignore contentContainerStyle has different types for FlashList and FlatList implmentations and confuses TS
12
- React.createElement(SectionList, { style: style, contentContainerStyle: contentContainerStyle, data: data, ...rest }));
13
- };
12
+ React.createElement(SectionList, { ref: ref, style: style, contentContainerStyle: contentContainerStyle, data: data, ...rest }));
13
+ });
14
14
  export default SimpleStyleSectionList;
15
15
  //# sourceMappingURL=SimpleStyleSectionList.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SimpleStyleSectionList.js","sourceRoot":"","sources":["../../../../../src/components/SimpleStyleScrollables/SimpleStyleSectionList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAK7C,OAAO,8BAA8B,MAAM,kCAAkC,CAAC;AAE9E;;;GAGG;AACH,MAAM,sBAAsB,GAAG,CAAmC,EAChE,KAAK,EAAE,SAAS,EAChB,IAAI,EACJ,GAAG,IAAI,EAIR,EAAE,EAAE;IACH,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GACpC,8BAA8B,CAAC,SAAS,CAAC,CAAC;IAE5C,OAAO;IACL,gHAAgH;IAChH,oBAAC,WAAW,IACV,KAAK,EAAE,KAAK,EACZ,qBAAqB,EAAE,qBAAqB,EAC5C,IAAI,EAAE,IAAI,KACN,IAAI,GACR,CACH,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,sBAAsB,CAAC"}
1
+ {"version":3,"file":"SimpleStyleSectionList.js","sourceRoot":"","sources":["../../../../../src/components/SimpleStyleScrollables/SimpleStyleSectionList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAK7C,OAAO,8BAA8B,MAAM,kCAAkC,CAAC;AAI9E;;;GAGG;AACH,MAAM,sBAAsB,GAAG,KAAK,CAAC,UAAU,CAC7C,CACE,EACE,KAAK,EAAE,SAAS,EAChB,IAAI,EACJ,GAAG,IAAI,EAIR,EACD,GAAyC,EACzC,EAAE;IACF,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GACpC,8BAA8B,CAAC,SAAS,CAAC,CAAC;IAE5C,OAAO;IACL,gHAAgH;IAChH,oBAAC,WAAW,IACV,GAAG,EAAE,GAAG,EACR,KAAK,EAAE,KAAK,EACZ,qBAAqB,EAAE,qBAAqB,EAC5C,IAAI,EAAE,IAAI,KACN,IAAI,GACR,CACH,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,eAAe,sBAAsB,CAAC"}
@@ -1,10 +1,14 @@
1
1
  import React from "react";
2
2
  import type { FlashListSwipeableListProps, FlatListSwipeableListProps } from "../SwipeableItem";
3
+ import { FlatList } from "react-native-gesture-handler";
4
+ import { FlashList } from "@shopify/flash-list";
3
5
  /**
4
6
  * A SwipeableList wrapper that takes a single `style` prop and internally extracts
5
7
  * the appropriate style keys into the `contentContainerStyle`
6
8
  */
7
- declare const SimpleStyleSwipeableList: <T extends {
9
+ declare const SimpleStyleSwipeableList: React.ForwardRefExoticComponent<Omit<FlashListSwipeableListProps<{
8
10
  [key: string]: any;
9
- }>({ style: styleProp, data, ...rest }: Omit<FlashListSwipeableListProps<T> | FlatListSwipeableListProps<T>, "contentContainerStyle">) => React.JSX.Element;
11
+ }> | FlatListSwipeableListProps<{
12
+ [key: string]: any;
13
+ }>, "contentContainerStyle"> & React.RefAttributes<FlashList<any> | FlatList<any>>>;
10
14
  export default SimpleStyleSwipeableList;
@@ -5,11 +5,11 @@ import useSplitContentContainerStyles from "./useSplitContentContainerStyles";
5
5
  * A SwipeableList wrapper that takes a single `style` prop and internally extracts
6
6
  * the appropriate style keys into the `contentContainerStyle`
7
7
  */
8
- const SimpleStyleSwipeableList = ({ style: styleProp, data, ...rest }) => {
8
+ const SimpleStyleSwipeableList = React.forwardRef(({ style: styleProp, data, ...rest }, ref) => {
9
9
  const { style, contentContainerStyle } = useSplitContentContainerStyles(styleProp);
10
10
  return (
11
11
  //@ts-ignore contentContainerStyle has different types for FlashList and FlatList implmentations and confuses TS
12
- React.createElement(SwipeableList, { style: style, contentContainerStyle: contentContainerStyle, data: data, ...rest }));
13
- };
12
+ React.createElement(SwipeableList, { ref: ref, style: style, contentContainerStyle: contentContainerStyle, data: data, ...rest }));
13
+ });
14
14
  export default SimpleStyleSwipeableList;
15
15
  //# sourceMappingURL=SimpleStyleSwipeableList.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SimpleStyleSwipeableList.js","sourceRoot":"","sources":["../../../../../src/components/SimpleStyleScrollables/SimpleStyleSwipeableList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAKjD,OAAO,8BAA8B,MAAM,kCAAkC,CAAC;AAE9E;;;GAGG;AACH,MAAM,wBAAwB,GAAG,CAAmC,EAClE,KAAK,EAAE,SAAS,EAChB,IAAI,EACJ,GAAG,IAAI,EAIR,EAAE,EAAE;IACH,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GACpC,8BAA8B,CAAC,SAAS,CAAC,CAAC;IAE5C,OAAO;IACL,gHAAgH;IAChH,oBAAC,aAAa,IACZ,KAAK,EAAE,KAAK,EACZ,qBAAqB,EAAE,qBAAqB,EAC5C,IAAI,EAAE,IAAI,KACN,IAAI,GACR,CACH,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,wBAAwB,CAAC"}
1
+ {"version":3,"file":"SimpleStyleSwipeableList.js","sourceRoot":"","sources":["../../../../../src/components/SimpleStyleScrollables/SimpleStyleSwipeableList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAKjD,OAAO,8BAA8B,MAAM,kCAAkC,CAAC;AAI9E;;;GAGG;AACH,MAAM,wBAAwB,GAAG,KAAK,CAAC,UAAU,CAC/C,CACE,EACE,KAAK,EAAE,SAAS,EAChB,IAAI,EACJ,GAAG,IAAI,EAIR,EACD,GAAyC,EACzC,EAAE;IACF,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GACpC,8BAA8B,CAAC,SAAS,CAAC,CAAC;IAE5C,OAAO;IACL,gHAAgH;IAChH,oBAAC,aAAa,IACZ,GAAG,EAAE,GAAG,EACR,KAAK,EAAE,KAAK,EACZ,qBAAqB,EAAE,qBAAqB,EAC5C,IAAI,EAAE,IAAI,KACN,IAAI,GACR,CACH,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,eAAe,wBAAwB,CAAC"}
@@ -1,6 +1,6 @@
1
1
  import * as React from "react";
2
2
  import { StyleProp, ViewStyle } from "react-native";
3
- import type { ReadTheme } from "@draftbit/theme";
3
+ import type { Theme } from "../styles/DefaultTheme";
4
4
  import type { IconSlot } from "../interfaces/Icon";
5
5
  export declare type Props = {
6
6
  style?: StyleProp<ViewStyle>;
@@ -18,7 +18,10 @@ export declare type Props = {
18
18
  maximumValue: number;
19
19
  step: number;
20
20
  onValueChange?: (value: number) => void;
21
- theme: ReadTheme;
21
+ theme: Theme;
22
22
  } & IconSlot;
23
- declare const _default: React.ComponentType<Omit<Props, "theme">>;
23
+ declare function Slider({ Icon, leftIcon, rightIcon, leftIconColor, rightIconColor, value, defaultValue, minimumTrackTintColor, maximumTrackTintColor, thumbTintColor, minimumValue, maximumValue, tapToSeek, step, onValueChange, style, theme, ...rest }: Props): React.JSX.Element;
24
+ declare const _default: React.ComponentType<import("@draftbit/react-theme-provider").$Without<Props, "theme"> & {
25
+ theme?: import("@draftbit/react-theme-provider").$DeepPartial<any> | undefined;
26
+ }> & import("@draftbit/react-theme-provider/typings/hoist-non-react-statics").NonReactStatics<React.ComponentType<Props> & typeof Slider, {}>;
24
27
  export default _default;
@@ -3,7 +3,7 @@ import { View, StyleSheet, Platform } from "react-native";
3
3
  import NativeSlider from "@react-native-community/slider";
4
4
  import isNumber from "lodash.isnumber";
5
5
  import toNumber from "lodash.tonumber";
6
- import { withTheme } from "@draftbit/theme";
6
+ import { withTheme } from "../theming";
7
7
  function maybeParseValue(value) {
8
8
  if (value === undefined) {
9
9
  return undefined;
@@ -52,11 +52,11 @@ function Slider({ Icon, leftIcon, rightIcon, leftIconColor, rightIconColor, valu
52
52
  setInternalValue(defaultValue);
53
53
  }
54
54
  }, [defaultValue]);
55
- const minTrackColor = minimumTrackTintColor || theme.colors.branding.primary;
56
- const maxTrackColor = maximumTrackTintColor || theme.colors.foreground.light;
57
- const thumbColor = thumbTintColor || theme.colors.branding.primary;
58
- const leftIconThemeColor = leftIconColor || theme.colors.text.light;
59
- const rightIconThemeColor = rightIconColor || theme.colors.text.light;
55
+ const minTrackColor = minimumTrackTintColor || theme.colors.primary;
56
+ const maxTrackColor = maximumTrackTintColor || theme.colors.light;
57
+ const thumbColor = thumbTintColor || theme.colors.primary;
58
+ const leftIconThemeColor = leftIconColor || theme.colors.light;
59
+ const rightIconThemeColor = rightIconColor || theme.colors.light;
60
60
  const parsedValue = maybeParseValue(internalValue);
61
61
  const handleSlidingComplete = (newValue) => {
62
62
  setInternalValue(newValue);
@@ -1 +1 @@
1
- {"version":3,"file":"Slider.js","sourceRoot":"","sources":["../../../../src/components/Slider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,IAAI,EAAE,UAAU,EAAwB,QAAQ,EAAE,MAAM,cAAc,CAAC;AAChF,OAAO,YAAY,MAAM,gCAAgC,CAAC;AAC1D,OAAO,QAAQ,MAAM,iBAAiB,CAAC;AACvC,OAAO,QAAQ,MAAM,iBAAiB,CAAC;AAEvC,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AA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EACxC,KAAK,EAAE,MAAM,CAAC,MAAM;YACpB,oCAAoC;YACpC,UAAU,EAAE,QAAQ,CAAC,EAAE,KAAK,KAAK,CAAC,CAAC,CAAC,cAAc,CAAC,CAAC,CAAC,SAAS,GAC9D;QACD,SAAS,CAAC,CAAC,CAAC,CACX,oBAAC,IAAI,IAAC,KAAK,EAAE,mBAAmB,EAAE,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,EAAE,GAAI,CAChE,CAAC,CAAC,CAAC,IAAI,CACH,CACR,CAAC;AACJ,CAAC;AAED,MAAM,MAAM,GAAG,UAAU,CAAC,MAAM,CAAC;IAC/B,SAAS,EAAE;QACT,MAAM,EAAE,EAAE;QACV,aAAa,EAAE,KAAK;QACpB,UAAU,EAAE,QAAQ;KACrB;IACD,MAAM,EAAE;QACN,IAAI,EAAE,CAAC;QACP,gBAAgB,EAAE,EAAE;KACrB;CACF,CAAC,CAAC;AAEH,eAAe,SAAS,CAAC,MAAM,CAAC,CAAC"}
@@ -1,6 +1,6 @@
1
1
  import * as React from "react";
2
2
  import { StyleProp, ViewStyle } from "react-native";
3
- import type { ReadTheme } from "@draftbit/theme";
3
+ import type { Theme } from "../styles/DefaultTheme";
4
4
  import type { IconSlot } from "../interfaces/Icon";
5
5
  declare type Props = {
6
6
  starSize?: number;
@@ -10,9 +10,11 @@ declare type Props = {
10
10
  isEditable?: boolean;
11
11
  activeColor?: string;
12
12
  inactiveColor?: string;
13
- theme: ReadTheme;
13
+ theme: Theme;
14
14
  style?: StyleProp<ViewStyle>;
15
15
  onPress?: (newValue: number) => void;
16
16
  } & IconSlot;
17
- declare const _default: React.ComponentType<Omit<React.PropsWithChildren<Props>, "theme">>;
17
+ declare const _default: React.ComponentType<import("@draftbit/react-theme-provider").$Without<React.PropsWithChildren<Props>, "theme"> & {
18
+ theme?: import("@draftbit/react-theme-provider").$DeepPartial<any> | undefined;
19
+ }> & import("@draftbit/react-theme-provider/typings/hoist-non-react-statics").NonReactStatics<React.ComponentType<React.PropsWithChildren<Props>> & React.FC<React.PropsWithChildren<Props>>, {}>;
18
20
  export default _default;
@@ -1,6 +1,6 @@
1
1
  import * as React from "react";
2
2
  import { View, StyleSheet, Pressable, } from "react-native";
3
- import { withTheme } from "@draftbit/theme";
3
+ import { withTheme } from "../theming";
4
4
  const StarRating = ({ Icon, starSize = 16, maxStars = 5, rating = 0, defaultValue, isEditable = false, activeColor, inactiveColor, style, onPress, ...rest }) => {
5
5
  const [localRating, setLocalRating] = React.useState(rating || defaultValue || 0);
6
6
  React.useEffect(() => {
@@ -1 +1 @@
1
- {"version":3,"file":"StarRating.js","sourceRoot":"","sources":["../../../../src/components/StarRating.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EACL,IAAI,EACJ,UAAU,EAGV,SAAS,GACV,MAAM,cAAc,CAAC;AACtB,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAiB5C,MAAM,UAAU,GAA6C,CAAC,EAC5D,IAAI,EACJ,QAAQ,GAAG,EAAE,EACb,QAAQ,GAAG,CAAC,EACZ,MAAM,GAAG,CAAC,EACV,YAAY,EACZ,UAAU,GAAG,KAAK,EAClB,WAAW,EACX,aAAa,EACb,KAAK,EACL,OAAO,EACP,GAAG,IAAI,EACR,EAAE,EAAE;IACH,MAAM,CAAC,WAAW,EAAE,cAAc,CAAC,GAAG,KAAK,CAAC,QAAQ,CAClD,MAAM,IAAI,YAAY,IAAI,CAAC,CAC5B,CAAC;IAEF,KAAK,CAAC,SAAS,CAAC,GAAG,EAAE;QACnB,IAAI,MAAM,IAAI,IAAI,EAAE;YAClB,cAAc,CAAC,MAAM,CAAC,CAAC;SACxB;IACH,CAAC,EAAE,CAAC,MAAM,CAAC,CAAC,CAAC;IAEb,KAAK,CAAC,SAAS,CAAC,GAAG,EAAE;QACnB,IAAI,YAAY,IAAI,IAAI,EAAE;YACxB,cAAc,CAAC,YAAY,CAAC,CAAC;SAC9B;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ACG,CACR,CACI,CACR,CAAC,CACG,CACR,CAAC;AACJ,CAAC,CAAC;AAEF,MAAM,MAAM,GAAG,UAAU,CAAC,MAAM,CAAC;IAC/B,SAAS,EAAE;QACT,aAAa,EAAE,KAAK;QACpB,UAAU,EAAE,QAAQ;KACrB;IACD,cAAc,EAAE;QACd,OAAO,EAAE,MAAM;QACf,aAAa,EAAE,KAAK;QACpB,QAAQ,EAAE,UAAU;QACpB,GAAG,EAAE,CAAC;QACN,KAAK,EAAE,CAAC;QACR,IAAI,EAAE,CAAC;QACP,MAAM,EAAE,CAAC;QACT,MAAM,EAAE,CAAC;KACV;IACD,SAAS,EAAE;QACT,IAAI,EAAE,CAAC;QACP,MAAM,EAAE,MAAM;QACd,KAAK,EAAE,KAAK;KACb;CACF,CAAC,CAAC;AAEH,eAAe,SAAS,CAAC,UAAU,CAAC,CAAC"}
1
+ {"version":3,"file":"StarRating.js","sourceRoot":"","sources":["../../../../src/components/StarRating.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EACL,IAAI,EACJ,UAAU,EAGV,SAAS,GACV,MAAM,cAAc,CAAC;AACtB,OAAO,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAiBvC,MAAM,UAAU,GAA6C,CAAC,EAC5D,IAAI,EACJ,QAAQ,GAAG,EAAE,EACb,QAAQ,GAAG,CAAC,EACZ,MAAM,GAAG,CAAC,EACV,YAAY,EACZ,UAAU,GAAG,KAAK,EAClB,WAAW,EACX,aAAa,EACb,KAAK,EACL,OAAO,EACP,GAAG,IAAI,EACR,EAAE,EAAE;IACH,MAAM,CAAC,WAAW,EAAE,cAAc,CAAC,GAAG,KAAK,CAAC,QAAQ,CAClD,MAAM,IAAI,YAAY,IAAI,CAAC,CAC5B,CAAC;IAEF,KAAK,CAAC,SAAS,CAAC,GAAG,EAAE;QACnB,IAAI,MAAM,IAAI,IAAI,EAAE;YAClB,cAAc,CAAC,MAAM,CAAC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,CAAC,aAAa,CAAC,CAAC,GAAG,GAAG,CAAC,GACrC;YACF,oBAAC,SAAS,IACR,KAAK,EAAE,MAAM,CAAC,SAAS,EACvB,OAAO,EAAE,GAAG,EAAE,CAAC,aAAa,CAAC,CAAC,GAAG,CAAC,CAAC,GACnC,CACG,CACR,CACI,CACR,CAAC,CACG,CACR,CAAC;AACJ,CAAC,CAAC;AAEF,MAAM,MAAM,GAAG,UAAU,CAAC,MAAM,CAAC;IAC/B,SAAS,EAAE;QACT,aAAa,EAAE,KAAK;QACpB,UAAU,EAAE,QAAQ;KACrB;IACD,cAAc,EAAE;QACd,OAAO,EAAE,MAAM;QACf,aAAa,EAAE,KAAK;QACpB,QAAQ,EAAE,UAAU;QACpB,GAAG,EAAE,CAAC;QACN,KAAK,EAAE,CAAC;QACR,IAAI,EAAE,CAAC;QACP,MAAM,EAAE,CAAC;QACT,MAAM,EAAE,CAAC;KACV;IACD,SAAS,EAAE;QACT,IAAI,EAAE,CAAC;QACP,MAAM,EAAE,MAAM;QACd,KAAK,EAAE,KAAK;KACb;CACF,CAAC,CAAC;AAEH,eAAe,SAAS,CAAC,UAAU,CAAC,CAAC"}
@@ -1,6 +1,6 @@
1
1
  import React from "react";
2
2
  import { StyleProp, ViewStyle, TextStyle } from "react-native";
3
- import type { ReadTheme } from "@draftbit/theme";
3
+ import type { Theme } from "../styles/DefaultTheme";
4
4
  import type { IconSlot } from "../interfaces/Icon";
5
5
  declare type Props = {
6
6
  min: number;
@@ -11,7 +11,9 @@ declare type Props = {
11
11
  iconSize: number;
12
12
  iconColor?: string;
13
13
  onChange?: (value: number) => void;
14
- theme: ReadTheme;
14
+ theme: Theme;
15
15
  } & IconSlot;
16
- declare const _default: React.ComponentType<Omit<Props, "theme">>;
16
+ declare const _default: React.ComponentType<import("@draftbit/react-theme-provider").$Without<Props, "theme"> & {
17
+ theme?: import("@draftbit/react-theme-provider").$DeepPartial<any> | undefined;
18
+ }> & import("@draftbit/react-theme-provider/typings/hoist-non-react-statics").NonReactStatics<React.ComponentType<Props> & React.FC<Props>, {}>;
17
19
  export default _default;
@@ -1,7 +1,7 @@
1
1
  import React, { useEffect, useState } from "react";
2
2
  import { View, Text } from "react-native";
3
3
  import { isNumber } from "lodash";
4
- import { withTheme } from "@draftbit/theme";
4
+ import { withTheme } from "../theming";
5
5
  import IconButton from "./IconButton";
6
6
  import { extractStyles } from "../utilities";
7
7
  const Stepper = ({ min = -Infinity, max = Infinity, value: valueProp, defaultValue, style, iconSize = 24, iconColor, onChange, theme: { colors, typography }, Icon, }) => {
@@ -27,12 +27,11 @@ const Stepper = ({ min = -Infinity, max = Infinity, value: valueProp, defaultVal
27
27
  return (React.createElement(View, { style: [{ flexDirection: "row" }, viewStyles] },
28
28
  React.createElement(IconButton, { Icon: Icon, icon: "MaterialIcons/remove", onPress: () => handlePlusOrMinus("minus"), size: iconSize, color: iconColor, disabled: value === min, style: { opacity: value === min ? 0.5 : 1 } }),
29
29
  React.createElement(Text, { style: [
30
- { color: colors.text.strong },
31
30
  typography.body1,
32
31
  {
33
32
  textAlign: "center",
34
33
  alignSelf: "center",
35
- color: colors.text.medium,
34
+ color: colors.medium,
36
35
  marginHorizontal: 8,
37
36
  },
38
37
  textStyles,
@@ -1 +1 @@
1
- {"version":3,"file":"Stepper.js","sourceRoot":"","sources":["../../../../src/components/Stepper.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAM,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACvD,OAAO,EAAE,IAAI,EAAE,IAAI,EAAmC,MAAM,cAAc,CAAC;AAC3E,OAAO,EAAE,QAAQ,EAAE,MAAM,QAAQ,CAAC;AAElC,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAG5C,OAAO,UAAU,MAAM,cAAc,CAAC;AACtC,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAc7C,MAAM,OAAO,GAAc,CAAC,EAC1B,GAAG,GAAG,CAAC,QAAQ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Prop, ViewStyle } from "react-native";
3
- import type { ReadTheme } from "@draftbit/theme";
3
+ import type { Theme } from "../styles/DefaultTheme";
4
4
  declare type Props = {
5
5
  elevation?: number;
6
6
  style?: StyleProp<ViewStyle>;
7
- theme: ReadTheme;
7
+ theme: Theme;
8
8
  } & ViewProps;
9
- declare const _default: React.ComponentType<Omit<React.PropsWithChildren<Props>, "theme">>;
9
+ declare const _default: React.ComponentType<import("@draftbit/react-theme-provider").$Without<React.PropsWithChildren<Props>, "theme"> & {
10
+ theme?: import("@draftbit/react-theme-provider").$DeepPartial<any> | undefined;
11
+ }> & import("@draftbit/react-theme-provider/typings/hoist-non-react-statics").NonReactStatics<React.ComponentType<React.PropsWithChildren<Props>> & React.FC<React.PropsWithChildren<Props>>, {}>;
10
12
  export default _default;
@@ -1,23 +1,30 @@
1
1
  /* Copied from https://github.com/callstack/react-native-paper/blob/main/src/components/Surface.tsx */
2
2
  import * as React from "react";
3
3
  import { Animated, StyleSheet, } from "react-native";
4
- import { withTheme } from "@draftbit/theme";
4
+ import shadow from "../styles/shadow";
5
+ import overlay from "../styles/overlay";
6
+ import { withTheme } from "../theming";
5
7
  const Surface = ({ elevation: propElevation, style, theme, children, ...rest }) => {
6
8
  const { elevation: styleElevation = 3, backgroundColor, ...restStyle } = (StyleSheet.flatten(style) || {});
7
- const { colors } = theme;
9
+ const { dark: isDarkTheme, mode, colors } = theme;
8
10
  const elevation = propElevation !== null && propElevation !== void 0 ? propElevation : styleElevation;
11
+ const evalationStyles = elevation ? shadow(elevation) : {};
9
12
  const getBackgroundColor = () => {
10
13
  if (backgroundColor) {
11
14
  return backgroundColor;
12
15
  }
16
+ else if (isDarkTheme && mode === "adaptive") {
17
+ return overlay(elevation, colors.surface);
18
+ }
13
19
  else {
14
- return colors.background.brand;
20
+ return colors.surface;
15
21
  }
16
22
  };
17
23
  return (React.createElement(Animated.View, { ...rest, style: [
18
24
  {
19
25
  backgroundColor: getBackgroundColor(),
20
26
  elevation,
27
+ ...evalationStyles,
21
28
  ...restStyle,
22
29
  },
23
30
  ] }, children));