From 41cdc6e650080ff44fdc53510775718fc1e1296f Mon Sep 17 00:00:00 2001 From: roymondchen Date: Thu, 11 Aug 2022 14:38:21 +0800 Subject: [PATCH] =?UTF-8?q?test(editor):=20=E6=9B=B4=E6=96=B0propsService?= =?UTF-8?q?=E5=BC=95=E7=94=A8=E8=B7=AF=E5=BE=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/editor/src/services/editor.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/editor/src/services/editor.ts b/packages/editor/src/services/editor.ts index c3bcd845..4ac8d8b7 100644 --- a/packages/editor/src/services/editor.ts +++ b/packages/editor/src/services/editor.ts @@ -39,9 +39,9 @@ import { setLayout, } from '../utils/editor'; import { beforePaste, beforeRemove, getAddParent } from '../utils/operator'; -import { propsService } from '..'; import BaseService from './BaseService'; +import propsService from './props'; class Editor extends BaseService { public state: StoreState = reactive({ @@ -508,10 +508,10 @@ class Editor extends BaseService { * @param position 粘贴的坐标 * @returns 添加后的组件节点配置 */ - public async paste(position: PastePosition = {}): Promise { + public async paste(position: PastePosition = {}): Promise { const config: MNode[] = await storageService.getItem(COPY_STORAGE_KEY); - if (!Array.isArray(config)) return []; + if (!Array.isArray(config)) return; const pasteConfigs = await beforePaste(position, config);