|
@@ -2292,11 +2292,15 @@ export default {
|
|
|
|
|
|
if (matchedContent?.content) {
|
|
|
// 构建替换内容
|
|
|
+ const cleanContent = matchedContent.content.trim() // 清理前后空格
|
|
|
+ const chineseDescription = matchedContent.chinese_description || '' // 获取中文释义,如果有的话 !important
|
|
|
const formattedReplacement = `
|
|
|
- <span class="replacement-content" data-code="${currentCode}">
|
|
|
- ${matchedContent.content}
|
|
|
- </span>
|
|
|
- `.trim()
|
|
|
+ <span
|
|
|
+ class="replacement-content"
|
|
|
+ data-code="${currentCode}"
|
|
|
+ title="${chineseDescription}"
|
|
|
+ style="background-color: #ffff00; padding: 2px 4px; border-radius: 2px; display: inline-block;"
|
|
|
+ >${cleanContent}${chineseDescription ? `<span class="chinese-desc" style="color: #67c23a; margin-left: 4px; font-size: 0.9em;">(${chineseDescription})</span>` : ''}</span>`.trim()
|
|
|
|
|
|
// 处理表格和其他内容
|
|
|
updatedContent = this.processTableContent(
|