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
Im working on a project where I need a "scroll zoom" like functionality.
So a way to zoom without changing the center of the camera. Currently if you pinch to zoom, it is possible to pan the map.
Currently the web version supports this. But i haven't found a nice way to do this with the RN variant.
The "hack" i use now is as follows:
on onRegionIsChanging the camera coordinates are resetted by Camera.moveTo([original.long, original.lat], 0)
It's not 100% smooth, small jumps are inevitable unfortunately...
I tried multiple other things like programatically set the zoom level based on Gesture events, but it didnt really work out.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hi people!
Im working on a project where I need a "scroll zoom" like functionality.
So a way to zoom without changing the center of the camera. Currently if you pinch to zoom, it is possible to pan the map.
Currently the web version supports this. But i haven't found a nice way to do this with the RN variant.
The "hack" i use now is as follows:
on
onRegionIsChanging
the camera coordinates are resetted byCamera.moveTo([original.long, original.lat], 0)
It's not 100% smooth, small jumps are inevitable unfortunately...
I tried multiple other things like programatically set the zoom level based on Gesture events, but it didnt really work out.
Also noticed that recently a similar options has been added to react-native-map . react-native-maps/react-native-maps#3784
Does someone already found a nice way to do this? Or can we maybe add a functionality like this?
Thanks in advance!
Beta Was this translation helpful? Give feedback.
All reactions