Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Accessibility Bug: Filter + Search Dropdown Field Traps Focus When Using <Shift>+<Tab> #1234

Closed
jhawkmedvesky opened this issue Dec 3, 2024 · 0 comments · Fixed by #1239
Closed
Labels

Comments

@jhawkmedvesky
Copy link

jhawkmedvesky commented Dec 3, 2024

Describe the bug:

An accessibility issue exists with the drop-down field in the Search and Filter function. When users attempt to navigate backward using <Shift>+<Tab>, the focus does not return to the previous field. Instead, it collapses/expands the drop-down repeatedly, creating a "focus trap". Users must navigate forward through all subsequent <Tab>-able elements to return to the previous field, which disrupts keyboard navigation and hinders accessibility.

To Reproduce:

  • Steps to reproduce the behavior:
  1. Go to the Events List page on our staging site: https://glump.io/list-block/.
  2. Locate the Filters section at the top of the page.
  3. Use <Tab> to navigate into the first and second drop-down fields ("Category"," All Locations").
  4. Verify that <Tab> moves the focus forward and <Shift>+<Tab> correctly moves the focus back to the previous field or interactive element.
  5. Navigate to the third field ("Select Postal Code") where the Search and Filter function is applied.
  6. Attempt to use <Shift>+<Tab> to return to the previous field.
  • Observed Behavior - instead of moving to the previous drop-down field, <Shift>+<Tab> causes the drop-down to collapse/expand, and the focus remains trapped within the field.

  • NOTE: - I also encountered this same bug when using <Tab>/<Shift>+<Tab> commands in the examples provided on https://choices-js.github.io/Choices/, under the "Multiple select input" section.

Expected behavior:

When using <Shift>+<Tab> in the "Select Postal Code" field:

  • The focus should move to the previous drop-down field ("All Locations").
  • Keyboard users should not encounter any traps or disruptions in navigation, ensuring smooth backward navigation across all fields in the section.

Screenshots:

  • Not applicable.

Choices version and bundle:

  • 11.0.2, choices.js

Desktop (please complete the following information):

  • OS: Windows 11 Pro - version 23H2
  • Browsers - tested in:
    • Firefox Developer Edition - version 134.0b3
    • Chrome - version 131.0.6778.86
    • Edge - version 131.0.2903.70

Note - all browsers indicate they are up to date in Settings section.

Smartphone (please complete the following information):

  • Not applicable (since this is a keyboard issue).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant