Commit f922fedb authored by Chenu Denis's avatar Chenu Denis

[fix] Other in multiple choice

parent de73329b
......@@ -83,6 +83,9 @@ table.ls-answers thead th,table.ls-answers thead td,table.ls-answers .ls-heading
}
/* hide (then disable tab) for input other in multiple choice */
.checkbox-text-item .other-checkbox[aria-hidden]{display:none}
.checkbox-text-item .checkbox-item .other-checkbox[aria-hidden] + label::before {display:none}
.checkbox-text-item .checkbox-item .other-checkbox[aria-hidden] + label::after {display:none}
/* group system : need fix for panel */
.panel .panel.question-container{border:0 none transparent;
-webkit-box-shadow: initial;
......
......@@ -2,6 +2,7 @@ var skelVanilla = {
init : function (options) {
this.addCheckedClass();
this.otherListRadio();
this.otherListCheckbox();
this.addHoverColumn();
if(options.removeBack) {
this.removeBack();
......@@ -143,5 +144,16 @@ var skelVanilla = {
$(this).find("input[type=radio]").click();
$(this).find("input[type=text]").focus();
});
},
otherListCheckbox : function() {
/* Disable false checkbox, and never remove user entered value … */
$(document).ready(function(){
$('li.checkbox-text-item [type=checkbox]').each(function(){
$(this).prop('disabled',true);
});
$('li.checkbox-text-item label').each(function(){
$(this).attr('for',$(this).attr('for').replace('othercbox', 'other'));
});
});
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment