From 3aba5ed0ce4f6ea345ff79b906f97d999cd32868 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 b12c2e9e9df..3ff79905ba7 100644 --- a/lib/outputrenderers.php +++ b/lib/outputrenderers.php @@ -2522,7 +2522,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'; }