From 7a109689d96a4ffdeee99776a0c44671e88be4f7 Mon Sep 17 00:00:00 2001 From: Adam Stachowicz Date: Wed, 1 Sep 2021 21:17:50 +0200 Subject: [PATCH] Make `Resp. Time (ms)` and `N/A` i18n --- src/components/PingChart.vue | 2 +- src/components/Uptime.vue | 2 +- src/languages/en.js | 4 +++- src/pages/Details.vue | 4 ++-- 4 files changed, 7 insertions(+), 5 deletions(-) diff --git a/src/components/PingChart.vue b/src/components/PingChart.vue index 8f53ea76..0baa9881 100644 --- a/src/components/PingChart.vue +++ b/src/components/PingChart.vue @@ -85,7 +85,7 @@ export default { y: { title: { display: true, - text: "Resp. Time (ms)", + text: this.$t("respTime"), }, offset: false, grid: { diff --git a/src/components/Uptime.vue b/src/components/Uptime.vue index b1f3a018..a4bf22f6 100644 --- a/src/components/Uptime.vue +++ b/src/components/Uptime.vue @@ -22,7 +22,7 @@ export default { return Math.round(this.$root.uptimeList[key] * 10000) / 100 + "%"; } - return "N/A" + return this.$t("notAvailableShort") }, color() { diff --git a/src/languages/en.js b/src/languages/en.js index 2781ba81..f0e4ae96 100644 --- a/src/languages/en.js +++ b/src/languages/en.js @@ -106,5 +106,7 @@ export default { "Resource Record Type": "Resource Record Type", "Last Result": "Last Result", "Create your admin account": "Create your admin account", - "Repeat Password": "Repeat Password" + "Repeat Password": "Repeat Password", + respTime: "Resp. Time (ms)", + notAvailableShort: "N/A" } diff --git a/src/pages/Details.vue b/src/pages/Details.vue index 44cac818..badcc687 100644 --- a/src/pages/Details.vue +++ b/src/pages/Details.vue @@ -238,7 +238,7 @@ export default { return this.lastHeartBeat.ping; } - return "N/A" + return this.$t("notAvailableShort") }, avgPing() { @@ -246,7 +246,7 @@ export default { return this.$root.avgPingList[this.monitor.id]; } - return "N/A" + return this.$t("notAvailableShort") }, importantHeartBeatList() {