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

Lazy focusable widgets #167

Open
SamRodri opened this issue Apr 29, 2024 · 0 comments
Open

Lazy focusable widgets #167

SamRodri opened this issue Apr 29, 2024 · 0 comments
Labels
A-scroll Area: Scroll todo TODO task

Comments

@SamRodri
Copy link
Collaborator

Lazy widgets are not fully inited, so if they are focusable they are not visible in the focus tree. This causes problems like in the 'icon' example, where cycle navigation back from the search box only scrolls to the last loaded icon, not the actual last.

Possible solutions:

1 - Create some "focus anchor" thing that exists as a full widget placed at the edges of the lazy bounds, just to receive focus and then remove itself and focus the loaded widget nearest to it.
2- Create custom nav API that Scroll! can use to intercept the navigation-from-edges operations and scroll first before computing.

Workaround:

You can workaround this issue by having a focusable footer of some sort (inside the same Scroll!).

@SamRodri SamRodri added todo TODO task A-scroll Area: Scroll labels Apr 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-scroll Area: Scroll todo TODO task
Projects
None yet
Development

No branches or pull requests

1 participant