@hedia/recommendation-screen 2.1.75-alpha.0 → 2.2.0-alpha.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (393) hide show
  1. package/dist/index.d.ts +5 -0
  2. package/dist/index.js +5 -0
  3. package/{lib/typescript → dist/src}/RecommendationScreen.d.ts +68 -82
  4. package/dist/src/RecommendationScreen.js +522 -0
  5. package/dist/src/assets/assets/activity/Cyclist.png +0 -0
  6. package/dist/src/assets/assets/activity/Other.png +0 -0
  7. package/dist/src/assets/assets/activity/Runner.png +0 -0
  8. package/dist/src/assets/assets/activity/Swimmer.png +0 -0
  9. package/dist/src/assets/assets/activity/Walk.png +0 -0
  10. package/dist/src/assets/assets/fonts/Poppins-Bold.ttf +0 -0
  11. package/dist/src/assets/assets/fonts/Poppins-SemiBold.ttf +0 -0
  12. package/dist/src/assets/assets/icons/Edit.tsx +22 -0
  13. package/dist/src/assets/assets/icons/X.tsx +14 -0
  14. package/dist/src/assets/assets/mood/happy.png +0 -0
  15. package/dist/src/assets/assets/mood/happy_active.png +0 -0
  16. package/dist/src/assets/assets/mood/neutral.png +0 -0
  17. package/dist/src/assets/assets/mood/neutral_active.png +0 -0
  18. package/dist/src/assets/assets/mood/sad.png +0 -0
  19. package/dist/src/assets/assets/mood/sad_active.png +0 -0
  20. package/dist/src/assets/assets/mood/semi_happy.png +0 -0
  21. package/dist/src/assets/assets/mood/semi_happy_active.png +0 -0
  22. package/dist/src/assets/assets/mood/semi_sad.png +0 -0
  23. package/dist/src/assets/assets/mood/semi_sad_active.png +0 -0
  24. package/dist/src/assets/icons/Edit.d.ts +4 -0
  25. package/dist/src/assets/icons/Edit.js +7 -0
  26. package/dist/src/assets/icons/X.d.ts +4 -0
  27. package/dist/src/assets/icons/X.js +6 -0
  28. package/dist/src/components/ForecastInfoBar.d.ts +109 -0
  29. package/dist/src/components/ForecastInfoBar.js +138 -0
  30. package/dist/src/components/Header.d.ts +8 -0
  31. package/dist/src/components/Header.js +54 -0
  32. package/dist/src/components/Icon.d.ts +20 -0
  33. package/dist/src/components/Icon.js +43 -0
  34. package/{lib/typescript → dist/src}/components/InfoBars.d.ts +28 -14
  35. package/dist/src/components/InfoBars.js +128 -0
  36. package/{lib/typescript → dist/src}/components/InvisibleNumberInput.d.ts +3 -9
  37. package/dist/src/components/InvisibleNumberInput.js +121 -0
  38. package/dist/src/components/LimitationMessage.d.ts +14 -0
  39. package/dist/src/components/LimitationMessage.js +30 -0
  40. package/{lib/typescript → dist/src}/components/LineSeparator.d.ts +1 -6
  41. package/dist/src/components/LineSeparator.js +18 -0
  42. package/{lib/typescript → dist/src}/components/RecentInsulin.d.ts +1 -3
  43. package/dist/src/components/RecentInsulin.js +73 -0
  44. package/{lib/typescript → dist/src}/components/RecommendationModal.d.ts +63 -63
  45. package/dist/src/components/RecommendationModal.js +226 -0
  46. package/{lib/typescript → dist/src}/components/RecommendedCarbs.d.ts +0 -3
  47. package/dist/src/components/RecommendedCarbs.js +251 -0
  48. package/{lib/typescript → dist/src}/components/RecommendedInsulin.d.ts +1 -2
  49. package/dist/src/components/RecommendedInsulin.js +180 -0
  50. package/{lib/typescript → dist/src}/components/Remeasure.d.ts +15 -6
  51. package/dist/src/components/Remeasure.js +130 -0
  52. package/{lib/typescript/components/TransferToLogbook.d.ts → dist/src/components/SaveButton.d.ts} +2 -3
  53. package/dist/src/components/SaveButton.js +71 -0
  54. package/dist/src/components/TwoOptionModal.d.ts +136 -0
  55. package/dist/src/components/TwoOptionModal.js +141 -0
  56. package/{lib/typescript → dist/src}/components/activity/Activity.d.ts +2 -3
  57. package/dist/src/components/activity/Activity.js +84 -0
  58. package/{lib/typescript → dist/src}/components/activity/ActivityIcon.d.ts +7 -8
  59. package/dist/src/components/activity/ActivityIcon.js +58 -0
  60. package/{lib/typescript → dist/src}/components/activity/ActivityIntensity.d.ts +1 -2
  61. package/dist/src/components/activity/ActivityIntensity.js +58 -0
  62. package/{lib/typescript → dist/src}/components/mood/Emotion.d.ts +1 -2
  63. package/dist/src/components/mood/Emotion.js +64 -0
  64. package/{lib/typescript → dist/src}/components/mood/MoodIcon.d.ts +5 -5
  65. package/dist/src/components/mood/MoodIcon.js +63 -0
  66. package/dist/src/components/text/TextBold.d.ts +8 -0
  67. package/dist/src/components/text/TextBold.js +12 -0
  68. package/dist/src/components/text/TextRegular.d.ts +8 -0
  69. package/dist/src/components/text/TextRegular.js +12 -0
  70. package/dist/src/locale/da/messages.js +1 -0
  71. package/dist/src/locale/da/messages.po +349 -0
  72. package/dist/src/locale/de/messages.js +1 -0
  73. package/dist/src/locale/de/messages.po +349 -0
  74. package/dist/src/locale/en/messages.js +1 -0
  75. package/dist/src/locale/en/messages.po +349 -0
  76. package/dist/src/locale/es/messages.js +1 -0
  77. package/dist/src/locale/es/messages.po +349 -0
  78. package/dist/src/locale/fr/messages.js +1 -0
  79. package/dist/src/locale/fr/messages.po +349 -0
  80. package/dist/src/locale/i18nUtils.d.ts +18 -0
  81. package/dist/src/locale/i18nUtils.js +39 -0
  82. package/dist/src/locale/it/messages.js +1 -0
  83. package/dist/src/locale/it/messages.po +349 -0
  84. package/{lib/typescript → dist/src}/types/enum.d.ts +15 -22
  85. package/dist/src/types/enum.js +145 -0
  86. package/{lib/typescript → dist/src}/types/types.d.ts +0 -1
  87. package/dist/src/types/types.js +1 -0
  88. package/{lib/typescript → dist/src}/utils/AttentionMessages.d.ts +0 -1
  89. package/dist/src/utils/AttentionMessages.js +118 -0
  90. package/{lib/typescript → dist/src}/utils/Constants.d.ts +3 -18
  91. package/{lib/module → dist/src}/utils/Constants.js +21 -79
  92. package/{lib/typescript → dist/src}/utils/RecommendationError.d.ts +0 -1
  93. package/dist/src/utils/RecommendationError.js +63 -0
  94. package/{lib/typescript → dist/src}/utils/RecommendationUtils.d.ts +0 -1
  95. package/{lib/module → dist/src}/utils/RecommendationUtils.js +88 -90
  96. package/{lib/typescript → dist/src}/utils/Translations.d.ts +0 -1
  97. package/{lib/module → dist/src}/utils/Translations.js +5 -7
  98. package/{lib/typescript → dist/src}/utils/Utils.d.ts +1 -2
  99. package/dist/src/utils/Utils.js +141 -0
  100. package/{lib/typescript → dist/src}/utils/Validations.d.ts +1 -2
  101. package/{lib/module → dist/src}/utils/Validations.js +128 -156
  102. package/package.json +96 -109
  103. package/lib/commonjs/RecommendationScreen.js +0 -778
  104. package/lib/commonjs/RecommendationScreen.js.map +0 -1
  105. package/lib/commonjs/assets/IconsSVG/Close.js +0 -20
  106. package/lib/commonjs/assets/IconsSVG/Close.js.map +0 -1
  107. package/lib/commonjs/assets/IconsSVG/CloseOutlined.js +0 -28
  108. package/lib/commonjs/assets/IconsSVG/CloseOutlined.js.map +0 -1
  109. package/lib/commonjs/assets/IconsSVG/Edit.js +0 -23
  110. package/lib/commonjs/assets/IconsSVG/Edit.js.map +0 -1
  111. package/lib/commonjs/assets/IconsSVG/activity/Cycling.js +0 -43
  112. package/lib/commonjs/assets/IconsSVG/activity/Cycling.js.map +0 -1
  113. package/lib/commonjs/assets/IconsSVG/activity/Running.js +0 -33
  114. package/lib/commonjs/assets/IconsSVG/activity/Running.js.map +0 -1
  115. package/lib/commonjs/assets/IconsSVG/activity/Stretching.js +0 -33
  116. package/lib/commonjs/assets/IconsSVG/activity/Stretching.js.map +0 -1
  117. package/lib/commonjs/assets/IconsSVG/activity/Swimming.js +0 -48
  118. package/lib/commonjs/assets/IconsSVG/activity/Swimming.js.map +0 -1
  119. package/lib/commonjs/assets/IconsSVG/activity/Walking.js +0 -38
  120. package/lib/commonjs/assets/IconsSVG/activity/Walking.js.map +0 -1
  121. package/lib/commonjs/assets/IconsSVG/mood/Happy.js +0 -34
  122. package/lib/commonjs/assets/IconsSVG/mood/Happy.js.map +0 -1
  123. package/lib/commonjs/assets/IconsSVG/mood/Neutral.js +0 -34
  124. package/lib/commonjs/assets/IconsSVG/mood/Neutral.js.map +0 -1
  125. package/lib/commonjs/assets/IconsSVG/mood/Sad.js +0 -34
  126. package/lib/commonjs/assets/IconsSVG/mood/Sad.js.map +0 -1
  127. package/lib/commonjs/assets/IconsSVG/mood/SemiHappy.js +0 -34
  128. package/lib/commonjs/assets/IconsSVG/mood/SemiHappy.js.map +0 -1
  129. package/lib/commonjs/assets/IconsSVG/mood/SemiSad.js +0 -34
  130. package/lib/commonjs/assets/IconsSVG/mood/SemiSad.js.map +0 -1
  131. package/lib/commonjs/components/ExitModal.js +0 -124
  132. package/lib/commonjs/components/ExitModal.js.map +0 -1
  133. package/lib/commonjs/components/InfoBars.js +0 -123
  134. package/lib/commonjs/components/InfoBars.js.map +0 -1
  135. package/lib/commonjs/components/InvisibleNumberInput.js +0 -150
  136. package/lib/commonjs/components/InvisibleNumberInput.js.map +0 -1
  137. package/lib/commonjs/components/LineSeparator.js +0 -27
  138. package/lib/commonjs/components/LineSeparator.js.map +0 -1
  139. package/lib/commonjs/components/RecentInsulin.js +0 -105
  140. package/lib/commonjs/components/RecentInsulin.js.map +0 -1
  141. package/lib/commonjs/components/RecommendationModal.js +0 -302
  142. package/lib/commonjs/components/RecommendationModal.js.map +0 -1
  143. package/lib/commonjs/components/RecommendedCarbs.js +0 -289
  144. package/lib/commonjs/components/RecommendedCarbs.js.map +0 -1
  145. package/lib/commonjs/components/RecommendedInsulin.js +0 -209
  146. package/lib/commonjs/components/RecommendedInsulin.js.map +0 -1
  147. package/lib/commonjs/components/Remeasure.js +0 -131
  148. package/lib/commonjs/components/Remeasure.js.map +0 -1
  149. package/lib/commonjs/components/Text.js +0 -25
  150. package/lib/commonjs/components/Text.js.map +0 -1
  151. package/lib/commonjs/components/TimeoutModal.js +0 -113
  152. package/lib/commonjs/components/TimeoutModal.js.map +0 -1
  153. package/lib/commonjs/components/TransferToLogbook.js +0 -83
  154. package/lib/commonjs/components/TransferToLogbook.js.map +0 -1
  155. package/lib/commonjs/components/activity/Activity.js +0 -112
  156. package/lib/commonjs/components/activity/Activity.js.map +0 -1
  157. package/lib/commonjs/components/activity/ActivityIcon.js +0 -86
  158. package/lib/commonjs/components/activity/ActivityIcon.js.map +0 -1
  159. package/lib/commonjs/components/activity/ActivityIntensity.js +0 -65
  160. package/lib/commonjs/components/activity/ActivityIntensity.js.map +0 -1
  161. package/lib/commonjs/components/mood/Emotion.js +0 -86
  162. package/lib/commonjs/components/mood/Emotion.js.map +0 -1
  163. package/lib/commonjs/components/mood/MoodIcon.js +0 -107
  164. package/lib/commonjs/components/mood/MoodIcon.js.map +0 -1
  165. package/lib/commonjs/components/styles/fonts.js +0 -160
  166. package/lib/commonjs/components/styles/fonts.js.map +0 -1
  167. package/lib/commonjs/index.js +0 -21
  168. package/lib/commonjs/index.js.map +0 -1
  169. package/lib/commonjs/locales/da/translations.json +0 -82
  170. package/lib/commonjs/locales/de/translations.json +0 -81
  171. package/lib/commonjs/locales/en/translations.json +0 -84
  172. package/lib/commonjs/locales/es/translations.json +0 -81
  173. package/lib/commonjs/locales/fr/translations.json +0 -81
  174. package/lib/commonjs/locales/it/translations.json +0 -81
  175. package/lib/commonjs/locales/translate.js +0 -63
  176. package/lib/commonjs/locales/translate.js.map +0 -1
  177. package/lib/commonjs/types/enum.js +0 -179
  178. package/lib/commonjs/types/enum.js.map +0 -1
  179. package/lib/commonjs/types/types.js +0 -6
  180. package/lib/commonjs/types/types.js.map +0 -1
  181. package/lib/commonjs/utils/AttentionMessages.js +0 -141
  182. package/lib/commonjs/utils/AttentionMessages.js.map +0 -1
  183. package/lib/commonjs/utils/Constants.js +0 -138
  184. package/lib/commonjs/utils/Constants.js.map +0 -1
  185. package/lib/commonjs/utils/RecommendationError.js +0 -116
  186. package/lib/commonjs/utils/RecommendationError.js.map +0 -1
  187. package/lib/commonjs/utils/RecommendationUtils.js +0 -212
  188. package/lib/commonjs/utils/RecommendationUtils.js.map +0 -1
  189. package/lib/commonjs/utils/Translations.js +0 -22
  190. package/lib/commonjs/utils/Translations.js.map +0 -1
  191. package/lib/commonjs/utils/Utils.js +0 -162
  192. package/lib/commonjs/utils/Utils.js.map +0 -1
  193. package/lib/commonjs/utils/Validations.js +0 -468
  194. package/lib/commonjs/utils/Validations.js.map +0 -1
  195. package/lib/module/RecommendationScreen.js +0 -768
  196. package/lib/module/RecommendationScreen.js.map +0 -1
  197. package/lib/module/assets/IconsSVG/Close.js +0 -11
  198. package/lib/module/assets/IconsSVG/Close.js.map +0 -1
  199. package/lib/module/assets/IconsSVG/CloseOutlined.js +0 -19
  200. package/lib/module/assets/IconsSVG/CloseOutlined.js.map +0 -1
  201. package/lib/module/assets/IconsSVG/Edit.js +0 -14
  202. package/lib/module/assets/IconsSVG/Edit.js.map +0 -1
  203. package/lib/module/assets/IconsSVG/activity/Cycling.js +0 -34
  204. package/lib/module/assets/IconsSVG/activity/Cycling.js.map +0 -1
  205. package/lib/module/assets/IconsSVG/activity/Running.js +0 -24
  206. package/lib/module/assets/IconsSVG/activity/Running.js.map +0 -1
  207. package/lib/module/assets/IconsSVG/activity/Stretching.js +0 -24
  208. package/lib/module/assets/IconsSVG/activity/Stretching.js.map +0 -1
  209. package/lib/module/assets/IconsSVG/activity/Swimming.js +0 -39
  210. package/lib/module/assets/IconsSVG/activity/Swimming.js.map +0 -1
  211. package/lib/module/assets/IconsSVG/activity/Walking.js +0 -29
  212. package/lib/module/assets/IconsSVG/activity/Walking.js.map +0 -1
  213. package/lib/module/assets/IconsSVG/mood/Happy.js +0 -25
  214. package/lib/module/assets/IconsSVG/mood/Happy.js.map +0 -1
  215. package/lib/module/assets/IconsSVG/mood/Neutral.js +0 -25
  216. package/lib/module/assets/IconsSVG/mood/Neutral.js.map +0 -1
  217. package/lib/module/assets/IconsSVG/mood/Sad.js +0 -25
  218. package/lib/module/assets/IconsSVG/mood/Sad.js.map +0 -1
  219. package/lib/module/assets/IconsSVG/mood/SemiHappy.js +0 -25
  220. package/lib/module/assets/IconsSVG/mood/SemiHappy.js.map +0 -1
  221. package/lib/module/assets/IconsSVG/mood/SemiSad.js +0 -25
  222. package/lib/module/assets/IconsSVG/mood/SemiSad.js.map +0 -1
  223. package/lib/module/components/ExitModal.js +0 -114
  224. package/lib/module/components/ExitModal.js.map +0 -1
  225. package/lib/module/components/InfoBars.js +0 -114
  226. package/lib/module/components/InfoBars.js.map +0 -1
  227. package/lib/module/components/InvisibleNumberInput.js +0 -142
  228. package/lib/module/components/InvisibleNumberInput.js.map +0 -1
  229. package/lib/module/components/LineSeparator.js +0 -19
  230. package/lib/module/components/LineSeparator.js.map +0 -1
  231. package/lib/module/components/RecentInsulin.js +0 -97
  232. package/lib/module/components/RecentInsulin.js.map +0 -1
  233. package/lib/module/components/RecommendationModal.js +0 -291
  234. package/lib/module/components/RecommendationModal.js.map +0 -1
  235. package/lib/module/components/RecommendedCarbs.js +0 -281
  236. package/lib/module/components/RecommendedCarbs.js.map +0 -1
  237. package/lib/module/components/RecommendedInsulin.js +0 -201
  238. package/lib/module/components/RecommendedInsulin.js.map +0 -1
  239. package/lib/module/components/Remeasure.js +0 -123
  240. package/lib/module/components/Remeasure.js.map +0 -1
  241. package/lib/module/components/Text.js +0 -16
  242. package/lib/module/components/Text.js.map +0 -1
  243. package/lib/module/components/TimeoutModal.js +0 -103
  244. package/lib/module/components/TimeoutModal.js.map +0 -1
  245. package/lib/module/components/TransferToLogbook.js +0 -75
  246. package/lib/module/components/TransferToLogbook.js.map +0 -1
  247. package/lib/module/components/activity/Activity.js +0 -104
  248. package/lib/module/components/activity/Activity.js.map +0 -1
  249. package/lib/module/components/activity/ActivityIcon.js +0 -78
  250. package/lib/module/components/activity/ActivityIcon.js.map +0 -1
  251. package/lib/module/components/activity/ActivityIntensity.js +0 -57
  252. package/lib/module/components/activity/ActivityIntensity.js.map +0 -1
  253. package/lib/module/components/mood/Emotion.js +0 -78
  254. package/lib/module/components/mood/Emotion.js.map +0 -1
  255. package/lib/module/components/mood/MoodIcon.js +0 -97
  256. package/lib/module/components/mood/MoodIcon.js.map +0 -1
  257. package/lib/module/components/styles/fonts.js +0 -152
  258. package/lib/module/components/styles/fonts.js.map +0 -1
  259. package/lib/module/index.js +0 -5
  260. package/lib/module/index.js.map +0 -1
  261. package/lib/module/locales/da/translations.json +0 -82
  262. package/lib/module/locales/de/translations.json +0 -81
  263. package/lib/module/locales/en/translations.json +0 -84
  264. package/lib/module/locales/es/translations.json +0 -81
  265. package/lib/module/locales/fr/translations.json +0 -81
  266. package/lib/module/locales/it/translations.json +0 -81
  267. package/lib/module/locales/translate.js +0 -55
  268. package/lib/module/locales/translate.js.map +0 -1
  269. package/lib/module/types/enum.js +0 -170
  270. package/lib/module/types/enum.js.map +0 -1
  271. package/lib/module/types/types.js +0 -2
  272. package/lib/module/types/types.js.map +0 -1
  273. package/lib/module/utils/AttentionMessages.js +0 -131
  274. package/lib/module/utils/AttentionMessages.js.map +0 -1
  275. package/lib/module/utils/Constants.js.map +0 -1
  276. package/lib/module/utils/RecommendationError.js +0 -87
  277. package/lib/module/utils/RecommendationError.js.map +0 -1
  278. package/lib/module/utils/RecommendationUtils.js.map +0 -1
  279. package/lib/module/utils/Translations.js.map +0 -1
  280. package/lib/module/utils/Utils.js +0 -155
  281. package/lib/module/utils/Utils.js.map +0 -1
  282. package/lib/module/utils/Validations.js.map +0 -1
  283. package/lib/typescript/RecommendationScreen.d.ts.map +0 -1
  284. package/lib/typescript/assets/IconsSVG/Close.d.ts +0 -5
  285. package/lib/typescript/assets/IconsSVG/Close.d.ts.map +0 -1
  286. package/lib/typescript/assets/IconsSVG/CloseOutlined.d.ts +0 -5
  287. package/lib/typescript/assets/IconsSVG/CloseOutlined.d.ts.map +0 -1
  288. package/lib/typescript/assets/IconsSVG/Edit.d.ts +0 -5
  289. package/lib/typescript/assets/IconsSVG/Edit.d.ts.map +0 -1
  290. package/lib/typescript/assets/IconsSVG/activity/Cycling.d.ts +0 -5
  291. package/lib/typescript/assets/IconsSVG/activity/Cycling.d.ts.map +0 -1
  292. package/lib/typescript/assets/IconsSVG/activity/Running.d.ts +0 -5
  293. package/lib/typescript/assets/IconsSVG/activity/Running.d.ts.map +0 -1
  294. package/lib/typescript/assets/IconsSVG/activity/Stretching.d.ts +0 -5
  295. package/lib/typescript/assets/IconsSVG/activity/Stretching.d.ts.map +0 -1
  296. package/lib/typescript/assets/IconsSVG/activity/Swimming.d.ts +0 -5
  297. package/lib/typescript/assets/IconsSVG/activity/Swimming.d.ts.map +0 -1
  298. package/lib/typescript/assets/IconsSVG/activity/Walking.d.ts +0 -5
  299. package/lib/typescript/assets/IconsSVG/activity/Walking.d.ts.map +0 -1
  300. package/lib/typescript/assets/IconsSVG/mood/Happy.d.ts +0 -5
  301. package/lib/typescript/assets/IconsSVG/mood/Happy.d.ts.map +0 -1
  302. package/lib/typescript/assets/IconsSVG/mood/Neutral.d.ts +0 -5
  303. package/lib/typescript/assets/IconsSVG/mood/Neutral.d.ts.map +0 -1
  304. package/lib/typescript/assets/IconsSVG/mood/Sad.d.ts +0 -5
  305. package/lib/typescript/assets/IconsSVG/mood/Sad.d.ts.map +0 -1
  306. package/lib/typescript/assets/IconsSVG/mood/SemiHappy.d.ts +0 -5
  307. package/lib/typescript/assets/IconsSVG/mood/SemiHappy.d.ts.map +0 -1
  308. package/lib/typescript/assets/IconsSVG/mood/SemiSad.d.ts +0 -5
  309. package/lib/typescript/assets/IconsSVG/mood/SemiSad.d.ts.map +0 -1
  310. package/lib/typescript/components/ExitModal.d.ts +0 -26
  311. package/lib/typescript/components/ExitModal.d.ts.map +0 -1
  312. package/lib/typescript/components/InfoBars.d.ts.map +0 -1
  313. package/lib/typescript/components/InvisibleNumberInput.d.ts.map +0 -1
  314. package/lib/typescript/components/LineSeparator.d.ts.map +0 -1
  315. package/lib/typescript/components/RecentInsulin.d.ts.map +0 -1
  316. package/lib/typescript/components/RecommendationModal.d.ts.map +0 -1
  317. package/lib/typescript/components/RecommendedCarbs.d.ts.map +0 -1
  318. package/lib/typescript/components/RecommendedInsulin.d.ts.map +0 -1
  319. package/lib/typescript/components/Remeasure.d.ts.map +0 -1
  320. package/lib/typescript/components/Text.d.ts +0 -14
  321. package/lib/typescript/components/Text.d.ts.map +0 -1
  322. package/lib/typescript/components/TimeoutModal.d.ts +0 -25
  323. package/lib/typescript/components/TimeoutModal.d.ts.map +0 -1
  324. package/lib/typescript/components/TransferToLogbook.d.ts.map +0 -1
  325. package/lib/typescript/components/activity/Activity.d.ts.map +0 -1
  326. package/lib/typescript/components/activity/ActivityIcon.d.ts.map +0 -1
  327. package/lib/typescript/components/activity/ActivityIntensity.d.ts.map +0 -1
  328. package/lib/typescript/components/mood/Emotion.d.ts.map +0 -1
  329. package/lib/typescript/components/mood/MoodIcon.d.ts.map +0 -1
  330. package/lib/typescript/components/styles/fonts.d.ts +0 -151
  331. package/lib/typescript/components/styles/fonts.d.ts.map +0 -1
  332. package/lib/typescript/index.d.ts +0 -5
  333. package/lib/typescript/index.d.ts.map +0 -1
  334. package/lib/typescript/locales/translate.d.ts +0 -20
  335. package/lib/typescript/locales/translate.d.ts.map +0 -1
  336. package/lib/typescript/types/enum.d.ts.map +0 -1
  337. package/lib/typescript/types/types.d.ts.map +0 -1
  338. package/lib/typescript/utils/AttentionMessages.d.ts.map +0 -1
  339. package/lib/typescript/utils/Constants.d.ts.map +0 -1
  340. package/lib/typescript/utils/RecommendationError.d.ts.map +0 -1
  341. package/lib/typescript/utils/RecommendationUtils.d.ts.map +0 -1
  342. package/lib/typescript/utils/Translations.d.ts.map +0 -1
  343. package/lib/typescript/utils/Utils.d.ts.map +0 -1
  344. package/lib/typescript/utils/Validations.d.ts.map +0 -1
  345. package/src/RecommendationScreen.tsx +0 -854
  346. package/src/assets/IconsSVG/Close.tsx +0 -13
  347. package/src/assets/IconsSVG/CloseOutlined.tsx +0 -23
  348. package/src/assets/IconsSVG/Edit.tsx +0 -16
  349. package/src/assets/IconsSVG/activity/Cycling.tsx +0 -41
  350. package/src/assets/IconsSVG/activity/Running.tsx +0 -29
  351. package/src/assets/IconsSVG/activity/Stretching.tsx +0 -29
  352. package/src/assets/IconsSVG/activity/Swimming.tsx +0 -47
  353. package/src/assets/IconsSVG/activity/Walking.tsx +0 -35
  354. package/src/assets/IconsSVG/mood/Happy.tsx +0 -30
  355. package/src/assets/IconsSVG/mood/Neutral.tsx +0 -30
  356. package/src/assets/IconsSVG/mood/Sad.tsx +0 -30
  357. package/src/assets/IconsSVG/mood/SemiHappy.tsx +0 -30
  358. package/src/assets/IconsSVG/mood/SemiSad.tsx +0 -30
  359. package/src/components/ExitModal.tsx +0 -134
  360. package/src/components/InfoBars.tsx +0 -122
  361. package/src/components/InvisibleNumberInput.tsx +0 -170
  362. package/src/components/LineSeparator.tsx +0 -29
  363. package/src/components/RecentInsulin.tsx +0 -109
  364. package/src/components/RecommendationModal.tsx +0 -319
  365. package/src/components/RecommendedCarbs.tsx +0 -303
  366. package/src/components/RecommendedInsulin.tsx +0 -220
  367. package/src/components/Remeasure.tsx +0 -135
  368. package/src/components/Text.tsx +0 -27
  369. package/src/components/TimeoutModal.tsx +0 -121
  370. package/src/components/TransferToLogbook.tsx +0 -92
  371. package/src/components/activity/Activity.tsx +0 -107
  372. package/src/components/activity/ActivityIcon.tsx +0 -77
  373. package/src/components/activity/ActivityIntensity.tsx +0 -67
  374. package/src/components/mood/Emotion.tsx +0 -97
  375. package/src/components/mood/MoodIcon.tsx +0 -91
  376. package/src/components/styles/fonts.ts +0 -151
  377. package/src/index.ts +0 -5
  378. package/src/locales/da/translations.json +0 -82
  379. package/src/locales/de/translations.json +0 -81
  380. package/src/locales/en/translations.json +0 -84
  381. package/src/locales/es/translations.json +0 -81
  382. package/src/locales/fr/translations.json +0 -81
  383. package/src/locales/it/translations.json +0 -81
  384. package/src/locales/translate.ts +0 -62
  385. package/src/types/enum.ts +0 -164
  386. package/src/types/types.ts +0 -19
  387. package/src/utils/AttentionMessages.ts +0 -167
  388. package/src/utils/Constants.ts +0 -77
  389. package/src/utils/RecommendationError.ts +0 -182
  390. package/src/utils/RecommendationUtils.ts +0 -232
  391. package/src/utils/Translations.ts +0 -17
  392. package/src/utils/Utils.ts +0 -156
  393. package/src/utils/Validations.ts +0 -490
@@ -0,0 +1,109 @@
1
+ import { BloodGlucoseUnit } from "@hedia/types";
2
+ import React from "react";
3
+ import { Testing } from "../types/enum";
4
+ export interface IProps {
5
+ /** The display label that describes the value to the user. */
6
+ label: string;
7
+ /** The value to display. */
8
+ value: string;
9
+ /** Unit label to print after the value. */
10
+ unit: BloodGlucoseUnit;
11
+ /** Forecasted time value to display. */
12
+ forecastedTime: string;
13
+ /** optional object that contains as properties a valueID and a unitID */
14
+ testID?: {
15
+ valueID: Testing.Id.InfoBarTestIds.Value;
16
+ unitID: Testing.Id.InfoBarTestIds.Unit;
17
+ };
18
+ }
19
+ /** A standard panel to display some data that the user entered. */
20
+ export default class ForecastInfoBar extends React.Component<IProps> {
21
+ /**
22
+ * Determine the unit string to be displayed in the infobar.
23
+ *
24
+ * @returns The string to display as the unit in the infobar
25
+ */
26
+ displayUnit: () => string;
27
+ /**
28
+ * @returns JSX element to display a card with the entered value.
29
+ */
30
+ render(): JSX.Element;
31
+ }
32
+ /** @internal */
33
+ export declare const infoStyles: {
34
+ container: {
35
+ flex: number;
36
+ marginVertical: number;
37
+ marginHorizontal: number;
38
+ marginBottom: number;
39
+ };
40
+ gradient: {
41
+ padding: number;
42
+ borderRadius: number;
43
+ };
44
+ border: {
45
+ borderRadius: number;
46
+ backgroundColor: string;
47
+ paddingTop: string;
48
+ paddingBottom: number;
49
+ paddingHorizontal: string;
50
+ };
51
+ row: {
52
+ flexDirection: "row";
53
+ };
54
+ labelContainer: {
55
+ flex: number;
56
+ justifyContent: "center";
57
+ };
58
+ label: {
59
+ color: string;
60
+ fontSize: number;
61
+ };
62
+ valueUnitContainer: {
63
+ flex: number;
64
+ justifyContent: "flex-end";
65
+ flexDirection: "row";
66
+ };
67
+ valueContainer: {
68
+ flex: number;
69
+ justifyContent: "flex-end";
70
+ };
71
+ value: {
72
+ color: string;
73
+ fontSize: number;
74
+ textAlign: "right";
75
+ };
76
+ unitContainer: {
77
+ flex: number;
78
+ justifyContent: "flex-end";
79
+ };
80
+ units: {
81
+ color: string;
82
+ fontSize: number;
83
+ textAlign: "left";
84
+ paddingLeft: string;
85
+ marginBottom: number;
86
+ };
87
+ forecastDot: {
88
+ height: number;
89
+ width: number;
90
+ borderRadius: number;
91
+ borderWidth: number;
92
+ borderColor: string;
93
+ };
94
+ forecastSubtitle: {
95
+ flexDirection: "row";
96
+ alignItems: "center";
97
+ paddingVertical: number;
98
+ };
99
+ forecastText: {
100
+ color: string;
101
+ marginLeft: number;
102
+ };
103
+ forecastTime: {
104
+ color: string;
105
+ fontSize: number;
106
+ lineHeight: number;
107
+ marginLeft: number;
108
+ };
109
+ };
@@ -0,0 +1,138 @@
1
+ import { t } from "@lingui/macro";
2
+ import React from "react";
3
+ import { Dimensions, StyleSheet, View } from "react-native";
4
+ import LinearGradient from "react-native-linear-gradient";
5
+ import { i18n } from "../locale/i18nUtils";
6
+ import { colors } from "../utils/Constants";
7
+ import { Utils } from "../utils/Utils";
8
+ import TextBold from "./text/TextBold";
9
+ import TextRegular from "./text/TextRegular";
10
+ /** A standard panel to display some data that the user entered. */
11
+ export default class ForecastInfoBar extends React.Component {
12
+ /**
13
+ * Determine the unit string to be displayed in the infobar.
14
+ *
15
+ * @returns The string to display as the unit in the infobar
16
+ */
17
+ displayUnit = () => {
18
+ const { unit } = this.props;
19
+ return Utils.formatUnit(unit);
20
+ };
21
+ /**
22
+ * @returns JSX element to display a card with the entered value.
23
+ */
24
+ render() {
25
+ const { forecastedTime, testID, label } = this.props;
26
+ const { border, container, forecastDot, forecastSubtitle, forecastText, forecastTime, gradient, labelContainer, row, unitContainer, units, value, valueContainer, valueUnitContainer, } = infoStyles;
27
+ return (<View style={container}>
28
+ <LinearGradient style={gradient} colors={[`#8B38F5`, `#D593E5`]} useAngle={true} angle={170}>
29
+ <View style={border}>
30
+ <View style={row}>
31
+ <View style={labelContainer}>
32
+ <TextBold style={infoStyles.label}>{label}</TextBold>
33
+ </View>
34
+ <View style={valueUnitContainer}>
35
+ <View style={valueContainer}>
36
+ <TextBold style={value} testID={testID?.valueID}>
37
+ {this.props.value}
38
+ </TextBold>
39
+ </View>
40
+ <View style={unitContainer}>
41
+ <TextRegular style={units} testID={testID?.unitID}>
42
+ {this.displayUnit()}
43
+ </TextRegular>
44
+ </View>
45
+ </View>
46
+ </View>
47
+
48
+ <View style={row}>
49
+ <View style={forecastSubtitle}>
50
+ <LinearGradient colors={[`#8B38F5`, `#D593E5`]} useAngle={true} angle={135} style={forecastDot}/>
51
+ <TextRegular style={forecastText}>{i18n._(t `Forecasted time:`)}</TextRegular>
52
+ <TextRegular style={forecastTime}>{forecastedTime}</TextRegular>
53
+ </View>
54
+ </View>
55
+ </View>
56
+ </LinearGradient>
57
+ </View>);
58
+ }
59
+ }
60
+ const { width } = Dimensions.get(`screen`);
61
+ /** @internal */
62
+ export const infoStyles = StyleSheet.create({
63
+ container: {
64
+ flex: 1,
65
+ marginVertical: width / 35,
66
+ marginHorizontal: width / 17,
67
+ marginBottom: 0,
68
+ },
69
+ gradient: {
70
+ padding: 2,
71
+ borderRadius: 11,
72
+ },
73
+ border: {
74
+ borderRadius: 10,
75
+ backgroundColor: colors.darkBlue,
76
+ paddingTop: `2%`,
77
+ paddingBottom: 0,
78
+ paddingHorizontal: `3%`,
79
+ },
80
+ row: {
81
+ flexDirection: `row`,
82
+ },
83
+ labelContainer: {
84
+ flex: 7,
85
+ justifyContent: `center`,
86
+ },
87
+ label: {
88
+ color: `white`,
89
+ fontSize: width / 22,
90
+ },
91
+ valueUnitContainer: {
92
+ flex: 6.5,
93
+ justifyContent: `flex-end`,
94
+ flexDirection: `row`,
95
+ },
96
+ valueContainer: {
97
+ flex: 5,
98
+ justifyContent: `flex-end`,
99
+ },
100
+ value: {
101
+ color: `white`,
102
+ fontSize: width / 15,
103
+ textAlign: `right`,
104
+ },
105
+ unitContainer: {
106
+ flex: 3,
107
+ justifyContent: `flex-end`,
108
+ },
109
+ units: {
110
+ color: `white`,
111
+ fontSize: width / 30,
112
+ textAlign: `left`,
113
+ paddingLeft: `15%`,
114
+ marginBottom: 4,
115
+ },
116
+ forecastDot: {
117
+ height: (width / 100) * 3,
118
+ width: (width / 100) * 3,
119
+ borderRadius: 6,
120
+ borderWidth: 1,
121
+ borderColor: colors.lightBlue,
122
+ },
123
+ forecastSubtitle: {
124
+ flexDirection: `row`,
125
+ alignItems: `center`,
126
+ paddingVertical: 10,
127
+ },
128
+ forecastText: {
129
+ color: colors.lightBlue,
130
+ marginLeft: width / 40,
131
+ },
132
+ forecastTime: {
133
+ color: `white`,
134
+ fontSize: width / 32,
135
+ lineHeight: width / 28,
136
+ marginLeft: width / 100,
137
+ },
138
+ });
@@ -0,0 +1,8 @@
1
+ import React from "react";
2
+ export interface IProps {
3
+ /** A callback that doesn’t take any arguments and doesn’t return a value to be called when the cancel-button is pressed. */
4
+ exitCallback(): void;
5
+ }
6
+ /** Component to display a header text along with a cancel-button that triggers a callback function. */
7
+ declare const Header: React.FC<IProps>;
8
+ export default Header;
@@ -0,0 +1,54 @@
1
+ import { t } from "@lingui/macro";
2
+ import React from "react";
3
+ import { Dimensions, SafeAreaView, StyleSheet, TouchableOpacity, View } from "react-native";
4
+ import XIcon from "../assets/icons/X";
5
+ import { i18n } from "../locale/i18nUtils";
6
+ import { Testing } from "../types/enum";
7
+ import TextBold from "./text/TextBold";
8
+ /** Component to display a header text along with a cancel-button that triggers a callback function. */
9
+ const Header = ({ exitCallback }) => {
10
+ const { iconWrapper, container, emptyButton, text } = headerStyles;
11
+ return (<>
12
+ <SafeAreaView />
13
+ <View style={container}>
14
+ <TouchableOpacity testID={Testing.Id.HeaderTestIds.ExitCalculation} style={iconWrapper} onPress={exitCallback}>
15
+ <XIcon />
16
+ </TouchableOpacity>
17
+
18
+ <TextBold style={text} testID={Testing.Id.HeaderTestIds.HeaderText}>
19
+ {i18n._(t `INSULIN${`\n`}RECOMMENDATION`)}
20
+ </TextBold>
21
+
22
+ <View style={emptyButton}/>
23
+ </View>
24
+ </>);
25
+ };
26
+ const { width } = Dimensions.get(`screen`);
27
+ const headerStyles = StyleSheet.create({
28
+ container: {
29
+ flexDirection: `row`,
30
+ flex: 1,
31
+ paddingHorizontal: width / 17,
32
+ paddingVertical: width / 43,
33
+ alignItems: `center`,
34
+ justifyContent: `space-between`,
35
+ },
36
+ iconWrapper: {
37
+ padding: width / 60,
38
+ borderWidth: 1,
39
+ borderColor: `#C8CCFA33`,
40
+ borderRadius: 10,
41
+ },
42
+ text: {
43
+ fontFamily: `Poppins-SemiBold`,
44
+ fontSize: width / 22,
45
+ lineHeight: width / 14,
46
+ textAlign: `center`,
47
+ color: `white`,
48
+ },
49
+ emptyButton: {
50
+ width: width / 11,
51
+ height: width / 11,
52
+ },
53
+ });
54
+ export default Header;
@@ -0,0 +1,20 @@
1
+ import React from "react";
2
+ import { StyleSheet } from "react-native";
3
+ /** Mapping from react-native-vector-icons identifier to corresponding icon resource. */
4
+ export declare const IconSets: Record<string, any>;
5
+ export interface IProps {
6
+ /** The name of the react-native-vector-icons identifier */
7
+ iconIdentifier: string;
8
+ /** Style of the icon */
9
+ iconStyle: StyleSheet.NamedStyles<any>;
10
+ }
11
+ /** Component used to display a react-native-vector-icons */
12
+ export default class Icon extends React.Component<IProps> {
13
+ static defaultProps: any;
14
+ _root: any;
15
+ setNativeProps(nativeProps: any): void;
16
+ /**
17
+ * @returns JSX Element containing the desired react-native-vector-icons
18
+ */
19
+ render(): JSX.Element;
20
+ }
@@ -0,0 +1,43 @@
1
+ // @ts-nocheck
2
+ /* tslint:disable */
3
+ import React from "react";
4
+ /** Mapping from react-native-vector-icons identifier to corresponding icon resource. */
5
+ export const IconSets = {
6
+ AntDesign: require(`react-native-vector-icons/AntDesign`),
7
+ Feather: require(`react-native-vector-icons/Feather`),
8
+ EvilIcons: require(`react-native-vector-icons/EvilIcons`),
9
+ Ionicons: require(`react-native-vector-icons/Ionicons`),
10
+ FontAwesome: require(`react-native-vector-icons/FontAwesome`),
11
+ Entypo: require(`react-native-vector-icons/Entypo`),
12
+ };
13
+ /** Component used to display a react-native-vector-icons */
14
+ export default class Icon extends React.Component {
15
+ static defaultProps;
16
+ _root;
17
+ setNativeProps(nativeProps) {
18
+ this._root.setNativeProps(nativeProps);
19
+ }
20
+ /**
21
+ * @returns JSX Element containing the desired react-native-vector-icons
22
+ */
23
+ render() {
24
+ const iconParts = this.props.iconIdentifier.split(`/`);
25
+ let iconPackageName = iconParts[0];
26
+ let iconName = iconParts[1];
27
+ if (!IconSets[iconPackageName]) {
28
+ iconPackageName = `FontAwesome`;
29
+ iconName = `question`;
30
+ }
31
+ const clonedProps = {
32
+ ...this.props,
33
+ name: iconName,
34
+ iconIdentifier: undefined,
35
+ ref: (component) => (this._root = component),
36
+ };
37
+ const IconClass = IconSets[iconPackageName].default;
38
+ return <IconClass {...clonedProps}/>;
39
+ }
40
+ }
41
+ Icon.defaultProps = {
42
+ iconIdentifier: `FontAwesome/question`,
43
+ };
@@ -1,5 +1,5 @@
1
- import React from "react";
2
1
  import { BloodGlucoseUnit, BloodKetonesUnit } from "@hedia/types";
2
+ import React from "react";
3
3
  import { Testing } from "../types/enum";
4
4
  export interface IProps {
5
5
  /** The display label that describes the value to the user. */
@@ -47,42 +47,56 @@ export default class InfoBars extends React.Component<IProps> {
47
47
  export declare const infoStyles: {
48
48
  container: {
49
49
  flex: number;
50
- flexDirection: "row";
50
+ };
51
+ margin: {
52
+ flex: number;
53
+ marginVertical: number;
54
+ marginHorizontal: number;
51
55
  marginBottom: number;
52
- padding: number;
56
+ };
57
+ border: {
53
58
  borderWidth: number;
54
59
  borderColor: string;
55
60
  borderRadius: number;
56
- alignItems: "center";
61
+ paddingVertical: string;
62
+ };
63
+ borderContainer: {
64
+ flex: number;
65
+ flexDirection: "row";
66
+ justifyContent: "space-between";
67
+ paddingHorizontal: string;
57
68
  };
58
69
  labelContainer: {
59
70
  flex: number;
60
- justifyContent: "flex-start";
71
+ justifyContent: "center";
61
72
  };
62
73
  label: {
63
74
  color: string;
64
- fontFamily: import("./styles/fonts").FontFamily;
65
75
  fontSize: number;
66
- lineHeight: number;
67
76
  };
68
77
  valueUnitContainer: {
69
78
  flex: number;
70
79
  justifyContent: "flex-end";
71
- alignItems: "baseline";
72
80
  flexDirection: "row";
73
81
  };
82
+ valueContainer: {
83
+ flex: number;
84
+ justifyContent: "flex-end";
85
+ };
74
86
  value: {
75
87
  color: string;
76
- fontFamily: import("./styles/fonts").FontFamily;
77
88
  fontSize: number;
78
- lineHeight: number;
89
+ textAlign: "right";
90
+ };
91
+ unitContainer: {
92
+ flex: number;
93
+ justifyContent: "flex-end";
79
94
  };
80
95
  units: {
81
96
  color: string;
82
- paddingLeft: number;
83
- fontFamily: import("./styles/fonts").FontFamily;
84
97
  fontSize: number;
85
- lineHeight: number;
98
+ textAlign: "left";
99
+ paddingLeft: string;
100
+ marginBottom: number;
86
101
  };
87
102
  };
88
- //# sourceMappingURL=InfoBars.d.ts.map
@@ -0,0 +1,128 @@
1
+ import { BloodGlucoseUnit, BloodKetonesUnit } from "@hedia/types";
2
+ import { t } from "@lingui/macro";
3
+ import React from "react";
4
+ import { Dimensions, StyleSheet, View } from "react-native";
5
+ import { i18n } from "../locale/i18nUtils";
6
+ import { colors } from "../utils/Constants";
7
+ import { Utils } from "../utils/Utils";
8
+ import TextBold from "./text/TextBold";
9
+ import TextRegular from "./text/TextRegular";
10
+ /** A standard panel to display some data that the user entered. */
11
+ export default class InfoBars extends React.Component {
12
+ /**
13
+ * Determine the value to be displayed in the infobar.
14
+ *
15
+ * Steps:
16
+ * 1. Unpack showNullAsDash, unit, and value from props.
17
+ * 2. Set noDecimal to be true if unit is BloodGlucoseUnit.MG_DL or if unit is BloodKetonesUnit.MG_DL.
18
+ * 3. Set nullPlaceholder to be ‘-' if noDecimal is true and to '-.-’ otherwise.
19
+ * 4. Return value if it is not null or undefined. Otherwise, if showNullAsDash is true then return nullPlaceholder, otherwise return the string '0'.
20
+ * @returns The string to display as the value in the infobar.
21
+ */
22
+ displayValue = () => {
23
+ const { showNullAsDash, unit, value } = this.props;
24
+ const noDecimal = unit === BloodGlucoseUnit.MG_DL || unit === BloodKetonesUnit.MG_DL;
25
+ const nullPlaceholder = noDecimal || !unit ? `-` : `-.-`;
26
+ return value ?? (showNullAsDash ? nullPlaceholder : `0`);
27
+ };
28
+ /**
29
+ * Determine the unit string to be displayed in the infobar.
30
+ *
31
+ * Steps:
32
+ * 1. Unpack unit from props.
33
+ * 2. Return unit if unit is “units” or the result of calling formatUnit() with unit as argument otherwise.
34
+ * @returns The string to display as the unit in the infobar
35
+ */
36
+ displayUnit = () => {
37
+ const { unit } = this.props;
38
+ if (!unit) {
39
+ return null;
40
+ }
41
+ return unit === i18n._(t `units`) ? unit : Utils.formatUnit(unit);
42
+ };
43
+ /**
44
+ * @returns JSX element to display a card with the entered value.
45
+ */
46
+ render() {
47
+ const { testID } = this.props;
48
+ return (<View style={infoStyles.container}>
49
+ <View style={infoStyles.margin}>
50
+ <View style={infoStyles.border}>
51
+ <View style={infoStyles.borderContainer}>
52
+ <View style={infoStyles.labelContainer}>
53
+ <TextBold style={infoStyles.label}>{this.props.label}</TextBold>
54
+ </View>
55
+ <View style={infoStyles.valueUnitContainer}>
56
+ <View style={infoStyles.valueContainer}>
57
+ <TextBold style={infoStyles.value} testID={testID?.valueID}>
58
+ {this.displayValue()}
59
+ </TextBold>
60
+ </View>
61
+ <View style={infoStyles.unitContainer}>
62
+ <TextRegular style={infoStyles.units} testID={testID?.unitID}>
63
+ {this.displayUnit()}
64
+ </TextRegular>
65
+ </View>
66
+ </View>
67
+ </View>
68
+ </View>
69
+ </View>
70
+ </View>);
71
+ }
72
+ }
73
+ const { width } = Dimensions.get(`screen`);
74
+ /** @internal */
75
+ export const infoStyles = StyleSheet.create({
76
+ container: { flex: 1 },
77
+ margin: {
78
+ flex: 1,
79
+ marginVertical: width / 35,
80
+ marginHorizontal: width / 17,
81
+ marginBottom: 0,
82
+ },
83
+ border: {
84
+ borderWidth: 2,
85
+ borderColor: colors.mistBlue,
86
+ borderRadius: 5,
87
+ paddingVertical: `1%`,
88
+ },
89
+ borderContainer: {
90
+ flex: 1,
91
+ flexDirection: `row`,
92
+ justifyContent: `space-between`,
93
+ paddingHorizontal: `3%`,
94
+ },
95
+ labelContainer: {
96
+ flex: 7,
97
+ justifyContent: `center`,
98
+ },
99
+ label: {
100
+ color: `white`,
101
+ fontSize: width / 22,
102
+ },
103
+ valueUnitContainer: {
104
+ flex: 6.5,
105
+ justifyContent: `flex-end`,
106
+ flexDirection: `row`,
107
+ },
108
+ valueContainer: {
109
+ flex: 5,
110
+ justifyContent: `flex-end`,
111
+ },
112
+ value: {
113
+ color: `white`,
114
+ fontSize: width / 16,
115
+ textAlign: `right`,
116
+ },
117
+ unitContainer: {
118
+ flex: 3,
119
+ justifyContent: `flex-end`,
120
+ },
121
+ units: {
122
+ color: `white`,
123
+ fontSize: width / 30,
124
+ textAlign: `left`,
125
+ paddingLeft: `15%`,
126
+ marginBottom: 4,
127
+ },
128
+ });
@@ -1,5 +1,5 @@
1
1
  import React from "react";
2
- import { EmitterSubscription, TextInput } from "react-native";
2
+ import { TextInput } from "react-native";
3
3
  export interface IProps {
4
4
  /** The initial value to put in the input field. */
5
5
  startValue?: string;
@@ -32,9 +32,8 @@ export interface IState {
32
32
  * This function is then passed to the parent by giving it as the argument for a callback function named visible.
33
33
  */
34
34
  export default class InvisibleNumberInput extends React.Component<IProps, IState> {
35
- keyboardDidHideSubscription: EmitterSubscription | null;
36
- inputRef: React.RefObject<TextInput> | null;
37
- constructor(props: IProps);
35
+ /** For holding a reference to the TextInput component so it can be focused when the InvisibleNumberInput component has been mounted. */
36
+ textInput?: TextInput;
38
37
  /** Initialise the state value variable with `0` */
39
38
  state: IState;
40
39
  /**
@@ -46,10 +45,6 @@ export default class InvisibleNumberInput extends React.Component<IProps, IState
46
45
  * - Return the value from calling the focus() method on the input field.
47
46
  */
48
47
  componentDidMount(): void;
49
- /**
50
- * Call the blur method on the TextInput component.
51
- */
52
- callOnTextInputsBlur: () => void;
53
48
  /**
54
49
  * Sanitise a user-entered value by removing invalid characters
55
50
  *
@@ -92,4 +87,3 @@ export default class InvisibleNumberInput extends React.Component<IProps, IState
92
87
  */
93
88
  render(): JSX.Element;
94
89
  }
95
- //# sourceMappingURL=InvisibleNumberInput.d.ts.map