bamlab / react-native-hide-with-keyboard

Wrap around components to hide them if keyboard is up
MIT License
124 stars 13 forks source link

TextInput autoFocus #9

Open demarchisd opened 6 years ago

demarchisd commented 6 years ago

Hey!

First of all, I'd like to thank you for sharing this component, it's very useful!

So, I'm using the HideWithKeyboard, and most of my screens have a TextInput with autoFocus set to true, so it opens the keyboard right when the screens are opened.

I've been noticing some inconsistency with this, sometimes my content that should be hidden is actually hidden, but sometimes it still shows up. If I close the keyboard and open it again by clicking on the TextInput it always works. It seems to be something with autoFocus.

I've been only testing with Android, so I don't know if the same happens with iOS devices.

Versions
react-native-hide-with-keyboard: 1.1.1
react-native-cli: 2.0.1
react-native: 0.55.1

Thanks!

JamesBond95470 commented 5 years ago

Hi did you find a solution for this issue ?

demarchisd commented 5 years ago

No. I ended up manually calling the input focus when the screens are loaded as a workaround.