Vanessa 2025-07-27 11:38:58 +08:00
parent 7308536ded
commit ccbcb4b809
2 changed files with 3 additions and 3 deletions

View file

@ -295,8 +295,8 @@ export const avClick = (protyle: IProtyle, event: MouseEvent & { target: HTMLEle
event.stopPropagation(); event.stopPropagation();
return true; return true;
} else if (type === "av-group-fold") { } else if (type === "av-group-fold") {
if (target.getAttribute("disabled") !== "true") { if (target.getAttribute("data-folding") !== "true") {
target.setAttribute("disabled", "true"); target.setAttribute("data-folding", "true");
const isOpen = target.firstElementChild.classList.contains("av__group-arrow--open"); const isOpen = target.firstElementChild.classList.contains("av__group-arrow--open");
transaction(protyle, [{ transaction(protyle, [{
action: "foldAttrViewGroup", action: "foldAttrViewGroup",

View file

@ -615,7 +615,7 @@ export const refreshAV = (protyle: IProtyle, operation: IOperation) => {
foldElement.firstElementChild.classList.add("av__group-arrow--open"); foldElement.firstElementChild.classList.add("av__group-arrow--open");
foldElement.parentElement.nextElementSibling.classList.remove("fn__none"); foldElement.parentElement.nextElementSibling.classList.remove("fn__none");
} }
foldElement.removeAttribute("disabled"); foldElement.removeAttribute("data-folding");
}); });
return; return;
} }