From 2a9f835a0ff21889701a12cb80ea51d1ae0c787c Mon Sep 17 00:00:00 2001
From: "34701892@qq.com" <34701892@qq.com>
Date: Wed, 4 Feb 2026 14:04:02 +0800
Subject: [PATCH] =?UTF-8?q?style(RankList):=20=E6=A0=BC=E5=BC=8F=E5=8C=96?=
=?UTF-8?q?=E4=BB=A3=E7=A0=81=E5=B9=B6=E4=BF=AE=E5=A4=8D=E7=A1=AC=E7=BC=96?=
=?UTF-8?q?=E7=A0=81=E7=9A=84=E6=96=B0=E9=97=BB=E6=9D=A5=E6=BA=90?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
- 调整标签和元数据的代码格式以提高可读性
- 将硬编码的新闻来源替换为动态变量
- 统一字体家族的声明格式
---
src/components/RankList.vue | 67 +++++++++++++++++++++++++------------
1 file changed, 45 insertions(+), 22 deletions(-)
diff --git a/src/components/RankList.vue b/src/components/RankList.vue
index 3a94948..b4fbfeb 100644
--- a/src/components/RankList.vue
+++ b/src/components/RankList.vue
@@ -24,19 +24,25 @@
- {{
- item
- }}
+ {{ item }}
- {{
- item
- }}
+ {{ item }}
@@ -44,7 +50,7 @@
- {{ item.source }}
+ 中国证券报
@@ -53,7 +59,8 @@
资讯评分:
- {{ item.news_score }}
+ {{ item.news_score }}
@@ -66,8 +73,12 @@
-
+
@@ -94,7 +105,7 @@ watch(
try {
concept_label = JSON.parse(item.concept_label);
industry_label = JSON.parse(item.industry_label);
- } catch (e) { }
+ } catch (e) {}
rankListLocal.value.push({
...item,
conceptLabels: concept_label,
@@ -103,7 +114,7 @@ watch(
});
loading.value = false;
- }
+ },
);
watch(
@@ -122,7 +133,7 @@ watch(
try {
concept_label = JSON.parse(item.concept_label);
industry_label = JSON.parse(item.industry_label);
- } catch (e) { }
+ } catch (e) {}
rankListLocal.value.push({
...item,
@@ -131,7 +142,7 @@ watch(
});
});
loading.value = false;
- }
+ },
);
// 接收父组件传入的新闻列表
@@ -261,7 +272,9 @@ function timeFormat(dateTime = null, formatStr = "yyyy-mm-dd hh:MM:ss") {
}
.rank-text-top3 {
- font-family: PingFangSC, PingFang SC;
+ font-family:
+ PingFangSC,
+ PingFang SC;
font-weight: 500;
font-size: 24rpx;
color: #ffffff;
@@ -278,7 +291,9 @@ function timeFormat(dateTime = null, formatStr = "yyyy-mm-dd hh:MM:ss") {
}
.rank-text {
- font-family: PingFangSC, PingFang SC;
+ font-family:
+ PingFangSC,
+ PingFang SC;
font-weight: bold;
font-size: 28rpx;
color: #e98254;
@@ -300,7 +315,9 @@ function timeFormat(dateTime = null, formatStr = "yyyy-mm-dd hh:MM:ss") {
}
.news-desc {
- font-family: PingFangSC, PingFang SC;
+ font-family:
+ PingFangSC,
+ PingFang SC;
font-weight: 400;
font-size: 24rpx;
color: #333333;
@@ -331,7 +348,9 @@ function timeFormat(dateTime = null, formatStr = "yyyy-mm-dd hh:MM:ss") {
.time,
.score {
// opacity: 0.8;
- font-family: PingFangSC, PingFang SC;
+ font-family:
+ PingFangSC,
+ PingFang SC;
font-weight: 400;
font-size: 22rpx;
color: #999999;
@@ -345,7 +364,9 @@ function timeFormat(dateTime = null, formatStr = "yyyy-mm-dd hh:MM:ss") {
}
.score {
- font-family: PingFangSC, PingFang SC;
+ font-family:
+ PingFangSC,
+ PingFang SC;
font-weight: 500;
font-size: 22rpx;
color: #ffa800;
@@ -378,7 +399,9 @@ function timeFormat(dateTime = null, formatStr = "yyyy-mm-dd hh:MM:ss") {
gap: 10rpx;
.tag {
- font-family: PingFangSC, PingFang SC;
+ font-family:
+ PingFangSC,
+ PingFang SC;
font-weight: 400;
font-size: 22rpx;
color: #3f80fa;