@rash2x/bridge-widget 0.6.74 → 0.6.76
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/dist/evaa-bridge.cjs +1 -1
- package/dist/evaa-bridge.mjs +1 -1
- package/dist/{index-BXuhMmPg.cjs → index-D7rILjYR.cjs} +191 -212
- package/dist/index-D7rILjYR.cjs.map +1 -0
- package/dist/{index-ByJYFgBm.js → index-DGTEYGjh.js} +2 -2
- package/dist/{index-ByJYFgBm.js.map → index-DGTEYGjh.js.map} +1 -1
- package/dist/{index-8QY4DTwO.cjs → index-UP2rtmG0.cjs} +2 -2
- package/dist/{index-8QY4DTwO.cjs.map → index-UP2rtmG0.cjs.map} +1 -1
- package/dist/{index-CmwUxIdY.js → index-yABy9lq6.js} +191 -212
- package/dist/index-yABy9lq6.js.map +1 -0
- package/dist/styles.css +1 -1
- package/package.json +1 -1
- package/dist/index-BXuhMmPg.cjs.map +0 -1
- package/dist/index-CmwUxIdY.js.map +0 -1
package/dist/evaa-bridge.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
-
const index = require("./index-
|
|
3
|
+
const index = require("./index-D7rILjYR.cjs");
|
|
4
4
|
exports.DEFAULT_SLIPPAGE_BPS = index.DEFAULT_SLIPPAGE_BPS;
|
|
5
5
|
exports.EvaaBridge = index.EvaaBridge;
|
|
6
6
|
exports.RoutePriority = index.RoutePriority;
|
package/dist/evaa-bridge.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { L, d, f, e, D, Q, H, z, W, U, w, s, v, r, p, q, G, Z, a5, $, a2, x, A, y, a0, B, _, a3, a4, S, a1, P, I, V, Y, a6, J, K, X, F, N, t, o, i, u, l, m, j, n, h, k } from "./index-
|
|
1
|
+
import { L, d, f, e, D, Q, H, z, W, U, w, s, v, r, p, q, G, Z, a5, $, a2, x, A, y, a0, B, _, a3, a4, S, a1, P, I, V, Y, a6, J, K, X, F, N, t, o, i, u, l, m, j, n, h, k } from "./index-yABy9lq6.js";
|
|
2
2
|
export {
|
|
3
3
|
L as DEFAULT_SLIPPAGE_BPS,
|
|
4
4
|
d as EvaaBridge,
|
|
@@ -2382,58 +2382,51 @@ const ChainSelectModal = ({
|
|
|
2382
2382
|
chain2.chainKey
|
|
2383
2383
|
);
|
|
2384
2384
|
};
|
|
2385
|
-
return /* @__PURE__ */ jsxRuntime.jsx(dialog.Dialog, { open: isOpen, onOpenChange: (open) => !open && handleClose(), children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2386
|
-
dialog.
|
|
2387
|
-
|
|
2388
|
-
|
|
2389
|
-
|
|
2390
|
-
|
|
2391
|
-
|
|
2392
|
-
|
|
2393
|
-
|
|
2394
|
-
|
|
2395
|
-
|
|
2396
|
-
|
|
2385
|
+
return /* @__PURE__ */ jsxRuntime.jsx(dialog.Dialog, { open: isOpen, onOpenChange: (open) => !open && handleClose(), children: /* @__PURE__ */ jsxRuntime.jsxs(dialog.DialogContent, { className: "md:max-h-[90dvh] md:h-[90dvh] overflow-hidden flex flex-col", children: [
|
|
2386
|
+
/* @__PURE__ */ jsxRuntime.jsx(dialog.DialogHeader, { className: "text-left pb-2", children: /* @__PURE__ */ jsxRuntime.jsx(dialog.DialogTitle, { className: "text-xl leading-8", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-0", children: [
|
|
2387
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { children: t2("bridge.select") }),
|
|
2388
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { children: t2(
|
|
2389
|
+
isSource ? "bridge.sourceNetwork" : "bridge.destinationNetwork"
|
|
2390
|
+
) })
|
|
2391
|
+
] }) }) }),
|
|
2392
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2393
|
+
SearchInput,
|
|
2394
|
+
{
|
|
2395
|
+
placeholder: t2("bridge.search"),
|
|
2396
|
+
value: query,
|
|
2397
|
+
onChange: setQuery,
|
|
2398
|
+
className: "text-foreground placeholder:text-muted-foreground"
|
|
2399
|
+
}
|
|
2400
|
+
),
|
|
2401
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-1 overflow-y-auto [&::-webkit-scrollbar]:w-1 [&::-webkit-scrollbar-track]:bg-transparent [&::-webkit-scrollbar-thumb]:bg-muted-foreground/20 [&::-webkit-scrollbar-thumb]:rounded-full hover:[&::-webkit-scrollbar-thumb]:bg-muted-foreground/30", children: [
|
|
2402
|
+
groupedChains.available.length > 0 && groupedChains.available.map((c2) => renderChainItem(c2, false)),
|
|
2403
|
+
groupedChains.willChangeSrc.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
2397
2404
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2398
|
-
|
|
2405
|
+
"p",
|
|
2399
2406
|
{
|
|
2400
|
-
|
|
2401
|
-
|
|
2402
|
-
onChange: setQuery,
|
|
2403
|
-
className: "text-foreground placeholder:text-muted-foreground"
|
|
2407
|
+
className: `px-5 py-2 leading-4 text-base font-semibold text-muted-foreground uppercase ${groupedChains.available.length > 0 ? "mt-10" : ""}`,
|
|
2408
|
+
children: t2("bridge.willChangeSourceChain")
|
|
2404
2409
|
}
|
|
2405
2410
|
),
|
|
2406
|
-
|
|
2407
|
-
|
|
2408
|
-
|
|
2409
|
-
|
|
2410
|
-
|
|
2411
|
-
|
|
2412
|
-
|
|
2413
|
-
|
|
2414
|
-
|
|
2415
|
-
)
|
|
2416
|
-
|
|
2417
|
-
|
|
2418
|
-
|
|
2419
|
-
|
|
2420
|
-
|
|
2421
|
-
|
|
2422
|
-
|
|
2423
|
-
|
|
2424
|
-
|
|
2425
|
-
children: t2("bridge.willChangeSourceNetworkAndToken")
|
|
2426
|
-
}
|
|
2427
|
-
),
|
|
2428
|
-
groupedChains.willChangeTokenAndSrc.map(
|
|
2429
|
-
(c2) => renderChainItem(c2, false, true)
|
|
2430
|
-
)
|
|
2431
|
-
] }),
|
|
2432
|
-
groupedChains.available.length === 0 && groupedChains.willChangeSrc.length === 0 && groupedChains.willChangeTokenAndSrc.length === 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-sm text-muted-foreground px-12 py-2 h-28 flex items-center justify-center text-center", children: t2("bridge.chainNotFound") })
|
|
2433
|
-
] })
|
|
2434
|
-
]
|
|
2435
|
-
}
|
|
2436
|
-
) });
|
|
2411
|
+
groupedChains.willChangeSrc.map(
|
|
2412
|
+
(c2) => renderChainItem(c2, true, false)
|
|
2413
|
+
)
|
|
2414
|
+
] }),
|
|
2415
|
+
groupedChains.willChangeTokenAndSrc.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
2416
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2417
|
+
"p",
|
|
2418
|
+
{
|
|
2419
|
+
className: `px-5 py-2 leading-4 text-base font-semibold text-muted-foreground uppercase ${groupedChains.available.length > 0 || groupedChains.willChangeSrc.length > 0 ? "mt-10" : ""}`,
|
|
2420
|
+
children: t2("bridge.willChangeSourceNetworkAndToken")
|
|
2421
|
+
}
|
|
2422
|
+
),
|
|
2423
|
+
groupedChains.willChangeTokenAndSrc.map(
|
|
2424
|
+
(c2) => renderChainItem(c2, false, true)
|
|
2425
|
+
)
|
|
2426
|
+
] }),
|
|
2427
|
+
groupedChains.available.length === 0 && groupedChains.willChangeSrc.length === 0 && groupedChains.willChangeTokenAndSrc.length === 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-sm text-muted-foreground px-12 py-2 h-28 flex items-center justify-center text-center", children: t2("bridge.chainNotFound") })
|
|
2428
|
+
] })
|
|
2429
|
+
] }) });
|
|
2437
2430
|
};
|
|
2438
2431
|
const useWalletSelectModal = zustand.create((set2) => ({
|
|
2439
2432
|
isOpen: false,
|
|
@@ -4162,7 +4155,7 @@ const WalletSelectModal = () => {
|
|
|
4162
4155
|
}
|
|
4163
4156
|
return a2.order - b2.order;
|
|
4164
4157
|
});
|
|
4165
|
-
return /* @__PURE__ */ jsxRuntime.jsx(dialog.Dialog, { open: isOpen, onOpenChange: (open) => !open && onClose(), children: /* @__PURE__ */ jsxRuntime.jsxs(dialog.DialogContent, {
|
|
4158
|
+
return /* @__PURE__ */ jsxRuntime.jsx(dialog.Dialog, { open: isOpen, onOpenChange: (open) => !open && onClose(), children: /* @__PURE__ */ jsxRuntime.jsxs(dialog.DialogContent, { children: [
|
|
4166
4159
|
/* @__PURE__ */ jsxRuntime.jsxs(dialog.DialogHeader, { className: "text-left", children: [
|
|
4167
4160
|
/* @__PURE__ */ jsxRuntime.jsx(dialog.DialogTitle, { className: "text-2xl leading-8", children: t2("wallets.chooseWallet") }),
|
|
4168
4161
|
/* @__PURE__ */ jsxRuntime.jsx(dialog.DialogDescription, { children: t2("wallets.oneWalletPerEnv") })
|
|
@@ -4324,7 +4317,7 @@ const FailedStep = ({
|
|
|
4324
4317
|
current.errorParams || {}
|
|
4325
4318
|
) })
|
|
4326
4319
|
] }),
|
|
4327
|
-
/* @__PURE__ */ jsxRuntime.jsx(dialog.DialogFooter, { className: "w-full", children: /* @__PURE__ */ jsxRuntime.jsx(button.Button, { variant: "outline", className: "w-full min-w-40", onClick: reset, children: t2("common.close") }) })
|
|
4320
|
+
/* @__PURE__ */ jsxRuntime.jsx(dialog.DialogFooter, { className: "w-full pt-10", children: /* @__PURE__ */ jsxRuntime.jsx(button.Button, { variant: "outline", className: "w-full min-w-40", onClick: reset, children: t2("common.close") }) })
|
|
4328
4321
|
] });
|
|
4329
4322
|
};
|
|
4330
4323
|
const SuccessStep = ({
|
|
@@ -6498,103 +6491,96 @@ const SettingsModal = ({ isOpen, onClose }) => {
|
|
|
6498
6491
|
);
|
|
6499
6492
|
const activeBtn = "bg-primary hover:bg-primary/80 text-primary-foreground transition-colors";
|
|
6500
6493
|
const notActiveBtn = "bg-accent hover:bg-accent/80 text-accent-foreground transition-colors";
|
|
6501
|
-
return /* @__PURE__ */ jsxRuntime.jsx(dialog.Dialog, { open: isOpen, onOpenChange: (open) => !open && onClose(), children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
6502
|
-
dialog.
|
|
6503
|
-
{
|
|
6504
|
-
|
|
6505
|
-
|
|
6506
|
-
|
|
6507
|
-
|
|
6508
|
-
|
|
6509
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-5", children: [
|
|
6510
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex justify-between items-center", children: [
|
|
6511
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
|
|
6512
|
-
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground text-sm font-medium leading-4", children: t2("settings.gasOnDestination") }),
|
|
6513
|
-
/* @__PURE__ */ jsxRuntime.jsx(Tip, { text: t2("settings.gasOnDestinationDescription"), children: /* @__PURE__ */ jsxRuntime.jsx(InfoIcon, { className: "w-4 h-4 text-muted-foreground" }) })
|
|
6514
|
-
] }),
|
|
6515
|
-
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-foreground text-sm font-medium leading-4", children: formatUsd(gasUsdValue) })
|
|
6516
|
-
] }),
|
|
6517
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between gap-3", children: [
|
|
6518
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center w-1/3 gap-2 shrink-0", children: [
|
|
6519
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
6520
|
-
TokenSymbol,
|
|
6521
|
-
{
|
|
6522
|
-
symbol: dstNativeToken?.symbol || "eth",
|
|
6523
|
-
className: "h-4 w-4 rounded-full",
|
|
6524
|
-
alt: dstNativeToken?.symbol || t2("common.nativeToken", { defaultValue: "Native Token" })
|
|
6525
|
-
}
|
|
6526
|
-
),
|
|
6527
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-2", children: /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-lg text-foreground leading-5 font-semibold h-5", children: gasDisplayAmount % 1 === 0 ? gasDisplayAmount.toFixed(0) : gasDisplayAmount.toFixed(
|
|
6528
|
-
gasDisplayAmount < 1e-3 ? 6 : 3
|
|
6529
|
-
) }) })
|
|
6530
|
-
] }),
|
|
6531
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-2", children: gasPresets.map((g2) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
6532
|
-
badge.Badge,
|
|
6533
|
-
{
|
|
6534
|
-
onClick: () => setGasPreset(g2),
|
|
6535
|
-
className: utils$1.cn(
|
|
6536
|
-
"cursor-pointer h-7 rounded px-2",
|
|
6537
|
-
gasPreset === g2 ? activeBtn : notActiveBtn
|
|
6538
|
-
),
|
|
6539
|
-
children: t2(`settings.gasPresets.${g2}`)
|
|
6540
|
-
},
|
|
6541
|
-
g2
|
|
6542
|
-
)) })
|
|
6543
|
-
] })
|
|
6494
|
+
return /* @__PURE__ */ jsxRuntime.jsx(dialog.Dialog, { open: isOpen, onOpenChange: (open) => !open && onClose(), children: /* @__PURE__ */ jsxRuntime.jsxs(dialog.DialogContent, { onOpenAutoFocus: (e2) => e2.preventDefault(), children: [
|
|
6495
|
+
/* @__PURE__ */ jsxRuntime.jsx(dialog.DialogHeader, { className: "text-left", children: /* @__PURE__ */ jsxRuntime.jsx(dialog.DialogTitle, { className: "text-2xl leading-8", children: t2("settings.title") }) }),
|
|
6496
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-5 flex-1 pt-4", children: [
|
|
6497
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-5", children: [
|
|
6498
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex justify-between items-center", children: [
|
|
6499
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
|
|
6500
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground text-sm font-medium leading-4", children: t2("settings.gasOnDestination") }),
|
|
6501
|
+
/* @__PURE__ */ jsxRuntime.jsx(Tip, { text: t2("settings.gasOnDestinationDescription"), children: /* @__PURE__ */ jsxRuntime.jsx(InfoIcon, { className: "w-4 h-4 text-muted-foreground" }) })
|
|
6544
6502
|
] }),
|
|
6545
|
-
/* @__PURE__ */ jsxRuntime.jsx("
|
|
6546
|
-
|
|
6547
|
-
|
|
6548
|
-
|
|
6549
|
-
|
|
6550
|
-
|
|
6551
|
-
] }),
|
|
6552
|
-
slippageBps >= 500 && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-destructive text-xs font-medium", children: t2("settings.highSlippageWarning", {
|
|
6553
|
-
defaultValue: "High slippage warning"
|
|
6554
|
-
}) })
|
|
6555
|
-
] }),
|
|
6556
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between gap-6", children: [
|
|
6557
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-2", children: /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-lg text-foreground leading-5 font-semibold h-5", children: slippagePercent }) }),
|
|
6558
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-2", children: slippagePresets.map((p2) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
6559
|
-
badge.Badge,
|
|
6560
|
-
{
|
|
6561
|
-
onClick: () => {
|
|
6562
|
-
const bps = parseFloat(p2.replace("%", "")) * 100;
|
|
6563
|
-
setSlippageBps(bps);
|
|
6564
|
-
},
|
|
6565
|
-
className: utils$1.cn(
|
|
6566
|
-
"cursor-pointer h-7 rounded px-2",
|
|
6567
|
-
activeSlippagePreset === p2 ? activeBtn : notActiveBtn
|
|
6568
|
-
),
|
|
6569
|
-
children: p2
|
|
6570
|
-
},
|
|
6571
|
-
p2
|
|
6572
|
-
)) })
|
|
6573
|
-
] })
|
|
6574
|
-
] }),
|
|
6575
|
-
/* @__PURE__ */ jsxRuntime.jsx("hr", {}),
|
|
6576
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-5", children: [
|
|
6577
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex justify-between items-center", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
|
|
6578
|
-
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground text-sm font-medium leading-4", children: t2("settings.routePriority") }),
|
|
6579
|
-
/* @__PURE__ */ jsxRuntime.jsx(Tip, { text: t2("settings.routePriorityDescription"), children: /* @__PURE__ */ jsxRuntime.jsx(InfoIcon, { className: "w-4 h-4 text-muted-foreground" }) })
|
|
6580
|
-
] }) }),
|
|
6581
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center justify-end gap-2", children: routePresets.map((r2) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
6582
|
-
badge.Badge,
|
|
6503
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-foreground text-sm font-medium leading-4", children: formatUsd(gasUsdValue) })
|
|
6504
|
+
] }),
|
|
6505
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between gap-3", children: [
|
|
6506
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 shrink-0", children: [
|
|
6507
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
6508
|
+
TokenSymbol,
|
|
6583
6509
|
{
|
|
6584
|
-
|
|
6585
|
-
className:
|
|
6586
|
-
|
|
6587
|
-
|
|
6588
|
-
|
|
6589
|
-
|
|
6510
|
+
symbol: dstNativeToken?.symbol || "eth",
|
|
6511
|
+
className: "h-4 w-4 rounded-full",
|
|
6512
|
+
alt: dstNativeToken?.symbol || t2("common.nativeToken", { defaultValue: "Native Token" })
|
|
6513
|
+
}
|
|
6514
|
+
),
|
|
6515
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-2", children: /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-lg text-foreground leading-5 font-semibold h-5", children: gasDisplayAmount % 1 === 0 ? gasDisplayAmount.toFixed(0) : gasDisplayAmount.toFixed(
|
|
6516
|
+
gasDisplayAmount < 1e-3 ? 6 : 3
|
|
6517
|
+
) }) })
|
|
6518
|
+
] }),
|
|
6519
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-2", children: gasPresets.map((g2) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
6520
|
+
badge.Badge,
|
|
6521
|
+
{
|
|
6522
|
+
onClick: () => setGasPreset(g2),
|
|
6523
|
+
className: utils$1.cn(
|
|
6524
|
+
"cursor-pointer h-7 rounded px-2",
|
|
6525
|
+
gasPreset === g2 ? activeBtn : notActiveBtn
|
|
6526
|
+
),
|
|
6527
|
+
children: t2(`settings.gasPresets.${g2}`)
|
|
6528
|
+
},
|
|
6529
|
+
g2
|
|
6530
|
+
)) })
|
|
6531
|
+
] })
|
|
6532
|
+
] }),
|
|
6533
|
+
/* @__PURE__ */ jsxRuntime.jsx("hr", {}),
|
|
6534
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-5", children: [
|
|
6535
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex justify-between items-center", children: [
|
|
6536
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
|
|
6537
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground text-sm font-medium leading-4", children: t2("settings.slippageTolerance") }),
|
|
6538
|
+
/* @__PURE__ */ jsxRuntime.jsx(Tip, { text: t2("settings.slippageToleranceDescription"), children: /* @__PURE__ */ jsxRuntime.jsx(InfoIcon, { className: "w-4 h-4 text-muted-foreground" }) })
|
|
6539
|
+
] }),
|
|
6540
|
+
slippageBps >= 500 && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-destructive text-xs font-medium", children: t2("settings.highSlippageWarning", {
|
|
6541
|
+
defaultValue: "High slippage warning"
|
|
6542
|
+
}) })
|
|
6543
|
+
] }),
|
|
6544
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between gap-6", children: [
|
|
6545
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-2", children: /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-lg text-foreground leading-5 font-semibold h-5", children: slippagePercent }) }),
|
|
6546
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-2", children: slippagePresets.map((p2) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
6547
|
+
badge.Badge,
|
|
6548
|
+
{
|
|
6549
|
+
onClick: () => {
|
|
6550
|
+
const bps = parseFloat(p2.replace("%", "")) * 100;
|
|
6551
|
+
setSlippageBps(bps);
|
|
6590
6552
|
},
|
|
6591
|
-
|
|
6592
|
-
|
|
6593
|
-
|
|
6553
|
+
className: utils$1.cn(
|
|
6554
|
+
"cursor-pointer h-7 rounded px-2",
|
|
6555
|
+
activeSlippagePreset === p2 ? activeBtn : notActiveBtn
|
|
6556
|
+
),
|
|
6557
|
+
children: p2
|
|
6558
|
+
},
|
|
6559
|
+
p2
|
|
6560
|
+
)) })
|
|
6594
6561
|
] })
|
|
6595
|
-
]
|
|
6596
|
-
|
|
6597
|
-
|
|
6562
|
+
] }),
|
|
6563
|
+
/* @__PURE__ */ jsxRuntime.jsx("hr", {}),
|
|
6564
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-5", children: [
|
|
6565
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex justify-between items-center", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
|
|
6566
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground text-sm font-medium leading-4", children: t2("settings.routePriority") }),
|
|
6567
|
+
/* @__PURE__ */ jsxRuntime.jsx(Tip, { text: t2("settings.routePriorityDescription"), children: /* @__PURE__ */ jsxRuntime.jsx(InfoIcon, { className: "w-4 h-4 text-muted-foreground" }) })
|
|
6568
|
+
] }) }),
|
|
6569
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center justify-end gap-2", children: routePresets.map((r2) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
6570
|
+
badge.Badge,
|
|
6571
|
+
{
|
|
6572
|
+
onClick: () => setRoutePriority(r2),
|
|
6573
|
+
className: utils$1.cn(
|
|
6574
|
+
"cursor-pointer h-7 rounded px-2",
|
|
6575
|
+
routePriority === r2 ? activeBtn : notActiveBtn
|
|
6576
|
+
),
|
|
6577
|
+
children: t2(`settings.routePresets.${r2}`)
|
|
6578
|
+
},
|
|
6579
|
+
r2
|
|
6580
|
+
)) })
|
|
6581
|
+
] })
|
|
6582
|
+
] })
|
|
6583
|
+
] }) });
|
|
6598
6584
|
};
|
|
6599
6585
|
const TOKEN_ROW_HEIGHT = 52;
|
|
6600
6586
|
const TokenRow = ({
|
|
@@ -6892,74 +6878,67 @@ const TokenSelectModal = ({
|
|
|
6892
6878
|
},
|
|
6893
6879
|
[effectiveTab, virtualItems]
|
|
6894
6880
|
);
|
|
6895
|
-
return /* @__PURE__ */ jsxRuntime.jsx(dialog.Dialog, { open: isOpen, onOpenChange: (open) => !open && handleClose(), children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
6896
|
-
dialog.
|
|
6897
|
-
|
|
6898
|
-
|
|
6899
|
-
|
|
6900
|
-
|
|
6901
|
-
|
|
6902
|
-
|
|
6903
|
-
|
|
6904
|
-
|
|
6905
|
-
|
|
6906
|
-
|
|
6907
|
-
|
|
6908
|
-
|
|
6909
|
-
|
|
6910
|
-
|
|
6911
|
-
|
|
6912
|
-
|
|
6913
|
-
|
|
6914
|
-
|
|
6915
|
-
|
|
6916
|
-
|
|
6917
|
-
|
|
6918
|
-
},
|
|
6919
|
-
size: "sm",
|
|
6920
|
-
className: utils$1.cn(
|
|
6921
|
-
"px-4 h-9 cursor-pointer",
|
|
6922
|
-
effectiveTab !== "my" && "bg-muted hover:bg-accent"
|
|
6923
|
-
),
|
|
6924
|
-
children: t2("bridge.myTokens")
|
|
6925
|
-
}
|
|
6881
|
+
return /* @__PURE__ */ jsxRuntime.jsx(dialog.Dialog, { open: isOpen, onOpenChange: (open) => !open && handleClose(), children: /* @__PURE__ */ jsxRuntime.jsxs(dialog.DialogContent, { className: "md:max-h-[90dvh] md:h-[90dvh] overflow-hidden flex flex-col gap-4", children: [
|
|
6882
|
+
/* @__PURE__ */ jsxRuntime.jsx(dialog.DialogHeader, { className: "text-left pb-2", children: /* @__PURE__ */ jsxRuntime.jsx(dialog.DialogTitle, { className: "text-2xl leading-8", children: t2("bridge.selectToken") }) }),
|
|
6883
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
6884
|
+
SearchInput,
|
|
6885
|
+
{
|
|
6886
|
+
placeholder: t2("bridge.searchToken"),
|
|
6887
|
+
value: query,
|
|
6888
|
+
onChange: setQuery
|
|
6889
|
+
}
|
|
6890
|
+
),
|
|
6891
|
+
hasSourceWallet() && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex gap-2", children: [
|
|
6892
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
6893
|
+
button.Button,
|
|
6894
|
+
{
|
|
6895
|
+
variant: effectiveTab === "my" ? "default" : "ghost",
|
|
6896
|
+
onClick: () => {
|
|
6897
|
+
setTab("my");
|
|
6898
|
+
setManualTabSwitch(true);
|
|
6899
|
+
},
|
|
6900
|
+
size: "sm",
|
|
6901
|
+
className: utils$1.cn(
|
|
6902
|
+
"px-4 h-9 cursor-pointer",
|
|
6903
|
+
effectiveTab !== "my" && "bg-muted hover:bg-accent"
|
|
6926
6904
|
),
|
|
6927
|
-
|
|
6928
|
-
|
|
6929
|
-
|
|
6930
|
-
|
|
6931
|
-
|
|
6932
|
-
|
|
6933
|
-
|
|
6934
|
-
|
|
6935
|
-
|
|
6936
|
-
|
|
6937
|
-
|
|
6938
|
-
|
|
6939
|
-
|
|
6940
|
-
|
|
6941
|
-
|
|
6942
|
-
)
|
|
6943
|
-
|
|
6944
|
-
|
|
6945
|
-
|
|
6946
|
-
|
|
6947
|
-
|
|
6948
|
-
|
|
6949
|
-
|
|
6950
|
-
|
|
6951
|
-
|
|
6952
|
-
|
|
6953
|
-
|
|
6954
|
-
|
|
6955
|
-
|
|
6956
|
-
|
|
6957
|
-
|
|
6958
|
-
|
|
6959
|
-
|
|
6960
|
-
|
|
6961
|
-
|
|
6962
|
-
|
|
6905
|
+
children: t2("bridge.myTokens")
|
|
6906
|
+
}
|
|
6907
|
+
),
|
|
6908
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
6909
|
+
button.Button,
|
|
6910
|
+
{
|
|
6911
|
+
variant: effectiveTab === "all" ? "default" : "ghost",
|
|
6912
|
+
onClick: () => {
|
|
6913
|
+
setTab("all");
|
|
6914
|
+
setManualTabSwitch(true);
|
|
6915
|
+
},
|
|
6916
|
+
size: "sm",
|
|
6917
|
+
className: utils$1.cn(
|
|
6918
|
+
"px-4 h-9 cursor-pointer",
|
|
6919
|
+
effectiveTab !== "all" && "bg-muted hover:bg-accent"
|
|
6920
|
+
),
|
|
6921
|
+
children: t2("bridge.allTokens")
|
|
6922
|
+
}
|
|
6923
|
+
)
|
|
6924
|
+
] }),
|
|
6925
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { id: "token-select-list", className: "flex-1 -mx-5 min-h-0", children: hasNoResults ? /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm text-muted-foreground px-12 py-2 h-28 flex items-center justify-center text-center", children: t2("bridge.tokenNotFound") }) : /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
6926
|
+
effectiveTab === "my" && myTokens.length === 0 && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "leading-4 px-5 text-base text-muted-foreground uppercase py-2", children: t2("bridge.noBalancesFound") }),
|
|
6927
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
6928
|
+
reactWindow.FixedSizeList,
|
|
6929
|
+
{
|
|
6930
|
+
height: listHeight,
|
|
6931
|
+
itemCount: virtualItems.length,
|
|
6932
|
+
itemSize: TOKEN_ROW_HEIGHT,
|
|
6933
|
+
width: "100%",
|
|
6934
|
+
itemKey,
|
|
6935
|
+
className: "[&::-webkit-scrollbar]:w-1 [&::-webkit-scrollbar-track]:bg-transparent [&::-webkit-scrollbar-thumb]:bg-muted-foreground/20 [&::-webkit-scrollbar-thumb]:rounded-full hover:[&::-webkit-scrollbar-thumb]:bg-muted-foreground/30",
|
|
6936
|
+
overscanCount: 5,
|
|
6937
|
+
children: VirtualRow
|
|
6938
|
+
}
|
|
6939
|
+
)
|
|
6940
|
+
] }) })
|
|
6941
|
+
] }) });
|
|
6963
6942
|
};
|
|
6964
6943
|
function useBridgeRefresh() {
|
|
6965
6944
|
const qc = reactQuery.useQueryClient();
|
|
@@ -25778,7 +25757,7 @@ class WalletConnectModal {
|
|
|
25778
25757
|
}
|
|
25779
25758
|
async initUi() {
|
|
25780
25759
|
if (typeof window !== "undefined") {
|
|
25781
|
-
await Promise.resolve().then(() => require("./index-
|
|
25760
|
+
await Promise.resolve().then(() => require("./index-UP2rtmG0.cjs"));
|
|
25782
25761
|
const modal = document.createElement("wcm-modal");
|
|
25783
25762
|
document.body.insertAdjacentElement("beforeend", modal);
|
|
25784
25763
|
OptionsCtrl.setIsUiLoaded(true);
|
|
@@ -26545,4 +26524,4 @@ exports.useSettingsStore = useSettingsStore;
|
|
|
26545
26524
|
exports.useSwapModel = useSwapModel;
|
|
26546
26525
|
exports.useTokensStore = useTokensStore;
|
|
26547
26526
|
exports.useTransactionStore = useTransactionStore;
|
|
26548
|
-
//# sourceMappingURL=index-
|
|
26527
|
+
//# sourceMappingURL=index-D7rILjYR.cjs.map
|