增加delete删除node功能
This commit is contained in:
parent
e9c5ac6ec0
commit
8350dfe2c9
|
@ -11,7 +11,7 @@ export default function(G6){
|
|||
onKeydown(e) {
|
||||
const items = this.graph.get('selectedItems');
|
||||
const focus = this.graph.get('focusGraphWrapper');
|
||||
if(e.keyCode === 8 && items && items.length > 0 && focus){
|
||||
if (e.keyCode === 46 && items && items.length > 0 && focus) {
|
||||
if (this.graph.executeCommand) {
|
||||
this.graph.executeCommand('delete', {});
|
||||
} else {
|
||||
|
|
Loading…
Reference in New Issue