@adyen/kyc-components 2.69.0 → 2.70.1

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.
@@ -654,6 +654,7 @@ const defaultTrans = {
654
654
  errorMessage_1_5051: "Signing person on the affiliation document could not be verified",
655
655
  errorMessage_1_5052: "The affiliation document verifies the payout entity is not 100% affiliated with the company. Setup can't be continued.",
656
656
  errorMessage_1_5053: "The affiliation document was not issued within the last 6 months",
657
+ errorMessage_1_5064: "The VAT number didn't match the one on the registry.",
657
658
  errorMessage_1_5067: "The legal name didn't match the one on the VAT registry.",
658
659
  errorMessage_1_51: "Organization details didn't match the document",
659
660
  errorMessage_1_52: "Registration document didn't meet requirements",
@@ -1928,6 +1929,7 @@ const KNOWN_BROKEN_PRIMARY_SOURCE_CONNECTIONS = [
1928
1929
  ];
1929
1930
  const KNOWN_DISALLOWED_INDEX_DATASET_STATES = [
1930
1931
  StateCodesUS.California,
1932
+ StateCodesUS.Florida,
1931
1933
  StateCodesUS.Texas
1932
1934
  ];
1933
1935
  const logger$E = createLogger("useBusinessData");
@@ -4345,7 +4347,8 @@ const Select = ({
4345
4347
  if (enableTracking) {
4346
4348
  userEvents.addFieldEvent("Interacted with form field", {
4347
4349
  actionType: "select",
4348
- field: name
4350
+ field: name,
4351
+ returnValue: selectedItem.id
4349
4352
  });
4350
4353
  }
4351
4354
  if (showSearchList) setIsShowList(showSearchList);
@@ -23439,8 +23442,8 @@ const invalidInputRemediationActionMappings = {
23439
23442
  // [{ key: 'documents', type: ['proofOfOwnership'] }] // <---- See DEV-50768,
23440
23443
  "1_508": [],
23441
23444
  // [{ key: 'documents', type: ['proofOfOwnership'] }] // <---- See DEV-50768
23442
- "1_512": [{ key: DocumentType.VAT_DOCUMENT }],
23443
- "1_513": [{ key: DocumentType.VAT_DOCUMENT }],
23445
+ "1_512": [{ key: DocumentType.VAT_DOCUMENT }, { key: "organization.vatNumber" }],
23446
+ "1_513": [{ key: DocumentType.VAT_DOCUMENT }, { key: "organization.vatNumber" }],
23444
23447
  "1_600": [{ key: "soleProprietorship.name" }, { key: "soleProprietorship.registeredAddress" }],
23445
23448
  // Both trust and soleprop remediation to upload constitutional document use the same codes
23446
23449
  "1_601": [{ key: DocumentType.CONSTITUTIONAL_DOCUMENT }],
@@ -23714,6 +23717,14 @@ const setReviewRequiredError = (verificationError, entityProblems) => {
23714
23717
  };
23715
23718
  setPriorityStatus(entityProblems, TaskStatus.SUBMIT);
23716
23719
  };
23720
+ const FIELDS_WITH_LINKED_DATA = ["vatNumber"];
23721
+ const getLinkedRemedidationFormFields = (acc, field) => {
23722
+ switch (field) {
23723
+ case "vatNumber":
23724
+ acc.fields = [...acc.fields, "vatAbsenceReason", "exemptedFromVat"];
23725
+ break;
23726
+ }
23727
+ };
23717
23728
  function setInvalidInputError(parentVerificationError, entityProblems, isExperimentEnabled) {
23718
23729
  var _a, _b;
23719
23730
  const processedSubErrors = (_a = parentVerificationError == null ? void 0 : parentVerificationError.subErrors) == null ? void 0 : _a.reduce(
@@ -23729,6 +23740,9 @@ function setInvalidInputError(parentVerificationError, entityProblems, isExperim
23729
23740
  const formsAndFields = mappedCompFields == null ? void 0 : mappedCompFields.reduce(
23730
23741
  (acc3, fullFieldPath) => {
23731
23742
  const [form, field] = fullFieldPath.split(/\.(.+)/, 2);
23743
+ if (FIELDS_WITH_LINKED_DATA.includes(field)) {
23744
+ getLinkedRemedidationFormFields(acc3, field);
23745
+ }
23732
23746
  acc3.forms = [...acc3.forms, form];
23733
23747
  acc3.fields = [...acc3.fields, field];
23734
23748
  return acc3;
@@ -39331,7 +39345,7 @@ const convertToEmbeddedEvent = (eventQueueItem, sessionData) => {
39331
39345
  };
39332
39346
  };
39333
39347
  const useAnalytics = ({ onUserEvent, legalEntityId, componentName }) => {
39334
- const sdkVersion = "2.69.0";
39348
+ const sdkVersion = "2.70.1";
39335
39349
  const { isEmbeddedDropin, loadingContext: base } = useAuthContext();
39336
39350
  const loadingContext = `${base}api/${COMPONENTS_API_VERSION}/`;
39337
39351
  useEffect(() => {
@@ -39673,7 +39687,7 @@ const ConfigurationApiProvider = ({
39673
39687
  [authContext, rootLegalEntityId]
39674
39688
  );
39675
39689
  return /* @__PURE__ */ jsxs(ConfigurationApiContext.Provider, { value: contextValue, children: [
39676
- /* @__PURE__ */ jsx("span", { className: "adyen-kyc__sdk-version", hidden: true, children: "2.69.0" }),
39690
+ /* @__PURE__ */ jsx("span", { className: "adyen-kyc__sdk-version", hidden: true, children: "2.70.1" }),
39677
39691
  children
39678
39692
  ] });
39679
39693
  };
@@ -40289,7 +40303,7 @@ const DebugModal = ({ rootLegalEntityId, onExit, getRootLegalEntity }) => {
40289
40303
  };
40290
40304
  const copyToClipboard = async () => {
40291
40305
  const toCopy = {
40292
- sdkVersion: "2.69.0",
40306
+ sdkVersion: "2.70.1",
40293
40307
  experiments: Object.fromEntries(allExperimentsWithValues),
40294
40308
  settings: Object.fromEntries(allSettingsWithValues)
40295
40309
  };
@@ -40354,7 +40368,7 @@ const DebugModal = ({ rootLegalEntityId, onExit, getRootLegalEntity }) => {
40354
40368
  /* @__PURE__ */ jsx("div", { className: "adyen-kyc-debug-modal__meta", children: /* @__PURE__ */ jsx("table", { children: /* @__PURE__ */ jsxs("tbody", { children: [
40355
40369
  /* @__PURE__ */ jsx("tr", { children: /* @__PURE__ */ jsxs("td", { children: [
40356
40370
  /* @__PURE__ */ jsx("span", { className: "adyen-kyc-debug-modal__table-key", children: "SDK version" }),
40357
- /* @__PURE__ */ jsx(Tag, { variant: "green", className: "adyen-kyc-tag--large", children: "2.69.0" })
40371
+ /* @__PURE__ */ jsx(Tag, { variant: "green", className: "adyen-kyc-tag--large", children: "2.70.1" })
40358
40372
  ] }) }),
40359
40373
  /* @__PURE__ */ jsx("tr", { children: /* @__PURE__ */ jsxs("td", { children: [
40360
40374
  /* @__PURE__ */ jsx("span", { className: "adyen-kyc-debug-modal__table-key", children: "rootLegalEntityId" }),
@@ -40499,7 +40513,7 @@ class UIElement extends BaseElement {
40499
40513
  userEvents.updateBaseTrackingPayload({
40500
40514
  ...baseTracking,
40501
40515
  componentName: this.props.componentName,
40502
- sdkVersion: "2.69.0",
40516
+ sdkVersion: "2.70.1",
40503
40517
  userAgent: navigator.userAgent
40504
40518
  });
40505
40519
  return /* @__PURE__ */ jsx(SettingsProvider, { settings: this.props.settings, children: /* @__PURE__ */ jsx(
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@adyen/kyc-components",
3
- "version": "2.69.0",
3
+ "version": "2.70.1",
4
4
  "keywords": [
5
5
  "adyen",
6
6
  "adyen-kyc",