From ade063be971b09cae1f0232286d4cd1bb4ca6966 Mon Sep 17 00:00:00 2001 From: brave-builds Date: Mon, 5 Feb 2024 15:54:37 +0000 Subject: [PATCH 1/2] Uplift of #21894 (squashed) to release --- components/brave_wallet_ui/panel/container.tsx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/components/brave_wallet_ui/panel/container.tsx b/components/brave_wallet_ui/panel/container.tsx index 695f99c44313..fb326549d907 100644 --- a/components/brave_wallet_ui/panel/container.tsx +++ b/components/brave_wallet_ui/panel/container.tsx @@ -188,7 +188,10 @@ function Container() { if ( selectedAccount && - (selectedPendingTransaction || signMessageData.length) && + (selectedPendingTransaction || + signMessageData.length || + signAllTransactionsRequests.length || + signTransactionRequests.length) && selectedPanel === 'connectHardwareWallet' ) { return ( From 771b5d8198e3fa09a4231f4e8e6751bef1814b82 Mon Sep 17 00:00:00 2001 From: Anirudha Bose Date: Tue, 6 Feb 2024 19:52:12 +0530 Subject: [PATCH 2/2] Fix broken build --- components/brave_wallet_ui/panel/container.tsx | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/components/brave_wallet_ui/panel/container.tsx b/components/brave_wallet_ui/panel/container.tsx index fb326549d907..c922f7e4f3e2 100644 --- a/components/brave_wallet_ui/panel/container.tsx +++ b/components/brave_wallet_ui/panel/container.tsx @@ -114,6 +114,13 @@ function Container() { PanelSelectors.signMessageErrorData ) + const signTransactionRequests = useUnsafePanelSelector( + PanelSelectors.signTransactionRequests + ) + const signAllTransactionsRequests = useUnsafePanelSelector( + PanelSelectors.signAllTransactionsRequests + ) + // queries & mutations const { accounts } = useAccountsQuery() const { data: selectedAccount } = useSelectedAccountQuery() @@ -292,8 +299,10 @@ function Container() { } if ( - selectedPanel === 'signTransaction' || - selectedPanel === 'signAllTransactions' + (signAllTransactionsRequests.length > 0 || + signTransactionRequests.length > 0) && + (selectedPanel === 'signTransaction' || + selectedPanel === 'signAllTransactions') ) { return (