-
Notifications
You must be signed in to change notification settings - Fork 71
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: Safari focus when there are no draggables left #360
fix: Safari focus when there are no draggables left #360
Conversation
Thanks for the pull request, @CefBoud! Please note that it may take us up to several weeks or months to complete a review and merge your PR. Feel free to add as much of the following information to the ticket as you can:
All technical communication about the code itself will be done via the GitHub pull request interface. As a reminder, our process documentation is here. Please let us know once your PR is ready for our review and all tests are green. |
1 similar comment
Thanks for the pull request, @CefBoud! Please note that it may take us up to several weeks or months to complete a review and merge your PR. Feel free to add as much of the following information to the ticket as you can:
All technical communication about the code itself will be done via the GitHub pull request interface. As a reminder, our process documentation is here. Please let us know once your PR is ready for our review and all tests are green. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
- I tested this: tested the described scenario in Safari
- I read through the code
- I checked for accessibility issues
- Includes documentation: n/a
- I made sure any change in configuration variables is reflected in the corresponding client's
configuration-secure
repository: n/a
@CefBoud 🎉 Your pull request was merged! Please take a moment to answer a two question survey so we can improve your experience in the future. |
1 similar comment
@CefBoud 🎉 Your pull request was merged! Please take a moment to answer a two question survey so we can improve your experience in the future. |
Description
This PR addresses an accessibility issue that has been observed only with Safari when relying solely on the keyboard.
The problem boils down to losing focus after the last correct drop happens and there are no more draggable items left in the bank.
The focus is "trapped" within
.close-feedback-popup-button
which loses visibility after it's closed and the focusFirstDraggable , which is subsequently called, tries to shift focus to the first option, which happens to be an invisible item placeholder that is not focusable because it has no tabindex.Clicking Tab, Shift+Tab, or ESC has no effect in Safari. With Chrome or Firefox, however, the focus is able to leave the hidden button and jump to the first Zone.
This PR adds a check to ensure the presence of draggable items and otherwise defaults focus to the first Zone in
focusFirstDraggable
.Testing instructions
Please check the following video. I increased the outlines' width for better clarity.
focus_bug_safari.mov