From cc9a537bd230bbd095148a20dc00e430236258a0 Mon Sep 17 00:00:00 2001 From: Jun Pataleta Date: Mon, 11 Sep 2023 13:57:59 +0800 Subject: [PATCH 1/2] MDL-77651 core: Hide left/right arrow characters for link_arrow_xx() * The arrow characters in link_arrow_right() and link_arrow_left() functions get announced by screen readers. This causes confusion and is unnecessary. --- lib/weblib.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/weblib.php b/lib/weblib.php index 0de326bc066..733ea344b8a 100644 --- a/lib/weblib.php +++ b/lib/weblib.php @@ -2402,7 +2402,7 @@ function link_arrow_right($text, $url='', $accesshide=false, $addclass='', $addp if (!$url) { $arrowclass .= $addclass; } - $arrow = ''.$OUTPUT->rarrow().''; + $arrow = ''; $htmltext = ''; if ($text) { $htmltext = ''.$text.' '; @@ -2444,7 +2444,7 @@ function link_arrow_left($text, $url='', $accesshide=false, $addclass='', $addpa if (! $url) { $arrowclass .= $addclass; } - $arrow = ''.$OUTPUT->larrow().''; + $arrow = ''; $htmltext = ''; if ($text) { $htmltext = ' '.$text.''; From 11e0579540dbd2efd695e9d7dba029866d690002 Mon Sep 17 00:00:00 2001 From: Jun Pataleta Date: Mon, 11 Sep 2023 13:58:56 +0800 Subject: [PATCH 2/2] MDL-77651 calendar: Hide left/right arrow characters * Hide the arrow characters for the calendar templates so they won't be read out by screen readers and avoid confusion for screen reader users. --- calendar/templates/day_navigation.mustache | 4 ++-- calendar/templates/month_navigation.mustache | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/calendar/templates/day_navigation.mustache b/calendar/templates/day_navigation.mustache index d2c7ecad8fc..065d32532ff 100644 --- a/calendar/templates/day_navigation.mustache +++ b/calendar/templates/day_navigation.mustache @@ -41,7 +41,7 @@ }} data-month="{{previousperiod.mon}}"{{! }} data-day="{{previousperiod.mday}}"{{! }}> - {{{larrow}}} +   {{previousperiodname}} @@ -58,7 +58,7 @@ }}> {{nextperiodname}}   - {{{rarrow}}} + diff --git a/calendar/templates/month_navigation.mustache b/calendar/templates/month_navigation.mustache index 89dcfcf13bc..946a0c7fa99 100644 --- a/calendar/templates/month_navigation.mustache +++ b/calendar/templates/month_navigation.mustache @@ -41,7 +41,7 @@ }} data-month="{{previousperiod.mon}}"{{! }} data-drop-zone="nav-link" {{! }}> - {{{larrow}}} +   {{previousperiodname}} @@ -63,7 +63,7 @@ }}> {{nextperiodname}}   - {{{rarrow}}} +