@lydianpay/sdk-web 2.0.3 → 2.1.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.
@@ -1,4 +1,4 @@
1
- import { g as Qt, i as Fe, I as ft, h as pt, b as jn, s as Bn } from "./index-DJf7Eh8P.js";
1
+ import { g as Qt, i as Fe, I as ft, h as pt, b as jn, s as Bn } from "./index-BdyjcbDf.js";
2
2
  var Oe = { exports: {} }, gt;
3
3
  function Wn() {
4
4
  return gt || (gt = 1, (function(t) {
@@ -38,9 +38,9 @@ function Wn() {
38
38
  var p = n ? n + d : d, g = this._events[p];
39
39
  return g ? g.fn ? 1 : g.length : 0;
40
40
  }, l.prototype.emit = function(d, p, g, o, c, h) {
41
- var E = n ? n + d : d;
42
- if (!this._events[E]) return !1;
43
- var _ = this._events[E], I = arguments.length, v, k;
41
+ var k = n ? n + d : d;
42
+ if (!this._events[k]) return !1;
43
+ var _ = this._events[k], I = arguments.length, v, E;
44
44
  if (_.fn) {
45
45
  switch (_.once && this.removeListener(d, _.fn, void 0, !0), I) {
46
46
  case 1:
@@ -56,29 +56,29 @@ function Wn() {
56
56
  case 6:
57
57
  return _.fn.call(_.context, p, g, o, c, h), !0;
58
58
  }
59
- for (k = 1, v = new Array(I - 1); k < I; k++)
60
- v[k - 1] = arguments[k];
59
+ for (E = 1, v = new Array(I - 1); E < I; E++)
60
+ v[E - 1] = arguments[E];
61
61
  _.fn.apply(_.context, v);
62
62
  } else {
63
63
  var C = _.length, y;
64
- for (k = 0; k < C; k++)
65
- switch (_[k].once && this.removeListener(d, _[k].fn, void 0, !0), I) {
64
+ for (E = 0; E < C; E++)
65
+ switch (_[E].once && this.removeListener(d, _[E].fn, void 0, !0), I) {
66
66
  case 1:
67
- _[k].fn.call(_[k].context);
67
+ _[E].fn.call(_[E].context);
68
68
  break;
69
69
  case 2:
70
- _[k].fn.call(_[k].context, p);
70
+ _[E].fn.call(_[E].context, p);
71
71
  break;
72
72
  case 3:
73
- _[k].fn.call(_[k].context, p, g);
73
+ _[E].fn.call(_[E].context, p, g);
74
74
  break;
75
75
  case 4:
76
- _[k].fn.call(_[k].context, p, g, o);
76
+ _[E].fn.call(_[E].context, p, g, o);
77
77
  break;
78
78
  default:
79
79
  if (!v) for (y = 1, v = new Array(I - 1); y < I; y++)
80
80
  v[y - 1] = arguments[y];
81
- _[k].fn.apply(_[k].context, v);
81
+ _[E].fn.apply(_[E].context, v);
82
82
  }
83
83
  }
84
84
  return !0;
@@ -95,8 +95,8 @@ function Wn() {
95
95
  if (h.fn)
96
96
  h.fn === p && (!o || h.once) && (!g || h.context === g) && a(this, c);
97
97
  else {
98
- for (var E = 0, _ = [], I = h.length; E < I; E++)
99
- (h[E].fn !== p || o && !h[E].once || g && h[E].context !== g) && _.push(h[E]);
98
+ for (var k = 0, _ = [], I = h.length; k < I; k++)
99
+ (h[k].fn !== p || o && !h[k].once || g && h[k].context !== g) && _.push(h[k]);
100
100
  _.length ? this._events[c] = _.length === 1 ? _[0] : _ : a(this, c);
101
101
  }
102
102
  return this;
@@ -321,12 +321,12 @@ const L = {
321
321
  limitExceeded: (t) => $(U.rpc.limitExceeded, t)
322
322
  },
323
323
  provider: {
324
- userRejectedRequest: (t) => oe(U.provider.userRejectedRequest, t),
325
- unauthorized: (t) => oe(U.provider.unauthorized, t),
326
- unsupportedMethod: (t) => oe(U.provider.unsupportedMethod, t),
327
- disconnected: (t) => oe(U.provider.disconnected, t),
328
- chainDisconnected: (t) => oe(U.provider.chainDisconnected, t),
329
- unsupportedChain: (t) => oe(U.provider.unsupportedChain, t),
324
+ userRejectedRequest: (t) => ce(U.provider.userRejectedRequest, t),
325
+ unauthorized: (t) => ce(U.provider.unauthorized, t),
326
+ unsupportedMethod: (t) => ce(U.provider.unsupportedMethod, t),
327
+ disconnected: (t) => ce(U.provider.disconnected, t),
328
+ chainDisconnected: (t) => ce(U.provider.chainDisconnected, t),
329
+ unsupportedChain: (t) => ce(U.provider.unsupportedChain, t),
330
330
  custom: (t) => {
331
331
  if (!t || typeof t != "object" || Array.isArray(t))
332
332
  throw new Error("Ethereum Provider custom errors must provide single object argument.");
@@ -341,7 +341,7 @@ function $(t, e) {
341
341
  const [n, s] = tn(e);
342
342
  return new nn(t, n || tt(t), s);
343
343
  }
344
- function oe(t, e) {
344
+ function ce(t, e) {
345
345
  const [n, s] = tn(e);
346
346
  return new sn(t, n || tt(t), s);
347
347
  }
@@ -866,8 +866,8 @@ function gs() {
866
866
  const w = b.length;
867
867
  let H = new Uint32Array(w), W = new Uint32Array(w);
868
868
  for (let q = 0; q < w; q++) {
869
- const { h: re, l: ae } = n(b[q], m);
870
- [H[q], W[q]] = [re, ae];
869
+ const { h: ae, l: oe } = n(b[q], m);
870
+ [H[q], W[q]] = [ae, oe];
871
871
  }
872
872
  return [H, W];
873
873
  }
@@ -893,8 +893,8 @@ function gs() {
893
893
  x.rotlSH = c;
894
894
  const h = (b, m, w) => m << w | b >>> 32 - w;
895
895
  x.rotlSL = h;
896
- const E = (b, m, w) => m << w - 32 | b >>> 64 - w;
897
- x.rotlBH = E;
896
+ const k = (b, m, w) => m << w - 32 | b >>> 64 - w;
897
+ x.rotlBH = k;
898
898
  const _ = (b, m, w) => b << w - 32 | m >>> 64 - w;
899
899
  x.rotlBL = _;
900
900
  function I(b, m, w, H) {
@@ -903,8 +903,8 @@ function gs() {
903
903
  }
904
904
  const v = (b, m, w) => (b >>> 0) + (m >>> 0) + (w >>> 0);
905
905
  x.add3L = v;
906
- const k = (b, m, w, H) => m + w + H + (b / 2 ** 32 | 0) | 0;
907
- x.add3H = k;
906
+ const E = (b, m, w, H) => m + w + H + (b / 2 ** 32 | 0) | 0;
907
+ x.add3H = E;
908
908
  const C = (b, m, w, H) => (b >>> 0) + (m >>> 0) + (w >>> 0) + (H >>> 0);
909
909
  x.add4L = C;
910
910
  const y = (b, m, w, H, W) => m + w + H + W + (b / 2 ** 32 | 0) | 0;
@@ -927,11 +927,11 @@ function gs() {
927
927
  rotr32L: o,
928
928
  rotlSH: c,
929
929
  rotlSL: h,
930
- rotlBH: E,
930
+ rotlBH: k,
931
931
  rotlBL: _,
932
932
  add: I,
933
933
  add3L: v,
934
- add3H: k,
934
+ add3H: E,
935
935
  add4L: C,
936
936
  add4H: y,
937
937
  add5H: M,
@@ -947,7 +947,7 @@ var It;
947
947
  function ms() {
948
948
  return It || (It = 1, (function(t) {
949
949
  /*! noble-hashes - MIT License (c) 2022 Paul Miller (paulmillr.com) */
950
- Object.defineProperty(t, "__esModule", { value: !0 }), t.wrapXOFConstructorWithOpts = t.wrapConstructorWithOpts = t.wrapConstructor = t.Hash = t.nextTick = t.swap32IfBE = t.byteSwapIfBE = t.swap8IfBE = t.isLE = void 0, t.isBytes = n, t.anumber = s, t.abytes = r, t.ahash = i, t.aexists = a, t.aoutput = l, t.u8 = u, t.u32 = d, t.clean = p, t.createView = g, t.rotr = o, t.rotl = c, t.byteSwap = h, t.byteSwap32 = E, t.bytesToHex = v, t.hexToBytes = y, t.asyncLoop = M, t.utf8ToBytes = P, t.bytesToUtf8 = b, t.toBytes = m, t.kdfInputToBytes = w, t.concatBytes = H, t.checkOpts = W, t.createHasher = re, t.createOptHasher = ae, t.createXOFer = se, t.randomBytes = Hn;
950
+ Object.defineProperty(t, "__esModule", { value: !0 }), t.wrapXOFConstructorWithOpts = t.wrapConstructorWithOpts = t.wrapConstructor = t.Hash = t.nextTick = t.swap32IfBE = t.byteSwapIfBE = t.swap8IfBE = t.isLE = void 0, t.isBytes = n, t.anumber = s, t.abytes = r, t.ahash = i, t.aexists = a, t.aoutput = l, t.u8 = u, t.u32 = d, t.clean = p, t.createView = g, t.rotr = o, t.rotl = c, t.byteSwap = h, t.byteSwap32 = k, t.bytesToHex = v, t.hexToBytes = y, t.asyncLoop = M, t.utf8ToBytes = P, t.bytesToUtf8 = b, t.toBytes = m, t.kdfInputToBytes = w, t.concatBytes = H, t.checkOpts = W, t.createHasher = ae, t.createOptHasher = oe, t.createXOFer = se, t.randomBytes = Hn;
951
951
  const e = /* @__PURE__ */ _s();
952
952
  function n(f) {
953
953
  return f instanceof Uint8Array || ArrayBuffer.isView(f) && f.constructor.name === "Uint8Array";
@@ -1003,12 +1003,12 @@ function ms() {
1003
1003
  return f << 24 & 4278190080 | f << 8 & 16711680 | f >>> 8 & 65280 | f >>> 24 & 255;
1004
1004
  }
1005
1005
  t.swap8IfBE = t.isLE ? (f) => f : (f) => h(f), t.byteSwapIfBE = t.swap8IfBE;
1006
- function E(f) {
1006
+ function k(f) {
1007
1007
  for (let S = 0; S < f.length; S++)
1008
1008
  f[S] = h(f[S]);
1009
1009
  return f;
1010
1010
  }
1011
- t.swap32IfBE = t.isLE ? (f) => f : E;
1011
+ t.swap32IfBE = t.isLE ? (f) => f : k;
1012
1012
  const _ = /* @ts-ignore */ typeof Uint8Array.from([]).toHex == "function" && typeof Uint8Array.fromHex == "function", I = /* @__PURE__ */ Array.from({ length: 256 }, (f, S) => S.toString(16).padStart(2, "0"));
1013
1013
  function v(f) {
1014
1014
  if (r(f), _)
@@ -1018,14 +1018,14 @@ function ms() {
1018
1018
  S += I[f[N]];
1019
1019
  return S;
1020
1020
  }
1021
- const k = { _0: 48, _9: 57, A: 65, F: 70, a: 97, f: 102 };
1021
+ const E = { _0: 48, _9: 57, A: 65, F: 70, a: 97, f: 102 };
1022
1022
  function C(f) {
1023
- if (f >= k._0 && f <= k._9)
1024
- return f - k._0;
1025
- if (f >= k.A && f <= k.F)
1026
- return f - (k.A - 10);
1027
- if (f >= k.a && f <= k.f)
1028
- return f - (k.a - 10);
1023
+ if (f >= E._0 && f <= E._9)
1024
+ return f - E._0;
1025
+ if (f >= E.A && f <= E.F)
1026
+ return f - (E.A - 10);
1027
+ if (f >= E.a && f <= E.f)
1028
+ return f - (E.a - 10);
1029
1029
  }
1030
1030
  function y(f) {
1031
1031
  if (typeof f != "string")
@@ -1092,11 +1092,11 @@ function ms() {
1092
1092
  class q {
1093
1093
  }
1094
1094
  t.Hash = q;
1095
- function re(f) {
1095
+ function ae(f) {
1096
1096
  const S = (D) => f().update(m(D)).digest(), N = f();
1097
1097
  return S.outputLen = N.outputLen, S.blockLen = N.blockLen, S.create = () => f(), S;
1098
1098
  }
1099
- function ae(f) {
1099
+ function oe(f) {
1100
1100
  const S = (D, V) => f(V).update(m(D)).digest(), N = f({});
1101
1101
  return S.outputLen = N.outputLen, S.blockLen = N.blockLen, S.create = (D) => f(D), S;
1102
1102
  }
@@ -1104,7 +1104,7 @@ function ms() {
1104
1104
  const S = (D, V) => f(V).update(m(D)).digest(), N = f({});
1105
1105
  return S.outputLen = N.outputLen, S.blockLen = N.blockLen, S.create = (D) => f(D), S;
1106
1106
  }
1107
- t.wrapConstructor = re, t.wrapConstructorWithOpts = ae, t.wrapXOFConstructorWithOpts = se;
1107
+ t.wrapConstructor = ae, t.wrapConstructorWithOpts = oe, t.wrapXOFConstructorWithOpts = se;
1108
1108
  function Hn(f = 32) {
1109
1109
  if (e.crypto && typeof e.crypto.getRandomValues == "function")
1110
1110
  return e.crypto.getRandomValues(new Uint8Array(f));
@@ -1126,20 +1126,20 @@ function ys() {
1126
1126
  y = (y << s ^ (y >> i) * l) % a, y & r && (P ^= s << (s << /* @__PURE__ */ BigInt(b)) - s);
1127
1127
  p.push(P);
1128
1128
  }
1129
- const g = (0, t.split)(p, !0), o = g[0], c = g[1], h = (C, y, A) => A > 32 ? (0, t.rotlBH)(C, y, A) : (0, t.rotlSH)(C, y, A), E = (C, y, A) => A > 32 ? (0, t.rotlBL)(C, y, A) : (0, t.rotlSL)(C, y, A);
1129
+ const g = (0, t.split)(p, !0), o = g[0], c = g[1], h = (C, y, A) => A > 32 ? (0, t.rotlBH)(C, y, A) : (0, t.rotlSH)(C, y, A), k = (C, y, A) => A > 32 ? (0, t.rotlBL)(C, y, A) : (0, t.rotlSL)(C, y, A);
1130
1130
  function _(C, y = 24) {
1131
1131
  const A = new Uint32Array(10);
1132
1132
  for (let M = 24 - y; M < 24; M++) {
1133
1133
  for (let m = 0; m < 10; m++)
1134
1134
  A[m] = C[m] ^ C[m + 10] ^ C[m + 20] ^ C[m + 30] ^ C[m + 40];
1135
1135
  for (let m = 0; m < 10; m += 2) {
1136
- const w = (m + 8) % 10, H = (m + 2) % 10, W = A[H], q = A[H + 1], re = h(W, q, 1) ^ A[w], ae = E(W, q, 1) ^ A[w + 1];
1136
+ const w = (m + 8) % 10, H = (m + 2) % 10, W = A[H], q = A[H + 1], ae = h(W, q, 1) ^ A[w], oe = k(W, q, 1) ^ A[w + 1];
1137
1137
  for (let se = 0; se < 50; se += 10)
1138
- C[m + se] ^= re, C[m + se + 1] ^= ae;
1138
+ C[m + se] ^= ae, C[m + se + 1] ^= oe;
1139
1139
  }
1140
1140
  let P = C[2], b = C[3];
1141
1141
  for (let m = 0; m < 24; m++) {
1142
- const w = d[m], H = h(P, b, w), W = E(P, b, w), q = u[m];
1142
+ const w = d[m], H = h(P, b, w), W = k(P, b, w), q = u[m];
1143
1143
  P = C[q], b = C[q + 1], C[q] = H, C[q + 1] = W;
1144
1144
  }
1145
1145
  for (let m = 0; m < 50; m += 10) {
@@ -1220,8 +1220,8 @@ function ys() {
1220
1220
  T.Keccak = I;
1221
1221
  const v = (C, y, A) => (0, e.createHasher)(() => new I(y, C, A));
1222
1222
  T.sha3_224 = v(6, 144, 224 / 8), T.sha3_256 = v(6, 136, 256 / 8), T.sha3_384 = v(6, 104, 384 / 8), T.sha3_512 = v(6, 72, 512 / 8), T.keccak_224 = v(1, 144, 224 / 8), T.keccak_256 = v(1, 136, 256 / 8), T.keccak_384 = v(1, 104, 384 / 8), T.keccak_512 = v(1, 72, 512 / 8);
1223
- const k = (C, y, A) => (0, e.createXOFer)((M = {}) => new I(y, C, M.dkLen === void 0 ? A : M.dkLen, !0));
1224
- return T.shake128 = k(31, 168, 128 / 8), T.shake256 = k(31, 136, 256 / 8), T;
1223
+ const E = (C, y, A) => (0, e.createXOFer)((M = {}) => new I(y, C, M.dkLen === void 0 ? A : M.dkLen, !0));
1224
+ return T.shake128 = E(31, 168, 128 / 8), T.shake256 = E(31, 136, 256 / 8), T;
1225
1225
  }
1226
1226
  var Be, St;
1227
1227
  function fn() {
@@ -1235,26 +1235,26 @@ function fn() {
1235
1235
  return c.toString(2).length;
1236
1236
  }
1237
1237
  function s(c, h) {
1238
- let E = c.toString(16);
1239
- E.length % 2 !== 0 && (E = "0" + E);
1240
- const _ = E.match(/.{1,2}/g).map((I) => parseInt(I, 16));
1238
+ let k = c.toString(16);
1239
+ k.length % 2 !== 0 && (k = "0" + k);
1240
+ const _ = k.match(/.{1,2}/g).map((I) => parseInt(I, 16));
1241
1241
  for (; _.length < h; )
1242
1242
  _.unshift(0);
1243
1243
  return Buffer.from(_);
1244
1244
  }
1245
1245
  function r(c, h) {
1246
- const E = c < 0n;
1246
+ const k = c < 0n;
1247
1247
  let _;
1248
- if (E) {
1248
+ if (k) {
1249
1249
  const I = (1n << BigInt(h)) - 1n;
1250
1250
  _ = (~c & I) + 1n;
1251
1251
  } else
1252
1252
  _ = c;
1253
1253
  return _ &= (1n << BigInt(h)) - 1n, _;
1254
1254
  }
1255
- function i(c, h, E) {
1255
+ function i(c, h, k) {
1256
1256
  const _ = e(h);
1257
- return c = l(c), E ? c.length < h ? (c.copy(_), _) : c.slice(0, h) : c.length < h ? (c.copy(_, h - c.length), _) : c.slice(-h);
1257
+ return c = l(c), k ? c.length < h ? (c.copy(_), _) : c.slice(0, h) : c.length < h ? (c.copy(_, h - c.length), _) : c.slice(-h);
1258
1258
  }
1259
1259
  function a(c, h) {
1260
1260
  return i(c, h, !0);
@@ -1336,7 +1336,7 @@ function ws() {
1336
1336
  throw new Error("Argument is not a number");
1337
1337
  }
1338
1338
  function a(o, c) {
1339
- var h, E, _, I;
1339
+ var h, k, _, I;
1340
1340
  if (o === "address")
1341
1341
  return a("uint160", i(c));
1342
1342
  if (o === "bool")
@@ -1366,26 +1366,26 @@ function ws() {
1366
1366
  } else if (o.startsWith("uint")) {
1367
1367
  if (h = n(o), h % 8 || h < 8 || h > 256)
1368
1368
  throw new Error("Invalid uint<N> width: " + h);
1369
- E = i(c);
1370
- const k = t.bitLengthFromBigInt(E);
1371
- if (k > h)
1372
- throw new Error("Supplied uint exceeds width: " + h + " vs " + k);
1373
- if (E < 0)
1369
+ k = i(c);
1370
+ const E = t.bitLengthFromBigInt(k);
1371
+ if (E > h)
1372
+ throw new Error("Supplied uint exceeds width: " + h + " vs " + E);
1373
+ if (k < 0)
1374
1374
  throw new Error("Supplied uint is negative");
1375
- return t.bufferBEFromBigInt(E, 32);
1375
+ return t.bufferBEFromBigInt(k, 32);
1376
1376
  } else if (o.startsWith("int")) {
1377
1377
  if (h = n(o), h % 8 || h < 8 || h > 256)
1378
1378
  throw new Error("Invalid int<N> width: " + h);
1379
- E = i(c);
1380
- const k = t.bitLengthFromBigInt(E);
1381
- if (k > h)
1382
- throw new Error("Supplied int exceeds width: " + h + " vs " + k);
1383
- const C = t.twosFromBigInt(E, 256);
1379
+ k = i(c);
1380
+ const E = t.bitLengthFromBigInt(k);
1381
+ if (E > h)
1382
+ throw new Error("Supplied int exceeds width: " + h + " vs " + E);
1383
+ const C = t.twosFromBigInt(k, 256);
1384
1384
  return t.bufferBEFromBigInt(C, 32);
1385
1385
  } else if (o.startsWith("ufixed")) {
1386
- if (h = s(o), E = i(c), E < 0)
1386
+ if (h = s(o), k = i(c), k < 0)
1387
1387
  throw new Error("Supplied ufixed is negative");
1388
- return a("uint256", E * BigInt(2) ** BigInt(h[1]));
1388
+ return a("uint256", k * BigInt(2) ** BigInt(h[1]));
1389
1389
  } else if (o.startsWith("fixed"))
1390
1390
  return h = s(o), a("int256", i(c) * BigInt(2) ** BigInt(h[1]));
1391
1391
  }
@@ -1398,46 +1398,46 @@ function ws() {
1398
1398
  return o.lastIndexOf("]") === o.length - 1;
1399
1399
  }
1400
1400
  function d(o, c) {
1401
- var h = [], E = [], _ = 32 * o.length;
1401
+ var h = [], k = [], _ = 32 * o.length;
1402
1402
  for (var I in o) {
1403
- var v = e(o[I]), k = c[I], C = a(v, k);
1404
- l(v) ? (h.push(a("uint256", _)), E.push(C), _ += C.length) : h.push(C);
1403
+ var v = e(o[I]), E = c[I], C = a(v, E);
1404
+ l(v) ? (h.push(a("uint256", _)), k.push(C), _ += C.length) : h.push(C);
1405
1405
  }
1406
- return Buffer.concat(h.concat(E));
1406
+ return Buffer.concat(h.concat(k));
1407
1407
  }
1408
1408
  function p(o, c) {
1409
1409
  if (o.length !== c.length)
1410
1410
  throw new Error("Number of types are not matching the values");
1411
- for (var h, E, _ = [], I = 0; I < o.length; I++) {
1412
- var v = e(o[I]), k = c[I];
1411
+ for (var h, k, _ = [], I = 0; I < o.length; I++) {
1412
+ var v = e(o[I]), E = c[I];
1413
1413
  if (v === "bytes")
1414
- _.push(k);
1414
+ _.push(E);
1415
1415
  else if (v === "string")
1416
- _.push(new Buffer(k, "utf8"));
1416
+ _.push(new Buffer(E, "utf8"));
1417
1417
  else if (v === "bool")
1418
- _.push(new Buffer(k ? "01" : "00", "hex"));
1418
+ _.push(new Buffer(E ? "01" : "00", "hex"));
1419
1419
  else if (v === "address")
1420
- _.push(t.setLength(k, 20));
1420
+ _.push(t.setLength(E, 20));
1421
1421
  else if (v.startsWith("bytes")) {
1422
1422
  if (h = n(v), h < 1 || h > 32)
1423
1423
  throw new Error("Invalid bytes<N> width: " + h);
1424
- _.push(t.setLengthRight(k, h));
1424
+ _.push(t.setLengthRight(E, h));
1425
1425
  } else if (v.startsWith("uint")) {
1426
1426
  if (h = n(v), h % 8 || h < 8 || h > 256)
1427
1427
  throw new Error("Invalid uint<N> width: " + h);
1428
- E = i(k);
1429
- const C = t.bitLengthFromBigInt(E);
1428
+ k = i(E);
1429
+ const C = t.bitLengthFromBigInt(k);
1430
1430
  if (C > h)
1431
1431
  throw new Error("Supplied uint exceeds width: " + h + " vs " + C);
1432
- _.push(t.bufferBEFromBigInt(E, h / 8));
1432
+ _.push(t.bufferBEFromBigInt(k, h / 8));
1433
1433
  } else if (v.startsWith("int")) {
1434
1434
  if (h = n(v), h % 8 || h < 8 || h > 256)
1435
1435
  throw new Error("Invalid int<N> width: " + h);
1436
- E = i(k);
1437
- const C = t.bitLengthFromBigInt(E);
1436
+ k = i(E);
1437
+ const C = t.bitLengthFromBigInt(k);
1438
1438
  if (C > h)
1439
1439
  throw new Error("Supplied int exceeds width: " + h + " vs " + C);
1440
- const y = t.twosFromBigInt(E, h);
1440
+ const y = t.twosFromBigInt(k, h);
1441
1441
  _.push(t.bufferBEFromBigInt(y, h / 8));
1442
1442
  } else
1443
1443
  throw new Error("Unsupported or invalid type: " + v);
@@ -1501,7 +1501,7 @@ function bs() {
1501
1501
  if (c === "string")
1502
1502
  return typeof h == "string" && (h = Buffer.from(h, "utf8")), ["bytes32", t.keccak(h)];
1503
1503
  if (c.lastIndexOf("]") === c.length - 1) {
1504
- const E = c.slice(0, c.lastIndexOf("[")), _ = h.map((I) => g(o, E, I));
1504
+ const k = c.slice(0, c.lastIndexOf("[")), _ = h.map((I) => g(o, k, I));
1505
1505
  return ["bytes32", t.keccak(e.rawEncode(
1506
1506
  _.map(([I]) => I),
1507
1507
  _.map(([, I]) => I)
@@ -2127,17 +2127,17 @@ class xs {
2127
2127
  }
2128
2128
  }
2129
2129
  const Mt = "session:id", Pt = "session:secret", Rt = "session:linked";
2130
- class ce {
2130
+ class le {
2131
2131
  constructor(e, n, s, r = !1) {
2132
2132
  this.storage = e, this.id = n, this.secret = s, this.key = jn(Bn(`${n}, ${s} WalletLink`)), this._linked = !!r;
2133
2133
  }
2134
2134
  static create(e) {
2135
2135
  const n = ie(16), s = ie(32);
2136
- return new ce(e, n, s).save();
2136
+ return new le(e, n, s).save();
2137
2137
  }
2138
2138
  static load(e) {
2139
2139
  const n = e.getItem(Mt), s = e.getItem(Rt), r = e.getItem(Pt);
2140
- return n && r ? new ce(e, n, r, s === "1") : null;
2140
+ return n && r ? new le(e, n, r, s === "1") : null;
2141
2141
  }
2142
2142
  get linked() {
2143
2143
  return this._linked;
@@ -2214,15 +2214,15 @@ function Te(t) {
2214
2214
  function Ie(t, e) {
2215
2215
  this.props = t, this.context = e;
2216
2216
  }
2217
- function le(t, e) {
2218
- if (e == null) return t.__ ? le(t.__, t.__i + 1) : null;
2217
+ function re(t, e) {
2218
+ if (e == null) return t.__ ? re(t.__, t.__i + 1) : null;
2219
2219
  for (var n; e < t.__k.length; e++) if ((n = t.__k[e]) != null && n.__e != null) return n.__e;
2220
- return typeof t.type == "function" ? le(t) : null;
2220
+ return typeof t.type == "function" ? re(t) : null;
2221
2221
  }
2222
2222
  function Os(t) {
2223
2223
  if (t.__P && t.__d) {
2224
2224
  var e = t.__v, n = e.__e, s = [], r = [], i = X({}, e);
2225
- i.__v = e.__v + 1, O.vnode && O.vnode(i), lt(t.__P, i, e, t.__n, t.__P.namespaceURI, 32 & e.__u ? [n] : null, s, n ?? le(e), !!(32 & e.__u), r), i.__v = e.__v, i.__.__k[i.__i] = i, Cn(s, i, r), e.__e = e.__ = null, i.__e != n && vn(i);
2225
+ i.__v = e.__v + 1, O.vnode && O.vnode(i), lt(t.__P, i, e, t.__n, t.__P.namespaceURI, 32 & e.__u ? [n] : null, s, n ?? re(e), !!(32 & e.__u), r), i.__v = e.__v, i.__.__k[i.__i] = i, Cn(s, i, r), e.__e = e.__ = null, i.__e != n && vn(i);
2226
2226
  }
2227
2227
  }
2228
2228
  function vn(t) {
@@ -2241,23 +2241,23 @@ function xe() {
2241
2241
  }
2242
2242
  }
2243
2243
  function kn(t, e, n, s, r, i, a, l, u, d, p) {
2244
- var g, o, c, h, E, _, I, v = s && s.__k || Ae, k = e.length;
2245
- for (u = Ns(n, e, v, u, k), g = 0; g < k; g++) (c = n.__k[g]) != null && (o = c.__i != -1 && v[c.__i] || Se, c.__i = g, _ = lt(t, c, o, r, i, a, l, u, d, p), h = c.__e, c.ref && o.ref != c.ref && (o.ref && dt(o.ref, null, c), p.push(c.ref, c.__c || h, c)), E == null && h != null && (E = h), (I = !!(4 & c.__u)) || o.__k === c.__k ? (u = En(c, u, t, I), I && o.__e && (o.__e = null)) : typeof c.type == "function" && _ !== void 0 ? u = _ : h && (u = h.nextSibling), c.__u &= -7);
2246
- return n.__e = E, u;
2244
+ var g, o, c, h, k, _, I = s && s.__k || Ae, v = e.length;
2245
+ for (u = Ns(n, e, I, u, v), g = 0; g < v; g++) (c = n.__k[g]) != null && (o = c.__i != -1 && I[c.__i] || Se, c.__i = g, _ = lt(t, c, o, r, i, a, l, u, d, p), h = c.__e, c.ref && o.ref != c.ref && (o.ref && dt(o.ref, null, c), p.push(c.ref, c.__c || h, c)), k == null && h != null && (k = h), 4 & c.__u ? (u = En(c, u, t), o.__e && (o.__e = null)) : typeof c.type == "function" && _ !== void 0 ? u = _ : h && (u = h.nextSibling), c.__u &= -7);
2246
+ return n.__e = k, u;
2247
2247
  }
2248
2248
  function Ns(t, e, n, s, r) {
2249
2249
  var i, a, l, u, d, p = n.length, g = p, o = 0;
2250
2250
  for (t.__k = new Array(r), i = 0; i < r; i++) (a = e[i]) != null && typeof a != "boolean" && typeof a != "function" ? (typeof a == "string" || typeof a == "number" || typeof a == "bigint" || a.constructor == String ? a = t.__k[i] = Ee(null, a, null, null, null) : Re(a) ? a = t.__k[i] = Ee(Te, { children: a }, null, null, null) : a.constructor === void 0 && a.__b > 0 ? a = t.__k[i] = Ee(a.type, a.props, a.key, a.ref ? a.ref : null, a.__v) : t.__k[i] = a, u = i + o, a.__ = t, a.__b = t.__b + 1, l = null, (d = a.__i = Ds(a, n, u, g)) != -1 && (g--, (l = n[d]) && (l.__u |= 2)), l == null || l.__v == null ? (d == -1 && (r > p ? o-- : r < p && o++), typeof a.type != "function" && (a.__u |= 4)) : d != u && (d == u - 1 ? o-- : d == u + 1 ? o++ : (d > u ? o-- : o++, a.__u |= 4))) : t.__k[i] = null;
2251
- if (g) for (i = 0; i < p; i++) (l = n[i]) != null && (2 & l.__u) == 0 && (l.__e == s && (s = le(l)), An(l, l));
2251
+ if (g) for (i = 0; i < p; i++) (l = n[i]) != null && (2 & l.__u) == 0 && (l.__e == s && (s = re(l)), An(l, l));
2252
2252
  return s;
2253
2253
  }
2254
- function En(t, e, n, s) {
2255
- var r, i;
2254
+ function En(t, e, n) {
2255
+ var s, r;
2256
2256
  if (typeof t.type == "function") {
2257
- for (r = t.__k, i = 0; r && i < r.length; i++) r[i] && (r[i].__ = t, e = En(r[i], e, n, s));
2257
+ for (s = t.__k, r = 0; s && r < s.length; r++) s[r] && (s[r].__ = t, e = En(s[r], e, n));
2258
2258
  return e;
2259
2259
  }
2260
- t.__e != e && (s && (e && t.type && !e.parentNode && (e = le(t)), n.insertBefore(t.__e, e || null)), e = t.__e);
2260
+ t.__e != e && (e && t.type && !e.parentNode && (e = re(t)), e = n.insertBefore(t.__e, e || null));
2261
2261
  do
2262
2262
  e = e && e.nextSibling;
2263
2263
  while (e != null && e.nodeType == 8);
@@ -2303,29 +2303,29 @@ function Dt(t) {
2303
2303
  };
2304
2304
  }
2305
2305
  function lt(t, e, n, s, r, i, a, l, u, d) {
2306
- var p, g, o, c, h, E, _, I, v, k, C, y, A, M, P, b, m = e.type;
2306
+ var p, g, o, c, h, k, _, I, v, E, C, y, A, M, P, b, m = e.type;
2307
2307
  if (e.constructor !== void 0) return null;
2308
2308
  128 & n.__u && (u = !!(32 & n.__u), i = [l = e.__e = n.__e]), (p = O.__b) && p(e);
2309
2309
  e: if (typeof m == "function") {
2310
2310
  g = a.length;
2311
2311
  try {
2312
- if (v = e.props, k = m.prototype && m.prototype.render, C = (p = m.contextType) && s[p.__c], y = p ? C ? C.props.value : p.__ : s, n.__c ? I = (o = e.__c = n.__c).__ = o.__E : (k ? e.__c = o = new m(v, y) : (e.__c = o = new Ie(v, y), o.constructor = m, o.render = Us), C && C.sub(o), o.state || (o.state = {}), o.__n = s, c = o.__d = !0, o.__h = [], o._sb = []), k && o.__s == null && (o.__s = o.state), k && m.getDerivedStateFromProps != null && (o.__s == o.state && (o.__s = X({}, o.__s)), X(o.__s, m.getDerivedStateFromProps(v, o.__s))), h = o.props, E = o.state, o.__v = e, c) k && m.getDerivedStateFromProps == null && o.componentWillMount != null && o.componentWillMount(), k && o.componentDidMount != null && o.__h.push(o.componentDidMount);
2312
+ if (v = e.props, E = m.prototype && m.prototype.render, C = (p = m.contextType) && s[p.__c], y = p ? C ? C.props.value : p.__ : s, n.__c ? I = (o = e.__c = n.__c).__ = o.__E : (E ? e.__c = o = new m(v, y) : (e.__c = o = new Ie(v, y), o.constructor = m, o.render = Us), C && C.sub(o), o.state || (o.state = {}), o.__n = s, c = o.__d = !0, o.__h = [], o._sb = []), E && o.__s == null && (o.__s = o.state), E && m.getDerivedStateFromProps != null && (o.__s == o.state && (o.__s = X({}, o.__s)), X(o.__s, m.getDerivedStateFromProps(v, o.__s))), h = o.props, k = o.state, o.__v = e, c) E && m.getDerivedStateFromProps == null && o.componentWillMount != null && o.componentWillMount(), E && o.componentDidMount != null && o.__h.push(o.componentDidMount);
2313
2313
  else {
2314
- if (k && m.getDerivedStateFromProps == null && v !== h && o.componentWillReceiveProps != null && o.componentWillReceiveProps(v, y), e.__v == n.__v || !o.__e && o.shouldComponentUpdate != null && o.shouldComponentUpdate(v, o.__s, y) === !1) {
2314
+ if (E && m.getDerivedStateFromProps == null && v !== h && o.componentWillReceiveProps != null && o.componentWillReceiveProps(v, y), e.__v == n.__v || !o.__e && o.shouldComponentUpdate != null && o.shouldComponentUpdate(v, o.__s, y) === !1) {
2315
2315
  e.__v != n.__v && (o.props = v, o.state = o.__s, o.__d = !1), e.__e = n.__e, e.__k = n.__k, e.__k.some(function(w) {
2316
2316
  w && (w.__ = e);
2317
- }), Ae.push.apply(o.__h, o._sb), o._sb = [], o.__h.length && a.push(o);
2317
+ }), Ae.push.apply(o.__h, o._sb), o._sb = [], o.__h.length && a.push(o), l = re(n);
2318
2318
  break e;
2319
2319
  }
2320
- o.componentWillUpdate != null && o.componentWillUpdate(v, o.__s, y), k && o.componentDidUpdate != null && o.__h.push(function() {
2321
- o.componentDidUpdate(h, E, _);
2320
+ o.componentWillUpdate != null && o.componentWillUpdate(v, o.__s, y), E && o.componentDidUpdate != null && o.__h.push(function() {
2321
+ o.componentDidUpdate(h, k, _);
2322
2322
  });
2323
2323
  }
2324
- if (o.context = y, o.props = v, o.__P = t, o.__e = !1, A = O.__r, M = 0, k) o.state = o.__s, o.__d = !1, A && A(e), p = o.render(o.props, o.state, o.context), Ae.push.apply(o.__h, o._sb), o._sb = [];
2324
+ if (o.context = y, o.props = v, o.__P = t, o.__e = !1, A = O.__r, M = 0, E) o.state = o.__s, o.__d = !1, A && A(e), p = o.render(o.props, o.state, o.context), Ae.push.apply(o.__h, o._sb), o._sb = [];
2325
2325
  else do
2326
2326
  o.__d = !1, A && A(e), p = o.render(o.props, o.state, o.context), o.state = o.__s;
2327
2327
  while (o.__d && ++M < 25);
2328
- o.state = o.__s, o.getChildContext != null && (s = X(X({}, s), o.getChildContext())), k && !c && o.getSnapshotBeforeUpdate != null && (_ = o.getSnapshotBeforeUpdate(h, E)), P = p != null && p.type === Te && p.key == null ? Sn(p.props.children) : p, l = kn(t, Re(P) ? P : [P], e, n, s, r, i, a, l, u, d), o.base = e.__e, e.__u &= -161, o.__h.length && a.push(o), I && (o.__E = o.__ = null);
2328
+ o.state = o.__s, o.getChildContext != null && (s = X(X({}, s), o.getChildContext())), E && !c && o.getSnapshotBeforeUpdate != null && (_ = o.getSnapshotBeforeUpdate(h, k)), P = p != null && p.type === Te && p.key == null ? Sn(p.props.children) : p, l = kn(t, Re(P) ? P : [P], e, n, s, r, i, a, l, u, d), o.base = e.__e, e.__u &= -161, o.__h.length && a.push(o), I && (o.__E = o.__ = null);
2329
2329
  } catch (w) {
2330
2330
  if (a.length = g, e.__v = null, u || i != null) {
2331
2331
  if (w.then) {
@@ -2357,7 +2357,7 @@ function Sn(t) {
2357
2357
  return typeof t != "object" || t == null || t.__b > 0 ? t : Re(t) ? t.map(Sn) : t.constructor !== void 0 ? null : X({}, t);
2358
2358
  }
2359
2359
  function Hs(t, e, n, s, r, i, a, l, u) {
2360
- var d, p, g, o, c, h, E, _ = n.props || Se, I = e.props, v = e.type;
2360
+ var d, p, g, o, c, h, k, _ = n.props || Se, I = e.props, v = e.type;
2361
2361
  if (v == "svg" ? r = "http://www.w3.org/2000/svg" : v == "math" ? r = "http://www.w3.org/1998/Math/MathML" : r || (r = "http://www.w3.org/1999/xhtml"), i != null) {
2362
2362
  for (d = 0; d < i.length; d++) if ((c = i[d]) && "setAttribute" in c == !!v && (v ? c.localName == v : c.nodeType == 3)) {
2363
2363
  t = c, i[d] = null;
@@ -2372,10 +2372,10 @@ function Hs(t, e, n, s, r, i, a, l, u) {
2372
2372
  else {
2373
2373
  if (i = v == "textarea" && I.defaultValue != null ? null : i && Pe.call(t.childNodes), !l && i != null) for (_ = {}, d = 0; d < t.attributes.length; d++) _[(c = t.attributes[d]).name] = c.value;
2374
2374
  for (d in _) c = _[d], d == "dangerouslySetInnerHTML" ? g = c : d == "children" || d in I || d == "value" && "defaultValue" in I || d == "checked" && "defaultChecked" in I || we(t, d, null, c, r);
2375
- for (d in I) c = I[d], d == "children" ? o = c : d == "dangerouslySetInnerHTML" ? p = c : d == "value" ? h = c : d == "checked" ? E = c : l && typeof c != "function" || _[d] === c || we(t, d, c, _[d], r);
2375
+ for (d in I) c = I[d], d == "children" ? o = c : d == "dangerouslySetInnerHTML" ? p = c : d == "value" ? h = c : d == "checked" ? k = c : l && typeof c != "function" || _[d] === c || we(t, d, c, _[d], r);
2376
2376
  if (p) l || g && (p.__html == g.__html || p.__html == t.innerHTML) || (t.innerHTML = p.__html), e.__k = [];
2377
- else if (g && (t.innerHTML = ""), kn(e.type == "template" ? t.content : t, Re(o) ? o : [o], e, n, s, v == "foreignObject" ? "http://www.w3.org/1999/xhtml" : r, i, a, i ? i[0] : n.__k && le(n, 0), l, u), i != null) for (d = i.length; d--; ) ct(i[d]);
2378
- l && v != "textarea" || (d = "value", v == "progress" && h == null ? t.removeAttribute("value") : h != null && (h !== t[d] || v == "progress" && !h || v == "option" && h != _[d]) && we(t, d, h, _[d], r), d = "checked", E != null && E != t[d] && we(t, d, E, _[d], r));
2377
+ else if (g && (t.innerHTML = ""), kn(e.type == "template" ? t.content : t, Re(o) ? o : [o], e, n, s, v == "foreignObject" ? "http://www.w3.org/1999/xhtml" : r, i, a, i ? i[0] : n.__k && re(n, 0), l, u), i != null) for (d = i.length; d--; ) ct(i[d]);
2378
+ l && v != "textarea" || (d = "value", v == "progress" && h == null ? t.removeAttribute("value") : h != null && (h !== t[d] || v == "progress" && !h || v == "option" && h != _[d]) && we(t, d, h, _[d], r), d = "checked", k != null && k != t[d] && we(t, d, k, _[d], r));
2379
2379
  }
2380
2380
  return t;
2381
2381
  }
@@ -2776,7 +2776,7 @@ class Q {
2776
2776
  this._session = n, this.connection = r, this.relayEventManager = new xs(), this.ui = s, this.ui.attach();
2777
2777
  }
2778
2778
  subscribe() {
2779
- const e = ce.load(this.storage) || ce.create(this.storage), { linkAPIUrl: n } = this, s = new As({
2779
+ const e = le.load(this.storage) || le.create(this.storage), { linkAPIUrl: n } = this, s = new As({
2780
2780
  session: e,
2781
2781
  linkAPIUrl: n,
2782
2782
  listener: this
@@ -2785,7 +2785,7 @@ class Q {
2785
2785
  }
2786
2786
  resetAndReload() {
2787
2787
  this.connection.destroy().then(() => {
2788
- const e = ce.load(this.storage);
2788
+ const e = le.load(this.storage);
2789
2789
  (e == null ? void 0 : e.id) === this._session.id && Y.clearAll(), document.location.reload();
2790
2790
  }).catch((e) => {
2791
2791
  });