DomParfitt / graphviz-react

React component for displaying Graphviz graphs
MIT License
102 stars 21 forks source link

Allow Zoom to be Disabled #30

Open DomParfitt opened 3 years ago

DomParfitt commented 3 years ago

Currently (as per #29) if zoom is enabled for a graph then disabling will have no effect and scrolling will still zoom in and out of the graph. The expected behaviour is that disabling zoom should prevent the graph from scaling in and out on scroll.

This appears to be a bug in the underlying package (d3-graphviz) and there is an open issue for it there: d3-graphviz#180 but because d3-graphviz is a major version ahead of graphviz-react any bugfix may not be backported to the version used by graphviz-react. Therefore we are putting a fix in place here until we are able to upgrade to the latest version to ensure the behaviour is as expected.