Blazorise Maps API

Explore the Blazorise Maps API reference for parameters, events, methods, and related types.

For examples and usage guidance, see the Maps documentation.

API

Parameters

Map

ParameterDefaultType
ChildContentnullRenderFragment

Defines tile layers, markers, shapes, and other map content rendered inside the map.
Optionsnew()MapOptions

Configures map interaction, provider, zoom limits, and controls.
Viewnew()MapView

Specifies the map center, zoom level, and optional bounds. Updating the value after render moves the displayed map view.

MapTileLayer

ParameterDefaultType
Attribution—string

Provides attribution text required by the tile provider.
IdGeneratedstring

Identifies this layer for updates, events, and removal. Changing the value after initialization removes the previous provider layer and registers a new one.
When omitted, generates a GUID in N format.
Interactivetruebool

Enables pointer interaction for this layer when supported by the provider.
MaxZoomnulldouble?

Limits this tile layer to the specified maximum zoom level.
MinZoomnulldouble?

Limits this tile layer to the specified minimum zoom level.
Name—string

Provides an optional display name for UI or diagnostics.
Opacity1ddouble

Applies layer opacity to tile, marker, and shape rendering, where 1 is fully opaque and 0 is fully transparent.
Source—string

Specifies the raster tile source URL, typically using {z}, {x}, and {y} placeholders.
Subdomainsnullstring[]

Specifies optional tile subdomains used by the source URL.
TileSize256int

Specifies the tile size in pixels.
Visibletruebool

Controls whether this layer is rendered on the map.
ZIndexnullint?

Controls the layer ordering relative to other layers when supported by the provider.

MapMarker

ParameterDefaultType
CoordinatenullMapCoordinate

Specifies the marker coordinate.
Draggablefalsebool

Allows the marker to be moved by dragging.
IconnullMapMarkerIcon

Specifies a custom marker icon.
IdGeneratedstring

Identifies this layer for updates, events, and removal. Changing the value after initialization removes the previous provider layer and registers a new one.
When omitted, generates a GUID in N format.
Interactivetruebool

Enables pointer interaction for this layer when supported by the provider.
Name—string

Provides an optional display name for UI or diagnostics.
Opacity1ddouble

Applies layer opacity to tile, marker, and shape rendering, where 1 is fully opaque and 0 is fully transparent.
PopupText—string

Provides popup text opened by the marker.
Title—string

Provides browser title text for the marker.
TooltipText—string

Provides tooltip text displayed near the marker.
Visibletruebool

Controls whether this layer is rendered on the map.
ZIndexnullint?

Controls the layer ordering relative to other layers when supported by the provider.

MapMarkerLayer

ParameterDefaultType
DatanullIEnumerable<TItem>

Provides the data items used to create markers.
IdGeneratedstring

Identifies this layer for updates, events, and removal. Changing the value after initialization removes the previous provider layer and registers a new one.
When omitted, generates a GUID in N format.
Interactivetruebool

Enables pointer interaction for this layer when supported by the provider.
Name—string

Provides an optional display name for UI or diagnostics.
Opacity1ddouble

Applies layer opacity to tile, marker, and shape rendering, where 1 is fully opaque and 0 is fully transparent.
Visibletruebool

Controls whether this layer is rendered on the map.
ZIndexnullint?

Controls the layer ordering relative to other layers when supported by the provider.

MapCircle

ParameterDefaultType
CenternullMapCoordinate

Specifies the circle center coordinate.
IdGeneratedstring

Identifies this layer for updates, events, and removal. Changing the value after initialization removes the previous provider layer and registers a new one.
When omitted, generates a GUID in N format.
Interactivetruebool

Enables pointer interaction for this layer when supported by the provider.
Name—string

Provides an optional display name for UI or diagnostics.
Opacity1ddouble

Applies layer opacity to tile, marker, and shape rendering, where 1 is fully opaque and 0 is fully transparent.
Radius0double

Specifies the circle radius in meters.
Stylenew()MapShapeStyle

Controls the circle stroke and fill styling.
Visibletruebool

Controls whether this layer is rendered on the map.
ZIndexnullint?

Controls the layer ordering relative to other layers when supported by the provider.

MapPolyline

ParameterDefaultType
CoordinatesnullIReadOnlyList<MapCoordinate>

Specifies the ordered coordinates connected by the polyline.
IdGeneratedstring

Identifies this layer for updates, events, and removal. Changing the value after initialization removes the previous provider layer and registers a new one.
When omitted, generates a GUID in N format.
Interactivetruebool

Enables pointer interaction for this layer when supported by the provider.
Name—string

Provides an optional display name for UI or diagnostics.
Opacity1ddouble

Applies layer opacity to tile, marker, and shape rendering, where 1 is fully opaque and 0 is fully transparent.
Stylenew()MapShapeStyle

Controls the polyline stroke styling.
Visibletruebool

Controls whether this layer is rendered on the map.
ZIndexnullint?

Controls the layer ordering relative to other layers when supported by the provider.

MapPolygon

ParameterDefaultType
IdGeneratedstring

Identifies this layer for updates, events, and removal. Changing the value after initialization removes the previous provider layer and registers a new one.
When omitted, generates a GUID in N format.
Interactivetruebool

Enables pointer interaction for this layer when supported by the provider.
Name—string

Provides an optional display name for UI or diagnostics.
Opacity1ddouble

Applies layer opacity to tile, marker, and shape rendering, where 1 is fully opaque and 0 is fully transparent.
RingsnullIReadOnlyList<IReadOnlyList<MapCoordinate>>

Specifies the polygon rings. The first ring is the outer boundary; additional rings can represent holes.
Stylenew()MapShapeStyle

Controls the polygon stroke and fill styling.
Visibletruebool

Controls whether this layer is rendered on the map.
ZIndexnullint?

Controls the layer ordering relative to other layers when supported by the provider.

Events

Map

EventType
ClickedEventCallback<MapMouseEventArgs>

Handles single-click interaction on the map surface.
ContextMenuEventCallback<MapMouseEventArgs>

Handles context-menu interaction on the map surface.
DoubleClickedEventCallback<MapMouseEventArgs>

Handles double-click interaction on the map surface.
ReadyEventCallback<MapReadyEventArgs>

Runs after the map provider has initialized the rendered map.
ViewChangedEventCallback<MapView>

Notifies when the bound map view changes.
ViewUpdatedEventCallback<MapViewUpdatedEventArgs>

Reports view changes with bounds and the reason for the change.

MapMarker

EventType
ClickedEventCallback<MapMarkerEventArgs>

Handles clicks on this marker.
DraggedEventCallback<MapMarkerDraggedEventArgs>

Handles completed drag operations for this marker.

MapMarkerLayer

EventType
CoordinateSelectorFunc<TItem, MapCoordinate>

Selects the marker coordinate from each data item.
DraggableSelectorFunc<TItem, bool>

Determines whether each marker can be dragged.
IconSelectorFunc<TItem, MapMarkerIcon>

Selects a custom icon for each marker.
IdSelectorFunc<TItem, string>

Selects a stable marker identifier from each data item.
MarkerClickedEventCallback<MapMarkerClickedEventArgs<TItem>>

Handles clicks on data-bound markers.
MarkerDraggedEventCallback<MapMarkerDraggedEventArgs<TItem>>

Handles completed drag operations for data-bound markers.
PopupTextSelectorFunc<TItem, string>

Selects popup text for each marker.
TitleSelectorFunc<TItem, string>

Selects the browser title text for each marker.
TooltipTextSelectorFunc<TItem, string>

Selects tooltip text for each marker.

Methods

Map

MethodReturnParameters
FitBoundsValueTaskMapBounds bounds, MapFitBoundsOptions options

Fits the map view to the specified bounds.
GetBoundsValueTask<MapBounds>—

Reads the currently visible geographic bounds from the rendered map.
GetViewValueTask<MapView>—

Reads the current center, zoom level, and visible bounds from the rendered map.
InvalidateSizeValueTask—

Invalidates the map size after its container size changes.
PanToValueTaskMapCoordinate center, MapAnimationOptions options

Pans the map to the specified center coordinate.
SetViewValueTaskMapCoordinate center, double zoom, MapAnimationOptions options

Sets the map view to the specified center and zoom.
ZoomInValueTask—

Increases the current zoom level.
ZoomOutValueTask—

Decreases the current zoom level.
On this page