TextInput doesn't lose focus after dismissing keyboard on some Android devices
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 127k
- Forks
- 25.3k
- Avg merge
- 1d 23h
- Merged PRs (30d)
- 4
Description
Description
Current Behavior
When TextInput is focused and keyboard is shown, pressing hardware back button dismisses the keyboard but doesnt't blur the TextInput. Pressing on the TextInput again doesn't trigger the keyboard.
I noticed it happening on these devices: Mobistart V1 (android v 9), Meizu M3s (android v 5.1), Honor 8 (android v 7).
This behaviour doesn't seem to be dependant on Android version or brand.
Also this behaviour appears in every React Native app.
Expected Behavior
The TextInput should lose focus after hardware back button press.
Version
0.65.1
Output of npx react-native info
No warnings or errors apper in console.
Steps to reproduce
Basically it happens with any TextInput.
<TextInput />
Snack, code example, screenshot, or link to a repository
No response
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the minimal reproduction on the affected Android devices, then trace the hardware-back keyboard dismissal and focus handling in React Native's Android TextInput path. Done means the input loses focus after the keyboard is dismissed and can show the keyboard again when pressed; verify this across the reported Android versions and devices.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, react-native
- Domain
- mobile
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100