mirror of
https://github.com/Luzifer/mondash.git
synced 2024-12-22 12:01:19 +00:00
Fix: Properly display newlines in metric description
Signed-off-by: Knut Ahlers <knut@ahlers.me>
This commit is contained in:
parent
45cce5eb67
commit
324b724f03
1 changed files with 7 additions and 1 deletions
|
@ -13,7 +13,7 @@
|
|||
</b-row>
|
||||
|
||||
<b-card-text>
|
||||
{{ metric.description }}
|
||||
{{ description }}
|
||||
</b-card-text>
|
||||
|
||||
<graph :metric="metric" v-if="!metric.config.hide_mad"></graph>
|
||||
|
@ -46,6 +46,12 @@ export default {
|
|||
name: 'metric',
|
||||
props: ['metric'],
|
||||
|
||||
computed: {
|
||||
description() {
|
||||
return this.metric.description.replace(new RegExp(/\n/, 'g'), '<br>')
|
||||
},
|
||||
},
|
||||
|
||||
components: { graph, historyBar },
|
||||
|
||||
methods: {
|
||||
|
|
Loading…
Reference in a new issue