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

keyboard trap for screenreaders with aria-hidden #15

Closed
Veyfeyken opened this issue Apr 25, 2016 · 3 comments
Closed

keyboard trap for screenreaders with aria-hidden #15

Veyfeyken opened this issue Apr 25, 2016 · 3 comments

Comments

@Veyfeyken
Copy link

Hi,
It's not modal for screenreaders yet. You can navigate the page behind the dialog. A possible solution is hiding all other content on the page for screenreaders when the modal is active, using aria-hidden="true". This makes everything invisible except the dialog, creating a keyboard trap. Example http://a11y.nicolas-hoffmann.net/modal/.

@danhumaan
Copy link
Collaborator

Thanks @Veyfeyken this is really great feedback. We'll investigate this further and work it in as a priority in the next release!

@AndrewArch
Copy link

AndrewArch commented May 1, 2016

Further to @Veyfeyken's comment, I found I was able to tab out of the modal and lost keyboard focus - ended up in the address bar and then somewhere on the background page before re-entering the modal.

@danhumaan
Copy link
Collaborator

Hi @Veyfeyken, thanks again for your contribution. We've spent some time investigation the focus states as well as applied some fixes for when users could tab away from the modal. Strictly speaking we haven't added the aria-hidden attribute, however we believe this issue has been fixed via other means in the latest release.

@AndrewArch, the behaviour of allowing the focus to move out of the page and into the application frame, such as address bar, is something that we want to retain. If we override this we'll likely only be doing more harm to keyboard users, and users with assistive technologies by locking them into the content, subsequently not allowing them to continue on onto other tasks outside the website.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants