Skip to content

Commit

Permalink
feat(web): adding missing round inside case overview
Browse files Browse the repository at this point in the history
  • Loading branch information
kemuru committed Sep 9, 2023
1 parent 7cbc1db commit 360fcb6
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion web/src/pages/Cases/CaseDetails/Overview.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ import PolicyIcon from "svgs/icons/policy.svg";
import { StyledSkeleton } from "components/StyledSkeleton";
import DisputeInfo from "components/DisputeCard/DisputeInfo";
import Verdict from "components/Verdict/index";
import { useVotingHistory } from "hooks/queries/useVotingHistory";

const Container = styled.div`
width: 100%;
Expand Down Expand Up @@ -86,10 +87,13 @@ const Overview: React.FC<IOverview> = ({ arbitrable, courtID, currentPeriodIndex
const { data: disputeDetails } = useDisputeDetailsQuery(id);
const { data: courtPolicyURI } = useCourtPolicyURI(courtID);
const { data: courtPolicy } = useCourtPolicy(courtID);
const { data: votingHistory } = useVotingHistory(id);
const courtName = courtPolicy?.name;
const court = disputeDetails?.dispute?.court;
const rewards = court ? `≥ ${formatEther(court.feeForJuror)} ETH` : undefined;
const category = disputeTemplate ? disputeTemplate.category : undefined;
const localRounds = votingHistory?.dispute?.disputeKitDispute?.localRounds;

return (
<>
<Container>
Expand Down Expand Up @@ -126,7 +130,7 @@ const Overview: React.FC<IOverview> = ({ arbitrable, courtID, currentPeriodIndex
</>
)}

<DisputeInfo courtId={court?.id} court={courtName} {...{ rewards, category }} />
<DisputeInfo courtId={court?.id} court={courtName} round={localRounds?.length} {...{ rewards, category }} />
</Container>
<ShadeArea>
<p>Make sure you understand the Policies</p>
Expand Down

0 comments on commit 360fcb6

Please sign in to comment.