Skip to content
This repository was archived by the owner on Oct 11, 2024. It is now read-only.

Commit 907a7c1

Browse files
committed
Fix build errors
1 parent b1639a5 commit 907a7c1

File tree

3 files changed

+8
-4
lines changed

3 files changed

+8
-4
lines changed

ts/pages/governance/vote_form.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ import { Heading, Paragraph } from 'ts/components/text';
1818
import { PreferenceSelecter } from 'ts/pages/governance/preference_selecter';
1919
import { State as ReduxState } from 'ts/redux/reducer';
2020
import { colors } from 'ts/style/colors';
21-
import { PoolWithStats, Providers, ProviderState } from 'ts/types';
21+
import { Network, PoolWithStats, Providers, ProviderState } from 'ts/types';
2222
import { backendClient } from 'ts/utils/backend_client';
2323
import { configs, GOVERNOR_CONTRACT_ADDRESS } from 'ts/utils/configs';
2424
import { constants } from 'ts/utils/constants';

ts/pages/governance/vote_index.tsx

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,10 @@ type ProposalWithOrder = Proposal & {
5353
order?: number;
5454
};
5555

56+
type TreasuryProposalWithOrder = TreasuryProposal & {
57+
order?: number;
58+
}
59+
5660
const PROPOSALS = environments.isProduction() ? prodProposals : stagingProposals;
5761
const ZEIP_IDS = Object.keys(PROPOSALS).map((idString) => parseInt(idString, 10));
5862
const ZEIP_PROPOSALS: ProposalWithOrder[] = ZEIP_IDS.map((id) => PROPOSALS[id]).sort(
@@ -146,7 +150,7 @@ interface Proposals {
146150
export const VoteIndex: React.FC<VoteIndexProps> = () => {
147151
const [filter, setFilter] = React.useState<string>('all');
148152
const [tallys, setTallys] = React.useState<ZeipTallyMap>(undefined);
149-
const [proposals, setProposals] = React.useState<ProposalWithOrder[]>([]);
153+
const [proposals, setProposals] = React.useState<TreasuryProposalWithOrder[]>([]);
150154
const [quorumThreshold, setQuorumThreshold] = React.useState<BigNumber>();
151155
const [isExpanded, setIsExpanded] = React.useState<boolean>(false);
152156
const providerState = useSelector((state: State) => state.providerState);
@@ -299,7 +303,7 @@ export const VoteIndex: React.FC<VoteIndexProps> = () => {
299303
})}
300304
{showTreasury.includes(filter) &&
301305
proposals.length > 0 &&
302-
proposals.map((proposal: TreasuryProposal) => {
306+
proposals.map((proposal: TreasuryProposalWithOrder) => {
303307
const tally = {
304308
no: new BigNumber(proposal.againstVotes.toString()),
305309
yes: new BigNumber(proposal.forVotes.toString()),

ts/pages/governance/vote_index_card.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ interface TreasuryCardProps {
3333
upcoming: boolean;
3434
happening: boolean;
3535
timestamp: moment.Moment;
36-
order: number;
36+
order?: number;
3737
description: string;
3838
tally?: TallyInterface;
3939
status?: string;

0 commit comments

Comments
 (0)