reach/reach-ui

[Listbox] View jumps when opening listbox with space or down arrow.

Open

#698 aperta il 5 nov 2020

Vedi su GitHub
 (2 commenti) (0 reazioni) (0 assegnatari)TypeScript (558 fork)auto 404
Help WantedType: Bug

Metriche repository

Star
 (5975 star)
Metriche merge PR
 (Metriche PR in attesa)

Descrizione

🐛 Bug report

Current Behavior

Browser view jumps away from the focused ListboxOption when opening listbox with space or down arrow key. The focused elements is completely out of the view.

Expected behavior

Browser view / scroll position should remain unchanged or at least try to fit the focused element into to current view.

Reproducible example

https://reach.tech/listbox/#reach-skip-nav

To reproduce:

  1. open the example page with a chromium based browser on Mac OS (maybe Windows too?)
  2. use tab (you can use the skip link) to navigate to first listbox example
  3. Press space or down arrow

Additional context

Seems to concern chromium based browsers at least on mac OS. Could also be a chromium bug since it is not reproducible with other browsers.

Your environment

Software Name(s) Version
Reach Package Listbox latest?
React
Browser Chrome 86.0.4240.183
Assistive tech -
Node
npm/yarn
Operating System Mac OS 10.15.7 (19H2)

Guida contributor