Fix Bulk Access Management usability issues

- Added aria-labels to trash & select bitstream icon
- Added aria-labels ui-switch components (had to upgrade ngx-ui-switch to 14.1.0)
- Fixed aria-controls pointing to non-existing ids
- Fixed bulk-access-browse not having the tab role on it's tabs
- Fixed role="tablist" not having direct role="tab" by adding role="presentation" on the li elements
- Fixed aria-expanded being set to true when collapsed and backwards for BulkAccessBrowseComponent & BulkAccessSettingsComponent
This commit is contained in:
Alexandre Vryghem
2023-11-26 21:28:12 +01:00
parent cc71d60ebb
commit c300123b78
7 changed files with 82 additions and 63 deletions

View File

@@ -4,10 +4,11 @@
<ds-alert
*ngIf="titleMessage"
[type]="AlertType.Info"
[content]="titleMessage">
[content]="titleMessage"
class="d-block pb-3">
</ds-alert>
<div class="row mt-5">
<div class="row">
<div class="col-12 col-md-6 border-right d-flex flex-column justify-content-between">
<div>
@@ -16,6 +17,7 @@
{{ 'access-control-item-header-toggle' | translate }}
</h4>
<ui-switch
[ariaLabel]="(state.bitstream.toggleStatus ? 'access-control-item-toggle.disable' : 'access-control-item-toggle.enable') | translate"
[(ngModel)]="state.item.toggleStatus"
(ngModelChange)="handleStatusChange('item', $event)">
</ui-switch>
@@ -69,6 +71,7 @@
{{'access-control-bitstream-header-toggle' | translate}}
</h4>
<ui-switch
[ariaLabel]="(state.bitstream.toggleStatus ? 'access-control-bitstream-toggle.disable' : 'access-control-bitstream-toggle.enable') | translate"
[(ngModel)]="state.bitstream.toggleStatus"
(ngModelChange)="handleStatusChange('bitstream', $event)">
</ui-switch>
@@ -99,6 +102,7 @@
<button
*ngIf="itemRD"
[attr.aria-label]="'access-control-bitstreams-select' | translate"
[disabled]="!state.bitstream.toggleStatus || state.bitstream.changesLimit !== 'selected'"
(click)="openSelectBitstreamsModal(itemRD.payload)"
class="btn btn-outline-dark border-0" type="button">