vn-verdnaturachat/app/containers/routes/AuthRoutes.js

60 lines
1.2 KiB
JavaScript
Raw Normal View History

import { Platform } from 'react-native';
import { StackNavigator, DrawerNavigator } from 'react-navigation';
import Sidebar from '../../containers/Sidebar';
import RoomsListView from '../../views/RoomsListView';
import RoomView from '../../views/RoomView';
import CreateChannelView from '../../views/CreateChannelView';
import SelectUsersView from '../../views/SelectUsersView';
import NewServerView from '../../views/NewServerView';
const AuthRoutes = StackNavigator(
{
RoomsList: {
screen: RoomsListView
},
Room: {
screen: RoomView
},
CreateChannel: {
screen: CreateChannelView,
navigationOptions: {
title: 'Create Channel'
}
},
SelectUsers: {
screen: SelectUsersView,
navigationOptions: {
title: 'Select Users'
}
},
AddServer: {
screen: NewServerView,
navigationOptions: {
title: 'New server'
}
}
},
2017-12-11 20:37:33 +00:00
{
navigationOptions: {
headerTitleAllowFontScaling: false
}
}
);
const Routes = DrawerNavigator(
{
Home: {
screen: AuthRoutes
}
},
{
contentComponent: Sidebar,
navigationOptions: {
drawerLockMode: Platform.OS === 'ios' ? 'locked-closed' : 'unlocked'
}
}
);
export default Routes;