From 4b75a882474f1edbff92985e1c80ff1e221ec7da Mon Sep 17 00:00:00 2001 From: root Date: Tue, 11 Aug 2026 17:05:18 +0800 Subject: [PATCH] =?UTF-8?q?fix(ui):=20status=20pie=20=E2=80=94=20drop=20ce?= =?UTF-8?q?nter=20number,=20carve=20clean=20donut=20hole?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - remove the total-req number drawn in the pie center - carve a center hole (donut) with the card background for a cleaner look; total still shown in the card header caption and legend - deployed (bak .bak.20260811o), server active --- internal/gateway/ui/index.html | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/internal/gateway/ui/index.html b/internal/gateway/ui/index.html index 52b6f8d..c0cc5ac 100644 --- a/internal/gateway/ui/index.html +++ b/internal/gateway/ui/index.html @@ -979,14 +979,11 @@ function drawStatusChart(rows) { ctx.fill(); a0 += sweep; }); - // center label = total - ctx.fillStyle = 'var(--fg)'; - ctx.font = '700 16px ui-monospace,Menlo,Consolas,monospace'; - ctx.textAlign = 'center'; ctx.textBaseline = 'middle'; - ctx.fillText(fmtN(total), cx, cy - 7); - ctx.fillStyle = 'var(--muted)'; - ctx.font = '10px ui-monospace,Menlo,Consolas,monospace'; - ctx.fillText(t('thReqs'), cx, cy + 9); + // carve a clean center hole (donut) instead of a solid pie with a number + ctx.beginPath(); + ctx.arc(cx, cy, Math.max(r * 0.45, 1), 0, Math.PI * 2); + ctx.fillStyle = 'var(--card)'; + ctx.fill(); } function paintKeyTable(rows, keyNames) { const el = $('#tb-key'); if (!el) return;