fix(edit-monitor): fix minification of translations containing { }

This commit is contained in:
Bert Verhelst 2021-10-09 11:38:12 +02:00
parent c3c273f9df
commit b8093e909b
3 changed files with 11 additions and 6 deletions

View file

@ -328,11 +328,11 @@ export default {
},
bodyPlaceholder() {
return this.$t("BodyPlaceholder");
return this.decodeHtml(this.$t("BodyPlaceholder"));
},
headersPlaceholder() {
return this.$t("HeadersPlaceholder");
return this.decodeHtml(this.$t("HeadersPlaceholder"));
}
},
@ -490,6 +490,12 @@ export default {
addedNotification(id) {
this.monitor.notificationIDList[id] = true;
},
decodeHtml(html) {
const txt = document.createElement("textarea");
txt.innerHTML = html;
return txt.value;
}
},
};
</script>