inasafe / inasafe-fba

Next generation of InaSAFE that includes support for forecast based action
MIT License
1 stars 8 forks source link

Incorrect legend shown when roads tab is active #36

Closed NyakudyaA closed 4 years ago

NyakudyaA commented 4 years ago

Problem

When I have the road tab active and zoom to the district level I get the building legend.

Peek 2020-01-19 12-52

Solution

Show the legend of the exposed road at that time.

anitanh commented 4 years ago

Hi @NyakudyaA since the layer on the map does not change regardless which tab we choose so I've added the exposed road legend and let it be shown regardless which tab is active

NyakudyaA commented 4 years ago

Hi, @ann26 thanks for this. I see that once the legend are loaded on the map there is no way to close them. Is it possible that we could have the following interaction

NB A bonus would be to have a legend icon where you can individually activate a legend per choose but still render them at the correct scale and position

your thoughts @ann26

anitanh commented 4 years ago

hi @NyakudyaA

Add a legend icon which controls visibility either on or off like below

yeah we can, i'll add it

Maintain the interaction that legends become visible only at that particular scale and are placed the same way you have them.

how do we define the scale?

Add a close icon for each legend but how would they become visible again. Maybe add a minimize legend which will collapse it into a drawer.

you can click on each legend they'll shrink and become an icon

Or maybe we can split the legends into two classes and have an icon for each class hazard legends or vulnerability legends.

we already have this, just the default view is to show the legend, but I can change it to have default view as icon I think, I'll check

NyakudyaA commented 4 years ago

hi @NyakudyaA

Add a legend icon which controls visibility either on or off like below

yeah we can, i'll add it

Cool.

Maintain the interaction that legends become visible only at that particular scale and are placed the same way you have them.

how do we define the scale?

Currently, the forecast legend is visible when you click on a forecast. The vulnerability legends are visible when you drill down ie at district level. This interaction is fine as it is.

Add a close icon for each legend but how would they become visible again. Maybe add a minimize legend which will collapse it into a drawer.

you can click on each legend they'll shrink and become an icon You can choose which option you think makes it better.

Or maybe we can split the legends into two classes and have an icon for each class hazard legends or vulnerability legends.

we already have this, just the default view is to show the legend, but I can change it to have default view as icon I think, I'll check

Thanks @ann26