Skip to content

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

@aappoalander

Description

@aappoalander

🐛 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)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Help WantedExtra attention is neededType: BugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions