From 4030ae31a6296172a84d135d305e087520449fb8 Mon Sep 17 00:00:00 2001 From: Vanessa Date: Thu, 21 Sep 2023 11:15:49 +0800 Subject: [PATCH] :art: fix https://github.com/siyuan-note/siyuan/issues/9244 --- app/src/layout/topBar.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/app/src/layout/topBar.ts b/app/src/layout/topBar.ts index 3e279e2f6..626eef370 100644 --- a/app/src/layout/topBar.ts +++ b/app/src/layout/topBar.ts @@ -19,6 +19,7 @@ import {fetchPost} from "../util/fetch"; import {needSubscribe} from "../util/needSubscribe"; import * as dayjs from "dayjs"; import {commandPanel} from "../plugin/commandPanel"; +import {exportLayout} from "./util"; export const initBar = (app: App) => { const toolbarElement = document.getElementById("toolbar"); @@ -115,7 +116,12 @@ export const initBar = (app: App) => { event.stopPropagation(); break; } else if (targetId === "barExit") { - exitSiYuan(); + exportLayout({ + reload: false, + onlyData: false, + errorExit: true, + cb: exitSiYuan + }); event.stopPropagation(); break; } else if (targetId === "barMode") {