From 48fe138973d4a6e3756bd0d0dd10f3b6684969de Mon Sep 17 00:00:00 2001 From: Matthew Terentjevs Date: Sun, 9 Sep 2018 10:04:16 +0100 Subject: [PATCH 1/5] Adding front cover images --- bower.json | 8 ++++---- less/expose.less | 3 +-- properties.schema | 24 ++++++++++++++++++++++++ templates/expose.hbs | 4 +++- 4 files changed, 32 insertions(+), 7 deletions(-) diff --git a/bower.json b/bower.json index bd41763..095bcc1 100644 --- a/bower.json +++ b/bower.json @@ -1,14 +1,14 @@ { "name": "adapt-expose", "description": "Content is hidden behind covers. Click the cover and expose the content below. Range of animations. Demo available.", - "version": "1.1.3", + "version": "1.1.5", "framework": "^2.0.0", "displayName": "Expose", "component": "expose", "main": "/js/adapt-expose.js", - "homepage": "https://github.com/danielstorey/adapt-expose", - "repository": "git://github.com/danielstorey/adapt-expose.git", - "issues": "https://github.com/danielstorey/adapt-expose/issues", + "homepage": "https://github.com/elearningdifferently/adapt-expose", + "repository": "git://github.com/elearningdifferently/adapt-expose.git", + "issues": "https://github.com/elearningdifferently/adapt-expose/issues", "keywords": [ "adapt-plugin", "adapt-component" diff --git a/less/expose.less b/less/expose.less index ec0e598..e86bd25 100644 --- a/less/expose.less +++ b/less/expose.less @@ -66,8 +66,7 @@ transform: translateY(-50%); -webkit-backface-visibility: hidden; backface-visibility: hidden; - font-size: 24px; - + font-size: 26px; } .back, diff --git a/properties.schema b/properties.schema index 074a88e..31ce02f 100644 --- a/properties.schema +++ b/properties.schema @@ -67,6 +67,30 @@ "help": "The text to display on the front cover", "translatable": true }, + "_front_graphic": { + "type": "object", + "required": false, + "title": "Front Image", + "properties":{ + "alt": { + "type": "string", + "required": false, + "default": "", + "inputType": "Text", + "validators": [], + "help": "The alternative text for the front image", + "translatable": true + }, + "src": { + "type": "string", + "required": false, + "default": "", + "inputType": "Asset:image", + "validators": [], + "help": "Optional image which will be rendered on the items front" + } + } + }, "back": { "type": "object", "required": true, diff --git a/templates/expose.hbs b/templates/expose.hbs index 863b7fd..65fc891 100644 --- a/templates/expose.hbs +++ b/templates/expose.hbs @@ -8,8 +8,10 @@
-
+
+
{{#if front}} {{{a11y_text front}}} {{else}} ? {{/if}} +
{{#with back}} From fd14dfa95f65326aa779a568790f8a91e71d14cc Mon Sep 17 00:00:00 2001 From: Matthew Terentjevs Date: Sun, 9 Sep 2018 10:27:41 +0100 Subject: [PATCH 2/5] Adding changes to .less to give front page text some @primary-background --- less/expose.less | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/less/expose.less b/less/expose.less index e86bd25..10ffc02 100644 --- a/less/expose.less +++ b/less/expose.less @@ -54,6 +54,23 @@ padding: 0; text-align: center; color: @primary-color-inverted; + + .text-bg { + position: relative; + display: inline-block; + position: relative; + top: 50%; + width: 80%; + -webkit-transform: translateY(-50%); + -ms-transform: translateY(-50%); + transform: translateY(-50%); + -webkit-backface-visibility: hidden; + backface-visibility: hidden; + font-size: 26px; + background-color: @primary-color; + padding-top: 25px; + padding-bottom: 5px; + } .text { position: relative; From d802d15d763bef4b684ad2997ca699967b47c561 Mon Sep 17 00:00:00 2001 From: Matthew Terentjevs Date: Sun, 9 Sep 2018 10:28:23 +0100 Subject: [PATCH 3/5] Version up to apply updae --- bower.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bower.json b/bower.json index 095bcc1..335f235 100644 --- a/bower.json +++ b/bower.json @@ -1,7 +1,7 @@ { "name": "adapt-expose", "description": "Content is hidden behind covers. Click the cover and expose the content below. Range of animations. Demo available.", - "version": "1.1.5", + "version": "1.1.6", "framework": "^2.0.0", "displayName": "Expose", "component": "expose", From 0275d026898269d7800d29a3ead533e774ca4472 Mon Sep 17 00:00:00 2001 From: Matthew Terentjevs Date: Sun, 9 Sep 2018 10:56:57 +0100 Subject: [PATCH 4/5] Removing "alt" from front image and adding else statement --- properties.schema | 9 --------- templates/expose.hbs | 2 +- 2 files changed, 1 insertion(+), 10 deletions(-) diff --git a/properties.schema b/properties.schema index 31ce02f..b1653ca 100644 --- a/properties.schema +++ b/properties.schema @@ -72,15 +72,6 @@ "required": false, "title": "Front Image", "properties":{ - "alt": { - "type": "string", - "required": false, - "default": "", - "inputType": "Text", - "validators": [], - "help": "The alternative text for the front image", - "translatable": true - }, "src": { "type": "string", "required": false, diff --git a/templates/expose.hbs b/templates/expose.hbs index 65fc891..201a9e0 100644 --- a/templates/expose.hbs +++ b/templates/expose.hbs @@ -8,7 +8,7 @@
-
+
{{#if front}} {{{a11y_text front}}} {{else}} ? {{/if}}
From 7f09a74e24a3ed93af318a1c0aab8b2484e0c999 Mon Sep 17 00:00:00 2001 From: Matthew Terentjevs Date: Sun, 9 Sep 2018 11:12:02 +0100 Subject: [PATCH 5/5] Upping the version --- bower.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bower.json b/bower.json index 335f235..89ef5da 100644 --- a/bower.json +++ b/bower.json @@ -1,7 +1,7 @@ { "name": "adapt-expose", "description": "Content is hidden behind covers. Click the cover and expose the content below. Range of animations. Demo available.", - "version": "1.1.6", + "version": "1.1.7", "framework": "^2.0.0", "displayName": "Expose", "component": "expose",