Open kmeleta opened 1 year ago
The focus trap used in the menu drawer breaks in several scenarios and allows focus to escape outside the dialog. It appears to occur when..
https://screenshot.click/05-30-cea10-p4hnd.mp4
Focus should always be trapped in the drawer and return to the menu toggle when tabbing past the last focusable item.
Noticed on Dawn 8.0.0
The elements in the localization disclosures are being recognized as the last focusable item in the dialog, rather than the parent element or triggering button.
The account button can also get recognized as the last element even when it is hidden (the issue wouldn't occur on mobile when the account button becomes visible).
Related to or possibly a duplicate of https://github.com/Shopify/dawn/issues/360.
Describe the current behavior
The focus trap used in the menu drawer breaks in several scenarios and allows focus to escape outside the dialog. It appears to occur when..
https://screenshot.click/05-30-cea10-p4hnd.mp4
Describe the expected behavior
Focus should always be trapped in the drawer and return to the menu toggle when tabbing past the last focusable item.
Version information (Dawn, browsers and operating systems)
Noticed on Dawn 8.0.0
Possible solution
The elements in the localization disclosures are being recognized as the last focusable item in the dialog, rather than the parent element or triggering button.
The account button can also get recognized as the last element even when it is hidden (the issue wouldn't occur on mobile when the account button becomes visible).