@adyen/kyc-components 3.49.1 → 3.50.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/es/{B4MFY5CR-AuQHUV9g.js → B4MFY5CR-Bt-nnzG3.js} +1 -1
- package/dist/es/{HO4MOOFI-BOYDsHNa.js → HO4MOOFI-70Nm-7sY.js} +2 -2
- package/dist/es/{HUY7CZI3-CEkZPXCo.js → HUY7CZI3-1U-zoofU.js} +2 -2
- package/dist/es/adyen-kyc-components.es.js +1 -1
- package/dist/es/{index-Ed-ypPId.js → index-BSV6Ni-p.js} +697 -521
- package/dist/style.css +84 -104
- package/dist/types/components/Address/constants.d.ts +0 -1
- package/dist/types/components/Address/utils.d.ts +1 -1
- package/dist/types/components/BusinessMismatchModal/BusinessMismatchModal.d.ts +6 -0
- package/dist/types/components/Company/Company.d.ts +0 -1
- package/dist/types/components/Dropins/FormNavigation/types.d.ts +2 -5
- package/dist/types/components/Dropins/SourceOfFundsDropin/SOFAdditionalData/AdditionalDataForAssetSale.d.ts +2 -2
- package/dist/types/components/Dropins/SourceOfFundsDropin/SOFAdditionalData/AdditionalDataForBusiness.d.ts +2 -2
- package/dist/types/components/Dropins/SourceOfFundsDropin/SOFAdditionalData/AdditionalDataForCryptocurrency.d.ts +2 -2
- package/dist/types/components/Dropins/SourceOfFundsDropin/SOFAdditionalData/AdditionalDataForDonation.d.ts +2 -2
- package/dist/types/components/Dropins/SourceOfFundsDropin/SOFAdditionalData/AdditionalDataForGambling.d.ts +2 -2
- package/dist/types/components/Dropins/SourceOfFundsDropin/SOFAdditionalData/AdditionalDataForInheritance.d.ts +2 -2
- package/dist/types/components/Dropins/SourceOfFundsDropin/SOFAdditionalData/AdditionalDataForThirdParty.d.ts +2 -2
- package/dist/types/components/Dropins/SourceOfFundsDropin/SOFAdditionalData/AdditionalDataOriginatorLegalEntity.d.ts +2 -2
- package/dist/types/components/Dropins/SourceOfFundsDropin/types.d.ts +1 -1
- package/dist/types/components/EmbeddedDropins/ViewVerificationStatus/ViewVerificationStatusComponent.d.ts +0 -1
- package/dist/types/components/ErrorPanel/types.d.ts +4 -4
- package/dist/types/components/Individual/Individual.d.ts +0 -1
- package/dist/types/components/SingpassBanner/SingpassBanner.d.ts +1 -1
- package/dist/types/components/Summary/types.d.ts +2 -6
- package/dist/types/components/TaskList/TaskListItem.d.ts +1 -1
- package/dist/types/components/TaskList/types.d.ts +4 -1
- package/dist/types/components/Trust/Trust.d.ts +0 -1
- package/dist/types/components/UIElement/UIElement.d.ts +4 -4
- package/dist/types/components/ui/atoms/Button/Button.d.ts +1 -1
- package/dist/types/components/ui/atoms/Button/Button.types.d.ts +1 -0
- package/dist/types/components/ui/atoms/Modal/Modal.d.ts +2 -1
- package/dist/types/components/ui/atoms/Tag/Tag.d.ts +0 -2
- package/dist/types/components/{FormEndState → ui/molecules/FormEndState}/types.d.ts +1 -1
- package/dist/types/core/context/ExperimentContext/types.d.ts +2 -1
- package/dist/types/core/hooks/useBusinessData/types.d.ts +1 -0
- package/dist/types/core/hooks/useForm/reducer.d.ts +2 -2
- package/dist/types/core/hooks/useForm/types.d.ts +4 -1
- package/dist/types/core/hooks/useForm/useForm.d.ts +1 -1
- package/dist/types/core/models/api/document.d.ts +8 -8
- package/dist/types/core/models/form-rules.d.ts +1 -0
- package/dist/types/core/user-events.d.ts +10 -5
- package/dist/types/utils/entityStatusUtil.d.ts +1 -1
- package/dist/types/utils/formUtils.d.ts +4 -5
- package/dist/types/utils/localizeDateString.d.ts +4 -1
- package/dist/types/utils/mapping/componentApiMapping.d.ts +1 -1
- package/dist/types/utils/trackNavigation.d.ts +9 -7
- package/dist/types/utils/validation/types.d.ts +2 -1
- package/package.json +2 -2
- package/dist/types/components/ui/molecules/Splashscreen/Splashscreen.d.ts +0 -10
- package/dist/types/core/hooks/usePolling.d.ts +0 -9
- /package/dist/types/components/{FormEndState → ui/molecules/FormEndState}/FormEndState.d.ts +0 -0
|
@@ -218,7 +218,9 @@ const defaultLocaleTranslations = {
|
|
|
218
218
|
businessIncorporationNumber: "Business incorporation number",
|
|
219
219
|
businessInformation: "Business information",
|
|
220
220
|
businessInvestorDetails: "Business investor details",
|
|
221
|
+
businessLegalName: "Business legal name",
|
|
221
222
|
businessName: "Business name",
|
|
223
|
+
businessName__helperText: "The legal name is used to identify a business with the government; enter it exactly as it appears on your government or legal forms.",
|
|
222
224
|
businessNumber: "Business number",
|
|
223
225
|
businessRegistrationDocument__FR: "Business registration document, such as a KBIS extract or situation au répertoire sirene",
|
|
224
226
|
businessRegistryStatement: "Business registry statement",
|
|
@@ -228,6 +230,10 @@ const defaultLocaleTranslations = {
|
|
|
228
230
|
businessSelection__heading: "Select your business",
|
|
229
231
|
businessSelection__invalidTin: "This company's TIN doesn't match yours",
|
|
230
232
|
businessSelection__tinVerificationFailure: "Sorry, something went wrong. Try again or continue by pressing Add details manually",
|
|
233
|
+
businessSelection__tinVerificationFailureModalContent: "The tax ID didn't match the legal business name. How would you like to continue?",
|
|
234
|
+
businessSelection__tinVerificationFailureModalHeader: "Business couldn't be identified",
|
|
235
|
+
businessSelection__tinVerificationFailureModalPrimaryButton: "Continue anyway",
|
|
236
|
+
businessSelection__tinVerificationFailureModalSecondaryButton: "Edit details",
|
|
231
237
|
businessStructure: "Business structure",
|
|
232
238
|
businessTrust: "Business trust",
|
|
233
239
|
businessTrusteeDetails: "Business trustee details",
|
|
@@ -413,6 +419,7 @@ const defaultLocaleTranslations = {
|
|
|
413
419
|
downloadACopy: "Download a copy",
|
|
414
420
|
downloadAsPdf: "Download as PDF",
|
|
415
421
|
driversLicense: "Driver's license",
|
|
422
|
+
driving_licence: "Driving license",
|
|
416
423
|
drivinglicenseBack: "Driving license (back)",
|
|
417
424
|
drivinglicenseFront: "Driving license (front)",
|
|
418
425
|
dropFileToUpload: "Drop file to upload",
|
|
@@ -1075,6 +1082,8 @@ const defaultLocaleTranslations = {
|
|
|
1075
1082
|
nameOfTrustAgreement: "Name of trust agreement",
|
|
1076
1083
|
namesOfInvolvedParties: "Names of involved parties (if applicable)",
|
|
1077
1084
|
namesOfLandlordAndTenant: "Names of landlord and tenant",
|
|
1085
|
+
national_identity_card: "National ID Card",
|
|
1086
|
+
nationalIdNumber: "National ID Number",
|
|
1078
1087
|
nationalInsuranceNumber: "National Insurance Number (NINO)",
|
|
1079
1088
|
nationality: "Nationality",
|
|
1080
1089
|
naturalPersonDescription: "He/she doesn't have any business.",
|
|
@@ -1224,9 +1233,13 @@ const defaultLocaleTranslations = {
|
|
|
1224
1233
|
processing: "Processing",
|
|
1225
1234
|
professionalServiceProvider: "My settlor is a professional service provider",
|
|
1226
1235
|
progress: "Progress",
|
|
1236
|
+
proofOfAddress: "Proof of address",
|
|
1227
1237
|
proofOfAnnualTurnoverAmount: "Proof of annual turnover amount",
|
|
1228
1238
|
proofOfDirector: "Proof of director",
|
|
1239
|
+
proofOfFundingOrWealthSource: "Proof of funding or wealth source",
|
|
1229
1240
|
proofOfNationalId: "Proof of national ID",
|
|
1241
|
+
proofOfNationalIdNumber: "Proof of national ID number",
|
|
1242
|
+
proofOfOrganizationTaxInfo: "Proof of organization tax information",
|
|
1230
1243
|
proofOfOwnership: "Proof of ownership",
|
|
1231
1244
|
proofOfOwnershipRent: "Proof of ownership",
|
|
1232
1245
|
proofOfRelationship: "Proof of relationship",
|
|
@@ -1361,6 +1374,7 @@ const defaultLocaleTranslations = {
|
|
|
1361
1374
|
requirements: "Requirements:",
|
|
1362
1375
|
requiresDecisionMakers: "Requires decision-makers",
|
|
1363
1376
|
requiresSignatory: "Requires signatory",
|
|
1377
|
+
residence_permit: "Residence permit",
|
|
1364
1378
|
residencePermitBack: "Residence permit (back)",
|
|
1365
1379
|
residencePermitFront: "Residence permit (front)",
|
|
1366
1380
|
residencyCountry: "Country/region of residence",
|
|
@@ -1644,6 +1658,7 @@ const defaultLocaleTranslations = {
|
|
|
1644
1658
|
validationPleaseEnterAValidVatNumber: "Please enter a valid Tax id number",
|
|
1645
1659
|
validationPleaseEnterAValidVatNumberWithFormat: "Please enter a valid VAT number. Expected format: %{format}",
|
|
1646
1660
|
vatAbsenceReason: "VAT number absence reason",
|
|
1661
|
+
vatDocument: "VAT document",
|
|
1647
1662
|
vatNumber: "VAT number",
|
|
1648
1663
|
vatNummerMomsregistreringsnummerOrMomsnummer: "VAT-nummer, Momsregistreringsnummer, or Momsnummer",
|
|
1649
1664
|
vatRegistrationNumber: "VAT registration number",
|
|
@@ -2223,6 +2238,25 @@ function useBusinessData({
|
|
|
2223
2238
|
},
|
|
2224
2239
|
[handleVerifyTin]
|
|
2225
2240
|
);
|
|
2241
|
+
const verifyManualBusinessData = useCallback(
|
|
2242
|
+
async (name, tin) => {
|
|
2243
|
+
if (!handleVerifyTin) {
|
|
2244
|
+
logger$R.log("Missing handlers for verifyBusinessData");
|
|
2245
|
+
return;
|
|
2246
|
+
}
|
|
2247
|
+
try {
|
|
2248
|
+
setVerifying("loading");
|
|
2249
|
+
const { matched } = await handleVerifyTin({ name, tin });
|
|
2250
|
+
return matched;
|
|
2251
|
+
} catch (e) {
|
|
2252
|
+
setVerifying("error");
|
|
2253
|
+
logger$R.error(e);
|
|
2254
|
+
} finally {
|
|
2255
|
+
setVerifying((prevState) => prevState !== "error" ? "loaded" : prevState);
|
|
2256
|
+
}
|
|
2257
|
+
},
|
|
2258
|
+
[handleVerifyTin]
|
|
2259
|
+
);
|
|
2226
2260
|
const clearTrustedBusinessData = useCallback(async () => {
|
|
2227
2261
|
try {
|
|
2228
2262
|
setResettingTrustedData("loading");
|
|
@@ -2246,6 +2280,7 @@ function useBusinessData({
|
|
|
2246
2280
|
searchForBusiness,
|
|
2247
2281
|
fetchBusinessData,
|
|
2248
2282
|
verifyBusinessData,
|
|
2283
|
+
verifyManualBusinessData,
|
|
2249
2284
|
clearTrustedBusinessData,
|
|
2250
2285
|
resetBusinessData,
|
|
2251
2286
|
resetTinVerification,
|
|
@@ -2327,7 +2362,6 @@ const createFormUtils = (props, i18n) => ({
|
|
|
2327
2362
|
isReadOnly: (field) => props.readOnly || (props.readOnlyFields ? props.readOnlyFields.includes(field) : false),
|
|
2328
2363
|
isObscured: (field) => props.obscuredFields ? props.obscuredFields.includes(field) : false,
|
|
2329
2364
|
isTrusted: (field) => props.trustedFields ? props.trustedFields.includes(field) : false,
|
|
2330
|
-
getVal: (val) => i18n.get(val),
|
|
2331
2365
|
getErrorMessage: (field, errors, fieldProblems) => {
|
|
2332
2366
|
var _a2;
|
|
2333
2367
|
const errorMessage = (_a2 = errors == null ? void 0 : errors[field]) == null ? void 0 : _a2.errorMessage;
|
|
@@ -2703,7 +2737,7 @@ const loaderSmall = "adyen-kyc-loader-small";
|
|
|
2703
2737
|
const loaderMedium = "adyen-kyc-loader-medium";
|
|
2704
2738
|
const loaderXsmall = "adyen-kyc-loader-xsmall";
|
|
2705
2739
|
const loaderDot = "adyen-kyc-loader-dot";
|
|
2706
|
-
const styles$
|
|
2740
|
+
const styles$o = {
|
|
2707
2741
|
loaderWrapper,
|
|
2708
2742
|
loaderWrapperInline,
|
|
2709
2743
|
loader,
|
|
@@ -2714,16 +2748,16 @@ const styles$l = {
|
|
|
2714
2748
|
loaderDot
|
|
2715
2749
|
};
|
|
2716
2750
|
const sizeMap = {
|
|
2717
|
-
xsmall: styles$
|
|
2718
|
-
small: styles$
|
|
2719
|
-
medium: styles$
|
|
2720
|
-
large: styles$
|
|
2751
|
+
xsmall: styles$o.loaderXsmall,
|
|
2752
|
+
small: styles$o.loaderSmall,
|
|
2753
|
+
medium: styles$o.loaderMedium,
|
|
2754
|
+
large: styles$o.loaderLarge
|
|
2721
2755
|
};
|
|
2722
|
-
const Loader = ({ inline = false, size = "large", dot = false }) => /* @__PURE__ */ jsx("div", { className: cx(styles$
|
|
2756
|
+
const Loader = ({ inline = false, size = "large", dot = false }) => /* @__PURE__ */ jsx("div", { className: cx(styles$o.loaderWrapper, { [styles$o.loaderWrapperInline]: inline }), children: /* @__PURE__ */ jsx(
|
|
2723
2757
|
"div",
|
|
2724
2758
|
{
|
|
2725
2759
|
role: "progressbar",
|
|
2726
|
-
className: cx(styles$
|
|
2760
|
+
className: cx(styles$o.loader, sizeMap[size], { [styles$o.loaderDot]: dot })
|
|
2727
2761
|
}
|
|
2728
2762
|
) });
|
|
2729
2763
|
const Button = ({
|
|
@@ -2740,6 +2774,7 @@ const Button = ({
|
|
|
2740
2774
|
label = "",
|
|
2741
2775
|
icon,
|
|
2742
2776
|
iconPosition = "left",
|
|
2777
|
+
iconClassName = "",
|
|
2743
2778
|
title,
|
|
2744
2779
|
disabled = false,
|
|
2745
2780
|
type = "button",
|
|
@@ -2756,13 +2791,14 @@ const Button = ({
|
|
|
2756
2791
|
onClick(event);
|
|
2757
2792
|
}
|
|
2758
2793
|
};
|
|
2794
|
+
const iconClassNames = cx("adyen-kyc-link__icon", iconClassName);
|
|
2759
2795
|
const buttonTextClasses = showAsLink ? "adyen-kyc-link__text" : "adyen-kyc-button__text";
|
|
2760
2796
|
const buttonText = loading ? /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
2761
2797
|
label && /* @__PURE__ */ jsx("span", { className: buttonTextClasses, children: label }),
|
|
2762
2798
|
/* @__PURE__ */ jsx("span", { className: "adyen-kyc-button__loader-container--active", children: /* @__PURE__ */ jsx(Loader, { size: "small" }) })
|
|
2763
2799
|
] }) : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
2764
2800
|
label && /* @__PURE__ */ jsx("span", { className: buttonTextClasses, children: label }),
|
|
2765
|
-
icon && /* @__PURE__ */ jsx(Icon, { name: icon, className:
|
|
2801
|
+
icon && /* @__PURE__ */ jsx(Icon, { name: icon, className: iconClassNames })
|
|
2766
2802
|
] });
|
|
2767
2803
|
const buttonClasses = showAsLink ? cx("adyen-kyc-link", className2, {
|
|
2768
2804
|
"adyen-kyc-link--icon-left": icon && iconPosition === "left",
|
|
@@ -2798,10 +2834,10 @@ const Button = ({
|
|
|
2798
2834
|
);
|
|
2799
2835
|
};
|
|
2800
2836
|
const divider = "adyen-kyc-divider";
|
|
2801
|
-
const styles$
|
|
2837
|
+
const styles$n = {
|
|
2802
2838
|
divider
|
|
2803
2839
|
};
|
|
2804
|
-
const Divider = () => /* @__PURE__ */ jsx("hr", { className: styles$
|
|
2840
|
+
const Divider = () => /* @__PURE__ */ jsx("hr", { className: styles$n.divider });
|
|
2805
2841
|
const alert = "adyen-kyc-alert";
|
|
2806
2842
|
const alertWithoutIcon = "adyen-kyc-alert-without-icon";
|
|
2807
2843
|
const alertExplanation = "adyen-kyc-alert-explanation";
|
|
@@ -2819,7 +2855,7 @@ const alertIconWarning = "adyen-kyc-alert-icon-warning";
|
|
|
2819
2855
|
const alertIconSuccess = "adyen-kyc-alert-icon-success";
|
|
2820
2856
|
const alertCloseButton = "adyen-kyc-alert-close-button";
|
|
2821
2857
|
const alertTitle = "adyen-kyc-alert-title";
|
|
2822
|
-
const styles$
|
|
2858
|
+
const styles$m = {
|
|
2823
2859
|
alert,
|
|
2824
2860
|
alertWithoutIcon,
|
|
2825
2861
|
alertExplanation,
|
|
@@ -2850,7 +2886,7 @@ const accordionContent = "adyen-kyc-accordion-content";
|
|
|
2850
2886
|
const accordionWithIcon = "adyen-kyc-accordion-with-icon";
|
|
2851
2887
|
const accordionArrow = "adyen-kyc-accordion-arrow";
|
|
2852
2888
|
const accordionArrowRight = "adyen-kyc-accordion-arrow-right";
|
|
2853
|
-
const styles$
|
|
2889
|
+
const styles$l = {
|
|
2854
2890
|
accordion,
|
|
2855
2891
|
accordionSummary,
|
|
2856
2892
|
accordionBasic,
|
|
@@ -2867,7 +2903,7 @@ const styles$i = {
|
|
|
2867
2903
|
const skeleton = "adyen-kyc-skeleton";
|
|
2868
2904
|
const skeletonCircle = "adyen-kyc-skeleton-circle";
|
|
2869
2905
|
const skeletonText = "adyen-kyc-skeleton-text";
|
|
2870
|
-
const styles$
|
|
2906
|
+
const styles$k = {
|
|
2871
2907
|
skeleton,
|
|
2872
2908
|
skeletonCircle,
|
|
2873
2909
|
skeletonText
|
|
@@ -2878,9 +2914,9 @@ const Skeleton = ({
|
|
|
2878
2914
|
height = "1em",
|
|
2879
2915
|
width
|
|
2880
2916
|
}) => {
|
|
2881
|
-
const classNames = cx(styles$
|
|
2882
|
-
[styles$
|
|
2883
|
-
[styles$
|
|
2917
|
+
const classNames = cx(styles$k.skeleton, {
|
|
2918
|
+
[styles$k.skeletonCircle]: circle,
|
|
2919
|
+
[styles$k.skeletonText]: text
|
|
2884
2920
|
});
|
|
2885
2921
|
return /* @__PURE__ */ jsx("div", { className: classNames, style: { height, width } });
|
|
2886
2922
|
};
|
|
@@ -2898,52 +2934,52 @@ const Accordion = ({
|
|
|
2898
2934
|
onToggle(e.newState === "closed" ? "close" : "open");
|
|
2899
2935
|
};
|
|
2900
2936
|
const variantMap2 = {
|
|
2901
|
-
basic: styles$
|
|
2902
|
-
info: styles$
|
|
2903
|
-
error: styles$
|
|
2904
|
-
warning: styles$
|
|
2905
|
-
success: styles$
|
|
2937
|
+
basic: styles$l.accordionBasic,
|
|
2938
|
+
info: styles$l.accordionInfo,
|
|
2939
|
+
error: styles$l.accordionError,
|
|
2940
|
+
warning: styles$l.accordionWarning,
|
|
2941
|
+
success: styles$l.accordionSuccess
|
|
2906
2942
|
};
|
|
2907
2943
|
return /* @__PURE__ */ jsxs(
|
|
2908
2944
|
"details",
|
|
2909
2945
|
{
|
|
2910
2946
|
onToggle: handleToggle,
|
|
2911
|
-
className: cx(className2, styles$
|
|
2912
|
-
[styles$
|
|
2913
|
-
[styles$
|
|
2947
|
+
className: cx(className2, styles$l.accordion, variantMap2[variant], {
|
|
2948
|
+
[styles$l.accordionWithIcon]: expandOnLeft,
|
|
2949
|
+
[styles$l.accordionNarrow]: narrow
|
|
2914
2950
|
}),
|
|
2915
2951
|
children: [
|
|
2916
|
-
/* @__PURE__ */ jsxs("summary", { className: styles$
|
|
2917
|
-
expandOnLeft && /* @__PURE__ */ jsx(Icon, { name: "chevron-down", className: styles$
|
|
2952
|
+
/* @__PURE__ */ jsxs("summary", { className: styles$l.accordionSummary, children: [
|
|
2953
|
+
expandOnLeft && /* @__PURE__ */ jsx(Icon, { name: "chevron-down", className: styles$l.accordionArrow }),
|
|
2918
2954
|
/* @__PURE__ */ jsx(Slot, { name: "icon" }),
|
|
2919
2955
|
/* @__PURE__ */ jsx(Slot, { name: "title", children: /* @__PURE__ */ jsx(Skeleton, {}) }),
|
|
2920
2956
|
!expandOnLeft && /* @__PURE__ */ jsx(
|
|
2921
2957
|
Icon,
|
|
2922
2958
|
{
|
|
2923
2959
|
name: "chevron-down",
|
|
2924
|
-
className: cx(styles$
|
|
2960
|
+
className: cx(styles$l.accordionArrow, styles$l.accordionArrowRight)
|
|
2925
2961
|
}
|
|
2926
2962
|
)
|
|
2927
2963
|
] }),
|
|
2928
|
-
/* @__PURE__ */ jsx("section", { className: styles$
|
|
2964
|
+
/* @__PURE__ */ jsx("section", { className: styles$l.accordionContent, children: /* @__PURE__ */ jsx(Slot, { name: "content", children: /* @__PURE__ */ jsx(Skeleton, {}) }) })
|
|
2929
2965
|
]
|
|
2930
2966
|
}
|
|
2931
2967
|
);
|
|
2932
2968
|
};
|
|
2933
|
-
const variantMap = {
|
|
2934
|
-
basic: styles$
|
|
2935
|
-
info: styles$
|
|
2936
|
-
error: styles$
|
|
2937
|
-
warning: styles$
|
|
2938
|
-
success: styles$
|
|
2969
|
+
const variantMap$1 = {
|
|
2970
|
+
basic: styles$m.alertBasic,
|
|
2971
|
+
info: styles$m.alertInfo,
|
|
2972
|
+
error: styles$m.alertError,
|
|
2973
|
+
warning: styles$m.alertWarning,
|
|
2974
|
+
success: styles$m.alertSuccess
|
|
2939
2975
|
};
|
|
2940
2976
|
const iconVariantMap = {
|
|
2941
2977
|
basic: "",
|
|
2942
2978
|
// does not exist
|
|
2943
|
-
info: styles$
|
|
2944
|
-
error: styles$
|
|
2945
|
-
warning: styles$
|
|
2946
|
-
success: styles$
|
|
2979
|
+
info: styles$m.alertIconInfo,
|
|
2980
|
+
error: styles$m.alertIconError,
|
|
2981
|
+
warning: styles$m.alertIconWarning,
|
|
2982
|
+
success: styles$m.alertIconSuccess
|
|
2947
2983
|
};
|
|
2948
2984
|
const Alert = ({
|
|
2949
2985
|
title,
|
|
@@ -2969,33 +3005,35 @@ const Alert = ({
|
|
|
2969
3005
|
if (isValidElement(icon)) {
|
|
2970
3006
|
return icon;
|
|
2971
3007
|
}
|
|
2972
|
-
return /* @__PURE__ */ jsx("span", { className: cx(styles$
|
|
3008
|
+
return /* @__PURE__ */ jsx("span", { className: cx(styles$m.alertIcon, iconVariantMap[variant]), children: /* @__PURE__ */ jsx(AlertIcon, { variant }) });
|
|
2973
3009
|
};
|
|
2974
3010
|
const renderedIcon = renderIcon();
|
|
2975
3011
|
if (type === "collapsible") {
|
|
2976
3012
|
return /* @__PURE__ */ jsxs(Accordion, { variant, onToggle: onToggle || void 0, narrow: true, className: className2, children: [
|
|
2977
3013
|
/* @__PURE__ */ jsx("template", { slot: "title", children: title }),
|
|
2978
3014
|
/* @__PURE__ */ jsx("template", { slot: "icon", children: renderedIcon }),
|
|
2979
|
-
/* @__PURE__ */
|
|
2980
|
-
|
|
3015
|
+
/* @__PURE__ */ jsxs("template", { slot: "content", children: [
|
|
3016
|
+
children2,
|
|
3017
|
+
/* @__PURE__ */ jsx("div", { className: styles$m.alertActions, children: actions })
|
|
3018
|
+
] })
|
|
2981
3019
|
] });
|
|
2982
3020
|
}
|
|
2983
3021
|
if (type === "callToAction") {
|
|
2984
3022
|
return /* @__PURE__ */ jsxs(
|
|
2985
3023
|
"div",
|
|
2986
3024
|
{
|
|
2987
|
-
className: cx(styles$
|
|
2988
|
-
[styles$
|
|
3025
|
+
className: cx(styles$m.alert, className2, variantMap$1[variant], {
|
|
3026
|
+
[styles$m.alertWithoutIcon]: !renderedIcon
|
|
2989
3027
|
}),
|
|
2990
3028
|
role: "alert",
|
|
2991
3029
|
"data-testid": testId,
|
|
2992
3030
|
children: [
|
|
2993
|
-
/* @__PURE__ */ jsxs("div", { className: styles$
|
|
3031
|
+
/* @__PURE__ */ jsxs("div", { className: styles$m.alertHeader, children: [
|
|
2994
3032
|
renderedIcon,
|
|
2995
|
-
title && /* @__PURE__ */ jsx("span", { className: styles$
|
|
2996
|
-
!!actions && /* @__PURE__ */ jsx("div", { className: styles$
|
|
3033
|
+
title && /* @__PURE__ */ jsx("span", { className: styles$m.alertTitle, children: title }),
|
|
3034
|
+
!!actions && /* @__PURE__ */ jsx("div", { className: styles$m.alertActions, children: actions })
|
|
2997
3035
|
] }),
|
|
2998
|
-
!!children2 && /* @__PURE__ */ jsx("div", { className: styles$
|
|
3036
|
+
!!children2 && /* @__PURE__ */ jsx("div", { className: styles$m.alertExplanation, children: children2 })
|
|
2999
3037
|
]
|
|
3000
3038
|
}
|
|
3001
3039
|
);
|
|
@@ -3003,15 +3041,15 @@ const Alert = ({
|
|
|
3003
3041
|
return /* @__PURE__ */ jsxs(
|
|
3004
3042
|
"div",
|
|
3005
3043
|
{
|
|
3006
|
-
className: cx(styles$
|
|
3007
|
-
[styles$
|
|
3044
|
+
className: cx(styles$m.alert, className2, variantMap$1[variant], {
|
|
3045
|
+
[styles$m.alertWithoutIcon]: !renderedIcon
|
|
3008
3046
|
}),
|
|
3009
3047
|
role: "alert",
|
|
3010
3048
|
"data-testid": testId,
|
|
3011
3049
|
children: [
|
|
3012
|
-
/* @__PURE__ */ jsxs("div", { className: styles$
|
|
3050
|
+
/* @__PURE__ */ jsxs("div", { className: styles$m.alertHeader, children: [
|
|
3013
3051
|
renderedIcon,
|
|
3014
|
-
title && /* @__PURE__ */ jsx("span", { className: styles$
|
|
3052
|
+
title && /* @__PURE__ */ jsx("span", { className: styles$m.alertTitle, children: title }),
|
|
3015
3053
|
type === "dismissible" && /* @__PURE__ */ jsx(
|
|
3016
3054
|
Button,
|
|
3017
3055
|
{
|
|
@@ -3019,12 +3057,12 @@ const Alert = ({
|
|
|
3019
3057
|
tertiary: true,
|
|
3020
3058
|
icon: "cross",
|
|
3021
3059
|
onClick: closeAlert,
|
|
3022
|
-
className: styles$
|
|
3060
|
+
className: styles$m.alertCloseButton
|
|
3023
3061
|
}
|
|
3024
3062
|
)
|
|
3025
3063
|
] }),
|
|
3026
|
-
!!children2 && /* @__PURE__ */ jsx("div", { className: styles$
|
|
3027
|
-
!!actions && /* @__PURE__ */ jsx("div", { className: styles$
|
|
3064
|
+
!!children2 && /* @__PURE__ */ jsx("div", { className: styles$m.alertExplanation, children: children2 }),
|
|
3065
|
+
!!actions && /* @__PURE__ */ jsx("div", { className: styles$m.alertActions, children: actions })
|
|
3028
3066
|
]
|
|
3029
3067
|
}
|
|
3030
3068
|
);
|
|
@@ -3111,28 +3149,29 @@ function ServerValidationErrors({
|
|
|
3111
3149
|
validationErrors,
|
|
3112
3150
|
formUtils
|
|
3113
3151
|
}) {
|
|
3152
|
+
const { i18n } = useI18nContext();
|
|
3114
3153
|
const validationErrorFieldNames = Object.keys(validationErrors || {});
|
|
3115
3154
|
const getValidationErrorMessage = useCallback(
|
|
3116
|
-
() =>
|
|
3155
|
+
() => i18n.get({
|
|
3117
3156
|
key: "fieldHasUnsupportedFormats",
|
|
3118
3157
|
values: { fieldName: formUtils.getLabel(validationErrorFieldNames[0]) }
|
|
3119
|
-
})
|
|
3158
|
+
}),
|
|
3120
3159
|
[formUtils, validationErrorFieldNames]
|
|
3121
3160
|
);
|
|
3122
|
-
return /* @__PURE__ */ jsx(Alert, { title:
|
|
3161
|
+
return /* @__PURE__ */ jsx(Alert, { title: i18n.get("informationCouldNotBeSubmitted"), variant: "error", children: (validationErrorFieldNames == null ? void 0 : validationErrorFieldNames.length) === 1 ? /* @__PURE__ */ jsxs("div", { "data-testid": "validation-error--case-1", children: [
|
|
3123
3162
|
getValidationErrorMessage(),
|
|
3124
3163
|
" ",
|
|
3125
3164
|
/* @__PURE__ */ jsx(
|
|
3126
3165
|
NavigateToFieldLink,
|
|
3127
3166
|
{
|
|
3128
3167
|
fieldName: validationErrorFieldNames[0],
|
|
3129
|
-
label:
|
|
3168
|
+
label: i18n.get("updateTheInformation")
|
|
3130
3169
|
}
|
|
3131
3170
|
),
|
|
3132
3171
|
" ",
|
|
3133
|
-
|
|
3172
|
+
i18n.get("andResubmit")
|
|
3134
3173
|
] }) : /* @__PURE__ */ jsxs("div", { "data-testid": "validation-error--case-2", children: [
|
|
3135
|
-
|
|
3174
|
+
i18n.get("someFieldsHaveUnsupportedFormatedUpdateInfoAndResubmit"),
|
|
3136
3175
|
/* @__PURE__ */ jsx("ul", { children: validationErrorFieldNames.map((fieldName) => /* @__PURE__ */ jsx(
|
|
3137
3176
|
"li",
|
|
3138
3177
|
{
|
|
@@ -3163,23 +3202,23 @@ function StateContextWatcher({
|
|
|
3163
3202
|
}
|
|
3164
3203
|
var DocumentType = /* @__PURE__ */ ((DocumentType2) => {
|
|
3165
3204
|
DocumentType2["BANK_STATEMENT"] = "bankStatement";
|
|
3205
|
+
DocumentType2["CONSTITUTIONAL_DOCUMENT"] = "constitutionalDocument";
|
|
3166
3206
|
DocumentType2["DRIVERS_LICENSE"] = "driversLicense";
|
|
3207
|
+
DocumentType2["DRIVING_LICENCE"] = "driving_licence";
|
|
3167
3208
|
DocumentType2["IDENTITY_CARD"] = "identityCard";
|
|
3209
|
+
DocumentType2["NATIONAL_IDENTITY_CARD"] = "national_identity_card";
|
|
3168
3210
|
DocumentType2["NATIONAL_ID_NUMBER"] = "nationalIdNumber";
|
|
3169
3211
|
DocumentType2["PASSPORT"] = "passport";
|
|
3170
3212
|
DocumentType2["PROOF_OF_ADDRESS"] = "proofOfAddress";
|
|
3213
|
+
DocumentType2["PROOF_OF_DIRECTOR"] = "proofOfDirector";
|
|
3214
|
+
DocumentType2["PROOF_OF_FUNDING"] = "proofOfFundingOrWealthSource";
|
|
3171
3215
|
DocumentType2["PROOF_OF_NATIONAL_ID_NUMBER"] = "proofOfNationalIdNumber";
|
|
3216
|
+
DocumentType2["PROOF_OF_ORGANIZATION_TAX_INFO"] = "proofOfOrganizationTaxInfo";
|
|
3217
|
+
DocumentType2["PROOF_OF_RELATIONSHIP"] = "proofOfRelationship";
|
|
3172
3218
|
DocumentType2["PROOF_OF_RESIDENCY"] = "proofOfResidency";
|
|
3173
3219
|
DocumentType2["REGISTRATION_DOCUMENT"] = "registrationDocument";
|
|
3174
|
-
DocumentType2["VAT_DOCUMENT"] = "vatDocument";
|
|
3175
|
-
DocumentType2["CONSTITUTIONAL_DOCUMENT"] = "constitutionalDocument";
|
|
3176
|
-
DocumentType2["DRIVING_LICENCE"] = "driving_licence";
|
|
3177
|
-
DocumentType2["NATIONAL_IDENTITY_CARD"] = "national_identity_card";
|
|
3178
3220
|
DocumentType2["RESIDENCE_PERMIT"] = "residence_permit";
|
|
3179
|
-
DocumentType2["
|
|
3180
|
-
DocumentType2["PROOF_OF_RELATIONSHIP"] = "proofOfRelationship";
|
|
3181
|
-
DocumentType2["PROOF_OF_DIRECTOR"] = "proofOfDirector";
|
|
3182
|
-
DocumentType2["PROOF_OF_FUNDING"] = "proofOfFundingOrWealthSource";
|
|
3221
|
+
DocumentType2["VAT_DOCUMENT"] = "vatDocument";
|
|
3183
3222
|
return DocumentType2;
|
|
3184
3223
|
})(DocumentType || {});
|
|
3185
3224
|
function getFormProps(props, innerFormId) {
|
|
@@ -3344,6 +3383,7 @@ var ExperimentNames = /* @__PURE__ */ ((ExperimentNames2) => {
|
|
|
3344
3383
|
ExperimentNames2["ShowCustomerSupportV4"] = "ShowCustomerSupportV4";
|
|
3345
3384
|
ExperimentNames2["EnableRegistrationAndTaxAbsentStatesV4"] = "EnableRegistrationAndTaxAbsentStatesV4";
|
|
3346
3385
|
ExperimentNames2["CredentialBankingWeightage_EmphasizeCredentialBankingFlow"] = "CredentialBankingWeightage_EmphasizeCredentialBankingFlow";
|
|
3386
|
+
ExperimentNames2["EnableManualCompanyTinVerification"] = "EnableManualCompanyTinVerification";
|
|
3347
3387
|
return ExperimentNames2;
|
|
3348
3388
|
})(ExperimentNames || {});
|
|
3349
3389
|
const debounce$1 = (func, delay) => {
|
|
@@ -4389,7 +4429,6 @@ class UserEvents {
|
|
|
4389
4429
|
subCategory: "hosted onboarding",
|
|
4390
4430
|
countryCode: void 0,
|
|
4391
4431
|
capabilities: void 0,
|
|
4392
|
-
legalEntityId: void 0,
|
|
4393
4432
|
task: void 0
|
|
4394
4433
|
};
|
|
4395
4434
|
this.sharedEventProperties = {};
|
|
@@ -4412,11 +4451,14 @@ class UserEvents {
|
|
|
4412
4451
|
this.notifySubscribers();
|
|
4413
4452
|
}
|
|
4414
4453
|
/**
|
|
4415
|
-
*
|
|
4454
|
+
* Adds an event with context specific to page-related events
|
|
4416
4455
|
*/
|
|
4417
|
-
|
|
4418
|
-
this.
|
|
4419
|
-
|
|
4456
|
+
addPageEvent(eventName, properties) {
|
|
4457
|
+
this.addEvent(eventName, {
|
|
4458
|
+
actionLevel: "page",
|
|
4459
|
+
page: this.sharedEventProperties.page,
|
|
4460
|
+
...properties
|
|
4461
|
+
});
|
|
4420
4462
|
}
|
|
4421
4463
|
/**
|
|
4422
4464
|
* Adds an event with context specific to field-related events
|
|
@@ -4428,6 +4470,13 @@ class UserEvents {
|
|
|
4428
4470
|
...properties
|
|
4429
4471
|
});
|
|
4430
4472
|
}
|
|
4473
|
+
/**
|
|
4474
|
+
* Starts a timer for an event to measure the time it takes for an event to occur. Time is ended when `addEvent` is executed with the same key
|
|
4475
|
+
*/
|
|
4476
|
+
startEvent(eventName) {
|
|
4477
|
+
this.add({ type: "start_event", name: eventName });
|
|
4478
|
+
this.notifySubscribers();
|
|
4479
|
+
}
|
|
4431
4480
|
/**
|
|
4432
4481
|
* Subscribes a callback to analytics events. It gets called every time
|
|
4433
4482
|
* one of the above public methods get called, and the event data is passed back as an array.
|
|
@@ -5034,7 +5083,7 @@ var hasOwnProperty = objectProto$1.hasOwnProperty;
|
|
|
5034
5083
|
var nativeObjectToString$1 = objectProto$1.toString;
|
|
5035
5084
|
var symToStringTag$1 = Symbol$1 ? Symbol$1.toStringTag : void 0;
|
|
5036
5085
|
function getRawTag(value) {
|
|
5037
|
-
var isOwn = hasOwnProperty.call(value, symToStringTag$1),
|
|
5086
|
+
var isOwn = hasOwnProperty.call(value, symToStringTag$1), tag2 = value[symToStringTag$1];
|
|
5038
5087
|
try {
|
|
5039
5088
|
value[symToStringTag$1] = void 0;
|
|
5040
5089
|
var unmasked = true;
|
|
@@ -5043,7 +5092,7 @@ function getRawTag(value) {
|
|
|
5043
5092
|
var result = nativeObjectToString$1.call(value);
|
|
5044
5093
|
if (unmasked) {
|
|
5045
5094
|
if (isOwn) {
|
|
5046
|
-
value[symToStringTag$1] =
|
|
5095
|
+
value[symToStringTag$1] = tag2;
|
|
5047
5096
|
} else {
|
|
5048
5097
|
delete value[symToStringTag$1];
|
|
5049
5098
|
}
|
|
@@ -5191,7 +5240,7 @@ const getAssociatedLeAnalyticsPayload = ({
|
|
|
5191
5240
|
associatedLegalEntityOrgType: associatedLegalEntityOrg.type
|
|
5192
5241
|
} : {}
|
|
5193
5242
|
});
|
|
5194
|
-
const debouncedInputEvent
|
|
5243
|
+
const debouncedInputEvent = debounce(
|
|
5195
5244
|
(properties) => userEvents.addFieldEvent("Interacted with form field", properties),
|
|
5196
5245
|
500
|
|
5197
5246
|
);
|
|
@@ -5343,7 +5392,7 @@ const Select = ({
|
|
|
5343
5392
|
(e) => {
|
|
5344
5393
|
const { value } = e.target;
|
|
5345
5394
|
if (enableTracking) {
|
|
5346
|
-
debouncedInputEvent
|
|
5395
|
+
debouncedInputEvent({ actionType: "input", field: name });
|
|
5347
5396
|
}
|
|
5348
5397
|
if (isSearch) debouncedOnSearch(value);
|
|
5349
5398
|
if (!onSearchTextChange) {
|
|
@@ -5673,7 +5722,7 @@ const InputBase = forwardRef((props, ref) => {
|
|
|
5673
5722
|
const handleInput = (e) => {
|
|
5674
5723
|
var _a2;
|
|
5675
5724
|
if (enableTracking) {
|
|
5676
|
-
debouncedInputEvent
|
|
5725
|
+
debouncedInputEvent({ actionType: "input", field: name });
|
|
5677
5726
|
}
|
|
5678
5727
|
e.target.value = convertFullToHalf(e.target.value);
|
|
5679
5728
|
(_a2 = props.onInput) == null ? void 0 : _a2.call(props, e);
|
|
@@ -11693,7 +11742,8 @@ const businessDetailsBase = {
|
|
|
11693
11742
|
registrationNumber: { rule: "countryRequiresRegistrationNumberForCompanies" },
|
|
11694
11743
|
exemptedFromRegistrationNumber: { rule: "companyRegistrationNumberExemptionAllowed" },
|
|
11695
11744
|
eInvoicingCode: { rule: "isEInvoicingCodeEnabled" },
|
|
11696
|
-
countryOfGoverningLaw: { rule: "countryOfGoverningLawRequired" }
|
|
11745
|
+
countryOfGoverningLaw: { rule: "countryOfGoverningLawRequired" },
|
|
11746
|
+
taxDocument: { rule: "ifCountryUsAndTinFailed" }
|
|
11697
11747
|
};
|
|
11698
11748
|
const taxInformationBase$1 = {
|
|
11699
11749
|
vatNumber: { rule: "countryUsesVat" },
|
|
@@ -12559,10 +12609,6 @@ function Dropzone(props) {
|
|
|
12559
12609
|
] });
|
|
12560
12610
|
}
|
|
12561
12611
|
const logger$M = createLogger("TextArea");
|
|
12562
|
-
const debouncedInputEvent = debounce(
|
|
12563
|
-
(properties) => userEvents.addFieldEvent("Interacted with form field", properties),
|
|
12564
|
-
500
|
|
12565
|
-
);
|
|
12566
12612
|
function TextArea(props) {
|
|
12567
12613
|
const { classNameModifiers, uniqueId, ...passedProps } = props;
|
|
12568
12614
|
const {
|
|
@@ -13014,7 +13060,7 @@ const financialInfoValidationRules = {
|
|
|
13014
13060
|
}
|
|
13015
13061
|
};
|
|
13016
13062
|
const financialInformationReportedValueOptions = "adyen-kyc-financial-information-reported-value-options";
|
|
13017
|
-
const styles$
|
|
13063
|
+
const styles$j = {
|
|
13018
13064
|
financialInformationReportedValueOptions
|
|
13019
13065
|
};
|
|
13020
13066
|
const logger$L = createLogger("InputCurrency");
|
|
@@ -13061,7 +13107,7 @@ const InputCurrency = ({
|
|
|
13061
13107
|
};
|
|
13062
13108
|
const reportedValue = "adyen-kyc-reported-value";
|
|
13063
13109
|
const reportedValueInput = "adyen-kyc-reported-value-input";
|
|
13064
|
-
const styles$
|
|
13110
|
+
const styles$i = {
|
|
13065
13111
|
reportedValue,
|
|
13066
13112
|
reportedValueInput
|
|
13067
13113
|
};
|
|
@@ -13076,7 +13122,7 @@ const ReportedValue = ({
|
|
|
13076
13122
|
isValid
|
|
13077
13123
|
}) => {
|
|
13078
13124
|
const { i18n } = useI18nContext();
|
|
13079
|
-
return /* @__PURE__ */ jsx("div", { className: styles$
|
|
13125
|
+
return /* @__PURE__ */ jsx("div", { className: styles$i.reportedValue, children: /* @__PURE__ */ jsx(Field, { name: fieldName, errorMessage, isValid, helper, children: (childProps) => /* @__PURE__ */ jsx(
|
|
13080
13126
|
InputCurrency,
|
|
13081
13127
|
{
|
|
13082
13128
|
...childProps,
|
|
@@ -13084,7 +13130,7 @@ const ReportedValue = ({
|
|
|
13084
13130
|
currency,
|
|
13085
13131
|
amount,
|
|
13086
13132
|
onAmountChanged,
|
|
13087
|
-
className: styles$
|
|
13133
|
+
className: styles$i.reportedValueInput,
|
|
13088
13134
|
"aria-label": label
|
|
13089
13135
|
}
|
|
13090
13136
|
) }) });
|
|
@@ -13221,7 +13267,7 @@ function FinancialInformation(props) {
|
|
|
13221
13267
|
],
|
|
13222
13268
|
onChange: updateReportedValueOption,
|
|
13223
13269
|
showContentOnlyOnSelected: true,
|
|
13224
|
-
className: styles$
|
|
13270
|
+
className: styles$j.financialInformationReportedValueOptions
|
|
13225
13271
|
}
|
|
13226
13272
|
)
|
|
13227
13273
|
}
|
|
@@ -13271,7 +13317,6 @@ const COUNTRIES_WITH_HOUSE_NUMBER_FIRST = [
|
|
|
13271
13317
|
CountryCodes.UnitedKingdom,
|
|
13272
13318
|
CountryCodes.France
|
|
13273
13319
|
];
|
|
13274
|
-
const COUNTRIES_WITH_COMMA_SEPARATED = [CountryCodes.Spain];
|
|
13275
13320
|
const ADDRESS_SCHEMAS = {
|
|
13276
13321
|
[CountryCodes.Australia]: [COUNTRY, ADDRESS, OTHER_ADDRESS_INFORMATION, CITY, STATE, POSTAL_CODE],
|
|
13277
13322
|
[CountryCodes.Canada]: [COUNTRY, ADDRESS, OTHER_ADDRESS_INFORMATION, CITY, POSTAL_CODE, STATE],
|
|
@@ -14173,8 +14218,7 @@ function AddressForm(props) {
|
|
|
14173
14218
|
if (!street && line1) return handleChangeFor("address", "input")(line1);
|
|
14174
14219
|
if (hasHouseNumber) {
|
|
14175
14220
|
const isHouseNumberFirst = data.country ? COUNTRIES_WITH_HOUSE_NUMBER_FIRST.includes(data.country) : false;
|
|
14176
|
-
const
|
|
14177
|
-
const formattedAddress = isHouseNumberFirst ? `${houseNumberOrName}${needsComma ? ", " : " "}${street}` : `${street}${needsComma ? ", " : " "}${houseNumberOrName}`;
|
|
14221
|
+
const formattedAddress = isHouseNumberFirst ? `${houseNumberOrName}${" "}${street}` : `${street}${" "}${houseNumberOrName}`;
|
|
14178
14222
|
return handleChangeFor("address", "input")(formattedAddress);
|
|
14179
14223
|
}
|
|
14180
14224
|
return handleChangeFor("address", "input")(street);
|
|
@@ -14376,8 +14420,7 @@ function FieldContainer({
|
|
|
14376
14420
|
if (!street && line1) return handleChangeFor("address", "input")(line1);
|
|
14377
14421
|
if (hasHouseNumber) {
|
|
14378
14422
|
const isHouseNumberFirst = data.country ? COUNTRIES_WITH_HOUSE_NUMBER_FIRST.includes(data.country) : false;
|
|
14379
|
-
const
|
|
14380
|
-
const formattedAddress = isHouseNumberFirst ? `${houseNumberOrName}${needsComma ? ", " : " "}${street}` : `${street}${needsComma ? ", " : " "}${houseNumberOrName}`;
|
|
14423
|
+
const formattedAddress = isHouseNumberFirst ? `${houseNumberOrName}${" "}${street}` : `${street}${" "}${houseNumberOrName}`;
|
|
14381
14424
|
return handleChangeFor("address", "input")(formattedAddress);
|
|
14382
14425
|
}
|
|
14383
14426
|
return handleChangeFor("address", "input")(street);
|
|
@@ -14662,17 +14705,13 @@ function Address({
|
|
|
14662
14705
|
trustedFields,
|
|
14663
14706
|
shouldValidate
|
|
14664
14707
|
});
|
|
14665
|
-
useEffect(
|
|
14666
|
-
()
|
|
14667
|
-
|
|
14668
|
-
|
|
14669
|
-
|
|
14670
|
-
|
|
14671
|
-
|
|
14672
|
-
},
|
|
14673
|
-
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
14674
|
-
[verifiedAddress]
|
|
14675
|
-
);
|
|
14708
|
+
useEffect(() => {
|
|
14709
|
+
if (verifiedAddress) {
|
|
14710
|
+
entriesOf(verifiedAddress).forEach(([key, value]) => {
|
|
14711
|
+
if (formData[key] !== value) handleChangeFor(key, "input")(value);
|
|
14712
|
+
});
|
|
14713
|
+
}
|
|
14714
|
+
}, [verifiedAddress]);
|
|
14676
14715
|
const formUtils = createFormUtils(
|
|
14677
14716
|
{
|
|
14678
14717
|
labels: labels2,
|
|
@@ -15761,7 +15800,8 @@ const rules$3 = ({
|
|
|
15761
15800
|
taskType,
|
|
15762
15801
|
isExperimentEnabled = () => false,
|
|
15763
15802
|
accountHolder,
|
|
15764
|
-
rootLegalEntity
|
|
15803
|
+
rootLegalEntity,
|
|
15804
|
+
tinMatched
|
|
15765
15805
|
}) => ({
|
|
15766
15806
|
countryRequiresStateOrProvince: () => {
|
|
15767
15807
|
if (COUNTRIES_WITH_STATES_DATASET.includes(country)) {
|
|
@@ -15933,6 +15973,11 @@ const rules$3 = ({
|
|
|
15933
15973
|
if (isExperimentEnabled("EnableEInvoicingCodeField") && COUNTRIES_REQUIRING_E_INVOICING_CODE.includes(country)) {
|
|
15934
15974
|
return "REQUIRED";
|
|
15935
15975
|
}
|
|
15976
|
+
},
|
|
15977
|
+
ifCountryUsAndTinFailed: () => {
|
|
15978
|
+
if (isExperimentEnabled("EnableManualCompanyTinVerification") && isExperimentEnabled("EnableNewBusinessDetailsFlow") && tinMatched === false && country === CountryCodes.UnitedStates) {
|
|
15979
|
+
return "REQUIRED";
|
|
15980
|
+
}
|
|
15936
15981
|
}
|
|
15937
15982
|
});
|
|
15938
15983
|
const logger$I = createLogger("mapPayoutAccountSchemaToApiBankAccount");
|
|
@@ -16060,6 +16105,11 @@ const getObscuredAccountNumber = ({
|
|
|
16060
16105
|
accountIdentifier,
|
|
16061
16106
|
realLastFour
|
|
16062
16107
|
}) => realLastFour ? `*******${realLastFour}` : accountIdentifier;
|
|
16108
|
+
var EntityType = /* @__PURE__ */ ((EntityType2) => {
|
|
16109
|
+
EntityType2["BANK_ACCOUNT"] = "BankAccount";
|
|
16110
|
+
EntityType2["LEGAL_ENTITY"] = "LegalEntity";
|
|
16111
|
+
return EntityType2;
|
|
16112
|
+
})(EntityType || {});
|
|
16063
16113
|
const mandatoryApiFields = {
|
|
16064
16114
|
INDIVIDUAL: [
|
|
16065
16115
|
"personalDetails.firstName",
|
|
@@ -16341,7 +16391,7 @@ const remediationIndividualApiKeyMapping = {
|
|
|
16341
16391
|
[DocumentType.PROOF_OF_RELATIONSHIP]: "proofOfRelationship.proofOfRelationship"
|
|
16342
16392
|
};
|
|
16343
16393
|
const remediationPayoutApiKeyMapping = {
|
|
16344
|
-
|
|
16394
|
+
[EntityType.BANK_ACCOUNT]: "payoutAccountDetails",
|
|
16345
16395
|
...payoutComponentKeyMapping,
|
|
16346
16396
|
[DocumentType.BANK_STATEMENT]: "payoutAccountDocuments.bankStatementDocument"
|
|
16347
16397
|
};
|
|
@@ -17224,7 +17274,7 @@ const useIdVerificationToken = ({
|
|
|
17224
17274
|
};
|
|
17225
17275
|
const loaderWrapperLoader = "adyen-kyc-loader-wrapper-loader";
|
|
17226
17276
|
const loaderWrapperLoaderActive = "adyen-kyc-loader-wrapper-loader-active";
|
|
17227
|
-
const styles$
|
|
17277
|
+
const styles$h = {
|
|
17228
17278
|
loaderWrapperLoader,
|
|
17229
17279
|
loaderWrapperLoaderActive
|
|
17230
17280
|
};
|
|
@@ -17239,13 +17289,13 @@ const LoaderWrapper = ({
|
|
|
17239
17289
|
const opacitySyle = status === "loading" ? {
|
|
17240
17290
|
opacity: formOpacityWhenLoading
|
|
17241
17291
|
} : { opacity: 1 };
|
|
17242
|
-
const loaderWrapperClass = cx(styles$
|
|
17243
|
-
[styles$
|
|
17292
|
+
const loaderWrapperClass = cx(styles$h.loaderWrapperLoader, {
|
|
17293
|
+
[styles$h.loaderWrapperLoaderActive]: status === "loading" && showSpinner
|
|
17244
17294
|
});
|
|
17245
|
-
const overlayClass = cx(styles$
|
|
17295
|
+
const overlayClass = cx(styles$h.loaderWrapper, className2);
|
|
17246
17296
|
return /* @__PURE__ */ jsxs("div", { className: overlayClass, style: { position: "relative" }, children: [
|
|
17247
17297
|
/* @__PURE__ */ jsx("div", { className: loaderWrapperClass, children: /* @__PURE__ */ jsx(Loader, { size: loaderSize }) }),
|
|
17248
|
-
/* @__PURE__ */ jsx("div", { className: styles$
|
|
17298
|
+
/* @__PURE__ */ jsx("div", { className: styles$h.loaderWrapperForm, style: opacitySyle, children: children2 })
|
|
17249
17299
|
] });
|
|
17250
17300
|
};
|
|
17251
17301
|
const containerId = "adyen-kyc-id-verification";
|
|
@@ -23074,11 +23124,6 @@ const getCountrySpecificTrustTypeOptions = (country) => {
|
|
|
23074
23124
|
return countrySpecificTrustTypeOption;
|
|
23075
23125
|
});
|
|
23076
23126
|
};
|
|
23077
|
-
var EntityType = /* @__PURE__ */ ((EntityType2) => {
|
|
23078
|
-
EntityType2["BANK_ACCOUNT"] = "BankAccount";
|
|
23079
|
-
EntityType2["LEGAL_ENTITY"] = "LegalEntity";
|
|
23080
|
-
return EntityType2;
|
|
23081
|
-
})(EntityType || {});
|
|
23082
23127
|
var VerificationStatus = /* @__PURE__ */ ((VerificationStatus2) => {
|
|
23083
23128
|
VerificationStatus2["VALID"] = "valid";
|
|
23084
23129
|
VerificationStatus2["PENDING"] = "pending";
|
|
@@ -27719,7 +27764,7 @@ const preferInstantVerificationMethod = "adyen-kyc-prefer-instant-verification-m
|
|
|
27719
27764
|
const preferInstantVerificationMethodCard = "adyen-kyc-prefer-instant-verification-method-card";
|
|
27720
27765
|
const preferInstantVerificationMethodInstantButton = "adyen-kyc-prefer-instant-verification-method-instant-button";
|
|
27721
27766
|
const preferInstantVerificationMethodModalFooter = "adyen-kyc-prefer-instant-verification-method-modal-footer";
|
|
27722
|
-
const styles$
|
|
27767
|
+
const styles$g = {
|
|
27723
27768
|
preferInstantVerificationMethod,
|
|
27724
27769
|
preferInstantVerificationMethodCard,
|
|
27725
27770
|
preferInstantVerificationMethodInstantButton,
|
|
@@ -27799,7 +27844,7 @@ const modalFooter = "adyen-kyc-modal-footer";
|
|
|
27799
27844
|
const modalButton = "adyen-kyc-modal-button";
|
|
27800
27845
|
const modalLarge = "adyen-kyc-modal-large";
|
|
27801
27846
|
const modalFullscreen = "adyen-kyc-modal-fullscreen";
|
|
27802
|
-
const styles$
|
|
27847
|
+
const styles$f = {
|
|
27803
27848
|
modal,
|
|
27804
27849
|
modalSmall,
|
|
27805
27850
|
modalMain,
|
|
@@ -27811,7 +27856,12 @@ const styles$c = {
|
|
|
27811
27856
|
modalLarge,
|
|
27812
27857
|
modalFullscreen
|
|
27813
27858
|
};
|
|
27814
|
-
const Modal = ({
|
|
27859
|
+
const Modal = ({
|
|
27860
|
+
children: children2,
|
|
27861
|
+
size = "medium",
|
|
27862
|
+
onClose,
|
|
27863
|
+
showCloseButton = true
|
|
27864
|
+
}) => {
|
|
27815
27865
|
const dialogRef = useRef(null);
|
|
27816
27866
|
useLayoutEffect(() => {
|
|
27817
27867
|
const dialogElement = dialogRef.current;
|
|
@@ -27832,23 +27882,23 @@ const Modal = ({ children: children2, size = "medium", onClose }) => {
|
|
|
27832
27882
|
"dialog",
|
|
27833
27883
|
{
|
|
27834
27884
|
ref: dialogRef,
|
|
27835
|
-
className: cx(styles$
|
|
27836
|
-
[styles$
|
|
27837
|
-
[styles$
|
|
27838
|
-
[styles$
|
|
27885
|
+
className: cx(styles$f.modal, {
|
|
27886
|
+
[styles$f.modalSmall]: size === "small",
|
|
27887
|
+
[styles$f.modalLarge]: size === "large",
|
|
27888
|
+
[styles$f.modalFullscreen]: size === "fullscreen"
|
|
27839
27889
|
}),
|
|
27840
27890
|
onClose,
|
|
27841
27891
|
role: "dialog",
|
|
27842
|
-
children: /* @__PURE__ */ jsx("div", { className: styles$
|
|
27843
|
-
/* @__PURE__ */ jsx("div", { className: styles$
|
|
27892
|
+
children: /* @__PURE__ */ jsx("div", { className: styles$f.modalWrapper, children: /* @__PURE__ */ jsxs("div", { className: styles$f.modalMain, children: [
|
|
27893
|
+
showCloseButton && /* @__PURE__ */ jsx("div", { className: styles$f.modalButton, children: /* @__PURE__ */ jsx(Button, { tertiary: true, ariaLabel: "close", icon: "cross", onClick: onClose, shaded: true }) }),
|
|
27844
27894
|
children2
|
|
27845
27895
|
] }) })
|
|
27846
27896
|
}
|
|
27847
27897
|
);
|
|
27848
27898
|
};
|
|
27849
|
-
const ModalHeader = ({ children: children2 }) => /* @__PURE__ */ jsx("header", { className: styles$
|
|
27850
|
-
const ModalContent = ({ children: children2 }) => /* @__PURE__ */ jsx("section", { className: styles$
|
|
27851
|
-
const ModalFooter = ({ children: children2 }) => /* @__PURE__ */ jsx("footer", { className: styles$
|
|
27899
|
+
const ModalHeader = ({ children: children2 }) => /* @__PURE__ */ jsx("header", { className: styles$f.modalHeader, children: children2 });
|
|
27900
|
+
const ModalContent = ({ children: children2 }) => /* @__PURE__ */ jsx("section", { className: styles$f.modalContent, children: children2 });
|
|
27901
|
+
const ModalFooter = ({ children: children2 }) => /* @__PURE__ */ jsx("footer", { className: styles$f.modalFooter, children: children2 });
|
|
27852
27902
|
const PreferInstantVerificationMethod = ({
|
|
27853
27903
|
loadingStatus,
|
|
27854
27904
|
provider,
|
|
@@ -27917,7 +27967,7 @@ const PreferInstantVerificationMethod = ({
|
|
|
27917
27967
|
label: hideVerificationWidget ? i18n.get("addAccountWith", {
|
|
27918
27968
|
values: { providerName: iconName ? "" : provider.name }
|
|
27919
27969
|
}) : void 0,
|
|
27920
|
-
className: styles$
|
|
27970
|
+
className: styles$g.preferInstantVerificationMethodInstantButton,
|
|
27921
27971
|
onClick: handleClickInstantButton,
|
|
27922
27972
|
disabled: bankInfoValidated,
|
|
27923
27973
|
loading: !hideVerificationWidget,
|
|
@@ -27925,8 +27975,8 @@ const PreferInstantVerificationMethod = ({
|
|
|
27925
27975
|
iconPosition: "right",
|
|
27926
27976
|
block: true
|
|
27927
27977
|
}
|
|
27928
|
-
) : /* @__PURE__ */ jsx(Card, { background: "secondary", className: styles$
|
|
27929
|
-
return /* @__PURE__ */ jsxs("div", { className: styles$
|
|
27978
|
+
) : /* @__PURE__ */ jsx(Card, { background: "secondary", className: styles$g.preferInstantVerificationMethodCard, children: i18n.get("unfortunatelyAnInstantProvider") });
|
|
27979
|
+
return /* @__PURE__ */ jsxs("div", { className: styles$g.preferInstantVerificationMethod, children: [
|
|
27930
27980
|
loadingStatus === "loading" ? /* @__PURE__ */ jsx("div", { className: "adyen-kyc-u-margin-bottom-8", children: /* @__PURE__ */ jsx(Skeleton, { height: "2.5rem" }) }) : InstantButton,
|
|
27931
27981
|
/* @__PURE__ */ jsx(
|
|
27932
27982
|
Button,
|
|
@@ -27964,7 +28014,7 @@ const PreferInstantVerificationMethod = ({
|
|
|
27964
28014
|
isModalOpen ? /* @__PURE__ */ jsxs(Modal, { size: "small", onClose: () => setIsModalOpen(false), children: [
|
|
27965
28015
|
/* @__PURE__ */ jsx(ModalHeader, { children: i18n.get("manuallyAddAccountQuestion") }),
|
|
27966
28016
|
/* @__PURE__ */ jsx(ModalContent, { children: i18n.get("addingAndVerifiyingABankAccount") }),
|
|
27967
|
-
/* @__PURE__ */ jsx(ModalFooter, { children: /* @__PURE__ */ jsxs("div", { className: styles$
|
|
28017
|
+
/* @__PURE__ */ jsx(ModalFooter, { children: /* @__PURE__ */ jsxs("div", { className: styles$g.preferInstantVerificationMethodModalFooter, children: [
|
|
27968
28018
|
/* @__PURE__ */ jsx(Button, { label: i18n.get("yesContinue"), onClick: handleClickContinue, secondary: true }),
|
|
27969
28019
|
/* @__PURE__ */ jsx(Button, { onClick: () => setIsModalOpen(false), label: i18n.get("cancel") })
|
|
27970
28020
|
] }) })
|
|
@@ -29410,22 +29460,16 @@ const getComponentMappingFromLEFieldPath = (context, entityType, isExperimentEna
|
|
|
29410
29460
|
}
|
|
29411
29461
|
switch (entityType) {
|
|
29412
29462
|
case LegalEntityType.INDIVIDUAL:
|
|
29413
|
-
return remediationIndividualApiKeyMapping[context.key];
|
|
29463
|
+
return context.key in remediationIndividualApiKeyMapping ? remediationIndividualApiKeyMapping[context.key] : void 0;
|
|
29414
29464
|
case LegalEntityType.ORGANIZATION:
|
|
29415
|
-
return (isExperimentEnabled == null ? void 0 : isExperimentEnabled("EnableNewBusinessDetailsFlow")) ?
|
|
29416
|
-
// @ts-ignore
|
|
29417
|
-
remediationBusinessDetailsApiKeyMapping[context.key]
|
|
29418
|
-
) : (
|
|
29419
|
-
// @ts-ignore
|
|
29420
|
-
remediationCompanyApiKeyMapping[context.key]
|
|
29421
|
-
);
|
|
29465
|
+
return (isExperimentEnabled == null ? void 0 : isExperimentEnabled("EnableNewBusinessDetailsFlow")) ? context.key in remediationBusinessDetailsApiKeyMapping ? remediationBusinessDetailsApiKeyMapping[context.key] : void 0 : context.key in remediationCompanyApiKeyMapping ? remediationCompanyApiKeyMapping[context.key] : void 0;
|
|
29422
29466
|
case EntityType.BANK_ACCOUNT:
|
|
29423
|
-
return remediationPayoutApiKeyMapping[context.key];
|
|
29467
|
+
return context.key in remediationPayoutApiKeyMapping ? remediationPayoutApiKeyMapping[context.key] : void 0;
|
|
29424
29468
|
case LegalEntityType.SOLE_PROPRIETORSHIP:
|
|
29425
|
-
return remediationSolePropKeyMapping[context.key];
|
|
29469
|
+
return context.key in remediationSolePropKeyMapping ? remediationSolePropKeyMapping[context.key] : void 0;
|
|
29426
29470
|
case LegalEntityType.TRUST:
|
|
29427
29471
|
default:
|
|
29428
|
-
return remediationTrustKeyMapping[context.key];
|
|
29472
|
+
return context.key in remediationTrustKeyMapping ? remediationTrustKeyMapping[context.key] : void 0;
|
|
29429
29473
|
}
|
|
29430
29474
|
};
|
|
29431
29475
|
const getRemediationsWithFormsAndFields = (remediatingActions, entityType, isExperimentEnabled) => {
|
|
@@ -29679,11 +29723,12 @@ function VerificationErrors({
|
|
|
29679
29723
|
formUtils
|
|
29680
29724
|
}) {
|
|
29681
29725
|
var _a2, _b2;
|
|
29682
|
-
const
|
|
29726
|
+
const { i18n } = useI18nContext();
|
|
29727
|
+
const getErrorMessage = (errorCode) => i18n.get(`errorMessage_${errorCode}`);
|
|
29683
29728
|
const getRemediationMessage = (remediationActions, uploadFieldCollection) => {
|
|
29684
29729
|
var _a3, _b3;
|
|
29685
29730
|
if ((remediationActions == null ? void 0 : remediationActions.length) === 1) {
|
|
29686
|
-
return
|
|
29731
|
+
return i18n.get(`remediationMessage_${remediationActions[0].code}`);
|
|
29687
29732
|
}
|
|
29688
29733
|
const uploadFields = uploadFieldCollection && Object.keys(uploadFieldCollection);
|
|
29689
29734
|
let uploadFilesCopy;
|
|
@@ -29697,7 +29742,7 @@ function VerificationErrors({
|
|
|
29697
29742
|
NavigateToFieldLink,
|
|
29698
29743
|
{
|
|
29699
29744
|
fieldName: uploadField,
|
|
29700
|
-
label:
|
|
29745
|
+
label: i18n.get(
|
|
29701
29746
|
`remediationMessage_${(_a4 = uploadFieldCollection[uploadField]) == null ? void 0 : _a4.remediation.code}`
|
|
29702
29747
|
)
|
|
29703
29748
|
}
|
|
@@ -29710,14 +29755,14 @@ function VerificationErrors({
|
|
|
29710
29755
|
] });
|
|
29711
29756
|
} else {
|
|
29712
29757
|
const firstUploadField = uploadFields[0];
|
|
29713
|
-
const label = ` ${(_b3 =
|
|
29758
|
+
const label = ` ${(_b3 = i18n.get(`remediationMessage_${(_a3 = uploadFieldCollection[firstUploadField]) == null ? void 0 : _a3.remediation.code}`)) == null ? void 0 : _b3.toLowerCase()}`;
|
|
29714
29759
|
uploadFilesCopy = /* @__PURE__ */ jsx(NavigateToFieldLink, { fieldName: firstUploadField, label });
|
|
29715
29760
|
}
|
|
29716
29761
|
}
|
|
29717
29762
|
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
29718
|
-
|
|
29763
|
+
i18n.get("reviewTheInformationBelowAndCorrectMistakesOr"),
|
|
29719
29764
|
uploadFilesCopy,
|
|
29720
|
-
|
|
29765
|
+
i18n.get("thenResubmit")
|
|
29721
29766
|
] });
|
|
29722
29767
|
};
|
|
29723
29768
|
let verificationErrorMsg;
|
|
@@ -29758,14 +29803,14 @@ function VerificationErrors({
|
|
|
29758
29803
|
);
|
|
29759
29804
|
} else if (childErrorCodes.length === 2) {
|
|
29760
29805
|
verificationErrorMsg = /* @__PURE__ */ jsxs("div", { "data-testid": "verification-error--case-2-2", children: [
|
|
29761
|
-
|
|
29806
|
+
i18n.get("weFoundTheFollowingIssues"),
|
|
29762
29807
|
/* @__PURE__ */ jsx("ul", { children: childErrorCodes.map((subErrorCode) => /* @__PURE__ */ jsx("li", { children: /* @__PURE__ */ jsx("span", { children: getErrorMessage(subErrorCode) }) }, subErrorCode)) }),
|
|
29763
29808
|
/* @__PURE__ */ jsx("span", { children: getRemediationMessage(onlyChildRemediationActions, fileUploadRemediationFields) })
|
|
29764
29809
|
] });
|
|
29765
29810
|
} else {
|
|
29766
29811
|
verificationErrorMsg = /* @__PURE__ */ jsx("div", { "data-testid": "verification-error--case-2-3", children: getRemediationMessage(onlyChildRemediationActions, fileUploadRemediationFields) });
|
|
29767
29812
|
}
|
|
29768
|
-
const defaultHeading = parentCode ? getErrorMessage(parentCode) :
|
|
29813
|
+
const defaultHeading = parentCode ? getErrorMessage(parentCode) : i18n.get("correctErrorsResubmit");
|
|
29769
29814
|
return /* @__PURE__ */ jsx(Alert, { title: defaultHeading, variant: "error", children: verificationErrorMsg });
|
|
29770
29815
|
}
|
|
29771
29816
|
function ErrorPanel({
|
|
@@ -29834,9 +29879,9 @@ function Summary({
|
|
|
29834
29879
|
icon: "edit",
|
|
29835
29880
|
onClick: () => {
|
|
29836
29881
|
trackNavigation2({
|
|
29837
|
-
|
|
29882
|
+
actionType: "edit",
|
|
29838
29883
|
toForm: formName,
|
|
29839
|
-
|
|
29884
|
+
label: "Pencil icon"
|
|
29840
29885
|
});
|
|
29841
29886
|
editForm(formId);
|
|
29842
29887
|
},
|
|
@@ -29876,6 +29921,9 @@ function Summary({
|
|
|
29876
29921
|
Object.entries(innerForms).forEach(([innerFormName, innerFormFieldData]) => {
|
|
29877
29922
|
const formName = i18n.get(labelData == null ? void 0 : labelData[innerFormName]) || i18n.get(innerFormName);
|
|
29878
29923
|
if (typeof innerFormFieldData === "object" && innerFormFieldData !== null) {
|
|
29924
|
+
if (Object.values(innerFormFieldData).every((value) => isEmpty$1(value))) {
|
|
29925
|
+
return;
|
|
29926
|
+
}
|
|
29879
29927
|
dataList.push(renderSummarySection(innerFormFieldData, labelData, formName, parentFormId));
|
|
29880
29928
|
}
|
|
29881
29929
|
});
|
|
@@ -29932,18 +29980,18 @@ function Summary({
|
|
|
29932
29980
|
] });
|
|
29933
29981
|
}
|
|
29934
29982
|
const trackNavigation = ({
|
|
29935
|
-
|
|
29983
|
+
actionType,
|
|
29936
29984
|
toForm,
|
|
29937
|
-
|
|
29985
|
+
label,
|
|
29986
|
+
returnValue,
|
|
29938
29987
|
baseTrackingPayload
|
|
29939
29988
|
}) => {
|
|
29940
|
-
userEvents.
|
|
29941
|
-
|
|
29942
|
-
|
|
29943
|
-
|
|
29944
|
-
|
|
29945
|
-
|
|
29946
|
-
toPage: toForm
|
|
29989
|
+
userEvents.addPageEvent("Clicked button", {
|
|
29990
|
+
actionType,
|
|
29991
|
+
toPage: toForm,
|
|
29992
|
+
label,
|
|
29993
|
+
returnValue,
|
|
29994
|
+
...baseTrackingPayload
|
|
29947
29995
|
});
|
|
29948
29996
|
};
|
|
29949
29997
|
const getOpeningStep = (forms, remediationActions) => {
|
|
@@ -29987,7 +30035,7 @@ const useFormComposer = ({
|
|
|
29987
30035
|
);
|
|
29988
30036
|
}, [forms]);
|
|
29989
30037
|
useEffect(() => {
|
|
29990
|
-
userEvents.updateSharedEventProperties({ page: activeForm.
|
|
30038
|
+
userEvents.updateSharedEventProperties({ page: activeForm.formName });
|
|
29991
30039
|
}, [activeForm]);
|
|
29992
30040
|
useEffect(() => {
|
|
29993
30041
|
if (hasAlreadyNavigatedForm) return;
|
|
@@ -29996,14 +30044,6 @@ const useFormComposer = ({
|
|
|
29996
30044
|
setActiveForm(openingStep);
|
|
29997
30045
|
}
|
|
29998
30046
|
}, [activeForm, forms, problems == null ? void 0 : problems.remediationActions, hasAlreadyNavigatedForm]);
|
|
29999
|
-
const trackSectionCompletion = (formName) => {
|
|
30000
|
-
userEvents.addEvent("Success", {
|
|
30001
|
-
...baseTrackingPayload,
|
|
30002
|
-
actionLevel: "page",
|
|
30003
|
-
actionType: "next",
|
|
30004
|
-
page: formName
|
|
30005
|
-
});
|
|
30006
|
-
};
|
|
30007
30047
|
const gotoFormByFormIndex = (nextFormIndex) => {
|
|
30008
30048
|
if (formRef == null ? void 0 : formRef.current.verifyForm) {
|
|
30009
30049
|
formRef.current.verifyForm(activeForm.formId).then((isVerified) => {
|
|
@@ -30027,6 +30067,12 @@ const useFormComposer = ({
|
|
|
30027
30067
|
}
|
|
30028
30068
|
if (!activeForm.isValid) {
|
|
30029
30069
|
validateCurrentForm();
|
|
30070
|
+
trackNavigation({
|
|
30071
|
+
actionType: "next",
|
|
30072
|
+
label: "next",
|
|
30073
|
+
returnValue: "validation error",
|
|
30074
|
+
baseTrackingPayload
|
|
30075
|
+
});
|
|
30030
30076
|
return;
|
|
30031
30077
|
}
|
|
30032
30078
|
if (isFinalStep) {
|
|
@@ -30034,27 +30080,25 @@ const useFormComposer = ({
|
|
|
30034
30080
|
return;
|
|
30035
30081
|
}
|
|
30036
30082
|
setShouldValidate(false);
|
|
30037
|
-
const toFormIndex =
|
|
30083
|
+
const toFormIndex = currentStep + 1;
|
|
30038
30084
|
gotoFormByFormIndex(toFormIndex);
|
|
30039
30085
|
trackNavigation({
|
|
30040
|
-
|
|
30086
|
+
actionType: "next",
|
|
30041
30087
|
toForm: forms[toFormIndex].formName,
|
|
30042
|
-
|
|
30088
|
+
label: "next",
|
|
30089
|
+
returnValue: "success",
|
|
30043
30090
|
baseTrackingPayload
|
|
30044
30091
|
});
|
|
30045
|
-
trackSectionCompletion(activeForm.formName);
|
|
30046
30092
|
};
|
|
30047
30093
|
const handleBackClick = () => {
|
|
30048
|
-
|
|
30049
|
-
|
|
30050
|
-
const fromForm = forms[currentFormIndex];
|
|
30051
|
-
const toForm = forms[currentFormIndex - 1];
|
|
30094
|
+
if (currentStep > 0) {
|
|
30095
|
+
const toForm = forms[currentStep - 1];
|
|
30052
30096
|
setActiveForm(toForm);
|
|
30053
30097
|
setHasAlreadyNavigatedForm(true);
|
|
30054
30098
|
trackNavigation({
|
|
30055
|
-
|
|
30099
|
+
actionType: "back",
|
|
30056
30100
|
toForm: toForm.formName,
|
|
30057
|
-
|
|
30101
|
+
label: "back",
|
|
30058
30102
|
baseTrackingPayload
|
|
30059
30103
|
});
|
|
30060
30104
|
}
|
|
@@ -30754,19 +30798,13 @@ const addValidityToForms = (forms, formValidity, problems) => forms.map(({ formI
|
|
|
30754
30798
|
const convertApiFieldNameToSchemaFieldName = (apiField, legalEntityType, isExperimentEnabled) => {
|
|
30755
30799
|
switch (legalEntityType) {
|
|
30756
30800
|
case LegalEntityType.INDIVIDUAL:
|
|
30757
|
-
return individualApiKeyMapping[apiField];
|
|
30801
|
+
return apiField in individualApiKeyMapping ? individualApiKeyMapping[apiField] : void 0;
|
|
30758
30802
|
case LegalEntityType.ORGANIZATION:
|
|
30759
|
-
return (isExperimentEnabled == null ? void 0 : isExperimentEnabled("EnableNewBusinessDetailsFlow")) ?
|
|
30760
|
-
// @ts-ignore
|
|
30761
|
-
businessDetailsApiKeyMapping[apiField]
|
|
30762
|
-
) : (
|
|
30763
|
-
// @ts-ignore
|
|
30764
|
-
companyApiKeyMapping[apiField]
|
|
30765
|
-
);
|
|
30803
|
+
return (isExperimentEnabled == null ? void 0 : isExperimentEnabled("EnableNewBusinessDetailsFlow")) ? apiField in businessDetailsApiKeyMapping ? businessDetailsApiKeyMapping[apiField] : void 0 : apiField in companyApiKeyMapping ? companyApiKeyMapping[apiField] : void 0;
|
|
30766
30804
|
case LegalEntityType.SOLE_PROPRIETORSHIP:
|
|
30767
|
-
return solePropApiKeyMapping[apiField];
|
|
30805
|
+
return apiField in solePropApiKeyMapping ? solePropApiKeyMapping[apiField] : void 0;
|
|
30768
30806
|
case LegalEntityType.TRUST:
|
|
30769
|
-
return trustApiKeyMapping[apiField];
|
|
30807
|
+
return apiField in trustApiKeyMapping ? trustApiKeyMapping[apiField] : void 0;
|
|
30770
30808
|
default:
|
|
30771
30809
|
throw Error("No valid legal entity type, cannot convert");
|
|
30772
30810
|
}
|
|
@@ -30829,7 +30867,7 @@ const structuredList = "adyen-kyc-structured-list";
|
|
|
30829
30867
|
const structuredListListItem = "adyen-kyc-structured-list-list-item";
|
|
30830
30868
|
const structuredListLabel = "adyen-kyc-structured-list-label";
|
|
30831
30869
|
const structuredListValue = "adyen-kyc-structured-list-value";
|
|
30832
|
-
const styles$
|
|
30870
|
+
const styles$e = {
|
|
30833
30871
|
structuredList,
|
|
30834
30872
|
structuredListListItem,
|
|
30835
30873
|
structuredListLabel,
|
|
@@ -30837,9 +30875,9 @@ const styles$b = {
|
|
|
30837
30875
|
};
|
|
30838
30876
|
const StructuredList = ({ items }) => {
|
|
30839
30877
|
const { i18n } = useI18nContext();
|
|
30840
|
-
return /* @__PURE__ */ jsx("dl", { className: styles$
|
|
30841
|
-
/* @__PURE__ */ jsx("dt", { className: styles$
|
|
30842
|
-
/* @__PURE__ */ jsx("dd", { className: styles$
|
|
30878
|
+
return /* @__PURE__ */ jsx("dl", { className: styles$e.structuredList, children: items.map((item) => /* @__PURE__ */ jsxs("div", { className: styles$e.structuredListListItem, children: [
|
|
30879
|
+
/* @__PURE__ */ jsx("dt", { className: styles$e.structuredListLabel, children: i18n.get(item.labelKey) }),
|
|
30880
|
+
/* @__PURE__ */ jsx("dd", { className: styles$e.structuredListValue, children: item.value })
|
|
30843
30881
|
] }, item.labelKey)) });
|
|
30844
30882
|
};
|
|
30845
30883
|
function VerifiedBusinessCard({
|
|
@@ -31171,16 +31209,12 @@ function AdditionalInformation({
|
|
|
31171
31209
|
}
|
|
31172
31210
|
};
|
|
31173
31211
|
}, [verifiedBusiness, basicInformation == null ? void 0 : basicInformation.stateOrProvince, country]);
|
|
31174
|
-
useEffect(
|
|
31175
|
-
()
|
|
31176
|
-
|
|
31177
|
-
|
|
31178
|
-
|
|
31179
|
-
|
|
31180
|
-
},
|
|
31181
|
-
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
31182
|
-
[verifiedBusiness]
|
|
31183
|
-
);
|
|
31212
|
+
useEffect(() => {
|
|
31213
|
+
applyVerifiedBusinessData(verifiedBusiness, handleChangeFor);
|
|
31214
|
+
if (basicInformation && (verifiedBusiness == null ? void 0 : verifiedBusiness.name)) {
|
|
31215
|
+
basicInformation.legalCompanyName = verifiedBusiness.name;
|
|
31216
|
+
}
|
|
31217
|
+
}, [verifiedBusiness]);
|
|
31184
31218
|
useEffect(() => {
|
|
31185
31219
|
if (!verifiedBusiness && !showCompanyStructure) resetToDefaultData();
|
|
31186
31220
|
}, [verifiedBusiness]);
|
|
@@ -31755,7 +31789,7 @@ function BusinessSelection({
|
|
|
31755
31789
|
if ((searchResults == null ? void 0 : searchResults.length) && !showCompanyStructure || showLoader) {
|
|
31756
31790
|
return /* @__PURE__ */ jsxs("div", { className: businessSelectionClasses, children: [
|
|
31757
31791
|
/* @__PURE__ */ jsx("div", { className: loaderClasses, "data-testId": "business-selection-loader", children: /* @__PURE__ */ jsx(Loader, { size: "large" }) }),
|
|
31758
|
-
(searchResults == null ? void 0 : searchResults.length) && !showCompanyStructure && !showLoader && /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
31792
|
+
!!((searchResults == null ? void 0 : searchResults.length) && !showCompanyStructure && !showLoader) && /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
31759
31793
|
/* @__PURE__ */ jsx(FormHeader, { heading: i18n.get("businessSelection__heading") }),
|
|
31760
31794
|
/* @__PURE__ */ jsx(CardGroup, { spaced: true, children: searchResults == null ? void 0 : searchResults.map((result) => /* @__PURE__ */ jsx(
|
|
31761
31795
|
BusinessInformationCard,
|
|
@@ -33363,7 +33397,7 @@ const progressStep = "adyen-kyc-progress-step";
|
|
|
33363
33397
|
const progressStepActive = "adyen-kyc-progress-step-active";
|
|
33364
33398
|
const progressStepLabel = "adyen-kyc-progress-step-label";
|
|
33365
33399
|
const progressBarCircles = "adyen-kyc-progress-bar-circles";
|
|
33366
|
-
const styles$
|
|
33400
|
+
const styles$d = {
|
|
33367
33401
|
progress,
|
|
33368
33402
|
progressBar,
|
|
33369
33403
|
progressBarThick,
|
|
@@ -33391,14 +33425,14 @@ const StepProgressIndicator = ({
|
|
|
33391
33425
|
"div",
|
|
33392
33426
|
{
|
|
33393
33427
|
"aria-label": `Step ${activeStepIndex} of ${stepsCount}`,
|
|
33394
|
-
className: styles$
|
|
33428
|
+
className: styles$d.progress,
|
|
33395
33429
|
role: "group",
|
|
33396
33430
|
children: /* @__PURE__ */ jsx(
|
|
33397
33431
|
"ol",
|
|
33398
33432
|
{
|
|
33399
|
-
className: cx(styles$
|
|
33400
|
-
[styles$
|
|
33401
|
-
[styles$
|
|
33433
|
+
className: cx(styles$d.progressBar, {
|
|
33434
|
+
[styles$d.progressBarThick]: thick,
|
|
33435
|
+
[styles$d.progressBarCircles]: circles
|
|
33402
33436
|
}),
|
|
33403
33437
|
children: range(stepsCount).map((stepNumber) => {
|
|
33404
33438
|
const isHighlighted = shouldHighlight(activeStepIndex, stepNumber, fillBefore);
|
|
@@ -33406,10 +33440,10 @@ const StepProgressIndicator = ({
|
|
|
33406
33440
|
"li",
|
|
33407
33441
|
{
|
|
33408
33442
|
"aria-current": isHighlighted ? "step" : void 0,
|
|
33409
|
-
className: cx(styles$
|
|
33410
|
-
[styles$
|
|
33443
|
+
className: cx(styles$d.progressStep, {
|
|
33444
|
+
[styles$d.progressStepActive]: isHighlighted
|
|
33411
33445
|
}),
|
|
33412
|
-
children: /* @__PURE__ */ jsx("span", { className: styles$
|
|
33446
|
+
children: /* @__PURE__ */ jsx("span", { className: styles$d.progressStepLabel, children: `Step ${stepNumber}: ${stepNumber < activeStepIndex ? "completed" : "not completed"}` })
|
|
33413
33447
|
},
|
|
33414
33448
|
stepNumber
|
|
33415
33449
|
);
|
|
@@ -33461,9 +33495,10 @@ function FormNavigation({
|
|
|
33461
33495
|
if (form.formId === activeForm.formId) return;
|
|
33462
33496
|
gotoForm(getFormIndex(form));
|
|
33463
33497
|
trackNavigation2({
|
|
33464
|
-
|
|
33465
|
-
toForm:
|
|
33466
|
-
|
|
33498
|
+
actionType: "navigate",
|
|
33499
|
+
toForm: form.formName,
|
|
33500
|
+
label: form.formName,
|
|
33501
|
+
returnValue: "success"
|
|
33467
33502
|
});
|
|
33468
33503
|
};
|
|
33469
33504
|
const getNavigateHandler = (form, activeForm2) => {
|
|
@@ -33472,7 +33507,15 @@ function FormNavigation({
|
|
|
33472
33507
|
if (allPriorFormsValid || !validateForm) {
|
|
33473
33508
|
return goToForm(form);
|
|
33474
33509
|
}
|
|
33475
|
-
return activeForm2.isValid ? void 0 :
|
|
33510
|
+
return activeForm2.isValid ? void 0 : () => {
|
|
33511
|
+
trackNavigation2({
|
|
33512
|
+
actionType: "navigate",
|
|
33513
|
+
toForm: form.formName,
|
|
33514
|
+
label: form.formName,
|
|
33515
|
+
returnValue: "validation error"
|
|
33516
|
+
});
|
|
33517
|
+
validateForm();
|
|
33518
|
+
};
|
|
33476
33519
|
};
|
|
33477
33520
|
return /* @__PURE__ */ jsxs("div", { className: cx("adyen-kyc-form-navigation", className2), children: [
|
|
33478
33521
|
/* @__PURE__ */ jsx("div", { className: "adyen-kyc-form-navigation__header", children: i18n.get(taskName2) }),
|
|
@@ -33536,15 +33579,9 @@ const FormWrapper = ({
|
|
|
33536
33579
|
);
|
|
33537
33580
|
const showTaxExemptedLegalCaption = showExtraTaxExemptionReasons && ((_a2 = summaryData == null ? void 0 : summaryData.companyRegistrationDetails) == null ? void 0 : _a2.vatAbsenceReason) && ["companyDetails", "businessDetails"].includes(taskName2);
|
|
33538
33581
|
const handleTrackNavigation = useCallback(
|
|
33539
|
-
({
|
|
33540
|
-
fromForm,
|
|
33541
|
-
toForm,
|
|
33542
|
-
component
|
|
33543
|
-
}) => {
|
|
33582
|
+
(props) => {
|
|
33544
33583
|
trackNavigation({
|
|
33545
|
-
|
|
33546
|
-
toForm,
|
|
33547
|
-
component,
|
|
33584
|
+
...props,
|
|
33548
33585
|
baseTrackingPayload
|
|
33549
33586
|
});
|
|
33550
33587
|
},
|
|
@@ -34117,6 +34154,41 @@ const getCountryOfGoverningLaw = (isCountryOfGoverningLawEnabled, basicData) =>
|
|
|
34117
34154
|
}
|
|
34118
34155
|
return basicData == null ? void 0 : basicData.countryOfGoverningLaw;
|
|
34119
34156
|
};
|
|
34157
|
+
const businessVerificationModalHeader = "adyen-kyc-business-verification-modal-header";
|
|
34158
|
+
const businessVerificationModalContent = "adyen-kyc-business-verification-modal-content";
|
|
34159
|
+
const businessVerificationModalButton = "adyen-kyc-business-verification-modal-button";
|
|
34160
|
+
const styles$c = {
|
|
34161
|
+
businessVerificationModalHeader,
|
|
34162
|
+
businessVerificationModalContent,
|
|
34163
|
+
businessVerificationModalButton
|
|
34164
|
+
};
|
|
34165
|
+
const BusinessMismatchModal = ({ onContinue, onBackClick }) => {
|
|
34166
|
+
const { i18n } = useI18nContext();
|
|
34167
|
+
return /* @__PURE__ */ jsxs(Modal, { size: "small", onClose: () => {
|
|
34168
|
+
}, showCloseButton: false, children: [
|
|
34169
|
+
/* @__PURE__ */ jsx(ModalHeader, { children: /* @__PURE__ */ jsx(Typography, { variant: "title", el: "h3", className: styles$c.businessVerificationModalHeader, children: i18n.get("businessSelection__tinVerificationFailureModalHeader") }) }),
|
|
34170
|
+
/* @__PURE__ */ jsxs(ModalContent, { children: [
|
|
34171
|
+
/* @__PURE__ */ jsx(Typography, { el: "p", variant: "body", className: styles$c.businessVerificationModalContent, children: i18n.get("businessSelection__tinVerificationFailureModalContent") }),
|
|
34172
|
+
/* @__PURE__ */ jsx(
|
|
34173
|
+
Button,
|
|
34174
|
+
{
|
|
34175
|
+
className: styles$c.businessVerificationModalButton,
|
|
34176
|
+
secondary: true,
|
|
34177
|
+
label: i18n.get("businessSelection__tinVerificationFailureModalPrimaryButton"),
|
|
34178
|
+
onClick: onContinue
|
|
34179
|
+
}
|
|
34180
|
+
),
|
|
34181
|
+
/* @__PURE__ */ jsx(
|
|
34182
|
+
Button,
|
|
34183
|
+
{
|
|
34184
|
+
className: styles$c.businessVerificationModalButton,
|
|
34185
|
+
label: i18n.get("businessSelection__tinVerificationFailureModalSecondaryButton"),
|
|
34186
|
+
onClick: onBackClick
|
|
34187
|
+
}
|
|
34188
|
+
)
|
|
34189
|
+
] })
|
|
34190
|
+
] });
|
|
34191
|
+
};
|
|
34120
34192
|
function BusinessDetailsDropin({
|
|
34121
34193
|
country,
|
|
34122
34194
|
problems,
|
|
@@ -34145,7 +34217,7 @@ function BusinessDetailsDropin({
|
|
|
34145
34217
|
handleVerifyTin,
|
|
34146
34218
|
handleClearCompanyData
|
|
34147
34219
|
}) {
|
|
34148
|
-
var _a2, _b2, _c2, _d2, _e2, _f2;
|
|
34220
|
+
var _a2, _b2, _c2, _d2, _e2, _f2, _g2, _h2, _i2, _j2;
|
|
34149
34221
|
const {
|
|
34150
34222
|
state: { currentState }
|
|
34151
34223
|
} = useStateContext();
|
|
@@ -34182,6 +34254,9 @@ function BusinessDetailsDropin({
|
|
|
34182
34254
|
},
|
|
34183
34255
|
[(_a2 = currentState.data.basicInformation) == null ? void 0 : _a2.country, country]
|
|
34184
34256
|
);
|
|
34257
|
+
const [tinMatched, setTinMatched] = useState(void 0);
|
|
34258
|
+
const isManualTinVerificationEnabledAndUS = isExperimentEnabled(ExperimentNames.EnableManualCompanyTinVerification) && country === CountryCodes.UnitedStates;
|
|
34259
|
+
const [businessMismatchModalOpen, setBusinessMismatchModalOpen] = useState(false);
|
|
34185
34260
|
const [initialData, setInitialData] = useState(
|
|
34186
34261
|
mapLegalEntityToBusinessDetailsSchema(legalEntityResponse, isExperimentEnabled)
|
|
34187
34262
|
);
|
|
@@ -34230,9 +34305,10 @@ function BusinessDetailsDropin({
|
|
|
34230
34305
|
country: currentCountry,
|
|
34231
34306
|
taskType,
|
|
34232
34307
|
isExperimentEnabled,
|
|
34233
|
-
accountHolder
|
|
34308
|
+
accountHolder,
|
|
34309
|
+
tinMatched
|
|
34234
34310
|
}),
|
|
34235
|
-
[currentCountry, currentState.data, isExperimentEnabled, taskType, accountHolder]
|
|
34311
|
+
[currentCountry, currentState.data, isExperimentEnabled, taskType, tinMatched, accountHolder]
|
|
34236
34312
|
);
|
|
34237
34313
|
const initialForms = useMemo(() => getForms(currentCountry), [currentCountry]);
|
|
34238
34314
|
const derivedProps = useMemo(
|
|
@@ -34361,6 +34437,7 @@ function BusinessDetailsDropin({
|
|
|
34361
34437
|
searchForBusiness,
|
|
34362
34438
|
fetchBusinessData,
|
|
34363
34439
|
verifyBusinessData,
|
|
34440
|
+
verifyManualBusinessData,
|
|
34364
34441
|
clearTrustedBusinessData,
|
|
34365
34442
|
resetBusinessData,
|
|
34366
34443
|
resetTinVerification,
|
|
@@ -34396,16 +34473,19 @@ function BusinessDetailsDropin({
|
|
|
34396
34473
|
if (!(currentData == null ? void 0 : currentData.legalCompanyName) || !(currentData == null ? void 0 : currentData.country) || !(currentData == null ? void 0 : currentData.stateOrProvince)) {
|
|
34397
34474
|
return;
|
|
34398
34475
|
}
|
|
34399
|
-
const tin = (_b3 = (_a3 = currentData == null ? void 0 : currentData.taxInformation) == null ? void 0 : _a3.find(
|
|
34400
|
-
(taxId) => currentCountry === taxId.country
|
|
34401
|
-
)) == null ? void 0 : _b3.number;
|
|
34476
|
+
const tin = ((_b3 = (_a3 = currentData == null ? void 0 : currentData.taxInformation) == null ? void 0 : _a3.find((taxId) => currentCountry === taxId.country)) == null ? void 0 : _b3.number) || "";
|
|
34402
34477
|
const results = await searchForBusiness({
|
|
34403
34478
|
name: currentData.legalCompanyName,
|
|
34404
34479
|
country: currentData.country,
|
|
34405
34480
|
state: currentData.stateOrProvince,
|
|
34406
34481
|
registrationNumber: currentData.registrationNumber
|
|
34407
34482
|
});
|
|
34408
|
-
if (results
|
|
34483
|
+
if (!results) {
|
|
34484
|
+
setShowCompanyStructure(true);
|
|
34485
|
+
setTrustedFields([]);
|
|
34486
|
+
return;
|
|
34487
|
+
}
|
|
34488
|
+
if ((results == null ? void 0 : results.length) === 1) {
|
|
34409
34489
|
const businessData = await fetchBusinessData(
|
|
34410
34490
|
results[0],
|
|
34411
34491
|
currentData.stateOrProvince
|
|
@@ -34414,14 +34494,31 @@ function BusinessDetailsDropin({
|
|
|
34414
34494
|
const tinMatch = await handleVerifyBusinessData(businessData, tin);
|
|
34415
34495
|
return tinMatch ? handleNextClick() : void 0;
|
|
34416
34496
|
}
|
|
34497
|
+
} else if (Array.isArray(results) && !(results == null ? void 0 : results.length)) {
|
|
34498
|
+
if (!isManualTinVerificationEnabledAndUS) {
|
|
34499
|
+
setShowCompanyStructure(true);
|
|
34500
|
+
return;
|
|
34501
|
+
}
|
|
34502
|
+
const tinMatch = await verifyManualBusinessData(currentData.legalCompanyName, tin);
|
|
34503
|
+
setTinMatched(tinMatch);
|
|
34504
|
+
if (tinMatch) {
|
|
34505
|
+
setShowCompanyStructure(true);
|
|
34506
|
+
} else {
|
|
34507
|
+
resetBusinessData();
|
|
34508
|
+
setBusinessMismatchModalOpen(true);
|
|
34509
|
+
}
|
|
34417
34510
|
}
|
|
34418
34511
|
},
|
|
34419
34512
|
[
|
|
34513
|
+
searchForBusiness,
|
|
34420
34514
|
currentCountry,
|
|
34421
34515
|
fetchBusinessData,
|
|
34516
|
+
setShowCompanyStructure,
|
|
34517
|
+
handleVerifyBusinessData,
|
|
34422
34518
|
handleNextClick,
|
|
34423
|
-
|
|
34424
|
-
|
|
34519
|
+
isManualTinVerificationEnabledAndUS,
|
|
34520
|
+
verifyManualBusinessData,
|
|
34521
|
+
resetBusinessData
|
|
34425
34522
|
]
|
|
34426
34523
|
);
|
|
34427
34524
|
const isBusinessSelection = useMemo(
|
|
@@ -34489,9 +34586,10 @@ function BusinessDetailsDropin({
|
|
|
34489
34586
|
case "basicInformation":
|
|
34490
34587
|
if (((_b3 = currentState.validityByForm) == null ? void 0 : _b3.basicInformation) && !isBusinessSelection && !verifiedBusiness) {
|
|
34491
34588
|
trackNavigation({
|
|
34492
|
-
|
|
34589
|
+
actionType: "next",
|
|
34493
34590
|
toForm: toFormName || "home",
|
|
34494
|
-
|
|
34591
|
+
label: "next",
|
|
34592
|
+
returnValue: "success"
|
|
34495
34593
|
});
|
|
34496
34594
|
findBusiness(currentState.data.basicInformation);
|
|
34497
34595
|
setShowBusinessSelection(true);
|
|
@@ -34506,7 +34604,6 @@ function BusinessDetailsDropin({
|
|
|
34506
34604
|
handleNextClick,
|
|
34507
34605
|
forms,
|
|
34508
34606
|
activeForm.formId,
|
|
34509
|
-
activeForm.formName,
|
|
34510
34607
|
(_e2 = currentState.validityByForm) == null ? void 0 : _e2.basicInformation,
|
|
34511
34608
|
currentState.data.basicInformation,
|
|
34512
34609
|
isBusinessSelection,
|
|
@@ -34518,9 +34615,9 @@ function BusinessDetailsDropin({
|
|
|
34518
34615
|
switch (activeForm.formId) {
|
|
34519
34616
|
case "basicInformation": {
|
|
34520
34617
|
trackNavigation({
|
|
34521
|
-
|
|
34618
|
+
actionType: "back",
|
|
34522
34619
|
toForm: "basicDetails",
|
|
34523
|
-
|
|
34620
|
+
label: "back"
|
|
34524
34621
|
});
|
|
34525
34622
|
return showBusinessSelection ? setShowBusinessSelection(false) : void 0;
|
|
34526
34623
|
}
|
|
@@ -34548,8 +34645,6 @@ function BusinessDetailsDropin({
|
|
|
34548
34645
|
currentCountry,
|
|
34549
34646
|
handleBackClick,
|
|
34550
34647
|
activeForm.formId,
|
|
34551
|
-
activeForm.formName,
|
|
34552
|
-
i18n,
|
|
34553
34648
|
showBusinessSelection,
|
|
34554
34649
|
searching,
|
|
34555
34650
|
searchResults,
|
|
@@ -34557,35 +34652,63 @@ function BusinessDetailsDropin({
|
|
|
34557
34652
|
]);
|
|
34558
34653
|
const homeClick = () => {
|
|
34559
34654
|
trackNavigation({
|
|
34560
|
-
|
|
34655
|
+
actionType: "save",
|
|
34561
34656
|
toForm: "home",
|
|
34562
|
-
|
|
34657
|
+
label: "home"
|
|
34563
34658
|
});
|
|
34564
34659
|
handleHomeClick == null ? void 0 : handleHomeClick();
|
|
34565
34660
|
};
|
|
34566
34661
|
const proceedToManualDataEntry = useCallback(async () => {
|
|
34567
|
-
await clearTrustedBusinessData().then(() =>
|
|
34568
|
-
|
|
34569
|
-
|
|
34570
|
-
|
|
34571
|
-
|
|
34572
|
-
|
|
34573
|
-
|
|
34574
|
-
|
|
34662
|
+
await clearTrustedBusinessData().then(async () => {
|
|
34663
|
+
var _a3, _b3, _c3, _d3, _e3;
|
|
34664
|
+
if (!isManualTinVerificationEnabledAndUS) {
|
|
34665
|
+
setShowCompanyStructure(true);
|
|
34666
|
+
return;
|
|
34667
|
+
}
|
|
34668
|
+
const businessName = ((_b3 = (_a3 = currentState == null ? void 0 : currentState.data) == null ? void 0 : _a3.basicInformation) == null ? void 0 : _b3.legalCompanyName) || "";
|
|
34669
|
+
const taxInformation = (_d3 = (_c3 = currentState == null ? void 0 : currentState.data) == null ? void 0 : _c3.basicInformation) == null ? void 0 : _d3.taxInformation;
|
|
34670
|
+
const tin = ((_e3 = taxInformation == null ? void 0 : taxInformation.find((taxId) => currentCountry === taxId.country)) == null ? void 0 : _e3.number) || "";
|
|
34671
|
+
const tinMatch = await verifyManualBusinessData(businessName, tin);
|
|
34672
|
+
if (tinMatch) {
|
|
34673
|
+
setShowCompanyStructure(true);
|
|
34674
|
+
setBusinessMismatchModalOpen(false);
|
|
34675
|
+
} else {
|
|
34676
|
+
setBusinessMismatchModalOpen(true);
|
|
34677
|
+
setTinMatched(false);
|
|
34678
|
+
}
|
|
34679
|
+
});
|
|
34680
|
+
}, [
|
|
34681
|
+
clearTrustedBusinessData,
|
|
34682
|
+
isManualTinVerificationEnabledAndUS,
|
|
34683
|
+
(_g2 = (_f2 = currentState == null ? void 0 : currentState.data) == null ? void 0 : _f2.basicInformation) == null ? void 0 : _g2.legalCompanyName,
|
|
34684
|
+
(_i2 = (_h2 = currentState == null ? void 0 : currentState.data) == null ? void 0 : _h2.basicInformation) == null ? void 0 : _i2.taxInformation,
|
|
34685
|
+
verifyManualBusinessData,
|
|
34686
|
+
currentCountry
|
|
34687
|
+
]);
|
|
34688
|
+
const handleBusinessMismatchContinue = useCallback(() => {
|
|
34689
|
+
setShowCompanyStructure(true);
|
|
34690
|
+
setTrustedFields([]);
|
|
34691
|
+
setBusinessMismatchModalOpen(false);
|
|
34692
|
+
}, [setShowCompanyStructure, setTrustedFields, setBusinessMismatchModalOpen]);
|
|
34693
|
+
const handleBusinessMismatchCancel = useCallback(() => {
|
|
34694
|
+
backClick == null ? void 0 : backClick();
|
|
34695
|
+
setBusinessMismatchModalOpen(false);
|
|
34696
|
+
setTinMatched(void 0);
|
|
34697
|
+
}, [backClick, setTinMatched, setBusinessMismatchModalOpen]);
|
|
34575
34698
|
useEffect(() => {
|
|
34576
34699
|
var _a3, _b3;
|
|
34577
34700
|
if (((_a3 = currentState.data.basicInformation) == null ? void 0 : _a3.legalCompanyName) !== currentSearchName && ((_b3 = currentState.data.basicInformation) == null ? void 0 : _b3.legalCompanyName) !== (verifiedBusiness == null ? void 0 : verifiedBusiness.name)) {
|
|
34578
34701
|
setShowCompanyStructure(false);
|
|
34579
34702
|
resetBusinessData();
|
|
34580
34703
|
}
|
|
34581
|
-
}, [currentSearchName, (
|
|
34704
|
+
}, [currentSearchName, (_j2 = currentState.data.basicInformation) == null ? void 0 : _j2.legalCompanyName, verifiedBusiness]);
|
|
34582
34705
|
useEffect(() => {
|
|
34583
34706
|
var _a3;
|
|
34584
34707
|
if ((trustedFields == null ? void 0 : trustedFields.length) && ((_a3 = legalEntityResponse.organization) == null ? void 0 : _a3.registeredAddress.country) !== currentCountry) {
|
|
34585
34708
|
setTrustedFields(void 0);
|
|
34586
34709
|
}
|
|
34587
34710
|
}, [currentCountry]);
|
|
34588
|
-
return /* @__PURE__ */
|
|
34711
|
+
return /* @__PURE__ */ jsxs(
|
|
34589
34712
|
FormWrapper,
|
|
34590
34713
|
{
|
|
34591
34714
|
taskName: taskName2 ?? "businessDetails",
|
|
@@ -34607,38 +34730,47 @@ function BusinessDetailsDropin({
|
|
|
34607
34730
|
steps,
|
|
34608
34731
|
showBackButton,
|
|
34609
34732
|
hideNextButton,
|
|
34610
|
-
children:
|
|
34611
|
-
|
|
34612
|
-
|
|
34613
|
-
|
|
34614
|
-
|
|
34615
|
-
|
|
34616
|
-
|
|
34617
|
-
|
|
34618
|
-
|
|
34619
|
-
|
|
34620
|
-
|
|
34621
|
-
|
|
34622
|
-
|
|
34623
|
-
|
|
34624
|
-
|
|
34625
|
-
|
|
34626
|
-
|
|
34627
|
-
|
|
34628
|
-
|
|
34629
|
-
|
|
34630
|
-
|
|
34631
|
-
|
|
34632
|
-
|
|
34633
|
-
|
|
34634
|
-
|
|
34635
|
-
|
|
34636
|
-
|
|
34637
|
-
|
|
34638
|
-
|
|
34639
|
-
|
|
34640
|
-
|
|
34641
|
-
|
|
34733
|
+
children: [
|
|
34734
|
+
/* @__PURE__ */ jsx(
|
|
34735
|
+
BusinessDetails,
|
|
34736
|
+
{
|
|
34737
|
+
...derivedProps,
|
|
34738
|
+
ref: formRef,
|
|
34739
|
+
data: initialData,
|
|
34740
|
+
country: currentCountry,
|
|
34741
|
+
problems: currentProblems,
|
|
34742
|
+
activeForm,
|
|
34743
|
+
shouldValidate,
|
|
34744
|
+
isTopLevelEntity: taskType === TaskTypes.BUSINESS_DETAILS,
|
|
34745
|
+
baseTrackingPayload,
|
|
34746
|
+
showBusinessSelection,
|
|
34747
|
+
setShowBusinessSelection,
|
|
34748
|
+
showCompanyStructure,
|
|
34749
|
+
setShowCompanyStructure,
|
|
34750
|
+
searchResults,
|
|
34751
|
+
invalidTin,
|
|
34752
|
+
resetTinVerification,
|
|
34753
|
+
verifiedBusiness,
|
|
34754
|
+
searching,
|
|
34755
|
+
fetching,
|
|
34756
|
+
verifying,
|
|
34757
|
+
resettingTrustedData,
|
|
34758
|
+
fetchBusinessData,
|
|
34759
|
+
verifyBusinessData,
|
|
34760
|
+
proceedToManualDataEntry,
|
|
34761
|
+
handleNextClick: nextClick,
|
|
34762
|
+
handleAddressSearch,
|
|
34763
|
+
handleFindAddress
|
|
34764
|
+
}
|
|
34765
|
+
),
|
|
34766
|
+
businessMismatchModalOpen && /* @__PURE__ */ jsx(
|
|
34767
|
+
BusinessMismatchModal,
|
|
34768
|
+
{
|
|
34769
|
+
onContinue: handleBusinessMismatchContinue,
|
|
34770
|
+
onBackClick: handleBusinessMismatchCancel
|
|
34771
|
+
}
|
|
34772
|
+
)
|
|
34773
|
+
]
|
|
34642
34774
|
}
|
|
34643
34775
|
);
|
|
34644
34776
|
}
|
|
@@ -35963,6 +36095,10 @@ const BusinessTypeSelection = ({
|
|
|
35963
36095
|
if (loadingStatus === "loading") return;
|
|
35964
36096
|
triggerValidation();
|
|
35965
36097
|
if (isValid) {
|
|
36098
|
+
userEvents.addEvent("Clicked button", {
|
|
36099
|
+
actionLevel: "task",
|
|
36100
|
+
actionType: "next"
|
|
36101
|
+
});
|
|
35966
36102
|
if (((_a3 = data.businessType) == null ? void 0 : _a3.id) === "legalArrangement") {
|
|
35967
36103
|
if (currentStep !== 1) {
|
|
35968
36104
|
setCurrentStep(
|
|
@@ -36239,6 +36375,12 @@ function CustomerSupport({
|
|
|
36239
36375
|
// Old phone field data
|
|
36240
36376
|
email: (_f2 = (_e2 = legalEntityResponse[legalEntityType]) == null ? void 0 : _e2.support) == null ? void 0 : _f2.email
|
|
36241
36377
|
};
|
|
36378
|
+
useEffect(() => {
|
|
36379
|
+
userEvents.addEvent("Landed on page", {
|
|
36380
|
+
actionLevel: "task",
|
|
36381
|
+
actionType: "start"
|
|
36382
|
+
});
|
|
36383
|
+
}, []);
|
|
36242
36384
|
const submitForm = async () => {
|
|
36243
36385
|
if (!currentState.isValid) {
|
|
36244
36386
|
setShouldValidate(true);
|
|
@@ -36252,6 +36394,10 @@ function CustomerSupport({
|
|
|
36252
36394
|
try {
|
|
36253
36395
|
await (handleUpdateLegalEntity == null ? void 0 : handleUpdateLegalEntity(payload, legalEntityResponse == null ? void 0 : legalEntityResponse.id));
|
|
36254
36396
|
onSubmit();
|
|
36397
|
+
userEvents.addEvent("Success", {
|
|
36398
|
+
actionLevel: "task",
|
|
36399
|
+
actionType: "submit"
|
|
36400
|
+
});
|
|
36255
36401
|
} catch {
|
|
36256
36402
|
const label = i18n.get("failedToUpdateDetails");
|
|
36257
36403
|
logger$t.error(label, payload);
|
|
@@ -36450,7 +36596,7 @@ const VerificationErrorAlert = ({
|
|
|
36450
36596
|
};
|
|
36451
36597
|
const actionsMenu = "adyen-kyc-actions-menu";
|
|
36452
36598
|
const actionsMenuOption = "adyen-kyc-actions-menu-option";
|
|
36453
|
-
const styles$
|
|
36599
|
+
const styles$b = {
|
|
36454
36600
|
actionsMenu,
|
|
36455
36601
|
actionsMenuOption
|
|
36456
36602
|
};
|
|
@@ -36496,12 +36642,12 @@ const ActionsMenu = ({ options, open, setOpen }) => {
|
|
|
36496
36642
|
icon,
|
|
36497
36643
|
label,
|
|
36498
36644
|
title: title ?? label,
|
|
36499
|
-
className: styles$
|
|
36645
|
+
className: styles$b.actionsMenuOption,
|
|
36500
36646
|
role: "menuitem"
|
|
36501
36647
|
},
|
|
36502
36648
|
label
|
|
36503
36649
|
));
|
|
36504
|
-
return open ? /* @__PURE__ */ jsx(ClickAwayWrapper, { onClickAway: () => setOpen(false), className: styles$
|
|
36650
|
+
return open ? /* @__PURE__ */ jsx(ClickAwayWrapper, { onClickAway: () => setOpen(false), className: styles$b.actionsMenu, role: "menu", children: menuItems }) : null;
|
|
36505
36651
|
};
|
|
36506
36652
|
const Remove = ({
|
|
36507
36653
|
onRemove,
|
|
@@ -36574,9 +36720,32 @@ const Remove = ({
|
|
|
36574
36720
|
}
|
|
36575
36721
|
);
|
|
36576
36722
|
};
|
|
36723
|
+
const tag = "adyen-kyc-tag";
|
|
36724
|
+
const tagGrey = "adyen-kyc-tag-grey";
|
|
36725
|
+
const tagBlue = "adyen-kyc-tag-blue";
|
|
36726
|
+
const tagOrange = "adyen-kyc-tag-orange";
|
|
36727
|
+
const tagRed = "adyen-kyc-tag-red";
|
|
36728
|
+
const tagTeal = "adyen-kyc-tag-teal";
|
|
36729
|
+
const tagGreen = "adyen-kyc-tag-green";
|
|
36730
|
+
const styles$a = {
|
|
36731
|
+
tag,
|
|
36732
|
+
tagGrey,
|
|
36733
|
+
tagBlue,
|
|
36734
|
+
tagOrange,
|
|
36735
|
+
tagRed,
|
|
36736
|
+
tagTeal,
|
|
36737
|
+
tagGreen
|
|
36738
|
+
};
|
|
36739
|
+
const variantMap = {
|
|
36740
|
+
grey: styles$a.tagGrey,
|
|
36741
|
+
teal: styles$a.tagTeal,
|
|
36742
|
+
red: styles$a.tagRed,
|
|
36743
|
+
green: styles$a.tagGreen,
|
|
36744
|
+
orange: styles$a.tagOrange,
|
|
36745
|
+
blue: styles$a.tagBlue
|
|
36746
|
+
};
|
|
36577
36747
|
const Tag = ({ className: className2, variant = "blue", children: children2 }) => {
|
|
36578
|
-
|
|
36579
|
-
return /* @__PURE__ */ jsx("span", { className: classNames, children: children2 });
|
|
36748
|
+
return /* @__PURE__ */ jsx("span", { className: cx(styles$a.tag, variantMap[variant], className2), children: children2 });
|
|
36580
36749
|
};
|
|
36581
36750
|
const EntityAssociation = ({
|
|
36582
36751
|
name,
|
|
@@ -36772,6 +36941,12 @@ const DecisionMakers = ({
|
|
|
36772
36941
|
);
|
|
36773
36942
|
const uniqueDecisionMakers = mappedDecisionMakers ? Object.values(mappedDecisionMakers) : [];
|
|
36774
36943
|
const showWarning = Boolean(remediationMessages.DECISION_MAKER && uniqueDecisionMakers.length);
|
|
36944
|
+
useEffect(() => {
|
|
36945
|
+
userEvents.addEvent("Landed on page", {
|
|
36946
|
+
actionLevel: "task",
|
|
36947
|
+
actionType: "start"
|
|
36948
|
+
});
|
|
36949
|
+
}, []);
|
|
36775
36950
|
useEffect(() => {
|
|
36776
36951
|
if (showWarning) {
|
|
36777
36952
|
userEvents.addEvent("Encountered error", {
|
|
@@ -37090,15 +37265,16 @@ const Introduction = ({
|
|
|
37090
37265
|
page: (introductionScreens == null ? void 0 : introductionScreens.length) ? introductionScreens[activeIndex] : void 0
|
|
37091
37266
|
};
|
|
37092
37267
|
useEffect(() => {
|
|
37093
|
-
|
|
37094
|
-
|
|
37095
|
-
|
|
37096
|
-
|
|
37097
|
-
|
|
37098
|
-
|
|
37268
|
+
userEvents.addEvent("Landed on page", {
|
|
37269
|
+
actionLevel: "task",
|
|
37270
|
+
actionType: "start"
|
|
37271
|
+
});
|
|
37272
|
+
}, []);
|
|
37273
|
+
useEffect(() => {
|
|
37274
|
+
if (!(introductionScreens == null ? void 0 : introductionScreens.length)) {
|
|
37099
37275
|
onExitIntroduction();
|
|
37100
37276
|
}
|
|
37101
|
-
}, [introductionScreens]);
|
|
37277
|
+
}, [introductionScreens, onExitIntroduction]);
|
|
37102
37278
|
const translationKeys = {
|
|
37103
37279
|
skip: "goToOverviewFromIntroduction",
|
|
37104
37280
|
back: "back",
|
|
@@ -37163,7 +37339,7 @@ const Introduction = ({
|
|
|
37163
37339
|
onClick: () => {
|
|
37164
37340
|
userEvents.addEvent("Success", {
|
|
37165
37341
|
actionLevel: "task",
|
|
37166
|
-
actionType: "
|
|
37342
|
+
actionType: "submit",
|
|
37167
37343
|
label: translationKeys.start
|
|
37168
37344
|
});
|
|
37169
37345
|
onExitIntroduction();
|
|
@@ -37276,8 +37452,27 @@ const SingpassLoginButton = ({
|
|
|
37276
37452
|
]
|
|
37277
37453
|
}
|
|
37278
37454
|
);
|
|
37279
|
-
const SingpassBanner = (
|
|
37280
|
-
|
|
37455
|
+
const SingpassBanner = ({
|
|
37456
|
+
isLoading,
|
|
37457
|
+
isSuccess,
|
|
37458
|
+
errorMessage,
|
|
37459
|
+
onClick,
|
|
37460
|
+
onAlertClose,
|
|
37461
|
+
onMessage,
|
|
37462
|
+
legalEntityType
|
|
37463
|
+
}) => {
|
|
37464
|
+
const authContext = useAuthContext();
|
|
37465
|
+
const singpassEventListener = useCallback(
|
|
37466
|
+
(event) => {
|
|
37467
|
+
if (event.origin !== authContext.loadingContext) return;
|
|
37468
|
+
onMessage({ data: { isSuccessful: event.data.isSuccessful } });
|
|
37469
|
+
},
|
|
37470
|
+
[authContext.loadingContext, onMessage]
|
|
37471
|
+
);
|
|
37472
|
+
useEffect(() => {
|
|
37473
|
+
window.addEventListener("message", singpassEventListener);
|
|
37474
|
+
return () => window.removeEventListener("message", singpassEventListener);
|
|
37475
|
+
}, []);
|
|
37281
37476
|
const channel = new BroadcastChannel("sgidprovider");
|
|
37282
37477
|
useEffect(() => {
|
|
37283
37478
|
channel.onmessage = onMessage;
|
|
@@ -37482,6 +37677,7 @@ const useBusinessSetup = (legalEntityResponse) => {
|
|
|
37482
37677
|
return businessSetup;
|
|
37483
37678
|
};
|
|
37484
37679
|
const TaskListItem = ({
|
|
37680
|
+
titleKey,
|
|
37485
37681
|
title,
|
|
37486
37682
|
icon,
|
|
37487
37683
|
status,
|
|
@@ -37498,18 +37694,31 @@ const TaskListItem = ({
|
|
|
37498
37694
|
removeEntity,
|
|
37499
37695
|
isRemoveDisabled = false,
|
|
37500
37696
|
handleIsRemoveDisabled,
|
|
37501
|
-
testId
|
|
37697
|
+
testId,
|
|
37698
|
+
enableTracking = true
|
|
37502
37699
|
}) => {
|
|
37700
|
+
const { i18n } = useI18nContext();
|
|
37503
37701
|
const shouldShowErrorAlert = showErrorAlerts === "always" || showErrorAlerts === "onErrorStatus" && status === TaskStatus.ERROR;
|
|
37504
37702
|
const [isStatusRemoving, setIsStatusRemoving] = useState(false);
|
|
37703
|
+
const handleNavigateToTask = () => {
|
|
37704
|
+
if (enableTracking) {
|
|
37705
|
+
userEvents.addEvent("Clicked button", {
|
|
37706
|
+
actionLevel: "journey",
|
|
37707
|
+
actionType: "open",
|
|
37708
|
+
task: void 0,
|
|
37709
|
+
label: titleKey
|
|
37710
|
+
});
|
|
37711
|
+
}
|
|
37712
|
+
onNavigateToTask == null ? void 0 : onNavigateToTask();
|
|
37713
|
+
};
|
|
37505
37714
|
return /* @__PURE__ */ jsx(
|
|
37506
37715
|
Card,
|
|
37507
37716
|
{
|
|
37508
37717
|
stateful: onNavigateToTask && !loading && !disabled,
|
|
37509
37718
|
warning: showWarningAlert,
|
|
37510
37719
|
warningMessage,
|
|
37511
|
-
onClick: loading ? void 0 :
|
|
37512
|
-
onKeyDown: handleKeys(["Enter"],
|
|
37720
|
+
onClick: loading ? void 0 : handleNavigateToTask,
|
|
37721
|
+
onKeyDown: handleKeys(["Enter"], handleNavigateToTask ?? noop$2),
|
|
37513
37722
|
className: "adyen-task",
|
|
37514
37723
|
disabled,
|
|
37515
37724
|
children: /* @__PURE__ */ jsxs(
|
|
@@ -37523,7 +37732,7 @@ const TaskListItem = ({
|
|
|
37523
37732
|
/* @__PURE__ */ jsxs("div", { className: "adyen-task-item__header", children: [
|
|
37524
37733
|
/* @__PURE__ */ jsxs("div", { className: "adyen-task-item__heading", children: [
|
|
37525
37734
|
/* @__PURE__ */ jsx("span", { className: "adyen-task-item__icon-wrapper", children: /* @__PURE__ */ jsx(Icon, { name: icon }) }),
|
|
37526
|
-
/* @__PURE__ */ jsx("div", { className: "adyen-task-item__body", children: /* @__PURE__ */ jsx("span", { className: "adyen-task-item__title", children: title }) })
|
|
37735
|
+
/* @__PURE__ */ jsx("div", { className: "adyen-task-item__body", children: /* @__PURE__ */ jsx("span", { className: "adyen-task-item__title", children: title || i18n.get(titleKey) }) })
|
|
37527
37736
|
] }),
|
|
37528
37737
|
info && /* @__PURE__ */ jsxs("div", { className: "adyen-task-item__info", children: [
|
|
37529
37738
|
/* @__PURE__ */ jsx(Icon, { name: "info-circle" }),
|
|
@@ -37576,6 +37785,7 @@ const PayoutAccountTaskListItem = ({
|
|
|
37576
37785
|
disabled: isInstantVerificationAccount && status === TaskStatus.PROCESSING,
|
|
37577
37786
|
onNavigateToTask: isInstantVerificationAccount ? void 0 : onNavigateToTask,
|
|
37578
37787
|
icon: "payout",
|
|
37788
|
+
titleKey: "accountNumber",
|
|
37579
37789
|
title: obscuredAccountNumber,
|
|
37580
37790
|
status,
|
|
37581
37791
|
problems: (_a2 = capabilityProblems == null ? void 0 : capabilityProblems.BankAccount) == null ? void 0 : _a2[account.id],
|
|
@@ -37744,7 +37954,7 @@ function TaskList({
|
|
|
37744
37954
|
{
|
|
37745
37955
|
onNavigateToTask: handleOnNavigateToTaskIndividual,
|
|
37746
37956
|
icon: "decision-maker",
|
|
37747
|
-
|
|
37957
|
+
titleKey: hasTrust ? "trusteePersonalDetails" : "personalDetails",
|
|
37748
37958
|
status: getTaskStatus(TaskTypes.INDIVIDUAL),
|
|
37749
37959
|
problems: (_e2 = capabilityProblems == null ? void 0 : capabilityProblems.LegalEntity) == null ? void 0 : _e2[legalEntityResponse.id]
|
|
37750
37960
|
}
|
|
@@ -37754,7 +37964,7 @@ function TaskList({
|
|
|
37754
37964
|
{
|
|
37755
37965
|
onNavigateToTask: handleOnNavigateToTaskLegalRepresentative,
|
|
37756
37966
|
icon: "decision-maker",
|
|
37757
|
-
|
|
37967
|
+
titleKey: "legalRepresentative",
|
|
37758
37968
|
status: getTaskStatus(TaskTypes.LEGAL_REPRESENTATIVE_DETAILS)
|
|
37759
37969
|
}
|
|
37760
37970
|
),
|
|
@@ -37763,9 +37973,7 @@ function TaskList({
|
|
|
37763
37973
|
{
|
|
37764
37974
|
onNavigateToTask: handleOnNavigateToSoleProp,
|
|
37765
37975
|
icon: "company",
|
|
37766
|
-
|
|
37767
|
-
canChangeEntityType ? "soleProprietorshipDetails" : "soleProprietorDetails"
|
|
37768
|
-
),
|
|
37976
|
+
titleKey: canChangeEntityType ? "soleProprietorshipDetails" : "soleProprietorDetails",
|
|
37769
37977
|
status: getTaskStatus(TaskTypes.SOLE_PROPRIETOR_COMPANY),
|
|
37770
37978
|
problems: getOwnSolePropProblems(legalEntityResponse, capabilityProblems)
|
|
37771
37979
|
}
|
|
@@ -37776,7 +37984,7 @@ function TaskList({
|
|
|
37776
37984
|
testId: TaskTypes.COMPANY,
|
|
37777
37985
|
onNavigateToTask: handleOnNavigateToTaskCompany,
|
|
37778
37986
|
icon: "company",
|
|
37779
|
-
|
|
37987
|
+
titleKey: hasTrust ? "companyTrusteeDetails" : "companyDetails",
|
|
37780
37988
|
status: getTaskStatus(TaskTypes.COMPANY),
|
|
37781
37989
|
problems: (_f2 = capabilityProblems == null ? void 0 : capabilityProblems.LegalEntity) == null ? void 0 : _f2[legalEntityResponse.id]
|
|
37782
37990
|
}
|
|
@@ -37787,7 +37995,7 @@ function TaskList({
|
|
|
37787
37995
|
testId: TaskTypes.BUSINESS_DETAILS,
|
|
37788
37996
|
onNavigateToTask: handleOnNavigateToTaskBusinessDetails,
|
|
37789
37997
|
icon: "company",
|
|
37790
|
-
|
|
37998
|
+
titleKey: hasTrust ? "businessTrusteeDetails" : "businessDetails",
|
|
37791
37999
|
status: getTaskStatus(TaskTypes.BUSINESS_DETAILS),
|
|
37792
38000
|
problems: (_g2 = capabilityProblems == null ? void 0 : capabilityProblems.LegalEntity) == null ? void 0 : _g2[legalEntityResponse.id]
|
|
37793
38001
|
}
|
|
@@ -37797,7 +38005,7 @@ function TaskList({
|
|
|
37797
38005
|
{
|
|
37798
38006
|
onNavigateToTask: handleOnNavigateToTaskDecisionMaker,
|
|
37799
38007
|
icon: "decision-maker",
|
|
37800
|
-
|
|
38008
|
+
titleKey: "decisionMakers",
|
|
37801
38009
|
status: getTaskStatus(TaskTypes.DECISION_MAKER_OVERVIEW),
|
|
37802
38010
|
showWarningAlert: showDecisionMakersWarning,
|
|
37803
38011
|
warningMessage: remediationMessages[TaskTypes.DECISION_MAKER]
|
|
@@ -37808,7 +38016,7 @@ function TaskList({
|
|
|
37808
38016
|
{
|
|
37809
38017
|
onNavigateToTask: handleOnNavigateToTaskCustomerSupport,
|
|
37810
38018
|
icon: "webinar",
|
|
37811
|
-
|
|
38019
|
+
titleKey: "customerSupport",
|
|
37812
38020
|
status: getTaskStatus(TaskTypes.CUSTOMER_SUPPORT)
|
|
37813
38021
|
}
|
|
37814
38022
|
)
|
|
@@ -37821,7 +38029,7 @@ function TaskList({
|
|
|
37821
38029
|
{
|
|
37822
38030
|
onNavigateToTask: handleOnNavigateToTaskTrust,
|
|
37823
38031
|
icon: "trust",
|
|
37824
|
-
|
|
38032
|
+
titleKey: "trustDetails",
|
|
37825
38033
|
status: getTaskStatus(TaskTypes.TRUST),
|
|
37826
38034
|
problems: getOwnTrustProblems(legalEntityResponse, capabilityProblems)
|
|
37827
38035
|
}
|
|
@@ -37831,7 +38039,7 @@ function TaskList({
|
|
|
37831
38039
|
{
|
|
37832
38040
|
onNavigateToTask: handleOnNavigateToTaskTrustMember,
|
|
37833
38041
|
icon: "decision-maker",
|
|
37834
|
-
|
|
38042
|
+
titleKey: "trustMembers",
|
|
37835
38043
|
status: getTaskStatus(TaskTypes.TRUST_MEMBER_OVERVIEW)
|
|
37836
38044
|
}
|
|
37837
38045
|
)
|
|
@@ -37841,7 +38049,7 @@ function TaskList({
|
|
|
37841
38049
|
{
|
|
37842
38050
|
onNavigateToTask: handleOnNavigateToSourceOfFunds,
|
|
37843
38051
|
icon: "cash-stack",
|
|
37844
|
-
|
|
38052
|
+
titleKey: "fundingSources",
|
|
37845
38053
|
status: getTaskStatus(TaskTypes.SOURCE_OF_FUNDS),
|
|
37846
38054
|
problems: getOwnTrustProblems(legalEntityResponse, capabilityProblems)
|
|
37847
38055
|
}
|
|
@@ -37883,7 +38091,7 @@ function TaskList({
|
|
|
37883
38091
|
{
|
|
37884
38092
|
onNavigateToTask: () => handleOnNavigateToTaskPayout(),
|
|
37885
38093
|
icon: "payout",
|
|
37886
|
-
|
|
38094
|
+
titleKey: canChangeEntityType ? "bankAccountDetails" : hasPayinTaskNotPayout ? "payinDetails" : "payoutDetails",
|
|
37887
38095
|
status: getTaskStatus(hasPayinTaskNotPayout ? TaskTypes.PAYIN : TaskTypes.PAYOUT),
|
|
37888
38096
|
disabled: !canAddPayoutAccount,
|
|
37889
38097
|
problems: getEmptyBankAccountProblems()
|
|
@@ -37897,7 +38105,7 @@ function TaskList({
|
|
|
37897
38105
|
{
|
|
37898
38106
|
onNavigateToTask: handleOnNavigateToServiceAgreement,
|
|
37899
38107
|
icon: "contract",
|
|
37900
|
-
|
|
38108
|
+
titleKey: "signServiceAgreement",
|
|
37901
38109
|
disabled: areServiceAgreementTasksDisabled,
|
|
37902
38110
|
status: serviceAgreementTypes.length ? TaskStatus.SIGN : TaskStatus.SIGNED,
|
|
37903
38111
|
info: areServiceAgreementTasksDisabled ? i18n.get("requiresSignatory") : void 0
|
|
@@ -37908,7 +38116,7 @@ function TaskList({
|
|
|
37908
38116
|
{
|
|
37909
38117
|
onNavigateToTask: handleOnNavigateToPci,
|
|
37910
38118
|
icon: "pci",
|
|
37911
|
-
|
|
38119
|
+
titleKey: "pciDssQuestionnaire",
|
|
37912
38120
|
status: canDownloadPci ? TaskStatus.DOWNLOAD : TaskStatus.SIGN,
|
|
37913
38121
|
statusLabel: canDownloadPci ? i18n.get("downloadACopy") : void 0,
|
|
37914
38122
|
downloadHandler: onPciDownload,
|
|
@@ -37922,7 +38130,7 @@ function TaskList({
|
|
|
37922
38130
|
{
|
|
37923
38131
|
onNavigateToTask: handleOnNavigateToTaskReview,
|
|
37924
38132
|
icon: "review",
|
|
37925
|
-
|
|
38133
|
+
titleKey: "submitReviewOfYourData",
|
|
37926
38134
|
status: TaskStatus.SUBMIT,
|
|
37927
38135
|
problems: (_h2 = capabilityProblems == null ? void 0 : capabilityProblems.LegalEntity) == null ? void 0 : _h2[legalEntityResponse.id],
|
|
37928
38136
|
showErrorAlerts: "always"
|
|
@@ -38294,16 +38502,16 @@ const TrustMembersOverview = ({
|
|
|
38294
38502
|
}
|
|
38295
38503
|
);
|
|
38296
38504
|
};
|
|
38297
|
-
const localizeDateString = (dateString, locale) => {
|
|
38505
|
+
const localizeDateString = (dateString, locale, options) => {
|
|
38298
38506
|
const logger2 = createLogger("localizeDateString");
|
|
38299
|
-
const
|
|
38507
|
+
const formatOptions = {
|
|
38300
38508
|
timeZone: "UTC",
|
|
38301
38509
|
year: "numeric",
|
|
38302
38510
|
month: "long",
|
|
38303
38511
|
day: "2-digit"
|
|
38304
38512
|
};
|
|
38305
38513
|
try {
|
|
38306
|
-
return new Intl.DateTimeFormat(locale,
|
|
38514
|
+
return new Intl.DateTimeFormat(locale, formatOptions).format(new Date(dateString));
|
|
38307
38515
|
} catch (err) {
|
|
38308
38516
|
logger2.error(err);
|
|
38309
38517
|
}
|
|
@@ -39205,7 +39413,7 @@ function PayoutDetailsDropin({
|
|
|
39205
39413
|
userEvents.addEvent("Landed on page", {
|
|
39206
39414
|
actionLevel: "task",
|
|
39207
39415
|
actionType: "start",
|
|
39208
|
-
isUsingNewBankingFlowExperiment:
|
|
39416
|
+
isUsingNewBankingFlowExperiment: enableEmphasizedCredentialBankingFlow
|
|
39209
39417
|
});
|
|
39210
39418
|
}, []);
|
|
39211
39419
|
useEffect(() => {
|
|
@@ -39476,6 +39684,10 @@ function PayoutDetailsDropin({
|
|
|
39476
39684
|
if (trustedTransferInstrumentId) {
|
|
39477
39685
|
externalOnSubmit == null ? void 0 : externalOnSubmit({ ...data, id: trustedTransferInstrumentId });
|
|
39478
39686
|
}
|
|
39687
|
+
userEvents.addEvent("Success", {
|
|
39688
|
+
actionLevel: "task",
|
|
39689
|
+
actionType: "submit"
|
|
39690
|
+
});
|
|
39479
39691
|
navigateBackToTaskList == null ? void 0 : navigateBackToTaskList();
|
|
39480
39692
|
} : onSubmit
|
|
39481
39693
|
});
|
|
@@ -39541,20 +39753,6 @@ function PayoutDetailsDropin({
|
|
|
39541
39753
|
}
|
|
39542
39754
|
);
|
|
39543
39755
|
}
|
|
39544
|
-
const outlinedIcon = "adyen-kyc-outlined-icon";
|
|
39545
|
-
const styles$8 = {
|
|
39546
|
-
outlinedIcon
|
|
39547
|
-
};
|
|
39548
|
-
const OutlinedIcon = ({ name }) => /* @__PURE__ */ jsx("div", { className: styles$8.outlinedIcon, children: /* @__PURE__ */ jsx(Icon, { name }) });
|
|
39549
|
-
const Splashscreen = ({ title, subtitle, icon, buttonText, onClick }) => {
|
|
39550
|
-
const { i18n } = useI18nContext();
|
|
39551
|
-
return /* @__PURE__ */ jsxs("div", { className: "adyen-kyc-splashscreen", children: [
|
|
39552
|
-
icon && /* @__PURE__ */ jsx(OutlinedIcon, { name: icon }),
|
|
39553
|
-
/* @__PURE__ */ jsx(Typography, { el: "h2", variant: "title-l", children: title }),
|
|
39554
|
-
/* @__PURE__ */ jsx(Typography, { el: "p", variant: "body", children: subtitle }),
|
|
39555
|
-
onClick && /* @__PURE__ */ jsx(Button, { onClick, label: buttonText ?? i18n.get("finish") })
|
|
39556
|
-
] });
|
|
39557
|
-
};
|
|
39558
39756
|
function ContractViewer({ contract, className: className2, onExpandSection }) {
|
|
39559
39757
|
const classNames = cx("adyen-contract-viewer", className2);
|
|
39560
39758
|
const container = useRef(null);
|
|
@@ -39581,6 +39779,27 @@ const pciValidationRules = {
|
|
|
39581
39779
|
errorMessage: "fieldIsRequired"
|
|
39582
39780
|
}
|
|
39583
39781
|
};
|
|
39782
|
+
const FormEndState = ({ variant = "success", children: children2, className: className2 }) => {
|
|
39783
|
+
const Slot = defineSlots(children2, ["title", "content", "icon", "actions"]);
|
|
39784
|
+
return /* @__PURE__ */ jsxs(
|
|
39785
|
+
"div",
|
|
39786
|
+
{
|
|
39787
|
+
className: cx("adyen-form-end-state", `adyen-form-end-state__icon--${variant}`, className2),
|
|
39788
|
+
role: "alert",
|
|
39789
|
+
children: [
|
|
39790
|
+
/* @__PURE__ */ jsx(Slot, { name: "icon", children: variant === "success" ? /* @__PURE__ */ jsx(Icon, { name: "checkmark" }) : /* @__PURE__ */ jsx(AlertIcon, { variant }) }),
|
|
39791
|
+
/* @__PURE__ */ jsx("span", { className: "adyen-form-end-state__title", children: /* @__PURE__ */ jsx(Slot, { name: "title" }) }),
|
|
39792
|
+
/* @__PURE__ */ jsx("div", { className: "adyen-form-end-state__description", children: /* @__PURE__ */ jsx(Slot, { name: "content" }) }),
|
|
39793
|
+
/* @__PURE__ */ jsx("div", { className: "adyen-form-end-state__actions", children: /* @__PURE__ */ jsx(Slot, { name: "actions" }) })
|
|
39794
|
+
]
|
|
39795
|
+
}
|
|
39796
|
+
);
|
|
39797
|
+
};
|
|
39798
|
+
const outlinedIcon = "adyen-kyc-outlined-icon";
|
|
39799
|
+
const styles$9 = {
|
|
39800
|
+
outlinedIcon
|
|
39801
|
+
};
|
|
39802
|
+
const OutlinedIcon = ({ name }) => /* @__PURE__ */ jsx("div", { className: styles$9.outlinedIcon, children: /* @__PURE__ */ jsx(Icon, { name }) });
|
|
39584
39803
|
const PciFields = ["signer", "acceptPci"];
|
|
39585
39804
|
function PciDropin({
|
|
39586
39805
|
legalEntityResponse,
|
|
@@ -39690,14 +39909,11 @@ function PciDropin({
|
|
|
39690
39909
|
] })
|
|
39691
39910
|
] });
|
|
39692
39911
|
return /* @__PURE__ */ jsxs(MaybeModal, { inline: !asModal, onClose: handleCloseClick, children: [
|
|
39693
|
-
/* @__PURE__ */ jsx(ModalContent, { children: !needsSigning ? /* @__PURE__ */
|
|
39694
|
-
|
|
39695
|
-
{
|
|
39696
|
-
|
|
39697
|
-
|
|
39698
|
-
onClick: handleCloseClick
|
|
39699
|
-
}
|
|
39700
|
-
) : /* @__PURE__ */ jsxs(LoaderWrapper, { status: loadingStatus, formOpacityWhenLoading: 0.3, showSpinner: false, children: [
|
|
39912
|
+
/* @__PURE__ */ jsx(ModalContent, { children: !needsSigning ? /* @__PURE__ */ jsxs(FormEndState, { children: [
|
|
39913
|
+
/* @__PURE__ */ jsx("template", { slot: "title", children: i18n.get("serviceAgreementSignedAndDated") }),
|
|
39914
|
+
/* @__PURE__ */ jsx(OutlinedIcon, { slot: "icon", name: "check" }),
|
|
39915
|
+
/* @__PURE__ */ jsx("div", { slot: "content", children: /* @__PURE__ */ jsx(Button, { onClick: () => handleCloseClick, label: i18n.get("finish") }) })
|
|
39916
|
+
] }) : /* @__PURE__ */ jsxs(LoaderWrapper, { status: loadingStatus, formOpacityWhenLoading: 0.3, showSpinner: false, children: [
|
|
39701
39917
|
hasExpired && /* @__PURE__ */ jsx(ExpiredBanner, {}),
|
|
39702
39918
|
/* @__PURE__ */ jsx(ContractViewer, { contract: pciQuestionnaire, onExpandSection: handleExpandSection }),
|
|
39703
39919
|
/* @__PURE__ */ jsx(
|
|
@@ -40240,11 +40456,11 @@ const TrustRoleAndEntityType = (props) => {
|
|
|
40240
40456
|
] });
|
|
40241
40457
|
};
|
|
40242
40458
|
const settlorExemptionReasonsList = "adyen-kyc-settlor-exemption-reasons-list";
|
|
40243
|
-
const styles$
|
|
40459
|
+
const styles$8 = {
|
|
40244
40460
|
settlorExemptionReasonsList
|
|
40245
40461
|
};
|
|
40246
40462
|
const formatRolesForSummary = (roles, i18n) => roles.map((role) => i18n.get(getRoleName(role))).join(", ");
|
|
40247
|
-
const formatSettlorExemptionReasonsForSummary = (reasons, i18n) => /* @__PURE__ */ jsx("ul", { className: styles$
|
|
40463
|
+
const formatSettlorExemptionReasonsForSummary = (reasons, i18n) => /* @__PURE__ */ jsx("ul", { className: styles$8.settlorExemptionReasonsList, children: reasons.map((reason) => /* @__PURE__ */ jsx("li", { children: i18n.get(reason) }, reason)) });
|
|
40248
40464
|
const formatRoleAndEntityTypeSummary = (data, i18n, isOrganizationSettlorWithExemptionEnabled) => {
|
|
40249
40465
|
var _a2, _b2;
|
|
40250
40466
|
const { trustMemberType, roles } = data;
|
|
@@ -40981,14 +41197,11 @@ function ServiceAgreementDropin({
|
|
|
40981
41197
|
setHasFinished(true);
|
|
40982
41198
|
}
|
|
40983
41199
|
};
|
|
40984
|
-
const endScreen = hasFinished && /* @__PURE__ */
|
|
40985
|
-
|
|
40986
|
-
{
|
|
40987
|
-
|
|
40988
|
-
|
|
40989
|
-
onClick: handleCloseClick
|
|
40990
|
-
}
|
|
40991
|
-
);
|
|
41200
|
+
const endScreen = hasFinished && /* @__PURE__ */ jsxs(FormEndState, { children: [
|
|
41201
|
+
/* @__PURE__ */ jsx("template", { slot: "title", children: i18n.get("serviceAgreementSignedAndDated") }),
|
|
41202
|
+
/* @__PURE__ */ jsx(OutlinedIcon, { slot: "icon", name: "check" }),
|
|
41203
|
+
/* @__PURE__ */ jsx("div", { slot: "content", children: /* @__PURE__ */ jsx(Button, { onClick: () => handleCloseClick, label: i18n.get("finish") }) })
|
|
41204
|
+
] });
|
|
40992
41205
|
return /* @__PURE__ */ jsx(MaybeModal, { inline: !asModal, onClose: handleCloseClick, children: /* @__PURE__ */ jsxs(ModalContent, { children: [
|
|
40993
41206
|
!asEmbedded && sidebar,
|
|
40994
41207
|
endScreen || content,
|
|
@@ -41765,7 +41978,7 @@ const useNavigation = ({
|
|
|
41765
41978
|
};
|
|
41766
41979
|
}, [navigateTo]);
|
|
41767
41980
|
useEffect(() => {
|
|
41768
|
-
const pushedTask = taskHistory.
|
|
41981
|
+
const pushedTask = taskHistory[taskHistory.length - 1];
|
|
41769
41982
|
if (pushedTask === "default") {
|
|
41770
41983
|
const defaultTask = getDefaultTask({
|
|
41771
41984
|
legalEntity: legalEntity2,
|
|
@@ -41787,8 +42000,8 @@ const useNavigation = ({
|
|
|
41787
42000
|
taskHistory
|
|
41788
42001
|
]);
|
|
41789
42002
|
return {
|
|
41790
|
-
currentTask: actualTasks.
|
|
41791
|
-
previousTask: actualTasks.
|
|
42003
|
+
currentTask: actualTasks[actualTasks.length - 1],
|
|
42004
|
+
previousTask: actualTasks[actualTasks.length - 2],
|
|
41792
42005
|
navigateBack,
|
|
41793
42006
|
navigateTo
|
|
41794
42007
|
};
|
|
@@ -42168,7 +42381,7 @@ const tileTitle = "adyen-kyc-tile-title";
|
|
|
42168
42381
|
const tileCheckbox = "adyen-kyc-tile-checkbox";
|
|
42169
42382
|
const tileContainerHorizontal = "adyen-kyc-tile-container-horizontal";
|
|
42170
42383
|
const tileLabel = "adyen-kyc-tile-label";
|
|
42171
|
-
const styles$
|
|
42384
|
+
const styles$7 = {
|
|
42172
42385
|
tileContainer,
|
|
42173
42386
|
tile,
|
|
42174
42387
|
tileIcon,
|
|
@@ -42210,8 +42423,8 @@ function Tile({
|
|
|
42210
42423
|
return /* @__PURE__ */ jsxs(
|
|
42211
42424
|
"label",
|
|
42212
42425
|
{
|
|
42213
|
-
className: cx(styles$
|
|
42214
|
-
[styles$
|
|
42426
|
+
className: cx(styles$7.tileContainer, {
|
|
42427
|
+
[styles$7.tileContainerHorizontal]: isHorizontal
|
|
42215
42428
|
}),
|
|
42216
42429
|
tabIndex: disabled ? -1 : 0,
|
|
42217
42430
|
htmlFor: idUse,
|
|
@@ -42221,7 +42434,7 @@ function Tile({
|
|
|
42221
42434
|
"input",
|
|
42222
42435
|
{
|
|
42223
42436
|
ref: inputNode,
|
|
42224
|
-
className: styles$
|
|
42437
|
+
className: styles$7.tileCheckbox,
|
|
42225
42438
|
disabled,
|
|
42226
42439
|
checked: !!checked,
|
|
42227
42440
|
value,
|
|
@@ -42231,10 +42444,10 @@ function Tile({
|
|
|
42231
42444
|
onChange: handleChange
|
|
42232
42445
|
}
|
|
42233
42446
|
),
|
|
42234
|
-
/* @__PURE__ */ jsxs("div", { className: styles$
|
|
42235
|
-
icon && /* @__PURE__ */ jsx("div", { className: styles$
|
|
42236
|
-
/* @__PURE__ */ jsxs("div", { className: styles$
|
|
42237
|
-
/* @__PURE__ */ jsx(Typography, { el: "h4", variant: "body-strongest", className: styles$
|
|
42447
|
+
/* @__PURE__ */ jsxs("div", { className: styles$7.tile, children: [
|
|
42448
|
+
icon && /* @__PURE__ */ jsx("div", { className: styles$7.tileIcon, children: /* @__PURE__ */ jsx(Icon, { name: icon, testId: icon }) }),
|
|
42449
|
+
/* @__PURE__ */ jsxs("div", { className: styles$7.tileLabel, children: [
|
|
42450
|
+
/* @__PURE__ */ jsx(Typography, { el: "h4", variant: "body-strongest", className: styles$7.tileTitle, children: label }),
|
|
42238
42451
|
subTitle && /* @__PURE__ */ jsx(Typography, { el: "p", variant: "body", children: subTitle })
|
|
42239
42452
|
] })
|
|
42240
42453
|
] })
|
|
@@ -42246,7 +42459,7 @@ const tileGroup = "adyen-kyc-tile-group";
|
|
|
42246
42459
|
const tileGroupError = "adyen-kyc-tile-group-error";
|
|
42247
42460
|
const tileGroupErrorIcon = "adyen-kyc-tile-group-error-icon";
|
|
42248
42461
|
const tileGroupHorizontal = "adyen-kyc-tile-group-horizontal";
|
|
42249
|
-
const styles$
|
|
42462
|
+
const styles$6 = {
|
|
42250
42463
|
tileGroup,
|
|
42251
42464
|
tileGroupError,
|
|
42252
42465
|
tileGroupErrorIcon,
|
|
@@ -42266,15 +42479,15 @@ function TileGroup({
|
|
|
42266
42479
|
const name = nameProp ?? uniqName;
|
|
42267
42480
|
const finalName = allowMultiple ? `${name}[]` : name;
|
|
42268
42481
|
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
42269
|
-
!!errorMessage && /* @__PURE__ */ jsxs("div", { "aria-live": "polite", className: styles$
|
|
42270
|
-
/* @__PURE__ */ jsx("span", { className: styles$
|
|
42482
|
+
!!errorMessage && /* @__PURE__ */ jsxs("div", { "aria-live": "polite", className: styles$6.tileGroupError, children: [
|
|
42483
|
+
/* @__PURE__ */ jsx("span", { className: styles$6.tileGroupErrorIcon, children: /* @__PURE__ */ jsx(Icon, { name: "field-error" }) }),
|
|
42271
42484
|
errorMessage
|
|
42272
42485
|
] }),
|
|
42273
42486
|
/* @__PURE__ */ jsx(
|
|
42274
42487
|
"div",
|
|
42275
42488
|
{
|
|
42276
|
-
className: cx(styles$
|
|
42277
|
-
[styles$
|
|
42489
|
+
className: cx(styles$6.tileGroup, {
|
|
42490
|
+
[styles$6.tileGroupHorizontal]: isHorizontal
|
|
42278
42491
|
}),
|
|
42279
42492
|
children: tiles.map((tile2, index) => {
|
|
42280
42493
|
const { value, id, icon, subTitle, label, disabled } = tile2;
|
|
@@ -43331,7 +43544,7 @@ const sourceOfFundsUploadModalContentFieldRadioGroup = "adyen-kyc-source-of-fund
|
|
|
43331
43544
|
const sourceOfFundsUploadModalContentRequirementsContainer = "adyen-kyc-source-of-funds-upload-modal-content-requirements-container";
|
|
43332
43545
|
const sourceOfFundsUploadListHeading = "adyen-kyc-source-of-funds-upload-list-heading";
|
|
43333
43546
|
const sourceOfFundsUploadListRemoveButton = "adyen-kyc-source-of-funds-upload-list-remove-button";
|
|
43334
|
-
const styles$
|
|
43547
|
+
const styles$5 = {
|
|
43335
43548
|
sourceOfFunds,
|
|
43336
43549
|
sourceOfFundsWrapperLoading,
|
|
43337
43550
|
sourceOfFundsWrapperHeading,
|
|
@@ -43375,7 +43588,7 @@ function AdditionalDataForAssetSale(props) {
|
|
|
43375
43588
|
handleAmountChange("amount");
|
|
43376
43589
|
};
|
|
43377
43590
|
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
43378
|
-
/* @__PURE__ */ jsxs("div", { className: styles$
|
|
43591
|
+
/* @__PURE__ */ jsxs("div", { className: styles$5.sourceOfFundsGridContainer, children: [
|
|
43379
43592
|
/* @__PURE__ */ jsx(
|
|
43380
43593
|
Field,
|
|
43381
43594
|
{
|
|
@@ -43598,21 +43811,21 @@ const SOFFinancierModal = (props) => {
|
|
|
43598
43811
|
{
|
|
43599
43812
|
variant: "title-l",
|
|
43600
43813
|
el: "h3",
|
|
43601
|
-
className: styles$
|
|
43814
|
+
className: styles$5.sourceOfFundsGettingStartedHelpHeader,
|
|
43602
43815
|
children: i18n.get("investorDetails")
|
|
43603
43816
|
}
|
|
43604
43817
|
) }),
|
|
43605
|
-
/* @__PURE__ */ jsx(ModalContent, { children: /* @__PURE__ */ jsxs("div", { className: styles$
|
|
43818
|
+
/* @__PURE__ */ jsx(ModalContent, { children: /* @__PURE__ */ jsxs("div", { className: styles$5.sourceOfFundsSofFinancierForm, children: [
|
|
43606
43819
|
errorMessage && /* @__PURE__ */ jsx(
|
|
43607
43820
|
Alert,
|
|
43608
43821
|
{
|
|
43609
43822
|
title: "Error submitting data",
|
|
43610
43823
|
variant: "error",
|
|
43611
|
-
className: styles$
|
|
43824
|
+
className: styles$5.sourceOfFundsSofFinancierFormError,
|
|
43612
43825
|
children: errorMessage
|
|
43613
43826
|
}
|
|
43614
43827
|
),
|
|
43615
|
-
/* @__PURE__ */ jsxs("div", { className: styles$
|
|
43828
|
+
/* @__PURE__ */ jsxs("div", { className: styles$5.sourceOfFundsSofFinancierFormNameGroup, children: [
|
|
43616
43829
|
/* @__PURE__ */ jsx(
|
|
43617
43830
|
Field,
|
|
43618
43831
|
{
|
|
@@ -43725,7 +43938,7 @@ const SOFFinancierModal = (props) => {
|
|
|
43725
43938
|
}
|
|
43726
43939
|
)
|
|
43727
43940
|
] }) }),
|
|
43728
|
-
/* @__PURE__ */ jsx(ModalFooter, { children: /* @__PURE__ */ jsxs("div", { className: styles$
|
|
43941
|
+
/* @__PURE__ */ jsx(ModalFooter, { children: /* @__PURE__ */ jsxs("div", { className: styles$5.sourceOfFundsFinancierFooter, children: [
|
|
43729
43942
|
Number.isFinite(indexNumber) && /* @__PURE__ */ jsx(
|
|
43730
43943
|
Button,
|
|
43731
43944
|
{
|
|
@@ -43805,19 +44018,19 @@ function AdditionalDataForThirdParty(props) {
|
|
|
43805
44018
|
{
|
|
43806
44019
|
type: "button",
|
|
43807
44020
|
onClick: () => handleShowUpdateFinancierModal(index),
|
|
43808
|
-
className: styles$
|
|
44021
|
+
className: styles$5.sourceOfFundsThirdPartyFundingFinancierGroup,
|
|
43809
44022
|
children: [
|
|
43810
|
-
/* @__PURE__ */ jsxs("div", { className: styles$
|
|
44023
|
+
/* @__PURE__ */ jsxs("div", { className: styles$5.sourceOfFundsThirdPartyFundingNameAvatarGroup, children: [
|
|
43811
44024
|
/* @__PURE__ */ jsx(
|
|
43812
44025
|
Button,
|
|
43813
44026
|
{
|
|
43814
44027
|
tertiary: true,
|
|
43815
44028
|
icon: "user",
|
|
43816
44029
|
onClick: () => handleShowUpdateFinancierModal(index),
|
|
43817
|
-
className: styles$
|
|
44030
|
+
className: styles$5.sourceOfFundsThirdPartyFundingAvatar
|
|
43818
44031
|
}
|
|
43819
44032
|
),
|
|
43820
|
-
/* @__PURE__ */ jsxs("div", { className: styles$
|
|
44033
|
+
/* @__PURE__ */ jsxs("div", { className: styles$5.sourceOfFundsThirdPartyFundingNameAddressGroup, children: [
|
|
43821
44034
|
/* @__PURE__ */ jsxs(Typography, { el: "div", variant: "body-strongest", children: [
|
|
43822
44035
|
financier.firstName,
|
|
43823
44036
|
" ",
|
|
@@ -43836,16 +44049,16 @@ function AdditionalDataForThirdParty(props) {
|
|
|
43836
44049
|
"button",
|
|
43837
44050
|
{
|
|
43838
44051
|
type: "button",
|
|
43839
|
-
className: styles$
|
|
44052
|
+
className: styles$5.sourceOfFundsThirdPartyFundingFinancierGroup,
|
|
43840
44053
|
onClick: handleToggleFinancierModal,
|
|
43841
|
-
children: /* @__PURE__ */ jsxs("div", { className: styles$
|
|
44054
|
+
children: /* @__PURE__ */ jsxs("div", { className: styles$5.sourceOfFundsThirdPartyFundingNameAvatarGroup, children: [
|
|
43842
44055
|
/* @__PURE__ */ jsx(
|
|
43843
44056
|
Button,
|
|
43844
44057
|
{
|
|
43845
44058
|
tertiary: true,
|
|
43846
44059
|
icon: "plus",
|
|
43847
44060
|
onClick: handleToggleFinancierModal,
|
|
43848
|
-
className: styles$
|
|
44061
|
+
className: styles$5.sourceOfFundsThirdPartyFundingAvatar
|
|
43849
44062
|
}
|
|
43850
44063
|
),
|
|
43851
44064
|
/* @__PURE__ */ jsx(Typography, { el: "div", variant: "body-strongest", children: i18n.get("addInvestor") })
|
|
@@ -43882,14 +44095,14 @@ function AdditionalDataOriginatorLegalEntity(props) {
|
|
|
43882
44095
|
Field,
|
|
43883
44096
|
{
|
|
43884
44097
|
name: "originatorType",
|
|
43885
|
-
className: styles$
|
|
44098
|
+
className: styles$5.sourceOfFundsUploadModalContentField,
|
|
43886
44099
|
label: i18n.get("originatorType"),
|
|
43887
44100
|
children: (childProps) => /* @__PURE__ */ jsx(
|
|
43888
44101
|
RadioGroup,
|
|
43889
44102
|
{
|
|
43890
44103
|
...childProps,
|
|
43891
44104
|
name: "originatorType",
|
|
43892
|
-
className: styles$
|
|
44105
|
+
className: styles$5.sourceOfFundsUploadModalContentFieldRadioGroup,
|
|
43893
44106
|
items: radioItems,
|
|
43894
44107
|
value: data.originatorType,
|
|
43895
44108
|
disabled: false,
|
|
@@ -44037,7 +44250,7 @@ function AdditionalDataForInheritance(props) {
|
|
|
44037
44250
|
handleAmountChange("amount");
|
|
44038
44251
|
};
|
|
44039
44252
|
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
44040
|
-
/* @__PURE__ */ jsxs("div", { className: styles$
|
|
44253
|
+
/* @__PURE__ */ jsxs("div", { className: styles$5.sourceOfFundsGridContainer, children: [
|
|
44041
44254
|
/* @__PURE__ */ jsx(
|
|
44042
44255
|
Field,
|
|
44043
44256
|
{
|
|
@@ -44111,7 +44324,7 @@ function AdditionalDataForInheritance(props) {
|
|
|
44111
44324
|
}
|
|
44112
44325
|
)
|
|
44113
44326
|
] }),
|
|
44114
|
-
/* @__PURE__ */ jsxs("div", { className: styles$
|
|
44327
|
+
/* @__PURE__ */ jsxs("div", { className: styles$5.sourceOfFundsSubHeading, children: [
|
|
44115
44328
|
/* @__PURE__ */ jsx(Typography, { el: "div", variant: "body-strongest", children: i18n.get("describeTheDecedent") }),
|
|
44116
44329
|
/* @__PURE__ */ jsx(Typography, { el: "div", variant: "caption", children: i18n.get("weNeedMoreInformationAboutTheIndividual") })
|
|
44117
44330
|
] }),
|
|
@@ -44168,7 +44381,7 @@ function AdditionalDataForDonation(props) {
|
|
|
44168
44381
|
)
|
|
44169
44382
|
}
|
|
44170
44383
|
),
|
|
44171
|
-
/* @__PURE__ */ jsxs("div", { className: styles$
|
|
44384
|
+
/* @__PURE__ */ jsxs("div", { className: styles$5.sourceOfFundsGridContainer, children: [
|
|
44172
44385
|
/* @__PURE__ */ jsx(
|
|
44173
44386
|
Field,
|
|
44174
44387
|
{
|
|
@@ -44217,7 +44430,7 @@ function AdditionalDataForDonation(props) {
|
|
|
44217
44430
|
}
|
|
44218
44431
|
)
|
|
44219
44432
|
] }),
|
|
44220
|
-
/* @__PURE__ */ jsx("div", { className: styles$
|
|
44433
|
+
/* @__PURE__ */ jsx("div", { className: styles$5.sourceOfFundsSubHeading, children: /* @__PURE__ */ jsx(Typography, { el: "div", variant: "body-strongest", children: i18n.get("benefactorDetails") }) }),
|
|
44221
44434
|
/* @__PURE__ */ jsx(
|
|
44222
44435
|
AdditionalDataOriginatorLegalEntity,
|
|
44223
44436
|
{
|
|
@@ -44390,7 +44603,7 @@ function SourceOfFundsAdditionalData(props) {
|
|
|
44390
44603
|
return null;
|
|
44391
44604
|
}
|
|
44392
44605
|
};
|
|
44393
|
-
return /* @__PURE__ */ jsxs("form", { className: styles$
|
|
44606
|
+
return /* @__PURE__ */ jsxs("form", { className: styles$5.sourceOfFundsAdditionalDataForm, children: [
|
|
44394
44607
|
/* @__PURE__ */ jsx(
|
|
44395
44608
|
ErrorPanel,
|
|
44396
44609
|
{
|
|
@@ -44423,8 +44636,8 @@ function SourceOfFunds(props) {
|
|
|
44423
44636
|
() => getPageHeadings(sourceOfFundsType ?? "adyen"),
|
|
44424
44637
|
[sourceOfFundsType]
|
|
44425
44638
|
);
|
|
44426
|
-
return loading || !activeBusinessLine ? /* @__PURE__ */ jsx("div", { className: styles$
|
|
44427
|
-
/* @__PURE__ */ jsxs("div", { className: styles$
|
|
44639
|
+
return loading || !activeBusinessLine ? /* @__PURE__ */ jsx("div", { className: styles$5.sourceOfFundsWrapperLoading, children: /* @__PURE__ */ jsx(Loader, { size: "medium" }) }) : /* @__PURE__ */ jsxs("div", { className: "adyen-kyc-form-wrapper", children: [
|
|
44640
|
+
/* @__PURE__ */ jsxs("div", { className: styles$5.sourceOfFundsWrapperHeading, children: [
|
|
44428
44641
|
/* @__PURE__ */ jsx(Typography, { el: "h1", variant: "title-l", children: i18n.get(
|
|
44429
44642
|
(activeForm == null ? void 0 : activeForm.formId) === "additionalData" ? pageHeadings.heading : {
|
|
44430
44643
|
key: "selectASourceOfFunding",
|
|
@@ -44433,7 +44646,7 @@ function SourceOfFunds(props) {
|
|
|
44433
44646
|
}
|
|
44434
44647
|
}
|
|
44435
44648
|
) }),
|
|
44436
|
-
/* @__PURE__ */ jsxs(Typography, { className: styles$
|
|
44649
|
+
/* @__PURE__ */ jsxs(Typography, { className: styles$5.sourceOfFundsWrapperDescription, children: [
|
|
44437
44650
|
(activeForm == null ? void 0 : activeForm.formId) === "additionalData" && pageHeadings.description && i18n.get(pageHeadings.description),
|
|
44438
44651
|
allSoFTypes.length === 0 && i18n.get("noCategoriesAvailable")
|
|
44439
44652
|
] })
|
|
@@ -44460,19 +44673,19 @@ const description = "adyen-kyc-description";
|
|
|
44460
44673
|
const descriptionSectionField = "adyen-kyc-description-section-field";
|
|
44461
44674
|
const descriptionSectionLabel = "adyen-kyc-description-section-label";
|
|
44462
44675
|
const descriptionSectionData = "adyen-kyc-description-section-data";
|
|
44463
|
-
const styles$
|
|
44676
|
+
const styles$4 = {
|
|
44464
44677
|
description,
|
|
44465
44678
|
descriptionSectionField,
|
|
44466
44679
|
descriptionSectionLabel,
|
|
44467
44680
|
descriptionSectionData
|
|
44468
44681
|
};
|
|
44469
44682
|
const Description = ({ className: className2, list }) => {
|
|
44470
|
-
const descriptionClassNames = cx(styles$
|
|
44471
|
-
return /* @__PURE__ */ jsx("dl", { className: descriptionClassNames, children: list.map(({ term, details }, index) => /* @__PURE__ */ jsxs("div", { className: styles$
|
|
44472
|
-
/* @__PURE__ */ jsx("dt", { className: styles$
|
|
44473
|
-
Array.isArray(details) ? /* @__PURE__ */ jsx("dd", { className: styles$
|
|
44683
|
+
const descriptionClassNames = cx(styles$4.description, className2);
|
|
44684
|
+
return /* @__PURE__ */ jsx("dl", { className: descriptionClassNames, children: list.map(({ term, details }, index) => /* @__PURE__ */ jsxs("div", { className: styles$4.descriptionSectionField, children: [
|
|
44685
|
+
/* @__PURE__ */ jsx("dt", { className: styles$4.descriptionSectionLabel, children: term }),
|
|
44686
|
+
Array.isArray(details) ? /* @__PURE__ */ jsx("dd", { className: styles$4.descriptionSectionData, children: details.map((detail, index2) => {
|
|
44474
44687
|
return /* @__PURE__ */ jsx("div", { children: detail }, index2);
|
|
44475
|
-
}) }) : /* @__PURE__ */ jsx("dd", { className: styles$
|
|
44688
|
+
}) }) : /* @__PURE__ */ jsx("dd", { className: styles$4.descriptionSectionData, children: details })
|
|
44476
44689
|
] }, index)) });
|
|
44477
44690
|
};
|
|
44478
44691
|
function SourceOfFundsGettingStartedCard(props) {
|
|
@@ -44481,9 +44694,9 @@ function SourceOfFundsGettingStartedCard(props) {
|
|
|
44481
44694
|
return /* @__PURE__ */ jsx(
|
|
44482
44695
|
Card,
|
|
44483
44696
|
{
|
|
44484
|
-
className: styles$
|
|
44485
|
-
headerClassName: styles$
|
|
44486
|
-
bodyClassName: styles$
|
|
44697
|
+
className: styles$5.sourceOfFundsGettingStartedCardsCard,
|
|
44698
|
+
headerClassName: styles$5.sourceOfFundsGettingStartedCardsCardHeader,
|
|
44699
|
+
bodyClassName: styles$5.sourceOfFundsGettingStartedCardsCardBody,
|
|
44487
44700
|
title,
|
|
44488
44701
|
stateful: true,
|
|
44489
44702
|
onClick,
|
|
@@ -44499,7 +44712,7 @@ function SourceOfFundsGettingStartedCard(props) {
|
|
|
44499
44712
|
children: isEdit && (meta == null ? void 0 : meta.length) && /* @__PURE__ */ jsx(
|
|
44500
44713
|
Description,
|
|
44501
44714
|
{
|
|
44502
|
-
className: styles$
|
|
44715
|
+
className: styles$5.sourceOfFundsGettingStartedCardsCardDescription,
|
|
44503
44716
|
list: meta
|
|
44504
44717
|
}
|
|
44505
44718
|
)
|
|
@@ -44598,7 +44811,7 @@ const SourceOfFundsGettingStarted = ({
|
|
|
44598
44811
|
return /* @__PURE__ */ jsxs(
|
|
44599
44812
|
"div",
|
|
44600
44813
|
{
|
|
44601
|
-
className: styles$
|
|
44814
|
+
className: styles$5.sourceOfFundsGettingStarted,
|
|
44602
44815
|
"data-testid": "source-of-funds-getting-started",
|
|
44603
44816
|
children: [
|
|
44604
44817
|
!hasSourceOfFunds && /* @__PURE__ */ jsx(
|
|
@@ -44607,13 +44820,13 @@ const SourceOfFundsGettingStarted = ({
|
|
|
44607
44820
|
type: "image",
|
|
44608
44821
|
testId: "source-of-funds-getting-started-icon",
|
|
44609
44822
|
name: "source-of-funds",
|
|
44610
|
-
className: styles$
|
|
44823
|
+
className: styles$5.sourceOfFundsGettingStartedIcon
|
|
44611
44824
|
}
|
|
44612
44825
|
),
|
|
44613
|
-
/* @__PURE__ */ jsx(Typography, { className: styles$
|
|
44826
|
+
/* @__PURE__ */ jsx(Typography, { className: styles$5.sourceOfFundsGettingStartedHeading, el: "h2", variant: "title-l", children: i18n.get("financialProductFundingSources") }),
|
|
44614
44827
|
hasSourceOfFunds && /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
44615
|
-
/* @__PURE__ */ jsx(Typography, { className: styles$
|
|
44616
|
-
/* @__PURE__ */ jsx("div", { className: styles$
|
|
44828
|
+
/* @__PURE__ */ jsx(Typography, { className: styles$5.sourceOfFundsGettingStartedBody, children: i18n.get("addAllSourcesOfFundsBeingUsed") }),
|
|
44829
|
+
/* @__PURE__ */ jsx("div", { className: styles$5.sourceOfFundsGettingStartedCards, children: mapBusinessLines(businessLines) }),
|
|
44617
44830
|
handleCancelClick && /* @__PURE__ */ jsx(
|
|
44618
44831
|
Button,
|
|
44619
44832
|
{
|
|
@@ -44621,20 +44834,20 @@ const SourceOfFundsGettingStarted = ({
|
|
|
44621
44834
|
block: true,
|
|
44622
44835
|
large: true,
|
|
44623
44836
|
testId: "source-of-funds-getting-return-button",
|
|
44624
|
-
className: styles$
|
|
44837
|
+
className: styles$5.sourceOfFundsGettingStartedCancelButton,
|
|
44625
44838
|
onClick: handleCancelClick,
|
|
44626
44839
|
label: i18n.get("returnToTaskList")
|
|
44627
44840
|
}
|
|
44628
44841
|
)
|
|
44629
44842
|
] }),
|
|
44630
44843
|
!hasSourceOfFunds && /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
44631
|
-
/* @__PURE__ */ jsx(Typography, { className: styles$
|
|
44632
|
-
/* @__PURE__ */ jsxs("div", { className: styles$
|
|
44844
|
+
/* @__PURE__ */ jsx(Typography, { className: styles$5.sourceOfFundsGettingStartedBody, children: i18n.get("inTheNextStepWellCollectInformation") }),
|
|
44845
|
+
/* @__PURE__ */ jsxs("div", { className: styles$5.sourceOfFundsGettingStartedActions, children: [
|
|
44633
44846
|
/* @__PURE__ */ jsx(
|
|
44634
44847
|
Button,
|
|
44635
44848
|
{
|
|
44636
44849
|
large: true,
|
|
44637
|
-
className: styles$
|
|
44850
|
+
className: styles$5.sourceOfFundsGettingStartedPrimaryButton,
|
|
44638
44851
|
label: i18n.get("gettingStarted"),
|
|
44639
44852
|
block: true,
|
|
44640
44853
|
testId: "source-of-funds-getting-primary-button",
|
|
@@ -44736,23 +44949,23 @@ const SOFUploadModal = (props) => {
|
|
|
44736
44949
|
{
|
|
44737
44950
|
variant: "title-l",
|
|
44738
44951
|
el: "h2",
|
|
44739
|
-
className: styles$
|
|
44952
|
+
className: styles$5.sourceOfFundsGettingStartedHelpHeader,
|
|
44740
44953
|
children: i18n.get("uploadASupportingDocument")
|
|
44741
44954
|
}
|
|
44742
44955
|
) }),
|
|
44743
|
-
/* @__PURE__ */ jsx(ModalContent, { children: /* @__PURE__ */ jsxs("div", { className: styles$
|
|
44956
|
+
/* @__PURE__ */ jsx(ModalContent, { children: /* @__PURE__ */ jsxs("div", { className: styles$5.sourceOfFundsUploadModalContent, children: [
|
|
44744
44957
|
(businessLines == null ? void 0 : businessLines.length) > 1 ? /* @__PURE__ */ jsx(
|
|
44745
44958
|
Field,
|
|
44746
44959
|
{
|
|
44747
44960
|
name: "service",
|
|
44748
|
-
className: styles$
|
|
44961
|
+
className: styles$5.sourceOfFundsUploadModalContentField,
|
|
44749
44962
|
label: i18n.get("whatFinancialProductIsThisFor"),
|
|
44750
44963
|
children: (childProps) => /* @__PURE__ */ jsx(
|
|
44751
44964
|
RadioGroup,
|
|
44752
44965
|
{
|
|
44753
44966
|
...childProps,
|
|
44754
44967
|
name: "service",
|
|
44755
|
-
className: styles$
|
|
44968
|
+
className: styles$5.sourceOfFundsUploadModalContentFieldRadioGroup,
|
|
44756
44969
|
items: serviceRadioItems,
|
|
44757
44970
|
value: selectedService,
|
|
44758
44971
|
disabled: false,
|
|
@@ -44769,7 +44982,7 @@ const SOFUploadModal = (props) => {
|
|
|
44769
44982
|
name: "documentType",
|
|
44770
44983
|
label: i18n.get("documentType"),
|
|
44771
44984
|
"data-testid": "documentType",
|
|
44772
|
-
className: styles$
|
|
44985
|
+
className: styles$5.sourceOfFundsUploadModalContentField,
|
|
44773
44986
|
children: (childProps) => /* @__PURE__ */ jsx(
|
|
44774
44987
|
Select,
|
|
44775
44988
|
{
|
|
@@ -44783,7 +44996,7 @@ const SOFUploadModal = (props) => {
|
|
|
44783
44996
|
)
|
|
44784
44997
|
}
|
|
44785
44998
|
),
|
|
44786
|
-
(documentRequirements == null ? void 0 : documentRequirements.length) ? /* @__PURE__ */ jsxs("div", { className: styles$
|
|
44999
|
+
(documentRequirements == null ? void 0 : documentRequirements.length) ? /* @__PURE__ */ jsxs("div", { className: styles$5.sourceOfFundsUploadModalContentRequirementsContainer, children: [
|
|
44787
45000
|
/* @__PURE__ */ jsx(Typography, { variant: "body-strongest", el: "div", children: i18n.get("documentRequirements") }),
|
|
44788
45001
|
/* @__PURE__ */ jsx("ul", { children: documentRequirements == null ? void 0 : documentRequirements.map((requirement) => /* @__PURE__ */ jsx("li", { children: /* @__PURE__ */ jsx(Typography, { variant: "body-stronger", el: "div", children: i18n.get(requirement) }) }, requirement)) })
|
|
44789
45002
|
] }) : null,
|
|
@@ -44849,10 +45062,10 @@ const SourceOfFundsUpload = ({
|
|
|
44849
45062
|
}
|
|
44850
45063
|
}
|
|
44851
45064
|
};
|
|
44852
|
-
return /* @__PURE__ */ jsxs("div", { className: styles$
|
|
44853
|
-
/* @__PURE__ */ jsxs("div", { className: styles$
|
|
45065
|
+
return /* @__PURE__ */ jsxs("div", { className: styles$5.sourceOfFundsUploadList, children: [
|
|
45066
|
+
/* @__PURE__ */ jsxs("div", { className: styles$5.sourceOfFundsUploadListHeading, children: [
|
|
44854
45067
|
/* @__PURE__ */ jsx(Typography, { el: "h1", variant: "title-l", children: i18n.get("supportingDocuments") }),
|
|
44855
|
-
/* @__PURE__ */ jsx(Typography, { className: styles$
|
|
45068
|
+
/* @__PURE__ */ jsx(Typography, { className: styles$5.sourceOfFundsWrapperDescription, children: (sourceOfFundsCategories == null ? void 0 : sourceOfFundsCategories.length) ? i18n.get("weNeedProofOfFundingPlural", {
|
|
44856
45069
|
values: {
|
|
44857
45070
|
category1_name: sourceOfFundsCategories[0] ?? "",
|
|
44858
45071
|
category2_name: sourceOfFundsCategories[1] ?? ""
|
|
@@ -44864,12 +45077,12 @@ const SourceOfFundsUpload = ({
|
|
|
44864
45077
|
documents == null ? void 0 : documents.map((document2) => /* @__PURE__ */ jsxs(
|
|
44865
45078
|
"div",
|
|
44866
45079
|
{
|
|
44867
|
-
className: styles$
|
|
45080
|
+
className: styles$5.sourceOfFundsThirdPartyFundingFinancierGroup,
|
|
44868
45081
|
onClick: () => setDocToDelete(document2),
|
|
44869
45082
|
children: [
|
|
44870
|
-
/* @__PURE__ */ jsxs("div", { className: styles$
|
|
44871
|
-
/* @__PURE__ */ jsx("div", { className: styles$
|
|
44872
|
-
/* @__PURE__ */ jsxs("div", { className: styles$
|
|
45083
|
+
/* @__PURE__ */ jsxs("div", { className: styles$5.sourceOfFundsThirdPartyFundingNameAvatarGroup, children: [
|
|
45084
|
+
/* @__PURE__ */ jsx("div", { className: styles$5.sourceOfFundsThirdPartyFundingAvatar, children: /* @__PURE__ */ jsx(Icon, { name: "document" }) }),
|
|
45085
|
+
/* @__PURE__ */ jsxs("div", { className: styles$5.sourceOfFundsThirdPartyFundingNameAddressGroup, children: [
|
|
44873
45086
|
/* @__PURE__ */ jsx(Typography, { el: "div", variant: "body-strongest", children: document2.fileName }),
|
|
44874
45087
|
/* @__PURE__ */ jsx(Typography, { el: "div", variant: "caption", children: parseSOFDocumentDescription(i18n, document2.description) })
|
|
44875
45088
|
] })
|
|
@@ -44877,7 +45090,7 @@ const SourceOfFundsUpload = ({
|
|
|
44877
45090
|
/* @__PURE__ */ jsx(
|
|
44878
45091
|
Button,
|
|
44879
45092
|
{
|
|
44880
|
-
className: styles$
|
|
45093
|
+
className: styles$5.sourceOfFundsUploadListRemoveButton,
|
|
44881
45094
|
iconOnly: true,
|
|
44882
45095
|
icon: "cross",
|
|
44883
45096
|
onClick: () => setDocToDelete(document2),
|
|
@@ -44892,16 +45105,16 @@ const SourceOfFundsUpload = ({
|
|
|
44892
45105
|
"button",
|
|
44893
45106
|
{
|
|
44894
45107
|
type: "button",
|
|
44895
|
-
className: styles$
|
|
45108
|
+
className: styles$5.sourceOfFundsThirdPartyFundingFinancierGroup,
|
|
44896
45109
|
onClick: openUploadModal,
|
|
44897
|
-
children: /* @__PURE__ */ jsxs("div", { className: styles$
|
|
45110
|
+
children: /* @__PURE__ */ jsxs("div", { className: styles$5.sourceOfFundsThirdPartyFundingNameAvatarGroup, children: [
|
|
44898
45111
|
/* @__PURE__ */ jsx(
|
|
44899
45112
|
Button,
|
|
44900
45113
|
{
|
|
44901
45114
|
tertiary: true,
|
|
44902
45115
|
icon: "plus",
|
|
44903
45116
|
onClick: openUploadModal,
|
|
44904
|
-
className: styles$
|
|
45117
|
+
className: styles$5.sourceOfFundsUploadDocumentCardsIcon,
|
|
44905
45118
|
testId: "source-of-funds-upload-button"
|
|
44906
45119
|
}
|
|
44907
45120
|
),
|
|
@@ -44909,7 +45122,7 @@ const SourceOfFundsUpload = ({
|
|
|
44909
45122
|
] })
|
|
44910
45123
|
}
|
|
44911
45124
|
),
|
|
44912
|
-
/* @__PURE__ */ jsx("div", { className: styles$
|
|
45125
|
+
/* @__PURE__ */ jsx("div", { className: styles$5.sourceOfFundsGettingStartedActions, children: handleNavigateToSummary && /* @__PURE__ */ jsx(
|
|
44913
45126
|
Button,
|
|
44914
45127
|
{
|
|
44915
45128
|
tertiary: true,
|
|
@@ -45020,6 +45233,10 @@ function SourceOfFundsDropin({
|
|
|
45020
45233
|
}
|
|
45021
45234
|
};
|
|
45022
45235
|
useEffect(() => {
|
|
45236
|
+
userEvents.addEvent("Landed on page", {
|
|
45237
|
+
actionLevel: "task",
|
|
45238
|
+
actionType: "start"
|
|
45239
|
+
});
|
|
45023
45240
|
loadBusinessLines(legalEntityResponse.id);
|
|
45024
45241
|
}, []);
|
|
45025
45242
|
const canSubmitForm = useMemo(
|
|
@@ -45151,7 +45368,7 @@ function SourceOfFundsDropin({
|
|
|
45151
45368
|
const handleNavigateToUploadPage = () => {
|
|
45152
45369
|
setShowUploadPage(true);
|
|
45153
45370
|
};
|
|
45154
|
-
return /* @__PURE__ */ jsx("div", { className: styles$
|
|
45371
|
+
return /* @__PURE__ */ jsx("div", { className: styles$5.sourceOfFunds, children: loading ? /* @__PURE__ */ jsx(Loader, { size: "medium" }) : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
45155
45372
|
gettingStarted && !showUploadPage && /* @__PURE__ */ jsx(
|
|
45156
45373
|
SourceOfFundsGettingStarted,
|
|
45157
45374
|
{
|
|
@@ -45695,6 +45912,9 @@ function DropinComposer({
|
|
|
45695
45912
|
actionType: "start"
|
|
45696
45913
|
});
|
|
45697
45914
|
}, []);
|
|
45915
|
+
useEffect(() => {
|
|
45916
|
+
userEvents.updateBaseTrackingPayload({ task: currentTask });
|
|
45917
|
+
}, [currentTask]);
|
|
45698
45918
|
useEffect(() => {
|
|
45699
45919
|
const fetchConfiguration = async () => {
|
|
45700
45920
|
const data = await getConfiguration2({
|
|
@@ -47008,7 +47228,6 @@ function AcceptTermsOfServiceComponent({
|
|
|
47008
47228
|
await getServiceAgreementAcceptanceInfos2(legalEntityId2).then(({ data }) => setServiceAgreementAcceptanceInfos(data)).catch(logger$l.error);
|
|
47009
47229
|
}, [getServiceAgreementAcceptanceInfos2, legalEntityId2]);
|
|
47010
47230
|
const handleSign = useCallback(
|
|
47011
|
-
// @ts-ignore-error:next-line ts does not infer type correctly
|
|
47012
47231
|
async (...params) => {
|
|
47013
47232
|
const serviceAgreement = await acceptServiceAgreement2(...params);
|
|
47014
47233
|
await Promise.all([fetchUnsigned(), fetchSigned()]);
|
|
@@ -47271,7 +47490,7 @@ const embeddedStatusAvatar = "adyen-kyc-embedded-status-avatar";
|
|
|
47271
47490
|
const embeddedStatusLight = "adyen-kyc-embedded-status-light";
|
|
47272
47491
|
const embeddedStatusActionIndicator = "adyen-kyc-embedded-status-action-indicator";
|
|
47273
47492
|
const embeddedStatusInfo = "adyen-kyc-embedded-status-info";
|
|
47274
|
-
const styles$
|
|
47493
|
+
const styles$3 = {
|
|
47275
47494
|
embeddedStatus,
|
|
47276
47495
|
embeddedStatusLoading,
|
|
47277
47496
|
embeddedStatusAvatar,
|
|
@@ -47321,22 +47540,22 @@ const EmbeddedStatus = ({
|
|
|
47321
47540
|
"button",
|
|
47322
47541
|
{
|
|
47323
47542
|
type: "button",
|
|
47324
|
-
className: cx(className2, styles$
|
|
47325
|
-
[styles$
|
|
47326
|
-
[styles$
|
|
47543
|
+
className: cx(className2, styles$3.embeddedStatus, "adyen-kyc-externalComponent", {
|
|
47544
|
+
[styles$3.embeddedStatusLoading]: loading,
|
|
47545
|
+
[styles$3.embeddedStatusLight]: light
|
|
47327
47546
|
}),
|
|
47328
47547
|
onClick,
|
|
47329
47548
|
...props,
|
|
47330
47549
|
children: [
|
|
47331
|
-
/* @__PURE__ */ jsx("section", { className: styles$
|
|
47332
|
-
/* @__PURE__ */ jsx("section", { className: styles$
|
|
47550
|
+
/* @__PURE__ */ jsx("section", { className: styles$3.embeddedStatusAvatar, children: loading ? /* @__PURE__ */ jsx(Skeleton, { height: "100%", width: "100%", circle: true }) : /* @__PURE__ */ jsx(Icon, { className: styles$3.embeddedStatusIcon, name: iconName }) }),
|
|
47551
|
+
/* @__PURE__ */ jsx("section", { className: styles$3.embeddedStatusInfo, children: loading ? /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
47333
47552
|
/* @__PURE__ */ jsx(Skeleton, { text: true, width: "20ch", height: "1em" }),
|
|
47334
47553
|
/* @__PURE__ */ jsx(Skeleton, { text: true, width: "90%", height: "1em" })
|
|
47335
47554
|
] }) : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
47336
47555
|
/* @__PURE__ */ jsx(Typography, { variant: "body-stronger", children: title }),
|
|
47337
47556
|
/* @__PURE__ */ jsx(Typography, { variant: "caption", color: "secondary", children: subtitle })
|
|
47338
47557
|
] }) }),
|
|
47339
|
-
actionIndicator ? /* @__PURE__ */ jsx("section", { className: styles$
|
|
47558
|
+
actionIndicator ? /* @__PURE__ */ jsx("section", { className: styles$3.embeddedStatusButton, children: loading ? /* @__PURE__ */ jsx(Skeleton, { width: "5em", height: "2em" }) : /* @__PURE__ */ jsx(Typography, { variant: "body-stronger", className: styles$3.embeddedStatusActionIndicator, children: i18n.get(actionIndicator.labelKey) }) }) : (statusTag == null ? void 0 : statusTag.translationKey) && /* @__PURE__ */ jsx("section", { className: styles$3.embeddedStatusTag, children: loading ? /* @__PURE__ */ jsx(Skeleton, { width: "8ch", height: "1em" }) : /* @__PURE__ */ jsx(Tag, { variant: statusTag.variant, children: i18n.get(statusTag.translationKey) }) })
|
|
47340
47559
|
]
|
|
47341
47560
|
}
|
|
47342
47561
|
);
|
|
@@ -48060,7 +48279,6 @@ function SignPCIComponent({
|
|
|
48060
48279
|
});
|
|
48061
48280
|
}, [fetchLegalEntity, fetchPciTemplate]);
|
|
48062
48281
|
const handleSign = useCallback(
|
|
48063
|
-
// @ts-ignore-error:next-line ts does not infer type correctly
|
|
48064
48282
|
async (...params) => {
|
|
48065
48283
|
await signPci2(...params);
|
|
48066
48284
|
await Promise.all([fetchLegalEntity(), fetchPciTemplate()]);
|
|
@@ -48075,14 +48293,11 @@ function SignPCIComponent({
|
|
|
48075
48293
|
return /* @__PURE__ */ jsx(Loader, { size: "medium" });
|
|
48076
48294
|
}
|
|
48077
48295
|
if (!hasGenericError) {
|
|
48078
|
-
return /* @__PURE__ */ jsx(MaybeModal, { inline: !modalView, onClose: handleOnClose, children: /* @__PURE__ */ jsx(ModalContent, { children: /* @__PURE__ */
|
|
48079
|
-
|
|
48080
|
-
{
|
|
48081
|
-
|
|
48082
|
-
|
|
48083
|
-
onClick: handleOnClose
|
|
48084
|
-
}
|
|
48085
|
-
) }) });
|
|
48296
|
+
return /* @__PURE__ */ jsx(MaybeModal, { inline: !modalView, onClose: handleOnClose, children: /* @__PURE__ */ jsx(ModalContent, { children: /* @__PURE__ */ jsxs(FormEndState, { children: [
|
|
48297
|
+
/* @__PURE__ */ jsx("template", { slot: "title", children: i18n.get("pciDoesNotNeedSigningOrHasBeenSigned") }),
|
|
48298
|
+
/* @__PURE__ */ jsx(OutlinedIcon, { slot: "icon", name: "check" }),
|
|
48299
|
+
/* @__PURE__ */ jsx("div", { slot: "content", children: /* @__PURE__ */ jsx(Button, { onClick: handleOnClose, label: i18n.get("finish") }) })
|
|
48300
|
+
] }) }) });
|
|
48086
48301
|
}
|
|
48087
48302
|
return pciTemplate ? /* @__PURE__ */ jsx(
|
|
48088
48303
|
PciDropin,
|
|
@@ -49351,22 +49566,6 @@ function AdditionalFieldsForHighExposureUltimateParentCompany(props) {
|
|
|
49351
49566
|
)
|
|
49352
49567
|
] });
|
|
49353
49568
|
}
|
|
49354
|
-
const FormEndState = ({ variant = "success", children: children2, className: className2 }) => {
|
|
49355
|
-
const Slot = defineSlots(children2, ["title", "content", "icon", "actions"]);
|
|
49356
|
-
return /* @__PURE__ */ jsxs(
|
|
49357
|
-
"div",
|
|
49358
|
-
{
|
|
49359
|
-
className: cx("adyen-form-end-state", `adyen-form-end-state__icon--${variant}`, className2),
|
|
49360
|
-
role: "alert",
|
|
49361
|
-
children: [
|
|
49362
|
-
/* @__PURE__ */ jsx(Slot, { name: "icon", children: variant === "success" ? /* @__PURE__ */ jsx(Icon, { name: "checkmark" }) : /* @__PURE__ */ jsx(AlertIcon, { variant }) }),
|
|
49363
|
-
/* @__PURE__ */ jsx("span", { className: "adyen-form-end-state__title", children: /* @__PURE__ */ jsx(Slot, { name: "title" }) }),
|
|
49364
|
-
/* @__PURE__ */ jsx("div", { className: "adyen-form-end-state__description", children: /* @__PURE__ */ jsx(Slot, { name: "content" }) }),
|
|
49365
|
-
/* @__PURE__ */ jsx("div", { className: "adyen-form-end-state__actions", children: /* @__PURE__ */ jsx(Slot, { name: "actions" }) })
|
|
49366
|
-
]
|
|
49367
|
-
}
|
|
49368
|
-
);
|
|
49369
|
-
};
|
|
49370
49569
|
const customLabels = {
|
|
49371
49570
|
company: {
|
|
49372
49571
|
legalForm: "businessStructure",
|
|
@@ -49916,24 +50115,11 @@ function UpdateLegalEntityForHighExposure({
|
|
|
49916
50115
|
}
|
|
49917
50116
|
);
|
|
49918
50117
|
}
|
|
49919
|
-
const
|
|
49920
|
-
|
|
49921
|
-
|
|
49922
|
-
|
|
49923
|
-
|
|
49924
|
-
immediate = false
|
|
49925
|
-
}) => {
|
|
49926
|
-
useEffect(() => {
|
|
49927
|
-
if (skip) return;
|
|
49928
|
-
const pollAndProvideNewValue = () => {
|
|
49929
|
-
poller().then((newValue) => onNewValueReceived(newValue)).catch((err) => console.error(err));
|
|
49930
|
-
};
|
|
49931
|
-
if (immediate) {
|
|
49932
|
-
pollAndProvideNewValue();
|
|
49933
|
-
}
|
|
49934
|
-
const timeoutId = setInterval(pollAndProvideNewValue, pollingInterval);
|
|
49935
|
-
return () => clearInterval(timeoutId);
|
|
49936
|
-
}, [onNewValueReceived, poller, pollingInterval, skip, immediate]);
|
|
50118
|
+
const verification = "adyen-kyc-verification";
|
|
50119
|
+
const verificationDescription = "adyen-kyc-verification-description";
|
|
50120
|
+
const styles$2 = {
|
|
50121
|
+
verification,
|
|
50122
|
+
verificationDescription
|
|
49937
50123
|
};
|
|
49938
50124
|
const coerceError = (err) => {
|
|
49939
50125
|
if (err instanceof Error) return err;
|
|
@@ -49980,7 +50166,7 @@ function ViewVerificationStatusComponent({
|
|
|
49980
50166
|
onRedirect
|
|
49981
50167
|
}) {
|
|
49982
50168
|
const { i18n } = useI18nContext();
|
|
49983
|
-
const {
|
|
50169
|
+
const { generateOnboardingLink: generateOnboardingLink2 } = useComponentApi(legalEntityId2);
|
|
49984
50170
|
const [onboardingStatus, setOnboardingStatus] = useState();
|
|
49985
50171
|
const [alertContent, setAlertContent] = useState();
|
|
49986
50172
|
const content = useMemo(() => {
|
|
@@ -50001,15 +50187,6 @@ function ViewVerificationStatusComponent({
|
|
|
50001
50187
|
},
|
|
50002
50188
|
[i18n, onError]
|
|
50003
50189
|
);
|
|
50004
|
-
const fetchOnboardingStatus = useCallback(async () => {
|
|
50005
|
-
try {
|
|
50006
|
-
const { status } = await getOnboardingStatus2();
|
|
50007
|
-
return status;
|
|
50008
|
-
} catch (error) {
|
|
50009
|
-
handleError2(error, "onboardingRedirectLinkError");
|
|
50010
|
-
return void 0;
|
|
50011
|
-
}
|
|
50012
|
-
}, [getOnboardingStatus2, handleError2]);
|
|
50013
50190
|
const updateOnboardingStatus = useCallback(
|
|
50014
50191
|
(newStatus) => {
|
|
50015
50192
|
if (!newStatus) return;
|
|
@@ -50018,16 +50195,18 @@ function ViewVerificationStatusComponent({
|
|
|
50018
50195
|
},
|
|
50019
50196
|
[onStatusChange]
|
|
50020
50197
|
);
|
|
50021
|
-
|
|
50022
|
-
|
|
50023
|
-
|
|
50024
|
-
|
|
50025
|
-
|
|
50198
|
+
const { isLoading, data, isError: isError2 } = useOnboardingStatus({
|
|
50199
|
+
refetchInterval: (res) => {
|
|
50200
|
+
var _a2;
|
|
50201
|
+
const status = (_a2 = res.state.data) == null ? void 0 : _a2.status;
|
|
50202
|
+
setOnboardingStatus(status);
|
|
50203
|
+
return status === void 0 || !FINAL_STATUSES.includes(status) ? 3e3 : false;
|
|
50204
|
+
}
|
|
50026
50205
|
});
|
|
50027
50206
|
useEffect(() => {
|
|
50028
50207
|
setAlertContent(void 0);
|
|
50029
|
-
|
|
50030
|
-
}, [
|
|
50208
|
+
updateOnboardingStatus(data == null ? void 0 : data.status);
|
|
50209
|
+
}, [data, updateOnboardingStatus]);
|
|
50031
50210
|
const [loadingLinkStatus, setLinkLoadingStatus] = useState("success");
|
|
50032
50211
|
const redirectToAdyen = async () => {
|
|
50033
50212
|
setLinkLoadingStatus("loading");
|
|
@@ -50070,26 +50249,24 @@ function ViewVerificationStatusComponent({
|
|
|
50070
50249
|
{
|
|
50071
50250
|
label: i18n.get(content.ctaButton),
|
|
50072
50251
|
onClick: redirectToAdyen,
|
|
50073
|
-
type: "button",
|
|
50074
|
-
className: "adyen-view-verification-status__button",
|
|
50075
50252
|
role: "link",
|
|
50076
50253
|
loading: loadingLinkStatus === "loading"
|
|
50077
50254
|
}
|
|
50078
50255
|
);
|
|
50079
50256
|
};
|
|
50080
50257
|
const renderBody = () => {
|
|
50081
|
-
if (alertContent) {
|
|
50082
|
-
return /* @__PURE__ */ jsx(Alert, { title: i18n.get(alertContent), variant: "error" });
|
|
50258
|
+
if (alertContent || isError2) {
|
|
50259
|
+
return /* @__PURE__ */ jsx(Alert, { title: i18n.get(alertContent ?? "onboardingRedirectLinkError"), variant: "error" });
|
|
50083
50260
|
}
|
|
50084
|
-
if (content) {
|
|
50261
|
+
if (!isLoading && content) {
|
|
50085
50262
|
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
50086
|
-
hideExplanation ? null : content.description.map((key) => /* @__PURE__ */ jsx("p", { className:
|
|
50087
|
-
/* @__PURE__ */ jsx("div", {
|
|
50263
|
+
hideExplanation ? null : content.description.map((key) => /* @__PURE__ */ jsx("p", { className: styles$2.verificationDescription, children: i18n.get(key) }, key)),
|
|
50264
|
+
/* @__PURE__ */ jsx("div", { children: renderFooter() })
|
|
50088
50265
|
] });
|
|
50089
50266
|
}
|
|
50090
50267
|
return /* @__PURE__ */ jsx(Loader, { size: "medium" });
|
|
50091
50268
|
};
|
|
50092
|
-
return /* @__PURE__ */ jsx("section", { className:
|
|
50269
|
+
return /* @__PURE__ */ jsx("section", { className: styles$2.verification, children: renderBody() });
|
|
50093
50270
|
}
|
|
50094
50271
|
const componentsMap = {
|
|
50095
50272
|
individualDropin: IndividualDropin,
|
|
@@ -50181,7 +50358,6 @@ const useAnalytics = ({ onUserEvent, sdkVersion, componentName }) => {
|
|
|
50181
50358
|
const capabilities = Object.keys(rootLegalEntity.capabilities ?? {});
|
|
50182
50359
|
const loadingContext = `${base}api/${COMPONENTS_API_VERSION}/`;
|
|
50183
50360
|
userEvents.updateBaseTrackingPayload({
|
|
50184
|
-
legalEntityId: rootLegalEntity.id,
|
|
50185
50361
|
entityType: rootLegalEntity.type,
|
|
50186
50362
|
countryCode,
|
|
50187
50363
|
capabilities
|
|
@@ -50626,7 +50802,7 @@ const ConfigurationApiProvider = ({
|
|
|
50626
50802
|
}) => {
|
|
50627
50803
|
const authContext = useAuthContext();
|
|
50628
50804
|
const { isEmbeddedDropin, loadingContext } = authContext;
|
|
50629
|
-
const sdkVersion = "3.
|
|
50805
|
+
const sdkVersion = "3.50.0";
|
|
50630
50806
|
const rootLegalEntityId = useGlobalStore((store) => store.rootLegalEntity.id);
|
|
50631
50807
|
useAnalytics({
|
|
50632
50808
|
onUserEvent,
|
|
@@ -51401,12 +51577,12 @@ const DebugTable = ({
|
|
|
51401
51577
|
"No results found for ",
|
|
51402
51578
|
/* @__PURE__ */ jsx("strong", { children: searchTerm })
|
|
51403
51579
|
] }) : /* @__PURE__ */ jsx("table", { children: /* @__PURE__ */ jsx("tbody", { children: filteredData.map(({ key, value, label, variant }) => /* @__PURE__ */ jsxs("tr", { children: [
|
|
51404
|
-
tagPosition === "before" ? /* @__PURE__ */ jsx("td", { children: /* @__PURE__ */ jsx(Tag, { variant: variant ?? "grey",
|
|
51580
|
+
tagPosition === "before" ? /* @__PURE__ */ jsx("td", { children: /* @__PURE__ */ jsx(Tag, { variant: variant ?? "grey", children: value }) }) : void 0,
|
|
51405
51581
|
/* @__PURE__ */ jsxs("td", { children: [
|
|
51406
51582
|
/* @__PURE__ */ jsx("span", { className: "adyen-kyc-debug-modal__table-key", children: key }),
|
|
51407
51583
|
label && /* @__PURE__ */ jsx("span", { children: label })
|
|
51408
51584
|
] }),
|
|
51409
|
-
tagPosition === "after" ? /* @__PURE__ */ jsx("td", { children: /* @__PURE__ */ jsx(Tag, { variant: variant ?? "grey",
|
|
51585
|
+
tagPosition === "after" ? /* @__PURE__ */ jsx("td", { children: /* @__PURE__ */ jsx(Tag, { variant: variant ?? "grey", children: value }) }) : void 0
|
|
51410
51586
|
] }, key)) }) })
|
|
51411
51587
|
] });
|
|
51412
51588
|
};
|
|
@@ -51510,7 +51686,7 @@ const DebugModal = ({ onExit }) => {
|
|
|
51510
51686
|
const [tab, setTab] = useState("metadata");
|
|
51511
51687
|
const rootLegalEntity = useGlobalStore((store) => store.rootLegalEntity);
|
|
51512
51688
|
const metadata = {
|
|
51513
|
-
sdkVersion: "3.
|
|
51689
|
+
sdkVersion: "3.50.0",
|
|
51514
51690
|
locale: i18n.locale,
|
|
51515
51691
|
rootLegalEntityId: rootLegalEntity.id
|
|
51516
51692
|
};
|
|
@@ -54507,7 +54683,7 @@ var TanstackQueryDevtools = (_k = class {
|
|
|
54507
54683
|
if (__privateGet(this, _Component)) {
|
|
54508
54684
|
Devtools = __privateGet(this, _Component);
|
|
54509
54685
|
} else {
|
|
54510
|
-
Devtools = lazy(() => import("./HO4MOOFI-
|
|
54686
|
+
Devtools = lazy(() => import("./HO4MOOFI-70Nm-7sY.js"));
|
|
54511
54687
|
__privateSet(this, _Component, Devtools);
|
|
54512
54688
|
}
|
|
54513
54689
|
setupStyleSheet(__privateGet(this, _styleNonce), __privateGet(this, _shadowDOMTarget));
|
|
@@ -54629,7 +54805,7 @@ var TanstackQueryDevtoolsPanel = (_l = class {
|
|
|
54629
54805
|
if (__privateGet(this, _Component2)) {
|
|
54630
54806
|
Devtools = __privateGet(this, _Component2);
|
|
54631
54807
|
} else {
|
|
54632
|
-
Devtools = lazy(() => import("./HUY7CZI3-
|
|
54808
|
+
Devtools = lazy(() => import("./HUY7CZI3-1U-zoofU.js"));
|
|
54633
54809
|
__privateSet(this, _Component2, Devtools);
|
|
54634
54810
|
}
|
|
54635
54811
|
setupStyleSheet(__privateGet(this, _styleNonce2), __privateGet(this, _shadowDOMTarget2));
|
|
@@ -54789,7 +54965,7 @@ class UIElement extends BaseElement {
|
|
|
54789
54965
|
constructor() {
|
|
54790
54966
|
super(...arguments);
|
|
54791
54967
|
this.render = () => {
|
|
54792
|
-
const
|
|
54968
|
+
const UIElement2 = this.props.component;
|
|
54793
54969
|
return /* @__PURE__ */ jsx(SettingsProvider, { settings: this.props.settings, children: /* @__PURE__ */ jsx(
|
|
54794
54970
|
ExperimentsContextProvider,
|
|
54795
54971
|
{
|
|
@@ -54821,7 +54997,7 @@ class UIElement extends BaseElement {
|
|
|
54821
54997
|
refreshExpiry: this.props.refreshExpiry,
|
|
54822
54998
|
eventEmitter: this.eventEmitter,
|
|
54823
54999
|
children: /* @__PURE__ */ jsx(DebugWrapper, { children: /* @__PURE__ */ jsx("div", { className: "adyen-kyc-ui-element-container-wrapper", children: /* @__PURE__ */ jsx(AutoResizer, { children: /* @__PURE__ */ jsx("div", { className: "adyen-kyc-ui-element-container", children: /* @__PURE__ */ jsx(ToastContextProvider, { children: /* @__PURE__ */ jsx(StateProvider, { children: /* @__PURE__ */ jsx(
|
|
54824
|
-
|
|
55000
|
+
UIElement2,
|
|
54825
55001
|
{
|
|
54826
55002
|
...this.props.componentProps,
|
|
54827
55003
|
onUnmount: this.remove
|