Dashboards: Fix 'days' unit pluralization (#93326)

This commit is contained in:
kay delaney 2024-09-18 10:00:42 +01:00 committed by GitHub
parent eb3f64b3f8
commit 98a4d2858a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -185,7 +185,7 @@ export function toDays(size: number, decimals?: DecimalCount): FormattedValue {
}
if (Math.abs(size) < 7) {
return { text: toFixed(size, decimals), suffix: ' day' };
return toFixedScaled(size, decimals, ' day');
} else if (Math.abs(size) < 365) {
return toFixedScaled(size / 7, decimals, ' week');
} else {