V10 iOS issue with onPress for multiple touchable layers #2191
Unanswered
FrancoisVA
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi, when rendering multiple shapeSources on top of each other (using url as source) the onPress for shapeSources rendered at the top (like roads) fail. For example if I have a polygon fill layer rendered and a road going over it, tapping on the road only triggers the onPress for the fillLayer beneath. This didn't happen when using the old mapbox-gl package, and is only an issue on iOS, it also looks like it isn't an issue if the top layers source is
shape={GeoJson}
, it's only an issue if the source isurl={path}
. If the onPress for the layer beneath is disabled the issue doesn't persist.If tried using the onReponder... properties available on ShapeSource, but could not trigger any of those events.
I created an issue, but was unable to provide a sufficient repro, as I do not have the skills to create made up geoJSON objects and store them in storage. I closed the issue due to inactivity after adding steps to reproduce without code snippet.
What is the best way for me to proceed with this issue?
Is there anyone that can help me to reproduce this issue? If you are rendering a shape source with a line layer over a shapeSource with a fill layer (both from a URI souce), you can simply add an onPress to both to see if you can trigger onPress for the line layer.
The images below shows the desired outcome (being able to select road layer) working on android.
Beta Was this translation helpful? Give feedback.
All reactions