This commit is contained in:
Vanessa 2023-11-17 23:14:16 +08:00
parent 8e93286077
commit af2fd13ae1
3 changed files with 9 additions and 2 deletions

View file

@ -98,7 +98,7 @@ class App {
fetchPost("/api/system/getEmojiConf", {}, emojiResponse => {
window.siyuan.emojis = emojiResponse.data as IEmoji[];
setNoteBook(() => {
initFramework(this);
initFramework(this, confResponse.data.start);
initRightMenu(this);
openChangelog();
const unPinsMenu: IMenu[] = [];

View file

@ -20,7 +20,7 @@ import {syncGuide} from "../../sync/syncGuide";
import {Inbox} from "../../layout/dock/Inbox";
import {App} from "../../index";
export const initFramework = (app: App) => {
export const initFramework = (app: App, isStart:boolean) => {
setInlineStyle();
renderSnippet();
initKeyboardToolbar();
@ -122,6 +122,10 @@ export const initFramework = (app: App) => {
idZoomIn.isZoomIn ? [Constants.CB_GET_ALL, Constants.CB_GET_FOCUS] : [Constants.CB_GET_FOCUS, Constants.CB_GET_CONTEXT, Constants.CB_GET_ROOTSCROLL]);
return;
}
if (window.siyuan.config.fileTree.closeTabsOnStart && isStart) {
setEmpty(app);
return;
}
const localDoc = window.siyuan.storage[Constants.LOCAL_DOCINFO];
fetchPost("/api/block/checkBlockExist", {id: localDoc.id}, existResponse => {
if (existResponse.data) {

View file

@ -288,6 +288,9 @@ export class Background {
id: protyle.block.rootID,
attrs: {"title-img": this.ial["title-img"]}
});
/// #if MOBILE
window.siyuan.menus.menu.remove();
/// #endif
}, Constants.SIYUAN_ASSETS_IMAGE);
event.preventDefault();
event.stopPropagation();