fix line wrap and timestamp font

This commit is contained in:
muzam1l
2022-03-08 19:18:51 +05:30
parent ce91182c7b
commit db0ffe999e
2 changed files with 9 additions and 3 deletions

View File

@@ -172,7 +172,8 @@ export const Log: FC<ILog> = ({
}, },
[accounts] [accounts]
); );
const message = enrichAccounts(_message.trim()); _message = _message.trim().replace(/\n /gi, "\n");
const message = enrichAccounts(_message);
const jsonData = enrichAccounts(_jsonData); const jsonData = enrichAccounts(_jsonData);
return ( return (
@@ -182,8 +183,8 @@ export const Log: FC<ILog> = ({
activeAccountAddress={dialogAccount} activeAccountAddress={dialogAccount}
/> />
<LogText variant={type}> <LogText variant={type}>
{timestamp && <Text muted>{timestamp} </Text>} {timestamp && <Text muted monospace>{timestamp} </Text>}
<Pre line>{message} </Pre> <Pre>{message} </Pre>
{link && ( {link && (
<NextLink href={link} shallow passHref> <NextLink href={link} shallow passHref>
<Link as="a">{linkText}</Link> <Link as="a">{linkText}</Link>

View File

@@ -14,6 +14,11 @@ const Text = styled("span", {
true: { true: {
color: '$mauve9' color: '$mauve9'
} }
},
monospace: {
true: {
fontFamily: '$monospace'
}
} }
} }
}); });