mirror of
https://github.com/ItzCrazyKns/Perplexica.git
synced 2026-04-10 13:54:28 +00:00
feat(app): fix build issues
This commit is contained in:
@@ -7,6 +7,9 @@ import SyntaxHighlighter from 'react-syntax-highlighter';
|
|||||||
import darkTheme from './CodeBlockDarkTheme';
|
import darkTheme from './CodeBlockDarkTheme';
|
||||||
import lightTheme from './CodeBlockLightTheme';
|
import lightTheme from './CodeBlockLightTheme';
|
||||||
|
|
||||||
|
const SyntaxHighlighterComponent =
|
||||||
|
SyntaxHighlighter as unknown as React.ComponentType<any>;
|
||||||
|
|
||||||
const CodeBlock = ({
|
const CodeBlock = ({
|
||||||
language,
|
language,
|
||||||
children,
|
children,
|
||||||
@@ -50,13 +53,13 @@ const CodeBlock = ({
|
|||||||
/>
|
/>
|
||||||
)}
|
)}
|
||||||
</button>
|
</button>
|
||||||
<SyntaxHighlighter
|
<SyntaxHighlighterComponent
|
||||||
language={language}
|
language={language}
|
||||||
style={syntaxTheme}
|
style={syntaxTheme}
|
||||||
showInlineLineNumbers
|
showInlineLineNumbers
|
||||||
>
|
>
|
||||||
{children as string}
|
{children as string}
|
||||||
</SyntaxHighlighter>
|
</SyntaxHighlighterComponent>
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user