@draftbit/core 46.4.4-d93fe1.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 (752) 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 +6 -28
  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 +11 -46
  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 -67
  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 +11 -11
  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 +18 -34
  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 +2 -4
  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 +2 -11
  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 +7 -30
  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 +4 -22
  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 -3
  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/index.d.ts +0 -1
  720. package/lib/typescript/src/mappings/TextField.d.ts +2 -2
  721. package/lib/typescript/src/mappings/TextInput.d.ts +1 -1
  722. package/package.json +4 -6
  723. package/src/components/Text.js +8 -2
  724. package/src/components/Text.tsx +6 -1
  725. package/src/components/TextField.js +6 -1
  726. package/src/components/TextField.tsx +7 -1
  727. package/src/index.js +0 -1
  728. package/src/index.tsx +0 -1
  729. package/src/mappings/TextField.js +1 -1
  730. package/src/mappings/TextField.ts +1 -1
  731. package/src/mappings/TextInput.js +1 -1
  732. package/src/mappings/TextInput.ts +1 -1
  733. package/lib/commonjs/components/TabView/TabView.js +0 -102
  734. package/lib/commonjs/components/TabView/TabViewItem.js +0 -26
  735. package/lib/commonjs/components/TabView/index.js +0 -23
  736. package/lib/commonjs/mappings/TabView.js +0 -79
  737. package/lib/module/components/TabView/TabView.js +0 -87
  738. package/lib/module/components/TabView/TabViewItem.js +0 -18
  739. package/lib/module/components/TabView/index.js +0 -2
  740. package/lib/module/mappings/TabView.js +0 -70
  741. package/lib/typescript/src/components/TabView/TabView.d.ts +0 -19
  742. package/lib/typescript/src/components/TabView/TabViewItem.d.ts +0 -10
  743. package/lib/typescript/src/components/TabView/index.d.ts +0 -2
  744. package/lib/typescript/src/mappings/TabView.d.ts +0 -111
  745. package/src/components/TabView/TabView.js +0 -34
  746. package/src/components/TabView/TabView.tsx +0 -97
  747. package/src/components/TabView/TabViewItem.js +0 -5
  748. package/src/components/TabView/TabViewItem.tsx +0 -21
  749. package/src/components/TabView/index.js +0 -2
  750. package/src/components/TabView/index.tsx +0 -2
  751. package/src/mappings/TabView.js +0 -73
  752. package/src/mappings/TabView.ts +0 -80
@@ -1,38 +1,34 @@
1
- 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; }
2
-
1
+ 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; }
2
+ function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
3
+ 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); }
3
4
  import * as React from "react";
4
5
  export default class PortalConsumer extends React.Component {
5
6
  constructor() {
6
7
  super(...arguments);
7
-
8
8
  _defineProperty(this, "key", void 0);
9
9
  }
10
-
11
10
  async componentDidMount() {
12
- this.checkManager(); // Delay updating to prevent React from going to infinite loop
11
+ this.checkManager();
13
12
 
13
+ // Delay updating to prevent React from going to infinite loop
14
14
  await Promise.resolve();
15
15
  this.key = this.props.manager.mount(this.props.children);
16
16
  }
17
-
18
17
  componentDidUpdate() {
19
18
  this.checkManager();
20
19
  this.props.manager.update(this.key, this.props.children);
21
20
  }
22
-
23
21
  componentWillUnmount() {
24
22
  this.checkManager();
25
23
  this.props.manager.unmount(this.key);
26
24
  }
27
-
28
25
  checkManager() {
29
26
  if (!this.props.manager) {
30
27
  throw new Error("Looks like you forgot to wrap your root component with `Provider` component from `react-native-paper`.\n\n" + "Please read our getting-started guide and make sure you've followed all the required steps.\n\n" + "https://callstack.github.io/react-native-paper/getting-started.html");
31
28
  }
32
29
  }
33
-
34
30
  render() {
35
31
  return null;
36
32
  }
37
-
38
- }
33
+ }
34
+ //# sourceMappingURL=PortalConsumer.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["React","PortalConsumer","Component","componentDidMount","checkManager","Promise","resolve","key","props","manager","mount","children","componentDidUpdate","update","componentWillUnmount","unmount","Error","render"],"sources":["PortalConsumer.tsx"],"sourcesContent":["import * as React from \"react\";\nimport { PortalMethods } from \"./PortalHost\";\n\ntype Props = {\n manager: PortalMethods;\n children: React.ReactNode;\n};\n\nexport default class PortalConsumer extends React.Component<Props> {\n async componentDidMount() {\n this.checkManager();\n\n // Delay updating to prevent React from going to infinite loop\n await Promise.resolve();\n\n this.key = this.props.manager.mount(this.props.children);\n }\n\n componentDidUpdate() {\n this.checkManager();\n\n this.props.manager.update(this.key, this.props.children);\n }\n\n componentWillUnmount() {\n this.checkManager();\n\n this.props.manager.unmount(this.key);\n }\n\n private key: any;\n\n private checkManager() {\n if (!this.props.manager) {\n throw new Error(\n \"Looks like you forgot to wrap your root component with `Provider` component from `react-native-paper`.\\n\\n\" +\n \"Please read our getting-started guide and make sure you've followed all the required steps.\\n\\n\" +\n \"https://callstack.github.io/react-native-paper/getting-started.html\"\n );\n }\n }\n\n render() {\n return null;\n }\n}\n"],"mappings":";;;AAAA,OAAO,KAAKA,KAAK,MAAM,OAAO;AAQ9B,eAAe,MAAMC,cAAc,SAASD,KAAK,CAACE,SAAS,CAAQ;EAAA;IAAA;IAAA;EAAA;EACjE,MAAMC,iBAAiB,GAAG;IACxB,IAAI,CAACC,YAAY,EAAE;;IAEnB;IACA,MAAMC,OAAO,CAACC,OAAO,EAAE;IAEvB,IAAI,CAACC,GAAG,GAAG,IAAI,CAACC,KAAK,CAACC,OAAO,CAACC,KAAK,CAAC,IAAI,CAACF,KAAK,CAACG,QAAQ,CAAC;EAC1D;EAEAC,kBAAkB,GAAG;IACnB,IAAI,CAACR,YAAY,EAAE;IAEnB,IAAI,CAACI,KAAK,CAACC,OAAO,CAACI,MAAM,CAAC,IAAI,CAACN,GAAG,EAAE,IAAI,CAACC,KAAK,CAACG,QAAQ,CAAC;EAC1D;EAEAG,oBAAoB,GAAG;IACrB,IAAI,CAACV,YAAY,EAAE;IAEnB,IAAI,CAACI,KAAK,CAACC,OAAO,CAACM,OAAO,CAAC,IAAI,CAACR,GAAG,CAAC;EACtC;EAIQH,YAAY,GAAG;IACrB,IAAI,CAAC,IAAI,CAACI,KAAK,CAACC,OAAO,EAAE;MACvB,MAAM,IAAIO,KAAK,CACb,4GAA4G,GAC1G,iGAAiG,GACjG,qEAAqE,CACxE;IACH;EACF;EAEAC,MAAM,GAAG;IACP,OAAO,IAAI;EACb;AACF"}
@@ -1,9 +1,11 @@
1
- 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; }
2
-
1
+ 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; }
2
+ function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
3
+ 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); }
3
4
  import * as React from "react";
4
5
  import { View, StyleSheet } from "react-native";
5
6
  import PortalManager from "./PortalManager";
6
7
  export const PortalContext = /*#__PURE__*/React.createContext(null);
8
+
7
9
  /**
8
10
  * Portal host renders all of its children `Portal` elements.
9
11
  * For example, you can wrap a screen in `Portal.Host` to render items above the screen.
@@ -28,18 +30,14 @@ export const PortalContext = /*#__PURE__*/React.createContext(null);
28
30
  *
29
31
  * Here any `Portal` elements under `<App />` are rendered alongside `<App />` and will appear above `<App />` like a `Modal`.
30
32
  */
31
-
32
33
  export default class PortalHost extends React.Component {
33
34
  constructor() {
34
35
  super(...arguments);
35
-
36
36
  _defineProperty(this, "setManager", manager => {
37
37
  this.manager = manager;
38
38
  });
39
-
40
39
  _defineProperty(this, "mount", children => {
41
40
  const key = this.nextKey++;
42
-
43
41
  if (this.manager) {
44
42
  this.manager.mount(key, children);
45
43
  } else {
@@ -49,10 +47,8 @@ export default class PortalHost extends React.Component {
49
47
  children
50
48
  });
51
49
  }
52
-
53
50
  return key;
54
51
  });
55
-
56
52
  _defineProperty(this, "update", (key, children) => {
57
53
  if (this.manager) {
58
54
  this.manager.update(key, children);
@@ -63,7 +59,6 @@ export default class PortalHost extends React.Component {
63
59
  children
64
60
  };
65
61
  const index = this.queue.findIndex(o => o.type === "mount" || o.type === "update" && o.key === key);
66
-
67
62
  if (index > -1) {
68
63
  // @ts-ignore
69
64
  this.queue[index] = op;
@@ -72,7 +67,6 @@ export default class PortalHost extends React.Component {
72
67
  }
73
68
  }
74
69
  });
75
-
76
70
  _defineProperty(this, "unmount", key => {
77
71
  if (this.manager) {
78
72
  this.manager.unmount(key);
@@ -83,31 +77,23 @@ export default class PortalHost extends React.Component {
83
77
  });
84
78
  }
85
79
  });
86
-
87
80
  _defineProperty(this, "nextKey", 0);
88
-
89
81
  _defineProperty(this, "queue", []);
90
-
91
82
  _defineProperty(this, "manager", void 0);
92
83
  }
93
-
94
84
  componentDidMount() {
95
85
  const manager = this.manager;
96
86
  const queue = this.queue;
97
-
98
87
  while (queue.length && manager) {
99
88
  const action = queue.pop();
100
-
101
89
  if (action) {
102
90
  switch (action.type) {
103
91
  case "mount":
104
92
  manager.mount(action.key, action.children);
105
93
  break;
106
-
107
94
  case "update":
108
95
  manager.update(action.key, action.children);
109
96
  break;
110
-
111
97
  case "unmount":
112
98
  manager.unmount(action.key);
113
99
  break;
@@ -115,7 +101,6 @@ export default class PortalHost extends React.Component {
115
101
  }
116
102
  }
117
103
  }
118
-
119
104
  render() {
120
105
  return /*#__PURE__*/React.createElement(PortalContext.Provider, {
121
106
  value: {
@@ -131,13 +116,11 @@ export default class PortalHost extends React.Component {
131
116
  ref: this.setManager
132
117
  }));
133
118
  }
134
-
135
119
  }
136
-
137
120
  _defineProperty(PortalHost, "displayName", "Portal.Host");
138
-
139
121
  const styles = StyleSheet.create({
140
122
  container: {
141
123
  flex: 1
142
124
  }
143
- });
125
+ });
126
+ //# sourceMappingURL=PortalHost.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["React","View","StyleSheet","PortalManager","PortalContext","createContext","PortalHost","Component","manager","children","key","nextKey","mount","queue","push","type","update","op","index","findIndex","o","unmount","componentDidMount","length","action","pop","render","styles","container","props","setManager","create","flex"],"sources":["PortalHost.tsx"],"sourcesContent":["import * as React from \"react\";\nimport { View, StyleSheet } from \"react-native\";\nimport PortalManager from \"./PortalManager\";\n\ntype Props = {\n children: React.ReactNode;\n};\n\ntype Operation =\n | { type: \"mount\"; key: number; children: React.ReactNode }\n | { type: \"update\"; key: number; children: React.ReactNode }\n | { type: \"unmount\"; key: number };\n\nexport type PortalMethods = {\n mount: (children: React.ReactNode) => number;\n update: (key: number, children: React.ReactNode) => void;\n unmount: (key: number) => void;\n};\n\nexport const PortalContext = React.createContext<PortalMethods>(null as any);\n\n/**\n * Portal host renders all of its children `Portal` elements.\n * For example, you can wrap a screen in `Portal.Host` to render items above the screen.\n * If you're using the `Provider` component, it already includes `Portal.Host`.\n *\n * ## Usage\n * ```js\n * import * as React from 'react';\n * import { Text } from 'react-native';\n * import { Portal } from 'react-native-paper';\n *\n * export default class MyComponent extends React.Component {\n * render() {\n * return (\n * <Portal.Host>\n * <Text>Content of the app</Text>\n * </Portal.Host>\n * );\n * }\n * }\n * ```\n *\n * Here any `Portal` elements under `<App />` are rendered alongside `<App />` and will appear above `<App />` like a `Modal`.\n */\nexport default class PortalHost extends React.Component<Props> {\n static displayName = \"Portal.Host\";\n\n componentDidMount() {\n const manager = this.manager;\n const queue = this.queue;\n\n while (queue.length && manager) {\n const action = queue.pop();\n if (action) {\n switch (action.type) {\n case \"mount\":\n manager.mount(action.key, action.children);\n break;\n case \"update\":\n manager.update(action.key, action.children);\n break;\n case \"unmount\":\n manager.unmount(action.key);\n break;\n }\n }\n }\n }\n\n private setManager = (manager: PortalManager | undefined | null) => {\n this.manager = manager;\n };\n\n private mount = (children: React.ReactNode) => {\n const key = this.nextKey++;\n\n if (this.manager) {\n this.manager.mount(key, children);\n } else {\n this.queue.push({ type: \"mount\", key, children });\n }\n\n return key;\n };\n\n private update = (key: number, children: React.ReactNode) => {\n if (this.manager) {\n this.manager.update(key, children);\n } else {\n const op = { type: \"mount\", key, children };\n const index = this.queue.findIndex(\n (o) => o.type === \"mount\" || (o.type === \"update\" && o.key === key)\n );\n\n if (index > -1) {\n // @ts-ignore\n this.queue[index] = op;\n } else {\n this.queue.push(op as Operation);\n }\n }\n };\n\n private unmount = (key: number) => {\n if (this.manager) {\n this.manager.unmount(key);\n } else {\n this.queue.push({ type: \"unmount\", key });\n }\n };\n\n private nextKey = 0;\n private queue: Operation[] = [];\n private manager: PortalManager | null | undefined;\n\n render() {\n return (\n <PortalContext.Provider\n value={{\n mount: this.mount,\n update: this.update,\n unmount: this.unmount,\n }}\n >\n {/* Need collapsable=false here to clip the elevations, otherwise they appear above Portal components */}\n <View\n style={styles.container}\n collapsable={false}\n pointerEvents=\"box-none\"\n >\n {this.props.children}\n </View>\n <PortalManager ref={this.setManager} />\n </PortalContext.Provider>\n );\n }\n}\n\nconst styles = StyleSheet.create({\n container: {\n flex: 1,\n },\n});\n"],"mappings":"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"}
@@ -1,19 +1,17 @@
1
- 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; }
2
-
1
+ 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; }
2
+ function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
3
+ 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); }
3
4
  import * as React from "react";
4
5
  import { View, StyleSheet } from "react-native";
5
-
6
6
  /**
7
7
  * Portal host is the component which actually renders all Portals.
8
8
  */
9
9
  export default class PortalManager extends React.PureComponent {
10
10
  constructor() {
11
11
  super(...arguments);
12
-
13
12
  _defineProperty(this, "state", {
14
13
  portals: []
15
14
  });
16
-
17
15
  _defineProperty(this, "mount", (key, children) => {
18
16
  this.setState(state => ({
19
17
  portals: [...state.portals, {
@@ -22,24 +20,21 @@ export default class PortalManager extends React.PureComponent {
22
20
  }]
23
21
  }));
24
22
  });
25
-
26
23
  _defineProperty(this, "update", (key, children) => this.setState(state => ({
27
24
  portals: state.portals.map(item => {
28
25
  if (item.key === key) {
29
- return { ...item,
26
+ return {
27
+ ...item,
30
28
  children
31
29
  };
32
30
  }
33
-
34
31
  return item;
35
32
  })
36
33
  })));
37
-
38
34
  _defineProperty(this, "unmount", key => this.setState(state => ({
39
35
  portals: state.portals.filter(item => item.key !== key)
40
36
  })));
41
37
  }
42
-
43
38
  render() {
44
39
  return this.state.portals.map(_ref => {
45
40
  let {
@@ -48,13 +43,12 @@ export default class PortalManager extends React.PureComponent {
48
43
  } = _ref;
49
44
  return /*#__PURE__*/React.createElement(View, {
50
45
  key: key,
51
- collapsable: false
52
- /* Need collapsable=false here to clip the elevations, otherwise they appear above sibling components */
53
- ,
46
+ collapsable: false /* Need collapsable=false here to clip the elevations, otherwise they appear above sibling components */,
47
+
54
48
  pointerEvents: "box-none",
55
49
  style: StyleSheet.absoluteFill
56
50
  }, children);
57
51
  });
58
52
  }
59
-
60
- }
53
+ }
54
+ //# sourceMappingURL=PortalManager.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["React","View","StyleSheet","PortalManager","PureComponent","portals","key","children","setState","state","map","item","filter","render","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,OAAO,KAAKA,KAAK,MAAM,OAAO;AAC9B,SAASC,IAAI,EAAEC,UAAU,QAAQ,cAAc;AAS/C;AACA;AACA;AACA,eAAe,MAAMC,aAAa,SAASH,KAAK,CAACI,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,IAAI;QACH,GAAG,EAAED,GAAI;QACT,WAAW,EACT,KAAK,CAAC,wGACP;;QACD,aAAa,EAAC,UAAU;QACxB,KAAK,EAAEJ,UAAU,CAACY;MAAa,GAE9BP,QAAQ,CACJ;IAAA,CACR,CAAC;EACJ;AACF"}
@@ -1,7 +1,7 @@
1
1
  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); }
2
-
3
- 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; }
4
-
2
+ 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; }
3
+ function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
4
+ 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); }
5
5
  import React, { Component } from "react";
6
6
  import { Animated, Easing, View, I18nManager } from "react-native";
7
7
  const INDETERMINATE_WIDTH_FACTOR = 0.3;
@@ -9,24 +9,20 @@ const BAR_WIDTH_ZERO_POSITION = INDETERMINATE_WIDTH_FACTOR / (1 + INDETERMINATE_
9
9
  export default class ProgressBar extends Component {
10
10
  constructor(props) {
11
11
  super(props);
12
-
13
12
  _defineProperty(this, "handleLayout", event => {
14
13
  const {
15
14
  width = 150,
16
15
  onLayout
17
16
  } = this.props;
18
-
19
17
  if (!width) {
20
18
  this.setState({
21
19
  width: event.nativeEvent.layout.width
22
20
  });
23
21
  }
24
-
25
22
  if (onLayout) {
26
23
  onLayout(event);
27
24
  }
28
25
  });
29
-
30
26
  const {
31
27
  progress: progressP = 0,
32
28
  indeterminate = false
@@ -38,17 +34,14 @@ export default class ProgressBar extends Component {
38
34
  animationValue: new Animated.Value(BAR_WIDTH_ZERO_POSITION)
39
35
  };
40
36
  }
41
-
42
37
  componentDidMount() {
43
38
  const {
44
39
  indeterminate = false
45
40
  } = this.props;
46
-
47
41
  if (indeterminate) {
48
42
  this.animate();
49
43
  }
50
44
  }
51
-
52
45
  componentDidUpdate(prevProps) {
53
46
  const {
54
47
  indeterminate = false,
@@ -60,7 +53,6 @@ export default class ProgressBar extends Component {
60
53
  },
61
54
  animated = true
62
55
  } = this.props;
63
-
64
56
  if (prevProps.indeterminate !== indeterminate) {
65
57
  if (indeterminate) {
66
58
  this.animate();
@@ -71,12 +63,11 @@ export default class ProgressBar extends Component {
71
63
  }).start();
72
64
  }
73
65
  }
74
-
75
66
  if (prevProps.indeterminate !== indeterminate || prevProps.progress !== progressP) {
76
67
  const progress = this.props.indeterminate ? INDETERMINATE_WIDTH_FACTOR : Math.min(Math.max(progressP, 0), 1);
77
-
78
68
  if (animated) {
79
- Animated[animationType](this.state.progress, { ...animationConfig,
69
+ Animated[animationType](this.state.progress, {
70
+ ...animationConfig,
80
71
  toValue: progress,
81
72
  velocity: 0,
82
73
  //adjust this value if animation fails - velocity is required
@@ -87,7 +78,6 @@ export default class ProgressBar extends Component {
87
78
  }
88
79
  }
89
80
  }
90
-
91
81
  animate() {
92
82
  const {
93
83
  useNativeDriver = false,
@@ -106,7 +96,6 @@ export default class ProgressBar extends Component {
106
96
  }
107
97
  });
108
98
  }
109
-
110
99
  render() {
111
100
  const {
112
101
  borderColor,
@@ -157,5 +146,5 @@ export default class ProgressBar extends Component {
157
146
  style: progressStyle
158
147
  }), children);
159
148
  }
160
-
161
- }
149
+ }
150
+ //# sourceMappingURL=ProgressBar.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["React","Component","Animated","Easing","View","I18nManager","INDETERMINATE_WIDTH_FACTOR","BAR_WIDTH_ZERO_POSITION","ProgressBar","constructor","props","event","width","onLayout","setState","nativeEvent","layout","progress","progressP","indeterminate","Math","min","max","state","Value","animationValue","componentDidMount","animate","componentDidUpdate","prevProps","useNativeDriver","animationType","animationConfig","bounciness","animated","spring","toValue","start","velocity","setValue","indeterminateAnimationDuration","timing","duration","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","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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"}
@@ -2,7 +2,6 @@ import * as React from "react";
2
2
  import { Text } from "react-native";
3
3
  import AnimatedCircularProgress from "./AnimatedCircularProgress";
4
4
  import { withTheme } from "../theming";
5
-
6
5
  const ProgressCircle = _ref => {
7
6
  let {
8
7
  progress = 0.5,
@@ -36,5 +35,5 @@ const ProgressCircle = _ref => {
36
35
  }, textStyle]
37
36
  }, Math.round(fill), "%") : null);
38
37
  };
39
-
40
- export default withTheme(ProgressCircle);
38
+ export default withTheme(ProgressCircle);
39
+ //# sourceMappingURL=ProgressCircle.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["React","Text","AnimatedCircularProgress","withTheme","ProgressCircle","progress","style","color","size","showsText","unfilledColor","strokeCap","textStyle","thickness","theme","progressNum","Math","round","tintColor","colors","primary","backgroundColor","secondary","fill","fontSize"],"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,OAAO,KAAKA,KAAK,MAAM,OAAO;AAC9B,SAASC,IAAI,QAAyC,cAAc;AACpE,OAAOC,wBAAwB,MAAM,4BAA4B;AACjE,SAASC,SAAS,QAAQ,YAAY;AAiBtC,MAAMC,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,wBAAwB;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,IAAI;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;AAED,eAAepB,SAAS,CAACC,cAAc,CAAC"}
@@ -1,7 +1,6 @@
1
1
  import * as React from "react";
2
2
  import StepIndicator from "./StepIndicator";
3
3
  import { withTheme } from "../theming";
4
-
5
4
  const ProgressIndicator = _ref => {
6
5
  let {
7
6
  numberOfSteps,
@@ -43,5 +42,5 @@ const ProgressIndicator = _ref => {
43
42
  }
44
43
  });
45
44
  };
46
-
47
- export default withTheme(ProgressIndicator);
45
+ export default withTheme(ProgressIndicator);
46
+ //# sourceMappingURL=ProgressIndicator.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["React","StepIndicator","withTheme","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"],"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,OAAO,KAAKA,KAAK,MAAM,OAAO;AAC9B,OAAOC,aAAa,MAAM,iBAAiB;AAC3C,SAASC,SAAS,QAAQ,YAAY;AAqBtC,MAAMC,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,aAAa;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;AAED,eAAe5B,SAAS,CAACC,iBAAiB,CAAC"}
@@ -1,11 +1,9 @@
1
1
  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); }
2
-
3
2
  import * as React from "react";
4
3
  import Config from "../Config";
5
4
  import IconButton from "../IconButton";
6
5
  import { getValueForRadioButton } from "../../utilities";
7
6
  import { useRadioButtonGroupContext } from "./context";
8
-
9
7
  const RadioButton = _ref => {
10
8
  let {
11
9
  Icon,
@@ -27,13 +25,11 @@ const RadioButton = _ref => {
27
25
  } = useRadioButtonGroupContext();
28
26
  const realValue = getValueForRadioButton(value);
29
27
  const realContextValue = getValueForRadioButton(contextValue);
30
- const isSelected = selected !== null && selected !== void 0 ? selected : realContextValue === realValue;
31
-
28
+ const isSelected = selected ?? realContextValue === realValue;
32
29
  const handlePress = () => {
33
30
  onPress === null || onPress === void 0 ? void 0 : onPress(realValue);
34
31
  onValueChange === null || onValueChange === void 0 ? void 0 : onValueChange(realValue);
35
32
  };
36
-
37
33
  return /*#__PURE__*/React.createElement(IconButton, _extends({
38
34
  Icon: Icon,
39
35
  icon: isSelected ? selectedIcon : unselectedIcon,
@@ -44,5 +40,5 @@ const RadioButton = _ref => {
44
40
  style: style
45
41
  }, rest));
46
42
  };
47
-
48
- export default RadioButton;
43
+ export default RadioButton;
44
+ //# sourceMappingURL=RadioButton.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["React","Config","IconButton","getValueForRadioButton","useRadioButtonGroupContext","RadioButton","Icon","disabled","color","value","selected","unselectedColor","onPress","size","radioButtonSize","selectedIcon","unselectedIcon","style","rest","contextValue","onValueChange","realValue","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,OAAO,KAAKA,KAAK,MAAM,OAAO;AAG9B,OAAOC,MAAM,MAAM,WAAW;AAC9B,OAAOC,UAAU,MAAM,eAAe;AACtC,SAASC,sBAAsB,QAAQ,iBAAiB;AACxD,SAASC,0BAA0B,QAAQ,WAAW;AAiBtD,MAAMC,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,GAAGZ,MAAM,CAACa,eAAe;IAC7BC,YAAY,GAAG,oCAAoC;IACnDC,cAAc,GAAG,sCAAsC;IACvDC,KAAK;IACL,GAAGC;EACL,CAAC;EACC,MAAM;IAAET,KAAK,EAAEU,YAAY;IAAEC;EAAc,CAAC,GAAGhB,0BAA0B,EAAE;EAE3E,MAAMiB,SAAS,GAAGlB,sBAAsB,CAACM,KAAK,CAAC;EAC/C,MAAMa,gBAAgB,GAAGnB,sBAAsB,CAACgB,YAAY,CAAC;EAC7D,MAAMI,UAAU,GAAGb,QAAQ,IAAIY,gBAAgB,KAAKD,SAAS;EAE7D,MAAMG,WAAW,GAAG,MAAM;IACxBZ,OAAO,aAAPA,OAAO,uBAAPA,OAAO,CAAGS,SAAS,CAAC;IACpBD,aAAa,aAAbA,aAAa,uBAAbA,aAAa,CAAGC,SAAS,CAAC;EAC5B,CAAC;EAED,oBACE,oBAAC,UAAU;IACT,IAAI,EAAEf,IAAK;IACX,IAAI,EAAEiB,UAAU,GAAGR,YAAY,GAAGC,cAAe;IACjD,KAAK,EAAEO,UAAU,GAAGf,KAAK,GAAGG,eAAgB;IAC5C,QAAQ,EAAEJ,QAAS;IACnB,OAAO,EAAEiB,WAAY;IACrB,IAAI,EAAEX,IAAK;IACX,KAAK,EAAEI;EAAM,GACTC,IAAI,EACR;AAEN,CAAC;AAED,eAAeb,WAAW"}
@@ -1,11 +1,9 @@
1
1
  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); }
2
-
3
2
  import React from "react";
4
3
  import { View } from "react-native";
5
4
  import Text from "../Text";
6
5
  import { withTheme } from "../../theming";
7
6
  import RadioButtonGroup from "./RadioButtonGroup";
8
-
9
7
  const RadioButtonFieldGroup = _ref => {
10
8
  let {
11
9
  label,
@@ -26,5 +24,5 @@ const RadioButtonFieldGroup = _ref => {
26
24
  theme: theme
27
25
  }, rest), children));
28
26
  };
29
-
30
- export default withTheme(RadioButtonFieldGroup);
27
+ export default withTheme(RadioButtonFieldGroup);
28
+ //# sourceMappingURL=RadioButtonFieldGroup.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["React","View","Text","withTheme","RadioButtonGroup","RadioButtonFieldGroup","label","children","theme","labelStyle","style","rest","fontSize","typography","headline4","color"],"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,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,IAAI,QAAyC,cAAc;AACpE,OAAOC,IAAI,MAAM,SAAS;AAC1B,SAASC,SAAS,QAAQ,eAAe;AACzC,OAAOC,gBAAgB,MAAiC,oBAAoB;AAQ5E,MAAMC,qBAA+D,GAAG,QAOlE;EAAA,IAPmE;IACvEC,KAAK;IACLC,QAAQ;IACRC,KAAK;IACLC,UAAU;IACVC,KAAK;IACL,GAAGC;EACL,CAAC;EACC,oBACE,oBAAC,IAAI;IAAC,KAAK,EAAED;EAAM,gBACjB,oBAAC,IAAI;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,oBAAC,gBAAgB;IAAC,KAAK,EAAEE;EAAM,GAAKG,IAAI,GACrCJ,QAAQ,CACQ,CACd;AAEX,CAAC;AAED,eAAeJ,SAAS,CAACE,qBAAqB,CAAC"}
@@ -1,5 +1,4 @@
1
1
  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); }
2
-
3
2
  import * as React from "react";
4
3
  import { View } from "react-native";
5
4
  import { getValueForRadioButton } from "../../utilities";
@@ -7,7 +6,6 @@ import { radioButtonGroupContext, Direction } from "./context";
7
6
  const {
8
7
  Provider
9
8
  } = radioButtonGroupContext;
10
-
11
9
  const RadioButtonGroup = _ref => {
12
10
  let {
13
11
  direction = Direction.Vertical,
@@ -31,23 +29,19 @@ const RadioButtonGroup = _ref => {
31
29
  setInternalValue(realDefaultValue);
32
30
  }
33
31
  }, [defaultValue]);
34
-
35
32
  const handleValueChange = newValue => {
36
33
  const realNewValue = getValueForRadioButton(newValue);
37
34
  setInternalValue(realNewValue);
38
35
  onValueChange === null || onValueChange === void 0 ? void 0 : onValueChange(realNewValue);
39
36
  };
40
-
41
37
  const _containerStyle = [{
42
38
  flexDirection: direction === Direction.Horizontal ? "row" : "column"
43
39
  }];
44
-
45
40
  if (direction !== Direction.Vertical) {
46
41
  _containerStyle.push({
47
42
  alignItems: "center"
48
43
  });
49
44
  }
50
-
51
45
  return /*#__PURE__*/React.createElement(View, _extends({
52
46
  style: [{
53
47
  minHeight: 40
@@ -62,5 +56,5 @@ const RadioButtonGroup = _ref => {
62
56
  style: _containerStyle
63
57
  }, children)));
64
58
  };
65
-
66
- export default RadioButtonGroup;
59
+ export default RadioButtonGroup;
60
+ //# sourceMappingURL=RadioButtonGroup.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["React","View","getValueForRadioButton","radioButtonGroupContext","Direction","Provider","RadioButtonGroup","direction","Vertical","value","onValueChange","defaultValue","style","children","rest","internalValue","setInternalValue","useState","useEffect","realValue","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,OAAO,KAAKA,KAAK,MAAM,OAAO;AAC9B,SAASC,IAAI,QAA8B,cAAc;AAEzD,SAASC,sBAAsB,QAAQ,iBAAiB;AACxD,SAASC,uBAAuB,EAAEC,SAAS,QAAQ,WAAW;AAW9D,MAAM;EAAEC;AAAS,CAAC,GAAGF,uBAAuB;AAE5C,MAAMG,gBAAiD,GAAG,QAQpD;EAAA,IARqD;IACzDC,SAAS,GAAGH,SAAS,CAACI,QAAQ;IAC9BC,KAAK,GAAG,EAAE;IACVC,aAAa;IACbC,YAAY;IACZC,KAAK;IACLC,QAAQ;IACR,GAAGC;EACL,CAAC;EACC,MAAM,CAACC,aAAa,EAAEC,gBAAgB,CAAC,GAAGhB,KAAK,CAACiB,QAAQ,CAAC,EAAE,CAAC;EAE5DjB,KAAK,CAACkB,SAAS,CAAC,MAAM;IACpB,IAAIT,KAAK,IAAI,IAAI,EAAE;MACjB,MAAMU,SAAS,GAAGjB,sBAAsB,CAACO,KAAK,CAAC;MAE/CO,gBAAgB,CAACG,SAAS,CAAC;IAC7B;EACF,CAAC,EAAE,CAACV,KAAK,CAAC,CAAC;EAEXT,KAAK,CAACkB,SAAS,CAAC,MAAM;IACpB,IAAIP,YAAY,IAAI,IAAI,EAAE;MACxB,MAAMS,gBAAgB,GAAGlB,sBAAsB,CAACS,YAAY,CAAC;MAE7DK,gBAAgB,CAACI,gBAAgB,CAAC;IACpC;EACF,CAAC,EAAE,CAACT,YAAY,CAAC,CAAC;EAElB,MAAMU,iBAAiB,GAAIC,QAAyB,IAAK;IACvD,MAAMC,YAAY,GAAGrB,sBAAsB,CAACoB,QAAQ,CAAC;IAErDN,gBAAgB,CAACO,YAAY,CAAC;IAC9Bb,aAAa,aAAbA,aAAa,uBAAbA,aAAa,CAAGa,YAAY,CAAC;EAC/B,CAAC;EAED,MAAMC,eAAqC,GAAG,CAC5C;IACEC,aAAa,EAAElB,SAAS,KAAKH,SAAS,CAACsB,UAAU,GAAG,KAAK,GAAG;EAC9D,CAAC,CACF;EAED,IAAInB,SAAS,KAAKH,SAAS,CAACI,QAAQ,EAAE;IACpCgB,eAAe,CAACG,IAAI,CAAC;MACnBC,UAAU,EAAE;IACd,CAAC,CAAC;EACJ;EAEA,oBACE,oBAAC,IAAI;IAAC,KAAK,EAAE,CAAC;MAAEC,SAAS,EAAE;IAAG,CAAC,EAAEjB,KAAK;EAAE,GAAKE,IAAI,gBAC/C,oBAAC,QAAQ;IACP,KAAK,EAAE;MACLL,KAAK,EAAEM,aAAa;MACpBL,aAAa,EAAEW,iBAAiB;MAChCd;IACF;EAAE,gBAEF,oBAAC,IAAI;IAAC,KAAK,EAAEiB;EAAgB,GAAEX,QAAQ,CAAQ,CACtC,CACN;AAEX,CAAC;AAED,eAAeP,gBAAgB"}
@@ -1,5 +1,4 @@
1
1
  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); }
2
-
3
2
  import * as React from "react";
4
3
  import { StyleSheet, View, Platform } from "react-native";
5
4
  import RadioButton from "./RadioButton";
@@ -9,12 +8,10 @@ import { Direction as GroupDirection } from "./context";
9
8
  import Touchable from "../Touchable";
10
9
  import { extractStyles, getValueForRadioButton } from "../../utilities";
11
10
  export let Direction;
12
-
13
11
  (function (Direction) {
14
12
  Direction["Row"] = "row";
15
13
  Direction["RowReverse"] = "row-reverse";
16
14
  })(Direction || (Direction = {}));
17
-
18
15
  const getRadioButtonAlignment = (parentDirection, direction) => {
19
16
  if (parentDirection === GroupDirection.Horizontal) {
20
17
  return direction === Direction.Row ? "flex-start" : "flex-end";
@@ -24,7 +21,6 @@ const getRadioButtonAlignment = (parentDirection, direction) => {
24
21
  return "flex-end";
25
22
  }
26
23
  };
27
-
28
24
  const renderLabel = (value, labelStyle, textStyle) => {
29
25
  if (typeof value === "string") {
30
26
  return /*#__PURE__*/React.createElement(Text, {
@@ -34,7 +30,6 @@ const renderLabel = (value, labelStyle, textStyle) => {
34
30
  return /*#__PURE__*/React.createElement(React.Fragment, null, value);
35
31
  }
36
32
  };
37
-
38
33
  const RadioButtonRow = _ref => {
39
34
  let {
40
35
  Icon,
@@ -59,13 +54,11 @@ const RadioButtonRow = _ref => {
59
54
  } = useRadioButtonGroupContext();
60
55
  const realValue = getValueForRadioButton(value);
61
56
  const realContextValue = getValueForRadioButton(contextValue);
62
- const isSelected = selected !== null && selected !== void 0 ? selected : realContextValue === realValue;
63
-
57
+ const isSelected = selected ?? realContextValue === realValue;
64
58
  const handlePress = () => {
65
59
  onPress === null || onPress === void 0 ? void 0 : onPress(realValue);
66
60
  onValueChange === null || onValueChange === void 0 ? void 0 : onValueChange(realValue);
67
61
  };
68
-
69
62
  const {
70
63
  textStyles,
71
64
  viewStyles
@@ -94,7 +87,6 @@ const RadioButtonRow = _ref => {
94
87
  style: radioButtonStyle
95
88
  })));
96
89
  };
97
-
98
90
  const styles = StyleSheet.create({
99
91
  mainParent: {
100
92
  alignItems: "center",
@@ -114,4 +106,5 @@ const styles = StyleSheet.create({
114
106
  flex: 3
115
107
  }
116
108
  });
117
- export default RadioButtonRow;
109
+ export default RadioButtonRow;
110
+ //# sourceMappingURL=RadioButtonRow.js.map