mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-22 01:20:12 +01:00
This commit is contained in:
parent
4ecb555c1f
commit
aa56c16830
5 changed files with 20 additions and 7 deletions
|
|
@ -26,6 +26,7 @@ import {initBar} from "../layout/topBar";
|
|||
import {setProxy} from "../config/util/setProxy";
|
||||
import {openChangelog} from "./openChangelog";
|
||||
import {getIdFromSYProtocol, isSYProtocol} from "../util/pathName";
|
||||
import {App} from "../index";
|
||||
|
||||
const matchKeymap = (keymap: Record<string, IKeymapItem>, key1: "general" | "editor", key2?: "general" | "insert" | "heading" | "list" | "table") => {
|
||||
if (key1 === "general") {
|
||||
|
|
@ -84,7 +85,7 @@ const hasKeymap = (keymap: Record<string, IKeymapItem>, key1: "general" | "edito
|
|||
return match;
|
||||
};
|
||||
|
||||
export const onGetConfig = (isStart: boolean) => {
|
||||
export const onGetConfig = (isStart: boolean, app:App) => {
|
||||
const matchKeymap1 = matchKeymap(Constants.SIYUAN_KEYMAP.general, "general");
|
||||
const matchKeymap2 = matchKeymap(Constants.SIYUAN_KEYMAP.editor.general, "editor", "general");
|
||||
const matchKeymap3 = matchKeymap(Constants.SIYUAN_KEYMAP.editor.insert, "editor", "insert");
|
||||
|
|
@ -140,7 +141,7 @@ export const onGetConfig = (isStart: boolean) => {
|
|||
resetLayout();
|
||||
}
|
||||
});
|
||||
initBar();
|
||||
initBar(app);
|
||||
setProxy();
|
||||
initStatus();
|
||||
initWindow();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue