Samantha Christoff
Samantha Christoff

Reputation: 37

Mapbox and GeoJSON: making some markers invsible

I am having trouble with GeoJSON, is there an attribute for marker that sets the marker opacity to zero? I am using mapbox currently to load the markers and my code for a marker is below:

 "properties":{
        "description":"<img src=\"http://xxx.xxx.xxx/wp-content/uploads/2014/01/map.png\">",
        "id":"marker-hqib0xcd10",
        "marker-color":"#1087bf",
        "marker-size":"medium",
        "marker-symbol":"",
        "title":"Available 2015",
        "category" : "Marker" }

does anyone have any idea if mapbox recognizes an opacity property in geojson?

Upvotes: 1

Views: 316

Answers (1)

tmcw
tmcw

Reputation: 11882

does anyone have any idea if mapbox recognizes an opacity property in geojson?

No, at the moment we don't. If you want to hide markers, you can either not include them in the GeoJSON document, or if you're using L.mapbox.featureLayer/L.mapbox.markerLayer, you can use .setFilter() to show markers selectively.

Upvotes: 1

Related Questions