@draftbit/core 46.4.4-d73221.2 → 46.4.4-dc4ec4.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 (729) hide show
  1. package/lib/commonjs/Provider.js +2 -10
  2. package/lib/commonjs/Provider.js.map +1 -0
  3. package/lib/commonjs/components/Accordion/AccordionGroup.js +2 -15
  4. package/lib/commonjs/components/Accordion/AccordionGroup.js.map +1 -0
  5. package/lib/commonjs/components/Accordion/AccordionItem.js +2 -14
  6. package/lib/commonjs/components/Accordion/AccordionItem.js.map +1 -0
  7. package/lib/commonjs/components/Accordion/index.js +2 -4
  8. package/lib/commonjs/components/Accordion/index.js.map +1 -0
  9. package/lib/commonjs/components/ActionSheet/ActionSheet.js +2 -10
  10. package/lib/commonjs/components/ActionSheet/ActionSheet.js.map +1 -0
  11. package/lib/commonjs/components/ActionSheet/ActionSheetCancel.js +2 -6
  12. package/lib/commonjs/components/ActionSheet/ActionSheetCancel.js.map +1 -0
  13. package/lib/commonjs/components/ActionSheet/ActionSheetItem.js +2 -8
  14. package/lib/commonjs/components/ActionSheet/ActionSheetItem.js.map +1 -0
  15. package/lib/commonjs/components/ActionSheet/index.js +2 -5
  16. package/lib/commonjs/components/ActionSheet/index.js.map +1 -0
  17. package/lib/commonjs/components/AnimatedCircularProgress.js +2 -16
  18. package/lib/commonjs/components/AnimatedCircularProgress.js.map +1 -0
  19. package/lib/commonjs/components/AspectRatio.js +2 -11
  20. package/lib/commonjs/components/AspectRatio.js.map +1 -0
  21. package/lib/commonjs/components/AvatarEdit.js +2 -13
  22. package/lib/commonjs/components/AvatarEdit.js.map +1 -0
  23. package/lib/commonjs/components/Banner.js +11 -24
  24. package/lib/commonjs/components/Banner.js.map +1 -0
  25. package/lib/commonjs/components/Button.js +4 -20
  26. package/lib/commonjs/components/Button.js.map +1 -0
  27. package/lib/commonjs/components/Card.js +2 -15
  28. package/lib/commonjs/components/Card.js.map +1 -0
  29. package/lib/commonjs/components/CardBlock.js +2 -16
  30. package/lib/commonjs/components/CardBlock.js.map +1 -0
  31. package/lib/commonjs/components/CardContainer.js +2 -19
  32. package/lib/commonjs/components/CardContainer.js.map +1 -0
  33. package/lib/commonjs/components/CardContainerRating.js +4 -21
  34. package/lib/commonjs/components/CardContainerRating.js.map +1 -0
  35. package/lib/commonjs/components/CardContainerShortImage.js +2 -13
  36. package/lib/commonjs/components/CardContainerShortImage.js.map +1 -0
  37. package/lib/commonjs/components/CardInline.js +3 -15
  38. package/lib/commonjs/components/CardInline.js.map +1 -0
  39. package/lib/commonjs/components/Carousel.js +5 -22
  40. package/lib/commonjs/components/Carousel.js.map +1 -0
  41. package/lib/commonjs/components/Checkbox/Checkbox.js +5 -19
  42. package/lib/commonjs/components/Checkbox/Checkbox.js.map +1 -0
  43. package/lib/commonjs/components/Checkbox/CheckboxGroup.js +2 -12
  44. package/lib/commonjs/components/Checkbox/CheckboxGroup.js.map +1 -0
  45. package/lib/commonjs/components/Checkbox/CheckboxGroupRow.js +2 -21
  46. package/lib/commonjs/components/Checkbox/CheckboxGroupRow.js.map +1 -0
  47. package/lib/commonjs/components/Checkbox/CheckboxRow.js +5 -25
  48. package/lib/commonjs/components/Checkbox/CheckboxRow.js.map +1 -0
  49. package/lib/commonjs/components/Checkbox/context.js +2 -6
  50. package/lib/commonjs/components/Checkbox/context.js.map +1 -0
  51. package/lib/commonjs/components/Checkbox/index.js +2 -5
  52. package/lib/commonjs/components/Checkbox/index.js.map +1 -0
  53. package/lib/commonjs/components/CircleImage.js +2 -10
  54. package/lib/commonjs/components/CircleImage.js.map +1 -0
  55. package/lib/commonjs/components/CircularProgress.js +5 -14
  56. package/lib/commonjs/components/CircularProgress.js.map +1 -0
  57. package/lib/commonjs/components/Config.js +7 -14
  58. package/lib/commonjs/components/Config.js.map +1 -0
  59. package/lib/commonjs/components/Container.js +2 -12
  60. package/lib/commonjs/components/Container.js.map +1 -0
  61. package/lib/commonjs/components/DatePicker/DatePicker.js +18 -49
  62. package/lib/commonjs/components/DatePicker/DatePicker.js.map +1 -0
  63. package/lib/commonjs/components/DatePicker/DatePickerComponent.js +2 -8
  64. package/lib/commonjs/components/DatePicker/DatePickerComponent.js.map +1 -0
  65. package/lib/commonjs/components/DatePicker/DatePickerComponent.web.js +2 -11
  66. package/lib/commonjs/components/DatePicker/DatePickerComponent.web.js.map +1 -0
  67. package/lib/commonjs/components/DatePicker/DatePickerComponentType.js +2 -1
  68. package/lib/commonjs/components/DatePicker/DatePickerComponentType.js.map +1 -0
  69. package/lib/commonjs/components/DeprecatedButton.js +2 -24
  70. package/lib/commonjs/components/DeprecatedButton.js.map +1 -0
  71. package/lib/commonjs/components/DeprecatedCardWrapper.js +2 -12
  72. package/lib/commonjs/components/DeprecatedCardWrapper.js.map +1 -0
  73. package/lib/commonjs/components/DeprecatedFAB.js +2 -27
  74. package/lib/commonjs/components/DeprecatedFAB.js.map +1 -0
  75. package/lib/commonjs/components/Divider.js +2 -10
  76. package/lib/commonjs/components/Divider.js.map +1 -0
  77. package/lib/commonjs/components/Elevation.js +2 -12
  78. package/lib/commonjs/components/Elevation.js.map +1 -0
  79. package/lib/commonjs/components/FAB.js +2 -11
  80. package/lib/commonjs/components/FAB.js.map +1 -0
  81. package/lib/commonjs/components/FieldSearchBarFull.js +2 -19
  82. package/lib/commonjs/components/FieldSearchBarFull.js.map +1 -0
  83. package/lib/commonjs/components/FormRow.js +2 -11
  84. package/lib/commonjs/components/FormRow.js.map +1 -0
  85. package/lib/commonjs/components/Header.js +2 -14
  86. package/lib/commonjs/components/Header.js.map +1 -0
  87. package/lib/commonjs/components/HeaderLarge.js +2 -10
  88. package/lib/commonjs/components/HeaderLarge.js.map +1 -0
  89. package/lib/commonjs/components/HeaderMedium.js +2 -10
  90. package/lib/commonjs/components/HeaderMedium.js.map +1 -0
  91. package/lib/commonjs/components/HeaderOverline.js +2 -10
  92. package/lib/commonjs/components/HeaderOverline.js.map +1 -0
  93. package/lib/commonjs/components/IconButton.js +2 -11
  94. package/lib/commonjs/components/IconButton.js.map +1 -0
  95. package/lib/commonjs/components/Image.js +2 -18
  96. package/lib/commonjs/components/Image.js.map +1 -0
  97. package/lib/commonjs/components/Justification.js +3 -3
  98. package/lib/commonjs/components/Justification.js.map +1 -0
  99. package/lib/commonjs/components/Layout.js +4 -13
  100. package/lib/commonjs/components/Layout.js.map +1 -0
  101. package/lib/commonjs/components/NumberInput.js +10 -22
  102. package/lib/commonjs/components/NumberInput.js.map +1 -0
  103. package/lib/commonjs/components/Picker/Picker.js +8 -40
  104. package/lib/commonjs/components/Picker/Picker.js.map +1 -0
  105. package/lib/commonjs/components/Picker/PickerComponent.android.js +8 -24
  106. package/lib/commonjs/components/Picker/PickerComponent.android.js.map +1 -0
  107. package/lib/commonjs/components/Picker/PickerComponent.ios.js +10 -28
  108. package/lib/commonjs/components/Picker/PickerComponent.ios.js.map +1 -0
  109. package/lib/commonjs/components/Picker/PickerComponent.web.js +8 -24
  110. package/lib/commonjs/components/Picker/PickerComponent.web.js.map +1 -0
  111. package/lib/commonjs/components/Picker/PickerTypes.js +2 -1
  112. package/lib/commonjs/components/Picker/PickerTypes.js.map +1 -0
  113. package/lib/commonjs/components/Portal/Portal.js +6 -15
  114. package/lib/commonjs/components/Portal/Portal.js.map +1 -0
  115. package/lib/commonjs/components/Portal/PortalConsumer.js +7 -16
  116. package/lib/commonjs/components/Portal/PortalConsumer.js.map +1 -0
  117. package/lib/commonjs/components/Portal/PortalHost.js +6 -32
  118. package/lib/commonjs/components/Portal/PortalHost.js.map +1 -0
  119. package/lib/commonjs/components/Portal/PortalManager.js +9 -20
  120. package/lib/commonjs/components/Portal/PortalManager.js.map +1 -0
  121. package/lib/commonjs/components/ProgressBar.js +7 -26
  122. package/lib/commonjs/components/ProgressBar.js.map +1 -0
  123. package/lib/commonjs/components/ProgressCircle.js +2 -11
  124. package/lib/commonjs/components/ProgressCircle.js.map +1 -0
  125. package/lib/commonjs/components/ProgressIndicator.js +2 -10
  126. package/lib/commonjs/components/ProgressIndicator.js.map +1 -0
  127. package/lib/commonjs/components/RadioButton/RadioButton.js +3 -15
  128. package/lib/commonjs/components/RadioButton/RadioButton.js.map +1 -0
  129. package/lib/commonjs/components/RadioButton/RadioButtonFieldGroup.js +2 -11
  130. package/lib/commonjs/components/RadioButton/RadioButtonFieldGroup.js.map +1 -0
  131. package/lib/commonjs/components/RadioButton/RadioButtonGroup.js +2 -15
  132. package/lib/commonjs/components/RadioButton/RadioButtonGroup.js.map +1 -0
  133. package/lib/commonjs/components/RadioButton/RadioButtonRow.js +3 -22
  134. package/lib/commonjs/components/RadioButton/RadioButtonRow.js.map +1 -0
  135. package/lib/commonjs/components/RadioButton/context.js +2 -6
  136. package/lib/commonjs/components/RadioButton/context.js.map +1 -0
  137. package/lib/commonjs/components/RadioButton/index.js +2 -6
  138. package/lib/commonjs/components/RadioButton/index.js.map +1 -0
  139. package/lib/commonjs/components/ResizeMode.js +3 -3
  140. package/lib/commonjs/components/ResizeMode.js.map +1 -0
  141. package/lib/commonjs/components/Row.js +2 -12
  142. package/lib/commonjs/components/Row.js.map +1 -0
  143. package/lib/commonjs/components/RowBodyIcon.js +2 -11
  144. package/lib/commonjs/components/RowBodyIcon.js.map +1 -0
  145. package/lib/commonjs/components/RowHeadlineImageCaption.js +4 -12
  146. package/lib/commonjs/components/RowHeadlineImageCaption.js.map +1 -0
  147. package/lib/commonjs/components/RowHeadlineImageIcon.js +2 -11
  148. package/lib/commonjs/components/RowHeadlineImageIcon.js.map +1 -0
  149. package/lib/commonjs/components/SVG.js +2 -10
  150. package/lib/commonjs/components/SVG.js.map +1 -0
  151. package/lib/commonjs/components/ScreenContainer.js +2 -15
  152. package/lib/commonjs/components/ScreenContainer.js.map +1 -0
  153. package/lib/commonjs/components/Slider.js +2 -22
  154. package/lib/commonjs/components/Slider.js.map +1 -0
  155. package/lib/commonjs/components/StarRating.js +2 -11
  156. package/lib/commonjs/components/StarRating.js.map +1 -0
  157. package/lib/commonjs/components/StepIndicator.js +7 -40
  158. package/lib/commonjs/components/StepIndicator.js.map +1 -0
  159. package/lib/commonjs/components/Stepper.js +6 -19
  160. package/lib/commonjs/components/Stepper.js.map +1 -0
  161. package/lib/commonjs/components/Surface.js +2 -15
  162. package/lib/commonjs/components/Surface.js.map +1 -0
  163. package/lib/commonjs/components/Swiper/Swiper.js +2 -9
  164. package/lib/commonjs/components/Swiper/Swiper.js.map +1 -0
  165. package/lib/commonjs/components/Swiper/SwiperItem.js +2 -7
  166. package/lib/commonjs/components/Swiper/SwiperItem.js.map +1 -0
  167. package/lib/commonjs/components/Swiper/index.js +2 -4
  168. package/lib/commonjs/components/Swiper/index.js.map +1 -0
  169. package/lib/commonjs/components/Switch.js +7 -19
  170. package/lib/commonjs/components/Switch.js.map +1 -0
  171. package/lib/commonjs/components/Text.js +10 -20
  172. package/lib/commonjs/components/Text.js.map +1 -0
  173. package/lib/commonjs/components/TextField.js +18 -63
  174. package/lib/commonjs/components/TextField.js.map +1 -0
  175. package/lib/commonjs/components/ToggleButton.js +2 -15
  176. package/lib/commonjs/components/ToggleButton.js.map +1 -0
  177. package/lib/commonjs/components/Touchable.js +18 -8
  178. package/lib/commonjs/components/Touchable.js.map +1 -0
  179. package/lib/commonjs/components/Touchable.web.js +2 -3
  180. package/lib/commonjs/components/Touchable.web.js.map +1 -0
  181. package/lib/commonjs/components/Typography.js +2 -6
  182. package/lib/commonjs/components/Typography.js.map +1 -0
  183. package/lib/commonjs/components/useAuthState.js +2 -10
  184. package/lib/commonjs/components/useAuthState.js.map +1 -0
  185. package/lib/commonjs/constants.js +2 -5
  186. package/lib/commonjs/constants.js.map +1 -0
  187. package/lib/commonjs/hooks.js +6 -8
  188. package/lib/commonjs/hooks.js.map +1 -0
  189. package/lib/commonjs/index.js +2 -53
  190. package/lib/commonjs/index.js.map +1 -0
  191. package/lib/commonjs/interfaces/Icon.js +5 -6
  192. package/lib/commonjs/interfaces/Icon.js.map +1 -0
  193. package/lib/commonjs/mappings/Accordion.js +2 -3
  194. package/lib/commonjs/mappings/Accordion.js.map +1 -0
  195. package/lib/commonjs/mappings/AccordionItem.js +2 -3
  196. package/lib/commonjs/mappings/AccordionItem.js.map +1 -0
  197. package/lib/commonjs/mappings/ActionSheet.js +2 -3
  198. package/lib/commonjs/mappings/ActionSheet.js.map +1 -0
  199. package/lib/commonjs/mappings/ActionSheetCancel.js +2 -3
  200. package/lib/commonjs/mappings/ActionSheetCancel.js.map +1 -0
  201. package/lib/commonjs/mappings/ActionSheetItem.js +2 -3
  202. package/lib/commonjs/mappings/ActionSheetItem.js.map +1 -0
  203. package/lib/commonjs/mappings/ActivityIndicator.js +2 -3
  204. package/lib/commonjs/mappings/ActivityIndicator.js.map +1 -0
  205. package/lib/commonjs/mappings/AudioPlayer.js +2 -3
  206. package/lib/commonjs/mappings/AudioPlayer.js.map +1 -0
  207. package/lib/commonjs/mappings/AvatarEdit.js +2 -3
  208. package/lib/commonjs/mappings/AvatarEdit.js.map +1 -0
  209. package/lib/commonjs/mappings/Banner.js +2 -3
  210. package/lib/commonjs/mappings/Banner.js.map +1 -0
  211. package/lib/commonjs/mappings/BlurView.js +2 -3
  212. package/lib/commonjs/mappings/BlurView.js.map +1 -0
  213. package/lib/commonjs/mappings/Button.js +8 -6
  214. package/lib/commonjs/mappings/Button.js.map +1 -0
  215. package/lib/commonjs/mappings/Card.js +5 -5
  216. package/lib/commonjs/mappings/Card.js.map +1 -0
  217. package/lib/commonjs/mappings/CardBlock.js +8 -6
  218. package/lib/commonjs/mappings/CardBlock.js.map +1 -0
  219. package/lib/commonjs/mappings/CardContainer.js +7 -8
  220. package/lib/commonjs/mappings/CardContainer.js.map +1 -0
  221. package/lib/commonjs/mappings/CardContainerRating.js +6 -5
  222. package/lib/commonjs/mappings/CardContainerRating.js.map +1 -0
  223. package/lib/commonjs/mappings/CardContainerShortImage.js +2 -3
  224. package/lib/commonjs/mappings/CardContainerShortImage.js.map +1 -0
  225. package/lib/commonjs/mappings/CardInline.js +2 -3
  226. package/lib/commonjs/mappings/CardInline.js.map +1 -0
  227. package/lib/commonjs/mappings/Carousel.js +2 -3
  228. package/lib/commonjs/mappings/Carousel.js.map +1 -0
  229. package/lib/commonjs/mappings/Checkbox.js +2 -3
  230. package/lib/commonjs/mappings/Checkbox.js.map +1 -0
  231. package/lib/commonjs/mappings/CheckboxGroup.js +2 -3
  232. package/lib/commonjs/mappings/CheckboxGroup.js.map +1 -0
  233. package/lib/commonjs/mappings/CheckboxRow.js +2 -3
  234. package/lib/commonjs/mappings/CheckboxRow.js.map +1 -0
  235. package/lib/commonjs/mappings/CircleImage.js +2 -3
  236. package/lib/commonjs/mappings/CircleImage.js.map +1 -0
  237. package/lib/commonjs/mappings/Container.js +2 -3
  238. package/lib/commonjs/mappings/Container.js.map +1 -0
  239. package/lib/commonjs/mappings/CustomCode.js +2 -3
  240. package/lib/commonjs/mappings/CustomCode.js.map +1 -0
  241. package/lib/commonjs/mappings/DatePicker.js +6 -5
  242. package/lib/commonjs/mappings/DatePicker.js.map +1 -0
  243. package/lib/commonjs/mappings/Divider.js +2 -3
  244. package/lib/commonjs/mappings/Divider.js.map +1 -0
  245. package/lib/commonjs/mappings/FAB.js +2 -3
  246. package/lib/commonjs/mappings/FAB.js.map +1 -0
  247. package/lib/commonjs/mappings/Fetch.js +2 -3
  248. package/lib/commonjs/mappings/Fetch.js.map +1 -0
  249. package/lib/commonjs/mappings/FieldSearchBarFull.js +4 -4
  250. package/lib/commonjs/mappings/FieldSearchBarFull.js.map +1 -0
  251. package/lib/commonjs/mappings/FlashList.js +2 -3
  252. package/lib/commonjs/mappings/FlashList.js.map +1 -0
  253. package/lib/commonjs/mappings/FlatList.js +2 -3
  254. package/lib/commonjs/mappings/FlatList.js.map +1 -0
  255. package/lib/commonjs/mappings/HeaderLarge.js +2 -3
  256. package/lib/commonjs/mappings/HeaderLarge.js.map +1 -0
  257. package/lib/commonjs/mappings/HeaderMedium.js +2 -3
  258. package/lib/commonjs/mappings/HeaderMedium.js.map +1 -0
  259. package/lib/commonjs/mappings/HeaderOverline.js +2 -3
  260. package/lib/commonjs/mappings/HeaderOverline.js.map +1 -0
  261. package/lib/commonjs/mappings/Icon.js +4 -4
  262. package/lib/commonjs/mappings/Icon.js.map +1 -0
  263. package/lib/commonjs/mappings/IconButton.js +2 -3
  264. package/lib/commonjs/mappings/IconButton.js.map +1 -0
  265. package/lib/commonjs/mappings/Image.js +2 -3
  266. package/lib/commonjs/mappings/Image.js.map +1 -0
  267. package/lib/commonjs/mappings/ImageBackground.js +2 -3
  268. package/lib/commonjs/mappings/ImageBackground.js.map +1 -0
  269. package/lib/commonjs/mappings/KeyboardAvoidingView.js +2 -3
  270. package/lib/commonjs/mappings/KeyboardAvoidingView.js.map +1 -0
  271. package/lib/commonjs/mappings/KeyboardAwareScrollView.js +2 -3
  272. package/lib/commonjs/mappings/KeyboardAwareScrollView.js.map +1 -0
  273. package/lib/commonjs/mappings/Layout.js +2 -3
  274. package/lib/commonjs/mappings/Layout.js.map +1 -0
  275. package/lib/commonjs/mappings/LinearGradient.js +2 -3
  276. package/lib/commonjs/mappings/LinearGradient.js.map +1 -0
  277. package/lib/commonjs/mappings/MapCallout.js +2 -3
  278. package/lib/commonjs/mappings/MapCallout.js.map +1 -0
  279. package/lib/commonjs/mappings/MapMarker.js +2 -3
  280. package/lib/commonjs/mappings/MapMarker.js.map +1 -0
  281. package/lib/commonjs/mappings/MapView.js +2 -3
  282. package/lib/commonjs/mappings/MapView.js.map +1 -0
  283. package/lib/commonjs/mappings/Modal.js +2 -3
  284. package/lib/commonjs/mappings/Modal.js.map +1 -0
  285. package/lib/commonjs/mappings/NumberInput.js +6 -5
  286. package/lib/commonjs/mappings/NumberInput.js.map +1 -0
  287. package/lib/commonjs/mappings/Picker.js +6 -5
  288. package/lib/commonjs/mappings/Picker.js.map +1 -0
  289. package/lib/commonjs/mappings/ProgressBar.js +2 -3
  290. package/lib/commonjs/mappings/ProgressBar.js.map +1 -0
  291. package/lib/commonjs/mappings/ProgressCircle.js +2 -3
  292. package/lib/commonjs/mappings/ProgressCircle.js.map +1 -0
  293. package/lib/commonjs/mappings/ProgressIndicator.js +2 -3
  294. package/lib/commonjs/mappings/ProgressIndicator.js.map +1 -0
  295. package/lib/commonjs/mappings/RadioButton.js +2 -3
  296. package/lib/commonjs/mappings/RadioButton.js.map +1 -0
  297. package/lib/commonjs/mappings/RadioButtonGroup.js +2 -3
  298. package/lib/commonjs/mappings/RadioButtonGroup.js.map +1 -0
  299. package/lib/commonjs/mappings/RadioButtonRow.js +2 -3
  300. package/lib/commonjs/mappings/RadioButtonRow.js.map +1 -0
  301. package/lib/commonjs/mappings/RowBodyIcon.js +2 -3
  302. package/lib/commonjs/mappings/RowBodyIcon.js.map +1 -0
  303. package/lib/commonjs/mappings/RowHeadlineImageCaption.js +2 -3
  304. package/lib/commonjs/mappings/RowHeadlineImageCaption.js.map +1 -0
  305. package/lib/commonjs/mappings/RowHeadlineImageIcon.js +14 -9
  306. package/lib/commonjs/mappings/RowHeadlineImageIcon.js.map +1 -0
  307. package/lib/commonjs/mappings/SVG.js +2 -3
  308. package/lib/commonjs/mappings/SVG.js.map +1 -0
  309. package/lib/commonjs/mappings/SafeAreaView.js +2 -3
  310. package/lib/commonjs/mappings/SafeAreaView.js.map +1 -0
  311. package/lib/commonjs/mappings/ScrollView.js +2 -3
  312. package/lib/commonjs/mappings/ScrollView.js.map +1 -0
  313. package/lib/commonjs/mappings/Slider.js +2 -3
  314. package/lib/commonjs/mappings/Slider.js.map +1 -0
  315. package/lib/commonjs/mappings/StarRating.js +3 -4
  316. package/lib/commonjs/mappings/StarRating.js.map +1 -0
  317. package/lib/commonjs/mappings/Stepper.js +2 -3
  318. package/lib/commonjs/mappings/Stepper.js.map +1 -0
  319. package/lib/commonjs/mappings/Surface.js +2 -3
  320. package/lib/commonjs/mappings/Surface.js.map +1 -0
  321. package/lib/commonjs/mappings/Swiper.js +2 -3
  322. package/lib/commonjs/mappings/Swiper.js.map +1 -0
  323. package/lib/commonjs/mappings/SwiperItem.js +2 -3
  324. package/lib/commonjs/mappings/SwiperItem.js.map +1 -0
  325. package/lib/commonjs/mappings/Switch.js +2 -3
  326. package/lib/commonjs/mappings/Switch.js.map +1 -0
  327. package/lib/commonjs/mappings/Text.js +7 -6
  328. package/lib/commonjs/mappings/Text.js.map +1 -0
  329. package/lib/commonjs/mappings/TextArea.js +4 -4
  330. package/lib/commonjs/mappings/TextArea.js.map +1 -0
  331. package/lib/commonjs/mappings/TextField.js +10 -10
  332. package/lib/commonjs/mappings/TextField.js.map +1 -0
  333. package/lib/commonjs/mappings/TextInput.js +5 -5
  334. package/lib/commonjs/mappings/TextInput.js.map +1 -0
  335. package/lib/commonjs/mappings/ToggleButton.js +2 -3
  336. package/lib/commonjs/mappings/ToggleButton.js.map +1 -0
  337. package/lib/commonjs/mappings/Touchable.js +2 -3
  338. package/lib/commonjs/mappings/Touchable.js.map +1 -0
  339. package/lib/commonjs/mappings/Video.js +2 -3
  340. package/lib/commonjs/mappings/Video.js.map +1 -0
  341. package/lib/commonjs/mappings/View.js +2 -3
  342. package/lib/commonjs/mappings/View.js.map +1 -0
  343. package/lib/commonjs/mappings/WebView.js +2 -3
  344. package/lib/commonjs/mappings/WebView.js.map +1 -0
  345. package/lib/commonjs/styles/DarkTheme.js +7 -7
  346. package/lib/commonjs/styles/DarkTheme.js.map +1 -0
  347. package/lib/commonjs/styles/DefaultTheme.js +28 -18
  348. package/lib/commonjs/styles/DefaultTheme.js.map +1 -0
  349. package/lib/commonjs/styles/fonts.js +5 -6
  350. package/lib/commonjs/styles/fonts.js.map +1 -0
  351. package/lib/commonjs/styles/overlay.js +7 -15
  352. package/lib/commonjs/styles/overlay.js.map +1 -0
  353. package/lib/commonjs/styles/shadow.js +2 -10
  354. package/lib/commonjs/styles/shadow.js.map +1 -0
  355. package/lib/commonjs/theming.js +2 -5
  356. package/lib/commonjs/theming.js.map +1 -0
  357. package/lib/commonjs/utilities.js +4 -15
  358. package/lib/commonjs/utilities.js.map +1 -0
  359. package/lib/module/Provider.js +2 -2
  360. package/lib/module/Provider.js.map +1 -0
  361. package/lib/module/components/Accordion/AccordionGroup.js +2 -5
  362. package/lib/module/components/Accordion/AccordionGroup.js.map +1 -0
  363. package/lib/module/components/Accordion/AccordionItem.js +2 -4
  364. package/lib/module/components/Accordion/AccordionItem.js.map +1 -0
  365. package/lib/module/components/Accordion/index.js +2 -1
  366. package/lib/module/components/Accordion/index.js.map +1 -0
  367. package/lib/module/components/ActionSheet/ActionSheet.js +2 -3
  368. package/lib/module/components/ActionSheet/ActionSheet.js.map +1 -0
  369. package/lib/module/components/ActionSheet/ActionSheetCancel.js +2 -3
  370. package/lib/module/components/ActionSheet/ActionSheetCancel.js.map +1 -0
  371. package/lib/module/components/ActionSheet/ActionSheetItem.js +2 -3
  372. package/lib/module/components/ActionSheet/ActionSheetItem.js.map +1 -0
  373. package/lib/module/components/ActionSheet/index.js +2 -1
  374. package/lib/module/components/ActionSheet/index.js.map +1 -0
  375. package/lib/module/components/AnimatedCircularProgress.js +2 -7
  376. package/lib/module/components/AnimatedCircularProgress.js.map +1 -0
  377. package/lib/module/components/AspectRatio.js +2 -7
  378. package/lib/module/components/AspectRatio.js.map +1 -0
  379. package/lib/module/components/AvatarEdit.js +2 -4
  380. package/lib/module/components/AvatarEdit.js.map +1 -0
  381. package/lib/module/components/Banner.js +14 -34
  382. package/lib/module/components/Banner.js.map +1 -0
  383. package/lib/module/components/Button.js +4 -11
  384. package/lib/module/components/Button.js.map +1 -0
  385. package/lib/module/components/Card.js +2 -3
  386. package/lib/module/components/Card.js.map +1 -0
  387. package/lib/module/components/CardBlock.js +2 -7
  388. package/lib/module/components/CardBlock.js.map +1 -0
  389. package/lib/module/components/CardContainer.js +2 -8
  390. package/lib/module/components/CardContainer.js.map +1 -0
  391. package/lib/module/components/CardContainerRating.js +4 -9
  392. package/lib/module/components/CardContainerRating.js.map +1 -0
  393. package/lib/module/components/CardContainerShortImage.js +2 -4
  394. package/lib/module/components/CardContainerShortImage.js.map +1 -0
  395. package/lib/module/components/CardInline.js +2 -3
  396. package/lib/module/components/CardInline.js.map +1 -0
  397. package/lib/module/components/Carousel.js +5 -10
  398. package/lib/module/components/Carousel.js.map +1 -0
  399. package/lib/module/components/Checkbox/Checkbox.js +5 -10
  400. package/lib/module/components/Checkbox/Checkbox.js.map +1 -0
  401. package/lib/module/components/Checkbox/CheckboxGroup.js +2 -6
  402. package/lib/module/components/Checkbox/CheckboxGroup.js.map +1 -0
  403. package/lib/module/components/Checkbox/CheckboxGroupRow.js +2 -9
  404. package/lib/module/components/Checkbox/CheckboxGroupRow.js.map +1 -0
  405. package/lib/module/components/Checkbox/CheckboxRow.js +5 -12
  406. package/lib/module/components/Checkbox/CheckboxRow.js.map +1 -0
  407. package/lib/module/components/Checkbox/context.js +2 -3
  408. package/lib/module/components/Checkbox/context.js.map +1 -0
  409. package/lib/module/components/Checkbox/index.js +2 -1
  410. package/lib/module/components/Checkbox/index.js.map +1 -0
  411. package/lib/module/components/CircleImage.js +2 -4
  412. package/lib/module/components/CircleImage.js.map +1 -0
  413. package/lib/module/components/CircularProgress.js +5 -10
  414. package/lib/module/components/CircularProgress.js.map +1 -0
  415. package/lib/module/components/Config.js +7 -12
  416. package/lib/module/components/Config.js.map +1 -0
  417. package/lib/module/components/Container.js +2 -4
  418. package/lib/module/components/Container.js.map +1 -0
  419. package/lib/module/components/DatePicker/DatePicker.js +25 -40
  420. package/lib/module/components/DatePicker/DatePicker.js.map +1 -0
  421. package/lib/module/components/DatePicker/DatePickerComponent.js +2 -3
  422. package/lib/module/components/DatePicker/DatePickerComponent.js.map +1 -0
  423. package/lib/module/components/DatePicker/DatePickerComponent.web.js +2 -3
  424. package/lib/module/components/DatePicker/DatePickerComponent.web.js.map +1 -0
  425. package/lib/module/components/DatePicker/DatePickerComponentType.js +2 -1
  426. package/lib/module/components/DatePicker/DatePickerComponentType.js.map +1 -0
  427. package/lib/module/components/DeprecatedButton.js +2 -10
  428. package/lib/module/components/DeprecatedButton.js.map +1 -0
  429. package/lib/module/components/DeprecatedCardWrapper.js +2 -7
  430. package/lib/module/components/DeprecatedCardWrapper.js.map +1 -0
  431. package/lib/module/components/DeprecatedFAB.js +2 -14
  432. package/lib/module/components/DeprecatedFAB.js.map +1 -0
  433. package/lib/module/components/Divider.js +2 -4
  434. package/lib/module/components/Divider.js.map +1 -0
  435. package/lib/module/components/Elevation.js +4 -17
  436. package/lib/module/components/Elevation.js.map +1 -0
  437. package/lib/module/components/FAB.js +2 -4
  438. package/lib/module/components/FAB.js.map +1 -0
  439. package/lib/module/components/FieldSearchBarFull.js +2 -10
  440. package/lib/module/components/FieldSearchBarFull.js.map +1 -0
  441. package/lib/module/components/FormRow.js +2 -2
  442. package/lib/module/components/FormRow.js.map +1 -0
  443. package/lib/module/components/Header.js +2 -3
  444. package/lib/module/components/Header.js.map +1 -0
  445. package/lib/module/components/HeaderLarge.js +2 -3
  446. package/lib/module/components/HeaderLarge.js.map +1 -0
  447. package/lib/module/components/HeaderMedium.js +2 -3
  448. package/lib/module/components/HeaderMedium.js.map +1 -0
  449. package/lib/module/components/HeaderOverline.js +2 -3
  450. package/lib/module/components/HeaderOverline.js.map +1 -0
  451. package/lib/module/components/IconButton.js +2 -4
  452. package/lib/module/components/IconButton.js.map +1 -0
  453. package/lib/module/components/Image.js +4 -28
  454. package/lib/module/components/Image.js.map +1 -0
  455. package/lib/module/components/Justification.js +2 -1
  456. package/lib/module/components/Justification.js.map +1 -0
  457. package/lib/module/components/Layout.js +6 -4
  458. package/lib/module/components/Layout.js.map +1 -0
  459. package/lib/module/components/NumberInput.js +10 -17
  460. package/lib/module/components/NumberInput.js.map +1 -0
  461. package/lib/module/components/Picker/Picker.js +8 -24
  462. package/lib/module/components/Picker/Picker.js.map +1 -0
  463. package/lib/module/components/Picker/PickerComponent.android.js +8 -11
  464. package/lib/module/components/Picker/PickerComponent.android.js.map +1 -0
  465. package/lib/module/components/Picker/PickerComponent.ios.js +10 -12
  466. package/lib/module/components/Picker/PickerComponent.ios.js.map +1 -0
  467. package/lib/module/components/Picker/PickerComponent.web.js +8 -11
  468. package/lib/module/components/Picker/PickerComponent.web.js.map +1 -0
  469. package/lib/module/components/Picker/PickerTypes.js +2 -1
  470. package/lib/module/components/Picker/PickerTypes.js.map +1 -0
  471. package/lib/module/components/Portal/Portal.js +6 -7
  472. package/lib/module/components/Portal/Portal.js.map +1 -0
  473. package/lib/module/components/Portal/PortalConsumer.js +7 -11
  474. package/lib/module/components/Portal/PortalConsumer.js.map +1 -0
  475. package/lib/module/components/Portal/PortalHost.js +6 -23
  476. package/lib/module/components/Portal/PortalHost.js.map +1 -0
  477. package/lib/module/components/Portal/PortalManager.js +9 -15
  478. package/lib/module/components/Portal/PortalManager.js.map +1 -0
  479. package/lib/module/components/ProgressBar.js +7 -18
  480. package/lib/module/components/ProgressBar.js.map +1 -0
  481. package/lib/module/components/ProgressCircle.js +2 -3
  482. package/lib/module/components/ProgressCircle.js.map +1 -0
  483. package/lib/module/components/ProgressIndicator.js +2 -3
  484. package/lib/module/components/ProgressIndicator.js.map +1 -0
  485. package/lib/module/components/RadioButton/RadioButton.js +3 -7
  486. package/lib/module/components/RadioButton/RadioButton.js.map +1 -0
  487. package/lib/module/components/RadioButton/RadioButtonFieldGroup.js +2 -4
  488. package/lib/module/components/RadioButton/RadioButtonFieldGroup.js.map +1 -0
  489. package/lib/module/components/RadioButton/RadioButtonGroup.js +2 -8
  490. package/lib/module/components/RadioButton/RadioButtonGroup.js.map +1 -0
  491. package/lib/module/components/RadioButton/RadioButtonRow.js +3 -10
  492. package/lib/module/components/RadioButton/RadioButtonRow.js.map +1 -0
  493. package/lib/module/components/RadioButton/context.js +2 -3
  494. package/lib/module/components/RadioButton/context.js.map +1 -0
  495. package/lib/module/components/RadioButton/index.js +2 -1
  496. package/lib/module/components/RadioButton/index.js.map +1 -0
  497. package/lib/module/components/ResizeMode.js +2 -1
  498. package/lib/module/components/ResizeMode.js.map +1 -0
  499. package/lib/module/components/Row.js +2 -3
  500. package/lib/module/components/Row.js.map +1 -0
  501. package/lib/module/components/RowBodyIcon.js +2 -3
  502. package/lib/module/components/RowBodyIcon.js.map +1 -0
  503. package/lib/module/components/RowHeadlineImageCaption.js +4 -4
  504. package/lib/module/components/RowHeadlineImageCaption.js.map +1 -0
  505. package/lib/module/components/RowHeadlineImageIcon.js +2 -3
  506. package/lib/module/components/RowHeadlineImageIcon.js.map +1 -0
  507. package/lib/module/components/SVG.js +2 -3
  508. package/lib/module/components/SVG.js.map +1 -0
  509. package/lib/module/components/ScreenContainer.js +2 -7
  510. package/lib/module/components/ScreenContainer.js.map +1 -0
  511. package/lib/module/components/Slider.js +2 -11
  512. package/lib/module/components/Slider.js.map +1 -0
  513. package/lib/module/components/StarRating.js +2 -4
  514. package/lib/module/components/StarRating.js.map +1 -0
  515. package/lib/module/components/StepIndicator.js +21 -61
  516. package/lib/module/components/StepIndicator.js.map +1 -0
  517. package/lib/module/components/Stepper.js +6 -10
  518. package/lib/module/components/Stepper.js.map +1 -0
  519. package/lib/module/components/Surface.js +2 -6
  520. package/lib/module/components/Surface.js.map +1 -0
  521. package/lib/module/components/Swiper/Swiper.js +2 -5
  522. package/lib/module/components/Swiper/Swiper.js.map +1 -0
  523. package/lib/module/components/Swiper/SwiperItem.js +2 -3
  524. package/lib/module/components/Swiper/SwiperItem.js.map +1 -0
  525. package/lib/module/components/Swiper/index.js +2 -1
  526. package/lib/module/components/Swiper/index.js.map +1 -0
  527. package/lib/module/components/Switch.js +7 -8
  528. package/lib/module/components/Switch.js.map +1 -0
  529. package/lib/module/components/Text.js +10 -12
  530. package/lib/module/components/Text.js.map +1 -0
  531. package/lib/module/components/TextField.js +18 -51
  532. package/lib/module/components/TextField.js.map +1 -0
  533. package/lib/module/components/ToggleButton.js +2 -6
  534. package/lib/module/components/ToggleButton.js.map +1 -0
  535. package/lib/module/components/Touchable.js +2 -2
  536. package/lib/module/components/Touchable.js.map +1 -0
  537. package/lib/module/components/Touchable.web.js +2 -1
  538. package/lib/module/components/Touchable.web.js.map +1 -0
  539. package/lib/module/components/Typography.js +2 -1
  540. package/lib/module/components/Typography.js.map +1 -0
  541. package/lib/module/components/useAuthState.js +2 -5
  542. package/lib/module/components/useAuthState.js.map +1 -0
  543. package/lib/module/constants.js +4 -2
  544. package/lib/module/constants.js.map +1 -0
  545. package/lib/module/hooks.js +6 -3
  546. package/lib/module/hooks.js.map +1 -0
  547. package/lib/module/index.js +5 -2
  548. package/lib/module/index.js.map +1 -0
  549. package/lib/module/interfaces/Icon.js +4 -2
  550. package/lib/module/interfaces/Icon.js.map +1 -0
  551. package/lib/module/mappings/Accordion.js +2 -1
  552. package/lib/module/mappings/Accordion.js.map +1 -0
  553. package/lib/module/mappings/AccordionItem.js +2 -1
  554. package/lib/module/mappings/AccordionItem.js.map +1 -0
  555. package/lib/module/mappings/ActionSheet.js +2 -1
  556. package/lib/module/mappings/ActionSheet.js.map +1 -0
  557. package/lib/module/mappings/ActionSheetCancel.js +2 -1
  558. package/lib/module/mappings/ActionSheetCancel.js.map +1 -0
  559. package/lib/module/mappings/ActionSheetItem.js +2 -1
  560. package/lib/module/mappings/ActionSheetItem.js.map +1 -0
  561. package/lib/module/mappings/ActivityIndicator.js +2 -1
  562. package/lib/module/mappings/ActivityIndicator.js.map +1 -0
  563. package/lib/module/mappings/AudioPlayer.js +2 -1
  564. package/lib/module/mappings/AudioPlayer.js.map +1 -0
  565. package/lib/module/mappings/AvatarEdit.js +2 -1
  566. package/lib/module/mappings/AvatarEdit.js.map +1 -0
  567. package/lib/module/mappings/Banner.js +2 -1
  568. package/lib/module/mappings/Banner.js.map +1 -0
  569. package/lib/module/mappings/BlurView.js +2 -1
  570. package/lib/module/mappings/BlurView.js.map +1 -0
  571. package/lib/module/mappings/Button.js +8 -4
  572. package/lib/module/mappings/Button.js.map +1 -0
  573. package/lib/module/mappings/Card.js +5 -3
  574. package/lib/module/mappings/Card.js.map +1 -0
  575. package/lib/module/mappings/CardBlock.js +8 -4
  576. package/lib/module/mappings/CardBlock.js.map +1 -0
  577. package/lib/module/mappings/CardContainer.js +7 -6
  578. package/lib/module/mappings/CardContainer.js.map +1 -0
  579. package/lib/module/mappings/CardContainerRating.js +6 -3
  580. package/lib/module/mappings/CardContainerRating.js.map +1 -0
  581. package/lib/module/mappings/CardContainerShortImage.js +2 -1
  582. package/lib/module/mappings/CardContainerShortImage.js.map +1 -0
  583. package/lib/module/mappings/CardInline.js +2 -1
  584. package/lib/module/mappings/CardInline.js.map +1 -0
  585. package/lib/module/mappings/Carousel.js +2 -1
  586. package/lib/module/mappings/Carousel.js.map +1 -0
  587. package/lib/module/mappings/Checkbox.js +2 -1
  588. package/lib/module/mappings/Checkbox.js.map +1 -0
  589. package/lib/module/mappings/CheckboxGroup.js +2 -1
  590. package/lib/module/mappings/CheckboxGroup.js.map +1 -0
  591. package/lib/module/mappings/CheckboxRow.js +2 -1
  592. package/lib/module/mappings/CheckboxRow.js.map +1 -0
  593. package/lib/module/mappings/CircleImage.js +2 -1
  594. package/lib/module/mappings/CircleImage.js.map +1 -0
  595. package/lib/module/mappings/Container.js +2 -1
  596. package/lib/module/mappings/Container.js.map +1 -0
  597. package/lib/module/mappings/CustomCode.js +2 -1
  598. package/lib/module/mappings/CustomCode.js.map +1 -0
  599. package/lib/module/mappings/DatePicker.js +6 -3
  600. package/lib/module/mappings/DatePicker.js.map +1 -0
  601. package/lib/module/mappings/Divider.js +2 -1
  602. package/lib/module/mappings/Divider.js.map +1 -0
  603. package/lib/module/mappings/FAB.js +2 -1
  604. package/lib/module/mappings/FAB.js.map +1 -0
  605. package/lib/module/mappings/Fetch.js +2 -2
  606. package/lib/module/mappings/Fetch.js.map +1 -0
  607. package/lib/module/mappings/FieldSearchBarFull.js +4 -2
  608. package/lib/module/mappings/FieldSearchBarFull.js.map +1 -0
  609. package/lib/module/mappings/FlashList.js +2 -1
  610. package/lib/module/mappings/FlashList.js.map +1 -0
  611. package/lib/module/mappings/FlatList.js +2 -1
  612. package/lib/module/mappings/FlatList.js.map +1 -0
  613. package/lib/module/mappings/HeaderLarge.js +2 -1
  614. package/lib/module/mappings/HeaderLarge.js.map +1 -0
  615. package/lib/module/mappings/HeaderMedium.js +2 -1
  616. package/lib/module/mappings/HeaderMedium.js.map +1 -0
  617. package/lib/module/mappings/HeaderOverline.js +2 -1
  618. package/lib/module/mappings/HeaderOverline.js.map +1 -0
  619. package/lib/module/mappings/Icon.js +4 -2
  620. package/lib/module/mappings/Icon.js.map +1 -0
  621. package/lib/module/mappings/IconButton.js +2 -1
  622. package/lib/module/mappings/IconButton.js.map +1 -0
  623. package/lib/module/mappings/Image.js +2 -1
  624. package/lib/module/mappings/Image.js.map +1 -0
  625. package/lib/module/mappings/ImageBackground.js +2 -1
  626. package/lib/module/mappings/ImageBackground.js.map +1 -0
  627. package/lib/module/mappings/KeyboardAvoidingView.js +2 -1
  628. package/lib/module/mappings/KeyboardAvoidingView.js.map +1 -0
  629. package/lib/module/mappings/KeyboardAwareScrollView.js +2 -1
  630. package/lib/module/mappings/KeyboardAwareScrollView.js.map +1 -0
  631. package/lib/module/mappings/Layout.js +2 -1
  632. package/lib/module/mappings/Layout.js.map +1 -0
  633. package/lib/module/mappings/LinearGradient.js +2 -1
  634. package/lib/module/mappings/LinearGradient.js.map +1 -0
  635. package/lib/module/mappings/MapCallout.js +2 -1
  636. package/lib/module/mappings/MapCallout.js.map +1 -0
  637. package/lib/module/mappings/MapMarker.js +2 -1
  638. package/lib/module/mappings/MapMarker.js.map +1 -0
  639. package/lib/module/mappings/MapView.js +2 -1
  640. package/lib/module/mappings/MapView.js.map +1 -0
  641. package/lib/module/mappings/Modal.js +2 -1
  642. package/lib/module/mappings/Modal.js.map +1 -0
  643. package/lib/module/mappings/NumberInput.js +6 -3
  644. package/lib/module/mappings/NumberInput.js.map +1 -0
  645. package/lib/module/mappings/Picker.js +6 -3
  646. package/lib/module/mappings/Picker.js.map +1 -0
  647. package/lib/module/mappings/ProgressBar.js +2 -1
  648. package/lib/module/mappings/ProgressBar.js.map +1 -0
  649. package/lib/module/mappings/ProgressCircle.js +2 -1
  650. package/lib/module/mappings/ProgressCircle.js.map +1 -0
  651. package/lib/module/mappings/ProgressIndicator.js +2 -1
  652. package/lib/module/mappings/ProgressIndicator.js.map +1 -0
  653. package/lib/module/mappings/RadioButton.js +2 -1
  654. package/lib/module/mappings/RadioButton.js.map +1 -0
  655. package/lib/module/mappings/RadioButtonGroup.js +2 -1
  656. package/lib/module/mappings/RadioButtonGroup.js.map +1 -0
  657. package/lib/module/mappings/RadioButtonRow.js +2 -1
  658. package/lib/module/mappings/RadioButtonRow.js.map +1 -0
  659. package/lib/module/mappings/RowBodyIcon.js +2 -1
  660. package/lib/module/mappings/RowBodyIcon.js.map +1 -0
  661. package/lib/module/mappings/RowHeadlineImageCaption.js +2 -1
  662. package/lib/module/mappings/RowHeadlineImageCaption.js.map +1 -0
  663. package/lib/module/mappings/RowHeadlineImageIcon.js +14 -7
  664. package/lib/module/mappings/RowHeadlineImageIcon.js.map +1 -0
  665. package/lib/module/mappings/SVG.js +2 -1
  666. package/lib/module/mappings/SVG.js.map +1 -0
  667. package/lib/module/mappings/SafeAreaView.js +2 -1
  668. package/lib/module/mappings/SafeAreaView.js.map +1 -0
  669. package/lib/module/mappings/ScrollView.js +2 -1
  670. package/lib/module/mappings/ScrollView.js.map +1 -0
  671. package/lib/module/mappings/Slider.js +2 -1
  672. package/lib/module/mappings/Slider.js.map +1 -0
  673. package/lib/module/mappings/StarRating.js +3 -2
  674. package/lib/module/mappings/StarRating.js.map +1 -0
  675. package/lib/module/mappings/Stepper.js +2 -1
  676. package/lib/module/mappings/Stepper.js.map +1 -0
  677. package/lib/module/mappings/Surface.js +2 -1
  678. package/lib/module/mappings/Surface.js.map +1 -0
  679. package/lib/module/mappings/Swiper.js +2 -1
  680. package/lib/module/mappings/Swiper.js.map +1 -0
  681. package/lib/module/mappings/SwiperItem.js +2 -1
  682. package/lib/module/mappings/SwiperItem.js.map +1 -0
  683. package/lib/module/mappings/Switch.js +2 -1
  684. package/lib/module/mappings/Switch.js.map +1 -0
  685. package/lib/module/mappings/Text.js +7 -4
  686. package/lib/module/mappings/Text.js.map +1 -0
  687. package/lib/module/mappings/TextArea.js +4 -2
  688. package/lib/module/mappings/TextArea.js.map +1 -0
  689. package/lib/module/mappings/TextField.js +10 -8
  690. package/lib/module/mappings/TextField.js.map +1 -0
  691. package/lib/module/mappings/TextInput.js +5 -3
  692. package/lib/module/mappings/TextInput.js.map +1 -0
  693. package/lib/module/mappings/ToggleButton.js +2 -1
  694. package/lib/module/mappings/ToggleButton.js.map +1 -0
  695. package/lib/module/mappings/Touchable.js +2 -1
  696. package/lib/module/mappings/Touchable.js.map +1 -0
  697. package/lib/module/mappings/Video.js +2 -1
  698. package/lib/module/mappings/Video.js.map +1 -0
  699. package/lib/module/mappings/View.js +2 -1
  700. package/lib/module/mappings/View.js.map +1 -0
  701. package/lib/module/mappings/WebView.js +2 -1
  702. package/lib/module/mappings/WebView.js.map +1 -0
  703. package/lib/module/styles/DarkTheme.js +6 -3
  704. package/lib/module/styles/DarkTheme.js.map +1 -0
  705. package/lib/module/styles/DefaultTheme.js +28 -14
  706. package/lib/module/styles/DefaultTheme.js.map +1 -0
  707. package/lib/module/styles/fonts.js +4 -2
  708. package/lib/module/styles/fonts.js.map +1 -0
  709. package/lib/module/styles/overlay.js +6 -11
  710. package/lib/module/styles/overlay.js.map +1 -0
  711. package/lib/module/styles/shadow.js +2 -7
  712. package/lib/module/styles/shadow.js.map +1 -0
  713. package/lib/module/theming.js +2 -1
  714. package/lib/module/theming.js.map +1 -0
  715. package/lib/module/utilities.js +4 -6
  716. package/lib/module/utilities.js.map +1 -0
  717. package/lib/typescript/src/components/Text.d.ts +2 -1
  718. package/lib/typescript/src/components/TextField.d.ts +2 -1
  719. package/lib/typescript/src/mappings/TextField.d.ts +2 -2
  720. package/lib/typescript/src/mappings/TextInput.d.ts +1 -1
  721. package/package.json +3 -3
  722. package/src/components/Text.js +8 -2
  723. package/src/components/Text.tsx +6 -1
  724. package/src/components/TextField.js +6 -1
  725. package/src/components/TextField.tsx +7 -1
  726. package/src/mappings/TextField.js +1 -1
  727. package/src/mappings/TextField.ts +1 -1
  728. package/src/mappings/TextInput.js +1 -1
  729. package/src/mappings/TextInput.ts +1 -1
@@ -4,28 +4,22 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = void 0;
7
-
8
7
  var React = _interopRequireWildcard(require("react"));
9
-
10
8
  var _reactNative = require("react-native");
11
-
12
9
  function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
13
-
14
10
  function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
15
-
16
- function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
17
-
11
+ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
12
+ function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
13
+ function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
18
14
  /**
19
15
  * Portal host is the component which actually renders all Portals.
20
16
  */
21
17
  class PortalManager extends React.PureComponent {
22
18
  constructor() {
23
19
  super(...arguments);
24
-
25
20
  _defineProperty(this, "state", {
26
21
  portals: []
27
22
  });
28
-
29
23
  _defineProperty(this, "mount", (key, children) => {
30
24
  this.setState(state => ({
31
25
  portals: [...state.portals, {
@@ -34,24 +28,21 @@ class PortalManager extends React.PureComponent {
34
28
  }]
35
29
  }));
36
30
  });
37
-
38
31
  _defineProperty(this, "update", (key, children) => this.setState(state => ({
39
32
  portals: state.portals.map(item => {
40
33
  if (item.key === key) {
41
- return { ...item,
34
+ return {
35
+ ...item,
42
36
  children
43
37
  };
44
38
  }
45
-
46
39
  return item;
47
40
  })
48
41
  })));
49
-
50
42
  _defineProperty(this, "unmount", key => this.setState(state => ({
51
43
  portals: state.portals.filter(item => item.key !== key)
52
44
  })));
53
45
  }
54
-
55
46
  render() {
56
47
  return this.state.portals.map(_ref => {
57
48
  let {
@@ -60,15 +51,13 @@ class PortalManager extends React.PureComponent {
60
51
  } = _ref;
61
52
  return /*#__PURE__*/React.createElement(_reactNative.View, {
62
53
  key: key,
63
- collapsable: false
64
- /* Need collapsable=false here to clip the elevations, otherwise they appear above sibling components */
65
- ,
54
+ collapsable: false /* Need collapsable=false here to clip the elevations, otherwise they appear above sibling components */,
55
+
66
56
  pointerEvents: "box-none",
67
57
  style: _reactNative.StyleSheet.absoluteFill
68
58
  }, children);
69
59
  });
70
60
  }
71
-
72
61
  }
73
-
74
- exports.default = PortalManager;
62
+ exports.default = PortalManager;
63
+ //# sourceMappingURL=PortalManager.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["PortalManager","React","PureComponent","portals","key","children","setState","state","map","item","filter","render","StyleSheet","absoluteFill"],"sources":["PortalManager.tsx"],"sourcesContent":["import * as React from \"react\";\nimport { View, StyleSheet } from \"react-native\";\n\ntype State = {\n portals: Array<{\n key: number;\n children: React.ReactNode;\n }>;\n};\n\n/**\n * Portal host is the component which actually renders all Portals.\n */\nexport default class PortalManager extends React.PureComponent<{}, State> {\n state: State = {\n portals: [],\n };\n\n mount = (key: number, children: React.ReactNode) => {\n this.setState((state) => ({\n portals: [...state.portals, { key, children }],\n }));\n };\n\n update = (key: number, children: React.ReactNode) =>\n this.setState((state) => ({\n portals: state.portals.map((item) => {\n if (item.key === key) {\n return { ...item, children };\n }\n return item;\n }),\n }));\n\n unmount = (key: number) =>\n this.setState((state) => ({\n portals: state.portals.filter((item) => item.key !== key),\n }));\n\n render() {\n return this.state.portals.map(({ key, children }) => (\n <View\n key={key}\n collapsable={\n false /* Need collapsable=false here to clip the elevations, otherwise they appear above sibling components */\n }\n pointerEvents=\"box-none\"\n style={StyleSheet.absoluteFill}\n >\n {children}\n </View>\n ));\n }\n}\n"],"mappings":";;;;;;AAAA;AACA;AAAgD;AAAA;AAAA;AAAA;AAAA;AAShD;AACA;AACA;AACe,MAAMA,aAAa,SAASC,KAAK,CAACC,aAAa,CAAY;EAAA;IAAA;IAAA,+BACzD;MACbC,OAAO,EAAE;IACX,CAAC;IAAA,+BAEO,CAACC,GAAW,EAAEC,QAAyB,KAAK;MAClD,IAAI,CAACC,QAAQ,CAAEC,KAAK,KAAM;QACxBJ,OAAO,EAAE,CAAC,GAAGI,KAAK,CAACJ,OAAO,EAAE;UAAEC,GAAG;UAAEC;QAAS,CAAC;MAC/C,CAAC,CAAC,CAAC;IACL,CAAC;IAAA,gCAEQ,CAACD,GAAW,EAAEC,QAAyB,KAC9C,IAAI,CAACC,QAAQ,CAAEC,KAAK,KAAM;MACxBJ,OAAO,EAAEI,KAAK,CAACJ,OAAO,CAACK,GAAG,CAAEC,IAAI,IAAK;QACnC,IAAIA,IAAI,CAACL,GAAG,KAAKA,GAAG,EAAE;UACpB,OAAO;YAAE,GAAGK,IAAI;YAAEJ;UAAS,CAAC;QAC9B;QACA,OAAOI,IAAI;MACb,CAAC;IACH,CAAC,CAAC,CAAC;IAAA,iCAEML,GAAW,IACpB,IAAI,CAACE,QAAQ,CAAEC,KAAK,KAAM;MACxBJ,OAAO,EAAEI,KAAK,CAACJ,OAAO,CAACO,MAAM,CAAED,IAAI,IAAKA,IAAI,CAACL,GAAG,KAAKA,GAAG;IAC1D,CAAC,CAAC,CAAC;EAAA;EAELO,MAAM,GAAG;IACP,OAAO,IAAI,CAACJ,KAAK,CAACJ,OAAO,CAACK,GAAG,CAAC;MAAA,IAAC;QAAEJ,GAAG;QAAEC;MAAS,CAAC;MAAA,oBAC9C,oBAAC,iBAAI;QACH,GAAG,EAAED,GAAI;QACT,WAAW,EACT,KAAK,CAAC,wGACP;;QACD,aAAa,EAAC,UAAU;QACxB,KAAK,EAAEQ,uBAAU,CAACC;MAAa,GAE9BR,QAAQ,CACJ;IAAA,CACR,CAAC;EACJ;AACF;AAAC"}
@@ -4,43 +4,33 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = void 0;
7
-
8
7
  var _react = _interopRequireWildcard(require("react"));
9
-
10
8
  var _reactNative = require("react-native");
11
-
12
9
  function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
13
-
14
10
  function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
15
-
16
11
  function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
17
-
18
- function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
19
-
12
+ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
13
+ function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
14
+ function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
20
15
  const INDETERMINATE_WIDTH_FACTOR = 0.3;
21
16
  const BAR_WIDTH_ZERO_POSITION = INDETERMINATE_WIDTH_FACTOR / (1 + INDETERMINATE_WIDTH_FACTOR);
22
-
23
17
  class ProgressBar extends _react.Component {
24
18
  constructor(props) {
25
19
  super(props);
26
-
27
20
  _defineProperty(this, "handleLayout", event => {
28
21
  const {
29
22
  width = 150,
30
23
  onLayout
31
24
  } = this.props;
32
-
33
25
  if (!width) {
34
26
  this.setState({
35
27
  width: event.nativeEvent.layout.width
36
28
  });
37
29
  }
38
-
39
30
  if (onLayout) {
40
31
  onLayout(event);
41
32
  }
42
33
  });
43
-
44
34
  const {
45
35
  progress: progressP = 0,
46
36
  indeterminate = false
@@ -52,17 +42,14 @@ class ProgressBar extends _react.Component {
52
42
  animationValue: new _reactNative.Animated.Value(BAR_WIDTH_ZERO_POSITION)
53
43
  };
54
44
  }
55
-
56
45
  componentDidMount() {
57
46
  const {
58
47
  indeterminate = false
59
48
  } = this.props;
60
-
61
49
  if (indeterminate) {
62
50
  this.animate();
63
51
  }
64
52
  }
65
-
66
53
  componentDidUpdate(prevProps) {
67
54
  const {
68
55
  indeterminate = false,
@@ -74,7 +61,6 @@ class ProgressBar extends _react.Component {
74
61
  },
75
62
  animated = true
76
63
  } = this.props;
77
-
78
64
  if (prevProps.indeterminate !== indeterminate) {
79
65
  if (indeterminate) {
80
66
  this.animate();
@@ -85,12 +71,11 @@ class ProgressBar extends _react.Component {
85
71
  }).start();
86
72
  }
87
73
  }
88
-
89
74
  if (prevProps.indeterminate !== indeterminate || prevProps.progress !== progressP) {
90
75
  const progress = this.props.indeterminate ? INDETERMINATE_WIDTH_FACTOR : Math.min(Math.max(progressP, 0), 1);
91
-
92
76
  if (animated) {
93
- _reactNative.Animated[animationType](this.state.progress, { ...animationConfig,
77
+ _reactNative.Animated[animationType](this.state.progress, {
78
+ ...animationConfig,
94
79
  toValue: progress,
95
80
  velocity: 0,
96
81
  //adjust this value if animation fails - velocity is required
@@ -101,14 +86,12 @@ class ProgressBar extends _react.Component {
101
86
  }
102
87
  }
103
88
  }
104
-
105
89
  animate() {
106
90
  const {
107
91
  useNativeDriver = false,
108
92
  indeterminateAnimationDuration = 1000
109
93
  } = this.props;
110
94
  this.state.animationValue.setValue(0);
111
-
112
95
  _reactNative.Animated.timing(this.state.animationValue, {
113
96
  toValue: 1,
114
97
  duration: indeterminateAnimationDuration,
@@ -121,7 +104,6 @@ class ProgressBar extends _react.Component {
121
104
  }
122
105
  });
123
106
  }
124
-
125
107
  render() {
126
108
  const {
127
109
  borderColor,
@@ -172,7 +154,6 @@ class ProgressBar extends _react.Component {
172
154
  style: progressStyle
173
155
  }), children);
174
156
  }
175
-
176
157
  }
177
-
178
- exports.default = ProgressBar;
158
+ exports.default = ProgressBar;
159
+ //# sourceMappingURL=ProgressBar.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["INDETERMINATE_WIDTH_FACTOR","BAR_WIDTH_ZERO_POSITION","ProgressBar","Component","constructor","props","event","width","onLayout","setState","nativeEvent","layout","progress","progressP","indeterminate","Math","min","max","state","Animated","Value","animationValue","componentDidMount","animate","componentDidUpdate","prevProps","useNativeDriver","animationType","animationConfig","bounciness","animated","spring","toValue","start","velocity","setValue","indeterminateAnimationDuration","timing","duration","easing","Easing","linear","isInteraction","endState","finished","render","borderColor","borderRadius","borderWidth","children","color","style","unfilledColor","restProps","innerWidth","containerStyle","overflow","backgroundColor","progressStyle","height","transform","translateX","interpolate","inputRange","outputRange","I18nManager","isRTL","scaleX","handleLayout"],"sources":["ProgressBar.tsx"],"sourcesContent":["import React, { Component } from \"react\";\nimport {\n Animated,\n Easing,\n View,\n I18nManager,\n ViewProps,\n StyleProp,\n ViewStyle,\n LayoutChangeEvent,\n} from \"react-native\";\n\nconst INDETERMINATE_WIDTH_FACTOR = 0.3;\nconst BAR_WIDTH_ZERO_POSITION =\n INDETERMINATE_WIDTH_FACTOR / (1 + INDETERMINATE_WIDTH_FACTOR);\n\ntype Props = {\n borderColor?: string;\n borderRadius?: number;\n borderWidth?: number;\n children?: React.ReactNode;\n color?: string;\n height?: number;\n style?: StyleProp<ViewStyle>;\n unfilledColor?: string;\n width?: number;\n animated?: boolean;\n indeterminate?: boolean;\n indeterminateAnimationDuration?: number;\n progress?: number;\n useNativeDriver?: boolean;\n animationConfig?: Animated.AnimationConfig;\n animationType?: \"decay\" | \"timing\" | \"spring\";\n} & ViewProps;\n\ninterface State {\n width: number;\n progress: Animated.Value;\n animationValue: Animated.Value;\n}\n\nexport default class ProgressBar extends Component<Props, State> {\n constructor(props: Props) {\n super(props);\n const { progress: progressP = 0, indeterminate = false } = props;\n const progress = Math.min(Math.max(progressP, 0), 1);\n this.state = {\n width: 0,\n progress: new Animated.Value(\n indeterminate ? INDETERMINATE_WIDTH_FACTOR : progress\n ),\n animationValue: new Animated.Value(BAR_WIDTH_ZERO_POSITION),\n };\n }\n\n componentDidMount() {\n const { indeterminate = false } = this.props;\n if (indeterminate) {\n this.animate();\n }\n }\n\n componentDidUpdate(prevProps: Props) {\n const {\n indeterminate = false,\n useNativeDriver = false,\n progress: progressP = 0,\n animationType = \"spring\",\n animationConfig = { bounciness: 0 },\n animated = true,\n } = this.props;\n\n if (prevProps.indeterminate !== indeterminate) {\n if (indeterminate) {\n this.animate();\n } else {\n Animated.spring(this.state.animationValue, {\n toValue: BAR_WIDTH_ZERO_POSITION,\n useNativeDriver,\n }).start();\n }\n }\n if (\n prevProps.indeterminate !== indeterminate ||\n prevProps.progress !== progressP\n ) {\n const progress = this.props.indeterminate\n ? INDETERMINATE_WIDTH_FACTOR\n : Math.min(Math.max(progressP, 0), 1);\n\n if (animated) {\n Animated[animationType](this.state.progress, {\n ...animationConfig,\n toValue: progress,\n velocity: 0, //adjust this value if animation fails - velocity is required\n useNativeDriver,\n }).start();\n } else {\n this.state.progress.setValue(progress);\n }\n }\n }\n\n handleLayout = (event: LayoutChangeEvent) => {\n const { width = 150, onLayout } = this.props;\n if (!width) {\n this.setState({ width: event.nativeEvent.layout.width });\n }\n if (onLayout) {\n onLayout(event);\n }\n };\n\n animate() {\n const { useNativeDriver = false, indeterminateAnimationDuration = 1000 } =\n this.props;\n this.state.animationValue.setValue(0);\n Animated.timing(this.state.animationValue, {\n toValue: 1,\n duration: indeterminateAnimationDuration,\n easing: Easing.linear,\n isInteraction: false,\n useNativeDriver,\n }).start((endState) => {\n if (endState.finished) {\n this.animate();\n }\n });\n }\n\n render() {\n const {\n borderColor,\n borderRadius = 4,\n borderWidth = 1,\n children,\n color = \"rgba(0, 122, 255, 1)\",\n style,\n unfilledColor,\n width = 150,\n ...restProps\n } = this.props;\n\n const innerWidth = Math.max(0, width || this.state.width) - borderWidth * 2;\n const containerStyle: StyleProp<ViewStyle> = {\n width,\n borderWidth,\n borderColor: borderColor || color,\n borderRadius,\n overflow: \"hidden\",\n backgroundColor: unfilledColor,\n };\n const progressStyle = {\n backgroundColor: color,\n // Always take up full height of container.\n height: \"100%\",\n transform: [\n {\n translateX: this.state.animationValue.interpolate({\n inputRange: [0, 1],\n outputRange: [innerWidth * -INDETERMINATE_WIDTH_FACTOR, innerWidth],\n }),\n },\n {\n translateX: this.state.progress.interpolate({\n inputRange: [0, 1],\n outputRange: [innerWidth / (I18nManager.isRTL ? 2 : -2), 0],\n }),\n },\n {\n // Interpolation a temp workaround for https://github.com/facebook/react-native/issues/6278\n scaleX: this.state.progress.interpolate({\n inputRange: [0, 1],\n outputRange: [0.0001, 1],\n }),\n },\n ],\n };\n\n return (\n <View\n style={[containerStyle, style]}\n onLayout={this.handleLayout}\n {...restProps}\n >\n <Animated.View style={progressStyle} />\n {children}\n </View>\n );\n }\n}\n"],"mappings":"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"}
@@ -4,21 +4,13 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = void 0;
7
-
8
7
  var React = _interopRequireWildcard(require("react"));
9
-
10
8
  var _reactNative = require("react-native");
11
-
12
9
  var _AnimatedCircularProgress = _interopRequireDefault(require("./AnimatedCircularProgress"));
13
-
14
10
  var _theming = require("../theming");
15
-
16
11
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
17
-
18
12
  function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
19
-
20
13
  function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
21
-
22
14
  const ProgressCircle = _ref => {
23
15
  let {
24
16
  progress = 0.5,
@@ -52,7 +44,6 @@ const ProgressCircle = _ref => {
52
44
  }, textStyle]
53
45
  }, Math.round(fill), "%") : null);
54
46
  };
55
-
56
47
  var _default = (0, _theming.withTheme)(ProgressCircle);
57
-
58
- exports.default = _default;
48
+ exports.default = _default;
49
+ //# sourceMappingURL=ProgressCircle.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["ProgressCircle","progress","style","color","size","showsText","unfilledColor","strokeCap","textStyle","thickness","theme","progressNum","Math","round","tintColor","colors","primary","backgroundColor","secondary","fill","fontSize","withTheme"],"sources":["ProgressCircle.tsx"],"sourcesContent":["import * as React from \"react\";\nimport { Text, StyleProp, ViewStyle, TextStyle } from \"react-native\";\nimport AnimatedCircularProgress from \"./AnimatedCircularProgress\";\nimport { withTheme } from \"../theming\";\nimport themeT from \"../styles/DefaultTheme\";\nimport { colorTypes } from \"@draftbit/types\";\n\ntype Props = {\n progress?: number;\n style?: StyleProp<ViewStyle>;\n color?: colorTypes;\n size?: number;\n showsText?: boolean;\n unfilledColor?: colorTypes;\n strokeCap?: \"butt\" | \"square\" | \"round\" | undefined;\n textStyle?: StyleProp<TextStyle>;\n thickness?: number;\n theme: typeof themeT;\n};\n\nconst ProgressCircle: React.FC<React.PropsWithChildren<Props>> = ({\n progress = 0.5,\n style,\n color = \"primary\",\n size = 100,\n showsText = true,\n unfilledColor,\n strokeCap = \"butt\",\n textStyle,\n thickness = 1,\n theme,\n}) => {\n const progressNum = Math.round(progress * 100);\n\n const tintColor = color || theme.colors.primary;\n const backgroundColor = unfilledColor || theme.colors.secondary;\n\n return (\n <AnimatedCircularProgress\n size={size}\n width={thickness}\n backgroundWidth={thickness}\n fill={progressNum}\n tintColor={tintColor}\n backgroundColor={backgroundColor}\n rotation={0}\n lineCap={strokeCap}\n style={style}\n >\n {/* @ts-ignore */}\n {(fill) =>\n showsText ? (\n <Text\n style={[{ fontSize: size * 0.275, color: tintColor }, textStyle]}\n >\n {Math.round(fill)}%\n </Text>\n ) : null\n }\n </AnimatedCircularProgress>\n );\n};\n\nexport default withTheme(ProgressCircle);\n"],"mappings":";;;;;;AAAA;AACA;AACA;AACA;AAAuC;AAAA;AAAA;AAiBvC,MAAMA,cAAwD,GAAG,QAW3D;EAAA,IAX4D;IAChEC,QAAQ,GAAG,GAAG;IACdC,KAAK;IACLC,KAAK,GAAG,SAAS;IACjBC,IAAI,GAAG,GAAG;IACVC,SAAS,GAAG,IAAI;IAChBC,aAAa;IACbC,SAAS,GAAG,MAAM;IAClBC,SAAS;IACTC,SAAS,GAAG,CAAC;IACbC;EACF,CAAC;EACC,MAAMC,WAAW,GAAGC,IAAI,CAACC,KAAK,CAACZ,QAAQ,GAAG,GAAG,CAAC;EAE9C,MAAMa,SAAS,GAAGX,KAAK,IAAIO,KAAK,CAACK,MAAM,CAACC,OAAO;EAC/C,MAAMC,eAAe,GAAGX,aAAa,IAAII,KAAK,CAACK,MAAM,CAACG,SAAS;EAE/D,oBACE,oBAAC,iCAAwB;IACvB,IAAI,EAAEd,IAAK;IACX,KAAK,EAAEK,SAAU;IACjB,eAAe,EAAEA,SAAU;IAC3B,IAAI,EAAEE,WAAY;IAClB,SAAS,EAAEG,SAAU;IACrB,eAAe,EAAEG,eAAgB;IACjC,QAAQ,EAAE,CAAE;IACZ,OAAO,EAAEV,SAAU;IACnB,KAAK,EAAEL;EAAM,GAGXiB,IAAI,IACJd,SAAS,gBACP,oBAAC,iBAAI;IACH,KAAK,EAAE,CAAC;MAAEe,QAAQ,EAAEhB,IAAI,GAAG,KAAK;MAAED,KAAK,EAAEW;IAAU,CAAC,EAAEN,SAAS;EAAE,GAEhEI,IAAI,CAACC,KAAK,CAACM,IAAI,CAAC,MACZ,GACL,IAAI,CAEe;AAE/B,CAAC;AAAC,eAEa,IAAAE,kBAAS,EAACrB,cAAc,CAAC;AAAA"}
@@ -4,19 +4,12 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = void 0;
7
-
8
7
  var React = _interopRequireWildcard(require("react"));
9
-
10
8
  var _StepIndicator = _interopRequireDefault(require("./StepIndicator"));
11
-
12
9
  var _theming = require("../theming");
13
-
14
10
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
15
-
16
11
  function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
17
-
18
12
  function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
19
-
20
13
  const ProgressIndicator = _ref => {
21
14
  let {
22
15
  numberOfSteps,
@@ -58,7 +51,6 @@ const ProgressIndicator = _ref => {
58
51
  }
59
52
  });
60
53
  };
61
-
62
54
  var _default = (0, _theming.withTheme)(ProgressIndicator);
63
-
64
- exports.default = _default;
55
+ exports.default = _default;
56
+ //# sourceMappingURL=ProgressIndicator.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["ProgressIndicator","numberOfSteps","currentStep","currentStepStrokeWidth","stepStrokeCurrentColor","stepIndicatorSize","currentStepIndicatorSize","stepIndicatorCurrentColor","stepIndicatorLabelCurrentColor","stepIndicatorLabelFontSize","stepNumberFinishedColor","stepNumberUnfinishedColor","unfinishedColor","finishedColor","theme","currentPosition","stepStrokeFinishedColor","stepStrokeUnFinishedColor","separatorFinishedColor","separatorUnFinishedColor","stepIndicatorFinishedColor","stepIndicatorUnFinishedColor","stepIndicatorLabelUnFinishedColor","stepIndicatorLabelFinishedColor","labelFontFamily","typography","body1","fontFamily","withTheme"],"sources":["ProgressIndicator.tsx"],"sourcesContent":["import * as React from \"react\";\nimport StepIndicator from \"./StepIndicator\";\nimport { withTheme } from \"../theming\";\nimport themeT from \"../styles/DefaultTheme\";\nimport { colorTypes } from \"@draftbit/types\";\n\ntype Props = {\n numberOfSteps: number;\n currentStep: number;\n currentStepStrokeWidth?: number;\n stepStrokeCurrentColor?: colorTypes;\n stepIndicatorSize?: number;\n currentStepIndicatorSize?: number;\n stepIndicatorCurrentColor?: colorTypes;\n stepIndicatorLabelCurrentColor?: colorTypes;\n stepIndicatorLabelFontSize?: number;\n stepNumberFinishedColor?: colorTypes;\n stepNumberUnfinishedColor?: colorTypes;\n unfinishedColor?: colorTypes;\n finishedColor?: colorTypes;\n theme: typeof themeT;\n};\n\nconst ProgressIndicator: React.FC<React.PropsWithChildren<Props>> = ({\n numberOfSteps,\n currentStep,\n currentStepStrokeWidth = 3,\n stepStrokeCurrentColor = \"primary\",\n stepIndicatorSize,\n currentStepIndicatorSize,\n stepIndicatorCurrentColor,\n stepIndicatorLabelCurrentColor,\n stepIndicatorLabelFontSize = 12,\n stepNumberFinishedColor = \"strongInverse\",\n stepNumberUnfinishedColor = \"primary\",\n unfinishedColor = \"light\",\n finishedColor = \"primary\",\n theme,\n}) => {\n const currentPosition = currentStep - 1;\n return (\n <StepIndicator\n stepCount={numberOfSteps}\n currentPosition={currentPosition}\n customStyles={{\n stepIndicatorSize,\n currentStepIndicatorSize: currentStepIndicatorSize\n ? currentStepIndicatorSize\n : stepIndicatorSize,\n stepStrokeFinishedColor: finishedColor,\n stepStrokeUnFinishedColor: unfinishedColor,\n separatorFinishedColor: finishedColor,\n separatorUnFinishedColor: unfinishedColor,\n stepIndicatorFinishedColor: finishedColor,\n stepIndicatorUnFinishedColor: unfinishedColor,\n currentStepStrokeWidth,\n stepStrokeCurrentColor:\n stepStrokeCurrentColor || stepIndicatorCurrentColor,\n stepIndicatorLabelUnFinishedColor: stepNumberUnfinishedColor,\n stepIndicatorLabelFinishedColor: stepNumberFinishedColor,\n stepIndicatorCurrentColor: stepIndicatorCurrentColor || unfinishedColor,\n stepIndicatorLabelCurrentColor:\n stepIndicatorLabelCurrentColor || stepNumberUnfinishedColor,\n stepIndicatorLabelFontSize,\n labelFontFamily: theme.typography.body1.fontFamily,\n }}\n />\n );\n};\n\nexport default withTheme(ProgressIndicator);\n"],"mappings":";;;;;;AAAA;AACA;AACA;AAAuC;AAAA;AAAA;AAqBvC,MAAMA,iBAA2D,GAAG,QAe9D;EAAA,IAf+D;IACnEC,aAAa;IACbC,WAAW;IACXC,sBAAsB,GAAG,CAAC;IAC1BC,sBAAsB,GAAG,SAAS;IAClCC,iBAAiB;IACjBC,wBAAwB;IACxBC,yBAAyB;IACzBC,8BAA8B;IAC9BC,0BAA0B,GAAG,EAAE;IAC/BC,uBAAuB,GAAG,eAAe;IACzCC,yBAAyB,GAAG,SAAS;IACrCC,eAAe,GAAG,OAAO;IACzBC,aAAa,GAAG,SAAS;IACzBC;EACF,CAAC;EACC,MAAMC,eAAe,GAAGb,WAAW,GAAG,CAAC;EACvC,oBACE,oBAAC,sBAAa;IACZ,SAAS,EAAED,aAAc;IACzB,eAAe,EAAEc,eAAgB;IACjC,YAAY,EAAE;MACZV,iBAAiB;MACjBC,wBAAwB,EAAEA,wBAAwB,GAC9CA,wBAAwB,GACxBD,iBAAiB;MACrBW,uBAAuB,EAAEH,aAAa;MACtCI,yBAAyB,EAAEL,eAAe;MAC1CM,sBAAsB,EAAEL,aAAa;MACrCM,wBAAwB,EAAEP,eAAe;MACzCQ,0BAA0B,EAAEP,aAAa;MACzCQ,4BAA4B,EAAET,eAAe;MAC7CT,sBAAsB;MACtBC,sBAAsB,EACpBA,sBAAsB,IAAIG,yBAAyB;MACrDe,iCAAiC,EAAEX,yBAAyB;MAC5DY,+BAA+B,EAAEb,uBAAuB;MACxDH,yBAAyB,EAAEA,yBAAyB,IAAIK,eAAe;MACvEJ,8BAA8B,EAC5BA,8BAA8B,IAAIG,yBAAyB;MAC7DF,0BAA0B;MAC1Be,eAAe,EAAEV,KAAK,CAACW,UAAU,CAACC,KAAK,CAACC;IAC1C;EAAE,EACF;AAEN,CAAC;AAAC,eAEa,IAAAC,kBAAS,EAAC5B,iBAAiB,CAAC;AAAA"}
@@ -4,25 +4,15 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = void 0;
7
-
8
7
  var React = _interopRequireWildcard(require("react"));
9
-
10
8
  var _Config = _interopRequireDefault(require("../Config"));
11
-
12
9
  var _IconButton = _interopRequireDefault(require("../IconButton"));
13
-
14
10
  var _utilities = require("../../utilities");
15
-
16
11
  var _context = require("./context");
17
-
18
12
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
19
-
20
13
  function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
21
-
22
14
  function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
23
-
24
15
  function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
25
-
26
16
  const RadioButton = _ref => {
27
17
  let {
28
18
  Icon,
@@ -44,13 +34,11 @@ const RadioButton = _ref => {
44
34
  } = (0, _context.useRadioButtonGroupContext)();
45
35
  const realValue = (0, _utilities.getValueForRadioButton)(value);
46
36
  const realContextValue = (0, _utilities.getValueForRadioButton)(contextValue);
47
- const isSelected = selected !== null && selected !== void 0 ? selected : realContextValue === realValue;
48
-
37
+ const isSelected = selected ?? realContextValue === realValue;
49
38
  const handlePress = () => {
50
39
  onPress === null || onPress === void 0 ? void 0 : onPress(realValue);
51
40
  onValueChange === null || onValueChange === void 0 ? void 0 : onValueChange(realValue);
52
41
  };
53
-
54
42
  return /*#__PURE__*/React.createElement(_IconButton.default, _extends({
55
43
  Icon: Icon,
56
44
  icon: isSelected ? selectedIcon : unselectedIcon,
@@ -61,6 +49,6 @@ const RadioButton = _ref => {
61
49
  style: style
62
50
  }, rest));
63
51
  };
64
-
65
52
  var _default = RadioButton;
66
- exports.default = _default;
53
+ exports.default = _default;
54
+ //# sourceMappingURL=RadioButton.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["RadioButton","Icon","disabled","color","value","selected","unselectedColor","onPress","size","Config","radioButtonSize","selectedIcon","unselectedIcon","style","rest","contextValue","onValueChange","useRadioButtonGroupContext","realValue","getValueForRadioButton","realContextValue","isSelected","handlePress"],"sources":["RadioButton.tsx"],"sourcesContent":["import * as React from \"react\";\nimport { StyleProp, ViewStyle } from \"react-native\";\n\nimport Config from \"../Config\";\nimport IconButton from \"../IconButton\";\nimport { getValueForRadioButton } from \"../../utilities\";\nimport { useRadioButtonGroupContext } from \"./context\";\n\nimport type { IconSlot } from \"../../interfaces/Icon\";\n\nexport type RadioButtonProps = {\n selected?: boolean;\n disabled?: boolean;\n color?: string;\n value?: string | number;\n unselectedColor?: string;\n onPress?: (value?: string) => void;\n style?: StyleProp<ViewStyle>;\n size?: number;\n selectedIcon?: string;\n unselectedIcon?: string;\n} & IconSlot;\n\nconst RadioButton: React.FC<RadioButtonProps> = ({\n Icon,\n disabled = false,\n color,\n value = \"\",\n selected,\n unselectedColor,\n onPress,\n size = Config.radioButtonSize,\n selectedIcon = \"MaterialIcons/radio-button-checked\",\n unselectedIcon = \"MaterialIcons/radio-button-unchecked\",\n style,\n ...rest\n}) => {\n const { value: contextValue, onValueChange } = useRadioButtonGroupContext();\n\n const realValue = getValueForRadioButton(value);\n const realContextValue = getValueForRadioButton(contextValue);\n const isSelected = selected ?? realContextValue === realValue;\n\n const handlePress = () => {\n onPress?.(realValue);\n onValueChange?.(realValue);\n };\n\n return (\n <IconButton\n Icon={Icon}\n icon={isSelected ? selectedIcon : unselectedIcon}\n color={isSelected ? color : unselectedColor}\n disabled={disabled}\n onPress={handlePress}\n size={size}\n style={style}\n {...rest}\n />\n );\n};\n\nexport default RadioButton;\n"],"mappings":";;;;;;AAAA;AAGA;AACA;AACA;AACA;AAAuD;AAAA;AAAA;AAAA;AAiBvD,MAAMA,WAAuC,GAAG,QAa1C;EAAA,IAb2C;IAC/CC,IAAI;IACJC,QAAQ,GAAG,KAAK;IAChBC,KAAK;IACLC,KAAK,GAAG,EAAE;IACVC,QAAQ;IACRC,eAAe;IACfC,OAAO;IACPC,IAAI,GAAGC,eAAM,CAACC,eAAe;IAC7BC,YAAY,GAAG,oCAAoC;IACnDC,cAAc,GAAG,sCAAsC;IACvDC,KAAK;IACL,GAAGC;EACL,CAAC;EACC,MAAM;IAAEV,KAAK,EAAEW,YAAY;IAAEC;EAAc,CAAC,GAAG,IAAAC,mCAA0B,GAAE;EAE3E,MAAMC,SAAS,GAAG,IAAAC,iCAAsB,EAACf,KAAK,CAAC;EAC/C,MAAMgB,gBAAgB,GAAG,IAAAD,iCAAsB,EAACJ,YAAY,CAAC;EAC7D,MAAMM,UAAU,GAAGhB,QAAQ,IAAIe,gBAAgB,KAAKF,SAAS;EAE7D,MAAMI,WAAW,GAAG,MAAM;IACxBf,OAAO,aAAPA,OAAO,uBAAPA,OAAO,CAAGW,SAAS,CAAC;IACpBF,aAAa,aAAbA,aAAa,uBAAbA,aAAa,CAAGE,SAAS,CAAC;EAC5B,CAAC;EAED,oBACE,oBAAC,mBAAU;IACT,IAAI,EAAEjB,IAAK;IACX,IAAI,EAAEoB,UAAU,GAAGV,YAAY,GAAGC,cAAe;IACjD,KAAK,EAAES,UAAU,GAAGlB,KAAK,GAAGG,eAAgB;IAC5C,QAAQ,EAAEJ,QAAS;IACnB,OAAO,EAAEoB,WAAY;IACrB,IAAI,EAAEd,IAAK;IACX,KAAK,EAAEK;EAAM,GACTC,IAAI,EACR;AAEN,CAAC;AAAC,eAEad,WAAW;AAAA"}
@@ -4,21 +4,13 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = void 0;
7
-
8
7
  var _react = _interopRequireDefault(require("react"));
9
-
10
8
  var _reactNative = require("react-native");
11
-
12
9
  var _Text = _interopRequireDefault(require("../Text"));
13
-
14
10
  var _theming = require("../../theming");
15
-
16
11
  var _RadioButtonGroup = _interopRequireDefault(require("./RadioButtonGroup"));
17
-
18
12
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
19
-
20
13
  function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
21
-
22
14
  const RadioButtonFieldGroup = _ref => {
23
15
  let {
24
16
  label,
@@ -39,7 +31,6 @@ const RadioButtonFieldGroup = _ref => {
39
31
  theme: theme
40
32
  }, rest), children));
41
33
  };
42
-
43
34
  var _default = (0, _theming.withTheme)(RadioButtonFieldGroup);
44
-
45
- exports.default = _default;
35
+ exports.default = _default;
36
+ //# sourceMappingURL=RadioButtonFieldGroup.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["RadioButtonFieldGroup","label","children","theme","labelStyle","style","rest","fontSize","typography","headline4","color","withTheme"],"sources":["RadioButtonFieldGroup.tsx"],"sourcesContent":["import React from \"react\";\nimport { View, StyleProp, TextStyle, ViewStyle } from \"react-native\";\nimport Text from \"../Text\";\nimport { withTheme } from \"../../theming\";\nimport RadioButtonGroup, { RadioButtonGroupProps } from \"./RadioButtonGroup\";\n\ninterface Props extends RadioButtonGroupProps {\n label?: string;\n labelStyle?: StyleProp<TextStyle>;\n style?: StyleProp<ViewStyle>;\n}\n\nconst RadioButtonFieldGroup: React.FC<React.PropsWithChildren<Props>> = ({\n label,\n children,\n theme,\n labelStyle,\n style,\n ...rest\n}) => {\n return (\n <View style={style}>\n <Text\n style={[\n {\n fontSize: theme.typography.headline4.fontSize,\n color: theme.typography.headline4.color,\n },\n labelStyle,\n ]}\n >\n {label}\n </Text>\n <RadioButtonGroup theme={theme} {...rest}>\n {children}\n </RadioButtonGroup>\n </View>\n );\n};\n\nexport default withTheme(RadioButtonFieldGroup);\n"],"mappings":";;;;;;AAAA;AACA;AACA;AACA;AACA;AAA6E;AAAA;AAQ7E,MAAMA,qBAA+D,GAAG,QAOlE;EAAA,IAPmE;IACvEC,KAAK;IACLC,QAAQ;IACRC,KAAK;IACLC,UAAU;IACVC,KAAK;IACL,GAAGC;EACL,CAAC;EACC,oBACE,6BAAC,iBAAI;IAAC,KAAK,EAAED;EAAM,gBACjB,6BAAC,aAAI;IACH,KAAK,EAAE,CACL;MACEE,QAAQ,EAAEJ,KAAK,CAACK,UAAU,CAACC,SAAS,CAACF,QAAQ;MAC7CG,KAAK,EAAEP,KAAK,CAACK,UAAU,CAACC,SAAS,CAACC;IACpC,CAAC,EACDN,UAAU;EACV,GAEDH,KAAK,CACD,eACP,6BAAC,yBAAgB;IAAC,KAAK,EAAEE;EAAM,GAAKG,IAAI,GACrCJ,QAAQ,CACQ,CACd;AAEX,CAAC;AAAC,eAEa,IAAAS,kBAAS,EAACX,qBAAqB,CAAC;AAAA"}
@@ -4,25 +4,16 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = void 0;
7
-
8
7
  var React = _interopRequireWildcard(require("react"));
9
-
10
8
  var _reactNative = require("react-native");
11
-
12
9
  var _utilities = require("../../utilities");
13
-
14
10
  var _context = require("./context");
15
-
16
11
  function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
17
-
18
12
  function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
19
-
20
13
  function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
21
-
22
14
  const {
23
15
  Provider
24
16
  } = _context.radioButtonGroupContext;
25
-
26
17
  const RadioButtonGroup = _ref => {
27
18
  let {
28
19
  direction = _context.Direction.Vertical,
@@ -46,23 +37,19 @@ const RadioButtonGroup = _ref => {
46
37
  setInternalValue(realDefaultValue);
47
38
  }
48
39
  }, [defaultValue]);
49
-
50
40
  const handleValueChange = newValue => {
51
41
  const realNewValue = (0, _utilities.getValueForRadioButton)(newValue);
52
42
  setInternalValue(realNewValue);
53
43
  onValueChange === null || onValueChange === void 0 ? void 0 : onValueChange(realNewValue);
54
44
  };
55
-
56
45
  const _containerStyle = [{
57
46
  flexDirection: direction === _context.Direction.Horizontal ? "row" : "column"
58
47
  }];
59
-
60
48
  if (direction !== _context.Direction.Vertical) {
61
49
  _containerStyle.push({
62
50
  alignItems: "center"
63
51
  });
64
52
  }
65
-
66
53
  return /*#__PURE__*/React.createElement(_reactNative.View, _extends({
67
54
  style: [{
68
55
  minHeight: 40
@@ -77,6 +64,6 @@ const RadioButtonGroup = _ref => {
77
64
  style: _containerStyle
78
65
  }, children)));
79
66
  };
80
-
81
67
  var _default = RadioButtonGroup;
82
- exports.default = _default;
68
+ exports.default = _default;
69
+ //# sourceMappingURL=RadioButtonGroup.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["Provider","radioButtonGroupContext","RadioButtonGroup","direction","Direction","Vertical","value","onValueChange","defaultValue","style","children","rest","internalValue","setInternalValue","React","useState","useEffect","realValue","getValueForRadioButton","realDefaultValue","handleValueChange","newValue","realNewValue","_containerStyle","flexDirection","Horizontal","push","alignItems","minHeight"],"sources":["RadioButtonGroup.tsx"],"sourcesContent":["import * as React from \"react\";\nimport { View, StyleProp, ViewStyle } from \"react-native\";\nimport type { Theme } from \"../../styles/DefaultTheme\";\nimport { getValueForRadioButton } from \"../../utilities\";\nimport { radioButtonGroupContext, Direction } from \"./context\";\nexport interface RadioButtonGroupProps {\n direction?: Direction;\n style?: StyleProp<ViewStyle>;\n value: string | number;\n onValueChange?: (value: string) => void;\n defaultValue?: string | number;\n theme: Theme;\n children: React.ReactNode;\n}\n\nconst { Provider } = radioButtonGroupContext;\n\nconst RadioButtonGroup: React.FC<RadioButtonGroupProps> = ({\n direction = Direction.Vertical,\n value = \"\",\n onValueChange,\n defaultValue,\n style,\n children,\n ...rest\n}) => {\n const [internalValue, setInternalValue] = React.useState(\"\");\n\n React.useEffect(() => {\n if (value != null) {\n const realValue = getValueForRadioButton(value);\n\n setInternalValue(realValue);\n }\n }, [value]);\n\n React.useEffect(() => {\n if (defaultValue != null) {\n const realDefaultValue = getValueForRadioButton(defaultValue);\n\n setInternalValue(realDefaultValue);\n }\n }, [defaultValue]);\n\n const handleValueChange = (newValue: string | number) => {\n const realNewValue = getValueForRadioButton(newValue);\n\n setInternalValue(realNewValue);\n onValueChange?.(realNewValue);\n };\n\n const _containerStyle: StyleProp<ViewStyle> = [\n {\n flexDirection: direction === Direction.Horizontal ? \"row\" : \"column\",\n },\n ];\n\n if (direction !== Direction.Vertical) {\n _containerStyle.push({\n alignItems: \"center\",\n });\n }\n\n return (\n <View style={[{ minHeight: 40 }, style]} {...rest}>\n <Provider\n value={{\n value: internalValue,\n onValueChange: handleValueChange,\n direction,\n }}\n >\n <View style={_containerStyle}>{children}</View>\n </Provider>\n </View>\n );\n};\n\nexport default RadioButtonGroup;\n"],"mappings":";;;;;;AAAA;AACA;AAEA;AACA;AAA+D;AAAA;AAAA;AAW/D,MAAM;EAAEA;AAAS,CAAC,GAAGC,gCAAuB;AAE5C,MAAMC,gBAAiD,GAAG,QAQpD;EAAA,IARqD;IACzDC,SAAS,GAAGC,kBAAS,CAACC,QAAQ;IAC9BC,KAAK,GAAG,EAAE;IACVC,aAAa;IACbC,YAAY;IACZC,KAAK;IACLC,QAAQ;IACR,GAAGC;EACL,CAAC;EACC,MAAM,CAACC,aAAa,EAAEC,gBAAgB,CAAC,GAAGC,KAAK,CAACC,QAAQ,CAAC,EAAE,CAAC;EAE5DD,KAAK,CAACE,SAAS,CAAC,MAAM;IACpB,IAAIV,KAAK,IAAI,IAAI,EAAE;MACjB,MAAMW,SAAS,GAAG,IAAAC,iCAAsB,EAACZ,KAAK,CAAC;MAE/CO,gBAAgB,CAACI,SAAS,CAAC;IAC7B;EACF,CAAC,EAAE,CAACX,KAAK,CAAC,CAAC;EAEXQ,KAAK,CAACE,SAAS,CAAC,MAAM;IACpB,IAAIR,YAAY,IAAI,IAAI,EAAE;MACxB,MAAMW,gBAAgB,GAAG,IAAAD,iCAAsB,EAACV,YAAY,CAAC;MAE7DK,gBAAgB,CAACM,gBAAgB,CAAC;IACpC;EACF,CAAC,EAAE,CAACX,YAAY,CAAC,CAAC;EAElB,MAAMY,iBAAiB,GAAIC,QAAyB,IAAK;IACvD,MAAMC,YAAY,GAAG,IAAAJ,iCAAsB,EAACG,QAAQ,CAAC;IAErDR,gBAAgB,CAACS,YAAY,CAAC;IAC9Bf,aAAa,aAAbA,aAAa,uBAAbA,aAAa,CAAGe,YAAY,CAAC;EAC/B,CAAC;EAED,MAAMC,eAAqC,GAAG,CAC5C;IACEC,aAAa,EAAErB,SAAS,KAAKC,kBAAS,CAACqB,UAAU,GAAG,KAAK,GAAG;EAC9D,CAAC,CACF;EAED,IAAItB,SAAS,KAAKC,kBAAS,CAACC,QAAQ,EAAE;IACpCkB,eAAe,CAACG,IAAI,CAAC;MACnBC,UAAU,EAAE;IACd,CAAC,CAAC;EACJ;EAEA,oBACE,oBAAC,iBAAI;IAAC,KAAK,EAAE,CAAC;MAAEC,SAAS,EAAE;IAAG,CAAC,EAAEnB,KAAK;EAAE,GAAKE,IAAI,gBAC/C,oBAAC,QAAQ;IACP,KAAK,EAAE;MACLL,KAAK,EAAEM,aAAa;MACpBL,aAAa,EAAEa,iBAAiB;MAChCjB;IACF;EAAE,gBAEF,oBAAC,iBAAI;IAAC,KAAK,EAAEoB;EAAgB,GAAEb,QAAQ,CAAQ,CACtC,CACN;AAEX,CAAC;AAAC,eAEaR,gBAAgB;AAAA"}
@@ -4,37 +4,23 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = exports.Direction = void 0;
7
-
8
7
  var React = _interopRequireWildcard(require("react"));
9
-
10
8
  var _reactNative = require("react-native");
11
-
12
9
  var _RadioButton = _interopRequireDefault(require("./RadioButton"));
13
-
14
10
  var _Text = _interopRequireDefault(require("../Text"));
15
-
16
11
  var _context = require("./context");
17
-
18
12
  var _Touchable = _interopRequireDefault(require("../Touchable"));
19
-
20
13
  var _utilities = require("../../utilities");
21
-
22
14
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
23
-
24
15
  function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
25
-
26
16
  function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
27
-
28
17
  function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
29
-
30
18
  let Direction;
31
19
  exports.Direction = Direction;
32
-
33
20
  (function (Direction) {
34
21
  Direction["Row"] = "row";
35
22
  Direction["RowReverse"] = "row-reverse";
36
23
  })(Direction || (exports.Direction = Direction = {}));
37
-
38
24
  const getRadioButtonAlignment = (parentDirection, direction) => {
39
25
  if (parentDirection === _context.Direction.Horizontal) {
40
26
  return direction === Direction.Row ? "flex-start" : "flex-end";
@@ -44,7 +30,6 @@ const getRadioButtonAlignment = (parentDirection, direction) => {
44
30
  return "flex-end";
45
31
  }
46
32
  };
47
-
48
33
  const renderLabel = (value, labelStyle, textStyle) => {
49
34
  if (typeof value === "string") {
50
35
  return /*#__PURE__*/React.createElement(_Text.default, {
@@ -54,7 +39,6 @@ const renderLabel = (value, labelStyle, textStyle) => {
54
39
  return /*#__PURE__*/React.createElement(React.Fragment, null, value);
55
40
  }
56
41
  };
57
-
58
42
  const RadioButtonRow = _ref => {
59
43
  let {
60
44
  Icon,
@@ -79,13 +63,11 @@ const RadioButtonRow = _ref => {
79
63
  } = (0, _context.useRadioButtonGroupContext)();
80
64
  const realValue = (0, _utilities.getValueForRadioButton)(value);
81
65
  const realContextValue = (0, _utilities.getValueForRadioButton)(contextValue);
82
- const isSelected = selected !== null && selected !== void 0 ? selected : realContextValue === realValue;
83
-
66
+ const isSelected = selected ?? realContextValue === realValue;
84
67
  const handlePress = () => {
85
68
  onPress === null || onPress === void 0 ? void 0 : onPress(realValue);
86
69
  onValueChange === null || onValueChange === void 0 ? void 0 : onValueChange(realValue);
87
70
  };
88
-
89
71
  const {
90
72
  textStyles,
91
73
  viewStyles
@@ -114,7 +96,6 @@ const RadioButtonRow = _ref => {
114
96
  style: radioButtonStyle
115
97
  })));
116
98
  };
117
-
118
99
  const styles = _reactNative.StyleSheet.create({
119
100
  mainParent: {
120
101
  alignItems: "center",
@@ -134,6 +115,6 @@ const styles = _reactNative.StyleSheet.create({
134
115
  flex: 3
135
116
  }
136
117
  });
137
-
138
118
  var _default = RadioButtonRow;
139
- exports.default = _default;
119
+ exports.default = _default;
120
+ //# sourceMappingURL=RadioButtonRow.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["Direction","getRadioButtonAlignment","parentDirection","direction","GroupDirection","Horizontal","Row","RowReverse","renderLabel","value","labelStyle","textStyle","RadioButtonRow","Icon","label","color","unselectedColor","onPress","labelContainerStyle","radioButtonStyle","selected","disabled","style","rest","contextValue","onValueChange","useRadioButtonGroupContext","realValue","getValueForRadioButton","realContextValue","isSelected","handlePress","textStyles","viewStyles","extractStyles","styles","mainParent","flexDirection","alignItems","flex","StyleSheet","create","justifyContent","paddingStart","minHeight","paddingEnd","display","Platform","select","web","cursor","userSelect"],"sources":["RadioButtonRow.tsx"],"sourcesContent":["import * as React from \"react\";\nimport {\n StyleProp,\n ViewStyle,\n StyleSheet,\n TextStyle,\n View,\n Platform,\n} from \"react-native\";\nimport RadioButton, { RadioButtonProps } from \"./RadioButton\";\nimport Text from \"../Text\";\nimport { useRadioButtonGroupContext } from \"./context\";\nimport type { IconSlot } from \"../../interfaces/Icon\";\nimport { Direction as GroupDirection } from \"./context\";\nimport Touchable from \"../Touchable\";\nimport { extractStyles, getValueForRadioButton } from \"../../utilities\";\n\nexport enum Direction {\n Row = \"row\",\n RowReverse = \"row-reverse\",\n}\n\nexport interface RadioButtonRowProps extends Omit<RadioButtonProps, \"onPress\"> {\n label: string | React.ReactNode;\n value: string | number; // A string (or number that will be parsed String(number)) that this radio button row represents when selected\n color?: string;\n unselectedColor?: string;\n labelContainerStyle: StyleProp<ViewStyle>;\n radioButtonStyle?: StyleProp<ViewStyle>;\n labelStyle?: StyleProp<TextStyle>;\n onPress?: (value: string) => void;\n direction?: Direction;\n}\n\nconst getRadioButtonAlignment = (\n parentDirection: GroupDirection | undefined,\n direction: Direction\n) => {\n if (parentDirection === GroupDirection.Horizontal) {\n return direction === Direction.Row ? \"flex-start\" : \"flex-end\";\n } else if (direction === Direction.RowReverse) {\n return \"flex-start\";\n } else {\n return \"flex-end\";\n }\n};\n\nconst renderLabel = (\n value: string | React.ReactNode,\n labelStyle: StyleProp<TextStyle>,\n textStyle: StyleProp<TextStyle>\n) => {\n if (typeof value === \"string\") {\n return <Text style={[labelStyle, textStyle]}>{value}</Text>;\n } else {\n return <>{value}</>;\n }\n};\n\nconst RadioButtonRow: React.FC<RadioButtonRowProps & IconSlot> = ({\n Icon,\n label,\n value = \"\",\n color,\n unselectedColor,\n onPress,\n labelContainerStyle,\n labelStyle,\n radioButtonStyle,\n direction = Direction.Row,\n selected,\n disabled,\n style,\n ...rest\n}) => {\n const {\n value: contextValue,\n onValueChange,\n direction: parentDirection,\n } = useRadioButtonGroupContext();\n\n const realValue = getValueForRadioButton(value);\n const realContextValue = getValueForRadioButton(contextValue);\n const isSelected = selected ?? realContextValue === realValue;\n\n const handlePress = () => {\n onPress?.(realValue);\n onValueChange?.(realValue);\n };\n\n const { textStyles, viewStyles } = extractStyles(style);\n\n return (\n <Touchable\n onPress={handlePress}\n style={[styles.mainParent, { flexDirection: direction }, viewStyles]}\n disabled={disabled}\n {...rest}\n >\n <View\n style={[\n styles.label,\n {\n alignItems: direction === Direction.Row ? \"flex-start\" : \"flex-end\",\n },\n labelContainerStyle,\n ]}\n >\n {renderLabel(label, labelStyle, textStyles)}\n </View>\n <View\n style={{\n flex: 1,\n alignItems: getRadioButtonAlignment(parentDirection, direction),\n }}\n >\n <RadioButton\n Icon={Icon}\n selected={isSelected}\n value={realValue}\n color={color}\n unselectedColor={unselectedColor}\n style={radioButtonStyle}\n />\n </View>\n </Touchable>\n );\n};\n\nconst styles = StyleSheet.create({\n mainParent: {\n alignItems: \"center\",\n justifyContent: \"space-around\",\n paddingStart: 20,\n minHeight: 50,\n paddingEnd: 20,\n display: \"flex\",\n ...Platform.select({\n web: {\n cursor: \"pointer\",\n userSelect: \"none\",\n },\n }),\n },\n label: {\n flex: 3,\n },\n});\n\nexport default RadioButtonRow;\n"],"mappings":"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"}
@@ -5,24 +5,20 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.radioButtonGroupContext = exports.Direction = void 0;
7
7
  exports.useRadioButtonGroupContext = useRadioButtonGroupContext;
8
-
9
8
  var _react = require("react");
10
-
11
9
  let Direction;
12
10
  exports.Direction = Direction;
13
-
14
11
  (function (Direction) {
15
12
  Direction["Horizontal"] = "horizontal";
16
13
  Direction["Vertical"] = "vertical";
17
14
  })(Direction || (exports.Direction = Direction = {}));
18
-
19
15
  const radioButtonGroupContext = /*#__PURE__*/(0, _react.createContext)({
20
16
  onValueChange: () => {},
21
17
  value: "",
22
18
  direction: undefined
23
19
  });
24
20
  exports.radioButtonGroupContext = radioButtonGroupContext;
25
-
26
21
  function useRadioButtonGroupContext() {
27
22
  return (0, _react.useContext)(radioButtonGroupContext);
28
- }
23
+ }
24
+ //# sourceMappingURL=context.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["Direction","radioButtonGroupContext","createContext","onValueChange","value","direction","undefined","useRadioButtonGroupContext","useContext"],"sources":["context.tsx"],"sourcesContent":["import { createContext, useContext } from \"react\";\n\nexport enum Direction {\n Horizontal = \"horizontal\",\n Vertical = \"vertical\",\n}\ninterface RadioButtonGroupContext {\n onValueChange: (value: string) => void;\n value: string;\n direction?: Direction;\n}\n\nexport const radioButtonGroupContext = createContext<RadioButtonGroupContext>({\n onValueChange: () => {},\n value: \"\",\n direction: undefined,\n});\n\nexport function useRadioButtonGroupContext() {\n return useContext(radioButtonGroupContext);\n}\n"],"mappings":";;;;;;;AAAA;AAAkD,IAEtCA,SAAS;AAAA;AAAA,WAATA,SAAS;EAATA,SAAS;EAATA,SAAS;AAAA,GAATA,SAAS,yBAATA,SAAS;AAUd,MAAMC,uBAAuB,gBAAG,IAAAC,oBAAa,EAA0B;EAC5EC,aAAa,EAAE,MAAM,CAAC,CAAC;EACvBC,KAAK,EAAE,EAAE;EACTC,SAAS,EAAEC;AACb,CAAC,CAAC;AAAC;AAEI,SAASC,0BAA0B,GAAG;EAC3C,OAAO,IAAAC,iBAAU,EAACP,uBAAuB,CAAC;AAC5C"}