[ACA-2506] Header - Button does not have a role (#1229)

* Add aria label to avatar button

* Add tabindex 0 to make it tab focusable

* changed to button as div doesn't allow using tab for opening the menu
This commit is contained in:
Martin Muller
2019-10-17 18:53:56 +02:00
committed by Cilibiu Bogdan
parent 1c1a365ac9
commit 322cd27111

View File

@@ -1,8 +1,12 @@
<div title="{{ (profile$ | async)?.id }}">
<div class="current-user__full-name">{{ (profile$ | async)?.userName }}</div>
<div class="current-user__avatar am-avatar" [matMenuTriggerFor]="userMenu">
<button
mat-icon-button
class="current-user__avatar am-avatar"
[matMenuTriggerFor]="userMenu"
>
{{ (profile$ | async)?.initials }}
</div>
</button>
</div>
<mat-menu #userMenu="matMenu" [overlapTrigger]="false">