Composer - backup android focus (#4415)
* backup android focus * bump to 300ms just to make sure it catches all of them
This commit is contained in:
parent
fefae27396
commit
29a4a5f90c
1 changed files with 13 additions and 0 deletions
|
@ -402,6 +402,19 @@ export const ComposePost = observer(function ComposePost({
|
||||||
bottomBarAnimatedStyle,
|
bottomBarAnimatedStyle,
|
||||||
} = useAnimatedBorders()
|
} = useAnimatedBorders()
|
||||||
|
|
||||||
|
// Backup focus on android, if the keyboard *still* refuses to show
|
||||||
|
useEffect(() => {
|
||||||
|
if (!isAndroid) return
|
||||||
|
if (isModalReady) {
|
||||||
|
setTimeout(() => {
|
||||||
|
if (!Keyboard.isVisible()) {
|
||||||
|
textInput.current?.blur()
|
||||||
|
textInput.current?.focus()
|
||||||
|
}
|
||||||
|
}, 300)
|
||||||
|
}
|
||||||
|
}, [isModalReady])
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
<KeyboardAvoidingView
|
<KeyboardAvoidingView
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue