@dogeos/dogeos-sdk 3.0.7-beta.1 → 3.0.7-beta.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.
- package/README.md +14 -2
- package/dist/dogeos-sdk.css +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1091 -1042
- package/package.json +4 -4
package/dist/index.js
CHANGED
|
@@ -1,14 +1,15 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import Ur from "
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
|
|
1
|
+
import './dogeos-sdk.css';
|
|
2
|
+
import { jsxs as C, jsx as i, Fragment as ot } from "react/jsx-runtime";
|
|
3
|
+
import { createContext as zr, useState as N, useRef as ce, useEffect as Y, useMemo as B, useContext as V, useCallback as T } from "react";
|
|
4
|
+
import { Button as X, BackIcon as ct, CloseIcon as at, OkIcon as lt, CopyIcon as wr, Image as ne, PowerIcon as Ir, DownIcon as Pr, Spinner as te, Skeleton as Br, Modal as At, Link as Ee, TomoLogoIcon as yr, Card as hr, CardBody as Mr, Tabs as Wr, Tab as Vr, Chip as Ln, SearchIcon as Xr, Input as bn, SearchOutlinedIcon as Nr, addToast as jr, RightArrowIcon as zn, ModalHeader as Tr, ModalBody as Er, ModalContent as Lr, TomoUIProvider as Sr, ToastProvider as Or } from "@tomo-inc/tomo-ui";
|
|
5
|
+
import { isMobile as on, metaMaskWallet as Yr, phantomWallet as Zr, coinbaseWallet as kr, binanceWallet as Jr, walletConnectWallet as Fr, loadConnectors as Dr, ProviderProtocol as Sn, connect as Hr, switchChain as On, addChain as Qr, signMessage as qr, signInWithWallet as Kr, setWalletConnectConfig as Gr } from "@tomo-inc/wallet-adaptor-base";
|
|
6
|
+
import { useMutation as wn, useQuery as Ur, QueryClientProvider as Rr, QueryClient as _r } from "@tanstack/react-query";
|
|
7
|
+
import $r from "copy-to-clipboard";
|
|
8
|
+
import es from "qr-code-styling";
|
|
9
|
+
import { EmbeddedWallet as ns } from "@tomo-inc/embedded-wallet-providers";
|
|
10
|
+
import { useConfig as Yn, useConnect as ts, useDisconnect as rs, useAccount as ss, createConnector as is } from "wagmi";
|
|
11
|
+
import { getAddress as Me, SwitchChainError as Zn, numberToHex as kn, UserRejectedRequestError as F, withRetry as os, withTimeout as cs, ResourceUnavailableRpcError as Ue } from "viem";
|
|
12
|
+
const W = zr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ C(
|
|
12
13
|
"svg",
|
|
13
14
|
{
|
|
14
15
|
"aria-hidden": "true",
|
|
@@ -41,8 +42,8 @@ const M = xr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ v(
|
|
|
41
42
|
fillOpacity: "0.3"
|
|
42
43
|
}
|
|
43
44
|
),
|
|
44
|
-
/* @__PURE__ */
|
|
45
|
-
/* @__PURE__ */
|
|
45
|
+
/* @__PURE__ */ C("defs", { children: [
|
|
46
|
+
/* @__PURE__ */ C(
|
|
46
47
|
"linearGradient",
|
|
47
48
|
{
|
|
48
49
|
id: "paint0_linear_3546_7073",
|
|
@@ -57,7 +58,7 @@ const M = xr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ v(
|
|
|
57
58
|
]
|
|
58
59
|
}
|
|
59
60
|
),
|
|
60
|
-
/* @__PURE__ */
|
|
61
|
+
/* @__PURE__ */ C(
|
|
61
62
|
"linearGradient",
|
|
62
63
|
{
|
|
63
64
|
id: "paint1_linear_3546_7073",
|
|
@@ -75,9 +76,9 @@ const M = xr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ v(
|
|
|
75
76
|
] })
|
|
76
77
|
]
|
|
77
78
|
}
|
|
78
|
-
), ft = ({ ...e }) => /* @__PURE__ */ i(dt, { testnet: !0, ...e }),
|
|
79
|
+
), ft = ({ ...e }) => /* @__PURE__ */ i(dt, { testnet: !0, ...e }), Le = ({ testnet: e, ...n }) => {
|
|
79
80
|
let t = "var(--ck-chain-ethereum-01, #627EEA)", r = "var(--ck-chain-ethereum-02, #ffffff)";
|
|
80
|
-
return e && (t = "linear-gradient(180deg, #8995A9 0%, #627EEA 99.48%)", r = "#fff"), /* @__PURE__ */
|
|
81
|
+
return e && (t = "linear-gradient(180deg, #8995A9 0%, #627EEA 99.48%)", r = "#fff"), /* @__PURE__ */ C(
|
|
81
82
|
"svg",
|
|
82
83
|
{
|
|
83
84
|
"aria-hidden": "true",
|
|
@@ -128,7 +129,7 @@ const M = xr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ v(
|
|
|
128
129
|
}
|
|
129
130
|
)
|
|
130
131
|
}
|
|
131
|
-
), gt = ({ testnet: e, ...n }) => /* @__PURE__ */
|
|
132
|
+
), gt = ({ testnet: e, ...n }) => /* @__PURE__ */ C(
|
|
132
133
|
"svg",
|
|
133
134
|
{
|
|
134
135
|
"aria-hidden": "true",
|
|
@@ -175,7 +176,7 @@ const M = xr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ v(
|
|
|
175
176
|
}
|
|
176
177
|
), vt = ({ testnet: e, ...n }) => {
|
|
177
178
|
const t = e ? "#ffffff" : "#28A0F0";
|
|
178
|
-
return /* @__PURE__ */
|
|
179
|
+
return /* @__PURE__ */ C(
|
|
179
180
|
"svg",
|
|
180
181
|
{
|
|
181
182
|
"aria-hidden": "true",
|
|
@@ -228,7 +229,7 @@ const M = xr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ v(
|
|
|
228
229
|
]
|
|
229
230
|
}
|
|
230
231
|
);
|
|
231
|
-
}, Ct = ({ testnet: e, ...n }) => /* @__PURE__ */
|
|
232
|
+
}, Ct = ({ testnet: e, ...n }) => /* @__PURE__ */ C(
|
|
232
233
|
"svg",
|
|
233
234
|
{
|
|
234
235
|
"aria-hidden": "true",
|
|
@@ -299,9 +300,9 @@ const M = xr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ v(
|
|
|
299
300
|
}
|
|
300
301
|
)
|
|
301
302
|
}
|
|
302
|
-
), xt = ({ ...e }) => /* @__PURE__ */
|
|
303
|
+
), xt = ({ ...e }) => /* @__PURE__ */ C("svg", { width: "200", height: "208", viewBox: "0 0 200 208", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: [
|
|
303
304
|
/* @__PURE__ */ i("rect", { width: "199.4", height: "207.623", fill: "#121212" }),
|
|
304
|
-
/* @__PURE__ */
|
|
305
|
+
/* @__PURE__ */ C("g", { clipPath: "url(#clip0_2318_291)", children: [
|
|
305
306
|
/* @__PURE__ */ i("path", { d: "M132.369 155.99H49.7001V68.8854H68.6148V139.109H132.369V155.981V155.99Z", fill: "#fff" }),
|
|
306
307
|
/* @__PURE__ */ i(
|
|
307
308
|
"path",
|
|
@@ -312,7 +313,7 @@ const M = xr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ v(
|
|
|
312
313
|
)
|
|
313
314
|
] }),
|
|
314
315
|
/* @__PURE__ */ i("defs", { children: /* @__PURE__ */ i("clipPath", { id: "clip0_2318_291", children: /* @__PURE__ */ i("rect", { width: "99.5407", height: "103.977", fill: "white", transform: "translate(49.7001 52.0134)" }) }) })
|
|
315
|
-
] }),
|
|
316
|
+
] }), Je = ({ ...e }) => /* @__PURE__ */ C("svg", { width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: [
|
|
316
317
|
/* @__PURE__ */ i(
|
|
317
318
|
"path",
|
|
318
319
|
{
|
|
@@ -327,8 +328,8 @@ const M = xr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ v(
|
|
|
327
328
|
fill: "white"
|
|
328
329
|
}
|
|
329
330
|
)
|
|
330
|
-
] }),
|
|
331
|
-
/* @__PURE__ */
|
|
331
|
+
] }), Fe = ({ ...e }) => /* @__PURE__ */ C("svg", { width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: [
|
|
332
|
+
/* @__PURE__ */ C("g", { clipPath: "url(#clip0_101_1146)", children: [
|
|
332
333
|
/* @__PURE__ */ i(
|
|
333
334
|
"path",
|
|
334
335
|
{
|
|
@@ -336,7 +337,7 @@ const M = xr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ v(
|
|
|
336
337
|
fill: "black"
|
|
337
338
|
}
|
|
338
339
|
),
|
|
339
|
-
/* @__PURE__ */
|
|
340
|
+
/* @__PURE__ */ C("g", { clipPath: "url(#clip1_101_1146)", children: [
|
|
340
341
|
/* @__PURE__ */ i(
|
|
341
342
|
"path",
|
|
342
343
|
{
|
|
@@ -360,8 +361,8 @@ const M = xr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ v(
|
|
|
360
361
|
)
|
|
361
362
|
] })
|
|
362
363
|
] }),
|
|
363
|
-
/* @__PURE__ */
|
|
364
|
-
/* @__PURE__ */
|
|
364
|
+
/* @__PURE__ */ C("defs", { children: [
|
|
365
|
+
/* @__PURE__ */ C(
|
|
365
366
|
"linearGradient",
|
|
366
367
|
{
|
|
367
368
|
id: "paint0_linear_101_1146",
|
|
@@ -376,7 +377,7 @@ const M = xr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ v(
|
|
|
376
377
|
]
|
|
377
378
|
}
|
|
378
379
|
),
|
|
379
|
-
/* @__PURE__ */
|
|
380
|
+
/* @__PURE__ */ C(
|
|
380
381
|
"linearGradient",
|
|
381
382
|
{
|
|
382
383
|
id: "paint1_linear_101_1146",
|
|
@@ -391,7 +392,7 @@ const M = xr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ v(
|
|
|
391
392
|
]
|
|
392
393
|
}
|
|
393
394
|
),
|
|
394
|
-
/* @__PURE__ */
|
|
395
|
+
/* @__PURE__ */ C(
|
|
395
396
|
"linearGradient",
|
|
396
397
|
{
|
|
397
398
|
id: "paint2_linear_101_1146",
|
|
@@ -409,7 +410,7 @@ const M = xr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ v(
|
|
|
409
410
|
/* @__PURE__ */ i("clipPath", { id: "clip0_101_1146", children: /* @__PURE__ */ i("rect", { width: "20", height: "20", fill: "white" }) }),
|
|
410
411
|
/* @__PURE__ */ i("clipPath", { id: "clip1_101_1146", children: /* @__PURE__ */ i("rect", { width: "13.125", height: "10", fill: "white", transform: "translate(3.75 5)" }) })
|
|
411
412
|
] })
|
|
412
|
-
] }),
|
|
413
|
+
] }), as = ({ ...e }) => /* @__PURE__ */ C("svg", { width: "32", height: "32", viewBox: "0 0 32 32", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: [
|
|
413
414
|
/* @__PURE__ */ i("circle", { cx: "16", cy: "16", r: "16", fill: "black" }),
|
|
414
415
|
/* @__PURE__ */ i(
|
|
415
416
|
"mask",
|
|
@@ -431,7 +432,7 @@ const M = xr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ v(
|
|
|
431
432
|
fill: "#FFDA34"
|
|
432
433
|
}
|
|
433
434
|
) })
|
|
434
|
-
] }), pt = ({ ...e }) => /* @__PURE__ */
|
|
435
|
+
] }), pt = ({ ...e }) => /* @__PURE__ */ C(
|
|
435
436
|
"svg",
|
|
436
437
|
{
|
|
437
438
|
width: "36",
|
|
@@ -464,7 +465,7 @@ const M = xr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ v(
|
|
|
464
465
|
fillOpacity: "0.8"
|
|
465
466
|
}
|
|
466
467
|
),
|
|
467
|
-
/* @__PURE__ */
|
|
468
|
+
/* @__PURE__ */ C("defs", { children: [
|
|
468
469
|
/* @__PURE__ */ i("pattern", { id: "pattern0_5204_7902", patternContentUnits: "objectBoundingBox", width: "1", height: "1", children: /* @__PURE__ */ i("use", { xlinkHref: "#image0_5204_7902", transform: "translate(-0.4375 -0.125) scale(0.0015625)" }) }),
|
|
469
470
|
/* @__PURE__ */ i(
|
|
470
471
|
"image",
|
|
@@ -479,7 +480,7 @@ const M = xr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ v(
|
|
|
479
480
|
] })
|
|
480
481
|
]
|
|
481
482
|
}
|
|
482
|
-
), bt = ({ ...e }) => /* @__PURE__ */
|
|
483
|
+
), bt = ({ ...e }) => /* @__PURE__ */ C("svg", { width: "56", height: "56", viewBox: "0 0 56 56", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e, children: [
|
|
483
484
|
/* @__PURE__ */ i("foreignObject", { x: "-2.16759", y: "-2.16759", width: "60.3349", height: "60.3352", children: /* @__PURE__ */ i(
|
|
484
485
|
"div",
|
|
485
486
|
{
|
|
@@ -491,7 +492,7 @@ const M = xr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ v(
|
|
|
491
492
|
}
|
|
492
493
|
}
|
|
493
494
|
) }),
|
|
494
|
-
/* @__PURE__ */
|
|
495
|
+
/* @__PURE__ */ C("g", { "data-figma-bg-blur-radius": "2.16759", children: [
|
|
495
496
|
/* @__PURE__ */ i("circle", { cx: "27.9999", cy: "27.9999", r: "27.6817", fill: "#313036", fillOpacity: "0.3" }),
|
|
496
497
|
/* @__PURE__ */ i("circle", { cx: "27.9999", cy: "27.9999", r: "27.6817", fill: "url(#paint0_linear_750_175)" }),
|
|
497
498
|
/* @__PURE__ */ i("circle", { cx: "27.9999", cy: "27.9999", r: "27.6817", stroke: "url(#paint1_linear_750_175)", strokeWidth: "0.636361" })
|
|
@@ -507,9 +508,9 @@ const M = xr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ v(
|
|
|
507
508
|
) }),
|
|
508
509
|
/* @__PURE__ */ i("path", { d: "M27.9999 32.1357V32.613", stroke: "#44444F", strokeWidth: "1.90908", strokeLinecap: "round" }),
|
|
509
510
|
/* @__PURE__ */ i("path", { d: "M27.9999 24.5L28.0038 29.2725", stroke: "#44444F", strokeWidth: "1.90908", strokeLinecap: "round" }),
|
|
510
|
-
/* @__PURE__ */
|
|
511
|
+
/* @__PURE__ */ C("defs", { children: [
|
|
511
512
|
/* @__PURE__ */ i("clipPath", { id: "bgblur_0_750_175_clip_path", transform: "translate(2.16759 2.16759)", children: /* @__PURE__ */ i("circle", { cx: "27.9999", cy: "27.9999", r: "27.6817" }) }),
|
|
512
|
-
/* @__PURE__ */
|
|
513
|
+
/* @__PURE__ */ C(
|
|
513
514
|
"filter",
|
|
514
515
|
{
|
|
515
516
|
id: "filter1_ii_750_175",
|
|
@@ -551,7 +552,7 @@ const M = xr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ v(
|
|
|
551
552
|
]
|
|
552
553
|
}
|
|
553
554
|
),
|
|
554
|
-
/* @__PURE__ */
|
|
555
|
+
/* @__PURE__ */ C(
|
|
555
556
|
"linearGradient",
|
|
556
557
|
{
|
|
557
558
|
id: "paint0_linear_750_175",
|
|
@@ -566,7 +567,7 @@ const M = xr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ v(
|
|
|
566
567
|
]
|
|
567
568
|
}
|
|
568
569
|
),
|
|
569
|
-
/* @__PURE__ */
|
|
570
|
+
/* @__PURE__ */ C(
|
|
570
571
|
"linearGradient",
|
|
571
572
|
{
|
|
572
573
|
id: "paint1_linear_750_175",
|
|
@@ -581,7 +582,7 @@ const M = xr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ v(
|
|
|
581
582
|
]
|
|
582
583
|
}
|
|
583
584
|
),
|
|
584
|
-
/* @__PURE__ */
|
|
585
|
+
/* @__PURE__ */ C(
|
|
585
586
|
"linearGradient",
|
|
586
587
|
{
|
|
587
588
|
id: "paint2_linear_750_175",
|
|
@@ -597,37 +598,37 @@ const M = xr(null), dt = ({ testnet: e, ...n }) => /* @__PURE__ */ v(
|
|
|
597
598
|
}
|
|
598
599
|
)
|
|
599
600
|
] })
|
|
600
|
-
] }),
|
|
601
|
+
] }), ls = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
601
602
|
__proto__: null,
|
|
602
|
-
Apots:
|
|
603
|
+
Apots: Je,
|
|
603
604
|
Arbitrum: vt,
|
|
604
605
|
Base: mt,
|
|
605
606
|
BinanceSmartChain: Ct,
|
|
606
607
|
Doge: pt,
|
|
607
|
-
Ethereum:
|
|
608
|
+
Ethereum: Le,
|
|
608
609
|
KnownChain: dt,
|
|
609
610
|
Linea: xt,
|
|
610
|
-
Movement:
|
|
611
|
+
Movement: as,
|
|
611
612
|
Optimism: gt,
|
|
612
613
|
Polygon: ut,
|
|
613
|
-
Solana:
|
|
614
|
+
Solana: Fe,
|
|
614
615
|
UnknownChain: ft,
|
|
615
616
|
UnsupportChain: bt
|
|
616
617
|
}, Symbol.toStringTag, { value: "Module" })), le = ({ icon: e, iconName: n, className: t, iconProps: r }) => {
|
|
617
|
-
const s = e ||
|
|
618
|
-
return /* @__PURE__ */
|
|
618
|
+
const s = e || ls?.[n] || ft;
|
|
619
|
+
return /* @__PURE__ */ C("div", { className: t, children: [
|
|
619
620
|
/* @__PURE__ */ i(s, { "data-icon": "chain-icon", width: "100%", height: "100%", ...r }),
|
|
620
621
|
";"
|
|
621
622
|
] });
|
|
622
623
|
}, In = () => {
|
|
623
624
|
const [e, n] = N(!1), t = ce(null), r = (s) => {
|
|
624
625
|
try {
|
|
625
|
-
return
|
|
626
|
+
return $r(s), n(!0), t.current = setTimeout(() => n(!1), 1200), !0;
|
|
626
627
|
} catch (o) {
|
|
627
628
|
return console.warn("Copy failed, but continuing execution:", o), !1;
|
|
628
629
|
}
|
|
629
630
|
};
|
|
630
|
-
return
|
|
631
|
+
return Y(
|
|
631
632
|
() => () => {
|
|
632
633
|
t.current && (clearTimeout(t.current), t.current = null);
|
|
633
634
|
},
|
|
@@ -646,12 +647,12 @@ function zt(e) {
|
|
|
646
647
|
const r = e.split("@")[0];
|
|
647
648
|
return !(r.startsWith(".") || r.endsWith(".") || r.includes(".."));
|
|
648
649
|
}
|
|
649
|
-
function
|
|
650
|
+
function As(e) {
|
|
650
651
|
return !e || e.trim().length === 0 ? "Please enter your email address" : zt(e) ? null : "Please enter a valid email address";
|
|
651
652
|
}
|
|
652
653
|
const Pn = {
|
|
653
654
|
WALLET_STATE: "tomo_wallet_state"
|
|
654
|
-
},
|
|
655
|
+
}, ds = (e) => {
|
|
655
656
|
try {
|
|
656
657
|
const n = {
|
|
657
658
|
...e,
|
|
@@ -661,7 +662,7 @@ const Pn = {
|
|
|
661
662
|
} catch (n) {
|
|
662
663
|
console.error("Failed to save wallet state:", n);
|
|
663
664
|
}
|
|
664
|
-
},
|
|
665
|
+
}, fs = () => {
|
|
665
666
|
try {
|
|
666
667
|
const e = localStorage.getItem(Pn.WALLET_STATE);
|
|
667
668
|
if (!e) return null;
|
|
@@ -681,14 +682,14 @@ function Jn(e, n) {
|
|
|
681
682
|
const t = e.info?.uuid, r = t ? n.has(t) : !1, s = e.isInstalled === !0;
|
|
682
683
|
return r && s ? 0 : !r && s ? 1 : r && !s ? 2 : 3;
|
|
683
684
|
}
|
|
684
|
-
function
|
|
685
|
+
function us(e, n) {
|
|
685
686
|
const t = new Set(e.map((a) => a.info?.uuid).filter(Boolean)), r = (a, l) => Jn(a, t) - Jn(l, t), s = /* @__PURE__ */ new Set();
|
|
686
687
|
return [[...e, ...n].filter((a) => {
|
|
687
688
|
const l = a.info?.uuid;
|
|
688
689
|
return !l || s.has(l) ? !1 : (s.add(l), !0);
|
|
689
690
|
}).sort(r), n];
|
|
690
691
|
}
|
|
691
|
-
function
|
|
692
|
+
function gs(e, n = 6, t = 4) {
|
|
692
693
|
if (!e) return "";
|
|
693
694
|
if (e.length <= n + t)
|
|
694
695
|
return e;
|
|
@@ -702,26 +703,26 @@ const O = {
|
|
|
702
703
|
},
|
|
703
704
|
aptos: {
|
|
704
705
|
name: "Aptos",
|
|
705
|
-
icon:
|
|
706
|
+
icon: Je
|
|
706
707
|
},
|
|
707
708
|
evm: {
|
|
708
709
|
name: "EVM(Ethereum)",
|
|
709
|
-
icon:
|
|
710
|
+
icon: Le
|
|
710
711
|
},
|
|
711
712
|
solana: {
|
|
712
713
|
name: "Solana",
|
|
713
|
-
icon:
|
|
714
|
+
icon: Fe
|
|
714
715
|
},
|
|
715
716
|
dogecoin: {
|
|
716
717
|
name: "Dogecoin",
|
|
717
718
|
icon: pt
|
|
718
719
|
}
|
|
719
720
|
}, It = {
|
|
720
|
-
aptos:
|
|
721
|
-
solana:
|
|
722
|
-
evm:
|
|
721
|
+
aptos: Je,
|
|
722
|
+
solana: Fe,
|
|
723
|
+
evm: Le,
|
|
723
724
|
// Evm chains
|
|
724
|
-
evm_1:
|
|
725
|
+
evm_1: Le,
|
|
725
726
|
evm_10: gt,
|
|
726
727
|
evm_56: Ct,
|
|
727
728
|
evm_137: ut,
|
|
@@ -751,7 +752,7 @@ const Pt = "2.38.2";
|
|
|
751
752
|
let _e = {
|
|
752
753
|
getDocsUrl: ({ docsBaseUrl: e, docsPath: n = "", docsSlug: t }) => n ? `${e ?? "https://viem.sh"}${n}${t ? `#${t}` : ""}` : void 0,
|
|
753
754
|
version: `viem@${Pt}`
|
|
754
|
-
},
|
|
755
|
+
}, h = class an extends Error {
|
|
755
756
|
constructor(n, t = {}) {
|
|
756
757
|
const r = t.cause instanceof an ? t.cause.details : t.cause?.message ? t.cause.message : t.details, s = t.cause instanceof an && t.cause.docsPath || t.docsPath, o = _e.getDocsUrl?.({ ...t, docsPath: s }), c = [
|
|
757
758
|
n || "An error occurred.",
|
|
@@ -801,42 +802,42 @@ let _e = {
|
|
|
801
802
|
function Bt(e, n) {
|
|
802
803
|
return n?.(e) ? e : e && typeof e == "object" && "cause" in e && e.cause !== void 0 ? Bt(e.cause, n) : n ? null : e;
|
|
803
804
|
}
|
|
804
|
-
class
|
|
805
|
+
class vs extends h {
|
|
805
806
|
constructor({ max: n, min: t, signed: r, size: s, value: o }) {
|
|
806
807
|
super(`Number "${o}" is not in safe ${s ? `${s * 8}-bit ${r ? "signed" : "unsigned"} ` : ""}integer range ${n ? `(${t} to ${n})` : `(above ${t})`}`, { name: "IntegerOutOfRangeError" });
|
|
807
808
|
}
|
|
808
809
|
}
|
|
809
|
-
class
|
|
810
|
+
class Cs extends h {
|
|
810
811
|
constructor({ givenSize: n, maxSize: t }) {
|
|
811
812
|
super(`Size cannot exceed ${t} bytes. Given size: ${n} bytes.`, { name: "SizeOverflowError" });
|
|
812
813
|
}
|
|
813
814
|
}
|
|
814
|
-
function
|
|
815
|
+
function Ie(e, { strict: n = !0 } = {}) {
|
|
815
816
|
return !e || typeof e != "string" ? !1 : n ? /^0x[0-9a-fA-F]*$/.test(e) : e.startsWith("0x");
|
|
816
817
|
}
|
|
817
818
|
function ae(e) {
|
|
818
|
-
return
|
|
819
|
+
return Ie(e, { strict: !1 }) ? Math.ceil((e.length - 2) / 2) : e.length;
|
|
819
820
|
}
|
|
820
|
-
function
|
|
821
|
+
function Se(e, { dir: n = "left" } = {}) {
|
|
821
822
|
let t = typeof e == "string" ? e.replace("0x", "") : e, r = 0;
|
|
822
823
|
for (let s = 0; s < t.length - 1 && t[n === "left" ? s : t.length - s - 1].toString() === "0"; s++)
|
|
823
824
|
r++;
|
|
824
825
|
return t = n === "left" ? t.slice(r) : t.slice(0, t.length - r), typeof e == "string" ? (t.length === 1 && n === "right" && (t = `${t}0`), `0x${t.length % 2 === 1 ? `0${t}` : t}`) : t;
|
|
825
826
|
}
|
|
826
|
-
class
|
|
827
|
+
class ms extends h {
|
|
827
828
|
constructor({ offset: n, position: t, size: r }) {
|
|
828
829
|
super(`Slice ${t === "start" ? "starting" : "ending"} at offset "${n}" is out-of-bounds (size: ${r}).`, { name: "SliceOffsetOutOfBoundsError" });
|
|
829
830
|
}
|
|
830
831
|
}
|
|
831
|
-
class yt extends
|
|
832
|
+
class yt extends h {
|
|
832
833
|
constructor({ size: n, targetSize: t, type: r }) {
|
|
833
834
|
super(`${r.charAt(0).toUpperCase()}${r.slice(1).toLowerCase()} size (${n}) exceeds padding size (${t}).`, { name: "SizeExceedsPaddingSizeError" });
|
|
834
835
|
}
|
|
835
836
|
}
|
|
836
837
|
function Ae(e, { dir: n, size: t = 32 } = {}) {
|
|
837
|
-
return typeof e == "string" ?
|
|
838
|
+
return typeof e == "string" ? xs(e, { dir: n, size: t }) : ps(e, { dir: n, size: t });
|
|
838
839
|
}
|
|
839
|
-
function
|
|
840
|
+
function xs(e, { dir: n, size: t = 32 } = {}) {
|
|
840
841
|
if (t === null)
|
|
841
842
|
return e;
|
|
842
843
|
const r = e.replace("0x", "");
|
|
@@ -848,7 +849,7 @@ function vs(e, { dir: n, size: t = 32 } = {}) {
|
|
|
848
849
|
});
|
|
849
850
|
return `0x${r[n === "right" ? "padEnd" : "padStart"](t * 2, "0")}`;
|
|
850
851
|
}
|
|
851
|
-
function
|
|
852
|
+
function ps(e, { dir: n, size: t = 32 } = {}) {
|
|
852
853
|
if (t === null)
|
|
853
854
|
return e;
|
|
854
855
|
if (e.length > t)
|
|
@@ -864,18 +865,18 @@ function Cs(e, { dir: n, size: t = 32 } = {}) {
|
|
|
864
865
|
}
|
|
865
866
|
return r;
|
|
866
867
|
}
|
|
867
|
-
const
|
|
868
|
-
function
|
|
869
|
-
return typeof e == "number" || typeof e == "bigint" ? z(e, n) : typeof e == "string" ?
|
|
868
|
+
const bs = /* @__PURE__ */ Array.from({ length: 256 }, (e, n) => n.toString(16).padStart(2, "0"));
|
|
869
|
+
function me(e, n = {}) {
|
|
870
|
+
return typeof e == "number" || typeof e == "bigint" ? z(e, n) : typeof e == "string" ? Is(e, n) : typeof e == "boolean" ? zs(e, n) : q(e, n);
|
|
870
871
|
}
|
|
871
|
-
function
|
|
872
|
+
function zs(e, n = {}) {
|
|
872
873
|
const t = `0x${Number(e)}`;
|
|
873
874
|
return typeof n.size == "number" ? (de(t, { size: n.size }), Ae(t, { size: n.size })) : t;
|
|
874
875
|
}
|
|
875
876
|
function q(e, n = {}) {
|
|
876
877
|
let t = "";
|
|
877
878
|
for (let s = 0; s < e.length; s++)
|
|
878
|
-
t +=
|
|
879
|
+
t += bs[e[s]];
|
|
879
880
|
const r = `0x${t}`;
|
|
880
881
|
return typeof n.size == "number" ? (de(r, { size: n.size }), Ae(r, { dir: "right", size: n.size })) : r;
|
|
881
882
|
}
|
|
@@ -886,7 +887,7 @@ function z(e, n = {}) {
|
|
|
886
887
|
const c = typeof o == "bigint" && t ? -o - 1n : 0;
|
|
887
888
|
if (o && s > o || s < c) {
|
|
888
889
|
const l = typeof e == "bigint" ? "n" : "";
|
|
889
|
-
throw new
|
|
890
|
+
throw new vs({
|
|
890
891
|
max: o ? `${o}${l}` : void 0,
|
|
891
892
|
min: `${c}${l}`,
|
|
892
893
|
signed: t,
|
|
@@ -897,16 +898,16 @@ function z(e, n = {}) {
|
|
|
897
898
|
const a = `0x${(t && s < 0 ? (1n << BigInt(r * 8)) + BigInt(s) : s).toString(16)}`;
|
|
898
899
|
return r ? Ae(a, { size: r }) : a;
|
|
899
900
|
}
|
|
900
|
-
const
|
|
901
|
-
function
|
|
902
|
-
const t =
|
|
901
|
+
const ws = /* @__PURE__ */ new TextEncoder();
|
|
902
|
+
function Is(e, n = {}) {
|
|
903
|
+
const t = ws.encode(e);
|
|
903
904
|
return q(t, n);
|
|
904
905
|
}
|
|
905
|
-
const
|
|
906
|
+
const Ps = /* @__PURE__ */ new TextEncoder();
|
|
906
907
|
function ht(e, n = {}) {
|
|
907
|
-
return typeof e == "number" || typeof e == "bigint" ?
|
|
908
|
+
return typeof e == "number" || typeof e == "bigint" ? ys(e, n) : typeof e == "boolean" ? Bs(e, n) : Ie(e) ? _(e, n) : Mt(e, n);
|
|
908
909
|
}
|
|
909
|
-
function
|
|
910
|
+
function Bs(e, n = {}) {
|
|
910
911
|
const t = new Uint8Array(1);
|
|
911
912
|
return t[0] = Number(e), typeof n.size == "number" ? (de(t, { size: n.size }), Ae(t, { size: n.size })) : t;
|
|
912
913
|
}
|
|
@@ -935,22 +936,22 @@ function _(e, n = {}) {
|
|
|
935
936
|
for (let c = 0, a = 0; c < s; c++) {
|
|
936
937
|
const l = Fn(r.charCodeAt(a++)), A = Fn(r.charCodeAt(a++));
|
|
937
938
|
if (l === void 0 || A === void 0)
|
|
938
|
-
throw new
|
|
939
|
+
throw new h(`Invalid byte sequence ("${r[a - 2]}${r[a - 1]}" in "${r}").`);
|
|
939
940
|
o[c] = l * 16 + A;
|
|
940
941
|
}
|
|
941
942
|
return o;
|
|
942
943
|
}
|
|
943
|
-
function
|
|
944
|
+
function ys(e, n) {
|
|
944
945
|
const t = z(e, n);
|
|
945
946
|
return _(t);
|
|
946
947
|
}
|
|
947
948
|
function Mt(e, n = {}) {
|
|
948
|
-
const t =
|
|
949
|
+
const t = Ps.encode(e);
|
|
949
950
|
return typeof n.size == "number" ? (de(t, { size: n.size }), Ae(t, { dir: "right", size: n.size })) : t;
|
|
950
951
|
}
|
|
951
952
|
function de(e, { size: n }) {
|
|
952
953
|
if (ae(e) > n)
|
|
953
|
-
throw new
|
|
954
|
+
throw new Cs({
|
|
954
955
|
givenSize: ae(e),
|
|
955
956
|
maxSize: n
|
|
956
957
|
});
|
|
@@ -964,7 +965,7 @@ function se(e, n = {}) {
|
|
|
964
965
|
const s = (e.length - 2) / 2, o = (1n << BigInt(s) * 8n - 1n) - 1n;
|
|
965
966
|
return r <= o ? r : r - BigInt(`0x${"f".padStart(s * 2, "f")}`) - 1n;
|
|
966
967
|
}
|
|
967
|
-
function
|
|
968
|
+
function Oe(e, n = {}) {
|
|
968
969
|
return Number(se(e, n));
|
|
969
970
|
}
|
|
970
971
|
function Bn(e, n) {
|
|
@@ -995,13 +996,13 @@ function yn(e, n) {
|
|
|
995
996
|
...e,
|
|
996
997
|
blockHash: e.blockHash ? e.blockHash : null,
|
|
997
998
|
blockNumber: e.blockNumber ? BigInt(e.blockNumber) : null,
|
|
998
|
-
chainId: e.chainId ?
|
|
999
|
+
chainId: e.chainId ? Oe(e.chainId) : void 0,
|
|
999
1000
|
gas: e.gas ? BigInt(e.gas) : void 0,
|
|
1000
1001
|
gasPrice: e.gasPrice ? BigInt(e.gasPrice) : void 0,
|
|
1001
1002
|
maxFeePerBlobGas: e.maxFeePerBlobGas ? BigInt(e.maxFeePerBlobGas) : void 0,
|
|
1002
1003
|
maxFeePerGas: e.maxFeePerGas ? BigInt(e.maxFeePerGas) : void 0,
|
|
1003
1004
|
maxPriorityFeePerGas: e.maxPriorityFeePerGas ? BigInt(e.maxPriorityFeePerGas) : void 0,
|
|
1004
|
-
nonce: e.nonce ?
|
|
1005
|
+
nonce: e.nonce ? Oe(e.nonce) : void 0,
|
|
1005
1006
|
to: e.to ? e.to : null,
|
|
1006
1007
|
transactionIndex: e.transactionIndex ? Number(e.transactionIndex) : null,
|
|
1007
1008
|
type: e.type ? Wt[e.type] : void 0,
|
|
@@ -1009,7 +1010,7 @@ function yn(e, n) {
|
|
|
1009
1010
|
value: e.value ? BigInt(e.value) : void 0,
|
|
1010
1011
|
v: e.v ? BigInt(e.v) : void 0
|
|
1011
1012
|
};
|
|
1012
|
-
return e.authorizationList && (t.authorizationList =
|
|
1013
|
+
return e.authorizationList && (t.authorizationList = Ms(e.authorizationList)), t.yParity = (() => {
|
|
1013
1014
|
if (e.yParity)
|
|
1014
1015
|
return Number(e.yParity);
|
|
1015
1016
|
if (typeof t.v == "bigint") {
|
|
@@ -1022,8 +1023,8 @@ function yn(e, n) {
|
|
|
1022
1023
|
}
|
|
1023
1024
|
})(), t.type === "legacy" && (delete t.accessList, delete t.maxFeePerBlobGas, delete t.maxFeePerGas, delete t.maxPriorityFeePerGas, delete t.yParity), t.type === "eip2930" && (delete t.maxFeePerBlobGas, delete t.maxFeePerGas, delete t.maxPriorityFeePerGas), t.type === "eip1559" && delete t.maxFeePerBlobGas, t;
|
|
1024
1025
|
}
|
|
1025
|
-
const
|
|
1026
|
-
function
|
|
1026
|
+
const hs = /* @__PURE__ */ Bn("transaction", yn);
|
|
1027
|
+
function Ms(e) {
|
|
1027
1028
|
return e.map((n) => ({
|
|
1028
1029
|
address: n.address,
|
|
1029
1030
|
chainId: Number(n.chainId),
|
|
@@ -1033,7 +1034,7 @@ function Bs(e) {
|
|
|
1033
1034
|
yParity: Number(n.yParity)
|
|
1034
1035
|
}));
|
|
1035
1036
|
}
|
|
1036
|
-
function
|
|
1037
|
+
function Ws(e, n) {
|
|
1037
1038
|
const t = (e.transactions ?? []).map((r) => typeof r == "string" ? r : yn(r));
|
|
1038
1039
|
return {
|
|
1039
1040
|
...e,
|
|
@@ -1053,8 +1054,8 @@ function ys(e, n) {
|
|
|
1053
1054
|
totalDifficulty: e.totalDifficulty ? BigInt(e.totalDifficulty) : null
|
|
1054
1055
|
};
|
|
1055
1056
|
}
|
|
1056
|
-
const
|
|
1057
|
-
function
|
|
1057
|
+
const Vs = /* @__PURE__ */ Bn("block", Ws);
|
|
1058
|
+
function Xs(e, { args: n, eventName: t } = {}) {
|
|
1058
1059
|
return {
|
|
1059
1060
|
...e,
|
|
1060
1061
|
blockHash: e.blockHash ? e.blockHash : null,
|
|
@@ -1065,11 +1066,11 @@ function Ms(e, { args: n, eventName: t } = {}) {
|
|
|
1065
1066
|
...t ? { args: n, eventName: t } : {}
|
|
1066
1067
|
};
|
|
1067
1068
|
}
|
|
1068
|
-
const
|
|
1069
|
+
const Ns = {
|
|
1069
1070
|
"0x0": "reverted",
|
|
1070
1071
|
"0x1": "success"
|
|
1071
1072
|
};
|
|
1072
|
-
function
|
|
1073
|
+
function js(e, n) {
|
|
1073
1074
|
const t = {
|
|
1074
1075
|
...e,
|
|
1075
1076
|
blockNumber: e.blockNumber ? BigInt(e.blockNumber) : null,
|
|
@@ -1077,26 +1078,26 @@ function Vs(e, n) {
|
|
|
1077
1078
|
cumulativeGasUsed: e.cumulativeGasUsed ? BigInt(e.cumulativeGasUsed) : null,
|
|
1078
1079
|
effectiveGasPrice: e.effectiveGasPrice ? BigInt(e.effectiveGasPrice) : null,
|
|
1079
1080
|
gasUsed: e.gasUsed ? BigInt(e.gasUsed) : null,
|
|
1080
|
-
logs: e.logs ? e.logs.map((r) =>
|
|
1081
|
+
logs: e.logs ? e.logs.map((r) => Xs(r)) : null,
|
|
1081
1082
|
to: e.to ? e.to : null,
|
|
1082
|
-
transactionIndex: e.transactionIndex ?
|
|
1083
|
-
status: e.status ?
|
|
1083
|
+
transactionIndex: e.transactionIndex ? Oe(e.transactionIndex) : null,
|
|
1084
|
+
status: e.status ? Ns[e.status] : null,
|
|
1084
1085
|
type: e.type ? Wt[e.type] || e.type : null
|
|
1085
1086
|
};
|
|
1086
1087
|
return e.blobGasPrice && (t.blobGasPrice = BigInt(e.blobGasPrice)), e.blobGasUsed && (t.blobGasUsed = BigInt(e.blobGasUsed)), t;
|
|
1087
1088
|
}
|
|
1088
|
-
const
|
|
1089
|
+
const Ts = /* @__PURE__ */ Bn("transactionReceipt", js), Es = {
|
|
1089
1090
|
legacy: "0x0",
|
|
1090
1091
|
eip2930: "0x1",
|
|
1091
1092
|
eip1559: "0x2",
|
|
1092
1093
|
eip4844: "0x3",
|
|
1093
1094
|
eip7702: "0x4"
|
|
1094
1095
|
};
|
|
1095
|
-
function
|
|
1096
|
+
function Ls(e, n) {
|
|
1096
1097
|
const t = {};
|
|
1097
|
-
return typeof e.authorizationList < "u" && (t.authorizationList =
|
|
1098
|
+
return typeof e.authorizationList < "u" && (t.authorizationList = Ss(e.authorizationList)), typeof e.accessList < "u" && (t.accessList = e.accessList), typeof e.blobVersionedHashes < "u" && (t.blobVersionedHashes = e.blobVersionedHashes), typeof e.blobs < "u" && (typeof e.blobs[0] != "string" ? t.blobs = e.blobs.map((r) => q(r)) : t.blobs = e.blobs), typeof e.data < "u" && (t.data = e.data), typeof e.from < "u" && (t.from = e.from), typeof e.gas < "u" && (t.gas = z(e.gas)), typeof e.gasPrice < "u" && (t.gasPrice = z(e.gasPrice)), typeof e.maxFeePerBlobGas < "u" && (t.maxFeePerBlobGas = z(e.maxFeePerBlobGas)), typeof e.maxFeePerGas < "u" && (t.maxFeePerGas = z(e.maxFeePerGas)), typeof e.maxPriorityFeePerGas < "u" && (t.maxPriorityFeePerGas = z(e.maxPriorityFeePerGas)), typeof e.nonce < "u" && (t.nonce = z(e.nonce)), typeof e.to < "u" && (t.to = e.to), typeof e.type < "u" && (t.type = Es[e.type]), typeof e.value < "u" && (t.value = z(e.value)), t;
|
|
1098
1099
|
}
|
|
1099
|
-
function
|
|
1100
|
+
function Ss(e) {
|
|
1100
1101
|
return e.map((n) => ({
|
|
1101
1102
|
address: n.address,
|
|
1102
1103
|
r: n.r ? z(BigInt(n.r)) : n.r,
|
|
@@ -1107,28 +1108,28 @@ function Ts(e) {
|
|
|
1107
1108
|
...typeof n.v < "u" && typeof n.yParity > "u" ? { v: z(n.v) } : {}
|
|
1108
1109
|
}));
|
|
1109
1110
|
}
|
|
1110
|
-
const
|
|
1111
|
-
function
|
|
1111
|
+
const De = 2n ** 256n - 1n;
|
|
1112
|
+
function Pe(e) {
|
|
1112
1113
|
return `0x${e.reduce((n, t) => n + t.replace("0x", ""), "")}`;
|
|
1113
1114
|
}
|
|
1114
|
-
class Dn extends
|
|
1115
|
+
class Dn extends h {
|
|
1115
1116
|
constructor({ offset: n }) {
|
|
1116
1117
|
super(`Offset \`${n}\` cannot be negative.`, {
|
|
1117
1118
|
name: "NegativeOffsetError"
|
|
1118
1119
|
});
|
|
1119
1120
|
}
|
|
1120
1121
|
}
|
|
1121
|
-
class
|
|
1122
|
+
class Os extends h {
|
|
1122
1123
|
constructor({ length: n, position: t }) {
|
|
1123
1124
|
super(`Position \`${t}\` is out of bounds (\`0 < position < ${n}\`).`, { name: "PositionOutOfBoundsError" });
|
|
1124
1125
|
}
|
|
1125
1126
|
}
|
|
1126
|
-
class
|
|
1127
|
+
class Ys extends h {
|
|
1127
1128
|
constructor({ count: n, limit: t }) {
|
|
1128
1129
|
super(`Recursive read limit of \`${t}\` exceeded (recursive read count: \`${n}\`).`, { name: "RecursiveReadLimitExceededError" });
|
|
1129
1130
|
}
|
|
1130
1131
|
}
|
|
1131
|
-
const
|
|
1132
|
+
const Zs = {
|
|
1132
1133
|
bytes: new Uint8Array(),
|
|
1133
1134
|
dataView: new DataView(new ArrayBuffer(0)),
|
|
1134
1135
|
position: 0,
|
|
@@ -1137,14 +1138,14 @@ const Ss = {
|
|
|
1137
1138
|
recursiveReadLimit: Number.POSITIVE_INFINITY,
|
|
1138
1139
|
assertReadLimit() {
|
|
1139
1140
|
if (this.recursiveReadCount >= this.recursiveReadLimit)
|
|
1140
|
-
throw new
|
|
1141
|
+
throw new Ys({
|
|
1141
1142
|
count: this.recursiveReadCount + 1,
|
|
1142
1143
|
limit: this.recursiveReadLimit
|
|
1143
1144
|
});
|
|
1144
1145
|
},
|
|
1145
1146
|
assertPosition(e) {
|
|
1146
1147
|
if (e < 0 || e > this.bytes.length - 1)
|
|
1147
|
-
throw new
|
|
1148
|
+
throw new Os({
|
|
1148
1149
|
length: this.bytes.length,
|
|
1149
1150
|
position: e
|
|
1150
1151
|
});
|
|
@@ -1251,7 +1252,7 @@ const Ss = {
|
|
|
1251
1252
|
}
|
|
1252
1253
|
};
|
|
1253
1254
|
function Vt(e, { recursiveReadLimit: n = 8192 } = {}) {
|
|
1254
|
-
const t = Object.create(
|
|
1255
|
+
const t = Object.create(Zs);
|
|
1255
1256
|
return t.bytes = e, t.dataView = new DataView(e.buffer, e.byteOffset, e.byteLength), t.positionReadCount = /* @__PURE__ */ new Map(), t.recursiveReadLimit = n, t;
|
|
1256
1257
|
}
|
|
1257
1258
|
function $(e, n = "hex") {
|
|
@@ -1259,9 +1260,9 @@ function $(e, n = "hex") {
|
|
|
1259
1260
|
return t.encode(r), n === "hex" ? q(r.bytes) : r.bytes;
|
|
1260
1261
|
}
|
|
1261
1262
|
function Xt(e) {
|
|
1262
|
-
return Array.isArray(e) ?
|
|
1263
|
+
return Array.isArray(e) ? ks(e.map((n) => Xt(n))) : Js(e);
|
|
1263
1264
|
}
|
|
1264
|
-
function
|
|
1265
|
+
function ks(e) {
|
|
1265
1266
|
const n = e.reduce((s, o) => s + o.length, 0), t = Nt(n);
|
|
1266
1267
|
return {
|
|
1267
1268
|
length: n <= 55 ? 1 + n : 1 + t + n,
|
|
@@ -1272,7 +1273,7 @@ function Os(e) {
|
|
|
1272
1273
|
}
|
|
1273
1274
|
};
|
|
1274
1275
|
}
|
|
1275
|
-
function
|
|
1276
|
+
function Js(e) {
|
|
1276
1277
|
const n = typeof e == "string" ? _(e) : e, t = Nt(n.length);
|
|
1277
1278
|
return {
|
|
1278
1279
|
length: n.length === 1 && n[0] < 128 ? 1 : n.length <= 55 ? 1 + n.length : 1 + t + n.length,
|
|
@@ -1290,12 +1291,12 @@ function Nt(e) {
|
|
|
1290
1291
|
return 3;
|
|
1291
1292
|
if (e < 2 ** 32)
|
|
1292
1293
|
return 4;
|
|
1293
|
-
throw new
|
|
1294
|
+
throw new h("Length is too large.");
|
|
1294
1295
|
}
|
|
1295
|
-
const
|
|
1296
|
+
const Fs = {
|
|
1296
1297
|
gwei: 9,
|
|
1297
1298
|
wei: 18
|
|
1298
|
-
},
|
|
1299
|
+
}, Ds = {
|
|
1299
1300
|
ether: -9,
|
|
1300
1301
|
wei: 9
|
|
1301
1302
|
};
|
|
@@ -1309,18 +1310,18 @@ function jt(e, n) {
|
|
|
1309
1310
|
];
|
|
1310
1311
|
return o = o.replace(/(0+)$/, ""), `${r ? "-" : ""}${s || "0"}${o ? `.${o}` : ""}`;
|
|
1311
1312
|
}
|
|
1312
|
-
function
|
|
1313
|
-
return jt(e,
|
|
1313
|
+
function Hs(e, n = "wei") {
|
|
1314
|
+
return jt(e, Fs[n]);
|
|
1314
1315
|
}
|
|
1315
1316
|
function R(e, n = "wei") {
|
|
1316
|
-
return jt(e,
|
|
1317
|
+
return jt(e, Ds[n]);
|
|
1317
1318
|
}
|
|
1318
1319
|
function Tt(e) {
|
|
1319
1320
|
const n = Object.entries(e).map(([r, s]) => s === void 0 || s === !1 ? null : [r, s]).filter(Boolean), t = n.reduce((r, [s]) => Math.max(r, s.length), 0);
|
|
1320
1321
|
return n.map(([r, s]) => ` ${`${r}:`.padEnd(t + 1)} ${s}`).join(`
|
|
1321
1322
|
`);
|
|
1322
1323
|
}
|
|
1323
|
-
class
|
|
1324
|
+
class Qs extends h {
|
|
1324
1325
|
constructor() {
|
|
1325
1326
|
super([
|
|
1326
1327
|
"Cannot specify both a `gasPrice` and a `maxFeePerGas`/`maxPriorityFeePerGas`.",
|
|
@@ -1329,14 +1330,14 @@ class Fs extends y {
|
|
|
1329
1330
|
`), { name: "FeeConflictError" });
|
|
1330
1331
|
}
|
|
1331
1332
|
}
|
|
1332
|
-
class
|
|
1333
|
+
class qs extends h {
|
|
1333
1334
|
constructor({ v: n }) {
|
|
1334
1335
|
super(`Invalid \`v\` value "${n}". Expected 27 or 28.`, {
|
|
1335
1336
|
name: "InvalidLegacyVError"
|
|
1336
1337
|
});
|
|
1337
1338
|
}
|
|
1338
1339
|
}
|
|
1339
|
-
class
|
|
1340
|
+
class Ks extends h {
|
|
1340
1341
|
constructor({ transaction: n }) {
|
|
1341
1342
|
super("Cannot infer a transaction type from provided transaction.", {
|
|
1342
1343
|
metaMessages: [
|
|
@@ -1357,22 +1358,22 @@ class Hs extends y {
|
|
|
1357
1358
|
});
|
|
1358
1359
|
}
|
|
1359
1360
|
}
|
|
1360
|
-
class
|
|
1361
|
+
class Gs extends h {
|
|
1361
1362
|
constructor({ storageKey: n }) {
|
|
1362
1363
|
super(`Size for storage key "${n}" is invalid. Expected 32 bytes. Got ${Math.floor((n.length - 2) / 2)} bytes.`, { name: "InvalidStorageKeySizeError" });
|
|
1363
1364
|
}
|
|
1364
1365
|
}
|
|
1365
|
-
function
|
|
1366
|
+
function Us(e) {
|
|
1366
1367
|
if (!e || e.length === 0)
|
|
1367
1368
|
return [];
|
|
1368
1369
|
const n = [];
|
|
1369
1370
|
for (const t of e) {
|
|
1370
1371
|
const { chainId: r, nonce: s, ...o } = t, c = t.address;
|
|
1371
1372
|
n.push([
|
|
1372
|
-
r ?
|
|
1373
|
+
r ? me(r) : "0x",
|
|
1373
1374
|
c,
|
|
1374
|
-
s ?
|
|
1375
|
-
...
|
|
1375
|
+
s ? me(s) : "0x",
|
|
1376
|
+
...Be({}, o)
|
|
1376
1377
|
]);
|
|
1377
1378
|
}
|
|
1378
1379
|
return n;
|
|
@@ -1391,35 +1392,35 @@ function Lt(e) {
|
|
|
1391
1392
|
}
|
|
1392
1393
|
return t === "bytes" ? o : o.map((c) => q(c));
|
|
1393
1394
|
}
|
|
1394
|
-
function
|
|
1395
|
+
function Rs(e) {
|
|
1395
1396
|
return e instanceof Uint8Array || ArrayBuffer.isView(e) && e.constructor.name === "Uint8Array";
|
|
1396
1397
|
}
|
|
1397
1398
|
function Hn(e) {
|
|
1398
1399
|
if (!Number.isSafeInteger(e) || e < 0)
|
|
1399
1400
|
throw new Error("positive integer expected, got " + e);
|
|
1400
1401
|
}
|
|
1401
|
-
function
|
|
1402
|
-
if (!
|
|
1402
|
+
function xe(e, ...n) {
|
|
1403
|
+
if (!Rs(e))
|
|
1403
1404
|
throw new Error("Uint8Array expected");
|
|
1404
1405
|
if (n.length > 0 && !n.includes(e.length))
|
|
1405
1406
|
throw new Error("Uint8Array expected of length " + n + ", got length=" + e.length);
|
|
1406
1407
|
}
|
|
1407
|
-
function
|
|
1408
|
+
function Ye(e, n = !0) {
|
|
1408
1409
|
if (e.destroyed)
|
|
1409
1410
|
throw new Error("Hash instance has been destroyed");
|
|
1410
1411
|
if (n && e.finished)
|
|
1411
1412
|
throw new Error("Hash#digest() has already been called");
|
|
1412
1413
|
}
|
|
1413
1414
|
function St(e, n) {
|
|
1414
|
-
|
|
1415
|
+
xe(e);
|
|
1415
1416
|
const t = n.outputLen;
|
|
1416
1417
|
if (e.length < t)
|
|
1417
1418
|
throw new Error("digestInto() expects output buffer of length at least " + t);
|
|
1418
1419
|
}
|
|
1419
|
-
function
|
|
1420
|
+
function _s(e) {
|
|
1420
1421
|
return new Uint32Array(e.buffer, e.byteOffset, Math.floor(e.byteLength / 4));
|
|
1421
1422
|
}
|
|
1422
|
-
function
|
|
1423
|
+
function pe(...e) {
|
|
1423
1424
|
for (let n = 0; n < e.length; n++)
|
|
1424
1425
|
e[n].fill(0);
|
|
1425
1426
|
}
|
|
@@ -1429,23 +1430,23 @@ function $e(e) {
|
|
|
1429
1430
|
function J(e, n) {
|
|
1430
1431
|
return e << 32 - n | e >>> n;
|
|
1431
1432
|
}
|
|
1432
|
-
const
|
|
1433
|
-
function
|
|
1433
|
+
const $s = new Uint8Array(new Uint32Array([287454020]).buffer)[0] === 68;
|
|
1434
|
+
function ei(e) {
|
|
1434
1435
|
return e << 24 & 4278190080 | e << 8 & 16711680 | e >>> 8 & 65280 | e >>> 24 & 255;
|
|
1435
1436
|
}
|
|
1436
|
-
function
|
|
1437
|
+
function ni(e) {
|
|
1437
1438
|
for (let n = 0; n < e.length; n++)
|
|
1438
|
-
e[n] =
|
|
1439
|
+
e[n] = ei(e[n]);
|
|
1439
1440
|
return e;
|
|
1440
1441
|
}
|
|
1441
|
-
const Qn =
|
|
1442
|
-
function
|
|
1442
|
+
const Qn = $s ? (e) => e : ni;
|
|
1443
|
+
function ti(e) {
|
|
1443
1444
|
if (typeof e != "string")
|
|
1444
1445
|
throw new Error("string expected");
|
|
1445
1446
|
return new Uint8Array(new TextEncoder().encode(e));
|
|
1446
1447
|
}
|
|
1447
1448
|
function hn(e) {
|
|
1448
|
-
return typeof e == "string" && (e =
|
|
1449
|
+
return typeof e == "string" && (e = ti(e)), xe(e), e;
|
|
1449
1450
|
}
|
|
1450
1451
|
class Ot {
|
|
1451
1452
|
}
|
|
@@ -1453,24 +1454,24 @@ function Yt(e) {
|
|
|
1453
1454
|
const n = (r) => e().update(hn(r)).digest(), t = e();
|
|
1454
1455
|
return n.outputLen = t.outputLen, n.blockLen = t.blockLen, n.create = () => e(), n;
|
|
1455
1456
|
}
|
|
1456
|
-
function
|
|
1457
|
+
function ri(e, n, t, r) {
|
|
1457
1458
|
if (typeof e.setBigUint64 == "function")
|
|
1458
1459
|
return e.setBigUint64(n, t, r);
|
|
1459
1460
|
const s = BigInt(32), o = BigInt(4294967295), c = Number(t >> s & o), a = Number(t & o), l = r ? 4 : 0, A = r ? 0 : 4;
|
|
1460
1461
|
e.setUint32(n + l, c, r), e.setUint32(n + A, a, r);
|
|
1461
1462
|
}
|
|
1462
|
-
function
|
|
1463
|
+
function si(e, n, t) {
|
|
1463
1464
|
return e & n ^ ~e & t;
|
|
1464
1465
|
}
|
|
1465
|
-
function
|
|
1466
|
+
function ii(e, n, t) {
|
|
1466
1467
|
return e & n ^ e & t ^ n & t;
|
|
1467
1468
|
}
|
|
1468
|
-
class
|
|
1469
|
+
class oi extends Ot {
|
|
1469
1470
|
constructor(n, t, r, s) {
|
|
1470
1471
|
super(), this.finished = !1, this.length = 0, this.pos = 0, this.destroyed = !1, this.blockLen = n, this.outputLen = t, this.padOffset = r, this.isLE = s, this.buffer = new Uint8Array(n), this.view = $e(this.buffer);
|
|
1471
1472
|
}
|
|
1472
1473
|
update(n) {
|
|
1473
|
-
|
|
1474
|
+
Ye(this), n = hn(n), xe(n);
|
|
1474
1475
|
const { view: t, buffer: r, blockLen: s } = this, o = n.length;
|
|
1475
1476
|
for (let c = 0; c < o; ) {
|
|
1476
1477
|
const a = Math.min(s - this.pos, o - c);
|
|
@@ -1485,13 +1486,13 @@ class ri extends Ot {
|
|
|
1485
1486
|
return this.length += n.length, this.roundClean(), this;
|
|
1486
1487
|
}
|
|
1487
1488
|
digestInto(n) {
|
|
1488
|
-
|
|
1489
|
+
Ye(this), St(n, this), this.finished = !0;
|
|
1489
1490
|
const { buffer: t, view: r, blockLen: s, isLE: o } = this;
|
|
1490
1491
|
let { pos: c } = this;
|
|
1491
|
-
t[c++] = 128,
|
|
1492
|
+
t[c++] = 128, pe(this.buffer.subarray(c)), this.padOffset > s - c && (this.process(r, 0), c = 0);
|
|
1492
1493
|
for (let f = c; f < s; f++)
|
|
1493
1494
|
t[f] = 0;
|
|
1494
|
-
|
|
1495
|
+
ri(r, s - 8, BigInt(this.length * 8), o), this.process(r, 0);
|
|
1495
1496
|
const a = $e(n), l = this.outputLen;
|
|
1496
1497
|
if (l % 4)
|
|
1497
1498
|
throw new Error("_sha2: outputLen should be aligned to 32bit");
|
|
@@ -1525,20 +1526,20 @@ const K = /* @__PURE__ */ Uint32Array.from([
|
|
|
1525
1526
|
2600822924,
|
|
1526
1527
|
528734635,
|
|
1527
1528
|
1541459225
|
|
1528
|
-
]),
|
|
1529
|
-
function
|
|
1530
|
-
return n ? { h: Number(e &
|
|
1529
|
+
]), We = /* @__PURE__ */ BigInt(2 ** 32 - 1), qn = /* @__PURE__ */ BigInt(32);
|
|
1530
|
+
function ci(e, n = !1) {
|
|
1531
|
+
return n ? { h: Number(e & We), l: Number(e >> qn & We) } : { h: Number(e >> qn & We) | 0, l: Number(e & We) | 0 };
|
|
1531
1532
|
}
|
|
1532
|
-
function
|
|
1533
|
+
function ai(e, n = !1) {
|
|
1533
1534
|
const t = e.length;
|
|
1534
1535
|
let r = new Uint32Array(t), s = new Uint32Array(t);
|
|
1535
1536
|
for (let o = 0; o < t; o++) {
|
|
1536
|
-
const { h: c, l: a } =
|
|
1537
|
+
const { h: c, l: a } = ci(e[o], n);
|
|
1537
1538
|
[r[o], s[o]] = [c, a];
|
|
1538
1539
|
}
|
|
1539
1540
|
return [r, s];
|
|
1540
1541
|
}
|
|
1541
|
-
const
|
|
1542
|
+
const li = (e, n, t) => e << t | n >>> 32 - t, Ai = (e, n, t) => n << t | e >>> 32 - t, di = (e, n, t) => n << t - 32 | e >>> 64 - t, fi = (e, n, t) => e << t - 32 | n >>> 64 - t, ui = /* @__PURE__ */ Uint32Array.from([
|
|
1542
1543
|
1116352408,
|
|
1543
1544
|
1899447441,
|
|
1544
1545
|
3049323471,
|
|
@@ -1604,7 +1605,7 @@ const oi = (e, n, t) => e << t | n >>> 32 - t, ci = (e, n, t) => n << t | e >>>
|
|
|
1604
1605
|
3204031479,
|
|
1605
1606
|
3329325298
|
|
1606
1607
|
]), G = /* @__PURE__ */ new Uint32Array(64);
|
|
1607
|
-
class
|
|
1608
|
+
class gi extends oi {
|
|
1608
1609
|
constructor(n = 32) {
|
|
1609
1610
|
super(64, n, 8, !1), this.A = K[0] | 0, this.B = K[1] | 0, this.C = K[2] | 0, this.D = K[3] | 0, this.E = K[4] | 0, this.F = K[5] | 0, this.G = K[6] | 0, this.H = K[7] | 0;
|
|
1610
1611
|
}
|
|
@@ -1620,35 +1621,35 @@ class di extends ri {
|
|
|
1620
1621
|
for (let f = 0; f < 16; f++, t += 4)
|
|
1621
1622
|
G[f] = n.getUint32(t, !1);
|
|
1622
1623
|
for (let f = 16; f < 64; f++) {
|
|
1623
|
-
const
|
|
1624
|
-
G[f] =
|
|
1624
|
+
const u = G[f - 15], g = G[f - 2], x = J(u, 7) ^ J(u, 18) ^ u >>> 3, v = J(g, 17) ^ J(g, 19) ^ g >>> 10;
|
|
1625
|
+
G[f] = v + G[f - 7] + x + G[f - 16] | 0;
|
|
1625
1626
|
}
|
|
1626
1627
|
let { A: r, B: s, C: o, D: c, E: a, F: l, G: A, H: d } = this;
|
|
1627
1628
|
for (let f = 0; f < 64; f++) {
|
|
1628
|
-
const
|
|
1629
|
-
d = A, A = l, l = a, a = c +
|
|
1629
|
+
const u = J(a, 6) ^ J(a, 11) ^ J(a, 25), g = d + u + si(a, l, A) + ui[f] + G[f] | 0, v = (J(r, 2) ^ J(r, 13) ^ J(r, 22)) + ii(r, s, o) | 0;
|
|
1630
|
+
d = A, A = l, l = a, a = c + g | 0, c = o, o = s, s = r, r = g + v | 0;
|
|
1630
1631
|
}
|
|
1631
1632
|
r = r + this.A | 0, s = s + this.B | 0, o = o + this.C | 0, c = c + this.D | 0, a = a + this.E | 0, l = l + this.F | 0, A = A + this.G | 0, d = d + this.H | 0, this.set(r, s, o, c, a, l, A, d);
|
|
1632
1633
|
}
|
|
1633
1634
|
roundClean() {
|
|
1634
|
-
|
|
1635
|
+
pe(G);
|
|
1635
1636
|
}
|
|
1636
1637
|
destroy() {
|
|
1637
|
-
this.set(0, 0, 0, 0, 0, 0, 0, 0),
|
|
1638
|
+
this.set(0, 0, 0, 0, 0, 0, 0, 0), pe(this.buffer);
|
|
1638
1639
|
}
|
|
1639
1640
|
}
|
|
1640
|
-
const
|
|
1641
|
-
function
|
|
1642
|
-
return
|
|
1641
|
+
const vi = /* @__PURE__ */ Yt(() => new gi()), Ci = vi;
|
|
1642
|
+
function mi(e, n) {
|
|
1643
|
+
return Ci(Ie(e, { strict: !1 }) ? ht(e) : e);
|
|
1643
1644
|
}
|
|
1644
|
-
function
|
|
1645
|
-
const { commitment: n, version: t = 1 } = e, r = e.to ?? (typeof n == "string" ? "hex" : "bytes"), s =
|
|
1645
|
+
function xi(e) {
|
|
1646
|
+
const { commitment: n, version: t = 1 } = e, r = e.to ?? (typeof n == "string" ? "hex" : "bytes"), s = mi(n);
|
|
1646
1647
|
return s.set([t], 0), r === "bytes" ? s : q(s);
|
|
1647
1648
|
}
|
|
1648
|
-
function
|
|
1649
|
+
function pi(e) {
|
|
1649
1650
|
const { commitments: n, version: t } = e, r = e.to ?? (typeof n[0] == "string" ? "hex" : "bytes"), s = [];
|
|
1650
1651
|
for (const o of n)
|
|
1651
|
-
s.push(
|
|
1652
|
+
s.push(xi({
|
|
1652
1653
|
commitment: o,
|
|
1653
1654
|
to: r,
|
|
1654
1655
|
version: t
|
|
@@ -1658,7 +1659,7 @@ function Ci(e) {
|
|
|
1658
1659
|
const Kn = 6, Zt = 32, Mn = 4096, kt = Zt * Mn, Gn = kt * Kn - // terminator byte (0x80).
|
|
1659
1660
|
1 - // zero byte (0x00) appended to each field element.
|
|
1660
1661
|
1 * Mn * Kn, Jt = 1;
|
|
1661
|
-
class
|
|
1662
|
+
class bi extends h {
|
|
1662
1663
|
constructor({ maxSize: n, size: t }) {
|
|
1663
1664
|
super("Blob size is too large.", {
|
|
1664
1665
|
metaMessages: [`Max: ${n} bytes`, `Given: ${t} bytes`],
|
|
@@ -1666,12 +1667,12 @@ class mi extends y {
|
|
|
1666
1667
|
});
|
|
1667
1668
|
}
|
|
1668
1669
|
}
|
|
1669
|
-
class Ft extends
|
|
1670
|
+
class Ft extends h {
|
|
1670
1671
|
constructor() {
|
|
1671
1672
|
super("Blob data must not be empty.", { name: "EmptyBlobError" });
|
|
1672
1673
|
}
|
|
1673
1674
|
}
|
|
1674
|
-
class
|
|
1675
|
+
class zi extends h {
|
|
1675
1676
|
constructor({ hash: n, size: t }) {
|
|
1676
1677
|
super(`Versioned hash "${n}" size is invalid.`, {
|
|
1677
1678
|
metaMessages: ["Expected: 32", `Received: ${t}`],
|
|
@@ -1679,7 +1680,7 @@ class xi extends y {
|
|
|
1679
1680
|
});
|
|
1680
1681
|
}
|
|
1681
1682
|
}
|
|
1682
|
-
class
|
|
1683
|
+
class wi extends h {
|
|
1683
1684
|
constructor({ hash: n, version: t }) {
|
|
1684
1685
|
super(`Versioned hash "${n}" version is invalid.`, {
|
|
1685
1686
|
metaMessages: [
|
|
@@ -1690,12 +1691,12 @@ class pi extends y {
|
|
|
1690
1691
|
});
|
|
1691
1692
|
}
|
|
1692
1693
|
}
|
|
1693
|
-
function
|
|
1694
|
+
function Ii(e) {
|
|
1694
1695
|
const n = e.to ?? (typeof e.data == "string" ? "hex" : "bytes"), t = typeof e.data == "string" ? _(e.data) : e.data, r = ae(t);
|
|
1695
1696
|
if (!r)
|
|
1696
1697
|
throw new Ft();
|
|
1697
1698
|
if (r > Gn)
|
|
1698
|
-
throw new
|
|
1699
|
+
throw new bi({
|
|
1699
1700
|
maxSize: Gn,
|
|
1700
1701
|
size: r
|
|
1701
1702
|
});
|
|
@@ -1716,8 +1717,8 @@ function bi(e) {
|
|
|
1716
1717
|
}
|
|
1717
1718
|
return n === "bytes" ? s.map((a) => a.bytes) : s.map((a) => q(a.bytes));
|
|
1718
1719
|
}
|
|
1719
|
-
function
|
|
1720
|
-
const { data: n, kzg: t, to: r } = e, s = e.blobs ??
|
|
1720
|
+
function Pi(e) {
|
|
1721
|
+
const { data: n, kzg: t, to: r } = e, s = e.blobs ?? Ii({ data: n, to: r }), o = e.commitments ?? Et({ blobs: s, kzg: t, to: r }), c = e.proofs ?? Lt({ blobs: s, commitments: o, kzg: t, to: r }), a = [];
|
|
1721
1722
|
for (let l = 0; l < s.length; l++)
|
|
1722
1723
|
a.push({
|
|
1723
1724
|
blob: s[l],
|
|
@@ -1726,7 +1727,7 @@ function zi(e) {
|
|
|
1726
1727
|
});
|
|
1727
1728
|
return a;
|
|
1728
1729
|
}
|
|
1729
|
-
class H extends
|
|
1730
|
+
class H extends h {
|
|
1730
1731
|
constructor({ address: n }) {
|
|
1731
1732
|
super(`Address "${n}" is invalid.`, {
|
|
1732
1733
|
metaMessages: [
|
|
@@ -1737,12 +1738,12 @@ class H extends y {
|
|
|
1737
1738
|
});
|
|
1738
1739
|
}
|
|
1739
1740
|
}
|
|
1740
|
-
class
|
|
1741
|
+
class He extends h {
|
|
1741
1742
|
constructor({ chainId: n }) {
|
|
1742
1743
|
super(typeof n == "number" ? `Chain ID "${n}" is invalid.` : "Chain ID is invalid.", { name: "InvalidChainIdError" });
|
|
1743
1744
|
}
|
|
1744
1745
|
}
|
|
1745
|
-
class ie extends
|
|
1746
|
+
class ie extends h {
|
|
1746
1747
|
constructor({ cause: n, message: t } = {}) {
|
|
1747
1748
|
const r = t?.replace("execution reverted: ", "")?.replace("execution reverted", "");
|
|
1748
1749
|
super(`Execution reverted ${r ? `with reason: ${r}` : "for an unknown reason"}.`, {
|
|
@@ -1763,7 +1764,7 @@ Object.defineProperty(ie, "nodeMessage", {
|
|
|
1763
1764
|
writable: !0,
|
|
1764
1765
|
value: /execution reverted/
|
|
1765
1766
|
});
|
|
1766
|
-
class ee extends
|
|
1767
|
+
class ee extends h {
|
|
1767
1768
|
constructor({ cause: n, maxFeePerGas: t } = {}) {
|
|
1768
1769
|
super(`The fee cap (\`maxFeePerGas\`${t ? ` = ${R(t)} gwei` : ""}) cannot be higher than the maximum allowed value (2^256-1).`, {
|
|
1769
1770
|
cause: n,
|
|
@@ -1777,7 +1778,7 @@ Object.defineProperty(ee, "nodeMessage", {
|
|
|
1777
1778
|
writable: !0,
|
|
1778
1779
|
value: /max fee per gas higher than 2\^256-1|fee cap higher than 2\^256-1/
|
|
1779
1780
|
});
|
|
1780
|
-
class ln extends
|
|
1781
|
+
class ln extends h {
|
|
1781
1782
|
constructor({ cause: n, maxFeePerGas: t } = {}) {
|
|
1782
1783
|
super(`The fee cap (\`maxFeePerGas\`${t ? ` = ${R(t)}` : ""} gwei) cannot be lower than the block base fee.`, {
|
|
1783
1784
|
cause: n,
|
|
@@ -1791,7 +1792,7 @@ Object.defineProperty(ln, "nodeMessage", {
|
|
|
1791
1792
|
writable: !0,
|
|
1792
1793
|
value: /max fee per gas less than block base fee|fee cap less than block base fee|transaction is outdated/
|
|
1793
1794
|
});
|
|
1794
|
-
class An extends
|
|
1795
|
+
class An extends h {
|
|
1795
1796
|
constructor({ cause: n, nonce: t } = {}) {
|
|
1796
1797
|
super(`Nonce provided for the transaction ${t ? `(${t}) ` : ""}is higher than the next one expected.`, { cause: n, name: "NonceTooHighError" });
|
|
1797
1798
|
}
|
|
@@ -1802,7 +1803,7 @@ Object.defineProperty(An, "nodeMessage", {
|
|
|
1802
1803
|
writable: !0,
|
|
1803
1804
|
value: /nonce too high/
|
|
1804
1805
|
});
|
|
1805
|
-
class dn extends
|
|
1806
|
+
class dn extends h {
|
|
1806
1807
|
constructor({ cause: n, nonce: t } = {}) {
|
|
1807
1808
|
super([
|
|
1808
1809
|
`Nonce provided for the transaction ${t ? `(${t}) ` : ""}is lower than the current nonce of the account.`,
|
|
@@ -1817,7 +1818,7 @@ Object.defineProperty(dn, "nodeMessage", {
|
|
|
1817
1818
|
writable: !0,
|
|
1818
1819
|
value: /nonce too low|transaction already imported|already known/
|
|
1819
1820
|
});
|
|
1820
|
-
class fn extends
|
|
1821
|
+
class fn extends h {
|
|
1821
1822
|
constructor({ cause: n, nonce: t } = {}) {
|
|
1822
1823
|
super(`Nonce provided for the transaction ${t ? `(${t}) ` : ""}exceeds the maximum allowed nonce.`, { cause: n, name: "NonceMaxValueError" });
|
|
1823
1824
|
}
|
|
@@ -1828,7 +1829,7 @@ Object.defineProperty(fn, "nodeMessage", {
|
|
|
1828
1829
|
writable: !0,
|
|
1829
1830
|
value: /nonce has max value/
|
|
1830
1831
|
});
|
|
1831
|
-
class un extends
|
|
1832
|
+
class un extends h {
|
|
1832
1833
|
constructor({ cause: n } = {}) {
|
|
1833
1834
|
super([
|
|
1834
1835
|
"The total cost (gas * gas fee + value) of executing this transaction exceeds the balance of the account."
|
|
@@ -1855,7 +1856,7 @@ Object.defineProperty(un, "nodeMessage", {
|
|
|
1855
1856
|
writable: !0,
|
|
1856
1857
|
value: /insufficient funds|exceeds transaction sender account balance/
|
|
1857
1858
|
});
|
|
1858
|
-
class gn extends
|
|
1859
|
+
class gn extends h {
|
|
1859
1860
|
constructor({ cause: n, gas: t } = {}) {
|
|
1860
1861
|
super(`The amount of gas ${t ? `(${t}) ` : ""}provided for the transaction exceeds the limit allowed for the block.`, {
|
|
1861
1862
|
cause: n,
|
|
@@ -1869,7 +1870,7 @@ Object.defineProperty(gn, "nodeMessage", {
|
|
|
1869
1870
|
writable: !0,
|
|
1870
1871
|
value: /intrinsic gas too high|gas limit reached/
|
|
1871
1872
|
});
|
|
1872
|
-
class vn extends
|
|
1873
|
+
class vn extends h {
|
|
1873
1874
|
constructor({ cause: n, gas: t } = {}) {
|
|
1874
1875
|
super(`The amount of gas ${t ? `(${t}) ` : ""}provided for the transaction is too low.`, {
|
|
1875
1876
|
cause: n,
|
|
@@ -1883,7 +1884,7 @@ Object.defineProperty(vn, "nodeMessage", {
|
|
|
1883
1884
|
writable: !0,
|
|
1884
1885
|
value: /intrinsic gas too low/
|
|
1885
1886
|
});
|
|
1886
|
-
class Cn extends
|
|
1887
|
+
class Cn extends h {
|
|
1887
1888
|
constructor({ cause: n }) {
|
|
1888
1889
|
super("The transaction type is not supported for this chain.", {
|
|
1889
1890
|
cause: n,
|
|
@@ -1897,7 +1898,7 @@ Object.defineProperty(Cn, "nodeMessage", {
|
|
|
1897
1898
|
writable: !0,
|
|
1898
1899
|
value: /transaction type not valid/
|
|
1899
1900
|
});
|
|
1900
|
-
class
|
|
1901
|
+
class be extends h {
|
|
1901
1902
|
constructor({ cause: n, maxPriorityFeePerGas: t, maxFeePerGas: r } = {}) {
|
|
1902
1903
|
super([
|
|
1903
1904
|
`The provided tip (\`maxPriorityFeePerGas\`${t ? ` = ${R(t)} gwei` : ""}) cannot be higher than the fee cap (\`maxFeePerGas\`${r ? ` = ${R(r)} gwei` : ""}).`
|
|
@@ -1908,13 +1909,13 @@ class pe extends y {
|
|
|
1908
1909
|
});
|
|
1909
1910
|
}
|
|
1910
1911
|
}
|
|
1911
|
-
Object.defineProperty(
|
|
1912
|
+
Object.defineProperty(be, "nodeMessage", {
|
|
1912
1913
|
enumerable: !0,
|
|
1913
1914
|
configurable: !0,
|
|
1914
1915
|
writable: !0,
|
|
1915
1916
|
value: /max priority fee per gas higher than max fee per gas|tip higher than fee cap/
|
|
1916
1917
|
});
|
|
1917
|
-
class Dt extends
|
|
1918
|
+
class Dt extends h {
|
|
1918
1919
|
constructor({ cause: n }) {
|
|
1919
1920
|
super(`An error occurred while executing: ${n?.shortMessage}`, {
|
|
1920
1921
|
cause: n,
|
|
@@ -1943,24 +1944,24 @@ class Ht extends Map {
|
|
|
1943
1944
|
return this;
|
|
1944
1945
|
}
|
|
1945
1946
|
}
|
|
1946
|
-
const
|
|
1947
|
+
const Bi = BigInt(0), ue = BigInt(1), yi = BigInt(2), hi = BigInt(7), Mi = BigInt(256), Wi = BigInt(113), Qt = [], qt = [], Kt = [];
|
|
1947
1948
|
for (let e = 0, n = ue, t = 1, r = 0; e < 24; e++) {
|
|
1948
1949
|
[t, r] = [r, (2 * t + 3 * r) % 5], Qt.push(2 * (5 * r + t)), qt.push((e + 1) * (e + 2) / 2 % 64);
|
|
1949
|
-
let s =
|
|
1950
|
+
let s = Bi;
|
|
1950
1951
|
for (let o = 0; o < 7; o++)
|
|
1951
|
-
n = (n << ue ^ (n >>
|
|
1952
|
+
n = (n << ue ^ (n >> hi) * Wi) % Mi, n & yi && (s ^= ue << (ue << /* @__PURE__ */ BigInt(o)) - ue);
|
|
1952
1953
|
Kt.push(s);
|
|
1953
1954
|
}
|
|
1954
|
-
const Gt =
|
|
1955
|
-
function
|
|
1955
|
+
const Gt = ai(Kt, !0), Vi = Gt[0], Xi = Gt[1], Un = (e, n, t) => t > 32 ? di(e, n, t) : li(e, n, t), Rn = (e, n, t) => t > 32 ? fi(e, n, t) : Ai(e, n, t);
|
|
1956
|
+
function Ni(e, n = 24) {
|
|
1956
1957
|
const t = new Uint32Array(10);
|
|
1957
1958
|
for (let r = 24 - n; r < 24; r++) {
|
|
1958
1959
|
for (let c = 0; c < 10; c++)
|
|
1959
1960
|
t[c] = e[c] ^ e[c + 10] ^ e[c + 20] ^ e[c + 30] ^ e[c + 40];
|
|
1960
1961
|
for (let c = 0; c < 10; c += 2) {
|
|
1961
|
-
const a = (c + 8) % 10, l = (c + 2) % 10, A = t[l], d = t[l + 1], f = Un(A, d, 1) ^ t[a],
|
|
1962
|
-
for (let
|
|
1963
|
-
e[c +
|
|
1962
|
+
const a = (c + 8) % 10, l = (c + 2) % 10, A = t[l], d = t[l + 1], f = Un(A, d, 1) ^ t[a], u = Rn(A, d, 1) ^ t[a + 1];
|
|
1963
|
+
for (let g = 0; g < 50; g += 10)
|
|
1964
|
+
e[c + g] ^= f, e[c + g + 1] ^= u;
|
|
1964
1965
|
}
|
|
1965
1966
|
let s = e[2], o = e[3];
|
|
1966
1967
|
for (let c = 0; c < 24; c++) {
|
|
@@ -1973,25 +1974,25 @@ function Wi(e, n = 24) {
|
|
|
1973
1974
|
for (let a = 0; a < 10; a++)
|
|
1974
1975
|
e[c + a] ^= ~t[(a + 2) % 10] & t[(a + 4) % 10];
|
|
1975
1976
|
}
|
|
1976
|
-
e[0] ^=
|
|
1977
|
+
e[0] ^= Vi[r], e[1] ^= Xi[r];
|
|
1977
1978
|
}
|
|
1978
|
-
|
|
1979
|
+
pe(t);
|
|
1979
1980
|
}
|
|
1980
1981
|
class Wn extends Ot {
|
|
1981
1982
|
// NOTE: we accept arguments in bytes instead of bits here.
|
|
1982
1983
|
constructor(n, t, r, s = !1, o = 24) {
|
|
1983
1984
|
if (super(), this.pos = 0, this.posOut = 0, this.finished = !1, this.destroyed = !1, this.enableXOF = !1, this.blockLen = n, this.suffix = t, this.outputLen = r, this.enableXOF = s, this.rounds = o, Hn(r), !(0 < n && n < 200))
|
|
1984
1985
|
throw new Error("only keccak-f1600 function is supported");
|
|
1985
|
-
this.state = new Uint8Array(200), this.state32 =
|
|
1986
|
+
this.state = new Uint8Array(200), this.state32 = _s(this.state);
|
|
1986
1987
|
}
|
|
1987
1988
|
clone() {
|
|
1988
1989
|
return this._cloneInto();
|
|
1989
1990
|
}
|
|
1990
1991
|
keccak() {
|
|
1991
|
-
Qn(this.state32),
|
|
1992
|
+
Qn(this.state32), Ni(this.state32, this.rounds), Qn(this.state32), this.posOut = 0, this.pos = 0;
|
|
1992
1993
|
}
|
|
1993
1994
|
update(n) {
|
|
1994
|
-
|
|
1995
|
+
Ye(this), n = hn(n), xe(n);
|
|
1995
1996
|
const { blockLen: t, state: r } = this, s = n.length;
|
|
1996
1997
|
for (let o = 0; o < s; ) {
|
|
1997
1998
|
const c = Math.min(t - this.pos, s - o);
|
|
@@ -2009,7 +2010,7 @@ class Wn extends Ot {
|
|
|
2009
2010
|
n[r] ^= t, (t & 128) !== 0 && r === s - 1 && this.keccak(), n[s - 1] ^= 128, this.keccak();
|
|
2010
2011
|
}
|
|
2011
2012
|
writeInto(n) {
|
|
2012
|
-
|
|
2013
|
+
Ye(this, !1), xe(n), this.finish();
|
|
2013
2014
|
const t = this.state, { blockLen: r } = this;
|
|
2014
2015
|
for (let s = 0, o = n.length; s < o; ) {
|
|
2015
2016
|
this.posOut >= r && this.keccak();
|
|
@@ -2035,59 +2036,59 @@ class Wn extends Ot {
|
|
|
2035
2036
|
return this.digestInto(new Uint8Array(this.outputLen));
|
|
2036
2037
|
}
|
|
2037
2038
|
destroy() {
|
|
2038
|
-
this.destroyed = !0,
|
|
2039
|
+
this.destroyed = !0, pe(this.state);
|
|
2039
2040
|
}
|
|
2040
2041
|
_cloneInto(n) {
|
|
2041
2042
|
const { blockLen: t, suffix: r, outputLen: s, rounds: o, enableXOF: c } = this;
|
|
2042
2043
|
return n || (n = new Wn(t, r, s, c, o)), n.state32.set(this.state32), n.pos = this.pos, n.posOut = this.posOut, n.finished = this.finished, n.rounds = o, n.suffix = r, n.outputLen = s, n.enableXOF = c, n.destroyed = this.destroyed, n;
|
|
2043
2044
|
}
|
|
2044
2045
|
}
|
|
2045
|
-
const
|
|
2046
|
-
function
|
|
2047
|
-
return
|
|
2046
|
+
const ji = (e, n, t) => Yt(() => new Wn(n, e, t)), Ti = ji(1, 136, 256 / 8);
|
|
2047
|
+
function Ei(e, n) {
|
|
2048
|
+
return Ti(Ie(e, { strict: !1 }) ? ht(e) : e);
|
|
2048
2049
|
}
|
|
2049
2050
|
const en = /* @__PURE__ */ new Ht(8192);
|
|
2050
|
-
function
|
|
2051
|
+
function Li(e, n) {
|
|
2051
2052
|
if (en.has(`${e}.${n}`))
|
|
2052
2053
|
return en.get(`${e}.${n}`);
|
|
2053
|
-
const t = e.substring(2).toLowerCase(), r =
|
|
2054
|
+
const t = e.substring(2).toLowerCase(), r = Ei(Mt(t)), s = t.split("");
|
|
2054
2055
|
for (let c = 0; c < 40; c += 2)
|
|
2055
2056
|
r[c >> 1] >> 4 >= 8 && s[c] && (s[c] = s[c].toUpperCase()), (r[c >> 1] & 15) >= 8 && s[c + 1] && (s[c + 1] = s[c + 1].toUpperCase());
|
|
2056
2057
|
const o = `0x${s.join("")}`;
|
|
2057
2058
|
return en.set(`${e}.${n}`, o), o;
|
|
2058
2059
|
}
|
|
2059
|
-
const
|
|
2060
|
+
const Si = /^0x[a-fA-F0-9]{40}$/, nn = /* @__PURE__ */ new Ht(8192);
|
|
2060
2061
|
function Q(e, n) {
|
|
2061
2062
|
const { strict: t = !0 } = n ?? {}, r = `${e}.${t}`;
|
|
2062
2063
|
if (nn.has(r))
|
|
2063
2064
|
return nn.get(r);
|
|
2064
|
-
const s =
|
|
2065
|
+
const s = Si.test(e) ? e.toLowerCase() === e ? !0 : t ? Li(e) === e : !0 : !1;
|
|
2065
2066
|
return nn.set(r, s), s;
|
|
2066
2067
|
}
|
|
2067
|
-
function
|
|
2068
|
-
return
|
|
2068
|
+
function Oi(e, n, t, { strict: r } = {}) {
|
|
2069
|
+
return Ie(e, { strict: !1 }) ? Zi(e, n, t, {
|
|
2069
2070
|
strict: r
|
|
2070
|
-
}) :
|
|
2071
|
+
}) : Yi(e, n, t, {
|
|
2071
2072
|
strict: r
|
|
2072
2073
|
});
|
|
2073
2074
|
}
|
|
2074
2075
|
function Ut(e, n, t) {
|
|
2075
2076
|
if (ae(e) !== t - n)
|
|
2076
|
-
throw new
|
|
2077
|
+
throw new ms({
|
|
2077
2078
|
offset: t,
|
|
2078
2079
|
position: "end",
|
|
2079
2080
|
size: ae(e)
|
|
2080
2081
|
});
|
|
2081
2082
|
}
|
|
2082
|
-
function
|
|
2083
|
+
function Yi(e, n, t, { strict: r } = {}) {
|
|
2083
2084
|
const s = e.slice(n, t);
|
|
2084
2085
|
return r && Ut(s, n, t), s;
|
|
2085
2086
|
}
|
|
2086
|
-
function
|
|
2087
|
+
function Zi(e, n, t, { strict: r } = {}) {
|
|
2087
2088
|
const s = `0x${e.replace("0x", "").slice(n * 2, t * 2)}`;
|
|
2088
2089
|
return r && Ut(s, n, t), s;
|
|
2089
2090
|
}
|
|
2090
|
-
function
|
|
2091
|
+
function ki(e) {
|
|
2091
2092
|
const { authorizationList: n } = e;
|
|
2092
2093
|
if (n)
|
|
2093
2094
|
for (const t of n) {
|
|
@@ -2095,21 +2096,21 @@ function Oi(e) {
|
|
|
2095
2096
|
if (!Q(s))
|
|
2096
2097
|
throw new H({ address: s });
|
|
2097
2098
|
if (r < 0)
|
|
2098
|
-
throw new
|
|
2099
|
+
throw new He({ chainId: r });
|
|
2099
2100
|
}
|
|
2100
2101
|
Vn(e);
|
|
2101
2102
|
}
|
|
2102
|
-
function
|
|
2103
|
+
function Ji(e) {
|
|
2103
2104
|
const { blobVersionedHashes: n } = e;
|
|
2104
2105
|
if (n) {
|
|
2105
2106
|
if (n.length === 0)
|
|
2106
2107
|
throw new Ft();
|
|
2107
2108
|
for (const t of n) {
|
|
2108
|
-
const r = ae(t), s =
|
|
2109
|
+
const r = ae(t), s = Oe(Oi(t, 0, 1));
|
|
2109
2110
|
if (r !== 32)
|
|
2110
|
-
throw new
|
|
2111
|
+
throw new zi({ hash: t, size: r });
|
|
2111
2112
|
if (s !== Jt)
|
|
2112
|
-
throw new
|
|
2113
|
+
throw new wi({
|
|
2113
2114
|
hash: t,
|
|
2114
2115
|
version: s
|
|
2115
2116
|
});
|
|
@@ -2120,37 +2121,37 @@ function Yi(e) {
|
|
|
2120
2121
|
function Vn(e) {
|
|
2121
2122
|
const { chainId: n, maxPriorityFeePerGas: t, maxFeePerGas: r, to: s } = e;
|
|
2122
2123
|
if (n <= 0)
|
|
2123
|
-
throw new
|
|
2124
|
+
throw new He({ chainId: n });
|
|
2124
2125
|
if (s && !Q(s))
|
|
2125
2126
|
throw new H({ address: s });
|
|
2126
|
-
if (r && r >
|
|
2127
|
+
if (r && r > De)
|
|
2127
2128
|
throw new ee({ maxFeePerGas: r });
|
|
2128
2129
|
if (t && r && t > r)
|
|
2129
|
-
throw new
|
|
2130
|
+
throw new be({ maxFeePerGas: r, maxPriorityFeePerGas: t });
|
|
2130
2131
|
}
|
|
2131
|
-
function
|
|
2132
|
+
function Fi(e) {
|
|
2132
2133
|
const { chainId: n, maxPriorityFeePerGas: t, gasPrice: r, maxFeePerGas: s, to: o } = e;
|
|
2133
2134
|
if (n <= 0)
|
|
2134
|
-
throw new
|
|
2135
|
+
throw new He({ chainId: n });
|
|
2135
2136
|
if (o && !Q(o))
|
|
2136
2137
|
throw new H({ address: o });
|
|
2137
2138
|
if (t || s)
|
|
2138
|
-
throw new
|
|
2139
|
-
if (r && r >
|
|
2139
|
+
throw new h("`maxFeePerGas`/`maxPriorityFeePerGas` is not a valid EIP-2930 Transaction attribute.");
|
|
2140
|
+
if (r && r > De)
|
|
2140
2141
|
throw new ee({ maxFeePerGas: r });
|
|
2141
2142
|
}
|
|
2142
|
-
function
|
|
2143
|
+
function Di(e) {
|
|
2143
2144
|
const { chainId: n, maxPriorityFeePerGas: t, gasPrice: r, maxFeePerGas: s, to: o } = e;
|
|
2144
2145
|
if (o && !Q(o))
|
|
2145
2146
|
throw new H({ address: o });
|
|
2146
2147
|
if (typeof n < "u" && n <= 0)
|
|
2147
|
-
throw new
|
|
2148
|
+
throw new He({ chainId: n });
|
|
2148
2149
|
if (t || s)
|
|
2149
|
-
throw new
|
|
2150
|
-
if (r && r >
|
|
2150
|
+
throw new h("`maxFeePerGas`/`maxPriorityFeePerGas` is not a valid Legacy Transaction attribute.");
|
|
2151
|
+
if (r && r > De)
|
|
2151
2152
|
throw new ee({ maxFeePerGas: r });
|
|
2152
2153
|
}
|
|
2153
|
-
function
|
|
2154
|
+
function Hi(e) {
|
|
2154
2155
|
if (e.type)
|
|
2155
2156
|
return e.type;
|
|
2156
2157
|
if (typeof e.authorizationList < "u")
|
|
@@ -2161,9 +2162,9 @@ function Ji(e) {
|
|
|
2161
2162
|
return "eip1559";
|
|
2162
2163
|
if (typeof e.gasPrice < "u")
|
|
2163
2164
|
return typeof e.accessList < "u" ? "eip2930" : "legacy";
|
|
2164
|
-
throw new
|
|
2165
|
+
throw new Ks({ transaction: e });
|
|
2165
2166
|
}
|
|
2166
|
-
function
|
|
2167
|
+
function Qe(e) {
|
|
2167
2168
|
if (!e || e.length === 0)
|
|
2168
2169
|
return [];
|
|
2169
2170
|
const n = [];
|
|
@@ -2171,22 +2172,22 @@ function He(e) {
|
|
|
2171
2172
|
const { address: r, storageKeys: s } = e[t];
|
|
2172
2173
|
for (let o = 0; o < s.length; o++)
|
|
2173
2174
|
if (s[o].length - 2 !== 64)
|
|
2174
|
-
throw new
|
|
2175
|
+
throw new Gs({ storageKey: s[o] });
|
|
2175
2176
|
if (!Q(r, { strict: !1 }))
|
|
2176
2177
|
throw new H({ address: r });
|
|
2177
2178
|
n.push([r, s]);
|
|
2178
2179
|
}
|
|
2179
2180
|
return n;
|
|
2180
2181
|
}
|
|
2181
|
-
function
|
|
2182
|
-
const t =
|
|
2183
|
-
return t === "eip1559" ?
|
|
2182
|
+
function Qi(e, n) {
|
|
2183
|
+
const t = Hi(e);
|
|
2184
|
+
return t === "eip1559" ? Gi(e, n) : t === "eip2930" ? Ui(e, n) : t === "eip4844" ? Ki(e, n) : t === "eip7702" ? qi(e, n) : Ri(e, n);
|
|
2184
2185
|
}
|
|
2185
|
-
function
|
|
2186
|
+
function qi(e, n) {
|
|
2186
2187
|
const { authorizationList: t, chainId: r, gas: s, nonce: o, to: c, value: a, maxFeePerGas: l, maxPriorityFeePerGas: A, accessList: d, data: f } = e;
|
|
2187
|
-
|
|
2188
|
-
const
|
|
2189
|
-
return
|
|
2188
|
+
ki(e);
|
|
2189
|
+
const u = Qe(d), g = Us(t);
|
|
2190
|
+
return Pe([
|
|
2190
2191
|
"0x04",
|
|
2191
2192
|
$([
|
|
2192
2193
|
z(r),
|
|
@@ -2197,29 +2198,29 @@ function Di(e, n) {
|
|
|
2197
2198
|
c ?? "0x",
|
|
2198
2199
|
a ? z(a) : "0x",
|
|
2199
2200
|
f ?? "0x",
|
|
2200
|
-
g,
|
|
2201
2201
|
u,
|
|
2202
|
-
|
|
2202
|
+
g,
|
|
2203
|
+
...Be(e, n)
|
|
2203
2204
|
])
|
|
2204
2205
|
]);
|
|
2205
2206
|
}
|
|
2206
|
-
function
|
|
2207
|
+
function Ki(e, n) {
|
|
2207
2208
|
const { chainId: t, gas: r, nonce: s, to: o, value: c, maxFeePerBlobGas: a, maxFeePerGas: l, maxPriorityFeePerGas: A, accessList: d, data: f } = e;
|
|
2208
|
-
|
|
2209
|
-
let
|
|
2210
|
-
if (e.blobs && (typeof
|
|
2211
|
-
const
|
|
2212
|
-
blobs:
|
|
2209
|
+
Ji(e);
|
|
2210
|
+
let u = e.blobVersionedHashes, g = e.sidecars;
|
|
2211
|
+
if (e.blobs && (typeof u > "u" || typeof g > "u")) {
|
|
2212
|
+
const b = typeof e.blobs[0] == "string" ? e.blobs : e.blobs.map((j) => q(j)), w = e.kzg, I = Et({
|
|
2213
|
+
blobs: b,
|
|
2213
2214
|
kzg: w
|
|
2214
2215
|
});
|
|
2215
|
-
if (typeof
|
|
2216
|
+
if (typeof u > "u" && (u = pi({
|
|
2216
2217
|
commitments: I
|
|
2217
|
-
})), typeof
|
|
2218
|
-
const j = Lt({ blobs:
|
|
2219
|
-
|
|
2218
|
+
})), typeof g > "u") {
|
|
2219
|
+
const j = Lt({ blobs: b, commitments: I, kzg: w });
|
|
2220
|
+
g = Pi({ blobs: b, commitments: I, proofs: j });
|
|
2220
2221
|
}
|
|
2221
2222
|
}
|
|
2222
|
-
const x =
|
|
2223
|
+
const x = Qe(d), v = [
|
|
2223
2224
|
z(t),
|
|
2224
2225
|
s ? z(s) : "0x",
|
|
2225
2226
|
A ? z(A) : "0x",
|
|
@@ -2230,24 +2231,24 @@ function Hi(e, n) {
|
|
|
2230
2231
|
f ?? "0x",
|
|
2231
2232
|
x,
|
|
2232
2233
|
a ? z(a) : "0x",
|
|
2233
|
-
|
|
2234
|
-
...
|
|
2235
|
-
], m = [],
|
|
2236
|
-
if (
|
|
2237
|
-
for (let
|
|
2238
|
-
const { blob: w, commitment: I, proof: j } =
|
|
2239
|
-
m.push(w),
|
|
2234
|
+
u ?? [],
|
|
2235
|
+
...Be(e, n)
|
|
2236
|
+
], m = [], p = [], y = [];
|
|
2237
|
+
if (g)
|
|
2238
|
+
for (let b = 0; b < g.length; b++) {
|
|
2239
|
+
const { blob: w, commitment: I, proof: j } = g[b];
|
|
2240
|
+
m.push(w), p.push(I), y.push(j);
|
|
2240
2241
|
}
|
|
2241
|
-
return
|
|
2242
|
+
return Pe([
|
|
2242
2243
|
"0x03",
|
|
2243
2244
|
// If sidecars are enabled, envelope turns into a "wrapper":
|
|
2244
|
-
$(
|
|
2245
|
+
$(g ? [v, m, p, y] : v)
|
|
2245
2246
|
]);
|
|
2246
2247
|
}
|
|
2247
|
-
function
|
|
2248
|
+
function Gi(e, n) {
|
|
2248
2249
|
const { chainId: t, gas: r, nonce: s, to: o, value: c, maxFeePerGas: a, maxPriorityFeePerGas: l, accessList: A, data: d } = e;
|
|
2249
2250
|
Vn(e);
|
|
2250
|
-
const f =
|
|
2251
|
+
const f = Qe(A), u = [
|
|
2251
2252
|
z(t),
|
|
2252
2253
|
s ? z(s) : "0x",
|
|
2253
2254
|
l ? z(l) : "0x",
|
|
@@ -2257,17 +2258,17 @@ function Qi(e, n) {
|
|
|
2257
2258
|
c ? z(c) : "0x",
|
|
2258
2259
|
d ?? "0x",
|
|
2259
2260
|
f,
|
|
2260
|
-
...
|
|
2261
|
+
...Be(e, n)
|
|
2261
2262
|
];
|
|
2262
|
-
return
|
|
2263
|
+
return Pe([
|
|
2263
2264
|
"0x02",
|
|
2264
|
-
$(
|
|
2265
|
+
$(u)
|
|
2265
2266
|
]);
|
|
2266
2267
|
}
|
|
2267
|
-
function
|
|
2268
|
+
function Ui(e, n) {
|
|
2268
2269
|
const { chainId: t, gas: r, data: s, nonce: o, to: c, value: a, accessList: l, gasPrice: A } = e;
|
|
2269
|
-
|
|
2270
|
-
const d =
|
|
2270
|
+
Fi(e);
|
|
2271
|
+
const d = Qe(l), f = [
|
|
2271
2272
|
z(t),
|
|
2272
2273
|
o ? z(o) : "0x",
|
|
2273
2274
|
A ? z(A) : "0x",
|
|
@@ -2276,16 +2277,16 @@ function qi(e, n) {
|
|
|
2276
2277
|
a ? z(a) : "0x",
|
|
2277
2278
|
s ?? "0x",
|
|
2278
2279
|
d,
|
|
2279
|
-
...
|
|
2280
|
+
...Be(e, n)
|
|
2280
2281
|
];
|
|
2281
|
-
return
|
|
2282
|
+
return Pe([
|
|
2282
2283
|
"0x01",
|
|
2283
2284
|
$(f)
|
|
2284
2285
|
]);
|
|
2285
2286
|
}
|
|
2286
|
-
function
|
|
2287
|
+
function Ri(e, n) {
|
|
2287
2288
|
const { chainId: t = 0, gas: r, data: s, nonce: o, to: c, value: a, gasPrice: l } = e;
|
|
2288
|
-
|
|
2289
|
+
Di(e);
|
|
2289
2290
|
let A = [
|
|
2290
2291
|
o ? z(o) : "0x",
|
|
2291
2292
|
l ? z(l) : "0x",
|
|
@@ -2300,16 +2301,16 @@ function Ki(e, n) {
|
|
|
2300
2301
|
return (n.v - 35n) / 2n > 0 ? n.v : 27n + (n.v === 35n ? 0n : 1n);
|
|
2301
2302
|
if (t > 0)
|
|
2302
2303
|
return BigInt(t * 2) + BigInt(35n + n.v - 27n);
|
|
2303
|
-
const
|
|
2304
|
-
if (n.v !==
|
|
2305
|
-
throw new
|
|
2306
|
-
return
|
|
2307
|
-
})(), f =
|
|
2304
|
+
const g = 27n + (n.v === 27n ? 0n : 1n);
|
|
2305
|
+
if (n.v !== g)
|
|
2306
|
+
throw new qs({ v: n.v });
|
|
2307
|
+
return g;
|
|
2308
|
+
})(), f = Se(n.r), u = Se(n.s);
|
|
2308
2309
|
A = [
|
|
2309
2310
|
...A,
|
|
2310
2311
|
z(d),
|
|
2311
2312
|
f === "0x00" ? "0x" : f,
|
|
2312
|
-
|
|
2313
|
+
u === "0x00" ? "0x" : u
|
|
2313
2314
|
];
|
|
2314
2315
|
} else t > 0 && (A = [
|
|
2315
2316
|
...A,
|
|
@@ -2319,7 +2320,7 @@ function Ki(e, n) {
|
|
|
2319
2320
|
]);
|
|
2320
2321
|
return $(A);
|
|
2321
2322
|
}
|
|
2322
|
-
function
|
|
2323
|
+
function Be(e, n) {
|
|
2323
2324
|
const t = n ?? e, { v: r, yParity: s } = t;
|
|
2324
2325
|
if (typeof t.r > "u")
|
|
2325
2326
|
return [];
|
|
@@ -2327,10 +2328,10 @@ function Pe(e, n) {
|
|
|
2327
2328
|
return [];
|
|
2328
2329
|
if (typeof r > "u" && typeof s > "u")
|
|
2329
2330
|
return [];
|
|
2330
|
-
const o =
|
|
2331
|
+
const o = Se(t.r), c = Se(t.s);
|
|
2331
2332
|
return [typeof s == "number" ? s ? z(1) : "0x" : r === 0n ? "0x" : r === 1n ? z(1) : r === 27n ? "0x" : z(1), o === "0x00" ? "0x" : o, c === "0x00" ? "0x" : c];
|
|
2332
2333
|
}
|
|
2333
|
-
const
|
|
2334
|
+
const _i = {
|
|
2334
2335
|
gasPriceOracle: { address: "0x420000000000000000000000000000000000000F" },
|
|
2335
2336
|
l1Block: { address: "0x4200000000000000000000000000000000000015" },
|
|
2336
2337
|
l2CrossDomainMessenger: {
|
|
@@ -2341,8 +2342,8 @@ const Gi = {
|
|
|
2341
2342
|
l2ToL1MessagePasser: {
|
|
2342
2343
|
address: "0x4200000000000000000000000000000000000016"
|
|
2343
2344
|
}
|
|
2344
|
-
},
|
|
2345
|
-
block: /* @__PURE__ */
|
|
2345
|
+
}, $i = {
|
|
2346
|
+
block: /* @__PURE__ */ Vs({
|
|
2346
2347
|
format(e) {
|
|
2347
2348
|
return {
|
|
2348
2349
|
transactions: e.transactions?.map((t) => {
|
|
@@ -2355,13 +2356,13 @@ const Gi = {
|
|
|
2355
2356
|
};
|
|
2356
2357
|
}
|
|
2357
2358
|
}),
|
|
2358
|
-
transaction: /* @__PURE__ */
|
|
2359
|
+
transaction: /* @__PURE__ */ hs({
|
|
2359
2360
|
format(e) {
|
|
2360
2361
|
const n = {};
|
|
2361
2362
|
return e.type === "0x7e" && (n.isSystemTx = e.isSystemTx, n.mint = e.mint ? se(e.mint) : void 0, n.sourceHash = e.sourceHash, n.type = "deposit"), n;
|
|
2362
2363
|
}
|
|
2363
2364
|
}),
|
|
2364
|
-
transactionReceipt: /* @__PURE__ */
|
|
2365
|
+
transactionReceipt: /* @__PURE__ */ Ts({
|
|
2365
2366
|
format(e) {
|
|
2366
2367
|
return {
|
|
2367
2368
|
l1GasPrice: e.l1GasPrice ? se(e.l1GasPrice) : null,
|
|
@@ -2372,45 +2373,45 @@ const Gi = {
|
|
|
2372
2373
|
}
|
|
2373
2374
|
})
|
|
2374
2375
|
};
|
|
2375
|
-
function
|
|
2376
|
-
return
|
|
2376
|
+
function eo(e, n) {
|
|
2377
|
+
return ro(e) ? to(e) : Qi(e, n);
|
|
2377
2378
|
}
|
|
2378
|
-
const
|
|
2379
|
-
transaction:
|
|
2379
|
+
const no = {
|
|
2380
|
+
transaction: eo
|
|
2380
2381
|
};
|
|
2381
|
-
function
|
|
2382
|
-
|
|
2382
|
+
function to(e) {
|
|
2383
|
+
so(e);
|
|
2383
2384
|
const { sourceHash: n, data: t, from: r, gas: s, isSystemTx: o, mint: c, to: a, value: l } = e, A = [
|
|
2384
2385
|
n,
|
|
2385
2386
|
r,
|
|
2386
2387
|
a ?? "0x",
|
|
2387
|
-
c ?
|
|
2388
|
-
l ?
|
|
2389
|
-
s ?
|
|
2388
|
+
c ? me(c) : "0x",
|
|
2389
|
+
l ? me(l) : "0x",
|
|
2390
|
+
s ? me(s) : "0x",
|
|
2390
2391
|
o ? "0x1" : "0x",
|
|
2391
2392
|
t ?? "0x"
|
|
2392
2393
|
];
|
|
2393
|
-
return
|
|
2394
|
+
return Pe([
|
|
2394
2395
|
"0x7e",
|
|
2395
2396
|
$(A)
|
|
2396
2397
|
]);
|
|
2397
2398
|
}
|
|
2398
|
-
function
|
|
2399
|
+
function ro(e) {
|
|
2399
2400
|
return e.type === "deposit" || typeof e.sourceHash < "u";
|
|
2400
2401
|
}
|
|
2401
|
-
function
|
|
2402
|
+
function so(e) {
|
|
2402
2403
|
const { from: n, to: t } = e;
|
|
2403
2404
|
if (n && !Q(n))
|
|
2404
2405
|
throw new H({ address: n });
|
|
2405
2406
|
if (t && !Q(t))
|
|
2406
2407
|
throw new H({ address: t });
|
|
2407
2408
|
}
|
|
2408
|
-
const
|
|
2409
|
+
const Ze = {
|
|
2409
2410
|
blockTime: 2e3,
|
|
2410
|
-
contracts:
|
|
2411
|
-
formatters:
|
|
2412
|
-
serializers:
|
|
2413
|
-
},
|
|
2411
|
+
contracts: _i,
|
|
2412
|
+
formatters: $i,
|
|
2413
|
+
serializers: no
|
|
2414
|
+
}, io = /* @__PURE__ */ U({
|
|
2414
2415
|
id: 42161,
|
|
2415
2416
|
name: "Arbitrum One",
|
|
2416
2417
|
nativeCurrency: { name: "Ether", symbol: "ETH", decimals: 18 },
|
|
@@ -2434,7 +2435,7 @@ const Ye = {
|
|
|
2434
2435
|
}
|
|
2435
2436
|
}
|
|
2436
2437
|
}), ge = 1, Rt = /* @__PURE__ */ U({
|
|
2437
|
-
...
|
|
2438
|
+
...Ze,
|
|
2438
2439
|
id: 8453,
|
|
2439
2440
|
name: "Base",
|
|
2440
2441
|
nativeCurrency: { name: "Ether", symbol: "ETH", decimals: 18 },
|
|
@@ -2451,7 +2452,7 @@ const Ye = {
|
|
|
2451
2452
|
}
|
|
2452
2453
|
},
|
|
2453
2454
|
contracts: {
|
|
2454
|
-
...
|
|
2455
|
+
...Ze.contracts,
|
|
2455
2456
|
disputeGameFactory: {
|
|
2456
2457
|
[ge]: {
|
|
2457
2458
|
address: "0x43edB88C4B80fDD2AdFF2412A7BebF9dF42cB40e"
|
|
@@ -2484,7 +2485,7 @@ const Ye = {
|
|
|
2484
2485
|
({
|
|
2485
2486
|
...Rt
|
|
2486
2487
|
});
|
|
2487
|
-
const
|
|
2488
|
+
const oo = /* @__PURE__ */ U({
|
|
2488
2489
|
id: 56,
|
|
2489
2490
|
name: "BNB Smart Chain",
|
|
2490
2491
|
blockTime: 750,
|
|
@@ -2513,7 +2514,7 @@ const ro = /* @__PURE__ */ U({
|
|
|
2513
2514
|
function Xn(e) {
|
|
2514
2515
|
return typeof e == "string" ? { address: e, type: "json-rpc" } : e;
|
|
2515
2516
|
}
|
|
2516
|
-
class
|
|
2517
|
+
class co extends h {
|
|
2517
2518
|
constructor({ docsPath: n } = {}) {
|
|
2518
2519
|
super([
|
|
2519
2520
|
"Could not find an Account to execute with this Action.",
|
|
@@ -2530,7 +2531,7 @@ function _n(e) {
|
|
|
2530
2531
|
return e.reduce((n, { slot: t, value: r }) => `${n} ${t}: ${r}
|
|
2531
2532
|
`, "");
|
|
2532
2533
|
}
|
|
2533
|
-
function
|
|
2534
|
+
function ao(e) {
|
|
2534
2535
|
return e.reduce((n, { address: t, ...r }) => {
|
|
2535
2536
|
let s = `${n} ${t}:
|
|
2536
2537
|
`;
|
|
@@ -2543,13 +2544,13 @@ function io(e) {
|
|
|
2543
2544
|
}, ` State Override:
|
|
2544
2545
|
`).slice(0, -1);
|
|
2545
2546
|
}
|
|
2546
|
-
class
|
|
2547
|
-
constructor(n, { account: t, docsPath: r, chain: s, data: o, gas: c, gasPrice: a, maxFeePerGas: l, maxPriorityFeePerGas: A, nonce: d, to: f, value:
|
|
2547
|
+
class lo extends h {
|
|
2548
|
+
constructor(n, { account: t, docsPath: r, chain: s, data: o, gas: c, gasPrice: a, maxFeePerGas: l, maxPriorityFeePerGas: A, nonce: d, to: f, value: u, stateOverride: g }) {
|
|
2548
2549
|
const x = t ? Xn(t) : void 0;
|
|
2549
|
-
let
|
|
2550
|
+
let v = Tt({
|
|
2550
2551
|
from: x?.address,
|
|
2551
2552
|
to: f,
|
|
2552
|
-
value: typeof
|
|
2553
|
+
value: typeof u < "u" && `${Hs(u)} ${s?.nativeCurrency?.symbol || "ETH"}`,
|
|
2553
2554
|
data: o,
|
|
2554
2555
|
gas: c,
|
|
2555
2556
|
gasPrice: typeof a < "u" && `${R(a)} gwei`,
|
|
@@ -2557,14 +2558,14 @@ class oo extends y {
|
|
|
2557
2558
|
maxPriorityFeePerGas: typeof A < "u" && `${R(A)} gwei`,
|
|
2558
2559
|
nonce: d
|
|
2559
2560
|
});
|
|
2560
|
-
|
|
2561
|
-
${
|
|
2561
|
+
g && (v += `
|
|
2562
|
+
${ao(g)}`), super(n.shortMessage, {
|
|
2562
2563
|
cause: n,
|
|
2563
2564
|
docsPath: r,
|
|
2564
2565
|
metaMessages: [
|
|
2565
2566
|
...n.metaMessages ? [...n.metaMessages, " "] : [],
|
|
2566
2567
|
"Raw Call Arguments:",
|
|
2567
|
-
|
|
2568
|
+
v
|
|
2568
2569
|
].filter(Boolean),
|
|
2569
2570
|
name: "CallExecutionError"
|
|
2570
2571
|
}), Object.defineProperty(this, "cause", {
|
|
@@ -2575,9 +2576,9 @@ ${io(u)}`), super(n.shortMessage, {
|
|
|
2575
2576
|
}), this.cause = n;
|
|
2576
2577
|
}
|
|
2577
2578
|
}
|
|
2578
|
-
function
|
|
2579
|
-
const t = (e.details || "").toLowerCase(), r = e instanceof
|
|
2580
|
-
return r instanceof
|
|
2579
|
+
function Ao(e, n) {
|
|
2580
|
+
const t = (e.details || "").toLowerCase(), r = e instanceof h ? e.walk((s) => s?.code === ie.code) : e;
|
|
2581
|
+
return r instanceof h ? new ie({
|
|
2581
2582
|
cause: e,
|
|
2582
2583
|
message: r.details
|
|
2583
2584
|
}) : ie.nodeMessage.test(t) ? new ie({
|
|
@@ -2589,7 +2590,7 @@ function co(e, n) {
|
|
|
2589
2590
|
}) : ln.nodeMessage.test(t) ? new ln({
|
|
2590
2591
|
cause: e,
|
|
2591
2592
|
maxFeePerGas: n?.maxFeePerGas
|
|
2592
|
-
}) : An.nodeMessage.test(t) ? new An({ cause: e, nonce: n?.nonce }) : dn.nodeMessage.test(t) ? new dn({ cause: e, nonce: n?.nonce }) : fn.nodeMessage.test(t) ? new fn({ cause: e, nonce: n?.nonce }) : un.nodeMessage.test(t) ? new un({ cause: e }) : gn.nodeMessage.test(t) ? new gn({ cause: e, gas: n?.gas }) : vn.nodeMessage.test(t) ? new vn({ cause: e, gas: n?.gas }) : Cn.nodeMessage.test(t) ? new Cn({ cause: e }) :
|
|
2593
|
+
}) : An.nodeMessage.test(t) ? new An({ cause: e, nonce: n?.nonce }) : dn.nodeMessage.test(t) ? new dn({ cause: e, nonce: n?.nonce }) : fn.nodeMessage.test(t) ? new fn({ cause: e, nonce: n?.nonce }) : un.nodeMessage.test(t) ? new un({ cause: e }) : gn.nodeMessage.test(t) ? new gn({ cause: e, gas: n?.gas }) : vn.nodeMessage.test(t) ? new vn({ cause: e, gas: n?.gas }) : Cn.nodeMessage.test(t) ? new Cn({ cause: e }) : be.nodeMessage.test(t) ? new be({
|
|
2593
2594
|
cause: e,
|
|
2594
2595
|
maxFeePerGas: n?.maxFeePerGas,
|
|
2595
2596
|
maxPriorityFeePerGas: n?.maxPriorityFeePerGas
|
|
@@ -2597,17 +2598,17 @@ function co(e, n) {
|
|
|
2597
2598
|
cause: e
|
|
2598
2599
|
});
|
|
2599
2600
|
}
|
|
2600
|
-
function
|
|
2601
|
+
function fo(e, { docsPath: n, ...t }) {
|
|
2601
2602
|
const r = (() => {
|
|
2602
|
-
const s =
|
|
2603
|
+
const s = Ao(e, t);
|
|
2603
2604
|
return s instanceof Dt ? e : s;
|
|
2604
2605
|
})();
|
|
2605
|
-
return new
|
|
2606
|
+
return new lo(r, {
|
|
2606
2607
|
docsPath: n,
|
|
2607
2608
|
...t
|
|
2608
2609
|
});
|
|
2609
2610
|
}
|
|
2610
|
-
function
|
|
2611
|
+
function uo(e, { format: n }) {
|
|
2611
2612
|
if (!n)
|
|
2612
2613
|
return {};
|
|
2613
2614
|
const t = {};
|
|
@@ -2619,30 +2620,30 @@ function lo(e, { format: n }) {
|
|
|
2619
2620
|
const s = n(e || {});
|
|
2620
2621
|
return r(s), t;
|
|
2621
2622
|
}
|
|
2622
|
-
function
|
|
2623
|
+
function go(e) {
|
|
2623
2624
|
const { account: n, gasPrice: t, maxFeePerGas: r, maxPriorityFeePerGas: s, to: o } = e, c = n ? Xn(n) : void 0;
|
|
2624
2625
|
if (c && !Q(c.address))
|
|
2625
2626
|
throw new H({ address: c.address });
|
|
2626
2627
|
if (o && !Q(o))
|
|
2627
2628
|
throw new H({ address: o });
|
|
2628
2629
|
if (typeof t < "u" && (typeof r < "u" || typeof s < "u"))
|
|
2629
|
-
throw new
|
|
2630
|
-
if (r && r >
|
|
2630
|
+
throw new Qs();
|
|
2631
|
+
if (r && r > De)
|
|
2631
2632
|
throw new ee({ maxFeePerGas: r });
|
|
2632
2633
|
if (s && r && s > r)
|
|
2633
|
-
throw new
|
|
2634
|
+
throw new be({ maxFeePerGas: r, maxPriorityFeePerGas: s });
|
|
2634
2635
|
}
|
|
2635
|
-
async function
|
|
2636
|
+
async function vo(e, n) {
|
|
2636
2637
|
const { account: t = e.account } = n;
|
|
2637
2638
|
if (!t)
|
|
2638
|
-
throw new
|
|
2639
|
+
throw new co();
|
|
2639
2640
|
const r = Xn(t);
|
|
2640
2641
|
try {
|
|
2641
|
-
const { accessList: s, blockNumber: o, blockTag: c, data: a, gas: l, gasPrice: A, maxFeePerGas: d, maxPriorityFeePerGas: f, nonce:
|
|
2642
|
-
|
|
2643
|
-
const
|
|
2642
|
+
const { accessList: s, blockNumber: o, blockTag: c, data: a, gas: l, gasPrice: A, maxFeePerGas: d, maxPriorityFeePerGas: f, nonce: u, to: g, value: x, ...v } = n, p = (typeof o == "bigint" ? z(o) : void 0) || c;
|
|
2643
|
+
go(n);
|
|
2644
|
+
const y = e.chain?.formatters?.transactionRequest?.format, w = (y || Ls)({
|
|
2644
2645
|
// Pick out extra data that might exist on the chain's transaction request type.
|
|
2645
|
-
...
|
|
2646
|
+
...uo(v, { format: y }),
|
|
2646
2647
|
from: r?.address,
|
|
2647
2648
|
accessList: s,
|
|
2648
2649
|
data: a,
|
|
@@ -2650,27 +2651,27 @@ async function fo(e, n) {
|
|
|
2650
2651
|
gasPrice: A,
|
|
2651
2652
|
maxFeePerGas: d,
|
|
2652
2653
|
maxPriorityFeePerGas: f,
|
|
2653
|
-
nonce:
|
|
2654
|
-
to:
|
|
2654
|
+
nonce: u,
|
|
2655
|
+
to: g,
|
|
2655
2656
|
value: x
|
|
2656
|
-
}, "estimateGas"), { baseFeePerGas: I, gasLimit: j, priorityFeePerGas:
|
|
2657
|
+
}, "estimateGas"), { baseFeePerGas: I, gasLimit: j, priorityFeePerGas: M } = await e.request({
|
|
2657
2658
|
method: "linea_estimateGas",
|
|
2658
|
-
params:
|
|
2659
|
+
params: p ? [w, p] : [w]
|
|
2659
2660
|
});
|
|
2660
2661
|
return {
|
|
2661
2662
|
baseFeePerGas: BigInt(I),
|
|
2662
2663
|
gasLimit: BigInt(j),
|
|
2663
|
-
priorityFeePerGas: BigInt(
|
|
2664
|
+
priorityFeePerGas: BigInt(M)
|
|
2664
2665
|
};
|
|
2665
2666
|
} catch (s) {
|
|
2666
|
-
throw
|
|
2667
|
+
throw fo(s, {
|
|
2667
2668
|
...n,
|
|
2668
2669
|
account: r,
|
|
2669
2670
|
chain: e.chain
|
|
2670
2671
|
});
|
|
2671
2672
|
}
|
|
2672
2673
|
}
|
|
2673
|
-
const
|
|
2674
|
+
const Co = {
|
|
2674
2675
|
fees: {
|
|
2675
2676
|
estimateFeesPerGas: $n,
|
|
2676
2677
|
async maxPriorityFeePerGas({ block: e, client: n, request: t }) {
|
|
@@ -2687,7 +2688,7 @@ const uo = {
|
|
|
2687
2688
|
};
|
|
2688
2689
|
async function $n({ client: e, multiply: n, request: t, type: r }) {
|
|
2689
2690
|
try {
|
|
2690
|
-
const s = await
|
|
2691
|
+
const s = await vo(e, {
|
|
2691
2692
|
...t,
|
|
2692
2693
|
account: t?.account
|
|
2693
2694
|
}), { priorityFeePerGas: o } = s, a = n(BigInt(s.baseFeePerGas)) + o;
|
|
@@ -2699,8 +2700,8 @@ async function $n({ client: e, multiply: n, request: t, type: r }) {
|
|
|
2699
2700
|
return null;
|
|
2700
2701
|
}
|
|
2701
2702
|
}
|
|
2702
|
-
const
|
|
2703
|
-
...
|
|
2703
|
+
const mo = /* @__PURE__ */ U({
|
|
2704
|
+
...Co,
|
|
2704
2705
|
id: 59144,
|
|
2705
2706
|
name: "Linea Mainnet",
|
|
2706
2707
|
nativeCurrency: { name: "Linea Ether", symbol: "ETH", decimals: 18 },
|
|
@@ -2733,7 +2734,7 @@ const go = /* @__PURE__ */ U({
|
|
|
2733
2734
|
},
|
|
2734
2735
|
ensTlds: [".linea.eth"],
|
|
2735
2736
|
testnet: !1
|
|
2736
|
-
}),
|
|
2737
|
+
}), xo = /* @__PURE__ */ U({
|
|
2737
2738
|
id: 1,
|
|
2738
2739
|
name: "Ethereum",
|
|
2739
2740
|
nativeCurrency: { name: "Ether", symbol: "ETH", decimals: 18 },
|
|
@@ -2760,8 +2761,8 @@ const go = /* @__PURE__ */ U({
|
|
|
2760
2761
|
blockCreated: 14353601
|
|
2761
2762
|
}
|
|
2762
2763
|
}
|
|
2763
|
-
}), ve = 1,
|
|
2764
|
-
...
|
|
2764
|
+
}), ve = 1, po = /* @__PURE__ */ U({
|
|
2765
|
+
...Ze,
|
|
2765
2766
|
id: 10,
|
|
2766
2767
|
name: "OP Mainnet",
|
|
2767
2768
|
nativeCurrency: { name: "Ether", symbol: "ETH", decimals: 18 },
|
|
@@ -2778,7 +2779,7 @@ const go = /* @__PURE__ */ U({
|
|
|
2778
2779
|
}
|
|
2779
2780
|
},
|
|
2780
2781
|
contracts: {
|
|
2781
|
-
...
|
|
2782
|
+
...Ze.contracts,
|
|
2782
2783
|
disputeGameFactory: {
|
|
2783
2784
|
[ve]: {
|
|
2784
2785
|
address: "0xe5965Ab5962eDc7477C8520243A95517CD252fA9"
|
|
@@ -2805,7 +2806,7 @@ const go = /* @__PURE__ */ U({
|
|
|
2805
2806
|
}
|
|
2806
2807
|
},
|
|
2807
2808
|
sourceId: ve
|
|
2808
|
-
}),
|
|
2809
|
+
}), bo = /* @__PURE__ */ U({
|
|
2809
2810
|
id: 137,
|
|
2810
2811
|
name: "Polygon",
|
|
2811
2812
|
nativeCurrency: { name: "POL", symbol: "POL", decimals: 18 },
|
|
@@ -2827,18 +2828,18 @@ const go = /* @__PURE__ */ U({
|
|
|
2827
2828
|
blockCreated: 25770160
|
|
2828
2829
|
}
|
|
2829
2830
|
}
|
|
2830
|
-
}),
|
|
2831
|
-
evm: [
|
|
2831
|
+
}), Ne = {
|
|
2832
|
+
evm: [xo, oo, po, io, mo, Rt, bo],
|
|
2832
2833
|
solana: [
|
|
2833
2834
|
{
|
|
2834
2835
|
name: "Solana",
|
|
2835
|
-
icon:
|
|
2836
|
+
icon: Fe
|
|
2836
2837
|
}
|
|
2837
2838
|
],
|
|
2838
2839
|
aptos: [
|
|
2839
2840
|
{
|
|
2840
2841
|
name: "Aptos",
|
|
2841
|
-
icon:
|
|
2842
|
+
icon: Je
|
|
2842
2843
|
}
|
|
2843
2844
|
]
|
|
2844
2845
|
}, _t = (e, n) => {
|
|
@@ -2850,7 +2851,7 @@ const go = /* @__PURE__ */ U({
|
|
|
2850
2851
|
},
|
|
2851
2852
|
chainType: "aptos",
|
|
2852
2853
|
provider: n?.aptos || null
|
|
2853
|
-
})), r = (e?.evm ||
|
|
2854
|
+
})), r = (e?.evm || Ne?.evm || [O?.evm || []]).map((a) => ({
|
|
2854
2855
|
...a,
|
|
2855
2856
|
chainInfo: {
|
|
2856
2857
|
icon: It[`evm_${a.id}`],
|
|
@@ -2877,13 +2878,13 @@ const go = /* @__PURE__ */ U({
|
|
|
2877
2878
|
}));
|
|
2878
2879
|
return [...t, ...r, ...s, ...o];
|
|
2879
2880
|
};
|
|
2880
|
-
var
|
|
2881
|
-
const
|
|
2881
|
+
var je = /* @__PURE__ */ ((e) => (e.Tomo = "tomo", e.MyDoge = "mydoge", e))(je || {}), P = /* @__PURE__ */ ((e) => (e.Loading = "LOADING", e.Logged = "LOGGED", e.WalletList = "WALLET_LIST", e.WalletSearch = "WALLET_SEARCH", e.WalletSelectProviders = "WALLET_SELECT_PROVIDERS", e.WalletInstallGuide = "WALLET_INSTALL_GUIDE", e.Connecting = "CONNECTING", e.Error = "ERROR", e.Account = "ACCOUNT", e.SelectChains = "SELECT_CHAINS", e.ChangeNetwork = "CHANGE_NETWORK", e.SignInWallet = "SIGN_IN_WALLET", e.WalletConnect = "WALLET_CONNECT", e.UnsupportChain = "UNSUPPORT_CHAIN", e.SocialLogin = "SOCIAL_LOGIN", e.MyDogeSocialLogin = "MYDOGE_SOCIAL_LOGIN", e))(P || {}), k = /* @__PURE__ */ ((e) => (e.All = "all", e.EVM = "evm", e.Solana = "solana", e.Aptos = "aptos", e))(k || {});
|
|
2882
|
+
const zo = ({ title: e, onBack: n, onClose: t, rightContent: r, hideCloseButton: s }) => {
|
|
2882
2883
|
const o = B(() => n ? /* @__PURE__ */ i(X, { isIconOnly: !0, color: "default", size: "sm", variant: "light", onPress: n, radius: "full", className: "p-0", children: /* @__PURE__ */ i(ct, {}) }) : null, [n]);
|
|
2883
|
-
return /* @__PURE__ */
|
|
2884
|
+
return /* @__PURE__ */ C("div", { className: "flex items-center justify-between px-0 py-3", children: [
|
|
2884
2885
|
o,
|
|
2885
2886
|
/* @__PURE__ */ i("div", { className: "font-medium text-lg", children: e }),
|
|
2886
|
-
/* @__PURE__ */
|
|
2887
|
+
/* @__PURE__ */ C("div", { className: "flex items-center gap-3", children: [
|
|
2887
2888
|
r,
|
|
2888
2889
|
s ? null : /* @__PURE__ */ i(X, { isIconOnly: !0, color: "default", size: "sm", variant: "light", onPress: t, radius: "full", className: "p-0", children: /* @__PURE__ */ i(at, { className: "text-xl" }) })
|
|
2889
2890
|
] })
|
|
@@ -2896,12 +2897,12 @@ const xo = ({ title: e, onBack: n, onClose: t, rightContent: r, hideCloseButton:
|
|
|
2896
2897
|
headerRightContent: s,
|
|
2897
2898
|
hideCloseButton: o
|
|
2898
2899
|
}) => {
|
|
2899
|
-
const c = V(
|
|
2900
|
+
const c = V(W);
|
|
2900
2901
|
if (!c)
|
|
2901
2902
|
throw new Error("WalletConnectContext not found");
|
|
2902
|
-
return /* @__PURE__ */
|
|
2903
|
+
return /* @__PURE__ */ C("div", { className: "flex flex-col gap-3 min-h-0 flex-1", children: [
|
|
2903
2904
|
/* @__PURE__ */ i(
|
|
2904
|
-
|
|
2905
|
+
zo,
|
|
2905
2906
|
{
|
|
2906
2907
|
title: n,
|
|
2907
2908
|
onBack: t,
|
|
@@ -2914,28 +2915,28 @@ const xo = ({ title: e, onBack: n, onClose: t, rightContent: r, hideCloseButton:
|
|
|
2914
2915
|
),
|
|
2915
2916
|
/* @__PURE__ */ i("div", { className: "flex-1 flex flex-col min-h-0", children: e })
|
|
2916
2917
|
] });
|
|
2917
|
-
},
|
|
2918
|
-
const e = V(
|
|
2918
|
+
}, wo = () => {
|
|
2919
|
+
const e = V(W);
|
|
2919
2920
|
if (!e)
|
|
2920
2921
|
throw new Error("WalletConnectContext not found");
|
|
2921
|
-
const { copied: n, copy: t } = In(), { account: r, disconnect: s } = e, o = r.currentWallet?.info?.name || "Wallet", c = r.currentWallet?.info?.icon, a = r.address, l = r.chainType, A = r.chainId, d = A ? Number(BigInt(A || "0").toString()) : void 0, f = r.currentWallet,
|
|
2922
|
+
const { copied: n, copy: t } = In(), { account: r, disconnect: s } = e, o = r.currentWallet?.info?.name || "Wallet", c = r.currentWallet?.info?.icon, a = r.address, l = r.chainType, A = r.chainId, d = A ? Number(BigInt(A || "0").toString()) : void 0, f = r.currentWallet, u = T(async () => {
|
|
2922
2923
|
try {
|
|
2923
2924
|
if (!a) return;
|
|
2924
2925
|
t(a);
|
|
2925
2926
|
} catch (m) {
|
|
2926
2927
|
console.error("Failed to copy address:", m);
|
|
2927
2928
|
}
|
|
2928
|
-
}, [a, t]),
|
|
2929
|
+
}, [a, t]), g = B(() => /* @__PURE__ */ i(X, { isIconOnly: !0, variant: "light", color: "default", className: "size-10", onPress: u, children: n ? /* @__PURE__ */ i(lt, { className: "text-success size-6" }) : /* @__PURE__ */ i(wr, { className: "text-foreground size-4" }) }), [u, n]);
|
|
2929
2930
|
if (!f)
|
|
2930
2931
|
return null;
|
|
2931
|
-
const x = _t(e.config?.chains, f?.providers),
|
|
2932
|
+
const x = _t(e.config?.chains, f?.providers), v = x.find((m) => m.chainType === l && m.id === d);
|
|
2932
2933
|
return console.log("--- AccountView ---", {
|
|
2933
2934
|
config: e.config,
|
|
2934
2935
|
chains: x,
|
|
2935
2936
|
currentChainType: l,
|
|
2936
2937
|
chainNumber: d,
|
|
2937
2938
|
currentWallet: f,
|
|
2938
|
-
currentChain:
|
|
2939
|
+
currentChain: v
|
|
2939
2940
|
}), /* @__PURE__ */ i(
|
|
2940
2941
|
S,
|
|
2941
2942
|
{
|
|
@@ -2945,23 +2946,23 @@ const xo = ({ title: e, onBack: n, onClose: t, rightContent: r, hideCloseButton:
|
|
|
2945
2946
|
variant: "light",
|
|
2946
2947
|
color: "default",
|
|
2947
2948
|
onPress: () => e.modal.setView(P.SelectChains),
|
|
2948
|
-
endContent: /* @__PURE__ */ i(
|
|
2949
|
-
children: /* @__PURE__ */
|
|
2950
|
-
/* @__PURE__ */ i(le, { icon:
|
|
2951
|
-
/* @__PURE__ */ i("span", { className: "text-sm", children:
|
|
2949
|
+
endContent: /* @__PURE__ */ i(Pr, { className: "size-4" }),
|
|
2950
|
+
children: /* @__PURE__ */ C("div", { className: "flex items-center gap-2", children: [
|
|
2951
|
+
/* @__PURE__ */ i(le, { icon: v?.chainInfo?.icon, className: "size-7 overflow-hidden rounded-full" }),
|
|
2952
|
+
/* @__PURE__ */ i("span", { className: "text-sm", children: v?.chainInfo?.name })
|
|
2952
2953
|
] })
|
|
2953
2954
|
}
|
|
2954
2955
|
),
|
|
2955
|
-
children: /* @__PURE__ */
|
|
2956
|
-
/* @__PURE__ */
|
|
2957
|
-
/* @__PURE__ */
|
|
2956
|
+
children: /* @__PURE__ */ C("div", { className: "w-full flex flex-col gap-6 pb-4", children: [
|
|
2957
|
+
/* @__PURE__ */ C("div", { className: "flex items-center justify-between gap-3 px-4 py-5 rounded-lg border border-primary", children: [
|
|
2958
|
+
/* @__PURE__ */ C("div", { className: "flex items-center gap-3", children: [
|
|
2958
2959
|
/* @__PURE__ */ i("div", { className: "w-10 h-10 rounded-full overflow-hidden bg-content2 flex items-center justify-center", children: c ? /* @__PURE__ */ i(ne, { src: c, alt: o, width: 40, height: 40 }) : /* @__PURE__ */ i("div", { className: "w-6 h-6 rounded bg-content3" }) }),
|
|
2959
|
-
/* @__PURE__ */
|
|
2960
|
-
/* @__PURE__ */ i("span", { className: "break-all", children:
|
|
2960
|
+
/* @__PURE__ */ C("div", { className: "flex flex-col", children: [
|
|
2961
|
+
/* @__PURE__ */ i("span", { className: "break-all", children: gs(a, 8, 6) || "-" }),
|
|
2961
2962
|
/* @__PURE__ */ i("span", { className: "text-xs text-foreground/70", children: o })
|
|
2962
2963
|
] })
|
|
2963
2964
|
] }),
|
|
2964
|
-
|
|
2965
|
+
g
|
|
2965
2966
|
] }),
|
|
2966
2967
|
/* @__PURE__ */ i("div", { children: /* @__PURE__ */ i(
|
|
2967
2968
|
X,
|
|
@@ -2969,7 +2970,7 @@ const xo = ({ title: e, onBack: n, onClose: t, rightContent: r, hideCloseButton:
|
|
|
2969
2970
|
color: "default",
|
|
2970
2971
|
variant: "light",
|
|
2971
2972
|
className: "w-full",
|
|
2972
|
-
startContent: /* @__PURE__ */ i(
|
|
2973
|
+
startContent: /* @__PURE__ */ i(Ir, { className: "size-4" }),
|
|
2973
2974
|
onPress: s,
|
|
2974
2975
|
children: "Disconnect wallet"
|
|
2975
2976
|
}
|
|
@@ -2995,8 +2996,8 @@ const xo = ({ title: e, onBack: n, onClose: t, rightContent: r, hideCloseButton:
|
|
|
2995
2996
|
n(et), wt();
|
|
2996
2997
|
}
|
|
2997
2998
|
};
|
|
2998
|
-
},
|
|
2999
|
-
const e = V(
|
|
2999
|
+
}, Io = () => {
|
|
3000
|
+
const e = V(W), n = e?.modal.state;
|
|
3000
3001
|
if (!e)
|
|
3001
3002
|
throw new Error("WalletConnectContext not found");
|
|
3002
3003
|
const t = n?.chainType || "evm", r = n?.chainId || "", s = n?.name || "-", o = n?.chainInfo?.icon || "", { resetWalletState: c } = Nn(), { mutate: a, isPending: l } = wn({
|
|
@@ -3008,27 +3009,27 @@ const xo = ({ title: e, onBack: n, onClose: t, rightContent: r, hideCloseButton:
|
|
|
3008
3009
|
});
|
|
3009
3010
|
}
|
|
3010
3011
|
});
|
|
3011
|
-
return /* @__PURE__ */ i(S, { title: "Switch network", onBack: () => e?.modal.backView(), children: /* @__PURE__ */
|
|
3012
|
+
return /* @__PURE__ */ i(S, { title: "Switch network", onBack: () => e?.modal.backView(), children: /* @__PURE__ */ C("div", { className: "flex flex-col items-center justify-center", children: [
|
|
3012
3013
|
/* @__PURE__ */ i("div", { className: "flex justify-center", children: /* @__PURE__ */ i(le, { icon: o, className: "size-14 overflow-hidden rounded-full" }) }),
|
|
3013
|
-
/* @__PURE__ */
|
|
3014
|
-
/* @__PURE__ */
|
|
3014
|
+
/* @__PURE__ */ C("div", { className: "mt-6 flex flex-col justify-center items-center", children: [
|
|
3015
|
+
/* @__PURE__ */ C("div", { className: "text-t1 text-sm", children: [
|
|
3015
3016
|
"Switch to ",
|
|
3016
3017
|
s
|
|
3017
3018
|
] }),
|
|
3018
|
-
/* @__PURE__ */
|
|
3019
|
+
/* @__PURE__ */ C("div", { className: "text-[#A9A29D] mt-2 text-sm text-center", children: [
|
|
3019
3020
|
"Your current wallet cannot connect to the ",
|
|
3020
3021
|
s,
|
|
3021
3022
|
" network. You need to connect with a new wallet."
|
|
3022
3023
|
] })
|
|
3023
3024
|
] }),
|
|
3024
|
-
/* @__PURE__ */
|
|
3025
|
+
/* @__PURE__ */ C(X, { className: "w-full my-4", disabled: l, onPress: () => a(), children: [
|
|
3025
3026
|
"Connect ",
|
|
3026
3027
|
s,
|
|
3027
3028
|
" wallet"
|
|
3028
3029
|
] })
|
|
3029
3030
|
] }) });
|
|
3030
|
-
},
|
|
3031
|
-
const e = V(
|
|
3031
|
+
}, qe = () => {
|
|
3032
|
+
const e = V(W);
|
|
3032
3033
|
return {
|
|
3033
3034
|
connectWallet: T(
|
|
3034
3035
|
async (t, r, s = "") => {
|
|
@@ -3059,12 +3060,12 @@ const xo = ({ title: e, onBack: n, onClose: t, rightContent: r, hideCloseButton:
|
|
|
3059
3060
|
[e?.modal.setView, e?.connect]
|
|
3060
3061
|
)
|
|
3061
3062
|
};
|
|
3062
|
-
},
|
|
3063
|
+
}, Po = ({
|
|
3063
3064
|
iconSrc: e,
|
|
3064
3065
|
iconAlt: n,
|
|
3065
3066
|
variant: t
|
|
3066
|
-
}) => /* @__PURE__ */
|
|
3067
|
-
t === "error" ? /* @__PURE__ */ i("div", { className: "absolute inset-0 border-4 border-danger rounded-full" }) : t === "connecting" ? /* @__PURE__ */
|
|
3067
|
+
}) => /* @__PURE__ */ C("div", { "data-tag": "ringed-icon", className: "relative w-20 h-20 flex items-center justify-center", children: [
|
|
3068
|
+
t === "error" ? /* @__PURE__ */ i("div", { className: "absolute inset-0 border-4 border-danger rounded-full" }) : t === "connecting" ? /* @__PURE__ */ C(ot, { children: [
|
|
3068
3069
|
/* @__PURE__ */ i("div", { className: "absolute inset-0 border-4 border-primary/20 rounded-full" }),
|
|
3069
3070
|
/* @__PURE__ */ i(
|
|
3070
3071
|
"div",
|
|
@@ -3076,31 +3077,31 @@ const xo = ({ title: e, onBack: n, onClose: t, rightContent: r, hideCloseButton:
|
|
|
3076
3077
|
] }) : /* @__PURE__ */ i("div", { className: "absolute inset-0 border-4 border-success rounded-full" }),
|
|
3077
3078
|
e ? /* @__PURE__ */ i(ne, { src: e, alt: n || "Wallet", width: 64, height: 64, className: "rounded-full relative z-10" }) : null,
|
|
3078
3079
|
t === "success" ? /* @__PURE__ */ i("div", { className: "absolute -bottom-1 -right-1 w-6 h-6 rounded-full bg-success flex items-center justify-center border-2 border-white", children: /* @__PURE__ */ i("svg", { className: "w-4 h-4 text-white", fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ i("path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 3, d: "M5 13l4 4L19 7" }) }) }) : null
|
|
3079
|
-
] }),
|
|
3080
|
-
const e = V(
|
|
3080
|
+
] }), Bo = () => {
|
|
3081
|
+
const e = V(W);
|
|
3081
3082
|
if (!e)
|
|
3082
3083
|
throw new Error("WalletConnectContext not found");
|
|
3083
|
-
const { currentWallet: n } = e.account, { isConnected: t, isConnecting: r, error: s } = e.connection, { connectWallet: o } =
|
|
3084
|
+
const { currentWallet: n } = e.account, { isConnected: t, isConnecting: r, error: s } = e.connection, { connectWallet: o } = qe(), [c, a] = N(!1), l = async () => {
|
|
3084
3085
|
if (c) return;
|
|
3085
3086
|
e.connection.setError("");
|
|
3086
3087
|
const x = e?.modal?.state || {
|
|
3087
3088
|
chainType: e.account.chainType || "evm",
|
|
3088
3089
|
chainId: ""
|
|
3089
|
-
},
|
|
3090
|
-
if (!n || !
|
|
3090
|
+
}, v = x.chainType, m = x.chainId || "";
|
|
3091
|
+
if (!n || !v) {
|
|
3091
3092
|
e.modal.setView(e.modal.mainView);
|
|
3092
3093
|
return;
|
|
3093
3094
|
}
|
|
3094
3095
|
try {
|
|
3095
|
-
a(!0), await o(n,
|
|
3096
|
-
} catch (
|
|
3097
|
-
console.error("handleRetry::",
|
|
3096
|
+
a(!0), await o(n, v, m), a(!1);
|
|
3097
|
+
} catch (p) {
|
|
3098
|
+
console.error("handleRetry::", p), await cn(1e3), a(!1);
|
|
3098
3099
|
}
|
|
3099
3100
|
}, A = () => {
|
|
3100
3101
|
e.connection.setError(""), e.modal.backView();
|
|
3101
|
-
}, d = t && !r, f = !!s && !r,
|
|
3102
|
+
}, d = t && !r, f = !!s && !r, u = d && !f ? "success" : f ? "error" : "connecting", g = () => d && !f ? /* @__PURE__ */ C("div", { className: "flex flex-col items-center gap-2", children: [
|
|
3102
3103
|
/* @__PURE__ */ i("p", { className: "text-lg font-semibold text-foreground", children: "Successfully Connected!" }),
|
|
3103
|
-
/* @__PURE__ */
|
|
3104
|
+
/* @__PURE__ */ C("p", { className: "text-sm text-foreground/60", children: [
|
|
3104
3105
|
"Connected to ",
|
|
3105
3106
|
n?.info?.name || "Wallet"
|
|
3106
3107
|
] })
|
|
@@ -3111,9 +3112,9 @@ const xo = ({ title: e, onBack: n, onClose: t, rightContent: r, hideCloseButton:
|
|
|
3111
3112
|
title: "Requesting Connection"
|
|
3112
3113
|
}
|
|
3113
3114
|
) }) });
|
|
3114
|
-
return /* @__PURE__ */ i(S, { title: n?.info?.name || "Wallet", onBack: A, children: /* @__PURE__ */
|
|
3115
|
-
/* @__PURE__ */ i(
|
|
3116
|
-
|
|
3115
|
+
return /* @__PURE__ */ i(S, { title: n?.info?.name || "Wallet", onBack: A, children: /* @__PURE__ */ C("div", { className: "flex flex-col items-center justify-center py-12 gap-6 flex-1", children: [
|
|
3116
|
+
/* @__PURE__ */ i(Po, { iconSrc: n?.info?.icon, iconAlt: n?.info?.name, variant: u }),
|
|
3117
|
+
g(),
|
|
3117
3118
|
f ? /* @__PURE__ */ i("div", { className: "w-full px-4", children: /* @__PURE__ */ i(
|
|
3118
3119
|
X,
|
|
3119
3120
|
{
|
|
@@ -3136,15 +3137,15 @@ const xo = ({ title: e, onBack: n, onClose: t, rightContent: r, hideCloseButton:
|
|
|
3136
3137
|
}
|
|
3137
3138
|
) }) : null
|
|
3138
3139
|
] }) });
|
|
3139
|
-
}, nt = ({ error: e, title: n }) => /* @__PURE__ */
|
|
3140
|
+
}, nt = ({ error: e, title: n }) => /* @__PURE__ */ C("div", { className: "flex flex-col items-center gap-2 text-sm text-foreground/60 text-center px-4", children: [
|
|
3140
3141
|
/* @__PURE__ */ i("p", { className: "text-lg font-semibold text-foreground", children: n }),
|
|
3141
3142
|
/* @__PURE__ */ i("p", { children: e })
|
|
3142
|
-
] }),
|
|
3143
|
-
const e = V(
|
|
3143
|
+
] }), yo = () => {
|
|
3144
|
+
const e = V(W);
|
|
3144
3145
|
if (!e)
|
|
3145
3146
|
throw new Error("WalletConnectContext not found");
|
|
3146
3147
|
const { error: n } = e.connection;
|
|
3147
|
-
return /* @__PURE__ */
|
|
3148
|
+
return /* @__PURE__ */ C("div", { className: "flex flex-col items-center justify-center py-12", children: [
|
|
3148
3149
|
/* @__PURE__ */ i("div", { className: "text-danger text-5xl mb-4", children: "⚠️" }),
|
|
3149
3150
|
/* @__PURE__ */ i("p", { className: "text-lg font-semibold mb-2 text-danger", children: "Connection Failed" }),
|
|
3150
3151
|
/* @__PURE__ */ i("p", { className: "text-sm text-gray-600 dark:text-gray-400 mb-6 text-center", children: n }),
|
|
@@ -3154,7 +3155,7 @@ const xo = ({ title: e, onBack: n, onClose: t, rightContent: r, hideCloseButton:
|
|
|
3154
3155
|
] });
|
|
3155
3156
|
}, $t = ({ content: e, size: n = 280, logo: t, logoBackground: r }) => {
|
|
3156
3157
|
const s = ce(null), o = ce(null);
|
|
3157
|
-
return
|
|
3158
|
+
return Y(() => {
|
|
3158
3159
|
if (!e || !s.current)
|
|
3159
3160
|
return;
|
|
3160
3161
|
const c = s.current, a = {
|
|
@@ -3190,57 +3191,57 @@ const xo = ({ title: e, onBack: n, onClose: t, rightContent: r, hideCloseButton:
|
|
|
3190
3191
|
if (o.current)
|
|
3191
3192
|
o.current.update(a);
|
|
3192
3193
|
else {
|
|
3193
|
-
const A = new
|
|
3194
|
+
const A = new es(a);
|
|
3194
3195
|
o.current = A, c.innerHTML = "", A.append(c);
|
|
3195
3196
|
}
|
|
3196
3197
|
const l = c;
|
|
3197
3198
|
return () => {
|
|
3198
3199
|
l && o.current && (l.innerHTML = "", o.current = null);
|
|
3199
3200
|
};
|
|
3200
|
-
}, [e, n, t, r]), console.log("-- qr code content", e), /* @__PURE__ */ i(
|
|
3201
|
-
},
|
|
3201
|
+
}, [e, n, t, r]), console.log("-- qr code content", e), /* @__PURE__ */ i(Br, { isLoaded: !!e, style: { width: n, height: n }, className: "rounded-lg", children: /* @__PURE__ */ i("div", { className: "flex items-center justify-center p-2 bg-[#1C1917] rounded-lg", children: /* @__PURE__ */ i("div", { ref: s }) }) });
|
|
3202
|
+
}, ho = ({ isOpen: e, onClose: n, onBack: t, url: r, logo: s, logoBackground: o, title: c }) => {
|
|
3202
3203
|
const { copy: a, copied: l } = In();
|
|
3203
|
-
return /* @__PURE__ */ i(At, { isOpen: e, onClose: n, onBack: t, title: c, children: /* @__PURE__ */
|
|
3204
|
+
return /* @__PURE__ */ i(At, { isOpen: e, onClose: n, onBack: t, title: c, children: /* @__PURE__ */ C("div", { className: "flex flex-col items-center justify-center px-5 pb-6 gap-4", children: [
|
|
3204
3205
|
/* @__PURE__ */ i("p", { className: "text-sm text-foreground/80 text-center", children: "Scan the QR code with your camera phone to get the app on iOS or Android." }),
|
|
3205
3206
|
/* @__PURE__ */ i($t, { content: r, logo: s, logoBackground: o }),
|
|
3206
3207
|
/* @__PURE__ */ i(X, { variant: "bordered", size: "lg", fullWidth: !0, onPress: () => {
|
|
3207
3208
|
a(r);
|
|
3208
3209
|
}, children: l ? "Copied!" : "Copy Link" })
|
|
3209
3210
|
] }) });
|
|
3210
|
-
},
|
|
3211
|
+
}, Mo = () => {
|
|
3211
3212
|
if (typeof window > "u") return "other";
|
|
3212
3213
|
const e = window.navigator.userAgent.toLowerCase();
|
|
3213
3214
|
return e.includes("chrome") && !e.includes("edge") && !e.includes("opera") ? "chrome" : e.includes("edge") ? "edge" : e.includes("firefox") ? "firefox" : e.includes("opera") || e.includes("opr") ? "opera" : e.includes("safari") && !e.includes("chrome") ? "safari" : "other";
|
|
3214
|
-
},
|
|
3215
|
+
}, Wo = () => {
|
|
3215
3216
|
if (typeof window > "u") return "desktop";
|
|
3216
3217
|
const e = window.navigator.userAgent.toLowerCase();
|
|
3217
3218
|
return /iphone|ipad|ipod/.test(e) ? "ios" : /android/.test(e) ? "android" : "desktop";
|
|
3218
|
-
},
|
|
3219
|
+
}, Vo = (e) => {
|
|
3219
3220
|
if (!e) return null;
|
|
3220
|
-
const n =
|
|
3221
|
+
const n = Wo(), t = Mo();
|
|
3221
3222
|
return n === "ios" ? e.ios_install || e.mobile || e.homepage || null : n === "android" ? e.android_install || e.mobile || e.homepage || null : t === "chrome" ? e.chrome_install || e.homepage || null : t === "edge" ? e.edge || e.homepage || null : t === "firefox" ? e.firefox || e.homepage || null : t === "opera" ? e.opera || e.homepage || null : t === "safari" ? e.safari || e.homepage || null : e.homepage || e.mobile || null;
|
|
3222
|
-
},
|
|
3223
|
+
}, Xo = (e) => {
|
|
3223
3224
|
if (!e) return [];
|
|
3224
3225
|
const n = [];
|
|
3225
3226
|
return e.chrome_install && n.push({ label: "Chrome", url: e.chrome_install }), e.edge && n.push({ label: "Edge", url: e.edge }), e.firefox && n.push({ label: "Firefox", url: e.firefox }), e.opera && n.push({ label: "Opera", url: e.opera }), e.safari && n.push({ label: "Safari", url: e.safari }), e.ios_install && n.push({ label: "iOS", url: e.ios_install }), e.android_install && n.push({ label: "Android", url: e.android_install }), e.mobile && !n.find((t) => t.url === e.mobile) && n.push({ label: "Mobile App", url: e.mobile }), e.homepage && !n.find((t) => t.url === e.homepage) && n.push({ label: "Homepage", url: e.homepage }), n;
|
|
3226
|
-
},
|
|
3227
|
-
const e = V(
|
|
3227
|
+
}, No = () => {
|
|
3228
|
+
const e = V(W);
|
|
3228
3229
|
if (!e)
|
|
3229
3230
|
throw new Error("WalletConnectContext not found");
|
|
3230
3231
|
const { currentWallet: n } = e.account;
|
|
3231
3232
|
if (!n)
|
|
3232
3233
|
throw new Error("Current wallet not found");
|
|
3233
3234
|
console.log("-- InstallGuideView -- currentWallet", n);
|
|
3234
|
-
const t = B(() => `Install ${n?.info?.name} Wallet`, [n?.info?.name]), r = B(() => n?.info, [n?.info]), s = B(() =>
|
|
3235
|
+
const t = B(() => `Install ${n?.info?.name} Wallet`, [n?.info?.name]), r = B(() => n?.info, [n?.info]), s = B(() => Vo(r?.links), [r?.links]), o = B(() => Xo(r?.links), [r?.links]), [c, a] = N({
|
|
3235
3236
|
isOpen: !1,
|
|
3236
3237
|
url: ""
|
|
3237
3238
|
}), l = () => {
|
|
3238
3239
|
s && window.open(s, "_blank", "noopener,noreferrer");
|
|
3239
|
-
}, A = (
|
|
3240
|
-
|
|
3240
|
+
}, A = (u) => {
|
|
3241
|
+
u.label === "iOS" || u.label === "Android" ? a({
|
|
3241
3242
|
isOpen: !0,
|
|
3242
|
-
url:
|
|
3243
|
-
}) : window.open(
|
|
3243
|
+
url: u.url
|
|
3244
|
+
}) : window.open(u.url, "_blank", "noopener,noreferrer");
|
|
3244
3245
|
}, d = () => {
|
|
3245
3246
|
a({
|
|
3246
3247
|
isOpen: !1,
|
|
@@ -3252,27 +3253,27 @@ const xo = ({ title: e, onBack: n, onClose: t, rightContent: r, hideCloseButton:
|
|
|
3252
3253
|
url: ""
|
|
3253
3254
|
});
|
|
3254
3255
|
};
|
|
3255
|
-
return /* @__PURE__ */
|
|
3256
|
-
/* @__PURE__ */
|
|
3256
|
+
return /* @__PURE__ */ C(S, { title: t, onBack: () => e.modal.backView(), children: [
|
|
3257
|
+
/* @__PURE__ */ C("div", { className: "flex flex-col items-center justify-center py-6", children: [
|
|
3257
3258
|
/* @__PURE__ */ i("div", { className: "flex items-center justify-center mb-6", children: /* @__PURE__ */ i(ne, { src: r.icon, alt: r.name, width: 64, height: 64 }) }),
|
|
3258
3259
|
/* @__PURE__ */ i("h3", { className: "text-lg font-semibold mb-2 text-foreground", children: r.name }),
|
|
3259
|
-
/* @__PURE__ */
|
|
3260
|
+
/* @__PURE__ */ C("p", { className: "text-sm text-foreground/60 mb-6 text-center px-4", children: [
|
|
3260
3261
|
"To connect with ",
|
|
3261
3262
|
r.name,
|
|
3262
3263
|
", please install the wallet extension or app."
|
|
3263
3264
|
] }),
|
|
3264
|
-
s && /* @__PURE__ */
|
|
3265
|
+
s && /* @__PURE__ */ C(X, { variant: "solid", color: "primary", size: "lg", fullWidth: !0, onPress: l, className: "mb-4", children: [
|
|
3265
3266
|
"Install ",
|
|
3266
3267
|
r.name
|
|
3267
3268
|
] }),
|
|
3268
|
-
o.length > 1 && /* @__PURE__ */
|
|
3269
|
+
o.length > 1 && /* @__PURE__ */ C("div", { className: "w-full", children: [
|
|
3269
3270
|
/* @__PURE__ */ i("p", { className: "text-xs text-foreground/60 mb-2 text-center", children: "Or download from:" }),
|
|
3270
|
-
/* @__PURE__ */ i("div", { className: "flex flex-wrap gap-2 justify-center", children: o.map((
|
|
3271
|
+
/* @__PURE__ */ i("div", { className: "flex flex-wrap gap-2 justify-center", children: o.map((u, g) => /* @__PURE__ */ i(X, { variant: "bordered", size: "sm", onPress: () => A(u), children: u.label }, g)) })
|
|
3271
3272
|
] }),
|
|
3272
3273
|
/* @__PURE__ */ i("p", { className: "text-xs text-foreground/40 mt-6 text-center px-4", children: "After installing, refresh the page and try connecting again." })
|
|
3273
3274
|
] }),
|
|
3274
3275
|
/* @__PURE__ */ i(
|
|
3275
|
-
|
|
3276
|
+
ho,
|
|
3276
3277
|
{
|
|
3277
3278
|
title: t,
|
|
3278
3279
|
isOpen: c.isOpen,
|
|
@@ -3284,10 +3285,10 @@ const xo = ({ title: e, onBack: n, onClose: t, rightContent: r, hideCloseButton:
|
|
|
3284
3285
|
}
|
|
3285
3286
|
)
|
|
3286
3287
|
] });
|
|
3287
|
-
},
|
|
3288
|
-
if (!V(
|
|
3288
|
+
}, jo = () => {
|
|
3289
|
+
if (!V(W))
|
|
3289
3290
|
throw new Error("WalletConnectContext not found");
|
|
3290
|
-
return /* @__PURE__ */ i(S, { title: "Loading", children: /* @__PURE__ */
|
|
3291
|
+
return /* @__PURE__ */ i(S, { title: "Loading", children: /* @__PURE__ */ C("div", { className: "flex flex-col items-center justify-center py-12 gap-6 flex-1", children: [
|
|
3291
3292
|
/* @__PURE__ */ i(
|
|
3292
3293
|
te,
|
|
3293
3294
|
{
|
|
@@ -3298,13 +3299,13 @@ const xo = ({ title: e, onBack: n, onClose: t, rightContent: r, hideCloseButton:
|
|
|
3298
3299
|
}
|
|
3299
3300
|
}
|
|
3300
3301
|
),
|
|
3301
|
-
/* @__PURE__ */
|
|
3302
|
+
/* @__PURE__ */ C("div", { className: "flex flex-col items-center gap-2 text-sm text-foreground/60 text-center px-4", children: [
|
|
3302
3303
|
/* @__PURE__ */ i("p", { className: "text-lg font-semibold text-foreground", children: "Initializing Wallet" }),
|
|
3303
3304
|
/* @__PURE__ */ i("p", { children: "Please wait while we set up your wallet connection..." })
|
|
3304
3305
|
] })
|
|
3305
3306
|
] }) });
|
|
3306
3307
|
}, jn = () => {
|
|
3307
|
-
const e = V(
|
|
3308
|
+
const e = V(W);
|
|
3308
3309
|
if (!e)
|
|
3309
3310
|
throw new Error("useAccount must be used within WalletConnectProvider");
|
|
3310
3311
|
return {
|
|
@@ -3324,9 +3325,9 @@ const xo = ({ title: e, onBack: n, onClose: t, rightContent: r, hideCloseButton:
|
|
|
3324
3325
|
// signAndSendTransaction: context.signAndSendTransaction,
|
|
3325
3326
|
// sendTransaction: context.sendTransaction,
|
|
3326
3327
|
};
|
|
3327
|
-
},
|
|
3328
|
+
}, To = () => {
|
|
3328
3329
|
const [e, n] = N(0), [t, r] = N(!1);
|
|
3329
|
-
return
|
|
3330
|
+
return Y(() => {
|
|
3330
3331
|
if (typeof window < "u" && window.visualViewport) {
|
|
3331
3332
|
const s = window.visualViewport, o = () => {
|
|
3332
3333
|
const c = window.innerHeight - s.height;
|
|
@@ -3347,7 +3348,7 @@ const xo = ({ title: e, onBack: n, onClose: t, rightContent: r, hideCloseButton:
|
|
|
3347
3348
|
}
|
|
3348
3349
|
}, []), { keyboardHeight: e, isKeyboardVisible: t };
|
|
3349
3350
|
};
|
|
3350
|
-
function
|
|
3351
|
+
function Eo(e = !1) {
|
|
3351
3352
|
const [n, t] = N(e), r = T(() => t(!0), []), s = T(() => t(!1), []), o = T(() => t((a) => !a), []), c = T((a) => t(a), []);
|
|
3352
3353
|
return {
|
|
3353
3354
|
isOpen: n,
|
|
@@ -3357,47 +3358,56 @@ function No(e = !1) {
|
|
|
3357
3358
|
onOpenChange: c
|
|
3358
3359
|
};
|
|
3359
3360
|
}
|
|
3360
|
-
const
|
|
3361
|
-
const { isOpen: n, onOpen: t, onClose: r } =
|
|
3362
|
-
|
|
3363
|
-
|
|
3361
|
+
const Lo = (e) => {
|
|
3362
|
+
const { isOpen: n, onOpen: t, onClose: r } = Eo(), [s, o] = N(e), [c, a] = N(null), [l, A] = N([]);
|
|
3363
|
+
Y(() => {
|
|
3364
|
+
s !== e && o(e);
|
|
3365
|
+
}, [e]);
|
|
3366
|
+
const d = T(
|
|
3367
|
+
(p, y, b) => {
|
|
3368
|
+
s === p && !b || (b || A((w) => [...w, { view: s, state: c }]), o(p), a(y || null));
|
|
3364
3369
|
},
|
|
3365
3370
|
[s, c]
|
|
3366
|
-
),
|
|
3371
|
+
), f = T(() => {
|
|
3367
3372
|
o(e), setTimeout(() => {
|
|
3368
|
-
a(null), A(
|
|
3373
|
+
a(null), A([]);
|
|
3369
3374
|
}, 400);
|
|
3370
|
-
}, []),
|
|
3371
|
-
r?.(),
|
|
3372
|
-
}, [r,
|
|
3373
|
-
(
|
|
3374
|
-
A(
|
|
3375
|
+
}, [e]), u = T(() => {
|
|
3376
|
+
r?.(), f();
|
|
3377
|
+
}, [r, f]), g = T(
|
|
3378
|
+
(p, y) => {
|
|
3379
|
+
A((b) => [...b, { view: s, state: c }]), o(p), a(y || null), t();
|
|
3375
3380
|
},
|
|
3376
3381
|
[s, c, t]
|
|
3377
|
-
),
|
|
3378
|
-
|
|
3379
|
-
|
|
3380
|
-
|
|
3381
|
-
|
|
3382
|
+
), x = T(() => {
|
|
3383
|
+
A((p) => {
|
|
3384
|
+
if (p.length === 0)
|
|
3385
|
+
return o(e), a(null), p;
|
|
3386
|
+
const y = p[p.length - 1], b = p.slice(0, -1);
|
|
3387
|
+
return o(y.view), a(y.state), b;
|
|
3388
|
+
});
|
|
3389
|
+
}, [e]), v = T((p) => {
|
|
3390
|
+
a(p || null);
|
|
3391
|
+
}, []), m = l.length > 0 ? l[l.length - 1].view : null;
|
|
3382
3392
|
return {
|
|
3383
3393
|
isOpen: n,
|
|
3384
3394
|
view: s,
|
|
3385
|
-
prevView:
|
|
3395
|
+
prevView: m,
|
|
3386
3396
|
openModal: t,
|
|
3387
|
-
openModalWithState:
|
|
3388
|
-
closeModal:
|
|
3389
|
-
setView:
|
|
3390
|
-
backView:
|
|
3397
|
+
openModalWithState: g,
|
|
3398
|
+
closeModal: u,
|
|
3399
|
+
setView: d,
|
|
3400
|
+
backView: x,
|
|
3391
3401
|
state: c,
|
|
3392
|
-
setCurrentViewState:
|
|
3402
|
+
setCurrentViewState: v
|
|
3393
3403
|
};
|
|
3394
|
-
},
|
|
3404
|
+
}, So = (e) => {
|
|
3395
3405
|
const n = ce(null);
|
|
3396
|
-
return
|
|
3406
|
+
return Y(() => {
|
|
3397
3407
|
n.current && (n.current.scrollTop = 0);
|
|
3398
3408
|
}, e), n;
|
|
3399
3409
|
}, er = () => {
|
|
3400
|
-
const e = V(
|
|
3410
|
+
const e = V(W);
|
|
3401
3411
|
if (!e)
|
|
3402
3412
|
throw new Error("useEmbeddedWallet must be used within WalletConnectProvider");
|
|
3403
3413
|
return e.embeddedWallet || {
|
|
@@ -3407,8 +3417,8 @@ const jo = (e) => {
|
|
|
3407
3417
|
connectedInfo: null,
|
|
3408
3418
|
isLoading: !0
|
|
3409
3419
|
};
|
|
3410
|
-
},
|
|
3411
|
-
const e = V(
|
|
3420
|
+
}, Ke = () => {
|
|
3421
|
+
const e = V(W), { connectWallet: n } = qe();
|
|
3412
3422
|
return {
|
|
3413
3423
|
handleSelectWallet: T(
|
|
3414
3424
|
(r, s) => {
|
|
@@ -3447,20 +3457,52 @@ const jo = (e) => {
|
|
|
3447
3457
|
[e, n]
|
|
3448
3458
|
)
|
|
3449
3459
|
};
|
|
3450
|
-
},
|
|
3451
|
-
|
|
3452
|
-
|
|
3453
|
-
|
|
3454
|
-
|
|
3455
|
-
|
|
3456
|
-
|
|
3457
|
-
|
|
3460
|
+
}, Oo = {
|
|
3461
|
+
themes: {
|
|
3462
|
+
light: {
|
|
3463
|
+
colors: {
|
|
3464
|
+
foreground: "#12122A",
|
|
3465
|
+
background: "#FFF",
|
|
3466
|
+
content1: "#FCFCFD",
|
|
3467
|
+
primary: {
|
|
3468
|
+
50: "#FFFBEA",
|
|
3469
|
+
100: "#FFF3C4",
|
|
3470
|
+
200: "#FCE588",
|
|
3471
|
+
300: "#FADB5F",
|
|
3472
|
+
400: "#F7C948",
|
|
3473
|
+
500: "#FCD436",
|
|
3474
|
+
600: "#F0B429",
|
|
3475
|
+
700: "#DE911D",
|
|
3476
|
+
800: "#CB6E17",
|
|
3477
|
+
900: "#B44D12",
|
|
3478
|
+
foreground: "#12122A",
|
|
3479
|
+
DEFAULT: "#FCD436"
|
|
3480
|
+
},
|
|
3481
|
+
danger: "#FF5A5A",
|
|
3482
|
+
warning: "#FFAD32",
|
|
3483
|
+
success: "#079455",
|
|
3484
|
+
t1: "#12122A",
|
|
3485
|
+
t2: "#616184",
|
|
3486
|
+
t3: "#8989AB",
|
|
3487
|
+
t4: "#C1C0D8",
|
|
3488
|
+
t5: "#EEC41F"
|
|
3489
|
+
}
|
|
3490
|
+
}
|
|
3491
|
+
}
|
|
3492
|
+
}, Ce = "https://dogeos.embedded-wallet.tomo.inc", Yo = [
|
|
3493
|
+
Yr(Ce),
|
|
3494
|
+
Zr(Ce),
|
|
3495
|
+
kr(Ce),
|
|
3496
|
+
Jr(Ce),
|
|
3497
|
+
Fr(Ce)
|
|
3498
|
+
], ye = {
|
|
3499
|
+
recommonedWallets: Yo,
|
|
3458
3500
|
links: {
|
|
3459
3501
|
privacyPolicy: "https://www.mydoge.com/privacy",
|
|
3460
3502
|
termsOfService: "https://www.mydoge.com/terms",
|
|
3461
3503
|
homepage: "https://www.mydoge.com"
|
|
3462
3504
|
}
|
|
3463
|
-
},
|
|
3505
|
+
}, Zo = {
|
|
3464
3506
|
projectId: "44cb8a6aedbe379ba8f2fa4fbc1a461f",
|
|
3465
3507
|
metadata: {
|
|
3466
3508
|
name: "Doge Wallet Connect",
|
|
@@ -3468,24 +3510,27 @@ const jo = (e) => {
|
|
|
3468
3510
|
url: typeof window < "u" ? window.location.origin : "",
|
|
3469
3511
|
icons: ["https://getdoge.com/cdn/shop/files/Symbol_1.png?v=1681939190&width=200"]
|
|
3470
3512
|
}
|
|
3471
|
-
},
|
|
3513
|
+
}, ko = "cTQxTUlSZXhwOXF6T2hnTHJVRzI6MTpjaQ", Jo = "362812706401-eppkpnqocdaejaf45ics815t22oe0j7l.apps.googleusercontent.com", nr = "mSzQLiebxpwV64barnRZpCGZTwB38kSiuszi42Cqq41fkRH8KM99dqG4pFNnvaVA4DV7zHsic0or0pd8tlMIt9vc", tr = {
|
|
3472
3514
|
tomoStage: "prod",
|
|
3473
3515
|
//dev/pre/prod
|
|
3474
3516
|
name: "Doge Embedded Wallet",
|
|
3475
3517
|
logo: "https://getdoge.com/cdn/shop/files/Symbol_1.png?v=1681939190&width=200",
|
|
3476
3518
|
clientId: nr,
|
|
3477
|
-
xClientId:
|
|
3478
|
-
googleClientId:
|
|
3519
|
+
xClientId: ko,
|
|
3520
|
+
googleClientId: Jo,
|
|
3479
3521
|
walletBaseUrl: "https://dogeos.embedded-wallet.tomo.inc/embed"
|
|
3480
3522
|
//provider.apis
|
|
3481
|
-
},
|
|
3482
|
-
const n = e.length > 0 ? e :
|
|
3483
|
-
return
|
|
3523
|
+
}, Fo = Oo, Do = ["wallets", "all"], Ho = (e) => () => {
|
|
3524
|
+
const n = e.length > 0 ? e : ye.recommonedWallets || [], t = tr.walletBaseUrl.replace(/\/embed$/, "");
|
|
3525
|
+
return Dr({
|
|
3484
3526
|
chainType: "all",
|
|
3485
3527
|
recommonedConnectors: n,
|
|
3486
|
-
connectorTypes: n.map(() => "tomo")
|
|
3528
|
+
connectorTypes: n.map(() => "tomo"),
|
|
3529
|
+
options: {
|
|
3530
|
+
baseUrl: t
|
|
3531
|
+
}
|
|
3487
3532
|
});
|
|
3488
|
-
}, tt = (e, n) => n === "all" ? e : e.filter((t) => !!t.providers[n]),
|
|
3533
|
+
}, tt = (e, n) => n === "all" ? e : e.filter((t) => !!t.providers[n]), rr = (e) => {
|
|
3489
3534
|
if (!e || !e.info)
|
|
3490
3535
|
return null;
|
|
3491
3536
|
const n = {};
|
|
@@ -3502,23 +3547,23 @@ const jo = (e) => {
|
|
|
3502
3547
|
isEmbeddedWallet: !0,
|
|
3503
3548
|
logout: async () => e.logout()
|
|
3504
3549
|
};
|
|
3505
|
-
},
|
|
3506
|
-
const r = V(
|
|
3550
|
+
}, he = (e, n = []) => {
|
|
3551
|
+
const r = V(W)?.embeddedWallet, { wallet: s } = r || {
|
|
3507
3552
|
wallet: null
|
|
3508
|
-
}, o = B(() => n.length > 0 ? n :
|
|
3509
|
-
() =>
|
|
3553
|
+
}, o = B(() => n.length > 0 ? n : ye.recommonedWallets || [], [n]), c = B(
|
|
3554
|
+
() => Ho(o),
|
|
3510
3555
|
[o]
|
|
3511
3556
|
// Only recreate when connectors ID changes
|
|
3512
|
-
), a =
|
|
3513
|
-
queryKey:
|
|
3557
|
+
), a = Ur({
|
|
3558
|
+
queryKey: Do,
|
|
3514
3559
|
queryFn: c,
|
|
3515
3560
|
// Refetch on window focus to update wallet installation status
|
|
3516
3561
|
refetchOnWindowFocus: !0
|
|
3517
|
-
}), l = B(() => s ?
|
|
3562
|
+
}), l = B(() => s ? rr(s) : null, [s]), A = B(() => {
|
|
3518
3563
|
if (!a.data)
|
|
3519
3564
|
return;
|
|
3520
3565
|
const d = [...a.data.all], f = [...a.data.recommoned];
|
|
3521
|
-
return l && (d.some((
|
|
3566
|
+
return l && (d.some((g) => g.info.uuid === l.info.uuid) || (d.push(l), f.push(l))), {
|
|
3522
3567
|
all: tt(d, e),
|
|
3523
3568
|
recommoned: tt(f, e)
|
|
3524
3569
|
};
|
|
@@ -3530,37 +3575,39 @@ const jo = (e) => {
|
|
|
3530
3575
|
embeddedWallet: r,
|
|
3531
3576
|
embeddedWalletConnector: l
|
|
3532
3577
|
};
|
|
3533
|
-
},
|
|
3534
|
-
const { closeModalBeforeIframe: n = !0 } = e, [t, r] = N(!1), s = V(
|
|
3578
|
+
}, sr = (e = {}) => {
|
|
3579
|
+
const { closeModalBeforeIframe: n = !0 } = e, [t, r] = N(!1), s = V(W), o = er(), { embeddedWalletConnector: c } = he("all"), { handleSelectWallet: a } = Ke();
|
|
3535
3580
|
if (!s)
|
|
3536
3581
|
throw new Error("WalletConnectContext not found");
|
|
3537
|
-
const l = (
|
|
3582
|
+
const l = (g) => {
|
|
3538
3583
|
s.modal.setView(
|
|
3539
3584
|
s.modal.mainView,
|
|
3540
3585
|
{
|
|
3541
3586
|
isLoading: !1,
|
|
3542
3587
|
email: s.modal.state?.email || "",
|
|
3543
|
-
error:
|
|
3588
|
+
error: g
|
|
3544
3589
|
},
|
|
3545
3590
|
!0
|
|
3546
3591
|
), r(!1);
|
|
3547
3592
|
}, A = async () => {
|
|
3548
|
-
a(c)
|
|
3593
|
+
a(c), o.wallet?.onLoginStatusChanged(({ type: g }) => {
|
|
3594
|
+
g === "logout" && s.disconnect?.();
|
|
3595
|
+
});
|
|
3549
3596
|
};
|
|
3550
3597
|
return {
|
|
3551
3598
|
isLoading: t,
|
|
3552
|
-
handleEmailLogin: async (
|
|
3599
|
+
handleEmailLogin: async (g) => {
|
|
3553
3600
|
try {
|
|
3554
|
-
const x =
|
|
3601
|
+
const x = As(g);
|
|
3555
3602
|
if (x && l(x), r(!0), o.isLoading || !o.wallet)
|
|
3556
3603
|
return l("Embedded wallet initialization failed");
|
|
3557
|
-
const
|
|
3604
|
+
const v = o.wallet;
|
|
3558
3605
|
n && s.modal.closeModal();
|
|
3559
|
-
const m = await
|
|
3606
|
+
const m = await v?.loginByEmail?.({ email: g });
|
|
3560
3607
|
if (!m)
|
|
3561
3608
|
return l("Failed to login with email");
|
|
3562
|
-
const
|
|
3563
|
-
if (!
|
|
3609
|
+
const p = m;
|
|
3610
|
+
if (!p || !(await v.login(p)).isAvailable)
|
|
3564
3611
|
return l("Failed to login with email");
|
|
3565
3612
|
A();
|
|
3566
3613
|
} catch (x) {
|
|
@@ -3571,15 +3618,15 @@ const jo = (e) => {
|
|
|
3571
3618
|
try {
|
|
3572
3619
|
if (r(!0), o.isLoading || !o.wallet)
|
|
3573
3620
|
return l("Embedded wallet initialization failed");
|
|
3574
|
-
const
|
|
3621
|
+
const g = o.wallet, x = await g?.loginByGoogle?.();
|
|
3575
3622
|
if (!x)
|
|
3576
3623
|
return l("Failed to login with Google");
|
|
3577
|
-
const
|
|
3578
|
-
if (!
|
|
3624
|
+
const v = x;
|
|
3625
|
+
if (!v || !(await g.login(v)).isAvailable)
|
|
3579
3626
|
return l("Failed to login with Google");
|
|
3580
3627
|
A();
|
|
3581
|
-
} catch (
|
|
3582
|
-
console.error("Google login error:",
|
|
3628
|
+
} catch (g) {
|
|
3629
|
+
console.error("Google login error:", g), l("Failed to login with Google");
|
|
3583
3630
|
} finally {
|
|
3584
3631
|
r(!1);
|
|
3585
3632
|
}
|
|
@@ -3588,35 +3635,35 @@ const jo = (e) => {
|
|
|
3588
3635
|
try {
|
|
3589
3636
|
if (r(!0), o.isLoading || !o.wallet)
|
|
3590
3637
|
return l("Embedded wallet initialization failed");
|
|
3591
|
-
const
|
|
3638
|
+
const g = o.wallet, x = await g?.loginByX?.();
|
|
3592
3639
|
if (!x)
|
|
3593
3640
|
return l("Failed to login with X");
|
|
3594
|
-
const
|
|
3595
|
-
if (!
|
|
3641
|
+
const v = x;
|
|
3642
|
+
if (!v || !(await g.login(v)).isAvailable)
|
|
3596
3643
|
return l("Failed to login with X");
|
|
3597
3644
|
A();
|
|
3598
|
-
} catch (
|
|
3599
|
-
console.error("X login error:",
|
|
3645
|
+
} catch (g) {
|
|
3646
|
+
console.error("X login error:", g), l(g instanceof Error ? g.message : g);
|
|
3600
3647
|
} finally {
|
|
3601
3648
|
r(!1);
|
|
3602
3649
|
}
|
|
3603
3650
|
}
|
|
3604
3651
|
};
|
|
3605
3652
|
};
|
|
3606
|
-
let oe = null,
|
|
3653
|
+
let oe = null, ir = null;
|
|
3607
3654
|
function rt(e) {
|
|
3608
3655
|
oe = e, console.log("setWagmiConfig>>>>", e);
|
|
3609
3656
|
}
|
|
3610
|
-
function
|
|
3657
|
+
function Qo() {
|
|
3611
3658
|
return oe;
|
|
3612
3659
|
}
|
|
3613
3660
|
function tn(e) {
|
|
3614
|
-
console.log("setWagmiConnectors>>>>", e),
|
|
3615
|
-
}
|
|
3616
|
-
function ir() {
|
|
3617
|
-
return sr;
|
|
3661
|
+
console.log("setWagmiConnectors>>>>", e), ir = e;
|
|
3618
3662
|
}
|
|
3619
3663
|
function or() {
|
|
3664
|
+
return ir;
|
|
3665
|
+
}
|
|
3666
|
+
function cr() {
|
|
3620
3667
|
if (typeof window > "u")
|
|
3621
3668
|
return oe;
|
|
3622
3669
|
if (oe)
|
|
@@ -3632,38 +3679,38 @@ function or() {
|
|
|
3632
3679
|
return console.log("useWagmiConfig error>>>>", e.message), null;
|
|
3633
3680
|
}
|
|
3634
3681
|
}
|
|
3635
|
-
function
|
|
3682
|
+
function ze() {
|
|
3636
3683
|
return oe !== null;
|
|
3637
3684
|
}
|
|
3638
3685
|
function Tn() {
|
|
3639
|
-
const e =
|
|
3640
|
-
return
|
|
3686
|
+
const e = cr();
|
|
3687
|
+
return ze() ? e !== null : !1;
|
|
3641
3688
|
}
|
|
3642
|
-
function
|
|
3643
|
-
if (console.log("isWagmiAvailable>>>>",
|
|
3689
|
+
function ar() {
|
|
3690
|
+
if (console.log("isWagmiAvailable>>>>", ze()), !ze())
|
|
3644
3691
|
return null;
|
|
3645
3692
|
const e = Tn();
|
|
3646
3693
|
console.log("inProvider>>>>", e);
|
|
3647
|
-
const n =
|
|
3694
|
+
const n = ts();
|
|
3648
3695
|
return e ? n : null;
|
|
3649
3696
|
}
|
|
3650
|
-
function
|
|
3651
|
-
if (!
|
|
3697
|
+
function qo() {
|
|
3698
|
+
if (!ze())
|
|
3652
3699
|
return null;
|
|
3653
|
-
const e = Tn(), n =
|
|
3700
|
+
const e = Tn(), n = rs();
|
|
3654
3701
|
return e ? n : null;
|
|
3655
3702
|
}
|
|
3656
|
-
function
|
|
3657
|
-
if (!
|
|
3703
|
+
function Ko() {
|
|
3704
|
+
if (!ze())
|
|
3658
3705
|
return null;
|
|
3659
|
-
const e = Tn(), n =
|
|
3706
|
+
const e = Tn(), n = ss();
|
|
3660
3707
|
return e ? n : null;
|
|
3661
3708
|
}
|
|
3662
3709
|
function mn(e, n, t) {
|
|
3663
|
-
const r =
|
|
3710
|
+
const r = Qo();
|
|
3664
3711
|
if (!r)
|
|
3665
3712
|
return null;
|
|
3666
|
-
const s =
|
|
3713
|
+
const s = or(), o = t || s || r.connectors;
|
|
3667
3714
|
return !o || o.length === 0 ? null : o.find((c) => {
|
|
3668
3715
|
const a = (c.id || "").toLowerCase(), l = (c.name || "").toLowerCase(), A = e.toLowerCase(), d = n?.toLowerCase();
|
|
3669
3716
|
return a === A || a === d || l === A || l === d || a.includes(A) || l.includes(A);
|
|
@@ -3672,7 +3719,7 @@ function mn(e, n, t) {
|
|
|
3672
3719
|
const rn = (e, n, t = "Wallet is performing an action, please wait...") => {
|
|
3673
3720
|
if (e)
|
|
3674
3721
|
throw n(t), new Error(t);
|
|
3675
|
-
},
|
|
3722
|
+
}, Go = ({
|
|
3676
3723
|
walletState: e,
|
|
3677
3724
|
modalState: n,
|
|
3678
3725
|
setWalletState: t,
|
|
@@ -3680,22 +3727,22 @@ const rn = (e, n, t = "Wallet is performing an action, please wait...") => {
|
|
|
3680
3727
|
resetWalletState: s,
|
|
3681
3728
|
setMainView: o
|
|
3682
3729
|
}) => {
|
|
3683
|
-
const { currentProvider: c, currentWallet: a, isConnected: l, actionsLoading: A } = e, d =
|
|
3684
|
-
async (
|
|
3685
|
-
const { wallet: w, chainType: I } =
|
|
3730
|
+
const { currentProvider: c, currentWallet: a, isConnected: l, actionsLoading: A } = e, d = ar(), f = qo(), u = or(), g = T(
|
|
3731
|
+
async (b) => {
|
|
3732
|
+
const { wallet: w, chainType: I } = b, j = w.providers[I]?.provider;
|
|
3686
3733
|
if (l && a?.info?.uuid === w.info.uuid && I === e.chainType)
|
|
3687
3734
|
throw r("Wallet is already connected"), new Error("Wallet is already connected");
|
|
3688
3735
|
if (!j && !on())
|
|
3689
3736
|
throw r("Provider not available for this chain type"), new Error("Provider not available for this chain type");
|
|
3690
|
-
r(""), t((
|
|
3691
|
-
...
|
|
3737
|
+
r(""), t((M) => ({
|
|
3738
|
+
...M,
|
|
3692
3739
|
isConnecting: !0,
|
|
3693
3740
|
currentWallet: w,
|
|
3694
3741
|
currentProvider: j,
|
|
3695
3742
|
actionsLoading: !0
|
|
3696
3743
|
}));
|
|
3697
3744
|
try {
|
|
3698
|
-
const
|
|
3745
|
+
const M = await Hr(
|
|
3699
3746
|
{
|
|
3700
3747
|
dappLink: typeof window < "u" ? window.location.href : ""
|
|
3701
3748
|
},
|
|
@@ -3705,18 +3752,18 @@ const rn = (e, n, t = "Wallet is performing an action, please wait...") => {
|
|
|
3705
3752
|
walletInfo: w.info
|
|
3706
3753
|
}
|
|
3707
3754
|
), E = {
|
|
3708
|
-
address:
|
|
3709
|
-
chainId:
|
|
3755
|
+
address: M.address,
|
|
3756
|
+
chainId: M.chainId || "",
|
|
3710
3757
|
chainType: I
|
|
3711
3758
|
};
|
|
3712
|
-
if (await cn(800), console.log("wagmiConnect", d), console.log("wagmiConnectors",
|
|
3759
|
+
if (await cn(800), console.log("wagmiConnect", d), console.log("wagmiConnectors", u), d && I === k.EVM && u)
|
|
3713
3760
|
try {
|
|
3714
|
-
const L = mn(w.info.uuid, w.info.rdns,
|
|
3761
|
+
const L = mn(w.info.uuid, w.info.rdns, u);
|
|
3715
3762
|
if (L) {
|
|
3716
|
-
const
|
|
3763
|
+
const Z = M.chainId ? parseInt(M.chainId, 16) : void 0;
|
|
3717
3764
|
await d.connectAsync({
|
|
3718
3765
|
connector: L,
|
|
3719
|
-
chainId:
|
|
3766
|
+
chainId: Z
|
|
3720
3767
|
});
|
|
3721
3768
|
}
|
|
3722
3769
|
} catch (L) {
|
|
@@ -3726,15 +3773,15 @@ const rn = (e, n, t = "Wallet is performing an action, please wait...") => {
|
|
|
3726
3773
|
...L,
|
|
3727
3774
|
isConnecting: !1,
|
|
3728
3775
|
isConnected: !0,
|
|
3729
|
-
address:
|
|
3730
|
-
chainId:
|
|
3776
|
+
address: M.address,
|
|
3777
|
+
chainId: M.chainId,
|
|
3731
3778
|
chainType: I,
|
|
3732
3779
|
balance: "0.0",
|
|
3733
3780
|
actionsLoading: !1,
|
|
3734
|
-
currentProvider:
|
|
3735
|
-
})),
|
|
3736
|
-
address:
|
|
3737
|
-
chainId:
|
|
3781
|
+
currentProvider: M.provider || j
|
|
3782
|
+
})), ds({
|
|
3783
|
+
address: M.address,
|
|
3784
|
+
chainId: M.chainId,
|
|
3738
3785
|
chainType: I,
|
|
3739
3786
|
balance: "0.0",
|
|
3740
3787
|
walletInfo: {
|
|
@@ -3753,10 +3800,10 @@ const rn = (e, n, t = "Wallet is performing an action, please wait...") => {
|
|
|
3753
3800
|
account: { address: E.address, chainId: E.chainId },
|
|
3754
3801
|
provider: j
|
|
3755
3802
|
}), t((L) => ({ ...L, chainId: Re.evm_1.chainId, chainType: I }))), E;
|
|
3756
|
-
} catch (
|
|
3757
|
-
throw console.error("Connection failed:",
|
|
3803
|
+
} catch (M) {
|
|
3804
|
+
throw console.error("Connection failed:", M), r(M?.message || "Connection failed"), M;
|
|
3758
3805
|
} finally {
|
|
3759
|
-
t((
|
|
3806
|
+
t((M) => ({ ...M, isConnecting: !1, actionsLoading: !1 }));
|
|
3760
3807
|
}
|
|
3761
3808
|
},
|
|
3762
3809
|
[
|
|
@@ -3767,20 +3814,20 @@ const rn = (e, n, t = "Wallet is performing an action, please wait...") => {
|
|
|
3767
3814
|
t,
|
|
3768
3815
|
n,
|
|
3769
3816
|
d,
|
|
3770
|
-
|
|
3817
|
+
u
|
|
3771
3818
|
]
|
|
3772
3819
|
), x = T(async () => {
|
|
3773
|
-
t((
|
|
3820
|
+
t((b) => ({ ...b, actionsLoading: !0 }));
|
|
3774
3821
|
try {
|
|
3775
3822
|
if (n.closeModal(), c?.disconnect?.(), f)
|
|
3776
3823
|
try {
|
|
3777
3824
|
f.disconnect();
|
|
3778
|
-
} catch (
|
|
3779
|
-
console.warn("Failed to disconnect wagmi connector:",
|
|
3825
|
+
} catch (b) {
|
|
3826
|
+
console.warn("Failed to disconnect wagmi connector:", b);
|
|
3780
3827
|
}
|
|
3781
3828
|
a?.isEmbeddedWallet && o(P.Logged), s();
|
|
3782
3829
|
} finally {
|
|
3783
|
-
t((
|
|
3830
|
+
t((b) => ({ ...b, actionsLoading: !1 }));
|
|
3784
3831
|
}
|
|
3785
3832
|
}, [
|
|
3786
3833
|
t,
|
|
@@ -3790,27 +3837,27 @@ const rn = (e, n, t = "Wallet is performing an action, please wait...") => {
|
|
|
3790
3837
|
s,
|
|
3791
3838
|
o,
|
|
3792
3839
|
f
|
|
3793
|
-
]),
|
|
3794
|
-
async ({ chainInfo:
|
|
3840
|
+
]), v = T(
|
|
3841
|
+
async ({ chainInfo: b, chainType: w }) => {
|
|
3795
3842
|
rn(A, r);
|
|
3796
|
-
const I =
|
|
3843
|
+
const I = b.id.toString(), j = {
|
|
3797
3844
|
chainType: w,
|
|
3798
3845
|
account: e,
|
|
3799
3846
|
provider: e.currentProvider
|
|
3800
|
-
},
|
|
3847
|
+
}, M = {
|
|
3801
3848
|
chainId: I,
|
|
3802
|
-
chainName:
|
|
3803
|
-
rpcUrls:
|
|
3849
|
+
chainName: b.name,
|
|
3850
|
+
rpcUrls: b.rpcUrls.default.http,
|
|
3804
3851
|
iconUrls: [],
|
|
3805
|
-
nativeCurrency:
|
|
3806
|
-
blockExplorerUrls: [
|
|
3852
|
+
nativeCurrency: b.nativeCurrency,
|
|
3853
|
+
blockExplorerUrls: [b.blockExplorers?.default.url || ""]
|
|
3807
3854
|
};
|
|
3808
3855
|
try {
|
|
3809
3856
|
return t((E) => ({ ...E, actionsLoading: !0 })), await On(I, j), t((E) => ({ ...E, chainId: I, chainType: w })), !0;
|
|
3810
3857
|
} catch (E) {
|
|
3811
3858
|
if (E?.code === 4902)
|
|
3812
3859
|
try {
|
|
3813
|
-
return await
|
|
3860
|
+
return await Qr(M, j), !0;
|
|
3814
3861
|
} catch (L) {
|
|
3815
3862
|
throw console.error("Add chain failed:", L), L;
|
|
3816
3863
|
}
|
|
@@ -3821,7 +3868,7 @@ const rn = (e, n, t = "Wallet is performing an action, please wait...") => {
|
|
|
3821
3868
|
},
|
|
3822
3869
|
[t, e, A, r]
|
|
3823
3870
|
), m = T(
|
|
3824
|
-
async (
|
|
3871
|
+
async (b) => {
|
|
3825
3872
|
if (rn(A, r), !e.isConnected || !e.currentProvider || !e.chainType)
|
|
3826
3873
|
throw new Error("Wallet not connected");
|
|
3827
3874
|
return t((w) => ({ ...w, actionsLoading: !0 })), new Promise((w, I) => {
|
|
@@ -3833,9 +3880,9 @@ const rn = (e, n, t = "Wallet is performing an action, please wait...") => {
|
|
|
3833
3880
|
version: "1",
|
|
3834
3881
|
nonce: Math.random().toString(36).substring(7),
|
|
3835
3882
|
issuedAt: (/* @__PURE__ */ new Date()).toISOString()
|
|
3836
|
-
}, ...
|
|
3883
|
+
}, ...b || {} };
|
|
3837
3884
|
try {
|
|
3838
|
-
const
|
|
3885
|
+
const Z = await Kr(L, {
|
|
3839
3886
|
chainType: e.chainType,
|
|
3840
3887
|
account: {
|
|
3841
3888
|
address: e.address,
|
|
@@ -3845,24 +3892,24 @@ const rn = (e, n, t = "Wallet is performing an action, please wait...") => {
|
|
|
3845
3892
|
walletInfo: e.currentWallet?.info,
|
|
3846
3893
|
isInstalled: e.currentWallet?.isInstalled
|
|
3847
3894
|
});
|
|
3848
|
-
if (
|
|
3849
|
-
w(
|
|
3895
|
+
if (Z)
|
|
3896
|
+
w(Z);
|
|
3850
3897
|
else {
|
|
3851
3898
|
const fe = new Error("Failed to sign in");
|
|
3852
3899
|
throw I(fe), fe;
|
|
3853
3900
|
}
|
|
3854
|
-
} catch (
|
|
3855
|
-
throw I(
|
|
3901
|
+
} catch (Z) {
|
|
3902
|
+
throw I(Z), Z;
|
|
3856
3903
|
} finally {
|
|
3857
|
-
t((
|
|
3904
|
+
t((Z) => ({ ...Z, actionsLoading: !1 }));
|
|
3858
3905
|
}
|
|
3859
|
-
},
|
|
3906
|
+
}, M = async () => {
|
|
3860
3907
|
I(new Error("User rejected the request.")), t((E) => ({ ...E, actionsLoading: !1 }));
|
|
3861
3908
|
};
|
|
3862
3909
|
n.setView(P.SignInWallet, {
|
|
3863
|
-
params:
|
|
3910
|
+
params: b,
|
|
3864
3911
|
onConfirm: j,
|
|
3865
|
-
onCancel:
|
|
3912
|
+
onCancel: M
|
|
3866
3913
|
}), n.openModal();
|
|
3867
3914
|
});
|
|
3868
3915
|
},
|
|
@@ -3879,14 +3926,14 @@ const rn = (e, n, t = "Wallet is performing an action, please wait...") => {
|
|
|
3879
3926
|
r,
|
|
3880
3927
|
n
|
|
3881
3928
|
]
|
|
3882
|
-
),
|
|
3883
|
-
async (
|
|
3929
|
+
), p = T(
|
|
3930
|
+
async (b) => {
|
|
3884
3931
|
if (rn(A, r), !e.isConnected || !e.currentProvider || !e.chainType)
|
|
3885
3932
|
throw new Error("Wallet not connected");
|
|
3886
|
-
const { message: w, nonce: I } =
|
|
3933
|
+
const { message: w, nonce: I } = b;
|
|
3887
3934
|
if (!w || w.length === 0)
|
|
3888
3935
|
throw new Error("Message is required");
|
|
3889
|
-
return t((
|
|
3936
|
+
return t((M) => ({ ...M, actionsLoading: !0 })), await qr(
|
|
3890
3937
|
{ message: w, nonce: I || Math.random().toString(36).substring(7) },
|
|
3891
3938
|
{
|
|
3892
3939
|
chainType: e.chainType,
|
|
@@ -3898,8 +3945,10 @@ const rn = (e, n, t = "Wallet is performing an action, please wait...") => {
|
|
|
3898
3945
|
walletInfo: e.currentWallet?.info,
|
|
3899
3946
|
isInstalled: e.currentWallet?.isInstalled
|
|
3900
3947
|
}
|
|
3901
|
-
).
|
|
3902
|
-
|
|
3948
|
+
).catch((M) => {
|
|
3949
|
+
throw console.error("signMessage error:", M), M;
|
|
3950
|
+
}).finally(() => {
|
|
3951
|
+
t((M) => ({ ...M, actionsLoading: !1 }));
|
|
3903
3952
|
});
|
|
3904
3953
|
},
|
|
3905
3954
|
[
|
|
@@ -3914,23 +3963,23 @@ const rn = (e, n, t = "Wallet is performing an action, please wait...") => {
|
|
|
3914
3963
|
t,
|
|
3915
3964
|
r
|
|
3916
3965
|
]
|
|
3917
|
-
),
|
|
3918
|
-
(
|
|
3966
|
+
), y = T(
|
|
3967
|
+
(b) => t((w) => ({ ...w, currentWallet: b })),
|
|
3919
3968
|
[t]
|
|
3920
3969
|
);
|
|
3921
3970
|
return {
|
|
3922
|
-
connect:
|
|
3971
|
+
connect: g,
|
|
3923
3972
|
disconnect: x,
|
|
3924
|
-
switchChain:
|
|
3973
|
+
switchChain: v,
|
|
3925
3974
|
signInWithWallet: m,
|
|
3926
|
-
signMessage:
|
|
3975
|
+
signMessage: p,
|
|
3927
3976
|
// signTransaction,
|
|
3928
3977
|
// signAndSendTransaction,
|
|
3929
3978
|
// sendTransaction,
|
|
3930
|
-
_setCurrentWallet:
|
|
3979
|
+
_setCurrentWallet: y
|
|
3931
3980
|
};
|
|
3932
|
-
},
|
|
3933
|
-
const e = V(
|
|
3981
|
+
}, ta = () => {
|
|
3982
|
+
const e = V(W);
|
|
3934
3983
|
if (!e)
|
|
3935
3984
|
throw new Error("useWalletConnect must be used within WalletConnectProvider");
|
|
3936
3985
|
return {
|
|
@@ -3947,17 +3996,17 @@ const rn = (e, n, t = "Wallet is performing an action, please wait...") => {
|
|
|
3947
3996
|
// Disconnect
|
|
3948
3997
|
disconnect: e.disconnect
|
|
3949
3998
|
};
|
|
3950
|
-
},
|
|
3951
|
-
const e = V(
|
|
3999
|
+
}, Uo = () => {
|
|
4000
|
+
const e = V(W), { handleSelectWallet: n } = Ke();
|
|
3952
4001
|
if (!e)
|
|
3953
4002
|
throw new Error("WalletConnectContext not found");
|
|
3954
|
-
const t = er(), r =
|
|
3955
|
-
return /* @__PURE__ */ i(S, { title: "Logged In", hideCloseButton: !0, children: /* @__PURE__ */
|
|
3956
|
-
/* @__PURE__ */
|
|
4003
|
+
const t = er(), r = rr(t?.wallet);
|
|
4004
|
+
return /* @__PURE__ */ i(S, { title: "Logged In", hideCloseButton: !0, children: /* @__PURE__ */ C("div", { className: "flex flex-col items-center justify-center py-12 gap-6 flex-1", children: [
|
|
4005
|
+
/* @__PURE__ */ C("div", { className: "flex flex-col items-center gap-2 text-sm text-foreground/60 text-center px-4", children: [
|
|
3957
4006
|
/* @__PURE__ */ i("p", { className: "text-lg font-semibold text-foreground", children: "You are logged in" }),
|
|
3958
4007
|
/* @__PURE__ */ i("p", { children: "Connect a wallet to get started" })
|
|
3959
4008
|
] }),
|
|
3960
|
-
/* @__PURE__ */
|
|
4009
|
+
/* @__PURE__ */ C("div", { className: "flex flex-col gap-2 w-full px-4", children: [
|
|
3961
4010
|
/* @__PURE__ */ i(X, { fullWidth: !0, size: "lg", variant: "solid", color: "primary", className: "rounded-full", onPress: () => {
|
|
3962
4011
|
r && n(r);
|
|
3963
4012
|
}, children: "Connect Wallet" }),
|
|
@@ -3966,12 +4015,12 @@ const rn = (e, n, t = "Wallet is performing an action, please wait...") => {
|
|
|
3966
4015
|
}, children: "Logout" })
|
|
3967
4016
|
] })
|
|
3968
4017
|
] }) });
|
|
3969
|
-
},
|
|
3970
|
-
const { links: n } =
|
|
3971
|
-
return /* @__PURE__ */
|
|
3972
|
-
e || /* @__PURE__ */ i(
|
|
3973
|
-
/* @__PURE__ */
|
|
3974
|
-
|
|
4018
|
+
}, Ge = ({ extendContent: e }) => {
|
|
4019
|
+
const { links: n } = ye;
|
|
4020
|
+
return /* @__PURE__ */ C("div", { className: "flex flex-col gap-2", children: [
|
|
4021
|
+
e || /* @__PURE__ */ i(Ro, {}),
|
|
4022
|
+
/* @__PURE__ */ C(
|
|
4023
|
+
Ee,
|
|
3975
4024
|
{
|
|
3976
4025
|
color: "primary",
|
|
3977
4026
|
target: "_blank",
|
|
@@ -3979,41 +4028,41 @@ const rn = (e, n, t = "Wallet is performing an action, please wait...") => {
|
|
|
3979
4028
|
className: "text-xs text-[#57534E] flex justify-center items-center gap-1",
|
|
3980
4029
|
children: [
|
|
3981
4030
|
/* @__PURE__ */ i("span", { children: "Powered by" }),
|
|
3982
|
-
/* @__PURE__ */ i(
|
|
4031
|
+
/* @__PURE__ */ i(yr, {})
|
|
3983
4032
|
]
|
|
3984
4033
|
}
|
|
3985
4034
|
)
|
|
3986
4035
|
] });
|
|
3987
|
-
},
|
|
3988
|
-
const { links: e } =
|
|
3989
|
-
return /* @__PURE__ */
|
|
4036
|
+
}, Ro = () => {
|
|
4037
|
+
const { links: e } = ye;
|
|
4038
|
+
return /* @__PURE__ */ C("div", { className: "text-xs text-[#A9A29D] text-center", children: [
|
|
3990
4039
|
/* @__PURE__ */ i("p", { children: "By connecting your wallet, you agree to" }),
|
|
3991
|
-
/* @__PURE__ */
|
|
4040
|
+
/* @__PURE__ */ C("p", { children: [
|
|
3992
4041
|
"our",
|
|
3993
4042
|
" ",
|
|
3994
|
-
/* @__PURE__ */ i(
|
|
4043
|
+
/* @__PURE__ */ i(Ee, { color: "primary", className: "text-xs", underline: "hover", href: e.termsOfService, target: "_blank", children: "Terms of Service" }),
|
|
3995
4044
|
" ",
|
|
3996
4045
|
"&",
|
|
3997
4046
|
" ",
|
|
3998
|
-
/* @__PURE__ */ i(
|
|
4047
|
+
/* @__PURE__ */ i(Ee, { color: "primary", className: "text-xs", underline: "hover", href: e.privacyPolicy, target: "_blank", children: "Privacy Policy" }),
|
|
3999
4048
|
"."
|
|
4000
4049
|
] })
|
|
4001
4050
|
] });
|
|
4002
|
-
},
|
|
4051
|
+
}, _o = ({ wallet: e, onSelectWallet: n }) => {
|
|
4003
4052
|
const { info: t, isInstalled: r } = e, s = B(() => {
|
|
4004
4053
|
if (!r) return null;
|
|
4005
4054
|
const o = t?.uuid === "walletConnect";
|
|
4006
4055
|
return /* @__PURE__ */ i("span", { className: "text-xs line-height-[140px] font-normal text-[#A9A29D]", children: o ? "QR Code" : "Installed" });
|
|
4007
4056
|
}, [t?.uuid, r]);
|
|
4008
|
-
return /* @__PURE__ */ i(
|
|
4057
|
+
return /* @__PURE__ */ i(hr, { isPressable: !0, isHoverable: !0, shadow: "none", radius: "sm", onPress: () => n?.(e), children: /* @__PURE__ */ C(Mr, { className: "flex flex-col items-center gap-1 px-0 py-2", children: [
|
|
4009
4058
|
/* @__PURE__ */ i("div", { className: "p-1 h-[56px]", children: /* @__PURE__ */ i(ne, { src: t.icon, alt: t.name, width: 48, height: 48, removeWrapper: !0, radius: "md" }) }),
|
|
4010
|
-
/* @__PURE__ */
|
|
4059
|
+
/* @__PURE__ */ C("div", { className: "flex flex-col justify-center items-center scale-80 text-center", children: [
|
|
4011
4060
|
/* @__PURE__ */ i("span", { className: "text-sm font-medium", children: t.name }),
|
|
4012
4061
|
s
|
|
4013
4062
|
] })
|
|
4014
4063
|
] }) }, t.uuid);
|
|
4015
4064
|
};
|
|
4016
|
-
function
|
|
4065
|
+
function $o({ wallets: e, loading: n, onSelectWallet: t }) {
|
|
4017
4066
|
return n ? /* @__PURE__ */ i(
|
|
4018
4067
|
te,
|
|
4019
4068
|
{
|
|
@@ -4024,15 +4073,15 @@ function Go({ wallets: e, loading: n, onSelectWallet: t }) {
|
|
|
4024
4073
|
},
|
|
4025
4074
|
className: "m-auto"
|
|
4026
4075
|
}
|
|
4027
|
-
) : e.length === 0 ? /* @__PURE__ */ i("div", { className: "flex flex-col items-center justify-center py-12", children: /* @__PURE__ */ i("p", { className: "text-gray-600", children: "No wallets found" }) }) : /* @__PURE__ */ i("div", { className: "grid grid-cols-4", children: e.map((r) => /* @__PURE__ */ i(
|
|
4076
|
+
) : e.length === 0 ? /* @__PURE__ */ i("div", { className: "flex flex-col items-center justify-center py-12", children: /* @__PURE__ */ i("p", { className: "text-gray-600", children: "No wallets found" }) }) : /* @__PURE__ */ i("div", { className: "grid grid-cols-4", children: e.map((r) => /* @__PURE__ */ i(_o, { wallet: r, onSelectWallet: t }, r.info?.uuid)) });
|
|
4028
4077
|
}
|
|
4029
|
-
const
|
|
4078
|
+
const ec = {
|
|
4030
4079
|
evm: { tabKey: "evm", chainKey: "evm" },
|
|
4031
4080
|
solana: { tabKey: "solana", chainKey: "solana" },
|
|
4032
4081
|
aptos: { tabKey: "aptos", chainKey: "aptos" },
|
|
4033
4082
|
dogecoin: { tabKey: "doge", chainKey: "dogecoin" }
|
|
4034
|
-
},
|
|
4035
|
-
const t = V(
|
|
4083
|
+
}, nc = ({ selectedKey: e, onSelectionChange: n }) => {
|
|
4084
|
+
const t = V(W), r = B(() => {
|
|
4036
4085
|
const o = t?.config?.chains || {}, c = [
|
|
4037
4086
|
{
|
|
4038
4087
|
key: "all",
|
|
@@ -4041,7 +4090,7 @@ const Uo = {
|
|
|
4041
4090
|
}
|
|
4042
4091
|
];
|
|
4043
4092
|
return Object.keys(o).forEach((a) => {
|
|
4044
|
-
const l =
|
|
4093
|
+
const l = ec[a];
|
|
4045
4094
|
if (l) {
|
|
4046
4095
|
const A = O[l.chainKey];
|
|
4047
4096
|
c.push({
|
|
@@ -4053,30 +4102,30 @@ const Uo = {
|
|
|
4053
4102
|
}), c;
|
|
4054
4103
|
}, [t?.config?.chains]), s = (o) => o.icon ? /* @__PURE__ */ i(le, { icon: o.icon, className: "size-6 overflow-hidden rounded-full" }) : o.title;
|
|
4055
4104
|
return /* @__PURE__ */ i(
|
|
4056
|
-
|
|
4105
|
+
Wr,
|
|
4057
4106
|
{
|
|
4058
4107
|
variant: "bordered",
|
|
4059
4108
|
fullWidth: !0,
|
|
4060
4109
|
selectedKey: e,
|
|
4061
4110
|
onSelectionChange: (o) => n(o),
|
|
4062
|
-
children: r.map((o) => /* @__PURE__ */ i(
|
|
4111
|
+
children: r.map((o) => /* @__PURE__ */ i(Vr, { title: s(o) }, o.key))
|
|
4063
4112
|
}
|
|
4064
4113
|
);
|
|
4065
|
-
},
|
|
4114
|
+
}, tc = ({ wallet: e, onSelectWallet: n }) => {
|
|
4066
4115
|
const { info: t, isInstalled: r } = e, s = B(() => r ? t?.uuid === "walletConnect" ? /* @__PURE__ */ i(Ln, { className: "text-xs text-[#D7D3D0] border h-5", variant: "dot", children: "QR Code" }) : /* @__PURE__ */ i(Ln, { className: "text-xs text-[#D7D3D0] border h-5", variant: "dot", children: "Installed" }) : null, [t?.uuid, r]);
|
|
4067
4116
|
return /* @__PURE__ */ i(
|
|
4068
|
-
|
|
4117
|
+
Ar,
|
|
4069
4118
|
{
|
|
4070
4119
|
onPress: () => n?.(e),
|
|
4071
|
-
startContent: /* @__PURE__ */ i(
|
|
4120
|
+
startContent: /* @__PURE__ */ i(lr, { icon: t?.icon, title: t?.name }),
|
|
4072
4121
|
endContent: s
|
|
4073
4122
|
},
|
|
4074
4123
|
e.info.uuid
|
|
4075
4124
|
);
|
|
4076
|
-
},
|
|
4125
|
+
}, lr = ({ icon: e, title: n }) => /* @__PURE__ */ C("div", { className: "flex items-center gap-2", children: [
|
|
4077
4126
|
typeof e == "string" ? /* @__PURE__ */ i(ne, { src: e, alt: n, width: 32, height: 32, radius: "md" }) : e,
|
|
4078
4127
|
/* @__PURE__ */ i("span", { className: "text-sm font-medium text-foreground", children: n })
|
|
4079
|
-
] }),
|
|
4128
|
+
] }), Ar = (e) => /* @__PURE__ */ i(
|
|
4080
4129
|
X,
|
|
4081
4130
|
{
|
|
4082
4131
|
fullWidth: !0,
|
|
@@ -4089,7 +4138,7 @@ const Uo = {
|
|
|
4089
4138
|
children: /* @__PURE__ */ i("span", {})
|
|
4090
4139
|
}
|
|
4091
4140
|
);
|
|
4092
|
-
function
|
|
4141
|
+
function rc({ wallets: e, loading: n, onSelectWallet: t }) {
|
|
4093
4142
|
return n ? /* @__PURE__ */ i(
|
|
4094
4143
|
te,
|
|
4095
4144
|
{
|
|
@@ -4100,47 +4149,47 @@ function $o({ wallets: e, loading: n, onSelectWallet: t }) {
|
|
|
4100
4149
|
circle2: "border-b-primary"
|
|
4101
4150
|
}
|
|
4102
4151
|
}
|
|
4103
|
-
) : e.length === 0 ? /* @__PURE__ */ i("div", { className: "flex flex-col items-center justify-center py-12", children: /* @__PURE__ */ i("p", { className: "text-gray-600", children: "No wallets found" }) }) : /* @__PURE__ */ i("div", { className: "flex flex-col gap-2", children: e.map((r) => /* @__PURE__ */ i(
|
|
4152
|
+
) : e.length === 0 ? /* @__PURE__ */ i("div", { className: "flex flex-col items-center justify-center py-12", children: /* @__PURE__ */ i("p", { className: "text-gray-600", children: "No wallets found" }) }) : /* @__PURE__ */ i("div", { className: "flex flex-col gap-2", children: e.map((r) => /* @__PURE__ */ i(tc, { wallet: r, onSelectWallet: t }, r.info?.uuid)) });
|
|
4104
4153
|
}
|
|
4105
|
-
const
|
|
4106
|
-
const e = V(
|
|
4154
|
+
const sc = () => {
|
|
4155
|
+
const e = V(W), { handleSelectWallet: n } = Ke(), { data: t, isLoading: r } = he(k.All, e?.config?.connectors), [s, o] = B(() => {
|
|
4107
4156
|
const a = t?.recommoned || [], l = t?.all || [];
|
|
4108
|
-
return
|
|
4157
|
+
return us(a, l);
|
|
4109
4158
|
}, [t]);
|
|
4110
|
-
return /* @__PURE__ */ i(S, { title: "Connect your wallet", children: /* @__PURE__ */
|
|
4111
|
-
/* @__PURE__ */ i("div", { className: "space-y-2 h-[312px] max-h-[312px] overflow-y-auto [&::-webkit-scrollbar]:hidden [-ms-overflow-style:none] [scrollbar-width:none]", children: /* @__PURE__ */ i("div", { className: `flex flex-col gap-2 h-full ${r ? "justify-center" : ""}`, children: /* @__PURE__ */ i(
|
|
4159
|
+
return /* @__PURE__ */ i(S, { title: "Connect your wallet", children: /* @__PURE__ */ C("div", { className: "flex flex-col gap-4", children: [
|
|
4160
|
+
/* @__PURE__ */ i("div", { className: "space-y-2 h-[312px] max-h-[312px] overflow-y-auto [&::-webkit-scrollbar]:hidden [-ms-overflow-style:none] [scrollbar-width:none]", children: /* @__PURE__ */ i("div", { className: `flex flex-col gap-2 h-full ${r ? "justify-center" : ""}`, children: /* @__PURE__ */ i(rc, { loading: r, wallets: s, onSelectWallet: n }) }) }),
|
|
4112
4161
|
r ? null : /* @__PURE__ */ i(
|
|
4113
|
-
|
|
4162
|
+
Ar,
|
|
4114
4163
|
{
|
|
4115
4164
|
onPress: () => e?.modal.setView(P.WalletSearch),
|
|
4116
|
-
startContent: /* @__PURE__ */ i(
|
|
4165
|
+
startContent: /* @__PURE__ */ i(lr, { icon: /* @__PURE__ */ i(Xr, {}), title: "Search more wallets" }),
|
|
4117
4166
|
endContent: /* @__PURE__ */ i("span", { className: "text-[#A9A29D] text-sm", children: o.length })
|
|
4118
4167
|
}
|
|
4119
4168
|
),
|
|
4120
|
-
/* @__PURE__ */ i(
|
|
4169
|
+
/* @__PURE__ */ i(Ge, {})
|
|
4121
4170
|
] }) });
|
|
4122
|
-
},
|
|
4123
|
-
const e = V(
|
|
4124
|
-
(
|
|
4125
|
-
e?.modal.setCurrentViewState({ chainType:
|
|
4171
|
+
}, ic = bn, oc = () => {
|
|
4172
|
+
const e = V(W), { handleSelectWallet: n } = Ke(), t = e?.modal.state, r = B(() => t?.chainType || "all", [t?.chainType]), { data: s, isLoading: o } = he(r, e?.config?.connectors), c = B(() => s?.all || [], [s]), [a, l] = N(""), { isKeyboardVisible: A, keyboardHeight: d } = To(), f = B(() => c.filter((v) => v.info?.name?.toLowerCase().includes(a.toLowerCase())).filter((v) => !v.isEmbeddedWallet), [c, a]), u = So([r]), g = B(() => A && d > 0 ? `${Math.max(180, 340 - d * 0.6)}px` : "340px", [A, d]), x = T(
|
|
4173
|
+
(v) => {
|
|
4174
|
+
e?.modal.setCurrentViewState({ chainType: v });
|
|
4126
4175
|
},
|
|
4127
4176
|
[e]
|
|
4128
4177
|
);
|
|
4129
|
-
return /* @__PURE__ */ i(S, { title: "All wallets", onBack: () => e?.modal.backView(), children: /* @__PURE__ */
|
|
4178
|
+
return /* @__PURE__ */ i(S, { title: "All wallets", onBack: () => e?.modal.backView(), children: /* @__PURE__ */ C("div", { className: "flex flex-col gap-4 min-h-0", children: [
|
|
4130
4179
|
/* @__PURE__ */ i(
|
|
4131
|
-
|
|
4180
|
+
nc,
|
|
4132
4181
|
{
|
|
4133
4182
|
selectedKey: t?.chainType || "all",
|
|
4134
|
-
onSelectionChange: (
|
|
4183
|
+
onSelectionChange: (v) => x(v)
|
|
4135
4184
|
}
|
|
4136
4185
|
),
|
|
4137
4186
|
/* @__PURE__ */ i(
|
|
4138
|
-
|
|
4187
|
+
ic,
|
|
4139
4188
|
{
|
|
4140
4189
|
placeholder: "Search wallet",
|
|
4141
4190
|
value: a,
|
|
4142
|
-
onChange: (
|
|
4143
|
-
startContent: /* @__PURE__ */ i(
|
|
4191
|
+
onChange: (v) => l(v.target.value),
|
|
4192
|
+
startContent: /* @__PURE__ */ i(Nr, {}),
|
|
4144
4193
|
classNames: {
|
|
4145
4194
|
inputWrapper: "rounded-full h-11"
|
|
4146
4195
|
}
|
|
@@ -4149,40 +4198,40 @@ const ec = () => {
|
|
|
4149
4198
|
/* @__PURE__ */ i(
|
|
4150
4199
|
"div",
|
|
4151
4200
|
{
|
|
4152
|
-
ref:
|
|
4201
|
+
ref: u,
|
|
4153
4202
|
className: "space-y-2 shrink-0 overflow-y-auto transition-all duration-200 [&::-webkit-scrollbar]:hidden [-ms-overflow-style:none] [scrollbar-width:none]",
|
|
4154
4203
|
style: {
|
|
4155
|
-
height:
|
|
4156
|
-
maxHeight:
|
|
4204
|
+
height: g,
|
|
4205
|
+
maxHeight: g
|
|
4157
4206
|
},
|
|
4158
4207
|
children: /* @__PURE__ */ i("div", { className: `flex flex-col gap-2 h-full ${o ? "justify-center" : ""}`, children: /* @__PURE__ */ i(
|
|
4159
|
-
|
|
4208
|
+
$o,
|
|
4160
4209
|
{
|
|
4161
4210
|
loading: o,
|
|
4162
4211
|
wallets: f,
|
|
4163
|
-
onSelectWallet: (
|
|
4212
|
+
onSelectWallet: (v) => n(v, r)
|
|
4164
4213
|
}
|
|
4165
4214
|
) })
|
|
4166
4215
|
}
|
|
4167
4216
|
),
|
|
4168
|
-
/* @__PURE__ */ i(
|
|
4217
|
+
/* @__PURE__ */ i(Ge, {})
|
|
4169
4218
|
] }) });
|
|
4170
|
-
},
|
|
4171
|
-
const e = V(
|
|
4219
|
+
}, dr = () => Fo, cc = () => {
|
|
4220
|
+
const e = V(W);
|
|
4172
4221
|
if (!e)
|
|
4173
4222
|
return { themeMode: "dark", themeType: "doge_dark" };
|
|
4174
|
-
const { themeMode: n } = e.config || { themeMode: "dark" }, t =
|
|
4223
|
+
const { themeMode: n } = e.config || { themeMode: "dark" }, t = dr(e.config?.clientId || "");
|
|
4175
4224
|
return { themeMode: n, themeType: t, isDark: n === "dark" };
|
|
4176
4225
|
}, xn = ({
|
|
4177
4226
|
text: e = "or",
|
|
4178
4227
|
className: n = "",
|
|
4179
4228
|
lineClassName: t = "bg-[#292524]",
|
|
4180
4229
|
textClassName: r = "text-sm text-[#78716C]"
|
|
4181
|
-
}) => /* @__PURE__ */
|
|
4230
|
+
}) => /* @__PURE__ */ C("div", { className: `flex items-center gap-4 ${n}`, children: [
|
|
4182
4231
|
/* @__PURE__ */ i("div", { className: `flex-1 h-px ${t}` }),
|
|
4183
4232
|
/* @__PURE__ */ i("span", { className: r, children: e }),
|
|
4184
4233
|
/* @__PURE__ */ i("div", { className: `flex-1 h-px ${t}` })
|
|
4185
|
-
] }),
|
|
4234
|
+
] }), fr = ({ isLoading: e = !1, text: n = "Loading..." }) => e ? /* @__PURE__ */ i("div", { className: "absolute inset-0 backdrop-blur-sm z-50 flex items-center justify-center", children: /* @__PURE__ */ C("div", { className: "flex flex-col items-center gap-3", children: [
|
|
4186
4235
|
/* @__PURE__ */ i(
|
|
4187
4236
|
te,
|
|
4188
4237
|
{
|
|
@@ -4194,7 +4243,7 @@ const ec = () => {
|
|
|
4194
4243
|
}
|
|
4195
4244
|
),
|
|
4196
4245
|
/* @__PURE__ */ i("span", { className: "text-foreground text-sm font-medium", children: n })
|
|
4197
|
-
] }) }) : null,
|
|
4246
|
+
] }) }) : null, ur = ({ className: e, width: n = 24, height: t = 24 }) => /* @__PURE__ */ C(
|
|
4198
4247
|
"svg",
|
|
4199
4248
|
{
|
|
4200
4249
|
width: n,
|
|
@@ -4234,7 +4283,7 @@ const ec = () => {
|
|
|
4234
4283
|
)
|
|
4235
4284
|
]
|
|
4236
4285
|
}
|
|
4237
|
-
),
|
|
4286
|
+
), gr = ({ className: e, width: n = 24, height: t = 24, fill: r = "white" }) => /* @__PURE__ */ i(
|
|
4238
4287
|
"svg",
|
|
4239
4288
|
{
|
|
4240
4289
|
width: n,
|
|
@@ -4245,15 +4294,15 @@ const ec = () => {
|
|
|
4245
4294
|
className: e,
|
|
4246
4295
|
children: /* @__PURE__ */ i("path", { d: "M18.244 2.25h3.308l-7.227 8.26 8.502 11.24H16.17l-5.214-6.817L4.99 21.75H1.68l7.73-8.835L1.254 2.25H8.08l4.713 6.231zm-1.161 17.52h1.833L7.084 4.126H5.117z" })
|
|
4247
4296
|
}
|
|
4248
|
-
),
|
|
4249
|
-
const e = V(
|
|
4297
|
+
), ac = bn, lc = () => {
|
|
4298
|
+
const e = V(W), { isLoading: n, handleEmailLogin: t, handleGoogleLogin: r, handleXLogin: s } = sr({
|
|
4250
4299
|
closeModalBeforeIframe: !0
|
|
4251
4300
|
});
|
|
4252
4301
|
if (!e)
|
|
4253
4302
|
throw new Error("WalletConnectContext not found");
|
|
4254
4303
|
const [o, c] = N(e.modal.state?.email || "");
|
|
4255
|
-
|
|
4256
|
-
e.modal.state?.error && (
|
|
4304
|
+
Y(() => {
|
|
4305
|
+
e.modal.state?.error && (jr({
|
|
4257
4306
|
title: e.modal.state.error,
|
|
4258
4307
|
color: "danger",
|
|
4259
4308
|
timeout: 3e3,
|
|
@@ -4264,13 +4313,13 @@ const ec = () => {
|
|
|
4264
4313
|
await t(o);
|
|
4265
4314
|
}, l = () => {
|
|
4266
4315
|
e.modal.setView(P.WalletSearch);
|
|
4267
|
-
}, { isDark: A } =
|
|
4268
|
-
return console.log("context.modal.state: ", n, e.modal.state?.isLoading), /* @__PURE__ */
|
|
4316
|
+
}, { isDark: A } = cc();
|
|
4317
|
+
return console.log("context.modal.state: ", n, e.modal.state?.isLoading), /* @__PURE__ */ C(
|
|
4269
4318
|
S,
|
|
4270
4319
|
{
|
|
4271
4320
|
title: "Log in or sign up",
|
|
4272
|
-
headerRightContent: /* @__PURE__ */
|
|
4273
|
-
|
|
4321
|
+
headerRightContent: /* @__PURE__ */ C(
|
|
4322
|
+
Ee,
|
|
4274
4323
|
{
|
|
4275
4324
|
className: "text-sm text-[#78716C] hover:text-primary cursor-pointer flex items-center gap-1",
|
|
4276
4325
|
onPress: l,
|
|
@@ -4281,10 +4330,10 @@ const ec = () => {
|
|
|
4281
4330
|
}
|
|
4282
4331
|
),
|
|
4283
4332
|
children: [
|
|
4284
|
-
/* @__PURE__ */ i(
|
|
4285
|
-
/* @__PURE__ */
|
|
4286
|
-
/* @__PURE__ */
|
|
4287
|
-
/* @__PURE__ */
|
|
4333
|
+
/* @__PURE__ */ i(fr, { isLoading: n || e.modal.state?.isLoading }),
|
|
4334
|
+
/* @__PURE__ */ C("div", { className: "flex flex-col justify-between min-h-0 flex-1 pt-8", children: [
|
|
4335
|
+
/* @__PURE__ */ C("div", { className: "flex flex-col gap-6", children: [
|
|
4336
|
+
/* @__PURE__ */ C("div", { className: "flex gap-3 pb-6", children: [
|
|
4288
4337
|
/* @__PURE__ */ i(
|
|
4289
4338
|
X,
|
|
4290
4339
|
{
|
|
@@ -4293,7 +4342,7 @@ const ec = () => {
|
|
|
4293
4342
|
variant: "bordered",
|
|
4294
4343
|
className: "h-12 rounded-2xl border-primary border-2 bg-primary-50",
|
|
4295
4344
|
onPress: s,
|
|
4296
|
-
startContent: /* @__PURE__ */ i(
|
|
4345
|
+
startContent: /* @__PURE__ */ i(gr, { width: 20, height: 20, fill: A ? "white" : "black" }),
|
|
4297
4346
|
children: /* @__PURE__ */ i("span", { className: "text-base font-medium", children: "Twitter" })
|
|
4298
4347
|
}
|
|
4299
4348
|
),
|
|
@@ -4305,7 +4354,7 @@ const ec = () => {
|
|
|
4305
4354
|
variant: "solid",
|
|
4306
4355
|
className: "h-12 rounded-2xl bg-background",
|
|
4307
4356
|
onPress: r,
|
|
4308
|
-
startContent: /* @__PURE__ */ i(
|
|
4357
|
+
startContent: /* @__PURE__ */ i(ur, { width: 20, height: 20 }),
|
|
4309
4358
|
children: /* @__PURE__ */ i("span", { className: "text-base font-medium", children: "Google" })
|
|
4310
4359
|
}
|
|
4311
4360
|
)
|
|
@@ -4318,9 +4367,9 @@ const ec = () => {
|
|
|
4318
4367
|
text: "or continue with"
|
|
4319
4368
|
}
|
|
4320
4369
|
),
|
|
4321
|
-
/* @__PURE__ */
|
|
4370
|
+
/* @__PURE__ */ C("div", { className: "flex flex-col gap-5 items-center pb-8", children: [
|
|
4322
4371
|
/* @__PURE__ */ i(
|
|
4323
|
-
|
|
4372
|
+
ac,
|
|
4324
4373
|
{
|
|
4325
4374
|
type: "email",
|
|
4326
4375
|
placeholder: "Enter your email",
|
|
@@ -4354,19 +4403,19 @@ const ec = () => {
|
|
|
4354
4403
|
)
|
|
4355
4404
|
] })
|
|
4356
4405
|
] }),
|
|
4357
|
-
/* @__PURE__ */ i("div", { className: "mt-5", children: /* @__PURE__ */ i(
|
|
4406
|
+
/* @__PURE__ */ i("div", { className: "mt-5", children: /* @__PURE__ */ i(Ge, {}) })
|
|
4358
4407
|
] })
|
|
4359
4408
|
]
|
|
4360
4409
|
}
|
|
4361
4410
|
);
|
|
4362
|
-
},
|
|
4411
|
+
}, Ac = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGAAAAAgCAYAAADtwH1UAAAACXBIWXMAABYlAAAWJQFJUiTwAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAA4eSURBVHgBvVoJcBRVGv5eT8+Vc0KQSwKDIJccEWFFFIMu4oUQd9li0VUDuqulW0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94vkOsO4qyD6YenbAkO2nCJkH52njdJMjL2LGjS+dP7rPUEOXxWlIObJcT84wnHSvYx48REpIJevQmpk1/o+iYbhbdriy9gDSUHr6fen09LR8Qm2v6tcs35EHc/21bxSUvhTVorZUGD3dqvCCMfpFgpC1Ind7aO7ALhP8d1ZFP5wsIq83BuBXnqtOZPc9hE6lllHs6toHKTdTCX0xZcYg/ncnhpHcylKIf3ezfRo6qMD+fGEx/WbXO28f7xHOrG+Vcv4o5n8/F0gq7avK7ex9ObXi322LJRSoyYQ+9Npc1fb8/j6cJnHE9HbaQNWwuu7X08fVedr/SdvR1zPv3ujKltoWxve9jtYUjKc7T7C5xtvglDA3U/n2yvnTbZm/h4eps8Xj6Hxk04f3k8XUMtcvs8nj6HSuL+GRxP/z/hFFWXpmDkiwAAAABJRU5ErkJggg==", dc = () => {
|
|
4363
4412
|
const { walletState: e } = Nn(), { chainType: n, chainId: t } = e, { switchChain: r } = jn();
|
|
4364
4413
|
return wn({
|
|
4365
4414
|
mutationKey: ["switch-chain", n, t],
|
|
4366
4415
|
mutationFn: async (s) => r(s)
|
|
4367
4416
|
});
|
|
4368
4417
|
}, st = ({ chainType: e, chain: n }) => {
|
|
4369
|
-
const { mutateAsync: t, isPending: r } =
|
|
4418
|
+
const { mutateAsync: t, isPending: r } = dc(), s = V(W), { connectWallet: o } = qe();
|
|
4370
4419
|
if (!n || !s)
|
|
4371
4420
|
throw new Error(`Chain ${e} not found`);
|
|
4372
4421
|
const { currentWallet: c } = s.account;
|
|
@@ -4375,7 +4424,7 @@ const ec = () => {
|
|
|
4375
4424
|
const { chainType: a, chainId: l } = jn(), A = Number(BigInt(l || "0").toString()), d = B(() => {
|
|
4376
4425
|
const x = a?.toLowerCase() === e?.toLowerCase();
|
|
4377
4426
|
return a === "evm" ? x && A === n?.id : x;
|
|
4378
|
-
}, [n?.id, A, e, a]), f = B(() => c?.providers?.[e]?.provider, [c, e]),
|
|
4427
|
+
}, [n?.id, A, e, a]), f = B(() => c?.providers?.[e]?.provider, [c, e]), u = B(() => d ? /* @__PURE__ */ i("div", { className: "size-5 bg-[#079555] rounded-full flex items-center justify-center", children: /* @__PURE__ */ i(lt, { className: "size-3", color: "white" }) }) : r ? /* @__PURE__ */ i(
|
|
4379
4428
|
te,
|
|
4380
4429
|
{
|
|
4381
4430
|
size: "sm",
|
|
@@ -4384,7 +4433,7 @@ const ec = () => {
|
|
|
4384
4433
|
circle2: "border-b-primary"
|
|
4385
4434
|
}
|
|
4386
4435
|
}
|
|
4387
|
-
) : /* @__PURE__ */ i(zn, { className: "size-4" }), [r, d]),
|
|
4436
|
+
) : /* @__PURE__ */ i(zn, { className: "size-4" }), [r, d]), g = () => {
|
|
4388
4437
|
if (!(r || d)) {
|
|
4389
4438
|
if (a !== e) {
|
|
4390
4439
|
f ? o(c, e) : s.modal.setView(P.ChangeNetwork, n);
|
|
@@ -4411,12 +4460,12 @@ const ec = () => {
|
|
|
4411
4460
|
className: `border justify-between border-primary gap-3 hover:bg-primary/50 ${d ? "bg-primary" : ""}`,
|
|
4412
4461
|
"aria-label": `${n?.name}`,
|
|
4413
4462
|
startContent: /* @__PURE__ */ i(le, { icon: n?.chainInfo?.icon, className: "size-8 overflow-hidden rounded-full" }),
|
|
4414
|
-
endContent:
|
|
4415
|
-
onPress:
|
|
4463
|
+
endContent: u,
|
|
4464
|
+
onPress: g,
|
|
4416
4465
|
children: /* @__PURE__ */ i("span", { className: "flex-1 text-left text-sm font-medium", children: n?.chainInfo?.name })
|
|
4417
4466
|
}
|
|
4418
4467
|
);
|
|
4419
|
-
},
|
|
4468
|
+
}, fc = ({ chains: e }) => {
|
|
4420
4469
|
const { chainType: n } = jn(), { currentChains: t, otherChains: r } = B(() => {
|
|
4421
4470
|
const s = [], o = [];
|
|
4422
4471
|
return e.map((c) => {
|
|
@@ -4430,25 +4479,25 @@ const ec = () => {
|
|
|
4430
4479
|
key: "chains",
|
|
4431
4480
|
currentChains: t,
|
|
4432
4481
|
otherChains: r
|
|
4433
|
-
}), /* @__PURE__ */
|
|
4434
|
-
t[0]?.chainType === "evm" && /* @__PURE__ */
|
|
4482
|
+
}), /* @__PURE__ */ C("div", { className: "flex flex-col w-full", children: [
|
|
4483
|
+
t[0]?.chainType === "evm" && /* @__PURE__ */ C("div", { className: "text-sm flex gap-2 mt-2 mb-4 items-center", children: [
|
|
4435
4484
|
/* @__PURE__ */ i("span", { children: "EVM network" }),
|
|
4436
|
-
/* @__PURE__ */ i("img", { src:
|
|
4485
|
+
/* @__PURE__ */ i("img", { src: Ac, alt: "Evm chains", className: "h-4 w-auto" })
|
|
4437
4486
|
] }),
|
|
4438
4487
|
/* @__PURE__ */ i("div", { className: "flex flex-col gap-1 w-full mb-4", children: t?.map((s, o) => /* @__PURE__ */ i(st, { chainType: s.chainType, chain: s }, `${s.name}-${o}`)) }),
|
|
4439
4488
|
/* @__PURE__ */ i("div", { className: "text-sm flex gap-2 mt-2 mb-4", children: /* @__PURE__ */ i("span", { children: "Other network" }) }),
|
|
4440
4489
|
/* @__PURE__ */ i("div", { className: "flex flex-col gap-1 w-full mb-4", children: r?.map((s, o) => /* @__PURE__ */ i(st, { chainType: s.chainType, chain: s }, `${s.name}-${o}`)) })
|
|
4441
4490
|
] });
|
|
4442
|
-
},
|
|
4443
|
-
const e = V(
|
|
4491
|
+
}, uc = () => {
|
|
4492
|
+
const e = V(W);
|
|
4444
4493
|
if (!e)
|
|
4445
4494
|
throw new Error("WalletConnectContext not found");
|
|
4446
4495
|
const { currentWallet: n } = e.account;
|
|
4447
4496
|
if (!n)
|
|
4448
4497
|
throw new Error("Current wallet not found");
|
|
4449
4498
|
const t = _t(e.config?.chains, n?.providers);
|
|
4450
|
-
return /* @__PURE__ */ i(S, { title: "Select network", onBack: () => e?.modal.backView(), children: /* @__PURE__ */ i("div", { className: "flex flex-col items-center justify-center", children: /* @__PURE__ */ i(
|
|
4451
|
-
},
|
|
4499
|
+
return /* @__PURE__ */ i(S, { title: "Select network", onBack: () => e?.modal.backView(), children: /* @__PURE__ */ i("div", { className: "flex flex-col items-center justify-center", children: /* @__PURE__ */ i(fc, { chains: t }) }) });
|
|
4500
|
+
}, gc = ({ chainType: e, onSelect: n }) => {
|
|
4452
4501
|
const t = O[e];
|
|
4453
4502
|
if (!t)
|
|
4454
4503
|
throw new Error(`Chain ${e} not found`);
|
|
@@ -4467,19 +4516,19 @@ const ec = () => {
|
|
|
4467
4516
|
children: /* @__PURE__ */ i("span", { className: "flex-1 text-left text-sm font-medium", children: O[e].name })
|
|
4468
4517
|
}
|
|
4469
4518
|
);
|
|
4470
|
-
},
|
|
4471
|
-
|
|
4519
|
+
}, vc = ({ providers: e, onSelect: n }) => /* @__PURE__ */ i("div", { className: "flex flex-col gap-2 w-full pb-6", children: e.map((t, r) => /* @__PURE__ */ i(
|
|
4520
|
+
gc,
|
|
4472
4521
|
{
|
|
4473
4522
|
chainType: t.chainType,
|
|
4474
4523
|
provider: t.provider,
|
|
4475
4524
|
onSelect: () => n(t.chainType)
|
|
4476
4525
|
},
|
|
4477
4526
|
`${t.chainType}-${t.protocol}-${r}`
|
|
4478
|
-
)) }),
|
|
4479
|
-
const e = V(
|
|
4527
|
+
)) }), Cc = () => {
|
|
4528
|
+
const e = V(W);
|
|
4480
4529
|
if (!e)
|
|
4481
4530
|
throw new Error("WalletConnectContext not found");
|
|
4482
|
-
const { connectWallet: n } =
|
|
4531
|
+
const { connectWallet: n } = qe(), { currentWallet: t } = e.account;
|
|
4483
4532
|
if (!t)
|
|
4484
4533
|
throw new Error("Current wallet not found");
|
|
4485
4534
|
const r = B(() => t?.info, [t?.info]), s = B(() => {
|
|
@@ -4498,18 +4547,18 @@ const ec = () => {
|
|
|
4498
4547
|
},
|
|
4499
4548
|
[n, t]
|
|
4500
4549
|
);
|
|
4501
|
-
return /* @__PURE__ */ i(S, { title: "Select network", onBack: () => e?.modal.backView(), children: /* @__PURE__ */
|
|
4550
|
+
return /* @__PURE__ */ i(S, { title: "Select network", onBack: () => e?.modal.backView(), children: /* @__PURE__ */ C("div", { className: "flex flex-col items-center justify-center", children: [
|
|
4502
4551
|
/* @__PURE__ */ i("div", { className: "flex items-center justify-center mb-6", children: /* @__PURE__ */ i(ne, { src: r.icon, alt: r.name, width: 48, height: 48 }) }),
|
|
4503
|
-
/* @__PURE__ */
|
|
4552
|
+
/* @__PURE__ */ C("p", { className: "text-sm text-foreground/60 mb-6 text-center", children: [
|
|
4504
4553
|
/* @__PURE__ */ i("span", { className: "text-foreground", children: r.name }),
|
|
4505
4554
|
" supports multiple networks.",
|
|
4506
4555
|
/* @__PURE__ */ i("br", {}),
|
|
4507
4556
|
"Please select the network you'd like to connect to."
|
|
4508
4557
|
] }),
|
|
4509
|
-
/* @__PURE__ */ i(
|
|
4558
|
+
/* @__PURE__ */ i(vc, { providers: s, onSelect: o })
|
|
4510
4559
|
] }) });
|
|
4511
|
-
}, gc = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTUwIiBoZWlnaHQ9IjE1MCIgdmlld0JveD0iMCAwIDE1MCAxNTAiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgPGZvcmVpZ25PYmplY3QgeD0iMjEuMDg4MiIgeT0iMjEuNTg0MyIgd2lkdGg9IjEwNi45MjgiIGhlaWdodD0iMTA2LjkzNSI+PGRpdiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94aHRtbCIgc3R5bGU9ImJhY2tkcm9wLWZpbHRlcjpibHVyKDAuNjlweCk7Y2xpcC1wYXRoOnVybCgjYmdibHVyXzBfMTQxXzExMDJfY2xpcF9wYXRoKTtoZWlnaHQ6MTAwJTt3aWR0aDoxMDAlIj48L2Rpdj48L2ZvcmVpZ25PYmplY3Q+PGcgZGF0YS1maWdtYS1iZy1ibHVyLXJhZGl1cz0iMS4zNzQ2NSI+CiAgPHBhdGggZD0iTTg0LjYyNCA3NC42ODI2SDEyNi40MzVDMTI2LjQzNyA3NC44MDYzIDEyNi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b3Agb2Zmc2V0PSIxIiBzdG9wLWNvbG9yPSIjQUNGRThCIi8+CjwvbGluZWFyR3JhZGllbnQ+CjwvZGVmcz4KPC9zdmc+Cg==", pc = () => {
|
|
4561
|
+
const [e, n] = N(!1), [t, r] = N(null), s = V(W);
|
|
4513
4562
|
if (!s)
|
|
4514
4563
|
throw new Error("WalletConnectContext not found");
|
|
4515
4564
|
const o = () => {
|
|
@@ -4524,13 +4573,13 @@ const ec = () => {
|
|
|
4524
4573
|
n(!1), r("Failed to sign in. Please try again.");
|
|
4525
4574
|
}
|
|
4526
4575
|
});
|
|
4527
|
-
return
|
|
4576
|
+
return Y(() => (e && (c.current = setTimeout(() => {
|
|
4528
4577
|
s.modal.closeModal();
|
|
4529
4578
|
}, 1e3)), () => {
|
|
4530
4579
|
c.current && (clearTimeout(c.current), c.current = null);
|
|
4531
|
-
}), [e, s.modal]), /* @__PURE__ */ i(S, { onClose: o, title: "Verify wallet ownership", onBack: o, children: /* @__PURE__ */
|
|
4532
|
-
/* @__PURE__ */ i(ne, { src: e ?
|
|
4533
|
-
/* @__PURE__ */
|
|
4580
|
+
}), [e, s.modal]), /* @__PURE__ */ i(S, { onClose: o, title: "Verify wallet ownership", onBack: o, children: /* @__PURE__ */ C("div", { className: "flex flex-col items-center justify-center py-6 gap-6 flex-1", children: [
|
|
4581
|
+
/* @__PURE__ */ i(ne, { src: e ? xc : mc, alt: "Sign In Icon", className: "rounded-full" }),
|
|
4582
|
+
/* @__PURE__ */ C("div", { className: "text-sm text-center", children: [
|
|
4534
4583
|
/* @__PURE__ */ i("p", { className: "text-foreground", children: e ? "Ownership verified" : "Verify yourself as the owner of this wallet" }),
|
|
4535
4584
|
t ? /* @__PURE__ */ i("p", { className: "text-foreground/60", children: t }) : e ? null : /* @__PURE__ */ i("p", { className: "text-foreground/60", children: "Please sign the message request in your wallet to continue." })
|
|
4536
4585
|
] }),
|
|
@@ -4557,19 +4606,19 @@ const ec = () => {
|
|
|
4557
4606
|
}
|
|
4558
4607
|
) })
|
|
4559
4608
|
] }) });
|
|
4560
|
-
},
|
|
4561
|
-
const [e, n] = N(""), t = V(
|
|
4609
|
+
}, bc = bn, zc = () => {
|
|
4610
|
+
const [e, n] = N(""), t = V(W), { isLoading: r, handleEmailLogin: s, handleGoogleLogin: o, handleXLogin: c } = sr({
|
|
4562
4611
|
closeModalBeforeIframe: !0
|
|
4563
4612
|
});
|
|
4564
4613
|
if (!t)
|
|
4565
4614
|
throw new Error("WalletConnectContext not found");
|
|
4566
|
-
return /* @__PURE__ */
|
|
4567
|
-
/* @__PURE__ */ i(
|
|
4568
|
-
/* @__PURE__ */
|
|
4569
|
-
/* @__PURE__ */
|
|
4570
|
-
/* @__PURE__ */
|
|
4615
|
+
return /* @__PURE__ */ C(S, { title: "Log in or sign up", children: [
|
|
4616
|
+
/* @__PURE__ */ i(fr, { isLoading: r }),
|
|
4617
|
+
/* @__PURE__ */ C("div", { className: "flex flex-col justify-between min-h-0 flex-1 pb-4", children: [
|
|
4618
|
+
/* @__PURE__ */ C("div", { className: "flex flex-col gap-6 px-4", children: [
|
|
4619
|
+
/* @__PURE__ */ C("div", { className: "flex items-center gap-2", children: [
|
|
4571
4620
|
/* @__PURE__ */ i(
|
|
4572
|
-
|
|
4621
|
+
bc,
|
|
4573
4622
|
{
|
|
4574
4623
|
type: "email",
|
|
4575
4624
|
placeholder: "Enter your email",
|
|
@@ -4607,7 +4656,7 @@ const ec = () => {
|
|
|
4607
4656
|
)
|
|
4608
4657
|
] }),
|
|
4609
4658
|
/* @__PURE__ */ i(xn, {}),
|
|
4610
|
-
/* @__PURE__ */
|
|
4659
|
+
/* @__PURE__ */ C("div", { className: "flex flex-col gap-3", children: [
|
|
4611
4660
|
/* @__PURE__ */ i(
|
|
4612
4661
|
X,
|
|
4613
4662
|
{
|
|
@@ -4616,7 +4665,7 @@ const ec = () => {
|
|
|
4616
4665
|
variant: "bordered",
|
|
4617
4666
|
className: "h-11 rounded-full bg-[#1C1917] border-[#44403C] text-white hover:bg-[#44403C] shadow-[inset_0px_0px_16px_4px_#EAAC0814]",
|
|
4618
4667
|
onPress: o,
|
|
4619
|
-
startContent: /* @__PURE__ */ i(
|
|
4668
|
+
startContent: /* @__PURE__ */ i(ur, {}),
|
|
4620
4669
|
children: "Continue with Google"
|
|
4621
4670
|
}
|
|
4622
4671
|
),
|
|
@@ -4628,7 +4677,7 @@ const ec = () => {
|
|
|
4628
4677
|
variant: "bordered",
|
|
4629
4678
|
className: "h-11 rounded-full bg-[#1C1917] border-[#44403C] text-white hover:bg-[#44403C] shadow-[inset_0px_0px_16px_4px_#EAAC0814]",
|
|
4630
4679
|
onPress: c,
|
|
4631
|
-
startContent: /* @__PURE__ */ i(
|
|
4680
|
+
startContent: /* @__PURE__ */ i(gr, {}),
|
|
4632
4681
|
children: "Continue with X"
|
|
4633
4682
|
}
|
|
4634
4683
|
)
|
|
@@ -4648,32 +4697,32 @@ const ec = () => {
|
|
|
4648
4697
|
}
|
|
4649
4698
|
)
|
|
4650
4699
|
] }),
|
|
4651
|
-
/* @__PURE__ */ i("div", { className: "mt-6 px-4", children: /* @__PURE__ */ i(
|
|
4700
|
+
/* @__PURE__ */ i("div", { className: "mt-6 px-4", children: /* @__PURE__ */ i(Ge, {}) })
|
|
4652
4701
|
] })
|
|
4653
4702
|
] });
|
|
4654
|
-
},
|
|
4655
|
-
const e = V(
|
|
4703
|
+
}, wc = "Please reselect the network you want to switch to", Ic = It.unsupported, Pc = () => {
|
|
4704
|
+
const e = V(W);
|
|
4656
4705
|
if (!e)
|
|
4657
4706
|
throw new Error("WalletConnectContext not found");
|
|
4658
4707
|
const n = e.modal.state?.name || "-", t = () => {
|
|
4659
4708
|
e?.modal.backView();
|
|
4660
4709
|
};
|
|
4661
|
-
return /* @__PURE__ */ i(S, { title: "Select network", onBack: t, children: /* @__PURE__ */
|
|
4662
|
-
/* @__PURE__ */ i("div", { className: "flex justify-center", children: /* @__PURE__ */ i(le, { icon:
|
|
4663
|
-
/* @__PURE__ */
|
|
4664
|
-
/* @__PURE__ */
|
|
4710
|
+
return /* @__PURE__ */ i(S, { title: "Select network", onBack: t, children: /* @__PURE__ */ C("div", { className: "flex flex-col items-center justify-center", children: [
|
|
4711
|
+
/* @__PURE__ */ i("div", { className: "flex justify-center", children: /* @__PURE__ */ i(le, { icon: Ic, className: "size-14 overflow-hidden rounded-full" }) }),
|
|
4712
|
+
/* @__PURE__ */ C("div", { className: "mt-6 flex flex-col justify-center items-center", children: [
|
|
4713
|
+
/* @__PURE__ */ C("div", { className: "text-t1 text-sm text-center", children: [
|
|
4665
4714
|
"Current Wallet Does Not Support ",
|
|
4666
4715
|
/* @__PURE__ */ i("br", {}),
|
|
4667
4716
|
" ",
|
|
4668
4717
|
n,
|
|
4669
4718
|
" Chain"
|
|
4670
4719
|
] }),
|
|
4671
|
-
/* @__PURE__ */ i("div", { className: "text-[#A9A29D] mt-2 text-sm text-center", children:
|
|
4720
|
+
/* @__PURE__ */ i("div", { className: "text-[#A9A29D] mt-2 text-sm text-center", children: wc })
|
|
4672
4721
|
] }),
|
|
4673
4722
|
/* @__PURE__ */ i(X, { className: "w-full my-4", onPress: t, children: "Got it" })
|
|
4674
4723
|
] }) });
|
|
4675
|
-
},
|
|
4676
|
-
const e = V(
|
|
4724
|
+
}, Bc = () => {
|
|
4725
|
+
const e = V(W);
|
|
4677
4726
|
if (!e)
|
|
4678
4727
|
throw new Error("WalletConnectContext not found");
|
|
4679
4728
|
const { currentWallet: n } = e.account;
|
|
@@ -4682,7 +4731,7 @@ const ec = () => {
|
|
|
4682
4731
|
const [t, r] = N(""), { copy: s, copied: o } = In(), c = () => {
|
|
4683
4732
|
s(t);
|
|
4684
4733
|
}, a = e.modal.state?.chainType || "evm", l = B(() => n.providers?.[a]?.provider, [n, a]);
|
|
4685
|
-
return
|
|
4734
|
+
return Y(() => {
|
|
4686
4735
|
if (l && l && typeof l.on == "function" && typeof l.off == "function") {
|
|
4687
4736
|
const d = (f) => {
|
|
4688
4737
|
r(f.uri);
|
|
@@ -4702,7 +4751,7 @@ const ec = () => {
|
|
|
4702
4751
|
}
|
|
4703
4752
|
}, [l, r]), /* @__PURE__ */ i(S, { onBack: () => {
|
|
4704
4753
|
e.modal.backView();
|
|
4705
|
-
}, title: "Wallet Connect", children: /* @__PURE__ */
|
|
4754
|
+
}, title: "Wallet Connect", children: /* @__PURE__ */ C("div", { className: "flex flex-col items-center justify-center px-5 pb-6 gap-4", children: [
|
|
4706
4755
|
/* @__PURE__ */ i("p", { className: "text-sm text-foreground/80 text-center", children: "Scan the QR code with your wallet camera" }),
|
|
4707
4756
|
/* @__PURE__ */ i(
|
|
4708
4757
|
$t,
|
|
@@ -4714,43 +4763,43 @@ const ec = () => {
|
|
|
4714
4763
|
),
|
|
4715
4764
|
/* @__PURE__ */ i(X, { variant: "light", size: "lg", fullWidth: !0, onPress: c, children: o ? "Copied!" : "Copy Link" })
|
|
4716
4765
|
] }) });
|
|
4717
|
-
},
|
|
4718
|
-
[P.Loading]: () => /* @__PURE__ */ i(
|
|
4719
|
-
[P.Logged]: () => /* @__PURE__ */ i(
|
|
4720
|
-
[P.Error]: () => /* @__PURE__ */ i(
|
|
4721
|
-
[P.Connecting]: () => /* @__PURE__ */ i(
|
|
4722
|
-
[P.WalletList]: () => /* @__PURE__ */ i(
|
|
4723
|
-
[P.WalletSearch]: () => /* @__PURE__ */ i(
|
|
4724
|
-
[P.WalletSelectProviders]: () => /* @__PURE__ */ i(
|
|
4725
|
-
[P.WalletInstallGuide]: () => /* @__PURE__ */ i(
|
|
4726
|
-
[P.Account]: () => /* @__PURE__ */ i(
|
|
4727
|
-
[P.SelectChains]: () => /* @__PURE__ */ i(
|
|
4728
|
-
[P.ChangeNetwork]: () => /* @__PURE__ */ i(
|
|
4729
|
-
[P.SignInWallet]: () => /* @__PURE__ */ i(
|
|
4730
|
-
[P.WalletConnect]: () => /* @__PURE__ */ i(
|
|
4731
|
-
[P.UnsupportChain]: () => /* @__PURE__ */ i(
|
|
4732
|
-
[P.SocialLogin]: () => /* @__PURE__ */ i(
|
|
4733
|
-
[P.MyDogeSocialLogin]: () => /* @__PURE__ */ i(
|
|
4734
|
-
},
|
|
4735
|
-
const { hideHeader: n, hideBody: t, onBack: r, ...s } = e, o = B(() => r ? /* @__PURE__ */ i(X, { isIconOnly: !0, size: "sm", variant: "light", onPress: r, radius: "full", children: /* @__PURE__ */ i(ct, {}) }) : null, [r]), c = B(() => n ? null : /* @__PURE__ */
|
|
4766
|
+
}, vr = {
|
|
4767
|
+
[P.Loading]: () => /* @__PURE__ */ i(jo, {}),
|
|
4768
|
+
[P.Logged]: () => /* @__PURE__ */ i(Uo, {}),
|
|
4769
|
+
[P.Error]: () => /* @__PURE__ */ i(yo, {}),
|
|
4770
|
+
[P.Connecting]: () => /* @__PURE__ */ i(Bo, {}),
|
|
4771
|
+
[P.WalletList]: () => /* @__PURE__ */ i(sc, {}),
|
|
4772
|
+
[P.WalletSearch]: () => /* @__PURE__ */ i(oc, {}),
|
|
4773
|
+
[P.WalletSelectProviders]: () => /* @__PURE__ */ i(Cc, {}),
|
|
4774
|
+
[P.WalletInstallGuide]: () => /* @__PURE__ */ i(No, {}),
|
|
4775
|
+
[P.Account]: () => /* @__PURE__ */ i(wo, {}),
|
|
4776
|
+
[P.SelectChains]: () => /* @__PURE__ */ i(uc, {}),
|
|
4777
|
+
[P.ChangeNetwork]: () => /* @__PURE__ */ i(Io, {}),
|
|
4778
|
+
[P.SignInWallet]: () => /* @__PURE__ */ i(pc, {}),
|
|
4779
|
+
[P.WalletConnect]: () => /* @__PURE__ */ i(Bc, {}),
|
|
4780
|
+
[P.UnsupportChain]: () => /* @__PURE__ */ i(Pc, {}),
|
|
4781
|
+
[P.SocialLogin]: () => /* @__PURE__ */ i(zc, {}),
|
|
4782
|
+
[P.MyDogeSocialLogin]: () => /* @__PURE__ */ i(lc, {})
|
|
4783
|
+
}, yc = (e) => {
|
|
4784
|
+
const { hideHeader: n, hideBody: t, onBack: r, ...s } = e, o = B(() => r ? /* @__PURE__ */ i(X, { isIconOnly: !0, size: "sm", variant: "light", onPress: r, radius: "full", children: /* @__PURE__ */ i(ct, {}) }) : null, [r]), c = B(() => n ? null : /* @__PURE__ */ C(Tr, { className: "flex items-center justify-between", children: [
|
|
4736
4785
|
o,
|
|
4737
4786
|
/* @__PURE__ */ i("span", { children: e.title }),
|
|
4738
4787
|
/* @__PURE__ */ i(X, { isIconOnly: !0, size: "sm", variant: "light", onPress: e.onClose, radius: "full", children: /* @__PURE__ */ i(at, {}) })
|
|
4739
|
-
] }), [n, e.title, e.onClose, o]), a = B(() => t ? null : /* @__PURE__ */ i(
|
|
4740
|
-
return /* @__PURE__ */ i(At, { ...s, hideCloseButton: !0,
|
|
4788
|
+
] }), [n, e.title, e.onClose, o]), a = B(() => t ? null : /* @__PURE__ */ i(Er, { className: "px-5", children: e.children }), [t, e.children]);
|
|
4789
|
+
return /* @__PURE__ */ i(At, { ...s, hideCloseButton: !0, children: /* @__PURE__ */ C(Lr, { className: "w-[448px]", children: [
|
|
4741
4790
|
c,
|
|
4742
4791
|
a
|
|
4743
4792
|
] }) });
|
|
4744
|
-
},
|
|
4745
|
-
const e = V(
|
|
4793
|
+
}, hc = () => {
|
|
4794
|
+
const e = V(W);
|
|
4746
4795
|
if (!e)
|
|
4747
4796
|
return null;
|
|
4748
4797
|
const { modal: n, connection: t } = e, r = () => {
|
|
4749
|
-
const s =
|
|
4798
|
+
const s = vr[n.view];
|
|
4750
4799
|
return s ? s(e) : null;
|
|
4751
4800
|
};
|
|
4752
4801
|
return /* @__PURE__ */ i(
|
|
4753
|
-
|
|
4802
|
+
yc,
|
|
4754
4803
|
{
|
|
4755
4804
|
hideHeader: !0,
|
|
4756
4805
|
isOpen: n.isOpen,
|
|
@@ -4760,93 +4809,98 @@ const ec = () => {
|
|
|
4760
4809
|
children: r()
|
|
4761
4810
|
}
|
|
4762
4811
|
);
|
|
4763
|
-
},
|
|
4764
|
-
|
|
4765
|
-
|
|
4766
|
-
|
|
4812
|
+
}, Mc = ({
|
|
4813
|
+
config: e,
|
|
4814
|
+
setMainView: n,
|
|
4815
|
+
defaultMainView: t
|
|
4816
|
+
}) => {
|
|
4817
|
+
const [r, s] = N(null), [o, c] = N(!1), [a, l] = N(null), [A, d] = N(null), [f, u] = N(!0);
|
|
4818
|
+
return Y(() => {
|
|
4819
|
+
const g = ns.getInstance();
|
|
4767
4820
|
(async () => {
|
|
4768
|
-
|
|
4769
|
-
|
|
4770
|
-
|
|
4771
|
-
|
|
4821
|
+
const v = await g.init({ ...e, tomoClientId: e.clientId }).finally(() => {
|
|
4822
|
+
u(!1);
|
|
4823
|
+
});
|
|
4824
|
+
if (!v) {
|
|
4825
|
+
u(!1);
|
|
4772
4826
|
return;
|
|
4773
4827
|
}
|
|
4774
|
-
const { isAvailable:
|
|
4775
|
-
console.log("initEmbeddedWallet result: ",
|
|
4828
|
+
const { isAvailable: m, message: p, connectedInfo: y } = v || {};
|
|
4829
|
+
console.log("initEmbeddedWallet result: ", v), s(g), c(m || !1), l(p ?? null), d(y), u(!1), n(m ? P.Logged : t);
|
|
4776
4830
|
})();
|
|
4777
|
-
}, [
|
|
4778
|
-
},
|
|
4831
|
+
}, []), { wallet: r, isAvailable: o, message: a, connectedInfo: A, isLoading: f };
|
|
4832
|
+
}, Wc = ({
|
|
4779
4833
|
setWalletState: e,
|
|
4780
4834
|
currentWallet: n,
|
|
4781
4835
|
isConnected: t,
|
|
4782
4836
|
embeddedWallet: r,
|
|
4783
4837
|
wagmiConfig: s
|
|
4784
4838
|
}) => {
|
|
4785
|
-
const o = ce(!1), { data: c } =
|
|
4786
|
-
|
|
4839
|
+
const o = ce(!1), { data: c } = he("all"), a = B(() => c?.all || [], [c?.all]), l = ar(), A = Ko();
|
|
4840
|
+
Y(() => {
|
|
4787
4841
|
if (o.current || t || n)
|
|
4788
4842
|
return;
|
|
4789
4843
|
const d = async () => {
|
|
4790
4844
|
const f = r?.wallet;
|
|
4791
4845
|
try {
|
|
4792
|
-
const
|
|
4793
|
-
if (!
|
|
4846
|
+
const u = fs();
|
|
4847
|
+
if (!u) {
|
|
4794
4848
|
o.current = !0;
|
|
4795
4849
|
return;
|
|
4796
4850
|
}
|
|
4797
|
-
console.log("Attempting to restore wallet connection...",
|
|
4798
|
-
const
|
|
4799
|
-
if (
|
|
4851
|
+
console.log("Attempting to restore wallet connection...", u);
|
|
4852
|
+
const g = a.find((m) => m.info.uuid === u.walletInfo?.uuid);
|
|
4853
|
+
if (g && f.isAvailable && e((m) => ({
|
|
4800
4854
|
...m,
|
|
4801
|
-
currentWallet:
|
|
4802
|
-
})), !
|
|
4855
|
+
currentWallet: g
|
|
4856
|
+
})), !g) {
|
|
4803
4857
|
console.log("Stored wallet not found in available wallets"), f && (o.current = !0);
|
|
4804
4858
|
return;
|
|
4805
4859
|
}
|
|
4806
|
-
const x =
|
|
4807
|
-
if (!
|
|
4860
|
+
const x = u.chainType, v = g?.providers[x]?.provider;
|
|
4861
|
+
if (!v) {
|
|
4808
4862
|
console.log("Provider not available for stored chain type"), o.current = !0;
|
|
4809
4863
|
return;
|
|
4810
4864
|
}
|
|
4811
|
-
if (
|
|
4865
|
+
if (g.isEmbeddedWallet) {
|
|
4812
4866
|
const m = r?.connectedInfo;
|
|
4813
4867
|
if (!m) {
|
|
4814
4868
|
console.log("No connectedInfo available for embedded wallet"), o.current = !0;
|
|
4815
4869
|
return;
|
|
4816
4870
|
}
|
|
4817
|
-
let
|
|
4818
|
-
if (m.evmProvider?.connected === !0 ?
|
|
4871
|
+
let p = null;
|
|
4872
|
+
if (m.evmProvider?.connected === !0 ? p = "evm" : m.solanaProvider?.connected === !0 ? p = "solana" : m.dogeProvider?.connected === !0 && (p = "dogecoin"), !p) {
|
|
4819
4873
|
console.log("No connected provider found in connectedInfo"), o.current = !0;
|
|
4820
4874
|
return;
|
|
4821
4875
|
}
|
|
4822
|
-
const
|
|
4823
|
-
if (!
|
|
4824
|
-
console.log("Provider not available for connected chain type:",
|
|
4876
|
+
const y = g?.providers[p]?.provider;
|
|
4877
|
+
if (!y) {
|
|
4878
|
+
console.log("Provider not available for connected chain type:", p), o.current = !0;
|
|
4825
4879
|
return;
|
|
4826
4880
|
}
|
|
4827
|
-
const
|
|
4881
|
+
const b = m[`${p}Provider`]?.address?.[0] || u.address;
|
|
4828
4882
|
if (console.log("Restoring embedded wallet connection", {
|
|
4829
|
-
connectedChainType:
|
|
4830
|
-
connectedAddress:
|
|
4883
|
+
connectedChainType: p,
|
|
4884
|
+
connectedAddress: b,
|
|
4831
4885
|
connectedInfo: m
|
|
4832
4886
|
}), e((w) => ({
|
|
4833
4887
|
...w,
|
|
4834
4888
|
isConnected: !0,
|
|
4835
|
-
address:
|
|
4836
|
-
chainId:
|
|
4837
|
-
chainType:
|
|
4838
|
-
balance:
|
|
4839
|
-
currentWallet:
|
|
4840
|
-
currentProvider:
|
|
4841
|
-
})), l &&
|
|
4889
|
+
address: b,
|
|
4890
|
+
chainId: u.chainId,
|
|
4891
|
+
chainType: p,
|
|
4892
|
+
balance: u.balance || "0.0",
|
|
4893
|
+
currentWallet: g,
|
|
4894
|
+
currentProvider: y
|
|
4895
|
+
})), l && p === k.EVM && s && A && !A.isConnected)
|
|
4842
4896
|
try {
|
|
4843
4897
|
const w = mn(
|
|
4844
|
-
|
|
4845
|
-
|
|
4898
|
+
g.info.uuid,
|
|
4899
|
+
g.info.rdns,
|
|
4846
4900
|
s.connectors
|
|
4847
4901
|
);
|
|
4848
4902
|
if (w && w.ready) {
|
|
4849
|
-
const I =
|
|
4903
|
+
const I = u.chainId ? parseInt(u.chainId, 16) : void 0;
|
|
4850
4904
|
await l.connectAsync({
|
|
4851
4905
|
connector: w,
|
|
4852
4906
|
chainId: I
|
|
@@ -4858,39 +4912,39 @@ const ec = () => {
|
|
|
4858
4912
|
o.current = !0;
|
|
4859
4913
|
} else
|
|
4860
4914
|
try {
|
|
4861
|
-
const m = await
|
|
4862
|
-
if (m && m.length > 0 && m[0].toLowerCase() ===
|
|
4863
|
-
...
|
|
4915
|
+
const m = await v.request?.({ method: "eth_accounts" });
|
|
4916
|
+
if (m && m.length > 0 && m[0].toLowerCase() === u.address.toLowerCase() && (console.log("Restoring plugin wallet connection for:", g.info.name), e((p) => ({
|
|
4917
|
+
...p,
|
|
4864
4918
|
isConnected: !0,
|
|
4865
|
-
address:
|
|
4866
|
-
chainId:
|
|
4867
|
-
chainType:
|
|
4868
|
-
balance:
|
|
4869
|
-
currentWallet:
|
|
4870
|
-
currentProvider:
|
|
4871
|
-
})), l &&
|
|
4919
|
+
address: u.address,
|
|
4920
|
+
chainId: u.chainId,
|
|
4921
|
+
chainType: u.chainType,
|
|
4922
|
+
balance: u.balance || "0.0",
|
|
4923
|
+
currentWallet: g,
|
|
4924
|
+
currentProvider: v
|
|
4925
|
+
})), l && u.chainType === k.EVM && s && A && !A.isConnected))
|
|
4872
4926
|
try {
|
|
4873
|
-
const
|
|
4874
|
-
|
|
4875
|
-
|
|
4927
|
+
const p = mn(
|
|
4928
|
+
g.info.uuid,
|
|
4929
|
+
g.info.rdns,
|
|
4876
4930
|
s.connectors
|
|
4877
4931
|
);
|
|
4878
|
-
if (
|
|
4879
|
-
const
|
|
4932
|
+
if (p && p.ready) {
|
|
4933
|
+
const y = u.chainId ? parseInt(u.chainId, 16) : void 0;
|
|
4880
4934
|
await l.connectAsync({
|
|
4881
|
-
connector:
|
|
4882
|
-
chainId:
|
|
4935
|
+
connector: p,
|
|
4936
|
+
chainId: y
|
|
4883
4937
|
});
|
|
4884
4938
|
}
|
|
4885
|
-
} catch (
|
|
4886
|
-
console.warn("Failed to restore wagmi connection:",
|
|
4939
|
+
} catch (p) {
|
|
4940
|
+
console.warn("Failed to restore wagmi connection:", p);
|
|
4887
4941
|
}
|
|
4888
4942
|
o.current = !0;
|
|
4889
4943
|
} catch (m) {
|
|
4890
4944
|
o.current = !0, console.log("Failed to verify wallet connection:", m);
|
|
4891
4945
|
}
|
|
4892
|
-
} catch (
|
|
4893
|
-
o.current = !0, console.error("Failed to restore wallet connection:",
|
|
4946
|
+
} catch (u) {
|
|
4947
|
+
o.current = !0, console.error("Failed to restore wallet connection:", u);
|
|
4894
4948
|
}
|
|
4895
4949
|
};
|
|
4896
4950
|
a.length > 0 && r?.wallet && d();
|
|
@@ -4906,11 +4960,11 @@ const ec = () => {
|
|
|
4906
4960
|
A
|
|
4907
4961
|
]);
|
|
4908
4962
|
};
|
|
4909
|
-
function
|
|
4963
|
+
function Vc(e) {
|
|
4910
4964
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
4911
4965
|
}
|
|
4912
4966
|
var sn = { exports: {} }, it;
|
|
4913
|
-
function
|
|
4967
|
+
function Xc() {
|
|
4914
4968
|
return it || (it = 1, function(e) {
|
|
4915
4969
|
var n = Object.prototype.hasOwnProperty, t = "~";
|
|
4916
4970
|
function r() {
|
|
@@ -4919,11 +4973,11 @@ function Mc() {
|
|
|
4919
4973
|
function s(l, A, d) {
|
|
4920
4974
|
this.fn = l, this.context = A, this.once = d || !1;
|
|
4921
4975
|
}
|
|
4922
|
-
function o(l, A, d, f,
|
|
4976
|
+
function o(l, A, d, f, u) {
|
|
4923
4977
|
if (typeof d != "function")
|
|
4924
4978
|
throw new TypeError("The listener must be a function");
|
|
4925
|
-
var
|
|
4926
|
-
return l._events[x] ? l._events[x].fn ? l._events[x] = [l._events[x],
|
|
4979
|
+
var g = new s(d, f || l, u), x = t ? t + A : A;
|
|
4980
|
+
return l._events[x] ? l._events[x].fn ? l._events[x] = [l._events[x], g] : l._events[x].push(g) : (l._events[x] = g, l._eventsCount++), l;
|
|
4927
4981
|
}
|
|
4928
4982
|
function c(l, A) {
|
|
4929
4983
|
--l._eventsCount === 0 ? l._events = new r() : delete l._events[A];
|
|
@@ -4941,18 +4995,18 @@ function Mc() {
|
|
|
4941
4995
|
var d = t ? t + A : A, f = this._events[d];
|
|
4942
4996
|
if (!f) return [];
|
|
4943
4997
|
if (f.fn) return [f.fn];
|
|
4944
|
-
for (var
|
|
4945
|
-
x[
|
|
4998
|
+
for (var u = 0, g = f.length, x = new Array(g); u < g; u++)
|
|
4999
|
+
x[u] = f[u].fn;
|
|
4946
5000
|
return x;
|
|
4947
5001
|
}, a.prototype.listenerCount = function(A) {
|
|
4948
5002
|
var d = t ? t + A : A, f = this._events[d];
|
|
4949
5003
|
return f ? f.fn ? 1 : f.length : 0;
|
|
4950
|
-
}, a.prototype.emit = function(A, d, f,
|
|
4951
|
-
var
|
|
4952
|
-
if (!this._events[
|
|
4953
|
-
var m = this._events[
|
|
5004
|
+
}, a.prototype.emit = function(A, d, f, u, g, x) {
|
|
5005
|
+
var v = t ? t + A : A;
|
|
5006
|
+
if (!this._events[v]) return !1;
|
|
5007
|
+
var m = this._events[v], p = arguments.length, y, b;
|
|
4954
5008
|
if (m.fn) {
|
|
4955
|
-
switch (m.once && this.removeListener(A, m.fn, void 0, !0),
|
|
5009
|
+
switch (m.once && this.removeListener(A, m.fn, void 0, !0), p) {
|
|
4956
5010
|
case 1:
|
|
4957
5011
|
return m.fn.call(m.context), !0;
|
|
4958
5012
|
case 2:
|
|
@@ -4960,35 +5014,35 @@ function Mc() {
|
|
|
4960
5014
|
case 3:
|
|
4961
5015
|
return m.fn.call(m.context, d, f), !0;
|
|
4962
5016
|
case 4:
|
|
4963
|
-
return m.fn.call(m.context, d, f,
|
|
5017
|
+
return m.fn.call(m.context, d, f, u), !0;
|
|
4964
5018
|
case 5:
|
|
4965
|
-
return m.fn.call(m.context, d, f,
|
|
5019
|
+
return m.fn.call(m.context, d, f, u, g), !0;
|
|
4966
5020
|
case 6:
|
|
4967
|
-
return m.fn.call(m.context, d, f,
|
|
5021
|
+
return m.fn.call(m.context, d, f, u, g, x), !0;
|
|
4968
5022
|
}
|
|
4969
|
-
for (
|
|
4970
|
-
|
|
4971
|
-
m.fn.apply(m.context,
|
|
5023
|
+
for (b = 1, y = new Array(p - 1); b < p; b++)
|
|
5024
|
+
y[b - 1] = arguments[b];
|
|
5025
|
+
m.fn.apply(m.context, y);
|
|
4972
5026
|
} else {
|
|
4973
5027
|
var w = m.length, I;
|
|
4974
|
-
for (
|
|
4975
|
-
switch (m[
|
|
5028
|
+
for (b = 0; b < w; b++)
|
|
5029
|
+
switch (m[b].once && this.removeListener(A, m[b].fn, void 0, !0), p) {
|
|
4976
5030
|
case 1:
|
|
4977
|
-
m[
|
|
5031
|
+
m[b].fn.call(m[b].context);
|
|
4978
5032
|
break;
|
|
4979
5033
|
case 2:
|
|
4980
|
-
m[
|
|
5034
|
+
m[b].fn.call(m[b].context, d);
|
|
4981
5035
|
break;
|
|
4982
5036
|
case 3:
|
|
4983
|
-
m[
|
|
5037
|
+
m[b].fn.call(m[b].context, d, f);
|
|
4984
5038
|
break;
|
|
4985
5039
|
case 4:
|
|
4986
|
-
m[
|
|
5040
|
+
m[b].fn.call(m[b].context, d, f, u);
|
|
4987
5041
|
break;
|
|
4988
5042
|
default:
|
|
4989
|
-
if (!
|
|
4990
|
-
|
|
4991
|
-
m[
|
|
5043
|
+
if (!y) for (I = 1, y = new Array(p - 1); I < p; I++)
|
|
5044
|
+
y[I - 1] = arguments[I];
|
|
5045
|
+
m[b].fn.apply(m[b].context, y);
|
|
4992
5046
|
}
|
|
4993
5047
|
}
|
|
4994
5048
|
return !0;
|
|
@@ -4996,18 +5050,18 @@ function Mc() {
|
|
|
4996
5050
|
return o(this, A, d, f, !1);
|
|
4997
5051
|
}, a.prototype.once = function(A, d, f) {
|
|
4998
5052
|
return o(this, A, d, f, !0);
|
|
4999
|
-
}, a.prototype.removeListener = function(A, d, f,
|
|
5000
|
-
var
|
|
5001
|
-
if (!this._events[
|
|
5053
|
+
}, a.prototype.removeListener = function(A, d, f, u) {
|
|
5054
|
+
var g = t ? t + A : A;
|
|
5055
|
+
if (!this._events[g]) return this;
|
|
5002
5056
|
if (!d)
|
|
5003
|
-
return c(this,
|
|
5004
|
-
var x = this._events[
|
|
5057
|
+
return c(this, g), this;
|
|
5058
|
+
var x = this._events[g];
|
|
5005
5059
|
if (x.fn)
|
|
5006
|
-
x.fn === d && (!
|
|
5060
|
+
x.fn === d && (!u || x.once) && (!f || x.context === f) && c(this, g);
|
|
5007
5061
|
else {
|
|
5008
|
-
for (var
|
|
5009
|
-
(x[
|
|
5010
|
-
m.length ? this._events[
|
|
5062
|
+
for (var v = 0, m = [], p = x.length; v < p; v++)
|
|
5063
|
+
(x[v].fn !== d || u && !x[v].once || f && x[v].context !== f) && m.push(x[v]);
|
|
5064
|
+
m.length ? this._events[g] = m.length === 1 ? m[0] : m : c(this, g);
|
|
5011
5065
|
}
|
|
5012
5066
|
return this;
|
|
5013
5067
|
}, a.prototype.removeAllListeners = function(A) {
|
|
@@ -5016,9 +5070,9 @@ function Mc() {
|
|
|
5016
5070
|
}, a.prototype.off = a.prototype.removeListener, a.prototype.addListener = a.prototype.on, a.prefixed = t, a.EventEmitter = a, e.exports = a;
|
|
5017
5071
|
}(sn)), sn.exports;
|
|
5018
5072
|
}
|
|
5019
|
-
var
|
|
5020
|
-
const
|
|
5021
|
-
class
|
|
5073
|
+
var Nc = Xc();
|
|
5074
|
+
const jc = /* @__PURE__ */ Vc(Nc);
|
|
5075
|
+
class Tc {
|
|
5022
5076
|
constructor(n) {
|
|
5023
5077
|
Object.defineProperty(this, "uid", {
|
|
5024
5078
|
enumerable: !0,
|
|
@@ -5029,7 +5083,7 @@ class Xc {
|
|
|
5029
5083
|
enumerable: !0,
|
|
5030
5084
|
configurable: !0,
|
|
5031
5085
|
writable: !0,
|
|
5032
|
-
value: new
|
|
5086
|
+
value: new jc()
|
|
5033
5087
|
});
|
|
5034
5088
|
}
|
|
5035
5089
|
on(n, t) {
|
|
@@ -5049,34 +5103,34 @@ class Xc {
|
|
|
5049
5103
|
return this._emitter.listenerCount(n);
|
|
5050
5104
|
}
|
|
5051
5105
|
}
|
|
5052
|
-
function
|
|
5053
|
-
return new
|
|
5106
|
+
function Ec(e) {
|
|
5107
|
+
return new Tc(e);
|
|
5054
5108
|
}
|
|
5055
5109
|
const pn = 256;
|
|
5056
|
-
let
|
|
5057
|
-
function
|
|
5058
|
-
if (!
|
|
5059
|
-
|
|
5110
|
+
let Ve = pn, Xe;
|
|
5111
|
+
function Lc(e = 11) {
|
|
5112
|
+
if (!Xe || Ve + e > pn * 2) {
|
|
5113
|
+
Xe = "", Ve = 0;
|
|
5060
5114
|
for (let n = 0; n < pn; n++)
|
|
5061
|
-
|
|
5115
|
+
Xe += (256 + Math.random() * 256 | 0).toString(16).substring(1);
|
|
5062
5116
|
}
|
|
5063
|
-
return
|
|
5117
|
+
return Xe.substring(Ve, Ve++ + e);
|
|
5064
5118
|
}
|
|
5065
|
-
const
|
|
5066
|
-
var
|
|
5119
|
+
const Sc = "2.22.1", Oc = () => `@wagmi/core@${Sc}`;
|
|
5120
|
+
var Cr = function(e, n, t, r) {
|
|
5067
5121
|
if (t === "a" && !r) throw new TypeError("Private accessor was defined without a getter");
|
|
5068
5122
|
if (typeof n == "function" ? e !== n || !r : !n.has(e)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
5069
5123
|
return t === "m" ? r : t === "a" ? r.call(e) : r ? r.value : n.get(e);
|
|
5070
|
-
},
|
|
5071
|
-
class
|
|
5124
|
+
}, ke, mr;
|
|
5125
|
+
class we extends Error {
|
|
5072
5126
|
get docsBaseUrl() {
|
|
5073
5127
|
return "https://wagmi.sh/core";
|
|
5074
5128
|
}
|
|
5075
5129
|
get version() {
|
|
5076
|
-
return
|
|
5130
|
+
return Oc();
|
|
5077
5131
|
}
|
|
5078
5132
|
constructor(n, t = {}) {
|
|
5079
|
-
super(),
|
|
5133
|
+
super(), ke.add(this), Object.defineProperty(this, "details", {
|
|
5080
5134
|
enumerable: !0,
|
|
5081
5135
|
configurable: !0,
|
|
5082
5136
|
writable: !0,
|
|
@@ -5102,7 +5156,7 @@ class ze extends Error {
|
|
|
5102
5156
|
writable: !0,
|
|
5103
5157
|
value: "WagmiCoreError"
|
|
5104
5158
|
});
|
|
5105
|
-
const r = t.cause instanceof
|
|
5159
|
+
const r = t.cause instanceof we ? t.cause.details : t.cause?.message ? t.cause.message : t.details, s = t.cause instanceof we && t.cause.docsPath || t.docsPath;
|
|
5106
5160
|
this.message = [
|
|
5107
5161
|
n || "An error occurred.",
|
|
5108
5162
|
"",
|
|
@@ -5116,13 +5170,13 @@ class ze extends Error {
|
|
|
5116
5170
|
`), t.cause && (this.cause = t.cause), this.details = r, this.docsPath = s, this.metaMessages = t.metaMessages, this.shortMessage = n;
|
|
5117
5171
|
}
|
|
5118
5172
|
walk(n) {
|
|
5119
|
-
return
|
|
5173
|
+
return Cr(this, ke, "m", mr).call(this, this, n);
|
|
5120
5174
|
}
|
|
5121
5175
|
}
|
|
5122
|
-
|
|
5123
|
-
return t?.(n) ? n : n.cause ?
|
|
5176
|
+
ke = /* @__PURE__ */ new WeakSet(), mr = function e(n, t) {
|
|
5177
|
+
return t?.(n) ? n : n.cause ? Cr(this, ke, "m", e).call(this, n.cause, t) : n;
|
|
5124
5178
|
};
|
|
5125
|
-
class
|
|
5179
|
+
class Yc extends we {
|
|
5126
5180
|
constructor() {
|
|
5127
5181
|
super("Chain not configured."), Object.defineProperty(this, "name", {
|
|
5128
5182
|
enumerable: !0,
|
|
@@ -5132,7 +5186,7 @@ class Lc extends ze {
|
|
|
5132
5186
|
});
|
|
5133
5187
|
}
|
|
5134
5188
|
}
|
|
5135
|
-
class re extends
|
|
5189
|
+
class re extends we {
|
|
5136
5190
|
constructor() {
|
|
5137
5191
|
super("Provider not found."), Object.defineProperty(this, "name", {
|
|
5138
5192
|
enumerable: !0,
|
|
@@ -5153,7 +5207,7 @@ function En(e = {}) {
|
|
|
5153
5207
|
return A;
|
|
5154
5208
|
}
|
|
5155
5209
|
return typeof l == "object" ? l : typeof l == "string" ? {
|
|
5156
|
-
...
|
|
5210
|
+
...Zc[l] ?? {
|
|
5157
5211
|
id: l,
|
|
5158
5212
|
name: `${l[0].toUpperCase()}${l.slice(1)}`,
|
|
5159
5213
|
provider: `is${l[0].toUpperCase()}${l.slice(1)}`
|
|
@@ -5187,41 +5241,41 @@ function En(e = {}) {
|
|
|
5187
5241
|
A?.on && e.target && (c || (c = this.onConnect.bind(this), A.on("connect", c)), s || (s = this.onAccountsChanged.bind(this), A.on("accountsChanged", s)));
|
|
5188
5242
|
},
|
|
5189
5243
|
async connect({ chainId: A, isReconnecting: d, withCapabilities: f } = {}) {
|
|
5190
|
-
const
|
|
5191
|
-
if (!
|
|
5244
|
+
const u = await this.getProvider();
|
|
5245
|
+
if (!u)
|
|
5192
5246
|
throw new re();
|
|
5193
|
-
let
|
|
5247
|
+
let g = [];
|
|
5194
5248
|
if (d)
|
|
5195
|
-
|
|
5249
|
+
g = await this.getAccounts().catch(() => []);
|
|
5196
5250
|
else if (n)
|
|
5197
5251
|
try {
|
|
5198
|
-
|
|
5252
|
+
g = (await u.request({
|
|
5199
5253
|
method: "wallet_requestPermissions",
|
|
5200
5254
|
params: [{ eth_accounts: {} }]
|
|
5201
|
-
}))[0]?.caveats?.[0]?.value?.map((
|
|
5255
|
+
}))[0]?.caveats?.[0]?.value?.map((v) => Me(v)), g.length > 0 && (g = await this.getAccounts());
|
|
5202
5256
|
} catch (x) {
|
|
5203
|
-
const
|
|
5204
|
-
if (
|
|
5205
|
-
throw new F(
|
|
5206
|
-
if (
|
|
5207
|
-
throw
|
|
5257
|
+
const v = x;
|
|
5258
|
+
if (v.code === F.code)
|
|
5259
|
+
throw new F(v);
|
|
5260
|
+
if (v.code === Ue.code)
|
|
5261
|
+
throw v;
|
|
5208
5262
|
}
|
|
5209
5263
|
try {
|
|
5210
|
-
!
|
|
5264
|
+
!g?.length && !d && (g = (await u.request({
|
|
5211
5265
|
method: "eth_requestAccounts"
|
|
5212
|
-
})).map((m) =>
|
|
5266
|
+
})).map((m) => Me(m))), c && (u.removeListener("connect", c), c = void 0), s || (s = this.onAccountsChanged.bind(this), u.on("accountsChanged", s)), o || (o = this.onChainChanged.bind(this), u.on("chainChanged", o)), a || (a = this.onDisconnect.bind(this), u.on("disconnect", a));
|
|
5213
5267
|
let x = await this.getChainId();
|
|
5214
5268
|
return A && x !== A && (x = (await this.switchChain({ chainId: A }).catch((m) => {
|
|
5215
5269
|
if (m.code === F.code)
|
|
5216
5270
|
throw m;
|
|
5217
5271
|
return { id: x };
|
|
5218
5272
|
}))?.id ?? x), n && await l.storage?.removeItem(`${this.id}.disconnected`), e.target || await l.storage?.setItem("injected.connected", !0), {
|
|
5219
|
-
accounts: f ?
|
|
5273
|
+
accounts: f ? g.map((v) => ({ address: v, capabilities: {} })) : g,
|
|
5220
5274
|
chainId: x
|
|
5221
5275
|
};
|
|
5222
5276
|
} catch (x) {
|
|
5223
|
-
const
|
|
5224
|
-
throw
|
|
5277
|
+
const v = x;
|
|
5278
|
+
throw v.code === F.code ? new F(v) : v.code === Ue.code ? new Ue(v) : v;
|
|
5225
5279
|
}
|
|
5226
5280
|
},
|
|
5227
5281
|
async disconnect() {
|
|
@@ -5230,7 +5284,7 @@ function En(e = {}) {
|
|
|
5230
5284
|
throw new re();
|
|
5231
5285
|
o && (A.removeListener("chainChanged", o), o = void 0), a && (A.removeListener("disconnect", a), a = void 0), c || (c = this.onConnect.bind(this), A.on("connect", c));
|
|
5232
5286
|
try {
|
|
5233
|
-
await
|
|
5287
|
+
await cs(() => (
|
|
5234
5288
|
// TODO: Remove explicit type for viem@3
|
|
5235
5289
|
A.request({
|
|
5236
5290
|
// `'wallet_revokePermissions'` added in `viem@2.10.3`
|
|
@@ -5246,7 +5300,7 @@ function En(e = {}) {
|
|
|
5246
5300
|
const A = await this.getProvider();
|
|
5247
5301
|
if (!A)
|
|
5248
5302
|
throw new re();
|
|
5249
|
-
return (await A.request({ method: "eth_accounts" })).map((f) =>
|
|
5303
|
+
return (await A.request({ method: "eth_accounts" })).map((f) => Me(f));
|
|
5250
5304
|
},
|
|
5251
5305
|
async getChainId() {
|
|
5252
5306
|
const A = await this.getProvider();
|
|
@@ -5260,7 +5314,7 @@ function En(e = {}) {
|
|
|
5260
5314
|
return;
|
|
5261
5315
|
let A;
|
|
5262
5316
|
const d = r();
|
|
5263
|
-
return typeof d.provider == "function" ? A = d.provider(window) : typeof d.provider == "string" ? A =
|
|
5317
|
+
return typeof d.provider == "function" ? A = d.provider(window) : typeof d.provider == "string" ? A = Te(window, d.provider) : A = d.provider, A && !A.removeListener && ("off" in A && typeof A.off == "function" ? A.removeListener = A.off : A.removeListener = () => {
|
|
5264
5318
|
}), A;
|
|
5265
5319
|
},
|
|
5266
5320
|
async isAuthorized() {
|
|
@@ -5270,18 +5324,18 @@ function En(e = {}) {
|
|
|
5270
5324
|
return !1;
|
|
5271
5325
|
if (!await this.getProvider()) {
|
|
5272
5326
|
if (t !== void 0 && t !== !1) {
|
|
5273
|
-
const
|
|
5327
|
+
const u = async () => (typeof window < "u" && window.removeEventListener("ethereum#initialized", u), !!await this.getProvider()), g = typeof t == "number" ? t : 1e3;
|
|
5274
5328
|
if (await Promise.race([
|
|
5275
5329
|
...typeof window < "u" ? [
|
|
5276
|
-
new Promise((
|
|
5330
|
+
new Promise((v) => window.addEventListener("ethereum#initialized", () => v(u()), { once: !0 }))
|
|
5277
5331
|
] : [],
|
|
5278
|
-
new Promise((
|
|
5332
|
+
new Promise((v) => setTimeout(() => v(u()), g))
|
|
5279
5333
|
]))
|
|
5280
5334
|
return !0;
|
|
5281
5335
|
}
|
|
5282
5336
|
throw new re();
|
|
5283
5337
|
}
|
|
5284
|
-
return !!(await
|
|
5338
|
+
return !!(await os(() => this.getAccounts())).length;
|
|
5285
5339
|
} catch {
|
|
5286
5340
|
return !1;
|
|
5287
5341
|
}
|
|
@@ -5290,14 +5344,14 @@ function En(e = {}) {
|
|
|
5290
5344
|
const f = await this.getProvider();
|
|
5291
5345
|
if (!f)
|
|
5292
5346
|
throw new re();
|
|
5293
|
-
const
|
|
5294
|
-
if (!
|
|
5295
|
-
throw new Zn(new
|
|
5296
|
-
const
|
|
5297
|
-
const
|
|
5298
|
-
"chainId" in m && m.chainId === d && (l.emitter.off("change",
|
|
5347
|
+
const u = l.chains.find((x) => x.id === d);
|
|
5348
|
+
if (!u)
|
|
5349
|
+
throw new Zn(new Yc());
|
|
5350
|
+
const g = new Promise((x) => {
|
|
5351
|
+
const v = (m) => {
|
|
5352
|
+
"chainId" in m && m.chainId === d && (l.emitter.off("change", v), x());
|
|
5299
5353
|
};
|
|
5300
|
-
l.emitter.on("change",
|
|
5354
|
+
l.emitter.on("change", v);
|
|
5301
5355
|
});
|
|
5302
5356
|
try {
|
|
5303
5357
|
return await Promise.all([
|
|
@@ -5307,29 +5361,29 @@ function En(e = {}) {
|
|
|
5307
5361
|
}).then(async () => {
|
|
5308
5362
|
await this.getChainId() === d && l.emitter.emit("change", { chainId: d });
|
|
5309
5363
|
}),
|
|
5310
|
-
|
|
5311
|
-
]),
|
|
5364
|
+
g
|
|
5365
|
+
]), u;
|
|
5312
5366
|
} catch (x) {
|
|
5313
|
-
const
|
|
5314
|
-
if (
|
|
5367
|
+
const v = x;
|
|
5368
|
+
if (v.code === 4902 || // Unwrapping for MetaMask Mobile
|
|
5315
5369
|
// https://github.com/MetaMask/metamask-mobile/issues/2944#issuecomment-976988719
|
|
5316
|
-
|
|
5370
|
+
v?.data?.originalError?.code === 4902)
|
|
5317
5371
|
try {
|
|
5318
|
-
const { default: m, ...
|
|
5319
|
-
let
|
|
5320
|
-
A?.blockExplorerUrls ?
|
|
5372
|
+
const { default: m, ...p } = u.blockExplorers ?? {};
|
|
5373
|
+
let y;
|
|
5374
|
+
A?.blockExplorerUrls ? y = A.blockExplorerUrls : m && (y = [
|
|
5321
5375
|
m.url,
|
|
5322
|
-
...Object.values(
|
|
5376
|
+
...Object.values(p).map((I) => I.url)
|
|
5323
5377
|
]);
|
|
5324
|
-
let
|
|
5325
|
-
A?.rpcUrls?.length ?
|
|
5378
|
+
let b;
|
|
5379
|
+
A?.rpcUrls?.length ? b = A.rpcUrls : b = [u.rpcUrls.default?.http[0] ?? ""];
|
|
5326
5380
|
const w = {
|
|
5327
|
-
blockExplorerUrls:
|
|
5381
|
+
blockExplorerUrls: y,
|
|
5328
5382
|
chainId: kn(d),
|
|
5329
|
-
chainName: A?.chainName ??
|
|
5383
|
+
chainName: A?.chainName ?? u.name,
|
|
5330
5384
|
iconUrls: A?.iconUrls,
|
|
5331
|
-
nativeCurrency: A?.nativeCurrency ??
|
|
5332
|
-
rpcUrls:
|
|
5385
|
+
nativeCurrency: A?.nativeCurrency ?? u.nativeCurrency,
|
|
5386
|
+
rpcUrls: b
|
|
5333
5387
|
};
|
|
5334
5388
|
return await Promise.all([
|
|
5335
5389
|
f.request({
|
|
@@ -5341,12 +5395,12 @@ function En(e = {}) {
|
|
|
5341
5395
|
else
|
|
5342
5396
|
throw new F(new Error("User rejected switch after adding network."));
|
|
5343
5397
|
}),
|
|
5344
|
-
|
|
5345
|
-
]),
|
|
5398
|
+
g
|
|
5399
|
+
]), u;
|
|
5346
5400
|
} catch (m) {
|
|
5347
5401
|
throw new F(m);
|
|
5348
5402
|
}
|
|
5349
|
-
throw
|
|
5403
|
+
throw v.code === F.code ? new F(v) : new Zn(v);
|
|
5350
5404
|
}
|
|
5351
5405
|
},
|
|
5352
5406
|
async onAccountsChanged(A) {
|
|
@@ -5357,7 +5411,7 @@ function En(e = {}) {
|
|
|
5357
5411
|
this.onConnect({ chainId: d }), n && await l.storage?.removeItem(`${this.id}.disconnected`);
|
|
5358
5412
|
} else
|
|
5359
5413
|
l.emitter.emit("change", {
|
|
5360
|
-
accounts: A.map((d) =>
|
|
5414
|
+
accounts: A.map((d) => Me(d))
|
|
5361
5415
|
});
|
|
5362
5416
|
},
|
|
5363
5417
|
onChainChanged(A) {
|
|
@@ -5370,8 +5424,8 @@ function En(e = {}) {
|
|
|
5370
5424
|
return;
|
|
5371
5425
|
const f = Number(A.chainId);
|
|
5372
5426
|
l.emitter.emit("connect", { accounts: d, chainId: f });
|
|
5373
|
-
const
|
|
5374
|
-
|
|
5427
|
+
const u = await this.getProvider();
|
|
5428
|
+
u && (c && (u.removeListener("connect", c), c = void 0), s || (s = this.onAccountsChanged.bind(this), u.on("accountsChanged", s)), o || (o = this.onChainChanged.bind(this), u.on("chainChanged", o)), a || (a = this.onDisconnect.bind(this), u.on("disconnect", a)));
|
|
5375
5429
|
},
|
|
5376
5430
|
async onDisconnect(A) {
|
|
5377
5431
|
const d = await this.getProvider();
|
|
@@ -5379,19 +5433,19 @@ function En(e = {}) {
|
|
|
5379
5433
|
}
|
|
5380
5434
|
});
|
|
5381
5435
|
}
|
|
5382
|
-
const
|
|
5436
|
+
const Zc = {
|
|
5383
5437
|
coinbaseWallet: {
|
|
5384
5438
|
id: "coinbaseWallet",
|
|
5385
5439
|
name: "Coinbase Wallet",
|
|
5386
5440
|
provider(e) {
|
|
5387
|
-
return e?.coinbaseWalletExtension ? e.coinbaseWalletExtension :
|
|
5441
|
+
return e?.coinbaseWalletExtension ? e.coinbaseWalletExtension : Te(e, "isCoinbaseWallet");
|
|
5388
5442
|
}
|
|
5389
5443
|
},
|
|
5390
5444
|
metaMask: {
|
|
5391
5445
|
id: "metaMask",
|
|
5392
5446
|
name: "MetaMask",
|
|
5393
5447
|
provider(e) {
|
|
5394
|
-
return
|
|
5448
|
+
return Te(e, (n) => {
|
|
5395
5449
|
if (!n.isMetaMask || n.isBraveWallet && !n._events && !n._state)
|
|
5396
5450
|
return !1;
|
|
5397
5451
|
const t = [
|
|
@@ -5425,11 +5479,11 @@ const Sc = {
|
|
|
5425
5479
|
id: "phantom",
|
|
5426
5480
|
name: "Phantom",
|
|
5427
5481
|
provider(e) {
|
|
5428
|
-
return e?.phantom?.ethereum ? e.phantom?.ethereum :
|
|
5482
|
+
return e?.phantom?.ethereum ? e.phantom?.ethereum : Te(e, "isPhantom");
|
|
5429
5483
|
}
|
|
5430
5484
|
}
|
|
5431
5485
|
};
|
|
5432
|
-
function
|
|
5486
|
+
function Te(e, n) {
|
|
5433
5487
|
function t(s) {
|
|
5434
5488
|
return typeof n == "function" ? n(s) : typeof n == "string" ? s[n] : !0;
|
|
5435
5489
|
}
|
|
@@ -5439,14 +5493,14 @@ function je(e, n) {
|
|
|
5439
5493
|
if (r && t(r))
|
|
5440
5494
|
return r;
|
|
5441
5495
|
}
|
|
5442
|
-
function
|
|
5496
|
+
function kc(e, n = k.EVM) {
|
|
5443
5497
|
if (!e.providers[n])
|
|
5444
5498
|
return null;
|
|
5445
5499
|
const t = e.providers[n]?.provider;
|
|
5446
5500
|
if (!t)
|
|
5447
5501
|
return null;
|
|
5448
5502
|
const r = e.info, s = r.rdns || r.uuid || `wallet-${r.name.toLowerCase().replace(/\s+/g, "-")}`;
|
|
5449
|
-
return
|
|
5503
|
+
return is((o) => ({
|
|
5450
5504
|
...En({
|
|
5451
5505
|
target: () => ({
|
|
5452
5506
|
id: s,
|
|
@@ -5462,14 +5516,14 @@ function Oc(e, n = k.EVM) {
|
|
|
5462
5516
|
emitter: o.emitter
|
|
5463
5517
|
}));
|
|
5464
5518
|
}
|
|
5465
|
-
function
|
|
5519
|
+
function Jc(e, n = k.EVM, t) {
|
|
5466
5520
|
const r = [];
|
|
5467
5521
|
if (t.length === 0)
|
|
5468
5522
|
return r;
|
|
5469
5523
|
for (const s of e) {
|
|
5470
|
-
const o =
|
|
5524
|
+
const o = kc(s, n);
|
|
5471
5525
|
if (o) {
|
|
5472
|
-
const c =
|
|
5526
|
+
const c = Ec(Lc());
|
|
5473
5527
|
r.push(
|
|
5474
5528
|
o({
|
|
5475
5529
|
chains: t,
|
|
@@ -5480,81 +5534,79 @@ function Yc(e, n = k.EVM, t) {
|
|
|
5480
5534
|
}
|
|
5481
5535
|
return r;
|
|
5482
5536
|
}
|
|
5483
|
-
function
|
|
5537
|
+
function Fc(e, n = []) {
|
|
5484
5538
|
const t = [...n], r = (o) => o.id ?? o.options?.id ?? o.options?.name, s = new Set(n.map((o) => r(o)));
|
|
5485
5539
|
for (const o of e)
|
|
5486
5540
|
s.has(r(o)) || t.push(o);
|
|
5487
5541
|
return t;
|
|
5488
5542
|
}
|
|
5489
|
-
const
|
|
5490
|
-
const [t, r] = N(P.Loading), { walletState: s, setWalletState: o, error: c, setError: a, resetWalletState: l } = Nn(), A =
|
|
5543
|
+
const Dc = new _r(), ra = ({ children: e, config: n }) => {
|
|
5544
|
+
const [t, r] = N(P.Loading), { walletState: s, setWalletState: o, error: c, setError: a, resetWalletState: l } = Nn(), A = cr(), d = B(() => {
|
|
5491
5545
|
const fe = {
|
|
5492
|
-
evm:
|
|
5493
|
-
solana:
|
|
5546
|
+
evm: Ne.evm,
|
|
5547
|
+
solana: Ne.solana,
|
|
5494
5548
|
// dogecoin: recommonedChains.dogecoin,
|
|
5495
|
-
aptos:
|
|
5496
|
-
},
|
|
5549
|
+
aptos: Ne.aptos
|
|
5550
|
+
}, xr = n?.chains || {}, pr = {
|
|
5497
5551
|
...fe,
|
|
5498
|
-
...
|
|
5499
|
-
},
|
|
5552
|
+
...xr
|
|
5553
|
+
}, br = {
|
|
5500
5554
|
...n,
|
|
5501
|
-
connectors: n?.connectors ||
|
|
5502
|
-
chains:
|
|
5503
|
-
embeddedWalletConfig: { ...
|
|
5555
|
+
connectors: n?.connectors || ye.recommonedWallets,
|
|
5556
|
+
chains: pr,
|
|
5557
|
+
embeddedWalletConfig: { ...tr, clientId: n?.clientId || nr },
|
|
5504
5558
|
themeMode: "light",
|
|
5505
|
-
prodType:
|
|
5559
|
+
prodType: je.MyDoge,
|
|
5506
5560
|
wagmi: A ? {
|
|
5507
5561
|
config: A
|
|
5508
5562
|
} : void 0
|
|
5509
5563
|
};
|
|
5510
|
-
return rt(A || null),
|
|
5511
|
-
}, [n, A]), f = B(() => d?.prodType ===
|
|
5512
|
-
wallet:
|
|
5513
|
-
isAvailable:
|
|
5564
|
+
return rt(A || null), br;
|
|
5565
|
+
}, [n, A]), f = B(() => d?.prodType === je.Tomo ? P.SocialLogin : d?.prodType === je.MyDoge ? P.MyDogeSocialLogin : P.SocialLogin, [d?.prodType]), {
|
|
5566
|
+
wallet: u,
|
|
5567
|
+
isAvailable: g,
|
|
5514
5568
|
isLoading: x,
|
|
5515
|
-
connectedInfo:
|
|
5569
|
+
connectedInfo: v,
|
|
5516
5570
|
message: m
|
|
5517
|
-
} =
|
|
5518
|
-
config: d.embeddedWalletConfig
|
|
5519
|
-
|
|
5520
|
-
|
|
5521
|
-
|
|
5522
|
-
|
|
5523
|
-
|
|
5524
|
-
b.setView(s.isConnected ? P.Account : t), b.openModal();
|
|
5525
|
-
}, [b.setView, b.openModal, s.isConnected, t]), p = Ho({
|
|
5571
|
+
} = Mc({
|
|
5572
|
+
config: d.embeddedWalletConfig,
|
|
5573
|
+
setMainView: r,
|
|
5574
|
+
defaultMainView: f
|
|
5575
|
+
}), p = Lo(t), y = T(() => {
|
|
5576
|
+
p.setView(s.isConnected ? P.Account : t), p.openModal();
|
|
5577
|
+
}, [p.setView, p.openModal, s.isConnected, t]), b = Go({
|
|
5526
5578
|
walletState: s,
|
|
5527
|
-
modalState:
|
|
5579
|
+
modalState: p,
|
|
5528
5580
|
setWalletState: o,
|
|
5529
5581
|
resetWalletState: l,
|
|
5530
5582
|
setError: a,
|
|
5531
5583
|
setMainView: r
|
|
5532
5584
|
}), w = B(
|
|
5533
5585
|
() => ({
|
|
5534
|
-
isOpen:
|
|
5535
|
-
view:
|
|
5536
|
-
prevView:
|
|
5537
|
-
openModal:
|
|
5538
|
-
closeModal:
|
|
5539
|
-
setView:
|
|
5540
|
-
openModalWithState:
|
|
5541
|
-
backView:
|
|
5542
|
-
state:
|
|
5543
|
-
setCurrentViewState:
|
|
5586
|
+
isOpen: p.isOpen,
|
|
5587
|
+
view: p.view,
|
|
5588
|
+
prevView: p.prevView,
|
|
5589
|
+
openModal: y,
|
|
5590
|
+
closeModal: p.closeModal,
|
|
5591
|
+
setView: p.setView,
|
|
5592
|
+
openModalWithState: p.openModalWithState,
|
|
5593
|
+
backView: p.backView,
|
|
5594
|
+
state: p.state,
|
|
5595
|
+
setCurrentViewState: p.setCurrentViewState,
|
|
5544
5596
|
mainView: t,
|
|
5545
5597
|
setMainView: r
|
|
5546
5598
|
}),
|
|
5547
5599
|
[
|
|
5548
|
-
|
|
5549
|
-
|
|
5550
|
-
|
|
5551
|
-
|
|
5552
|
-
|
|
5553
|
-
|
|
5554
|
-
|
|
5555
|
-
|
|
5556
|
-
|
|
5557
|
-
|
|
5600
|
+
p.isOpen,
|
|
5601
|
+
p.view,
|
|
5602
|
+
p.prevView,
|
|
5603
|
+
p.closeModal,
|
|
5604
|
+
p.setView,
|
|
5605
|
+
p.backView,
|
|
5606
|
+
p.state,
|
|
5607
|
+
p.setCurrentViewState,
|
|
5608
|
+
y,
|
|
5609
|
+
p.openModalWithState,
|
|
5558
5610
|
t,
|
|
5559
5611
|
r
|
|
5560
5612
|
]
|
|
@@ -5583,35 +5635,35 @@ const kc = new Gr(), ea = ({ children: e, config: n }) => {
|
|
|
5583
5635
|
s.currentWallet,
|
|
5584
5636
|
s.currentProvider
|
|
5585
5637
|
]
|
|
5586
|
-
),
|
|
5638
|
+
), M = B(
|
|
5587
5639
|
() => ({
|
|
5588
|
-
connect:
|
|
5589
|
-
disconnect:
|
|
5590
|
-
switchChain:
|
|
5591
|
-
signInWithWallet:
|
|
5592
|
-
signMessage:
|
|
5640
|
+
connect: b.connect,
|
|
5641
|
+
disconnect: b.disconnect,
|
|
5642
|
+
switchChain: b.switchChain,
|
|
5643
|
+
signInWithWallet: b.signInWithWallet,
|
|
5644
|
+
signMessage: b.signMessage,
|
|
5593
5645
|
// signTransaction: walletActions.signTransaction,
|
|
5594
5646
|
// signAndSendTransaction: walletActions.signAndSendTransaction,
|
|
5595
5647
|
// sendTransaction: walletActions.sendTransaction,
|
|
5596
|
-
_setCurrentWallet:
|
|
5648
|
+
_setCurrentWallet: b._setCurrentWallet
|
|
5597
5649
|
}),
|
|
5598
5650
|
[
|
|
5599
|
-
|
|
5600
|
-
|
|
5601
|
-
|
|
5602
|
-
|
|
5603
|
-
|
|
5604
|
-
|
|
5651
|
+
b.connect,
|
|
5652
|
+
b.disconnect,
|
|
5653
|
+
b.switchChain,
|
|
5654
|
+
b.signInWithWallet,
|
|
5655
|
+
b.signMessage,
|
|
5656
|
+
b._setCurrentWallet
|
|
5605
5657
|
]
|
|
5606
5658
|
), E = B(
|
|
5607
5659
|
() => ({
|
|
5608
|
-
wallet:
|
|
5609
|
-
isAvailable:
|
|
5660
|
+
wallet: u,
|
|
5661
|
+
isAvailable: g,
|
|
5610
5662
|
isLoading: x,
|
|
5611
|
-
connectedInfo:
|
|
5663
|
+
connectedInfo: v,
|
|
5612
5664
|
message: m
|
|
5613
5665
|
}),
|
|
5614
|
-
[
|
|
5666
|
+
[u, g, x, v, m]
|
|
5615
5667
|
), L = B(
|
|
5616
5668
|
() => ({
|
|
5617
5669
|
config: d,
|
|
@@ -5619,18 +5671,15 @@ const kc = new Gr(), ea = ({ children: e, config: n }) => {
|
|
|
5619
5671
|
connection: I,
|
|
5620
5672
|
account: j,
|
|
5621
5673
|
embeddedWallet: E,
|
|
5622
|
-
...
|
|
5674
|
+
...M
|
|
5623
5675
|
}),
|
|
5624
|
-
[d, w, I, j, E,
|
|
5625
|
-
),
|
|
5626
|
-
|
|
5627
|
-
|
|
5628
|
-
|
|
5629
|
-
return console.log("--- WalletConnectProvider --- defaultTheme::", Y), /* @__PURE__ */ i(Kr, { client: kc, children: /* @__PURE__ */ v(M.Provider, { value: L, children: [
|
|
5630
|
-
/* @__PURE__ */ i(Jc, { setWalletState: o }),
|
|
5631
|
-
/* @__PURE__ */ v(Tr, { defaultTheme: Y, forcedTheme: Y, children: [
|
|
5676
|
+
[d, w, I, j, E, M]
|
|
5677
|
+
), Z = B(() => dr(), []);
|
|
5678
|
+
return console.log("--- WalletConnectProvider --- defaultTheme::", Z), typeof window > "u" ? null : /* @__PURE__ */ i(Rr, { client: Dc, children: /* @__PURE__ */ C(W.Provider, { value: L, children: [
|
|
5679
|
+
/* @__PURE__ */ i(Hc, { setWalletState: o }),
|
|
5680
|
+
/* @__PURE__ */ C(Sr, { themeConfig: Z, children: [
|
|
5632
5681
|
/* @__PURE__ */ i(
|
|
5633
|
-
|
|
5682
|
+
Or,
|
|
5634
5683
|
{
|
|
5635
5684
|
maxVisibleToasts: 3,
|
|
5636
5685
|
placement: "top-center",
|
|
@@ -5642,24 +5691,24 @@ const kc = new Gr(), ea = ({ children: e, config: n }) => {
|
|
|
5642
5691
|
}
|
|
5643
5692
|
),
|
|
5644
5693
|
e,
|
|
5645
|
-
/* @__PURE__ */ i(
|
|
5694
|
+
/* @__PURE__ */ i(hc, {})
|
|
5646
5695
|
] })
|
|
5647
5696
|
] }) });
|
|
5648
|
-
},
|
|
5649
|
-
const n = V(
|
|
5697
|
+
}, Hc = ({ setWalletState: e }) => {
|
|
5698
|
+
const n = V(W);
|
|
5650
5699
|
if (!n)
|
|
5651
5700
|
throw new Error("SetupHooks must be used within WalletConnectProvider");
|
|
5652
|
-
const t =
|
|
5653
|
-
return
|
|
5701
|
+
const t = he("all", n.config?.connectors || []), r = n.config?.wagmi, s = r?.config;
|
|
5702
|
+
return Y(() => {
|
|
5654
5703
|
if (!s || !t.data) {
|
|
5655
5704
|
tn(null);
|
|
5656
5705
|
return;
|
|
5657
5706
|
}
|
|
5658
|
-
const o = s.connectors || [], c = s.chains || [], a = t?.data?.all?.filter((d) => d.providers.evm), l =
|
|
5707
|
+
const o = s.connectors || [], c = s.chains || [], a = t?.data?.all?.filter((d) => d.providers.evm), l = Jc(a || [], k.EVM, c), A = Fc(l, o);
|
|
5659
5708
|
A.length > 0 ? tn(A) : tn(null);
|
|
5660
|
-
}, [t.data, s]),
|
|
5661
|
-
|
|
5662
|
-
}, [n.config?.walletConnectConfig]),
|
|
5709
|
+
}, [t.data, s]), Y(() => {
|
|
5710
|
+
Gr(n.config?.walletConnectConfig || Zo);
|
|
5711
|
+
}, [n.config?.walletConnectConfig]), Wc({
|
|
5663
5712
|
setWalletState: e,
|
|
5664
5713
|
currentWallet: n.account.currentWallet,
|
|
5665
5714
|
isConnected: n.connection.isConnected,
|
|
@@ -5672,14 +5721,14 @@ const kc = new Gr(), ea = ({ children: e, config: n }) => {
|
|
|
5672
5721
|
},
|
|
5673
5722
|
wagmiConfig: r
|
|
5674
5723
|
}), null;
|
|
5675
|
-
},
|
|
5676
|
-
const t = V(
|
|
5677
|
-
if (
|
|
5724
|
+
}, sa = ({ className: e, style: n }) => {
|
|
5725
|
+
const t = V(W), r = t?.modal.mainView || P.MyDogeSocialLogin;
|
|
5726
|
+
if (Y(() => {
|
|
5678
5727
|
t && t.modal.view !== r && t.modal.setView(r);
|
|
5679
5728
|
}, [r]), !t)
|
|
5680
5729
|
return console.error("WalletConnectEmbed must be used within WalletConnectProvider"), null;
|
|
5681
5730
|
const s = t.modal.view, c = (() => {
|
|
5682
|
-
const a =
|
|
5731
|
+
const a = vr[s];
|
|
5683
5732
|
return a ? a(t) : null;
|
|
5684
5733
|
})();
|
|
5685
5734
|
return /* @__PURE__ */ i(
|
|
@@ -5692,9 +5741,9 @@ const kc = new Gr(), ea = ({ children: e, config: n }) => {
|
|
|
5692
5741
|
);
|
|
5693
5742
|
};
|
|
5694
5743
|
export {
|
|
5695
|
-
|
|
5696
|
-
|
|
5744
|
+
sa as WalletConnectEmbed,
|
|
5745
|
+
ra as WalletConnectProvider,
|
|
5697
5746
|
jn as useAccount,
|
|
5698
5747
|
er as useEmbeddedWallet,
|
|
5699
|
-
|
|
5748
|
+
ta as useWalletConnect
|
|
5700
5749
|
};
|