feat(ui): redesign all miniprogram pages

- 全局样式改为粉色(#E6508C)/金色(#DCB982)/绿色(#52c41a)配色
- 所有非tab页使用自定义导航栏,带彩色头部+标题+副标题
- login页: 粉色头部+🌸图标+微信授权登录
- scan页: 粉色头部+虚线扫码框+手动输入按钮
- ble-connect页: 蓝牙提示+搜索中/已发现设备卡片
- bind-success页: 绿色头部+成功图标+7天试用提示卡
- wear-check页: 设备信息行+佩戴指引卡片
- index首页: 粉色设备卡片+开始护理/设备管理按钮
- treatment-setup页: 模式选择+面部地图选区域
- auto-scan页: 面部轮廓+扫描线动画+检测标签
- treating页: 蓝色头部+大倒计时+渐变进度条+放松提示
- treatment-done页: 绿色头部+统计卡片+已记录提示
- subscribe-prompt页: 普通/智能模式对比+试用提示+金色订阅按钮
- subscribe-plans页: 金色头部+服务卡片+月卡/年卡选择
- subscribe-success页: 绿色头部+订阅详情卡+金色按钮
- profile页: 渐变头部+用户行+订阅卡+菜单列表
- history页: 粉色统计行+模式标签记录列表
这个提交包含在:
Guoguo
2026-04-22 21:40:55 +08:00
父节点 a84e37a6e2
当前提交 aa4b215c8b
修改 50 个文件,包含 1535 行新增835 行删除
@@ -3,9 +3,8 @@ var http = require('../../utils/request')
Page({
data: {
plans: [
{ name: '月度套餐', plan: 'monthly', days: 30, price: 29.9', desc: '30天畅享' },
{ name: '季度套餐', plan: 'quarterly', days: 90, price: 79.9', desc: '90天畅享' },
{ name: '年度套餐', plan: 'yearly', days: 365, price: '¥269', desc: '365天畅享' }
{ plan: 'monthly', price: 99', desc: '约3.3元/天' },
{ plan: 'yearly', price: 899', desc: '省¥289' }
],
selected: null,
purchasing: false
@@ -1,3 +1,4 @@
{
"navigationStyle": "custom",
"navigationBarTitleText": "订阅套餐"
}
@@ -1,15 +1,38 @@
<view class="container">
<view wx:for="{{plans}}" wx:key="plan"
class="card plan-card {{selected === item.plan ? 'plan-active' : ''}}"
bindtap="onSelect" data-plan="{{item.plan}}">
<view class="plan-name">{{item.name}}</view>
<view class="plan-price">{{item.price}}</view>
<view class="plan-desc text-muted">{{item.desc}}</view>
<view class="page">
<view class="page-header page-header-gold">
<view class="page-header-title">订阅服务</view>
<view class="page-header-subtitle">解锁智能模式</view>
</view>
<view class="btn-area-fixed">
<view class="btn-primary" bindtap="onPurchase" disabled="{{purchasing || !selected}}">
{{purchasing ? '处理中...' : '立即订阅'}}
<view class="page-content">
<view class="page-title">选择订阅套餐</view>
<view class="service-card">
<view class="service-icon">✨</view>
<view class="service-info">
<view class="service-name">智能模式</view>
<view class="service-desc">根据皮肤状态自动调节</view>
</view>
</view>
<view class="plans">
<view class="plan {{selected === 'monthly' ? 'selected' : ''}}" bindtap="onSelect" data-plan="monthly">
<view class="plan-price">¥99</view>
<view class="plan-name">月卡</view>
<view class="plan-save">约3.3元/天</view>
</view>
<view class="plan {{selected === 'yearly' ? 'selected' : ''}}" bindtap="onSelect" data-plan="yearly">
<view class="plan-tag" wx:if="{{selected !== 'yearly'}}">推荐</view>
<view class="plan-tag plan-tag-active" wx:else>推荐</view>
<view class="plan-price">¥899</view>
<view class="plan-name">年卡</view>
<view class="plan-save">省¥289</view>
</view>
</view>
<button class="btn-primary btn-primary-gold" bindtap="onPurchase" disabled="{{purchasing}}" loading="{{purchasing}}">
确认支付
</button>
<view class="agreement">支付即表示同意《订阅协议》</view>
</view>
</view>
@@ -1,27 +1,94 @@
.plan-card {
text-align: center;
border: 2rpx solid #eeeeee;
transition: border-color 0.2s;
.service-card {
display: flex;
align-items: center;
gap: 20rpx;
padding: 24rpx;
background: #fff9e6;
border: 2rpx solid #DCB982;
border-radius: 20rpx;
margin-bottom: 24rpx;
}
.plan-active {
border-color: #333333;
background-color: #fafafa;
.service-icon {
width: 76rpx;
height: 76rpx;
background: #DCB982;
border-radius: 50%;
display: flex;
align-items: center;
justify-content: center;
color: #ffffff;
font-size: 36rpx;
flex-shrink: 0;
}
.plan-name {
font-size: 32rpx;
.service-name {
font-size: 28rpx;
font-weight: 600;
margin-bottom: 12rpx;
color: #333333;
}
.service-desc {
font-size: 22rpx;
color: #666666;
}
.plans {
display: flex;
gap: 20rpx;
margin-bottom: 24rpx;
}
.plan {
flex: 1;
padding: 24rpx 16rpx;
border: 4rpx solid #e5e5e5;
border-radius: 20rpx;
text-align: center;
position: relative;
}
.plan.selected {
border-color: #E6508C;
background: #fdf2f8;
}
.plan-tag {
position: absolute;
right: -8rpx;
top: -8rpx;
background: #E6508C;
color: #ffffff;
font-size: 18rpx;
padding: 4rpx 12rpx;
border-radius: 12rpx;
}
.plan-price {
font-size: 48rpx;
font-weight: 700;
font-size: 36rpx;
font-weight: 600;
color: #333333;
margin-bottom: 8rpx;
}
.plan-desc {
font-size: 24rpx;
.plan-name {
font-size: 22rpx;
color: #999999;
margin-top: 4rpx;
}
.plan-save {
font-size: 20rpx;
color: #52c41a;
margin-top: 4rpx;
}
.agreement {
text-align: center;
font-size: 22rpx;
color: #999999;
margin-top: 20rpx;
}
.btn-primary-gold::after {
border: none;
}