feat(脑图): 快捷键是否可编辑判定

This commit is contained in:
baiqi 2024-11-07 15:17:19 +08:00 committed by 刘瑞斌
parent 6657ad923f
commit 6e749c4e2d
1 changed files with 4 additions and 2 deletions

View File

@ -59,7 +59,7 @@
tagProps,
viewMenuProps,
} from './props';
import { isNodeInMinderView } from './script/tool/utils';
import { isDisableNode, isNodeInMinderView } from './script/tool/utils';
const emit = defineEmits<{
(e: 'moldChange', data: number): void;
@ -132,7 +132,9 @@
const { unbindShortcuts } = useShortCut(
{
input: () => {
if (window.minder._status !== 'readonly' && !isDisableNode(window.minder)) {
window.minderEditor.editText();
}
},
undo: () => {
window.minderHistory?.undo();