From b6857348aadc38dcffd73e632d37b0af3f9e5d5a Mon Sep 17 00:00:00 2001 From: Michael Prentice Date: Mon, 21 Sep 2020 18:01:44 -0400 Subject: [PATCH] fix(icon): providing empty alt or aria-label attributes do not hide them from a11y - change behavior around how `aria-label` and `aria-hidden` is applied to match documentation - clarify documentation around `alt` and `aria-label` behavior - fix/improve Closure types - remove unused variable and out of date comments - replace blacklist with block-list in comments Fixes #10721 --- .../demoFontIconsWithClassnames/index.html | 18 ++--- .../demoFontIconsWithClassnames/script.js | 3 - src/components/icon/js/iconDirective.js | 68 ++++++++++--------- src/core/services/aria/aria.js | 14 ++-- 4 files changed, 53 insertions(+), 50 deletions(-) diff --git a/src/components/icon/demoFontIconsWithClassnames/index.html b/src/components/icon/demoFontIconsWithClassnames/index.html index 0bc4621a22..6032f24b13 100644 --- a/src/components/icon/demoFontIconsWithClassnames/index.html +++ b/src/components/icon/demoFontIconsWithClassnames/index.html @@ -8,11 +8,11 @@ + aria-label="{{ font.name + '-' + it.size }}" + class="step">
- {{ it.size }}px + {{ it.size }}px
@@ -20,16 +20,16 @@