@alipay/ams-checkout 0.0.1730706734-dev.0 → 0.0.1730878287-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.
Files changed (126) hide show
  1. package/dist/umd/ams-checkout.min.js +1 -1
  2. package/esm/config/index.d.ts +2 -2
  3. package/esm/config/index.js +5 -5
  4. package/esm/constant/index.d.ts +0 -6
  5. package/esm/constant/index.js +0 -8
  6. package/esm/core/bus/interface.d.ts +0 -12
  7. package/esm/core/bus/interface.js +2 -16
  8. package/esm/core/component/address.d.ts +2 -2
  9. package/esm/core/component/appPreloadProcessing.js +0 -2
  10. package/esm/core/component/ckp/index.d.ts +3 -3
  11. package/esm/core/component/ckp/index.js +3 -3
  12. package/esm/core/component/index.d.ts +5 -5
  13. package/esm/core/component/index.js +16 -20
  14. package/esm/core/drop-in/index.d.ts +2 -2
  15. package/esm/core/drop-in/index.js +2 -2
  16. package/esm/core/instance/index.d.ts +5 -5
  17. package/esm/core/instance/index.js +10 -11
  18. package/esm/index.d.ts +10 -16
  19. package/esm/index.js +59 -70
  20. package/esm/plugin/applepay/component.js +3 -3
  21. package/esm/plugin/applepay/service.d.ts +2 -2
  22. package/esm/plugin/applepay/service.js +2 -2
  23. package/esm/plugin/component/cashierApp.d.ts +5 -7
  24. package/esm/plugin/component/cashierApp.js +8 -16
  25. package/esm/plugin/component/channel.d.ts +4 -4
  26. package/esm/plugin/component/component.inline.style.d.ts +4 -4
  27. package/esm/plugin/component/component.inline.style.js +7 -10
  28. package/esm/plugin/component/component.popup.style.d.ts +6 -15
  29. package/esm/plugin/component/component.popup.style.js +15 -33
  30. package/esm/plugin/component/index.d.ts +7 -7
  31. package/esm/plugin/component/index.js +90 -113
  32. package/esm/plugin/const.js +5 -5
  33. package/esm/plugin/drop-in/index.d.ts +5 -5
  34. package/esm/plugin/drop-in/index.js +7 -7
  35. package/esm/plugin/payment-element/utils.d.ts +1 -1
  36. package/esm/plugin/payment-element/utils.js +1 -2
  37. package/esm/plugin/type.d.ts +4 -4
  38. package/esm/service/index.d.ts +0 -1
  39. package/esm/service/index.js +0 -2
  40. package/esm/types/index.d.ts +38 -240
  41. package/esm/types/index.js +59 -103
  42. package/esm/util/createIframeNode.d.ts +2 -2
  43. package/esm/util/createIframeNode.js +3 -3
  44. package/esm/util/index.d.ts +1 -1
  45. package/esm/util/index.js +4 -3
  46. package/esm/{foundation/service/security → util}/security.d.ts +2 -2
  47. package/esm/{foundation/service/security → util}/security.js +3 -3
  48. package/package.json +1 -2
  49. package/esm/core/bus/ability/globalData.d.ts +0 -10
  50. package/esm/core/bus/ability/globalData.js +0 -89
  51. package/esm/core/bus/ability/request.d.ts +0 -10
  52. package/esm/core/bus/ability/request.js +0 -151
  53. package/esm/core/component/element/components/address.d.ts +0 -19
  54. package/esm/core/component/element/components/address.js +0 -68
  55. package/esm/core/component/element/components/auth.d.ts +0 -17
  56. package/esm/core/component/element/components/auth.js +0 -59
  57. package/esm/core/component/element/components/payment.d.ts +0 -19
  58. package/esm/core/component/element/components/payment.js +0 -74
  59. package/esm/core/component/element/element-mock.d.ts +0 -2
  60. package/esm/core/component/element/element-mock.js +0 -263
  61. package/esm/core/component/element/index.d.ts +0 -47
  62. package/esm/core/component/element/index.js +0 -776
  63. package/esm/core/component/element/mock.d.ts +0 -3
  64. package/esm/core/component/element/mock.js +0 -1156
  65. package/esm/core/component/element/type.d.ts +0 -176
  66. package/esm/core/component/element/type.js +0 -34
  67. package/esm/core/component/element/utils.d.ts +0 -13
  68. package/esm/core/component/element/utils.js +0 -6
  69. package/esm/foundation/core/index.d.ts +0 -26
  70. package/esm/foundation/core/index.js +0 -301
  71. package/esm/foundation/index.d.ts +0 -72
  72. package/esm/foundation/index.js +0 -42
  73. package/esm/foundation/product-processor/easysafepay/deps.d.ts +0 -15
  74. package/esm/foundation/product-processor/easysafepay/deps.js +0 -9
  75. package/esm/foundation/product-processor/easysafepay/index.d.ts +0 -26
  76. package/esm/foundation/product-processor/easysafepay/index.js +0 -536
  77. package/esm/foundation/service/container/index.d.ts +0 -28
  78. package/esm/foundation/service/container/index.js +0 -256
  79. package/esm/foundation/service/container/popup.d.ts +0 -17
  80. package/esm/foundation/service/container/popup.js +0 -103
  81. package/esm/foundation/service/container/utils.d.ts +0 -7
  82. package/esm/foundation/service/container/utils.js +0 -48
  83. package/esm/foundation/service/event-bus/ability/callback.d.ts +0 -9
  84. package/esm/foundation/service/event-bus/ability/callback.js +0 -55
  85. package/esm/foundation/service/event-bus/ability/globalData.d.ts +0 -10
  86. package/esm/foundation/service/event-bus/ability/globalData.js +0 -89
  87. package/esm/foundation/service/event-bus/ability/request.d.ts +0 -10
  88. package/esm/foundation/service/event-bus/ability/request.js +0 -151
  89. package/esm/foundation/service/event-bus/ability/security.d.ts +0 -12
  90. package/esm/foundation/service/event-bus/ability/security.js +0 -151
  91. package/esm/foundation/service/event-bus/ability/tracker.d.ts +0 -9
  92. package/esm/foundation/service/event-bus/ability/tracker.js +0 -80
  93. package/esm/foundation/service/event-bus/busManager.d.ts +0 -127
  94. package/esm/foundation/service/event-bus/busManager.js +0 -398
  95. package/esm/foundation/service/event-bus/index.d.ts +0 -20
  96. package/esm/foundation/service/event-bus/index.js +0 -88
  97. package/esm/foundation/service/event-center.d.ts +0 -75
  98. package/esm/foundation/service/event-center.js +0 -244
  99. package/esm/foundation/service/global-data/index.d.ts +0 -11
  100. package/esm/foundation/service/global-data/index.js +0 -69
  101. package/esm/foundation/service/index.d.ts +0 -19
  102. package/esm/foundation/service/index.js +0 -82
  103. package/esm/foundation/service/log/index.d.ts +0 -43
  104. package/esm/foundation/service/log/index.js +0 -235
  105. package/esm/foundation/service/log/types.d.ts +0 -32
  106. package/esm/foundation/service/log/types.js +0 -1
  107. package/esm/foundation/service/requester/deps.d.ts +0 -17
  108. package/esm/foundation/service/requester/deps.js +0 -11
  109. package/esm/foundation/service/requester/requester.d.ts +0 -22
  110. package/esm/foundation/service/requester/requester.js +0 -211
  111. package/esm/foundation/service/security/index.d.ts +0 -26
  112. package/esm/foundation/service/security/index.js +0 -216
  113. package/esm/foundation/types/index.d.ts +0 -4
  114. package/esm/foundation/types/index.js +0 -4
  115. package/esm/foundation/utils/gray_scale_utils.d.ts +0 -7
  116. package/esm/foundation/utils/gray_scale_utils.js +0 -40
  117. package/esm/foundation/utils/payment_context_utils.d.ts +0 -13
  118. package/esm/foundation/utils/payment_context_utils.js +0 -57
  119. package/esm/foundation/utils/redirect_utils.d.ts +0 -6
  120. package/esm/foundation/utils/redirect_utils.js +0 -99
  121. package/esm/foundation/utils/system_events.d.ts +0 -4
  122. package/esm/foundation/utils/system_events.js +0 -71
  123. package/esm/foundation/utils/web_app_url_utils.d.ts +0 -37
  124. package/esm/foundation/utils/web_app_url_utils.js +0 -97
  125. package/esm/service/element.d.ts +0 -4
  126. package/esm/service/element.js +0 -51
@@ -1,19 +0,0 @@
1
- import { AddressMountComponentsParams } from '../type';
2
- interface ElementAddressMountOptions extends Omit<AddressMountComponentsParams, 'type'> {
3
- selector: string;
4
- }
5
- export declare class ElementAddressComponent {
6
- private sdk;
7
- private elementContainer;
8
- private isConnect;
9
- constructor();
10
- create(options: {
11
- environment: string;
12
- locale: string;
13
- appVersion: string;
14
- }, isConnect: boolean): void;
15
- mount(sessionData: string, options: ElementAddressMountOptions): Promise<HTMLIFrameElement | undefined>;
16
- update(): void;
17
- unmount(): void;
18
- }
19
- export {};
@@ -1,68 +0,0 @@
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 _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
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); } }
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; }
6
- function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
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); }
8
- import { AddressComponent } from "../../address";
9
- export var ElementAddressComponent = /*#__PURE__*/function () {
10
- function ElementAddressComponent() {
11
- _classCallCheck(this, ElementAddressComponent);
12
- _defineProperty(this, "sdk", void 0);
13
- _defineProperty(this, "elementContainer", void 0);
14
- _defineProperty(this, "isConnect", void 0);
15
- }
16
- _createClass(ElementAddressComponent, [{
17
- key: "create",
18
- value: function create(options, isConnect) {
19
- this.isConnect = isConnect;
20
- this.sdk = new AddressComponent(options);
21
- }
22
- }, {
23
- key: "mount",
24
- value: function mount(sessionData, options) {
25
- var _this = this;
26
- var elementContainer = document.querySelector(options.selector);
27
- if (this.isConnect) {
28
- elementContainer.style.display = 'none';
29
- }
30
- return new Promise(function (resolve) {
31
- _this.sdk.mountComponent({
32
- sessionData: sessionData,
33
- debugProps: options.debugProps,
34
- configParams: options.configParams,
35
- appearance: options.appearance,
36
- prefillValue: options.prefillValue,
37
- appendAliasContainerId: true
38
- }, options.selector).then(function () {
39
- var _elementContainer$get;
40
- _this.elementContainer = elementContainer;
41
- var iframes = elementContainer === null || elementContainer === void 0 || (_elementContainer$get = elementContainer.getElementsByTagName) === null || _elementContainer$get === void 0 ? void 0 : _elementContainer$get.call(elementContainer, 'iframe');
42
- resolve(iframes === null || iframes === void 0 ? void 0 : iframes[0]);
43
- }, function () {
44
- resolve(undefined);
45
- });
46
- });
47
- }
48
- }, {
49
- key: "update",
50
- value: function update() {
51
- if (this.elementContainer && this.isConnect) {
52
- this.elementContainer.style.display = '';
53
- }
54
- // 下发数据
55
- }
56
- }, {
57
- key: "unmount",
58
- value: function unmount() {
59
- var _this$elementContaine, _this$elementContaine2;
60
- var containers = (_this$elementContaine = this.elementContainer) === null || _this$elementContaine === void 0 || (_this$elementContaine2 = _this$elementContaine.getElementsByTagName) === null || _this$elementContaine2 === void 0 ? void 0 : _this$elementContaine2.call(_this$elementContaine, 'div');
61
- if (containers !== null && containers !== void 0 && containers[0]) {
62
- var _containers$, _containers$$remove;
63
- (_containers$ = containers[0]) === null || _containers$ === void 0 || (_containers$$remove = _containers$.remove) === null || _containers$$remove === void 0 || _containers$$remove.call(_containers$);
64
- }
65
- }
66
- }]);
67
- return ElementAddressComponent;
68
- }();
@@ -1,17 +0,0 @@
1
- import { LinkAuthMountOptions } from '../type';
2
- interface ElementAuthMountOptions extends Omit<LinkAuthMountOptions, 'type' | 'debugProps'> {
3
- selector: string;
4
- url: string;
5
- }
6
- export declare class ElementAuthComponent {
7
- private elementContainer;
8
- constructor();
9
- create(options: {
10
- environment: string;
11
- locale: string;
12
- }): void;
13
- mount(options: ElementAuthMountOptions): Promise<HTMLIFrameElement | undefined>;
14
- update(height?: number): void;
15
- unmount(): void;
16
- }
17
- export {};
@@ -1,59 +0,0 @@
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 _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
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); } }
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; }
6
- function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
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); }
8
- import { createIframe } from "../../../../foundation/service/container/utils";
9
- import { createInlineBaseElement } from "../../../../plugin/component/component.inline.style";
10
- export var ElementAuthComponent = /*#__PURE__*/function () {
11
- function ElementAuthComponent() {
12
- _classCallCheck(this, ElementAuthComponent);
13
- _defineProperty(this, "elementContainer", void 0);
14
- }
15
- _createClass(ElementAuthComponent, [{
16
- key: "create",
17
- value: function create(options) {}
18
- }, {
19
- key: "mount",
20
- value: function mount(options) {
21
- var _this = this;
22
- return new Promise(function (resolve) {
23
- try {
24
- var selector = options.selector,
25
- url = options.url;
26
- var containerSelector = "antom-sdk-web-app-".concat(selector);
27
- var container = createInlineBaseElement(selector);
28
- var webApp = createIframe(containerSelector);
29
- webApp.src = url;
30
- container.appendChild(webApp);
31
- _this.elementContainer = container;
32
- resolve(webApp);
33
- } catch (error) {
34
- resolve(undefined);
35
- }
36
- });
37
- }
38
- }, {
39
- key: "update",
40
- value: function update() {
41
- var _this$elementContaine, _this$elementContaine2;
42
- var height = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 100;
43
- var iframes = (_this$elementContaine = this.elementContainer) === null || _this$elementContaine === void 0 || (_this$elementContaine2 = _this$elementContaine.getElementsByTagName) === null || _this$elementContaine2 === void 0 ? void 0 : _this$elementContaine2.call(_this$elementContaine, 'iframe');
44
- if (iframes !== null && iframes !== void 0 && iframes[0]) {
45
- var iframe = iframes[0];
46
- iframe.style.opacity = '1';
47
- iframe.style.overflow = 'visible';
48
- iframe.style.height = "".concat(height, "px");
49
- }
50
- }
51
- }, {
52
- key: "unmount",
53
- value: function unmount() {
54
- var _this$elementContaine3, _this$elementContaine4;
55
- (_this$elementContaine3 = this.elementContainer) === null || _this$elementContaine3 === void 0 || (_this$elementContaine4 = _this$elementContaine3.remove) === null || _this$elementContaine4 === void 0 || _this$elementContaine4.call(_this$elementContaine3);
56
- }
57
- }]);
58
- return ElementAuthComponent;
59
- }();
@@ -1,19 +0,0 @@
1
- import { PaymentMountOptions } from '../type';
2
- interface ElementPaymentMountOptions extends Omit<PaymentMountOptions, 'type'> {
3
- selector: string;
4
- }
5
- export declare class ElementPaymentComponent {
6
- private sdk;
7
- private elementContainer;
8
- private isConnect;
9
- constructor();
10
- create(options: {
11
- environment: string;
12
- locale: string;
13
- appVersion: string;
14
- }, isConnect: boolean): void;
15
- mount(sessionData: string, options: ElementPaymentMountOptions): Promise<HTMLIFrameElement | undefined>;
16
- update(): void;
17
- unmount(): void;
18
- }
19
- export {};
@@ -1,74 +0,0 @@
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 ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
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 _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
5
- 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
- function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
7
- 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; }
8
- function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
9
- 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); }
10
- import AMSPaymentElement from "../../../../index";
11
- export var ElementPaymentComponent = /*#__PURE__*/function () {
12
- function ElementPaymentComponent() {
13
- _classCallCheck(this, ElementPaymentComponent);
14
- _defineProperty(this, "sdk", void 0);
15
- _defineProperty(this, "elementContainer", void 0);
16
- _defineProperty(this, "isConnect", void 0);
17
- }
18
- _createClass(ElementPaymentComponent, [{
19
- key: "create",
20
- value: function create(options, isConnect) {
21
- this.isConnect = isConnect;
22
- this.sdk = new AMSPaymentElement(_objectSpread(_objectSpread({}, options), {}, {
23
- analytics: {
24
- enabled: true
25
- },
26
- onEventCallback: function onEventCallback(state) {}
27
- }));
28
- }
29
- }, {
30
- key: "mount",
31
- value: function mount(sessionData, options) {
32
- var _this = this;
33
- var elementContainer = document.querySelector(options.selector);
34
- if (this.isConnect) {
35
- elementContainer.style.display = 'none';
36
- }
37
- return new Promise(function (resolve) {
38
- _this.sdk.mountComponent({
39
- sessionData: sessionData,
40
- appearance: options.appearance,
41
- debugProps: options.debugProps,
42
- notRedirectAfterComplete: true,
43
- appendAliasContainerId: true
44
- }, options.selector).then(function () {
45
- var _elementContainer$get;
46
- _this.elementContainer = elementContainer;
47
- var iframes = elementContainer === null || elementContainer === void 0 || (_elementContainer$get = elementContainer.getElementsByTagName) === null || _elementContainer$get === void 0 ? void 0 : _elementContainer$get.call(elementContainer, 'iframe');
48
- resolve(iframes === null || iframes === void 0 ? void 0 : iframes[0]);
49
- }, function () {
50
- resolve(undefined);
51
- });
52
- });
53
- }
54
- }, {
55
- key: "update",
56
- value: function update() {
57
- if (this.elementContainer && this.isConnect) {
58
- this.elementContainer.style.display = 'initial';
59
- }
60
- // 下发数据
61
- }
62
- }, {
63
- key: "unmount",
64
- value: function unmount() {
65
- var _this$elementContaine, _this$elementContaine2;
66
- var containers = (_this$elementContaine = this.elementContainer) === null || _this$elementContaine === void 0 || (_this$elementContaine2 = _this$elementContaine.getElementsByTagName) === null || _this$elementContaine2 === void 0 ? void 0 : _this$elementContaine2.call(_this$elementContaine, 'div');
67
- if (containers !== null && containers !== void 0 && containers[0]) {
68
- var _containers$, _containers$$remove;
69
- (_containers$ = containers[0]) === null || _containers$ === void 0 || (_containers$$remove = _containers$.remove) === null || _containers$$remove === void 0 || _containers$$remove.call(_containers$);
70
- }
71
- }
72
- }]);
73
- return ElementPaymentComponent;
74
- }();
@@ -1,2 +0,0 @@
1
- export declare const sdkAction: any;
2
- export declare const oneAccount: any;
@@ -1,263 +0,0 @@
1
- export var sdkAction = {
2
- amountConfirmRequired: false,
3
- autoDebitWithToken: false,
4
- errorActions: {},
5
- extendInfo: {},
6
- links: {},
7
- needInstallmentAbility: false,
8
- needOtherElements: false,
9
- openPopPaymentRetryAbility: 'Y',
10
- orderAmount: {
11
- amount: '288.86',
12
- currency: 'USD',
13
- currencyLabel: 'US $',
14
- formattedAmount: '288.86',
15
- formattedAmountWithCurrency: 'US $288.86',
16
- value: '28886'
17
- },
18
- orderAmountView: {
19
- currency: 'USD',
20
- currencyDivider: ' ',
21
- currencyLabel: '$',
22
- currencySymbolPosition: 'L',
23
- formattedValue: '288.86',
24
- value: '288.86'
25
- },
26
- paymentAmount: {
27
- amount: '288.86',
28
- currency: 'USD',
29
- currencyLabel: 'US $',
30
- formattedAmount: '288.86',
31
- formattedAmountWithCurrency: 'US $288.86',
32
- value: '28886'
33
- },
34
- paymentAmountView: {
35
- currency: 'USD',
36
- currencyDivider: ' ',
37
- currencyLabel: '$',
38
- currencySymbolPosition: 'L',
39
- formattedValue: '288.86',
40
- value: '288.86'
41
- },
42
- paymentMethods: [{
43
- antomPage: 'paymentMetaPage',
44
- category: 'AC_WALLET',
45
- expressCheckout: false,
46
- icon: 'https://cdn.marmot-cloud.com/storage/2024/05/15/8c2df293-4ff8-4a1c-bd39-457c26937acb.svg',
47
- iconName: 'Rabbit LINE Pay',
48
- interActionType: 'SHOW_CODE',
49
- paymentMethodName: 'Rabbit LINE Pay',
50
- paymentMethodType: 'RABBIT_LINE_PAY',
51
- recommend: false,
52
- webRedirectType: 'PAGE_REFRESH'
53
- }, {
54
- antomPage: 'paymentMetaPage',
55
- category: 'AC_WALLET',
56
- expressCheckout: false,
57
- icon: 'https://cdn.marmot-cloud.com/storage/2024/05/15/72aa8973-7638-4f3f-b657-7af0ae02e6cf.svg',
58
- iconName: 'BPI',
59
- interActionType: 'SHOW_CODE',
60
- paymentMethodName: 'BPI',
61
- paymentMethodType: 'BPI',
62
- recommend: false,
63
- webRedirectType: 'PAGE_REFRESH'
64
- }, {
65
- antomPage: 'paymentMetaPage',
66
- category: 'AC_WALLET',
67
- expressCheckout: true,
68
- icon: 'https://cdn.marmot-cloud.com/storage/2024/05/15/5b829130-42d9-46e7-a23d-6774f7352900.svg',
69
- iconName: 'Alipay',
70
- interActionType: 'SHOW_CODE',
71
- paymentMethodName: 'Alipay',
72
- paymentMethodType: 'ALIPAY_CN',
73
- recommend: false,
74
- webRedirectType: 'PAGE_REFRESH'
75
- }, {
76
- antomPage: 'paymentMetaPage',
77
- category: 'AC_WALLET',
78
- expressCheckout: false,
79
- icon: 'https://cdn.marmot-cloud.com/storage/2024/05/15/ed012d1a-06c4-4606-a493-0d81ead685b6.svg',
80
- iconName: 'Akulaku PayLater',
81
- interActionType: 'SHOW_CODE',
82
- paymentMethodName: 'Akulaku PayLater PH',
83
- paymentMethodType: 'AKULAKU_PAYLATER_PH',
84
- recommend: false,
85
- webRedirectType: 'PAGE_REFRESH'
86
- }, {
87
- antomPage: 'paymentMetaPage',
88
- category: 'AC_WALLET',
89
- expressCheckout: false,
90
- icon: 'https://cdn.marmot-cloud.com/storage/2024/05/15/ed012d1a-06c4-4606-a493-0d81ead685b6.svg',
91
- iconName: 'Akulaku PayLater',
92
- interActionType: 'SHOW_CODE',
93
- paymentMethodName: 'Akulaku PayLater',
94
- paymentMethodType: 'AKULAKU_PAYLATER',
95
- recommend: false,
96
- webRedirectType: 'PAGE_REFRESH'
97
- }, {
98
- antomPage: 'paymentMetaPage',
99
- category: 'AC_WALLET',
100
- expressCheckout: false,
101
- icon: 'https://cdn.marmot-cloud.com/storage/2024/05/15/fcf9ba5e-b2b4-4c33-a041-f21bcf1539e4.svg',
102
- iconName: 'BillEase',
103
- interActionType: 'SHOW_CODE',
104
- paymentMethodName: 'BILLEASE',
105
- paymentMethodType: 'BILLEASE',
106
- recommend: false,
107
- webRedirectType: 'PAGE_REFRESH'
108
- }, {
109
- antomPage: 'paymentMetaPage',
110
- category: 'AC_WALLET',
111
- expressCheckout: false,
112
- icon: 'https://cdn.marmot-cloud.com/storage/2024/05/15/dfcedf07-3135-49b6-9e39-6ab89b5ba5a1.svg',
113
- iconName: 'Kredivo',
114
- interActionType: 'SHOW_CODE',
115
- paymentMethodName: 'KREDIVO',
116
- paymentMethodType: 'KREDIVO_ID',
117
- recommend: false,
118
- webRedirectType: 'PAGE_REFRESH'
119
- }, {
120
- antomPage: 'paymentMetaPage',
121
- category: 'AC_WALLET',
122
- expressCheckout: false,
123
- icon: 'https://cdn.marmot-cloud.com/storage/2024/05/15/6c7baedf-cb9e-47b1-8c2e-d2477b0d3018.svg',
124
- iconName: 'Toss Pay',
125
- interActionType: 'SHOW_CODE',
126
- paymentMethodName: 'Toss Pay',
127
- paymentMethodType: 'TOSSPAY',
128
- recommend: false,
129
- webRedirectType: 'PAGE_REFRESH'
130
- }, {
131
- antomPage: 'paymentMetaPage',
132
- category: 'AC_WALLET',
133
- expressCheckout: false,
134
- icon: 'https://cdn.marmot-cloud.com/storage/2024/05/15/89c1063e-c7d3-4b60-82a0-6e4c40426612.svg',
135
- iconName: 'Kakao Pay',
136
- interActionType: 'SHOW_CODE',
137
- paymentMethodName: 'KAKAOPAY',
138
- paymentMethodType: 'KAKAOPAY',
139
- recommend: false,
140
- webRedirectType: 'PAGE_REFRESH'
141
- }, {
142
- antomPage: 'paymentMetaPage',
143
- category: 'AC_WALLET',
144
- expressCheckout: false,
145
- icon: 'https://cdn.marmot-cloud.com/storage/2024/05/15/46ac203c-21fd-4feb-80c6-fd19faf1a9b7.svg',
146
- iconName: 'GCash',
147
- interActionType: 'SHOW_CODE',
148
- paymentMethodName: 'GCash',
149
- paymentMethodType: 'GCASH',
150
- recommend: false,
151
- webRedirectType: 'PAGE_REFRESH'
152
- }, {
153
- antomPage: 'paymentMetaPage',
154
- category: 'AC_WALLET',
155
- expressCheckout: false,
156
- icon: 'https://cdn.marmot-cloud.com/storage/2024/05/15/8409ec96-3153-4d31-9bcb-a6b60f6ce11f.svg',
157
- iconName: 'Boost',
158
- interActionType: 'SHOW_CODE',
159
- paymentMethodName: 'Boost',
160
- paymentMethodType: 'BOOST',
161
- recommend: false,
162
- webRedirectType: 'PAGE_REFRESH'
163
- }, {
164
- antomPage: 'paymentMetaPage',
165
- category: 'AC_WALLET',
166
- expressCheckout: false,
167
- icon: 'https://cdn.marmot-cloud.com/storage/2024/05/15/dd81e7d9-d845-434e-95b8-87b726d44aa4.svg',
168
- iconName: 'DOKU',
169
- interActionType: 'SHOW_CODE',
170
- paymentMethodName: 'DOKU',
171
- paymentMethodType: 'DOKU',
172
- recommend: false,
173
- webRedirectType: 'PAGE_REFRESH'
174
- }, {
175
- antomPage: 'paymentMetaPage',
176
- category: 'AC_WALLET',
177
- expressCheckout: false,
178
- icon: 'https://cdn.marmot-cloud.com/storage/2024/05/15/2ec693a8-2c42-4efe-8acd-efdeeabd3210.svg',
179
- iconName: 'K PLUS',
180
- interActionType: 'SHOW_CODE',
181
- paymentMethodName: 'KPLUS',
182
- paymentMethodType: 'KPLUS',
183
- recommend: false,
184
- webRedirectType: 'PAGE_REFRESH'
185
- }, {
186
- antomPage: 'paymentMetaPage',
187
- category: 'AC_WALLET',
188
- expressCheckout: false,
189
- icon: 'https://cdn.marmot-cloud.com/storage/2024/05/15/82288753-bc33-4f4c-9c07-e54c5da5c8f8.svg',
190
- iconName: "Touch'n Go eWallet",
191
- interActionType: 'SHOW_CODE',
192
- paymentMethodName: 'TNG',
193
- paymentMethodType: 'TNG',
194
- recommend: false,
195
- webRedirectType: 'PAGE_REFRESH'
196
- }, {
197
- antomPage: 'paymentMetaPage',
198
- category: 'AC_WALLET',
199
- expressCheckout: false,
200
- icon: 'https://cdn.marmot-cloud.com/storage/2024/05/15/db94babb-71db-42c4-80be-a65de641631a.svg',
201
- iconName: 'NAVER Pay',
202
- interActionType: 'SHOW_CODE',
203
- paymentMethodName: 'NAVER Pay',
204
- paymentMethodType: 'NAVERPAY',
205
- recommend: false,
206
- webRedirectType: 'PAGE_REFRESH'
207
- }, {
208
- antomPage: 'paymentMetaPage',
209
- category: 'AC_WALLET',
210
- expressCheckout: false,
211
- icon: 'https://cdn.marmot-cloud.com/storage/2024/05/15/5b1ec246-b49f-4390-b356-3af2af5acf09.svg',
212
- iconName: 'TrueMoney',
213
- interActionType: 'SHOW_CODE',
214
- paymentMethodName: 'TrueMoney Wallet',
215
- paymentMethodType: 'TRUEMONEY',
216
- recommend: false,
217
- webRedirectType: 'PAGE_REFRESH'
218
- }, {
219
- antomPage: 'paymentMetaPage',
220
- category: 'AC_WALLET',
221
- expressCheckout: false,
222
- icon: 'https://cdn.marmot-cloud.com/storage/2024/05/15/97dbcec8-7bdd-464b-b49a-5d9af6d98c0b.svg',
223
- iconName: 'AlipayHK',
224
- interActionType: 'SHOW_CODE',
225
- paymentMethodName: 'ALIPAY_HK',
226
- paymentMethodType: 'ALIPAY_HK',
227
- recommend: false,
228
- webRedirectType: 'PAGE_REFRESH'
229
- }, {
230
- antomPage: 'paymentMetaPage',
231
- category: 'AC_WALLET',
232
- expressCheckout: false,
233
- icon: 'https://cdn.marmot-cloud.com/storage/2024/05/15/6148dd94-9d28-43d5-9073-c99bfb8e7ace.svg',
234
- iconName: 'DANA',
235
- interActionType: 'SHOW_CODE',
236
- paymentMethodName: 'DANA',
237
- paymentMethodType: 'DANA',
238
- recommend: false,
239
- webRedirectType: 'PAGE_REFRESH'
240
- }],
241
- redirectUrl: 'https://www.baidu.com',
242
- savedPaymentMethods: [],
243
- success: true
244
- };
245
- export var oneAccount = {
246
- accountInfo: {
247
- accountStatus: 'EFFECTIVE',
248
- email: 'like.xh@antgroup.com'
249
- },
250
- actionForm: {
251
- challengeAutoTriggered: false,
252
- challengeRetrySupported: true,
253
- challengeType: 'EMAIL_OTP',
254
- estimatedDuration: 0,
255
- resendLeftTimes: 0,
256
- verifyId: 'q4gtI6ONJab5bnuGyf5f0gm4D2AyXfKh'
257
- },
258
- errorActions: {},
259
- extendInfo: {},
260
- paymentMethods: [],
261
- shippings: [],
262
- success: true
263
- };
@@ -1,47 +0,0 @@
1
- import { IElementOptions } from '../../../types';
2
- import type { AddressMountOptions, AddressMountResult, LinkAuthMountOptions, LinkAuthMountResult, PaymentMountOptions, PaymentMountResult } from './type';
3
- export declare class ElementComponent {
4
- private parseData;
5
- private loading;
6
- private sessionData;
7
- private elementContainer;
8
- private authBase;
9
- private addressBase;
10
- private paymentBase;
11
- private _options;
12
- private eventService;
13
- private requestService;
14
- private sdkActionRes;
15
- private oneAccountRes;
16
- private launchSource;
17
- private isConnect;
18
- private iframeSrc;
19
- private mountOptions;
20
- private iframes;
21
- private componentsCount;
22
- private eventCallback;
23
- constructor(options: IElementOptions);
24
- private createElement;
25
- private createIframeSrc;
26
- private addListener;
27
- private launchFunc;
28
- private showIframe;
29
- private afterInit;
30
- private sendRenderData;
31
- private removeListener;
32
- private registerEventListener;
33
- private mountAuth;
34
- private mountAddress;
35
- private mountPayment;
36
- mount(renderOptions: AddressMountOptions, sdkSelector: string): AddressMountResult;
37
- mount(renderOptions: PaymentMountOptions, sdkSelector: string): PaymentMountResult;
38
- mount(renderOptions: LinkAuthMountOptions, sdkSelector: string): LinkAuthMountResult;
39
- private removeIframe;
40
- unmount(): void;
41
- private onAfterSubmitFunc;
42
- private onSubmitRiskFunc;
43
- private onSubmit;
44
- private onValidateFunc;
45
- private validatePromiseFuncs;
46
- submitPayment(): Promise<void>;
47
- }