From a27ec221cc8f26e599f74dad75a38a68e8d8fc08 Mon Sep 17 00:00:00 2001 From: James Mealy Date: Mon, 23 Sep 2024 11:11:20 +0200 Subject: [PATCH] fix: do not disable currently selected network in the network selector --- .../common/NetworkSelector/NetworkMultiSelector.tsx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/components/common/NetworkSelector/NetworkMultiSelector.tsx b/src/components/common/NetworkSelector/NetworkMultiSelector.tsx index 6cd39c69f3..22f0a666e1 100644 --- a/src/components/common/NetworkSelector/NetworkMultiSelector.tsx +++ b/src/components/common/NetworkSelector/NetworkMultiSelector.tsx @@ -67,8 +67,9 @@ const NetworkMultiSelector = ({ if (isAdvancedFlow) return optionNetwork.chainId != firstSelectedNetwork.chainId // Check required feature toggles + const optionIsSelectedNetwork = firstSelectedNetwork.chainId === optionNetwork.chainId if (!hasMultiChainCreationFeatures(optionNetwork) || !hasMultiChainCreationFeatures(firstSelectedNetwork)) { - return true + return !optionIsSelectedNetwork } // Check if required deployments are available @@ -88,7 +89,7 @@ const NetworkMultiSelector = ({ ) // Only 1.4.1 safes with canonical deployment addresses can be deployed as part of a multichain group - if (!selectedHasCanonicalSingletonDeployment) return firstSelectedNetwork.chainId !== optionNetwork.chainId + if (!selectedHasCanonicalSingletonDeployment) return !optionIsSelectedNetwork return !optionHasCanonicalSingletonDeployment }, [isAdvancedFlow, selectedNetworks],