@adyen/adyen-web 5.13.1 → 5.16.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/README.md +4 -1
- package/dist/adyen.css +8 -7
- package/dist/adyen.css.map +1 -1
- package/dist/adyen.js +1 -1
- package/dist/adyen.js.map +1 -1
- package/dist/cjs/adyen.css +8 -7
- package/dist/cjs/adyen.css.map +1 -1
- package/dist/cjs/index.js +1 -1
- package/dist/es/adyen.css +8 -7
- package/dist/es/adyen.css.map +1 -1
- package/dist/es/index.js +1 -1
- package/dist/es.modern/adyen.css +8 -7
- package/dist/es.modern/adyen.css.map +1 -1
- package/dist/es.modern/index.js +1 -1
- package/dist/types/components/Atome/config.d.ts +2 -2
- package/dist/types/components/BankTransfer/types.d.ts +3 -0
- package/dist/types/components/BcmcMobile/BcmcMobile.d.ts +1 -4
- package/dist/types/components/Card/Bancontact.d.ts +1 -4
- package/dist/types/components/Card/Card.d.ts +1 -4
- package/dist/types/components/Card/components/CardInput/components/CardFieldsWrapper.d.ts +3 -1
- package/dist/types/components/Card/components/CardInput/components/CardHolderName.d.ts +1 -1
- package/dist/types/components/Card/components/CardInput/components/types.d.ts +6 -0
- package/dist/types/components/Card/components/CardInput/defaultProps.d.ts +2 -0
- package/dist/types/components/Card/components/CardInput/types.d.ts +7 -1
- package/dist/types/components/Card/components/CardInput/utils.d.ts +9 -1
- package/dist/types/components/Dragonpay/Dragonpay.d.ts +1 -4
- package/dist/types/components/Dropin/Dropin.d.ts +1 -4
- package/dist/types/components/Dropin/components/DropinComponent.d.ts +5 -0
- package/dist/types/components/Dropin/types.d.ts +4 -1
- package/dist/types/components/MBWay/components/MBWayInput/MBWayInput.d.ts +2 -0
- package/dist/types/components/MBWay/components/MBWayInput/types.d.ts +5 -0
- package/dist/types/components/OnlineBankingIN/index.d.ts +11 -0
- package/dist/types/components/Pix/Pix.d.ts +1 -4
- package/dist/types/components/Swish/Swish.d.ts +1 -4
- package/dist/types/components/WalletIN/index.d.ts +17 -0
- package/dist/types/components/WeChat/WeChat.d.ts +1 -4
- package/dist/types/components/index.d.ts +2 -0
- package/dist/types/components/internal/Address/Specifications.d.ts +9 -0
- package/dist/types/components/internal/Address/constants.d.ts +9 -0
- package/dist/types/components/internal/Address/types.d.ts +4 -1
- package/dist/types/components/internal/IFrame/Iframe.d.ts +1 -3
- package/dist/types/components/internal/PhoneInput/types.d.ts +4 -0
- package/dist/types/components/internal/PhoneInputNew/PhoneInput.d.ts +10 -0
- package/dist/types/components/internal/PhoneInputNew/index.d.ts +1 -0
- package/dist/types/components/internal/PhoneInputNew/types.d.ts +25 -0
- package/dist/types/components/internal/PhoneInputNew/usePhonePrefixes.d.ts +7 -0
- package/dist/types/components/internal/PhoneInputNew/validate.d.ts +3 -0
- package/dist/types/components/internal/SecuredFields/SFP/SecuredFieldsProvider.d.ts +2 -0
- package/dist/types/components/internal/SecuredFields/SFP/SecuredFieldsProviderHandlers.d.ts +2 -0
- package/dist/types/components/internal/SecuredFields/SFP/defaultProps.d.ts +1 -0
- package/dist/types/components/internal/SecuredFields/lib/CSF/AbstractCSF.d.ts +3 -1
- package/dist/types/components/internal/SecuredFields/lib/CSF/extensions/handleIOSTouchEvents.d.ts +39 -0
- package/dist/types/components/internal/SecuredFields/lib/CSF/types.d.ts +1 -0
- package/dist/types/components/internal/SecuredFields/lib/configuration/constants.d.ts +1 -1
- package/dist/types/components/internal/SecuredFields/lib/securedField/AbstractSecuredField.d.ts +1 -1
- package/dist/types/components/internal/SecuredFields/lib/securedField/SecuredField.d.ts +1 -1
- package/dist/types/components/internal/SecuredFields/lib/utilities/commonUtils.d.ts +5 -6
- package/dist/types/components/internal/SocialSecurityNumberBrazil/SocialSecurityNumberBrazil.d.ts +2 -1
- package/dist/types/components/types.d.ts +2 -4
- package/dist/types/core/Analytics/Analytics.d.ts +1 -1
- package/dist/types/core/Analytics/types.d.ts +0 -4
- package/dist/types/core/CheckoutSession/CheckoutSession.d.ts +5 -0
- package/dist/types/core/Services/data-set.d.ts +6 -0
- package/dist/types/core/Services/get-dataset.d.ts +1 -1
- package/dist/types/core/Services/sessions/cancel-order.d.ts +6 -0
- package/dist/types/utils/Validator/ValidationRuleResult.d.ts +17 -0
- package/dist/types/utils/Validator/Validator.d.ts +5 -18
- package/dist/types/utils/Validator/types.d.ts +4 -0
- package/dist/types/utils/useForm/reducer.d.ts +4 -2
- package/dist/types/utils/useForm/types.d.ts +18 -8
- package/dist/types/utils/useForm/useForm.d.ts +2 -18
- package/dist/types/utils/validator-utils.d.ts +9 -0
- package/package.json +3 -3
- package/dist/types/components/internal/SecuredFields/lib/CSF/extensions/additionalFields.d.ts +0 -9
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export declare const
|
|
1
|
+
export declare const ATOME_SUPPORTED_COUNTRIES: string[];
|
|
2
2
|
/**
|
|
3
|
-
* Creates Address Specification
|
|
3
|
+
* Creates Address Specification according to the Atome UI. This specification overrides all available specifications
|
|
4
4
|
*
|
|
5
5
|
* This custom specification is needed in order to create the desired layout of the Atome billing address part. The usage of the
|
|
6
6
|
* 'default' layout specification from the Address component does not align correctly the available fields, therefore we need to
|
|
@@ -11,10 +11,7 @@ declare class BCMCMobileElement extends QRLoaderContainer {
|
|
|
11
11
|
qrCodeImage?: string;
|
|
12
12
|
paymentData?: string;
|
|
13
13
|
instructions?: string;
|
|
14
|
-
session?:
|
|
15
|
-
id: string;
|
|
16
|
-
data: string;
|
|
17
|
-
};
|
|
14
|
+
session?: import("../../core/CheckoutSession/CheckoutSession").default;
|
|
18
15
|
onChange?: (state: any, element: import("../UIElement").UIElement<any>) => void;
|
|
19
16
|
onValid?: (state: any, element: import("../UIElement").UIElement<any>) => void;
|
|
20
17
|
beforeSubmit?: (state: any, element: import("../UIElement").UIElement<any>, actions: any) => Promise<void>;
|
|
@@ -57,10 +57,7 @@ declare class BancontactElement extends CardElement {
|
|
|
57
57
|
onFocus?: (event: import("../internal/SecuredFields/lib/types").CbObjOnFocus) => void;
|
|
58
58
|
onBinValue?: (event: import("../internal/SecuredFields/lib/types").CbObjOnBinValue) => void;
|
|
59
59
|
onBinLookup?: (event: import("../internal/SecuredFields/lib/types").CbObjOnBinLookup) => void;
|
|
60
|
-
session?:
|
|
61
|
-
id: string;
|
|
62
|
-
data: string;
|
|
63
|
-
};
|
|
60
|
+
session?: import("../../core/CheckoutSession/CheckoutSession").default;
|
|
64
61
|
onChange?: (state: any, element: import("../UIElement").UIElement<any>) => void;
|
|
65
62
|
onValid?: (state: any, element: import("../UIElement").UIElement<any>) => void;
|
|
66
63
|
beforeSubmit?: (state: any, element: import("../UIElement").UIElement<any>, actions: any) => Promise<void>;
|
|
@@ -52,10 +52,7 @@ export declare class CardElement extends UIElement<CardElementProps> {
|
|
|
52
52
|
onFocus?: (event: import("../internal/SecuredFields/lib/types").CbObjOnFocus) => void;
|
|
53
53
|
onBinValue?: (event: import("../internal/SecuredFields/lib/types").CbObjOnBinValue) => void;
|
|
54
54
|
onBinLookup?: (event: CbObjOnBinLookup) => void;
|
|
55
|
-
session?:
|
|
56
|
-
id: string;
|
|
57
|
-
data: string;
|
|
58
|
-
};
|
|
55
|
+
session?: import("../../core/CheckoutSession/CheckoutSession").default;
|
|
59
56
|
onChange?: (state: any, element: UIElement<any>) => void;
|
|
60
57
|
onValid?: (state: any, element: UIElement<any>) => void;
|
|
61
58
|
beforeSubmit?: (state: any, element: UIElement<any>, actions: any) => Promise<void>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { h } from 'preact';
|
|
2
|
-
export declare const CardFieldsWrapper: ({ data, valid, errors, handleChangeFor, sfpState, setFocusOn, collateErrors, errorFieldId, cvcPolicy, focusedElement, hasInstallments, handleInstallments, showAmountsInInstallments, brandsIcons, mergedSRErrors, moveFocus, showPanel, handleErrorPanelFocus, formData, formErrors, formValid, expiryDatePolicy, dualBrandSelectElements, extensions, selectedBrandValue, showKCP, showBrazilianSSN, socialSecurityNumber, handleOnStoreDetails, billingAddress, handleAddress, billingAddressRef, amount, billingAddressRequired, billingAddressRequiredFields, billingAddressAllowedCountries, brandsConfiguration, enableStoreDetails, hasCVC, hasHolderName, holderNameRequired, installmentOptions, placeholders, positionHolderNameOnTop, showBrandIcon, showBrandsUnderCardNumber }: {
|
|
2
|
+
export declare const CardFieldsWrapper: ({ data, valid, errors, handleChangeFor, sfpState, setFocusOn, collateErrors, errorFieldId, cvcPolicy, focusedElement, hasInstallments, handleInstallments, showAmountsInInstallments, brandsIcons, mergedSRErrors, moveFocus, showPanel, handleErrorPanelFocus, formData, formErrors, formValid, expiryDatePolicy, dualBrandSelectElements, extensions, selectedBrandValue, showKCP, showBrazilianSSN, socialSecurityNumber, handleOnStoreDetails, billingAddress, handleAddress, billingAddressRef, partialAddressSchema, amount, billingAddressRequired, billingAddressRequiredFields, billingAddressAllowedCountries, brandsConfiguration, enableStoreDetails, hasCVC, hasHolderName, holderNameRequired, installmentOptions, placeholders, positionHolderNameOnTop, showBrandIcon, showBrandsUnderCardNumber, iOSFocusedField }: {
|
|
3
3
|
data: any;
|
|
4
4
|
valid: any;
|
|
5
5
|
errors: any;
|
|
@@ -32,6 +32,7 @@ export declare const CardFieldsWrapper: ({ data, valid, errors, handleChangeFor,
|
|
|
32
32
|
billingAddress: any;
|
|
33
33
|
handleAddress: any;
|
|
34
34
|
billingAddressRef: any;
|
|
35
|
+
partialAddressSchema: any;
|
|
35
36
|
amount: any;
|
|
36
37
|
billingAddressRequired: any;
|
|
37
38
|
billingAddressRequiredFields: any;
|
|
@@ -46,4 +47,5 @@ export declare const CardFieldsWrapper: ({ data, valid, errors, handleChangeFor,
|
|
|
46
47
|
positionHolderNameOnTop: any;
|
|
47
48
|
showBrandIcon: any;
|
|
48
49
|
showBrandsUnderCardNumber: any;
|
|
50
|
+
iOSFocusedField: any;
|
|
49
51
|
}) => h.JSX.Element;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { h } from 'preact';
|
|
2
2
|
import { CardHolderNameProps } from './types';
|
|
3
|
-
export default function CardHolderName({ onBlur, onInput, placeholder, value, required, error, isValid }: CardHolderNameProps): h.JSX.Element;
|
|
3
|
+
export default function CardHolderName({ onBlur, onInput, placeholder, value, required, error, isValid, disabled }: CardHolderNameProps): h.JSX.Element;
|
|
@@ -31,6 +31,7 @@ export interface CardHolderNameProps {
|
|
|
31
31
|
placeholder?: string;
|
|
32
32
|
required?: boolean;
|
|
33
33
|
value?: string;
|
|
34
|
+
disabled?: boolean;
|
|
34
35
|
}
|
|
35
36
|
export interface CardNumberProps {
|
|
36
37
|
brand: string;
|
|
@@ -115,6 +116,7 @@ export interface KCPProps {
|
|
|
115
116
|
error: boolean;
|
|
116
117
|
isValid: boolean;
|
|
117
118
|
value: string;
|
|
119
|
+
disabled?: boolean;
|
|
118
120
|
}
|
|
119
121
|
export declare type RtnType_ParamBooleanFn = (tn: any) => boolean;
|
|
120
122
|
export declare type RtnType_ParamVoidFn = (e: any) => void;
|
|
@@ -138,3 +140,7 @@ export interface SfSpanProps {
|
|
|
138
140
|
children?: ComponentChildren;
|
|
139
141
|
['data-info']?: string;
|
|
140
142
|
}
|
|
143
|
+
export interface TouchStartEventObj {
|
|
144
|
+
fieldType: string;
|
|
145
|
+
name?: string;
|
|
146
|
+
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { SocialSecurityMode } from '../../types';
|
|
2
|
+
import { AddressModeOptions } from './types';
|
|
2
3
|
declare const _default: {
|
|
3
4
|
type: string;
|
|
4
5
|
setComponentRef: () => void;
|
|
@@ -10,6 +11,7 @@ declare const _default: {
|
|
|
10
11
|
showBrandsUnderCardNumber: boolean;
|
|
11
12
|
positionHolderNameOnTop: boolean;
|
|
12
13
|
billingAddressRequired: boolean;
|
|
14
|
+
billingAddressMode: AddressModeOptions;
|
|
13
15
|
billingAddressRequiredFields: string[];
|
|
14
16
|
installmentOptions: {};
|
|
15
17
|
configuration: {
|
|
@@ -4,7 +4,7 @@ import { PaymentAmount } from '../../../../types';
|
|
|
4
4
|
import { InstallmentOptions } from './components/types';
|
|
5
5
|
import { ValidationResult } from '../../../internal/PersonalDetails/types';
|
|
6
6
|
import { CVCPolicyType, DatePolicyType } from '../../../internal/SecuredFields/lib/types';
|
|
7
|
-
import { ValidationRuleResult } from '../../../../utils/Validator/
|
|
7
|
+
import { ValidationRuleResult } from '../../../../utils/Validator/ValidationRuleResult';
|
|
8
8
|
import Specifications from '../../../internal/Address/Specifications';
|
|
9
9
|
import { AddressSchema, StringObject } from '../../../internal/Address/types';
|
|
10
10
|
import { CbObjOnError, StylesObject } from '../../../internal/SecuredFields/lib/types';
|
|
@@ -49,6 +49,7 @@ export interface CardInputProps {
|
|
|
49
49
|
billingAddressAllowedCountries?: string[];
|
|
50
50
|
billingAddressRequired?: boolean;
|
|
51
51
|
billingAddressRequiredFields?: string[];
|
|
52
|
+
billingAddressMode?: AddressModeOptions;
|
|
52
53
|
brand?: string;
|
|
53
54
|
brands?: string[];
|
|
54
55
|
brandsConfiguration?: CardBrandsConfiguration;
|
|
@@ -163,4 +164,9 @@ export interface SortErrorsObj {
|
|
|
163
164
|
i18n: Language;
|
|
164
165
|
countrySpecificLabels: StringObject;
|
|
165
166
|
}
|
|
167
|
+
export declare enum AddressModeOptions {
|
|
168
|
+
full = "full",
|
|
169
|
+
partial = "partial",
|
|
170
|
+
none = "none"
|
|
171
|
+
}
|
|
166
172
|
export {};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ErrorPanelObj } from '../../../../core/Errors/ErrorPanel';
|
|
2
|
-
import { CardInputProps, LayoutObj, SortErrorsObj } from './types';
|
|
2
|
+
import { AddressModeOptions, CardInputProps, LayoutObj, SortErrorsObj } from './types';
|
|
3
3
|
import { InstallmentsObj } from './components/Installments/Installments';
|
|
4
4
|
import { SFPProps } from '../../../internal/SecuredFields/SFP/types';
|
|
5
5
|
export declare const getCardImageUrl: (brand: string, loadingContext: string) => string;
|
|
@@ -32,3 +32,11 @@ export declare const extractPropsForCardFields: (props: CardInputProps) => {
|
|
|
32
32
|
expiryYear: string;
|
|
33
33
|
};
|
|
34
34
|
export declare const extractPropsForSFP: (props: CardInputProps) => SFPProps;
|
|
35
|
+
export declare const handlePartialAddressMode: (addressMode: AddressModeOptions) => any[] | {
|
|
36
|
+
default: {
|
|
37
|
+
labels: {
|
|
38
|
+
postalCode: string;
|
|
39
|
+
};
|
|
40
|
+
schema: "postalCode"[];
|
|
41
|
+
};
|
|
42
|
+
};
|
|
@@ -21,10 +21,7 @@ export declare class DragonpayElement extends UIElement<DragonpayElementProps> {
|
|
|
21
21
|
loadingContext?: string;
|
|
22
22
|
reference?: string;
|
|
23
23
|
i18n?: import("../../language").default;
|
|
24
|
-
session?:
|
|
25
|
-
id: string;
|
|
26
|
-
data: string;
|
|
27
|
-
};
|
|
24
|
+
session?: import("../../core/CheckoutSession/CheckoutSession").default;
|
|
28
25
|
onChange?: (state: any, element: UIElement<any>) => void;
|
|
29
26
|
onValid?: (state: any, element: UIElement<any>) => void;
|
|
30
27
|
beforeSubmit?: (state: any, element: UIElement<any>, actions: any) => Promise<void>;
|
|
@@ -46,10 +46,7 @@ declare class DropinElement extends UIElement<DropinElementProps> {
|
|
|
46
46
|
onSelect?: (paymentMethod: any) => void;
|
|
47
47
|
showRemovePaymentMethodButton?: boolean;
|
|
48
48
|
onDisableStoredPaymentMethod?: (storedPaymentMethod: any, resolve: any, reject: any) => void;
|
|
49
|
-
session?:
|
|
50
|
-
id: string;
|
|
51
|
-
data: string;
|
|
52
|
-
};
|
|
49
|
+
session?: import("../../core/CheckoutSession/CheckoutSession").default;
|
|
53
50
|
onChange?: (state: any, element: UIElement<any>) => void;
|
|
54
51
|
onValid?: (state: any, element: UIElement<any>) => void;
|
|
55
52
|
beforeSubmit?: (state: any, element: UIElement<any>, actions: any) => Promise<void>;
|
|
@@ -12,6 +12,11 @@ export declare class DropinComponent extends Component<DropinComponentProps, Dro
|
|
|
12
12
|
private handleOnSelectPaymentMethod;
|
|
13
13
|
private handleDisableStoredPaymentMethod;
|
|
14
14
|
closeActivePaymentMethod(): void;
|
|
15
|
+
/**
|
|
16
|
+
* getOnOrderCancel decides which onOrderCancel logic should be used, manual or sessions
|
|
17
|
+
*/
|
|
18
|
+
private getOnOrderCancel;
|
|
19
|
+
private onOrderCancel;
|
|
15
20
|
render(props: any, { elements, instantPaymentElements, status, activePaymentMethod, cachedPaymentMethods }: {
|
|
16
21
|
elements: any;
|
|
17
22
|
instantPaymentElements: any;
|
|
@@ -47,10 +47,13 @@ export interface DropinElementProps extends UIElementProps {
|
|
|
47
47
|
*/
|
|
48
48
|
onDisableStoredPaymentMethod?: (storedPaymentMethod: any, resolve: any, reject: any) => void;
|
|
49
49
|
}
|
|
50
|
+
export interface onOrderCancelData {
|
|
51
|
+
order: Order;
|
|
52
|
+
}
|
|
50
53
|
export interface DropinComponentProps extends DropinElementProps {
|
|
51
54
|
onCreateElements: any;
|
|
52
55
|
onChange: (newState?: object) => void;
|
|
53
|
-
onOrderCancel?: (
|
|
56
|
+
onOrderCancel?: (data: onOrderCancelData) => void;
|
|
54
57
|
}
|
|
55
58
|
interface DropinStatus {
|
|
56
59
|
type: UIElementStatus;
|
|
@@ -1,11 +1,16 @@
|
|
|
1
1
|
import { UIElementProps } from '../../../types';
|
|
2
2
|
export interface MBWayInputData {
|
|
3
3
|
telephoneNumber?: string;
|
|
4
|
+
phoneNumber?: string;
|
|
5
|
+
phonePrefix?: string;
|
|
4
6
|
}
|
|
5
7
|
export interface MBWayInputProps extends UIElementProps {
|
|
6
8
|
data?: MBWayInputData;
|
|
7
9
|
placeholders?: MBWayInputData;
|
|
8
10
|
onChange: (state: any) => void;
|
|
11
|
+
allowedCountries?: string[];
|
|
12
|
+
requiredFields?: string[];
|
|
13
|
+
phoneNumberKey?: string;
|
|
9
14
|
}
|
|
10
15
|
export interface MBWayDataState {
|
|
11
16
|
telephoneNumber?: string;
|
|
@@ -2,5 +2,16 @@ import IssuerListContainer from '../helpers/IssuerListContainer';
|
|
|
2
2
|
declare class OnlineBankingINElement extends IssuerListContainer {
|
|
3
3
|
static type: string;
|
|
4
4
|
formatProps(props: any): any;
|
|
5
|
+
/**
|
|
6
|
+
* Formats the component data output
|
|
7
|
+
*/
|
|
8
|
+
formatData(): {
|
|
9
|
+
browserInfo: import("../../types").BrowserInfo;
|
|
10
|
+
paymentMethod: {
|
|
11
|
+
type: string;
|
|
12
|
+
issuer: string;
|
|
13
|
+
};
|
|
14
|
+
};
|
|
15
|
+
get browserInfo(): import("../../types").BrowserInfo;
|
|
5
16
|
}
|
|
6
17
|
export default OnlineBankingINElement;
|
|
@@ -23,10 +23,7 @@ declare class PixElement extends QRLoaderContainer<PixProps> {
|
|
|
23
23
|
qrCodeImage?: string;
|
|
24
24
|
paymentData?: string;
|
|
25
25
|
instructions?: string;
|
|
26
|
-
session?:
|
|
27
|
-
id: string;
|
|
28
|
-
data: string;
|
|
29
|
-
};
|
|
26
|
+
session?: import("../../core/CheckoutSession/CheckoutSession").default;
|
|
30
27
|
onChange?: (state: any, element: import("../UIElement").UIElement<any>) => void;
|
|
31
28
|
onValid?: (state: any, element: import("../UIElement").UIElement<any>) => void;
|
|
32
29
|
beforeSubmit?: (state: any, element: import("../UIElement").UIElement<any>, actions: any) => Promise<void>;
|
|
@@ -11,10 +11,7 @@ declare class SwishElement extends QRLoaderContainer {
|
|
|
11
11
|
qrCodeImage?: string;
|
|
12
12
|
paymentData?: string;
|
|
13
13
|
instructions: string;
|
|
14
|
-
session?:
|
|
15
|
-
id: string;
|
|
16
|
-
data: string;
|
|
17
|
-
};
|
|
14
|
+
session?: import("../../core/CheckoutSession/CheckoutSession").default;
|
|
18
15
|
onChange?: (state: any, element: import("../UIElement").UIElement<any>) => void;
|
|
19
16
|
onValid?: (state: any, element: import("../UIElement").UIElement<any>) => void;
|
|
20
17
|
beforeSubmit?: (state: any, element: import("../UIElement").UIElement<any>, actions: any) => Promise<void>;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import IssuerListContainer from '../helpers/IssuerListContainer';
|
|
2
|
+
declare class WalletINElement extends IssuerListContainer {
|
|
3
|
+
static type: string;
|
|
4
|
+
formatProps(props: any): any;
|
|
5
|
+
/**
|
|
6
|
+
* Formats the component data output
|
|
7
|
+
*/
|
|
8
|
+
formatData(): {
|
|
9
|
+
browserInfo: import("../../types").BrowserInfo;
|
|
10
|
+
paymentMethod: {
|
|
11
|
+
type: string;
|
|
12
|
+
issuer: string;
|
|
13
|
+
};
|
|
14
|
+
};
|
|
15
|
+
get browserInfo(): import("../../types").BrowserInfo;
|
|
16
|
+
}
|
|
17
|
+
export default WalletINElement;
|
|
@@ -11,10 +11,7 @@ declare class WeChatPayElement extends QRLoaderContainer {
|
|
|
11
11
|
qrCodeImage?: string;
|
|
12
12
|
paymentData?: string;
|
|
13
13
|
instructions?: string;
|
|
14
|
-
session?:
|
|
15
|
-
id: string;
|
|
16
|
-
data: string;
|
|
17
|
-
};
|
|
14
|
+
session?: import("../../core/CheckoutSession/CheckoutSession").default;
|
|
18
15
|
onChange?: (state: any, element: import("../UIElement").UIElement<any>) => void;
|
|
19
16
|
onValid?: (state: any, element: import("../UIElement").UIElement<any>) => void;
|
|
20
17
|
beforeSubmit?: (state: any, element: import("../UIElement").UIElement<any>, actions: any) => Promise<void>;
|
|
@@ -49,6 +49,7 @@ import Twint from './Twint';
|
|
|
49
49
|
import MealVoucherFR from './MealVoucherFR';
|
|
50
50
|
import OnlineBankingINElement from './OnlineBankingIN';
|
|
51
51
|
import RatePayDirectDebit from "./RatePay/RatePayDirectDebit";
|
|
52
|
+
import WalletINElement from './WalletIN';
|
|
52
53
|
/**
|
|
53
54
|
* Maps each component with a Component element.
|
|
54
55
|
*/
|
|
@@ -144,6 +145,7 @@ declare const componentsMap: {
|
|
|
144
145
|
threeDS2Challenge: typeof ThreeDS2Challenge;
|
|
145
146
|
threeDS2DeviceFingerprint: typeof ThreeDS2DeviceFingerprint;
|
|
146
147
|
visa: typeof Card;
|
|
148
|
+
wallet_IN: typeof WalletINElement;
|
|
147
149
|
wechatpay: typeof WeChat;
|
|
148
150
|
wechatpayQR: typeof WeChat;
|
|
149
151
|
oxxo: typeof Oxxo;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { AddressSchema, StringObject } from './types';
|
|
2
|
+
import { AddressField } from '../../../types';
|
|
2
3
|
declare class Specifications {
|
|
3
4
|
private specifications;
|
|
4
5
|
constructor(specifications?: any);
|
|
@@ -45,5 +46,13 @@ declare class Specifications {
|
|
|
45
46
|
* @param country - The selected country
|
|
46
47
|
*/
|
|
47
48
|
getPlaceholderKeyForField(fieldName: string, country: string): string;
|
|
49
|
+
/**
|
|
50
|
+
* Returns an array with the address schema of the selected country or the default address schema
|
|
51
|
+
* Flat version of getAddressSchemaForCountry
|
|
52
|
+
* @param country - The selected country
|
|
53
|
+
* @param mode - Address schema mode, can be 'full', 'partial' or 'none'
|
|
54
|
+
* @returns Array
|
|
55
|
+
*/
|
|
56
|
+
getAddressSchemaForCountryFlat(country: string): AddressField[];
|
|
48
57
|
}
|
|
49
58
|
export default Specifications;
|
|
@@ -3,3 +3,12 @@ export declare const FALLBACK_VALUE = "N/A";
|
|
|
3
3
|
export declare const ADDRESS_SCHEMA: readonly ["street", "houseNumberOrName", "postalCode", "city", "stateOrProvince", "country"];
|
|
4
4
|
export declare const STREET: "street", HOUSE_NUMBER_OR_NAME: "houseNumberOrName", POSTAL_CODE: "postalCode", CITY: "city", STATE_OR_PROVINCE: "stateOrProvince", COUNTRY: "country";
|
|
5
5
|
export declare const ADDRESS_SPECIFICATIONS: AddressSpecifications;
|
|
6
|
+
export declare const PARTIAL_ADDRESS_SCHEMA: {
|
|
7
|
+
default: {
|
|
8
|
+
labels: {
|
|
9
|
+
postalCode: string;
|
|
10
|
+
};
|
|
11
|
+
schema: "postalCode"[];
|
|
12
|
+
};
|
|
13
|
+
};
|
|
14
|
+
export declare const COUNTRIES_WITH_CUSTOM_SPECIFICATION: string[];
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { AddressField, AddressData } from '../../../types';
|
|
2
2
|
import Specifications from './Specifications';
|
|
3
3
|
import { ValidatorRules } from '../../../utils/Validator/types';
|
|
4
|
-
import { ValidationRuleResult } from '../../../utils/Validator/
|
|
4
|
+
import { ValidationRuleResult } from '../../../utils/Validator/ValidationRuleResult';
|
|
5
5
|
export declare type StringObject = {
|
|
6
6
|
[key: string]: string;
|
|
7
7
|
};
|
|
@@ -16,6 +16,8 @@ export interface AddressProps {
|
|
|
16
16
|
specifications?: AddressSpecifications;
|
|
17
17
|
validationRules?: ValidatorRules;
|
|
18
18
|
visibility?: string;
|
|
19
|
+
overrideSchema?: AddressSpecifications;
|
|
20
|
+
iOSFocusedField?: string;
|
|
19
21
|
}
|
|
20
22
|
export interface AddressStateError {
|
|
21
23
|
street?: ValidationRuleResult;
|
|
@@ -40,6 +42,7 @@ export interface FieldContainerProps {
|
|
|
40
42
|
specifications: Specifications;
|
|
41
43
|
maxlength?: number;
|
|
42
44
|
trimOnBlur?: boolean;
|
|
45
|
+
disabled?: boolean;
|
|
43
46
|
}
|
|
44
47
|
export interface ReadOnlyAddressProps {
|
|
45
48
|
data: AddressData;
|
|
@@ -17,7 +17,6 @@ declare class Iframe extends Component<IframeProps> {
|
|
|
17
17
|
height: string;
|
|
18
18
|
minWidth: string;
|
|
19
19
|
minHeight: string;
|
|
20
|
-
border: string;
|
|
21
20
|
src: any;
|
|
22
21
|
allow: any;
|
|
23
22
|
title: string;
|
|
@@ -26,14 +25,13 @@ declare class Iframe extends Component<IframeProps> {
|
|
|
26
25
|
iframeOnLoad(): void;
|
|
27
26
|
componentDidMount(): void;
|
|
28
27
|
componentWillUnmount(): void;
|
|
29
|
-
render({ name, src, width, height, minWidth, minHeight,
|
|
28
|
+
render({ name, src, width, height, minWidth, minHeight, allow, title }: {
|
|
30
29
|
name: any;
|
|
31
30
|
src: any;
|
|
32
31
|
width: any;
|
|
33
32
|
height: any;
|
|
34
33
|
minWidth: any;
|
|
35
34
|
minHeight: any;
|
|
36
|
-
border: any;
|
|
37
35
|
allow: any;
|
|
38
36
|
title: any;
|
|
39
37
|
}): h.JSX.Element;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { h } from 'preact';
|
|
2
|
+
import './PhoneInput.scss';
|
|
3
|
+
import { PhoneInputProps } from './types';
|
|
4
|
+
declare function PhoneInput(props: PhoneInputProps): h.JSX.Element;
|
|
5
|
+
declare namespace PhoneInput {
|
|
6
|
+
var defaultProps: {
|
|
7
|
+
phoneLabel: string;
|
|
8
|
+
};
|
|
9
|
+
}
|
|
10
|
+
export default PhoneInput;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './PhoneInput';
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { DataSet, DataSetItem } from '../../../core/Services/data-set';
|
|
2
|
+
export interface PhoneInputSchema {
|
|
3
|
+
phoneNumber?: string;
|
|
4
|
+
phonePrefix?: string;
|
|
5
|
+
}
|
|
6
|
+
export interface PhoneInputProps {
|
|
7
|
+
items: DataSet;
|
|
8
|
+
requiredFields?: string[];
|
|
9
|
+
data: {
|
|
10
|
+
phonePrefix?: string;
|
|
11
|
+
phoneNumber?: string;
|
|
12
|
+
};
|
|
13
|
+
onChange: (obj: any) => void;
|
|
14
|
+
phoneNumberKey?: string;
|
|
15
|
+
phonePrefixErrorKey?: string;
|
|
16
|
+
phoneNumberErrorKey?: string;
|
|
17
|
+
placeholders?: {
|
|
18
|
+
phoneNumber?: string;
|
|
19
|
+
};
|
|
20
|
+
ref?: any;
|
|
21
|
+
}
|
|
22
|
+
export interface PhonePrefixes {
|
|
23
|
+
phonePrefixes: DataSetItem[];
|
|
24
|
+
loadingStatus: string;
|
|
25
|
+
}
|
|
@@ -22,6 +22,7 @@ declare class SecuredFieldsProvider extends Component<SFPProps, SFPState> {
|
|
|
22
22
|
private handleOnError;
|
|
23
23
|
private handleOnAutoComplete;
|
|
24
24
|
private handleOnNoDataRequired;
|
|
25
|
+
private handleOnTouchstartIOS;
|
|
25
26
|
state: SFPState;
|
|
26
27
|
props: any;
|
|
27
28
|
private issuingCountryCode;
|
|
@@ -46,6 +47,7 @@ declare class SecuredFieldsProvider extends Component<SFPProps, SFPState> {
|
|
|
46
47
|
onBinValue: () => void;
|
|
47
48
|
onFocus: () => void;
|
|
48
49
|
onAutoComplete: () => void;
|
|
50
|
+
onTouchstartIOS: () => any;
|
|
49
51
|
styles: {};
|
|
50
52
|
};
|
|
51
53
|
componentDidMount(): void;
|
|
@@ -28,6 +28,7 @@ declare function handleOnBrand(cardInfo: CbObjOnBrand): void;
|
|
|
28
28
|
*/
|
|
29
29
|
declare function handleOnError(cbObj: CbObjOnError, hasUnsupportedCard?: boolean): boolean;
|
|
30
30
|
declare function handleFocus(cbObj: CbObjOnFocus): void;
|
|
31
|
+
declare function handleOnTouchstartIOS(cbObj: any): void;
|
|
31
32
|
declare function handleOnAutoComplete(cbObj: CbObjOnAutoComplete): void;
|
|
32
33
|
/**
|
|
33
34
|
* Handles cases where no secured fields are necessary (one click payments without CVC)
|
|
@@ -44,5 +45,6 @@ declare const _default: {
|
|
|
44
45
|
handleOnBrand: typeof handleOnBrand;
|
|
45
46
|
handleOnError: typeof handleOnError;
|
|
46
47
|
handleOnNoDataRequired: typeof handleOnNoDataRequired;
|
|
48
|
+
handleOnTouchstartIOS: typeof handleOnTouchstartIOS;
|
|
47
49
|
};
|
|
48
50
|
export default _default;
|
|
@@ -16,8 +16,9 @@ declare abstract class AbstractCSF {
|
|
|
16
16
|
protected createNonCardSecuredFields: (securedFields: HTMLElement[]) => number;
|
|
17
17
|
protected createSecuredFields: typeof createSecuredFields;
|
|
18
18
|
protected destroySecuredFields: () => void;
|
|
19
|
+
protected handleIOSTouchEvents: () => void;
|
|
19
20
|
protected destroyTouchendListener: () => void;
|
|
20
|
-
protected
|
|
21
|
+
protected destroyTouchstartListener: () => void;
|
|
21
22
|
protected handleBinValue: (pFeedbackObj: SFFeedbackObj) => void;
|
|
22
23
|
protected handleEncryption: (pFeedbackObj: SFFeedbackObj) => void;
|
|
23
24
|
protected handleFocus: (pFeedbackObj: SFFeedbackObj) => void;
|
|
@@ -34,6 +35,7 @@ declare abstract class AbstractCSF {
|
|
|
34
35
|
protected setFocusOnFrame: (pFieldType: string, doLog?: boolean) => void;
|
|
35
36
|
protected setupSecuredField: (pItem: HTMLElement) => void;
|
|
36
37
|
protected touchendListener: (e: Event) => void;
|
|
38
|
+
protected touchstartListener: () => void;
|
|
37
39
|
protected encryptedAttrName: string;
|
|
38
40
|
protected hasRedundantCVCField: boolean;
|
|
39
41
|
protected isSingleBrandedCard: boolean;
|
package/dist/types/components/internal/SecuredFields/lib/CSF/extensions/handleIOSTouchEvents.d.ts
ADDED
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Detect if touched element is an input or textArea.
|
|
3
|
+
* - If it is do some quirky shit to set focus and caret position on this element
|
|
4
|
+
* - Else do some quirky shit to make the iOS keyboard retract
|
|
5
|
+
*
|
|
6
|
+
* Always then remove this listener and set var saying we have done so (read in CSF...handleFocus)
|
|
7
|
+
* Tell all securedFields some other element now has focus so they can blur themselves
|
|
8
|
+
*
|
|
9
|
+
* @param e -
|
|
10
|
+
*/
|
|
11
|
+
declare function touchendListener(e: Event): void;
|
|
12
|
+
/**
|
|
13
|
+
* re. Disabling arrow keys in iOS - need to enable all fields in the form and tell SFs to disable
|
|
14
|
+
*
|
|
15
|
+
* NOTE: Only called when iOS detected
|
|
16
|
+
*/
|
|
17
|
+
declare function touchstartListener(e: Event): void;
|
|
18
|
+
/**
|
|
19
|
+
* This works with the touchend handler to allow us to catch (click) events on non-securedFields elements
|
|
20
|
+
* (re. http://gravitydept.com/blog/js-click-event-bubbling-on-ios - events don't bubble unless the click takes place on a link or input)
|
|
21
|
+
*
|
|
22
|
+
* We can use this event to:
|
|
23
|
+
* 1. Set focus on these other elements, and
|
|
24
|
+
* 2. Tell SecuredFields that this has happened so they can blur themselves
|
|
25
|
+
* (see note in adyen-secured-fields...inputBase.js - "Blur event never fires on input field")
|
|
26
|
+
*
|
|
27
|
+
* NOTE: Only called when iOS detected
|
|
28
|
+
*/
|
|
29
|
+
declare function handleTouchend(): void;
|
|
30
|
+
declare function destroyTouchendListener(): void;
|
|
31
|
+
declare function destroyTouchstartListener(): void;
|
|
32
|
+
declare const _default: {
|
|
33
|
+
touchendListener: typeof touchendListener;
|
|
34
|
+
touchstartListener: typeof touchstartListener;
|
|
35
|
+
handleTouchend: typeof handleTouchend;
|
|
36
|
+
destroyTouchendListener: typeof destroyTouchendListener;
|
|
37
|
+
destroyTouchstartListener: typeof destroyTouchstartListener;
|
|
38
|
+
};
|
|
39
|
+
export default _default;
|
|
@@ -65,6 +65,7 @@ export interface CSFCallbacksConfig {
|
|
|
65
65
|
onAutoComplete?: (callbackObj: object) => void;
|
|
66
66
|
onAdditionalSFConfig?: (callbackObj: object) => void;
|
|
67
67
|
onAdditionalSFRemoved?: (callbackObj: object) => void;
|
|
68
|
+
onTouchstartIOS?: (callbackObj: object) => void;
|
|
68
69
|
}
|
|
69
70
|
export interface CSFStateObject {
|
|
70
71
|
type: string;
|
|
@@ -11,7 +11,7 @@ export declare const ENCRYPTED_BANK_LOCATION_FIELD = "encryptedBankLocationId";
|
|
|
11
11
|
export declare const ENCRYPTED_SECURITY_CODE_3_DIGITS = "encryptedSecurityCode3digits";
|
|
12
12
|
export declare const ENCRYPTED_SECURITY_CODE_4_DIGITS = "encryptedSecurityCode4digits";
|
|
13
13
|
export declare const GIFT_CARD = "giftcard";
|
|
14
|
-
export declare const SF_VERSION = "3.
|
|
14
|
+
export declare const SF_VERSION = "3.10.2";
|
|
15
15
|
export declare const DEFAULT_CARD_GROUP_TYPES: string[];
|
|
16
16
|
export declare const NON_CREDIT_CARD_TYPE_SECURED_FIELDS: string[];
|
|
17
17
|
export declare const CREDIT_CARD_SF_FIELDS: string[];
|
package/dist/types/components/internal/SecuredFields/lib/securedField/AbstractSecuredField.d.ts
CHANGED
|
@@ -86,7 +86,7 @@ declare abstract class AbstractSecuredField {
|
|
|
86
86
|
protected onValidationCallback: RtnType_callbackFn;
|
|
87
87
|
protected onFocusCallback: RtnType_callbackFn;
|
|
88
88
|
protected onBinValueCallback: RtnType_callbackFn;
|
|
89
|
-
protected
|
|
89
|
+
protected onTouchstartCallback: RtnType_callbackFn;
|
|
90
90
|
protected onShiftTabCallback: RtnType_callbackFn;
|
|
91
91
|
protected onAutoCompleteCallback: RtnType_callbackFn;
|
|
92
92
|
protected constructor();
|
|
@@ -17,7 +17,7 @@ declare class SecuredField extends AbstractSecuredField {
|
|
|
17
17
|
onConfig(callbackFn: RtnType_callbackFn): SecuredField;
|
|
18
18
|
onFocus(callbackFn: RtnType_callbackFn): SecuredField;
|
|
19
19
|
onBinValue(callbackFn: RtnType_callbackFn): SecuredField;
|
|
20
|
-
|
|
20
|
+
onTouchstart(callbackFn: RtnType_callbackFn): SecuredField;
|
|
21
21
|
onShiftTab(callbackFn: RtnType_callbackFn): SecuredField;
|
|
22
22
|
onAutoComplete(callbackFn: RtnType_callbackFn): SecuredField;
|
|
23
23
|
get errorType(): string;
|