fix: track token_list_rank (#4857)

This commit is contained in:
vignesh mohankumar 2022-10-10 23:15:47 -05:00 committed by GitHub
parent a75e239fd2
commit 5d1377af80
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -488,12 +488,14 @@ export const LoadedRow = forwardRef((props: LoadedRowProps, ref: ForwardedRef<HT
const delta = token.market?.pricePercentChange?.value const delta = token.market?.pricePercentChange?.value
const arrow = getDeltaArrow(delta) const arrow = getDeltaArrow(delta)
const formattedDelta = formatDelta(delta) const formattedDelta = formatDelta(delta)
const rank = sortAscending ? tokenListLength - tokenListIndex : tokenListIndex + 1
const exploreTokenSelectedEventProperties = { const exploreTokenSelectedEventProperties = {
chain_id: filterNetwork, chain_id: filterNetwork,
token_address: tokenAddress, token_address: tokenAddress,
token_symbol: tokenSymbol, token_symbol: tokenSymbol,
token_list_index: tokenListIndex, token_list_index: tokenListIndex,
token_list_rank: rank,
token_list_length: tokenListLength, token_list_length: tokenListLength,
time_frame: timePeriod, time_frame: timePeriod,
search_token_address_input: filterString, search_token_address_input: filterString,
@ -518,7 +520,7 @@ export const LoadedRow = forwardRef((props: LoadedRowProps, ref: ForwardedRef<HT
<FavoriteIcon isFavorited={isFavorited} /> <FavoriteIcon isFavorited={isFavorited} />
</ClickFavorited> </ClickFavorited>
} }
listNumber={sortAscending ? tokenListLength - tokenListIndex : tokenListIndex + 1} listNumber={rank}
tokenInfo={ tokenInfo={
<ClickableName> <ClickableName>
<LogoContainer> <LogoContainer>