Make sure styles are not being added twice to questions [HFP-56]
parent
568e0992e5
commit
163e314059
|
@ -455,7 +455,7 @@ H5P.QuestionSet = function (options, contentId, contentData) {
|
||||||
*/
|
*/
|
||||||
var resetTask = function () {
|
var resetTask = function () {
|
||||||
|
|
||||||
// Clear previous state to ensure questions are created cleanly
|
// Clear previous state to ensure questions are created cleanly
|
||||||
contentData.previousState = [];
|
contentData.previousState = [];
|
||||||
|
|
||||||
showingSolutions = false;
|
showingSolutions = false;
|
||||||
|
@ -827,6 +827,9 @@ H5P.QuestionSet = function (options, contentId, contentData) {
|
||||||
for (var i = 0; i < questionInstances.length; i++) {
|
for (var i = 0; i < questionInstances.length; i++) {
|
||||||
var question = questionInstances[i];
|
var question = questionInstances[i];
|
||||||
|
|
||||||
|
// Make sure styles are not being added twice
|
||||||
|
$('.question-container:eq(' + i + ')', $myDom).attr('class', 'question-container');
|
||||||
|
|
||||||
question.attach($('.question-container:eq(' + i + ')', $myDom));
|
question.attach($('.question-container:eq(' + i + ')', $myDom));
|
||||||
|
|
||||||
// Listen for image resize
|
// Listen for image resize
|
||||||
|
|
Loading…
Reference in New Issue