From d98cb4c2d7c5e88962656186822770f7c0e8fc89 Mon Sep 17 00:00:00 2001 From: wukko Date: Thu, 6 Mar 2025 16:57:49 +0600 Subject: [PATCH] web/util/formatFileSize: don't parseFloat, allow .00 to stick around prevents rapid jiggle in the queue --- web/src/lib/util.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web/src/lib/util.ts b/web/src/lib/util.ts index c590f22e..772f35e2 100644 --- a/web/src/lib/util.ts +++ b/web/src/lib/util.ts @@ -8,7 +8,7 @@ export const formatFileSize = (size: number | undefined) => { units.pop(); } - const roundedSize = parseFloat(size.toFixed(2)); + const roundedSize = size.toFixed(2); const unit = units[units.length - 1] + "B"; return `${roundedSize} ${unit}`; }