@stripe/stripe-js 1.20.3 → 1.21.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/pure.esm.js +1 -1
- package/dist/pure.js +1 -1
- package/dist/stripe.esm.js +1 -1
- package/dist/stripe.js +1 -1
- package/package.json +5 -5
- package/src/shared.ts +1 -2
- package/types/api/bank-accounts.d.ts +61 -0
- package/types/api/cards.d.ts +130 -0
- package/types/api/index.d.ts +9 -9
- package/types/api/payment-intents.d.ts +330 -0
- package/types/api/payment-methods.d.ts +349 -0
- package/types/api/setup-intents.d.ts +184 -0
- package/types/api/shared.d.ts +124 -126
- package/types/api/sources.d.ts +1045 -0
- package/types/api/tokens.d.ts +634 -0
- package/types/api/verification-sessions.d.ts +9 -0
- package/types/index.d.ts +14 -12
- package/types/stripe-js/checkout.d.ts +134 -136
- package/types/stripe-js/elements/affirm-message.d.ts +59 -61
- package/types/stripe-js/elements/afterpay-clearpay-message.d.ts +118 -120
- package/types/stripe-js/elements/au-bank-account.d.ts +123 -120
- package/types/stripe-js/elements/base.d.ts +263 -263
- package/types/stripe-js/elements/card-cvc.d.ts +107 -103
- package/types/stripe-js/elements/card-expiry.d.ts +107 -104
- package/types/stripe-js/elements/card-number.d.ts +128 -125
- package/types/stripe-js/elements/card.d.ts +157 -154
- package/types/stripe-js/elements/eps-bank.d.ts +125 -121
- package/types/stripe-js/elements/fpx-bank.d.ts +120 -116
- package/types/stripe-js/elements/iban.d.ts +134 -131
- package/types/stripe-js/elements/ideal-bank.d.ts +125 -121
- package/types/stripe-js/elements/index.d.ts +17 -0
- package/types/stripe-js/elements/link-authentication.d.ts +92 -94
- package/types/stripe-js/elements/p24-bank.d.ts +125 -121
- package/types/stripe-js/elements/payment-request-button.d.ts +127 -127
- package/types/stripe-js/elements/payment.d.ts +190 -180
- package/types/stripe-js/elements/shipping-address.d.ts +123 -125
- package/types/stripe-js/elements-group.d.ts +617 -0
- package/types/stripe-js/index.d.ts +7 -1069
- package/types/stripe-js/payment-intents.d.ts +951 -919
- package/types/stripe-js/payment-request.d.ts +503 -503
- package/types/stripe-js/setup-intents.d.ts +149 -135
- package/types/stripe-js/stripe.d.ts +1070 -0
- package/types/stripe-js/token-and-sources.d.ts +80 -80
- package/types/utils.d.ts +2 -0
- package/types/api/BankAccounts.d.ts +0 -63
- package/types/api/Cards.d.ts +0 -130
- package/types/api/PaymentIntents.d.ts +0 -329
- package/types/api/PaymentMethods.d.ts +0 -349
- package/types/api/SetupIntents.d.ts +0 -184
- package/types/api/Sources.d.ts +0 -1045
- package/types/api/Tokens.d.ts +0 -632
- package/types/api/VerificationSessions.d.ts +0 -11
- package/types/stripe-js/elements.d.ts +0 -604
|
@@ -1,135 +1,138 @@
|
|
|
1
|
-
|
|
1
|
+
import {
|
|
2
|
+
StripeElementBase,
|
|
3
|
+
StripeElementStyle,
|
|
4
|
+
StripeElementClasses,
|
|
5
|
+
StripeElementChangeEvent,
|
|
6
|
+
} from './base';
|
|
2
7
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
): StripeAuBankAccountElement;
|
|
8
|
+
export type StripeAuBankAccountElement = StripeElementBase & {
|
|
9
|
+
/**
|
|
10
|
+
* The change event is triggered when the `Element`'s value changes.
|
|
11
|
+
*/
|
|
12
|
+
on(
|
|
13
|
+
eventType: 'change',
|
|
14
|
+
handler: (event: StripeAuBankAccountElementChangeEvent) => any
|
|
15
|
+
): StripeAuBankAccountElement;
|
|
16
|
+
once(
|
|
17
|
+
eventType: 'change',
|
|
18
|
+
handler: (event: StripeAuBankAccountElementChangeEvent) => any
|
|
19
|
+
): StripeAuBankAccountElement;
|
|
20
|
+
off(
|
|
21
|
+
eventType: 'change',
|
|
22
|
+
handler?: (event: StripeAuBankAccountElementChangeEvent) => any
|
|
23
|
+
): StripeAuBankAccountElement;
|
|
20
24
|
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
25
|
+
/**
|
|
26
|
+
* Triggered when the element is fully rendered and can accept `element.focus` calls.
|
|
27
|
+
*/
|
|
28
|
+
on(
|
|
29
|
+
eventType: 'ready',
|
|
30
|
+
handler: (event: {elementType: 'auBankAccount'}) => any
|
|
31
|
+
): StripeAuBankAccountElement;
|
|
32
|
+
once(
|
|
33
|
+
eventType: 'ready',
|
|
34
|
+
handler: (event: {elementType: 'auBankAccount'}) => any
|
|
35
|
+
): StripeAuBankAccountElement;
|
|
36
|
+
off(
|
|
37
|
+
eventType: 'ready',
|
|
38
|
+
handler?: (event: {elementType: 'auBankAccount'}) => any
|
|
39
|
+
): StripeAuBankAccountElement;
|
|
36
40
|
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
41
|
+
/**
|
|
42
|
+
* Triggered when the element gains focus.
|
|
43
|
+
*/
|
|
44
|
+
on(
|
|
45
|
+
eventType: 'focus',
|
|
46
|
+
handler: (event: {elementType: 'auBankAccount'}) => any
|
|
47
|
+
): StripeAuBankAccountElement;
|
|
48
|
+
once(
|
|
49
|
+
eventType: 'focus',
|
|
50
|
+
handler: (event: {elementType: 'auBankAccount'}) => any
|
|
51
|
+
): StripeAuBankAccountElement;
|
|
52
|
+
off(
|
|
53
|
+
eventType: 'focus',
|
|
54
|
+
handler?: (event: {elementType: 'auBankAccount'}) => any
|
|
55
|
+
): StripeAuBankAccountElement;
|
|
52
56
|
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
57
|
+
/**
|
|
58
|
+
* Triggered when the element loses focus.
|
|
59
|
+
*/
|
|
60
|
+
on(
|
|
61
|
+
eventType: 'blur',
|
|
62
|
+
handler: (event: {elementType: 'auBankAccount'}) => any
|
|
63
|
+
): StripeAuBankAccountElement;
|
|
64
|
+
once(
|
|
65
|
+
eventType: 'blur',
|
|
66
|
+
handler: (event: {elementType: 'auBankAccount'}) => any
|
|
67
|
+
): StripeAuBankAccountElement;
|
|
68
|
+
off(
|
|
69
|
+
eventType: 'blur',
|
|
70
|
+
handler?: (event: {elementType: 'auBankAccount'}) => any
|
|
71
|
+
): StripeAuBankAccountElement;
|
|
68
72
|
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
73
|
+
/**
|
|
74
|
+
* Triggered when the escape key is pressed within the element.
|
|
75
|
+
*/
|
|
76
|
+
on(
|
|
77
|
+
eventType: 'escape',
|
|
78
|
+
handler: (event: {elementType: 'auBankAccount'}) => any
|
|
79
|
+
): StripeAuBankAccountElement;
|
|
80
|
+
once(
|
|
81
|
+
eventType: 'escape',
|
|
82
|
+
handler: (event: {elementType: 'auBankAccount'}) => any
|
|
83
|
+
): StripeAuBankAccountElement;
|
|
84
|
+
off(
|
|
85
|
+
eventType: 'escape',
|
|
86
|
+
handler?: (event: {elementType: 'auBankAccount'}) => any
|
|
87
|
+
): StripeAuBankAccountElement;
|
|
84
88
|
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
89
|
+
/**
|
|
90
|
+
* Updates the options the `AuBankAccountElement` was initialized with.
|
|
91
|
+
* Updates are merged into the existing configuration.
|
|
92
|
+
*
|
|
93
|
+
* The styles of an `AuBankAccountElement` can be dynamically changed using `element.update`.
|
|
94
|
+
* This method can be used to simulate CSS media queries that automatically adjust the size of elements when viewed on different devices.
|
|
95
|
+
*/
|
|
96
|
+
update(options: Partial<StripeAuBankAccountElementOptions>): void;
|
|
97
|
+
};
|
|
94
98
|
|
|
95
|
-
|
|
96
|
-
|
|
99
|
+
export interface StripeAuBankAccountElementOptions {
|
|
100
|
+
classes?: StripeElementClasses;
|
|
97
101
|
|
|
98
|
-
|
|
102
|
+
style?: StripeElementStyle;
|
|
99
103
|
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
+
/**
|
|
105
|
+
* Appearance of the icon in the Element.
|
|
106
|
+
*/
|
|
107
|
+
iconStyle?: 'default' | 'solid';
|
|
104
108
|
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
109
|
+
/**
|
|
110
|
+
* Hides the icon in the Element.
|
|
111
|
+
* Default is `false`.
|
|
112
|
+
*/
|
|
113
|
+
hideIcon?: boolean;
|
|
110
114
|
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
115
|
+
/**
|
|
116
|
+
* Applies a disabled state to the Element such that user input is not accepted.
|
|
117
|
+
* Default is false.
|
|
118
|
+
*/
|
|
119
|
+
disabled?: boolean;
|
|
120
|
+
}
|
|
117
121
|
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
122
|
+
export interface StripeAuBankAccountElementChangeEvent
|
|
123
|
+
extends StripeElementChangeEvent {
|
|
124
|
+
/**
|
|
125
|
+
* The type of element that emitted this event.
|
|
126
|
+
*/
|
|
127
|
+
elementType: 'auBankAccount';
|
|
124
128
|
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
+
/**
|
|
130
|
+
* The bank name corresponding to the entered BSB.
|
|
131
|
+
*/
|
|
132
|
+
bankName?: string;
|
|
129
133
|
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
}
|
|
134
|
+
/**
|
|
135
|
+
* The branch name corresponding to the entered BSB.
|
|
136
|
+
*/
|
|
137
|
+
branchName?: string;
|
|
135
138
|
}
|