diff --git a/frontend/src/components/Graph.jsx b/frontend/src/components/Graph.jsx index 595eb5f..2769a91 100644 --- a/frontend/src/components/Graph.jsx +++ b/frontend/src/components/Graph.jsx @@ -46,13 +46,20 @@ class GraphImpl extends React.Component { settings={SETTINGS} style={STYLE} onClickNode={(e) => this.props.selectAndLoadInstance(e.data.node.label)} - onClickStage={(e) => this.props.selectAndLoadInstance(null)} + onClickStage={this.onClickStage} > ) } + + onClickStage = (e) => { + // Deselect the instance (unless this was a drag event) + if (!e.data.captor.isDragging) { + this.props.selectAndLoadInstance(null); + } + } } const mapStateToProps = (state) => ({