fix: 对话md渲染优化

This commit is contained in:
Gsh
2025-07-14 22:20:32 +08:00
parent 5162f9ce3b
commit 1ef82e5f93
4 changed files with 134 additions and 17 deletions

View File

@@ -271,10 +271,6 @@ watch(
},
);
function markdownContent(item: any) {
return item.content;
}
// 复制
function copy(item: any) {
console.log('复制', item);
@@ -296,7 +292,7 @@ function copy(item: any) {
</template>
<!-- 自定义气泡内容 -->
<template #content="{ item }">
<XMarkdown class="markdown-body" :markdown="markdownContent(item)" />
<XMarkdown v-if="item.content" class="markdown-body" :markdown="item.content" />
</template>
<!-- 自定义底部 -->