feat(tours): take a tour over from another trip, the dialog (LIB-02)

The Tours tab's list of the trip's tours gains a button beside the GPX
import: take a tour over from another trip. Its dialog lists the tours of
the user's other trips, searched by name and filtered by trip and type,
each with its trip and the measures it has (time, distance, ascent; one it
lacks is left out, a paddle tour's climb too). Choosing one shows it on a
map with where it comes from, its type, distance, time, heights and number
of waypoints, and the name it gets in this trip, its own name to start
with. The note under the name says the copy is a tour of this trip of its
own, on no day yet, and that later changes stay apart.

Only the button in the foot takes it over. The new tour then comes into
the trip's lists and map and opens in the editor, unless the editor holds
unsaved work, which it never replaces. Nothing is written before the
confirm, and closing writes nothing. The library is online only: offline,
or when the list fails, the dialog says so and offers to try again; a list
cut at 100 tours says to search or filter.

A tour taken over names its source in its provenance: "Taken over from"
with the trip and the tour as they were called then.
This commit is contained in:
Maurice
2026-10-19 15:28:53 +02:00
parent f6fd2722d0
commit 692373c8b8
39 changed files with 1545 additions and 6 deletions
+23
View File
@@ -260,6 +260,29 @@ const tours: TranslationStrings = {
'tours.scope.imported': 'เวลาจากการนำเข้า',
'tours.scope.planned': 'วางแผนรวมพัก',
'tours.scope.noMeasures': 'ยังไม่ทราบระยะทาง ความสูง หรือเวลา',
'tours.library.open': 'นำทัวร์จากทริปอื่นมาใช้',
'tours.library.eyebrow': 'นำทัวร์มาใช้',
'tours.library.title': 'จากทริปอื่น',
'tours.library.sub': 'คัดลอกทัวร์จากทริปอื่นของคุณมาไว้ในทริปนี้ ต้นฉบับยังคงเหมือนเดิม',
'tours.library.search': 'ค้นหาตามชื่อ',
'tours.library.trip': 'ทริป',
'tours.library.allTrips': 'ทุกทริป',
'tours.library.allTypes': 'ทุกประเภท',
'tours.library.empty': 'ไม่มีทัวร์ที่ตรงกัน',
'tours.library.noTrips': 'ทริปอื่นของคุณยังไม่มีทัวร์',
'tours.library.truncated': 'แสดง 100 ทัวร์แรก ค้นหาหรือกรองเพื่อหาทัวร์อื่น',
'tours.library.offline': 'การนำทัวร์มาใช้ต้องเชื่อมต่ออินเทอร์เน็ต',
'tours.library.loadFailed': 'โหลดทัวร์ไม่ได้',
'tours.library.previewFailed': 'โหลดตัวอย่างไม่ได้',
'tours.library.chooseHint': 'เลือกทัวร์เพื่อดูที่นี่ก่อนนำมาใช้',
'tours.library.fromTrip': 'จากทริป',
'tours.library.controlPoints': 'จุดแวะ',
'tours.library.nameHere': 'ชื่อในทริปนี้',
'tours.library.independent': 'กลายเป็นทัวร์ของทริปนี้เอง ยังไม่อยู่ในวันใด และการแก้ไขภายหลังของแต่ละอันจะแยกกัน',
'tours.library.confirm': 'นำมาใช้',
'tours.library.taken': 'นำ “{name}” มาใช้ในทริปนี้แล้ว',
'tours.library.failed': 'นำทัวร์มาใช้ไม่ได้',
'tours.provenance.takenOverFrom': 'นำมาจาก',
'tours.copy.action': 'บันทึกเป็นทัวร์ใหม่',
'tours.copy.hint': 'คัดลอกทัวร์นี้เป็นทัวร์ใหม่ที่แยกเป็นอิสระโดยไม่รวมวัน ต้นฉบับจะคงเดิม',
'tours.copy.name': '{name} (สำเนา)',