[ADF-4970] Improve breadcrumb accessibility (#5187)

* [ADF-4970] improve accessibility for dropdown-breadcrumb

- allow keyboard only control

* [ADF-4970] add accessibility improvements to breadcrumb.component

* [ADF-4970] more fixes & preventDefault for click event

* [ADF-4970] better keyboard-only experience when selecting a breadcrumb option

* [ADF-4970] set focus color on content-node-selector breadcrumb

* [ADF-4970] set aria-current to location

* [ADF-4970] extra check - fix unit test
This commit is contained in:
Suzana Dirla
2019-10-25 12:20:22 +03:00
committed by Eugenio Romano
parent 0aed1845a0
commit d35e8d8523
9 changed files with 24 additions and 17 deletions

View File

@@ -131,6 +131,7 @@ export class BreadcrumbComponent implements OnInit, OnChanges, OnDestroy {
open(): void {
if (this.dropdown) {
this.dropdown.open();
this.dropdown.focus();
}
}
@@ -178,7 +179,7 @@ export class BreadcrumbComponent implements OnInit, OnChanges, OnDestroy {
}
onRoutePathClick(route: PathElementEntity, event?: Event): void {
if (event) {
if (event && event.type === 'click') {
event.preventDefault();
}