mirror of
https://github.com/zhigang1992/react-navigation.git
synced 2026-02-09 09:13:32 +08:00
29 lines
849 B
TypeScript
29 lines
849 B
TypeScript
import React from 'react';
|
|
import { MaterialIcons } from '@expo/vector-icons';
|
|
import { createDrawerNavigator } from 'react-navigation-drawer';
|
|
import SimpleTabs from './SimpleTabs';
|
|
import StacksOverTabs from './StacksOverTabs';
|
|
|
|
const TabsInDrawer = createDrawerNavigator({
|
|
SimpleTabs: {
|
|
navigationOptions: {
|
|
drawerIcon: ({ tintColor }: { tintColor: string }) => (
|
|
<MaterialIcons name="filter-1" size={24} style={{ color: tintColor }} />
|
|
),
|
|
drawerLabel: 'Simple tabs',
|
|
},
|
|
screen: SimpleTabs,
|
|
},
|
|
StacksOverTabs: {
|
|
navigationOptions: {
|
|
drawerIcon: ({ tintColor }: { tintColor: string }) => (
|
|
<MaterialIcons name="filter-2" size={24} style={{ color: tintColor }} />
|
|
),
|
|
drawerLabel: 'Stacks Over Tabs',
|
|
},
|
|
screen: StacksOverTabs,
|
|
},
|
|
});
|
|
|
|
export default TabsInDrawer;
|