[ACA-2602]- Datatable - Selected state properly announced (#5459)

* chore: selected row now announces state

* chore: removal of tabindex on icon button
This commit is contained in:
Mark Steadman
2020-02-09 15:22:56 -06:00
committed by GitHub
parent f54bc24317
commit 3459c98bd0
2 changed files with 6 additions and 2 deletions

View File

@@ -67,7 +67,11 @@ export class DataTableRowComponent implements FocusableOption {
if (!this.row) {
return null;
}
return this.row.getValue('name') || '';
if (this.row.isSelected) {
return this.row.getValue('name') + ' selected' || '';
} else {
return this.row.getValue('name') || '';
}
}
@HostBinding('attr.tabindex')

View File

@@ -107,7 +107,7 @@
adf-drop-zone dropTarget="cell" [dropColumn]="col" [dropRow]="row">
<div *ngIf="!col.template" class="adf-datatable-cell-container">
<ng-container [ngSwitch]="col.type">
<div *ngSwitchCase="'image'" class="adf-cell-value" tabindex="0">
<div *ngSwitchCase="'image'" class="adf-cell-value">
<mat-icon *ngIf="isIconValue(row, col); else no_iconvalue">{{ asIconValue(row, col) }}
</mat-icon>
<ng-template #no_iconvalue>