The map classes expected the data to be in a certain order in an array; since we were reusing the same arrays from the tables, when I changed those to include cash bail cases it changed the order
To better future-proof this I changed the BailRateMap and BailRaceMap implementations to take an object and the key to select, which also allows us to use the same map data object BAIL_RATE_MAP_DATA for all maps
I also did this for the averages as they were in the wrong order
Old
New
Increase title font size to 18px
Increase table header font size to 13px
Switch visualizations in tables to use em rather than px
This made it easier to fix the alignment of the dots
Other small style fixes in the viz: align dotted average lines properly with the top and bottom of the table; move dots to in front of the average lines; and align headers properly
Old
New
Mobile sizing fix: make county name columns narrower on mobile to avoid overflow/horizontal scrolling
Mobile sizing fix: prevent horizontal scrolling and overlap on very small phones for average bail amount/non-posting rate chart; note that this looks a little different in dev vs. on the staging site because of the additional containers and whatnot but it should still work because the fix for the horizontal scrolling was to add a small margin to the right side of the graph on mobile
Old
New
Mobile sizing fix: make sure the bail type chart legend fits without overflow on small phones (note both this and the above change requiring reducing the text size to 11px, which is something we're doing elsewhere on the site)
Changes
BailRateMap
andBailRaceMap
implementations to take an object and the key to select, which also allows us to use the same map data objectBAIL_RATE_MAP_DATA
for all maps