privacy-scaling-explorations / maci-platform

MACI Platform - Voting and Funding using MACI
https://maci-platform.vercel.app
16 stars 15 forks source link

Bug(interface): prevent negative countdown timer #284

Closed kittybest closed 2 months ago

kittybest commented 2 months ago

Description When voting period is over the timer is negative, should move to the next period --> check why it's not moving to the Tallying status.

ctrlc03 commented 2 months ago

@kittybest maybe here https://github.com/privacy-scaling-explorations/maci-platform/blob/main/packages/interface/src/components/VotingInfo.tsx#L21-L23 we need to add

  {!isLoading && timeLeft[3] < 0 && <p>Voting has ended</p>}

?

kittybest commented 2 months ago

@kittybest maybe here https://github.com/privacy-scaling-explorations/maci-platform/blob/main/packages/interface/src/components/VotingInfo.tsx#L21-L23 we need to add

  {!isLoading && timeLeft[3] < 0 && <p>Voting has ended</p>}

?

I'm just thinking about if the timeLeft < 0, the state should be moved to Tally? So actually this shouldn't happen. But it's a efficient way to prevent negative timer displayed.

kittybest commented 2 months ago

close by #290