@adyen/adyen-web 5.40.1 → 5.42.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/adyen.js +1 -1
- package/dist/adyen.js.map +1 -1
- package/dist/cjs/index.js +1 -1
- package/dist/es/index.js +1 -1
- package/dist/es.modern/index.js +1 -1
- package/dist/types/components/Ach/Ach.d.ts +4 -3
- package/dist/types/components/Ach/components/AchInput/types.d.ts +2 -0
- package/dist/types/components/AmazonPay/types.d.ts +3 -2
- package/dist/types/components/BaseElement.d.ts +2 -0
- package/dist/types/components/BcmcMobile/BcmcMobile.d.ts +4 -3
- package/dist/types/components/Card/Bancontact.d.ts +4 -3
- package/dist/types/components/Card/Card.d.ts +8 -4
- package/dist/types/components/Card/components/CardInput/types.d.ts +3 -0
- package/dist/types/components/Card/components/CardInput/utils.d.ts +0 -1
- package/dist/types/components/Dragonpay/Dragonpay.d.ts +4 -3
- package/dist/types/components/Dropin/Dropin.d.ts +7 -7
- package/dist/types/components/DuitNow/DuitNow.d.ts +4 -3
- package/dist/types/components/PayNow/PayNow.d.ts +4 -3
- package/dist/types/components/PayPal/types.d.ts +3 -2
- package/dist/types/components/PromptPay/PromptPay.d.ts +4 -3
- package/dist/types/components/SecuredFields/SecuredFieldsInput/SecuredFieldsInput.d.ts +2 -0
- package/dist/types/components/Swish/Swish.d.ts +4 -3
- package/dist/types/components/WeChat/WeChat.d.ts +4 -3
- package/dist/types/components/internal/SecuredFields/SFP/types.d.ts +2 -0
- package/dist/types/components/internal/SecuredFields/utils.d.ts +2 -1
- package/dist/types/components/types.d.ts +5 -3
- package/dist/types/core/Context/CoreContext.d.ts +2 -0
- package/dist/types/core/Context/CoreProvider.d.ts +2 -0
- package/dist/types/core/Context/Resources.d.ts +6 -0
- package/dist/types/core/Context/useCoreContext.d.ts +1 -0
- package/dist/types/core/Context/useImage.d.ts +3 -0
- package/dist/types/core/Environment/Environment.d.ts +3 -2
- package/dist/types/core/Environment/index.d.ts +1 -1
- package/dist/types/core/types.d.ts +1 -0
- package/dist/types/types/index.d.ts +3 -3
- package/dist/types/utils/arrayUtils.d.ts +1 -0
- package/dist/types/utils/hookUtils.d.ts +1 -0
- package/dist/types/utils/regex.d.ts +5 -1
- package/package.json +1 -1
|
@@ -37,9 +37,10 @@ export declare class AchElement extends UIElement<AchElementProps> {
|
|
|
37
37
|
_parentInstance?: import("../../core/core").default;
|
|
38
38
|
order?: import("../../types").Order;
|
|
39
39
|
modules?: {
|
|
40
|
-
srPanel
|
|
41
|
-
analytics
|
|
42
|
-
|
|
40
|
+
srPanel?: import("../../core/Errors/SRPanel").SRPanel;
|
|
41
|
+
analytics?: import("../../core/Analytics/Analytics").default;
|
|
42
|
+
resources?: import("../../core/Context/Resources").Resources;
|
|
43
|
+
risk?: import("../../core/RiskModule").default;
|
|
43
44
|
};
|
|
44
45
|
isDropin?: boolean;
|
|
45
46
|
};
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import Language from '../../../../language/Language';
|
|
2
2
|
import { StylesObject } from '../../../internal/SecuredFields/lib/types';
|
|
3
3
|
import UIElement from '../../../UIElement';
|
|
4
|
+
import { Resources } from '../../../../core/Context/Resources';
|
|
4
5
|
export interface ACHInputStateValid {
|
|
5
6
|
holderName?: boolean;
|
|
6
7
|
billingAddress?: boolean;
|
|
@@ -48,6 +49,7 @@ export interface ACHInputProps {
|
|
|
48
49
|
payButton?: (obj: any) => {};
|
|
49
50
|
placeholders?: Placeholders;
|
|
50
51
|
ref?: any;
|
|
52
|
+
resources: Resources;
|
|
51
53
|
showPayButton?: boolean;
|
|
52
54
|
showWarnings?: boolean;
|
|
53
55
|
styles?: StylesObject;
|
|
@@ -2,6 +2,7 @@ import Language from '../../language/Language';
|
|
|
2
2
|
import { SUPPORTED_LOCALES_EU, SUPPORTED_LOCALES_US } from './config';
|
|
3
3
|
import { BrowserInfo, PaymentAmount } from '../../types';
|
|
4
4
|
import UIElement from '../UIElement';
|
|
5
|
+
import { UIElementProps } from '../types';
|
|
5
6
|
declare global {
|
|
6
7
|
interface Window {
|
|
7
8
|
amazon: object;
|
|
@@ -14,7 +15,7 @@ type ChargePermissionType = 'OneTime' | 'Recurring';
|
|
|
14
15
|
type FrequencyUnit = 'Year' | 'Month' | 'Week' | 'Day' | 'Variable';
|
|
15
16
|
export type Currency = 'EUR' | 'GBP' | 'USD';
|
|
16
17
|
export type Region = 'EU' | 'UK' | 'US';
|
|
17
|
-
export type SupportedLocale = typeof SUPPORTED_LOCALES_EU[number] | typeof SUPPORTED_LOCALES_US[number];
|
|
18
|
+
export type SupportedLocale = (typeof SUPPORTED_LOCALES_EU)[number] | (typeof SUPPORTED_LOCALES_US)[number];
|
|
18
19
|
export interface RecurringMetadata {
|
|
19
20
|
frequency: {
|
|
20
21
|
unit: string;
|
|
@@ -31,7 +32,7 @@ export interface AmazonPayConfiguration {
|
|
|
31
32
|
region?: Region;
|
|
32
33
|
storeId?: string;
|
|
33
34
|
}
|
|
34
|
-
export interface AmazonPayElementProps {
|
|
35
|
+
export interface AmazonPayElementProps extends UIElementProps {
|
|
35
36
|
addressDetails?: AddressDetails;
|
|
36
37
|
amazonPayToken?: string;
|
|
37
38
|
amazonCheckoutSessionId?: string;
|
|
@@ -3,6 +3,7 @@ import EventEmitter from './EventEmitter';
|
|
|
3
3
|
import Core from '../core';
|
|
4
4
|
import { BaseElementProps, PaymentData } from './types';
|
|
5
5
|
import { RiskData } from '../core/RiskModule/RiskModule';
|
|
6
|
+
import { Resources } from '../core/Context/Resources';
|
|
6
7
|
declare class BaseElement<P extends BaseElementProps> {
|
|
7
8
|
readonly _id: string;
|
|
8
9
|
props: P;
|
|
@@ -12,6 +13,7 @@ declare class BaseElement<P extends BaseElementProps> {
|
|
|
12
13
|
_component: any;
|
|
13
14
|
eventEmitter: EventEmitter;
|
|
14
15
|
protected readonly _parentInstance: Core;
|
|
16
|
+
protected resources: Resources;
|
|
15
17
|
protected constructor(props: P);
|
|
16
18
|
/**
|
|
17
19
|
* Executed during creation of any payment element.
|
|
@@ -39,9 +39,10 @@ declare class BCMCMobileElement extends QRLoaderContainer {
|
|
|
39
39
|
_parentInstance?: import("../../core/core").default;
|
|
40
40
|
order?: import("../../types").Order;
|
|
41
41
|
modules?: {
|
|
42
|
-
srPanel
|
|
43
|
-
analytics
|
|
44
|
-
|
|
42
|
+
srPanel?: import("../../core/Errors/SRPanel").SRPanel;
|
|
43
|
+
analytics?: import("../../core/Analytics/Analytics").default;
|
|
44
|
+
resources?: import("../../core/Context/Resources").Resources;
|
|
45
|
+
risk?: import("../../core/RiskModule").default;
|
|
45
46
|
};
|
|
46
47
|
isDropin?: boolean;
|
|
47
48
|
};
|
|
@@ -91,9 +91,10 @@ declare class BancontactElement extends CardElement {
|
|
|
91
91
|
_parentInstance?: import("../../core/core").default;
|
|
92
92
|
order?: import("../../types").Order;
|
|
93
93
|
modules?: {
|
|
94
|
-
srPanel
|
|
95
|
-
analytics
|
|
96
|
-
|
|
94
|
+
srPanel?: import("../../core/Errors/SRPanel").SRPanel;
|
|
95
|
+
analytics?: import("../../core/Analytics/Analytics").default;
|
|
96
|
+
resources?: import("../../core/Context/Resources").Resources;
|
|
97
|
+
risk?: import("../../core/RiskModule").default;
|
|
97
98
|
};
|
|
98
99
|
isDropin?: boolean;
|
|
99
100
|
};
|
|
@@ -88,7 +88,10 @@ export declare class CardElement extends UIElement<CardElementProps> {
|
|
|
88
88
|
amount?: import("../../types").PaymentAmount;
|
|
89
89
|
secondaryAmount?: import("../../types").PaymentAmountExtended;
|
|
90
90
|
showPayButton?: boolean;
|
|
91
|
-
setStatusAutomatically?: boolean;
|
|
91
|
+
setStatusAutomatically?: boolean; /**
|
|
92
|
+
* Click to Pay configuration
|
|
93
|
+
* - If email is set explicitly in the configuration, then it can override the one used in the session creation
|
|
94
|
+
*/
|
|
92
95
|
payButton?: (options: import("../types").PayButtonFunctionProps) => h.JSX.Element;
|
|
93
96
|
loadingContext?: string;
|
|
94
97
|
createFromAction?: (action: import("../../types").PaymentAction, props: object) => UIElement<any>;
|
|
@@ -98,9 +101,10 @@ export declare class CardElement extends UIElement<CardElementProps> {
|
|
|
98
101
|
_parentInstance?: import("../../core/core").default;
|
|
99
102
|
order?: import("../../types").Order;
|
|
100
103
|
modules?: {
|
|
101
|
-
srPanel
|
|
102
|
-
analytics
|
|
103
|
-
|
|
104
|
+
srPanel?: import("../../core/Errors/SRPanel").SRPanel;
|
|
105
|
+
analytics?: import("../../core/Analytics/Analytics").default;
|
|
106
|
+
resources?: import("../../core/Context/Resources").Resources;
|
|
107
|
+
risk?: import("../../core/RiskModule").default;
|
|
104
108
|
};
|
|
105
109
|
isDropin?: boolean;
|
|
106
110
|
};
|
|
@@ -7,6 +7,7 @@ import { CVCPolicyType, DatePolicyType } from '../../../internal/SecuredFields/l
|
|
|
7
7
|
import Specifications from '../../../internal/Address/Specifications';
|
|
8
8
|
import { AddressSchema } from '../../../internal/Address/types';
|
|
9
9
|
import { CbObjOnError, StylesObject } from '../../../internal/SecuredFields/lib/types';
|
|
10
|
+
import { Resources } from '../../../../core/Context/Resources';
|
|
10
11
|
import { SRPanel } from '../../../../core/Errors/SRPanel';
|
|
11
12
|
import Analytics from '../../../../core/Analytics';
|
|
12
13
|
import RiskElement from '../../../../core/RiskModule';
|
|
@@ -85,6 +86,7 @@ export interface CardInputProps {
|
|
|
85
86
|
srPanel: SRPanel;
|
|
86
87
|
analytics: Analytics;
|
|
87
88
|
risk: RiskElement;
|
|
89
|
+
resources: Resources;
|
|
88
90
|
};
|
|
89
91
|
onAdditionalSFConfig?: () => {};
|
|
90
92
|
onAdditionalSFRemoved?: () => {};
|
|
@@ -102,6 +104,7 @@ export interface CardInputProps {
|
|
|
102
104
|
payButton?: (obj: any) => {};
|
|
103
105
|
placeholders?: Placeholders;
|
|
104
106
|
positionHolderNameOnTop?: boolean;
|
|
107
|
+
resources: Resources;
|
|
105
108
|
setComponentRef?: (ref: any) => void;
|
|
106
109
|
showBrandsUnderCardNumber: boolean;
|
|
107
110
|
showBrandIcon?: boolean;
|
|
@@ -39,4 +39,3 @@ export declare const extractPropsForCardFields: (props: CardInputProps) => {
|
|
|
39
39
|
export declare const extractPropsForSFP: (props: CardInputProps) => SFPProps;
|
|
40
40
|
export declare const handlePartialAddressMode: (addressMode: AddressModeOptions) => AddressSpecifications | null;
|
|
41
41
|
export declare function lookupBlurBasedErrors(errorCode: any): boolean;
|
|
42
|
-
export declare function usePrevious<T>(value: T): T;
|
|
@@ -46,9 +46,10 @@ export declare class DragonpayElement extends UIElement<DragonpayElementProps> {
|
|
|
46
46
|
_parentInstance?: import("../../core/core").default;
|
|
47
47
|
order?: import("../../types").Order;
|
|
48
48
|
modules?: {
|
|
49
|
-
srPanel
|
|
50
|
-
analytics
|
|
51
|
-
|
|
49
|
+
srPanel?: import("../../core/Errors/SRPanel").SRPanel;
|
|
50
|
+
analytics?: import("../../core/Analytics/Analytics").default;
|
|
51
|
+
resources?: import("../../core/Context/Resources").Resources;
|
|
52
|
+
risk?: import("../../core/RiskModule").default;
|
|
52
53
|
};
|
|
53
54
|
isDropin?: boolean;
|
|
54
55
|
};
|
|
@@ -52,12 +52,11 @@ declare class DropinElement extends UIElement<DropinElementProps> {
|
|
|
52
52
|
onValid?: (state: any, element: UIElement<any>) => void;
|
|
53
53
|
beforeSubmit?: (state: any, element: UIElement<any>, actions: any) => Promise<void>;
|
|
54
54
|
onComplete?: (state: any, element: UIElement<any>) => void;
|
|
55
|
-
/**
|
|
56
|
-
* Calls the onSubmit event with the state of the activePaymentMethod
|
|
57
|
-
*/
|
|
58
55
|
onActionHandled?: (rtnObj: import("../types").ActionHandledReturnObject) => void;
|
|
59
56
|
onAdditionalDetails?: (state: any, element: UIElement<any>) => void;
|
|
60
|
-
onError?: (error: any, element?: UIElement<any>) => void;
|
|
57
|
+
onError?: (error: any, element?: UIElement<any>) => void; /**
|
|
58
|
+
* Creates the Drop-in elements
|
|
59
|
+
*/
|
|
61
60
|
onPaymentCompleted?: (result: any, element: UIElement<any>) => void;
|
|
62
61
|
beforeRedirect?: (resolve: any, reject: any, redirectData: any, element: UIElement<any>) => void;
|
|
63
62
|
isInstantPayment?: boolean;
|
|
@@ -76,9 +75,10 @@ declare class DropinElement extends UIElement<DropinElementProps> {
|
|
|
76
75
|
i18n?: import("../../language").default;
|
|
77
76
|
_parentInstance?: import("../../core/core").default;
|
|
78
77
|
modules?: {
|
|
79
|
-
srPanel
|
|
80
|
-
analytics
|
|
81
|
-
|
|
78
|
+
srPanel?: import("../../core/Errors/SRPanel").SRPanel;
|
|
79
|
+
analytics?: import("../../core/Analytics/Analytics").default;
|
|
80
|
+
resources?: import("../../core/Context/Resources").Resources;
|
|
81
|
+
risk?: import("../../core/RiskModule").default;
|
|
82
82
|
};
|
|
83
83
|
isDropin?: boolean;
|
|
84
84
|
};
|
|
@@ -39,9 +39,10 @@ declare class DuitNowElement extends QRLoaderContainer {
|
|
|
39
39
|
_parentInstance?: import("../../core/core").default;
|
|
40
40
|
order?: import("../../types").Order;
|
|
41
41
|
modules?: {
|
|
42
|
-
srPanel
|
|
43
|
-
analytics
|
|
44
|
-
|
|
42
|
+
srPanel?: import("../../core/Errors/SRPanel").SRPanel;
|
|
43
|
+
analytics?: import("../../core/Analytics/Analytics").default;
|
|
44
|
+
resources?: import("../../core/Context/Resources").Resources;
|
|
45
|
+
risk?: import("../../core/RiskModule").default;
|
|
45
46
|
};
|
|
46
47
|
isDropin?: boolean;
|
|
47
48
|
};
|
|
@@ -39,9 +39,10 @@ declare class PayNowElement extends QRLoaderContainer {
|
|
|
39
39
|
_parentInstance?: import("../../core/core").default;
|
|
40
40
|
order?: import("../../types").Order;
|
|
41
41
|
modules?: {
|
|
42
|
-
srPanel
|
|
43
|
-
analytics
|
|
44
|
-
|
|
42
|
+
srPanel?: import("../../core/Errors/SRPanel").SRPanel;
|
|
43
|
+
analytics?: import("../../core/Analytics/Analytics").default;
|
|
44
|
+
resources?: import("../../core/Context/Resources").Resources;
|
|
45
|
+
risk?: import("../../core/RiskModule").default;
|
|
45
46
|
};
|
|
46
47
|
isDropin?: boolean;
|
|
47
48
|
};
|
|
@@ -12,7 +12,7 @@ declare global {
|
|
|
12
12
|
* @see {@link https://developer.paypal.com/docs/checkout/reference/customize-sdk/#intent}
|
|
13
13
|
*/
|
|
14
14
|
export type Intent = 'sale' | 'capture' | 'authorize' | 'order' | 'tokenize';
|
|
15
|
-
export type FundingSource = 'paypal' | 'credit';
|
|
15
|
+
export type FundingSource = 'paypal' | 'credit' | 'paylater' | 'venmo';
|
|
16
16
|
export interface PayPalStyles {
|
|
17
17
|
/**
|
|
18
18
|
* @see {@link https://developer.paypal.com/docs/checkout/integration-features/customize-button/#color}
|
|
@@ -64,9 +64,10 @@ interface PayPalCommonProps {
|
|
|
64
64
|
*/
|
|
65
65
|
blockPayPalPayLaterButton?: boolean;
|
|
66
66
|
/**
|
|
67
|
-
* Set to true to force the UI to
|
|
67
|
+
* Set to true to force the UI to not render PayPal Venmo button
|
|
68
68
|
* @defaultValue false
|
|
69
69
|
*/
|
|
70
|
+
blockPayPalVenmoButton?: boolean;
|
|
70
71
|
enableMessages?: boolean;
|
|
71
72
|
/**
|
|
72
73
|
* @see {@link https://developer.paypal.com/docs/business/javascript-sdk/javascript-sdk-configuration/#csp-nonce}
|
|
@@ -39,9 +39,10 @@ declare class PromptPayElement extends QRLoaderContainer {
|
|
|
39
39
|
_parentInstance?: import("../../core/core").default;
|
|
40
40
|
order?: import("../../types").Order;
|
|
41
41
|
modules?: {
|
|
42
|
-
srPanel
|
|
43
|
-
analytics
|
|
44
|
-
|
|
42
|
+
srPanel?: import("../../core/Errors/SRPanel").SRPanel;
|
|
43
|
+
analytics?: import("../../core/Analytics/Analytics").default;
|
|
44
|
+
resources?: import("../../core/Context/Resources").Resources;
|
|
45
|
+
risk?: import("../../core/RiskModule").default;
|
|
45
46
|
};
|
|
46
47
|
isDropin?: boolean;
|
|
47
48
|
};
|
|
@@ -2,6 +2,7 @@ import { h } from 'preact';
|
|
|
2
2
|
import Language from '../../../language/Language';
|
|
3
3
|
import { CardBrandsConfiguration } from '../../Card/types';
|
|
4
4
|
import { StylesObject } from '../../internal/SecuredFields/lib/types';
|
|
5
|
+
import { Resources } from '../../../core/Context/Resources';
|
|
5
6
|
interface SecuredFieldsProps {
|
|
6
7
|
allowedDOMAccess?: boolean;
|
|
7
8
|
autoFocus?: boolean;
|
|
@@ -28,6 +29,7 @@ interface SecuredFieldsProps {
|
|
|
28
29
|
onFocus?: (e: any) => {};
|
|
29
30
|
onLoad?: () => {};
|
|
30
31
|
rootNode: HTMLElement;
|
|
32
|
+
resources: Resources;
|
|
31
33
|
showWarnings?: boolean;
|
|
32
34
|
styles?: StylesObject;
|
|
33
35
|
trimTrailingSeparator?: boolean;
|
|
@@ -39,9 +39,10 @@ declare class SwishElement extends QRLoaderContainer {
|
|
|
39
39
|
_parentInstance?: import("../../core/core").default;
|
|
40
40
|
order?: import("../../types").Order;
|
|
41
41
|
modules?: {
|
|
42
|
-
srPanel
|
|
43
|
-
analytics
|
|
44
|
-
|
|
42
|
+
srPanel?: import("../../core/Errors/SRPanel").SRPanel;
|
|
43
|
+
analytics?: import("../../core/Analytics/Analytics").default;
|
|
44
|
+
resources?: import("../../core/Context/Resources").Resources;
|
|
45
|
+
risk?: import("../../core/RiskModule").default;
|
|
45
46
|
};
|
|
46
47
|
isDropin?: boolean;
|
|
47
48
|
};
|
|
@@ -39,9 +39,10 @@ declare class WeChatPayElement extends QRLoaderContainer {
|
|
|
39
39
|
_parentInstance?: import("../../core/core").default;
|
|
40
40
|
order?: import("../../types").Order;
|
|
41
41
|
modules?: {
|
|
42
|
-
srPanel
|
|
43
|
-
analytics
|
|
44
|
-
|
|
42
|
+
srPanel?: import("../../core/Errors/SRPanel").SRPanel;
|
|
43
|
+
analytics?: import("../../core/Analytics/Analytics").default;
|
|
44
|
+
resources?: import("../../core/Context/Resources").Resources;
|
|
45
|
+
risk?: import("../../core/RiskModule").default;
|
|
45
46
|
};
|
|
46
47
|
isDropin?: boolean;
|
|
47
48
|
};
|
|
@@ -2,6 +2,7 @@ import { CVCPolicyType, DatePolicyType, StylesObject } from '../lib/types';
|
|
|
2
2
|
import { AddressData } from '../../../../types';
|
|
3
3
|
import { CardBrandsConfiguration } from '../../../Card/types';
|
|
4
4
|
import { Language } from '../../../../language/Language';
|
|
5
|
+
import { Resources } from '../../../../core/Context/Resources';
|
|
5
6
|
import { TouchStartEventObj } from '../../../Card/components/CardInput/components/types';
|
|
6
7
|
/**
|
|
7
8
|
* Should be the only props that can be sent to SFP (from CardInput, SecuredFieldsInput, AchInput, GiftcardComponent)
|
|
@@ -40,6 +41,7 @@ export interface SFPProps {
|
|
|
40
41
|
trimTrailingSeparator?: boolean;
|
|
41
42
|
type: string;
|
|
42
43
|
render: () => {};
|
|
44
|
+
resources: Resources;
|
|
43
45
|
maskSecurityCode: boolean;
|
|
44
46
|
disableIOSArrowKeys: (obj: TouchStartEventObj) => void | null;
|
|
45
47
|
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import Language from '../../../language/Language';
|
|
2
2
|
import { SFPlaceholdersObject } from './lib/securedField/AbstractSecuredField';
|
|
3
|
+
import { Resources } from '../../../core/Context/Resources';
|
|
3
4
|
/**
|
|
4
5
|
* Lookup translated values for the placeholders for the SecuredFields
|
|
5
6
|
* and return an object with these mapped to the data-cse value of the SecuredField
|
|
@@ -8,7 +9,7 @@ export declare const resolvePlaceholders: (i18n?: Language) => SFPlaceholdersObj
|
|
|
8
9
|
/**
|
|
9
10
|
* Used by SecuredFieldsProviderHandlers
|
|
10
11
|
*/
|
|
11
|
-
export declare const getCardImageUrl: (brand: any,
|
|
12
|
+
export declare const getCardImageUrl: (brand: any, resources: Resources) => any;
|
|
12
13
|
/**
|
|
13
14
|
* 'Destructures' properties from object - returns a new object only containing those properties that were asked for (including if those properties
|
|
14
15
|
* have values that are falsy: null, undefined, false, '').
|
|
@@ -6,6 +6,7 @@ import RiskElement from '../core/RiskModule';
|
|
|
6
6
|
import { PayButtonProps } from './internal/PayButton/PayButton';
|
|
7
7
|
import Session from '../core/CheckoutSession';
|
|
8
8
|
import { SRPanel } from '../core/Errors/SRPanel';
|
|
9
|
+
import { Resources } from '../core/Context/Resources';
|
|
9
10
|
export interface PaymentMethodData {
|
|
10
11
|
paymentMethod: {
|
|
11
12
|
[key: string]: any;
|
|
@@ -51,9 +52,10 @@ export interface BaseElementProps {
|
|
|
51
52
|
_parentInstance?: Core;
|
|
52
53
|
order?: Order;
|
|
53
54
|
modules?: {
|
|
54
|
-
srPanel
|
|
55
|
-
analytics
|
|
56
|
-
|
|
55
|
+
srPanel?: SRPanel;
|
|
56
|
+
analytics?: Analytics;
|
|
57
|
+
resources?: Resources;
|
|
58
|
+
risk?: RiskElement;
|
|
57
59
|
};
|
|
58
60
|
isDropin?: boolean;
|
|
59
61
|
}
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import { CommonPropsTypes } from './CoreProvider';
|
|
2
2
|
import Language from '../../language/Language';
|
|
3
|
+
import { Resources } from './Resources';
|
|
3
4
|
export declare const CoreContext: import("preact").Context<{
|
|
4
5
|
i18n: Language;
|
|
5
6
|
loadingContext: string;
|
|
6
7
|
commonProps: CommonPropsTypes;
|
|
8
|
+
resources: Resources;
|
|
7
9
|
}>;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
1
|
export declare const FALLBACK_CONTEXT = "https://checkoutshopper-live.adyen.com/checkoutshopper/";
|
|
2
|
-
declare const resolveEnvironment: (env?: string) => string;
|
|
3
|
-
export
|
|
2
|
+
export declare const resolveEnvironment: (env?: string) => string;
|
|
3
|
+
export declare const FALLBACK_CDN_CONTEXT = "https://checkoutshopper-live.adyen.com/checkoutshopper/";
|
|
4
|
+
export declare const resolveCDNEnvironment: (env?: string) => any;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export {
|
|
1
|
+
export { resolveCDNEnvironment, resolveEnvironment } from './Environment';
|
|
@@ -209,11 +209,11 @@ export interface OrderStatus {
|
|
|
209
209
|
*/
|
|
210
210
|
export interface BrowserInfo {
|
|
211
211
|
acceptHeader: string;
|
|
212
|
-
colorDepth:
|
|
212
|
+
colorDepth: number;
|
|
213
213
|
language: string;
|
|
214
214
|
javaEnabled: boolean;
|
|
215
|
-
screenHeight:
|
|
216
|
-
screenWidth:
|
|
215
|
+
screenHeight: number;
|
|
216
|
+
screenWidth: number;
|
|
217
217
|
userAgent: string;
|
|
218
218
|
timeZoneOffset: number;
|
|
219
219
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function getArrayDifferences<A, S extends string>(currentArray: A[], previousArray: A[], comparisonKey?: S): A[];
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function usePrevious<T>(value: T): T;
|
|
@@ -1,5 +1,9 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Email regex
|
|
2
|
+
* Email regex follows https://en.wikipedia.org/wiki/Email_address.
|
|
3
|
+
* It checks that the email address starts with a local part that includes letters, digits, and some special characters, optionally separated by periods.
|
|
4
|
+
* Alternatively, the local part can be enclosed in quotes and include any characters except a new line.
|
|
5
|
+
* This is followed by an `@` symbol and a domain name or an IP address enclosed in square brackets.
|
|
6
|
+
* The domain name consists of one or more words separated by periods, where each word can include letters, digits, and hyphens. The top-level domain must consist of two or more letters.
|
|
3
7
|
*/
|
|
4
8
|
export declare const email: RegExp;
|
|
5
9
|
/**
|
package/package.json
CHANGED