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
the content of the alert when read by screen reader always starts with Close, followed by the ng-template slot content. As the users of the ng-bootstrap cannot swap that rendering order (as opposed to BS users), this seems to impact the user experience greatly, while it can be easily fixed:
That is totally valid. Even Bootstrap provides markup guideline rendering the close button after the content. (See here)
<divclass="alert alert-warning alert-dismissible fade show" role="alert"><strong>Holy guacamole!</strong> You should check in on some of those fields below.
<buttontype="button" class="close" data-dismiss="alert" aria-label="Close"><spanaria-hidden="true">×</span></button></div>
Order between the close button and `<ng-content>` used to be wrong. Content needs to render first in order for a11y/screen-reader to properly read it before the close button.
Fixes#3171
Bug description:
With the current content rendering order within alert component template:
the content of the alert when read by screen reader always starts with
Close
, followed by theng-template
slot content. As the users of theng-bootstrap
cannot swap that rendering order (as opposed to BS users), this seems to impact the user experience greatly, while it can be easily fixed:Link to minimally-working StackBlitz that reproduces the issue:
https://ng-bootstrap.github.io/#/components/alert/examples
Versions of Angular, ng-bootstrap and Bootstrap:
Angular:
n/a
ng-bootstrap:
4.1.2
Bootstrap:
n/a
The text was updated successfully, but these errors were encountered: