From 611b42416906c69a27c07123c92831bae4c9a97e Mon Sep 17 00:00:00 2001 From: XingZhe Date: Tue, 24 Sep 2024 08:27:06 +0000 Subject: [PATCH] =?UTF-8?q?fix(toolbar):=20=E4=BF=AE=E5=A4=8D=E6=96=87?= =?UTF-8?q?=E6=9C=AC=E6=A1=86=E6=97=A0=E6=B3=95=E7=B2=98=E8=B4=B4=E4=BA=8B?= =?UTF-8?q?=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: XingZhe --- src/views/screen-editor/header-toolbar/index.vue | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/views/screen-editor/header-toolbar/index.vue b/src/views/screen-editor/header-toolbar/index.vue index f922252..7d1b400 100644 --- a/src/views/screen-editor/header-toolbar/index.vue +++ b/src/views/screen-editor/header-toolbar/index.vue @@ -369,6 +369,14 @@ export default defineComponent({ } }) window.addEventListener('paste', (event: any) => { + // 检查是否有文本内容 + const textContent = event.clipboardData.getData('text/plain') + if (textContent) { + // 允许文本粘贴 + return + } + + // 处理图片类型 const param = [ { key: 'token', -- Gitee