From 9179f6209aa2434d0f779b3fd88e9c856ffbbcdd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?P=C3=A5l=20J=C3=B8rgensen?= Date: Thu, 3 Apr 2014 10:19:47 +0200 Subject: [PATCH] Added transparent background-color to title and description fields on intro-page --- css/questionset.css | 16 ++++++++++++++++ js/questionset.js | 2 +- library.json | 2 +- 3 files changed, 18 insertions(+), 2 deletions(-) diff --git a/css/questionset.css b/css/questionset.css index e63b276..923904a 100644 --- a/css/questionset.css +++ b/css/questionset.css @@ -65,9 +65,25 @@ font-weight: bold; text-align: center; } +.intro-page .title > span { + padding: 0 0.2em; + background: rgb(255,255,255); /* Fallback for browsers not supporting rgba */ + background: rgba(255,255,255,0.8); /* Gives WCAG contrast ratio of 5.6:1 with the current font color */ +} .intro-page .introduction { font-size: 1.25em; margin: 0 1em; + background: rgb(255,255,255); /* Fallback for browsers not supporting rgba */ + background: rgba(255,255,255,0.8); /* Gives WCAG contrast ratio of 5.6:1 with the current font color */ + padding: 0.2em; +} +/* Overrides whatever margins have been set in site-CSS, to avoid too much spacing + on description field, aswell as getting same padding on top and bottom of field */ +.intro-page .introduction > p { + margin: 0 0 0.5em 0; +} +.intro-page .introduction > p:last-child { + margin: 0; } .intro-page .buttons { margin: 3em auto; diff --git a/js/questionset.js b/js/questionset.js index ec4de30..50ed833 100644 --- a/js/questionset.js +++ b/js/questionset.js @@ -39,7 +39,7 @@ H5P.QuestionSet = function (options, contentId) { var texttemplate = '<% if (introPage.showIntroPage) { %>' + '
' + - '
<%= introPage.title %>
' + + '
<%= introPage.title %>
' + '
<%= introPage.introduction %>
' + ' ' + '
' + diff --git a/library.json b/library.json index 51bee2c..e842aee 100644 --- a/library.json +++ b/library.json @@ -3,7 +3,7 @@ "contentType": "question", "majorVersion": 1, "minorVersion": 0, - "patchVersion": 44, + "patchVersion": 45, "runnable": 1, "fullscreen": 0, "machineName": "H5P.QuestionSet",