From 440e3208a95e263f13ca0da17c82aaa92c9bef64 Mon Sep 17 00:00:00 2001 From: MHSanaei Date: Fri, 8 May 2026 18:42:10 +0200 Subject: [PATCH] fix(frontend): shrink dashboard percent text and surface the unfinished arc Two follow-up tweaks to the dashboard gauges: - AD-Vue scales the percent text from the SVG, not from :width, so the 90px gauges still rendered the number at ~27px. Pin .ant-progress-text to 14px via :deep() and trim the gauge to 70px (60px on mobile) so the whole card stays compact. - The default trail (rgba(0,0,0,0.06) / rgba(255,255,255,0.08)) was invisible on the light-theme card. Pass an explicit rgba(128,128,128,0.25) trail-color so the unfinished portion is visible under both light and dark themes. Co-Authored-By: Claude Opus 4.7 --- frontend/src/pages/index/StatusCard.vue | 26 ++++++++++++++++++------- 1 file changed, 19 insertions(+), 7 deletions(-) diff --git a/frontend/src/pages/index/StatusCard.vue b/frontend/src/pages/index/StatusCard.vue index 9865d5ba..ebcaed81 100644 --- a/frontend/src/pages/index/StatusCard.vue +++ b/frontend/src/pages/index/StatusCard.vue @@ -15,9 +15,14 @@ const props = defineProps({ defineEmits(['open-cpu-history']); // AD-Vue's default 120px dashboard renders the percent text at ~36px -// which dwarfs the rest of the card. 90 (or 70 on mobile) keeps the -// proportions sane against the surrounding labels. -const gaugeSize = computed(() => (props.isMobile ? 70 : 90)); +// which dwarfs the rest of the card. 70 (60 on mobile) plus the +// :deep(.ant-progress-text) override below keep the gauges compact. +const gaugeSize = computed(() => (props.isMobile ? 60 : 70)); + +// AD-Vue's default unfinished trail (rgba(0,0,0,0.06) / +// rgba(255,255,255,0.08)) is invisible against the light card; a +// neutral mid-gray reads on both themes. +const trailColor = 'rgba(128, 128, 128, 0.25)';