MDL-73386 mod_quiz: Use plain text for quiz navigation fake block title

* No need to enclose the title of the quiz navigation fake block in
a span tag. The block title also gets appended to the skip link which
means that a block title with a span tag assigned with an identifier
can cause duplicate ID errors on the DOM.
This commit is contained in:
Jun Pataleta
2022-05-21 00:33:46 +08:00
parent 2affa30359
commit 4bdedd7d56
+1 -2
View File
@@ -1889,8 +1889,7 @@ class quiz_attempt {
$bc = new block_contents();
$bc->attributes['id'] = 'mod_quiz_navblock';
$bc->attributes['role'] = 'navigation';
$bc->attributes['aria-labelledby'] = 'mod_quiz_navblock_title';
$bc->title = html_writer::span(get_string('quiznavigation', 'quiz'), '', array('id' => 'mod_quiz_navblock_title'));
$bc->title = get_string('quiznavigation', 'quiz');
$bc->content = $output->navigation_panel($panel);
return $bc;
}