FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Dropdown and dropdown-like components should have the same interaction · Issue #2898 · patternfly/patternfly-react · GitHub

Dropdown and dropdown-like components should have the same interaction #2898

Description

Following up on #2890, I noticed that not all dropdown and dropdown-like components have the same interaction pattern. The components in question are:

  • Application launcher
  • Context selector
  • Dropdown
  • FormSelect
  • Options menu
  • Pagination
  • Select

Here are some interactions i would generally expect to happen across these using the keyboard:

  1. Tab to focus on a toggle
  2. Enter key opens the menu
  3. The focus is placed on the first menu item
  4. I can use keyboard up/down to navigate between the items
  5. One of:
    a) Enter key on an item closes the menu (if applicable and not multi-select)
    b) Escape key is pressed to close the menu
  6. Focus is returned to the toggle
  7. Hitting the enter key again should reopen the menu since focus is back on the toggle

I think the key to have the same behavior across all of these components is to fix this behavior first in DropdownToggle / DropdownMenu components and then reuse these components in the other mentioned components. We have started to reuse some Dropdown components in other components, but there is still a lot of redundant code, especially surrounding the Toggle/Menu part of it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


    Back | FazBrowse Home | New Git URL