Mapbox-gl-js: Icon and text overlap conflict

Created on 7 Mar 2018  路  1Comment  路  Source: mapbox/mapbox-gl-js

mapbox-gl-js version

I have encountered what I think is a bug. I have several icons on display and each icon has a text-field under it. At any given zoom level, I would like to have the icons always show, but the text only show when there is no overlap.

Steps to Trigger Behavior

  1. Have several markers on a map with custom icon + text-field
  2. set "icon-allow-overlap": true,and "text-allow-overlap": false,
  3. animate the markers by updating the Source data

Expected Behavior

The icons should always be there, and the text should only be displayed when there is no overlap

Actual Behavior

The icons disappear with the text when there is an overlap. The behavior should be separate.

Most helpful comment

Hi @PhaelIshall, thanks for using Mapbox. Setting "text-optional": true should produce the desired behavior in this case.

>All comments

Hi @PhaelIshall, thanks for using Mapbox. Setting "text-optional": true should produce the desired behavior in this case.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

PBrockmann picture PBrockmann  路  3Comments

rasagy picture rasagy  路  3Comments

Scarysize picture Scarysize  路  3Comments

yoursweater picture yoursweater  路  3Comments

jfirebaugh picture jfirebaugh  路  3Comments