@xsolla/payment-client-core 0.2.108 → 0.2.110
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/esm2022/lib/core/legal/legal.component.config.mjs +1 -1
- package/esm2022/lib/core/legal/legal.service.mjs +11 -6
- package/esm2022/lib/core/payment/actions/show-fields/show-fields.action.class.mjs +2 -1
- package/esm2022/lib/core/payment/actions/show-fields/show-fields.action.type.mjs +1 -1
- package/esm2022/lib/core/payment/field-names.enum.mjs +28 -3
- package/esm2022/lib/core/payment/payment.service.mjs +3 -2
- package/fesm2022/xsolla-payment-client-core.mjs +40 -8
- package/fesm2022/xsolla-payment-client-core.mjs.map +1 -1
- package/lib/core/legal/legal.component.config.d.ts +1 -1
- package/lib/core/payment/actions/show-fields/show-fields.action.type.d.ts +1 -0
- package/lib/core/payment/field-names.enum.d.ts +27 -2
- package/package.json +1 -1
- package/xsolla-payment-client-core-0.2.110.tgz +0 -0
- package/xsolla-payment-client-core-0.2.108.tgz +0 -0
|
@@ -1334,6 +1334,9 @@ var FieldNames;
|
|
|
1334
1334
|
FieldNames["allowSubscription"] = "allowSubscription";
|
|
1335
1335
|
FieldNames["apt"] = "apt";
|
|
1336
1336
|
FieldNames["availableCardTypes"] = "available_card_types";
|
|
1337
|
+
FieldNames["babka_pay_phone"] = "babka_pay_phone";
|
|
1338
|
+
FieldNames["babka_pay_jwt"] = "babka_pay_jwt";
|
|
1339
|
+
FieldNames["babkaPayLoyaltyParticipation"] = "babka_pay_loyalty_participation";
|
|
1337
1340
|
FieldNames["bank"] = "bank";
|
|
1338
1341
|
FieldNames["birthDate"] = "birth_date";
|
|
1339
1342
|
FieldNames["cardMonth"] = "card_month";
|
|
@@ -1343,13 +1346,14 @@ var FieldNames;
|
|
|
1343
1346
|
FieldNames["cardholdername"] = "cardholdername";
|
|
1344
1347
|
FieldNames["city"] = "city";
|
|
1345
1348
|
FieldNames["couponCode"] = "couponCode";
|
|
1349
|
+
FieldNames["document"] = "document";
|
|
1346
1350
|
FieldNames["cpfName"] = "cpf_name";
|
|
1347
1351
|
FieldNames["cpfNumber"] = "cpf_number";
|
|
1348
1352
|
FieldNames["cvv"] = "cvv";
|
|
1349
1353
|
FieldNames["description"] = "description";
|
|
1354
|
+
FieldNames["collectedEmailConsent"] = "collectedEmailConsent";
|
|
1350
1355
|
FieldNames["email"] = "email";
|
|
1351
1356
|
FieldNames["psEmail"] = "psEmail";
|
|
1352
|
-
FieldNames["psAccountCountry"] = "psAccountCountry";
|
|
1353
1357
|
FieldNames["bazitemail"] = "bazitemail";
|
|
1354
1358
|
FieldNames["euCheck"] = "eu_check";
|
|
1355
1359
|
FieldNames["extraCvv"] = "extra_cvv";
|
|
@@ -1359,6 +1363,7 @@ var FieldNames;
|
|
|
1359
1363
|
FieldNames["installments"] = "installments";
|
|
1360
1364
|
FieldNames["lName"] = "l_name";
|
|
1361
1365
|
FieldNames["needInstallments"] = "needInstallments";
|
|
1366
|
+
FieldNames["payer"] = "payer";
|
|
1362
1367
|
FieldNames["personId"] = "person_id";
|
|
1363
1368
|
FieldNames["personIdAr"] = "person_id_ar";
|
|
1364
1369
|
FieldNames["personIdCo"] = "person_id_co";
|
|
@@ -1381,6 +1386,7 @@ var FieldNames;
|
|
|
1381
1386
|
FieldNames["licenseDisclaimer"] = "licenseDisclaimer";
|
|
1382
1387
|
FieldNames["xsollaTipsAmount"] = "xsollaTipsAmount";
|
|
1383
1388
|
FieldNames["zip"] = "zip";
|
|
1389
|
+
FieldNames["psAccountCountry"] = "psAccountCountry";
|
|
1384
1390
|
FieldNames["allowSave"] = "allowSave";
|
|
1385
1391
|
FieldNames["koreaLimitsInstruction"] = "korea_limits_instruction";
|
|
1386
1392
|
FieldNames["tokenApplePay"] = "token_applepay";
|
|
@@ -1388,11 +1394,14 @@ var FieldNames;
|
|
|
1388
1394
|
FieldNames["fixPid"] = "fix_pid";
|
|
1389
1395
|
FieldNames["signature"] = "signature";
|
|
1390
1396
|
FieldNames["qr"] = "qr";
|
|
1397
|
+
FieldNames["qrCode"] = "qr_code";
|
|
1398
|
+
FieldNames["qrTtl"] = "qr_ttl";
|
|
1391
1399
|
FieldNames["sum"] = "sum";
|
|
1392
1400
|
FieldNames["out"] = "out";
|
|
1393
1401
|
FieldNames["tinkoffDisclaimer"] = "ps.tinkoff.disclaimer";
|
|
1394
1402
|
FieldNames["ppEmail"] = "pp_email";
|
|
1395
1403
|
FieldNames["redeemPoints"] = "redeemPoints";
|
|
1404
|
+
FieldNames["redeemLoyaltyPoints"] = "redeemLoyaltyPoints";
|
|
1396
1405
|
FieldNames["omnibusDirective"] = "omnibus_directive";
|
|
1397
1406
|
FieldNames["labelApplePay"] = "label_applePay";
|
|
1398
1407
|
FieldNames["countryCode"] = "countryCode";
|
|
@@ -1405,9 +1414,25 @@ var FieldNames;
|
|
|
1405
1414
|
FieldNames["payInstanceAccountId"] = "payInstanceAccountId";
|
|
1406
1415
|
FieldNames["getApplePaySessionUrl"] = "getApplePaySessionUrl";
|
|
1407
1416
|
FieldNames["payViaCheckoutUrl"] = "payViaCheckoutUrl";
|
|
1417
|
+
FieldNames["paymentInstruction"] = "payment_instruction";
|
|
1418
|
+
FieldNames["paymentWithSavedMethod"] = "paymentWithSavedMethod";
|
|
1419
|
+
FieldNames["xsollaOrbsPartialPayment"] = "xsolla_currency_wallet_partial";
|
|
1420
|
+
FieldNames["xsollaGoldOrbsPartial"] = "xsolla-gold-orbs-partial";
|
|
1421
|
+
FieldNames["xsollaOrbsFullPayment"] = "xsolla_currency_wallet_full";
|
|
1422
|
+
FieldNames["xsollaCurrencyDescription"] = "xsolla_currency_description";
|
|
1423
|
+
FieldNames["fixCommand"] = "fix_command";
|
|
1424
|
+
FieldNames["jwtToken"] = "jwt_token";
|
|
1425
|
+
FieldNames["userId"] = "user_id";
|
|
1426
|
+
FieldNames["userPass"] = "user_pass";
|
|
1427
|
+
FieldNames["pinCard"] = "pin_card";
|
|
1428
|
+
FieldNames["payType"] = "payType";
|
|
1429
|
+
FieldNames["fullName"] = "user_name";
|
|
1430
|
+
FieldNames["name"] = "name";
|
|
1431
|
+
FieldNames["epin"] = "epin";
|
|
1432
|
+
FieldNames["zipCode"] = "zip_code";
|
|
1433
|
+
FieldNames["googlePay3dsRedirect"] = "googlePay3DSRedirect";
|
|
1408
1434
|
FieldNames["googlePayInitData"] = "googlePayInitData";
|
|
1409
1435
|
FieldNames["googlePayPaymentData"] = "googlePayPaymentData";
|
|
1410
|
-
FieldNames["googlePay3dsRedirect"] = "googlePay3DSRedirect";
|
|
1411
1436
|
FieldNames["externalCardIssuerCountry"] = "externalCardIssuerCountry";
|
|
1412
1437
|
FieldNames["pmId"] = "pm_id";
|
|
1413
1438
|
})(FieldNames || (FieldNames = {}));
|
|
@@ -1891,6 +1916,7 @@ class ShowFieldsActionCreator {
|
|
|
1891
1916
|
data.errors = submitResponse.errors;
|
|
1892
1917
|
data.messages = submitResponse.messages;
|
|
1893
1918
|
data.order = submitResponse.summary;
|
|
1919
|
+
data.submitButtonText = submitResponse.buyData?.value;
|
|
1894
1920
|
return {
|
|
1895
1921
|
type: this.type,
|
|
1896
1922
|
data,
|
|
@@ -7781,11 +7807,12 @@ class PaymentService {
|
|
|
7781
7807
|
this.runThreeDs();
|
|
7782
7808
|
return;
|
|
7783
7809
|
}
|
|
7810
|
+
const nextAction = this.nextActionService.getNextAction(submitResponse);
|
|
7784
7811
|
this.fields = this.getFields();
|
|
7785
7812
|
this.form = this.formService.createForm(this.fields);
|
|
7786
7813
|
this.listenFormStatusChanges(this.form);
|
|
7787
7814
|
this.syncService.setup(this.form, this.fields, this.config);
|
|
7788
|
-
return
|
|
7815
|
+
return nextAction;
|
|
7789
7816
|
}
|
|
7790
7817
|
async submitWithFields(fields) {
|
|
7791
7818
|
if (!this.form) {
|
|
@@ -8296,11 +8323,16 @@ class LegalService {
|
|
|
8296
8323
|
}
|
|
8297
8324
|
get legalArea() {
|
|
8298
8325
|
const userCountry = this.countryService.userIpCountry;
|
|
8299
|
-
|
|
8300
|
-
|
|
8301
|
-
|
|
8302
|
-
|
|
8303
|
-
|
|
8326
|
+
switch (true) {
|
|
8327
|
+
case userCountry === 'US':
|
|
8328
|
+
return 'US';
|
|
8329
|
+
case userCountry === 'KR':
|
|
8330
|
+
return 'KR';
|
|
8331
|
+
case euCountries.has(userCountry):
|
|
8332
|
+
return 'EU';
|
|
8333
|
+
default:
|
|
8334
|
+
return 'other';
|
|
8335
|
+
}
|
|
8304
8336
|
}
|
|
8305
8337
|
constructor(countryService, settingsService, refundPolicyService, disclaimerService) {
|
|
8306
8338
|
this.countryService = countryService;
|