Viktoriia 1 gadu atpakaļ
vecāks
revīzija
28022ae0eb

+ 12 - 14
src/components/MenuDrawer/index.tsx

@@ -61,20 +61,18 @@ export const MenuDrawer = (props: any) => {
           <View style={styles.logoContainer}>
             <Image source={require('../../../assets/logo-ua.png')} style={styles.logo} />
           </View>
-          <View style={{ top: 12 }}>
-            <MenuButton
-              label="Contact Us"
-              icon={<MailIcon fill={Colors.DARK_BLUE} width={20} height={20} />}
-              red={false}
-              buttonFn={() => Linking.openURL('https://nomadmania.com/contact/')}
-            />
-            <MenuButton
-              label="Terms & Conditions"
-              icon={<DocumentIcon fill={Colors.DARK_BLUE} width={20} height={20} />}
-              red={false}
-              buttonFn={() => Linking.openURL('https://nomadmania.com/terms/')}
-            />
-          </View>
+          <MenuButton
+            label="Contact Us"
+            icon={<MailIcon fill={Colors.DARK_BLUE} width={20} height={20} />}
+            red={false}
+            buttonFn={() => Linking.openURL('https://nomadmania.com/contact/')}
+          />
+          <MenuButton
+            label="Terms & Conditions"
+            icon={<DocumentIcon fill={Colors.DARK_BLUE} width={20} height={20} />}
+            red={false}
+            buttonFn={() => Linking.openURL('https://nomadmania.com/terms/')}
+          />
         </View>
 
         {token ? (

+ 22 - 2
src/screens/InAppScreens/MapScreen/index.tsx

@@ -150,7 +150,24 @@ const MapScreen: React.FC<MapScreenProps> = ({ navigation }) => {
   }, [strokeWidthAnim]);
 
   useEffect(() => {
-    navigation.setOptions({
+    navigation.addListener('state', (state) => {
+      navigation.getParent()?.setOptions({
+        tabBarStyle: {
+          display:
+            (state.data.state.history[1] as { status?: string })?.status === 'open' ||
+            regionPopupVisible
+              ? 'none'
+              : 'flex',
+          position: 'absolute',
+          ...Platform.select({
+            android: {
+              height: 58
+            }
+          })
+        }
+      });
+    });
+    navigation.getParent()?.setOptions({
       tabBarStyle: {
         display: regionPopupVisible ? 'none' : 'flex',
         position: 'absolute',
@@ -611,7 +628,10 @@ const MapScreen: React.FC<MapScreenProps> = ({ navigation }) => {
         </>
       ) : (
         <>
-          <TouchableOpacity style={[styles.cornerButton, styles.topRightButton]} onPress={() => (navigation as any)?.openDrawer()}>
+          <TouchableOpacity
+            style={[styles.cornerButton, styles.topRightButton]}
+            onPress={() => (navigation as any)?.openDrawer()}
+          >
             <MenuIcon />
           </TouchableOpacity>
 

+ 1 - 1
src/screens/InAppScreens/MapScreen/style.tsx

@@ -43,7 +43,7 @@ export const styles = StyleSheet.create({
     right: 16,
   },
   bottomButton: {
-    bottom: Platform.OS == 'android' ? 24 : 32,
+    bottom: Platform.OS == 'android' ? 80 : 100,
     width: 42,
     height: 42,
     borderRadius: 21,