From 1fe1d13c600b7dfe421b3b99b833b7d5d1232724 Mon Sep 17 00:00:00 2001 From: Dennis Fink Date: Thu, 23 Jul 2026 00:18:21 +0200 Subject: Add GPX trail maps to blog posts This adds a trail flow block so posts can include attached GPX files as interactive maps with route display, elevation charts, activity summaries, and start/finish markers. The trail assets are loaded only when needed, keeping the shared templates clean while vendoring the Leaflet dependencies required for offline, self-hosted map rendering. --- templates/base.html | 31 ++++++++++++++++++++++++++++++- 1 file changed, 30 insertions(+), 1 deletion(-) (limited to 'templates/base.html') diff --git a/templates/base.html b/templates/base.html index 024907d..99341e7 100644 --- a/templates/base.html +++ b/templates/base.html @@ -75,6 +75,19 @@ type="text/css" href="{{ '/static/css/style.css' | asseturl }}"> {% endblock styles %} + + {% block feature_styles %} + {% if needs_trail_assets | default(false) %} + + + + + {% endif %} + {% endblock feature_styles %} + {% block meta_links %} {% endblock body %} + {% block scripts %} + {% if needs_trail_assets | default(false) %} + + + + + + + + {% endif %} + {% endblock scripts %} + -- cgit v1.3.1