Closed m7kvqbe1 closed 1 month ago
Name | Link |
---|---|
Latest commit | a0bc59724b5ab8809d20c48c25d794f5a7d10e8e |
Latest deploy log | https://app.netlify.com/sites/storybook-navy-digital-mod-uk/deploys/663b2adfd4744800074b525a |
Deploy Preview | https://deploy-preview-3785--storybook-navy-digital-mod-uk.netlify.app |
Preview on mobile | Toggle QR Code...Use your smartphone camera to open QR code link. |
To edit notification comments on pull requests, go to your Netlify site configuration.
Maybe some duplication between Modal and Dialog. Perhaps add a ticket to refactor
Dialog is just a wrapper around Modal really - it's being prescriptive about how Modal is composed.
It exposes an isDanger prop, onCancel and onConfirm handler.
Issues
0 New issues
0 Accepted issues
Measures
0 Security Hotspots
80.0% Coverage on New Code
0.0% Duplication on New Code
Related issue
Closes #3757
Overview
Apply focus trap to Modal and Dialog components (use native Dialog).
Expose show and close methods via forwardedRef and imperative handle.
Reason
Modal and Dialog were not correctly applying a focus trap.
Work carried out
Screenshot
Developer notes
When a dialog opens, the browser, by default, gives focus to the first element that can be focused within the dialog (always the close button if it is specified).
The Escape key can also now be used to close the modal.
https://developer.mozilla.org/en-US/docs/Web/HTML/Element/dialog