mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-02-21 06:24:06 +01:00
This commit is contained in:
parent
d954602379
commit
d9a314d116
1 changed files with 3 additions and 3 deletions
|
|
@ -714,7 +714,7 @@ export const dropEvent = (protyle: IProtyle, editorElement: HTMLElement) => {
|
|||
return;
|
||||
} else if (target.classList.contains("av__cellheader")) {
|
||||
window.siyuan.dragElement = target.parentElement;
|
||||
event.dataTransfer.setData(`${Constants.SIYUAN_DROP_GUTTER}NodeAttributeView${Constants.ZWSP}Col${Constants.ZWSP}${[target.parentElement.getAttribute("data-id")]}`,
|
||||
event.dataTransfer.setData(`${Constants.SIYUAN_DROP_GUTTER}NodeAttributeView${Constants.ZWSP}Col${Constants.ZWSP}${[target.parentElement.getAttribute("data-col-id")]}`,
|
||||
target.innerHTML);
|
||||
return;
|
||||
} else if (target.classList.contains("av__gutters")) {
|
||||
|
|
@ -827,12 +827,12 @@ export const dropEvent = (protyle: IProtyle, editorElement: HTMLElement) => {
|
|||
transaction(protyle, [{
|
||||
action: "sortAttrViewCol",
|
||||
avID,
|
||||
previousID: (targetElement.classList.contains("dragover__left") ? targetElement.previousElementSibling?.getAttribute("data-id") : targetElement.getAttribute("data-id")) || "",
|
||||
previousID: (targetElement.classList.contains("dragover__left") ? targetElement.previousElementSibling?.getAttribute("data-col-id") : targetElement.getAttribute("data-col-id")) || "",
|
||||
id: gutterTypes[2],
|
||||
}], [{
|
||||
action: "sortAttrViewCol",
|
||||
avID,
|
||||
previousID: targetElement.parentElement.querySelector(`[data-id="${gutterTypes[2]}"`).previousElementSibling?.getAttribute("data-id") || "",
|
||||
previousID: targetElement.parentElement.querySelector(`[data-col-id="${gutterTypes[2]}"`).previousElementSibling?.getAttribute("data-col-id") || "",
|
||||
id: gutterTypes[2],
|
||||
}]);
|
||||
return;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue