Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

use UIManager.measure instead of UIManager.measureInWindow #414

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

simonasdev
Copy link

When focusing inputs even slightly behind the keyboard, scroll position becomes incorrect: https://drive.google.com/file/d/1HI_aTBHg2RndH7tSKo86KBeoysULOPhG/view

By using UIManager.measure instead of UIManager.measureInWindow this issue does not occur. Not sure if this doesn't break any other use cases though

@simonasdev
Copy link
Author

simonasdev commented Dec 23, 2019

Apparently I have no clue what I'm doing. This just makes textInputBottomPosition > keyboardPosition - totalExtraHeight to always evaluate to false and not perform any scrollToFocusedInput function calls, and just update the keyboardSpace, which sets scrollview's contentInset.bottom prop, which when combined with extraScrollHeight allows for a consistent position.

So there's a different problem, either that an incorrect reactNode is being passed to ScrollResponder.scrollResponderScrollNativeHandleToKeyboard function, or that function does not work as it should.
Does anyone have any ideas how to 'properly' fix the issue that occurs in the link above?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant