Skip to content

Commit

Permalink
Ensuring that the message “There were no items to show” is announced …
Browse files Browse the repository at this point in the history
…to the screen reader when necessary
  • Loading branch information
Andrea-Guevara authored and tdonohue committed Dec 19, 2024
1 parent 14680b0 commit 75260b0
Showing 1 changed file with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,11 @@
</div>
<div class="treeview-container">
<ds-themed-loading *ngIf="loading | async" [showMessage]="false"></ds-themed-loading>
<h2 *ngIf="!(loading | async) && dataSource.data.length === 0" class="h4 text-center text-muted mt-4" >
<span>{{'vocabulary-treeview.search.no-result' | translate}}</span>
</h2>
<div aria-live="polite">
<h2 *ngIf="!(loading | async) && dataSource.data.length === 0" class="h4 text-center text-muted mt-4" >
<span>{{'vocabulary-treeview.search.no-result' | translate}}</span>
</h2>
</div>
<cdk-tree [dataSource]="dataSource" [treeControl]="treeControl">
<!-- Leaf node -->
<cdk-tree-node *cdkTreeNodeDef="let node" cdkTreeNodePadding class="d-flex">
Expand Down

0 comments on commit 75260b0

Please sign in to comment.