ui-mapbox icon indicating copy to clipboard operation
ui-mapbox copied to clipboard

Marker onTap event is not fired since 6.2.20

Open foxgreek opened this issue 1 year ago • 11 comments

After updating to 6.2.20, the onTap event of markers on the map is not fired anymore. Going down to 6.2.19 solved the problem.

foxgreek avatar Sep 08 '23 07:09 foxgreek

@mohammadrafigh seems your change broke other things. Can you look at it?

farfromrefug avatar Sep 08 '23 13:09 farfromrefug

I experienced the same thing as well.

paulmlilo avatar Sep 27 '23 15:09 paulmlilo

@farfromrefug Well, It seems we need to check if there is an onTap listener available then we should bypass default listener. But if there is no onTap listener, then we can allow custom tap listeners. This way there is no possibility to have both. I will take a look to see if we can have both behaviors at the same time. So for now the solution for who uses onTap listener is to use 6.2.19. I will send a PR soon, hope this time it fixes everything and gets merged :)).

mohammadrafigh avatar Sep 27 '23 17:09 mohammadrafigh

@mohammadrafigh it is still broken in 6.2.27

foxgreek avatar Jul 12 '24 14:07 foxgreek

@foxgreek yes this repo is looking for maintainers. I personally. dont use mapbox anymore. If you want to have a go at it please do

farfromrefug avatar Jul 13 '24 11:07 farfromrefug

Hi Guys, I'm not able to reproduce your problem, It's working here. Can you provide a demo project so I can take a look?

mohammadrafigh avatar Jul 26 '24 18:07 mohammadrafigh

It is not working on iOS

kakha13 avatar Sep 05 '24 16:09 kakha13

It's working on my projects. I'm not able to fix it unless someone provides a demo project that reproduces the problem. Otherwise I consider that it works and something might be wrong with your usage.

mohammadrafigh avatar Sep 05 '24 20:09 mohammadrafigh

It's working on my projects. I'm not able to fix it unless someone provides a demo project that reproduces the problem. Otherwise I consider that it works and something might be wrong with your usage.

Hey thanks, here is demo mapbox-marker-demo

kakha13 avatar Sep 06 '24 12:09 kakha13

Good I will check this out after the weekend. Thank you

On Fri, Sep 6, 2024, 3:57 PM Kakha @.***> wrote:

It's working on my projects. I'm not able to fix it unless someone provides a demo project that reproduces the problem. Otherwise I consider that it works and something might be wrong with your usage.

Hey thanks, here is demo mapbox-marker-demo https://github.com/kakha13/mapbox-marker-demo

— Reply to this email directly, view it on GitHub https://github.com/nativescript-community/ui-mapbox/issues/102#issuecomment-2333943842, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABTM4ZAF52THJFH5X3Z7V6TZVGNSNAVCNFSM6AAAAABKZCV2XWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGMZTHE2DGOBUGI . You are receiving this because you were mentioned.Message ID: @.***>

mohammadrafigh avatar Sep 06 '24 18:09 mohammadrafigh

I compared the current version with 6.2.19 and found this difference. inside index.ios.js function: setOnMapClickListener

 if (recognizer instanceof UITapGestureRecognizer) {
      recognizer.addTargetAction(theMap['mapTapHandler'], 'tap');
      break;
  }

Change:

if (recognizer instanceof UITapGestureRecognizer) {
    tapGestureRecognizer.requireGestureRecognizerToFail(recognizer);
}

Tap on marker working now.

kakha13 avatar Sep 20 '24 19:09 kakha13