feat(tours): plan rides on horseback from signposted horse routes

A tour can now be a ride (HOR-01). The planner offers "Horse ride" as a
tour type with its own horseshoe, and a Horse routes card beside the
waypoints looks, when asked, for the route=horse relations OpenStreetMap
knows in the map view. A route opens in a dialog that shows it on a map in
the sections it is made of, split at forks, gaps and crossings, so nothing
is ever joined across a gap. The rider picks a section and its direction,
sees what the horse=* tags along it say (open, limited, closed, or unknown
where untagged) and whether it is signposted the other way, and takes it as
one undoable step. A section that does not start where the ride ends is
only joined by a straight manual stretch once the rider switched that on.

Nothing of a ride is routed: every leg follows a section or is drawn by
hand, and the waypoint list and the map say which (a section as a solid
line with its route, a manual stretch dashed and marked unchecked). A point
at a section stays where the route has it, a ride works out no riding time,
and distance, heights, day assignment, GPX import and export, the 3D view
and the reversed ride keep working with each leg's origin saved and opened
again. A failed lookup leaves the ride and the routes already found as they
were.

The server reads the routes through the shared Overpass client
(GET /api/trips/:tripId/tours/horse-routes, Tours addon, trip access),
keeps an answer twelve hours per grid-aligned view, and the tour contract
refuses a routed leg, a via ferrata or a riding time on a ride and a horse
route section on any other type. A migration enables the horse tour type.
This commit is contained in:
Maurice
2026-10-20 12:48:41 +02:00
parent dfe11e9c4c
commit 0331d9950f
103 changed files with 5470 additions and 82 deletions
@@ -128,8 +128,14 @@ export function useGpxConversion(planner: TourPlannerController) {
/**
* The import shown can be planned from: it has a track and the user may add tours. A ski
* track (SKI-02) never: TREK routes no ski track, and a hike's or a walk's route is no stand-in.
* A ride (HOR-01) neither: no router plans one, and walking it again on foot would be no ride.
*/
available: tour !== null && tour.tour_type !== 'ski' && (track?.length ?? 0) >= 2 && planner.canEdit,
available:
tour !== null &&
tour.tour_type !== 'ski' &&
tour.tour_type !== 'horse' &&
(track?.length ?? 0) >= 2 &&
planner.canEdit,
difficulty,
/** The import is a paddle tour: its version is drawn with straight legs, not routed. */
paddle,