From d2f05c7b71a71971932ecf5a42c4a265d734ec20 Mon Sep 17 00:00:00 2001 From: tianyaxiang Date: Sun, 2 Feb 2025 09:26:17 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=BC=95=E7=94=A8=E5=B5=8C?= =?UTF-8?q?=E5=A5=97=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/lib/markdown.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/lib/markdown.ts b/src/lib/markdown.ts index cb73781..2d9e20b 100644 --- a/src/lib/markdown.ts +++ b/src/lib/markdown.ts @@ -117,7 +117,10 @@ export function convertToWechat(markdown: string, options: RendererOptions = def renderer.blockquote = function({ text }: Tokens.Blockquote) { const style = mergedOptions.block?.blockquote const styleStr = cssPropertiesToString(style) - return `${text}` + const tokens = marked.Lexer.lexInline(text) + const content = marked.Parser.parseInline(tokens, { renderer }) + + return `${content}` } renderer.code = function({ text, lang }: Tokens.Code) {