From 1a15ff4589b3ab2b1049622194d9f730fe3616aa Mon Sep 17 00:00:00 2001 From: Yohan Simard Date: Sun, 8 Mar 2020 11:17:47 +0100 Subject: [PATCH] Grayed out tab icons when unfocused --- navigation/MainTabNavigator.js | 3 ++- utils/ThemeManager.js | 5 +++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/navigation/MainTabNavigator.js b/navigation/MainTabNavigator.js index 468f12b..a3705e1 100644 --- a/navigation/MainTabNavigator.js +++ b/navigation/MainTabNavigator.js @@ -208,7 +208,8 @@ function TabNavigator(props) { let icon = TAB_ICONS[route.name]; // tintColor is ignoring activeColor and inactiveColor for some reason icon = focused ? icon : icon + ('-outline'); - return ; + let iconColor = focused ? colors.tabIconFocused : colors.tabIcon; + return ; }, })} > diff --git a/utils/ThemeManager.js b/utils/ThemeManager.js index 72105b9..1c2a754 100644 --- a/utils/ThemeManager.js +++ b/utils/ThemeManager.js @@ -22,6 +22,8 @@ export default class ThemeManager { ...DefaultTheme.colors, primary: '#be1522', accent: '#be1522', + tabIcon: "#929292", + tabIconFocused: "#000000", card: "rgb(255, 255, 255)", dividerBackground: '#e2e2e2', textDisabled: '#c1c1c1', @@ -59,6 +61,9 @@ export default class ThemeManager { ...DarkTheme.colors, primary: '#be1522', accent: '#be1522', + tabBackground: "#181818", + tabIcon: "#6d6d6d", + tabIconFocused: "#ffffff", card: "rgb(18, 18, 18)", dividerBackground: '#222222', textDisabled: '#5b5b5b',