@redneckz/wildless-cms-uni-blocks 0.14.884 → 0.14.885

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 (197) hide show
  1. package/bundle/bundle.umd.js +212 -56
  2. package/bundle/bundle.umd.min.js +1 -1
  3. package/bundle/components/ApplicationLeadForm/EsiaLoginBanner.d.ts +2 -1
  4. package/bundle/components/DebitForm/DebitFormStepsData.d.ts +1 -0
  5. package/bundle/components/DebitForm/utils.d.ts +2 -0
  6. package/bundle/retail/components/DraftDialog/EmptyDraftDialog.d.ts +4 -1
  7. package/bundle/retail/components/DraftDialog/creditProgramCodes.d.ts +39 -0
  8. package/bundle/retail/components/DraftDialog/utils.d.ts +5 -34
  9. package/bundle/retail/model/LeadFormState.d.ts +0 -1
  10. package/dist/components/ApplicationLeadForm/ApplicationLeadForm.js +1 -1
  11. package/dist/components/ApplicationLeadForm/ApplicationLeadForm.js.map +1 -1
  12. package/dist/components/ApplicationLeadForm/EsiaLoginBanner.d.ts +2 -1
  13. package/dist/components/ApplicationLeadForm/EsiaLoginBanner.js +2 -2
  14. package/dist/components/ApplicationLeadForm/EsiaLoginBanner.js.map +1 -1
  15. package/dist/components/ApplicationLeadForm/consents.js +0 -4
  16. package/dist/components/ApplicationLeadForm/consents.js.map +1 -1
  17. package/dist/components/DebitForm/DebitForm.js +5 -1
  18. package/dist/components/DebitForm/DebitForm.js.map +1 -1
  19. package/dist/components/DebitForm/DebitFormStepsData.d.ts +1 -0
  20. package/dist/components/DebitForm/DebitFormStepsData.js +122 -6
  21. package/dist/components/DebitForm/DebitFormStepsData.js.map +1 -1
  22. package/dist/components/DebitForm/formStateMap.js +1 -0
  23. package/dist/components/DebitForm/formStateMap.js.map +1 -1
  24. package/dist/components/DebitForm/utils.d.ts +2 -0
  25. package/dist/components/DebitForm/utils.js +2 -0
  26. package/dist/components/DebitForm/utils.js.map +1 -1
  27. package/dist/retail/adaptors/getPersonalInfoData.js +4 -1
  28. package/dist/retail/adaptors/getPersonalInfoData.js.map +1 -1
  29. package/dist/retail/components/DraftDialog/DraftDialog.js +7 -14
  30. package/dist/retail/components/DraftDialog/DraftDialog.js.map +1 -1
  31. package/dist/retail/components/DraftDialog/EmptyDraftDialog.d.ts +4 -1
  32. package/dist/retail/components/DraftDialog/EmptyDraftDialog.js +4 -2
  33. package/dist/retail/components/DraftDialog/EmptyDraftDialog.js.map +1 -1
  34. package/dist/retail/components/DraftDialog/creditProgramCodes.d.ts +39 -0
  35. package/dist/retail/components/DraftDialog/creditProgramCodes.js +39 -0
  36. package/dist/retail/components/DraftDialog/creditProgramCodes.js.map +1 -0
  37. package/dist/retail/components/DraftDialog/useDraftDialog.js +1 -1
  38. package/dist/retail/components/DraftDialog/useDraftDialog.js.map +1 -1
  39. package/dist/retail/components/DraftDialog/utils.d.ts +5 -34
  40. package/dist/retail/components/DraftDialog/utils.js +23 -24
  41. package/dist/retail/components/DraftDialog/utils.js.map +1 -1
  42. package/dist/retail/components/Fields/CardCategoryField.js +8 -2
  43. package/dist/retail/components/Fields/CardCategoryField.js.map +1 -1
  44. package/dist/retail/model/LeadFormState.d.ts +0 -1
  45. package/dist/ui-kit/FormField/getObjectValidator.js +1 -1
  46. package/lib/common.css +1 -1
  47. package/lib/components/ApplicationLeadForm/ApplicationLeadForm.js +1 -1
  48. package/lib/components/ApplicationLeadForm/ApplicationLeadForm.js.map +1 -1
  49. package/lib/components/ApplicationLeadForm/EsiaLoginBanner.d.ts +2 -1
  50. package/lib/components/ApplicationLeadForm/EsiaLoginBanner.js +2 -2
  51. package/lib/components/ApplicationLeadForm/EsiaLoginBanner.js.map +1 -1
  52. package/lib/components/ApplicationLeadForm/consents.js +0 -4
  53. package/lib/components/ApplicationLeadForm/consents.js.map +1 -1
  54. package/lib/components/DebitForm/DebitForm.js +5 -1
  55. package/lib/components/DebitForm/DebitForm.js.map +1 -1
  56. package/lib/components/DebitForm/DebitFormStepsData.d.ts +1 -0
  57. package/lib/components/DebitForm/DebitFormStepsData.js +122 -6
  58. package/lib/components/DebitForm/DebitFormStepsData.js.map +1 -1
  59. package/lib/components/DebitForm/formStateMap.js +1 -0
  60. package/lib/components/DebitForm/formStateMap.js.map +1 -1
  61. package/lib/components/DebitForm/utils.d.ts +2 -0
  62. package/lib/components/DebitForm/utils.js +2 -0
  63. package/lib/components/DebitForm/utils.js.map +1 -1
  64. package/lib/retail/adaptors/getPersonalInfoData.js +4 -1
  65. package/lib/retail/adaptors/getPersonalInfoData.js.map +1 -1
  66. package/lib/retail/components/DraftDialog/DraftDialog.js +6 -13
  67. package/lib/retail/components/DraftDialog/DraftDialog.js.map +1 -1
  68. package/lib/retail/components/DraftDialog/EmptyDraftDialog.d.ts +4 -1
  69. package/lib/retail/components/DraftDialog/EmptyDraftDialog.js +4 -2
  70. package/lib/retail/components/DraftDialog/EmptyDraftDialog.js.map +1 -1
  71. package/lib/retail/components/DraftDialog/creditProgramCodes.d.ts +39 -0
  72. package/lib/retail/components/DraftDialog/creditProgramCodes.js +37 -0
  73. package/lib/retail/components/DraftDialog/creditProgramCodes.js.map +1 -0
  74. package/lib/retail/components/DraftDialog/useDraftDialog.js +1 -1
  75. package/lib/retail/components/DraftDialog/useDraftDialog.js.map +1 -1
  76. package/lib/retail/components/DraftDialog/utils.d.ts +5 -34
  77. package/lib/retail/components/DraftDialog/utils.js +21 -23
  78. package/lib/retail/components/DraftDialog/utils.js.map +1 -1
  79. package/lib/retail/components/Fields/CardCategoryField.js +9 -3
  80. package/lib/retail/components/Fields/CardCategoryField.js.map +1 -1
  81. package/lib/retail/model/LeadFormState.d.ts +0 -1
  82. package/lib/ui-kit/FormField/getObjectValidator.js +1 -1
  83. package/mobile/bundle/bundle.umd.js +212 -56
  84. package/mobile/bundle/bundle.umd.min.js +1 -1
  85. package/mobile/bundle/components/ApplicationLeadForm/EsiaLoginBanner.d.ts +2 -1
  86. package/mobile/bundle/components/DebitForm/DebitFormStepsData.d.ts +1 -0
  87. package/mobile/bundle/components/DebitForm/utils.d.ts +2 -0
  88. package/mobile/bundle/retail/components/DraftDialog/EmptyDraftDialog.d.ts +4 -1
  89. package/mobile/bundle/retail/components/DraftDialog/creditProgramCodes.d.ts +39 -0
  90. package/mobile/bundle/retail/components/DraftDialog/utils.d.ts +5 -34
  91. package/mobile/bundle/retail/model/LeadFormState.d.ts +0 -1
  92. package/mobile/dist/components/ApplicationLeadForm/ApplicationLeadForm.js +1 -1
  93. package/mobile/dist/components/ApplicationLeadForm/ApplicationLeadForm.js.map +1 -1
  94. package/mobile/dist/components/ApplicationLeadForm/EsiaLoginBanner.d.ts +2 -1
  95. package/mobile/dist/components/ApplicationLeadForm/EsiaLoginBanner.js +2 -2
  96. package/mobile/dist/components/ApplicationLeadForm/EsiaLoginBanner.js.map +1 -1
  97. package/mobile/dist/components/ApplicationLeadForm/consents.js +0 -4
  98. package/mobile/dist/components/ApplicationLeadForm/consents.js.map +1 -1
  99. package/mobile/dist/components/DebitForm/DebitForm.js +5 -1
  100. package/mobile/dist/components/DebitForm/DebitForm.js.map +1 -1
  101. package/mobile/dist/components/DebitForm/DebitFormStepsData.d.ts +1 -0
  102. package/mobile/dist/components/DebitForm/DebitFormStepsData.js +122 -6
  103. package/mobile/dist/components/DebitForm/DebitFormStepsData.js.map +1 -1
  104. package/mobile/dist/components/DebitForm/formStateMap.js +1 -0
  105. package/mobile/dist/components/DebitForm/formStateMap.js.map +1 -1
  106. package/mobile/dist/components/DebitForm/utils.d.ts +2 -0
  107. package/mobile/dist/components/DebitForm/utils.js +2 -0
  108. package/mobile/dist/components/DebitForm/utils.js.map +1 -1
  109. package/mobile/dist/retail/adaptors/getPersonalInfoData.js +4 -1
  110. package/mobile/dist/retail/adaptors/getPersonalInfoData.js.map +1 -1
  111. package/mobile/dist/retail/components/DraftDialog/DraftDialog.js +7 -14
  112. package/mobile/dist/retail/components/DraftDialog/DraftDialog.js.map +1 -1
  113. package/mobile/dist/retail/components/DraftDialog/EmptyDraftDialog.d.ts +4 -1
  114. package/mobile/dist/retail/components/DraftDialog/EmptyDraftDialog.js +4 -2
  115. package/mobile/dist/retail/components/DraftDialog/EmptyDraftDialog.js.map +1 -1
  116. package/mobile/dist/retail/components/DraftDialog/creditProgramCodes.d.ts +39 -0
  117. package/mobile/dist/retail/components/DraftDialog/creditProgramCodes.js +39 -0
  118. package/mobile/dist/retail/components/DraftDialog/creditProgramCodes.js.map +1 -0
  119. package/mobile/dist/retail/components/DraftDialog/useDraftDialog.js +1 -1
  120. package/mobile/dist/retail/components/DraftDialog/useDraftDialog.js.map +1 -1
  121. package/mobile/dist/retail/components/DraftDialog/utils.d.ts +5 -34
  122. package/mobile/dist/retail/components/DraftDialog/utils.js +23 -24
  123. package/mobile/dist/retail/components/DraftDialog/utils.js.map +1 -1
  124. package/mobile/dist/retail/components/Fields/CardCategoryField.js +8 -2
  125. package/mobile/dist/retail/components/Fields/CardCategoryField.js.map +1 -1
  126. package/mobile/dist/retail/model/LeadFormState.d.ts +0 -1
  127. package/mobile/dist/ui-kit/FormField/getObjectValidator.js +1 -1
  128. package/mobile/lib/common.css +1 -1
  129. package/mobile/lib/components/ApplicationLeadForm/ApplicationLeadForm.js +1 -1
  130. package/mobile/lib/components/ApplicationLeadForm/ApplicationLeadForm.js.map +1 -1
  131. package/mobile/lib/components/ApplicationLeadForm/EsiaLoginBanner.d.ts +2 -1
  132. package/mobile/lib/components/ApplicationLeadForm/EsiaLoginBanner.js +2 -2
  133. package/mobile/lib/components/ApplicationLeadForm/EsiaLoginBanner.js.map +1 -1
  134. package/mobile/lib/components/ApplicationLeadForm/consents.js +0 -4
  135. package/mobile/lib/components/ApplicationLeadForm/consents.js.map +1 -1
  136. package/mobile/lib/components/DebitForm/DebitForm.js +5 -1
  137. package/mobile/lib/components/DebitForm/DebitForm.js.map +1 -1
  138. package/mobile/lib/components/DebitForm/DebitFormStepsData.d.ts +1 -0
  139. package/mobile/lib/components/DebitForm/DebitFormStepsData.js +122 -6
  140. package/mobile/lib/components/DebitForm/DebitFormStepsData.js.map +1 -1
  141. package/mobile/lib/components/DebitForm/formStateMap.js +1 -0
  142. package/mobile/lib/components/DebitForm/formStateMap.js.map +1 -1
  143. package/mobile/lib/components/DebitForm/utils.d.ts +2 -0
  144. package/mobile/lib/components/DebitForm/utils.js +2 -0
  145. package/mobile/lib/components/DebitForm/utils.js.map +1 -1
  146. package/mobile/lib/retail/adaptors/getPersonalInfoData.js +4 -1
  147. package/mobile/lib/retail/adaptors/getPersonalInfoData.js.map +1 -1
  148. package/mobile/lib/retail/components/DraftDialog/DraftDialog.js +6 -13
  149. package/mobile/lib/retail/components/DraftDialog/DraftDialog.js.map +1 -1
  150. package/mobile/lib/retail/components/DraftDialog/EmptyDraftDialog.d.ts +4 -1
  151. package/mobile/lib/retail/components/DraftDialog/EmptyDraftDialog.js +4 -2
  152. package/mobile/lib/retail/components/DraftDialog/EmptyDraftDialog.js.map +1 -1
  153. package/mobile/lib/retail/components/DraftDialog/creditProgramCodes.d.ts +39 -0
  154. package/mobile/lib/retail/components/DraftDialog/creditProgramCodes.js +37 -0
  155. package/mobile/lib/retail/components/DraftDialog/creditProgramCodes.js.map +1 -0
  156. package/mobile/lib/retail/components/DraftDialog/useDraftDialog.js +1 -1
  157. package/mobile/lib/retail/components/DraftDialog/useDraftDialog.js.map +1 -1
  158. package/mobile/lib/retail/components/DraftDialog/utils.d.ts +5 -34
  159. package/mobile/lib/retail/components/DraftDialog/utils.js +21 -23
  160. package/mobile/lib/retail/components/DraftDialog/utils.js.map +1 -1
  161. package/mobile/lib/retail/components/Fields/CardCategoryField.js +9 -3
  162. package/mobile/lib/retail/components/Fields/CardCategoryField.js.map +1 -1
  163. package/mobile/lib/retail/model/LeadFormState.d.ts +0 -1
  164. package/mobile/lib/ui-kit/FormField/getObjectValidator.js +1 -1
  165. package/mobile/src/components/ApplicationLeadForm/ApplicationLeadForm.tsx +3 -1
  166. package/mobile/src/components/ApplicationLeadForm/EsiaLoginBanner.tsx +16 -11
  167. package/mobile/src/components/ApplicationLeadForm/consents.ts +0 -4
  168. package/mobile/src/components/DebitForm/DebitForm.tsx +6 -1
  169. package/mobile/src/components/DebitForm/DebitFormStepsData.tsx +123 -6
  170. package/mobile/src/components/DebitForm/formStateMap.tsx +1 -0
  171. package/mobile/src/components/DebitForm/utils.ts +2 -0
  172. package/mobile/src/retail/adaptors/getPersonalInfoData.tsx +4 -1
  173. package/mobile/src/retail/components/DraftDialog/DraftDialog.tsx +6 -13
  174. package/mobile/src/retail/components/DraftDialog/EmptyDraftDialog.tsx +8 -2
  175. package/mobile/src/retail/components/DraftDialog/creditProgramCodes.ts +40 -0
  176. package/mobile/src/retail/components/DraftDialog/useDraftDialog.tsx +1 -1
  177. package/mobile/src/retail/components/DraftDialog/utils.ts +22 -27
  178. package/mobile/src/retail/components/Fields/CardCategoryField.tsx +14 -3
  179. package/mobile/src/retail/model/LeadFormState.ts +0 -1
  180. package/mobile/src/ui-kit/FormField/getObjectValidator.tsx +1 -1
  181. package/package.json +1 -1
  182. package/src/components/ApplicationLeadForm/ApplicationLeadForm.tsx +3 -1
  183. package/src/components/ApplicationLeadForm/EsiaLoginBanner.tsx +16 -11
  184. package/src/components/ApplicationLeadForm/consents.ts +0 -4
  185. package/src/components/DebitForm/DebitForm.tsx +6 -1
  186. package/src/components/DebitForm/DebitFormStepsData.tsx +123 -6
  187. package/src/components/DebitForm/formStateMap.tsx +1 -0
  188. package/src/components/DebitForm/utils.ts +2 -0
  189. package/src/retail/adaptors/getPersonalInfoData.tsx +4 -1
  190. package/src/retail/components/DraftDialog/DraftDialog.tsx +6 -13
  191. package/src/retail/components/DraftDialog/EmptyDraftDialog.tsx +8 -2
  192. package/src/retail/components/DraftDialog/creditProgramCodes.ts +40 -0
  193. package/src/retail/components/DraftDialog/useDraftDialog.tsx +1 -1
  194. package/src/retail/components/DraftDialog/utils.ts +22 -27
  195. package/src/retail/components/Fields/CardCategoryField.tsx +14 -3
  196. package/src/retail/model/LeadFormState.ts +0 -1
  197. package/src/ui-kit/FormField/getObjectValidator.tsx +1 -1
@@ -2294,7 +2294,7 @@
2294
2294
  };
2295
2295
  const byNonEmptyValidator = (validator = {}) => ({ name }) => Boolean(validator[name ?? '']);
2296
2296
  const byCondition = (formState) => (fieldDef) => !fieldDef?.condition ||
2297
- fieldDef.condition.values.find((_) => {
2297
+ fieldDef.condition.values.some((_) => {
2298
2298
  const dependencyValue = formState?.[fieldDef?.condition?.name ?? ''];
2299
2299
  return _ === (dependencyValue?.key ?? dependencyValue);
2300
2300
  });
@@ -2821,10 +2821,6 @@
2821
2821
  text: 'Согласие на информирование о продуктах и услугах Банка',
2822
2822
  docId: 14,
2823
2823
  },
2824
- consentProviderFlg: {
2825
- text: 'Согласие об использовании простой электронной подписи',
2826
- docId: 5,
2827
- },
2828
2824
  consentOthersFlg: {
2829
2825
  text: 'Прочие согласия',
2830
2826
  docId: 20,
@@ -2914,7 +2910,7 @@
2914
2910
 
2915
2911
  const getLink = (body) => fetchRetailJSON('/esia/getLink', 'POST', body);
2916
2912
 
2917
- const EsiaLoginBanner = JSX(({ onChangeEsiaStatus }) => {
2913
+ const EsiaLoginBanner = JSX(({ onChangeEsiaStatus, productType }) => {
2918
2914
  const navigator = locationNavigator();
2919
2915
  const handleAuth = useCallback(async () => {
2920
2916
  try {
@@ -2929,7 +2925,7 @@
2929
2925
  onChangeEsiaStatus(EsiaStatuses.Error);
2930
2926
  }
2931
2927
  }, []);
2932
- return (jsxs("div", { className: "flex gap-lg items-center rounded-md bg-main-gray p-4xl", children: [jsxs("div", { className: "flex flex-col justify-around w-full", children: [jsx("p", { className: "mb-m text-xl", children: "\u0417\u0430\u043F\u043E\u043B\u043D\u0438\u0442\u0435 \u0434\u0430\u043D\u043D\u044B\u0435 \u0447\u0435\u0440\u0435\u0437 \u0413\u043E\u0441\u0443\u0441\u043B\u0443\u0433\u0438" }), jsxs("ul", { className: "list-disc list-inside mb-4xl", children: [jsx("li", { children: "\u0412\u0435\u0440\u043E\u044F\u0442\u043D\u043E\u0441\u0442\u044C \u043E\u0434\u043E\u0431\u0440\u0435\u043D\u0438\u044F \u0432\u044B\u0448\u0435" }), jsx("li", { children: "\u0411\u0435\u0437 \u0441\u043F\u0440\u0430\u0432\u043E\u043A \u043E \u0434\u043E\u0445\u043E\u0434\u0430\u0445 \u0438 \u0442\u0440\u0443\u0434\u043E\u0443\u0441\u0442\u0440\u043E\u0439\u0441\u0442\u0432\u0435" }), jsx("li", { children: "\u0421 \u0437\u0430\u0449\u0438\u0442\u043E\u0439 \u0412\u0430\u0448\u0438\u0445 \u0434\u0430\u043D\u043D\u044B\u0445" })] }), jsx(Img, { className: "block mb-xl self-center @md:hidden", image: { icon: 'GosUslugiIcon', iconVersion: 'normal' }, height: "80", width: "80" }), jsx(Button, { type: "button", onClick: handleAuth, className: "w-full @md:w-fit", children: "\u0417\u0430\u043F\u043E\u043B\u043D\u0438\u0442\u044C" })] }), jsx(Img, { className: "hidden @md:block", image: { icon: 'GosUslugiIcon', iconVersion: 'normal' }, height: "164" })] }));
2928
+ return (jsxs("div", { className: "flex items-center rounded-md bg-main-gray p-4xl", children: [jsxs("div", { className: "flex gap-m flex-col justify-around w-full", children: [jsx("p", { className: "text-xl", children: `Заполните данные через Госуслуги${productType === 'debitCard' ? ' - это значительно сократит время оформления заявки' : ''}` }), productType === 'debitCard' ? null : (jsxs("ul", { className: "list-disc list-inside", children: [jsx("li", { children: "\u0412\u0435\u0440\u043E\u044F\u0442\u043D\u043E\u0441\u0442\u044C \u043E\u0434\u043E\u0431\u0440\u0435\u043D\u0438\u044F \u0432\u044B\u0448\u0435" }), jsx("li", { children: "\u0411\u0435\u0437 \u0441\u043F\u0440\u0430\u0432\u043E\u043A \u043E \u0434\u043E\u0445\u043E\u0434\u0430\u0445 \u0438 \u0442\u0440\u0443\u0434\u043E\u0443\u0441\u0442\u0440\u043E\u0439\u0441\u0442\u0432\u0435" }), jsx("li", { children: "\u0421 \u0437\u0430\u0449\u0438\u0442\u043E\u0439 \u0412\u0430\u0448\u0438\u0445 \u0434\u0430\u043D\u043D\u044B\u0445" })] })), jsx(Img, { className: "block self-center @md:hidden", image: { icon: 'GosUslugiIcon', iconVersion: 'normal' }, height: "80", width: "80" }), jsx(Button, { type: "button", onClick: handleAuth, className: "w-full @md:w-fit", children: "\u0417\u0430\u043F\u043E\u043B\u043D\u0438\u0442\u044C" })] }), jsx(Img, { className: "hidden @md:block", image: { icon: 'GosUslugiIcon', iconVersion: 'normal' }, height: "164" })] }));
2933
2929
  });
2934
2930
 
2935
2931
  const NAME_HINTS_LIST_OPTIONS = {
@@ -4055,17 +4051,23 @@
4055
4051
  const [programId] = useLocalStorage('programId');
4056
4052
  const { value: selectedCardCategory, onChange: cardCategoryChange } = field('cardCategory');
4057
4053
  const selectedPaymentSystem = field('paymentSystem')?.value?.key;
4054
+ const getCardCategoryValue = useCallback((fetchedCardTypes) => fetchedCardTypes.length === 1
4055
+ ? {
4056
+ key: fetchedCardTypes[0].key,
4057
+ text: fetchedCardTypes[0].value,
4058
+ }
4059
+ : null, []);
4058
4060
  useEffect(() => {
4059
4061
  if (selectedPaymentSystem && programId) {
4060
4062
  (async () => {
4061
4063
  const fetchedCardTypes = await getCardTypes(selectedPaymentSystem, programId);
4062
4064
  setCardTypes(fetchedCardTypes);
4063
4065
  if (!isValidCardCategory(fetchedCardTypes, selectedCardCategory)) {
4064
- cardCategoryChange && cardCategoryChange(null);
4066
+ cardCategoryChange?.(getCardCategoryValue(fetchedCardTypes));
4065
4067
  }
4066
4068
  })();
4067
4069
  }
4068
- }, [selectedPaymentSystem]);
4070
+ }, [selectedPaymentSystem, getCardCategoryValue]);
4069
4071
  const description = useMemo(() => cardTypes?.find((_) => _.key === selectedCardCategory?.key)?.description, [cardTypes, selectedCardCategory]);
4070
4072
  return (jsxs("div", { children: [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 }), description ? jsx(InfoCard, { __html: description }) : null] }));
4071
4073
  });
@@ -4465,6 +4467,8 @@
4465
4467
  42: 'eco_debit_card',
4466
4468
  43: 'junior_debit_card',
4467
4469
  44: 'appetit_debit_card',
4470
+ 46: 'owner_debit_card_plus',
4471
+ 47: 'owner_debit_card_pens_plus',
4468
4472
  };
4469
4473
 
4470
4474
  const RadioButtonGroupControl = JSX(({ className, label, error, ...rest }) => (jsxs("div", { className: style('shrink-0 w-full', className), children: [jsx(RadioButtonGroup, { label: getRequiredLabel({ label, errors: rest?.errors }), ...rest }), renderErrorText(error)] })));
@@ -5539,6 +5543,43 @@
5539
5543
  };
5540
5544
  };
5541
5545
 
5546
+ /* eslint-disable camelcase */
5547
+ const creditCodesToProgrammIdMap = {
5548
+ credit_cash: '10',
5549
+ credit_cash_single_doc: '28',
5550
+ credit_mcx: '39',
5551
+ family_offer_credit: '41',
5552
+ gas_engine_fuel: '33',
5553
+ pension_credit: '12',
5554
+ ref_credit: '11',
5555
+ ref_credit_single_doc: '29',
5556
+ self_employed: '34',
5557
+ summer_cash: '35',
5558
+ summer_cash_pens: '36',
5559
+ };
5560
+ const debitCardCodesToProgrammIdMap = {
5561
+ amur_debit_card: '17',
5562
+ owner_debit_card: '16',
5563
+ pension_debit_card: '18',
5564
+ salary_debit_card: '38',
5565
+ vordi_debit_card: '40',
5566
+ eco_debit_card: '42',
5567
+ junior_debit_card: '43',
5568
+ appetit_debit_card: '44',
5569
+ owner_debit_card_plus: '46',
5570
+ owner_debit_card_pens_plus: '47',
5571
+ };
5572
+ const cardCodesToProgrammIdMap = {
5573
+ amur_card: '14',
5574
+ owner_card: '13',
5575
+ travel_card: '15',
5576
+ };
5577
+ const creditProgramCodeToProductIdMap = {
5578
+ ...creditCodesToProgrammIdMap,
5579
+ ...cardCodesToProgrammIdMap,
5580
+ ...debitCardCodesToProgrammIdMap,
5581
+ };
5582
+
5542
5583
  const DraftActionButton = JSX(({ title, icon, description, onClick = noop }) => (jsxs("button", { className: "flex gap-lg items-center border border-gray/30 rounded-xl cursor-pointer p-4 hover:border-green", type: "button", onClick: onClick, children: [jsx(Img, { image: { icon, iconVersion: 'normal' }, width: "78", height: "78" }), jsxs("div", { className: "flex flex-col items-start gap-xs md:w-72 md:mr-lg", children: [title ? (jsx(Text, { font: "font-medium", size: "text-s", children: title })) : null, description ? (jsx(Text, { color: "text-secondary-text", size: "text-xs", children: description })) : null] })] })));
5543
5584
 
5544
5585
  const fieldsNamesToContactKeysMap = {
@@ -5634,7 +5675,6 @@
5634
5675
  };
5635
5676
  const countIncomeAverage = (wages, retirementIncome) => (Number(wages ?? 0) + Number(retirementIncome ?? 0)).toString();
5636
5677
 
5637
- /* eslint-disable camelcase */
5638
5678
  const EMPLOYMENT_TYPE = {
5639
5679
  WORK: 'Работаю',
5640
5680
  RETIREE: 'Пенсионер',
@@ -5645,28 +5685,6 @@
5645
5685
  PFR_CERTIFICATE: 'Получаю зарплату на счет/карту в другом банке',
5646
5686
  OTHER: 'Другое',
5647
5687
  };
5648
- const creditCodesToProgrammIdMap = {
5649
- credit_cash: '10',
5650
- credit_cash_single_doc: '28',
5651
- credit_mcx: '39',
5652
- family_offer_credit: '41',
5653
- gas_engine_fuel: '33',
5654
- pension_credit: '12',
5655
- ref_credit: '11',
5656
- ref_credit_single_doc: '29',
5657
- self_employed: '34',
5658
- summer_cash: '35',
5659
- summer_cash_pens: '36',
5660
- };
5661
- const cardCodesToProgrammIdMap = {
5662
- amur_card: '14',
5663
- owner_card: '13',
5664
- travel_card: '15',
5665
- };
5666
- const creditProgramCodeToProductIdMap = {
5667
- ...creditCodesToProgrammIdMap,
5668
- ...cardCodesToProgrammIdMap,
5669
- };
5670
5688
  const getParticipantIncomes = (participantIncomes) => {
5671
5689
  const wages = participantIncomes?.find((contact) => contact.incomeTypeCd.key === "WAGES" /* EIncomesType.WAGES */)?.value;
5672
5690
  const mandatoryPayments = participantIncomes?.find((contact) => contact.incomeTypeCd.key === "MANDATORY_PAYMENTS" /* EIncomesType.MANDATORY_PAYMENTS */)?.value;
@@ -5722,6 +5740,27 @@
5722
5740
  }
5723
5741
  : undefined;
5724
5742
  };
5743
+ const getProductData = (isDebit = false, isCredit = false) => {
5744
+ if (isDebit) {
5745
+ return {
5746
+ nextStepLink: '/debit-card-lead',
5747
+ newTaskLink: '/natural/debetcards',
5748
+ description: 'На дебетовую карту',
5749
+ };
5750
+ }
5751
+ else if (isCredit) {
5752
+ return {
5753
+ nextStepLink: '/credit-lead',
5754
+ newTaskLink: '/natural/loans/all-goals',
5755
+ description: 'На получение кредита',
5756
+ };
5757
+ }
5758
+ return {
5759
+ nextStepLink: '/credit-card-lead',
5760
+ newTaskLink: '/natural/creditcards/svoya',
5761
+ description: 'На получение кредитной карты',
5762
+ };
5763
+ };
5725
5764
 
5726
5765
  const parseDraftTask = (task) => {
5727
5766
  const participant = task.participants[0];
@@ -5793,15 +5832,7 @@
5793
5832
  const { participants, creditProgram, createdDate = '', id: taskId } = task;
5794
5833
  const programmId = creditProgramCodeToProductIdMap[creditProgram.code];
5795
5834
  const isCredit = Boolean(creditCodesToProgrammIdMap[creditProgram.code]);
5796
- const getNextStepLink = () => {
5797
- if (isDebit) {
5798
- return '/debit-card-lead';
5799
- }
5800
- else if (isCredit) {
5801
- return '/credit-lead';
5802
- }
5803
- return '/credit-card-lead';
5804
- };
5835
+ const productData = getProductData(isDebit, isCredit);
5805
5836
  const { id: participantId, profile } = participants[0];
5806
5837
  const handleGoToDraft = useCallback(() => {
5807
5838
  const taskFromDraft = parseDraftTask(task);
@@ -5813,18 +5844,19 @@
5813
5844
  if (profile?.id) {
5814
5845
  sendAspects(profile.id, taskId);
5815
5846
  }
5816
- navigator.assign(getNextStepLink());
5847
+ navigator.assign(productData.nextStepLink);
5817
5848
  }, []);
5818
5849
  const handleGoToNewTask = useCallback(() => {
5819
- navigator.assign(isCredit ? '/natural/loans/all-goals' : '/natural/creditcards/svoya');
5850
+ navigator.assign(productData.newTaskLink);
5820
5851
  }, []);
5821
- return (jsx(Dialog, { className: "my-6xl max-w-4xl w-full min-h-fit mx-auto rounded-xl py-0", onClose: onClose, children: jsxs("div", { className: "flex flex-col gap-lg items-center mt-xs mx-6xl", children: [jsx(Heading, { className: "whitespace-pre-wrap text-center", title: "\u041D\u0430\u0448\u043B\u0438 \u0447\u0435\u0440\u043D\u043E\u0432\u0438\u043A \u0432\u0430\u0448\u0435\u0439 \u0437\u0430\u044F\u0432\u043A\u0438", headingType: "h5" }), jsxs("div", { className: "flex flex-col gap-m max-w-lg", children: [jsx(DraftActionButton, { title: "\u041F\u0440\u043E\u0434\u043E\u043B\u0436\u0438\u0442\u044C \u0437\u0430\u043F\u043E\u043B\u043D\u0435\u043D\u0438\u0435 \u0447\u0435\u0440\u043D\u043E\u0432\u0438\u043A\u0430", icon: "BankColorIcon", description: createdDate ? `Черновик от ${formatDate(new Date(createdDate))}` : '', onClick: handleGoToDraft }), jsx(DraftActionButton, { title: isFromLead ? 'Продолжить заполнение текущей заявки' : 'Создать новую заявку', icon: "NewLoanIcon", description: "\u041D\u0430 \u043F\u043E\u043B\u0443\u0447\u0435\u043D\u0438\u0435 \u043A\u0440\u0435\u0434\u0438\u0442\u0430", onClick: isFromLead ? onClose : handleGoToNewTask })] })] }) }));
5852
+ return (jsx(Dialog, { className: "my-6xl max-w-4xl w-full min-h-fit mx-auto rounded-xl py-0", onClose: onClose, children: jsxs("div", { className: "flex flex-col gap-lg items-center mt-xs mx-6xl", children: [jsx(Heading, { className: "whitespace-pre-wrap text-center", title: "\u041D\u0430\u0448\u043B\u0438 \u0447\u0435\u0440\u043D\u043E\u0432\u0438\u043A \u0432\u0430\u0448\u0435\u0439 \u0437\u0430\u044F\u0432\u043A\u0438", headingType: "h5" }), jsxs("div", { className: "flex flex-col gap-m max-w-lg", children: [jsx(DraftActionButton, { title: "\u041F\u0440\u043E\u0434\u043E\u043B\u0436\u0438\u0442\u044C \u0437\u0430\u043F\u043E\u043B\u043D\u0435\u043D\u0438\u0435 \u0447\u0435\u0440\u043D\u043E\u0432\u0438\u043A\u0430", icon: "BankColorIcon", description: createdDate ? `Черновик от ${formatDate(new Date(createdDate))}` : '', onClick: handleGoToDraft }), jsx(DraftActionButton, { title: isFromLead ? 'Продолжить заполнение текущей заявки' : 'Создать новую заявку', icon: "NewLoanIcon", description: productData.description, onClick: isFromLead ? onClose : handleGoToNewTask })] })] }) }));
5822
5853
  });
5823
5854
 
5824
- const EmptyDraftDialog = JSX(function ({ onClose = noop }) {
5855
+ const EmptyDraftDialog = JSX(function ({ isDebit, onClose = noop }) {
5825
5856
  const navigator = locationNavigator();
5857
+ const productData = getProductData(isDebit);
5826
5858
  const handleGoNewTask = useCallback(() => {
5827
- navigator.assign('/natural/loans/all-goals');
5859
+ navigator.assign(productData.newTaskLink);
5828
5860
  }, []);
5829
5861
  const handleGoMainPage = useCallback(() => {
5830
5862
  navigator.assign('/');
@@ -5839,7 +5871,7 @@
5839
5871
  open: ({ task, isFromLead, isDebit, onClose, sendAspects }) => {
5840
5872
  task
5841
5873
  ? openDraftDialog({ task, isFromLead, isDebit, onClose, sendAspects })
5842
- : openEmptyDraftDialog({});
5874
+ : openEmptyDraftDialog({ isDebit });
5843
5875
  },
5844
5876
  };
5845
5877
  };
@@ -6516,7 +6548,7 @@
6516
6548
  reset();
6517
6549
  }
6518
6550
  }, [leadForm?.current, esiaStatus]);
6519
- return (jsxs(ApplicationFormLayout, { className: style('container space-y-m', className), title: title, ...rest, children: [!esiaStatus ? jsx(EsiaLoginBanner, { onChangeEsiaStatus: setEsiaStatus }) : null, jsxs("form", { onSubmit: onSubmitWithPrecondition, className: "space-y-m relative", ref: leadForm, children: [esiaStatus === EsiaStatuses.Pending ? jsx(Loader, { blur: false }) : null, applicationFormData.map((_, i) => (jsxs("div", { className: style(inputColumnStyles(_.columns), 'grid gap-x-m'), children: [renderTitle(_.title), renderInputs$1({ field, inputs: _?.inputs }, productType)] }, `section-${i}`))), renderSubmitButton(button, isSending), esiaStatus === EsiaStatuses.Error ? (jsx(Text, { size: "text-m", font: "font-medium", color: "text-error", children: "\u0418\u0441\u043F\u043E\u043B\u044C\u0437\u043E\u0432\u0430\u0442\u044C \u0413\u043E\u0441\u0443\u0441\u043B\u0443\u0433\u0438 \u0434\u043B\u044F \u043E\u0444\u043E\u0440\u043C\u043B\u0435\u043D\u0438\u044F \u0437\u0430\u044F\u0432\u043A\u0438 \u043D\u0435\u0432\u043E\u0437\u043C\u043E\u0436\u043D\u043E, \u043D\u0435\u043E\u0431\u0445\u043E\u0434\u0438\u043C\u043E \u0437\u0430\u043F\u043E\u043B\u043D\u0438\u0442\u044C \u043F\u043E\u043B\u044F \u0432\u0440\u0443\u0447\u043D\u0443\u044E." })) : null] })] }));
6551
+ return (jsxs(ApplicationFormLayout, { className: style('container space-y-m', className), title: title, ...rest, children: [!esiaStatus ? (jsx(EsiaLoginBanner, { onChangeEsiaStatus: setEsiaStatus, productType: productType })) : null, jsxs("form", { onSubmit: onSubmitWithPrecondition, className: "space-y-m relative", ref: leadForm, children: [esiaStatus === EsiaStatuses.Pending ? jsx(Loader, { blur: false }) : null, applicationFormData.map((_, i) => (jsxs("div", { className: style(inputColumnStyles(_.columns), 'grid gap-x-m'), children: [renderTitle(_.title), renderInputs$1({ field, inputs: _?.inputs }, productType)] }, `section-${i}`))), renderSubmitButton(button, isSending), esiaStatus === EsiaStatuses.Error ? (jsx(Text, { size: "text-m", font: "font-medium", color: "text-error", children: "\u0418\u0441\u043F\u043E\u043B\u044C\u0437\u043E\u0432\u0430\u0442\u044C \u0413\u043E\u0441\u0443\u0441\u043B\u0443\u0433\u0438 \u0434\u043B\u044F \u043E\u0444\u043E\u0440\u043C\u043B\u0435\u043D\u0438\u044F \u0437\u0430\u044F\u0432\u043A\u0438 \u043D\u0435\u0432\u043E\u0437\u043C\u043E\u0436\u043D\u043E, \u043D\u0435\u043E\u0431\u0445\u043E\u0434\u0438\u043C\u043E \u0437\u0430\u043F\u043E\u043B\u043D\u0438\u0442\u044C \u043F\u043E\u043B\u044F \u0432\u0440\u0443\u0447\u043D\u0443\u044E." })) : null] })] }));
6520
6552
  });
6521
6553
  const getInputs = (applicationFormData) => (applicationFormData?.flatMap((_) => _?.inputs) || []);
6522
6554
  const getExtendedValidatorObj = (productType) => ({
@@ -8279,7 +8311,10 @@
8279
8311
  phone: formatPhone(phone),
8280
8312
  email,
8281
8313
  }),
8282
- participantAddresses: getParticipantAddresses$1({ addressRegistration, addressFact }),
8314
+ participantAddresses: getParticipantAddresses$1({
8315
+ addressRegistration,
8316
+ addressFact: addressMatch ? addressRegistration : addressFact,
8317
+ }),
8283
8318
  genderCd: sex
8284
8319
  ? {
8285
8320
  key: sex === 'male' ? 'MAN' : 'WOMAN',
@@ -9506,6 +9541,7 @@
9506
9541
  fullAddress: '',
9507
9542
  fiasCode: '',
9508
9543
  },
9544
+ addressMatch: true,
9509
9545
  addressFact: {
9510
9546
  fullAddress: '',
9511
9547
  fiasCode: '',
@@ -9659,6 +9695,108 @@
9659
9695
  return (jsxs("form", { onSubmit: handleSubmit, className: "space-y-m", children: [renderStep$1({ sections, field, step }), jsx(StepsNavigationButtons, { step: step, isSending: isSending, onPrevStep: onPrevStep })] }));
9660
9696
  });
9661
9697
 
9698
+ /* eslint-disable max-lines */
9699
+ const DELIVERY_DEBIT_CARD_CONTENT = [
9700
+ {
9701
+ title: 'Регион обслуживания карты',
9702
+ columns: 1,
9703
+ inputs: [],
9704
+ },
9705
+ {
9706
+ inputs: [
9707
+ {
9708
+ name: 'regionRetail',
9709
+ required: true,
9710
+ },
9711
+ ],
9712
+ },
9713
+ {
9714
+ title: 'Способ получения',
9715
+ columns: 1,
9716
+ inputs: [],
9717
+ condition: {
9718
+ name: 'regionHasDelivery',
9719
+ values: [true],
9720
+ },
9721
+ },
9722
+ {
9723
+ inputs: [
9724
+ {
9725
+ name: 'methodObtain',
9726
+ condition: {
9727
+ name: 'regionHasDelivery',
9728
+ values: [true],
9729
+ },
9730
+ },
9731
+ ],
9732
+ },
9733
+ {
9734
+ title: 'Выбор офиса',
9735
+ columns: 1,
9736
+ inputs: [],
9737
+ condition: {
9738
+ name: 'methodObtain',
9739
+ values: ['office'],
9740
+ },
9741
+ },
9742
+ {
9743
+ title: 'Адрес доставки',
9744
+ columns: 1,
9745
+ inputs: [],
9746
+ condition: {
9747
+ name: 'methodObtain',
9748
+ values: ['courier'],
9749
+ },
9750
+ },
9751
+ {
9752
+ inputs: [
9753
+ {
9754
+ name: 'addressCourier',
9755
+ dadata: true,
9756
+ condition: {
9757
+ name: 'methodObtain',
9758
+ values: ['courier'],
9759
+ },
9760
+ required: true,
9761
+ },
9762
+ ],
9763
+ },
9764
+ {
9765
+ inputs: [
9766
+ {
9767
+ name: 'infoCard',
9768
+ condition: {
9769
+ name: 'methodObtain',
9770
+ values: ['courier'],
9771
+ },
9772
+ label: 'Ожидайте звонка для согласования даты и времени доставки карты',
9773
+ },
9774
+ ],
9775
+ },
9776
+ {
9777
+ inputs: [
9778
+ {
9779
+ name: 'comment',
9780
+ condition: {
9781
+ name: 'methodObtain',
9782
+ values: ['courier'],
9783
+ },
9784
+ },
9785
+ ],
9786
+ },
9787
+ {
9788
+ inputs: [
9789
+ {
9790
+ name: 'addressRetail',
9791
+ required: true,
9792
+ condition: {
9793
+ name: 'methodObtain',
9794
+ values: ['office'],
9795
+ },
9796
+ },
9797
+ ],
9798
+ },
9799
+ ];
9662
9800
  const DEBIT_PERSONAL_INFO_CONTENT = [
9663
9801
  ...PERSONAL_DATA,
9664
9802
  {
@@ -9680,9 +9818,23 @@
9680
9818
  {
9681
9819
  title: 'Адрес фактического проживания (место пребывания РФ)',
9682
9820
  inputs: [],
9821
+ condition: {
9822
+ name: 'addressMatch',
9823
+ values: [false],
9824
+ },
9683
9825
  },
9684
9826
  {
9685
- inputs: [{ name: 'addressFact', required: true, dadata: true }],
9827
+ inputs: [
9828
+ {
9829
+ name: 'addressFact',
9830
+ required: true,
9831
+ dadata: true,
9832
+ condition: {
9833
+ name: 'addressMatch',
9834
+ values: [false],
9835
+ },
9836
+ },
9837
+ ],
9686
9838
  },
9687
9839
  ];
9688
9840
  const DEBIT_CARD_CONTENT = [
@@ -9713,6 +9865,9 @@
9713
9865
  },
9714
9866
  ],
9715
9867
  },
9868
+ {
9869
+ inputs: [{ name: 'codeWord', required: true }],
9870
+ },
9716
9871
  {
9717
9872
  inputs: [
9718
9873
  {
@@ -9723,12 +9878,9 @@
9723
9878
  },
9724
9879
  ],
9725
9880
  },
9726
- {
9727
- inputs: [{ name: 'codeWord', required: true }],
9728
- },
9729
9881
  ];
9730
9882
  const stepsSectionsMap = [
9731
- DELIVERY_CARD_CONTENT,
9883
+ DELIVERY_DEBIT_CARD_CONTENT,
9732
9884
  DEBIT_PERSONAL_INFO_CONTENT,
9733
9885
  DEBIT_CARD_CONTENT,
9734
9886
  ];
@@ -9751,7 +9903,11 @@
9751
9903
  }, []);
9752
9904
  const sections = stepsSectionsMap[step];
9753
9905
  const isStartStep = step === 0;
9754
- const [isFormFinished, { setTrue: handleFinish }] = useBool(false);
9906
+ const [isFormFinished, { setTrue: setIsFormFinished }] = useBool(false);
9907
+ const handleFinish = useCallback(() => {
9908
+ setIsFormFinished();
9909
+ scrollToTop();
9910
+ }, []);
9755
9911
  return (jsx(BlockWrapper, { className: className, ...rest, children: jsxs("div", { ref: formContainerRef, className: "container grid grid-cols-12", children: [isStartStep || isFormFinished ? null : (jsx(DebitFormProgress, { stepsTitles: STEP_TITLES, step: step, totalSteps: STEPS })), jsx("div", { className: "py-lg px-5xl mt-2xs bg-white col-span-12", children: isFormFinished ? (jsx(DebitFormStatusTracker, {})) : (jsx(DebitFormStep, { step: step, sections: sections, onNextStep: handleNextStep, onPrevStep: handlePrevStep, onFinish: handleFinish }, String(step))) })] }) }));
9756
9912
  });
9757
9913
 
@@ -11368,7 +11524,7 @@
11368
11524
  slots: () => [HEADER_SLOT, FOOTER_SLOT, STICKY_FOOTER_SLOT],
11369
11525
  });
11370
11526
 
11371
- const packageVersion = "0.14.883";
11527
+ const packageVersion = "0.14.884";
11372
11528
 
11373
11529
  exports.Blocks = Blocks;
11374
11530
  exports.ContentPage = ContentPage;