diff --git a/.github/ISSUE_TEMPLATE/feature_request.yaml b/.github/ISSUE_TEMPLATE/feature_request.yaml index f0a92ede1..b26841c42 100644 --- a/.github/ISSUE_TEMPLATE/feature_request.yaml +++ b/.github/ISSUE_TEMPLATE/feature_request.yaml @@ -1,7 +1,7 @@ name: 🚀 Feature Request description: "Submit a proposal for a new feature" #title: "[Feature] " -labels: [enhancement] +labels: [feature-request] body: - type: checkboxes id: no-duplicate-issues diff --git a/package.json b/package.json index 038d52ebd..c7ec3d8ee 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "uptime-kuma", - "version": "1.10.1", + "version": "1.10.2", "license": "MIT", "repository": { "type": "git", @@ -30,13 +30,13 @@ "build-docker": "npm run build-docker-debian && npm run build-docker-alpine", "build-docker-alpine-base": "docker buildx build -f docker/alpine-base.dockerfile --platform linux/amd64,linux/arm64,linux/arm/v7 -t louislam/uptime-kuma:base-alpine . --push", "build-docker-debian-base": "docker buildx build -f docker/debian-base.dockerfile --platform linux/amd64,linux/arm64,linux/arm/v7 -t louislam/uptime-kuma:base-debian . --push", - "build-docker-alpine": "docker buildx build -f docker/dockerfile-alpine --platform linux/amd64,linux/arm64,linux/arm/v7 -t louislam/uptime-kuma:alpine -t louislam/uptime-kuma:1-alpine -t louislam/uptime-kuma:1.10.1-alpine --target release . --push", - "build-docker-debian": "docker buildx build -f docker/dockerfile --platform linux/amd64,linux/arm64,linux/arm/v7 -t louislam/uptime-kuma -t louislam/uptime-kuma:1 -t louislam/uptime-kuma:1.10.1 -t louislam/uptime-kuma:debian -t louislam/uptime-kuma:1-debian -t louislam/uptime-kuma:1.10.1-debian --target release . --push", + "build-docker-alpine": "docker buildx build -f docker/dockerfile-alpine --platform linux/amd64,linux/arm64,linux/arm/v7 -t louislam/uptime-kuma:alpine -t louislam/uptime-kuma:1-alpine -t louislam/uptime-kuma:1.10.2-alpine --target release . --push", + "build-docker-debian": "docker buildx build -f docker/dockerfile --platform linux/amd64,linux/arm64,linux/arm/v7 -t louislam/uptime-kuma -t louislam/uptime-kuma:1 -t louislam/uptime-kuma:1.10.2 -t louislam/uptime-kuma:debian -t louislam/uptime-kuma:1-debian -t louislam/uptime-kuma:1.10.2-debian --target release . --push", "build-docker-nightly": "docker buildx build -f docker/dockerfile --platform linux/amd64,linux/arm64,linux/arm/v7 -t louislam/uptime-kuma:nightly --target nightly . --push", "build-docker-nightly-alpine": "docker buildx build -f docker/dockerfile-alpine --platform linux/amd64,linux/arm64,linux/arm/v7 -t louislam/uptime-kuma:nightly-alpine --target nightly . --push", "build-docker-nightly-amd64": "docker buildx build -f docker/dockerfile --platform linux/amd64 -t louislam/uptime-kuma:nightly-amd64 --target nightly . --push --progress plain", "upload-artifacts": "docker buildx build -f docker/dockerfile --platform linux/amd64 -t louislam/uptime-kuma:upload-artifact --build-arg GITHUB_TOKEN --target upload-artifact . --progress plain", - "setup": "git checkout 1.10.1 && npm ci --production && npm run download-dist", + "setup": "git checkout 1.10.2 && npm ci --production && npm run download-dist", "download-dist": "node extra/download-dist.js", "update-version": "node extra/update-version.js", "mark-as-nightly": "node extra/mark-as-nightly.js", diff --git a/src/languages/nl-NL.js b/src/languages/nl-NL.js index 818893af6..ff18832d7 100644 --- a/src/languages/nl-NL.js +++ b/src/languages/nl-NL.js @@ -116,7 +116,7 @@ export default { "Repeat Password": "Herhaal wachtwoord", Export: "Exporteren", Import: "Importeren", - respTime: "resp. tijd (ms)", + respTime: "reactietijd (ms)", notAvailableShort: "N.v.t.", "Default enabled": "Default enabled", "Apply on all existing monitors": "Pas toe op alle bestaande monitors", @@ -138,48 +138,48 @@ export default { "Two Factor Authentication": "Two Factor Authenticatie", Active: "Actief", Inactive: "Inactief", - "Also apply to existing monitors": "Also apply to existing monitors", + "Also apply to existing monitors": "Voeg ook toe aan bestaande monitors", Token: "Token", "Show URI": "Toon URI", "Clear all statistics": "Wis alle statistieken", - retryCheckEverySecond: "Retry every {0} seconds.", - importHandleDescription: "Choose 'Skip existing' if you want to skip every monitor or notification with the same name. 'Overwrite' will delete every existing monitor and notification.", - confirmImportMsg: "Are you sure to import the backup? Please make sure you've selected the right import option.", + retryCheckEverySecond: "Probeer elke {0} seconden.", + importHandleDescription: "Kies 'Sla bestaande over' als je elke monitor of melding met dezelfde naam wilt overslaan. Kies 'Overschrijf' als je elke monitor of notificatie wilt verwijderen.", + confirmImportMsg: "Weet je zeker dat je dit bestand wilt importeren?", "Heartbeat Retry Interval": "Heartbeat Retry Interval", - "Import Backup": "Import Backup", - "Export Backup": "Export Backup", - "Skip existing": "Skip existing", - Overwrite: "Overwrite", - Options: "Options", - "Keep both": "Keep both", - Tags: "Tags", - "Add New below or Select...": "Add New below or Select...", - "Tag with this name already exist.": "Tag with this name already exist.", - "Tag with this value already exist.": "Tag with this value already exist.", - color: "color", - "value (optional)": "value (optional)", - Gray: "Gray", - Red: "Red", - Orange: "Orange", - Green: "Green", - Blue: "Blue", + "Import Backup": "Importeer Backup", + "Export Backup": "Exporteer Backup", + "Skip existing": "Sla bestaande over", + Overwrite: "Overschrijf", + Options: "Opties", + "Keep both": "Bewaar beide", + Tags: "Labels", + "Add New below or Select...": "Voeg nieuwe toe of selecteer...", + "Tag with this name already exist.": "Label met deze naam bestaat al", + "Tag with this value already exist.": "Label met deze waarde bestaat al", + color: "Kleur", + "value (optional)": "waarde (optioneel)", + Gray: "Grijs", + Red: "Rood", + Orange: "Oranje", + Green: "Groen", + Blue: "Blauw", Indigo: "Indigo", - Purple: "Purple", - Pink: "Pink", - "Search...": "Search...", - "Avg. Ping": "Avg. Ping", - "Avg. Response": "Avg. Response", + Purple: "Paars", + Pink: "Roze", + "Search...": "Zoeken...", + "Avg. Ping": "Gemiddelde Ping", + "Avg. Response": "Gemiddelde Response", "Entry Page": "Entry Page", - statusPageNothing: "Nothing here, please add a group or a monitor.", + statusPageNothing: "Niets hier, voeg een groep of monitor toe.", "No Services": "No Services", - "All Systems Operational": "All Systems Operational", - "Partially Degraded Service": "Partially Degraded Service", - "Degraded Service": "Degraded Service", - "Add Group": "Add Group", - "Add a monitor": "Add a monitor", - "Edit Status Page": "Edit Status Page", - "Go to Dashboard": "Go to Dashboard", - "Status Page": "Status Page", + "All Systems Operational": "Alle systemen operationeel", + "Partially Degraded Service": "Gedeeltelijk verminderde prestaties", + "Degraded Service": "Verminderde prestaties", + "Add Group": "Voeg groep toe", + "Add a monitor": "Voeg monitor toe", + "Edit Status Page": "Wijzig status pagina", + "Go to Dashboard": "Ga naar Dashboard", + "Status Page": "Status Pagina", telegram: "Telegram", webhook: "Webhook", smtp: "Email (SMTP)", diff --git a/src/mixins/socket.js b/src/mixins/socket.js index 170a07a73..affac4f82 100644 --- a/src/mixins/socket.js +++ b/src/mixins/socket.js @@ -1,5 +1,6 @@ import { io } from "socket.io-client"; import { useToast } from "vue-toastification"; +import jwt_decode from "jwt-decode"; const toast = useToast(); let socket; @@ -217,6 +218,15 @@ export default { return (this.remember) ? localStorage : sessionStorage; }, + getJWTPayload() { + const jwtToken = this.$root.storage().token; + + if (jwtToken && jwtToken !== "autoLogin") { + return jwt_decode(jwtToken); + } + return undefined; + }, + getSocket() { return socket; }, diff --git a/src/pages/Settings.vue b/src/pages/Settings.vue index 9312b0c24..9d501407d 100644 --- a/src/pages/Settings.vue +++ b/src/pages/Settings.vue @@ -306,7 +306,7 @@
这是为 有第三方认证 的用户提供的功能,如 Cloudflare Access
请谨慎使用!
- +你是否要取消登入驗證?
此功能是設計給已有第三方認證的使用者,例如 Cloudflare Access。
@@ -515,9 +515,11 @@ export default { }, loadUsername() { - const jwtToken = this.$root.storage().token; - const jwtPayload = jwt_decode(jwtToken); - this.username = jwtPayload.username; + const jwtPayload = this.$root.getJWTPayload(); + + if (jwtPayload) { + this.username = jwtPayload.username; + } }, loadSettings() { @@ -568,6 +570,7 @@ export default { this.settings.disableAuth = false; this.saveSettings(); this.$root.storage().removeItem("token"); + location.reload(); }, downloadBackup() {