fix(ui-alerts,console): remove Alert live-region role warning - #2664
Open
ToMESSKa wants to merge 1 commit into
Open
fix(ui-alerts,console): remove Alert live-region role warning#2664ToMESSKa wants to merge 1 commit into
ToMESSKa wants to merge 1 commit into
Conversation
Contributor
|
Contributor
Visual regression report
Diff images (33)alert.png — baseline no longer producedavatar.png — baseline no longer producedbadge.png — baseline no longer producedbillboard.png — baseline no longer producedbreadcrumb.png — baseline no longer producedbutton-and-derivatives.png — baseline no longer producedbyline.png — baseline no longer producedcalendar.png — baseline no longer producedcheckbox.png — baseline no longer producedcheckboxgroup.png — baseline no longer producedcolorpicker.png — baseline no longer producedcontextview.png — baseline no longer producedcustom-and-lucide-icons.png — baseline no longer produceddateinput-dateinput2.png — baseline no longer produceddatetimeinput.png — baseline no longer produceddiff-demo.png — 6324 pixels differdrilldown.png — baseline no longer producedfiledrop.png — baseline no longer producedform-errors.png — baseline no longer producedheading.png — baseline no longer producedimg.png — baseline no longer producedlink.png — baseline no longer producedmenu.png — baseline no longer producedmetric-pill-tag-timeselect-text.png — baseline no longer producedoptions.png — baseline no longer producedpagination.png — baseline no longer producedprogressbar.png — baseline no longer producedselect-simpleselect.png — baseline no longer producedtable.png — baseline no longer producedtabs.png — baseline no longer producedtooltip.png — baseline no longer producedtreebrowser.png — baseline no longer producedview.png — baseline no longer producedBaselines come from the |
ToMESSKa
force-pushed
the
INSTUI-5131-alert-wants-role-alert-added-to-live-region
branch
from
July 31, 2026 12:12
53103e2 to
240bcda
Compare
ToMESSKa
marked this pull request as ready for review
July 31, 2026 12:35
matyasf
requested changes
Aug 3, 2026
| <Figure.Item>aria-live="polite" alerts will only be announced if the user is not currently doing anything. Polite should be used in most situations involving live regions that present new info to users</Figure.Item> | ||
| <Figure.Item>aria-live="assertive" alerts will be announced to the user as soon as possible, but not necessarily immediately. Assertive should be used if there is information that a user must know about right away, for example, a warning message in a form that does validation on the fly</Figure.Item> | ||
| <Figure.Item>The aria-atomic=BOOLEAN is used to set whether or not the screen reader should always present the live region as a whole, even if only part of the region changes. The possible settings are: false or true. The default setting is false.</Figure.Item> | ||
| <Figure.Item>If the `liveRegion` element has a `role`, match it to the `liveRegionPoliteness` level: use `role="status"` for `polite` and `role="alert"` for `assertive`.</Figure.Item> |
Collaborator
There was a problem hiding this comment.
hmm this is not the best description, its more complicated. Please add this:
<Figure.Item>
For the liveRegion DOM element, note that the role prop adds implicit ARIA attributes, but these are not applied, unless you set liveRegionPoliteness or isLiveRegionAtomic to undefined.
</Figure.Item>
Contributor
Author
There was a problem hiding this comment.
@matyasf liveRegionPoliteness and isLiveRegionAtomic both have default values.
65 static defaultProps = {
...
72 liveRegionPoliteness: 'assertive',
73 isLiveRegionAtomic: false,
...
76 }
So aria-live and aria-atomic are always explicitly set even if these props are undefined, e.g.:
<div>
<div className="alerts-container" id="live-region"></div>
<Alert
variant="info"
renderCloseButtonLabel="Dismiss alert"
liveRegion={() => document.getElementById("live-region")}
>
Just an alert.
</Alert>
</div>
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.

INSTUI-5131
ISSUE:
role="alert"added to live region #2276TEST PLAN:
packages/__docs__/src/index.htmlafter line 4 (webpack 5 doesn't provideprocessin the browser so typeof process resolves to "undefined" inpackages/console/src/console.tsand log messages are not emitted)