mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-10-05 15:27:05 +00:00
Merge pull request #29981 from JKillian/horizontal_info
add horizontal prop to tabBarIcon option in NavigationTabScreenOptionsBase
This commit is contained in:
Vendored
+3
-2
@@ -1,4 +1,4 @@
|
||||
// Type definitions for react-navigation 2.0
|
||||
// Type definitions for react-navigation 2.13
|
||||
// Project: https://github.com/react-navigation/react-navigation
|
||||
// Definitions by: Huhuanming <https://github.com/huhuanming>
|
||||
// mhcgrq <https://github.com/mhcgrq>
|
||||
@@ -25,6 +25,7 @@
|
||||
// Denis Frezzato <https://github.com/DenisFrezzato>
|
||||
// Mickael Wegerich <https://github.com/mickaelw>
|
||||
// Max Davidson <https://github.com/maxdavidson>
|
||||
// Jason Killian <https://github.com/jkillian>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 2.8
|
||||
|
||||
@@ -518,7 +519,7 @@ interface NavigationTabScreenOptionsBase {
|
||||
tabBarIcon?:
|
||||
| React.ReactElement<any>
|
||||
| ((
|
||||
options: { tintColor: string | null; focused: boolean }
|
||||
options: { tintColor: string | null; focused: boolean; horizontal: boolean }
|
||||
) => React.ReactElement<any> | null);
|
||||
tabBarLabel?:
|
||||
| string
|
||||
|
||||
@@ -179,7 +179,8 @@ const tabNavigatorConfig: TabNavigatorConfig = {
|
||||
tabBarComponent: TabBarTop,
|
||||
tabBarOptions: { activeBackgroundColor: "blue" },
|
||||
navigationOptions: () => ({
|
||||
tabBarOnPress: ({ scene, jumpToIndex }) => jumpToIndex(scene.index)
|
||||
tabBarOnPress: ({ scene, jumpToIndex }) => jumpToIndex(scene.index),
|
||||
tabBarIcon: ({ horizontal }) => <View />,
|
||||
})
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user