@reown/appkit-cdn 1.0.2 → 1.0.3

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.
Files changed (35) hide show
  1. package/dist/{W3MFrameProviderSingleton-DyEiFdpq.js → W3MFrameProviderSingleton-CRF_1us_.js} +3355 -3487
  2. package/dist/{W3MFrameProviderSingleton-9N7Xjb4-.cjs → W3MFrameProviderSingleton-EQdqCGSY.cjs} +34 -34
  3. package/dist/ethers.cjs +1 -1
  4. package/dist/ethers.js +133 -139
  5. package/dist/{hooks.module-BgSrACu5.js → hooks.module-Bo49CUkD.js} +1 -1
  6. package/dist/{hooks.module-DjNSWU32.cjs → hooks.module-Dv1obaBy.cjs} +1 -1
  7. package/dist/{index-CY9GXdH8.js → index-B4aMSR4c.js} +2 -2
  8. package/dist/{index-CDogBYT6.cjs → index-BuOJ8QNL.cjs} +1 -1
  9. package/dist/{index-D_fyd8O3.js → index-ByE-R0E1.js} +2 -2
  10. package/dist/{index-BDP9SW0d.js → index-C2gFFabd.js} +2 -2
  11. package/dist/{index-BQcKnJi6.js → index-CG2NGIOC.js} +2 -2
  12. package/dist/{index-DTO1KwGw.js → index-CHb2nMaf.js} +2 -2
  13. package/dist/{index-iqke2ukg.cjs → index-CKVZVFq_.cjs} +1 -1
  14. package/dist/{index-Cs0eLnEu.cjs → index-CLxU5hsA.cjs} +1 -1
  15. package/dist/{index-B-dJOHC4.js → index-CQRSLm_m.js} +1 -1
  16. package/dist/{index-Bslsy8mP.cjs → index-CcTeiaz4.cjs} +1 -1
  17. package/dist/{index-DwKYRtI4.cjs → index-CeQNoxrU.cjs} +1 -1
  18. package/dist/{index-JGQ5x3fU.cjs → index-DH3qaBPp.cjs} +1 -1
  19. package/dist/{index-CSN-mQVF.js → index-DVFjsAEF.js} +2 -2
  20. package/dist/{index-DzhspnbK.cjs → index-DwRBfwIO.cjs} +1 -1
  21. package/dist/{index-Bw9OMS3B.cjs → index-h3CAtOy2.cjs} +1 -1
  22. package/dist/{index-DnJKKBCl.js → index-hXCH-znD.js} +2 -2
  23. package/dist/{index.es-BUHHRWJS.cjs → index.es-DnJzv0Jm.cjs} +2 -2
  24. package/dist/{index.es-DKBx9MC0.js → index.es-bcU603NI.js} +2 -2
  25. package/dist/{metamask-sdk-DRkDynNt.js → metamask-sdk-CXJHRcL2.js} +1 -1
  26. package/dist/{metamask-sdk-DW0pLP9m.cjs → metamask-sdk-my5l20D3.cjs} +1 -1
  27. package/dist/{native-CM-ttrga.cjs → native-AlGArcwp.cjs} +1 -1
  28. package/dist/{native-BTEMDqpx.js → native-CAgUwsyb.js} +1 -1
  29. package/dist/{w3m-modal-mZmS_e_d.cjs → w3m-modal-BC3zgDJa.cjs} +4 -4
  30. package/dist/{w3m-modal-VPikPCIA.js → w3m-modal-BNjtW4Kj.js} +43 -43
  31. package/dist/{wagmi-BixRJnz_.js → wagmi-BSo7cFxV.js} +1620 -1621
  32. package/dist/{wagmi-BTPiDqk7.cjs → wagmi-D-vZdxZZ.cjs} +14 -14
  33. package/dist/wagmi.cjs +1 -1
  34. package/dist/wagmi.js +2 -2
  35. package/package.json +5 -5
package/dist/ethers.js CHANGED
@@ -17,8 +17,8 @@ var Fi = (r, e, t, n) => ({
17
17
  return u(r, e, n);
18
18
  }
19
19
  }), I = (r, e, t) => (kc(r, e, "access private method"), t);
20
- import { C as F, P as gt, c as ca, m as Aa, i as Bp, B as ne, s as Lp, n as dt, o as Mp, H as bu, g as On, a as Tn, p as Dp, h as He, S as Tt, b as _t, f as Au, N as Eu, j as xc, k as Up, d as Fp, A as Hp } from "./W3MFrameProviderSingleton-DyEiFdpq.js";
21
- import { j as Gp, r as rd, a as sd, b as Kp } from "./hooks.module-BgSrACu5.js";
20
+ import { C as F, P as gt, b as ca, m as Aa, i as Bp, B as ne, s as Lp, n as dt, o as Mp, H as bu, h as On, a as Tn, p as Dp, j as He, f as Tt, g as _t, e as Au, N as Eu, k as xc, l as Up, c as Fp, A as Hp } from "./W3MFrameProviderSingleton-CRF_1us_.js";
21
+ import { j as Gp, r as rd, a as sd, b as Kp } from "./hooks.module-Bo49CUkD.js";
22
22
  const Pc = {
23
23
  ERROR_CODE_UNRECOGNIZED_CHAIN_ID: 4902,
24
24
  ERROR_CODE_DEFAULT: 5e3
@@ -284,7 +284,7 @@ function Ea(r, e) {
284
284
  return t;
285
285
  }
286
286
  function cd(r, e) {
287
- let t = _(r, "value");
287
+ let t = T(r, "value");
288
288
  const n = BigInt(H(e, "width")), s = St << n - St;
289
289
  if (t < Wa) {
290
290
  t = -t, v(t <= s, "too low", "NUMERIC_FAULT", {
@@ -306,7 +306,7 @@ function br(r, e) {
306
306
  const t = Qa(r, "value"), n = BigInt(H(e, "bits"));
307
307
  return t & (St << n) - St;
308
308
  }
309
- function _(r, e) {
309
+ function T(r, e) {
310
310
  switch (typeof r) {
311
311
  case "bigint":
312
312
  return r;
@@ -324,7 +324,7 @@ function _(r, e) {
324
324
  y(!1, "invalid BigNumberish value", e || "value", r);
325
325
  }
326
326
  function Qa(r, e) {
327
- const t = _(r, e);
327
+ const t = T(r, e);
328
328
  return v(t >= Wa, "unsigned value cannot be negative", "NUMERIC_FAULT", {
329
329
  fault: "overflow",
330
330
  operation: "getUint",
@@ -339,7 +339,7 @@ function za(r) {
339
339
  e += vu[t >> 4], e += vu[t & 15];
340
340
  return BigInt(e);
341
341
  }
342
- return _(r);
342
+ return T(r);
343
343
  }
344
344
  function H(r, e) {
345
345
  switch (typeof r) {
@@ -1583,7 +1583,7 @@ const Fn = class Fn {
1583
1583
  */
1584
1584
  static fromValue(e, t, n) {
1585
1585
  const s = t == null ? 0 : H(t), i = Oc(n);
1586
- let o = _(e, "value");
1586
+ let o = T(e, "value");
1587
1587
  const a = s - i.decimals;
1588
1588
  if (a > 0) {
1589
1589
  const c = ur(a);
@@ -2469,12 +2469,12 @@ class Vg extends Nd {
2469
2469
  for (let N = 0; N < 16; N++, t += 4)
2470
2470
  Ln[N] = e.getUint32(t), Mn[N] = e.getUint32(t += 4);
2471
2471
  for (let N = 16; N < 80; N++) {
2472
- const T = Ln[N - 15] | 0, x = Mn[N - 15] | 0, P = G.rotrSH(T, x, 1) ^ G.rotrSH(T, x, 8) ^ G.shrSH(T, x, 7), M = G.rotrSL(T, x, 1) ^ G.rotrSL(T, x, 8) ^ G.shrSL(T, x, 7), D = Ln[N - 2] | 0, q = Mn[N - 2] | 0, Q = G.rotrSH(D, q, 19) ^ G.rotrBH(D, q, 61) ^ G.shrSH(D, q, 6), z = G.rotrSL(D, q, 19) ^ G.rotrBL(D, q, 61) ^ G.shrSL(D, q, 6), fe = G.add4L(M, z, Mn[N - 7], Mn[N - 16]), be = G.add4H(fe, P, Q, Ln[N - 7], Ln[N - 16]);
2472
+ const _ = Ln[N - 15] | 0, x = Mn[N - 15] | 0, P = G.rotrSH(_, x, 1) ^ G.rotrSH(_, x, 8) ^ G.shrSH(_, x, 7), M = G.rotrSL(_, x, 1) ^ G.rotrSL(_, x, 8) ^ G.shrSL(_, x, 7), D = Ln[N - 2] | 0, q = Mn[N - 2] | 0, Q = G.rotrSH(D, q, 19) ^ G.rotrBH(D, q, 61) ^ G.shrSH(D, q, 6), z = G.rotrSL(D, q, 19) ^ G.rotrBL(D, q, 61) ^ G.shrSL(D, q, 6), fe = G.add4L(M, z, Mn[N - 7], Mn[N - 16]), be = G.add4H(fe, P, Q, Ln[N - 7], Ln[N - 16]);
2473
2473
  Ln[N] = be | 0, Mn[N] = fe | 0;
2474
2474
  }
2475
2475
  let { Ah: n, Al: s, Bh: i, Bl: o, Ch: a, Cl: c, Dh: l, Dl: h, Eh: d, El: f, Fh: g, Fl: w, Gh: m, Gl: E, Hh: C, Hl: S } = this;
2476
2476
  for (let N = 0; N < 80; N++) {
2477
- const T = G.rotrSH(d, f, 14) ^ G.rotrSH(d, f, 18) ^ G.rotrBH(d, f, 41), x = G.rotrSL(d, f, 14) ^ G.rotrSL(d, f, 18) ^ G.rotrBL(d, f, 41), P = d & g ^ ~d & m, M = f & w ^ ~f & E, D = G.add5L(S, x, M, jg[N], Mn[N]), q = G.add5H(D, C, T, P, Kg[N], Ln[N]), Q = D | 0, z = G.rotrSH(n, s, 28) ^ G.rotrBH(n, s, 34) ^ G.rotrBH(n, s, 39), fe = G.rotrSL(n, s, 28) ^ G.rotrBL(n, s, 34) ^ G.rotrBL(n, s, 39), be = n & i ^ n & a ^ i & a, Ot = s & o ^ s & c ^ o & c;
2477
+ const _ = G.rotrSH(d, f, 14) ^ G.rotrSH(d, f, 18) ^ G.rotrBH(d, f, 41), x = G.rotrSL(d, f, 14) ^ G.rotrSL(d, f, 18) ^ G.rotrBL(d, f, 41), P = d & g ^ ~d & m, M = f & w ^ ~f & E, D = G.add5L(S, x, M, jg[N], Mn[N]), q = G.add5H(D, C, _, P, Kg[N], Ln[N]), Q = D | 0, z = G.rotrSH(n, s, 28) ^ G.rotrBH(n, s, 34) ^ G.rotrBH(n, s, 39), fe = G.rotrSL(n, s, 28) ^ G.rotrBL(n, s, 34) ^ G.rotrBL(n, s, 39), be = n & i ^ n & a ^ i & a, Ot = s & o ^ s & c ^ o & c;
2478
2478
  C = m | 0, S = E | 0, m = g | 0, E = w | 0, g = d | 0, w = f | 0, { h: d, l: f } = G.add(l | 0, h | 0, q | 0, Q | 0), l = a | 0, h = c | 0, a = i | 0, c = o | 0, i = n | 0, o = s | 0;
2479
2479
  const k = G.add3L(Q, fe, Ot);
2480
2480
  n = G.add3H(k, q, z, be), s = k | 0;
@@ -3085,8 +3085,8 @@ function N0(r, e) {
3085
3085
  const m = w * c;
3086
3086
  let E = Number(o & d);
3087
3087
  o >>= g, E > c && (E -= f, o += Lc);
3088
- const C = m, S = m + Math.abs(E) - 1, N = w % 2 !== 0, T = E < 0;
3089
- E === 0 ? h = h.add(t(N, i[C])) : l = l.add(t(T, i[S]));
3088
+ const C = m, S = m + Math.abs(E) - 1, N = w % 2 !== 0, _ = E < 0;
3089
+ E === 0 ? h = h.add(t(N, i[C])) : l = l.add(t(_, i[S]));
3090
3090
  }
3091
3091
  return { p: l, f: h };
3092
3092
  },
@@ -3301,7 +3301,7 @@ function P0(r) {
3301
3301
  */
3302
3302
  equals(m) {
3303
3303
  h(m);
3304
- const { px: E, py: C, pz: S } = this, { px: N, py: T, pz: x } = m, P = t.eql(t.mul(E, x), t.mul(N, S)), M = t.eql(t.mul(C, x), t.mul(T, S));
3304
+ const { px: E, py: C, pz: S } = this, { px: N, py: _, pz: x } = m, P = t.eql(t.mul(E, x), t.mul(N, S)), M = t.eql(t.mul(C, x), t.mul(_, S));
3305
3305
  return P && M;
3306
3306
  }
3307
3307
  /**
@@ -3315,9 +3315,9 @@ function P0(r) {
3315
3315
  // https://eprint.iacr.org/2015/1060, algorithm 3
3316
3316
  // Cost: 8M + 3S + 3*a + 2*b3 + 15add.
3317
3317
  double() {
3318
- const { a: m, b: E } = e, C = t.mul(E, Hu), { px: S, py: N, pz: T } = this;
3319
- let x = t.ZERO, P = t.ZERO, M = t.ZERO, D = t.mul(S, S), q = t.mul(N, N), Q = t.mul(T, T), z = t.mul(S, N);
3320
- return z = t.add(z, z), M = t.mul(S, T), M = t.add(M, M), x = t.mul(m, M), P = t.mul(C, Q), P = t.add(x, P), x = t.sub(q, P), P = t.add(q, P), P = t.mul(x, P), x = t.mul(z, x), M = t.mul(C, M), Q = t.mul(m, Q), z = t.sub(D, Q), z = t.mul(m, z), z = t.add(z, M), M = t.add(D, D), D = t.add(M, D), D = t.add(D, Q), D = t.mul(D, z), P = t.add(P, D), Q = t.mul(N, T), Q = t.add(Q, Q), D = t.mul(Q, z), x = t.sub(x, D), M = t.mul(Q, q), M = t.add(M, M), M = t.add(M, M), new d(x, P, M);
3318
+ const { a: m, b: E } = e, C = t.mul(E, Hu), { px: S, py: N, pz: _ } = this;
3319
+ let x = t.ZERO, P = t.ZERO, M = t.ZERO, D = t.mul(S, S), q = t.mul(N, N), Q = t.mul(_, _), z = t.mul(S, N);
3320
+ return z = t.add(z, z), M = t.mul(S, _), M = t.add(M, M), x = t.mul(m, M), P = t.mul(C, Q), P = t.add(x, P), x = t.sub(q, P), P = t.add(q, P), P = t.mul(x, P), x = t.mul(z, x), M = t.mul(C, M), Q = t.mul(m, Q), z = t.sub(D, Q), z = t.mul(m, z), z = t.add(z, M), M = t.add(D, D), D = t.add(M, D), D = t.add(D, Q), D = t.mul(D, z), P = t.add(P, D), Q = t.mul(N, _), Q = t.add(Q, Q), D = t.mul(Q, z), x = t.sub(x, D), M = t.mul(Q, q), M = t.add(M, M), M = t.add(M, M), new d(x, P, M);
3321
3321
  }
3322
3322
  // Renes-Costello-Batina exception-free addition formula.
3323
3323
  // There is 30% faster Jacobian formula, but it is not complete.
@@ -3325,13 +3325,13 @@ function P0(r) {
3325
3325
  // Cost: 12M + 0S + 3*a + 3*b3 + 23add.
3326
3326
  add(m) {
3327
3327
  h(m);
3328
- const { px: E, py: C, pz: S } = this, { px: N, py: T, pz: x } = m;
3328
+ const { px: E, py: C, pz: S } = this, { px: N, py: _, pz: x } = m;
3329
3329
  let P = t.ZERO, M = t.ZERO, D = t.ZERO;
3330
3330
  const q = e.a, Q = t.mul(e.b, Hu);
3331
- let z = t.mul(E, N), fe = t.mul(C, T), be = t.mul(S, x), Ot = t.add(E, C), k = t.add(N, T);
3331
+ let z = t.mul(E, N), fe = t.mul(C, _), be = t.mul(S, x), Ot = t.add(E, C), k = t.add(N, _);
3332
3332
  Ot = t.mul(Ot, k), k = t.add(z, fe), Ot = t.sub(Ot, k), k = t.add(E, S);
3333
3333
  let B = t.add(N, x);
3334
- return k = t.mul(k, B), B = t.add(z, be), k = t.sub(k, B), B = t.add(C, S), P = t.add(T, x), B = t.mul(B, P), P = t.add(fe, be), B = t.sub(B, P), D = t.mul(q, k), P = t.mul(Q, be), D = t.add(P, D), P = t.sub(fe, D), D = t.add(fe, D), M = t.mul(P, D), fe = t.add(z, z), fe = t.add(fe, z), be = t.mul(q, be), k = t.mul(Q, k), fe = t.add(fe, be), be = t.sub(z, be), be = t.mul(q, be), k = t.add(k, be), z = t.mul(fe, k), M = t.add(M, z), z = t.mul(B, k), P = t.mul(Ot, P), P = t.sub(P, z), z = t.mul(Ot, fe), D = t.mul(B, D), D = t.add(D, z), new d(P, M, D);
3334
+ return k = t.mul(k, B), B = t.add(z, be), k = t.sub(k, B), B = t.add(C, S), P = t.add(_, x), B = t.mul(B, P), P = t.add(fe, be), B = t.sub(B, P), D = t.mul(q, k), P = t.mul(Q, be), D = t.add(P, D), P = t.sub(fe, D), D = t.add(fe, D), M = t.mul(P, D), fe = t.add(z, z), fe = t.add(fe, z), be = t.mul(q, be), k = t.mul(Q, k), fe = t.add(fe, be), be = t.sub(z, be), be = t.mul(q, be), k = t.add(k, be), z = t.mul(fe, k), M = t.add(M, z), z = t.mul(B, k), P = t.mul(Ot, P), P = t.sub(P, z), z = t.mul(Ot, fe), D = t.mul(B, D), D = t.add(D, z), new d(P, M, D);
3335
3335
  }
3336
3336
  subtract(m) {
3337
3337
  return this.add(m.negate());
@@ -3359,10 +3359,10 @@ function P0(r) {
3359
3359
  const { endo: C } = e;
3360
3360
  if (!C)
3361
3361
  return g.unsafeLadder(this, m);
3362
- let { k1neg: S, k1: N, k2neg: T, k2: x } = C.splitScalar(m), P = E, M = E, D = this;
3362
+ let { k1neg: S, k1: N, k2neg: _, k2: x } = C.splitScalar(m), P = E, M = E, D = this;
3363
3363
  for (; N > Cn || x > Cn; )
3364
3364
  N & lt && (P = P.add(D)), x & lt && (M = M.add(D)), D = D.double(), N >>= lt, x >>= lt;
3365
- return S && (P = P.negate()), T && (M = M.negate()), M = new d(t.mul(M.px, C.beta), M.py, M.pz), P.add(M);
3365
+ return S && (P = P.negate()), _ && (M = M.negate()), M = new d(t.mul(M.px, C.beta), M.py, M.pz), P.add(M);
3366
3366
  }
3367
3367
  /**
3368
3368
  * Constant time multiplication.
@@ -3378,12 +3378,12 @@ function P0(r) {
3378
3378
  let E = m, C, S;
3379
3379
  const { endo: N } = e;
3380
3380
  if (N) {
3381
- const { k1neg: T, k1: x, k2neg: P, k2: M } = N.splitScalar(E);
3381
+ const { k1neg: _, k1: x, k2neg: P, k2: M } = N.splitScalar(E);
3382
3382
  let { p: D, f: q } = this.wNAF(x), { p: Q, f: z } = this.wNAF(M);
3383
- D = g.constTimeNegate(T, D), Q = g.constTimeNegate(P, Q), Q = new d(t.mul(Q.px, N.beta), Q.py, Q.pz), C = D.add(Q), S = q.add(z);
3383
+ D = g.constTimeNegate(_, D), Q = g.constTimeNegate(P, Q), Q = new d(t.mul(Q.px, N.beta), Q.py, Q.pz), C = D.add(Q), S = q.add(z);
3384
3384
  } else {
3385
- const { p: T, f: x } = this.wNAF(E);
3386
- C = T, S = x;
3385
+ const { p: _, f: x } = this.wNAF(E);
3386
+ C = _, S = x;
3387
3387
  }
3388
3388
  return d.normalizeZ([C, S])[0];
3389
3389
  }
@@ -3394,8 +3394,8 @@ function P0(r) {
3394
3394
  * @returns non-zero affine point
3395
3395
  */
3396
3396
  multiplyAndAddUnsafe(m, E, C) {
3397
- const S = d.BASE, N = (x, P) => P === Cn || P === lt || !x.equals(S) ? x.multiplyUnsafe(P) : x.multiply(P), T = N(this, E).add(N(m, C));
3398
- return T.is0() ? void 0 : T;
3397
+ const S = d.BASE, N = (x, P) => P === Cn || P === lt || !x.equals(S) ? x.multiplyUnsafe(P) : x.multiply(P), _ = N(this, E).add(N(m, C));
3398
+ return _.is0() ? void 0 : _;
3399
3399
  }
3400
3400
  // Converts Projective point to affine (x, y) coordinates.
3401
3401
  // Can accept precomputed Z^-1 - for example, from invertBatch.
@@ -3403,12 +3403,12 @@ function P0(r) {
3403
3403
  toAffine(m) {
3404
3404
  const { px: E, py: C, pz: S } = this, N = this.is0();
3405
3405
  m == null && (m = N ? t.ONE : t.inv(S));
3406
- const T = t.mul(E, m), x = t.mul(C, m), P = t.mul(S, m);
3406
+ const _ = t.mul(E, m), x = t.mul(C, m), P = t.mul(S, m);
3407
3407
  if (N)
3408
3408
  return { x: t.ZERO, y: t.ZERO };
3409
3409
  if (!t.eql(P, t.ONE))
3410
3410
  throw new Error("invZ was invalid");
3411
- return { x: T, y: x };
3411
+ return { x: _, y: x };
3412
3412
  }
3413
3413
  isTorsionFree() {
3414
3414
  const { h: m, isTorsionFree: E } = e;
@@ -3583,14 +3583,14 @@ function O0(r) {
3583
3583
  function N(k, B = !0) {
3584
3584
  return l.fromPrivateKey(k).toRawBytes(B);
3585
3585
  }
3586
- function T(k) {
3586
+ function _(k) {
3587
3587
  const B = k instanceof Uint8Array, K = typeof k == "string", ee = (B || K) && k.length;
3588
3588
  return B ? ee === s || ee === i : K ? ee === 2 * s || ee === 2 * i : k instanceof l;
3589
3589
  }
3590
3590
  function x(k, B, K = !0) {
3591
- if (T(k))
3591
+ if (_(k))
3592
3592
  throw new Error("first arg must be private key");
3593
- if (!T(B))
3593
+ if (!_(B))
3594
3594
  throw new Error("second arg must be public key");
3595
3595
  return l.fromHex(B).multiply(h(k)).toRawBytes(K);
3596
3596
  }
@@ -3699,7 +3699,7 @@ function _0(r, e) {
3699
3699
  /*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */
3700
3700
  const qd = BigInt("0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f"), Gu = BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"), B0 = BigInt(1), fl = BigInt(2), Ku = (r, e) => (r + e / fl) / e;
3701
3701
  function L0(r) {
3702
- const e = qd, t = BigInt(3), n = BigInt(6), s = BigInt(11), i = BigInt(22), o = BigInt(23), a = BigInt(44), c = BigInt(88), l = r * r * r % e, h = l * l * r % e, d = tt(h, t, e) * h % e, f = tt(d, t, e) * h % e, g = tt(f, fl, e) * l % e, w = tt(g, s, e) * g % e, m = tt(w, i, e) * w % e, E = tt(m, a, e) * m % e, C = tt(E, c, e) * E % e, S = tt(C, a, e) * m % e, N = tt(S, t, e) * h % e, T = tt(N, o, e) * w % e, x = tt(T, n, e) * l % e, P = tt(x, fl, e);
3702
+ const e = qd, t = BigInt(3), n = BigInt(6), s = BigInt(11), i = BigInt(22), o = BigInt(23), a = BigInt(44), c = BigInt(88), l = r * r * r % e, h = l * l * r % e, d = tt(h, t, e) * h % e, f = tt(d, t, e) * h % e, g = tt(f, fl, e) * l % e, w = tt(g, s, e) * g % e, m = tt(w, i, e) * w % e, E = tt(m, a, e) * m % e, C = tt(E, c, e) * E % e, S = tt(C, a, e) * m % e, N = tt(S, t, e) * h % e, _ = tt(N, o, e) * w % e, x = tt(_, n, e) * l % e, P = tt(x, fl, e);
3703
3703
  if (!pl.eql(pl.sqr(P), r))
3704
3704
  throw new Error("Cannot find square root");
3705
3705
  return P;
@@ -3867,7 +3867,7 @@ const yt = class yt {
3867
3867
  * //_result:
3868
3868
  */
3869
3869
  static getChainId(e) {
3870
- const t = _(e, "v");
3870
+ const t = T(e, "v");
3871
3871
  return t == zu || t == Ju ? Vu : (y(t >= Zo, "invalid EIP-155 v", "v", e), (t - Zo) / Qu);
3872
3872
  }
3873
3873
  /**
@@ -3885,7 +3885,7 @@ const yt = class yt {
3885
3885
  *
3886
3886
  */
3887
3887
  static getChainIdV(e, t) {
3888
- return _(e) * Qu + BigInt(35 + t - 27);
3888
+ return T(e) * Qu + BigInt(35 + t - 27);
3889
3889
  }
3890
3890
  /**
3891
3891
  * Compute the normalized legacy transaction ``v`` from a ``yParirty``,
@@ -3909,7 +3909,7 @@ const yt = class yt {
3909
3909
  * //_error:
3910
3910
  */
3911
3911
  static getNormalizedV(e) {
3912
- const t = _(e);
3912
+ const t = T(e);
3913
3913
  return t === Vu || t === zu ? 27 : t === Wu || t === Ju ? 28 : (y(t >= Zo, "invalid v", "v", e), t & Wu ? 27 : 28);
3914
3914
  }
3915
3915
  /**
@@ -3957,7 +3957,7 @@ const yt = class yt {
3957
3957
  t((W(i)[0] & 128) == 0, "non-canonical s");
3958
3958
  const { networkV: o, v: a } = function(l, h, d) {
3959
3959
  if (l != null) {
3960
- const f = _(l);
3960
+ const f = T(l);
3961
3961
  return {
3962
3962
  networkV: f >= Zo ? f : void 0,
3963
3963
  v: yt.getNormalizedV(f)
@@ -4197,7 +4197,7 @@ function $(r) {
4197
4197
  }
4198
4198
  function G0(r) {
4199
4199
  const e = $(r.from);
4200
- let n = _(r.nonce, "tx.nonce").toString(16);
4200
+ let n = T(r.nonce, "tx.nonce").toString(16);
4201
4201
  return n === "0" ? n = "0x" : n.length % 2 ? n = "0x0" + n : n = "0x" + n, $(ie(he($r([e, n])), 12));
4202
4202
  }
4203
4203
  function Zd(r) {
@@ -5185,7 +5185,7 @@ class X0 extends kn {
5185
5185
  return 0;
5186
5186
  }
5187
5187
  encode(t, n) {
5188
- let s = _(Pe.dereference(n, this.type)), i = br(Y0, De * 8);
5188
+ let s = T(Pe.dereference(n, this.type)), i = br(Y0, De * 8);
5189
5189
  if (this.signed) {
5190
5190
  let o = br(i, this.size * 8 - 1);
5191
5191
  (s > o || s < -(o + $0)) && this._throwError("value out-of-bounds", n), s = cd(s, 8 * De);
@@ -5286,15 +5286,15 @@ function nm(r) {
5286
5286
  E = E & g | E << 1 & m >>> 1 | h(), D = D << 1 ^ g, q = (q ^ g) << 1 | g | 1;
5287
5287
  S = D, N = 1 + q - D;
5288
5288
  }
5289
- let T = n - 4;
5289
+ let _ = n - 4;
5290
5290
  return C.map((x) => {
5291
- switch (x - T) {
5291
+ switch (x - _) {
5292
5292
  case 3:
5293
- return T + 65792 + (r[a++] << 16 | r[a++] << 8 | r[a++]);
5293
+ return _ + 65792 + (r[a++] << 16 | r[a++] << 8 | r[a++]);
5294
5294
  case 2:
5295
- return T + 256 + (r[a++] << 8 | r[a++]);
5295
+ return _ + 256 + (r[a++] << 8 | r[a++]);
5296
5296
  case 1:
5297
- return T + r[a++];
5297
+ return _ + r[a++];
5298
5298
  default:
5299
5299
  return x - 1;
5300
5300
  }
@@ -5887,11 +5887,11 @@ function Do(r, e) {
5887
5887
  function le(r, e) {
5888
5888
  if (r === "0x")
5889
5889
  return ye;
5890
- const t = _(r, e);
5890
+ const t = T(r, e);
5891
5891
  return y(t <= Wm, "value exceeds uint size", e, t), t;
5892
5892
  }
5893
5893
  function te(r, e) {
5894
- const t = _(r, "value"), n = Me(t);
5894
+ const t = T(r, "value"), n = Me(t);
5895
5895
  return y(n.length <= 32, "value too large", `tx.${e}`, t), n;
5896
5896
  }
5897
5897
  function Yl(r) {
@@ -5942,7 +5942,7 @@ function Jm(r, e) {
5942
5942
  ];
5943
5943
  let n = ye;
5944
5944
  if (r.chainId != ye)
5945
- n = _(r.chainId, "tx.chainId"), y(!e || e.networkV == null || e.legacyChainId === n, "tx.chainId/sig.v mismatch", "sig", e);
5945
+ n = T(r.chainId, "tx.chainId"), y(!e || e.networkV == null || e.legacyChainId === n, "tx.chainId/sig.v mismatch", "sig", e);
5946
5946
  else if (r.signature) {
5947
5947
  const i = r.signature.legacyChainId;
5948
5948
  i != null && (n = i);
@@ -6188,7 +6188,7 @@ const on = class on {
6188
6188
  return u(this, Zs);
6189
6189
  }
6190
6190
  set gasLimit(e) {
6191
- p(this, Zs, _(e));
6191
+ p(this, Zs, T(e));
6192
6192
  }
6193
6193
  /**
6194
6194
  * The gas price.
@@ -6201,7 +6201,7 @@ const on = class on {
6201
6201
  return e == null && (this.type === 0 || this.type === 1) ? ye : e;
6202
6202
  }
6203
6203
  set gasPrice(e) {
6204
- p(this, $s, e == null ? null : _(e, "gasPrice"));
6204
+ p(this, $s, e == null ? null : T(e, "gasPrice"));
6205
6205
  }
6206
6206
  /**
6207
6207
  * The maximum priority fee per unit of gas to pay. On legacy
@@ -6212,7 +6212,7 @@ const on = class on {
6212
6212
  return e ?? (this.type === 2 || this.type === 3 ? ye : null);
6213
6213
  }
6214
6214
  set maxPriorityFeePerGas(e) {
6215
- p(this, Ys, e == null ? null : _(e, "maxPriorityFeePerGas"));
6215
+ p(this, Ys, e == null ? null : T(e, "maxPriorityFeePerGas"));
6216
6216
  }
6217
6217
  /**
6218
6218
  * The maximum total fee per unit of gas to pay. On legacy
@@ -6223,7 +6223,7 @@ const on = class on {
6223
6223
  return e ?? (this.type === 2 || this.type === 3 ? ye : null);
6224
6224
  }
6225
6225
  set maxFeePerGas(e) {
6226
- p(this, Xs, e == null ? null : _(e, "maxFeePerGas"));
6226
+ p(this, Xs, e == null ? null : T(e, "maxFeePerGas"));
6227
6227
  }
6228
6228
  /**
6229
6229
  * The transaction data. For ``init`` transactions this is the
@@ -6242,7 +6242,7 @@ const on = class on {
6242
6242
  return u(this, ei);
6243
6243
  }
6244
6244
  set value(e) {
6245
- p(this, ei, _(e, "value"));
6245
+ p(this, ei, T(e, "value"));
6246
6246
  }
6247
6247
  /**
6248
6248
  * The chain ID this transaction is valid on.
@@ -6251,7 +6251,7 @@ const on = class on {
6251
6251
  return u(this, ti);
6252
6252
  }
6253
6253
  set chainId(e) {
6254
- p(this, ti, _(e));
6254
+ p(this, ti, T(e));
6255
6255
  }
6256
6256
  /**
6257
6257
  * If signed, the signature for this transaction.
@@ -6283,7 +6283,7 @@ const on = class on {
6283
6283
  return e == null && this.type === 3 ? ye : e;
6284
6284
  }
6285
6285
  set maxFeePerBlobGas(e) {
6286
- p(this, Br, e == null ? null : _(e, "maxFeePerBlobGas"));
6286
+ p(this, Br, e == null ? null : T(e, "maxFeePerBlobGas"));
6287
6287
  }
6288
6288
  /**
6289
6289
  * The BLOb versioned hashes for Cancun transactions.
@@ -6580,7 +6580,7 @@ const oy = {
6580
6580
  name: ah("name"),
6581
6581
  version: ah("version"),
6582
6582
  chainId: function(r) {
6583
- const e = _(r, "domain.chainId");
6583
+ const e = T(r, "domain.chainId");
6584
6584
  return y(e >= 0, "invalid chain ID", "domain.chainId", r), Number.isSafeInteger(e) ? Number(e) : vs(e);
6585
6585
  },
6586
6586
  verifyingContract: function(r) {
@@ -6603,7 +6603,7 @@ function Gc(r) {
6603
6603
  y(n % 8 === 0 && n !== 0 && n <= 256 && e[2] === String(n), "invalid numeric width", "type", r);
6604
6604
  const s = br(ny, t ? n - 1 : n), i = t ? (s + If) * ty : vf;
6605
6605
  return function(o) {
6606
- const a = _(o, "value");
6606
+ const a = T(o, "value");
6607
6607
  return y(a >= i && a <= s, `value out-of-bounds for ${r}`, "value", a), ar(t ? cd(a, 256) : a, 32);
6608
6608
  };
6609
6609
  }
@@ -6864,7 +6864,7 @@ const rt = class rt {
6864
6864
  if (c.match(/^bytes(\d*)/))
6865
6865
  return O(W(l));
6866
6866
  if (c.match(/^u?int/))
6867
- return _(l).toString();
6867
+ return T(l).toString();
6868
6868
  switch (c) {
6869
6869
  case "address":
6870
6870
  return l.toLowerCase();
@@ -7104,7 +7104,7 @@ function In(r, e) {
7104
7104
  function _f(r) {
7105
7105
  if (r.peekType("AT")) {
7106
7106
  if (r.pop(), r.peekType("NUMBER"))
7107
- return _(r.pop().text);
7107
+ return T(r.pop().text);
7108
7108
  throw new Error("invalid gas");
7109
7109
  }
7110
7110
  return null;
@@ -8703,7 +8703,7 @@ const yr = class yr {
8703
8703
  * If the matching function cannot be found, return null.
8704
8704
  */
8705
8705
  parseTransaction(e) {
8706
- const t = W(e.data, "tx.data"), n = _(e.value != null ? e.value : 0, "tx.value"), s = this.getFunction(O(t.slice(0, 4)));
8706
+ const t = W(e.data, "tx.data"), n = T(e.value != null ? e.value : 0, "tx.value"), s = this.getFunction(O(t.slice(0, 4)));
8707
8707
  if (!s)
8708
8708
  return null;
8709
8709
  const i = u(this, Ie).decode(s.inputs, t.slice(4));
@@ -8902,7 +8902,7 @@ function Ta(r) {
8902
8902
  r.to && (e.to = r.to), r.from && (e.from = r.from), r.data && (e.data = O(r.data));
8903
8903
  const t = "chainId,gasLimit,gasPrice,maxFeePerBlobGas,maxFeePerGas,maxPriorityFeePerGas,value".split(/,/);
8904
8904
  for (const s of t)
8905
- !(s in r) || r[s] == null || (e[s] = _(r[s], `request.${s}`));
8905
+ !(s in r) || r[s] == null || (e[s] = T(r[s], `request.${s}`));
8906
8906
  const n = "type,nonce".split(/,/);
8907
8907
  for (const s of n)
8908
8908
  !(s in r) || r[s] == null || (e[s] = H(r[s], `request.${s}`));
@@ -10155,7 +10155,7 @@ function Ty(r) {
10155
10155
  const e = async function(o) {
10156
10156
  const a = await Vf(o, ["data"]);
10157
10157
  a.to = await r.getAddress(), a.from && (a.from = await Ue(a.from, jf(r.runner)));
10158
- const c = r.interface, l = _(a.value || vh, "overrides.value") === vh, h = (a.data || "0x") === "0x";
10158
+ const c = r.interface, l = T(a.value || vh, "overrides.value") === vh, h = (a.data || "0x") === "0x";
10159
10159
  c.fallback && !c.fallback.payable && c.receive && !h && !l && y(!1, "cannot send data to receive or send value to non-payable fallback", "overrides", o), y(c.fallback || h, "cannot send data to receive-only contract", "overrides.data", a.data);
10160
10160
  const d = c.receive || c.fallback && c.fallback.payable;
10161
10161
  return y(d || l, "cannot send value to non-payable fallback", "overrides.value", a.value), y(c.fallback || h, "cannot send data to receive-only contract", "overrides.data", a.data), a;
@@ -10328,7 +10328,7 @@ async function Ih(r, e, t) {
10328
10328
  }
10329
10329
  if (C) {
10330
10330
  const S = C, N = s ? r.interface.decodeEventLog(s, E.data, E.topics) : [];
10331
- Il(r, t, N, (T) => new Py(r, T, t, S, E));
10331
+ Il(r, t, N, (_) => new Py(r, _, t, S, E));
10332
10332
  } else
10333
10333
  Il(r, t, [], (S) => new Ff(r, S, t, E));
10334
10334
  };
@@ -11113,17 +11113,17 @@ const jy = Fo({
11113
11113
  number: H,
11114
11114
  timestamp: H,
11115
11115
  nonce: V(_i),
11116
- difficulty: _,
11117
- gasLimit: _,
11118
- gasUsed: _,
11116
+ difficulty: T,
11117
+ gasLimit: T,
11118
+ gasUsed: T,
11119
11119
  stateRoot: V(Ce, null),
11120
11120
  receiptsRoot: V(Ce, null),
11121
- blobGasUsed: V(_, null),
11122
- excessBlobGas: V(_, null),
11121
+ blobGasUsed: V(T, null),
11122
+ excessBlobGas: V(T, null),
11123
11123
  miner: V($),
11124
11124
  prevRandao: V(Ce, null),
11125
11125
  extraData: _i,
11126
- baseFeePerGas: V(_)
11126
+ baseFeePerGas: V(T)
11127
11127
  }, {
11128
11128
  prevRandao: ["mixHash"]
11129
11129
  });
@@ -11153,17 +11153,17 @@ const zy = Fo({
11153
11153
  // should be allowNull(hash), but broken-EIP-658 support is handled in receipt
11154
11154
  index: H,
11155
11155
  root: V(O),
11156
- gasUsed: _,
11157
- blobGasUsed: V(_, null),
11156
+ gasUsed: T,
11157
+ blobGasUsed: V(T, null),
11158
11158
  logsBloom: V(_i),
11159
11159
  blockHash: Ce,
11160
11160
  hash: Ce,
11161
11161
  logs: rc(Qy),
11162
11162
  blockNumber: H,
11163
11163
  //confirmations: allowNull(getNumber, null),
11164
- cumulativeGasUsed: _,
11165
- effectiveGasPrice: V(_),
11166
- blobGasPrice: V(_, null),
11164
+ cumulativeGasUsed: T,
11165
+ effectiveGasPrice: V(T),
11166
+ blobGasPrice: V(T, null),
11167
11167
  status: V(H),
11168
11168
  type: V(H, 0)
11169
11169
  }, {
@@ -11175,7 +11175,7 @@ function Jy(r) {
11175
11175
  return zy(r);
11176
11176
  }
11177
11177
  function Jf(r) {
11178
- r.to && _(r.to) === Sh && (r.to = "0x0000000000000000000000000000000000000000");
11178
+ r.to && T(r.to) === Sh && (r.to = "0x0000000000000000000000000000000000000000");
11179
11179
  const e = Fo({
11180
11180
  hash: Ce,
11181
11181
  // Some nodes do not return this, usually test nodes (like Ganache)
@@ -11188,17 +11188,17 @@ function Jf(r) {
11188
11188
  transactionIndex: V(H, null),
11189
11189
  from: $,
11190
11190
  // either (gasPrice) or (maxPriorityFeePerGas + maxFeePerGas) must be set
11191
- gasPrice: V(_),
11192
- maxPriorityFeePerGas: V(_),
11193
- maxFeePerGas: V(_),
11194
- maxFeePerBlobGas: V(_, null),
11195
- gasLimit: _,
11191
+ gasPrice: V(T),
11192
+ maxPriorityFeePerGas: V(T),
11193
+ maxFeePerGas: V(T),
11194
+ maxFeePerBlobGas: V(T, null),
11195
+ gasLimit: T,
11196
11196
  to: V($, null),
11197
- value: _,
11197
+ value: T,
11198
11198
  nonce: H,
11199
11199
  data: _i,
11200
11200
  creates: V($, null),
11201
- chainId: V(_, null)
11201
+ chainId: V(T, null)
11202
11202
  }, {
11203
11203
  data: ["input"],
11204
11204
  gasLimit: ["gas"],
@@ -11208,7 +11208,7 @@ function Jf(r) {
11208
11208
  const t = e.signature.legacyChainId;
11209
11209
  t != null && (e.chainId = t);
11210
11210
  }
11211
- return e.blockHash && _(e.blockHash) === Sh && (e.blockHash = null), e;
11211
+ return e.blockHash && T(e.blockHash) === Sh && (e.blockHash = null), e;
11212
11212
  }
11213
11213
  const qy = "0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e";
11214
11214
  class Ho {
@@ -11348,7 +11348,7 @@ const xs = class xs {
11348
11348
  b(this, ui, void 0);
11349
11349
  b(this, hi, void 0);
11350
11350
  b(this, qn, void 0);
11351
- p(this, ui, e), p(this, hi, _(t)), p(this, qn, /* @__PURE__ */ new Map());
11351
+ p(this, ui, e), p(this, hi, T(t)), p(this, qn, /* @__PURE__ */ new Map());
11352
11352
  }
11353
11353
  /**
11354
11354
  * Returns a JSON-compatible representation of a Network.
@@ -11375,7 +11375,7 @@ const xs = class xs {
11375
11375
  return u(this, hi);
11376
11376
  }
11377
11377
  set chainId(e) {
11378
- p(this, hi, _(e, "chainId"));
11378
+ p(this, hi, T(e, "chainId"));
11379
11379
  }
11380
11380
  /**
11381
11381
  * Returns true if %%other%% matches this network. Any chain ID
@@ -11389,14 +11389,14 @@ const xs = class xs {
11389
11389
  return !1;
11390
11390
  if (typeof e == "string") {
11391
11391
  try {
11392
- return this.chainId === _(e);
11392
+ return this.chainId === T(e);
11393
11393
  } catch {
11394
11394
  }
11395
11395
  return this.name === e;
11396
11396
  }
11397
11397
  if (typeof e == "number" || typeof e == "bigint") {
11398
11398
  try {
11399
- return this.chainId === _(e);
11399
+ return this.chainId === T(e);
11400
11400
  } catch {
11401
11401
  }
11402
11402
  return !1;
@@ -11404,7 +11404,7 @@ const xs = class xs {
11404
11404
  if (typeof e == "object") {
11405
11405
  if (e.chainId != null) {
11406
11406
  try {
11407
- return this.chainId === _(e.chainId);
11407
+ return this.chainId === T(e.chainId);
11408
11408
  } catch {
11409
11409
  }
11410
11410
  return !1;
@@ -12133,7 +12133,7 @@ class ow {
12133
12133
  gasPrice: (async () => {
12134
12134
  try {
12135
12135
  const h = await I(this, Oe, Je).call(this, { method: "getGasPrice" });
12136
- return _(h, "%response");
12136
+ return T(h, "%response");
12137
12137
  } catch {
12138
12138
  }
12139
12139
  return null;
@@ -12141,7 +12141,7 @@ class ow {
12141
12141
  priorityFee: (async () => {
12142
12142
  try {
12143
12143
  const h = await I(this, Oe, Je).call(this, { method: "getPriorityFee" });
12144
- return _(h, "%response");
12144
+ return T(h, "%response");
12145
12145
  } catch {
12146
12146
  }
12147
12147
  return null;
@@ -12159,7 +12159,7 @@ class ow {
12159
12159
  }
12160
12160
  async estimateGas(e) {
12161
12161
  let t = this._getTransactionRequest(e);
12162
- return ea(t) && (t = await t), _(await I(this, Oe, Je).call(this, {
12162
+ return ea(t) && (t = await t), T(await I(this, Oe, Je).call(this, {
12163
12163
  method: "estimateGas",
12164
12164
  transaction: t
12165
12165
  }), "%response");
@@ -12172,7 +12172,7 @@ class ow {
12172
12172
  return await I(this, xo, Pl).call(this, I(this, ko, xl).call(this, t, n, e.enableCcipRead ? 0 : -1));
12173
12173
  }
12174
12174
  async getBalance(e, t) {
12175
- return _(await I(this, Fr, zi).call(this, { method: "getBalance" }, e, t), "%response");
12175
+ return T(await I(this, Fr, zi).call(this, { method: "getBalance" }, e, t), "%response");
12176
12176
  }
12177
12177
  async getTransactionCount(e, t) {
12178
12178
  return H(await I(this, Fr, zi).call(this, { method: "getTransactionCount" }, e, t), "%response");
@@ -12181,7 +12181,7 @@ class ow {
12181
12181
  return O(await I(this, Fr, zi).call(this, { method: "getCode" }, e, t));
12182
12182
  }
12183
12183
  async getStorage(e, t, n) {
12184
- const s = _(t, "position");
12184
+ const s = T(t, "position");
12185
12185
  return O(await I(this, Fr, zi).call(this, { method: "getStorage", position: s }, e, n));
12186
12186
  }
12187
12187
  // Write
@@ -12754,7 +12754,7 @@ class dw {
12754
12754
  n.nonce == null && (n.nonce = await this.getNonce("pending")), n.gasLimit == null && (n.gasLimit = await this.estimateGas(n));
12755
12755
  const s = await this.provider.getNetwork();
12756
12756
  if (n.chainId != null) {
12757
- const o = _(n.chainId);
12757
+ const o = T(n.chainId);
12758
12758
  y(o === s.chainId, "transaction chainId mismatch", "tx.chainId", e.chainId);
12759
12759
  } else
12760
12760
  n.chainId = s.chainId;
@@ -13115,7 +13115,7 @@ class Yf extends ow {
13115
13115
  async _perform(t) {
13116
13116
  if (t.method === "call" || t.method === "estimateGas") {
13117
13117
  let s = t.transaction;
13118
- if (s && s.type != null && _(s.type) && s.maxFeePerGas == null && s.maxPriorityFeePerGas == null) {
13118
+ if (s && s.type != null && T(s.type) && s.maxFeePerGas == null && s.maxPriorityFeePerGas == null) {
13119
13119
  const i = await this.getFeeData();
13120
13120
  i.maxFeePerGas == null && i.maxPriorityFeePerGas == null && (t = Object.assign({}, t, {
13121
13121
  transaction: Object.assign({}, s, { type: void 0 })
@@ -13142,7 +13142,7 @@ class Yf extends ow {
13142
13142
  return t;
13143
13143
  return u(this, Ke) ? await u(this, Ke) : this.ready ? (p(this, Ke, (async () => {
13144
13144
  try {
13145
- const n = kt.from(_(await this.send("eth_chainId", [])));
13145
+ const n = kt.from(T(await this.send("eth_chainId", [])));
13146
13146
  return p(this, Ke, null), n;
13147
13147
  } catch (n) {
13148
13148
  throw p(this, Ke, null), n;
@@ -13162,7 +13162,7 @@ class Yf extends ow {
13162
13162
  throw p(this, Ke, null), this.emit("debug", { action: "receiveRpcError", error: i }), i;
13163
13163
  }
13164
13164
  if (this.emit("debug", { action: "receiveRpcResult", result: s }), "result" in s)
13165
- return kt.from(_(s.result));
13165
+ return kt.from(T(s.result));
13166
13166
  throw this.getRpcError(n, s);
13167
13167
  })()), await u(this, Ke));
13168
13168
  }
@@ -13221,7 +13221,7 @@ class Yf extends ow {
13221
13221
  if (t[s] == null)
13222
13222
  return;
13223
13223
  let i = s;
13224
- s === "gasLimit" && (i = "gas"), n[i] = vs(_(t[s], `tx.${s}`));
13224
+ s === "gasLimit" && (i = "gas"), n[i] = vs(T(t[s], `tx.${s}`));
13225
13225
  }), ["from", "to", "data"].forEach((s) => {
13226
13226
  t[s] != null && (n[s] = O(t[s]));
13227
13227
  }), t.accessList && (n.accessList = rs(t.accessList)), t.blobVersionedHashes && (n.blobVersionedHashes = t.blobVersionedHashes.map((s) => s.toLowerCase())), n;
@@ -15923,7 +15923,7 @@ hu.default = ".-cbwsdk-css-reset .-gear-container{margin-left:16px !important;ma
15923
15923
  const d = ({ autoExpand: f, message: g, menuItems: w }) => {
15924
15924
  const [m, E] = (0, s.useState)(!0), [C, S] = (0, s.useState)(f ?? !1);
15925
15925
  (0, s.useEffect)(() => {
15926
- const T = [
15926
+ const _ = [
15927
15927
  window.setTimeout(() => {
15928
15928
  E(!1);
15929
15929
  }, 1),
@@ -15932,7 +15932,7 @@ hu.default = ".-cbwsdk-css-reset .-gear-container{margin-left:16px !important;ma
15932
15932
  }, 1e4)
15933
15933
  ];
15934
15934
  return () => {
15935
- T.forEach(window.clearTimeout);
15935
+ _.forEach(window.clearTimeout);
15936
15936
  };
15937
15937
  });
15938
15938
  const N = () => {
@@ -15958,15 +15958,15 @@ hu.default = ".-cbwsdk-css-reset .-gear-container{margin-left:16px !important;ma
15958
15958
  (0, n.h)("img", { src: c, class: "-gear-icon", title: "Expand" })
15959
15959
  )
15960
15960
  ),
15961
- w && w.length > 0 && (0, n.h)("div", { class: "-cbwsdk-snackbar-instance-menu" }, w.map((T, x) => (0, n.h)(
15961
+ w && w.length > 0 && (0, n.h)("div", { class: "-cbwsdk-snackbar-instance-menu" }, w.map((_, x) => (0, n.h)(
15962
15962
  "div",
15963
- { class: (0, t.default)("-cbwsdk-snackbar-instance-menu-item", T.isRed && "-cbwsdk-snackbar-instance-menu-item-is-red"), onClick: T.onClick, key: x },
15963
+ { class: (0, t.default)("-cbwsdk-snackbar-instance-menu-item", _.isRed && "-cbwsdk-snackbar-instance-menu-item-is-red"), onClick: _.onClick, key: x },
15964
15964
  (0, n.h)(
15965
15965
  "svg",
15966
- { width: T.svgWidth, height: T.svgHeight, viewBox: "0 0 10 11", fill: "none", xmlns: "http://www.w3.org/2000/svg" },
15967
- (0, n.h)("path", { "fill-rule": T.defaultFillRule, "clip-rule": T.defaultClipRule, d: T.path, fill: "#AAAAAA" })
15966
+ { width: _.svgWidth, height: _.svgHeight, viewBox: "0 0 10 11", fill: "none", xmlns: "http://www.w3.org/2000/svg" },
15967
+ (0, n.h)("path", { "fill-rule": _.defaultFillRule, "clip-rule": _.defaultClipRule, d: _.path, fill: "#AAAAAA" })
15968
15968
  ),
15969
- (0, n.h)("span", { class: (0, t.default)("-cbwsdk-snackbar-instance-menu-item-info", T.isRed && "-cbwsdk-snackbar-instance-menu-item-info-is-red") }, T.info)
15969
+ (0, n.h)("span", { class: (0, t.default)("-cbwsdk-snackbar-instance-menu-item-info", _.isRed && "-cbwsdk-snackbar-instance-menu-item-info-is-red") }, _.info)
15970
15970
  )))
15971
15971
  );
15972
15972
  };
@@ -17351,10 +17351,10 @@ class Y1 {
17351
17351
  }) : !!window.ethereum;
17352
17352
  },
17353
17353
  disconnect: async () => {
17354
- var E, C, S, N, T;
17354
+ var E, C, S, N, _;
17355
17355
  const f = He.getProvider("eip155"), g = He.state.providerIds.eip155;
17356
17356
  if ((E = this.appKit) == null || E.setClientId(null), (N = (S = (C = this.options) == null ? void 0 : C.siweConfig) == null ? void 0 : S.options) != null && N.signOutOnDisconnect) {
17357
- const { SIWEController: x } = await import("./index-DnJKKBCl.js");
17357
+ const { SIWEController: x } = await import("./index-hXCH-znD.js");
17358
17358
  await x.signOut();
17359
17359
  }
17360
17360
  const m = {
@@ -17377,7 +17377,7 @@ class Y1 {
17377
17377
  f && (f.emit("disconnect"), await this.revokeProviderPermissions(f));
17378
17378
  }
17379
17379
  }[g];
17380
- m ? await m() : console.warn(`No disconnect function found for provider type: ${g}`), Tt.removeItem(_t.WALLET_ID), (T = this.appKit) == null || T.resetAccount(this.chainNamespace);
17380
+ m ? await m() : console.warn(`No disconnect function found for provider type: ${g}`), Tt.removeItem(_t.WALLET_ID), (_ = this.appKit) == null || _.resetAccount(this.chainNamespace);
17381
17381
  },
17382
17382
  signMessage: async (f) => {
17383
17383
  const g = He.getProvider(this.chainNamespace), w = On.state.activeCaipAddress, m = Tn.getPlainAddress(w);
@@ -17492,30 +17492,25 @@ class Y1 {
17492
17492
  i != null && i.provider && (this.setProvider(i.provider, t), this.setupProviderListeners(i.provider, t));
17493
17493
  }
17494
17494
  async setProvider(e, t, n) {
17495
- var s, i, o, a;
17495
+ var s, i, o;
17496
17496
  if (t === "w3mAuth")
17497
17497
  this.setAuthProvider();
17498
17498
  else {
17499
- const c = t;
17500
- if (Tt.setItem(_t.WALLET_ID, c), n && Tt.setItem(_t.WALLET_NAME, n), e) {
17501
- const { addresses: l, chainId: h } = await wr.getUserInfo(e), d = l == null ? void 0 : l[0], f = this.caipNetworks.find((w) => w.chainId === h), g = `${this.chainNamespace}:${h}:${d}`;
17502
- d && h && f && ((s = this.appKit) == null || s.setCaipAddress(g, this.chainNamespace), (i = this.appKit) == null || i.setCaipNetwork(f), He.setProviderId("eip155", t), He.setProvider("eip155", e), (o = this.appKit) == null || o.setStatus("connected", this.chainNamespace), (a = this.appKit) == null || a.setAllAccounts(l.map((w) => ({ address: w, type: "eoa" })), this.chainNamespace));
17499
+ const a = t;
17500
+ if (Tt.setItem(_t.WALLET_ID, a), n && Tt.setItem(_t.WALLET_NAME, n), e) {
17501
+ const { addresses: c, chainId: l } = await wr.getUserInfo(e), h = c == null ? void 0 : c[0], d = `${this.chainNamespace}:${l}:${h}`;
17502
+ h && l && ((s = this.appKit) == null || s.setCaipAddress(d, this.chainNamespace), He.setProviderId("eip155", t), He.setProvider("eip155", e), (i = this.appKit) == null || i.setStatus("connected", this.chainNamespace), (o = this.appKit) == null || o.setAllAccounts(c.map((f) => ({ address: f, type: "eoa" })), this.chainNamespace));
17503
17503
  }
17504
17504
  }
17505
17505
  }
17506
17506
  async setAuthProvider() {
17507
- var e, t, n, s, i, o, a, c, l, h, d, f;
17507
+ var e, t, n, s, i, o, a, c, l, h, d;
17508
17508
  if (Tt.setItem(_t.WALLET_ID, F.AUTH_CONNECTOR_ID), this.authProvider) {
17509
17509
  (e = this.appKit) == null || e.setLoading(!0);
17510
- const { address: g, chainId: w, smartAccountDeployed: m, preferredAccountType: E, accounts: C = [] } = await this.authProvider.connect({
17510
+ const { address: f, chainId: g, smartAccountDeployed: w, preferredAccountType: m, accounts: E = [] } = await this.authProvider.connect({
17511
17511
  chainId: Number(Eu.caipNetworkIdToNumber((n = (t = this.appKit) == null ? void 0 : t.getCaipNetwork()) == null ? void 0 : n.id) ?? ((s = this.caipNetworks[0]) == null ? void 0 : s.chainId))
17512
- }), { smartAccountEnabledNetworks: S } = await this.authProvider.getSmartAccountEnabledNetworks();
17513
- if ((i = this.appKit) == null || i.setSmartAccountEnabledNetworks(S, this.chainNamespace), g && w) {
17514
- (o = this.appKit) == null || o.setAllAccounts(C.length > 0 ? C : [{ address: g, type: E }], this.chainNamespace);
17515
- const N = this.caipNetworks.find((T) => T.chainId === w);
17516
- (a = this.appKit) == null || a.setCaipNetwork(N), (c = this.appKit) == null || c.setStatus("connected", this.chainNamespace), (l = this.appKit) == null || l.setCaipAddress(`${this.chainNamespace}:${w}:${g}`, this.chainNamespace), (h = this.appKit) == null || h.setPreferredAccountType(E, this.chainNamespace), (d = this.appKit) == null || d.setSmartAccountDeployed(!!m, this.chainNamespace), He.setProvider("eip155", this.authProvider), He.setProviderId("eip155", F.AUTH_CONNECTOR_ID), this.setupProviderListeners(this.authProvider, "w3mAuth"), this.watchModal();
17517
- }
17518
- (f = this.appKit) == null || f.setLoading(!1);
17512
+ }), { smartAccountEnabledNetworks: C } = await this.authProvider.getSmartAccountEnabledNetworks();
17513
+ (i = this.appKit) == null || i.setSmartAccountEnabledNetworks(C, this.chainNamespace), f && g && ((o = this.appKit) == null || o.setAllAccounts(E.length > 0 ? E : [{ address: f, type: m }], this.chainNamespace), (a = this.appKit) == null || a.setStatus("connected", this.chainNamespace), (c = this.appKit) == null || c.setCaipAddress(`${this.chainNamespace}:${g}:${f}`, this.chainNamespace), (l = this.appKit) == null || l.setPreferredAccountType(m, this.chainNamespace), (h = this.appKit) == null || h.setSmartAccountDeployed(!!w, this.chainNamespace), He.setProvider("eip155", this.authProvider), He.setProviderId("eip155", F.AUTH_CONNECTOR_ID), this.setupProviderListeners(this.authProvider, "w3mAuth"), this.watchModal()), (d = this.appKit) == null || d.setLoading(!1);
17519
17514
  }
17520
17515
  }
17521
17516
  watchModal() {
@@ -17532,11 +17527,9 @@ class Y1 {
17532
17527
  const a = o == null ? void 0 : o[0];
17533
17528
  a ? ((c = this.appKit) == null || c.setCaipAddress(a, this.chainNamespace), t === F.EIP6963_CONNECTOR_ID && ((l = this.appKit) == null || l.setAllAccounts(o.map((f) => ({ address: f, type: "eoa" })), this.chainNamespace))) : (t === F.EIP6963_CONNECTOR_ID && ((h = this.appKit) == null || h.setAllAccounts([], this.chainNamespace)), Tt.removeItem(_t.WALLET_ID), (d = this.appKit) == null || d.resetAccount(this.chainNamespace));
17534
17529
  }, i = (o) => {
17535
- var a;
17536
- if (o) {
17537
- const c = typeof o == "string" ? wr.hexStringToNumber(o) : Number(o), l = this.caipNetworks.find((h) => h.chainId === c);
17538
- (a = this.appKit) == null || a.setCaipNetwork(l);
17539
- }
17530
+ var h, d;
17531
+ const a = typeof o == "string" ? wr.hexStringToNumber(o) : Number(o), c = this.caipNetworks.find((f) => f.chainId === a), l = (h = this.appKit) == null ? void 0 : h.getCaipNetwork();
17532
+ (!l || (l == null ? void 0 : l.id) !== (c == null ? void 0 : c.id)) && ((d = this.appKit) == null || d.setCaipNetwork(c));
17540
17533
  };
17541
17534
  t === F.AUTH_CONNECTOR_ID ? this.setupAuthListeners(e) : (e.on("disconnect", n), e.on("accountsChanged", s), e.on("chainChanged", i)), this.providerHandlers = {
17542
17535
  disconnect: n,
@@ -17579,17 +17572,17 @@ class Y1 {
17579
17572
  ((n = this.appKit) == null ? void 0 : n.getActiveChainNamespace()) === this.chainNamespace && ((s = this.appKit) == null || s.setPreferredAccountType(e, this.chainNamespace));
17580
17573
  }
17581
17574
  handleAuthSetPreferredAccount(e, t) {
17582
- var i, o, a, c, l, h, d, f;
17575
+ var s, i, o, a, c, l, h;
17583
17576
  if (!e)
17584
17577
  return;
17585
- (i = this.appKit) == null || i.setLoading(!0);
17586
- const n = Eu.caipNetworkIdToNumber((a = (o = this.appKit) == null ? void 0 : o.getCaipNetwork()) == null ? void 0 : a.id), s = this.caipNetworks.find((g) => g.chainId === n);
17587
- (c = this.appKit) == null || c.setCaipAddress(`eip155:${n}:${e}`, this.chainNamespace), (l = this.appKit) == null || l.setCaipNetwork(s), (h = this.appKit) == null || h.setStatus("connected", this.chainNamespace), (d = this.appKit) == null || d.setPreferredAccountType(t, this.chainNamespace), this.syncAccount({
17578
+ (s = this.appKit) == null || s.setLoading(!0);
17579
+ const n = Eu.caipNetworkIdToNumber((o = (i = this.appKit) == null ? void 0 : i.getCaipNetwork()) == null ? void 0 : o.id);
17580
+ (a = this.appKit) == null || a.setCaipAddress(`eip155:${n}:${e}`, this.chainNamespace), (c = this.appKit) == null || c.setStatus("connected", this.chainNamespace), (l = this.appKit) == null || l.setPreferredAccountType(t, this.chainNamespace), this.syncAccount({
17588
17581
  address: e
17589
17582
  }).then(() => {
17590
- var g;
17591
- return (g = this.appKit) == null ? void 0 : g.setLoading(!1);
17592
- }), (f = this.appKit) == null || f.setLoading(!1);
17583
+ var d;
17584
+ return (d = this.appKit) == null ? void 0 : d.setLoading(!1);
17585
+ }), (h = this.appKit) == null || h.setLoading(!1);
17593
17586
  }
17594
17587
  async syncReownName(e) {
17595
17588
  var t, n, s, i;
@@ -17673,20 +17666,21 @@ class Y1 {
17673
17666
  }
17674
17667
  async switchNetwork(e) {
17675
17668
  var i, o, a, c, l, h, d, f;
17676
- const t = async (g) => {
17677
- var w, m, E;
17669
+ async function t(g) {
17670
+ var w, m;
17678
17671
  try {
17679
17672
  await g.request({
17680
17673
  method: "wallet_switchEthereumChain",
17681
17674
  params: [{ chainId: wr.numberToHexString(e.chainId) }]
17682
- }), (w = this.appKit) == null || w.setCaipNetwork(e);
17683
- } catch (C) {
17684
- if (C.code === Pc.ERROR_CODE_UNRECOGNIZED_CHAIN_ID || C.code === Pc.ERROR_CODE_DEFAULT || ((E = (m = C == null ? void 0 : C.data) == null ? void 0 : m.originalError) == null ? void 0 : E.code) === Pc.ERROR_CODE_UNRECOGNIZED_CHAIN_ID)
17675
+ });
17676
+ } catch (E) {
17677
+ if (E.code === Pc.ERROR_CODE_UNRECOGNIZED_CHAIN_ID || E.code === Pc.ERROR_CODE_DEFAULT || ((m = (w = E == null ? void 0 : E.data) == null ? void 0 : w.originalError) == null ? void 0 : m.code) === Pc.ERROR_CODE_UNRECOGNIZED_CHAIN_ID)
17685
17678
  await wr.addEthereumChain(g, e);
17686
17679
  else
17687
17680
  throw new Error("Chain is not supported");
17688
17681
  }
17689
- }, n = He.getProvider("eip155"), s = He.state.providerIds.eip155;
17682
+ }
17683
+ const n = He.getProvider("eip155"), s = He.state.providerIds.eip155;
17690
17684
  if (n)
17691
17685
  switch (s) {
17692
17686
  case F.WALLET_CONNECT_CONNECTOR_ID:
@@ -17788,7 +17782,7 @@ class Y1 {
17788
17782
  }
17789
17783
  }
17790
17784
  }
17791
- const X1 = "@reown/appkit-ethers", eA = "1.0.2", tA = "module", nA = "./dist/esm/exports/index.js", rA = "./dist/types/exports/index.d.ts", sA = [
17785
+ const X1 = "@reown/appkit-ethers", eA = "1.0.3", tA = "module", nA = "./dist/esm/exports/index.js", rA = "./dist/types/exports/index.d.ts", sA = [
17792
17786
  "dist",
17793
17787
  "!tsconfig.tsbuildinfo"
17794
17788
  ], iA = {