Skip to content

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

:art: https://github.com/siyuan-note/siyuan/issues/17830

Vanessa4aab74cba5d5
diff --git a/app/appearance/themes/daylight/theme.css b/app/appearance/themes/daylight/theme.css
index 5842ad6a3f..8cef0d4aea 100644
--- a/app/appearance/themes/daylight/theme.css
+++ b/app/appearance/themes/daylight/theme.css
@@ -58,7 +58,7 @@
--b3-list-icon-hover: rgba(33, 34, 36, .1);
/* 菜单 */
- --b3-menu-background: var(--b3-theme-surface);
+ --b3-menu-background: #f9f9fa;
/* 提示 */
--b3-tooltips-background: #312f35;
diff --git a/app/src/protyle/render/av/gallery/render.ts b/app/src/protyle/render/av/gallery/render.ts
index a8ecaa6a1b..93b0eae3bf 100644
--- a/app/src/protyle/render/av/gallery/render.ts
+++ b/app/src/protyle/render/av/gallery/render.ts
@@ -48,7 +48,9 @@ const getGalleryHTML = (data: IAVGallery, e: HTMLElement, virtualData: IAVVirtua
// body
data.cards.forEach((item: IAVGalleryItem, rowIndex: number) => {
if (virtualData && virtualData.renderedEnd) {
- e.setAttribute(Constants.ATTRIBUTE_V_SCROLL, "true");
+ if (rowIndex === 0) {
+ e.setAttribute(Constants.ATTRIBUTE_V_SCROLL, "true");
+ }
if (rowIndex > virtualData.renderedEnd || rowIndex < virtualData.renderedStart) {
return;
}
diff --git a/app/src/protyle/render/av/kanban/render.ts b/app/src/protyle/render/av/kanban/render.ts
index 35e1988e8e..b315319dc3 100644
--- a/app/src/protyle/render/av/kanban/render.ts
+++ b/app/src/protyle/render/av/kanban/render.ts
@@ -37,7 +37,9 @@ const getKanbanHTML = (data: IAVKanban, e: HTMLElement, virtualData: IAVVirtualD
// body
data.cards.forEach((item: IAVGalleryItem, rowIndex: number) => {
if (virtualData && virtualData.renderedEnd) {
- e.setAttribute(Constants.ATTRIBUTE_V_SCROLL, "true");
+ if (rowIndex === 0) {
+ e.setAttribute(Constants.ATTRIBUTE_V_SCROLL, "true");
+ }
if (rowIndex > virtualData.renderedEnd || rowIndex < virtualData.renderedStart) {
return;
}
diff --git a/app/src/protyle/render/av/render.ts b/app/src/protyle/render/av/render.ts
index d0ebb17539..0cd304b0fd 100644
--- a/app/src/protyle/render/av/render.ts
+++ b/app/src/protyle/render/av/render.ts
@@ -194,7 +194,9 @@ style="width: ${column.width || "200px"}">${getCalcValue(column) || `<svg><use x
// body
data.rows.find((row: IAVRow, rowIndex: number) => {
if (virtualData && virtualData.renderedEnd) {
- e.setAttribute(Constants.ATTRIBUTE_V_SCROLL, "true");
+ if (rowIndex === 0) {
+ e.setAttribute(Constants.ATTRIBUTE_V_SCROLL, "true");
+ }
if (rowIndex > virtualData.renderedEnd || rowIndex < virtualData.renderedStart) {
return;
}
diff --git a/app/src/protyle/render/av/virtualScroll.ts b/app/src/protyle/render/av/virtualScroll.ts
index 14b1742748..3921e65dac 100644
--- a/app/src/protyle/render/av/virtualScroll.ts
+++ b/app/src/protyle/render/av/virtualScroll.ts
@@ -213,6 +213,9 @@ export const initVirtualScroll = (options: {
blockElement: HTMLElement,
data: IAV,
}): void => {
+ if (options.blockElement.getAttribute(Constants.ATTRIBUTE_V_SCROLL) !== "true") {
+ return;
+ }
dataStore.set(options.blockElement.getAttribute("data-av-id") +
options.blockElement.getAttribute(Constants.CUSTOM_SY_AV_VIEW), {
protyle: options.protyle,