[x] "Save all activities" button is transitioned into dash component, and a "save selected activities" button is added
[x] Include a checkmark input at the end of each row
[x] exists
[x] grayed out if the activity already exists in the db
Row shows conditional format if activity already exists in db
(moved to #39) controls whether the corresponding activity is saved by the batch operation.
[x] Add an inputgroup of checkboxes specifying how the batch of activities should be added:
"Add activities with overlapping times?" -> (if an activity has a distinct strava id from a saved activity, but its start and end times overlap with those of the saved activity, it's likely a duplicate).
For now, pinned checked. Avoiding overlaps across strava accts is sophisticated and it doesn't make sense to add it early.
"Save walks and hikes as runs?" -> otherwise, these activities are ignored
For now, pinned checked. The default behavior is walks getting treated the same.
(later) "Save bike rides?" -> requires completely different metrics and stuff; tempting one day though.
For now, pinned unchecked. Now I just need the backend to actually avoid saving bike rides.
[x] Format values in datatable appropriately:
Date (datetime.datetime) -> Sat, 12/31/2022 HH:MM:SS
Time (datetime.timedelta) -> H:MM:SS
Distance (int) -> X.XX mi
Elevation (int) -> X,XXX ft
[x] Make activity titles hyperlinks to the strava activity detail
:warning: I decided to leave out filtering for now, because it's just text-based (eg using '<', 'contains', etc) and also because it doesn't support upper and lower bounds for activities.
:bulb: I think it would be better to supply additional components with callbacks to edit the data returned, than to use or modify the built-in data filtration.
Sport by activity type
Date by (from, to). Either endpoint is optional.
Title by matching text? Search function?
Time, Distance, Elevation by (low, high), both endpoints optional.
Sort
:warning: as a rule, these only work on a per-page basis because of limitations with Strava's API: I cannot request results in a different sort order. A workaround would be to adjust the "per page" attribute to be super large, say 100k, ...wait for those results to load... , and then sort those results as desired.
Sport, Title alphabetically
Date by (newest first, oldest first)
Time by (shortest first, longest first)
Distance by (shortest first, longest first)
Elevation by (fewest first, most first)
Pagination
Like filter + sort, only load the data requested by the current datatable configuration. Don't load all the activities each time.
Provide a total number of pages, if possible.
(Not gonna do this for now, because there is no straightforward implementation and I don't see a ton of value here).
[x] Make sure that godawful font is changed to match the stylesheets
[x] Make the table fit within the page width. Maybe that means a different strategy for low screen widths. Probably need to ensure the Title column wraps, as it can get long.
grayed out if the activity already exists in the dbRow shows conditional format if activity already exists in dbSat, 12/31/2022 HH:MM:SS
H:MM:SS