From 83551e317e105ea1c42097b9e53a464aa6f1cbe0 Mon Sep 17 00:00:00 2001 From: Devin Howard Date: Mon, 2 Mar 2015 18:05:45 -0500 Subject: [PATCH] create synapse if you click away from the synapse title form --- app/assets/javascripts/src/Metamaps.JIT.js.erb | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/app/assets/javascripts/src/Metamaps.JIT.js.erb b/app/assets/javascripts/src/Metamaps.JIT.js.erb index c34fcb6b..6cd0fa88 100644 --- a/app/assets/javascripts/src/Metamaps.JIT.js.erb +++ b/app/assets/javascripts/src/Metamaps.JIT.js.erb @@ -1047,7 +1047,11 @@ Metamaps.JIT = { Metamaps.TopicCard.hideCard(); Metamaps.SynapseCard.hideCard(); Metamaps.Create.newTopic.hide(); - Metamaps.Create.newSynapse.hide(); + if ($('#new_synapse').is(":visible")) { + // Hide the new_synapse form and create the synapse! + Metamaps.Synapse.createSynapseLocally(); + }//if + $('.rightclickmenu').remove(); // reset the draw synapse positions to false Metamaps.Mouse.synapseStartCoordinates = [];