@bigcommerce/checkout-sdk 1.250.0 → 1.253.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/CHANGELOG.md +29 -0
- package/dist/checkout-button.d.ts +51 -0
- package/dist/checkout-button.js +1 -1
- package/dist/checkout-button.js.map +1 -1
- package/dist/checkout-button.umd.js +1 -1
- package/dist/checkout-button.umd.js.map +1 -1
- package/dist/checkout-sdk.d.ts +51 -0
- package/dist/checkout-sdk.js +1 -1
- package/dist/checkout-sdk.js.map +1 -1
- package/dist/checkout-sdk.umd.js +1 -1
- package/dist/checkout-sdk.umd.js.map +1 -1
- package/dist/hosted-form.js +1 -1
- package/dist/hosted-form.js.map +1 -1
- package/dist/hosted-form.umd.js +1 -1
- package/dist/hosted-form.umd.js.map +1 -1
- package/docs/README.md +2 -0
- package/docs/enums/checkoutbuttonmethodtype.md +14 -0
- package/docs/interfaces/braintreepaypalcreditbuttoninitializeoptions.md +85 -0
- package/docs/interfaces/braintreevenmobuttoninitializeoptions.md +29 -0
- package/docs/interfaces/checkoutbuttoninitializeoptions.md +20 -0
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,35 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
|
4
4
|
|
|
5
|
+
## [1.253.0](https://github.com/bigcommerce/checkout-sdk-js/compare/v1.252.0...v1.253.0) (2022-06-14)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
### Features
|
|
9
|
+
|
|
10
|
+
* **payment:** PAYPAL-1381 added braintreevenmo checkout button strategy ([#1463](https://github.com/bigcommerce/checkout-sdk-js/issues/1463)) ([659bb0d](https://github.com/bigcommerce/checkout-sdk-js/commit/659bb0d367f0cb7509da196344a9a28d0e28e0a1))
|
|
11
|
+
|
|
12
|
+
## [1.252.0](https://github.com/bigcommerce/checkout-sdk-js/compare/v1.251.0...v1.252.0) (2022-06-14)
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
### Features
|
|
16
|
+
|
|
17
|
+
* **payment:** PAYPAL-1382 added braintreepaypal checkout button strategy ([#1465](https://github.com/bigcommerce/checkout-sdk-js/issues/1465)) ([b2446ac](https://github.com/bigcommerce/checkout-sdk-js/commit/b2446ac68c4496c6a8935a1c284a7e747b00d13f))
|
|
18
|
+
|
|
19
|
+
## [1.251.0](https://github.com/bigcommerce/checkout-sdk-js/compare/v1.250.0...v1.251.0) (2022-06-14)
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
### Features
|
|
23
|
+
|
|
24
|
+
* **payment:** PAYPAL-1382 added _removeElement method instead of _hideElement in BraintreePayPalCreditButtonStrategy ([a9a5e8e](https://github.com/bigcommerce/checkout-sdk-js/commit/a9a5e8e71593cd668c0261e0e86f8309ac2c8fb2))
|
|
25
|
+
* **payment:** PAYPAL-1382 added braintreepaypalcredit checkout button strategy ([82aa29e](https://github.com/bigcommerce/checkout-sdk-js/commit/82aa29e016c493602e7ef6144c66d663e9b966b6))
|
|
26
|
+
* **payment:** PAYPAL-1382 cleared some code in BraintreePayPalCreditButtonStrategy ([33edc69](https://github.com/bigcommerce/checkout-sdk-js/commit/33edc6913baeb247ab6f396047e91326ae1f6334))
|
|
27
|
+
* **payment:** PAYPAL-1382 updated checkout button method mapper ([b165152](https://github.com/bigcommerce/checkout-sdk-js/commit/b165152f173942b37f4875426e104095fdc64294))
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
### Bug Fixes
|
|
31
|
+
|
|
32
|
+
* **payment:** PAYPAL-1382 fixed an issue with braintreepaypalcreditv2 naming ([e061d19](https://github.com/bigcommerce/checkout-sdk-js/commit/e061d196fb975c8893272fdfda91de87e11dcd91))
|
|
33
|
+
|
|
5
34
|
## [1.250.0](https://github.com/bigcommerce/checkout-sdk-js/compare/v1.249.0...v1.250.0) (2022-06-08)
|
|
6
35
|
|
|
7
36
|
|
|
@@ -135,6 +135,36 @@ declare interface BraintreeError extends Error {
|
|
|
135
135
|
details?: unknown;
|
|
136
136
|
}
|
|
137
137
|
|
|
138
|
+
declare interface BraintreePaypalCreditButtonInitializeOptions {
|
|
139
|
+
/**
|
|
140
|
+
* A set of styling options for the checkout button.
|
|
141
|
+
*/
|
|
142
|
+
style?: Pick<PaypalButtonStyleOptions, 'layout' | 'size' | 'color' | 'label' | 'shape' | 'tagline' | 'fundingicons' | 'height'>;
|
|
143
|
+
/**
|
|
144
|
+
* Address to be used for shipping.
|
|
145
|
+
* If not provided, it will use the first saved address from the active customer.
|
|
146
|
+
*/
|
|
147
|
+
shippingAddress?: Address | null;
|
|
148
|
+
/**
|
|
149
|
+
* A callback that gets called if unable to authorize and tokenize payment.
|
|
150
|
+
*
|
|
151
|
+
* @param error - The error object describing the failure.
|
|
152
|
+
*/
|
|
153
|
+
onAuthorizeError?(error: BraintreeError | StandardError): void;
|
|
154
|
+
/**
|
|
155
|
+
* A callback that gets called if unable to submit payment.
|
|
156
|
+
*
|
|
157
|
+
* @param error - The error object describing the failure.
|
|
158
|
+
*/
|
|
159
|
+
onPaymentError?(error: BraintreeError | StandardError): void;
|
|
160
|
+
/**
|
|
161
|
+
* A callback that gets called on any error instead of submit payment or authorization errors.
|
|
162
|
+
*
|
|
163
|
+
* @param error - The error object describing the failure.
|
|
164
|
+
*/
|
|
165
|
+
onError?(error: BraintreeError | StandardError): void;
|
|
166
|
+
}
|
|
167
|
+
|
|
138
168
|
declare interface BraintreePaypalV1ButtonInitializeOptions {
|
|
139
169
|
/**
|
|
140
170
|
* The ID of a container which the messaging should be inserted.
|
|
@@ -173,6 +203,15 @@ declare interface BraintreePaypalV1ButtonInitializeOptions {
|
|
|
173
203
|
onError?(error: BraintreeError | StandardError): void;
|
|
174
204
|
}
|
|
175
205
|
|
|
206
|
+
declare interface BraintreeVenmoButtonInitializeOptions {
|
|
207
|
+
/**
|
|
208
|
+
* A callback that gets called on any error.
|
|
209
|
+
*
|
|
210
|
+
* @param error - The error object describing the failure.
|
|
211
|
+
*/
|
|
212
|
+
onError?(error: BraintreeError | StandardError): void;
|
|
213
|
+
}
|
|
214
|
+
|
|
176
215
|
declare enum ButtonColor {
|
|
177
216
|
Default = "default",
|
|
178
217
|
Black = "black",
|
|
@@ -211,6 +250,16 @@ declare interface CheckoutButtonInitializeOptions extends CheckoutButtonOptions
|
|
|
211
250
|
* omitted unless you need to support Braintree Credit.
|
|
212
251
|
*/
|
|
213
252
|
braintreepaypalcredit?: BraintreePaypalV1ButtonInitializeOptions;
|
|
253
|
+
/**
|
|
254
|
+
* The options that are required to facilitate Braintree Credit. They can be
|
|
255
|
+
* omitted unless you need to support Braintree Credit.
|
|
256
|
+
*/
|
|
257
|
+
braintreepaypalcreditv2?: BraintreePaypalCreditButtonInitializeOptions;
|
|
258
|
+
/**
|
|
259
|
+
* The options that are required to facilitate Braintree Venmo. They can be
|
|
260
|
+
* omitted unless you need to support Braintree Venmo.
|
|
261
|
+
*/
|
|
262
|
+
braintreevenmo?: BraintreeVenmoButtonInitializeOptions;
|
|
214
263
|
/**
|
|
215
264
|
* The options that are required to facilitate PayPal. They can be omitted
|
|
216
265
|
* unless you need to support Paypal.
|
|
@@ -366,8 +415,10 @@ declare enum CheckoutButtonMethodType {
|
|
|
366
415
|
APPLEPAY = "applepay",
|
|
367
416
|
AMAZON_PAY_V2 = "amazonpay",
|
|
368
417
|
BRAINTREE_PAYPAL = "braintreepaypal",
|
|
418
|
+
BRAINTREE_PAYPALV2 = "braintreepaypalv2",
|
|
369
419
|
BRAINTREE_VENMO = "braintreevenmo",
|
|
370
420
|
BRAINTREE_PAYPAL_CREDIT = "braintreepaypalcredit",
|
|
421
|
+
BRAINTREE_PAYPAL_CREDITV2 = "braintreepaypalcreditv2",
|
|
371
422
|
GOOGLEPAY_ADYENV2 = "googlepayadyenv2",
|
|
372
423
|
GOOGLEPAY_ADYENV3 = "googlepayadyenv3",
|
|
373
424
|
GOOGLEPAY_AUTHORIZENET = "googlepayauthorizenet",
|