From 4293339fc91c4cc2e21fee9f0c87452dddf93d1b Mon Sep 17 00:00:00 2001 From: Shamim Rezaie Date: Tue, 10 Mar 2020 16:30:08 +1100 Subject: [PATCH] MDL-68135 output: remove the presentation role from user pic "presentation" is not a valid role for the img element. Moreover, it doesn't make sense to have both role="presentation" and aria-hidden="true" for an element at the same time. For more info please see: https://timwright.org/blog/2016/11/19/difference-rolepresentation-aria-hiddentrue/ --- lib/outputrenderers.php | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/outputrenderers.php b/lib/outputrenderers.php index 5f906948902..f75de0211ca 100644 --- a/lib/outputrenderers.php +++ b/lib/outputrenderers.php @@ -2526,7 +2526,6 @@ class core_renderer extends renderer_base { $attributes = array('src' => $src, 'class' => $class, 'width' => $size, 'height' => $size); if (!$userpicture->visibletoscreenreaders) { - $attributes['role'] = 'presentation'; $alt = ''; $attributes['aria-hidden'] = 'true'; }