Removed markdown to not cause problems
This commit is contained in:
parent
83631d56e7
commit
a8c474588c
1 changed files with 13 additions and 12 deletions
|
|
@ -186,7 +186,7 @@ export default function ChatMessage({
|
||||||
/>
|
/>
|
||||||
) : (
|
) : (
|
||||||
<Markdown
|
<Markdown
|
||||||
remarkPlugins={[remarkGfm, remarkMath]}
|
remarkPlugins={[remarkGfm]}
|
||||||
rehypePlugins={[rehypeMathjax]}
|
rehypePlugins={[rehypeMathjax]}
|
||||||
className={cn(
|
className={cn(
|
||||||
"markdown prose flex flex-col word-break-break-word dark:prose-invert",
|
"markdown prose flex flex-col word-break-break-word dark:prose-invert",
|
||||||
|
|
@ -205,18 +205,19 @@ export default function ChatMessage({
|
||||||
children,
|
children,
|
||||||
...props
|
...props
|
||||||
}) => {
|
}) => {
|
||||||
if ((children as string)!.length) {
|
if(typeof children === "string"){
|
||||||
if (children![0] === "▍") {
|
if ((children as string)!.length) {
|
||||||
return (
|
if (children![0] === "▍") {
|
||||||
<span className="form-modal-markdown-span">
|
return (
|
||||||
▍
|
<span className="form-modal-markdown-span">
|
||||||
</span>
|
▍
|
||||||
);
|
</span>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
children![0] = (
|
||||||
|
children![0] as string
|
||||||
|
).replace("`▍`", "▍");
|
||||||
}
|
}
|
||||||
|
|
||||||
children![0] = (
|
|
||||||
children![0] as string
|
|
||||||
).replace("`▍`", "▍");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
const match = /language-(\w+)/.exec(
|
const match = /language-(\w+)/.exec(
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue