Page MenuHomePhabricator

ComboBoxInputWidget: does not close when tabbing out with selected value
Closed, ResolvedPublicBUG REPORT

Description

Steps to Reproduce:

  • open a page with a ComboBoxInputWidget on in
  • tab through the form fields (using the keyboard) until the ComboBoxInputWidget is reached
  • select a value (through keyboard arrows)
  • tab to go to the next form field

Actual Results:

  1. upon the first tab "out", the list of suggestions is actually closed, but the ComboBoxInputWidget's input is still focused
  2. upon the second tab "out", the list of suggestions opens again
  3. upon the third tab "out", the "next form field" is actually focused but the list of suggestions remains open (possibly covering the relevant form field)

Expected Results:

  1. upon the first tab "out", the list of suggestions is actually closed and the next input element is focused

Depending on how ComboBoxInputWidget is supposed to function it is ok if also the arrow button opens the list of suggestions, but it is important that upon leaving the ComboBoxInputWidget the list of suggestions is acutally closed.

Note:

  • it appears that tabbing out of the ComboBoxInputWidget with no value selected, the observed is correct (the list of suggestions closes)

Screenshot:

Bildschirmfoto von 2020-11-18 14-38-06.png (730×1 px, 67 KB)
(one can see that actually the "hash" to the right is focused but the list of suggestions is still open)

Info:
This can be witnessed on https://doc.wikimedia.org/oojs-ui/master/demos/?page=widgets&theme=wikimediaui&direction=ltr&platform=desktop#ComboBoxInputWidget
We discovered this while looking at T266638: language/spelling variant selector on Special:NewItem and Special:NewLexeme stays open when tabbing out of it, covering other input fields.

Event Timeline

Change 641761 had a related patch set uploaded (by Thiemo Kreuz (WMDE); owner: Thiemo Kreuz (WMDE)):
[oojs/ui@master] Fix ComboBoxInputWidget misbehaving when tabbing

https://gerrit.wikimedia.org/r/641761

Thanks for letting me know. I had a look and was indeed able to reproduce the issue. It looks like the code that open the dropdown menu when e.g. the field is focused gets triggered in to many situations. I uploaded an alternative bugfix.

Change 641761 merged by jenkins-bot:
[oojs/ui@master] Fix ComboBoxInputWidget misbehaving when tabbing

https://gerrit.wikimedia.org/r/641761

Volker_E edited projects, added OOUI (OOUI-0.41.0); removed OOUI.

Change 645179 had a related patch set uploaded (by VolkerE; owner: VolkerE):
[mediawiki/core@master] Update OOUI to v0.41.0

https://gerrit.wikimedia.org/r/645179

Change 645179 merged by jenkins-bot:
[mediawiki/core@master] Update OOUI to v0.41.0

https://gerrit.wikimedia.org/r/645179