mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-20 08:30:12 +01:00
This commit is contained in:
parent
263dcbe8bc
commit
383fa70bd7
2 changed files with 3 additions and 1 deletions
|
|
@ -416,7 +416,7 @@ const updateCellValueByInput = (protyle: IProtyle, type: TAVCol, blockElement: H
|
||||||
if (type === "template") {
|
if (type === "template") {
|
||||||
const colId = cellElements[0].getAttribute("data-col-id");
|
const colId = cellElements[0].getAttribute("data-col-id");
|
||||||
const textElement = avMaskElement.querySelector(".b3-text-field") as HTMLInputElement;
|
const textElement = avMaskElement.querySelector(".b3-text-field") as HTMLInputElement;
|
||||||
if (textElement.value !== textElement.dataset.template) {
|
if (textElement.value !== textElement.dataset.template && !blockElement.getAttribute("data-loading")) {
|
||||||
transaction(protyle, [{
|
transaction(protyle, [{
|
||||||
action: "updateAttrViewColTemplate",
|
action: "updateAttrViewColTemplate",
|
||||||
id: colId,
|
id: colId,
|
||||||
|
|
@ -430,6 +430,7 @@ const updateCellValueByInput = (protyle: IProtyle, type: TAVCol, blockElement: H
|
||||||
data: textElement.dataset.template,
|
data: textElement.dataset.template,
|
||||||
type: "template",
|
type: "template",
|
||||||
}]);
|
}]);
|
||||||
|
blockElement.setAttribute("data-loading", "true");
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
updateCellsValue(protyle, blockElement, type === "checkbox" ? {
|
updateCellsValue(protyle, blockElement, type === "checkbox" ? {
|
||||||
|
|
|
||||||
|
|
@ -324,6 +324,7 @@ export const refreshAV = (protyle: IProtyle, operation: IOperation) => {
|
||||||
document.querySelector(".av__mask")?.remove();
|
document.querySelector(".av__mask")?.remove();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
item.removeAttribute("data-loading");
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue