@@ -15,13 +15,14 @@ import { usePopulatedDisputeData } from "hooks/queries/usePopulatedDisputeData";
15
15
import { useVotingHistory } from "hooks/queries/useVotingHistory" ;
16
16
import { useVotingContext } from "hooks/useVotingContext" ;
17
17
import { getLocalRounds } from "utils/getLocalRounds" ;
18
+ import { isUndefined } from "utils/index" ;
18
19
19
20
import { useDisputeDetailsQuery } from "queries/useDisputeDetailsQuery" ;
20
21
21
22
import { responsiveSize } from "styles/responsiveSize" ;
22
23
24
+ import RulingAndRewardsIndicators from "./RulingAndRewardsIndicators" ;
23
25
import AnswerDisplay from "./Answer" ;
24
- import VerdictBanner from "./VerdictBanner" ;
25
26
import { Divider } from "../Divider" ;
26
27
import { StyledArrowLink } from "../StyledArrowLink" ;
27
28
@@ -90,6 +91,8 @@ const FinalDecision: React.FC<IFinalDecision> = ({ arbitrable }) => {
90
91
} ) ;
91
92
const currentRuling = Number ( currentRulingArray ?. [ 0 ] ) ;
92
93
const answer = populatedDisputeData ?. answers ?. [ currentRuling ! - 1 ] ;
94
+ const rounds = votingHistory ?. dispute ?. rounds ;
95
+ const jurorRewardsDispersed = useMemo ( ( ) => Boolean ( rounds ?. every ( ( round ) => round . jurorRewardsDispersed ) ) , [ rounds ] ) ;
93
96
const buttonText = useMemo ( ( ) => {
94
97
if ( ! wasDrawn || isDisconnected ) return "Check how the jury voted" ;
95
98
if ( isCommitPeriod && ! commited ) return "Commit your vote" ;
@@ -101,7 +104,12 @@ const FinalDecision: React.FC<IFinalDecision> = ({ arbitrable }) => {
101
104
return (
102
105
< Container >
103
106
< VerdictContainer >
104
- < VerdictBanner ruled = { ruled } />
107
+ { ! isUndefined ( Boolean ( disputeDetails ?. dispute ?. ruled ) ) || jurorRewardsDispersed ? (
108
+ < RulingAndRewardsIndicators
109
+ ruled = { Boolean ( disputeDetails ?. dispute ?. ruled ) }
110
+ jurorRewardsDispersed = { jurorRewardsDispersed }
111
+ />
112
+ ) : null }
105
113
{ ruled && (
106
114
< JuryContainer >
107
115
< JuryDecisionTag > The jury decided in favor of:</ JuryDecisionTag >
0 commit comments