Skip to content

Commit 3d41fd5

Browse files
wangshihao111LeoYuan
authored andcommitted
fix: 新元素无法在大纲树拖拽
1 parent f400172 commit 3d41fd5

File tree

1 file changed

+2
-1
lines changed
  • packages/plugin-outline-pane/src

1 file changed

+2
-1
lines changed

packages/plugin-outline-pane/src/main.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,8 @@ export class OutlineMain implements ISensor, ITreeBoard, IScrollable {
152152
return canMove;
153153
});
154154

155-
if (!operationalNodes || operationalNodes.length === 0) {
155+
// 如果拖拽的是 Node 才需要后面的判断,拖拽 data 不需要
156+
if (isDragNodeObject(dragObject) && (!operationalNodes || operationalNodes.length === 0)) {
156157
return;
157158
}
158159

0 commit comments

Comments
 (0)