diff --git a/web/components/contract/contract-card.tsx b/web/components/contract/contract-card.tsx index d1c7dd31..7472dbf4 100644 --- a/web/components/contract/contract-card.tsx +++ b/web/components/contract/contract-card.tsx @@ -17,6 +17,7 @@ import { FreeResponse, FreeResponseContract, FullContract, + NumericContract, } from 'common/contract' import { AnswerLabel, @@ -25,6 +26,7 @@ import { } from '../outcome-label' import { getOutcomeProbability, getTopAnswer } from 'common/calculate' import { AbbrContractDetails } from './contract-details' +import { getValueFromBucket } from 'common/calculate-dpm' export function ContractCard(props: { contract: Contract @@ -164,3 +166,20 @@ export function FreeResponseResolutionOrChance(props: { ) } + +export function NumericResolution(props: { + contract: NumericContract + className?: string +}) { + const { contract, className } = props + const { resolution } = contract + + const resolutionValue = getValueFromBucket(resolution, contract) + + return ( +