You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If this is something more people want, I could see a "styleFeature" function being added to Draw that would allow a user to set a features style. Internally this would add a style layer to the mapbox-gl-js that references that id of the feature.
draw.styleFeature('id', { style json })
The style json would be a paired down version of what is in the default styles, noting that filter, id and source would all need to be left off so that Draw could set them.
draw.styleFeature('id', null)
Would remove the style from the map as would draw.deleteFeature('id').
This issue is for discussing adding a new styleFeature() funciton to future versions of the library. For workarounds in the current version, see #833 (comment).
The text was updated successfully, but these errors were encountered:
From #833 (comment)
This issue is for discussing adding a new
styleFeature()
funciton to future versions of the library. For workarounds in the current version, see #833 (comment).The text was updated successfully, but these errors were encountered: