React-native-navigation: [Android]: Tab Bar color not working

Created on 15 May 2018  路  2Comments  路  Source: wix/react-native-navigation

Issue Description

Styling the tab bar does not work on Android even though the docs state these should work cross platform, which leads me to believe there is something missing in my code.

Steps to Reproduce / Code Snippets / Screenshots

export const Colors = {
  Yellow: '#f7ca02',
  ButtonGrey: '#cdcdcd',
  White: '#ffffff',
  Black: '#000000',
  Blue: '#3755b0'
}
  Navigation.startTabBasedApp({
    animationType: 'fade',
    tabs: [
      {
        screen: Screens.Dispatches,
        icon: Icons.TabBar.Dispatches,
        label: 'Dispatches',
        title: 'Dispatches'
      },
      {
        screen: Screens.History,
        icon: Icons.TabBar.History,
        label: 'History',
        title: 'History'
      },
      {
        screen: Screens.Account,
        icon: Icons.TabBar.Account,
        label: 'Account',
        title: 'Account'
      }
    ],
    tabsStyle: {
      tabBarLabelColor: Colors.White,
      tabBarButtonColor: Colors.White,
      tabBarSelectedLabelColor: Colors.Yellow,
      tabBarSelectedButtonColor: Colors.Yellow,
      tabBarBackgroundColor: Colors.Black
    }
  })

iOS:
img_1337

Android:
screenshot_20180515-131948


Environment

  • React Native Navigation version: 1.1.458
  • React Native version: 0.55
  • Platform(s) (iOS, Android, or both?): Both
  • Device info (Simulator/Device? OS version? Debug/Release?): iPhone X vs Samsung Galaxy S7 Edge (both real devices)

Most helpful comment

Due to historical reasons, BottomTabs style on Android should be declared in appStyle
https://wix.github.io/react-native-navigation/#/styling-the-tab-bar

All 2 comments

Due to historical reasons, BottomTabs style on Android should be declared in appStyle
https://wix.github.io/react-native-navigation/#/styling-the-tab-bar

Due to historical reasons, BottomTabs style on Android should be declared in appStyle
https://wix.github.io/react-native-navigation/#/styling-the-tab-bar

Thank you very much. it is working in android correctly

Was this page helpful?
0 / 5 - 0 ratings

Related issues

tmaly1980 picture tmaly1980  路  3Comments

birkir picture birkir  路  3Comments

viper4595 picture viper4595  路  3Comments

nbolender picture nbolender  路  3Comments

zhanguangao picture zhanguangao  路  3Comments