@adyen/kyc-components 2.7.1 → 2.8.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.
- package/dist/es/adyen-kyc-components.es.js +25794 -25029
- package/dist/style.css +122464 -14819
- package/dist/types/components/BankVerification/types.d.ts +5 -0
- package/dist/types/components/BankVerification/verification/widget/component/BankVerificationWidget.d.ts +4 -1
- package/dist/types/components/Company/component/CompanyComponent.d.ts +1 -1
- package/dist/types/components/Company/types.d.ts +13 -14
- package/dist/types/components/CompanyDetails/types.d.ts +1 -0
- package/dist/types/components/DecisionMakers/types.d.ts +0 -1
- package/dist/types/components/Dropins/CompanyDropin/components/CompanyDropinComponent.d.ts +1 -1
- package/dist/types/components/Dropins/FormComposer/components/StepProgressIndicator/StepProgressIndicator.d.ts +7 -0
- package/dist/types/components/Dropins/PayoutDetailsDropin/components/PayoutDetailsDropinComponent.d.ts +1 -1
- package/dist/types/components/Dropins/PciDropin/components/PciDropinComponent.d.ts +1 -1
- package/dist/types/components/Dropins/PciDropin/types.d.ts +2 -2
- package/dist/types/components/Dropins/ServiceAgreementDropinComponent/components/ServiceAgreementDropinComponent.d.ts +1 -1
- package/dist/types/components/Dropins/ServiceAgreementDropinComponent/types.d.ts +1 -1
- package/dist/types/components/Dropins/SolePropDropin/components/SolePropDropinComponent.d.ts +1 -1
- package/dist/types/components/Dropins/types.d.ts +8 -9
- package/dist/types/components/EmbeddedDropins/PayoutEmbeddedDropin/PayoutEmbeddedDropin.d.ts +2 -1
- package/dist/types/components/Individual/types.d.ts +2 -2
- package/dist/types/components/PayoutDetails/types.d.ts +5 -2
- package/dist/types/components/RegistrationAddress/component/RegistrationAddressComponent.d.ts +2 -3
- package/dist/types/components/RegistrationAddress/index.d.ts +1 -0
- package/dist/types/components/SoleProp/types.d.ts +0 -1
- package/dist/types/components/TaskIntros/TaskIntro.d.ts +8 -0
- package/dist/types/components/TaskIntros/TaskIntros.d.ts +10 -0
- package/dist/types/components/TaskIntros/copy.d.ts +14 -0
- package/dist/types/components/TaskIntros/types.d.ts +8 -0
- package/dist/types/components/TaskList/types.d.ts +4 -3
- package/dist/types/components/UIElement.d.ts +2 -1
- package/dist/types/components/UenOrGst/types.d.ts +9 -0
- package/dist/types/components/internal/Address/utils.d.ts +1 -1
- package/dist/types/components/internal/Button/Button.d.ts +1 -1
- package/dist/types/components/internal/Icon/Icon.d.ts +1 -1
- package/dist/types/core/Context/ConfigurationApiContext/ConfigurationApiContext.d.ts +6 -0
- package/dist/types/core/Context/ConfigurationApiContext/ConfigurationApiProvider.d.ts +1 -1
- package/dist/types/core/Context/CoreContext.d.ts +0 -4
- package/dist/types/core/Context/CoreProvider.d.ts +1 -4
- package/dist/types/core/Context/I18nProvider/I18nContext.d.ts +7 -0
- package/dist/types/core/Context/I18nProvider/I18nProvider.d.ts +8 -0
- package/dist/types/core/Context/SettingsContext/types.d.ts +12 -1
- package/dist/types/core/Context/StateContext/types.d.ts +24 -11
- package/dist/types/core/Services/agnostic/get-fonts.d.ts +2 -2
- package/dist/types/core/Services/componentApi/create-trusted-transferInstrument.d.ts +3 -0
- package/dist/types/core/Services/componentApi/handle-bank-verification-error.d.ts +3 -0
- package/dist/types/core/Services/http.d.ts +1 -1
- package/dist/types/core/Services/kycExternalApi/company-deep-search.d.ts +5 -0
- package/dist/types/core/Services/kycExternalApi/company-index-search.d.ts +5 -0
- package/dist/types/core/Services/kycExternalApi/get-company-data.d.ts +5 -0
- package/dist/types/core/Services/kycExternalApi/index.d.ts +5 -0
- package/dist/types/core/Services/kycExternalApi/refresh-company-data.d.ts +5 -0
- package/dist/types/core/Services/kycExternalApi/verify-tin.d.ts +5 -0
- package/dist/types/core/Services/types.d.ts +1 -1
- package/dist/types/core/hooks/useAllowedLocales.d.ts +1 -0
- package/dist/types/core/hooks/useBankConfigurationHandlers.d.ts +24 -0
- package/dist/types/core/hooks/useComponentApi.d.ts +3 -0
- package/dist/types/core/hooks/useLocalStorage.d.ts +11 -0
- package/dist/types/core/hooks/useSalesChannelsSettings.d.ts +1 -0
- package/dist/types/core/hooks/useShouldShowGuidanceIntros.d.ts +7 -0
- package/dist/types/core/hooks/useTranslations.d.ts +10 -0
- package/dist/types/core/models/api/company-search.d.ts +80 -0
- package/dist/types/core/models/api/contracts.d.ts +5 -1
- package/dist/types/core/models/api/legal-arrangement.d.ts +2 -1
- package/dist/types/core/models/api/organization.d.ts +4 -2
- package/dist/types/core/models/api/trusted-transferInstrument.d.ts +8 -0
- package/dist/types/core/models/currency.d.ts +1 -0
- package/dist/types/core/models/errors/capability-problems.d.ts +2 -2
- package/dist/types/core/models/errors/entity-problems.d.ts +1 -1
- package/dist/types/core/models/state-code.d.ts +54 -0
- package/dist/types/language/Language.d.ts +11 -29
- package/dist/types/language/config.d.ts +37 -0
- package/dist/types/language/types.d.ts +2 -2
- package/dist/types/language/utils.d.ts +9 -22
- package/dist/types/openbankingsdk/OpenBankingSDK.d.ts +14 -0
- package/dist/types/openbankingsdk/types.d.ts +22 -0
- package/dist/types/utils/company-util.d.ts +2 -1
- package/dist/types/utils/decision-maker-roles.d.ts +1 -1
- package/dist/types/utils/entity-status-util.d.ts +2 -2
- package/dist/types/utils/mapping/componentApiMapping.d.ts +18 -17
- package/dist/types/utils/toCapitalized.d.ts +1 -0
- package/dist/types/utils/toPascalCase.d.ts +1 -0
- package/dist/types/utils/trust-util.d.ts +1 -1
- package/package.json +33 -32
|
@@ -2,6 +2,7 @@ import { StateUpdater } from 'preact/hooks';
|
|
|
2
2
|
import { BaseInnerFormProps } from '../../core/hooks/useForm';
|
|
3
3
|
import { BankVerificationVendorsResponse } from '../../core/models/api/get-bankVerification-providers';
|
|
4
4
|
import { LegalEntity } from '../../core/models/api/legal-entity';
|
|
5
|
+
import { BankVerificationErrorResponse, CreateTrustedTransferInstrumentResponse } from '../../core/models/api/trusted-transferInstrument';
|
|
5
6
|
import { CountryCode } from '../../core/models/country-code';
|
|
6
7
|
import { Currency } from '../../core/models/currency';
|
|
7
8
|
export interface AccountVerificationResponse {
|
|
@@ -29,6 +30,8 @@ export interface PayoutAccountVerificationProps extends BaseInnerFormProps<Accou
|
|
|
29
30
|
hideOnHomeButton: StateUpdater<boolean>;
|
|
30
31
|
formIsActive: boolean;
|
|
31
32
|
refreshLegalEntity?(): Promise<LegalEntity>;
|
|
33
|
+
createTrustedTransferInstrument: (code: string, state: string) => Promise<CreateTrustedTransferInstrumentResponse>;
|
|
34
|
+
handleBankVerificationError: (errorCode: string, errorMessage: string, state: string, metadata?: Map<string, string>) => Promise<BankVerificationErrorResponse>;
|
|
32
35
|
}
|
|
33
36
|
export interface InstantBankVerificationProps {
|
|
34
37
|
getBankVerificationVendors: (country: CountryCode) => Promise<BankVerificationVendorsResponse>;
|
|
@@ -36,6 +39,8 @@ export interface InstantBankVerificationProps {
|
|
|
36
39
|
setBankVerificationError: (error: InstantVerificationErrorNotification) => void;
|
|
37
40
|
country: string;
|
|
38
41
|
onBack?(): void;
|
|
42
|
+
createTrustedTransferInstrument: (code: string, state: string) => Promise<CreateTrustedTransferInstrumentResponse>;
|
|
43
|
+
handleBankVerificationError: (errorCode: string, errorMessage: string, state: string, metadata?: Map<string, string>) => Promise<BankVerificationErrorResponse>;
|
|
39
44
|
}
|
|
40
45
|
export type CountryBankVerificationVendors = Partial<Record<CountryCode, string>>;
|
|
41
46
|
export interface BankVerificationVendor {
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import './BankVerificationWidget.scss';
|
|
2
|
+
import { BankVerificationErrorResponse, CreateTrustedTransferInstrumentResponse } from '../../../../../core/models/api/trusted-transferInstrument';
|
|
2
3
|
import { AccountVerificationResponse } from '../../../types';
|
|
3
4
|
import { AccountVerificationCallbackErrorObject } from '../iframeWidget';
|
|
4
5
|
type SuccessPayload = {
|
|
@@ -19,6 +20,8 @@ export type BankVerificationWidgetProps = {
|
|
|
19
20
|
url: string;
|
|
20
21
|
vendor: string;
|
|
21
22
|
widgetCallback: VerificationWidgetCallback;
|
|
23
|
+
createTrustedTransferInstrument: (code: string, state: string) => Promise<CreateTrustedTransferInstrumentResponse>;
|
|
24
|
+
handleBankVerificationError: (errorCode: string, errorMessage: string, state: string, metadata?: Map<string, string>) => Promise<BankVerificationErrorResponse>;
|
|
22
25
|
};
|
|
23
|
-
export declare function BankVerificationWidget({ url, vendor, widgetCallback, }: BankVerificationWidgetProps): import("preact").JSX.Element;
|
|
26
|
+
export declare function BankVerificationWidget({ url, vendor, widgetCallback, createTrustedTransferInstrument, handleBankVerificationError, }: BankVerificationWidgetProps): import("preact").JSX.Element;
|
|
24
27
|
export default BankVerificationWidget;
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
import { BaseOuterFormProps } from '../../core/hooks/useForm';
|
|
2
|
-
import { LegalEntity } from '../../core/models/api/legal-entity';
|
|
3
|
-
import { LegalEntityType } from '../../core/models/api/legal-entity-type';
|
|
4
|
-
import { CountryCode } from '../../core/models/country-code';
|
|
5
|
-
import { FormModel } from '../../core/models/form';
|
|
6
|
-
import { CompanyDetailsSchema } from '../CompanyDetails/types';
|
|
7
|
-
import { CompanyNameAndCountrySchema } from '../CompanyNameAndCountry/types';
|
|
8
|
-
import { CompanyTypeSchema } from '../CompanyType/types';
|
|
9
|
-
import { DocumentUploadSchema } from '../DocumentUpload/types';
|
|
10
|
-
import { DropinAPIHandlers, DropinProps } from '../Dropins/types';
|
|
11
|
-
import { RegistrationAddressSchema
|
|
12
|
-
import { TrustMember } from '../TrustMembers/types';
|
|
1
|
+
import type { BaseOuterFormProps } from '../../core/hooks/useForm';
|
|
2
|
+
import type { LegalEntity } from '../../core/models/api/legal-entity';
|
|
3
|
+
import type { LegalEntityType } from '../../core/models/api/legal-entity-type';
|
|
4
|
+
import type { CountryCode } from '../../core/models/country-code';
|
|
5
|
+
import type { FormModel } from '../../core/models/form';
|
|
6
|
+
import type { CompanyDetailsSchema } from '../CompanyDetails/types';
|
|
7
|
+
import type { CompanyNameAndCountrySchema } from '../CompanyNameAndCountry/types';
|
|
8
|
+
import type { CompanyTypeSchema } from '../CompanyType/types';
|
|
9
|
+
import type { DocumentUploadSchema } from '../DocumentUpload/types';
|
|
10
|
+
import type { DropinAPIHandlers, DropinProps } from '../Dropins/types';
|
|
11
|
+
import type { RegistrationAddressSchema } from '../RegistrationAddress/types';
|
|
12
|
+
import type { TrustMember } from '../TrustMembers/types';
|
|
13
13
|
export interface CompanySchema {
|
|
14
14
|
companyDetails?: CompanyDetailsSchema;
|
|
15
15
|
companyType?: CompanyTypeSchema;
|
|
16
|
-
|
|
16
|
+
companyRegistrationAddress?: RegistrationAddressSchema;
|
|
17
17
|
companyNameAndCountry?: CompanyNameAndCountrySchema;
|
|
18
18
|
companyRegistrationDocument?: DocumentUploadSchema;
|
|
19
19
|
companyTaxDocument?: DocumentUploadSchema;
|
|
@@ -30,7 +30,6 @@ export interface CompanyProps extends BaseOuterFormProps<CompanySchema> {
|
|
|
30
30
|
handleFindAddress?: DropinAPIHandlers['handleFindAddress'];
|
|
31
31
|
}
|
|
32
32
|
export interface CompanyDropinProps extends CompanyProps, DropinAPIHandlers, DropinProps {
|
|
33
|
-
legalEntity?: LegalEntity;
|
|
34
33
|
parentLegalEntity?: LegalEntity;
|
|
35
34
|
associationDetail?: TrustMember;
|
|
36
35
|
isTargetLegalEntityType?: boolean;
|
|
@@ -10,6 +10,7 @@ export interface CompanyDetailsSchema extends BusinessRegistrationNumberSchema,
|
|
|
10
10
|
stockExchangeMIC?: string;
|
|
11
11
|
stockISIN?: string;
|
|
12
12
|
dateOfIncorporation?: string;
|
|
13
|
+
uenOrGst?: string;
|
|
13
14
|
}
|
|
14
15
|
export interface CompanyDetailsProps extends BaseInnerFormProps<CompanyDetailsSchema> {
|
|
15
16
|
companyType?: CompanyTypesValue;
|
|
@@ -2,7 +2,6 @@ import { ExistingLegalEntity } from '../../core/models/api/legal-entity';
|
|
|
2
2
|
import { CapabilityProblems } from '../../core/models/errors/capability-problems';
|
|
3
3
|
import { DropinAPIHandlers, DropinProps } from '../Dropins/types';
|
|
4
4
|
export interface DecisionMakersProps extends DropinAPIHandlers, DropinProps {
|
|
5
|
-
legalEntityResponse?: ExistingLegalEntity;
|
|
6
5
|
parentLegalEntity?: ExistingLegalEntity;
|
|
7
6
|
onNavigateToIndividual(legalEntityId?: string): void;
|
|
8
7
|
navigateBackToTaskList(): void;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { CompanyDropinProps } from '../../../Company/types';
|
|
2
|
-
export declare function CompanyDropinComponent({
|
|
2
|
+
export declare function CompanyDropinComponent({ country: parentCountry, problems: propProblems, hideDropinLayout, taskName, capabilities, homeButtonLabel, taskType, trackingConfig, associationDetail, parentLegalEntity, legalEntityResponse, isTargetLegalEntityType, eventEmitter, onSubmit: onExternalSubmit, handleCreateDocument, handleGetDocument, handleUpdateDocument, handleAddressSearch, handleFindAddress, handleCreateLegalEntity, handleUpdateLegalEntity, handleHomeClick, onTypeSwitch, onChange, }: CompanyDropinProps): import("preact").JSX.Element;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import './StepProgressIndicator.scss';
|
|
2
|
+
import { JSX } from 'preact';
|
|
3
|
+
export interface StepProgressIndicatorProps {
|
|
4
|
+
stepsCount: number;
|
|
5
|
+
activeStepIndex: number;
|
|
6
|
+
}
|
|
7
|
+
export declare const StepProgressIndicator: ({ activeStepIndex, stepsCount, }: StepProgressIndicatorProps) => JSX.Element | null;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { LegalEntity } from '../../../../core/models/api/legal-entity';
|
|
2
2
|
import { PayoutDetailsDropinProps } from '../../../PayoutDetails/types';
|
|
3
3
|
export declare const getRegistrationCountry: (legalEntityResponse: LegalEntity) => "ID" | "AF" | "AX" | "AL" | "DZ" | "AS" | "AD" | "AO" | "AI" | "AQ" | "AG" | "AR" | "AM" | "AW" | "AU" | "AT" | "AZ" | "BS" | "BH" | "BD" | "BB" | "BY" | "BE" | "BZ" | "BJ" | "BM" | "BT" | "BO" | "BQ" | "BA" | "BW" | "BV" | "BR" | "IO" | "BN" | "BG" | "BF" | "BI" | "KH" | "CM" | "CA" | "CV" | "KY" | "CF" | "TD" | "CL" | "CN" | "CX" | "CC" | "CO" | "KM" | "CG" | "CD" | "CK" | "CR" | "CI" | "HR" | "CU" | "CW" | "CY" | "CZ" | "DK" | "DJ" | "DM" | "DO" | "EC" | "EG" | "SV" | "GQ" | "ER" | "EE" | "ET" | "FK" | "FO" | "FJ" | "FI" | "FR" | "GF" | "PF" | "TF" | "GA" | "GM" | "GE" | "DE" | "GH" | "GI" | "GR" | "EL" | "GL" | "GD" | "GP" | "GU" | "GT" | "GG" | "GN" | "GW" | "GY" | "HT" | "HM" | "VA" | "HN" | "HK" | "HU" | "IS" | "IN" | "IR" | "IQ" | "IE" | "IM" | "IL" | "IT" | "JM" | "JP" | "JE" | "JO" | "KZ" | "KE" | "KI" | "KR" | "KP" | "KW" | "KG" | "LA" | "LV" | "LB" | "LS" | "LR" | "LY" | "LI" | "LT" | "LU" | "MO" | "MK" | "MG" | "MW" | "MY" | "MV" | "ML" | "MT" | "MH" | "MQ" | "MR" | "MU" | "YT" | "MX" | "FM" | "MD" | "MC" | "MN" | "ME" | "MS" | "MA" | "MZ" | "MM" | "NA" | "NR" | "NP" | "NL" | "NC" | "NZ" | "NI" | "NE" | "NG" | "NU" | "NF" | "MP" | "NO" | "OM" | "PK" | "PW" | "PS" | "PA" | "PG" | "PY" | "PE" | "PH" | "PN" | "PL" | "PT" | "PR" | "QA" | "RE" | "RO" | "RU" | "RW" | "SH" | "KN" | "LC" | "PM" | "VC" | "WS" | "SM" | "ST" | "SA" | "SN" | "RS" | "SC" | "SL" | "SG" | "SK" | "SI" | "SB" | "SO" | "ZA" | "GS" | "ES" | "LK" | "SD" | "SR" | "SJ" | "SZ" | "SE" | "CH" | "SY" | "TW" | "TJ" | "TZ" | "TH" | "TL" | "TG" | "TK" | "TO" | "TT" | "TN" | "TR" | "TM" | "TC" | "TV" | "UG" | "UA" | "AE" | "GB" | "US" | "UM" | "UY" | "UZ" | "VU" | "VE" | "VN" | "VG" | "VI" | "WF" | "EH" | "YE" | "ZM" | "ZW";
|
|
4
|
-
export declare function PayoutDetailsDropinComponent({ transferInstrument, setTransferInstrument, handleCreateDocument, handleGetDocument, handleUpdateDocument, handleUpdateTransferInstrument, handleCreateTransferInstrument, handleGetBankVerificationVendors, legalEntityResponse, trackingConfig, accountHolder, country, problems: propProblems, onSubmit: externalOnSubmit, onChange, taskType, taskName, eventEmitter, capabilities, handleHomeClick, homeButtonLabel, refreshLegalEntity, navigateBackToTaskList, }: PayoutDetailsDropinProps): import("preact").JSX.Element;
|
|
4
|
+
export declare function PayoutDetailsDropinComponent({ transferInstrument, setTransferInstrument, handleCreateDocument, handleGetDocument, handleUpdateDocument, handleUpdateTransferInstrument, handleCreateTransferInstrument, handleGetBankVerificationVendors, legalEntityResponse, trackingConfig, accountHolder, country, problems: propProblems, onSubmit: externalOnSubmit, onChange, taskType, taskName, eventEmitter, capabilities, handleHomeClick, homeButtonLabel, refreshLegalEntity, navigateBackToTaskList, createTrustedTransferInstrument, handleBankVerificationError, }: PayoutDetailsDropinProps): import("preact").JSX.Element;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { PciDropinProps } from '../types';
|
|
2
|
-
export declare function PciDropinComponent({
|
|
2
|
+
export declare function PciDropinComponent({ legalEntityResponse, pciTemplateResponse, handleHomeClick, handleLanguageChange, handleSign, taskType, trackingConfig, }: PciDropinProps): import("preact").JSX.Element;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { PciTemplateResponse, SignedBy } from '../../../core/models/api/contracts';
|
|
2
|
-
import {
|
|
2
|
+
import { ExistingLegalEntity } from '../../../core/models/api/legal-entity';
|
|
3
3
|
import { DropinProps } from '../types';
|
|
4
4
|
export interface PciSchema {
|
|
5
5
|
signer?: string;
|
|
6
6
|
acceptPci?: boolean;
|
|
7
7
|
}
|
|
8
8
|
export interface PciDropinProps extends DropinProps {
|
|
9
|
-
|
|
9
|
+
legalEntityResponse: ExistingLegalEntity;
|
|
10
10
|
pciTemplateResponse: PciTemplateResponse;
|
|
11
11
|
handleHomeClick(): void;
|
|
12
12
|
handleLanguageChange(): void;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { ServiceAgreementDropinProps } from '../types';
|
|
2
|
-
export declare function ServiceAgreementDropinComponent({
|
|
2
|
+
export declare function ServiceAgreementDropinComponent({ legalEntityResponse, handleGetServiceAgreement, handleHomeClick, handleSign, taskType, serviceAgreementTypes, serviceAgreementAcceptanceInfos, trackingConfig, }: ServiceAgreementDropinProps): import("preact").JSX.Element;
|
|
@@ -15,8 +15,8 @@ export interface ServiceAgreementSchema {
|
|
|
15
15
|
acceptServiceAgreement?: boolean;
|
|
16
16
|
}
|
|
17
17
|
export interface ServiceAgreementDropinProps extends DropinProps {
|
|
18
|
+
legalEntityResponse: ExistingLegalEntity;
|
|
18
19
|
taskType: TaskTypes.SERVICE_AGREEMENT;
|
|
19
|
-
legalEntity: ExistingLegalEntity;
|
|
20
20
|
serviceAgreementTypes: ServiceAgreementType[];
|
|
21
21
|
serviceAgreementAcceptanceInfos: ServiceAgreementAcceptanceInfo[];
|
|
22
22
|
handleHomeClick(): void;
|
package/dist/types/components/Dropins/SolePropDropin/components/SolePropDropinComponent.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { SolePropDropinProps } from '../../../SoleProp/types';
|
|
2
|
-
export declare function SolePropDropinComponent(
|
|
2
|
+
export declare function SolePropDropinComponent({ problems: problemsProp, capabilities, country, parentLegalEntity, legalEntityResponse, eventEmitter, homeButtonLabel, hideDropinLayout, onSubmit, onChange, handleHomeClick, handleCreateDocument, handleGetDocument, handleUpdateDocument, handleAddressSearch, handleFindAddress, handleUpdateLegalEntity, handleCreateLegalEntity, }: SolePropDropinProps): import("preact").JSX.Element;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { State, TopLevelDataSchema } from '../../core/Context/StateContext/types';
|
|
2
|
-
import { Address, AddressSearchRequest, AddressSearchResponse } from '../../core/models/api/address-search';
|
|
3
|
-
import { DownloadPci, PciQuestionnaireIds, PciQuestionnaires, PciStatus, PciTemplateRequest, PciTemplateResponse, ServiceAgreementAcceptanceInfos, ServiceAgreementRequest, ServiceAgreementResponse, ServiceAgreementSignRequest, ServiceAgreementSignResponse, ServiceAgreementStatus, SignedBy } from '../../core/models/api/contracts';
|
|
1
|
+
import type { State, TopLevelDataSchema } from '../../core/Context/StateContext/types';
|
|
2
|
+
import type { Address, AddressSearchRequest, AddressSearchResponse } from '../../core/models/api/address-search';
|
|
3
|
+
import type { DownloadPci, PciQuestionnaireIds, PciQuestionnaires, PciStatus, PciStatusRequest, PciTemplateRequest, PciTemplateResponse, ServiceAgreementAcceptanceInfos, ServiceAgreementRequest, ServiceAgreementResponse, ServiceAgreementSignRequest, ServiceAgreementSignResponse, ServiceAgreementStatus, SignedBy } from '../../core/models/api/contracts';
|
|
4
4
|
import { Document } from '../../core/models/api/document';
|
|
5
5
|
import { BankVerificationVendorsResponse } from '../../core/models/api/get-bankVerification-providers';
|
|
6
|
-
import { InstantIdVerificationStartCheckRequest, InstantIdVerificationStartCheckResponse, InstantIdVerificationTokenRequest, InstantIdVerificationTokenResponse } from '../../core/models/api/instant-id-verification';
|
|
6
|
+
import type { InstantIdVerificationStartCheckRequest, InstantIdVerificationStartCheckResponse, InstantIdVerificationTokenRequest, InstantIdVerificationTokenResponse } from '../../core/models/api/instant-id-verification';
|
|
7
7
|
import { ExistingLegalEntity, LegalEntity, PatchLegalEntity } from '../../core/models/api/legal-entity';
|
|
8
8
|
import { ReviewCompletion } from '../../core/models/api/review';
|
|
9
9
|
import { TransferInstrument } from '../../core/models/api/transfer-instrument';
|
|
@@ -11,10 +11,10 @@ import { BaseTrackingPayload } from '../../core/utils';
|
|
|
11
11
|
import { TranslationKey } from '../../language/types';
|
|
12
12
|
import EventEmitter from '../EventEmitter';
|
|
13
13
|
import { TaskTypes } from '../TaskList/types';
|
|
14
|
-
import { BasicComponentProps } from '../UIElement';
|
|
14
|
+
import type { BasicComponentProps } from '../UIElement';
|
|
15
15
|
export interface DropinComposerProps extends DropinAPIHandlers, BasicComponentProps {
|
|
16
16
|
capabilities?: string[];
|
|
17
|
-
legalEntityResponse
|
|
17
|
+
legalEntityResponse: ExistingLegalEntity;
|
|
18
18
|
onChange?: (state: State<TopLevelDataSchema>) => void;
|
|
19
19
|
onSubmit?: (data: unknown) => void;
|
|
20
20
|
onLoad?: () => void;
|
|
@@ -37,7 +37,7 @@ export interface DropinAPIHandlers {
|
|
|
37
37
|
handleGetPciQuestionnaires?(legalEntityId: string): Promise<PciQuestionnaires>;
|
|
38
38
|
handleSignPci?(legalEntityId: string, data: SignedBy): Promise<PciQuestionnaireIds>;
|
|
39
39
|
handleDownloadPci?(legalEntityId: string, pciReference: string): Promise<DownloadPci>;
|
|
40
|
-
handleGetPciStatus?(legalEntityId: string): Promise<PciStatus>;
|
|
40
|
+
handleGetPciStatus?(legalEntityId: string, data: PciStatusRequest): Promise<PciStatus>;
|
|
41
41
|
handleGetServiceAgreement?(legalEntityId: string, data: ServiceAgreementRequest): Promise<ServiceAgreementResponse>;
|
|
42
42
|
handleSignServiceAgreement?(legalEntityId: string, termsOfServiceDocumentId: string, data: ServiceAgreementSignRequest): Promise<ServiceAgreementSignResponse>;
|
|
43
43
|
handleGetServiceAgreementStatus?(legalEntityId: string): Promise<ServiceAgreementStatus>;
|
|
@@ -48,14 +48,13 @@ export interface DropinAPIHandlers {
|
|
|
48
48
|
handleGetIdVerificationStartCheck?(legalEntityId: string, data: InstantIdVerificationStartCheckRequest): Promise<InstantIdVerificationStartCheckResponse>;
|
|
49
49
|
}
|
|
50
50
|
export interface DropinProps {
|
|
51
|
+
legalEntityResponse?: ExistingLegalEntity;
|
|
51
52
|
baseTrackingPayload?: BaseTrackingPayload;
|
|
52
53
|
eventEmitter: EventEmitter;
|
|
53
54
|
homeButtonLabel?: string;
|
|
54
55
|
handleHomeClick?(): void;
|
|
55
56
|
handleBackClick?(): void;
|
|
56
57
|
hideDropinLayout?: boolean;
|
|
57
|
-
legalEntityId?: string;
|
|
58
|
-
legalEntityResponse?: ExistingLegalEntity;
|
|
59
58
|
trackingConfig?: {
|
|
60
59
|
topLevelLegalEntity: ExistingLegalEntity;
|
|
61
60
|
};
|
package/dist/types/components/EmbeddedDropins/PayoutEmbeddedDropin/PayoutEmbeddedDropin.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
|
+
import { ExistingLegalEntity } from '../../../core/models/api/legal-entity';
|
|
1
2
|
import EventEmitter from '../../EventEmitter';
|
|
2
3
|
export interface PayoutEmbeddedDropinProps {
|
|
3
|
-
legalEntityId:
|
|
4
|
+
legalEntityId: ExistingLegalEntity['id'];
|
|
4
5
|
transferInstrumentId?: string;
|
|
5
6
|
onChange?(): void;
|
|
6
7
|
onSubmit?(): void;
|
|
@@ -32,7 +32,7 @@ export interface IndividualProps extends BaseOuterFormProps<IndividualSchema> {
|
|
|
32
32
|
activeForm?: FormModel;
|
|
33
33
|
forms?: FormModel[];
|
|
34
34
|
problems?: any;
|
|
35
|
-
legalEntityId
|
|
35
|
+
legalEntityId: string;
|
|
36
36
|
taskType?: TaskTypes;
|
|
37
37
|
allowedRoles?: DecisionMakerType[];
|
|
38
38
|
onTypeSwitch?(legalEntityType: LegalEntityType): void;
|
|
@@ -40,7 +40,7 @@ export interface IndividualProps extends BaseOuterFormProps<IndividualSchema> {
|
|
|
40
40
|
onNext?(e: any, callbacks: any, isValid: any): void;
|
|
41
41
|
onBack?(): void;
|
|
42
42
|
}
|
|
43
|
-
export interface IndividualDropinProps extends IndividualProps, DropinAPIHandlers, DropinProps {
|
|
43
|
+
export interface IndividualDropinProps extends Omit<IndividualProps, 'legalEntityId'>, DropinAPIHandlers, DropinProps {
|
|
44
44
|
parentLegalEntity?: LegalEntity;
|
|
45
45
|
trustMember?: TrustMember;
|
|
46
46
|
isTargetLegalEntityType?: boolean;
|
|
@@ -3,6 +3,7 @@ import type { BaseOuterFormProps } from '../../core/hooks/useForm';
|
|
|
3
3
|
import { BankVerificationVendorsResponse } from '../../core/models/api/get-bankVerification-providers';
|
|
4
4
|
import { ExistingLegalEntity, LegalEntity } from '../../core/models/api/legal-entity';
|
|
5
5
|
import { TransferInstrument } from '../../core/models/api/transfer-instrument';
|
|
6
|
+
import { BankVerificationErrorResponse, CreateTrustedTransferInstrumentResponse } from '../../core/models/api/trusted-transferInstrument';
|
|
6
7
|
import { FormModel } from '../../core/models/form';
|
|
7
8
|
import type { AccountVerificationSchema, CountryBankVerificationVendors } from '../BankVerification/types';
|
|
8
9
|
import type { DropinAPIHandlers, DropinProps } from '../Dropins/types';
|
|
@@ -24,7 +25,7 @@ export interface PayoutDetailsProps extends BaseOuterFormProps<PayoutDetailsSche
|
|
|
24
25
|
forms?: FormModel[];
|
|
25
26
|
problems?: any;
|
|
26
27
|
onSubmit?: (data: PayoutDetailsSchema) => void;
|
|
27
|
-
legalEntityResponse
|
|
28
|
+
legalEntityResponse: ExistingLegalEntity;
|
|
28
29
|
taskType?: TaskTypes;
|
|
29
30
|
handleGetBankVerificationVendors?(data: string): Promise<BankVerificationVendorsResponse>;
|
|
30
31
|
onBack?: () => void;
|
|
@@ -33,8 +34,10 @@ export interface PayoutDetailsProps extends BaseOuterFormProps<PayoutDetailsSche
|
|
|
33
34
|
bankVerificationVendors?: CountryBankVerificationVendors;
|
|
34
35
|
instantVerificationEnabled?: boolean;
|
|
35
36
|
refreshLegalEntity?(): Promise<LegalEntity>;
|
|
37
|
+
createTrustedTransferInstrument?: (code: string, state: string) => Promise<CreateTrustedTransferInstrumentResponse>;
|
|
38
|
+
handleBankVerificationError?: (errorCode: string, errorMessage: string, state: string, metadata?: Map<string, string>) => Promise<BankVerificationErrorResponse>;
|
|
36
39
|
}
|
|
37
|
-
export interface PayoutDetailsDropinProps extends PayoutDetailsProps, DropinProps, DropinAPIHandlers {
|
|
40
|
+
export interface PayoutDetailsDropinProps extends PayoutDetailsProps, Omit<DropinProps, 'legalEntityResponse'>, DropinAPIHandlers {
|
|
38
41
|
accountHolder?: string;
|
|
39
42
|
transferInstrument?: TransferInstrument;
|
|
40
43
|
setTransferInstrument?: StateUpdater<TransferInstrument>;
|
package/dist/types/components/RegistrationAddress/component/RegistrationAddressComponent.d.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { FormList } from '../../../core/models/form';
|
|
2
2
|
import { RegistrationAddressProps } from '../types';
|
|
3
3
|
export declare const registrationAddressFields: string[];
|
|
4
|
-
export declare const
|
|
5
|
-
declare function RegistrationAddressComponent(props: RegistrationAddressProps): import("preact").JSX.Element;
|
|
6
|
-
export default RegistrationAddressComponent;
|
|
4
|
+
export declare const registrationAddressForms: FormList;
|
|
5
|
+
export declare function RegistrationAddressComponent(props: RegistrationAddressProps): import("preact").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './component/RegistrationAddressComponent';
|
|
@@ -27,5 +27,4 @@ export interface SolePropProps extends BaseOuterFormProps<SolePropSchema> {
|
|
|
27
27
|
handleFindAddress?: DropinAPIHandlers['handleFindAddress'];
|
|
28
28
|
}
|
|
29
29
|
export interface SolePropDropinProps extends SolePropProps, DropinAPIHandlers, DropinProps {
|
|
30
|
-
legalEntity?: LegalEntity;
|
|
31
30
|
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { LegalEntityType } from '../../core/models/api/legal-entity-type';
|
|
2
|
+
import { IntroTypes } from './types';
|
|
3
|
+
export interface TaskIntroProps {
|
|
4
|
+
index: number;
|
|
5
|
+
intro: IntroTypes;
|
|
6
|
+
legalEntityType: LegalEntityType;
|
|
7
|
+
}
|
|
8
|
+
export declare const TaskIntro: ({ index, intro, legalEntityType }: TaskIntroProps) => import("preact").JSX.Element;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import './_task-intros.component.scss';
|
|
2
|
+
import type { JSX } from 'preact';
|
|
3
|
+
import { LegalEntityType } from '../../core/models/api/legal-entity-type';
|
|
4
|
+
import { TaskTypes } from '../TaskList/types';
|
|
5
|
+
export interface TaskIntrosProps {
|
|
6
|
+
legalEntityType: LegalEntityType;
|
|
7
|
+
onExitIntro: () => void;
|
|
8
|
+
tasks: TaskTypes[];
|
|
9
|
+
}
|
|
10
|
+
export declare const TaskIntros: ({ legalEntityType, onExitIntro, tasks, }: TaskIntrosProps) => JSX.Element | null;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { LegalEntityType } from '../../core/models/api/legal-entity-type';
|
|
2
|
+
import { TranslationKey, Translations } from '../../language/types';
|
|
3
|
+
import { IntroTypes } from './types';
|
|
4
|
+
export declare enum IntroDescriptionTranslationKeyElements {
|
|
5
|
+
ListItem = "LI",
|
|
6
|
+
Paragraph = "P"
|
|
7
|
+
}
|
|
8
|
+
interface IntroDescriptionTranslationKeyFactors {
|
|
9
|
+
elementType?: IntroDescriptionTranslationKeyElements;
|
|
10
|
+
legalEntityType: LegalEntityType;
|
|
11
|
+
introType: IntroTypes;
|
|
12
|
+
}
|
|
13
|
+
export declare const getIntroDescriptionTranslationKeys: (translations: Translations, factors: IntroDescriptionTranslationKeyFactors) => TranslationKey[];
|
|
14
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { TaskTypes } from '../TaskList/types';
|
|
2
|
+
export declare const taskIntrosInOrder: readonly [TaskTypes.COMPANY, TaskTypes.DECISION_MAKER_OVERVIEW, TaskTypes.INDIVIDUAL, TaskTypes.PAYOUT];
|
|
3
|
+
export type TaskTypesWithIntro = (typeof taskIntrosInOrder)[number];
|
|
4
|
+
export declare const enum ExtraIntroTypes {
|
|
5
|
+
PROLOGUE = "prologue",
|
|
6
|
+
EPILOGUE = "epilogue"
|
|
7
|
+
}
|
|
8
|
+
export type IntroTypes = TaskTypesWithIntro | `${ExtraIntroTypes}`;
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import type { PciStatus } from '../../core/models/api/contracts';
|
|
2
|
-
import type {
|
|
2
|
+
import type { ExistingLegalEntity } from '../../core/models/api/legal-entity';
|
|
3
3
|
import type { CapabilityProblems } from '../../core/models/errors/capability-problems';
|
|
4
4
|
import type { EntityProblems } from '../../core/models/errors/entity-problems';
|
|
5
5
|
import type { ServiceAgreementAcceptanceInfo, ServiceAgreementType } from '../Dropins/ServiceAgreementDropinComponent/types';
|
|
6
6
|
import type { ActionsMenuOption } from '../internal/Menu/ActionsMenu';
|
|
7
7
|
export declare enum TaskTypes {
|
|
8
|
+
INTRO = "INTRO",
|
|
8
9
|
TASKS_OVERVIEW = "TASKS_OVERVIEW",
|
|
9
10
|
REVIEW = "REVIEW",
|
|
10
11
|
INDIVIDUAL = "INDIVIDUAL",
|
|
@@ -13,10 +14,10 @@ export declare enum TaskTypes {
|
|
|
13
14
|
PAYIN = "PAYIN",
|
|
14
15
|
SERVICE_AGREEMENT = "SERVICE_AGREEMENT",
|
|
15
16
|
PCI_DSS = "PCI_DSS",
|
|
17
|
+
DECISION_MAKER = "DECISION_MAKER",
|
|
16
18
|
DECISION_MAKER_OVERVIEW = "DECISION_MAKER_OVERVIEW",
|
|
17
19
|
TRUST = "TRUST",
|
|
18
20
|
TRUST_MEMBER_OVERVIEW = "TRUST_MEMBER",
|
|
19
|
-
DECISION_MAKER = "DECISION_MAKER",
|
|
20
21
|
TRUST_MEMBER_INDIVIDUAL = "TRUST_MEMBER_INDIVIDUAL",
|
|
21
22
|
TRUST_MEMBER_COMPANY = "TRUST_MEMBER_COMPANY",
|
|
22
23
|
TRUST_MEMBER_ROLE_AND_TYPE = "TRUST_MEMBER_ROLE_AND_TYPE",
|
|
@@ -49,7 +50,7 @@ export interface TaskListComponentProps {
|
|
|
49
50
|
isReview?: boolean;
|
|
50
51
|
onNavigateToTask(taskType: TaskTypes, id?: string): void;
|
|
51
52
|
capabilityProblems: CapabilityProblems;
|
|
52
|
-
legalEntityResponse:
|
|
53
|
+
legalEntityResponse: ExistingLegalEntity;
|
|
53
54
|
pciStatus?: PciStatus;
|
|
54
55
|
serviceAgreementTypes?: ServiceAgreementType[];
|
|
55
56
|
serviceAgreementAcceptanceInfos?: ServiceAgreementAcceptanceInfo[];
|
|
@@ -2,6 +2,7 @@ import { JSX } from 'preact';
|
|
|
2
2
|
import { AuthProviderProps } from '../core/Context/AuthContext/AuthProvider';
|
|
3
3
|
import { CoreProviderProps } from '../core/Context/CoreProvider';
|
|
4
4
|
import { ExperimentsProps } from '../core/Context/ExperimentContext/types';
|
|
5
|
+
import { I18nProviderProps } from '../core/Context/I18nProvider/I18nProvider';
|
|
5
6
|
import { SettingsProps } from '../core/Context/SettingsContext/types';
|
|
6
7
|
import { UserEventCallback } from '../core/user-events';
|
|
7
8
|
import { BaseElement, BaseElementProps } from './BaseElement';
|
|
@@ -9,7 +10,7 @@ import EventEmitter from './EventEmitter';
|
|
|
9
10
|
export interface BasicComponentProps {
|
|
10
11
|
eventEmitter?: EventEmitter;
|
|
11
12
|
}
|
|
12
|
-
export interface UIElementProps<ComponentProps extends BasicComponentProps> extends BaseElementProps, CoreProviderProps, AuthProviderProps, SettingsProps, ExperimentsProps {
|
|
13
|
+
export interface UIElementProps<ComponentProps extends BasicComponentProps> extends BaseElementProps, CoreProviderProps, AuthProviderProps, I18nProviderProps, SettingsProps, ExperimentsProps {
|
|
13
14
|
onUserEvent?: UserEventCallback;
|
|
14
15
|
component: (props: ComponentProps) => JSX.Element;
|
|
15
16
|
componentProps: ComponentProps;
|