feat(tours): a city walk's arrivals and opening hours for the day it is on, at each stop in the planner and the detail (CW-02, CW-04)

A city walk now shows, at each stop, when the walk gets there, until when
the stay lasts, and what the stop's opening hours say about that visit. The
same lines appear under each stop row in the planner and under each stop in
the walk's detail, in the user's 12 or 24 hour format. A conflict names the
stop, the arrival, the end of the stay and the hours it was checked against,
for instance "Lenbachhaus closes at 18:00, during the stay from 17:20 to
18:20 (open 10:00 to 18:00)", in the warning colour. Nothing is changed by
these hints: no stop, order or route moves.

The times belong to one day the walk is on. Opened from a day of the plan,
the detail keeps that day, and checking stops off stays bound to it.
Opened otherwise, and in the planner, a small pill above the stops names
the day and its start, and the walk's other days can be picked from it; it
starts on the first day with a start time. The pick is only what is looked
at and is never saved, and another day never takes over the times quietly.
Without a day, a date or a start time the line says what is missing and no
arrival is shown. TREK keeps no time zone on a trip, so start, arrivals and
opening hours are all read as the local time of the plan, and an arrival
after midnight is said to be on the next day without being checked.

Opening hours come from the trip place a stop stands for, as the travellers
entered them, and otherwise from OpenStreetMap; a pill at each stop names
the source, and a notice says the hours are a hint to check. A stop without
hours stays unknown and is never shown as open, hours that are not in a
plain form are shown as written, and an arrival that is only a lower bound,
because a stay before it is not entered yet, is not judged unless no later
arrival could escape the conflict. A trip place that a stop stands for also
gives the stop its name before "Stop N".

The arrival at a stop is found where the route passes it in the walk's
order, so the end of a loop and a stop passed on the way out and back get
the right time. The rules live once in the shared package, for the server
to give the same answers. The walk's detail reads its stops again after a
save, its own or a teammate's.
This commit is contained in:
Maurice
2026-10-20 03:22:11 +00:00
parent 0d7e3ceb3d
commit 2203ff3a2e
48 changed files with 2476 additions and 397 deletions
+22 -3
View File
@@ -537,12 +537,31 @@ const tours: TranslationStrings = {
'tours.walk.themeReason': 'Vorgeschlagen für {theme}',
'tours.walk.arrival': 'Ankunft ca. {time}',
'tours.walk.arrivalAtLeast': 'Ankunft frühestens {time}',
'tours.walk.hours.closed': 'Um {arrival} laut Öffnungszeiten geschlossen',
'tours.walk.hours.closes': 'Ankunft {arrival}, Aufenthalt bis {leave}, aber Schließung um {closes}',
'tours.walk.hours.closed': '{name} ist um {arrival} geschlossen, der Aufenthalt ginge bis {leave}; geöffnet {window}',
'tours.walk.hours.closes':
'{name} schließt um {closes}, während des Aufenthalts von {arrival} bis {leave} (geöffnet {window})',
'tours.walk.hours.unread': 'Öffnungszeiten hier nicht auswertbar: {text}',
'tours.walk.hours.source':
'Öffnungszeiten wie bei OpenStreetMap eingetragen, gegen die geschätzte Ankunft; vor Ort lieber prüfen. Eine Station ohne Zeiten ist unbekannt, nicht geöffnet.',
'Öffnungszeiten aus OpenStreetMap oder aus deinen eigenen Ortsangaben, verglichen mit der geschätzten Ankunft in der Ortszeit des Plans; vor Ort lieber prüfen. Eine Station ohne Zeiten ist unbekannt, nicht geöffnet.',
'tours.walk.hours.noStart': 'Gib dem Walk an diesem Tag eine Uhrzeit, um Ankünfte und Öffnungszeiten zu sehen.',
'tours.walk.day.label': 'Zeiten für',
'tours.walk.day.start': '{day}, Beginn {time}',
'tours.walk.day.noStart': '{day}, ohne Startzeit',
'tours.walk.hours.noDate': 'Dieser Tag hat kein Datum, deshalb fehlen Ankünfte und Öffnungszeiten.',
'tours.walk.hours.noDay': 'Lege den Walk auf einen Tag mit Startzeit, um Ankünfte und Öffnungszeiten zu sehen.',
'tours.walk.hours.closedNoStay': '{name} ist um {arrival} geschlossen; geöffnet {window}',
'tours.walk.hours.closedAllDay': '{name} ist an diesem Datum den ganzen Tag geschlossen',
'tours.walk.hours.open': 'Geöffnet {window}',
'tours.walk.hours.window': '{from} bis {to}',
'tours.walk.hours.uncertain': 'Öffnungszeiten nicht geprüft: Bei einer Station davor fehlt noch der Aufenthalt.',
'tours.walk.arrivalNextDay':
'Ankunft ca. {time} am nächsten Tag; Öffnungszeiten werden über Mitternacht hinaus nicht geprüft.',
'tours.walk.arrivalStay': 'Ankunft ca. {arrival}, Aufenthalt bis {leave}',
'tours.walk.arrivalStayAtLeast': 'Ankunft frühestens {arrival}, Aufenthalt bis {leave} oder länger',
'tours.walk.hours.sourceOsm': 'OpenStreetMap',
'tours.walk.hours.sourcePlace': 'Ort der Reise',
'tours.walk.hours.sourceOsmHint': 'Mit der Station aus OpenStreetMap übernommen; kann veraltet sein.',
'tours.walk.hours.sourcePlaceHint': 'Für diesen Ort der Reise eingetragen.',
'tours.poi.categoriesNone': 'Keine Kategorie gewählt',
'tours.poi.categoriesMore': '{first} +{more}',
'tours.planner.tourType': 'Tourtyp',