From 9babbe7f9ccb5afc9212f2ee19d3e7cdd0f498fb Mon Sep 17 00:00:00 2001 From: "lihao.ylh" Date: Fri, 30 Jul 2021 11:17:17 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E5=A4=84=E7=90=86=E5=A4=8D=E6=9D=82=20p?= =?UTF-8?q?rop=20=E5=AF=B9=E8=B1=A1=E5=9C=A8=20dispose=20=E6=97=B6?= =?UTF-8?q?=E6=B2=A1=E6=9C=89=E6=B8=85=E9=99=A4=E5=AD=90=E5=AF=B9=E8=B1=A1?= =?UTF-8?q?=E4=B8=AD=E7=9A=84=20slot=20=E5=AE=9E=E4=BE=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/designer/src/document/node/props/prop.ts | 2 +- packages/types/src/schema.ts | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/designer/src/document/node/props/prop.ts b/packages/designer/src/document/node/props/prop.ts index e903f70ef..448f72f9c 100644 --- a/packages/designer/src/document/node/props/prop.ts +++ b/packages/designer/src/document/node/props/prop.ts @@ -590,7 +590,7 @@ export class Prop implements IPropParent { } this._maps = null; if (this._slotNode && this._slotNode.slotFor === this) { - this._slotNode.purge(); + this._slotNode.remove(); } } diff --git a/packages/types/src/schema.ts b/packages/types/src/schema.ts index 85f8521bd..8ca0f2b5f 100644 --- a/packages/types/src/schema.ts +++ b/packages/types/src/schema.ts @@ -95,6 +95,7 @@ export type RootSchema = PageSchema | ComponentSchema | BlockSchema; export interface SlotSchema extends NodeSchema { componentName: 'Slot'; + name?: string; params?: string[]; }