feat: 训练完成后首页 streak 卡片高亮 3 秒

timer 记录保存时写 _last_train_at 时间戳,index onShow 检测
< 10s 的标记则触发 just-completed class,卡片脉冲 2 次 + 主题色
边框 + 阴影,3 秒后自动淡出。让'完成训练'的反馈在首页也可见。
This commit is contained in:
2026-07-08 14:13:50 +08:00
parent c0f7ca612c
commit f052327276
4 changed files with 43 additions and 1 deletions
+12
View File
@@ -350,3 +350,15 @@
padding: 12rpx 0;
margin-top: 8rpx;
}
/* ---- 训练完成高亮 (3 秒后淡出) ---- */
.just-completed {
animation: justCompletedPulse 1s ease-in-out 2;
border: 4rpx solid var(--primary) !important;
box-shadow: 0 4rpx 24rpx rgba(var(--primary-rgb), 0.3) !important;
}
@keyframes justCompletedPulse {
0%, 100% { transform: scale(1); }
50% { transform: scale(1.02); }
}