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: 新增行后弹出的输入框
Vanessa3da9f0f1e133
diff --git a/app/src/protyle/render/av/cell.ts b/app/src/protyle/render/av/cell.tsindex dd2665bf19..1fdbf07cf4 100644--- a/app/src/protyle/render/av/cell.ts+++ b/app/src/protyle/render/av/cell.ts@@ -402,10 +402,19 @@ export const popTextCell = (protyle: IProtyle, cellElements: HTMLElement[], type};const updateCellValue = (protyle: IProtyle, type: TAVCol, cellElements: HTMLElement[]) => {- if (!document.contains(cellElements[0]) && cellElements.length === 1 && cellElements[0].dataset.detached === "true") {- // 新增行后弹出的输入框进行修改后,原始 cell 已被更新+ if (!document.contains(cellElements[0]) && cellElements.length === 1) {+ // 原始 cell 已被更新const avid = cellElements[0].parentElement.dataset.avid;- cellElements[0] = protyle.wysiwyg.element.querySelector(`[data-av-id="${avid}"] .av__row--add`).previousElementSibling.querySelector('[data-detached="true"]');+ if (avid) {+ // 新增行后弹出的输入框+ cellElements[0] = protyle.wysiwyg.element.querySelector(`[data-av-id="${avid}"] .av__row--add`).previousElementSibling.querySelector('[data-detached="true"]');+ } else {+ // 修改单元格后立即修改其他单元格+ cellElements[0] = protyle.wysiwyg.element.querySelector(`.av__cell[data-id="${cellElements[0].dataset.id}"]`);+ if (!cellElements[0]) {+ return;+ }+ }}if (cellElements.length === 1 && cellElements[0].dataset.detached === "true" && !cellElements[0].parentElement.dataset.id) {return;