diff --git a/src/components/Graph.jsx b/src/components/Graph.jsx index 65b52ab..5030814 100644 --- a/src/components/Graph.jsx +++ b/src/components/Graph.jsx @@ -277,7 +277,9 @@ export default class GraphContainer extends Component { relayout() { closeTooltip(); + this.clearScale(); sigma.layouts.stopForceLink(); + if (appStore.dagre) { sigma.layouts.dagre.start(this.state.sigmaInstance); } else { diff --git a/src/index.js b/src/index.js index 283cf15..502293f 100644 --- a/src/index.js +++ b/src/index.js @@ -312,6 +312,7 @@ if (!existsSync(imagepath)){ global.closeTooltip = function(){ if (appStore.currentTooltip !== null){ appStore.currentTooltip.close(); + appStore.currentTooltip = null; } }