hamishgibbs / rt_vis

Interactive RT visualisation
3 stars 0 forks source link

ui improvements #51

Closed hamishgibbs closed 3 years ago

hamishgibbs commented 3 years ago

Various bug fixes.

1.

Added a catch to prevent a hard error for NA values in summary data (only affecting Expected change in daily cases dataset).

This was occurring for estimates from Papua New Guinea with null values handled appropriately for sequential data.

The error stopped the mapping of estimate values (and fill colors) for each polygon - resulting in some polygons with no styling.

Closes #50.

2.

Added headers to legend to indicate the existence of both legend and dataset selection panels. Cycling through the closed - legend - dataset select panels works as before.

Resolved a bug that arose from adding panel titles. Bug was related to the grouping of dataset selection labels in the legend group, rather than as an individual group. This fired two click events when only one should have been triggered. When selecting a new dataset - the legend will now start in closed position and the legend can be viewed by cycling to the legend panel. This is less convenient than selecting a new dataset and immediately viewing the legend but is hopefully alright.

Note: the legend code is currently very tough to maintain. Rather confusing conditional statements are responsible for cycling through panels and everything is housed in the map svg. It would be preferable to have the legend as a standard - styled, absolute positioned, (draggable?) div on top of the map. This would be a valuable future enhancement.

Closes #43.

3.

Added titles to time series legend and "filter date" title to date filter brush. Hopefully makes it more clear how to change the date.

Closes #42.

4.

Reduced the number of date ticks in the time selector so that it will not look as crowded in R Markdown.

Closes #41.

hamishgibbs commented 3 years ago

Hopefully just a bit of work to merge this with RtD3 because of changes to where time series colors are defined (still working on lifting out map colors). And should fix the major issues with the current implementation.