'How to replace manipulation GUI with my own in vis.js

My question is regarding the default manipulation user interface in vis.js:

Image of the default graphical user interface

I would like to replace the existing manipulation user interface in vis.js with my own controls so I will be able to right click the network to add or remove nodes and edges.

I can see from this issue that in 2014 it wasn't possible but it it might have been possible to hack something together (though the links in there doesn't work anymore). My hope is that in the last 5 years this has been made possible without the need to fork the project.

Question:
Is it possible to disable the existing user interface and connect my own controls?



Solution 1:[1]

and how to put angular MatDialog in function that add edge for example?

  manipulation: {
    enabled: false,
    addEdge: this.addEdge
  }

In this case dialogRef = undefined and i can't open modal window to fill form.

addEdge(edgeData: any, callback: any) {
    const dialogRef = this._dialog.open(CreateEdgeModalComponent, {
      width: window.innerWidth > 960 ? '23%' : '40%',
    });
    dialogRef.afterClosed().subscribe(result => {
      if (result) {
        edgeData.label = ' ';
        edgeData.labelFrom = result;
        edgeData.labelTo = prompt('Please enter edge label', '');
        callback(edgeData);
      }
    })
  }

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Igor Abramov