feat ui设计稿bug修复

This commit is contained in:
Ironsp
2026-10-01 10:53:13 +08:00
parent 9ab6253c81
commit 1601bdd82c
89 changed files with 4741 additions and 3652 deletions

View File

@@ -1,69 +1,55 @@
<script setup lang="ts">
interface MenuItem {
to: string
icon: string
label: string
}
// 设计稿(个人中心)菜单项 y268/304/340/376/412/448/484/520,行距 36,文字 x179(卡内缩进 24)
const menus: MenuItem[] = [
{ to: '/profile/security', icon: '🔒', label: '账号安全' },
{ to: '/profile/address', icon: '📍', label: '收货地址' },
{ to: '/profile/favorites', icon: '⭐', label: '我的收藏' },
{ to: '/profile/qualifications', icon: '📜', label: '资质管理' },
{ to: '/profile/feedback', icon: '💡', label: '意见反馈' },
{ to: '/profile/help', icon: '❓', label: '帮助中心' },
{ to: '/profile/about', icon: 'ℹ️', label: '关于我们' },
{ to: '/profile/hotline', icon: '📞', label: '客服热线' },
{ to: '/profile/security', label: '账号安全' },
{ to: '/profile/address', label: '地址管理' },
{ to: '/profile/favorites', label: '收藏列表' },
{ to: '/profile/qualifications', label: '资质列表' },
{ to: '/profile/feedback', label: '意见反馈' },
{ to: '/profile/help', label: '帮助中心' },
{ to: '/profile/about', label: '关于我们' },
{ to: '/profile/hotline', label: '专属客服热线' },
]
</script>
<template>
<nav class="profile-sider" aria-label="个人中心导航">
<ul class="profile-sider__menu">
<li v-for="item in menus" :key="item.to">
<RouterLink :to="item.to" class="profile-sider__item">
<span class="profile-sider__label">{{ item.label }}</span>
</RouterLink>
</li>
</ul>
<div class="profile-sider__footer">
<RouterLink
to="/profile/hotline"
class="profile-sider__hotline"
title="专属客服热线"
>
📞 专属客服热线
</RouterLink>
</div>
<RouterLink
v-for="item in menus"
:key="item.to"
:to="item.to"
class="profile-sider__item"
>
{{ item.label }}
</RouterLink>
</nav>
</template>
<style lang="less" scoped>
// 设计稿:菜单为独立白卡(245 宽),选中项浅蓝底 @profile-nav-active-bg 圆角 6
.profile-sider {
.flex(column, space-between);
min-height: 480px;
padding: @spacing-sm 0;
.flex(column, flex-start);
gap: 0;
padding: 4px 0;
border-radius: @radius-lg;
background: @white;
&__menu {
.flex(column, flex-start);
gap: 0;
list-style: none;
}
// 设计 14/28:纯文字菜单,选中项浅蓝底 + 蓝色加粗,行距 36 × 0.77 ≈ 28
&__item {
.flex(row, flex-start, center);
height: 28px;
padding: 0 @spacing-sm;
height: 36px; // 设计行距 36
padding: 0 24px; // 卡 x155 → 文字 x179
border-radius: @profile-radius;
color: @text-color;
font-size: 11px;
line-height: 1;
font-size: @font-size-base; // 设计 12/400
font-weight: 400;
transition: all 0.2s;
&:hover {
background: @primary-light;
color: @primary-strong;
}
@@ -73,25 +59,5 @@ const menus: MenuItem[] = [
font-weight: 600;
}
}
&__label {
white-space: nowrap;
}
&__footer {
padding: @spacing-sm @spacing-sm 0;
border-top: 1px solid @project-divider;
}
&__hotline {
display: inline-block;
font-size: 11px;
color: @text-color-secondary;
transition: color 0.2s;
&:hover {
color: @primary-strong;
}
}
}
</style>