diff --git a/apps/mobile/app/(app)/[workspace]/(tabs)/chat.tsx b/apps/mobile/app/(app)/[workspace]/(tabs)/chat.tsx index f1cbf24752..90ef0abcf8 100644 --- a/apps/mobile/app/(app)/[workspace]/(tabs)/chat.tsx +++ b/apps/mobile/app/(app)/[workspace]/(tabs)/chat.tsx @@ -34,10 +34,9 @@ import { useCallback, useEffect, useMemo, useRef, useState } from "react"; import { Alert, AppState, - KeyboardAvoidingView, - Platform, View, } from "react-native"; +import { KeyboardAvoidingView } from "react-native-keyboard-controller"; import { router } from "expo-router"; import { useFocusEffect, useIsFocused } from "@react-navigation/native"; import { useQuery, useQueryClient } from "@tanstack/react-query"; @@ -465,8 +464,15 @@ export default function ChatTab() { } /> {availability === "none" ? : null} + {/* + * Use the keyboard-controller implementation already mounted by the + * root KeyboardProvider. Unlike RN's event-driven KAV, its padding is + * derived from the native keyboard state, so a keyboard dismissal that + * occurs while the app is backgrounded cannot leave stale bottom + * padding and collapse this flex layout when the app resumes. + */}