diff --git a/src/components/basicUIElements/view/userListItem/userListItem.tsx b/src/components/basicUIElements/view/userListItem/userListItem.tsx index 3200c22d09..d03b883932 100644 --- a/src/components/basicUIElements/view/userListItem/userListItem.tsx +++ b/src/components/basicUIElements/view/userListItem/userListItem.tsx @@ -49,7 +49,7 @@ const UserListItem = ({ > {leftItemRenderer && leftItemRenderer()} - {itemIndex && {itemIndex}} + {!!itemIndex && {itemIndex}} {!searchValue && {text || username}} @@ -80,7 +80,7 @@ const UserListItem = ({ {description} )} - {middleText && ( + {!!middleText && ( {rightText} - {subRightText && {subRightText}} + {!!subRightText && {subRightText}} { const _renderItem = ({ item, index }) => { const value = item.reward && `$ ${item.reward}`; - const percent = item.percent100 && `${item.percent100}%`; + const percent = !isNaN(item.percent100) && `${item.percent100}%`; // snippet to avoid rendering time form long past const minTimestamp = new Date(createdAt).getTime();