Skip to content

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

:art: Show database column width on pointer down https://github.com/siyuan-note/siyuan/issues/12952

Danielbef7a35121da
diff --git a/app/src/protyle/wysiwyg/index.ts b/app/src/protyle/wysiwyg/index.ts
index d09ded6c6c..41ceb81fa8 100644
--- a/app/src/protyle/wysiwyg/index.ts
+++ b/app/src/protyle/wysiwyg/index.ts
@@ -1412,8 +1412,8 @@ export class WYSIWYG {
const headerRect = headerElement.getBoundingClientRect();
const headerTop = headerRect.top;
const guideHeight = Math.round(headerRect.height);
- let newWidth: number;
- let resizeSnapped: boolean;
+ let newWidth = oldWidth;
+ let resizeSnapped = false;
let resizeGuide: HTMLElement;
let resizeTip: HTMLElement;
let pendingResize: { width: number, snapped: boolean } | undefined;
@@ -1447,6 +1447,7 @@ export class WYSIWYG {
resizeTip.textContent = `${newWidth}px${snapped ?
window.siyuan.languages.sameWidthAsLeftColumnTip : ""}`;
};
+ updateResizePreview(resizeSnapped);
const flushResize = () => {
if (!pendingResize) {
return;