From: Leo Koppelkamm Date: Sun, 5 May 2013 13:30:17 +0000 (+0200) Subject: Replace note markers with ones styled like the other markers X-Git-Tag: live~4990 X-Git-Url: https://git.openstreetmap.org/rails.git/commitdiff_plain/890153b2a6412a60f352f88fc3d8c80be14451fc Replace note markers with ones styled like the other markers --- diff --git a/app/assets/images/NoteMarker.svg b/app/assets/images/NoteMarker.svg new file mode 100644 index 000000000..47b7bb571 --- /dev/null +++ b/app/assets/images/NoteMarker.svg @@ -0,0 +1,56 @@ + + +image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/app/assets/images/closed_note_marker.png b/app/assets/images/closed_note_marker.png index bf6d6bb25..ad2812fbe 100644 Binary files a/app/assets/images/closed_note_marker.png and b/app/assets/images/closed_note_marker.png differ diff --git a/app/assets/images/closed_note_marker@2x.png b/app/assets/images/closed_note_marker@2x.png new file mode 100644 index 000000000..ea434e90e Binary files /dev/null and b/app/assets/images/closed_note_marker@2x.png differ diff --git a/app/assets/images/new_note_marker.png b/app/assets/images/new_note_marker.png index 671cf424c..a41464487 100644 Binary files a/app/assets/images/new_note_marker.png and b/app/assets/images/new_note_marker.png differ diff --git a/app/assets/images/new_note_marker@2x.png b/app/assets/images/new_note_marker@2x.png new file mode 100644 index 000000000..6098079cd Binary files /dev/null and b/app/assets/images/new_note_marker@2x.png differ diff --git a/app/assets/images/open_note_marker.png b/app/assets/images/open_note_marker.png index a58031663..6fe5cb7ac 100644 Binary files a/app/assets/images/open_note_marker.png and b/app/assets/images/open_note_marker.png differ diff --git a/app/assets/images/open_note_marker@2x.png b/app/assets/images/open_note_marker@2x.png new file mode 100644 index 000000000..e465ca918 Binary files /dev/null and b/app/assets/images/open_note_marker@2x.png differ diff --git a/app/assets/javascripts/index/notes.js.erb b/app/assets/javascripts/index/notes.js.erb index a58e5c568..7336c49ec 100644 --- a/app/assets/javascripts/index/notes.js.erb +++ b/app/assets/javascripts/index/notes.js.erb @@ -7,18 +7,18 @@ $(document).ready(function () { var noteIcons = { "new": L.icon({ iconUrl: "<%= image_path 'new_note_marker.png' %>", - iconSize: [22, 22], - iconAnchor: [11, 11] + iconSize: [25, 40], + iconAnchor: [12, 40] }), "open": L.icon({ iconUrl: "<%= image_path 'open_note_marker.png' %>", - iconSize: [22, 22], - iconAnchor: [11, 11] + iconSize: [25, 40], + iconAnchor: [12, 40] }), "closed": L.icon({ iconUrl: "<%= image_path 'closed_note_marker.png' %>", - iconSize: [22, 22], - iconAnchor: [11, 11] + iconSize: [25, 40], + iconAnchor: [12, 40] }) }; @@ -96,7 +96,7 @@ $(document).ready(function () { { marker = L.marker(feature.geometry.coordinates.reverse(), { icon: noteIcons[feature.properties.status], - opacity: 0.7 + opacity: 0.9 }); marker.addTo(noteLayer).bindPopup( @@ -151,7 +151,7 @@ $(document).ready(function () { minWidth: 320, maxWidth: mapSize.y * 1 / 3, maxHeight: mapSize.y * 2 / 3, - offset: new L.Point(0, -3), + offset: new L.Point(0, -40), autoPanPadding: new L.Point(60, 40) }; } @@ -264,7 +264,7 @@ $(document).ready(function () { newNote = L.marker(map.containerPointToLatLng(markerPosition), { icon: noteIcons["new"], - opacity: 0.7, + opacity: 0.9, draggable: true });