diff --git a/App.js b/App.js index 9718d3ac..61c17abb 100644 --- a/App.js +++ b/App.js @@ -1,12 +1,5 @@ import './shim.js'; -import React from 'react'; -import PropTypes from 'prop-types'; -import { Text, ScrollView, StyleSheet } from 'react-native'; -import { createDrawerNavigator, SafeAreaView } from 'react-navigation'; import MainBottomTabs from './MainBottomTabs'; -import Selftest from './screen/selftest'; -import About from './screen/settings/about'; -import PlausibleDeniability from './screen/plausibledeniability'; import Sentry from 'sentry-expo'; Sentry.config('https://23377936131848ca8003448a893cb622@sentry.io/1295736').install(); @@ -18,70 +11,4 @@ if (!Error.captureStackTrace) { Error.captureStackTrace = () => {}; } -const pkg = require('./package.json'); -const appjson = require('./app.json'); - -// - -const CustomDrawerContentComponent = props => ( - - - props.navigation.navigate('About')} style={styles.heading}> - {' '} - {pkg.name} v{pkg.version} (build {appjson.expo.ios.buildNumber}) - - - -); - -CustomDrawerContentComponent.propTypes = { - navigation: PropTypes.shape({ - navigate: PropTypes.func, - }), -}; - -const styles = StyleSheet.create({ - container: { - marginTop: 20, - flex: 1, - }, - heading: { - textAlign: 'center', - color: 'black', - fontWeight: 'bold', - fontSize: 20, - }, -}); - -const TabsInDrawer = createDrawerNavigator( - { - MainBottomTabs: { - screen: MainBottomTabs, - navigationOptions: { - drawer: () => ({ - label: 'Tabs', - }), - }, - }, - Selftest: { - screen: Selftest, - navigationOptions: {}, - }, - About: { - screen: About, - navigationOptions: {}, - }, - PlausibleDeniability: { - screen: PlausibleDeniability, - navigationOptions: {}, - }, - }, - { - contentComponent: CustomDrawerContentComponent, - drawerOpenRoute: 'DrawerOpen', - drawerCloseRoute: 'DrawerClose', - drawerToggleRoute: 'DrawerToggle', - }, -); - -export default TabsInDrawer; +export default MainBottomTabs; diff --git a/screen/settings/about.js b/screen/settings/about.js index e4a934df..a1ba2e53 100644 --- a/screen/settings/about.js +++ b/screen/settings/about.js @@ -15,7 +15,9 @@ import PropTypes from 'prop-types'; /** @type {AppStorage} */ let BlueApp = require('../../BlueApp'); const { width, height } = Dimensions.get('window'); -let loc = require('../../loc/'); +const loc = require('../../loc/'); +const pkg = require('../../package.json'); +const appjson = require('../../app.json'); export default class About extends Component { static navigationOptions = () => ({ @@ -45,7 +47,7 @@ export default class About extends Component { - BlueWallet is free and opensource Bitcoin wallet. Licensed MIT. + BlueWallet is a free and open source Bitcoin wallet. Licensed MIT. {Constants.platform.ios.model} ({Constants.platform.ios.platform}) + + + + {pkg.name} v{pkg.version} (build {appjson.expo.ios.buildNumber}) +