From 27f60d14b16ff46ed29ee93a9176b17444e5d6f9 Mon Sep 17 00:00:00 2001 From: Maksymilian Gala Date: Sat, 20 Jul 2024 23:25:01 +0200 Subject: [PATCH] Format MBLD results below 1 minute more clearly --- client/src/lib/attempt-result.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/client/src/lib/attempt-result.js b/client/src/lib/attempt-result.js index c9d322b..55b4f7d 100644 --- a/client/src/lib/attempt-result.js +++ b/client/src/lib/attempt-result.js @@ -267,7 +267,9 @@ function formatMbldAttemptResult(attemptResult) { decodeMbldAttemptResult(attemptResult); const clockFormat = centisecondsToClockFormat(centiseconds); const shortClockFormat = clockFormat.replace(/\.00$/, ""); - return `${solved}/${attempted} ${shortClockFormat}`; + return `${solved}/${attempted} ${ + centiseconds < 6000 ? `0:${shortClockFormat}` : shortClockFormat + }`; } function formatFmAttemptResult(attemptResult) {