From 1b0eb31bd94fcbb52019d355fd062581fe974675 Mon Sep 17 00:00:00 2001 From: Luke De Feo Date: Thu, 26 Oct 2023 05:24:30 -0700 Subject: [PATCH] Default to first tab if active tab not available Summary: This is only really an issue in theUIDebugger where we have a dynamic number of tabs. on some nodes you have 3 tabs, on others you have 2. if you select the 3rd tab and move to a node with 2 tabs nothing will be selected. With this fix we will fallback to the first tab Reviewed By: lblasa Differential Revision: D50595977 fbshipit-source-id: 25c36a5609f774c2d3fd650eb6520104864fbe95 --- desktop/flipper-plugin/src/ui/Tabs.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/desktop/flipper-plugin/src/ui/Tabs.tsx b/desktop/flipper-plugin/src/ui/Tabs.tsx index 46f88e880..53c77ddb8 100644 --- a/desktop/flipper-plugin/src/ui/Tabs.tsx +++ b/desktop/flipper-plugin/src/ui/Tabs.tsx @@ -59,7 +59,7 @@ export function Tabs({ return ( { setActiveTab(key); }}