Skip to content

Commit

Permalink
feat: show proposal activation time (#947)
Browse files Browse the repository at this point in the history
  • Loading branch information
emccorson committed Jul 26, 2024
1 parent 6e8729d commit 513e1ba
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
6 changes: 3 additions & 3 deletions apps/namadillo/src/App/Governance/VoteInfoCards.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { AddRemove, PgfActions, Proposal } from "@namada/types";

import { proposalFamily } from "atoms/proposals";
import { useAtomValue } from "jotai";
import { epochToString, secondsToDateTimeString } from "utils";
import { secondsToDateTimeString } from "utils";

const InfoCard: React.FC<
{
Expand Down Expand Up @@ -129,8 +129,8 @@ const Loaded: React.FC<{
className="col-span-2"
/>
<InfoCard
title="Activation Epoch"
content={epochToString(proposal.activationEpoch)}
title="Activation Time"
content={secondsToDateTimeString(proposal.activationTime)}
className="col-span-2"
/>
<InfoCard
Expand Down
1 change: 1 addition & 0 deletions apps/namadillo/src/atoms/proposals/functions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,7 @@ const toProposal = (
activationEpoch: BigInt(proposal.activationEpoch),
startTime: BigInt(proposal.startTime),
endTime: BigInt(proposal.endTime),
activationTime: BigInt(proposal.activationTime),
currentTime: BigInt(proposal.currentTime),
proposalType: decodeProposalType(proposal.type, proposal.data),
tallyType: toTally(proposal.tallyType),
Expand Down
1 change: 1 addition & 0 deletions packages/types/src/proposals.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ export type Proposal = {
activationEpoch: bigint;
startTime: bigint;
endTime: bigint;
activationTime: bigint;
currentTime: bigint;
proposalType: ProposalType;
tallyType: TallyType;
Expand Down

0 comments on commit 513e1ba

Please sign in to comment.