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: fix https://github.com/siyuan-note/siyuan/issues/10054
Vanessaafd1ea9dc275
diff --git a/app/src/protyle/render/av/asset.ts b/app/src/protyle/render/av/asset.tsindex d9a9eddf5a..26cb69c20e 100644--- a/app/src/protyle/render/av/asset.ts+++ b/app/src/protyle/render/av/asset.ts@@ -103,6 +103,7 @@ export const updateAssetCell = (options: {const colId = options.cellElements[0].dataset.colId;const cellDoOperations: IOperation[] = [];const cellUndoOperations: IOperation[] = [];+ let mAssetValue: IAVCellAssetValue[]options.cellElements.forEach((item, elementIndex) => {if (!options.blockElement.contains(item)) {const rowElement = hasClosestByClassName(item, "av__row");@@ -151,6 +152,9 @@ export const updateAssetCell = (options: {} else {cellValue.mAsset = options.replaceValue;}+ mAssetValue = cellValue.mAsset+ } else {+ cellValue.mAsset = mAssetValue}cellDoOperations.push({action: "updateAttrViewCell",diff --git a/app/src/protyle/render/av/select.ts b/app/src/protyle/render/av/select.tsindex fc85288084..e77ea632fd 100644--- a/app/src/protyle/render/av/select.ts+++ b/app/src/protyle/render/av/select.ts@@ -54,6 +54,7 @@ export const removeCellOption = (protyle: IProtyle, data: IAV, cellElements: HTMconst colId = cellElements[0].dataset.colId;const doOperations: IOperation[] = [];const undoOperations: IOperation[] = [];+ let mSelectValue: IAVCellSelectValue[];cellElements.forEach((item, elementIndex) => {if (!blockElement.contains(item)) {item = cellElements[elementIndex] = blockElement.querySelector(`.av__cell[data-id="${item.dataset.id}"]`) as HTMLElement;@@ -62,14 +63,16 @@ export const removeCellOption = (protyle: IProtyle, data: IAV, cellElements: HTMconst cellValue = genCellValueByElement(getTypeByCellElement(item) || item.dataset.type as TAVCol, item);const oldValue = JSON.parse(JSON.stringify(cellValue));if (elementIndex === 0) {- cellValue.mSelect?.find((item: { content: string }, index: number) => {+ cellValue.mSelect?.find((item, index) => {if (item.content === target.dataset.content) {cellValue.mSelect.splice(index, 1);return true;}});+ mSelectValue = cellValue.mSelect;+ } else {+ cellValue.mSelect = mSelectValue;}-doOperations.push({action: "updateAttrViewCell",id: cellValue.id,@@ -455,6 +458,7 @@ export const addColOptionOrCell = (protyle: IProtyle, data: IAV, cellElements: Hconst cellDoOperations: IOperation[] = [];const cellUndoOperations: IOperation[] = [];+ let mSelectValue: IAVCellSelectValue[];cellElements.forEach((item, index) => {const itemRowElement = hasClosestByClassName(item, "av__row");if (!itemRowElement) {@@ -483,6 +487,9 @@ export const addColOptionOrCell = (protyle: IProtyle, data: IAV, cellElements: Hcontent: currentElement.dataset.name}];}+ mSelectValue = cellValue.mSelect;+ } else {+ cellValue.mSelect = mSelectValue;}const rowID = itemRowElement.dataset.id;cellDoOperations.push({