APSL / react-native-keyboard-aware-scroll-view

A ScrollView component that handles keyboard appearance and automatically scrolls to focused TextInput.
MIT License
5.24k stars 643 forks source link

iOS 14.0 on keyboard dismiss _updateKeyboardSpace is called as well as _resetKeyboardSpace #454

Open c-moss-talk opened 3 years ago

c-moss-talk commented 3 years ago

Hi,

Noticed a bug (on latest of this library & RN0.60.6) that occurs on iOS14, not 13, that when the keyboard is dismissed the _resetKeyboardSpace callback is not returning the keyboard to the proper scroll position. The callback is in fact firing, I have verified; however, the _updateKeyboardSpace is also called and the final position (after keyboard dismiss) of the textInput ends up quite a bit lower than desired.

It seems the "keyboardWillShow" event is getting triggered on the close keyboard event.

c-moss-talk commented 3 years ago

I mean I don't really understand all the things this callback is doing, but the keyboardWillShow event seems to be firing on all interactions with the a TextInput, even typing, but just disabling this scrollToNode seems to return it to the expected behavior. This was tested on both simulators and actual devices -- previous behavior was restored to as it was on 13.

lovejaco commented 3 years ago

It seems to be related to https://github.com/facebook/react-native/issues/30037

000xuandu commented 3 years ago

Facing this same error.

heyman333 commented 3 years ago

+1

vb-ben commented 3 years ago

+1