Skip to content

Commit 0f257b4

Browse files
authored
Merge pull request blockscout#1421 from blockscout/fe-1412
token transfers fix
2 parents 43637f9 + b0507a2 commit 0f257b4

File tree

2 files changed

+20
-5
lines changed

2 files changed

+20
-5
lines changed

ui/token/TokenTransfer/TokenTransferListItem.tsx

Lines changed: 20 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Flex, Skeleton } from '@chakra-ui/react';
1+
import { Grid, Flex, Skeleton } from '@chakra-ui/react';
22
import React from 'react';
33

44
import type { TokenTransfer } from 'types/api/tokenTransfer';
@@ -72,16 +72,31 @@ const TokenTransferListItem = ({
7272
/>
7373
</Flex>
7474
{ valueStr && (token.type === 'ERC-20' || token.type === 'ERC-1155') && (
75-
<Flex columnGap={ 2 } w="100%">
75+
<Grid gap={ 2 } templateColumns={ `1fr auto auto${ usd ? ' auto' : '' }` }>
7676
<Skeleton isLoaded={ !isLoading } flexShrink={ 0 } fontWeight={ 500 }>
7777
Value
7878
</Skeleton>
79-
<Skeleton isLoaded={ !isLoading } color="text_secondary">
79+
<Skeleton
80+
isLoaded={ !isLoading }
81+
color="text_secondary"
82+
wordBreak="break-all"
83+
overflow="hidden"
84+
flexGrow={ 1 }
85+
>
8086
<span>{ valueStr }</span>
8187
</Skeleton>
8288
{ token.symbol && <TruncatedValue isLoading={ isLoading } value={ token.symbol }/> }
83-
{ usd && <Skeleton isLoaded={ !isLoading } color="text_secondary"><span>(${ usd })</span></Skeleton> }
84-
</Flex>
89+
{ usd && (
90+
<Skeleton
91+
isLoaded={ !isLoading }
92+
color="text_secondary"
93+
wordBreak="break-all"
94+
overflow="hidden"
95+
>
96+
<span>(${ usd })</span>
97+
</Skeleton>
98+
) }
99+
</Grid>
85100
) }
86101
{ 'token_id' in total && (token.type === 'ERC-721' || token.type === 'ERC-1155') && (
87102
<NftEntity
Loading

0 commit comments

Comments
 (0)