Skip to content

Commit a35ceb0

Browse files
committed
chore: commify juror rewards
1 parent 7449259 commit a35ceb0

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

web/src/components/NumberDisplay.tsx

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
import React from "react";
22

33
import { Tooltip } from "@kleros/ui-components-library";
4+
5+
import { commify } from "utils/commify";
6+
47
interface INumberDisplay {
58
value: string | number;
69
unit?: string;
@@ -31,10 +34,11 @@ const NumberDisplay: React.FC<INumberDisplay> = ({
3134
isCurrency = false,
3235
}) => {
3336
const parsedValue = Number(value);
34-
const formattedValue = getFormattedValue(parsedValue, decimals);
37+
const formattedValue = commify(getFormattedValue(parsedValue, decimals));
3538
const tooltipValue = isCurrency ? `${unit} ${value}` : `${value} ${unit}`;
3639
const displayUnit = showUnitInDisplay ? unit : "";
3740
const displayValue = isCurrency ? `${displayUnit} ${formattedValue}` : `${formattedValue} ${displayUnit}`;
41+
3842
return (
3943
<Tooltip small text={tooltipValue} place={place}>
4044
{displayValue}

0 commit comments

Comments
 (0)