From bf80cf15b6f48b0c69aea94c5b442d4aeb07267a Mon Sep 17 00:00:00 2001
From: liyy <18435186204@163.com>
Date: Wed, 2 Sep 2026 15:57:20 +0800
Subject: [PATCH] =?UTF-8?q?refactor:=20=E7=A7=BB=E5=8A=A8=E7=AB=AF?=
=?UTF-8?q?=E5=8E=BB=E9=99=A4layout=E9=A1=B6=E6=A0=8F=EF=BC=8C=E9=A1=B5?=
=?UTF-8?q?=E9=9D=A2=E5=A4=B4=E7=BB=9F=E4=B8=80=E6=94=B6=E6=95=9B=E5=88=B0?=
=?UTF-8?q?AppPageHeader?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
client/src/components/base/AppPageHeader.vue | 94 +++++++++++++++++--
client/src/layouts/MobileLayout.vue | 25 -----
client/src/views/mock/MockFormView.vue | 2 +-
client/src/views/mock/MockView.vue | 2 +-
client/src/views/news/NewsDetailView.vue | 30 +-----
client/src/views/news/NewsView.vue | 2 +-
client/src/views/plan/PlanReviewView.vue | 33 +------
client/src/views/plan/PlanView.vue | 2 +-
client/src/views/practice/AiExplainView.vue | 33 +------
client/src/views/practice/WrongDetailView.vue | 45 +--------
client/src/views/profile/ProfileView.vue | 2 +-
client/src/views/questions/QuestionsView.vue | 4 +-
client/src/views/settings/SettingsView.vue | 2 +-
13 files changed, 113 insertions(+), 163 deletions(-)
diff --git a/client/src/components/base/AppPageHeader.vue b/client/src/components/base/AppPageHeader.vue
index 015d5ca..9ce8688 100644
--- a/client/src/components/base/AppPageHeader.vue
+++ b/client/src/components/base/AppPageHeader.vue
@@ -1,21 +1,59 @@
-
+
+
+
-
{{ title }}
-
{{ subtitle }}
+
+ {{ title }}
+ {{ subtitle }}
+
+
@@ -49,9 +87,53 @@ withDefaults(
gap: var(--space-3);
flex: none;
}
+
+/* 返回按钮(左段) */
+.page-head__back {
+ display: grid;
+ place-items: center;
+ width: 36px;
+ height: 36px;
+ flex: none;
+ border-radius: 50%;
+ background: var(--bg-card);
+ border: 1px solid var(--border-subtle);
+ color: var(--text-secondary);
+ cursor: pointer;
+ transition: background var(--motion-hover-fast) var(--ease-default);
+}
+.page-head__back:hover {
+ background: var(--bg-soft);
+}
+
+/* 详情/子页返回头:紧凑行内布局 */
+.page-head--detail {
+ align-items: center;
+ gap: var(--space-3);
+}
+.page-head--detail .page-head__title {
+ display: flex;
+ align-items: center;
+ gap: var(--space-3);
+}
+.page-head--detail h1 {
+ font-size: var(--fs-h3);
+ font-weight: var(--fw-h1);
+}
+
@media (max-width: 767px) {
.page-head--stack {
flex-direction: column;
}
+ /* 吸顶(替代原 layout topbar;负边距让背景铺满屏宽) */
+ .page-head--sticky-mobile {
+ position: sticky;
+ top: 0;
+ z-index: 30;
+ margin-left: calc(-1 * var(--padding-mobile));
+ margin-right: calc(-1 * var(--padding-mobile));
+ padding: var(--space-2) var(--padding-mobile);
+ background: var(--bg-canvas);
+ }
}
diff --git a/client/src/layouts/MobileLayout.vue b/client/src/layouts/MobileLayout.vue
index 545e35b..b1b9c6c 100644
--- a/client/src/layouts/MobileLayout.vue
+++ b/client/src/layouts/MobileLayout.vue
@@ -1,22 +1,13 @@
-