@alipay/ams-checkout 0.0.1717141544-dev.3 → 0.0.1717141544-dev.5

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.
@@ -81,6 +81,7 @@ export default class ComponentApp {
81
81
  _handleAppMessage(data: eventPayload): void;
82
82
  private dismissLoadingFunc;
83
83
  private handleSizeChanged;
84
+ private handleAuthUrlInfo;
84
85
  private handleRedirect;
85
86
  private handleDeclareInfo;
86
87
  private handleDeclarePopWindowCallback;
@@ -247,6 +247,10 @@ var ComponentApp = /*#__PURE__*/function () {
247
247
  key: "appendIframeNodes",
248
248
  value: function appendIframeNodes(componentSign, renderParams) {
249
249
  var _renderParams,
250
+ _this$_renderParams5,
251
+ _this$_renderParams6,
252
+ _this$_renderParams7,
253
+ _this$_renderParams8,
250
254
  _this3 = this;
251
255
  if (this._isInitComponent) {
252
256
  this.dispatchToSDK(EVENT.error.name, ERRORMESSAGE.CREATECOMPONENT_ERROR.SINGLETON_COMPONENT_ERROR);
@@ -266,6 +270,49 @@ var ComponentApp = /*#__PURE__*/function () {
266
270
  key: 'sdk_create_component',
267
271
  value: Date.now()
268
272
  });
273
+ var params = {
274
+ paymentSessionData: this._renderParams && ((_this$_renderParams5 = this._renderParams) === null || _this$_renderParams5 === void 0 ? void 0 : _this$_renderParams5.sessionData) || '',
275
+ paymentSessionConfig: (_this$_renderParams6 = this._renderParams) === null || _this$_renderParams6 === void 0 || (_this$_renderParams6 = _this$_renderParams6.paymentSessionMetaData) === null || _this$_renderParams6 === void 0 ? void 0 : _this$_renderParams6.paymentSessionConfig
276
+ };
277
+ var _ref2 = params.paymentSessionConfig || {},
278
+ _ref2$productSceneVer = _ref2.productSceneVersion,
279
+ productSceneVersion = _ref2$productSceneVer === void 0 ? '' : _ref2$productSceneVer,
280
+ _ref2$productScene = _ref2.productScene,
281
+ productScene = _ref2$productScene === void 0 ? '' : _ref2$productScene;
282
+ var _ref3 = ((_this$_renderParams7 = this._renderParams) === null || _this$_renderParams7 === void 0 ? void 0 : _this$_renderParams7.paymentSessionMetaData) || {},
283
+ _ref3$action = _ref3.action,
284
+ _ref3$action2 = _ref3$action === void 0 ? {} : _ref3$action,
285
+ _ref3$action2$autoDeb = _ref3$action2.autoDebitWithToken,
286
+ autoDebitWithToken = _ref3$action2$autoDeb === void 0 ? false : _ref3$action2$autoDeb,
287
+ _ref3$action2$require = _ref3$action2.requireFastSdk,
288
+ requireFastSdk = _ref3$action2$require === void 0 ? false : _ref3$action2$require;
289
+ var _ref4 = ((_this$_renderParams8 = this._renderParams) === null || _this$_renderParams8 === void 0 ? void 0 : _this$_renderParams8.paymentSessionMetaData) || {},
290
+ _ref4$authUrlInfo = _ref4.authUrlInfo,
291
+ authUrlInfo = _ref4$authUrlInfo === void 0 ? {} : _ref4$authUrlInfo;
292
+ this.AMSSDK.logger.logInfo({
293
+ title: 'sdk_event_createComponent'
294
+ }, {
295
+ version: productSceneVersion,
296
+ product: this.AMSSDK.options.product
297
+ }).send();
298
+ if (componentSignEnum.EASY_PAY_WALLET === this._componentSign) {
299
+ if (productScene === productSceneEnum.EASY_PAY && productSceneVersion === '1.0' && !autoDebitWithToken && requireFastSdk) {
300
+ // EASY_PAY 1.0首次支付,requireFastSdk为true,不需要接口请求
301
+ this.handleAuthUrlInfo(authUrlInfo);
302
+ return;
303
+ }
304
+ }
305
+ if (componentSignEnum.AUTO_DEBIT_WALLET === this._componentSign) {
306
+ var _this$_renderParams9, _action$web, _action$wap;
307
+ var action = ((_this$_renderParams9 = this._renderParams) === null || _this$_renderParams9 === void 0 || (_this$_renderParams9 = _this$_renderParams9.paymentSessionMetaData) === null || _this$_renderParams9 === void 0 ? void 0 : _this$_renderParams9.action) || {};
308
+ var signType = isPC() ? action === null || action === void 0 || (_action$web = action.web) === null || _action$web === void 0 ? void 0 : _action$web.signType : action === null || action === void 0 || (_action$wap = action.wap) === null || _action$wap === void 0 ? void 0 : _action$wap.signType;
309
+ var _requireFastSdk = (action === null || action === void 0 ? void 0 : action.requireFastSdk) || false;
310
+ if (signType === 'REDIRECT' && _requireFastSdk === true) {
311
+ // REDIRECT,requireFastSdk为true,不需要接口请求
312
+ this.handleAuthUrlInfo(authUrlInfo);
313
+ return;
314
+ }
315
+ }
269
316
  this.dispatchToSDK(EVENT.eventCallback.name, {
270
317
  code: eventCodeEnum.SDK_START_OF_LOADING
271
318
  });
@@ -275,10 +322,10 @@ var ComponentApp = /*#__PURE__*/function () {
275
322
  insertStyleSheet();
276
323
  }
277
324
  if (this._renderDisplayType === renderDisplayTypeEnum.popup) {
278
- var _this$_renderParams5;
325
+ var _this$_renderParams10;
279
326
  createBaseElement(this.platform, this.closeBtnFunc.bind(this));
280
327
  createRetentionPopup(this.platform, this.hideRetentionPopupFunc.bind(this), this.retentionPopupLeaveFunc.bind(this));
281
- var channelBehavior = getChannelBehavior((_this$_renderParams5 = this._renderParams) === null || _this$_renderParams5 === void 0 ? void 0 : _this$_renderParams5.paymentSessionMetaData);
328
+ var channelBehavior = getChannelBehavior((_this$_renderParams10 = this._renderParams) === null || _this$_renderParams10 === void 0 ? void 0 : _this$_renderParams10.paymentSessionMetaData);
282
329
  var onClickOutside = function onClickOutside() {};
283
330
  if (channelBehavior !== null && channelBehavior !== void 0 && channelBehavior.allowClickOutsideClose) {
284
331
  onClickOutside = this.closeBtnFunc.bind(this);
@@ -366,9 +413,9 @@ var ComponentApp = /*#__PURE__*/function () {
366
413
  }, {
367
414
  key: "createActionQueryPromise",
368
415
  value: function createActionQueryPromise() {
369
- var _this$_renderParams6,
416
+ var _this$_renderParams11,
370
417
  _this5 = this;
371
- var paymentMethodType = (_this$_renderParams6 = this._renderParams) === null || _this$_renderParams6 === void 0 || (_this$_renderParams6 = _this$_renderParams6.paymentSessionMetaData) === null || _this$_renderParams6 === void 0 || (_this$_renderParams6 = _this$_renderParams6.paymentMethodInfoView) === null || _this$_renderParams6 === void 0 ? void 0 : _this$_renderParams6.paymentMethodType;
418
+ var paymentMethodType = (_this$_renderParams11 = this._renderParams) === null || _this$_renderParams11 === void 0 || (_this$_renderParams11 = _this$_renderParams11.paymentSessionMetaData) === null || _this$_renderParams11 === void 0 || (_this$_renderParams11 = _this$_renderParams11.paymentMethodInfoView) === null || _this$_renderParams11 === void 0 ? void 0 : _this$_renderParams11.paymentMethodType;
372
419
  this._performanceData.push({
373
420
  key: 'sdk_action_query_start',
374
421
  value: Date.now()
@@ -376,9 +423,9 @@ var ComponentApp = /*#__PURE__*/function () {
376
423
 
377
424
  // eslint-disable-next-line no-async-promise-executor
378
425
  this._actionQueryPromise = new Promise( /*#__PURE__*/function () {
379
- var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(resolve, reject) {
426
+ var _ref5 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(resolve, reject) {
380
427
  var _this5$_renderParams, _this5$_renderParams2, _this5$_renderParams3, _this5$_renderParams4, _this5$_renderParams5, _this5$_renderParams6;
381
- var envInfo, params, _ref3, _ref3$extendInfo, extendInfo, actionData, enableVaultingApiOptimize, enableEasypayApiOptimize, _ref4, skipSdkQuery, skipSdkQueryForm, extendInfoData, ifSkip, channelBehavior, _this5$_renderParams7, _this5$_renderParams8, _ref5, _ref5$productSceneVer, productSceneVersion, _ref5$productScene, productScene, _ref6, _ref6$action, _ref6$action2, _ref6$action2$autoDeb, autoDebitWithToken, _this5$_renderParams9, _action$web, _action$wap, action, signType;
428
+ var envInfo, params, _ref6, _ref6$extendInfo, extendInfo, actionData, enableVaultingApiOptimize, enableEasypayApiOptimize, _ref7, skipSdkQuery, skipSdkQueryForm, extendInfoData, ifSkip, channelBehavior, _this5$_renderParams7, _this5$_renderParams8, _ref8, _ref8$productSceneVer, productSceneVersion, _ref8$productScene, productScene, _ref9, _ref9$action, _ref9$action2, _ref9$action2$autoDeb, autoDebitWithToken, _this5$_renderParams9, _action$web2, _action$wap2, action, signType;
382
429
  return _regeneratorRuntime().wrap(function _callee2$(_context2) {
383
430
  while (1) switch (_context2.prev = _context2.next) {
384
431
  case 0:
@@ -394,10 +441,10 @@ var ComponentApp = /*#__PURE__*/function () {
394
441
  /**
395
442
  * @description Simulated or unnecessary scenarios
396
443
  */
397
- _ref3 = ((_this5$_renderParams4 = _this5._renderParams) === null || _this5$_renderParams4 === void 0 ? void 0 : _this5$_renderParams4.paymentSessionMetaData) || {}, _ref3$extendInfo = _ref3.extendInfo, extendInfo = _ref3$extendInfo === void 0 ? '' : _ref3$extendInfo, actionData = _ref3.action;
444
+ _ref6 = ((_this5$_renderParams4 = _this5._renderParams) === null || _this5$_renderParams4 === void 0 ? void 0 : _this5$_renderParams4.paymentSessionMetaData) || {}, _ref6$extendInfo = _ref6.extendInfo, extendInfo = _ref6$extendInfo === void 0 ? '' : _ref6$extendInfo, actionData = _ref6.action;
398
445
  enableVaultingApiOptimize = false;
399
446
  enableEasypayApiOptimize = false;
400
- _ref4 = ((_this5$_renderParams5 = _this5._renderParams) === null || _this5$_renderParams5 === void 0 || (_this5$_renderParams5 = _this5$_renderParams5.paymentSessionMetaData) === null || _this5$_renderParams5 === void 0 ? void 0 : _this5$_renderParams5.action) || {}, skipSdkQuery = _ref4.skipSdkQuery, skipSdkQueryForm = _ref4.skipSdkQueryForm;
447
+ _ref7 = ((_this5$_renderParams5 = _this5._renderParams) === null || _this5$_renderParams5 === void 0 || (_this5$_renderParams5 = _this5$_renderParams5.paymentSessionMetaData) === null || _this5$_renderParams5 === void 0 ? void 0 : _this5$_renderParams5.action) || {}, skipSdkQuery = _ref7.skipSdkQuery, skipSdkQueryForm = _ref7.skipSdkQueryForm;
401
448
  try {
402
449
  extendInfoData = JSON.parse(extendInfo);
403
450
  enableVaultingApiOptimize = extendInfoData.enableVaultingApiOptimize || false;
@@ -481,8 +528,8 @@ var ComponentApp = /*#__PURE__*/function () {
481
528
  _context2.next = 40;
482
529
  break;
483
530
  }
484
- _ref5 = params.paymentSessionConfig || {}, _ref5$productSceneVer = _ref5.productSceneVersion, productSceneVersion = _ref5$productSceneVer === void 0 ? '' : _ref5$productSceneVer, _ref5$productScene = _ref5.productScene, productScene = _ref5$productScene === void 0 ? '' : _ref5$productScene;
485
- _ref6 = ((_this5$_renderParams7 = _this5._renderParams) === null || _this5$_renderParams7 === void 0 ? void 0 : _this5$_renderParams7.paymentSessionMetaData) || {}, _ref6$action = _ref6.action, _ref6$action2 = _ref6$action === void 0 ? {} : _ref6$action, _ref6$action2$autoDeb = _ref6$action2.autoDebitWithToken, autoDebitWithToken = _ref6$action2$autoDeb === void 0 ? false : _ref6$action2$autoDeb;
531
+ _ref8 = params.paymentSessionConfig || {}, _ref8$productSceneVer = _ref8.productSceneVersion, productSceneVersion = _ref8$productSceneVer === void 0 ? '' : _ref8$productSceneVer, _ref8$productScene = _ref8.productScene, productScene = _ref8$productScene === void 0 ? '' : _ref8$productScene;
532
+ _ref9 = ((_this5$_renderParams7 = _this5._renderParams) === null || _this5$_renderParams7 === void 0 ? void 0 : _this5$_renderParams7.paymentSessionMetaData) || {}, _ref9$action = _ref9.action, _ref9$action2 = _ref9$action === void 0 ? {} : _ref9$action, _ref9$action2$autoDeb = _ref9$action2.autoDebitWithToken, autoDebitWithToken = _ref9$action2$autoDeb === void 0 ? false : _ref9$action2$autoDeb;
486
533
  if (!((_this5$_renderParams8 = _this5._renderParams) !== null && _this5$_renderParams8 !== void 0 && (_this5$_renderParams8 = _this5$_renderParams8.paymentSessionMetaData) !== null && _this5$_renderParams8 !== void 0 && (_this5$_renderParams8 = _this5$_renderParams8.action) !== null && _this5$_renderParams8 !== void 0 && _this5$_renderParams8.skipSdkQuery && enableEasypayApiOptimize)) {
487
534
  _context2.next = 35;
488
535
  break;
@@ -511,7 +558,7 @@ var ComponentApp = /*#__PURE__*/function () {
511
558
  break;
512
559
  }
513
560
  action = ((_this5$_renderParams9 = _this5._renderParams) === null || _this5$_renderParams9 === void 0 || (_this5$_renderParams9 = _this5$_renderParams9.paymentSessionMetaData) === null || _this5$_renderParams9 === void 0 ? void 0 : _this5$_renderParams9.action) || {};
514
- signType = isPC() ? action === null || action === void 0 || (_action$web = action.web) === null || _action$web === void 0 ? void 0 : _action$web.signType : action === null || action === void 0 || (_action$wap = action.wap) === null || _action$wap === void 0 ? void 0 : _action$wap.signType;
561
+ signType = isPC() ? action === null || action === void 0 || (_action$web2 = action.web) === null || _action$web2 === void 0 ? void 0 : _action$web2.signType : action === null || action === void 0 || (_action$wap2 = action.wap) === null || _action$wap2 === void 0 ? void 0 : _action$wap2.signType;
515
562
  if (!(signType === 'SMS')) {
516
563
  _context2.next = 45;
517
564
  break;
@@ -579,7 +626,7 @@ var ComponentApp = /*#__PURE__*/function () {
579
626
  }, _callee2);
580
627
  }));
581
628
  return function (_x, _x2) {
582
- return _ref2.apply(this, arguments);
629
+ return _ref5.apply(this, arguments);
583
630
  };
584
631
  }());
585
632
  return this._actionQueryPromise;
@@ -589,24 +636,24 @@ var ComponentApp = /*#__PURE__*/function () {
589
636
  }, {
590
637
  key: "createSubmitPromise",
591
638
  value: function createSubmitPromise() {
592
- var _this$_renderParams7,
593
- _this$_renderParams8,
594
- _this$_renderParams9,
639
+ var _this$_renderParams12,
640
+ _this$_renderParams13,
641
+ _this$_renderParams14,
595
642
  _this6 = this;
596
643
  this._performanceData.push({
597
644
  key: 'sdk_submit_start',
598
645
  value: Date.now()
599
646
  });
600
647
  var params = {
601
- paymentSessionData: this._renderParams && ((_this$_renderParams7 = this._renderParams) === null || _this$_renderParams7 === void 0 ? void 0 : _this$_renderParams7.sessionData) || '',
602
- paymentSessionConfig: (_this$_renderParams8 = this._renderParams) === null || _this$_renderParams8 === void 0 || (_this$_renderParams8 = _this$_renderParams8.paymentSessionMetaData) === null || _this$_renderParams8 === void 0 ? void 0 : _this$_renderParams8.paymentSessionConfig
648
+ paymentSessionData: this._renderParams && ((_this$_renderParams12 = this._renderParams) === null || _this$_renderParams12 === void 0 ? void 0 : _this$_renderParams12.sessionData) || '',
649
+ paymentSessionConfig: (_this$_renderParams13 = this._renderParams) === null || _this$_renderParams13 === void 0 || (_this$_renderParams13 = _this$_renderParams13.paymentSessionMetaData) === null || _this$_renderParams13 === void 0 ? void 0 : _this$_renderParams13.paymentSessionConfig
603
650
  };
604
- var channelBehavior = getChannelBehavior((_this$_renderParams9 = this._renderParams) === null || _this$_renderParams9 === void 0 ? void 0 : _this$_renderParams9.paymentSessionMetaData);
651
+ var channelBehavior = getChannelBehavior((_this$_renderParams14 = this._renderParams) === null || _this$_renderParams14 === void 0 ? void 0 : _this$_renderParams14.paymentSessionMetaData);
605
652
  // eslint-disable-next-line no-async-promise-executor
606
653
  this._actionSubmitPromise = new Promise( /*#__PURE__*/function () {
607
- var _ref7 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee3(resolve) {
654
+ var _ref10 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee3(resolve) {
608
655
  var _channelBehavior$buil, _this6$_renderParams$;
609
- var shouldSkipSubmitPayInSDK, _this6$_renderParams, _this6$_renderParams2, _ref8, _ref8$productSceneVer, productSceneVersion, _ref8$productScene, productScene, _ref9, _ref9$action, _ref9$action2, _ref9$action2$enableS, enableSignAgreement, extParams;
656
+ var shouldSkipSubmitPayInSDK, _this6$_renderParams, _this6$_renderParams2, _ref11, _ref11$productSceneVe, productSceneVersion, _ref11$productScene, productScene, _ref12, _ref12$action, _ref12$action2, _ref12$action2$enable, enableSignAgreement, extParams;
610
657
  return _regeneratorRuntime().wrap(function _callee3$(_context3) {
611
658
  while (1) switch (_context3.prev = _context3.next) {
612
659
  case 0:
@@ -618,8 +665,8 @@ var ComponentApp = /*#__PURE__*/function () {
618
665
  shouldSkipSubmitPayInSDK = !((_this6$_renderParams = _this6._renderParams) !== null && _this6$_renderParams !== void 0 && (_this6$_renderParams = _this6$_renderParams.paymentSessionMetaData) !== null && _this6$_renderParams !== void 0 && (_this6$_renderParams = _this6$_renderParams.action) !== null && _this6$_renderParams !== void 0 && _this6$_renderParams.skipSdkQuery) || componentSignEnum.EASY_PAY_WALLET !== _this6._componentSign;
619
666
  }
620
667
  if (componentSignEnum.EASY_PAY_WALLET === _this6._componentSign) {
621
- _ref8 = params.paymentSessionConfig || {}, _ref8$productSceneVer = _ref8.productSceneVersion, productSceneVersion = _ref8$productSceneVer === void 0 ? '' : _ref8$productSceneVer, _ref8$productScene = _ref8.productScene, productScene = _ref8$productScene === void 0 ? '' : _ref8$productScene;
622
- _ref9 = ((_this6$_renderParams2 = _this6._renderParams) === null || _this6$_renderParams2 === void 0 ? void 0 : _this6$_renderParams2.paymentSessionMetaData) || {}, _ref9$action = _ref9.action, _ref9$action2 = _ref9$action === void 0 ? {} : _ref9$action, _ref9$action2$enableS = _ref9$action2.enableSignAgreement, enableSignAgreement = _ref9$action2$enableS === void 0 ? false : _ref9$action2$enableS;
668
+ _ref11 = params.paymentSessionConfig || {}, _ref11$productSceneVe = _ref11.productSceneVersion, productSceneVersion = _ref11$productSceneVe === void 0 ? '' : _ref11$productSceneVe, _ref11$productScene = _ref11.productScene, productScene = _ref11$productScene === void 0 ? '' : _ref11$productScene;
669
+ _ref12 = ((_this6$_renderParams2 = _this6._renderParams) === null || _this6$_renderParams2 === void 0 ? void 0 : _this6$_renderParams2.paymentSessionMetaData) || {}, _ref12$action = _ref12.action, _ref12$action2 = _ref12$action === void 0 ? {} : _ref12$action, _ref12$action2$enable = _ref12$action2.enableSignAgreement, enableSignAgreement = _ref12$action2$enable === void 0 ? false : _ref12$action2$enable;
623
670
  if (productScene === productSceneEnum.EASY_PAY && productSceneVersion === '2.0') {
624
671
  params['signAgreement'] = enableSignAgreement;
625
672
  }
@@ -694,7 +741,7 @@ var ComponentApp = /*#__PURE__*/function () {
694
741
  }, _callee3);
695
742
  }));
696
743
  return function (_x3) {
697
- return _ref7.apply(this, arguments);
744
+ return _ref10.apply(this, arguments);
698
745
  };
699
746
  }());
700
747
  }
@@ -1220,11 +1267,31 @@ var ComponentApp = /*#__PURE__*/function () {
1220
1267
  this.app.style.height = "".concat(data.context.data.height, "px");
1221
1268
  }
1222
1269
  }
1270
+ }, {
1271
+ key: "handleAuthUrlInfo",
1272
+ value: function handleAuthUrlInfo(authUrlInfo) {
1273
+ var data = {};
1274
+ if (!(authUrlInfo !== null && authUrlInfo !== void 0 && authUrlInfo.normalUrl) && !(authUrlInfo !== null && authUrlInfo !== void 0 && authUrlInfo.schemeUrl) && !(authUrlInfo !== null && authUrlInfo !== void 0 && authUrlInfo.applinkUrl) && authUrlInfo !== null && authUrlInfo !== void 0 && authUrlInfo.authUrl) {
1275
+ data = {
1276
+ normalUrl: authUrlInfo === null || authUrlInfo === void 0 ? void 0 : authUrlInfo.authUrl,
1277
+ schemeUrl: authUrlInfo === null || authUrlInfo === void 0 ? void 0 : authUrlInfo.authUrl,
1278
+ applinkUrl: authUrlInfo === null || authUrlInfo === void 0 ? void 0 : authUrlInfo.authUrl
1279
+ };
1280
+ } else {
1281
+ data = {
1282
+ normalUrl: authUrlInfo === null || authUrlInfo === void 0 ? void 0 : authUrlInfo.normalUrl,
1283
+ schemeUrl: authUrlInfo === null || authUrlInfo === void 0 ? void 0 : authUrlInfo.schemeUrl,
1284
+ applinkUrl: authUrlInfo === null || authUrlInfo === void 0 ? void 0 : authUrlInfo.applinkUrl
1285
+ };
1286
+ }
1287
+ this.handleRedirect(data, true);
1288
+ }
1223
1289
  }, {
1224
1290
  key: "handleRedirect",
1225
1291
  value: function handleRedirect(data) {
1226
1292
  var _data$isDestroy,
1227
1293
  _this7 = this;
1294
+ var fromFastSdk = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
1228
1295
  var _data = typeof data === 'string' ? {
1229
1296
  normalUrl: data
1230
1297
  } : _objectSpread(_objectSpread({}, data), {}, {
@@ -1247,7 +1314,8 @@ var ComponentApp = /*#__PURE__*/function () {
1247
1314
  }, {
1248
1315
  redirectInfo: JSON.stringify(_data),
1249
1316
  openType: type,
1250
- url: url
1317
+ url: url,
1318
+ fromFastSdk: fromFastSdk
1251
1319
  }).send();
1252
1320
  };
1253
1321
  var failCallback = function failCallback(type, url) {
@@ -1260,7 +1328,8 @@ var ComponentApp = /*#__PURE__*/function () {
1260
1328
  }, {
1261
1329
  redirectInfo: JSON.stringify(_data),
1262
1330
  openType: type,
1263
- url: url
1331
+ url: url,
1332
+ fromFastSdk: fromFastSdk
1264
1333
  }).send();
1265
1334
  };
1266
1335
 
@@ -1303,9 +1372,9 @@ var ComponentApp = /*#__PURE__*/function () {
1303
1372
  }
1304
1373
  }, {
1305
1374
  key: "handleDeclareInfo",
1306
- value: function handleDeclareInfo(_ref10) {
1307
- var _ref10$closeDialogDat = _ref10.closeDialogData,
1308
- closeDialogData = _ref10$closeDialogDat === void 0 ? {} : _ref10$closeDialogDat;
1375
+ value: function handleDeclareInfo(_ref13) {
1376
+ var _ref13$closeDialogDat = _ref13.closeDialogData,
1377
+ closeDialogData = _ref13$closeDialogDat === void 0 ? {} : _ref13$closeDialogDat;
1309
1378
  _handleDeclareInfo({
1310
1379
  closeDialogData: closeDialogData
1311
1380
  });
@@ -1446,7 +1515,7 @@ var ComponentApp = /*#__PURE__*/function () {
1446
1515
  key: "sendRenderEvent",
1447
1516
  value: (function () {
1448
1517
  var _sendRenderEvent = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee8() {
1449
- var _this$_renderParams10, _this$_renderParams11, _this$_renderParams12, _this$_renderParams13, _this$_renderParams14, _this$_renderParams15, _this$AMSSDK$logger, _this$_renderParams16, _this$_renderParams17, _this$_renderParams18, _this$AMSSDK, _this$_renderParams19, res, submitRes;
1518
+ var _this$_renderParams15, _this$_renderParams16, _this$_renderParams17, _this$_renderParams18, _this$_renderParams19, _this$_renderParams20, _this$AMSSDK$logger, _this$_renderParams21, _this$_renderParams22, _this$_renderParams23, _this$AMSSDK, _this$_renderParams24, res, submitRes;
1450
1519
  return _regeneratorRuntime().wrap(function _callee8$(_context8) {
1451
1520
  while (1) switch (_context8.prev = _context8.next) {
1452
1521
  case 0:
@@ -1475,28 +1544,28 @@ var ComponentApp = /*#__PURE__*/function () {
1475
1544
  data: {
1476
1545
  queryResult: res,
1477
1546
  submitResult: submitRes,
1478
- sessionResult: (_this$_renderParams10 = this._renderParams) === null || _this$_renderParams10 === void 0 ? void 0 : _this$_renderParams10.paymentSessionMetaData,
1479
- paymentSessionData: (_this$_renderParams11 = this._renderParams) === null || _this$_renderParams11 === void 0 ? void 0 : _this$_renderParams11.sessionData,
1547
+ sessionResult: (_this$_renderParams15 = this._renderParams) === null || _this$_renderParams15 === void 0 ? void 0 : _this$_renderParams15.paymentSessionMetaData,
1548
+ paymentSessionData: (_this$_renderParams16 = this._renderParams) === null || _this$_renderParams16 === void 0 ? void 0 : _this$_renderParams16.sessionData,
1480
1549
  heightOfVisible: Math.max(window.changingPageHeight, window.innerHeight),
1481
- renderDisplayType: (_this$_renderParams12 = this._renderParams) === null || _this$_renderParams12 === void 0 ? void 0 : _this$_renderParams12.renderDisplayType,
1482
- appearance: (_this$_renderParams13 = this._renderParams) === null || _this$_renderParams13 === void 0 ? void 0 : _this$_renderParams13.appearance,
1483
- notRedirectAfterComplete: ((_this$_renderParams14 = this._renderParams) === null || _this$_renderParams14 === void 0 ? void 0 : _this$_renderParams14.notRedirectAfterComplete) === true,
1550
+ renderDisplayType: (_this$_renderParams17 = this._renderParams) === null || _this$_renderParams17 === void 0 ? void 0 : _this$_renderParams17.renderDisplayType,
1551
+ appearance: (_this$_renderParams18 = this._renderParams) === null || _this$_renderParams18 === void 0 ? void 0 : _this$_renderParams18.appearance,
1552
+ notRedirectAfterComplete: ((_this$_renderParams19 = this._renderParams) === null || _this$_renderParams19 === void 0 ? void 0 : _this$_renderParams19.notRedirectAfterComplete) === true,
1484
1553
  merchantAppointParam: this._merchantAppointParam,
1485
1554
  envInfo: {
1486
1555
  screenHeight: screen.height,
1487
1556
  screenWidth: screen.width
1488
1557
  },
1489
1558
  logMetaData: _objectSpread(_objectSpread({
1490
- trackId: (_this$_renderParams15 = this._renderParams) === null || _this$_renderParams15 === void 0 ? void 0 : _this$_renderParams15.sessionData,
1559
+ trackId: (_this$_renderParams20 = this._renderParams) === null || _this$_renderParams20 === void 0 ? void 0 : _this$_renderParams20.sessionData,
1491
1560
  platform: this.platform,
1492
1561
  firstLogTime: (_this$AMSSDK$logger = this.AMSSDK.logger) === null || _this$AMSSDK$logger === void 0 ? void 0 : _this$AMSSDK$logger.getComponentStartTime()
1493
- }, ((_this$_renderParams16 = this._renderParams) === null || _this$_renderParams16 === void 0 || (_this$_renderParams16 = _this$_renderParams16.paymentSessionMetaData) === null || _this$_renderParams16 === void 0 ? void 0 : _this$_renderParams16.paymentSessionConfig) || {}), {}, {
1494
- renderDisplayType: (_this$_renderParams17 = this._renderParams) === null || _this$_renderParams17 === void 0 ? void 0 : _this$_renderParams17.renderDisplayType,
1562
+ }, ((_this$_renderParams21 = this._renderParams) === null || _this$_renderParams21 === void 0 || (_this$_renderParams21 = _this$_renderParams21.paymentSessionMetaData) === null || _this$_renderParams21 === void 0 ? void 0 : _this$_renderParams21.paymentSessionConfig) || {}), {}, {
1563
+ renderDisplayType: (_this$_renderParams22 = this._renderParams) === null || _this$_renderParams22 === void 0 ? void 0 : _this$_renderParams22.renderDisplayType,
1495
1564
  sdkVersion: this._appVersion,
1496
- merchantId: (_this$_renderParams18 = this._renderParams) === null || _this$_renderParams18 === void 0 || (_this$_renderParams18 = _this$_renderParams18.paymentSessionMetaData) === null || _this$_renderParams18 === void 0 ? void 0 : _this$_renderParams18.clientId,
1565
+ merchantId: (_this$_renderParams23 = this._renderParams) === null || _this$_renderParams23 === void 0 || (_this$_renderParams23 = _this$_renderParams23.paymentSessionMetaData) === null || _this$_renderParams23 === void 0 ? void 0 : _this$_renderParams23.clientId,
1497
1566
  instanceId: (_this$AMSSDK = this.AMSSDK) === null || _this$AMSSDK === void 0 ? void 0 : _this$AMSSDK._instanceId,
1498
1567
  performanceData: this._performanceData,
1499
- paymentMethodType: (_this$_renderParams19 = this._renderParams) === null || _this$_renderParams19 === void 0 || (_this$_renderParams19 = _this$_renderParams19.paymentSessionMetaData) === null || _this$_renderParams19 === void 0 || (_this$_renderParams19 = _this$_renderParams19.paymentMethodInfoView) === null || _this$_renderParams19 === void 0 ? void 0 : _this$_renderParams19.paymentMethodType
1568
+ paymentMethodType: (_this$_renderParams24 = this._renderParams) === null || _this$_renderParams24 === void 0 || (_this$_renderParams24 = _this$_renderParams24.paymentSessionMetaData) === null || _this$_renderParams24 === void 0 || (_this$_renderParams24 = _this$_renderParams24.paymentMethodInfoView) === null || _this$_renderParams24 === void 0 ? void 0 : _this$_renderParams24.paymentMethodType
1500
1569
  })
1501
1570
  }
1502
1571
  }
@@ -149,12 +149,20 @@ export interface IpaymentSessionMetaData {
149
149
  autoDebitWithToken: boolean;
150
150
  enableSignAgreement?: boolean;
151
151
  skipSdkQuery: boolean;
152
+ requireFastSdk: boolean;
152
153
  skipSdkQueryForm?: {
153
154
  value: boolean;
154
155
  version: string;
155
156
  platform: string;
156
157
  };
157
158
  };
159
+ authUrlInfo?: {
160
+ appIdentifier?: string;
161
+ applinkUrl?: string;
162
+ normalUrl?: string;
163
+ schemeUrl?: string;
164
+ authUrl?: string;
165
+ };
158
166
  paymentSessionFactor?: {
159
167
  extendInfo?: {
160
168
  merchantCapabilities?: string[];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alipay/ams-checkout",
3
- "version": "0.0.1717141544-dev.3",
3
+ "version": "0.0.1717141544-dev.5",
4
4
  "description": "",
5
5
  "author": "",
6
6
  "main": "esm/index.js",