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

pull/529/head
Bert Verhelst 3 years ago
parent c3c273f9df
commit b8093e909b

@ -277,17 +277,16 @@ export default {
promosmsTypeEco: "SMS ECO - cheap but slow and often overloaded. Limited only to Polish recipients.", promosmsTypeEco: "SMS ECO - cheap but slow and often overloaded. Limited only to Polish recipients.",
promosmsTypeFlash: "SMS FLASH - Message will automatically show on recipient device. Limited only to Polish recipients.", promosmsTypeFlash: "SMS FLASH - Message will automatically show on recipient device. Limited only to Polish recipients.",
promosmsTypeFull: "SMS FULL - Premium tier of SMS, You can use Your Sender Name (You need to register name first). Reliable for alerts.", promosmsTypeFull: "SMS FULL - Premium tier of SMS, You can use Your Sender Name (You need to register name first). Reliable for alerts.",
promosmsTypeFull: "SMS SPEED - Highest priority in system. Very quick and reliable but costly (about twice of SMS FULL price).", promosmsTypeSpeed: "SMS SPEED - Highest priority in system. Very quick and reliable but costly (about twice of SMS FULL price).",
promosmsPhoneNumber: "Phone number (for Polish recipient You can skip area codes)", promosmsPhoneNumber: "Phone number (for Polish recipient You can skip area codes)",
promosmsSMSSender: "SMS Sender Name : Pre-registred name or one of defaults: InfoSMS, SMS Info, MaxSMS, INFO, SMS", promosmsSMSSender: "SMS Sender Name : Pre-registred name or one of defaults: InfoSMS, SMS Info, MaxSMS, INFO, SMS",
// End notification form // End notification form
"Status Page": "Status Page",
Method: "Method", Method: "Method",
Body: "Body", Body: "Body",
Headers: "Headers", Headers: "Headers",
PushUrl: "Push URL", PushUrl: "Push URL",
HeadersInvalidFormat: "Headers do not have a valid format: \"key: value <new line> key: value <new line>...\"", HeadersInvalidFormat: "Headers do not have a valid format: \"key: value <new line> key: value <new line>...\"",
BodyInvalidFormat: "The request body is not valid JSON: ", BodyInvalidFormat: "The request body is not valid JSON: ",
BodyPlaceholder: "{\n\t\"id\": 124357,\n\t\"username\": \"admin\",\n\t\"password\": \"myAdminPassword\"\n}", BodyPlaceholder: "&lbrace;\n\t\"id\": 124357,\n\t\"username\": \"admin\",\n\t\"password\": \"myAdminPassword\"\n&rbrace;",
HeadersPlaceholder: "Authorization: Bearer abc123\nContent-Type: application/json", HeadersPlaceholder: "Authorization: Bearer abc123\nContent-Type: application/json",
}; };

@ -204,6 +204,6 @@ export default {
PushUrl: "Push URL", PushUrl: "Push URL",
HeadersInvalidFormat: "Headers hebben een incorrect formaat: \"key: waarde <new line> key: waarde <new line>...\"", HeadersInvalidFormat: "Headers hebben een incorrect formaat: \"key: waarde <new line> key: waarde <new line>...\"",
BodyInvalidFormat: "De request body is geen geldige JSON: ", BodyInvalidFormat: "De request body is geen geldige JSON: ",
BodyPlaceholder: "{\n\t\"id\": 124357,\n\t\"gebruikersnaam\": \"admin\",\n\t\"wachtwoord\": \"mijnAdminWachtwoord\"\n}", BodyPlaceholder: "&lbrace;\n\t\"id\": 124357,\n\t\"gebruikersnaam\": \"admin\",\n\t\"wachtwoord\": \"mijnAdminWachtwoord\"\n&rbrace;",
HeadersPlaceholder: "Authorization: Bearer abc123\nContent-Type: application/json", HeadersPlaceholder: "Authorization: Bearer abc123\nContent-Type: application/json",
}; };

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

Loading…
Cancel
Save