Change center position on zooming in Blazor Maps Component
4 Nov 20251 minute to read
The Blazor Maps component supports changing the map’s center position by specifying coordinates in the MapsCenterPosition. The ZoomFactor property in the MapsZoomSettings focuses on the specified center position.
@using Syncfusion.Blazor.Maps
<SfMaps>
@* To change center position *@
<MapsCenterPosition Latitude="25.54244147012483" Longitude="-89.62646484375"></MapsCenterPosition>
<MapsZoomSettings Enable="false" ZoomFactor="13"></MapsZoomSettings>
<MapsLayers>
<MapsLayer ShapeData='new {dataOptions= "https://cdn.syncfusion.com/maps/map-data/world-map.json"}' TValue="string"></MapsLayer>
</MapsLayers>
</SfMaps>