mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-22 01:20:12 +01:00
This commit is contained in:
parent
31e1798ff2
commit
01205215eb
3 changed files with 14 additions and 0 deletions
|
|
@ -66,6 +66,9 @@ export class App {
|
||||||
window.siyuan.config.editor.readOnly = data.data;
|
window.siyuan.config.editor.readOnly = data.data;
|
||||||
hideAllElements(["util"]);
|
hideAllElements(["util"]);
|
||||||
break;
|
break;
|
||||||
|
case "setConf":
|
||||||
|
window.siyuan.config = data.data;
|
||||||
|
break;
|
||||||
case "progress":
|
case "progress":
|
||||||
progressLoading(data);
|
progressLoading(data);
|
||||||
break;
|
break;
|
||||||
|
|
|
||||||
|
|
@ -9,6 +9,9 @@ export const onMessage = (app: App, data: IWebSocketData) => {
|
||||||
case "syncMergeResult":
|
case "syncMergeResult":
|
||||||
reloadSync(app, data.data);
|
reloadSync(app, data.data);
|
||||||
break;
|
break;
|
||||||
|
case "setConf":
|
||||||
|
window.siyuan.config = data.data;
|
||||||
|
break;
|
||||||
case "readonly":
|
case "readonly":
|
||||||
window.siyuan.config.editor.readOnly = data.data;
|
window.siyuan.config.editor.readOnly = data.data;
|
||||||
break;
|
break;
|
||||||
|
|
|
||||||
|
|
@ -20,6 +20,7 @@ import {getAllTabs} from "../layout/getAll";
|
||||||
import {getLocalStorage} from "../protyle/util/compatibility";
|
import {getLocalStorage} from "../protyle/util/compatibility";
|
||||||
import {init} from "../window/init";
|
import {init} from "../window/init";
|
||||||
import {loadPlugins} from "../plugin/loader";
|
import {loadPlugins} from "../plugin/loader";
|
||||||
|
import {hideAllElements} from "../protyle/ui/hideElements";
|
||||||
|
|
||||||
class App {
|
class App {
|
||||||
public plugins: import("../plugin").Plugin[] = [];
|
public plugins: import("../plugin").Plugin[] = [];
|
||||||
|
|
@ -53,6 +54,13 @@ class App {
|
||||||
case "syncMergeResult":
|
case "syncMergeResult":
|
||||||
reloadSync(this, data.data);
|
reloadSync(this, data.data);
|
||||||
break;
|
break;
|
||||||
|
case "readonly":
|
||||||
|
window.siyuan.config.editor.readOnly = data.data;
|
||||||
|
hideAllElements(["util"]);
|
||||||
|
break;
|
||||||
|
case "setConf":
|
||||||
|
window.siyuan.config = data.data;
|
||||||
|
break;
|
||||||
case "progress":
|
case "progress":
|
||||||
progressLoading(data);
|
progressLoading(data);
|
||||||
break;
|
break;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue