@monei-js/components 1.3.0 → 1.5.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/api.d.ts +5 -1
- package/dist/cofidis/container.d.ts +4 -0
- package/dist/cofidis/index.d.ts +6 -0
- package/dist/cofidis/modal.d.ts +3 -0
- package/dist/cofidis/types.d.ts +44 -0
- package/dist/cofidis/widget.d.ts +3 -0
- package/dist/cofidisLoan/container.d.ts +4 -0
- package/dist/cofidisLoan/index.d.ts +7 -0
- package/dist/cofidisLoan/modal.d.ts +4 -0
- package/dist/cofidisLoan/types.d.ts +44 -0
- package/dist/cofidisLoan/widget.d.ts +4 -0
- package/dist/components.cjs.development.js +715 -35
- package/dist/components.cjs.development.js.map +1 -1
- package/dist/components.cjs.production.min.js +1 -1
- package/dist/components.cjs.production.min.js.map +1 -1
- package/dist/components.esm.js +707 -36
- package/dist/components.esm.js.map +1 -1
- package/dist/config.d.ts +6 -0
- package/dist/index.d.ts +2 -0
- package/dist/paymentModal/container.d.ts +4 -0
- package/dist/paymentRequest/types.d.ts +1 -1
- package/dist/types.d.ts +28 -6
- package/package.json +1 -1
package/dist/api.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { CreateApplePaySessionRequest, CreatePaymentRequest, CreateTokenRequest, CreateTokenResponse, GetPaymentMethodsRequest, GetPaymentMethodsResponse, PaymentResult, SendPaymentReceiptRequest } from './types';
|
|
1
|
+
import { CalculateFinancingRequest, CalculateFinancingResponse, CreateApplePaySessionRequest, CreatePaymentRequest, CreateTokenRequest, CreateTokenResponse, GetPaymentMethodsRequest, GetPaymentMethodsResponse, PaymentResult, SendPaymentReceiptRequest, ValidateBizumPhoneRequest } from './types';
|
|
2
2
|
import { ConfirmPaymentParams } from './paymentModal';
|
|
3
3
|
export declare const getPaymentMethods: ({ accountId, paymentId }: GetPaymentMethodsRequest) => Promise<GetPaymentMethodsResponse>;
|
|
4
4
|
export declare const createToken: ({ paymentMethod, paymentId, sessionId, amount, currency, accountId }: CreateTokenRequest) => Promise<CreateTokenResponse>;
|
|
@@ -7,3 +7,7 @@ export declare const confirmPayment: ({ paymentId, ...body }: ConfirmPaymentPara
|
|
|
7
7
|
export declare const createPayment: ({ signature, ...body }: CreatePaymentRequest) => Promise<PaymentResult>;
|
|
8
8
|
export declare const sendPaymentReceipt: ({ paymentId, customerEmail, signature, language }: SendPaymentReceiptRequest) => Promise<PaymentResult>;
|
|
9
9
|
export declare const createApplePaySession: (body: CreateApplePaySessionRequest) => Promise<any>;
|
|
10
|
+
export declare const calculateFinancing: (req: CalculateFinancingRequest) => Promise<CalculateFinancingResponse>;
|
|
11
|
+
export declare const validateBizumPhone: (req: ValidateBizumPhoneRequest) => Promise<{
|
|
12
|
+
isValid: boolean;
|
|
13
|
+
}>;
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { CSSObject } from '../../types/css';
|
|
2
|
+
export interface CofidisProps {
|
|
3
|
+
paymentId?: string;
|
|
4
|
+
language?: string;
|
|
5
|
+
hint?: boolean;
|
|
6
|
+
onError?: (error: any) => void;
|
|
7
|
+
onProps?: (cb: (props: CofidisProps) => void) => Promise<void>;
|
|
8
|
+
onLoad?: (isSupported: boolean) => void;
|
|
9
|
+
onOpen?: () => void;
|
|
10
|
+
onSubmit: (data: {
|
|
11
|
+
token?: string;
|
|
12
|
+
error?: string;
|
|
13
|
+
redirectUrl?: string;
|
|
14
|
+
}) => void;
|
|
15
|
+
fullscreen?: boolean;
|
|
16
|
+
style?: {
|
|
17
|
+
height?: number;
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
export interface CofidisModalProps extends CofidisProps {
|
|
21
|
+
isOpen?: boolean;
|
|
22
|
+
amount: number;
|
|
23
|
+
currency: string;
|
|
24
|
+
accountId: string;
|
|
25
|
+
onError: (error: any) => void;
|
|
26
|
+
}
|
|
27
|
+
export interface CofidisWidgetProps {
|
|
28
|
+
amount?: number;
|
|
29
|
+
amountInt?: number;
|
|
30
|
+
accountId: string;
|
|
31
|
+
language?: string;
|
|
32
|
+
showLogo?: boolean;
|
|
33
|
+
style?: {
|
|
34
|
+
base?: CSSObject;
|
|
35
|
+
link?: CSSObject;
|
|
36
|
+
amount?: CSSObject;
|
|
37
|
+
label?: CSSObject;
|
|
38
|
+
terms?: CSSObject;
|
|
39
|
+
logo?: CSSObject;
|
|
40
|
+
content?: CSSObject;
|
|
41
|
+
};
|
|
42
|
+
onError?: (error: any) => void;
|
|
43
|
+
onLoad?: () => void;
|
|
44
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { CofidisLoanProps } from './types';
|
|
2
|
+
import { MoneiComponent } from '../../types/component';
|
|
3
|
+
export * from './types';
|
|
4
|
+
export * from './modal';
|
|
5
|
+
export * from './widget';
|
|
6
|
+
export declare const CofidisLoan: MoneiComponent<CofidisLoanProps>;
|
|
7
|
+
export declare const CofidisPay: MoneiComponent<CofidisLoanProps>;
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { CSSObject } from '../../types/css';
|
|
2
|
+
export interface CofidisLoanProps {
|
|
3
|
+
paymentId?: string;
|
|
4
|
+
language?: string;
|
|
5
|
+
hint?: boolean;
|
|
6
|
+
onError?: (error: any) => void;
|
|
7
|
+
onProps?: (cb: (props: CofidisLoanProps) => void) => Promise<void>;
|
|
8
|
+
onLoad?: (isSupported: boolean) => void;
|
|
9
|
+
onOpen?: () => void;
|
|
10
|
+
onSubmit: (data: {
|
|
11
|
+
token?: string;
|
|
12
|
+
error?: string;
|
|
13
|
+
redirectUrl?: string;
|
|
14
|
+
}) => void;
|
|
15
|
+
fullscreen?: boolean;
|
|
16
|
+
style?: {
|
|
17
|
+
height?: number;
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
export interface CofidisLoanModalProps extends CofidisLoanProps {
|
|
21
|
+
isOpen?: boolean;
|
|
22
|
+
amount: number;
|
|
23
|
+
currency: string;
|
|
24
|
+
accountId: string;
|
|
25
|
+
onError: (error: any) => void;
|
|
26
|
+
}
|
|
27
|
+
export interface CofidisLoanWidgetProps {
|
|
28
|
+
amount?: number;
|
|
29
|
+
amountInt?: number;
|
|
30
|
+
accountId: string;
|
|
31
|
+
language?: string;
|
|
32
|
+
showLogo?: boolean;
|
|
33
|
+
style?: {
|
|
34
|
+
base?: CSSObject;
|
|
35
|
+
link?: CSSObject;
|
|
36
|
+
amount?: CSSObject;
|
|
37
|
+
label?: CSSObject;
|
|
38
|
+
terms?: CSSObject;
|
|
39
|
+
logo?: CSSObject;
|
|
40
|
+
content?: CSSObject;
|
|
41
|
+
};
|
|
42
|
+
onError?: (error: any) => void;
|
|
43
|
+
onLoad?: () => void;
|
|
44
|
+
}
|