Closed clhenrick closed 7 years ago
One hang up: if the app's default date range (1 month) is passed to the chart view, then period one in the chart view will break. This is due to the chart view enforcing that a time period is at least two months.
To prevent this from happening the app would have to recognize that the period 1 start and end date are the same, then set the start date one month prior, but this seems like an edge case and most users would probably want to look at more than 1 month of data in the chart view.
Alternatively if the start and end date are the same then it could just use the default start and end dates, or try setting the start date to one year prior to the end date.
cc @danrademacher
I would say the optimal behavior is:
And quite acceptable would be:
Latter especially OK because use case of a single month selected will most often be when a user has not made any changes to default timing on the map. So loading defaults on chart makes sense
Similar to the "chart view" app, a nav menu to the right of the title
should contain:
"map" should always be set to active; "about" should work as it does now (modal); compare, trend, and rank all link to the respective view in the chart app.
Query params should carry over from the map view to the chart view so that any filters such as start and end date would be used to set similar filters in the chart view app.
Relates to https://github.com/GreenInfo-Network/nyc-crash-mapper-chart-view/issues/48