mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-22 09:30:14 +01:00
This commit is contained in:
parent
a6728a5db5
commit
f132067952
3 changed files with 24 additions and 23 deletions
|
|
@ -44,7 +44,7 @@ export const openMenuPanel = (protyle: IProtyle,
|
|||
if (options && options.cellElement) {
|
||||
const cellRect = options.cellElement.getBoundingClientRect();
|
||||
setPosition(menuElement, cellRect.left, cellRect.bottom, cellRect.height);
|
||||
bindSelectEvent(protyle, data.view, menuElement, options);
|
||||
bindSelectEvent(protyle, data, menuElement, options);
|
||||
menuElement.querySelector("input").select();
|
||||
menuElement.querySelector("input").focus();
|
||||
} else {
|
||||
|
|
@ -110,7 +110,7 @@ export const openMenuPanel = (protyle: IProtyle,
|
|||
data: oldData,
|
||||
}]);
|
||||
menuElement.innerHTML = getSelectHTML(data.view, options);
|
||||
bindSelectEvent(protyle, data.view, menuElement, options);
|
||||
bindSelectEvent(protyle, data, menuElement, options);
|
||||
return;
|
||||
}
|
||||
const sourceId = sourceElement.dataset.id;
|
||||
|
|
@ -475,11 +475,11 @@ export const openMenuPanel = (protyle: IProtyle,
|
|||
event.stopPropagation();
|
||||
break;
|
||||
} else if (type === "setSelectCol") {
|
||||
setSelectCol(protyle, data.view, options, target);
|
||||
setSelectCol(protyle, data, options, target);
|
||||
event.stopPropagation();
|
||||
break;
|
||||
} else if (type === "addSelectColAndCell") {
|
||||
addSelectColAndCell(protyle, data.view, options, target, menuElement);
|
||||
addSelectColAndCell(protyle, data, options, target, menuElement);
|
||||
window.siyuan.menus.menu.remove();
|
||||
event.stopPropagation();
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue