mirror of
https://github.com/austinried/subtracks.git
synced 2025-12-27 09:09:29 +01:00
fix tab labels
This commit is contained in:
parent
c58f860520
commit
d486fb9782
@ -93,7 +93,7 @@ const BottomTabBar: React.FC<BottomTabBarProps> = ({ state, descriptors, navigat
|
||||
label={label}
|
||||
name={route.name}
|
||||
isFocused={state.index === index}
|
||||
img={icons[options.icon]}
|
||||
img={icons[route.name]}
|
||||
navigation={navigation}
|
||||
/>
|
||||
)
|
||||
|
||||
@ -107,10 +107,10 @@ const Tab = createBottomTabNavigator()
|
||||
const BottomTabNavigator = () => {
|
||||
return (
|
||||
<Tab.Navigator tabBar={BottomTabBar} initialRouteName="home">
|
||||
<Tab.Screen name="home" component={HomeTab} options={{ icon: 'home' } as any} />
|
||||
<Tab.Screen name="library" component={LibraryTab} options={{ icon: 'library' } as any} />
|
||||
<Tab.Screen name="search" component={SearchTab} options={{ icon: 'search' } as any} />
|
||||
<Tab.Screen name="settings" component={SettingsView} options={{ icon: 'settings' } as any} />
|
||||
<Tab.Screen name="home" component={HomeTab} options={{ tabBarLabel: 'Home' }} />
|
||||
<Tab.Screen name="library" component={LibraryTab} options={{ tabBarLabel: 'Library' }} />
|
||||
<Tab.Screen name="search" component={SearchTab} options={{ tabBarLabel: 'Search' }} />
|
||||
<Tab.Screen name="settings" component={SettingsView} options={{ tabBarLabel: 'Settings' }} />
|
||||
</Tab.Navigator>
|
||||
)
|
||||
}
|
||||
|
||||
@ -18,9 +18,9 @@ const LibraryTopTabNavigator = () => (
|
||||
indicatorStyle: styles.tabindicatorStyle,
|
||||
}}
|
||||
initialRouteName="albums">
|
||||
<Tab.Screen name="albums" component={AlbumsTab} />
|
||||
<Tab.Screen name="artists" component={ArtistsTab} />
|
||||
<Tab.Screen name="playlists" component={PlaylistsTab} />
|
||||
<Tab.Screen name="albums" component={AlbumsTab} options={{ tabBarLabel: 'Albums' }} />
|
||||
<Tab.Screen name="artists" component={ArtistsTab} options={{ tabBarLabel: 'Artists' }} />
|
||||
<Tab.Screen name="playlists" component={PlaylistsTab} options={{ tabBarLabel: 'Playlists' }} />
|
||||
</Tab.Navigator>
|
||||
)
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user