This repository has been archived by the owner on Feb 8, 2020. It is now read-only.
generated from satya164/typescript-template
-
Notifications
You must be signed in to change notification settings - Fork 41
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add integration for paper's bottom navigation
- Loading branch information
Showing
9 changed files
with
169 additions
and
127 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
import * as React from 'react'; | ||
import { StyleSheet } from 'react-native'; | ||
import createMaterialBottomTabNavigator from '@navigation-ex/material-bottom-tabs'; | ||
import Article from '../Shared/Article'; | ||
import Albums from '../Shared/Albums'; | ||
import Contacts from '../Shared/Contacts'; | ||
import Chat from '../Shared/Chat'; | ||
|
||
type MaterialBottomTabParams = { | ||
article: undefined; | ||
albums: undefined; | ||
contacts: undefined; | ||
chat: undefined; | ||
}; | ||
|
||
const MaterialBottomTabs = createMaterialBottomTabNavigator< | ||
MaterialBottomTabParams | ||
>(); | ||
|
||
export default function MaterialBottomTabsScreen() { | ||
return ( | ||
<MaterialBottomTabs.Navigator barStyle={styles.tabBar}> | ||
<MaterialBottomTabs.Screen | ||
name="article" | ||
component={Article} | ||
options={{ | ||
tabBarLabel: 'Article', | ||
tabBarIcon: 'chrome-reader-mode', | ||
tabBarColor: '#C9E7F8', | ||
}} | ||
/> | ||
<MaterialBottomTabs.Screen | ||
name="chat" | ||
component={Chat} | ||
options={{ | ||
tabBarLabel: 'Chat', | ||
tabBarIcon: 'chat-bubble', | ||
tabBarColor: '#9FD5C9', | ||
tabBarBadge: true, | ||
}} | ||
/> | ||
<MaterialBottomTabs.Screen | ||
name="contacts" | ||
component={Contacts} | ||
options={{ | ||
tabBarLabel: 'Contacts', | ||
tabBarIcon: 'contacts', | ||
tabBarColor: '#F7EAA2', | ||
}} | ||
/> | ||
<MaterialBottomTabs.Screen | ||
name="albums" | ||
component={Albums} | ||
options={{ | ||
tabBarLabel: 'Albums', | ||
tabBarIcon: 'photo-album', | ||
tabBarColor: '#FAD4D6', | ||
}} | ||
/> | ||
</MaterialBottomTabs.Navigator> | ||
); | ||
} | ||
|
||
const styles = StyleSheet.create({ | ||
tabBar: { | ||
backgroundColor: 'white', | ||
}, | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.