-
Notifications
You must be signed in to change notification settings - Fork 3
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
fix: Weird shape colors #289
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it means that if there a lot of observations with null measures, we will have a lot of gray shapes on the map ? Why do we draw the shape at all ? Couldn't we just not draw the shape ?
Yes, I think it's a common approach to show shapes with no data as "greyed out" - let's say that somebody configured a map with no relief, and that all cantons are visible at first. But there are also interactive filters enabled and after doing some filtering only one canton has some data, then it would be alone on the map without any context. I just thought that it makes sense, do you think it should be done differently? |
I see, I had not the interactive filter with no data in mind. Shouldn't it be managed by the base layer then ? |
👍
If you filter out some cantons, is it not because you do not want to see them on the map ? Anyway, I think it's good that we have no problems for the moment, the fix is good to me ;) LGTM |
Generally yes, but I think that we aren't able to filter by geo dimensions in interactive filters, so this should only happen when we filter by some other filter and encounter missing data there :) I will have to check the logic on including dimensions in interactive filters, but this is the case for current testing datasets. |
I see, thanks for the explanations 💯 |
@ptbrowne if you think everything looks good, you can approve so the bug shouldn't happen anymore (maybe BAFU has already started testing the maps). I'm going to handle "no data" on legend in a different PR :) |
Oups sorry I had forgotten to review again. |
Closes #281.
Previously, if no observation was mapped to a shape (or its measure value was equal to
null
), anull
was used as a shape fill color. This led to weird bugs - changing this to a light gray color fixes the issue.