feat(timer): 训练到目标时长不再自动结束,支持超长发挥

- Timer: 到时间触发 onGoalReached(提示)而非自动结束,elapsed/overtime
  继续累加直到用户手动停止
- timer: onGoalReached 播 goal 语音 + goalReached 状态;finishTraining
  补 complete 语音;完成弹窗显示"超长发挥 +X 秒"
- wxml: 超时 badge 训练中也显示;新增 goalReached hint 分支
- voice/tts: 新增 goal 语音 prompt(需部署 tts 云函数)
- config: 版本号 v2.5 -> v2.6

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
2026-07-09 09:37:32 +08:00
parent 6fffc5aece
commit dd9cd1859c
6 changed files with 42 additions and 27 deletions
+6 -2
View File
@@ -46,7 +46,7 @@
<view class="spark s6">💪</view>
</view>
<view class="overtime-badge" wx:if="{{isCompleted && overtime > 0}}">
<view class="overtime-badge" wx:if="{{overtime > 0}}">
<image class="overtime-icon" src="{{icons.hotFill}}" mode="aspectFit"></image>
<text>+{{overtime}}s</text>
</view>
@@ -61,6 +61,10 @@
<block wx:else>今日目标 {{duration}} 秒 · 第 {{planDay}} 天</block>
</text>
</view>
<view class="hint-row" wx:elif="{{status === 'running' && goalReached}}">
<image class="hint-icon running-pulse" src="{{icons.hotFill}}" mode="aspectFit"></image>
<text class="hint-text running">目标达成,继续挑战!</text>
</view>
<view class="hint-row" wx:elif="{{status === 'running'}}">
<image class="hint-icon running-pulse" src="{{icons.likeFill}}" mode="aspectFit"></image>
<text class="hint-text running">保持姿势,核心收紧!</text>
@@ -145,7 +149,7 @@
<view class="completion-overtime" wx:if="{{completionOvertime > 0}}">
<text class="overtime-plus">+{{completionOvertime}}</text>
<text class="overtime-label">秒超</text>
<text class="overtime-label">秒超长发挥</text>
</view>
<view class="completion-streak" wx:if="{{completionStreak > 0}}">