Fix incorrect hour/minute calculation in simpleTimeLabel()

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-03-07 07:05:41 +08:00
parent f4fbae8a5c
commit 702d508d37
2 changed files with 22 additions and 2 deletions

View File

@@ -131,8 +131,8 @@ export function simpleTimeLabel(second, fixedNumber = 0) {
const hour = 60 * 60;
const minutes = 60;
const dd = Math.floor(second / day);
const hh = Math.floor((second / hour) / day);
const mm = Math.floor((second / hour) / minutes);
const hh = Math.floor((second % day) / hour);
const mm = Math.floor((second % hour) / minutes);
if(dd > 0){
return (second / day).toFixed(fixedNumber) + "d";