@stripe/stripe-js 7.3.1 → 7.4.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/index.js CHANGED
@@ -55,7 +55,7 @@ var registerWrapper = function registerWrapper(stripe, startTime) {
55
55
 
56
56
  stripe._registerWrapper({
57
57
  name: 'stripe-js',
58
- version: "7.3.1",
58
+ version: "7.4.0",
59
59
  startTime: startTime
60
60
  });
61
61
  };
@@ -151,7 +151,7 @@ var initStripe = function initStripe(maybeStripe, args, startTime) {
151
151
  var expectedVersion = RELEASE_TRAIN;
152
152
 
153
153
  if (isTestKey && version !== expectedVersion) {
154
- console.warn("Stripe.js@".concat(version, " was loaded on the page, but @stripe/stripe-js@").concat("7.3.1", " expected Stripe.js@").concat(expectedVersion, ". This may result in unexpected behavior. For more information, see https://docs.stripe.com/sdks/stripejs-versioning"));
154
+ console.warn("Stripe.js@".concat(version, " was loaded on the page, but @stripe/stripe-js@").concat("7.4.0", " expected Stripe.js@").concat(expectedVersion, ". This may result in unexpected behavior. For more information, see https://docs.stripe.com/sdks/stripejs-versioning"));
155
155
  }
156
156
 
157
157
  var stripe = maybeStripe.apply(undefined, args);
package/dist/index.mjs CHANGED
@@ -51,7 +51,7 @@ var registerWrapper = function registerWrapper(stripe, startTime) {
51
51
 
52
52
  stripe._registerWrapper({
53
53
  name: 'stripe-js',
54
- version: "7.3.1",
54
+ version: "7.4.0",
55
55
  startTime: startTime
56
56
  });
57
57
  };
@@ -147,7 +147,7 @@ var initStripe = function initStripe(maybeStripe, args, startTime) {
147
147
  var expectedVersion = RELEASE_TRAIN;
148
148
 
149
149
  if (isTestKey && version !== expectedVersion) {
150
- console.warn("Stripe.js@".concat(version, " was loaded on the page, but @stripe/stripe-js@").concat("7.3.1", " expected Stripe.js@").concat(expectedVersion, ". This may result in unexpected behavior. For more information, see https://docs.stripe.com/sdks/stripejs-versioning"));
150
+ console.warn("Stripe.js@".concat(version, " was loaded on the page, but @stripe/stripe-js@").concat("7.4.0", " expected Stripe.js@").concat(expectedVersion, ". This may result in unexpected behavior. For more information, see https://docs.stripe.com/sdks/stripejs-versioning"));
151
151
  }
152
152
 
153
153
  var stripe = maybeStripe.apply(undefined, args);
package/dist/pure.js CHANGED
@@ -71,7 +71,7 @@ var registerWrapper = function registerWrapper(stripe, startTime) {
71
71
 
72
72
  stripe._registerWrapper({
73
73
  name: 'stripe-js',
74
- version: "7.3.1",
74
+ version: "7.4.0",
75
75
  startTime: startTime
76
76
  });
77
77
  };
@@ -167,7 +167,7 @@ var initStripe = function initStripe(maybeStripe, args, startTime) {
167
167
  var expectedVersion = RELEASE_TRAIN;
168
168
 
169
169
  if (isTestKey && version !== expectedVersion) {
170
- console.warn("Stripe.js@".concat(version, " was loaded on the page, but @stripe/stripe-js@").concat("7.3.1", " expected Stripe.js@").concat(expectedVersion, ". This may result in unexpected behavior. For more information, see https://docs.stripe.com/sdks/stripejs-versioning"));
170
+ console.warn("Stripe.js@".concat(version, " was loaded on the page, but @stripe/stripe-js@").concat("7.4.0", " expected Stripe.js@").concat(expectedVersion, ". This may result in unexpected behavior. For more information, see https://docs.stripe.com/sdks/stripejs-versioning"));
171
171
  }
172
172
 
173
173
  var stripe = maybeStripe.apply(undefined, args);
package/dist/pure.mjs CHANGED
@@ -67,7 +67,7 @@ var registerWrapper = function registerWrapper(stripe, startTime) {
67
67
 
68
68
  stripe._registerWrapper({
69
69
  name: 'stripe-js',
70
- version: "7.3.1",
70
+ version: "7.4.0",
71
71
  startTime: startTime
72
72
  });
73
73
  };
@@ -163,7 +163,7 @@ var initStripe = function initStripe(maybeStripe, args, startTime) {
163
163
  var expectedVersion = RELEASE_TRAIN;
164
164
 
165
165
  if (isTestKey && version !== expectedVersion) {
166
- console.warn("Stripe.js@".concat(version, " was loaded on the page, but @stripe/stripe-js@").concat("7.3.1", " expected Stripe.js@").concat(expectedVersion, ". This may result in unexpected behavior. For more information, see https://docs.stripe.com/sdks/stripejs-versioning"));
166
+ console.warn("Stripe.js@".concat(version, " was loaded on the page, but @stripe/stripe-js@").concat("7.4.0", " expected Stripe.js@").concat(expectedVersion, ". This may result in unexpected behavior. For more information, see https://docs.stripe.com/sdks/stripejs-versioning"));
167
167
  }
168
168
 
169
169
  var stripe = maybeStripe.apply(undefined, args);
@@ -525,6 +525,12 @@ export interface StripeExpressCheckoutElementClickEvent {
525
525
  * This must be called within 1 second of the 'click' event being emitted.
526
526
  */
527
527
  resolve: (resolveDetails?: ClickResolveDetails) => void;
528
+
529
+ /**
530
+ * Callback to allow for cancellation of the payment interface.
531
+ * This must be called within 1 second of the 'click' event being emitted.
532
+ */
533
+ reject: () => void;
528
534
  }
529
535
 
530
536
  export interface StripeExpressCheckoutElementConfirmEvent {
@@ -525,6 +525,12 @@ export interface StripeExpressCheckoutElementClickEvent {
525
525
  * This must be called within 1 second of the 'click' event being emitted.
526
526
  */
527
527
  resolve: (resolveDetails?: ClickResolveDetails) => void;
528
+
529
+ /**
530
+ * Callback to allow for cancellation of the payment interface.
531
+ * This must be called within 1 second of the 'click' event being emitted.
532
+ */
533
+ reject: () => void;
528
534
  }
529
535
 
530
536
  export interface StripeExpressCheckoutElementConfirmEvent {
@@ -706,6 +706,14 @@ export interface StripeElementsOptionsClientSecret
706
706
  * Either use mode or clientSecret when creating an Elements group
707
707
  */
708
708
  mode?: never;
709
+
710
+ /**
711
+ * Influences available payment methods when creating SetupIntents with automatic_payment_methods.
712
+ * Payment Element renders the payment methods enabled in the Stripe Dashboard that support the provided currency.
713
+ *
714
+ * Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
715
+ */
716
+ currency?: string;
709
717
  }
710
718
 
711
719
  export interface StripeElementsOptionsMode extends BaseStripeElementsOptions {
@@ -706,6 +706,14 @@ export interface StripeElementsOptionsClientSecret
706
706
  * Either use mode or clientSecret when creating an Elements group
707
707
  */
708
708
  mode?: never;
709
+
710
+ /**
711
+ * Influences available payment methods when creating SetupIntents with automatic_payment_methods.
712
+ * Payment Element renders the payment methods enabled in the Stripe Dashboard that support the provided currency.
713
+ *
714
+ * Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
715
+ */
716
+ currency?: string;
709
717
  }
710
718
 
711
719
  export interface StripeElementsOptionsMode extends BaseStripeElementsOptions {
@@ -159,7 +159,9 @@ export interface PaymentRequestUpdateOptions {
159
159
  /**
160
160
  * Specify the options to be used when the Apple Pay payment interface opens.
161
161
  */
162
- applePay?: ApplePayOption;
162
+ applePay?: ApplePayOption & {
163
+ cardFunding?: 'supportsCredit' | 'supportsDebit';
164
+ };
163
165
  }
164
166
 
165
167
  /**
@@ -235,7 +237,9 @@ export interface PaymentRequestOptions {
235
237
  /**
236
238
  * Specify the options to be used when the Apple Pay payment interface opens.
237
239
  */
238
- applePay?: ApplePayOption;
240
+ applePay?: ApplePayOption & {
241
+ cardFunding?: 'supportsCredit' | 'supportsDebit';
242
+ };
239
243
 
240
244
  /**
241
245
  * The Stripe account ID which is the business of record.
@@ -159,7 +159,9 @@ export interface PaymentRequestUpdateOptions {
159
159
  /**
160
160
  * Specify the options to be used when the Apple Pay payment interface opens.
161
161
  */
162
- applePay?: ApplePayOption;
162
+ applePay?: ApplePayOption & {
163
+ cardFunding?: 'supportsCredit' | 'supportsDebit';
164
+ };
163
165
  }
164
166
 
165
167
  /**
@@ -235,7 +237,9 @@ export interface PaymentRequestOptions {
235
237
  /**
236
238
  * Specify the options to be used when the Apple Pay payment interface opens.
237
239
  */
238
- applePay?: ApplePayOption;
240
+ applePay?: ApplePayOption & {
241
+ cardFunding?: 'supportsCredit' | 'supportsDebit';
242
+ };
239
243
 
240
244
  /**
241
245
  * The Stripe account ID which is the business of record.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stripe/stripe-js",
3
- "version": "7.3.1",
3
+ "version": "7.4.0",
4
4
  "description": "Stripe.js loading utility",
5
5
  "repository": "github:stripe/stripe-js",
6
6
  "main": "lib/index.js",