An open-source, privacy-first, self-hosted knowledge workspace where humans and AI agents work together 开源、隐私优先、自托管的知识工作空间,让人与智能体在此协作
TypeScript agentic-aiai-agentknowledge-baselocal-firstmarkdownmcpmindmapnote-takingself-hostedsiyuanworkspace
:lipstick: https://github.com/siyuan-note/siyuan/issues/12911
Vanessa63badb1c7467
diff --git a/app/src/assets/scss/mobile.scss b/app/src/assets/scss/mobile.scssindex efd8bbad3f..fd7a6f35cf 100644--- a/app/src/assets/scss/mobile.scss+++ b/app/src/assets/scss/mobile.scss@@ -481,6 +481,10 @@&-background__img img {height: 200px;}++ &-scroll {+ right: 0;+ }}.av__views .block__icon {diff --git a/app/src/assets/scss/protyle/_protyle.scss b/app/src/assets/scss/protyle/_protyle.scssindex 9bb0a2db94..6208b1de14 100644--- a/app/src/assets/scss/protyle/_protyle.scss+++ b/app/src/assets/scss/protyle/_protyle.scss@@ -6,7 +6,7 @@.protyle-scroll {--b3-dynamicscroll-width: 200px;position: absolute;- right: 0;+ right: 10px;top: 30px;width: 16px;bottom: 9px; // 下图标 hover 时,需要留出一定的空间diff --git a/app/src/block/Panel.ts b/app/src/block/Panel.tsindex e3a3268fe3..058eccada4 100644--- a/app/src/block/Panel.ts+++ b/app/src/block/Panel.ts@@ -195,7 +195,7 @@ export class BlockPanel {}// 由于 afterCB 中高度的设定,需在之后再进行设定// 49 = 16(上图标)+16(下图标)+8(padding)+9(底部距离)- editor.protyle.scroll.element.parentElement.setAttribute("style", `--b3-dynamicscroll-width:${Math.min(editor.protyle.contentElement.clientHeight - 49, 200)}px;${isMobile() ? "" : "right:10px"}`);+ editor.protyle.scroll.element.parentElement.setAttribute("style", `--b3-dynamicscroll-width:${Math.min(editor.protyle.contentElement.clientHeight - 49, 200)}px;`);}});this.editors.push(editor);diff --git a/app/src/protyle/scroll/index.ts b/app/src/protyle/scroll/index.tsindex 646949bdb3..520c8b899b 100644--- a/app/src/protyle/scroll/index.ts+++ b/app/src/protyle/scroll/index.ts@@ -17,9 +17,6 @@ export class Scroll {constructor(protyle: IProtyle) {this.parentElement = document.createElement("div");this.parentElement.classList.add("protyle-scroll");- if (!isMobile()) {- this.parentElement.style.right = "10px";- }this.parentElement.innerHTML = `<div class="protyle-scroll__up ariaLabel" data-position="right4top" aria-label="${updateHotkeyTip("⌘Home")}"><svg><use xlink:href="#iconUp"></use></svg></div>diff --git a/app/src/protyle/util/resize.ts b/app/src/protyle/util/resize.tsindex e30f24a701..1cb09df2cb 100644--- a/app/src/protyle/util/resize.ts+++ b/app/src/protyle/util/resize.ts@@ -11,6 +11,9 @@ export const resize = (protyle: IProtyle) => {const MIN_ABS = 4;// 不能 clearTimeout,否则 split 时左侧无法 resizesetTimeout(() => {+ if (protyle.scroll && protyle.scroll.element.parentElement.getAttribute("style")) {+ protyle.scroll.element.parentElement.setAttribute("style", `--b3-dynamicscroll-width:${Math.min(protyle.contentElement.clientHeight - 49, 200)}px`);+ }if (!protyle.disabled) {const contentRect = protyle.contentElement.getBoundingClientRect();protyle.wysiwyg.element.querySelectorAll(".av").forEach((item: HTMLElement) => {diff --git a/app/src/protyle/wysiwyg/index.ts b/app/src/protyle/wysiwyg/index.tsindex 68a9f2b7f9..134713e6ff 100644--- a/app/src/protyle/wysiwyg/index.ts+++ b/app/src/protyle/wysiwyg/index.ts@@ -519,7 +519,7 @@ export class WYSIWYG {}nodeElement.querySelectorAll(".av__row").forEach((rowElement: HTMLElement, index: number) => {if ((newIndex.rowIndex < firstCellIndex.rowIndex && index >= newIndex.rowIndex && index < firstCellIndex.rowIndex) ||- (newIndex.rowIndex > dragFillCellIndex.rowIndex && index <= newIndex.rowIndex&& index > dragFillCellIndex.rowIndex)) {+ (newIndex.rowIndex > dragFillCellIndex.rowIndex && index <= newIndex.rowIndex && index > dragFillCellIndex.rowIndex)) {rowElement.querySelectorAll(".av__cell").forEach((cellElement: HTMLElement, cellIndex: number) => {if (cellIndex >= firstCellIndex.celIndex && cellIndex <= newIndex.celIndex) {cellElement.classList.add("av__cell--active");