This commit is contained in:
Vanessa 2023-07-05 19:41:29 +08:00
parent 9c01a5754c
commit 64360e4d88

View file

@ -10,7 +10,7 @@ import {getSearch, isMobile} from "../../util/functions";
import {shell} from "electron";
/// #endif
/// #if !MOBILE
import {openAsset, openBy} from "../../editor/util";
import {openAsset, openBy, updateOutline} from "../../editor/util";
import {getAllModels} from "../../layout/getAll";
import {setPanelFocus} from "../../layout/util";
/// #endif
@ -74,6 +74,7 @@ export class Preview {
this.element.addEventListener("click", (event) => {
if (protyle.model) {
setPanelFocus(protyle.model.element.parentElement.parentElement);
updateOutline(getAllModels(), protyle.model.editor.protyle);
}
let target = event.target as HTMLElement;
while (target && !target.isEqualNode(this.element)) {