Releases: openlayers/ol-mapbox-style
Releases · openlayers/ol-mapbox-style
v6.0.1
v6.0.0
Breaking changes
Module paths
ol-mapbox-style now ships with transpiled modules in the dist/
folder, and sources in the src/
folder. Previously, all modules were provided in the root directory.
When upgrading, the import paths need to be checked. For example,
import stylefunction from 'ol-mapbox-style/stylefunction';
needs to be changed to
import stylefunction from 'ol-mapbox-style/dist/stylefunction';
Other changes
- Allow mapbox:// urls for all layer types, not just vector
v5.0.2
v5.0.0-beta.2
- More efficient midpoint rendering
- Only include style spec once
- Trim the label-field string
- Round text size to integer pixels
v5.0.0-beta.1
- Requires ol@6
- Uses new OpenLayers z-index ordering for decluttered content
- Support for the
text-rotation-alignment
property - Better
max-angle
handling in combination withtext-letter-spacing
v4.3.0
- Load Google fonts with the correct weight and style
- Support for the
text-max-angle
layout property - More efficient color handling without cache
- Improve text wrapping for to avoid short lines
- Apply default resolutions (Mapbox zoom levels) to the view
- Do not create layers for unsupported layer types
- Support for the
text-translate
paint property - Improve performance for circle styles
v4.2.1
4.2.1
- Smarter text wrapping. We now try to distribute text more evenly across lines
- Take letter spacing into account for calculating line breaks
- Add support for the
text-line-height
layout property - Respect text halo for text anchor
- Fix how we interpret the
text-halo-width
paint property - Respect
tileSize
for TileJSON when specified in the style doc
v4.1.0
v4.1.0 brings a few performance improvements and bug fixes:
- More efficient font caching
- Always stroke polygons to be in line with the style spec
- Stroke polygons without drawing the outline a 2nd time
- Do not cache transparent colors, making hiding features more efficient
- Fix background opacity
- Respect minzoom from TileJSON sources, avoiding underzooming which can lead to loading thousands of tiles
v4.0.0
Breaking changes
Zoom handling
The way how we handle zoom
, minzoom
and maxzoom
throughout the library has been reworked:
- When ol-mapbox-style creates an
ol/View
instance, it will be configured with the zoom level range that mapbox-gl uses. When updating from previous versions, you will notice that the zoom levels of the OpenLayers view will now match those in the Mapbox Style object. Previously OpenLayers zoom levels were higher by 1. - When a Mapbox Style object is configured with a
zoom
, the zoom level will now be interpreted like in mapbox-gl, i.e. you will be zoomed in one level deeper than before the update. minzoom
andmaxzoom
on a Mapbox Style layer were previously determined by the tile size of the underlying source. For raster sources with a tile size of 256, this means thatminzoom
andmaxzoom
are zoomed in one level deeper than before the update. For sources with a tile size of 512, nothing changes.minzoom
andmaxzoom
on a Mapbox Style source now influence theol/tilegrid/TileGrid
that ol-mapbox-style creates for a source in a different way. The resolutions will always match mapbox-gl default zoom levels.minzoom
andmaxzoom
on Mapbox Style layers no longer influences whether theol/layer/Layer
instance is setvisible
at a certain resolution. Instead, the layer'smaxResolution
andminResolution
are set.
Other changes
- Add support for
text-letter-spacing