hookehuyr

style(user): 美化头像修改页面样式

- 优化页面背景色为淡灰色
- 添加头像展示卡片和圆环边框
- 改进编辑图标为右下角悬浮样式
- 统一底部按钮风格

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
...@@ -5,6 +5,23 @@ ...@@ -5,6 +5,23 @@
5 5
6 --- 6 ---
7 7
8 +## [2026-02-11] - 美化头像修改页面布局和样式
9 +
10 +### 优化
11 +- **UI 升级**
12 + - 将页面背景色调整为淡灰色 (`#F9FAFB`),提升视觉舒适度
13 + - 增加头像展示卡片,采用白色背景和阴影效果,增强层次感
14 + - 优化头像容器样式,增加白色圆环边框
15 + - 改进编辑图标样式,改为右下角悬浮的蓝色相机图标,符合常见交互习惯
16 + - 统一底部按钮风格,使其更具质感且符合品牌调性
17 +
18 +**详细信息**
19 +- **影响文件**: src/pages/avatar/index.vue
20 +- **技术栈**: Vue 3, Tailwind CSS, NutUI
21 +- **备注**: 提升头像修改页面的视觉体验,使其更加现代和专业
22 +
23 +---
24 +
8 ## [2026-02-11] - 优化计划书删除用户体验 25 ## [2026-02-11] - 优化计划书删除用户体验
9 26
10 ### 优化 27 ### 优化
......
1 <!-- 1 <!--
2 * @Date: 2026-01-29 22:25:57 2 * @Date: 2026-01-29 22:25:57
3 * @LastEditors: hookehuyr hookehuyr@gmail.com 3 * @LastEditors: hookehuyr hookehuyr@gmail.com
4 - * @LastEditTime: 2026-01-29 22:54:41 4 + * @LastEditTime: 2026-02-11 14:06:51
5 * @FilePath: /manulife-weapp/src/pages/avatar/index.vue 5 * @FilePath: /manulife-weapp/src/pages/avatar/index.vue
6 * @Description: 修改头像页面 6 * @Description: 修改头像页面
7 --> 7 -->
8 <template> 8 <template>
9 - <view class="min-h-screen bg-white flex flex-col"> 9 + <view class="min-h-screen bg-[#F9FAFB] flex flex-col">
10 <!-- NavHeader --> 10 <!-- NavHeader -->
11 <NavHeader title="修改头像" /> 11 <NavHeader title="修改头像" />
12 +
12 <!-- Main Content --> 13 <!-- Main Content -->
13 - <view class="flex-1 flex flex-col items-center pt-[120rpx]"> 14 + <view class="flex-1 flex flex-col items-center pt-[60rpx]">
14 - <view class="relative mb-[60rpx]" @tap="onChangeAvatar"> 15 + <!-- Avatar Card -->
15 - <nut-avatar size="large" class="!w-[240rpx] !h-[240rpx] shadow-lg border-4 border-gray-100"> 16 + <view
16 - <img :src="avatarUrl" style="object-fit: cover; width: 100%; height: 100%;" /> 17 + class="bg-white rounded-[32rpx] p-[60rpx] flex flex-col items-center shadow-sm mx-[40rpx] w-[calc(100%-80rpx)]">
18 + <view class="relative mb-[40rpx] group" @tap="onChangeAvatar">
19 + <!-- Avatar Container with Ring -->
20 + <view
21 + class="w-[240rpx] h-[240rpx] rounded-full p-[6rpx] bg-white shadow-lg border border-gray-100 flex items-center justify-center relative z-10">
22 + <nut-avatar size="large" class="!w-full !h-full !rounded-full overflow-hidden !bg-gray-50">
23 + <img :src="avatarUrl" class="w-full h-full object-cover" />
17 </nut-avatar> 24 </nut-avatar>
18 - <view class="absolute top-1/2 left-1/2 transform -translate-x-1/2 -translate-y-1/2 flex items-center justify-center w-[96rpx] h-[96rpx] bg-black/30 rounded-full"> 25 + </view>
19 - <IconFont name="photograph" color="#fff" size="24" /> 26 +
27 + <!-- Edit Badge (Bottom Right) -->
28 + <view
29 + class="absolute bottom-[6rpx] right-[6rpx] w-[72rpx] h-[72rpx] bg-[#007AFF] text-white rounded-full flex items-center justify-center shadow-md border-[4rpx] border-white z-20 active:scale-95 transition-transform">
30 + <IconFont name="photograph" color="#fff" size="20" />
20 </view> 31 </view>
21 </view> 32 </view>
22 33
23 - <text class="text-gray-500 text-[32rpx] mb-[12rpx]">点击更换头像</text> 34 + <text class="text-gray-900 text-[34rpx] font-medium mb-[12rpx]">更换头像</text>
35 + <text class="text-gray-400 text-[26rpx]">点击上方图标选择新图片</text>
36 + </view>
24 </view> 37 </view>
25 38
26 <!-- Footer Buttons --> 39 <!-- Footer Buttons -->
27 - <view class="px-[40rpx] pb-[80rpx] w-full"> 40 + <view class="px-[40rpx] pb-[calc(40rpx+env(safe-area-inset-bottom))] w-full mb-[20rpx]">
28 <view class="flex gap-[32rpx]"> 41 <view class="flex gap-[32rpx]">
29 - <nut-button plain type="primary" block class="flex-1 !rounded-[48rpx]" @click="onCancel">取消</nut-button> 42 + <nut-button plain type="default" block
30 - <nut-button type="primary" block class="flex-1 !rounded-[48rpx]" @click="onSave">保存</nut-button> 43 + class="flex-1 !rounded-[48rpx] !h-[96rpx] !border-gray-200 !text-gray-600 !bg-white !text-[30rpx]"
44 + @click="onCancel">
45 + 取消
46 + </nut-button>
47 + <nut-button type="primary" block
48 + class="flex-1 !rounded-[48rpx] !h-[96rpx] !bg-[#007AFF] !border-[#007AFF] shadow-lg shadow-blue-100 !text-[30rpx]"
49 + @click="onSave">
50 + 保存
51 + </nut-button>
31 </view> 52 </view>
32 </view> 53 </view>
33 </view> 54 </view>
......