From a9028b0a945047da937547e6e33e7646a016db68 Mon Sep 17 00:00:00 2001 From: James Grugett Date: Wed, 13 Apr 2022 15:47:10 -0500 Subject: [PATCH] Remove invested metric for cfmm markets --- web/components/bets-list.tsx | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/web/components/bets-list.tsx b/web/components/bets-list.tsx index f5511f95..cc7f0a6a 100644 --- a/web/components/bets-list.tsx +++ b/web/components/bets-list.tsx @@ -306,8 +306,9 @@ export function MyBetsSummary(props: { className?: string }) { const { bets, contract, className } = props - const { resolution, outcomeType } = contract + const { resolution, outcomeType, mechanism } = contract const isBinary = outcomeType === 'BINARY' + const isCpmm = mechanism === 'cpmm-1' const excludeSales = bets.filter((b) => !b.isSold && !b.sale) const yesWinnings = _.sumBy(excludeSales, (bet) => @@ -324,12 +325,14 @@ export function MyBetsSummary(props: { return ( - -
- Invested -
-
{formatMoney(invested)}
- + {!isCpmm && ( + +
+ Invested +
+
{formatMoney(invested)}
+ + )} {resolution ? (
Payout