Proposal : TVFocusGuideView for Android
See original GitHub issueCurrently, it’s very difficult to direct Focus between Viewgroups of Touchables
ForExample
- In the below image it’s very difficult to direct focus from any items in cluster 2 to the previously focused item in cluster 1 to achieve this currently we have to set
nextFocusUpprops for all the children in cluster 2 to cluster 1 last focused item id.
- In the below example from all the horizontal list items we should open a previously selected menu, which is the second item. For this, we have to set all the first items of lists
nextFocusLeftto the 2nd menu item id
Also, one more problem is we have to pass node id between components to achieve this via props which make components reusability an issue
Solution If we have WrapperView like TVFocusFocusGuide which gets focus first for a cluster and then based on requirement we can pass the focus to any of its children’s.
We have android:descendantFocusability and onRequestFocusInDescendants view group props which will let us achieve this behavior.
We can have a component that wraps touchable and controls the focus setup and movement between view groups.
Issue Analytics
- State:
- Created 2 years ago
- Reactions:5
- Comments:9 (2 by maintainers)
Top Results From Across the Web
React Native Repo with Additions for Apple TV Support - Morioh
TVFocusGuideView : This component provides support for Apple's ... You can use this open-source framework to code natively rendering Android and iOS mobile ......
Read more >Building For TV Devices - React Native
TV devices support has been implemented with the intention of making existing React Native applications work on Apple TV and Android TV, ...
Read more >IOS and android mobile app development using react native ...
Project details. I build app for IOS and android mobile app development platform then React Native/Expo is the best choice. I am experienced...
Read more >react-native-tvos - npm
(but no Android TV devices) you can use: ... TVFocusGuideView: This component provides support for Apple's UIFocusGuide API, to help ensure ...
Read more >0 - Stack Overflow
-2) Run this command below. $ cd android $ ./gradlew assembleRelease. -3) Result: I receive the following error message. index.js: Cannot find ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

@TrebuhD that API looks VERY interesting indeed, thank you for letting me know.
API-wise, it would be great to have something like react-spatial-navigation.