@alipay/ams-checkout 0.0.1729593469-dev.0 → 0.0.1730107332-dev.1
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/{plugin/component → component}/channel.d.ts +3 -4
- package/esm/{plugin/component → component}/channel.js +1 -37
- package/esm/component/component.inline.style.d.ts +10 -0
- package/esm/{plugin/component → component}/component.inline.style.js +11 -9
- package/esm/{plugin/component → component}/component.popup.style.d.ts +15 -6
- package/esm/{plugin/component → component}/component.popup.style.js +36 -18
- package/esm/{plugin/component → component}/popupWindow.style.js +2 -2
- package/esm/config/index.d.ts +7 -7
- package/esm/config/index.js +7 -7
- package/esm/constant/index.d.ts +7 -6
- package/esm/constant/index.js +11 -80
- package/esm/foundation/core/index.d.ts +26 -0
- package/esm/foundation/core/index.js +335 -0
- package/esm/foundation/index.d.ts +71 -0
- package/esm/foundation/index.js +42 -0
- package/esm/foundation/product-processor/easysafepay/deps.d.ts +17 -0
- package/esm/foundation/product-processor/easysafepay/deps.js +11 -0
- package/esm/foundation/product-processor/easysafepay/index.d.ts +27 -0
- package/esm/foundation/product-processor/easysafepay/index.js +581 -0
- package/esm/{core/bus → foundation/service/api-bus}/ability/callback.d.ts +2 -2
- package/esm/{core/bus → foundation/service/api-bus}/ability/callback.js +1 -1
- package/esm/foundation/service/api-bus/ability/globalData.d.ts +10 -0
- package/esm/{core/component/address.js → foundation/service/api-bus/ability/globalData.js} +75 -58
- package/esm/foundation/service/api-bus/ability/request.d.ts +10 -0
- package/esm/foundation/service/api-bus/ability/request.js +151 -0
- package/esm/{core/bus → foundation/service/api-bus}/ability/security.d.ts +6 -4
- package/esm/{core/bus → foundation/service/api-bus}/ability/security.js +92 -35
- package/esm/{core/bus → foundation/service/api-bus}/ability/tracker.d.ts +4 -4
- package/esm/{core/bus → foundation/service/api-bus}/ability/tracker.js +6 -3
- package/esm/{core/bus/index.d.ts → foundation/service/api-bus/busManager.d.ts} +17 -15
- package/esm/{core/bus/index.js → foundation/service/api-bus/busManager.js} +67 -35
- package/esm/foundation/service/api-bus/index.d.ts +20 -0
- package/esm/foundation/service/api-bus/index.js +88 -0
- package/esm/{core/bus → foundation/service/api-bus}/interface.d.ts +12 -0
- package/esm/{core/bus → foundation/service/api-bus}/interface.js +16 -2
- package/esm/foundation/service/container/index.d.ts +28 -0
- package/esm/foundation/service/container/index.js +257 -0
- package/esm/foundation/service/container/popup.d.ts +17 -0
- package/esm/{core/component/appPreloadProcessing.js → foundation/service/container/popup.js} +97 -83
- package/esm/foundation/service/container/utils.d.ts +7 -0
- package/esm/foundation/service/container/utils.js +48 -0
- package/esm/foundation/service/event-center.d.ts +74 -0
- package/esm/foundation/service/event-center.js +213 -0
- package/esm/foundation/service/global-data/index.d.ts +11 -0
- package/esm/foundation/service/global-data/index.js +68 -0
- package/esm/foundation/service/index.d.ts +19 -0
- package/esm/foundation/service/index.js +82 -0
- package/esm/foundation/service/log/index.d.ts +43 -0
- package/esm/foundation/service/log/index.js +235 -0
- package/esm/foundation/service/log/types.d.ts +32 -0
- package/esm/foundation/service/requester/deps.d.ts +17 -0
- package/esm/foundation/service/requester/deps.js +11 -0
- package/esm/foundation/service/requester/requester.d.ts +22 -0
- package/esm/foundation/service/requester/requester.js +214 -0
- package/esm/foundation/service/security/index.d.ts +28 -0
- package/esm/foundation/service/security/index.js +285 -0
- package/esm/{util → foundation/service/security}/security.d.ts +2 -2
- package/esm/{util → foundation/service/security}/security.js +3 -3
- package/esm/foundation/types/index.d.ts +4 -0
- package/esm/foundation/types/index.js +4 -0
- package/esm/foundation/utils/gray_scale_utils.d.ts +7 -0
- package/esm/foundation/utils/gray_scale_utils.js +40 -0
- package/esm/foundation/utils/payment_context_utils.d.ts +13 -0
- package/esm/foundation/utils/payment_context_utils.js +57 -0
- package/esm/foundation/utils/payment_product_utils.d.ts +13 -0
- package/esm/foundation/utils/payment_product_utils.js +38 -0
- package/esm/foundation/utils/redirect_utils.d.ts +6 -0
- package/esm/foundation/utils/redirect_utils.js +99 -0
- package/esm/foundation/utils/system_events.d.ts +4 -0
- package/esm/foundation/utils/system_events.js +71 -0
- package/esm/foundation/utils/web_app_url_utils.d.ts +46 -0
- package/esm/foundation/utils/web_app_url_utils.js +112 -0
- package/esm/index.d.ts +5 -28
- package/esm/index.js +28 -158
- package/esm/types/index.d.ts +66 -38
- package/esm/types/index.js +63 -59
- package/esm/util/index.d.ts +1 -1
- package/esm/util/index.js +3 -4
- package/package.json +2 -2
- package/esm/core/component/address.d.ts +0 -8
- package/esm/core/component/appPreloadProcessing.d.ts +0 -1
- package/esm/core/component/ckp/index.d.ts +0 -27
- package/esm/core/component/ckp/index.js +0 -166
- package/esm/core/component/index.d.ts +0 -51
- package/esm/core/component/index.js +0 -531
- package/esm/core/drop-in/index.d.ts +0 -22
- package/esm/core/drop-in/index.js +0 -104
- package/esm/core/instance/index.d.ts +0 -89
- package/esm/core/instance/index.js +0 -499
- package/esm/plugin/applepay/component.d.ts +0 -50
- package/esm/plugin/applepay/component.js +0 -339
- package/esm/plugin/applepay/index.d.ts +0 -17
- package/esm/plugin/applepay/index.js +0 -117
- package/esm/plugin/applepay/interface.d.ts +0 -161
- package/esm/plugin/applepay/interface.js +0 -69
- package/esm/plugin/applepay/service.d.ts +0 -54
- package/esm/plugin/applepay/service.js +0 -289
- package/esm/plugin/component/cashierApp.d.ts +0 -34
- package/esm/plugin/component/cashierApp.js +0 -237
- package/esm/plugin/component/component.inline.style.d.ts +0 -10
- package/esm/plugin/component/index.d.ts +0 -126
- package/esm/plugin/component/index.js +0 -1839
- package/esm/plugin/const.d.ts +0 -2
- package/esm/plugin/const.js +0 -33
- package/esm/plugin/drop-in/index.d.ts +0 -71
- package/esm/plugin/drop-in/index.js +0 -324
- package/esm/plugin/payment-element/utils.d.ts +0 -2
- package/esm/plugin/payment-element/utils.js +0 -6
- package/esm/plugin/paypal/index.d.ts +0 -20
- package/esm/plugin/paypal/index.js +0 -390
- package/esm/plugin/type.d.ts +0 -34
- package/esm/plugin/utils.d.ts +0 -6
- package/esm/plugin/utils.js +0 -21
- package/esm/util/createIframeNode.d.ts +0 -6
- package/esm/util/createIframeNode.js +0 -48
- package/esm/util/getBackScheme.d.ts +0 -5
- package/esm/util/getBackScheme.js +0 -42
- package/esm/util/ua/index.d.ts +0 -2
- package/esm/util/ua/index.js +0 -2
- package/esm/util/ua/isAndroid.d.ts +0 -4
- package/esm/util/ua/isAndroid.js +0 -7
- package/esm/util/ua/isIOS.d.ts +0 -4
- package/esm/util/ua/isIOS.js +0 -7
- /package/esm/{plugin/component → component}/popupWindow.style.d.ts +0 -0
- /package/esm/{plugin/type.js → foundation/service/log/types.js} +0 -0
package/esm/index.js
CHANGED
@@ -1,19 +1,10 @@
|
|
1
1
|
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
2
|
-
function
|
3
|
-
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
4
|
-
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; }
|
2
|
+
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
5
3
|
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
|
6
4
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
5
|
+
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; }
|
7
6
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
8
7
|
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); }
|
9
|
-
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
10
|
-
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
11
|
-
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
12
|
-
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
13
|
-
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
|
14
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
15
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
16
|
-
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
17
8
|
/**
|
18
9
|
* Copyright (c) 2022 International Business Group, Ant Group. All rights reserved.
|
19
10
|
*
|
@@ -21,155 +12,34 @@ function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.g
|
|
21
12
|
* 1. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE; and
|
22
13
|
* 2. If applicable, the use of the Software is also subject to the terms and conditions of any non-disclosure agreement signed by you and the relevant Ant Group entity.
|
23
14
|
*/
|
24
|
-
|
25
|
-
import {
|
26
|
-
import {
|
27
|
-
import {
|
28
|
-
import {
|
29
|
-
var logger = new Logger(LogConfig, true);
|
30
|
-
export { AMSCheckoutPage } from "./core/component/ckp";
|
15
|
+
|
16
|
+
import { AntomSDKCore } from "./foundation/core";
|
17
|
+
import { EasySafePayProcessor } from "./foundation/product-processor/easysafepay";
|
18
|
+
import { DisplayTypeEnum } from "./types";
|
19
|
+
import { ProductSceneEnum } from "./types/index";
|
31
20
|
export * from "./types";
|
32
|
-
export var
|
33
|
-
_inherits(AMSCheckout, _AMSComponent);
|
34
|
-
var _super = _createSuper(AMSCheckout);
|
35
|
-
function AMSCheckout(_options, channelType) {
|
36
|
-
var _this;
|
37
|
-
var productSceneVersion = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : '1.0';
|
38
|
-
_classCallCheck(this, AMSCheckout);
|
39
|
-
_this = _super.call(this, _objectSpread({
|
40
|
-
appVersion: AMSCheckoutAppVersion
|
41
|
-
}, _options));
|
42
|
-
_this.preloadComponent(channelType, productSceneVersion);
|
43
|
-
return _this;
|
44
|
-
}
|
45
|
-
return _createClass(AMSCheckout);
|
46
|
-
}(AMSComponent);
|
47
|
-
export var AMSAutoDebit = /*#__PURE__*/function (_AMSCheckout) {
|
48
|
-
_inherits(AMSAutoDebit, _AMSCheckout);
|
49
|
-
var _super2 = _createSuper(AMSAutoDebit);
|
50
|
-
function AMSAutoDebit(options) {
|
51
|
-
_classCallCheck(this, AMSAutoDebit);
|
52
|
-
var _options = Object.assign({}, options, {
|
53
|
-
product: productSceneEnum.AUTO_DEBIT,
|
54
|
-
appVersion: AMSAutoDebitAppVersion
|
55
|
-
});
|
56
|
-
return _super2.call(this, _options, [componentSignEnum.AUTO_DEBIT_WALLET]);
|
57
|
-
}
|
58
|
-
return _createClass(AMSAutoDebit);
|
59
|
-
}(AMSCheckout);
|
60
|
-
export var AMSAutoDebitPay = /*#__PURE__*/function (_AMSCheckout2) {
|
61
|
-
_inherits(AMSAutoDebitPay, _AMSCheckout2);
|
62
|
-
var _super3 = _createSuper(AMSAutoDebitPay);
|
63
|
-
function AMSAutoDebitPay(options) {
|
64
|
-
_classCallCheck(this, AMSAutoDebitPay);
|
65
|
-
var _options = Object.assign({}, options, {
|
66
|
-
product: productSceneEnum.AUTO_DEBIT_PAY
|
67
|
-
});
|
68
|
-
return _super3.call(this, _options, [componentSignEnum.AUTO_DEBIT_PAY_WALLET]);
|
69
|
-
}
|
70
|
-
return _createClass(AMSAutoDebitPay);
|
71
|
-
}(AMSCheckout);
|
72
|
-
export var AMSEasyPay = /*#__PURE__*/function (_AMSCheckout3) {
|
73
|
-
_inherits(AMSEasyPay, _AMSCheckout3);
|
74
|
-
var _super4 = _createSuper(AMSEasyPay);
|
21
|
+
export var AMSEasyPay = /*#__PURE__*/function () {
|
75
22
|
function AMSEasyPay(options) {
|
76
23
|
_classCallCheck(this, AMSEasyPay);
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
logger.logError({
|
95
|
-
title: 'performance_optimization_get_previousChannel_error'
|
96
|
-
}, {
|
97
|
-
error: error
|
24
|
+
_defineProperty(this, "core", void 0);
|
25
|
+
this.core = new AntomSDKCore();
|
26
|
+
this.core.registerProcessor(ProductSceneEnum.EASY_PAY, '', new EasySafePayProcessor());
|
27
|
+
this.core.init(options, ProductSceneEnum.EASY_PAY);
|
28
|
+
}
|
29
|
+
_createClass(AMSEasyPay, [{
|
30
|
+
key: "createComponent",
|
31
|
+
value: function createComponent(params) {
|
32
|
+
this.core.startBizFlow({
|
33
|
+
submitPayRequestExtra: {
|
34
|
+
notRedirectAfterComplete: params.notRedirectAfterComplete,
|
35
|
+
merchantAppointParam: params.merchantAppointParam
|
36
|
+
},
|
37
|
+
paymentSession: params.sessionData || params.paymentSessionData,
|
38
|
+
displayInfo: {
|
39
|
+
type: DisplayTypeEnum.popup
|
40
|
+
}
|
98
41
|
});
|
99
42
|
}
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
}(AMSCheckout);
|
104
|
-
export var AMSCashierPayment = /*#__PURE__*/function (_AMSCheckout4) {
|
105
|
-
_inherits(AMSCashierPayment, _AMSCheckout4);
|
106
|
-
var _super5 = _createSuper(AMSCashierPayment);
|
107
|
-
function AMSCashierPayment(options) {
|
108
|
-
_classCallCheck(this, AMSCashierPayment);
|
109
|
-
var _options = Object.assign({}, options, {
|
110
|
-
product: productSceneEnum.CASHIER_PAYMENT,
|
111
|
-
appVersion: AMSCashierPaymentAppVersion
|
112
|
-
});
|
113
|
-
var currentChannelType;
|
114
|
-
try {
|
115
|
-
var previousChannelStr = localStorage.getItem('antom_checkout_previousChannel');
|
116
|
-
var previousChannel = JSON.parse(previousChannelStr) || {};
|
117
|
-
var _ref2 = previousChannel || {},
|
118
|
-
_ref2$channelType = _ref2.channelType,
|
119
|
-
channelType = _ref2$channelType === void 0 ? '' : _ref2$channelType;
|
120
|
-
if ([componentSignEnum.CASHIER_PAYMENT_CARD, componentSignEnum.CASHIER_PAYMENT_APM, componentSignEnum.CASHIER_PAYMENT_BANK].includes(channelType)) {
|
121
|
-
currentChannelType = [channelType];
|
122
|
-
} else {
|
123
|
-
currentChannelType = [componentSignEnum.CASHIER_PAYMENT_CARD, componentSignEnum.CASHIER_PAYMENT_APM];
|
124
|
-
}
|
125
|
-
} catch (error) {
|
126
|
-
logger.logError({
|
127
|
-
title: 'performance_optimization_get_previousChannel_error'
|
128
|
-
}, {
|
129
|
-
error: error
|
130
|
-
});
|
131
|
-
}
|
132
|
-
return _super5.call(this, _options, currentChannelType);
|
133
|
-
}
|
134
|
-
return _createClass(AMSCashierPayment);
|
135
|
-
}(AMSCheckout);
|
136
|
-
export var AMSVaulting = /*#__PURE__*/function (_AMSCheckout5) {
|
137
|
-
_inherits(AMSVaulting, _AMSCheckout5);
|
138
|
-
var _super6 = _createSuper(AMSVaulting);
|
139
|
-
function AMSVaulting(options) {
|
140
|
-
_classCallCheck(this, AMSVaulting);
|
141
|
-
var _options = Object.assign({}, options, {
|
142
|
-
product: productSceneEnum.VAULTING,
|
143
|
-
appVersion: AMSVaultingAppVersion
|
144
|
-
});
|
145
|
-
return _super6.call(this, _options, [componentSignEnum.CASHIER_PAYMENT_CARD]);
|
146
|
-
}
|
147
|
-
return _createClass(AMSVaulting);
|
148
|
-
}(AMSCheckout);
|
149
|
-
export var AntomElement = /*#__PURE__*/function (_AMSCheckout6) {
|
150
|
-
_inherits(AntomElement, _AMSCheckout6);
|
151
|
-
var _super7 = _createSuper(AntomElement);
|
152
|
-
function AntomElement(options) {
|
153
|
-
_classCallCheck(this, AntomElement);
|
154
|
-
var _options = Object.assign({}, options, {
|
155
|
-
product: productSceneEnum.ELEMENT_PAYMENT,
|
156
|
-
appVersion: AMSPaymentElementAppVersion
|
157
|
-
});
|
158
|
-
return _super7.call(this, _options, [componentSignEnum.ELEMENT_PAYMENT]);
|
159
|
-
}
|
160
|
-
return _createClass(AntomElement);
|
161
|
-
}(AMSCheckout);
|
162
|
-
export var AddressElement = /*#__PURE__*/function (_AddressComponent) {
|
163
|
-
_inherits(AddressElement, _AddressComponent);
|
164
|
-
var _super8 = _createSuper(AddressElement);
|
165
|
-
function AddressElement(options) {
|
166
|
-
_classCallCheck(this, AddressElement);
|
167
|
-
var _options = Object.assign({}, options, {
|
168
|
-
product: productSceneEnum.ELEMENT_ADDRESS,
|
169
|
-
appVersion: ADDRESSElementAppVersion
|
170
|
-
});
|
171
|
-
return _super8.call(this, _options);
|
172
|
-
}
|
173
|
-
return _createClass(AddressElement);
|
174
|
-
}(AddressComponent);
|
175
|
-
export default AMSCheckout;
|
43
|
+
}]);
|
44
|
+
return AMSEasyPay;
|
45
|
+
}();
|
package/esm/types/index.d.ts
CHANGED
@@ -19,7 +19,7 @@ interface AddressValueResult {
|
|
19
19
|
/**
|
20
20
|
* SDK options
|
21
21
|
*/
|
22
|
-
export interface
|
22
|
+
export interface IOptionsParams {
|
23
23
|
environment?: string;
|
24
24
|
locale?: string;
|
25
25
|
onError?: callOnError;
|
@@ -37,10 +37,10 @@ export interface IoptionsParams {
|
|
37
37
|
product?: string;
|
38
38
|
onBeforeSubmit?: callOnBeforeSubmit;
|
39
39
|
}
|
40
|
-
export interface IApplePayOptionsParams extends Pick<
|
40
|
+
export interface IApplePayOptionsParams extends Pick<IOptionsParams, 'locale' | 'environment' | 'onEventCallback' | 'analytics'> {
|
41
41
|
}
|
42
42
|
export type Iselector = string;
|
43
|
-
export declare enum
|
43
|
+
export declare enum DisplayTypeEnum {
|
44
44
|
'popup' = "popup",
|
45
45
|
'inline' = "inline"
|
46
46
|
}
|
@@ -57,7 +57,7 @@ export declare enum ComponentSignEnumV2 {
|
|
57
57
|
'ELEMENT_PAYMENT' = "ELEMENT_PAYMENT_ALL",
|
58
58
|
'ELEMENT_ADDRESS' = "ELEMENT_ADDRESS_ALL"
|
59
59
|
}
|
60
|
-
export declare enum
|
60
|
+
export declare enum ComponentSignEnum {
|
61
61
|
'EASY_PAY_WALLET' = "EASY_PAY_WALLET",
|
62
62
|
'EASY_PAY_APM' = "EASY_PAY_APM",
|
63
63
|
'CASHIER_PAYMENT_CARD' = "CASHIER_PAYMENT_CARD",
|
@@ -68,10 +68,9 @@ export declare enum componentSignEnum {
|
|
68
68
|
'NONE' = "NONE",
|
69
69
|
'VAULTING_CARD' = "VAULTING_CARD",
|
70
70
|
'ELEMENT_PAYMENT' = "ELEMENT_PAYMENT_ALL",
|
71
|
-
'ELEMENT_ADDRESS' = "ELEMENT_ADDRESS_ALL"
|
72
|
-
'CHECKOUT_PAYMENT' = "CHECKOUT_PAYMENT"
|
71
|
+
'ELEMENT_ADDRESS' = "ELEMENT_ADDRESS_ALL"
|
73
72
|
}
|
74
|
-
export declare enum
|
73
|
+
export declare enum ProductSceneEnum {
|
75
74
|
'EASY_PAY' = "EASY_PAY",
|
76
75
|
'CASHIER_PAYMENT' = "CASHIER_PAYMENT",
|
77
76
|
'AUTO_DEBIT' = "AUTO_DEBIT",
|
@@ -83,7 +82,7 @@ export declare enum productSceneEnum {
|
|
83
82
|
'ELEMENT_ADDRESS' = "ELEMENT_ADDRESS",
|
84
83
|
'CHECKOUT_PAYMENT' = "CHECKOUT_PAYMENT"
|
85
84
|
}
|
86
|
-
export declare enum
|
85
|
+
export declare enum PaymentMethodCategoryTypeEnum {
|
87
86
|
'CARD' = "CARD",
|
88
87
|
'WALLET' = "WALLET",
|
89
88
|
'BANK' = "BANK",
|
@@ -92,8 +91,8 @@ export declare enum paymentMethodCategoryTypeEnum {
|
|
92
91
|
}
|
93
92
|
export interface DeviceIdParameter {
|
94
93
|
scene?: string;
|
95
|
-
productScene?:
|
96
|
-
paymentMethodCategoryType?:
|
94
|
+
productScene?: ProductSceneEnum;
|
95
|
+
paymentMethodCategoryType?: PaymentMethodCategoryTypeEnum;
|
97
96
|
tokenCollectTime?: string;
|
98
97
|
dataPollingInterval?: string;
|
99
98
|
}
|
@@ -106,14 +105,16 @@ export interface IcreateComponent {
|
|
106
105
|
themeType?: string;
|
107
106
|
accentColor?: string;
|
108
107
|
};
|
109
|
-
isAppWebview?: boolean;
|
110
108
|
merchantAppointParam?: IMerchantAppointParam;
|
111
109
|
}
|
112
110
|
export interface IappendIframeNodesParams extends IcreateComponent {
|
113
|
-
paymentSessionMetaData:
|
114
|
-
renderDisplayType:
|
111
|
+
paymentSessionMetaData: IPaymentSessionMetaData;
|
112
|
+
renderDisplayType: DisplayTypeEnum;
|
115
113
|
selector?: Iselector;
|
116
114
|
paypalConfiguration?: IPaypalConfiguration;
|
115
|
+
connectFactor?: {
|
116
|
+
enableConnect: boolean;
|
117
|
+
};
|
117
118
|
/** 将address-element参数定义合入原参数定义 */
|
118
119
|
configParams?: {
|
119
120
|
hideFields?: string[];
|
@@ -197,8 +198,8 @@ export interface Isubmit {
|
|
197
198
|
billingAddress?: IbillingAddress;
|
198
199
|
}
|
199
200
|
export interface IpaymentSessionConfig {
|
200
|
-
productScene:
|
201
|
-
paymentMethodCategoryType
|
201
|
+
productScene: ProductSceneEnum;
|
202
|
+
paymentMethodCategoryType: PaymentMethodCategoryTypeEnum;
|
202
203
|
productSceneVersion: string;
|
203
204
|
}
|
204
205
|
export interface IpaymentSecurityConfig {
|
@@ -216,14 +217,27 @@ export interface IsecurityConfig {
|
|
216
217
|
h5gateway: string;
|
217
218
|
}
|
218
219
|
export interface InitSecurityConfig {
|
219
|
-
product:
|
220
|
+
product: ProductSceneEnum;
|
220
221
|
region?: string;
|
221
222
|
}
|
222
223
|
export interface frontModulesToBeLoadedInterface {
|
223
224
|
acquirerName: string;
|
224
225
|
scriptUrl: string;
|
225
226
|
}
|
226
|
-
export interface
|
227
|
+
export interface PaymentSessionActionData {
|
228
|
+
amountConfirmRequired?: boolean;
|
229
|
+
autoDebitWithToken: boolean;
|
230
|
+
enableSignAgreement?: boolean;
|
231
|
+
skipSdkQuery: boolean;
|
232
|
+
requireFastSdk: boolean;
|
233
|
+
nonCompliant?: boolean;
|
234
|
+
skipSdkQueryForm?: {
|
235
|
+
value: boolean;
|
236
|
+
version: string;
|
237
|
+
platform: string;
|
238
|
+
};
|
239
|
+
}
|
240
|
+
export interface IPaymentSessionMetaData {
|
227
241
|
clientId?: string;
|
228
242
|
renderDisplayType?: string;
|
229
243
|
paymentSessionConfig?: IpaymentSessionConfig;
|
@@ -231,18 +245,7 @@ export interface IpaymentSessionMetaData {
|
|
231
245
|
moneyView?: any;
|
232
246
|
extendInfo?: string;
|
233
247
|
paymentMethodInfoView?: any;
|
234
|
-
action?:
|
235
|
-
amountConfirmRequired?: boolean;
|
236
|
-
autoDebitWithToken: boolean;
|
237
|
-
enableSignAgreement?: boolean;
|
238
|
-
skipSdkQuery: boolean;
|
239
|
-
requireFastSdk: boolean;
|
240
|
-
skipSdkQueryForm?: {
|
241
|
-
value: boolean;
|
242
|
-
version: string;
|
243
|
-
platform: string;
|
244
|
-
};
|
245
|
-
};
|
248
|
+
action?: PaymentSessionActionData;
|
246
249
|
authUrlInfo?: {
|
247
250
|
appIdentifier?: string;
|
248
251
|
applinkUrl?: string;
|
@@ -313,6 +316,9 @@ export interface IpaymentSessionMetaData {
|
|
313
316
|
};
|
314
317
|
frontModulesToBeLoaded?: frontModulesToBeLoadedInterface[];
|
315
318
|
};
|
319
|
+
connectFactor?: {
|
320
|
+
enableConnect?: boolean;
|
321
|
+
};
|
316
322
|
}
|
317
323
|
export interface IPaymentSessionFactor {
|
318
324
|
merchantInfo?: IMerchantInfo;
|
@@ -359,7 +365,7 @@ export declare enum networkModeEnum {
|
|
359
365
|
export interface IcheckoutState {
|
360
366
|
paymentMethodType?: string;
|
361
367
|
}
|
362
|
-
export declare enum
|
368
|
+
export declare enum EnvironmentEnum {
|
363
369
|
sandbox = "sandbox",
|
364
370
|
prod = "prod",
|
365
371
|
light_sandbox = "light_sandbox"
|
@@ -380,7 +386,7 @@ export interface Ienv {
|
|
380
386
|
terminalType: terminalTypeEnum;
|
381
387
|
environment: string;
|
382
388
|
}
|
383
|
-
export declare enum
|
389
|
+
export declare enum PlatformEnum {
|
384
390
|
desktop = "desktop",
|
385
391
|
mobile = "mobile"
|
386
392
|
}
|
@@ -434,19 +440,19 @@ export type callOnBeforeSubmit = (state?: Record<string, any>) => Promise<onBefo
|
|
434
440
|
* @description Create an event handler, In pop-up layer mode, the user clicks the semi floating layer close button and is called.
|
435
441
|
*/
|
436
442
|
export type callOnClose = () => void;
|
437
|
-
export declare enum
|
443
|
+
export declare enum MessageName {
|
438
444
|
SDK_TO_APP = "SDK_TO_APP",
|
439
445
|
APP_TO_SDK = "APP_TO_SDK",
|
440
446
|
APP_TO_APP = "APP_TO_APP"
|
441
447
|
}
|
442
|
-
export interface
|
443
|
-
name:
|
448
|
+
export interface EventPayload {
|
449
|
+
name: MessageName;
|
444
450
|
mode?: string;
|
445
451
|
appId?: string;
|
446
452
|
instanceId: string;
|
447
|
-
context:
|
453
|
+
context: EventPayloadContext;
|
448
454
|
}
|
449
|
-
export interface
|
455
|
+
export interface EventPayloadContext {
|
450
456
|
event: string;
|
451
457
|
data: any;
|
452
458
|
eventCallbackId?: string;
|
@@ -462,7 +468,7 @@ export interface AMSCheckoutOptions {
|
|
462
468
|
export interface Ianalytics {
|
463
469
|
enabled: boolean;
|
464
470
|
}
|
465
|
-
export declare enum
|
471
|
+
export declare enum TargetEnum {
|
466
472
|
BLANK = "_blank",
|
467
473
|
SELF = "_self",
|
468
474
|
REPLACE = "_replace"
|
@@ -531,6 +537,7 @@ export interface CashierSubmitPayRequest {
|
|
531
537
|
verifyFactors?: Record<string, string>;
|
532
538
|
paymentSessionData: string;
|
533
539
|
paymentSessionConfig?: any;
|
540
|
+
traceId?: string;
|
534
541
|
extParams?: any;
|
535
542
|
}
|
536
543
|
export interface CashierSdkActionQueryResult {
|
@@ -548,6 +555,7 @@ export interface CashierSdkActionQueryResult {
|
|
548
555
|
normalUrl?: string;
|
549
556
|
applinkUrl?: string;
|
550
557
|
schemeUrl?: string;
|
558
|
+
traceId?: string;
|
551
559
|
authUrl?: string;
|
552
560
|
extendInfo?: {
|
553
561
|
channelOrderId?: string;
|
@@ -593,6 +601,7 @@ export interface CashierSubmitPayResult {
|
|
593
601
|
normalUrl?: string;
|
594
602
|
errorStatus?: string;
|
595
603
|
message?: string;
|
604
|
+
traceId?: string;
|
596
605
|
}
|
597
606
|
export declare enum eventCodeEnum {
|
598
607
|
SDK_START_OF_LOADING = "SDK_START_OF_LOADING",
|
@@ -647,9 +656,28 @@ export declare enum ProductSceneVersion {
|
|
647
656
|
V2 = "2.0"
|
648
657
|
}
|
649
658
|
export type IAppendParams = {
|
650
|
-
componentSign:
|
659
|
+
componentSign: ComponentSignEnum;
|
651
660
|
iframeNodesParams: IappendIframeNodesParams;
|
652
661
|
};
|
662
|
+
export declare enum EventCallbackCode {
|
663
|
+
Failed = "Failed",
|
664
|
+
Completed = "Completed"
|
665
|
+
}
|
666
|
+
export interface IElementOptions {
|
667
|
+
sessionData: string;
|
668
|
+
environment?: string;
|
669
|
+
locale?: string;
|
670
|
+
mode?: string;
|
671
|
+
onEventCallback?: ({ code, message }: {
|
672
|
+
code: EventCallbackCode;
|
673
|
+
message: string;
|
674
|
+
}) => void;
|
675
|
+
loading?: {
|
676
|
+
showLoading: boolean;
|
677
|
+
onStartLoading?: () => void;
|
678
|
+
onEndLoading?: () => void;
|
679
|
+
};
|
680
|
+
}
|
653
681
|
export interface IoptionsAddressParams {
|
654
682
|
environment?: string;
|
655
683
|
locale?: string;
|
package/esm/types/index.js
CHANGED
@@ -11,51 +11,50 @@
|
|
11
11
|
* SDK options
|
12
12
|
*/
|
13
13
|
|
14
|
-
export var
|
15
|
-
|
16
|
-
|
17
|
-
return
|
14
|
+
export var DisplayTypeEnum = /*#__PURE__*/function (DisplayTypeEnum) {
|
15
|
+
DisplayTypeEnum["popup"] = "popup";
|
16
|
+
DisplayTypeEnum["inline"] = "inline";
|
17
|
+
return DisplayTypeEnum;
|
18
18
|
}({});
|
19
19
|
export var ComponentSignEnumV2 = /*#__PURE__*/function (ComponentSignEnumV2) {
|
20
20
|
ComponentSignEnumV2["ELEMENT_PAYMENT"] = "ELEMENT_PAYMENT_ALL";
|
21
21
|
ComponentSignEnumV2["ELEMENT_ADDRESS"] = "ELEMENT_ADDRESS_ALL";
|
22
22
|
return ComponentSignEnumV2;
|
23
23
|
}({});
|
24
|
-
export var
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
return paymentMethodCategoryTypeEnum;
|
24
|
+
export var ComponentSignEnum = /*#__PURE__*/function (ComponentSignEnum) {
|
25
|
+
ComponentSignEnum["EASY_PAY_WALLET"] = "EASY_PAY_WALLET";
|
26
|
+
ComponentSignEnum["EASY_PAY_APM"] = "EASY_PAY_APM";
|
27
|
+
ComponentSignEnum["CASHIER_PAYMENT_CARD"] = "CASHIER_PAYMENT_CARD";
|
28
|
+
ComponentSignEnum["CASHIER_PAYMENT_BANK"] = "CASHIER_PAYMENT_BANK";
|
29
|
+
ComponentSignEnum["CASHIER_PAYMENT_APM"] = "CASHIER_PAYMENT_APM";
|
30
|
+
ComponentSignEnum["AUTO_DEBIT_WALLET"] = "AUTO_DEBIT_WALLET";
|
31
|
+
ComponentSignEnum["AUTO_DEBIT_PAY_WALLET"] = "AUTO_DEBIT_PAY_WALLET";
|
32
|
+
ComponentSignEnum["NONE"] = "NONE";
|
33
|
+
ComponentSignEnum["VAULTING_CARD"] = "VAULTING_CARD";
|
34
|
+
ComponentSignEnum["ELEMENT_PAYMENT"] = "ELEMENT_PAYMENT_ALL";
|
35
|
+
ComponentSignEnum["ELEMENT_ADDRESS"] = "ELEMENT_ADDRESS_ALL";
|
36
|
+
return ComponentSignEnum;
|
37
|
+
}({}); // 'CHECKOUT_PAYMENT' = 'CHECKOUT_PAYMENT',
|
38
|
+
export var ProductSceneEnum = /*#__PURE__*/function (ProductSceneEnum) {
|
39
|
+
ProductSceneEnum["EASY_PAY"] = "EASY_PAY";
|
40
|
+
ProductSceneEnum["CASHIER_PAYMENT"] = "CASHIER_PAYMENT";
|
41
|
+
ProductSceneEnum["AUTO_DEBIT"] = "AUTO_DEBIT";
|
42
|
+
ProductSceneEnum["AUTO_DEBIT_PAY"] = "AUTO_DEBIT_PAY";
|
43
|
+
ProductSceneEnum["VAULTING"] = "VAULTING";
|
44
|
+
ProductSceneEnum["FLASH_BUY"] = "FLASH_BUY";
|
45
|
+
ProductSceneEnum["CARD_APPLE_PAY"] = "CARD_APPLE_PAY";
|
46
|
+
ProductSceneEnum["ELEMENT_PAYMENT"] = "ELEMENT_PAYMENT";
|
47
|
+
ProductSceneEnum["ELEMENT_ADDRESS"] = "ELEMENT_ADDRESS";
|
48
|
+
ProductSceneEnum["CHECKOUT_PAYMENT"] = "CHECKOUT_PAYMENT";
|
49
|
+
return ProductSceneEnum;
|
50
|
+
}({});
|
51
|
+
export var PaymentMethodCategoryTypeEnum = /*#__PURE__*/function (PaymentMethodCategoryTypeEnum) {
|
52
|
+
PaymentMethodCategoryTypeEnum["CARD"] = "CARD";
|
53
|
+
PaymentMethodCategoryTypeEnum["WALLET"] = "WALLET";
|
54
|
+
PaymentMethodCategoryTypeEnum["BANK"] = "BANK";
|
55
|
+
PaymentMethodCategoryTypeEnum["APM"] = "APM";
|
56
|
+
PaymentMethodCategoryTypeEnum["ALL"] = "ALL";
|
57
|
+
return PaymentMethodCategoryTypeEnum;
|
59
58
|
}({});
|
60
59
|
|
61
60
|
/** 表单地址数据 */
|
@@ -88,11 +87,11 @@ export var networkModeEnum = /*#__PURE__*/function (networkModeEnum) {
|
|
88
87
|
networkModeEnum["session"] = "session";
|
89
88
|
return networkModeEnum;
|
90
89
|
}({});
|
91
|
-
export var
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
return
|
90
|
+
export var EnvironmentEnum = /*#__PURE__*/function (EnvironmentEnum) {
|
91
|
+
EnvironmentEnum["sandbox"] = "sandbox";
|
92
|
+
EnvironmentEnum["prod"] = "prod";
|
93
|
+
EnvironmentEnum["light_sandbox"] = "light_sandbox";
|
94
|
+
return EnvironmentEnum;
|
96
95
|
}({});
|
97
96
|
export var osTypeEnum = /*#__PURE__*/function (osTypeEnum) {
|
98
97
|
osTypeEnum["IOS"] = "IOS";
|
@@ -107,10 +106,10 @@ export var terminalTypeEnum = /*#__PURE__*/function (terminalTypeEnum) {
|
|
107
106
|
terminalTypeEnum["MINI_APP"] = "MINI_APP";
|
108
107
|
return terminalTypeEnum;
|
109
108
|
}({});
|
110
|
-
export var
|
111
|
-
|
112
|
-
|
113
|
-
return
|
109
|
+
export var PlatformEnum = /*#__PURE__*/function (PlatformEnum) {
|
110
|
+
PlatformEnum["desktop"] = "desktop";
|
111
|
+
PlatformEnum["mobile"] = "mobile";
|
112
|
+
return PlatformEnum;
|
114
113
|
}({});
|
115
114
|
|
116
115
|
/**
|
@@ -129,17 +128,17 @@ export var platformEnum = /*#__PURE__*/function (platformEnum) {
|
|
129
128
|
* @description Create an event handler, In pop-up layer mode, the user clicks the semi floating layer close button and is called.
|
130
129
|
*/
|
131
130
|
|
132
|
-
export var
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
return
|
137
|
-
}({});
|
138
|
-
export var
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
return
|
131
|
+
export var MessageName = /*#__PURE__*/function (MessageName) {
|
132
|
+
MessageName["SDK_TO_APP"] = "SDK_TO_APP";
|
133
|
+
MessageName["APP_TO_SDK"] = "APP_TO_SDK";
|
134
|
+
MessageName["APP_TO_APP"] = "APP_TO_APP";
|
135
|
+
return MessageName;
|
136
|
+
}({});
|
137
|
+
export var TargetEnum = /*#__PURE__*/function (TargetEnum) {
|
138
|
+
TargetEnum["BLANK"] = "_blank";
|
139
|
+
TargetEnum["SELF"] = "_self";
|
140
|
+
TargetEnum["REPLACE"] = "_replace";
|
141
|
+
return TargetEnum;
|
143
142
|
}({});
|
144
143
|
export var errorEnum = /*#__PURE__*/function (errorEnum) {
|
145
144
|
errorEnum["PARAMS"] = "PARAMS";
|
@@ -208,4 +207,9 @@ export var ProductSceneVersion = /*#__PURE__*/function (ProductSceneVersion) {
|
|
208
207
|
ProductSceneVersion["V1"] = "1.0";
|
209
208
|
ProductSceneVersion["V2"] = "2.0";
|
210
209
|
return ProductSceneVersion;
|
210
|
+
}({});
|
211
|
+
export var EventCallbackCode = /*#__PURE__*/function (EventCallbackCode) {
|
212
|
+
EventCallbackCode["Failed"] = "Failed";
|
213
|
+
EventCallbackCode["Completed"] = "Completed";
|
214
|
+
return EventCallbackCode;
|
211
215
|
}({});
|
package/esm/util/index.d.ts
CHANGED
@@ -4,7 +4,6 @@
|
|
4
4
|
* 1. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE; and
|
5
5
|
* 2. If applicable, the use of the Software is also subject to the terms and conditions of any non-disclosure agreement signed by you and the relevant Ant Group entity.
|
6
6
|
*/
|
7
|
-
declare const getType: (target: any) => string;
|
8
7
|
declare class EventCenter {
|
9
8
|
private events;
|
10
9
|
private eventsKey;
|
@@ -15,6 +14,7 @@ declare class EventCenter {
|
|
15
14
|
once(name: string, func: any, key?: string): void;
|
16
15
|
isExist(name: string): boolean;
|
17
16
|
}
|
17
|
+
declare const getType: (target: any) => string;
|
18
18
|
declare const getViewPort: (key: string) => any;
|
19
19
|
declare const getOrigin: () => string;
|
20
20
|
declare const serialize: (obj: Record<string, string>) => string;
|
package/esm/util/index.js
CHANGED
@@ -12,10 +12,6 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
|
|
12
12
|
* 2. If applicable, the use of the Software is also subject to the terms and conditions of any non-disclosure agreement signed by you and the relevant Ant Group entity.
|
13
13
|
*/
|
14
14
|
/* eslint-disable @typescript-eslint/no-explicit-any */
|
15
|
-
|
16
|
-
var getType = function getType(target) {
|
17
|
-
return Object.prototype.toString.call(target).slice(8, -1).toLowerCase();
|
18
|
-
};
|
19
15
|
var EventCenter = /*#__PURE__*/function () {
|
20
16
|
function EventCenter() {
|
21
17
|
_classCallCheck(this, EventCenter);
|
@@ -91,6 +87,9 @@ var EventCenter = /*#__PURE__*/function () {
|
|
91
87
|
}]);
|
92
88
|
return EventCenter;
|
93
89
|
}();
|
90
|
+
var getType = function getType(target) {
|
91
|
+
return Object.prototype.toString.call(target).slice(8, -1).toLowerCase();
|
92
|
+
};
|
94
93
|
var getViewPort = function getViewPort(key) {
|
95
94
|
var meta = document.getElementsByTagName('meta');
|
96
95
|
// HTMLMetaElement
|