From d0e37b8c414661204c35a1db2b896a3f3f463c33 Mon Sep 17 00:00:00 2001 From: Christopher Serr Date: Mon, 14 Apr 2025 20:58:05 +0200 Subject: [PATCH] Fix Sidebar Not Refreshing in Splits Selection (#1050) When the splits selection view is open, the sidebar and the view itself don't refresh properly anymore when in mobile mode. This is because the React compiler notices that with the way we wrote the code, these components have no reason to re-render. There is currently no proper `useMobile` hook. So while I implemented a quick workaround here, by forcing it to not memoize the individual props properly, we should refactor the sidebar code at some point to use a proper `useMobile` hook. --- src/ui/views/SplitsSelection.tsx | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/src/ui/views/SplitsSelection.tsx b/src/ui/views/SplitsSelection.tsx index bd17bf9..71aedc4 100644 --- a/src/ui/views/SplitsSelection.tsx +++ b/src/ui/views/SplitsSelection.tsx @@ -99,13 +99,7 @@ export function SplitsSelection(props: Props) { }; return props.callbacks.renderViewWithSidebar( - , + ,