]> git.openstreetmap.org Git - rails.git/blobdiff - app/assets/javascripts/index/note.js
Merge pull request #1151 from polarbearing/patch-1
[rails.git] / app / assets / javascripts / index / note.js
index 2d4a8decff96e87ece810aa4c506e00a8c3eea6c..3973420bdd3d3536682aa0b87b6720c65b7e9874 100644 (file)
@@ -1,6 +1,5 @@
 OSM.Note = function (map) {
-  var noteLayer = map.noteLayer,
-    content = $('#sidebar_content'),
+  var content = $('#sidebar_content'),
     page = {},
     halo, currentNote;
 
@@ -60,7 +59,7 @@ OSM.Note = function (map) {
     content.find("textarea").on("input", function (e) {
       var form = e.target.form;
 
-      if ($(e.target).val() == "") {
+      if ($(e.target).val() === "") {
         $(form.close).val(I18n.t("javascripts.notes.show.resolve"));
         $(form.comment).prop("disabled", true);
       } else {
@@ -88,13 +87,13 @@ OSM.Note = function (map) {
     currentNote = L.marker(latLng, {
       icon: noteIcons[data.status],
       opacity: 1,
-      clickable: true
+      interactive: true
     });
 
     map.addLayer(currentNote);
 
     if (callback) callback();
-  };
+  }
 
   function moveToNote() {
     var data = $('.details').data(),