From b32a3ceb54f6331d205879a5d6db7b726b20fb5a Mon Sep 17 00:00:00 2001 From: Frode Petterson Date: Fri, 3 May 2013 15:24:17 +0200 Subject: [PATCH 1/2] Fixed missing translations. Fixed video-support. Removed random order and initial question index. --- css/questionset.css | 18 ++++++++++++++++-- js/questionset.js | 3 ++- semantics.json | 20 +++++++------------- 3 files changed, 25 insertions(+), 16 deletions(-) diff --git a/css/questionset.css b/css/questionset.css index 416217c..953313f 100644 --- a/css/questionset.css +++ b/css/questionset.css @@ -1,3 +1,6 @@ +.questionset, .intro-page, .questionset-results { + overflow: hidden; +} .questionset.hidden { display: none; } @@ -49,7 +52,7 @@ overflow: hidden; } -.qs-footer .button, .qs-startbutton, .qs-finishbutton, .questionset-results .button { +.qs-footer .button, .qs-startbutton, .qs-finishbutton, .questionset-results .button, .video-container > .button { display: block; line-height: 1.25em; padding: 0.25em 1em; @@ -66,7 +69,7 @@ background-image: -ms-linear-gradient(top, #3999ea, #267ec9); filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#3999ea', endColorstr='#267ec9',GradientType=0); } -.qs-footer .button:hover, .qs-startbutton:hover, .questionset-results .button:hover { +.qs-footer .button:hover, .qs-startbutton:hover, .questionset-results .button:hover, .video-container > .button:hover { text-decoration: none; color: #fff; box-shadow: 0 0 0.5em #267ec9; @@ -84,6 +87,17 @@ .questionset-results .qs-finishbutton { display: none; } +.video-container { + position: relative; +} +.video-container > video { + background-color: #000; +} +.video-container > .button { + position: absolute; + top: 0.5em; + right: 0.5em; +} .qs-progress { text-align: center; diff --git a/js/questionset.js b/js/questionset.js index 8ace8e4..2a52995 100644 --- a/js/questionset.js +++ b/js/questionset.js @@ -76,7 +76,7 @@ H5P.QuestionSet = function (options, contentId) { passPercentage: 50, questions: [], introPage: { - showIntroPage: true, + showIntroPage: false, title: '', introduction: '', startButtonText: 'Start' @@ -239,6 +239,7 @@ H5P.QuestionSet = function (options, contentId) { if (params.endGame.showAnimations) { var videoData = success ? params.endGame.successVideo : params.endGame.failVideo; if (videoData) { + $myDom.children().hide(); var $videoContainer = $('
').appendTo($myDom); var video = new H5P.Video({ diff --git a/semantics.json b/semantics.json index acd3f6b..5615235 100644 --- a/semantics.json +++ b/semantics.json @@ -5,19 +5,6 @@ "label": "Title", "description": "Question set title (optional)." }, - { - "name": "randomOrder", - "type": "boolean", - "label": "Randomize order", - "description": "Whether questions should be shown in random order." - }, - { - "name": "initialQuestion", - "type": "number", - "label": "Initial question", - "description": "Which question to start with. Count from 0.", - "default": 0 - }, { "name": "backgroundImage", "type": "image", @@ -185,6 +172,13 @@ "default": "This didn't go so well.", "description": "This comment will be displayed after the score if the user has failed the quiz." }, + { + "name": "solutionButtonText", + "type": "text", + "label": "Solution button label", + "default": "Show solution", + "description": "Text for the solution button." + }, { "name": "finishButtonText", "type": "text", From 8deb92bb8333de81eff37b9d8bcd2ed2f2d71546 Mon Sep 17 00:00:00 2001 From: Frode Petterson Date: Fri, 3 May 2013 15:31:35 +0200 Subject: [PATCH 2/2] Upping the patch level. --- library.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library.json b/library.json index 0c865da..8ed289f 100644 --- a/library.json +++ b/library.json @@ -3,7 +3,7 @@ "contentType": "question", "majorVersion": 1, "minorVersion": 0, - "patchVersion": 7, + "patchVersion": 8, "runnable": 1, "machineName": "H5P.QuestionSet", "author": "Amendor AS",