Open
Description
Summary:
It seems to be possible to escape the focus lock with VoiceOver and Safari on MacOS if Quick Nav is turned off. Navigating with left or right arrow key (without VoiceOver modifier key) allows the screen reader cursor to escape the modal. Once a focusable element outside the modal is reached, focus escapes and it is possible to navigate the underlying page with e.g. tab-key.
Steps to reproduce:
- Open Safari on MacOS
- Navigate to https://github.com/reactjs/react-modal#demos / Minimal example
- Turn on VoiceOver, turn off Quick Nav (left+right arrow)
- Trigger / open the modal
- Navigate with left arrow key (without modifier) until cursor reaches the trigger button outside the modal
Expected behavior:
Cursor should stay inside the modal like here (https://www.w3.org/TR/wai-aria-practices-1.1/examples/dialog-modal/dialog.html). Focus should not escape.
Link to example of issue:
https://codepen.io/claydiffrient/pen/KNxgav
Additional notes:
This is pontentially a MacOS/Safari/VoiceOver bug.