Löschen/Deaktivierung

This commit is contained in:
2026-02-01 02:28:56 +01:00
parent f5d2194839
commit 2e53e7e238
3 changed files with 9 additions and 5 deletions

View File

@@ -180,13 +180,17 @@ export function initEditor() {
if (selectionJustChanged && keys.length === 0) return;
markDirty();
};
editor.on('update', onUpdate);
editor.on('component:update', onComponentUpdate);
editor.on('component:add', onUpdate);
editor.on('component:remove', onUpdate);
editor.on('style:property:update', onUpdate);
editor.on('component:selected', onSelect);
return () => {
try {
editor.off('update', onUpdate);
editor.off('component:update', onComponentUpdate);
editor.off('component:add', onUpdate);
editor.off('component:remove', onUpdate);
editor.off('style:property:update', onUpdate);
editor.off('component:selected', onSelect);
} catch {}
};