@alipay/ams-checkout 0.0.1730107332-dev.18 → 0.0.1730107332-dev.20
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/foundation/product-processor/easysafepay/deps.d.ts +1 -1
- package/esm/foundation/product-processor/easysafepay/deps.js +1 -1
- package/esm/foundation/product-processor/easysafepay/index.d.ts +0 -1
- package/esm/foundation/product-processor/easysafepay/index.js +1 -19
- package/esm/util/index.d.ts +1 -2
- package/esm/util/index.js +1 -14
- package/package.json +1 -1
@@ -5,7 +5,7 @@ export * as ChannelCustomize from '../../../component/channel';
|
|
5
5
|
export type { IChannelBehavior } from '../../../component/channel';
|
6
6
|
export { DisplayTypeEnum, PaymentMethodCategoryTypeEnum, ProductSceneEnum } from '../../../types';
|
7
7
|
export type { CashierSdkActionQueryRequest, CashierSdkActionQueryResult, CashierSubmitPayRequest, CashierSubmitPayResult, IOptionsParams, } from '../../../types';
|
8
|
-
export {
|
8
|
+
export { isPC } from '../../../util';
|
9
9
|
export { getBackScheme } from '../../../util/getBackScheme';
|
10
10
|
export { isLocalMock } from '../../../util/mock';
|
11
11
|
export { ServiceProvider } from '../../service';
|
@@ -2,7 +2,7 @@ export { v4 as uuid } from 'uuid';
|
|
2
2
|
import * as _ChannelCustomize from "../../../component/channel";
|
3
3
|
export { _ChannelCustomize as ChannelCustomize };
|
4
4
|
export { DisplayTypeEnum, PaymentMethodCategoryTypeEnum, ProductSceneEnum } from "../../../types";
|
5
|
-
export {
|
5
|
+
export { isPC } from "../../../util";
|
6
6
|
export { getBackScheme } from "../../../util/getBackScheme";
|
7
7
|
export { isLocalMock } from "../../../util/mock";
|
8
8
|
export { ServiceProvider } from "../../service";
|
@@ -16,7 +16,7 @@ function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _d
|
|
16
16
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
17
17
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
18
18
|
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
19
|
-
import { ChannelCustomize, DisplayTypeEnum, getBackScheme, isPC, ProductInfoCacheUtil, ProductSceneEnum, ServiceProvider, uuid, WebAppUrlUtil
|
19
|
+
import { ChannelCustomize, DisplayTypeEnum, getBackScheme, isPC, ProductInfoCacheUtil, ProductSceneEnum, ServiceProvider, uuid, WebAppUrlUtil } from "./deps";
|
20
20
|
export var EasySafePayProcessor = /*#__PURE__*/function () {
|
21
21
|
function EasySafePayProcessor() {
|
22
22
|
_classCallCheck(this, EasySafePayProcessor);
|
@@ -223,8 +223,6 @@ export var EasySafePayProcessor = /*#__PURE__*/function () {
|
|
223
223
|
eventCenter.dispatchToApp({
|
224
224
|
event: 'renderComponent',
|
225
225
|
data: {
|
226
|
-
// For ESP 1.0
|
227
|
-
queryResult: _this2.getQueryResult(),
|
228
226
|
sessionResult: (_this2$paymentContext = _this2.paymentContext) === null || _this2$paymentContext === void 0 ? void 0 : _this2$paymentContext.paymentSessionObj,
|
229
227
|
submitResult: submitRes,
|
230
228
|
paymentSessionData: (_this2$paymentContext2 = _this2.paymentContext) === null || _this2$paymentContext2 === void 0 ? void 0 : _this2$paymentContext2.paymentSession,
|
@@ -368,22 +366,6 @@ export var EasySafePayProcessor = /*#__PURE__*/function () {
|
|
368
366
|
}
|
369
367
|
return processSubmitPay;
|
370
368
|
}()
|
371
|
-
}, {
|
372
|
-
key: "getQueryResult",
|
373
|
-
value: function getQueryResult() {
|
374
|
-
var _this$paymentContext4, _this$paymentContext5;
|
375
|
-
if (isEmpty((_this$paymentContext4 = this.paymentContext) === null || _this$paymentContext4 === void 0 ? void 0 : _this$paymentContext4.paymentSessionObj)) {
|
376
|
-
return {
|
377
|
-
success: false
|
378
|
-
};
|
379
|
-
}
|
380
|
-
return _objectSpread(_objectSpread({
|
381
|
-
success: true,
|
382
|
-
orderAmount: _objectSpread(_objectSpread({}, this.paymentContext.paymentSessionObj.paymentView), {}, {
|
383
|
-
formattedAmount: (_this$paymentContext5 = this.paymentContext) === null || _this$paymentContext5 === void 0 || (_this$paymentContext5 = _this$paymentContext5.paymentSessionObj.paymentView) === null || _this$paymentContext5 === void 0 ? void 0 : _this$paymentContext5.formattedValue
|
384
|
-
})
|
385
|
-
}, this.paymentContext.paymentSessionObj), this.paymentContext.paymentSessionObj.action);
|
386
|
-
}
|
387
369
|
}, {
|
388
370
|
key: "acquireApdidToken",
|
389
371
|
value: function () {
|
package/esm/util/index.d.ts
CHANGED
@@ -36,5 +36,4 @@ declare function loadSDKScript({ src, attrOptions, timeOut, loadCallback }: {
|
|
36
36
|
timeOut?: number;
|
37
37
|
loadCallback?: any;
|
38
38
|
}, logger: any): Promise<unknown>;
|
39
|
-
|
40
|
-
export { getType, getViewPort, getOrigin, serialize, isJsonString, isDom, isFunction, isEmpty, device, safeJson, isPC, queryParse, getDesignFontSize, amsSetSize, addSetFontSizeEvent, getOrSetStorageId, checkTimeElapsed, parseBase64ToString, loadSDKScript, };
|
39
|
+
export { getType, getViewPort, getOrigin, serialize, isJsonString, isDom, isFunction, device, safeJson, isPC, queryParse, getDesignFontSize, amsSetSize, addSetFontSizeEvent, getOrSetStorageId, checkTimeElapsed, parseBase64ToString, loadSDKScript, };
|
package/esm/util/index.js
CHANGED
@@ -251,17 +251,4 @@ function loadSDKScript(_ref, logger) {
|
|
251
251
|
document.head.appendChild(script);
|
252
252
|
});
|
253
253
|
}
|
254
|
-
|
255
|
-
if (value == null) {
|
256
|
-
// Checks for null and undefined
|
257
|
-
return true;
|
258
|
-
}
|
259
|
-
if (typeof value === 'string' || Array.isArray(value)) {
|
260
|
-
return value.length === 0;
|
261
|
-
}
|
262
|
-
if (_typeof(value) === 'object') {
|
263
|
-
return Object.keys(value).length === 0;
|
264
|
-
}
|
265
|
-
return false; // For other types (like numbers, functions, etc.)
|
266
|
-
};
|
267
|
-
export { getType, getViewPort, getOrigin, serialize, isJsonString, isDom, isFunction, isEmpty, device, safeJson, isPC, queryParse, getDesignFontSize, amsSetSize, addSetFontSizeEvent, getOrSetStorageId, checkTimeElapsed, parseBase64ToString, loadSDKScript };
|
254
|
+
export { getType, getViewPort, getOrigin, serialize, isJsonString, isDom, isFunction, device, safeJson, isPC, queryParse, getDesignFontSize, amsSetSize, addSetFontSizeEvent, getOrSetStorageId, checkTimeElapsed, parseBase64ToString, loadSDKScript };
|