downshift-js/downshift

[useSelect] Selecting item with spacebar in firefox reopens the menu

Open

#1 197 ouverte le 18 nov. 2020

Voir sur GitHub
 (5 commentaires) (0 réactions) (0 assignés)JavaScript (980 forks)batch import
bughelp wantedneeds investigation

Métriques du dépôt

Stars
 (11 761 stars)
Métriques de merge PR
 (Merge moyen 6j 9h) (5 PRs mergées en 30 j)

Description

  • downshift version: 6.0.6
  • firefox version: 82.0.3

Relevant code or config

Error present in reference implementation: https://www.downshift-js.com/use-select

What you did:

With firefox, open a menu and select an item with the spacebar key

What happened:

The item was selected, but the menu was reopened. Closely inspecting the result of onStateChange it is revelead that on key down the __menu_keydown_space_button__ is emitted, and on key up the __togglebutton_click__ is emitted.

Error is not present in chrome.

Reproduction repository:

Problem description:

Suggested solution:

Guide contributeur