Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 13 additions & 2 deletions app.js
Original file line number Diff line number Diff line change
Expand Up @@ -471,16 +471,26 @@ legend.onAdd = function (map) {
// add muni marker to map
var muni_icon = L.divIcon({
className: 'muni-marker'
,html: '<a href="//' + m + '.' + DOMAIN + '/">תב״ע פתוחה: ' + mun.display + '</a>'
,html: '<a href="//' + m + '.' + DOMAIN + '/"><i class="icon-home"></i><br><span class=marker_text>' + mun.display + '</span></a>'
,iconSize: null
});
L.marker(mun.center, {icon: muni_icon}).addTo(map);
var muni_marker = L.marker(mun.center, {icon: muni_icon, riseOnHover: true});
muni_marker.url = '//' + m + '.' + DOMAIN + '/';
muni_marker.addTo(map).on('click', changeMuni);

function changeMuni(e) {
window.open(e.target.url,'_self');

}
}

div.innerHTML += '<div id="muni-list" style="display: none;">' + mlist + '</div>'
return div;
};




legend.addTo(map);

// catch touchstart if possible, because click behaves weird on touch screens
Expand Down Expand Up @@ -543,4 +553,5 @@ $.ajax({
map._onResize();
}


});
17 changes: 14 additions & 3 deletions css/stylesheet.css
Original file line number Diff line number Diff line change
Expand Up @@ -120,15 +120,26 @@ h1 {
}

.muni-marker {
font-size: 20px;
background-color: #eee;
font-size: 1vw;
background-color: rgba(238, 238, 238, 0.7);
color: #333;
border: solid 3px rgba(0, 0, 0, .5);
border: solid 1px rgba(0, 0, 0, .5);
padding: 5px 10px;
white-space:nowrap;
border-radius: 8px;
text-align: center;
}


.muni-marker .marker_text {
display: none;
}

.muni-marker:hover .marker_text {
display: inline-block;
}


.row {
margin-left: 0;
}
Expand Down