feat: 优化统计和步数详情页面,添加活动等级计算和展示,更新压力计组件以支持HRV值直接显示

This commit is contained in:
2025-09-05 22:28:04 +08:00
parent e6708e68c2
commit c37c3a16b1
4 changed files with 261 additions and 155 deletions

View File

@@ -465,7 +465,8 @@ async function fetchHeartRateVariability(options: HealthDataOptions): Promise<nu
const latestHrv = res[res.length - 1];
if (latestHrv && latestHrv.value) {
resolve(Math.round(latestHrv.value * 1000));
// HealthKit 中的 HRV 数据已经是毫秒单位,无需转换
resolve(Math.round(latestHrv.value));
} else {
resolve(null);
}