maps icon indicating copy to clipboard operation
maps copied to clipboard

No way to render callouts

Open SethTyemill opened this issue 7 years ago • 7 comments

Describe the bug I am unable to find any way to get callouts to render WITHOUT using point annotation. I have tried with annotations and symbol layer but am having no luck.

To Reproduce Try to make a callout without using point annotation.

Expected behavior There would be some way to implement this in this library.

Versions (please complete the following information):

  • Platfrom: Android, iOS
  • SDK Version [e.g. 22]
  • React Native Version: Current

Additional context I would really like to use this library but as far as I see there is no way to render callouts anymore unless you use a deprecated component.

SethTyemill avatar Jul 29 '19 17:07 SethTyemill

Is there any comment on this issue? I am having the same problem within my project.

markspereira avatar Sep 03 '19 17:09 markspereira

Same issue here.

gongmingqm10 avatar Sep 19 '19 03:09 gongmingqm10

We just reworked pointAnnotation. It’s no longer deprecated.

Please note that point annotations are not as scalable as shapesources.

If you plan to add thousands of points, you’ll want to use shape source for all points and point annotation with a callout for the selected point. There are a few discussions around here with tips about this.

kristfal avatar Sep 19 '19 19:09 kristfal

@kristfal All you said makes sense, but the documentation still says PointAnnotations are "legacy, soon to be deprecated". I was also avoiding using PointAnnotations due to that, and only by stumbling on this issue did I find I could actually use them.

fvieira avatar Jan 15 '20 19:01 fvieira

@fvieira Did you notice this issue too https://github.com/react-native-mapbox-gl/maps/issues/532

I tried using the point annotation with callout, though it seems broken.

lrpinto avatar Jan 19 '20 01:01 lrpinto

@lrpinto Actually, I didn't care much for the Callout component, I just wrote my own component using normal Views. All I needed was a way of attaching my component to a coordinate, and PointAnnotation did the job.

fvieira avatar Jan 19 '20 17:01 fvieira

@fvieira That is a good idea. Ty.

lrpinto avatar Jan 20 '20 00:01 lrpinto