refactor(index): 去掉首页底部 toolbar 上方的小提示卡片
- 删除首页随机姿势提示卡片(homeTip):wxml 移除 tip-card 整块、wxss 清理 .tip-card/.tip-icon/.tip-text、js 移除 homeTip 逻辑 - config.postureTips 仍被训练页复用,保留不动
This commit is contained in:
@@ -4,7 +4,7 @@
|
|||||||
*/
|
*/
|
||||||
module.exports = {
|
module.exports = {
|
||||||
/** 应用版本号,外显在设置页「关于」 */
|
/** 应用版本号,外显在设置页「关于」 */
|
||||||
version: 'v3.02',
|
version: 'v3.1',
|
||||||
|
|
||||||
/** 最后更新日期,外显在设置页「关于」 */
|
/** 最后更新日期,外显在设置页「关于」 */
|
||||||
updatedAt: '2026-07-31',
|
updatedAt: '2026-07-31',
|
||||||
@@ -25,7 +25,7 @@ module.exports = {
|
|||||||
* 耐力榜领奖台顶部文案。哲理注脚,点出"撑得越久不一定越好"的价值观,
|
* 耐力榜领奖台顶部文案。哲理注脚,点出"撑得越久不一定越好"的价值观,
|
||||||
* 与耐力榜(比谁单次撑最久)形成反差。仅耐力榜领奖台顶部显示,改这里即可。
|
* 与耐力榜(比谁单次撑最久)形成反差。仅耐力榜领奖台顶部显示,改这里即可。
|
||||||
*/
|
*/
|
||||||
leaderboardPodiumSlogan: '平板支撑不是一场和时间的恋爱。撑得越久,不一定越好;真正重要的,是每一秒都没有辜负身体。',
|
leaderboardPodiumSlogan: '平板支撑不是一场和时间的恋爱,撑得越久,不一定越好。真正重要的,是每一秒都没有辜负身体。',
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 语音合成(TTS)参数 - 直接改这里调整音色/音量/语速,无需改逻辑代码。
|
* 语音合成(TTS)参数 - 直接改这里调整音色/音量/语速,无需改逻辑代码。
|
||||||
|
|||||||
@@ -15,7 +15,6 @@ Page({
|
|||||||
todayDone: false,
|
todayDone: false,
|
||||||
todayDuration: 0,
|
todayDuration: 0,
|
||||||
todayTargetText: '',
|
todayTargetText: '',
|
||||||
homeTip: '',
|
|
||||||
// Ring number font size in rpx. WeChat auto-scales text by the user's
|
// Ring number font size in rpx. WeChat auto-scales text by the user's
|
||||||
// font-size setting (fontSizeScaleFactor) but does NOT scale rpx box
|
// font-size setting (fontSizeScaleFactor) but does NOT scale rpx box
|
||||||
// dimensions — so on a real device with enlarged system font the 84rpx
|
// dimensions — so on a real device with enlarged system font the 84rpx
|
||||||
@@ -148,10 +147,6 @@ Page({
|
|||||||
// 分段格子(每天一格)只在计划天数 <= 10 时用;更长则退化为里程碑连续条,避免格子过密
|
// 分段格子(每天一格)只在计划天数 <= 10 时用;更长则退化为里程碑连续条,避免格子过密
|
||||||
const useSegments = plan.totalDays > 0 && plan.totalDays <= 10
|
const useSegments = plan.totalDays > 0 && plan.totalDays <= 10
|
||||||
const planDays = useSegments ? Array.from({ length: plan.totalDays }, (_, i) => i) : []
|
const planDays = useSegments ? Array.from({ length: plan.totalDays }, (_, i) => i) : []
|
||||||
// 首页姿势要领:从 config.postureTips 随机取一条,每次刷新都换,
|
|
||||||
// 让用户反复进首页能看到不同要领。配置为空时回退到默认文案,避免空白。
|
|
||||||
const tips = config.postureTips || []
|
|
||||||
const homeTip = tips.length ? tips[Math.floor(Math.random() * tips.length)] : '保持身体成一条直线,核心收紧,均匀呼吸'
|
|
||||||
this.setData({
|
this.setData({
|
||||||
theme,
|
theme,
|
||||||
icons: iconsMod.build(theme),
|
icons: iconsMod.build(theme),
|
||||||
@@ -165,8 +160,7 @@ Page({
|
|||||||
planTotal: plan.totalDays,
|
planTotal: plan.totalDays,
|
||||||
planProgress,
|
planProgress,
|
||||||
useSegments,
|
useSegments,
|
||||||
planDays,
|
planDays
|
||||||
homeTip
|
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|||||||
@@ -101,14 +101,6 @@
|
|||||||
></ui-btn>
|
></ui-btn>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<!-- 小提示 -->
|
|
||||||
<ui-card variant="soft" padded="{{false}}">
|
|
||||||
<view class="tip-card">
|
|
||||||
<image class="tip-icon" src="{{icons.lightFill}}" mode="aspectFit"></image>
|
|
||||||
<text class="tip-text">{{homeTip}}</text>
|
|
||||||
</view>
|
|
||||||
</ui-card>
|
|
||||||
|
|
||||||
<!-- 时间选择弹窗 -->
|
<!-- 时间选择弹窗 -->
|
||||||
<ui-modal
|
<ui-modal
|
||||||
visible="{{showPicker}}"
|
visible="{{showPicker}}"
|
||||||
|
|||||||
@@ -313,29 +313,6 @@
|
|||||||
margin: 8rpx 0 8rpx;
|
margin: 8rpx 0 8rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ---- tip card ---- */
|
|
||||||
.tip-card {
|
|
||||||
display: flex;
|
|
||||||
align-items: flex-start;
|
|
||||||
padding: 24rpx 32rpx;
|
|
||||||
background: transparent;
|
|
||||||
border-radius: 20rpx;
|
|
||||||
}
|
|
||||||
|
|
||||||
.tip-icon {
|
|
||||||
width: 32rpx;
|
|
||||||
height: 32rpx;
|
|
||||||
margin-right: 12rpx;
|
|
||||||
flex-shrink: 0;
|
|
||||||
align-self: center;
|
|
||||||
}
|
|
||||||
|
|
||||||
.tip-text {
|
|
||||||
font-size: 28rpx;
|
|
||||||
color: var(--text-secondary);
|
|
||||||
line-height: 1.6;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* ---- picker ---- */
|
/* ---- picker ---- */
|
||||||
.picker-title {
|
.picker-title {
|
||||||
font-size: 34rpx;
|
font-size: 34rpx;
|
||||||
|
|||||||
Reference in New Issue
Block a user