Skip to content

Arrow key up/down on closed <selectmenu> #433

Description

@dandclark

Another <selectmenu> behavior to discuss: what should happen when the control's listbox is closed, and a user arrow keys up/down on the control's button?

Per my testing of <select> in Chromium and Gecko on Windows, up/down arrow keys advance backwards/forwards through the list of options without opening the listbox.

However looking at the example at https://www.w3.org/TR/wai-aria-practices/examples/listbox/listbox-collapsible.html, up/down arrow open the listbox in addition to moving to the next previous option.

Down Arrow

  • Moves focus to and selects the next option.
  • If the listbox is collapsed, also expands the list.

Up Arrow

  • Moves focus to and selects the previous option.
  • If the listbox is collapsed, also expands the list.

The guidance in https://www.w3.org/TR/wai-aria-practices/#listbox_kbd_interaction doesn't state that up/down arrow should open the listbox.

Down Arrow: Moves focus to the next option. Optionally, in a single-select listbox, selection may also move with focus.
Up Arrow: Moves focus to the previous option. Optionally, in a single-select listbox, selection may also move with focus.

So I'm not clear on whether the best practice is to open the listbox or not when up/down arrow is pressed. Thoughts?

(Thanks @mfreed7 for pointing this out).

Metadata

Metadata

Assignees

No one assigned

    Labels

    i18n-trackerGroup bringing to attention of Internationalization, or tracked by i18n but not needing response.selectThese are issues that relate to the select component

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions