@chainrails/react 0.1.4 → 0.1.5

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,6 +1,6 @@
1
- import { useState as Ne, useRef as se, useEffect as ne, useMemo as me, useSyncExternalStore as Tt, useCallback as At, useLayoutEffect as vt, useDebugValue as Pt } from "react";
2
- import { jsx as U, Fragment as It, jsxs as ye } from "react/jsx-runtime";
3
- import './index.css';class X extends Error {
1
+ import { useState as X, useRef as ne, useEffect as re, useMemo as ye, useSyncExternalStore as Tt, useCallback as At, useLayoutEffect as vt, useDebugValue as Pt } from "react";
2
+ import { jsx as C, Fragment as It, jsxs as we } from "react/jsx-runtime";
3
+ import './index.css';class J extends Error {
4
4
  response;
5
5
  request;
6
6
  options;
@@ -31,7 +31,7 @@ class F extends Error {
31
31
  super(t?.code ? `Forced retry: ${t.code}` : "Forced retry", s ? { cause: s } : void 0), this.customDelay = t?.delay, this.code = t?.code, this.customRequest = t?.request;
32
32
  }
33
33
  }
34
- const we = (() => {
34
+ const be = (() => {
35
35
  let e = !1, t = !1;
36
36
  const s = typeof globalThis.ReadableStream == "function", n = typeof globalThis.Request == "function";
37
37
  if (s && n)
@@ -59,14 +59,14 @@ const we = (() => {
59
59
  // Supported in modern Fetch implementations (for example, browsers and recent Node.js/undici).
60
60
  // We still feature-check at runtime before exposing the shortcut.
61
61
  bytes: "*/*"
62
- }, H = 2147483647, Ot = new TextEncoder().encode("------WebKitFormBoundaryaxpyiPgbbPti10Rw").length, $e = Symbol("stop");
62
+ }, H = 2147483647, Dt = new TextEncoder().encode("------WebKitFormBoundaryaxpyiPgbbPti10Rw").length, $e = Symbol("stop");
63
63
  class Le {
64
64
  options;
65
65
  constructor(t) {
66
66
  this.options = t;
67
67
  }
68
68
  }
69
- const Dt = (e) => new Le(e), Nt = {
69
+ const Ot = (e) => new Le(e), Nt = {
70
70
  json: !0,
71
71
  parseJson: !0,
72
72
  stringifyJson: !0,
@@ -104,7 +104,7 @@ const Dt = (e) => new Le(e), Nt = {
104
104
  if (e instanceof FormData) {
105
105
  let t = 0;
106
106
  for (const [s, n] of e)
107
- t += Ot, t += new TextEncoder().encode(`Content-Disposition: form-data; name="${s}"`).length, t += typeof n == "string" ? new TextEncoder().encode(n).length : n.size;
107
+ t += Dt, t += new TextEncoder().encode(`Content-Disposition: form-data; name="${s}"`).length, t += typeof n == "string" ? new TextEncoder().encode(n).length : n.size;
108
108
  return t;
109
109
  }
110
110
  if (e instanceof Blob)
@@ -164,25 +164,25 @@ const Dt = (e) => new Le(e), Nt = {
164
164
  duplex: "half",
165
165
  body: ze(e.body, n, t)
166
166
  });
167
- }, P = (e) => e !== null && typeof e == "object", N = (...e) => {
167
+ }, I = (e) => e !== null && typeof e == "object", M = (...e) => {
168
168
  for (const t of e)
169
- if ((!P(t) || Array.isArray(t)) && t !== void 0)
169
+ if ((!I(t) || Array.isArray(t)) && t !== void 0)
170
170
  throw new TypeError("The `options` argument must be an object");
171
- return re({}, ...e);
171
+ return oe({}, ...e);
172
172
  }, je = (e = {}, t = {}) => {
173
173
  const s = new globalThis.Headers(e), n = t instanceof globalThis.Headers, r = new globalThis.Headers(t);
174
174
  for (const [i, o] of r.entries())
175
175
  n && o === "undefined" || o === void 0 ? s.delete(i) : s.set(i, o);
176
176
  return s;
177
177
  };
178
- function M(e, t, s) {
179
- return Object.hasOwn(t, s) && t[s] === void 0 ? [] : re(e[s] ?? [], t[s] ?? []);
178
+ function B(e, t, s) {
179
+ return Object.hasOwn(t, s) && t[s] === void 0 ? [] : oe(e[s] ?? [], t[s] ?? []);
180
180
  }
181
181
  const qe = (e = {}, t = {}) => ({
182
- beforeRequest: M(e, t, "beforeRequest"),
183
- beforeRetry: M(e, t, "beforeRetry"),
184
- afterResponse: M(e, t, "afterResponse"),
185
- beforeError: M(e, t, "beforeError")
182
+ beforeRequest: B(e, t, "beforeRequest"),
183
+ beforeRetry: B(e, t, "beforeRetry"),
184
+ afterResponse: B(e, t, "afterResponse"),
185
+ beforeError: B(e, t, "beforeError")
186
186
  }), zt = (e, t) => {
187
187
  const s = new URLSearchParams();
188
188
  for (const n of [e, t])
@@ -196,7 +196,7 @@ const qe = (e = {}, t = {}) => ({
196
196
  throw new TypeError("Array search parameters must be provided in [[key, value], ...] format");
197
197
  s.append(String(r[0]), String(r[1]));
198
198
  }
199
- else if (P(n))
199
+ else if (I(n))
200
200
  for (const [r, i] of Object.entries(n))
201
201
  i !== void 0 && s.append(r, String(i));
202
202
  else {
@@ -205,20 +205,20 @@ const qe = (e = {}, t = {}) => ({
205
205
  s.append(i, o);
206
206
  }
207
207
  return s;
208
- }, re = (...e) => {
208
+ }, oe = (...e) => {
209
209
  let t = {}, s = {}, n = {}, r;
210
210
  const i = [];
211
211
  for (const o of e)
212
212
  if (Array.isArray(o))
213
213
  Array.isArray(t) || (t = []), t = [...t, ...o];
214
- else if (P(o)) {
214
+ else if (I(o)) {
215
215
  for (let [a, c] of Object.entries(o)) {
216
216
  if (a === "signal" && c instanceof globalThis.AbortSignal) {
217
217
  i.push(c);
218
218
  continue;
219
219
  }
220
220
  if (a === "context") {
221
- if (c != null && (!P(c) || Array.isArray(c)))
221
+ if (c != null && (!I(c) || Array.isArray(c)))
222
222
  throw new TypeError("The `context` option must be an object");
223
223
  t = {
224
224
  ...t,
@@ -230,12 +230,12 @@ const qe = (e = {}, t = {}) => ({
230
230
  c == null ? r = void 0 : r = r === void 0 ? c : zt(r, c);
231
231
  continue;
232
232
  }
233
- P(c) && a in t && (c = re(t[a], c)), t = { ...t, [a]: c };
233
+ I(c) && a in t && (c = oe(t[a], c)), t = { ...t, [a]: c };
234
234
  }
235
- P(o.hooks) && (n = qe(n, o.hooks), t.hooks = n), P(o.headers) && (s = je(s, o.headers), t.headers = s);
235
+ I(o.hooks) && (n = qe(n, o.hooks), t.hooks = n), I(o.headers) && (s = je(s, o.headers), t.headers = s);
236
236
  }
237
237
  return r !== void 0 && (t.searchParams = r), i.length > 0 && (i.length === 1 ? t.signal = i[0] : Be ? t.signal = AbortSignal.any(i) : t.signal = i.at(-1)), t.context === void 0 && (t.context = {}), t;
238
- }, jt = (e) => _e.includes(e) ? e.toUpperCase() : e, qt = ["get", "put", "head", "delete", "options", "trace"], Ft = [408, 413, 429, 500, 502, 503, 504], Ht = [413, 429, 503], be = {
238
+ }, jt = (e) => _e.includes(e) ? e.toUpperCase() : e, qt = ["get", "put", "head", "delete", "options", "trace"], Ft = [408, 413, 429, 500, 502, 503, 504], Ht = [413, 429, 503], Ee = {
239
239
  limit: 2,
240
240
  methods: qt,
241
241
  statusCodes: Ft,
@@ -248,7 +248,7 @@ const qe = (e = {}, t = {}) => ({
248
248
  }, Kt = (e = {}) => {
249
249
  if (typeof e == "number")
250
250
  return {
251
- ...be,
251
+ ...Ee,
252
252
  limit: e
253
253
  };
254
254
  if (e.methods && !Array.isArray(e.methods))
@@ -256,11 +256,11 @@ const qe = (e = {}, t = {}) => ({
256
256
  if (e.statusCodes && !Array.isArray(e.statusCodes))
257
257
  throw new Error("retry.statusCodes must be an array");
258
258
  return {
259
- ...be,
259
+ ...Ee,
260
260
  ...e
261
261
  };
262
262
  };
263
- class J extends Error {
263
+ class G extends Error {
264
264
  request;
265
265
  constructor(t) {
266
266
  super(`Request timed out: ${t.method} ${t.url}`), this.name = "TimeoutError", this.request = t;
@@ -269,7 +269,7 @@ class J extends Error {
269
269
  async function Wt(e, t, s, n) {
270
270
  return new Promise((r, i) => {
271
271
  const o = setTimeout(() => {
272
- s && s.abort(), i(new J(e));
272
+ s && s.abort(), i(new G(e));
273
273
  }, n.timeout);
274
274
  n.fetch(e, t).then(r).catch(i).then(() => {
275
275
  clearTimeout(o);
@@ -294,10 +294,10 @@ const Yt = (e, t) => {
294
294
  return s;
295
295
  }, Xt = (e) => e === void 0 ? !1 : Array.isArray(e) ? e.length > 0 : e instanceof URLSearchParams ? e.size > 0 : typeof e == "object" ? Object.keys(e).length > 0 : typeof e == "string" ? e.trim().length > 0 : !!e;
296
296
  function Jt(e) {
297
- return e instanceof X || e?.name === X.name;
297
+ return e instanceof J || e?.name === J.name;
298
298
  }
299
299
  function Gt(e) {
300
- return e instanceof J || e?.name === J.name;
300
+ return e instanceof G || e?.name === G.name;
301
301
  }
302
302
  class O {
303
303
  static create(t, s) {
@@ -315,7 +315,7 @@ class O {
315
315
  ]), new F(u.options);
316
316
  }
317
317
  if (n.#l(o), !o.ok && (typeof n.#e.throwHttpErrors == "function" ? n.#e.throwHttpErrors(o.status) : n.#e.throwHttpErrors)) {
318
- let a = new X(o, n.request, n.#a());
318
+ let a = new J(o, n.request, n.#a());
319
319
  for (const c of n.#e.hooks.beforeError)
320
320
  a = await c(a, { retryCount: n.#s });
321
321
  throw a;
@@ -385,7 +385,7 @@ class O {
385
385
  throw new Error("`input` must not begin with a slash when using `prefixUrl`");
386
386
  this.#e.prefixUrl.endsWith("/") || (this.#e.prefixUrl += "/"), this.#t = this.#e.prefixUrl + this.#t;
387
387
  }
388
- Ut && Be && (this.#r = this.#e.signal ?? this.#t.signal, this.#n = new globalThis.AbortController(), this.#e.signal = this.#r ? AbortSignal.any([this.#r, this.#n.signal]) : this.#n.signal), we && (this.#e.duplex = "half"), this.#e.json !== void 0 && (this.#e.body = this.#e.stringifyJson?.(this.#e.json) ?? JSON.stringify(this.#e.json), this.#e.headers.set("content-type", this.#e.headers.get("content-type") ?? "application/json"));
388
+ Ut && Be && (this.#r = this.#e.signal ?? this.#t.signal, this.#n = new globalThis.AbortController(), this.#e.signal = this.#r ? AbortSignal.any([this.#r, this.#n.signal]) : this.#n.signal), be && (this.#e.duplex = "half"), this.#e.json !== void 0 && (this.#e.body = this.#e.stringifyJson?.(this.#e.json) ?? JSON.stringify(this.#e.json), this.#e.headers.set("content-type", this.#e.headers.get("content-type") ?? "application/json"));
389
389
  const n = s.headers && new globalThis.Headers(s.headers).has("content-type");
390
390
  if (this.#t instanceof globalThis.Request && (xt && this.#e.body instanceof globalThis.FormData || this.#e.body instanceof URLSearchParams) && !n && this.#e.headers.delete("content-type"), this.request = new globalThis.Request(this.#t, this.#e), Xt(this.#e.searchParams)) {
391
391
  const i = "?" + (typeof this.#e.searchParams == "string" ? this.#e.searchParams.replace(/^\?/, "") : new URLSearchParams(O.#d(this.#e.searchParams)).toString()), o = this.request.url.replace(/(?:\?.*?)?(?=#|$)/, i);
@@ -394,7 +394,7 @@ class O {
394
394
  if (this.#e.onUploadProgress) {
395
395
  if (typeof this.#e.onUploadProgress != "function")
396
396
  throw new TypeError("The `onUploadProgress` option must be a function");
397
- if (!we)
397
+ if (!be)
398
398
  throw new Error("Request streams are not supported in your environment. The `duplex` option for `Request` is not available.");
399
399
  this.request = this.#h(this.request, this.#e.body ?? void 0);
400
400
  }
@@ -498,13 +498,13 @@ class O {
498
498
  }
499
499
  }
500
500
  /*! MIT License © Sindre Sorhus */
501
- const G = (e) => {
502
- const t = (s, n) => O.create(s, N(e, n));
501
+ const Z = (e) => {
502
+ const t = (s, n) => O.create(s, M(e, n));
503
503
  for (const s of _e)
504
- t[s] = (n, r) => O.create(n, N(e, r, { method: s }));
505
- return t.create = (s) => G(N(s)), t.extend = (s) => (typeof s == "function" && (s = s(e ?? {})), G(N(e, s))), t.stop = $e, t.retry = Dt, t;
506
- }, Zt = G();
507
- var E = /* @__PURE__ */ ((e) => (e.USDC = "USDC", e))(E || {});
504
+ t[s] = (n, r) => O.create(n, M(e, r, { method: s }));
505
+ return t.create = (s) => Z(M(s)), t.extend = (s) => (typeof s == "function" && (s = s(e ?? {})), Z(M(e, s))), t.stop = $e, t.retry = Ot, t;
506
+ }, Zt = Z();
507
+ var S = /* @__PURE__ */ ((e) => (e.USDC = "USDC", e))(S || {});
508
508
  const Fe = {
509
509
  type: "evm",
510
510
  chainId: 42161,
@@ -567,20 +567,20 @@ const Fe = {
567
567
  cctpDomain: null,
568
568
  logoURI: "/images/chains/starknet.svg"
569
569
  };
570
- function oe(e, { strict: t = !0 } = {}) {
570
+ function ie(e, { strict: t = !0 } = {}) {
571
571
  return !e || typeof e != "string" ? !1 : t ? /^0x[0-9a-fA-F]*$/.test(e) : e.startsWith("0x");
572
572
  }
573
- function Ee(e) {
574
- return oe(e, { strict: !1 }) ? Math.ceil((e.length - 2) / 2) : e.length;
573
+ function Se(e) {
574
+ return ie(e, { strict: !1 }) ? Math.ceil((e.length - 2) / 2) : e.length;
575
575
  }
576
576
  const Qe = "2.43.4";
577
577
  let K = {
578
578
  getDocsUrl: ({ docsBaseUrl: e, docsPath: t = "", docsSlug: s }) => t ? `${e ?? "https://viem.sh"}${t}${s ? `#${s}` : ""}` : void 0,
579
579
  version: `viem@${Qe}`
580
580
  };
581
- class A extends Error {
581
+ class v extends Error {
582
582
  constructor(t, s = {}) {
583
- const n = s.cause instanceof A ? s.cause.details : s.cause?.message ? s.cause.message : s.details, r = s.cause instanceof A && s.cause.docsPath || s.docsPath, i = K.getDocsUrl?.({ ...s, docsPath: r }), o = [
583
+ const n = s.cause instanceof v ? s.cause.details : s.cause?.message ? s.cause.message : s.details, r = s.cause instanceof v && s.cause.docsPath || s.docsPath, i = K.getDocsUrl?.({ ...s, docsPath: r }), o = [
584
584
  t || "An error occurred.",
585
585
  "",
586
586
  ...s.metaMessages ? [...s.metaMessages, ""] : [],
@@ -628,12 +628,12 @@ class A extends Error {
628
628
  function et(e, t) {
629
629
  return t?.(e) ? e : e && typeof e == "object" && "cause" in e && e.cause !== void 0 ? et(e.cause, t) : t ? null : e;
630
630
  }
631
- class tt extends A {
631
+ class tt extends v {
632
632
  constructor({ size: t, targetSize: s, type: n }) {
633
633
  super(`${n.charAt(0).toUpperCase()}${n.slice(1).toLowerCase()} size (${t}) exceeds padding size (${s}).`, { name: "SizeExceedsPaddingSizeError" });
634
634
  }
635
635
  }
636
- function j(e, { dir: t, size: s = 32 } = {}) {
636
+ function q(e, { dir: t, size: s = 32 } = {}) {
637
637
  return typeof e == "string" ? Qt(e, { dir: t, size: s }) : es(e, { dir: t, size: s });
638
638
  }
639
639
  function Qt(e, { dir: t, size: s = 32 } = {}) {
@@ -664,20 +664,20 @@ function es(e, { dir: t, size: s = 32 } = {}) {
664
664
  }
665
665
  return n;
666
666
  }
667
- class ts extends A {
667
+ class ts extends v {
668
668
  constructor({ max: t, min: s, signed: n, size: r, value: i }) {
669
669
  super(`Number "${i}" is not in safe ${r ? `${r * 8}-bit ${n ? "signed" : "unsigned"} ` : ""}integer range ${t ? `(${s} to ${t})` : `(above ${s})`}`, { name: "IntegerOutOfRangeError" });
670
670
  }
671
671
  }
672
- class ss extends A {
672
+ class ss extends v {
673
673
  constructor({ givenSize: t, maxSize: s }) {
674
674
  super(`Size cannot exceed ${s} bytes. Given size: ${t} bytes.`, { name: "SizeOverflowError" });
675
675
  }
676
676
  }
677
- function ie(e, { size: t }) {
678
- if (Ee(e) > t)
677
+ function ae(e, { size: t }) {
678
+ if (Se(e) > t)
679
679
  throw new ss({
680
- givenSize: Ee(e),
680
+ givenSize: Se(e),
681
681
  maxSize: t
682
682
  });
683
683
  }
@@ -697,17 +697,17 @@ function ns(e, t = {}) {
697
697
  });
698
698
  }
699
699
  const a = `0x${(s && r < 0 ? (1n << BigInt(n * 8)) + BigInt(r) : r).toString(16)}`;
700
- return n ? j(a, { size: n }) : a;
700
+ return n ? q(a, { size: n }) : a;
701
701
  }
702
702
  const rs = /* @__PURE__ */ new TextEncoder();
703
703
  function os(e, t = {}) {
704
- return typeof e == "number" || typeof e == "bigint" ? as(e, t) : typeof e == "boolean" ? is(e, t) : oe(e) ? st(e, t) : nt(e, t);
704
+ return typeof e == "number" || typeof e == "bigint" ? as(e, t) : typeof e == "boolean" ? is(e, t) : ie(e) ? st(e, t) : nt(e, t);
705
705
  }
706
706
  function is(e, t = {}) {
707
707
  const s = new Uint8Array(1);
708
- return s[0] = Number(e), typeof t.size == "number" ? (ie(s, { size: t.size }), j(s, { size: t.size })) : s;
708
+ return s[0] = Number(e), typeof t.size == "number" ? (ae(s, { size: t.size }), q(s, { size: t.size })) : s;
709
709
  }
710
- const S = {
710
+ const R = {
711
711
  zero: 48,
712
712
  nine: 57,
713
713
  A: 65,
@@ -715,24 +715,24 @@ const S = {
715
715
  a: 97,
716
716
  f: 102
717
717
  };
718
- function Se(e) {
719
- if (e >= S.zero && e <= S.nine)
720
- return e - S.zero;
721
- if (e >= S.A && e <= S.F)
722
- return e - (S.A - 10);
723
- if (e >= S.a && e <= S.f)
724
- return e - (S.a - 10);
718
+ function Re(e) {
719
+ if (e >= R.zero && e <= R.nine)
720
+ return e - R.zero;
721
+ if (e >= R.A && e <= R.F)
722
+ return e - (R.A - 10);
723
+ if (e >= R.a && e <= R.f)
724
+ return e - (R.a - 10);
725
725
  }
726
726
  function st(e, t = {}) {
727
727
  let s = e;
728
- t.size && (ie(s, { size: t.size }), s = j(s, { dir: "right", size: t.size }));
728
+ t.size && (ae(s, { size: t.size }), s = q(s, { dir: "right", size: t.size }));
729
729
  let n = s.slice(2);
730
730
  n.length % 2 && (n = `0${n}`);
731
731
  const r = n.length / 2, i = new Uint8Array(r);
732
732
  for (let o = 0, a = 0; o < r; o++) {
733
- const c = Se(n.charCodeAt(a++)), u = Se(n.charCodeAt(a++));
733
+ const c = Re(n.charCodeAt(a++)), u = Re(n.charCodeAt(a++));
734
734
  if (c === void 0 || u === void 0)
735
- throw new A(`Invalid byte sequence ("${n[a - 2]}${n[a - 1]}" in "${n}").`);
735
+ throw new v(`Invalid byte sequence ("${n[a - 2]}${n[a - 1]}" in "${n}").`);
736
736
  i[o] = c * 16 + u;
737
737
  }
738
738
  return i;
@@ -743,11 +743,11 @@ function as(e, t) {
743
743
  }
744
744
  function nt(e, t = {}) {
745
745
  const s = rs.encode(e);
746
- return typeof t.size == "number" ? (ie(s, { size: t.size }), j(s, { dir: "right", size: t.size })) : s;
746
+ return typeof t.size == "number" ? (ae(s, { size: t.size }), q(s, { dir: "right", size: t.size })) : s;
747
747
  }
748
- const B = /* @__PURE__ */ BigInt(2 ** 32 - 1), Re = /* @__PURE__ */ BigInt(32);
748
+ const _ = /* @__PURE__ */ BigInt(2 ** 32 - 1), Te = /* @__PURE__ */ BigInt(32);
749
749
  function cs(e, t = !1) {
750
- return t ? { h: Number(e & B), l: Number(e >> Re & B) } : { h: Number(e >> Re & B) | 0, l: Number(e & B) | 0 };
750
+ return t ? { h: Number(e & _), l: Number(e >> Te & _) } : { h: Number(e >> Te & _) | 0, l: Number(e & _) | 0 };
751
751
  }
752
752
  function us(e, t = !1) {
753
753
  const s = e.length;
@@ -763,24 +763,24 @@ const ls = (e, t, s) => e << s | t >>> 32 - s, fs = (e, t, s) => t << s | e >>>
763
763
  function ps(e) {
764
764
  return e instanceof Uint8Array || ArrayBuffer.isView(e) && e.constructor.name === "Uint8Array";
765
765
  }
766
- function Te(e) {
766
+ function Ae(e) {
767
767
  if (!Number.isSafeInteger(e) || e < 0)
768
768
  throw new Error("positive integer expected, got " + e);
769
769
  }
770
- function _(e, ...t) {
770
+ function $(e, ...t) {
771
771
  if (!ps(e))
772
772
  throw new Error("Uint8Array expected");
773
773
  if (t.length > 0 && !t.includes(e.length))
774
774
  throw new Error("Uint8Array expected of length " + t + ", got length=" + e.length);
775
775
  }
776
- function Ae(e, t = !0) {
776
+ function ve(e, t = !0) {
777
777
  if (e.destroyed)
778
778
  throw new Error("Hash instance has been destroyed");
779
779
  if (t && e.finished)
780
780
  throw new Error("Hash#digest() has already been called");
781
781
  }
782
782
  function gs(e, t) {
783
- _(e);
783
+ $(e);
784
784
  const s = t.outputLen;
785
785
  if (e.length < s)
786
786
  throw new Error("digestInto() expects output buffer of length at least " + s);
@@ -801,14 +801,14 @@ function bs(e) {
801
801
  e[t] = ws(e[t]);
802
802
  return e;
803
803
  }
804
- const ve = ys ? (e) => e : bs;
804
+ const Pe = ys ? (e) => e : bs;
805
805
  function Es(e) {
806
806
  if (typeof e != "string")
807
807
  throw new Error("string expected");
808
808
  return new Uint8Array(new TextEncoder().encode(e));
809
809
  }
810
810
  function ot(e) {
811
- return typeof e == "string" && (e = Es(e)), _(e), e;
811
+ return typeof e == "string" && (e = Es(e)), $(e), e;
812
812
  }
813
813
  class Ss {
814
814
  }
@@ -816,29 +816,29 @@ function Rs(e) {
816
816
  const t = (n) => e().update(ot(n)).digest(), s = e();
817
817
  return t.outputLen = s.outputLen, t.blockLen = s.blockLen, t.create = () => e(), t;
818
818
  }
819
- const Ts = BigInt(0), C = BigInt(1), As = BigInt(2), vs = BigInt(7), Ps = BigInt(256), Is = BigInt(113), it = [], at = [], ct = [];
820
- for (let e = 0, t = C, s = 1, n = 0; e < 24; e++) {
819
+ const Ts = BigInt(0), x = BigInt(1), As = BigInt(2), vs = BigInt(7), Ps = BigInt(256), Is = BigInt(113), it = [], at = [], ct = [];
820
+ for (let e = 0, t = x, s = 1, n = 0; e < 24; e++) {
821
821
  [s, n] = [n, (2 * s + 3 * n) % 5], it.push(2 * (5 * n + s)), at.push((e + 1) * (e + 2) / 2 % 64);
822
822
  let r = Ts;
823
823
  for (let i = 0; i < 7; i++)
824
- t = (t << C ^ (t >> vs) * Is) % Ps, t & As && (r ^= C << (C << /* @__PURE__ */ BigInt(i)) - C);
824
+ t = (t << x ^ (t >> vs) * Is) % Ps, t & As && (r ^= x << (x << /* @__PURE__ */ BigInt(i)) - x);
825
825
  ct.push(r);
826
826
  }
827
- const ut = us(ct, !0), Us = ut[0], Cs = ut[1], Pe = (e, t, s) => s > 32 ? hs(e, t, s) : ls(e, t, s), Ie = (e, t, s) => s > 32 ? ds(e, t, s) : fs(e, t, s);
827
+ const ut = us(ct, !0), Us = ut[0], Cs = ut[1], Ie = (e, t, s) => s > 32 ? hs(e, t, s) : ls(e, t, s), Ue = (e, t, s) => s > 32 ? ds(e, t, s) : fs(e, t, s);
828
828
  function xs(e, t = 24) {
829
829
  const s = new Uint32Array(10);
830
830
  for (let n = 24 - t; n < 24; n++) {
831
831
  for (let o = 0; o < 10; o++)
832
832
  s[o] = e[o] ^ e[o + 10] ^ e[o + 20] ^ e[o + 30] ^ e[o + 40];
833
833
  for (let o = 0; o < 10; o += 2) {
834
- const a = (o + 8) % 10, c = (o + 2) % 10, u = s[c], l = s[c + 1], w = Pe(u, l, 1) ^ s[a], d = Ie(u, l, 1) ^ s[a + 1];
835
- for (let y = 0; y < 50; y += 10)
836
- e[o + y] ^= w, e[o + y + 1] ^= d;
834
+ const a = (o + 8) % 10, c = (o + 2) % 10, u = s[c], f = s[c + 1], y = Ie(u, f, 1) ^ s[a], g = Ue(u, f, 1) ^ s[a + 1];
835
+ for (let w = 0; w < 50; w += 10)
836
+ e[o + w] ^= y, e[o + w + 1] ^= g;
837
837
  }
838
838
  let r = e[2], i = e[3];
839
839
  for (let o = 0; o < 24; o++) {
840
- const a = at[o], c = Pe(r, i, a), u = Ie(r, i, a), l = it[o];
841
- r = e[l], i = e[l + 1], e[l] = c, e[l + 1] = u;
840
+ const a = at[o], c = Ie(r, i, a), u = Ue(r, i, a), f = it[o];
841
+ r = e[f], i = e[f + 1], e[f] = c, e[f + 1] = u;
842
842
  }
843
843
  for (let o = 0; o < 50; o += 10) {
844
844
  for (let a = 0; a < 10; a++)
@@ -850,10 +850,10 @@ function xs(e, t = 24) {
850
850
  }
851
851
  rt(s);
852
852
  }
853
- class ae extends Ss {
853
+ class ce extends Ss {
854
854
  // NOTE: we accept arguments in bytes instead of bits here.
855
855
  constructor(t, s, n, r = !1, i = 24) {
856
- if (super(), this.pos = 0, this.posOut = 0, this.finished = !1, this.destroyed = !1, this.enableXOF = !1, this.blockLen = t, this.suffix = s, this.outputLen = n, this.enableXOF = r, this.rounds = i, Te(n), !(0 < t && t < 200))
856
+ if (super(), this.pos = 0, this.posOut = 0, this.finished = !1, this.destroyed = !1, this.enableXOF = !1, this.blockLen = t, this.suffix = s, this.outputLen = n, this.enableXOF = r, this.rounds = i, Ae(n), !(0 < t && t < 200))
857
857
  throw new Error("only keccak-f1600 function is supported");
858
858
  this.state = new Uint8Array(200), this.state32 = ms(this.state);
859
859
  }
@@ -861,10 +861,10 @@ class ae extends Ss {
861
861
  return this._cloneInto();
862
862
  }
863
863
  keccak() {
864
- ve(this.state32), xs(this.state32, this.rounds), ve(this.state32), this.posOut = 0, this.pos = 0;
864
+ Pe(this.state32), xs(this.state32, this.rounds), Pe(this.state32), this.posOut = 0, this.pos = 0;
865
865
  }
866
866
  update(t) {
867
- Ae(this), t = ot(t), _(t);
867
+ ve(this), t = ot(t), $(t);
868
868
  const { blockLen: s, state: n } = this, r = t.length;
869
869
  for (let i = 0; i < r; ) {
870
870
  const o = Math.min(s - this.pos, r - i);
@@ -882,7 +882,7 @@ class ae extends Ss {
882
882
  t[n] ^= s, (s & 128) !== 0 && n === r - 1 && this.keccak(), t[r - 1] ^= 128, this.keccak();
883
883
  }
884
884
  writeInto(t) {
885
- Ae(this, !1), _(t), this.finish();
885
+ ve(this, !1), $(t), this.finish();
886
886
  const s = this.state, { blockLen: n } = this;
887
887
  for (let r = 0, i = t.length; r < i; ) {
888
888
  this.posOut >= n && this.keccak();
@@ -897,7 +897,7 @@ class ae extends Ss {
897
897
  return this.writeInto(t);
898
898
  }
899
899
  xof(t) {
900
- return Te(t), this.xofInto(new Uint8Array(t));
900
+ return Ae(t), this.xofInto(new Uint8Array(t));
901
901
  }
902
902
  digestInto(t) {
903
903
  if (gs(t, this), this.finished)
@@ -912,14 +912,14 @@ class ae extends Ss {
912
912
  }
913
913
  _cloneInto(t) {
914
914
  const { blockLen: s, suffix: n, outputLen: r, rounds: i, enableXOF: o } = this;
915
- return t || (t = new ae(s, n, r, o, i)), t.state32.set(this.state32), t.pos = this.pos, t.posOut = this.posOut, t.finished = this.finished, t.rounds = i, t.suffix = n, t.outputLen = r, t.enableXOF = o, t.destroyed = this.destroyed, t;
915
+ return t || (t = new ce(s, n, r, o, i)), t.state32.set(this.state32), t.pos = this.pos, t.posOut = this.posOut, t.finished = this.finished, t.rounds = i, t.suffix = n, t.outputLen = r, t.enableXOF = o, t.destroyed = this.destroyed, t;
916
916
  }
917
917
  }
918
- const ks = (e, t, s) => Rs(() => new ae(t, e, s)), Os = ks(1, 136, 256 / 8);
919
- function Ds(e, t) {
920
- return Os(oe(e, { strict: !1 }) ? os(e) : e);
918
+ const ks = (e, t, s) => Rs(() => new ce(t, e, s)), Ds = ks(1, 136, 256 / 8);
919
+ function Os(e, t) {
920
+ return Ds(ie(e, { strict: !1 }) ? os(e) : e);
921
921
  }
922
- class Ns extends A {
922
+ class Ns extends v {
923
923
  constructor({ address: t }) {
924
924
  super(`Address "${t}" is invalid.`, {
925
925
  metaMessages: [
@@ -955,13 +955,13 @@ const W = /* @__PURE__ */ new lt(8192);
955
955
  function ft(e, t) {
956
956
  if (W.has(`${e}.${t}`))
957
957
  return W.get(`${e}.${t}`);
958
- const s = e.substring(2).toLowerCase(), n = Ds(nt(s)), r = s.split("");
958
+ const s = e.substring(2).toLowerCase(), n = Os(nt(s)), r = s.split("");
959
959
  for (let o = 0; o < 40; o += 2)
960
960
  n[o >> 1] >> 4 >= 8 && r[o] && (r[o] = r[o].toUpperCase()), (n[o >> 1] & 15) >= 8 && r[o + 1] && (r[o + 1] = r[o + 1].toUpperCase());
961
961
  const i = `0x${r.join("")}`;
962
962
  return W.set(`${e}.${t}`, i), i;
963
963
  }
964
- function R(e, t) {
964
+ function T(e, t) {
965
965
  if (!Bs(e, { strict: !1 }))
966
966
  throw new Ns({ address: e });
967
967
  return ft(e, t);
@@ -976,7 +976,7 @@ function Bs(e, t) {
976
976
  }
977
977
  const _s = {
978
978
  chainId: He.chainId,
979
- address: R("0x75faf114eafb1BDbe2F0316DF893fd58CE46AA4d"),
979
+ address: T("0x75faf114eafb1BDbe2F0316DF893fd58CE46AA4d"),
980
980
  symbol: "USDC",
981
981
  fiatISO: "USD",
982
982
  decimals: 6,
@@ -984,7 +984,7 @@ const _s = {
984
984
  logoSourceURI: "https://pay.daimo.com/coin-logos/usdc.png"
985
985
  }, $s = {
986
986
  chainId: Fe.chainId,
987
- address: R("0xaf88d065e77c8cC2239327C5EDb3A432268e5831"),
987
+ address: T("0xaf88d065e77c8cC2239327C5EDb3A432268e5831"),
988
988
  symbol: "USDC",
989
989
  name: "USD Coin",
990
990
  decimals: 6,
@@ -992,7 +992,7 @@ const _s = {
992
992
  /* USDC */
993
993
  }, Ls = {
994
994
  chainId: Ge.chainId,
995
- address: R("0x5425890298aed601595a70ab815c96711a31bc65"),
995
+ address: T("0x5425890298aed601595a70ab815c96711a31bc65"),
996
996
  symbol: "USDC",
997
997
  fiatISO: "USD",
998
998
  decimals: 6,
@@ -1000,7 +1000,7 @@ const _s = {
1000
1000
  logoSourceURI: "https://pay.daimo.com/coin-logos/usdc.png"
1001
1001
  }, zs = {
1002
1002
  chainId: Je.chainId,
1003
- address: R("0xB97EF9Ef8734C71904D8002F8b6Bc66Dd9c48a6E"),
1003
+ address: T("0xB97EF9Ef8734C71904D8002F8b6Bc66Dd9c48a6E"),
1004
1004
  symbol: "USDC",
1005
1005
  fiatISO: "USD",
1006
1006
  decimals: 6,
@@ -1008,7 +1008,7 @@ const _s = {
1008
1008
  logoSourceURI: "https://pay.daimo.com/coin-logos/usdc.png"
1009
1009
  }, js = {
1010
1010
  chainId: We.chainId,
1011
- address: R("0x036CbD53842c5426634e7929541eC2318f3dCF7e"),
1011
+ address: T("0x036CbD53842c5426634e7929541eC2318f3dCF7e"),
1012
1012
  symbol: "USDC",
1013
1013
  fiatISO: "USD",
1014
1014
  decimals: 6,
@@ -1016,7 +1016,7 @@ const _s = {
1016
1016
  logoSourceURI: "https://pay.daimo.com/coin-logos/usdc.png"
1017
1017
  }, qs = {
1018
1018
  chainId: Ke.chainId,
1019
- address: R("0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913"),
1019
+ address: T("0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913"),
1020
1020
  symbol: "USDC",
1021
1021
  fiatISO: "USD",
1022
1022
  decimals: 6,
@@ -1024,21 +1024,21 @@ const _s = {
1024
1024
  logoSourceURI: "https://pay.daimo.com/coin-logos/usdc.png"
1025
1025
  }, Fs = {
1026
1026
  chainId: Ve.chainId,
1027
- address: R("0x8AC76a51cc950d9822D68b83fE1Ad97B32Cd580d"),
1027
+ address: T("0x8AC76a51cc950d9822D68b83fE1Ad97B32Cd580d"),
1028
1028
  symbol: "USDC",
1029
1029
  decimals: 18,
1030
1030
  logoURI: "https://pay.daimo.com/coin-logos/usdc.png",
1031
1031
  logoSourceURI: "https://pay.daimo.com/coin-logos/usdc.png"
1032
1032
  }, Hs = {
1033
1033
  chainId: Xe.chainId,
1034
- address: R("0x1c7D4B196Cb0C7B01d743Fbc6116a902379C7238"),
1034
+ address: T("0x1c7D4B196Cb0C7B01d743Fbc6116a902379C7238"),
1035
1035
  symbol: "USDC",
1036
1036
  decimals: 6,
1037
1037
  logoURI: "https://pay.daimo.com/coin-logos/usdc.png",
1038
1038
  logoSourceURI: "https://pay.daimo.com/coin-logos/usdc.png"
1039
1039
  }, Ks = {
1040
1040
  chainId: Ye.chainId,
1041
- address: R("0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48"),
1041
+ address: T("0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48"),
1042
1042
  symbol: "USDC",
1043
1043
  decimals: 6,
1044
1044
  logoURI: "https://pay.daimo.com/coin-logos/usdc.png",
@@ -1050,11 +1050,11 @@ const _s = {
1050
1050
  decimals: 6,
1051
1051
  logoURI: "https://pay.daimo.com/coin-logos/usdc.png",
1052
1052
  logoSourceURI: "https://pay.daimo.com/coin-logos/usdc.png"
1053
- }, Ue = {
1053
+ }, Ce = {
1054
1054
  ARBITRUM_MAINNET: {
1055
1055
  ...Fe,
1056
1056
  tokens: {
1057
- [E.USDC]: $s
1057
+ [S.USDC]: $s
1058
1058
  },
1059
1059
  explorer: "https://arbiscan.io"
1060
1060
  },
@@ -1062,79 +1062,79 @@ const _s = {
1062
1062
  ...He,
1063
1063
  explorer: "https://sepolia.arbiscan.io",
1064
1064
  tokens: {
1065
- [E.USDC]: _s
1065
+ [S.USDC]: _s
1066
1066
  }
1067
1067
  },
1068
1068
  AVALANCHE_MAINNET: {
1069
1069
  ...Je,
1070
1070
  tokens: {
1071
- [E.USDC]: zs
1071
+ [S.USDC]: zs
1072
1072
  },
1073
1073
  explorer: "https://snowtrace.io"
1074
1074
  },
1075
1075
  AVALANCHE_TESTNET: {
1076
1076
  ...Ge,
1077
1077
  tokens: {
1078
- [E.USDC]: Ls
1078
+ [S.USDC]: Ls
1079
1079
  },
1080
1080
  explorer: "https://testnet.snowtrace.io"
1081
1081
  },
1082
1082
  BASE_MAINNET: {
1083
1083
  ...Ke,
1084
1084
  tokens: {
1085
- [E.USDC]: qs
1085
+ [S.USDC]: qs
1086
1086
  },
1087
1087
  explorer: "https://basescan.org"
1088
1088
  },
1089
1089
  BASE_TESTNET: {
1090
1090
  ...We,
1091
1091
  tokens: {
1092
- [E.USDC]: js
1092
+ [S.USDC]: js
1093
1093
  },
1094
1094
  explorer: "https://sepolia.basescan.org"
1095
1095
  },
1096
1096
  BSC_MAINNET: {
1097
1097
  ...Ve,
1098
1098
  tokens: {
1099
- [E.USDC]: Fs
1099
+ [S.USDC]: Fs
1100
1100
  },
1101
1101
  explorer: "https://bscscan.com"
1102
1102
  },
1103
1103
  ETHEREUM_MAINNET: {
1104
1104
  ...Ye,
1105
1105
  tokens: {
1106
- [E.USDC]: Ks
1106
+ [S.USDC]: Ks
1107
1107
  },
1108
1108
  explorer: "https://etherscan.io"
1109
1109
  },
1110
1110
  ETHEREUM_TESTNET: {
1111
1111
  ...Xe,
1112
1112
  tokens: {
1113
- [E.USDC]: Hs
1113
+ [S.USDC]: Hs
1114
1114
  },
1115
1115
  explorer: "https://sepolia.etherscan.io"
1116
1116
  },
1117
1117
  STARKNET_MAINNET: {
1118
1118
  ...Ze,
1119
1119
  tokens: {
1120
- [E.USDC]: Ws
1120
+ [S.USDC]: Ws
1121
1121
  },
1122
1122
  explorer: ""
1123
1123
  }
1124
1124
  };
1125
- var Z = /* @__PURE__ */ ((e) => (e.ARBITRUM = "ARBITRUM_MAINNET", e.ARBITRUM_TESTNET = "ARBITRUM_TESTNET", e.AVALANCHE = "AVALANCHE_MAINNET", e.AVALANCHE_TESTNET = "AVALANCHE_TESTNET", e.BASE = "BASE_MAINNET", e.BASE_TESTNET = "BASE_TESTNET", e.BSC = "BSC_MAINNET", e.ETHEREUM = "ETHEREUM_MAINNET", e.ETHEREUM_TESTNET = "ETHEREUM_TESTNET", e.STARKNET = "STARKNET_MAINNET", e))(Z || {}), ht = /* @__PURE__ */ ((e) => (e.USDC = "USDC", e))(ht || {});
1125
+ var Q = /* @__PURE__ */ ((e) => (e.ARBITRUM = "ARBITRUM_MAINNET", e.ARBITRUM_TESTNET = "ARBITRUM_TESTNET", e.AVALANCHE = "AVALANCHE_MAINNET", e.AVALANCHE_TESTNET = "AVALANCHE_TESTNET", e.BASE = "BASE_MAINNET", e.BASE_TESTNET = "BASE_TESTNET", e.BSC = "BSC_MAINNET", e.ETHEREUM = "ETHEREUM_MAINNET", e.ETHEREUM_TESTNET = "ETHEREUM_TESTNET", e.STARKNET = "STARKNET_MAINNET", e))(Q || {}), ht = /* @__PURE__ */ ((e) => (e.USDC = "USDC", e))(ht || {});
1126
1126
  const Vs = (e) => {
1127
1127
  const t = e?.trim().toUpperCase();
1128
- if (Ue[t])
1129
- return Ue[t];
1128
+ if (Ce[t])
1129
+ return Ce[t];
1130
1130
  };
1131
1131
  function Ys(e, t) {
1132
1132
  return Vs(e)?.tokens[t]?.address;
1133
1133
  }
1134
- var ce = /* @__PURE__ */ ((e) => (e.PRODUCTION = "production", e.STAGING = "staging", e))(ce || {});
1134
+ var ue = /* @__PURE__ */ ((e) => (e.PRODUCTION = "production", e.STAGING = "staging", e))(ue || {});
1135
1135
  class h {
1136
1136
  constructor({ api_key: t, env: s, seesion_token: n }) {
1137
- this.api_key = t || "", this.sessionToken = n || "", this.env = s ?? ce.PRODUCTION;
1137
+ this.api_key = t || "", this.sessionToken = n || "", this.env = s ?? ue.PRODUCTION;
1138
1138
  }
1139
1139
  static async config(t) {
1140
1140
  if (!h.app) {
@@ -1180,9 +1180,9 @@ class h {
1180
1180
  return i + o + a;
1181
1181
  }
1182
1182
  }
1183
- let Q = null;
1183
+ let ee = null;
1184
1184
  function Xs() {
1185
- Q = Zt.create({
1185
+ ee = Zt.create({
1186
1186
  prefixUrl: h.getBaseUrl(),
1187
1187
  headers: {
1188
1188
  "Content-Type": "application/json"
@@ -1202,7 +1202,7 @@ function Xs() {
1202
1202
  });
1203
1203
  }
1204
1204
  function m() {
1205
- return Q || Xs(), Q;
1205
+ return ee || Xs(), ee;
1206
1206
  }
1207
1207
  class Js {
1208
1208
  async getById(t) {
@@ -1282,10 +1282,10 @@ class tn {
1282
1282
  const s = {
1283
1283
  recipient: t.recipient,
1284
1284
  tokenOut: Ys(
1285
- Z[t.destinationChain],
1285
+ Q[t.destinationChain],
1286
1286
  ht[t.token]
1287
1287
  ),
1288
- destinationChain: Z[t.destinationChain],
1288
+ destinationChain: Q[t.destinationChain],
1289
1289
  amount: t.amount
1290
1290
  };
1291
1291
  return m().post("modal/sessions", { json: s }).json();
@@ -1323,73 +1323,73 @@ function Un(e) {
1323
1323
  open: a,
1324
1324
  close: c,
1325
1325
  onCancel: u,
1326
- onSuccess: l,
1327
- data: w
1328
- } = e, [d, y] = Ne(!0), T = se(null);
1329
- ne(() => {
1330
- f();
1331
- const p = document.body.style.overflow;
1332
- i ? (document.body.style.overflow = "hidden", document.body.style.overflow = "hidden") : document.body.style.overflow = p || "";
1333
- const g = (b) => {
1334
- b.data === "closed" && (c(), u?.()), b.data === "completed" && (window.setTimeout(c, 2e3), l?.());
1326
+ onSuccess: f,
1327
+ data: y
1328
+ } = e, [g, w] = X(!0), E = ne(null);
1329
+ re(() => {
1330
+ l();
1331
+ const d = document.body.style.overflow;
1332
+ i ? (document.body.style.overflow = "hidden", document.body.style.overflow = "hidden") : document.body.style.overflow = d || "";
1333
+ const p = (b) => {
1334
+ b.data === "closed" && (c(), u?.()), b.data === "completed" && (window.setTimeout(c, 2e3), f?.());
1335
1335
  };
1336
- return window.addEventListener("message", g), () => {
1337
- document.body.style.overflow = p || "", window.removeEventListener("message", g);
1336
+ return window.addEventListener("message", p), () => {
1337
+ document.body.style.overflow = d || "", window.removeEventListener("message", p);
1338
1338
  };
1339
- }, [i, u, l]);
1340
- function q() {
1341
- y(!1), f();
1339
+ }, [i, u, f]);
1340
+ function A() {
1341
+ w(!1), l();
1342
1342
  }
1343
- function f() {
1344
- if (!w?.sessionToken) return;
1345
- const p = {
1343
+ function l() {
1344
+ if (!y?.sessionToken) return;
1345
+ const d = {
1346
1346
  type: "session",
1347
- session_token: w.sessionToken,
1348
- environment: h.getEnv() || ce.PRODUCTION
1347
+ session_token: y.sessionToken,
1348
+ environment: h.getEnv() || ue.PRODUCTION
1349
1349
  };
1350
- T.current?.contentWindow?.postMessage(p, "https://app.chainrails.io"), T.current?.contentWindow?.postMessage(p, "https://chainrails-frontend-git-staging-horus-labs.vercel.app");
1350
+ E.current?.contentWindow?.postMessage(d, "https://app.chainrails.io"), E.current?.contentWindow?.postMessage(d, "https://chainrails-frontend-git-staging-horus-labs.vercel.app");
1351
1351
  }
1352
- return w?.sessionToken ? /* @__PURE__ */ ye("div", {
1353
- className: sn("payment-modal-wrapper", d || o ? "loading" : "not-loading", i ? "open" : "closed"),
1354
- children: [(d || o) && /* @__PURE__ */ U("div", {
1352
+ return y?.sessionToken ? /* @__PURE__ */ we("div", {
1353
+ className: sn("payment-modal-wrapper", g || o ? "loading" : "not-loading", i ? "open" : "closed"),
1354
+ children: [(g || o) && /* @__PURE__ */ C("div", {
1355
1355
  role: "status",
1356
1356
  className: "payment-modal-loader",
1357
- children: /* @__PURE__ */ ye("svg", {
1357
+ children: /* @__PURE__ */ we("svg", {
1358
1358
  "aria-hidden": "true",
1359
1359
  className: "icon",
1360
1360
  viewBox: "0 0 100 101",
1361
1361
  fill: "none",
1362
1362
  xmlns: "http://www.w3.org/2000/svg",
1363
- children: [/* @__PURE__ */ U("path", {
1363
+ children: [/* @__PURE__ */ C("path", {
1364
1364
  d: "M100 50.5908C100 78.2051 77.6142 100.591 50 100.591C22.3858 100.591 0 78.2051 0 50.5908C0 22.9766 22.3858 0.59082 50 0.59082C77.6142 0.59082 100 22.9766 100 50.5908ZM9.08144 50.5908C9.08144 73.1895 27.4013 91.5094 50 91.5094C72.5987 91.5094 90.9186 73.1895 90.9186 50.5908C90.9186 27.9921 72.5987 9.67226 50 9.67226C27.4013 9.67226 9.08144 27.9921 9.08144 50.5908Z",
1365
1365
  fill: "currentColor"
1366
- }), /* @__PURE__ */ U("path", {
1366
+ }), /* @__PURE__ */ C("path", {
1367
1367
  d: "M93.9676 39.0409C96.393 38.4038 97.8624 35.9116 97.0079 33.5539C95.2932 28.8227 92.871 24.3692 89.8167 20.348C85.8452 15.1192 80.8826 10.7238 75.2124 7.41289C69.5422 4.10194 63.2754 1.94025 56.7698 1.05124C51.7666 0.367541 46.6976 0.446843 41.7345 1.27873C39.2613 1.69328 37.813 4.19778 38.4501 6.62326C39.0873 9.04874 41.5694 10.4717 44.0505 10.1071C47.8511 9.54855 51.7191 9.52689 55.5402 10.0491C60.8642 10.7766 65.9928 12.5457 70.6331 15.2552C75.2735 17.9648 79.3347 21.5619 82.5849 25.841C84.9175 28.9121 86.7997 32.2913 88.1811 35.8758C89.083 38.2158 91.5421 39.6781 93.9676 39.0409Z",
1368
1368
  fill: "currentFill"
1369
1369
  })]
1370
1370
  })
1371
- }), /* @__PURE__ */ U("iframe", {
1371
+ }), /* @__PURE__ */ C("iframe", {
1372
1372
  allow: "clipboard-read *; clipboard-write *",
1373
1373
  src: h.getPayModalUrl(n, s, t, r),
1374
- onLoad: q,
1375
- className: `payment-modal ${d || o ? "invisible" : "visible"}`,
1374
+ onLoad: A,
1375
+ className: `payment-modal ${g || o ? "invisible" : "visible"}`,
1376
1376
  "data-id": r,
1377
- ref: T
1377
+ ref: E
1378
1378
  })]
1379
- }) : /* @__PURE__ */ U(It, {});
1379
+ }) : /* @__PURE__ */ C(It, {});
1380
1380
  }
1381
1381
  function nn(e) {
1382
1382
  return BigInt(e).toString();
1383
1383
  }
1384
- const rn = Symbol(), ue = Symbol(), x = "a", pt = "f", Ce = "p", gt = "c", mt = "t", le = "h", k = "w", fe = "o", he = "k";
1384
+ const rn = Symbol(), le = Symbol(), k = "a", pt = "f", xe = "p", gt = "c", mt = "t", fe = "h", D = "w", he = "o", de = "k";
1385
1385
  let on = (e, t) => new Proxy(e, t);
1386
- const ee = Object.getPrototypeOf, te = /* @__PURE__ */ new WeakMap(), yt = (e) => e && (te.has(e) ? te.get(e) : ee(e) === Object.prototype || ee(e) === Array.prototype), $ = (e) => typeof e == "object" && e !== null, an = (e) => Object.values(Object.getOwnPropertyDescriptors(e)).some((t) => !t.configurable && !t.writable), cn = (e) => {
1386
+ const te = Object.getPrototypeOf, se = /* @__PURE__ */ new WeakMap(), yt = (e) => e && (se.has(e) ? se.get(e) : te(e) === Object.prototype || te(e) === Array.prototype), L = (e) => typeof e == "object" && e !== null, an = (e) => Object.values(Object.getOwnPropertyDescriptors(e)).some((t) => !t.configurable && !t.writable), cn = (e) => {
1387
1387
  if (Array.isArray(e))
1388
1388
  return Array.from(e);
1389
1389
  const t = Object.getOwnPropertyDescriptors(e);
1390
1390
  return Object.values(t).forEach((s) => {
1391
1391
  s.configurable = !0;
1392
- }), Object.create(ee(e), t);
1392
+ }), Object.create(te(e), t);
1393
1393
  }, un = (e, t) => {
1394
1394
  const s = {
1395
1395
  [pt]: t
@@ -1397,55 +1397,55 @@ const ee = Object.getPrototypeOf, te = /* @__PURE__ */ new WeakMap(), yt = (e) =
1397
1397
  let n = !1;
1398
1398
  const r = (a, c) => {
1399
1399
  if (!n) {
1400
- let u = s[x].get(e);
1401
- if (u || (u = {}, s[x].set(e, u)), a === k)
1402
- u[k] = !0;
1400
+ let u = s[k].get(e);
1401
+ if (u || (u = {}, s[k].set(e, u)), a === D)
1402
+ u[D] = !0;
1403
1403
  else {
1404
- let l = u[a];
1405
- l || (l = /* @__PURE__ */ new Set(), u[a] = l), l.add(c);
1404
+ let f = u[a];
1405
+ f || (f = /* @__PURE__ */ new Set(), u[a] = f), f.add(c);
1406
1406
  }
1407
1407
  }
1408
1408
  }, i = () => {
1409
- n = !0, s[x].delete(e);
1409
+ n = !0, s[k].delete(e);
1410
1410
  }, o = {
1411
1411
  get(a, c) {
1412
- return c === ue ? e : (r(he, c), wt(Reflect.get(a, c), s[x], s[gt], s[mt]));
1412
+ return c === le ? e : (r(de, c), wt(Reflect.get(a, c), s[k], s[gt], s[mt]));
1413
1413
  },
1414
1414
  has(a, c) {
1415
- return c === rn ? (i(), !0) : (r(le, c), Reflect.has(a, c));
1415
+ return c === rn ? (i(), !0) : (r(fe, c), Reflect.has(a, c));
1416
1416
  },
1417
1417
  getOwnPropertyDescriptor(a, c) {
1418
- return r(fe, c), Reflect.getOwnPropertyDescriptor(a, c);
1418
+ return r(he, c), Reflect.getOwnPropertyDescriptor(a, c);
1419
1419
  },
1420
1420
  ownKeys(a) {
1421
- return r(k), Reflect.ownKeys(a);
1421
+ return r(D), Reflect.ownKeys(a);
1422
1422
  }
1423
1423
  };
1424
1424
  return t && (o.set = o.deleteProperty = () => !1), [o, s];
1425
- }, de = (e) => (
1425
+ }, pe = (e) => (
1426
1426
  // unwrap proxy
1427
- e[ue] || // otherwise
1427
+ e[le] || // otherwise
1428
1428
  e
1429
1429
  ), wt = (e, t, s, n) => {
1430
1430
  if (!yt(e))
1431
1431
  return e;
1432
1432
  let r = n && n.get(e);
1433
1433
  if (!r) {
1434
- const c = de(e);
1434
+ const c = pe(e);
1435
1435
  an(c) ? r = [c, cn(c)] : r = [c], n?.set(e, r);
1436
1436
  }
1437
1437
  const [i, o] = r;
1438
1438
  let a = s && s.get(i);
1439
- return (!a || a[1][pt] !== !!o) && (a = un(i, !!o), a[1][Ce] = on(o || i, a[0]), s && s.set(i, a)), a[1][x] = t, a[1][gt] = s, a[1][mt] = n, a[1][Ce];
1439
+ return (!a || a[1][pt] !== !!o) && (a = un(i, !!o), a[1][xe] = on(o || i, a[0]), s && s.set(i, a)), a[1][k] = t, a[1][gt] = s, a[1][mt] = n, a[1][xe];
1440
1440
  }, ln = (e, t) => {
1441
1441
  const s = Reflect.ownKeys(e), n = Reflect.ownKeys(t);
1442
1442
  return s.length !== n.length || s.some((r, i) => r !== n[i]);
1443
1443
  }, bt = (e, t, s, n, r = Object.is) => {
1444
1444
  if (r(e, t))
1445
1445
  return !1;
1446
- if (!$(e) || !$(t))
1446
+ if (!L(e) || !L(t))
1447
1447
  return !0;
1448
- const i = s.get(de(e));
1448
+ const i = s.get(pe(e));
1449
1449
  if (!i)
1450
1450
  return !0;
1451
1451
  if (n) {
@@ -1454,57 +1454,57 @@ const ee = Object.getPrototypeOf, te = /* @__PURE__ */ new WeakMap(), yt = (e) =
1454
1454
  n.set(e, t);
1455
1455
  }
1456
1456
  let o = null;
1457
- for (const a of i[le] || [])
1457
+ for (const a of i[fe] || [])
1458
1458
  if (o = Reflect.has(e, a) !== Reflect.has(t, a), o)
1459
1459
  return o;
1460
- if (i[k] === !0) {
1460
+ if (i[D] === !0) {
1461
1461
  if (o = ln(e, t), o)
1462
1462
  return o;
1463
1463
  } else
1464
- for (const a of i[fe] || []) {
1464
+ for (const a of i[he] || []) {
1465
1465
  const c = !!Reflect.getOwnPropertyDescriptor(e, a), u = !!Reflect.getOwnPropertyDescriptor(t, a);
1466
1466
  if (o = c !== u, o)
1467
1467
  return o;
1468
1468
  }
1469
- for (const a of i[he] || [])
1469
+ for (const a of i[de] || [])
1470
1470
  if (o = bt(e[a], t[a], s, n, r), o)
1471
1471
  return o;
1472
1472
  if (o === null)
1473
1473
  throw new Error("invalid used");
1474
1474
  return o;
1475
- }, fn = (e) => yt(e) && e[ue] || null, xe = (e, t = !0) => {
1476
- te.set(e, t);
1475
+ }, fn = (e) => yt(e) && e[le] || null, ke = (e, t = !0) => {
1476
+ se.set(e, t);
1477
1477
  }, hn = (e, t, s) => {
1478
1478
  const n = [], r = /* @__PURE__ */ new WeakSet(), i = (o, a) => {
1479
- var c, u, l;
1479
+ var c, u, f;
1480
1480
  if (r.has(o))
1481
1481
  return;
1482
- $(o) && r.add(o);
1483
- const w = $(o) && t.get(de(o));
1484
- if (w) {
1485
- if ((c = w[le]) === null || c === void 0 || c.forEach((d) => {
1486
- const y = `:has(${String(d)})`;
1487
- n.push(a ? [...a, y] : [y]);
1488
- }), w[k] === !0) {
1489
- const d = ":ownKeys";
1490
- n.push(a ? [...a, d] : [d]);
1482
+ L(o) && r.add(o);
1483
+ const y = L(o) && t.get(pe(o));
1484
+ if (y) {
1485
+ if ((c = y[fe]) === null || c === void 0 || c.forEach((g) => {
1486
+ const w = `:has(${String(g)})`;
1487
+ n.push(a ? [...a, w] : [w]);
1488
+ }), y[D] === !0) {
1489
+ const g = ":ownKeys";
1490
+ n.push(a ? [...a, g] : [g]);
1491
1491
  } else
1492
- (u = w[fe]) === null || u === void 0 || u.forEach((d) => {
1493
- const y = `:hasOwn(${String(d)})`;
1494
- n.push(a ? [...a, y] : [y]);
1492
+ (u = y[he]) === null || u === void 0 || u.forEach((g) => {
1493
+ const w = `:hasOwn(${String(g)})`;
1494
+ n.push(a ? [...a, w] : [w]);
1495
1495
  });
1496
- (l = w[he]) === null || l === void 0 || l.forEach((d) => {
1497
- "value" in (Object.getOwnPropertyDescriptor(o, d) || {}) && i(o[d], a ? [...a, d] : [d]);
1496
+ (f = y[de]) === null || f === void 0 || f.forEach((g) => {
1497
+ "value" in (Object.getOwnPropertyDescriptor(o, g) || {}) && i(o[g], a ? [...a, g] : [g]);
1498
1498
  });
1499
1499
  } else a && n.push(a);
1500
1500
  };
1501
1501
  return i(e), n;
1502
- }, L = {}, pe = (e) => typeof e == "object" && e !== null, dn = (e) => pe(e) && !ge.has(e) && (Array.isArray(e) || !(Symbol.iterator in e)) && !(e instanceof WeakMap) && !(e instanceof WeakSet) && !(e instanceof Error) && !(e instanceof Number) && !(e instanceof Date) && !(e instanceof String) && !(e instanceof RegExp) && !(e instanceof ArrayBuffer) && !(e instanceof Promise), Et = (e, t) => {
1503
- const s = ke.get(e);
1502
+ }, z = {}, ge = (e) => typeof e == "object" && e !== null, dn = (e) => ge(e) && !me.has(e) && (Array.isArray(e) || !(Symbol.iterator in e)) && !(e instanceof WeakMap) && !(e instanceof WeakSet) && !(e instanceof Error) && !(e instanceof Number) && !(e instanceof Date) && !(e instanceof String) && !(e instanceof RegExp) && !(e instanceof ArrayBuffer) && !(e instanceof Promise), Et = (e, t) => {
1503
+ const s = De.get(e);
1504
1504
  if (s?.[0] === t)
1505
1505
  return s[1];
1506
1506
  const n = Array.isArray(e) ? [] : Object.create(Object.getPrototypeOf(e));
1507
- return xe(n, !0), ke.set(e, [t, n]), Reflect.ownKeys(e).forEach((r) => {
1507
+ return ke(n, !0), De.set(e, [t, n]), Reflect.ownKeys(e).forEach((r) => {
1508
1508
  if (Object.getOwnPropertyDescriptor(n, r))
1509
1509
  return;
1510
1510
  const i = Reflect.get(e, r), { enumerable: o } = Reflect.getOwnPropertyDescriptor(
@@ -1517,10 +1517,10 @@ const ee = Object.getPrototypeOf, te = /* @__PURE__ */ new WeakMap(), yt = (e) =
1517
1517
  // It's still non-writable, so it avoids assigning a value.
1518
1518
  configurable: !0
1519
1519
  };
1520
- if (ge.has(i))
1521
- xe(i, !1);
1522
- else if (I.has(i)) {
1523
- const [c, u] = I.get(
1520
+ if (me.has(i))
1521
+ ke(i, !1);
1522
+ else if (U.has(i)) {
1523
+ const [c, u] = U.get(
1524
1524
  i
1525
1525
  );
1526
1526
  a.value = Et(c, u());
@@ -1536,81 +1536,81 @@ const ee = Object.getPrototypeOf, te = /* @__PURE__ */ new WeakMap(), yt = (e) =
1536
1536
  },
1537
1537
  set(r, i, o, a) {
1538
1538
  const c = !e() && Reflect.has(r, i), u = Reflect.get(r, i, a);
1539
- if (c && (Oe(u, o) || z.has(o) && Oe(u, z.get(o))))
1539
+ if (c && (Oe(u, o) || j.has(o) && Oe(u, j.get(o))))
1540
1540
  return !0;
1541
- s(i), pe(o) && (o = fn(o) || o);
1542
- const l = !I.has(o) && mn(o) ? St(o) : o;
1543
- return t(i, l), Reflect.set(r, i, l, a), n(["set", [i], o, u]), !0;
1541
+ s(i), ge(o) && (o = fn(o) || o);
1542
+ const f = !U.has(o) && mn(o) ? St(o) : o;
1543
+ return t(i, f), Reflect.set(r, i, f, a), n(["set", [i], o, u]), !0;
1544
1544
  }
1545
- }), I = /* @__PURE__ */ new WeakMap(), ge = /* @__PURE__ */ new WeakSet(), ke = /* @__PURE__ */ new WeakMap(), Y = [1], z = /* @__PURE__ */ new WeakMap();
1545
+ }), U = /* @__PURE__ */ new WeakMap(), me = /* @__PURE__ */ new WeakSet(), De = /* @__PURE__ */ new WeakMap(), Y = [1], j = /* @__PURE__ */ new WeakMap();
1546
1546
  let Oe = Object.is, gn = (e, t) => new Proxy(e, t), mn = dn, yn = Et, wn = pn;
1547
1547
  function St(e = {}) {
1548
- if (!pe(e))
1548
+ if (!ge(e))
1549
1549
  throw new Error("object required");
1550
- const t = z.get(e);
1550
+ const t = j.get(e);
1551
1551
  if (t)
1552
1552
  return t;
1553
1553
  let s = Y[0];
1554
- const n = /* @__PURE__ */ new Set(), r = (f, p = ++Y[0]) => {
1555
- s !== p && (i = s = p, n.forEach((g) => g(f, p)));
1554
+ const n = /* @__PURE__ */ new Set(), r = (l, d = ++Y[0]) => {
1555
+ s !== d && (i = s = d, n.forEach((p) => p(l, d)));
1556
1556
  };
1557
1557
  let i = s;
1558
- const o = (f = Y[0]) => (i !== f && (i = f, c.forEach(([p]) => {
1559
- const g = p[1](f);
1560
- g > s && (s = g);
1561
- })), s), a = (f) => (p, g) => {
1562
- const b = [...p];
1563
- b[1] = [f, ...b[1]], r(b, g);
1564
- }, c = /* @__PURE__ */ new Map(), u = (f, p) => {
1565
- const g = !ge.has(p) && I.get(p);
1566
- if (g) {
1567
- if ((L ? "production" : void 0) !== "production" && c.has(f))
1558
+ const o = (l = Y[0]) => (i !== l && (i = l, c.forEach(([d]) => {
1559
+ const p = d[1](l);
1560
+ p > s && (s = p);
1561
+ })), s), a = (l) => (d, p) => {
1562
+ const b = [...d];
1563
+ b[1] = [l, ...b[1]], r(b, p);
1564
+ }, c = /* @__PURE__ */ new Map(), u = (l, d) => {
1565
+ const p = !me.has(d) && U.get(d);
1566
+ if (p) {
1567
+ if ((z ? "production" : void 0) !== "production" && c.has(l))
1568
1568
  throw new Error("prop listener already exists");
1569
1569
  if (n.size) {
1570
- const b = g[2](a(f));
1571
- c.set(f, [g, b]);
1570
+ const b = p[2](a(l));
1571
+ c.set(l, [p, b]);
1572
1572
  } else
1573
- c.set(f, [g]);
1573
+ c.set(l, [p]);
1574
1574
  }
1575
- }, l = (f) => {
1576
- var p;
1577
- const g = c.get(f);
1578
- g && (c.delete(f), (p = g[1]) == null || p.call(g));
1579
- }, w = (f) => (n.add(f), n.size === 1 && c.forEach(([g, b], D) => {
1580
- if ((L ? "production" : void 0) !== "production" && b)
1575
+ }, f = (l) => {
1576
+ var d;
1577
+ const p = c.get(l);
1578
+ p && (c.delete(l), (d = p[1]) == null || d.call(p));
1579
+ }, y = (l) => (n.add(l), n.size === 1 && c.forEach(([p, b], N) => {
1580
+ if ((z ? "production" : void 0) !== "production" && b)
1581
1581
  throw new Error("remove already exists");
1582
- const Rt = g[2](a(D));
1583
- c.set(D, [g, Rt]);
1582
+ const Rt = p[2](a(N));
1583
+ c.set(N, [p, Rt]);
1584
1584
  }), () => {
1585
- n.delete(f), n.size === 0 && c.forEach(([g, b], D) => {
1586
- b && (b(), c.set(D, [g]));
1585
+ n.delete(l), n.size === 0 && c.forEach(([p, b], N) => {
1586
+ b && (b(), c.set(N, [p]));
1587
1587
  });
1588
1588
  });
1589
- let d = !0;
1590
- const y = wn(
1591
- () => d,
1589
+ let g = !0;
1590
+ const w = wn(
1591
+ () => g,
1592
1592
  u,
1593
- l,
1593
+ f,
1594
1594
  r
1595
- ), T = gn(e, y);
1596
- z.set(e, T);
1597
- const q = [e, o, w];
1598
- return I.set(T, q), Reflect.ownKeys(e).forEach((f) => {
1599
- const p = Object.getOwnPropertyDescriptor(
1595
+ ), E = gn(e, w);
1596
+ j.set(e, E);
1597
+ const A = [e, o, y];
1598
+ return U.set(E, A), Reflect.ownKeys(e).forEach((l) => {
1599
+ const d = Object.getOwnPropertyDescriptor(
1600
1600
  e,
1601
- f
1601
+ l
1602
1602
  );
1603
- "value" in p && p.writable && (T[f] = e[f]);
1604
- }), d = !1, T;
1603
+ "value" in d && d.writable && (E[l] = e[l]);
1604
+ }), g = !1, E;
1605
1605
  }
1606
1606
  function bn(e, t, s) {
1607
- const n = I.get(e);
1608
- (L ? "production" : void 0) !== "production" && !n && console.warn("Please use proxy object");
1607
+ const n = U.get(e);
1608
+ (z ? "production" : void 0) !== "production" && !n && console.warn("Please use proxy object");
1609
1609
  let r;
1610
1610
  const i = [], o = n[2];
1611
1611
  let a = !1;
1612
- const u = o((l) => {
1613
- i.push(l), r || (r = Promise.resolve().then(() => {
1612
+ const u = o((f) => {
1613
+ i.push(f), r || (r = Promise.resolve().then(() => {
1614
1614
  r = void 0, a && t(i.splice(0));
1615
1615
  }));
1616
1616
  });
@@ -1618,23 +1618,23 @@ function bn(e, t, s) {
1618
1618
  a = !1, u();
1619
1619
  };
1620
1620
  }
1621
- function De(e) {
1622
- const t = I.get(e);
1623
- (L ? "production" : void 0) !== "production" && !t && console.warn("Please use proxy object");
1621
+ function Ne(e) {
1622
+ const t = U.get(e);
1623
+ (z ? "production" : void 0) !== "production" && !t && console.warn("Please use proxy object");
1624
1624
  const [s, n] = t;
1625
1625
  return yn(s, n());
1626
1626
  }
1627
1627
  const En = {}, Sn = (e, t) => {
1628
- const s = se(void 0);
1629
- ne(() => {
1628
+ const s = ne(void 0);
1629
+ re(() => {
1630
1630
  s.current = hn(e, t);
1631
1631
  }), Pt(s.current);
1632
1632
  }, Rn = Sn, Tn = /* @__PURE__ */ new WeakMap();
1633
1633
  function An(e, t) {
1634
- const n = me(
1634
+ const n = ye(
1635
1635
  () => e && /* @__PURE__ */ new WeakMap(),
1636
1636
  [e]
1637
- ), r = se(void 0);
1637
+ ), r = ne(void 0);
1638
1638
  let i = !0;
1639
1639
  const o = Tt(
1640
1640
  At(
@@ -1645,7 +1645,7 @@ function An(e, t) {
1645
1645
  [e, void 0]
1646
1646
  ),
1647
1647
  () => {
1648
- const c = De(e);
1648
+ const c = Ne(e);
1649
1649
  try {
1650
1650
  if (!i && r.current && !bt(
1651
1651
  r.current,
@@ -1658,15 +1658,15 @@ function An(e, t) {
1658
1658
  }
1659
1659
  return c;
1660
1660
  },
1661
- () => De(e)
1661
+ () => Ne(e)
1662
1662
  );
1663
1663
  i = !1, vt(() => {
1664
1664
  r.current = o;
1665
1665
  }), (En ? "production" : void 0) !== "production" && Rn(o, n);
1666
- const a = me(() => /* @__PURE__ */ new WeakMap(), []);
1666
+ const a = ye(() => /* @__PURE__ */ new WeakMap(), []);
1667
1667
  return wt(o, n, a, Tn);
1668
1668
  }
1669
- const v = St({
1669
+ const P = St({
1670
1670
  data: null,
1671
1671
  isPending: !1,
1672
1672
  error: null
@@ -1680,15 +1680,16 @@ function Cn({
1680
1680
  onCancel: i,
1681
1681
  onSuccess: o
1682
1682
  }) {
1683
- const a = An(v), [c, u] = Ne(!1);
1684
- function l() {
1683
+ const a = An(P), [c, u] = X(!1), [f, y] = X(Date.now());
1684
+ function g() {
1685
1685
  u(!0);
1686
1686
  }
1687
1687
  function w() {
1688
- u(!1), d();
1688
+ u(!1), E();
1689
1689
  }
1690
- const d = () => {
1691
- v.isPending = !0, v.error = null, fetch(e, {
1690
+ const E = () => {
1691
+ const A = Date.now();
1692
+ P.isPending = !0, P.error = null, fetch(e, {
1692
1693
  method: "POST",
1693
1694
  headers: {
1694
1695
  "Content-Type": "application/json"
@@ -1699,25 +1700,25 @@ function Cn({
1699
1700
  amount: n ? nn(n) : "0",
1700
1701
  recipient: r
1701
1702
  })
1702
- }).then((y) => y.json()).then((y) => {
1703
- v.data = y, h.config({
1704
- api_key: y.sessionToken
1705
- }), v.isPending = !1;
1706
- }).catch((y) => {
1707
- v.error = y?.toString(), v.isPending = !1;
1703
+ }).then((l) => l.json()).then((l) => {
1704
+ A < f || (P.data = l, h.config({
1705
+ api_key: l.sessionToken
1706
+ }), P.isPending = !1, y(A));
1707
+ }).catch((l) => {
1708
+ A < f || (P.error = l?.toString(), P.isPending = !1, y(A));
1708
1709
  });
1709
1710
  };
1710
- return ne(() => {
1711
- d();
1711
+ return re(() => {
1712
+ E();
1712
1713
  }, [t, s, n, r]), {
1713
1714
  ...a,
1714
1715
  destinationChain: t,
1715
1716
  token: s,
1716
1717
  recipient: r,
1717
1718
  isOpen: c,
1718
- open: l,
1719
+ open: g,
1719
1720
  close: w,
1720
- refetch: d,
1721
+ refetch: E,
1721
1722
  onSuccess: o,
1722
1723
  onCancel: i
1723
1724
  };
@@ -1725,7 +1726,7 @@ function Cn({
1725
1726
  export {
1726
1727
  h as Chainrails,
1727
1728
  Un as PaymentModal,
1728
- Z as chains,
1729
+ Q as chains,
1729
1730
  In as crapi,
1730
1731
  ht as tokens,
1731
1732
  Cn as usePaymentSession