From 04be125365bfd254166072f75da87e406f633ba3 Mon Sep 17 00:00:00 2001
From: cloudroam <cloudroam>
Date: 星期四, 09 一月 2025 18:36:56 +0800
Subject: [PATCH] Merge branch 'master' of http://47.96.225.205:8888/r/operation_pc-v2
---
components/base-editor.vue | 11 ++++++++++-
1 files changed, 10 insertions(+), 1 deletions(-)
diff --git a/components/base-editor.vue b/components/base-editor.vue
index eea3740..56ca01f 100644
--- a/components/base-editor.vue
+++ b/components/base-editor.vue
@@ -37,6 +37,7 @@
import 'tinymce/plugins/anchor'
import 'tinymce/plugins/codesample'
import 'tinymce/plugins/fullscreen'
+import 'tinymce/plugins/paste'
export default {
components: {
Editor,
@@ -53,7 +54,7 @@
plugins: {
type: [String, Array],
default:
- 'importcss autoresize searchreplace autolink code visualblocks visualchars fullscreen image link codesample table charmap nonbreaking anchor advlist lists wordcount charmap emoticons indent2em',
+ 'importcss autoresize searchreplace autolink code visualblocks visualchars fullscreen image link codesample table charmap nonbreaking anchor advlist lists wordcount charmap emoticons indent2em paste',
},
toolbar: {
type: [String, Array],
@@ -86,6 +87,14 @@
branding: false,
promotion: false,
convert_urls: false,
+ paste_preprocess: (plugin, args) => {
+ if (args.wordContent) {
+ this.$message.warning(
+ '检测到可能是从word中复制的内容,如果存在图片请通过编辑器的图片上传功能上传'
+ )
+ }
+ },
+ paste_data_images: true,
font_formats:
'Arial=arial,helvetica,sans-serif; 宋体=SimSun; 微软雅黑=Microsoft Yahei; Impact=impact,chicago;',
fontsize_formats:
--
Gitblit v1.9.3