react-native-timacare 3.1.2 → 3.1.4-beta

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 (626) hide show
  1. package/lib/commonjs/assets/icons/cam2.svg +5 -0
  2. package/lib/commonjs/assets/icons/chip.svg +20 -0
  3. package/lib/commonjs/assets/icons/index.js +1 -1
  4. package/lib/commonjs/assets/icons/index.js.flow +8 -0
  5. package/lib/commonjs/assets/icons/index.js.map +1 -1
  6. package/lib/commonjs/assets/icons/ocr.svg +11 -0
  7. package/lib/commonjs/assets/icons/takePhoto.svg +20 -0
  8. package/lib/commonjs/assets/icons/tima_small.svg +12 -23
  9. package/lib/commonjs/assets/svgs/back.svg +4 -0
  10. package/lib/commonjs/assets/svgs/complete.svg +27 -0
  11. package/lib/commonjs/assets/svgs/currentStep.svg +28 -0
  12. package/lib/commonjs/assets/svgs/edit.svg +42 -0
  13. package/lib/commonjs/assets/svgs/edit_success.svg +15 -0
  14. package/lib/commonjs/assets/svgs/ekyc.svg +18 -0
  15. package/lib/commonjs/assets/svgs/ekyc_success.svg +6 -0
  16. package/lib/commonjs/assets/svgs/index.js +2 -0
  17. package/lib/commonjs/assets/svgs/index.js.flow +23 -0
  18. package/lib/commonjs/assets/svgs/index.js.map +1 -0
  19. package/lib/commonjs/assets/svgs/nextStep.svg +21 -0
  20. package/lib/commonjs/assets/svgs/notify.svg +18 -0
  21. package/lib/commonjs/assets/svgs/orc_success.svg +11 -0
  22. package/lib/commonjs/assets/tts/1000009864.png +0 -0
  23. package/lib/commonjs/assets/tts/1000009872.png +0 -0
  24. package/lib/commonjs/assets/tts/1000011964.png +0 -0
  25. package/lib/commonjs/assets/tts/Banner.png +0 -0
  26. package/lib/commonjs/assets/tts/Frame 1000011947.png +0 -0
  27. package/lib/commonjs/assets/tts/Frame1000011946.png +0 -0
  28. package/lib/commonjs/assets/tts/Frame1000011953.png +0 -0
  29. package/lib/commonjs/assets/tts/back.png +0 -0
  30. package/lib/commonjs/assets/tts/front.png +0 -0
  31. package/lib/commonjs/assets/tts/otp.png +0 -0
  32. package/lib/commonjs/assets/tts/vehicleRegistration.png +0 -0
  33. package/lib/commonjs/assets/tts/vehicleStep.png +0 -0
  34. package/lib/commonjs/components/CIMBLoading.js +1 -1
  35. package/lib/commonjs/components/CIMBLoading.js.map +1 -1
  36. package/lib/commonjs/components/CommonSelect.js +1 -1
  37. package/lib/commonjs/components/CommonSelect.js.map +1 -1
  38. package/lib/commonjs/components/Loading.js +1 -1
  39. package/lib/commonjs/components/Loading.js.map +1 -1
  40. package/lib/commonjs/components/MButton.js +1 -1
  41. package/lib/commonjs/components/MButton.js.map +1 -1
  42. package/lib/commonjs/components/MHeader.js +1 -1
  43. package/lib/commonjs/components/MHeader.js.flow +1 -1
  44. package/lib/commonjs/components/MHeader.js.map +1 -1
  45. package/lib/commonjs/components/MSelect.js +2 -0
  46. package/lib/commonjs/components/MSelect.js.flow +78 -0
  47. package/lib/commonjs/components/MSelect.js.map +1 -0
  48. package/lib/commonjs/components/MText.js +1 -1
  49. package/lib/commonjs/components/MText.js.map +1 -1
  50. package/lib/commonjs/components/MyTextInput.js +1 -1
  51. package/lib/commonjs/components/MyTextInput.js.map +1 -1
  52. package/lib/commonjs/components/StepIndicator.js +2 -0
  53. package/lib/commonjs/components/StepIndicator.js.flow +85 -0
  54. package/lib/commonjs/components/StepIndicator.js.map +1 -0
  55. package/lib/commonjs/components/keyboardspace/index.js +1 -1
  56. package/lib/commonjs/components/keyboardspace/index.js.map +1 -1
  57. package/lib/commonjs/components/logoTima/index.js +1 -1
  58. package/lib/commonjs/components/logoTima/index.js.map +1 -1
  59. package/lib/commonjs/components/select/index.js +1 -1
  60. package/lib/commonjs/components/select/index.js.flow +19 -3
  61. package/lib/commonjs/components/select/index.js.map +1 -1
  62. package/lib/commonjs/index.js +1 -1
  63. package/lib/commonjs/index.js.flow +3 -1
  64. package/lib/commonjs/index.js.map +1 -1
  65. package/lib/commonjs/navigation/primary-navigator.js +1 -1
  66. package/lib/commonjs/navigation/primary-navigator.js.flow +81 -1
  67. package/lib/commonjs/navigation/primary-navigator.js.map +1 -1
  68. package/lib/commonjs/navigation/root-navigator.js +1 -1
  69. package/lib/commonjs/navigation/root-navigator.js.map +1 -1
  70. package/lib/commonjs/screens/Selector.js +1 -1
  71. package/lib/commonjs/screens/Selector.js.map +1 -1
  72. package/lib/commonjs/screens/camera/index.js +1 -1
  73. package/lib/commonjs/screens/camera/index.js.flow +1 -1
  74. package/lib/commonjs/screens/camera/index.js.map +1 -1
  75. package/lib/commonjs/screens/cimb-sign/index.js +1 -1
  76. package/lib/commonjs/screens/cimb-sign/index.js.map +1 -1
  77. package/lib/commonjs/screens/contract/index.js +1 -1
  78. package/lib/commonjs/screens/contract/index.js.map +1 -1
  79. package/lib/commonjs/screens/detail-loan/DetailLoanTima.js +1 -1
  80. package/lib/commonjs/screens/detail-loan/DetailLoanTima.js.map +1 -1
  81. package/lib/commonjs/screens/detail-loan/Info.js +1 -1
  82. package/lib/commonjs/screens/detail-loan/Info.js.map +1 -1
  83. package/lib/commonjs/screens/detail-loan/Payment.js +1 -1
  84. package/lib/commonjs/screens/detail-loan/Payment.js.map +1 -1
  85. package/lib/commonjs/screens/detail-loan/PaymentAll.js +1 -1
  86. package/lib/commonjs/screens/detail-loan/PaymentAll.js.map +1 -1
  87. package/lib/commonjs/screens/detail-loan/PaymentInfo.js +1 -1
  88. package/lib/commonjs/screens/detail-loan/PaymentInfo.js.map +1 -1
  89. package/lib/commonjs/screens/detail-loan/QrPayment.js +1 -1
  90. package/lib/commonjs/screens/detail-loan/QrPayment.js.map +1 -1
  91. package/lib/commonjs/screens/detail-loan/ShowQrCode.js +1 -1
  92. package/lib/commonjs/screens/detail-loan/ShowQrCode.js.map +1 -1
  93. package/lib/commonjs/screens/detail-loan/index.js +1 -1
  94. package/lib/commonjs/screens/detail-loan/index.js.map +1 -1
  95. package/lib/commonjs/screens/digital-lending/Step1.js +1 -1
  96. package/lib/commonjs/screens/digital-lending/Step1.js.map +1 -1
  97. package/lib/commonjs/screens/digital-lending/Step2.js +1 -1
  98. package/lib/commonjs/screens/digital-lending/Step2.js.map +1 -1
  99. package/lib/commonjs/screens/digital-lending/Step3.js +1 -1
  100. package/lib/commonjs/screens/digital-lending/Step3.js.map +1 -1
  101. package/lib/commonjs/screens/digital-lending/Step4.js +1 -1
  102. package/lib/commonjs/screens/digital-lending/Step4.js.map +1 -1
  103. package/lib/commonjs/screens/digital-lending/Step5.js +1 -1
  104. package/lib/commonjs/screens/digital-lending/Step5.js.map +1 -1
  105. package/lib/commonjs/screens/digital-lending/Step6.js +1 -1
  106. package/lib/commonjs/screens/digital-lending/Step6.js.map +1 -1
  107. package/lib/commonjs/screens/digital-lending/index.js +1 -1
  108. package/lib/commonjs/screens/digital-lending/index.js.map +1 -1
  109. package/lib/commonjs/screens/eSign/PreviewContract.js +1 -1
  110. package/lib/commonjs/screens/eSign/PreviewContract.js.map +1 -1
  111. package/lib/commonjs/screens/eSign/Store.js +1 -1
  112. package/lib/commonjs/screens/eSign/Store.js.flow +9 -2
  113. package/lib/commonjs/screens/eSign/Store.js.map +1 -1
  114. package/lib/commonjs/screens/eSign/index.js +1 -1
  115. package/lib/commonjs/screens/eSign/index.js.flow +4 -1
  116. package/lib/commonjs/screens/eSign/index.js.map +1 -1
  117. package/lib/commonjs/screens/forgotPassword/index.js +1 -1
  118. package/lib/commonjs/screens/forgotPassword/index.js.map +1 -1
  119. package/lib/commonjs/screens/full-submit/accept_policy.js +1 -1
  120. package/lib/commonjs/screens/full-submit/accept_policy.js.map +1 -1
  121. package/lib/commonjs/screens/full-submit/index.js +1 -1
  122. package/lib/commonjs/screens/full-submit/index.js.flow +7 -7
  123. package/lib/commonjs/screens/full-submit/index.js.map +1 -1
  124. package/lib/commonjs/screens/full-submit/selfie.js +1 -1
  125. package/lib/commonjs/screens/full-submit/selfie.js.map +1 -1
  126. package/lib/commonjs/screens/full-submit/update-document.js +1 -1
  127. package/lib/commonjs/screens/full-submit/update-document.js.flow +1 -1
  128. package/lib/commonjs/screens/full-submit/update-document.js.map +1 -1
  129. package/lib/commonjs/screens/full-submit/update-info.js +1 -1
  130. package/lib/commonjs/screens/full-submit/update-info.js.flow +1 -1
  131. package/lib/commonjs/screens/full-submit/update-info.js.map +1 -1
  132. package/lib/commonjs/screens/guide-transfer-bank/TransferDetail.js +1 -1
  133. package/lib/commonjs/screens/guide-transfer-bank/TransferDetail.js.map +1 -1
  134. package/lib/commonjs/screens/guide-transfer-bank/index.js +1 -1
  135. package/lib/commonjs/screens/guide-transfer-bank/index.js.map +1 -1
  136. package/lib/commonjs/screens/home/CIMBxTima.js +1 -1
  137. package/lib/commonjs/screens/home/CIMBxTima.js.map +1 -1
  138. package/lib/commonjs/screens/home/index.js +1 -1
  139. package/lib/commonjs/screens/home/index.js.flow +1809 -1400
  140. package/lib/commonjs/screens/home/index.js.map +1 -1
  141. package/lib/commonjs/screens/intro/index.js +1 -1
  142. package/lib/commonjs/screens/intro/index.js.map +1 -1
  143. package/lib/commonjs/screens/introduction/index.js +1 -1
  144. package/lib/commonjs/screens/introduction/index.js.map +1 -1
  145. package/lib/commonjs/screens/liveness/LivenessStore.js +1 -1
  146. package/lib/commonjs/screens/liveness/LivenessStore.js.flow +87 -1
  147. package/lib/commonjs/screens/liveness/LivenessStore.js.map +1 -1
  148. package/lib/commonjs/screens/liveness/index.js +1 -1
  149. package/lib/commonjs/screens/liveness/index.js.map +1 -1
  150. package/lib/commonjs/screens/liveness-v2/index.js +1 -1
  151. package/lib/commonjs/screens/liveness-v2/index.js.flow +36 -23
  152. package/lib/commonjs/screens/liveness-v2/index.js.map +1 -1
  153. package/lib/commonjs/screens/loan/PreviewSchedulePaymentTopup.js +1 -1
  154. package/lib/commonjs/screens/loan/PreviewSchedulePaymentTopup.js.map +1 -1
  155. package/lib/commonjs/screens/loan/UpdateLoan.js +1 -1
  156. package/lib/commonjs/screens/loan/UpdateLoan.js.map +1 -1
  157. package/lib/commonjs/screens/loginWithPassword/index.js +1 -1
  158. package/lib/commonjs/screens/loginWithPassword/index.js.map +1 -1
  159. package/lib/commonjs/screens/main/index.js +1 -1
  160. package/lib/commonjs/screens/main/index.js.map +1 -1
  161. package/lib/commonjs/screens/mrz-scanner/index.js +1 -1
  162. package/lib/commonjs/screens/mrz-scanner/index.js.flow +2 -2
  163. package/lib/commonjs/screens/mrz-scanner/index.js.map +1 -1
  164. package/lib/commonjs/screens/nationalID/index.js +1 -1
  165. package/lib/commonjs/screens/nationalID/index.js.map +1 -1
  166. package/lib/commonjs/screens/nationalIDBack/index.js +1 -1
  167. package/lib/commonjs/screens/nationalIDBack/index.js.map +1 -1
  168. package/lib/commonjs/screens/notification/index.js +1 -1
  169. package/lib/commonjs/screens/notification/index.js.map +1 -1
  170. package/lib/commonjs/screens/otp/index.js +1 -1
  171. package/lib/commonjs/screens/otp/index.js.map +1 -1
  172. package/lib/commonjs/screens/payment-evidence/Guideline.js +1 -1
  173. package/lib/commonjs/screens/payment-evidence/Guideline.js.map +1 -1
  174. package/lib/commonjs/screens/payment-evidence/ModalGuideline.js +1 -1
  175. package/lib/commonjs/screens/payment-evidence/ModalGuideline.js.map +1 -1
  176. package/lib/commonjs/screens/payment-evidence/index.js +1 -1
  177. package/lib/commonjs/screens/payment-evidence/index.js.map +1 -1
  178. package/lib/commonjs/screens/personal/index.js +1 -1
  179. package/lib/commonjs/screens/personal/index.js.map +1 -1
  180. package/lib/commonjs/screens/qualify/index.js +1 -1
  181. package/lib/commonjs/screens/qualify/index.js.map +1 -1
  182. package/lib/commonjs/screens/quick-submit/index.js +1 -1
  183. package/lib/commonjs/screens/quick-submit/index.js.map +1 -1
  184. package/lib/commonjs/screens/register/index.js +1 -1
  185. package/lib/commonjs/screens/register/index.js.flow +3 -1
  186. package/lib/commonjs/screens/register/index.js.map +1 -1
  187. package/lib/commonjs/screens/schedule-payment/DigitalSchedulePayment.js +1 -1
  188. package/lib/commonjs/screens/schedule-payment/DigitalSchedulePayment.js.map +1 -1
  189. package/lib/commonjs/screens/schedule-payment/index.js +1 -1
  190. package/lib/commonjs/screens/schedule-payment/index.js.map +1 -1
  191. package/lib/commonjs/screens/schedule-payment/payment-list.js +1 -1
  192. package/lib/commonjs/screens/schedule-payment/payment-list.js.map +1 -1
  193. package/lib/commonjs/screens/selfie/index.js +1 -1
  194. package/lib/commonjs/screens/selfie/index.js.map +1 -1
  195. package/lib/commonjs/screens/setPassword/confirmPassword.js +1 -1
  196. package/lib/commonjs/screens/setPassword/confirmPassword.js.map +1 -1
  197. package/lib/commonjs/screens/setPassword/index.js +1 -1
  198. package/lib/commonjs/screens/setPassword/index.js.map +1 -1
  199. package/lib/commonjs/screens/sign-tima/ConfirmContract.js +1 -1
  200. package/lib/commonjs/screens/sign-tima/ConfirmContract.js.map +1 -1
  201. package/lib/commonjs/screens/sign-tima/ViewContract.js +1 -1
  202. package/lib/commonjs/screens/sign-tima/ViewContract.js.map +1 -1
  203. package/lib/commonjs/screens/splash/index.js +1 -1
  204. package/lib/commonjs/screens/splash/index.js.map +1 -1
  205. package/lib/commonjs/screens/terms/QuickTerm.js +1 -1
  206. package/lib/commonjs/screens/terms/QuickTerm.js.map +1 -1
  207. package/lib/commonjs/screens/terms/TermScreen.js +1 -1
  208. package/lib/commonjs/screens/terms/TermScreen.js.map +1 -1
  209. package/lib/commonjs/screens/toan-trinh-so/LoanInterestRate.js +2 -0
  210. package/lib/commonjs/screens/toan-trinh-so/LoanInterestRate.js.flow +373 -0
  211. package/lib/commonjs/screens/toan-trinh-so/LoanInterestRate.js.map +1 -0
  212. package/lib/commonjs/screens/toan-trinh-so/OCR.js +2 -0
  213. package/lib/commonjs/screens/toan-trinh-so/OCR.js.flow +831 -0
  214. package/lib/commonjs/screens/toan-trinh-so/OCR.js.map +1 -0
  215. package/lib/commonjs/screens/toan-trinh-so/RegisterCamera.js +2 -0
  216. package/lib/commonjs/screens/toan-trinh-so/RegisterCamera.js.flow +467 -0
  217. package/lib/commonjs/screens/toan-trinh-so/RegisterCamera.js.map +1 -0
  218. package/lib/commonjs/screens/toan-trinh-so/ReviewInformation.js +2 -0
  219. package/lib/commonjs/screens/toan-trinh-so/ReviewInformation.js.flow +1007 -0
  220. package/lib/commonjs/screens/toan-trinh-so/ReviewInformation.js.map +1 -0
  221. package/lib/commonjs/screens/toan-trinh-so/ReviewInformationOther.js +2 -0
  222. package/lib/commonjs/screens/toan-trinh-so/ReviewInformationOther.js.flow +791 -0
  223. package/lib/commonjs/screens/toan-trinh-so/ReviewInformationOther.js.map +1 -0
  224. package/lib/commonjs/screens/toan-trinh-so/ReviewLoan.js +2 -0
  225. package/lib/commonjs/screens/toan-trinh-so/ReviewLoan.js.flow +1200 -0
  226. package/lib/commonjs/screens/toan-trinh-so/ReviewLoan.js.map +1 -0
  227. package/lib/commonjs/screens/toan-trinh-so/TTSNationalIDBack.js +2 -0
  228. package/lib/commonjs/screens/toan-trinh-so/TTSNationalIDBack.js.flow +242 -0
  229. package/lib/commonjs/screens/toan-trinh-so/TTSNationalIDBack.js.map +1 -0
  230. package/lib/commonjs/screens/toan-trinh-so/TTSNationalIDFront.js +2 -0
  231. package/lib/commonjs/screens/toan-trinh-so/TTSNationalIDFront.js.flow +247 -0
  232. package/lib/commonjs/screens/toan-trinh-so/TTSNationalIDFront.js.map +1 -0
  233. package/lib/commonjs/screens/toan-trinh-so/TTSOTP.js +2 -0
  234. package/lib/commonjs/screens/toan-trinh-so/TTSOTP.js.flow +356 -0
  235. package/lib/commonjs/screens/toan-trinh-so/TTSOTP.js.map +1 -0
  236. package/lib/commonjs/screens/toan-trinh-so/TTSSelfie.js +2 -0
  237. package/lib/commonjs/screens/toan-trinh-so/TTSSelfie.js.flow +267 -0
  238. package/lib/commonjs/screens/toan-trinh-so/TTSSelfie.js.map +1 -0
  239. package/lib/commonjs/screens/toan-trinh-so/TTSSignLoan.js +2 -0
  240. package/lib/commonjs/screens/toan-trinh-so/TTSSignLoan.js.flow +143 -0
  241. package/lib/commonjs/screens/toan-trinh-so/TTSSignLoan.js.map +1 -0
  242. package/lib/commonjs/screens/toan-trinh-so/VehicleCamera.js +2 -0
  243. package/lib/commonjs/screens/toan-trinh-so/VehicleCamera.js.flow +477 -0
  244. package/lib/commonjs/screens/toan-trinh-so/VehicleCamera.js.map +1 -0
  245. package/lib/commonjs/screens/toan-trinh-so/VehicleRegistration.js +2 -0
  246. package/lib/commonjs/screens/toan-trinh-so/VehicleRegistration.js.flow +197 -0
  247. package/lib/commonjs/screens/toan-trinh-so/VehicleRegistration.js.map +1 -0
  248. package/lib/commonjs/screens/toan-trinh-so/VehicleRegistrationBack.js +2 -0
  249. package/lib/commonjs/screens/toan-trinh-so/VehicleRegistrationBack.js.flow +239 -0
  250. package/lib/commonjs/screens/toan-trinh-so/VehicleRegistrationBack.js.map +1 -0
  251. package/lib/commonjs/screens/toan-trinh-so/VehicleRegistrationFront.js +2 -0
  252. package/lib/commonjs/screens/toan-trinh-so/VehicleRegistrationFront.js.flow +240 -0
  253. package/lib/commonjs/screens/toan-trinh-so/VehicleRegistrationFront.js.map +1 -0
  254. package/lib/commonjs/screens/toan-trinh-so/store.js +2 -0
  255. package/lib/commonjs/screens/toan-trinh-so/store.js.flow +237 -0
  256. package/lib/commonjs/screens/toan-trinh-so/store.js.map +1 -0
  257. package/lib/commonjs/screens/uploadVideo/index.js +1 -1
  258. package/lib/commonjs/screens/uploadVideo/index.js.map +1 -1
  259. package/lib/commonjs/services/api/api-config.js +1 -1
  260. package/lib/commonjs/services/api/api-config.js.flow +2 -2
  261. package/lib/commonjs/services/api/api-config.js.map +1 -1
  262. package/lib/commonjs/services/api/api.js +1 -1
  263. package/lib/commonjs/services/api/api.js.flow +235 -0
  264. package/lib/commonjs/services/api/api.js.map +1 -1
  265. package/lib/commonjs/utils/index.js +1 -1
  266. package/lib/commonjs/utils/index.js.flow +67 -45
  267. package/lib/commonjs/utils/index.js.map +1 -1
  268. package/lib/commonjs/utils/storage/storage.js +1 -1
  269. package/lib/commonjs/utils/storage/storage.js.flow +4 -0
  270. package/lib/commonjs/utils/storage/storage.js.map +1 -1
  271. package/lib/module/assets/icons/cam2.svg +5 -0
  272. package/lib/module/assets/icons/chip.svg +20 -0
  273. package/lib/module/assets/icons/index.js +1 -1
  274. package/lib/module/assets/icons/index.js.map +1 -1
  275. package/lib/module/assets/icons/ocr.svg +11 -0
  276. package/lib/module/assets/icons/takePhoto.svg +20 -0
  277. package/lib/module/assets/icons/tima_small.svg +12 -23
  278. package/lib/module/assets/svgs/back.svg +4 -0
  279. package/lib/module/assets/svgs/complete.svg +27 -0
  280. package/lib/module/assets/svgs/currentStep.svg +28 -0
  281. package/lib/module/assets/svgs/edit.svg +42 -0
  282. package/lib/module/assets/svgs/edit_success.svg +15 -0
  283. package/lib/module/assets/svgs/ekyc.svg +18 -0
  284. package/lib/module/assets/svgs/ekyc_success.svg +6 -0
  285. package/lib/module/assets/svgs/index.js +2 -0
  286. package/lib/module/assets/svgs/index.js.map +1 -0
  287. package/lib/module/assets/svgs/nextStep.svg +21 -0
  288. package/lib/module/assets/svgs/notify.svg +18 -0
  289. package/lib/module/assets/svgs/orc_success.svg +11 -0
  290. package/lib/module/assets/tts/1000009864.png +0 -0
  291. package/lib/module/assets/tts/1000009872.png +0 -0
  292. package/lib/module/assets/tts/1000011964.png +0 -0
  293. package/lib/module/assets/tts/Banner.png +0 -0
  294. package/lib/module/assets/tts/Frame 1000011947.png +0 -0
  295. package/lib/module/assets/tts/Frame1000011946.png +0 -0
  296. package/lib/module/assets/tts/Frame1000011953.png +0 -0
  297. package/lib/module/assets/tts/back.png +0 -0
  298. package/lib/module/assets/tts/front.png +0 -0
  299. package/lib/module/assets/tts/otp.png +0 -0
  300. package/lib/module/assets/tts/vehicleRegistration.png +0 -0
  301. package/lib/module/assets/tts/vehicleStep.png +0 -0
  302. package/lib/module/components/CIMBLoading.js +1 -1
  303. package/lib/module/components/CIMBLoading.js.map +1 -1
  304. package/lib/module/components/CommonSelect.js +1 -1
  305. package/lib/module/components/CommonSelect.js.map +1 -1
  306. package/lib/module/components/Loading.js +1 -1
  307. package/lib/module/components/Loading.js.map +1 -1
  308. package/lib/module/components/MButton.js +1 -1
  309. package/lib/module/components/MButton.js.map +1 -1
  310. package/lib/module/components/MHeader.js +1 -1
  311. package/lib/module/components/MHeader.js.map +1 -1
  312. package/lib/module/components/MSelect.js +2 -0
  313. package/lib/module/components/MSelect.js.map +1 -0
  314. package/lib/module/components/MText.js +1 -1
  315. package/lib/module/components/MText.js.map +1 -1
  316. package/lib/module/components/MyTextInput.js +1 -1
  317. package/lib/module/components/MyTextInput.js.map +1 -1
  318. package/lib/module/components/StepIndicator.js +2 -0
  319. package/lib/module/components/StepIndicator.js.map +1 -0
  320. package/lib/module/components/keyboardspace/index.js +1 -1
  321. package/lib/module/components/keyboardspace/index.js.map +1 -1
  322. package/lib/module/components/logoTima/index.js +1 -1
  323. package/lib/module/components/logoTima/index.js.map +1 -1
  324. package/lib/module/components/select/index.js +1 -1
  325. package/lib/module/components/select/index.js.map +1 -1
  326. package/lib/module/index.js +1 -1
  327. package/lib/module/index.js.map +1 -1
  328. package/lib/module/navigation/primary-navigator.js +1 -1
  329. package/lib/module/navigation/primary-navigator.js.map +1 -1
  330. package/lib/module/navigation/root-navigator.js +1 -1
  331. package/lib/module/navigation/root-navigator.js.map +1 -1
  332. package/lib/module/screens/Selector.js +1 -1
  333. package/lib/module/screens/Selector.js.map +1 -1
  334. package/lib/module/screens/camera/index.js +1 -1
  335. package/lib/module/screens/camera/index.js.map +1 -1
  336. package/lib/module/screens/cimb-sign/index.js +1 -1
  337. package/lib/module/screens/cimb-sign/index.js.map +1 -1
  338. package/lib/module/screens/contract/index.js +1 -1
  339. package/lib/module/screens/contract/index.js.map +1 -1
  340. package/lib/module/screens/detail-loan/DetailLoanTima.js +1 -1
  341. package/lib/module/screens/detail-loan/DetailLoanTima.js.map +1 -1
  342. package/lib/module/screens/detail-loan/Info.js +1 -1
  343. package/lib/module/screens/detail-loan/Info.js.map +1 -1
  344. package/lib/module/screens/detail-loan/Payment.js +1 -1
  345. package/lib/module/screens/detail-loan/Payment.js.map +1 -1
  346. package/lib/module/screens/detail-loan/PaymentAll.js +1 -1
  347. package/lib/module/screens/detail-loan/PaymentAll.js.map +1 -1
  348. package/lib/module/screens/detail-loan/PaymentInfo.js +1 -1
  349. package/lib/module/screens/detail-loan/PaymentInfo.js.map +1 -1
  350. package/lib/module/screens/detail-loan/QrPayment.js +1 -1
  351. package/lib/module/screens/detail-loan/QrPayment.js.map +1 -1
  352. package/lib/module/screens/detail-loan/ShowQrCode.js +1 -1
  353. package/lib/module/screens/detail-loan/ShowQrCode.js.map +1 -1
  354. package/lib/module/screens/detail-loan/index.js +1 -1
  355. package/lib/module/screens/detail-loan/index.js.map +1 -1
  356. package/lib/module/screens/digital-lending/Step1.js +1 -1
  357. package/lib/module/screens/digital-lending/Step1.js.map +1 -1
  358. package/lib/module/screens/digital-lending/Step2.js +1 -1
  359. package/lib/module/screens/digital-lending/Step2.js.map +1 -1
  360. package/lib/module/screens/digital-lending/Step3.js +1 -1
  361. package/lib/module/screens/digital-lending/Step3.js.map +1 -1
  362. package/lib/module/screens/digital-lending/Step4.js +1 -1
  363. package/lib/module/screens/digital-lending/Step4.js.map +1 -1
  364. package/lib/module/screens/digital-lending/Step5.js +1 -1
  365. package/lib/module/screens/digital-lending/Step5.js.map +1 -1
  366. package/lib/module/screens/digital-lending/Step6.js +1 -1
  367. package/lib/module/screens/digital-lending/Step6.js.map +1 -1
  368. package/lib/module/screens/digital-lending/index.js +1 -1
  369. package/lib/module/screens/digital-lending/index.js.map +1 -1
  370. package/lib/module/screens/eSign/PreviewContract.js +1 -1
  371. package/lib/module/screens/eSign/PreviewContract.js.map +1 -1
  372. package/lib/module/screens/eSign/Store.js +1 -1
  373. package/lib/module/screens/eSign/Store.js.map +1 -1
  374. package/lib/module/screens/eSign/index.js +1 -1
  375. package/lib/module/screens/eSign/index.js.map +1 -1
  376. package/lib/module/screens/forgotPassword/index.js +1 -1
  377. package/lib/module/screens/forgotPassword/index.js.map +1 -1
  378. package/lib/module/screens/full-submit/accept_policy.js +1 -1
  379. package/lib/module/screens/full-submit/accept_policy.js.map +1 -1
  380. package/lib/module/screens/full-submit/index.js +1 -1
  381. package/lib/module/screens/full-submit/index.js.map +1 -1
  382. package/lib/module/screens/full-submit/selfie.js +1 -1
  383. package/lib/module/screens/full-submit/selfie.js.map +1 -1
  384. package/lib/module/screens/full-submit/update-document.js +1 -1
  385. package/lib/module/screens/full-submit/update-document.js.map +1 -1
  386. package/lib/module/screens/full-submit/update-info.js +1 -1
  387. package/lib/module/screens/full-submit/update-info.js.map +1 -1
  388. package/lib/module/screens/guide-transfer-bank/TransferDetail.js +1 -1
  389. package/lib/module/screens/guide-transfer-bank/TransferDetail.js.map +1 -1
  390. package/lib/module/screens/guide-transfer-bank/index.js +1 -1
  391. package/lib/module/screens/guide-transfer-bank/index.js.map +1 -1
  392. package/lib/module/screens/home/CIMBxTima.js +1 -1
  393. package/lib/module/screens/home/CIMBxTima.js.map +1 -1
  394. package/lib/module/screens/home/index.js +1 -1
  395. package/lib/module/screens/home/index.js.map +1 -1
  396. package/lib/module/screens/intro/index.js +1 -1
  397. package/lib/module/screens/intro/index.js.map +1 -1
  398. package/lib/module/screens/introduction/index.js +1 -1
  399. package/lib/module/screens/introduction/index.js.map +1 -1
  400. package/lib/module/screens/liveness/LivenessStore.js +1 -1
  401. package/lib/module/screens/liveness/LivenessStore.js.map +1 -1
  402. package/lib/module/screens/liveness/index.js +1 -1
  403. package/lib/module/screens/liveness/index.js.map +1 -1
  404. package/lib/module/screens/liveness-v2/index.js +1 -1
  405. package/lib/module/screens/liveness-v2/index.js.map +1 -1
  406. package/lib/module/screens/loan/PreviewSchedulePaymentTopup.js +1 -1
  407. package/lib/module/screens/loan/PreviewSchedulePaymentTopup.js.map +1 -1
  408. package/lib/module/screens/loan/UpdateLoan.js +1 -1
  409. package/lib/module/screens/loan/UpdateLoan.js.map +1 -1
  410. package/lib/module/screens/loginWithPassword/index.js +1 -1
  411. package/lib/module/screens/loginWithPassword/index.js.map +1 -1
  412. package/lib/module/screens/main/index.js +1 -1
  413. package/lib/module/screens/main/index.js.map +1 -1
  414. package/lib/module/screens/mrz-scanner/index.js +1 -1
  415. package/lib/module/screens/mrz-scanner/index.js.map +1 -1
  416. package/lib/module/screens/nationalID/index.js +1 -1
  417. package/lib/module/screens/nationalID/index.js.map +1 -1
  418. package/lib/module/screens/nationalIDBack/index.js +1 -1
  419. package/lib/module/screens/nationalIDBack/index.js.map +1 -1
  420. package/lib/module/screens/notification/index.js +1 -1
  421. package/lib/module/screens/notification/index.js.map +1 -1
  422. package/lib/module/screens/otp/index.js +1 -1
  423. package/lib/module/screens/otp/index.js.map +1 -1
  424. package/lib/module/screens/payment-evidence/Guideline.js +1 -1
  425. package/lib/module/screens/payment-evidence/Guideline.js.map +1 -1
  426. package/lib/module/screens/payment-evidence/ModalGuideline.js +1 -1
  427. package/lib/module/screens/payment-evidence/ModalGuideline.js.map +1 -1
  428. package/lib/module/screens/payment-evidence/index.js +1 -1
  429. package/lib/module/screens/payment-evidence/index.js.map +1 -1
  430. package/lib/module/screens/personal/index.js +1 -1
  431. package/lib/module/screens/personal/index.js.map +1 -1
  432. package/lib/module/screens/qualify/index.js +1 -1
  433. package/lib/module/screens/qualify/index.js.map +1 -1
  434. package/lib/module/screens/quick-submit/index.js +1 -1
  435. package/lib/module/screens/quick-submit/index.js.map +1 -1
  436. package/lib/module/screens/register/index.js +1 -1
  437. package/lib/module/screens/register/index.js.map +1 -1
  438. package/lib/module/screens/schedule-payment/DigitalSchedulePayment.js +1 -1
  439. package/lib/module/screens/schedule-payment/DigitalSchedulePayment.js.map +1 -1
  440. package/lib/module/screens/schedule-payment/index.js +1 -1
  441. package/lib/module/screens/schedule-payment/index.js.map +1 -1
  442. package/lib/module/screens/schedule-payment/payment-list.js +1 -1
  443. package/lib/module/screens/schedule-payment/payment-list.js.map +1 -1
  444. package/lib/module/screens/selfie/index.js +1 -1
  445. package/lib/module/screens/selfie/index.js.map +1 -1
  446. package/lib/module/screens/setPassword/confirmPassword.js +1 -1
  447. package/lib/module/screens/setPassword/confirmPassword.js.map +1 -1
  448. package/lib/module/screens/setPassword/index.js +1 -1
  449. package/lib/module/screens/setPassword/index.js.map +1 -1
  450. package/lib/module/screens/sign-tima/ConfirmContract.js +1 -1
  451. package/lib/module/screens/sign-tima/ConfirmContract.js.map +1 -1
  452. package/lib/module/screens/sign-tima/ViewContract.js +1 -1
  453. package/lib/module/screens/sign-tima/ViewContract.js.map +1 -1
  454. package/lib/module/screens/splash/index.js +1 -1
  455. package/lib/module/screens/splash/index.js.map +1 -1
  456. package/lib/module/screens/terms/QuickTerm.js +1 -1
  457. package/lib/module/screens/terms/QuickTerm.js.map +1 -1
  458. package/lib/module/screens/terms/TermScreen.js +1 -1
  459. package/lib/module/screens/terms/TermScreen.js.map +1 -1
  460. package/lib/module/screens/toan-trinh-so/LoanInterestRate.js +2 -0
  461. package/lib/module/screens/toan-trinh-so/LoanInterestRate.js.map +1 -0
  462. package/lib/module/screens/toan-trinh-so/OCR.js +2 -0
  463. package/lib/module/screens/toan-trinh-so/OCR.js.map +1 -0
  464. package/lib/module/screens/toan-trinh-so/RegisterCamera.js +2 -0
  465. package/lib/module/screens/toan-trinh-so/RegisterCamera.js.map +1 -0
  466. package/lib/module/screens/toan-trinh-so/ReviewInformation.js +2 -0
  467. package/lib/module/screens/toan-trinh-so/ReviewInformation.js.map +1 -0
  468. package/lib/module/screens/toan-trinh-so/ReviewInformationOther.js +2 -0
  469. package/lib/module/screens/toan-trinh-so/ReviewInformationOther.js.map +1 -0
  470. package/lib/module/screens/toan-trinh-so/ReviewLoan.js +2 -0
  471. package/lib/module/screens/toan-trinh-so/ReviewLoan.js.map +1 -0
  472. package/lib/module/screens/toan-trinh-so/TTSNationalIDBack.js +2 -0
  473. package/lib/module/screens/toan-trinh-so/TTSNationalIDBack.js.map +1 -0
  474. package/lib/module/screens/toan-trinh-so/TTSNationalIDFront.js +2 -0
  475. package/lib/module/screens/toan-trinh-so/TTSNationalIDFront.js.map +1 -0
  476. package/lib/module/screens/toan-trinh-so/TTSOTP.js +2 -0
  477. package/lib/module/screens/toan-trinh-so/TTSOTP.js.map +1 -0
  478. package/lib/module/screens/toan-trinh-so/TTSSelfie.js +2 -0
  479. package/lib/module/screens/toan-trinh-so/TTSSelfie.js.map +1 -0
  480. package/lib/module/screens/toan-trinh-so/TTSSignLoan.js +2 -0
  481. package/lib/module/screens/toan-trinh-so/TTSSignLoan.js.map +1 -0
  482. package/lib/module/screens/toan-trinh-so/VehicleCamera.js +2 -0
  483. package/lib/module/screens/toan-trinh-so/VehicleCamera.js.map +1 -0
  484. package/lib/module/screens/toan-trinh-so/VehicleRegistration.js +2 -0
  485. package/lib/module/screens/toan-trinh-so/VehicleRegistration.js.map +1 -0
  486. package/lib/module/screens/toan-trinh-so/VehicleRegistrationBack.js +2 -0
  487. package/lib/module/screens/toan-trinh-so/VehicleRegistrationBack.js.map +1 -0
  488. package/lib/module/screens/toan-trinh-so/VehicleRegistrationFront.js +2 -0
  489. package/lib/module/screens/toan-trinh-so/VehicleRegistrationFront.js.map +1 -0
  490. package/lib/module/screens/toan-trinh-so/store.js +2 -0
  491. package/lib/module/screens/toan-trinh-so/store.js.map +1 -0
  492. package/lib/module/screens/uploadVideo/index.js +1 -1
  493. package/lib/module/screens/uploadVideo/index.js.map +1 -1
  494. package/lib/module/services/api/api-config.js +1 -1
  495. package/lib/module/services/api/api-config.js.map +1 -1
  496. package/lib/module/services/api/api.js +1 -1
  497. package/lib/module/services/api/api.js.map +1 -1
  498. package/lib/module/utils/index.js +1 -1
  499. package/lib/module/utils/index.js.map +1 -1
  500. package/lib/module/utils/storage/storage.js +1 -1
  501. package/lib/module/utils/storage/storage.js.map +1 -1
  502. package/lib/typescript/assets/icons/index.d.ts +5 -1
  503. package/lib/typescript/assets/icons/index.d.ts.map +1 -1
  504. package/lib/typescript/assets/svgs/index.d.ts +12 -0
  505. package/lib/typescript/assets/svgs/index.d.ts.map +1 -0
  506. package/lib/typescript/components/MSelect.d.ts +2 -0
  507. package/lib/typescript/components/MSelect.d.ts.map +1 -0
  508. package/lib/typescript/components/StepIndicator.d.ts +5 -0
  509. package/lib/typescript/components/StepIndicator.d.ts.map +1 -0
  510. package/lib/typescript/components/select/index.d.ts.map +1 -1
  511. package/lib/typescript/index.d.ts.map +1 -1
  512. package/lib/typescript/navigation/primary-navigator.d.ts +16 -0
  513. package/lib/typescript/navigation/primary-navigator.d.ts.map +1 -1
  514. package/lib/typescript/screens/eSign/Store.d.ts +1 -1
  515. package/lib/typescript/screens/eSign/Store.d.ts.map +1 -1
  516. package/lib/typescript/screens/eSign/index.d.ts.map +1 -1
  517. package/lib/typescript/screens/home/index.d.ts.map +1 -1
  518. package/lib/typescript/screens/liveness/LivenessStore.d.ts +1 -0
  519. package/lib/typescript/screens/liveness/LivenessStore.d.ts.map +1 -1
  520. package/lib/typescript/screens/liveness-v2/index.d.ts.map +1 -1
  521. package/lib/typescript/screens/register/index.d.ts.map +1 -1
  522. package/lib/typescript/screens/toan-trinh-so/LoanInterestRate.d.ts +2 -0
  523. package/lib/typescript/screens/toan-trinh-so/LoanInterestRate.d.ts.map +1 -0
  524. package/lib/typescript/screens/toan-trinh-so/OCR.d.ts +2 -0
  525. package/lib/typescript/screens/toan-trinh-so/OCR.d.ts.map +1 -0
  526. package/lib/typescript/screens/toan-trinh-so/RegisterCamera.d.ts +2 -0
  527. package/lib/typescript/screens/toan-trinh-so/RegisterCamera.d.ts.map +1 -0
  528. package/lib/typescript/screens/toan-trinh-so/ReviewInformation.d.ts +2 -0
  529. package/lib/typescript/screens/toan-trinh-so/ReviewInformation.d.ts.map +1 -0
  530. package/lib/typescript/screens/toan-trinh-so/ReviewInformationOther.d.ts +2 -0
  531. package/lib/typescript/screens/toan-trinh-so/ReviewInformationOther.d.ts.map +1 -0
  532. package/lib/typescript/screens/toan-trinh-so/ReviewLoan.d.ts +2 -0
  533. package/lib/typescript/screens/toan-trinh-so/ReviewLoan.d.ts.map +1 -0
  534. package/lib/typescript/screens/toan-trinh-so/TTSNationalIDBack.d.ts +2 -0
  535. package/lib/typescript/screens/toan-trinh-so/TTSNationalIDBack.d.ts.map +1 -0
  536. package/lib/typescript/screens/toan-trinh-so/TTSNationalIDFront.d.ts +2 -0
  537. package/lib/typescript/screens/toan-trinh-so/TTSNationalIDFront.d.ts.map +1 -0
  538. package/lib/typescript/screens/toan-trinh-so/TTSOTP.d.ts +2 -0
  539. package/lib/typescript/screens/toan-trinh-so/TTSOTP.d.ts.map +1 -0
  540. package/lib/typescript/screens/toan-trinh-so/TTSSelfie.d.ts +2 -0
  541. package/lib/typescript/screens/toan-trinh-so/TTSSelfie.d.ts.map +1 -0
  542. package/lib/typescript/screens/toan-trinh-so/TTSSignLoan.d.ts +2 -0
  543. package/lib/typescript/screens/toan-trinh-so/TTSSignLoan.d.ts.map +1 -0
  544. package/lib/typescript/screens/toan-trinh-so/VehicleCamera.d.ts +2 -0
  545. package/lib/typescript/screens/toan-trinh-so/VehicleCamera.d.ts.map +1 -0
  546. package/lib/typescript/screens/toan-trinh-so/VehicleRegistration.d.ts +2 -0
  547. package/lib/typescript/screens/toan-trinh-so/VehicleRegistration.d.ts.map +1 -0
  548. package/lib/typescript/screens/toan-trinh-so/VehicleRegistrationBack.d.ts +2 -0
  549. package/lib/typescript/screens/toan-trinh-so/VehicleRegistrationBack.d.ts.map +1 -0
  550. package/lib/typescript/screens/toan-trinh-so/VehicleRegistrationFront.d.ts +2 -0
  551. package/lib/typescript/screens/toan-trinh-so/VehicleRegistrationFront.d.ts.map +1 -0
  552. package/lib/typescript/screens/toan-trinh-so/store.d.ts +26 -0
  553. package/lib/typescript/screens/toan-trinh-so/store.d.ts.map +1 -0
  554. package/lib/typescript/services/api/api.d.ts +224 -0
  555. package/lib/typescript/services/api/api.d.ts.map +1 -1
  556. package/lib/typescript/utils/index.d.ts +8 -0
  557. package/lib/typescript/utils/index.d.ts.map +1 -1
  558. package/lib/typescript/utils/storage/storage.d.ts +3 -0
  559. package/lib/typescript/utils/storage/storage.d.ts.map +1 -1
  560. package/package.json +1 -1
  561. package/src/assets/icons/cam2.svg +5 -0
  562. package/src/assets/icons/chip.svg +20 -0
  563. package/src/assets/icons/index.tsx +8 -0
  564. package/src/assets/icons/ocr.svg +11 -0
  565. package/src/assets/icons/takePhoto.svg +20 -0
  566. package/src/assets/icons/tima_small.svg +12 -23
  567. package/src/assets/svgs/back.svg +4 -0
  568. package/src/assets/svgs/complete.svg +27 -0
  569. package/src/assets/svgs/currentStep.svg +28 -0
  570. package/src/assets/svgs/edit.svg +42 -0
  571. package/src/assets/svgs/edit_success.svg +15 -0
  572. package/src/assets/svgs/ekyc.svg +18 -0
  573. package/src/assets/svgs/ekyc_success.svg +6 -0
  574. package/src/assets/svgs/index.tsx +23 -0
  575. package/src/assets/svgs/nextStep.svg +21 -0
  576. package/src/assets/svgs/notify.svg +18 -0
  577. package/src/assets/svgs/orc_success.svg +11 -0
  578. package/src/assets/tts/1000009864.png +0 -0
  579. package/src/assets/tts/1000009872.png +0 -0
  580. package/src/assets/tts/1000011964.png +0 -0
  581. package/src/assets/tts/Banner.png +0 -0
  582. package/src/assets/tts/Frame 1000011947.png +0 -0
  583. package/src/assets/tts/Frame1000011946.png +0 -0
  584. package/src/assets/tts/Frame1000011953.png +0 -0
  585. package/src/assets/tts/back.png +0 -0
  586. package/src/assets/tts/front.png +0 -0
  587. package/src/assets/tts/otp.png +0 -0
  588. package/src/assets/tts/vehicleRegistration.png +0 -0
  589. package/src/assets/tts/vehicleStep.png +0 -0
  590. package/src/components/MHeader.tsx +1 -1
  591. package/src/components/MSelect.tsx +78 -0
  592. package/src/components/StepIndicator.tsx +85 -0
  593. package/src/components/select/index.tsx +19 -3
  594. package/src/index.tsx +3 -1
  595. package/src/navigation/primary-navigator.tsx +81 -1
  596. package/src/screens/camera/index.tsx +1 -1
  597. package/src/screens/eSign/Store.tsx +9 -2
  598. package/src/screens/eSign/index.tsx +4 -1
  599. package/src/screens/full-submit/index.tsx +7 -7
  600. package/src/screens/full-submit/update-document.tsx +1 -1
  601. package/src/screens/full-submit/update-info.tsx +1 -1
  602. package/src/screens/home/index.tsx +1809 -1400
  603. package/src/screens/liveness/LivenessStore.tsx +87 -1
  604. package/src/screens/liveness-v2/index.tsx +36 -23
  605. package/src/screens/mrz-scanner/index.tsx +2 -2
  606. package/src/screens/register/index.tsx +3 -1
  607. package/src/screens/toan-trinh-so/LoanInterestRate.tsx +373 -0
  608. package/src/screens/toan-trinh-so/OCR.tsx +831 -0
  609. package/src/screens/toan-trinh-so/RegisterCamera.tsx +467 -0
  610. package/src/screens/toan-trinh-so/ReviewInformation.tsx +1007 -0
  611. package/src/screens/toan-trinh-so/ReviewInformationOther.tsx +791 -0
  612. package/src/screens/toan-trinh-so/ReviewLoan.tsx +1200 -0
  613. package/src/screens/toan-trinh-so/TTSNationalIDBack.tsx +242 -0
  614. package/src/screens/toan-trinh-so/TTSNationalIDFront.tsx +247 -0
  615. package/src/screens/toan-trinh-so/TTSOTP.tsx +356 -0
  616. package/src/screens/toan-trinh-so/TTSSelfie.tsx +267 -0
  617. package/src/screens/toan-trinh-so/TTSSignLoan.tsx +143 -0
  618. package/src/screens/toan-trinh-so/VehicleCamera.tsx +477 -0
  619. package/src/screens/toan-trinh-so/VehicleRegistration.tsx +197 -0
  620. package/src/screens/toan-trinh-so/VehicleRegistrationBack.tsx +239 -0
  621. package/src/screens/toan-trinh-so/VehicleRegistrationFront.tsx +240 -0
  622. package/src/screens/toan-trinh-so/store.ts +237 -0
  623. package/src/services/api/api-config.ts +2 -2
  624. package/src/services/api/api.ts +235 -0
  625. package/src/utils/index.tsx +67 -45
  626. package/src/utils/storage/storage.ts +4 -0
@@ -0,0 +1,356 @@
1
+ //@ts-nocheck
2
+ import React, { useEffect, useState } from 'react';
3
+ import {
4
+ Alert,
5
+ Image,
6
+ ImageStyle,
7
+ SafeAreaView,
8
+ ScrollView,
9
+ StyleSheet,
10
+ TouchableOpacity,
11
+ View,
12
+ } from 'react-native';
13
+ import { commonStyles } from '../CommonStyles';
14
+ import { IconBackWhite } from '../../assets/icons';
15
+ import { MText } from '../../components/MText';
16
+ import {
17
+ CodeField,
18
+ Cursor,
19
+ useBlurOnFulfill,
20
+ useClearByFocusCell,
21
+ } from 'react-native-confirmation-code-field';
22
+ import { Api } from '../../services/api';
23
+ import Loading from '../../components/Loading';
24
+ import { ScreenNames } from '../../navigation';
25
+
26
+ const logoView: ImageStyle = {
27
+ position: 'absolute',
28
+ width: '100%',
29
+ height: '100%',
30
+ resizeMode: 'cover',
31
+ };
32
+
33
+ export default function TTSOTP({ navigation, route }: any) {
34
+ const loan = route?.params?.loan;
35
+ const [description, setDescription] = useState(
36
+ 'Vui lòng click “Gửi mã OTP” để nhận mã xác thực được gửi vào số điện thoại của bạn'
37
+ );
38
+ const [timeLeft, setTimeLeft] = useState(300);
39
+ const [isResendEnabled, setIsResendEnabled] = useState(false);
40
+ const [isLoading, setIsLoading] = useState(false);
41
+ const [isCounting, setIsCounting] = useState(false);
42
+ const CELL_COUNT = 6;
43
+ const [value, setValue] = useState('');
44
+ const ref = useBlurOnFulfill({ value, cellCount: CELL_COUNT });
45
+
46
+ const [props, getCellOnLayoutHandler] = useClearByFocusCell({
47
+ value,
48
+ setValue,
49
+ });
50
+
51
+ useEffect(() => {
52
+ let interval: NodeJS.Timeout;
53
+ if (isCounting && timeLeft > 0) {
54
+ interval = setInterval(() => {
55
+ setTimeLeft((prev) => prev - 1);
56
+ }, 1000);
57
+ } else if (timeLeft === 0) {
58
+ setIsCounting(false);
59
+ setIsResendEnabled(true);
60
+ }
61
+ return () => clearInterval(interval);
62
+ }, [isCounting, timeLeft]);
63
+
64
+ const sendOtp = async () => {
65
+ setIsLoading(true);
66
+ const response = await Api.getInstance().signContractForBorrower({
67
+ loanBriefId: loan.id,
68
+ });
69
+ setIsLoading(false);
70
+ if (response.kind === 'ok' && response.data.meta.errorCode === 200) {
71
+ setTimeLeft(300);
72
+ setDescription(
73
+ 'Mã xác thực OTP của bạn sẽ được gửi vào số điện thoại của bạn, vui lòng nhập mã để hoàn thành ký hợp đồng.'
74
+ );
75
+ setIsCounting(true);
76
+ } else {
77
+ Alert.alert('Thông báo', response.data.meta.errorMessage, [
78
+ { text: 'Đồng ý' },
79
+ ]);
80
+ setValue('');
81
+ }
82
+ };
83
+
84
+ const resendOtp = async () => {
85
+ setIsLoading(true);
86
+ const response = await Api.getInstance().eSignSendOTP({
87
+ customerId: loan?.id,
88
+ });
89
+ setIsLoading(false);
90
+ if (response.kind === 'ok' && response.data.meta.errorCode === 200) {
91
+ setDescription(
92
+ 'Mã xác thực OTP đã được gửi lại vào số điện thoại của bạn, vui lòng nhập mã để hoàn thành ký hợp đồng.'
93
+ );
94
+ setTimeLeft(300);
95
+ setIsCounting(true);
96
+ setIsResendEnabled(false);
97
+ setValue('');
98
+ } else {
99
+ Alert.alert('Thông báo', response.data.meta.errorMessage, [
100
+ { text: 'Đồng ý' },
101
+ ]);
102
+ setValue('');
103
+ }
104
+ };
105
+
106
+ const onSubmit = async () => {
107
+ if (value.length === CELL_COUNT) {
108
+ setIsLoading(true);
109
+ const response = await Api.getInstance().confirmSignContractForBorrower({
110
+ loanBriefId: loan.id,
111
+ otp: value,
112
+ });
113
+ setIsLoading(false);
114
+ if (response.kind === 'ok' && response.data.meta.errorCode === 200) {
115
+ Alert.alert('Thông báo', 'Ký hợp đồng thành công', [
116
+ {
117
+ text: 'Đồng ý',
118
+ onPress: () => {
119
+ navigation.dispatch(
120
+ CommonActions.reset({
121
+ index: 1,
122
+ routes: [
123
+ {
124
+ name: ScreenNames.Main,
125
+ },
126
+ ],
127
+ })
128
+ );
129
+ },
130
+ },
131
+ ]);
132
+ } else {
133
+ Alert.alert('Thông báo', response.data.meta.errorMessage, [
134
+ { text: 'Đồng ý' },
135
+ ]);
136
+ setValue('');
137
+ }
138
+ } else {
139
+ Alert.alert('Thông báo', 'Vui lòng nhập đầy đủ mã OTP gồm 6 chữ số.', [
140
+ { text: 'Đồng ý' },
141
+ ]);
142
+ setValue('');
143
+ }
144
+ };
145
+
146
+ const formatTime = (seconds: number) => {
147
+ const m = Math.floor(seconds / 60)
148
+ .toString()
149
+ .padStart(2, '0');
150
+ const s = (seconds % 60).toString().padStart(2, '0');
151
+ return `${m}:${s}`;
152
+ };
153
+
154
+ return (
155
+ <View style={commonStyles.fill}>
156
+ <Image source={require('../../assets/tts/otp.png')} style={logoView} />
157
+ <SafeAreaView style={commonStyles.fill}>
158
+ <View
159
+ style={{
160
+ paddingVertical: 16,
161
+ }}
162
+ >
163
+ <TouchableOpacity
164
+ onPress={() => {
165
+ navigation.goBack();
166
+ }}
167
+ style={{
168
+ position: 'absolute',
169
+ left: 10,
170
+ top: 16,
171
+ width: 25,
172
+ height: 25,
173
+ zIndex: 1000,
174
+ alignItems: 'center',
175
+ }}
176
+ >
177
+ <IconBackWhite />
178
+ </TouchableOpacity>
179
+ <MText
180
+ style={{
181
+ fontSize: 16,
182
+ color: '#FDFDFD',
183
+ fontWeight: 'bold',
184
+ textAlign: 'center',
185
+ }}
186
+ >
187
+ Xác thực OTP
188
+ </MText>
189
+ </View>
190
+ <ScrollView>
191
+ <MText
192
+ style={{
193
+ color: '#FFFFFF',
194
+ textAlign: 'center',
195
+ marginTop: 16,
196
+ paddingHorizontal: 24,
197
+ }}
198
+ >
199
+ {description}
200
+ </MText>
201
+ <CodeField
202
+ ref={ref}
203
+ {...props}
204
+ value={value}
205
+ onChangeText={setValue}
206
+ cellCount={CELL_COUNT}
207
+ rootStyle={styles.codeFieldRoot}
208
+ keyboardType="number-pad"
209
+ textContentType="oneTimeCode"
210
+ renderCell={({ index, symbol, isFocused }) => (
211
+ <View
212
+ key={index}
213
+ style={[styles.cell, isFocused && styles.focusCell]}
214
+ onLayout={getCellOnLayoutHandler(index)}
215
+ >
216
+ <MText style={styles.cellText}>
217
+ {symbol || (isFocused ? <Cursor /> : null)}
218
+ </MText>
219
+ </View>
220
+ )}
221
+ />
222
+ <View
223
+ style={{
224
+ flexDirection: 'row',
225
+ alignItems: 'center',
226
+ justifyContent: 'center',
227
+ marginTop: 40,
228
+ }}
229
+ >
230
+ {isCounting ? (
231
+ <TouchableOpacity
232
+ onPress={() => {
233
+ onSubmit();
234
+ }}
235
+ style={{
236
+ backgroundColor: 'white',
237
+ borderRadius: 4,
238
+ height: 40,
239
+ alignItems: 'center',
240
+ paddingHorizontal: 20,
241
+ justifyContent: 'center',
242
+ }}
243
+ >
244
+ <MText
245
+ style={{
246
+ color: 'rgba(239, 89, 46, 1)',
247
+ fontSize: 16,
248
+ }}
249
+ >
250
+ Xác nhận
251
+ </MText>
252
+ </TouchableOpacity>
253
+ ) : isResendEnabled ? (
254
+ <TouchableOpacity
255
+ onPress={() => {
256
+ resendOtp();
257
+ }}
258
+ style={{
259
+ backgroundColor: 'white',
260
+ borderRadius: 4,
261
+ height: 40,
262
+ alignItems: 'center',
263
+ paddingHorizontal: 20,
264
+ justifyContent: 'center',
265
+ }}
266
+ >
267
+ <MText
268
+ style={{
269
+ color: 'rgba(239, 89, 46, 1)',
270
+ fontSize: 16,
271
+ }}
272
+ >
273
+ Gửi lại mã OTP
274
+ </MText>
275
+ </TouchableOpacity>
276
+ ) : (
277
+ <TouchableOpacity
278
+ onPress={() => {
279
+ sendOtp();
280
+ }}
281
+ style={{
282
+ backgroundColor: 'white',
283
+ borderRadius: 4,
284
+ height: 40,
285
+ alignItems: 'center',
286
+ paddingHorizontal: 20,
287
+ justifyContent: 'center',
288
+ }}
289
+ >
290
+ <MText
291
+ style={{
292
+ color: 'rgba(239, 89, 46, 1)',
293
+ fontSize: 16,
294
+ }}
295
+ >
296
+ Gửi mã OTP
297
+ </MText>
298
+ </TouchableOpacity>
299
+ )}
300
+ </View>
301
+ {isCounting && (
302
+ <MText
303
+ style={{
304
+ textAlign: 'center',
305
+ marginTop: 16,
306
+ color: '#FFFFFF',
307
+ fontSize: 14,
308
+ }}
309
+ >
310
+ Gửi lại mã OTP sau{' '}
311
+ <MText
312
+ style={{
313
+ color: '#FFFFFF',
314
+ fontWeight: 'bold',
315
+ }}
316
+ >
317
+ ({formatTime(timeLeft)})
318
+ </MText>
319
+ </MText>
320
+ )}
321
+ </ScrollView>
322
+ </SafeAreaView>
323
+ <Loading isLoading={isLoading} />
324
+ </View>
325
+ );
326
+ }
327
+
328
+ const styles = StyleSheet.create({
329
+ codeFieldRoot: {
330
+ width: '85%',
331
+ alignSelf: 'center',
332
+ marginTop: 24,
333
+ },
334
+
335
+ cell: {
336
+ width: 50,
337
+ height: 50,
338
+ borderRadius: 8,
339
+ justifyContent: 'center',
340
+ alignItems: 'center',
341
+ backgroundColor: 'rgba(253, 253, 253, 0.3)',
342
+ },
343
+ focusCell: {
344
+ // backgroundColor: '#FFFFFF',
345
+ // borderRadius: 8,
346
+ // borderWidth: 1,
347
+ // borderColor: '#EF592E',
348
+ },
349
+
350
+ cellText: {
351
+ fontSize: 24,
352
+ textAlign: 'center',
353
+ color: '#FFFFFF',
354
+ fontWeight: 'bold',
355
+ },
356
+ });
@@ -0,0 +1,267 @@
1
+ //@ts-nocheck
2
+ import React, { useEffect, useRef, useState } from 'react';
3
+ import {
4
+ ActivityIndicator,
5
+ Alert,
6
+ Dimensions,
7
+ Platform,
8
+ View,
9
+ } from 'react-native';
10
+ import { CommonActions, useNavigation } from '@react-navigation/native';
11
+ import {
12
+ request,
13
+ PERMISSIONS,
14
+ RESULTS,
15
+ openSettings,
16
+ } from 'react-native-permissions';
17
+ import { RNCamera } from 'react-native-camera';
18
+ import { MText } from '../../components/MText';
19
+ import MButton from '../../components/MButton';
20
+ import { commonStyles } from '../CommonStyles';
21
+ import { IconBackWhite, TakePhotoSvg } from '../../assets/icons';
22
+ import Loading from '../../components/Loading';
23
+ import { Api } from '../../services/api';
24
+ import { ScreenNames } from '../../navigation';
25
+
26
+ export default function TTSSelfie(props: any) {
27
+ const navigation = useNavigation();
28
+ const [taking, setTaking] = useState(false);
29
+ const [isLoading, setIsLoading] = useState(false);
30
+ const [passPermission, setPassPermission] = useState(false);
31
+
32
+ const myCamera = useRef(null);
33
+
34
+ const requestPermissions = () => {
35
+ request(
36
+ Platform.OS === 'ios'
37
+ ? PERMISSIONS.IOS.CAMERA
38
+ : PERMISSIONS.ANDROID.CAMERA
39
+ ).then((result) => {
40
+ switch (result) {
41
+ case RESULTS.UNAVAILABLE:
42
+ console.log(
43
+ 'This feature is not available (on this device / in this context)'
44
+ );
45
+ Alert.alert(
46
+ 'Thông báo',
47
+ 'Máy ảnh trên thiết bị không tương thích.\nVui lòng kiểm tra lại thiết bị!',
48
+ [{ text: 'Đồng ý' }]
49
+ );
50
+ break;
51
+ case RESULTS.DENIED:
52
+ console.log(
53
+ 'The permission has not been requested / is denied but requestable'
54
+ );
55
+ Alert.alert(
56
+ 'Thông báo',
57
+ 'Bạn đã từ chối quyền máy ảnh. Vui lòng cấp quyền máy ảnh để tiếp tục!',
58
+ [
59
+ {
60
+ text: 'Đồng ý',
61
+ onPress: () => {
62
+ if (Platform.OS === 'ios') {
63
+ openSettings();
64
+ } else {
65
+ requestPermissions();
66
+ }
67
+ },
68
+ },
69
+ ]
70
+ );
71
+ break;
72
+ case RESULTS.LIMITED:
73
+ console.log('The permission is limited: some actions are possible');
74
+ Alert.alert(
75
+ 'Thông báo',
76
+ 'Quyền máy ảnh bị hạn chế. Vui lòng kiểm tra lại để tiếp tục!',
77
+ [
78
+ {
79
+ text: 'Đồng ý',
80
+ onPress: () => {
81
+ if (Platform.OS === 'ios') {
82
+ openSettings();
83
+ } else {
84
+ requestPermissions();
85
+ }
86
+ },
87
+ },
88
+ ]
89
+ );
90
+ break;
91
+ case RESULTS.GRANTED:
92
+ console.log('The permission is granted');
93
+ setPassPermission(true);
94
+ break;
95
+ case RESULTS.BLOCKED:
96
+ console.log('The permission is denied and not requestable anymore');
97
+ Alert.alert(
98
+ 'Thông báo',
99
+ 'Bạn đã từ chối quyền máy ảnh. Vui lòng cấp quyền máy ảnh để tiếp tục!',
100
+ [
101
+ {
102
+ text: 'Đồng ý',
103
+ onPress: () => {
104
+ if (Platform.OS === 'ios') {
105
+ openSettings();
106
+ } else {
107
+ openSettings();
108
+ }
109
+ },
110
+ },
111
+ ]
112
+ );
113
+ break;
114
+ }
115
+ });
116
+ };
117
+
118
+ useEffect(() => {
119
+ requestPermissions();
120
+ }, []);
121
+
122
+ const takePhoto = async () => {
123
+ setTaking(true);
124
+ const options = {
125
+ pauseAfterCapture: true,
126
+ fixOrientation: false,
127
+ forceUpOrientation: false,
128
+ orientation: RNCamera.Constants.Orientation.portrait,
129
+ };
130
+ const data = await myCamera.current.takePictureAsync(options);
131
+ setTaking(false);
132
+ if (data.uri) {
133
+ setIsLoading(true);
134
+ const formData = new FormData();
135
+ formData.append('LoanBriefId', props?.route?.params?.loan?.id);
136
+ formData.append('TypeDocumentId', 125); // Anh selfie
137
+ formData.append('image', {
138
+ uri: data.uri,
139
+ type: 'image/jpg',
140
+ name: 'image.jpg',
141
+ });
142
+ const response = await Api.getInstance().uploadImageOcr(formData);
143
+ setIsLoading(false);
144
+ if (response.kind === 'ok') {
145
+ if (response.data?.meta.errorCode === 200) {
146
+ navigation.push(ScreenNames.VehicleCamera, {
147
+ front: true,
148
+ loan: props?.route?.params?.loan,
149
+ });
150
+ } else {
151
+ Alert.alert('Thông báo', response.data?.meta?.errorMessage);
152
+ }
153
+ } else {
154
+ Alert.alert('Thông báo', 'Có lỗi xảy ra. Vui lòng thử lại sau');
155
+ }
156
+ }
157
+ };
158
+
159
+ return (
160
+ <View
161
+ style={{ flex: 1, backgroundColor: 'black' }}
162
+ pointerEvents={'box-none'}
163
+ >
164
+ {passPermission && (
165
+ <View
166
+ style={[
167
+ commonStyles.fill,
168
+ {
169
+ width: Dimensions.get('window').width,
170
+ height: Dimensions.get('window').height,
171
+ },
172
+ ]}
173
+ >
174
+ <View
175
+ style={{
176
+ marginVertical: 24,
177
+ flexDirection: 'row',
178
+ alignItems: 'center',
179
+ justifyContent: 'center',
180
+ }}
181
+ >
182
+ <MButton
183
+ onPress={() => {
184
+ navigation.goBack();
185
+ }}
186
+ style={{
187
+ position: 'absolute',
188
+ left: 16,
189
+ }}
190
+ >
191
+ <IconBackWhite />
192
+ </MButton>
193
+ <MText
194
+ style={{
195
+ color: 'white',
196
+ fontWeight: 'bold',
197
+ textAlgin: 'center',
198
+ }}
199
+ >
200
+ Xác thực khuôn mặt
201
+ </MText>
202
+ </View>
203
+ <RNCamera
204
+ ref={myCamera}
205
+ defaultVideoQuality={RNCamera.Constants.VideoQuality['720p']}
206
+ style={{
207
+ width: Dimensions.get('window').width,
208
+ height: (Dimensions.get('window').width * 4) / 3.1,
209
+ }}
210
+ type={RNCamera.Constants.Type.front}
211
+ maxZoom={1}
212
+ androidCameraPermissionOptions={{
213
+ title: 'Permission to use camera',
214
+ message: 'We need your permission to use your camera',
215
+ buttonPositive: 'Ok',
216
+ buttonNegative: 'Cancel',
217
+ }}
218
+ >
219
+ {({ camera, status, recordAudioPermissionStatus }) => {
220
+ if (status !== 'READY') return <ActivityIndicator />;
221
+ }}
222
+ </RNCamera>
223
+
224
+ <View
225
+ style={{
226
+ position: 'absolute',
227
+ bottom: 20,
228
+ left: 0,
229
+ right: 0,
230
+ }}
231
+ >
232
+ {!taking && (
233
+ <>
234
+ <MText
235
+ style={{
236
+ color: 'white',
237
+ textAlign: 'center',
238
+ fontSize: 14,
239
+ }}
240
+ >
241
+ Xin vui lòng nhìn thẳng, khuôn mặt ở trong khung hình, ánh
242
+ sáng đủ rõ nét khuôn mặt
243
+ </MText>
244
+ <View
245
+ style={{
246
+ alignItems: 'center',
247
+ marginVertical: 24,
248
+ }}
249
+ >
250
+ <MButton
251
+ onPress={() => {
252
+ takePhoto();
253
+ }}
254
+ >
255
+ <TakePhotoSvg />
256
+ </MButton>
257
+ </View>
258
+ </>
259
+ )}
260
+ </View>
261
+ </View>
262
+ )}
263
+
264
+ <Loading isLoading={isLoading} />
265
+ </View>
266
+ );
267
+ }