~/Projects/uptime
git clone https://code.lsong.org/uptime
Commit
- Commit
- 9c5466890e0ce567d0346c3a27e930c65d173543
- Author
- Ivan Bratović <[email protected]>
- Date
- 2021-11-29 12:40:53 +0100 +0100
- Diffstat
src/languages/en.js | 3 --- src/pages/EditMonitor.vue | 18 ++++++++++++++++--
Revert "Replace body and header placeholder functions with translations" This reverts commit 2c85491ee011ca7f7ba655592eb292b2aa5733c7.
diff --git a/src/languages/en.js b/src/languages/en.js index f7a637de6139e70a895b8b3498e3094700ff9038..24de7410f721ecd8e5f6ca3c84558a670d9fd548 100644 --- a/src/languages/en.js +++ b/src/languages/en.js @@ -316,9 +316,6 @@ "Pick a RR-Type...": "Pick a RR-Type...", "Pick Accepted Status Codes...": "Pick Accepted Status Codes...", Default: "Default", checkEverySecond: "Check every {0} seconds", - pauseMonitorMsg: "Are you sure want to pause?", - bodyPlaceholder: "Example:\n{\n \"key\": \"value\"\n}", - checkEverySecond: "Check every {0} seconds", clearEventsMsg: "Are you sure want to delete all events for this monitor?", "Create Incident": "Create Incident", Title: "Title", diff --git a/src/pages/EditMonitor.vue b/src/pages/EditMonitor.vue index 07bd818efa24ea4e79a46f6f051ad6fd9087c495..2678a94af47edaea51f31996725f8e7e87bd31bc 100644 --- a/src/pages/EditMonitor.vue +++ b/src/pages/EditMonitor.vue @@ -257,13 +257,13 @@ <!-- Body --> <div class="my-3"> <label for="body" class="form-label">{{ $t("Body") }}</label> - <textarea id="body" v-model="monitor.body" class="form-control" :placeholder="$t('bodyPlaceholder')"></textarea> + <textarea id="body" v-model="monitor.body" class="form-control" :placeholder="bodyPlaceholder"></textarea> </div> <!-- Headers --> <div class="my-3"> <label for="headers" class="form-label">{{ $t("Headers") }}</label> - <textarea id="headers" v-model="monitor.headers" class="form-control" :placeholder="$t('headersPlaceholder')"></textarea> + <textarea id="headers" v-model="monitor.headers" class="form-control" :placeholder="headersPlaceholder"></textarea> </div> <!-- HTTP Basic Auth --> @@ -351,6 +351,20 @@ pushURL() { return this.$root.baseURL + "/api/push/" + this.monitor.pushToken + "?msg=OK&ping="; }, + + bodyPlaceholder() { + return `Example: +{ + "key": "value" +}`; + }, + + headersPlaceholder() { + return `Example: +{ + "HeaderName": "HeaderValue" +}`; + } }, watch: {