@alipay/ams-checkout 0.0.1720423407-dev.0 → 0.0.1720491429-dev.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/umd/ams-checkout.min.js +1 -1
- package/esm/index.d.ts +0 -3
- package/esm/index.js +12 -24
- package/esm/plugin/component/cashierApp.js +1 -1
- package/esm/plugin/component/index.js +1 -13
- package/esm/types/index.d.ts +0 -2
- package/esm/types/index.js +0 -2
- package/package.json +1 -1
package/esm/index.d.ts
CHANGED
@@ -14,9 +14,6 @@ export declare class AMSCheckout extends AMSComponent {
|
|
14
14
|
export declare class AMSAutoDebit extends AMSCheckout {
|
15
15
|
constructor(options: IoptionsParams);
|
16
16
|
}
|
17
|
-
export declare class AMSAutoDebitPay extends AMSCheckout {
|
18
|
-
constructor(options: IoptionsParams);
|
19
|
-
}
|
20
17
|
export declare class AMSEasyPay extends AMSCheckout {
|
21
18
|
constructor(options: IoptionsParams);
|
22
19
|
}
|
package/esm/index.js
CHANGED
@@ -49,21 +49,9 @@ export var AMSAutoDebit = /*#__PURE__*/function (_AMSCheckout) {
|
|
49
49
|
}
|
50
50
|
return _createClass(AMSAutoDebit);
|
51
51
|
}(AMSCheckout);
|
52
|
-
export var
|
53
|
-
_inherits(
|
54
|
-
var _super3 = _createSuper(
|
55
|
-
function AMSAutoDebitPay(options) {
|
56
|
-
_classCallCheck(this, AMSAutoDebitPay);
|
57
|
-
var _options = Object.assign({}, options, {
|
58
|
-
product: productSceneEnum.AUTO_DEBIT_PAY
|
59
|
-
});
|
60
|
-
return _super3.call(this, _options, [componentSignEnum.AUTO_DEBIT_PAY_WALLET]);
|
61
|
-
}
|
62
|
-
return _createClass(AMSAutoDebitPay);
|
63
|
-
}(AMSCheckout);
|
64
|
-
export var AMSEasyPay = /*#__PURE__*/function (_AMSCheckout3) {
|
65
|
-
_inherits(AMSEasyPay, _AMSCheckout3);
|
66
|
-
var _super4 = _createSuper(AMSEasyPay);
|
52
|
+
export var AMSEasyPay = /*#__PURE__*/function (_AMSCheckout2) {
|
53
|
+
_inherits(AMSEasyPay, _AMSCheckout2);
|
54
|
+
var _super3 = _createSuper(AMSEasyPay);
|
67
55
|
function AMSEasyPay(options) {
|
68
56
|
_classCallCheck(this, AMSEasyPay);
|
69
57
|
var _options = Object.assign({}, options, {
|
@@ -88,13 +76,13 @@ export var AMSEasyPay = /*#__PURE__*/function (_AMSCheckout3) {
|
|
88
76
|
error: error
|
89
77
|
});
|
90
78
|
}
|
91
|
-
return
|
79
|
+
return _super3.call(this, _options, [componentSignEnum.EASY_PAY_WALLET], currentProductSceneVersion);
|
92
80
|
}
|
93
81
|
return _createClass(AMSEasyPay);
|
94
82
|
}(AMSCheckout);
|
95
|
-
export var AMSCashierPayment = /*#__PURE__*/function (
|
96
|
-
_inherits(AMSCashierPayment,
|
97
|
-
var
|
83
|
+
export var AMSCashierPayment = /*#__PURE__*/function (_AMSCheckout3) {
|
84
|
+
_inherits(AMSCashierPayment, _AMSCheckout3);
|
85
|
+
var _super4 = _createSuper(AMSCashierPayment);
|
98
86
|
function AMSCashierPayment(options) {
|
99
87
|
_classCallCheck(this, AMSCashierPayment);
|
100
88
|
var _options = Object.assign({}, options, {
|
@@ -119,19 +107,19 @@ export var AMSCashierPayment = /*#__PURE__*/function (_AMSCheckout4) {
|
|
119
107
|
error: error
|
120
108
|
});
|
121
109
|
}
|
122
|
-
return
|
110
|
+
return _super4.call(this, _options, currentChannelType);
|
123
111
|
}
|
124
112
|
return _createClass(AMSCashierPayment);
|
125
113
|
}(AMSCheckout);
|
126
|
-
export var AMSVaulting = /*#__PURE__*/function (
|
127
|
-
_inherits(AMSVaulting,
|
128
|
-
var
|
114
|
+
export var AMSVaulting = /*#__PURE__*/function (_AMSCheckout4) {
|
115
|
+
_inherits(AMSVaulting, _AMSCheckout4);
|
116
|
+
var _super5 = _createSuper(AMSVaulting);
|
129
117
|
function AMSVaulting(options) {
|
130
118
|
_classCallCheck(this, AMSVaulting);
|
131
119
|
var _options = Object.assign({}, options, {
|
132
120
|
product: productSceneEnum.VAULTING
|
133
121
|
});
|
134
|
-
return
|
122
|
+
return _super5.call(this, _options, [componentSignEnum.CASHIER_PAYMENT_CARD]);
|
135
123
|
}
|
136
124
|
return _createClass(AMSVaulting);
|
137
125
|
}(AMSCheckout);
|
@@ -52,7 +52,7 @@ var getAppVersion = function getAppVersion(_extendInfo, productScene, mid) {
|
|
52
52
|
}
|
53
53
|
};
|
54
54
|
var getFinalProductSceneVersion = function getFinalProductSceneVersion(componentSign, productSceneVersion) {
|
55
|
-
var signSupportMap = _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(
|
55
|
+
var signSupportMap = _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, componentSignEnum.NONE, ['']), componentSignEnum.AUTO_DEBIT_WALLET, ['1.0']), componentSignEnum.CASHIER_PAYMENT_BANK, ['1.0']), componentSignEnum.CASHIER_PAYMENT_CARD, ['1.0']), componentSignEnum.CASHIER_PAYMENT_APM, ['1.0']), componentSignEnum.EASY_PAY_WALLET, ['1.0', '2.0']), componentSignEnum.EASY_PAY_APM, ['2.0']), componentSignEnum.VAULTING_CARD, ['1.0']);
|
56
56
|
var supportProductSceneVersion = signSupportMap[componentSign];
|
57
57
|
// 从左到右,从旧到新
|
58
58
|
var isSupport = supportProductSceneVersion.find(function (it) {
|
@@ -298,7 +298,7 @@ var ComponentApp = /*#__PURE__*/function () {
|
|
298
298
|
}).send();
|
299
299
|
if (componentSignEnum.EASY_PAY_WALLET === this._componentSign) {
|
300
300
|
if (productScene === productSceneEnum.EASY_PAY && productSceneVersion === '1.0' && !autoDebitWithToken && requireFastSdk) {
|
301
|
-
// EASY_PAY 1.0首次支付,requireFastSdk为true,不需要接口请求
|
301
|
+
// EASY_PAY 1.0首次支付,requireFastSdk为true,不需要接口请求
|
302
302
|
this.handleAuthUrlInfo(authUrlInfo);
|
303
303
|
return;
|
304
304
|
}
|
@@ -314,18 +314,6 @@ var ComponentApp = /*#__PURE__*/function () {
|
|
314
314
|
return;
|
315
315
|
}
|
316
316
|
}
|
317
|
-
if (componentSignEnum.AUTO_DEBIT_PAY_WALLET === this._componentSign) {
|
318
|
-
if (requireFastSdk === true && productSceneVersion === '1.0') {
|
319
|
-
// REDIRECT,requireFastSdk为true,不需要接口请求
|
320
|
-
this.handleAuthUrlInfo(authUrlInfo);
|
321
|
-
return;
|
322
|
-
} else {
|
323
|
-
return Promise.reject({
|
324
|
-
code: ERRORMESSAGE.CREATEPAYMENT_PARAMETER_ERROR.code,
|
325
|
-
message: "Abnormal response data, interface failure, or unsupported payment method."
|
326
|
-
});
|
327
|
-
}
|
328
|
-
}
|
329
317
|
this.dispatchToSDK(EVENT.eventCallback.name, {
|
330
318
|
code: eventCodeEnum.SDK_START_OF_LOADING
|
331
319
|
});
|
package/esm/types/index.d.ts
CHANGED
@@ -47,7 +47,6 @@ export declare enum componentSignEnum {
|
|
47
47
|
'CASHIER_PAYMENT_BANK' = "CASHIER_PAYMENT_BANK",
|
48
48
|
'CASHIER_PAYMENT_APM' = "CASHIER_PAYMENT_APM",
|
49
49
|
'AUTO_DEBIT_WALLET' = "AUTO_DEBIT_WALLET",
|
50
|
-
'AUTO_DEBIT_PAY_WALLET' = "AUTO_DEBIT_PAY_WALLET",
|
51
50
|
'NONE' = "NONE",
|
52
51
|
'VAULTING_CARD' = "VAULTING_CARD"
|
53
52
|
}
|
@@ -55,7 +54,6 @@ export declare enum productSceneEnum {
|
|
55
54
|
'EASY_PAY' = "EASY_PAY",
|
56
55
|
'CASHIER_PAYMENT' = "CASHIER_PAYMENT",
|
57
56
|
'AUTO_DEBIT' = "AUTO_DEBIT",
|
58
|
-
'AUTO_DEBIT_PAY' = "AUTO_DEBIT_PAY",
|
59
57
|
'VAULTING' = "VAULTING",
|
60
58
|
'FLASH_BUY' = "FLASH_BUY",
|
61
59
|
'CARD_APPLE_PAY' = "CARD_APPLE_PAY"
|
package/esm/types/index.js
CHANGED
@@ -22,7 +22,6 @@ export var componentSignEnum = /*#__PURE__*/function (componentSignEnum) {
|
|
22
22
|
componentSignEnum["CASHIER_PAYMENT_BANK"] = "CASHIER_PAYMENT_BANK";
|
23
23
|
componentSignEnum["CASHIER_PAYMENT_APM"] = "CASHIER_PAYMENT_APM";
|
24
24
|
componentSignEnum["AUTO_DEBIT_WALLET"] = "AUTO_DEBIT_WALLET";
|
25
|
-
componentSignEnum["AUTO_DEBIT_PAY_WALLET"] = "AUTO_DEBIT_PAY_WALLET";
|
26
25
|
componentSignEnum["NONE"] = "NONE";
|
27
26
|
componentSignEnum["VAULTING_CARD"] = "VAULTING_CARD";
|
28
27
|
return componentSignEnum;
|
@@ -31,7 +30,6 @@ export var productSceneEnum = /*#__PURE__*/function (productSceneEnum) {
|
|
31
30
|
productSceneEnum["EASY_PAY"] = "EASY_PAY";
|
32
31
|
productSceneEnum["CASHIER_PAYMENT"] = "CASHIER_PAYMENT";
|
33
32
|
productSceneEnum["AUTO_DEBIT"] = "AUTO_DEBIT";
|
34
|
-
productSceneEnum["AUTO_DEBIT_PAY"] = "AUTO_DEBIT_PAY";
|
35
33
|
productSceneEnum["VAULTING"] = "VAULTING";
|
36
34
|
productSceneEnum["FLASH_BUY"] = "FLASH_BUY";
|
37
35
|
productSceneEnum["CARD_APPLE_PAY"] = "CARD_APPLE_PAY";
|