@pagopa/io-app-design-system 1.0.0-9 → 1.1.1

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 (342) hide show
  1. package/README.md +39 -4
  2. package/lib/commonjs/components/Advice/Advice.js +5 -7
  3. package/lib/commonjs/components/Advice/Advice.js.map +1 -1
  4. package/lib/commonjs/components/Advice/__test__/advice.test.js +2 -2
  5. package/lib/commonjs/components/Advice/__test__/advice.test.js.map +1 -1
  6. package/lib/commonjs/components/accordion/RawAccordion.js.map +1 -1
  7. package/lib/commonjs/components/badge/__test__/badge.test.js.map +1 -1
  8. package/lib/commonjs/components/buttons/ButtonLink.js +4 -5
  9. package/lib/commonjs/components/buttons/ButtonLink.js.map +1 -1
  10. package/lib/commonjs/components/buttons/IconButton.js +0 -2
  11. package/lib/commonjs/components/buttons/IconButton.js.map +1 -1
  12. package/lib/commonjs/components/buttons/IconButtonContained.js +131 -0
  13. package/lib/commonjs/components/buttons/IconButtonContained.js.map +1 -0
  14. package/lib/commonjs/components/buttons/IconButtonSolid.js +109 -0
  15. package/lib/commonjs/components/buttons/IconButtonSolid.js.map +1 -0
  16. package/lib/commonjs/components/buttons/__test__/__snapshots__/button.test.tsx.snap +370 -0
  17. package/lib/commonjs/components/buttons/__test__/button.test.js +27 -0
  18. package/lib/commonjs/components/buttons/__test__/button.test.js.map +1 -1
  19. package/lib/commonjs/components/buttons/index.js +30 -8
  20. package/lib/commonjs/components/buttons/index.js.map +1 -1
  21. package/lib/commonjs/components/checkbox/AnimatedCheckbox.js +1 -1
  22. package/lib/commonjs/components/checkbox/AnimatedCheckbox.js.map +1 -1
  23. package/lib/commonjs/components/icons/Icon.js +35 -9
  24. package/lib/commonjs/components/icons/Icon.js.map +1 -1
  25. package/lib/commonjs/components/icons/index.js +0 -18
  26. package/lib/commonjs/components/icons/index.js.map +1 -1
  27. package/lib/commonjs/components/icons/svg/{LegIconSearch.js → IconCheckTick.js} +4 -9
  28. package/lib/commonjs/components/icons/svg/{IconCompleted.js.map → IconCheckTick.js.map} +1 -1
  29. package/lib/commonjs/components/icons/svg/{IconCompleted.js → IconCheckTickBig.js} +3 -3
  30. package/lib/commonjs/components/icons/svg/IconCheckTickBig.js.map +1 -0
  31. package/lib/commonjs/components/icons/svg/IconMerchant.js +31 -0
  32. package/lib/commonjs/components/icons/svg/IconMerchant.js.map +1 -0
  33. package/lib/commonjs/components/icons/svg/IconSystemAppsAndroid.js +49 -0
  34. package/lib/commonjs/components/icons/svg/IconSystemAppsAndroid.js.map +1 -0
  35. package/lib/commonjs/components/icons/svg/IconSystemNotificationsInstructions.js +42 -0
  36. package/lib/commonjs/components/icons/svg/IconSystemNotificationsInstructions.js.map +1 -0
  37. package/lib/commonjs/components/icons/svg/IconSystemSettingsAndroid.js +34 -0
  38. package/lib/commonjs/components/icons/svg/IconSystemSettingsAndroid.js.map +1 -0
  39. package/lib/commonjs/components/icons/svg/IconSystemSettingsiOS.js +68 -0
  40. package/lib/commonjs/components/icons/svg/IconSystemSettingsiOS.js.map +1 -0
  41. package/lib/commonjs/components/icons/svg/{LegIconChevronLeft.js → IconSystemToggleInstructions.js} +5 -5
  42. package/lib/commonjs/components/icons/svg/IconSystemToggleInstructions.js.map +1 -0
  43. package/lib/commonjs/components/index.js +72 -72
  44. package/lib/commonjs/components/index.js.map +1 -1
  45. package/lib/commonjs/components/layout/GradientBottomActions.js +90 -0
  46. package/lib/commonjs/components/layout/GradientBottomActions.js.map +1 -0
  47. package/lib/commonjs/components/layout/GradientScrollView.js +111 -0
  48. package/lib/commonjs/components/layout/GradientScrollView.js.map +1 -0
  49. package/lib/commonjs/components/layout/HeaderFirstLevel.js +62 -0
  50. package/lib/commonjs/components/layout/HeaderFirstLevel.js.map +1 -0
  51. package/lib/commonjs/components/layout/index.js +17 -0
  52. package/lib/commonjs/components/layout/index.js.map +1 -0
  53. package/lib/commonjs/components/listitems/ListItemCheckbox.js +135 -0
  54. package/lib/commonjs/components/listitems/ListItemCheckbox.js.map +1 -0
  55. package/lib/commonjs/components/listitems/ListItemInfo.js +3 -6
  56. package/lib/commonjs/components/listitems/ListItemInfo.js.map +1 -1
  57. package/lib/commonjs/components/listitems/ListItemInfoCopy.js +1 -4
  58. package/lib/commonjs/components/listitems/ListItemInfoCopy.js.map +1 -1
  59. package/lib/commonjs/components/listitems/ListItemRadio.js +136 -0
  60. package/lib/commonjs/components/listitems/ListItemRadio.js.map +1 -0
  61. package/lib/commonjs/components/listitems/ListItemSwitch.js +82 -0
  62. package/lib/commonjs/components/listitems/ListItemSwitch.js.map +1 -0
  63. package/lib/commonjs/components/listitems/ListItemTransaction.js +2 -3
  64. package/lib/commonjs/components/listitems/ListItemTransaction.js.map +1 -1
  65. package/lib/commonjs/components/listitems/__test__/__snapshots__/listitem.test.tsx.snap +0 -14
  66. package/lib/commonjs/components/listitems/index.js +33 -0
  67. package/lib/commonjs/components/listitems/index.js.map +1 -1
  68. package/lib/commonjs/components/logos/svg/LogoPaymentExtMaestro.js +3 -19
  69. package/lib/commonjs/components/logos/svg/LogoPaymentExtMaestro.js.map +1 -1
  70. package/lib/commonjs/components/logos/svg/LogoPaymentExtMastercard.js +5 -21
  71. package/lib/commonjs/components/logos/svg/LogoPaymentExtMastercard.js.map +1 -1
  72. package/lib/commonjs/components/logos/svg/LogoPaymentExtPayPal.js +9 -28
  73. package/lib/commonjs/components/logos/svg/LogoPaymentExtPayPal.js.map +1 -1
  74. package/lib/commonjs/components/logos/svg/LogoPaymentMaestro.js +8 -18
  75. package/lib/commonjs/components/logos/svg/LogoPaymentMaestro.js.map +1 -1
  76. package/lib/commonjs/components/logos/svg/LogoPaymentMastercard.js +7 -17
  77. package/lib/commonjs/components/logos/svg/LogoPaymentMastercard.js.map +1 -1
  78. package/lib/commonjs/components/logos/svg/LogoPaymentPayPal.js +5 -5
  79. package/lib/commonjs/components/logos/svg/LogoPaymentPayPal.js.map +1 -1
  80. package/lib/commonjs/components/radio/AnimatedRadio.js +1 -1
  81. package/lib/commonjs/components/radio/AnimatedRadio.js.map +1 -1
  82. package/lib/commonjs/components/radio/RadioGroup.js +36 -0
  83. package/lib/commonjs/components/radio/RadioGroup.js.map +1 -0
  84. package/lib/commonjs/components/radio/index.js +11 -0
  85. package/lib/commonjs/components/radio/index.js.map +1 -1
  86. package/lib/commonjs/components/typography/H3.js +20 -49
  87. package/lib/commonjs/components/typography/H3.js.map +1 -1
  88. package/lib/commonjs/components/typography/Link.js +17 -23
  89. package/lib/commonjs/components/typography/Link.js.map +1 -1
  90. package/lib/commonjs/components/typography/__test__/__snapshots__/typography.test.tsx.snap +50 -45
  91. package/lib/commonjs/core/IOColors.js +1 -1
  92. package/lib/commonjs/core/IOColors.js.map +1 -1
  93. package/lib/commonjs/core/IOSpacing.js +1 -1
  94. package/lib/commonjs/core/IOSpacing.js.map +1 -1
  95. package/lib/commonjs/core/IOStyles.js +7 -1
  96. package/lib/commonjs/core/IOStyles.js.map +1 -1
  97. package/lib/commonjs/index.js +30 -8
  98. package/lib/commonjs/index.js.map +1 -1
  99. package/lib/commonjs/json-import.d.js +2 -0
  100. package/lib/commonjs/json-import.d.js.map +1 -0
  101. package/lib/module/components/Advice/Advice.js +4 -6
  102. package/lib/module/components/Advice/Advice.js.map +1 -1
  103. package/lib/module/components/Advice/__test__/advice.test.js +1 -1
  104. package/lib/module/components/Advice/__test__/advice.test.js.map +1 -1
  105. package/lib/module/components/accordion/RawAccordion.js +1 -1
  106. package/lib/module/components/accordion/RawAccordion.js.map +1 -1
  107. package/lib/module/components/badge/__test__/badge.test.js.map +1 -1
  108. package/lib/module/components/buttons/ButtonLink.js +4 -5
  109. package/lib/module/components/buttons/ButtonLink.js.map +1 -1
  110. package/lib/module/components/buttons/IconButton.js +0 -2
  111. package/lib/module/components/buttons/IconButton.js.map +1 -1
  112. package/lib/module/components/buttons/IconButtonContained.js +122 -0
  113. package/lib/module/components/buttons/IconButtonContained.js.map +1 -0
  114. package/lib/module/components/buttons/IconButtonSolid.js +100 -0
  115. package/lib/module/components/buttons/IconButtonSolid.js.map +1 -0
  116. package/lib/module/components/buttons/__test__/__snapshots__/button.test.tsx.snap +370 -0
  117. package/lib/module/components/buttons/__test__/button.test.js +27 -0
  118. package/lib/module/components/buttons/__test__/button.test.js.map +1 -1
  119. package/lib/module/components/buttons/index.js +4 -2
  120. package/lib/module/components/buttons/index.js.map +1 -1
  121. package/lib/module/components/checkbox/AnimatedCheckbox.js +3 -3
  122. package/lib/module/components/checkbox/AnimatedCheckbox.js.map +1 -1
  123. package/lib/module/components/icons/Icon.js +33 -8
  124. package/lib/module/components/icons/Icon.js.map +1 -1
  125. package/lib/module/components/icons/index.js +0 -1
  126. package/lib/module/components/icons/index.js.map +1 -1
  127. package/lib/module/components/icons/svg/{LegIconSearch.js → IconCheckTick.js} +4 -9
  128. package/lib/module/components/icons/svg/{IconCompleted.js.map → IconCheckTick.js.map} +1 -1
  129. package/lib/module/components/icons/svg/{IconCompleted.js → IconCheckTickBig.js} +3 -3
  130. package/lib/module/components/icons/svg/IconCheckTickBig.js.map +1 -0
  131. package/lib/module/components/icons/svg/IconMerchant.js +23 -0
  132. package/lib/module/components/icons/svg/IconMerchant.js.map +1 -0
  133. package/lib/module/components/icons/svg/IconSystemAppsAndroid.js +41 -0
  134. package/lib/module/components/icons/svg/IconSystemAppsAndroid.js.map +1 -0
  135. package/lib/module/components/icons/svg/IconSystemNotificationsInstructions.js +34 -0
  136. package/lib/module/components/icons/svg/IconSystemNotificationsInstructions.js.map +1 -0
  137. package/lib/module/components/icons/svg/IconSystemSettingsAndroid.js +26 -0
  138. package/lib/module/components/icons/svg/IconSystemSettingsAndroid.js.map +1 -0
  139. package/lib/module/components/icons/svg/IconSystemSettingsiOS.js +60 -0
  140. package/lib/module/components/icons/svg/IconSystemSettingsiOS.js.map +1 -0
  141. package/lib/module/components/icons/svg/{LegIconChevronLeft.js → IconSystemToggleInstructions.js} +5 -5
  142. package/lib/module/components/icons/svg/IconSystemToggleInstructions.js.map +1 -0
  143. package/lib/module/components/index.js +13 -13
  144. package/lib/module/components/index.js.map +1 -1
  145. package/lib/module/components/layout/GradientBottomActions.js +79 -0
  146. package/lib/module/components/layout/GradientBottomActions.js.map +1 -0
  147. package/lib/module/components/layout/GradientScrollView.js +100 -0
  148. package/lib/module/components/layout/GradientScrollView.js.map +1 -0
  149. package/lib/module/components/layout/HeaderFirstLevel.js +52 -0
  150. package/lib/module/components/layout/HeaderFirstLevel.js.map +1 -0
  151. package/lib/module/components/layout/index.js +2 -0
  152. package/lib/module/components/layout/index.js.map +1 -0
  153. package/lib/module/components/listitems/ListItemCheckbox.js +126 -0
  154. package/lib/module/components/listitems/ListItemCheckbox.js.map +1 -0
  155. package/lib/module/components/listitems/ListItemInfo.js +3 -6
  156. package/lib/module/components/listitems/ListItemInfo.js.map +1 -1
  157. package/lib/module/components/listitems/ListItemInfoCopy.js +1 -4
  158. package/lib/module/components/listitems/ListItemInfoCopy.js.map +1 -1
  159. package/lib/module/components/listitems/ListItemRadio.js +127 -0
  160. package/lib/module/components/listitems/ListItemRadio.js.map +1 -0
  161. package/lib/module/components/listitems/ListItemSwitch.js +74 -0
  162. package/lib/module/components/listitems/ListItemSwitch.js.map +1 -0
  163. package/lib/module/components/listitems/ListItemTransaction.js +2 -3
  164. package/lib/module/components/listitems/ListItemTransaction.js.map +1 -1
  165. package/lib/module/components/listitems/__test__/__snapshots__/listitem.test.tsx.snap +0 -14
  166. package/lib/module/components/listitems/index.js +3 -0
  167. package/lib/module/components/listitems/index.js.map +1 -1
  168. package/lib/module/components/logos/svg/LogoPaymentExtMaestro.js +3 -19
  169. package/lib/module/components/logos/svg/LogoPaymentExtMaestro.js.map +1 -1
  170. package/lib/module/components/logos/svg/LogoPaymentExtMastercard.js +5 -21
  171. package/lib/module/components/logos/svg/LogoPaymentExtMastercard.js.map +1 -1
  172. package/lib/module/components/logos/svg/LogoPaymentExtPayPal.js +10 -29
  173. package/lib/module/components/logos/svg/LogoPaymentExtPayPal.js.map +1 -1
  174. package/lib/module/components/logos/svg/LogoPaymentMaestro.js +9 -19
  175. package/lib/module/components/logos/svg/LogoPaymentMaestro.js.map +1 -1
  176. package/lib/module/components/logos/svg/LogoPaymentMastercard.js +8 -18
  177. package/lib/module/components/logos/svg/LogoPaymentMastercard.js.map +1 -1
  178. package/lib/module/components/logos/svg/LogoPaymentPayPal.js +5 -5
  179. package/lib/module/components/logos/svg/LogoPaymentPayPal.js.map +1 -1
  180. package/lib/module/components/radio/AnimatedRadio.js +3 -3
  181. package/lib/module/components/radio/AnimatedRadio.js.map +1 -1
  182. package/lib/module/components/radio/RadioGroup.js +28 -0
  183. package/lib/module/components/radio/RadioGroup.js.map +1 -0
  184. package/lib/module/components/radio/index.js +1 -0
  185. package/lib/module/components/radio/index.js.map +1 -1
  186. package/lib/module/components/typography/H3.js +19 -47
  187. package/lib/module/components/typography/H3.js.map +1 -1
  188. package/lib/module/components/typography/Link.js +17 -23
  189. package/lib/module/components/typography/Link.js.map +1 -1
  190. package/lib/module/components/typography/__test__/__snapshots__/typography.test.tsx.snap +50 -45
  191. package/lib/module/core/IOColors.js +1 -1
  192. package/lib/module/core/IOColors.js.map +1 -1
  193. package/lib/module/core/IOSpacing.js +1 -1
  194. package/lib/module/core/IOSpacing.js.map +1 -1
  195. package/lib/module/core/IOStyles.js +5 -0
  196. package/lib/module/core/IOStyles.js.map +1 -1
  197. package/lib/module/index.js +3 -1
  198. package/lib/module/index.js.map +1 -1
  199. package/lib/module/json-import.d.js +2 -0
  200. package/lib/module/json-import.d.js.map +1 -0
  201. package/lib/typescript/components/Advice/Advice.d.ts +7 -3
  202. package/lib/typescript/components/Advice/Advice.d.ts.map +1 -1
  203. package/lib/typescript/components/accordion/RawAccordion.d.ts +2 -2
  204. package/lib/typescript/components/accordion/RawAccordion.d.ts.map +1 -1
  205. package/lib/typescript/components/buttons/ButtonLink.d.ts.map +1 -1
  206. package/lib/typescript/components/buttons/IconButton.d.ts.map +1 -1
  207. package/lib/typescript/components/buttons/IconButtonContained.d.ts +15 -0
  208. package/lib/typescript/components/buttons/IconButtonContained.d.ts.map +1 -0
  209. package/lib/typescript/components/buttons/IconButtonSolid.d.ts +15 -0
  210. package/lib/typescript/components/buttons/IconButtonSolid.d.ts.map +1 -0
  211. package/lib/typescript/components/buttons/index.d.ts +4 -2
  212. package/lib/typescript/components/buttons/index.d.ts.map +1 -1
  213. package/lib/typescript/components/checkbox/AnimatedCheckbox.d.ts.map +1 -1
  214. package/lib/typescript/components/icons/Icon.d.ts +16 -3
  215. package/lib/typescript/components/icons/Icon.d.ts.map +1 -1
  216. package/lib/typescript/components/icons/index.d.ts +0 -1
  217. package/lib/typescript/components/icons/index.d.ts.map +1 -1
  218. package/lib/typescript/components/icons/svg/IconCheckTick.d.ts +5 -0
  219. package/lib/typescript/components/icons/svg/IconCheckTick.d.ts.map +1 -0
  220. package/lib/typescript/components/icons/svg/IconCheckTickBig.d.ts +5 -0
  221. package/lib/typescript/components/icons/svg/IconCheckTickBig.d.ts.map +1 -0
  222. package/lib/typescript/components/icons/svg/IconMerchant.d.ts +5 -0
  223. package/lib/typescript/components/icons/svg/IconMerchant.d.ts.map +1 -0
  224. package/lib/typescript/components/icons/svg/IconSystemAppsAndroid.d.ts +5 -0
  225. package/lib/typescript/components/icons/svg/IconSystemAppsAndroid.d.ts.map +1 -0
  226. package/lib/typescript/components/icons/svg/IconSystemNotificationsInstructions.d.ts +5 -0
  227. package/lib/typescript/components/icons/svg/IconSystemNotificationsInstructions.d.ts.map +1 -0
  228. package/lib/typescript/components/icons/svg/IconSystemSettingsAndroid.d.ts +5 -0
  229. package/lib/typescript/components/icons/svg/IconSystemSettingsAndroid.d.ts.map +1 -0
  230. package/lib/typescript/components/icons/svg/IconSystemSettingsiOS.d.ts +5 -0
  231. package/lib/typescript/components/icons/svg/IconSystemSettingsiOS.d.ts.map +1 -0
  232. package/lib/typescript/components/icons/svg/IconSystemToggleInstructions.d.ts +5 -0
  233. package/lib/typescript/components/icons/svg/IconSystemToggleInstructions.d.ts.map +1 -0
  234. package/lib/typescript/components/index.d.ts +13 -13
  235. package/lib/typescript/components/index.d.ts.map +1 -1
  236. package/lib/typescript/components/layout/GradientBottomActions.d.ts +22 -0
  237. package/lib/typescript/components/layout/GradientBottomActions.d.ts.map +1 -0
  238. package/lib/typescript/components/layout/GradientScrollView.d.ts +14 -0
  239. package/lib/typescript/components/layout/GradientScrollView.d.ts.map +1 -0
  240. package/lib/typescript/components/layout/HeaderFirstLevel.d.ts +11 -0
  241. package/lib/typescript/components/layout/HeaderFirstLevel.d.ts.map +1 -0
  242. package/lib/typescript/components/layout/index.d.ts +2 -0
  243. package/lib/typescript/components/layout/index.d.ts.map +1 -0
  244. package/lib/typescript/components/listitems/ListItemCheckbox.d.ts +21 -0
  245. package/lib/typescript/components/listitems/ListItemCheckbox.d.ts.map +1 -0
  246. package/lib/typescript/components/listitems/ListItemInfo.d.ts.map +1 -1
  247. package/lib/typescript/components/listitems/ListItemInfoCopy.d.ts.map +1 -1
  248. package/lib/typescript/components/listitems/ListItemRadio.d.ts +22 -0
  249. package/lib/typescript/components/listitems/ListItemRadio.d.ts.map +1 -0
  250. package/lib/typescript/components/listitems/ListItemSwitch.d.ts +18 -0
  251. package/lib/typescript/components/listitems/ListItemSwitch.d.ts.map +1 -0
  252. package/lib/typescript/components/listitems/ListItemTransaction.d.ts.map +1 -1
  253. package/lib/typescript/components/listitems/index.d.ts +3 -0
  254. package/lib/typescript/components/listitems/index.d.ts.map +1 -1
  255. package/lib/typescript/components/logos/svg/LogoPaymentExtMaestro.d.ts.map +1 -1
  256. package/lib/typescript/components/logos/svg/LogoPaymentExtMastercard.d.ts +2 -2
  257. package/lib/typescript/components/logos/svg/LogoPaymentExtMastercard.d.ts.map +1 -1
  258. package/lib/typescript/components/logos/svg/LogoPaymentExtPayPal.d.ts.map +1 -1
  259. package/lib/typescript/components/logos/svg/LogoPaymentMaestro.d.ts.map +1 -1
  260. package/lib/typescript/components/logos/svg/LogoPaymentMastercard.d.ts.map +1 -1
  261. package/lib/typescript/components/radio/AnimatedRadio.d.ts.map +1 -1
  262. package/lib/typescript/components/radio/RadioGroup.d.ts +22 -0
  263. package/lib/typescript/components/radio/RadioGroup.d.ts.map +1 -0
  264. package/lib/typescript/components/radio/index.d.ts +1 -0
  265. package/lib/typescript/components/radio/index.d.ts.map +1 -1
  266. package/lib/typescript/components/typography/H3.d.ts +11 -30
  267. package/lib/typescript/components/typography/H3.d.ts.map +1 -1
  268. package/lib/typescript/components/typography/Link.d.ts +4 -4
  269. package/lib/typescript/components/typography/Link.d.ts.map +1 -1
  270. package/lib/typescript/core/IOColors.d.ts +2 -1
  271. package/lib/typescript/core/IOColors.d.ts.map +1 -1
  272. package/lib/typescript/core/IOSpacing.d.ts +1 -1
  273. package/lib/typescript/core/IOSpacing.d.ts.map +1 -1
  274. package/lib/typescript/core/IOStyles.d.ts +6 -2
  275. package/lib/typescript/core/IOStyles.d.ts.map +1 -1
  276. package/lib/typescript/index.d.ts +3 -1
  277. package/lib/typescript/index.d.ts.map +1 -1
  278. package/package.json +12 -8
  279. package/src/components/Advice/Advice.tsx +19 -23
  280. package/src/components/Advice/__test__/advice.test.tsx +4 -2
  281. package/src/components/accordion/RawAccordion.tsx +6 -6
  282. package/src/components/badge/__test__/badge.test.tsx +4 -2
  283. package/src/components/buttons/ButtonLink.tsx +177 -177
  284. package/src/components/buttons/IconButton.tsx +9 -6
  285. package/src/components/buttons/IconButtonContained.tsx +201 -0
  286. package/src/components/buttons/IconButtonSolid.tsx +168 -0
  287. package/src/components/buttons/__test__/__snapshots__/button.test.tsx.snap +370 -0
  288. package/src/components/buttons/__test__/button.test.tsx +59 -4
  289. package/src/components/buttons/index.tsx +5 -3
  290. package/src/components/checkbox/AnimatedCheckbox.tsx +6 -8
  291. package/src/components/icons/Icon.tsx +37 -8
  292. package/src/components/icons/index.tsx +1 -2
  293. package/src/components/icons/svg/IconCheckTick.tsx +16 -0
  294. package/src/components/icons/svg/{IconCompleted.tsx → IconCheckTickBig.tsx} +2 -2
  295. package/src/components/icons/svg/IconMerchant.tsx +16 -0
  296. package/src/components/icons/svg/IconSystemAppsAndroid.tsx +17 -0
  297. package/src/components/icons/svg/IconSystemNotificationsInstructions.tsx +28 -0
  298. package/src/components/icons/svg/IconSystemSettingsAndroid.tsx +15 -0
  299. package/src/components/icons/svg/IconSystemSettingsiOS.tsx +58 -0
  300. package/src/components/icons/svg/IconSystemToggleInstructions.tsx +18 -0
  301. package/src/components/index.tsx +13 -13
  302. package/src/components/layout/GradientBottomActions.tsx +119 -0
  303. package/src/components/layout/GradientScrollView.tsx +167 -0
  304. package/src/components/layout/HeaderFirstLevel.tsx +76 -0
  305. package/src/components/layout/index.tsx +1 -0
  306. package/src/components/listitems/ListItemCheckbox.tsx +182 -0
  307. package/src/components/listitems/ListItemInfo.tsx +53 -58
  308. package/src/components/listitems/ListItemInfoCopy.tsx +122 -127
  309. package/src/components/listitems/ListItemRadio.tsx +185 -0
  310. package/src/components/listitems/ListItemSwitch.tsx +109 -0
  311. package/src/components/listitems/ListItemTransaction.tsx +154 -151
  312. package/src/components/listitems/__test__/__snapshots__/listitem.test.tsx.snap +0 -14
  313. package/src/components/listitems/index.tsx +3 -0
  314. package/src/components/logos/svg/LogoPaymentExtMaestro.tsx +3 -20
  315. package/src/components/logos/svg/LogoPaymentExtMastercard.tsx +5 -22
  316. package/src/components/logos/svg/LogoPaymentExtPayPal.tsx +9 -31
  317. package/src/components/logos/svg/LogoPaymentMaestro.tsx +8 -6
  318. package/src/components/logos/svg/LogoPaymentMastercard.tsx +8 -6
  319. package/src/components/logos/svg/LogoPaymentPayPal.tsx +5 -5
  320. package/src/components/radio/AnimatedRadio.tsx +6 -8
  321. package/src/components/radio/RadioGroup.tsx +43 -0
  322. package/src/components/radio/index.tsx +1 -0
  323. package/src/components/typography/H3.tsx +25 -91
  324. package/src/components/typography/Link.tsx +23 -30
  325. package/src/components/typography/__test__/__snapshots__/typography.test.tsx.snap +50 -45
  326. package/src/core/IOColors.ts +2 -2
  327. package/src/core/IOSpacing.ts +2 -2
  328. package/src/core/IOStyles.ts +9 -0
  329. package/src/index.tsx +4 -1
  330. package/src/json-import.d.ts +13 -0
  331. package/lib/commonjs/components/icons/svg/LegIconChevronLeft.js.map +0 -1
  332. package/lib/commonjs/components/icons/svg/LegIconSearch.js.map +0 -1
  333. package/lib/module/components/icons/svg/LegIconChevronLeft.js.map +0 -1
  334. package/lib/module/components/icons/svg/LegIconSearch.js.map +0 -1
  335. package/lib/typescript/components/icons/svg/IconCompleted.d.ts +0 -5
  336. package/lib/typescript/components/icons/svg/IconCompleted.d.ts.map +0 -1
  337. package/lib/typescript/components/icons/svg/LegIconChevronLeft.d.ts +0 -5
  338. package/lib/typescript/components/icons/svg/LegIconChevronLeft.d.ts.map +0 -1
  339. package/lib/typescript/components/icons/svg/LegIconSearch.d.ts +0 -5
  340. package/lib/typescript/components/icons/svg/LegIconSearch.d.ts.map +0 -1
  341. package/src/components/icons/svg/LegIconChevronLeft.tsx +0 -14
  342. package/src/components/icons/svg/LegIconSearch.tsx +0 -22
@@ -0,0 +1,28 @@
1
+ import React from "react";
2
+ import { Svg, Path, Rect, Circle } from "react-native-svg";
3
+ import { SVGIconProps } from "../Icon";
4
+
5
+ const IconSystemNotificationsInstructions = ({
6
+ size,
7
+ style,
8
+ ...props
9
+ }: SVGIconProps) => (
10
+ <Svg width={size} height={size} viewBox="0 0 24 24" style={style} {...props}>
11
+ <Rect width={size} height={size} fill="#EB4E3E" rx="4.364" />
12
+ <Path
13
+ stroke="#fff"
14
+ stroke-width="1.091"
15
+ d="M4.909 8.727c0-1.044 0-1.772.075-2.321.072-.534.203-.816.404-1.018.201-.2.484-.332 1.018-.404.549-.074 1.277-.075 2.32-.075h6.546c1.044 0 1.772.001 2.322.075.533.072.816.203 1.017.404.202.202.333.484.404 1.018.074.55.076 1.277.076 2.321v6.546c0 1.044-.002 1.772-.076 2.321-.071.534-.202.816-.404 1.018-.201.201-.484.332-1.017.404-.55.074-1.278.075-2.322.075H8.727c-1.044 0-1.772-.001-2.321-.075-.534-.072-.817-.203-1.018-.404-.201-.201-.332-.484-.404-1.018-.074-.55-.075-1.277-.075-2.321V8.727Z"
16
+ />
17
+ <Circle
18
+ cx="17.454"
19
+ cy="7.091"
20
+ r="3.818"
21
+ fill="#fff"
22
+ stroke="#EB4E3E"
23
+ stroke-width="1.091"
24
+ />
25
+ </Svg>
26
+ );
27
+
28
+ export default IconSystemNotificationsInstructions;
@@ -0,0 +1,15 @@
1
+ import React from "react";
2
+ import { Svg, Path, Rect } from "react-native-svg";
3
+ import { SVGIconProps } from "../Icon";
4
+
5
+ const IconSystemSettingsAndroid = ({ size, style, ...props }: SVGIconProps) => (
6
+ <Svg width={size} height={size} viewBox="0 0 24 24" style={style} {...props}>
7
+ <Rect width={size} height={size} fill="#418DAF" rx="8" />
8
+ <Path
9
+ fill="#fff"
10
+ d="M17.95 12.784c.033-.25.05-.509.05-.784a4.81 4.81 0 0 0-.058-.783L19.633 9.9a.409.409 0 0 0 .1-.508l-1.6-2.767a.407.407 0 0 0-.491-.183l-1.992.8a5.885 5.885 0 0 0-1.35-.783L14 4.342A.403.403 0 0 0 13.6 4h-3.2c-.2 0-.358.142-.392.342l-.3 2.117c-.491.2-.941.475-1.35.783l-1.991-.8a.398.398 0 0 0-.492.183L4.283 9.392c-.1.175-.066.392.1.508l1.692 1.317A4.89 4.89 0 0 0 6 12c0 .259.017.534.058.784L4.367 14.1a.409.409 0 0 0-.1.509l1.6 2.766c.1.184.308.242.491.184l1.992-.8c.417.316.858.583 1.35.783l.3 2.117c.042.2.2.341.4.341h3.2c.2 0 .367-.141.392-.341l.3-2.117c.491-.2.941-.467 1.35-.783l1.991.8c.184.066.392 0 .492-.184l1.6-2.766c.1-.184.058-.392-.1-.509l-1.675-1.316ZM12 15c-1.65 0-3-1.35-3-3s1.35-3 3-3 3 1.35 3 3-1.35 3-3 3Z"
11
+ />
12
+ </Svg>
13
+ );
14
+
15
+ export default IconSystemSettingsAndroid;
@@ -0,0 +1,58 @@
1
+ import React from "react";
2
+ import { Svg, Path, Defs, LinearGradient, Stop } from "react-native-svg";
3
+ import { SVGIconProps } from "../Icon";
4
+
5
+ const IconSystemSettingsiOS = ({ size, style, ...props }: SVGIconProps) => (
6
+ <Svg width={size} height={size} viewBox="0 0 24 24" style={style} {...props}>
7
+ <Path
8
+ d="M15.6266 0c2.4 0 3.6 0 4.9067.4 1.4133.50667 2.5333 1.62666 3.04 3.04C24 4.74666 24 5.97333 24 8.37332v7.25328c0 2.4 0 3.6-.4 4.9067-.5067 1.4133-1.6267 2.5333-3.04 3.04C19.2266 24 18.0266 24 15.6266 24H8.37332c-2.39999 0-3.59999 0-4.90666-.4C2.02666 23.0666.93333 21.9733.4 20.5333c-.4-1.28-.4-2.48-.4-4.9067V8.37332c0-2.39999 0-3.59999.4-4.90666.53333-1.41333 1.62666-2.53333 3.06666-3.04C4.74666 0 5.94666 0 8.37332 0h7.25328Z"
9
+ fill="url(#b)"
10
+ />
11
+ <Path
12
+ d="M11.9996 22.4001c5.7438 0 10.4-4.6563 10.4-10.4 0-5.74377-4.6562-10.4-10.4-10.4-5.74376 0-10.39999 4.65623-10.39999 10.4 0 5.7437 4.65623 10.4 10.39999 10.4Z"
13
+ fill="#2E2E30"
14
+ />
15
+ <Path
16
+ d="m12.6997 6.46427.0792.01114.1849.02597.2887-.71342c.0862-.23024.1353-.19641.1321.01856l-.0247.75053c.0792.01114.1811.05239.2603.06352l.3643-.67588c.1089-.20012.1617-.1927.1283.04497l-.1303.73569c.0755.03754.1774.07879.2566.08992l.4361-.61193c.1353-.19641.1844-.16258.1246.07137l-.2095.72456c.0755.03754.1774.07879.2492.14274l.4852-.5781c.158-.1663.2071-.13247.1246.07137l-.2888.71342c.0718.06395.1474.10149.2192.16543l.5569-.51415c.1844-.16258.2336-.12875.1209.09778l-.3605.64947c.0718.06395.1436.1279.189.18813l.625-.42379c.1807-.13618.2298-.10235.0945.09406l-.4699.66104c.0718.06394.1172.12418.1853.21454l.6667-.33716c.2034-.10606.2525-.07223.0908.12048l-.5079.54798c.0454.06023.1135.15059.1552.23723l.7121-.27691c.2261-.07594.2451-.01942.0644.11676l-.5797.48403.1251.25994.7274-.19399c.2224-.04953.2414.007.0644.11676l-.6251.4238c.0417.08667.057.16957.0986.25627l.7427-.1111c.2187-.0231.2641.0371.0343.1395l-.6668.3371c.0153.0829.057.1696.0686.2789l.7278-.0054c.2414.007.2339.0598.0342.1395l-.682.2542c.0153.0829.0269.1923.0421.2752l.7431.0775c.2377.0334.2303.0862.0079.1357l-.7237.1676c.0153.083.0004.1886-.0107.2678l.7019.1794c.2339.0598.2265.1127-.0186.1321l-.739.0846c-.0111.0792-.026.1849-.0371.2641l-.0037.0264.6944.2322c.2303.0862.2229.1391-.0185.1321l-.7279.0054c-.0148.1056-.0523.1811-.0672.2868l.6532.3341c.2001.1089.1927.1617-.045.1283l-.713-.1002c-.0375.0755-.0523.1812-.0899.2567l.6157.4097c.1964.1353.1625.1844-.045.1283l-.7019-.1795c-.0375.0756-.0788.1775-.1163.253l.5517.4815c.1663.158.1589.2108-.0714.1246l-.6643-.255c-.0639.0718-.1052.1737-.1691.2455l.4914.5269c.1663.158.1288.2335-.0978.1209l-.6647-.4435c-.064.0718-.1279.1436-.1919.2154l.4313.5723c.1361.1807.1023.2298-.0941.0944l-.5892-.4059c-.064.0718-.1279.1436-.2146.1853l.371.6176c.1061.2034.0722.2525-.1205.0908l-.5517-.4815c-.0903.0681-.1506.1135-.2372.1552l.2843.6593c.1024.2298.0459.2488-.1167.0644l-.4915-.5269c-.0866.0417-.1733.0834-.2599.1251l.1977.701c.0759.2261.0194.2451-.1168.0643l-.4011-.5949c-.0866.0417-.1733.0834-.2863.1213l.1148.7163c.0495.2224-.007.2414-.1395.0343l-.3409-.6404c-.0829.0153-.196.0533-.2789.0685l.0356.7052c.0194.2451-.0599.2339-.1395.0342l-.2654-.6028c-.0829.0153-.1922.0269-.2752.0422l-.0474.7204c-.007.2413-.0862.2302-.1357.0078l-.1977-.701c-.0829.0153-.1886.0004-.2979.012l-.153.7056c-.0334.2376-.1126.2265-.1358.0078l-.0582-.7352c-.1056-.0149-.1849-.026-.2942-.0144l-.2322.6944c-.0863.2302-.1391.2228-.1321-.0186l-.0054-.7278c-.1056-.0149-.1848-.026-.2868-.0672l-.3077.6569c-.0825.2038-.1617.1927-.1283-.045l.0738-.7167c-.102-.0413-.1812-.0524-.2567-.0899l-.40965.6156c-.10892.2001-.18814.189-.12833-.045l.15302-.7055c-.07551-.0376-.17743-.0788-.25294-.1164l-.45877.5819c-.13532.1964-.21083.1588-.12461-.0714l.23224-.6945c-.07551-.0375-.14731-.1014-.24923-.1427l-.53057.5179c-.15801.1663-.20711.1324-.12461-.0714l.33416-.6532c-.0718-.0639-.1436-.1279-.21911-.1654l-.57596.4576c-.18071.1362-.22981.1024-.0945-.0941l.40967-.6156c-.0718-.064-.14359-.1279-.18528-.2145l-.61021.3181c-.20712.1325-.25251.0723-.0945-.094l.45877-.5819c-.0718-.0639-.11348-.1505-.15887-.2108l-.66303.3108c-.20341.106-.2488.0458-.09079-.1205l.53057-.5179c-.04168-.0866-.08707-.1469-.12875-.2335l-.70471.2241c-.2261.0759-.24509.0194-.06438-.1168l.60237-.4539c-.04168-.0866-.08336-.1733-.09863-.2562l-.71999.1412c-.22239.0495-.24138-.007-.03426-.1395l.64405-.3673c-.04168-.0866-.05695-.1695-.07223-.2525l-.78807.0509c-.24509.0194-.26407-.0372-.03426-.1395l.68573-.2806c-.01527-.083-.02684-.1923-.04211-.2752l-.75053-.0247c-.24138-.007-.23396-.0598-.00785-.1358l.70471-.2241c-.01527-.0829-.00043-.1885-.0157-.2715l-.73569-.1303c-.23766-.0334-.22653-.1126-.00785-.1357l.74639-.1375c.01114-.0792-.00042-.1886.01071-.2678l-.72456-.2095c-.23395-.0598-.22281-.1391.01856-.1321l.75796-.0281c.01113-.0792.02598-.1848.03711-.2641l-.68701-.285c-.20384-.0825-.1927-.1617.04496-.1283l.74682.0511c.01114-.0793.05239-.1812.08993-.2567l-.64947-.36055c-.20013-.10891-.1927-.16173.04496-.12832l.73569.13032c.03754-.07551.07879-.17743.11633-.25294l-.61193-.43607c-.19641-.13532-.16258-.18443.07137-.12462l.72084.23595c.03754-.07551.10149-.1473.13903-.22281l-.54798-.50788c-.16629-.15801-.13246-.20712.07137-.12461l.6833.31146c.06395-.0718.10149-.14731.16544-.21911l-.48403-.57967c-.16259-.18442-.10235-.22981.09406-.09449l.64576.38697c.06395-.0718.12419-.11719.18814-.18899l-.42009-.65147c-.13247-.20712-.07594-.2261.09407-.0945l.60822.46248c.06394-.07179.15059-.11348.21454-.18527l-.32603-.74597c-.10605-.20341-.04581-.2488.12048-.09078l.54427.53428c.06024-.04539.14688-.08707.23353-.12875l-.25052-.70843c-.07593-.2261-.01941-.24509.11677-.06438l.48032.60608c.08665-.04168.17329-.08336.23353-.12875l-.16387-.7501c-.04953-.22239.00699-.24138.14317-.06067l.39364.64776c.0867-.04168.1696-.05695.2525-.07223l-.0809-.76537c-.0194-.24509.0371-.26408.1395-.03426l.307.68944c.0829-.01528.1659-.03055.2488-.04582l.0247-.75054c.007-.24137.0598-.23395.1357-.00785l.2204.73112c.083-.01527.1923-.02683.2715-.0157l.1077-.7658c.0334-.23767.0862-.23024.1357-.00785l.1639.7501c.0792.01113.1885-.00043.2678.01071l.1831-.72827c.0598-.23395.1126-.22653.132.01856l.0884.71256ZM11.3612 16.5629c2.5087.3526 4.8278-1.395 5.1804-3.9037.3525-2.5086-1.395-4.82775-3.9037-5.18032-2.5087-.35258-4.85051 1.36489-5.20308 3.87352-.35257 2.5087 1.4177 4.858 3.92638 5.2105Z"
17
+ fill="#000"
18
+ />
19
+ <Path
20
+ d="m12.6997 6.46427.0792.01114.1849.02597.2887-.71342c.0862-.23024.1353-.19641.1321.01856l-.0247.75053c.0792.01114.1811.05239.2603.06352l.3643-.67588c.1089-.20012.1617-.1927.1283.04497l-.1303.73569c.0755.03754.1774.07879.2566.08992l.4361-.61193c.1353-.19641.1844-.16258.1246.07137l-.2095.72456c.0755.03754.1774.07879.2492.14274l.4852-.5781c.158-.1663.2071-.13247.1246.07137l-.2888.71342c.0718.06395.1474.10149.2192.16543l.5569-.51415c.1844-.16258.2336-.12875.1209.09778l-.3605.64947c.0718.06395.1436.1279.189.18813l.625-.42379c.1807-.13618.2298-.10235.0945.09406l-.4699.66104c.0718.06394.1172.12418.1853.21454l.6667-.33716c.2034-.10606.2525-.07223.0908.12048l-.5079.54798c.0454.06023.1135.15059.1552.23723l.7121-.27691c.2261-.07594.2451-.01942.0644.11676l-.5797.48403.1251.25994.7274-.19399c.2224-.04953.2414.007.0644.11676l-.6251.4238c.0417.08667.057.16957.0986.25627l.7427-.1111c.2187-.0231.2641.0371.0343.1395l-.6668.3371c.0153.0829.057.1696.0686.2789l.7278-.0054c.2414.007.2339.0598.0342.1395l-.682.2542c.0153.0829.0269.1923.0421.2752l.7431.0775c.2377.0334.2303.0862.0079.1357l-.7237.1676c.0153.083.0004.1886-.0107.2678l.7019.1794c.2339.0598.2265.1127-.0186.1321l-.739.0846c-.0111.0792-.026.1849-.0371.2641l-.0037.0264.6944.2322c.2303.0862.2229.1391-.0185.1321l-.7279.0054c-.0148.1056-.0523.1811-.0672.2868l.6532.3341c.2001.1089.1927.1617-.045.1283l-.713-.1002c-.0375.0755-.0523.1812-.0899.2567l.6157.4097c.1964.1353.1625.1844-.045.1283l-.7019-.1795c-.0375.0756-.0788.1775-.1163.253l.5517.4815c.1663.158.1589.2108-.0714.1246l-.6643-.255c-.0639.0718-.1052.1737-.1691.2455l.4914.5269c.1663.158.1288.2335-.0978.1209l-.6647-.4435c-.064.0718-.1279.1436-.1919.2154l.4313.5723c.1361.1807.1023.2298-.0941.0944l-.5892-.4059c-.064.0718-.1279.1436-.2146.1853l.371.6176c.1061.2034.0722.2525-.1205.0908l-.5517-.4815c-.0903.0681-.1506.1135-.2372.1552l.2843.6593c.1024.2298.0459.2488-.1167.0644l-.4915-.5269c-.0866.0417-.1733.0834-.2599.1251l.1977.701c.0759.2261.0194.2451-.1168.0643l-.4011-.5949c-.0866.0417-.1733.0834-.2863.1213l.1148.7163c.0495.2224-.007.2414-.1395.0343l-.3409-.6404c-.0829.0153-.196.0533-.2789.0685l.0356.7052c.0194.2451-.0599.2339-.1395.0342l-.2654-.6028c-.0829.0153-.1922.0269-.2752.0422l-.0474.7204c-.007.2413-.0862.2302-.1357.0078l-.1977-.701c-.0829.0153-.1886.0004-.2979.012l-.153.7056c-.0334.2376-.1126.2265-.1358.0078l-.0582-.7352c-.1056-.0149-.1849-.026-.2942-.0144l-.2322.6944c-.0863.2302-.1391.2228-.1321-.0186l-.0054-.7278c-.1056-.0149-.1848-.026-.2868-.0672l-.3077.6569c-.0825.2038-.1617.1927-.1283-.045l.0738-.7167c-.102-.0413-.1812-.0524-.2567-.0899l-.40965.6156c-.10892.2001-.18814.189-.12833-.045l.15302-.7055c-.07551-.0376-.17743-.0788-.25294-.1164l-.45877.5819c-.13532.1964-.21083.1588-.12461-.0714l.23224-.6945c-.07551-.0375-.14731-.1014-.24923-.1427l-.53057.5179c-.15801.1663-.20711.1324-.12461-.0714l.33416-.6532c-.0718-.0639-.1436-.1279-.21911-.1654l-.57596.4576c-.18071.1362-.22981.1024-.0945-.0941l.40967-.6156c-.0718-.064-.14359-.1279-.18528-.2145l-.61021.3181c-.20712.1325-.25251.0723-.0945-.094l.45877-.5819c-.0718-.0639-.11348-.1505-.15887-.2108l-.66303.3108c-.20341.106-.2488.0458-.09079-.1205l.53057-.5179c-.04168-.0866-.08707-.1469-.12875-.2335l-.70471.2241c-.2261.0759-.24509.0194-.06438-.1168l.60237-.4539c-.04168-.0866-.08336-.1733-.09863-.2562l-.71999.1412c-.22239.0495-.24138-.007-.03426-.1395l.64405-.3673c-.04168-.0866-.05695-.1695-.07223-.2525l-.78807.0509c-.24509.0194-.26407-.0372-.03426-.1395l.68573-.2806c-.01527-.083-.02684-.1923-.04211-.2752l-.75053-.0247c-.24138-.007-.23396-.0598-.00785-.1358l.70471-.2241c-.01527-.0829-.00043-.1885-.0157-.2715l-.73569-.1303c-.23766-.0334-.22653-.1126-.00785-.1357l.74639-.1375c.01114-.0792-.00042-.1886.01071-.2678l-.72456-.2095c-.23395-.0598-.22281-.1391.01856-.1321l.75796-.0281c.01113-.0792.02598-.1848.03711-.2641l-.68701-.285c-.20384-.0825-.1927-.1617.04496-.1283l.74682.0511c.01114-.0793.05239-.1812.08993-.2567l-.64947-.36055c-.20013-.10891-.1927-.16173.04496-.12832l.73569.13032c.03754-.07551.07879-.17743.11633-.25294l-.61193-.43607c-.19641-.13532-.16258-.18443.07137-.12462l.72084.23595c.03754-.07551.10149-.1473.13903-.22281l-.54798-.50788c-.16629-.15801-.13246-.20712.07137-.12461l.6833.31146c.06395-.0718.10149-.14731.16544-.21911l-.48403-.57967c-.16259-.18442-.10235-.22981.09406-.09449l.64576.38697c.06395-.0718.12419-.11719.18814-.18899l-.42009-.65147c-.13247-.20712-.07594-.2261.09407-.0945l.60822.46248c.06394-.07179.15059-.11348.21454-.18527l-.32603-.74597c-.10605-.20341-.04581-.2488.12048-.09078l.54427.53428c.06024-.04539.14688-.08707.23353-.12875l-.25052-.70843c-.07593-.2261-.01941-.24509.11677-.06438l.48032.60608c.08665-.04168.17329-.08336.23353-.12875l-.16387-.7501c-.04953-.22239.00699-.24138.14317-.06067l.39364.64776c.0867-.04168.1696-.05695.2525-.07223l-.0809-.76537c-.0194-.24509.0371-.26408.1395-.03426l.307.68944c.0829-.01528.1659-.03055.2488-.04582l.0247-.75054c.007-.24137.0598-.23395.1357-.00785l.2204.73112c.083-.01527.1923-.02683.2715-.0157l.1077-.7658c.0334-.23767.0862-.23024.1357-.00785l.1639.7501c.0792.01113.1885-.00043.2678.01071l.1831-.72827c.0598-.23395.1126-.22653.132.01856l.0884.71256ZM11.3612 16.5629c2.5087.3526 4.8278-1.395 5.1804-3.9037.3525-2.5086-1.395-4.82775-3.9037-5.18032-2.5087-.35258-4.85051 1.36489-5.20308 3.87352-.35257 2.5087 1.4177 4.858 3.92638 5.2105Z"
21
+ fill="#7F7F7F"
22
+ />
23
+ <Path
24
+ d="m12.6997 6.46427.0792.01114.1849.02597.2887-.71342c.0862-.23024.1353-.19641.1321.01856l-.0247.75053c.0792.01114.1811.05239.2603.06352l.3643-.67588c.1089-.20012.1617-.1927.1283.04497l-.1303.73569c.0755.03754.1774.07879.2566.08992l.4361-.61193c.1353-.19641.1844-.16258.1246.07137l-.2095.72456c.0755.03754.1774.07879.2492.14274l.4852-.5781c.158-.1663.2071-.13247.1246.07137l-.2888.71342c.0718.06395.1474.10149.2192.16543l.5569-.51415c.1844-.16258.2336-.12875.1209.09778l-.3605.64947c.0718.06395.1436.1279.189.18813l.625-.42379c.1807-.13618.2298-.10235.0945.09406l-.4699.66104c.0718.06394.1172.12418.1853.21454l.6667-.33716c.2034-.10606.2525-.07223.0908.12048l-.5079.54798c.0454.06023.1135.15059.1552.23723l.7121-.27691c.2261-.07594.2451-.01942.0644.11676l-.5797.48403.1251.25994.7274-.19399c.2224-.04953.2414.007.0644.11676l-.6251.4238c.0417.08667.057.16957.0986.25627l.7427-.1111c.2187-.0231.2641.0371.0343.1395l-.6668.3371c.0153.0829.057.1696.0686.2789l.7278-.0054c.2414.007.2339.0598.0342.1395l-.682.2542c.0153.0829.0269.1923.0421.2752l.7431.0775c.2377.0334.2303.0862.0079.1357l-.7237.1676c.0153.083.0004.1886-.0107.2678l.7019.1794c.2339.0598.2265.1127-.0186.1321l-.739.0846c-.0111.0792-.026.1849-.0371.2641l-.0037.0264.6944.2322c.2303.0862.2229.1391-.0185.1321l-.7279.0054c-.0148.1056-.0523.1811-.0672.2868l.6532.3341c.2001.1089.1927.1617-.045.1283l-.713-.1002c-.0375.0755-.0523.1812-.0899.2567l.6157.4097c.1964.1353.1625.1844-.045.1283l-.7019-.1795c-.0375.0756-.0788.1775-.1163.253l.5517.4815c.1663.158.1589.2108-.0714.1246l-.6643-.255c-.0639.0718-.1052.1737-.1691.2455l.4914.5269c.1663.158.1288.2335-.0978.1209l-.6647-.4435c-.064.0718-.1279.1436-.1919.2154l.4313.5723c.1361.1807.1023.2298-.0941.0944l-.5892-.4059c-.064.0718-.1279.1436-.2146.1853l.371.6176c.1061.2034.0722.2525-.1205.0908l-.5517-.4815c-.0903.0681-.1506.1135-.2372.1552l.2843.6593c.1024.2298.0459.2488-.1167.0644l-.4915-.5269c-.0866.0417-.1733.0834-.2599.1251l.1977.701c.0759.2261.0194.2451-.1168.0643l-.4011-.5949c-.0866.0417-.1733.0834-.2863.1213l.1148.7163c.0495.2224-.007.2414-.1395.0343l-.3409-.6404c-.0829.0153-.196.0533-.2789.0685l.0356.7052c.0194.2451-.0599.2339-.1395.0342l-.2654-.6028c-.0829.0153-.1922.0269-.2752.0422l-.0474.7204c-.007.2413-.0862.2302-.1357.0078l-.1977-.701c-.0829.0153-.1886.0004-.2979.012l-.153.7056c-.0334.2376-.1126.2265-.1358.0078l-.0582-.7352c-.1056-.0149-.1849-.026-.2942-.0144l-.2322.6944c-.0863.2302-.1391.2228-.1321-.0186l-.0054-.7278c-.1056-.0149-.1848-.026-.2868-.0672l-.3077.6569c-.0825.2038-.1617.1927-.1283-.045l.0738-.7167c-.102-.0413-.1812-.0524-.2567-.0899l-.40965.6156c-.10892.2001-.18814.189-.12833-.045l.15302-.7055c-.07551-.0376-.17743-.0788-.25294-.1164l-.45877.5819c-.13532.1964-.21083.1588-.12461-.0714l.23224-.6945c-.07551-.0375-.14731-.1014-.24923-.1427l-.53057.5179c-.15801.1663-.20711.1324-.12461-.0714l.33416-.6532c-.0718-.0639-.1436-.1279-.21911-.1654l-.57596.4576c-.18071.1362-.22981.1024-.0945-.0941l.40967-.6156c-.0718-.064-.14359-.1279-.18528-.2145l-.61021.3181c-.20712.1325-.25251.0723-.0945-.094l.45877-.5819c-.0718-.0639-.11348-.1505-.15887-.2108l-.66303.3108c-.20341.106-.2488.0458-.09079-.1205l.53057-.5179c-.04168-.0866-.08707-.1469-.12875-.2335l-.70471.2241c-.2261.0759-.24509.0194-.06438-.1168l.60237-.4539c-.04168-.0866-.08336-.1733-.09863-.2562l-.71999.1412c-.22239.0495-.24138-.007-.03426-.1395l.64405-.3673c-.04168-.0866-.05695-.1695-.07223-.2525l-.78807.0509c-.24509.0194-.26407-.0372-.03426-.1395l.68573-.2806c-.01527-.083-.02684-.1923-.04211-.2752l-.75053-.0247c-.24138-.007-.23396-.0598-.00785-.1358l.70471-.2241c-.01527-.0829-.00043-.1885-.0157-.2715l-.73569-.1303c-.23766-.0334-.22653-.1126-.00785-.1357l.74639-.1375c.01114-.0792-.00042-.1886.01071-.2678l-.72456-.2095c-.23395-.0598-.22281-.1391.01856-.1321l.75796-.0281c.01113-.0792.02598-.1848.03711-.2641l-.68701-.285c-.20384-.0825-.1927-.1617.04496-.1283l.74682.0511c.01114-.0793.05239-.1812.08993-.2567l-.64947-.36055c-.20013-.10891-.1927-.16173.04496-.12832l.73569.13032c.03754-.07551.07879-.17743.11633-.25294l-.61193-.43607c-.19641-.13532-.16258-.18443.07137-.12462l.72084.23595c.03754-.07551.10149-.1473.13903-.22281l-.54798-.50788c-.16629-.15801-.13246-.20712.07137-.12461l.6833.31146c.06395-.0718.10149-.14731.16544-.21911l-.48403-.57967c-.16259-.18442-.10235-.22981.09406-.09449l.64576.38697c.06395-.0718.12419-.11719.18814-.18899l-.42009-.65147c-.13247-.20712-.07594-.2261.09407-.0945l.60822.46248c.06394-.07179.15059-.11348.21454-.18527l-.32603-.74597c-.10605-.20341-.04581-.2488.12048-.09078l.54427.53428c.06024-.04539.14688-.08707.23353-.12875l-.25052-.70843c-.07593-.2261-.01941-.24509.11677-.06438l.48032.60608c.08665-.04168.17329-.08336.23353-.12875l-.16387-.7501c-.04953-.22239.00699-.24138.14317-.06067l.39364.64776c.0867-.04168.1696-.05695.2525-.07223l-.0809-.76537c-.0194-.24509.0371-.26408.1395-.03426l.307.68944c.0829-.01528.1659-.03055.2488-.04582l.0247-.75054c.007-.24137.0598-.23395.1357-.00785l.2204.73112c.083-.01527.1923-.02683.2715-.0157l.1077-.7658c.0334-.23767.0862-.23024.1357-.00785l.1639.7501c.0792.01113.1885-.00043.2678.01071l.1831-.72827c.0598-.23395.1126-.22653.132.01856l.0884.71256ZM11.3612 16.5629c2.5087.3526 4.8278-1.395 5.1804-3.9037.3525-2.5086-1.395-4.82775-3.9037-5.18032-2.5087-.35258-4.85051 1.36489-5.20308 3.87352-.35257 2.5087 1.4177 4.858 3.92638 5.2105Z"
25
+ fill="#777"
26
+ />
27
+ <Path
28
+ d="M21.3595 12.4797c.3467-.0533.3467-.1333 0-.2133l-.9867-.1867V11.5997l.96-.24c.3467-.08.32-.1867-.0266-.2133l-.9867-.08c-.0267-.16-.0267-.2934-.0533-.4534l.9333-.3466c.32-.1334.32-.2134-.0267-.2134l-.9866.0267c-.0267-.16001-.08-.29335-.1067-.45335l.88-.45333c.32-.16.2667-.24-.0533-.18667l-.9867.16c-.0533-.13333-.1067-.29333-.16-.42666l.8267-.56c.2933-.21334.24-.29333-.08-.18667l-.96.26667c-.08-.13333-.1334-.26667-.2134-.4l.7467-.66667c.2667-.24.2133-.32-.1067-.18666l-.9066.37333c-.08-.13333-.1867-.26667-.2667-.37333l.6667-.74667c.24-.26667.1866-.32-.1334-.16l-.9333.48c-.1067-.10667-.1867-.24-.2933-.34667l.5866-.82666c.2134-.29334.1334-.34667-.16-.16l-.8.58666c-.1066-.10666-.2133-.21333-.3466-.29333l.48-.88c.16-.32.08-.37333-.16-.13333l-.72.66666c-.1334-.08-.24-.18666-.3734-.26666l.3734-.93333c.1333-.32.0533-.37334-.1867-.10667l-.64.74666c-.1333-.07999-.2667-.13333-.4-.21333l.24-.96c.08-.34666 0-.37333-.1867-.08l-.5333.82667c-.1333-.05333-.2933-.10667-.4267-.16l.1334-.98667c.0533-.34666-.0267-.37333-.1867-.05333l-.4533.88c-.1334-.05333-.2934-.08-.4534-.10667l.0267-.98666c0-.34667-.08-.37334-.2133-.02667l-.3467.93333c-.16-.02666-.2933-.05333-.4533-.05333l-.16-.96c-.0267-.34667-.1334-.34667-.2134-.02667l-.24.96H11.8395l-.2133-.98666c-.08-.34667-.16-.34667-.2134 0l-.1066.98666c-.16 0-.2934.02667-.4534.05334l-.3466-.93334c-.1067-.32-.2134-.32-.2134.02667l.0267.98667c-.16.02666-.2933.05333-.45334.10666l-.42666-.90666c-.16-.32-.24-.29334-.21334.05333l.10667.98667c-.13333.05333-.29333.10666-.42666.16l-.53334-.82667c-.18666-.29333-.26666-.26667-.18666.08l.24.96c-.13334.05333-.26667.13333-.4.21333l-.64-.77333c-.21334-.26667-.29334-.21333-.18667.10667l.34667.93333c-.13334.08-.26667.16-.37334.24l-.71999-.69333c-.26667-.24-.32-.18667-.16001.13333l.45334.88c-.10667.10666-.24.18666-.34667.29333l-.8-.58667c-.29333-.21333-.34666-.13333-.16.13334l.56.82666c-.10666.10667-.21333.21334-.32.34667l-.85333-.50667c-.29333-.18666-.37333-.10666-.13333.16l.64.74667c-.08.10667-.18667.24-.26667.37333l-.90667-.4c-.32-.13333-.37333-.05333-.10666.18667l.74666.66667c-.08.13333-.16.26666-.21333.39999l-.96-.26666c-.34667-.10667-.37333 0-.08.18666l.8.56c-.05333.13334-.13333.26667-.18667.42667l-.98666-.16c-.34667-.05333-.37334.02667-.08.18667l.88.48c-.05334.13333-.08.29333-.13334.42666l-.98666-.02666c-.34667 0-.37333.08-.05334.21331l.93334.3467c-.02667.16-.05334.2933-.08.4533l-.98667.1334c-.34666.0266-.34666.1066-.02667.2133l.96.2667c0 .16-.02666.2933-.02666.4533l-.98667.1867c-.34666.0533-.34666.16 0 .2133l.98667.1333c0 .16.02666.2934.02666.4534l-.96.2933c-.34666.1066-.31999.1866.02667.2133l.98667.0267c.02666.16.05333.2933.08.4533l-.90667.4267c-.32.16-.29333.24.05333.2133l.98667-.1067c.05333.16.08.2934.13333.4534l-.85333.5066c-.29333.1867-.26667.2667.08.1867l.98667-.2133c.05333.1333.13333.2666.18666.4266l-.77333.6134c-.26667.2133-.24.2933.10667.1866l.93333-.32c.08.1334.16.2667.24.4l-.64.64c-.24.24-.18667.32.10667.16l.90666-.4266c.08.1333.18667.24.29334.3466l-.61334.7734c-.21333.2666-.16.3466.13334.16l.82666-.5334c.10667.1067.21333.2134.32.32l-.50666.8534c-.18667.2933-.10667.3466.16.1333l.77333-.64c.10666.1067.24.1867.37333.2933l-.42667.9067c-.16.32-.08.3733.16.1067l.69334-.72.4.24-.32.9333c-.10667.32-.02667.3733.18666.1067l.61334-.8c.13333.0533.26666.1333.42666.1866l-.18666.9867c-.08.3467.02666.3733.18666.08l.50667-.8533c.13333.0533.29333.1066.42667.1333l-.10667 1.0133c-.02667.3467.05333.3734.21333.0534l.39997-.9067c.16.0267.2934.0533.4534.08l.0533.9867c.0267.3466.1067.3466.2133.0266l.2667-.96c.16.0267.32.0267.4533.0267l.16.9867c.0534.3466.1334.3466.2134 0l.1866-.9867c.16 0 .2934 0 .4534-.0267l.2666.96c.1067.3467.1867.32.2134-.0266l.0533-.9867c.16-.0267.2933-.0533.4533-.08l.3734.9067c.1333.32.2133.2933.2133-.0534l-.1067-.9333c.16-.0267.2934-.08.4267-.1333l.5067.8533c.1866.2933.2666.2667.1866-.08l-.1866-.9867c.1333-.0533.2933-.1066.4266-.1866l.5867.8c.2133.2933.2933.24.1867-.1067l-.2667-.9067c.1333-.08.2667-.16.4-.24l.6667.72c.24.2667.32.2134.1866-.1066l-.4-.9067c.1334-.08.24-.1867.3734-.2667l.7733.64c.2667.2134.3467.16.16-.1333l-.5067-.8533.32-.32.8267.5333c.2933.1867.3467.1333.1333-.16l-.6133-.7733c.1067-.1067.1867-.24.2933-.3467l.9067.4533c.32.16.3733.08.1333-.16l-.72-.72c.08-.1333.16-.24.24-.3733l.9334.32c.32.1067.3733.0267.1066-.1867l-.7733-.6133c.08-.1333.1333-.2667.2133-.4267l.96.2134c.3467.08.3734 0 .08-.1867l-.8533-.5333c.0533-.1334.1067-.2934.16-.4267l.9867.1067c.3466.0266.3733-.0534.0533-.2134l-.9067-.4266c.0267-.16.08-.2934.1067-.4534l.9867-.0266c.3466 0 .3733-.1067.0266-.2133l-.9333-.2401c.0267-.1599.0267-.2933.0533-.4533l.9867-.1333ZM8.50617 17.173c-.26667.48-.96.5333-1.38667.2933-.29333-.16-.98666-.8266-1.62666-1.8666-.58667-1.0667-.90667-2.2667-.90667-3.5733 0-2.18671.93333-4.13338 2.45333-5.49338.48-.26666 1.14667-.21333 1.41333.24l2.63997 4.53338c.2134.3733.2134 1.0933-.0266 1.4666l-2.56003 4.4Zm9.20003-.48c-.8534 1.0133-1.9467 1.8133-3.2267 2.2667-1.6533.48-3.8133.5066-4.64.0533-.56-.2667-.77333-.8533-.50667-1.3333l2.61337-4.5334c.2133-.3733.7733-.6933 1.2-.6933h5.0933c.56 0 .9333.48.9333.96 0 .4267-.3466 1.8933-1.4666 3.28Zm-6.1067-4.6933c0-.2133.1867-.4.4-.4.2133 0 .4.1867.4.4 0 .2133-.1867.4-.4.4-.2133 0-.4-.1867-.4-.4Zm6.7467-.48h-5.3334c-.4533-.0267-.9866-.4-1.2-.8L9.2795 6.31969c-.26667-.48.02667-1.01333.45333-1.25333.29337-.16 1.22667-.45334 2.45337-.45334 3.4933.08 6.3733 2.61334 7.04 5.91998.08.56-.4.9867-.88.9867Z"
29
+ fill="url(#c)"
30
+ />
31
+ <Defs>
32
+ <LinearGradient
33
+ id="b"
34
+ x1="11.9963"
35
+ y1=".00747"
36
+ x2="11.9963"
37
+ y2="23.9994"
38
+ gradientUnits="userSpaceOnUse"
39
+ >
40
+ <Stop stopColor="#D3D7DD" />
41
+ <Stop offset="1" stopColor="#888C90" />
42
+ </LinearGradient>
43
+ <LinearGradient
44
+ id="c"
45
+ x1="11.9942"
46
+ y1="2.38536"
47
+ x2="11.9942"
48
+ y2="21.6406"
49
+ gradientUnits="userSpaceOnUse"
50
+ >
51
+ <Stop stopColor="#D9DADB" />
52
+ <Stop offset="1" stopColor="#7D8082" />
53
+ </LinearGradient>
54
+ </Defs>
55
+ </Svg>
56
+ );
57
+
58
+ export default IconSystemSettingsiOS;
@@ -0,0 +1,18 @@
1
+ import React from "react";
2
+ import { Svg, Path } from "react-native-svg";
3
+ import { SVGIconProps } from "../Icon";
4
+
5
+ const IconSystemToggleInstructions = ({
6
+ size,
7
+ style,
8
+ ...props
9
+ }: SVGIconProps) => (
10
+ <Svg width={size} height={size} viewBox="0 0 24 24" style={style} {...props}>
11
+ <Path
12
+ fill="#7FCD7D"
13
+ d="M18 6.545H6c-3.312 0-6 2.81-6 6.273 0 3.463 2.688 6.273 6 6.273h12c3.312 0 6-2.81 6-6.273 0-3.462-2.688-6.273-6-6.273Zm0 10.037c-1.992 0-3.6-1.681-3.6-3.764 0-2.082 1.608-3.763 3.6-3.763s3.6 1.68 3.6 3.763-1.608 3.764-3.6 3.764Z"
14
+ />
15
+ </Svg>
16
+ );
17
+
18
+ export default IconSystemToggleInstructions;
@@ -1,18 +1,18 @@
1
- export * from "./pictograms";
2
- export * from "./icons";
3
- export * from "./checkbox";
4
- export * from "./radio";
5
- export * from "./switch";
6
- export * from "./spacer/Spacer";
7
- export * from "./divider/Divider";
8
- export * from "./contentWrapper/ContentWrapper";
9
- export * from "./typography";
10
- export * from "./spacer";
11
- export * from "./avatar";
12
1
  export * from "./accordion";
2
+ export * from "./alert";
3
+ export * from "./avatar";
13
4
  export * from "./badge";
14
5
  export * from "./buttons";
6
+ export * from "./checkbox";
7
+ export * from "./contentWrapper";
8
+ export * from "./divider";
9
+ export * from "./icons";
15
10
  export * from "./listitems";
11
+ export * from "./logos";
12
+ export * from "./banner";
13
+ export * from "./pictograms";
14
+ export * from "./radio";
15
+ export * from "./spacer";
16
+ export * from "./switch";
16
17
  export * from "./tag";
17
- export * from "./alert";
18
- export * from "./logos";
18
+ export * from "./typography";
@@ -0,0 +1,119 @@
1
+ import * as React from "react";
2
+ import { View, StyleSheet, ViewStyle, StyleProp } from "react-native";
3
+ import LinearGradient from "react-native-linear-gradient";
4
+ import Animated from "react-native-reanimated";
5
+ import { WithTestID } from "../../utils/types";
6
+ import { IOColors, hexToRgba, IOSpacer, IOVisualCostants } from "../../core";
7
+ import { VSpacer } from "../spacer";
8
+
9
+ export type GradientBottomActions = WithTestID<{
10
+ transitionAnimStyle: Animated.AnimateStyle<StyleProp<ViewStyle>>;
11
+ dimensions: GradientBottomActionsDimensions;
12
+ // Accepted components: ButtonSolid, ButtonLink
13
+ // Don't use any components other than this, please.
14
+ primaryAction?: React.ReactNode;
15
+ secondaryAction?: React.ReactNode;
16
+ // Debug mode
17
+ debugMode?: boolean;
18
+ }>;
19
+
20
+ type GradientBottomActionsDimensions = {
21
+ bottomMargin: number;
22
+ extraBottomMargin: number;
23
+ gradientAreaHeight: number;
24
+ spaceBetweenActions: IOSpacer;
25
+ safeBackgroundHeight: number;
26
+ };
27
+
28
+ // Background color should be app main background (both light and dark themes)
29
+ const HEADER_BG_COLOR: IOColors = "white";
30
+
31
+ const styles = StyleSheet.create({
32
+ buttonContainer: {
33
+ paddingHorizontal: IOVisualCostants.appMarginDefault,
34
+ width: "100%",
35
+ flex: 1,
36
+ flexShrink: 0,
37
+ justifyContent: "flex-end"
38
+ },
39
+ gradientContainer: {
40
+ ...StyleSheet.absoluteFillObject
41
+ },
42
+ safeBackgroundBlock: {
43
+ position: "absolute",
44
+ bottom: 0,
45
+ left: 0,
46
+ right: 0,
47
+ backgroundColor: IOColors[HEADER_BG_COLOR]
48
+ }
49
+ });
50
+
51
+ export const GradientBottomActions = ({
52
+ primaryAction,
53
+ secondaryAction,
54
+ dimensions,
55
+ transitionAnimStyle,
56
+ debugMode,
57
+ testID
58
+ }: GradientBottomActions) => (
59
+ <View
60
+ style={{
61
+ width: "100%",
62
+ position: "absolute",
63
+ bottom: 0,
64
+ height: dimensions.gradientAreaHeight,
65
+ paddingBottom: dimensions.bottomMargin
66
+ }}
67
+ testID={testID}
68
+ pointerEvents="box-none"
69
+ >
70
+ <Animated.View
71
+ style={[
72
+ styles.gradientContainer,
73
+ debugMode && {
74
+ borderTopColor: IOColors["error-500"],
75
+ borderTopWidth: 1,
76
+ backgroundColor: hexToRgba(IOColors["error-500"], 0.5)
77
+ },
78
+ transitionAnimStyle
79
+ ]}
80
+ pointerEvents="none"
81
+ >
82
+ <LinearGradient
83
+ style={{ height: dimensions.gradientAreaHeight }}
84
+ // 100% opacity bg color fills at least 50% of the area
85
+ locations={[0, 0.5]}
86
+ colors={[
87
+ hexToRgba(IOColors[HEADER_BG_COLOR], 0),
88
+ IOColors[HEADER_BG_COLOR]
89
+ ]}
90
+ />
91
+ </Animated.View>
92
+
93
+ <View
94
+ style={[
95
+ styles.safeBackgroundBlock,
96
+ {
97
+ height: dimensions.safeBackgroundHeight
98
+ }
99
+ ]}
100
+ />
101
+ <View style={styles.buttonContainer} pointerEvents="box-none">
102
+ {primaryAction}
103
+
104
+ {secondaryAction && (
105
+ <View
106
+ style={{
107
+ alignSelf: "center",
108
+ marginBottom: dimensions.extraBottomMargin
109
+ }}
110
+ >
111
+ <VSpacer size={dimensions.spaceBetweenActions} />
112
+ {secondaryAction}
113
+ </View>
114
+ )}
115
+ </View>
116
+ </View>
117
+ );
118
+
119
+ export default GradientBottomActions;
@@ -0,0 +1,167 @@
1
+ import * as React from "react";
2
+ import { useMemo } from "react";
3
+ import Animated, {
4
+ Easing,
5
+ useAnimatedScrollHandler,
6
+ useAnimatedStyle,
7
+ useSharedValue,
8
+ withTiming
9
+ } from "react-native-reanimated";
10
+ import { useSafeAreaInsets } from "react-native-safe-area-context";
11
+ import { WithTestID } from "../../utils/types";
12
+ import {
13
+ IOVisualCostants,
14
+ buttonSolidHeight,
15
+ IOSpacer,
16
+ IOSpacingScale
17
+ } from "../../core";
18
+ import GradientBottomActions from "./GradientBottomActions";
19
+
20
+ export type GradientScrollView = WithTestID<{
21
+ children: React.ReactNode;
22
+ excludeSafeAreaMargins?: boolean;
23
+ debugMode?: boolean;
24
+ // Accepted components: ButtonSolid, ButtonLink
25
+ // Don't use any components other than this, please.
26
+ primaryAction: React.ReactNode;
27
+ secondaryAction?: React.ReactNode;
28
+ }>;
29
+
30
+ // Extended gradient area above the actions
31
+ export const gradientSafeArea: IOSpacingScale = 80;
32
+ // End content margin before the actions
33
+ const contentEndMargin: IOSpacingScale = 32;
34
+ // Margin between primary action and secondary one
35
+ const spaceBetweenActions: IOSpacer = 24;
36
+ // Estimated height of the secondary action
37
+ const secondaryActionEstHeight: number = 20;
38
+ // Extra bottom margin for iPhone bottom handle
39
+ const extraSafeAreaMargin: IOSpacingScale = 8;
40
+
41
+ export const GradientScrollView = ({
42
+ children,
43
+ primaryAction,
44
+ secondaryAction,
45
+ // Don't include safe area insets
46
+ excludeSafeAreaMargins = false,
47
+ debugMode = false,
48
+ testID
49
+ }: GradientScrollView) => {
50
+ const gradientOpacity = useSharedValue(1);
51
+ const insets = useSafeAreaInsets();
52
+
53
+ /* Check if the iPhone bottom handle is present.
54
+ If not, or if you don't need safe area insets,
55
+ add a default margin to prevent the button
56
+ from sticking to the bottom. */
57
+ const bottomMargin: number = useMemo(
58
+ () =>
59
+ insets.bottom === 0 || excludeSafeAreaMargins
60
+ ? IOVisualCostants.appMarginDefault
61
+ : insets.bottom,
62
+ [insets, excludeSafeAreaMargins]
63
+ );
64
+
65
+ /* When the secondary action is visible, add extra margin
66
+ to avoid little space from iPhone bottom handle */
67
+ const extraBottomMargin: number = useMemo(
68
+ () => (secondaryAction && insets.bottom !== 0 ? extraSafeAreaMargin : 0),
69
+ [insets.bottom, secondaryAction]
70
+ );
71
+
72
+ /* Total height of actions */
73
+ const actionsArea: number = useMemo(
74
+ () =>
75
+ primaryAction && secondaryAction
76
+ ? (buttonSolidHeight as number) +
77
+ spaceBetweenActions +
78
+ secondaryActionEstHeight +
79
+ extraBottomMargin
80
+ : buttonSolidHeight,
81
+ [extraBottomMargin, primaryAction, secondaryAction]
82
+ );
83
+
84
+ /* Total height of "Actions + Gradient" area */
85
+ const gradientAreaHeight: number = useMemo(
86
+ () => bottomMargin + actionsArea + gradientSafeArea,
87
+ [actionsArea, bottomMargin]
88
+ );
89
+
90
+ /* Height of the safe bottom area, applied to the ScrollView:
91
+ Actions + Content end margin */
92
+ const safeBottomAreaHeight: number = useMemo(
93
+ () => bottomMargin + actionsArea + contentEndMargin,
94
+ [actionsArea, bottomMargin]
95
+ );
96
+
97
+ {
98
+ /* Safe background block. It's added because when
99
+ you swipe up quickly, the content below is visible
100
+ for about 100ms. Without this block, the content
101
+ appears glitchy. */
102
+ }
103
+
104
+ const safeBackgroundHeight = useMemo(
105
+ () =>
106
+ secondaryAction
107
+ ? spaceBetweenActions +
108
+ secondaryActionEstHeight +
109
+ extraBottomMargin +
110
+ bottomMargin
111
+ : bottomMargin,
112
+ [bottomMargin, extraBottomMargin, secondaryAction]
113
+ );
114
+
115
+ const handleScroll = useAnimatedScrollHandler(
116
+ ({ contentOffset, layoutMeasurement, contentSize }) => {
117
+ /* We use Math.floor because decimals used on Android
118
+ devices never change the `isEndReached` boolean value.
119
+ We have more consistent behavior across platforms
120
+ if we round these calculations ¯\_(ツ)_/¯ */
121
+ const isEndReached =
122
+ Math.floor(layoutMeasurement.height + contentOffset.y) >=
123
+ Math.floor(contentSize.height);
124
+
125
+ // eslint-disable-next-line functional/immutable-data
126
+ gradientOpacity.value = isEndReached ? 0 : 1;
127
+ }
128
+ );
129
+
130
+ const opacityTransition = useAnimatedStyle(() => ({
131
+ opacity: withTiming(gradientOpacity.value, {
132
+ duration: 200,
133
+ easing: Easing.ease
134
+ })
135
+ }));
136
+
137
+ return (
138
+ <>
139
+ <Animated.ScrollView
140
+ testID={testID}
141
+ onScroll={handleScroll}
142
+ scrollEventThrottle={16}
143
+ contentContainerStyle={{
144
+ paddingHorizontal: IOVisualCostants.appMarginDefault,
145
+ paddingBottom: safeBottomAreaHeight
146
+ }}
147
+ >
148
+ {children}
149
+ </Animated.ScrollView>
150
+ <GradientBottomActions
151
+ debugMode={debugMode}
152
+ primaryAction={primaryAction}
153
+ secondaryAction={secondaryAction}
154
+ transitionAnimStyle={opacityTransition}
155
+ dimensions={{
156
+ bottomMargin,
157
+ extraBottomMargin,
158
+ gradientAreaHeight,
159
+ spaceBetweenActions,
160
+ safeBackgroundHeight
161
+ }}
162
+ />
163
+ </>
164
+ );
165
+ };
166
+
167
+ export default GradientScrollView;
@@ -0,0 +1,76 @@
1
+ import * as React from "react";
2
+ import { View, StyleSheet } from "react-native";
3
+ import { useSafeAreaInsets } from "react-native-safe-area-context";
4
+ import { WithTestID } from "../../utils/types";
5
+ import { IOStyles, IOVisualCostants, IOColors } from "../../core";
6
+ import { H3 } from "../typography";
7
+ import { HSpacer } from "../spacer";
8
+
9
+ export type HeaderFirstLevel = WithTestID<{
10
+ title: string;
11
+ // Accepted components: IconButton
12
+ // Don't use any components other than this, please.
13
+ firstAction?: React.ReactNode;
14
+ secondAction?: React.ReactNode;
15
+ thirdAction?: React.ReactNode;
16
+ }>;
17
+
18
+ const HEADER_BG_COLOR: IOColors = "white";
19
+
20
+ const styles = StyleSheet.create({
21
+ headerInner: {
22
+ paddingHorizontal: IOVisualCostants.appMarginDefault,
23
+ height: IOVisualCostants.headerHeight,
24
+ width: "100%",
25
+ flexDirection: "row",
26
+ alignItems: "center",
27
+ justifyContent: "space-between"
28
+ }
29
+ });
30
+
31
+ export const HeaderFirstLevel = ({
32
+ title,
33
+ firstAction,
34
+ secondAction,
35
+ thirdAction,
36
+ testID
37
+ }: HeaderFirstLevel) => {
38
+ const insets = useSafeAreaInsets();
39
+
40
+ return (
41
+ <View
42
+ style={{
43
+ paddingTop: insets.top,
44
+ backgroundColor: IOColors[HEADER_BG_COLOR]
45
+ }}
46
+ accessibilityRole="header"
47
+ testID={testID}
48
+ >
49
+ <View style={styles.headerInner}>
50
+ <H3 style={{ flexShrink: 1 }} numberOfLines={1}>
51
+ {title}
52
+ </H3>
53
+ <View style={[IOStyles.row, { flexShrink: 0 }]}>
54
+ {firstAction}
55
+ {secondAction && (
56
+ <>
57
+ {/* Ideally, with the "gap" flex property,
58
+ we can get rid of these ugly constructs */}
59
+ <HSpacer size={16} />
60
+ {secondAction}
61
+ </>
62
+ )}
63
+ {thirdAction && (
64
+ <>
65
+ {/* Same as above */}
66
+ <HSpacer size={16} />
67
+ {thirdAction}
68
+ </>
69
+ )}
70
+ </View>
71
+ </View>
72
+ </View>
73
+ );
74
+ };
75
+
76
+ export default HeaderFirstLevel;
@@ -0,0 +1 @@
1
+ export * from "./GradientBottomActions";