![]() The more the user is zoomed in, the larger the radius. Var marker = L.circle(, markerRadius(price)). Im using Leaflet to visualize point data and Im trying to change the radius of circle according to the zoom level. My ultimate goal is for the circle markers to be reduced in size as the user zooms into the map, and then increase in size as the user zooms out.īelow is my code. You can access my map at this link (sorry for the untrusted certificate). I would like to use this fork (updated to work with latest Leaflet version) of the Leaflet Zoomify plugin to display a custom map (huge texture 30000x70000). Leaflet.Autocomplete is to expand the autosugestion plugin with the ability to geocode and show data on the map in the way you think you need. Refreshing the feature layer also does not change the behavior. Cannot retrieve contributors at this time 37 lines (33 sloc) 1. ![]() So far, I have tried firing map.InvalidateSize() on the zoomend event but that does not seem to have any effect. Leaflet.Zoomify/example.html Go to file Go to fileT Go to lineL Copy path Copy This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository. ![]() With addTiles you will add the default base map and with setView you will be able to set a center point and a zoom level. Theres a myZoom object that records the zoom levels so you can find out whether or not the final zoom is in or out by simple subtraction. I am trying to find a way to have my CircleMarkers resize themselves after zooming in or out so that they scale properly with the map. In order to create a simple map you will need to load the package and then use the leaflet function and then add new layers with the pipe operator ( > ). ![]()
0 Comments
Leave a Reply. |