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

Fix tab index handling for modal dialogs #19

Open
robotdan opened this issue Dec 30, 2019 · 0 comments
Open

Fix tab index handling for modal dialogs #19

robotdan opened this issue Dec 30, 2019 · 0 comments

Comments

@robotdan
Copy link
Member

When a modal dialog is open the tab index still will progress through elements behind the overlay.

Here is a good summary of the issue.

https://stackoverflow.com/questions/14572084/keep-tabbing-within-modal-pane-only

A simple fix is to capture the tab key and then manually move focus to the first element in the dialog before the tab index moves focus out of the dialog.

The better solution may to be to use what was suggested in the above SO article which is to set aria-disabled on everything that isn't currently active above the overlay.

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

No branches or pull requests

1 participant