@tap-payments/auth-jsconnect 2.6.2-test → 2.6.3

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 (638) hide show
  1. package/README.md +1 -1
  2. package/build/@types/app.d.ts +150 -12
  3. package/build/@types/app.js +18 -1
  4. package/build/@types/config.d.ts +45 -0
  5. package/build/@types/config.js +1 -0
  6. package/build/@types/form.d.ts +19 -2
  7. package/build/@types/index.d.ts +1 -0
  8. package/build/@types/index.js +1 -0
  9. package/build/@types/redux.d.ts +1 -0
  10. package/build/@types/theme.d.ts +4 -0
  11. package/build/@types/theme.js +5 -0
  12. package/build/api/account.d.ts +5 -0
  13. package/build/api/account.js +16 -2
  14. package/build/api/auth.d.ts +25 -1
  15. package/build/api/auth.js +18 -1
  16. package/build/api/availabilityServices.d.ts +1 -0
  17. package/build/api/country.d.ts +1 -0
  18. package/build/api/country.js +8 -1
  19. package/build/api/data.d.ts +4 -17
  20. package/build/api/data.js +5 -45
  21. package/build/api/entity.d.ts +30 -2
  22. package/build/api/entity.js +49 -5
  23. package/build/api/firebase.js +68 -8
  24. package/build/api/index.d.ts +21 -25
  25. package/build/api/lead.d.ts +25 -3
  26. package/build/api/lead.js +47 -1
  27. package/build/api/operator.d.ts +10 -0
  28. package/build/api/operator.js +9 -1
  29. package/build/app/rootReducer.d.ts +2 -0
  30. package/build/app/rootReducer.js +5 -1
  31. package/build/app/settings.d.ts +14 -3
  32. package/build/app/settings.js +127 -41
  33. package/build/app/store.d.ts +4 -0
  34. package/build/assets/locales/ar.json +333 -131
  35. package/build/assets/locales/en.json +330 -131
  36. package/build/components/AnimationFlow/AnimationFlow.d.ts +14 -3
  37. package/build/components/AnimationFlow/AnimationFlow.js +16 -5
  38. package/build/components/AnimationFlow/BottomSheet.d.ts +7 -2
  39. package/build/components/AnimationFlow/BottomSheet.js +37 -12
  40. package/build/components/AnimationFlow/Dialog.d.ts +11 -2
  41. package/build/components/AnimationFlow/Dialog.js +7 -11
  42. package/build/components/AnimationFlow/Loader.d.ts +6 -1
  43. package/build/components/AnimationFlow/Loader.js +17 -5
  44. package/build/components/ArabicDatePicker/ArabicDatePicker.d.ts +1 -1
  45. package/build/components/ArabicDatePicker/ArabicDatePicker.js +2 -2
  46. package/build/components/DatePicker/DatePicker.d.ts +1 -1
  47. package/build/components/DatePicker/DatePicker.js +2 -2
  48. package/build/components/ExpandIcon/ExpandIcon.d.ts +2 -0
  49. package/build/components/Footer/Footer.js +2 -1
  50. package/build/components/Providers/ThemeProvider.js +3 -3
  51. package/build/components/SimpleList/SimpleList.js +1 -1
  52. package/build/components/Slide/Slide.d.ts +1 -1
  53. package/build/components/Tooltip/Tooltip.js +1 -1
  54. package/build/constants/api.d.ts +11 -7
  55. package/build/constants/api.js +22 -14
  56. package/build/constants/app.d.ts +47 -0
  57. package/build/constants/app.js +393 -22
  58. package/build/constants/assets.d.ts +4 -0
  59. package/build/constants/assets.js +5 -1
  60. package/build/constants/dummy.d.ts +43 -196
  61. package/build/constants/dummy.js +614 -6141
  62. package/build/constants/validation.d.ts +5 -0
  63. package/build/constants/validation.js +6 -1
  64. package/build/features/app/auth/authStore.d.ts +103 -0
  65. package/build/features/app/auth/authStore.js +1179 -0
  66. package/build/features/app/bank/bankStore.d.ts +14 -18
  67. package/build/features/app/bank/bankStore.js +218 -158
  68. package/build/features/app/board/boardStore.d.ts +33 -0
  69. package/build/features/app/board/boardStore.js +269 -0
  70. package/build/features/app/brand/brandStore.d.ts +18 -31
  71. package/build/features/app/brand/brandStore.js +296 -263
  72. package/build/features/app/business/businessStore.d.ts +28 -10
  73. package/build/features/app/business/businessStore.js +361 -215
  74. package/build/features/app/connect/connectStore.d.ts +39 -15
  75. package/build/features/app/connect/connectStore.js +308 -207
  76. package/build/features/app/connectExpress/connectExpressStore.d.ts +71 -26
  77. package/build/features/app/connectExpress/connectExpressStore.js +897 -302
  78. package/build/features/app/entity/entityStore.d.ts +21 -34
  79. package/build/features/app/entity/entityStore.js +248 -246
  80. package/build/features/app/individual/individualStore.d.ts +24 -33
  81. package/build/features/app/individual/individualStore.js +336 -274
  82. package/build/features/app/password/passwordStore.d.ts +34 -18
  83. package/build/features/app/password/passwordStore.js +286 -219
  84. package/build/features/app/tax/taxStore.d.ts +14 -7
  85. package/build/features/app/tax/taxStore.js +202 -141
  86. package/build/features/auth/Auth.d.ts +14 -0
  87. package/build/features/auth/Auth.js +168 -0
  88. package/build/features/auth/index.d.ts +1 -0
  89. package/build/features/auth/index.js +1 -0
  90. package/build/features/auth/screens/AccountCreatedLoader/AccountCreatedLoader.d.ts +5 -0
  91. package/build/features/auth/screens/AccountCreatedLoader/AccountCreatedLoader.js +36 -0
  92. package/build/features/auth/screens/AccountCreatedLoader/index.d.ts +2 -0
  93. package/build/features/auth/screens/AccountCreatedLoader/index.js +2 -0
  94. package/build/features/auth/screens/AccountNotFound/AccountNotFound.d.ts +5 -0
  95. package/build/features/auth/screens/AccountNotFound/AccountNotFound.js +71 -0
  96. package/build/features/auth/screens/AccountNotFound/index.d.ts +2 -0
  97. package/build/features/auth/screens/AccountNotFound/index.js +2 -0
  98. package/build/features/auth/screens/AuthMerchant/AuthMerchant.d.ts +5 -0
  99. package/build/features/auth/screens/AuthMerchant/AuthMerchant.js +73 -0
  100. package/build/features/auth/screens/AuthMerchant/MerchantList.d.ts +11 -0
  101. package/build/features/auth/screens/AuthMerchant/MerchantList.js +64 -0
  102. package/build/features/auth/screens/AuthMerchant/index.d.ts +2 -0
  103. package/build/features/auth/screens/AuthMerchant/index.js +2 -0
  104. package/build/features/auth/screens/AuthMerchant/validation.d.ts +8 -0
  105. package/build/features/auth/screens/AuthMerchant/validation.js +4 -0
  106. package/build/features/auth/screens/AuthSwitch/AuthSwitch.d.ts +5 -0
  107. package/build/features/auth/screens/AuthSwitch/AuthSwitch.js +58 -0
  108. package/build/features/auth/screens/AuthSwitch/index.d.ts +3 -0
  109. package/build/features/auth/screens/AuthSwitch/index.js +2 -0
  110. package/build/features/auth/screens/AuthenticationList/AuthenticationList.d.ts +5 -0
  111. package/build/features/auth/screens/AuthenticationList/AuthenticationList.js +96 -0
  112. package/build/features/auth/screens/AuthenticationList/BrandList.d.ts +10 -0
  113. package/build/features/auth/screens/AuthenticationList/BrandList.js +81 -0
  114. package/build/features/auth/screens/AuthenticationList/EntityLegalName.d.ts +3 -0
  115. package/build/features/auth/screens/AuthenticationList/EntityLegalName.js +48 -0
  116. package/build/features/auth/screens/AuthenticationList/EntityLicenseType.d.ts +31 -0
  117. package/build/features/auth/screens/AuthenticationList/EntityLicenseType.js +90 -0
  118. package/build/features/auth/screens/AuthenticationList/EntityList.d.ts +11 -0
  119. package/build/features/auth/screens/AuthenticationList/EntityList.js +138 -0
  120. package/build/features/auth/screens/AuthenticationList/LicenseNumber.d.ts +3 -0
  121. package/build/features/auth/screens/AuthenticationList/LicenseNumber.js +36 -0
  122. package/build/features/auth/screens/AuthenticationList/index.d.ts +3 -0
  123. package/build/features/auth/screens/AuthenticationList/index.js +2 -0
  124. package/build/features/auth/screens/AuthenticationList/validation.d.ts +20 -0
  125. package/build/features/auth/screens/AuthenticationList/validation.js +68 -0
  126. package/build/features/auth/screens/BusinessCountry/BusinessCountry.d.ts +5 -0
  127. package/build/features/auth/screens/BusinessCountry/BusinessCountry.js +111 -0
  128. package/build/features/auth/screens/BusinessCountry/index.d.ts +3 -0
  129. package/build/features/auth/screens/BusinessCountry/index.js +2 -0
  130. package/build/features/auth/screens/CivilID/CivilID.d.ts +5 -0
  131. package/build/features/auth/screens/CivilID/CivilID.js +57 -0
  132. package/build/features/auth/screens/CivilID/IDNumber.d.ts +8 -0
  133. package/build/features/auth/screens/CivilID/IDNumber.js +54 -0
  134. package/build/features/auth/screens/CivilID/index.d.ts +3 -0
  135. package/build/features/auth/screens/CivilID/index.js +2 -0
  136. package/build/features/auth/screens/CivilID/validation.d.ts +8 -0
  137. package/build/features/auth/screens/CivilID/validation.js +4 -0
  138. package/build/features/auth/screens/DOB/DOB.js +47 -0
  139. package/build/features/auth/screens/DOB/DOBForm.d.ts +5 -0
  140. package/build/features/auth/screens/DOB/DOBForm.js +59 -0
  141. package/build/features/auth/screens/DOB/index.d.ts +3 -0
  142. package/build/features/auth/screens/DOB/index.js +2 -0
  143. package/build/features/auth/screens/DOB/validation.d.ts +8 -0
  144. package/build/features/auth/screens/DOB/validation.js +4 -0
  145. package/build/features/auth/screens/Email/Email.d.ts +5 -0
  146. package/build/features/auth/screens/Email/Email.js +57 -0
  147. package/build/features/auth/screens/Email/EmailField.d.ts +8 -0
  148. package/build/features/auth/screens/Email/EmailField.js +52 -0
  149. package/build/features/auth/screens/Email/index.d.ts +3 -0
  150. package/build/features/auth/screens/Email/index.js +2 -0
  151. package/build/features/auth/screens/Email/validation.d.ts +8 -0
  152. package/build/features/auth/screens/Email/validation.js +4 -0
  153. package/build/features/auth/screens/EmailSent/EmailSent.d.ts +5 -0
  154. package/build/features/auth/screens/EmailSent/EmailSent.js +79 -0
  155. package/build/features/auth/screens/EmailSent/index.d.ts +2 -0
  156. package/build/features/auth/screens/EmailSent/index.js +2 -0
  157. package/build/features/auth/screens/MigratingData/MigratingData.d.ts +5 -0
  158. package/build/features/auth/screens/MigratingData/MigratingData.js +44 -0
  159. package/build/features/auth/screens/MigratingData/index.d.ts +2 -0
  160. package/build/features/auth/screens/MigratingData/index.js +2 -0
  161. package/build/features/auth/screens/Mobile/Mobile.d.ts +5 -0
  162. package/build/features/auth/screens/Mobile/Mobile.js +82 -0
  163. package/build/features/auth/screens/Mobile/MobileNumber.d.ts +13 -0
  164. package/build/features/auth/screens/Mobile/MobileNumber.js +158 -0
  165. package/build/features/auth/screens/Mobile/index.d.ts +3 -0
  166. package/build/features/auth/screens/Mobile/index.js +2 -0
  167. package/build/features/auth/screens/Mobile/validation.d.ts +8 -0
  168. package/build/features/auth/screens/Mobile/validation.js +35 -0
  169. package/build/features/auth/screens/NID/IDNumber.d.ts +7 -0
  170. package/build/features/auth/screens/NID/IDNumber.js +55 -0
  171. package/build/features/auth/screens/NID/NID.d.ts +5 -0
  172. package/build/features/auth/screens/NID/NID.js +56 -0
  173. package/build/features/auth/screens/NID/index.d.ts +3 -0
  174. package/build/features/auth/screens/NID/index.js +2 -0
  175. package/build/features/auth/screens/NID/validation.d.ts +8 -0
  176. package/build/features/auth/screens/NID/validation.js +10 -0
  177. package/build/features/auth/screens/OTP/OTP.js +118 -0
  178. package/build/features/{connectExpress/screens/IdentityOTP → auth/screens/OTP}/OTPInput.js +27 -7
  179. package/build/features/auth/screens/OperatorError/OperatorError.d.ts +5 -0
  180. package/build/features/auth/screens/OperatorError/OperatorError.js +9 -0
  181. package/build/features/auth/screens/OperatorError/index.d.ts +3 -0
  182. package/build/features/auth/screens/OperatorError/index.js +2 -0
  183. package/build/features/auth/screens/Password/Password.d.ts +5 -0
  184. package/build/features/auth/screens/Password/Password.js +61 -0
  185. package/build/features/auth/screens/Password/PasswordField.d.ts +5 -0
  186. package/build/features/auth/screens/Password/PasswordField.js +28 -0
  187. package/build/features/auth/screens/Password/index.d.ts +3 -0
  188. package/build/features/auth/screens/Password/index.js +2 -0
  189. package/build/features/auth/screens/Password/validation.d.ts +8 -0
  190. package/build/features/auth/screens/Password/validation.js +4 -0
  191. package/build/features/auth/screens/PreparingData/PreparingData.d.ts +5 -0
  192. package/build/features/auth/screens/PreparingData/PreparingData.js +44 -0
  193. package/build/features/auth/screens/PreparingData/index.d.ts +2 -0
  194. package/build/features/auth/screens/PreparingData/index.js +2 -0
  195. package/build/features/auth/screens/ResetPasswordMessage/ResetPasswordMessage.d.ts +5 -0
  196. package/build/features/auth/screens/ResetPasswordMessage/ResetPasswordMessage.js +21 -0
  197. package/build/features/auth/screens/ResetPasswordMessage/index.d.ts +3 -0
  198. package/build/features/auth/screens/ResetPasswordMessage/index.js +2 -0
  199. package/build/features/auth/screens/VerifyNafath/VerifyNafath.d.ts +5 -0
  200. package/build/features/auth/screens/VerifyNafath/VerifyNafath.js +35 -0
  201. package/build/features/auth/screens/VerifyNafath/index.d.ts +3 -0
  202. package/build/features/auth/screens/VerifyNafath/index.js +2 -0
  203. package/build/features/auth/screens/VerifyPACI/VerifyPACI.d.ts +5 -0
  204. package/build/features/auth/screens/VerifyPACI/VerifyPACI.js +34 -0
  205. package/build/features/auth/screens/VerifyPACI/index.d.ts +3 -0
  206. package/build/features/auth/screens/VerifyPACI/index.js +2 -0
  207. package/build/features/bank/Bank.d.ts +2 -0
  208. package/build/features/bank/Bank.js +15 -9
  209. package/build/features/bank/screens/BankDetails/BankDetails.js +21 -7
  210. package/build/features/bank/screens/OperatorError/OperatorError.d.ts +5 -0
  211. package/build/features/bank/screens/OperatorError/OperatorError.js +9 -0
  212. package/build/features/bank/screens/OperatorError/index.d.ts +3 -0
  213. package/build/features/bank/screens/OperatorError/index.js +2 -0
  214. package/build/features/bank/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +13 -5
  215. package/build/features/bank/screens/Verify/Verify.js +8 -7
  216. package/build/features/board/Board.d.ts +13 -0
  217. package/build/features/board/Board.js +87 -0
  218. package/build/features/board/index.d.ts +1 -0
  219. package/build/features/board/index.js +1 -0
  220. package/build/features/board/screens/OperatorError/OperatorError.d.ts +5 -0
  221. package/build/features/board/screens/OperatorError/OperatorError.js +9 -0
  222. package/build/features/board/screens/OperatorError/index.d.ts +3 -0
  223. package/build/features/board/screens/OperatorError/index.js +2 -0
  224. package/build/features/board/screens/PrepareDataLoading/PrepareDataLoading.d.ts +4 -0
  225. package/build/features/board/screens/PrepareDataLoading/PrepareDataLoading.js +10 -0
  226. package/build/features/board/screens/PrepareDataLoading/index.d.ts +2 -0
  227. package/build/features/board/screens/PrepareDataLoading/index.js +2 -0
  228. package/build/features/board/screens/ResetPasswordSuccess/ResetPasswordSuccess.d.ts +5 -0
  229. package/build/features/board/screens/ResetPasswordSuccess/ResetPasswordSuccess.js +21 -0
  230. package/build/features/board/screens/ResetPasswordSuccess/index.d.ts +3 -0
  231. package/build/features/board/screens/ResetPasswordSuccess/index.js +2 -0
  232. package/build/features/board/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.d.ts +3 -0
  233. package/build/features/board/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +44 -0
  234. package/build/features/board/screens/SuccessWithFlowButtons/index.d.ts +2 -0
  235. package/build/features/board/screens/SuccessWithFlowButtons/index.js +2 -0
  236. package/build/features/board/screens/Verify/OTPInput.d.ts +7 -0
  237. package/build/features/{business/screens/OTP → board/screens/Verify}/OTPInput.js +9 -7
  238. package/build/features/{connectExpress/screens/IdentityOTP/OTP.js → board/screens/Verify/Verify.js} +25 -37
  239. package/build/features/board/screens/Verify/index.d.ts +2 -0
  240. package/build/features/board/screens/Verify/index.js +2 -0
  241. package/build/features/brand/Brand.d.ts +2 -0
  242. package/build/features/brand/Brand.js +15 -9
  243. package/build/features/brand/screens/BrandActivities/ActivitiesList.d.ts +9 -9
  244. package/build/features/brand/screens/BrandActivities/BrandActivities.js +49 -12
  245. package/build/features/brand/screens/BrandActivities/CustomerBase.d.ts +6 -6
  246. package/build/features/brand/screens/BrandActivities/CustomerBase.js +1 -1
  247. package/build/features/brand/screens/BrandActivities/ExpectedSalesRange.js +5 -2
  248. package/build/features/brand/screens/BrandActivities/RefundPolicy.d.ts +4 -4
  249. package/build/features/brand/screens/BrandActivities/RefundPolicy.js +1 -1
  250. package/build/features/brand/screens/BrandActivities/TAC.d.ts +1 -1
  251. package/build/features/brand/screens/BrandActivities/TAC.js +1 -1
  252. package/build/features/brand/screens/BrandActivities/TransactionPolicy.js +1 -1
  253. package/build/features/brand/screens/BrandInfo/BrandInfo.js +27 -7
  254. package/build/features/brand/screens/BrandInfo/BrandName.js +5 -2
  255. package/build/features/brand/screens/BrandInfo/validation.js +2 -2
  256. package/build/features/brand/screens/BrandSegmentInfo/BrandSegmentInfo.js +23 -7
  257. package/build/features/brand/screens/OperatorError/OperatorError.d.ts +5 -0
  258. package/build/features/brand/screens/OperatorError/OperatorError.js +9 -0
  259. package/build/features/brand/screens/OperatorError/index.d.ts +3 -0
  260. package/build/features/brand/screens/OperatorError/index.js +2 -0
  261. package/build/features/brand/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +13 -5
  262. package/build/features/brand/screens/Verify/Verify.js +4 -3
  263. package/build/features/business/Business.js +20 -12
  264. package/build/features/business/screens/Activities/Activities.js +27 -10
  265. package/build/features/business/screens/Activities/ActivitiesList.d.ts +4 -4
  266. package/build/features/business/screens/Activities/ActivitiesList.js +1 -1
  267. package/build/features/business/screens/Activities/OperationStartDate.d.ts +5 -3
  268. package/build/features/business/screens/Activities/OperationStartDate.js +2 -2
  269. package/build/features/business/screens/BrandDetails/SalesChannel.d.ts +2 -2
  270. package/build/features/business/screens/BusinessType/BusinessType.js +24 -8
  271. package/build/features/business/screens/BusinessType/EntityName.js +3 -3
  272. package/build/features/business/screens/BusinessType/LicenseList.js +3 -3
  273. package/build/features/business/screens/BusinessType/LicenseNumber.js +10 -9
  274. package/build/features/business/screens/BusinessType/LicenseType.d.ts +4 -4
  275. package/build/features/business/screens/BusinessType/validation.d.ts +10 -0
  276. package/build/features/business/screens/BusinessType/validation.js +16 -0
  277. package/build/features/business/screens/CivilID/CivilID.js +1 -1
  278. package/build/features/business/screens/Customers/CustomerLocations.d.ts +14 -12
  279. package/build/features/business/screens/Customers/CustomerLocations.js +5 -3
  280. package/build/features/business/screens/Customers/Customers.js +51 -11
  281. package/build/features/business/screens/Customers/ExpectedCustomers.d.ts +3 -1
  282. package/build/features/business/screens/Customers/ExpectedCustomers.js +5 -3
  283. package/build/features/business/screens/Customers/ExpectedSalesRange.d.ts +3 -1
  284. package/build/features/business/screens/Customers/ExpectedSalesRange.js +10 -4
  285. package/build/features/business/screens/Customers/RefundPolicy.d.ts +12 -5
  286. package/build/features/business/screens/Customers/RefundPolicy.js +13 -13
  287. package/build/features/business/screens/Customers/TransactionPolicy.d.ts +4 -1
  288. package/build/features/business/screens/Customers/TransactionPolicy.js +8 -5
  289. package/build/features/business/screens/Customers/validation.d.ts +6 -6
  290. package/build/features/business/screens/Customers/validation.js +3 -8
  291. package/build/features/business/screens/DOB/DOB.d.ts +6 -0
  292. package/build/features/business/screens/DOB/DOB.js +45 -0
  293. package/build/features/business/screens/DOB/DOBForm.d.ts +5 -0
  294. package/build/features/business/screens/DOB/DOBForm.js +72 -0
  295. package/build/features/business/screens/DOB/index.d.ts +3 -0
  296. package/build/features/business/screens/DOB/index.js +2 -0
  297. package/build/features/business/screens/DOB/validation.d.ts +8 -0
  298. package/build/features/business/screens/DOB/validation.js +4 -0
  299. package/build/features/business/screens/IDBOD/ID.js +6 -2
  300. package/build/features/business/screens/IDBOD/IDBOD.js +18 -19
  301. package/build/features/business/screens/IDBOD/validation.d.ts +7 -0
  302. package/build/features/business/screens/IDBOD/validation.js +4 -1
  303. package/build/features/business/screens/OperatorError/OperatorError.d.ts +5 -0
  304. package/build/features/business/screens/OperatorError/OperatorError.js +9 -0
  305. package/build/features/business/screens/OperatorError/index.d.ts +3 -0
  306. package/build/features/business/screens/OperatorError/index.js +2 -0
  307. package/build/features/business/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +14 -3
  308. package/build/features/business/screens/Verify/Verify.js +16 -5
  309. package/build/features/business/screens/VerifyNafath/VerifyNafath.d.ts +5 -0
  310. package/build/features/business/screens/VerifyNafath/VerifyNafath.js +35 -0
  311. package/build/features/business/screens/VerifyNafath/index.d.ts +3 -0
  312. package/build/features/business/screens/VerifyNafath/index.js +2 -0
  313. package/build/features/connect/Connect.d.ts +5 -1
  314. package/build/features/connect/Connect.js +48 -31
  315. package/build/features/connect/screens/BrandSegment/BrandSegment.js +4 -26
  316. package/build/features/connect/screens/BrandSegment/TeamSize.js +1 -1
  317. package/build/features/connect/screens/BrandSegment/validation.d.ts +0 -9
  318. package/build/features/connect/screens/BrandSegment/validation.js +0 -3
  319. package/build/features/connect/screens/BusinessCountry/BusinessCountry.d.ts +5 -0
  320. package/build/features/connect/screens/BusinessCountry/BusinessCountry.js +113 -0
  321. package/build/features/connect/screens/BusinessCountry/index.d.ts +3 -0
  322. package/build/features/connect/screens/BusinessCountry/index.js +2 -0
  323. package/build/features/connect/screens/CivilID/CivilID.js +12 -4
  324. package/build/features/{connectExpress/screens/NID → connect/screens/DOB}/DOB.d.ts +1 -2
  325. package/build/features/connect/screens/{NID → DOB}/DOB.js +2 -2
  326. package/build/features/connect/screens/DOB/DOBForm.d.ts +5 -0
  327. package/build/features/connect/screens/DOB/DOBForm.js +59 -0
  328. package/build/features/connect/screens/DOB/index.d.ts +3 -0
  329. package/build/features/connect/screens/DOB/index.js +2 -0
  330. package/build/features/connect/screens/DOB/validation.d.ts +8 -0
  331. package/build/features/connect/screens/DOB/validation.js +4 -0
  332. package/build/features/connect/screens/Individual/Individual.js +12 -6
  333. package/build/features/connect/screens/Individual/MobileNumber.js +6 -3
  334. package/build/features/connect/screens/Individual/validation.js +8 -3
  335. package/build/features/connect/screens/Merchant/BrandList.js +3 -3
  336. package/build/features/connect/screens/Merchant/BrandName.js +5 -2
  337. package/build/features/connect/screens/Merchant/Merchant.js +1 -1
  338. package/build/features/connect/screens/Merchant/SalesChannels.js +1 -1
  339. package/build/features/connect/screens/Merchant/validation.js +2 -2
  340. package/build/features/connect/screens/Mobile/Mobile.js +14 -7
  341. package/build/features/connect/screens/Mobile/MobileNumber.js +14 -8
  342. package/build/features/connect/screens/Mobile/validation.js +8 -3
  343. package/build/features/connect/screens/NID/IDNumber.d.ts +1 -0
  344. package/build/features/connect/screens/NID/IDNumber.js +2 -2
  345. package/build/features/connect/screens/NID/NID.js +10 -13
  346. package/build/features/connect/screens/NID/validation.d.ts +0 -3
  347. package/build/features/connect/screens/NID/validation.js +0 -1
  348. package/build/features/connect/screens/OTP/OTP.js +7 -7
  349. package/build/features/connect/screens/OTP/OTPInput.js +3 -11
  350. package/build/features/connect/screens/OperatorError/OperatorError.d.ts +5 -0
  351. package/build/features/connect/screens/OperatorError/OperatorError.js +9 -0
  352. package/build/features/connect/screens/OperatorError/index.d.ts +3 -0
  353. package/build/features/connect/screens/OperatorError/index.js +2 -0
  354. package/build/features/connect/screens/VerifyNafath/VerifyNafath.d.ts +5 -0
  355. package/build/features/connect/screens/VerifyNafath/VerifyNafath.js +35 -0
  356. package/build/features/connect/screens/VerifyNafath/index.d.ts +3 -0
  357. package/build/features/connect/screens/VerifyNafath/index.js +2 -0
  358. package/build/features/connectExpress/ConnectExpress.d.ts +5 -3
  359. package/build/features/connectExpress/ConnectExpress.js +70 -40
  360. package/build/features/connectExpress/screens/AccountAlreadyCreated/AccountAlreadyCreated.js +14 -2
  361. package/build/features/connectExpress/screens/AccountCreatedLoader/AccountCreatedLoader.d.ts +5 -0
  362. package/build/features/connectExpress/screens/AccountCreatedLoader/AccountCreatedLoader.js +36 -0
  363. package/build/features/connectExpress/screens/AccountCreatedLoader/index.d.ts +2 -0
  364. package/build/features/connectExpress/screens/AccountCreatedLoader/index.js +2 -0
  365. package/build/features/connectExpress/screens/AuthMerchant/AuthMerchant.d.ts +5 -0
  366. package/build/features/connectExpress/screens/AuthMerchant/AuthMerchant.js +74 -0
  367. package/build/features/connectExpress/screens/AuthMerchant/MerchantList.d.ts +11 -0
  368. package/build/features/connectExpress/screens/AuthMerchant/MerchantList.js +64 -0
  369. package/build/features/connectExpress/screens/AuthMerchant/index.d.ts +2 -0
  370. package/build/features/connectExpress/screens/AuthMerchant/index.js +2 -0
  371. package/build/features/connectExpress/screens/AuthMerchant/validation.d.ts +8 -0
  372. package/build/features/connectExpress/screens/AuthMerchant/validation.js +4 -0
  373. package/build/features/connectExpress/screens/AuthenticationList/AuthenticationList.d.ts +5 -0
  374. package/build/features/connectExpress/screens/AuthenticationList/AuthenticationList.js +104 -0
  375. package/build/features/connectExpress/screens/AuthenticationList/BrandList.d.ts +10 -0
  376. package/build/features/connectExpress/screens/AuthenticationList/BrandList.js +81 -0
  377. package/build/features/connectExpress/screens/AuthenticationList/EntityLegalName.d.ts +3 -0
  378. package/build/features/connectExpress/screens/AuthenticationList/EntityLegalName.js +48 -0
  379. package/build/features/connectExpress/screens/AuthenticationList/EntityLicenseType.d.ts +31 -0
  380. package/build/features/connectExpress/screens/AuthenticationList/EntityLicenseType.js +90 -0
  381. package/build/features/connectExpress/screens/AuthenticationList/EntityList.d.ts +11 -0
  382. package/build/features/connectExpress/screens/AuthenticationList/EntityList.js +138 -0
  383. package/build/features/connectExpress/screens/AuthenticationList/LicenseNumber.d.ts +3 -0
  384. package/build/features/connectExpress/screens/AuthenticationList/LicenseNumber.js +36 -0
  385. package/build/features/connectExpress/screens/AuthenticationList/index.d.ts +3 -0
  386. package/build/features/connectExpress/screens/AuthenticationList/index.js +2 -0
  387. package/build/features/connectExpress/screens/AuthenticationList/validation.d.ts +20 -0
  388. package/build/features/connectExpress/screens/AuthenticationList/validation.js +68 -0
  389. package/build/features/connectExpress/screens/BusinessCountry/BusinessCountry.d.ts +5 -0
  390. package/build/features/connectExpress/screens/BusinessCountry/BusinessCountry.js +111 -0
  391. package/build/features/connectExpress/screens/BusinessCountry/index.d.ts +3 -0
  392. package/build/features/connectExpress/screens/BusinessCountry/index.js +2 -0
  393. package/build/features/connectExpress/screens/CivilID/CivilID.js +16 -5
  394. package/build/features/connectExpress/screens/CivilID/IDNumber.js +7 -2
  395. package/build/features/connectExpress/screens/CivilIDMissed/CivilID.js +2 -2
  396. package/build/features/connectExpress/screens/CollectBusinessInfo/BrandName.js +5 -2
  397. package/build/features/connectExpress/screens/CollectBusinessInfo/CollectBusinessInfo.js +20 -5
  398. package/build/features/connectExpress/screens/CollectBusinessInfo/LicenseList.js +6 -5
  399. package/build/features/connectExpress/screens/CollectBusinessInfo/LicenseNumber.js +9 -8
  400. package/build/features/connectExpress/screens/CollectBusinessInfo/LicenseType.d.ts +4 -4
  401. package/build/features/connectExpress/screens/CollectBusinessInfo/LicenseType.js +1 -1
  402. package/build/features/connectExpress/screens/CollectBusinessInfo/TAC.d.ts +1 -1
  403. package/build/features/connectExpress/screens/CollectBusinessInfo/validation.d.ts +13 -0
  404. package/build/features/connectExpress/screens/CollectBusinessInfo/validation.js +68 -1
  405. package/build/features/connectExpress/screens/CollectIndividualInfo/CollectIndividualInfo.js +34 -7
  406. package/build/features/connectExpress/screens/CollectIndividualInfo/MobileNumber.js +7 -4
  407. package/build/features/connectExpress/screens/CollectIndividualInfo/validation.js +8 -3
  408. package/build/features/connectExpress/screens/CreateAccountLoader/CreateAccountLoader.js +14 -24
  409. package/build/features/connectExpress/screens/DOB/DOB.d.ts +6 -0
  410. package/build/features/connectExpress/screens/{NID → DOB}/DOB.js +3 -3
  411. package/build/features/connectExpress/screens/DOB/DOBForm.d.ts +5 -0
  412. package/build/features/connectExpress/screens/DOB/DOBForm.js +63 -0
  413. package/build/features/connectExpress/screens/DOB/index.d.ts +3 -0
  414. package/build/features/connectExpress/screens/DOB/index.js +2 -0
  415. package/build/features/connectExpress/screens/DOB/validation.d.ts +8 -0
  416. package/build/features/connectExpress/screens/DOB/validation.js +4 -0
  417. package/build/features/connectExpress/screens/IdentityVerifyNafath/IdentityVerifyNafath.d.ts +5 -0
  418. package/build/features/connectExpress/screens/IdentityVerifyNafath/IdentityVerifyNafath.js +35 -0
  419. package/build/features/connectExpress/screens/IdentityVerifyNafath/index.d.ts +3 -0
  420. package/build/features/connectExpress/screens/IdentityVerifyNafath/index.js +2 -0
  421. package/build/features/connectExpress/screens/IdentityVerifyPACI/VerifyPACI.js +2 -2
  422. package/build/features/connectExpress/screens/Mobile/Mobile.js +17 -7
  423. package/build/features/connectExpress/screens/Mobile/MobileNumber.js +17 -11
  424. package/build/features/connectExpress/screens/Mobile/TAC.js +1 -1
  425. package/build/features/connectExpress/screens/Mobile/validation.js +16 -6
  426. package/build/features/connectExpress/screens/NID/IDNumber.d.ts +1 -0
  427. package/build/features/connectExpress/screens/NID/IDNumber.js +2 -2
  428. package/build/features/connectExpress/screens/NID/NID.js +15 -12
  429. package/build/features/connectExpress/screens/NID/TAC.d.ts +1 -1
  430. package/build/features/connectExpress/screens/NID/TAC.js +2 -2
  431. package/build/features/connectExpress/screens/NID/validation.d.ts +0 -3
  432. package/build/features/connectExpress/screens/NID/validation.js +0 -2
  433. package/build/features/connectExpress/screens/NIDMissed/IDNumber.js +6 -2
  434. package/build/features/connectExpress/screens/NIDMissed/NID.js +10 -8
  435. package/build/features/connectExpress/screens/NIDMissed/validation.d.ts +7 -0
  436. package/build/features/connectExpress/screens/NIDMissed/validation.js +4 -1
  437. package/build/features/connectExpress/screens/OTP/OTP.js +14 -16
  438. package/build/features/connectExpress/screens/OTP/OTPInput.js +12 -10
  439. package/build/features/connectExpress/screens/OperatorError/OperatorError.d.ts +5 -0
  440. package/build/features/connectExpress/screens/OperatorError/OperatorError.js +9 -0
  441. package/build/features/connectExpress/screens/OperatorError/index.d.ts +3 -0
  442. package/build/features/connectExpress/screens/OperatorError/index.js +2 -0
  443. package/build/features/connectExpress/screens/PrepareDataLoading/PrepareDataLoading.d.ts +5 -0
  444. package/build/features/connectExpress/screens/PrepareDataLoading/PrepareDataLoading.js +34 -0
  445. package/build/features/connectExpress/screens/PrepareDataLoading/index.d.ts +2 -0
  446. package/build/features/connectExpress/screens/PrepareDataLoading/index.js +2 -0
  447. package/build/features/connectExpress/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +15 -7
  448. package/build/features/connectExpress/screens/VerifyNafath/VerifyNafath.d.ts +5 -0
  449. package/build/features/connectExpress/screens/VerifyNafath/VerifyNafath.js +35 -0
  450. package/build/features/connectExpress/screens/VerifyNafath/index.d.ts +3 -0
  451. package/build/features/connectExpress/screens/VerifyNafath/index.js +2 -0
  452. package/build/features/entity/Entity.d.ts +2 -0
  453. package/build/features/entity/Entity.js +15 -9
  454. package/build/features/entity/screens/EntityCapital/ActivityList.d.ts +4 -4
  455. package/build/features/entity/screens/EntityCapital/CapitalPaid.js +5 -3
  456. package/build/features/entity/screens/EntityCapital/CapitalShareValue.js +6 -4
  457. package/build/features/entity/screens/EntityCapital/EntityCapital.js +34 -10
  458. package/build/features/entity/screens/EntityName/EntityName.js +44 -19
  459. package/build/features/entity/screens/EntityName/EntityTypeList.d.ts +9 -9
  460. package/build/features/entity/screens/EntityName/EntityTypeList.js +2 -3
  461. package/build/features/entity/screens/EntityName/ExpiryDate.d.ts +2 -2
  462. package/build/features/entity/screens/EntityName/ExpiryDate.js +5 -7
  463. package/build/features/entity/screens/EntityName/IssuingDate.d.ts +2 -2
  464. package/build/features/entity/screens/EntityName/IssuingDate.js +5 -7
  465. package/build/features/entity/screens/EntityName/LegalName.js +1 -13
  466. package/build/features/entity/screens/EntityName/LicenseNumber.js +10 -11
  467. package/build/features/entity/screens/EntityName/UnifiedNumber.js +4 -6
  468. package/build/features/entity/screens/EntityName/validation.d.ts +31 -3
  469. package/build/features/entity/screens/EntityName/validation.js +38 -9
  470. package/build/features/entity/screens/OperatorError/OperatorError.d.ts +5 -0
  471. package/build/features/entity/screens/OperatorError/OperatorError.js +9 -0
  472. package/build/features/entity/screens/OperatorError/index.d.ts +3 -0
  473. package/build/features/entity/screens/OperatorError/index.js +2 -0
  474. package/build/features/entity/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +13 -5
  475. package/build/features/entity/screens/Verify/Verify.js +4 -3
  476. package/build/features/featuresScreens.d.ts +2 -0
  477. package/build/features/featuresScreens.js +254 -15
  478. package/build/features/individual/Individual.d.ts +2 -0
  479. package/build/features/individual/Individual.js +15 -9
  480. package/build/features/individual/screens/AdditionalIndividualInfo/AdditionalIndividualInfo.d.ts +2 -2
  481. package/build/features/individual/screens/AdditionalIndividualInfo/AdditionalIndividualInfo.js +55 -15
  482. package/build/features/individual/screens/AdditionalIndividualInfo/IsAuthorizedSwitch.d.ts +36 -0
  483. package/build/features/individual/screens/AdditionalIndividualInfo/IsAuthorizedSwitch.js +76 -0
  484. package/build/features/individual/screens/AdditionalIndividualInfo/MonthlyIncome.js +5 -2
  485. package/build/features/individual/screens/AdditionalIndividualInfo/PEPSwitch.d.ts +4 -4
  486. package/build/features/individual/screens/AdditionalIndividualInfo/ShareValue.js +7 -4
  487. package/build/features/individual/screens/AdditionalIndividualInfo/validation.d.ts +4 -1
  488. package/build/features/individual/screens/AdditionalIndividualInfo/validation.js +4 -3
  489. package/build/features/individual/screens/IndividualList/IndividualList.d.ts +4 -4
  490. package/build/features/individual/screens/IndividualList/IndividualList.js +21 -6
  491. package/build/features/individual/screens/IndividualList/MobileNumber.js +6 -3
  492. package/build/features/individual/screens/IndividualList/UserList.js +13 -9
  493. package/build/features/individual/screens/IndividualList/validation.js +8 -3
  494. package/build/features/individual/screens/IndividualPersonalInfo/Gender.d.ts +4 -4
  495. package/build/features/individual/screens/IndividualPersonalInfo/ID.js +6 -2
  496. package/build/features/individual/screens/IndividualPersonalInfo/IndividualPersonalInfo.d.ts +2 -2
  497. package/build/features/individual/screens/IndividualPersonalInfo/IndividualPersonalInfo.js +79 -21
  498. package/build/features/individual/screens/IndividualPersonalInfo/MobileNumber.js +6 -3
  499. package/build/features/individual/screens/IndividualPersonalInfo/validation.d.ts +1 -1
  500. package/build/features/individual/screens/IndividualPersonalInfo/validation.js +72 -63
  501. package/build/features/individual/screens/IndividualPhoneInfo/MobileNumber.js +7 -4
  502. package/build/features/individual/screens/IndividualPhoneInfo/PhoneInfo.js +1 -1
  503. package/build/features/individual/screens/IndividualPhoneInfo/validation.js +8 -3
  504. package/build/features/individual/screens/OperatorError/OperatorError.d.ts +5 -0
  505. package/build/features/individual/screens/OperatorError/OperatorError.js +9 -0
  506. package/build/features/individual/screens/OperatorError/index.d.ts +3 -0
  507. package/build/features/individual/screens/OperatorError/index.js +2 -0
  508. package/build/features/individual/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +13 -5
  509. package/build/features/individual/screens/Verify/Verify.js +4 -3
  510. package/build/features/password/Password.d.ts +2 -0
  511. package/build/features/password/Password.js +94 -32
  512. package/build/features/password/screens/CreatePassword/CreatePassword.js +10 -4
  513. package/build/features/password/screens/OTP/OTP.js +4 -4
  514. package/build/features/password/screens/OperatorError/OperatorError.d.ts +5 -0
  515. package/build/features/password/screens/OperatorError/OperatorError.js +9 -0
  516. package/build/features/password/screens/OperatorError/index.d.ts +3 -0
  517. package/build/features/password/screens/OperatorError/index.js +2 -0
  518. package/build/features/password/screens/PrepareDataLoading/PrepareDataLoading.d.ts +4 -0
  519. package/build/features/password/screens/PrepareDataLoading/PrepareDataLoading.js +10 -0
  520. package/build/features/password/screens/PrepareDataLoading/index.d.ts +2 -0
  521. package/build/features/password/screens/PrepareDataLoading/index.js +2 -0
  522. package/build/features/password/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +13 -5
  523. package/build/features/password/screens/Verify/Verify.js +8 -7
  524. package/build/features/shared/Address/CountryList.d.ts +7 -7
  525. package/build/features/shared/Address/InputSelect.d.ts +7 -7
  526. package/build/features/shared/Background/Background.d.ts +3 -1
  527. package/build/features/shared/Background/Background.js +9 -11
  528. package/build/features/shared/BusinessCountry/BusinessCountry.d.ts +15 -0
  529. package/build/features/shared/BusinessCountry/BusinessCountry.js +179 -0
  530. package/build/features/shared/BusinessCountry/index.d.ts +2 -0
  531. package/build/features/shared/BusinessCountry/index.js +2 -0
  532. package/build/features/shared/Button/Button.js +11 -5
  533. package/build/features/shared/Button/EmailProvidersButtons.js +2 -0
  534. package/build/features/shared/Button/FlowsButtons.d.ts +3 -1
  535. package/build/features/shared/Button/FlowsButtons.js +29 -14
  536. package/build/features/shared/Button/NafathButton.d.ts +8 -0
  537. package/build/features/shared/Button/{AbsherButton.js → NafathButton.js} +12 -3
  538. package/build/features/shared/Button/index.d.ts +2 -2
  539. package/build/features/shared/Button/index.js +2 -2
  540. package/build/features/shared/Calender/Calender.d.ts +2 -1
  541. package/build/features/shared/Calender/Calender.js +3 -3
  542. package/build/features/shared/Containers/FeatureContainer.d.ts +2 -1
  543. package/build/features/shared/Containers/FeatureContainer.js +3 -3
  544. package/build/features/shared/Containers/ScreenContainer.d.ts +1 -1
  545. package/build/features/shared/DataLoading/DataLoading.d.ts +4 -1
  546. package/build/features/shared/DataLoading/DataLoading.js +2 -2
  547. package/build/features/shared/Footer/Footer.js +2 -1
  548. package/build/features/shared/Input/Input.d.ts +2 -2
  549. package/build/features/shared/NafathVerification/NafathVerification.d.ts +14 -0
  550. package/build/features/shared/NafathVerification/NafathVerification.js +92 -0
  551. package/build/features/shared/NafathVerification/VerifyNafathLoading.d.ts +8 -0
  552. package/build/features/shared/NafathVerification/VerifyNafathLoading.js +53 -0
  553. package/build/features/shared/NafathVerification/VerifyNafathSuccess.d.ts +5 -0
  554. package/build/features/shared/NafathVerification/VerifyNafathSuccess.js +8 -0
  555. package/build/features/shared/NafathVerification/index.d.ts +2 -0
  556. package/build/features/shared/NafathVerification/index.js +2 -0
  557. package/build/features/shared/SuccessFlowButtons/SuccessFlowButtons.d.ts +8 -1
  558. package/build/features/shared/SuccessFlowButtons/SuccessFlowButtons.js +11 -14
  559. package/build/features/shared/SuccessScreen/SuccessScreen.js +1 -1
  560. package/build/features/shared/UploadFile/FileUpload.d.ts +1 -1
  561. package/build/features/shared/UploadFile/UploadFile.d.ts +1 -1
  562. package/build/features/shared/UploadFile/UploadWrapper.d.ts +1 -1
  563. package/build/features/shared/UploadMultipleFile/UploadFile.d.ts +1 -1
  564. package/build/features/shared/UploadMultipleFile/UploadMultipleFile.d.ts +1 -1
  565. package/build/features/signIn/SignIn.js +18 -7
  566. package/build/features/signIn/screens/Mobile/MobileNumber.js +6 -3
  567. package/build/features/signIn/screens/Mobile/validation.js +8 -3
  568. package/build/features/signIn/screens/OTP/OTP.js +5 -4
  569. package/build/features/signIn/screens/OperatorError/OperatorError.d.ts +5 -0
  570. package/build/features/signIn/screens/OperatorError/OperatorError.js +9 -0
  571. package/build/features/signIn/screens/OperatorError/index.d.ts +3 -0
  572. package/build/features/signIn/screens/OperatorError/index.js +2 -0
  573. package/build/features/tax/Tax.d.ts +2 -0
  574. package/build/features/tax/Tax.js +15 -9
  575. package/build/features/tax/screens/OperatorError/OperatorError.d.ts +5 -0
  576. package/build/features/tax/screens/OperatorError/OperatorError.js +9 -0
  577. package/build/features/tax/screens/OperatorError/index.d.ts +3 -0
  578. package/build/features/tax/screens/OperatorError/index.js +2 -0
  579. package/build/features/tax/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +13 -5
  580. package/build/features/tax/screens/TaxDetails/TaxDetails.js +9 -3
  581. package/build/features/tax/screens/Verify/Verify.js +8 -7
  582. package/build/hooks/index.d.ts +3 -0
  583. package/build/hooks/index.js +3 -0
  584. package/build/hooks/useAppConfig.d.ts +3 -3
  585. package/build/hooks/useAppConfig.js +9 -6
  586. package/build/hooks/useAppDispatch.d.ts +2 -0
  587. package/build/hooks/useAppTheme.js +4 -3
  588. package/build/hooks/useCountDown.d.ts +10 -0
  589. package/build/hooks/useCountDown.js +17 -0
  590. package/build/hooks/useCountry.d.ts +1 -0
  591. package/build/hooks/useCountry.js +4 -3
  592. package/build/hooks/useFormDirtyCheck.d.ts +10 -0
  593. package/build/hooks/useFormDirtyCheck.js +66 -0
  594. package/build/hooks/useSanitizedTranslation.d.ts +1 -0
  595. package/build/hooks/useSanitizedTranslation.js +15 -0
  596. package/build/hooks/useVerifyToken.d.ts +5 -2
  597. package/build/hooks/useVerifyToken.js +10 -5
  598. package/build/index.css +360 -120
  599. package/build/index.d.ts +4 -2
  600. package/build/index.js +6 -2
  601. package/build/theme/components.js +7 -0
  602. package/build/theme/palette.js +4 -2
  603. package/build/theme/theme.d.ts +1 -1
  604. package/build/theme/theme.js +2 -2
  605. package/build/utils/array.js +2 -2
  606. package/build/utils/common.d.ts +3 -0
  607. package/build/utils/common.js +38 -2
  608. package/build/utils/device.d.ts +2 -0
  609. package/build/utils/device.js +6 -0
  610. package/build/utils/locale.js +2 -1
  611. package/build/utils/object.d.ts +1 -0
  612. package/build/utils/object.js +4 -1
  613. package/build/utils/string.d.ts +5 -2
  614. package/build/utils/string.js +24 -5
  615. package/build/utils/validation.d.ts +5 -0
  616. package/build/utils/validation.js +16 -0
  617. package/package.json +2 -2
  618. package/build/features/business/screens/OTP/OTP.d.ts +0 -8
  619. package/build/features/business/screens/OTP/OTP.js +0 -90
  620. package/build/features/connect/screens/BrandSegment/SegmentLocations.d.ts +0 -8
  621. package/build/features/connect/screens/BrandSegment/SegmentLocations.js +0 -66
  622. package/build/features/connect/screens/BrandSegment/SegmentProfits.d.ts +0 -8
  623. package/build/features/connect/screens/BrandSegment/SegmentProfits.js +0 -66
  624. package/build/features/connect/screens/BrandSegment/SegmentTechs.d.ts +0 -8
  625. package/build/features/connect/screens/BrandSegment/SegmentTechs.js +0 -66
  626. package/build/features/connectExpress/screens/IdentityOTP/index.d.ts +0 -3
  627. package/build/features/connectExpress/screens/IdentityOTP/index.js +0 -2
  628. package/build/features/shared/Button/AbsherButton.d.ts +0 -8
  629. /package/build/features/{connect/screens/NID → auth/screens/DOB}/DOB.d.ts +0 -0
  630. /package/build/features/{connectExpress/screens/IdentityOTP → auth/screens/OTP}/OTP.d.ts +0 -0
  631. /package/build/features/{business → auth}/screens/OTP/OTPInput.d.ts +0 -0
  632. /package/build/features/{business → auth}/screens/OTP/index.d.ts +0 -0
  633. /package/build/features/{business → auth}/screens/OTP/index.js +0 -0
  634. /package/build/features/{business → auth}/screens/OTP/validation.d.ts +0 -0
  635. /package/build/features/{business → auth}/screens/OTP/validation.js +0 -0
  636. /package/build/features/{connectExpress/screens/IdentityOTP/OTPInput.d.ts → board/screens/Verify/Verify.d.ts} +0 -0
  637. /package/build/features/{connectExpress/screens/IdentityOTP → board/screens/Verify}/validation.d.ts +0 -0
  638. /package/build/features/{connectExpress/screens/IdentityOTP → board/screens/Verify}/validation.js +0 -0
@@ -49,74 +49,69 @@ var _a;
49
49
  import { createAsyncThunk, createSlice } from '@reduxjs/toolkit';
50
50
  import API from '../../../api';
51
51
  import { FlowsTypes } from '../../../@types';
52
- import { handleCurrentActiveScreen, handleNextScreenStep, handlePublicKey, handleSetCountryByIso2 } from '../../../app/settings';
52
+ import { handleCurrentActiveScreen, handleNextScreenStep, handlePrevScreenStep, handlePublicKey, handleSetCountryByIso2, onCloseComplete } from '../../../app/settings';
53
53
  import { PASSWORD_OPERATION_TYPE, PASSWORD_STEP_NAMES } from '../../../constants';
54
- import { retrieveIndividualData } from '../../../utils';
55
- export var verifyLeadToken = createAsyncThunk('passwordVerifyLeadToken', function (token, thunkApi) { return __awaiter(void 0, void 0, void 0, function () {
56
- var payload, data, boardStatusData, boardInfoData, boardData, individualData, _a, board_id, board_info_id, config, publicKey, _b, id_1, type_1, serviceCallBack, _c, boardRes, individualRes, countryIso2, info, hasPasswordCompleted;
57
- var _d, _e, _f, _g, _h;
58
- return __generator(this, function (_j) {
59
- switch (_j.label) {
60
- case 0:
61
- payload = {
62
- service_name: 'tap_email',
63
- verify_token: token
64
- };
65
- return [4, API.leadService.verifyLeadToken(payload)];
66
- case 1:
67
- data = (_j.sent()).data;
68
- individualData = undefined;
69
- if (!(!(data === null || data === void 0 ? void 0 : data.errors) && !(data === null || data === void 0 ? void 0 : data.mw_error))) return [3, 8];
70
- _a = data || {}, board_id = _a.id, board_info_id = _a.board_info_id, config = _a.config;
71
- publicKey = config === null || config === void 0 ? void 0 : config.public_key;
72
- if (publicKey) {
73
- thunkApi.dispatch(handlePublicKey(publicKey));
74
- }
75
- if (!board_id) return [3, 7];
76
- if (!board_info_id) return [3, 3];
77
- return [4, API.boardService.retrieveBoardInfo({ id: board_id, infoId: board_info_id })];
78
- case 2:
79
- boardInfoData = _j.sent();
80
- _j.label = 3;
81
- case 3: return [4, API.boardService.retrieveBoardInfoStatus(board_id)];
82
- case 4:
83
- boardStatusData = _j.sent();
84
- return [4, API.boardService.retrieveBoardDetails(board_id)];
85
- case 5:
86
- boardData = _j.sent();
87
- _b = ((_d = boardInfoData === null || boardInfoData === void 0 ? void 0 : boardInfoData.notification) === null || _d === void 0 ? void 0 : _d.recipient) || {}, id_1 = _b.id, type_1 = _b.type;
88
- serviceCallBack = function () { return API.individualService.retrieveIndividual(id_1, type_1); };
89
- return [4, retrieveIndividualData(type_1, boardData, serviceCallBack)];
90
- case 6:
91
- _c = _j.sent(), boardRes = _c.boardRes, individualRes = _c.individualRes;
92
- boardData = boardRes;
93
- individualData = individualRes;
94
- _j.label = 7;
95
- case 7:
96
- countryIso2 = (_e = boardData === null || boardData === void 0 ? void 0 : boardData.entity) === null || _e === void 0 ? void 0 : _e.country;
97
- if (countryIso2)
98
- thunkApi.dispatch(handleSetCountryByIso2(countryIso2));
99
- info = (boardStatusData || {}).info;
100
- hasPasswordCompleted = ((_f = info === null || info === void 0 ? void 0 : info.find(function (flow) { return flow.name === 'password'; })) === null || _f === void 0 ? void 0 : _f.status) === 'completed';
101
- if (data.step_name === PASSWORD_STEP_NAMES.PHONE_AUTH) {
54
+ import { retrieveIndividualData, sendCustomEventToGTM, sleep } from '../../../utils';
55
+ export var verifyLeadToken = createAsyncThunk('passwordVerifyLeadToken', function (_a, thunkApi) {
56
+ var token = _a.token, isInternally = _a.isInternally;
57
+ return __awaiter(void 0, void 0, void 0, function () {
58
+ var payload, data, _b, config, board_info_password_status, country_code, board_id, recipient, countryIso2, publicKey, data_1, flows, data_2;
59
+ var _c, _d;
60
+ return __generator(this, function (_e) {
61
+ switch (_e.label) {
62
+ case 0:
63
+ payload = __assign({ service_name: 'tap_email', verify_token: token }, (isInternally && {
64
+ notification: {
65
+ sms: false
66
+ }
67
+ }));
68
+ return [4, API.leadService.verifyLeadToken(payload)];
69
+ case 1:
70
+ data = (_e.sent()).data;
71
+ if (((_c = data === null || data === void 0 ? void 0 : data.errors) === null || _c === void 0 ? void 0 : _c.length) || (data === null || data === void 0 ? void 0 : data.mw_error))
72
+ throw new Error(data.errors[0].description || (data === null || data === void 0 ? void 0 : data.mw_error));
73
+ if (isInternally)
74
+ data.step_name = PASSWORD_STEP_NAMES.PASSWORD_INFO;
75
+ _b = data || {}, config = _b.config, board_info_password_status = _b.board_info_password_status, country_code = _b.country_code, board_id = _b.id, recipient = _b.recipient;
76
+ countryIso2 = country_code;
77
+ if (countryIso2)
78
+ thunkApi.dispatch(handleSetCountryByIso2(countryIso2));
79
+ publicKey = config === null || config === void 0 ? void 0 : config.public_key;
80
+ if (publicKey)
81
+ thunkApi.dispatch(handlePublicKey(publicKey));
82
+ if (!!country_code) return [3, 3];
83
+ return [4, API.boardService.retrieveBoardDetails(board_id)];
84
+ case 2:
85
+ data_1 = _e.sent();
86
+ if ((_d = data_1 === null || data_1 === void 0 ? void 0 : data_1.entity) === null || _d === void 0 ? void 0 : _d.country)
87
+ thunkApi.dispatch(handleSetCountryByIso2(data_1.entity.country));
88
+ _e.label = 3;
89
+ case 3:
90
+ flows = [];
91
+ if (!(data.step_name === PASSWORD_STEP_NAMES.PHONE_AUTH)) return [3, 4];
102
92
  thunkApi.dispatch(handleCurrentActiveScreen('PASSWORD_VERIFY_STEP'));
103
- }
104
- else if (hasPasswordCompleted) {
93
+ return [3, 7];
94
+ case 4:
95
+ if (!(board_info_password_status === 'completed')) return [3, 6];
96
+ return [4, Promise.all([
97
+ API.boardService.retrieveBoardInfoStatus(board_id),
98
+ thunkApi.dispatch(retrieveBoardDetails({ boardId: board_id, individualId: recipient === null || recipient === void 0 ? void 0 : recipient.id, individualType: recipient === null || recipient === void 0 ? void 0 : recipient.type })).unwrap()
99
+ ])];
100
+ case 5:
101
+ data_2 = (_e.sent())[0];
102
+ flows = (data_2 === null || data_2 === void 0 ? void 0 : data_2.info) || [];
105
103
  thunkApi.dispatch(handleNextScreenStep('PASSWORD_SUCCESS_FOUR_FLOWS_BUTTONS_STEP'));
106
- }
107
- else if (data.step_name === PASSWORD_STEP_NAMES.PASSWORD_INFO) {
108
- thunkApi.dispatch(handleNextScreenStep('PASSWORD_CREATE_PASSWORD_STEP'));
109
- }
110
- _j.label = 8;
111
- case 8: return [2, {
112
- data: data,
113
- individualData: individualData,
114
- boardResponse: __assign(__assign({}, boardData === null || boardData === void 0 ? void 0 : boardData.business), { flows: (boardStatusData === null || boardStatusData === void 0 ? void 0 : boardStatusData.info) || [], user: boardData === null || boardData === void 0 ? void 0 : boardData.user, brand: boardData === null || boardData === void 0 ? void 0 : boardData.brand, bank_account: boardData === null || boardData === void 0 ? void 0 : boardData.bank_account, entity: boardData === null || boardData === void 0 ? void 0 : boardData.entity, merchant: boardData === null || boardData === void 0 ? void 0 : boardData.merchant, individuals: boardData === null || boardData === void 0 ? void 0 : boardData.individuals, name: (_g = boardData === null || boardData === void 0 ? void 0 : boardData.user) === null || _g === void 0 ? void 0 : _g.names, contact: (_h = boardData === null || boardData === void 0 ? void 0 : boardData.user) === null || _h === void 0 ? void 0 : _h.contact, business: boardData === null || boardData === void 0 ? void 0 : boardData.business, notification: boardInfoData === null || boardInfoData === void 0 ? void 0 : boardInfoData.notification }),
115
- token: token
116
- }];
117
- }
104
+ return [3, 7];
105
+ case 6:
106
+ if (data.step_name === PASSWORD_STEP_NAMES.PASSWORD_INFO) {
107
+ thunkApi.dispatch(handleNextScreenStep('PASSWORD_CREATE_PASSWORD_STEP'));
108
+ }
109
+ _e.label = 7;
110
+ case 7: return [2, { data: data, token: token, flows: flows }];
111
+ }
112
+ });
118
113
  });
119
- }); });
114
+ });
120
115
  export var resendOTP = createAsyncThunk('resendOTPPassword', function (params, thunkApi) { return __awaiter(void 0, void 0, void 0, function () {
121
116
  var password, payload, data;
122
117
  return __generator(this, function (_a) {
@@ -134,54 +129,82 @@ export var resendOTP = createAsyncThunk('resendOTPPassword', function (params, t
134
129
  }
135
130
  });
136
131
  }); });
137
- export var retrieveBoardDetails = createAsyncThunk('retrievePasswordBoardDetails', function (boardId) { return __awaiter(void 0, void 0, void 0, function () {
138
- var data;
139
- var _a, _b;
140
- return __generator(this, function (_c) {
141
- switch (_c.label) {
142
- case 0: return [4, API.boardService.retrieveBoardDetails(boardId)];
143
- case 1:
144
- data = _c.sent();
145
- return [2, {
146
- data: __assign(__assign({}, data), { user: data === null || data === void 0 ? void 0 : data.user, brand: data === null || data === void 0 ? void 0 : data.brand, bank_account: data === null || data === void 0 ? void 0 : data.bank_account, entity: data === null || data === void 0 ? void 0 : data.entity, merchant: data === null || data === void 0 ? void 0 : data.merchant, name: (_a = data === null || data === void 0 ? void 0 : data.user) === null || _a === void 0 ? void 0 : _a.names, individuals: data === null || data === void 0 ? void 0 : data.individuals, contact: (_b = data === null || data === void 0 ? void 0 : data.user) === null || _b === void 0 ? void 0 : _b.contact })
147
- }];
148
- }
132
+ export var retrieveBoardDetails = createAsyncThunk('retrievePasswordBoardDetails', function (_a) {
133
+ var boardId = _a.boardId, id = _a.individualId, type = _a.individualType;
134
+ return __awaiter(void 0, void 0, void 0, function () {
135
+ var data, individualData, boardData, serviceCallBack, _b, boardRes, individualRes;
136
+ var _c, _d, _e;
137
+ return __generator(this, function (_f) {
138
+ switch (_f.label) {
139
+ case 0: return [4, API.boardService.retrieveBoardDetails(boardId)];
140
+ case 1:
141
+ data = _f.sent();
142
+ individualData = data === null || data === void 0 ? void 0 : data.user;
143
+ boardData = data;
144
+ if (!(((_c = data === null || data === void 0 ? void 0 : data.user) === null || _c === void 0 ? void 0 : _c.id) !== id && id)) return [3, 3];
145
+ serviceCallBack = function () { return API.individualService.retrieveIndividual(id, type); };
146
+ return [4, retrieveIndividualData(type, data, serviceCallBack)];
147
+ case 2:
148
+ _b = _f.sent(), boardRes = _b.boardRes, individualRes = _b.individualRes;
149
+ individualData = individualRes;
150
+ boardData = boardRes;
151
+ _f.label = 3;
152
+ case 3: return [2, __assign(__assign({}, boardData), { brand: boardData === null || boardData === void 0 ? void 0 : boardData.brand, bank_account: boardData === null || boardData === void 0 ? void 0 : boardData.bank_account, entity: boardData === null || boardData === void 0 ? void 0 : boardData.entity, merchant: boardData === null || boardData === void 0 ? void 0 : boardData.merchant, name: (_d = boardData === null || boardData === void 0 ? void 0 : boardData.user) === null || _d === void 0 ? void 0 : _d.names, individuals: boardData === null || boardData === void 0 ? void 0 : boardData.individuals, contact: (_e = boardData === null || boardData === void 0 ? void 0 : boardData.user) === null || _e === void 0 ? void 0 : _e.contact, user: individualData, board_status: boardData === null || boardData === void 0 ? void 0 : boardData.status })];
153
+ }
154
+ });
149
155
  });
150
- }); });
156
+ });
151
157
  export var verifyPasswordLeadOTP = createAsyncThunk('verifyPasswordLeadOTP', function (params, thunkApi) { return __awaiter(void 0, void 0, void 0, function () {
152
- var _a, password, settings, responseBody, payload, data, publicKey, flows, hasPasswordCompleted;
153
- var _b, _c, _d, _e, _f;
154
- return __generator(this, function (_g) {
155
- switch (_g.label) {
158
+ var _a, password, settings, responseBody, payload, data, _b, config, board_info_password_status, country_code, board_id, recipient, countryIso2, publicKey, flows, data_3, data_4;
159
+ var _c, _d, _e, _f, _g;
160
+ return __generator(this, function (_h) {
161
+ switch (_h.label) {
156
162
  case 0:
157
163
  _a = thunkApi.getState(), password = _a.password, settings = _a.settings;
158
164
  responseBody = password.data.verify.responseBody;
159
165
  payload = {
160
166
  data: params.otp,
161
- service_name: (_b = responseBody === null || responseBody === void 0 ? void 0 : responseBody.verification_by) === null || _b === void 0 ? void 0 : _b.service_name,
167
+ service_name: (_c = responseBody === null || responseBody === void 0 ? void 0 : responseBody.verification_by) === null || _c === void 0 ? void 0 : _c.service_name,
162
168
  verify_token: responseBody === null || responseBody === void 0 ? void 0 : responseBody.verify_token,
163
169
  step_name: PASSWORD_STEP_NAMES.PHONE_AUTH,
164
170
  encryption_contract: ['data']
165
171
  };
166
172
  return [4, API.leadService.verifyLeadOTP(payload)];
167
173
  case 1:
168
- data = (_g.sent()).data;
169
- if (!data.errors) {
170
- publicKey = (_c = data === null || data === void 0 ? void 0 : data.config) === null || _c === void 0 ? void 0 : _c.public_key;
171
- if (publicKey) {
172
- thunkApi.dispatch(handlePublicKey(publicKey));
173
- }
174
- (_e = (_d = settings.data.appConfig).onStepCompleted) === null || _e === void 0 ? void 0 : _e.call(_d, settings.data.activeScreen.name, { otp: params.otp });
175
- flows = (responseBody || {}).flows;
176
- hasPasswordCompleted = ((_f = flows === null || flows === void 0 ? void 0 : flows.find(function (flow) { return flow.name === 'password'; })) === null || _f === void 0 ? void 0 : _f.status) === 'completed';
177
- if (hasPasswordCompleted) {
178
- thunkApi.dispatch(handleNextScreenStep('PASSWORD_SUCCESS_FOUR_FLOWS_BUTTONS_STEP'));
179
- }
180
- else {
181
- thunkApi.dispatch(handleNextScreenStep('PASSWORD_CREATE_PASSWORD_STEP'));
182
- }
183
- }
184
- return [2, { data: data, formData: __assign({}, params) }];
174
+ data = (_h.sent()).data;
175
+ if ((_d = data === null || data === void 0 ? void 0 : data.errors) === null || _d === void 0 ? void 0 : _d.length)
176
+ throw new Error(data.errors[0].description);
177
+ _b = data || {}, config = _b.config, board_info_password_status = _b.board_info_password_status, country_code = _b.country_code, board_id = _b.id, recipient = _b.recipient;
178
+ countryIso2 = country_code;
179
+ if (countryIso2)
180
+ thunkApi.dispatch(handleSetCountryByIso2(countryIso2));
181
+ publicKey = config === null || config === void 0 ? void 0 : config.public_key;
182
+ if (publicKey)
183
+ thunkApi.dispatch(handlePublicKey(publicKey));
184
+ (_f = (_e = settings.data.appConfig).onStepCompleted) === null || _f === void 0 ? void 0 : _f.call(_e, settings.data.activeScreen.name, { otp: params.otp });
185
+ flows = [];
186
+ if (!(board_info_password_status === 'completed')) return [3, 3];
187
+ return [4, Promise.all([
188
+ API.boardService.retrieveBoardInfoStatus(board_id),
189
+ thunkApi.dispatch(retrieveBoardDetails({ boardId: board_id, individualId: recipient === null || recipient === void 0 ? void 0 : recipient.id, individualType: recipient === null || recipient === void 0 ? void 0 : recipient.type })).unwrap()
190
+ ])];
191
+ case 2:
192
+ data_3 = (_h.sent())[0];
193
+ flows = (data_3 === null || data_3 === void 0 ? void 0 : data_3.info) || [];
194
+ thunkApi.dispatch(handleNextScreenStep('PASSWORD_SUCCESS_FOUR_FLOWS_BUTTONS_STEP'));
195
+ return [3, 6];
196
+ case 3:
197
+ if (!!country_code) return [3, 5];
198
+ return [4, API.boardService.retrieveBoardDetails(board_id)];
199
+ case 4:
200
+ data_4 = _h.sent();
201
+ if ((_g = data_4 === null || data_4 === void 0 ? void 0 : data_4.entity) === null || _g === void 0 ? void 0 : _g.country)
202
+ thunkApi.dispatch(handleSetCountryByIso2(data_4.entity.country));
203
+ _h.label = 5;
204
+ case 5:
205
+ thunkApi.dispatch(handleNextScreenStep('PASSWORD_CREATE_PASSWORD_STEP'));
206
+ _h.label = 6;
207
+ case 6: return [2, { data: data, formData: __assign({}, params), flows: flows }];
185
208
  }
186
209
  });
187
210
  }); });
@@ -201,90 +224,114 @@ export var createPassword = createAsyncThunk('createPassword', function (params,
201
224
  return [4, API.authService.createPassword(requestBody)];
202
225
  case 1:
203
226
  data = _f.sent();
204
- thunkApi.dispatch(handleNextScreenStep('PASSWORD_SUCCESS_STEP'));
227
+ sleep(100).then(function () { return thunkApi.dispatch(handleNextScreenStep('PASSWORD_SUCCESS_STEP')); });
205
228
  (_e = (_d = settings.data.appConfig).onStepCompleted) === null || _e === void 0 ? void 0 : _e.call(_d, settings.data.activeScreen.name, requestBody);
206
229
  return [2, { data: data, formData: params }];
207
230
  }
208
231
  });
209
232
  }); });
210
233
  export var updateBoardSuccess = createAsyncThunk('passwordUpdateBoardSuccess', function (params, thunkApi) { return __awaiter(void 0, void 0, void 0, function () {
211
- var _a, settings, password, _b, id, infoId, payload, data, boardInfoData;
212
- var _c, _d, _e, _f;
213
- return __generator(this, function (_g) {
214
- switch (_g.label) {
234
+ var _a, settings, password, _b, board_id, infoId, _c, showBoard, mode, payload, data, _d, id, type, boardInfoStatusData;
235
+ var _e, _f, _g, _h, _j, _k, _l, _m, _o;
236
+ return __generator(this, function (_p) {
237
+ switch (_p.label) {
215
238
  case 0:
216
239
  _a = thunkApi.getState(), settings = _a.settings, password = _a.password;
217
- _b = password.data.verify.responseBody || {}, id = _b.board_id, infoId = _b.board_info_id;
218
- if (!id)
240
+ _b = password.data.verify.responseBody || {}, board_id = _b.board_id, infoId = _b.board_info_id;
241
+ _c = settings.data.appConfig, showBoard = _c.showBoard, mode = _c.mode;
242
+ if (!board_id)
219
243
  return [2];
220
244
  payload = {
221
245
  lang: settings.data.language,
222
- step_name: PASSWORD_STEP_NAMES.PASSWORD_SUCCESS,
223
- id: id
246
+ step_name: PASSWORD_STEP_NAMES.PASSWORD_SUCCESS
224
247
  };
225
- return [4, API.boardService.updateBoardInfo(__assign({ id: id, infoId: infoId }, payload))];
248
+ return [4, API.boardService.updateBoardInfo(__assign({ id: board_id, infoId: infoId }, payload))];
226
249
  case 1:
227
- data = _g.sent();
228
- return [4, API.boardService.retrieveBoardInfoStatus(id)];
250
+ data = _p.sent();
251
+ sendCustomEventToGTM({
252
+ event: 'Send Event',
253
+ event_category: 'Board Flows - Password',
254
+ event_action: 'Password Update Success Page',
255
+ event_label: settings.data.businessCountry.iso2
256
+ });
257
+ if (!showBoard && mode === 'content') {
258
+ (_f = (_e = settings.data.appConfig).onStepCompleted) === null || _f === void 0 ? void 0 : _f.call(_e, settings.data.activeScreen.name, {});
259
+ (_h = (_g = settings.data.appConfig).onFlowCompleted) === null || _h === void 0 ? void 0 : _h.call(_g, { data: data });
260
+ return [2, { data: data }];
261
+ }
262
+ _d = ((_j = data === null || data === void 0 ? void 0 : data.notification) === null || _j === void 0 ? void 0 : _j.recipient) || {}, id = _d.id, type = _d.type;
263
+ return [4, Promise.all([
264
+ API.boardService.retrieveBoardInfoStatus(board_id),
265
+ thunkApi.dispatch(retrieveBoardDetails({ boardId: board_id, individualId: id, individualType: type })).unwrap()
266
+ ])];
229
267
  case 2:
230
- boardInfoData = _g.sent();
231
- return [4, thunkApi.dispatch(retrieveBoardDetails(id))];
232
- case 3:
233
- _g.sent();
234
- (_d = (_c = settings.data.appConfig).onStepCompleted) === null || _d === void 0 ? void 0 : _d.call(_c, settings.data.activeScreen.name, {});
235
- (_f = (_e = settings.data.appConfig).onFlowCompleted) === null || _f === void 0 ? void 0 : _f.call(_e, { data: data });
268
+ boardInfoStatusData = (_p.sent())[0];
269
+ (_l = (_k = settings.data.appConfig).onStepCompleted) === null || _l === void 0 ? void 0 : _l.call(_k, settings.data.activeScreen.name, {});
270
+ (_o = (_m = settings.data.appConfig).onFlowCompleted) === null || _o === void 0 ? void 0 : _o.call(_m, { data: data });
236
271
  thunkApi.dispatch(handleNextScreenStep());
237
- return [2, { response: __assign(__assign({}, data), { flows: (boardInfoData === null || boardInfoData === void 0 ? void 0 : boardInfoData.info) || [] }), formData: params }];
272
+ return [2, { data: data, flows: (boardInfoStatusData === null || boardInfoStatusData === void 0 ? void 0 : boardInfoStatusData.info) || [] }];
273
+ }
274
+ });
275
+ }); });
276
+ export var retrieveBoardStatus = createAsyncThunk('password/retrieveBoardStatus', function (params, thunkApi) { return __awaiter(void 0, void 0, void 0, function () {
277
+ var password, _a, board_id, board_info_id, recipient, _b, id, type, data;
278
+ return __generator(this, function (_c) {
279
+ switch (_c.label) {
280
+ case 0:
281
+ password = thunkApi.getState().password;
282
+ _a = password.data.verify.responseBody || {}, board_id = _a.board_id, board_info_id = _a.board_info_id, recipient = _a.recipient;
283
+ if (!board_id || !board_info_id)
284
+ throw new Error('Internal server error');
285
+ _b = recipient || {}, id = _b.id, type = _b.type;
286
+ return [4, Promise.all([
287
+ API.boardService.retrieveBoardInfoStatus(board_id),
288
+ thunkApi.dispatch(retrieveBoardDetails({ boardId: board_id, individualId: id, individualType: type })).unwrap()
289
+ ])];
290
+ case 1:
291
+ data = (_c.sent())[0];
292
+ thunkApi.dispatch(handlePrevScreenStep());
293
+ return [2, { flows: (data === null || data === void 0 ? void 0 : data.info) || [] }];
238
294
  }
239
295
  });
240
296
  }); });
241
297
  export var verifyOperationToken = createAsyncThunk('verifyOperationToken', function (params, thunkApi) { return __awaiter(void 0, void 0, void 0, function () {
242
- var token, boardId, boardInfoId, boardInfoData, boardStatusData, individualData, boardData, payload, data, _a, id_2, type_2, serviceCallBack, _b, boardRes, individualRes;
243
- var _c, _d, _e;
244
- return __generator(this, function (_f) {
245
- switch (_f.label) {
298
+ var token, boardId, boardInfoId, userId, userType, payload, data, countryIso2, publicKey, data_5;
299
+ var _a, _b, _c;
300
+ return __generator(this, function (_d) {
301
+ switch (_d.label) {
246
302
  case 0:
247
- token = params.token, boardId = params.boardId, boardInfoId = params.boardInfoId;
248
- boardData = undefined;
303
+ token = params.token, boardId = params.boardId, boardInfoId = params.boardInfoId, userId = params.userId, userType = params.userType;
249
304
  payload = {
250
305
  auth_type: 7,
251
306
  auth_token: token
252
307
  };
253
308
  return [4, API.authService.verifyAuth(payload)];
254
309
  case 1:
255
- data = (_f.sent()).data;
256
- if (!boardId) return [3, 7];
257
- return [4, API.boardService.retrieveBoardInfoStatus(boardId)];
258
- case 2:
259
- boardStatusData = _f.sent();
310
+ data = (_d.sent()).data;
311
+ if ((_a = data === null || data === void 0 ? void 0 : data.errors) === null || _a === void 0 ? void 0 : _a.length)
312
+ throw new Error(data.errors[0].description);
313
+ countryIso2 = data === null || data === void 0 ? void 0 : data.country;
314
+ if (countryIso2)
315
+ thunkApi.dispatch(handleSetCountryByIso2(countryIso2));
316
+ publicKey = (_b = data === null || data === void 0 ? void 0 : data.config) === null || _b === void 0 ? void 0 : _b.public_key;
317
+ if (publicKey)
318
+ thunkApi.dispatch(handlePublicKey(publicKey));
319
+ if (!!(data === null || data === void 0 ? void 0 : data.country)) return [3, 3];
260
320
  return [4, API.boardService.retrieveBoardDetails(boardId)];
321
+ case 2:
322
+ data_5 = _d.sent();
323
+ if ((_c = data_5 === null || data_5 === void 0 ? void 0 : data_5.entity) === null || _c === void 0 ? void 0 : _c.country)
324
+ thunkApi.dispatch(handleSetCountryByIso2(data_5.entity.country));
325
+ _d.label = 3;
261
326
  case 3:
262
- boardData = _f.sent();
263
- if (!boardInfoId) return [3, 5];
264
- return [4, API.boardService.retrieveBoardInfo({ id: boardId, infoId: boardInfoId })];
265
- case 4:
266
- boardInfoData = _f.sent();
267
- _f.label = 5;
268
- case 5:
269
- _a = ((_c = boardInfoData === null || boardInfoData === void 0 ? void 0 : boardInfoData.notification) === null || _c === void 0 ? void 0 : _c.recipient) || {}, id_2 = _a.id, type_2 = _a.type;
270
- serviceCallBack = function () { return API.individualService.retrieveIndividual(id_2, type_2); };
271
- return [4, retrieveIndividualData(type_2, boardData, serviceCallBack)];
272
- case 6:
273
- _b = _f.sent(), boardRes = _b.boardRes, individualRes = _b.individualRes;
274
- boardData = boardRes;
275
- individualData = individualRes;
276
- _f.label = 7;
277
- case 7:
278
327
  thunkApi.dispatch(handleNextScreenStep('PASSWORD_CREATE_PASSWORD_STEP'));
279
- return [2, {
280
- data: data,
281
- token: token,
282
- boardId: boardId,
283
- boardInfoId: boardInfoId,
284
- individualData: individualData,
285
- boardResponse: __assign(__assign({}, boardData === null || boardData === void 0 ? void 0 : boardData.business), { user: boardData === null || boardData === void 0 ? void 0 : boardData.user, brand: boardData === null || boardData === void 0 ? void 0 : boardData.brand, bank_account: boardData === null || boardData === void 0 ? void 0 : boardData.bank_account, entity: boardData === null || boardData === void 0 ? void 0 : boardData.entity, merchant: boardData === null || boardData === void 0 ? void 0 : boardData.merchant, individuals: boardData === null || boardData === void 0 ? void 0 : boardData.individuals, name: (_d = boardData === null || boardData === void 0 ? void 0 : boardData.user) === null || _d === void 0 ? void 0 : _d.names, contact: (_e = boardData === null || boardData === void 0 ? void 0 : boardData.user) === null || _e === void 0 ? void 0 : _e.contact, business: boardData === null || boardData === void 0 ? void 0 : boardData.business, notification: boardInfoData === null || boardInfoData === void 0 ? void 0 : boardInfoData.notification }),
286
- flows: (boardStatusData === null || boardStatusData === void 0 ? void 0 : boardStatusData.info) || []
287
- }];
328
+ return [2, __assign({ data: data, token: token, boardId: boardId, boardInfoId: boardInfoId }, (userId &&
329
+ userType && {
330
+ recipient: {
331
+ id: userId,
332
+ type: userType
333
+ }
334
+ }))];
288
335
  }
289
336
  });
290
337
  }); });
@@ -307,9 +354,9 @@ export var resendOperationOTP = createAsyncThunk('resendOperationOTPPassword', f
307
354
  }); });
308
355
  export var resetPassword = createAsyncThunk('resetPassword', function (params, thunkApi) { return __awaiter(void 0, void 0, void 0, function () {
309
356
  var _a, password, settings, responseBody, passwordData, payload, data;
310
- var _b, _c;
311
- return __generator(this, function (_d) {
312
- switch (_d.label) {
357
+ var _b, _c, _d;
358
+ return __generator(this, function (_e) {
359
+ switch (_e.label) {
313
360
  case 0:
314
361
  _a = thunkApi.getState(), password = _a.password, settings = _a.settings;
315
362
  responseBody = password.data.verify.responseBody;
@@ -326,33 +373,56 @@ export var resetPassword = createAsyncThunk('resetPassword', function (params, t
326
373
  };
327
374
  return [4, API.authService.verifyAuth(payload)];
328
375
  case 1:
329
- data = (_d.sent()).data;
376
+ data = (_e.sent()).data;
377
+ if ((_b = data === null || data === void 0 ? void 0 : data.errors) === null || _b === void 0 ? void 0 : _b.length)
378
+ throw new Error(data.errors[0].description);
330
379
  if (!(data === null || data === void 0 ? void 0 : data.errors)) {
331
- thunkApi.dispatch(handleNextScreenStep('PASSWORD_SUCCESS_STEP'));
332
- (_c = (_b = settings.data.appConfig).onStepCompleted) === null || _c === void 0 ? void 0 : _c.call(_b, settings.data.activeScreen.name, payload);
380
+ sleep(100).then(function () { return thunkApi.dispatch(handleNextScreenStep('PASSWORD_SUCCESS_STEP')); });
381
+ (_d = (_c = settings.data.appConfig).onStepCompleted) === null || _d === void 0 ? void 0 : _d.call(_c, settings.data.activeScreen.name, payload);
333
382
  }
334
383
  return [2, { data: data, formData: __assign(__assign({}, params), passwordData) }];
335
384
  }
336
385
  });
337
386
  }); });
338
387
  export var retrieveBoardResetPasswordSuccess = createAsyncThunk('retrieveBoardResetPasswordSuccess', function (params, thunkApi) { return __awaiter(void 0, void 0, void 0, function () {
339
- var _a, password, settings, id, boardInfoData;
340
- var _b, _c, _d, _e;
341
- return __generator(this, function (_f) {
342
- switch (_f.label) {
388
+ var _a, password, settings, _b, board_id, boardResponse, recipient, _c, showBoard, mode, _d, id, type, data;
389
+ var _e, _f, _g, _h, _j, _k, _l, _m;
390
+ return __generator(this, function (_o) {
391
+ switch (_o.label) {
343
392
  case 0:
344
393
  _a = thunkApi.getState(), password = _a.password, settings = _a.settings;
345
- id = (password.data.verify.responseBody || { board_id: '' }).board_id;
346
- return [4, API.boardService.retrieveBoardInfoStatus(id)];
394
+ _b = password.data.verify.responseBody || { board_id: '' }, board_id = _b.board_id, boardResponse = _b.boardResponse, recipient = _b.recipient;
395
+ _c = settings.data.appConfig, showBoard = _c.showBoard, mode = _c.mode;
396
+ if (!showBoard && mode === 'content') {
397
+ (_f = (_e = settings.data.appConfig).onStepCompleted) === null || _f === void 0 ? void 0 : _f.call(_e, settings.data.activeScreen.name, {});
398
+ (_h = (_g = settings.data.appConfig).onFlowCompleted) === null || _h === void 0 ? void 0 : _h.call(_g, { data: boardResponse });
399
+ return [2, { id: board_id, flows: [] }];
400
+ }
401
+ _d = recipient || {}, id = _d.id, type = _d.type;
402
+ return [4, Promise.all([
403
+ API.boardService.retrieveBoardInfoStatus(board_id),
404
+ thunkApi.dispatch(retrieveBoardDetails({ boardId: board_id, individualId: id, individualType: type })).unwrap()
405
+ ])];
347
406
  case 1:
348
- boardInfoData = _f.sent();
349
- return [4, thunkApi.dispatch(retrieveBoardDetails(id))];
350
- case 2:
351
- _f.sent();
407
+ data = (_o.sent())[0];
352
408
  thunkApi.dispatch(handleNextScreenStep());
353
- (_c = (_b = settings.data.appConfig).onStepCompleted) === null || _c === void 0 ? void 0 : _c.call(_b, settings.data.activeScreen.name, { id: id });
354
- (_e = (_d = settings.data.appConfig).onFlowCompleted) === null || _e === void 0 ? void 0 : _e.call(_d, id);
355
- return [2, { id: id, response: { flows: (boardInfoData === null || boardInfoData === void 0 ? void 0 : boardInfoData.info) || [] } }];
409
+ (_k = (_j = settings.data.appConfig).onStepCompleted) === null || _k === void 0 ? void 0 : _k.call(_j, settings.data.activeScreen.name, { id: id });
410
+ (_m = (_l = settings.data.appConfig).onFlowCompleted) === null || _m === void 0 ? void 0 : _m.call(_l, board_id);
411
+ return [2, { id: board_id, flows: (data === null || data === void 0 ? void 0 : data.info) || [] }];
412
+ }
413
+ });
414
+ }); });
415
+ export var onCloseCompletePassword = createAsyncThunk('password/onCloseCompletePassword', function (_, thunkApi) { return __awaiter(void 0, void 0, void 0, function () {
416
+ var password, _a, merchant, brand, entity;
417
+ return __generator(this, function (_b) {
418
+ switch (_b.label) {
419
+ case 0:
420
+ password = thunkApi.getState().password;
421
+ _a = password.data.verify.responseBody || {}, merchant = _a.merchant, brand = _a.brand, entity = _a.entity;
422
+ return [4, thunkApi.dispatch(onCloseComplete({ merchantId: merchant === null || merchant === void 0 ? void 0 : merchant.id, brandId: brand === null || brand === void 0 ? void 0 : brand.id, entityId: entity === null || entity === void 0 ? void 0 : entity.id }))];
423
+ case 1:
424
+ _b.sent();
425
+ return [2];
356
426
  }
357
427
  });
358
428
  }); });
@@ -393,17 +463,13 @@ export var passwordSlice = createSlice({
393
463
  extraReducers: function (builder) {
394
464
  builder
395
465
  .addCase(verifyLeadToken.fulfilled, function (state, action) {
396
- var _a;
397
466
  state.data.verify.operationType = PASSWORD_OPERATION_TYPE.SET_PASSWORD;
398
467
  state.error = null;
399
468
  state.customLoading = false;
400
- var _b = action.payload, data = _b.data, token = _b.token, boardResponse = _b.boardResponse;
401
- var description = (((_a = data === null || data === void 0 ? void 0 : data.errors) === null || _a === void 0 ? void 0 : _a[0]) || {}).description;
402
- if (description) {
403
- state.error = description;
404
- return;
405
- }
406
- state.data.verify.responseBody = __assign(__assign(__assign(__assign({}, data), boardResponse), state.data.verify.responseBody), { board_id: data.id });
469
+ var _a = action.payload, data = _a.data, token = _a.token, flows = _a.flows;
470
+ state.data.verify.responseBody = __assign(__assign(__assign(__assign({}, data), state.data.verify.responseBody), { board_id: data.id }), ((flows === null || flows === void 0 ? void 0 : flows.length) && {
471
+ flows: flows
472
+ }));
407
473
  state.data.verify.token = token;
408
474
  })
409
475
  .addCase(verifyLeadToken.pending, function (state) {
@@ -436,17 +502,14 @@ export var passwordSlice = createSlice({
436
502
  state.error = null;
437
503
  })
438
504
  .addCase(verifyPasswordLeadOTP.fulfilled, function (state, action) {
439
- var _a;
440
505
  state.loading = false;
441
506
  state.error = null;
442
- var _b = action.payload, data = _b.data, formData = _b.formData;
443
- var description = (((_a = data === null || data === void 0 ? void 0 : data.errors) === null || _a === void 0 ? void 0 : _a[0]) || {}).description;
444
- if (description) {
445
- state.error = description;
446
- return;
447
- }
507
+ var _a = action.payload, data = _a.data, formData = _a.formData, flows = _a.flows;
448
508
  state.data.otpData = formData;
449
509
  state.data.otpData.responseBody = data;
510
+ state.data.verify.responseBody = __assign(__assign(__assign(__assign({}, data), state.data.verify.responseBody), { board_id: data.id }), ((flows === null || flows === void 0 ? void 0 : flows.length) && {
511
+ flows: flows
512
+ }));
450
513
  })
451
514
  .addCase(verifyPasswordLeadOTP.rejected, function (state, action) {
452
515
  state.loading = false;
@@ -480,7 +543,7 @@ export var passwordSlice = createSlice({
480
543
  .addCase(retrieveBoardDetails.fulfilled, function (state, action) {
481
544
  state.error = null;
482
545
  state.loading = false;
483
- var data = (action.payload || {}).data;
546
+ var data = action.payload || {};
484
547
  state.data.verify.responseBody = __assign(__assign({}, state.data.verify.responseBody), data);
485
548
  })
486
549
  .addCase(retrieveBoardDetails.rejected, function (state, action) {
@@ -488,15 +551,11 @@ export var passwordSlice = createSlice({
488
551
  state.loading = false;
489
552
  })
490
553
  .addCase(updateBoardSuccess.fulfilled, function (state, action) {
554
+ var _a;
491
555
  state.loading = false;
492
556
  state.error = null;
493
- var response = (action.payload || {}).response;
494
- var flows = response.flows;
495
- var _a = state.data.verify.responseBody || {}, individuals = _a.individuals, individualData = _a.individualData;
496
- var data_state = (individualData || {}).data_state;
497
- state.data.verify.responseBody = __assign(__assign(__assign(__assign({}, state.data.verify.responseBody), { flows: flows }), (individualData && { user: individualData })), (data_state && {
498
- individuals: __assign(__assign({}, individuals), { data_state: data_state })
499
- }));
557
+ var _b = action.payload || {}, flows = _b.flows, data = _b.data;
558
+ state.data.verify.responseBody = __assign(__assign({}, state.data.verify.responseBody), { flows: flows, recipient: (_a = data === null || data === void 0 ? void 0 : data.notification) === null || _a === void 0 ? void 0 : _a.recipient });
500
559
  })
501
560
  .addCase(updateBoardSuccess.pending, function (state) {
502
561
  state.loading = true;
@@ -505,20 +564,27 @@ export var passwordSlice = createSlice({
505
564
  .addCase(updateBoardSuccess.rejected, function (state, action) {
506
565
  state.loading = false;
507
566
  state.error = action.error.message;
567
+ })
568
+ .addCase(retrieveBoardStatus.pending, function (state) {
569
+ state.error = null;
570
+ state.loading = true;
571
+ })
572
+ .addCase(retrieveBoardStatus.fulfilled, function (state, action) {
573
+ state.error = null;
574
+ state.loading = false;
575
+ var flows = (action.payload || {}).flows;
576
+ state.data.verify.responseBody = __assign(__assign({}, state.data.verify.responseBody), { flows: flows });
577
+ })
578
+ .addCase(retrieveBoardStatus.rejected, function (state, action) {
579
+ state.error = action.error.message;
580
+ state.loading = false;
508
581
  })
509
582
  .addCase(verifyOperationToken.fulfilled, function (state, action) {
510
- var _a;
511
583
  state.data.verify.operationType = PASSWORD_OPERATION_TYPE.RESET_PASSWORD;
512
584
  state.error = null;
513
585
  state.customLoading = false;
514
- var _b = action.payload, data = _b.data, token = _b.token, boardId = _b.boardId, flows = _b.flows, boardResponse = _b.boardResponse, boardInfoId = _b.boardInfoId;
515
- state.data.verify.responseBody = __assign(__assign(__assign({}, boardResponse), state.data.verify.responseBody), { board_id: boardId, board_info_id: boardInfoId, flows: flows });
516
- var description = (((_a = data === null || data === void 0 ? void 0 : data.errors) === null || _a === void 0 ? void 0 : _a[0]) || {}).description;
517
- if (description) {
518
- state.error = description;
519
- return;
520
- }
521
- state.data.verify.responseBody = __assign(__assign(__assign(__assign({}, data), boardResponse), state.data.verify.responseBody), { board_id: boardId, board_info_id: boardInfoId, flows: flows });
586
+ var _a = action.payload, data = _a.data, token = _a.token, boardId = _a.boardId, boardInfoId = _a.boardInfoId, recipient = _a.recipient;
587
+ state.data.verify.responseBody = __assign(__assign(__assign(__assign({}, data), state.data.verify.responseBody), { board_id: boardId, board_info_id: boardInfoId }), (recipient && { recipient: recipient }));
522
588
  state.data.verify.token = token;
523
589
  })
524
590
  .addCase(verifyOperationToken.pending, function (state) {
@@ -547,16 +613,10 @@ export var passwordSlice = createSlice({
547
613
  state.error = action.error.message;
548
614
  })
549
615
  .addCase(resetPassword.fulfilled, function (state, action) {
550
- var _a;
551
616
  state.data.verify.operationType = PASSWORD_OPERATION_TYPE.RESET_PASSWORD;
552
617
  state.error = null;
553
618
  state.loading = false;
554
- var _b = action.payload, data = _b.data, formData = _b.formData;
555
- var description = (((_a = data === null || data === void 0 ? void 0 : data.errors) === null || _a === void 0 ? void 0 : _a[0]) || {}).description;
556
- if (description) {
557
- state.error = description;
558
- return;
559
- }
619
+ var _a = action.payload, data = _a.data, formData = _a.formData;
560
620
  state.data.passwordData = formData;
561
621
  state.data.passwordData.responseBody = data;
562
622
  })
@@ -571,13 +631,8 @@ export var passwordSlice = createSlice({
571
631
  .addCase(retrieveBoardResetPasswordSuccess.fulfilled, function (state, action) {
572
632
  state.loading = false;
573
633
  state.error = null;
574
- var response = (action.payload || {}).response;
575
- var flows = response.flows;
576
- var _a = state.data.verify.responseBody || {}, individuals = _a.individuals, individualData = _a.individualData;
577
- var data_state = (((individualData === null || individualData === void 0 ? void 0 : individualData.is_authorized) ? individuals : individualData) || {}).data_state;
578
- state.data.verify.responseBody = __assign(__assign(__assign(__assign({}, state.data.verify.responseBody), { flows: flows }), (individualData && { user: individualData })), (data_state && {
579
- individuals: __assign(__assign({}, individuals), { data_state: data_state })
580
- }));
634
+ var flows = (action.payload || {}).flows;
635
+ state.data.verify.responseBody = __assign(__assign({}, state.data.verify.responseBody), { flows: flows });
581
636
  })
582
637
  .addCase(retrieveBoardResetPasswordSuccess.pending, function (state) {
583
638
  state.loading = true;
@@ -586,6 +641,18 @@ export var passwordSlice = createSlice({
586
641
  .addCase(retrieveBoardResetPasswordSuccess.rejected, function (state, action) {
587
642
  state.loading = false;
588
643
  state.error = action.error.message;
644
+ })
645
+ .addCase(onCloseCompletePassword.pending, function (state) {
646
+ state.loading = true;
647
+ state.error = null;
648
+ })
649
+ .addCase(onCloseCompletePassword.fulfilled, function (state) {
650
+ state.loading = false;
651
+ state.error = null;
652
+ })
653
+ .addCase(onCloseCompletePassword.rejected, function (state, action) {
654
+ state.loading = false;
655
+ state.error = action.error.message;
589
656
  });
590
657
  }
591
658
  });