mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-11-22 09:57:02 +01:00
UX: Multichain: Don't filter out custom mainnet RPCs (#19150)
This commit is contained in:
parent
556d3d82cc
commit
577e4cba0b
@ -120,7 +120,8 @@
|
||||
"networkConfigurations": {
|
||||
"testNetworkConfigurationId": {
|
||||
"rpcUrl": "https://testrpc.com",
|
||||
"chainId": "0x1"
|
||||
"chainId": "0x1",
|
||||
"nickname": "Custom Mainnet RPC"
|
||||
}
|
||||
},
|
||||
"keyrings": [
|
||||
|
@ -76,7 +76,7 @@ export const NetworkListMenu = ({ onClose }) => {
|
||||
>
|
||||
<>
|
||||
<Box className="multichain-network-list-menu" ref={networkListRef}>
|
||||
{networks.map((network) => {
|
||||
{networks.map((network, index) => {
|
||||
const isCurrentNetwork = currentChainId === network.chainId;
|
||||
const canDeleteNetwork =
|
||||
!isCurrentNetwork &&
|
||||
@ -86,7 +86,7 @@ export const NetworkListMenu = ({ onClose }) => {
|
||||
<NetworkListItem
|
||||
name={network.nickname}
|
||||
iconSrc={network?.rpcPrefs?.imageUrl}
|
||||
key={network.id || network.chainId}
|
||||
key={`${network.id || network.chainId}-${index}`}
|
||||
selected={isCurrentNetwork}
|
||||
onClick={async () => {
|
||||
dispatch(toggleNetworkMenu());
|
||||
|
@ -1189,7 +1189,6 @@ export function getAllNetworks(state) {
|
||||
({ chainId }) =>
|
||||
![
|
||||
CHAIN_IDS.LOCALHOST,
|
||||
CHAIN_IDS.MAINNET,
|
||||
// Linea gets added as a custom network configuration so
|
||||
// we must ignore it here to display in test networks
|
||||
CHAIN_IDS.LINEA_TESTNET,
|
||||
|
Loading…
Reference in New Issue
Block a user