How can I change the background color of tab bar item when the screen is focused. I am using react-navigation
version 6.x. Here is my code snippet for the bottom bar
<NavigationContainer>
<Tab.Navigator
initialRouteName="Main"
activeColor={colors.yellow}
inactiveColor={colors.white}>
<Tab.Screen
name="Main"
component={Main}
options={{
tabBarIcon: ({color}) => (
<Icon name="home" color={color} size={26} />
),
}}
/>
<Tab.Screen
name="Countries"
component={Countries}
options={{
tabBarIcon: ({color}) => (
<Icon name="ios-globe" color={color} size={26} />
),
}}
/>
<Tab.Screen name="GlobalCasesScreen" component={GlobalCasesScreen} />
</Tab.Navigator>
</NavigationContainer>