-
Notifications
You must be signed in to change notification settings - Fork 8.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Maps] force vector layer to only contain single feature type #35666
Comments
Pinging @elastic/kibana-gis |
Just chatted things over with @thomasneirynck and it sounds like there is a path forward that retains When we originally discusses the vector style property data structure it looked like the structure below where each feature type had its own copy of each style property. This created the problem of the legend icon since points could have one fill color while polygons could have another.
Instead, we can keep the existing data structure and only have a single copy of each style property.
The idea of styling by feature type is just a UI construct that hides styles that are not applicable to that feature type. Under the covers, there is only one set of properties so points and polygons will always have the same fill color. The Vector style UI would be updated to show a button group with point, line, polygon.
The default selected feature type would be generated by looking at the current feature collection for the layer. If the feature collection only contains points then points would be selected by default. If the feature collection only contains lines then lines would be selected by default. If the feature collection is in neither of those states then polygon would be selected by default. This solves the problem of the legend icon because there can only be one style per property regard less of feature type. The icon type could be a point if the feature collection only contains points, a line if the feature collection only contains lines, and a polygon for an other cases. Since all of the feature properties are the same across the feature types then there are not problems about multiple icons. Thoughts? |
voted down, since @nreese's suggestion #35666 (comment) satisfies a lot of requirements
|
Can we close with #36280 merged? |
Closed by #36280 |
The current vector layer implementation does not enforce vector layers to be homogeneous (all the same feature type - point, line, or polygon).
Not knowing the vector layer feature type impacts the vector style UI. Some style properties are only needed for some feature types. For example, the
Symbol size
property is only used by points andFill color
style property is not used by lines. The problem is going to get worse when enhancements like custom icons get added.Allow vector layer to be heterogeneous and display points, lines, and polygons
The vector style UI problem could be solved by breaking the styling out into three sections, for point, line, and polygon. Users could style each feature type independently.
pros
cons
Force vector layer to only contain single feature type
The vector layer feature type would be a user configured setting that would be set in the layer details panel. The selected type would drive the displayed style properties. Only features that matched the selected feature type would get rendered on the map.
pros
cons
Please vote on this issue
Force vector layer to only contain single feature type
Allow vector layer to be heterogeneous and display points, lines, and polygons
. If you vote thumbs down, please provide suggestions on how to solve the highlighted problems.cc @cchaos @alexfrancoeur
The text was updated successfully, but these errors were encountered: