@adyen/kyc-components 2.37.0 → 2.37.2

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.
@@ -302,6 +302,7 @@ const pciDssQuestionnaire = "PCI DSS questionnaire";
302
302
  const serviceAgreementSignedSuccessfully = "Service agreement signed successfully";
303
303
  const serviceAgreementSignFailed = "Service agreement signing failed";
304
304
  const failedToGetServiceAgreementStatus = "Failed to get the service agreement status";
305
+ const failedToFetchAcceptedByName = "Failed to get the legal entity that accepted service agreement";
305
306
  const failedToGetServiceAgreement = "Failed to get the service agreement";
306
307
  const failedToGetServiceAgreementInSelectedLanguageFallbackToEn = "Failed to get the service agreement in the selected language. Falling back to English.";
307
308
  const iHaveReadAndIAcceptTheseTerms = "I have read and I accept these terms and confirm that I am a legal representative authorized to accept these terms on behalf of the company. I have taken notice of the privacy statement (www.adyen.com/policies-and-disclaimer/privacy-policy) and I consent to my (personal) data being used for the purposes described therein.";
@@ -1549,6 +1550,7 @@ const defaultTrans = {
1549
1550
  serviceAgreementSignedSuccessfully,
1550
1551
  serviceAgreementSignFailed,
1551
1552
  failedToGetServiceAgreementStatus,
1553
+ failedToFetchAcceptedByName,
1552
1554
  failedToGetServiceAgreement,
1553
1555
  failedToGetServiceAgreementInSelectedLanguageFallbackToEn,
1554
1556
  iHaveReadAndIAcceptTheseTerms,
@@ -11042,8 +11044,13 @@ function AccountHolder(props) {
11042
11044
  fieldProblems: props == null ? void 0 : props.fieldValidationErrors
11043
11045
  });
11044
11046
  useEffect(() => {
11045
- var _a2, _b;
11046
- (_b = (_a2 = stateRef.current) == null ? void 0 : _a2.setState) == null ? void 0 : _b.call(_a2, {
11047
+ var _a2, _b, _c;
11048
+ (_a2 = props.onChange) == null ? void 0 : _a2.call(props, {
11049
+ data,
11050
+ valid,
11051
+ errors
11052
+ });
11053
+ (_c = (_b = stateRef.current) == null ? void 0 : _b.setState) == null ? void 0 : _c.call(_b, {
11047
11054
  type: "addToState",
11048
11055
  value: {
11049
11056
  data,
@@ -25879,8 +25886,9 @@ const CompanyStructureValidation = {
25879
25886
  }
25880
25887
  };
25881
25888
  const COMPANY_STRUCTURE_FORM_ID = "companyStructure";
25882
- const companyStructureFields = ["entityType"];
25889
+ const companyStructureFields = ["entityType", "accountHolder"];
25883
25890
  function CompanyStructureComponent({
25891
+ id: id2,
25884
25892
  data,
25885
25893
  labels: labels2,
25886
25894
  heading,
@@ -25888,7 +25896,9 @@ function CompanyStructureComponent({
25888
25896
  formVerificationErrors,
25889
25897
  fieldValidationErrors,
25890
25898
  requiredFields,
25891
- kompanyVerifiedData
25899
+ country: country2,
25900
+ kompanyVerifiedData,
25901
+ ...props
25892
25902
  }) {
25893
25903
  var _a;
25894
25904
  const {
@@ -25938,6 +25948,19 @@ function CompanyStructureComponent({
25938
25948
  });
25939
25949
  }, [formSchema, formData, formErrors, formValid, formFieldProblems, updateStateSlice]);
25940
25950
  const companyTypeOptions = isNewEntryFlowEnabled ? companyTypes.filter((companyType2) => companyType2.id !== CompanyTypesValue.INCORPORATED_PARTNERSHIP && companyType2.id !== CompanyTypesValue.INCORPORATED_ASSOCIATION) : companyTypes;
25951
+ const companyTypeExamples2 = useCompanyTypeExamples(country2);
25952
+ const accountHolderProps = getFieldProps({
25953
+ id: id2,
25954
+ data,
25955
+ labels: labels2,
25956
+ heading,
25957
+ description: description2,
25958
+ formVerificationErrors,
25959
+ fieldValidationErrors,
25960
+ requiredFields,
25961
+ country: country2,
25962
+ ...props
25963
+ }, accountHolderFields);
25941
25964
  return jsxs("form", {
25942
25965
  children: [jsx(FormHeader, {
25943
25966
  heading,
@@ -25952,18 +25975,24 @@ function CompanyStructureComponent({
25952
25975
  useLabelElement: false,
25953
25976
  errorMessage: formUtils.getErrorMessage("entityType", formErrors, formFieldProblems),
25954
25977
  classNameModifiers: ["entityType"],
25955
- children: (childProps) => jsx(RadioGroupCard, {
25978
+ children: (childProps) => jsx(EntityTypeRadioGroupCard, {
25956
25979
  ...childProps,
25957
25980
  "aria-required": true,
25958
25981
  "aria-label": formUtils.getLabel("entityType", "whatTypeOfCompanyDoYouHave"),
25959
25982
  "aria-invalid": !formValid.entityType,
25960
25983
  name: "entityType",
25961
25984
  items: companyTypeOptions,
25962
- selected: companyTypeOptions.find((type) => type.id === (formData == null ? void 0 : formData.entityType)),
25985
+ selected: companyTypeOptions.find((type) => type.id === formData.entityType),
25963
25986
  readonly: disabled,
25964
- isItemDisabled: () => disabled,
25965
- onSelect: (item) => handleChangeFor("entityType")(item.id)
25987
+ onSelect: (item) => handleChangeFor("entityType")(item.id),
25988
+ examples: companyTypeExamples2
25966
25989
  })
25990
+ }), !isNewEntryFlowEnabled && country2 && jsx(AccountHolder, {
25991
+ ...accountHolderProps,
25992
+ dataStoreId: id2,
25993
+ legalEntityType: LegalEntityType.ORGANIZATION,
25994
+ country: country2,
25995
+ onChange: (value) => handleChangeFor("accountHolder")(value.data.accountHolder)
25967
25996
  })]
25968
25997
  });
25969
25998
  }
@@ -26231,7 +26260,7 @@ const mapApiDocumentToCompanySearchDocuments = (entityId) => {
26231
26260
  } : void 0
26232
26261
  };
26233
26262
  };
26234
- const mapLegalEntityToCompanySearchSchema = (legalEntity) => {
26263
+ const mapLegalEntityToCompanySearchSchema = (legalEntity, isChangingType) => {
26235
26264
  const companySearchSchema = {
26236
26265
  companyBasics: {},
26237
26266
  companyRegistrationAddress: {},
@@ -26276,7 +26305,10 @@ const mapLegalEntityToCompanySearchSchema = (legalEntity) => {
26276
26305
  case "companyStructure": {
26277
26306
  return {
26278
26307
  ...componentData,
26279
- [key]: value
26308
+ [key]: {
26309
+ ...value,
26310
+ accountHolder: getDefaultAccountHolderType(legalEntity, isChangingType)
26311
+ }
26280
26312
  };
26281
26313
  }
26282
26314
  case "companyRegistrationDocument": {
@@ -26307,6 +26339,7 @@ function useCompanySearchTaskSubmit({
26307
26339
  legalEntityResponse,
26308
26340
  problems,
26309
26341
  baseTrackingPayload,
26342
+ isTargetLegalEntityType,
26310
26343
  documentUtils,
26311
26344
  setProblems,
26312
26345
  setLoadingStatus,
@@ -26368,7 +26401,7 @@ function useCompanySearchTaskSubmit({
26368
26401
  legalEntityName: ((_c = data.companyBasics) == null ? void 0 : _c.legalCompanyName) ?? null,
26369
26402
  usedAdditionalAddress: ((_d = data.companyRegistrationAddress) == null ? void 0 : _d.operationalAddressIsSame) === operationalAddressIsSameIds.OPERATIONAL_ADDRESS_IS_NOT_SAME
26370
26403
  };
26371
- const savedLegalEntityData = mapLegalEntityToCompanySearchSchema(legalEntityResponse);
26404
+ const savedLegalEntityData = mapLegalEntityToCompanySearchSchema(legalEntityResponse, isTargetLegalEntityType);
26372
26405
  const filteredData = removeOldDataBySchema(data, savedLegalEntityData);
26373
26406
  const legalEntity = {
26374
26407
  ...mapCompanySearchSchemaToLegalEntity(filteredData),
@@ -26441,7 +26474,7 @@ function useCompanySearchTaskSubmit({
26441
26474
  };
26442
26475
  }
26443
26476
  function CompanySearchComponent(props) {
26444
- var _a, _b, _c, _d, _e;
26477
+ var _a, _b, _c, _d, _e, _f;
26445
26478
  const {
26446
26479
  i18n
26447
26480
  } = useI18nContext();
@@ -26457,12 +26490,14 @@ function CompanySearchComponent(props) {
26457
26490
  handleCompanyDeepSearch,
26458
26491
  handleGetCompanyDataset,
26459
26492
  handleRefreshCompanyDataset,
26460
- handleVerifyTin
26493
+ handleVerifyTin,
26494
+ onTypeSwitch
26461
26495
  } = props;
26462
26496
  const globalData = useGlobalData();
26463
26497
  const [kompanyAddress, setKompanyAddress] = useState();
26464
26498
  const [kompanyVerifiedData, setKompanyVerifiedData] = useState();
26465
26499
  const formWrapperClasses = (formId) => (activeForm == null ? void 0 : activeForm.formId) !== formId ? "adyen-kyc-form-wrapper adyen-kyc-form-wrapper--hidden" : "adyen-kyc-form-wrapper";
26500
+ this.customNavigationHandler = ((_a = globalData.companyStructure) == null ? void 0 : _a.accountHolder) === "myName" ? () => onTypeSwitch == null ? void 0 : onTypeSwitch(LegalEntityType.INDIVIDUAL) : null;
26466
26501
  return jsxs("div", {
26467
26502
  className: "adyen-kyc-company",
26468
26503
  children: [jsx("div", {
@@ -26472,7 +26507,7 @@ function CompanySearchComponent(props) {
26472
26507
  id: forms.companyBasics.formId,
26473
26508
  heading: i18n.get(forms.companyBasics.formName),
26474
26509
  country: country2,
26475
- companyType: (_a = globalData == null ? void 0 : globalData.companyStructure) == null ? void 0 : _a.entityType,
26510
+ companyType: (_b = globalData == null ? void 0 : globalData.companyStructure) == null ? void 0 : _b.entityType,
26476
26511
  isTopLevelEntity,
26477
26512
  baseTrackingPayload,
26478
26513
  handleCompanyIndexSearch,
@@ -26506,6 +26541,7 @@ function CompanySearchComponent(props) {
26506
26541
  id: forms.companyStructure.formId,
26507
26542
  heading: i18n.get(forms.companyStructure.formName),
26508
26543
  description: i18n.get(forms.companyStructure.formDescription),
26544
+ country: country2,
26509
26545
  kompanyVerifiedData
26510
26546
  })
26511
26547
  }), jsx("div", {
@@ -26515,8 +26551,8 @@ function CompanySearchComponent(props) {
26515
26551
  id: forms.companyOtherDetails.formId,
26516
26552
  heading: i18n.get(forms.companyOtherDetails.formName),
26517
26553
  country: country2,
26518
- legalCompanyName: (_b = globalData == null ? void 0 : globalData.companyBasics) == null ? void 0 : _b.legalCompanyName,
26519
- companyType: (_c = globalData == null ? void 0 : globalData.companyStructure) == null ? void 0 : _c.entityType,
26554
+ legalCompanyName: (_c = globalData == null ? void 0 : globalData.companyBasics) == null ? void 0 : _c.legalCompanyName,
26555
+ companyType: (_d = globalData == null ? void 0 : globalData.companyStructure) == null ? void 0 : _d.entityType,
26520
26556
  kompanyVerifiedData
26521
26557
  })
26522
26558
  }), jsx("div", {
@@ -26527,7 +26563,7 @@ function CompanySearchComponent(props) {
26527
26563
  heading: forms.companyRegistrationDocument.formHeading,
26528
26564
  description: forms.companyRegistrationDocument.formDescription,
26529
26565
  country: country2,
26530
- companyType: (_d = globalData.companyStructure) == null ? void 0 : _d.entityType
26566
+ companyType: (_e = globalData.companyStructure) == null ? void 0 : _e.entityType
26531
26567
  })
26532
26568
  }), jsx("div", {
26533
26569
  className: formWrapperClasses(forms.companyTaxDocument.formId),
@@ -26537,7 +26573,7 @@ function CompanySearchComponent(props) {
26537
26573
  heading: forms.companyTaxDocument.formHeading,
26538
26574
  description: forms.companyTaxDocument.formDescription,
26539
26575
  country: country2,
26540
- companyType: (_e = globalData.companyStructure) == null ? void 0 : _e.entityType
26576
+ companyType: (_f = globalData.companyStructure) == null ? void 0 : _f.entityType
26541
26577
  }) : jsx(DocumentUpload, {
26542
26578
  ...getFormProps(props, forms.companyTaxDocument.formId),
26543
26579
  id: forms.companyTaxDocument.formId,
@@ -26569,6 +26605,7 @@ function CompanySearchDropinComponent({
26569
26605
  country: parentCountry,
26570
26606
  problems: propProblems,
26571
26607
  legalEntityResponse,
26608
+ isTargetLegalEntityType,
26572
26609
  parentLegalEntity,
26573
26610
  trackingConfig,
26574
26611
  eventEmitter,
@@ -26590,7 +26627,8 @@ function CompanySearchDropinComponent({
26590
26627
  handleCompanyDeepSearch,
26591
26628
  handleGetCompanyDataset,
26592
26629
  handleRefreshCompanyDataset,
26593
- handleVerifyTin
26630
+ handleVerifyTin,
26631
+ onTypeSwitch
26594
26632
  }) {
26595
26633
  var _a, _b, _c, _d;
26596
26634
  const {
@@ -26616,7 +26654,7 @@ function CompanySearchDropinComponent({
26616
26654
  isExperimentEnabled
26617
26655
  } = useExperimentsContext();
26618
26656
  const [loadingStatus, setLoadingStatus] = useState("success");
26619
- const [initialData, setInitialData] = useState(mapLegalEntityToCompanySearchSchema(legalEntityResponse));
26657
+ const [initialData, setInitialData] = useState(mapLegalEntityToCompanySearchSchema(legalEntityResponse, Boolean(isTargetLegalEntityType)));
26620
26658
  const country2 = useMemo(() => {
26621
26659
  var _a2;
26622
26660
  return ((_a2 = currentState.data.companyBasics) == null ? void 0 : _a2.country) ?? parentCountry;
@@ -26702,6 +26740,7 @@ function CompanySearchDropinComponent({
26702
26740
  legalEntityResponse,
26703
26741
  problems,
26704
26742
  baseTrackingPayload,
26743
+ isTargetLegalEntityType: Boolean(isTargetLegalEntityType),
26705
26744
  documentUtils,
26706
26745
  setProblems,
26707
26746
  setLoadingStatus,
@@ -26760,6 +26799,7 @@ function CompanySearchDropinComponent({
26760
26799
  activeForm,
26761
26800
  shouldValidate,
26762
26801
  isTopLevelEntity: taskType === TaskTypes.COMPANY_SEARCH,
26802
+ onTypeSwitch,
26763
26803
  baseTrackingPayload,
26764
26804
  handleAddressSearch,
26765
26805
  handleFindAddress,
@@ -32504,11 +32544,19 @@ function DropinComposerComponent({
32504
32544
  getPciTemplate().catch(logger$8.error);
32505
32545
  }, [getPciTemplate, tasks]);
32506
32546
  const addFetchedAcceptedByName = async (acceptanceInfo) => {
32507
- const acceptedByEntity = await (args == null ? void 0 : args.handleGetLegalEntity(acceptanceInfo.acceptedBy));
32508
- return {
32509
- ...acceptanceInfo,
32510
- acceptedByName: getLegalEntityNameBasedOnType(acceptedByEntity)
32511
- };
32547
+ try {
32548
+ const acceptedByEntity = await (args == null ? void 0 : args.handleGetLegalEntity(acceptanceInfo.acceptedBy));
32549
+ return {
32550
+ ...acceptanceInfo,
32551
+ acceptedByName: getLegalEntityNameBasedOnType(acceptedByEntity)
32552
+ };
32553
+ } catch (e) {
32554
+ logger$8.warn(i18n.get("failedToFetchAcceptedByName"));
32555
+ return {
32556
+ ...acceptanceInfo,
32557
+ acceptedByName: null
32558
+ };
32559
+ }
32512
32560
  };
32513
32561
  const getServiceAgreementAcceptanceInfos = async () => {
32514
32562
  if (rootLegalEntity.id && (args == null ? void 0 : args.handleGetServiceAgreementAcceptanceInfos)) {
@@ -33190,7 +33238,9 @@ function DropinComposerComponent({
33190
33238
  handleCompanyDeepSearch: args.handleCompanyDeepSearch,
33191
33239
  handleGetCompanyDataset: args.handleGetCompanyDataset,
33192
33240
  handleRefreshCompanyDataset: args.handleRefreshCompanyDataset,
33193
- handleVerifyTin: args.handleVerifyTin
33241
+ handleVerifyTin: args.handleVerifyTin,
33242
+ onTypeSwitch: navigateToTypeSwitcher,
33243
+ isTargetLegalEntityType: legalEntityType === LegalEntityType.ORGANIZATION
33194
33244
  });
33195
33245
  case TaskTypes.TRUST_MEMBER_COMPANY:
33196
33246
  return jsx(CompanyDropinComponent, {
@@ -34514,7 +34564,7 @@ const ConfigurationApiProvider = ({
34514
34564
  isEmbeddedDropin,
34515
34565
  loadingContext
34516
34566
  } = authContext;
34517
- const sdkVersion = "2.37.0";
34567
+ const sdkVersion = "2.37.2";
34518
34568
  useAnalytics({
34519
34569
  onUserEvent,
34520
34570
  legalEntityId: rootLegalEntityId,
package/dist/style.css CHANGED
@@ -80066,6 +80066,8 @@ a.adl-button:disabled, a.adl-button.adl-button--disabled {
80066
80066
  padding-bottom: 4px;
80067
80067
  }
80068
80068
  .adyen-company-lookup-results-list__result-option {
80069
+ display: flex;
80070
+ justify-content: space-between;
80069
80071
  background-color: #fff;
80070
80072
  box-shadow: 0 1px 1px rgba(0, 17, 44, 0.12), 0 1px 3px rgba(0, 17, 44, 0.14);
80071
80073
  border: 1px solid #fff;
@@ -15,7 +15,7 @@ export declare const forms: {
15
15
  readonly formId: keyof CompanySearchSchema;
16
16
  readonly formName: "companyStructureFormName";
17
17
  readonly formDescription: "companyStructureFormDescription";
18
- readonly fields: "entityType"[];
18
+ readonly fields: (keyof import("../CompanyStructure/types").CompanyStructureSchema)[];
19
19
  };
20
20
  readonly companyOtherDetails: {
21
21
  readonly formId: keyof CompanySearchSchema;
@@ -1,4 +1,5 @@
1
1
  import type { BaseOuterFormProps } from '../../core/hooks/useForm';
2
+ import type { LegalEntityType } from '../../core/models/api/legal-entity-type';
2
3
  import type { CountryCode } from '../../core/models/country-code';
3
4
  import type { FormModel } from '../../core/models/form';
4
5
  import type { BaseTrackingPayload } from '../../core/utils';
@@ -29,4 +30,5 @@ export interface CompanySearchProps extends BaseOuterFormProps<CompanySearchSche
29
30
  handleRefreshCompanyDataset: DropinAPIHandlers['handleRefreshCompanyDataset'];
30
31
  handleVerifyTin: DropinAPIHandlers['handleVerifyTin'];
31
32
  onSubmit?: (company: CompanySearchSchema) => void;
33
+ onTypeSwitch?: (legalEntityType: LegalEntityType) => void;
32
34
  }
@@ -3,4 +3,4 @@ import { CompanySearchSchema } from '../../CompanySearch/types';
3
3
  import { CompanyStructureProps, CompanyStructureSchema } from '../types';
4
4
  export declare const COMPANY_STRUCTURE_FORM_ID: keyof CompanySearchSchema;
5
5
  export declare const companyStructureFields: Array<keyof CompanyStructureSchema>;
6
- export declare function CompanyStructureComponent({ data, labels, heading, description, formVerificationErrors, fieldValidationErrors, requiredFields, kompanyVerifiedData, }: CompanyStructureProps): import("preact").JSX.Element;
6
+ export declare function CompanyStructureComponent({ id, data, labels, heading, description, formVerificationErrors, fieldValidationErrors, requiredFields, country, kompanyVerifiedData, ...props }: CompanyStructureProps): import("preact").JSX.Element;
@@ -1,9 +1,12 @@
1
1
  import type { BaseInnerFormProps } from '../../core/hooks/useForm';
2
2
  import type { CompanyTypesValue } from '../../core/models/api/company-types-value';
3
+ import type { CountryCode } from '../../core/models/country-code';
3
4
  import type { CompanySearchSchema } from '../CompanySearch/types';
4
- export interface CompanyStructureSchema {
5
+ import type { AccountHolderSchema } from '../internal/AccountHolder/types';
6
+ export interface CompanyStructureSchema extends AccountHolderSchema {
5
7
  entityType?: CompanyTypesValue;
6
8
  }
7
9
  export interface CompanyStructureProps extends BaseInnerFormProps<CompanyStructureSchema> {
10
+ country: CountryCode;
8
11
  kompanyVerifiedData?: CompanySearchSchema;
9
12
  }
@@ -1,2 +1,2 @@
1
1
  import { CompanySearchDropinProps } from '../types';
2
- export declare function CompanySearchDropinComponent({ country: parentCountry, problems: propProblems, legalEntityResponse, parentLegalEntity, trackingConfig, eventEmitter, taskType, capabilities, taskName, hideDropinLayout, homeButtonLabel, onChange, onSubmit: onExternalSubmit, handleHomeClick, handleCreateDocument, handleGetDocument, handleUpdateDocument, handleAddressSearch, handleFindAddress, handleUpdateLegalEntity, handleCompanyIndexSearch, handleCompanyDeepSearch, handleGetCompanyDataset, handleRefreshCompanyDataset, handleVerifyTin, }: CompanySearchDropinProps): import("preact").JSX.Element;
2
+ export declare function CompanySearchDropinComponent({ country: parentCountry, problems: propProblems, legalEntityResponse, isTargetLegalEntityType, parentLegalEntity, trackingConfig, eventEmitter, taskType, capabilities, taskName, hideDropinLayout, homeButtonLabel, onChange, onSubmit: onExternalSubmit, handleHomeClick, handleCreateDocument, handleGetDocument, handleUpdateDocument, handleAddressSearch, handleFindAddress, handleUpdateLegalEntity, handleCompanyIndexSearch, handleCompanyDeepSearch, handleGetCompanyDataset, handleRefreshCompanyDataset, handleVerifyTin, onTypeSwitch, }: CompanySearchDropinProps): import("preact").JSX.Element;
@@ -18,6 +18,7 @@ export declare enum CompanySearchEvents {
18
18
  export type CompanySearchDropinApihandler = Required<Pick<DropinAPIHandlers, 'handleCreateDocument' | 'handleGetDocument' | 'handleUpdateDocument' | 'handleUpdateLegalEntity'>>;
19
19
  export interface CompanySearchDropinProps extends Omit<CompanySearchProps, 'isTopLevelEntity' | 'baseTrackingPayload'>, CompanySearchDropinApihandler, DropinProps {
20
20
  legalEntityResponse: ExistingLegalEntity;
21
+ isTargetLegalEntityType?: boolean;
21
22
  parentLegalEntity?: LegalEntity;
22
23
  associationDetail?: TrustMember;
23
24
  }
@@ -11,7 +11,7 @@ export interface ServiceAgreementAcceptanceInfo {
11
11
  type: ServiceAgreementType;
12
12
  }
13
13
  export interface ServiceAgreementAcceptanceInfoWithName extends ServiceAgreementAcceptanceInfo {
14
- acceptedByName: string;
14
+ acceptedByName?: string;
15
15
  }
16
16
  export interface ServiceAgreementSchema {
17
17
  signer?: string;
@@ -21,6 +21,7 @@ export interface FormTaskSubmitOptions {
21
21
  legalEntityResponse: ExistingLegalEntity;
22
22
  problems?: EntityProblems;
23
23
  baseTrackingPayload: BaseTrackingPayload;
24
+ isTargetLegalEntityType: boolean;
24
25
  documentUtils: DocumentApiUtils;
25
26
  setProblems: StateUpdater<EntityProblems | undefined>;
26
27
  setLoadingStatus: StateUpdater<LoadingStatus>;
@@ -30,4 +31,4 @@ export interface FormTaskSubmitOptions {
30
31
  export type FormTaskSubmit<FormTaskSchema> = {
31
32
  submit: (options: SubmitOptions<FormTaskSchema>) => Promise<void>;
32
33
  };
33
- export declare function useCompanySearchTaskSubmit<FormTaskSchema extends CompanySearchSchema>({ task, forms, legalEntityResponse, problems, baseTrackingPayload, documentUtils, setProblems, setLoadingStatus, onExternalSubmit, handleUpdateLegalEntity, }: FormTaskSubmitOptions): FormTaskSubmit<FormTaskSchema>;
34
+ export declare function useCompanySearchTaskSubmit<FormTaskSchema extends CompanySearchSchema>({ task, forms, legalEntityResponse, problems, baseTrackingPayload, isTargetLegalEntityType, documentUtils, setProblems, setLoadingStatus, onExternalSubmit, handleUpdateLegalEntity, }: FormTaskSubmitOptions): FormTaskSubmit<FormTaskSchema>;
@@ -1,4 +1,4 @@
1
1
  import { CompanySearchSchema } from '../../../components/CompanySearch/types';
2
2
  import { ExistingLegalEntity } from '../../../core/models/api/legal-entity';
3
3
  export declare const mapApiDocumentToCompanySearchDocuments: (entityId: string) => CompanySearchSchema;
4
- export declare const mapLegalEntityToCompanySearchSchema: (legalEntity: ExistingLegalEntity) => CompanySearchSchema;
4
+ export declare const mapLegalEntityToCompanySearchSchema: (legalEntity: ExistingLegalEntity, isChangingType: boolean) => CompanySearchSchema;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@adyen/kyc-components",
3
- "version": "2.37.0",
3
+ "version": "2.37.2",
4
4
  "description": "",
5
5
  "license": "MIT",
6
6
  "files": [