MDL-68864 qtype_multichoice: clearchoice button styles

- display the clearchoice link as a button to improve the way
it looks when using keyboard focus
This commit is contained in:
Bas Brands 2020-06-09 15:56:51 +02:00 committed by Jun Pataleta
parent 233eafd8eb
commit 5d5153906c
4 changed files with 2 additions and 23 deletions

View File

@ -307,7 +307,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::link('', get_string('clearchoice', 'qtype_multichoice'),
['for' => $clearchoiceid, 'role' => 'button', 'tabindex' => $linktabindex]);
['for' => $clearchoiceid, 'role' => 'button', 'tabindex' => $linktabindex,
'class' => 'btn btn-link ml-4 pl-1 mt-2']);
// Now wrap the radio and label inside a div.
$result = html_writer::tag('div', $clearchoiceradio, ['id' => $clearchoicefieldname, 'class' => $cssclass]);

View File

@ -305,14 +305,6 @@ body.path-question-type {
.que.multichoice .answer div.r1 .icon.fa-remove {
text-indent: 0;
}
.qtype_multichoice_clearchoice {
padding-top: 10px;
a {
cursor: pointer;
text-decoration: underline;
padding-left: 30px;
}
}
.formulation input[type="text"],
.formulation select {

View File

@ -15604,13 +15604,6 @@ body.path-question-type {
.que.multichoice .answer div.r1 .icon.fa-remove {
text-indent: 0; }
.qtype_multichoice_clearchoice {
padding-top: 10px; }
.qtype_multichoice_clearchoice a {
cursor: pointer;
text-decoration: underline;
padding-left: 30px; }
.formulation input[type="text"],
.formulation select {
width: auto;

View File

@ -15827,13 +15827,6 @@ body.path-question-type {
.que.multichoice .answer div.r1 .icon.fa-remove {
text-indent: 0; }
.qtype_multichoice_clearchoice {
padding-top: 10px; }
.qtype_multichoice_clearchoice a {
cursor: pointer;
text-decoration: underline;
padding-left: 30px; }
.formulation input[type="text"],
.formulation select {
width: auto;