功能:更新消息中心和 YumiNail 模块

This commit is contained in:
xiaowang
2026-05-13 12:43:01 +08:00
parent 6b9eba5aca
commit 2074addc40
284 changed files with 21031 additions and 4533 deletions
@@ -0,0 +1,243 @@
<template>
<div class="mobile-container">
<header class="header">
<a-button class="back-btn" type="text" @click="handleBackClick">
<LeftOutlined :style="{ fontSize: '20px' }" />
</a-button>
<h1>设置中心</h1>
<div class="empty"></div>
</header>
<div class="settings-menu">
<a-card :bordered="false" class="settings-card">
<a-list :data-source="settingsSections" :split="false">
<template #renderItem="{ item }">
<a-list-item v-if="item.type === 'title'" class="section-title">
<span>{{ item.title }}</span>
</a-list-item>
<a-list-item v-else class="setting-item" @click="handleSettingClick(item.key)">
<template #actions>
<RightOutlined />
</template>
<a-list-item-meta>
<template #avatar>
<div class="setting-icon" :style="{ backgroundColor: item.bgColor }">
<component :is="item.icon" />
</div>
</template>
<template #title>
<span>{{ item.title }}</span>
</template>
<template #description>
<span>{{ item.desc }}</span>
</template>
</a-list-item-meta>
</a-list-item>
</template>
</a-list>
</a-card>
</div>
<div class="version-info">
<a-typography-text type="secondary">版本 1.0.0</a-typography-text>
</div>
</div>
</template>
<script setup lang="ts">
import { ref } from 'vue'
import { useRouter } from 'vue-router'
import {
BellOutlined,
ClearOutlined,
InfoCircleOutlined,
LeftOutlined,
LockOutlined,
MessageOutlined,
QuestionCircleOutlined,
RightOutlined,
SafetyOutlined,
SoundOutlined
} from '@ant-design/icons-vue'
import { message } from 'ant-design-vue'
const router = useRouter()
const comingSoonDesc = '暂未开放,敬请期待'
const settingsSections = ref([
{
type: 'title',
title: '账号与安全'
},
{
key: 'account',
title: '账号设置',
desc: '修改密码、绑定手机号、管理账号安全项',
icon: LockOutlined,
bgColor: '#e6f7ff'
},
{
type: 'title',
title: '更多功能'
},
{
key: 'notifications',
title: '消息通知',
desc: comingSoonDesc,
icon: BellOutlined,
bgColor: '#f6ffed'
},
{
key: 'message-push',
title: '消息推送',
desc: comingSoonDesc,
icon: MessageOutlined,
bgColor: '#fffbe6'
},
{
key: 'theme',
title: '主题设置',
desc: comingSoonDesc,
icon: SoundOutlined,
bgColor: '#f9f0ff'
},
{
key: 'clear-cache',
title: '缓存清理',
desc: comingSoonDesc,
icon: ClearOutlined,
bgColor: '#fff2e8'
},
{
key: 'privacy',
title: '隐私政策',
desc: comingSoonDesc,
icon: SafetyOutlined,
bgColor: '#e6f7ff'
},
{
key: 'about',
title: '关于我们',
desc: comingSoonDesc,
icon: InfoCircleOutlined,
bgColor: '#f6ffed'
},
{
key: 'help',
title: '帮助中心',
desc: comingSoonDesc,
icon: QuestionCircleOutlined,
bgColor: '#eef9ff'
}
])
const showComingSoon = () => {
message.info('该功能暂未开放,敬请期待')
}
const handleBackClick = () => {
router.back()
}
const handleSettingClick = (key: string) => {
if (key === 'account') {
router.push('/settings/account')
return
}
showComingSoon()
}
</script>
<style scoped>
.header {
display: flex;
justify-content: space-between;
align-items: center;
padding: 10px 15px;
border-bottom: 1px solid #f0f0f0;
}
.header h1 {
font-size: 18px;
font-weight: bold;
margin: 0;
}
.back-btn,
.empty {
width: 40px;
height: 40px;
display: flex;
align-items: center;
justify-content: center;
}
.settings-menu {
padding: 15px;
}
.settings-card {
border-radius: 16px;
overflow: hidden;
}
.settings-card :deep(.ant-card-body) {
padding: 0;
}
.section-title {
padding: 12px 16px;
font-size: 13px;
color: #999;
background: #fafafa;
}
.setting-item {
padding: 16px;
cursor: pointer;
transition: background 0.3s;
border-bottom: 1px solid #f0f0f0;
}
.setting-item:hover {
background: #fafafa;
}
.setting-item:last-child {
border-bottom: none;
}
.setting-item :deep(.ant-list-item-action) {
margin-left: 8px;
color: #ccc;
}
.setting-icon {
width: 40px;
height: 40px;
border-radius: 10px;
display: flex;
align-items: center;
justify-content: center;
font-size: 18px;
}
.setting-item :deep(.ant-list-item-meta-title) {
font-size: 15px;
font-weight: 500;
color: #333;
}
.setting-item :deep(.ant-list-item-meta-description) {
font-size: 12px;
color: #999;
}
.version-info {
padding: 20px;
text-align: center;
}
</style>