Skip to content

Commit

Permalink
chore(isct-293): add 3 digits to show in chart v4 tooltip
Browse files Browse the repository at this point in the history
  • Loading branch information
AndyKIron committed Mar 17, 2024
1 parent 41a2b41 commit 1b907ef
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -584,7 +584,8 @@ export abstract class ChartBaseComponent implements OnInit, OnDestroy, OnChanges
retVal =
'$' +
this.numberToStringPipe.transform(value, {
noSeparateBySpace: true
noSeparateBySpace: true,
precision: this.componentVersion === 4 ? 3 : undefined
});
break;
case 'percent':
Expand All @@ -596,7 +597,8 @@ export abstract class ChartBaseComponent implements OnInit, OnDestroy, OnChanges
case 'shortString':
retVal = !!value
? this.numberToStringPipe.transform(value, {
noSeparateBySpace: true
noSeparateBySpace: true,
precision: this.componentVersion === 4 ? 3 : undefined
})
: value;
break;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,6 @@ export class ShortNumberScaleSuffixPipe implements PipeTransform {
numberToShow = bigPart.toPrecision(precision);
}

return `${numberToShow}${noSpaceDelimiter ? '' : ' '}${['', 'K', 'M', 'G', 'T', 'P', 'E', 'Z', 'Y'][i] ?? ''}`.trim();
return `${numberToShow}${noSpaceDelimiter ? '' : ' '}${['', 'K', 'M', 'B', 'T', 'P', 'E', 'Z', 'Y'][i] ?? ''}`.trim();
}
}

0 comments on commit 1b907ef

Please sign in to comment.