mirror of
https://github.com/mauriceboe/TREK.git
synced 2026-12-01 08:53:13 +00:00
feat(tours): import a ski track from GPX and keep it as recorded
SKI-02. Ski joins the types a GPX file can be imported as, offered in the import preview's type field only: TREK routes no ski track, so the planner never offers it. The preview asks for the discipline on purpose (alpine, snowboard, cross-country or ski touring, none chosen at first) and, for cross-country, the technique (classic, skating or unknown); Import waits until both are named, and the technique stays in sight but dimmed for the other disciplines. The track is stored exactly as recorded, with its file name as provenance, its distance and heights from the file and no time: no ski time is worked out and no hiking estimate stands in for one. Opened in the planner, a ski track gets a rail card with its discipline on a tinted tile, a cross-country technique as a badge beside it, the ski time said as not worked out, and an info dot on what TREK does not say (snow, avalanches, open runs, and that the 3D gradient colours are no difficulty or avalanche rating). Change opens a dialog to classify the track again; only the classification changes, through the offline core, with the revision it was made at. Planning over the import is not offered for ski. The existing 3D terrain view, the elevation profile and its focus work on the track as for any import, with the standard map, topo and satellite and no via ferratas. Lists, the day plan and the detail show the discipline as a frosted corner badge on the tile and as a pill with the technique inside; day assignment, copies and take-overs work as for any tour. The corner badge is now one component that the winter label shares. The server keeps tours.ski_discipline and tours.ski_technique (CHECK lists, NULL on every other type), switches the ski type on without a routing profile, refuses a ski import without its discipline, a technique outside cross-country and ski fields on any other type, and takes a planned save's classification off. PUT /api/trips/:tripId/tours/:placeId/ski classifies a ski track again (place_edit, 409 on a stale revision, 400 for a tour that is no ski track) and broadcasts tours:changed. GPX export names the discipline (alpine_skiing, snowboarding, cross_country_skiing, backcountry_skiing), and list_tours describes both fields with what a ski track does not say. Ski is labelled plainly as Ski in every language, so it no longer reads as ski touring.
This commit is contained in:
@@ -195,7 +195,7 @@ const tours: TranslationStrings = {
|
||||
'tourTypes.hike': 'ハイキング',
|
||||
'tourTypes.bike': 'サイクリング',
|
||||
'tourTypes.run': 'ランニング',
|
||||
'tourTypes.ski': 'スキーツアー',
|
||||
'tourTypes.ski': 'スキー',
|
||||
'tourTypes.kayak': 'パドルツアー',
|
||||
'tourTypes.walk': '街歩き・観光',
|
||||
'tourTypes.food': 'グルメ・ワインツアー',
|
||||
@@ -395,6 +395,27 @@ const tours: TranslationStrings = {
|
||||
'tours.winter.activity.snowshoe': 'スノーシューハイキング',
|
||||
'tours.winter.labelOnly':
|
||||
'旅行者が付けたラベルです。ルートと時間は通常のハイキングと同じく計画され、冬向けには確認されていません。',
|
||||
'tours.planner.tourTypeHint.ski': 'GPX ファイルから、記録されたまま',
|
||||
'tours.ski.title': 'スキーのトラック',
|
||||
'tours.ski.discipline': '種目',
|
||||
'tours.ski.discipline.alpine': 'アルペン',
|
||||
'tours.ski.discipline.snowboard': 'スノーボード',
|
||||
'tours.ski.discipline.cross_country': 'クロスカントリー',
|
||||
'tours.ski.discipline.touring': '山スキー',
|
||||
'tours.ski.technique': '走法',
|
||||
'tours.ski.technique.classic': 'クラシカル',
|
||||
'tours.ski.technique.skating': 'スケーティング',
|
||||
'tours.ski.technique.unknown': '不明',
|
||||
'tours.ski.chooseDiscipline': 'スキーとして取り込むには種目を選んでください。',
|
||||
'tours.ski.chooseTechnique': '走法を選ぶか、不明を選んでください。',
|
||||
'tours.ski.infoLabel': 'TREK がスキーのトラックで行うこと',
|
||||
'tours.ski.info':
|
||||
'記録されたまま保持され、ルート検索されることはありません。距離と標高はファイルの値です。TREK はスキーの所要時間を計算せず、トラックも 3D の勾配の色も、難易度、積雪、雪崩、コースの営業状況について何も示しません。',
|
||||
'tours.ski.time': 'スキー時間',
|
||||
'tours.ski.timeUnknown': '計算なし',
|
||||
'tours.ski.classifyTitle': 'スキーのトラックを分類',
|
||||
'tours.ski.saved': '分類を保存しました',
|
||||
'tours.ski.saveFailed': '分類を保存できませんでした。',
|
||||
'tours.planner.tourTypeHint.run': '自分のペースで、走りやすい道を',
|
||||
'tours.planner.namePlaceholder.run': '無題のラン',
|
||||
'tours.planner.unreachable.run':
|
||||
|
||||
Reference in New Issue
Block a user