Skip to content

An open-source, privacy-first, self-hosted knowledge workspace where humans and AI agents work together 开源、隐私优先、自托管的知识工作空间,让人与智能体在此协作

:rotating_light:

Vanessa7b342fc00466
diff --git a/app/src/layout/dock/index.ts b/app/src/layout/dock/index.ts
index 88447508a2..53f8bfc61c 100644
--- a/app/src/layout/dock/index.ts
+++ b/app/src/layout/dock/index.ts
@@ -817,13 +817,13 @@ export class Dock {
activesElement.forEach((item) => {
if (this.position === "Left" || this.position === "Right") {
if (item.getAttribute("data-index") === "1" && activesElement.length > 1) {
- const dockElement = (this.data[item.getAttribute("data-type") as TDock] as Model).parent.parent.element
+ const dockElement = (this.data[item.getAttribute("data-type") as TDock] as Model).parent.parent.element;
item.setAttribute("data-height", dockElement.style.height ? dockElement.clientHeight.toString() : "");
}
item.setAttribute("data-width", this.layout.element.clientWidth.toString());
} else {
if (item.getAttribute("data-index") === "1" && activesElement.length > 1) {
- const dockElement = (this.data[item.getAttribute("data-type") as TDock] as Model).parent.parent.element
+ const dockElement = (this.data[item.getAttribute("data-type") as TDock] as Model).parent.parent.element;
item.setAttribute("data-width", dockElement.style.width ? dockElement.clientWidth.toString() : "");
}
item.setAttribute("data-height", this.layout.element.clientHeight.toString());
diff --git a/app/src/layout/util.ts b/app/src/layout/util.ts
index aeb01ed038..8915953488 100644
--- a/app/src/layout/util.ts
+++ b/app/src/layout/util.ts
@@ -907,45 +907,45 @@ export const addResize = (obj: Layout | Wnd) => {
const previousElement = resizeElement.previousElementSibling as HTMLElement;
const nextElement = resizeElement.nextElementSibling as HTMLElement;
if (previousElement && nextElement) {
- const bigType = ["graph", "inbox", "globalGraph", "backlink"]
- let size = 232
+ const bigType = ["graph", "inbox", "globalGraph", "backlink"];
+ let size = 232;
nextElement.style.transition = "none";
previousElement.style.transition = "none";
if (resizeElement.classList.contains("layout__resize--lr")) {
if (previousElement.classList.contains("layout__dockl")) {
document.querySelectorAll("#dockLeft .dock__item--active").forEach(item => {
if (bigType.includes(item.getAttribute("data-type"))) {
- size = 320
+ size = 320;
}
- })
- previousElement.style.width = size + 'px'
+ });
+ previousElement.style.width = size + "px";
window.siyuan.layout.leftDock.setSize();
} else if (nextElement.classList.contains("layout__dockr")) {
document.querySelectorAll("#dockRight .dock__item--active").forEach(item => {
if (bigType.includes(item.getAttribute("data-type"))) {
- size = 320
+ size = 320;
}
- })
- nextElement.style.width = size + 'px'
+ });
+ nextElement.style.width = size + "px";
window.siyuan.layout.rightDock.setSize();
} else {
- previousElement.style.width = ''
- nextElement.style.width = ''
- previousElement.classList.add("fn__flex-1")
- nextElement.classList.add("fn__flex-1")
+ previousElement.style.width = "";
+ nextElement.style.width = "";
+ previousElement.classList.add("fn__flex-1");
+ nextElement.classList.add("fn__flex-1");
if (resizeElement.parentElement.classList.contains("layout__dockb")) {
window.siyuan.layout.bottomDock.setSize();
}
}
} else {
if (nextElement.classList.contains("layout__dockb")) {
- nextElement.style.height = '232px'
+ nextElement.style.height = "232px";
window.siyuan.layout.bottomDock.setSize();
} else {
- previousElement.style.height = ''
- nextElement.style.height = ''
- previousElement.classList.add("fn__flex-1")
- nextElement.classList.add("fn__flex-1")
+ previousElement.style.height = "";
+ nextElement.style.height = "";
+ previousElement.classList.add("fn__flex-1");
+ nextElement.classList.add("fn__flex-1");
if (resizeElement.parentElement.classList.contains("layout__dockl")) {
window.siyuan.layout.leftDock.setSize();
} else if (resizeElement.parentElement.classList.contains("layout__dockr")) {
diff --git a/app/src/protyle/wysiwyg/keydown.ts b/app/src/protyle/wysiwyg/keydown.ts
index f953c47d08..55a1070c06 100644
--- a/app/src/protyle/wysiwyg/keydown.ts
+++ b/app/src/protyle/wysiwyg/keydown.ts
@@ -1180,7 +1180,7 @@ export const keydown = (protyle: IProtyle, editorElement: HTMLElement) => {
// https://github.com/siyuan-note/siyuan/issues/12989
const cardElement = hasClosestByClassName(range.startContainer, "card__main", true);
if (cardElement && document.activeElement && document.activeElement.classList.contains("protyle-wysiwyg")) {
- (cardElement.querySelector(".card__action:not(.fn__none) button") as HTMLElement).focus()
+ (cardElement.querySelector(".card__action:not(.fn__none) button") as HTMLElement).focus();
hideElements(["select"], protyle);
}
} else {