mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-01-23 16:56:10 +01:00
🎨 https://github.com/siyuan-note/siyuan/issues/5066 "click-editorcontent" | "click-pdf"
This commit is contained in:
parent
ca2d08de27
commit
981c6688b8
2 changed files with 12 additions and 3 deletions
|
|
@ -579,7 +579,9 @@ export class Gutter {
|
|||
}).element);
|
||||
}
|
||||
}
|
||||
AIActions(selectsElement, protyle);
|
||||
if (!protyle.disabled) {
|
||||
AIActions(selectsElement, protyle);
|
||||
}
|
||||
const copyMenu: IMenu[] = [{
|
||||
label: window.siyuan.languages.copy,
|
||||
accelerator: "⌘C",
|
||||
|
|
@ -710,6 +712,7 @@ export class Gutter {
|
|||
}
|
||||
this.app?.plugins?.forEach((plugin) => {
|
||||
plugin.eventBus.emit("click-blockicon", {
|
||||
protyle,
|
||||
menu: window.siyuan.menus.menu,
|
||||
blockElements: selectsElement,
|
||||
});
|
||||
|
|
@ -996,7 +999,9 @@ export class Gutter {
|
|||
submenu: turnIntoSubmenu
|
||||
}).element);
|
||||
}
|
||||
AIActions([nodeElement], protyle);
|
||||
if (!protyle.disabled) {
|
||||
AIActions([nodeElement], protyle);
|
||||
}
|
||||
const copyMenu = (copySubMenu(id, true, nodeElement) as IMenu[]).concat([{
|
||||
label: window.siyuan.languages.copy,
|
||||
accelerator: "⌘C",
|
||||
|
|
@ -1509,6 +1514,7 @@ export class Gutter {
|
|||
}).element);
|
||||
this.app?.plugins?.forEach((plugin) => {
|
||||
plugin.eventBus.emit("click-blockicon", {
|
||||
protyle,
|
||||
menu: window.siyuan.menus.menu,
|
||||
blockElements: [nodeElement]
|
||||
});
|
||||
|
|
|
|||
|
|
@ -1503,7 +1503,10 @@ export class WYSIWYG {
|
|||
let shiftStartElement: HTMLElement;
|
||||
this.element.addEventListener("click", (event: MouseEvent & { target: HTMLElement }) => {
|
||||
this.app.plugins.forEach(item => {
|
||||
item.eventBus.emit("click-editorcontent", event);
|
||||
item.eventBus.emit("click-editorcontent", {
|
||||
protyle,
|
||||
event
|
||||
});
|
||||
});
|
||||
hideElements(["hint", "util"], protyle);
|
||||
const ctrlIsPressed = event.metaKey || event.ctrlKey;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue