fix: markdown support in blockquote (#1394)

This commit is contained in:
Zeng1998
2023-03-21 22:38:38 +08:00
committed by GitHub
parent af3d3c2c9b
commit 026fb3e50e

View File

@@ -1,3 +1,5 @@
import { inlineElementParserList } from ".";
import { marked } from "..";
import { matcher } from "../matcher";
export const BLOCKQUOTE_REG = /^> ([^\n]+)/;
@@ -8,7 +10,8 @@ const renderer = (rawStr: string) => {
return <>{rawStr}</>;
}
return <blockquote>{matchResult[1]}</blockquote>;
const parsedContent = marked(matchResult[1], [], inlineElementParserList);
return <blockquote>{parsedContent}</blockquote>;
};
export default {