@openfort/react 1.2.0 → 1.4.0

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 (146) hide show
  1. package/build/assets/logos.d.ts +3 -0
  2. package/build/assets/logos.js +2 -0
  3. package/build/assets/logos.js.map +1 -1
  4. package/build/components/Common/Modal/styles.js +3 -0
  5. package/build/components/Common/Modal/styles.js.map +1 -1
  6. package/build/components/Common/ScrollArea/index.d.ts +5 -1
  7. package/build/components/Common/ScrollArea/index.js +2 -2
  8. package/build/components/Common/ScrollArea/styles.d.ts +4 -1
  9. package/build/components/Common/ScrollArea/styles.js +19 -4
  10. package/build/components/Common/ScrollArea/styles.js.map +1 -1
  11. package/build/components/Common/SolanaChain/index.d.ts +8 -0
  12. package/build/components/Common/SolanaChain/index.js +40 -0
  13. package/build/components/Common/SolanaChain/index.js.map +1 -0
  14. package/build/components/ConnectModal/index.js +17 -5
  15. package/build/components/ConnectModal/index.js.map +1 -1
  16. package/build/components/Openfort/types.d.ts +17 -11
  17. package/build/components/Openfort/types.js +1 -0
  18. package/build/components/Openfort/types.js.map +1 -1
  19. package/build/components/PageContent/index.d.ts +2 -1
  20. package/build/components/PageContent/index.js +2 -2
  21. package/build/components/Pages/Buy/coinbaseApi.d.ts +1 -1
  22. package/build/components/Pages/Buy/coinbaseApi.js +2 -13
  23. package/build/components/Pages/Buy/coinbaseApi.js.map +1 -1
  24. package/build/components/Pages/Buy/evmCurrencies.d.ts +11 -0
  25. package/build/components/Pages/Buy/evmCurrencies.js +27 -0
  26. package/build/components/Pages/Buy/evmCurrencies.js.map +1 -0
  27. package/build/components/Pages/Buy/index.js +8 -1
  28. package/build/components/Pages/Buy/index.js.map +1 -1
  29. package/build/components/Pages/Buy/onrampApi.d.ts +8 -1
  30. package/build/components/Pages/Buy/onrampApi.js +24 -14
  31. package/build/components/Pages/Buy/onrampApi.js.map +1 -1
  32. package/build/components/Pages/Buy/solanaCurrencies.d.ts +9 -0
  33. package/build/components/Pages/Buy/solanaCurrencies.js +25 -0
  34. package/build/components/Pages/Buy/solanaCurrencies.js.map +1 -0
  35. package/build/components/Pages/Buy/stripeApi.d.ts +1 -1
  36. package/build/components/Pages/Buy/stripeApi.js +2 -13
  37. package/build/components/Pages/Buy/stripeApi.js.map +1 -1
  38. package/build/components/Pages/BuyComplete/index.js +7 -1
  39. package/build/components/Pages/BuyComplete/index.js.map +1 -1
  40. package/build/components/Pages/BuyProcessing/index.js +9 -5
  41. package/build/components/Pages/BuyProcessing/index.js.map +1 -1
  42. package/build/components/Pages/BuyProviderSelect/styles.d.ts +2 -1
  43. package/build/components/Pages/BuySelectProvider/index.js +10 -5
  44. package/build/components/Pages/BuySelectProvider/index.js.map +1 -1
  45. package/build/components/Pages/Connected/EthereumConnected.js +7 -3
  46. package/build/components/Pages/Connected/EthereumConnected.js.map +1 -1
  47. package/build/components/Pages/Connected/SolanaConnected.js +3 -2
  48. package/build/components/Pages/Connected/SolanaConnected.js.map +1 -1
  49. package/build/components/Pages/Deposit/AssetChainLogo.d.ts +5 -2
  50. package/build/components/Pages/Deposit/AssetChainLogo.js +21 -4
  51. package/build/components/Pages/Deposit/AssetChainLogo.js.map +1 -1
  52. package/build/components/Pages/Deposit/DepositAddressBlock.js +1 -1
  53. package/build/components/Pages/Deposit/DepositProgress.js +3 -2
  54. package/build/components/Pages/Deposit/DepositProgress.js.map +1 -1
  55. package/build/components/Pages/Deposit/DepositSuccess.js +2 -1
  56. package/build/components/Pages/Deposit/DepositSuccess.js.map +1 -1
  57. package/build/components/Pages/Deposit/RouteSelectors.js +11 -1
  58. package/build/components/Pages/Deposit/RouteSelectors.js.map +1 -1
  59. package/build/components/Pages/Deposit/SameChainDepositStatus.d.ts +7 -0
  60. package/build/components/Pages/Deposit/SameChainDepositStatus.js +34 -0
  61. package/build/components/Pages/Deposit/SameChainDepositStatus.js.map +1 -0
  62. package/build/components/Pages/Deposit/SameChainDepositSuccess.d.ts +11 -0
  63. package/build/components/Pages/Deposit/SameChainDepositSuccess.js +30 -0
  64. package/build/components/Pages/Deposit/SameChainDepositSuccess.js.map +1 -0
  65. package/build/components/Pages/Deposit/TestnetNotice.d.ts +10 -0
  66. package/build/components/Pages/Deposit/TestnetNotice.js +131 -0
  67. package/build/components/Pages/Deposit/TestnetNotice.js.map +1 -0
  68. package/build/components/Pages/Deposit/UnsupportedNetworkNotice.d.ts +12 -0
  69. package/build/components/Pages/Deposit/UnsupportedNetworkNotice.js +111 -0
  70. package/build/components/Pages/Deposit/UnsupportedNetworkNotice.js.map +1 -0
  71. package/build/components/Pages/Deposit/index.js +35 -5
  72. package/build/components/Pages/Deposit/index.js.map +1 -1
  73. package/build/components/Pages/Deposit/paymentOptions.d.ts +6 -0
  74. package/build/components/Pages/Deposit/paymentOptions.js +10 -4
  75. package/build/components/Pages/Deposit/paymentOptions.js.map +1 -1
  76. package/build/components/Pages/Deposit/useDepositRoute.d.ts +2 -1
  77. package/build/components/Pages/Deposit/useDepositRoute.js +36 -13
  78. package/build/components/Pages/Deposit/useDepositRoute.js.map +1 -1
  79. package/build/components/Pages/Deposit/useFundingTarget.d.ts +2 -4
  80. package/build/components/Pages/Deposit/useFundingTarget.js +3 -5
  81. package/build/components/Pages/Deposit/useFundingTarget.js.map +1 -1
  82. package/build/components/Pages/Deposit/useSameChainArrival.d.ts +19 -0
  83. package/build/components/Pages/Deposit/useSameChainArrival.js +86 -0
  84. package/build/components/Pages/Deposit/useSameChainArrival.js.map +1 -0
  85. package/build/components/Pages/DepositCex/index.js +7 -8
  86. package/build/components/Pages/DepositCex/index.js.map +1 -1
  87. package/build/components/Pages/DepositCrypto/index.js +26 -3
  88. package/build/components/Pages/DepositCrypto/index.js.map +1 -1
  89. package/build/components/Pages/DepositWallet/DepositWalletDesktop.d.ts +4 -1
  90. package/build/components/Pages/DepositWallet/DepositWalletDesktop.js +19 -27
  91. package/build/components/Pages/DepositWallet/DepositWalletDesktop.js.map +1 -1
  92. package/build/components/Pages/DepositWallet/index.d.ts +5 -5
  93. package/build/components/Pages/DepositWallet/index.js +82 -39
  94. package/build/components/Pages/DepositWallet/index.js.map +1 -1
  95. package/build/components/Pages/DepositWallet/walletDeeplinks.d.ts +6 -4
  96. package/build/components/Pages/DepositWallet/walletDeeplinks.js +3 -1
  97. package/build/components/Pages/DepositWallet/walletDeeplinks.js.map +1 -1
  98. package/build/components/Pages/SelectToken/SolanaSelectToken.d.ts +1 -0
  99. package/build/components/Pages/SelectToken/SolanaSelectToken.js +50 -0
  100. package/build/components/Pages/SelectToken/SolanaSelectToken.js.map +1 -0
  101. package/build/components/Pages/SelectToken/index.js +13 -2
  102. package/build/components/Pages/SelectToken/index.js.map +1 -1
  103. package/build/components/Pages/SelectToken/styles.d.ts +2 -1
  104. package/build/components/Pages/Send/SolanaSend.js +32 -31
  105. package/build/components/Pages/Send/SolanaSend.js.map +1 -1
  106. package/build/components/Pages/Send/utils.js +4 -1
  107. package/build/components/Pages/Send/utils.js.map +1 -1
  108. package/build/components/Pages/SendConfirmation/SolanaSendConfirmation.js +57 -13
  109. package/build/components/Pages/SendConfirmation/SolanaSendConfirmation.js.map +1 -1
  110. package/build/components/Pages/SendConfirmation/index.js +1 -1
  111. package/build/components/Pages/SendConfirmation/styles.d.ts +0 -5
  112. package/build/components/Pages/SendConfirmation/styles.js +1 -39
  113. package/build/components/Pages/SendConfirmation/styles.js.map +1 -1
  114. package/build/constants/chainConfigs.js +32 -32
  115. package/build/constants/logos.d.ts +4 -0
  116. package/build/constants/logos.js +25 -1
  117. package/build/constants/logos.js.map +1 -1
  118. package/build/ethereum/hooks/useEthereumWalletAssets.js +39 -3
  119. package/build/ethereum/hooks/useEthereumWalletAssets.js.map +1 -1
  120. package/build/hooks/openfort/useFunding.js +7 -7
  121. package/build/hooks/openfort/useFundingChains.d.ts +6 -0
  122. package/build/hooks/openfort/useFundingChains.js +22 -10
  123. package/build/hooks/openfort/useFundingChains.js.map +1 -1
  124. package/build/shared/hooks/useAsyncData.js +15 -2
  125. package/build/shared/hooks/useAsyncData.js.map +1 -1
  126. package/build/shared/utils/explorer.js +6 -4
  127. package/build/shared/utils/explorer.js.map +1 -1
  128. package/build/solana/transfer.d.ts +35 -6
  129. package/build/solana/transfer.js +112 -18
  130. package/build/solana/transfer.js.map +1 -1
  131. package/build/solana/types.d.ts +8 -0
  132. package/build/utils/validation.d.ts +9 -0
  133. package/build/utils/validation.js +14 -1
  134. package/build/utils/validation.js.map +1 -1
  135. package/build/version.d.ts +1 -1
  136. package/build/version.js +1 -1
  137. package/build/wagmi/components/ChainSelect/index.js +3 -2
  138. package/build/wagmi/components/ChainSelect/index.js.map +1 -1
  139. package/build/wagmi/components/ChainSelectList/index.js +3 -2
  140. package/build/wagmi/components/ChainSelectList/index.js.map +1 -1
  141. package/build/wagmi/components/SwitchNetworks/index.js +3 -2
  142. package/build/wagmi/components/SwitchNetworks/index.js.map +1 -1
  143. package/build/wagmi/useSwitchChainFiltered.d.ts +199 -0
  144. package/build/wagmi/useSwitchChainFiltered.js +53 -0
  145. package/build/wagmi/useSwitchChainFiltered.js.map +1 -0
  146. package/package.json +5 -1
@@ -1,11 +1,15 @@
1
1
  import { jsxs, jsx } from 'react/jsx-runtime';
2
+ import { ChainTypeEnum } from '@openfort/openfort-js';
2
3
  import { useState, useEffect } from 'react';
3
4
  import { formatUnits } from 'viem';
4
5
  import { useEthereumWalletAssets } from '../../../ethereum/hooks/useEthereumWalletAssets.js';
6
+ import { useOpenfortCore } from '../../../openfort/useOpenfort.js';
5
7
  import { Arrow, ArrowChevron, TextLinkButton } from '../../Common/Button/styles.js';
6
8
  import { ModalHeading } from '../../Common/Modal/styles.js';
7
9
  import { routes } from '../../Openfort/types.js';
8
10
  import { useOpenfort } from '../../Openfort/useOpenfort.js';
11
+ import { EVM_BUY_CURRENCIES } from '../Buy/evmCurrencies.js';
12
+ import { SOLANA_BUY_CURRENCIES } from '../Buy/solanaCurrencies.js';
9
13
  import { getAssetSymbol, getAssetDecimals, formatBalanceWithSymbol } from '../Send/utils.js';
10
14
  import { SelectTokenContent, EmptyState, TokenList, TokenButton, TokenInfo, TokenSymbol, TokenName, TokenBalance } from './styles.js';
11
15
 
@@ -22,9 +26,16 @@ const SelectToken = ({ isBuyFlow }) => {
22
26
  useEffect(() => {
23
27
  triggerResize();
24
28
  }, [viewAllAssets]);
29
+ const { chainType } = useOpenfortCore();
25
30
  const { data: walletAssets, isLoading: isBalancesLoading } = useEthereumWalletAssets();
26
- // Show all tokens for both buy and send flows
27
- const selectableTokens = walletAssets || [];
31
+ // Buys pick from a fixed buyable-currency list (USDC first, then native) per
32
+ // chain family, so the picker always has options even for a fresh wallet with no
33
+ // indexed balances. The send flow reads the EVM wallet's actual assets.
34
+ const selectableTokens = isBuyFlow
35
+ ? chainType === ChainTypeEnum.SVM
36
+ ? SOLANA_BUY_CURRENCIES
37
+ : EVM_BUY_CURRENCIES
38
+ : walletAssets || [];
28
39
  const handleSelect = (asset) => {
29
40
  var _a;
30
41
  // In send flow, don't allow selecting tokens with 0 balance
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,9 +1,10 @@
1
- export declare const SelectTokenContent: import("styled-components").StyledComponent<({ children, width, onBack, logoutOnBack, header }: {
1
+ export declare const SelectTokenContent: import("styled-components").StyledComponent<({ children, width, onBack, logoutOnBack, header, className, }: {
2
2
  children?: React.ReactNode;
3
3
  width?: number | string;
4
4
  onBack?: import("../../PageContent").SetOnBackFunction;
5
5
  logoutOnBack?: boolean;
6
6
  header?: string;
7
+ className?: string;
7
8
  }) => import("react/jsx-runtime").JSX.Element, any, {}, never>;
8
9
  export declare const TokenList: import("styled-components").StyledComponent<"div", any, {}, never>;
9
10
  export declare const TokenButton: import("styled-components").StyledComponent<"button", any, {}, never>;
@@ -1,16 +1,15 @@
1
1
  import { jsxs, jsx } from 'react/jsx-runtime';
2
2
  import { useMemo } from 'react';
3
3
  import { parseUnits, formatUnits } from 'viem';
4
- import { fetchSolanaBalance } from '../../../hooks/useBalance.js';
5
- import { useAsyncData } from '../../../shared/hooks/useAsyncData.js';
6
- import { useSolanaEmbeddedWallet } from '../../../solana/hooks/useSolanaEmbeddedWallet.js';
4
+ import { useSolanaWalletAssets } from '../../../solana/hooks/useSolanaWalletAssets.js';
7
5
  import Button from '../../Common/Button/index.js';
6
+ import { Arrow, ArrowChevron } from '../../Common/Button/styles.js';
8
7
  import Input from '../../Common/Input/index.js';
9
8
  import { ModalHeading } from '../../Common/Modal/styles.js';
10
9
  import { routes } from '../../Openfort/types.js';
11
10
  import { useOpenfort } from '../../Openfort/useOpenfort.js';
12
11
  import { PageContent } from '../../PageContent/index.js';
13
- import { Form, Field, FieldLabel, AmountInputWrapper, MaxButton, HelperText, ErrorText } from './styles.js';
12
+ import { Form, Field, FieldLabel, TokenSelectorButton, TokenSelectorContent, TokenSelectorValue, TokenSelectorRight, AmountInputWrapper, MaxButton, HelperText, ErrorText } from './styles.js';
14
13
  import { sanitizeForParsing, formatBalance, sanitizeAmountInput } from './utils.js';
15
14
 
16
15
  const SOL_DECIMALS = 9;
@@ -18,39 +17,40 @@ const SOL_DECIMALS = 9;
18
17
  function isLikelySolanaAddress(value) {
19
18
  return /^[1-9A-HJ-NP-Za-km-z]{32,44}$/.test(value);
20
19
  }
20
+ /** A native SOL asset with the canonical metadata (the default form asset has none). */
21
+ function solAsset(balance) {
22
+ return {
23
+ type: 'native',
24
+ balance,
25
+ metadata: { symbol: 'SOL', decimals: SOL_DECIMALS, fiat: { value: 0, currency: 'USD' } },
26
+ };
27
+ }
21
28
  const SolanaSend = () => {
22
- var _a;
23
29
  const { sendForm, setSendForm, setRoute } = useOpenfort();
24
- const wallet = useSolanaEmbeddedWallet();
25
- const address = wallet.status === 'connected' ? wallet.address : undefined;
26
- const rpcUrl = wallet.rpcUrl;
27
- const balanceResult = useAsyncData({
28
- queryKey: ['solana-balance', address, rpcUrl],
29
- queryFn: async () => {
30
- if (!address || !rpcUrl)
31
- return null;
32
- const { value } = await fetchSolanaBalance(address, rpcUrl, 'confirmed');
33
- return value;
34
- },
35
- enabled: Boolean(address && rpcUrl),
36
- });
37
- const balanceLamports = (_a = balanceResult.data) !== null && _a !== void 0 ? _a : undefined;
30
+ const { data: assets } = useSolanaWalletAssets();
31
+ const asset = sendForm.asset;
32
+ const selected = asset.type === 'spl'
33
+ ? { isSpl: true, mint: asset.address, decimals: asset.metadata.decimals, symbol: asset.metadata.symbol }
34
+ : { isSpl: false, mint: 'native', decimals: SOL_DECIMALS, symbol: 'SOL' };
35
+ // Live balance (base units) for the selected token, matched by mint.
36
+ const liveToken = assets === null || assets === void 0 ? void 0 : assets.find((t) => (selected.isSpl ? t.mint === selected.mint : t.isNative));
37
+ const balanceBase = liveToken === null || liveToken === void 0 ? void 0 : liveToken.amount;
38
38
  const parsedAmount = useMemo(() => {
39
39
  const raw = sanitizeForParsing(sendForm.amount);
40
40
  if (!raw)
41
41
  return null;
42
42
  try {
43
- return parseUnits(raw, SOL_DECIMALS);
43
+ return parseUnits(raw, selected.decimals);
44
44
  }
45
45
  catch {
46
46
  return null;
47
47
  }
48
- }, [sendForm.amount]);
48
+ }, [sendForm.amount, selected.decimals]);
49
49
  const recipientValid = isLikelySolanaAddress(sendForm.recipient.trim());
50
- const insufficientBalance = parsedAmount !== null && balanceLamports !== undefined ? parsedAmount > balanceLamports : false;
50
+ const insufficientBalance = parsedAmount !== null && balanceBase !== undefined ? parsedAmount > balanceBase : false;
51
51
  const amountValid = parsedAmount !== null && parsedAmount > BigInt(0) && !insufficientBalance;
52
52
  const canProceed = recipientValid && amountValid;
53
- const availableLabel = formatBalance(balanceLamports, SOL_DECIMALS);
53
+ const availableLabel = formatBalance(balanceBase, selected.decimals);
54
54
  const handleSubmit = (event) => {
55
55
  event.preventDefault();
56
56
  if (!canProceed)
@@ -58,15 +58,15 @@ const SolanaSend = () => {
58
58
  const normalized = sanitizeForParsing(sendForm.amount);
59
59
  if (!normalized)
60
60
  return;
61
+ // Persist the selected token with its live balance so the confirmation reads it.
62
+ const nextAsset = asset.type === 'spl'
63
+ ? { type: 'spl', address: asset.address, balance: balanceBase !== null && balanceBase !== void 0 ? balanceBase : asset.balance, metadata: asset.metadata }
64
+ : solAsset(balanceBase !== null && balanceBase !== void 0 ? balanceBase : BigInt(0));
61
65
  setSendForm((prev) => ({
62
66
  ...prev,
63
67
  recipient: prev.recipient.trim(),
64
68
  amount: normalized,
65
- asset: {
66
- type: 'native',
67
- balance: balanceLamports !== null && balanceLamports !== void 0 ? balanceLamports : BigInt(0),
68
- metadata: { symbol: 'SOL', decimals: SOL_DECIMALS, fiat: { value: 0, currency: 'USD' } },
69
- },
69
+ asset: nextAsset,
70
70
  }));
71
71
  setRoute(routes.SOL_SEND_CONFIRMATION);
72
72
  };
@@ -77,11 +77,12 @@ const SolanaSend = () => {
77
77
  }
78
78
  };
79
79
  const handleMax = () => {
80
- if (balanceLamports === undefined)
80
+ if (balanceBase === undefined)
81
81
  return;
82
- setSendForm((prev) => ({ ...prev, amount: formatUnits(balanceLamports, SOL_DECIMALS) }));
82
+ setSendForm((prev) => ({ ...prev, amount: formatUnits(balanceBase, selected.decimals) }));
83
83
  };
84
- return (jsxs(PageContent, { onBack: routes.SOL_CONNECTED, children: [jsx(ModalHeading, { children: "Send SOL" }), jsxs(Form, { onSubmit: handleSubmit, children: [jsxs(Field, { children: [jsx(FieldLabel, { children: "Amount" }), jsxs(AmountInputWrapper, { children: [jsx(Input, { placeholder: "0.00", value: sendForm.amount, onChange: handleAmountChange, inputMode: "decimal", autoComplete: "off", style: { paddingRight: '86px' } }), jsx(MaxButton, { type: "button", onClick: handleMax, disabled: balanceLamports === undefined, children: "Max" })] }), jsxs(HelperText, { children: ["Available: ", availableLabel, " SOL"] }), sendForm.amount && parsedAmount === null && jsx(ErrorText, { children: "Enter a valid amount." }), insufficientBalance && jsx(ErrorText, { children: "Insufficient SOL balance for this transfer." })] }), jsxs(Field, { children: [jsx(FieldLabel, { children: "Recipient address" }), jsx(Input, { placeholder: "Solana address", value: sendForm.recipient, onChange: (e) => setSendForm((prev) => ({ ...prev, recipient: e.target.value })), autoComplete: "off" }), sendForm.recipient && !recipientValid && jsx(ErrorText, { children: "Enter a valid Solana address." })] }), jsx(Button, { variant: "primary", disabled: !canProceed, children: "Review transfer" })] })] }));
84
+ const handleOpenTokenSelector = () => setRoute(routes.SOL_SEND_TOKEN_SELECT);
85
+ return (jsxs(PageContent, { onBack: routes.SOL_CONNECTED, children: [jsx(ModalHeading, { children: "Send assets" }), jsxs(Form, { onSubmit: handleSubmit, children: [jsxs(Field, { children: [jsx(FieldLabel, { children: "Asset" }), jsxs(TokenSelectorButton, { type: "button", onClick: handleOpenTokenSelector, children: [jsx(TokenSelectorContent, { children: jsx(TokenSelectorValue, { "$primary": true, children: selected.symbol }) }), jsxs(TokenSelectorRight, { children: [jsx(TokenSelectorValue, { children: availableLabel === '--' ? '--' : `${availableLabel} ${selected.symbol}` }), jsx(Arrow, { width: "13", height: "12", viewBox: "0 0 13 12", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: jsx(ArrowChevron, { stroke: "currentColor", d: "M7.51431 1.5L11.757 5.74264M7.5 10.4858L11.7426 6.24314", strokeWidth: "2", strokeLinecap: "round" }) })] })] })] }), jsxs(Field, { children: [jsx(FieldLabel, { children: "Amount" }), jsxs(AmountInputWrapper, { children: [jsx(Input, { placeholder: "0.00", value: sendForm.amount, onChange: handleAmountChange, inputMode: "decimal", autoComplete: "off", style: { paddingRight: '86px' } }), jsx(MaxButton, { type: "button", onClick: handleMax, disabled: balanceBase === undefined, children: "Max" })] }), jsxs(HelperText, { children: ["Available: ", availableLabel, " ", selected.symbol] }), sendForm.amount && parsedAmount === null && jsx(ErrorText, { children: "Enter a valid amount." }), insufficientBalance && jsxs(ErrorText, { children: ["Insufficient ", selected.symbol, " balance for this transfer."] })] }), jsxs(Field, { children: [jsx(FieldLabel, { children: "Recipient address" }), jsx(Input, { placeholder: "Solana address", value: sendForm.recipient, onChange: (e) => setSendForm((prev) => ({ ...prev, recipient: e.target.value })), autoComplete: "off" }), sendForm.recipient && !recipientValid && jsx(ErrorText, { children: "Enter a valid Solana address." })] }), jsx(Button, { variant: "primary", disabled: !canProceed, children: "Review transfer" })] })] }));
85
86
  };
86
87
 
87
88
  export { SolanaSend };
@@ -1 +1 @@
1
- {"version":3,"file":"SolanaSend.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"SolanaSend.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -44,10 +44,13 @@ const isSameToken = (a, b) => {
44
44
  return false;
45
45
  if (a.type === 'native')
46
46
  return true;
47
- // At this point, a.type === 'erc20' and b.type === 'erc20'
48
47
  if (a.type === 'erc20' && b.type === 'erc20') {
49
48
  return a.address.toLowerCase() === b.address.toLowerCase();
50
49
  }
50
+ // SPL mints are base58 and case-sensitive — compare verbatim.
51
+ if (a.type === 'spl' && b.type === 'spl') {
52
+ return a.address === b.address;
53
+ }
51
54
  return false;
52
55
  };
53
56
  const getAssetSymbol = (asset) => {
@@ -1 +1 @@
1
- {"version":3,"file":"utils.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"utils.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,9 +1,10 @@
1
1
  import { jsxs, jsx } from 'react/jsx-runtime';
2
2
  import { ChainTypeEnum } from '@openfort/openfort-js';
3
3
  import { useState, useEffect } from 'react';
4
+ import { parseUnits } from 'viem';
4
5
  import { getExplorerUrl } from '../../../shared/utils/explorer.js';
5
6
  import { useSolanaEmbeddedWallet } from '../../../solana/hooks/useSolanaEmbeddedWallet.js';
6
- import { sendSolGasless, sendSol } from '../../../solana/transfer.js';
7
+ import { sendSplTokenGasless, sendSplToken, sendSolGasless, sendSol } from '../../../solana/transfer.js';
7
8
  import 'detect-browser';
8
9
  import { truncateSolanaAddress } from '../../../utils/format.js';
9
10
  import Button from '../../Common/Button/index.js';
@@ -13,11 +14,12 @@ import { ModalHeading, ModalBody } from '../../Common/Modal/styles.js';
13
14
  import { routes } from '../../Openfort/types.js';
14
15
  import { useOpenfort } from '../../Openfort/useOpenfort.js';
15
16
  import { PageContent } from '../../PageContent/index.js';
16
- import { ButtonRow, SummaryList, SummaryItem, SummaryLabel, AmountValue, AddressValue, GaslessRow, GaslessToggle, ErrorContainer, ErrorTitle, ErrorMessage } from './styles.js';
17
+ import { ButtonRow, SummaryList, SummaryItem, SummaryLabel, AmountValue, AddressValue, FeesValue, ErrorContainer, ErrorTitle, ErrorMessage } from './styles.js';
17
18
 
19
+ const SOL_DECIMALS = 9;
18
20
  const SolanaSendConfirmation = () => {
19
- var _a;
20
- const { sendForm, setRoute, publishableKey, triggerResize } = useOpenfort();
21
+ var _a, _b;
22
+ const { sendForm, setRoute, publishableKey, triggerResize, walletConfig } = useOpenfort();
21
23
  const wallet = useSolanaEmbeddedWallet();
22
24
  const address = wallet.status === 'connected' ? wallet.address : undefined;
23
25
  const provider = wallet.status === 'connected' ? wallet.provider : undefined;
@@ -25,7 +27,11 @@ const SolanaSendConfirmation = () => {
25
27
  const rpcUrl = wallet.rpcUrl;
26
28
  const recipient = sendForm.recipient;
27
29
  const amount = sendForm.amount;
28
- const [gasless, setGasless] = useState(false);
30
+ const asset = sendForm.asset;
31
+ const symbol = asset.type === 'spl' ? asset.metadata.symbol : 'SOL';
32
+ const decimals = asset.type === 'spl' ? asset.metadata.decimals : SOL_DECIMALS;
33
+ // Fees are sponsored from config (the SVM counterpart of ethereumFeeSponsorshipId).
34
+ const isSponsored = Boolean((_b = walletConfig === null || walletConfig === void 0 ? void 0 : walletConfig.solana) === null || _b === void 0 ? void 0 : _b.sponsorFees);
29
35
  const [isLoading, setIsLoading] = useState(false);
30
36
  const [signature, setSignature] = useState(null);
31
37
  const [error, setError] = useState(null);
@@ -37,21 +43,59 @@ const SolanaSendConfirmation = () => {
37
43
  const handleConfirm = async () => {
38
44
  if (!address || !provider || isLoading)
39
45
  return;
40
- const amountSol = Number(amount);
41
- if (!Number.isFinite(amountSol) || amountSol <= 0) {
46
+ // The Send screen validates these before navigating here; re-guard in case
47
+ // this page is reached directly with an unvalidated form.
48
+ if (!recipient.trim()) {
49
+ setError('Enter a recipient address.');
50
+ return;
51
+ }
52
+ const amountNum = Number(amount);
53
+ if (!Number.isFinite(amountNum) || amountNum <= 0) {
42
54
  setError('Enter a valid amount.');
43
55
  return;
44
56
  }
45
- if (!gasless && !rpcUrl) {
57
+ if (!isSponsored && !rpcUrl) {
46
58
  setError('No Solana RPC is configured for this network.');
47
59
  return;
48
60
  }
49
61
  setIsLoading(true);
50
62
  setError(null);
51
63
  try {
52
- const sig = gasless
53
- ? await sendSolGasless({ from: address, to: recipient, amountSol, provider, cluster, publishableKey })
54
- : await sendSol({ from: address, to: recipient, amountSol, provider, rpcUrl: rpcUrl !== null && rpcUrl !== void 0 ? rpcUrl : '' });
64
+ let sig;
65
+ if (asset.type === 'spl') {
66
+ const baseUnits = parseUnits(amount, decimals);
67
+ sig = isSponsored
68
+ ? await sendSplTokenGasless({
69
+ from: address,
70
+ to: recipient,
71
+ mint: asset.address,
72
+ amount: baseUnits,
73
+ provider,
74
+ cluster,
75
+ publishableKey,
76
+ })
77
+ : await sendSplToken({
78
+ from: address,
79
+ to: recipient,
80
+ mint: asset.address,
81
+ amount: baseUnits,
82
+ decimals,
83
+ provider,
84
+ rpcUrl: rpcUrl !== null && rpcUrl !== void 0 ? rpcUrl : '',
85
+ });
86
+ }
87
+ else {
88
+ sig = isSponsored
89
+ ? await sendSolGasless({
90
+ from: address,
91
+ to: recipient,
92
+ amountSol: amountNum,
93
+ provider,
94
+ cluster,
95
+ publishableKey,
96
+ })
97
+ : await sendSol({ from: address, to: recipient, amountSol: amountNum, provider, rpcUrl: rpcUrl !== null && rpcUrl !== void 0 ? rpcUrl : '' });
98
+ }
55
99
  setSignature(sig);
56
100
  }
57
101
  catch (err) {
@@ -68,9 +112,9 @@ const SolanaSendConfirmation = () => {
68
112
  window.open(getExplorerUrl(ChainTypeEnum.SVM, { txHash: signature, cluster }), '_blank', 'noopener,noreferrer');
69
113
  };
70
114
  if (signature) {
71
- return (jsxs(PageContent, { children: [jsx(Loader, { isSuccess: true, header: "Transfer sent", description: `${amount} SOL sent successfully` }), jsxs(ButtonRow, { children: [jsx(Button, { variant: "primary", onClick: handleViewExplorer, children: "View on Explorer" }), jsx(Button, { variant: "secondary", onClick: handleFinish, children: "Back to profile" })] })] }));
115
+ return (jsxs(PageContent, { children: [jsx(Loader, { isSuccess: true, header: "Transfer sent", description: `${amount} ${symbol} sent successfully` }), jsxs(ButtonRow, { children: [jsx(Button, { variant: "primary", onClick: handleViewExplorer, children: "View on Explorer" }), jsx(Button, { variant: "secondary", onClick: handleFinish, children: "Back to profile" })] })] }));
72
116
  }
73
- return (jsxs(PageContent, { onBack: routes.SOL_SEND, children: [jsx(ModalHeading, { children: "Confirm transfer" }), jsx(ModalBody, { children: "Review the transaction details before sending." }), jsxs(SummaryList, { children: [jsxs(SummaryItem, { children: [jsx(SummaryLabel, { children: "Sending" }), jsxs(AmountValue, { children: [amount || '0', " SOL"] })] }), jsxs(SummaryItem, { children: [jsx(SummaryLabel, { children: "From" }), jsx(AddressValue, { children: address ? (jsx(CopyText, { size: "1rem", value: address, children: truncateSolanaAddress(address) })) : ('--') })] }), jsxs(SummaryItem, { children: [jsx(SummaryLabel, { children: "To" }), jsx(AddressValue, { children: recipient ? (jsx(CopyText, { size: "1rem", value: recipient, children: truncateSolanaAddress(recipient) })) : ('--') })] })] }), jsxs(GaslessRow, { children: [jsxs("div", { children: [jsx(SummaryLabel, { children: "Sponsor network fee" }), jsx("div", { style: { fontSize: 12, color: 'var(--ck-body-color-muted)', marginTop: 2 }, children: "Pay no SOL fee (requires a sponsorship policy)" })] }), jsx(GaslessToggle, { type: "button", role: "switch", "aria-checked": gasless, "aria-label": "Sponsor network fee", "$on": gasless, onClick: () => setGasless((v) => !v), disabled: isLoading, children: jsx("span", {}) })] }), error && (jsxs(ErrorContainer, { children: [jsx(ErrorTitle, { children: "Transaction failed" }), jsx(ErrorMessage, { children: error })] })), jsxs(ButtonRow, { children: [jsx(Button, { variant: "primary", onClick: handleConfirm, disabled: !address || isLoading, waiting: isLoading, children: isLoading ? 'Confirming...' : 'Confirm' }), jsx(Button, { variant: "secondary", onClick: () => setRoute(routes.SOL_SEND), disabled: isLoading, children: "Cancel" })] })] }));
117
+ return (jsxs(PageContent, { onBack: routes.SOL_SEND, children: [jsx(ModalHeading, { children: "Confirm transfer" }), jsx(ModalBody, { children: "Review the transaction details before sending." }), jsxs(SummaryList, { children: [jsxs(SummaryItem, { children: [jsx(SummaryLabel, { children: "Sending" }), jsxs(AmountValue, { children: [amount || '0', " ", symbol] })] }), jsxs(SummaryItem, { children: [jsx(SummaryLabel, { children: "From" }), jsx(AddressValue, { children: address ? (jsx(CopyText, { size: "1rem", value: address, children: truncateSolanaAddress(address) })) : ('--') })] }), jsxs(SummaryItem, { children: [jsx(SummaryLabel, { children: "To" }), jsx(AddressValue, { children: recipient ? (jsx(CopyText, { size: "1rem", value: recipient, children: truncateSolanaAddress(recipient) })) : ('--') })] }), isSponsored && (jsxs(SummaryItem, { children: [jsx(SummaryLabel, { children: "Network fee" }), jsx(FeesValue, { "$completed": true, children: "Sponsored" })] }))] }), error && (jsxs(ErrorContainer, { children: [jsx(ErrorTitle, { children: "Transaction failed" }), jsx(ErrorMessage, { children: error })] })), jsxs(ButtonRow, { children: [jsx(Button, { variant: "primary", onClick: handleConfirm, disabled: !address || isLoading, waiting: isLoading, children: isLoading ? 'Confirming...' : 'Confirm' }), jsx(Button, { variant: "secondary", onClick: () => setRoute(routes.SOL_SEND), disabled: isLoading, children: "Cancel" })] })] }));
74
118
  };
75
119
 
76
120
  export { SolanaSendConfirmation };
@@ -1 +1 @@
1
- {"version":3,"file":"SolanaSendConfirmation.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"SolanaSendConfirmation.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -329,7 +329,7 @@ const SendConfirmation = () => {
329
329
  if (isSuccess) {
330
330
  const successAmount = normalisedAmount || '0';
331
331
  const successSymbol = getAssetSymbol(token);
332
- return (jsxs(PageContent, { children: [jsx(Loader, { isSuccess: true, header: "Transfer Sent", description: `${successAmount} ${successSymbol} sent successfully` }), jsxs(ButtonRow, { children: [jsx(Button, { variant: "primary", onClick: handleOpenBlockExplorer, children: "View on Explorer" }), jsx(Button, { variant: "secondary", onClick: handleFinish, children: "Back to profile" })] })] }));
332
+ return (jsxs(PageContent, { children: [jsx(Loader, { isSuccess: true, header: "Transfer Sent", description: `${successAmount} ${successSymbol} sent successfully` }), jsxs(ButtonRow, { children: [blockExplorerUrl && (jsx(Button, { variant: "primary", onClick: handleOpenBlockExplorer, children: "View on Explorer" })), jsx(Button, { variant: "secondary", onClick: handleFinish, children: "Back to profile" })] })] }));
333
333
  }
334
334
  return (jsxs(PageContent, { children: [jsx(ModalHeading, { children: "Confirm transfer" }), jsx(ModalBody, { children: "Review the transaction details before sending." }), jsxs(SummaryList, { children: [jsxs(SummaryItem, { children: [jsx(SummaryLabel, { children: "Sending" }), jsxs(AmountValue, { children: [normalisedAmount || '0', " ", getAssetSymbol(token)] })] }), jsxs(SummaryItem, { children: [jsx(SummaryLabel, { children: "From" }), jsx(AddressValue, { children: address ? (jsx(CopyText, { size: "1rem", value: address, children: truncateEthAddress(address) })) : ('--') })] }), jsxs(SummaryItem, { children: [jsx(SummaryLabel, { children: "To" }), jsx(AddressValue, { children: recipientAddress ? (jsx(CopyText, { size: "1rem", value: recipientAddress, children: truncateEthAddress(recipientAddress) })) : ('--') })] }), jsxs("div", { children: [jsxs(SummaryItem, { children: [jsx(SummaryLabel, { children: "Estimated fees" }), jsxs(FeesValue, { "$completed": isSponsored, children: [jsx(EstimatedFees, { account: address, to: token.type === 'erc20' ? token.address : recipientAddress, value: token.type === 'native' && parsedAmount ? parsedAmount : undefined, data: transferData, chainId: chainId, nativeSymbol: nativeSymbol, enabled: Boolean(address && recipientAddress && parsedAmount && parsedAmount > BigInt(0)), hideInfoIcon: isSponsored }), jsx(CheckIconWrapper, { children: jsx(TickIcon, {}) })] })] }), isSponsored && (jsx("div", { style: {
335
335
  textAlign: 'end',
@@ -16,8 +16,3 @@ export declare const ErrorContainer: import("styled-components").StyledComponent
16
16
  export declare const ErrorTitle: import("styled-components").StyledComponent<"div", any, {}, never>;
17
17
  export declare const ErrorMessage: import("styled-components").StyledComponent<"div", any, {}, never>;
18
18
  export declare const ErrorAction: import("styled-components").StyledComponent<"div", any, {}, never>;
19
- export declare const GaslessRow: import("styled-components").StyledComponent<"div", any, {}, never>;
20
- /** A minimal theme-aware switch for the Solana "sponsor fee" toggle. */
21
- export declare const GaslessToggle: import("styled-components").StyledComponent<"button", any, {
22
- $on?: boolean;
23
- }, never>;
@@ -124,44 +124,6 @@ const ErrorAction = styled.div `
124
124
  color: var(--ck-body-color-muted);
125
125
  line-height: 1.4;
126
126
  `;
127
- const GaslessRow = styled.div `
128
- display: flex;
129
- align-items: center;
130
- justify-content: space-between;
131
- gap: 12px;
132
- margin: 4px 0 8px;
133
- text-align: left;
134
- `;
135
- /** A minimal theme-aware switch for the Solana "sponsor fee" toggle. */
136
- const GaslessToggle = styled.button `
137
- position: relative;
138
- flex-shrink: 0;
139
- width: 40px;
140
- height: 24px;
141
- border-radius: 999px;
142
- border: 1px solid var(--ck-body-divider);
143
- background: ${(props) => (props.$on ? 'var(--ck-body-color-valid, #22c55e)' : 'var(--ck-body-background-secondary)')};
144
- cursor: pointer;
145
- transition: background 150ms ease;
146
- padding: 0;
147
-
148
- &:disabled {
149
- opacity: 0.5;
150
- cursor: not-allowed;
151
- }
152
-
153
- > span {
154
- position: absolute;
155
- top: 50%;
156
- left: ${(props) => (props.$on ? '18px' : '2px')};
157
- transform: translateY(-50%);
158
- width: 18px;
159
- height: 18px;
160
- border-radius: 50%;
161
- background: #fff;
162
- transition: left 150ms ease;
163
- }
164
- `;
165
127
 
166
- export { AddressValue, AmountValue, ButtonRow, CheckIconWrapper, ErrorAction, ErrorContainer, ErrorMessage, ErrorTitle, FeesValue, GaslessRow, GaslessToggle, InfoIconWrapper, StatusMessage, SummaryItem, SummaryLabel, SummaryList };
128
+ export { AddressValue, AmountValue, ButtonRow, CheckIconWrapper, ErrorAction, ErrorContainer, ErrorMessage, ErrorTitle, FeesValue, InfoIconWrapper, StatusMessage, SummaryItem, SummaryLabel, SummaryList };
167
129
  //# sourceMappingURL=styles.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"styles.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"styles.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -27,28 +27,28 @@ const chainConfigs = [
27
27
  {
28
28
  id: 37111,
29
29
  name: 'Lens Chain Testnet',
30
- logo: jsx(ChainIcons.LensChain, { testnet: true }),
30
+ logo: jsx(ChainIcons.LensChain, {}),
31
31
  },
32
32
  {
33
33
  id: 3,
34
34
  name: 'Rinkeby',
35
- logo: jsx(ChainIcons.Ethereum, { testnet: true }),
35
+ logo: jsx(ChainIcons.Ethereum, {}),
36
36
  rpcUrls: {},
37
37
  },
38
38
  {
39
39
  id: 4,
40
40
  name: 'Ropsten',
41
- logo: jsx(ChainIcons.Ethereum, { testnet: true }),
41
+ logo: jsx(ChainIcons.Ethereum, {}),
42
42
  },
43
43
  {
44
44
  id: 5,
45
45
  name: 'Görli',
46
- logo: jsx(ChainIcons.Ethereum, { testnet: true }),
46
+ logo: jsx(ChainIcons.Ethereum, {}),
47
47
  },
48
48
  {
49
49
  id: 42,
50
50
  name: 'Kovan',
51
- logo: jsx(ChainIcons.Ethereum, { testnet: true }),
51
+ logo: jsx(ChainIcons.Ethereum, {}),
52
52
  },
53
53
  {
54
54
  id: 10,
@@ -58,17 +58,17 @@ const chainConfigs = [
58
58
  {
59
59
  id: 69, // nice
60
60
  name: 'Optimism Kovan',
61
- logo: jsx(ChainIcons.Optimism, { testnet: true }),
61
+ logo: jsx(ChainIcons.Optimism, {}),
62
62
  },
63
63
  {
64
64
  id: 420, // nice
65
65
  name: 'Optimism Goerli',
66
- logo: jsx(ChainIcons.Optimism, { testnet: true }),
66
+ logo: jsx(ChainIcons.Optimism, {}),
67
67
  },
68
68
  {
69
69
  id: 11155420,
70
70
  name: 'Optimism Sepolia',
71
- logo: jsx(ChainIcons.Optimism, { testnet: true }),
71
+ logo: jsx(ChainIcons.Optimism, {}),
72
72
  },
73
73
  {
74
74
  id: 137,
@@ -78,27 +78,27 @@ const chainConfigs = [
78
78
  {
79
79
  id: 80001,
80
80
  name: 'Polygon Mumbai',
81
- logo: jsx(ChainIcons.Polygon, { testnet: true }),
81
+ logo: jsx(ChainIcons.Polygon, {}),
82
82
  },
83
83
  {
84
84
  id: 80002,
85
85
  name: 'Polygon Amoy',
86
- logo: jsx(ChainIcons.Polygon, { testnet: true }),
86
+ logo: jsx(ChainIcons.Polygon, {}),
87
87
  },
88
88
  {
89
89
  id: 13337,
90
90
  name: 'Beam Testnet',
91
- logo: jsx(ChainIcons.Avalanche, { testnet: true }),
91
+ logo: jsx(ChainIcons.Avalanche, {}),
92
92
  },
93
93
  {
94
94
  id: 31337,
95
95
  name: 'Hardhat',
96
- logo: jsx(ChainIcons.Ethereum, { testnet: true }),
96
+ logo: jsx(ChainIcons.Ethereum, {}),
97
97
  },
98
98
  {
99
99
  id: 1337,
100
100
  name: 'Localhost',
101
- logo: jsx(ChainIcons.Ethereum, { testnet: true }),
101
+ logo: jsx(ChainIcons.Ethereum, {}),
102
102
  },
103
103
  {
104
104
  id: 42161,
@@ -118,12 +118,12 @@ const chainConfigs = [
118
118
  {
119
119
  id: 421611,
120
120
  name: 'Arbitrum Rinkeby',
121
- logo: jsx(ChainIcons.Arbitrum, { testnet: true }),
121
+ logo: jsx(ChainIcons.Arbitrum, {}),
122
122
  },
123
123
  {
124
124
  id: 421613,
125
125
  name: 'Arbitrum Goerli',
126
- logo: jsx(ChainIcons.Arbitrum, { testnet: true }),
126
+ logo: jsx(ChainIcons.Arbitrum, {}),
127
127
  rpcUrls: {
128
128
  alchemy: {
129
129
  http: ['https://arb-goerli.g.alchemy.com/v2'],
@@ -143,7 +143,7 @@ const chainConfigs = [
143
143
  {
144
144
  id: 41,
145
145
  name: 'Telos Testnet',
146
- logo: jsx(ChainIcons.Telos, { testnet: true }),
146
+ logo: jsx(ChainIcons.Telos, {}),
147
147
  },
148
148
  {
149
149
  id: 1313161554,
@@ -153,7 +153,7 @@ const chainConfigs = [
153
153
  {
154
154
  id: 1313161555,
155
155
  name: 'Aurora Testnet',
156
- logo: jsx(ChainIcons.Aurora, { testnet: true }),
156
+ logo: jsx(ChainIcons.Aurora, {}),
157
157
  },
158
158
  {
159
159
  id: 43114,
@@ -163,12 +163,12 @@ const chainConfigs = [
163
163
  {
164
164
  id: 43113,
165
165
  name: 'Avalanche Fuji',
166
- logo: jsx(ChainIcons.Avalanche, { testnet: true }),
166
+ logo: jsx(ChainIcons.Avalanche, {}),
167
167
  },
168
168
  {
169
169
  id: 31337,
170
170
  name: 'Foundry',
171
- logo: jsx(ChainIcons.Foundry, { testnet: true }),
171
+ logo: jsx(ChainIcons.Foundry, {}),
172
172
  },
173
173
  {
174
174
  id: 100,
@@ -183,7 +183,7 @@ const chainConfigs = [
183
183
  {
184
184
  id: 9000,
185
185
  name: 'Evmos Testnet',
186
- logo: jsx(ChainIcons.Evmos, { testnet: true }),
186
+ logo: jsx(ChainIcons.Evmos, {}),
187
187
  },
188
188
  {
189
189
  id: 56,
@@ -193,7 +193,7 @@ const chainConfigs = [
193
193
  {
194
194
  id: 97,
195
195
  name: 'Binance Smart Chain Testnet',
196
- logo: jsx(ChainIcons.BinanceSmartChain, { testnet: true }),
196
+ logo: jsx(ChainIcons.BinanceSmartChain, {}),
197
197
  },
198
198
  {
199
199
  id: 11155111,
@@ -208,7 +208,7 @@ const chainConfigs = [
208
208
  {
209
209
  id: 842,
210
210
  name: 'Taraxa Testnet',
211
- logo: jsx(ChainIcons.Taraxa, { testnet: true }),
211
+ logo: jsx(ChainIcons.Taraxa, {}),
212
212
  },
213
213
  {
214
214
  id: 324,
@@ -218,7 +218,7 @@ const chainConfigs = [
218
218
  {
219
219
  id: 280,
220
220
  name: 'zkSync Testnet',
221
- logo: jsx(ChainIcons.zkSync, { testnet: true }),
221
+ logo: jsx(ChainIcons.zkSync, {}),
222
222
  },
223
223
  {
224
224
  id: 42220,
@@ -228,7 +228,7 @@ const chainConfigs = [
228
228
  {
229
229
  id: 44787,
230
230
  name: 'Celo Alfajores',
231
- logo: jsx(ChainIcons.Celo, { testnet: true }),
231
+ logo: jsx(ChainIcons.Celo, {}),
232
232
  },
233
233
  {
234
234
  id: 7700,
@@ -253,12 +253,12 @@ const chainConfigs = [
253
253
  {
254
254
  id: 3141,
255
255
  name: 'Filecoin Hyperspace',
256
- logo: jsx(ChainIcons.Filecoin, { testnet: true }),
256
+ logo: jsx(ChainIcons.Filecoin, {}),
257
257
  },
258
258
  {
259
259
  id: 314159,
260
260
  name: 'Filecoin Calibration',
261
- logo: jsx(ChainIcons.Filecoin, { testnet: true }),
261
+ logo: jsx(ChainIcons.Filecoin, {}),
262
262
  },
263
263
  {
264
264
  id: 1088,
@@ -268,7 +268,7 @@ const chainConfigs = [
268
268
  {
269
269
  id: 599,
270
270
  name: 'Metis Goerli',
271
- logo: jsx(ChainIcons.Metis, { testnet: true }),
271
+ logo: jsx(ChainIcons.Metis, {}),
272
272
  },
273
273
  {
274
274
  id: 4689,
@@ -278,7 +278,7 @@ const chainConfigs = [
278
278
  {
279
279
  id: 4690,
280
280
  name: 'IoTeX Testnet',
281
- logo: jsx(ChainIcons.IoTeX, { testnet: true }),
281
+ logo: jsx(ChainIcons.IoTeX, {}),
282
282
  },
283
283
  {
284
284
  id: 8453,
@@ -288,12 +288,12 @@ const chainConfigs = [
288
288
  {
289
289
  id: 84531,
290
290
  name: 'Base Goerli',
291
- logo: jsx(ChainIcons.Base, { testnet: true }),
291
+ logo: jsx(ChainIcons.Base, {}),
292
292
  },
293
293
  {
294
294
  id: 84532,
295
295
  name: 'Base Sepolia',
296
- logo: jsx(ChainIcons.Base, { testnet: true }),
296
+ logo: jsx(ChainIcons.Base, {}),
297
297
  },
298
298
  {
299
299
  id: 7777777,
@@ -303,12 +303,12 @@ const chainConfigs = [
303
303
  {
304
304
  id: 999999999,
305
305
  name: 'Zora Sepolia',
306
- logo: jsx(ChainIcons.Zora, { testnet: true }),
306
+ logo: jsx(ChainIcons.Zora, {}),
307
307
  },
308
308
  {
309
309
  id: 999,
310
310
  name: 'Zora Goerli Testnet',
311
- logo: jsx(ChainIcons.Zora, { testnet: true }),
311
+ logo: jsx(ChainIcons.Zora, {}),
312
312
  },
313
313
  ];
314
314