mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-17 23:20:13 +01:00
This commit is contained in:
parent
3a1803c8da
commit
d61fbd83c6
2 changed files with 11 additions and 7 deletions
|
|
@ -546,18 +546,22 @@ export const refreshAV = (protyle: IProtyle, operation: IOperation) => {
|
|||
item.querySelector(".av__drag-fill")?.remove();
|
||||
});
|
||||
addDragFill(item.querySelector(".av__cell--select"));
|
||||
}
|
||||
if (operation.action === "setAttrViewBlockView") {
|
||||
} else if (operation.action === "setAttrViewBlockView") {
|
||||
const viewTabElement = item.querySelector(`.av__views > .layout-tab-bar > .item[data-id="${operation.id}"]`) as HTMLElement;
|
||||
if (viewTabElement) {
|
||||
item.dataset.pageSize = viewTabElement.dataset.page;
|
||||
}
|
||||
}
|
||||
if (operation.action === "addAttrViewView") {
|
||||
} else if (operation.action === "addAttrViewView") {
|
||||
item.dataset.pageSize = "50";
|
||||
}
|
||||
if (operation.action === "removeAttrViewView") {
|
||||
} else if (operation.action === "removeAttrViewView") {
|
||||
item.dataset.pageSize = item.querySelector(`.av__views > .layout-tab-bar .item[data-id="${item.getAttribute(Constants.CUSTOM_SY_AV_VIEW)}"]`)?.getAttribute("data-page");
|
||||
} else if (operation.action === "sortAttrViewView" && operation.data === "unRefresh") {
|
||||
const viewTabElement = item.querySelector(`.av__views > .layout-tab-bar > .item[data-id="${operation.id}"]`) as HTMLElement;
|
||||
if (viewTabElement && !operation.previousID && !viewTabElement.previousElementSibling) {
|
||||
return;
|
||||
} else if (viewTabElement && operation.previousID && viewTabElement.previousElementSibling?.getAttribute("data-id") === operation.previousID) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
avRender(item, protyle, () => {
|
||||
const attrElement = document.querySelector(`.b3-dialog--open[data-key="${Constants.DIALOG_ATTR}"] div[data-av-id="${avID}"]`) as HTMLElement;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue