From 86dbe4448748dbb0ca0c8980c7fcec17b57e9730 Mon Sep 17 00:00:00 2001 From: Miodec Date: Wed, 16 Mar 2022 18:49:39 +0100 Subject: [PATCH] showing client version on version shift click --- frontend/src/scripts/popups/version-popup.ts | 3 ++- frontend/src/scripts/version.ts | 6 ++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/frontend/src/scripts/popups/version-popup.ts b/frontend/src/scripts/popups/version-popup.ts index 9382bf1ba..1e74135fc 100644 --- a/frontend/src/scripts/popups/version-popup.ts +++ b/frontend/src/scripts/popups/version-popup.ts @@ -5,7 +5,8 @@ export function show(): void { .animate({ opacity: 1 }, 125); } -$(document.body).on("click", ".version", () => { +$(document.body).on("click", ".version", (e) => { + if (e.shiftKey) return; show(); }); diff --git a/frontend/src/scripts/version.ts b/frontend/src/scripts/version.ts index bbccfa6e9..e1e3bfac4 100644 --- a/frontend/src/scripts/version.ts +++ b/frontend/src/scripts/version.ts @@ -1 +1,7 @@ export const CLIENT_VERSION = "DEVELOPMENT-CLIENT"; + +$(document.body).on("click", ".version", (e) => { + if (e.shiftKey) { + alert(CLIENT_VERSION); + } +});