mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-05-02 22:21:28 +08:00
This commit is contained in:
parent
a05faf6fc1
commit
5c739ffa77
@ -71,7 +71,9 @@ export class App {
|
|||||||
setDefRefCount(data.data);
|
setDefRefCount(data.data);
|
||||||
break;
|
break;
|
||||||
case "reloadTag":
|
case "reloadTag":
|
||||||
(getDockByType("tag")?.data.tag as Tag).update();
|
if (getDockByType("tag")?.data.tag instanceof Tag) {
|
||||||
|
(getDockByType("tag").data.tag as Tag).update();
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
/// #if BROWSER
|
/// #if BROWSER
|
||||||
case "setLocalShorthandCount":
|
case "setLocalShorthandCount":
|
||||||
|
@ -580,19 +580,17 @@ export const onTransaction = (protyle: IProtyle, operation: IOperation, isUndo:
|
|||||||
enableProtyle(protyle);
|
enableProtyle(protyle);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (data.new.icon !== data.old.icon) {
|
if (data.new.icon !== data.old.icon ||
|
||||||
|
data.new["title-img"] !== data.old["title-img"] ||
|
||||||
|
data.new.tags !== data.old.tags && protyle.background) {
|
||||||
/// #if MOBILE
|
/// #if MOBILE
|
||||||
if (window.siyuan.mobile.editor.protyle.background.ial.icon !== data.new.icon) {
|
protyle = window.siyuan.mobile.editor.protyle;
|
||||||
window.siyuan.mobile.editor.protyle.background.ial.icon = data.new.icon;
|
|
||||||
window.siyuan.mobile.editor.protyle.background.render(window.siyuan.mobile.editor.protyle.background.ial, window.siyuan.mobile.editor.protyle.block.rootID);
|
|
||||||
}
|
|
||||||
/// #else
|
|
||||||
if (protyle.background && protyle.background.ial.icon !== data.new.icon) {
|
|
||||||
protyle.background.ial.icon = data.new.icon;
|
|
||||||
protyle.background.render(protyle.background.ial, protyle.block.rootID);
|
|
||||||
protyle.model?.parent.setDocIcon(data.new.icon);
|
|
||||||
}
|
|
||||||
/// #endif
|
/// #endif
|
||||||
|
protyle.background.ial.icon = data.new.icon;
|
||||||
|
protyle.background.ial.tags = data.new.tags;
|
||||||
|
protyle.background.ial["title-img"] = data.new["title-img"];
|
||||||
|
protyle.background.render(protyle.background.ial, protyle.block.rootID);
|
||||||
|
protyle.model?.parent.setDocIcon(data.new.icon);
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user