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
Android no longer scrolls to input on initial focus #23564
Comments
+1 |
Who would be best to take a look at this? |
This is still blocking us from moving to Expo 49. @brentvatne, may we ask you or somebody from the team to have a look and review the recordings? |
I'm getting the same error after upgrading to SDK 49. I can confirm that the issue has been introduced by SDK 49, as I was on 48 before. The snack @Jackman3005 has provided is on expo 47. I've re-used most of it and upgraded to SDK 49 and can easily reproduce the issue. Made a reproduction repo: https://github.com/louislatreille/keyboardIssueExpo49 |
@louislatreille Thank you for creating a legitimate reproduction! This is stopping us from upgrading to Expo 49 for the time being. |
Thank you for filing this issue! |
Hi all! I tried the code in the repro's App.js in SDK's 47, 48, 49, and found it scrolled correctly to a ScrollView/ Keyboard interaction is a pretty core-level thing that wouldn't likely be affected by a new SDK directly, but new Expo SDK's generally ship with updated versions of I then created a project with the RNC CLI ( I've accepted this issue and will raise it internally so we can see if it would work to up the In terms of fast workaround, the actual PR that fixed this is quite small (facebook/react-native#38728), and I think it would be straightforward to apply with patch-package, and then you could get that fix right away with a development build or in your production code (just not in Expo Go). I would also recommend trying to reproduce the issue on the latest RN, just in case there's a scenario that it doesn't cover, so another issue can be opened on the RN repo if needed. |
Big thanks @keith-kurak for going to the bottom of that issue! I can confirm that after upgrading to RN 72.4, my keyboard works as expected. |
Summary
Hello, we have been upgrading from SDK 47 to 49 and have noticed a regression in behavior with Android and how it behaves when you click on a TextInput towards the bottom of the screen. The keyboard comes up and covers the input now (at least initially). If I make repeated focus changes the follow-up ones will actually scroll to the input if the keyboard will cover it, but for multi-line inputs it now only scrolls to show the top of the input, not the full input like it used to.
I have tried many combinations of changing the React Native
KeyboardAvoidingView
(KAV
in the table below) behavior (including disabling it) and the Android's Keyboard layout setting defined in the App Config: (softwareKeyboardLayoutMode: 'pan'
). Each of the possible combinations resulted in the regression or other regressions.KAV
Behavior'pan'
layout'resize'
layoutposition
padding
height
disabled
Unfortunately I was not having any success building our app with Expo 48, so I cannot definitively say if this was introduced going from 47 to 48 or 48 to 49 . Edit: @louislatreille confirmed below that it happens when upgrading from Expo 48 to 49
Minimal reproducible example
https://snack.expo.dev/@jcoy/belligerent-stroopwafels
Environment
The text was updated successfully, but these errors were encountered: