Query on click-to-zoom feature #1054
-
I am trying to create a dashboard in Streamlit where I will have multiple layers for a three-level drill-down map e.g. State to County to City. I was able to add a dropdown to filter and zoom, but I am interested in click-to-zoom for quick filtering. Does Leafmap support click-to-zoom feature? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 6 replies
-
Streamlit for folium lacks bidrectional communication functionality. Once the map is deplayed, it is a done deal. There is no way to pass information programmatically back to the map. For web apps with directional functionality, you need to use Solara with leafmap. It has native support for ipywidgets. Try out my example: https://huggingface.co/spaces/giswqs/solara-geospatial |
Beta Was this translation helpful? Give feedback.
-
You can create a new Map class that inherits See this exmaple Line 1256 in 7fc7230 |
Beta Was this translation helpful? Give feedback.
Streamlit for folium lacks bidrectional communication functionality. Once the map is deplayed, it is a done deal. There is no way to pass information programmatically back to the map.
For web apps with directional functionality, you need to use Solara with leafmap. It has native support for ipywidgets. Try out my example: https://huggingface.co/spaces/giswqs/solara-geospatial