@redneckz/wildless-cms-uni-blocks 0.14.670 → 0.14.672

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 (425) hide show
  1. package/bundle/api/RetailAPI/checkCaptcha.d.ts +1 -1
  2. package/bundle/api/RetailAPI/createCaptcha.d.ts +1 -1
  3. package/bundle/api/RetailAPI/createUserProfile.d.ts +1 -1
  4. package/bundle/api/RetailAPI/doRequest.d.ts +2 -1
  5. package/bundle/api/RetailAPI/getCardTypes.d.ts +8 -0
  6. package/bundle/api/RetailAPI/getLink.d.ts +1 -1
  7. package/bundle/api/RetailAPI/getPaymentSystems.d.ts +4 -0
  8. package/bundle/api/RetailAPI/getTaskStatus.d.ts +2 -3
  9. package/bundle/api/RetailAPI/regionOffices.d.ts +1 -1
  10. package/bundle/api/RetailAPI/sendCode.d.ts +1 -4
  11. package/bundle/api/RetailAPI/sendSignalToProcess.d.ts +1 -5
  12. package/bundle/api/RetailAPI/updateProfileEsia.d.ts +1 -1
  13. package/bundle/api/RetailAPI/updateUserProfile.d.ts +1 -1
  14. package/bundle/api/RetailAPI/updateUserTask.d.ts +1 -1
  15. package/bundle/bundle.umd.js +131 -104
  16. package/bundle/bundle.umd.min.js +1 -1
  17. package/bundle/ui-kit/FormField/Fields/PaymentSystemField.d.ts +0 -2
  18. package/dist/api/RetailAPI/checkCaptcha.d.ts +1 -1
  19. package/dist/api/RetailAPI/checkCaptcha.js +3 -1
  20. package/dist/api/RetailAPI/checkCaptcha.js.map +1 -1
  21. package/dist/api/RetailAPI/checkCode.js +5 -3
  22. package/dist/api/RetailAPI/checkCode.js.map +1 -1
  23. package/dist/api/RetailAPI/createCaptcha.d.ts +1 -1
  24. package/dist/api/RetailAPI/createCaptcha.js +1 -1
  25. package/dist/api/RetailAPI/createCaptcha.js.map +1 -1
  26. package/dist/api/RetailAPI/createDraftTask.js +4 -1
  27. package/dist/api/RetailAPI/createDraftTask.js.map +1 -1
  28. package/dist/api/RetailAPI/createUserProfile.d.ts +1 -1
  29. package/dist/api/RetailAPI/createUserProfile.js +1 -1
  30. package/dist/api/RetailAPI/createUserProfile.js.map +1 -1
  31. package/dist/api/RetailAPI/doRequest.d.ts +2 -1
  32. package/dist/api/RetailAPI/doRequest.js +13 -6
  33. package/dist/api/RetailAPI/doRequest.js.map +1 -1
  34. package/dist/api/RetailAPI/feedbackById.js +1 -1
  35. package/dist/api/RetailAPI/feedbackById.js.map +1 -1
  36. package/dist/api/RetailAPI/getCardTypes.d.ts +8 -0
  37. package/dist/api/RetailAPI/getCardTypes.js +13 -0
  38. package/dist/api/RetailAPI/getCardTypes.js.map +1 -0
  39. package/dist/api/RetailAPI/getLink.d.ts +1 -1
  40. package/dist/api/RetailAPI/getLink.js +1 -1
  41. package/dist/api/RetailAPI/getLink.js.map +1 -1
  42. package/dist/api/RetailAPI/getPaymentSystems.d.ts +4 -0
  43. package/dist/api/RetailAPI/getPaymentSystems.js +15 -0
  44. package/dist/api/RetailAPI/getPaymentSystems.js.map +1 -0
  45. package/dist/api/RetailAPI/getTaskStatus.d.ts +2 -3
  46. package/dist/api/RetailAPI/getTaskStatus.js +1 -1
  47. package/dist/api/RetailAPI/getTaskStatus.js.map +1 -1
  48. package/dist/api/RetailAPI/regionOffices.d.ts +1 -1
  49. package/dist/api/RetailAPI/regionOffices.js +9 -8
  50. package/dist/api/RetailAPI/regionOffices.js.map +1 -1
  51. package/dist/api/RetailAPI/sendCode.d.ts +1 -4
  52. package/dist/api/RetailAPI/sendCode.js +4 -1
  53. package/dist/api/RetailAPI/sendCode.js.map +1 -1
  54. package/dist/api/RetailAPI/sendSignalToProcess.d.ts +1 -5
  55. package/dist/api/RetailAPI/sendSignalToProcess.js.map +1 -1
  56. package/dist/api/RetailAPI/updateProfileEsia.d.ts +1 -1
  57. package/dist/api/RetailAPI/updateProfileEsia.js +1 -1
  58. package/dist/api/RetailAPI/updateProfileEsia.js.map +1 -1
  59. package/dist/api/RetailAPI/updateRefreshToken.js +4 -4
  60. package/dist/api/RetailAPI/updateRefreshToken.js.map +1 -1
  61. package/dist/api/RetailAPI/updateUserProfile.d.ts +1 -1
  62. package/dist/api/RetailAPI/updateUserProfile.js +1 -1
  63. package/dist/api/RetailAPI/updateUserProfile.js.map +1 -1
  64. package/dist/api/RetailAPI/updateUserTask.d.ts +1 -1
  65. package/dist/api/RetailAPI/updateUserTask.js +1 -1
  66. package/dist/api/RetailAPI/updateUserTask.js.map +1 -1
  67. package/dist/components/ApplicationLeadForm/useApplicationLeadApi.js +1 -1
  68. package/dist/components/ApplicationLeadForm/useApplicationLeadApi.js.map +1 -1
  69. package/dist/components/ApplicationLeadForm/useInitApplicationLead.js +5 -4
  70. package/dist/components/ApplicationLeadForm/useInitApplicationLead.js.map +1 -1
  71. package/dist/components/CreditCardForm/CreditCardFormStatusTracker.js +4 -3
  72. package/dist/components/CreditCardForm/CreditCardFormStatusTracker.js.map +1 -1
  73. package/dist/components/CreditCardForm/formStateMap.js +1 -2
  74. package/dist/components/CreditCardForm/formStateMap.js.map +1 -1
  75. package/dist/components/CreditForm/CreditFormStatusTracker.js +1 -1
  76. package/dist/components/CreditForm/CreditFormStatusTracker.js.map +1 -1
  77. package/dist/ui-kit/CaptchaDialog/CaptchaDialog.js +16 -5
  78. package/dist/ui-kit/CaptchaDialog/CaptchaDialog.js.map +1 -1
  79. package/dist/ui-kit/EsiaLoginDialog/EsiaLoginDialog.js.map +1 -1
  80. package/dist/ui-kit/FormField/Fields/AddressRetailField.js +2 -3
  81. package/dist/ui-kit/FormField/Fields/AddressRetailField.js.map +1 -1
  82. package/dist/ui-kit/FormField/Fields/CardCategoryField.js +11 -3
  83. package/dist/ui-kit/FormField/Fields/CardCategoryField.js.map +1 -1
  84. package/dist/ui-kit/FormField/Fields/PaymentSystemField.d.ts +0 -2
  85. package/dist/ui-kit/FormField/Fields/PaymentSystemField.js +11 -6
  86. package/dist/ui-kit/FormField/Fields/PaymentSystemField.js.map +1 -1
  87. package/dist/ui-kit/VerifyPhoneDialog/VerifyPhoneDialog.js +17 -12
  88. package/dist/ui-kit/VerifyPhoneDialog/VerifyPhoneDialog.js.map +1 -1
  89. package/lib/api/RetailAPI/checkCaptcha.d.ts +1 -1
  90. package/lib/api/RetailAPI/checkCaptcha.js +3 -1
  91. package/lib/api/RetailAPI/checkCaptcha.js.map +1 -1
  92. package/lib/api/RetailAPI/checkCode.js +6 -4
  93. package/lib/api/RetailAPI/checkCode.js.map +1 -1
  94. package/lib/api/RetailAPI/createCaptcha.d.ts +1 -1
  95. package/lib/api/RetailAPI/createCaptcha.js +1 -1
  96. package/lib/api/RetailAPI/createCaptcha.js.map +1 -1
  97. package/lib/api/RetailAPI/createDraftTask.js +5 -2
  98. package/lib/api/RetailAPI/createDraftTask.js.map +1 -1
  99. package/lib/api/RetailAPI/createUserProfile.d.ts +1 -1
  100. package/lib/api/RetailAPI/createUserProfile.js +2 -2
  101. package/lib/api/RetailAPI/createUserProfile.js.map +1 -1
  102. package/lib/api/RetailAPI/doRequest.d.ts +2 -1
  103. package/lib/api/RetailAPI/doRequest.js +11 -5
  104. package/lib/api/RetailAPI/doRequest.js.map +1 -1
  105. package/lib/api/RetailAPI/feedbackById.js +1 -1
  106. package/lib/api/RetailAPI/feedbackById.js.map +1 -1
  107. package/lib/api/RetailAPI/getCardTypes.d.ts +8 -0
  108. package/lib/api/RetailAPI/getCardTypes.js +10 -0
  109. package/lib/api/RetailAPI/getCardTypes.js.map +1 -0
  110. package/lib/api/RetailAPI/getLink.d.ts +1 -1
  111. package/lib/api/RetailAPI/getLink.js +2 -2
  112. package/lib/api/RetailAPI/getLink.js.map +1 -1
  113. package/lib/api/RetailAPI/getPaymentSystems.d.ts +4 -0
  114. package/lib/api/RetailAPI/getPaymentSystems.js +12 -0
  115. package/lib/api/RetailAPI/getPaymentSystems.js.map +1 -0
  116. package/lib/api/RetailAPI/getTaskStatus.d.ts +2 -3
  117. package/lib/api/RetailAPI/getTaskStatus.js +2 -2
  118. package/lib/api/RetailAPI/getTaskStatus.js.map +1 -1
  119. package/lib/api/RetailAPI/regionOffices.d.ts +1 -1
  120. package/lib/api/RetailAPI/regionOffices.js +8 -7
  121. package/lib/api/RetailAPI/regionOffices.js.map +1 -1
  122. package/lib/api/RetailAPI/sendCode.d.ts +1 -4
  123. package/lib/api/RetailAPI/sendCode.js +5 -2
  124. package/lib/api/RetailAPI/sendCode.js.map +1 -1
  125. package/lib/api/RetailAPI/sendSignalToProcess.d.ts +1 -5
  126. package/lib/api/RetailAPI/sendSignalToProcess.js.map +1 -1
  127. package/lib/api/RetailAPI/updateProfileEsia.d.ts +1 -1
  128. package/lib/api/RetailAPI/updateProfileEsia.js +2 -2
  129. package/lib/api/RetailAPI/updateProfileEsia.js.map +1 -1
  130. package/lib/api/RetailAPI/updateRefreshToken.js +4 -4
  131. package/lib/api/RetailAPI/updateRefreshToken.js.map +1 -1
  132. package/lib/api/RetailAPI/updateUserProfile.d.ts +1 -1
  133. package/lib/api/RetailAPI/updateUserProfile.js +2 -2
  134. package/lib/api/RetailAPI/updateUserProfile.js.map +1 -1
  135. package/lib/api/RetailAPI/updateUserTask.d.ts +1 -1
  136. package/lib/api/RetailAPI/updateUserTask.js +2 -2
  137. package/lib/api/RetailAPI/updateUserTask.js.map +1 -1
  138. package/lib/components/ApplicationLeadForm/useApplicationLeadApi.js +1 -1
  139. package/lib/components/ApplicationLeadForm/useApplicationLeadApi.js.map +1 -1
  140. package/lib/components/ApplicationLeadForm/useInitApplicationLead.js +5 -4
  141. package/lib/components/ApplicationLeadForm/useInitApplicationLead.js.map +1 -1
  142. package/lib/components/CreditCardForm/CreditCardFormStatusTracker.js +5 -4
  143. package/lib/components/CreditCardForm/CreditCardFormStatusTracker.js.map +1 -1
  144. package/lib/components/CreditCardForm/formStateMap.js +1 -2
  145. package/lib/components/CreditCardForm/formStateMap.js.map +1 -1
  146. package/lib/components/CreditForm/CreditFormStatusTracker.js +1 -1
  147. package/lib/components/CreditForm/CreditFormStatusTracker.js.map +1 -1
  148. package/lib/ui-kit/CaptchaDialog/CaptchaDialog.js +17 -6
  149. package/lib/ui-kit/CaptchaDialog/CaptchaDialog.js.map +1 -1
  150. package/lib/ui-kit/EsiaLoginDialog/EsiaLoginDialog.js.map +1 -1
  151. package/lib/ui-kit/FormField/Fields/AddressRetailField.js +3 -4
  152. package/lib/ui-kit/FormField/Fields/AddressRetailField.js.map +1 -1
  153. package/lib/ui-kit/FormField/Fields/CardCategoryField.js +11 -3
  154. package/lib/ui-kit/FormField/Fields/CardCategoryField.js.map +1 -1
  155. package/lib/ui-kit/FormField/Fields/PaymentSystemField.d.ts +0 -2
  156. package/lib/ui-kit/FormField/Fields/PaymentSystemField.js +10 -5
  157. package/lib/ui-kit/FormField/Fields/PaymentSystemField.js.map +1 -1
  158. package/lib/ui-kit/VerifyPhoneDialog/VerifyPhoneDialog.js +17 -12
  159. package/lib/ui-kit/VerifyPhoneDialog/VerifyPhoneDialog.js.map +1 -1
  160. package/mobile/bundle/api/RetailAPI/checkCaptcha.d.ts +1 -1
  161. package/mobile/bundle/api/RetailAPI/createCaptcha.d.ts +1 -1
  162. package/mobile/bundle/api/RetailAPI/createUserProfile.d.ts +1 -1
  163. package/mobile/bundle/api/RetailAPI/doRequest.d.ts +2 -1
  164. package/mobile/bundle/api/RetailAPI/getCardTypes.d.ts +8 -0
  165. package/mobile/bundle/api/RetailAPI/getLink.d.ts +1 -1
  166. package/mobile/bundle/api/RetailAPI/getPaymentSystems.d.ts +4 -0
  167. package/mobile/bundle/api/RetailAPI/getTaskStatus.d.ts +2 -3
  168. package/mobile/bundle/api/RetailAPI/regionOffices.d.ts +1 -1
  169. package/mobile/bundle/api/RetailAPI/sendCode.d.ts +1 -4
  170. package/mobile/bundle/api/RetailAPI/sendSignalToProcess.d.ts +1 -5
  171. package/mobile/bundle/api/RetailAPI/updateProfileEsia.d.ts +1 -1
  172. package/mobile/bundle/api/RetailAPI/updateUserProfile.d.ts +1 -1
  173. package/mobile/bundle/api/RetailAPI/updateUserTask.d.ts +1 -1
  174. package/mobile/bundle/bundle.umd.js +131 -104
  175. package/mobile/bundle/bundle.umd.min.js +1 -1
  176. package/mobile/bundle/ui-kit/FormField/Fields/PaymentSystemField.d.ts +0 -2
  177. package/mobile/dist/api/RetailAPI/checkCaptcha.d.ts +1 -1
  178. package/mobile/dist/api/RetailAPI/checkCaptcha.js +3 -1
  179. package/mobile/dist/api/RetailAPI/checkCaptcha.js.map +1 -1
  180. package/mobile/dist/api/RetailAPI/checkCode.js +5 -3
  181. package/mobile/dist/api/RetailAPI/checkCode.js.map +1 -1
  182. package/mobile/dist/api/RetailAPI/createCaptcha.d.ts +1 -1
  183. package/mobile/dist/api/RetailAPI/createCaptcha.js +1 -1
  184. package/mobile/dist/api/RetailAPI/createCaptcha.js.map +1 -1
  185. package/mobile/dist/api/RetailAPI/createDraftTask.js +4 -1
  186. package/mobile/dist/api/RetailAPI/createDraftTask.js.map +1 -1
  187. package/mobile/dist/api/RetailAPI/createUserProfile.d.ts +1 -1
  188. package/mobile/dist/api/RetailAPI/createUserProfile.js +1 -1
  189. package/mobile/dist/api/RetailAPI/createUserProfile.js.map +1 -1
  190. package/mobile/dist/api/RetailAPI/doRequest.d.ts +2 -1
  191. package/mobile/dist/api/RetailAPI/doRequest.js +13 -6
  192. package/mobile/dist/api/RetailAPI/doRequest.js.map +1 -1
  193. package/mobile/dist/api/RetailAPI/feedbackById.js +1 -1
  194. package/mobile/dist/api/RetailAPI/feedbackById.js.map +1 -1
  195. package/mobile/dist/api/RetailAPI/getCardTypes.d.ts +8 -0
  196. package/mobile/dist/api/RetailAPI/getCardTypes.js +13 -0
  197. package/mobile/dist/api/RetailAPI/getCardTypes.js.map +1 -0
  198. package/mobile/dist/api/RetailAPI/getLink.d.ts +1 -1
  199. package/mobile/dist/api/RetailAPI/getLink.js +1 -1
  200. package/mobile/dist/api/RetailAPI/getLink.js.map +1 -1
  201. package/mobile/dist/api/RetailAPI/getPaymentSystems.d.ts +4 -0
  202. package/mobile/dist/api/RetailAPI/getPaymentSystems.js +15 -0
  203. package/mobile/dist/api/RetailAPI/getPaymentSystems.js.map +1 -0
  204. package/mobile/dist/api/RetailAPI/getTaskStatus.d.ts +2 -3
  205. package/mobile/dist/api/RetailAPI/getTaskStatus.js +1 -1
  206. package/mobile/dist/api/RetailAPI/getTaskStatus.js.map +1 -1
  207. package/mobile/dist/api/RetailAPI/regionOffices.d.ts +1 -1
  208. package/mobile/dist/api/RetailAPI/regionOffices.js +9 -8
  209. package/mobile/dist/api/RetailAPI/regionOffices.js.map +1 -1
  210. package/mobile/dist/api/RetailAPI/sendCode.d.ts +1 -4
  211. package/mobile/dist/api/RetailAPI/sendCode.js +4 -1
  212. package/mobile/dist/api/RetailAPI/sendCode.js.map +1 -1
  213. package/mobile/dist/api/RetailAPI/sendSignalToProcess.d.ts +1 -5
  214. package/mobile/dist/api/RetailAPI/sendSignalToProcess.js.map +1 -1
  215. package/mobile/dist/api/RetailAPI/updateProfileEsia.d.ts +1 -1
  216. package/mobile/dist/api/RetailAPI/updateProfileEsia.js +1 -1
  217. package/mobile/dist/api/RetailAPI/updateProfileEsia.js.map +1 -1
  218. package/mobile/dist/api/RetailAPI/updateRefreshToken.js +4 -4
  219. package/mobile/dist/api/RetailAPI/updateRefreshToken.js.map +1 -1
  220. package/mobile/dist/api/RetailAPI/updateUserProfile.d.ts +1 -1
  221. package/mobile/dist/api/RetailAPI/updateUserProfile.js +1 -1
  222. package/mobile/dist/api/RetailAPI/updateUserProfile.js.map +1 -1
  223. package/mobile/dist/api/RetailAPI/updateUserTask.d.ts +1 -1
  224. package/mobile/dist/api/RetailAPI/updateUserTask.js +1 -1
  225. package/mobile/dist/api/RetailAPI/updateUserTask.js.map +1 -1
  226. package/mobile/dist/components/ApplicationLeadForm/useApplicationLeadApi.js +1 -1
  227. package/mobile/dist/components/ApplicationLeadForm/useApplicationLeadApi.js.map +1 -1
  228. package/mobile/dist/components/ApplicationLeadForm/useInitApplicationLead.js +5 -4
  229. package/mobile/dist/components/ApplicationLeadForm/useInitApplicationLead.js.map +1 -1
  230. package/mobile/dist/components/CreditCardForm/CreditCardFormStatusTracker.js +4 -3
  231. package/mobile/dist/components/CreditCardForm/CreditCardFormStatusTracker.js.map +1 -1
  232. package/mobile/dist/components/CreditCardForm/formStateMap.js +1 -2
  233. package/mobile/dist/components/CreditCardForm/formStateMap.js.map +1 -1
  234. package/mobile/dist/components/CreditForm/CreditFormStatusTracker.js +1 -1
  235. package/mobile/dist/components/CreditForm/CreditFormStatusTracker.js.map +1 -1
  236. package/mobile/dist/ui-kit/CaptchaDialog/CaptchaDialog.js +16 -5
  237. package/mobile/dist/ui-kit/CaptchaDialog/CaptchaDialog.js.map +1 -1
  238. package/mobile/dist/ui-kit/EsiaLoginDialog/EsiaLoginDialog.js.map +1 -1
  239. package/mobile/dist/ui-kit/FormField/Fields/AddressRetailField.js +2 -3
  240. package/mobile/dist/ui-kit/FormField/Fields/AddressRetailField.js.map +1 -1
  241. package/mobile/dist/ui-kit/FormField/Fields/CardCategoryField.js +11 -3
  242. package/mobile/dist/ui-kit/FormField/Fields/CardCategoryField.js.map +1 -1
  243. package/mobile/dist/ui-kit/FormField/Fields/PaymentSystemField.d.ts +0 -2
  244. package/mobile/dist/ui-kit/FormField/Fields/PaymentSystemField.js +11 -6
  245. package/mobile/dist/ui-kit/FormField/Fields/PaymentSystemField.js.map +1 -1
  246. package/mobile/dist/ui-kit/VerifyPhoneDialog/VerifyPhoneDialog.js +17 -12
  247. package/mobile/dist/ui-kit/VerifyPhoneDialog/VerifyPhoneDialog.js.map +1 -1
  248. package/mobile/lib/api/RetailAPI/checkCaptcha.d.ts +1 -1
  249. package/mobile/lib/api/RetailAPI/checkCaptcha.js +3 -1
  250. package/mobile/lib/api/RetailAPI/checkCaptcha.js.map +1 -1
  251. package/mobile/lib/api/RetailAPI/checkCode.js +6 -4
  252. package/mobile/lib/api/RetailAPI/checkCode.js.map +1 -1
  253. package/mobile/lib/api/RetailAPI/createCaptcha.d.ts +1 -1
  254. package/mobile/lib/api/RetailAPI/createCaptcha.js +1 -1
  255. package/mobile/lib/api/RetailAPI/createCaptcha.js.map +1 -1
  256. package/mobile/lib/api/RetailAPI/createDraftTask.js +5 -2
  257. package/mobile/lib/api/RetailAPI/createDraftTask.js.map +1 -1
  258. package/mobile/lib/api/RetailAPI/createUserProfile.d.ts +1 -1
  259. package/mobile/lib/api/RetailAPI/createUserProfile.js +2 -2
  260. package/mobile/lib/api/RetailAPI/createUserProfile.js.map +1 -1
  261. package/mobile/lib/api/RetailAPI/doRequest.d.ts +2 -1
  262. package/mobile/lib/api/RetailAPI/doRequest.js +11 -5
  263. package/mobile/lib/api/RetailAPI/doRequest.js.map +1 -1
  264. package/mobile/lib/api/RetailAPI/feedbackById.js +1 -1
  265. package/mobile/lib/api/RetailAPI/feedbackById.js.map +1 -1
  266. package/mobile/lib/api/RetailAPI/getCardTypes.d.ts +8 -0
  267. package/mobile/lib/api/RetailAPI/getCardTypes.js +10 -0
  268. package/mobile/lib/api/RetailAPI/getCardTypes.js.map +1 -0
  269. package/mobile/lib/api/RetailAPI/getLink.d.ts +1 -1
  270. package/mobile/lib/api/RetailAPI/getLink.js +2 -2
  271. package/mobile/lib/api/RetailAPI/getLink.js.map +1 -1
  272. package/mobile/lib/api/RetailAPI/getPaymentSystems.d.ts +4 -0
  273. package/mobile/lib/api/RetailAPI/getPaymentSystems.js +12 -0
  274. package/mobile/lib/api/RetailAPI/getPaymentSystems.js.map +1 -0
  275. package/mobile/lib/api/RetailAPI/getTaskStatus.d.ts +2 -3
  276. package/mobile/lib/api/RetailAPI/getTaskStatus.js +2 -2
  277. package/mobile/lib/api/RetailAPI/getTaskStatus.js.map +1 -1
  278. package/mobile/lib/api/RetailAPI/regionOffices.d.ts +1 -1
  279. package/mobile/lib/api/RetailAPI/regionOffices.js +8 -7
  280. package/mobile/lib/api/RetailAPI/regionOffices.js.map +1 -1
  281. package/mobile/lib/api/RetailAPI/sendCode.d.ts +1 -4
  282. package/mobile/lib/api/RetailAPI/sendCode.js +5 -2
  283. package/mobile/lib/api/RetailAPI/sendCode.js.map +1 -1
  284. package/mobile/lib/api/RetailAPI/sendSignalToProcess.d.ts +1 -5
  285. package/mobile/lib/api/RetailAPI/sendSignalToProcess.js.map +1 -1
  286. package/mobile/lib/api/RetailAPI/updateProfileEsia.d.ts +1 -1
  287. package/mobile/lib/api/RetailAPI/updateProfileEsia.js +2 -2
  288. package/mobile/lib/api/RetailAPI/updateProfileEsia.js.map +1 -1
  289. package/mobile/lib/api/RetailAPI/updateRefreshToken.js +4 -4
  290. package/mobile/lib/api/RetailAPI/updateRefreshToken.js.map +1 -1
  291. package/mobile/lib/api/RetailAPI/updateUserProfile.d.ts +1 -1
  292. package/mobile/lib/api/RetailAPI/updateUserProfile.js +2 -2
  293. package/mobile/lib/api/RetailAPI/updateUserProfile.js.map +1 -1
  294. package/mobile/lib/api/RetailAPI/updateUserTask.d.ts +1 -1
  295. package/mobile/lib/api/RetailAPI/updateUserTask.js +2 -2
  296. package/mobile/lib/api/RetailAPI/updateUserTask.js.map +1 -1
  297. package/mobile/lib/components/ApplicationLeadForm/useApplicationLeadApi.js +1 -1
  298. package/mobile/lib/components/ApplicationLeadForm/useApplicationLeadApi.js.map +1 -1
  299. package/mobile/lib/components/ApplicationLeadForm/useInitApplicationLead.js +5 -4
  300. package/mobile/lib/components/ApplicationLeadForm/useInitApplicationLead.js.map +1 -1
  301. package/mobile/lib/components/CreditCardForm/CreditCardFormStatusTracker.js +5 -4
  302. package/mobile/lib/components/CreditCardForm/CreditCardFormStatusTracker.js.map +1 -1
  303. package/mobile/lib/components/CreditCardForm/formStateMap.js +1 -2
  304. package/mobile/lib/components/CreditCardForm/formStateMap.js.map +1 -1
  305. package/mobile/lib/components/CreditForm/CreditFormStatusTracker.js +1 -1
  306. package/mobile/lib/components/CreditForm/CreditFormStatusTracker.js.map +1 -1
  307. package/mobile/lib/ui-kit/CaptchaDialog/CaptchaDialog.js +17 -6
  308. package/mobile/lib/ui-kit/CaptchaDialog/CaptchaDialog.js.map +1 -1
  309. package/mobile/lib/ui-kit/EsiaLoginDialog/EsiaLoginDialog.js.map +1 -1
  310. package/mobile/lib/ui-kit/FormField/Fields/AddressRetailField.js +3 -4
  311. package/mobile/lib/ui-kit/FormField/Fields/AddressRetailField.js.map +1 -1
  312. package/mobile/lib/ui-kit/FormField/Fields/CardCategoryField.js +11 -3
  313. package/mobile/lib/ui-kit/FormField/Fields/CardCategoryField.js.map +1 -1
  314. package/mobile/lib/ui-kit/FormField/Fields/PaymentSystemField.d.ts +0 -2
  315. package/mobile/lib/ui-kit/FormField/Fields/PaymentSystemField.js +10 -5
  316. package/mobile/lib/ui-kit/FormField/Fields/PaymentSystemField.js.map +1 -1
  317. package/mobile/lib/ui-kit/VerifyPhoneDialog/VerifyPhoneDialog.js +17 -12
  318. package/mobile/lib/ui-kit/VerifyPhoneDialog/VerifyPhoneDialog.js.map +1 -1
  319. package/mobile/src/api/RetailAPI/checkCaptcha.ts +3 -1
  320. package/mobile/src/api/RetailAPI/checkCode.ts +7 -5
  321. package/mobile/src/api/RetailAPI/createCaptcha.ts +3 -1
  322. package/mobile/src/api/RetailAPI/createDraftTask.ts +12 -3
  323. package/mobile/src/api/RetailAPI/createUserProfile.ts +4 -2
  324. package/mobile/src/api/RetailAPI/doRequest.ts +19 -9
  325. package/mobile/src/api/RetailAPI/feedbackById.ts +2 -2
  326. package/mobile/src/api/RetailAPI/getCardTypes.ts +20 -0
  327. package/mobile/src/api/RetailAPI/getLink.ts +2 -2
  328. package/mobile/src/api/RetailAPI/getPaymentSystems.ts +21 -0
  329. package/mobile/src/api/RetailAPI/getTaskStatus.ts +3 -3
  330. package/mobile/src/api/RetailAPI/regionOffices.ts +18 -12
  331. package/mobile/src/api/RetailAPI/sendCode.ts +14 -2
  332. package/mobile/src/api/RetailAPI/sendSignalToProcess.ts +1 -6
  333. package/mobile/src/api/RetailAPI/updateProfileEsia.ts +2 -2
  334. package/mobile/src/api/RetailAPI/updateRefreshToken.ts +6 -6
  335. package/mobile/src/api/RetailAPI/updateUserProfile.ts +2 -2
  336. package/mobile/src/api/RetailAPI/updateUserTask.ts +2 -2
  337. package/mobile/src/components/ApplicationLeadForm/useApplicationLeadApi.ts +3 -3
  338. package/mobile/src/components/ApplicationLeadForm/useInitApplicationLead.ts +5 -4
  339. package/mobile/src/components/CreditCardForm/CreditCardFormStatusTracker.tsx +9 -8
  340. package/mobile/src/components/CreditCardForm/formStateMap.tsx +1 -2
  341. package/mobile/src/components/CreditForm/CreditFormStatusTracker.tsx +1 -1
  342. package/mobile/src/ui-kit/CaptchaDialog/CaptchaDialog.tsx +20 -12
  343. package/mobile/src/ui-kit/EsiaLoginDialog/EsiaLoginDialog.tsx +1 -0
  344. package/mobile/src/ui-kit/FormField/Fields/AddressRetailField.tsx +3 -4
  345. package/mobile/src/ui-kit/FormField/Fields/CardCategoryField.tsx +12 -3
  346. package/mobile/src/ui-kit/FormField/Fields/PaymentSystemField.tsx +12 -6
  347. package/mobile/src/ui-kit/VerifyPhoneDialog/VerifyPhoneDialog.tsx +18 -13
  348. package/package.json +1 -1
  349. package/src/api/RetailAPI/checkCaptcha.ts +3 -1
  350. package/src/api/RetailAPI/checkCode.ts +7 -5
  351. package/src/api/RetailAPI/createCaptcha.ts +3 -1
  352. package/src/api/RetailAPI/createDraftTask.ts +12 -3
  353. package/src/api/RetailAPI/createUserProfile.ts +4 -2
  354. package/src/api/RetailAPI/doRequest.ts +19 -9
  355. package/src/api/RetailAPI/feedbackById.ts +2 -2
  356. package/src/api/RetailAPI/getCardTypes.ts +20 -0
  357. package/src/api/RetailAPI/getLink.ts +2 -2
  358. package/src/api/RetailAPI/getPaymentSystems.ts +21 -0
  359. package/src/api/RetailAPI/getTaskStatus.ts +3 -3
  360. package/src/api/RetailAPI/regionOffices.ts +18 -12
  361. package/src/api/RetailAPI/sendCode.ts +14 -2
  362. package/src/api/RetailAPI/sendSignalToProcess.ts +1 -6
  363. package/src/api/RetailAPI/updateProfileEsia.ts +2 -2
  364. package/src/api/RetailAPI/updateRefreshToken.ts +6 -6
  365. package/src/api/RetailAPI/updateUserProfile.ts +2 -2
  366. package/src/api/RetailAPI/updateUserTask.ts +2 -2
  367. package/src/components/ApplicationLeadForm/useApplicationLeadApi.ts +3 -3
  368. package/src/components/ApplicationLeadForm/useInitApplicationLead.ts +5 -4
  369. package/src/components/CreditCardForm/CreditCardFormStatusTracker.tsx +9 -8
  370. package/src/components/CreditCardForm/formStateMap.tsx +1 -2
  371. package/src/components/CreditForm/CreditFormStatusTracker.tsx +1 -1
  372. package/src/ui-kit/CaptchaDialog/CaptchaDialog.tsx +20 -12
  373. package/src/ui-kit/EsiaLoginDialog/EsiaLoginDialog.tsx +1 -0
  374. package/src/ui-kit/FormField/Fields/AddressRetailField.tsx +3 -4
  375. package/src/ui-kit/FormField/Fields/CardCategoryField.tsx +12 -3
  376. package/src/ui-kit/FormField/Fields/PaymentSystemField.tsx +12 -6
  377. package/src/ui-kit/VerifyPhoneDialog/VerifyPhoneDialog.tsx +18 -13
  378. package/bundle/ui-kit/CaptchaDialog/handleCheckCaptcha.d.ts +0 -8
  379. package/bundle/ui-kit/CaptchaDialog/handleCreateCaptcha.d.ts +0 -1
  380. package/bundle/ui-kit/VerifyPhoneDialog/handleSendCode.d.ts +0 -15
  381. package/dist/ui-kit/CaptchaDialog/handleCheckCaptcha.d.ts +0 -8
  382. package/dist/ui-kit/CaptchaDialog/handleCheckCaptcha.js +0 -16
  383. package/dist/ui-kit/CaptchaDialog/handleCheckCaptcha.js.map +0 -1
  384. package/dist/ui-kit/CaptchaDialog/handleCreateCaptcha.d.ts +0 -1
  385. package/dist/ui-kit/CaptchaDialog/handleCreateCaptcha.js +0 -9
  386. package/dist/ui-kit/CaptchaDialog/handleCreateCaptcha.js.map +0 -1
  387. package/dist/ui-kit/VerifyPhoneDialog/handleSendCode.d.ts +0 -15
  388. package/dist/ui-kit/VerifyPhoneDialog/handleSendCode.js +0 -25
  389. package/dist/ui-kit/VerifyPhoneDialog/handleSendCode.js.map +0 -1
  390. package/lib/ui-kit/CaptchaDialog/handleCheckCaptcha.d.ts +0 -8
  391. package/lib/ui-kit/CaptchaDialog/handleCheckCaptcha.js +0 -13
  392. package/lib/ui-kit/CaptchaDialog/handleCheckCaptcha.js.map +0 -1
  393. package/lib/ui-kit/CaptchaDialog/handleCreateCaptcha.d.ts +0 -1
  394. package/lib/ui-kit/CaptchaDialog/handleCreateCaptcha.js +0 -6
  395. package/lib/ui-kit/CaptchaDialog/handleCreateCaptcha.js.map +0 -1
  396. package/lib/ui-kit/VerifyPhoneDialog/handleSendCode.d.ts +0 -15
  397. package/lib/ui-kit/VerifyPhoneDialog/handleSendCode.js +0 -22
  398. package/lib/ui-kit/VerifyPhoneDialog/handleSendCode.js.map +0 -1
  399. package/mobile/bundle/ui-kit/CaptchaDialog/handleCheckCaptcha.d.ts +0 -8
  400. package/mobile/bundle/ui-kit/CaptchaDialog/handleCreateCaptcha.d.ts +0 -1
  401. package/mobile/bundle/ui-kit/VerifyPhoneDialog/handleSendCode.d.ts +0 -15
  402. package/mobile/dist/ui-kit/CaptchaDialog/handleCheckCaptcha.d.ts +0 -8
  403. package/mobile/dist/ui-kit/CaptchaDialog/handleCheckCaptcha.js +0 -16
  404. package/mobile/dist/ui-kit/CaptchaDialog/handleCheckCaptcha.js.map +0 -1
  405. package/mobile/dist/ui-kit/CaptchaDialog/handleCreateCaptcha.d.ts +0 -1
  406. package/mobile/dist/ui-kit/CaptchaDialog/handleCreateCaptcha.js +0 -9
  407. package/mobile/dist/ui-kit/CaptchaDialog/handleCreateCaptcha.js.map +0 -1
  408. package/mobile/dist/ui-kit/VerifyPhoneDialog/handleSendCode.d.ts +0 -15
  409. package/mobile/dist/ui-kit/VerifyPhoneDialog/handleSendCode.js +0 -25
  410. package/mobile/dist/ui-kit/VerifyPhoneDialog/handleSendCode.js.map +0 -1
  411. package/mobile/lib/ui-kit/CaptchaDialog/handleCheckCaptcha.d.ts +0 -8
  412. package/mobile/lib/ui-kit/CaptchaDialog/handleCheckCaptcha.js +0 -13
  413. package/mobile/lib/ui-kit/CaptchaDialog/handleCheckCaptcha.js.map +0 -1
  414. package/mobile/lib/ui-kit/CaptchaDialog/handleCreateCaptcha.d.ts +0 -1
  415. package/mobile/lib/ui-kit/CaptchaDialog/handleCreateCaptcha.js +0 -6
  416. package/mobile/lib/ui-kit/CaptchaDialog/handleCreateCaptcha.js.map +0 -1
  417. package/mobile/lib/ui-kit/VerifyPhoneDialog/handleSendCode.d.ts +0 -15
  418. package/mobile/lib/ui-kit/VerifyPhoneDialog/handleSendCode.js +0 -22
  419. package/mobile/lib/ui-kit/VerifyPhoneDialog/handleSendCode.js.map +0 -1
  420. package/mobile/src/ui-kit/CaptchaDialog/handleCheckCaptcha.ts +0 -25
  421. package/mobile/src/ui-kit/CaptchaDialog/handleCreateCaptcha.ts +0 -9
  422. package/mobile/src/ui-kit/VerifyPhoneDialog/handleSendCode.ts +0 -43
  423. package/src/ui-kit/CaptchaDialog/handleCheckCaptcha.ts +0 -25
  424. package/src/ui-kit/CaptchaDialog/handleCreateCaptcha.ts +0 -9
  425. package/src/ui-kit/VerifyPhoneDialog/handleSendCode.ts +0 -43
@@ -4,11 +4,10 @@ export declare enum STATUS_TYPE {
4
4
  fail = "CANCELLED",
5
5
  rework = "REVISION"
6
6
  }
7
- interface GetTaskStatusResponse {
7
+ export interface GetTaskStatusResponse {
8
8
  statusCd: STATUS_TYPE;
9
9
  taskId: number;
10
10
  }
11
11
  export declare const getTaskStatus: (body: {
12
12
  taskId: number | null;
13
- }) => Promise<GetTaskStatusResponse>;
14
- export {};
13
+ }) => Promise<GetTaskStatusResponse | null>;
@@ -13,4 +13,4 @@ export declare type OfficeType = {
13
13
  export interface RegionOfficesResponseType {
14
14
  offices: OfficeType[];
15
15
  }
16
- export declare const regionOffices: (regionKey: string) => Promise<any>;
16
+ export declare const fetchRegionOffices: (regionKey: string) => Promise<OfficeType[]>;
@@ -1,10 +1,7 @@
1
- import { type StatusType } from './StatusType';
2
1
  export declare type SendCodeBody = {
3
2
  phoneNumber: string;
4
3
  smsCodesSetName: {
5
4
  key: 'AUTHENTICATION' | 'SEND_TASK';
6
5
  };
7
6
  };
8
- export declare const sendCode: (body: SendCodeBody) => Promise<StatusType | {
9
- errorMessage: string;
10
- }>;
7
+ export declare const sendCode: (body: SendCodeBody) => Promise<boolean>;
@@ -3,9 +3,5 @@ interface SendSignalToProcess {
3
3
  signalType: SignalType;
4
4
  taskId: number | null;
5
5
  }
6
- interface SendSignalToProcessResponse {
7
- statusCd: string;
8
- taskId: number;
9
- }
10
- export declare const sendSignalToProcess: (body: SendSignalToProcess) => Promise<SendSignalToProcessResponse>;
6
+ export declare const sendSignalToProcess: (body: SendSignalToProcess) => Promise<Response>;
11
7
  export {};
@@ -63,4 +63,4 @@ export declare type UpdateProfileEsiaResponse = {
63
63
  apartment: string;
64
64
  };
65
65
  };
66
- export declare const updateProfileEsia: (body: UpdateProfileEsiaBody) => Promise<UpdateProfileEsiaResponse>;
66
+ export declare const updateProfileEsia: (body: UpdateProfileEsiaBody) => Promise<UpdateProfileEsiaResponse | null>;
@@ -19,4 +19,4 @@ export declare type UpdateUserProfileBody = {
19
19
  smsConsentBki?: string;
20
20
  };
21
21
  };
22
- export declare const updateUserProfile: (body: UpdateUserProfileBody) => Promise<CreateUserProfileResponse>;
22
+ export declare const updateUserProfile: (body: UpdateUserProfileBody) => Promise<CreateUserProfileResponse | null>;
@@ -123,5 +123,5 @@ export declare type CreateUserProfileResponse = {
123
123
  id: number;
124
124
  };
125
125
  };
126
- export declare const updateUserTask: (body: UpdateUserTaskBody) => Promise<CreateUserProfileResponse>;
126
+ export declare const updateUserTask: (body: UpdateUserTaskBody) => Promise<CreateUserProfileResponse | null>;
127
127
  export {};
@@ -2024,8 +2024,18 @@
2024
2024
  const mapByIndex = (points, index) => points.map((_) => _.coords?.[index]);
2025
2025
  const getArraySumAndAverage = (arr) => arr.length && arr.reduce((a, b) => a + b) / arr.length;
2026
2026
 
2027
+ const fetchRetailJSON = async (url, method, body) => {
2028
+ try {
2029
+ const response = await doRequest(url, method, body);
2030
+ return response.json();
2031
+ }
2032
+ catch (err) {
2033
+ console.error(err);
2034
+ return null;
2035
+ }
2036
+ };
2027
2037
  async function doRequest(url, method, body) {
2028
- const response = await fetch(`${API_BASE_URI}${url}`, {
2038
+ return globalThis?.fetch?.(`${API_BASE_URI}${url}`, {
2029
2039
  method,
2030
2040
  headers: {
2031
2041
  'Content-Type': 'application/json',
@@ -2034,29 +2044,26 @@
2034
2044
  credentials: 'include',
2035
2045
  body: body ? JSON.stringify(body) : null,
2036
2046
  });
2037
- // TODO: add error handling
2038
- return isJSON(response) ? response.json() : response;
2039
2047
  }
2040
- // TODO: Need delete isJSON
2041
- const isJSON = (response) => response.headers.get('Content-Type') === 'application/json';
2042
2048
  const getAuthorizationHeaders = () => {
2043
2049
  const token = sessionStorage.getItem('accessToken');
2044
2050
  return token ? { Authorization: `Bearer ${token}` } : null;
2045
2051
  };
2046
2052
 
2047
- const regionOffices = async (regionKey) => {
2048
- const response = await doRequest('/public-data/regionOffices', 'POST', {
2053
+ const fetchRegionOffices = async (regionKey) => {
2054
+ const response = await fetchRetailJSON('/public-data/regionOffices', 'POST', {
2049
2055
  regionRfCd: {
2050
2056
  key: regionKey,
2051
2057
  },
2052
2058
  cashCardFlg: true,
2053
2059
  });
2054
- return await response.json().then((_) => _?.offices?.map((office) => ({
2060
+ return (response?.offices?.map((office) => ({
2055
2061
  ...office,
2056
- gpsLatitude: (office.latitude ?? DEFAULT_CENTER_COORDS[0]).toString().replace(',', '.'),
2057
- gpsLongitude: (office.longitude ?? DEFAULT_CENTER_COORDS[1]).toString().replace(',', '.'),
2058
- })));
2062
+ gpsLatitude: formatCoordinate(office.latitude ?? DEFAULT_CENTER_COORDS[0]),
2063
+ gpsLongitude: formatCoordinate(office.longitude ?? DEFAULT_CENTER_COORDS[1]),
2064
+ })) || []);
2059
2065
  };
2066
+ const formatCoordinate = (coordinate) => Number(coordinate.toString().replace(',', '.'));
2060
2067
 
2061
2068
  const Foldable = JSX(({ className = '', isFoldButtonOnTop = false, unfoldedByDefault = false, renderFoldableSection, renderFoldButton, }) => {
2062
2069
  const [isUnfolded, setIsUnfolded] = useState(unfoldedByDefault);
@@ -2479,9 +2486,8 @@
2479
2486
  field('addressRetail');
2480
2487
  useEffect(() => {
2481
2488
  (async () => {
2482
- const officesList = await regionOffices(regionValue?.key ?? '');
2483
- // eslint-disable-next-line @typescript-eslint/no-unsafe-argument
2484
- setOffices(officesList || []);
2489
+ const officesList = await fetchRegionOffices(regionValue?.key ?? '');
2490
+ setOffices(officesList);
2485
2491
  })();
2486
2492
  if (regionValue?.key) {
2487
2493
  field?.('addressRetail')?.onChange?.('');
@@ -2887,9 +2893,25 @@
2887
2893
  const FIELD_NAME$7 = 'birthPlace';
2888
2894
  const BirthPlaceField = JSX(({ field, input }) => (jsx(InputControl, { label: "\u041C\u0435\u0441\u0442\u043E \u0440\u043E\u0436\u0434\u0435\u043D\u0438\u044F", ...getValidation(field('birthPlace'), validatorObj.birthPlace, input?.required), ...input, disabled: input?.filledByEsia && isEsiaAuthorize(field, FIELD_NAME$7) })));
2889
2895
 
2896
+ const getCardTypes = async (paymentSystemType) => {
2897
+ const response = await doRequest('/dictionaryFiltered', 'POST', {
2898
+ type: 'CARD_TYPE',
2899
+ presets: { paymentSystemType, creditProgramId: 13 },
2900
+ });
2901
+ const data = await response?.json();
2902
+ return data;
2903
+ };
2904
+
2890
2905
  const CardCategoryField = JSX(({ field, input }) => {
2891
- const { data: cardCategory } = useLeadFormData('CARD_TYPE');
2892
- return (jsx(SelectField, { field: field, source: cardCategory, label: "\u041A\u0430\u0442\u0435\u0433\u043E\u0440\u0438\u044F \u043A\u0430\u0440\u0442\u044B", fieldName: "cardCategory", input: input }));
2906
+ const [cardTypes, setCardTypes] = useState([]);
2907
+ const selectedPaymentSystem = field('paymentSystem').value;
2908
+ useEffect(() => {
2909
+ (async () => {
2910
+ const fetchedCardTypes = await getCardTypes(selectedPaymentSystem);
2911
+ setCardTypes(fetchedCardTypes);
2912
+ })();
2913
+ }, [selectedPaymentSystem]);
2914
+ return (jsx(SelectField, { field: field, source: cardTypes, label: "\u041A\u0430\u0442\u0435\u0433\u043E\u0440\u0438\u044F \u043A\u0430\u0440\u0442\u044B", fieldName: "cardCategory", input: input }));
2893
2915
  });
2894
2916
 
2895
2917
  const ChildrenField = JSX(({ field, input }) => (jsx(InputControl, { label: "\u041A\u043E\u043B\u0438\u0447\u0435\u0441\u0442\u0432\u043E \u0434\u0435\u0442\u0435\u0439 \u0434\u043E 18 \u043B\u0435\u0442", placeholder: "\u0412\u0432\u0435\u0434\u0438\u0442\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435", type: "number", ...getValidation(field('children'), validatorObj.children, input?.required), ...input })));
@@ -2938,7 +2960,7 @@
2938
2960
 
2939
2961
  const feedbackById = async (id, convertToPng = false) => {
2940
2962
  const response = await doRequest(`/feedback/file?id=${encodeURIComponent(id)}&convertToPngFlg=${convertToPng}`, 'GET');
2941
- return await response.blob();
2963
+ return response ? await response.blob() : new Blob();
2942
2964
  };
2943
2965
 
2944
2966
  const getDocument = async (id, convertToPng = false) => {
@@ -3190,13 +3212,27 @@
3190
3212
  return (jsx(InputControl, { ...getValidation(field('partnerComments'), validatorObj.partnerComments, required), placeholder: "\u0423\u043A\u0430\u0436\u0438\u0442\u0435 \u0438\u043D\u0442\u0435\u0440\u0435\u0441\u0443\u044E\u0449\u0438\u0439 \u0432\u0430\u0441 \u0432\u043E\u043F\u0440\u043E\u0441", isTextarea: true, ...rest }));
3191
3213
  });
3192
3214
 
3193
- const PAYMENT_SYSTEM_TYPES = [
3194
- { id: 'mir', text: 'Карта МИР' },
3195
- { id: 'union_pay', text: 'UnionPay' },
3196
- ];
3215
+ const getPaymentSystems = async () => {
3216
+ const response = await doRequest('/public-data/creditProgramConditions', 'POST', {
3217
+ creditProgramId: 13,
3218
+ });
3219
+ const data = await response?.json();
3220
+ return data?.paymentSystems?.map((paymentSystem) => ({
3221
+ id: paymentSystem.type,
3222
+ text: paymentSystem.name,
3223
+ }));
3224
+ };
3225
+
3197
3226
  const PaymentSystemField = JSX(({ field, input }) => {
3198
3227
  const { value, onChange } = field('paymentSystem');
3199
- return (jsx(RadioButtonGroupControl, { label: "\u041F\u043B\u0430\u0442\u0435\u0436\u043D\u0430\u044F \u0441\u0438\u0441\u0442\u0435\u043C\u0430", orientation: "horizontal", items: PAYMENT_SYSTEM_TYPES, value: value, onChange: (_) => onChange?.(_), ...getValidation(field('paymentSystem'), validatorObj.paymentSystem, input?.required) }));
3228
+ const [paymentSystemOptions, setPaymentSystemOptions] = useState([]);
3229
+ useEffect(() => {
3230
+ (async () => {
3231
+ const fetchedPaymentSystems = await getPaymentSystems();
3232
+ setPaymentSystemOptions(fetchedPaymentSystems || []);
3233
+ })();
3234
+ }, []);
3235
+ return (jsx(RadioButtonGroupControl, { label: "\u041F\u043B\u0430\u0442\u0435\u0436\u043D\u0430\u044F \u0441\u0438\u0441\u0442\u0435\u043C\u0430", orientation: "horizontal", items: paymentSystemOptions, value: value, onChange: (_) => onChange?.(_), ...getValidation(field('paymentSystem'), validatorObj.paymentSystem, input?.required) }));
3200
3236
  });
3201
3237
 
3202
3238
  const isPlaceholder = (_) => _ === '_';
@@ -3702,13 +3738,16 @@
3702
3738
 
3703
3739
  const renderSubmitButton = (button, className) => (jsx(Button, { className: style('w-full @xl:w-auto', className), type: "submit", children: button?.text ? button.text : 'Отправить заявку' }));
3704
3740
 
3705
- const createDraftTask = (body) => doRequest('/user-data/createDraftTask', 'POST', body);
3741
+ const createDraftTask = async (body) => {
3742
+ const res = await fetchRetailJSON('/user-data/createDraftTask', 'POST', body);
3743
+ return res || {};
3744
+ };
3706
3745
 
3707
- const createUserProfile = (body) => doRequest('/public-data/createUserProfile', 'POST', body);
3746
+ const createUserProfile = (body) => fetchRetailJSON('/public-data/createUserProfile', 'POST', body).then((res) => res?.profile?.id || null);
3708
3747
 
3709
- const updateUserProfile = (body) => doRequest('/user-data/updateUserProfile', 'PUT', body);
3748
+ const updateUserProfile = (body) => fetchRetailJSON('/user-data/updateUserProfile', 'PUT', body);
3710
3749
 
3711
- const updateUserTask = (body) => doRequest('/user-data/updateUserTask', 'PUT', body);
3750
+ const updateUserTask = (body) => fetchRetailJSON('/user-data/updateUserTask', 'PUT', body);
3712
3751
 
3713
3752
  const getUpdateUserProfileData = (profileId, formData) => {
3714
3753
  const { name = '', surname = '', middleName = '', birthday = '', phone = '', email = '', processPersonalDataFlg, consentProviderFlg, consentPfrFlg, consentPhotoFlg, consentAssignmentClaimsFlg, consentCollectionFlg, consentInformFlg, } = formData;
@@ -3732,6 +3771,17 @@
3732
3771
  };
3733
3772
  };
3734
3773
 
3774
+ const sendCode = (body) => fetchRetailJSON('/sms/sendCode', 'POST', body).then((res) => !isErrorResult(res, body.phoneNumber));
3775
+ const isErrorResult = (res, phoneNumber) => Boolean(res) &&
3776
+ typeof res !== 'string' &&
3777
+ Boolean(res?.errorMessage.startsWith(`Too many request for phoneNumber [${phoneNumber}]`));
3778
+
3779
+ const checkCaptcha = (body) => doRequest('/sms/checkCaptcha', 'POST', body)
3780
+ .then((res) => res.text())
3781
+ .then((text) => text !== 'ERROR');
3782
+
3783
+ const createCaptcha = (phoneNumber) => doRequest(`/sms/createCaptcha?phoneNumber=${encodeURIComponent(phoneNumber)}`, 'GET').then(async (res) => (res ? await res.blob() : new Blob()));
3784
+
3735
3785
  const ICON_SIZE$1 = { width: '103', height: '21' };
3736
3786
 
3737
3787
  const logoTitleSizeStyle = 'text-s';
@@ -3762,34 +3812,25 @@
3762
3812
  ? children ?? (jsx("div", { className: "ml-s", children: jsx(Text, { font: "font-medium", color: TEXT_COLOR[bgColor], size: logoTitleSizeStyle, children: logo?.title ?? 'Россельхозбанк' }) }))
3763
3813
  : null] })));
3764
3814
 
3765
- const checkCaptcha = (body) => doRequest('/sms/checkCaptcha', 'POST', body);
3766
-
3767
- const handleCheckCaptcha = async ({ code, setHasError, close, sendCode = noop, }) => {
3768
- const response = await checkCaptcha({ captchaText: code });
3769
- if ((await response.text()) === 'ERROR') {
3770
- setHasError(true);
3771
- }
3772
- else {
3773
- sendCode();
3774
- close?.();
3775
- }
3776
- };
3777
-
3778
- const createCaptcha = (phoneNumber) => doRequest(`/sms/createCaptcha?phoneNumber=${encodeURIComponent(phoneNumber)}`, 'GET');
3779
-
3780
- const handleCreateCaptcha = async (setCaptcha, phoneNumber) => {
3781
- const response = await createCaptcha(phoneNumber);
3782
- setCaptcha(URL.createObjectURL(await response.blob()));
3783
- };
3784
-
3785
3815
  const CaptchaDialog = JSX(({ phoneNumber, close, sendCode, onClose }) => {
3786
3816
  const [captcha, setCaptcha] = useState('');
3787
3817
  const [code, setCode] = useState('');
3788
3818
  const [hasError, setHasError] = useState(false);
3789
- useEffect(() => {
3790
- handleCreateCaptcha(setCaptcha, phoneNumber);
3819
+ const handleCheckCaptcha = useCallback(async () => {
3820
+ const isValidCode = await checkCaptcha({ captchaText: code });
3821
+ if (isValidCode) {
3822
+ sendCode?.();
3823
+ close?.();
3824
+ }
3825
+ else {
3826
+ setHasError(isValidCode);
3827
+ }
3828
+ }, []);
3829
+ const handleCreateCaptcha = useCallback(() => {
3830
+ (async () => setCaptcha(URL.createObjectURL(await createCaptcha(phoneNumber))))();
3791
3831
  }, []);
3792
- return (jsx(Dialog, { head: jsx(Logo, {}), onClose: onClose, className: "my-6xl max-w-lg w-full min-h-fit mx-auto rounded-lg", children: jsxs("div", { className: "flex flex-col gap-lg items-center rounded-md", children: [jsxs("div", { className: "flex h-36 w-72", children: [jsx("img", { className: "grow", src: captcha }), jsx("div", { onClick: () => handleCreateCaptcha(setCaptcha, phoneNumber), className: "flex w-8 items-center justify-center cursor-pointer", children: jsx(Icon, { iconVersion: "normal", name: "RefreshIcon" }) })] }), jsx(Input, { className: "w-[300px]", onChange: setCode, value: code, placeholder: "\u0412\u0432\u0435\u0434\u0438\u0442\u0435 \u043A\u043E\u0434 \u0441 \u043A\u0430\u0440\u0442\u0438\u043D\u043A\u0438" }), hasError ? jsx("div", { className: "text-error", children: "\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u043A\u043E\u0434" }) : null, jsxs("div", { className: "flex w-[310px] justify-between", children: [jsx(Button, { onClick: close, version: "secondary", children: "\u0412\u0435\u0440\u043D\u0443\u0442\u044C\u0441\u044F" }), jsx(Button, { type: "submit", disabled: !code, onClick: () => handleCheckCaptcha({ code, setHasError, close, sendCode }), version: "secondary", children: "\u041E\u0442\u043F\u0440\u0430\u0432\u0438\u0442\u044C" })] })] }) }));
3832
+ useEffect(handleCreateCaptcha, []);
3833
+ return (jsx(Dialog, { head: jsx(Logo, {}), onClose: onClose, className: "my-6xl max-w-lg w-full min-h-fit mx-auto rounded-lg", children: jsxs("div", { className: "flex flex-col gap-lg items-center rounded-md", children: [jsxs("div", { className: "flex h-36 w-72", children: [jsx("img", { className: "grow", src: captcha }), jsx("div", { onClick: handleCreateCaptcha, className: "flex w-8 items-center justify-center cursor-pointer", children: jsx(Icon, { iconVersion: "normal", name: "RefreshIcon" }) })] }), jsx(Input, { className: "w-[300px]", onChange: setCode, value: code, placeholder: "\u0412\u0432\u0435\u0434\u0438\u0442\u0435 \u043A\u043E\u0434 \u0441 \u043A\u0430\u0440\u0442\u0438\u043D\u043A\u0438" }), hasError ? jsx("div", { className: "text-error", children: "\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u043A\u043E\u0434" }) : null, jsxs("div", { className: "flex w-[310px] justify-between", children: [jsx(Button, { onClick: close, version: "secondary", children: "\u0412\u0435\u0440\u043D\u0443\u0442\u044C\u0441\u044F" }), jsx(Button, { type: "submit", disabled: !code, onClick: handleCheckCaptcha, version: "secondary", children: "\u041E\u0442\u043F\u0440\u0430\u0432\u0438\u0442\u044C" })] })] }) }));
3793
3834
  });
3794
3835
 
3795
3836
  const useCaptchaDialog = (initialProps, onClose) => {
@@ -3821,29 +3862,6 @@
3821
3862
  return `${minutes}:${seconds}`;
3822
3863
  };
3823
3864
 
3824
- const sendCode = (body) => doRequest('/sms/sendCode', 'POST', body);
3825
-
3826
- const handleSendCode = async ({ phoneNumber, captchaDialog, setTimeNextReq, setIsTimerStarted, setAttemps, }) => {
3827
- try {
3828
- await sendCode({
3829
- phoneNumber: phoneNumber,
3830
- smsCodesSetName: { key: 'AUTHENTICATION' },
3831
- }).then((res) => {
3832
- if (typeof res !== 'string' &&
3833
- res.errorMessage &&
3834
- res.errorMessage.startsWith(`Too many request for phoneNumber [${phoneNumber}]`)) {
3835
- throw res;
3836
- }
3837
- });
3838
- setAttemps(0);
3839
- setTimeNextReq(180);
3840
- setIsTimerStarted(true);
3841
- }
3842
- catch (e) {
3843
- captchaDialog.open();
3844
- }
3845
- };
3846
-
3847
3865
  const InputCode = JSX(({ values, setValues, hasError, errorText }) => {
3848
3866
  const [activeIndex, setActiveIndex] = useState(0);
3849
3867
  const inputRefs = useRef([]);
@@ -3888,10 +3906,12 @@
3888
3906
  return (jsx(Button, { type: "button", onClick: onClick, disabled: isDisabled, children: jsx(Text, { font: "font-normal", children: text }) }));
3889
3907
  });
3890
3908
 
3891
- const checkCode = async (body) => doRequest('/sms/checkCode', 'POST', body).then(saveToken);
3909
+ const checkCode = async (body) => fetchRetailJSON('/sms/checkCode', 'POST', body).then(saveToken);
3892
3910
  const saveToken = (data) => {
3893
- globalThis.sessionStorage.setItem('accessToken', data.access_token);
3894
- globalThis.sessionStorage.setItem('refreshToken', data.refresh_token);
3911
+ if (data) {
3912
+ globalThis.sessionStorage.setItem('accessToken', data.access_token);
3913
+ globalThis.sessionStorage.setItem('refreshToken', data.refresh_token);
3914
+ }
3895
3915
  };
3896
3916
 
3897
3917
  const useVerifyPhoneDialogSubmit = ({ close, values }) => {
@@ -3951,23 +3971,28 @@
3951
3971
  const VerifyPhoneDialog = JSX(({ close = noop, onClose = noop, title, description, __html, code = true, codeLength = 4, textButton = '', phoneNumber = '+79999999999', }) => {
3952
3972
  const [values, setValues] = useState(Array(codeLength).fill(''));
3953
3973
  const { handleSubmit, hasError, errorText, isLoading, timeNextReq, isSubmitButtonDisabled, setTimeNextReq, setIsTimerStarted, setAttemps, } = useVerifyPhoneDialogSubmit({ values, close });
3954
- const sendCode = useCallback(() => {
3955
- handleSendCode({
3956
- phoneNumber,
3957
- captchaDialog,
3958
- setTimeNextReq,
3959
- setIsTimerStarted,
3960
- setAttemps,
3974
+ const handleSendCode = useCallback(async () => {
3975
+ const isSuccessSendCode = await sendCode({
3976
+ phoneNumber: phoneNumber,
3977
+ smsCodesSetName: { key: 'AUTHENTICATION' },
3961
3978
  });
3979
+ if (isSuccessSendCode) {
3980
+ setAttemps(0);
3981
+ setTimeNextReq(180);
3982
+ setIsTimerStarted(true);
3983
+ }
3984
+ else {
3985
+ captchaDialog.open();
3986
+ }
3962
3987
  }, []);
3963
- const captchaDialog = useCaptchaDialog({ phoneNumber, sendCode }, onClose);
3988
+ const captchaDialog = useCaptchaDialog({ phoneNumber, sendCode: handleSendCode }, onClose);
3964
3989
  useEffect(() => {
3965
- sendCode();
3990
+ handleSendCode();
3966
3991
  }, []);
3967
- return (jsx(Dialog, { className: "my-6xl max-w-3xl w-full min-h-fit mx-auto rounded-xl px-5xl py-0", children: jsxs("div", { className: "flex flex-col gap-xl items-center rounded-md", children: [jsx(Headline, { className: "w-full", title: title, description: description, headlineVersion: "XS", isEmbedded: true, as: "h6" }), code ? (jsx(InputCode, { values: values, setValues: setValues, errorText: errorText, hasError: hasError })) : null, renderText$2(timeNextReq, setTimeNextReq, sendCode), jsx(RichText, { itemSize: "list-s", __html: __html }), renderTextButton(textButton, isSubmitButtonDisabled, handleSubmit), isLoading ? jsx(Loader, { blur: false }) : null] }) }));
3992
+ return (jsx(Dialog, { className: "my-6xl max-w-3xl w-full min-h-fit mx-auto rounded-xl px-5xl py-0", children: jsxs("div", { className: "flex flex-col gap-xl items-center rounded-md", children: [jsx(Headline, { className: "w-full", title: title, description: description, headlineVersion: "XS", isEmbedded: true, as: "h6" }), code ? (jsx(InputCode, { values: values, setValues: setValues, errorText: errorText, hasError: hasError })) : null, renderText$2(timeNextReq, setTimeNextReq, handleSendCode), jsx(RichText, { itemSize: "list-s", __html: __html }), renderTextButton(textButton, isSubmitButtonDisabled, handleSubmit), isLoading ? jsx(Loader, { blur: false }) : null] }) }));
3968
3993
  });
3969
3994
  const renderTextButton = (textButton, isDisabled, handleSubmit) => textButton ? (jsx(SubmitButton, { isDisabled: isDisabled, onClick: handleSubmit, text: textButton })) : null;
3970
- const renderText$2 = (timeNextReq, setTimeNextReq, sendCode) => timeNextReq ? (jsxs("div", { className: "flex flex-row text-l font-light text-base", children: ["\u041F\u043E\u043B\u0443\u0447\u0438\u0442\u044C \u043D\u043E\u0432\u044B\u0439 \u043A\u043E\u0434 \u043C\u043E\u0436\u043D\u043E \u0447\u0435\u0440\u0435\u0437", jsx(Timer, { className: "text-base ml-1", time: timeNextReq, setTime: setTimeNextReq })] })) : (jsx(LinkButton, { onClick: sendCode, className: "text-primary-main", children: "\u041F\u043E\u043B\u0443\u0447\u0438\u0442\u044C \u043D\u043E\u0432\u044B\u0439 \u043A\u043E\u0434" }));
3995
+ const renderText$2 = (timeNextReq, setTimeNextReq, handleSendCode) => timeNextReq ? (jsxs("div", { className: "flex flex-row text-l font-light text-base", children: ["\u041F\u043E\u043B\u0443\u0447\u0438\u0442\u044C \u043D\u043E\u0432\u044B\u0439 \u043A\u043E\u0434 \u043C\u043E\u0436\u043D\u043E \u0447\u0435\u0440\u0435\u0437", jsx(Timer, { className: "text-base ml-1", time: timeNextReq, setTime: setTimeNextReq })] })) : (jsx(LinkButton, { onClick: handleSendCode, className: "text-primary-main", children: "\u041F\u043E\u043B\u0443\u0447\u0438\u0442\u044C \u043D\u043E\u0432\u044B\u0439 \u043A\u043E\u0434" }));
3971
3996
 
3972
3997
  const useVerifyPhoneDialog = () => {
3973
3998
  const { open, close } = useDialogManager();
@@ -4046,7 +4071,7 @@
4046
4071
  <ul><li>согласие на запрос информации в БКИ</li></ul>`,
4047
4072
  });
4048
4073
 
4049
- const getLink = (body) => doRequest('/esia/getLink', 'POST', body);
4074
+ const getLink = (body) => fetchRetailJSON('/esia/getLink', 'POST', body);
4050
4075
 
4051
4076
  const EsiaLoginDialog = JSX(function ({ handleClose }) {
4052
4077
  const handleAuth = useCallback(async () => {
@@ -4190,7 +4215,7 @@
4190
4215
  return console.warn('validation fail');
4191
4216
  }
4192
4217
  try {
4193
- const { profile: { id: profileId }, } = await createUserProfile({
4218
+ const profileId = await createUserProfile({
4194
4219
  profile: { phone: formatPhone(formData.phone) },
4195
4220
  });
4196
4221
  if (profileId && formData?.phone) {
@@ -4259,7 +4284,7 @@
4259
4284
  };
4260
4285
  };
4261
4286
 
4262
- const updateProfileEsia = (body) => doRequest('/esia/updateProfileEsia', 'POST', body);
4287
+ const updateProfileEsia = (body) => fetchRetailJSON('/esia/updateProfileEsia', 'POST', body);
4263
4288
 
4264
4289
  const parseEsiaProfile = (esiaProfile) => {
4265
4290
  const { profile, addInfo, document, addressRegistration, addressFact } = esiaProfile;
@@ -4325,10 +4350,11 @@
4325
4350
  state,
4326
4351
  redirectUri: globalThis.location?.href,
4327
4352
  });
4328
- setLeadForm({
4329
- ...leadForm,
4330
- ...parseEsiaProfile(data),
4331
- });
4353
+ data &&
4354
+ setLeadForm({
4355
+ ...leadForm,
4356
+ ...parseEsiaProfile(data),
4357
+ });
4332
4358
  globalThis.location.href = nextStepLink;
4333
4359
  }
4334
4360
  }, []);
@@ -6000,12 +6026,12 @@
6000
6026
  // eslint-disable-next-line camelcase
6001
6027
  access_token: accessToken,
6002
6028
  });
6003
- if (res instanceof Response) {
6029
+ if (res) {
6004
6030
  handleStatus(res.status);
6005
- return;
6031
+ const data = await res.json();
6032
+ globalThis.sessionStorage.setItem('refreshToken', data.refresh_token);
6033
+ globalThis.sessionStorage.setItem('accessToken', data.access_token);
6006
6034
  }
6007
- globalThis.sessionStorage.setItem('refreshToken', res.refresh_token);
6008
- globalThis.sessionStorage.setItem('accessToken', res.access_token);
6009
6035
  };
6010
6036
  updateTokenRequest();
6011
6037
  const timer = setInterval(updateTokenRequest, UPDATING_INTERVAL);
@@ -6031,7 +6057,7 @@
6031
6057
  STATUS_TYPE["fail"] = "CANCELLED";
6032
6058
  STATUS_TYPE["rework"] = "REVISION";
6033
6059
  })(STATUS_TYPE || (STATUS_TYPE = {}));
6034
- const getTaskStatus = (body) => doRequest('/user-data/getTaskStatus', 'POST', body);
6060
+ const getTaskStatus = (body) => fetchRetailJSON('/user-data/getTaskStatus', 'POST', body);
6035
6061
 
6036
6062
  const sendSignalToProcess = (body) => doRequest('/user-data/sendSignalToProcess', 'POST', body);
6037
6063
 
@@ -6137,12 +6163,13 @@
6137
6163
  await sendSignalToProcess({ signalType, taskId });
6138
6164
  }
6139
6165
  })();
6140
- const trackStatus = () => getTaskStatus({ taskId }).then((res) => {
6141
- if (res.statusCd && res.statusCd !== STATUS_TYPE.process) {
6166
+ const trackStatus = useCallback(async () => {
6167
+ const res = await getTaskStatus({ taskId });
6168
+ if (res && res?.statusCd !== STATUS_TYPE.process) {
6142
6169
  clearInterval(pullingInterval);
6143
6170
  setStatus(res.statusCd);
6144
6171
  }
6145
- });
6172
+ }, []);
6146
6173
  const pullingInterval = setInterval(trackStatus, 30000);
6147
6174
  }, []);
6148
6175
  return renderStatus$1(status);
@@ -6159,7 +6186,7 @@
6159
6186
 
6160
6187
  const formStateMap$1 = [
6161
6188
  {
6162
- paymentSystem: PAYMENT_SYSTEM_TYPES[0].id,
6189
+ paymentSystem: '',
6163
6190
  currency: 'rub',
6164
6191
  codeWord: '',
6165
6192
  },
@@ -7015,7 +7042,7 @@
7015
7042
  })();
7016
7043
  const trackStatus = () => taskId &&
7017
7044
  getTaskStatus({ taskId }).then((res) => {
7018
- if (res.statusCd && res.statusCd !== STATUS_TYPE.process) {
7045
+ if (res?.statusCd && res.statusCd !== STATUS_TYPE.process) {
7019
7046
  clearInterval(pullingInterval);
7020
7047
  setStatus(res.statusCd);
7021
7048
  }
@@ -9599,7 +9626,7 @@
9599
9626
  slots: () => [HEADER_SLOT, FOOTER_SLOT, STICKY_FOOTER_SLOT],
9600
9627
  });
9601
9628
 
9602
- const packageVersion = "0.14.669";
9629
+ const packageVersion = "0.14.671";
9603
9630
 
9604
9631
  exports.Blocks = Blocks;
9605
9632
  exports.ContentPage = ContentPage;