diff options
Diffstat (limited to 'src/components')
-rw-r--r-- | src/components/DynamicTheme.vue | 8 | ||||
-rw-r--r-- | src/components/Message.vue | 6 |
2 files changed, 12 insertions, 2 deletions
diff --git a/src/components/DynamicTheme.vue b/src/components/DynamicTheme.vue index cf9963b..2ccb47b 100644 --- a/src/components/DynamicTheme.vue +++ b/src/components/DynamicTheme.vue | |||
@@ -25,7 +25,13 @@ export default { | |||
25 | getVars: function (theme) { | 25 | getVars: function (theme) { |
26 | let vars = []; | 26 | let vars = []; |
27 | for (const themeVars in theme) { | 27 | for (const themeVars in theme) { |
28 | vars.push(`--${themeVars}: ${theme[themeVars]}`); | 28 | let value = `${theme[themeVars]}`; |
29 | if (!value) { | ||
30 | value = "inital"; | ||
31 | } else if (themeVars == "background-image") { | ||
32 | value = `url(${theme[themeVars]})`; | ||
33 | } | ||
34 | vars.push(`--${themeVars}: ${value}`); | ||
29 | } | 35 | } |
30 | return vars.join(";"); | 36 | return vars.join(";"); |
31 | }, | 37 | }, |
diff --git a/src/components/Message.vue b/src/components/Message.vue index 2c3df40..d007d3e 100644 --- a/src/components/Message.vue +++ b/src/components/Message.vue | |||
@@ -3,7 +3,11 @@ | |||
3 | <div v-if="message.title" class="message-header"> | 3 | <div v-if="message.title" class="message-header"> |
4 | <p>{{ message.title }}</p> | 4 | <p>{{ message.title }}</p> |
5 | </div> | 5 | </div> |
6 | <div v-if="message.content" class="message-body" v-html="message.content"></div> | 6 | <div |
7 | v-if="message.content" | ||
8 | class="message-body" | ||
9 | v-html="message.content" | ||
10 | ></div> | ||
7 | </article> | 11 | </article> |
8 | </template> | 12 | </template> |
9 | 13 | ||