When the opacity of a feature is updated, we currently set the paint property for the fill colour of the feature (e.g. circle-color) with an RGBA value, which sets the alpha value to the opacity value. e.g. a red circle feature with 50% opacity would be equal to rgba(255,0,0,0.5).
Although this works, it may be useful to separate the responsibilities of opacity and color paint updates, especially since Mapbox has dedicated opacity paint properties for each of it's layer types (e.g. circle-opacity).
When the opacity of a feature is updated, we currently set the paint property for the fill colour of the feature (e.g.
circle-color
) with an RGBA value, which sets the alpha value to the opacity value. e.g. a red circle feature with 50% opacity would be equal to rgba(255,0,0,0.5).Although this works, it may be useful to separate the responsibilities of opacity and color paint updates, especially since Mapbox has dedicated opacity paint properties for each of it's layer types (e.g.
circle-opacity
).