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

Scrollable areas not keyboard-accessible #7236

Closed
missmatsuko opened this issue Dec 7, 2020 · 1 comment
Closed

Scrollable areas not keyboard-accessible #7236

missmatsuko opened this issue Dec 7, 2020 · 1 comment
Assignees
Labels
accessibility 👤 features related to accessibility bug

Comments

@missmatsuko
Copy link
Contributor

missmatsuko commented Dec 7, 2020

Description

Elements with the style overflow: auto; become scrollable when their content overflows their container. However, the scrollbars cannot be controlled using keyboard alone.

Firefox seems to be the only browser that does make such elements keyboard-focusable. There's an open issue for WebKit (Safari). The issue has been fixed in Chromium, but it's not actually reflected in Edge and Chrome, possibly due to this related issue.

Until browsers handle this by default, the recommended solution is to add tabindex="0" to the containing element. Ideally this will only be added to elements that are actually scrollable so that there aren't extra tab stops for non-interactive content.

References

Steps to reproduce

Use keyboard to tab through a page with a scrollable element. Except in Firefox, the scrollable element won't be focusable and controllable by keyboard.

If you have content in project config, there should be such a scrollable element at Utilities → Project Config (/admin/utilities/project-config) under the heading "Loaded Project Config Data".

Additional info

  • Craft version: 3.5.16
@missmatsuko missmatsuko added bug accessibility 👤 features related to accessibility labels Dec 7, 2020
@missmatsuko missmatsuko changed the title Scrollable areas with overflow: auto not keyboard-accessible Scrollable areas not keyboard-accessible Dec 12, 2020
@brandonkelly
Copy link
Member

Added tabindex="0" attributes for all places I could find this being a potential issue:

  • The diff pane and loaded config pane in the Project Config utility
  • Stack trace modals in the Deprecation Warnings utility
  • The error details pane in the updater, in the event of a failed update / plugin installation

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
accessibility 👤 features related to accessibility bug
Projects
None yet
Development

No branches or pull requests

2 participants