mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-07-03 14:09:06 +02:00
This commit is contained in:
@@ -517,6 +517,9 @@ export const popTextCell = (protyle: IProtyle, cellElements: HTMLElement[], type
|
||||
html = `<input type="number" spellcheck="false" value="${cellElements[0].firstElementChild.getAttribute("data-content")}" ${style} class="b3-text-field">`;
|
||||
} else {
|
||||
if (["select", "mSelect"].includes(type)) {
|
||||
if (blockElement.getAttribute("data-rendering") === "true") {
|
||||
return;
|
||||
}
|
||||
openMenuPanel({protyle, blockElement, type: "select", cellElements});
|
||||
} else if (type === "mAsset") {
|
||||
openMenuPanel({protyle, blockElement, type: "asset", cellElements});
|
||||
|
||||
@@ -451,6 +451,7 @@ export const avRender = (element: Element, protyle: IProtyle, cb?: (data: IAV) =
|
||||
}
|
||||
if (avElements.length > 0) {
|
||||
avElements.forEach((e: HTMLElement) => {
|
||||
e.removeAttribute("data-rendering");
|
||||
if (e.getAttribute("data-render") === "true" || hasClosestByClassName(e, "av__gallery-content")) {
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -633,6 +633,7 @@ export const addColOptionOrCell = (protyle: IProtyle, data: IAV, cellElements: H
|
||||
transaction(protyle, cellDoOperations, cellUndoOperations);
|
||||
}
|
||||
if (colData.type === "select") {
|
||||
blockElement.setAttribute("data-rendering", "true");
|
||||
menuElement.parentElement.dispatchEvent(new CustomEvent("click", {detail: "close"}));
|
||||
} else {
|
||||
const oldScroll = menuElement.querySelector(".b3-menu__items").scrollTop;
|
||||
|
||||
Reference in New Issue
Block a user