feat(tours): show the known SAC grades along a hike (MAP-03)

A hike in the planner, being edited or viewed as an import, now has an
"SAC grades" card. Switched on, it asks the router which OpenStreetMap
ways lie under the line (matched on foot, every grade of path open) and
the server reads their sac_scale through the Overpass mirrors, the same
trail-grades read the mountain bike grades use. The grades are drawn
along the route on the planner map in one ramp of a single hue, T1 to
T6, and listed by share and length; a row draws its class alone. Each
row names its source in a tooltip: the SAC hiking scale and the
sac_scale value OpenStreetMap wrote.

What is not known stays unknown and says why, never T1: a way without
a grade, a grade that names no single step (handed on as written), a
stretch with no way clearly under the tour's line, or a way that could
not be asked about. For imported tracks and stretches drawn by hand a
matched way only counts where it keeps within 25 m of the tour's own
line, so the original line is kept and nothing is guessed. The router's
own reading of the scale is not asked for, since it may be normalised.

The routing limit of a planned hike sits apart as a setting with its
own badge, and a known step above it is marked. Nothing about the tour,
its places or its days changes; switched off, the map is as it was.
No regional colour categories and no grade derived from slope, height
or trail markings.
This commit is contained in:
Maurice
2026-10-20 12:25:20 +02:00
parent ad2d653e9a
commit ea9e997338
63 changed files with 2327 additions and 108 deletions
+30
View File
@@ -522,6 +522,36 @@ const tours: TranslationStrings = {
'Schwierigkeiten, wie OpenStreetMap-Mapper sie vergeben haben. Ein Weg ohne Angabe ist unbekannt, nicht leicht. Sie sagen nichts darüber, ob ein Trail zu dir passt.',
'tours.bike.trail.loading': 'Trail-Schwierigkeiten werden gelesen…',
'tours.bike.trail.failed': 'Die Trail-Schwierigkeiten konnten diesmal nicht gelesen werden.',
'tours.hike.sac.title': 'SAC-Schwierigkeit',
'tours.hike.sac.show': 'Entlang der Route zeigen',
'tours.hike.sac.t1': 'Wandern',
'tours.hike.sac.t2': 'Bergwandern',
'tours.hike.sac.t3': 'Anspruchsvolles Bergwandern',
'tours.hike.sac.t4': 'Alpinwandern',
'tours.hike.sac.t5': 'Anspruchsvolles Alpinwandern',
'tours.hike.sac.t6': 'Schwieriges Alpinwandern',
'tours.hike.sac.untagged': 'Keine Angabe in OpenStreetMap',
'tours.hike.sac.unclear': 'Angabe unklar',
'tours.hike.sac.unmatched': 'Weg nicht eindeutig zugeordnet',
'tours.hike.sac.unasked': 'Diesmal nicht abfragbar',
'tours.hike.sac.unknown': 'Unbekannt',
'tours.hike.sac.stepTip': 'SAC-Wanderskala {step}, aus OpenStreetMap: sac_scale={tag}',
'tours.hike.sac.untaggedTip': 'OpenStreetMap gibt diesen Wegen kein sac_scale. Unbekannt heißt nicht leicht.',
'tours.hike.sac.unclearTip': 'OpenStreetMap schreibt hier {tags}, das benennt keine einzelne Stufe.',
'tours.hike.sac.unmatchedTip':
'Hier liegt kein Weg eindeutig unter der Linie der Tour, daher wird keine Stufe gezeigt.',
'tours.hike.sac.known': 'Bekannt',
'tours.hike.sac.knownTip':
'Der Anteil der Route, für den OpenStreetMap eine SAC-Stufe angibt. Der Rest ist unbekannt.',
'tours.hike.sac.highest': 'Höchste bekannte',
'tours.hike.sac.routingLimit': 'Routing-Grenze',
'tours.hike.sac.routingLimitTip':
'Das Höchste, was die Routensuche nutzen darf: eine Einstellung, nicht die Schwierigkeit der Wege.',
'tours.hike.sac.aboveLimit': 'Über der Grenze',
'tours.hike.sac.loading': 'SAC-Stufen werden gelesen…',
'tours.hike.sac.offline': 'Die SAC-Stufen brauchen eine Verbindung.',
'tours.hike.sac.failed': 'Die SAC-Stufen konnten nicht gelesen werden. Die Tour bleibt unverändert.',
'tours.hike.sac.source': 'Aus OpenStreetMap. Lücken sind möglich; keine Sicherheitsbewertung.',
'tours.copy.action': 'Als neue Tour speichern',
'tours.copy.hint': 'Kopiert diese Tour als neue, eigenständige Tour ohne ihre Tage. Das Original bleibt, wie es ist.',
'tours.copy.name': '{name} (Kopie)',