generated from nhcarrigan/template
fix: display sub-one values with two decimal places (#25)
This commit is contained in:
@@ -73,7 +73,9 @@ const formatSuffix = (value: number): string => {
|
||||
return `${(value / threshold).toFixed(2)}${suffix}`;
|
||||
}
|
||||
}
|
||||
return value.toFixed(1);
|
||||
return value < 1
|
||||
? value.toFixed(2)
|
||||
: value.toFixed(1);
|
||||
};
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user