Commit 84d0f06f authored by tom's avatar tom

minor fixes

parent 85a25d22
...@@ -49,15 +49,18 @@ const BlockPageContent = () => { ...@@ -49,15 +49,18 @@ const BlockPageContent = () => {
const hasPagination = !isMobile && router.query.tab === 'txs' && blockTxsQuery.isPaginationVisible; const hasPagination = !isMobile && router.query.tab === 'txs' && blockTxsQuery.isPaginationVisible;
const referrer = isInBrowser ? window.document.referrer : appProps.referrer; const referrer = isInBrowser ? window.document.referrer : appProps.referrer;
const hasGoBackLink = referrer && referrer.includes('/blocks');
return ( return (
<Page> <Page>
<Flex alignItems="center" columnGap={ 3 }> <Flex alignItems="center" columnGap={ 3 }>
{ hasGoBackLink && (
<Tooltip label="Back to blocks list"> <Tooltip label="Back to blocks list">
<Link mb={ 6 } display="inline-flex" href={ referrer }> <Link mb={ 6 } display="inline-flex" href={ referrer }>
<Icon as={ eastArrowIcon } boxSize={ 6 } transform="rotate(180deg)"/> <Icon as={ eastArrowIcon } boxSize={ 6 } transform="rotate(180deg)"/>
</Link> </Link>
</Tooltip> </Tooltip>
) }
<PageTitle text={ `Block #${ router.query.id }` }/> <PageTitle text={ `Block #${ router.query.id }` }/>
</Flex> </Flex>
<RoutedTabs <RoutedTabs
......
...@@ -77,6 +77,7 @@ const TxsListItem = ({ tx, showBlockInfo, currentAddress }: Props) => { ...@@ -77,6 +77,7 @@ const TxsListItem = ({ tx, showBlockInfo, currentAddress }: Props) => {
</Flex> </Flex>
<Text variant="secondary" fontWeight="400" fontSize="sm">{ dayjs(tx.timestamp).fromNow() }</Text> <Text variant="secondary" fontWeight="400" fontSize="sm">{ dayjs(tx.timestamp).fromNow() }</Text>
</Flex> </Flex>
{ tx.method && (
<Flex mt={ 3 }> <Flex mt={ 3 }>
<Text as="span" whiteSpace="pre">Method </Text> <Text as="span" whiteSpace="pre">Method </Text>
<Text <Text
...@@ -89,6 +90,7 @@ const TxsListItem = ({ tx, showBlockInfo, currentAddress }: Props) => { ...@@ -89,6 +90,7 @@ const TxsListItem = ({ tx, showBlockInfo, currentAddress }: Props) => {
{ tx.method } { tx.method }
</Text> </Text>
</Flex> </Flex>
) }
{ showBlockInfo && tx.block !== null && ( { showBlockInfo && tx.block !== null && (
<Box mt={ 2 }> <Box mt={ 2 }>
<Text as="span">Block </Text> <Text as="span">Block </Text>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment