mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 00:46:50 +02:00
MDL-5311 qtype_multichoice: replace label to a for clean button
To avoid behat errors with Firefox, the 'Clean my choice' has been changed from label to link (with role button).
This commit is contained in:
parent
30513f9740
commit
d5e084bcb6
4 changed files with 5 additions and 5 deletions
|
@ -300,8 +300,8 @@ class qtype_multichoice_single_renderer extends qtype_multichoice_renderer_base
|
|||
}
|
||||
// Adds an hidden radio that will be checked to give the impression the choice has been cleared.
|
||||
$clearchoiceradio = html_writer::empty_tag('input', $clearchoiceradioattrs);
|
||||
$clearchoiceradio .= html_writer::tag('label', get_string('clearchoice', 'qtype_multichoice'),
|
||||
['for' => $clearchoiceid]);
|
||||
$clearchoiceradio .= html_writer::link('', get_string('clearchoice', 'qtype_multichoice'),
|
||||
['for' => $clearchoiceid, 'role' => 'button']);
|
||||
|
||||
// Now wrap the radio and label inside a div.
|
||||
$result = html_writer::tag('div', $clearchoiceradio, ['id' => $clearchoicefieldname, 'class' => $cssclass]);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue