diff --git a/App.js b/App.js
index 5f60e71..a95f7f8 100644
--- a/App.js
+++ b/App.js
@@ -1,6 +1,6 @@
import React from 'react';
import {Dimensions, StyleSheet, View, Text} from 'react-native';
-import {StyleProvider} from 'native-base';
+import {StyleProvider, Root} from 'native-base';
import AppNavigator from './navigation/AppNavigator';
import ThemeManager from './utils/ThemeManager';
import LocaleManager from './utils/LocaleManager';
@@ -48,7 +48,9 @@ export default class App extends React.Component {
// console.log(this.state.currentTheme.variables.containerBgColor);
return (
-
+
+
+
);
}
}
diff --git a/components/CustomHeader.js b/components/CustomHeader.js
index b1f2174..2c6c1ed 100644
--- a/components/CustomHeader.js
+++ b/components/CustomHeader.js
@@ -2,23 +2,48 @@ import React from "react";
import {Body, Button, Header, Icon, Left, Right, Title} from "native-base";
import {StyleSheet} from "react-native";
import {getStatusBarHeight} from "react-native-status-bar-height";
+import Touchable from 'react-native-platform-touchable';
+
export default class CustomHeader extends React.Component {
render() {
+ let button;
+ let rightMenu;
+ if (this.props.backButton !== undefined && this.props.backButton === true)
+ button =
+ this.props.navigation.goBack()}>
+
+ ;
+ else
+ button =
+ this.props.navigation.toggleDrawer()}>
+
+ ;
+
+ if (this.props.rightMenu)
+ rightMenu = this.props.rightMenu;
+ else
+ rightMenu = ;
+
return (
-
+ {button}
{this.props.title}
-
+ {rightMenu}
);
}
};
@@ -30,4 +55,4 @@ const styles = StyleSheet.create({
paddingTop: getStatusBarHeight(),
height: 54 + getStatusBarHeight(),
},
-});
\ No newline at end of file
+});
diff --git a/components/SideMenu.js b/components/SideMenu.js
index 4cff317..eecdfb6 100644
--- a/components/SideMenu.js
+++ b/components/SideMenu.js
@@ -1,7 +1,6 @@
import React from 'react';
-import {Platform, Dimensions, ScrollView, StyleSheet, View, Image, FlatList} from 'react-native';
-import {Drawer} from 'react-native-paper';
-import {Badge, Text, Container, Content, Icon, Left, List, ListItem, Right} from "native-base";
+import {Platform, Dimensions, StyleSheet, Image, FlatList} from 'react-native';
+import {Badge, Text, Container, Content, Icon, Left, ListItem, Right} from "native-base";
import i18n from "i18n-js";
const deviceHeight = Dimensions.get("window").height;
diff --git a/navigation/AppNavigator.js b/navigation/AppNavigator.js
index e01d704..2fb9d45 100644
--- a/navigation/AppNavigator.js
+++ b/navigation/AppNavigator.js
@@ -1,9 +1,17 @@
-import { createAppContainer, createSwitchNavigator } from 'react-navigation';
+import {createAppContainer, createStackNavigator} from 'react-navigation';
import MainDrawerNavigator from './MainDrawerNavigator';
+import ProximoListScreen from '../screens/Proximo/ProximoListScreen';
+
export default createAppContainer(
- createSwitchNavigator({
- Main: MainDrawerNavigator,
- })
-);
\ No newline at end of file
+ createStackNavigator({
+ Main: MainDrawerNavigator,
+ ProximoListScreen: {screen: ProximoListScreen},
+ },
+ {
+ initialRouteName: "Main",
+ mode: 'card',
+ headerMode: "none"
+ })
+);
diff --git a/navigation/MainDrawerNavigator.js b/navigation/MainDrawerNavigator.js
index a27059a..d3cd95e 100644
--- a/navigation/MainDrawerNavigator.js
+++ b/navigation/MainDrawerNavigator.js
@@ -4,7 +4,7 @@ import {createDrawerNavigator} from 'react-navigation';
import HomeScreen from '../screens/HomeScreen';
import PlanningScreen from '../screens/PlanningScreen';
import ProxiwashScreen from '../screens/ProxiwashScreen';
-import ProximoScreen from '../screens/ProximoScreen';
+import ProximoMainScreen from '../screens/Proximo/ProximoMainScreen';
import SettingsScreen from '../screens/SettingsScreen';
import AboutScreen from '../screens/AboutScreen';
import SideMenu from "../components/SideMenu";
@@ -14,11 +14,15 @@ export default createDrawerNavigator({
Home: {screen: HomeScreen},
Planning: {screen: PlanningScreen,},
Proxiwash: {screen: ProxiwashScreen,},
- Proximo: {screen: ProximoScreen,},
+ Proximo: {screen: ProximoMainScreen,},
Settings: {screen: SettingsScreen,},
About: {screen: AboutScreen,},
}, {
contentComponent: SideMenu,
+ initialRouteName: 'Home',
+ backBehavior: 'initialRoute',
+ drawerType: 'front',
+ useNativeAnimations: true,
}
);
diff --git a/package-lock.json b/package-lock.json
index 125244f..6d1e1c0 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -6264,6 +6264,15 @@
"resolved": "https://registry.npmjs.org/react-native-maps/-/react-native-maps-0.24.2.tgz",
"integrity": "sha512-1iNIDikp2dkCG+8DguaEviYZiMSYyvwqYT7pO2YTZvuFRDSc/P9jXMhTUnSh4wNDlEeQ47OJ09l0pwWVBZ7wxg=="
},
+ "react-native-material-menu": {
+ "version": "0.6.2",
+ "resolved": "https://registry.npmjs.org/react-native-material-menu/-/react-native-material-menu-0.6.2.tgz",
+ "integrity": "sha512-xrWO1JhfB+9vlq13Y5qwAgxsD6RJvGLammjm1vJzTXHp1drtFwizga2TLwsryy0h/fo224H3INVSAxS4PWc7+A==",
+ "dev": true,
+ "requires": {
+ "prop-types": "^15.6.0"
+ }
+ },
"react-native-paper": {
"version": "2.16.0",
"resolved": "https://registry.npmjs.org/react-native-paper/-/react-native-paper-2.16.0.tgz",
@@ -6296,6 +6305,11 @@
}
}
},
+ "react-native-platform-touchable": {
+ "version": "1.1.1",
+ "resolved": "https://registry.npmjs.org/react-native-platform-touchable/-/react-native-platform-touchable-1.1.1.tgz",
+ "integrity": "sha1-/eSsxl7qWF0osWTQw3FqQhKaaOQ="
+ },
"react-native-ratings": {
"version": "6.3.1",
"resolved": "https://registry.npmjs.org/react-native-ratings/-/react-native-ratings-6.3.1.tgz",
diff --git a/package.json b/package.json
index 51f0766..f64c7bd 100644
--- a/package.json
+++ b/package.json
@@ -25,10 +25,12 @@
"react-native-web": "^0.11.4",
"react-native-week-view": "latest",
"react-navigation": "latest",
- "react-navigation-material-bottom-tabs": "latest"
+ "react-navigation-material-bottom-tabs": "latest",
+ "react-native-platform-touchable": "latest"
},
"devDependencies": {
- "babel-preset-expo": "^5.1.1"
+ "babel-preset-expo": "^5.1.1",
+ "react-native-material-menu": "^0.6.2"
},
"private": true
}
diff --git a/screens/AboutScreen.js b/screens/AboutScreen.js
index dbda873..311f3fd 100644
--- a/screens/AboutScreen.js
+++ b/screens/AboutScreen.js
@@ -53,7 +53,8 @@ export default class AboutScreen extends React.Component {
{Platform.OS === "ios" ? i18n.t('aboutScreen.appstore') : i18n.t('aboutScreen.playstore')}
-
+
Gitlab
-
+
{i18n.t('aboutScreen.bugs')}
-
+
-
+
-
+
@@ -140,7 +145,8 @@ export default class AboutScreen extends React.Component {
-
+
-
+
-
+
@@ -191,7 +199,8 @@ export default class AboutScreen extends React.Component {
-
+
-
+
diff --git a/screens/HomeScreen.js b/screens/HomeScreen.js
index 77769b7..222c821 100644
--- a/screens/HomeScreen.js
+++ b/screens/HomeScreen.js
@@ -12,7 +12,7 @@ export default class HomeScreen extends React.Component {
return (
-
+