Add commas to animated count (#125)

This commit is contained in:
Maria Rushkova 2021-07-16 11:49:47 +02:00 committed by GitHub
parent c082c06df3
commit 7744edeee8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 3 deletions

View File

@ -7,7 +7,6 @@ import { VoteType, voteTypes } from './../../constants/voteTypes'
import { CurrentVoting } from '../../models/community'
import { VoteGraphBar } from './VoteGraphBar'
import { formatTimeLeft } from '../../helpers/fomatTimeLeft'
export interface VoteChartProps {
vote: CurrentVoting
voteWinner?: number
@ -51,7 +50,7 @@ export function VoteChart({
<span>
{' '}
{isAnimation && proposingAmount && selectedVote && selectedVote.type === 0 ? (
<CountUp end={votesAgainst + proposingAmount} />
<CountUp end={votesAgainst + proposingAmount} separator="," />
) : (
addCommas(votesAgainst)
)}{' '}
@ -66,7 +65,7 @@ export function VoteChart({
<span>
{' '}
{isAnimation && proposingAmount && selectedVote && selectedVote.type === 1 ? (
<CountUp end={votesFor + proposingAmount} />
<CountUp end={votesFor + proposingAmount} separator="," />
) : (
addCommas(votesFor)
)}{' '}