mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-01-25 17:56:09 +01:00
This commit is contained in:
parent
459b700e26
commit
c33e9429cd
8 changed files with 38 additions and 25 deletions
|
|
@ -24,18 +24,30 @@ export const processMessage = (response: IWebSocketData) => {
|
|||
if ("reloadui" === response.cmd) {
|
||||
if (response.data?.resetScroll) {
|
||||
window.siyuan.storage[Constants.LOCAL_FILEPOSITION] = {};
|
||||
setStorageVal(Constants.LOCAL_FILEPOSITION, window.siyuan.storage[Constants.LOCAL_FILEPOSITION]);
|
||||
}
|
||||
/// #if MOBILE
|
||||
window.location.reload();
|
||||
/// #else
|
||||
exportLayout({
|
||||
cb() {
|
||||
setStorageVal(Constants.LOCAL_FILEPOSITION, window.siyuan.storage[Constants.LOCAL_FILEPOSITION], () => {
|
||||
/// #if MOBILE
|
||||
window.location.reload();
|
||||
},
|
||||
errorExit: false,
|
||||
});
|
||||
/// #endif
|
||||
/// #else
|
||||
exportLayout({
|
||||
cb() {
|
||||
window.location.reload();
|
||||
},
|
||||
errorExit: false,
|
||||
});
|
||||
/// #endif
|
||||
});
|
||||
} else {
|
||||
/// #if MOBILE
|
||||
window.location.reload();
|
||||
/// #else
|
||||
exportLayout({
|
||||
cb() {
|
||||
window.location.reload();
|
||||
},
|
||||
errorExit: false,
|
||||
});
|
||||
/// #endif
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue