[Bug]: MarkerView and iOS (Gestures won't work on iOS with 20 MarkerViews)
Mapbox Implementation
Mapbox
Mapbox Version
11.4.1 and up to 11.9.0
React Native Version
0.76.5
Platform
iOS
@rnmapbox/maps version
10.1.33
Standalone component to reproduce
Observed behavior and steps to reproduce
I am running into this issue where I have a bunch of MarkerViews (roughly 20-30). As soon as I render these, I'm unable to pan or zoom the map anymore. It would work at some points, but mostly won't work on the map
I don't know if it is related to hit boxes or anything else, but if I zoom out to a different location where I don't have markers anymore, then it works.
Is there any way I can debug and publish more report on whats going on?
And it works perfectly fine on Android, but not on iOS
I can try to recreate this for the demo, but I fear it might not be reproducible.
react-native": "^0.76.5",
"expo": "~52.0.20",
"@rnmapbox/maps": "^10.1.33",
app.config
RNMapboxMapsVersion: "11.9.0"
Expected behavior
Panning and Zooming Gestures should work
Notes / preliminary analysis
- Works fine on Android but not on iOS
- If I render null inside MarkerView then it works fine
- Doesn't matter what is inside MarkerView (Text/View etc and not does its width/height)
Additional links and references
console.log(1);
Additional Info: It works fine when I have 1 MarkerViews and starts breaking with 8.
Stumbled upon this, wondering if it has anything to do.
https://github.com/rnmapbox/maps/blob/fa80ae549a65d8473cd731f79f57a65fcc9c9fbc/src/components/MarkerView.tsx#L102-L107
Same issue here!
Images may overlap the map view. Try debugging the images used for markers (e.g., add a backgroundColor to the image wrapper)
I've tried the above already. For some reason, even if I have a small image (e.g. 50x50px) it renders a seemingly much larger invisible layer, and they all start to overlap each other. Which stops the map interactions from working, so no pinch and zoom, rotation, touches etc.
Same problem here.
@atif089 unrelated to this issue, but I see you got images working on react native 0.76.5. There's an outstanding issue where images are not showing. Did you do anything special to get those images to show?
https://github.com/rnmapbox/maps/issues/3695