An open-source, privacy-first, self-hosted knowledge workspace where humans and AI agents work together 开源、隐私优先、自托管的知识工作空间,让人与智能体在此协作
TypeScript agentic-aiai-agentknowledge-baselocal-firstmarkdownmcpmindmapnote-takingself-hostedsiyuanworkspace
:bug: 重启后窗口大小恢复默认问题 Fix https://github.com/siyuan-note/siyuan/issues/7755
Liang Ding555a9ba2ca8f
diff --git a/app/electron/main.js b/app/electron/main.jsindex 32eabf2a84..f014d01e87 100644--- a/app/electron/main.js+++ b/app/electron/main.js@@ -206,11 +206,13 @@ const boot = () => {height: defaultHeight,}, oldWindowState);+ // writeLog("windowStat [width=" + windowState.width + ", height=" + windowState.height + "], default [width=" + defaultWidth + ", height=" + defaultHeight + "], workArea [width=" + workArea.width + ", height=" + workArea.height + "]");+let x = windowState.x;let y = windowState.y;if (workArea) {- // 窗口大小等同于或大于 workArea 时,缩小会隐藏到左下角- if (windowState.width >= workArea.width || windowState.height >= workArea.height) {+ // 窗口大于 workArea 时缩小会隐藏到左下角,这里使用最小值重置+ if (windowState.width > workArea.width || windowState.height > workArea.height) { // 重启后窗口大小恢复默认问题 https://github.com/siyuan-note/siyuan/issues/7755windowState.width = Math.min(defaultWidth, workArea.width);windowState.height = Math.min(defaultHeight, workArea.height);}