@depay/widgets 10.2.12 → 10.2.13
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/dist/esm/index.bundle.js +1 -1
- package/dist/esm/index.js +16 -10
- package/dist/umd/index.bundle.js +1 -1
- package/dist/umd/index.js +16 -10
- package/package.json +1 -1
package/dist/esm/index.js
CHANGED
|
@@ -24983,6 +24983,8 @@ var Login = function Login(options) {
|
|
|
24983
24983
|
}());
|
|
24984
24984
|
};
|
|
24985
24985
|
|
|
24986
|
+
var SUPPORTED_CURRENCIES = ["all", "xcd", "eur", "bbd", "btn", "bnd", "xaf", "cup", "usd", "fkp", "gip", "huf", "irr", "jmd", "aud", "lak", "lyd", "mkd", "xof", "nzd", "omr", "pgk", "rwf", "wst", "rsd", "sek", "tzs", "amd", "bsd", "bam", "cve", "cny", "crc", "czk", "ern", "gel", "htg", "inr", "jod", "krw", "lbp", "mwk", "mru", "mzn", "ang", "pen", "qar", "std", "sll", "sos", "sdg", "syp", "aoa", "awg", "bhd", "bzd", "bwp", "bif", "kyd", "cop", "dkk", "gtq", "hnl", "idr", "ils", "kzt", "kwd", "lsl", "myr", "mur", "mnt", "mmk", "ngn", "pab", "php", "ron", "sar", "sgd", "zar", "srd", "twd", "top", "vef", "dzd", "ars", "azn", "bob", "bgn", "cad", "clp", "cdf", "dop", "fjd", "gmd", "gyd", "isk", "iqd", "jpy", "kpw", "chf", "mga", "mdl", "mad", "npr", "nio", "pkr", "pyg", "shp", "scr", "sbd", "lkr", "thb", "try", "aed", "vuv", "yer", "afn", "bdt", "brl", "khr", "kmf", "hrk", "djf", "egp", "etb", "xpf", "ghs", "gnf", "hkd", "xdr", "kes", "kgs", "lrd", "mop", "mvr", "mxn", "nad", "nok", "pln", "rub", "szl", "tjs", "ttd", "ugx", "uyu", "vnd", "tnd", "uah", "uzs", "tmt", "gbp", "zmw", "byn", "bmd", "ggp", "clf", "cuc", "imp", "jep", "svc", "xag", "zwl"];
|
|
24987
|
+
|
|
24986
24988
|
var PaymentAmountRoutingContext = /*#__PURE__*/React.createContext();
|
|
24987
24989
|
|
|
24988
24990
|
var PaymentAmountRoutingProvider = (function (props) {
|
|
@@ -25058,7 +25060,8 @@ var PaymentOverviewDialog = (function (props) {
|
|
|
25058
25060
|
var _useContext = useContext(ConfigurationContext),
|
|
25059
25061
|
currencyCode = _useContext.currencyCode,
|
|
25060
25062
|
recover = _useContext.recover,
|
|
25061
|
-
amountConfiguration = _useContext.amount
|
|
25063
|
+
amountConfiguration = _useContext.amount,
|
|
25064
|
+
currency = _useContext.currency;
|
|
25062
25065
|
var _useContext2 = useContext(PaymentContext),
|
|
25063
25066
|
payment = _useContext2.payment,
|
|
25064
25067
|
paymentState = _useContext2.paymentState;
|
|
@@ -25172,7 +25175,7 @@ var PaymentOverviewDialog = (function (props) {
|
|
|
25172
25175
|
className: "TokenSymbolCell"
|
|
25173
25176
|
}, payment.symbol), /*#__PURE__*/React.createElement("span", null, "\xA0"), /*#__PURE__*/React.createElement("span", {
|
|
25174
25177
|
className: "TokenAmountCell"
|
|
25175
|
-
}, format(payment.amount))), displayedPaymentValue != "".concat(payment.symbol, " ").concat(format(payment.amount)) && !(amountsMissing && !fixedCurrency) && /*#__PURE__*/React.createElement("div", {
|
|
25178
|
+
}, format(payment.amount))), displayedPaymentValue != "".concat(payment.symbol, " ").concat(format(payment.amount)) && !(amountsMissing && !fixedCurrency) && currency !== false && /*#__PURE__*/React.createElement("div", {
|
|
25176
25179
|
className: "TokenAmountRow small grey"
|
|
25177
25180
|
}, /*#__PURE__*/React.createElement("span", {
|
|
25178
25181
|
className: "TokenAmountCell"
|
|
@@ -25337,13 +25340,16 @@ var Payment = /*#__PURE__*/function () {
|
|
|
25337
25340
|
case 0:
|
|
25338
25341
|
accept = _ref3.accept, amount = _ref3.amount, sent = _ref3.sent, succeeded = _ref3.succeeded, validated = _ref3.validated, failed = _ref3.failed, error = _ref3.error, critical = _ref3.critical, style = _ref3.style, whitelist = _ref3.whitelist, blacklist = _ref3.blacklist, providers = _ref3.providers, currency = _ref3.currency, connected = _ref3.connected, closed = _ref3.closed, track = _ref3.track, fee = _ref3.fee, recover = _ref3.recover, closable = _ref3.closable, integration = _ref3.integration, link = _ref3.link, container = _ref3.container, before = _ref3.before, wallet = _ref3.wallet, document = _ref3.document;
|
|
25339
25342
|
requireReactVersion();
|
|
25340
|
-
|
|
25341
|
-
|
|
25343
|
+
if (currency && !SUPPORTED_CURRENCIES.includes(currency.toLowerCase())) {
|
|
25344
|
+
currency = false;
|
|
25345
|
+
}
|
|
25346
|
+
_context2.prev = 3;
|
|
25347
|
+
_context2.next = 6;
|
|
25342
25348
|
return preflight$1({
|
|
25343
25349
|
accept: accept,
|
|
25344
25350
|
recover: recover
|
|
25345
25351
|
});
|
|
25346
|
-
case
|
|
25352
|
+
case 6:
|
|
25347
25353
|
if (typeof window._depayUnmountLoading == 'function') {
|
|
25348
25354
|
window._depayUnmountLoading();
|
|
25349
25355
|
}
|
|
@@ -25410,18 +25416,18 @@ var Payment = /*#__PURE__*/function () {
|
|
|
25410
25416
|
return _context2.abrupt("return", {
|
|
25411
25417
|
unmount: unmount
|
|
25412
25418
|
});
|
|
25413
|
-
case
|
|
25414
|
-
_context2.prev =
|
|
25415
|
-
_context2.t0 = _context2["catch"](
|
|
25419
|
+
case 11:
|
|
25420
|
+
_context2.prev = 11;
|
|
25421
|
+
_context2.t0 = _context2["catch"](3);
|
|
25416
25422
|
console.log('critical error', _context2.t0);
|
|
25417
25423
|
if (critical != undefined) {
|
|
25418
25424
|
critical(_context2.t0);
|
|
25419
25425
|
}
|
|
25420
|
-
case
|
|
25426
|
+
case 15:
|
|
25421
25427
|
case "end":
|
|
25422
25428
|
return _context2.stop();
|
|
25423
25429
|
}
|
|
25424
|
-
}, _callee2, null, [[
|
|
25430
|
+
}, _callee2, null, [[3, 11]]);
|
|
25425
25431
|
}));
|
|
25426
25432
|
return function Payment(_x2) {
|
|
25427
25433
|
return _ref4.apply(this, arguments);
|