@rhinestone/deposit-modal 0.20.0 → 0.20.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (49) hide show
  1. package/README.md +3 -0
  2. package/dist/{BankOnrampStep-NPGXAA7U.cjs → BankOnrampStep-3SNUX6V2.cjs} +11 -11
  3. package/dist/{BankOnrampStep-JG32OCM2.mjs → BankOnrampStep-4D24HVHV.mjs} +4 -4
  4. package/dist/{DepositModalReown-ALVWADG7.cjs → DepositModalReown-7EHOJTFW.cjs} +16 -16
  5. package/dist/{DepositModalReown-3FGTPER6.mjs → DepositModalReown-SYQ2SCHC.mjs} +3 -3
  6. package/dist/WithdrawModal-LLJLEYXZ.cjs +12 -0
  7. package/dist/{WithdrawModal-LL4Z5WZP.mjs → WithdrawModal-LXDIT4UV.mjs} +3 -3
  8. package/dist/{chunk-BTEG2VNZ.cjs → chunk-CIVFT5KR.cjs} +58 -58
  9. package/dist/{chunk-EKFXUF5A.cjs → chunk-D3R3O4CY.cjs} +1 -1
  10. package/dist/{chunk-6CTJFR3T.mjs → chunk-EJDBIWNH.mjs} +1 -1
  11. package/dist/{chunk-247GJH57.mjs → chunk-FW7ZMXQS.mjs} +444 -477
  12. package/dist/{chunk-PYRXOP2Y.cjs → chunk-IPHKBBUV.cjs} +2 -2
  13. package/dist/{chunk-HP7S7AD6.mjs → chunk-IPKT3FU6.mjs} +1 -1
  14. package/dist/{chunk-5QUWEFD4.mjs → chunk-JPX4MEHV.mjs} +1 -1
  15. package/dist/{chunk-CXRH5MKO.cjs → chunk-KXSU24RU.cjs} +354 -275
  16. package/dist/{chunk-OPT5EW6L.cjs → chunk-LVMNNMOZ.cjs} +2 -2
  17. package/dist/{chunk-FMUSY563.cjs → chunk-O5OW4S7L.cjs} +3 -3
  18. package/dist/{chunk-32ERBFMO.mjs → chunk-OZPMRTW3.mjs} +93 -14
  19. package/dist/{chunk-Z4RBTNKX.cjs → chunk-PVFEZ3UG.cjs} +596 -629
  20. package/dist/{chunk-XBJCZYBX.mjs → chunk-YQCRXJIL.mjs} +1 -1
  21. package/dist/{chunk-B2LZQIGB.mjs → chunk-ZOJMB5TZ.mjs} +1 -1
  22. package/dist/compliance.cjs +4 -4
  23. package/dist/compliance.mjs +3 -3
  24. package/dist/constants.cjs +2 -2
  25. package/dist/constants.d.cts +1 -1
  26. package/dist/constants.d.ts +1 -1
  27. package/dist/constants.mjs +1 -1
  28. package/dist/deposit.cjs +4 -4
  29. package/dist/deposit.d.cts +2 -2
  30. package/dist/deposit.d.ts +2 -2
  31. package/dist/deposit.mjs +3 -3
  32. package/dist/embed.cjs +14 -14
  33. package/dist/embed.d.cts +1 -1
  34. package/dist/embed.d.ts +1 -1
  35. package/dist/embed.mjs +4 -4
  36. package/dist/index.cjs +5 -5
  37. package/dist/index.d.cts +1 -1
  38. package/dist/index.d.ts +1 -1
  39. package/dist/index.mjs +4 -4
  40. package/dist/onramp.cjs +4 -4
  41. package/dist/onramp.mjs +3 -3
  42. package/dist/{types-CixUBhrM.d.cts → types-BEEMfNi2.d.cts} +4 -2
  43. package/dist/{types-BxSrazbq.d.ts → types-DQDUqzsZ.d.ts} +4 -2
  44. package/dist/withdraw.cjs +4 -4
  45. package/dist/withdraw.d.cts +2 -2
  46. package/dist/withdraw.d.ts +2 -2
  47. package/dist/withdraw.mjs +3 -3
  48. package/package.json +5 -5
  49. package/dist/WithdrawModal-5YWFJSYY.cjs +0 -12
@@ -94,7 +94,10 @@ var _chunkFVJKUTHFcjs = require('./chunk-FVJKUTHF.cjs');
94
94
 
95
95
 
96
96
 
97
- var _chunkCXRH5MKOcjs = require('./chunk-CXRH5MKO.cjs');
97
+
98
+
99
+
100
+ var _chunkKXSU24RUcjs = require('./chunk-KXSU24RU.cjs');
98
101
 
99
102
 
100
103
 
@@ -186,7 +189,6 @@ var _react = require('react');
186
189
 
187
190
 
188
191
 
189
-
190
192
  // src/components/steps/ConnectStep.tsx
191
193
 
192
194
 
@@ -255,11 +257,11 @@ SegmentedToggle.displayName = "SegmentedToggle";
255
257
 
256
258
  function ChainIcon({ chainId, className, loading }) {
257
259
  const badge = _chunkFKJ6EJHHcjs.getChainBadge.call(void 0, chainId);
258
- const catalogChain = _chunkCXRH5MKOcjs.useCatalogChain.call(void 0, _chunkCXRH5MKOcjs.catalogKeyForChain.call(void 0, chainId));
260
+ const catalogChain = _chunkKXSU24RUcjs.useCatalogChain.call(void 0, _chunkKXSU24RUcjs.catalogKeyForChain.call(void 0, chainId));
259
261
  const name = _nullishCoalesce(_optionalChain([catalogChain, 'optionalAccess', _2 => _2.name]), () => ( _chunkFKJ6EJHHcjs.getChainName.call(void 0, chainId)));
260
262
  const initial = (_nullishCoalesce(_optionalChain([catalogChain, 'optionalAccess', _3 => _3.name]), () => ( badge.shortLabel))).charAt(0);
261
263
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
262
- _chunkCXRH5MKOcjs.CdnIcon,
264
+ _chunkKXSU24RUcjs.CdnIcon,
263
265
  {
264
266
  src: _nullishCoalesce(_optionalChain([catalogChain, 'optionalAccess', _4 => _4.iconUrl]), () => ( _chunkFKJ6EJHHcjs.getChainIcon.call(void 0, chainId))),
265
267
  alt: name,
@@ -282,7 +284,7 @@ ChainIcon.displayName = "ChainIcon";
282
284
  // src/components/ui/WalletBadgeIcons/index.tsx
283
285
 
284
286
  function BadgeImage({ src, alt = "" }) {
285
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.CdnIcon, { src, alt }) });
287
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.CdnIcon, { src, alt }) });
286
288
  }
287
289
  var WALLET_BADGES = ["rabby", "phantom", "walletconnect"];
288
290
  function WalletBadgeIcons() {
@@ -335,7 +337,7 @@ var DAPP_IMPORT_CATALOG = [
335
337
  // src/components/ui/BrandIcons.tsx
336
338
 
337
339
  function ExchangeBadgeImage({ name }) {
338
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.CdnIcon, { src: _nullishCoalesce(_chunkCXRH5MKOcjs.getExchangeLogoSrc.call(void 0, name), () => ( void 0)) });
340
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.CdnIcon, { src: _nullishCoalesce(_chunkKXSU24RUcjs.getExchangeLogoSrc.call(void 0, name), () => ( void 0)) });
339
341
  }
340
342
  var CARD_NETWORKS = ["amex", "visa", "mastercard"];
341
343
  function CardNetworkIcons() {
@@ -343,7 +345,7 @@ function CardNetworkIcons() {
343
345
  "span",
344
346
  {
345
347
  className: `rs-card-network rs-card-network--${network}`,
346
- children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.CdnIcon, { src: _chunkFKJ6EJHHcjs.cdnIconUrl.call(void 0, "cards", network) })
348
+ children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.CdnIcon, { src: _chunkFKJ6EJHHcjs.cdnIconUrl.call(void 0, "cards", network) })
347
349
  },
348
350
  network
349
351
  )) });
@@ -362,7 +364,7 @@ function DappBadgeIcons() {
362
364
  ).filter(
363
365
  (brand) => Boolean(brand)
364
366
  );
365
- 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, _chunkCXRH5MKOcjs.CdnIcon, { src: brand.iconUrl, alt: brand.label }) }, brand.id)) });
367
+ 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, _chunkKXSU24RUcjs.CdnIcon, { src: brand.iconUrl, alt: brand.label }) }, brand.id)) });
366
368
  }
367
369
  DappBadgeIcons.displayName = "DappBadgeIcons";
368
370
  var DAPP_BADGE_COUNT = DAPP_BADGE_ORDER.length;
@@ -480,7 +482,7 @@ var CONNECT_META = /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fra
480
482
  ] });
481
483
  var EXTRA_EXCHANGE_COUNT = Math.max(
482
484
  0,
483
- _chunkCXRH5MKOcjs.SUPPORTED_CONNECT_EXCHANGE_COUNT - EXCHANGE_BADGE_COUNT
485
+ _chunkKXSU24RUcjs.SUPPORTED_CONNECT_EXCHANGE_COUNT - EXCHANGE_BADGE_COUNT
484
486
  );
485
487
  var EXCHANGE_META = /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
486
488
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ExchangeBadgeIcons, {}),
@@ -518,6 +520,7 @@ function ConnectStep({
518
520
  onPrefetchFiatMethod,
519
521
  recommendedMethod,
520
522
  onSelectFundFromExchange,
523
+ fundFromExchangeLoading,
521
524
  onRequestConnect,
522
525
  onConnect,
523
526
  onDisconnect,
@@ -539,7 +542,7 @@ function ConnectStep({
539
542
  if (onSelectTransferCrypto) {
540
543
  cryptoRows.push(
541
544
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
542
- _chunkCXRH5MKOcjs.ListRow,
545
+ _chunkKXSU24RUcjs.ListRow,
543
546
  {
544
547
  leading: TRANSFER_CRYPTO_LEADING,
545
548
  title: "Transfer crypto",
@@ -560,7 +563,7 @@ function ConnectStep({
560
563
  );
561
564
  cryptoRows.push(
562
565
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
563
- _chunkCXRH5MKOcjs.ListRow,
566
+ _chunkKXSU24RUcjs.ListRow,
564
567
  {
565
568
  leading: renderWalletLeading(row),
566
569
  title: collapseToExternal ? "External wallet" : row.label,
@@ -577,7 +580,7 @@ function ConnectStep({
577
580
  if (!hasSessionWallet && handleConnect) {
578
581
  cryptoRows.push(
579
582
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
580
- _chunkCXRH5MKOcjs.ListRow,
583
+ _chunkKXSU24RUcjs.ListRow,
581
584
  {
582
585
  leading: WALLET_LEADING,
583
586
  title: "Connect wallet",
@@ -592,13 +595,15 @@ function ConnectStep({
592
595
  if (onSelectFundFromExchange) {
593
596
  cryptoRows.push(
594
597
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
595
- _chunkCXRH5MKOcjs.ListRow,
598
+ _chunkKXSU24RUcjs.ListRow,
596
599
  {
597
600
  leading: EXCHANGE_LEADING,
598
601
  title: "Connect exchange",
599
602
  subtitle: "Instant - No limit",
600
603
  meta: EXCHANGE_META,
601
- onClick: onSelectFundFromExchange
604
+ onClick: onSelectFundFromExchange,
605
+ disabled: fundFromExchangeLoading,
606
+ trailing: fundFromExchangeLoading ? SMALL_SPINNER : void 0
602
607
  },
603
608
  "connect-exchange"
604
609
  )
@@ -607,7 +612,7 @@ function ConnectStep({
607
612
  if (onSelectMigrateAssets) {
608
613
  cryptoRows.push(
609
614
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
610
- _chunkCXRH5MKOcjs.ListRow,
615
+ _chunkKXSU24RUcjs.ListRow,
611
616
  {
612
617
  leading: MIGRATE_ASSETS_LEADING,
613
618
  title: "Migrate assets",
@@ -628,7 +633,7 @@ function ConnectStep({
628
633
  for (const opt of fiatPaymentMethods) {
629
634
  cashRows.push(
630
635
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
631
- _chunkCXRH5MKOcjs.ListRow,
636
+ _chunkKXSU24RUcjs.ListRow,
632
637
  {
633
638
  leading: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, FiatMethodIcon, { option: opt }),
634
639
  title: opt.label,
@@ -643,7 +648,7 @@ function ConnectStep({
643
648
  } else if (fiatLoading) {
644
649
  cashRows.push(
645
650
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
646
- _chunkCXRH5MKOcjs.ListRow,
651
+ _chunkKXSU24RUcjs.ListRow,
647
652
  {
648
653
  leading: SMALL_SPINNER,
649
654
  title: "Loading payment options\u2026",
@@ -691,7 +696,7 @@ function ConnectStep({
691
696
  ) : void 0
692
697
  }
693
698
  ),
694
- fiatNotice && (activeTab === "cash" || !hasCash) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.Callout, { variant: "warning", children: fiatNotice }),
699
+ fiatNotice && (activeTab === "cash" || !hasCash) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.Callout, { variant: "warning", children: fiatNotice }),
695
700
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
696
701
  "div",
697
702
  {
@@ -711,7 +716,7 @@ function ConnectStep({
711
716
  children: "Disconnect wallet"
712
717
  }
713
718
  ) }),
714
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.PoweredBy, {})
719
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.PoweredBy, {})
715
720
  ] });
716
721
  }
717
722
  ConnectStep.displayName = "ConnectStep";
@@ -734,13 +739,13 @@ function AssetSelectStep({
734
739
  const [selectedAssetId, setSelectedAssetId] = _react.useState.call(void 0, null);
735
740
  const [loading, setLoading] = _react.useState.call(void 0, true);
736
741
  const [error, setError] = _react.useState.call(void 0, null);
737
- const isDepositChain = _chunkCXRH5MKOcjs.useIsDepositChain.call(void 0, );
738
- const isExcludedByRestrictedList = _chunkCXRH5MKOcjs.useRestrictedListExclusion.call(void 0, );
739
- const { catalog } = _chunkCXRH5MKOcjs.useChainCatalog.call(void 0, );
740
- const chainName = _chunkCXRH5MKOcjs.useChainName.call(void 0, );
742
+ const isDepositChain = _chunkKXSU24RUcjs.useIsDepositChain.call(void 0, );
743
+ const isExcludedByRestrictedList = _chunkKXSU24RUcjs.useRestrictedListExclusion.call(void 0, );
744
+ const { catalog } = _chunkKXSU24RUcjs.useChainCatalog.call(void 0, );
745
+ const chainName = _chunkKXSU24RUcjs.useChainName.call(void 0, );
741
746
  const defaultAssetId = _react.useMemo.call(void 0, () => {
742
747
  if (!defaultSourceChain || !defaultSourceToken) return null;
743
- return _chunkCXRH5MKOcjs.getAssetId.call(void 0, {
748
+ return _chunkKXSU24RUcjs.getAssetId.call(void 0, {
744
749
  chainId: defaultSourceChain,
745
750
  token: defaultSourceToken
746
751
  });
@@ -765,7 +770,7 @@ function AssetSelectStep({
765
770
  try {
766
771
  const portfolio = await service.fetchPortfolio(address);
767
772
  if (!active) return;
768
- const portfolioAssets = _chunkCXRH5MKOcjs.portfolioToAssets.call(void 0, portfolio.tokens);
773
+ const portfolioAssets = _chunkKXSU24RUcjs.portfolioToAssets.call(void 0, portfolio.tokens);
769
774
  setAssets(portfolioAssets);
770
775
  emitAssetsUpdate(portfolioAssets);
771
776
  const hasNative = portfolioAssets.some(
@@ -834,7 +839,7 @@ function AssetSelectStep({
834
839
  return 0;
835
840
  });
836
841
  }, [assets, isDepositChain, isExcludedByRestrictedList]);
837
- const displays = _chunkCXRH5MKOcjs.useTokenDisplays.call(void 0,
842
+ const displays = _chunkKXSU24RUcjs.useTokenDisplays.call(void 0,
838
843
  filteredRows.map((asset) => ({
839
844
  chain: asset.chainId,
840
845
  address: asset.token,
@@ -861,7 +866,7 @@ function AssetSelectStep({
861
866
  const raw = _viem.formatUnits.call(void 0, BigInt(asset.balance), asset.decimals);
862
867
  const numeric = Number(raw);
863
868
  if (!Number.isFinite(numeric)) return raw;
864
- return _chunkCXRH5MKOcjs.tokenFormatter.format(numeric);
869
+ return _chunkKXSU24RUcjs.tokenFormatter.format(numeric);
865
870
  } catch (e3) {
866
871
  return asset.balance;
867
872
  }
@@ -880,7 +885,7 @@ function AssetSelectStep({
880
885
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkG264OM23cjs.Spinner, { className: "rs-text-tertiary" }),
881
886
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-text-sm rs-text-tertiary", children: "Loading balances" })
882
887
  ] }),
883
- error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.Callout, { variant: "error", children: error }),
888
+ error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.Callout, { variant: "error", children: error }),
884
889
  !loading && !error && rows.length === 0 && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-empty-state", children: [
885
890
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkG264OM23cjs.WalletIcon, { className: "rs-empty-icon" }),
886
891
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-empty-text", children: "No funds in connected wallet" }),
@@ -915,14 +920,14 @@ function AssetSelectStep({
915
920
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-asset-info", children: [
916
921
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-asset-icon-wrapper", children: [
917
922
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-asset-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
918
- _chunkCXRH5MKOcjs.TokenIcon,
923
+ _chunkKXSU24RUcjs.TokenIcon,
919
924
  {
920
925
  token: { chain: asset.chainId, address: asset.token },
921
926
  symbol: asset.symbol,
922
927
  fallback: asset.symbol.slice(0, 4)
923
928
  }
924
929
  ) }),
925
- chainIcon ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-asset-chain-badge", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.CdnIcon, { src: chainIcon, alt: chainName(asset.chainId) }) }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
930
+ chainIcon ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-asset-chain-badge", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.CdnIcon, { src: chainIcon, alt: chainName(asset.chainId) }) }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
926
931
  "span",
927
932
  {
928
933
  className: "rs-asset-chain-badge",
@@ -949,14 +954,14 @@ function AssetSelectStep({
949
954
  ] })
950
955
  ] })
951
956
  ] }),
952
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-asset-balance", children: asset.balanceUsd !== void 0 && asset.balanceUsd > 0 ? _chunkCXRH5MKOcjs.currencyFormatter.format(asset.balanceUsd) : tokenAmount !== "--" ? `${tokenAmount} ${asset.symbol}` : "--" })
957
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-asset-balance", children: asset.balanceUsd !== void 0 && asset.balanceUsd > 0 ? _chunkKXSU24RUcjs.currencyFormatter.format(asset.balanceUsd) : tokenAmount !== "--" ? `${tokenAmount} ${asset.symbol}` : "--" })
953
958
  ]
954
959
  },
955
960
  asset.id
956
961
  );
957
962
  }) }),
958
963
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
959
- _chunkCXRH5MKOcjs.Button,
964
+ _chunkKXSU24RUcjs.Button,
960
965
  {
961
966
  onClick: () => selectedAsset && onContinue(selectedAsset),
962
967
  disabled: !selectedAsset,
@@ -965,7 +970,7 @@ function AssetSelectStep({
965
970
  }
966
971
  )
967
972
  ] }),
968
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.PoweredBy, {})
973
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.PoweredBy, {})
969
974
  ] });
970
975
  }
971
976
  async function fetchNativeAssets(address, publicClient, existing, isDepositChain, catalogChain) {
@@ -973,7 +978,7 @@ async function fetchNativeAssets(address, publicClient, existing, isDepositChain
973
978
  const connectedChainId = _optionalChain([publicClient, 'access', _18 => _18.chain, 'optionalAccess', _19 => _19.id]);
974
979
  if (!connectedChainId) return [];
975
980
  if (!isDepositChain(connectedChainId)) return [];
976
- const id = _chunkCXRH5MKOcjs.getAssetId.call(void 0, {
981
+ const id = _chunkKXSU24RUcjs.getAssetId.call(void 0, {
977
982
  chainId: connectedChainId,
978
983
  token: _chunkFKJ6EJHHcjs.NATIVE_TOKEN_ADDRESS
979
984
  });
@@ -1162,7 +1167,7 @@ function AmountStep({
1162
1167
  _optionalChain([walletClient, 'optionalAccess', _30 => _30.chain, 'optionalAccess', _31 => _31.id]) && walletClient.chain.id !== asset.chainId
1163
1168
  );
1164
1169
  const targetChainId = _chunkFKJ6EJHHcjs.targetChainToChainId.call(void 0, targetChain);
1165
- const targetSymbol = _chunkCXRH5MKOcjs.useTokenDisplay.call(void 0, targetChainId, targetToken).symbol;
1170
+ const targetSymbol = _chunkKXSU24RUcjs.useTokenDisplay.call(void 0, targetChainId, targetToken).symbol;
1166
1171
  const isSourceStablecoin = _chunkFKJ6EJHHcjs.isStablecoinSymbol.call(void 0, asset.symbol);
1167
1172
  const derivedPriceUsd = _react.useMemo.call(void 0, () => {
1168
1173
  if (tokenPriceUsdOverride !== void 0 && tokenPriceUsdOverride > 0)
@@ -1192,7 +1197,7 @@ function AmountStep({
1192
1197
  const balanceTarget = _nullishCoalesce(balanceAddress, () => ( address));
1193
1198
  if (!balanceTarget || !publicClient) return;
1194
1199
  try {
1195
- const bal = _chunkCXRH5MKOcjs.isNativeAsset.call(void 0, asset) ? await publicClient.getBalance({ address: balanceTarget }) : await publicClient.readContract({
1200
+ const bal = _chunkKXSU24RUcjs.isNativeAsset.call(void 0, asset) ? await publicClient.getBalance({ address: balanceTarget }) : await publicClient.readContract({
1196
1201
  address: asset.token,
1197
1202
  abi: _viem.erc20Abi,
1198
1203
  functionName: "balanceOf",
@@ -1213,7 +1218,7 @@ function AmountStep({
1213
1218
  hasAttemptedSwitch.current = true;
1214
1219
  switchChain(asset.chainId).catch((err) => {
1215
1220
  const raw = err instanceof Error ? err.message : "Failed to switch chain";
1216
- setError(_chunkCXRH5MKOcjs.formatUserError.call(void 0, raw));
1221
+ setError(_chunkKXSU24RUcjs.formatUserError.call(void 0, raw));
1217
1222
  });
1218
1223
  }
1219
1224
  }, [chainMismatch, switchChain, asset.chainId]);
@@ -1266,7 +1271,7 @@ function AmountStep({
1266
1271
  const raw = _viem.formatUnits.call(void 0, balance, asset.decimals);
1267
1272
  const numeric = Number(raw);
1268
1273
  if (!Number.isFinite(numeric)) return raw;
1269
- return _chunkCXRH5MKOcjs.tokenFormatter.format(numeric);
1274
+ return _chunkKXSU24RUcjs.tokenFormatter.format(numeric);
1270
1275
  } catch (e9) {
1271
1276
  return "\u2026";
1272
1277
  }
@@ -1307,8 +1312,8 @@ function AmountStep({
1307
1312
  const exceedsBalance = Boolean(
1308
1313
  sourceAmountUnits !== null && balance !== null && sourceAmountUnits > balance
1309
1314
  );
1310
- const boundsFor = _chunkCXRH5MKOcjs.useDepositBounds.call(void 0, );
1311
- const boundViolation = _chunkCXRH5MKOcjs.depositBoundsViolation.call(void 0,
1315
+ const boundsFor = _chunkKXSU24RUcjs.useDepositBounds.call(void 0, );
1316
+ const boundViolation = _chunkKXSU24RUcjs.depositBoundsViolation.call(void 0,
1312
1317
  boundsFor(asset.chainId, asset.token),
1313
1318
  sourceAmountUnits
1314
1319
  );
@@ -1423,7 +1428,7 @@ function AmountStep({
1423
1428
  // that way and the payer has to be told, not left on a dead button.
1424
1429
  chainMismatch || lockedAmount === null || exceedsBalance || boundViolation !== null || knowsBalance && balance === null
1425
1430
  ) : chainMismatch || exceedsBalance || boundViolation !== null || blockedOnPricing || numericAmount === 0 && !isBelowMin || knowsBalance && balance === null;
1426
- const chainName = _chunkCXRH5MKOcjs.useChainName.call(void 0, );
1431
+ const chainName = _chunkKXSU24RUcjs.useChainName.call(void 0, );
1427
1432
  const sourceChainName = chainName(asset.chainId);
1428
1433
  const targetChainName = chainName(targetChainId);
1429
1434
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen", children: [
@@ -1431,7 +1436,7 @@ function AmountStep({
1431
1436
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkG264OM23cjs.BodyHeader, { icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkG264OM23cjs.WalletIcon, {}), title }),
1432
1437
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-amount-section", children: [
1433
1438
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-amount-display", children: [
1434
- payment ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-amount-fixed", "aria-label": "Amount to pay", children: lockedAmount ? `${_chunkCXRH5MKOcjs.tokenFormatter.format(Number(lockedAmount))} ${asset.symbol}` : "\u2014" }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1439
+ payment ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-amount-fixed", "aria-label": "Amount to pay", children: lockedAmount ? `${_chunkKXSU24RUcjs.tokenFormatter.format(Number(lockedAmount))} ${asset.symbol}` : "\u2014" }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1435
1440
  AnimatedAmountInput,
1436
1441
  {
1437
1442
  value: amount,
@@ -1448,13 +1453,13 @@ function AmountStep({
1448
1453
  " available",
1449
1454
  balanceUsd !== null && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
1450
1455
  " (~",
1451
- _chunkCXRH5MKOcjs.currencyFormatter.format(balanceUsd),
1456
+ _chunkKXSU24RUcjs.currencyFormatter.format(balanceUsd),
1452
1457
  ")"
1453
1458
  ] })
1454
1459
  ] }),
1455
1460
  minDepositUsd !== null && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-amount-meta-minimum", children: [
1456
1461
  "Min. deposit ",
1457
- _chunkCXRH5MKOcjs.currencyFormatter.format(minDepositUsd)
1462
+ _chunkKXSU24RUcjs.currencyFormatter.format(minDepositUsd)
1458
1463
  ] })
1459
1464
  ] })
1460
1465
  ] }),
@@ -1480,7 +1485,7 @@ function AmountStep({
1480
1485
  asset.symbol
1481
1486
  ] }),
1482
1487
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1483
- _chunkCXRH5MKOcjs.TokenIcon,
1488
+ _chunkKXSU24RUcjs.TokenIcon,
1484
1489
  {
1485
1490
  token: { chain: asset.chainId, address: asset.token },
1486
1491
  symbol: asset.symbol
@@ -1497,7 +1502,7 @@ function AmountStep({
1497
1502
  targetSymbol
1498
1503
  ] }),
1499
1504
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1500
- _chunkCXRH5MKOcjs.TokenIcon,
1505
+ _chunkKXSU24RUcjs.TokenIcon,
1501
1506
  {
1502
1507
  token: { chain: targetChainId, address: targetToken },
1503
1508
  symbol: targetSymbol
@@ -1507,10 +1512,10 @@ function AmountStep({
1507
1512
  ] }),
1508
1513
  balanceAfterUsd !== null && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-amount-detail-row", children: [
1509
1514
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: "Balance after deposit" }),
1510
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-value", children: _chunkCXRH5MKOcjs.currencyFormatter.format(balanceAfterUsd) })
1515
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-value", children: _chunkKXSU24RUcjs.currencyFormatter.format(balanceAfterUsd) })
1511
1516
  ] })
1512
1517
  ] }),
1513
- payment && paymentQuote === "unavailable" && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkCXRH5MKOcjs.Callout, { variant: "error", children: [
1518
+ payment && paymentQuote === "unavailable" && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkKXSU24RUcjs.Callout, { variant: "error", children: [
1514
1519
  "This payment can't be priced from ",
1515
1520
  asset.symbol,
1516
1521
  " on",
@@ -1518,13 +1523,13 @@ function AmountStep({
1518
1523
  sourceChainName,
1519
1524
  " right now. Try another asset."
1520
1525
  ] }),
1521
- blockedOnPricing && sourcePriceUnavailable && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkCXRH5MKOcjs.Callout, { variant: "error", children: [
1526
+ blockedOnPricing && sourcePriceUnavailable && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkKXSU24RUcjs.Callout, { variant: "error", children: [
1522
1527
  asset.symbol,
1523
1528
  " can't be priced right now, so this deposit can't be estimated. You can still send any amount to the deposit address."
1524
1529
  ] }),
1525
- error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.Callout, { variant: "error", children: error }),
1530
+ error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.Callout, { variant: "error", children: error }),
1526
1531
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1527
- _chunkCXRH5MKOcjs.Button,
1532
+ _chunkKXSU24RUcjs.Button,
1528
1533
  {
1529
1534
  onClick: handleContinue,
1530
1535
  fullWidth: true,
@@ -1533,7 +1538,7 @@ function AmountStep({
1533
1538
  }
1534
1539
  )
1535
1540
  ] }),
1536
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.PoweredBy, {})
1541
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.PoweredBy, {})
1537
1542
  ] });
1538
1543
  }
1539
1544
 
@@ -1562,14 +1567,14 @@ function ReviewDetails({
1562
1567
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: "Source chain" }),
1563
1568
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-review-detail-value", children: [
1564
1569
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: sourceChainName }),
1565
- sourceChainIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.CdnIcon, { src: sourceChainIcon }) })
1570
+ sourceChainIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.CdnIcon, { src: sourceChainIcon }) })
1566
1571
  ] })
1567
1572
  ] }),
1568
1573
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-review-detail-row", children: [
1569
1574
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: "Destination chain" }),
1570
1575
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-review-detail-value", children: [
1571
1576
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: targetChainName }),
1572
- targetChainIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.CdnIcon, { src: targetChainIcon }) })
1577
+ targetChainIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.CdnIcon, { src: targetChainIcon }) })
1573
1578
  ] })
1574
1579
  ] }),
1575
1580
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-review-detail-row", children: [
@@ -1584,21 +1589,21 @@ function ReviewDetails({
1584
1589
  " ",
1585
1590
  sendSymbol
1586
1591
  ] }),
1587
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.TokenIcon, { token: sendToken, symbol: sendSymbol }) })
1592
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.TokenIcon, { token: sendToken, symbol: sendSymbol }) })
1588
1593
  ] })
1589
1594
  ] }),
1590
1595
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-review-detail-row", children: [
1591
1596
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: "Receive" }),
1592
1597
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-review-detail-value", children: [
1593
1598
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: receiveDisplay }),
1594
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.TokenIcon, { token: receiveToken, symbol: receiveSymbol }) })
1599
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.TokenIcon, { token: receiveToken, symbol: receiveSymbol }) })
1595
1600
  ] })
1596
1601
  ] }),
1597
1602
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-review-detail-row", children: [
1598
1603
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: "Fees" }),
1599
1604
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-review-detail-value", children: [
1600
1605
  fee.display === null ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-skeleton rs-skeleton-fee", "aria-hidden": "true" }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { style: fee.struck ? { textDecoration: "line-through" } : void 0, children: fee.display }),
1601
- fee.tooltip !== void 0 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.Tooltip, { content: fee.tooltip, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-info", "aria-label": "Fee info", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkG264OM23cjs.InfoIcon, {}) }) })
1606
+ fee.tooltip !== void 0 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.Tooltip, { content: fee.tooltip, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-review-detail-info", "aria-label": "Fee info", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkG264OM23cjs.InfoIcon, {}) }) })
1602
1607
  ] })
1603
1608
  ] })
1604
1609
  ] });
@@ -1821,24 +1826,24 @@ function ConfirmStep({
1821
1826
  ]);
1822
1827
  const quote = setupReady && _optionalChain([quoteResult, 'optionalAccess', _71 => _71.requestKey]) === quoteRequestKey ? quoteResult.quote : null;
1823
1828
  const targetChainId = _chunkFKJ6EJHHcjs.targetChainToChainId.call(void 0, targetChain);
1824
- const resolvedTargetSymbol = _chunkCXRH5MKOcjs.useTokenDisplay.call(void 0, targetChainId, targetToken).symbol;
1829
+ const resolvedTargetSymbol = _chunkKXSU24RUcjs.useTokenDisplay.call(void 0, targetChainId, targetToken).symbol;
1825
1830
  const targetSymbol = sameRoute ? asset.symbol : resolvedTargetSymbol;
1826
- const sourceTrusted = _chunkCXRH5MKOcjs.useIsRecognizedToken.call(void 0, asset.chainId, asset.token);
1831
+ const sourceTrusted = _chunkKXSU24RUcjs.useIsRecognizedToken.call(void 0, asset.chainId, asset.token);
1827
1832
  const sourceChainName = _chunkFKJ6EJHHcjs.getChainName.call(void 0, asset.chainId);
1828
1833
  const targetChainName = _chunkFKJ6EJHHcjs.getChainName.call(void 0, targetChainId);
1829
1834
  const sourceChainIcon = _chunkFKJ6EJHHcjs.getChainIcon.call(void 0, asset.chainId);
1830
1835
  const targetChainIcon = _chunkFKJ6EJHHcjs.getChainIcon.call(void 0, targetChainId);
1831
- const formattedSendAmount = amount && Number.isFinite(Number(amount)) ? _nullishCoalesce(_chunkCXRH5MKOcjs.formatTokenAmount.call(void 0, Number(amount), asset.symbol), () => ( "0")) : "0";
1832
- const mustHaveQuote = !appFeesResolved || _chunkCXRH5MKOcjs.resolveAppFeeBps.call(void 0,
1836
+ const formattedSendAmount = amount && Number.isFinite(Number(amount)) ? _nullishCoalesce(_chunkKXSU24RUcjs.formatTokenAmount.call(void 0, Number(amount), asset.symbol), () => ( "0")) : "0";
1837
+ const mustHaveQuote = !appFeesResolved || _chunkKXSU24RUcjs.resolveAppFeeBps.call(void 0,
1833
1838
  appFees,
1834
1839
  `eip155:${quoteSource.chainId}`,
1835
1840
  quoteSource.token
1836
1841
  ) > 0;
1837
- const { display: feeDisplay, struck: feesFullySponsored } = _chunkCXRH5MKOcjs.quoteFeeRow.call(void 0,
1842
+ const { display: feeDisplay, struck: feesFullySponsored } = _chunkKXSU24RUcjs.quoteFeeRow.call(void 0,
1838
1843
  _optionalChain([quote, 'optionalAccess', _72 => _72.fees])
1839
1844
  );
1840
1845
  const directTransfer = sameRoute && !mustHaveQuote && !executeTransfer && !routeThroughAccount;
1841
- const permitEligible = enableGaslessDeposit && !_chunkCXRH5MKOcjs.isNativeAsset.call(void 0, asset) && !isDappImportAsset(asset) && !executeTransfer && !directTransfer && asset.chainId !== _chunkFKJ6EJHHcjs.HYPERCORE_CHAIN_ID;
1846
+ const permitEligible = enableGaslessDeposit && !_chunkKXSU24RUcjs.isNativeAsset.call(void 0, asset) && !isDappImportAsset(asset) && !executeTransfer && !directTransfer && asset.chainId !== _chunkFKJ6EJHHcjs.HYPERCORE_CHAIN_ID;
1842
1847
  const permitRequestKey = JSON.stringify([
1843
1848
  smartAccount.toLowerCase(),
1844
1849
  asset.chainId,
@@ -1848,9 +1853,9 @@ function ConfirmStep({
1848
1853
  address.toLowerCase()
1849
1854
  ]);
1850
1855
  const permit = permitEligible && !permitDisabled && _optionalChain([permitResult, 'optionalAccess', _73 => _73.requestKey]) === permitRequestKey ? permitResult.prepared : null;
1851
- const boundsFor = _chunkCXRH5MKOcjs.useDepositBounds.call(void 0, );
1856
+ const boundsFor = _chunkKXSU24RUcjs.useDepositBounds.call(void 0, );
1852
1857
  const activeRefusal = _nullishCoalesce((_optionalChain([previewRefusal, 'optionalAccess', _74 => _74.requestKey]) === quoteRequestKey ? previewRefusal.refusal : null), () => ( (_optionalChain([permitRefusal, 'optionalAccess', _75 => _75.requestKey]) === permitRequestKey ? permitRefusal.refusal : null)));
1853
- const blockedReason = activeRefusal ? _chunkCXRH5MKOcjs.describePolicyRefusal.call(void 0,
1858
+ const blockedReason = activeRefusal ? _chunkKXSU24RUcjs.describePolicyRefusal.call(void 0,
1854
1859
  activeRefusal,
1855
1860
  boundsFor(quoteSource.chainId, quoteSource.token)
1856
1861
  ) : null;
@@ -1866,12 +1871,12 @@ function ConfirmStep({
1866
1871
  const receiveDisplay = (() => {
1867
1872
  if (directTransfer) return `${formattedSendAmount} ${asset.symbol}`;
1868
1873
  if (quote) {
1869
- const quoted = _chunkCXRH5MKOcjs.formatQuotedReceive.call(void 0, quote.output, targetSymbol);
1874
+ const quoted = _chunkKXSU24RUcjs.formatQuotedReceive.call(void 0, quote.output, targetSymbol);
1870
1875
  if (quoted !== void 0) return quoted;
1871
1876
  }
1872
1877
  const usdValue = Number(targetAmount);
1873
1878
  const sourceAmountUsd = Number.isFinite(usdValue) && usdValue > 0 ? usdValue : void 0;
1874
- const estimate = _chunkCXRH5MKOcjs.formatReceiveEstimate.call(void 0, {
1879
+ const estimate = _chunkKXSU24RUcjs.formatReceiveEstimate.call(void 0, {
1875
1880
  sourceAmount: Number.isFinite(Number(amount)) ? Number(amount) : void 0,
1876
1881
  sourceSymbol: asset.symbol,
1877
1882
  targetSymbol,
@@ -1880,19 +1885,19 @@ function ConfirmStep({
1880
1885
  // The target is the curated deposit destination, so a stablecoin target
1881
1886
  // estimates at $1 when unquoted (DepositFlow skips fetching stablecoin
1882
1887
  // target prices). Not applied to the source — that can be a held token.
1883
- prices: targetTokenPriceUsd !== null && targetTokenPriceUsd > 0 ? { [targetSymbol.toUpperCase()]: targetTokenPriceUsd } : _chunkCXRH5MKOcjs.isDisplayStablecoinSymbol.call(void 0, targetSymbol) ? { [targetSymbol.toUpperCase()]: 1 } : {}
1888
+ prices: targetTokenPriceUsd !== null && targetTokenPriceUsd > 0 ? { [targetSymbol.toUpperCase()]: targetTokenPriceUsd } : _chunkKXSU24RUcjs.isDisplayStablecoinSymbol.call(void 0, targetSymbol) ? { [targetSymbol.toUpperCase()]: 1 } : {}
1884
1889
  });
1885
1890
  if (estimate !== void 0) return estimate;
1886
1891
  return targetSymbol;
1887
1892
  })();
1888
1893
  const servedExpectedSeconds = _nullishCoalesce(_optionalChain([quote, 'optionalAccess', _76 => _76.timing, 'optionalAccess', _77 => _77.expectedSeconds]), () => ( (quote && Number.isFinite(quote.estimatedFillTimeSeconds) ? quote.estimatedFillTimeSeconds : void 0)));
1889
- const estimatedTimeDisplay = servedExpectedSeconds !== void 0 ? _chunkCXRH5MKOcjs.formatExpectedDuration.call(void 0, servedExpectedSeconds) : estimatedTime;
1894
+ const estimatedTimeDisplay = servedExpectedSeconds !== void 0 ? _chunkKXSU24RUcjs.formatExpectedDuration.call(void 0, servedExpectedSeconds) : estimatedTime;
1890
1895
  _react.useEffect.call(void 0, () => {
1891
1896
  if (chainMismatch && switchChain && !hasAttemptedSwitch.current) {
1892
1897
  hasAttemptedSwitch.current = true;
1893
1898
  switchChain(asset.chainId).catch((err) => {
1894
1899
  const raw = err instanceof Error ? err.message : "Failed to switch chain";
1895
- setError(_chunkCXRH5MKOcjs.formatUserError.call(void 0, raw));
1900
+ setError(_chunkKXSU24RUcjs.formatUserError.call(void 0, raw));
1896
1901
  });
1897
1902
  }
1898
1903
  }, [chainMismatch, switchChain, asset.chainId]);
@@ -1920,7 +1925,7 @@ function ConfirmStep({
1920
1925
  }).then((result) => {
1921
1926
  if (cancelled) return;
1922
1927
  setPreviewSettledKey(quoteRequestKey);
1923
- if (_chunkCXRH5MKOcjs.isDepositPolicyRefusal.call(void 0, result)) {
1928
+ if (_chunkKXSU24RUcjs.isDepositPolicyRefusal.call(void 0, result)) {
1924
1929
  setQuoteResult(null);
1925
1930
  setPreviewRefusal({
1926
1931
  requestKey: quoteRequestKey,
@@ -1970,7 +1975,7 @@ function ConfirmStep({
1970
1975
  if (cancelled) return;
1971
1976
  setPermitSettledKey(permitRequestKey);
1972
1977
  if (prepared === null) return;
1973
- if (_chunkCXRH5MKOcjs.isDepositPolicyRefusal.call(void 0, prepared)) {
1978
+ if (_chunkKXSU24RUcjs.isDepositPolicyRefusal.call(void 0, prepared)) {
1974
1979
  setPermitRefusal({
1975
1980
  requestKey: permitRequestKey,
1976
1981
  refusal: prepared.policyRefusal
@@ -2105,9 +2110,9 @@ function ConfirmStep({
2105
2110
  );
2106
2111
  } catch (err) {
2107
2112
  const raw = err instanceof Error ? err.message : "Signing failed";
2108
- const safeToTransfer = !submitStarted || err instanceof _chunkCXRH5MKOcjs.PermitDepositSubmitError && err.safeToTransfer;
2113
+ const safeToTransfer = !submitStarted || err instanceof _chunkKXSU24RUcjs.PermitDepositSubmitError && err.safeToTransfer;
2109
2114
  if (safeToTransfer) setPermitDisabled(true);
2110
- const message = safeToTransfer ? _chunkCXRH5MKOcjs.formatUserError.call(void 0, raw) : "Deposit submission status is uncertain. Check your activity before trying a transfer.";
2115
+ const message = safeToTransfer ? _chunkKXSU24RUcjs.formatUserError.call(void 0, raw) : "Deposit submission status is uncertain. Check your activity before trying a transfer.";
2111
2116
  setError(message);
2112
2117
  _optionalChain([onError, 'optionalCall', _78 => _78(message, "PERMIT_ERROR", raw)]);
2113
2118
  } finally {
@@ -2128,7 +2133,7 @@ function ConfirmStep({
2128
2133
  const result = await executeTransfer(amountUnits);
2129
2134
  hash = result.txHash;
2130
2135
  resolvedSourceToken = result.sourceToken;
2131
- } else if (_chunkCXRH5MKOcjs.isNativeAsset.call(void 0, asset)) {
2136
+ } else if (_chunkKXSU24RUcjs.isNativeAsset.call(void 0, asset)) {
2132
2137
  hash = await walletClient.sendTransaction({
2133
2138
  account,
2134
2139
  chain,
@@ -2159,8 +2164,8 @@ function ConfirmStep({
2159
2164
  );
2160
2165
  } catch (err) {
2161
2166
  const raw = err instanceof Error ? err.message : "Transfer failed";
2162
- const uncertain = _chunkCXRH5MKOcjs.isSubmissionUncertain.call(void 0, err);
2163
- const message = uncertain ? "Deposit submission status is uncertain. Check your activity before trying again." : _chunkCXRH5MKOcjs.formatUserError.call(void 0, raw);
2167
+ const uncertain = _chunkKXSU24RUcjs.isSubmissionUncertain.call(void 0, err);
2168
+ const message = uncertain ? "Deposit submission status is uncertain. Check your activity before trying again." : _chunkKXSU24RUcjs.formatUserError.call(void 0, raw);
2164
2169
  if (uncertain) setSubmissionUncertain(true);
2165
2170
  setError(message);
2166
2171
  _optionalChain([onError, 'optionalCall', _80 => _80(message, "TRANSFER_ERROR", raw)]);
@@ -2188,9 +2193,9 @@ function ConfirmStep({
2188
2193
  fee: { display: feeDisplay, struck: feesFullySponsored }
2189
2194
  }
2190
2195
  ),
2191
- (_nullishCoalesce(error, () => ( blockedReason))) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.Callout, { variant: "error", children: _nullishCoalesce(error, () => ( blockedReason)) }),
2196
+ (_nullishCoalesce(error, () => ( blockedReason))) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.Callout, { variant: "error", children: _nullishCoalesce(error, () => ( blockedReason)) }),
2192
2197
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
2193
- _chunkCXRH5MKOcjs.Button,
2198
+ _chunkKXSU24RUcjs.Button,
2194
2199
  {
2195
2200
  onClick: handleConfirm,
2196
2201
  loading: isSubmitting,
@@ -2219,7 +2224,7 @@ function ConfirmStep({
2219
2224
  ] }),
2220
2225
  !permit && permitEligible && permitUnavailable && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "rs-gasless-note", children: permitUnavailable === "permit2-approval-required" ? "Gasless unavailable until Permit2 is approved; Continue sends a token transaction." : "This wallet/token cannot use gasless authorization; Continue sends a token transaction." })
2221
2226
  ] }),
2222
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.PoweredBy, {})
2227
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.PoweredBy, {})
2223
2228
  ] });
2224
2229
  }
2225
2230
 
@@ -2240,9 +2245,9 @@ function QrReviewStep({
2240
2245
  }) {
2241
2246
  const [quote, setQuote] = _react.useState.call(void 0, { state: "loading", value: null });
2242
2247
  const targetChainId = _chunkFKJ6EJHHcjs.targetChainToChainId.call(void 0, targetChain);
2243
- const targetSymbol = _chunkCXRH5MKOcjs.useTokenDisplay.call(void 0, targetChainId, targetToken).symbol;
2244
- const sourceTrusted = _chunkCXRH5MKOcjs.useIsRecognizedToken.call(void 0, asset.chainId, asset.token);
2245
- const boundsFor = _chunkCXRH5MKOcjs.useDepositBounds.call(void 0, );
2248
+ const targetSymbol = _chunkKXSU24RUcjs.useTokenDisplay.call(void 0, targetChainId, targetToken).symbol;
2249
+ const sourceTrusted = _chunkKXSU24RUcjs.useIsRecognizedToken.call(void 0, asset.chainId, asset.token);
2250
+ const boundsFor = _chunkKXSU24RUcjs.useDepositBounds.call(void 0, );
2246
2251
  _react.useEffect.call(void 0, () => {
2247
2252
  let cancelled = false;
2248
2253
  let units;
@@ -2264,7 +2269,7 @@ function QrReviewStep({
2264
2269
  amount: units.toString()
2265
2270
  }).then((result) => {
2266
2271
  if (cancelled) return;
2267
- if (_chunkCXRH5MKOcjs.isDepositPolicyRefusal.call(void 0, result)) {
2272
+ if (_chunkKXSU24RUcjs.isDepositPolicyRefusal.call(void 0, result)) {
2268
2273
  setQuote({
2269
2274
  state: "refused",
2270
2275
  value: null,
@@ -2282,26 +2287,26 @@ function QrReviewStep({
2282
2287
  cancelled = true;
2283
2288
  };
2284
2289
  }, [service, smartAccount, asset, amount]);
2285
- const formattedSendAmount = _nullishCoalesce(_chunkCXRH5MKOcjs.formatTokenAmount.call(void 0, Number(amount), asset.symbol), () => ( amount));
2290
+ const formattedSendAmount = _nullishCoalesce(_chunkKXSU24RUcjs.formatTokenAmount.call(void 0, Number(amount), asset.symbol), () => ( amount));
2286
2291
  const receiveDisplay = (() => {
2287
2292
  if (quote.value) {
2288
- const quoted = _chunkCXRH5MKOcjs.formatQuotedReceive.call(void 0, quote.value.output, targetSymbol);
2293
+ const quoted = _chunkKXSU24RUcjs.formatQuotedReceive.call(void 0, quote.value.output, targetSymbol);
2289
2294
  if (quoted !== void 0) return quoted;
2290
2295
  }
2291
2296
  const usdValue = Number(targetAmount);
2292
- const estimate = _chunkCXRH5MKOcjs.formatReceiveEstimate.call(void 0, {
2297
+ const estimate = _chunkKXSU24RUcjs.formatReceiveEstimate.call(void 0, {
2293
2298
  sourceAmount: Number.isFinite(Number(amount)) ? Number(amount) : void 0,
2294
2299
  sourceSymbol: asset.symbol,
2295
2300
  targetSymbol,
2296
2301
  sourceAmountUsd: Number.isFinite(usdValue) && usdValue > 0 ? usdValue : void 0,
2297
2302
  sourceTrusted,
2298
- prices: targetTokenPriceUsd !== null && targetTokenPriceUsd > 0 ? { [targetSymbol.toUpperCase()]: targetTokenPriceUsd } : _chunkCXRH5MKOcjs.isDisplayStablecoinSymbol.call(void 0, targetSymbol) ? { [targetSymbol.toUpperCase()]: 1 } : {}
2303
+ prices: targetTokenPriceUsd !== null && targetTokenPriceUsd > 0 ? { [targetSymbol.toUpperCase()]: targetTokenPriceUsd } : _chunkKXSU24RUcjs.isDisplayStablecoinSymbol.call(void 0, targetSymbol) ? { [targetSymbol.toUpperCase()]: 1 } : {}
2299
2304
  });
2300
2305
  return _nullishCoalesce(estimate, () => ( targetSymbol));
2301
2306
  })();
2302
2307
  const expectedSeconds = _nullishCoalesce(_optionalChain([quote, 'access', _81 => _81.value, 'optionalAccess', _82 => _82.timing, 'optionalAccess', _83 => _83.expectedSeconds]), () => ( (quote.value && Number.isFinite(quote.value.estimatedFillTimeSeconds) ? quote.value.estimatedFillTimeSeconds : void 0)));
2303
- const estimatedTime = expectedSeconds !== void 0 ? _chunkCXRH5MKOcjs.formatExpectedDuration.call(void 0, expectedSeconds) : quote.state === "loading" ? "\u2026" : "\u2014";
2304
- const { display: quotedFee, struck } = _chunkCXRH5MKOcjs.quoteFeeRow.call(void 0, _optionalChain([quote, 'access', _84 => _84.value, 'optionalAccess', _85 => _85.fees]));
2308
+ const estimatedTime = expectedSeconds !== void 0 ? _chunkKXSU24RUcjs.formatExpectedDuration.call(void 0, expectedSeconds) : quote.state === "loading" ? "\u2026" : "\u2014";
2309
+ const { display: quotedFee, struck } = _chunkKXSU24RUcjs.quoteFeeRow.call(void 0, _optionalChain([quote, 'access', _84 => _84.value, 'optionalAccess', _85 => _85.fees]));
2305
2310
  const feeDisplay = quote.state === "unavailable" || quote.state === "refused" ? "\u2014" : quotedFee;
2306
2311
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen", children: [
2307
2312
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen-body rs-screen-body--gap-32", children: [
@@ -2323,13 +2328,13 @@ function QrReviewStep({
2323
2328
  fee: { display: feeDisplay, struck }
2324
2329
  }
2325
2330
  ),
2326
- quote.state === "refused" && quote.refusal && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.Callout, { variant: "error", children: _chunkCXRH5MKOcjs.describePolicyRefusal.call(void 0,
2331
+ quote.state === "refused" && quote.refusal && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.Callout, { variant: "error", children: _chunkKXSU24RUcjs.describePolicyRefusal.call(void 0,
2327
2332
  quote.refusal,
2328
2333
  boundsFor(asset.chainId, asset.token)
2329
2334
  ) }),
2330
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.Button, { onClick: onClose, fullWidth: true, children: "Close" })
2335
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.Button, { onClick: onClose, fullWidth: true, children: "Close" })
2331
2336
  ] }),
2332
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.PoweredBy, {})
2337
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.PoweredBy, {})
2333
2338
  ] });
2334
2339
  }
2335
2340
  QrReviewStep.displayName = "QrReviewStep";
@@ -2366,7 +2371,7 @@ function DepositAddressSkeleton({
2366
2371
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-deposit-address-dropdown-label", children: "Supported chain" }),
2367
2372
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-deposit-address-dropdown-trigger", children: [
2368
2373
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
2369
- _chunkCXRH5MKOcjs.CdnIcon,
2374
+ _chunkKXSU24RUcjs.CdnIcon,
2370
2375
  {
2371
2376
  src: chainIcon,
2372
2377
  className: "rs-deposit-address-dropdown-icon"
@@ -2382,7 +2387,7 @@ function DepositAddressSkeleton({
2382
2387
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-deposit-address-min", children: [
2383
2388
  "Min.$",
2384
2389
  (_nullishCoalesce(_optionalChain([uiConfig, 'optionalAccess', _86 => _86.minDepositUsd]), () => ( 0.1))).toFixed(2),
2385
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.Tooltip, { content: "Minimum deposit amount required for the selected chain.", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
2390
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.Tooltip, { content: "Minimum deposit amount required for the selected chain.", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
2386
2391
  _chunkG264OM23cjs.InfoIcon,
2387
2392
  {
2388
2393
  className: "rs-deposit-address-min-icon",
@@ -2432,7 +2437,7 @@ function DepositAddressSkeleton({
2432
2437
  }
2433
2438
  )
2434
2439
  ] }),
2435
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.PoweredBy, {})
2440
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.PoweredBy, {})
2436
2441
  ] });
2437
2442
  }
2438
2443
  DepositAddressSkeleton.displayName = "DepositAddressSkeleton";
@@ -2444,9 +2449,9 @@ var INITIAL_POLL_INTERVAL = 3e3;
2444
2449
  var MAX_POLL_INTERVAL = 3e4;
2445
2450
  var BACKOFF_MULTIPLIER = 1.5;
2446
2451
  function isEventForTx(event, txHash) {
2447
- const eventTxHash = _chunkCXRH5MKOcjs.getEventTxHash.call(void 0, event);
2452
+ const eventTxHash = _chunkKXSU24RUcjs.getEventTxHash.call(void 0, event);
2448
2453
  if (!eventTxHash) return false;
2449
- return _chunkCXRH5MKOcjs.txRefsMatch.call(void 0, eventTxHash, txHash);
2454
+ return _chunkKXSU24RUcjs.txRefsMatch.call(void 0, eventTxHash, txHash);
2450
2455
  }
2451
2456
  function truncateHash(hash) {
2452
2457
  return `${hash.slice(0, 4)}\u2026${hash.slice(-4)}`;
@@ -2634,7 +2639,7 @@ function DepositNotification({
2634
2639
  status,
2635
2640
  txHash
2636
2641
  ]);
2637
- const explorerTxUrl = _chunkCXRH5MKOcjs.useExplorerTxUrl.call(void 0, );
2642
+ const explorerTxUrl = _chunkKXSU24RUcjs.useExplorerTxUrl.call(void 0, );
2638
2643
  const sourceExplorerUrl = sourceChain === "unknown" ? void 0 : explorerTxUrl(sourceChain, txHash);
2639
2644
  const destExplorerUrl = destinationTxHash ? explorerTxUrl(_chunkFKJ6EJHHcjs.targetChainToChainId.call(void 0, targetChain), destinationTxHash) : null;
2640
2645
  const title = status === "complete" ? "Deposit completed" : status === "failed" ? "Deposit failed" : "Deposit received and processing\u2026";
@@ -2828,7 +2833,7 @@ function asString(value) {
2828
2833
  return typeof value === "string" ? value : void 0;
2829
2834
  }
2830
2835
  function resolveSolanaTokenMeta(token) {
2831
- const matched = token ? _chunkCXRH5MKOcjs.resolveSolanaToken.call(void 0, token) : void 0;
2836
+ const matched = token ? _chunkKXSU24RUcjs.resolveSolanaToken.call(void 0, token) : void 0;
2832
2837
  return matched ? { sourceSymbol: matched.symbol, sourceDecimals: matched.decimals } : {};
2833
2838
  }
2834
2839
  function getDepositEventDetails(event) {
@@ -2889,7 +2894,7 @@ function selectionAsAsset(chainId, symbol, offer, catalogChain) {
2889
2894
  }
2890
2895
  function TokenGlyph({ symbol, token }) {
2891
2896
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
2892
- _chunkCXRH5MKOcjs.TokenIcon,
2897
+ _chunkKXSU24RUcjs.TokenIcon,
2893
2898
  {
2894
2899
  token,
2895
2900
  symbol,
@@ -2921,14 +2926,14 @@ function DepositAddressStep({
2921
2926
  onError
2922
2927
  }) {
2923
2928
  const hasSolana = Boolean(solanaDepositAddress);
2924
- const offer = _chunkCXRH5MKOcjs.useDepositOffer.call(void 0, );
2929
+ const offer = _chunkKXSU24RUcjs.useDepositOffer.call(void 0, );
2925
2930
  const BASE_CHAIN_ID2 = 8453;
2926
- const evmChainIds = _chunkCXRH5MKOcjs.useDepositChainIds.call(void 0, );
2927
- const { catalog, isLoading: catalogLoading, shortlist } = _chunkCXRH5MKOcjs.useChainCatalog.call(void 0, );
2931
+ const evmChainIds = _chunkKXSU24RUcjs.useDepositChainIds.call(void 0, );
2932
+ const { catalog, isLoading: catalogLoading, shortlist } = _chunkKXSU24RUcjs.useChainCatalog.call(void 0, );
2928
2933
  const catalogFor = _react.useCallback.call(void 0,
2929
2934
  (chain) => {
2930
2935
  if (!catalog) return void 0;
2931
- const key = _chunkCXRH5MKOcjs.catalogKeyForChain.call(void 0, chain);
2936
+ const key = _chunkKXSU24RUcjs.catalogKeyForChain.call(void 0, chain);
2932
2937
  return typeof key === "number" ? catalog.byChainId.get(key) : catalog.byCaip2.get(key);
2933
2938
  },
2934
2939
  [catalog]
@@ -3047,10 +3052,10 @@ function DepositAddressStep({
3047
3052
  });
3048
3053
  return address ? { chain: sourceChainId, address } : void 0;
3049
3054
  };
3050
- const assetStore = _chunkCXRH5MKOcjs.useAssetStore.call(void 0, );
3055
+ const assetStore = _chunkKXSU24RUcjs.useAssetStore.call(void 0, );
3051
3056
  const assetStoreRef = _react.useRef.call(void 0, assetStore);
3052
3057
  assetStoreRef.current = assetStore;
3053
- const paymentDecimals = _chunkCXRH5MKOcjs.useTokenDisplay.call(void 0,
3058
+ const paymentDecimals = _chunkKXSU24RUcjs.useTokenDisplay.call(void 0,
3054
3059
  typeof sourceChainId === "number" ? sourceChainId : void 0,
3055
3060
  sourceTokenIdentity
3056
3061
  ).decimals;
@@ -3187,10 +3192,10 @@ function DepositAddressStep({
3187
3192
  return;
3188
3193
  }
3189
3194
  const event = status.lastEvent;
3190
- const eventTxHash = _chunkCXRH5MKOcjs.isDepositEvent.call(void 0, event) ? _nullishCoalesce(_chunkCXRH5MKOcjs.getEventTxHash.call(void 0, event), () => ( null)) : null;
3195
+ const eventTxHash = _chunkKXSU24RUcjs.isDepositEvent.call(void 0, event) ? _nullishCoalesce(_chunkKXSU24RUcjs.getEventTxHash.call(void 0, event), () => ( null)) : null;
3191
3196
  if (baselineTxHashRef.current === void 0) {
3192
3197
  baselineTxHashRef.current = eventTxHash;
3193
- } else if (eventTxHash && (!baselineTxHashRef.current || !_chunkCXRH5MKOcjs.txRefsMatch.call(void 0, eventTxHash, baselineTxHashRef.current))) {
3198
+ } else if (eventTxHash && (!baselineTxHashRef.current || !_chunkKXSU24RUcjs.txRefsMatch.call(void 0, eventTxHash, baselineTxHashRef.current))) {
3194
3199
  const details = getDepositEventDetails(event);
3195
3200
  const chainId = _nullishCoalesce(details.chainId, () => ( "unknown"));
3196
3201
  const amount = _nullishCoalesce(details.amount, () => ( "0"));
@@ -3200,8 +3205,8 @@ function DepositAddressStep({
3200
3205
  isTrackingRef.current = true;
3201
3206
  const isEvmToken = token ? /^0x[a-fA-F0-9]{40}$/.test(token) : false;
3202
3207
  const knownChain = chainId === "unknown" ? void 0 : chainId;
3203
- const sourceDecimals = _nullishCoalesce(details.sourceDecimals, () => ( (token && knownChain !== void 0 ? _nullishCoalesce(_optionalChain([_chunkCXRH5MKOcjs.resolveCuratedToken.call(void 0, token, knownChain), 'optionalAccess', _149 => _149.decimals]), () => ( (knownChain === "hypercore" ? void 0 : _optionalChain([assetStoreRef, 'access', _150 => _150.current, 'optionalAccess', _151 => _151.peekMeta, 'call', _152 => _152(
3204
- _nullishCoalesce(_chunkCXRH5MKOcjs.assetIdFor.call(void 0, knownChain, token), () => ( ""))
3208
+ const sourceDecimals = _nullishCoalesce(details.sourceDecimals, () => ( (token && knownChain !== void 0 ? _nullishCoalesce(_optionalChain([_chunkKXSU24RUcjs.resolveCuratedToken.call(void 0, token, knownChain), 'optionalAccess', _149 => _149.decimals]), () => ( (knownChain === "hypercore" ? void 0 : _optionalChain([assetStoreRef, 'access', _150 => _150.current, 'optionalAccess', _151 => _151.peekMeta, 'call', _152 => _152(
3209
+ _nullishCoalesce(_chunkKXSU24RUcjs.assetIdFor.call(void 0, knownChain, token), () => ( ""))
3205
3210
  ), 'optionalAccess', _153 => _153.decimals])))) : void 0)));
3206
3211
  const directTransfer = typeof chainId === "number" && isEvmToken && isSameRoute(
3207
3212
  chainId,
@@ -3274,8 +3279,8 @@ function DepositAddressStep({
3274
3279
  if (offer.status === "error") {
3275
3280
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-screen", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen-body", children: [
3276
3281
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkG264OM23cjs.BodyHeader, { icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkG264OM23cjs.TransferCryptoIcon, {}), title: "Transfer crypto" }),
3277
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.Callout, { variant: "error", children: "The tokens this app accepts could not be loaded, so there is no deposit address to show." }),
3278
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.Button, { onClick: offer.retry, fullWidth: true, children: "Try again" })
3282
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.Callout, { variant: "error", children: "The tokens this app accepts could not be loaded, so there is no deposit address to show." }),
3283
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.Button, { onClick: offer.retry, fullWidth: true, children: "Try again" })
3279
3284
  ] }) });
3280
3285
  }
3281
3286
  if (chainOptions.length === 0) {
@@ -3284,7 +3289,7 @@ function DepositAddressStep({
3284
3289
  }
3285
3290
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-screen", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen-body", children: [
3286
3291
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkG264OM23cjs.BodyHeader, { icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkG264OM23cjs.TransferCryptoIcon, {}), title: "Transfer crypto" }),
3287
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.Callout, { variant: "error", children: catalog ? "This app does not accept deposits from any chain available here." : "Supported chains are unavailable right now, so there is no deposit address to show. Close and try again in a moment." })
3292
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.Callout, { variant: "error", children: catalog ? "This app does not accept deposits from any chain available here." : "Supported chains are unavailable right now, so there is no deposit address to show. Close and try again in a moment." })
3288
3293
  ] }) });
3289
3294
  }
3290
3295
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen rs-step--with-notifications", children: [
@@ -3305,7 +3310,7 @@ function DepositAddressStep({
3305
3310
  },
3306
3311
  children: [
3307
3312
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3308
- _chunkCXRH5MKOcjs.CdnIcon,
3313
+ _chunkKXSU24RUcjs.CdnIcon,
3309
3314
  {
3310
3315
  src: _nullishCoalesce(_optionalChain([catalogFor, 'call', _164 => _164(sourceChainId), 'optionalAccess', _165 => _165.iconUrl]), () => ( _chunkFKJ6EJHHcjs.getChainIcon.call(void 0, sourceChainId))),
3311
3316
  className: "rs-deposit-address-dropdown-icon"
@@ -3324,7 +3329,7 @@ function DepositAddressStep({
3324
3329
  onClick: () => handleSelectChain(chainId),
3325
3330
  children: [
3326
3331
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3327
- _chunkCXRH5MKOcjs.CdnIcon,
3332
+ _chunkKXSU24RUcjs.CdnIcon,
3328
3333
  {
3329
3334
  src: _nullishCoalesce(_optionalChain([catalogFor, 'call', _166 => _166(chainId), 'optionalAccess', _167 => _167.iconUrl]), () => ( _chunkFKJ6EJHHcjs.getChainIcon.call(void 0, chainId))),
3330
3335
  className: "rs-deposit-address-dropdown-icon"
@@ -3342,7 +3347,7 @@ function DepositAddressStep({
3342
3347
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-deposit-address-min", children: [
3343
3348
  "Min.$",
3344
3349
  (_chunkFKJ6EJHHcjs.isHyperCoreDestination.call(void 0, targetChain) || isHyperCore ? Math.max(_chunkFKJ6EJHHcjs.HYPERCORE_MIN_DEPOSIT_USD, _nullishCoalesce(_optionalChain([uiConfig, 'optionalAccess', _168 => _168.minDepositUsd]), () => ( 0))) : _nullishCoalesce(_optionalChain([uiConfig, 'optionalAccess', _169 => _169.minDepositUsd]), () => ( 0.1))).toFixed(2),
3345
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.Tooltip, { content: "Minimum deposit amount required for the selected chain.", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3350
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.Tooltip, { content: "Minimum deposit amount required for the selected chain.", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
3346
3351
  _chunkG264OM23cjs.InfoIcon,
3347
3352
  {
3348
3353
  className: "rs-deposit-address-min-icon",
@@ -3419,7 +3424,7 @@ function DepositAddressStep({
3419
3424
  ] }),
3420
3425
  !withholdPaymentQr && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-deposit-address-value", children: displayAddress })
3421
3426
  ] }),
3422
- paymentUnquotable && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkCXRH5MKOcjs.Callout, { variant: "error", children: [
3427
+ paymentUnquotable && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkKXSU24RUcjs.Callout, { variant: "error", children: [
3423
3428
  "This payment can't be priced from ",
3424
3429
  sourceTokenSymbol,
3425
3430
  " on",
@@ -3471,12 +3476,12 @@ function DepositAddressStep({
3471
3476
  },
3472
3477
  deposit.id
3473
3478
  )) }),
3474
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.PoweredBy, {})
3479
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.PoweredBy, {})
3475
3480
  ] });
3476
3481
  }
3477
3482
  DepositAddressStep.displayName = "DepositAddressStep";
3478
3483
 
3479
- // src/components/steps/FiatOnrampStep.tsx
3484
+ // src/components/steps/RampOrderStep.tsx
3480
3485
 
3481
3486
 
3482
3487
  // src/core/swapped.ts
@@ -3528,7 +3533,7 @@ function FinalisingDepositStep() {
3528
3533
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "rs-finalising-subtitle", children: "We are depositing your funds to the application." })
3529
3534
  ] })
3530
3535
  ] }),
3531
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.PoweredBy, {})
3536
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.PoweredBy, {})
3532
3537
  ] });
3533
3538
  }
3534
3539
  FinalisingDepositStep.displayName = "FinalisingDepositStep";
@@ -3549,7 +3554,7 @@ function SwappedOrderTracker({
3549
3554
  onRetry
3550
3555
  }) {
3551
3556
  const formattedAmount = formatTrackerAmount(amount);
3552
- const title = terminal ? terminal.kind === "cancelled" ? "Order cancelled" : "Deposit failed" : formattedAmount ? `Depositing ${formattedAmount} ${currency}` : `Depositing ${currency}`;
3557
+ const title = terminal ? _nullishCoalesce(terminal.title, () => ( (terminal.kind === "cancelled" ? "Order cancelled" : "Deposit failed"))) : formattedAmount ? `Depositing ${formattedAmount} ${currency}` : `Depositing ${currency}`;
3553
3558
  const labels = [
3554
3559
  STEP_LABELS[0],
3555
3560
  `${currency} received`,
@@ -3607,7 +3612,7 @@ function SwappedOrderTracker({
3607
3612
  }
3608
3613
  )
3609
3614
  ] }),
3610
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.PoweredBy, {})
3615
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.PoweredBy, {})
3611
3616
  ] });
3612
3617
  }
3613
3618
  function formatTrackerAmount(amount) {
@@ -3627,16 +3632,10 @@ var DEPOSIT_POLL_FAST_INTERVAL_MS = 500;
3627
3632
  var IFRAME_LOAD_TIMEOUT_MS = 15e3;
3628
3633
  var SWAPPED_SUCCESS_HANDOFF_DELAY_MS = 1400;
3629
3634
  var SWAPPED_IFRAME_ORIGINS = new Set(SWAPPED_ORIGINS);
3630
- var SWAPPED_TERMINAL_STATUSES = /* @__PURE__ */ new Set([
3631
- "order_completed",
3632
- "order_broadcasted"
3633
- ]);
3634
- var SWAPPED_STATUS_VALUES = /* @__PURE__ */ new Set([
3635
- "payment_pending",
3636
- "order_completed",
3637
- "order_broadcasted",
3638
- "order_cancelled"
3639
- ]);
3635
+ var OUTCOMES = {
3636
+ failed: { title: "Order failed", message: "Any charge will be refunded." },
3637
+ refunded: { title: "Order refunded", message: "Your payment was returned." }
3638
+ };
3640
3639
  var SWAPPED_GO_BACK_KEY = "SWAPPED_GO_BACK";
3641
3640
  var OPEN_FAILED_MESSAGE = "We could not open your browser.";
3642
3641
  var OPEN_FAILED_CODE = "SWAPPED_BROWSER_UNAVAILABLE";
@@ -3682,19 +3681,20 @@ function parseSwappedIframeMessage(raw) {
3682
3681
  const obj = data;
3683
3682
  const inner = obj.data && typeof obj.data === "object" ? obj.data : obj;
3684
3683
  const rawStatus = _nullishCoalesce(_nullishCoalesce(inner.order_status, () => ( inner.status)), () => ( obj.status));
3685
- if (typeof rawStatus !== "string" || !SWAPPED_STATUS_VALUES.has(rawStatus)) {
3686
- return null;
3687
- }
3688
3684
  const asString2 = (v) => typeof v === "string" && v.length > 0 ? v : void 0;
3685
+ const state = typeof rawStatus === "string" ? _chunkKXSU24RUcjs.hostedOrderStateFromSwapped.call(void 0,
3686
+ rawStatus,
3687
+ _nullishCoalesce(asString2(inner.transaction_id), () => ( asString2(obj.transactionId)))
3688
+ ) : null;
3689
+ if (!state) return null;
3689
3690
  return {
3690
- status: rawStatus,
3691
+ state,
3691
3692
  orderId: _nullishCoalesce(asString2(inner.order_id), () => ( asString2(obj.orderId))),
3692
3693
  externalCustomerId: _nullishCoalesce(_nullishCoalesce(_nullishCoalesce(asString2(inner.external_customer_id), () => ( asString2(obj.external_customer_id))), () => ( asString2(inner.externalCustomerId))), () => ( asString2(obj.externalCustomerId))),
3693
3694
  orderCrypto: assetSymbol(
3694
3695
  _nullishCoalesce(asString2(inner.order_crypto), () => ( asString2(obj.orderCrypto)))
3695
3696
  ),
3696
- orderCryptoAmount: _nullishCoalesce(asString2(inner.order_crypto_amount), () => ( asString2(obj.orderCryptoAmount))),
3697
- transactionId: _nullishCoalesce(asString2(inner.transaction_id), () => ( asString2(obj.transactionId)))
3697
+ orderCryptoAmount: _nullishCoalesce(asString2(inner.order_crypto_amount), () => ( asString2(obj.orderCryptoAmount)))
3698
3698
  };
3699
3699
  }
3700
3700
  function SwappedProviderStep({
@@ -3705,7 +3705,7 @@ function SwappedProviderStep({
3705
3705
  iframeTitle,
3706
3706
  loadErrorCode,
3707
3707
  loadErrorFallback,
3708
- bannerForStatus,
3708
+ cancelledMessage,
3709
3709
  onSwappedComplete,
3710
3710
  onSwappedFailed,
3711
3711
  onClose,
@@ -3738,6 +3738,8 @@ function SwappedProviderStep({
3738
3738
  const expectedExternalCustomerIdRef = _react.useRef.call(void 0, null);
3739
3739
  const baselineDepositTxHashRef = _react.useRef.call(void 0, void 0);
3740
3740
  const currentDepositTxHashRef = _react.useRef.call(void 0, null);
3741
+ const deliveryTxHashRef = _react.useRef.call(void 0, null);
3742
+ deliveryTxHashRef.current = _nullishCoalesce(_optionalChain([orderState, 'optionalAccess', _172 => _172.deliveryTxHash]), () => ( null));
3741
3743
  const fastDepositPollEnabledRef = _react.useRef.call(void 0, false);
3742
3744
  const rescheduleDepositPollRef = _react.useRef.call(void 0,
3743
3745
  null
@@ -3787,18 +3789,18 @@ function SwappedProviderStep({
3787
3789
  if (cancelled) return;
3788
3790
  if (!isTrustedSwappedWidgetUrl(res.url)) {
3789
3791
  setLoadError(loadErrorFallback);
3790
- _optionalChain([onErrorRef, 'access', _172 => _172.current, 'optionalCall', _173 => _173(loadErrorFallback, loadErrorCode)]);
3792
+ _optionalChain([onErrorRef, 'access', _173 => _173.current, 'optionalCall', _174 => _174(loadErrorFallback, loadErrorCode)]);
3791
3793
  return;
3792
3794
  }
3793
3795
  setWidgetUrl(res.url);
3794
3796
  expectedExternalCustomerIdRef.current = res.externalCustomerId;
3795
- _optionalChain([onAttemptConsumed, 'optionalCall', _174 => _174(res.externalCustomerId)]);
3797
+ _optionalChain([onAttemptConsumed, 'optionalCall', _175 => _175(res.externalCustomerId)]);
3796
3798
  expectedOrderUuidRef.current = res.orderId;
3797
3799
  }).catch((err) => {
3798
3800
  if (cancelled) return;
3799
3801
  const message = err instanceof Error ? err.message : loadErrorFallback;
3800
3802
  setLoadError(message);
3801
- _optionalChain([onErrorRef, 'access', _175 => _175.current, 'optionalCall', _176 => _176(message, loadErrorCode)]);
3803
+ _optionalChain([onErrorRef, 'access', _176 => _176.current, 'optionalCall', _177 => _177(message, loadErrorCode)]);
3802
3804
  });
3803
3805
  return () => {
3804
3806
  cancelled = true;
@@ -3813,7 +3815,7 @@ function SwappedProviderStep({
3813
3815
  const timer = setTimeout(() => {
3814
3816
  const message = "Iframe took too long to load.";
3815
3817
  setLoadError(message);
3816
- _optionalChain([onErrorRef, 'access', _177 => _177.current, 'optionalCall', _178 => _178(message, "SWAPPED_IFRAME_TIMEOUT")]);
3818
+ _optionalChain([onErrorRef, 'access', _178 => _178.current, 'optionalCall', _179 => _179(message, "SWAPPED_IFRAME_TIMEOUT")]);
3817
3819
  }, IFRAME_LOAD_TIMEOUT_MS);
3818
3820
  return () => clearTimeout(timer);
3819
3821
  }, [openExternally, widgetUrl, iframeLoaded, loadError]);
@@ -3823,7 +3825,7 @@ function SwappedProviderStep({
3823
3825
  setIframeSrc(nextSrc);
3824
3826
  if (nextSrc && assignedIframeUrlRef.current !== nextSrc) {
3825
3827
  assignedIframeUrlRef.current = nextSrc;
3826
- _optionalChain([onProviderHandoffRef, 'access', _179 => _179.current, 'optionalCall', _180 => _180()]);
3828
+ _optionalChain([onProviderHandoffRef, 'access', _180 => _180.current, 'optionalCall', _181 => _181()]);
3827
3829
  }
3828
3830
  }, [openExternally, widgetUrl, loadError, retryToken]);
3829
3831
  const openPaymentPage = async (url) => {
@@ -3833,11 +3835,11 @@ function SwappedProviderStep({
3833
3835
  try {
3834
3836
  await openExternally(url);
3835
3837
  setHandoffOpened(true);
3836
- _optionalChain([onProviderHandoff, 'optionalCall', _181 => _181()]);
3838
+ _optionalChain([onProviderHandoff, 'optionalCall', _182 => _182()]);
3837
3839
  } catch (error) {
3838
3840
  openedUrlRef.current = null;
3839
3841
  setLoadError(OPEN_FAILED_MESSAGE);
3840
- _optionalChain([onErrorRef, 'access', _182 => _182.current, 'optionalCall', _183 => _183(
3842
+ _optionalChain([onErrorRef, 'access', _183 => _183.current, 'optionalCall', _184 => _184(
3841
3843
  error instanceof Error && error.message ? error.message : OPEN_FAILED_MESSAGE,
3842
3844
  OPEN_FAILED_CODE
3843
3845
  )]);
@@ -3861,7 +3863,10 @@ function SwappedProviderStep({
3861
3863
  if (cancelled) return;
3862
3864
  const isCurrentOrder = res !== null && res.orderId === expectedOrderUuidRef.current;
3863
3865
  if (isCurrentOrder) {
3864
- setOrderState(res);
3866
+ setOrderState((prev) => ({
3867
+ ...res,
3868
+ ..._chunkKXSU24RUcjs.mergeHostedOrderState.call(void 0, prev, res)
3869
+ }));
3865
3870
  }
3866
3871
  } catch (e25) {
3867
3872
  }
@@ -3886,8 +3891,8 @@ function SwappedProviderStep({
3886
3891
  const doc = globalThis.document;
3887
3892
  const onVisible = () => {
3888
3893
  if (doc.visibilityState !== "visible") return;
3889
- _optionalChain([rescheduleStatusPollRef, 'access', _184 => _184.current, 'optionalCall', _185 => _185(0)]);
3890
- _optionalChain([rescheduleDepositPollRef, 'access', _186 => _186.current, 'optionalCall', _187 => _187(0)]);
3894
+ _optionalChain([rescheduleStatusPollRef, 'access', _185 => _185.current, 'optionalCall', _186 => _186(0)]);
3895
+ _optionalChain([rescheduleDepositPollRef, 'access', _187 => _187.current, 'optionalCall', _188 => _188(0)]);
3891
3896
  };
3892
3897
  doc.addEventListener("visibilitychange", onVisible);
3893
3898
  return () => doc.removeEventListener("visibilitychange", onVisible);
@@ -3898,15 +3903,29 @@ function SwappedProviderStep({
3898
3903
  async function pollDeposit() {
3899
3904
  if (cancelled) return;
3900
3905
  try {
3901
- const status = await service.fetchLatestStatus(smartAccount);
3902
- if (cancelled) return;
3903
- const event = status.lastEvent;
3904
- const eventTxHash = _chunkCXRH5MKOcjs.isDepositEvent.call(void 0, event) ? _nullishCoalesce(_chunkCXRH5MKOcjs.getEventTxHash.call(void 0, event), () => ( null)) : null;
3905
- if (baselineDepositTxHashRef.current === void 0) {
3906
- baselineDepositTxHashRef.current = eventTxHash;
3907
- } else if (eventTxHash && (!baselineDepositTxHashRef.current || !_chunkCXRH5MKOcjs.txRefsMatch.call(void 0, eventTxHash, baselineDepositTxHashRef.current))) {
3908
- currentDepositTxHashRef.current = eventTxHash;
3909
- setLatestEvent(_nullishCoalesce(event, () => ( null)));
3906
+ const deliveryTxHash = deliveryTxHashRef.current;
3907
+ if (deliveryTxHash) {
3908
+ const { lastEvent } = await service.fetchStatus(
3909
+ smartAccount,
3910
+ deliveryTxHash
3911
+ );
3912
+ if (cancelled) return;
3913
+ const txHash = _chunkKXSU24RUcjs.isDepositEvent.call(void 0, lastEvent) ? _chunkKXSU24RUcjs.getEventTxHash.call(void 0, lastEvent) : void 0;
3914
+ if (lastEvent && txHash && _chunkKXSU24RUcjs.txRefsMatch.call(void 0, txHash, deliveryTxHash)) {
3915
+ currentDepositTxHashRef.current = txHash;
3916
+ setLatestEvent(lastEvent);
3917
+ }
3918
+ } else {
3919
+ const status = await service.fetchLatestStatus(smartAccount);
3920
+ if (cancelled) return;
3921
+ const event = status.lastEvent;
3922
+ const eventTxHash = _chunkKXSU24RUcjs.isDepositEvent.call(void 0, event) ? _nullishCoalesce(_chunkKXSU24RUcjs.getEventTxHash.call(void 0, event), () => ( null)) : null;
3923
+ if (baselineDepositTxHashRef.current === void 0) {
3924
+ baselineDepositTxHashRef.current = eventTxHash;
3925
+ } else if (eventTxHash && (!baselineDepositTxHashRef.current || !_chunkKXSU24RUcjs.txRefsMatch.call(void 0, eventTxHash, baselineDepositTxHashRef.current))) {
3926
+ currentDepositTxHashRef.current = eventTxHash;
3927
+ setLatestEvent(_nullishCoalesce(event, () => ( null)));
3928
+ }
3910
3929
  }
3911
3930
  } catch (e26) {
3912
3931
  }
@@ -3929,8 +3948,7 @@ function SwappedProviderStep({
3929
3948
  }, [service, smartAccount]);
3930
3949
  _react.useEffect.call(void 0, () => {
3931
3950
  if (fastDepositPollEnabledRef.current) return;
3932
- const status = _optionalChain([orderState, 'optionalAccess', _188 => _188.status]);
3933
- if (!status || !SWAPPED_TERMINAL_STATUSES.has(status)) return;
3951
+ if (!_chunkKXSU24RUcjs.hasReached.call(void 0, orderState, "paid")) return;
3934
3952
  fastDepositPollEnabledRef.current = true;
3935
3953
  _optionalChain([rescheduleDepositPollRef, 'access', _189 => _189.current, 'optionalCall', _190 => _190(DEPOSIT_POLL_FAST_INITIAL_DELAY_MS)]);
3936
3954
  }, [orderState]);
@@ -3954,49 +3972,48 @@ function SwappedProviderStep({
3954
3972
  // Normalise to the uuid the backend poll also keys on, so orderState
3955
3973
  // is consistent regardless of which path set it.
3956
3974
  orderId: _nullishCoalesce(_nullishCoalesce(expectedOrderUuidRef.current, () => ( _optionalChain([prev, 'optionalAccess', _193 => _193.orderId]))), () => ( ext)),
3957
- status: parsed.status,
3975
+ ..._chunkKXSU24RUcjs.mergeHostedOrderState.call(void 0, prev, parsed.state),
3958
3976
  orderCrypto: _nullishCoalesce(_nullishCoalesce(parsed.orderCrypto, () => ( _optionalChain([prev, 'optionalAccess', _194 => _194.orderCrypto]))), () => ( null)),
3959
3977
  orderCryptoAmount: _nullishCoalesce(_nullishCoalesce(parsed.orderCryptoAmount, () => ( _optionalChain([prev, 'optionalAccess', _195 => _195.orderCryptoAmount]))), () => ( null)),
3960
- transactionId: _nullishCoalesce(_nullishCoalesce(parsed.transactionId, () => ( _optionalChain([prev, 'optionalAccess', _196 => _196.transactionId]))), () => ( null)),
3961
3978
  receivedAt: (/* @__PURE__ */ new Date()).toISOString(),
3962
- paidAmountUsd: _nullishCoalesce(_optionalChain([prev, 'optionalAccess', _197 => _197.paidAmountUsd]), () => ( null)),
3963
- paidAmountEur: _nullishCoalesce(_optionalChain([prev, 'optionalAccess', _198 => _198.paidAmountEur]), () => ( null)),
3964
- onrampFeeUsd: _nullishCoalesce(_optionalChain([prev, 'optionalAccess', _199 => _199.onrampFeeUsd]), () => ( null)),
3965
- paymentMethod: _nullishCoalesce(_optionalChain([prev, 'optionalAccess', _200 => _200.paymentMethod]), () => ( null))
3979
+ paidAmountUsd: _nullishCoalesce(_optionalChain([prev, 'optionalAccess', _196 => _196.paidAmountUsd]), () => ( null)),
3980
+ paidAmountEur: _nullishCoalesce(_optionalChain([prev, 'optionalAccess', _197 => _197.paidAmountEur]), () => ( null)),
3981
+ onrampFeeUsd: _nullishCoalesce(_optionalChain([prev, 'optionalAccess', _198 => _198.onrampFeeUsd]), () => ( null)),
3982
+ paymentMethod: _nullishCoalesce(_optionalChain([prev, 'optionalAccess', _199 => _199.paymentMethod]), () => ( null))
3966
3983
  }));
3967
3984
  }
3968
3985
  window.addEventListener("message", onMessage);
3969
3986
  return () => window.removeEventListener("message", onMessage);
3970
3987
  }, [openExternally]);
3971
3988
  _react.useEffect.call(void 0, () => {
3972
- const swappedProvesLive = orderState !== null && !(variant === "fiat" && orderState.status === "payment_pending");
3989
+ const swappedProvesLive = orderState !== null && (variant !== "fiat" || _chunkKXSU24RUcjs.hasReached.call(void 0, orderState, "paying") || orderState.outcome !== null);
3973
3990
  if (phase === "provider" && (swappedProvesLive || latestEvent !== null)) {
3974
3991
  setPhase("tracker");
3975
3992
  }
3976
3993
  }, [phase, orderState, latestEvent, variant]);
3977
3994
  const stepStates = _react.useMemo.call(void 0,
3978
- () => deriveStepStates(_nullishCoalesce(_optionalChain([orderState, 'optionalAccess', _201 => _201.status]), () => ( null)), latestEvent),
3995
+ () => deriveStepStates(orderState, latestEvent),
3979
3996
  [orderState, latestEvent]
3980
3997
  );
3981
3998
  const terminalState = _react.useMemo.call(void 0, () => {
3982
- if (_chunkCXRH5MKOcjs.isFailedEvent.call(void 0, _nullishCoalesce(latestEvent, () => ( void 0)))) {
3999
+ if (_chunkKXSU24RUcjs.isFailedEvent.call(void 0, _nullishCoalesce(latestEvent, () => ( void 0)))) {
3983
4000
  return {
3984
4001
  kind: "failed",
3985
- message: _chunkCXRH5MKOcjs.failureMessageForEvent.call(void 0, _nullishCoalesce(latestEvent, () => ( void 0)))
4002
+ message: _chunkKXSU24RUcjs.failureMessageForEvent.call(void 0, _nullishCoalesce(latestEvent, () => ( void 0)))
3986
4003
  };
3987
4004
  }
3988
- if (_optionalChain([orderState, 'optionalAccess', _202 => _202.status]) === "order_cancelled") {
3989
- const banner = bannerForStatus("order_cancelled", {});
3990
- return { kind: "cancelled", message: _nullishCoalesce(banner.detail, () => ( banner.title)) };
4005
+ const outcome = _optionalChain([orderState, 'optionalAccess', _200 => _200.outcome]);
4006
+ if (outcome) {
4007
+ return outcome === "cancelled" ? { kind: "cancelled", message: cancelledMessage } : { kind: "cancelled", ...OUTCOMES[outcome] };
3991
4008
  }
3992
4009
  return null;
3993
- }, [latestEvent, orderState, bannerForStatus]);
4010
+ }, [latestEvent, orderState, cancelledMessage]);
3994
4011
  _react.useEffect.call(void 0, () => {
3995
- if (_optionalChain([orderState, 'optionalAccess', _203 => _203.status]) === "order_cancelled") _optionalChain([onCancelled, 'optionalCall', _204 => _204()]);
3996
- }, [onCancelled, _optionalChain([orderState, 'optionalAccess', _205 => _205.status])]);
4012
+ if (_optionalChain([orderState, 'optionalAccess', _201 => _201.outcome]) === "cancelled") _optionalChain([onCancelled, 'optionalCall', _202 => _202()]);
4013
+ }, [onCancelled, _optionalChain([orderState, 'optionalAccess', _203 => _203.outcome])]);
3997
4014
  _react.useEffect.call(void 0, () => {
3998
4015
  if (completeFiredRef.current || failedFiredRef.current) return;
3999
- const t = _optionalChain([latestEvent, 'optionalAccess', _206 => _206.type]);
4016
+ const t = _optionalChain([latestEvent, 'optionalAccess', _204 => _204.type]);
4000
4017
  const isSuccess = t === "bridge-complete";
4001
4018
  if (!isSuccess) return;
4002
4019
  const txHash = currentDepositTxHashRef.current;
@@ -4005,10 +4022,10 @@ function SwappedProviderStep({
4005
4022
  const info = {
4006
4023
  smartAccount,
4007
4024
  txHash,
4008
- orderCrypto: _nullishCoalesce(_optionalChain([orderState, 'optionalAccess', _207 => _207.orderCrypto]), () => ( null)),
4025
+ orderCrypto: _nullishCoalesce(_optionalChain([orderState, 'optionalAccess', _205 => _205.orderCrypto]), () => ( null)),
4009
4026
  // Base-unit source amount from the deposit row/event, consistent with the
4010
4027
  // wallet/QR path. ProcessingStep + onLifecycle expect base units.
4011
- amount: _nullishCoalesce(_chunkCXRH5MKOcjs.getEventSourceDetails.call(void 0, _nullishCoalesce(latestEvent, () => ( void 0))).amount, () => ( null)),
4028
+ amount: _nullishCoalesce(_chunkKXSU24RUcjs.getEventSourceDetails.call(void 0, _nullishCoalesce(latestEvent, () => ( void 0))).amount, () => ( null)),
4012
4029
  expectedOrderUuid: expectedOrderUuidRef.current,
4013
4030
  initialEvent: _nullishCoalesce(latestEvent, () => ( void 0))
4014
4031
  };
@@ -4019,23 +4036,23 @@ function SwappedProviderStep({
4019
4036
  }, [latestEvent, orderState, smartAccount]);
4020
4037
  _react.useEffect.call(void 0, () => {
4021
4038
  if (failedFiredRef.current || completeFiredRef.current) return;
4022
- if (!_chunkCXRH5MKOcjs.isFailedEvent.call(void 0, _nullishCoalesce(latestEvent, () => ( void 0)))) return;
4039
+ if (!_chunkKXSU24RUcjs.isFailedEvent.call(void 0, _nullishCoalesce(latestEvent, () => ( void 0)))) return;
4023
4040
  const txHash = currentDepositTxHashRef.current;
4024
4041
  if (!txHash) return;
4025
4042
  failedFiredRef.current = true;
4026
4043
  setPhase("tracker");
4027
- _optionalChain([onSwappedFailedRef, 'access', _208 => _208.current, 'optionalCall', _209 => _209(
4044
+ _optionalChain([onSwappedFailedRef, 'access', _206 => _206.current, 'optionalCall', _207 => _207(
4028
4045
  txHash,
4029
- _chunkCXRH5MKOcjs.failureMessageForEvent.call(void 0, _nullishCoalesce(latestEvent, () => ( void 0)))
4046
+ _chunkKXSU24RUcjs.failureMessageForEvent.call(void 0, _nullishCoalesce(latestEvent, () => ( void 0)))
4030
4047
  )]);
4031
4048
  }, [latestEvent]);
4032
4049
  const immersive = !openExternally && variant === "fiat" && phase === "provider" && !loadError;
4033
4050
  _react.useEffect.call(void 0, () => {
4034
- _optionalChain([onImmersiveChangeRef, 'access', _210 => _210.current, 'optionalCall', _211 => _211(immersive)]);
4051
+ _optionalChain([onImmersiveChangeRef, 'access', _208 => _208.current, 'optionalCall', _209 => _209(immersive)]);
4035
4052
  }, [immersive]);
4036
- _react.useEffect.call(void 0, () => () => _optionalChain([onImmersiveChangeRef, 'access', _212 => _212.current, 'optionalCall', _213 => _213(false)]), []);
4053
+ _react.useEffect.call(void 0, () => () => _optionalChain([onImmersiveChangeRef, 'access', _210 => _210.current, 'optionalCall', _211 => _211(false)]), []);
4037
4054
  const handleRetry = () => {
4038
- _optionalChain([onRetry, 'optionalCall', _214 => _214()]);
4055
+ _optionalChain([onRetry, 'optionalCall', _212 => _212()]);
4039
4056
  setIframeSrc(null);
4040
4057
  setWidgetUrl(null);
4041
4058
  setIframeLoaded(false);
@@ -4053,8 +4070,8 @@ function SwappedProviderStep({
4053
4070
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4054
4071
  SwappedOrderTracker,
4055
4072
  {
4056
- amount: _nullishCoalesce(_optionalChain([orderState, 'optionalAccess', _215 => _215.orderCryptoAmount]), () => ( null)),
4057
- currency: _nullishCoalesce(_optionalChain([orderState, 'optionalAccess', _216 => _216.orderCrypto]), () => ( "USDC")),
4073
+ amount: _nullishCoalesce(_optionalChain([orderState, 'optionalAccess', _213 => _213.orderCryptoAmount]), () => ( null)),
4074
+ currency: _nullishCoalesce(_optionalChain([orderState, 'optionalAccess', _214 => _214.orderCrypto]), () => ( "USDC")),
4058
4075
  stepStates,
4059
4076
  terminal: terminalState,
4060
4077
  onRetry: handleRetry,
@@ -4100,7 +4117,7 @@ function SwappedProviderStep({
4100
4117
  }
4101
4118
  )
4102
4119
  ] }) }),
4103
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.PoweredBy, {})
4120
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.PoweredBy, {})
4104
4121
  ] });
4105
4122
  }
4106
4123
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-screen rs-fiat-onramp", "data-variant": variant, children: [
@@ -4129,7 +4146,7 @@ function SwappedProviderStep({
4129
4146
  allow: "payment; camera; microphone; clipboard-write; geolocation",
4130
4147
  onLoad: () => {
4131
4148
  try {
4132
- if (_optionalChain([iframeRef, 'access', _217 => _217.current, 'optionalAccess', _218 => _218.contentWindow, 'optionalAccess', _219 => _219.location, 'optionalAccess', _220 => _220.href]) === "about:blank") {
4149
+ if (_optionalChain([iframeRef, 'access', _215 => _215.current, 'optionalAccess', _216 => _216.contentWindow, 'optionalAccess', _217 => _217.location, 'optionalAccess', _218 => _218.href]) === "about:blank") {
4133
4150
  return;
4134
4151
  }
4135
4152
  } catch (e27) {
@@ -4140,84 +4157,88 @@ function SwappedProviderStep({
4140
4157
  retryToken
4141
4158
  )
4142
4159
  ] }) }),
4143
- loadError && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.PoweredBy, {})
4160
+ loadError && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.PoweredBy, {})
4144
4161
  ] });
4145
4162
  }
4146
- function deriveStepStates(swappedStatus, latestEvent) {
4147
- if (_chunkCXRH5MKOcjs.isFailedEvent.call(void 0, _nullishCoalesce(latestEvent, () => ( void 0)))) {
4163
+ function deriveStepStates(order, latestEvent) {
4164
+ if (_chunkKXSU24RUcjs.isFailedEvent.call(void 0, _nullishCoalesce(latestEvent, () => ( void 0)))) {
4148
4165
  return ["complete", "complete", "failed", "pending"];
4149
4166
  }
4150
- if (swappedStatus === "order_cancelled") {
4167
+ if (_optionalChain([order, 'optionalAccess', _219 => _219.outcome])) {
4151
4168
  return ["failed", "pending", "pending", "pending"];
4152
4169
  }
4153
- const step1Complete = swappedStatus === "order_completed" || swappedStatus === "order_broadcasted";
4154
- const step2Complete = latestEvent !== null || swappedStatus === "order_broadcasted";
4155
- const step3Complete = _optionalChain([latestEvent, 'optionalAccess', _221 => _221.type]) === "bridge-complete";
4170
+ const step2Complete = latestEvent !== null || _chunkKXSU24RUcjs.hasReached.call(void 0, order, "sent");
4171
+ const step3Complete = _optionalChain([latestEvent, 'optionalAccess', _220 => _220.type]) === "bridge-complete";
4156
4172
  if (step3Complete) {
4157
4173
  return ["complete", "complete", "complete", "complete"];
4158
4174
  }
4159
4175
  if (step2Complete) {
4160
4176
  return ["complete", "complete", "active", "pending"];
4161
4177
  }
4162
- if (step1Complete) {
4178
+ if (_chunkKXSU24RUcjs.hasReached.call(void 0, order, "paid")) {
4163
4179
  return ["complete", "active", "pending", "pending"];
4164
4180
  }
4165
4181
  return ["active", "pending", "pending", "pending"];
4166
4182
  }
4167
4183
  SwappedProviderStep.displayName = "SwappedProviderStep";
4168
4184
 
4169
- // src/components/steps/FiatOnrampStep.tsx
4185
+ // src/components/steps/RampOrderStep.tsx
4170
4186
 
4171
- function fiatBannerForStatus(status, context) {
4172
- if (context.currencyMismatch) {
4173
- return {
4174
- level: "warning",
4175
- title: "Currency mismatch",
4176
- detail: "Funds may not bridge automatically. Contact support if your balance does not arrive."
4177
- };
4187
+ var BankOnrampStep = _react.lazy.call(void 0, async () => {
4188
+ const module = await Promise.resolve().then(() => _interopRequireWildcard(require("./BankOnrampStep-3SNUX6V2.cjs")));
4189
+ return { default: module.BankOnrampStep };
4190
+ });
4191
+ var HOSTED = {
4192
+ fiat: {
4193
+ iframeTitle: "Buy crypto with Swapped",
4194
+ loadErrorCode: "SWAPPED_URL_FAILED",
4195
+ loadErrorFallback: "Failed to load on-ramp",
4196
+ cancelledMessage: "If you were charged, Swapped will refund within 5 business days."
4197
+ },
4198
+ exchange: {
4199
+ iframeTitle: "Fund from exchange via Swapped",
4200
+ loadErrorCode: "SWAPPED_CONNECT_URL_FAILED",
4201
+ loadErrorFallback: "Failed to load Connect",
4202
+ cancelledMessage: "If your exchange already debited the funds, Swapped will refund within 5 business days."
4178
4203
  }
4179
- switch (status) {
4180
- case "payment_pending":
4181
- return { level: "info", title: "Verifying payment\u2026" };
4182
- case "order_completed":
4183
- return { level: "success", title: "Payment received \u2014 sending crypto" };
4184
- case "order_broadcasted":
4185
- return {
4186
- level: "success",
4187
- title: "Crypto sent \u2014 confirming on-chain"
4188
- };
4189
- case "order_cancelled":
4190
- return {
4191
- level: "warning",
4192
- title: "Order cancelled",
4193
- detail: "If you were charged, Swapped will refund within 5 business days."
4194
- };
4204
+ };
4205
+ function RampOrderStep(props) {
4206
+ const { order, smartAccount } = props;
4207
+ if (order.flow === "funding_account") {
4208
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4209
+ BankOnrampStep,
4210
+ {
4211
+ backendUrl: order.backendUrl,
4212
+ smartAccount,
4213
+ bankOnramp: order.bankOnramp,
4214
+ onJourney: order.onJourney,
4215
+ onGoBack: props.onGoBack,
4216
+ onError: props.onError,
4217
+ openExternally: props.openExternally,
4218
+ onUnavailable: order.onUnavailable
4219
+ },
4220
+ `${order.backendUrl}:${smartAccount}`
4221
+ );
4195
4222
  }
4223
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, HostedOrder, { ...props, order });
4196
4224
  }
4197
- function FiatOnrampStep({
4225
+ function HostedOrder({
4226
+ order,
4198
4227
  smartAccount,
4199
4228
  service,
4200
- paymentMethod,
4201
- methodSelectionSource,
4202
- consumePrefetchedUrl,
4203
- onSwappedComplete,
4204
- onSwappedFailed,
4205
- onClose,
4206
- onGoBack,
4207
- onError,
4208
- onAttemptConsumed,
4209
- onProviderHandoff,
4210
- onRetry,
4211
- onCancelled,
4212
- onImmersiveChange,
4213
- openExternally
4229
+ ...callbacks
4214
4230
  }) {
4231
+ const method = order.kind === "fiat" ? order.method : void 0;
4232
+ const source = order.kind === "fiat" ? order.methodSelectionSource : void 0;
4233
+ const consumePrefetched = order.kind === "fiat" ? order.consumePrefetchedUrl : void 0;
4234
+ const connection = order.kind === "exchange" ? order.connection : void 0;
4235
+ const loadPrepared = order.kind === "exchange" ? order.loadPreparedUrl : void 0;
4215
4236
  const loadUrl = _react.useCallback.call(void 0, async () => {
4216
- const prefetched = _optionalChain([consumePrefetchedUrl, 'optionalCall', _222 => _222(
4217
- smartAccount,
4218
- paymentMethod,
4219
- methodSelectionSource
4220
- )]);
4237
+ if (connection !== void 0) {
4238
+ if (loadPrepared) return loadPrepared();
4239
+ return service.getSwappedConnectUrl({ smartAccount, connection });
4240
+ }
4241
+ const prefetched = _optionalChain([consumePrefetched, 'optionalCall', _221 => _221(smartAccount, method, source)]);
4221
4242
  if (prefetched) {
4222
4243
  try {
4223
4244
  const cached = await prefetched;
@@ -4227,126 +4248,31 @@ function FiatOnrampStep({
4227
4248
  }
4228
4249
  return service.getSwappedWidgetUrl({
4229
4250
  smartAccount,
4230
- method: paymentMethod,
4231
- methodSelectionSource
4251
+ method,
4252
+ methodSelectionSource: source
4232
4253
  });
4233
4254
  }, [
4234
4255
  service,
4235
4256
  smartAccount,
4236
- paymentMethod,
4237
- methodSelectionSource,
4238
- consumePrefetchedUrl
4257
+ method,
4258
+ source,
4259
+ consumePrefetched,
4260
+ connection,
4261
+ loadPrepared
4239
4262
  ]);
4240
4263
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4241
4264
  SwappedProviderStep,
4242
4265
  {
4243
4266
  smartAccount,
4244
4267
  service,
4245
- variant: "fiat",
4246
- loadUrl,
4247
- iframeTitle: "Buy crypto with Swapped",
4248
- loadErrorCode: "SWAPPED_URL_FAILED",
4249
- loadErrorFallback: "Failed to load on-ramp",
4250
- bannerForStatus: fiatBannerForStatus,
4251
- onSwappedComplete,
4252
- onSwappedFailed,
4253
- onClose,
4254
- onGoBack,
4255
- onError,
4256
- onAttemptConsumed,
4257
- onProviderHandoff,
4258
- onRetry,
4259
- onCancelled,
4260
- onImmersiveChange,
4261
- openExternally
4262
- }
4263
- );
4264
- }
4265
- FiatOnrampStep.displayName = "FiatOnrampStep";
4266
-
4267
- // src/components/steps/ExchangeConnectStep.tsx
4268
-
4269
-
4270
- function connectBannerForStatus(status, context) {
4271
- if (context.currencyMismatch) {
4272
- return {
4273
- level: "warning",
4274
- title: "Currency mismatch",
4275
- detail: "Funds may not bridge automatically. Contact support if your balance does not arrive."
4276
- };
4277
- }
4278
- switch (status) {
4279
- case "payment_pending":
4280
- return { level: "info", title: "Waiting for exchange transfer\u2026" };
4281
- case "order_completed":
4282
- return {
4283
- level: "success",
4284
- title: "Exchange transfer received \u2014 sending crypto"
4285
- };
4286
- case "order_broadcasted":
4287
- return {
4288
- level: "success",
4289
- title: "Crypto sent \u2014 confirming on-chain"
4290
- };
4291
- case "order_cancelled":
4292
- return {
4293
- level: "warning",
4294
- title: "Order cancelled",
4295
- detail: "If your exchange already debited the funds, Swapped will refund within 5 business days."
4296
- };
4297
- }
4298
- }
4299
- function ExchangeConnectStep({
4300
- smartAccount,
4301
- service,
4302
- connection,
4303
- loadUrl: loadPreparedUrl,
4304
- onSwappedComplete,
4305
- onSwappedFailed,
4306
- onClose,
4307
- onGoBack,
4308
- onError,
4309
- onAttemptConsumed,
4310
- onProviderHandoff,
4311
- onRetry,
4312
- onCancelled,
4313
- onImmersiveChange,
4314
- openExternally
4315
- }) {
4316
- const loadUrl = _react.useCallback.call(void 0, async () => {
4317
- if (loadPreparedUrl) return loadPreparedUrl();
4318
- const res = await service.getSwappedConnectUrl({
4319
- smartAccount,
4320
- connection
4321
- });
4322
- return res;
4323
- }, [loadPreparedUrl, service, smartAccount, connection]);
4324
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4325
- SwappedProviderStep,
4326
- {
4327
- smartAccount,
4328
- service,
4329
- variant: "connect",
4268
+ variant: order.kind === "fiat" ? "fiat" : "connect",
4330
4269
  loadUrl,
4331
- iframeTitle: "Fund from exchange via Swapped",
4332
- loadErrorCode: "SWAPPED_CONNECT_URL_FAILED",
4333
- loadErrorFallback: "Failed to load Connect",
4334
- bannerForStatus: connectBannerForStatus,
4335
- onSwappedComplete,
4336
- onSwappedFailed,
4337
- onClose,
4338
- onGoBack,
4339
- onError,
4340
- onAttemptConsumed,
4341
- onProviderHandoff,
4342
- onRetry,
4343
- onCancelled,
4344
- onImmersiveChange,
4345
- openExternally
4270
+ ...HOSTED[order.kind],
4271
+ ...callbacks
4346
4272
  }
4347
4273
  );
4348
4274
  }
4349
- ExchangeConnectStep.displayName = "ExchangeConnectStep";
4275
+ RampOrderStep.displayName = "RampOrderStep";
4350
4276
 
4351
4277
  // src/components/steps/ExchangeSelectStep.tsx
4352
4278
 
@@ -4393,7 +4319,7 @@ function ExchangeSelectStep({
4393
4319
  const message = err instanceof Error ? err.message : "Failed to load exchanges";
4394
4320
  setExchanges([]);
4395
4321
  setError(message);
4396
- _optionalChain([onError, 'optionalCall', _223 => _223(message, "SWAPPED_CONNECT_EXCHANGES_FAILED")]);
4322
+ _optionalChain([onError, 'optionalCall', _222 => _222(message, "SWAPPED_CONNECT_EXCHANGES_FAILED")]);
4397
4323
  }).finally(() => {
4398
4324
  if (!cancelled) setLoading(false);
4399
4325
  });
@@ -4410,7 +4336,7 @@ function ExchangeSelectStep({
4410
4336
  } catch (err) {
4411
4337
  const message = err instanceof Error ? err.message : "Failed to prepare Connect";
4412
4338
  setSelectionNotice(message);
4413
- _optionalChain([onError, 'optionalCall', _224 => _224(message, "SWAPPED_CONNECT_URL_FAILED")]);
4339
+ _optionalChain([onError, 'optionalCall', _223 => _223(message, "SWAPPED_CONNECT_URL_FAILED")]);
4414
4340
  } finally {
4415
4341
  setSelectingConnection(null);
4416
4342
  }
@@ -4453,7 +4379,7 @@ function ExchangeSelectStep({
4453
4379
  )
4454
4380
  ] }),
4455
4381
  !loading && !error && exchanges.length > 0 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-exchange-grid", children: exchanges.map((exchange) => {
4456
- const brand = _chunkCXRH5MKOcjs.getExchangeLogo.call(void 0, exchange.name, exchange.connection);
4382
+ const brand = _chunkKXSU24RUcjs.getExchangeLogo.call(void 0, exchange.name, exchange.connection);
4457
4383
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
4458
4384
  "button",
4459
4385
  {
@@ -4478,7 +4404,7 @@ function ExchangeSelectStep({
4478
4404
  );
4479
4405
  }) })
4480
4406
  ] }),
4481
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.PoweredBy, {}),
4407
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.PoweredBy, {}),
4482
4408
  selectionNotice && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "rs-exchange-select-fee-note", role: "status", children: selectionNotice })
4483
4409
  ] });
4484
4410
  }
@@ -4511,14 +4437,14 @@ function SolanaTokenSelectStep({
4511
4437
  setError(null);
4512
4438
  const portfolioBySymbol = {};
4513
4439
  try {
4514
- _chunkCXRH5MKOcjs.debugLog.call(void 0, debug, "solana-token-select", "portfolio:request", {
4440
+ _chunkKXSU24RUcjs.debugLog.call(void 0, debug, "solana-token-select", "portfolio:request", {
4515
4441
  solanaAddress
4516
4442
  });
4517
4443
  const portfolio = await service.fetchSolanaPortfolio(solanaAddress);
4518
4444
  if (!active) return;
4519
4445
  for (const t of portfolio.tokens) {
4520
4446
  const symbol = t.symbol.toUpperCase();
4521
- if (!_chunkCXRH5MKOcjs.SOLANA_TOKENS.some((st) => st.symbol === symbol)) continue;
4447
+ if (!_chunkKXSU24RUcjs.SOLANA_TOKENS.some((st) => st.symbol === symbol)) continue;
4522
4448
  let parsed = 0n;
4523
4449
  try {
4524
4450
  parsed = BigInt(t.balance || "0");
@@ -4534,12 +4460,12 @@ function SolanaTokenSelectStep({
4534
4460
  };
4535
4461
  }
4536
4462
  }
4537
- _chunkCXRH5MKOcjs.debugLog.call(void 0, debug, "solana-token-select", "portfolio:success", {
4463
+ _chunkKXSU24RUcjs.debugLog.call(void 0, debug, "solana-token-select", "portfolio:success", {
4538
4464
  symbols: Object.keys(portfolioBySymbol)
4539
4465
  });
4540
4466
  } catch (err) {
4541
4467
  if (!active) return;
4542
- _chunkCXRH5MKOcjs.debugError.call(void 0, debug, "solana-token-select", "portfolio:failure", err, {
4468
+ _chunkKXSU24RUcjs.debugError.call(void 0, debug, "solana-token-select", "portfolio:failure", err, {
4543
4469
  solanaAddress
4544
4470
  });
4545
4471
  setError(
@@ -4550,7 +4476,7 @@ function SolanaTokenSelectStep({
4550
4476
  return;
4551
4477
  }
4552
4478
  const results = [];
4553
- for (const token of _chunkCXRH5MKOcjs.SOLANA_TOKENS) {
4479
+ for (const token of _chunkKXSU24RUcjs.SOLANA_TOKENS) {
4554
4480
  const fromPortfolio = portfolioBySymbol[token.symbol];
4555
4481
  if (fromPortfolio && fromPortfolio.balance > 0n) {
4556
4482
  results.push({
@@ -4564,7 +4490,7 @@ function SolanaTokenSelectStep({
4564
4490
  setTokenBalances(results);
4565
4491
  setLoading(false);
4566
4492
  const totalUsd = results.reduce((sum, r) => sum + r.balanceUsd, 0);
4567
- _optionalChain([onTotalBalanceComputed, 'optionalCall', _225 => _225(totalUsd)]);
4493
+ _optionalChain([onTotalBalanceComputed, 'optionalCall', _224 => _224(totalUsd)]);
4568
4494
  }
4569
4495
  void loadBalances();
4570
4496
  return () => {
@@ -4586,7 +4512,7 @@ function SolanaTokenSelectStep({
4586
4512
  const raw = _viem.formatUnits.call(void 0, entry.balance, entry.token.decimals);
4587
4513
  const numeric = Number(raw);
4588
4514
  if (!Number.isFinite(numeric)) return raw;
4589
- return _chunkCXRH5MKOcjs.tokenFormatter.format(numeric);
4515
+ return _chunkKXSU24RUcjs.tokenFormatter.format(numeric);
4590
4516
  } catch (e30) {
4591
4517
  return "--";
4592
4518
  }
@@ -4607,7 +4533,7 @@ function SolanaTokenSelectStep({
4607
4533
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkG264OM23cjs.Spinner, { className: "rs-text-tertiary" }),
4608
4534
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-text-sm rs-text-tertiary", children: "Loading balances" })
4609
4535
  ] }),
4610
- error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.Callout, { variant: "error", children: error }),
4536
+ error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.Callout, { variant: "error", children: error }),
4611
4537
  !loading && !error && rows.length === 0 && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-empty-state", children: [
4612
4538
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkG264OM23cjs.WalletIcon, { className: "rs-empty-icon" }),
4613
4539
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-empty-text", children: "No funds in connected wallet" }),
@@ -4640,14 +4566,14 @@ function SolanaTokenSelectStep({
4640
4566
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-asset-info", children: [
4641
4567
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-asset-icon-wrapper", children: [
4642
4568
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-asset-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4643
- _chunkCXRH5MKOcjs.TokenIcon,
4569
+ _chunkKXSU24RUcjs.TokenIcon,
4644
4570
  {
4645
4571
  token: { chain: "solana", address: entry.token.mint },
4646
4572
  symbol: entry.token.symbol,
4647
4573
  fallback: entry.token.symbol.slice(0, 4)
4648
4574
  }
4649
4575
  ) }),
4650
- chainIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-asset-chain-badge", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.CdnIcon, { src: chainIcon, alt: chainName }) })
4576
+ chainIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-asset-chain-badge", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.CdnIcon, { src: chainIcon, alt: chainName }) })
4651
4577
  ] }),
4652
4578
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-asset-text", children: [
4653
4579
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-asset-name-row", children: [
@@ -4664,14 +4590,14 @@ function SolanaTokenSelectStep({
4664
4590
  ] })
4665
4591
  ] })
4666
4592
  ] }),
4667
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-asset-balance", children: entry.balanceUsd > 0 ? _chunkCXRH5MKOcjs.currencyFormatter.format(entry.balanceUsd) : tokenAmount !== "--" ? `${tokenAmount} ${entry.token.symbol}` : "--" })
4593
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-asset-balance", children: entry.balanceUsd > 0 ? _chunkKXSU24RUcjs.currencyFormatter.format(entry.balanceUsd) : tokenAmount !== "--" ? `${tokenAmount} ${entry.token.symbol}` : "--" })
4668
4594
  ]
4669
4595
  },
4670
4596
  entry.token.symbol
4671
4597
  );
4672
4598
  }) }),
4673
4599
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4674
- _chunkCXRH5MKOcjs.Button,
4600
+ _chunkKXSU24RUcjs.Button,
4675
4601
  {
4676
4602
  onClick: () => selectedEntry && onContinue(
4677
4603
  selectedEntry.token,
@@ -4684,7 +4610,7 @@ function SolanaTokenSelectStep({
4684
4610
  }
4685
4611
  )
4686
4612
  ] }),
4687
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.PoweredBy, {})
4613
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.PoweredBy, {})
4688
4614
  ] });
4689
4615
  }
4690
4616
 
@@ -4717,7 +4643,7 @@ function SolanaAmountStep({
4717
4643
  const [error, setError] = _react.useState.call(void 0, null);
4718
4644
  const hasAppliedDefaultRef = _react.useRef.call(void 0, false);
4719
4645
  const isSourceStablecoin = _chunkFKJ6EJHHcjs.isStablecoinSymbol.call(void 0, token.symbol);
4720
- const isMaxDefault = _optionalChain([defaultAmount, 'optionalAccess', _226 => _226.trim, 'call', _227 => _227(), 'access', _228 => _228.toLowerCase, 'call', _229 => _229()]) === "max";
4646
+ const isMaxDefault = _optionalChain([defaultAmount, 'optionalAccess', _225 => _225.trim, 'call', _226 => _226(), 'access', _227 => _227.toLowerCase, 'call', _228 => _228()]) === "max";
4721
4647
  const tokenPriceUsd = _react.useMemo.call(void 0, () => {
4722
4648
  if (isSourceStablecoin) return 1;
4723
4649
  try {
@@ -4737,7 +4663,7 @@ function SolanaAmountStep({
4737
4663
  const raw = _viem.formatUnits.call(void 0, balance, token.decimals);
4738
4664
  const numeric = Number(raw);
4739
4665
  if (!Number.isFinite(numeric)) return raw;
4740
- return _chunkCXRH5MKOcjs.tokenFormatter.format(numeric);
4666
+ return _chunkKXSU24RUcjs.tokenFormatter.format(numeric);
4741
4667
  } catch (e32) {
4742
4668
  return "\u2026";
4743
4669
  }
@@ -4754,7 +4680,7 @@ function SolanaAmountStep({
4754
4680
  }
4755
4681
  }, [balance, token.decimals, tokenPriceUsd, balanceUsd]);
4756
4682
  const spendableBalance = _react.useMemo.call(void 0, () => {
4757
- if (!_chunkCXRH5MKOcjs.isNativeSol.call(void 0, token)) return balance;
4683
+ if (!_chunkKXSU24RUcjs.isNativeSol.call(void 0, token)) return balance;
4758
4684
  return balance > SOL_FEE_RESERVE_LAMPORTS ? balance - SOL_FEE_RESERVE_LAMPORTS : 0n;
4759
4685
  }, [balance, token]);
4760
4686
  const spendableBalanceUsd = _react.useMemo.call(void 0, () => {
@@ -4819,15 +4745,15 @@ function SolanaAmountStep({
4819
4745
  return null;
4820
4746
  }
4821
4747
  }, [numericAmount, isSourceStablecoin, hasPricing, tokenPriceUsd, token.decimals]);
4822
- const minDepositUsd = _chunkFKJ6EJHHcjs.isHyperCoreDestination.call(void 0, targetChain) ? Math.max(_chunkFKJ6EJHHcjs.HYPERCORE_MIN_DEPOSIT_USD, _nullishCoalesce(_optionalChain([uiConfig, 'optionalAccess', _230 => _230.minDepositUsd]), () => ( 0))) : _nullishCoalesce(_optionalChain([uiConfig, 'optionalAccess', _231 => _231.minDepositUsd]), () => ( null));
4823
- const maxDepositUsd = _nullishCoalesce(_optionalChain([uiConfig, 'optionalAccess', _232 => _232.maxDepositUsd]), () => ( null));
4748
+ const minDepositUsd = _chunkFKJ6EJHHcjs.isHyperCoreDestination.call(void 0, targetChain) ? Math.max(_chunkFKJ6EJHHcjs.HYPERCORE_MIN_DEPOSIT_USD, _nullishCoalesce(_optionalChain([uiConfig, 'optionalAccess', _229 => _229.minDepositUsd]), () => ( 0))) : _nullishCoalesce(_optionalChain([uiConfig, 'optionalAccess', _230 => _230.minDepositUsd]), () => ( null));
4749
+ const maxDepositUsd = _nullishCoalesce(_optionalChain([uiConfig, 'optionalAccess', _231 => _231.maxDepositUsd]), () => ( null));
4824
4750
  const isBelowMin = minDepositUsd !== null && numericAmount > 0 && numericAmount < minDepositUsd;
4825
4751
  const isAboveMax = maxDepositUsd !== null && numericAmount > maxDepositUsd;
4826
4752
  const exceedsBalance = Boolean(
4827
4753
  sourceAmountUnits !== null && sourceAmountUnits > spendableBalance
4828
4754
  );
4829
- const boundsFor = _chunkCXRH5MKOcjs.useDepositBounds.call(void 0, );
4830
- const boundViolation = _chunkCXRH5MKOcjs.depositBoundsViolation.call(void 0,
4755
+ const boundsFor = _chunkKXSU24RUcjs.useDepositBounds.call(void 0, );
4756
+ const boundViolation = _chunkKXSU24RUcjs.depositBoundsViolation.call(void 0,
4831
4757
  boundsFor("solana", token.mint),
4832
4758
  sourceAmountUnits
4833
4759
  );
@@ -4835,7 +4761,7 @@ function SolanaAmountStep({
4835
4761
  const handlePresetClick = (percentage) => {
4836
4762
  const formatted = computePresetAmount(percentage);
4837
4763
  if (!formatted) return;
4838
- _chunkCXRH5MKOcjs.debugLog.call(void 0, debug, "solana-amount", "amount:preset", {
4764
+ _chunkKXSU24RUcjs.debugLog.call(void 0, debug, "solana-amount", "amount:preset", {
4839
4765
  percentage,
4840
4766
  symbol: token.symbol,
4841
4767
  formatted
@@ -4871,7 +4797,7 @@ function SolanaAmountStep({
4871
4797
  try {
4872
4798
  amountInUnits = _viem.parseUnits.call(void 0, sourceAmountStr, token.decimals);
4873
4799
  } catch (e37) {
4874
- _chunkCXRH5MKOcjs.debugLog.call(void 0, debug, "solana-amount", "amount:invalid", {
4800
+ _chunkKXSU24RUcjs.debugLog.call(void 0, debug, "solana-amount", "amount:invalid", {
4875
4801
  amount,
4876
4802
  sourceAmount: sourceAmountStr,
4877
4803
  reason: "parse-units-failed"
@@ -4880,13 +4806,13 @@ function SolanaAmountStep({
4880
4806
  return;
4881
4807
  }
4882
4808
  if (amountInUnits > spendableBalance) {
4883
- const isReserveIssue = _chunkCXRH5MKOcjs.isNativeSol.call(void 0, token) && amountInUnits <= balance;
4809
+ const isReserveIssue = _chunkKXSU24RUcjs.isNativeSol.call(void 0, token) && amountInUnits <= balance;
4884
4810
  setError(
4885
4811
  isReserveIssue ? "Use a bit less than your full SOL balance" : "Insufficient balance"
4886
4812
  );
4887
4813
  return;
4888
4814
  }
4889
- _chunkCXRH5MKOcjs.debugLog.call(void 0, debug, "solana-amount", "amount:continue", {
4815
+ _chunkKXSU24RUcjs.debugLog.call(void 0, debug, "solana-amount", "amount:continue", {
4890
4816
  symbol: token.symbol,
4891
4817
  inputAmountUsd: amount,
4892
4818
  sourceAmount: sourceAmountStr,
@@ -4919,13 +4845,13 @@ function SolanaAmountStep({
4919
4845
  " available",
4920
4846
  computedBalanceUsd !== null && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
4921
4847
  " (~",
4922
- _chunkCXRH5MKOcjs.currencyFormatter.format(computedBalanceUsd),
4848
+ _chunkKXSU24RUcjs.currencyFormatter.format(computedBalanceUsd),
4923
4849
  ")"
4924
4850
  ] })
4925
4851
  ] }),
4926
4852
  minDepositUsd !== null && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { className: "rs-amount-meta-minimum", children: [
4927
4853
  "Min. deposit ",
4928
- _chunkCXRH5MKOcjs.currencyFormatter.format(minDepositUsd)
4854
+ _chunkKXSU24RUcjs.currencyFormatter.format(minDepositUsd)
4929
4855
  ] })
4930
4856
  ] })
4931
4857
  ] }),
@@ -4949,7 +4875,7 @@ function SolanaAmountStep({
4949
4875
  token.symbol
4950
4876
  ] }),
4951
4877
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4952
- _chunkCXRH5MKOcjs.TokenIcon,
4878
+ _chunkKXSU24RUcjs.TokenIcon,
4953
4879
  {
4954
4880
  token: { chain: "solana", address: token.mint },
4955
4881
  symbol: token.symbol
@@ -4965,17 +4891,17 @@ function SolanaAmountStep({
4965
4891
  " ",
4966
4892
  targetTokenSymbol
4967
4893
  ] }),
4968
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.TokenIcon, { token: targetToken, symbol: targetTokenSymbol }) })
4894
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-icon", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.TokenIcon, { token: targetToken, symbol: targetTokenSymbol }) })
4969
4895
  ] })
4970
4896
  ] }),
4971
4897
  balanceAfterUsd !== null && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-amount-detail-row", children: [
4972
4898
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: "Balance after deposit" }),
4973
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-value", children: _chunkCXRH5MKOcjs.currencyFormatter.format(balanceAfterUsd) })
4899
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-amount-detail-value", children: _chunkKXSU24RUcjs.currencyFormatter.format(balanceAfterUsd) })
4974
4900
  ] })
4975
4901
  ] }),
4976
- error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.Callout, { variant: "error", children: error }),
4902
+ error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.Callout, { variant: "error", children: error }),
4977
4903
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
4978
- _chunkCXRH5MKOcjs.Button,
4904
+ _chunkKXSU24RUcjs.Button,
4979
4905
  {
4980
4906
  onClick: handleContinue,
4981
4907
  fullWidth: true,
@@ -4984,7 +4910,7 @@ function SolanaAmountStep({
4984
4910
  }
4985
4911
  )
4986
4912
  ] }),
4987
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.PoweredBy, {})
4913
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.PoweredBy, {})
4988
4914
  ] });
4989
4915
  }
4990
4916
 
@@ -5004,10 +4930,10 @@ function loadSolanaDependencies() {
5004
4930
  return dependenciesPromise2;
5005
4931
  }
5006
4932
  function getSolanaRpcUrl(rpcUrls) {
5007
- return _nullishCoalesce(_chunkCXRH5MKOcjs.rpcUrlFor.call(void 0, rpcUrls, "solana"), () => ( DEFAULT_SOLANA_RPC_URL));
4933
+ return _nullishCoalesce(_chunkKXSU24RUcjs.rpcUrlFor.call(void 0, rpcUrls, "solana"), () => ( DEFAULT_SOLANA_RPC_URL));
5008
4934
  }
5009
4935
  function hasConfiguredSolanaRpcUrl(rpcUrls) {
5010
- return _chunkCXRH5MKOcjs.rpcUrlFor.call(void 0, rpcUrls, "solana") !== void 0;
4936
+ return _chunkKXSU24RUcjs.rpcUrlFor.call(void 0, rpcUrls, "solana") !== void 0;
5011
4937
  }
5012
4938
  async function getSolanaConnection(rpcUrls) {
5013
4939
  const rpcUrl = getSolanaRpcUrl(rpcUrls);
@@ -5124,44 +5050,44 @@ function SolanaConfirmStep({
5124
5050
  onSubmittingChange,
5125
5051
  debug
5126
5052
  }) {
5127
- const rpcUrls = _chunkCXRH5MKOcjs.useRpcUrls.call(void 0, );
5053
+ const rpcUrls = _chunkKXSU24RUcjs.useRpcUrls.call(void 0, );
5128
5054
  const [isSubmitting, setIsSubmitting] = _react.useState.call(void 0, false);
5129
5055
  const [error, setError] = _react.useState.call(void 0, null);
5130
5056
  const onSubmittingChangeRef = _react.useRef.call(void 0, onSubmittingChange);
5131
5057
  onSubmittingChangeRef.current = onSubmittingChange;
5132
5058
  _react.useEffect.call(void 0, () => {
5133
- _optionalChain([onSubmittingChangeRef, 'access', _233 => _233.current, 'optionalCall', _234 => _234(isSubmitting)]);
5134
- return () => _optionalChain([onSubmittingChangeRef, 'access', _235 => _235.current, 'optionalCall', _236 => _236(false)]);
5059
+ _optionalChain([onSubmittingChangeRef, 'access', _232 => _232.current, 'optionalCall', _233 => _233(isSubmitting)]);
5060
+ return () => _optionalChain([onSubmittingChangeRef, 'access', _234 => _234.current, 'optionalCall', _235 => _235(false)]);
5135
5061
  }, [isSubmitting]);
5136
5062
  const targetChainId = _chunkFKJ6EJHHcjs.targetChainToChainId.call(void 0, targetChain);
5137
- const targetSymbol = _chunkCXRH5MKOcjs.useTokenDisplay.call(void 0, targetChainId, targetToken).symbol;
5063
+ const targetSymbol = _chunkKXSU24RUcjs.useTokenDisplay.call(void 0, targetChainId, targetToken).symbol;
5138
5064
  const sourceChainName = _chunkFKJ6EJHHcjs.getChainName.call(void 0, "solana");
5139
5065
  const targetChainName = _chunkFKJ6EJHHcjs.getChainName.call(void 0, targetChainId);
5140
5066
  const sourceChainIcon = _chunkFKJ6EJHHcjs.getChainIcon.call(void 0, "solana");
5141
5067
  const targetChainIcon = _chunkFKJ6EJHHcjs.getChainIcon.call(void 0, targetChainId);
5142
- const feeSponsored = _nullishCoalesce(_optionalChain([uiConfig, 'optionalAccess', _237 => _237.feeSponsored]), () => ( false));
5143
- const feeTooltip = _nullishCoalesce(_optionalChain([uiConfig, 'optionalAccess', _238 => _238.feeTooltip]), () => ( (feeSponsored ? "Network fees are sponsored for this deposit." : "Network fees apply.")));
5144
- const formattedAmount = sourceAmount && Number.isFinite(Number(sourceAmount)) ? _nullishCoalesce(_chunkCXRH5MKOcjs.formatTokenAmount.call(void 0, Number(sourceAmount), token.symbol), () => ( "0")) : "0";
5068
+ const feeSponsored = _nullishCoalesce(_optionalChain([uiConfig, 'optionalAccess', _236 => _236.feeSponsored]), () => ( false));
5069
+ const feeTooltip = _nullishCoalesce(_optionalChain([uiConfig, 'optionalAccess', _237 => _237.feeTooltip]), () => ( (feeSponsored ? "Network fees are sponsored for this deposit." : "Network fees apply.")));
5070
+ const formattedAmount = sourceAmount && Number.isFinite(Number(sourceAmount)) ? _nullishCoalesce(_chunkKXSU24RUcjs.formatTokenAmount.call(void 0, Number(sourceAmount), token.symbol), () => ( "0")) : "0";
5145
5071
  const receiveDisplay = (() => {
5146
5072
  const usdValue = Number(targetAmount);
5147
5073
  const sourceAmountUsd = Number.isFinite(usdValue) && usdValue > 0 ? usdValue : void 0;
5148
- const estimate = _chunkCXRH5MKOcjs.formatReceiveEstimate.call(void 0, {
5074
+ const estimate = _chunkKXSU24RUcjs.formatReceiveEstimate.call(void 0, {
5149
5075
  sourceAmount: Number.isFinite(Number(sourceAmount)) ? Number(sourceAmount) : void 0,
5150
5076
  sourceSymbol: token.symbol,
5151
5077
  targetSymbol,
5152
5078
  sourceAmountUsd,
5153
5079
  // The wallet flow only offers the allowlist, so this is the check.
5154
- sourceTrusted: _chunkCXRH5MKOcjs.resolveSolanaToken.call(void 0, token.mint) !== void 0,
5080
+ sourceTrusted: _chunkKXSU24RUcjs.resolveSolanaToken.call(void 0, token.mint) !== void 0,
5155
5081
  // Curated stablecoin target estimates at $1 when unquoted; never applied
5156
5082
  // to the source (a held token). See ConfirmStep for the rationale.
5157
- prices: targetTokenPriceUsd !== null && targetTokenPriceUsd > 0 ? { [targetSymbol.toUpperCase()]: targetTokenPriceUsd } : _chunkCXRH5MKOcjs.isDisplayStablecoinSymbol.call(void 0, targetSymbol) ? { [targetSymbol.toUpperCase()]: 1 } : {}
5083
+ prices: targetTokenPriceUsd !== null && targetTokenPriceUsd > 0 ? { [targetSymbol.toUpperCase()]: targetTokenPriceUsd } : _chunkKXSU24RUcjs.isDisplayStablecoinSymbol.call(void 0, targetSymbol) ? { [targetSymbol.toUpperCase()]: 1 } : {}
5158
5084
  });
5159
5085
  if (estimate !== void 0) return estimate;
5160
5086
  return targetSymbol;
5161
5087
  })();
5162
5088
  const handleConfirm = async () => {
5163
5089
  if (!solanaProvider) {
5164
- _chunkCXRH5MKOcjs.debugLog.call(void 0, debug, "solana-confirm", "submit:blocked", {
5090
+ _chunkKXSU24RUcjs.debugLog.call(void 0, debug, "solana-confirm", "submit:blocked", {
5165
5091
  reason: "missing-provider"
5166
5092
  });
5167
5093
  setError("Solana wallet not connected");
@@ -5169,7 +5095,7 @@ function SolanaConfirmStep({
5169
5095
  }
5170
5096
  const parsedAmount = parseFloat(sourceAmount);
5171
5097
  if (isNaN(parsedAmount) || parsedAmount <= 0) {
5172
- _chunkCXRH5MKOcjs.debugLog.call(void 0, debug, "solana-confirm", "submit:blocked", {
5098
+ _chunkKXSU24RUcjs.debugLog.call(void 0, debug, "solana-confirm", "submit:blocked", {
5173
5099
  reason: "invalid-amount",
5174
5100
  sourceAmount
5175
5101
  });
@@ -5178,7 +5104,7 @@ function SolanaConfirmStep({
5178
5104
  }
5179
5105
  setError(null);
5180
5106
  setIsSubmitting(true);
5181
- _chunkCXRH5MKOcjs.debugLog.call(void 0, debug, "solana-confirm", "submit:start", {
5107
+ _chunkKXSU24RUcjs.debugLog.call(void 0, debug, "solana-confirm", "submit:start", {
5182
5108
  smartAccount,
5183
5109
  solanaAddress,
5184
5110
  solanaDepositAddress,
@@ -5188,7 +5114,7 @@ function SolanaConfirmStep({
5188
5114
  });
5189
5115
  try {
5190
5116
  const check = await service.checkAccount(smartAccount);
5191
- _chunkCXRH5MKOcjs.debugLog.call(void 0, debug, "solana-confirm", "check:success", {
5117
+ _chunkKXSU24RUcjs.debugLog.call(void 0, debug, "solana-confirm", "check:success", {
5192
5118
  smartAccount,
5193
5119
  isRegistered: check.isRegistered,
5194
5120
  targetChain: check.targetChain,
@@ -5201,12 +5127,12 @@ function SolanaConfirmStep({
5201
5127
  }
5202
5128
  const connection = await (hasConfiguredSolanaRpcUrl(rpcUrls) ? getSolanaConnection(rpcUrls) : _nullishCoalesce(solanaConnection, () => ( getSolanaConnection(rpcUrls))));
5203
5129
  const amountUnits = _viem.parseUnits.call(void 0, sourceAmount, token.decimals);
5204
- _chunkCXRH5MKOcjs.debugLog.call(void 0, debug, "solana-confirm", "tx:build:start", {
5130
+ _chunkKXSU24RUcjs.debugLog.call(void 0, debug, "solana-confirm", "tx:build:start", {
5205
5131
  token: token.symbol,
5206
5132
  sourceAmount,
5207
5133
  amountUnits: amountUnits.toString()
5208
5134
  });
5209
- const transaction = _chunkCXRH5MKOcjs.isNativeSol.call(void 0, token) ? await buildSolTransferTransaction(
5135
+ const transaction = _chunkKXSU24RUcjs.isNativeSol.call(void 0, token) ? await buildSolTransferTransaction(
5210
5136
  connection,
5211
5137
  solanaAddress,
5212
5138
  solanaDepositAddress,
@@ -5218,10 +5144,10 @@ function SolanaConfirmStep({
5218
5144
  token.mint,
5219
5145
  amountUnits
5220
5146
  );
5221
- _chunkCXRH5MKOcjs.debugLog.call(void 0, debug, "solana-confirm", "tx:build:success", {
5147
+ _chunkKXSU24RUcjs.debugLog.call(void 0, debug, "solana-confirm", "tx:build:success", {
5222
5148
  token: token.symbol,
5223
5149
  instructionCount: transaction.instructions.length,
5224
- feePayer: _optionalChain([transaction, 'access', _239 => _239.feePayer, 'optionalAccess', _240 => _240.toBase58, 'call', _241 => _241()]),
5150
+ feePayer: _optionalChain([transaction, 'access', _238 => _238.feePayer, 'optionalAccess', _239 => _239.toBase58, 'call', _240 => _240()]),
5225
5151
  recentBlockhash: transaction.recentBlockhash
5226
5152
  });
5227
5153
  const txHash = await sendSolanaTransaction(
@@ -5229,7 +5155,7 @@ function SolanaConfirmStep({
5229
5155
  connection,
5230
5156
  transaction
5231
5157
  );
5232
- _chunkCXRH5MKOcjs.debugLog.call(void 0, debug, "solana-confirm", "tx:sent", {
5158
+ _chunkKXSU24RUcjs.debugLog.call(void 0, debug, "solana-confirm", "tx:sent", {
5233
5159
  txHash,
5234
5160
  amountUnits: amountUnits.toString()
5235
5161
  });
@@ -5241,14 +5167,14 @@ function SolanaConfirmStep({
5241
5167
  });
5242
5168
  } catch (err) {
5243
5169
  const raw = err instanceof Error ? err.message : "Transfer failed";
5244
- const message = _chunkCXRH5MKOcjs.formatUserError.call(void 0, raw);
5245
- _chunkCXRH5MKOcjs.debugError.call(void 0, debug, "solana-confirm", "submit:failure", err, {
5170
+ const message = _chunkKXSU24RUcjs.formatUserError.call(void 0, raw);
5171
+ _chunkKXSU24RUcjs.debugError.call(void 0, debug, "solana-confirm", "submit:failure", err, {
5246
5172
  smartAccount,
5247
5173
  token: token.symbol,
5248
5174
  sourceAmount
5249
5175
  });
5250
5176
  setError(message);
5251
- _optionalChain([onError, 'optionalCall', _242 => _242(message, "SOLANA_TRANSFER_ERROR", raw)]);
5177
+ _optionalChain([onError, 'optionalCall', _241 => _241(message, "SOLANA_TRANSFER_ERROR", raw)]);
5252
5178
  } finally {
5253
5179
  setIsSubmitting(false);
5254
5180
  }
@@ -5273,9 +5199,9 @@ function SolanaConfirmStep({
5273
5199
  fee: { display: "$0.04", struck: feeSponsored, tooltip: feeTooltip }
5274
5200
  }
5275
5201
  ),
5276
- error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.Callout, { variant: "error", children: error }),
5202
+ error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.Callout, { variant: "error", children: error }),
5277
5203
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
5278
- _chunkCXRH5MKOcjs.Button,
5204
+ _chunkKXSU24RUcjs.Button,
5279
5205
  {
5280
5206
  onClick: handleConfirm,
5281
5207
  loading: isSubmitting,
@@ -5286,7 +5212,7 @@ function SolanaConfirmStep({
5286
5212
  }
5287
5213
  )
5288
5214
  ] }),
5289
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.PoweredBy, {})
5215
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.PoweredBy, {})
5290
5216
  ] });
5291
5217
  }
5292
5218
 
@@ -5310,10 +5236,10 @@ function DappImportAssetSelectStep({
5310
5236
  ),
5311
5237
  incompleteSummary && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-asset-notice", role: "status", children: incompleteSummary }),
5312
5238
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-asset-list", children: assets.map((asset) => {
5313
- const tokenAmount = asset.balance ? _chunkCXRH5MKOcjs.tokenFormatter.format(
5239
+ const tokenAmount = asset.balance ? _chunkKXSU24RUcjs.tokenFormatter.format(
5314
5240
  Number(asset.balance) / 10 ** asset.decimals
5315
5241
  ) : "0";
5316
- const balanceUsd = asset.balanceUsd && asset.balanceUsd > 0 ? _chunkCXRH5MKOcjs.currencyFormatter.format(asset.balanceUsd) : `${tokenAmount} ${asset.symbol}`;
5242
+ const balanceUsd = asset.balanceUsd && asset.balanceUsd > 0 ? _chunkKXSU24RUcjs.currencyFormatter.format(asset.balanceUsd) : `${tokenAmount} ${asset.symbol}`;
5317
5243
  const assetIcon = asset.icon;
5318
5244
  const chainIcon = _chunkFKJ6EJHHcjs.getChainIcon.call(void 0, asset.chainId);
5319
5245
  const badge = _chunkFKJ6EJHHcjs.getChainBadge.call(void 0, asset.chainId);
@@ -5326,15 +5252,15 @@ function DappImportAssetSelectStep({
5326
5252
  children: [
5327
5253
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-asset-info", children: [
5328
5254
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-asset-icon-wrapper", children: [
5329
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-asset-icon", children: assetIcon ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.CdnIcon, { src: assetIcon, alt: asset.symbol }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
5330
- _chunkCXRH5MKOcjs.TokenIcon,
5255
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-asset-icon", children: assetIcon ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.CdnIcon, { src: assetIcon, alt: asset.symbol }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
5256
+ _chunkKXSU24RUcjs.TokenIcon,
5331
5257
  {
5332
5258
  token: { chain: asset.chainId, address: asset.token },
5333
5259
  symbol: asset.symbol,
5334
5260
  fallback: asset.symbol.slice(0, 4)
5335
5261
  }
5336
5262
  ) }),
5337
- chainIcon ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-asset-chain-badge", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.CdnIcon, { src: chainIcon, alt: _chunkFKJ6EJHHcjs.getChainName.call(void 0, asset.chainId) }) }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
5263
+ chainIcon ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "rs-asset-chain-badge", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.CdnIcon, { src: chainIcon, alt: _chunkFKJ6EJHHcjs.getChainName.call(void 0, asset.chainId) }) }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
5338
5264
  "span",
5339
5265
  {
5340
5266
  className: "rs-asset-chain-badge",
@@ -5366,7 +5292,7 @@ function DappImportAssetSelectStep({
5366
5292
  );
5367
5293
  }) })
5368
5294
  ] }),
5369
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.PoweredBy, {})
5295
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.PoweredBy, {})
5370
5296
  ] });
5371
5297
  }
5372
5298
  DappImportAssetSelectStep.displayName = "DappImportAssetSelectStep";
@@ -5388,7 +5314,7 @@ function describeRow(status, comingSoon) {
5388
5314
  }
5389
5315
  if (status.enabled) {
5390
5316
  return {
5391
- subtitle: status.balanceUsd > 0 ? _chunkCXRH5MKOcjs.currencyFormatter.format(status.balanceUsd) : "No balance",
5317
+ subtitle: status.balanceUsd > 0 ? _chunkKXSU24RUcjs.currencyFormatter.format(status.balanceUsd) : "No balance",
5392
5318
  disabled: false,
5393
5319
  busy: false
5394
5320
  };
@@ -5425,7 +5351,7 @@ function DappImportSelectStep({
5425
5351
  Boolean(brand.comingSoon)
5426
5352
  );
5427
5353
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
5428
- _chunkCXRH5MKOcjs.ListRow,
5354
+ _chunkKXSU24RUcjs.ListRow,
5429
5355
  {
5430
5356
  leadingMedia: brand.iconUrl,
5431
5357
  title: brand.label,
@@ -5434,7 +5360,7 @@ function DappImportSelectStep({
5434
5360
  trailing: busy ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkG264OM23cjs.Spinner, { className: "rs-spinner--sm" }) : void 0,
5435
5361
  onClick: () => {
5436
5362
  if (status === "needs-connect") {
5437
- _optionalChain([onRequestConnect, 'optionalCall', _243 => _243()]);
5363
+ _optionalChain([onRequestConnect, 'optionalCall', _242 => _242()]);
5438
5364
  return;
5439
5365
  }
5440
5366
  onSelect(brand.id);
@@ -5444,7 +5370,7 @@ function DappImportSelectStep({
5444
5370
  );
5445
5371
  }) })
5446
5372
  ] }),
5447
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.PoweredBy, {})
5373
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.PoweredBy, {})
5448
5374
  ] });
5449
5375
  }
5450
5376
  DappImportSelectStep.displayName = "DappImportSelectStep";
@@ -5501,21 +5427,21 @@ function DappImportAssetSelectSkeleton({
5501
5427
  children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: "Try again" })
5502
5428
  }
5503
5429
  ) }),
5504
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.PoweredBy, {})
5430
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.PoweredBy, {})
5505
5431
  ] });
5506
5432
  }
5507
5433
  DappImportAssetSelectSkeleton.displayName = "DappImportAssetSelectSkeleton";
5508
5434
 
5509
5435
  // src/core/fiat-methods.ts
5510
5436
  var REGIONAL_METHODS_TIMEOUT_MS = 3e3;
5511
- var BUILT_IN_ICON_METHODS = /* @__PURE__ */ new Set([
5437
+ var PRODUCT_METHODS = /* @__PURE__ */ new Set([
5512
5438
  "creditcard",
5513
5439
  "bank-transfer",
5514
5440
  "apple-pay"
5515
5441
  ]);
5516
5442
  function serverMethodToOption(m) {
5517
5443
  const icon = m.method === "bank-transfer" ? "bank" : m.method === "apple-pay" ? "apple" : "card";
5518
- const remoteIcon = BUILT_IN_ICON_METHODS.has(m.method) ? {} : {
5444
+ const remoteIcon = PRODUCT_METHODS.has(m.method) ? {} : {
5519
5445
  iconUrl: _nullishCoalesce(m.iconUrl, () => ( void 0)),
5520
5446
  iconUrlLight: _nullishCoalesce(m.iconUrlLight, () => ( void 0))
5521
5447
  };
@@ -5550,8 +5476,9 @@ function composeFiatMethods(regional, fallbackMethods) {
5550
5476
  source: "fallback"
5551
5477
  };
5552
5478
  }
5553
- if (regional.methods.length === 0) return { kind: "hidden" };
5554
- const methods = dedupe(regional.methods.map(serverMethodToOption));
5479
+ const methods = dedupe(
5480
+ regional.methods.filter((m) => PRODUCT_METHODS.has(m.method) || m.badge === "Popular").map(serverMethodToOption)
5481
+ );
5555
5482
  if (methods.length === 0) return { kind: "hidden" };
5556
5483
  const recommendedMethod = regional.recommendedMethod && methods.some(({ method }) => method === regional.recommendedMethod) ? regional.recommendedMethod : methods[0].method;
5557
5484
  return {
@@ -5590,7 +5517,7 @@ var aaveProvider = {
5590
5517
  throw new Error("Aave positions require a backend connection");
5591
5518
  }
5592
5519
  const response = await backend.getPositions(eoa);
5593
- if (_optionalChain([signal, 'optionalAccess', _244 => _244.aborted])) return null;
5520
+ if (_optionalChain([signal, 'optionalAccess', _243 => _243.aborted])) return null;
5594
5521
  const assets = toImportableAssets(response.positions);
5595
5522
  const failures = _nullishCoalesce(response.failures, () => ( []));
5596
5523
  if (assets.length === 0) {
@@ -5923,21 +5850,21 @@ var polymarketProvider = {
5923
5850
  async fetchAvailability({ eoa, getPublicClient: getPublicClient2, signal }) {
5924
5851
  const proxyWallet = await _chunkFVJKUTHFcjs.fetchPolymarketProxyWallet.call(void 0, eoa, signal);
5925
5852
  if (!proxyWallet) return null;
5926
- if (_optionalChain([signal, 'optionalAccess', _245 => _245.aborted])) return null;
5853
+ if (_optionalChain([signal, 'optionalAccess', _244 => _244.aborted])) return null;
5927
5854
  const polygonClient = getPublicClient2(_chunkFVJKUTHFcjs.POLYMARKET_POLYGON_CHAIN_ID);
5928
5855
  if (!polygonClient) return null;
5929
5856
  const balances = await _chunkFVJKUTHFcjs.readPolymarketBalances.call(void 0, {
5930
5857
  publicClient: polygonClient,
5931
5858
  proxyWallet
5932
5859
  });
5933
- if (_optionalChain([signal, 'optionalAccess', _246 => _246.aborted])) return null;
5860
+ if (_optionalChain([signal, 'optionalAccess', _245 => _245.aborted])) return null;
5934
5861
  if (balances.pusd === 0n && balances.usdce === 0n) return null;
5935
5862
  const walletKind = await detectPolymarketWalletKind({
5936
5863
  publicClient: polygonClient,
5937
5864
  proxyWallet,
5938
5865
  eoa
5939
5866
  });
5940
- if (_optionalChain([signal, 'optionalAccess', _247 => _247.aborted])) return null;
5867
+ if (_optionalChain([signal, 'optionalAccess', _246 => _246.aborted])) return null;
5941
5868
  if (!walletKind) return null;
5942
5869
  const assets = [];
5943
5870
  if (balances.pusd > 0n) {
@@ -6075,7 +6002,7 @@ function narrowDappImportAvailability(availability, isExcluded) {
6075
6002
  function computeDappImportStatus(providerId, inputs) {
6076
6003
  const { owner, availability, availabilityOwner, setup } = inputs;
6077
6004
  if (!owner) return "needs-connect";
6078
- const entry = _optionalChain([availabilityOwner, 'optionalAccess', _248 => _248.toLowerCase, 'call', _249 => _249()]) === owner.toLowerCase() ? availability[providerId] : void 0;
6005
+ const entry = _optionalChain([availabilityOwner, 'optionalAccess', _247 => _247.toLowerCase, 'call', _248 => _248()]) === owner.toLowerCase() ? availability[providerId] : void 0;
6079
6006
  if (entry === "loading" || entry === void 0) return "loading";
6080
6007
  if (entry === "error") {
6081
6008
  return {
@@ -6188,7 +6115,15 @@ function analyticsStepForFlowStep(method, step) {
6188
6115
  return "funding_method_home";
6189
6116
  }
6190
6117
  }
6118
+ var BANK_FAILURES = {
6119
+ BANK_ONRAMP_OPTIONS_FAILED: "bank_options_failed",
6120
+ BANK_ONRAMP_SETUP_FAILED: "bank_setup_failed",
6121
+ BANK_ONRAMP_DETAILS_FAILED: "bank_details_failed",
6122
+ BANK_ONRAMP_DETAILS_PENDING: "bank_details_pending"
6123
+ };
6191
6124
  function failureReasonForCode(code, cause) {
6125
+ const bank = code ? BANK_FAILURES[code] : void 0;
6126
+ if (bank) return bank;
6192
6127
  const normalized = `${_nullishCoalesce(code, () => ( ""))} ${_nullishCoalesce(cause, () => ( ""))}`.toLowerCase();
6193
6128
  if (normalized.includes("uncertain")) return "submission_uncertain";
6194
6129
  if (normalized.includes("reject") && (normalized.includes("sign") || normalized.includes("permit"))) {
@@ -6417,7 +6352,7 @@ function DepositAnalyticsControllerProvider({
6417
6352
  children,
6418
6353
  controllerRef
6419
6354
  }) {
6420
- const emit = _chunkCXRH5MKOcjs.useDepositAnalyticsEmitter.call(void 0, );
6355
+ const emit = _chunkKXSU24RUcjs.useDepositAnalyticsEmitter.call(void 0, );
6421
6356
  const controller = _react.useMemo.call(void 0,
6422
6357
  () => createDepositAnalyticsController(emit),
6423
6358
  [emit]
@@ -6505,7 +6440,8 @@ function createInitialState(overrides) {
6505
6440
  },
6506
6441
  fiat: {
6507
6442
  selectedMethod: null,
6508
- methodSelectionSource: null
6443
+ methodSelectionSource: null,
6444
+ selectedProvider: null
6509
6445
  },
6510
6446
  exchange: {
6511
6447
  selectedConnection: null
@@ -6793,7 +6729,8 @@ function applyAction(state, action) {
6793
6729
  fiat: {
6794
6730
  ...state.fiat,
6795
6731
  selectedMethod: _nullishCoalesce(action.paymentMethod, () => ( null)),
6796
- methodSelectionSource: _nullishCoalesce(action.methodSelectionSource, () => ( null))
6732
+ methodSelectionSource: _nullishCoalesce(action.methodSelectionSource, () => ( null)),
6733
+ selectedProvider: _nullishCoalesce(action.provider, () => ( null))
6797
6734
  },
6798
6735
  // Pin on ENTRY, not on submit: a Swapped order only reports a
6799
6736
  // submission on terminal success, so between paying and that callback
@@ -6937,7 +6874,7 @@ function applyAction(state, action) {
6937
6874
  totalUsd: null,
6938
6875
  // Keep any prior chains visible so the cluster does not flicker
6939
6876
  // empty across a refresh.
6940
- chainIds: _nullishCoalesce(_optionalChain([existing, 'optionalAccess', _250 => _250.chainIds]), () => ( []))
6877
+ chainIds: _nullishCoalesce(_optionalChain([existing, 'optionalAccess', _249 => _249.chainIds]), () => ( []))
6941
6878
  }
6942
6879
  }
6943
6880
  }
@@ -7148,7 +7085,7 @@ function applyAction(state, action) {
7148
7085
  flow: { ...state.flow, step: "processing" }
7149
7086
  };
7150
7087
  case "processing/quote-loaded":
7151
- if (state.flow.step !== "processing" || _optionalChain([state, 'access', _251 => _251.processing, 'access', _252 => _252.txHash, 'optionalAccess', _253 => _253.toLowerCase, 'call', _254 => _254()]) !== action.txHash.toLowerCase()) {
7088
+ if (state.flow.step !== "processing" || _optionalChain([state, 'access', _250 => _250.processing, 'access', _251 => _251.txHash, 'optionalAccess', _252 => _252.toLowerCase, 'call', _253 => _253()]) !== action.txHash.toLowerCase()) {
7152
7089
  return state;
7153
7090
  }
7154
7091
  return {
@@ -7374,7 +7311,11 @@ function applyAction(state, action) {
7374
7311
  byKey: {},
7375
7312
  nextRequestId: state.portfolio.nextRequestId
7376
7313
  },
7377
- fiat: { selectedMethod: null, methodSelectionSource: null },
7314
+ fiat: {
7315
+ selectedMethod: null,
7316
+ methodSelectionSource: null,
7317
+ selectedProvider: null
7318
+ },
7378
7319
  exchange: { selectedConnection: null }
7379
7320
  };
7380
7321
  }
@@ -7451,10 +7392,6 @@ function useDepositStore(selector) {
7451
7392
 
7452
7393
  // src/DepositFlow.tsx
7453
7394
 
7454
- var BankOnrampStep = _react.lazy.call(void 0, async () => {
7455
- const module = await Promise.resolve().then(() => _interopRequireWildcard(require("./BankOnrampStep-NPGXAA7U.cjs")));
7456
- return { default: module.BankOnrampStep };
7457
- });
7458
7395
  function swappedWidgetPrefetchKey(method, methodSelectionSource) {
7459
7396
  return JSON.stringify([_nullishCoalesce(methodSelectionSource, () => ( null)), _nullishCoalesce(method, () => ( null))]);
7460
7397
  }
@@ -7503,7 +7440,7 @@ async function fetchPinnedQuote(params) {
7503
7440
  timeoutId = setTimeout(resolve, SWAPPED_QUOTE_FEE_TIMEOUT_MS, null);
7504
7441
  })
7505
7442
  ]);
7506
- return quote && !_chunkCXRH5MKOcjs.isDepositPolicyRefusal.call(void 0, quote) ? quote : void 0;
7443
+ return quote && !_chunkKXSU24RUcjs.isDepositPolicyRefusal.call(void 0, quote) ? quote : void 0;
7507
7444
  } catch (e40) {
7508
7445
  return void 0;
7509
7446
  } finally {
@@ -7557,7 +7494,8 @@ function deriveStep(flow, d, p, activeEntry, fiat, exchange) {
7557
7494
  type: "fiat-onramp",
7558
7495
  smartAccount: committedAccount,
7559
7496
  paymentMethod: _nullishCoalesce(fiat.selectedMethod, () => ( void 0)),
7560
- methodSelectionSource: _nullishCoalesce(fiat.methodSelectionSource, () => ( void 0))
7497
+ methodSelectionSource: _nullishCoalesce(fiat.methodSelectionSource, () => ( void 0)),
7498
+ provider: _nullishCoalesce(fiat.selectedProvider, () => ( void 0))
7561
7499
  };
7562
7500
  case "exchange-select":
7563
7501
  return { type: "exchange-select" };
@@ -7750,7 +7688,7 @@ function DepositFlow({
7750
7688
  onError,
7751
7689
  debug
7752
7690
  }) {
7753
- const rpcUrls = _chunkCXRH5MKOcjs.useRpcUrls.call(void 0, );
7691
+ const rpcUrls = _chunkKXSU24RUcjs.useRpcUrls.call(void 0, );
7754
7692
  const onStepChangeRef = _chunkG264OM23cjs.useLatestRef.call(void 0, onStepChange);
7755
7693
  const analytics = useDepositAnalyticsController();
7756
7694
  const onLifecycleRef = _chunkG264OM23cjs.useLatestRef.call(void 0, onLifecycle);
@@ -7771,13 +7709,13 @@ function DepositFlow({
7771
7709
  const stableWalletSelectionKeyRef = _react.useRef.call(void 0, null);
7772
7710
  const logFlow = _react.useCallback.call(void 0,
7773
7711
  (message, data) => {
7774
- _chunkCXRH5MKOcjs.debugLog.call(void 0, debug, "deposit-flow", message, data);
7712
+ _chunkKXSU24RUcjs.debugLog.call(void 0, debug, "deposit-flow", message, data);
7775
7713
  },
7776
7714
  [debug]
7777
7715
  );
7778
7716
  const logFlowError = _react.useCallback.call(void 0,
7779
7717
  (message, error, data) => {
7780
- _chunkCXRH5MKOcjs.debugError.call(void 0, debug, "deposit-flow", message, error, data);
7718
+ _chunkKXSU24RUcjs.debugError.call(void 0, debug, "deposit-flow", message, error, data);
7781
7719
  },
7782
7720
  [debug]
7783
7721
  );
@@ -7809,12 +7747,12 @@ function DepositFlow({
7809
7747
  };
7810
7748
  }, [enableSwappedPreconnect]);
7811
7749
  const dappSwitchChain = _react.useMemo.call(void 0, () => {
7812
- if (!_optionalChain([walletClientProp, 'optionalAccess', _255 => _255.switchChain])) return void 0;
7750
+ if (!_optionalChain([walletClientProp, 'optionalAccess', _254 => _254.switchChain])) return void 0;
7813
7751
  return async (chainId) => {
7814
- await _optionalChain([walletClientProp, 'access', _256 => _256.switchChain, 'optionalCall', _257 => _257({ id: chainId })]);
7752
+ await _optionalChain([walletClientProp, 'access', _255 => _255.switchChain, 'optionalCall', _256 => _256({ id: chainId })]);
7815
7753
  };
7816
7754
  }, [walletClientProp]);
7817
- const connectedWalletAddress = _nullishCoalesce(_optionalChain([walletClientProp, 'optionalAccess', _258 => _258.account, 'optionalAccess', _259 => _259.address]), () => ( null));
7755
+ const connectedWalletAddress = _nullishCoalesce(_optionalChain([walletClientProp, 'optionalAccess', _257 => _257.account, 'optionalAccess', _258 => _258.address]), () => ( null));
7818
7756
  const walletOptions = _react.useMemo.call(void 0, () => {
7819
7757
  const options = [];
7820
7758
  const seen = /* @__PURE__ */ new Set();
@@ -7828,7 +7766,7 @@ function DepositFlow({
7828
7766
  });
7829
7767
  seen.add(id);
7830
7768
  }
7831
- if (_optionalChain([walletSession, 'optionalAccess', _260 => _260.isConnected]) && walletSession.isSolana && walletSession.solanaAddress) {
7769
+ if (_optionalChain([walletSession, 'optionalAccess', _259 => _259.isConnected]) && walletSession.isSolana && walletSession.solanaAddress) {
7832
7770
  const id = _nullishCoalesce(walletSession.caipAddress, () => ( `solana:${walletSession.solanaAddress}`));
7833
7771
  if (!seen.has(id)) {
7834
7772
  options.push({
@@ -7840,7 +7778,7 @@ function DepositFlow({
7840
7778
  });
7841
7779
  seen.add(id);
7842
7780
  }
7843
- } else if (_optionalChain([walletSession, 'optionalAccess', _261 => _261.address]) && walletSession.isConnected && walletSession.canSignEvm && !seen.has(`evm:${walletSession.address.toLowerCase()}`)) {
7781
+ } else if (_optionalChain([walletSession, 'optionalAccess', _260 => _260.address]) && walletSession.isConnected && walletSession.canSignEvm && !seen.has(`evm:${walletSession.address.toLowerCase()}`)) {
7844
7782
  const id = `evm:${walletSession.address.toLowerCase()}`;
7845
7783
  if (!seen.has(id)) {
7846
7784
  options.push({
@@ -7856,13 +7794,13 @@ function DepositFlow({
7856
7794
  return options;
7857
7795
  }, [
7858
7796
  connectedWalletAddress,
7859
- _optionalChain([walletSession, 'optionalAccess', _262 => _262.address]),
7860
- _optionalChain([walletSession, 'optionalAccess', _263 => _263.isConnected]),
7861
- _optionalChain([walletSession, 'optionalAccess', _264 => _264.canSignEvm]),
7862
- _optionalChain([walletSession, 'optionalAccess', _265 => _265.icon]),
7863
- _optionalChain([walletSession, 'optionalAccess', _266 => _266.isSolana]),
7864
- _optionalChain([walletSession, 'optionalAccess', _267 => _267.solanaAddress]),
7865
- _optionalChain([walletSession, 'optionalAccess', _268 => _268.caipAddress])
7797
+ _optionalChain([walletSession, 'optionalAccess', _261 => _261.address]),
7798
+ _optionalChain([walletSession, 'optionalAccess', _262 => _262.isConnected]),
7799
+ _optionalChain([walletSession, 'optionalAccess', _263 => _263.canSignEvm]),
7800
+ _optionalChain([walletSession, 'optionalAccess', _264 => _264.icon]),
7801
+ _optionalChain([walletSession, 'optionalAccess', _265 => _265.isSolana]),
7802
+ _optionalChain([walletSession, 'optionalAccess', _266 => _266.solanaAddress]),
7803
+ _optionalChain([walletSession, 'optionalAccess', _267 => _267.caipAddress])
7866
7804
  ]);
7867
7805
  const configuredFiatMethods = _react.useMemo.call(void 0,
7868
7806
  () => fiatMethods ? FIAT_ONRAMP_METHODS.filter(
@@ -7885,11 +7823,11 @@ function DepositFlow({
7885
7823
  hasEnabledAssetMigration
7886
7824
  ].filter(Boolean).length;
7887
7825
  const canAutoLock = Boolean(
7888
- enableWallet && _optionalChain([walletClientProp, 'optionalAccess', _269 => _269.account]) && !walletSession && enabledFeatureCount === 1
7826
+ enableWallet && _optionalChain([walletClientProp, 'optionalAccess', _268 => _268.account]) && !walletSession && enabledFeatureCount === 1
7889
7827
  );
7890
7828
  const hasWalletOptions = enableWallet && walletOptions.length > 0;
7891
7829
  const hasReownSession = Boolean(
7892
- _optionalChain([walletSession, 'optionalAccess', _270 => _270.isConnected]) || _optionalChain([walletSession, 'optionalAccess', _271 => _271.address])
7830
+ _optionalChain([walletSession, 'optionalAccess', _269 => _269.isConnected]) || _optionalChain([walletSession, 'optionalAccess', _270 => _270.address])
7893
7831
  );
7894
7832
  const isDappImportWalletHydrating = Boolean(
7895
7833
  hasWalletClientProp && walletClientProp === void 0 || walletSession && !hasReownSession && !walletSession.isReady
@@ -7911,10 +7849,10 @@ function DepositFlow({
7911
7849
  ]);
7912
7850
  const setupChainId = typeof targetChain === "number" && !_chunkFKJ6EJHHcjs.isVirtualDestination.call(void 0, targetChain) ? targetChain : typeof defaultSourceChain === "number" ? defaultSourceChain : DEFAULT_SETUP_CHAIN_ID;
7913
7851
  const targetChainId = _chunkFKJ6EJHHcjs.targetChainToChainId.call(void 0, targetChain);
7914
- const targetDisplay = _chunkCXRH5MKOcjs.useTokenDisplay.call(void 0, targetChainId, targetToken);
7852
+ const targetDisplay = _chunkKXSU24RUcjs.useTokenDisplay.call(void 0, targetChainId, targetToken);
7915
7853
  const targetSymbol = targetDisplay.symbol;
7916
7854
  const isTargetStablecoin = _chunkFKJ6EJHHcjs.isStablecoinSymbol.call(void 0, targetSymbol);
7917
- const assetStore = _chunkCXRH5MKOcjs.useAssetStore.call(void 0, );
7855
+ const assetStore = _chunkKXSU24RUcjs.useAssetStore.call(void 0, );
7918
7856
  const targetMarketPriceRef = _react.useRef.call(void 0, null);
7919
7857
  _react.useEffect.call(void 0, () => {
7920
7858
  targetMarketPriceRef.current = null;
@@ -7933,11 +7871,11 @@ function DepositFlow({
7933
7871
  return null;
7934
7872
  }
7935
7873
  if (canAutoLock) {
7936
- const fallbackChainId = _nullishCoalesce(_optionalChain([walletClientProp, 'optionalAccess', _272 => _272.chain, 'optionalAccess', _273 => _273.id]), () => ( setupChainId));
7874
+ const fallbackChainId = _nullishCoalesce(_optionalChain([walletClientProp, 'optionalAccess', _271 => _271.chain, 'optionalAccess', _272 => _272.id]), () => ( setupChainId));
7937
7875
  return {
7938
7876
  ownerAddress: walletClientProp.account.address,
7939
7877
  walletClient: walletClientProp,
7940
- publicClient: _nullishCoalesce(publicClientProp, () => ( _chunkCXRH5MKOcjs.getPublicClient.call(void 0, fallbackChainId, rpcUrls))),
7878
+ publicClient: _nullishCoalesce(publicClientProp, () => ( _chunkKXSU24RUcjs.getPublicClient.call(void 0, fallbackChainId, rpcUrls))),
7941
7879
  switchChain: dappSwitchChain
7942
7880
  };
7943
7881
  }
@@ -7949,20 +7887,20 @@ function DepositFlow({
7949
7887
  if (selectedOption.kind === "solana") {
7950
7888
  return null;
7951
7889
  }
7952
- if (selectedOption.kind === "connected" && _optionalChain([walletClientProp, 'optionalAccess', _274 => _274.account]) && selectedOption.address && walletClientProp.account.address.toLowerCase() === selectedOption.address.toLowerCase()) {
7953
- const fallbackChainId = _nullishCoalesce(_optionalChain([walletClientProp, 'optionalAccess', _275 => _275.chain, 'optionalAccess', _276 => _276.id]), () => ( setupChainId));
7890
+ if (selectedOption.kind === "connected" && _optionalChain([walletClientProp, 'optionalAccess', _273 => _273.account]) && selectedOption.address && walletClientProp.account.address.toLowerCase() === selectedOption.address.toLowerCase()) {
7891
+ const fallbackChainId = _nullishCoalesce(_optionalChain([walletClientProp, 'optionalAccess', _274 => _274.chain, 'optionalAccess', _275 => _275.id]), () => ( setupChainId));
7954
7892
  return {
7955
7893
  ownerAddress: walletClientProp.account.address,
7956
7894
  walletClient: walletClientProp,
7957
- publicClient: _nullishCoalesce(publicClientProp, () => ( _chunkCXRH5MKOcjs.getPublicClient.call(void 0, fallbackChainId, rpcUrls))),
7895
+ publicClient: _nullishCoalesce(publicClientProp, () => ( _chunkKXSU24RUcjs.getPublicClient.call(void 0, fallbackChainId, rpcUrls))),
7958
7896
  switchChain: dappSwitchChain
7959
7897
  };
7960
7898
  }
7961
- if (selectedOption.kind === "external" && _optionalChain([walletSession, 'optionalAccess', _277 => _277.address]) && selectedOption.address && walletSession.address.toLowerCase() === selectedOption.address.toLowerCase()) {
7899
+ if (selectedOption.kind === "external" && _optionalChain([walletSession, 'optionalAccess', _276 => _276.address]) && selectedOption.address && walletSession.address.toLowerCase() === selectedOption.address.toLowerCase()) {
7962
7900
  return {
7963
7901
  ownerAddress: walletSession.address,
7964
7902
  walletClient: walletSession.walletClient,
7965
- publicClient: _nullishCoalesce(walletSession.publicClient, () => ( _chunkCXRH5MKOcjs.getPublicClient.call(void 0, setupChainId, rpcUrls))),
7903
+ publicClient: _nullishCoalesce(walletSession.publicClient, () => ( _chunkKXSU24RUcjs.getPublicClient.call(void 0, setupChainId, rpcUrls))),
7966
7904
  switchChain: walletSession.switchChain
7967
7905
  };
7968
7906
  }
@@ -7984,7 +7922,7 @@ function DepositFlow({
7984
7922
  // nothing else here when the host switches chain, and the context would go
7985
7923
  // on holding a client bound to the old one: `chainMismatch` never clears
7986
7924
  // and the CTA stays disabled with nothing beside it.
7987
- _optionalChain([walletSession, 'optionalAccess', _278 => _278.walletClient]),
7925
+ _optionalChain([walletSession, 'optionalAccess', _277 => _277.walletClient]),
7988
7926
  setupChainId,
7989
7927
  rpcUrls
7990
7928
  ]);
@@ -8024,35 +7962,35 @@ function DepositFlow({
8024
7962
  const selectedEvmWalletOwner = _react.useMemo.call(void 0, () => {
8025
7963
  if (!selectedWalletId) return null;
8026
7964
  const opt = walletOptions.find((o) => o.id === selectedWalletId);
8027
- if (_optionalChain([opt, 'optionalAccess', _279 => _279.kind]) === "external" && opt.address) {
7965
+ if (_optionalChain([opt, 'optionalAccess', _278 => _278.kind]) === "external" && opt.address) {
8028
7966
  return opt.address;
8029
7967
  }
8030
- if (_optionalChain([opt, 'optionalAccess', _280 => _280.kind]) === "connected" && opt.address) {
7968
+ if (_optionalChain([opt, 'optionalAccess', _279 => _279.kind]) === "connected" && opt.address) {
8031
7969
  return opt.address;
8032
7970
  }
8033
7971
  return null;
8034
7972
  }, [selectedWalletId, walletOptions]);
8035
7973
  const dappImportOwner = _react.useMemo.call(void 0, () => {
8036
7974
  if (selectedEvmWalletOwner) return selectedEvmWalletOwner;
8037
- if (_optionalChain([walletSession, 'optionalAccess', _281 => _281.address]) && walletSession.isConnected) {
7975
+ if (_optionalChain([walletSession, 'optionalAccess', _280 => _280.address]) && walletSession.isConnected) {
8038
7976
  return walletSession.address;
8039
7977
  }
8040
7978
  if (connectedWalletAddress) return connectedWalletAddress;
8041
7979
  return null;
8042
7980
  }, [
8043
7981
  selectedEvmWalletOwner,
8044
- _optionalChain([walletSession, 'optionalAccess', _282 => _282.address]),
8045
- _optionalChain([walletSession, 'optionalAccess', _283 => _283.isConnected]),
7982
+ _optionalChain([walletSession, 'optionalAccess', _281 => _281.address]),
7983
+ _optionalChain([walletSession, 'optionalAccess', _282 => _282.isConnected]),
8046
7984
  connectedWalletAddress
8047
7985
  ]);
8048
7986
  const activeOwner = _react.useMemo.call(void 0,
8049
7987
  () => resolveOwnerForMode(flowMode, {
8050
- walletOwner: _nullishCoalesce(_optionalChain([signerContext, 'optionalAccess', _284 => _284.ownerAddress]), () => ( (canAutoLock ? connectedWalletAddress : selectedEvmWalletOwner))),
7988
+ walletOwner: _nullishCoalesce(_optionalChain([signerContext, 'optionalAccess', _283 => _283.ownerAddress]), () => ( (canAutoLock ? connectedWalletAddress : selectedEvmWalletOwner))),
8051
7989
  dappImportOwner
8052
7990
  }),
8053
7991
  [
8054
7992
  flowMode,
8055
- _optionalChain([signerContext, 'optionalAccess', _285 => _285.ownerAddress]),
7993
+ _optionalChain([signerContext, 'optionalAccess', _284 => _284.ownerAddress]),
8056
7994
  canAutoLock,
8057
7995
  connectedWalletAddress,
8058
7996
  selectedEvmWalletOwner,
@@ -8069,7 +8007,7 @@ function DepositFlow({
8069
8007
  ].join(":");
8070
8008
  if (lastSmartAccountLifecycleKeyRef.current === lifecycleKey) return;
8071
8009
  lastSmartAccountLifecycleKeyRef.current = lifecycleKey;
8072
- _optionalChain([onLifecycleRef, 'access', _286 => _286.current, 'optionalCall', _287 => _287({
8010
+ _optionalChain([onLifecycleRef, 'access', _285 => _285.current, 'optionalCall', _286 => _286({
8073
8011
  type: "smart-account-changed",
8074
8012
  evm: activeEntry.smartAccount,
8075
8013
  solana: _nullishCoalesce(activeEntry.solanaDepositAddress, () => ( null))
@@ -8097,7 +8035,7 @@ function DepositFlow({
8097
8035
  return;
8098
8036
  }
8099
8037
  lastConnectedLifecycleKeyRef.current = lifecycleKey;
8100
- _optionalChain([onLifecycleRef, 'access', _288 => _288.current, 'optionalCall', _289 => _289({
8038
+ _optionalChain([onLifecycleRef, 'access', _287 => _287.current, 'optionalCall', _288 => _288({
8101
8039
  type: "connected",
8102
8040
  address: activeOwner,
8103
8041
  smartAccount: activeEntry.smartAccount
@@ -8170,7 +8108,7 @@ function DepositFlow({
8170
8108
  const handleWalletDisconnect = _react.useCallback.call(void 0, () => {
8171
8109
  analytics.abandon("wallet_disconnect");
8172
8110
  analytics.resetAttempt();
8173
- _optionalChain([onDisconnect, 'optionalCall', _290 => _290()]);
8111
+ _optionalChain([onDisconnect, 'optionalCall', _289 => _289()]);
8174
8112
  storeApi.dispatch({
8175
8113
  type: "back/requested",
8176
8114
  hasWalletOptions: hasWalletOptions || Boolean(walletSession)
@@ -8209,7 +8147,7 @@ function DepositFlow({
8209
8147
  const currentBackHandler = canGoBackFromHere ? handleBack : void 0;
8210
8148
  const currentScreen = showConnectStep ? "connect" : effectiveStep.type;
8211
8149
  _react.useEffect.call(void 0, () => {
8212
- _optionalChain([onStepChangeRef, 'access', _291 => _291.current, 'optionalCall', _292 => _292(currentBackHandler, currentScreen)]);
8150
+ _optionalChain([onStepChangeRef, 'access', _290 => _290.current, 'optionalCall', _291 => _291(currentBackHandler, currentScreen)]);
8213
8151
  }, [currentBackHandler, currentScreen, onStepChangeRef]);
8214
8152
  const lastModalHeightRef = _react.useRef.call(void 0, 0);
8215
8153
  const modalContentElRef = _react.useRef.call(void 0, null);
@@ -8219,7 +8157,7 @@ function DepositFlow({
8219
8157
  modalContentElRef.current = mc;
8220
8158
  const ro = new ResizeObserver((entries) => {
8221
8159
  for (const entry of entries) {
8222
- const border = _optionalChain([entry, 'access', _293 => _293.borderBoxSize, 'optionalAccess', _294 => _294[0], 'optionalAccess', _295 => _295.blockSize]);
8160
+ const border = _optionalChain([entry, 'access', _292 => _292.borderBoxSize, 'optionalAccess', _293 => _293[0], 'optionalAccess', _294 => _294.blockSize]);
8223
8161
  lastModalHeightRef.current = typeof border === "number" ? border : entry.contentRect.height;
8224
8162
  }
8225
8163
  });
@@ -8280,7 +8218,7 @@ function DepositFlow({
8280
8218
  targetToken
8281
8219
  ]);
8282
8220
  _react.useEffect.call(void 0, () => {
8283
- _optionalChain([onLifecycleRef, 'access', _296 => _296.current, 'optionalCall', _297 => _297({
8221
+ _optionalChain([onLifecycleRef, 'access', _295 => _295.current, 'optionalCall', _296 => _296({
8284
8222
  type: "balance-changed",
8285
8223
  totalUsd: totalBalanceUsd
8286
8224
  })]);
@@ -8297,9 +8235,9 @@ function DepositFlow({
8297
8235
  const handleConfirmWallet = _react.useCallback.call(void 0,
8298
8236
  (walletId) => {
8299
8237
  const selectedOption = walletOptions.find((o) => o.id === walletId);
8300
- const mode = _optionalChain([selectedOption, 'optionalAccess', _298 => _298.kind]) === "solana" ? "solana-wallet" : "wallet";
8238
+ const mode = _optionalChain([selectedOption, 'optionalAccess', _297 => _297.kind]) === "solana" ? "solana-wallet" : "wallet";
8301
8239
  analytics.selectMethod("wallet", "user", {
8302
- network: _optionalChain([selectedOption, 'optionalAccess', _299 => _299.kind]) === "solana" ? "solana" : "evm",
8240
+ network: _optionalChain([selectedOption, 'optionalAccess', _298 => _298.kind]) === "solana" ? "solana" : "evm",
8303
8241
  integration: _nullishCoalesce(walletIntegration, () => ( "none"))
8304
8242
  });
8305
8243
  storeApi.dispatch({
@@ -8311,7 +8249,7 @@ function DepositFlow({
8311
8249
  [analytics, walletIntegration, walletOptions, storeApi]
8312
8250
  );
8313
8251
  const isSolanaWalletConnected = Boolean(
8314
- _optionalChain([walletSession, 'optionalAccess', _300 => _300.isConnected]) && _optionalChain([walletSession, 'optionalAccess', _301 => _301.isSolana])
8252
+ _optionalChain([walletSession, 'optionalAccess', _299 => _299.isConnected]) && _optionalChain([walletSession, 'optionalAccess', _300 => _300.isSolana])
8315
8253
  );
8316
8254
  const assetMigrationsKey = assetMigrations ? Object.keys(assetMigrations).filter((k) => assetMigrations[k]).sort().join(",") : "";
8317
8255
  const enabledDappImportProviders = _react.useMemo.call(void 0,
@@ -8330,7 +8268,7 @@ function DepositFlow({
8330
8268
  const owner = dappImportOwner;
8331
8269
  if (owner) {
8332
8270
  const wallet = walletOptions.find(
8333
- (o) => _optionalChain([(_nullishCoalesce(o.address, () => ( null))), 'optionalAccess', _302 => _302.toLowerCase, 'call', _303 => _303()]) === owner.toLowerCase()
8271
+ (o) => _optionalChain([(_nullishCoalesce(o.address, () => ( null))), 'optionalAccess', _301 => _301.toLowerCase, 'call', _302 => _302()]) === owner.toLowerCase()
8334
8272
  );
8335
8273
  if (wallet) {
8336
8274
  storeApi.dispatch({
@@ -8374,7 +8312,7 @@ function DepositFlow({
8374
8312
  eoa: dappImportOwner,
8375
8313
  getPublicClient: (chainId) => {
8376
8314
  try {
8377
- return _chunkCXRH5MKOcjs.getPublicClient.call(void 0, chainId, rpcUrls);
8315
+ return _chunkKXSU24RUcjs.getPublicClient.call(void 0, chainId, rpcUrls);
8378
8316
  } catch (e41) {
8379
8317
  return null;
8380
8318
  }
@@ -8432,7 +8370,7 @@ function DepositFlow({
8432
8370
  const storedDappImportAvailability = useDepositStore(
8433
8371
  (s) => s.dappImport.availability
8434
8372
  );
8435
- const isExcludedByRestrictedList = _chunkCXRH5MKOcjs.useRestrictedListExclusion.call(void 0, );
8373
+ const isExcludedByRestrictedList = _chunkKXSU24RUcjs.useRestrictedListExclusion.call(void 0, );
8436
8374
  const dappImportAvailability = _react.useMemo.call(void 0,
8437
8375
  () => narrowDappImportAvailability(
8438
8376
  storedDappImportAvailability,
@@ -8487,7 +8425,7 @@ function DepositFlow({
8487
8425
  }, [activeDappImportProviderId, enabledDappImportProviders]);
8488
8426
  const activeDappImportAvailability = _react.useMemo.call(void 0, () => {
8489
8427
  if (!activeDappImportProviderId) return null;
8490
- if (!dappImportOwner || _optionalChain([dappImportAvailabilityOwner, 'optionalAccess', _304 => _304.toLowerCase, 'call', _305 => _305()]) !== dappImportOwner.toLowerCase()) {
8428
+ if (!dappImportOwner || _optionalChain([dappImportAvailabilityOwner, 'optionalAccess', _303 => _303.toLowerCase, 'call', _304 => _304()]) !== dappImportOwner.toLowerCase()) {
8491
8429
  return null;
8492
8430
  }
8493
8431
  const entry = dappImportAvailability[activeDappImportProviderId];
@@ -8530,7 +8468,7 @@ function DepositFlow({
8530
8468
  setup: setupSlice
8531
8469
  });
8532
8470
  const pinnableWallet = dappImportOwner ? _nullishCoalesce(walletOptions.find(
8533
- (o) => _optionalChain([(_nullishCoalesce(o.address, () => ( null))), 'optionalAccess', _306 => _306.toLowerCase, 'call', _307 => _307()]) === dappImportOwner.toLowerCase()
8471
+ (o) => _optionalChain([(_nullishCoalesce(o.address, () => ( null))), 'optionalAccess', _305 => _305.toLowerCase, 'call', _306 => _306()]) === dappImportOwner.toLowerCase()
8534
8472
  ), () => ( null)) : null;
8535
8473
  const outcome = resolveBootOutcome({
8536
8474
  status,
@@ -8577,7 +8515,7 @@ function DepositFlow({
8577
8515
  if (dappImportOwner) {
8578
8516
  const plan = bootRetryPlan({
8579
8517
  setupStatus: snapshot.setup.status,
8580
- availabilityEntry: _optionalChain([snapshot, 'access', _308 => _308.dappImport, 'access', _309 => _309.availabilityOwner, 'optionalAccess', _310 => _310.toLowerCase, 'call', _311 => _311()]) === dappImportOwner.toLowerCase() ? snapshot.dappImport.availability[providerId] : void 0
8518
+ availabilityEntry: _optionalChain([snapshot, 'access', _307 => _307.dappImport, 'access', _308 => _308.availabilityOwner, 'optionalAccess', _309 => _309.toLowerCase, 'call', _310 => _310()]) === dappImportOwner.toLowerCase() ? snapshot.dappImport.availability[providerId] : void 0
8581
8519
  });
8582
8520
  if (plan.restartSetup) {
8583
8521
  storeApi.dispatch({ type: "setup/retry-requested" });
@@ -8594,15 +8532,17 @@ function DepositFlow({
8594
8532
  });
8595
8533
  }, [analytics, storeApi, dappImportOwner]);
8596
8534
  const handleSelectFiatMethod = _react.useCallback.call(void 0,
8597
- (paymentMethod, methodSelectionSource) => {
8535
+ (paymentMethod, methodSelectionSource, provider = "swapped") => {
8598
8536
  analytics.selectMethod("fiat_onramp", "user", {
8599
8537
  payment_method: paymentMethod,
8600
- source: methodSelectionSource
8538
+ source: methodSelectionSource,
8539
+ provider
8601
8540
  });
8602
8541
  storeApi.dispatch({
8603
8542
  type: "connect/fiat-onramp-selected",
8604
8543
  paymentMethod,
8605
- methodSelectionSource
8544
+ methodSelectionSource,
8545
+ provider
8606
8546
  });
8607
8547
  },
8608
8548
  [analytics, storeApi]
@@ -8651,7 +8591,7 @@ function DepositFlow({
8651
8591
  })
8652
8592
  }));
8653
8593
  const currentAccount = storeApi.getState().setup.smartAccount;
8654
- if (_optionalChain([currentAccount, 'optionalAccess', _312 => _312.toLowerCase, 'call', _313 => _313()]) !== owner) {
8594
+ if (_optionalChain([currentAccount, 'optionalAccess', _311 => _311.toLowerCase, 'call', _312 => _312()]) !== owner) {
8655
8595
  swappedConnectUrlRef.current.delete(key);
8656
8596
  throw new Error("Deposit account changed. Select your exchange again.");
8657
8597
  }
@@ -8671,7 +8611,7 @@ function DepositFlow({
8671
8611
  const key = `${smartAccount.toLowerCase()}:${connection}`;
8672
8612
  const entry = swappedConnectUrlRef.current.get(key);
8673
8613
  swappedConnectUrlRef.current.delete(key);
8674
- return _optionalChain([entry, 'optionalAccess', _314 => _314.smartAccount]) === smartAccount.toLowerCase() ? entry.response : service.getSwappedConnectUrl({ smartAccount, connection });
8614
+ return _optionalChain([entry, 'optionalAccess', _313 => _313.smartAccount]) === smartAccount.toLowerCase() ? entry.response : service.getSwappedConnectUrl({ smartAccount, connection });
8675
8615
  },
8676
8616
  [service]
8677
8617
  );
@@ -8732,6 +8672,31 @@ function DepositFlow({
8732
8672
  swappedConnectUrlRef.current.clear();
8733
8673
  }, [setupSlice.smartAccount]);
8734
8674
  const hasConfiguredFiatMethods = fiatMethods !== void 0;
8675
+ const [providers, setProviders] = _react.useState.call(void 0, "loading");
8676
+ _react.useEffect.call(void 0, () => {
8677
+ if (!enableFiatOnramp && !bankOnrampEnabled && !enableExchangeConnect) {
8678
+ return;
8679
+ }
8680
+ let settled = false;
8681
+ const settle = (list) => {
8682
+ if (settled) return;
8683
+ settled = true;
8684
+ clearTimeout(timer);
8685
+ setProviders(list);
8686
+ };
8687
+ setProviders("loading");
8688
+ const timer = setTimeout(() => settle(null), REGIONAL_METHODS_TIMEOUT_MS);
8689
+ void service.getOnrampProviders().then(settle);
8690
+ return () => {
8691
+ settled = true;
8692
+ clearTimeout(timer);
8693
+ };
8694
+ }, [bankOnrampEnabled, enableExchangeConnect, enableFiatOnramp, service]);
8695
+ const providersLoading = providers === "loading";
8696
+ const offers = (provider, kind) => providers === null || providers !== "loading" && providers.some((p) => p.provider === provider && p.kinds.includes(kind));
8697
+ const swappedFiatOffered = offers("swapped", "fiat");
8698
+ const noahOffered = offers("noah", "fiat");
8699
+ const exchangeOffered = enableExchangeConnect && offers("swapped", "exchange");
8735
8700
  const [regionalMethods, setRegionalMethods] = _react.useState.call(void 0, {
8736
8701
  status: "loading",
8737
8702
  country: null,
@@ -8779,10 +8744,10 @@ function DepositFlow({
8779
8744
  };
8780
8745
  }, [analytics, enableFiatOnramp, hasConfiguredFiatMethods, service]);
8781
8746
  const swappedCashDisplay = _react.useMemo.call(void 0,
8782
- () => !enableFiatOnramp ? { kind: "hidden" } : hasConfiguredFiatMethods ? {
8747
+ () => !enableFiatOnramp || !swappedFiatOffered ? { kind: "hidden" } : hasConfiguredFiatMethods ? {
8783
8748
  kind: "list",
8784
8749
  methods: configuredFiatMethods,
8785
- recommendedMethod: _nullishCoalesce(_optionalChain([configuredFiatMethods, 'access', _315 => _315[0], 'optionalAccess', _316 => _316.method]), () => ( "bank-transfer")),
8750
+ recommendedMethod: _nullishCoalesce(_optionalChain([configuredFiatMethods, 'access', _314 => _314[0], 'optionalAccess', _315 => _315.method]), () => ( "bank-transfer")),
8786
8751
  country: null,
8787
8752
  source: "configured"
8788
8753
  } : composeFiatMethods(regionalMethods, FIAT_ONRAMP_METHODS),
@@ -8790,25 +8755,30 @@ function DepositFlow({
8790
8755
  configuredFiatMethods,
8791
8756
  enableFiatOnramp,
8792
8757
  hasConfiguredFiatMethods,
8793
- regionalMethods
8758
+ regionalMethods,
8759
+ swappedFiatOffered
8794
8760
  ]
8795
8761
  );
8796
8762
  const swappedOffersBank = swappedCashDisplay.kind === "list" && swappedCashDisplay.methods.some(({ method }) => method === "bank-transfer");
8797
8763
  const [bankOnrampUnavailable, setBankOnrampUnavailable] = _react.useState.call(void 0, false);
8798
- const bankRowOffered = bankOnrampEnabled && !bankOnrampUnavailable;
8764
+ const bankRowOffered = bankOnrampEnabled && noahOffered && !bankOnrampUnavailable;
8799
8765
  const swappedRefusesBank = hasConfiguredFiatMethods ? !configuredFiatMethods.some(({ method }) => method === "bank-transfer") : regionalMethods.status === "ready" && regionalMethods.country !== null && !regionalMethods.methods.some(({ method }) => method === "bank-transfer");
8800
8766
  const handleBankOnrampUnavailable = _react.useCallback.call(void 0, () => {
8801
8767
  setBankOnrampUnavailable(true);
8802
8768
  if (swappedRefusesBank) handleProviderBack();
8803
8769
  }, [handleProviderBack, swappedRefusesBank]);
8804
8770
  const cashDisplay = _react.useMemo.call(void 0, () => {
8771
+ if (providersLoading && fiatEnabled) return { kind: "loading" };
8805
8772
  const swappedDisplay = swappedCashDisplay;
8806
8773
  if (!bankRowOffered || swappedDisplay.kind === "loading") {
8807
8774
  return swappedDisplay;
8808
8775
  }
8809
- if (swappedOffersBank) return swappedDisplay;
8810
- const bankTransfer = FIAT_ONRAMP_METHODS.find(
8811
- ({ method }) => method === "bank-transfer"
8776
+ const asNoah = (m) => m.method === "bank-transfer" ? { ...m, provider: "noah" } : m;
8777
+ if (swappedOffersBank && swappedDisplay.kind === "list") {
8778
+ return { ...swappedDisplay, methods: swappedDisplay.methods.map(asNoah) };
8779
+ }
8780
+ const bankTransfer = asNoah(
8781
+ FIAT_ONRAMP_METHODS.find(({ method }) => method === "bank-transfer")
8812
8782
  );
8813
8783
  return {
8814
8784
  kind: "list",
@@ -8817,7 +8787,13 @@ function DepositFlow({
8817
8787
  country: swappedDisplay.kind === "list" ? swappedDisplay.country : null,
8818
8788
  source: swappedDisplay.kind === "list" ? swappedDisplay.source : "configured"
8819
8789
  };
8820
- }, [bankRowOffered, swappedCashDisplay, swappedOffersBank]);
8790
+ }, [
8791
+ bankRowOffered,
8792
+ fiatEnabled,
8793
+ providersLoading,
8794
+ swappedCashDisplay,
8795
+ swappedOffersBank
8796
+ ]);
8821
8797
  _react.useEffect.call(void 0, () => {
8822
8798
  if (cashDisplay.kind === "hidden" && fiatEnabled) {
8823
8799
  analytics.friction(
@@ -8832,25 +8808,28 @@ function DepositFlow({
8832
8808
  }
8833
8809
  }, [analytics, cashDisplay, fiatEnabled, hasConfiguredFiatMethods]);
8834
8810
  const displayedFiatSource = cashDisplay.kind === "list" ? cashDisplay.source : void 0;
8811
+ const providerOf = _react.useCallback.call(void 0,
8812
+ (method) => cashDisplay.kind === "list" && _optionalChain([cashDisplay, 'access', _316 => _316.methods, 'access', _317 => _317.find, 'call', _318 => _318((m) => m.method === method), 'optionalAccess', _319 => _319.provider]) || "swapped",
8813
+ [cashDisplay]
8814
+ );
8835
8815
  const handleSelectDisplayedFiatMethod = _react.useCallback.call(void 0,
8836
8816
  (method) => {
8837
8817
  if (!displayedFiatSource) return;
8838
- handleSelectFiatMethod(method, displayedFiatSource);
8818
+ handleSelectFiatMethod(method, displayedFiatSource, providerOf(method));
8839
8819
  },
8840
- [displayedFiatSource, handleSelectFiatMethod]
8820
+ [displayedFiatSource, handleSelectFiatMethod, providerOf]
8841
8821
  );
8842
8822
  const handlePrefetchDisplayedFiatMethod = _react.useCallback.call(void 0,
8843
8823
  (method) => {
8844
- if (!displayedFiatSource) return;
8845
- if (bankRowOffered && method === "bank-transfer") return;
8824
+ if (!displayedFiatSource || providerOf(method) !== "swapped") return;
8846
8825
  handlePrefetchFiatMethod(method, displayedFiatSource);
8847
8826
  },
8848
- [bankRowOffered, displayedFiatSource, handlePrefetchFiatMethod]
8827
+ [displayedFiatSource, handlePrefetchFiatMethod, providerOf]
8849
8828
  );
8850
8829
  const handleNewDeposit = _react.useCallback.call(void 0, () => {
8851
8830
  analytics.completeStep();
8852
8831
  analytics.resetAttempt();
8853
- _optionalChain([onLifecycleRef, 'access', _317 => _317.current, 'optionalCall', _318 => _318({
8832
+ _optionalChain([onLifecycleRef, 'access', _320 => _320.current, 'optionalCall', _321 => _321({
8854
8833
  type: "smart-account-changed",
8855
8834
  evm: null,
8856
8835
  solana: null
@@ -8882,17 +8861,17 @@ function DepositFlow({
8882
8861
  payment
8883
8862
  ]
8884
8863
  );
8885
- const desiredSetupRequestKey = _chunkCXRH5MKOcjs.computeRequestKey.call(void 0, setupInput);
8864
+ const desiredSetupRequestKey = _chunkKXSU24RUcjs.computeRequestKey.call(void 0, setupInput);
8886
8865
  const setupReady = setupSlice.status === "ready" && setupSlice.requestKey === desiredSetupRequestKey;
8887
8866
  _react.useEffect.call(void 0, () => {
8888
8867
  void (async () => {
8889
- const requestKey = _chunkCXRH5MKOcjs.computeRequestKey.call(void 0, setupInput);
8890
- const cacheKey = _chunkCXRH5MKOcjs.computeCacheKey.call(void 0, setupInput);
8891
- const cacheable = _chunkCXRH5MKOcjs.computeIsCacheable.call(void 0, setupInput);
8868
+ const requestKey = _chunkKXSU24RUcjs.computeRequestKey.call(void 0, setupInput);
8869
+ const cacheKey = _chunkKXSU24RUcjs.computeCacheKey.call(void 0, setupInput);
8870
+ const cacheable = _chunkKXSU24RUcjs.computeIsCacheable.call(void 0, setupInput);
8892
8871
  if (storeApi.getState().setup.requestKey === requestKey) {
8893
8872
  return;
8894
8873
  }
8895
- const dedupedResult = _chunkCXRH5MKOcjs.readDedupedAccountSetupResult.call(void 0, requestKey);
8874
+ const dedupedResult = _chunkKXSU24RUcjs.readDedupedAccountSetupResult.call(void 0, requestKey);
8896
8875
  if (dedupedResult) {
8897
8876
  storeApi.dispatch({
8898
8877
  type: "setup/started",
@@ -8918,7 +8897,7 @@ function DepositFlow({
8918
8897
  cacheable
8919
8898
  });
8920
8899
  try {
8921
- const result = await _chunkCXRH5MKOcjs.runAccountSetupDeduped.call(void 0,
8900
+ const result = await _chunkKXSU24RUcjs.runAccountSetupDeduped.call(void 0,
8922
8901
  setupInput,
8923
8902
  { service, debug },
8924
8903
  requestKey
@@ -8933,7 +8912,7 @@ function DepositFlow({
8933
8912
  }
8934
8913
  });
8935
8914
  } catch (error) {
8936
- const message = error instanceof _chunkCXRH5MKOcjs.SetupError ? error.message : "Deposit service is temporarily unavailable. Please try again shortly.";
8915
+ const message = error instanceof _chunkKXSU24RUcjs.SetupError ? error.message : "Deposit service is temporarily unavailable. Please try again shortly.";
8937
8916
  storeApi.dispatch({
8938
8917
  type: "setup/failed",
8939
8918
  requestKey,
@@ -8965,11 +8944,11 @@ function DepositFlow({
8965
8944
  return;
8966
8945
  }
8967
8946
  storeApi.dispatch({ type: "portfolio/loading", network, address });
8968
- const requestId = _optionalChain([readPortfolioEntry, 'call', _319 => _319(
8947
+ const requestId = _optionalChain([readPortfolioEntry, 'call', _322 => _322(
8969
8948
  storeApi.getState().portfolio,
8970
8949
  network,
8971
8950
  address
8972
- ), 'optionalAccess', _320 => _320.requestId]);
8951
+ ), 'optionalAccess', _323 => _323.requestId]);
8973
8952
  if (requestId === void 0) return;
8974
8953
  void (async () => {
8975
8954
  try {
@@ -8982,7 +8961,7 @@ function DepositFlow({
8982
8961
  address,
8983
8962
  requestId,
8984
8963
  totalUsd: portfolio.totalUsd,
8985
- chainIds: _chunkCXRH5MKOcjs.chainIdsByValue.call(void 0, portfolio.tokens)
8964
+ chainIds: _chunkKXSU24RUcjs.chainIdsByValue.call(void 0, portfolio.tokens)
8986
8965
  });
8987
8966
  } catch (e42) {
8988
8967
  storeApi.dispatch({
@@ -9006,7 +8985,7 @@ function DepositFlow({
9006
8985
  { type: "transaction_hash", value: data.txHash },
9007
8986
  "transfer_tracking"
9008
8987
  );
9009
- _optionalChain([onLifecycleRef, 'access', _321 => _321.current, 'optionalCall', _322 => _322({ type: "submitted", ...data })]);
8988
+ _optionalChain([onLifecycleRef, 'access', _324 => _324.current, 'optionalCall', _325 => _325({ type: "submitted", ...data })]);
9010
8989
  },
9011
8990
  [analytics, logFlow, onLifecycleRef]
9012
8991
  );
@@ -9073,7 +9052,7 @@ function DepositFlow({
9073
9052
  sourceDecimals: tokenAtSubmit.decimals,
9074
9053
  inputAmountUsd: amountUsd
9075
9054
  });
9076
- _optionalChain([onLifecycleRef, 'access', _323 => _323.current, 'optionalCall', _324 => _324({
9055
+ _optionalChain([onLifecycleRef, 'access', _326 => _326.current, 'optionalCall', _327 => _327({
9077
9056
  type: "submitted",
9078
9057
  txHash,
9079
9058
  sourceChain: "solana",
@@ -9164,8 +9143,8 @@ function DepositFlow({
9164
9143
  sourceChain: chainId,
9165
9144
  sourceToken: token,
9166
9145
  amount,
9167
- sourceSymbol: _optionalChain([asset, 'optionalAccess', _325 => _325.symbol]),
9168
- sourceDecimals: _optionalChain([asset, 'optionalAccess', _326 => _326.decimals]),
9146
+ sourceSymbol: _optionalChain([asset, 'optionalAccess', _328 => _328.symbol]),
9147
+ sourceDecimals: _optionalChain([asset, 'optionalAccess', _329 => _329.decimals]),
9169
9148
  inputAmountUsd: _nullishCoalesce(depositAtSubmit.inputAmountUsd, () => ( void 0)),
9170
9149
  directTransfer: routed.directTransfer,
9171
9150
  sourceTxHashPending: routed.sourceTxHashPending,
@@ -9206,7 +9185,7 @@ function DepositFlow({
9206
9185
  swappedContext,
9207
9186
  initialEvent: info.initialEvent
9208
9187
  });
9209
- _optionalChain([onLifecycleRef, 'access', _327 => _327.current, 'optionalCall', _328 => _328({
9188
+ _optionalChain([onLifecycleRef, 'access', _330 => _330.current, 'optionalCall', _331 => _331({
9210
9189
  type: "submitted",
9211
9190
  txHash: info.txHash,
9212
9191
  sourceChain: SWAPPED_SOURCE_CHAIN,
@@ -9234,12 +9213,12 @@ function DepositFlow({
9234
9213
  const handleDepositSubmittedCallback = _react.useCallback.call(void 0,
9235
9214
  (txHash, sourceChain, amount) => {
9236
9215
  const depositAtSubmit = storeApi.getState().deposit;
9237
- _optionalChain([onLifecycleRef, 'access', _329 => _329.current, 'optionalCall', _330 => _330({
9216
+ _optionalChain([onLifecycleRef, 'access', _332 => _332.current, 'optionalCall', _333 => _333({
9238
9217
  type: "submitted",
9239
9218
  txHash,
9240
9219
  sourceChain,
9241
9220
  amount,
9242
- sourceDecimals: _optionalChain([depositAtSubmit, 'access', _331 => _331.selectedAsset, 'optionalAccess', _332 => _332.decimals]),
9221
+ sourceDecimals: _optionalChain([depositAtSubmit, 'access', _334 => _334.selectedAsset, 'optionalAccess', _335 => _335.decimals]),
9243
9222
  amountUsd: _nullishCoalesce(depositAtSubmit.inputAmountUsd, () => ( void 0))
9244
9223
  })]);
9245
9224
  },
@@ -9252,7 +9231,7 @@ function DepositFlow({
9252
9231
  analyticsStepForFlowStep(analyticsMethod, "processing")
9253
9232
  );
9254
9233
  analytics.outcome("completed");
9255
- _optionalChain([onLifecycleRef, 'access', _333 => _333.current, 'optionalCall', _334 => _334({
9234
+ _optionalChain([onLifecycleRef, 'access', _336 => _336.current, 'optionalCall', _337 => _337({
9256
9235
  type: "complete",
9257
9236
  txHash,
9258
9237
  destinationTxHash,
@@ -9269,7 +9248,7 @@ function DepositFlow({
9269
9248
  );
9270
9249
  analytics.outcome("failed");
9271
9250
  analytics.failure("processor_failed", false);
9272
- _optionalChain([onLifecycleRef, 'access', _335 => _335.current, 'optionalCall', _336 => _336({ type: "failed", txHash, error })]);
9251
+ _optionalChain([onLifecycleRef, 'access', _338 => _338.current, 'optionalCall', _339 => _339({ type: "failed", txHash, error })]);
9273
9252
  },
9274
9253
  [analytics, analyticsMethod, logFlowError, onLifecycleRef]
9275
9254
  );
@@ -9287,7 +9266,7 @@ function DepositFlow({
9287
9266
  failureStep
9288
9267
  );
9289
9268
  }
9290
- _optionalChain([onErrorRef, 'access', _337 => _337.current, 'optionalCall', _338 => _338({
9269
+ _optionalChain([onErrorRef, 'access', _340 => _340.current, 'optionalCall', _341 => _341({
9291
9270
  message,
9292
9271
  code,
9293
9272
  ...cause === void 0 ? {} : { cause }
@@ -9340,9 +9319,9 @@ function DepositFlow({
9340
9319
  address: _nullishCoalesce(_nullishCoalesce(option.address, () => ( option.solanaAddress)), () => ( option.id)),
9341
9320
  state,
9342
9321
  errorReason: _nullishCoalesce(entry.message, () => ( void 0)),
9343
- balanceStatus: _nullishCoalesce(_optionalChain([portfolioEntry, 'optionalAccess', _339 => _339.status]), () => ( "loading")),
9344
- balanceUsd: _optionalChain([portfolioEntry, 'optionalAccess', _340 => _340.status]) === "ready" ? portfolioEntry.totalUsd : null,
9345
- balanceChainIds: _nullishCoalesce(_optionalChain([portfolioEntry, 'optionalAccess', _341 => _341.chainIds]), () => ( []))
9322
+ balanceStatus: _nullishCoalesce(_optionalChain([portfolioEntry, 'optionalAccess', _342 => _342.status]), () => ( "loading")),
9323
+ balanceUsd: _optionalChain([portfolioEntry, 'optionalAccess', _343 => _343.status]) === "ready" ? portfolioEntry.totalUsd : null,
9324
+ balanceChainIds: _nullishCoalesce(_optionalChain([portfolioEntry, 'optionalAccess', _344 => _344.chainIds]), () => ( []))
9346
9325
  };
9347
9326
  });
9348
9327
  }, [enableWallet, walletOptions, setupSlice, portfolioSlice]);
@@ -9379,7 +9358,8 @@ function DepositFlow({
9379
9358
  recommendedMethod: cashDisplay.kind === "list" ? cashDisplay.recommendedMethod : void 0,
9380
9359
  onSelectFiatMethod: cashDisplay.kind === "list" ? handleSelectDisplayedFiatMethod : void 0,
9381
9360
  onPrefetchFiatMethod: cashDisplay.kind === "list" ? handlePrefetchDisplayedFiatMethod : void 0,
9382
- onSelectFundFromExchange: enableExchangeConnect ? () => handleSelectExchange() : void 0,
9361
+ onSelectFundFromExchange: exchangeOffered || enableExchangeConnect && providersLoading ? () => handleSelectExchange() : void 0,
9362
+ fundFromExchangeLoading: enableExchangeConnect && providersLoading,
9383
9363
  onRequestConnect: enableWallet ? onRequestConnect : void 0,
9384
9364
  onConnect: enableWallet ? onConnect : void 0,
9385
9365
  onDisconnect,
@@ -9496,30 +9476,21 @@ function DepositFlow({
9496
9476
  )
9497
9477
  ] });
9498
9478
  }
9479
+ const rampCallbacks = {
9480
+ service,
9481
+ onSwappedComplete: handleSwappedComplete,
9482
+ onSwappedFailed: handleDepositFailed,
9483
+ onClose: () => _optionalChain([onClose, 'optionalCall', _345 => _345(openExternally ? "native_dismiss_request" : "header_button")]),
9484
+ onGoBack: handleProviderBack,
9485
+ onError: handleError,
9486
+ onAttemptConsumed: handleSwappedAttemptConsumed,
9487
+ onProviderHandoff: handleSwappedProviderHandoff,
9488
+ onRetry: handleSwappedRetry,
9489
+ onCancelled: () => analytics.outcome("cancelled"),
9490
+ onImmersiveChange: onSwappedImmersiveChange,
9491
+ openExternally
9492
+ };
9499
9493
  if (isFiatOnrampMode) {
9500
- const swappedStep = step.type === "fiat-onramp" ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
9501
- FiatOnrampStep,
9502
- {
9503
- smartAccount: step.smartAccount,
9504
- service,
9505
- paymentMethod: step.paymentMethod,
9506
- methodSelectionSource: step.methodSelectionSource,
9507
- consumePrefetchedUrl: consumeSwappedWidgetUrlPrefetch,
9508
- onSwappedComplete: handleSwappedComplete,
9509
- onSwappedFailed: handleDepositFailed,
9510
- onClose: () => _optionalChain([onClose, 'optionalCall', _342 => _342(
9511
- openExternally ? "native_dismiss_request" : "header_button"
9512
- )]),
9513
- onGoBack: handleProviderBack,
9514
- onError: handleError,
9515
- onAttemptConsumed: handleSwappedAttemptConsumed,
9516
- onProviderHandoff: handleSwappedProviderHandoff,
9517
- onRetry: handleSwappedRetry,
9518
- onCancelled: () => analytics.outcome("cancelled"),
9519
- onImmersiveChange: onSwappedImmersiveChange,
9520
- openExternally
9521
- }
9522
- ) : null;
9523
9494
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
9524
9495
  "div",
9525
9496
  {
@@ -9534,23 +9505,28 @@ function DepositFlow({
9534
9505
  onRetry: activeEntry.status === "error" ? () => handleRetrySetup() : void 0
9535
9506
  }
9536
9507
  ),
9537
- step.type === "fiat-onramp" && bankRowOffered && bankOnramp && step.paymentMethod === "bank-transfer" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _react.Suspense, { fallback: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, AccountPreparingSkeleton, {}), children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
9538
- BankOnrampStep,
9508
+ step.type === "fiat-onramp" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _react.Suspense, { fallback: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, AccountPreparingSkeleton, {}), children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
9509
+ RampOrderStep,
9539
9510
  {
9540
- backendUrl,
9511
+ ...rampCallbacks,
9541
9512
  smartAccount: step.smartAccount,
9542
- bankOnramp,
9543
- onJourney: onBankJourney,
9544
- onGoBack: handleProviderBack,
9545
- onError: handleError,
9546
- openExternally,
9547
- onUnavailable: handleBankOnrampUnavailable
9548
- },
9549
- `${backendUrl}:${step.smartAccount}`
9513
+ order: step.provider === "noah" && bankRowOffered && bankOnramp ? {
9514
+ flow: "funding_account",
9515
+ backendUrl,
9516
+ bankOnramp,
9517
+ onJourney: onBankJourney,
9518
+ onUnavailable: handleBankOnrampUnavailable
9519
+ } : {
9520
+ flow: "hosted",
9521
+ kind: "fiat",
9522
+ method: step.paymentMethod,
9523
+ methodSelectionSource: step.methodSelectionSource,
9524
+ consumePrefetchedUrl: consumeSwappedWidgetUrlPrefetch
9525
+ }
9526
+ }
9550
9527
  ) }),
9551
- step.type === "fiat-onramp" && (!bankRowOffered || step.paymentMethod !== "bank-transfer") && swappedStep,
9552
9528
  step.type === "processing" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
9553
- _chunkCXRH5MKOcjs.ProcessingStep,
9529
+ _chunkKXSU24RUcjs.ProcessingStep,
9554
9530
  {
9555
9531
  flowLabel: payment ? "payment" : void 0,
9556
9532
  smartAccount: step.smartAccount,
@@ -9609,29 +9585,20 @@ function DepositFlow({
9609
9585
  }
9610
9586
  ),
9611
9587
  step.type === "exchange-connect" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
9612
- ExchangeConnectStep,
9588
+ RampOrderStep,
9613
9589
  {
9590
+ ...rampCallbacks,
9614
9591
  smartAccount: step.smartAccount,
9615
- service,
9616
- connection: step.connection,
9617
- loadUrl: () => loadSwappedConnectUrl(step.smartAccount, step.connection),
9618
- onSwappedComplete: handleSwappedComplete,
9619
- onSwappedFailed: handleDepositFailed,
9620
- onClose: () => _optionalChain([onClose, 'optionalCall', _343 => _343(
9621
- openExternally ? "native_dismiss_request" : "header_button"
9622
- )]),
9623
- onGoBack: handleProviderBack,
9624
- onError: handleError,
9625
- onAttemptConsumed: handleSwappedAttemptConsumed,
9626
- onProviderHandoff: handleSwappedProviderHandoff,
9627
- onRetry: handleSwappedRetry,
9628
- onCancelled: () => analytics.outcome("cancelled"),
9629
- onImmersiveChange: onSwappedImmersiveChange,
9630
- openExternally
9592
+ order: {
9593
+ flow: "hosted",
9594
+ kind: "exchange",
9595
+ connection: step.connection,
9596
+ loadPreparedUrl: () => loadSwappedConnectUrl(step.smartAccount, step.connection)
9597
+ }
9631
9598
  }
9632
9599
  ),
9633
9600
  step.type === "processing" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
9634
- _chunkCXRH5MKOcjs.ProcessingStep,
9601
+ _chunkKXSU24RUcjs.ProcessingStep,
9635
9602
  {
9636
9603
  flowLabel: payment ? "payment" : void 0,
9637
9604
  smartAccount: step.smartAccount,
@@ -9667,8 +9634,8 @@ function DepositFlow({
9667
9634
  );
9668
9635
  }
9669
9636
  if (isSolanaWalletMode) {
9670
- const solanaAddr = _optionalChain([walletSession, 'optionalAccess', _344 => _344.solanaAddress]);
9671
- const solanaProvider = _optionalChain([walletSession, 'optionalAccess', _345 => _345.solanaProvider]);
9637
+ const solanaAddr = _optionalChain([walletSession, 'optionalAccess', _346 => _346.solanaAddress]);
9638
+ const solanaProvider = _optionalChain([walletSession, 'optionalAccess', _347 => _347.solanaProvider]);
9672
9639
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-modal-body", children: [
9673
9640
  effectiveStep.type === "setup" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
9674
9641
  AccountPreparingSkeleton,
@@ -9720,7 +9687,7 @@ function DepositFlow({
9720
9687
  targetToken,
9721
9688
  service,
9722
9689
  solanaProvider,
9723
- solanaConnection: _optionalChain([walletSession, 'optionalAccess', _346 => _346.solanaConnection]),
9690
+ solanaConnection: _optionalChain([walletSession, 'optionalAccess', _348 => _348.solanaConnection]),
9724
9691
  uiConfig,
9725
9692
  onConfirm: handleSolanaConfirmed,
9726
9693
  onError: handleError,
@@ -9762,7 +9729,7 @@ function DepositFlow({
9762
9729
  ) })
9763
9730
  ] }) : null,
9764
9731
  effectiveStep.type === "processing" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
9765
- _chunkCXRH5MKOcjs.ProcessingStep,
9732
+ _chunkKXSU24RUcjs.ProcessingStep,
9766
9733
  {
9767
9734
  flowLabel: payment ? "payment" : void 0,
9768
9735
  smartAccount: effectiveStep.smartAccount,
@@ -9802,7 +9769,7 @@ function DepositFlow({
9802
9769
  children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
9803
9770
  DappImportAssetSelectSkeleton,
9804
9771
  {
9805
- sourceLabel: _nullishCoalesce(_optionalChain([activeDappImportProvider, 'optionalAccess', _347 => _347.sourceLabel]), () => ( "")),
9772
+ sourceLabel: _nullishCoalesce(_optionalChain([activeDappImportProvider, 'optionalAccess', _349 => _349.sourceLabel]), () => ( "")),
9806
9773
  error: dappImportBootError,
9807
9774
  onRetry: handleBootRetry
9808
9775
  }
@@ -9824,7 +9791,7 @@ function DepositFlow({
9824
9791
  rows: dappImportSelectRows,
9825
9792
  onRequestConnect: _nullishCoalesce(onConnect, () => ( onRequestConnect)),
9826
9793
  onSelect: (providerId) => {
9827
- const availabilityEntry = dappImportOwner && _optionalChain([dappImportAvailabilityOwner, 'optionalAccess', _348 => _348.toLowerCase, 'call', _349 => _349()]) === dappImportOwner.toLowerCase() ? dappImportAvailability[providerId] : void 0;
9794
+ const availabilityEntry = dappImportOwner && _optionalChain([dappImportAvailabilityOwner, 'optionalAccess', _350 => _350.toLowerCase, 'call', _351 => _351()]) === dappImportOwner.toLowerCase() ? dappImportAvailability[providerId] : void 0;
9828
9795
  if (availabilityEntry === "error") {
9829
9796
  storeApi.dispatch({
9830
9797
  type: "dapp-import/availability-retry-requested"
@@ -9843,16 +9810,16 @@ function DepositFlow({
9843
9810
  }
9844
9811
  );
9845
9812
  }
9846
- if (!_optionalChain([signerContext, 'optionalAccess', _350 => _350.walletClient]) || !_optionalChain([signerContext, 'optionalAccess', _351 => _351.publicClient])) {
9813
+ if (!_optionalChain([signerContext, 'optionalAccess', _352 => _352.walletClient]) || !_optionalChain([signerContext, 'optionalAccess', _353 => _353.publicClient])) {
9847
9814
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-modal-body", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-step", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-loading-state", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-loading-text", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "rs-loading-title", children: "Connecting wallet\u2026" }) }) }) }) });
9848
9815
  }
9849
9816
  const ownerAddress = signerContext.ownerAddress;
9850
- const ownerChainId = _nullishCoalesce(_nullishCoalesce(_optionalChain([signerContext, 'access', _352 => _352.walletClient, 'optionalAccess', _353 => _353.chain, 'optionalAccess', _354 => _354.id]), () => ( _optionalChain([signerContext, 'access', _355 => _355.publicClient, 'access', _356 => _356.chain, 'optionalAccess', _357 => _357.id]))), () => ( setupChainId));
9817
+ const ownerChainId = _nullishCoalesce(_nullishCoalesce(_optionalChain([signerContext, 'access', _354 => _354.walletClient, 'optionalAccess', _355 => _355.chain, 'optionalAccess', _356 => _356.id]), () => ( _optionalChain([signerContext, 'access', _357 => _357.publicClient, 'access', _358 => _358.chain, 'optionalAccess', _359 => _359.id]))), () => ( setupChainId));
9851
9818
  const getReadClientForChain = (chainId) => {
9852
- if (_optionalChain([signerContext, 'access', _358 => _358.publicClient, 'access', _359 => _359.chain, 'optionalAccess', _360 => _360.id]) === chainId) {
9819
+ if (_optionalChain([signerContext, 'access', _360 => _360.publicClient, 'access', _361 => _361.chain, 'optionalAccess', _362 => _362.id]) === chainId) {
9853
9820
  return signerContext.publicClient;
9854
9821
  }
9855
- return _chunkCXRH5MKOcjs.getPublicClient.call(void 0, chainId, rpcUrls);
9822
+ return _chunkKXSU24RUcjs.getPublicClient.call(void 0, chainId, rpcUrls);
9856
9823
  };
9857
9824
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-modal-body", children: [
9858
9825
  effectiveStep.type === "setup" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
@@ -9878,9 +9845,9 @@ function DepositFlow({
9878
9845
  effectiveStep.type === "dapp-import-asset-select" && activeDappImportProvider && activeDappImportAvailability && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
9879
9846
  DappImportAssetSelectStep,
9880
9847
  {
9881
- sourceLabel: _nullishCoalesce(_optionalChain([activeDappImportAvailability, 'access', _361 => _361.assets, 'access', _362 => _362[0], 'optionalAccess', _363 => _363.sourceLabel]), () => ( activeDappImportProvider.sourceLabel)),
9848
+ sourceLabel: _nullishCoalesce(_optionalChain([activeDappImportAvailability, 'access', _363 => _363.assets, 'access', _364 => _364[0], 'optionalAccess', _365 => _365.sourceLabel]), () => ( activeDappImportProvider.sourceLabel)),
9882
9849
  assets: activeDappImportAvailability.assets,
9883
- incompleteSummary: _optionalChain([activeDappImportAvailability, 'access', _364 => _364.incomplete, 'optionalAccess', _365 => _365.summary]),
9850
+ incompleteSummary: _optionalChain([activeDappImportAvailability, 'access', _366 => _366.incomplete, 'optionalAccess', _367 => _367.summary]),
9884
9851
  onSelect: handleDappImportAssetSelected
9885
9852
  }
9886
9853
  ),
@@ -9960,7 +9927,7 @@ function DepositFlow({
9960
9927
  }
9961
9928
  ),
9962
9929
  effectiveStep.type === "processing" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
9963
- _chunkCXRH5MKOcjs.ProcessingStep,
9930
+ _chunkKXSU24RUcjs.ProcessingStep,
9964
9931
  {
9965
9932
  flowLabel: payment ? "payment" : void 0,
9966
9933
  smartAccount: effectiveStep.smartAccount,
@@ -10105,7 +10072,7 @@ function useBankHistory(source, open, panelOpen) {
10105
10072
 
10106
10073
  var ReownDepositInner = _react.lazy.call(void 0, async () => {
10107
10074
  await loadReownDependencies();
10108
- const module = await Promise.resolve().then(() => _interopRequireWildcard(require("./DepositModalReown-ALVWADG7.cjs")));
10075
+ const module = await Promise.resolve().then(() => _interopRequireWildcard(require("./DepositModalReown-7EHOJTFW.cjs")));
10109
10076
  return { default: module.DepositModalReown };
10110
10077
  });
10111
10078
  function buildDepositAnalyticsSessionProperties({
@@ -10135,7 +10102,7 @@ function buildDepositAnalyticsSessionProperties({
10135
10102
  enabledFundingMethods.push("wallet");
10136
10103
  }
10137
10104
  if (enableQrTransfer) enabledFundingMethods.push("transfer");
10138
- if (bankOnrampEnabled || enableFiatOnramp && _optionalChain([configuredFiatIdentifiers, 'optionalAccess', _366 => _366.length]) !== 0) {
10105
+ if (bankOnrampEnabled || enableFiatOnramp && _optionalChain([configuredFiatIdentifiers, 'optionalAccess', _368 => _368.length]) !== 0) {
10139
10106
  enabledFundingMethods.push("fiat_onramp");
10140
10107
  }
10141
10108
  if (enableExchangeConnect) enabledFundingMethods.push("exchange_connect");
@@ -10155,7 +10122,7 @@ function buildDepositAnalyticsSessionProperties({
10155
10122
  amount: defaultAmount !== void 0,
10156
10123
  initial_asset_migration: initialAssetMigration !== void 0
10157
10124
  },
10158
- ..._chunkCXRH5MKOcjs.analyticsTargetProperties.call(void 0, { targetChain, targetToken })
10125
+ ..._chunkKXSU24RUcjs.analyticsTargetProperties.call(void 0, { targetChain, targetToken })
10159
10126
  };
10160
10127
  }
10161
10128
  var WALLET_CLIENT_PROP = "walletClient";
@@ -10163,8 +10130,8 @@ function hasSuppliedWalletClient(props) {
10163
10130
  return Object.prototype.hasOwnProperty.call(props, WALLET_CLIENT_PROP);
10164
10131
  }
10165
10132
  function DepositModal(props) {
10166
- _chunkCXRH5MKOcjs.warnRemovedProps.call(void 0, "DepositModal", props);
10167
- _chunkCXRH5MKOcjs.checkBackendUrl.call(void 0, "DepositModal", props.backendUrl);
10133
+ _chunkKXSU24RUcjs.warnRemovedProps.call(void 0, "DepositModal", props);
10134
+ _chunkKXSU24RUcjs.checkBackendUrl.call(void 0, "DepositModal", props.backendUrl);
10168
10135
  const needsReown = !!props.reownAppId;
10169
10136
  const hasWalletClientProp = hasSuppliedWalletClient(props);
10170
10137
  if (needsReown) {
@@ -10251,7 +10218,7 @@ function DepositModalInner({
10251
10218
  journey.source ? { source: journey.source, scope: bankScope } : null
10252
10219
  );
10253
10220
  }, [bankScope]);
10254
- const bankSource = _optionalChain([bankSession, 'optionalAccess', _367 => _367.scope]) === bankScope ? bankSession.source : null;
10221
+ const bankSource = _optionalChain([bankSession, 'optionalAccess', _369 => _369.scope]) === bankScope ? bankSession.source : null;
10255
10222
  _react.useEffect.call(void 0, () => {
10256
10223
  if (!isOpen) {
10257
10224
  setBankSession(null);
@@ -10264,30 +10231,30 @@ function DepositModalInner({
10264
10231
  void 0
10265
10232
  );
10266
10233
  const [processingSettled, setProcessingSettled] = _react.useState.call(void 0, false);
10267
- const historyButtonVisible = !payment && (bankJourneyVisible || _chunkCXRH5MKOcjs.isHistoryEntryVisible.call(void 0, {
10234
+ const historyButtonVisible = !payment && (bankJourneyVisible || _chunkKXSU24RUcjs.isHistoryEntryVisible.call(void 0, {
10268
10235
  screen: currentScreen,
10269
10236
  submitting,
10270
10237
  settled: processingSettled
10271
10238
  }));
10272
10239
  const targetChain = typeof targetChainProp === "string" ? targetChainProp : _chunkFKJ6EJHHcjs.getChainId.call(void 0, targetChainProp);
10273
10240
  const sourceChain = sourceChainProp ? _chunkFKJ6EJHHcjs.getChainId.call(void 0, sourceChainProp) : void 0;
10274
- const rpcUrls = _chunkCXRH5MKOcjs.useStableRpcUrls.call(void 0, rpcUrlsProp);
10241
+ const rpcUrls = _chunkKXSU24RUcjs.useStableRpcUrls.call(void 0, rpcUrlsProp);
10275
10242
  const service = _react.useMemo.call(void 0,
10276
- () => _chunkCXRH5MKOcjs.createDepositService.call(void 0, backendUrl, {
10243
+ () => _chunkKXSU24RUcjs.createDepositService.call(void 0, backendUrl, {
10277
10244
  debug,
10278
10245
  debugScope: "service:deposit"
10279
10246
  }),
10280
10247
  [backendUrl, debug]
10281
10248
  );
10282
10249
  const historyAnalytics = _react.useMemo.call(void 0,
10283
- () => _chunkCXRH5MKOcjs.createHistoryAnalytics.call(void 0, {
10250
+ () => _chunkKXSU24RUcjs.createHistoryAnalytics.call(void 0, {
10284
10251
  modal: "deposit",
10285
10252
  controllerRef: analyticsControllerRef,
10286
10253
  sessionIdRef: analyticsSessionIdRef
10287
10254
  }),
10288
10255
  []
10289
10256
  );
10290
- const history = _chunkCXRH5MKOcjs.useHistoryPanel.call(void 0, {
10257
+ const history = _chunkKXSU24RUcjs.useHistoryPanel.call(void 0, {
10291
10258
  isOpen: isOpen && !payment,
10292
10259
  recipient,
10293
10260
  service,
@@ -10339,15 +10306,15 @@ function DepositModalInner({
10339
10306
  }, [store, targetChain, targetToken]);
10340
10307
  _react.useEffect.call(void 0, () => {
10341
10308
  if (!isOpen || !modalRef.current) return;
10342
- return _chunkCXRH5MKOcjs.applyTheme.call(void 0, modalRef.current, theme);
10309
+ return _chunkKXSU24RUcjs.applyTheme.call(void 0, modalRef.current, theme);
10343
10310
  }, [isOpen, theme]);
10344
10311
  _react.useEffect.call(void 0, () => {
10345
10312
  if (isOpen) {
10346
- _optionalChain([onReadyRef, 'access', _368 => _368.current, 'optionalCall', _369 => _369()]);
10313
+ _optionalChain([onReadyRef, 'access', _370 => _370.current, 'optionalCall', _371 => _371()]);
10347
10314
  }
10348
10315
  }, [isOpen, onReadyRef]);
10349
10316
  _react.useEffect.call(void 0, () => {
10350
- _optionalChain([onUiStateRef, 'access', _370 => _370.current, 'optionalCall', _371 => _371({
10317
+ _optionalChain([onUiStateRef, 'access', _372 => _372.current, 'optionalCall', _373 => _373({
10351
10318
  screen: currentScreen,
10352
10319
  back: backHandler,
10353
10320
  // A recovery in flight is a submission whose outcome is unknown, so a
@@ -10371,7 +10338,7 @@ function DepositModalInner({
10371
10338
  const onLifecycleRef = _chunkG264OM23cjs.useLatestRef.call(void 0, onLifecycle);
10372
10339
  const handleLifecycle = _react.useCallback.call(void 0,
10373
10340
  (event) => {
10374
- _optionalChain([onLifecycleRef, 'access', _372 => _372.current, 'optionalCall', _373 => _373(event)]);
10341
+ _optionalChain([onLifecycleRef, 'access', _374 => _374.current, 'optionalCall', _375 => _375(event)]);
10375
10342
  if (event.type === "smart-account-changed" && !event.evm && !event.solana) {
10376
10343
  invalidateHistory();
10377
10344
  }
@@ -10385,8 +10352,8 @@ function DepositModalInner({
10385
10352
  (source) => {
10386
10353
  if (recoverySubmitting) return;
10387
10354
  const analytics = analyticsControllerRef.current;
10388
- _optionalChain([analytics, 'optionalAccess', _374 => _374.abandon, 'call', _375 => _375(source === "provider_back" ? "provider_back" : "modal_close")]);
10389
- _optionalChain([analytics, 'optionalAccess', _376 => _376.close, 'call', _377 => _377(source)]);
10355
+ _optionalChain([analytics, 'optionalAccess', _376 => _376.abandon, 'call', _377 => _377(source === "provider_back" ? "provider_back" : "modal_close")]);
10356
+ _optionalChain([analytics, 'optionalAccess', _378 => _378.close, 'call', _379 => _379(source)]);
10390
10357
  onClose();
10391
10358
  },
10392
10359
  [onClose, recoverySubmitting]
@@ -10402,8 +10369,8 @@ function DepositModalInner({
10402
10369
  _react.useEffect.call(void 0, () => {
10403
10370
  if (previousOpenRef.current && !isOpen) {
10404
10371
  const analytics = analyticsControllerRef.current;
10405
- _optionalChain([analytics, 'optionalAccess', _378 => _378.abandon, 'call', _379 => _379("modal_close")]);
10406
- _optionalChain([analytics, 'optionalAccess', _380 => _380.close, 'call', _381 => _381("host_controlled")]);
10372
+ _optionalChain([analytics, 'optionalAccess', _380 => _380.abandon, 'call', _381 => _381("modal_close")]);
10373
+ _optionalChain([analytics, 'optionalAccess', _382 => _382.close, 'call', _383 => _383("host_controlled")]);
10407
10374
  }
10408
10375
  previousOpenRef.current = isOpen;
10409
10376
  }, [isOpen]);
@@ -10443,12 +10410,12 @@ function DepositModalInner({
10443
10410
  targetChain,
10444
10411
  targetToken
10445
10412
  });
10446
- const showBackButton = _nullishCoalesce(_optionalChain([uiConfig, 'optionalAccess', _382 => _382.showBackButton]), () => ( true));
10413
+ const showBackButton = _nullishCoalesce(_optionalChain([uiConfig, 'optionalAccess', _384 => _384.showBackButton]), () => ( true));
10447
10414
  const canGoBack = backHandler !== void 0;
10448
10415
  const hideHeaderChrome = swappedImmersive;
10449
10416
  const modalClassName = `rs-modal${hideHeaderChrome ? " rs-modal--swapped-iframe" : ""}`;
10450
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.RpcUrlsProvider, { value: rpcUrls, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.ChainCatalogProvider, { service, rpcUrls, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCXRH5MKOcjs.AssetMetadataProvider, { service, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, DepositStoreProvider, { store, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
10451
- _chunkCXRH5MKOcjs.Modal,
10417
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.RpcUrlsProvider, { value: rpcUrls, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.ChainCatalogProvider, { service, rpcUrls, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkKXSU24RUcjs.AssetMetadataProvider, { service, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, DepositStoreProvider, { store, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
10418
+ _chunkKXSU24RUcjs.Modal,
10452
10419
  {
10453
10420
  isOpen,
10454
10421
  onClose: handleModalDismiss,
@@ -10457,7 +10424,7 @@ function DepositModalInner({
10457
10424
  closeOnOverlayClick,
10458
10425
  ariaLabel: "Deposit",
10459
10426
  children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
10460
- _chunkCXRH5MKOcjs.AnalyticsSession,
10427
+ _chunkKXSU24RUcjs.AnalyticsSession,
10461
10428
  {
10462
10429
  modal: "deposit",
10463
10430
  sessionProperties: analyticsSessionProperties,
@@ -10484,7 +10451,7 @@ function DepositModalInner({
10484
10451
  ) }),
10485
10452
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "rs-modal-header-nav-right", children: [
10486
10453
  historyButtonVisible && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
10487
- _chunkCXRH5MKOcjs.HistoryEntryButton,
10454
+ _chunkKXSU24RUcjs.HistoryEntryButton,
10488
10455
  {
10489
10456
  badge: bankJourneyVisible ? null : history.badge,
10490
10457
  unread: bankHistory.unread,
@@ -10539,7 +10506,7 @@ function DepositModalInner({
10539
10506
  onDisconnect,
10540
10507
  onRequestConnect,
10541
10508
  uiConfig,
10542
- appFees: _optionalChain([clientSetup, 'optionalAccess', _383 => _383.appFees]),
10509
+ appFees: _optionalChain([clientSetup, 'optionalAccess', _385 => _385.appFees]),
10543
10510
  appFeesResolved: clientSetup !== null,
10544
10511
  onStepChange: handleStepChange,
10545
10512
  onSwappedImmersiveChange: setSwappedImmersive,
@@ -10553,11 +10520,11 @@ function DepositModalInner({
10553
10520
  }
10554
10521
  ),
10555
10522
  history.isPanelOpen && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
10556
- _chunkCXRH5MKOcjs.HistoryOverlay,
10523
+ _chunkKXSU24RUcjs.HistoryOverlay,
10557
10524
  {
10558
10525
  controller: history,
10559
10526
  bankHistory,
10560
- bankSupportUrl: _optionalChain([bankOnramp, 'optionalAccess', _384 => _384.supportUrl]),
10527
+ bankSupportUrl: _optionalChain([bankOnramp, 'optionalAccess', _386 => _386.supportUrl]),
10561
10528
  backLabel: "Deposit",
10562
10529
  recipient,
10563
10530
  backendUrl,