Fix metrics fill theme color application #2797

This commit is contained in:
Jordy van Dortmont
2018-03-24 16:33:38 +01:00
parent 0fcd939f50
commit c66048d977
4 changed files with 31 additions and 28 deletions

View File

@@ -42,6 +42,9 @@ Chart.defaults.global.legend.display = false
module.exports = {
props: [
'metric',
'theme',
'theme-light',
'theme-dark'
],
data () {
return {
@@ -137,12 +140,12 @@ module.exports = {
labels: data_keys,
datasets: [{
data: _.values(this.data),
// backgroundColor: "{{ $theme_metrics }}",
// borderColor: "{{ color_darken($theme_metrics, -0.1) }}",
// pointBackgroundColor: "{{ color_darken($theme_metrics, -0.1) }}",
// pointBorderColor: "{{ color_darken($theme_metrics, -0.1) }}",
// pointHoverBackgroundColor: "{{ color_darken($theme_metrics, -0.2) }}",
// pointHoverBorderColor: "{{ color_darken($theme_metrics, -0.2) }}"
backgroundColor: this.themeLight,
borderColor: this.theme,
pointBackgroundColor: this.theme,
pointBorderColor: this.theme,
pointHoverBackgroundColor: this.themeDark,
pointHoverBorderColor: this.themeDark
}]
},
options: {