You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Prevented active loading overlays from stealing focus from already focused page controls during navigation. Also prevented loading overlays behind modals from exposing a second modal dialog to assistive tech.
Changelog
Changed
Prevented active loading overlays from stealing focus from an already focused page control during navigation.
Removed aria-modal="true" from loading dialogs to avoid conflicting modal semantics when a loading overlay appears behind a modal.
Testing / Reviewing
These changes fix the unexpected focus behavior introduced by 5d916f1, which may be considered a regression. I noticed issues after updating Carbon in one of the products I work on and seeing unexpected behavior related to Loading components.
Loading overlays should only claim focus when the document is focused on body.
Focus a page control, activate a Loading component with withOverlay, and verify that focus remains on the page control. Verify that focus trapping still works when focus moves outside the active overlay.
PR Checklist
As the author of this PR, before marking ready for review, confirm you:
Reviewed every line of the diff
Updated documentation and storybook examples
Followed the required v12 migration documentation
for any code change that affects v12, or struck through this item because
the PR does not affect v12
Wrote passing tests that cover this change
Addressed any impact on accessibility (a11y)
Tested for cross-browser consistency
Validated that this code is ready for review and status checks should pass
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No issue. Related to #22196
Prevented active loading overlays from stealing focus from already focused page controls during navigation. Also prevented loading overlays behind modals from exposing a second modal dialog to assistive tech.
Changelog
Changed
aria-modal="true"from loading dialogs to avoid conflicting modal semantics when a loading overlay appears behind a modal.Testing / Reviewing
These changes fix the unexpected focus behavior introduced by 5d916f1, which may be considered a regression. I noticed issues after updating Carbon in one of the products I work on and seeing unexpected behavior related to
Loadingcomponents.Loading overlays should only claim focus when the document is focused on
body.Focus a page control, activate a
Loadingcomponent withwithOverlay, and verify that focus remains on the page control. Verify that focus trapping still works when focus moves outside the active overlay.PR Checklist
As the author of this PR, before marking ready for review, confirm you:
Updated documentation and storybook examplesFollowed therequired v12 migration documentation
for any code change that affects v12, or struck through this item because
the PR does not affect v12
More details can be found in the pull request guide