Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
fix #1399
This is a very first look. But it's not as simple as I thought, because:
In this first implementation, I've created a new type of layer, that creates a CircleMarker for each feature, but doing so we lose all the interactions. I've tried to set a sort of proxy so that a click on the circle will fire a click on the feature, but as this feature is actually not on the map, this does not work naturally.
Also, at this point, the styling is only done once, so editing layer's style will not be updated live in the map.
A few more thinking is needed, mainly to decide how to handle the circle: should it be a "proxy layer" as now, or should we try to transform a feature on the fly (make sure it is a marker of type circle, but as for now our circle are html, not svg…), and in this case, should we magically handle polygons and polylines (taking their center), or only markers (which could be easier, and possibly enough) ?