Merge branch 'MDL-62143-master' of git://github.com/damyon/moodle
authorJun Pataleta <jun@moodle.com>
Tue, 5 Mar 2019 01:44:59 +0000 (09:44 +0800)
committerJun Pataleta <jun@moodle.com>
Tue, 5 Mar 2019 01:44:59 +0000 (09:44 +0800)
lib/outputrenderers.php
lib/templates/navbar.mustache

index 17f0d7e..28597f8 100644 (file)
@@ -3437,6 +3437,9 @@ EOD;
             if ($item->hidden) {
                 $attributes['class'] = 'dimmed_text';
             }
+            if ($item->is_last()) {
+                $attributes['aria-current'] = 'page';
+            }
             $content = html_writer::tag('span', $content, array('itemprop' => 'title'));
             $content = html_writer::link($item->action, $content, $attributes);
 
index 207081f..2998888 100644 (file)
@@ -68,7 +68,7 @@
         {{#get_items}}
             {{#has_action}}
                 <li class="breadcrumb-item{{#is_hidden}} dimmed_text{{/is_hidden}}">
-                    <a href="{{{action}}}" {{#get_title}}title="{{get_title}}"{{/get_title}}>{{{get_content}}}</a>
+                    <a href="{{{action}}}" {{#is_last}}aria-current="page"{{/is_last}} {{#get_title}}title="{{get_title}}"{{/get_title}}>{{{get_content}}}</a>
                 </li>
             {{/has_action}}
             {{^has_action}}