mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-18 07:30:12 +01:00
This commit is contained in:
parent
6b1a2925c9
commit
9ae8400b47
2 changed files with 2 additions and 2 deletions
|
|
@ -355,7 +355,7 @@ export const updateAVName = (protyle: IProtyle, blockElement: Element) => {
|
|||
id,
|
||||
data: blockElement.getAttribute("updated")
|
||||
}]);
|
||||
nameElement.setAttribute("updated", newUpdated);
|
||||
blockElement.setAttribute("updated", newUpdated);
|
||||
nameElement.dataset.title = newData;
|
||||
blockElement.querySelector(".layout-tab-bar .item__text").textContent = newData;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -252,7 +252,7 @@ export const refreshAV = (protyle: IProtyle, operation: IOperation) => {
|
|||
} else if (operation.action === "setAttrViewName") {
|
||||
Array.from(protyle.wysiwyg.element.querySelectorAll(`[data-av-id="${operation.id}"]`)).forEach((item: HTMLElement) => {
|
||||
const titleElement = item.querySelector(".av__title") as HTMLElement;
|
||||
if (!titleElement || titleElement.textContent.trim() === operation.data) {
|
||||
if (!titleElement) {
|
||||
return;
|
||||
}
|
||||
titleElement.textContent = operation.data;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue