diff --git a/CHANGELOG.md b/CHANGELOG.md index b9de3e2225b..22ea1d47399 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,8 @@ ## Unreleased (develop) +- changed: Append chain names to token codes in RampCreateScene + ## 4.42.0 (staging) - added: Zcash buy/sell support with Banxa diff --git a/src/components/scenes/RampCreateScene.tsx b/src/components/scenes/RampCreateScene.tsx index 8ecaf81f58f..fed4a86f85e 100644 --- a/src/components/scenes/RampCreateScene.tsx +++ b/src/components/scenes/RampCreateScene.tsx @@ -138,19 +138,18 @@ export const RampCreateScene: React.FC = (props: Props) => { ] : [undefined, undefined] - // Append chain name for L2-native assets like Optimism ETH + // Append chain name for tokens and L2-native assets like Optimism ETH function getSelectedCryptoDisplay(): string | undefined { if (selectedCrypto == null) return if (selectedWallet == null) return if (selectedCryptoCurrencyCode == null) return - const isL2Native = - selectedCrypto.tokenId == null && - !isAssetNativeToChain(selectedWallet.currencyInfo, undefined) - - return isL2Native - ? `${selectedCryptoCurrencyCode} (${selectedWallet.currencyInfo.displayName})` - : selectedCryptoCurrencyCode + return isAssetNativeToChain( + selectedWallet.currencyInfo, + selectedCrypto.tokenId + ) + ? selectedCryptoCurrencyCode + : `${selectedCryptoCurrencyCode} (${selectedWallet.currencyInfo.displayName})` } // Get the select crypto denomination for exchange rate