We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
@gorhom : I am using the following boilerplate, the NavigationContainer is already defined at the app level as you can see.
This code I am using inside a containers, this is an example of container:
import React, { useState, useEffect } from 'react'; import { View, StyleSheet, Text } from 'react-native'; const Home = () => { return ( <View> <Text>Home</Text> </View> ); }; const Profile = () => { return ( <View> <Text>Home</Text> </View> ); }; import { createBottomTabNavigator } from '@react-navigation/bottom-tabs'; import AnimatedTabBar, { TabsConfig, BubbleTabConfig, } from '@gorhom/animated-tabbar'; const Tab = createBottomTabNavigator(); const tabs = { Home: { labelStyle: { color: '#5B37B7', }, icon: { activeColor: 'rgba(91,55,183,1)', inactiveColor: 'rgba(0,0,0,1)', }, background: { activeColor: 'rgba(223,215,243,1)', inactiveColor: 'rgba(223,215,243,0)', }, }, Profile: { labelStyle: { color: '#1194AA', }, icon: { activeColor: 'rgba(17,148,170,1)', inactiveColor: 'rgba(0,0,0,1)', }, background: { activeColor: 'rgba(207,235,239,1)', inactiveColor: 'rgba(207,235,239,0)', }, }, }; const styles = StyleSheet.create({ container: { flex: 1, justifyContent: 'center', alignItems: 'center', backgroundColor: '#999', }, tabBarContainer: { borderRadius: 25, }, }); const IndexHomeContainer = (props) => { return ( <Tab.Navigator tabBar={(props) => ( <AnimatedTabBar iconSize={20} tabs={tabs} {...props} /> )}> <Tab.Screen name="Home" initialParams={{ backgroundColor: tabs.Home.labelStyle.color, nextScreen: 'Likes', }} component={Home} /> <Tab.Screen name="Profile" initialParams={{ backgroundColor: tabs.Profile.labelStyle.color, nextScreen: 'Home', }} component={Profile} /> </Tab.Navigator> ); }; export default IndexHomeContainer;
The text was updated successfully, but these errors were encountered:
hi @Angelk90 , you need to provide icon.component ⚠️
icon.component
Sorry, something went wrong.
No branches or pull requests
Bug
Environment info
Reproducible sample code
@gorhom : I am using the following boilerplate, the NavigationContainer is already defined at the app level as you can see.
This code I am using inside a containers, this is an example of container:
The text was updated successfully, but these errors were encountered: