From 77bb7b84dc018b9abc756a20ad87821bd4f91fd6 Mon Sep 17 00:00:00 2001 From: chahinebrini Date: Sun, 17 May 2026 21:58:05 +0200 Subject: [PATCH] =?UTF-8?q?fix(keyboard):=20Android=20keyboard=20covers=20?= =?UTF-8?q?input=20=E2=80=94=20use=20react-native-keyboard-controller?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Bug: 3 Stellen hatten `behavior={Platform.OS === 'ios' ? 'padding' : undefined}`. Auf Android = `undefined` = KeyboardAvoidingView macht NICHTS → Input wird von Tastatur verdeckt (chat-input, profile-edit-nickname, room-chat). Fix: switch zu react-native-keyboard-controller's KeyboardAvoidingView mit behavior='padding' für beide Plattformen. Funktioniert sauber cross-platform weil KeyboardProvider schon im root-layout sitzt. Affected Files: - components/KeyboardAwareScreen.tsx (used by profile-edit + auth-screens) - app/dm.tsx (DM chat) - app/room.tsx (room chat) lyra.tsx war bereits OK (`'height'` für Android — kein Fix nötig). iOS-Verhalten unverändert. Co-Authored-By: Claude Opus 4.7 --- apps/rebreak-native/app/dm.tsx | 4 ++-- apps/rebreak-native/app/room.tsx | 4 ++-- apps/rebreak-native/components/KeyboardAwareScreen.tsx | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/apps/rebreak-native/app/dm.tsx b/apps/rebreak-native/app/dm.tsx index 001eb1c..b4c20de 100644 --- a/apps/rebreak-native/app/dm.tsx +++ b/apps/rebreak-native/app/dm.tsx @@ -4,12 +4,12 @@ import { Text, FlatList, TouchableOpacity, - KeyboardAvoidingView, Platform, ActivityIndicator, Image, StyleSheet, } from 'react-native'; +import { KeyboardAvoidingView } from 'react-native-keyboard-controller'; import { SafeAreaView, useSafeAreaInsets } from 'react-native-safe-area-context'; import { useRouter, useLocalSearchParams } from 'expo-router'; import { Ionicons } from '@expo/vector-icons'; @@ -275,7 +275,7 @@ export default function DmScreen() { diff --git a/apps/rebreak-native/app/room.tsx b/apps/rebreak-native/app/room.tsx index 7d0a8dc..6eaba2e 100644 --- a/apps/rebreak-native/app/room.tsx +++ b/apps/rebreak-native/app/room.tsx @@ -9,12 +9,12 @@ import { Modal, TextInput, ActivityIndicator, - KeyboardAvoidingView, Platform, Alert, StyleSheet, ScrollView, } from 'react-native'; +import { KeyboardAvoidingView } from 'react-native-keyboard-controller'; import { SafeAreaView, useSafeAreaInsets } from 'react-native-safe-area-context'; import { useRouter, useLocalSearchParams } from 'expo-router'; import { Ionicons } from '@expo/vector-icons'; @@ -360,7 +360,7 @@ export default function RoomScreen() { ) : ( {scrollable ? (