@rhinestone/deposit-modal 0.1.43 → 0.1.45

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.
@@ -25,7 +25,7 @@
25
25
 
26
26
 
27
27
 
28
- var _chunkLT3QKJI2cjs = require('./chunk-LT3QKJI2.cjs');
28
+ var _chunk55QIUUIScjs = require('./chunk-55QIUUIS.cjs');
29
29
 
30
30
 
31
31
 
@@ -41,7 +41,7 @@ var _chunkLT3QKJI2cjs = require('./chunk-LT3QKJI2.cjs');
41
41
 
42
42
 
43
43
 
44
- var _chunkNELAYNA3cjs = require('./chunk-NELAYNA3.cjs');
44
+ var _chunkZNHU72LIcjs = require('./chunk-ZNHU72LI.cjs');
45
45
 
46
46
  // src/DepositModal.tsx
47
47
 
@@ -62,15 +62,15 @@ var _viem = require('viem');
62
62
 
63
63
  var _jsxruntime = require('react/jsx-runtime');
64
64
  async function resolveSessionOwner(eoaAddress) {
65
- const localOwner = _chunkLT3QKJI2cjs.loadSessionOwnerFromStorage.call(void 0, eoaAddress);
65
+ const localOwner = _chunk55QIUUIScjs.loadSessionOwnerFromStorage.call(void 0, eoaAddress);
66
66
  if (localOwner) {
67
67
  return {
68
- account: _chunkLT3QKJI2cjs.accountFromPrivateKey.call(void 0, localOwner.privateKey),
68
+ account: _chunk55QIUUIScjs.accountFromPrivateKey.call(void 0, localOwner.privateKey),
69
69
  address: localOwner.address
70
70
  };
71
71
  }
72
- const created = _chunkLT3QKJI2cjs.createSessionOwnerKey.call(void 0, );
73
- _chunkLT3QKJI2cjs.saveSessionOwnerToStorage.call(void 0, eoaAddress, created.privateKey, created.address);
72
+ const created = _chunk55QIUUIScjs.createSessionOwnerKey.call(void 0, );
73
+ _chunk55QIUUIScjs.saveSessionOwnerToStorage.call(void 0, eoaAddress, created.privateKey, created.address);
74
74
  return {
75
75
  account: created.account,
76
76
  address: created.address
@@ -105,7 +105,7 @@ function SetupStep({
105
105
  const setup = await service.setupAccount({
106
106
  ownerAddress: address,
107
107
  sessionOwnerAddress: sessionOwner.address,
108
- targetChain: _chunkLT3QKJI2cjs.toEvmCaip2.call(void 0, targetChain),
108
+ targetChain: _chunk55QIUUIScjs.toEvmCaip2.call(void 0, targetChain),
109
109
  targetToken,
110
110
  signerAddress,
111
111
  sessionChainIds,
@@ -132,7 +132,7 @@ function SetupStep({
132
132
  primaryType: typedData.primaryType,
133
133
  message: typedData.message
134
134
  });
135
- const sessionDetails = _chunkLT3QKJI2cjs.buildSessionDetails.call(void 0, setup.sessionDetailsUnsigned, signature);
135
+ const sessionDetails = _chunk55QIUUIScjs.buildSessionDetails.call(void 0, setup.sessionDetailsUnsigned, signature);
136
136
  setState({ type: "registering" });
137
137
  const registerResult = await service.registerAccount({
138
138
  address: smartAccount,
@@ -144,7 +144,7 @@ function SetupStep({
144
144
  eoaAddress: address,
145
145
  sessionOwner: sessionOwner.address,
146
146
  target: {
147
- chain: _chunkLT3QKJI2cjs.toEvmCaip2.call(void 0, targetChain),
147
+ chain: _chunk55QIUUIScjs.toEvmCaip2.call(void 0, targetChain),
148
148
  token: targetToken,
149
149
  ...recipient && { recipient }
150
150
  }
@@ -203,7 +203,7 @@ function SetupStep({
203
203
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-step", children: [
204
204
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-loading-state", children: [
205
205
  isLoading && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
206
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkLT3QKJI2cjs.Spinner, { className: "rs-spinner--lg rs-text-accent" }),
206
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk55QIUUIScjs.Spinner, { className: "rs-spinner--lg rs-text-accent" }),
207
207
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-loading-text", children: [
208
208
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-loading-title", children: renderStateMessage() }),
209
209
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-loading-subtitle", children: "This may take a moment" })
@@ -240,7 +240,7 @@ function SetupStep({
240
240
  ] })
241
241
  ] })
242
242
  ] }),
243
- isError && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-step-footer", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkLT3QKJI2cjs.Button, { onClick: handleRetry, variant: "default", fullWidth: true, children: "Try Again" }) })
243
+ isError && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-step-footer", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk55QIUUIScjs.Button, { onClick: handleRetry, variant: "default", fullWidth: true, children: "Try Again" }) })
244
244
  ] });
245
245
  }
246
246
 
@@ -264,7 +264,7 @@ function AssetSelectStep({
264
264
  const [error, setError] = _react.useState.call(void 0, null);
265
265
  const defaultAssetId = _react.useMemo.call(void 0, () => {
266
266
  if (!defaultSourceChain || !defaultSourceToken) return null;
267
- return _chunkLT3QKJI2cjs.getAssetId.call(void 0, {
267
+ return _chunk55QIUUIScjs.getAssetId.call(void 0, {
268
268
  chainId: defaultSourceChain,
269
269
  token: defaultSourceToken
270
270
  });
@@ -281,10 +281,10 @@ function AssetSelectStep({
281
281
  try {
282
282
  const portfolio = await service.fetchPortfolio(address);
283
283
  if (!active) return;
284
- const portfolioAssets = _chunkLT3QKJI2cjs.portfolioToAssets.call(void 0, portfolio.tokens);
284
+ const portfolioAssets = _chunk55QIUUIScjs.portfolioToAssets.call(void 0, portfolio.tokens);
285
285
  setAssets(portfolioAssets);
286
286
  const hasNative = portfolioAssets.some(
287
- (asset) => asset.token.toLowerCase() === _chunkNELAYNA3cjs.NATIVE_TOKEN_ADDRESS
287
+ (asset) => asset.token.toLowerCase() === _chunkZNHU72LIcjs.NATIVE_TOKEN_ADDRESS
288
288
  );
289
289
  if (!hasNative) {
290
290
  const nativeAssets = await fetchNativeAssets(
@@ -350,7 +350,7 @@ function AssetSelectStep({
350
350
  const raw = _viem.formatUnits.call(void 0, BigInt(asset.balance), asset.decimals);
351
351
  const numeric = Number(raw);
352
352
  if (!Number.isFinite(numeric)) return raw;
353
- return _chunkLT3QKJI2cjs.tokenFormatter.format(numeric);
353
+ return _chunk55QIUUIScjs.tokenFormatter.format(numeric);
354
354
  } catch (e3) {
355
355
  return asset.balance;
356
356
  }
@@ -364,7 +364,7 @@ function AssetSelectStep({
364
364
  style: { paddingTop: 4, overflow: "auto", maxHeight: 340 },
365
365
  children: [
366
366
  loading && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-loading-state", style: { padding: "40px 12px" }, children: [
367
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkLT3QKJI2cjs.Spinner, { className: "rs-text-tertiary" }),
367
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk55QIUUIScjs.Spinner, { className: "rs-text-tertiary" }),
368
368
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-text-sm rs-text-tertiary", children: "Loading balances" })
369
369
  ] }),
370
370
  error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-alert rs-alert--error", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-alert-text", children: error }) }),
@@ -397,9 +397,9 @@ function AssetSelectStep({
397
397
  !loading && !error && rows.length > 0 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-asset-list", children: rows.map((asset) => {
398
398
  const isSelected = selectedAssetId === asset.id;
399
399
  const tokenAmount = formatBalance(asset);
400
- const badge = _chunkNELAYNA3cjs.getChainBadge.call(void 0, asset.chainId);
401
- const tokenIcon = _chunkNELAYNA3cjs.getTokenIcon.call(void 0, asset.symbol);
402
- const chainIcon = _chunkNELAYNA3cjs.getChainIcon.call(void 0, asset.chainId);
400
+ const badge = _chunkZNHU72LIcjs.getChainBadge.call(void 0, asset.chainId);
401
+ const tokenIcon = _chunkZNHU72LIcjs.getTokenIcon.call(void 0, asset.symbol);
402
+ const chainIcon = _chunkZNHU72LIcjs.getChainIcon.call(void 0, asset.chainId);
403
403
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
404
404
  "button",
405
405
  {
@@ -423,7 +423,7 @@ function AssetSelectStep({
423
423
  "img",
424
424
  {
425
425
  src: chainIcon,
426
- alt: _chunkNELAYNA3cjs.getChainName.call(void 0, asset.chainId),
426
+ alt: _chunkZNHU72LIcjs.getChainName.call(void 0, asset.chainId),
427
427
  className: "rs-asset-chain-badge"
428
428
  }
429
429
  ) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
@@ -444,7 +444,7 @@ function AssetSelectStep({
444
444
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-asset-chain", children: [
445
445
  " ",
446
446
  "on ",
447
- _chunkNELAYNA3cjs.getChainName.call(void 0, asset.chainId)
447
+ _chunkZNHU72LIcjs.getChainName.call(void 0, asset.chainId)
448
448
  ] })
449
449
  ] }),
450
450
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-asset-balance-small", children: [
@@ -454,7 +454,7 @@ function AssetSelectStep({
454
454
  ] })
455
455
  ] })
456
456
  ] }),
457
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-asset-balance", children: asset.balanceUsd !== void 0 && asset.balanceUsd > 0 ? _chunkLT3QKJI2cjs.currencyFormatter.format(asset.balanceUsd) : tokenAmount !== "--" ? `${tokenAmount} ${asset.symbol}` : "--" })
457
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-asset-balance", children: asset.balanceUsd !== void 0 && asset.balanceUsd > 0 ? _chunk55QIUUIScjs.currencyFormatter.format(asset.balanceUsd) : tokenAmount !== "--" ? `${tokenAmount} ${asset.symbol}` : "--" })
458
458
  ]
459
459
  },
460
460
  asset.id
@@ -464,7 +464,7 @@ function AssetSelectStep({
464
464
  }
465
465
  ),
466
466
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-step-footer", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
467
- _chunkLT3QKJI2cjs.Button,
467
+ _chunk55QIUUIScjs.Button,
468
468
  {
469
469
  onClick: () => selectedAsset && onContinue(selectedAsset),
470
470
  disabled: !selectedAsset,
@@ -472,17 +472,17 @@ function AssetSelectStep({
472
472
  children: "Continue"
473
473
  }
474
474
  ) }),
475
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkLT3QKJI2cjs.PoweredBy, {})
475
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk55QIUUIScjs.PoweredBy, {})
476
476
  ] });
477
477
  }
478
478
  async function fetchNativeAssets(address, publicClient, existing) {
479
479
  const existingIds = new Set(existing.map((asset) => asset.id));
480
480
  const connectedChainId = _optionalChain([publicClient, 'access', _6 => _6.chain, 'optionalAccess', _7 => _7.id]);
481
481
  if (!connectedChainId) return [];
482
- if (!_chunkNELAYNA3cjs.SOURCE_CHAINS.some((chain) => chain.id === connectedChainId)) return [];
483
- const id = _chunkLT3QKJI2cjs.getAssetId.call(void 0, {
482
+ if (!_chunkZNHU72LIcjs.SOURCE_CHAINS.some((chain) => chain.id === connectedChainId)) return [];
483
+ const id = _chunk55QIUUIScjs.getAssetId.call(void 0, {
484
484
  chainId: connectedChainId,
485
- token: _chunkNELAYNA3cjs.NATIVE_TOKEN_ADDRESS
485
+ token: _chunkZNHU72LIcjs.NATIVE_TOKEN_ADDRESS
486
486
  });
487
487
  if (existingIds.has(id)) return [];
488
488
  try {
@@ -491,7 +491,7 @@ async function fetchNativeAssets(address, publicClient, existing) {
491
491
  {
492
492
  id,
493
493
  chainId: connectedChainId,
494
- token: _chunkNELAYNA3cjs.NATIVE_TOKEN_ADDRESS,
494
+ token: _chunkZNHU72LIcjs.NATIVE_TOKEN_ADDRESS,
495
495
  symbol: "ETH",
496
496
  name: "Ethereum",
497
497
  decimals: 18,
@@ -541,8 +541,8 @@ function AmountStep({
541
541
  const chainMismatch = Boolean(
542
542
  _optionalChain([walletClient, 'optionalAccess', _8 => _8.chain, 'optionalAccess', _9 => _9.id]) && walletClient.chain.id !== asset.chainId
543
543
  );
544
- const targetSymbol = _chunkNELAYNA3cjs.getTokenSymbol.call(void 0, targetToken, targetChain);
545
- const isSourceStablecoin = _chunkNELAYNA3cjs.isStablecoinSymbol.call(void 0, asset.symbol);
544
+ const targetSymbol = _chunkZNHU72LIcjs.getTokenSymbol.call(void 0, targetToken, targetChain);
545
+ const isSourceStablecoin = _chunkZNHU72LIcjs.isStablecoinSymbol.call(void 0, asset.symbol);
546
546
  const tokenPriceUsd = _react.useMemo.call(void 0, () => {
547
547
  if (tokenPriceUsdOverride !== void 0 && tokenPriceUsdOverride > 0)
548
548
  return tokenPriceUsdOverride;
@@ -566,7 +566,7 @@ function AmountStep({
566
566
  const balanceTarget = _nullishCoalesce(balanceAddress, () => ( address));
567
567
  if (!balanceTarget || !publicClient) return;
568
568
  try {
569
- const bal = _chunkLT3QKJI2cjs.isNativeAsset.call(void 0, asset) ? await publicClient.getBalance({ address: balanceTarget }) : await publicClient.readContract({
569
+ const bal = _chunk55QIUUIScjs.isNativeAsset.call(void 0, asset) ? await publicClient.getBalance({ address: balanceTarget }) : await publicClient.readContract({
570
570
  address: asset.token,
571
571
  abi: _viem.erc20Abi,
572
572
  functionName: "balanceOf",
@@ -592,7 +592,7 @@ function AmountStep({
592
592
  setIsSwitching(true);
593
593
  switchChain(asset.chainId).catch((err) => {
594
594
  const raw = err instanceof Error ? err.message : "Failed to switch chain";
595
- setError(_chunkLT3QKJI2cjs.formatUserError.call(void 0, raw));
595
+ setError(_chunk55QIUUIScjs.formatUserError.call(void 0, raw));
596
596
  }).finally(() => {
597
597
  setIsSwitching(false);
598
598
  });
@@ -628,7 +628,7 @@ function AmountStep({
628
628
  const raw = _viem.formatUnits.call(void 0, balance, asset.decimals);
629
629
  const numeric = Number(raw);
630
630
  if (!Number.isFinite(numeric)) return raw;
631
- return _chunkLT3QKJI2cjs.tokenFormatter.format(numeric);
631
+ return _chunk55QIUUIScjs.tokenFormatter.format(numeric);
632
632
  } catch (e8) {
633
633
  return "...";
634
634
  }
@@ -670,13 +670,13 @@ function AmountStep({
670
670
  const usdValue = numericAmount;
671
671
  if (_optionalChain([uiConfig, 'optionalAccess', _11 => _11.maxDepositUsd]) && usdValue > uiConfig.maxDepositUsd) {
672
672
  setError(
673
- `Maximum deposit is ${_chunkLT3QKJI2cjs.currencyFormatter.format(uiConfig.maxDepositUsd)}`
673
+ `Maximum deposit is ${_chunk55QIUUIScjs.currencyFormatter.format(uiConfig.maxDepositUsd)}`
674
674
  );
675
675
  return;
676
676
  }
677
677
  if (_optionalChain([uiConfig, 'optionalAccess', _12 => _12.minDepositUsd]) && usdValue < uiConfig.minDepositUsd) {
678
678
  setError(
679
- `Minimum deposit is ${_chunkLT3QKJI2cjs.currencyFormatter.format(uiConfig.minDepositUsd)}`
679
+ `Minimum deposit is ${_chunk55QIUUIScjs.currencyFormatter.format(uiConfig.minDepositUsd)}`
680
680
  );
681
681
  return;
682
682
  }
@@ -725,7 +725,7 @@ function AmountStep({
725
725
  hasPricing && balanceUsd !== null && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { style: { color: "var(--rs-muted-foreground)" }, children: [
726
726
  " ",
727
727
  "(",
728
- _chunkLT3QKJI2cjs.currencyFormatter.format(balanceUsd),
728
+ _chunk55QIUUIScjs.currencyFormatter.format(balanceUsd),
729
729
  ")"
730
730
  ] })
731
731
  ] }) })
@@ -739,26 +739,26 @@ function AmountStep({
739
739
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-flow-pill-label", children: "You send" }),
740
740
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-flow-pill-token", children: [
741
741
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-flow-pill-token-icon-wrapper", children: [
742
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-flow-pill-token-icon", children: _chunkNELAYNA3cjs.getTokenIcon.call(void 0, asset.symbol) ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
742
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-flow-pill-token-icon", children: _chunkZNHU72LIcjs.getTokenIcon.call(void 0, asset.symbol) ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
743
743
  "img",
744
744
  {
745
- src: _chunkNELAYNA3cjs.getTokenIcon.call(void 0, asset.symbol),
745
+ src: _chunkZNHU72LIcjs.getTokenIcon.call(void 0, asset.symbol),
746
746
  alt: asset.symbol
747
747
  }
748
748
  ) : asset.symbol.slice(0, 2) }),
749
749
  (() => {
750
- const chainIcon = _chunkNELAYNA3cjs.getChainIcon.call(void 0, asset.chainId);
750
+ const chainIcon = _chunkZNHU72LIcjs.getChainIcon.call(void 0, asset.chainId);
751
751
  if (chainIcon) {
752
752
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
753
753
  "img",
754
754
  {
755
755
  src: chainIcon,
756
- alt: _chunkNELAYNA3cjs.getChainName.call(void 0, asset.chainId),
756
+ alt: _chunkZNHU72LIcjs.getChainName.call(void 0, asset.chainId),
757
757
  className: "rs-flow-pill-chain-badge"
758
758
  }
759
759
  );
760
760
  }
761
- const badge = _chunkNELAYNA3cjs.getChainBadge.call(void 0, asset.chainId);
761
+ const badge = _chunkZNHU72LIcjs.getChainBadge.call(void 0, asset.chainId);
762
762
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
763
763
  "div",
764
764
  {
@@ -796,26 +796,26 @@ function AmountStep({
796
796
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-flow-pill-label", children: "You receive" }),
797
797
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-flow-pill-token", children: [
798
798
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-flow-pill-token-icon-wrapper", children: [
799
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-flow-pill-token-icon", children: _chunkNELAYNA3cjs.getTokenIcon.call(void 0, targetSymbol) ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
799
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-flow-pill-token-icon", children: _chunkZNHU72LIcjs.getTokenIcon.call(void 0, targetSymbol) ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
800
800
  "img",
801
801
  {
802
- src: _chunkNELAYNA3cjs.getTokenIcon.call(void 0, targetSymbol),
802
+ src: _chunkZNHU72LIcjs.getTokenIcon.call(void 0, targetSymbol),
803
803
  alt: targetSymbol
804
804
  }
805
805
  ) : targetSymbol.slice(0, 2) }),
806
806
  (() => {
807
- const chainIcon = _chunkNELAYNA3cjs.getChainIcon.call(void 0, targetChain);
807
+ const chainIcon = _chunkZNHU72LIcjs.getChainIcon.call(void 0, targetChain);
808
808
  if (chainIcon) {
809
809
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
810
810
  "img",
811
811
  {
812
812
  src: chainIcon,
813
- alt: _chunkNELAYNA3cjs.getChainName.call(void 0, targetChain),
813
+ alt: _chunkZNHU72LIcjs.getChainName.call(void 0, targetChain),
814
814
  className: "rs-flow-pill-chain-badge"
815
815
  }
816
816
  );
817
817
  }
818
- const badge = _chunkNELAYNA3cjs.getChainBadge.call(void 0, targetChain);
818
+ const badge = _chunkZNHU72LIcjs.getChainBadge.call(void 0, targetChain);
819
819
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
820
820
  "div",
821
821
  {
@@ -861,7 +861,7 @@ function AmountStep({
861
861
  }
862
862
  )
863
863
  ] }),
864
- chainMismatch && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-chain-switch", style: { marginTop: 16 }, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-chain-switch-text", children: isSwitching ? `Switching to ${_chunkNELAYNA3cjs.getChainName.call(void 0, asset.chainId)}...` : `Switch your wallet to ${_chunkNELAYNA3cjs.getChainName.call(void 0, asset.chainId)} to continue.` }) }),
864
+ chainMismatch && !isSwitching && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-chain-switch", style: { marginTop: 16 }, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-chain-switch-text", children: `Switch your wallet to ${_chunkZNHU72LIcjs.getChainName.call(void 0, asset.chainId)} to continue.` }) }),
865
865
  error && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-amount-error", children: [
866
866
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
867
867
  "svg",
@@ -885,7 +885,7 @@ function AmountStep({
885
885
  ] })
886
886
  ] }),
887
887
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-step-footer", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
888
- _chunkLT3QKJI2cjs.Button,
888
+ _chunk55QIUUIScjs.Button,
889
889
  {
890
890
  onClick: handleContinue,
891
891
  fullWidth: true,
@@ -893,7 +893,7 @@ function AmountStep({
893
893
  children: "Continue"
894
894
  }
895
895
  ) }),
896
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkLT3QKJI2cjs.PoweredBy, {})
896
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk55QIUUIScjs.PoweredBy, {})
897
897
  ] });
898
898
  }
899
899
 
@@ -924,7 +924,7 @@ function ConfirmStep({
924
924
  const hasAttemptedSwitch = _react.useRef.call(void 0, false);
925
925
  const chainMismatch = _optionalChain([walletClient, 'optionalAccess', _13 => _13.chain, 'optionalAccess', _14 => _14.id]) && walletClient.chain.id !== asset.chainId;
926
926
  const sameRoute = targetChain === asset.chainId && targetToken.toLowerCase() === asset.token.toLowerCase();
927
- const targetSymbol = sameRoute ? asset.symbol : _chunkNELAYNA3cjs.getTokenSymbol.call(void 0, targetToken, targetChain);
927
+ const targetSymbol = sameRoute ? asset.symbol : _chunkZNHU72LIcjs.getTokenSymbol.call(void 0, targetToken, targetChain);
928
928
  const formattedSendAmount = amount && !Number.isNaN(Number(amount)) ? Number(amount).toLocaleString("en-US", { maximumFractionDigits: 6 }) : "0";
929
929
  const formattedReceiveAmount = (() => {
930
930
  if (sameRoute) return formattedSendAmount;
@@ -943,7 +943,7 @@ function ConfirmStep({
943
943
  setIsSwitching(true);
944
944
  switchChain(asset.chainId).catch((err) => {
945
945
  const raw = err instanceof Error ? err.message : "Failed to switch chain";
946
- setError(_chunkLT3QKJI2cjs.formatUserError.call(void 0, raw));
946
+ setError(_chunk55QIUUIScjs.formatUserError.call(void 0, raw));
947
947
  }).finally(() => {
948
948
  setIsSwitching(false);
949
949
  });
@@ -958,7 +958,7 @@ function ConfirmStep({
958
958
  return;
959
959
  }
960
960
  if (chainMismatch) {
961
- setError(`Switch to ${_chunkNELAYNA3cjs.getChainName.call(void 0, asset.chainId)} to sign`);
961
+ setError(`Switch to ${_chunkZNHU72LIcjs.getChainName.call(void 0, asset.chainId)} to sign`);
962
962
  return;
963
963
  }
964
964
  const parsedAmount = parseFloat(amount);
@@ -986,7 +986,7 @@ function ConfirmStep({
986
986
  throw new Error("Wallet not properly connected");
987
987
  }
988
988
  const transferTo = sameRoute ? recipient : smartAccount;
989
- const hash = _chunkLT3QKJI2cjs.isNativeAsset.call(void 0, asset) ? await walletClient.sendTransaction({
989
+ const hash = _chunk55QIUUIScjs.isNativeAsset.call(void 0, asset) ? await walletClient.sendTransaction({
990
990
  account,
991
991
  chain,
992
992
  to: transferTo,
@@ -1003,7 +1003,7 @@ function ConfirmStep({
1003
1003
  onConfirm(hash, asset.chainId, amountUnits.toString(), asset.token);
1004
1004
  } catch (err) {
1005
1005
  const raw = err instanceof Error ? err.message : "Transfer failed";
1006
- const message = _chunkLT3QKJI2cjs.formatUserError.call(void 0, raw);
1006
+ const message = _chunk55QIUUIScjs.formatUserError.call(void 0, raw);
1007
1007
  setError(message);
1008
1008
  _optionalChain([onError, 'optionalCall', _16 => _16(message, "TRANSFER_ERROR")]);
1009
1009
  } finally {
@@ -1022,15 +1022,15 @@ function ConfirmStep({
1022
1022
  className: "rs-card-value",
1023
1023
  style: { display: "flex", alignItems: "center", gap: 8 },
1024
1024
  children: [
1025
- _chunkNELAYNA3cjs.getChainIcon.call(void 0, asset.chainId) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1025
+ _chunkZNHU72LIcjs.getChainIcon.call(void 0, asset.chainId) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1026
1026
  "img",
1027
1027
  {
1028
- src: _chunkNELAYNA3cjs.getChainIcon.call(void 0, asset.chainId),
1028
+ src: _chunkZNHU72LIcjs.getChainIcon.call(void 0, asset.chainId),
1029
1029
  alt: "",
1030
1030
  style: { width: 16, height: 16, borderRadius: 3 }
1031
1031
  }
1032
1032
  ),
1033
- _chunkNELAYNA3cjs.getChainName.call(void 0, asset.chainId)
1033
+ _chunkZNHU72LIcjs.getChainName.call(void 0, asset.chainId)
1034
1034
  ]
1035
1035
  }
1036
1036
  )
@@ -1043,15 +1043,15 @@ function ConfirmStep({
1043
1043
  className: "rs-card-value",
1044
1044
  style: { display: "flex", alignItems: "center", gap: 8 },
1045
1045
  children: [
1046
- _chunkNELAYNA3cjs.getChainIcon.call(void 0, targetChain) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1046
+ _chunkZNHU72LIcjs.getChainIcon.call(void 0, targetChain) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1047
1047
  "img",
1048
1048
  {
1049
- src: _chunkNELAYNA3cjs.getChainIcon.call(void 0, targetChain),
1049
+ src: _chunkZNHU72LIcjs.getChainIcon.call(void 0, targetChain),
1050
1050
  alt: "",
1051
1051
  style: { width: 16, height: 16, borderRadius: 3 }
1052
1052
  }
1053
1053
  ),
1054
- _chunkNELAYNA3cjs.getChainName.call(void 0, targetChain)
1054
+ _chunkZNHU72LIcjs.getChainName.call(void 0, targetChain)
1055
1055
  ]
1056
1056
  }
1057
1057
  )
@@ -1070,10 +1070,10 @@ function ConfirmStep({
1070
1070
  className: "rs-card-value",
1071
1071
  style: { display: "flex", alignItems: "center", gap: 6 },
1072
1072
  children: [
1073
- _chunkNELAYNA3cjs.getTokenIcon.call(void 0, asset.symbol) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1073
+ _chunkZNHU72LIcjs.getTokenIcon.call(void 0, asset.symbol) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1074
1074
  "img",
1075
1075
  {
1076
- src: _chunkNELAYNA3cjs.getTokenIcon.call(void 0, asset.symbol),
1076
+ src: _chunkZNHU72LIcjs.getTokenIcon.call(void 0, asset.symbol),
1077
1077
  alt: "",
1078
1078
  style: { width: 16, height: 16, borderRadius: "50%" }
1079
1079
  }
@@ -1093,10 +1093,10 @@ function ConfirmStep({
1093
1093
  className: "rs-card-value",
1094
1094
  style: { display: "flex", alignItems: "center", gap: 6 },
1095
1095
  children: [
1096
- _chunkNELAYNA3cjs.getTokenIcon.call(void 0, targetSymbol) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1096
+ _chunkZNHU72LIcjs.getTokenIcon.call(void 0, targetSymbol) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1097
1097
  "img",
1098
1098
  {
1099
- src: _chunkNELAYNA3cjs.getTokenIcon.call(void 0, targetSymbol),
1099
+ src: _chunkZNHU72LIcjs.getTokenIcon.call(void 0, targetSymbol),
1100
1100
  alt: "",
1101
1101
  style: { width: 16, height: 16, borderRadius: "50%" }
1102
1102
  }
@@ -1109,7 +1109,7 @@ function ConfirmStep({
1109
1109
  )
1110
1110
  ] })
1111
1111
  ] }),
1112
- chainMismatch && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-chain-switch", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-chain-switch-text", children: isSwitching ? `Switching to ${_chunkNELAYNA3cjs.getChainName.call(void 0, asset.chainId)}...` : `Switch your wallet to ${_chunkNELAYNA3cjs.getChainName.call(void 0, asset.chainId)} to sign.` }) }),
1112
+ chainMismatch && !isSwitching && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-chain-switch", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-chain-switch-text", children: `Switch your wallet to ${_chunkZNHU72LIcjs.getChainName.call(void 0, asset.chainId)} to sign.` }) }),
1113
1113
  error && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-alert rs-alert--error", children: [
1114
1114
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1115
1115
  "svg",
@@ -1133,7 +1133,7 @@ function ConfirmStep({
1133
1133
  ] })
1134
1134
  ] }),
1135
1135
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-step-footer", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1136
- _chunkLT3QKJI2cjs.Button,
1136
+ _chunk55QIUUIScjs.Button,
1137
1137
  {
1138
1138
  onClick: handleConfirm,
1139
1139
  loading: isSubmitting,
@@ -1142,7 +1142,7 @@ function ConfirmStep({
1142
1142
  children: "Confirm Order"
1143
1143
  }
1144
1144
  ) }),
1145
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkLT3QKJI2cjs.PoweredBy, {})
1145
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk55QIUUIScjs.PoweredBy, {})
1146
1146
  ] });
1147
1147
  }
1148
1148
 
@@ -1436,7 +1436,7 @@ function DepositAddressStep({
1436
1436
  onError
1437
1437
  }) {
1438
1438
  const hasSolana = Boolean(solanaDepositAddress);
1439
- const evmChainIds = _react.useMemo.call(void 0, () => _chunkNELAYNA3cjs.getSupportedChainIds.call(void 0, ), []);
1439
+ const evmChainIds = _react.useMemo.call(void 0, () => _chunkZNHU72LIcjs.getSupportedChainIds.call(void 0, ), []);
1440
1440
  const chainOptions = _react.useMemo.call(void 0,
1441
1441
  () => hasSolana ? [...evmChainIds, "solana"] : evmChainIds,
1442
1442
  [evmChainIds, hasSolana]
@@ -1446,7 +1446,7 @@ function DepositAddressStep({
1446
1446
  const [sourceChainId, setSourceChainId] = _react.useState.call(void 0, defaultChainId);
1447
1447
  const isSolana = sourceChainId === "solana";
1448
1448
  const tokensForChain = _react.useMemo.call(void 0,
1449
- () => isSolana ? SOLANA_TOKENS.map((t) => t.symbol) : _chunkNELAYNA3cjs.getTargetTokenSymbolsForChain.call(void 0, sourceChainId),
1449
+ () => isSolana ? SOLANA_TOKENS.map((t) => t.symbol) : _chunkZNHU72LIcjs.getTargetTokenSymbolsForChain.call(void 0, sourceChainId),
1450
1450
  [sourceChainId, isSolana]
1451
1451
  );
1452
1452
  const defaultToken = tokensForChain.includes("USDC") ? "USDC" : _nullishCoalesce(tokensForChain[0], () => ( "USDC"));
@@ -1466,7 +1466,7 @@ function DepositAddressStep({
1466
1466
  const depositHandledRef = _react.useRef.call(void 0, false);
1467
1467
  const sourceSelectionRef = _react.useRef.call(void 0, {
1468
1468
  chainId: defaultChainId,
1469
- token: typeof defaultChainId === "number" ? _chunkNELAYNA3cjs.getTokenAddress.call(void 0, defaultToken, defaultChainId) : void 0,
1469
+ token: typeof defaultChainId === "number" ? _chunkZNHU72LIcjs.getTokenAddress.call(void 0, defaultToken, defaultChainId) : void 0,
1470
1470
  sourceSymbol: defaultToken
1471
1471
  });
1472
1472
  _react.useEffect.call(void 0, () => {
@@ -1482,7 +1482,7 @@ function DepositAddressStep({
1482
1482
  }
1483
1483
  sourceSelectionRef.current = {
1484
1484
  chainId: sourceChainId,
1485
- token: _chunkNELAYNA3cjs.getTokenAddress.call(void 0, sourceTokenSymbol, sourceChainId),
1485
+ token: _chunkZNHU72LIcjs.getTokenAddress.call(void 0, sourceTokenSymbol, sourceChainId),
1486
1486
  sourceSymbol: sourceTokenSymbol
1487
1487
  };
1488
1488
  }, [sourceChainId, sourceTokenSymbol, isSolana]);
@@ -1540,10 +1540,10 @@ function DepositAddressStep({
1540
1540
  const status = await service.fetchLatestStatus(smartAccount);
1541
1541
  if (cancelled || depositHandledRef.current) return;
1542
1542
  const event = status.lastEvent;
1543
- const eventTxHash = _chunkLT3QKJI2cjs.isDepositEvent.call(void 0, event) ? _nullishCoalesce(_chunkLT3QKJI2cjs.getEventTxHash.call(void 0, event), () => ( null)) : null;
1543
+ const eventTxHash = _chunk55QIUUIScjs.isDepositEvent.call(void 0, event) ? _nullishCoalesce(_chunk55QIUUIScjs.getEventTxHash.call(void 0, event), () => ( null)) : null;
1544
1544
  if (baselineTxHash === void 0) {
1545
1545
  baselineTxHash = eventTxHash;
1546
- } else if (eventTxHash && (!baselineTxHash || !_chunkLT3QKJI2cjs.txRefsMatch.call(void 0, eventTxHash, baselineTxHash))) {
1546
+ } else if (eventTxHash && (!baselineTxHash || !_chunk55QIUUIScjs.txRefsMatch.call(void 0, eventTxHash, baselineTxHash))) {
1547
1547
  const details = getDepositEventDetails(event);
1548
1548
  const fallback = sourceSelectionRef.current;
1549
1549
  const chainId = _nullishCoalesce(details.chainId, () => ( fallback.chainId));
@@ -1582,7 +1582,7 @@ function DepositAddressStep({
1582
1582
  clearTimeout(timeoutId);
1583
1583
  };
1584
1584
  }, [smartAccount, service, onDepositDetected, onError]);
1585
- const qrIconSrc = _chunkNELAYNA3cjs.getChainIcon.call(void 0, sourceChainId);
1585
+ const qrIconSrc = _chunkZNHU72LIcjs.getChainIcon.call(void 0, sourceChainId);
1586
1586
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-step", children: [
1587
1587
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-step-body", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-deposit-address", children: [
1588
1588
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-deposit-address-selectors", children: [
@@ -1598,15 +1598,15 @@ function DepositAddressStep({
1598
1598
  setTokenDropdownOpen(false);
1599
1599
  },
1600
1600
  children: [
1601
- _chunkNELAYNA3cjs.getChainIcon.call(void 0, sourceChainId) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1601
+ _chunkZNHU72LIcjs.getChainIcon.call(void 0, sourceChainId) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1602
1602
  "img",
1603
1603
  {
1604
- src: _chunkNELAYNA3cjs.getChainIcon.call(void 0, sourceChainId),
1604
+ src: _chunkZNHU72LIcjs.getChainIcon.call(void 0, sourceChainId),
1605
1605
  alt: "",
1606
1606
  className: "rs-deposit-address-dropdown-icon"
1607
1607
  }
1608
1608
  ),
1609
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: _chunkNELAYNA3cjs.getChainName.call(void 0, sourceChainId) }),
1609
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: _chunkZNHU72LIcjs.getChainName.call(void 0, sourceChainId) }),
1610
1610
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1611
1611
  "svg",
1612
1612
  {
@@ -1638,15 +1638,15 @@ function DepositAddressStep({
1638
1638
  setChainDropdownOpen(false);
1639
1639
  },
1640
1640
  children: [
1641
- _chunkNELAYNA3cjs.getChainIcon.call(void 0, chainId) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1641
+ _chunkZNHU72LIcjs.getChainIcon.call(void 0, chainId) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1642
1642
  "img",
1643
1643
  {
1644
- src: _chunkNELAYNA3cjs.getChainIcon.call(void 0, chainId),
1644
+ src: _chunkZNHU72LIcjs.getChainIcon.call(void 0, chainId),
1645
1645
  alt: "",
1646
1646
  className: "rs-deposit-address-dropdown-icon"
1647
1647
  }
1648
1648
  ),
1649
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: _chunkNELAYNA3cjs.getChainName.call(void 0, chainId) })
1649
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: _chunkZNHU72LIcjs.getChainName.call(void 0, chainId) })
1650
1650
  ]
1651
1651
  },
1652
1652
  String(chainId)
@@ -1664,10 +1664,10 @@ function DepositAddressStep({
1664
1664
  setChainDropdownOpen(false);
1665
1665
  },
1666
1666
  children: [
1667
- _chunkNELAYNA3cjs.getTokenIcon.call(void 0, sourceTokenSymbol) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1667
+ _chunkZNHU72LIcjs.getTokenIcon.call(void 0, sourceTokenSymbol) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1668
1668
  "img",
1669
1669
  {
1670
- src: _chunkNELAYNA3cjs.getTokenIcon.call(void 0, sourceTokenSymbol),
1670
+ src: _chunkZNHU72LIcjs.getTokenIcon.call(void 0, sourceTokenSymbol),
1671
1671
  alt: "",
1672
1672
  className: "rs-deposit-address-dropdown-icon"
1673
1673
  }
@@ -1704,10 +1704,10 @@ function DepositAddressStep({
1704
1704
  setTokenDropdownOpen(false);
1705
1705
  },
1706
1706
  children: [
1707
- _chunkNELAYNA3cjs.getTokenIcon.call(void 0, symbol) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1707
+ _chunkZNHU72LIcjs.getTokenIcon.call(void 0, symbol) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1708
1708
  "img",
1709
1709
  {
1710
- src: _chunkNELAYNA3cjs.getTokenIcon.call(void 0, symbol),
1710
+ src: _chunkZNHU72LIcjs.getTokenIcon.call(void 0, symbol),
1711
1711
  alt: "",
1712
1712
  className: "rs-deposit-address-dropdown-icon"
1713
1713
  }
@@ -1766,7 +1766,7 @@ function DepositAddressStep({
1766
1766
  ] }),
1767
1767
  pollingError && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-deposit-address-error", children: pollingError })
1768
1768
  ] }) }),
1769
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkLT3QKJI2cjs.PoweredBy, {})
1769
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk55QIUUIScjs.PoweredBy, {})
1770
1770
  ] });
1771
1771
  }
1772
1772
  DepositAddressStep.displayName = "DepositAddressStep";
@@ -1797,7 +1797,7 @@ function SolanaTokenSelectStep({
1797
1797
  setError(null);
1798
1798
  const portfolioBySymbol = {};
1799
1799
  try {
1800
- _chunkLT3QKJI2cjs.debugLog.call(void 0, debug, "solana-token-select", "portfolio:request", {
1800
+ _chunk55QIUUIScjs.debugLog.call(void 0, debug, "solana-token-select", "portfolio:request", {
1801
1801
  solanaAddress
1802
1802
  });
1803
1803
  const portfolio = await service.fetchSolanaPortfolio(solanaAddress);
@@ -1820,12 +1820,12 @@ function SolanaTokenSelectStep({
1820
1820
  };
1821
1821
  }
1822
1822
  }
1823
- _chunkLT3QKJI2cjs.debugLog.call(void 0, debug, "solana-token-select", "portfolio:success", {
1823
+ _chunk55QIUUIScjs.debugLog.call(void 0, debug, "solana-token-select", "portfolio:success", {
1824
1824
  symbols: Object.keys(portfolioBySymbol)
1825
1825
  });
1826
1826
  } catch (err) {
1827
1827
  if (!active) return;
1828
- _chunkLT3QKJI2cjs.debugError.call(void 0, debug, "solana-token-select", "portfolio:failure", err, {
1828
+ _chunk55QIUUIScjs.debugError.call(void 0, debug, "solana-token-select", "portfolio:failure", err, {
1829
1829
  solanaAddress
1830
1830
  });
1831
1831
  setError(
@@ -1879,7 +1879,7 @@ function SolanaTokenSelectStep({
1879
1879
  style: { paddingTop: 4, overflow: "auto", maxHeight: 340 },
1880
1880
  children: [
1881
1881
  loading && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-loading-state", style: { padding: "40px 12px" }, children: [
1882
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkLT3QKJI2cjs.Spinner, { className: "rs-text-tertiary" }),
1882
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk55QIUUIScjs.Spinner, { className: "rs-text-tertiary" }),
1883
1883
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-text-sm rs-text-tertiary", children: "Loading balances" })
1884
1884
  ] }),
1885
1885
  !loading && rows.length === 0 && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-empty-state", children: [
@@ -1910,13 +1910,13 @@ function SolanaTokenSelectStep({
1910
1910
  ] }),
1911
1911
  !loading && rows.length > 0 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-asset-list", children: rows.map((entry) => {
1912
1912
  const isSelected = selectedSymbol === entry.token.symbol;
1913
- const tokenIcon = _chunkNELAYNA3cjs.getTokenIcon.call(void 0, entry.token.symbol);
1914
- const chainIcon = _chunkNELAYNA3cjs.getChainIcon.call(void 0, "solana");
1913
+ const tokenIcon = _chunkZNHU72LIcjs.getTokenIcon.call(void 0, entry.token.symbol);
1914
+ const chainIcon = _chunkZNHU72LIcjs.getChainIcon.call(void 0, "solana");
1915
1915
  let formattedBalance;
1916
1916
  try {
1917
1917
  const raw = _viem.formatUnits.call(void 0, entry.balance, entry.token.decimals);
1918
1918
  const numeric = Number(raw);
1919
- formattedBalance = Number.isFinite(numeric) ? _chunkLT3QKJI2cjs.tokenFormatter.format(numeric) : raw;
1919
+ formattedBalance = Number.isFinite(numeric) ? _chunk55QIUUIScjs.tokenFormatter.format(numeric) : raw;
1920
1920
  } catch (e14) {
1921
1921
  formattedBalance = "...";
1922
1922
  }
@@ -1960,7 +1960,7 @@ function SolanaTokenSelectStep({
1960
1960
  ] })
1961
1961
  ] })
1962
1962
  ] }),
1963
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-asset-balance", children: entry.balanceUsd > 0 ? _chunkLT3QKJI2cjs.currencyFormatter.format(entry.balanceUsd) : `${formattedBalance} ${entry.token.symbol}` })
1963
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-asset-balance", children: entry.balanceUsd > 0 ? _chunk55QIUUIScjs.currencyFormatter.format(entry.balanceUsd) : `${formattedBalance} ${entry.token.symbol}` })
1964
1964
  ]
1965
1965
  },
1966
1966
  entry.token.symbol
@@ -1970,7 +1970,7 @@ function SolanaTokenSelectStep({
1970
1970
  }
1971
1971
  ),
1972
1972
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-step-footer", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1973
- _chunkLT3QKJI2cjs.Button,
1973
+ _chunk55QIUUIScjs.Button,
1974
1974
  {
1975
1975
  onClick: () => selectedEntry && onContinue(
1976
1976
  selectedEntry.token,
@@ -1982,7 +1982,7 @@ function SolanaTokenSelectStep({
1982
1982
  children: "Continue"
1983
1983
  }
1984
1984
  ) }),
1985
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkLT3QKJI2cjs.PoweredBy, {})
1985
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk55QIUUIScjs.PoweredBy, {})
1986
1986
  ] });
1987
1987
  }
1988
1988
 
@@ -2005,14 +2005,14 @@ function SolanaAmountStep({
2005
2005
  const raw = _viem.formatUnits.call(void 0, balance, token.decimals);
2006
2006
  const numeric = Number(raw);
2007
2007
  if (!Number.isFinite(numeric)) return raw;
2008
- return _chunkLT3QKJI2cjs.tokenFormatter.format(numeric);
2008
+ return _chunk55QIUUIScjs.tokenFormatter.format(numeric);
2009
2009
  } catch (e15) {
2010
2010
  return "...";
2011
2011
  }
2012
2012
  }, [balance, token.decimals]);
2013
2013
  const formattedBalanceUsd = _react.useMemo.call(void 0, () => {
2014
2014
  if (!Number.isFinite(balanceUsd) || balanceUsd <= 0) return null;
2015
- return _chunkLT3QKJI2cjs.currencyFormatter.format(balanceUsd);
2015
+ return _chunk55QIUUIScjs.currencyFormatter.format(balanceUsd);
2016
2016
  }, [balanceUsd]);
2017
2017
  const spendableBalance = _react.useMemo.call(void 0, () => {
2018
2018
  if (!isNativeSol(token)) return balance;
@@ -2027,7 +2027,7 @@ function SolanaAmountStep({
2027
2027
  const factor = 10 ** maxDecimals;
2028
2028
  const truncated = Math.floor(value * factor) / factor;
2029
2029
  const formatted = truncated.toFixed(maxDecimals).replace(/\.?0+$/, "");
2030
- _chunkLT3QKJI2cjs.debugLog.call(void 0, debug, "solana-amount", "amount:preset", {
2030
+ _chunk55QIUUIScjs.debugLog.call(void 0, debug, "solana-amount", "amount:preset", {
2031
2031
  percentage,
2032
2032
  symbol: token.symbol,
2033
2033
  formatted
@@ -2041,7 +2041,7 @@ function SolanaAmountStep({
2041
2041
  const handleContinue = () => {
2042
2042
  const numericAmount = parseFloat(amount);
2043
2043
  if (isNaN(numericAmount) || numericAmount <= 0) {
2044
- _chunkLT3QKJI2cjs.debugLog.call(void 0, debug, "solana-amount", "amount:invalid", {
2044
+ _chunk55QIUUIScjs.debugLog.call(void 0, debug, "solana-amount", "amount:invalid", {
2045
2045
  amount,
2046
2046
  reason: "nan-or-non-positive"
2047
2047
  });
@@ -2052,7 +2052,7 @@ function SolanaAmountStep({
2052
2052
  try {
2053
2053
  amountInUnits = _viem.parseUnits.call(void 0, amount, token.decimals);
2054
2054
  } catch (e17) {
2055
- _chunkLT3QKJI2cjs.debugLog.call(void 0, debug, "solana-amount", "amount:invalid", {
2055
+ _chunk55QIUUIScjs.debugLog.call(void 0, debug, "solana-amount", "amount:invalid", {
2056
2056
  amount,
2057
2057
  reason: "parse-units-failed"
2058
2058
  });
@@ -2061,7 +2061,7 @@ function SolanaAmountStep({
2061
2061
  }
2062
2062
  if (amountInUnits > spendableBalance) {
2063
2063
  const isReserveIssue = isNativeSol(token) && amountInUnits <= balance;
2064
- _chunkLT3QKJI2cjs.debugLog.call(void 0, debug, "solana-amount", "amount:invalid", {
2064
+ _chunk55QIUUIScjs.debugLog.call(void 0, debug, "solana-amount", "amount:invalid", {
2065
2065
  amount,
2066
2066
  balance: balance.toString(),
2067
2067
  spendableBalance: spendableBalance.toString(),
@@ -2073,7 +2073,7 @@ function SolanaAmountStep({
2073
2073
  );
2074
2074
  return;
2075
2075
  }
2076
- _chunkLT3QKJI2cjs.debugLog.call(void 0, debug, "solana-amount", "amount:continue", {
2076
+ _chunk55QIUUIScjs.debugLog.call(void 0, debug, "solana-amount", "amount:continue", {
2077
2077
  symbol: token.symbol,
2078
2078
  amount,
2079
2079
  amountInUnits: amountInUnits.toString()
@@ -2163,7 +2163,7 @@ function SolanaAmountStep({
2163
2163
  ] })
2164
2164
  ] }),
2165
2165
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-step-footer", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
2166
- _chunkLT3QKJI2cjs.Button,
2166
+ _chunk55QIUUIScjs.Button,
2167
2167
  {
2168
2168
  onClick: handleContinue,
2169
2169
  fullWidth: true,
@@ -2171,7 +2171,7 @@ function SolanaAmountStep({
2171
2171
  children: "Continue"
2172
2172
  }
2173
2173
  ) }),
2174
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkLT3QKJI2cjs.PoweredBy, {})
2174
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk55QIUUIScjs.PoweredBy, {})
2175
2175
  ] });
2176
2176
  }
2177
2177
 
@@ -2197,7 +2197,7 @@ function SolanaConfirmStep({
2197
2197
  }) {
2198
2198
  const [isSubmitting, setIsSubmitting] = _react.useState.call(void 0, false);
2199
2199
  const [error, setError] = _react.useState.call(void 0, null);
2200
- const targetSymbol = _chunkNELAYNA3cjs.getTokenSymbol.call(void 0, targetToken, targetChain);
2200
+ const targetSymbol = _chunkZNHU72LIcjs.getTokenSymbol.call(void 0, targetToken, targetChain);
2201
2201
  const isSameToken = token.symbol.toUpperCase() === targetSymbol.toUpperCase();
2202
2202
  const formattedAmount = amount && !Number.isNaN(Number(amount)) ? Number(amount).toLocaleString("en-US", { maximumFractionDigits: 6 }) : "0";
2203
2203
  const formattedReceiveAmount = (() => {
@@ -2214,7 +2214,7 @@ function SolanaConfirmStep({
2214
2214
  const receiveAmount = isSameToken ? formattedReceiveAmount : `~ ${formattedReceiveAmount}`;
2215
2215
  const handleConfirm = async () => {
2216
2216
  if (!solanaProvider) {
2217
- _chunkLT3QKJI2cjs.debugLog.call(void 0, debug, "solana-confirm", "submit:blocked", {
2217
+ _chunk55QIUUIScjs.debugLog.call(void 0, debug, "solana-confirm", "submit:blocked", {
2218
2218
  reason: "missing-provider"
2219
2219
  });
2220
2220
  setError("Solana wallet not connected");
@@ -2222,7 +2222,7 @@ function SolanaConfirmStep({
2222
2222
  }
2223
2223
  const parsedAmount = parseFloat(amount);
2224
2224
  if (isNaN(parsedAmount) || parsedAmount <= 0) {
2225
- _chunkLT3QKJI2cjs.debugLog.call(void 0, debug, "solana-confirm", "submit:blocked", {
2225
+ _chunk55QIUUIScjs.debugLog.call(void 0, debug, "solana-confirm", "submit:blocked", {
2226
2226
  reason: "invalid-amount",
2227
2227
  amount
2228
2228
  });
@@ -2231,7 +2231,7 @@ function SolanaConfirmStep({
2231
2231
  }
2232
2232
  setError(null);
2233
2233
  setIsSubmitting(true);
2234
- _chunkLT3QKJI2cjs.debugLog.call(void 0, debug, "solana-confirm", "submit:start", {
2234
+ _chunk55QIUUIScjs.debugLog.call(void 0, debug, "solana-confirm", "submit:start", {
2235
2235
  smartAccount,
2236
2236
  solanaAddress,
2237
2237
  solanaDepositAddress,
@@ -2240,7 +2240,7 @@ function SolanaConfirmStep({
2240
2240
  });
2241
2241
  try {
2242
2242
  const check = await service.checkAccount(smartAccount);
2243
- _chunkLT3QKJI2cjs.debugLog.call(void 0, debug, "solana-confirm", "check:success", {
2243
+ _chunk55QIUUIScjs.debugLog.call(void 0, debug, "solana-confirm", "check:success", {
2244
2244
  smartAccount,
2245
2245
  isRegistered: check.isRegistered,
2246
2246
  targetChain: check.targetChain,
@@ -2253,7 +2253,7 @@ function SolanaConfirmStep({
2253
2253
  }
2254
2254
  const connection = getSolanaConnection();
2255
2255
  const amountUnits = _viem.parseUnits.call(void 0, amount, token.decimals);
2256
- _chunkLT3QKJI2cjs.debugLog.call(void 0, debug, "solana-confirm", "tx:build:start", {
2256
+ _chunk55QIUUIScjs.debugLog.call(void 0, debug, "solana-confirm", "tx:build:start", {
2257
2257
  token: token.symbol,
2258
2258
  amount,
2259
2259
  amountUnits: amountUnits.toString()
@@ -2270,7 +2270,7 @@ function SolanaConfirmStep({
2270
2270
  token.mint,
2271
2271
  amountUnits
2272
2272
  );
2273
- _chunkLT3QKJI2cjs.debugLog.call(void 0, debug, "solana-confirm", "tx:build:success", {
2273
+ _chunk55QIUUIScjs.debugLog.call(void 0, debug, "solana-confirm", "tx:build:success", {
2274
2274
  token: token.symbol,
2275
2275
  instructionCount: transaction.instructions.length,
2276
2276
  feePayer: _optionalChain([transaction, 'access', _34 => _34.feePayer, 'optionalAccess', _35 => _35.toBase58, 'call', _36 => _36()]),
@@ -2281,15 +2281,15 @@ function SolanaConfirmStep({
2281
2281
  connection,
2282
2282
  transaction
2283
2283
  );
2284
- _chunkLT3QKJI2cjs.debugLog.call(void 0, debug, "solana-confirm", "tx:sent", {
2284
+ _chunk55QIUUIScjs.debugLog.call(void 0, debug, "solana-confirm", "tx:sent", {
2285
2285
  txHash,
2286
2286
  amountUnits: amountUnits.toString()
2287
2287
  });
2288
2288
  onConfirm(txHash, amountUnits.toString());
2289
2289
  } catch (err) {
2290
2290
  const raw = err instanceof Error ? err.message : "Transfer failed";
2291
- const message = _chunkLT3QKJI2cjs.formatUserError.call(void 0, raw);
2292
- _chunkLT3QKJI2cjs.debugError.call(void 0, debug, "solana-confirm", "submit:failure", err, {
2291
+ const message = _chunk55QIUUIScjs.formatUserError.call(void 0, raw);
2292
+ _chunk55QIUUIScjs.debugError.call(void 0, debug, "solana-confirm", "submit:failure", err, {
2293
2293
  smartAccount,
2294
2294
  token: token.symbol,
2295
2295
  amount
@@ -2312,15 +2312,15 @@ function SolanaConfirmStep({
2312
2312
  className: "rs-card-value",
2313
2313
  style: { display: "flex", alignItems: "center", gap: 8 },
2314
2314
  children: [
2315
- _chunkNELAYNA3cjs.getChainIcon.call(void 0, "solana") && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
2315
+ _chunkZNHU72LIcjs.getChainIcon.call(void 0, "solana") && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
2316
2316
  "img",
2317
2317
  {
2318
- src: _chunkNELAYNA3cjs.getChainIcon.call(void 0, "solana"),
2318
+ src: _chunkZNHU72LIcjs.getChainIcon.call(void 0, "solana"),
2319
2319
  alt: "",
2320
2320
  style: { width: 16, height: 16, borderRadius: 3 }
2321
2321
  }
2322
2322
  ),
2323
- _chunkNELAYNA3cjs.getChainName.call(void 0, "solana")
2323
+ _chunkZNHU72LIcjs.getChainName.call(void 0, "solana")
2324
2324
  ]
2325
2325
  }
2326
2326
  )
@@ -2333,15 +2333,15 @@ function SolanaConfirmStep({
2333
2333
  className: "rs-card-value",
2334
2334
  style: { display: "flex", alignItems: "center", gap: 8 },
2335
2335
  children: [
2336
- _chunkNELAYNA3cjs.getChainIcon.call(void 0, targetChain) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
2336
+ _chunkZNHU72LIcjs.getChainIcon.call(void 0, targetChain) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
2337
2337
  "img",
2338
2338
  {
2339
- src: _chunkNELAYNA3cjs.getChainIcon.call(void 0, targetChain),
2339
+ src: _chunkZNHU72LIcjs.getChainIcon.call(void 0, targetChain),
2340
2340
  alt: "",
2341
2341
  style: { width: 16, height: 16, borderRadius: 3 }
2342
2342
  }
2343
2343
  ),
2344
- _chunkNELAYNA3cjs.getChainName.call(void 0, targetChain)
2344
+ _chunkZNHU72LIcjs.getChainName.call(void 0, targetChain)
2345
2345
  ]
2346
2346
  }
2347
2347
  )
@@ -2360,10 +2360,10 @@ function SolanaConfirmStep({
2360
2360
  className: "rs-card-value",
2361
2361
  style: { display: "flex", alignItems: "center", gap: 6 },
2362
2362
  children: [
2363
- _chunkNELAYNA3cjs.getTokenIcon.call(void 0, token.symbol) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
2363
+ _chunkZNHU72LIcjs.getTokenIcon.call(void 0, token.symbol) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
2364
2364
  "img",
2365
2365
  {
2366
- src: _chunkNELAYNA3cjs.getTokenIcon.call(void 0, token.symbol),
2366
+ src: _chunkZNHU72LIcjs.getTokenIcon.call(void 0, token.symbol),
2367
2367
  alt: "",
2368
2368
  style: { width: 16, height: 16, borderRadius: "50%" }
2369
2369
  }
@@ -2383,10 +2383,10 @@ function SolanaConfirmStep({
2383
2383
  className: "rs-card-value",
2384
2384
  style: { display: "flex", alignItems: "center", gap: 6 },
2385
2385
  children: [
2386
- _chunkNELAYNA3cjs.getTokenIcon.call(void 0, targetSymbol) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
2386
+ _chunkZNHU72LIcjs.getTokenIcon.call(void 0, targetSymbol) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
2387
2387
  "img",
2388
2388
  {
2389
- src: _chunkNELAYNA3cjs.getTokenIcon.call(void 0, targetSymbol),
2389
+ src: _chunkZNHU72LIcjs.getTokenIcon.call(void 0, targetSymbol),
2390
2390
  alt: "",
2391
2391
  style: { width: 16, height: 16, borderRadius: "50%" }
2392
2392
  }
@@ -2422,7 +2422,7 @@ function SolanaConfirmStep({
2422
2422
  ] })
2423
2423
  ] }),
2424
2424
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-step-footer", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
2425
- _chunkLT3QKJI2cjs.Button,
2425
+ _chunk55QIUUIScjs.Button,
2426
2426
  {
2427
2427
  onClick: handleConfirm,
2428
2428
  loading: isSubmitting,
@@ -2431,7 +2431,7 @@ function SolanaConfirmStep({
2431
2431
  children: "Confirm Order"
2432
2432
  }
2433
2433
  ) }),
2434
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkLT3QKJI2cjs.PoweredBy, {})
2434
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk55QIUUIScjs.PoweredBy, {})
2435
2435
  ] });
2436
2436
  }
2437
2437
 
@@ -2454,7 +2454,7 @@ function DepositFlow({
2454
2454
  sourceToken: defaultSourceToken,
2455
2455
  amount: defaultAmount,
2456
2456
  recipient,
2457
- signerAddress = _chunkNELAYNA3cjs.DEFAULT_SIGNER_ADDRESS,
2457
+ signerAddress = _chunkZNHU72LIcjs.DEFAULT_SIGNER_ADDRESS,
2458
2458
  sessionChainIds,
2459
2459
  forceRegister = false,
2460
2460
  waitForFinalTx = true,
@@ -2479,18 +2479,20 @@ function DepositFlow({
2479
2479
  const [totalBalanceUsd, setTotalBalanceUsd] = _react.useState.call(void 0, 0);
2480
2480
  const [isConnectSelectionConfirmed, setIsConnectSelectionConfirmed] = _react.useState.call(void 0, false);
2481
2481
  const [selectedWalletId, setSelectedWalletId] = _react.useState.call(void 0, null);
2482
+ const flowModeRef = _react.useRef.call(void 0, null);
2482
2483
  const portfolioAssetsRef = _react.useRef.call(void 0, []);
2483
2484
  const stableWalletSignerRef = _react.useRef.call(void 0, null);
2484
2485
  const stableWalletSelectionKeyRef = _react.useRef.call(void 0, null);
2486
+ flowModeRef.current = flowMode;
2485
2487
  const logFlow = _react.useCallback.call(void 0,
2486
2488
  (message, data) => {
2487
- _chunkLT3QKJI2cjs.debugLog.call(void 0, debug, "deposit-flow", message, data);
2489
+ _chunk55QIUUIScjs.debugLog.call(void 0, debug, "deposit-flow", message, data);
2488
2490
  },
2489
2491
  [debug]
2490
2492
  );
2491
2493
  const logFlowError = _react.useCallback.call(void 0,
2492
2494
  (message, error, data) => {
2493
- _chunkLT3QKJI2cjs.debugError.call(void 0, debug, "deposit-flow", message, error, data);
2495
+ _chunk55QIUUIScjs.debugError.call(void 0, debug, "deposit-flow", message, error, data);
2494
2496
  },
2495
2497
  [debug]
2496
2498
  );
@@ -2597,7 +2599,7 @@ function DepositFlow({
2597
2599
  return {
2598
2600
  ownerAddress: dappAddress,
2599
2601
  walletClient: void 0,
2600
- publicClient: _nullishCoalesce(dappPublicClient, () => ( _chunkLT3QKJI2cjs.getPublicClient.call(void 0, targetChain))),
2602
+ publicClient: _nullishCoalesce(dappPublicClient, () => ( _chunk55QIUUIScjs.getPublicClient.call(void 0, targetChain))),
2601
2603
  switchChain: void 0
2602
2604
  };
2603
2605
  }
@@ -2606,7 +2608,7 @@ function DepositFlow({
2606
2608
  return {
2607
2609
  ownerAddress: dappWalletClient.account.address,
2608
2610
  walletClient: dappWalletClient,
2609
- publicClient: _nullishCoalesce(dappPublicClient, () => ( _chunkLT3QKJI2cjs.getPublicClient.call(void 0, fallbackChainId))),
2611
+ publicClient: _nullishCoalesce(dappPublicClient, () => ( _chunk55QIUUIScjs.getPublicClient.call(void 0, fallbackChainId))),
2610
2612
  switchChain: dappSwitchChain
2611
2613
  };
2612
2614
  }
@@ -2620,7 +2622,7 @@ function DepositFlow({
2620
2622
  return {
2621
2623
  ownerAddress: dappAddress,
2622
2624
  walletClient: void 0,
2623
- publicClient: _nullishCoalesce(dappPublicClient, () => ( _chunkLT3QKJI2cjs.getPublicClient.call(void 0, targetChain))),
2625
+ publicClient: _nullishCoalesce(dappPublicClient, () => ( _chunk55QIUUIScjs.getPublicClient.call(void 0, targetChain))),
2624
2626
  switchChain: void 0
2625
2627
  };
2626
2628
  }
@@ -2629,7 +2631,7 @@ function DepositFlow({
2629
2631
  return {
2630
2632
  ownerAddress: dappWalletClient.account.address,
2631
2633
  walletClient: dappWalletClient,
2632
- publicClient: _nullishCoalesce(dappPublicClient, () => ( _chunkLT3QKJI2cjs.getPublicClient.call(void 0, fallbackChainId))),
2634
+ publicClient: _nullishCoalesce(dappPublicClient, () => ( _chunk55QIUUIScjs.getPublicClient.call(void 0, fallbackChainId))),
2633
2635
  switchChain: dappSwitchChain
2634
2636
  };
2635
2637
  }
@@ -2637,7 +2639,7 @@ function DepositFlow({
2637
2639
  return {
2638
2640
  ownerAddress: reownWallet.address,
2639
2641
  walletClient: reownWallet.walletClient,
2640
- publicClient: _nullishCoalesce(reownWallet.publicClient, () => ( _chunkLT3QKJI2cjs.getPublicClient.call(void 0, targetChain))),
2642
+ publicClient: _nullishCoalesce(reownWallet.publicClient, () => ( _chunk55QIUUIScjs.getPublicClient.call(void 0, targetChain))),
2641
2643
  switchChain: reownWallet.switchChain
2642
2644
  };
2643
2645
  }
@@ -2675,7 +2677,7 @@ function DepositFlow({
2675
2677
  return {
2676
2678
  ownerAddress: dappAddress,
2677
2679
  walletClient: void 0,
2678
- publicClient: _nullishCoalesce(dappPublicClient, () => ( _chunkLT3QKJI2cjs.getPublicClient.call(void 0, targetChain))),
2680
+ publicClient: _nullishCoalesce(dappPublicClient, () => ( _chunk55QIUUIScjs.getPublicClient.call(void 0, targetChain))),
2679
2681
  switchChain: void 0
2680
2682
  };
2681
2683
  }
@@ -2809,6 +2811,9 @@ function DepositFlow({
2809
2811
  const handleNewDeposit = _react.useCallback.call(void 0, () => {
2810
2812
  setFlowMode(null);
2811
2813
  setStep({ type: "setup" });
2814
+ setIsConnectSelectionConfirmed(false);
2815
+ setSelectedWalletId(null);
2816
+ hasNavigatedBackRef.current = false;
2812
2817
  }, []);
2813
2818
  const handleSetupComplete = _react.useCallback.call(void 0,
2814
2819
  (smartAccount, solanaDepositAddress) => {
@@ -2889,8 +2894,8 @@ function DepositFlow({
2889
2894
  );
2890
2895
  const handleSolanaAmountContinue = _react.useCallback.call(void 0,
2891
2896
  (token, amount) => {
2892
- const targetSym = _chunkNELAYNA3cjs.getTokenSymbol.call(void 0, targetToken, targetChain);
2893
- const isTargetStable = _chunkNELAYNA3cjs.isStablecoinSymbol.call(void 0, targetSym);
2897
+ const targetSym = _chunkZNHU72LIcjs.getTokenSymbol.call(void 0, targetToken, targetChain);
2898
+ const isTargetStable = _chunkZNHU72LIcjs.isStablecoinSymbol.call(void 0, targetSym);
2894
2899
  const targetTokenPriceUsd = isTargetStable ? 1 : getTokenPriceUsd(targetSym);
2895
2900
  logFlow("solana:amount:continue", {
2896
2901
  token: token.symbol,
@@ -2971,8 +2976,8 @@ function DepositFlow({
2971
2976
  );
2972
2977
  const handleAmountContinue = _react.useCallback.call(void 0,
2973
2978
  (amount, targetAmount, balance) => {
2974
- const targetSym = _chunkNELAYNA3cjs.getTokenSymbol.call(void 0, targetToken, targetChain);
2975
- const isTargetStable = _chunkNELAYNA3cjs.isStablecoinSymbol.call(void 0, targetSym);
2979
+ const targetSym = _chunkZNHU72LIcjs.getTokenSymbol.call(void 0, targetToken, targetChain);
2980
+ const isTargetStable = _chunkZNHU72LIcjs.isStablecoinSymbol.call(void 0, targetSym);
2976
2981
  const targetTokenPriceUsd = isTargetStable ? 1 : getTokenPriceUsd(targetSym);
2977
2982
  setStep((prev) => {
2978
2983
  if (prev.type !== "amount") return prev;
@@ -3055,6 +3060,9 @@ function DepositFlow({
3055
3060
  );
3056
3061
  const hasNavigatedBackRef = _react.useRef.call(void 0, false);
3057
3062
  _react.useEffect.call(void 0, () => {
3063
+ if (flowModeRef.current) {
3064
+ return;
3065
+ }
3058
3066
  setIsConnectSelectionConfirmed(false);
3059
3067
  setSelectedWalletId(null);
3060
3068
  setFlowMode(null);
@@ -3105,7 +3113,7 @@ function DepositFlow({
3105
3113
  ]);
3106
3114
  if (showConnectStep) {
3107
3115
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-modal-body", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3108
- _chunkLT3QKJI2cjs.ConnectStep,
3116
+ _chunk55QIUUIScjs.ConnectStep,
3109
3117
  {
3110
3118
  walletOptions,
3111
3119
  selectedWalletId: selectedWalletIdEffective,
@@ -3165,7 +3173,7 @@ function DepositFlow({
3165
3173
  }
3166
3174
  ),
3167
3175
  step.type === "processing" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3168
- _chunkLT3QKJI2cjs.ProcessingStep,
3176
+ _chunk55QIUUIScjs.ProcessingStep,
3169
3177
  {
3170
3178
  smartAccount: step.smartAccount,
3171
3179
  txHash: step.txHash,
@@ -3282,7 +3290,7 @@ function DepositFlow({
3282
3290
  ) })
3283
3291
  ] }) : null,
3284
3292
  step.type === "processing" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3285
- _chunkLT3QKJI2cjs.ProcessingStep,
3293
+ _chunk55QIUUIScjs.ProcessingStep,
3286
3294
  {
3287
3295
  smartAccount: step.smartAccount,
3288
3296
  txHash: step.txHash,
@@ -3314,7 +3322,7 @@ function DepositFlow({
3314
3322
  if (_optionalChain([signerContext, 'access', _85 => _85.publicClient, 'access', _86 => _86.chain, 'optionalAccess', _87 => _87.id]) === chainId) {
3315
3323
  return signerContext.publicClient;
3316
3324
  }
3317
- return _chunkLT3QKJI2cjs.getPublicClient.call(void 0, chainId);
3325
+ return _chunk55QIUUIScjs.getPublicClient.call(void 0, chainId);
3318
3326
  };
3319
3327
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-modal-body", children: [
3320
3328
  step.type === "setup" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
@@ -3383,7 +3391,7 @@ function DepositFlow({
3383
3391
  }
3384
3392
  ),
3385
3393
  step.type === "processing" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3386
- _chunkLT3QKJI2cjs.ProcessingStep,
3394
+ _chunk55QIUUIScjs.ProcessingStep,
3387
3395
  {
3388
3396
  smartAccount: step.smartAccount,
3389
3397
  txHash: step.txHash,
@@ -3410,7 +3418,7 @@ function DepositFlow({
3410
3418
  // src/DepositModal.tsx
3411
3419
 
3412
3420
  var ReownDepositInner = _react.lazy.call(void 0,
3413
- () => Promise.resolve().then(() => _interopRequireWildcard(require("./DepositModalReown-EEXNSXI4.cjs"))).then((m) => ({ default: m.DepositModalReown }))
3421
+ () => Promise.resolve().then(() => _interopRequireWildcard(require("./DepositModalReown-2QKLWRRU.cjs"))).then((m) => ({ default: m.DepositModalReown }))
3414
3422
  );
3415
3423
  function DepositModal(props) {
3416
3424
  const needsReown = !!props.reownAppId;
@@ -3433,9 +3441,9 @@ function DepositModalInner({
3433
3441
  sourceToken,
3434
3442
  defaultAmount,
3435
3443
  recipient,
3436
- backendUrl = _chunkNELAYNA3cjs.DEFAULT_BACKEND_URL,
3444
+ backendUrl = _chunkZNHU72LIcjs.DEFAULT_BACKEND_URL,
3437
3445
  solanaRpcUrl,
3438
- signerAddress = _chunkNELAYNA3cjs.DEFAULT_SIGNER_ADDRESS,
3446
+ signerAddress = _chunkZNHU72LIcjs.DEFAULT_SIGNER_ADDRESS,
3439
3447
  sessionChainIds,
3440
3448
  forceRegister = false,
3441
3449
  waitForFinalTx = true,
@@ -3460,10 +3468,10 @@ function DepositModalInner({
3460
3468
  const [currentStepIndex, setCurrentStepIndex] = _react.useState.call(void 0, 0);
3461
3469
  const [totalBalanceUsd, setTotalBalanceUsd] = _react.useState.call(void 0, null);
3462
3470
  const backHandlerRef = _react.useRef.call(void 0, void 0);
3463
- const targetChain = _chunkNELAYNA3cjs.getChainId.call(void 0, targetChainProp);
3464
- const sourceChain = sourceChainProp ? _chunkNELAYNA3cjs.getChainId.call(void 0, sourceChainProp) : void 0;
3471
+ const targetChain = _chunkZNHU72LIcjs.getChainId.call(void 0, targetChainProp);
3472
+ const sourceChain = sourceChainProp ? _chunkZNHU72LIcjs.getChainId.call(void 0, sourceChainProp) : void 0;
3465
3473
  const service = _react.useMemo.call(void 0,
3466
- () => _chunkLT3QKJI2cjs.createDepositService.call(void 0, backendUrl, {
3474
+ () => _chunk55QIUUIScjs.createDepositService.call(void 0, backendUrl, {
3467
3475
  debug,
3468
3476
  debugScope: "service:deposit"
3469
3477
  }),
@@ -3471,7 +3479,7 @@ function DepositModalInner({
3471
3479
  );
3472
3480
  _react.useEffect.call(void 0, () => {
3473
3481
  if (isOpen && modalRef.current) {
3474
- _chunkLT3QKJI2cjs.applyTheme.call(void 0, modalRef.current, theme);
3482
+ _chunk55QIUUIScjs.applyTheme.call(void 0, modalRef.current, theme);
3475
3483
  }
3476
3484
  }, [isOpen, theme]);
3477
3485
  _react.useEffect.call(void 0, () => {
@@ -3510,7 +3518,7 @@ function DepositModalInner({
3510
3518
  const title = _nullishCoalesce(_optionalChain([branding, 'optionalAccess', _96 => _96.title]), () => ( "Deposit"));
3511
3519
  const canGoBack = currentStepIndex > 0 && currentStepIndex < 4 && backHandlerRef.current !== void 0;
3512
3520
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3513
- _chunkLT3QKJI2cjs.Modal,
3521
+ _chunk55QIUUIScjs.Modal,
3514
3522
  {
3515
3523
  isOpen,
3516
3524
  onClose,
@@ -3571,7 +3579,7 @@ function DepositModalInner({
3571
3579
  balance.title,
3572
3580
  ":"
3573
3581
  ] }),
3574
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-modal-header-balance-value", children: _nullishCoalesce(balance.amount, () => ( (totalBalanceUsd !== null ? _chunkLT3QKJI2cjs.currencyFormatter.format(totalBalanceUsd) : null))) })
3582
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-modal-header-balance-value", children: _nullishCoalesce(balance.amount, () => ( (totalBalanceUsd !== null ? _chunk55QIUUIScjs.currencyFormatter.format(totalBalanceUsd) : null))) })
3575
3583
  ] })
3576
3584
  ] }),
3577
3585
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-modal-header-nav-right", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,