generated from nhcarrigan/template
feat: another balance and bug fix pass #238
@@ -127,7 +127,7 @@ const formatInteger = (value: number): string => {
|
|||||||
const steps = stepsAboveBase * 3;
|
const steps = stepsAboveBase * 3;
|
||||||
const divisorExp = letterBaseExp + steps;
|
const divisorExp = letterBaseExp + steps;
|
||||||
const divisor = Math.pow(10, divisorExp);
|
const divisor = Math.pow(10, divisorExp);
|
||||||
return `${String(Math.floor(value / divisor))}${getLetterSuffix(stepsAboveBase)}`;
|
return `${String(Math.round(value / divisor))}${getLetterSuffix(stepsAboveBase)}`;
|
||||||
}
|
}
|
||||||
for (const { threshold, suffix } of namedSuffixes) {
|
for (const { threshold, suffix } of namedSuffixes) {
|
||||||
if (value >= threshold) {
|
if (value >= threshold) {
|
||||||
|
|||||||
Reference in New Issue
Block a user