From fb5edce22f134ef1f72d2e905a0130d0a0e9ebb1 Mon Sep 17 00:00:00 2001 From: yanlongqi Date: Sat, 8 Nov 2025 04:33:12 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E9=94=99=E9=A2=98=E6=9C=AC?= =?UTF-8?q?=E9=A1=B5=E9=9D=A2UI=E5=92=8C=E6=A0=87=E9=A2=98=E6=A0=B7?= =?UTF-8?q?=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 主要改动: 1. 统一标题样式,与答题页面保持一致 - 标题居中显示 - 返回按钮使用绝对定位在左侧 - 移除标题中的图标 - Title组件level改为3 - 响应式字体大小:移动端16px,PC端20px,超宽屏22px 2. 优化首页统计文案 - 将"已刷"改为"已刷题目",更加清晰明确 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude --- web/src/pages/Home.tsx | 2 +- web/src/pages/WrongQuestions.module.less | 62 ++++++++++++++++-------- web/src/pages/WrongQuestions.tsx | 5 +- 3 files changed, 44 insertions(+), 25 deletions(-) diff --git a/web/src/pages/Home.tsx b/web/src/pages/Home.tsx index 2f26186..289bdc8 100644 --- a/web/src/pages/Home.tsx +++ b/web/src/pages/Home.tsx @@ -415,7 +415,7 @@ const Home: React.FC = () => {
{statistics.answered_questions}
-
已刷
+
已刷题目
diff --git a/web/src/pages/WrongQuestions.module.less b/web/src/pages/WrongQuestions.module.less index b89c762..a3fff2e 100644 --- a/web/src/pages/WrongQuestions.module.less +++ b/web/src/pages/WrongQuestions.module.less @@ -8,25 +8,33 @@ padding: 20px; padding-bottom: 16px; background: transparent; -} + display: flex; + justify-content: center; + align-items: center; + position: relative; -.backButton { - color: #007aff; - margin-bottom: 12px; - transition: all 0.3s ease; + .backButton { + color: #007aff; + font-weight: 500; + padding: 4px 12px; + transition: all 0.3s ease; + position: absolute; + left: 20px; - &:hover { - color: #0051d5; - transform: translateX(-4px); + &:hover { + color: #0051d5; + transform: translateX(-4px); + } } -} -.title { - color: #1d1d1f !important; - margin: 0 !important; - font-size: 28px; - font-weight: 700; - text-shadow: 0 1px 2px rgba(0, 0, 0, 0.02); + .title { + color: #1d1d1f !important; + margin: 0 !important; + font-weight: 700; + font-size: 18px !important; + text-align: center; + text-shadow: 0 1px 2px rgba(0, 0, 0, 0.02); + } } // 统计卡片容器 @@ -310,10 +318,16 @@ .header { padding: 16px; - } - .title { - font-size: 24px; + .backButton { + font-size: 14px; + padding: 4px 8px; + left: 16px; + } + + .title { + font-size: 16px !important; + } } .statsContainer { @@ -441,10 +455,10 @@ .header { padding: 32px 32px 24px; - } - .title { - font-size: 32px; + .title { + font-size: 20px !important; + } } .statsContainer { @@ -508,4 +522,10 @@ .container { max-width: 1600px; } + + .header { + .title { + font-size: 22px !important; + } + } } diff --git a/web/src/pages/WrongQuestions.tsx b/web/src/pages/WrongQuestions.tsx index 4748654..da7fbe3 100644 --- a/web/src/pages/WrongQuestions.tsx +++ b/web/src/pages/WrongQuestions.tsx @@ -2,7 +2,6 @@ import React, { useEffect, useState } from 'react' import { useNavigate } from 'react-router-dom' import { Card, List, Button, Tag, Typography, Space, message, Modal, Empty, Statistic, Progress, Select, Row, Col } from 'antd' import { - BookOutlined, CloseCircleOutlined, ArrowLeftOutlined, PlayCircleOutlined, @@ -169,8 +168,8 @@ const WrongQuestions: React.FC = () => { > 返回 - - <BookOutlined /> 错题本 + <Title level={3} className={styles.title}> + 错题本