This commit is contained in:
parent
2c7a58d3b9
commit
7d41575c2f
5 changed files with 18 additions and 7 deletions
|
@ -140,7 +140,7 @@ export class BlockPanel {
|
|||
pinElement.classList.add("block__icon--active");
|
||||
pinElement.setAttribute("aria-label", window.siyuan.languages.unpin);
|
||||
this.element.setAttribute("data-pin", "true");
|
||||
})
|
||||
});
|
||||
/// #endif
|
||||
this.render();
|
||||
}
|
||||
|
|
|
@ -491,8 +491,19 @@ export const bazaar = {
|
|||
});
|
||||
return;
|
||||
}
|
||||
bazaar._genMyHTML(bazaarType, app);
|
||||
bazaar._onBazaar(response, bazaarType, ["themes", "icons"].includes(bazaarType));
|
||||
bazaar._genMyHTML(bazaarType, app);
|
||||
if (bazaarType === "plugins") {
|
||||
confirmDialog(window.siyuan.languages.confirm, window.siyuan.languages.enablePluginTip, () => {
|
||||
fetchPost("/api/petal/setPetalEnabled", {
|
||||
packageName: dataObj.name,
|
||||
enabled: true,
|
||||
}, (response) => {
|
||||
loadPlugin(app, response.data);
|
||||
bazaar._genMyHTML(bazaarType, app);
|
||||
});
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
event.preventDefault();
|
||||
|
|
|
@ -4,8 +4,8 @@ import {Constants} from "../constants";
|
|||
export const moveResize = (element: HTMLElement, afterCB?: (type: string) => void) => {
|
||||
element.addEventListener("mousedown", (event: MouseEvent & { target: HTMLElement }) => {
|
||||
let iconsElement = hasClosestByClassName(event.target, "resize__move");
|
||||
let x: number
|
||||
let y: number
|
||||
let x: number;
|
||||
let y: number;
|
||||
const elementRect = element.getBoundingClientRect();
|
||||
if (!iconsElement) {
|
||||
x = event.clientX;
|
||||
|
@ -124,4 +124,4 @@ export const moveResize = (element: HTMLElement, afterCB?: (type: string) => voi
|
|||
}
|
||||
};
|
||||
});
|
||||
}
|
||||
};
|
||||
|
|
|
@ -90,7 +90,7 @@ export class Tag extends Model {
|
|||
openGlobalSearch(app, `#${element.getAttribute("data-label")}#`, !window.siyuan.ctrlIsPressed);
|
||||
},
|
||||
rightClick: (element: HTMLElement, event: MouseEvent) => {
|
||||
openTagMenu(element, event, element.getAttribute("data-label"))
|
||||
openTagMenu(element, event, element.getAttribute("data-label"));
|
||||
},
|
||||
blockExtHTML: window.siyuan.config.readonly ? undefined : '<span class="b3-list-item__action"><svg><use xlink:href="#iconMore"></use></svg></span>',
|
||||
topExtHTML: window.siyuan.config.readonly ? undefined : '<span class="b3-list-item__action"><svg><use xlink:href="#iconMore"></use></svg></span>'
|
||||
|
|
|
@ -3,7 +3,7 @@ import {showMessage} from "../dialog/message";
|
|||
import {isMobile} from "./functions";
|
||||
import {fetchPost} from "./fetch";
|
||||
import {Dialog} from "../dialog";
|
||||
import {getNotebookName, getOpenNotebookCount} from "./pathName";
|
||||
import {getOpenNotebookCount} from "./pathName";
|
||||
import {validateName} from "../editor/rename";
|
||||
import {setStorageVal} from "../protyle/util/compatibility";
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue