From 2bad8978a43260d37ffbccc4081dc944514c0db9 Mon Sep 17 00:00:00 2001 From: CN-JS-HuiBai Date: Sat, 4 Apr 2026 17:49:00 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E9=89=B4=E6=9D=83=E9=80=BB?= =?UTF-8?q?=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/css/style.css | 22 ++++- public/index.html | 32 ++++++- public/init.html | 41 ++++++++- public/js/app.js | 157 +++++++++++++++++++++++++++++++---- public/js/init.js | 85 +++++++++++++++++-- server/index.js | 145 +++++++++++++++++++++++++++++--- server/init-db.js | 16 +++- server/prometheus-service.js | 33 ++++---- 8 files changed, 474 insertions(+), 57 deletions(-) diff --git a/public/css/style.css b/public/css/style.css index 19e32de..a192697 100644 --- a/public/css/style.css +++ b/public/css/style.css @@ -55,6 +55,22 @@ --font-mono: 'JetBrains Mono', 'Fira Code', monospace; } +:root.light-theme { + --bg-primary: #f5f7fb; + --bg-secondary: #ffffff; + --bg-card: rgba(255, 255, 255, 0.9); + --bg-card-hover: rgba(255, 255, 255, 1); + --bg-input: #ffffff; + --border-color: rgba(99, 102, 241, 0.1); + --border-hover: rgba(99, 102, 241, 0.25); + --text-primary: #1e293b; + --text-secondary: #64748b; + --text-muted: #94a3b8; + --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.05); + --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.07); + --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1); +} + /* ---- Reset & Base ---- */ *, *::before, *::after { margin: 0; @@ -503,8 +519,8 @@ body { .gauge { position: relative; - width: 120px; - height: 120px; + width: 100px; + height: 100px; } .gauge svg { @@ -549,7 +565,7 @@ body { } .gauge-label { - font-size: 0.7rem; + font-size: 0.65rem; font-weight: 600; color: var(--text-muted); text-transform: uppercase; diff --git a/public/index.html b/public/index.html index 75dbf76..c512117 100644 --- a/public/index.html +++ b/public/index.html @@ -47,6 +47,12 @@
+ +
+ +
+ + + diff --git a/public/init.html b/public/init.html index 637c246..55bafe9 100644 --- a/public/init.html +++ b/public/init.html @@ -125,10 +125,47 @@ -