mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-20 08:30:12 +01:00
This commit is contained in:
parent
ac31b61a19
commit
609b50d40a
8 changed files with 19 additions and 3 deletions
|
|
@ -899,6 +899,7 @@
|
||||||
"column": "Column",
|
"column": "Column",
|
||||||
"copied": "Copied",
|
"copied": "Copied",
|
||||||
"copy": "Copy",
|
"copy": "Copy",
|
||||||
|
"copyText": "Copy text *",
|
||||||
"delete-column": "Delete Column",
|
"delete-column": "Delete Column",
|
||||||
"delete-row": "Delete Row",
|
"delete-row": "Delete Row",
|
||||||
"down": "Down",
|
"down": "Down",
|
||||||
|
|
|
||||||
|
|
@ -899,6 +899,7 @@
|
||||||
"column": "Columna",
|
"column": "Columna",
|
||||||
"copied": "Copiado",
|
"copied": "Copiado",
|
||||||
"copy": "Copiar",
|
"copy": "Copiar",
|
||||||
|
"copyText": "Copiar texto *",
|
||||||
"delete-column": "Borrar columna",
|
"delete-column": "Borrar columna",
|
||||||
"delete-row": "Borrar fila",
|
"delete-row": "Borrar fila",
|
||||||
"down": "Abajo",
|
"down": "Abajo",
|
||||||
|
|
|
||||||
|
|
@ -899,6 +899,7 @@
|
||||||
"column": "Colonne",
|
"column": "Colonne",
|
||||||
"copied": "Copié",
|
"copied": "Copié",
|
||||||
"copy": "Copie",
|
"copy": "Copie",
|
||||||
|
"copyText": "Copier le texte *",
|
||||||
"delete-column": "Supprimer une Colonne",
|
"delete-column": "Supprimer une Colonne",
|
||||||
"delete-row": "Supprimer la rangée",
|
"delete-row": "Supprimer la rangée",
|
||||||
"down": "En bas",
|
"down": "En bas",
|
||||||
|
|
|
||||||
|
|
@ -899,6 +899,7 @@
|
||||||
"column": "行",
|
"column": "行",
|
||||||
"copied": "已複製",
|
"copied": "已複製",
|
||||||
"copy": "複製",
|
"copy": "複製",
|
||||||
|
"copyText": "複製 文本 *",
|
||||||
"delete-column": "刪除行",
|
"delete-column": "刪除行",
|
||||||
"delete-row": "刪除列",
|
"delete-row": "刪除列",
|
||||||
"down": "下",
|
"down": "下",
|
||||||
|
|
|
||||||
|
|
@ -899,6 +899,7 @@
|
||||||
"column": "列",
|
"column": "列",
|
||||||
"copied": "已复制",
|
"copied": "已复制",
|
||||||
"copy": "复制",
|
"copy": "复制",
|
||||||
|
"copyText": "复制 文本 *",
|
||||||
"delete-column": "删除列",
|
"delete-column": "删除列",
|
||||||
"delete-row": "删除行",
|
"delete-row": "删除行",
|
||||||
"down": "下",
|
"down": "下",
|
||||||
|
|
|
||||||
|
|
@ -253,6 +253,7 @@ export abstract class Constants {
|
||||||
hLayout: {default: "", custom: ""},
|
hLayout: {default: "", custom: ""},
|
||||||
vLayout: {default: "", custom: ""},
|
vLayout: {default: "", custom: ""},
|
||||||
refPopover: {default: "", custom: ""},
|
refPopover: {default: "", custom: ""},
|
||||||
|
copyText: {default: "", custom: ""},
|
||||||
expand: {default: "⌘↓", custom: "⌘↓"},
|
expand: {default: "⌘↓", custom: "⌘↓"},
|
||||||
collapse: {default: "⌘↑", custom: "⌘↑"},
|
collapse: {default: "⌘↑", custom: "⌘↑"},
|
||||||
insertBottom: {default: "⌥⌘.", custom: "⌥⌘."},
|
insertBottom: {default: "⌥⌘.", custom: "⌥⌘."},
|
||||||
|
|
|
||||||
|
|
@ -729,7 +729,7 @@ export class Gutter {
|
||||||
|
|
||||||
if (protyle?.app?.plugins) {
|
if (protyle?.app?.plugins) {
|
||||||
emitOpenMenu({
|
emitOpenMenu({
|
||||||
plugins:protyle.app.plugins,
|
plugins: protyle.app.plugins,
|
||||||
type: "click-blockicon",
|
type: "click-blockicon",
|
||||||
detail: {
|
detail: {
|
||||||
protyle,
|
protyle,
|
||||||
|
|
@ -1545,7 +1545,7 @@ export class Gutter {
|
||||||
|
|
||||||
if (protyle?.app?.plugins) {
|
if (protyle?.app?.plugins) {
|
||||||
emitOpenMenu({
|
emitOpenMenu({
|
||||||
plugins:protyle.app.plugins,
|
plugins: protyle.app.plugins,
|
||||||
type: "click-blockicon",
|
type: "click-blockicon",
|
||||||
detail: {
|
detail: {
|
||||||
protyle,
|
protyle,
|
||||||
|
|
@ -1749,7 +1749,8 @@ export class Gutter {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
return {
|
return {
|
||||||
label: `${window.siyuan.languages.copy} ${window.siyuan.languages.text} *`,
|
accelerator: window.siyuan.config.keymap.editor.general.copyText.custom,
|
||||||
|
label: window.siyuan.languages.copyText,
|
||||||
click() {
|
click() {
|
||||||
// 用于标识复制文本 *
|
// 用于标识复制文本 *
|
||||||
selectsElement[0].setAttribute("data-reftext", "true");
|
selectsElement[0].setAttribute("data-reftext", "true");
|
||||||
|
|
|
||||||
|
|
@ -971,6 +971,15 @@ export const keydown = (protyle: IProtyle, editorElement: HTMLElement) => {
|
||||||
event.stopPropagation();
|
event.stopPropagation();
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
if (matchHotKey(window.siyuan.config.keymap.editor.general.copyText.custom, event)) {
|
||||||
|
// 用于标识复制文本 *
|
||||||
|
nodeElement.setAttribute("data-reftext", "true");
|
||||||
|
focusByRange(getEditorRange(nodeElement));
|
||||||
|
document.execCommand("copy");
|
||||||
|
event.preventDefault();
|
||||||
|
event.stopPropagation();
|
||||||
|
return true;
|
||||||
|
}
|
||||||
if (matchHotKey(window.siyuan.config.keymap.editor.general.copyBlockRef.custom, event)) {
|
if (matchHotKey(window.siyuan.config.keymap.editor.general.copyBlockRef.custom, event)) {
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
event.stopPropagation();
|
event.stopPropagation();
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue