You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Deprecate MapWidget.cameraOptions in favor of the viewport API — existing usage still works but will be removed in next major version; migrate camera initialization and updates to the viewport API.
Deprecate MapWidget.onTapListener and MapWidget.onLongTapListener in favor of the MapboxMap.addInteraction API — tap/long-tap handlers will be removed in next major version; migrate to the Interactions API for richer feature-aware handling.
Other gesture listeners (scroll, zoom, etc.) are unaffected.
// BeforeMapWidget(
onTapListener: (context) {
print('Tapped at ${context.point}');
},
onLongTapListener: (context) {
print('Long-tapped at ${context.point}');
},
);
// After — on the map itself
mapboxMap.addInteraction(TapInteraction.onMap((context) {
print('Tapped at ${context.point}');
}));
mapboxMap.addInteraction(LongTapInteraction.onMap((context) {
print('Long-tapped at ${context.point}');
}));