@rhinestone/deposit-modal 0.12.1 → 0.12.2
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/{DepositModalReown-SXAXHYTN.mjs → DepositModalReown-TEC3MEZ4.mjs} +5 -5
- package/dist/{DepositModalReown-CH6FUTCR.cjs → DepositModalReown-VG66OTIU.cjs} +13 -13
- package/dist/{chunk-O4AXBFHU.mjs → chunk-2TPSF77V.mjs} +3 -3
- package/dist/{chunk-65MLWUQD.cjs → chunk-BRYNGLDM.cjs} +24 -24
- package/dist/{chunk-TQWEGW3A.mjs → chunk-FLVLYO64.mjs} +2 -2
- package/dist/{chunk-2K44IE3V.mjs → chunk-FXXUIK4E.mjs} +1 -1
- package/dist/{chunk-TYBMAUGH.cjs → chunk-HL5NUKZW.cjs} +3 -3
- package/dist/{chunk-O2TQLD4I.mjs → chunk-IAGFDSNC.mjs} +1 -1
- package/dist/{chunk-PVWZN66D.mjs → chunk-J46WDSRD.mjs} +1 -1
- package/dist/{chunk-NHGFU3WC.mjs → chunk-JE4R5VA3.mjs} +1 -1
- package/dist/{chunk-DMYA7U53.cjs → chunk-L32UI7LA.cjs} +1 -1
- package/dist/{chunk-2BOEUV6B.cjs → chunk-OIN4CXCP.cjs} +266 -266
- package/dist/{chunk-FKHPVLJY.cjs → chunk-PWLEBV5V.cjs} +66 -66
- package/dist/{chunk-KPWB2JAX.mjs → chunk-SDSKIJC7.mjs} +4 -4
- package/dist/{chunk-UGK4JRK6.cjs → chunk-TM7VGHAG.cjs} +54 -54
- package/dist/{chunk-ZLCY33FQ.cjs → chunk-UQIJU6HV.cjs} +59 -59
- package/dist/claim.cjs +5 -5
- package/dist/claim.mjs +4 -4
- package/dist/constants.cjs +2 -2
- package/dist/constants.d.cts +1 -1
- package/dist/constants.d.ts +1 -1
- package/dist/constants.mjs +1 -1
- package/dist/deposit.cjs +6 -6
- package/dist/deposit.mjs +5 -5
- package/dist/index.cjs +8 -8
- package/dist/index.mjs +7 -7
- package/dist/styles.css +9 -0
- package/dist/withdraw.cjs +5 -5
- package/dist/withdraw.mjs +4 -4
- package/package.json +1 -1
|
@@ -17,10 +17,10 @@
|
|
|
17
17
|
|
|
18
18
|
|
|
19
19
|
|
|
20
|
-
var
|
|
20
|
+
var _chunkPWLEBV5Vcjs = require('./chunk-PWLEBV5V.cjs');
|
|
21
21
|
|
|
22
22
|
|
|
23
|
-
var
|
|
23
|
+
var _chunkHL5NUKZWcjs = require('./chunk-HL5NUKZW.cjs');
|
|
24
24
|
|
|
25
25
|
|
|
26
26
|
|
|
@@ -86,7 +86,7 @@ var _chunkTYBMAUGHcjs = require('./chunk-TYBMAUGH.cjs');
|
|
|
86
86
|
|
|
87
87
|
|
|
88
88
|
|
|
89
|
-
var
|
|
89
|
+
var _chunkBRYNGLDMcjs = require('./chunk-BRYNGLDM.cjs');
|
|
90
90
|
|
|
91
91
|
|
|
92
92
|
|
|
@@ -220,11 +220,11 @@ SegmentedToggle.displayName = "SegmentedToggle";
|
|
|
220
220
|
|
|
221
221
|
function ChainIcon({ chainId, className, loading }) {
|
|
222
222
|
const badge = _chunkO7BCVQ6Lcjs.getChainBadge.call(void 0, chainId);
|
|
223
|
-
const catalogChain =
|
|
223
|
+
const catalogChain = _chunkBRYNGLDMcjs.useCatalogChain.call(void 0, _chunkBRYNGLDMcjs.catalogKeyForChain.call(void 0, chainId));
|
|
224
224
|
const name = _nullishCoalesce(_optionalChain([catalogChain, 'optionalAccess', _2 => _2.name]), () => ( _chunkO7BCVQ6Lcjs.getChainName.call(void 0, chainId)));
|
|
225
225
|
const initial = (_nullishCoalesce(_optionalChain([catalogChain, 'optionalAccess', _3 => _3.name]), () => ( badge.shortLabel))).charAt(0);
|
|
226
226
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
227
|
-
|
|
227
|
+
_chunkBRYNGLDMcjs.CdnIcon,
|
|
228
228
|
{
|
|
229
229
|
src: _nullishCoalesce(_optionalChain([catalogChain, 'optionalAccess', _4 => _4.iconUrl]), () => ( _chunkO7BCVQ6Lcjs.getChainIcon.call(void 0, chainId))),
|
|
230
230
|
alt: name,
|
|
@@ -247,7 +247,7 @@ ChainIcon.displayName = "ChainIcon";
|
|
|
247
247
|
// src/components/ui/WalletBadgeIcons/index.tsx
|
|
248
248
|
|
|
249
249
|
function BadgeImage({ src, alt = "" }) {
|
|
250
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
250
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CdnIcon, { src, alt }) });
|
|
251
251
|
}
|
|
252
252
|
var WALLET_BADGES = ["rabby", "phantom", "walletconnect"];
|
|
253
253
|
function WalletBadgeIcons() {
|
|
@@ -300,7 +300,7 @@ var DAPP_IMPORT_CATALOG = [
|
|
|
300
300
|
// src/components/ui/BrandIcons.tsx
|
|
301
301
|
|
|
302
302
|
function ExchangeBadgeImage({ name }) {
|
|
303
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
303
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CdnIcon, { src: _nullishCoalesce(_chunkPWLEBV5Vcjs.getExchangeLogoSrc.call(void 0, name), () => ( void 0)) });
|
|
304
304
|
}
|
|
305
305
|
var CARD_NETWORKS = ["amex", "visa", "mastercard"];
|
|
306
306
|
function CardNetworkIcons() {
|
|
@@ -308,7 +308,7 @@ function CardNetworkIcons() {
|
|
|
308
308
|
"span",
|
|
309
309
|
{
|
|
310
310
|
className: `rs-card-network rs-card-network--${network}`,
|
|
311
|
-
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
311
|
+
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CdnIcon, { src: _chunkO7BCVQ6Lcjs.cdnIconUrl.call(void 0, "cards", network) })
|
|
312
312
|
},
|
|
313
313
|
network
|
|
314
314
|
)) });
|
|
@@ -327,7 +327,7 @@ function DappBadgeIcons() {
|
|
|
327
327
|
).filter(
|
|
328
328
|
(brand) => Boolean(brand)
|
|
329
329
|
);
|
|
330
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-list-row-meta-icons rs-list-row-meta-icons--exchanges", children: marks.map((brand) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
330
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-list-row-meta-icons rs-list-row-meta-icons--exchanges", children: marks.map((brand) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CdnIcon, { src: brand.iconUrl, alt: brand.label }) }, brand.id)) });
|
|
331
331
|
}
|
|
332
332
|
DappBadgeIcons.displayName = "DappBadgeIcons";
|
|
333
333
|
var DAPP_BADGE_COUNT = DAPP_BADGE_ORDER.length;
|
|
@@ -347,9 +347,9 @@ function balanceSubtitle(status, balanceUsd, fallback) {
|
|
|
347
347
|
return "No balance";
|
|
348
348
|
}
|
|
349
349
|
function fiatIcon(name) {
|
|
350
|
-
if (name === "apple") return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
351
|
-
if (name === "bank") return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
352
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
350
|
+
if (name === "apple") return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.AppleIcon, {});
|
|
351
|
+
if (name === "bank") return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.BankIcon, {});
|
|
352
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CardIcon, {});
|
|
353
353
|
}
|
|
354
354
|
function FiatMethodIcon({ option }) {
|
|
355
355
|
const [remoteFailed, setRemoteFailed] = _react.useState.call(void 0, false);
|
|
@@ -432,20 +432,20 @@ function renderWalletLeading(row) {
|
|
|
432
432
|
}
|
|
433
433
|
);
|
|
434
434
|
}
|
|
435
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
435
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.WalletIcon, {});
|
|
436
436
|
}
|
|
437
|
-
var TRANSFER_CRYPTO_LEADING = /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
438
|
-
var WALLET_LEADING = /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
439
|
-
var EXCHANGE_LEADING = /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
440
|
-
var MIGRATE_ASSETS_LEADING = /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
441
|
-
var SMALL_SPINNER = /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
437
|
+
var TRANSFER_CRYPTO_LEADING = /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.TransferCryptoIcon, {});
|
|
438
|
+
var WALLET_LEADING = /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.WalletIcon, {});
|
|
439
|
+
var EXCHANGE_LEADING = /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.UnplugIcon, {});
|
|
440
|
+
var MIGRATE_ASSETS_LEADING = /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.MigrateAssetsIcon, {});
|
|
441
|
+
var SMALL_SPINNER = /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.Spinner, { className: "rs-spinner--sm" });
|
|
442
442
|
var CONNECT_META = /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
|
|
443
443
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, WalletBadgeIcons, {}),
|
|
444
444
|
"+100"
|
|
445
445
|
] });
|
|
446
446
|
var EXTRA_EXCHANGE_COUNT = Math.max(
|
|
447
447
|
0,
|
|
448
|
-
|
|
448
|
+
_chunkBRYNGLDMcjs.SUPPORTED_CONNECT_EXCHANGE_COUNT - EXCHANGE_BADGE_COUNT
|
|
449
449
|
);
|
|
450
450
|
var EXCHANGE_META = /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
|
|
451
451
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, ExchangeBadgeIcons, {}),
|
|
@@ -503,7 +503,7 @@ function ConnectStep({
|
|
|
503
503
|
if (onSelectTransferCrypto) {
|
|
504
504
|
cryptoRows.push(
|
|
505
505
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
506
|
-
|
|
506
|
+
_chunkHL5NUKZWcjs.ListRow,
|
|
507
507
|
{
|
|
508
508
|
leading: TRANSFER_CRYPTO_LEADING,
|
|
509
509
|
title: "Transfer crypto",
|
|
@@ -524,7 +524,7 @@ function ConnectStep({
|
|
|
524
524
|
);
|
|
525
525
|
cryptoRows.push(
|
|
526
526
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
527
|
-
|
|
527
|
+
_chunkHL5NUKZWcjs.ListRow,
|
|
528
528
|
{
|
|
529
529
|
leading: renderWalletLeading(row),
|
|
530
530
|
title: collapseToExternal ? "External wallet" : row.label,
|
|
@@ -541,7 +541,7 @@ function ConnectStep({
|
|
|
541
541
|
if (!hasReownWallet && handleConnect) {
|
|
542
542
|
cryptoRows.push(
|
|
543
543
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
544
|
-
|
|
544
|
+
_chunkHL5NUKZWcjs.ListRow,
|
|
545
545
|
{
|
|
546
546
|
leading: WALLET_LEADING,
|
|
547
547
|
title: "Connect wallet",
|
|
@@ -556,7 +556,7 @@ function ConnectStep({
|
|
|
556
556
|
if (onSelectFundFromExchange) {
|
|
557
557
|
cryptoRows.push(
|
|
558
558
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
559
|
-
|
|
559
|
+
_chunkHL5NUKZWcjs.ListRow,
|
|
560
560
|
{
|
|
561
561
|
leading: EXCHANGE_LEADING,
|
|
562
562
|
title: "Connect exchange",
|
|
@@ -571,7 +571,7 @@ function ConnectStep({
|
|
|
571
571
|
if (onSelectMigrateAssets) {
|
|
572
572
|
cryptoRows.push(
|
|
573
573
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
574
|
-
|
|
574
|
+
_chunkHL5NUKZWcjs.ListRow,
|
|
575
575
|
{
|
|
576
576
|
leading: MIGRATE_ASSETS_LEADING,
|
|
577
577
|
title: "Migrate assets",
|
|
@@ -592,7 +592,7 @@ function ConnectStep({
|
|
|
592
592
|
for (const opt of fiatPaymentMethods) {
|
|
593
593
|
cashRows.push(
|
|
594
594
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
595
|
-
|
|
595
|
+
_chunkHL5NUKZWcjs.ListRow,
|
|
596
596
|
{
|
|
597
597
|
leading: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, FiatMethodIcon, { option: opt }),
|
|
598
598
|
title: opt.label,
|
|
@@ -607,7 +607,7 @@ function ConnectStep({
|
|
|
607
607
|
} else if (fiatLoading) {
|
|
608
608
|
cashRows.push(
|
|
609
609
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
610
|
-
|
|
610
|
+
_chunkHL5NUKZWcjs.ListRow,
|
|
611
611
|
{
|
|
612
612
|
leading: SMALL_SPINNER,
|
|
613
613
|
title: "Loading payment options\u2026",
|
|
@@ -636,9 +636,9 @@ function ConnectStep({
|
|
|
636
636
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen", children: [
|
|
637
637
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen-body rs-screen-body--gap-32", children: [
|
|
638
638
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
639
|
-
|
|
639
|
+
_chunkBRYNGLDMcjs.BodyHeader,
|
|
640
640
|
{
|
|
641
|
-
icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
641
|
+
icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.HandCoinsIcon, {}),
|
|
642
642
|
title,
|
|
643
643
|
subtitle: _nullishCoalesce(subtitle, () => ( defaultSubtitle)),
|
|
644
644
|
aside: showToggle ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
@@ -674,7 +674,7 @@ function ConnectStep({
|
|
|
674
674
|
children: "Disconnect wallet"
|
|
675
675
|
}
|
|
676
676
|
) }),
|
|
677
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
677
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.PoweredBy, {})
|
|
678
678
|
] });
|
|
679
679
|
}
|
|
680
680
|
ConnectStep.displayName = "ConnectStep";
|
|
@@ -697,17 +697,17 @@ function AssetSelectStep({
|
|
|
697
697
|
const [selectedAssetId, setSelectedAssetId] = _react.useState.call(void 0, null);
|
|
698
698
|
const [loading, setLoading] = _react.useState.call(void 0, true);
|
|
699
699
|
const [error, setError] = _react.useState.call(void 0, null);
|
|
700
|
-
const isDepositChain =
|
|
701
|
-
const { catalog } =
|
|
702
|
-
const chainName =
|
|
700
|
+
const isDepositChain = _chunkBRYNGLDMcjs.useIsDepositChain.call(void 0, );
|
|
701
|
+
const { catalog } = _chunkBRYNGLDMcjs.useChainCatalog.call(void 0, );
|
|
702
|
+
const chainName = _chunkBRYNGLDMcjs.useChainName.call(void 0, );
|
|
703
703
|
const defaultAssetId = _react.useMemo.call(void 0, () => {
|
|
704
704
|
if (!defaultSourceChain || !defaultSourceToken) return null;
|
|
705
|
-
return
|
|
705
|
+
return _chunkBRYNGLDMcjs.getAssetId.call(void 0, {
|
|
706
706
|
chainId: defaultSourceChain,
|
|
707
707
|
token: defaultSourceToken
|
|
708
708
|
});
|
|
709
709
|
}, [defaultSourceChain, defaultSourceToken]);
|
|
710
|
-
const onTotalBalanceComputedRef =
|
|
710
|
+
const onTotalBalanceComputedRef = _chunkBRYNGLDMcjs.useLatestRef.call(void 0, onTotalBalanceComputed);
|
|
711
711
|
_react.useEffect.call(void 0, () => {
|
|
712
712
|
let active = true;
|
|
713
713
|
function emitAssetsUpdate(currentAssets) {
|
|
@@ -727,7 +727,7 @@ function AssetSelectStep({
|
|
|
727
727
|
try {
|
|
728
728
|
const portfolio = await service.fetchPortfolio(address);
|
|
729
729
|
if (!active) return;
|
|
730
|
-
const portfolioAssets =
|
|
730
|
+
const portfolioAssets = _chunkBRYNGLDMcjs.portfolioToAssets.call(void 0, portfolio.tokens);
|
|
731
731
|
setAssets(portfolioAssets);
|
|
732
732
|
emitAssetsUpdate(portfolioAssets);
|
|
733
733
|
const hasNative = portfolioAssets.some(
|
|
@@ -806,7 +806,7 @@ function AssetSelectStep({
|
|
|
806
806
|
const raw = _viem.formatUnits.call(void 0, BigInt(asset.balance), asset.decimals);
|
|
807
807
|
const numeric = Number(raw);
|
|
808
808
|
if (!Number.isFinite(numeric)) return raw;
|
|
809
|
-
return
|
|
809
|
+
return _chunkBRYNGLDMcjs.tokenFormatter.format(numeric);
|
|
810
810
|
} catch (e3) {
|
|
811
811
|
return asset.balance;
|
|
812
812
|
}
|
|
@@ -814,20 +814,20 @@ function AssetSelectStep({
|
|
|
814
814
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen", children: [
|
|
815
815
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen-body", children: [
|
|
816
816
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
817
|
-
|
|
817
|
+
_chunkBRYNGLDMcjs.BodyHeader,
|
|
818
818
|
{
|
|
819
|
-
icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
819
|
+
icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.WalletIcon, {}),
|
|
820
820
|
title: "Your assets",
|
|
821
821
|
subtitle: "Select source assets to transfer"
|
|
822
822
|
}
|
|
823
823
|
),
|
|
824
824
|
loading && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-loading-state", style: { padding: "40px 12px" }, children: [
|
|
825
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
825
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.Spinner, { className: "rs-text-tertiary" }),
|
|
826
826
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-text-sm rs-text-tertiary", children: "Loading balances" })
|
|
827
827
|
] }),
|
|
828
|
-
error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
828
|
+
error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.Callout, { variant: "error", children: error }),
|
|
829
829
|
!loading && !error && rows.length === 0 && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-empty-state", children: [
|
|
830
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
830
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.WalletIcon, { className: "rs-empty-icon" }),
|
|
831
831
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-empty-text", children: "No funds in connected wallet" }),
|
|
832
832
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-empty-address", children: [
|
|
833
833
|
address.slice(0, 6),
|
|
@@ -860,13 +860,13 @@ function AssetSelectStep({
|
|
|
860
860
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-asset-info", children: [
|
|
861
861
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-asset-icon-wrapper", children: [
|
|
862
862
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-asset-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
863
|
-
|
|
863
|
+
_chunkBRYNGLDMcjs.TokenIcon,
|
|
864
864
|
{
|
|
865
865
|
symbol: asset.symbol,
|
|
866
866
|
fallback: asset.symbol.slice(0, 4)
|
|
867
867
|
}
|
|
868
868
|
) }),
|
|
869
|
-
chainIcon ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-asset-chain-badge", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
869
|
+
chainIcon ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-asset-chain-badge", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CdnIcon, { src: chainIcon, alt: chainName(asset.chainId) }) }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
870
870
|
"span",
|
|
871
871
|
{
|
|
872
872
|
className: "rs-asset-chain-badge",
|
|
@@ -893,14 +893,14 @@ function AssetSelectStep({
|
|
|
893
893
|
] })
|
|
894
894
|
] })
|
|
895
895
|
] }),
|
|
896
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-asset-balance", children: asset.balanceUsd !== void 0 && asset.balanceUsd > 0 ?
|
|
896
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-asset-balance", children: asset.balanceUsd !== void 0 && asset.balanceUsd > 0 ? _chunkBRYNGLDMcjs.currencyFormatter.format(asset.balanceUsd) : tokenAmount !== "--" ? `${tokenAmount} ${asset.symbol}` : "--" })
|
|
897
897
|
]
|
|
898
898
|
},
|
|
899
899
|
asset.id
|
|
900
900
|
);
|
|
901
901
|
}) }),
|
|
902
902
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
903
|
-
|
|
903
|
+
_chunkBRYNGLDMcjs.Button,
|
|
904
904
|
{
|
|
905
905
|
onClick: () => selectedAsset && onContinue(selectedAsset),
|
|
906
906
|
disabled: !selectedAsset,
|
|
@@ -909,7 +909,7 @@ function AssetSelectStep({
|
|
|
909
909
|
}
|
|
910
910
|
)
|
|
911
911
|
] }),
|
|
912
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
912
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.PoweredBy, {})
|
|
913
913
|
] });
|
|
914
914
|
}
|
|
915
915
|
async function fetchNativeAssets(address, publicClient, existing, isDepositChain, catalogChain) {
|
|
@@ -917,7 +917,7 @@ async function fetchNativeAssets(address, publicClient, existing, isDepositChain
|
|
|
917
917
|
const connectedChainId = _optionalChain([publicClient, 'access', _16 => _16.chain, 'optionalAccess', _17 => _17.id]);
|
|
918
918
|
if (!connectedChainId) return [];
|
|
919
919
|
if (!isDepositChain(connectedChainId)) return [];
|
|
920
|
-
const id =
|
|
920
|
+
const id = _chunkBRYNGLDMcjs.getAssetId.call(void 0, {
|
|
921
921
|
chainId: connectedChainId,
|
|
922
922
|
token: _chunkO7BCVQ6Lcjs.NATIVE_TOKEN_ADDRESS
|
|
923
923
|
});
|
|
@@ -1120,7 +1120,7 @@ function AmountStep({
|
|
|
1120
1120
|
const balanceTarget = _nullishCoalesce(balanceAddress, () => ( address));
|
|
1121
1121
|
if (!balanceTarget || !publicClient) return;
|
|
1122
1122
|
try {
|
|
1123
|
-
const bal =
|
|
1123
|
+
const bal = _chunkBRYNGLDMcjs.isNativeAsset.call(void 0, asset) ? await publicClient.getBalance({ address: balanceTarget }) : await publicClient.readContract({
|
|
1124
1124
|
address: asset.token,
|
|
1125
1125
|
abi: _viem.erc20Abi,
|
|
1126
1126
|
functionName: "balanceOf",
|
|
@@ -1141,7 +1141,7 @@ function AmountStep({
|
|
|
1141
1141
|
hasAttemptedSwitch.current = true;
|
|
1142
1142
|
switchChain(asset.chainId).catch((err) => {
|
|
1143
1143
|
const raw = err instanceof Error ? err.message : "Failed to switch chain";
|
|
1144
|
-
setError(
|
|
1144
|
+
setError(_chunkBRYNGLDMcjs.formatUserError.call(void 0, raw));
|
|
1145
1145
|
});
|
|
1146
1146
|
}
|
|
1147
1147
|
}, [chainMismatch, switchChain, asset.chainId]);
|
|
@@ -1194,7 +1194,7 @@ function AmountStep({
|
|
|
1194
1194
|
const raw = _viem.formatUnits.call(void 0, balance, asset.decimals);
|
|
1195
1195
|
const numeric = Number(raw);
|
|
1196
1196
|
if (!Number.isFinite(numeric)) return raw;
|
|
1197
|
-
return
|
|
1197
|
+
return _chunkBRYNGLDMcjs.tokenFormatter.format(numeric);
|
|
1198
1198
|
} catch (e8) {
|
|
1199
1199
|
return "\u2026";
|
|
1200
1200
|
}
|
|
@@ -1279,12 +1279,12 @@ function AmountStep({
|
|
|
1279
1279
|
};
|
|
1280
1280
|
const continueLabel = exceedsBalance ? "Insufficient balance" : isAboveMax ? "Continue with max allowed deposit" : isBelowMin ? "Continue with minimum deposit" : "Continue";
|
|
1281
1281
|
const continueDisabled = chainMismatch || exceedsBalance || numericAmount === 0 && !isBelowMin || balance === null;
|
|
1282
|
-
const chainName =
|
|
1282
|
+
const chainName = _chunkBRYNGLDMcjs.useChainName.call(void 0, );
|
|
1283
1283
|
const sourceChainName = chainName(asset.chainId);
|
|
1284
1284
|
const targetChainName = chainName(targetChainId);
|
|
1285
1285
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen", children: [
|
|
1286
1286
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen-body rs-screen-body--gap-32", children: [
|
|
1287
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1287
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.BodyHeader, { icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.WalletIcon, {}), title: "Wallet deposit" }),
|
|
1288
1288
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-amount-section", children: [
|
|
1289
1289
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-amount-display", children: [
|
|
1290
1290
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
@@ -1304,13 +1304,13 @@ function AmountStep({
|
|
|
1304
1304
|
" available",
|
|
1305
1305
|
balanceUsd !== null && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
|
|
1306
1306
|
" (~",
|
|
1307
|
-
|
|
1307
|
+
_chunkBRYNGLDMcjs.currencyFormatter.format(balanceUsd),
|
|
1308
1308
|
")"
|
|
1309
1309
|
] })
|
|
1310
1310
|
] }),
|
|
1311
1311
|
minDepositUsd !== null && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-amount-meta-minimum", children: [
|
|
1312
1312
|
"Min. deposit ",
|
|
1313
|
-
|
|
1313
|
+
_chunkBRYNGLDMcjs.currencyFormatter.format(minDepositUsd)
|
|
1314
1314
|
] })
|
|
1315
1315
|
] })
|
|
1316
1316
|
] }),
|
|
@@ -1335,7 +1335,7 @@ function AmountStep({
|
|
|
1335
1335
|
" ",
|
|
1336
1336
|
asset.symbol
|
|
1337
1337
|
] }),
|
|
1338
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1338
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.TokenIcon, { symbol: asset.symbol }) })
|
|
1339
1339
|
] })
|
|
1340
1340
|
] }),
|
|
1341
1341
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-amount-detail-row", children: [
|
|
@@ -1346,17 +1346,17 @@ function AmountStep({
|
|
|
1346
1346
|
" ",
|
|
1347
1347
|
targetSymbol
|
|
1348
1348
|
] }),
|
|
1349
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1349
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.TokenIcon, { symbol: targetSymbol }) })
|
|
1350
1350
|
] })
|
|
1351
1351
|
] }),
|
|
1352
1352
|
balanceAfterUsd !== null && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-amount-detail-row", children: [
|
|
1353
1353
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: "Balance after deposit" }),
|
|
1354
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-value", children:
|
|
1354
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-value", children: _chunkBRYNGLDMcjs.currencyFormatter.format(balanceAfterUsd) })
|
|
1355
1355
|
] })
|
|
1356
1356
|
] }),
|
|
1357
|
-
error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1357
|
+
error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.Callout, { variant: "error", children: error }),
|
|
1358
1358
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1359
|
-
|
|
1359
|
+
_chunkBRYNGLDMcjs.Button,
|
|
1360
1360
|
{
|
|
1361
1361
|
onClick: handleContinue,
|
|
1362
1362
|
fullWidth: true,
|
|
@@ -1365,7 +1365,7 @@ function AmountStep({
|
|
|
1365
1365
|
}
|
|
1366
1366
|
)
|
|
1367
1367
|
] }),
|
|
1368
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1368
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.PoweredBy, {})
|
|
1369
1369
|
] });
|
|
1370
1370
|
}
|
|
1371
1371
|
|
|
@@ -1434,34 +1434,34 @@ function ConfirmStep({
|
|
|
1434
1434
|
const targetChainName = _chunkO7BCVQ6Lcjs.getChainName.call(void 0, targetChainId);
|
|
1435
1435
|
const sourceChainIcon = _chunkO7BCVQ6Lcjs.getChainIcon.call(void 0, asset.chainId);
|
|
1436
1436
|
const targetChainIcon = _chunkO7BCVQ6Lcjs.getChainIcon.call(void 0, targetChainId);
|
|
1437
|
-
const formattedSendAmount = amount && Number.isFinite(Number(amount)) ? _nullishCoalesce(
|
|
1438
|
-
const mustHaveQuote = !appFeesResolved ||
|
|
1437
|
+
const formattedSendAmount = amount && Number.isFinite(Number(amount)) ? _nullishCoalesce(_chunkBRYNGLDMcjs.formatTokenAmount.call(void 0, Number(amount), asset.symbol), () => ( "0")) : "0";
|
|
1438
|
+
const mustHaveQuote = !appFeesResolved || _chunkBRYNGLDMcjs.resolveAppFeeBps.call(void 0,
|
|
1439
1439
|
appFees,
|
|
1440
1440
|
`eip155:${quoteSource.chainId}`,
|
|
1441
1441
|
quoteSource.token
|
|
1442
1442
|
) > 0;
|
|
1443
|
-
const { display: feeDisplay, struck: feesFullySponsored } =
|
|
1443
|
+
const { display: feeDisplay, struck: feesFullySponsored } = _chunkBRYNGLDMcjs.quoteFeeRow.call(void 0,
|
|
1444
1444
|
_optionalChain([quote, 'optionalAccess', _36 => _36.fees])
|
|
1445
1445
|
);
|
|
1446
1446
|
const directTransfer = sameRoute && !mustHaveQuote && !executeTransfer;
|
|
1447
1447
|
const receiveDisplay = (() => {
|
|
1448
1448
|
if (directTransfer) return `${formattedSendAmount} ${asset.symbol}`;
|
|
1449
1449
|
if (quote) {
|
|
1450
|
-
const quoted =
|
|
1450
|
+
const quoted = _chunkBRYNGLDMcjs.formatQuotedReceive.call(void 0, quote.output, targetSymbol);
|
|
1451
1451
|
if (quoted !== void 0) return quoted;
|
|
1452
1452
|
}
|
|
1453
1453
|
const usdValue = Number(targetAmount);
|
|
1454
1454
|
const sourceAmountUsd = Number.isFinite(usdValue) && usdValue > 0 ? usdValue : void 0;
|
|
1455
|
-
const estimate =
|
|
1455
|
+
const estimate = _chunkBRYNGLDMcjs.formatReceiveEstimate.call(void 0, {
|
|
1456
1456
|
sourceAmount: Number.isFinite(Number(amount)) ? Number(amount) : void 0,
|
|
1457
1457
|
sourceSymbol: asset.symbol,
|
|
1458
1458
|
targetSymbol,
|
|
1459
1459
|
sourceAmountUsd,
|
|
1460
|
-
sourceTrusted:
|
|
1460
|
+
sourceTrusted: _chunkBRYNGLDMcjs.isRecognizedToken.call(void 0, asset.token, asset.chainId),
|
|
1461
1461
|
// The target is the curated deposit destination, so a stablecoin target
|
|
1462
1462
|
// estimates at $1 when unquoted (DepositFlow skips fetching stablecoin
|
|
1463
1463
|
// target prices). Not applied to the source — that can be a held token.
|
|
1464
|
-
prices: targetTokenPriceUsd !== null && targetTokenPriceUsd > 0 ? { [targetSymbol.toUpperCase()]: targetTokenPriceUsd } :
|
|
1464
|
+
prices: targetTokenPriceUsd !== null && targetTokenPriceUsd > 0 ? { [targetSymbol.toUpperCase()]: targetTokenPriceUsd } : _chunkBRYNGLDMcjs.isDisplayStablecoinSymbol.call(void 0, targetSymbol) ? { [targetSymbol.toUpperCase()]: 1 } : {}
|
|
1465
1465
|
});
|
|
1466
1466
|
if (estimate !== void 0) return estimate;
|
|
1467
1467
|
return targetSymbol;
|
|
@@ -1472,7 +1472,7 @@ function ConfirmStep({
|
|
|
1472
1472
|
hasAttemptedSwitch.current = true;
|
|
1473
1473
|
switchChain(asset.chainId).catch((err) => {
|
|
1474
1474
|
const raw = err instanceof Error ? err.message : "Failed to switch chain";
|
|
1475
|
-
setError(
|
|
1475
|
+
setError(_chunkBRYNGLDMcjs.formatUserError.call(void 0, raw));
|
|
1476
1476
|
});
|
|
1477
1477
|
}
|
|
1478
1478
|
}, [chainMismatch, switchChain, asset.chainId]);
|
|
@@ -1561,7 +1561,7 @@ function ConfirmStep({
|
|
|
1561
1561
|
const result = await executeTransfer(amountUnits);
|
|
1562
1562
|
hash = result.txHash;
|
|
1563
1563
|
resolvedSourceToken = result.sourceToken;
|
|
1564
|
-
} else if (
|
|
1564
|
+
} else if (_chunkBRYNGLDMcjs.isNativeAsset.call(void 0, asset)) {
|
|
1565
1565
|
hash = await walletClient.sendTransaction({
|
|
1566
1566
|
account,
|
|
1567
1567
|
chain,
|
|
@@ -1592,7 +1592,7 @@ function ConfirmStep({
|
|
|
1592
1592
|
);
|
|
1593
1593
|
} catch (err) {
|
|
1594
1594
|
const raw = err instanceof Error ? err.message : "Transfer failed";
|
|
1595
|
-
const message =
|
|
1595
|
+
const message = _chunkBRYNGLDMcjs.formatUserError.call(void 0, raw);
|
|
1596
1596
|
setError(message);
|
|
1597
1597
|
_optionalChain([onError, 'optionalCall', _38 => _38(message, "TRANSFER_ERROR", raw)]);
|
|
1598
1598
|
} finally {
|
|
@@ -1601,20 +1601,20 @@ function ConfirmStep({
|
|
|
1601
1601
|
};
|
|
1602
1602
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen", children: [
|
|
1603
1603
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen-body rs-screen-body--gap-32", children: [
|
|
1604
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1604
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.BodyHeader, { icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.WalletIcon, {}), title: "Review deposit" }),
|
|
1605
1605
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-review-details", children: [
|
|
1606
1606
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-review-detail-row", children: [
|
|
1607
1607
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: "Source chain" }),
|
|
1608
1608
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-review-detail-value", children: [
|
|
1609
1609
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: sourceChainName }),
|
|
1610
|
-
sourceChainIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1610
|
+
sourceChainIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CdnIcon, { src: sourceChainIcon }) })
|
|
1611
1611
|
] })
|
|
1612
1612
|
] }),
|
|
1613
1613
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-review-detail-row", children: [
|
|
1614
1614
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: "Destination chain" }),
|
|
1615
1615
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-review-detail-value", children: [
|
|
1616
1616
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: targetChainName }),
|
|
1617
|
-
targetChainIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1617
|
+
targetChainIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CdnIcon, { src: targetChainIcon }) })
|
|
1618
1618
|
] })
|
|
1619
1619
|
] }),
|
|
1620
1620
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-review-detail-row", children: [
|
|
@@ -1629,14 +1629,14 @@ function ConfirmStep({
|
|
|
1629
1629
|
" ",
|
|
1630
1630
|
asset.symbol
|
|
1631
1631
|
] }),
|
|
1632
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1632
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.TokenIcon, { symbol: asset.symbol }) })
|
|
1633
1633
|
] })
|
|
1634
1634
|
] }),
|
|
1635
1635
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-review-detail-row", children: [
|
|
1636
1636
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: "Receive" }),
|
|
1637
1637
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-review-detail-value", children: [
|
|
1638
1638
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: receiveDisplay }),
|
|
1639
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1639
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.TokenIcon, { symbol: targetSymbol }) })
|
|
1640
1640
|
] })
|
|
1641
1641
|
] }),
|
|
1642
1642
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-review-detail-row", children: [
|
|
@@ -1656,9 +1656,9 @@ function ConfirmStep({
|
|
|
1656
1656
|
) })
|
|
1657
1657
|
] })
|
|
1658
1658
|
] }),
|
|
1659
|
-
error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1659
|
+
error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.Callout, { variant: "error", children: error }),
|
|
1660
1660
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1661
|
-
|
|
1661
|
+
_chunkBRYNGLDMcjs.Button,
|
|
1662
1662
|
{
|
|
1663
1663
|
onClick: handleConfirm,
|
|
1664
1664
|
loading: isSubmitting,
|
|
@@ -1672,7 +1672,7 @@ function ConfirmStep({
|
|
|
1672
1672
|
}
|
|
1673
1673
|
)
|
|
1674
1674
|
] }),
|
|
1675
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1675
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.PoweredBy, {})
|
|
1676
1676
|
] });
|
|
1677
1677
|
}
|
|
1678
1678
|
|
|
@@ -1703,20 +1703,20 @@ function DepositAddressSkeleton({
|
|
|
1703
1703
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen", "aria-busy": "true", children: [
|
|
1704
1704
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-sr-only", role: "status", children: "Preparing deposit details\u2026" }),
|
|
1705
1705
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen-body", children: [
|
|
1706
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1706
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.BodyHeader, { icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.TransferCryptoIcon, {}), title: "Transfer crypto" }),
|
|
1707
1707
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-deposit-address-selectors", "aria-hidden": "true", children: [
|
|
1708
1708
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-deposit-address-dropdown", children: [
|
|
1709
1709
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-deposit-address-dropdown-label", children: "Supported chain" }),
|
|
1710
1710
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-deposit-address-dropdown-trigger", children: [
|
|
1711
1711
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1712
|
-
|
|
1712
|
+
_chunkBRYNGLDMcjs.CdnIcon,
|
|
1713
1713
|
{
|
|
1714
1714
|
src: chainIcon,
|
|
1715
1715
|
className: "rs-deposit-address-dropdown-icon"
|
|
1716
1716
|
}
|
|
1717
1717
|
),
|
|
1718
1718
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: chainName }),
|
|
1719
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1719
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.ChevronDownIcon, { className: "rs-deposit-address-dropdown-chevron" })
|
|
1720
1720
|
] })
|
|
1721
1721
|
] }),
|
|
1722
1722
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-deposit-address-dropdown", children: [
|
|
@@ -1725,8 +1725,8 @@ function DepositAddressSkeleton({
|
|
|
1725
1725
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-deposit-address-min", children: [
|
|
1726
1726
|
"Min.$",
|
|
1727
1727
|
(_nullishCoalesce(_optionalChain([uiConfig, 'optionalAccess', _39 => _39.minDepositUsd]), () => ( 0.1))).toFixed(2),
|
|
1728
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1729
|
-
|
|
1728
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkPWLEBV5Vcjs.Tooltip, { content: "Minimum deposit amount required for the selected chain.", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1729
|
+
_chunkBRYNGLDMcjs.InfoIcon,
|
|
1730
1730
|
{
|
|
1731
1731
|
className: "rs-deposit-address-min-icon",
|
|
1732
1732
|
"aria-hidden": "true"
|
|
@@ -1736,14 +1736,14 @@ function DepositAddressSkeleton({
|
|
|
1736
1736
|
] }),
|
|
1737
1737
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-deposit-address-dropdown-trigger", children: [
|
|
1738
1738
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1739
|
-
|
|
1739
|
+
_chunkBRYNGLDMcjs.TokenIcon,
|
|
1740
1740
|
{
|
|
1741
1741
|
symbol: defaultToken,
|
|
1742
1742
|
className: "rs-deposit-address-dropdown-icon"
|
|
1743
1743
|
}
|
|
1744
1744
|
),
|
|
1745
1745
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: defaultToken }),
|
|
1746
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1746
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.ChevronDownIcon, { className: "rs-deposit-address-dropdown-chevron" })
|
|
1747
1747
|
] })
|
|
1748
1748
|
] })
|
|
1749
1749
|
] }),
|
|
@@ -1764,7 +1764,7 @@ function DepositAddressSkeleton({
|
|
|
1764
1764
|
disabled: true,
|
|
1765
1765
|
"aria-hidden": "true",
|
|
1766
1766
|
children: [
|
|
1767
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1767
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CopyIcon, {}),
|
|
1768
1768
|
"Copy address"
|
|
1769
1769
|
]
|
|
1770
1770
|
}
|
|
@@ -1777,16 +1777,16 @@ function DepositAddressSkeleton({
|
|
|
1777
1777
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-price-impact-label", children: "Price impact" }),
|
|
1778
1778
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-price-impact-label", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "strong", { children: "0.00%" }) }),
|
|
1779
1779
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1780
|
-
|
|
1780
|
+
_chunkPWLEBV5Vcjs.Tooltip,
|
|
1781
1781
|
{
|
|
1782
1782
|
className: "rs-price-impact-info",
|
|
1783
1783
|
content: "Price impact is the difference between expected and execution price, due to trade size and liquidity.",
|
|
1784
|
-
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1784
|
+
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.InfoIcon, { "aria-hidden": "true" })
|
|
1785
1785
|
}
|
|
1786
1786
|
)
|
|
1787
1787
|
] }),
|
|
1788
1788
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1789
|
-
|
|
1789
|
+
_chunkBRYNGLDMcjs.ChevronDownIcon,
|
|
1790
1790
|
{
|
|
1791
1791
|
className: "rs-price-impact-chevron",
|
|
1792
1792
|
"aria-hidden": "true"
|
|
@@ -1794,7 +1794,7 @@ function DepositAddressSkeleton({
|
|
|
1794
1794
|
)
|
|
1795
1795
|
] }) })
|
|
1796
1796
|
] }),
|
|
1797
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1797
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.PoweredBy, {})
|
|
1798
1798
|
] });
|
|
1799
1799
|
}
|
|
1800
1800
|
DepositAddressSkeleton.displayName = "DepositAddressSkeleton";
|
|
@@ -1806,9 +1806,9 @@ var INITIAL_POLL_INTERVAL = 3e3;
|
|
|
1806
1806
|
var MAX_POLL_INTERVAL = 3e4;
|
|
1807
1807
|
var BACKOFF_MULTIPLIER = 1.5;
|
|
1808
1808
|
function isEventForTx(event, txHash) {
|
|
1809
|
-
const eventTxHash =
|
|
1809
|
+
const eventTxHash = _chunkPWLEBV5Vcjs.getEventTxHash.call(void 0, event);
|
|
1810
1810
|
if (!eventTxHash) return false;
|
|
1811
|
-
return
|
|
1811
|
+
return _chunkPWLEBV5Vcjs.txRefsMatch.call(void 0, eventTxHash, txHash);
|
|
1812
1812
|
}
|
|
1813
1813
|
function truncateHash(hash) {
|
|
1814
1814
|
return `${hash.slice(0, 4)}\u2026${hash.slice(-4)}`;
|
|
@@ -1858,7 +1858,7 @@ function formatBridgeFailedMessage(event) {
|
|
|
1858
1858
|
}
|
|
1859
1859
|
return "Bridge failed";
|
|
1860
1860
|
}
|
|
1861
|
-
var txLinkIcon = /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1861
|
+
var txLinkIcon = /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.ExternalLinkIcon, { className: "rs-deposit-notification-link-icon" });
|
|
1862
1862
|
function DepositNotification({
|
|
1863
1863
|
deposit,
|
|
1864
1864
|
smartAccount,
|
|
@@ -1892,7 +1892,7 @@ function DepositNotification({
|
|
|
1892
1892
|
const pollIntervalRef = _react.useRef.call(void 0, INITIAL_POLL_INTERVAL);
|
|
1893
1893
|
const pollTimeoutRef = _react.useRef.call(void 0, null);
|
|
1894
1894
|
const completedRef = _react.useRef.call(void 0, _nullishCoalesce(directTransfer, () => ( false)));
|
|
1895
|
-
const depositContextRef =
|
|
1895
|
+
const depositContextRef = _chunkBRYNGLDMcjs.useLatestRef.call(void 0, {
|
|
1896
1896
|
amount,
|
|
1897
1897
|
sourceChain,
|
|
1898
1898
|
sourceToken: token,
|
|
@@ -1900,8 +1900,8 @@ function DepositNotification({
|
|
|
1900
1900
|
targetChain,
|
|
1901
1901
|
targetToken
|
|
1902
1902
|
});
|
|
1903
|
-
const onCompleteRef =
|
|
1904
|
-
const onFailedRef =
|
|
1903
|
+
const onCompleteRef = _chunkBRYNGLDMcjs.useLatestRef.call(void 0, onComplete);
|
|
1904
|
+
const onFailedRef = _chunkBRYNGLDMcjs.useLatestRef.call(void 0, onFailed);
|
|
1905
1905
|
const handleComplete = _react.useCallback.call(void 0,
|
|
1906
1906
|
(destTxHash) => {
|
|
1907
1907
|
if (completedRef.current) return;
|
|
@@ -1992,12 +1992,12 @@ function DepositNotification({
|
|
|
1992
1992
|
status,
|
|
1993
1993
|
txHash
|
|
1994
1994
|
]);
|
|
1995
|
-
const explorerTxUrl =
|
|
1995
|
+
const explorerTxUrl = _chunkBRYNGLDMcjs.useExplorerTxUrl.call(void 0, );
|
|
1996
1996
|
const sourceExplorerUrl = sourceChain === "unknown" ? void 0 : explorerTxUrl(sourceChain, txHash);
|
|
1997
1997
|
const destExplorerUrl = destinationTxHash ? explorerTxUrl(_chunkO7BCVQ6Lcjs.targetChainToChainId.call(void 0, targetChain), destinationTxHash) : null;
|
|
1998
1998
|
const title = status === "complete" ? "Deposit completed" : status === "failed" ? "Deposit failed" : "Deposit received and processing\u2026";
|
|
1999
1999
|
const subtitle = status === "complete" ? "Your deposit has been credited to your account." : status === "failed" ? "Your deposit could not be processed." : "Your deposit will be credited to your account shortly.";
|
|
2000
|
-
const statusIcon = status === "complete" ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-deposit-notification-badge rs-deposit-notification-badge--complete", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2000
|
+
const statusIcon = status === "complete" ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-deposit-notification-badge rs-deposit-notification-badge--complete", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CheckIcon, {}) }) : status === "failed" ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-deposit-notification-badge rs-deposit-notification-badge--failed", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CloseIcon, {}) }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-deposit-notification-badge rs-deposit-notification-badge--processing", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
2001
2001
|
"svg",
|
|
2002
2002
|
{
|
|
2003
2003
|
className: "rs-deposit-notification-spinner",
|
|
@@ -2047,7 +2047,7 @@ function DepositNotification({
|
|
|
2047
2047
|
className: "rs-deposit-notification-close",
|
|
2048
2048
|
onClick: () => onDismiss(deposit.id),
|
|
2049
2049
|
"aria-label": "Dismiss",
|
|
2050
|
-
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2050
|
+
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CloseIcon, {})
|
|
2051
2051
|
}
|
|
2052
2052
|
)
|
|
2053
2053
|
] }),
|
|
@@ -2063,7 +2063,7 @@ function DepositNotification({
|
|
|
2063
2063
|
"aria-expanded": expanded,
|
|
2064
2064
|
children: [
|
|
2065
2065
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: expanded ? "See less details" : "See more details" }),
|
|
2066
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2066
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.ChevronDownIcon, { className: "rs-deposit-notification-toggle-chevron" })
|
|
2067
2067
|
]
|
|
2068
2068
|
}
|
|
2069
2069
|
),
|
|
@@ -2213,7 +2213,7 @@ function resolveSourceTokenAddress(symbol, chainId, topTokens, catalogChain) {
|
|
|
2213
2213
|
}
|
|
2214
2214
|
function TokenGlyph({ symbol }) {
|
|
2215
2215
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2216
|
-
|
|
2216
|
+
_chunkBRYNGLDMcjs.TokenIcon,
|
|
2217
2217
|
{
|
|
2218
2218
|
symbol,
|
|
2219
2219
|
className: "rs-deposit-address-dropdown-icon",
|
|
@@ -2254,12 +2254,12 @@ function DepositAddressStep({
|
|
|
2254
2254
|
};
|
|
2255
2255
|
}, [service]);
|
|
2256
2256
|
const BASE_CHAIN_ID2 = 8453;
|
|
2257
|
-
const evmChainIds =
|
|
2258
|
-
const { catalog, isLoading: catalogLoading } =
|
|
2257
|
+
const evmChainIds = _chunkBRYNGLDMcjs.useDepositChainIds.call(void 0, );
|
|
2258
|
+
const { catalog, isLoading: catalogLoading } = _chunkBRYNGLDMcjs.useChainCatalog.call(void 0, );
|
|
2259
2259
|
const catalogFor = _react.useCallback.call(void 0,
|
|
2260
2260
|
(chain) => {
|
|
2261
2261
|
if (!catalog) return void 0;
|
|
2262
|
-
const key =
|
|
2262
|
+
const key = _chunkBRYNGLDMcjs.catalogKeyForChain.call(void 0, chain);
|
|
2263
2263
|
return typeof key === "number" ? catalog.byChainId.get(key) : catalog.byCaip2.get(key);
|
|
2264
2264
|
},
|
|
2265
2265
|
[catalog]
|
|
@@ -2468,10 +2468,10 @@ function DepositAddressStep({
|
|
|
2468
2468
|
return;
|
|
2469
2469
|
}
|
|
2470
2470
|
const event = status.lastEvent;
|
|
2471
|
-
const eventTxHash =
|
|
2471
|
+
const eventTxHash = _chunkPWLEBV5Vcjs.isDepositEvent.call(void 0, event) ? _nullishCoalesce(_chunkPWLEBV5Vcjs.getEventTxHash.call(void 0, event), () => ( null)) : null;
|
|
2472
2472
|
if (baselineTxHashRef.current === void 0) {
|
|
2473
2473
|
baselineTxHashRef.current = eventTxHash;
|
|
2474
|
-
} else if (eventTxHash && (!baselineTxHashRef.current || !
|
|
2474
|
+
} else if (eventTxHash && (!baselineTxHashRef.current || !_chunkPWLEBV5Vcjs.txRefsMatch.call(void 0, eventTxHash, baselineTxHashRef.current))) {
|
|
2475
2475
|
const details = getDepositEventDetails(event);
|
|
2476
2476
|
const chainId = _nullishCoalesce(details.chainId, () => ( "unknown"));
|
|
2477
2477
|
const amount = _nullishCoalesce(details.amount, () => ( "0"));
|
|
@@ -2549,13 +2549,13 @@ function DepositAddressStep({
|
|
|
2549
2549
|
if (chainOptions.length === 0) {
|
|
2550
2550
|
if (catalogLoading) return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, DepositAddressSkeleton, { uiConfig });
|
|
2551
2551
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-screen", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen-body", children: [
|
|
2552
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2553
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2552
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.BodyHeader, { icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.TransferCryptoIcon, {}), title: "Transfer crypto" }),
|
|
2553
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.Callout, { variant: "error", children: "Supported chains are unavailable right now, so there is no deposit address to show. Close and try again in a moment." })
|
|
2554
2554
|
] }) });
|
|
2555
2555
|
}
|
|
2556
2556
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen rs-step--with-notifications", children: [
|
|
2557
2557
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen-body", children: [
|
|
2558
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2558
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.BodyHeader, { icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.TransferCryptoIcon, {}), title: "Transfer crypto" }),
|
|
2559
2559
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-deposit-address-selectors", children: [
|
|
2560
2560
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-deposit-address-dropdown", ref: chainDropdownRef, children: [
|
|
2561
2561
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-deposit-address-dropdown-label", children: "Supported chain" }),
|
|
@@ -2571,14 +2571,14 @@ function DepositAddressStep({
|
|
|
2571
2571
|
},
|
|
2572
2572
|
children: [
|
|
2573
2573
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2574
|
-
|
|
2574
|
+
_chunkBRYNGLDMcjs.CdnIcon,
|
|
2575
2575
|
{
|
|
2576
2576
|
src: _nullishCoalesce(_optionalChain([catalogFor, 'call', _96 => _96(sourceChainId), 'optionalAccess', _97 => _97.iconUrl]), () => ( _chunkO7BCVQ6Lcjs.getChainIcon.call(void 0, sourceChainId))),
|
|
2577
2577
|
className: "rs-deposit-address-dropdown-icon"
|
|
2578
2578
|
}
|
|
2579
2579
|
),
|
|
2580
2580
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: chainLabel(sourceChainId, catalogFor(sourceChainId)) }),
|
|
2581
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2581
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.ChevronDownIcon, { className: "rs-deposit-address-dropdown-chevron" })
|
|
2582
2582
|
]
|
|
2583
2583
|
}
|
|
2584
2584
|
),
|
|
@@ -2590,7 +2590,7 @@ function DepositAddressStep({
|
|
|
2590
2590
|
onClick: () => handleSelectChain(chainId),
|
|
2591
2591
|
children: [
|
|
2592
2592
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2593
|
-
|
|
2593
|
+
_chunkBRYNGLDMcjs.CdnIcon,
|
|
2594
2594
|
{
|
|
2595
2595
|
src: _nullishCoalesce(_optionalChain([catalogFor, 'call', _98 => _98(chainId), 'optionalAccess', _99 => _99.iconUrl]), () => ( _chunkO7BCVQ6Lcjs.getChainIcon.call(void 0, chainId))),
|
|
2596
2596
|
className: "rs-deposit-address-dropdown-icon"
|
|
@@ -2608,8 +2608,8 @@ function DepositAddressStep({
|
|
|
2608
2608
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-deposit-address-min", children: [
|
|
2609
2609
|
"Min.$",
|
|
2610
2610
|
(_chunkO7BCVQ6Lcjs.isHyperCoreDestination.call(void 0, targetChain) || isHyperCore ? Math.max(_chunkO7BCVQ6Lcjs.HYPERCORE_MIN_DEPOSIT_USD, _nullishCoalesce(_optionalChain([uiConfig, 'optionalAccess', _100 => _100.minDepositUsd]), () => ( 0))) : _nullishCoalesce(_optionalChain([uiConfig, 'optionalAccess', _101 => _101.minDepositUsd]), () => ( 0.1))).toFixed(2),
|
|
2611
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2612
|
-
|
|
2611
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkPWLEBV5Vcjs.Tooltip, { content: "Minimum deposit amount required for the selected chain.", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2612
|
+
_chunkBRYNGLDMcjs.InfoIcon,
|
|
2613
2613
|
{
|
|
2614
2614
|
className: "rs-deposit-address-min-icon",
|
|
2615
2615
|
"aria-hidden": "true"
|
|
@@ -2630,7 +2630,7 @@ function DepositAddressStep({
|
|
|
2630
2630
|
children: [
|
|
2631
2631
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, TokenGlyph, { symbol: sourceTokenSymbol }),
|
|
2632
2632
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: sourceTokenSymbol }),
|
|
2633
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2633
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.ChevronDownIcon, { className: "rs-deposit-address-dropdown-chevron" })
|
|
2634
2634
|
]
|
|
2635
2635
|
}
|
|
2636
2636
|
),
|
|
@@ -2674,7 +2674,7 @@ function DepositAddressStep({
|
|
|
2674
2674
|
className: "rs-deposit-address-copy",
|
|
2675
2675
|
onClick: handleCopy,
|
|
2676
2676
|
children: [
|
|
2677
|
-
copied ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2677
|
+
copied ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CheckIcon, {}) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CopyIcon, {}),
|
|
2678
2678
|
copied ? "Copied!" : "Copy address"
|
|
2679
2679
|
]
|
|
2680
2680
|
}
|
|
@@ -2699,16 +2699,16 @@ function DepositAddressStep({
|
|
|
2699
2699
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-price-impact-label", children: "Price impact" }),
|
|
2700
2700
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-price-impact-label", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "strong", { children: "0.00%" }) }),
|
|
2701
2701
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2702
|
-
|
|
2702
|
+
_chunkPWLEBV5Vcjs.Tooltip,
|
|
2703
2703
|
{
|
|
2704
2704
|
className: "rs-price-impact-info",
|
|
2705
2705
|
content: "Price impact is the difference between expected and execution price, due to trade size and liquidity.",
|
|
2706
|
-
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2706
|
+
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.InfoIcon, { "aria-hidden": "true" })
|
|
2707
2707
|
}
|
|
2708
2708
|
)
|
|
2709
2709
|
] }),
|
|
2710
2710
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2711
|
-
|
|
2711
|
+
_chunkBRYNGLDMcjs.ChevronDownIcon,
|
|
2712
2712
|
{
|
|
2713
2713
|
className: "rs-price-impact-chevron",
|
|
2714
2714
|
"aria-hidden": "true"
|
|
@@ -2719,29 +2719,29 @@ function DepositAddressStep({
|
|
|
2719
2719
|
),
|
|
2720
2720
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-price-impact-panel", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-price-impact-panel-inner", children: [
|
|
2721
2721
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-price-impact-row", children: [
|
|
2722
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-price-impact-row-icon", "aria-hidden": "true", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2722
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-price-impact-row-icon", "aria-hidden": "true", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.PercentIcon, {}) }),
|
|
2723
2723
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-price-impact-label", children: [
|
|
2724
2724
|
"Max slippage: ",
|
|
2725
2725
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "strong", { children: "0.2%" })
|
|
2726
2726
|
] }),
|
|
2727
2727
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2728
|
-
|
|
2728
|
+
_chunkPWLEBV5Vcjs.Tooltip,
|
|
2729
2729
|
{
|
|
2730
2730
|
className: "rs-price-impact-info",
|
|
2731
2731
|
content: "Slippage accounts for price changes during execution. Slippage is adjusted per pair to ensure reliable execution.",
|
|
2732
|
-
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2732
|
+
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.InfoIcon, { "aria-hidden": "true" })
|
|
2733
2733
|
}
|
|
2734
2734
|
)
|
|
2735
2735
|
] }),
|
|
2736
2736
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-price-impact-row", children: [
|
|
2737
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-price-impact-row-icon", "aria-hidden": "true", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2737
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-price-impact-row-icon", "aria-hidden": "true", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.ClockIcon, {}) }),
|
|
2738
2738
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-price-impact-label", children: [
|
|
2739
2739
|
"Processing time: ",
|
|
2740
2740
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "strong", { children: "< 1 min" })
|
|
2741
2741
|
] })
|
|
2742
2742
|
] }),
|
|
2743
2743
|
liquidityHelper.kind !== "idle" && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-price-impact-row", children: [
|
|
2744
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-price-impact-row-icon", "aria-hidden": "true", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2744
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-price-impact-row-icon", "aria-hidden": "true", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.PlusCircleIcon, {}) }),
|
|
2745
2745
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-price-impact-label", children: [
|
|
2746
2746
|
"Max deposit:",
|
|
2747
2747
|
" ",
|
|
@@ -2772,7 +2772,7 @@ function DepositAddressStep({
|
|
|
2772
2772
|
},
|
|
2773
2773
|
deposit.id
|
|
2774
2774
|
)) }),
|
|
2775
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2775
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.PoweredBy, {})
|
|
2776
2776
|
] });
|
|
2777
2777
|
}
|
|
2778
2778
|
DepositAddressStep.displayName = "DepositAddressStep";
|
|
@@ -2820,7 +2820,7 @@ function FinalisingDepositStep() {
|
|
|
2820
2820
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "rs-finalising-subtitle", children: "We are depositing your funds to the application." })
|
|
2821
2821
|
] })
|
|
2822
2822
|
] }),
|
|
2823
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2823
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.PoweredBy, {})
|
|
2824
2824
|
] });
|
|
2825
2825
|
}
|
|
2826
2826
|
FinalisingDepositStep.displayName = "FinalisingDepositStep";
|
|
@@ -2850,7 +2850,7 @@ function SwappedOrderTracker({
|
|
|
2850
2850
|
];
|
|
2851
2851
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen rs-swapped-tracker", children: [
|
|
2852
2852
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen-body rs-screen-body--gap-32", children: [
|
|
2853
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2853
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.BodyHeader, { icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.HandCoinsIcon, {}), title }),
|
|
2854
2854
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "ol", { className: "rs-swapped-tracker-steps", children: labels.map((label, idx) => {
|
|
2855
2855
|
const status = stepStates[idx];
|
|
2856
2856
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
@@ -2864,7 +2864,7 @@ function SwappedOrderTracker({
|
|
|
2864
2864
|
{
|
|
2865
2865
|
className: "rs-swapped-tracker-step-marker",
|
|
2866
2866
|
"aria-hidden": "true",
|
|
2867
|
-
children: status === "complete" ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2867
|
+
children: status === "complete" ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CheckIcon, {}) : status === "failed" ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CloseIcon, {}) : status === "active" ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.Spinner, {}) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2868
2868
|
"svg",
|
|
2869
2869
|
{
|
|
2870
2870
|
className: "rs-swapped-tracker-step-ring",
|
|
@@ -2899,7 +2899,7 @@ function SwappedOrderTracker({
|
|
|
2899
2899
|
}
|
|
2900
2900
|
)
|
|
2901
2901
|
] }),
|
|
2902
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2902
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.PoweredBy, {})
|
|
2903
2903
|
] });
|
|
2904
2904
|
}
|
|
2905
2905
|
function formatTrackerAmount(amount) {
|
|
@@ -3104,10 +3104,10 @@ function SwappedIframeStep({
|
|
|
3104
3104
|
const status = await service.fetchLatestStatus(smartAccount);
|
|
3105
3105
|
if (cancelled) return;
|
|
3106
3106
|
const event = status.lastEvent;
|
|
3107
|
-
const eventTxHash =
|
|
3107
|
+
const eventTxHash = _chunkPWLEBV5Vcjs.isDepositEvent.call(void 0, event) ? _nullishCoalesce(_chunkPWLEBV5Vcjs.getEventTxHash.call(void 0, event), () => ( null)) : null;
|
|
3108
3108
|
if (baselineDepositTxHashRef.current === void 0) {
|
|
3109
3109
|
baselineDepositTxHashRef.current = eventTxHash;
|
|
3110
|
-
} else if (eventTxHash && (!baselineDepositTxHashRef.current || !
|
|
3110
|
+
} else if (eventTxHash && (!baselineDepositTxHashRef.current || !_chunkPWLEBV5Vcjs.txRefsMatch.call(void 0, eventTxHash, baselineDepositTxHashRef.current))) {
|
|
3111
3111
|
currentDepositTxHashRef.current = eventTxHash;
|
|
3112
3112
|
setLatestEvent(_nullishCoalesce(event, () => ( null)));
|
|
3113
3113
|
}
|
|
@@ -3181,10 +3181,10 @@ function SwappedIframeStep({
|
|
|
3181
3181
|
[orderState, latestEvent]
|
|
3182
3182
|
);
|
|
3183
3183
|
const terminalState = _react.useMemo.call(void 0, () => {
|
|
3184
|
-
if (
|
|
3184
|
+
if (_chunkPWLEBV5Vcjs.isFailedEvent.call(void 0, _nullishCoalesce(latestEvent, () => ( void 0)))) {
|
|
3185
3185
|
return {
|
|
3186
3186
|
kind: "failed",
|
|
3187
|
-
message:
|
|
3187
|
+
message: _chunkPWLEBV5Vcjs.failureMessageForEvent.call(void 0, _nullishCoalesce(latestEvent, () => ( void 0)))
|
|
3188
3188
|
};
|
|
3189
3189
|
}
|
|
3190
3190
|
if (_optionalChain([orderState, 'optionalAccess', _118 => _118.status]) === "order_cancelled") {
|
|
@@ -3207,7 +3207,7 @@ function SwappedIframeStep({
|
|
|
3207
3207
|
orderCrypto: _nullishCoalesce(_optionalChain([orderState, 'optionalAccess', _120 => _120.orderCrypto]), () => ( null)),
|
|
3208
3208
|
// Base-unit source amount from the deposit row/event, consistent with the
|
|
3209
3209
|
// wallet/QR path. ProcessingStep + onLifecycle expect base units.
|
|
3210
|
-
amount: _nullishCoalesce(
|
|
3210
|
+
amount: _nullishCoalesce(_chunkPWLEBV5Vcjs.getEventSourceDetails.call(void 0, _nullishCoalesce(latestEvent, () => ( void 0))).amount, () => ( null)),
|
|
3211
3211
|
expectedOrderUuid: expectedOrderUuidRef.current,
|
|
3212
3212
|
initialEvent: _nullishCoalesce(latestEvent, () => ( void 0))
|
|
3213
3213
|
};
|
|
@@ -3218,14 +3218,14 @@ function SwappedIframeStep({
|
|
|
3218
3218
|
}, [latestEvent, orderState, smartAccount]);
|
|
3219
3219
|
_react.useEffect.call(void 0, () => {
|
|
3220
3220
|
if (failedFiredRef.current || completeFiredRef.current) return;
|
|
3221
|
-
if (!
|
|
3221
|
+
if (!_chunkPWLEBV5Vcjs.isFailedEvent.call(void 0, _nullishCoalesce(latestEvent, () => ( void 0)))) return;
|
|
3222
3222
|
const txHash = currentDepositTxHashRef.current;
|
|
3223
3223
|
if (!txHash) return;
|
|
3224
3224
|
failedFiredRef.current = true;
|
|
3225
3225
|
setPhase("tracker");
|
|
3226
3226
|
_optionalChain([onSwappedFailedRef, 'access', _121 => _121.current, 'optionalCall', _122 => _122(
|
|
3227
3227
|
txHash,
|
|
3228
|
-
|
|
3228
|
+
_chunkPWLEBV5Vcjs.failureMessageForEvent.call(void 0, _nullishCoalesce(latestEvent, () => ( void 0)))
|
|
3229
3229
|
)]);
|
|
3230
3230
|
}, [latestEvent]);
|
|
3231
3231
|
const immersive = variant === "fiat" && phase === "iframe" && !loadError;
|
|
@@ -3271,7 +3271,7 @@ function SwappedIframeStep({
|
|
|
3271
3271
|
}
|
|
3272
3272
|
)
|
|
3273
3273
|
] }),
|
|
3274
|
-
!loadError && !iframeLoaded && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-fiat-onramp-loading", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3274
|
+
!loadError && !iframeLoaded && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-fiat-onramp-loading", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.Spinner, {}) }),
|
|
3275
3275
|
widgetUrl && !loadError && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3276
3276
|
"iframe",
|
|
3277
3277
|
{
|
|
@@ -3294,11 +3294,11 @@ function SwappedIframeStep({
|
|
|
3294
3294
|
retryToken
|
|
3295
3295
|
)
|
|
3296
3296
|
] }) }),
|
|
3297
|
-
loadError && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3297
|
+
loadError && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.PoweredBy, {})
|
|
3298
3298
|
] });
|
|
3299
3299
|
}
|
|
3300
3300
|
function deriveStepStates(swappedStatus, latestEvent) {
|
|
3301
|
-
if (
|
|
3301
|
+
if (_chunkPWLEBV5Vcjs.isFailedEvent.call(void 0, _nullishCoalesce(latestEvent, () => ( void 0)))) {
|
|
3302
3302
|
return ["complete", "complete", "failed", "pending"];
|
|
3303
3303
|
}
|
|
3304
3304
|
if (swappedStatus === "order_cancelled") {
|
|
@@ -3488,7 +3488,7 @@ ExchangeConnectStep.displayName = "ExchangeConnectStep";
|
|
|
3488
3488
|
function ExchangeLogo({ exchange }) {
|
|
3489
3489
|
const [failed, setFailed] = _react.useState.call(void 0, false);
|
|
3490
3490
|
if (!exchange.logoUrl || failed) {
|
|
3491
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3491
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.BankIcon, {});
|
|
3492
3492
|
}
|
|
3493
3493
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3494
3494
|
"img",
|
|
@@ -3569,14 +3569,14 @@ function ExchangeSelectStep({
|
|
|
3569
3569
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen rs-exchange-select", children: [
|
|
3570
3570
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen-body rs-screen-body--gap-32", children: [
|
|
3571
3571
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3572
|
-
|
|
3572
|
+
_chunkBRYNGLDMcjs.BodyHeader,
|
|
3573
3573
|
{
|
|
3574
|
-
icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3574
|
+
icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.UnplugIcon, {}),
|
|
3575
3575
|
title: "Connect exchange",
|
|
3576
3576
|
subtitle: "Select an exchange to connect"
|
|
3577
3577
|
}
|
|
3578
3578
|
),
|
|
3579
|
-
loading && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-exchange-select-state", "aria-live": "polite", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3579
|
+
loading && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-exchange-select-state", "aria-live": "polite", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.Spinner, {}) }),
|
|
3580
3580
|
!loading && error && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-exchange-select-state", "aria-live": "polite", children: [
|
|
3581
3581
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-exchange-select-state-title", children: "Couldn\u2019t load exchanges" }),
|
|
3582
3582
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
@@ -3602,7 +3602,7 @@ function ExchangeSelectStep({
|
|
|
3602
3602
|
)
|
|
3603
3603
|
] }),
|
|
3604
3604
|
!loading && !error && exchanges.length > 0 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-exchange-grid", children: exchanges.map((exchange) => {
|
|
3605
|
-
const brand =
|
|
3605
|
+
const brand = _chunkPWLEBV5Vcjs.getExchangeLogo.call(void 0, exchange.name, exchange.connection);
|
|
3606
3606
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
3607
3607
|
"button",
|
|
3608
3608
|
{
|
|
@@ -3627,7 +3627,7 @@ function ExchangeSelectStep({
|
|
|
3627
3627
|
);
|
|
3628
3628
|
}) })
|
|
3629
3629
|
] }),
|
|
3630
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3630
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.PoweredBy, {}),
|
|
3631
3631
|
exchangeFeeBps > 0 && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "p", { className: "rs-exchange-select-fee-note", children: [
|
|
3632
3632
|
"A ",
|
|
3633
3633
|
formatFeeRate(exchangeFeeBps),
|
|
@@ -3665,7 +3665,7 @@ function SolanaTokenSelectStep({
|
|
|
3665
3665
|
setError(null);
|
|
3666
3666
|
const portfolioBySymbol = {};
|
|
3667
3667
|
try {
|
|
3668
|
-
|
|
3668
|
+
_chunkBRYNGLDMcjs.debugLog.call(void 0, debug, "solana-token-select", "portfolio:request", {
|
|
3669
3669
|
solanaAddress
|
|
3670
3670
|
});
|
|
3671
3671
|
const portfolio = await service.fetchSolanaPortfolio(solanaAddress);
|
|
@@ -3688,12 +3688,12 @@ function SolanaTokenSelectStep({
|
|
|
3688
3688
|
};
|
|
3689
3689
|
}
|
|
3690
3690
|
}
|
|
3691
|
-
|
|
3691
|
+
_chunkBRYNGLDMcjs.debugLog.call(void 0, debug, "solana-token-select", "portfolio:success", {
|
|
3692
3692
|
symbols: Object.keys(portfolioBySymbol)
|
|
3693
3693
|
});
|
|
3694
3694
|
} catch (err) {
|
|
3695
3695
|
if (!active) return;
|
|
3696
|
-
|
|
3696
|
+
_chunkBRYNGLDMcjs.debugError.call(void 0, debug, "solana-token-select", "portfolio:failure", err, {
|
|
3697
3697
|
solanaAddress
|
|
3698
3698
|
});
|
|
3699
3699
|
setError(
|
|
@@ -3740,7 +3740,7 @@ function SolanaTokenSelectStep({
|
|
|
3740
3740
|
const raw = _viem.formatUnits.call(void 0, entry.balance, entry.token.decimals);
|
|
3741
3741
|
const numeric = Number(raw);
|
|
3742
3742
|
if (!Number.isFinite(numeric)) return raw;
|
|
3743
|
-
return
|
|
3743
|
+
return _chunkBRYNGLDMcjs.tokenFormatter.format(numeric);
|
|
3744
3744
|
} catch (e22) {
|
|
3745
3745
|
return "--";
|
|
3746
3746
|
}
|
|
@@ -3750,20 +3750,20 @@ function SolanaTokenSelectStep({
|
|
|
3750
3750
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen", children: [
|
|
3751
3751
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen-body", children: [
|
|
3752
3752
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3753
|
-
|
|
3753
|
+
_chunkBRYNGLDMcjs.BodyHeader,
|
|
3754
3754
|
{
|
|
3755
|
-
icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3755
|
+
icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.WalletIcon, {}),
|
|
3756
3756
|
title: "Your assets",
|
|
3757
3757
|
subtitle: "Select source assets to transfer"
|
|
3758
3758
|
}
|
|
3759
3759
|
),
|
|
3760
3760
|
loading && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-loading-state", style: { padding: "40px 12px" }, children: [
|
|
3761
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3761
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.Spinner, { className: "rs-text-tertiary" }),
|
|
3762
3762
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-text-sm rs-text-tertiary", children: "Loading balances" })
|
|
3763
3763
|
] }),
|
|
3764
|
-
error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3764
|
+
error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.Callout, { variant: "error", children: error }),
|
|
3765
3765
|
!loading && !error && rows.length === 0 && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-empty-state", children: [
|
|
3766
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3766
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.WalletIcon, { className: "rs-empty-icon" }),
|
|
3767
3767
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-empty-text", children: "No funds in connected wallet" }),
|
|
3768
3768
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-empty-address", children: [
|
|
3769
3769
|
solanaAddress.slice(0, 6),
|
|
@@ -3794,13 +3794,13 @@ function SolanaTokenSelectStep({
|
|
|
3794
3794
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-asset-info", children: [
|
|
3795
3795
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-asset-icon-wrapper", children: [
|
|
3796
3796
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-asset-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3797
|
-
|
|
3797
|
+
_chunkBRYNGLDMcjs.TokenIcon,
|
|
3798
3798
|
{
|
|
3799
3799
|
symbol: entry.token.symbol,
|
|
3800
3800
|
fallback: entry.token.symbol.slice(0, 4)
|
|
3801
3801
|
}
|
|
3802
3802
|
) }),
|
|
3803
|
-
chainIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-asset-chain-badge", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3803
|
+
chainIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-asset-chain-badge", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CdnIcon, { src: chainIcon, alt: chainName }) })
|
|
3804
3804
|
] }),
|
|
3805
3805
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-asset-text", children: [
|
|
3806
3806
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-asset-name-row", children: [
|
|
@@ -3817,14 +3817,14 @@ function SolanaTokenSelectStep({
|
|
|
3817
3817
|
] })
|
|
3818
3818
|
] })
|
|
3819
3819
|
] }),
|
|
3820
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-asset-balance", children: entry.balanceUsd > 0 ?
|
|
3820
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-asset-balance", children: entry.balanceUsd > 0 ? _chunkBRYNGLDMcjs.currencyFormatter.format(entry.balanceUsd) : tokenAmount !== "--" ? `${tokenAmount} ${entry.token.symbol}` : "--" })
|
|
3821
3821
|
]
|
|
3822
3822
|
},
|
|
3823
3823
|
entry.token.symbol
|
|
3824
3824
|
);
|
|
3825
3825
|
}) }),
|
|
3826
3826
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3827
|
-
|
|
3827
|
+
_chunkBRYNGLDMcjs.Button,
|
|
3828
3828
|
{
|
|
3829
3829
|
onClick: () => selectedEntry && onContinue(
|
|
3830
3830
|
selectedEntry.token,
|
|
@@ -3837,7 +3837,7 @@ function SolanaTokenSelectStep({
|
|
|
3837
3837
|
}
|
|
3838
3838
|
)
|
|
3839
3839
|
] }),
|
|
3840
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
3840
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.PoweredBy, {})
|
|
3841
3841
|
] });
|
|
3842
3842
|
}
|
|
3843
3843
|
|
|
@@ -3889,7 +3889,7 @@ function SolanaAmountStep({
|
|
|
3889
3889
|
const raw = _viem.formatUnits.call(void 0, balance, token.decimals);
|
|
3890
3890
|
const numeric = Number(raw);
|
|
3891
3891
|
if (!Number.isFinite(numeric)) return raw;
|
|
3892
|
-
return
|
|
3892
|
+
return _chunkBRYNGLDMcjs.tokenFormatter.format(numeric);
|
|
3893
3893
|
} catch (e24) {
|
|
3894
3894
|
return "\u2026";
|
|
3895
3895
|
}
|
|
@@ -3982,7 +3982,7 @@ function SolanaAmountStep({
|
|
|
3982
3982
|
const handlePresetClick = (percentage) => {
|
|
3983
3983
|
const formatted = computePresetAmount(percentage);
|
|
3984
3984
|
if (!formatted) return;
|
|
3985
|
-
|
|
3985
|
+
_chunkBRYNGLDMcjs.debugLog.call(void 0, debug, "solana-amount", "amount:preset", {
|
|
3986
3986
|
percentage,
|
|
3987
3987
|
symbol: token.symbol,
|
|
3988
3988
|
formatted
|
|
@@ -4017,7 +4017,7 @@ function SolanaAmountStep({
|
|
|
4017
4017
|
try {
|
|
4018
4018
|
amountInUnits = _viem.parseUnits.call(void 0, sourceAmountStr, token.decimals);
|
|
4019
4019
|
} catch (e29) {
|
|
4020
|
-
|
|
4020
|
+
_chunkBRYNGLDMcjs.debugLog.call(void 0, debug, "solana-amount", "amount:invalid", {
|
|
4021
4021
|
amount,
|
|
4022
4022
|
sourceAmount: sourceAmountStr,
|
|
4023
4023
|
reason: "parse-units-failed"
|
|
@@ -4032,7 +4032,7 @@ function SolanaAmountStep({
|
|
|
4032
4032
|
);
|
|
4033
4033
|
return;
|
|
4034
4034
|
}
|
|
4035
|
-
|
|
4035
|
+
_chunkBRYNGLDMcjs.debugLog.call(void 0, debug, "solana-amount", "amount:continue", {
|
|
4036
4036
|
symbol: token.symbol,
|
|
4037
4037
|
inputAmountUsd: amount,
|
|
4038
4038
|
sourceAmount: sourceAmountStr,
|
|
@@ -4045,7 +4045,7 @@ function SolanaAmountStep({
|
|
|
4045
4045
|
const continueDisabled = exceedsBalance || numericAmount === 0 && !isBelowMin;
|
|
4046
4046
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen", children: [
|
|
4047
4047
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen-body rs-screen-body--gap-32", children: [
|
|
4048
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4048
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.BodyHeader, { icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.WalletIcon, {}), title: "Wallet deposit" }),
|
|
4049
4049
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-amount-section", children: [
|
|
4050
4050
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-amount-display", children: [
|
|
4051
4051
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
@@ -4065,13 +4065,13 @@ function SolanaAmountStep({
|
|
|
4065
4065
|
" available",
|
|
4066
4066
|
computedBalanceUsd !== null && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
|
|
4067
4067
|
" (~",
|
|
4068
|
-
|
|
4068
|
+
_chunkBRYNGLDMcjs.currencyFormatter.format(computedBalanceUsd),
|
|
4069
4069
|
")"
|
|
4070
4070
|
] })
|
|
4071
4071
|
] }),
|
|
4072
4072
|
minDepositUsd !== null && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-amount-meta-minimum", children: [
|
|
4073
4073
|
"Min. deposit ",
|
|
4074
|
-
|
|
4074
|
+
_chunkBRYNGLDMcjs.currencyFormatter.format(minDepositUsd)
|
|
4075
4075
|
] })
|
|
4076
4076
|
] })
|
|
4077
4077
|
] }),
|
|
@@ -4094,7 +4094,7 @@ function SolanaAmountStep({
|
|
|
4094
4094
|
"Solana ",
|
|
4095
4095
|
token.symbol
|
|
4096
4096
|
] }),
|
|
4097
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4097
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.TokenIcon, { symbol: token.symbol }) })
|
|
4098
4098
|
] })
|
|
4099
4099
|
] }),
|
|
4100
4100
|
targetChainName && targetTokenSymbol && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-amount-detail-row", children: [
|
|
@@ -4105,17 +4105,17 @@ function SolanaAmountStep({
|
|
|
4105
4105
|
" ",
|
|
4106
4106
|
targetTokenSymbol
|
|
4107
4107
|
] }),
|
|
4108
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4108
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.TokenIcon, { symbol: targetTokenSymbol }) })
|
|
4109
4109
|
] })
|
|
4110
4110
|
] }),
|
|
4111
4111
|
balanceAfterUsd !== null && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-amount-detail-row", children: [
|
|
4112
4112
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: "Balance after deposit" }),
|
|
4113
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-value", children:
|
|
4113
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-value", children: _chunkBRYNGLDMcjs.currencyFormatter.format(balanceAfterUsd) })
|
|
4114
4114
|
] })
|
|
4115
4115
|
] }),
|
|
4116
|
-
error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4116
|
+
error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.Callout, { variant: "error", children: error }),
|
|
4117
4117
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4118
|
-
|
|
4118
|
+
_chunkBRYNGLDMcjs.Button,
|
|
4119
4119
|
{
|
|
4120
4120
|
onClick: handleContinue,
|
|
4121
4121
|
fullWidth: true,
|
|
@@ -4124,7 +4124,7 @@ function SolanaAmountStep({
|
|
|
4124
4124
|
}
|
|
4125
4125
|
)
|
|
4126
4126
|
] }),
|
|
4127
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4127
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.PoweredBy, {})
|
|
4128
4128
|
] });
|
|
4129
4129
|
}
|
|
4130
4130
|
|
|
@@ -4147,10 +4147,10 @@ var _spltoken = require('@solana/spl-token');
|
|
|
4147
4147
|
var DEFAULT_SOLANA_RPC_URL = "https://api.mainnet.solana.com";
|
|
4148
4148
|
var cachedConnections = /* @__PURE__ */ new Map();
|
|
4149
4149
|
function getSolanaRpcUrl(rpcUrls) {
|
|
4150
|
-
return _nullishCoalesce(
|
|
4150
|
+
return _nullishCoalesce(_chunkBRYNGLDMcjs.rpcUrlFor.call(void 0, rpcUrls, "solana"), () => ( DEFAULT_SOLANA_RPC_URL));
|
|
4151
4151
|
}
|
|
4152
4152
|
function hasConfiguredSolanaRpcUrl(rpcUrls) {
|
|
4153
|
-
return
|
|
4153
|
+
return _chunkBRYNGLDMcjs.rpcUrlFor.call(void 0, rpcUrls, "solana") !== void 0;
|
|
4154
4154
|
}
|
|
4155
4155
|
function getSolanaConnection(rpcUrls) {
|
|
4156
4156
|
const rpcUrl = getSolanaRpcUrl(rpcUrls);
|
|
@@ -4252,7 +4252,7 @@ function SolanaConfirmStep({
|
|
|
4252
4252
|
onError,
|
|
4253
4253
|
debug
|
|
4254
4254
|
}) {
|
|
4255
|
-
const rpcUrls =
|
|
4255
|
+
const rpcUrls = _chunkBRYNGLDMcjs.useRpcUrls.call(void 0, );
|
|
4256
4256
|
const [isSubmitting, setIsSubmitting] = _react.useState.call(void 0, false);
|
|
4257
4257
|
const [error, setError] = _react.useState.call(void 0, null);
|
|
4258
4258
|
const targetChainId = _chunkO7BCVQ6Lcjs.targetChainToChainId.call(void 0, targetChain);
|
|
@@ -4263,26 +4263,26 @@ function SolanaConfirmStep({
|
|
|
4263
4263
|
const targetChainIcon = _chunkO7BCVQ6Lcjs.getChainIcon.call(void 0, targetChainId);
|
|
4264
4264
|
const feeSponsored = _nullishCoalesce(_optionalChain([uiConfig, 'optionalAccess', _145 => _145.feeSponsored]), () => ( false));
|
|
4265
4265
|
const feeTooltip = _nullishCoalesce(_optionalChain([uiConfig, 'optionalAccess', _146 => _146.feeTooltip]), () => ( (feeSponsored ? "Network fees are sponsored for this deposit." : "Network fees apply.")));
|
|
4266
|
-
const formattedAmount = sourceAmount && Number.isFinite(Number(sourceAmount)) ? _nullishCoalesce(
|
|
4266
|
+
const formattedAmount = sourceAmount && Number.isFinite(Number(sourceAmount)) ? _nullishCoalesce(_chunkBRYNGLDMcjs.formatTokenAmount.call(void 0, Number(sourceAmount), token.symbol), () => ( "0")) : "0";
|
|
4267
4267
|
const receiveDisplay = (() => {
|
|
4268
4268
|
const usdValue = Number(targetAmount);
|
|
4269
4269
|
const sourceAmountUsd = Number.isFinite(usdValue) && usdValue > 0 ? usdValue : void 0;
|
|
4270
|
-
const estimate =
|
|
4270
|
+
const estimate = _chunkBRYNGLDMcjs.formatReceiveEstimate.call(void 0, {
|
|
4271
4271
|
sourceAmount: Number.isFinite(Number(sourceAmount)) ? Number(sourceAmount) : void 0,
|
|
4272
4272
|
sourceSymbol: token.symbol,
|
|
4273
4273
|
targetSymbol,
|
|
4274
4274
|
sourceAmountUsd,
|
|
4275
|
-
sourceTrusted:
|
|
4275
|
+
sourceTrusted: _chunkBRYNGLDMcjs.isRecognizedToken.call(void 0, token.mint, "solana"),
|
|
4276
4276
|
// Curated stablecoin target estimates at $1 when unquoted; never applied
|
|
4277
4277
|
// to the source (a held token). See ConfirmStep for the rationale.
|
|
4278
|
-
prices: targetTokenPriceUsd !== null && targetTokenPriceUsd > 0 ? { [targetSymbol.toUpperCase()]: targetTokenPriceUsd } :
|
|
4278
|
+
prices: targetTokenPriceUsd !== null && targetTokenPriceUsd > 0 ? { [targetSymbol.toUpperCase()]: targetTokenPriceUsd } : _chunkBRYNGLDMcjs.isDisplayStablecoinSymbol.call(void 0, targetSymbol) ? { [targetSymbol.toUpperCase()]: 1 } : {}
|
|
4279
4279
|
});
|
|
4280
4280
|
if (estimate !== void 0) return estimate;
|
|
4281
4281
|
return targetSymbol;
|
|
4282
4282
|
})();
|
|
4283
4283
|
const handleConfirm = async () => {
|
|
4284
4284
|
if (!solanaProvider) {
|
|
4285
|
-
|
|
4285
|
+
_chunkBRYNGLDMcjs.debugLog.call(void 0, debug, "solana-confirm", "submit:blocked", {
|
|
4286
4286
|
reason: "missing-provider"
|
|
4287
4287
|
});
|
|
4288
4288
|
setError("Solana wallet not connected");
|
|
@@ -4290,7 +4290,7 @@ function SolanaConfirmStep({
|
|
|
4290
4290
|
}
|
|
4291
4291
|
const parsedAmount = parseFloat(sourceAmount);
|
|
4292
4292
|
if (isNaN(parsedAmount) || parsedAmount <= 0) {
|
|
4293
|
-
|
|
4293
|
+
_chunkBRYNGLDMcjs.debugLog.call(void 0, debug, "solana-confirm", "submit:blocked", {
|
|
4294
4294
|
reason: "invalid-amount",
|
|
4295
4295
|
sourceAmount
|
|
4296
4296
|
});
|
|
@@ -4299,7 +4299,7 @@ function SolanaConfirmStep({
|
|
|
4299
4299
|
}
|
|
4300
4300
|
setError(null);
|
|
4301
4301
|
setIsSubmitting(true);
|
|
4302
|
-
|
|
4302
|
+
_chunkBRYNGLDMcjs.debugLog.call(void 0, debug, "solana-confirm", "submit:start", {
|
|
4303
4303
|
smartAccount,
|
|
4304
4304
|
solanaAddress,
|
|
4305
4305
|
solanaDepositAddress,
|
|
@@ -4309,7 +4309,7 @@ function SolanaConfirmStep({
|
|
|
4309
4309
|
});
|
|
4310
4310
|
try {
|
|
4311
4311
|
const check = await service.checkAccount(smartAccount);
|
|
4312
|
-
|
|
4312
|
+
_chunkBRYNGLDMcjs.debugLog.call(void 0, debug, "solana-confirm", "check:success", {
|
|
4313
4313
|
smartAccount,
|
|
4314
4314
|
isRegistered: check.isRegistered,
|
|
4315
4315
|
targetChain: check.targetChain,
|
|
@@ -4322,7 +4322,7 @@ function SolanaConfirmStep({
|
|
|
4322
4322
|
}
|
|
4323
4323
|
const connection = hasConfiguredSolanaRpcUrl(rpcUrls) ? getSolanaConnection(rpcUrls) : _nullishCoalesce(solanaConnection, () => ( getSolanaConnection(rpcUrls)));
|
|
4324
4324
|
const amountUnits = _viem.parseUnits.call(void 0, sourceAmount, token.decimals);
|
|
4325
|
-
|
|
4325
|
+
_chunkBRYNGLDMcjs.debugLog.call(void 0, debug, "solana-confirm", "tx:build:start", {
|
|
4326
4326
|
token: token.symbol,
|
|
4327
4327
|
sourceAmount,
|
|
4328
4328
|
amountUnits: amountUnits.toString()
|
|
@@ -4339,7 +4339,7 @@ function SolanaConfirmStep({
|
|
|
4339
4339
|
token.mint,
|
|
4340
4340
|
amountUnits
|
|
4341
4341
|
);
|
|
4342
|
-
|
|
4342
|
+
_chunkBRYNGLDMcjs.debugLog.call(void 0, debug, "solana-confirm", "tx:build:success", {
|
|
4343
4343
|
token: token.symbol,
|
|
4344
4344
|
instructionCount: transaction.instructions.length,
|
|
4345
4345
|
feePayer: _optionalChain([transaction, 'access', _147 => _147.feePayer, 'optionalAccess', _148 => _148.toBase58, 'call', _149 => _149()]),
|
|
@@ -4350,7 +4350,7 @@ function SolanaConfirmStep({
|
|
|
4350
4350
|
connection,
|
|
4351
4351
|
transaction
|
|
4352
4352
|
);
|
|
4353
|
-
|
|
4353
|
+
_chunkBRYNGLDMcjs.debugLog.call(void 0, debug, "solana-confirm", "tx:sent", {
|
|
4354
4354
|
txHash,
|
|
4355
4355
|
amountUnits: amountUnits.toString()
|
|
4356
4356
|
});
|
|
@@ -4362,8 +4362,8 @@ function SolanaConfirmStep({
|
|
|
4362
4362
|
});
|
|
4363
4363
|
} catch (err) {
|
|
4364
4364
|
const raw = err instanceof Error ? err.message : "Transfer failed";
|
|
4365
|
-
const message =
|
|
4366
|
-
|
|
4365
|
+
const message = _chunkBRYNGLDMcjs.formatUserError.call(void 0, raw);
|
|
4366
|
+
_chunkBRYNGLDMcjs.debugError.call(void 0, debug, "solana-confirm", "submit:failure", err, {
|
|
4367
4367
|
smartAccount,
|
|
4368
4368
|
token: token.symbol,
|
|
4369
4369
|
sourceAmount
|
|
@@ -4376,20 +4376,20 @@ function SolanaConfirmStep({
|
|
|
4376
4376
|
};
|
|
4377
4377
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen", children: [
|
|
4378
4378
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen-body rs-screen-body--gap-32", children: [
|
|
4379
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4379
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.BodyHeader, { icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.WalletIcon, {}), title: "Review deposit" }),
|
|
4380
4380
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-review-details", children: [
|
|
4381
4381
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-review-detail-row", children: [
|
|
4382
4382
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: "Source chain" }),
|
|
4383
4383
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-review-detail-value", children: [
|
|
4384
4384
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: sourceChainName }),
|
|
4385
|
-
sourceChainIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4385
|
+
sourceChainIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CdnIcon, { src: sourceChainIcon }) })
|
|
4386
4386
|
] })
|
|
4387
4387
|
] }),
|
|
4388
4388
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-review-detail-row", children: [
|
|
4389
4389
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: "Destination chain" }),
|
|
4390
4390
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-review-detail-value", children: [
|
|
4391
4391
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: targetChainName }),
|
|
4392
|
-
targetChainIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4392
|
+
targetChainIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CdnIcon, { src: targetChainIcon }) })
|
|
4393
4393
|
] })
|
|
4394
4394
|
] }),
|
|
4395
4395
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-review-detail-row", children: [
|
|
@@ -4404,14 +4404,14 @@ function SolanaConfirmStep({
|
|
|
4404
4404
|
" ",
|
|
4405
4405
|
token.symbol
|
|
4406
4406
|
] }),
|
|
4407
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4407
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.TokenIcon, { symbol: token.symbol }) })
|
|
4408
4408
|
] })
|
|
4409
4409
|
] }),
|
|
4410
4410
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-review-detail-row", children: [
|
|
4411
4411
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: "Receive" }),
|
|
4412
4412
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-review-detail-value", children: [
|
|
4413
4413
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: receiveDisplay }),
|
|
4414
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4414
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.TokenIcon, { symbol: targetSymbol }) })
|
|
4415
4415
|
] })
|
|
4416
4416
|
] }),
|
|
4417
4417
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-review-detail-row", children: [
|
|
@@ -4424,13 +4424,13 @@ function SolanaConfirmStep({
|
|
|
4424
4424
|
children: "$0.04"
|
|
4425
4425
|
}
|
|
4426
4426
|
),
|
|
4427
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4427
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkPWLEBV5Vcjs.Tooltip, { content: feeTooltip, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-info", "aria-label": "Fee info", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.InfoIcon, {}) }) })
|
|
4428
4428
|
] })
|
|
4429
4429
|
] })
|
|
4430
4430
|
] }),
|
|
4431
|
-
error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4431
|
+
error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.Callout, { variant: "error", children: error }),
|
|
4432
4432
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4433
|
-
|
|
4433
|
+
_chunkBRYNGLDMcjs.Button,
|
|
4434
4434
|
{
|
|
4435
4435
|
onClick: handleConfirm,
|
|
4436
4436
|
loading: isSubmitting,
|
|
@@ -4441,7 +4441,7 @@ function SolanaConfirmStep({
|
|
|
4441
4441
|
}
|
|
4442
4442
|
)
|
|
4443
4443
|
] }),
|
|
4444
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4444
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.PoweredBy, {})
|
|
4445
4445
|
] });
|
|
4446
4446
|
}
|
|
4447
4447
|
|
|
@@ -4456,19 +4456,19 @@ function DappImportAssetSelectStep({
|
|
|
4456
4456
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen", children: [
|
|
4457
4457
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen-body rs-screen-body--gap-32", children: [
|
|
4458
4458
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4459
|
-
|
|
4459
|
+
_chunkBRYNGLDMcjs.BodyHeader,
|
|
4460
4460
|
{
|
|
4461
|
-
icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4461
|
+
icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.WalletIcon, {}),
|
|
4462
4462
|
title: `Transfer from ${sourceLabel}`,
|
|
4463
4463
|
subtitle: "Pick the balance to import"
|
|
4464
4464
|
}
|
|
4465
4465
|
),
|
|
4466
4466
|
incompleteSummary && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-asset-notice", role: "status", children: incompleteSummary }),
|
|
4467
4467
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-asset-list", children: assets.map((asset) => {
|
|
4468
|
-
const tokenAmount = asset.balance ?
|
|
4468
|
+
const tokenAmount = asset.balance ? _chunkBRYNGLDMcjs.tokenFormatter.format(
|
|
4469
4469
|
Number(asset.balance) / 10 ** asset.decimals
|
|
4470
4470
|
) : "0";
|
|
4471
|
-
const balanceUsd = asset.balanceUsd && asset.balanceUsd > 0 ?
|
|
4471
|
+
const balanceUsd = asset.balanceUsd && asset.balanceUsd > 0 ? _chunkBRYNGLDMcjs.currencyFormatter.format(asset.balanceUsd) : `${tokenAmount} ${asset.symbol}`;
|
|
4472
4472
|
const assetIcon = asset.icon;
|
|
4473
4473
|
const chainIcon = _chunkO7BCVQ6Lcjs.getChainIcon.call(void 0, asset.chainId);
|
|
4474
4474
|
const badge = _chunkO7BCVQ6Lcjs.getChainBadge.call(void 0, asset.chainId);
|
|
@@ -4481,14 +4481,14 @@ function DappImportAssetSelectStep({
|
|
|
4481
4481
|
children: [
|
|
4482
4482
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-asset-info", children: [
|
|
4483
4483
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-asset-icon-wrapper", children: [
|
|
4484
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-asset-icon", children: assetIcon ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4485
|
-
|
|
4484
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-asset-icon", children: assetIcon ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CdnIcon, { src: assetIcon, alt: asset.symbol }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4485
|
+
_chunkBRYNGLDMcjs.TokenIcon,
|
|
4486
4486
|
{
|
|
4487
4487
|
symbol: asset.symbol,
|
|
4488
4488
|
fallback: asset.symbol.slice(0, 4)
|
|
4489
4489
|
}
|
|
4490
4490
|
) }),
|
|
4491
|
-
chainIcon ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-asset-chain-badge", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4491
|
+
chainIcon ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-asset-chain-badge", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CdnIcon, { src: chainIcon, alt: _chunkO7BCVQ6Lcjs.getChainName.call(void 0, asset.chainId) }) }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4492
4492
|
"span",
|
|
4493
4493
|
{
|
|
4494
4494
|
className: "rs-asset-chain-badge",
|
|
@@ -4520,7 +4520,7 @@ function DappImportAssetSelectStep({
|
|
|
4520
4520
|
);
|
|
4521
4521
|
}) })
|
|
4522
4522
|
] }),
|
|
4523
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4523
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.PoweredBy, {})
|
|
4524
4524
|
] });
|
|
4525
4525
|
}
|
|
4526
4526
|
DappImportAssetSelectStep.displayName = "DappImportAssetSelectStep";
|
|
@@ -4542,7 +4542,7 @@ function describeRow(status, comingSoon) {
|
|
|
4542
4542
|
}
|
|
4543
4543
|
if (status.enabled) {
|
|
4544
4544
|
return {
|
|
4545
|
-
subtitle: status.balanceUsd > 0 ?
|
|
4545
|
+
subtitle: status.balanceUsd > 0 ? _chunkBRYNGLDMcjs.currencyFormatter.format(status.balanceUsd) : "No balance",
|
|
4546
4546
|
disabled: false,
|
|
4547
4547
|
busy: false
|
|
4548
4548
|
};
|
|
@@ -4565,9 +4565,9 @@ function DappImportSelectStep({
|
|
|
4565
4565
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen", children: [
|
|
4566
4566
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen-body rs-screen-body--gap-32", children: [
|
|
4567
4567
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4568
|
-
|
|
4568
|
+
_chunkBRYNGLDMcjs.BodyHeader,
|
|
4569
4569
|
{
|
|
4570
|
-
icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4570
|
+
icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.MigrateAssetsIcon, {}),
|
|
4571
4571
|
title: "Migrate assets",
|
|
4572
4572
|
subtitle: "Select a position to migrate"
|
|
4573
4573
|
}
|
|
@@ -4579,13 +4579,13 @@ function DappImportSelectStep({
|
|
|
4579
4579
|
Boolean(brand.comingSoon)
|
|
4580
4580
|
);
|
|
4581
4581
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4582
|
-
|
|
4582
|
+
_chunkHL5NUKZWcjs.ListRow,
|
|
4583
4583
|
{
|
|
4584
4584
|
leadingMedia: brand.iconUrl,
|
|
4585
4585
|
title: brand.label,
|
|
4586
4586
|
subtitle,
|
|
4587
4587
|
disabled,
|
|
4588
|
-
trailing: busy ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4588
|
+
trailing: busy ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.Spinner, { className: "rs-spinner--sm" }) : void 0,
|
|
4589
4589
|
onClick: () => {
|
|
4590
4590
|
if (status === "needs-connect") {
|
|
4591
4591
|
_optionalChain([onRequestConnect, 'optionalCall', _151 => _151()]);
|
|
@@ -4598,7 +4598,7 @@ function DappImportSelectStep({
|
|
|
4598
4598
|
);
|
|
4599
4599
|
}) })
|
|
4600
4600
|
] }),
|
|
4601
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4601
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.PoweredBy, {})
|
|
4602
4602
|
] });
|
|
4603
4603
|
}
|
|
4604
4604
|
DappImportSelectStep.displayName = "DappImportSelectStep";
|
|
@@ -4615,9 +4615,9 @@ function DappImportAssetSelectSkeleton({
|
|
|
4615
4615
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-sr-only", role: "status", children: error ? "Couldn't load balances" : "Loading balances\u2026" }),
|
|
4616
4616
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen-body rs-screen-body--gap-32", children: [
|
|
4617
4617
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4618
|
-
|
|
4618
|
+
_chunkBRYNGLDMcjs.BodyHeader,
|
|
4619
4619
|
{
|
|
4620
|
-
icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4620
|
+
icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.WalletIcon, {}),
|
|
4621
4621
|
title: `Transfer from ${sourceLabel}`,
|
|
4622
4622
|
subtitle: "Pick the balance to import"
|
|
4623
4623
|
}
|
|
@@ -4655,7 +4655,7 @@ function DappImportAssetSelectSkeleton({
|
|
|
4655
4655
|
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: "Try again" })
|
|
4656
4656
|
}
|
|
4657
4657
|
) }),
|
|
4658
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
4658
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.PoweredBy, {})
|
|
4659
4659
|
] });
|
|
4660
4660
|
}
|
|
4661
4661
|
DappImportAssetSelectSkeleton.displayName = "DappImportAssetSelectSkeleton";
|
|
@@ -6458,11 +6458,11 @@ function DepositFlow({
|
|
|
6458
6458
|
onError,
|
|
6459
6459
|
debug
|
|
6460
6460
|
}) {
|
|
6461
|
-
const rpcUrls =
|
|
6462
|
-
const onStepChangeRef =
|
|
6463
|
-
const onEventRef =
|
|
6464
|
-
const onLifecycleRef =
|
|
6465
|
-
const onErrorRef =
|
|
6461
|
+
const rpcUrls = _chunkBRYNGLDMcjs.useRpcUrls.call(void 0, );
|
|
6462
|
+
const onStepChangeRef = _chunkBRYNGLDMcjs.useLatestRef.call(void 0, onStepChange);
|
|
6463
|
+
const onEventRef = _chunkBRYNGLDMcjs.useLatestRef.call(void 0, onEvent);
|
|
6464
|
+
const onLifecycleRef = _chunkBRYNGLDMcjs.useLatestRef.call(void 0, onLifecycle);
|
|
6465
|
+
const onErrorRef = _chunkBRYNGLDMcjs.useLatestRef.call(void 0, onError);
|
|
6466
6466
|
const storeApi = useDepositStoreApi();
|
|
6467
6467
|
const flowSlice = useDepositStore((s) => s.flow);
|
|
6468
6468
|
const depositSlice = useDepositStore((s) => s.deposit);
|
|
@@ -6479,13 +6479,13 @@ function DepositFlow({
|
|
|
6479
6479
|
const stableWalletSelectionKeyRef = _react.useRef.call(void 0, null);
|
|
6480
6480
|
const logFlow = _react.useCallback.call(void 0,
|
|
6481
6481
|
(message, data) => {
|
|
6482
|
-
|
|
6482
|
+
_chunkBRYNGLDMcjs.debugLog.call(void 0, debug, "deposit-flow", message, data);
|
|
6483
6483
|
},
|
|
6484
6484
|
[debug]
|
|
6485
6485
|
);
|
|
6486
6486
|
const logFlowError = _react.useCallback.call(void 0,
|
|
6487
6487
|
(message, error, data) => {
|
|
6488
|
-
|
|
6488
|
+
_chunkBRYNGLDMcjs.debugError.call(void 0, debug, "deposit-flow", message, error, data);
|
|
6489
6489
|
},
|
|
6490
6490
|
[debug]
|
|
6491
6491
|
);
|
|
@@ -6618,7 +6618,7 @@ function DepositFlow({
|
|
|
6618
6618
|
return;
|
|
6619
6619
|
}
|
|
6620
6620
|
let cancelled = false;
|
|
6621
|
-
|
|
6621
|
+
_chunkPWLEBV5Vcjs.fetchTokenPriceUsd.call(void 0, service, {
|
|
6622
6622
|
chainId: targetChainId,
|
|
6623
6623
|
address: targetToken,
|
|
6624
6624
|
symbol: targetSymbol
|
|
@@ -6639,7 +6639,7 @@ function DepositFlow({
|
|
|
6639
6639
|
return {
|
|
6640
6640
|
ownerAddress: walletClientProp.account.address,
|
|
6641
6641
|
walletClient: walletClientProp,
|
|
6642
|
-
publicClient: _nullishCoalesce(publicClientProp, () => (
|
|
6642
|
+
publicClient: _nullishCoalesce(publicClientProp, () => ( _chunkBRYNGLDMcjs.getPublicClient.call(void 0, fallbackChainId, rpcUrls))),
|
|
6643
6643
|
switchChain: dappSwitchChain
|
|
6644
6644
|
};
|
|
6645
6645
|
}
|
|
@@ -6656,7 +6656,7 @@ function DepositFlow({
|
|
|
6656
6656
|
return {
|
|
6657
6657
|
ownerAddress: walletClientProp.account.address,
|
|
6658
6658
|
walletClient: walletClientProp,
|
|
6659
|
-
publicClient: _nullishCoalesce(publicClientProp, () => (
|
|
6659
|
+
publicClient: _nullishCoalesce(publicClientProp, () => ( _chunkBRYNGLDMcjs.getPublicClient.call(void 0, fallbackChainId, rpcUrls))),
|
|
6660
6660
|
switchChain: dappSwitchChain
|
|
6661
6661
|
};
|
|
6662
6662
|
}
|
|
@@ -6664,7 +6664,7 @@ function DepositFlow({
|
|
|
6664
6664
|
return {
|
|
6665
6665
|
ownerAddress: reownWallet.address,
|
|
6666
6666
|
walletClient: reownWallet.walletClient,
|
|
6667
|
-
publicClient: _nullishCoalesce(reownWallet.publicClient, () => (
|
|
6667
|
+
publicClient: _nullishCoalesce(reownWallet.publicClient, () => ( _chunkBRYNGLDMcjs.getPublicClient.call(void 0, setupChainId, rpcUrls))),
|
|
6668
6668
|
switchChain: reownWallet.switchChain
|
|
6669
6669
|
};
|
|
6670
6670
|
}
|
|
@@ -7019,7 +7019,7 @@ function DepositFlow({
|
|
|
7019
7019
|
eoa: dappImportOwner,
|
|
7020
7020
|
getPublicClient: (chainId) => {
|
|
7021
7021
|
try {
|
|
7022
|
-
return
|
|
7022
|
+
return _chunkBRYNGLDMcjs.getPublicClient.call(void 0, chainId, rpcUrls);
|
|
7023
7023
|
} catch (e33) {
|
|
7024
7024
|
return null;
|
|
7025
7025
|
}
|
|
@@ -7244,7 +7244,7 @@ function DepositFlow({
|
|
|
7244
7244
|
acceptedExchangeFeeBps: disclosedFeeBps
|
|
7245
7245
|
});
|
|
7246
7246
|
} catch (error) {
|
|
7247
|
-
if (error instanceof
|
|
7247
|
+
if (error instanceof _chunkBRYNGLDMcjs.SwappedConnectFeeChangedError) {
|
|
7248
7248
|
return error.exchangeFeeBps;
|
|
7249
7249
|
}
|
|
7250
7250
|
throw error;
|
|
@@ -7495,17 +7495,17 @@ function DepositFlow({
|
|
|
7495
7495
|
forceRegister
|
|
7496
7496
|
]
|
|
7497
7497
|
);
|
|
7498
|
-
const desiredSetupRequestKey =
|
|
7498
|
+
const desiredSetupRequestKey = _chunkPWLEBV5Vcjs.computeRequestKey.call(void 0, setupInput);
|
|
7499
7499
|
const setupReady = setupSlice.status === "ready" && setupSlice.requestKey === desiredSetupRequestKey;
|
|
7500
7500
|
_react.useEffect.call(void 0, () => {
|
|
7501
7501
|
void (async () => {
|
|
7502
|
-
const requestKey =
|
|
7503
|
-
const cacheKey =
|
|
7504
|
-
const cacheable =
|
|
7502
|
+
const requestKey = _chunkPWLEBV5Vcjs.computeRequestKey.call(void 0, setupInput);
|
|
7503
|
+
const cacheKey = _chunkPWLEBV5Vcjs.computeCacheKey.call(void 0, setupInput);
|
|
7504
|
+
const cacheable = _chunkPWLEBV5Vcjs.computeIsCacheable.call(void 0, setupInput);
|
|
7505
7505
|
if (storeApi.getState().setup.requestKey === requestKey) {
|
|
7506
7506
|
return;
|
|
7507
7507
|
}
|
|
7508
|
-
const dedupedResult =
|
|
7508
|
+
const dedupedResult = _chunkPWLEBV5Vcjs.readDedupedAccountSetupResult.call(void 0, requestKey);
|
|
7509
7509
|
if (dedupedResult) {
|
|
7510
7510
|
storeApi.dispatch({
|
|
7511
7511
|
type: "setup/started",
|
|
@@ -7531,7 +7531,7 @@ function DepositFlow({
|
|
|
7531
7531
|
cacheable
|
|
7532
7532
|
});
|
|
7533
7533
|
try {
|
|
7534
|
-
const result = await
|
|
7534
|
+
const result = await _chunkPWLEBV5Vcjs.runAccountSetupDeduped.call(void 0,
|
|
7535
7535
|
setupInput,
|
|
7536
7536
|
{ service, debug },
|
|
7537
7537
|
requestKey
|
|
@@ -7546,7 +7546,7 @@ function DepositFlow({
|
|
|
7546
7546
|
}
|
|
7547
7547
|
});
|
|
7548
7548
|
} catch (error) {
|
|
7549
|
-
const message = error instanceof
|
|
7549
|
+
const message = error instanceof _chunkPWLEBV5Vcjs.SetupError ? error.message : "Deposit service is temporarily unavailable. Please try again shortly.";
|
|
7550
7550
|
storeApi.dispatch({
|
|
7551
7551
|
type: "setup/failed",
|
|
7552
7552
|
requestKey,
|
|
@@ -7595,7 +7595,7 @@ function DepositFlow({
|
|
|
7595
7595
|
address,
|
|
7596
7596
|
requestId,
|
|
7597
7597
|
totalUsd: portfolio.totalUsd,
|
|
7598
|
-
chainIds:
|
|
7598
|
+
chainIds: _chunkBRYNGLDMcjs.chainIdsByValue.call(void 0, portfolio.tokens)
|
|
7599
7599
|
});
|
|
7600
7600
|
} catch (e34) {
|
|
7601
7601
|
storeApi.dispatch({
|
|
@@ -8037,7 +8037,7 @@ function DepositFlow({
|
|
|
8037
8037
|
}
|
|
8038
8038
|
),
|
|
8039
8039
|
step.type === "processing" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
8040
|
-
|
|
8040
|
+
_chunkPWLEBV5Vcjs.ProcessingStep,
|
|
8041
8041
|
{
|
|
8042
8042
|
smartAccount: step.smartAccount,
|
|
8043
8043
|
solanaDepositAddress: step.solanaDepositAddress,
|
|
@@ -8109,7 +8109,7 @@ function DepositFlow({
|
|
|
8109
8109
|
}
|
|
8110
8110
|
),
|
|
8111
8111
|
step.type === "processing" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
8112
|
-
|
|
8112
|
+
_chunkPWLEBV5Vcjs.ProcessingStep,
|
|
8113
8113
|
{
|
|
8114
8114
|
smartAccount: step.smartAccount,
|
|
8115
8115
|
solanaDepositAddress: step.solanaDepositAddress,
|
|
@@ -8238,7 +8238,7 @@ function DepositFlow({
|
|
|
8238
8238
|
) })
|
|
8239
8239
|
] }) : null,
|
|
8240
8240
|
effectiveStep.type === "processing" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
8241
|
-
|
|
8241
|
+
_chunkPWLEBV5Vcjs.ProcessingStep,
|
|
8242
8242
|
{
|
|
8243
8243
|
smartAccount: effectiveStep.smartAccount,
|
|
8244
8244
|
solanaDepositAddress: effectiveStep.solanaDepositAddress,
|
|
@@ -8325,7 +8325,7 @@ function DepositFlow({
|
|
|
8325
8325
|
if (_optionalChain([signerContext, 'access', _271 => _271.publicClient, 'access', _272 => _272.chain, 'optionalAccess', _273 => _273.id]) === chainId) {
|
|
8326
8326
|
return signerContext.publicClient;
|
|
8327
8327
|
}
|
|
8328
|
-
return
|
|
8328
|
+
return _chunkBRYNGLDMcjs.getPublicClient.call(void 0, chainId, rpcUrls);
|
|
8329
8329
|
};
|
|
8330
8330
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-modal-body", children: [
|
|
8331
8331
|
effectiveStep.type === "setup" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
@@ -8436,7 +8436,7 @@ function DepositFlow({
|
|
|
8436
8436
|
}
|
|
8437
8437
|
),
|
|
8438
8438
|
effectiveStep.type === "processing" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
8439
|
-
|
|
8439
|
+
_chunkPWLEBV5Vcjs.ProcessingStep,
|
|
8440
8440
|
{
|
|
8441
8441
|
smartAccount: effectiveStep.smartAccount,
|
|
8442
8442
|
solanaDepositAddress: effectiveStep.solanaDepositAddress,
|
|
@@ -8614,7 +8614,7 @@ function DepositHistoryPanel({
|
|
|
8614
8614
|
className: "rs-modal-header-back",
|
|
8615
8615
|
"aria-label": "Back",
|
|
8616
8616
|
onClick: onClose,
|
|
8617
|
-
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
8617
|
+
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.ChevronLeftIcon, {})
|
|
8618
8618
|
}
|
|
8619
8619
|
) }),
|
|
8620
8620
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-modal-header-nav-right", children: onCloseModal && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
@@ -8624,29 +8624,29 @@ function DepositHistoryPanel({
|
|
|
8624
8624
|
className: "rs-modal-close",
|
|
8625
8625
|
"aria-label": "Close",
|
|
8626
8626
|
onClick: onCloseModal,
|
|
8627
|
-
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
8627
|
+
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CloseIcon, {})
|
|
8628
8628
|
}
|
|
8629
8629
|
) })
|
|
8630
8630
|
] }),
|
|
8631
8631
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-history-screen", children: [
|
|
8632
8632
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-history-screen-body", children: [
|
|
8633
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
8633
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.BodyHeader, { icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.HistoryIcon, {}), title: "History" }),
|
|
8634
8634
|
isLoading && deposits.length === 0 && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-history-empty", children: [
|
|
8635
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-history-empty-glyph", "aria-hidden": "true", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
8635
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-history-empty-glyph", "aria-hidden": "true", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.HistoryIcon, {}) }),
|
|
8636
8636
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-history-empty-text", children: [
|
|
8637
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
8637
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.Spinner, { className: "rs-spinner--sm" }),
|
|
8638
8638
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-history-empty-hint", children: "Loading history\u2026" })
|
|
8639
8639
|
] })
|
|
8640
8640
|
] }),
|
|
8641
8641
|
error && !isLoading && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-history-empty", children: [
|
|
8642
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-history-empty-glyph", "aria-hidden": "true", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
8642
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-history-empty-glyph", "aria-hidden": "true", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.AlertTriangleIcon, {}) }),
|
|
8643
8643
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-history-empty-text", children: [
|
|
8644
8644
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-history-empty-title", children: "Couldn't load history" }),
|
|
8645
8645
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-history-empty-hint", children: error })
|
|
8646
8646
|
] })
|
|
8647
8647
|
] }),
|
|
8648
8648
|
!isLoading && !error && visibleDeposits.length === 0 && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-history-empty", children: [
|
|
8649
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-history-empty-glyph", "aria-hidden": "true", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
8649
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-history-empty-glyph", "aria-hidden": "true", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.HistoryIcon, {}) }),
|
|
8650
8650
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-history-empty-text", children: [
|
|
8651
8651
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-history-empty-title", children: "No deposits yet" }),
|
|
8652
8652
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-history-empty-hint", children: "Your deposit history will appear here" })
|
|
@@ -8666,7 +8666,7 @@ function DepositHistoryPanel({
|
|
|
8666
8666
|
)
|
|
8667
8667
|
] })
|
|
8668
8668
|
] }),
|
|
8669
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
8669
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.PoweredBy, {})
|
|
8670
8670
|
] })
|
|
8671
8671
|
]
|
|
8672
8672
|
}
|
|
@@ -8702,8 +8702,8 @@ function HistoryCard({ deposit }) {
|
|
|
8702
8702
|
children: [
|
|
8703
8703
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-history-card-row", children: [
|
|
8704
8704
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-history-card-icons", children: [
|
|
8705
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-history-card-token", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
8706
|
-
sourceChainIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-history-card-chain", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
8705
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-history-card-token", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.TokenIcon, { symbol: sourceSymbol, fallback: sourceSymbol.slice(0, 2) }) }),
|
|
8706
|
+
sourceChainIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-history-card-chain", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CdnIcon, { src: sourceChainIcon }) })
|
|
8707
8707
|
] }),
|
|
8708
8708
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-history-card-text", children: [
|
|
8709
8709
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-history-card-title", children: txTypeLabel }),
|
|
@@ -8719,14 +8719,14 @@ function HistoryCard({ deposit }) {
|
|
|
8719
8719
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: "Source chain" }),
|
|
8720
8720
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-amount-detail-value", children: [
|
|
8721
8721
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: sourceChainName }),
|
|
8722
|
-
sourceChainIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
8722
|
+
sourceChainIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CdnIcon, { src: sourceChainIcon }) })
|
|
8723
8723
|
] })
|
|
8724
8724
|
] }),
|
|
8725
8725
|
targetChainName && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-amount-detail-row", children: [
|
|
8726
8726
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: "Destination chain" }),
|
|
8727
8727
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-amount-detail-value", children: [
|
|
8728
8728
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: targetChainName }),
|
|
8729
|
-
targetChainIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
8729
|
+
targetChainIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CdnIcon, { src: targetChainIcon }) })
|
|
8730
8730
|
] })
|
|
8731
8731
|
] }),
|
|
8732
8732
|
srcTxUrl && srcTxHash && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-amount-detail-row", children: [
|
|
@@ -8741,7 +8741,7 @@ function HistoryCard({ deposit }) {
|
|
|
8741
8741
|
onClick: (e) => e.stopPropagation(),
|
|
8742
8742
|
children: [
|
|
8743
8743
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: shortenHash(srcTxHash) }),
|
|
8744
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
8744
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.ArrowUpRightIcon, {})
|
|
8745
8745
|
]
|
|
8746
8746
|
}
|
|
8747
8747
|
)
|
|
@@ -8756,7 +8756,7 @@ DepositHistoryPanel.displayName = "DepositHistoryPanel";
|
|
|
8756
8756
|
// src/DepositModal.tsx
|
|
8757
8757
|
|
|
8758
8758
|
var ReownDepositInner = _react.lazy.call(void 0,
|
|
8759
|
-
() => Promise.resolve().then(() => _interopRequireWildcard(require("./DepositModalReown-
|
|
8759
|
+
() => Promise.resolve().then(() => _interopRequireWildcard(require("./DepositModalReown-VG66OTIU.cjs"))).then((m) => ({ default: m.DepositModalReown }))
|
|
8760
8760
|
);
|
|
8761
8761
|
function sortByCreatedAtDesc(items) {
|
|
8762
8762
|
return [...items].sort((a, b) => {
|
|
@@ -8770,8 +8770,8 @@ function hasSuppliedWalletClient(props) {
|
|
|
8770
8770
|
return Object.prototype.hasOwnProperty.call(props, WALLET_CLIENT_PROP);
|
|
8771
8771
|
}
|
|
8772
8772
|
function DepositModal(props) {
|
|
8773
|
-
|
|
8774
|
-
|
|
8773
|
+
_chunkPWLEBV5Vcjs.warnRemovedProps.call(void 0, "DepositModal", props);
|
|
8774
|
+
_chunkBRYNGLDMcjs.checkBackendUrl.call(void 0, "DepositModal", props.backendUrl);
|
|
8775
8775
|
const needsReown = !!props.reownAppId;
|
|
8776
8776
|
const hasWalletClientProp = hasSuppliedWalletClient(props);
|
|
8777
8777
|
if (needsReown) {
|
|
@@ -8833,7 +8833,7 @@ function DepositModalInner({
|
|
|
8833
8833
|
debug
|
|
8834
8834
|
}) {
|
|
8835
8835
|
const modalRef = _react.useRef.call(void 0, null);
|
|
8836
|
-
const onReadyRef =
|
|
8836
|
+
const onReadyRef = _chunkBRYNGLDMcjs.useLatestRef.call(void 0, onReady);
|
|
8837
8837
|
const [currentScreen, setCurrentScreen] = _react.useState.call(void 0, "connect");
|
|
8838
8838
|
const [swappedImmersive, setSwappedImmersive] = _react.useState.call(void 0, false);
|
|
8839
8839
|
const [backHandler, setBackHandler] = _react.useState.call(void 0,
|
|
@@ -8851,9 +8851,9 @@ function DepositModalInner({
|
|
|
8851
8851
|
const historyLoadedRef = _react.useRef.call(void 0, false);
|
|
8852
8852
|
const targetChain = targetChainProp === "solana" || targetChainProp === _chunkO7BCVQ6Lcjs.HYPERCORE_SPOT_CAIP2 ? targetChainProp : _chunkO7BCVQ6Lcjs.getChainId.call(void 0, targetChainProp);
|
|
8853
8853
|
const sourceChain = sourceChainProp ? _chunkO7BCVQ6Lcjs.getChainId.call(void 0, sourceChainProp) : void 0;
|
|
8854
|
-
const rpcUrls =
|
|
8854
|
+
const rpcUrls = _chunkBRYNGLDMcjs.useStableRpcUrls.call(void 0, rpcUrlsProp);
|
|
8855
8855
|
const service = _react.useMemo.call(void 0,
|
|
8856
|
-
() =>
|
|
8856
|
+
() => _chunkBRYNGLDMcjs.createDepositService.call(void 0, backendUrl, {
|
|
8857
8857
|
debug,
|
|
8858
8858
|
debugScope: "service:deposit"
|
|
8859
8859
|
}),
|
|
@@ -8887,7 +8887,7 @@ function DepositModalInner({
|
|
|
8887
8887
|
}, [store, targetChain, targetToken]);
|
|
8888
8888
|
_react.useEffect.call(void 0, () => {
|
|
8889
8889
|
if (isOpen && modalRef.current) {
|
|
8890
|
-
|
|
8890
|
+
_chunkBRYNGLDMcjs.applyTheme.call(void 0, modalRef.current, theme);
|
|
8891
8891
|
}
|
|
8892
8892
|
}, [isOpen, theme]);
|
|
8893
8893
|
_react.useEffect.call(void 0, () => {
|
|
@@ -8968,7 +8968,7 @@ function DepositModalInner({
|
|
|
8968
8968
|
fetchHistory("initial");
|
|
8969
8969
|
}
|
|
8970
8970
|
}, [historyOpen, fetchHistory]);
|
|
8971
|
-
const onLifecycleRef =
|
|
8971
|
+
const onLifecycleRef = _chunkBRYNGLDMcjs.useLatestRef.call(void 0, onLifecycle);
|
|
8972
8972
|
const handleLifecycle = _react.useCallback.call(void 0,
|
|
8973
8973
|
(event) => {
|
|
8974
8974
|
_optionalChain([onLifecycleRef, 'access', _285 => _285.current, 'optionalCall', _286 => _286(event)]);
|
|
@@ -9004,8 +9004,8 @@ function DepositModalInner({
|
|
|
9004
9004
|
const canGoBack = backHandler !== void 0;
|
|
9005
9005
|
const hideHeaderChrome = swappedImmersive;
|
|
9006
9006
|
const modalClassName = `rs-modal${hideHeaderChrome ? " rs-modal--swapped-iframe" : ""}`;
|
|
9007
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
9008
|
-
|
|
9007
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.RpcUrlsProvider, { value: rpcUrls, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.ChainCatalogProvider, { service, rpcUrls, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, DepositStoreProvider, { store, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
9008
|
+
_chunkBRYNGLDMcjs.Modal,
|
|
9009
9009
|
{
|
|
9010
9010
|
isOpen,
|
|
9011
9011
|
onClose,
|
|
@@ -9021,7 +9021,7 @@ function DepositModalInner({
|
|
|
9021
9021
|
className: "rs-modal-header-back",
|
|
9022
9022
|
"aria-label": "Go back",
|
|
9023
9023
|
onClick: backHandler,
|
|
9024
|
-
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
9024
|
+
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.ChevronLeftIcon, {})
|
|
9025
9025
|
}
|
|
9026
9026
|
) }),
|
|
9027
9027
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-modal-header-nav-right", children: [
|
|
@@ -9033,7 +9033,7 @@ function DepositModalInner({
|
|
|
9033
9033
|
"aria-label": "Deposit history",
|
|
9034
9034
|
onClick: handleHistoryOpen,
|
|
9035
9035
|
disabled: !recipient,
|
|
9036
|
-
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
9036
|
+
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.HistoryIcon, {})
|
|
9037
9037
|
}
|
|
9038
9038
|
),
|
|
9039
9039
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
@@ -9043,7 +9043,7 @@ function DepositModalInner({
|
|
|
9043
9043
|
onClick: onClose,
|
|
9044
9044
|
className: "rs-modal-close",
|
|
9045
9045
|
"aria-label": "Close",
|
|
9046
|
-
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
9046
|
+
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBRYNGLDMcjs.CloseIcon, {})
|
|
9047
9047
|
}
|
|
9048
9048
|
)
|
|
9049
9049
|
] })
|