Skip to content

Commit 6bb6ea6

Browse files
authoredOct 12, 2024
💄 style: fix artifacts render markdown (lobehub#4327)
1 parent eda92e2 commit 6bb6ea6

File tree

1 file changed

+5
-0
lines changed
  • src/app/(main)/chat/(workspace)/@portal/Artifacts/Body/Renderer

1 file changed

+5
-0
lines changed
 

‎src/app/(main)/chat/(workspace)/@portal/Artifacts/Body/Renderer/index.tsx

+5
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import { Markdown } from '@lobehub/ui';
12
import dynamic from 'next/dynamic';
23
import { memo } from 'react';
34

@@ -16,6 +17,10 @@ const Renderer = memo<{ content: string; type?: string }>(({ content, type }) =>
1617
return <SVGRender content={content} />;
1718
}
1819

20+
case 'text/markdown': {
21+
return <Markdown>{content}</Markdown>;
22+
}
23+
1924
default: {
2025
return <HTMLRenderer htmlContent={content} />;
2126
}

0 commit comments

Comments
 (0)
Please sign in to comment.