From a019e26c08be11f0bf660cda85ff3b93a58b4ecf Mon Sep 17 00:00:00 2001 From: qinzhenpen Date: Tue, 22 Sep 2026 10:07:06 +0800 Subject: [PATCH] =?UTF-8?q?style(student-training):=20=E7=A7=BB=E9=99=A4?= =?UTF-8?q?=E5=AD=90=E9=A1=B5=E9=9D=A2=E9=87=8D=E5=A4=8D=E7=9A=84padding?= =?UTF-8?q?=E6=A0=B7=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 统一由全局app-main样式提供页面padding,避免子页面重复设置导致的样式冲突和冗余 --- src/assets/styles/student-training.scss | 5 +- src/layout/components/Navbar.vue | 190 +++++++++++---------- src/views/training/GenericTrainingPage.vue | 6 +- 3 files changed, 104 insertions(+), 97 deletions(-) diff --git a/src/assets/styles/student-training.scss b/src/assets/styles/student-training.scss index 822233b..1212308 100644 --- a/src/assets/styles/student-training.scss +++ b/src/assets/styles/student-training.scss @@ -106,8 +106,9 @@ max-width: none !important; min-height: calc(100vh - 90px) !important; margin: 0 !important; - padding: 10px 10px 16px !important; - padding: 10px 10px 16px !important; + /* padding 由架构标签 .app-main 提供(sidebar.scss 中 28px 32px 40px 24px),子页面根标签不再叠加 */ + // padding: 10px 10px 16px !important; + // padding: 10px 10px 16px !important; background: #ffffff !important; /* 应用实训页专用字体栈 + 数字等宽对齐 */ font-family: var(--student-font-base) !important; diff --git a/src/layout/components/Navbar.vue b/src/layout/components/Navbar.vue index 9122383..b373483 100644 --- a/src/layout/components/Navbar.vue +++ b/src/layout/components/Navbar.vue @@ -773,69 +773,7 @@ onMounted(() => { } } -// 教师端下拉面板:亮色玻璃质感(dropdown teleport 到 body,需使用 popper-class 选择器) -.teacher-dropdown-popper { - .dropdown-panel { - background: linear-gradient(160deg, #ffffff 0%, #f3f8ff 50%, #eaf2fb 100%); - border: 1px solid rgba(30, 136, 229, 0.25); - box-shadow: 0 15px 40px rgba(30, 60, 100, 0.18), 0 0 20px rgba(30, 136, 229, 0.08); - - .dropdown-header { - background: linear-gradient(135deg, rgba(30, 136, 229, 0.1), rgba(66, 165, 245, 0.05)); - border-bottom: 1px solid rgba(30, 136, 229, 0.15); - - .user-info { - .user-name { - color: #1e3a5f; - } - - .user-role { - color: #1e88e5; - } - } - } - - .dropdown-divider { - background: linear-gradient(90deg, transparent, rgba(30, 136, 229, 0.25), transparent); - } - - .dropdown-menu-custom { - .dropdown-item { - color: #3a5a7a !important; - - svg { - color: rgba(30, 136, 229, 0.8); - } - - &:hover { - background: linear-gradient(135deg, rgba(30, 136, 229, 0.14), rgba(66, 165, 245, 0.06)) !important; - color: #1e88e5 !important; - - svg { - color: #1e88e5; - } - } - - &.logout { - color: rgba(200, 80, 80, 0.85) !important; - - svg { - color: rgba(220, 100, 100, 0.8); - } - - &:hover { - background: linear-gradient(135deg, rgba(220, 80, 80, 0.14), rgba(200, 60, 60, 0.06)) !important; - color: #d63030 !important; - - svg { - color: #d63030; - } - } - } - } - } - } -} +// 教师端下拉面板、学生端下拉面板已移至文件末尾非 scoped style 块 // 学生端下拉面板规则见文件末尾(置于基础块之后,避免被深色默认样式反压) @@ -939,9 +877,103 @@ onMounted(() => { } } -/* ===== 学生端用户下拉:白底墨黑(置于基础块之后,完整覆盖,避免蓝框/箭头/位移重影) ===== */ +/* ===== 学生端用户下拉已移至文件末尾非 scoped style 块 ===== */ + +@media (max-width: 768px) { + .navbar { + .navTitle, .TnavTitle { + .logo-area { + .nacber-name { + font-size: 13px; + letter-spacing: 1px; + } + } + } + + .el-ment { + display: none !important; + } + + .search-box { + display: none; + } + + .divider { + display: none; + } + } +} + + + + diff --git a/src/views/training/GenericTrainingPage.vue b/src/views/training/GenericTrainingPage.vue index a9318c9..a31496f 100644 --- a/src/views/training/GenericTrainingPage.vue +++ b/src/views/training/GenericTrainingPage.vue @@ -1713,7 +1713,8 @@ function exportOutcome() { max-width: 100%; min-height: calc(100vh - 106px); margin: 0; - padding: 24px 24px 32px; + /* padding 由架构标签 .app-main 提供,子页面根标签不再叠加 */ + // padding: 24px 24px 32px; color: #1f2937; background: #ffffff; } @@ -2731,7 +2732,8 @@ function exportOutcome() { @media (max-width: 900px) { .student-training-page { margin: 0; - padding: 14px 14px 18px; + /* padding 由架构标签 .app-main 提供,子页面根标签不再叠加 */ + // padding: 14px 14px 18px; } .training-core {