geo-activity-playground 0.45.0__py3-none-any.whl → 1.1.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- geo_activity_playground/alembic/versions/dc8073871da7_add_plotspec_group_by.py +28 -0
- geo_activity_playground/core/config.py +1 -0
- geo_activity_playground/core/datamodel.py +12 -0
- geo_activity_playground/core/export.py +129 -0
- geo_activity_playground/core/meta_search.py +1 -1
- geo_activity_playground/core/parametric_plot.py +101 -47
- geo_activity_playground/webui/app.py +10 -1
- geo_activity_playground/webui/authenticator.py +4 -2
- geo_activity_playground/webui/blueprints/activity_blueprint.py +11 -10
- geo_activity_playground/webui/blueprints/auth_blueprint.py +6 -2
- geo_activity_playground/webui/blueprints/bubble_chart_blueprint.py +2 -1
- geo_activity_playground/webui/blueprints/calendar_blueprint.py +3 -2
- geo_activity_playground/webui/blueprints/eddington_blueprints.py +3 -2
- geo_activity_playground/webui/blueprints/entry_views.py +11 -11
- geo_activity_playground/webui/blueprints/equipment_blueprint.py +2 -1
- geo_activity_playground/webui/blueprints/explorer_blueprint.py +343 -197
- geo_activity_playground/webui/blueprints/export_blueprint.py +31 -0
- geo_activity_playground/webui/blueprints/hall_of_fame_blueprint.py +79 -0
- geo_activity_playground/webui/blueprints/plot_builder_blueprint.py +38 -19
- geo_activity_playground/webui/blueprints/summary_blueprint.py +114 -240
- geo_activity_playground/webui/blueprints/upload_blueprint.py +9 -0
- geo_activity_playground/webui/columns.py +40 -7
- geo_activity_playground/webui/static/{browserconfig.xml → favicons/browserconfig.xml} +1 -1
- geo_activity_playground/webui/static/{site.webmanifest → favicons/site.webmanifest} +2 -2
- geo_activity_playground/webui/static/server-side-explorer.js +60 -0
- geo_activity_playground/webui/templates/activity/name.html.j2 +4 -4
- geo_activity_playground/webui/templates/activity/show.html.j2 +8 -8
- geo_activity_playground/webui/templates/auth/index.html.j2 +1 -0
- geo_activity_playground/webui/templates/eddington/distance.html.j2 +3 -3
- geo_activity_playground/webui/templates/eddington/elevation_gain.html.j2 +3 -3
- geo_activity_playground/webui/templates/elevation_eddington/index.html.j2 +3 -3
- geo_activity_playground/webui/templates/equipment/index.html.j2 +1 -1
- geo_activity_playground/webui/templates/explorer/server-side.html.j2 +42 -36
- geo_activity_playground/webui/templates/export/index.html.j2 +39 -0
- geo_activity_playground/webui/templates/hall_of_fame/index.html.j2 +58 -0
- geo_activity_playground/webui/templates/home.html.j2 +1 -4
- geo_activity_playground/webui/templates/page.html.j2 +26 -43
- geo_activity_playground/webui/templates/plot-macros.html.j2 +72 -0
- geo_activity_playground/webui/templates/plot_builder/edit.html.j2 +12 -7
- geo_activity_playground/webui/templates/plot_builder/import-spec.html.j2 +24 -0
- geo_activity_playground/webui/templates/plot_builder/index.html.j2 +5 -0
- geo_activity_playground/webui/templates/summary/index.html.j2 +23 -230
- geo_activity_playground/webui/templates/summary/vega-chart.html.j2 +3 -0
- {geo_activity_playground-0.45.0.dist-info → geo_activity_playground-1.1.0.dist-info}/METADATA +2 -1
- {geo_activity_playground-0.45.0.dist-info → geo_activity_playground-1.1.0.dist-info}/RECORD +74 -65
- geo_activity_playground/webui/templates/explorer/index.html.j2 +0 -148
- /geo_activity_playground/webui/static/{bootstrap-dark-mode.js → bootstrap/bootstrap-dark-mode.js} +0 -0
- /geo_activity_playground/webui/static/{bootstrap.bundle.min.js → bootstrap/bootstrap.bundle.min.js} +0 -0
- /geo_activity_playground/webui/static/{bootstrap.min.css → bootstrap/bootstrap.min.css} +0 -0
- /geo_activity_playground/webui/static/{android-chrome-192x192.png → favicons/android-chrome-192x192.png} +0 -0
- /geo_activity_playground/webui/static/{android-chrome-512x512.png → favicons/android-chrome-512x512.png} +0 -0
- /geo_activity_playground/webui/static/{apple-touch-icon.png → favicons/apple-touch-icon.png} +0 -0
- /geo_activity_playground/webui/static/{favicon-16x16.png → favicons/favicon-16x16.png} +0 -0
- /geo_activity_playground/webui/static/{favicon-32x32.png → favicons/favicon-32x32.png} +0 -0
- /geo_activity_playground/webui/static/{favicon-48x48.png → favicons/favicon-48x48.png} +0 -0
- /geo_activity_playground/webui/static/{favicon.ico → favicons/favicon.ico} +0 -0
- /geo_activity_playground/webui/static/{favicon.svg → favicons/favicon.svg} +0 -0
- /geo_activity_playground/webui/static/{mstile-150x150.png → favicons/mstile-150x150.png} +0 -0
- /geo_activity_playground/webui/static/{web-app-manifest-192x192.png → favicons/web-app-manifest-192x192.png} +0 -0
- /geo_activity_playground/webui/static/{web-app-manifest-512x512.png → favicons/web-app-manifest-512x512.png} +0 -0
- /geo_activity_playground/webui/static/{Leaflet.fullscreen.min.js → leaflet/Leaflet.fullscreen.min.js} +0 -0
- /geo_activity_playground/webui/static/{MarkerCluster.Default.css → leaflet/MarkerCluster.Default.css} +0 -0
- /geo_activity_playground/webui/static/{MarkerCluster.css → leaflet/MarkerCluster.css} +0 -0
- /geo_activity_playground/webui/static/{fullscreen.png → leaflet/fullscreen.png} +0 -0
- /geo_activity_playground/webui/static/{fullscreen@2x.png → leaflet/fullscreen@2x.png} +0 -0
- /geo_activity_playground/webui/static/{leaflet.css → leaflet/leaflet.css} +0 -0
- /geo_activity_playground/webui/static/{leaflet.fullscreen.css → leaflet/leaflet.fullscreen.css} +0 -0
- /geo_activity_playground/webui/static/{leaflet.js → leaflet/leaflet.js} +0 -0
- /geo_activity_playground/webui/static/{leaflet.markercluster.js → leaflet/leaflet.markercluster.js} +0 -0
- /geo_activity_playground/webui/static/{vega-embed@6 → vega/vega-embed@6.js} +0 -0
- /geo_activity_playground/webui/static/{vega-lite@4 → vega/vega-lite@4.js} +0 -0
- /geo_activity_playground/webui/static/{vega@5 → vega/vega@5.js} +0 -0
- {geo_activity_playground-0.45.0.dist-info → geo_activity_playground-1.1.0.dist-info}/LICENSE +0 -0
- {geo_activity_playground-0.45.0.dist-info → geo_activity_playground-1.1.0.dist-info}/WHEEL +0 -0
- {geo_activity_playground-0.45.0.dist-info → geo_activity_playground-1.1.0.dist-info}/entry_points.txt +0 -0
@@ -1,5 +1,6 @@
|
|
1
1
|
import collections
|
2
2
|
import datetime
|
3
|
+
from typing import Any
|
3
4
|
|
4
5
|
import altair as alt
|
5
6
|
import flask
|
@@ -7,6 +8,7 @@ import pandas as pd
|
|
7
8
|
import sqlalchemy
|
8
9
|
from flask import render_template
|
9
10
|
from flask import Response
|
11
|
+
from flask.typing import ResponseReturnValue
|
10
12
|
|
11
13
|
from ...core.activities import ActivityRepository
|
12
14
|
from ...core.activities import make_geojson_from_time_series
|
@@ -16,6 +18,7 @@ from ...core.datamodel import DB
|
|
16
18
|
from ..columns import column_distance
|
17
19
|
from ..columns import column_elevation_gain
|
18
20
|
from ..columns import ColumnDescription
|
21
|
+
from ..columns import META_COLUMNS
|
19
22
|
from ..plot_util import make_kind_scale
|
20
23
|
|
21
24
|
|
@@ -23,19 +26,16 @@ def register_entry_views(
|
|
23
26
|
app: flask.Flask, repository: ActivityRepository, config: Config
|
24
27
|
) -> None:
|
25
28
|
@app.route("/")
|
26
|
-
def index() ->
|
27
|
-
context = {"latest_activities": []}
|
29
|
+
def index() -> ResponseReturnValue:
|
30
|
+
context: dict[str, Any] = {"latest_activities": []}
|
31
|
+
df = repository.meta
|
28
32
|
|
29
33
|
if len(repository):
|
30
|
-
kind_scale = make_kind_scale(
|
31
|
-
context["
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
if config.reliable_elevation_measurements:
|
36
|
-
context["elevation_gain_last_30_days_plot"] = _last_30_days_meta_plot(
|
37
|
-
repository.meta, kind_scale, column_elevation_gain
|
38
|
-
)
|
34
|
+
kind_scale = make_kind_scale(df, config)
|
35
|
+
context["last_30_days_plot"] = {
|
36
|
+
column.display_name: _last_30_days_meta_plot(df, kind_scale, column)
|
37
|
+
for column in META_COLUMNS
|
38
|
+
}
|
39
39
|
|
40
40
|
context["latest_activities"] = collections.defaultdict(list)
|
41
41
|
for activity in DB.session.scalars(
|
@@ -2,6 +2,7 @@ import altair as alt
|
|
2
2
|
import pandas as pd
|
3
3
|
from flask import Blueprint
|
4
4
|
from flask import render_template
|
5
|
+
from flask.typing import ResponseReturnValue
|
5
6
|
|
6
7
|
from ...core.activities import ActivityRepository
|
7
8
|
from ...core.config import Config
|
@@ -15,7 +16,7 @@ def make_equipment_blueprint(
|
|
15
16
|
blueprint = Blueprint("equipment", __name__, template_folder="templates")
|
16
17
|
|
17
18
|
@blueprint.route("/")
|
18
|
-
def index():
|
19
|
+
def index() -> ResponseReturnValue:
|
19
20
|
equipment_summary = get_equipment_use_table(
|
20
21
|
repository.meta, config.equipment_offsets
|
21
22
|
)
|