bugfix: enables Escape to dismiss alert Dialog#28276
Conversation
Perf Analysis (
|
| Scenario | Render type | Master Ticks | PR Ticks | Iterations | Status |
|---|---|---|---|---|---|
| InfoButton | mount | 6 | 15 | 5000 | Possible regression |
All results
| Scenario | Render type | Master Ticks | PR Ticks | Iterations | Status |
|---|---|---|---|---|---|
| Avatar | mount | 599 | 581 | 5000 | |
| Button | mount | 284 | 290 | 5000 | |
| Field | mount | 1061 | 1069 | 5000 | |
| FluentProvider | mount | 632 | 664 | 5000 | |
| FluentProviderWithTheme | mount | 81 | 86 | 10 | |
| FluentProviderWithTheme | virtual-rerender | 73 | 66 | 10 | |
| FluentProviderWithTheme | virtual-rerender-with-unmount | 72 | 68 | 10 | |
| InfoButton | mount | 6 | 15 | 5000 | Possible regression |
| MakeStyles | mount | 847 | 868 | 50000 | |
| Persona | mount | 1609 | 1578 | 5000 | |
| SpinButton | mount | 1275 | 1296 | 5000 |
Asset size changesSize Auditor did not detect a change in bundle size for any component! Baseline commit: 5809e04461b488016393f68d0c809d5b43eb93db (build) |
|
This pull request is automatically built and testable in CodeSandbox. To see build info of the built libraries, click here or the icon next to each commit SHA. Latest deployment of this branch, based on commit 20e9131:
|
📊 Bundle size reportUnchanged fixtures
|
🕵 fluentuiv9 No visual regressions between this PR and main |
|
🎉 Handy links: |
|
🎉 Handy links: |
|
@bsunderhus @ling1726 Why is the Escape key allowed to close the Dialog with modalType="alert"? This doesn't make sense to me. Now there is no way to create a Dialog that can not be closed. Alert was the only modalType to prevent the Dialog from closing and forcing a user to take an action. Both Modal or non-Modal allow the user to close the Dialog. Also now the documentary is invalid, please see below: |
Hey there @goamn, you're completely right, I'll see to create an issue to update the documentation!
This change is due to WAI-ARIA alertdialog pattern compliance, an alert dialog has no such feature! you should always be able to close a dialog by pressing the
You can still control the opening state and avoid opening on |
|
Hello, ok thank you, at least there is a second way :) |

Previous Behavior
New Behavior
useDialogTrigger.styles.tsRelated Issue(s)