v11.13.0-beta.1
Pre-release
Pre-release
·
61 commits
to main
since this release
Changes
Breaking changes ⚠️
- The experimental style
MapStyle.standardExperimental
is removed. UseMapStyle.standard
instead. PointAnnotation.iconImageCrossFade
has been deprecated and setting value to it will not have any impact. UsePointAnnotationManager.iconImageCrossFadeTransition
instead.
Features ✨ and improvements 🏁
- The Interactions and Featuresets API is promoted from experimental. The new API allows you to add interaction handlers to layers, Standard Style featuresets (POI, Buildings and Place Labels), and the map itself in the consistent way. You can control the propagation of events, tappable area, and the order of event handling.
- Methods
GestureManager.onMapTap
,GestureManager.onMapLongPress
,GestureManager.onLayerTap
,GestureManager.onLayerLongPress
and their SwiftUI counterparts are deprecated. UseTapInteraction
andLongPressInteraction
instead.
- Methods
// Before (SwiftUI)
Map()
.onMapTapGesture { context in
// Handle tap on map
}
.onLayerLongPressGesture("a-layer-id") { feature, context in
// Handle press on a layer
return true
}
// After (SwiftUI)
Map {
TapInteraction { feature in
// Handle tap on map
return true
}
LongPressInteraction(.layer("a-layer-id")) { feature, context in
// Handle press on a layer
return true
}
// Bonus: If you use Standard style, new API allows to handle tap on POI, Buildings and Place Labels
TapInteraction(.standardPoi) { poi, feature in
print("Tap on \(poi.name)")
return true
}
}
// Before (UIKit)
mapView.gestures.onMapTap.observe { context in
// Handle Tap on Map
}.store(in: &cancelables)
mapView.gestures.onLayerLongPress("a-layer-id") { feature, context in
// Handle Long press
return true
}
// After (UIKit)
mapView.mapboxMap.addInteraction(TapInteraction { context in
// Handle tap on map
return true
})
mapView.mapboxMap.addInteraction(LongPressInteraction(.layer("a-layer-id")) { feature, context in
// Handle long press on a layer
return true
})
// Bonus: If you use Standard style, new API allows to handle tap on POI, Buildings and Place Labels
mapView.mapboxMap.addInteraction(TapInteraction(.standardPoi) { poi, feature in
print("Tap on poi \(poi.name)")
return true
})
- Add new
VectorSource.promoteId2
andGeoJSONSource.promoteId2
. DeprecateVectorSource.promoteId
andGeoJSONSource.promoteId
. The newer version support the expression variant ofpromoteId
, which can be used to dynamically nominate IDs to the features. - Expose new experimental properties:
CircleLayer.circleElevationReference
,FillLayer.fillConstructBridgeGuardRail
,FillLayer.fillBridgeGuardRailColor
,FillLayer.fillTunnelStructureColor
. - Expose new
showLandmarkIcons
property inMapStyle.standard
. - New example for elevated spiral line using the experimental API
LineLayer/linezOffset
.
Update MapboxCoreMaps to 11.13.0-beta.1
:
Features ✨ and improvements 🏁
- Update Dynamic View Annotations to avoid overlapping symbol layers
StyleManager.getStyleImage()
can now retrieve vector icons- New
at-interpolated
expression added and separated from existingat
expression. - Tile pack v2 format will now be used by default for endpoints that support it
- Add support for shadows on elevated symbols
- Add
screenShape
MapOption for better culling on non-rectangular displays - Support color-use-theme for rain and snow
- Elevated bridge rail guard style support for color, emissive strength and enable/disable rail guard
Bug fixes 🐞
- Fix elevated lines rendering regression. Original report here.
- Fix incorrect placement for symbols with symbol-z-elevate on Globe projection
- Elevated symbol heights now change as smooth as building heights
- Fix map flickering caused by the fill-extrusion pan tiles and missing stencil in 3D layers
- Fix unstable placement for elevated symbols
- Fix icon rasterization issue with luminance mask contexts
- Fix
clipPath
and mask rendering for vector icon rasterization - Fix symbol order when
symbol-z-elevate
istrue
- Fix issue that
promoteId
content is missing after vector source serialization - Fix semi-transparent landmark icons
- Return
null
for config expression if requested config option is missing - Fix dotted lines on tile borders
- Fix pattern not found error when using imports
- Fix line layer not rendering when using
line-pattern
inside an imported style - Fix flickering of elevated HD roads
- Fix ground effect gradient not working with multiple polygons
- Fix invisible line when interpolating
line-width
from 0 to 1 usingline-progress
- Fix temporary allocations in getDashPatternTexture
💫️ Optimizations and other updates
- Remove confusing error message when events are disabled and not sent
- Tiled model translation support for 3D models
- Flood light ground effect now shown on top of 3D objects
- Support mapbox:// tile URLs without version and tiles
- Reduce excessive allocations on the tile pyramid nodes re-creation
- Avoid re-allocations per frame on
tileclippingMasksID
s - Use LayerUID uint16_t instead of std::string for map keys
- Add simple bounds check to avoid crash during centroid computation
Update MapboxCommon to 24.13.0-beta.1
:
Features ✨ and improvements 🏁
- Support radius individually per point geofence geometry
Bug fixes 🐞
- Fix possible offline cache migration issues
- Fix iOS 18.4-18.5 network issues
- Fix possible crashes in HTTP requests processing in case of invalid UTF-8 headers
Dependency requirements:
- Compatible version of Xcode:
16.2