mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-02-26 00:44:07 +01:00
Add data-id attribute to the buttons (#14182)
fix https://github.com/siyuan-note/siyuan/issues/12518
This commit is contained in:
parent
853cf71d31
commit
33f8def8ce
16 changed files with 224 additions and 31 deletions
|
|
@ -195,6 +195,7 @@ export class Title {
|
|||
const range = getEditorRange(this.editElement);
|
||||
if (range.toString() !== "") {
|
||||
window.siyuan.menus.menu.append(new MenuItem({
|
||||
id: "copy",
|
||||
icon: "iconCopy",
|
||||
accelerator: "⌘C",
|
||||
label: window.siyuan.languages.copy,
|
||||
|
|
@ -204,6 +205,7 @@ export class Title {
|
|||
}
|
||||
}).element);
|
||||
window.siyuan.menus.menu.append(new MenuItem({
|
||||
id: "cut",
|
||||
icon: "iconCut",
|
||||
accelerator: "⌘X",
|
||||
label: window.siyuan.languages.cut,
|
||||
|
|
@ -216,6 +218,7 @@ export class Title {
|
|||
}
|
||||
}).element);
|
||||
window.siyuan.menus.menu.append(new MenuItem({
|
||||
id: "delete",
|
||||
icon: "iconTrashcan",
|
||||
accelerator: "⌫",
|
||||
label: window.siyuan.languages.delete,
|
||||
|
|
@ -230,6 +233,7 @@ export class Title {
|
|||
}).element);
|
||||
}
|
||||
window.siyuan.menus.menu.append(new MenuItem({
|
||||
id: "paste",
|
||||
label: window.siyuan.languages.paste,
|
||||
icon: "iconPaste",
|
||||
accelerator: "⌘V",
|
||||
|
|
@ -249,6 +253,7 @@ export class Title {
|
|||
}
|
||||
}).element);
|
||||
window.siyuan.menus.menu.append(new MenuItem({
|
||||
id: "pasteAsPlainText",
|
||||
label: window.siyuan.languages.pasteAsPlainText,
|
||||
accelerator: "⇧⌘V",
|
||||
click: async () => {
|
||||
|
|
@ -265,6 +270,7 @@ export class Title {
|
|||
}
|
||||
}).element);
|
||||
window.siyuan.menus.menu.append(new MenuItem({
|
||||
id: "selectAll",
|
||||
label: window.siyuan.languages.selectAll,
|
||||
icon: "iconSelect",
|
||||
accelerator: "⌘A",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue