Skip to content

Commit

Permalink
Adds supermajority display to BIP votes
Browse files Browse the repository at this point in the history
  • Loading branch information
uncoolzero committed Jul 4, 2023
1 parent b354830 commit 42d0f9c
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions projects/ui/src/components/Governance/Actions/Vote.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ const VoteForm: FC<
/// Proposal specific voting power
votingPower,
tag,
type,
},
loading: loadingQuorum,
} = quorum;
Expand Down Expand Up @@ -291,6 +292,27 @@ const VoteForm: FC<
)}
</StatHorizontal>
)}
{quorumPct && totalForQuorum && type === "BIP" && (
<StatHorizontal
label={
<>
<Row display="inline-flex" alignItems="center">
<span>Supermajority</span>
</Row>
</>
}
>
{loadingQuorum ? (
<CircularProgress size={16} />
) : (
<>
~{displayFullBN((totalOutstanding || ZERO_BN).multipliedBy(0.667), 0)}{' '}
{isNFT ? 'BEANFT' : 'STALK'}&nbsp;·&nbsp;
66.7%
</>
)}
</StatHorizontal>
)}
<Divider />
{proposal.choices.map((choice: string, index: number) => (
<Stack gap={0.5} key={choice}>
Expand Down

0 comments on commit 42d0f9c

Please sign in to comment.