mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-03-01 18:30:16 +01:00
This commit is contained in:
parent
7715ee0b4e
commit
1b3ec44e35
2 changed files with 4 additions and 2 deletions
|
|
@ -832,8 +832,6 @@ export const updateTableTitle = (protyle: IProtyle, nodeElement: Element) => {
|
|||
dialog.bindInput(inputElement, () => {
|
||||
(btnsElement[1] as HTMLButtonElement).click();
|
||||
});
|
||||
inputElement.focus();
|
||||
inputElement.value = captionElement?.textContent || "";
|
||||
btnsElement[0].addEventListener("click", () => {
|
||||
dialog.destroy();
|
||||
});
|
||||
|
|
@ -857,4 +855,7 @@ export const updateTableTitle = (protyle: IProtyle, nodeElement: Element) => {
|
|||
updateTransaction(protyle, nodeElement.getAttribute("data-node-id"), nodeElement.outerHTML, html);
|
||||
dialog.destroy();
|
||||
});
|
||||
inputElement.value = captionElement?.textContent || "";
|
||||
inputElement.focus();
|
||||
inputElement.select();
|
||||
};
|
||||
|
|
|
|||
|
|
@ -2666,6 +2666,7 @@ export class WYSIWYG {
|
|||
if (tableElement) {
|
||||
if (hasClosestByTag(event.target, "CAPTION")) {
|
||||
updateTableTitle(protyle, tableElement);
|
||||
return;
|
||||
}
|
||||
}
|
||||
// 面包屑定位,需至于前,否则 return 的元素就无法进行面包屑定位
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue