Skip to content
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

Enforce the GeoJSON polygon orientation in Vega Maps #122569

Open
jsanz opened this issue Jan 10, 2022 · 2 comments
Open

Enforce the GeoJSON polygon orientation in Vega Maps #122569

jsanz opened this issue Jan 10, 2022 · 2 comments
Labels
Feature:Maps Feature:Vega Vega visualizations impact:medium Addressing this issue will have a medium level of impact on the quality/strength of our product. Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas v8.1.0 v8.2.0

Comments

@jsanz
Copy link
Member

jsanz commented Jan 10, 2022

Vega uses d3-geo to render GeoJSON features into a Map. Unfortunately the convention used by this library is to expect polygon rings to be clockwise (more details about the reasoning here). This convention is not followed by current GeoJSON IETF RFC7946 standard where polygons are expected to be counterclockwise:

A linear ring MUST follow the right-hand rule with respect to the area it bounds, i.e., exterior rings are counterclockwise, and holes are clockwise.

On the other hand, EMS is nowadays serving some datasets on different conventions, making them to work inconsistently in Kibana Vega Maps: example issue in EMS File Service: elastic/ems-file-service#231

The agreement in the aforementioned issue is to make EMS to follow the industry standard and make in 8.1 all datasets to follow RFC7946. If we don't do anything that would make none of them to work in Kibana Vega, so we need to implement a mechanism to "rewind" the data when being loaded, maybe using this library.

@jsanz jsanz added Feature:Vega Vega visualizations [Deprecated-Use Team:Presentation]Team:Geo Former Team Label for Geo Team. Now use Team:Presentation labels Jan 10, 2022
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-gis (Team:Geo)

@jb1b84 jb1b84 added Feature:Maps Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas and removed [Deprecated-Use Team:Presentation]Team:Geo Former Team Label for Geo Team. Now use Team:Presentation labels Nov 3, 2022
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-presentation (Team:Presentation)

@nreese nreese added the impact:medium Addressing this issue will have a medium level of impact on the quality/strength of our product. label Feb 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature:Maps Feature:Vega Vega visualizations impact:medium Addressing this issue will have a medium level of impact on the quality/strength of our product. Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas v8.1.0 v8.2.0
Projects
None yet
Development

No branches or pull requests

5 participants