Map component that adds a minimap in view mode.
Arguments
- server
name of the provider or an URL (see
tm_tiles
). By default, it shows the same map as the basemap, and moreover, it will automatically change when the user switches basemaps. Note the latter does not happen whenserver
is specified.- toggle
should the minimap have a button to minimise it? By default
TRUE
.- stack
stack
- position
position
- z
z
- ...
Arguments passed on to
leaflet::addMiniMap
map
a map widget object
width
The width of the minimap in pixels. Defaults to 150.
height
The height of the minimap in pixels. Defaults to 150.
collapsedWidth
The width of the toggle marker and the minimap when collapsed, in pixels. Defaults to 19.
collapsedHeight
The height of the toggle marker and the minimap when collapsed, in pixels. Defaults to 19.
zoomLevelOffset
The offset applied to the zoom in the minimap compared to the zoom of the main map. Can be positive or negative, defaults to -5.
zoomLevelFixed
Overrides the offset to apply a fixed zoom level to the minimap regardless of the main map zoom. Set it to any valid zoom level, if unset zoomLevelOffset is used instead.
centerFixed
Applies a fixed position to the minimap regardless of the main map's view / position. Prevents panning the minimap, but does allow zooming (both in the minimap and the main map). If the minimap is zoomed, it will always zoom around the centerFixed point. You can pass in a LatLng-equivalent object. Defaults to false.
zoomAnimation
Sets whether the minimap should have an animated zoom. (Will cause it to lag a bit after the movement of the main map.) Defaults to false.
toggleDisplay
Sets whether the minimap should have a button to minimise it. Defaults to false.
autoToggleDisplay
Sets whether the minimap should hide automatically, if the parent map bounds does not fit within the minimap bounds. Especially useful when 'zoomLevelFixed' is set.
minimized
Sets whether the minimap should start in a minimized position.
aimingRectOptions
Sets the style of the aiming rectangle by passing in a Path.Options (https://web.archive.org/web/20220702182250/https://leafletjs.com/reference-1.3.4.html#path-options) object. (Clickable will always be overridden and set to false.)
shadowRectOptions
Sets the style of the aiming shadow rectangle by passing in a Path.Options (https://web.archive.org/web/20220702182250/https://leafletjs.com/reference-1.3.4.html#path-option) object. (Clickable will always be overridden and set to false.)
strings
Overrides the default strings allowing for translation.
tiles
URL for tiles or one of the pre-defined providers.
mapOptions
Sets Leaflet options for the MiniMap map. It does not override the MiniMap default map options but extends them.