@stripe/stripe-js
Advanced tools
Comparing version 5.2.0 to 5.3.0
@@ -181,8 +181,16 @@ import {Address, AddressParam} from './shared'; | ||
export interface NextAction { | ||
/** | ||
* Type of the next action to perform, one of `redirect_to_url`, `use_stripe_sdk`, `wechat_pay_display_qr_code`, or `verify_with_microdeposits`. | ||
*/ | ||
type: string; | ||
/** | ||
* Contains instructions for authenticating a payment by redirecting your customer to another page or application. | ||
*/ | ||
redirect_to_url?: NextAction.RedirectToUrl; | ||
/** | ||
* Type of the next action to perform, one of `redirect_to_url`, `use_stripe_sdk` or `wechat_pay_display_qr_code`. | ||
* When confirming a SetupIntent with Stripe.js, Stripe.js depends on the contents of this dictionary to invoke authentication flows. The shape of the contents is subject to change and is only intended to be used by Stripe.js. | ||
*/ | ||
type: string; | ||
use_stripe_sdk?: NextAction.UseStripeSdk; | ||
@@ -193,2 +201,7 @@ /** | ||
wechat_pay_display_qr_code?: NextAction.WechatPayDisplayQrCode; | ||
/** | ||
* Contains details describing microdeposits verification flow. | ||
*/ | ||
verify_with_microdeposits?: NextAction.VerifyWithMicrodeposits; | ||
} | ||
@@ -219,2 +232,19 @@ | ||
} | ||
export interface UseStripeSdk {} | ||
export interface VerifyWithMicrodeposits { | ||
/** | ||
* The timestamp when the microdeposits are expected to land. | ||
*/ | ||
arrival_date: number; | ||
/** | ||
* The URL for the hosted verification page, which allows customers to verify their bank account. | ||
*/ | ||
hosted_verification_url: string; | ||
/** | ||
* The type of the microdeposit sent to the customer. Used to distinguish between different verification methods. | ||
*/ | ||
microdeposit_type: string | null; | ||
} | ||
} | ||
@@ -221,0 +251,0 @@ |
@@ -45,3 +45,3 @@ 'use strict'; | ||
name: 'stripe-js', | ||
version: "5.1.0", | ||
version: "5.2.0", | ||
startTime: startTime | ||
@@ -51,3 +51,3 @@ }); | ||
var stripePromise = null; | ||
var stripePromise$1 = null; | ||
var onErrorListener = null; | ||
@@ -74,7 +74,7 @@ var onLoadListener = null; | ||
// Ensure that we only attempt to load Stripe.js at most once | ||
if (stripePromise !== null) { | ||
return stripePromise; | ||
if (stripePromise$1 !== null) { | ||
return stripePromise$1; | ||
} | ||
stripePromise = new Promise(function (resolve, reject) { | ||
stripePromise$1 = new Promise(function (resolve, reject) { | ||
if (typeof window === 'undefined' || typeof document === 'undefined') { | ||
@@ -125,4 +125,4 @@ // Resolve to null when imported server side. This makes the module | ||
return stripePromise["catch"](function (error) { | ||
stripePromise = null; | ||
return stripePromise$1["catch"](function (error) { | ||
stripePromise$1 = null; | ||
return Promise.reject(error); | ||
@@ -141,16 +141,16 @@ }); | ||
var stripePromise$1; | ||
var stripePromise; | ||
var loadCalled = false; | ||
var getStripePromise = function getStripePromise() { | ||
if (stripePromise$1) { | ||
return stripePromise$1; | ||
if (stripePromise) { | ||
return stripePromise; | ||
} | ||
stripePromise$1 = loadScript(null)["catch"](function (error) { | ||
stripePromise = loadScript(null)["catch"](function (error) { | ||
// clear cache on error | ||
stripePromise$1 = null; | ||
stripePromise = null; | ||
return Promise.reject(error); | ||
}); | ||
return stripePromise$1; | ||
return stripePromise; | ||
}; // Execute our own script injection after a tick to give users time to do their | ||
@@ -157,0 +157,0 @@ // own script injection. |
@@ -61,3 +61,3 @@ 'use strict'; | ||
name: 'stripe-js', | ||
version: "5.1.0", | ||
version: "5.2.0", | ||
startTime: startTime | ||
@@ -64,0 +64,0 @@ }); |
@@ -733,3 +733,3 @@ import { | ||
*/ | ||
captureMethod?: 'manual' | 'automatic'; | ||
captureMethod?: 'manual' | 'automatic' | 'automatic_async'; | ||
@@ -741,3 +741,3 @@ /** | ||
*/ | ||
capture_method?: 'manual' | 'automatic'; | ||
capture_method?: 'manual' | 'automatic' | 'automatic_async'; | ||
@@ -877,3 +877,3 @@ /** | ||
*/ | ||
captureMethod?: 'manual' | 'automatic'; | ||
captureMethod?: 'manual' | 'automatic' | 'automatic_async'; | ||
@@ -885,3 +885,3 @@ /** | ||
*/ | ||
capture_method?: 'manual' | 'automatic'; | ||
capture_method?: 'manual' | 'automatic' | 'automatic_async'; | ||
@@ -888,0 +888,0 @@ /** |
{ | ||
"name": "@stripe/stripe-js", | ||
"version": "5.2.0", | ||
"version": "5.3.0", | ||
"description": "Stripe.js loading utility", | ||
@@ -61,3 +61,3 @@ "repository": "github:stripe/stripe-js", | ||
"rimraf": "^2.6.2", | ||
"rollup": "^1.29.0", | ||
"rollup": "^2.79.2", | ||
"rollup-plugin-babel": "^4.3.3", | ||
@@ -64,0 +64,0 @@ "rollup-plugin-typescript2": "^0.25.3", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
926211
13168
1