-
Notifications
You must be signed in to change notification settings - Fork 25.1k
Open
Labels
API: KeyboardIssue: Author Provided ReproThis issue can be reproduced in Snack or an attached project.This issue can be reproduced in Snack or an attached project.Needs: Triage 🔍
Description
Description
Sometimes we need to set external keyboard focus from one place to another, for instance from one Pressable to another Pressable, or from a Pressable to a View.
For Screen Reader users we can use AccessibilityInfo.setAccessibilityFocus(tag) to manage focus, but this technique does not work for the external keyboard when a screen reader is not switched on.
The standard React method of ref.current.focus() also does not work for external keyboard users on mobile (only web).
React Native Version
0.71.3
Output of npx react-native info
I don't have access to this.
Steps to reproduce
On Android or iOS physical device:
- Connect a hardware keyboard to the device using bluetooth.
- Open https://snack.expo.dev/@nedgip/external-keyboard-focus-example-1 in Expo Go
- Navigate to the Send focus button using arrow keys
- Press Space
Expected
Focus should move to the Receive focus button
Actual
Focus remains on the Send focus button
Snack, screenshot, or link to a repository
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
API: KeyboardIssue: Author Provided ReproThis issue can be reproduced in Snack or an attached project.This issue can be reproduced in Snack or an attached project.Needs: Triage 🔍