@lightspeed/online-payments-sdk 1.9.0 → 1.9.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.
@@ -86,7 +86,7 @@ function mountSessionsFlow(mountElement, context, eventBroadcaster) {
86
86
  }
87
87
  // Multi-step Advanced flow: submit() surfaces the encrypted payment data for
88
88
  // the host to POST; handleNextAction() feeds the server response back to drive
89
- // native 3DS2. See MultiStepController in common.ts.
89
+ // 3DS actions. See MultiStepController in common.ts.
90
90
  function mountAdvancedFlow(mountElement, context, eventBroadcaster, onRequiresFinalization) {
91
91
  return __awaiter(this, void 0, void 0, function () {
92
92
  var stashedActions, pendingResolve, isValid, checkoutConfig, checkout, dropinConfiguration, dropIn;
@@ -167,7 +167,7 @@ function mountAdvancedFlow(mountElement, context, eventBroadcaster, onRequiresFi
167
167
  case 1:
168
168
  checkout = _b.sent();
169
169
  dropinConfiguration = {
170
- paymentMethodComponents: [adyen_web_1.Card, adyen_web_1.ApplePay, adyen_web_1.GooglePay, adyen_web_1.Bancontact],
170
+ paymentMethodComponents: [adyen_web_1.Card, adyen_web_1.ApplePay, adyen_web_1.GooglePay, adyen_web_1.Bancontact, adyen_web_1.Redirect],
171
171
  showStoredPaymentMethods: false,
172
172
  paymentMethodsConfiguration: {
173
173
  card: {
@@ -209,17 +209,8 @@ function mountAdvancedFlow(mountElement, context, eventBroadcaster, onRequiresFi
209
209
  var _a;
210
210
  var response = (serverResponse !== null && serverResponse !== void 0 ? serverResponse : {});
211
211
  if (response.action) {
212
- // 3DS1 (redirect) is out of scope: surface as an error so the host can
213
- // ask the shopper for a different card.
214
- if (response.action.type === 'redirect') {
215
- resolve({
216
- status: 'Error',
217
- error: { code: 'RedirectNotSupported', resultCode: response.resultCode },
218
- });
219
- return;
220
- }
221
- // Native 3DS2 step: let the component perform it, then resolve once
222
- // onAdditionalDetails hands us the next payload for the host to POST.
212
+ // Let Adyen Web perform the action. Native challenges call
213
+ // onAdditionalDetails; redirect actions navigate away to the issuer.
223
214
  pendingResolve = resolve;
224
215
  stashedActions === null || stashedActions === void 0 ? void 0 : stashedActions.resolve(response);
225
216
  return;
@@ -3,4 +3,4 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.SDK_VERSION = void 0;
4
4
  // This file is auto-generated during the build process
5
5
  // DO NOT EDIT MANUALLY - Version is extracted from package.json
6
- exports.SDK_VERSION = '1.9.0';
6
+ exports.SDK_VERSION = '1.9.1';
@@ -83,7 +83,7 @@ function mountSessionsFlow(mountElement, context, eventBroadcaster) {
83
83
  }
84
84
  // Multi-step Advanced flow: submit() surfaces the encrypted payment data for
85
85
  // the host to POST; handleNextAction() feeds the server response back to drive
86
- // native 3DS2. See MultiStepController in common.ts.
86
+ // 3DS actions. See MultiStepController in common.ts.
87
87
  function mountAdvancedFlow(mountElement, context, eventBroadcaster, onRequiresFinalization) {
88
88
  return __awaiter(this, void 0, void 0, function () {
89
89
  var stashedActions, pendingResolve, isValid, checkoutConfig, checkout, dropinConfiguration, dropIn;
@@ -164,7 +164,7 @@ function mountAdvancedFlow(mountElement, context, eventBroadcaster, onRequiresFi
164
164
  case 1:
165
165
  checkout = _b.sent();
166
166
  dropinConfiguration = {
167
- paymentMethodComponents: [Card, ApplePay, GooglePay, Bancontact],
167
+ paymentMethodComponents: [Card, ApplePay, GooglePay, Bancontact, Redirect],
168
168
  showStoredPaymentMethods: false,
169
169
  paymentMethodsConfiguration: {
170
170
  card: {
@@ -206,17 +206,8 @@ function mountAdvancedFlow(mountElement, context, eventBroadcaster, onRequiresFi
206
206
  var _a;
207
207
  var response = (serverResponse !== null && serverResponse !== void 0 ? serverResponse : {});
208
208
  if (response.action) {
209
- // 3DS1 (redirect) is out of scope: surface as an error so the host can
210
- // ask the shopper for a different card.
211
- if (response.action.type === 'redirect') {
212
- resolve({
213
- status: 'Error',
214
- error: { code: 'RedirectNotSupported', resultCode: response.resultCode },
215
- });
216
- return;
217
- }
218
- // Native 3DS2 step: let the component perform it, then resolve once
219
- // onAdditionalDetails hands us the next payload for the host to POST.
209
+ // Let Adyen Web perform the action. Native challenges call
210
+ // onAdditionalDetails; redirect actions navigate away to the issuer.
220
211
  pendingResolve = resolve;
221
212
  stashedActions === null || stashedActions === void 0 ? void 0 : stashedActions.resolve(response);
222
213
  return;
package/dist/version.d.ts CHANGED
@@ -1 +1 @@
1
- export declare const SDK_VERSION = "1.9.0";
1
+ export declare const SDK_VERSION = "1.9.1";
package/dist/version.js CHANGED
@@ -1,3 +1,3 @@
1
1
  // This file is auto-generated during the build process
2
2
  // DO NOT EDIT MANUALLY - Version is extracted from package.json
3
- export var SDK_VERSION = '1.9.0';
3
+ export var SDK_VERSION = '1.9.1';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lightspeed/online-payments-sdk",
3
- "version": "1.9.0",
3
+ "version": "1.9.1",
4
4
  "description": "Process online-payments with Lightspeed Payments",
5
5
  "author": "Lightspeed Commerce Inc.",
6
6
  "license": "SEE LICENSE IN LICENSE.md",