@blockend/widget 1.0.63-beta.1 → 1.0.63-beta.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (115) hide show
  1. package/dist/{AllRoutes-8vhlfGf-.js → AllRoutes-mBMX-bp_.js} +210 -207
  2. package/dist/{Box-BTaHIEfq.js → Box-Cr6tremn.js} +8 -8
  3. package/dist/{EstGas-CR6YmgrV.js → EstGas-ziYEbWgu.js} +547 -542
  4. package/dist/{Grow-BmLMXGpF.js → Grow-Uh43i8On.js} +218 -214
  5. package/dist/{InputComp-BcRHFujR.js → InputComp-DIz_bhSV.js} +3 -3
  6. package/dist/LoadRoute-BGqC0Xbo.js +104 -0
  7. package/dist/{QuotesProgress-dZK5t6Af.js → QuotesProgress-DK8bSV7f.js} +1 -1
  8. package/dist/{SwapAsset-Cb1HU2IW.js → SwapAsset-Bx_hxHw_.js} +1 -1
  9. package/dist/{Tooltip-CCJQNWKV.js → Tooltip-DB7x5JO7.js} +9 -6
  10. package/dist/{TxnButton-Ddhzivbr.js → TxnButton-CDmjKNZg.js} +65 -62
  11. package/dist/{add-CXxCm9LT.js → add-5z4JukLX.js} +1 -1
  12. package/dist/{all-wallets-B2k777Go.js → all-wallets-De3YAlW5.js} +1 -1
  13. package/dist/{app-store-BefvqWIr.js → app-store-YB3L3A0D.js} +1 -1
  14. package/dist/{apple-xv2wilZw.js → apple-kfJszt4b.js} +1 -1
  15. package/dist/{arrow-bottom-eJR2wz4Q.js → arrow-bottom-Cq_VhiDl.js} +1 -1
  16. package/dist/{arrow-bottom-circle-DiCGVTmN.js → arrow-bottom-circle-DvzO-Vqy.js} +1 -1
  17. package/dist/{arrow-left-eW5rkpGR.js → arrow-left-BCztmLY3.js} +1 -1
  18. package/dist/{arrow-right-D_PahEvj.js → arrow-right-sVlvqvsf.js} +1 -1
  19. package/dist/{arrow-top-Cd45U-OK.js → arrow-top-Cwc_K8xV.js} +1 -1
  20. package/dist/{bank-Du_PBJEL.js → bank-DANyn1rV.js} +1 -1
  21. package/dist/{basic-Og2t8wfR.js → basic-DZjAzDnu.js} +4 -4
  22. package/dist/{browser-HO6X74Jh.js → browser-B1RJm60J.js} +1 -1
  23. package/dist/{card-CjWBCXYA.js → card-DglUN2Dw.js} +1 -1
  24. package/dist/{ccip-DHqvWSgS.js → ccip-DyYKyf2y.js} +7 -7
  25. package/dist/{checkmark-CMLNKLjH.js → checkmark-QhiUr5Em.js} +1 -1
  26. package/dist/{checkmark-bold-CM9EIYV0.js → checkmark-bold-DwUSqNus.js} +1 -1
  27. package/dist/{chevron-bottom-BDaOxnxp.js → chevron-bottom-B8G1KuSc.js} +1 -1
  28. package/dist/{chevron-left-BuK5WmH2.js → chevron-left-C73Lc8jb.js} +1 -1
  29. package/dist/{chevron-right-BMRPUQ7d.js → chevron-right-Ci4LZG1w.js} +1 -1
  30. package/dist/{chevron-top-DndcjTpF.js → chevron-top-BlYO8Hto.js} +1 -1
  31. package/dist/{chrome-store-BMaWFKtJ.js → chrome-store-CSNoMmva.js} +1 -1
  32. package/dist/{clock-B5OmOXN6.js → clock-B4XVIA65.js} +1 -1
  33. package/dist/{close-Bkt0qqtO.js → close-B97SZOIl.js} +1 -1
  34. package/dist/{coinPlaceholder-B9E-pdBA.js → coinPlaceholder-QiZwz0LU.js} +1 -1
  35. package/dist/{compass-70YC7hlj.js → compass-D_qqx-55.js} +1 -1
  36. package/dist/{copy-6xIbuiPA.js → copy-BIUx3Q4I.js} +1 -1
  37. package/dist/{core-CIqAJqfO.js → core-d7L-Vu90.js} +390 -324
  38. package/dist/createSvgIcon-B3VTAeTx.js +195 -0
  39. package/dist/{cursor-transparent-umSbGkB7.js → cursor-transparent-RsKqf-mA.js} +1 -1
  40. package/dist/{cursor-XVsA3bFU.js → cursor-xqG0UDxP.js} +1 -1
  41. package/dist/{desktop-CXv5OVB9.js → desktop-BsA5eXYT.js} +1 -1
  42. package/dist/{disconnect-Dvhyoj4V.js → disconnect-Cv1V757w.js} +1 -1
  43. package/dist/{discord-BVK5s4WI.js → discord-Cr6DjrX0.js} +1 -1
  44. package/dist/{down-FxTTd1zc.js → down-CBwp2T3r.js} +4 -3
  45. package/dist/{etherscan-DxlyP6n6.js → etherscan-cVdy9Xv_.js} +1 -1
  46. package/dist/{exclamation-triangle-iHVFOZzs.js → exclamation-triangle-DB_vFVh2.js} +1 -1
  47. package/dist/{extension-DiDqWBcW.js → extension-Dx_lggvf.js} +1 -1
  48. package/dist/{external-link-BHW_akeT.js → external-link-DjGJMqQX.js} +1 -1
  49. package/dist/{facebook-BdfpC6Ls.js → facebook-ByNlHgEv.js} +1 -1
  50. package/dist/{farcaster-CsPD4_Ee.js → farcaster-AFncrE0q.js} +1 -1
  51. package/dist/{filters-CqRduOsu.js → filters-BJ7jwu2Q.js} +1 -1
  52. package/dist/{getChainIds-CJguHdTG.js → getChainIds-DgE0msCJ.js} +6 -4
  53. package/dist/{getCosmosAddress-Jm1ni4XU.js → getCosmosAddress-SgJhNeUL.js} +1542 -1537
  54. package/dist/{github-BOePu0Wa.js → github-BhBjXAs5.js} +1 -1
  55. package/dist/{google-BbTzqlxg.js → google-CnJ7nycT.js} +1 -1
  56. package/dist/{hamburger-Co59plQs.js → hamburger-l96tqs1h.js} +445 -436
  57. package/dist/{help-circle-f8w-O5uS.js → help-circle-DS8SqIHZ.js} +1 -1
  58. package/dist/{id-FJz-6DWQ.js → id-C59Wrku-.js} +1 -1
  59. package/dist/{image-BGcjHz_W.js → image-IR2_4E_d.js} +1 -1
  60. package/dist/{index-B7BjZ7QD.js → index-ABEW9neF.js} +4 -4
  61. package/dist/{index-BGtpuYz8.js → index-B6m7TmsK.js} +1 -1
  62. package/dist/{index-Qlxj5hfD.js → index-BFZtIV9K.js} +78 -78
  63. package/dist/{index-uGXbvlKh.js → index-BVUqg2le.js} +2 -2
  64. package/dist/{index-DN3VaeWb.js → index-BfLdGiQm.js} +32 -21
  65. package/dist/{index-CsUXwhXc.js → index-BiNu6NEt.js} +393 -388
  66. package/dist/{index-DTish3yr.js → index-Bl2UpALc.js} +3 -1
  67. package/dist/{index-BmpkN5Ku.js → index-Cbk_Sa95.js} +1151 -1134
  68. package/dist/index-Cyy7b5hp.js +113 -0
  69. package/dist/{index-Yg5537Ua.js → index-DxIrenBx.js} +1477 -1580
  70. package/dist/index-JX8acpSp.js +17555 -0
  71. package/dist/{index-B1aDjOsb.js → index-aVpPjW18.js} +5113 -5042
  72. package/dist/{index.es-DksqakUY.js → index.es-BN06Lzg3.js} +978 -958
  73. package/dist/{index.es-DI1TVLSl.js → index.es-DrRzHjO0.js} +1 -1
  74. package/dist/index.es.js +1 -1
  75. package/dist/{info-D7az05BN.js → info-BT2xuCwg.js} +1 -1
  76. package/dist/{info-circle-BJVzgICV.js → info-circle-DZehzZtq.js} +1 -1
  77. package/dist/{lightbulb-BwTw8953.js → lightbulb-DthuZVnA.js} +1 -1
  78. package/dist/{mail-yo0Q-pKc.js → mail-CkXT-iZ5.js} +1 -1
  79. package/dist/{mobile-Cq9QgJo1.js → mobile-DgdclEn8.js} +1 -1
  80. package/dist/{more-CA9mN5hg.js → more-Cejj_uHx.js} +1 -1
  81. package/dist/{network-placeholder-DJgEL8xU.js → network-placeholder-BpQc3aWv.js} +1 -1
  82. package/dist/{nftPlaceholder-BtmwsJfE.js → nftPlaceholder-cCa6Bwxp.js} +1 -1
  83. package/dist/{off-DOBUEPIz.js → off-CLDqc8wX.js} +1 -1
  84. package/dist/{play-store-CTeI1TUT.js → play-store-BO1-bjg7.js} +1 -1
  85. package/dist/{plus-BIMbqFAs.js → plus-DiEUEjd6.js} +1 -1
  86. package/dist/{qr-code-BNLm2nbm.js → qr-code-C7lqAnYE.js} +1 -1
  87. package/dist/{recycle-horizontal-CD20fzzc.js → recycle-horizontal-CFsdwGO2.js} +1 -1
  88. package/dist/{refresh-vAF43DQ5.js → refresh-DU5E3fUF.js} +1 -1
  89. package/dist/{reown-logo-QC8cVkw7.js → reown-logo-DQHwmwSu.js} +1 -1
  90. package/dist/{search-BEV7hWzk.js → search-DPTQ2PY-.js} +1 -1
  91. package/dist/{send-DQuKJTh-.js → send-qEnLDoA5.js} +1 -1
  92. package/dist/{swapHorizontal-QlUI5TkM.js → swapHorizontal-Z_ilQ4q_.js} +1 -1
  93. package/dist/{swapHorizontalBold-CxRB7lBz.js → swapHorizontalBold-CAfW1IWh.js} +1 -1
  94. package/dist/{swapHorizontalMedium-DR23H9E6.js → swapHorizontalMedium-CsxO8OiO.js} +1 -1
  95. package/dist/{swapHorizontalRoundedBold-CvCYhrA3.js → swapHorizontalRoundedBold-CNKb9td4.js} +1 -1
  96. package/dist/{swapVertical-NpfviMzk.js → swapVertical-CSHfhA6V.js} +1 -1
  97. package/dist/{telegram-B2E4bkq4.js → telegram-CcazSHGC.js} +1 -1
  98. package/dist/{three-dots-zOUHoCrw.js → three-dots-B1bx4iJg.js} +1 -1
  99. package/dist/{twitch-DvXB4cDF.js → twitch-Db4kgU2y.js} +1 -1
  100. package/dist/{twitterIcon-CkAU-gkN.js → twitterIcon-DFK4zKw_.js} +1 -1
  101. package/dist/{unsupportedProp-CR0Bm2eS.js → unsupportedProp-DKp2x8RO.js} +1 -1
  102. package/dist/{useRegisterError-B1UKihdk.js → useRegisterError-CoZkPgOD.js} +126 -122
  103. package/dist/{verify-filled-DQ3ygXuA.js → verify-filled-DOzDdvDY.js} +1 -1
  104. package/dist/{verify-DcGLVQiP.js → verify-xpMnGOFP.js} +1 -1
  105. package/dist/{w3m-modal-BJNv805u.js → w3m-modal-BiNAmx5t.js} +2 -2
  106. package/dist/{wallet-Dyl015cJ.js → wallet-0J5FldrO.js} +1 -1
  107. package/dist/{wallet-placeholder-DwdGMd_q.js → wallet-placeholder-DNMFsvfL.js} +1 -1
  108. package/dist/{walletconnect-Cm10vkxV.js → walletconnect-BNUJ3LS5.js} +1 -1
  109. package/dist/{warning-circle-B_JpskvF.js → warning-circle-BHQ_LgKt.js} +1 -1
  110. package/dist/widget.css +1 -1
  111. package/dist/{x-BBTlR8TT.js → x-C1_RFZRq.js} +1 -1
  112. package/package.json +2 -2
  113. package/dist/LoadRoute-D-6AXSyf.js +0 -125
  114. package/dist/index-By0HLmvg.js +0 -18509
  115. package/dist/index-C9NKLe0T.js +0 -330
@@ -1,10 +1,10 @@
1
1
  import { jsxs as b, jsx as t, Fragment as k } from "react/jsx-runtime";
2
- import { u as n, S as W } from "./index-B1aDjOsb.js";
2
+ import { u as n, S as W } from "./index-aVpPjW18.js";
3
3
  import { useState as S, useRef as x } from "react";
4
- import { u as j, i as I, W as D, F, f as p, c as u, z as R } from "./useRegisterError-B1UKihdk.js";
4
+ import { u as j, i as I, W as D, F, f as p, c as u, z as R } from "./useRegisterError-CoZkPgOD.js";
5
5
  import { useAccount as T, useBalance as A } from "wagmi";
6
6
  import "@dynamic-labs/sdk-react-core";
7
- import { c as B, r as G } from "./index-CsUXwhXc.js";
7
+ import { c as B, r as G } from "./index-BiNu6NEt.js";
8
8
  function H({ amount: w, setAmount: l, fetchBalance: M, getCoinBalance: h, isBalanceLoading: f }) {
9
9
  var d, o;
10
10
  const s = n((a) => a.configuration), e = n((a) => a.fromCoin), r = n((a) => a.fromChain), { isAnyWalletConnected: g } = j({ chainData: r }), [$, z] = S(40), { address: N } = T(), v = x(), { defaultCoin: y } = I;
@@ -0,0 +1,104 @@
1
+ import { jsx as b, jsxs as t, Fragment as m } from "react/jsx-runtime";
2
+ import { t as te } from "./truncate-D9t92mVX.js";
3
+ import { u as r, S as o, l as we } from "./index-aVpPjW18.js";
4
+ import { useState as ie, useEffect as le } from "react";
5
+ import { s as a } from "./WidgetForm.module-QHJ0-m5f.js";
6
+ import { G as ce, C as de, S as me } from "./clockIcon-C2W5xvyt.js";
7
+ import { S as re } from "./down-CBwp2T3r.js";
8
+ import { e as se } from "./ethertousd-CC_ezooz.js";
9
+ import { O as J } from "./index-B6m7TmsK.js";
10
+ import { F as K, i as ae } from "./useRegisterError-CoZkPgOD.js";
11
+ function Se({ routes: n, handleShowAllRoutes: Q, routesData: e, price: X, amount: Y, isRoutesEnabled: y }) {
12
+ var v, N, F, S, k, u, $, E, j, I, U, C, A, G, O, T, z, L, R, _, M, V, q, B, P, W;
13
+ const x = n.data, [c, Z] = ie(), l = r((i) => i.gradient), w = r((i) => i.configuration), h = r((i) => i.fromChain), g = r((i) => i.fromCoin), p = r((i) => i.toChain), d = r((i) => i.toCoin), { defaultCoin: D } = ae;
14
+ le(() => {
15
+ var i;
16
+ if (e) {
17
+ let f = { amountInUSD: 0, amountInNative: 0 }, H = {};
18
+ (i = e == null ? void 0 : e.fee) == null || i.forEach((s) => {
19
+ s.source == "FROM_SOURCE_WALLET" && (f.amountInUSD += Number(s.amountInUSD), f.amountInNative += Number(se(s.amountInToken, s.token.decimals)), H = { ...s });
20
+ }), Z({ tempGasObj: f, token: H });
21
+ }
22
+ }, [e]);
23
+ let ee = (e == null ? void 0 : e.outputAmountDisplay) || "", be = X.toString(), ne = (N = (v = e == null ? void 0 : e.providerDetails) == null ? void 0 : v.logoUrl) != null && N.length ? (F = e == null ? void 0 : e.providerDetails) == null ? void 0 : F.logoUrl : D;
24
+ return /* @__PURE__ */ b("div", { className: "bw-mt-2", children: (S = h == null ? void 0 : h.chain) != null && S.length && ((k = g == null ? void 0 : g.coin) != null && k.length) && ((u = p == null ? void 0 : p.chain) != null && u.length) && (($ = d == null ? void 0 : d.coin) != null && $.length) && Y.length && y ? n.isSuccess && !((I = (j = (E = n.data) == null ? void 0 : E.data) == null ? void 0 : j.quotes) != null && I.length) && !n.isFetching ? /* @__PURE__ */ b("div", { className: "bw-bg-background-container bw-text-text-secondary bw-flex bw-justify-center bw-items-center bw-h-[80px] bw-relative bw-flex-col bw-border bw-border-border-primary", children: "No Routes Available" }) : n.isSuccess || n.isLoading || n.isFetching ? /* @__PURE__ */ t("div", { children: [
25
+ /* @__PURE__ */ t("div", { className: "bw-flex bw-items-center bw-justify-between", children: [
26
+ " ",
27
+ /* @__PURE__ */ t("p", { className: "bw-text-sm bw-font-medium bw-text-text-secondary", children: [
28
+ "Get ",
29
+ d.name
30
+ ] }),
31
+ n.isFetching ? /* @__PURE__ */ b(m, {}) : /* @__PURE__ */ b("div", { onClick: Q, style: { ...w.gradientStyle }, className: `bw-w-[130px] bw-cursor-pointer bw-relative bw-p-[1px] bw-text-transparent bw-text-sm bw-font-normal bw-h-[18px] bw-rounded-xl ${l || `${a.overlayshow} ${(U = w.gradientStyle) != null && U.background ? "" : "bw-bg-gradient-to-r bw-from-[#A45EFF] bw-to-[#2CFFE4]"}`}`, children: /* @__PURE__ */ b("div", { className: " bw-w-full bw-h-full bw-text-text-secondary bw-relative bw-z-10 bw-bg-background-container bw-flex bw-justify-center bw-items-center bw-text-xs bw-font-normal bw-rounded-xl", children: "Show All Routes" }) })
32
+ ] }),
33
+ /* @__PURE__ */ t("div", { className: " bw-mt-2", children: [
34
+ /* @__PURE__ */ t("div", { style: n.isFetching ? {} : { ...w.gradientStyle }, className: ` ${n.isFetching ? "bw-bg-background-secondary" : ` ${l || `${(C = w.gradientStyle) != null && C.background ? "" : "bw-bg-gradient-to-r bw-from-[#A45EFF] bw-to-[#2CFFE4]"} ${a.overlay}`} `} bw-relative bw-flex bw-justify-center bw-rounded-[8px] bw-w-full bw-p-[1px] bw-h-[86px] `, children: [
35
+ /* @__PURE__ */ t("div", { className: "bw-w-full bw-h-full bw-flex bw-px-2 bw-pb-3 bw-items-center bw-justify-between bw-bg-background-container rbw-elative bw-z-10 bw-rounded-[8px]", children: [
36
+ /* @__PURE__ */ t("div", { className: "bw-flex bw-items-start bw-gap-x-2", children: [
37
+ d != null && d.image && !n.isFetching ? /* @__PURE__ */ b("img", { src: d.image, width: 30, height: 30, className: "bw-mt-1 bw-max-w-[30px] bw-max-h-[30px] bw-object-contain bw-bg-background-secondary bw-rounded-[50%]" }) : /* @__PURE__ */ b(m, {}),
38
+ /* @__PURE__ */ t("div", { children: [
39
+ n.isFetching ? /* @__PURE__ */ b(o, { className: "bw-bg-background-secondary bw-mt-3 bw-rounded-sm bw-h-[36px] bw-min-h-[36px]", animation: "wave", variant: "rectangular", height: 36, width: 250 }) : /* @__PURE__ */ b("p", { className: "bw-text-2xl md:bw-text-3xl bw-mb-1 bw-font-medium bw-text-text-primary", children: /* @__PURE__ */ b(J, { value: ee, decimal: 12 }) }),
40
+ n.isFetching ? /* @__PURE__ */ b(o, { className: "bw-bg-background-secondary bw-mt-2 bw-rounded-sm bw-h-[20px] bw-w-[100px] bw-min-h-[20px]", variant: "rectangular", animation: "wave", height: 20, width: 100 }) : /* @__PURE__ */ t("div", { className: "bw-flex bw-items-center bw-gap-x-1", children: [
41
+ /* @__PURE__ */ b(ce, { fill: "var(--tw-text-primary)" }),
42
+ /* @__PURE__ */ t("p", { className: "bw-text-xs md:bw-text-sm bw-font-medium bw-text-text-primary", children: [
43
+ "Total Fee:",
44
+ " $",
45
+ /* @__PURE__ */ b(K, { value: ((A = c == null ? void 0 : c.tempGasObj) == null ? void 0 : A.amountInUSD) || 0, options: { maxDecimals: 8 } }),
46
+ " (",
47
+ /* @__PURE__ */ b(K, { value: ((G = c == null ? void 0 : c.tempGasObj) == null ? void 0 : G.amountInNative) || 0, options: { maxDecimals: 8 } }),
48
+ ` ${((T = (O = c == null ? void 0 : c.token) == null ? void 0 : O.token) == null ? void 0 : T.symbol) || ""})`
49
+ ] })
50
+ ] })
51
+ ] })
52
+ ] }),
53
+ /* @__PURE__ */ t("div", { className: " bw-text-sm bw-font-medium bw-mt-2 bw-text-text-loaderbar ", children: [
54
+ n.isFetching ? /* @__PURE__ */ b(o, { className: "bw-bg-background-secondary bw-w-[50px] bw-rounded-sm bw-h-[20px] bw-min-h-[20px]", variant: "rectangular", animation: "wave", height: 20, width: 50 }) : /* @__PURE__ */ t("p", { className: "bw-text-text-secondary bw-font-medium bw-text-xs md:bw-text-sm", children: [
55
+ "$",
56
+ /* @__PURE__ */ b(J, { value: be, decimal: 10 })
57
+ ] }),
58
+ n.isFetching ? /* @__PURE__ */ b(o, { className: "bw-bg-background-secondary bw-w-[50px] bw-mt-2 bw-rounded-sm bw-h-[20px] bw-min-h-[20px] ", variant: "rectangular", animation: "wave", height: 20, width: 50 }) : ((R = (L = (z = x == null ? void 0 : x.data) == null ? void 0 : z.quotes) == null ? void 0 : L[0]) == null ? void 0 : R._id) === e._id ? /* @__PURE__ */ b("div", { style: { ...w.gradientStyle }, className: `${l || `${(_ = w.gradientStyle) != null && _.background ? "" : "bw-bg-gradient-to-r bw-from-[#A45EFF] bw-to-[#2CFFE4]"} `} bw-mt-3 bw-text-right bw-text-transparent bw-text-[10px] bw-font-bold bw-bg-clip-text ${a.gradienttext}`, children: "BEST" }) : /* @__PURE__ */ b(m, {})
59
+ ] })
60
+ ] }),
61
+ n.isFetching ? /* @__PURE__ */ b("div", { className: "bw-absolute bw-w-[40px] bw-h-[40px] bw-bottom-[-35%] bw-z-20 ", children: /* @__PURE__ */ b(re, {}) }) : /* @__PURE__ */ b(m, {}),
62
+ /* @__PURE__ */ t("div", { className: "bw-h-[18px] bw-w-max bw-z-10 bw-min-w-[200px] bw-bg-background-container bw-flex bw-items-center bw-absolute bw-bottom-[-10%]", children: [
63
+ !n.isFetching && !we.isEmpty(e) ? /* @__PURE__ */ t("div", { className: "bw-flex bw-w-full bw-px-6 bw-items-center bw-gap-x-1", children: [
64
+ " ",
65
+ /* @__PURE__ */ t("p", { className: "bw-text-sm bw-w-full bw-text-center bw-flex bw-justify-center bw-items-center bw-font-normal bw-my-1 bw-text-text-secondary", children: [
66
+ /* @__PURE__ */ b("span", { className: "bw-text-sm bw-font-light", children: "via" }),
67
+ " ",
68
+ /* @__PURE__ */ b("img", { src: ne, className: "bw-rounded-[50%] bw-mx-[4px] bw-min-w-[18px] bw-max-h-[18px] bw-min-h-[18px]", width: 18, height: 18 }),
69
+ ((M = e == null ? void 0 : e.providerDetails) == null ? void 0 : M.name) || "",
70
+ ": ",
71
+ e == null ? void 0 : e.protocolsUsed[0],
72
+ ((V = e == null ? void 0 : e.protocolsUsed) == null ? void 0 : V.length) <= 1 ? "" : /* @__PURE__ */ t("span", { className: "bw-ml-1 bw-text-xs bw-font-normal", children: [
73
+ `+${((q = e == null ? void 0 : e.protocolsUsed) == null ? void 0 : q.length) - 1}`,
74
+ " More"
75
+ ] }),
76
+ " "
77
+ ] }),
78
+ " "
79
+ ] }) : /* @__PURE__ */ b(m, {}),
80
+ /* @__PURE__ */ b("div", { style: n.isFetching ? {} : { ...w.gradientStyle }, className: ` ${n.isFetching ? "bw-bg-background-secondary" : ` ${l || ` ${a.overlay} ${(B = w == null ? void 0 : w.gradientStyle) != null && B.background ? "" : "bw-bg-gradient-to-r bw-from-[#A45EFF] bw-to-[#2CFFE4]"}`}`} bw-absolute bw-right-0 bw-rounded-[50%] bw-w-[4px] bw-h-[4px] ` }),
81
+ /* @__PURE__ */ b("div", { style: n.isFetching ? {} : { ...w.gradientStyle }, className: ` ${n.isFetching ? "bw-bg-background-secondary" : ` ${l || ` ${a.overlay} ${(P = w == null ? void 0 : w.gradientStyle) != null && P.background ? "" : "bw-bg-gradient-to-r bw-from-[#A45EFF] bw-to-[#2CFFE4]"}`}`} bw-absolute bw-rounded-[50%] bw-w-[4px] bw-h-[4px] ` })
82
+ ] })
83
+ ] }),
84
+ /* @__PURE__ */ b("div", { className: "bw-bg-background-container bw-flex bw-items-center bw-w-[85%] bw-mx-auto bw-rounded-b-md bw-justify-center bw-h-[60px]", children: n.isFetching ? /* @__PURE__ */ b("div", { className: "bw-mt-6 bw-w-full bw-h-[20px]" }) : /* @__PURE__ */ t("div", { className: "bw-flex bw-items-center bw-gap-x-4 bw-mt-2 bw-bg-background-container bw-justify-center ", children: [
85
+ /* @__PURE__ */ t("div", { className: "bw-flex bw-items-center bw-gap-x-1", children: [
86
+ /* @__PURE__ */ b("p", { className: "bw-text-sm bw-font-medium bw-text-text-secondary", children: "Fee" }),
87
+ /* @__PURE__ */ b("p", { className: "bw-text-sm bw-line-through bw-font-medium bw-text-text-secondary", children: "0.1%" }),
88
+ /* @__PURE__ */ b("p", { className: "bw-text-sm bw-font-medium bw-text-text-secondary", children: "0" })
89
+ ] }),
90
+ /* @__PURE__ */ t("div", { className: "bw-flex bw-items-center bw-gap-x-1", children: [
91
+ /* @__PURE__ */ b(de, { fill: "var(--tw-text-secondary)" }),
92
+ /* @__PURE__ */ b("p", { className: "bw-text-sm bw-font-medium bw-text-text-secondary", children: (e == null ? void 0 : e.estimatedTimeInSeconds) >= 90 ? `${Math.round(te(((e == null ? void 0 : e.estimatedTimeInSeconds) || 60) / 60, 2) || 0)}min` : `${(e == null ? void 0 : e.estimatedTimeInSeconds) || 60} secs` })
93
+ ] }),
94
+ /* @__PURE__ */ t("div", { className: " bw-gap-x-1 bw-flex bw-items-center bw-text-xs bw-font-normal bw-text-text-primary", children: [
95
+ /* @__PURE__ */ b(me, { fill: "var(--tw-text-secondary)" }),
96
+ /* @__PURE__ */ b("p", { className: "bw-text-sm bw-font-medium bw-text-text-secondary", children: `${((W = e == null ? void 0 : e.steps) == null ? void 0 : W.length) || ""} step` })
97
+ ] })
98
+ ] }) })
99
+ ] })
100
+ ] }) : y ? /* @__PURE__ */ b("div", { className: "bw-bg-background-container bw-text-text-secondary bw-justify-center bw-items-center bw-h-[80px] bw-relative bw-flex bw-flex-col bw-border bw-border-border-primary", children: "Failed to load routes" }) : /* @__PURE__ */ b(m, {}) : /* @__PURE__ */ b(m, {}) });
101
+ }
102
+ export {
103
+ Se as default
104
+ };
@@ -1,6 +1,6 @@
1
1
  import { jsxs as o, jsx as a, Fragment as m } from "react/jsx-runtime";
2
2
  import { s as l } from "./WidgetForm.module-QHJ0-m5f.js";
3
- import { u as g } from "./index-B1aDjOsb.js";
3
+ import { u as g } from "./index-aVpPjW18.js";
4
4
  function y({ routesData: x, routes: e, quoteTimer: n, amount: c }) {
5
5
  var s, b, d, w;
6
6
  const r = g((i) => i.configuration), t = g((i) => i.gradient);
@@ -1,5 +1,5 @@
1
1
  import { jsxs as s, jsx as t } from "react/jsx-runtime";
2
- import { u as a } from "./index-B1aDjOsb.js";
2
+ import { u as a } from "./index-aVpPjW18.js";
3
3
  function w({ fill1: o, fill2: r }) {
4
4
  return /* @__PURE__ */ s(
5
5
  "svg",
@@ -1,8 +1,8 @@
1
- import { b as go, g as To, i as yo, _ as vo, p as B, d as n, e as D, s as Q, f as Ve, h as Po, j as ze, P as e } from "./index-B1aDjOsb.js";
1
+ import { b as go, g as To, i as yo, _ as vo, p as B, d as n, e as D, s as Q, f as Ve, h as Po, j as ze, P as e } from "./index-aVpPjW18.js";
2
2
  import * as p from "react";
3
- import { G as Be, b as wo, u as Ro, a as Co, P as He } from "./Grow-BmLMXGpF.js";
3
+ import { G as Be, b as wo, u as Ro, a as Co, P as He } from "./Grow-Uh43i8On.js";
4
4
  import { jsx as j, jsxs as Se } from "react/jsx-runtime";
5
- import { j as xo, q as I, l as Ue, s as Oo, b as Eo, n as Mo, D as A, E as _o, w as No } from "./useRegisterError-B1UKihdk.js";
5
+ import { j as xo, q as I, l as Ue, s as Oo, b as Eo, n as Mo, D as A, E as _o, w as No } from "./useRegisterError-CoZkPgOD.js";
6
6
  function Lo(r) {
7
7
  return To("MuiTooltip", r);
8
8
  }
@@ -231,7 +231,8 @@ const ko = /* @__PURE__ */ p.forwardRef(function(t, s) {
231
231
  current: o
232
232
  } = p.useRef(Pe !== void 0);
233
233
  p.useEffect(() => {
234
- l && l.disabled && !o && m !== "" && l.tagName.toLowerCase();
234
+ l && l.disabled && !o && m !== "" && l.tagName.toLowerCase() === "button" && console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.", "A disabled element does not fire events.", "Tooltip needs to listen to the child element's events to display the title.", "", "Add a simple wrapper element, such as a `span`."].join(`
235
+ `));
235
236
  }, [m, l, o]);
236
237
  }
237
238
  const q = Co(Je), T = p.useRef(), N = Ue(() => {
@@ -309,10 +310,12 @@ const ko = /* @__PURE__ */ p.forwardRef(function(t, s) {
309
310
  onMouseMove: co
310
311
  } : {});
311
312
  B.env.NODE_ENV !== "production" && (a["data-mui-internal-clone-element"] = !0, p.useEffect(() => {
312
- l && l.getAttribute("data-mui-internal-clone-element");
313
+ l && !l.getAttribute("data-mui-internal-clone-element") && console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.", "Please make sure that props are spread on the same element that the ref is applied to."].join(`
314
+ `));
313
315
  }, [l]));
314
316
  const v = {};
315
- Ke || (a.onTouchStart = io, a.onTouchEnd = lo), he || (a.onMouseOver = k($, a.onMouseOver), a.onMouseLeave = k(G, a.onMouseLeave), H || (v.onMouseOver = $, v.onMouseLeave = G)), qe || (a.onFocus = k(De, a.onFocus), a.onBlur = k($e, a.onBlur), H || (v.onFocus = De, v.onBlur = $e)), B.env.NODE_ENV !== "production" && c.props.title;
317
+ Ke || (a.onTouchStart = io, a.onTouchEnd = lo), he || (a.onMouseOver = k($, a.onMouseOver), a.onMouseLeave = k(G, a.onMouseLeave), H || (v.onMouseOver = $, v.onMouseLeave = G)), qe || (a.onFocus = k(De, a.onFocus), a.onBlur = k($e, a.onBlur), H || (v.onFocus = De, v.onBlur = $e)), B.env.NODE_ENV !== "production" && c.props.title && console.error(["MUI: You have provided a `title` prop to the child of <Tooltip />.", `Remove this title prop \`${c.props.title}\` or the Tooltip component.`].join(`
318
+ `));
316
319
  const uo = p.useMemo(() => {
317
320
  var o;
318
321
  let i = [{
@@ -1,41 +1,41 @@
1
1
  import { jsx as G } from "react/jsx-runtime";
2
2
  import { useState as v, useEffect as z } from "react";
3
3
  import { useDynamicContext as xe, useSwitchNetwork as Me, useIsLoggedIn as Oe } from "@dynamic-labs/sdk-react-core";
4
- import { a as _, u as h, aA as Re, aB as pe } from "./index-B1aDjOsb.js";
4
+ import { a as _, u as N, aB as Re, aC as ge } from "./index-aVpPjW18.js";
5
5
  import { s as S } from "./WidgetForm.module-QHJ0-m5f.js";
6
6
  import { useAccount as Ve, useConfig as qe, useSwitchChain as Pe, useBalance as _e } from "wagmi";
7
- import { u as ge, d as Qe, c as He, C as ye } from "./useRegisterError-B1UKihdk.js";
7
+ import { u as pe, d as Qe, c as He, C as ye } from "./useRegisterError-CoZkPgOD.js";
8
8
  import { v as Je } from "./validError-CDlJpg_f.js";
9
- import { u as Ke, g as Ue, p as Xe } from "./index-CsUXwhXc.js";
9
+ import { u as Ke, g as Ue, p as Xe } from "./index-BiNu6NEt.js";
10
10
  function Ye(n) {
11
- const { wallet: u, address: l } = _(), [N, B] = v(0);
11
+ const { wallet: g, address: a } = _(), [h, B] = v(0);
12
12
  async function x() {
13
- const F = await window.tronWeb.trx.getBalance(l);
13
+ const F = await window.tronWeb.trx.getBalance(a);
14
14
  B(F / Math.pow(10, 6));
15
15
  }
16
16
  return z(() => {
17
- l && (n == null ? void 0 : n.networkType) === "tron" && x();
18
- }, [l, n == null ? void 0 : n.networkType]), { tronBal: N };
17
+ a && (n == null ? void 0 : n.networkType) === "tron" && x();
18
+ }, [a, n == null ? void 0 : n.networkType]), { tronBal: h };
19
19
  }
20
20
  function A(n) {
21
- if (n.key.toLowerCase() === "backpacksol")
21
+ if (console.log(n, "primary wallet"), n.key.toLowerCase() === "backpacksol")
22
22
  return !0;
23
23
  }
24
24
  function Ze() {
25
- const [n, u] = v(0), l = h((x) => x.fromChain), { primaryWallet: N } = xe();
25
+ const [n, g] = v(0), a = N((x) => x.fromChain), { primaryWallet: h } = xe();
26
26
  async function B() {
27
- let x = await N.getBalance();
28
- u(Number(x) || 0);
27
+ let x = await h.getBalance();
28
+ g(Number(x) || 0);
29
29
  }
30
30
  return z(() => {
31
- (l.networkType === "btc" || l.networkType === "sui") && B();
32
- }, [l.networkType, N]), n;
31
+ (a.networkType === "btc" || a.networkType === "sui") && B();
32
+ }, [a.networkType, h]), n;
33
33
  }
34
- function lt({ routesData: n, routes: u, amount: l, isAmountTyped: N, handleShowWallet: B, setConnectWalletField: x, handleConfirmClose: F, balanceSol: L, getCoinBalance: Te, handleSuccess: Q }) {
34
+ function lt({ routesData: n, routes: g, amount: a, isAmountTyped: h, handleShowWallet: B, setConnectWalletField: x, handleConfirmClose: F, balanceSol: L, getCoinBalance: Te, handleSuccess: Q }) {
35
35
  var C, ee, te, se, re, ce, ne, ie, de, ae, le, oe, we;
36
- const w = h((s) => s.gradient), I = h((s) => s.configuration), e = h((s) => s.fromChain), i = h((s) => s.fromCoin), r = h((s) => s.toChain), b = h((s) => s.toCoin), { isConnected: j, address: H, chain: m } = Ve(), { address: J, isConnected: We } = _(), Ie = qe(), me = Me(), { getBothWalletConnection: he, getConnectWallet: Ne } = ge({
36
+ const w = N((s) => s.gradient), I = N((s) => s.configuration), e = N((s) => s.fromChain), i = N((s) => s.fromCoin), r = N((s) => s.toChain), b = N((s) => s.toCoin), { isConnected: j, address: H, chain: m } = Ve(), { address: J, isConnected: We } = _(), Ie = qe(), me = Me(), { getBothWalletConnection: Ne, getConnectWallet: he } = pe({
37
37
  chainData: e
38
- }), { connected: K, address: U, disconnect: De } = _(), M = h((s) => s.toDisconnect), d = h((s) => s.customWallet), { getWallet: Be } = ge({ chainData: e }), fe = Ne(e, r), [O, Ge] = v("101"), { tronBal: R } = Ye(e), { cosmosBalance: X } = Ke(), Y = Ze(), V = ((C = e.chain) == null ? void 0 : C.length) && ((ee = r.chain) == null ? void 0 : ee.length), q = ((te = i.address) == null ? void 0 : te.length) && ((se = b.address) == null ? void 0 : se.length), Se = Qe(), Z = Re(), { switchChain: ke, switchChainAsync: $e, isPending: Ee } = Pe({
38
+ }), { connected: K, address: U, disconnect: De } = _(), M = N((s) => s.toDisconnect), d = N((s) => s.customWallet), { getWallet: Be } = pe({ chainData: e }), fe = he(e, r), [O, Ge] = v("101"), { tronBal: R } = Ye(e), { cosmosBalance: X } = Ke(), Y = Ze(), V = ((C = e.chain) == null ? void 0 : C.length) && ((ee = r.chain) == null ? void 0 : ee.length), q = ((te = i.address) == null ? void 0 : te.length) && ((se = b.address) == null ? void 0 : se.length), Se = Qe(), Z = Re(), { switchChain: ke, switchChainAsync: Ee, isPending: $e } = Pe({
39
39
  chainId: Number((e == null ? void 0 : e.chainId) || "0"),
40
40
  config: Ie,
41
41
  throwForSwitchChainNotSupported: !0,
@@ -47,7 +47,7 @@ function lt({ routesData: n, routes: u, amount: l, isAmountTyped: N, handleShowW
47
47
  token: "",
48
48
  chainId: Number((e == null ? void 0 : e.chainId) || 0),
49
49
  enabled: (e == null ? void 0 : e.networkType) == "evm"
50
- }), W = He(Te || 0, 11), [o, a] = v({
50
+ }), W = He(Te || 0, 11), [o, l] = v({
51
51
  text: "",
52
52
  isGradient: !1,
53
53
  color: "bw-bg-border-primary"
@@ -55,27 +55,30 @@ function lt({ routesData: n, routes: u, amount: l, isAmountTyped: N, handleShowW
55
55
  async function Fe() {
56
56
  if ((e == null ? void 0 : e.networkType) === "evm" && Number((e == null ? void 0 : e.chainId) || "0") !== (m == null ? void 0 : m.id))
57
57
  try {
58
- await $e({ chainId: Number((e == null ? void 0 : e.chainId) || "0") });
59
- } catch {
58
+ await Ee({ chainId: Number((e == null ? void 0 : e.chainId) || "0") });
59
+ } catch (s) {
60
+ console.log(s, "err");
60
61
  }
61
62
  else if ((e == null ? void 0 : e.networkType) === "sol" && O !== ((e == null ? void 0 : e.chainId) == "eclipse-svm" ? "201" : "101"))
62
63
  try {
63
64
  let s = await me({ wallet: p, network: e.chainId == "eclipse-svm" ? "201" : "101" });
64
65
  D();
65
- } catch {
66
+ } catch (s) {
67
+ console.log(s, "err");
66
68
  }
67
- else (e == null ? void 0 : e.networkType) === "sui" ? (Z.emit(pe.TransactionStarted, {
69
+ else (e == null ? void 0 : e.networkType) === "sui" ? (Z.emit(ge.TransactionStarted, {
68
70
  ...n
69
- }), f && (Q(!1), F())) : (Z.emit(pe.TransactionStarted, {
71
+ }), f && (Q(!1), F())) : (Z.emit(ge.TransactionStarted, {
70
72
  ...n
71
73
  }), f && (Q(!1), F()));
72
74
  }
73
- const { primaryWallet: p } = xe(), P = Oe(), f = (e == null ? void 0 : e.networkType) === r.networkType ? !!((ce = (re = Be(e)) == null ? void 0 : re.address) != null && ce.length) : he(e == null ? void 0 : e.networkType, (d == null ? void 0 : d.length) > 30 ? "customWallet" : r == null ? void 0 : r.networkType), D = async () => {
75
+ const { primaryWallet: p } = xe(), P = Oe(), f = (e == null ? void 0 : e.networkType) === r.networkType ? !!((ce = (re = Be(e)) == null ? void 0 : re.address) != null && ce.length) : Ne(e == null ? void 0 : e.networkType, (d == null ? void 0 : d.length) > 30 ? "customWallet" : r == null ? void 0 : r.networkType), D = async () => {
74
76
  if (p)
75
77
  try {
76
78
  const s = await p.getNetwork();
77
- Ge(s);
78
- } catch {
79
+ console.log("Current network:", s), Ge(s);
80
+ } catch (s) {
81
+ console.error("Error getting network:", s);
79
82
  }
80
83
  else
81
84
  return;
@@ -83,67 +86,67 @@ function lt({ routesData: n, routes: u, amount: l, isAmountTyped: N, handleShowW
83
86
  z(() => {
84
87
  D();
85
88
  }, [p]);
86
- function k(s, g) {
87
- let y = s / Math.pow(10, g);
88
- return y < 1e-6 ? y.toFixed(20) : y;
89
+ function k(s, y) {
90
+ let u = s / Math.pow(10, y);
91
+ return u < 1e-6 ? u.toFixed(20) : u;
89
92
  }
90
93
  function Le() {
91
94
  var s;
92
95
  return Number(((s = T == null ? void 0 : T.data) == null ? void 0 : s.formatted) || 0);
93
96
  }
94
97
  function je(s) {
95
- var g;
96
- return Number(((g = X[Xe(s.address)]) == null ? void 0 : g.amount) || 0) / Math.pow(10, s.decimals);
98
+ var y;
99
+ return Number(((y = X[Xe(s.address)]) == null ? void 0 : y.amount) || 0) / Math.pow(10, s.decimals);
97
100
  }
98
101
  function Ae() {
99
- var E;
102
+ var $;
100
103
  let s = {};
101
- async function g(t, c) {
102
- let $ = Object.keys(s);
104
+ async function y(t, c) {
105
+ let E = Object.keys(s);
103
106
  s[t == null ? void 0 : t.chainId] ? (s[t == null ? void 0 : t.chainId].amountInToken += c.amountInToken, s[t == null ? void 0 : t.chainId].gas += k(c.amountInToken, t == null ? void 0 : t.decimals)) : s[t == null ? void 0 : t.chainId] = {
104
107
  amountInToken: c.amountInToken,
105
108
  gas: k(c.amountInToken, t == null ? void 0 : t.decimals),
106
109
  token: t,
107
110
  nativeBal: (d == null ? void 0 : d.length) > 30 && !M && (t == null ? void 0 : t.chainId) == (r == null ? void 0 : r.chainId) && (r == null ? void 0 : r.chainId) !== (e == null ? void 0 : e.chainId) ? 0 : (t == null ? void 0 : t.networkType) == "sol" ? L : (t == null ? void 0 : t.networkType) == "tron" ? R : (t == null ? void 0 : t.networkType) == "btc" || (t == null ? void 0 : t.networkType) == "sui" ? Y : (t == null ? void 0 : t.networkType) == "cosmos" ? je(t) : (t == null ? void 0 : t.networkType) == "tron" ? Ue(J) : Le(),
108
111
  isFromChain: (e == null ? void 0 : e.chainId) === (t == null ? void 0 : t.chainId.toString()),
109
- order: (e == null ? void 0 : e.chainId) === (t == null ? void 0 : t.chainId) ? 1 : (r == null ? void 0 : r.chainId) === (t == null ? void 0 : t.chainId) ? 2 : $.length > 2 ? 3 : 2
112
+ order: (e == null ? void 0 : e.chainId) === (t == null ? void 0 : t.chainId) ? 1 : (r == null ? void 0 : r.chainId) === (t == null ? void 0 : t.chainId) ? 2 : E.length > 2 ? 3 : 2
110
113
  };
111
114
  }
112
- (E = n == null ? void 0 : n.fee) == null || E.forEach((t) => {
115
+ ($ = n == null ? void 0 : n.fee) == null || $.forEach((t) => {
113
116
  const { token: c } = t;
114
- t.source.toLowerCase() == "from_source_wallet" && g(c, t);
117
+ t.source.toLowerCase() == "from_source_wallet" && y(c, t);
115
118
  });
116
- let y = W;
117
- if (Number(l) > Number(y))
118
- a({
119
+ let u = W;
120
+ if (console.log(Number(u), Number(a), s, "coinBalance"), Number(a) > Number(u))
121
+ l({
119
122
  text: `Insufficient Balance ${i.coin || ""}`,
120
123
  isGradient: !1,
121
124
  color: "bw-bg-border-primary"
122
125
  });
123
126
  else if ((T != null && T.isLoading || T.isFetching) && (e == null ? void 0 : e.networkType) === "evm" || (typeof L > "u" || L === null) && (e == null ? void 0 : e.networkType) === "sol" || !R && (e == null ? void 0 : e.networkType) === "tron")
124
- a({
127
+ l({
125
128
  text: "Fetching Balance..",
126
129
  isGradient: !1,
127
130
  color: "bw-bg-border-primary"
128
131
  });
129
132
  else {
130
- let t = Object.values(s).sort((c, $) => c.order - $.order);
133
+ let t = Object.values(s).sort((c, E) => c.order - E.order);
131
134
  t.some((c) => {
132
- var $, be, ue;
133
- return c != null && c.isFromChain && Number(l) <= Number(y) && Number(c.nativeBal) - Number(l) < c.gas && (i != null && i.isNative) || Number(l) <= Number(y) && Number(c.nativeBal) < c.gas && !(i != null && i.isNative) && (c != null && c.isFromChain) ? (a({
134
- text: `Insufficient ${(($ = c == null ? void 0 : c.token) == null ? void 0 : $.symbol) || ""} for gas on ${c.token.blockchain}`,
135
+ var E, be, ue;
136
+ return c != null && c.isFromChain && Number(a) <= Number(u) && Number(c.nativeBal) - Number(a) < c.gas && (i != null && i.isNative) || Number(a) <= Number(u) && Number(c.nativeBal) < c.gas && !(i != null && i.isNative) && (c != null && c.isFromChain) ? (l({
137
+ text: `Insufficient ${((E = c == null ? void 0 : c.token) == null ? void 0 : E.symbol) || ""} for gas on ${c.token.blockchain}`,
135
138
  isGradient: !1,
136
139
  color: "bw-bg-border-primary"
137
- }), !0) : c.nativeBal < c.gas && !((d == null ? void 0 : d.length) > 30 && ((be = c == null ? void 0 : c.token) == null ? void 0 : be.chainId) == (r == null ? void 0 : r.chainId)) ? (a({
140
+ }), !0) : c.nativeBal < c.gas && !((d == null ? void 0 : d.length) > 30 && ((be = c == null ? void 0 : c.token) == null ? void 0 : be.chainId) == (r == null ? void 0 : r.chainId)) ? (l({
138
141
  text: `Insufficient ${((ue = c == null ? void 0 : c.token) == null ? void 0 : ue.symbol) || ""} for gas on ${c.token.blockchain}`,
139
142
  isGradient: !1,
140
143
  color: "bw-bg-border-primary"
141
- }), !0) : (a({
144
+ }), !0) : (l({
142
145
  text: "",
143
146
  isGradient: !0,
144
147
  color: w || S.gradientbutton
145
148
  }), !0);
146
- }), t.length == 0 && (n != null && n.gasless || (n == null ? void 0 : n.provider) == "meson") && a({
149
+ }), t.length == 0 && (n != null && n.gasless || (n == null ? void 0 : n.provider) == "meson") && l({
147
150
  text: "",
148
151
  isGradient: !0,
149
152
  color: w || S.gradientbutton
@@ -151,53 +154,53 @@ function lt({ routesData: n, routes: u, amount: l, isAmountTyped: N, handleShowW
151
154
  }
152
155
  }
153
156
  z(() => {
154
- var s, g, y;
155
- !i.coin.length || !(b != null && b.coin.length) ? a({
157
+ var s, y, u;
158
+ !i.coin.length || !(b != null && b.coin.length) ? l({
156
159
  text: "Select Token",
157
160
  isGradient: !0,
158
161
  color: w || S.gradientbutton
159
- }) : f ? typeof l < "u" && Number(l || 0) <= 0 ? a({
162
+ }) : f ? typeof a < "u" && Number(a || 0) <= 0 ? l({
160
163
  text: "Enter Amount",
161
164
  isGradient: !1,
162
165
  color: "bw-bg-border-primary"
163
- }) : u.isFetching || !N ? a({
166
+ }) : g.isFetching || !h ? l({
164
167
  text: "Loading Routes...",
165
168
  isGradient: !1,
166
169
  color: "bw-bg-border-primary"
167
- }) : e.chainId === "eclipse-svm" && !A(p) ? a({
170
+ }) : e.chainId === "eclipse-svm" && !A(p) ? l({
168
171
  text: `Select ${e.name} wallet`,
169
172
  isGradient: !0,
170
173
  color: w || S.gradientbutton
171
- }) : r.chainId === "eclipse-svm" && e.chainId !== "eclipse-svm" && !A(p) && d.length < 30 ? a({
174
+ }) : r.chainId === "eclipse-svm" && e.chainId !== "eclipse-svm" && !A(p) && d.length < 30 ? l({
172
175
  text: "Enter recipient wallet address",
173
176
  isGradient: !0,
174
177
  color: w || S.gradientbutton
175
- }) : (i == null ? void 0 : i.address) === (b == null ? void 0 : b.address) && (e == null ? void 0 : e.chainId) === (r == null ? void 0 : r.chainId) && !(d != null && d.length) || (e == null ? void 0 : e.networkType) === "evm" && H === d && (i == null ? void 0 : i.address) === (b == null ? void 0 : b.address) && (e == null ? void 0 : e.chainId) === (r == null ? void 0 : r.chainId) || (e == null ? void 0 : e.networkType) === "sol" && (p == null ? void 0 : p.address) === d && (i == null ? void 0 : i.address) === (b == null ? void 0 : b.address) && (e == null ? void 0 : e.chainId) === (r == null ? void 0 : r.chainId) ? a({
178
+ }) : (i == null ? void 0 : i.address) === (b == null ? void 0 : b.address) && (e == null ? void 0 : e.chainId) === (r == null ? void 0 : r.chainId) && !(d != null && d.length) || (e == null ? void 0 : e.networkType) === "evm" && H === d && (i == null ? void 0 : i.address) === (b == null ? void 0 : b.address) && (e == null ? void 0 : e.chainId) === (r == null ? void 0 : r.chainId) || (e == null ? void 0 : e.networkType) === "sol" && (p == null ? void 0 : p.address) === d && (i == null ? void 0 : i.address) === (b == null ? void 0 : b.address) && (e == null ? void 0 : e.chainId) === (r == null ? void 0 : r.chainId) ? l({
176
179
  text: "From and To asset can not be the same!",
177
180
  isGradient: !1,
178
181
  color: "bw-bg-border-primary"
179
- }) : (y = (g = (s = u == null ? void 0 : u.data) == null ? void 0 : s.data) == null ? void 0 : g.quotes) != null && y.length ? u != null && u.error ? a({
182
+ }) : (u = (y = (s = g == null ? void 0 : g.data) == null ? void 0 : s.data) == null ? void 0 : y.quotes) != null && u.length ? g != null && g.error ? l({
180
183
  text: "Failed to fetch Quotes",
181
184
  isGradient: !1,
182
185
  color: "bw-bg-border-primary"
183
- }) : j && Number((e == null ? void 0 : e.chainId) || "0") !== (m == null ? void 0 : m.id) && (e == null ? void 0 : e.networkType) === "evm" || P && ((e == null ? void 0 : e.chainId) === "eclipse-svm" ? "201" : "101") !== O && (e == null ? void 0 : e.networkType) === "sol" ? a({
186
+ }) : j && Number((e == null ? void 0 : e.chainId) || "0") !== (m == null ? void 0 : m.id) && (e == null ? void 0 : e.networkType) === "evm" || P && ((e == null ? void 0 : e.chainId) === "eclipse-svm" ? "201" : "101") !== O && (e == null ? void 0 : e.networkType) === "sol" ? l({
184
187
  text: `Switch Chain to ${e.chain}`,
185
188
  isGradient: !0,
186
189
  color: w || S.gradientbutton
187
- }) : Ae() : a({
190
+ }) : Ae() : l({
188
191
  text: "No Routes Found",
189
192
  isGradient: !1,
190
193
  color: "bw-bg-border-primary"
191
- }) : a({
194
+ }) : l({
192
195
  text: "",
193
196
  isGradient: !0,
194
197
  color: w || S.gradientbutton
195
198
  });
196
- }, [O, p, i, b, l, e, r, (ne = T.data) == null ? void 0 : ne.formatted, n, T.isFetching, T.isLoading, j, W, f, u.isFetching, m == null ? void 0 : m.id, N, R, L, d, Y, X, J]);
199
+ }, [O, p, i, b, a, e, r, (ne = T.data) == null ? void 0 : ne.formatted, n, T.isFetching, T.isLoading, j, W, f, g.isFetching, m == null ? void 0 : m.id, h, R, L, d, Y, X, J]);
197
200
  let ve = [`switch chain to ${(ie = e.chain) == null ? void 0 : ie.toLowerCase()}`, `select ${(de = e.chain) == null ? void 0 : de.toLowerCase()} wallet`, "connect custom wallet", "enter recipient wallet address"];
198
201
  function ze() {
199
- var s, g, y, E;
200
- return f ? u.isFetching ? !0 : o.text.length ? !ve.includes((s = o.text) == null ? void 0 : s.toLowerCase()) : !((E = (y = (g = u.data) == null ? void 0 : g.data) == null ? void 0 : y.quotes) != null && E.length) : !1;
202
+ var s, y, u, $;
203
+ return f ? g.isFetching ? !0 : o.text.length ? !ve.includes((s = o.text) == null ? void 0 : s.toLowerCase()) : !(($ = (u = (y = g.data) == null ? void 0 : y.data) == null ? void 0 : u.quotes) != null && $.length) : !1;
201
204
  }
202
205
  return /* @__PURE__ */ G(
203
206
  "button",
@@ -213,7 +216,7 @@ function lt({ routesData: n, routes: u, amount: l, isAmountTyped: N, handleShowW
213
216
  onClick: () => {
214
217
  f || (B(!0), ((e == null ? void 0 : e.networkType) !== "evm" && j || (e == null ? void 0 : e.networkType) !== "sol" && P && p !== null || (e == null ? void 0 : e.networkType) !== "tron" && K && U) && !M ? x("from") : j && (r == null ? void 0 : r.networkType) !== "evm" || P && (r == null ? void 0 : r.networkType) !== "sol" || (r == null ? void 0 : r.networkType) !== "tron" && K && U || M ? x("to") : x("from")), e.chainId === "eclipse-svm" && !A(p) ? (B(!0), x("from")) : r.chainId === "eclipse-svm" && e.chainId !== "eclipse-svm" && !A(p) && d.length < 30 ? (B(!0), x("to")) : Fe();
215
218
  },
216
- children: /* @__PURE__ */ G("div", { className: "bw-rounded-sm bw-bg-background-container bw-flex bw-items-center bw-justify-center b-w-full bw-h-full", children: /* @__PURE__ */ G("p", { className: "bw-relative bw-z-20", children: V && q ? Ee ? /* @__PURE__ */ G("div", { className: "bw-w-[30px] bw-flex bw-text-text-secondary bw-justify-center bw-items-center bw-h-[30px]", children: /* @__PURE__ */ G(ye, { size: 22, thickness: 5, color: "inherit" }) }) : f ? o.text.length ? o.text : "Start Transaction" : `Connect ${fe} Wallet` : /* @__PURE__ */ G("div", { className: "bw-w-[30px] bw-flex bw-text-text-secondary bw-justify-center bw-items-center bw-h-[30px]", children: /* @__PURE__ */ G(ye, { size: 22, thickness: 5, color: "inherit" }) }) }) })
219
+ children: /* @__PURE__ */ G("div", { className: "bw-rounded-sm bw-bg-background-container bw-flex bw-items-center bw-justify-center b-w-full bw-h-full", children: /* @__PURE__ */ G("p", { className: "bw-relative bw-z-20", children: V && q ? $e ? /* @__PURE__ */ G("div", { className: "bw-w-[30px] bw-flex bw-text-text-secondary bw-justify-center bw-items-center bw-h-[30px]", children: /* @__PURE__ */ G(ye, { size: 22, thickness: 5, color: "inherit" }) }) : f ? o.text.length ? o.text : "Start Transaction" : `Connect ${fe} Wallet` : /* @__PURE__ */ G("div", { className: "bw-w-[30px] bw-flex bw-text-text-secondary bw-justify-center bw-items-center bw-h-[30px]", children: /* @__PURE__ */ G(ye, { size: 22, thickness: 5, color: "inherit" }) }) }) })
217
220
  }
218
221
  );
219
222
  }
@@ -1,4 +1,4 @@
1
- import { m as l } from "./core-CIqAJqfO.js";
1
+ import { m as l } from "./core-d7L-Vu90.js";
2
2
  const o = l`<svg
3
3
  width="14"
4
4
  height="14"
@@ -1,4 +1,4 @@
1
- import { m as a } from "./core-CIqAJqfO.js";
1
+ import { m as a } from "./core-d7L-Vu90.js";
2
2
  const o = a`<svg fill="none" viewBox="0 0 24 24">
3
3
  <path
4
4
  style="fill: var(--wui-color-accent-100);"
@@ -1,4 +1,4 @@
1
- import { m as a } from "./core-CIqAJqfO.js";
1
+ import { m as a } from "./core-d7L-Vu90.js";
2
2
  const e = a`
3
3
  <svg width="36" height="36">
4
4
  <path
@@ -1,4 +1,4 @@
1
- import { m as l } from "./core-CIqAJqfO.js";
1
+ import { m as l } from "./core-d7L-Vu90.js";
2
2
  const f = l`<svg fill="none" viewBox="0 0 40 40">
3
3
  <g clip-path="url(#a)">
4
4
  <g clip-path="url(#b)">
@@ -1,4 +1,4 @@
1
- import { m as o } from "./core-CIqAJqfO.js";
1
+ import { m as o } from "./core-d7L-Vu90.js";
2
2
  const e = o`<svg fill="none" viewBox="0 0 14 15">
3
3
  <path
4
4
  fill="currentColor"
@@ -1,4 +1,4 @@
1
- import { m as C } from "./core-CIqAJqfO.js";
1
+ import { m as C } from "./core-d7L-Vu90.js";
2
2
  const e = C`<svg
3
3
  fill="none"
4
4
  viewBox="0 0 21 20"
@@ -1,4 +1,4 @@
1
- import { m as e } from "./core-CIqAJqfO.js";
1
+ import { m as e } from "./core-d7L-Vu90.js";
2
2
  const o = e`<svg fill="none" viewBox="0 0 14 15">
3
3
  <path
4
4
  fill="currentColor"
@@ -1,4 +1,4 @@
1
- import { m as l } from "./core-CIqAJqfO.js";
1
+ import { m as l } from "./core-d7L-Vu90.js";
2
2
  const e = l`<svg fill="none" viewBox="0 0 14 15">
3
3
  <path
4
4
  fill="currentColor"
@@ -1,4 +1,4 @@
1
- import { m as o } from "./core-CIqAJqfO.js";
1
+ import { m as o } from "./core-d7L-Vu90.js";
2
2
  const e = o`<svg fill="none" viewBox="0 0 14 15">
3
3
  <path
4
4
  fill="currentColor"
@@ -1,4 +1,4 @@
1
- import { m as e } from "./core-CIqAJqfO.js";
1
+ import { m as e } from "./core-d7L-Vu90.js";
2
2
  const o = e`<svg
3
3
  xmlns="http://www.w3.org/2000/svg"
4
4
  width="12"
@@ -1,6 +1,6 @@
1
- import { i as D, e as G, r as q, a as A, x as c, C as U, A as M, O as tt, b as z, E as et, R as O, c as Ut, d as K, f as N, S as pe, g as Cn, W as fe, h as Ze, j as vi, T as ti, k as Xt, M as on, l as rn, m as Dt, n as yi, o as $n } from "./core-CIqAJqfO.js";
2
- import { n as u, c as B, o as W, r as E, U as ht, e as Rn, f as En, a as In } from "./index-Qlxj5hfD.js";
3
- import { n as Wn } from "./index-B1aDjOsb.js";
1
+ import { i as D, e as G, r as q, a as A, x as c, C as U, A as M, O as tt, b as z, E as et, R as O, c as Ut, d as K, f as N, S as pe, g as Cn, W as fe, h as Ze, j as vi, T as ti, k as Xt, M as on, l as rn, m as Dt, n as yi, o as $n } from "./core-d7L-Vu90.js";
2
+ import { n as u, c as B, o as W, r as E, U as ht, e as Rn, f as En, a as In } from "./index-BFZtIV9K.js";
3
+ import { m as Wn } from "./index-aVpPjW18.js";
4
4
  const Sn = D`
5
5
  :host {
6
6
  position: relative;
@@ -899,7 +899,7 @@ let xt = class extends A {
899
899
  tabIdx=${W(this.tabIdx)}
900
900
  ></w3m-connect-recommended-widget>`;
901
901
  default:
902
- return null;
902
+ return console.warn(`Unknown connector type: ${h}`), null;
903
903
  }
904
904
  });
905
905
  }
@@ -1,4 +1,4 @@
1
- import { m as l } from "./core-CIqAJqfO.js";
1
+ import { m as l } from "./core-d7L-Vu90.js";
2
2
  const a = l`<svg fill="none" viewBox="0 0 20 20">
3
3
  <path
4
4
  fill="currentColor"
@@ -1,4 +1,4 @@
1
- import { m as C } from "./core-CIqAJqfO.js";
1
+ import { m as C } from "./core-d7L-Vu90.js";
2
2
  const l = C`<svg
3
3
  xmlns="http://www.w3.org/2000/svg"
4
4
  width="12"
@@ -1,4 +1,4 @@
1
- import { ad as L, ae as b, af as F, ag as N, ah as P, ai as w, aj as S, ak as E, al as $, am as C, an as I, ao as m, ap as G, aq as R, ar as k, as as y, at as O, au as q, av as T, aw as v, ax as D, ay as A, az as H } from "./index-B1aDjOsb.js";
1
+ import { ae as L, af as b, ag as F, ah as N, ai as P, aj as w, ak as S, al as E, am as $, an as C, ao as I, ap as m, aq as G, ar as A, as as R, at as y, au as O, av as q, aw as T, ax as v, ay as D, az as k, aA as H } from "./index-aVpPjW18.js";
2
2
  const h = "/docs/contract/encodeErrorResult";
3
3
  function x(t) {
4
4
  const { abi: s, errorName: a, args: r } = t;
@@ -72,10 +72,10 @@ function _(t) {
72
72
  });
73
73
  }
74
74
  function z(t, s) {
75
- if (!R(t, { strict: !1 }))
76
- throw new k({ address: t });
77
- if (!R(s, { strict: !1 }))
78
- throw new k({ address: s });
75
+ if (!A(t, { strict: !1 }))
76
+ throw new R({ address: t });
77
+ if (!A(s, { strict: !1 }))
78
+ throw new R({ address: s });
79
79
  return t.toLowerCase() === s.toLowerCase();
80
80
  }
81
81
  class J extends y {
@@ -193,7 +193,7 @@ async function V({ data: t, sender: s, urls: a }) {
193
193
  });
194
194
  let i;
195
195
  if ((e = d.headers.get("Content-Type")) != null && e.startsWith("application/json") ? i = (await d.json()).data : i = await d.text(), !d.ok) {
196
- r = new A({
196
+ r = new k({
197
197
  body: u,
198
198
  details: i != null && i.error ? q(i.error) : d.statusText,
199
199
  headers: d.headers,
@@ -211,7 +211,7 @@ async function V({ data: t, sender: s, urls: a }) {
211
211
  }
212
212
  return i;
213
213
  } catch (d) {
214
- r = new A({
214
+ r = new k({
215
215
  body: u,
216
216
  details: d.message,
217
217
  url: n