From c2499ec0da77f7aee8ad114b9eda8e053ce6774b Mon Sep 17 00:00:00 2001 From: wangjiahao <1522128093@qq.com> Date: Fri, 21 Jun 2024 09:59:39 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E4=BB=AA=E8=A1=A8=E6=9D=BF=E3=80=81?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E5=A4=A7=E5=B1=8F):=20=E4=BF=AE=E5=A4=8D?= =?UTF-8?q?=E5=AF=8C=E6=96=87=E6=9C=AC=E9=80=80=E5=87=BA=E7=BC=96=E8=BE=91?= =?UTF-8?q?=E8=B5=8B=E5=80=BC=E5=8F=8D=E9=A6=88=E4=B8=8D=E5=8F=8A=E6=97=B6?= =?UTF-8?q?=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/custom-component/rich-text/DeRichEditor.vue | 4 +++- .../src/custom-component/rich-text/DeRichTextView.vue | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/core/core-frontend/src/custom-component/rich-text/DeRichEditor.vue b/core/core-frontend/src/custom-component/rich-text/DeRichEditor.vue index 4a691ab51a..62d56883f7 100644 --- a/core/core-frontend/src/custom-component/rich-text/DeRichEditor.vue +++ b/core/core-frontend/src/custom-component/rich-text/DeRichEditor.vue @@ -19,6 +19,8 @@ import 'tinymce/plugins/table' // 插入表格插件 import 'tinymce/plugins/lists' // 列表插件 import 'tinymce/plugins/wordcount' // 字数统计插件 import 'tinymce/plugins/code' // 源码 +import './plugins' //自定义插件 +import '@npkg/tinymce-plugins/letterspacing' //接下来定义编辑器所需要的插件数据 import { reactive, ref } from 'vue' @@ -49,7 +51,7 @@ const props = defineProps({ toolbar: { type: [String, Array], default: - 'codesample bold italic underline alignleft aligncenter alignright alignjustify | undo redo | formatselect | fontselect | fontsizeselect | forecolor backcolor | bullist numlist outdent indent | lists link table code | removeformat ' + 'codesample bold italic underline alignleft aligncenter alignright alignjustify | undo redo | formatselect | fontselect | fontsizeselect | forecolor backcolor | bullist numlist outdent indent | lists link table code | removeformat letterspacing ' } //必填 }) //用于接收外部传递进来的富文本 diff --git a/core/core-frontend/src/custom-component/rich-text/DeRichTextView.vue b/core/core-frontend/src/custom-component/rich-text/DeRichTextView.vue index 67d82c5e40..c1ccdf7c0e 100644 --- a/core/core-frontend/src/custom-component/rich-text/DeRichTextView.vue +++ b/core/core-frontend/src/custom-component/rich-text/DeRichTextView.vue @@ -161,6 +161,7 @@ watch( canEdit.value = false reShow() myValue.value = assignment(element.value.propValue.textValue) + ed.setContent(myValue.value) } } )