mit-jp / mit-climate-data-viz

Plotting climate data for the MIT Joint Program on the Science and Policy of Global Change
https://cypressf.shinyapps.io/eppa-dashboard/
0 stars 0 forks source link

Zooming into State view with road/rail/water/etc overlay and using a combined data metric #215

Open azzacasch opened 3 years ago

azzacasch commented 3 years ago

Hey Cypress,

I noticed that when you zoom into a state with a combined data metric (that gives the distribution of the result) and you select any or multiple infrastructure overlay(s) (i.e. road/rail/waterway/etc), the overlays block the distribution plot as well as the shading legend. Seems like a quick fix?

Thanks! Adam

azzacasch commented 3 years ago

Quick follow up - this actually applies even when you are just looking at a single variable. Think it's just a case of placing the shading legend (and the distribution plot) "on top" of everything else.

cypressf commented 3 years ago

Yes, that's true. Nice catch.

cypressf commented 3 years ago

This is non-trivial to solve, because the map and its legend are in one svg "group" and the overlays are in a completely separate group. I need to draw the overlay on top of the map part of the map, but below the legend part of the map, which means I need to effectively insert it in between the two, but since it's in a separate group right now, I cannot. I'll need to restructure the code to get it to work. For now, I'm putting this on the back burner because it's probably not worth the time it would take to fix relative to other bugs and todo items.