ProjectSidewalk / SidewalkWebpage

Project Sidewalk web page
http://projectsidewalk.org
MIT License
80 stars 23 forks source link

Admin neighborhood completion histogram should have variable height #3565

Open misaugstad opened 2 weeks ago

misaugstad commented 2 weeks ago
Brief description of problem/feature

The "Coverage Percentage by Neighborhood" graph on the Admin page looks nice for some cities (like Seattle). Anything with around 50 open neighborhoods looks decent. But we have a fixed size for the chart. If there are only a couple of cities, or if there are many cities, it looks pretty bad (or is unreadable).

Screenshot from 2024-06-11 18-19-18 Screenshot from 2024-06-11 18-18-18

Expected behavior

This graph should change height depending on the number of neighborhoods that we are trying to show on the chart.

Across our deployments, we have anywhere from 1 to 1,049 neighborhoods in a given city. It would be nice for this chart to be legible and nice looking for any such deployment. I could see there being some sort of a cap; I'm not sure that we can show 1k neighborhoods in this sort of format easily. But we should see how close we can get without having to do a big overhaul!

It should be easy enough to actually set the height dynamically; we're choosing the height in JavaScript in a place where we already know the number of neighborhoods. It's just about playing around with a formula that will look nice across a wide range of deployments.

@nschung28 I'll have you take this on for now! You can create synthetic data in JS to make it easy to test the look for varying numbers of neighborhoods.