Rework modal dialogs
See original GitHub issueCurrent modal implementation appears quirky in current browser/AT combinations, and has some known shortcomings:
- while the modal uses focus trapping and
aria-modal
, this is still not supported correctly in all browser/ATs. for instance, Firefox/JAWS still allows navigating/reading through the underlying page; similarly, iOS VO ignores it, see https://github.com/twbs/bootstrap/issues/26770 - when the dialog is opened and focus is moved, NVDA does not announce that we’re in a modal - see https://github.com/twbs/bootstrap/issues/33715
- JAWS seems to have a weird issue with the initially set focus - once the modal is opened, the next tab and reading key press all go to the last button in the dialog, rather than starting at the top of the modal
We should take closer inspiration from https://www.w3.org/TR/wai-aria-practices/examples/dialog-modal/dialog.html (but that misses the fix for iOS/VO, so would still not be sufficient to copy the approach from there). as mentioned previously (though can’t quite find where, worth also looking at approaches like https://github.com/KittyGiraudel/a11y-dialog, and possibly https://github.com/WICG/inert
Issue Analytics
- State:
- Created 2 years ago
- Reactions:3
- Comments:12 (10 by maintainers)
Top Results From Across the Web
Modal - Bootstrap
Use Bootstrap's JavaScript modal plugin to add dialogs to your site for lightboxes, user notifications, or completely custom content.
Read more >Design Patterns for Replacing Modal Windows
The problem with modal windows · Pattern 1: Show UI elements inline · Pattern 2: Collapsible UI Elements · Pattern 3: Dynamic Inline...
Read more >Modal - Ant Design
Asynchronously close a modal dialog when the OK button is pressed. ... on 4.8.0 or above, you can pass a function to update...
Read more >c# - Update modal dialog in Caliburn Micro from outside the ...
ShowDialog() opens a modal window, which is why it blocks the further operations in the main/parent window until the modal window is closed....
Read more >Composing Reusable Modal Dialogs with Vue.js - Adam Wathan
Update Aug 12, 2017: All of the examples have now been updated for Vue 2.0! I was working on an app idea with...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
With the recent release of Safari 15.4 all major browser now support the
<dialog>
element natively:Sounds like there’s enough interest in improving these dialogs (modal & off canvas bootstrap components) - I should be able to push a PR this week so you all can start testing something tangible.