From c10051cd456e2fff6efc7ab818b3a01dfb9f69c2 Mon Sep 17 00:00:00 2001 From: HXY <2479895356@qq.com> Date: Thu, 7 Sep 2023 17:01:02 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E5=AD=97=E4=BD=93=E6=96=87?= =?UTF-8?q?=E4=BB=B6=E6=8C=82=E8=BD=BD=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docker-compose.yaml.backup | 3 ++- web/src/components/rightbar.vue | 5 +++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/docker-compose.yaml.backup b/docker-compose.yaml.backup index df0fc980..f68b88d4 100644 --- a/docker-compose.yaml.backup +++ b/docker-compose.yaml.backup @@ -126,10 +126,11 @@ services: volumes: - ./config.yaml.sample:/app/paopao-ce/config.yaml - ./custom:/app/paopao-ce/custom + - ./internal/servants/web/typeface/TTF/SourceSans3-Black.ttf:/app/paopao-ce/internal/servants/web/typeface/TTF/SourceSans3-Black.ttf ports: - 8008:8008 networks: - - paopao-network + - paopao-networ networks: paopao-network: diff --git a/web/src/components/rightbar.vue b/web/src/components/rightbar.vue index 90f87926..7807089b 100644 --- a/web/src/components/rightbar.vue +++ b/web/src/components/rightbar.vue @@ -181,7 +181,6 @@ const rightHotTopicMaxSize = Number( import.meta.env.VITE_RIGHT_HOT_TOPIC_MAX_SIZE ); -// 模拟排行榜数据 const rankingList = ref([]); const allDownloadRankingList = ref([]); const DownloadPreWeekRankingList = ref([]); @@ -286,8 +285,10 @@ const formatQuoteNumStats = (num: number) => { if (num >= 1000) { const formattedNum = (num / 1000).toFixed(1); // Get one decimal place return formattedNum + 'k'; + } else if (num >= 10) { + return num.toString(); // Display two digits for two-digit numbers } else { - return num.toString().padStart(3, '0'); // Ensure 3-digit format + return '0' + num.toString(); // Display two digits for one-digit numbers } };