diff --git a/pyvis/templates/template.html b/pyvis/templates/template.html
index 483a3e1..53712a3 100644
--- a/pyvis/templates/template.html
+++ b/pyvis/templates/template.html
@@ -265,6 +265,7 @@
{{heading}}
var network;
var container;
var options, data;
+ var highlightActive = false;
var filter = {
item : '',
property : '',
@@ -456,14 +457,10 @@ {{heading}}
network = new vis.Network(container, data, options);
- {% if neighborhood_highlight %}
+ {% if neighborhood_highlight or select_menu %}
network.on("click", neighbourhoodHighlight);
{% endif %}
- {% if select_menu %}
- network.on("selectNode", neighbourhoodHighlight);
- {% endif %}
-
{% if tooltip_link %}
// make a custom popup
var popup = document.createElement("div");