@getopenpay/openpay-js 0.5.13 → 0.5.15
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/{ExportResult-B-YLKMaU.js → ExportResult-BacsqwKA.js} +1 -1
- package/dist/{Resource-BZeevyoh.js → Resource-Ds5bbQ3b.js} +4 -4
- package/dist/SimpleSpanProcessor-0bSccE1S.js +910 -0
- package/dist/_commonjsHelpers-CdLE1o9f.js +30 -0
- package/dist/detect-resources-UwRkF4Xd.js +862 -0
- package/dist/{diag-api-CHLb_Weo.js → diag-api-CMlZXyyv.js} +2 -2
- package/dist/index-1jECpTsg.js +147 -0
- package/dist/index-BZEpD-f0.js +6718 -0
- package/dist/index-BhZy-TW3.js +430 -0
- package/dist/index-BmKZeOoc.js +1619 -0
- package/dist/index-CDdbDQxQ.js +6 -0
- package/dist/index-CWTkU3J-.js +18 -0
- package/dist/index-DFO-DCsT.js +127 -0
- package/dist/index-DsxDp11a.js +28 -0
- package/dist/index-JNJd_YS1.js +1012 -0
- package/dist/index-j7i6AeZa.js +7005 -0
- package/dist/index.d.ts +29 -4
- package/dist/index.es.js +2 -2
- package/dist/index.umd.js +45 -45
- package/dist/lifecycle-D1BdEbZs.js +119 -0
- package/dist/{metrics-api-ClKmMX3Y.js → metrics-api-C9pRFfr-.js} +2 -2
- package/dist/sdk-info-ChuKu8zW.js +285 -0
- package/dist/suppress-tracing-B94rObkn.js +17 -0
- package/dist/url-CdPstDG9.js +798 -0
- package/dist/utils--M6ihaNw.js +101 -0
- package/dist/utils-De78ey-v.js +12 -0
- package/dist/utils-VJ-0MC7c.js +270 -0
- package/package.json +4 -4
- package/dist/SimpleSpanProcessor-CwJD-GjM.js +0 -957
- package/dist/_commonjsHelpers-f76XedMs.js +0 -25
- package/dist/detect-resources-BatabDmW.js +0 -854
- package/dist/index-ByaN1AdQ.js +0 -6685
- package/dist/index-CU4AI3HW.js +0 -52
- package/dist/index-Cb34s3AM.js +0 -1599
- package/dist/index-CmtkHZgE.js +0 -330
- package/dist/index-CtZ-xuHu.js +0 -7041
- package/dist/index-D5OCmVN-.js +0 -19
- package/dist/index-DLJd6nUV.js +0 -150
- package/dist/index-DjekHBls.js +0 -431
- package/dist/index-DoKHV9rR.js +0 -130
- package/dist/index-_ZTp3kCj.js +0 -830
- package/dist/lifecycle-BjQ-7GLm.js +0 -119
- package/dist/sdk-info-DYuuxEVK.js +0 -484
- package/dist/url-BAeEv8aD.js +0 -797
- package/dist/utils--qqdHZ_b.js +0 -142
- package/dist/utils-Bf8wDuNo.js +0 -381
- package/dist/utils-CX5YT7yI.js +0 -14
package/dist/index.d.ts
CHANGED
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
/// <reference types="googlepay" />
|
|
3
3
|
|
|
4
4
|
import { PaymentRequest as PaymentRequest_2 } from '@stripe/stripe-js';
|
|
5
|
+
import { StripeLinkAuthenticationElement } from '@stripe/stripe-js';
|
|
5
6
|
import { Subject } from 'rxjs';
|
|
6
7
|
import { z } from 'zod';
|
|
7
8
|
|
|
@@ -80,7 +81,7 @@ declare type ApplePayFlowCustomParams = {
|
|
|
80
81
|
*/
|
|
81
82
|
processor?: PaymentProcessor;
|
|
82
83
|
overridePaymentRequest?: {
|
|
83
|
-
amount
|
|
84
|
+
amount?: Amount;
|
|
84
85
|
pending?: boolean;
|
|
85
86
|
label?: string;
|
|
86
87
|
applePayPaymentRequest?: ApplePayPaymentRequest;
|
|
@@ -241,6 +242,22 @@ declare type CustomInitParams = {
|
|
|
241
242
|
* If this value is true, the stripe link is not mounted on init, and should instead be manually mounted.
|
|
242
243
|
*/
|
|
243
244
|
doNotMountOnInit?: boolean;
|
|
245
|
+
|
|
246
|
+
/**
|
|
247
|
+
* If this value is true, the link authentication element is checked for login status silently.
|
|
248
|
+
*
|
|
249
|
+
* ⚠️ [**Warning**]: This is a workaround for checking Link authentication status without user gesture.
|
|
250
|
+
* Stripe don't expose API for this and it's recommended to mount the `linkAuthenticationElement` manually and check the authentication status via `.on('change')`
|
|
251
|
+
* You can mount the `linkAuthenticationElement` manually by calling `stripeLink.mountLinkAuthenticationElement(selector)`
|
|
252
|
+
*/
|
|
253
|
+
silentlyCheckAuthentication?: boolean;
|
|
254
|
+
/**
|
|
255
|
+
* This callback is called when the authentication status changes when `silentlyCheckAuthentication` is true,
|
|
256
|
+
*
|
|
257
|
+
* ⚠️ [**Warning**]: This is a workaround for checking authentication status without user gesture.
|
|
258
|
+
* This is working with current version of Stripe element (v3). This is not guaranteed to work with future versions of Stripe element.
|
|
259
|
+
*/
|
|
260
|
+
onAuthenticationStatusChange?: (isAuthenticated: boolean) => void;
|
|
244
261
|
};
|
|
245
262
|
|
|
246
263
|
googlePay?: {
|
|
@@ -416,7 +433,7 @@ declare type GooglePayFlowCustomParams = {
|
|
|
416
433
|
*/
|
|
417
434
|
processor?: PaymentProcessor;
|
|
418
435
|
overridePaymentRequest?: {
|
|
419
|
-
amount
|
|
436
|
+
amount?: Amount;
|
|
420
437
|
pending?: boolean;
|
|
421
438
|
label?: string;
|
|
422
439
|
googlePayPaymentRequest?: GooglePayPaymentRequest;
|
|
@@ -958,6 +975,7 @@ export declare class OpenPayForm {
|
|
|
958
975
|
name: SubmitMethods;
|
|
959
976
|
processors: PaymentProcessor[];
|
|
960
977
|
isAvailable: boolean;
|
|
978
|
+
controller?: unknown;
|
|
961
979
|
}[]>;
|
|
962
980
|
/**
|
|
963
981
|
* @deprecated
|
|
@@ -1100,7 +1118,7 @@ declare type PaymentRequestProvider = z.infer<typeof PaymentRequestProvider>;
|
|
|
1100
1118
|
|
|
1101
1119
|
declare type PaymentRequestStartParams = {
|
|
1102
1120
|
overridePaymentRequest?: {
|
|
1103
|
-
amount
|
|
1121
|
+
amount?: Amount;
|
|
1104
1122
|
pending?: boolean;
|
|
1105
1123
|
label?: string;
|
|
1106
1124
|
applePayPaymentRequest?: ApplePayPaymentRequest;
|
|
@@ -1125,6 +1143,7 @@ declare type ProcessorSpecificSubmitSettings<T extends SubmitMethod = SubmitMeth
|
|
|
1125
1143
|
[SubmitMethods.googlePay]: GooglePayFlowCustomParams;
|
|
1126
1144
|
[SubmitMethods.loopCrypto]: LoopCryptoFlowCustomParams;
|
|
1127
1145
|
[SubmitMethods.paypal]: PaypalFlowCustomParams;
|
|
1146
|
+
[SubmitMethods.stripeLink]: unknown;
|
|
1128
1147
|
// TODO: The following methods are deprecated and will be removed in the future.
|
|
1129
1148
|
// Use googlePay/applePay instead
|
|
1130
1149
|
[SubmitMethods.airwallexGooglePay]: GooglePayFlowCustomParams;
|
|
@@ -1152,10 +1171,11 @@ declare type RunOjsFlow<T_PARAMS = undefined, T_INIT_RESULT = undefined> = (
|
|
|
1152
1171
|
params: OjsFlowParams<T_PARAMS, T_INIT_RESULT>
|
|
1153
1172
|
) => Promise<void>;
|
|
1154
1173
|
|
|
1155
|
-
declare type StripeLinkController = {
|
|
1174
|
+
export declare type StripeLinkController = {
|
|
1156
1175
|
mountButton: () => void;
|
|
1157
1176
|
dismountButton: () => void;
|
|
1158
1177
|
waitForButtonToMount: () => Promise<HTMLElement>;
|
|
1178
|
+
mountLinkAuthenticationElement: (selector: string) => StripeLinkAuthenticationElement;
|
|
1159
1179
|
};
|
|
1160
1180
|
|
|
1161
1181
|
declare const SubmitMethod = z.nativeEnum(SubmitMethods);
|
|
@@ -1169,6 +1189,11 @@ export declare enum SubmitMethods {
|
|
|
1169
1189
|
googlePay = 'google-pay',
|
|
1170
1190
|
loopCrypto = 'loop-crypto',
|
|
1171
1191
|
paypal = 'paypal',
|
|
1192
|
+
/**
|
|
1193
|
+
* This submit method only for Available payment methods.
|
|
1194
|
+
* Manual submission for StripeLink is not available
|
|
1195
|
+
*/
|
|
1196
|
+
stripeLink = 'stripe-link',
|
|
1172
1197
|
// TODO: The following methods are deprecated and will be removed in the future.
|
|
1173
1198
|
/**
|
|
1174
1199
|
* @deprecated Use googlePay instead
|
package/dist/index.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { E as p, F as r, O as i, l as s } from "./index-
|
|
1
|
+
import { E as p, F as r, O as i, l as s } from "./index-j7i6AeZa.js";
|
|
2
2
|
import "penpal";
|
|
3
3
|
import "uuid";
|
|
4
4
|
import "zod";
|
|
@@ -8,4 +8,4 @@ export {
|
|
|
8
8
|
i as OpenPayForm,
|
|
9
9
|
s as SubmitMethods
|
|
10
10
|
};
|
|
11
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
11
|
+
//# sourceMappingURL=data:application/json;base64,ewogICJ2ZXJzaW9uIjogMywKICAic291cmNlcyI6IFsiaW5kZXguZXMuanMiXSwKICAic291cmNlc0NvbnRlbnQiOiBbImV4cG9ydCB7IEUgYXMgRWxlbWVudFR5cGVFbnVtLCBGIGFzIEZpZWxkTmFtZSwgTyBhcyBPcGVuUGF5Rm9ybSwgbCBhcyBTdWJtaXRNZXRob2RzIH0gZnJvbSAnLi9pbmRleC0hfnswMDl9fi5qcyc7XG5pbXBvcnQgJ3BlbnBhbCc7XG5pbXBvcnQgJ3V1aWQnO1xuaW1wb3J0ICd6b2QnOyJdLAogICJtYXBwaW5ncyI6ICJBQUFBLFNBQWMsS0FBTEEsR0FBMkIsS0FBTEMsR0FBcUIsS0FBTEMsR0FBdUIsS0FBTEMsU0FBMEI7QUFDM0YsT0FBTztBQUNQLE9BQU87QUFDUCxPQUFPOyIsCiAgIm5hbWVzIjogWyJFIiwgIkYiLCAiTyIsICJsIl0KfQo=
|