diff --git a/packages/page-tech-comm/src/Proposals/Proposal.tsx b/packages/page-tech-comm/src/Proposals/Proposal.tsx index b2f5fe0644..44ef4a7a45 100644 --- a/packages/page-tech-comm/src/Proposals/Proposal.tsx +++ b/packages/page-tech-comm/src/Proposals/Proposal.tsx @@ -90,6 +90,7 @@ function Proposal ({ className = '', imageHash, members, prime }: Props): React. {isVoteable && !isCloseable && ( diff --git a/packages/page-tech-comm/src/Proposals/Voting.tsx b/packages/page-tech-comm/src/Proposals/Voting.tsx index 388a7fa7a6..eafffb7ee2 100644 --- a/packages/page-tech-comm/src/Proposals/Voting.tsx +++ b/packages/page-tech-comm/src/Proposals/Voting.tsx @@ -12,11 +12,12 @@ import { useTranslation } from '../translate'; interface Props { hash: Hash | string; + members: string[]; prime?: AccountId | null; proposalId: BN | number; } -function Voting ({ hash, prime, proposalId }: Props): React.ReactElement | null { +function Voting ({ hash, members, prime, proposalId }: Props): React.ReactElement | null { const { t } = useTranslation(); const { hasAccounts } = useAccounts(); const [accountId, setAccountId] = useState(null); @@ -26,8 +27,6 @@ function Voting ({ hash, prime, proposalId }: Props): React.ReactElement return null; } - const isPrime = accountId === prime?.toString(); - return ( <> {isVotingOpen && ( @@ -36,8 +35,11 @@ function Voting ({ hash, prime, proposalId }: Props): React.ReactElement size='small' > - - {isPrime && ( + + {(accountId === prime?.toString()) && (
{t('You are voting with this collective\'s prime account. The vote will be the default outcome in case of any abstentions.')}