From e85c8477a23ae5479ed99e8140f0d18e73ae93f0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oskar=20Kwas=CC=81niewski?= Date: Fri, 8 Nov 2024 09:13:30 +0100 Subject: [PATCH] fix: hide routes with opacity 0 for Android --- src/TabView.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/TabView.tsx b/src/TabView.tsx index 37792fff..9d14c8b0 100644 --- a/src/TabView.tsx +++ b/src/TabView.tsx @@ -271,6 +271,7 @@ const TabView = ({ } const focused = route.key === focusedKey; + const opacity = focused ? 1 : 0; const zIndex = focused ? 0 : -1; return ( @@ -282,7 +283,7 @@ const TabView = ({ importantForAccessibility={focused ? 'auto' : 'no-hide-descendants'} style={ Platform.OS === 'android' - ? [StyleSheet.absoluteFill, { zIndex }] + ? [StyleSheet.absoluteFill, { zIndex, opacity }] : styles.fullWidth } >