fix issues related to syntax highlighting
This commit is contained in:
parent
9aa8d8a688
commit
91ccc80a97
|
@ -86,12 +86,12 @@ export default memo(function Text ({ nofollow, imgproxyUrls, children, tab, ...o
|
||||||
const Code = useCallback(({ node, inline, className, children, style, ...props }) => {
|
const Code = useCallback(({ node, inline, className, children, style, ...props }) => {
|
||||||
return inline
|
return inline
|
||||||
? (
|
? (
|
||||||
<code className={className} style={atomDark} {...props}>
|
<code className={className} {...props}>
|
||||||
{children}
|
{children}
|
||||||
</code>
|
</code>
|
||||||
)
|
)
|
||||||
: (
|
: (
|
||||||
<SyntaxHighlighter showLineNumbers style={atomDark} PreTag='div' {...props}>
|
<SyntaxHighlighter style={atomDark} language='text' PreTag='div' {...props}>
|
||||||
{children}
|
{children}
|
||||||
</SyntaxHighlighter>
|
</SyntaxHighlighter>
|
||||||
)
|
)
|
||||||
|
|
Loading…
Reference in New Issue