From da154bb58ffac7e469a0ccbbb838f03ddf8afe1b Mon Sep 17 00:00:00 2001 From: Martin Muller Date: Thu, 24 Oct 2019 13:58:03 +0200 Subject: [PATCH] [ADF-4972] CLONE - Header - sidenav menu button aria-label not translatable (#5178) * Make aria label fron header sidenav toggle button translateable * Make aria label fron header sidenav toggle button translateable * Make aria label fron header sidenav toggle button translateable --- lib/core/i18n/en.json | 5 ++++- lib/core/layout/components/header/header.component.html | 5 +++-- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/lib/core/i18n/en.json b/lib/core/i18n/en.json index 11d2cbe7cf..97d900c683 100644 --- a/lib/core/i18n/en.json +++ b/lib/core/i18n/en.json @@ -43,7 +43,10 @@ }, "CORE": { "HEADER": { - "LOGO_ARIA": "Company Logo" + "LOGO_ARIA": "Company Logo", + "ACCESSIBILITY": { + "SIDEBAR_TOGGLE_BUTTON_ARIA_LABEL": "Toggle Menu" + } }, "FILE_SIZE": { "BYTES": "Bytes", diff --git a/lib/core/layout/components/header/header.component.html b/lib/core/layout/components/header/header.component.html index 5ac27fcc2f..283e874c60 100644 --- a/lib/core/layout/components/header/header.component.html +++ b/lib/core/layout/components/header/header.component.html @@ -10,7 +10,7 @@ class="mat-icon-button adf-menu-icon" mat-icon-button (click)="toggleMenu()" - aria-label="Toggle Menu"> + [attr.aria-label]="'CORE.HEADER.ACCESSIBILITY.SIDEBAR_TOGGLE_BUTTON_ARIA_LABEL' | translate"> + [attr.aria-label]="'CORE.HEADER.ACCESSIBILITY.SIDEBAR_TOGGLE_BUTTON_ARIA_LABEL' | translate"> + >