@alipay/ams-checkout 0.0.1716363774-dev.1 → 0.0.1717583358-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.
@@ -56,7 +56,7 @@ var ComponentApp = /*#__PURE__*/function () {
56
56
  _defineProperty(this, "_multipleCallbackEvents", void 0);
57
57
  _defineProperty(this, "_merchantAppointParam", void 0);
58
58
  _defineProperty(this, "_webAppHeartBeatTimeoutFn", void 0);
59
- this._appVersion = '1.15.0';
59
+ this._appVersion = '1.15.1';
60
60
  this._isInitComponent = false;
61
61
  this._selector = "#".concat(COMPONENT_SECTION_ID);
62
62
  this.createIframeNode = function () {
@@ -116,7 +116,8 @@ export var PaypalBusSubscriber = /*#__PURE__*/function (_BusSubscriber) {
116
116
  blockPayPalPayLaterButton = _ref2.blockPayPalPayLaterButton,
117
117
  displayPayPalPayLaterButtonOnly = _ref2.displayPayPalPayLaterButtonOnly,
118
118
  enableMessages = _ref2.enableMessages,
119
- intent = _ref2.intent;
119
+ intent = _ref2.intent,
120
+ buyerCountry = _ref2.buyerCountry;
120
121
  var script = document.createElement('script');
121
122
  var src = "https://www.paypal.com/sdk/js?";
122
123
  var urlSearchParams = new URLSearchParams({
@@ -124,7 +125,9 @@ export var PaypalBusSubscriber = /*#__PURE__*/function (_BusSubscriber) {
124
125
  locale: locale,
125
126
  'client-id': channelMerchantAccountId
126
127
  });
127
- var disableFundingArr = [];
128
+ var disableFundingArr = ['bancontact', 'blik', 'eps', 'giropay', 'ideal', 'mercadopago', 'mybank', 'p24', 'sepa', 'sofort'];
129
+ // TODO: 上线后删除
130
+ // const disableFundingArr = [];
128
131
  if (blockPayPalCreditButton && !displayPayPalPayLaterButtonOnly) {
129
132
  disableFundingArr.push('card');
130
133
  }
@@ -143,6 +146,11 @@ export var PaypalBusSubscriber = /*#__PURE__*/function (_BusSubscriber) {
143
146
  urlSearchParams.append('intent', 'authorize');
144
147
  urlSearchParams.append('commit', 'false');
145
148
  }
149
+
150
+ // TODO: 上线后删除
151
+ if (buyerCountry) {
152
+ urlSearchParams.append('buyer-country', buyerCountry);
153
+ }
146
154
  if (PaypalMethodEnum.PAYPAL_VAULT === paymentMethodType) {
147
155
  urlSearchParams.append('vault', 'true');
148
156
  }
@@ -91,6 +91,7 @@ export interface IPaypalConfiguration {
91
91
  displayPayPalPayLaterButtonOnly?: boolean;
92
92
  enableMessages?: boolean;
93
93
  intent?: payPalConfigurationIntentEnum;
94
+ buyerCountry?: string;
94
95
  }
95
96
  export declare enum payPalConfigurationIntentEnum {
96
97
  'intent' = "intent",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alipay/ams-checkout",
3
- "version": "0.0.1716363774-dev.1",
3
+ "version": "0.0.1717583358-dev.0",
4
4
  "description": "",
5
5
  "author": "",
6
6
  "main": "esm/index.js",