From 0f13cb82cd3b5fc20ed79321b8fea870db1868f8 Mon Sep 17 00:00:00 2001 From: wujingjing <gersonwu@qq.com> Date: 星期五, 03 一月 2025 17:05:02 +0800 Subject: [PATCH] input-select --- src/components/chat/libs/markdown.ts | 21 +++++++++++---------- 1 files changed, 11 insertions(+), 10 deletions(-) diff --git a/src/components/chat/libs/markdown.ts b/src/components/chat/libs/markdown.ts index 0a002fe..7ccbe37 100644 --- a/src/components/chat/libs/markdown.ts +++ b/src/components/chat/libs/markdown.ts @@ -1,4 +1,4 @@ -import highlight from 'highlight.js'; +// import highlight from 'highlight.js'; import Markdown from 'markdown-it'; const mdOptions: Markdown.Options = { @@ -7,15 +7,16 @@ breaks: true, langPrefix: 'language-', // 浠g爜楂樹寒 - highlight(str, lang) { - if (lang && highlight.getLanguage(lang)) { - try { - return '<pre class="hljs"><code>' + highlight.highlight(lang, str, true).value + '</code></pre>'; - } catch (__) { - } - } - return ''; - }, + // hightlight 鍔犺浇杩囨參 + // highlight(str, lang) { + // if (lang && highlight.getLanguage(lang)) { + // try { + // return '<pre class="hljs"><code>' + highlight.highlight(lang, str, true).value + '</code></pre>'; + // } catch (__) { + // } + // } + // return ''; + // }, }; export const md = new Markdown(mdOptions); -- Gitblit v1.9.3