diff --git a/.gitattributes b/.gitattributes index 3dafcefbb2ce1b760156385b48c663a398e4266c..b59ca3c03a069a89185481fac845c144146b4a9f 100644 --- a/.gitattributes +++ b/.gitattributes @@ -29,3 +29,37 @@ server/assets/atlas/admin0.geojson.gz filter=lfs diff=lfs merge=lfs -text server/assets/atlas/admin1.geojson.gz filter=lfs diff=lfs merge=lfs -text shared/node_modules/@rolldown/binding-linux-x64-gnu/rolldown-binding.linux-x64-gnu.node filter=lfs diff=lfs merge=lfs -text shared/node_modules/@rolldown/binding-linux-x64-musl/rolldown-binding.linux-x64-musl.node filter=lfs diff=lfs merge=lfs -text +wiki/assets/Addons-Overview.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/Atlas.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/Audit.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/Backup.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/Budget.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/BudgetAddExpensive.gif filter=lfs diff=lfs merge=lfs -text +wiki/assets/BudgetCreateBudget.gif filter=lfs diff=lfs merge=lfs -text +wiki/assets/BudgetFinalSettlement.gif filter=lfs diff=lfs merge=lfs -text +wiki/assets/Collab.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/DashboardWidgets.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/DayItineraryAddPlaceByButton.gif filter=lfs diff=lfs merge=lfs -text +wiki/assets/DayItineraryAddPlaceDragging.gif filter=lfs diff=lfs merge=lfs -text +wiki/assets/DayItineraryRemovePlaceByButton.gif filter=lfs diff=lfs merge=lfs -text +wiki/assets/Journey.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/Login.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/MCPAccess.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/MCPConfig.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/NotifSettings.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/OptimizeRoute.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/PDFJourney.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/PDFTrip.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/PackingList.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/PermissionSettings.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/PlaceAutocomplete.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/Share.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/Todos.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/TripPlaner.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/TripPlannerWithPlane.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/UsersAndInvites.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/UsrSettings.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/UsrSettingsMap.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/Vacay.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/Weather.png filter=lfs diff=lfs merge=lfs -text +wiki/assets/portainer-stack-save.png filter=lfs diff=lfs merge=lfs -text diff --git a/shared/src/i18n/ru/packing.ts b/shared/src/i18n/ru/packing.ts new file mode 100644 index 0000000000000000000000000000000000000000..a6ca1892b5c9e6bf417b9170b9343fa20096e7ba --- /dev/null +++ b/shared/src/i18n/ru/packing.ts @@ -0,0 +1,186 @@ +import type { TranslationStrings } from '../types'; + +const packing: TranslationStrings = { + 'packing.title': 'Список вещей', + 'packing.empty': 'Список вещей пуст', + 'packing.import': 'Импорт', + 'packing.importTitle': 'Импорт списка вещей', + 'packing.importHint': + 'Один предмет на строку. Категория и количество — через запятую, точку с запятой или табуляцию: Название, Категория, Количество', + 'packing.importPlaceholder': + 'Зубная щётка\nСолнцезащитный крем, Гигиена\nФутболки, Одежда, 5\nПаспорт, Документы', + 'packing.importCsv': 'Загрузить CSV/TXT', + 'packing.importAction': 'Импортировать {count}', + 'packing.importSuccess': '{count} предметов импортировано', + 'packing.importError': 'Ошибка импорта', + 'packing.importEmpty': 'Нет предметов для импорта', + 'packing.progress': '{packed} из {total} собрано ({percent}%)', + 'packing.clearChecked': 'Удалить {count} отмеченных', + 'packing.clearCheckedShort': 'Удалить {count}', + 'packing.suggestions': 'Подсказки', + 'packing.suggestionsTitle': 'Добавить подсказки', + 'packing.allSuggested': 'Все подсказки добавлены', + 'packing.allPacked': 'Всё собрано!', + 'packing.addPlaceholder': 'Добавить вещь...', + 'packing.categoryPlaceholder': 'Категория...', + 'packing.filterAll': 'Все', + 'packing.filterOpen': 'Не собрано', + 'packing.filterDone': 'Собрано', + 'packing.emptyTitle': 'Список вещей пуст', + 'packing.emptyHint': 'Добавьте вещи или используйте подсказки', + 'packing.emptyFiltered': 'Нет вещей, соответствующих фильтру', + 'packing.menuRename': 'Переименовать', + 'packing.menuCheckAll': 'Отметить все', + 'packing.menuUncheckAll': 'Снять отметки', + 'packing.menuDeleteCat': 'Удалить категорию', + 'packing.addItem': 'Добавить вещь', + 'packing.addItemPlaceholder': 'Название...', + 'packing.addCategory': 'Добавить категорию', + 'packing.newCategoryPlaceholder': 'Название категории (напр. Одежда)', + 'packing.applyTemplate': 'Применить шаблон', + 'packing.template': 'Шаблон', + 'packing.templateApplied': '{count} вещей добавлено из шаблона', + 'packing.templateError': 'Ошибка применения шаблона', + 'packing.saveAsTemplate': 'Сохранить как шаблон', + 'packing.templateName': 'Название шаблона', + 'packing.templateSaved': 'Список вещей сохранён как шаблон', + 'packing.noMembers': 'Нет участников', + 'packing.bags': 'Багаж', + 'packing.noBag': 'Не назначено', + 'packing.totalWeight': 'Общий вес', + 'packing.bagName': 'Название...', + 'packing.addBag': 'Добавить багаж', + 'packing.changeCategory': 'Изменить категорию', + 'packing.confirm.clearChecked': + 'Вы уверены, что хотите удалить {count} отмеченных вещей?', + 'packing.confirm.deleteCat': + 'Вы уверены, что хотите удалить категорию «{name}» с {count} вещами?', + 'packing.defaultCategory': 'Другое', + 'packing.toast.saveError': 'Ошибка сохранения', + 'packing.toast.deleteError': 'Ошибка удаления', + 'packing.toast.renameError': 'Ошибка переименования', + 'packing.toast.addError': 'Ошибка добавления', + 'packing.suggestions.items': [ + { + name: 'Паспорт', + category: 'Документы', + }, + { + name: 'Удостоверение личности', + category: 'Документы', + }, + { + name: 'Страховка', + category: 'Документы', + }, + { + name: 'Авиабилеты', + category: 'Документы', + }, + { + name: 'Банковская карта', + category: 'Финансы', + }, + { + name: 'Наличные', + category: 'Финансы', + }, + { + name: 'Виза', + category: 'Документы', + }, + { + name: 'Футболки', + category: 'Одежда', + }, + { + name: 'Брюки', + category: 'Одежда', + }, + { + name: 'Нижнее бельё', + category: 'Одежда', + }, + { + name: 'Носки', + category: 'Одежда', + }, + { + name: 'Куртка', + category: 'Одежда', + }, + { + name: 'Пижама', + category: 'Одежда', + }, + { + name: 'Купальник', + category: 'Одежда', + }, + { + name: 'Дождевик', + category: 'Одежда', + }, + { + name: 'Удобная обувь', + category: 'Одежда', + }, + { + name: 'Зубная щётка', + category: 'Гигиена', + }, + { + name: 'Зубная паста', + category: 'Гигиена', + }, + { + name: 'Шампунь', + category: 'Гигиена', + }, + { + name: 'Дезодорант', + category: 'Гигиена', + }, + { + name: 'Солнцезащитный крем', + category: 'Гигиена', + }, + { + name: 'Бритва', + category: 'Гигиена', + }, + { + name: 'Зарядное устройство', + category: 'Электроника', + }, + { + name: 'Внешний аккумулятор', + category: 'Электроника', + }, + { + name: 'Наушники', + category: 'Электроника', + }, + { + name: 'Адаптер для розеток', + category: 'Электроника', + }, + { + name: 'Фотоаппарат', + category: 'Электроника', + }, + { + name: 'Обезболивающее', + category: 'Здоровье', + }, + { + name: 'Пластыри', + category: 'Здоровье', + }, + { + name: 'Антисептик', + category: 'Здоровье', + }, + ], +}; +export default packing; diff --git a/shared/src/i18n/ru/pdf.ts b/shared/src/i18n/ru/pdf.ts new file mode 100644 index 0000000000000000000000000000000000000000..a8c02d050102f58c80ea8205b7e1d03e8bd2979b --- /dev/null +++ b/shared/src/i18n/ru/pdf.ts @@ -0,0 +1,10 @@ +import type { TranslationStrings } from '../types'; + +const pdf: TranslationStrings = { + 'pdf.travelPlan': 'План поездки', + 'pdf.planned': 'Запланировано', + 'pdf.costLabel': 'Стоимость EUR', + 'pdf.preview': 'Предпросмотр PDF', + 'pdf.saveAsPdf': 'Сохранить как PDF', +}; +export default pdf; diff --git a/shared/src/i18n/ru/perm.ts b/shared/src/i18n/ru/perm.ts new file mode 100644 index 0000000000000000000000000000000000000000..e7148f62dfec3e133fb006a6d2116a5a855364fb --- /dev/null +++ b/shared/src/i18n/ru/perm.ts @@ -0,0 +1,63 @@ +import type { TranslationStrings } from '../types'; + +const perm: TranslationStrings = { + 'perm.title': 'Настройки разрешений', + 'perm.subtitle': 'Управляйте тем, кто может выполнять действия в приложении', + 'perm.saved': 'Настройки разрешений сохранены', + 'perm.resetDefaults': 'Сбросить по умолчанию', + 'perm.customized': 'изменено', + 'perm.level.admin': 'Только администратор', + 'perm.level.tripOwner': 'Владелец поездки', + 'perm.level.tripMember': 'Участники поездки', + 'perm.level.everybody': 'Все', + 'perm.cat.trip': 'Управление поездками', + 'perm.cat.members': 'Управление участниками', + 'perm.cat.files': 'Файлы', + 'perm.cat.content': 'Контент и расписание', + 'perm.cat.extras': 'Бюджет, сборы и совместная работа', + 'perm.action.trip_create': 'Создавать поездки', + 'perm.action.trip_edit': 'Редактировать детали поездки', + 'perm.action.trip_delete': 'Удалять поездки', + 'perm.action.trip_archive': 'Архивировать / разархивировать поездки', + 'perm.action.trip_cover_upload': 'Загружать обложку', + 'perm.action.member_manage': 'Добавлять / удалять участников', + 'perm.action.file_upload': 'Загружать файлы', + 'perm.action.file_edit': 'Редактировать метаданные файлов', + 'perm.action.file_delete': 'Удалять файлы', + 'perm.action.place_edit': 'Добавлять / редактировать / удалять места', + 'perm.action.day_edit': 'Редактировать дни, заметки и назначения', + 'perm.action.reservation_edit': 'Управлять бронированиями', + 'perm.action.budget_edit': 'Управлять бюджетом', + 'perm.action.packing_edit': 'Управлять списками вещей', + 'perm.action.collab_edit': 'Совместная работа (заметки, опросы, чат)', + 'perm.action.share_manage': 'Управлять ссылками для обмена', + 'perm.actionHint.trip_create': 'Кто может создавать новые поездки', + 'perm.actionHint.trip_edit': + 'Кто может менять название, даты, описание и валюту поездки', + 'perm.actionHint.trip_delete': 'Кто может безвозвратно удалить поездку', + 'perm.actionHint.trip_archive': + 'Кто может архивировать или разархивировать поездку', + 'perm.actionHint.trip_cover_upload': 'Кто может загружать или менять обложку', + 'perm.actionHint.member_manage': + 'Кто может приглашать или удалять участников поездки', + 'perm.actionHint.file_upload': 'Кто может загружать файлы в поездку', + 'perm.actionHint.file_edit': + 'Кто может редактировать описания и ссылки файлов', + 'perm.actionHint.file_delete': + 'Кто может перемещать файлы в корзину или безвозвратно удалять', + 'perm.actionHint.place_edit': + 'Кто может добавлять, редактировать или удалять места', + 'perm.actionHint.day_edit': + 'Кто может редактировать дни, заметки к дням и назначения мест', + 'perm.actionHint.reservation_edit': + 'Кто может создавать, редактировать или удалять бронирования', + 'perm.actionHint.budget_edit': + 'Кто может создавать, редактировать или удалять статьи бюджета', + 'perm.actionHint.packing_edit': + 'Кто может управлять вещами для сборов и сумками', + 'perm.actionHint.collab_edit': + 'Кто может создавать заметки, опросы и отправлять сообщения', + 'perm.actionHint.share_manage': + 'Кто может создавать или удалять публичные ссылки для обмена', +}; +export default perm; diff --git a/shared/src/i18n/ru/photos.ts b/shared/src/i18n/ru/photos.ts new file mode 100644 index 0000000000000000000000000000000000000000..eef31d033357c1ac31d7f04060d301e619ff3523 --- /dev/null +++ b/shared/src/i18n/ru/photos.ts @@ -0,0 +1,25 @@ +import type { TranslationStrings } from '../types'; + +const photos: TranslationStrings = { + 'photos.title': 'Фотографии', + 'photos.subtitle': '{count} фото для {trip}', + 'photos.dropHere': 'Перетащите фото сюда...', + 'photos.dropHereActive': 'Перетащите фото сюда', + 'photos.captionForAll': 'Подпись (для всех)', + 'photos.captionPlaceholder': 'Необязательная подпись...', + 'photos.addCaption': 'Добавить подпись...', + 'photos.allDays': 'Все дни', + 'photos.noPhotos': 'Фото пока нет', + 'photos.uploadHint': 'Загрузите фото из путешествия', + 'photos.clickToSelect': 'или нажмите для выбора', + 'photos.linkPlace': 'Привязать место', + 'photos.noPlace': 'Без места', + 'photos.uploadN': '{n} фото загружено', + 'photos.linkDay': 'Связать день', + 'photos.noDay': 'Нет дня', + 'photos.dayLabel': 'День {number}', + 'photos.photoSelected': 'Фото выбрано', + 'photos.photosSelected': 'Фото выбраны', + 'photos.fileTypeHint': 'JPG, PNG, WebP · макс. 10 МБ · до 30 фото', +}; +export default photos; diff --git a/shared/src/i18n/ru/places.ts b/shared/src/i18n/ru/places.ts new file mode 100644 index 0000000000000000000000000000000000000000..566a984057686e1c3305923a3d00e9bba17a8ee5 --- /dev/null +++ b/shared/src/i18n/ru/places.ts @@ -0,0 +1,97 @@ +import type { TranslationStrings } from '../types'; + +const places: TranslationStrings = { + 'places.addPlace': 'Добавить место/активность', + 'places.importFile': 'Импортировать файл', + 'places.sidebarDrop': 'Отпустите для импорта', + 'places.importFileHint': + 'Импортируйте файлы .gpx, .kml или .kmz из инструментов, таких как Google My Maps, Google Earth или GPS-трекер.', + 'places.importFileDropHere': + 'Нажмите для выбора файла или перетащите его сюда', + 'places.importFileDropActive': 'Отпустите файл для выбора', + 'places.importFileUnsupported': + 'Неподдерживаемый тип файла. Используйте .gpx, .kml или .kmz.', + 'places.importFileTooLarge': + 'Файл слишком большой. Максимальный размер загрузки — {maxMb} MB.', + 'places.importFileError': 'Ошибка импорта', + 'places.importAllSkipped': 'Все места уже были в поездке.', + 'places.gpxImported': '{count} мест импортировано из GPX', + 'places.gpxImportTypes': 'Что импортировать?', + 'places.gpxImportWaypoints': 'Путевые точки', + 'places.gpxImportRoutes': 'Маршруты', + 'places.gpxImportTracks': 'Треки (с геометрией пути)', + 'places.gpxImportNoneSelected': 'Выберите хотя бы один тип для импорта.', + 'places.kmlImportTypes': 'Что вы хотите импортировать?', + 'places.kmlImportPoints': 'Точки (Placemarks)', + 'places.kmlImportPaths': 'Маршруты (LineStrings)', + 'places.kmlImportNoneSelected': 'Выберите хотя бы один тип.', + 'places.selectionCount': '{count} выбрано', + 'places.deleteSelected': 'Удалить выбранные', + 'places.kmlKmzImported': '{count} мест импортировано из KMZ/KML', + 'places.urlResolved': 'Место импортировано из URL', + 'places.importList': 'Импорт списка', + 'places.kmlKmzSummaryValues': + 'Placemarks: {total} • Импортировано: {created} • Пропущено: {skipped}', + 'places.importGoogleList': 'Список Google', + 'places.importNaverList': 'Список Naver', + 'places.googleListHint': + 'Вставьте ссылку на общий список Google Maps для импорта всех мест.', + 'places.googleListImported': '{count} мест импортировано из "{list}"', + 'places.googleListError': 'Не удалось импортировать список Google Maps', + 'places.naverListHint': + 'Вставьте ссылку на общий список Naver Maps для импорта всех мест.', + 'places.naverListImported': '{count} мест импортировано из "{list}"', + 'places.naverListError': 'Не удалось импортировать список Naver Maps', + 'places.viewDetails': 'Подробности', + 'places.assignToDay': 'Добавить в какой день?', + 'places.all': 'Все', + 'places.unplanned': 'Незапланированные', + 'places.filterTracks': 'Треки', + 'places.search': 'Поиск мест...', + 'places.allCategories': 'Все категории', + 'places.categoriesSelected': 'категорий', + 'places.clearFilter': 'Сбросить фильтр', + 'places.count': '{count} мест', + 'places.countSingular': '1 место', + 'places.allPlanned': 'Все места запланированы', + 'places.noneFound': 'Места не найдены', + 'places.editPlace': 'Редактировать место', + 'places.formName': 'Название', + 'places.formNamePlaceholder': 'напр. Эйфелева башня', + 'places.formDescription': 'Описание', + 'places.formDescriptionPlaceholder': 'Краткое описание...', + 'places.formAddress': 'Адрес', + 'places.formAddressPlaceholder': 'Улица, город, страна', + 'places.formLat': 'Широта (напр. 48.8566)', + 'places.formLng': 'Долгота (напр. 2.3522)', + 'places.formCategory': 'Категория', + 'places.noCategory': 'Без категории', + 'places.categoryNamePlaceholder': 'Название категории', + 'places.formTime': 'Время', + 'places.startTime': 'Начало', + 'places.endTime': 'Конец', + 'places.endTimeBeforeStart': 'Время окончания раньше времени начала', + 'places.timeCollision': 'Пересечение по времени с:', + 'places.formWebsite': 'Сайт', + 'places.formNotes': 'Заметки', + 'places.formNotesPlaceholder': 'Личные заметки...', + 'places.formReservation': 'Бронирование', + 'places.reservationNotesPlaceholder': + 'Заметки о бронировании, номер подтверждения...', + 'places.mapsSearchPlaceholder': 'Поиск мест...', + 'places.mapsSearchError': 'Ошибка поиска мест.', + 'places.loadingDetails': 'Загрузка данных о месте…', + 'places.osmHint': + 'Поиск через OpenStreetMap (без фото, часов работы и рейтингов). Добавьте API-ключ Google в настройках для полной информации.', + 'places.osmActive': + 'Поиск через OpenStreetMap (без фото, рейтингов и часов работы). Добавьте API-ключ Google в настройках для расширенных данных.', + 'places.categoryCreateError': 'Не удалось создать категорию', + 'places.nameRequired': 'Введите название', + 'places.saveError': 'Ошибка сохранения', + 'places.duplicateExists': "'{name}' уже есть в этой поездке.", + 'places.addAnyway': 'Всё равно добавить', + 'places.enrichOnImport': 'Обогатить места через Google', + 'places.enrichOnImportHint': + 'Находит каждое импортированное место и добавляет фото, адрес и контакты. Требуется ключ Google Maps.', +}; +export default places; diff --git a/shared/src/i18n/ru/planner.ts b/shared/src/i18n/ru/planner.ts new file mode 100644 index 0000000000000000000000000000000000000000..54ce59f8b3553548f8ea6e15b8db9af71a29f1bb --- /dev/null +++ b/shared/src/i18n/ru/planner.ts @@ -0,0 +1,68 @@ +import type { TranslationStrings } from '../types'; + +const planner: TranslationStrings = { + 'planner.places': 'Места', + 'planner.bookings': 'Бронирования', + 'planner.packingList': 'Список вещей', + 'planner.documents': 'Документы', + 'planner.dayPlan': 'План дня', + 'planner.reservations': 'Бронирования', + 'planner.minTwoPlaces': 'Нужно минимум 2 места с координатами', + 'planner.noGeoPlaces': 'Нет мест с координатами', + 'planner.routeCalculated': 'Маршрут рассчитан', + 'planner.routeCalcFailed': 'Не удалось рассчитать маршрут', + 'planner.routeError': 'Ошибка расчёта маршрута', + 'planner.icsExportFailed': 'Не удалось экспортировать ICS', + 'planner.routeOptimized': 'Маршрут оптимизирован', + 'planner.reservationUpdated': 'Бронирование обновлено', + 'planner.reservationAdded': 'Бронирование добавлено', + 'planner.confirmDeleteReservation': 'Удалить бронирование?', + 'planner.reservationDeleted': 'Бронирование удалено', + 'planner.days': 'Дни', + 'planner.allPlaces': 'Все места', + 'planner.totalPlaces': 'Всего {n} мест', + 'planner.noDaysPlanned': 'Дни ещё не запланированы', + 'planner.editTrip': 'Редактировать поездку →', + 'planner.placeOne': '1 место', + 'planner.placeN': '{n} мест', + 'planner.addNote': 'Добавить заметку', + 'planner.noEntries': 'На этот день записей нет', + 'planner.addPlace': 'Добавить место/активность', + 'planner.addPlaceShort': '+ Добавить место/активность', + 'planner.resPending': 'Бронирование ожидает · ', + 'planner.resConfirmed': 'Бронирование подтверждено · ', + 'planner.notePlaceholder': 'Заметка…', + 'planner.noteTimePlaceholder': 'Время (необязательно)', + 'planner.noteExamplePlaceholder': + 'напр. S3 в 14:30 с вокзала, паром с причала 7, обеденный перерыв…', + 'planner.totalCost': 'Общая стоимость', + 'planner.searchPlaces': 'Поиск мест…', + 'planner.allCategories': 'Все категории', + 'planner.noPlacesFound': 'Места не найдены', + 'planner.addFirstPlace': 'Добавить первое место', + 'planner.noReservations': 'Нет бронирований', + 'planner.addFirstReservation': 'Добавить первое бронирование', + 'planner.new': 'Новое', + 'planner.addToDay': '+ День', + 'planner.calculating': 'Расчёт…', + 'planner.route': 'Маршрут', + 'planner.optimize': 'Оптимизировать', + 'planner.openGoogleMaps': 'Открыть в Google Maps', + 'planner.selectDayHint': + 'Выберите день из списка слева для просмотра плана дня', + 'planner.noPlacesForDay': 'На этот день мест пока нет', + 'planner.addPlacesLink': 'Добавить места →', + 'planner.minTotal': 'мин. всего', + 'planner.noReservation': 'Нет бронирования', + 'planner.removeFromDay': 'Убрать из дня', + 'planner.addToThisDay': 'Добавить в день', + 'planner.overview': 'Обзор', + 'planner.noDays': 'Дней нет', + 'planner.editTripToAddDays': 'Отредактируйте поездку для добавления дней', + 'planner.dayCount': '{n} дней', + 'planner.clickToUnlock': 'Нажмите для разблокировки', + 'planner.keepPosition': 'Сохранить позицию при оптимизации маршрута', + 'planner.dayDetails': 'Подробности дня', + 'planner.dayN': 'День {n}', +}; +export default planner; diff --git a/shared/src/i18n/ru/register.ts b/shared/src/i18n/ru/register.ts new file mode 100644 index 0000000000000000000000000000000000000000..c4b9099081360a331d3cc55d0b04d646e425cd08 --- /dev/null +++ b/shared/src/i18n/ru/register.ts @@ -0,0 +1,25 @@ +import type { TranslationStrings } from '../types'; + +const register: TranslationStrings = { + 'register.passwordMismatch': 'Пароли не совпадают', + 'register.passwordTooShort': 'Пароль должен содержать не менее 8 символов', + 'register.failed': 'Ошибка регистрации', + 'register.getStarted': 'Начать', + 'register.subtitle': 'Создайте аккаунт и начните планировать поездки мечты.', + 'register.feature1': 'Неограниченные планы поездок', + 'register.feature2': 'Интерактивная карта', + 'register.feature3': 'Управление местами и категориями', + 'register.feature4': 'Отслеживание бронирований', + 'register.feature5': 'Создание списков вещей', + 'register.feature6': 'Хранение фото и файлов', + 'register.createAccount': 'Создать аккаунт', + 'register.startPlanning': 'Начните планировать свои поездки', + 'register.minChars': 'Мин. 6 символов', + 'register.confirmPassword': 'Подтвердите пароль', + 'register.repeatPassword': 'Повторите пароль', + 'register.registering': 'Регистрация...', + 'register.register': 'Зарегистрироваться', + 'register.hasAccount': 'Уже есть аккаунт?', + 'register.signIn': 'Войти', +}; +export default register; diff --git a/shared/src/i18n/ru/reservations.ts b/shared/src/i18n/ru/reservations.ts new file mode 100644 index 0000000000000000000000000000000000000000..dc0acedaf26439c3d76c688316c9c71ddc99e399 --- /dev/null +++ b/shared/src/i18n/ru/reservations.ts @@ -0,0 +1,163 @@ +import type { TranslationStrings } from '../types'; + +const reservations: TranslationStrings = { + 'reservations.title': 'Бронирования', + 'reservations.empty': 'Пока нет бронирований', + 'reservations.emptyHint': + 'Добавьте бронирования на авиабилеты, отели и другое', + 'reservations.add': 'Добавить бронирование', + 'reservations.addManual': 'Ручное бронирование', + 'reservations.placeHint': + 'Совет: бронирования лучше создавать прямо из места, чтобы связать их с планом дня.', + 'reservations.confirmed': 'Подтверждено', + 'reservations.pending': 'Ожидание', + 'reservations.summary': '{confirmed} подтв., {pending} ожид.', + 'reservations.fromPlan': 'Из плана', + 'reservations.showFiles': 'Показать файлы', + 'reservations.editTitle': 'Редактировать бронирование', + 'reservations.status': 'Статус', + 'reservations.datetime': 'Дата и время', + 'reservations.startTime': 'Время начала', + 'reservations.endTime': 'Время окончания', + 'reservations.date': 'Дата', + 'reservations.time': 'Время', + 'reservations.timeAlt': 'Время (альтернативное, напр. 19:30)', + 'reservations.notes': 'Заметки', + 'reservations.notesPlaceholder': 'Дополнительные заметки...', + 'reservations.meta.airline': 'Авиакомпания', + 'reservations.meta.flightNumber': 'Номер рейса', + 'reservations.meta.from': 'Откуда', + 'reservations.meta.to': 'Куда', + 'reservations.layover.route': 'Маршрут', + 'reservations.layover.stop': 'Остановка', + 'reservations.layover.addStop': 'Добавить остановку', + 'reservations.layover.connection': 'Стыковка', + 'reservations.layover.layover': 'Пересадка', + 'reservations.needsReview': 'Проверить', + 'reservations.needsReviewHint': + 'Аэропорт не удалось определить автоматически — подтвердите местоположение.', + 'reservations.searchLocation': 'Искать станцию, порт, адрес...', + 'reservations.meta.trainNumber': 'Номер поезда', + 'reservations.meta.platform': 'Платформа', + 'reservations.meta.seat': 'Место', + 'reservations.meta.checkIn': 'Заезд', + 'reservations.meta.checkInUntil': 'Заселение до', + 'reservations.meta.checkOut': 'Выезд', + 'reservations.meta.linkAccommodation': 'Жильё', + 'reservations.meta.pickAccommodation': 'Привязать к жилью', + 'reservations.meta.noAccommodation': 'Нет', + 'reservations.meta.hotelPlace': 'Жильё', + 'reservations.meta.pickHotel': 'Выбрать жильё', + 'reservations.meta.fromDay': 'С', + 'reservations.meta.toDay': 'По', + 'reservations.meta.selectDay': 'Выбрать день', + 'reservations.type.flight': 'Авиабилет', + 'reservations.type.hotel': 'Жильё', + 'reservations.type.restaurant': 'Ресторан', + 'reservations.type.train': 'Поезд', + 'reservations.type.car': 'Автомобиль', + 'reservations.type.cruise': 'Круиз', + 'reservations.type.event': 'Мероприятие', + 'reservations.type.tour': 'Экскурсия', + 'reservations.type.other': 'Другое', + 'reservations.type.bus': 'Автобус', + 'reservations.type.ferry': 'Паром', + 'reservations.type.bicycle': 'Велосипед', + 'reservations.type.taxi': 'Такси', + 'reservations.type.transport_other': 'Другое', + 'reservations.confirm.delete': + 'Вы уверены, что хотите удалить бронирование «{name}»?', + 'reservations.confirm.deleteTitle': 'Удалить бронирование?', + 'reservations.confirm.deleteBody': '«{name}» будет удалено навсегда.', + 'reservations.toast.updated': 'Бронирование обновлено', + 'reservations.toast.removed': 'Бронирование удалено', + 'reservations.toast.fileUploaded': 'Файл загружен', + 'reservations.toast.uploadError': 'Ошибка загрузки', + 'reservations.newTitle': 'Новое бронирование', + 'reservations.bookingType': 'Тип бронирования', + 'reservations.titleLabel': 'Название', + 'reservations.titlePlaceholder': 'напр. Lufthansa LH123, Hotel Adlon, ...', + 'reservations.locationAddress': 'Местоположение / Адрес', + 'reservations.locationPlaceholder': 'Адрес, аэропорт, отель...', + 'reservations.confirmationCode': 'Код бронирования', + 'reservations.confirmationPlaceholder': 'напр. ABC12345', + 'reservations.day': 'День', + 'reservations.noDay': 'Без дня', + 'reservations.place': 'Место', + 'reservations.noPlace': 'Без места', + 'reservations.pendingSave': 'будет сохранено…', + 'reservations.uploading': 'Загрузка...', + 'reservations.attachFile': 'Прикрепить файл', + 'reservations.linkExisting': 'Привязать существующий файл', + 'reservations.toast.saveError': 'Ошибка сохранения', + 'reservations.toast.updateError': 'Ошибка обновления', + 'reservations.toast.deleteError': 'Ошибка удаления', + 'reservations.confirm.remove': 'Удалить бронирование для «{name}»?', + 'reservations.linkAssignment': 'Привязать к назначению дня', + 'reservations.pickAssignment': 'Выберите назначение из вашего плана...', + 'reservations.noAssignment': 'Без привязки (самостоятельное)', + 'reservations.price': 'Цена', + 'reservations.budgetCategory': 'Категория бюджета', + 'reservations.budgetCategoryPlaceholder': 'напр. Транспорт, Проживание', + 'reservations.budgetCategoryAuto': 'Авто (по типу бронирования)', + 'reservations.budgetHint': + 'При сохранении будет автоматически создана запись бюджета.', + 'reservations.departureDate': 'Вылет', + 'reservations.arrivalDate': 'Прилёт', + 'reservations.departureTime': 'Время вылета', + 'reservations.arrivalTime': 'Время прилёта', + 'reservations.pickupDate': 'Получение', + 'reservations.returnDate': 'Возврат', + 'reservations.pickupTime': 'Время получения', + 'reservations.returnTime': 'Время возврата', + 'reservations.endDate': 'Дата окончания', + 'reservations.meta.departureTimezone': 'TZ вылета', + 'reservations.meta.arrivalTimezone': 'TZ прилёта', + 'reservations.span.departure': 'Вылет', + 'reservations.span.arrival': 'Прилёт', + 'reservations.span.inTransit': 'В пути', + 'reservations.span.pickup': 'Получение', + 'reservations.span.return': 'Возврат', + 'reservations.span.active': 'Активно', + 'reservations.span.start': 'Начало', + 'reservations.span.end': 'Конец', + 'reservations.span.ongoing': 'Продолжается', + 'reservations.validation.endBeforeStart': + 'Дата/время окончания должны быть позже даты/времени начала', + 'reservations.addBooking': 'Добавить бронирование', + 'reservations.import.title': 'Импорт подтверждений бронирования', + 'reservations.import.cta': 'Импортировать из файла', + 'reservations.import.dropHere': 'Перетащите файлы подтверждений бронирования сюда или нажмите для выбора', + 'reservations.import.dropActive': 'Отпустите файлы для импорта', + 'reservations.import.acceptedFormats': 'Принимаются: EML, PDF, PKPass, HTML, TXT (макс. 10 МБ каждый, до 5 файлов)', + 'reservations.import.parsing': 'Обработка файлов…', + 'reservations.import.previewHeading': 'Найдено {count} бронирование(й)', + 'reservations.import.previewEmpty': 'Из загруженных файлов не удалось извлечь бронирования.', + 'reservations.import.removeItem': 'Удалить', + 'reservations.import.confirm': 'Импортировать {count} бронирование(й)', + 'reservations.import.back': 'Назад', + 'reservations.import.success': '{count} бронирование(й) импортировано', + 'reservations.import.partialFailure': '{created} импортировано, {failed} не удалось', + 'reservations.import.error': 'Обработка не удалась. Убедитесь, что файл является действительным подтверждением бронирования.', + 'reservations.import.unavailable': 'Импорт бронирований недоступен на этом сервере.', + 'reservations.import.unsupportedFormat': 'Неподдерживаемый формат файла. Используйте EML, PDF, PKPass, HTML или TXT.', + 'reservations.import.fileTooLarge': 'Файл «{name}» превышает ограничение в 10 МБ.', + 'reservations.airtrail.title': 'Импорт из AirTrail', + 'reservations.airtrail.cta': 'AirTrail', + 'reservations.airtrail.synced': 'AirTrail', + 'reservations.airtrail.syncedHint': 'Синхронизировано с AirTrail — изменения синхронизируются в обе стороны.', + 'reservations.airtrail.notSynced': 'Не синхронизировано', + 'reservations.airtrail.notSyncedHint': 'Этот рейс был удалён в AirTrail и больше не синхронизируется.', + 'reservations.airtrail.loadError': 'Не удалось загрузить ваши рейсы из AirTrail.', + 'reservations.airtrail.imported': 'Импортировано рейсов: {count}', + 'reservations.airtrail.skippedDuplicate': '{count} уже в этой поездке, пропущено', + 'reservations.airtrail.nothingImported': 'Нечего импортировать.', + 'reservations.airtrail.importError': 'Импорт не удался. Повторите попытку.', + 'reservations.airtrail.undo': 'Импорт из AirTrail', + 'reservations.airtrail.alreadyImported': 'Импортировано', + 'reservations.airtrail.duringTrip': 'Во время этой поездки', + 'reservations.airtrail.otherFlights': 'Другие рейсы', + 'reservations.airtrail.empty': 'В вашей учётной записи AirTrail не найдено рейсов.', + 'reservations.airtrail.importCta': 'Импортировать {count}', +}; +export default reservations; diff --git a/shared/src/i18n/ru/settings.ts b/shared/src/i18n/ru/settings.ts new file mode 100644 index 0000000000000000000000000000000000000000..ac02578f75681e01458af9e6d8353bae121478bd --- /dev/null +++ b/shared/src/i18n/ru/settings.ts @@ -0,0 +1,345 @@ +import type { TranslationStrings } from '../types'; + +const settings: TranslationStrings = { + 'settings.title': 'Настройки', + 'settings.subtitle': 'Настройте свои персональные параметры', + 'settings.tabs.display': 'Дисплей', + 'settings.tabs.map': 'Карта', + 'settings.tabs.notifications': 'Уведомления', + 'settings.tabs.integrations': 'Интеграции', + 'settings.tabs.account': 'Аккаунт', + 'settings.tabs.offline': 'Offline', + 'settings.tabs.about': 'О приложении', + 'settings.map': 'Карта', + 'settings.mapTemplate': 'Шаблон карты', + 'settings.mapTemplatePlaceholder.select': 'Выберите шаблон...', + 'settings.mapDefaultHint': 'Оставьте пустым для OpenStreetMap (по умолчанию)', + 'settings.mapTemplatePlaceholder': + 'https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', + 'settings.mapHint': 'URL-шаблон для тайлов карты', + 'settings.mapProvider': 'Провайдер карты', + 'settings.mapProviderHint': + 'Применяется к Trip Planner и Journey. Atlas всегда использует Leaflet.', + 'settings.mapLeafletSubtitle': 'Классические 2D, любые растровые тайлы', + 'settings.mapMapboxSubtitle': 'Векторные тайлы, 3D-здания и рельеф', + 'settings.mapExperimental': 'Экспериментально', + 'settings.mapMapboxToken': 'Токен доступа Mapbox', + 'settings.mapMapboxTokenHint': 'Публичный токен (pk.*) с', + 'settings.mapMapboxTokenLink': 'mapbox.com → Токены доступа', + 'settings.mapStyle': 'Стиль карты', + 'settings.mapStylePlaceholder': 'Выберите стиль Mapbox', + 'settings.mapStyleHint': 'Preset или собственный URL mapbox://styles/USER/ID', + 'settings.map3dBuildings': '3D-здания и рельеф', + 'settings.map3dHint': + 'Наклон + настоящие 3D-здания — работает со всеми стилями, включая спутник.', + 'settings.mapHighQuality': 'Режим высокого качества', + 'settings.mapHighQualityHint': + 'Сглаживание + проекция глобуса для более чётких краёв и реалистичного вида мира.', + 'settings.mapHighQualityWarning': + 'Может повлиять на производительность на слабых устройствах.', + 'settings.mapTipLabel': 'Совет:', + 'settings.mapTip': + 'Зажмите правую кнопку мыши и перетащите, чтобы повернуть/наклонить карту. Клик средней кнопкой — добавить место (правая кнопка зарезервирована для вращения).', + 'settings.latitude': 'Широта', + 'settings.longitude': 'Долгота', + 'settings.saveMap': 'Сохранить карту', + 'settings.apiKeys': 'API-ключи', + 'settings.mapsKey': 'API-ключ Google Maps', + 'settings.mapsKeyHint': + 'Для поиска мест. Требуется Places API (New). Получите на console.cloud.google.com', + 'settings.weatherKey': 'API-ключ OpenWeatherMap', + 'settings.weatherKeyHint': + 'Для данных о погоде. Бесплатно на openweathermap.org/api', + 'settings.keyPlaceholder': 'Введите ключ...', + 'settings.configured': 'Настроено', + 'settings.saveKeys': 'Сохранить ключи', + 'settings.display': 'Отображение', + 'settings.colorMode': 'Цветовая схема', + 'settings.light': 'Светлая', + 'settings.dark': 'Тёмная', + 'settings.auto': 'Авто', + 'settings.language': 'Язык', + 'settings.temperature': 'Единица температуры', + 'settings.timeFormat': 'Формат времени', + 'settings.blurBookingCodes': 'Скрыть коды бронирования', + 'settings.optimizeFromAccommodation': 'Оптимизировать маршрут от места проживания', + 'settings.optimizeFromAccommodationHint': + 'При оптимизации дня маршрут начинается от отеля, в котором вы просыпаетесь, и заканчивается у того, в который вы заселяетесь вечером.', + 'settings.notifications': 'Уведомления', + 'settings.notifyTripInvite': 'Приглашения в поездку', + 'settings.notifyBookingChange': 'Изменения бронирований', + 'settings.notifyTripReminder': 'Напоминания о поездке', + 'settings.notifyTodoDue': 'Задача к сроку', + 'settings.notifyVacayInvite': 'Приглашения слияния Vacay', + 'settings.notifyPhotosShared': 'Общие фото (Immich)', + 'settings.notifyCollabMessage': 'Сообщения чата (Collab)', + 'settings.notifyPackingTagged': 'Список вещей: назначения', + 'settings.notifyWebhook': 'Webhook-уведомления', + 'settings.notificationsDisabled': + 'Уведомления не настроены. Попросите администратора включить уведомления по электронной почте или webhook.', + 'settings.notificationsActive': 'Активный канал', + 'settings.notificationsManagedByAdmin': + 'События уведомлений настраиваются администратором.', + 'settings.on': 'Вкл.', + 'settings.off': 'Выкл.', + 'settings.mcp.title': 'Настройка MCP', + 'settings.mcp.endpoint': 'MCP-эндпоинт', + 'settings.mcp.clientConfig': 'Конфигурация клиента', + 'settings.mcp.clientConfigHint': + 'Замените на API-токен из списка ниже. Путь к npx может потребовать настройки для вашей системы (например, C:\\PROGRA~1\\nodejs\\npx.cmd в Windows).', + 'settings.mcp.clientConfigHintOAuth': + 'Замените и на учётные данные из созданного выше клиента OAuth 2.1. При первом подключении mcp-remote откроет браузер для завершения авторизации. Путь к npx может потребовать настройки для вашей системы (например, C:\\PROGRA~1\\nodejs\\npx.cmd в Windows).', + 'settings.mcp.copy': 'Копировать', + 'settings.mcp.copied': 'Скопировано!', + 'settings.mcp.apiTokens': 'API-токены', + 'settings.mcp.createToken': 'Создать токен', + 'settings.mcp.noTokens': + 'Токенов пока нет. Создайте один для подключения MCP-клиентов.', + 'settings.mcp.tokenCreatedAt': 'Создан', + 'settings.mcp.tokenUsedAt': 'Использован', + 'settings.mcp.deleteTokenTitle': 'Удалить токен', + 'settings.mcp.deleteTokenMessage': + 'Этот токен перестанет работать немедленно. Любой MCP-клиент, использующий его, потеряет доступ.', + 'settings.mcp.modal.createTitle': 'Создать API-токен', + 'settings.mcp.modal.tokenName': 'Название токена', + 'settings.mcp.modal.tokenNamePlaceholder': + 'напр. Claude Desktop, Рабочий ноутбук', + 'settings.mcp.modal.creating': 'Создание…', + 'settings.mcp.modal.create': 'Создать токен', + 'settings.mcp.modal.createdTitle': 'Токен создан', + 'settings.mcp.modal.createdWarning': + 'Этот токен будет показан только один раз. Скопируйте и сохраните его сейчас — восстановить его будет невозможно.', + 'settings.mcp.modal.done': 'Готово', + 'settings.mcp.toast.created': 'Токен создан', + 'settings.mcp.toast.createError': 'Не удалось создать токен', + 'settings.mcp.toast.deleted': 'Токен удалён', + 'settings.mcp.toast.deleteError': 'Не удалось удалить токен', + 'settings.mcp.apiTokensDeprecated': + 'API-токены устарели и будут удалены в будущей версии. Пожалуйста, используйте клиенты OAuth 2.1.', + 'settings.oauth.clients': 'Клиенты OAuth 2.1', + 'settings.oauth.clientsHint': + 'Зарегистрируйте клиенты OAuth 2.1, чтобы сторонние MCP-приложения (Claude Web, Cursor и др.) могли подключаться без статических токенов.', + 'settings.oauth.createClient': 'Новый клиент', + 'settings.oauth.noClients': 'Нет зарегистрированных клиентов OAuth.', + 'settings.oauth.clientId': 'ID клиента', + 'settings.oauth.clientSecret': 'Секрет клиента', + 'settings.oauth.deleteClient': 'Удалить клиента', + 'settings.oauth.deleteClientMessage': + 'Этот клиент и все активные сессии будут удалены навсегда. Любое приложение, использующее его, немедленно потеряет доступ.', + 'settings.oauth.rotateSecret': 'Обновить секрет', + 'settings.oauth.rotateSecretMessage': + 'Будет сгенерирован новый секрет клиента, а все существующие сессии будут немедленно аннулированы. Обновите приложение перед закрытием этого диалога.', + 'settings.oauth.rotateSecretConfirm': 'Обновить', + 'settings.oauth.rotateSecretConfirming': 'Обновление…', + 'settings.oauth.rotateSecretDoneTitle': 'Новый секрет сгенерирован', + 'settings.oauth.rotateSecretDoneWarning': + 'Этот секрет отображается только один раз. Скопируйте его сейчас и обновите приложение — все предыдущие сессии были аннулированы.', + 'settings.oauth.activeSessions': 'Активные сессии OAuth', + 'settings.oauth.sessionScopes': 'Области доступа', + 'settings.oauth.sessionExpires': 'Истекает', + 'settings.oauth.revoke': 'Отозвать', + 'settings.oauth.revokeSession': 'Отозвать сессию', + 'settings.oauth.revokeSessionMessage': + 'Это немедленно отзовёт доступ для данной сессии OAuth.', + 'settings.oauth.modal.createTitle': 'Зарегистрировать клиент OAuth', + 'settings.oauth.modal.presets': 'Быстрые настройки', + 'settings.oauth.modal.clientName': 'Название приложения', + 'settings.oauth.modal.clientNamePlaceholder': + 'напр. Claude Web, Моё MCP-приложение', + 'settings.oauth.modal.redirectUris': 'URI перенаправления', + 'settings.oauth.modal.redirectUrisPlaceholder': + 'https://your-app.com/callback\nhttps://your-app.com/auth', + 'settings.oauth.modal.redirectUrisHint': + 'Один URI на строку. Требуется HTTPS (localhost исключён). Требуется точное совпадение.', + 'settings.oauth.modal.scopes': 'Разрешённые области доступа', + 'settings.oauth.modal.scopesHint': + 'list_trips и get_trip_summary всегда доступны — область не требуется. Они помогают ИИ находить нужные ID поездок.', + 'settings.oauth.modal.selectAll': 'Выбрать все', + 'settings.oauth.modal.deselectAll': 'Снять выбор', + 'settings.oauth.modal.creating': 'Регистрация…', + 'settings.oauth.modal.create': 'Зарегистрировать клиента', + 'settings.oauth.modal.createdTitle': 'Клиент зарегистрирован', + 'settings.oauth.modal.createdWarning': + 'Секрет клиента отображается только один раз. Скопируйте его сейчас — его нельзя будет восстановить.', + 'settings.oauth.toast.createError': + 'Не удалось зарегистрировать клиент OAuth', + 'settings.oauth.toast.deleted': 'Клиент OAuth удалён', + 'settings.oauth.toast.deleteError': 'Не удалось удалить клиент OAuth', + 'settings.oauth.toast.revoked': 'Сессия отозвана', + 'settings.oauth.toast.revokeError': 'Не удалось отозвать сессию', + 'settings.oauth.toast.rotateError': 'Не удалось обновить секрет клиента', + 'settings.oauth.modal.machineClient': + 'Машинный клиент (без входа через браузер)', + 'settings.oauth.modal.machineClientHint': + 'Использует грант client_credentials — URI перенаправления не требуются. Токен выдаётся напрямую через client_id + client_secret и действует от вашего имени в пределах выбранных областей.', + 'settings.oauth.modal.machineClientUsage': + 'Получить токен: POST /oauth/token с grant_type=client_credentials, client_id и client_secret. Без браузера, без токена обновления.', + 'settings.oauth.badge.machine': 'машинный', + 'settings.account': 'Аккаунт', + 'settings.about': 'О приложении', + 'settings.about.reportBug': 'Сообщить об ошибке', + 'settings.about.reportBugHint': 'Нашли проблему? Сообщите нам', + 'settings.about.featureRequest': 'Предложить функцию', + 'settings.about.featureRequestHint': 'Предложите новую функцию', + 'settings.about.wikiHint': 'Документация и руководства', + 'settings.about.supporters.badge': 'Ежемесячные спонсоры', + 'settings.about.supporters.title': 'Спутники TREK', + 'settings.about.supporters.subtitle': + 'Пока ты планируешь следующий маршрут, эти люди планируют вместе со мной будущее TREK. Их ежемесячный взнос идёт напрямую в разработку и реально потраченные часы — чтобы TREK оставался Open Source.', + 'settings.about.supporters.since': 'спонсор с {date}', + 'settings.about.supporters.tierEmpty': 'Стань первым', + 'settings.about.supporter.tier.noReturnTicket': 'No Return Ticket', + 'settings.about.supporter.tier.lostLuggageVip': 'Lost Luggage VIP', + 'settings.about.supporter.tier.businessClassDreamer': + 'Business Class Dreamer', + 'settings.about.supporter.tier.budgetTraveller': 'Budget Traveller', + 'settings.about.supporter.tier.hostelBunkmate': 'Hostel Bunkmate', + 'settings.about.description': + 'TREK — это самостоятельно размещаемый планировщик путешествий, который помогает организовать поездки от первой идеи до последнего воспоминания. Планирование по дням, бюджет, списки вещей, фото и многое другое — всё в одном месте, на вашем собственном сервере.', + 'settings.about.madeWith': 'Сделано с', + 'settings.about.madeBy': 'Морисом и растущим open-source сообществом.', + 'settings.username': 'Имя пользователя', + 'settings.email': 'Эл. почта', + 'settings.role': 'Роль', + 'settings.roleAdmin': 'Администратор', + 'settings.oidcLinked': 'Связан с', + 'settings.changePassword': 'Изменить пароль', + 'settings.mustChangePassword': + 'Вы должны сменить пароль перед продолжением. Пожалуйста, установите новый пароль ниже.', + 'settings.currentPassword': 'Текущий пароль', + 'settings.currentPasswordRequired': 'Текущий пароль обязателен', + 'settings.newPassword': 'Новый пароль', + 'settings.confirmPassword': 'Подтвердите новый пароль', + 'settings.updatePassword': 'Обновить пароль', + 'settings.passwordRequired': 'Введите текущий и новый пароль', + 'settings.passwordTooShort': 'Пароль должен содержать не менее 8 символов', + 'settings.passwordMismatch': 'Пароли не совпадают', + 'settings.passwordWeak': + 'Пароль должен содержать заглавные, строчные буквы, цифру и специальный символ', + 'settings.passwordChanged': 'Пароль успешно изменён', + 'settings.deleteAccount': 'Удалить аккаунт', + 'settings.deleteAccountTitle': 'Удалить ваш аккаунт?', + 'settings.deleteAccountWarning': + 'Ваш аккаунт и все поездки, места и файлы будут безвозвратно удалены. Это действие нельзя отменить.', + 'settings.deleteAccountConfirm': 'Удалить безвозвратно', + 'settings.deleteBlockedTitle': 'Удаление невозможно', + 'settings.deleteBlockedMessage': + 'Вы единственный администратор. Назначьте другого пользователя администратором перед удалением своего аккаунта.', + 'settings.roleUser': 'Пользователь', + 'settings.saveProfile': 'Сохранить профиль', + 'settings.mfa.title': 'Двухфакторная аутентификация (2FA)', + 'settings.mfa.description': + 'Добавляет второй шаг при входе. Используйте приложение-аутентификатор (Google Authenticator, Authy и др.).', + 'settings.mfa.requiredByPolicy': + 'Администратор требует двухфакторную аутентификацию. Настройте приложение-аутентификатор ниже, прежде чем продолжить.', + 'settings.mfa.backupTitle': 'Резервные коды', + 'settings.mfa.backupDescription': + 'Используйте эти одноразовые коды, если потеряете доступ к приложению-аутентификатору.', + 'settings.mfa.backupWarning': + 'Сохраните их сейчас. Каждый код можно использовать только один раз.', + 'settings.mfa.backupCopy': 'Скопировать коды', + 'settings.mfa.backupDownload': 'Скачать TXT', + 'settings.mfa.backupPrint': 'Печать / PDF', + 'settings.mfa.backupCopied': 'Резервные коды скопированы', + 'settings.mfa.enabled': '2FA включена для вашего аккаунта.', + 'settings.mfa.disabled': '2FA не включена.', + 'settings.mfa.setup': 'Настроить аутентификатор', + 'settings.mfa.scanQr': + 'Отсканируйте QR-код приложением или введите ключ вручную.', + 'settings.mfa.secretLabel': 'Секретный ключ (ручной ввод)', + 'settings.mfa.codePlaceholder': '6-значный код', + 'settings.mfa.enable': 'Включить 2FA', + 'settings.mfa.cancelSetup': 'Отмена', + 'settings.mfa.disableTitle': 'Отключить 2FA', + 'settings.mfa.disableHint': + 'Введите пароль аккаунта и текущий код из аутентификатора.', + 'settings.mfa.disable': 'Отключить 2FA', + 'settings.mfa.toastEnabled': 'Двухфакторная аутентификация включена', + 'settings.mfa.toastDisabled': 'Двухфакторная аутентификация отключена', + 'settings.mfa.demoBlocked': 'Недоступно в демо-режиме', + 'settings.toast.mapSaved': 'Настройки карты сохранены', + 'settings.toast.keysSaved': 'API-ключи сохранены', + 'settings.toast.displaySaved': 'Настройки отображения сохранены', + 'settings.toast.profileSaved': 'Профиль сохранён', + 'settings.uploadAvatar': 'Загрузить фото профиля', + 'settings.removeAvatar': 'Удалить фото профиля', + 'settings.avatarUploaded': 'Фото профиля обновлено', + 'settings.avatarRemoved': 'Фото профиля удалено', + 'settings.avatarError': 'Ошибка загрузки', + 'settings.bookingLabels': 'Подписи маршрутов бронирований', + 'settings.bookingLabelsHint': + 'Отображает названия станций / аэропортов на карте. Если выключено, показывается только значок.', + 'settings.notifyVersionAvailable': 'Доступна новая версия', + 'settings.notificationPreferences.noChannels': + 'Каналы уведомлений не настроены. Попросите администратора настроить уведомления по электронной почте или через webhook.', + 'settings.webhookUrl.label': 'URL вебхука', + 'settings.webhookUrl.placeholder': 'https://discord.com/api/webhooks/...', + 'settings.webhookUrl.hint': + 'Введите URL вашего вебхука Discord, Slack или пользовательского для получения уведомлений.', + 'settings.webhookUrl.saved': 'URL вебхука сохранён', + 'settings.webhookUrl.test': 'Тест', + 'settings.webhookUrl.testSuccess': 'Тестовый вебхук успешно отправлен', + 'settings.webhookUrl.testFailed': 'Ошибка тестового вебхука', + 'settings.ntfyUrl.topicLabel': 'Тема Ntfy', + 'settings.ntfyUrl.topicPlaceholder': 'my-trek-alerts', + 'settings.ntfyUrl.serverLabel': 'URL сервера Ntfy (необязательно)', + 'settings.ntfyUrl.serverPlaceholder': 'https://ntfy.sh', + 'settings.ntfyUrl.hint': + 'Введите тему Ntfy для получения push-уведомлений. Оставьте поле сервера пустым, чтобы использовать настройку по умолчанию, заданную администратором.', + 'settings.ntfyUrl.tokenLabel': 'Токен доступа (необязательно)', + 'settings.ntfyUrl.tokenHint': 'Требуется для тем, защищённых паролем.', + 'settings.ntfyUrl.saved': 'Настройки Ntfy сохранены', + 'settings.ntfyUrl.test': 'Тест', + 'settings.ntfyUrl.testSuccess': + 'Тестовое уведомление Ntfy успешно отправлено', + 'settings.ntfyUrl.testFailed': 'Ошибка отправки тестового уведомления Ntfy', + 'settings.ntfyUrl.tokenCleared': 'Токен доступа очищен', + 'settings.notificationPreferences.inapp': 'In-App', + 'settings.notificationPreferences.webhook': 'Webhook', + 'settings.notificationPreferences.email': 'Email', + 'settings.notificationPreferences.ntfy': 'Ntfy', + "settings.currency": "Currency", + "settings.currencyHint": "All amounts in Costs are converted to and shown in this currency.", + 'settings.passkey.title': 'Passkeys', + 'settings.passkey.description': + 'Входите быстрее и с защитой от фишинга с помощью passkey — отпечатка пальца, лица, PIN-кода или аппаратного ключа. Ваш пароль остаётся как резервный способ.', + 'settings.passkey.notConfigured': + 'Passkeys включены, но ещё не полностью настроены на этом сервере. Попросите администратора задать домен WebAuthn.', + 'settings.passkey.add': 'Добавить passkey', + 'settings.passkey.addTitle': 'Добавить passkey', + 'settings.passkey.passwordPrompt': + 'Подтвердите текущий пароль, затем следуйте подсказке на устройстве.', + 'settings.passkey.passwordRequired': 'Требуется ваш текущий пароль.', + 'settings.passkey.namePlaceholder': 'Название (необязательно, напр. "iPhone")', + 'settings.passkey.addedToast': 'Passkey добавлен', + 'settings.passkey.added': 'Добавлен', + 'settings.passkey.addError': 'Не удалось добавить passkey', + 'settings.passkey.cancelled': 'Настройка passkey отменена', + 'settings.passkey.deleted': 'Passkey удалён', + 'settings.passkey.deleteConfirm': 'Удалить этот passkey? Подтвердите паролем.', + 'settings.passkey.rename': 'Переименовать', + 'settings.passkey.defaultName': 'Passkey', + 'settings.passkey.synced': 'Синхронизирован', + 'settings.passkey.deviceBound': 'Это устройство', + 'settings.passkey.lastUsed': 'Последнее использование', + 'settings.passkey.neverUsed': 'Не использовался', + 'settings.mapPoiPill': 'Поиск мест на карте', + 'settings.mapPoiPillHint': 'Показывать на карте поездки кнопку категорий, чтобы находить рядом рестораны, отели и другие места из OpenStreetMap.', + 'settings.airtrail.title': 'AirTrail', + 'settings.airtrail.hint': 'Подключите свой self-hosted AirTrail для импорта и синхронизации рейсов. Создайте ключ API в AirTrail в разделе «Настройки → Безопасность».', + 'settings.airtrail.url': 'URL экземпляра', + 'settings.airtrail.apiKey': 'Ключ API', + 'settings.airtrail.apiKeyPlaceholder': 'Bearer-ключ API', + 'settings.airtrail.apiKeyHint': 'Создаётся в AirTrail в разделе «Настройки → Безопасность». Хранится в зашифрованном виде.', + 'settings.airtrail.allowInsecureTls': 'Разрешить самоподписанные сертификаты', + 'settings.airtrail.allowInsecureTlsHint': 'Включайте только для доверенного экземпляра в вашей собственной сети.', + 'settings.airtrail.connected': 'Подключено', + 'settings.airtrail.notConnected': 'Не подключено', + 'settings.airtrail.toast.saved': 'Подключение к AirTrail сохранено', + 'settings.airtrail.toast.saveError': 'Не удалось сохранить подключение', + 'settings.airtrail.test.button': 'Проверить подключение', + 'settings.airtrail.test.success': 'Подключено — найдено рейсов: {count}', + 'settings.airtrail.test.failed': 'Не удалось подключиться', +}; + +export default settings; diff --git a/shared/src/i18n/ru/share.ts b/shared/src/i18n/ru/share.ts new file mode 100644 index 0000000000000000000000000000000000000000..c1f10a58a77aa2c16d66e8781f6f004ff0bef13a --- /dev/null +++ b/shared/src/i18n/ru/share.ts @@ -0,0 +1,16 @@ +import type { TranslationStrings } from '../types'; + +const share: TranslationStrings = { + 'share.linkTitle': 'Публичная ссылка', + 'share.linkHint': + 'Создайте ссылку, по которой любой сможет просмотреть эту поездку без входа в систему. Только чтение — редактирование невозможно.', + 'share.createLink': 'Создать ссылку', + 'share.deleteLink': 'Удалить ссылку', + 'share.createError': 'Не удалось создать ссылку', + 'share.permMap': 'Карта и план', + 'share.permBookings': 'Бронирования', + 'share.permPacking': 'Вещи', + 'share.permBudget': 'Бюджет', + 'share.permCollab': 'Чат', +}; +export default share; diff --git a/shared/src/i18n/ru/shared.ts b/shared/src/i18n/ru/shared.ts new file mode 100644 index 0000000000000000000000000000000000000000..a792116dd01195985ab501e542a6f12af569883b --- /dev/null +++ b/shared/src/i18n/ru/shared.ts @@ -0,0 +1,21 @@ +import type { TranslationStrings } from '../types'; + +const shared: TranslationStrings = { + 'shared.expired': 'Ссылка устарела или недействительна', + 'shared.expiredHint': 'Эта ссылка на поездку больше не активна.', + 'shared.readOnly': 'Режим только для чтения', + 'shared.tabPlan': 'План', + 'shared.tabBookings': 'Бронирования', + 'shared.tabPacking': 'Багаж', + 'shared.tabBudget': 'Бюджет', + 'shared.tabChat': 'Чат', + 'shared.days': 'дней', + 'shared.places': 'мест', + 'shared.other': 'Прочее', + 'shared.totalBudget': 'Общий бюджет', + 'shared.messages': 'сообщений', + 'shared.sharedVia': 'Поделено через', + 'shared.confirmed': 'Подтверждено', + 'shared.pending': 'Ожидает', +}; +export default shared; diff --git a/shared/src/i18n/ru/stats.ts b/shared/src/i18n/ru/stats.ts new file mode 100644 index 0000000000000000000000000000000000000000..405a51f16b62dd46bd71389132ae75ad5318a3b6 --- /dev/null +++ b/shared/src/i18n/ru/stats.ts @@ -0,0 +1,13 @@ +import type { TranslationStrings } from '../types'; + +const stats: TranslationStrings = { + 'stats.countries': 'Страны', + 'stats.cities': 'Города', + 'stats.trips': 'Поездки', + 'stats.places': 'Места', + 'stats.worldProgress': 'Прогресс по миру', + 'stats.visited': 'посещено', + 'stats.remaining': 'осталось', + 'stats.visitedCountries': 'Посещённые страны', +}; +export default stats; diff --git a/shared/src/i18n/ru/system_notice.ts b/shared/src/i18n/ru/system_notice.ts new file mode 100644 index 0000000000000000000000000000000000000000..30d29b557b55a88145b0e6e5f3e84da8bcd5a0f6 --- /dev/null +++ b/shared/src/i18n/ru/system_notice.ts @@ -0,0 +1,59 @@ +import type { TranslationStrings } from '../types'; + +const system_notice: TranslationStrings = { + 'system_notice.welcome_v1.title': 'Добро пожаловать в TREK', + 'system_notice.welcome_v1.body': + 'Ваш универсальный планировщик путешествий. Создавайте маршруты, делитесь поездками с друзьями и оставайтесь организованными — онлайн и офлайн.', + 'system_notice.welcome_v1.cta_label': 'Спланировать поездку', + 'system_notice.welcome_v1.hero_alt': + 'Живописное место назначения с интерфейсом TREK', + 'system_notice.welcome_v1.highlight_plan': 'Маршруты по дням', + 'system_notice.welcome_v1.highlight_share': + 'Совместное планирование с партнёрами', + 'system_notice.welcome_v1.highlight_offline': 'Работает офлайн на мобильном', + 'system_notice.dev_test_modal.title': '[Dev] Test notice', + 'system_notice.dev_test_modal.body': 'This is a dev-only test notice.', + 'system_notice.pager.prev': 'Предыдущее уведомление', + 'system_notice.pager.next': 'Следующее уведомление', + 'system_notice.pager.counter': '{current} / {total}', + 'system_notice.pager.goto': 'Перейти к уведомлению {n}', + 'system_notice.pager.position': 'Уведомление {current} из {total}', + 'system_notice.v3_photos.title': 'Фото перемещены в версии 3.0', + 'system_notice.v3_photos.body': + 'Вкладка **Фото** в Планировщике путешествий удалена. Ваши фото в безопасности — TREK никогда не изменял вашу библиотеку Immich или Synology.\n\nФото теперь доступны в дополнении **Journey**. Journey необязателен — если он ещё недоступен, попросите администратора включить его в разделе Admin → Дополнения.', + 'system_notice.v3_journey.title': 'Знакомьтесь с Journey', + 'system_notice.v3_journey.body': + 'Документируйте путешествия в виде рассказов с хронологиями, фотогалереями и интерактивными картами.', + 'system_notice.v3_journey.cta_label': 'Открыть Journey', + 'system_notice.v3_journey.highlight_timeline': + 'Ежедневная хронология и галерея', + 'system_notice.v3_journey.highlight_photos': 'Импорт из Immich или Synology', + 'system_notice.v3_journey.highlight_share': 'Общий доступ — без входа', + 'system_notice.v3_journey.highlight_export': 'Экспорт в PDF-фотокнигу', + 'system_notice.v3_features.title': 'Ещё нового в версии 3.0', + 'system_notice.v3_features.body': + 'Несколько других важных новшеств в этом релизе.', + 'system_notice.v3_features.highlight_dashboard': + 'Переработанная панель в mobile-first стиле', + 'system_notice.v3_features.highlight_offline': 'Полный офлайн-режим как PWA', + 'system_notice.v3_features.highlight_search': + 'Автодополнение поиска мест в реальном времени', + 'system_notice.v3_features.highlight_import': 'Импорт мест из KMZ/KML-файлов', + 'system_notice.v3_mcp.title': 'MCP: обновление OAuth 2.1', + 'system_notice.v3_mcp.body': + 'Интеграция MCP была полностью переработана. OAuth 2.1 теперь является рекомендуемым методом аутентификации. Статические токены (trek_…) устарели и будут удалены в будущей версии.', + 'system_notice.v3_mcp.highlight_oauth': + 'OAuth 2.1 рекомендуется (mcp-remote)', + 'system_notice.v3_mcp.highlight_scopes': '24 детальных области разрешений', + 'system_notice.v3_mcp.highlight_deprecated': + 'Статические токены trek_ устарели', + 'system_notice.v3_mcp.highlight_tools': 'Расширенный набор инструментов', + 'system_notice.v3_thankyou.title': 'Личное слово от меня', + 'system_notice.v3_thankyou.body': + 'Прежде чем продолжить — хочу остановиться на мгновение.\n\nTREK начинался как сторонний проект, который я создал для собственных поездок. Я никогда не думал, что он вырастет во что-то, чему 4 000 из вас доверяют планирование своих приключений. Каждая звёздочка, каждый issue, каждый запрос на фичу — я читаю их все, и именно они поддерживают меня в поздние ночи между основной работой и университетом.\n\nХочу, чтобы вы знали: TREK всегда будет open source, всегда self-hosted, всегда вашим. Никакого отслеживания, никаких подписок, никаких подвохов. Просто инструмент, созданный человеком, который любит путешествовать так же, как и вы.\n\nОсобая благодарность [jubnl](https://github.com/jubnl) — ты стал невероятным соратником. Многое из того, что делает версию 3.0 великолепной, несёт твой отпечаток. Спасибо, что поверил в этот проект, когда он был ещё сырым.\n\nИ каждому из вас, кто сообщил об ошибке, перевёл строку, поделился TREK с другом или просто использовал его для планирования поездки — **спасибо**. Вы — причина, по которой всё это существует.\n\nЗа множество новых приключений вместе.\n\n— Maurice\n\n---\n\n[Присоединяйся к сообществу в Discord](https://discord.gg/7Q6M6jDwzf)\n\nЕсли TREK делает твои путешествия лучше, [маленький кофе](https://ko-fi.com/mauriceboe) всегда помогает держать свет включённым.', + 'system_notice.v3014_whitespace_collision.title': + 'Требуется действие: конфликт учётных записей', + 'system_notice.v3014_whitespace_collision.body': + 'Обновление 3.0.14 обнаружило один или несколько конфликтов имён пользователей или адресов электронной почты, вызванных ведущими или завершающими пробелами в сохранённых значениях. Затронутые учётные записи были автоматически переименованы. Проверьте логи сервера на строки, начинающиеся с **[migration] WHITESPACE COLLISION**, чтобы определить учётные записи, требующие проверки.', +}; +export default system_notice; diff --git a/shared/src/i18n/ru/todo.ts b/shared/src/i18n/ru/todo.ts new file mode 100644 index 0000000000000000000000000000000000000000..036631e3dc3cc0172425d523fd5fc2e791e5ecf1 --- /dev/null +++ b/shared/src/i18n/ru/todo.ts @@ -0,0 +1,40 @@ +import type { TranslationStrings } from '../types'; + +const todo: TranslationStrings = { + 'todo.subtab.packing': 'Список вещей', + 'todo.subtab.todo': 'Задачи', + 'todo.completed': 'выполнено', + 'todo.filter.all': 'Все', + 'todo.filter.open': 'Открытые', + 'todo.filter.done': 'Выполненные', + 'todo.uncategorized': 'Без категории', + 'todo.namePlaceholder': 'Название задачи', + 'todo.descriptionPlaceholder': 'Описание (необязательно)', + 'todo.unassigned': 'Не назначено', + 'todo.noCategory': 'Без категории', + 'todo.hasDescription': 'Есть описание', + 'todo.addItem': 'Новая задача', + 'todo.sidebar.sortBy': 'Сортировать по', + 'todo.priority': 'Приоритет', + 'todo.newCategoryLabel': 'новая', + 'todo.newCategory': 'Название категории', + 'todo.addCategory': 'Добавить категорию', + 'todo.newItem': 'Новая задача', + 'todo.empty': 'Задач пока нет. Добавьте задачу, чтобы начать!', + 'todo.filter.my': 'Мои задачи', + 'todo.filter.overdue': 'Просроченные', + 'todo.sidebar.tasks': 'Задачи', + 'todo.sidebar.categories': 'Категории', + 'todo.detail.title': 'Задача', + 'todo.detail.description': 'Описание', + 'todo.detail.category': 'Категория', + 'todo.detail.dueDate': 'Срок выполнения', + 'todo.detail.assignedTo': 'Назначено', + 'todo.detail.delete': 'Удалить', + 'todo.detail.save': 'Сохранить изменения', + 'todo.detail.create': 'Создать задачу', + 'todo.detail.priority': 'Приоритет', + 'todo.detail.noPriority': 'Нет', + 'todo.sortByPrio': 'Приоритет', +}; +export default todo; diff --git a/shared/src/i18n/ru/transport.ts b/shared/src/i18n/ru/transport.ts new file mode 100644 index 0000000000000000000000000000000000000000..3986a437add10765059b565f258a643f0d2157e7 --- /dev/null +++ b/shared/src/i18n/ru/transport.ts @@ -0,0 +1,10 @@ +import type { TranslationStrings } from '../types'; + +const transport: TranslationStrings = { + 'transport.addTransport': 'Добавить транспорт', + 'transport.modalTitle.create': 'Добавить транспорт', + 'transport.modalTitle.edit': 'Изменить транспорт', + 'transport.title': 'Транспорт', + 'transport.addManual': 'Ручной транспорт', +}; +export default transport; diff --git a/shared/src/i18n/ru/trip.ts b/shared/src/i18n/ru/trip.ts new file mode 100644 index 0000000000000000000000000000000000000000..a56ff1f10d9bbd001faa7bf47e1da8d71d57b36e --- /dev/null +++ b/shared/src/i18n/ru/trip.ts @@ -0,0 +1,31 @@ +import type { TranslationStrings } from '../types'; + +const trip: TranslationStrings = { + 'trip.tabs.plan': 'План', + 'trip.tabs.transports': 'Транспорт', + 'trip.tabs.reservations': 'Бронирования', + 'trip.tabs.reservationsShort': 'Брони', + 'trip.tabs.packing': 'Список вещей', + 'trip.tabs.packingShort': 'Вещи', + 'trip.tabs.lists': 'Списки', + 'trip.tabs.listsShort': 'Списки', + 'trip.tabs.budget': "Costs", + 'trip.tabs.files': 'Файлы', + 'trip.loading': 'Загрузка поездки...', + 'trip.loadingPhotos': 'Загрузка фото мест...', + 'trip.mobilePlan': 'План', + 'trip.mobilePlaces': 'Места', + 'trip.toast.placeUpdated': 'Место обновлено', + 'trip.toast.placeAdded': 'Место добавлено', + 'trip.toast.placeDeleted': 'Место удалено', + 'trip.toast.selectDay': 'Сначала выберите день', + 'trip.toast.assignedToDay': 'Место назначено на день', + 'trip.toast.reorderError': 'Ошибка изменения порядка', + 'trip.toast.reservationUpdated': 'Бронирование обновлено', + 'trip.toast.reservationAdded': 'Бронирование добавлено', + 'trip.toast.deleted': 'Удалено', + 'trip.confirm.deletePlace': 'Вы уверены, что хотите удалить это место?', + 'trip.confirm.deletePlaces': 'Удалить {count} мест?', + 'trip.toast.placesDeleted': '{count} мест удалено', +}; +export default trip; diff --git a/shared/src/i18n/ru/trips.ts b/shared/src/i18n/ru/trips.ts new file mode 100644 index 0000000000000000000000000000000000000000..e129f5f9564368ee61694f2a03d6276c8e3cb308 --- /dev/null +++ b/shared/src/i18n/ru/trips.ts @@ -0,0 +1,17 @@ +import type { TranslationStrings } from '../types'; + +const trips: TranslationStrings = { + 'trips.memberRemoved': '{username} удалён', + 'trips.memberRemoveError': 'Не удалось удалить', + 'trips.memberAdded': '{username} добавлен', + 'trips.memberAddError': 'Не удалось добавить', + 'trips.reminder': 'Напоминание', + 'trips.reminderNone': 'Нет', + 'trips.reminderDay': 'день', + 'trips.reminderDays': 'дней', + 'trips.reminderCustom': 'Другое', + 'trips.reminderDaysBefore': 'дней до отъезда', + 'trips.reminderDisabledHint': + 'Напоминания о поездках отключены. Включите их в Админ > Настройки > Уведомления.', +}; +export default trips; diff --git a/shared/src/i18n/ru/undo.ts b/shared/src/i18n/ru/undo.ts new file mode 100644 index 0000000000000000000000000000000000000000..377156a58711313762b9387571fcab7f4e20012f --- /dev/null +++ b/shared/src/i18n/ru/undo.ts @@ -0,0 +1,22 @@ +import type { TranslationStrings } from '../types'; + +const undo: TranslationStrings = { + 'undo.button': 'Отменить', + 'undo.tooltip': 'Отменить: {action}', + 'undo.assignPlace': 'Место добавлено в день', + 'undo.removeAssignment': 'Место удалено из дня', + 'undo.reorder': 'Места переупорядочены', + 'undo.optimize': 'Маршрут оптимизирован', + 'undo.deletePlace': 'Место удалено', + 'undo.deletePlaces': 'Места удалены', + 'undo.moveDay': 'Место перемещено в другой день', + 'undo.lock': 'Блокировка места изменена', + 'undo.importGpx': 'Импорт GPX', + 'undo.importKeyholeMarkup': 'Импорт KMZ/KML', + 'undo.importGoogleList': 'Импорт из Google Maps', + 'undo.importNaverList': 'Импорт из Naver Maps', + 'undo.addPlace': 'Место добавлено', + 'undo.done': 'Отменено: {action}', + 'undo.importBooking': 'Импорт подтверждения бронирования', +}; +export default undo; diff --git a/shared/src/i18n/ru/vacay.ts b/shared/src/i18n/ru/vacay.ts new file mode 100644 index 0000000000000000000000000000000000000000..f9a1edccff3821c5187d6cfb6aee903fc1a7a556 --- /dev/null +++ b/shared/src/i18n/ru/vacay.ts @@ -0,0 +1,107 @@ +import type { TranslationStrings } from '../types'; + +const vacay: TranslationStrings = { + 'vacay.subtitle': 'Планируйте и управляйте днями отпуска', + 'vacay.settings': 'Настройки', + 'vacay.year': 'Год', + 'vacay.addYear': 'Добавить следующий год', + 'vacay.addPrevYear': 'Добавить предыдущий год', + 'vacay.removeYear': 'Удалить год', + 'vacay.removeYearConfirm': 'Удалить {year}?', + 'vacay.removeYearHint': + 'Все записи об отпуске и корпоративные выходные за этот год будут безвозвратно удалены.', + 'vacay.remove': 'Удалить', + 'vacay.persons': 'Люди', + 'vacay.noPersons': 'Никто не добавлен', + 'vacay.addPerson': 'Добавить человека', + 'vacay.editPerson': 'Редактировать', + 'vacay.removePerson': 'Удалить человека', + 'vacay.removePersonConfirm': 'Удалить {name}?', + 'vacay.removePersonHint': + 'Все записи об отпуске этого человека будут безвозвратно удалены.', + 'vacay.personName': 'Имя', + 'vacay.personNamePlaceholder': 'Введите имя', + 'vacay.color': 'Цвет', + 'vacay.add': 'Добавить', + 'vacay.legend': 'Легенда', + 'vacay.publicHoliday': 'Государственный праздник', + 'vacay.companyHoliday': 'Корпоративный выходной', + 'vacay.weekend': 'Выходные', + 'vacay.modeVacation': 'Отпуск', + 'vacay.modeCompany': 'Корпоративный выходной', + 'vacay.entitlement': 'Право на отпуск', + 'vacay.entitlementDays': 'Дни', + 'vacay.used': 'Использовано', + 'vacay.remaining': 'Осталось', + 'vacay.carriedOver': 'из {year}', + 'vacay.blockWeekends': 'Блокировать выходные', + 'vacay.blockWeekendsHint': + 'Запретить записи об отпуске в субботу и воскресенье', + 'vacay.weekendDays': 'Выходные дни', + 'vacay.mon': 'Пн', + 'vacay.tue': 'Вт', + 'vacay.wed': 'Ср', + 'vacay.thu': 'Чт', + 'vacay.fri': 'Пт', + 'vacay.sat': 'Сб', + 'vacay.sun': 'Вс', + 'vacay.publicHolidays': 'Государственные праздники', + 'vacay.publicHolidaysHint': 'Отмечать государственные праздники в календаре', + 'vacay.selectCountry': 'Выберите страну', + 'vacay.selectRegion': 'Выберите регион (необязательно)', + 'vacay.companyHolidays': 'Корпоративные выходные', + 'vacay.companyHolidaysHint': 'Разрешить отмечать корпоративные выходные дни', + 'vacay.companyHolidaysNoDeduct': + 'Корпоративные выходные не вычитаются из дней отпуска.', + 'vacay.weekStart': 'Неделя начинается с', + 'vacay.weekStartHint': + 'Выберите, начинается ли неделя с понедельника или воскресенья', + 'vacay.carryOver': 'Перенос', + 'vacay.carryOverHint': + 'Автоматически переносить оставшиеся дни отпуска на следующий год', + 'vacay.sharing': 'Общий доступ', + 'vacay.sharingHint': + 'Поделитесь планом отпуска с другими пользователями TREK', + 'vacay.owner': 'Владелец', + 'vacay.shareEmailPlaceholder': 'Эл. почта пользователя TREK', + 'vacay.shareSuccess': 'План успешно предоставлен', + 'vacay.shareError': 'Не удалось поделиться планом', + 'vacay.dissolve': 'Разделить объединение', + 'vacay.dissolveHint': + 'Снова разделить календари. Ваши записи будут сохранены.', + 'vacay.dissolveAction': 'Разделить', + 'vacay.dissolved': 'Календарь разделён', + 'vacay.fusedWith': 'Объединён с', + 'vacay.you': 'вы', + 'vacay.noData': 'Нет данных', + 'vacay.changeColor': 'Изменить цвет', + 'vacay.inviteUser': 'Пригласить пользователя', + 'vacay.inviteHint': + 'Пригласите другого пользователя TREK для совместного календаря отпусков.', + 'vacay.selectUser': 'Выберите пользователя', + 'vacay.sendInvite': 'Отправить приглашение', + 'vacay.inviteSent': 'Приглашение отправлено', + 'vacay.inviteError': 'Не удалось отправить приглашение', + 'vacay.pending': 'ожидание', + 'vacay.noUsersAvailable': 'Нет доступных пользователей', + 'vacay.accept': 'Принять', + 'vacay.decline': 'Отклонить', + 'vacay.acceptFusion': 'Принять и объединить', + 'vacay.inviteTitle': 'Запрос на объединение', + 'vacay.inviteWantsToFuse': 'хочет объединить календарь отпусков с вами.', + 'vacay.fuseInfo1': + 'Вы оба будете видеть все записи об отпуске в одном общем календаре.', + 'vacay.fuseInfo2': + 'Обе стороны могут создавать и редактировать записи друг для друга.', + 'vacay.fuseInfo3': + 'Обе стороны могут удалять записи и изменять право на отпуск.', + 'vacay.fuseInfo4': + 'Настройки, такие как праздники и корпоративные выходные, становятся общими.', + 'vacay.fuseInfo5': + 'Объединение можно отменить в любое время любой из сторон. Ваши записи будут сохранены.', + 'vacay.addCalendar': 'Добавить календарь', + 'vacay.calendarColor': 'Цвет', + 'vacay.calendarLabel': 'Название', + 'vacay.noCalendars': 'Нет календарей', +}; +export default vacay; diff --git a/shared/src/i18n/tr/admin.ts b/shared/src/i18n/tr/admin.ts new file mode 100644 index 0000000000000000000000000000000000000000..2453673c41b215e9c1185567ad9eefe2b7b86cd9 --- /dev/null +++ b/shared/src/i18n/tr/admin.ts @@ -0,0 +1,396 @@ +import type { TranslationStrings } from '../types'; + +const admin: TranslationStrings = { + 'admin.notifications.title': 'Bildirimler', + 'admin.notifications.hint': + 'Bir bildirim kanalı seçin. Aynı anda yalnızca biri etkin olabilir.', + 'admin.notifications.none': 'Kapalı', + 'admin.notifications.email': 'E-posta (SMTP)', + 'admin.notifications.webhook': 'Web kancası', + 'admin.notifications.ntfy': 'Ntfy', + 'admin.ntfy.hint': + 'Kullanıcıların kendi ntfy konularını yapılandırmasına izin verin. Aşağıdaki varsayılan sunucu kullanıcı ayarlarında ön doldurma için kullanılır.', + 'admin.notifications.save': 'Bildirim ayarlarını kaydet', + 'admin.notifications.saved': 'Bildirim ayarları kaydedildi', + 'admin.notifications.testWebhook': 'Test webhook gönder', + 'admin.notifications.testWebhookSuccess': 'Test webhook gönderildi', + 'admin.notifications.testWebhookFailed': 'Test webhook başarısız', + 'admin.notifications.testNtfy': 'Test ntfy gönder', + 'admin.notifications.testNtfySuccess': 'Test ntfy gönderildi', + 'admin.notifications.testNtfyFailed': 'Test ntfy başarısız', + 'admin.notifications.emailPanel.title': 'E-posta (SMTP)', + 'admin.notifications.webhookPanel.title': 'Web kancası', + 'admin.notifications.inappPanel.title': 'Uygulama içi', + 'admin.notifications.inappPanel.hint': + 'Uygulama içi bildirimler her zaman açıktır ve genel olarak kapatılamaz.', + 'admin.notifications.adminWebhookPanel.title': 'Yönetici Webhook', + 'admin.notifications.adminWebhookPanel.hint': + "Bu webhook yalnızca yönetici bildirimleri için kullanılır (örn. sürüm uyarıları). Kullanıcı webhook'larından ayrıdır ve ayarlıysa her zaman tetiklenir.", + 'admin.notifications.adminWebhookPanel.saved': + 'Yönetici webhook URL kaydedildi', + 'admin.notifications.adminWebhookPanel.testSuccess': + 'Test webhook gönderildi', + 'admin.notifications.adminWebhookPanel.testFailed': 'Test webhook başarısız', + 'admin.notifications.adminWebhookPanel.alwaysOnHint': + 'URL yapılandırıldığında yönetici webhook her zaman tetiklenir', + 'admin.notifications.adminNtfyPanel.title': 'Yönetici Ntfy', + 'admin.notifications.adminNtfyPanel.hint': + 'Bu ntfy konusu yalnızca yönetici bildirimleri için kullanılır. Kullanıcı konularından ayrıdır ve yapılandırıldığında her zaman tetiklenir.', + 'admin.notifications.adminNtfyPanel.serverLabel': "Ntfy Sunucu URL'si", + 'admin.notifications.adminNtfyPanel.serverHint': + 'Kullanıcı ntfy bildirimleri için varsayılan sunucu olarak da kullanılır. Boş bırakırsanız ntfy.sh olur. Kullanıcılar kendi ayarlarında geçersiz kılabilir.', + 'admin.notifications.adminNtfyPanel.serverPlaceholder': 'https://ntfy.sh', + 'admin.notifications.adminNtfyPanel.topicLabel': 'Yönetici Konusu', + 'admin.notifications.adminNtfyPanel.topicPlaceholder': + 'yürüyüş-yönetici-uyarıları', + 'admin.notifications.adminNtfyPanel.tokenLabel': + 'Erişim anahtarı (isteğe bağlı)', + 'admin.notifications.adminNtfyPanel.tokenCleared': + 'Yönetici erişim anahtarı temizlendi', + 'admin.notifications.adminNtfyPanel.saved': + 'Yönetici ntfy ayarları kaydedildi', + 'admin.notifications.adminNtfyPanel.test': 'Test ntfy gönder', + 'admin.notifications.adminNtfyPanel.testSuccess': 'Test ntfy gönderildi', + 'admin.notifications.adminNtfyPanel.testFailed': 'Test ntfy başarısız', + 'admin.notifications.adminNtfyPanel.alwaysOnHint': + 'Konu yapılandırıldığında yönetici ntfy her zaman tetiklenir', + 'admin.notifications.adminNotificationsHint': + 'Yalnızca yönetici bildirimlerinin hangi kanallardan iletileceğini yapılandırın.', + 'admin.notifications.tripReminders.title': 'Seyahat Hatırlatıcıları', + 'admin.notifications.tripReminders.hint': + 'Seyahat başlamadan önce hatırlatma gönderir (seyahatte hatırlatma günü ayarlı olmalıdır).', + 'admin.notifications.tripReminders.enabled': 'Seyahat hatırlatıcıları açık', + 'admin.notifications.tripReminders.disabled': + 'Seyahat hatırlatıcıları kapalı', + 'admin.smtp.title': 'E-posta ve Bildirimler', + 'admin.smtp.hint': 'E-posta bildirimleri için SMTP yapılandırması.', + 'admin.smtp.testButton': 'Test e-postası gönder', + 'admin.webhook.hint': + "Kullanıcıların bildirimler için kendi webhook URL'lerini (Discord, Slack vb.) yapılandırmasına izin verin.", + 'admin.smtp.testSuccess': 'Test e-postası gönderildi', + 'admin.smtp.testFailed': 'Test e-postası başarısız', + 'admin.title': 'Yönetim', + 'admin.subtitle': 'Kullanıcı yönetimi ve sistem ayarları', + 'admin.tabs.users': 'Kullanıcılar', + 'admin.tabs.categories': 'Kategoriler', + 'admin.tabs.backup': 'Yedekleme', + 'admin.tabs.notifications': 'Bildirimler', + 'admin.tabs.audit': 'Denetim', + 'admin.stats.users': 'Kullanıcılar', + 'admin.stats.trips': 'Seyahatler', + 'admin.stats.places': 'Yerler', + 'admin.stats.photos': 'Fotoğraflar', + 'admin.stats.files': 'Dosyalar', + 'admin.table.user': 'Kullanıcı', + 'admin.table.email': 'E-posta', + 'admin.table.role': 'Rol', + 'admin.table.created': 'Oluşturulma', + 'admin.table.lastLogin': 'Son Giriş', + 'admin.table.actions': 'İşlemler', + 'admin.you': '(Siz)', + 'admin.editUser': 'Kullanıcıyı Düzenle', + 'admin.newPassword': 'Yeni Şifre', + 'admin.newPasswordHint': 'Mevcut şifreyi korumak için boş bırakın', + 'admin.deleteUser': + '"{name}" kullanıcısı silinsin mi? Tüm geziler kalıcı olarak silinecek.', + 'admin.deleteUserTitle': 'Kullanıcıyı sil', + 'admin.newPasswordPlaceholder': 'Yeni şifreyi girin…', + 'admin.toast.loadError': 'Yönetici verileri yüklenemedi', + 'admin.toast.userUpdated': 'Kullanıcı güncellendi', + 'admin.toast.updateError': 'Güncelleme başarısız oldu', + 'admin.toast.userDeleted': 'Kullanıcı silindi', + 'admin.toast.deleteError': 'Silinemedi', + 'admin.toast.cannotDeleteSelf': 'Kendi hesabınızı silemiyorum', + 'admin.toast.userCreated': 'Kullanıcı oluşturuldu', + 'admin.toast.createError': 'Kullanıcı oluşturulamadı', + 'admin.toast.fieldsRequired': 'Kullanıcı adı, e-posta ve şifre gerekli', + 'admin.createUser': 'Kullanıcı Oluştur', + 'admin.invite.title': 'Bağlantıları Davet Et', + 'admin.invite.subtitle': 'Tek seferlik kayıt bağlantıları oluşturun', + 'admin.invite.create': 'Bağlantı Oluştur', + 'admin.invite.createAndCopy': 'Oluştur ve Kopyala', + 'admin.invite.empty': 'Henüz davet bağlantısı oluşturulmadı', + 'admin.invite.maxUses': 'Maks. Kullanım Alanları', + 'admin.invite.expiry': 'Şu tarihten sonra sona erer:', + 'admin.invite.uses': 'kullanılmış', + 'admin.invite.expiresAt': 'süresi doluyor', + 'admin.invite.createdBy': 'ile', + 'admin.invite.active': 'Aktif', + 'admin.invite.expired': 'Günü geçmiş', + 'admin.invite.usedUp': 'Kullanılmış', + 'admin.invite.copied': 'Davet bağlantısı panoya kopyalandı', + 'admin.invite.copyLink': 'Bağlantıyı kopyala', + 'admin.invite.deleted': 'Davet bağlantısı silindi', + 'admin.invite.createError': 'Davet bağlantısı oluşturulamadı', + 'admin.invite.deleteError': 'Davet bağlantısı silinemedi', + 'admin.tabs.settings': 'Ayarlar', + 'admin.allowRegistration': 'Kayda İzin Ver', + 'admin.allowRegistrationHint': + 'Yeni kullanıcılar kendileri kayıt olabilirler', + 'admin.authMethods': 'Kimlik Doğrulama Yöntemleri', + 'admin.passwordLogin': 'Şifre Girişi', + 'admin.passwordLoginHint': + 'Kullanıcıların e-posta ve şifreyle oturum açmasına izin ver', + 'admin.passwordRegistration': 'Şifre Kaydı', + 'admin.passwordRegistrationHint': + 'Yeni kullanıcıların e-posta ve şifreyle kaydolmasına izin ver', + 'admin.oidcLogin': 'TOA Girişi', + 'admin.oidcLoginHint': 'Kullanıcıların SSO ile oturum açmasına izin Ver', + 'admin.oidcRegistration': 'SSO Otomatik Temel Hazırlığı', + 'admin.oidcRegistrationHint': + 'Yeni SSO kullanıcıları için otomatik olarak hesap oluşturun', + 'admin.envOverrideHint': + 'Şifre oturum açma ayarları OIDC_ONLY ortam değişkeni tarafından kontrol edilir ve burada değiştirilemez.', + 'admin.lockoutWarning': 'En az bir oturum açma yöntemi etkin kalmalıdır', + 'admin.requireMfa': 'İki faktörlü kimlik doğrulama (2FA) gerektir', + 'admin.requireMfaHint': + "2FA'sı olmayan kullanıcıların uygulamayı kullanmadan önce Ayarlar'da kurulumu tamamlaması gerekir.", + 'admin.apiKeys': 'API Anahtarları', + 'admin.apiKeysHint': + 'İsteğe bağlı. Fotoğraflar ve hava durumu gibi genişletilmiş yer verilerini etkinleştirir.', + 'admin.mapsKey': 'Google Haritalar API Anahtarı', + 'admin.mapsKeyHint': + 'Yer arama için gereklidir. console.cloud.google.com adresinden erişin', + 'admin.mapsKeyHintLong': + 'API anahtarı olmadan OpenStreetMap yer arama için kullanılır. Bir Google API anahtarıyla fotoğraflar, derecelendirmeler ve açılış saatleri de yüklenebilir. console.cloud.google.com adresinden bir tane edinin.', + 'admin.recommended': 'Tavsiye edilen', + 'admin.weatherKey': 'OpenWeatherMap API Anahtarı', + 'admin.weatherKeyHint': + "Hava durumu verileri için. openweathermap.org'da ücretsiz", + 'admin.validateKey': 'Test et', + 'admin.keyValid': 'Bağlı', + 'admin.keyInvalid': 'Geçersiz', + 'admin.keySaved': 'API anahtarları kaydedildi', + 'admin.oidcTitle': 'Tek Oturum Açma (OIDC)', + 'admin.oidcSubtitle': + 'Google, Apple, Authentik veya Keycloak gibi harici sağlayıcılar aracılığıyla oturum açmaya izin verin.', + 'admin.oidcDisplayName': 'Ekran Adı', + 'admin.oidcIssuer': "Veren URL'si", + 'admin.oidcIssuerHint': + "Sağlayıcının OpenID Connect Veren URL'si. örneğin https://accounts.google.com", + 'admin.oidcSaved': 'OIDC yapılandırması kaydedildi', + 'admin.oidcOnlyMode': 'Parola kimlik doğrulamasını devre dışı bırak', + 'admin.oidcOnlyModeHint': + 'Etkinleştirildiğinde yalnızca SSO girişine izin verilir. Şifre tabanlı oturum açma ve kayıt engellenir.', + 'admin.fileTypes': 'İzin Verilen Dosya Türleri', + 'admin.fileTypesHint': + 'Kullanıcıların hangi dosya türlerini yükleyebileceğini yapılandırın.', + 'admin.fileTypesFormat': + 'Virgülle ayrılmış uzantılar (ör. jpg,png,pdf,doc). Tüm türlere izin vermek için * kullanın.', + 'admin.fileTypesSaved': 'Dosya türü ayarları kaydedildi', + 'admin.placesPhotos.title': 'Fotoğrafları Yerleştir', + 'admin.placesPhotos.subtitle': + "Fotoğrafları Google Rehber API'sinden alın. API kotasını kaydetmeyi devre dışı bırakın. Wikimedia fotoğrafları etkilenmez.", + 'admin.placesAutocomplete.title': 'Otomatik Tamamlamayı Yerleştir', + 'admin.placesAutocomplete.subtitle': + "Arama önerileri için Google Rehber API'sini kullanın. API kotasını kaydetmeyi devre dışı bırakın.", + 'admin.placesDetails.title': 'Yer Detayları', + 'admin.placesDetails.subtitle': + "Google Rehber API'sinden ayrıntılı yer bilgilerini (saat, puan, web sitesi) alın. API kotasını kaydetmeyi devre dışı bırakın.", + 'admin.bagTracking.title': 'Çanta Takibi', + 'admin.bagTracking.subtitle': + 'Paketleme öğeleri için ağırlık ve torba atamasını etkinleştirin', + 'admin.collab.chat.title': 'Sohbet', + 'admin.collab.chat.subtitle': + 'Seyahat işbirliği için gerçek zamanlı mesajlaşma', + 'admin.collab.notes.title': 'Notlar', + 'admin.collab.notes.subtitle': 'Paylaşılan notlar ve belgeler', + 'admin.collab.polls.title': 'Anketler', + 'admin.collab.polls.subtitle': 'Grup anketleri ve oylama', + 'admin.collab.whatsnext.title': "What's Next", + 'admin.collab.whatsnext.subtitle': 'Etkinlik önerileri ve sonraki adımlar', + 'admin.tabs.config': 'Kişiselleştirme', + 'admin.tabs.defaults': 'Kullanıcı Varsayılanları', + 'admin.defaultSettings.title': 'Varsayılan Kullanıcı Ayarları', + 'admin.defaultSettings.description': + 'Örnek çapında varsayılanları ayarlayın. Herhangi bir ayarı değiştirmemiş olan kullanıcılar bu değerleri görecektir. Kendi değişiklikleri her zaman önceliklidir.', + 'admin.defaultSettings.saved': 'Varsayılan kaydedildi', + 'admin.defaultSettings.reset': 'Yerleşik varsayılana sıfırla', + 'admin.defaultSettings.resetToBuiltIn': 'sıfırlama', + 'admin.tabs.templates': 'Paketleme Şablonları', + 'admin.packingTemplates.title': 'Paketleme Şablonları', + 'admin.packingTemplates.subtitle': + 'Seyahatleriniz için yeniden kullanılabilir paketleme listeleri oluşturun', + 'admin.packingTemplates.create': 'Yeni Şablon', + 'admin.packingTemplates.namePlaceholder': 'Şablon adı (ör. Plaj Tatili)', + 'admin.packingTemplates.empty': 'Henüz şablon oluşturulmadı', + 'admin.packingTemplates.items': 'öğeler', + 'admin.packingTemplates.categories': 'kategoriler', + 'admin.packingTemplates.itemName': 'Öğe adı', + 'admin.packingTemplates.itemCategory': 'Kategori', + 'admin.packingTemplates.categoryName': 'Kategori adı (ör. Giyim)', + 'admin.packingTemplates.addCategory': 'Kategori ekle', + 'admin.packingTemplates.created': 'Şablon oluşturuldu', + 'admin.packingTemplates.deleted': 'Şablon silindi', + 'admin.packingTemplates.loadError': 'Şablonlar yüklenemedi', + 'admin.packingTemplates.createError': 'Şablon oluşturulamadı', + 'admin.packingTemplates.deleteError': 'Şablon silinemedi', + 'admin.packingTemplates.saveError': 'Kaydedilemedi', + 'admin.tabs.addons': 'Eklentiler', + 'admin.addons.title': 'Eklentiler', + 'admin.addons.subtitle': + 'TREK deneyiminizi özelleştirmek için özellikleri etkinleştirin veya devre dışı bırakın.', + 'admin.addons.catalog.packing.name': 'Listeler', + 'admin.addons.catalog.packing.description': + 'Seyahatleriniz için paket listeleri ve yapılacak işler', + 'admin.addons.catalog.budget.name': 'Bütçe', + 'admin.addons.catalog.budget.description': + 'Harcamaları takip edin ve seyahat bütçenizi planlayın', + 'admin.addons.catalog.documents.name': 'Belgeler', + 'admin.addons.catalog.documents.description': + 'Seyahat belgelerini saklayın ve yönetin', + 'admin.addons.catalog.vacay.name': 'Tatil', + 'admin.addons.catalog.vacay.description': + 'Takvim görünümüne sahip kişisel tatil planlayıcısı', + 'admin.addons.catalog.atlas.name': 'Atlas', + 'admin.addons.catalog.atlas.description': + 'Ziyaret edilen ülkeleri ve seyahat istatistiklerini içeren dünya haritası', + 'admin.addons.catalog.collab.name': 'İş birliği', + 'admin.addons.catalog.collab.description': + 'Seyahat planlaması için gerçek zamanlı notlar, anketler ve sohbet', + 'admin.addons.catalog.memories.name': 'Fotoğraflar (Immich)', + 'admin.addons.catalog.memories.description': + 'Immich örneğiniz aracılığıyla gezi fotoğraflarını paylaşın', + 'admin.addons.catalog.mcp.name': 'MCP', + 'admin.addons.catalog.mcp.description': + 'Yapay zeka asistanı entegrasyonu için Model Bağlam Protokolü', + 'admin.addons.subtitleBefore': + 'Kişiselleştirmenizi özelleştirmek için özellikleri etkinleştirin veya devre dışı bırakın.', + 'admin.addons.subtitleAfter': 'deneyim.', + 'admin.addons.enabled': 'Etkinleştirilmiş', + 'admin.addons.disabled': 'Engelli', + 'admin.addons.type.trip': 'Seyahat', + 'admin.addons.type.global': 'Küresel', + 'admin.addons.type.integration': 'Entegrasyon', + 'admin.addons.tripHint': 'Her yolculukta bir sekme olarak mevcuttur', + 'admin.addons.globalHint': + 'Ana navigasyonda bağımsız bir bölüm olarak mevcuttur', + 'admin.addons.integrationHint': + 'Özel bir sayfa olmadan arka uç hizmetleri ve API entegrasyonları', + 'admin.addons.toast.updated': 'Eklenti güncellendi', + 'admin.addons.toast.error': 'Eklenti güncellenemedi', + 'admin.addons.noAddons': 'Kullanılabilir eklenti yok', + 'admin.weather.title': 'Hava Durumu Verileri', + 'admin.weather.badge': "24 Mart 2026'dan beri", + 'admin.weather.description': + "TREK, hava durumu veri kaynağı olarak Open-Meteo'yu kullanıyor. Open-Meteo ücretsiz, açık kaynaklı bir hava durumu hizmetidir; API anahtarı gerekmez.", + 'admin.weather.forecast': '16 günlük tahmin', + 'admin.weather.forecastDesc': 'Daha önce 5 gün (OpenWeatherMap)', + 'admin.weather.climate': 'Geçmiş iklim verileri', + 'admin.weather.climateDesc': + '16 günlük tahminin ötesindeki günler için son 85 yılın ortalamaları', + 'admin.weather.requests': '10.000 istek / gün', + 'admin.weather.requestsDesc': 'Ücretsiz, API anahtarı gerekmez', + 'admin.weather.locationHint': + 'Hava durumu her gün koordinatlarla ilk sırada yer alır. Bir güne herhangi bir yer atanmamışsa, yer listesindeki herhangi bir yer referans olarak kullanılır.', + 'admin.tabs.mcpTokens': 'MCP Erişimi', + 'admin.mcpTokens.title': 'MCP Erişimi', + 'admin.mcpTokens.subtitle': + 'Tüm Kullanıcılar genelinde OAuth Oturumlarını ve API belirteçlerini yönetin', + 'admin.mcpTokens.sectionTitle': 'API Belirteçleri', + 'admin.mcpTokens.owner': 'Mal sahibi', + 'admin.mcpTokens.tokenName': 'Jeton Adı', + 'admin.mcpTokens.created': 'Oluşturuldu', + 'admin.mcpTokens.lastUsed': 'Son Kullanılan', + 'admin.mcpTokens.never': 'Asla', + 'admin.mcpTokens.empty': 'Henüz MCP tokenı oluşturulmadı', + 'admin.mcpTokens.deleteTitle': 'Jetonu Sil', + 'admin.mcpTokens.deleteMessage': + 'Bu, jetonu anında iptal edecektir. Kullanıcı bu belirteç aracılığıyla MCP erişimini kaybedecektir.', + 'admin.mcpTokens.deleteSuccess': 'Jeton silindi', + 'admin.mcpTokens.deleteError': 'Jeton silinemedi', + 'admin.mcpTokens.loadError': 'Jetonlar yüklenemedi', + 'admin.oauthSessions.sectionTitle': 'OAuth Oturumları', + 'admin.oauthSessions.clientName': 'Müşteri', + 'admin.oauthSessions.owner': 'Mal sahibi', + 'admin.oauthSessions.scopes': 'Kapsamlar', + 'admin.oauthSessions.created': 'Oluşturuldu', + 'admin.oauthSessions.empty': 'Aktif OAuth Oturumu yok', + 'admin.oauthSessions.revokeTitle': 'Oturumu İptal Et', + 'admin.oauthSessions.revokeMessage': + 'Bu, OAuth oturumunu hemen iptal edecektir. İstemci MCP erişimini kaybedecek.', + 'admin.oauthSessions.revokeSuccess': 'Oturum iptal edildi', + 'admin.oauthSessions.revokeError': 'Oturum iptal edilemedi', + 'admin.oauthSessions.loadError': 'OAuth oturumları yüklenemedi', + 'admin.tabs.github': 'GitHub', + 'admin.audit.subtitle': + 'Güvenlik açısından hassas olaylar ve yönetim olayları (yedeklemeler, kullanıcılar, MFA, ayarlar).', + 'admin.audit.empty': 'Henüz denetim girişi yok.', + 'admin.audit.refresh': 'Yenile', + 'admin.audit.loadMore': 'Daha fazlasını yükle', + 'admin.audit.showing': '{count} yüklendi · {total} toplam', + 'admin.audit.col.time': 'Zaman', + 'admin.audit.col.user': 'Kullanıcı', + 'admin.audit.col.action': 'Aksiyon', + 'admin.audit.col.resource': 'Kaynak', + 'admin.audit.col.ip': 'IP', + 'admin.audit.col.details': 'Detaylar', + 'admin.github.title': 'Sürüm Geçmişi', + 'admin.github.subtitle': "{repo}'dan en son güncellemeler", + 'admin.github.latest': 'En sonuncu', + 'admin.github.prerelease': 'Ön sürüm', + 'admin.github.showDetails': 'Ayrıntıları göster', + 'admin.github.hideDetails': 'Ayrıntıları gizle', + 'admin.github.loadMore': 'Daha fazlasını yükle', + 'admin.github.loading': 'Yükleniyor...', + 'admin.github.error': 'Sürümler yüklenemedi', + 'admin.github.by': 'ile', + 'admin.github.support': "TREK'i geliştirmeye devam etmeme yardımcı oluyor", + 'admin.update.available': 'Güncelleme mevcut', + 'admin.update.text': 'TREK {versiyon} mevcut. {current} çalıştırıyorsunuz.', + 'admin.update.button': "GitHub'da görüntüle", + 'admin.update.install': 'Güncellemeyi Yükle', + 'admin.update.confirmTitle': 'Güncelleme Yüklensin mi?', + 'admin.update.confirmText': + 'TREK, {current} sürümünden {version} sürümüne güncellenecek. Sunucu daha sonra otomatik olarak yeniden başlatılacaktır.', + 'admin.update.dataInfo': + 'Tüm verileriniz (seyahatler, kullanıcılar, API anahtarları, yüklemeler, Vacay, Atlas, bütçeler) korunacaktır.', + 'admin.update.warning': + 'Yeniden başlatma sırasında uygulama kısa süreliğine kullanılamayacaktır.', + 'admin.update.confirm': 'Şimdi Güncelle', + 'admin.update.installing': 'Güncelleniyor…', + 'admin.update.success': 'Güncelleme yüklendi! Sunucu yeniden başlatılıyor…', + 'admin.update.failed': 'Güncelleme başarısız oldu', + 'admin.update.backupHint': + 'Güncellemeden önce bir yedek oluşturmanızı öneririz.', + 'admin.update.backupLink': 'Yedeklemeye Git', + 'admin.update.howTo': 'Nasıl Güncellenir?', + 'admin.update.dockerText': + "TREK örneğiniz Docker'da çalışır. {version} sürümüne güncellemek için sunucunuzda aşağıdaki komutları çalıştırın:", + 'admin.update.reloadHint': + 'Lütfen birkaç saniye içinde sayfayı yeniden yükleyin.', + 'admin.tabs.permissions': 'İzinler', + 'admin.addons.catalog.journey.name': 'Seyahat', + 'admin.addons.catalog.journey.description': + 'Check-in, fotoğraf ve günlük hikâyelerle seyahat takibi ve seyahat günlüğü', + 'admin.passkey.title': 'Passkey ile oturum açma', + 'admin.passkey.cardHint': + 'Kullanıcıların passkey (WebAuthn) ile oturum açmasına izin verin. Varsayılan olarak kapalı.', + 'admin.passkey.login': 'Passkey ile oturum açmayı etkinleştir', + 'admin.passkey.loginHint': + 'Bir "Passkey ile oturum açın" seçeneği gösterin ve kullanıcıların ayarlarında passkey kaydetmesine izin verin.', + 'admin.passkey.notConfigured': + 'Bu dağıtım için henüz çözümlenen bir WebAuthn alan adı yok. Aşağıdan APP_URL veya Relying Party ID değerini ayarlayın — o ana kadar passkey’ler gizli kalır.', + 'admin.passkey.rpId': 'Relying Party ID (alan adı)', + 'admin.passkey.rpIdHint': + 'Passkey’lerin bağlı olduğu yalın alan adı, ör. trek.example.org. APP_URL’den türetmek için boş bırakın. Daha sonra değiştirmek mevcut passkey’leri geçersiz kılar.', + 'admin.passkey.origins': 'İzin verilen kaynaklar', + 'admin.passkey.originsHint': + 'Virgülle ayrılmış tam kaynaklar, ör. https://trek.example.org. APP_URL kullanmak için boş bırakın.', + 'admin.passkey.reset': 'Passkey’leri sıfırla', + 'admin.passkey.resetHint': + 'Bu kullanıcının tüm passkey’lerini kaldırın (ör. kaybolan bir cihazda). Yine de şifreleriyle oturum açabilirler.', + 'admin.passkey.resetConfirm': '{name} için tüm passkey’ler kaldırılsın mı?', + 'admin.passkey.resetDone': '{count} passkey kaldırıldı', + 'admin.defaultSettings.mapProvider': 'Harita motoru', + 'admin.defaultSettings.mapProviderHint': 'Bu örnekteki herkes için varsayılan harita. Her kullanıcı bunu yine de kendi ayarlarında değiştirebilir.', + 'admin.defaultSettings.providerLeaflet': 'Standart (ücretsiz)', + 'admin.defaultSettings.providerMapbox': 'Mapbox (3D)', + 'admin.defaultSettings.mapboxToken': 'Paylaşılan Mapbox jetonu', + 'admin.defaultSettings.mapboxTokenHint': 'Kendi jetonunu girmemiş her kullanıcı için kullanılır — böylece anahtarı tek tek paylaşmadan tüm örnek Mapbox\'ı kullanır. Şifrelenmiş olarak saklanır.', + 'admin.defaultSettings.mapboxStyle': 'Harita stili', + 'admin.defaultSettings.mapboxStylePlaceholder': 'Bir stil seçin…', + 'admin.defaultSettings.mapbox3d': '3D binalar & arazi', + 'admin.defaultSettings.mapboxQuality': 'Yüksek kalite modu', +}; +export default admin; diff --git a/shared/src/i18n/tr/airport.ts b/shared/src/i18n/tr/airport.ts new file mode 100644 index 0000000000000000000000000000000000000000..ee678606b116b14b2ef1b5e8c0ac7005e8d332ed --- /dev/null +++ b/shared/src/i18n/tr/airport.ts @@ -0,0 +1,6 @@ +import type { TranslationStrings } from '../types'; + +const airport: TranslationStrings = { + 'airport.searchPlaceholder': 'Havaalanı kodu veya şehir (ör. FRA)', +}; +export default airport; diff --git a/shared/src/i18n/tr/atlas.ts b/shared/src/i18n/tr/atlas.ts new file mode 100644 index 0000000000000000000000000000000000000000..3e967f32d351410ee3116e295f74371824948c7b --- /dev/null +++ b/shared/src/i18n/tr/atlas.ts @@ -0,0 +1,60 @@ +import type { TranslationStrings } from '../types'; + +const atlas: TranslationStrings = { + 'atlas.subtitle': 'Dünya çapında seyahat iziniz', + 'atlas.countries': 'Ülkeler', + 'atlas.trips': 'Geziler', + 'atlas.places': 'Yer', + 'atlas.unmark': 'Kaldırmak', + 'atlas.confirmMark': 'Bu ülke ziyaret edildi olarak işaretlensin mi?', + 'atlas.confirmUnmark': 'Bu ülke ziyaret ettiğiniz listeden kaldırılsın mı?', + 'atlas.confirmUnmarkRegion': + 'Bu bölge ziyaret ettiğiniz listeden kaldırılsın mı?', + 'atlas.markVisited': 'Ziyaret edildi olarak işaretle', + 'atlas.markVisitedHint': 'Bu ülkeyi ziyaret ettiğiniz listeye ekleyin', + 'atlas.markRegionVisitedHint': 'Bu bölgeyi ziyaret ettiğiniz listeye ekleyin', + 'atlas.addToBucket': 'Yapılacaklar listesine ekle', + 'atlas.addPoi': 'Yer ekle', + 'atlas.searchCountry': 'Bir ülkeyi arayın...', + 'atlas.bucketNamePlaceholder': 'İsim (ülke, şehir, yer...)', + 'atlas.month': 'Ay', + 'atlas.year': 'Yıl', + 'atlas.addToBucketHint': 'Ziyaret etmek istediğiniz yer olarak kaydedin', + 'atlas.bucketWhen': 'Ne zaman ziyaret etmeyi planlıyorsunuz?', + 'atlas.statsTab': 'İstatistikler', + 'atlas.bucketTab': 'Yapılacaklar Listesi', + 'atlas.addBucket': 'Yapılacaklar listesine ekle', + 'atlas.bucketNotesPlaceholder': 'Notlar (isteğe bağlı)', + 'atlas.bucketEmpty': 'Yapılacaklar listeniz boş', + 'atlas.bucketEmptyHint': 'Ziyaret etmeyi hayal ettiğiniz yerleri ekleyin', + 'atlas.days': 'Günler', + 'atlas.visitedCountries': 'Ziyaret Edilen Ülkeler', + 'atlas.cities': 'Şehirler', + 'atlas.noData': 'Henüz seyahat verisi yok', + 'atlas.noDataHint': + 'Bir gezi oluşturun ve dünya haritanızı göreceğiniz yerleri ekleyin', + 'atlas.lastTrip': 'Son yolculuk', + 'atlas.nextTrip': 'Sonraki gezi', + 'atlas.daysLeft': 'kalan günler', + 'atlas.streak': 'Rüzgâr gibi geçmek', + 'atlas.years': 'yıllar', + 'atlas.yearInRow': 'yıl üst üste', + 'atlas.yearsInRow': 'yıllar üst üste', + 'atlas.tripIn': 'yolculuk', + 'atlas.tripsIn': 'geziler', + 'atlas.since': 'o zamandan beri', + 'atlas.europe': 'Avrupa', + 'atlas.asia': 'Asya', + 'atlas.northAmerica': 'Kuzey Amerika', + 'atlas.southAmerica': 'G. Amerika', + 'atlas.africa': 'Afrika', + 'atlas.oceania': 'Okyanusya', + 'atlas.other': 'Diğer', + 'atlas.firstVisit': 'İlk yolculuk', + 'atlas.lastVisitLabel': 'Son yolculuk', + 'atlas.tripSingular': 'Seyahat', + 'atlas.tripPlural': 'Geziler', + 'atlas.placeVisited': 'Ziyaret edilen yer', + 'atlas.placesVisited': 'Ziyaret edilen yerler', +}; +export default atlas; diff --git a/shared/src/i18n/tr/backup.ts b/shared/src/i18n/tr/backup.ts new file mode 100644 index 0000000000000000000000000000000000000000..2ab68479e916f4f090e1b5ac8a605cbe110b6097 --- /dev/null +++ b/shared/src/i18n/tr/backup.ts @@ -0,0 +1,76 @@ +import type { TranslationStrings } from '../types'; + +const backup: TranslationStrings = { + 'backup.title': 'Veri Yedekleme', + 'backup.subtitle': 'Veritabanı ve tüm yüklenen dosyalar', + 'backup.refresh': 'Yenile', + 'backup.upload': 'Yedek Yükle', + 'backup.uploading': 'Yükleniyor…', + 'backup.create': 'Yedek Oluştur', + 'backup.creating': 'Oluşturuluyor…', + 'backup.empty': 'Henüz yedek yok', + 'backup.createFirst': 'İlk yedeği oluştur', + 'backup.download': 'İndir', + 'backup.restore': 'Geri yükle', + 'backup.confirm.restore': + '"{name}" yedeği geri yüklensin mi?\\\\n\\\\nTüm mevcut veriler yedekle değiştirilecek.', + 'backup.confirm.uploadRestore': + '"{name}" yedek dosyası yüklenip geri yüklensin mi?\\\\n\\\\nTüm mevcut verilerin üzerine yazılacak.', + 'backup.confirm.delete': '"{name}" yedeği silinsin mi?', + 'backup.toast.loadError': 'Yedekler yüklenemedi', + 'backup.toast.created': 'Yedek başarıyla oluşturuldu', + 'backup.toast.createError': 'Yedek oluşturulamadı', + 'backup.toast.restored': 'Yedek geri Yüklendi. Sayfa yenilenecek…', + 'backup.toast.restoreError': 'Geri yükleme başarısız', + 'backup.toast.uploadError': 'Yükleme başarısız oldu', + 'backup.toast.deleted': 'Yedek silindi', + 'backup.toast.deleteError': 'Silinemedi', + 'backup.toast.downloadError': 'İndirme başarısız', + 'backup.toast.settingsSaved': 'Otomatik yedekleme ayarları kaydedildi', + 'backup.toast.settingsError': 'Ayarlar kaydedilemedi', + 'backup.auto.title': 'Otomatik yedekleme', + 'backup.auto.subtitle': 'Zamanlanmış otomatik yedekleme', + 'backup.auto.enable': 'Otomatik yedeklemeyi etkinleştir', + 'backup.auto.enableHint': + 'Yedekler seçilen programa göre otomatik oluşturulur', + 'backup.auto.interval': 'Aralık', + 'backup.auto.hour': 'Çalışma saati', + 'backup.auto.hourHint': 'Sunucu yerel saati ({format} biçimi)', + 'backup.auto.dayOfWeek': 'Haftanın günü', + 'backup.auto.dayOfMonth': 'Ayın günü', + 'backup.auto.dayOfMonthHint': 'Tüm aylarla uyumluluk için 1–28 ile sınırlı', + 'backup.auto.scheduleSummary': 'Program', + 'backup.auto.summaryDaily': 'Her gün saat {hour}:00', + 'backup.auto.summaryWeekly': 'Her {day} saat {hour}:00', + 'backup.auto.summaryMonthly': 'Her ayın {day}. günü saat {hour}:00', + 'backup.auto.envLocked': 'Liman işçisi', + 'backup.auto.envLockedHint': + 'Otomatik yedekleme Docker ortam değişkenleriyle yapılandırılır. Bu ayarları değiştirmek için docker-compose.yml dosyanızı güncelleyip konteyneri yeniden başlatın.', + 'backup.auto.copyEnv': 'Docker Ortam değişkenlerini kopyala', + 'backup.auto.envCopied': 'Docker ortam değişkenleri panoya kopyalandı', + 'backup.auto.keepLabel': 'Eski yedekleri şu süreden sonra sil', + 'backup.dow.sunday': 'Güneş', + 'backup.dow.monday': 'Pazartesi', + 'backup.dow.tuesday': 'Salı', + 'backup.dow.wednesday': 'Çar', + 'backup.dow.thursday': 'Per', + 'backup.dow.friday': 'Cuma', + 'backup.dow.saturday': 'Doygunluk', + 'backup.interval.hourly': 'Saatlik', + 'backup.interval.daily': 'Günlük', + 'backup.interval.weekly': 'Haftalık', + 'backup.interval.monthly': 'Aylık', + 'backup.keep.1day': '1 gün', + 'backup.keep.3days': '3 gün', + 'backup.keep.7days': '7 gün', + 'backup.keep.14days': '14 gün', + 'backup.keep.30days': '30 gün', + 'backup.keep.forever': 'Sonsuza kadar sakla', + 'backup.restoreConfirmTitle': 'Yedek geri yüklensin mi?', + 'backup.restoreWarning': + 'Tüm mevcut veriler (seyahatler, yerler, kullanıcılar, yüklemeler) yedekle kalıcı olarak değiştirilecek. Bu işlem geri alınamaz.', + 'backup.restoreTip': + 'İpucu: Geri yüklemeden önce mevcut durumun yedeğini oluşturun.', + 'backup.restoreConfirm': 'Evet, geri yükle', +}; +export default backup; diff --git a/shared/src/i18n/tr/budget.ts b/shared/src/i18n/tr/budget.ts new file mode 100644 index 0000000000000000000000000000000000000000..6b6e18152af4b3a278487bf42eee872eb0869e9d --- /dev/null +++ b/shared/src/i18n/tr/budget.ts @@ -0,0 +1,116 @@ +import type { TranslationStrings } from '../types'; + +const budget: TranslationStrings = { + 'budget.title': 'Bütçe', + 'budget.exportCsv': 'CSV dışa aktar', + 'budget.emptyTitle': 'Henüz bütçe oluşturulmadı', + 'budget.emptyText': + 'Seyahat bütçenizi planlamak için kategoriler ve kayıtlar oluşturun', + 'budget.emptyPlaceholder': 'Kategori adı girin...', + 'budget.createCategory': 'Kategori Oluştur', + 'budget.category': 'Kategori', + 'budget.categoryName': 'Kategori Adı', + 'budget.table.name': 'İsim', + 'budget.table.total': 'Toplam', + 'budget.table.persons': 'Kişiler', + 'budget.table.days': 'Günler', + 'budget.table.perPerson': 'Kişi Başı', + 'budget.table.perDay': 'Gün Başı', + 'budget.table.perPersonDay': 'Kişi/gün', + 'budget.table.note': 'Not', + 'budget.table.date': 'Tarih', + 'budget.newEntry': 'Yeni Kayıt', + 'budget.defaultEntry': 'Yeni Kayıt', + 'budget.defaultCategory': 'Yeni Kategori', + 'budget.total': 'Toplam', + 'budget.totalBudget': 'Toplam Bütçe', + 'budget.byCategory': 'Kategoriye Göre', + 'budget.editTooltip': 'Düzenlemek için tıklayın', + 'budget.linkedToReservation': 'Bir rezervasyona bağlı — adı orada düzenleyin', + 'budget.confirm.deleteCategory': + '"{name}" kategorisini {count} kayıtla birlikte silmek istediğinizden emin misiniz?', + 'budget.deleteCategory': 'Kategoriyi Sil', + 'budget.perPerson': 'Kişi Başı', + 'budget.paid': 'Ödendi', + 'budget.open': 'Açık', + 'budget.noMembers': 'Atanmış üye yok', + 'budget.settlement': 'Hesaplaşma', + 'budget.settlementInfo': + 'Bir bütçe kalemindeki üye avatarına tıklayarak yeşil işaretleyin — bu ödedikleri anlamına gelir. Hesaplaşma kimin kime ne kadar borçlu olduğunu gösterir.', + 'budget.netBalances': 'Net Bakiyeler', + 'budget.categoriesLabel': 'kategoriler', + "costs.you": "Siz", + "costs.youShort": "S", + "costs.youLower": "siz", + "costs.youOwe": "Borcunuz", + "costs.youOweSub": "Başkalarına ödemeniz gerekiyor", + "costs.youreOwed": "Size borçlu", + "costs.youreOwedSub": "Başkaları size ödemeli", + "costs.totalSpend": "Toplam seyahat harcaması", + "costs.totalSpendSub": "Tüm yolcular genelinde", + "costs.to": "Alıcı", + "costs.from": "Gönderen", + "costs.allSettled": "Tüm hesaplar kapandı", + "costs.nothingOwed": "Size borç yok", + "costs.yourShare": "Sizin payınız", + "costs.youPaid": "Siz ödediniz", + "costs.expenses": "Harcamalar", + "costs.entries": "{count} kayıt", + "costs.searchPlaceholder": "Harcamalarda ara…", + "costs.filter.all": "Tümü", + "costs.filter.mine": "Benim ödediklerim", + "costs.filter.owed": "Bana borçlu", + "costs.addExpense": "Harcama ekle", + "costs.editExpense": "Harcamayı düzenle", + "costs.noMatch": "Aramanızla eşleşen harcama yok.", + "costs.emptyText": "Henüz harcama yok. İlkini ekleyin.", + "costs.spent": "{amount} harcandı", + "costs.noDate": "Tarih yok", + "costs.noOnePaid": "Henüz kimse ödemedi", + "costs.youLent": "{amount} verdiniz", + "costs.youBorrowed": "{amount} aldınız", + "costs.settleUp": "Hesaplaş", + "costs.history": "Geçmiş", + "costs.everyoneSquare": "Herkesin hesabı kapalı", + "costs.nothingOutstanding": "Şu anda bekleyen ödeme yok.", + "costs.pay": "öde", + "costs.pays": "ödüyor", + "costs.settle": "Hesaplaş", + "costs.balances": "Bakiyeler", + "costs.byCategory": "Kategoriye göre", + "costs.noCategories": "Henüz harcama yok.", + "costs.settleHistory": "Hesaplaşma geçmişi", + "costs.noSettlements": "Henüz kapatılmış ödeme yok.", + "costs.paymentsSettled": "{count} ödeme kapatıldı", + "costs.paid": "ödendi", + "costs.undo": "Geri al", + "costs.whatFor": "Ne içindi?", + "costs.namePlaceholder": "örn. Akşam yemeği, hediyelik, benzin…", + "costs.totalAmount": "Toplam tutar", + "costs.currency": "Para birimi", + "costs.day": "Gün", + "costs.rateLabel": "{to} cinsinden 1 {from}", + "costs.category": "Kategori", + "costs.whoPaid": "Kim ödedi?", + "costs.splitBetween": "Eşit olarak böl", + "costs.pickSomeone": "Paylaşmak için en az bir kişi seçin.", + "costs.splitSummary": "{count} kişiye bölündü · her biri {amount}", + "costs.cat.accommodation": "Konaklama", + "costs.cat.food": "Yiyecek & içecek", + "costs.cat.groceries": "Market alışverişi", + "costs.cat.transport": "Ulaşım", + "costs.cat.flights": "Uçuşlar", + "costs.cat.activities": "Etkinlikler", + "costs.cat.sightseeing": "Gezi & turlar", + "costs.cat.shopping": "Alışveriş", + "costs.cat.fees": "Ücretler & biletler", + "costs.cat.health": "Sağlık", + "costs.cat.tips": "Bahşişler", + "costs.cat.other": "Diğer", + "costs.daysCount": "{count} gün", + "costs.travelers": "{count} yolcu", + "costs.liveRate": "anlık kur", + "costs.settleAll": "Tümünü hesaplaş", +}; + +export default budget; diff --git a/shared/src/i18n/tr/categories.ts b/shared/src/i18n/tr/categories.ts new file mode 100644 index 0000000000000000000000000000000000000000..5886b72260cb9956a34f66c87241abc1f29999e0 --- /dev/null +++ b/shared/src/i18n/tr/categories.ts @@ -0,0 +1,26 @@ +import type { TranslationStrings } from '../types'; + +const categories: TranslationStrings = { + 'categories.title': 'Kategoriler', + 'categories.subtitle': 'Yer kategorilerini yönetin', + 'categories.new': 'Yeni Kategori', + 'categories.empty': 'Henüz kategori yok', + 'categories.namePlaceholder': 'Kategori adı', + 'categories.icon': 'Simge', + 'categories.color': 'Renk', + 'categories.customColor': 'Özel renk seç', + 'categories.preview': 'Önizleme', + 'categories.defaultName': 'Kategori', + 'categories.update': 'Güncelle', + 'categories.create': 'Oluştur', + 'categories.confirm.delete': + 'Kategori silinsin mi? Bu kategorideki yerler silinmez.', + 'categories.toast.loadError': 'Kategoriler yüklenemedi', + 'categories.toast.nameRequired': 'Lütfen bir ad girin', + 'categories.toast.updated': 'Kategori güncellendi', + 'categories.toast.created': 'Kategori oluşturuldu', + 'categories.toast.saveError': 'Kaydedilemedi', + 'categories.toast.deleted': 'Kategori silindi', + 'categories.toast.deleteError': 'Silinemedi', +}; +export default categories; diff --git a/shared/src/i18n/tr/collab.ts b/shared/src/i18n/tr/collab.ts new file mode 100644 index 0000000000000000000000000000000000000000..f5ce49d0f9b030e76529731c303f77bb726ffffd --- /dev/null +++ b/shared/src/i18n/tr/collab.ts @@ -0,0 +1,76 @@ +import type { TranslationStrings } from '../types'; + +const collab: TranslationStrings = { + 'collab.tabs.chat': 'Sohbet', + 'collab.tabs.notes': 'Notlar', + 'collab.tabs.polls': 'Anketler', + 'collab.whatsNext.title': "What's Next", + 'collab.whatsNext.today': 'Bugün', + 'collab.whatsNext.tomorrow': 'Yarın', + 'collab.whatsNext.empty': 'Yaklaşan etkinlik yok', + 'collab.whatsNext.until': '–', + 'collab.whatsNext.emptyHint': 'Saati olan etkinlikler burada görünür', + 'collab.chat.send': 'Gönder', + 'collab.chat.placeholder': 'Mesaj yazın...', + 'collab.chat.empty': 'Sohbeti başlatın', + 'collab.chat.emptyHint': 'Mesajlar tüm seyahat üyeleriyle paylaşılır', + 'collab.chat.emptyDesc': + 'Seyahat grubunuzla fikir, plan ve güncellemeleri paylaşın', + 'collab.chat.today': 'Bugün', + 'collab.chat.yesterday': 'Dün', + 'collab.chat.deletedMessage': 'bir mesajı sildi', + 'collab.chat.reply': 'Yanıtla', + 'collab.chat.loadMore': 'Eski mesajları yükle', + 'collab.chat.justNow': 'az önce', + 'collab.chat.minutesAgo': '{n} dk önce', + 'collab.chat.hoursAgo': '{n} sa önce', + 'collab.notes.title': 'Notlar', + 'collab.notes.new': 'Yeni Not', + 'collab.notes.empty': 'Henüz not yok', + 'collab.notes.emptyHint': 'Fikir ve planları kaydetmeye başlayın', + 'collab.notes.all': 'Tüm', + 'collab.notes.titlePlaceholder': 'Not başlığı', + 'collab.notes.contentPlaceholder': 'Bir şeyler yazın...', + 'collab.notes.categoryPlaceholder': 'Kategori', + 'collab.notes.newCategory': 'Yeni kategori...', + 'collab.notes.category': 'Kategori', + 'collab.notes.noCategory': 'Kategori yok', + 'collab.notes.color': 'Renk', + 'collab.notes.save': 'Kaydet', + 'collab.notes.cancel': 'İptal etmek', + 'collab.notes.edit': 'Düzenle', + 'collab.notes.delete': 'Sil', + 'collab.notes.confirmDeleteTitle': 'Not silinsin mi?', + 'collab.notes.confirmDeleteBody': 'Bu not kalıcı olarak silinecek.', + 'collab.notes.pin': 'Sabitle', + 'collab.notes.unpin': 'Sabitlemeyi kaldır', + 'collab.notes.daysAgo': '{n} gün önce', + 'collab.notes.categorySettings': 'Kategorileri Yönet', + 'collab.notes.create': 'Oluştur', + 'collab.notes.website': 'Web sitesi', + 'collab.notes.websitePlaceholder': 'https://...', + 'collab.notes.attachFiles': 'Dosya ekle', + 'collab.notes.noCategoriesYet': 'Henüz kategori yok', + 'collab.notes.emptyDesc': 'Başlamak için bir not oluşturun', + 'collab.polls.title': 'Anketler', + 'collab.polls.new': 'Yeni Anket', + 'collab.polls.empty': 'Henüz anket yok', + 'collab.polls.emptyHint': 'Gruba sorun ve birlikte oy verin', + 'collab.polls.question': 'Soru', + 'collab.polls.questionPlaceholder': 'Ne yapalım?', + 'collab.polls.addOption': '+ Seçenek ekle', + 'collab.polls.optionPlaceholder': 'Seçenek {n}', + 'collab.polls.create': 'Anket Oluştur', + 'collab.polls.close': 'Kapat', + 'collab.polls.closed': 'Kapalı', + 'collab.polls.votes': '{n} oy', + 'collab.polls.vote': '{n} oy', + 'collab.polls.multipleChoice': 'Çoklu seçim', + 'collab.polls.multiChoice': 'Çoklu seçim', + 'collab.polls.deadline': 'Son tarih', + 'collab.polls.option': 'Seçenek', + 'collab.polls.options': 'Seçenekler', + 'collab.polls.delete': 'Sil', + 'collab.polls.closedSection': 'Kapalı', +}; +export default collab; diff --git a/shared/src/i18n/tr/common.ts b/shared/src/i18n/tr/common.ts new file mode 100644 index 0000000000000000000000000000000000000000..ff55965507c989d4a5726ae418d2f1313c0ed360 --- /dev/null +++ b/shared/src/i18n/tr/common.ts @@ -0,0 +1,55 @@ +import type { TranslationStrings } from '../types'; + +const common: TranslationStrings = { + 'common.save': 'Kaydet', + 'common.showMore': 'Daha fazla göster', + 'common.showLess': 'Daha az göster', + 'common.cancel': 'İptal', + 'common.clear': 'Temizle', + 'common.delete': 'Sil', + 'common.edit': 'Düzenle', + 'common.add': 'Ekle', + 'common.loading': 'Yükleniyor...', + 'common.import': 'İçe aktar', + 'common.select': 'Seç', + 'common.selectAll': 'Tümünü seç', + 'common.deselectAll': 'Seçimi kaldır', + 'common.error': 'Hata', + 'common.unknownError': 'Bilinmeyen hata', + 'common.tooManyAttempts': + 'Çok fazla deneme. Lütfen daha sonra tekrar deneyin.', + 'common.back': 'Geri', + 'common.all': 'Tümü', + 'common.close': 'Kapat', + 'common.open': 'Aç', + 'common.upload': 'Yükle', + 'common.search': 'Ara', + 'common.confirm': 'Onayla', + 'common.ok': 'Tamam', + 'common.yes': 'Evet', + 'common.no': 'Hayır', + 'common.or': 'veya', + 'common.none': 'Yok', + 'common.date': 'Tarih', + 'common.rename': 'Yeniden adlandır', + 'common.discardChanges': 'Değişiklikleri iptal et', + 'common.discard': 'Vazgeç', + 'common.name': 'Ad', + 'common.email': 'E-posta', + 'common.password': 'Şifre', + 'common.saving': 'Kaydediliyor...', + 'common.justNow': 'az önce', + 'common.hoursAgo': '{count} sa. önce', + 'common.daysAgo': '{count} gün önce', + 'common.saved': 'Kaydedildi', + 'common.update': 'Güncelle', + 'common.change': 'Değiştir', + 'common.uploading': 'Yükleniyor…', + 'common.backToPlanning': 'Planlamaya dön', + 'common.reset': 'Sıfırla', + 'common.expand': 'Genişlet', + 'common.collapse': 'Daralt', + 'common.copy': 'Kopyala', + 'common.copied': 'Kopyalandı', +}; +export default common; diff --git a/shared/src/i18n/tr/dashboard.ts b/shared/src/i18n/tr/dashboard.ts new file mode 100644 index 0000000000000000000000000000000000000000..f30036264babcd5ecf87d150029934405c1f6bb5 --- /dev/null +++ b/shared/src/i18n/tr/dashboard.ts @@ -0,0 +1,167 @@ +import type { TranslationStrings } from '../types'; + +const dashboard: TranslationStrings = { + 'dashboard.title': 'Seyahatlerim', + 'dashboard.subtitle.loading': 'Seyahatler yükleniyor...', + 'dashboard.subtitle.trips': '{count} seyahat ({archived} arşivde)', + 'dashboard.subtitle.empty': 'İlk seyahatinizi başlatın', + 'dashboard.subtitle.activeOne': '{count} etkin seyahat', + 'dashboard.subtitle.activeMany': '{count} etkin seyahat', + 'dashboard.subtitle.archivedSuffix': ' · {count} arşivde', + 'dashboard.newTrip': 'Yeni Seyahat', + 'dashboard.newTripSub': 'Sıfırdan yeni bir seyahat planla', + 'dashboard.gridView': 'Izgara görünümü', + 'dashboard.listView': 'Liste görünümü', + 'dashboard.currency': 'Para birimi', + 'dashboard.timezone': 'Saat dilimleri', + 'dashboard.localTime': 'Yerel', + 'dashboard.timezoneCustomTitle': 'Özel saat dilimi', + 'dashboard.timezoneCustomLabelPlaceholder': 'Etiket (isteğe bağlı)', + 'dashboard.timezoneCustomTzPlaceholder': 'örn. America/New_York', + 'dashboard.timezoneCustomAdd': 'Ekle', + 'dashboard.timezoneCustomErrorEmpty': 'Saat dilimi tanımlayıcısı girin', + 'dashboard.timezoneCustomErrorInvalid': + 'Geçersiz saat dilimi. Europe/Berlin gibi bir biçim kullanın', + 'dashboard.timezoneCustomErrorDuplicate': 'Zaten ekli', + 'dashboard.emptyTitle': 'Henüz seyahat yok', + 'dashboard.emptyText': 'İlk seyahatinizi oluşturup planlamaya başlayın!', + 'dashboard.emptyButton': 'İlk Seyahati Oluştur', + 'dashboard.nextTrip': 'Sonraki Seyahat', + 'dashboard.shared': 'Paylaşılan', + 'dashboard.sharedBy': '{name} paylaştı', + 'dashboard.days': 'Günler', + 'dashboard.places': 'Yerler', + 'dashboard.members': 'Arkadaşlar', + 'dashboard.archive': 'Arşivle', + 'dashboard.copyTrip': 'Kopyala', + 'dashboard.copySuffix': 'kopya', + 'dashboard.restore': 'Geri al', + 'dashboard.archived': 'Arşivlendi', + 'dashboard.status.ongoing': 'Devam ediyor', + 'dashboard.status.today': 'Bugün', + 'dashboard.status.tomorrow': 'Yarın', + 'dashboard.status.past': 'Geçmiş', + 'dashboard.status.daysLeft': '{count} gün kaldı', + 'dashboard.toast.loadError': 'Seyahatler yüklenemedi', + 'dashboard.toast.created': 'Seyahat oluşturuldu!', + 'dashboard.toast.createError': 'Seyahat oluşturulamadı', + 'dashboard.toast.updated': 'Seyahat güncellendi!', + 'dashboard.toast.updateError': 'Seyahat güncellenemedi', + 'dashboard.toast.deleted': 'Seyahat silindi', + 'dashboard.toast.deleteError': 'Seyahat silinemedi', + 'dashboard.toast.archived': 'Seyahat arşivlendi', + 'dashboard.toast.archiveError': 'Arşivlenemedi', + 'dashboard.toast.restored': 'Seyahat geri alındı', + 'dashboard.toast.restoreError': 'Geri alınamadı', + 'dashboard.toast.copied': 'Seyahat kopyalandı!', + 'dashboard.toast.copyError': 'Kopyalanamadı', + 'dashboard.confirm.delete': + '"{title}" seyahatini sil? Tüm yerler ve planlar kalıcı olarak silinir.', + 'dashboard.confirm.copy.title': 'Bu seyahat kopyalansın mı?', + 'dashboard.confirm.copy.willCopy': 'Kopyalanacak', + 'dashboard.confirm.copy.will1': 'Günler, yerler ve gün atamaları', + 'dashboard.confirm.copy.will2': 'Konaklama ve rezervasyonlar', + 'dashboard.confirm.copy.will3': 'Bütçe kalemleri ve kategori sırası', + 'dashboard.confirm.copy.will4': 'Paket listeleri (işaretlenmemiş)', + 'dashboard.confirm.copy.will5': 'Yapılacaklar (atanmamış ve işaretlenmemiş)', + 'dashboard.confirm.copy.will6': 'Gün notları', + 'dashboard.confirm.copy.wontCopy': 'Kopyalanmayacak', + 'dashboard.confirm.copy.wont1': 'İşbirlikçiler ve üye atamaları', + 'dashboard.confirm.copy.wont2': 'Collab notları, anketler ve mesajlar', + 'dashboard.confirm.copy.wont3': 'Dosyalar ve fotoğraflar', + 'dashboard.confirm.copy.wont4': 'Paylaşım jetonları', + 'dashboard.confirm.copy.confirm': 'Seyahati kopyala', + 'dashboard.editTrip': 'Seyahati Düzenle', + 'dashboard.createTrip': 'Yeni Seyahat Oluştur', + 'dashboard.tripTitle': 'Başlık', + 'dashboard.tripTitlePlaceholder': 'örn. Japonya yaz tatili', + 'dashboard.tripDescription': 'Açıklama', + 'dashboard.tripDescriptionPlaceholder': 'Bu seyahat ne hakkında?', + 'dashboard.startDate': 'Başlangıç Tarihi', + 'dashboard.endDate': 'Bitiş Tarihi', + 'dashboard.dayCount': 'Gün sayısı', + 'dashboard.dayCountHint': 'Seyahat tarihi yoksa kaç gün planlanacağı.', + 'dashboard.noDateHint': + 'Tarih yok — varsayılan 7 gün oluşturulur. İstediğiniz zaman değiştirebilirsiniz.', + 'dashboard.coverImage': 'Kapak Görseli', + 'dashboard.addCoverImage': 'Kapak ekle (sürükleyip bırakabilirsiniz)', + 'dashboard.addMembers': 'Seyahat arkadaşları', + 'dashboard.addMember': 'Üye ekle', + 'dashboard.coverSaved': 'Kapak kaydedildi', + 'dashboard.coverUploadError': 'Yüklenemedi', + 'dashboard.coverRemoveError': 'Kaldırılamadı', + 'dashboard.titleRequired': 'Başlık gerekli', + 'dashboard.endDateError': 'Bitiş tarihi başlangıçtan sonra olmalı', + 'dashboard.greeting.morning': 'Günaydın,', + 'dashboard.greeting.afternoon': 'İyi günler,', + 'dashboard.greeting.evening': 'İyi akşamlar,', + 'dashboard.mobile.liveNow': 'Canlı', + 'dashboard.mobile.tripProgress': 'Seyahat ilerlemesi', + 'dashboard.mobile.daysLeft': '{count} gün kaldı', + 'dashboard.mobile.places': 'Yerler', + 'dashboard.mobile.buddies': 'Arkadaşlar', + 'dashboard.mobile.newTrip': 'Yeni Seyahat', + 'dashboard.mobile.currency': 'Para birimi', + 'dashboard.mobile.timezone': 'Saat dilimi', + 'dashboard.mobile.upcomingTrips': 'Yaklaşan Seyahatler', + 'dashboard.mobile.yourTrips': 'Seyahatleriniz', + 'dashboard.mobile.trips': 'seyahat', + 'dashboard.mobile.starts': 'Başlıyor', + 'dashboard.mobile.duration': 'Süre', + 'dashboard.mobile.day': 'gün', + 'dashboard.mobile.days': 'gün', + 'dashboard.mobile.ongoing': 'Devam ediyor', + 'dashboard.mobile.startsToday': 'Bugün başlıyor', + 'dashboard.mobile.tomorrow': 'Yarın', + 'dashboard.mobile.inDays': '{count} gün içinde', + 'dashboard.mobile.inMonths': '{count} ay içinde', + 'dashboard.mobile.completed': 'Tamamlandı', + 'dashboard.mobile.currencyConverter': 'Döviz çevirici', + 'dashboard.filter.planned': 'Planlanan', + 'dashboard.hero.badgeLive': 'ŞİMDİ CANLI', + 'dashboard.hero.badgeToday': 'BUGÜN BAŞLIYOR', + 'dashboard.hero.badgeTomorrow': 'YARIN', + 'dashboard.hero.badgeNext': 'SIRADAKİ', + 'dashboard.hero.badgeRecent': 'YAKIN ZAMANDA', + 'dashboard.hero.tripDates': 'Gezi tarihleri', + 'dashboard.hero.noDates': 'Tarih ayarlanmadı', + 'dashboard.hero.travelerOne': '{count} gezgin', + 'dashboard.hero.travelerMany': '{count} gezgin', + 'dashboard.hero.destinationOne': '{count} varış noktası', + 'dashboard.hero.destinationMany': '{count} varış noktası', + 'dashboard.hero.dayUnitOne': 'gün', + 'dashboard.hero.dayUnitMany': 'gün', + 'dashboard.hero.dayLeft': 'gün kaldı', + 'dashboard.hero.daysLeft': 'gün kaldı', + 'dashboard.hero.lastDay': 'Son gün', + 'dashboard.hero.untilStart': 'Başlangıca', + 'dashboard.hero.startsIn': 'Başlamasına', + 'dashboard.atlas.countriesVisited': 'Atlas · Gezilen ülkeler', + 'dashboard.atlas.ofTotal': '/ {total}', + 'dashboard.atlas.tripsTotal': 'Toplam gezi', + 'dashboard.atlas.placesMapped': '{count} yer haritalandı', + 'dashboard.atlas.daysTraveled': 'Seyahat günleri', + 'dashboard.atlas.daysUnit': 'gün', + 'dashboard.atlas.acrossAllTrips': 'tüm gezilerde', + 'dashboard.atlas.distanceFlown': 'Uçulan mesafe', + 'dashboard.atlas.kmUnit': 'km', + 'dashboard.atlas.aroundEquator': '≈ ekvatorun {count}× çevresi', + 'dashboard.card.idea': 'Fikir', + 'dashboard.card.buddyOne': 'Arkadaş', + 'dashboard.fx.from': 'Kaynak', + 'dashboard.fx.to': 'Hedef', + 'dashboard.fx.unavailable': 'Kur kullanılamıyor', + 'dashboard.tz.searchPlaceholder': 'Saat dilimi ara…', + 'dashboard.tz.empty': 'Henüz başka saat dilimi yok — + ile bir tane ekleyin', + 'dashboard.upcoming.title': 'Yaklaşan rezervasyonlar', + 'dashboard.upcoming.empty': 'Henüz bir şey rezerve edilmedi.', + 'dashboard.aria.toggleView': 'Görünümü değiştir', + 'dashboard.aria.filter': 'Filtrele', + 'dashboard.aria.duplicate': 'Çoğalt', + 'dashboard.aria.refreshRates': 'Kurları yenile', + 'dashboard.aria.swapCurrencies': 'Para birimlerini değiştir', + 'dashboard.aria.addTimezone': 'Saat dilimi ekle', + 'dashboard.aria.removeTimezone': '{city} kaldır', + 'dashboard.dayCountRequired': 'Gün sayısı gereklidir', +}; +export default dashboard; diff --git a/shared/src/i18n/tr/day.ts b/shared/src/i18n/tr/day.ts new file mode 100644 index 0000000000000000000000000000000000000000..0a9bef91fb6a93c702718bb79ae2f108b639bc77 --- /dev/null +++ b/shared/src/i18n/tr/day.ts @@ -0,0 +1,26 @@ +import type { TranslationStrings } from '../types'; + +const day: TranslationStrings = { + 'day.precipProb': 'Yağış olasılığı', + 'day.precipitation': 'Yağış', + 'day.wind': 'Rüzgâr', + 'day.sunrise': 'Gün doğumu', + 'day.sunset': 'Gün batımı', + 'day.hourlyForecast': 'Saatlik Tahmin', + 'day.climateHint': + 'Tarihsel ortalamalar — gerçek tahmin bu tarihten 16 gün öncesine kadar kullanılabilir.', + 'day.noWeather': 'Hava durumu verisi yok. Koordinatlı bir yer ekleyin.', + 'day.overview': 'Günlük Özet', + 'day.accommodation': 'Konaklama', + 'day.addAccommodation': 'Konaklama ekle', + 'day.hotelDayRange': 'Günlere uygula', + 'day.noPlacesForHotel': 'Önce seyahatinize yer ekleyin', + 'day.allDays': 'Tüm', + 'day.checkIn': 'Giriş', + 'day.checkInUntil': 'Kadar', + 'day.checkOut': 'Çıkış yapmak', + 'day.confirmation': 'Onay kodu', + 'day.editAccommodation': 'Konaklamayı düzenle', + 'day.reservations': 'Rezervasyonlar', +}; +export default day; diff --git a/shared/src/i18n/tr/dayplan.ts b/shared/src/i18n/tr/dayplan.ts new file mode 100644 index 0000000000000000000000000000000000000000..ba61734df5c8ff6ae63c7d97e96d1be2aab32f2d --- /dev/null +++ b/shared/src/i18n/tr/dayplan.ts @@ -0,0 +1,60 @@ +import type { TranslationStrings } from '../types'; + +const dayplan: TranslationStrings = { + 'dayplan.icsTooltip': 'İhracat takvimi (ICS)', + 'dayplan.emptyDay': 'Bu gün için planlanmış yer yok', + 'dayplan.cannotReorderTransport': + 'Sabit zamanlı rezervasyonlar yeniden sıralanamaz', + 'dayplan.confirmRemoveTimeTitle': 'Saat kaldırılsın mı?', + 'dayplan.confirmRemoveTimeBody': + 'Bu yerin sabit bir saati var ({time}). Taşımak saati kaldırır ve serbest sıralamaya izin verir.', + 'dayplan.confirmRemoveTimeAction': 'Saati kaldır ve taşı', + 'dayplan.confirmDeleteNoteTitle': 'Not silinsin mi?', + 'dayplan.confirmDeleteNoteBody': 'Bu not kalıcı olarak silinecek.', + 'dayplan.cannotDropOnTimed': + 'Öğeler saate bağlı girişler arasına yerleştirilemez', + 'dayplan.cannotBreakChronology': + 'Bu, zamanlı öğelerin kronolojik sırasını bozar', + 'dayplan.addNote': 'Not Ekle', + 'dayplan.expandAll': 'Tüm günleri genişlet', + 'dayplan.collapseAll': 'Tüm günleri daralt', + 'dayplan.editNote': 'Notu Düzenle', + 'dayplan.noteAdd': 'Not Ekle', + 'dayplan.noteEdit': 'Notu Düzenle', + 'dayplan.noteTitle': 'Not', + 'dayplan.noteSubtitle': 'Günlük Not', + 'dayplan.totalCost': 'Toplam Maliyet', + 'dayplan.days': 'Günler', + 'dayplan.dayN': '{n}. gün', + 'dayplan.calculating': 'Hesaplanıyor...', + 'dayplan.route': 'Rota', + 'dayplan.optimize': 'Optimize et', + 'dayplan.optimized': 'Rota optimize edildi', + 'dayplan.routeError': 'Rota hesaplanamadı', + 'dayplan.toast.needTwoPlaces': + 'Rota optimizasyonu için en az iki yer gerekli', + 'dayplan.toast.routeOptimized': 'Rota optimize edildi', + 'dayplan.toast.routeOptimizedFromHotel': + 'Rota konakladığınız yerden optimize edildi', + 'dayplan.toast.noGeoPlaces': 'Rota için koordinatlı yer bulunamadı', + 'dayplan.confirmed': 'Onaylandı', + 'dayplan.pendingRes': 'Beklemede', + 'dayplan.pdf': "PDF'ler", + 'dayplan.pdfTooltip': 'Gün planını PDF olarak dışa aktar', + 'dayplan.pdfError': 'PDF dışa aktarılamadı', + 'dayplan.mobile.addPlace': 'Yer Ekle', + 'dayplan.mobile.searchPlaces': 'Yer ara...', + 'dayplan.mobile.allAssigned': 'Tüm yerler atandı', + 'dayplan.mobile.noMatch': 'Eşleşme yok', + 'dayplan.mobile.createNew': 'Yeni yer oluştur', + 'dayplan.reorderDays': 'Günleri yeniden sırala', + 'dayplan.reorderTitle': 'Günleri yeniden sırala', + 'dayplan.reorderHint': 'Bir günün yerleri, notları ve rezervasyonları onunla birlikte taşınır.', + 'dayplan.addDay': 'Gün ekle', + 'dayplan.moveUp': 'Yukarı taşı', + 'dayplan.moveDown': 'Aşağı taşı', + 'dayplan.reorderUndo': 'Günleri yeniden sırala', + 'dayplan.reorderError': 'Günler yeniden sıralanamadı', + 'dayplan.addDayError': 'Gün eklenemedi', +}; +export default dayplan; diff --git a/shared/src/i18n/tr/externalNotifications.ts b/shared/src/i18n/tr/externalNotifications.ts new file mode 100644 index 0000000000000000000000000000000000000000..218d860a28209ab9f59d6af13e47b7d10dfbd44e --- /dev/null +++ b/shared/src/i18n/tr/externalNotifications.ts @@ -0,0 +1,63 @@ +import type { NotificationLocale } from '../externalNotifications/types'; + +const tr: NotificationLocale = { + email: { + footer: "TREK'te bildirimleri etkinleştirdiğiniz için bunu aldınız.", + manage: 'Ayarlarda tercihleri yönetin', + madeWith: 'Made with', + openTrek: "TREK'i aç", + }, + events: { + trip_invite: (p) => ({ + title: `"${p.trip}" seyahatine davet`, + body: `${p.actor}, ${p.invitee || 'bir üyeyi'} "${p.trip}" seyahatine davet etti.`, + }), + booking_change: (p) => ({ + title: `Yeni rezervasyon: ${p.booking}`, + body: `${p.actor}, "${p.trip}" seyahatine "${p.booking}" (${p.type}) rezervasyonu ekledi.`, + }), + trip_reminder: (p) => ({ + title: `Seyahat hatırlatıcısı: ${p.trip}`, + body: `"${p.trip}" seyahatiniz yaklaşıyor!`, + }), + todo_due: (p) => ({ + title: `Görev süresi dolmak üzere: ${p.todo}`, + body: `"${p.trip}" içindeki "${p.todo}" görevi ${p.due} tarihinde bitiyor.`, + }), + vacay_invite: (p) => ({ + title: 'Vacay Fusion Daveti', + body: `${p.actor} sizi tatil planlarını birleştirmeye davet etti. Kabul etmek veya reddetmek için TREK'i açın.`, + }), + photos_shared: (p) => ({ + title: `${p.count} fotoğraf paylaşıldı`, + body: `${p.actor}, "${p.trip}" içinde ${p.count} fotoğraf paylaştı.`, + }), + collab_message: (p) => ({ + title: `"${p.trip}" içinde yeni mesaj`, + body: `${p.actor}: ${p.preview}`, + }), + packing_tagged: (p) => ({ + title: `Bagaj: ${p.category}`, + body: `${p.actor}, sizi "${p.trip}" içindeki "${p.category}" bagaj kategorisine atadı.`, + }), + version_available: (p) => ({ + title: 'Yeni TREK sürümü mevcut', + body: `TREK ${p.version} artık mevcut. Güncellemek için yönetici panelini ziyaret edin.`, + }), + synology_session_cleared: () => ({ + title: 'Synology oturumu temizlendi', + body: 'Synology hesabınız veya URL değişti. Synology Photos oturumunuz kapatıldı.', + }), + }, + passwordReset: { + subject: 'Şifrenizi sıfırlayın', + greeting: 'Merhaba', + body: 'TREK hesabınızın şifresini sıfırlamak için bir istek aldık. Yeni bir şifre belirlemek için aşağıdaki butona tıklayın.', + ctaIntro: 'Şifreyi sıfırla', + expiry: 'Bu bağlantı 60 dakika içinde sona erer.', + ignore: + 'Bu isteği siz yapmadıysanız, bu e-postayı güvenle yok sayabilirsiniz — şifreniz değişmeyecektir.', + }, +}; + +export default tr; diff --git a/shared/src/i18n/tr/files.ts b/shared/src/i18n/tr/files.ts new file mode 100644 index 0000000000000000000000000000000000000000..f5d117c9b2d05bb7d406e762339aa15269bb64ca --- /dev/null +++ b/shared/src/i18n/tr/files.ts @@ -0,0 +1,62 @@ +import type { TranslationStrings } from '../types'; + +const files: TranslationStrings = { + 'files.title': 'Dosyalar', + 'files.pageTitle': 'Dosyalar ve Belgeler', + 'files.subtitle': '{trip} için {count} dosya', + 'files.download': 'İndir', + 'files.openError': 'Dosya açılamadı', + 'files.downloadPdf': 'PDF İndir', + 'files.count': '{count} dosya', + 'files.countSingular': '1 dosya', + 'files.uploaded': '{count} yüklendi', + 'files.uploadError': 'Yükleme başarısız oldu', + 'files.dropzone': 'Dosyaları buraya bırakın', + 'files.dropzoneHint': 'veya göz atmak için tıklayın', + 'files.allowedTypes': + 'Görsel, PDF, DOC, DOCX, XLS, XLSX, TXT, CSV · Maks. 50 MB', + 'files.uploading': 'Yükleniyor...', + 'files.filterAll': 'Tüm', + 'files.filterPdf': "PDF'ler", + 'files.filterImages': 'Görseller', + 'files.filterDocs': 'Belgeler', + 'files.filterCollab': 'İşbirliği Notları', + 'files.sourceCollab': 'İşbirliği notlarından', + 'files.empty': 'Henüz dosya yok', + 'files.emptyHint': 'Seyahatinize eklemek için dosya yükleyin', + 'files.openTab': 'Yeni sekmede aç', + 'files.confirm.delete': 'Bu dosyayı silmek istediğinizden emin misiniz?', + 'files.toast.deleted': 'Dosya silindi', + 'files.toast.deleteError': 'Dosya silinemedi', + 'files.sourcePlan': 'Gün Planı', + 'files.sourceBooking': 'Rezervasyon', + 'files.sourceTransport': 'Ulaşım', + 'files.attach': 'Ekle', + 'files.pasteHint': 'Panodan görsel de yapıştırabilirsiniz (Ctrl+V)', + 'files.trash': 'Çöp kutusu', + 'files.trashEmpty': 'Çöp kutusu boş', + 'files.emptyTrash': 'Çöp kutusunu boşalt', + 'files.restore': 'Geri yükle', + 'files.star': 'Yıldızla', + 'files.unstar': 'Yıldızı kaldır', + 'files.assign': 'Ata', + 'files.assignTitle': 'Dosya Ata', + 'files.assignPlace': 'Yer', + 'files.assignBooking': 'Rezervasyon', + 'files.assignTransport': 'Ulaşım', + 'files.unassigned': 'Atanmamış', + 'files.unlink': 'Bağlantıyı kaldır', + 'files.toast.trashed': 'Çöp kutusuna taşındı', + 'files.toast.restored': 'Dosya geri yüklendi', + 'files.toast.trashEmptied': 'Çöp kutusu boşaltıldı', + 'files.toast.assigned': 'Dosya atandı', + 'files.toast.assignError': 'Atama başarısız', + 'files.toast.restoreError': 'Geri yükleme başarısız', + 'files.confirm.permanentDelete': + 'Bu dosya kalıcı olarak silinsin mi? Bu işlem geri alınamaz.', + 'files.confirm.emptyTrash': + 'Çöp kutusundaki tüm dosyalar kalıcı olarak silinsin mi? Bu işlem geri alınamaz.', + 'files.noteLabel': 'Not', + 'files.notePlaceholder': 'Not ekleyin...', +}; +export default files; diff --git a/shared/src/i18n/tr/index.ts b/shared/src/i18n/tr/index.ts new file mode 100644 index 0000000000000000000000000000000000000000..77aeb6a09fb62e2522e8b4c04e4169a94c2f8d99 --- /dev/null +++ b/shared/src/i18n/tr/index.ts @@ -0,0 +1,86 @@ +import admin from './admin'; +import airport from './airport'; +import atlas from './atlas'; +import backup from './backup'; +import budget from './budget'; +import categories from './categories'; +import collab from './collab'; +import common from './common'; +import dashboard from './dashboard'; +import day from './day'; +import dayplan from './dayplan'; +import files from './files'; +import inspector from './inspector'; +import journey from './journey'; +import login from './login'; +import map from './map'; +import members from './members'; +import memories from './memories'; +import nav from './nav'; +import notif from './notif'; +import notifications from './notifications'; +import oauth from './oauth'; +import packing from './packing'; +import pdf from './pdf'; +import perm from './perm'; +import photos from './photos'; +import places from './places'; +import planner from './planner'; +import register from './register'; +import reservations from './reservations'; +import settings from './settings'; +import share from './share'; +import shared from './shared'; +import stats from './stats'; +import system_notice from './system_notice'; +import todo from './todo'; +import transport from './transport'; +import trip from './trip'; +import trips from './trips'; +import undo from './undo'; +import vacay from './vacay'; + +const locale = { + ...common, + ...trips, + ...nav, + ...dashboard, + ...settings, + ...admin, + ...dayplan, + ...share, + ...shared, + ...login, + ...register, + ...vacay, + ...atlas, + ...trip, + ...places, + ...inspector, + ...reservations, + ...airport, + ...map, + ...budget, + ...files, + ...packing, + ...members, + ...categories, + ...backup, + ...photos, + ...pdf, + ...planner, + ...stats, + ...day, + ...memories, + ...collab, + ...perm, + ...undo, + ...notifications, + ...todo, + ...notif, + ...journey, + ...oauth, + ...system_notice, + ...transport, +}; +export default locale; diff --git a/shared/src/i18n/tr/inspector.ts b/shared/src/i18n/tr/inspector.ts new file mode 100644 index 0000000000000000000000000000000000000000..358f2aa116ff7ad1f9a8d6a025cadb6908f1f1a8 --- /dev/null +++ b/shared/src/i18n/tr/inspector.ts @@ -0,0 +1,22 @@ +import type { TranslationStrings } from '../types'; + +const inspector: TranslationStrings = { + 'inspector.opened': 'Açık', + 'inspector.closed': 'Kapalı', + 'inspector.openingHours': 'Açılış Saatleri', + 'inspector.showHours': 'Açılış saatlerini göster', + 'inspector.files': 'Dosyalar', + 'inspector.filesCount': '{count} dosya', + 'inspector.remove': 'Kaldırmak', + 'inspector.removeFromDay': 'Günden Kaldır', + 'inspector.addToDay': 'Güne Ekle', + 'inspector.confirmedRes': 'Onaylanmış Rezervasyon', + 'inspector.pendingRes': 'Bekleyen Rezervasyon', + 'inspector.google': "Google Haritalar'da aç", + 'inspector.website': 'Web Sitesini Aç', + 'inspector.addRes': 'Rezervasyon', + 'inspector.editRes': 'Rezervasyonu Düzenle', + 'inspector.participants': 'Katılımcılar', + 'inspector.trackStats': 'İstatistikleri Takip Et', +}; +export default inspector; diff --git a/shared/src/i18n/tr/journey.ts b/shared/src/i18n/tr/journey.ts new file mode 100644 index 0000000000000000000000000000000000000000..cac6851e4f4b60a3bf3608e866fbbbb5d8ce7806 --- /dev/null +++ b/shared/src/i18n/tr/journey.ts @@ -0,0 +1,246 @@ +import type { TranslationStrings } from '../types'; + +const journey: TranslationStrings = { + 'journey.search.placeholder': 'Journey ara…', + 'journey.search.noResults': '"{query}" ile eşleşen journey yok', + 'journey.title': 'Seyahat', + 'journey.subtitle': 'Seyahatlerinizi anında kaydedin', + 'journey.new': 'Yeni Journey', + 'journey.create': 'Oluştur', + 'journey.titlePlaceholder': 'Nereye gidiyorsunuz?', + 'journey.empty': 'Henüz journey yok', + 'journey.emptyHint': 'Bir sonraki seyahatinizi belgelemeye başlayın', + 'journey.deleted': 'Journey silindi', + 'journey.createError': 'Journey oluşturulamadı', + 'journey.deleteError': 'Journey silinemedi', + 'journey.deleteConfirmTitle': 'Sil', + 'journey.deleteConfirmMessage': + '"{title}" silinsin mi? Bu işlem geri alınamaz.', + 'journey.deleteConfirmGeneric': 'Bunu silmek istediğinizden emin misiniz?', + 'journey.notFound': 'Journey bulunamadı', + 'journey.photos': 'Fotoğraflar', + 'journey.timelineEmpty': 'Henüz durak yok', + 'journey.timelineEmptyHint': + 'Başlamak için check-in ekleyin veya günlük kaydı yazın', + 'journey.status.draft': 'Taslak', + 'journey.status.active': 'Aktif', + 'journey.status.completed': 'Tamamlandı', + 'journey.status.upcoming': 'Yaklaşan', + 'journey.status.archived': 'Arşivlendi', + 'journey.checkin.add': 'Giriş', + 'journey.checkin.namePlaceholder': 'Konum adı', + 'journey.checkin.notesPlaceholder': 'Notlar (isteğe bağlı)', + 'journey.checkin.save': 'Kaydet', + 'journey.checkin.error': 'Check-in kaydedilemedi', + 'journey.entry.add': 'Günlük', + 'journey.entry.edit': 'Kaydı düzenle', + 'journey.entry.titlePlaceholder': 'Başlık (isteğe bağlı)', + 'journey.entry.bodyPlaceholder': 'Bugün ne oldu?', + 'journey.entry.save': 'Kaydet', + 'journey.entry.error': 'Kayıt kaydedilemedi', + 'journey.photo.add': 'Fotoğraf', + 'journey.photo.uploadError': 'Yükleme başarısız oldu', + 'journey.share.share': 'Paylaş', + 'journey.share.public': 'Herkese açık', + 'journey.share.linkCopied': 'Herkese açık bağlantı kopyalandı', + 'journey.share.disabled': 'Herkese açık paylaşım kapalı', + 'journey.editor.titlePlaceholder': 'Bu ana bir ad verin...', + 'journey.editor.bodyPlaceholder': 'Bu günün hikâyesini anlatın...', + 'journey.editor.placePlaceholder': 'Konum (isteğe bağlı)', + 'journey.editor.tagsPlaceholder': + 'Etiketler: gizli cevher, en iyi yemek, tekrar ziyaret...', + 'journey.visibility.private': 'Gizli', + 'journey.visibility.shared': 'Paylaşılan', + 'journey.visibility.public': 'Herkese açık', + 'journey.emptyState.title': 'Hikâyeniz burada başlıyor', + 'journey.emptyState.subtitle': + 'Bir yerde check-in yapın veya ilk günlük kaydınızı yazın', + 'journey.frontpage.subtitle': + "Turn your trips into stories you'll never forget", + 'journey.frontpage.createJourney': 'Journey Oluştur', + 'journey.frontpage.activeJourney': 'Aktif Journey', + 'journey.frontpage.allJourneys': "Tüm Journey'ler", + 'journey.frontpage.journeys': 'journey', + 'journey.frontpage.createNew': 'Yeni Journey oluştur', + 'journey.frontpage.createNewSub': + 'Seyahat seçin, hikâyeler yazın, maceralarınızı paylaşın', + 'journey.frontpage.live': 'Canlı', + 'journey.frontpage.synced': 'Senkronize', + 'journey.frontpage.continueWriting': 'Yazmaya devam et', + 'journey.frontpage.updated': '{time} Güncellendi', + 'journey.frontpage.suggestionLabel': 'Seyahat yeni bitti', + 'journey.frontpage.suggestionText': + "{title} seyahatini Journey'e dönüştür", + 'journey.frontpage.dismiss': 'Kapat', + 'journey.frontpage.journeyName': 'Journey Adı', + 'journey.frontpage.namePlaceholder': 'örn. Güneydoğu Asya 2026', + 'journey.frontpage.selectTrips': 'Seyahat Seç', + 'journey.frontpage.tripsSelected': 'seyahat seçildi', + 'journey.frontpage.trips': 'seyahat', + 'journey.frontpage.placesImported': 'yer içe aktarılacak', + 'journey.frontpage.places': 'yer', + 'journey.detail.backToJourney': "Journey'e dön", + 'journey.detail.syncedWithTrips': 'Seyahatlerle senkronize', + 'journey.detail.addEntry': 'Kayıt Ekle', + 'journey.detail.newEntry': 'Yeni Kayıt', + 'journey.detail.editEntry': 'Kaydı Düzenle', + 'journey.detail.noEntries': 'Henüz kayıt yok', + 'journey.detail.noEntriesHint': + 'İskelet kayıtlarla başlamak için bir seyahat ekleyin', + 'journey.detail.noPhotos': 'Henüz fotoğraf yok', + 'journey.detail.noPhotosHint': + 'Kayıtlara fotoğraf yükleyin veya Immich/Synology kütüphanenize göz atın', + 'journey.detail.journeyTab': 'Seyahat', + 'journey.detail.journeyStats': 'Journey İstatistikleri', + 'journey.detail.syncedTrips': 'Senkronize Seyahatler', + 'journey.detail.noTripsLinked': 'Henüz bağlı seyahat yok', + 'journey.detail.contributors': 'Katkıda bulunanlar', + 'journey.detail.readMore': 'Devamını oku', + 'journey.detail.prosCons': 'Artılar ve Eksiler', + 'journey.detail.photos': 'fotoğraf', + 'journey.detail.day': '{number}. gün', + 'journey.detail.places': 'yer', + 'journey.stats.days': 'Günler', + 'journey.stats.cities': 'Şehirler', + 'journey.stats.entries': 'Kayıtlar', + 'journey.stats.photos': 'Fotoğraflar', + 'journey.stats.places': 'Yer', + 'journey.skeletons.show': 'Önerileri göster', + 'journey.skeletons.hide': 'Önerileri gizle', + 'journey.verdict.lovedIt': 'Çok beğendim', + 'journey.verdict.couldBeBetter': 'Daha iyi olabilirdi', + 'journey.synced.places': 'yer', + 'journey.synced.synced': 'senkronize', + 'journey.editor.discardChangesConfirm': + 'Kaydedilmemiş değişiklikleriniz var. Vazgeçilsin mi?', + 'journey.editor.uploadPhotos': 'Fotoğraf yükle', + 'journey.editor.uploading': 'Yükleniyor...', + 'journey.editor.fromGallery': 'Galeriden', + 'journey.editor.allPhotosAdded': 'Tüm fotoğraflar zaten eklendi', + 'journey.editor.writeStory': 'Hikâyenizi yazın...', + 'journey.editor.prosCons': 'Artılar ve Eksiler', + 'journey.editor.pros': 'Artılar', + 'journey.editor.cons': 'Eksiler', + 'journey.editor.proPlaceholder': 'Harika bir şey...', + 'journey.editor.conPlaceholder': 'Pek iyi değildi...', + 'journey.editor.addAnother': 'Bir tane daha ekle', + 'journey.editor.date': 'Tarih', + 'journey.editor.location': 'Konum', + 'journey.editor.searchLocation': 'Konum ara...', + 'journey.editor.mood': 'Ruh hali', + 'journey.editor.weather': 'Hava durumu', + 'journey.editor.photoFirst': '1.', + 'journey.editor.makeFirst': '1. yap', + 'journey.editor.searching': 'Aranıyor...', + 'journey.mood.amazing': 'Muhteşem', + 'journey.mood.good': 'İyi', + 'journey.mood.neutral': 'Nötr', + 'journey.mood.rough': 'Zor', + 'journey.weather.sunny': 'Güneşli', + 'journey.weather.partly': 'Parçalı bulutlu', + 'journey.weather.cloudy': 'Bulutlu', + 'journey.weather.rainy': 'Yağmurlu', + 'journey.weather.stormy': 'Fırtınalı', + 'journey.weather.cold': 'Karlı', + 'journey.trips.linkTrip': 'Seyahat Bağla', + 'journey.trips.searchTrip': 'Seyahat Ara', + 'journey.trips.searchPlaceholder': 'Seyahat adı veya destinasyon...', + 'journey.trips.noTripsAvailable': 'Kullanılabilir seyahat yok', + 'journey.trips.link': 'Bağla', + 'journey.trips.tripLinked': 'Seyahat bağlandı', + 'journey.trips.linkFailed': 'Seyahat bağlanamadı', + 'journey.trips.addTrip': 'Seyahat Ekle', + 'journey.trips.unlinkTrip': 'Seyahat bağlantısını kaldır', + 'journey.trips.unlinkMessage': + '"{title}" bağlantısı kaldırılsın mı? Bu seyahatten senkronize tüm kayıtlar ve fotoğraflar kalıcı olarak silinecek. Bu işlem geri alınamaz.', + 'journey.trips.unlink': 'Bağlantıyı kaldır', + 'journey.trips.tripUnlinked': 'Seyahat bağlantısı kaldırıldı', + 'journey.trips.unlinkFailed': 'Seyahat bağlantısı kaldırılamadı', + 'journey.trips.noTripsLinkedSettings': 'Bağlı seyahat yok', + 'journey.contributors.invite': 'Katkıda bulunan davet et', + 'journey.contributors.searchUser': 'Kullanıcı Ara', + 'journey.contributors.searchPlaceholder': 'Kullanıcı adı veya e-posta...', + 'journey.contributors.noUsers': 'Kullanıcı bulunamadı', + 'journey.contributors.role': 'Rol', + 'journey.contributors.added': 'Katkıda bulunan eklendi', + 'journey.contributors.addFailed': 'Katkıda bulunan eklenemedi', + 'journey.contributors.remove': 'Katkıda bulunanı kaldır', + 'journey.contributors.removeConfirm': + "{username} bu journey'den kaldırılsın mı?", + 'journey.contributors.removed': 'Katkıda bulunan kaldırıldı', + 'journey.contributors.removeFailed': 'Katkıda bulunan kaldırılamadı', + 'journey.share.publicShare': 'Herkese açık paylaşım', + 'journey.share.createLink': 'Paylaşım bağlantısı oluştur', + 'journey.share.linkCreated': 'Paylaşım bağlantısı oluşturuldu', + 'journey.share.createFailed': 'Bağlantı oluşturulamadı', + 'journey.share.copy': 'Kopyala', + 'journey.share.copied': 'Kopyalandı!', + 'journey.share.timeline': 'Zaman çizelgesi', + 'journey.share.gallery': 'Galeri', + 'journey.share.map': 'Harita', + 'journey.share.removeLink': 'Paylaşım bağlantısını kaldır', + 'journey.share.linkDeleted': 'Paylaşım bağlantısı silindi', + 'journey.share.deleteFailed': 'Silinemedi', + 'journey.share.updateFailed': 'Güncelleme başarısız oldu', + 'journey.invite.role': 'Rol', + 'journey.invite.viewer': 'Görüntüleyici', + 'journey.invite.editor': 'Düzenleyici', + 'journey.invite.invite': 'Davet et', + 'journey.invite.inviting': 'Davet ediliyor...', + 'journey.settings.title': 'Journey Ayarları', + 'journey.settings.coverImage': 'Kapak Görseli', + 'journey.settings.changeCover': 'Kapağı değiştir', + 'journey.settings.addCover': 'Kapak görseli ekle', + 'journey.settings.name': 'İsim', + 'journey.settings.subtitle': 'Alt başlık', + 'journey.settings.subtitlePlaceholder': 'örn. Tayland, Vietnam ve Kamboçya', + 'journey.settings.endJourney': "Journey'i Arşivle", + 'journey.settings.reopenJourney': "Journey'i geri aç", + 'journey.settings.archived': 'Journey arşivlendi', + 'journey.settings.reopened': 'Journey yeniden açıldı', + 'journey.settings.endDescription': + 'Canlı rozetini gizler. İstediğiniz zaman yeniden açabilirsiniz.', + 'journey.settings.delete': 'Sil', + 'journey.settings.deleteJourney': "Journey'i Sil", + 'journey.settings.deleteMessage': + '"{title}" silinsin mi? Tüm kayıtlar ve fotoğraflar kaybolacak.', + 'journey.settings.saved': 'Ayarlar kaydedildi', + 'journey.settings.saveFailed': 'Kaydedilemedi', + 'journey.settings.coverUpdated': 'Kapak güncellendi', + 'journey.settings.coverFailed': 'Yükleme başarısız oldu', + 'journey.settings.failedToDelete': 'Silinemedi', + 'journey.entries.deleteTitle': 'Kaydı Sil', + 'journey.photosUploaded': '{count} fotoğraf yüklendi', + 'journey.photosAdded': '{count} fotoğraf eklendi', + 'journey.public.notFound': 'Bulunamadı', + 'journey.public.notFoundMessage': + "This journey doesn't exist or the link has expired.", + 'journey.public.readOnly': 'Salt okunur · Herkese açık Journey', + 'journey.public.tagline': 'Seyahat Kaynak ve Keşif Kiti', + 'journey.public.sharedVia': 'Şununla paylaşıldı:', + 'journey.public.madeWith': 'İle yapıldı', + 'journey.pdf.journeyBook': 'Journey Kitabı', + 'journey.pdf.madeWith': 'TREK ile Yapıldı', + 'journey.pdf.day': 'Gün', + 'journey.pdf.theEnd': 'Son', + 'journey.pdf.saveAsPdf': 'PDF olarak Kaydet', + 'journey.pdf.pages': 'sayfa', + 'journey.picker.tripPeriod': 'Seyahat Dönemi', + 'journey.picker.dateRange': 'Tarih Aralığı', + 'journey.picker.allPhotos': 'Tüm Fotoğraflar', + 'journey.picker.albums': 'Albümler', + 'journey.picker.selected': 'seçildi', + 'journey.picker.addTo': 'Ekle:', + 'journey.picker.newGallery': 'Yeni Galeri', + 'journey.picker.selectAll': 'Tümünü seç', + 'journey.picker.deselectAll': 'Tümünün seçimini kaldır', + 'journey.picker.noAlbums': 'Albüm bulunamadı', + 'journey.picker.selectDate': 'Tarih seç', + 'journey.picker.search': 'Ara', + 'journey.editor.uploadingProgress': '{done}/{total} yükleniyor…', + 'journey.editor.uploadFailed': 'Fotoğraf yüklenemedi', + 'journey.editor.uploadPartialFailed': + '{total} fotoğraftan {failed} tanesi başarısız — tekrar denemek için kaydedin', + 'journey.photosUploadFailed': 'Bazı fotoğraflar yüklenemedi', +}; +export default journey; diff --git a/shared/src/i18n/tr/login.ts b/shared/src/i18n/tr/login.ts new file mode 100644 index 0000000000000000000000000000000000000000..800565057aa0d19daaf5ea2ff8f4190c189f840d --- /dev/null +++ b/shared/src/i18n/tr/login.ts @@ -0,0 +1,104 @@ +import type { TranslationStrings } from '../types'; + +const login: TranslationStrings = { + 'login.error': + 'Giriş başarısız oldu. Lütfen kimlik bilgilerinizi kontrol edin.', + 'login.tagline': 'Gezileriniz.\\nPlanınız.', + 'login.description': + 'Etkileşimli haritalar, bütçeler ve gerçek zamanlı senkronizasyonla gezileri işbirliği içinde planlayın.', + 'login.features.maps': 'İnteraktif Haritalar', + 'login.features.mapsDesc': 'Google Rehber, rotalar ve kümeleme', + 'login.features.realtime': 'Gerçek Zamanlı Senkronizasyon', + 'login.features.realtimeDesc': 'WebSocket aracılığıyla birlikte plan yapın', + 'login.features.budget': 'Bütçe Takibi', + 'login.features.budgetDesc': 'Kategoriler, grafikler ve kişi başı maliyetler', + 'login.features.collab': 'İşbirliği', + 'login.features.collabDesc': 'Paylaşılan gezilerle çok kullanıcılı', + 'login.features.packing': 'Paketleme Listeleri', + 'login.features.packingDesc': 'Kategoriler, ilerleme ve öneriler', + 'login.features.bookings': 'Rezervasyonlar', + 'login.features.bookingsDesc': + 'Uçuşlar, oteller, restoranlar ve daha fazlası', + 'login.features.files': 'Belgeler', + 'login.features.filesDesc': 'Belgeleri yükleyin ve yönetin', + 'login.features.routes': 'Akıllı Rotalar', + 'login.features.routesDesc': + "Otomatik optimize etme ve Google Haritalar'ı dışa aktarma", + 'login.selfHosted': + 'Kendi kendine barındırılan \\u00B7 Açık Kaynak \\u00B7 Verileriniz size ait kalır', + 'login.title': 'Oturum Aç', + 'login.subtitle': 'Tekrar hoş geldiniz', + 'login.signingIn': 'Oturum açılıyor…', + 'login.signIn': 'Oturum Aç', + 'login.createAdmin': 'Yönetici Hesabı Oluştur', + 'login.createAdminHint': 'TREK için ilk yönetici hesabını kurun.', + 'login.setNewPassword': 'Yeni Şifre Belirle', + 'login.setNewPasswordHint': 'Devam etmeden önce şifrenizi değiştirmelisiniz.', + 'login.createAccount': 'Hesap Oluşturmak', + 'login.createAccountHint': 'Yeni bir hesap kaydedin.', + 'login.creating': 'Oluşturuluyor…', + 'login.noAccount': "Don't have an account?", + 'login.hasAccount': 'Zaten bir hesabınız var mı?', + 'login.register': 'Kayıt olmak', + 'login.emailPlaceholder': 'sizin@e-postanız.com', + 'login.username': 'Kullanıcı adı', + 'login.oidc.registrationDisabled': + 'Kayıt devre dışı bırakıldı. Yöneticinizle iletişime geçin.', + 'login.oidc.noEmail': 'Sağlayıcıdan e-posta alınmadı.', + 'login.oidc.tokenFailed': 'Kimlik doğrulama başarısız oldu.', + 'login.oidc.invalidState': 'Geçersiz oturum. Lütfen tekrar deneyin.', + 'login.demoFailed': 'Demo girişi başarısız oldu', + 'login.oidcSignIn': '{name} ile oturum açın', + 'login.oidcOnly': + 'Parola kimlik doğrulaması devre dışı. Lütfen SSO sağlayıcınızı kullanarak oturum açın.', + 'login.oidcLoggedOut': + 'Çıkış yaptınız. SSO sağlayıcınızı kullanarak tekrar oturum açın.', + 'login.demoHint': 'Demoyu deneyin; kayıt olmanıza gerek yok', + 'login.mfaTitle': 'İki faktörlü kimlik doğrulama', + 'login.mfaSubtitle': 'Kimlik doğrulayıcı uygulamanızdan 6 haneli kodu girin.', + 'login.mfaCodeLabel': 'Doğrulama kodu', + 'login.mfaCodeRequired': 'Kimlik doğrulayıcı uygulamanızdan kodu girin.', + 'login.mfaHint': + "Google Authenticator'ı, Authy'yi veya başka bir TOTP uygulamasını açın.", + 'login.mfaBack': '← Oturum açmaya geri dön', + 'login.mfaVerify': 'Doğrula', + 'login.invalidInviteLink': 'Geçersiz veya süresi dolmuş davet bağlantısı', + 'login.oidcFailed': 'OIDC girişi başarısız oldu', + 'login.usernameRequired': 'Kullanıcı adı gerekli', + 'login.passwordMinLength': 'Şifre en az 8 karakter olmalıdır', + 'login.forgotPassword': 'Parolanızı mı unuttunuz?', + 'login.rememberMe': 'Beni hatırla', + 'login.forgotPasswordTitle': 'Şifrenizi sıfırlayın', + 'login.forgotPasswordBody': + "Enter the email address you signed up with. If an account exists, we'll send a reset link.", + 'login.forgotPasswordSubmit': 'Sıfırlama bağlantısını gönder', + 'login.forgotPasswordSentTitle': 'E-postanızı kontrol edin', + 'login.forgotPasswordSentBody': + 'Söz konusu e-posta için bir hesap mevcutsa sıfırlama bağlantısı yolda olacaktır. 60 dakika içinde sona erer.', + 'login.forgotPasswordSmtpHintOff': + "Heads up: your administrator hasn't configured SMTP, so the reset link will be written to the server console instead of being emailed.", + 'login.backToLogin': 'Oturum açmak için geri dön', + 'login.newPassword': 'Yeni Şifre', + 'login.confirmPassword': 'Yeni şifreyi onayla', + 'login.passwordsDontMatch': 'Şifreler eşleşmiyor', + 'login.mfaCode': '2FA kodu', + 'login.resetPasswordTitle': 'Yeni bir şifre belirleyin', + 'login.resetPasswordBody': + 'Daha önce burada kullanmadığınız güçlü bir şifre seçin. Minimum 8 karakter.', + 'login.resetPasswordMfaBody': + 'Sıfırlamayı tamamlamak için 2FA kodunuzu veya yedek kodu girin.', + 'login.resetPasswordSubmit': 'Şifreyi sıfırla', + 'login.resetPasswordVerify': 'Doğrula ve sıfırla', + 'login.resetPasswordSuccessTitle': 'Şifre güncellendi', + 'login.resetPasswordSuccessBody': + 'Artık yeni şifrenizle giriş yapabilirsiniz.', + 'login.resetPasswordInvalidLink': 'Geçersiz sıfırlama bağlantısı', + 'login.resetPasswordInvalidLinkBody': + 'Bu bağlantı eksik veya bozuk. Devam etmek için yeni bir tane isteyin.', + 'login.resetPasswordFailed': + 'Sıfırlama başarısız oldu. Bağlantının süresi dolmuş olabilir.', + 'login.passkey.signIn': 'Passkey ile oturum açın', + 'login.passkey.failed': + 'Passkey ile oturum açma başarısız oldu. Lütfen tekrar deneyin.', +}; +export default login; diff --git a/shared/src/i18n/tr/map.ts b/shared/src/i18n/tr/map.ts new file mode 100644 index 0000000000000000000000000000000000000000..4a0854d66daad0e9afd19bc0546451c7a454311d --- /dev/null +++ b/shared/src/i18n/tr/map.ts @@ -0,0 +1,17 @@ +import type { TranslationStrings } from '../types'; + +const map: TranslationStrings = { + 'map.connections': 'Bağlantılar', + 'map.showConnections': 'Rezervasyon rotalarını göster', + 'map.hideConnections': 'Rezervasyon rotalarını gizle', + 'poi.searchThisArea': 'Bu alanda ara', + 'poi.cat.restaurants': 'Restoranlar', + 'poi.cat.cafes': 'Kafeler', + 'poi.cat.bars': 'Bar ve gece hayatı', + 'poi.cat.hotels': 'Konaklama', + 'poi.cat.sights': 'Gezilecek yerler', + 'poi.cat.museums': 'Müzeler ve kültür', + 'poi.cat.nature': 'Doğa ve parklar', + 'poi.cat.activities': 'Aktiviteler', +}; +export default map; diff --git a/shared/src/i18n/tr/members.ts b/shared/src/i18n/tr/members.ts new file mode 100644 index 0000000000000000000000000000000000000000..35275e42b6f5cc46abfed3fab2bf32322e86e80f --- /dev/null +++ b/shared/src/i18n/tr/members.ts @@ -0,0 +1,25 @@ +import type { TranslationStrings } from '../types'; + +const members: TranslationStrings = { + 'members.shareTrip': 'Seyahati Paylaş', + 'members.inviteUser': 'Kullanıcı davet et', + 'members.selectUser': 'Kullanıcı seç…', + 'members.invite': 'Davet et', + 'members.allHaveAccess': 'Tüm kullanıcıların zaten erişimi var.', + 'members.access': 'Erişim', + 'members.person': 'kişi', + 'members.persons': 'kişi', + 'members.you': 'siz', + 'members.owner': 'Sahip', + 'members.leaveTrip': 'Seyahatten ayrıl', + 'members.removeAccess': 'Erişimi kaldır', + 'members.confirmLeave': + 'Seyahatten ayrılmak İstiyor musunuz? Erişiminizi kaybedersiniz.', + 'members.confirmRemove': 'Bu kullanıcının erişimi kaldırılsın mı?', + 'members.loadError': 'Üyeler yüklenemedi', + 'members.added': 'eklendi', + 'members.addError': 'Eklenemedi', + 'members.removed': 'Üye kaldırıldı', + 'members.removeError': 'Kaldırılamadı', +}; +export default members; diff --git a/shared/src/i18n/tr/memories.ts b/shared/src/i18n/tr/memories.ts new file mode 100644 index 0000000000000000000000000000000000000000..3d05a1df16074ab6f386ff67fa95fa58971f4713 --- /dev/null +++ b/shared/src/i18n/tr/memories.ts @@ -0,0 +1,81 @@ +import type { TranslationStrings } from '../types'; + +const memories: TranslationStrings = { + 'memories.title': 'Fotoğraflar', + 'memories.notConnected': '{provider_name} bağlı değil', + 'memories.notConnectedHint': + "Bu seyahate fotoğraf eklemek için Ayarlar'dan {provider_name} örneğinizi bağlayın.", + 'memories.notConnectedMultipleHint': + "Bu seyahate fotoğraf eklemek için Ayarlar'dan şu fotoğraf sağlayıcılarından birini bağlayın: {provider_names}", + 'memories.noDates': 'Fotoğrafları yüklemek için seyahatinize tarih ekleyin.', + 'memories.noPhotos': 'Fotoğraf bulunamadı', + 'memories.noPhotosHint': + "No photos found in {provider_name} for this trip's date range.", + 'memories.photosFound': 'fotoğraf', + 'memories.fromOthers': 'başkalarından', + 'memories.sharePhotos': 'Fotoğrafları paylaş', + 'memories.sharing': 'Paylaşma', + 'memories.reviewTitle': 'Fotoğraflarınızı gözden geçirin', + 'memories.reviewHint': 'Paylaşımdan hariç tutmak için fotoğraflara tıklayın.', + 'memories.shareCount': '{count} Fotoğraf paylaş', + 'memories.providerUrl': "Sunucu URL'si", + 'memories.providerApiKey': 'API Anahtarı', + 'memories.providerUsername': 'Kullanıcı adı', + 'memories.providerPassword': 'Şifre', + 'memories.providerOTP': 'MFA kodu (etkinse)', + 'memories.skipSSLVerification': 'SSL Sertifika doğrulamasını atla', + 'memories.immichAutoUpload': + "Journey fotoğraflarını yüklerken Immich'e yansıt", + 'memories.providerUrlHintSynology': + "URL'ye Photos uygulama yolunu ekleyin, örn. https://nas:5001/photo", + 'memories.testConnection': 'Bağlantıyı test et', + 'memories.testShort': 'Dene', + 'memories.testFirst': 'Önce bağlantıyı test edin', + 'memories.connected': 'Bağlı', + 'memories.disconnected': 'Bağlı değil', + 'memories.connectionSuccess': '{provider_name} ile bağlandı', + 'memories.connectionError': '{provider_name} ile bağlanılamadı', + 'memories.saved': '{provider_name} ayarları kaydedildi', + 'memories.providerDisconnectedBanner': + "{provider_name} Bağlantınız kesildi. Fotoğrafları görmek için Ayarlar'dan yeniden bağlanın.", + 'memories.saveError': '{provider_name} Ayarları kaydedilemedi', + 'memories.addPhotos': 'Fotoğraf ekle', + 'memories.linkAlbum': 'Albüm Bağla', + 'memories.selectAlbum': '{provider_name} Albümü Seç', + 'memories.selectAlbumMultiple': 'Albüm Seç', + 'memories.noAlbums': 'Albüm bulunamadı', + 'memories.syncAlbum': 'Albümü senkronize et', + 'memories.unlinkAlbum': 'Albüm bağlantısını kaldır', + 'memories.photos': 'fotoğraf', + 'memories.selectPhotos': '{provider_name} Fotoğraflarını seç', + 'memories.selectPhotosMultiple': 'Fotoğraf Seç', + 'memories.selectHint': 'Seçmek için fotoğraflara dokunun.', + 'memories.selected': 'seçildi', + 'memories.addSelected': '{count} Fotoğraf ekle', + 'memories.alreadyAdded': 'Eklendi', + 'memories.private': 'Gizli', + 'memories.stopSharing': 'Paylaşımı durdur', + 'memories.oldest': 'En eski önce', + 'memories.newest': 'En yeni önce', + 'memories.allLocations': 'Tüm konumlar', + 'memories.tripDates': 'Seyahat tarihleri', + 'memories.allPhotos': 'Tüm fotoğraflar', + 'memories.confirmShareTitle': 'Seyahat üyeleriyle paylaşılsın mı?', + 'memories.confirmShareHint': + '{count} fotoğraf bu seyahatin tüm üyelerine görünür olacak. Daha sonra tek tek gizli yapabilirsiniz.', + 'memories.confirmShareButton': 'Fotoğrafları paylaş', + 'memories.error.loadAlbums': 'Albümler yüklenemedi', + 'memories.error.linkAlbum': 'Albüm bağlanamadı', + 'memories.error.unlinkAlbum': 'Albüm bağlantısı kaldırılamadı', + 'memories.error.syncAlbum': 'Albüm senkronize edilemedi', + 'memories.error.loadPhotos': 'Fotoğraflar yüklenemedi', + 'memories.error.addPhotos': 'Fotoğraflar eklenemedi', + 'memories.error.removePhoto': 'Fotoğraf kaldırılamadı', + 'memories.error.toggleSharing': 'Paylaşım güncellenemedi', + 'memories.saveRouteNotConfigured': + 'Bu sağlayıcı için kaydetme yolu yapılandırılmamış', + 'memories.testRouteNotConfigured': + 'Bu sağlayıcı için test yolu yapılandırılmamış', + 'memories.fillRequiredFields': 'Lütfen tüm zorunlu alanları doldurun', +}; +export default memories; diff --git a/shared/src/i18n/tr/nav.ts b/shared/src/i18n/tr/nav.ts new file mode 100644 index 0000000000000000000000000000000000000000..3e16c37d7c0c8f98e87f97caa8ab2198f0ec2557 --- /dev/null +++ b/shared/src/i18n/tr/nav.ts @@ -0,0 +1,20 @@ +import type { TranslationStrings } from '../types'; + +const nav: TranslationStrings = { + 'nav.trip': 'Seyahat', + 'nav.share': 'Paylaş', + 'nav.settings': 'Ayarlar', + 'nav.admin': 'Yönetici', + 'nav.logout': 'Çıkış yap', + 'nav.lightMode': 'Açık Tema', + 'nav.darkMode': 'Koyu Tema', + 'nav.autoMode': 'Otomatik Tema', + 'nav.administrator': 'Yönetici', + 'nav.myTrips': 'Seyahatlerim', + 'nav.profile': 'Profil', + 'nav.bottomSettings': 'Ayarlar', + 'nav.bottomAdmin': 'Yönetici Ayarları', + 'nav.bottomLogout': 'Çıkış', + 'nav.bottomAdminBadge': 'Yönetici', +}; +export default nav; diff --git a/shared/src/i18n/tr/notif.ts b/shared/src/i18n/tr/notif.ts new file mode 100644 index 0000000000000000000000000000000000000000..c6ca2fea78e76514405a24bd29ec00a532682964 --- /dev/null +++ b/shared/src/i18n/tr/notif.ts @@ -0,0 +1,45 @@ +import type { TranslationStrings } from '../types'; + +const notif: TranslationStrings = { + 'notif.test.title': '[Test] Bildirim', + 'notif.test.simple.text': 'Bu basit bir test bildirimidir.', + 'notif.test.boolean.text': 'Bu test bildirimini kabul ediyor musunuz?', + 'notif.test.navigate.text': 'Gösterge paneline gitmek için aşağıya tıklayın.', + 'notif.trip_invite.title': 'Seyahat Daveti', + 'notif.trip_invite.text': '{actor} sizi {trip} seyahatine davet etti', + 'notif.booking_change.title': 'Rezervasyon Güncellendi', + 'notif.booking_change.text': + '{actor}, {trip} içindeki bir rezervasyonu güncelledi', + 'notif.trip_reminder.title': 'Seyahat Hatırlatıcısı', + 'notif.trip_reminder.text': '{trip} Seyahatiniz yaklaşıyor!', + 'notif.todo_due.title': 'Yapılacak vadesi', + 'notif.todo_due.text': '{trip} içindeki {todo} — son tarih: {due}', + 'notif.vacay_invite.title': 'Vacay Birleştirme Daveti', + 'notif.vacay_invite.text': + '{actor} tatil planlarını birleştirmeniz için sizi davet etti', + 'notif.photos_shared.title': 'Fotoğraflar Paylaşıldı', + 'notif.photos_shared.text': + '{actor}, {trip} içinde {count} fotoğraf paylaştı', + 'notif.collab_message.title': 'Yeni Mesaj', + 'notif.collab_message.text': '{actor}, {trip} içinde mesaj gönderdi', + 'notif.packing_tagged.title': 'Paket listesi ataması', + 'notif.packing_tagged.text': + '{actor} sizi {trip} içinde {category} kategorisine atadı', + 'notif.version_available.title': 'Yeni Sürüm Mevcut', + 'notif.version_available.text': 'TREK {version} artık kullanılabilir', + 'notif.action.view_trip': 'Seyahati Görüntüle', + 'notif.action.view_collab': 'Mesajları Görüntüle', + 'notif.action.view_packing': 'Paket listesini görüntüle', + 'notif.action.view_photos': 'Fotoğrafları Görüntüle', + 'notif.action.view_vacay': "Vacay'ı Görüntüle", + 'notif.action.view_admin': 'Yöneticiye git', + 'notif.action.view': 'Görüntüle', + 'notif.action.accept': 'Kabul et', + 'notif.action.decline': 'Reddet', + 'notif.generic.title': 'Bildirim', + 'notif.generic.text': 'Yeni bir bildiriminiz var', + 'notif.dev.unknown_event.title': '[GEL] Bilinmeyen Olay', + 'notif.dev.unknown_event.text': + '"{event}" olay türü EVENT_NOTIFICATION_CONFIG içinde kayıtlı değil', +}; +export default notif; diff --git a/shared/src/i18n/tr/notifications.ts b/shared/src/i18n/tr/notifications.ts new file mode 100644 index 0000000000000000000000000000000000000000..3ae5243f8773549fdc77abb8c64bb3d58dc973f5 --- /dev/null +++ b/shared/src/i18n/tr/notifications.ts @@ -0,0 +1,39 @@ +import type { TranslationStrings } from '../types'; + +const notifications: TranslationStrings = { + 'notifications.title': 'Bildirimler', + 'notifications.markAllRead': 'Tümünü okundu işaretle', + 'notifications.deleteAll': 'Tümünü sil', + 'notifications.showAll': 'Tüm bildirimleri göster', + 'notifications.empty': 'Bildirim yok', + 'notifications.emptyDescription': "You're all caught up!", + 'notifications.all': 'Tümü', + 'notifications.unreadOnly': 'Okunmamış', + 'notifications.markRead': 'Okundu işaretle', + 'notifications.markUnread': 'Okunmadı işaretle', + 'notifications.delete': 'Sil', + 'notifications.system': 'Sistem', + 'notifications.synologySessionCleared.title': + 'Synology Photos bağlantısı kesildi', + 'notifications.synologySessionCleared.text': + "Sunucunuz veya hesabınız değişti — bağlantıyı test etmek için Ayarlar'a gidin.", + 'notifications.versionAvailable.title': 'Güncelleme Mevcut', + 'notifications.versionAvailable.text': 'TREK {version} artık kullanılabilir.', + 'notifications.versionAvailable.button': 'Ayrıntıları Görüntüle', + 'notifications.test.title': '{actor} Kaynaklı test bildirimi', + 'notifications.test.text': 'Bu basit bir test bildirimidir.', + 'notifications.test.booleanTitle': '{actor} onayınızı istiyor', + 'notifications.test.booleanText': + 'Bu bir test boolean bildirimidir. Aşağıdan bir eylem seçin.', + 'notifications.test.accept': 'Onayla', + 'notifications.test.decline': 'Reddet', + 'notifications.test.navigateTitle': 'Bir şeye göz atın', + 'notifications.test.navigateText': 'Bu bir test navigasyon bildirimidir.', + 'notifications.test.goThere': 'Git', + 'notifications.test.adminTitle': 'Yönetici yayını', + 'notifications.test.adminText': + '{actor} tüm yöneticilere test bildirimi gönderdi.', + 'notifications.test.tripTitle': '{actor} seyahatinizde bir şey paylaştı', + 'notifications.test.tripText': '"{trip}" seyahati için test bildirimi.', +}; +export default notifications; diff --git a/shared/src/i18n/tr/oauth.ts b/shared/src/i18n/tr/oauth.ts new file mode 100644 index 0000000000000000000000000000000000000000..70936b1a3c8969fec8417bbe51a30f806290d75c --- /dev/null +++ b/shared/src/i18n/tr/oauth.ts @@ -0,0 +1,123 @@ +import type { TranslationStrings } from '../types'; + +const oauth: TranslationStrings = { + 'oauth.scope.group.trips': 'Geziler', + 'oauth.scope.group.places': 'Yer', + 'oauth.scope.group.atlas': 'Atlas', + 'oauth.scope.group.packing': 'Ambalaj', + 'oauth.scope.group.todos': 'Yapılacaklar', + 'oauth.scope.group.budget': 'Bütçe', + 'oauth.scope.group.reservations': 'Rezervasyonlar', + 'oauth.scope.group.collab': 'İşbirliği', + 'oauth.scope.group.notifications': 'Bildirimler', + 'oauth.scope.group.vacay': 'Tatil', + 'oauth.scope.group.geo': 'Coğrafi', + 'oauth.scope.group.weather': 'Hava durumu', + 'oauth.scope.group.journey': 'Seyahat', + 'oauth.scope.trips:read.label': 'Seyahatleri ve programları görüntüle', + 'oauth.scope.trips:read.description': + 'Seyahatleri, günleri, gün notlarını ve üyeleri oku', + 'oauth.scope.trips:write.label': 'Seyahatleri ve programları düzenle', + 'oauth.scope.trips:write.description': + 'Seyahatleri, günleri, notları oluştur ve güncelle; üyeleri yönet', + 'oauth.scope.trips:delete.label': 'Seyahatleri sil', + 'oauth.scope.trips:delete.description': + 'Tüm seyahatleri kalıcı olarak sil — bu işlem geri alınamaz', + 'oauth.scope.trips:share.label': 'Paylaşım bağlantılarını yönet', + 'oauth.scope.trips:share.description': + 'Seyahatler için herkese açık paylaşım bağlantıları oluştur, güncelle ve iptal et', + 'oauth.scope.places:read.label': 'Yerleri ve harita verilerini görüntüle', + 'oauth.scope.places:read.description': + 'Yerleri, gün atamalarını, etiketleri ve kategorileri oku', + 'oauth.scope.places:write.label': 'Yerleri yönet', + 'oauth.scope.places:write.description': + 'Yerleri, atamaları ve etiketleri oluştur, güncelle ve sil', + 'oauth.scope.atlas:read.label': "Atlas'ı Görüntüle", + 'oauth.scope.atlas:read.description': + 'Ziyaret edilen ülkeleri, bölgeleri ve yapılacaklar listesini oku', + 'oauth.scope.atlas:write.label': "Atlas'ı Yönet", + 'oauth.scope.atlas:write.description': + 'Ülke ve bölgeleri ziyaret edildi olarak işaretle, yapılacaklar listesini yönet', + 'oauth.scope.packing:read.label': 'Paket listelerini görüntüle', + 'oauth.scope.packing:read.description': + 'Paket öğelerini, çantaları ve kategori atamalarını oku', + 'oauth.scope.packing:write.label': 'Paket listelerini yönet', + 'oauth.scope.packing:write.description': + 'Paket öğelerini ve çantaları ekle, güncelle, sil, işaretle ve yeniden sırala', + 'oauth.scope.todos:read.label': 'Yapılacak listelerini görüntüle', + 'oauth.scope.todos:read.description': + 'Seyahat yapılacak öğelerini ve kategori atamalarını oku', + 'oauth.scope.todos:write.label': 'Yapılacak listelerini yönet', + 'oauth.scope.todos:write.description': + 'Yapılacak öğeleri oluştur, güncelle, işaretle, sil ve yeniden sırala', + 'oauth.scope.budget:read.label': 'Bütçeyi görüntüle', + 'oauth.scope.budget:read.description': + 'Bütçe kalemlerini ve harcama dökümünü oku', + 'oauth.scope.budget:write.label': 'Bütçeyi yönet', + 'oauth.scope.budget:write.description': + 'Bütçe kalemlerini oluştur, güncelle ve sil', + 'oauth.scope.reservations:read.label': 'Rezervasyonları görüntüle', + 'oauth.scope.reservations:read.description': + 'Rezervasyonları ve konaklama ayrıntılarını oku', + 'oauth.scope.reservations:write.label': 'Rezervasyonları yönet', + 'oauth.scope.reservations:write.description': + 'Rezervasyonları oluştur, güncelle, sil ve yeniden sırala', + 'oauth.scope.collab:read.label': 'İşbirliğini görüntüle', + 'oauth.scope.collab:read.description': + 'İşbirliği notlarını, anketleri ve mesajları oku', + 'oauth.scope.collab:write.label': 'İşbirliğini yönet', + 'oauth.scope.collab:write.description': + 'İşbirliği notlarını, anketleri ve mesajları oluştur, güncelle ve sil', + 'oauth.scope.notifications:read.label': 'Bildirimleri görüntüle', + 'oauth.scope.notifications:read.description': + 'Uygulama içi bildirimleri ve okunmamış sayıları oku', + 'oauth.scope.notifications:write.label': 'Bildirimleri yönet', + 'oauth.scope.notifications:write.description': + 'Bildirimleri okundu işaretle ve yanıtla', + 'oauth.scope.vacay:read.label': 'Tatil planlarını görüntüle', + 'oauth.scope.vacay:read.description': + 'Tatil planlama verilerini, kayıtları ve istatistikleri oku', + 'oauth.scope.vacay:write.label': 'Tatil planlarını yönet', + 'oauth.scope.vacay:write.description': + 'Tatil kayıtlarını, resmi tatilleri ve ekip planlarını oluştur ve yönet', + 'oauth.scope.geo:read.label': 'Haritalar ve coğrafi kodlama', + 'oauth.scope.geo:read.description': + "Konum ara, harita URL'lerini çöz ve koordinatları ters coğrafi kodla", + 'oauth.scope.weather:read.label': 'Hava durumu tahminleri', + 'oauth.scope.weather:read.description': + 'Seyahat konumları ve tarihleri için hava durumu tahminlerini getir', + 'oauth.scope.journey:read.label': "Journey'leri görüntüle", + 'oauth.scope.journey:read.description': + "Journey'leri, kayıtları ve katkıda bulunan listesini oku", + 'oauth.scope.journey:write.label': "Journey'leri yönet", + 'oauth.scope.journey:write.description': + "Journey'leri ve kayıtlarını oluştur, güncelle ve sil", + 'oauth.scope.journey:share.label': 'Journey bağlantılarını yönet', + 'oauth.scope.journey:share.description': + "Journey'ler için herkese açık paylaşım bağlantıları oluştur, güncelle ve iptal et", + 'oauth.authorize.authorizing': 'Authorizing…', // en-fallback + 'oauth.authorize.loading': 'Loading…', // en-fallback + 'oauth.authorize.errorTitle': 'Authorization Error', // en-fallback + 'oauth.authorize.loginTitle': 'Sign in to continue', // en-fallback + 'oauth.authorize.loginDescription': + '{client} wants access to your TREK account. Please sign in first.', // en-fallback + 'oauth.authorize.loginButton': 'Sign in to TREK', // en-fallback + 'oauth.authorize.requestLabel': 'Authorization Request', // en-fallback + 'oauth.authorize.requestDescription': + 'This application is requesting access to your TREK account.', // en-fallback + 'oauth.authorize.trustNote': + 'Only grant access to applications you trust. Your data stays on your server.', // en-fallback + 'oauth.authorize.selectScope': 'Select at least one scope', // en-fallback + 'oauth.authorize.approveOneScope': 'Approve ({count} scope)', // en-fallback + 'oauth.authorize.approveManyScopes': 'Approve ({count} scopes)', // en-fallback + 'oauth.authorize.approveAccess': 'Approve Access', // en-fallback + 'oauth.authorize.deny': 'Deny', // en-fallback + 'oauth.authorize.choosePermissions': 'Choose which permissions to grant', // en-fallback + 'oauth.authorize.permissionsRequested': 'Permissions requested', // en-fallback + 'oauth.authorize.alwaysIncluded': 'Always included', // en-fallback + 'oauth.authorize.alwaysTool.listTrips': + 'List your trips so the AI can discover trip IDs', // en-fallback + 'oauth.authorize.alwaysTool.getTripSummary': + 'Read a trip overview needed to use any other tool', // en-fallback +}; +export default oauth; diff --git a/shared/src/i18n/tr/packing.ts b/shared/src/i18n/tr/packing.ts new file mode 100644 index 0000000000000000000000000000000000000000..fd68646c2237af65007e73651316e155d869d1c6 --- /dev/null +++ b/shared/src/i18n/tr/packing.ts @@ -0,0 +1,96 @@ +import type { TranslationStrings } from '../types'; + +const packing: TranslationStrings = { + 'packing.title': 'Paket Listesi', + 'packing.empty': 'Paket listesi boş', + 'packing.import': 'İçe aktar', + 'packing.importTitle': 'Paket listesini içe aktar', + 'packing.importHint': + 'Satır başına bir öğe. Biçim: Kategori, Ad, Ağırlık (g, isteğe bağlı), Çanta (isteğe bağlı), işaretli/işaretsiz (isteğe bağlı)', + 'packing.importPlaceholder': + 'Hijyen, Diş fırçası\\nGiyim, Tişört, 200\\nBelgeler, Pasaport, , El bagajı\\nElektronik, Şarj cihazı, 50, Bavul, işaretli', + 'packing.importCsv': 'CSV/TXT Yükle', + 'packing.importAction': '{count} Öğeyi içe aktar', + 'packing.importSuccess': '{count} öğe içe aktarıldı', + 'packing.importError': 'İçe aktarma başarısız oldu', + 'packing.importEmpty': 'İçe aktarılacak öğe yok', + 'packing.progress': '{total} öğeden {packed} paketlendi (%{percent})', + 'packing.clearChecked': '{count} İşaretli öğeyi kaldır', + 'packing.clearCheckedShort': '{count} Kaldır', + 'packing.suggestions': 'Öneriler', + 'packing.suggestionsTitle': 'Öneri Ekle', + 'packing.allSuggested': 'Tüm öneriler eklendi', + 'packing.allPacked': 'Hepsi paketlendi!', + 'packing.addPlaceholder': 'Yeni öğe ekle...', + 'packing.categoryPlaceholder': 'Kategori...', + 'packing.filterAll': 'Tüm', + 'packing.filterOpen': 'Açık', + 'packing.filterDone': 'Tamamlamak', + 'packing.emptyTitle': 'Paket listesi boş', + 'packing.emptyHint': 'Öğe ekleyin veya önerileri kullanın', + 'packing.emptyFiltered': 'Bu filtreye uyan öğe yok', + 'packing.menuRename': 'Yeniden adlandır', + 'packing.menuCheckAll': 'Tümünü İşaretle', + 'packing.menuUncheckAll': 'Tüm işaretleri kaldır', + 'packing.menuDeleteCat': 'Kategoriyi Sil', + 'packing.noMembers': 'Seyahat üyesi yok', + 'packing.addItem': 'Öğe ekle', + 'packing.addItemPlaceholder': 'Öğe adı...', + 'packing.addCategory': 'Kategori ekle', + 'packing.newCategoryPlaceholder': 'Kategori adı (ör. Giyim)', + 'packing.applyTemplate': 'Şablon uygula', + 'packing.template': 'Şablon', + 'packing.templateApplied': 'Şablondan {count} öğe eklendi', + 'packing.templateError': 'Şablon uygulanamadı', + 'packing.saveAsTemplate': 'Şablon olarak kaydet', + 'packing.templateName': 'Şablon adı', + 'packing.templateSaved': 'Paket listesi şablon olarak kaydedildi', + 'packing.bags': 'Çantalar', + 'packing.noBag': 'Atanmamış', + 'packing.totalWeight': 'Toplam ağırlık', + 'packing.bagName': 'Çanta adı...', + 'packing.addBag': 'Çanta ekle', + 'packing.changeCategory': 'Kategoriyi Değiştir', + 'packing.confirm.clearChecked': + '{count} İşaretli öğeyi kaldırmak istediğinizden emin misiniz?', + 'packing.confirm.deleteCat': + '"{name}" kategorisini {count} öğeyle birlikte silmek istediğinizden emin misiniz?', + 'packing.defaultCategory': 'Diğer', + 'packing.toast.saveError': 'Kaydedilemedi', + 'packing.toast.deleteError': 'Silinemedi', + 'packing.toast.renameError': 'Yeniden adlandırılamadı', + 'packing.toast.addError': 'Eklenemedi', + 'packing.suggestions.items': [ + { name: 'Pasaport', category: 'Belgeler' }, + { name: 'Kimlik kartı', category: 'Belgeler' }, + { name: 'Seyahat sigortası', category: 'Belgeler' }, + { name: 'Uçak biletleri', category: 'Belgeler' }, + { name: 'Kredi kartı', category: 'Finans' }, + { name: 'Nakit', category: 'Finans' }, + { name: 'Vize', category: 'Belgeler' }, + { name: 'Tişört', category: 'Giyim' }, + { name: 'Pantolon', category: 'Giyim' }, + { name: 'İç çamaşırı', category: 'Giyim' }, + { name: 'Çorap', category: 'Giyim' }, + { name: 'Ceket', category: 'Giyim' }, + { name: 'Pijama', category: 'Giyim' }, + { name: 'Mayo', category: 'Giyim' }, + { name: 'Yağmurluk', category: 'Giyim' }, + { name: 'Rahat ayakkabı', category: 'Giyim' }, + { name: 'Diş fırçası', category: 'Hijyen' }, + { name: 'Diş macunu', category: 'Hijyen' }, + { name: 'Şampuan', category: 'Hijyen' }, + { name: 'Deodorant', category: 'Hijyen' }, + { name: 'Güneş kremi', category: 'Hijyen' }, + { name: 'Tıraş bıçağı', category: 'Hijyen' }, + { name: 'Şarj cihazı', category: 'Elektronik' }, + { name: 'Powerbank', category: 'Elektronik' }, + { name: 'Kulaklık', category: 'Elektronik' }, + { name: 'Seyahat adaptörü', category: 'Elektronik' }, + { name: 'Kamera', category: 'Elektronik' }, + { name: 'Ağrı kesici', category: 'Sağlık' }, + { name: 'Yara bandı', category: 'Sağlık' }, + { name: 'Dezenfektan', category: 'Sağlık' }, + ], +}; +export default packing; diff --git a/shared/src/i18n/tr/pdf.ts b/shared/src/i18n/tr/pdf.ts new file mode 100644 index 0000000000000000000000000000000000000000..f38bb75525c7b5a38ea23840b083f7ef3f730664 --- /dev/null +++ b/shared/src/i18n/tr/pdf.ts @@ -0,0 +1,10 @@ +import type { TranslationStrings } from '../types'; + +const pdf: TranslationStrings = { + 'pdf.travelPlan': 'Seyahat Planı', + 'pdf.planned': 'Planlandı', + 'pdf.costLabel': 'Maliyet EUR', + 'pdf.preview': 'PDF Önizleme', + 'pdf.saveAsPdf': 'PDF olarak Kaydet', +}; +export default pdf; diff --git a/shared/src/i18n/tr/perm.ts b/shared/src/i18n/tr/perm.ts new file mode 100644 index 0000000000000000000000000000000000000000..52372d98b0e03cc44a02da1f888840eb5d97796e --- /dev/null +++ b/shared/src/i18n/tr/perm.ts @@ -0,0 +1,65 @@ +import type { TranslationStrings } from '../types'; + +const perm: TranslationStrings = { + 'perm.title': 'İzin Ayarları', + 'perm.subtitle': + 'Uygulama genelinde kimlerin hangi işlemleri yapabileceğini belirleyin', + 'perm.saved': 'İzin ayarları kaydedildi', + 'perm.resetDefaults': 'Varsayılanlara sıfırla', + 'perm.customized': 'özelleştirildi', + 'perm.level.admin': 'Yalnızca yönetici', + 'perm.level.tripOwner': 'Seyahat sahibi', + 'perm.level.tripMember': 'Seyahat üyeleri', + 'perm.level.everybody': 'Herkes', + 'perm.cat.trip': 'Seyahat Yönetimi', + 'perm.cat.members': 'Üye Yönetimi', + 'perm.cat.files': 'Dosyalar', + 'perm.cat.content': 'İçerik ve Program', + 'perm.cat.extras': 'Bütçe, Paketleme ve İşbirliği', + 'perm.action.trip_create': 'Seyahat oluştur', + 'perm.action.trip_edit': 'Seyahat ayrıntılarını düzenle', + 'perm.action.trip_delete': 'Seyahatleri sil', + 'perm.action.trip_archive': 'Seyahatleri arşivle / geri al', + 'perm.action.trip_cover_upload': 'Kapak görseli yükle', + 'perm.action.member_manage': 'Üye ekle / kaldır', + 'perm.action.file_upload': 'Dosya yükle', + 'perm.action.file_edit': 'Dosya meta verisini düzenle', + 'perm.action.file_delete': 'Dosyaları sil', + 'perm.action.place_edit': 'Yer ekle / düzenle / sil', + 'perm.action.day_edit': 'Günleri, notları ve atamaları düzenle', + 'perm.action.reservation_edit': 'Rezervasyonları yönet', + 'perm.action.budget_edit': 'Bütçeyi yönet', + 'perm.action.packing_edit': 'Paket listelerini yönet', + 'perm.action.collab_edit': 'İşbirliği (notlar, anketler, sohbet)', + 'perm.action.share_manage': 'Paylaşım bağlantılarını yönet', + 'perm.actionHint.trip_create': 'Kimler yeni seyahat oluşturabilir', + 'perm.actionHint.trip_edit': + 'Kimler seyahat adını, tarihlerini, açıklamasını ve para birimini değiştirebilir', + 'perm.actionHint.trip_delete': 'Kimler bir seyahati kalıcı olarak silebilir', + 'perm.actionHint.trip_archive': + 'Kimler seyahati arşivleyebilir veya geri alabilir', + 'perm.actionHint.trip_cover_upload': + 'Kimler kapak görseli yükleyebilir veya değiştirebilir', + 'perm.actionHint.member_manage': + 'Kimler seyahat üyesi davet edebilir veya kaldırabilir', + 'perm.actionHint.file_upload': 'Kimler seyahate dosya yükleyebilir', + 'perm.actionHint.file_edit': + 'Kimler dosya açıklamalarını ve bağlantılarını düzenleyebilir', + 'perm.actionHint.file_delete': + 'Kimler dosyaları çöp kutusuna taşıyabilir veya kalıcı silebilir', + 'perm.actionHint.place_edit': + 'Kimler yer ekleyebilir, düzenleyebilir veya silebilir', + 'perm.actionHint.day_edit': + 'Kimler günleri, gün notlarını ve yer atamalarını düzenleyebilir', + 'perm.actionHint.reservation_edit': + 'Kimler rezervasyon oluşturabilir, düzenleyebilir veya silebilir', + 'perm.actionHint.budget_edit': + 'Kimler bütçe kalemleri oluşturabilir, düzenleyebilir veya silebilir', + 'perm.actionHint.packing_edit': + 'Kimler paket öğelerini ve çantaları yönetebilir', + 'perm.actionHint.collab_edit': + 'Kimler not, anket oluşturabilir ve mesaj gönderebilir', + 'perm.actionHint.share_manage': + 'Kimler genel paylaşım bağlantısı oluşturabilir veya silebilir', +}; +export default perm; diff --git a/shared/src/i18n/tr/photos.ts b/shared/src/i18n/tr/photos.ts new file mode 100644 index 0000000000000000000000000000000000000000..67bdbbd3528e67983994a46c8d0f054e8c272372 --- /dev/null +++ b/shared/src/i18n/tr/photos.ts @@ -0,0 +1,25 @@ +import type { TranslationStrings } from '../types'; + +const photos: TranslationStrings = { + 'photos.title': 'Fotoğraflar', + 'photos.subtitle': '{trip} için {count} fotoğraf', + 'photos.dropHere': 'Fotoğrafları buraya bırakın...', + 'photos.dropHereActive': 'Fotoğrafları buraya bırakın', + 'photos.captionForAll': 'Açıklama (hepsi için)', + 'photos.captionPlaceholder': 'İsteğe bağlı açıklama...', + 'photos.addCaption': 'Açıklama ekle...', + 'photos.allDays': 'Tüm Günler', + 'photos.noPhotos': 'Henüz fotoğraf yok', + 'photos.uploadHint': 'Seyahat fotoğraflarınızı yükleyin', + 'photos.clickToSelect': 'veya seçmek için tıklayın', + 'photos.linkPlace': 'Yere Bağla', + 'photos.noPlace': 'Yer Yok', + 'photos.uploadN': '{n} fotoğraf yükle', + 'photos.linkDay': 'Güne Bağla', + 'photos.noDay': 'Gün Yok', + 'photos.dayLabel': '{number}. gün', + 'photos.photoSelected': 'Fotoğraf seçildi', + 'photos.photosSelected': 'Fotoğraflar seçildi', + 'photos.fileTypeHint': 'JPG, PNG, WebP · maks. 10 MB · en fazla 30 fotoğraf', +}; +export default photos; diff --git a/shared/src/i18n/tr/places.ts b/shared/src/i18n/tr/places.ts new file mode 100644 index 0000000000000000000000000000000000000000..0ffd63b2b840e40292003bc73ed580ab6e52c9b3 --- /dev/null +++ b/shared/src/i18n/tr/places.ts @@ -0,0 +1,96 @@ +import type { TranslationStrings } from '../types'; + +const places: TranslationStrings = { + 'places.addPlace': 'Yer/etkinlik Ekle', + 'places.importFile': 'Dosyayı içe aktar', + 'places.sidebarDrop': 'İçe aktarmak için bırakın', + 'places.importFileHint': + 'Google Haritalarım, Google Earth veya GPS izleyici gibi araçlardan .gpx, .kml veya .kmz dosyalarını içe aktarın.', + 'places.importFileDropHere': + 'Bir dosya seçmek için tıklayın veya buraya sürükleyip bırakın', + 'places.importFileDropActive': 'Seçmek için dosyayı bırakın', + 'places.importFileUnsupported': + 'Desteklenmeyen dosya türü. .gpx, .kml veya .kmz kullanın.', + 'places.importFileTooLarge': + "Dosya çok büyük. Maksimum yükleme boyutu {maxMb} MB'tır.", + 'places.importFileError': 'İçe aktarma başarısız oldu', + 'places.importAllSkipped': 'Tüm yerler zaten yolculuktaydı.', + 'places.gpxImported': "{count} yer GPX'ten içe Aktarıldı", + 'places.gpxImportTypes': 'Neyi içe aktarmak istiyorsunuz?', + 'places.gpxImportWaypoints': 'Ara noktalar', + 'places.gpxImportRoutes': 'Rotalar', + 'places.gpxImportTracks': 'İzler (yol geometrisi ile)', + 'places.gpxImportNoneSelected': 'İçe aktarılacak en az bir tür seçin.', + 'places.kmlImportTypes': 'Neyi içe aktarmak istiyorsunuz?', + 'places.kmlImportPoints': 'Noktalar (Yer İşaretleri)', + 'places.kmlImportPaths': "Yollar (LineString'ler)", + 'places.kmlImportNoneSelected': 'İçe aktarılacak en az bir tür seçin.', + 'places.selectionCount': '{count} seçildi', + 'places.deleteSelected': 'Seçileni sil', + 'places.kmlKmzImported': "KMZ/KML'den {count} yer içe Aktarıldı", + 'places.urlResolved': "URL'den içe aktarılan Yer", + 'places.importList': 'Liste İçe Aktarma', + 'places.kmlKmzSummaryValues': + 'Yer işaretleri: {total} • İçe aktarıldı: {created} • Atlandı: {skipped}', + 'places.importGoogleList': 'Google Listesi', + 'places.importNaverList': 'Naver Listesi', + 'places.googleListHint': + 'Tüm yerleri içe aktarmak için paylaşılan bir Google Haritalar listesi bağlantısını yapıştırın.', + 'places.googleListImported': '"{list}"ten {count} yer içe aktarıldı', + 'places.googleListError': 'Google Haritalar listesi içe aktarılamadı', + 'places.naverListHint': + 'Tüm yerleri içe aktarmak için paylaşılan bir Naver Haritalar listesi bağlantısını yapıştırın.', + 'places.naverListImported': '"{list}"ten {count} yer içe aktarıldı', + 'places.naverListError': 'Naver Haritalar listesi içe aktarılamadı', + 'places.viewDetails': 'Ayrıntıları Görüntüle', + 'places.assignToDay': 'Hangi güne eklensin?', + 'places.all': 'Tüm', + 'places.unplanned': 'Planlanmamış', + 'places.filterTracks': 'Parçalar', + 'places.search': 'Yer ara...', + 'places.allCategories': 'Tüm Kategoriler', + 'places.categoriesSelected': 'kategoriler', + 'places.clearFilter': 'Filtreyi temizle', + 'places.count': '{count} yer', + 'places.countSingular': '1 yer', + 'places.allPlanned': 'Bütün yerler planlandı', + 'places.noneFound': 'Hiçbir yer bulunamadı', + 'places.editPlace': 'Yeri Düzenle', + 'places.formName': 'İsim', + 'places.formNamePlaceholder': 'örneğin Eyfel Kulesi', + 'places.formDescription': 'Tanım', + 'places.formDescriptionPlaceholder': 'Kısa açıklama...', + 'places.formAddress': 'Adres', + 'places.formAddressPlaceholder': 'Sokak, Şehir, Ülke', + 'places.formLat': 'Enlem (ör. 48,8566)', + 'places.formLng': 'Boylam (ör. 2,3522)', + 'places.formCategory': 'Kategori', + 'places.noCategory': 'Kategori Yok', + 'places.categoryNamePlaceholder': 'Kategori adı', + 'places.formTime': 'Zaman', + 'places.startTime': 'Başlangıç', + 'places.endTime': 'Son', + 'places.endTimeBeforeStart': 'Bitiş zamanı başlangıç ​​zamanından önce', + 'places.timeCollision': 'Zaman şununla çakışıyor:', + 'places.formWebsite': 'Web sitesi', + 'places.formNotes': 'Notlar', + 'places.formNotesPlaceholder': 'Kişisel notlar...', + 'places.formReservation': 'Rezervasyon', + 'places.reservationNotesPlaceholder': 'Rezervasyon notları, onay numarası...', + 'places.mapsSearchPlaceholder': 'Yerleri ara...', + 'places.mapsSearchError': 'Yer arama başarısız oldu.', + 'places.loadingDetails': 'Yer ayrıntıları yükleniyor…', + 'places.osmHint': + 'OpenStreetMap aramasını kullanma (fotoğraf, açılış saatleri veya derecelendirme yok). Tüm ayrıntılar için ayarlara bir Google API anahtarı ekleyin.', + 'places.osmActive': + "OpenStreetMap aracılığıyla arama yapın (fotoğraf, derecelendirme veya çalışma saatleri yok). Gelişmiş veriler için Ayarlar'a bir Google API anahtarı ekleyin.", + 'places.categoryCreateError': 'Kategori oluşturulamadı', + 'places.nameRequired': 'Lütfen bir ad girin', + 'places.saveError': 'Kaydedilemedi', + 'places.duplicateExists': "'{name}' zaten bu gezide var.", + 'places.addAnyway': 'Yine de ekle', + 'places.enrichOnImport': 'Yerleri Google ile zenginleştir', + 'places.enrichOnImportHint': + 'İçe aktarılan her yeri arayarak fotoğraf, adres ve iletişim bilgilerini ekler. Google Maps anahtarı gerekir.', +}; +export default places; diff --git a/shared/src/i18n/tr/planner.ts b/shared/src/i18n/tr/planner.ts new file mode 100644 index 0000000000000000000000000000000000000000..d7cfa60b10af52c48f04c56a65494ba495a9b3eb --- /dev/null +++ b/shared/src/i18n/tr/planner.ts @@ -0,0 +1,68 @@ +import type { TranslationStrings } from '../types'; + +const planner: TranslationStrings = { + 'planner.places': 'Yer', + 'planner.bookings': 'Rezervasyonlar', + 'planner.packingList': 'Paket Listesi', + 'planner.documents': 'Belgeler', + 'planner.dayPlan': 'Gün Planı', + 'planner.reservations': 'Rezervasyonlar', + 'planner.minTwoPlaces': 'En az 2 koordinatlı yer gerekli', + 'planner.noGeoPlaces': 'Koordinatlı yer bulunamadı', + 'planner.routeCalculated': 'Rota hesaplandı', + 'planner.routeCalcFailed': 'Rota hesaplanamadı', + 'planner.routeError': 'Rota hesaplanırken hata', + 'planner.icsExportFailed': 'ICS dışa aktarma başarısız', + 'planner.routeOptimized': 'Rota optimize edildi', + 'planner.reservationUpdated': 'Rezervasyon güncellendi', + 'planner.reservationAdded': 'Rezervasyon eklendi', + 'planner.confirmDeleteReservation': 'Rezervasyon silinsin mi?', + 'planner.reservationDeleted': 'Rezervasyon silindi', + 'planner.days': 'Günler', + 'planner.allPlaces': 'Tüm Yerler', + 'planner.totalPlaces': 'toplam {n} yer', + 'planner.noDaysPlanned': 'Henüz gün planlanmadı', + 'planner.editTrip': 'Seyahati düzenle →', + 'planner.placeOne': '1 yer', + 'planner.placeN': '{n} yer', + 'planner.addNote': 'Not ekle', + 'planner.noEntries': 'Bu gün için kayıt yok', + 'planner.addPlace': 'Yer/etkinlik ekle', + 'planner.addPlaceShort': '+ Yer/etkinlik ekle', + 'planner.resPending': 'Rezervasyon beklemede · ', + 'planner.resConfirmed': 'Rezervasyon onaylandı · ', + 'planner.notePlaceholder': 'Not…', + 'planner.noteTimePlaceholder': 'Saat (isteğe bağlı)', + 'planner.noteExamplePlaceholder': + "örn. Merkez istasyondan 14:30'da S3, iskele 7'den feribot, öğle molası…", + 'planner.totalCost': 'Toplam maliyet', + 'planner.searchPlaces': 'Yer ara…', + 'planner.allCategories': 'Tüm Kategoriler', + 'planner.noPlacesFound': 'Hiçbir yer bulunamadı', + 'planner.addFirstPlace': 'İlk yeri ekle', + 'planner.noReservations': 'Rezervasyon yok', + 'planner.addFirstReservation': 'İlk rezervasyonu ekle', + 'planner.new': 'Yeni', + 'planner.addToDay': '+ Gün', + 'planner.calculating': 'Hesaplanıyor…', + 'planner.route': 'Rota', + 'planner.optimize': 'Optimize et', + 'planner.openGoogleMaps': "Google Haritalar'da aç", + 'planner.selectDayHint': + 'Gün planını görmek için soldaki listeden bir gün seçin', + 'planner.noPlacesForDay': 'Bu gün için henüz yer yok', + 'planner.addPlacesLink': 'Yer ekle →', + 'planner.minTotal': 'dk. toplam', + 'planner.noReservation': 'Rezervasyon yok', + 'planner.removeFromDay': 'Günden kaldır', + 'planner.addToThisDay': 'Güne ekle', + 'planner.overview': 'Genel bakış', + 'planner.noDays': 'Henüz gün yok', + 'planner.editTripToAddDays': 'Gün eklemek için seyahati düzenleyin', + 'planner.dayCount': '{n} Gün', + 'planner.clickToUnlock': 'Kilidi açmak için tıklayın', + 'planner.keepPosition': 'Rota optimizasyonunda konumu koru', + 'planner.dayDetails': 'Gün ayrıntıları', + 'planner.dayN': '{n}. gün', +}; +export default planner; diff --git a/shared/src/i18n/tr/register.ts b/shared/src/i18n/tr/register.ts new file mode 100644 index 0000000000000000000000000000000000000000..2ac2cd7ea8d4c5483555b82ccbbda8cfae5ebb4c --- /dev/null +++ b/shared/src/i18n/tr/register.ts @@ -0,0 +1,26 @@ +import type { TranslationStrings } from '../types'; + +const register: TranslationStrings = { + 'register.passwordMismatch': 'Şifreler eşleşmiyor', + 'register.passwordTooShort': 'Şifre en az 8 karakter olmalıdır', + 'register.failed': 'Kayıt başarısız oldu', + 'register.getStarted': 'Başlayın', + 'register.subtitle': + 'Bir hesap oluşturun ve hayalinizdeki gezileri planlamaya başlayın.', + 'register.feature1': 'Sınırsız gezi planları', + 'register.feature2': 'İnteraktif harita görünümü', + 'register.feature3': 'Yerleri ve kategorileri yönetin', + 'register.feature4': 'Rezervasyonları takip edin', + 'register.feature5': 'Paketleme listeleri oluşturun', + 'register.feature6': 'Fotoğrafları ve dosyaları saklayın', + 'register.createAccount': 'Hesap Oluşturmak', + 'register.startPlanning': 'Seyahat planlamanıza başlayın', + 'register.minChars': 'Min. 6 karakter', + 'register.confirmPassword': 'Şifreyi Onayla', + 'register.repeatPassword': 'Şifreyi tekrar girin', + 'register.registering': 'Kaydediliyor...', + 'register.register': 'Kayıt olmak', + 'register.hasAccount': 'Zaten bir hesabınız var mı?', + 'register.signIn': 'Oturum Aç', +}; +export default register; diff --git a/shared/src/i18n/tr/reservations.ts b/shared/src/i18n/tr/reservations.ts new file mode 100644 index 0000000000000000000000000000000000000000..ba661801a6a94eded0390fccb8d3c658cf360afe --- /dev/null +++ b/shared/src/i18n/tr/reservations.ts @@ -0,0 +1,163 @@ +import type { TranslationStrings } from '../types'; + +const reservations: TranslationStrings = { + 'reservations.title': 'Rezervasyonlar', + 'reservations.empty': 'Henüz rezervasyon yok', + 'reservations.emptyHint': + 'Uçuşlar, oteller ve daha fazlası için rezervasyon ekleyin', + 'reservations.add': 'Rezervasyon Ekle', + 'reservations.addManual': 'Manuel Rezervasyon', + 'reservations.placeHint': + 'İpucu: Rezervasyonları doğrudan günlük planınıza bağlayacak bir yerden oluşturmak en iyisidir.', + 'reservations.confirmed': 'Onaylandı', + 'reservations.pending': 'Askıda olması', + 'reservations.summary': '{confirmed} onaylandı, {pending} beklemede', + 'reservations.fromPlan': 'Plandan', + 'reservations.showFiles': 'Dosyaları Göster', + 'reservations.editTitle': 'Rezervasyonu Düzenle', + 'reservations.status': 'Durum', + 'reservations.datetime': 'Tarih ve Saat', + 'reservations.startTime': 'Başlangıç ​​zamanı', + 'reservations.endTime': 'Bitiş zamanı', + 'reservations.date': 'Tarih', + 'reservations.time': 'Zaman', + 'reservations.timeAlt': 'Saat (alternatif, örneğin 19:30)', + 'reservations.notes': 'Notlar', + 'reservations.notesPlaceholder': 'Ek notlar...', + 'reservations.meta.airline': 'Havayolu', + 'reservations.meta.flightNumber': 'Uçuş No.', + 'reservations.meta.from': 'İtibaren', + 'reservations.meta.to': 'İle', + 'reservations.layover.route': 'Rota', + 'reservations.layover.stop': 'Durak', + 'reservations.layover.addStop': 'Durak ekle', + 'reservations.layover.connection': 'Aktarma', + 'reservations.layover.layover': 'Aktarma bekleme süresi', + 'reservations.needsReview': 'Gözden geçirmek', + 'reservations.needsReviewHint': + 'Havaalanı otomatik olarak eşleştirilemedi; lütfen konumu onaylayın.', + 'reservations.searchLocation': 'İstasyonu, limanı, adresi arayın…', + 'reservations.meta.trainNumber': 'Tren No.', + 'reservations.meta.platform': 'Platformu', + 'reservations.meta.seat': 'Koltuk', + 'reservations.meta.checkIn': 'Giriş', + 'reservations.meta.checkInUntil': 'Giriş tarihi şu tarihe kadar:', + 'reservations.meta.checkOut': 'Çıkış yapmak', + 'reservations.meta.linkAccommodation': 'Konaklama', + 'reservations.meta.pickAccommodation': 'Konaklama bağlantısı', + 'reservations.meta.noAccommodation': 'Hiçbiri', + 'reservations.meta.hotelPlace': 'Konaklama', + 'reservations.meta.pickHotel': 'Konaklama seçin', + 'reservations.meta.fromDay': 'İtibaren', + 'reservations.meta.toDay': 'İle', + 'reservations.meta.selectDay': 'Günü seçin', + 'reservations.type.flight': 'Uçuş', + 'reservations.type.hotel': 'Konaklama', + 'reservations.type.restaurant': 'Restoran', + 'reservations.type.train': 'Tren', + 'reservations.type.car': 'Araba', + 'reservations.type.cruise': 'Dolaşmak', + 'reservations.type.event': 'Etkinlik', + 'reservations.type.tour': 'Tur', + 'reservations.type.other': 'Diğer', + 'reservations.type.bus': 'Otobüs', + 'reservations.type.ferry': 'Feribot', + 'reservations.type.bicycle': 'Bisiklet', + 'reservations.type.taxi': 'Taksi', + 'reservations.type.transport_other': 'Diğer', + 'reservations.confirm.delete': + '"{name}" rezervasyonunu silmek istediğinizden emin misiniz?', + 'reservations.confirm.deleteTitle': 'Rezervasyon silinsin mi?', + 'reservations.confirm.deleteBody': '"{name}" kalıcı olarak silinecek.', + 'reservations.toast.updated': 'Rezervasyon güncellendi', + 'reservations.toast.removed': 'Rezervasyon silindi', + 'reservations.toast.fileUploaded': 'Dosya yüklendi', + 'reservations.toast.uploadError': 'Yükleme başarısız oldu', + 'reservations.newTitle': 'Yeni Rezervasyon', + 'reservations.bookingType': 'Rezervasyon Türü', + 'reservations.titleLabel': 'Başlık', + 'reservations.titlePlaceholder': 'örneğin Lufthansa LH123, Otel Adlon, ...', + 'reservations.locationAddress': 'Konum / Adres', + 'reservations.locationPlaceholder': 'Adres, Havaalanı, Otel...', + 'reservations.confirmationCode': 'Rezervasyon Kodu', + 'reservations.confirmationPlaceholder': 'örn. ABC12345', + 'reservations.day': 'Gün', + 'reservations.noDay': 'Gün Yok', + 'reservations.place': 'Yer', + 'reservations.noPlace': 'Yer Yok', + 'reservations.pendingSave': 'kaydedilecek…', + 'reservations.uploading': 'Yükleniyor...', + 'reservations.attachFile': 'Dosya ekle', + 'reservations.linkExisting': 'Mevcut dosyayı bağla', + 'reservations.toast.saveError': 'Kaydedilemedi', + 'reservations.toast.updateError': 'Güncelleme başarısız oldu', + 'reservations.toast.deleteError': 'Silinemedi', + 'reservations.confirm.remove': '"{name}" için rezervasyon kaldırılsın mı?', + 'reservations.linkAssignment': 'Gün atamasına bağla', + 'reservations.pickAssignment': 'Planınızdan bir atama seçin...', + 'reservations.noAssignment': 'Bağlantı yok (bağımsız)', + 'reservations.price': 'Fiyat', + 'reservations.budgetCategory': 'Bütçe kategorisi', + 'reservations.budgetCategoryPlaceholder': 'örn. Ulaşım, Konaklama', + 'reservations.budgetCategoryAuto': 'Otomatik (rezervasyon türünden)', + 'reservations.budgetHint': + 'Kaydederken otomatik olarak bir bütçe kaydı oluşturulur.', + 'reservations.departureDate': 'Kalkış', + 'reservations.arrivalDate': 'Varış', + 'reservations.departureTime': 'Kalkış saati', + 'reservations.arrivalTime': 'Varış saati', + 'reservations.pickupDate': 'Alış', + 'reservations.returnDate': 'İade', + 'reservations.pickupTime': 'Alış saati', + 'reservations.returnTime': 'İade saati', + 'reservations.endDate': 'Bitiş tarihi', + 'reservations.meta.departureTimezone': 'Kalkış SD', + 'reservations.meta.arrivalTimezone': 'Varış SD', + 'reservations.span.departure': 'Kalkış', + 'reservations.span.arrival': 'Varış', + 'reservations.span.inTransit': 'Yolda', + 'reservations.span.pickup': 'Alış', + 'reservations.span.return': 'İade', + 'reservations.span.active': 'Aktif', + 'reservations.span.start': 'Başlangıç', + 'reservations.span.end': 'Son', + 'reservations.span.ongoing': 'Devam ediyor', + 'reservations.validation.endBeforeStart': + 'Bitiş tarihi/saati başlangıçtan sonra olmalı', + 'reservations.addBooking': 'Rezervasyon ekle', + 'reservations.import.title': 'Rezervasyon onaylarını içe aktar', + 'reservations.import.cta': 'Dosyadan içe aktar', + 'reservations.import.dropHere': 'Rezervasyon onay dosyalarını buraya sürükleyin veya seçmek için tıklayın', + 'reservations.import.dropActive': 'İçe aktarmak için dosyaları bırakın', + 'reservations.import.acceptedFormats': 'Kabul edilenler: EML, PDF, PKPass, HTML, TXT (her biri maks. 10 MB, en fazla 5 dosya)', + 'reservations.import.parsing': 'Dosyalar işleniyor…', + 'reservations.import.previewHeading': '{count} rezervasyon bulundu', + 'reservations.import.previewEmpty': 'Yüklenen dosyalardan hiçbir rezervasyon çıkarılamadı.', + 'reservations.import.removeItem': 'Kaldır', + 'reservations.import.confirm': '{count} rezervasyonu içe aktar', + 'reservations.import.back': 'Geri', + 'reservations.import.success': '{count} rezervasyon içe aktarıldı', + 'reservations.import.partialFailure': '{created} içe aktarıldı, {failed} başarısız', + 'reservations.import.error': 'İşlem başarısız. Dosyanın geçerli bir rezervasyon onayı olduğundan emin olun.', + 'reservations.import.unavailable': 'Rezervasyon içe aktarma bu sunucuda mevcut değil.', + 'reservations.import.unsupportedFormat': 'Desteklenmeyen dosya biçimi. EML, PDF, PKPass, HTML veya TXT kullanın.', + 'reservations.import.fileTooLarge': '"{name}" dosyası 10 MB sınırını aşıyor.', + 'reservations.airtrail.title': 'AirTrail\'den içe aktar', + 'reservations.airtrail.cta': 'AirTrail', + 'reservations.airtrail.synced': 'AirTrail', + 'reservations.airtrail.syncedHint': 'AirTrail ile senkronize edildi — düzenlemeler iki yönlü olarak senkronize kalır.', + 'reservations.airtrail.notSynced': 'Senkronize değil', + 'reservations.airtrail.notSyncedHint': 'Bu uçuş AirTrail\'de kaldırıldı ve artık senkronize edilmiyor.', + 'reservations.airtrail.loadError': 'AirTrail uçuşlarınız yüklenemedi.', + 'reservations.airtrail.imported': '{count} uçuş içe aktarıldı', + 'reservations.airtrail.skippedDuplicate': '{count} zaten bu gezide, atlandı', + 'reservations.airtrail.nothingImported': 'İçe aktarılacak bir şey yok.', + 'reservations.airtrail.importError': 'İçe aktarma başarısız. Lütfen tekrar deneyin.', + 'reservations.airtrail.undo': 'AirTrail\'den içe aktar', + 'reservations.airtrail.alreadyImported': 'İçe aktarıldı', + 'reservations.airtrail.duringTrip': 'Bu gezi sırasında', + 'reservations.airtrail.otherFlights': 'Diğer uçuşlar', + 'reservations.airtrail.empty': 'AirTrail hesabınızda uçuş bulunamadı.', + 'reservations.airtrail.importCta': '{count} içe aktar', +}; +export default reservations; diff --git a/shared/src/i18n/tr/settings.ts b/shared/src/i18n/tr/settings.ts new file mode 100644 index 0000000000000000000000000000000000000000..99c612643707a13a05c76638f418694f5862be7b --- /dev/null +++ b/shared/src/i18n/tr/settings.ts @@ -0,0 +1,346 @@ +import type { TranslationStrings } from '../types'; + +const settings: TranslationStrings = { + 'settings.title': 'Ayarlar', + 'settings.subtitle': 'Kişisel ayarlarınızı yapılandırın', + 'settings.tabs.display': 'Görünüm', + 'settings.tabs.map': 'Harita', + 'settings.tabs.notifications': 'Bildirimler', + 'settings.tabs.integrations': 'Entegrasyonlar', + 'settings.tabs.account': 'Hesap', + 'settings.tabs.offline': 'Çevrimdışı', + 'settings.tabs.about': 'Hakkında', + 'settings.map': 'Harita', + 'settings.mapTemplate': 'Harita Şablonu', + 'settings.mapTemplatePlaceholder.select': 'Şablon seçin...', + 'settings.mapDefaultHint': 'OpenStreetMap için boş bırakın (varsayılan)', + 'settings.mapTemplatePlaceholder': + 'https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', + 'settings.mapHint': 'Harita kutucukları için URL şablonu', + 'settings.mapProvider': 'Harita Sağlayıcısı', + 'settings.mapProviderHint': + 'Seyahat planlayıcı ve Journey haritalarını etkiler. Atlas her zaman Leaflet kullanır.', + 'settings.mapLeafletSubtitle': 'Klasik 2D, herhangi bir raster kutucuk', + 'settings.mapMapboxSubtitle': 'Vektör kutucuklar, 3D binalar ve arazi', + 'settings.mapExperimental': 'Deneysel', + 'settings.mapMapboxToken': 'Mapbox Erişim Anahtarı', + 'settings.mapMapboxTokenHint': 'Genel anahtar (pk.*) kaynağı:', + 'settings.mapMapboxTokenLink': 'Mapbox.com → Jetonlara erişim', + 'settings.mapStyle': 'Harita Stili', + 'settings.mapStylePlaceholder': 'Bir Mapbox stili seçin', + 'settings.mapStyleHint': + 'Ön ayar veya kendi mapbox://styles/KULLANICI/ID adresiniz', + 'settings.map3dBuildings': '3D Binalar ve Arazi', + 'settings.map3dHint': + 'Eğim + gerçek 3D bina çıkıntıları — uydu dahil her stilde çalışır.', + 'settings.mapHighQuality': 'Yüksek Kalite Modu', + 'settings.mapHighQualityHint': + 'Keskin kenarlar ve gerçekçi dünya görünümü için antialiasing + küre projeksiyonu.', + 'settings.mapHighQualityWarning': + 'Düşük donanımlı cihazlarda performansı etkileyebilir.', + 'settings.mapTipLabel': 'İpucu:', + 'settings.mapTip': + 'Haritayı döndürmek/eğmek için sağ tıklayıp sürükleyin. Yer eklemek için orta tıklama (sağ tık döndürmeye ayrılmıştır).', + 'settings.latitude': 'Enlem', + 'settings.longitude': 'Boylam', + 'settings.saveMap': 'Haritayı Kaydet', + 'settings.apiKeys': 'API Anahtarları', + 'settings.mapsKey': 'Google Maps API Anahtarı', + 'settings.mapsKeyHint': + 'Yer araması için. Places API (New) gerekir. console.cloud.google.com', + 'settings.weatherKey': 'OpenWeatherMap API Anahtarı', + 'settings.weatherKeyHint': + 'Hava verisi için. Ücretsiz: openweathermap.org/api', + 'settings.keyPlaceholder': 'Anahtarı girin...', + 'settings.configured': 'Yapılandırıldı', + 'settings.saveKeys': 'Anahtarları Kaydet', + 'settings.display': 'Görünüm', + 'settings.colorMode': 'Renk Modu', + 'settings.light': 'Açık', + 'settings.dark': 'Koyu', + 'settings.auto': 'Otomatik', + 'settings.language': 'Dil', + 'settings.temperature': 'Sıcaklık Birimi', + 'settings.timeFormat': 'Saat Biçimi', + 'settings.bookingLabels': 'Rezervasyon rota etiketleri', + 'settings.bookingLabelsHint': + 'Haritada istasyon / havalimanı adlarını göster. Kapalıyken yalnızca simge görünür.', + 'settings.blurBookingCodes': 'Rezervasyon Kodlarını Bulanıklaştır', + 'settings.optimizeFromAccommodation': 'Rotayı konaklamadan optimize et', + 'settings.optimizeFromAccommodationHint': + 'Bir günü optimize ederken rotaya o sabah uyandığınız otelden başlayın ve akşam giriş yaptığınız otelde sonlandırın.', + 'settings.notifications': 'Bildirimler', + 'settings.notifyTripInvite': 'Seyahat davetleri', + 'settings.notifyBookingChange': 'Rezervasyon değişiklikleri', + 'settings.notifyTripReminder': 'Seyahat hatırlatıcıları', + 'settings.notifyTodoDue': 'Yapılacak vadesi yakında', + 'settings.notifyVacayInvite': 'Vacay birleştirme davetleri', + 'settings.notifyPhotosShared': 'Paylaşılan fotoğraflar (Immich)', + 'settings.notifyCollabMessage': 'Sohbet mesajları (Collab)', + 'settings.notifyPackingTagged': 'Paket listesi: atamalar', + 'settings.notifyWebhook': 'Webhook bildirimleri', + 'settings.notifyVersionAvailable': 'Yeni sürüm mevcut', + 'settings.notificationPreferences.email': 'E-posta', + 'settings.notificationPreferences.webhook': 'Web kancası', + 'settings.notificationPreferences.inapp': 'Uygulama içi', + 'settings.notificationPreferences.ntfy': 'Ntfy', + 'settings.notificationPreferences.noChannels': + 'Bildirim kanalı yapılandırılmadı. Yöneticiden e-posta veya webhook kurmasını isteyin.', + 'settings.webhookUrl.label': "Web kancası URL'si", + 'settings.webhookUrl.placeholder': 'https://discord.com/api/webhooks/...', + 'settings.webhookUrl.hint': + "Bildirim almak için Discord, Slack veya özel webhook URL'nizi girin.", + 'settings.webhookUrl.saved': 'Webhook URL kaydedildi', + 'settings.webhookUrl.test': 'Dene', + 'settings.webhookUrl.testSuccess': 'Test webhook başarıyla gönderildi', + 'settings.webhookUrl.testFailed': 'Test webhook başarısız', + 'settings.ntfyUrl.topicLabel': 'Ntfy Konusu', + 'settings.ntfyUrl.topicPlaceholder': 'benim-trek-uyarilari', + 'settings.ntfyUrl.serverLabel': "Ntfy sunucu URL'si (isteğe bağlı)", + 'settings.ntfyUrl.serverPlaceholder': 'https://ntfy.sh', + 'settings.ntfyUrl.hint': + 'Anlık bildirim için ntfy konusunu girin. Sunucuyu boş bırakırsanız yöneticinin varsayılanı kullanılır.', + 'settings.ntfyUrl.tokenLabel': 'Erişim anahtarı (isteğe bağlı)', + 'settings.ntfyUrl.tokenHint': 'Parola korumalı konular için gerekli.', + 'settings.ntfyUrl.saved': 'Ntfy ayarları kaydedildi', + 'settings.ntfyUrl.test': 'Dene', + 'settings.ntfyUrl.testSuccess': 'Test ntfy bildirimi gönderildi', + 'settings.ntfyUrl.testFailed': 'Test ntfy bildirimi başarısız', + 'settings.ntfyUrl.tokenCleared': 'Erişim anahtarı temizlendi', + 'settings.notificationsDisabled': + 'Bildirimler yapılandırılmadı. Yöneticiden e-posta veya webhook açmasını isteyin.', + 'settings.notificationsActive': 'Etkin kanal', + 'settings.notificationsManagedByAdmin': + 'Bildirim olayları yöneticiniz tarafından yapılandırılır.', + 'settings.on': 'Açık', + 'settings.off': 'Kapalı', + 'settings.mcp.title': 'MCP Yapılandırması', + 'settings.mcp.endpoint': 'MCP Uç Noktası', + 'settings.mcp.clientConfig': 'İstemci Yapılandırması', + 'settings.mcp.clientConfigHint': + " öğesini aşağıdaki listeden bir API belirteciyle değiştirin. Npx yolunun sisteminize göre ayarlanması gerekebilir (örn. Windows'ta C:\\\\\\\\PROGRA~1\\\\\\\\nodejs\\\\\\\\npx.cmd).", + 'settings.mcp.clientConfigHintOAuth': + " ve değerlerini yukarıda oluşturduğunuz OAuth 2.1 istemcisinde gösterilen kimlik bilgileriyle değiştirin. mcp-remote, ilk bağlandığınızda yetkilendirmeyi tamamlamak için tarayıcınızı açacaktır. Npx yolunun sisteminize göre ayarlanması gerekebilir (örn. Windows'ta C:\\PROGRA~1\\nodejs\\npx.cmd).", + 'settings.mcp.copy': 'Kopyala', + 'settings.mcp.copied': 'Kopyalandı!', + 'settings.mcp.apiTokens': 'API Belirteçleri', + 'settings.mcp.createToken': 'Yeni Jeton Oluştur', + 'settings.mcp.noTokens': + 'Henüz jeton yok. MCP istemcilerini bağlamak için bir tane oluşturun.', + 'settings.mcp.tokenCreatedAt': 'Oluşturuldu', + 'settings.mcp.tokenUsedAt': 'Kullanılmış', + 'settings.mcp.deleteTokenTitle': 'Jetonu Sil', + 'settings.mcp.deleteTokenMessage': + 'Bu jeton hemen çalışmayı durduracak. Bunu kullanan herhangi bir MCP istemcisi erişimi kaybedecektir.', + 'settings.mcp.modal.createTitle': 'API Jetonu Oluştur', + 'settings.mcp.modal.tokenName': 'Jeton Adı', + 'settings.mcp.modal.tokenNamePlaceholder': + 'örneğin Claude Masaüstü, İş dizüstü bilgisayarı', + 'settings.mcp.modal.creating': 'Oluşturuluyor…', + 'settings.mcp.modal.create': 'Jeton Oluştur', + 'settings.mcp.modal.createdTitle': 'Jeton Oluşturuldu', + 'settings.mcp.modal.createdWarning': + 'Bu jeton yalnızca bir kez gösterilecektir. Şimdi kopyalayıp saklayın; kurtarılamaz.', + 'settings.mcp.modal.done': 'Tamamlamak', + 'settings.mcp.toast.created': 'Jeton oluşturuldu', + 'settings.mcp.toast.createError': 'Jeton oluşturulamadı', + 'settings.mcp.toast.deleted': 'Jeton silindi', + 'settings.mcp.toast.deleteError': 'Jeton silinemedi', + 'settings.mcp.apiTokensDeprecated': + 'API Belirteçleri kullanımdan kaldırıldı ve gelecekteki bir sürümde kaldırılacak. Lütfen bunun yerine OAuth 2.1 İstemcilerini kullanın.', + 'settings.oauth.clients': 'OAuth 2.1 İstemcileri', + 'settings.oauth.clientsHint': + 'Üçüncü taraf MCP uygulamalarının (Claude Web, Cursor vb.) statik belirteçler olmadan bağlanmasına izin vermek için OAuth 2.1 istemcilerini kaydedin.', + 'settings.oauth.createClient': 'Yeni Müşteri', + 'settings.oauth.noClients': 'Kayıtlı OAuth istemcisi yok.', + 'settings.oauth.clientId': 'Müşteri Kimliği', + 'settings.oauth.clientSecret': 'Müşteri Sırrı', + 'settings.oauth.deleteClient': 'İstemciyi Sil', + 'settings.oauth.deleteClientMessage': + 'Bu istemci ve tüm aktif oturumlar kalıcı olarak kaldırılacak. Bunu kullanan herhangi bir uygulama erişimi anında kaybedecektir.', + 'settings.oauth.rotateSecret': 'Gizli Anahtarı Döndür', + 'settings.oauth.rotateSecretMessage': + 'Yeni bir istemci sırrı oluşturulacak ve mevcut tüm oturumlar derhal geçersiz kılınacaktır. Bu iletişim kutusunu kapatmadan önce uygulamanızı güncelleyin.', + 'settings.oauth.rotateSecretConfirm': 'Döndür', + 'settings.oauth.rotateSecretConfirming': 'Dönüyor…', + 'settings.oauth.rotateSecretDoneTitle': 'Yeni Gizli Oluşturuldu', + 'settings.oauth.rotateSecretDoneWarning': + 'Bu sır yalnızca bir kez gösterilir. Şimdi kopyalayın ve uygulamanızı güncelleyin; önceki tüm oturumlar geçersiz kılınmıştır.', + 'settings.oauth.activeSessions': 'Aktif OAuth Oturumları', + 'settings.oauth.sessionScopes': 'Kapsamlar', + 'settings.oauth.sessionExpires': 'Süresi doluyor', + 'settings.oauth.revoke': 'Geri çekmek', + 'settings.oauth.revokeSession': 'Oturumu İptal Et', + 'settings.oauth.revokeSessionMessage': + 'Bu, bu OAuth oturumuna erişimi anında iptal edecektir.', + 'settings.oauth.modal.createTitle': 'OAuth İstemcisini Kaydedin', + 'settings.oauth.modal.presets': 'Hızlı ön ayarlar', + 'settings.oauth.modal.clientName': 'Uygulama Adı', + 'settings.oauth.modal.clientNamePlaceholder': + 'örneğin Claude Web, MCP Uygulamam', + 'settings.oauth.modal.redirectUris': "URI'leri Yönlendir", + 'settings.oauth.modal.redirectUrisPlaceholder': + 'https://uygulamaniz.com/callback\\nhttps://uygulamaniz.com/auth', + 'settings.oauth.modal.redirectUrisHint': + 'Satır başına bir URI. HTTPS gerekli (yerel ana bilgisayar hariç). Tam eşleşme uygulandı.', + 'settings.oauth.modal.scopes': 'İzin Verilen Kapsamlar', + 'settings.oauth.modal.scopesHint': + 'list_trips ve get_trip_summary her zaman kullanılabilir; kapsam gerektirmez. Yapay zekanın başka herhangi bir aracı kullanmak için gereken yolculuk kimliklerini keşfetmesine olanak tanıyorlar.', + 'settings.oauth.modal.selectAll': 'Tümünü seç', + 'settings.oauth.modal.deselectAll': 'Tümünün seçimini kaldır', + 'settings.oauth.modal.creating': 'Kaydediliyor…', + 'settings.oauth.modal.create': 'Müşteriyi Kaydet', + 'settings.oauth.modal.createdTitle': 'Müşteri Kayıtlı', + 'settings.oauth.modal.createdWarning': + 'İstemci sırrı yalnızca bir kez gösterilir. Şimdi kopyalayın; kurtarılamaz.', + 'settings.oauth.toast.createError': 'OAuth istemcisi kaydedilemedi', + 'settings.oauth.toast.deleted': 'OAuth istemcisi silindi', + 'settings.oauth.toast.deleteError': 'OAuth istemcisi silinemedi', + 'settings.oauth.toast.revoked': 'Oturum iptal edildi', + 'settings.oauth.toast.revokeError': 'Oturum iptal edilemedi', + 'settings.oauth.toast.rotateError': 'İstemci sırrı döndürülemedi', + 'settings.account': 'Hesap', + 'settings.about': 'Hakkında', + 'settings.about.reportBug': 'Hata Bildir', + 'settings.about.reportBugHint': 'Bir sorun mu buldunuz? Bize bildirin', + 'settings.about.featureRequest': 'Özellik İsteği', + 'settings.about.featureRequestHint': 'Yeni bir özellik önerin', + 'settings.about.wikiHint': 'Belgeler ve kılavuzlar', + 'settings.about.supporters.badge': 'Aylık Destekçiler', + 'settings.about.supporters.title': 'TREK için seyahat Arkadaşları', + 'settings.about.supporters.subtitle': + "While you're planning your next route, these folks are helping plan TREK's future. Their monthly contribution goes straight into development and real hours spent — so TREK stays Open Source.", + 'settings.about.supporters.since': '{date} tarihinden beri destekçimiz', + 'settings.about.supporters.tierEmpty': 'İlk olun', + 'settings.about.supporter.tier.noReturnTicket': 'Dönüş Bileti Yok', + 'settings.about.supporter.tier.lostLuggageVip': 'Kayıp Bagaj VIP', + 'settings.about.supporter.tier.businessClassDreamer': + 'Business Class Hayalperest', + 'settings.about.supporter.tier.budgetTraveller': 'Bütçe Gezgini', + 'settings.about.supporter.tier.hostelBunkmate': 'Hostel Yatakhane Arkadaşı', + 'settings.about.description': + 'TREK, seyahatlerinizi ilk fikirden son anıya kadar organize etmenize yardımcı olan, kendi kendine barındırılan bir seyahat planlayıcıdır. Gün planlaması, bütçe, paketleme listeleri, fotoğraflar ve çok daha fazlası; hepsi tek bir yerde, kendi sunucunuzda.', + 'settings.about.madeWith': 'İle yapıldı', + 'settings.about.madeBy': + 'Maurice ve büyüyen bir açık kaynak topluluğu tarafından.', + 'settings.username': 'Kullanıcı adı', + 'settings.email': 'E-posta', + 'settings.role': 'Rol', + 'settings.roleAdmin': 'Yönetici', + 'settings.oidcLinked': 'ile bağlantılı', + 'settings.changePassword': 'Şifre Değiştir', + 'settings.currentPassword': 'Mevcut Şifre', + 'settings.currentPasswordRequired': 'Mevcut şifre gerekli', + 'settings.newPassword': 'Yeni Şifre', + 'settings.confirmPassword': 'Yeni şifreyi onayla', + 'settings.updatePassword': 'Şifreyi güncelle', + 'settings.passwordRequired': 'Lütfen mevcut ve yeni şifrenizi giriniz', + 'settings.passwordTooShort': 'Şifre en az 8 karakter olmalıdır', + 'settings.passwordMismatch': 'Şifreler eşleşmiyor', + 'settings.passwordWeak': + 'Şifre büyük harf, küçük harf, sayı ve özel karakter içermelidir', + 'settings.passwordChanged': 'Şifre başarıyla değiştirildi', + 'settings.mustChangePassword': + 'Devam etmeden önce şifrenizi değiştirmelisiniz. Lütfen aşağıdan yeni bir şifre belirleyin.', + 'settings.deleteAccount': 'Hesabı sil', + 'settings.deleteAccountTitle': 'Hesabınız silinsin mi?', + 'settings.deleteAccountWarning': + 'Hesabınız ve tüm gezileriniz, yerleriniz ve dosyalarınız kalıcı olarak silinecek. Bu eylem geri alınamaz.', + 'settings.deleteAccountConfirm': 'Kalıcı olarak sil', + 'settings.deleteBlockedTitle': 'Silme mümkün değil', + 'settings.deleteBlockedMessage': + 'Tek yönetici sizsiniz. Hesabınızı silmeden önce başka bir kullanıcıyı yönetici olarak atayın.', + 'settings.roleUser': 'Kullanıcı', + 'settings.saveProfile': 'Profili Kaydet', + 'settings.toast.mapSaved': 'Harita ayarları kaydedildi', + 'settings.toast.keysSaved': 'API anahtarları kaydedildi', + 'settings.toast.displaySaved': 'Ekran ayarları kaydedildi', + 'settings.toast.profileSaved': 'Profil kaydedildi', + 'settings.uploadAvatar': 'Profil Resmini Yükle', + 'settings.removeAvatar': 'Profil Resmini Kaldır', + 'settings.avatarUploaded': 'Profil resmi güncellendi', + 'settings.avatarRemoved': 'Profil resmi kaldırıldı', + 'settings.avatarError': 'Yükleme başarısız oldu', + 'settings.mfa.title': 'İki faktörlü kimlik doğrulama (2FA)', + 'settings.mfa.description': + 'E-posta ve şifreyle oturum açtığınızda ikinci bir adım ekler. Bir kimlik doğrulama uygulaması kullanın (Google Authenticator, Authy vb.).', + 'settings.mfa.requiredByPolicy': + 'Yöneticiniz iki faktörlü kimlik doğrulama gerektiriyor. Devam etmeden önce aşağıdan bir kimlik doğrulama uygulaması kurun.', + 'settings.mfa.backupTitle': 'Yedekleme kodları', + 'settings.mfa.backupDescription': + 'Kimlik doğrulayıcı uygulamanıza erişimi kaybederseniz bu tek seferlik yedek kodları kullanın.', + 'settings.mfa.backupWarning': + 'Şimdi bu kodları kaydedin. Her kod yalnızca bir kez kullanılabilir.', + 'settings.mfa.backupCopy': 'Kodları kopyala', + 'settings.mfa.backupDownload': "TXT'yi İndirin", + 'settings.mfa.backupPrint': 'Yazdır / PDF', + 'settings.mfa.backupCopied': 'Yedek kodlar kopyalandı', + 'settings.mfa.enabled': 'Hesabınızda 2FA etkin.', + 'settings.mfa.disabled': '2FA etkin değil.', + 'settings.mfa.setup': 'Kimlik doğrulayıcıyı ayarla', + 'settings.mfa.scanQr': + 'Bu QR kodunu uygulamanızla tarayın veya sırrı manuel olarak girin.', + 'settings.mfa.secretLabel': 'Gizli anahtar (manuel giriş)', + 'settings.mfa.codePlaceholder': '6 haneli kod', + 'settings.mfa.enable': "2FA'yı Etkinleştir", + 'settings.mfa.cancelSetup': 'İptal etmek', + 'settings.mfa.disableTitle': "2FA'yı devre dışı bırak", + 'settings.mfa.disableHint': + 'Hesap şifrenizi ve kimlik doğrulayıcınızdan aldığınız geçerli kodu girin.', + 'settings.mfa.disable': "2FA'yı devre dışı bırak", + 'settings.mfa.toastEnabled': 'İki faktörlü kimlik doğrulama etkin', + 'settings.mfa.toastDisabled': 'İki faktörlü kimlik doğrulama devre dışı', + 'settings.mfa.demoBlocked': 'Demo modunda kullanılamaz', + 'settings.oauth.modal.machineClient': + 'Makine istemcisi (tarayıcıda oturum açma yok)', + 'settings.oauth.modal.machineClientHint': + "client_credentials iznini kullanın — yönlendirme URI'lerine gerek yoktur. Belirteç doğrudan client_id + client_secret ile verilir ve seçilen kapsamlar dahilinde sizin adınıza hareket eder.", + 'settings.oauth.modal.machineClientUsage': + 'Bir jeton alın: grant_type=client_credentials, client_id ve client_secret ile POST /oauth/token. Tarayıcı yok, yenileme belirteci yok.', + 'settings.oauth.badge.machine': 'makine', + "settings.currency": "Currency", + "settings.currencyHint": "All amounts in Costs are converted to and shown in this currency.", + 'settings.passkey.title': 'Passkey’ler', + 'settings.passkey.description': + 'Passkey ile daha hızlı ve kimlik avına dayanıklı şekilde oturum açın — parmak iziniz, yüzünüz, PIN’iniz veya bir donanım anahtarı. Şifreniz yedek olarak kalır.', + 'settings.passkey.notConfigured': + 'Passkey’ler etkin ancak bu sunucuda henüz tam olarak yapılandırılmadı. WebAuthn alan adını ayarlaması için yöneticinize başvurun.', + 'settings.passkey.add': 'Passkey ekle', + 'settings.passkey.addTitle': 'Passkey ekle', + 'settings.passkey.passwordPrompt': + 'Mevcut şifrenizi onaylayın, ardından cihazınızın istemini izleyin.', + 'settings.passkey.passwordRequired': 'Mevcut şifreniz gerekli.', + 'settings.passkey.namePlaceholder': 'Ad (isteğe bağlı, ör. "iPhone")', + 'settings.passkey.addedToast': 'Passkey eklendi', + 'settings.passkey.added': 'Eklendi', + 'settings.passkey.addError': 'Passkey eklenemedi', + 'settings.passkey.cancelled': 'Passkey kurulumu iptal edildi', + 'settings.passkey.deleted': 'Passkey kaldırıldı', + 'settings.passkey.deleteConfirm': + 'Bu passkey kaldırılsın mı? Şifrenizle onaylayın.', + 'settings.passkey.rename': 'Yeniden adlandır', + 'settings.passkey.defaultName': 'Passkey', + 'settings.passkey.synced': 'Senkronize edildi', + 'settings.passkey.deviceBound': 'Bu cihaz', + 'settings.passkey.lastUsed': 'Son kullanım', + 'settings.passkey.neverUsed': 'Hiç kullanılmadı', + 'settings.mapPoiPill': 'Haritada yerleri keşfet', + 'settings.mapPoiPillHint': 'Yakındaki restoranları, otelleri ve daha fazlasını OpenStreetMap\'ten bulmak için gezi haritasında bir kategori etiketi göster.', + 'settings.airtrail.title': 'AirTrail', + 'settings.airtrail.hint': 'Uçuşları içe aktarmak ve senkronize etmek için kendi barındırdığınız AirTrail\'i bağlayın. AirTrail\'de Ayarlar → Güvenlik altından bir API anahtarı oluşturun.', + 'settings.airtrail.url': 'Örnek URL\'si', + 'settings.airtrail.apiKey': 'API anahtarı', + 'settings.airtrail.apiKeyPlaceholder': 'Bearer API anahtarı', + 'settings.airtrail.apiKeyHint': 'AirTrail\'de Ayarlar → Güvenlik altında oluşturulur. Şifreli olarak saklanır.', + 'settings.airtrail.allowInsecureTls': 'Kendinden imzalı sertifikalara izin ver', + 'settings.airtrail.allowInsecureTlsHint': 'Yalnızca kendi ağınızdaki güvenilir bir örnek için etkinleştirin.', + 'settings.airtrail.connected': 'Bağlandı', + 'settings.airtrail.notConnected': 'Bağlı değil', + 'settings.airtrail.toast.saved': 'AirTrail bağlantısı kaydedildi', + 'settings.airtrail.toast.saveError': 'Bağlantı kaydedilemedi', + 'settings.airtrail.test.button': 'Bağlantıyı test et', + 'settings.airtrail.test.success': 'Bağlandı — {count} uçuş bulundu', + 'settings.airtrail.test.failed': 'Bağlantı başarısız', +}; + +export default settings; diff --git a/shared/src/i18n/tr/share.ts b/shared/src/i18n/tr/share.ts new file mode 100644 index 0000000000000000000000000000000000000000..0d5ec40ce8d808ee8fe6725ee15af67825d94c28 --- /dev/null +++ b/shared/src/i18n/tr/share.ts @@ -0,0 +1,16 @@ +import type { TranslationStrings } from '../types'; + +const share: TranslationStrings = { + 'share.linkTitle': 'Genel Bağlantı', + 'share.linkHint': + 'Herkesin giriş yapmadan bu geziyi görüntülemek için kullanabileceği bir bağlantı oluşturun. Salt okunur — düzenleme mümkün değildir.', + 'share.createLink': 'Bağlantı oluştur', + 'share.deleteLink': 'Bağlantıyı sil', + 'share.createError': 'Bağlantı oluşturulamadı', + 'share.permMap': 'Harita ve Plan', + 'share.permBookings': 'Rezervasyonlar', + 'share.permPacking': 'Ambalaj', + 'share.permBudget': 'Bütçe', + 'share.permCollab': 'Sohbet', +}; +export default share; diff --git a/shared/src/i18n/tr/shared.ts b/shared/src/i18n/tr/shared.ts new file mode 100644 index 0000000000000000000000000000000000000000..f25a59053bc9a27a8cc572647054ea9cc3dca932 --- /dev/null +++ b/shared/src/i18n/tr/shared.ts @@ -0,0 +1,21 @@ +import type { TranslationStrings } from '../types'; + +const shared: TranslationStrings = { + 'shared.expired': 'Bağlantının süresi dolmuş veya geçersiz', + 'shared.expiredHint': 'Bu paylaşılan gezi bağlantısı artık etkin değil.', + 'shared.readOnly': 'Salt okunur paylaşılan görünüm', + 'shared.tabPlan': 'Planı', + 'shared.tabBookings': 'Rezervasyonlar', + 'shared.tabPacking': 'Ambalaj', + 'shared.tabBudget': 'Bütçe', + 'shared.tabChat': 'Sohbet', + 'shared.days': 'günler', + 'shared.places': 'yer', + 'shared.other': 'Diğer', + 'shared.totalBudget': 'Toplam Bütçe', + 'shared.messages': 'mesajlar', + 'shared.sharedVia': 'Şununla paylaşıldı:', + 'shared.confirmed': 'Onaylandı', + 'shared.pending': 'Askıda olması', +}; +export default shared; diff --git a/shared/src/i18n/tr/stats.ts b/shared/src/i18n/tr/stats.ts new file mode 100644 index 0000000000000000000000000000000000000000..f5b5501dcededadb3645e6966adcbaec8055821c --- /dev/null +++ b/shared/src/i18n/tr/stats.ts @@ -0,0 +1,13 @@ +import type { TranslationStrings } from '../types'; + +const stats: TranslationStrings = { + 'stats.countries': 'Ülkeler', + 'stats.cities': 'Şehirler', + 'stats.trips': 'Seyahatler', + 'stats.places': 'Yerler', + 'stats.worldProgress': 'Dünya İlerlemesi', + 'stats.visited': 'ziyaret edildi', + 'stats.remaining': 'kalan', + 'stats.visitedCountries': 'Ziyaret Edilen Ülkeler', +}; +export default stats; diff --git a/shared/src/i18n/tr/system_notice.ts b/shared/src/i18n/tr/system_notice.ts new file mode 100644 index 0000000000000000000000000000000000000000..a765c2404e11af95ed86dc4c6e99be9dbecd00de --- /dev/null +++ b/shared/src/i18n/tr/system_notice.ts @@ -0,0 +1,65 @@ +import type { TranslationStrings } from '../types'; + +const system_notice: TranslationStrings = { + 'system_notice.v3_photos.title': "Fotoğraflar 3.0'da taşındı", + 'system_notice.v3_photos.body': + "Seyahat Planlayıcı'daki **Fotoğraflar** kaldırıldı. Fotoğraflarınız güvende — TREK Immich veya Synology kütüphanenizi asla değiştirmedi.\\n\\nFotoğraflar artık **Journey** eklentisinde. Journey isteğe bağlıdır — henüz kullanılamıyorsa yöneticinizden Yönetici → Eklentiler bölümünden etkinleştirmesini isteyin.", + 'system_notice.v3_journey.title': 'Journey ile tanışın — seyahat günlüğü', + 'system_notice.v3_journey.body': + 'Seyahatlerinizi zaman çizelgeleri, fotoğraf galerileri ve etkileşimli haritalarla zengin hikâyelere dönüştürün.', + 'system_notice.v3_journey.cta_label': "Journey'i Aç", + 'system_notice.v3_journey.highlight_timeline': + 'Gün gün zaman çizelgesi ve galeri', + 'system_notice.v3_journey.highlight_photos': + "Immich veya Synology'den içe Aktar", + 'system_notice.v3_journey.highlight_share': + 'Herkese açık paylaş — giriş gerekmez', + 'system_notice.v3_journey.highlight_export': + 'PDF fotoğraf kitabı Olarak dışa aktar', + 'system_notice.v3_features.title': "3.0'Daki diğer öne çıkanlar", + 'system_notice.v3_features.body': + 'Bu sürüm hakkında bilmeniz gereken birkaç şey daha.', + 'system_notice.v3_features.highlight_dashboard': + 'Mobil öncelikli gösterge paneli yenilemesi', + 'system_notice.v3_features.highlight_offline': + 'PWA olarak tam çevrimdışı mod', + 'system_notice.v3_features.highlight_search': + 'Gerçek zamanlı yer arama otomatik tamamlama', + 'system_notice.v3_features.highlight_import': + 'KMZ/KML dosyalarından yer İçe aktarma', + 'system_notice.v3_mcp.title': 'MCP: OAuth 2.1 yükseltmesi', + 'system_notice.v3_mcp.body': + 'MCP entegrasyonu tamamen yenilendi. OAuth 2.1 artık önerilen kimlik doğrulama yöntemidir. Eski statik jetonlar (trek_…) kullanımdan kaldırıldı ve gelecekteki bir sürümde kaldırılacak.', + 'system_notice.v3_mcp.highlight_oauth': 'OAuth 2.1 önerilir (mcp-remote)', + 'system_notice.v3_mcp.highlight_scopes': '24 ayrıntılı izin kapsamı', + 'system_notice.v3_mcp.highlight_deprecated': + 'Statik trek_ jetonları kullanımdan kaldırıldı', + 'system_notice.v3_mcp.highlight_tools': 'Genişletilmiş araç seti ve istemler', + 'system_notice.v3_thankyou.title': 'Benden kişisel bir not', + 'system_notice.v3_thankyou.body': + "Before you go — I want to take a moment.\n\nTREK started as a side project I built for my own trips. I never imagined it would grow into something that 4,000 of you now trust to plan your adventures. Every star, every issue, every feature request — I read them all, and they keep me going through late nights between a full-time job and university.\n\nI want you to know: TREK will always be open source, always self-hosted, always yours. No tracking, no subscriptions, no strings attached. Just a tool built by someone who loves traveling as much as you do.\n\nSpecial thanks to [jubnl](https://github.com/jubnl) — you have become an incredible collaborator. So much of what makes 3.0 great carries your fingerprints. Thank you for believing in this project when it was still rough around the edges.\n\nAnd to every single one of you who filed a bug, translated a string, shared TREK with a friend, or simply used it to plan a trip — **thank you**. You are the reason this exists.\n\nHere's to many more adventures together.\n\n— Maurice\n\n---\n\n[Join the community on Discord](https://discord.gg/7Q6M6jDwzf)\n\nIf TREK makes your travels better, a [small coffee](https://ko-fi.com/mauriceboe) always keeps the lights on.", + 'system_notice.v3014_whitespace_collision.title': + 'İşlem gerekli: kullanıcı hesabı çakışması', + 'system_notice.v3014_whitespace_collision.body': + '3.0.14 yükseltmesi, kayıtlı hesaplardaki baştaki/sondaki boşluklardan kaynaklanan bir veya daha fazla kullanıcı adı veya e-posta çakışması tespit etti. Etkilenen hesaplar otomatik olarak yeniden adlandırıldı. Hangi hesapların incelenmesi gerektiğini belirlemek için sunucu günlüklerinde **[migration] WHITESPACE COLLISION** ile başlayan satırlara bakın.', + 'system_notice.welcome_v1.title': "TREK'e hoş Geldiniz", + 'system_notice.welcome_v1.body': + 'Hepsi bir arada seyahat planlayıcınız. Program oluşturun, seyahatleri arkadaşlarınızla paylaşın ve çevrimiçi veya çevrimdışı düzenli kalın.', + 'system_notice.welcome_v1.cta_label': 'Seyahat planla', + 'system_notice.welcome_v1.hero_alt': + 'TREK planlama arayüzü kaplamalı manzaralı bir seyahat destinasyonu', + 'system_notice.welcome_v1.highlight_plan': + 'Her seyahat için gün gün programlar', + 'system_notice.welcome_v1.highlight_share': + 'Seyahat partnerleriyle işbirliği', + 'system_notice.welcome_v1.highlight_offline': 'Mobilde çevrimdışı çalışır', + 'system_notice.dev_test_modal.title': '[Dev] Test bildirimi', + 'system_notice.dev_test_modal.body': + 'Bu yalnızca geliştirme ortamına özel bir test bildirimidir.', + 'system_notice.pager.prev': 'Önceki bildirim', + 'system_notice.pager.next': 'Sonraki bildirim', + 'system_notice.pager.counter': '{güncel} / {toplam}', + 'system_notice.pager.goto': '{n}. bildirime git', + 'system_notice.pager.position': '{total} Bildirimden {current}.', +}; +export default system_notice; diff --git a/shared/src/i18n/tr/todo.ts b/shared/src/i18n/tr/todo.ts new file mode 100644 index 0000000000000000000000000000000000000000..930b1291f8b3693321d90d42a221a7cc9bd6c42a --- /dev/null +++ b/shared/src/i18n/tr/todo.ts @@ -0,0 +1,40 @@ +import type { TranslationStrings } from '../types'; + +const todo: TranslationStrings = { + 'todo.subtab.packing': 'Paket Listesi', + 'todo.subtab.todo': 'Yapılacaklar', + 'todo.completed': 'tamamlandı', + 'todo.filter.all': 'Tümü', + 'todo.filter.open': 'Açık', + 'todo.filter.done': 'Tamamlandı', + 'todo.uncategorized': 'Kategorisiz', + 'todo.namePlaceholder': 'Görev adı', + 'todo.descriptionPlaceholder': 'Açıklama (isteğe bağlı)', + 'todo.unassigned': 'Atanmamış', + 'todo.noCategory': 'Kategori yok', + 'todo.hasDescription': 'Açıklama var', + 'todo.addItem': 'Yeni görev ekle', + 'todo.sidebar.sortBy': 'Sırala', + 'todo.priority': 'Öncelik', + 'todo.newCategoryLabel': 'yeni', + 'todo.newCategory': 'Kategori adı', + 'todo.addCategory': 'Kategori ekle', + 'todo.newItem': 'Yeni görev', + 'todo.empty': 'Henüz görev yok. Başlamak için bir görev ekleyin!', + 'todo.filter.my': 'Görevlerim', + 'todo.filter.overdue': 'Gecikmiş', + 'todo.sidebar.tasks': 'Görevler', + 'todo.sidebar.categories': 'Kategoriler', + 'todo.detail.title': 'Görev', + 'todo.detail.description': 'Açıklama', + 'todo.detail.category': 'Kategori', + 'todo.detail.dueDate': 'Son tarih', + 'todo.detail.assignedTo': 'Atanan', + 'todo.detail.delete': 'Sil', + 'todo.detail.save': 'Değişiklikleri kaydet', + 'todo.sortByPrio': 'Öncelik', + 'todo.detail.priority': 'Öncelik', + 'todo.detail.noPriority': 'Yok', + 'todo.detail.create': 'Görev oluştur', +}; +export default todo; diff --git a/shared/src/i18n/tr/transport.ts b/shared/src/i18n/tr/transport.ts new file mode 100644 index 0000000000000000000000000000000000000000..975577315e137e79b287f9cb93d02e82a0810718 --- /dev/null +++ b/shared/src/i18n/tr/transport.ts @@ -0,0 +1,10 @@ +import type { TranslationStrings } from '../types'; + +const transport: TranslationStrings = { + 'transport.addTransport': 'Ulaşım ekle', + 'transport.modalTitle.create': 'Ulaşım ekle', + 'transport.modalTitle.edit': 'Ulaşımı düzenle', + 'transport.title': 'Ulaşım', + 'transport.addManual': 'Manuel Ulaşım', +}; +export default transport; diff --git a/shared/src/i18n/tr/trip.ts b/shared/src/i18n/tr/trip.ts new file mode 100644 index 0000000000000000000000000000000000000000..11bbb5e6ff623f9ee87dc3f7ea0d0190075563bb --- /dev/null +++ b/shared/src/i18n/tr/trip.ts @@ -0,0 +1,31 @@ +import type { TranslationStrings } from '../types'; + +const trip: TranslationStrings = { + 'trip.tabs.plan': 'Planı', + 'trip.tabs.transports': 'Ulaşım', + 'trip.tabs.reservations': 'Rezervasyonlar', + 'trip.tabs.reservationsShort': 'Rezerv.', + 'trip.tabs.packing': 'Paket Listesi', + 'trip.tabs.packingShort': 'Paket', + 'trip.tabs.lists': 'Listeler', + 'trip.tabs.listsShort': 'Liste', + 'trip.tabs.budget': "Costs", + 'trip.tabs.files': 'Dosyalar', + 'trip.loading': 'Seyahat yükleniyor...', + 'trip.loadingPhotos': 'Yer fotoğrafları yükleniyor...', + 'trip.mobilePlan': 'Planı', + 'trip.mobilePlaces': 'Yerler', + 'trip.toast.placeUpdated': 'Yer güncellendi', + 'trip.toast.placeAdded': 'Yer eklendi', + 'trip.toast.placeDeleted': 'Yer silindi', + 'trip.toast.selectDay': 'Lütfen önce bir gün seçin', + 'trip.toast.assignedToDay': 'Yer güne atandı', + 'trip.toast.reorderError': 'Sıralama yapılamadı', + 'trip.toast.reservationUpdated': 'Rezervasyon güncellendi', + 'trip.toast.reservationAdded': 'Rezervasyon eklendi', + 'trip.toast.deleted': 'Silindi', + 'trip.confirm.deletePlace': 'Bu yeri silmek istediğinizden emin misiniz?', + 'trip.confirm.deletePlaces': '{count} Yer silinsin mi?', + 'trip.toast.placesDeleted': '{count} yer silindi', +}; +export default trip; diff --git a/shared/src/i18n/tr/trips.ts b/shared/src/i18n/tr/trips.ts new file mode 100644 index 0000000000000000000000000000000000000000..d0851687e42070a7a3c0cc8e5c4a78cce4d08b50 --- /dev/null +++ b/shared/src/i18n/tr/trips.ts @@ -0,0 +1,17 @@ +import type { TranslationStrings } from '../types'; + +const trips: TranslationStrings = { + 'trips.memberRemoved': '{username} kaldırıldı', + 'trips.memberRemoveError': 'Kaldırılamadı', + 'trips.memberAdded': '{username} eklendi', + 'trips.memberAddError': 'Eklenemedi', + 'trips.reminder': 'Hatırlatıcı', + 'trips.reminderNone': 'Yok', + 'trips.reminderDay': 'gün', + 'trips.reminderDays': 'gün', + 'trips.reminderCustom': 'Özel', + 'trips.reminderDaysBefore': 'hareketten önce gün', + 'trips.reminderDisabledHint': + 'Seyahat hatırlatıcıları kapalı. Yönetici > Ayarlar > Bildirimler bölümünden açın.', +}; +export default trips; diff --git a/shared/src/i18n/tr/undo.ts b/shared/src/i18n/tr/undo.ts new file mode 100644 index 0000000000000000000000000000000000000000..75c28350974ea19b0febea12c89549ae63d03930 --- /dev/null +++ b/shared/src/i18n/tr/undo.ts @@ -0,0 +1,22 @@ +import type { TranslationStrings } from '../types'; + +const undo: TranslationStrings = { + 'undo.button': 'Geri al', + 'undo.tooltip': 'Geri al: {action}', + 'undo.assignPlace': 'Yer güne atandı', + 'undo.removeAssignment': 'Yer günden kaldırıldı', + 'undo.reorder': 'Yerler yeniden sıralandı', + 'undo.optimize': 'Rota optimize edildi', + 'undo.deletePlace': 'Yer silindi', + 'undo.deletePlaces': 'Yerler silindi', + 'undo.moveDay': 'Yer başka güne taşındı', + 'undo.lock': 'Yer kilidi değiştirildi', + 'undo.importGpx': 'GPX içe aktarma', + 'undo.importKeyholeMarkup': 'KMZ/KML içe aktarma', + 'undo.importGoogleList': 'Google Haritalar içe aktarma', + 'undo.importNaverList': 'Naver Haritalar içe aktarma', + 'undo.addPlace': 'Yer eklendi', + 'undo.done': 'Geri alındı: {action}', + 'undo.importBooking': 'Rezervasyon onayı içe aktarma', +}; +export default undo; diff --git a/shared/src/i18n/tr/vacay.ts b/shared/src/i18n/tr/vacay.ts new file mode 100644 index 0000000000000000000000000000000000000000..6832d0d9c0ff6275b84eafaa1943a7e8c5a6a465 --- /dev/null +++ b/shared/src/i18n/tr/vacay.ts @@ -0,0 +1,105 @@ +import type { TranslationStrings } from '../types'; + +const vacay: TranslationStrings = { + 'vacay.subtitle': 'Tatil günlerini planlayın ve yönetin', + 'vacay.settings': 'Ayarlar', + 'vacay.year': 'Yıl', + 'vacay.addYear': 'Gelecek yıl ekle', + 'vacay.addPrevYear': 'Önceki yılı ekle', + 'vacay.removeYear': 'Yılı kaldır', + 'vacay.removeYearConfirm': '{year} Kaldırılsın mı?', + 'vacay.removeYearHint': + 'Bu yılın tüm tatil girişleri ve şirket tatilleri kalıcı olarak silinecek.', + 'vacay.remove': 'Kaldırmak', + 'vacay.persons': 'Kişiler', + 'vacay.noPersons': 'Hiç kişi eklenmedi', + 'vacay.addPerson': 'Kişi Ekle', + 'vacay.editPerson': 'Kişiyi Düzenle', + 'vacay.removePerson': 'Kişiyi Kaldır', + 'vacay.removePersonConfirm': '{name} Kaldırılsın mı?', + 'vacay.removePersonHint': + 'Bu kişinin tüm tatil girişleri kalıcı olarak silinecek.', + 'vacay.personName': 'İsim', + 'vacay.personNamePlaceholder': 'Ad girin', + 'vacay.color': 'Renk', + 'vacay.add': 'Eklemek', + 'vacay.legend': 'Efsane', + 'vacay.publicHoliday': 'Resmi Tatil', + 'vacay.companyHoliday': 'Şirket Tatili', + 'vacay.weekend': 'Hafta sonu', + 'vacay.modeVacation': 'Tatil', + 'vacay.modeCompany': 'Şirket Tatili', + 'vacay.entitlement': 'Yetki', + 'vacay.entitlementDays': 'Günler', + 'vacay.used': 'Kullanılmış', + 'vacay.remaining': 'Sol', + 'vacay.carriedOver': '{yıl} tarihinden itibaren', + 'vacay.blockWeekends': 'Hafta Sonlarını Engelle', + 'vacay.blockWeekendsHint': 'Hafta sonu günlerinde tatil girişlerini önleyin', + 'vacay.weekendDays': 'Hafta sonu günleri', + 'vacay.mon': 'Pazartesi', + 'vacay.tue': 'Salı', + 'vacay.wed': 'Çar', + 'vacay.thu': 'Per', + 'vacay.fri': 'Cuma', + 'vacay.sat': 'Doygunluk', + 'vacay.sun': 'Güneş', + 'vacay.publicHolidays': 'Resmi Tatiller', + 'vacay.publicHolidaysHint': 'Resmi tatil günlerini takvimde işaretleyin', + 'vacay.selectCountry': 'Ülke seçin', + 'vacay.selectRegion': 'Bölge seçin (isteğe bağlı)', + 'vacay.addCalendar': 'Takvim ekle', + 'vacay.calendarLabel': 'Etiket (isteğe bağlı)', + 'vacay.calendarColor': 'Renk', + 'vacay.noCalendars': 'Henüz tatil takvimi eklenmedi', + 'vacay.companyHolidays': 'Şirket Tatilleri', + 'vacay.companyHolidaysHint': + 'Şirket çapında tatil günlerinin işaretlenmesine izin ver', + 'vacay.companyHolidaysNoDeduct': + 'Şirket tatilleri tatil günlerinden sayılmaz.', + 'vacay.weekStart': 'Hafta başlıyor', + 'vacay.weekStartHint': + 'Takvim haftasının Pazartesi mi yoksa Pazar günü mü başlayacağını seçin', + 'vacay.carryOver': 'Devret', + 'vacay.carryOverHint': + 'Kalan tatil günlerini otomatik olarak bir sonraki yıla taşıyın', + 'vacay.sharing': 'Paylaşma', + 'vacay.sharingHint': 'Tatil planınızı diğer TREK kullanıcılarıyla paylaşın', + 'vacay.owner': 'Mal sahibi', + 'vacay.shareEmailPlaceholder': 'TREK kullanıcısının e-postası', + 'vacay.shareSuccess': 'Plan başarıyla paylaşıldı', + 'vacay.shareError': 'Plan paylaşılamadı', + 'vacay.dissolve': 'Füzyonu Çözün', + 'vacay.dissolveHint': 'Takvimleri tekrar ayırın. Girişleriniz saklanacaktır.', + 'vacay.dissolveAction': 'Çözün', + 'vacay.dissolved': 'Takvim ayrıldı', + 'vacay.fusedWith': 'İle kaynaşmış', + 'vacay.you': 'Sen', + 'vacay.noData': 'Veri yok', + 'vacay.changeColor': 'Rengi değiştir', + 'vacay.inviteUser': 'Kullanıcıyı Davet Et', + 'vacay.inviteHint': + 'Başka bir TREK kullanıcısını birleşik bir tatil takvimini paylaşmaya davet edin.', + 'vacay.selectUser': 'Kullanıcı seç', + 'vacay.sendInvite': 'Davet Gönder', + 'vacay.inviteSent': 'Davet gönderildi', + 'vacay.inviteError': 'Davet gönderilemedi', + 'vacay.pending': 'askıda olması', + 'vacay.noUsersAvailable': 'Kullanılabilir kullanıcı yok', + 'vacay.accept': 'Kabul etmek', + 'vacay.decline': 'Reddetmek', + 'vacay.acceptFusion': 'Kabul Et ve Sigortala', + 'vacay.inviteTitle': 'Füzyon Talebi', + 'vacay.inviteWantsToFuse': 'sizinle bir tatil takvimi paylaşmak istiyor.', + 'vacay.fuseInfo1': + 'İkiniz de tüm tatil kayıtlarını tek bir paylaşılan takvimde göreceksiniz.', + 'vacay.fuseInfo2': + 'Her iki taraf da birbirleri için girişler oluşturabilir ve düzenleyebilir.', + 'vacay.fuseInfo3': + 'Her iki taraf da girişleri silebilir ve tatil haklarını değiştirebilir.', + 'vacay.fuseInfo4': + 'Resmi tatiller ve şirket tatilleri gibi ayarlar paylaşılır.', + 'vacay.fuseInfo5': + 'Birleşme her iki tarafça da herhangi bir zamanda feshedilebilir. Girişleriniz korunacaktır.', +}; +export default vacay; diff --git a/shared/src/i18n/types.ts b/shared/src/i18n/types.ts new file mode 100644 index 0000000000000000000000000000000000000000..5bba13e9bfad443a5eadad4f1f8070fa17fe2b15 --- /dev/null +++ b/shared/src/i18n/types.ts @@ -0,0 +1,2 @@ +export type TranslationValue = string | { name: string; category: string }[]; +export type TranslationStrings = Record; diff --git a/shared/src/i18n/uk/admin.ts b/shared/src/i18n/uk/admin.ts new file mode 100644 index 0000000000000000000000000000000000000000..5c55c0e7ee4ff9c726009a80c7530cf4d41f71ff --- /dev/null +++ b/shared/src/i18n/uk/admin.ts @@ -0,0 +1,403 @@ +import type { TranslationStrings } from '../types'; + +const admin: TranslationStrings = { + 'admin.notifications.title': 'n', + 'admin.notifications.hint': + 'Виберіть канал сповіщень. Одночасно може бути активним лише один.', + 'admin.notifications.none': 'Вимкнено', + 'admin.notifications.email': 'Ел. пошта (SMTP)', + 'admin.notifications.webhook': 'Webhook', + 'admin.notifications.save': 'Зберегти налаштування сповіщень', + 'admin.notifications.saved': 'Налаштування сповіщень збережені', + 'admin.notifications.testWebhook': 'Відправити тестовий webhook', + 'admin.notifications.testWebhookSuccess': + 'Тестовий webhook успішно відправлено', + 'admin.notifications.testWebhookFailed': + "Помилка відправки тестового webhook'а", + 'admin.smtp.title': 'Пошта та сповіщення', + 'admin.smtp.hint': + 'Налаштування SMTP для відправки сповіщень електронною поштою.', + 'admin.smtp.testButton': 'Відправити тестовий лист', + 'admin.webhook.hint': + 'Відправляти сповіщення через зовнішній webhook (Discord, Slack тощо).', + 'admin.smtp.testSuccess': 'Тестовий лист успішно відправлено', + 'admin.smtp.testFailed': 'Помилка відправки тестового листа', + 'admin.title': 'Адміністрування', + 'admin.subtitle': 'Управління користувачами та системні налаштування', + 'admin.tabs.users': 'Користувачі', + 'admin.tabs.categories': 'Категорії', + 'admin.tabs.backup': 'Резервна копія', + 'admin.tabs.audit': 'Аудит', + 'admin.stats.users': 'Користувачі', + 'admin.stats.trips': 'Подорожі', + 'admin.stats.places': 'Місця', + 'admin.stats.photos': 'Фото', + 'admin.stats.files': 'Файли', + 'admin.table.user': 'Користувач', + 'admin.table.email': 'Ел. пошта', + 'admin.table.role': 'Роль', + 'admin.table.created': 'Створено', + 'admin.table.lastLogin': 'Останній вхід', + 'admin.table.actions': 'Дії', + 'admin.you': '(Ви)', + 'admin.editUser': 'Редагувати користувача', + 'admin.newPassword': 'Новий пароль', + 'admin.newPasswordHint': 'Залиште порожнім, щоб зберегти поточний пароль', + 'admin.deleteUser': + 'Видалити користувача «{name}»? Усі подорожі будуть безповоротно видалені.', + 'admin.deleteUserTitle': 'Видалити користувача', + 'admin.newPasswordPlaceholder': 'Введіть новий пароль…', + 'admin.toast.loadError': 'Не вдалося завантажити дані адміністрування', + 'admin.toast.userUpdated': 'Користувача оновлено', + 'admin.toast.updateError': 'Помилка оновлення', + 'admin.toast.userDeleted': 'Користувача видалено', + 'admin.toast.deleteError': 'Помилка видалення', + 'admin.toast.cannotDeleteSelf': 'Неможливо видалити власний акаунт', + 'admin.toast.userCreated': 'Користувача створено', + 'admin.toast.createError': 'Помилка створення користувача', + 'admin.toast.fieldsRequired': + 'Ім’я користувача, ел. пошта та пароль обов’язкові', + 'admin.createUser': 'Створити користувача', + 'admin.invite.title': 'Запрошення за посиланням', + 'admin.invite.subtitle': 'Створення одноразових посилань для реєстрації', + 'admin.invite.create': 'Створити посилання', + 'admin.invite.createAndCopy': 'Створити та скопіювати', + 'admin.invite.empty': 'Посилання-запрошення ще не створені', + 'admin.invite.maxUses': 'Макс. використань', + 'admin.invite.expiry': 'Дійсне', + 'admin.invite.uses': 'використано', + 'admin.invite.expiresAt': 'закінчується', + 'admin.invite.createdBy': 'від', + 'admin.invite.active': 'Активне', + 'admin.invite.expired': 'Закінчилося', + 'admin.invite.usedUp': 'Вичерпано', + 'admin.invite.copied': 'Посилання-запрошення скопійовано', + 'admin.invite.copyLink': 'Скопіювати посилання', + 'admin.invite.deleted': 'Посилання-запрошення видалено', + 'admin.invite.createError': 'Помилка створення посилання', + 'admin.invite.deleteError': 'Помилка видалення посилання', + 'admin.tabs.settings': 'Налаштування', + 'admin.allowRegistration': 'Дозволити реєстрацію', + 'admin.allowRegistrationHint': + 'Нові користувачі можуть реєструватися самостійно', + 'admin.authMethods': 'Методи автентифікації', + 'admin.passwordLogin': 'Вхід за паролем', + 'admin.passwordLoginHint': + 'Дозволити користувачам входити за ел. поштою та паролем', + 'admin.passwordRegistration': 'Реєстрація за паролем', + 'admin.passwordRegistrationHint': + 'Дозволити новим користувачам реєструватися за ел. поштою та паролем', + 'admin.oidcLogin': 'Вхід через SSO', + 'admin.oidcLoginHint': 'Дозволити користувачам входити через SSO', + 'admin.oidcRegistration': 'Автоматичне створення SSO-акаунтів', + 'admin.oidcRegistrationHint': + 'Автоматично створювати акаунти для нових SSO-користувачів', + 'admin.envOverrideHint': + 'Налаштування входу за паролем контролюються змінною середовища OIDC_ONLY і не можуть бути змінені тут.', + 'admin.lockoutWarning': + 'Потрібно залишити увімкненим принаймні один метод входу', + 'admin.requireMfa': 'Вимагати двофакторну автентифікацію (2FA)', + 'admin.requireMfaHint': + 'Користувачі без 2FA повинні завершити налаштування в розділі «Налаштування» перед використанням програми.', + 'admin.apiKeys': 'API-ключі', + 'admin.apiKeysHint': + 'Необов’язково. Включає розширені дані про місця, такі як фото та погода.', + 'admin.mapsKey': 'API-ключ Google Maps', + 'admin.mapsKeyHint': + 'Необхідний для пошуку місць. Отримайте на console.cloud.google.com', + 'admin.mapsKeyHintLong': + 'Без API-ключа для пошуку місць використовується OpenStreetMap. З ключем Google API можна завантажувати фото, рейтинги та години роботи. Отримайте ключ на console.cloud.google.com.', + 'admin.recommended': 'Рекомендується', + 'admin.weatherKey': 'API-ключ OpenWeatherMap', + 'admin.weatherKeyHint': + 'Для даних про погоду. Безкоштовно на openweathermap.org', + 'admin.validateKey': 'Перевірити', + 'admin.keyValid': 'Підключено', + 'admin.keyInvalid': 'Недійсний', + 'admin.keySaved': 'API-ключі збережено', + 'admin.oidcTitle': 'Єдиний вхід (OIDC)', + 'admin.oidcSubtitle': + 'Дозволити вхід через зовнішніх провайдерів, таких як Google, Apple, Authentik або Keycloak.', + 'admin.oidcDisplayName': 'Відображуване ім’я', + 'admin.oidcIssuer': 'URL видавця', + 'admin.oidcIssuerHint': + 'URL видавця OpenID Connect провайдера. Напр. https://accounts.google.com', + 'admin.oidcSaved': 'Конфігурацію OIDC збережено', + 'admin.oidcOnlyMode': 'Вимкнути вхід за паролем', + 'admin.oidcOnlyModeHint': + 'При ввімкненні дозволено тільки вхід через SSO. Вхід та реєстрація за паролем будуть заблоковані.', + 'admin.fileTypes': 'Дозволені типи файлів', + 'admin.fileTypesHint': + 'Налаштуйте, які типи файлів можуть завантажувати користувачі.', + 'admin.fileTypesFormat': + 'Розширення через кому (напр. jpg,png,pdf,doc). Використовуйте * для дозволу всіх типів.', + 'admin.fileTypesSaved': 'Налаштування типів файлів збережено', + 'admin.placesPhotos.title': 'Фотографії місць', + 'admin.placesPhotos.subtitle': + 'Завантаження фотографій з Google Places API. Вимкніть для економії квоти API. Фотографії Wikimedia не зачіпаються.', + 'admin.placesAutocomplete.title': 'Автодоповнення місць', + 'admin.placesAutocomplete.subtitle': + 'Використання Google Places API для підказок пошуку. Вимкніть для економії квоти API.', + 'admin.placesDetails.title': 'Відомості про місце', + 'admin.placesDetails.subtitle': + 'Завантаження детальної інформації про місце (години роботи, рейтинг, веб-сайт) з Google Places API. Вимкніть для економії квоти API.', + 'admin.bagTracking.title': 'Відстеження багажу', + 'admin.bagTracking.subtitle': + 'Увімкнути вагу та прив’язку до багажу для речей', + 'admin.collab.chat.title': 'Чат', + 'admin.collab.chat.subtitle': 'Обмін повідомленнями для спільної роботи', + 'admin.collab.notes.title': 'Нотатки', + 'admin.collab.notes.subtitle': 'Спільні нотатки та документи', + 'admin.collab.polls.title': 'Опитування', + 'admin.collab.polls.subtitle': 'Групові опитування та голосування', + 'admin.collab.whatsnext.title': 'Що далі', + 'admin.collab.whatsnext.subtitle': 'Пропозиції активностей та наступні кроки', + 'admin.tabs.config': 'Персоналізація', + 'admin.tabs.defaults': 'Налаштування за замовчуванням', + 'admin.defaultSettings.title': 'Налаштування користувачів за замовчуванням', + 'admin.defaultSettings.description': + 'Визначте значення за замовчуванням для всієї інстанції. Користувачі, які не змінювали параметр, побачать ці значення. Їхні власні зміни завжди мають пріоритет.', + 'admin.defaultSettings.saved': 'Значення за замовчуванням збережено', + 'admin.defaultSettings.reset': 'Скинути до вбудованого значення', + 'admin.defaultSettings.resetToBuiltIn': 'скинути', + 'admin.tabs.templates': 'Шаблони пакування', + 'admin.packingTemplates.title': 'Шаблони пакування', + 'admin.packingTemplates.subtitle': + 'Створюйте багаторазові списки речей для подорожей', + 'admin.packingTemplates.create': 'Новий шаблон', + 'admin.packingTemplates.namePlaceholder': + 'Назва шаблону (наприклад, Відпочинок на пляжі)', + 'admin.packingTemplates.empty': 'Шаблони ще не створені', + 'admin.packingTemplates.items': 'речей', + 'admin.packingTemplates.categories': 'категорії(й)', + 'admin.packingTemplates.itemName': 'Назва речі', + 'admin.packingTemplates.itemCategory': 'Категорія', + 'admin.packingTemplates.categoryName': 'Назва категорії (наприклад, Одяг)', + 'admin.packingTemplates.addCategory': 'Додати категорію', + 'admin.packingTemplates.created': 'Шаблон створено', + 'admin.packingTemplates.deleted': 'Шаблон видалено', + 'admin.packingTemplates.loadError': 'Помилка завантаження шаблонів', + 'admin.packingTemplates.createError': 'Помилка створення шаблону', + 'admin.packingTemplates.deleteError': 'Помилка видалення шаблону', + 'admin.packingTemplates.saveError': 'Помилка збереження', + 'admin.tabs.addons': 'Дополнения', + 'admin.addons.title': 'Доповнення', + 'admin.addons.subtitle': + 'Увімкніть або вимкніть функції, щоб налаштувати TREK під себе.', + 'admin.addons.catalog.memories.name': 'Фото (Immich)', + 'admin.addons.catalog.memories.description': + 'Діліться фотографіями з подорожей через Immich', + 'admin.addons.catalog.mcp.name': 'MCP', + 'admin.addons.catalog.mcp.description': + 'Протокол контексту моделі для інтеграції з ІІ-асистентами', + 'admin.addons.catalog.packing.name': 'Списки', + 'admin.addons.catalog.packing.description': + 'Списки речей та завдання для ваших подорожей', + 'admin.addons.catalog.budget.name': 'Бюджет', + 'admin.addons.catalog.budget.description': + 'Відстежуйте витрати та плануйте бюджет подорожі', + 'admin.addons.catalog.documents.name': 'Документи', + 'admin.addons.catalog.documents.description': + 'Зберігайте та керуйте документами для подорожей', + 'admin.addons.catalog.vacay.name': 'Vacay', + 'admin.addons.catalog.vacay.description': + 'Особистий планувальник відпусток з календарем', + 'admin.addons.catalog.atlas.name': 'Atlas', + 'admin.addons.catalog.atlas.description': + 'Карта світу з відвіданими країнами та статистикою подорожей', + 'admin.addons.catalog.collab.name': 'Collab', + 'admin.addons.catalog.collab.description': + 'Нотатки в реальному часі, опитування та чат для планування подорожей', + 'admin.addons.subtitleBefore': + 'Увімкніть або вимкніть функції для налаштування ', + 'admin.addons.subtitleAfter': ' під себе.', + 'admin.addons.enabled': 'Увімкнено', + 'admin.addons.disabled': 'Вимкнено', + 'admin.addons.type.trip': 'Поїздка', + 'admin.addons.type.global': 'Глобально', + 'admin.addons.type.integration': 'Інтеграція', + 'admin.addons.tripHint': 'Доступно як вкладка всередині кожної подорожі', + 'admin.addons.globalHint': 'Доступно як окремий розділ у головній навігації', + 'admin.addons.integrationHint': + 'Фонові сервіси та API-інтеграції без окремої сторінки', + 'admin.addons.toast.updated': 'Доповнення оновлено', + 'admin.addons.toast.error': 'Не вдалося оновити доповнення', + 'admin.addons.noAddons': 'Немає доступних доповнень', + 'admin.weather.title': 'Дані про погоду', + 'admin.weather.badge': 'З 24 березня 2026', + 'admin.weather.description': + 'TREK використовує Open-Meteo як джерело даних про погоду. Open-Meteo — безкоштовний сервіс з відкритим кодом, API-ключ не потрібен.', + 'admin.weather.forecast': 'Прогноз на 16 днів', + 'admin.weather.forecastDesc': 'Раніше 5 днів (OpenWeatherMap)', + 'admin.weather.climate': 'Історичні кліматичні дані', + 'admin.weather.climateDesc': + 'Середні значення за останні 85 років для днів поза межами 16-денного прогнозу', + 'admin.weather.requests': '10 000 запитів / день', + 'admin.weather.requestsDesc': 'Безкоштовно, API-ключ не потрібен', + 'admin.weather.locationHint': + 'Погода базується на першому місці з координатами в кожному дні. Якщо жодне місце не призначено на день, як орієнтир використовується будь-яке місце зі списку.', + 'admin.tabs.mcpTokens': 'MCP-доступ', + 'admin.mcpTokens.title': 'MCP-доступ', + 'admin.mcpTokens.subtitle': + 'Управління OAuth-сеансами та API-токенами всіх користувачів', + 'admin.mcpTokens.sectionTitle': 'API-токени', + 'admin.mcpTokens.owner': 'Власник', + 'admin.mcpTokens.tokenName': 'Назва токена', + 'admin.mcpTokens.created': 'Створено', + 'admin.mcpTokens.lastUsed': 'Останнє використання', + 'admin.mcpTokens.never': 'Ніколи', + 'admin.mcpTokens.empty': 'MCP-токени ще не створені', + 'admin.mcpTokens.deleteTitle': 'Видалити токен', + 'admin.mcpTokens.deleteMessage': + 'Токен буде негайно відкликано. Користувач втратить доступ до MCP через цей токен.', + 'admin.mcpTokens.deleteSuccess': 'Токен видалено', + 'admin.mcpTokens.deleteError': 'Не вдалося видалити токен', + 'admin.mcpTokens.loadError': 'Не вдалося завантажити токени', + 'admin.oauthSessions.sectionTitle': 'OAuth-сеанси', + 'admin.oauthSessions.clientName': 'Клієнт', + 'admin.oauthSessions.owner': 'Власник', + 'admin.oauthSessions.scopes': 'Права доступу', + 'admin.oauthSessions.created': 'Створено', + 'admin.oauthSessions.empty': 'Немає активних OAuth-сеансів', + 'admin.oauthSessions.revokeTitle': 'Відкликати сеанс', + 'admin.oauthSessions.revokeMessage': + 'Цей OAuth-сеанс буде негайно відкликаний. Клієнт втратить доступ до MCP.', + 'admin.oauthSessions.revokeSuccess': 'Сеанс відкликано', + 'admin.oauthSessions.revokeError': 'Не вдалося відкликати сеанс', + 'admin.oauthSessions.loadError': 'Не вдалося завантажити OAuth-сеанси', + 'admin.tabs.github': 'GitHub', + 'admin.audit.subtitle': + 'Події, пов’язані з безпекою та адмініструванням (резервні копії, користувачі, MFA, налаштування).', + 'admin.audit.empty': 'Записів аудиту поки немає.', + 'admin.audit.refresh': 'Оновити', + 'admin.audit.loadMore': 'Завантажити ще', + 'admin.audit.showing': 'Завантажено: {count} · всього {total}', + 'admin.audit.col.time': 'Час', + 'admin.audit.col.user': 'Користувач', + 'admin.audit.col.action': 'Дія', + 'admin.audit.col.resource': 'Об’єкт', + 'admin.audit.col.ip': 'IP', + 'admin.audit.col.details': 'Деталі', + 'admin.github.title': 'Історія релізів', + 'admin.github.subtitle': 'Останні оновлення з {repo}', + 'admin.github.latest': 'Останній', + 'admin.github.prerelease': 'Пререліз', + 'admin.github.showDetails': 'Показати деталі', + 'admin.github.hideDetails': 'Сховати деталі', + 'admin.github.loadMore': 'Завантажити ще', + 'admin.github.loading': 'Завантаження...', + 'admin.github.support': 'Допомагає продовжувати розробку TREK', + 'admin.github.error': 'Не вдалося завантажити релізи', + 'admin.github.by': 'від', + 'admin.update.available': 'Доступне оновлення', + 'admin.update.text': + 'Доступна версія TREK {version}. У вас встановлено {current}.', + 'admin.update.button': 'Переглянути на GitHub', + 'admin.update.install': 'Встановити оновлення', + 'admin.update.confirmTitle': 'Встановити оновлення?', + 'admin.update.confirmText': + 'TREK буде оновлено з {current} до {version}. Сервер перезапуститься автоматично.', + 'admin.update.dataInfo': + 'Усі ваші дані (поїздки, користувачі, API-ключі, завантаження, Vacay, Atlas, бюджети) будуть збережені.', + 'admin.update.warning': + 'Застосунок буде тимчасово недоступний під час перезапуску.', + 'admin.update.confirm': 'Оновити зараз', + 'admin.update.installing': 'Оновлення…', + 'admin.update.success': 'Оновлення встановлено! Сервер перезапускається…', + 'admin.update.failed': 'Помилка оновлення', + 'admin.update.backupHint': + 'Рекомендуємо створити резервну копію перед оновленням.', + 'admin.update.backupLink': 'Перейти до резервних копій', + 'admin.update.howTo': 'Як оновити', + 'admin.update.dockerText': + 'Ваш екземпляр TREK працює в Docker. Для оновлення до {version} виконайте ці команди на сервері:', + 'admin.update.reloadHint': 'Перезавантажте сторінку через кілька секунд.', + 'admin.tabs.permissions': 'Дозволи', + 'admin.notifications.emailPanel.title': 'Email (SMTP)', + 'admin.notifications.webhookPanel.title': 'Webhook', + 'admin.notifications.inappPanel.title': 'In-App', + 'admin.notifications.inappPanel.hint': + 'Сповіщення в додатку завжди активні і не можуть бути вимкнені глобально.', + 'admin.notifications.adminWebhookPanel.title': 'Webhook адміністратора', + 'admin.notifications.adminWebhookPanel.hint': + 'Цей webhook використовується виключно для сповіщень адміністратора (наприклад, повідомлень про версії). Він незалежить від користувацьких вебхуків і надсилається автоматично при наявності URL.', + 'admin.notifications.adminWebhookPanel.saved': + 'URL вебхука адміністратора збережено', + 'admin.notifications.adminWebhookPanel.testSuccess': + 'Тестовий webhook успішно надіслано', + 'admin.notifications.adminWebhookPanel.testFailed': + 'Помилка тестового вебхука', + 'admin.notifications.adminWebhookPanel.alwaysOnHint': + 'Webhook адміністратора надсилається автоматично при наявності URL', + 'admin.notifications.ntfy': 'Ntfy', + 'admin.ntfy.hint': + 'Дозволяє користувачам налаштовувати власні теми Ntfy для push-сповіщень. Встановіть сервер за замовчуванням нижче, щоб попередньо заповнити налаштування користувачів.', + 'admin.notifications.testNtfy': 'Надіслати тестовий Ntfy', + 'admin.notifications.testNtfySuccess': 'Тестовий Ntfy успішно надіслано', + 'admin.notifications.testNtfyFailed': 'Помилка надсилання тестового Ntfy', + 'admin.notifications.adminNtfyPanel.title': 'Ntfy адміністратора', + 'admin.notifications.adminNtfyPanel.hint': + 'Ця тема Ntfy використовується виключно для сповіщень адміністратора (наприклад, повідомлень про версії). Вона незалежна від тем користувачів і завжди надсилається при наявності налаштування.', + 'admin.notifications.adminNtfyPanel.serverLabel': 'URL сервера Ntfy', + 'admin.notifications.adminNtfyPanel.serverHint': + 'Також використовується як сервер за замовчуванням для ntfy-сповіщень користувачів. Залиште пустим, щоб використовувати ntfy.sh. Користувачі можуть змінити це в своїх налаштуваннях.', + 'admin.notifications.adminNtfyPanel.serverPlaceholder': 'https://ntfy.sh', + 'admin.notifications.adminNtfyPanel.topicLabel': 'Тема адміністратора', + 'admin.notifications.adminNtfyPanel.topicPlaceholder': 'trek-admin-alerts', + 'admin.notifications.adminNtfyPanel.tokenLabel': + 'Токен доступу (необов’язково)', + 'admin.notifications.adminNtfyPanel.tokenCleared': + 'Токен доступу адміністратора очищено', + 'admin.notifications.adminNtfyPanel.saved': + 'Налаштування Ntfy адміністратора збережено', + 'admin.notifications.adminNtfyPanel.test': 'Надіслати тестовий Ntfy', + 'admin.notifications.adminNtfyPanel.testSuccess': + 'Тестовий Ntfy успішно надіслано', + 'admin.notifications.adminNtfyPanel.testFailed': + 'Помилка надсилання тестового Ntfy', + 'admin.notifications.adminNtfyPanel.alwaysOnHint': + 'Ntfy адміністратора завжди надсилається при наявності налаштованої теми', + 'admin.notifications.adminNotificationsHint': + 'Налаштуйте, які канали доставляють сповіщення адміністратора (наприклад, повідомлення про версії). Вебхук надсилається автоматично, якщо задано URL вебхука адміністратора.', + 'admin.notifications.tripReminders.title': 'Нагадування про поїздки', + 'admin.notifications.tripReminders.hint': + 'Надсилає нагадування перед початком поїздки (необхідно вказати дні нагадування в параметрах поїздки).', + 'admin.notifications.tripReminders.enabled': + 'Нагадування про поїздки увімкнено', + 'admin.notifications.tripReminders.disabled': + 'Нагадування про поїздки вимкнено', + 'admin.tabs.notifications': 'Сповіщення', + 'admin.addons.catalog.journey.name': 'Journey', + 'admin.addons.catalog.journey.description': + 'Відстеження поїздок і щоденник подорожей з позначками, фото та щоденними історіями', + 'admin.passkey.title': 'Вхід за допомогою passkey', + 'admin.passkey.cardHint': + 'Дозволити користувачам входити за допомогою passkey (WebAuthn). За замовчуванням вимкнено.', + 'admin.passkey.login': 'Увімкнути вхід за допомогою passkey', + 'admin.passkey.loginHint': + 'Показувати опцію «Увійти за допомогою passkey» та дозволити користувачам реєструвати passkeys у своїх налаштуваннях.', + 'admin.passkey.notConfigured': + 'Для цього розгортання поки не визначено жодного домену WebAuthn. Вкажіть APP_URL або Relying Party ID нижче — до того часу passkeys залишатимуться прихованими.', + 'admin.passkey.rpId': 'Relying Party ID (домен)', + 'admin.passkey.rpIdHint': + 'Чистий домен, до якого прив’язані passkeys, напр. trek.example.org. Залиште порожнім, щоб визначити його з APP_URL. Подальша зміна робить наявні passkeys недійсними.', + 'admin.passkey.origins': 'Дозволені джерела (origins)', + 'admin.passkey.originsHint': + 'Повні джерела через кому, напр. https://trek.example.org. Залиште порожнім, щоб використати APP_URL.', + 'admin.passkey.reset': 'Скинути passkeys', + 'admin.passkey.resetHint': + 'Видалити всі passkeys цього користувача (напр. у разі втрати пристрою). Він зможе входити за допомогою свого пароля.', + 'admin.passkey.resetConfirm': 'Видалити всі passkeys для {name}?', + 'admin.passkey.resetDone': 'Видалено passkeys: {count}', + 'admin.defaultSettings.mapProvider': 'Картографічний рушій', + 'admin.defaultSettings.mapProviderHint': 'Карта за замовчуванням для всіх на цьому екземплярі. Кожен користувач може змінити її у власних налаштуваннях.', + 'admin.defaultSettings.providerLeaflet': 'Стандартна (безкоштовна)', + 'admin.defaultSettings.providerMapbox': 'Mapbox (3D)', + 'admin.defaultSettings.mapboxToken': 'Спільний токен Mapbox', + 'admin.defaultSettings.mapboxTokenHint': 'Використовується для кожного користувача, який не ввів власний токен — щоб увесь екземпляр отримав Mapbox без потреби ділитися ключем окремо. Зберігається в зашифрованому вигляді.', + 'admin.defaultSettings.mapboxStyle': 'Стиль карти', + 'admin.defaultSettings.mapboxStylePlaceholder': 'Виберіть стиль…', + 'admin.defaultSettings.mapbox3d': '3D-будівлі та рельєф', + 'admin.defaultSettings.mapboxQuality': 'Режим високої якості', +}; +export default admin; diff --git a/shared/src/i18n/uk/airport.ts b/shared/src/i18n/uk/airport.ts new file mode 100644 index 0000000000000000000000000000000000000000..4e76558e018e87a6819413bcb0295e70907129a2 --- /dev/null +++ b/shared/src/i18n/uk/airport.ts @@ -0,0 +1,6 @@ +import type { TranslationStrings } from '../types'; + +const airport: TranslationStrings = { + 'airport.searchPlaceholder': 'Код аеропорту або місто (наприклад, FRA)', +}; +export default airport; diff --git a/shared/src/i18n/uk/atlas.ts b/shared/src/i18n/uk/atlas.ts new file mode 100644 index 0000000000000000000000000000000000000000..ebe4a117d6c6396e545bd3e3f92d74a5e7377410 --- /dev/null +++ b/shared/src/i18n/uk/atlas.ts @@ -0,0 +1,59 @@ +import type { TranslationStrings } from '../types'; + +const atlas: TranslationStrings = { + 'atlas.subtitle': 'Ваш слід подорожей по всьому світу', + 'atlas.countries': 'Країни', + 'atlas.trips': 'Подорожі', + 'atlas.places': 'Місця', + 'atlas.days': 'Дні', + 'atlas.visitedCountries': 'Відвідані країни', + 'atlas.cities': 'Міста', + 'atlas.noData': 'Даних про подорожі поки немає', + 'atlas.noDataHint': + 'Створіть подорож і додайте місця, щоб побачити карту світу', + 'atlas.lastTrip': 'Остання подорож', + 'atlas.nextTrip': 'Наступна подорож', + 'atlas.daysLeft': 'днів залишилося', + 'atlas.streak': 'Серія', + 'atlas.year': 'рік', + 'atlas.years': 'років', + 'atlas.yearInRow': 'рік підряд', + 'atlas.yearsInRow': 'років підряд', + 'atlas.tripIn': 'подорожі до', + 'atlas.tripsIn': 'подорожей до', + 'atlas.since': 'з', + 'atlas.europe': 'Європа', + 'atlas.asia': 'Азія', + 'atlas.northAmerica': 'Пн. Америка', + 'atlas.southAmerica': 'Пд. Америка', + 'atlas.africa': 'Африка', + 'atlas.oceania': 'Океанія', + 'atlas.other': 'Інше', + 'atlas.firstVisit': 'Перша поїздка', + 'atlas.lastVisitLabel': 'Остання поїздка', + 'atlas.tripSingular': 'Поїздка', + 'atlas.tripPlural': 'Поїздки', + 'atlas.placeVisited': 'Відвідане місце', + 'atlas.placesVisited': 'Відвідані місця', + 'atlas.statsTab': 'Статистика', + 'atlas.bucketTab': 'Список бажань', + 'atlas.addBucket': 'Додати до списку бажань', + 'atlas.bucketNamePlaceholder': 'Місце або напрямок...', + 'atlas.bucketNotesPlaceholder': 'Нотатки (необов’язково)', + 'atlas.bucketEmpty': 'Ваш список бажань порожній', + 'atlas.bucketEmptyHint': 'Додайте місця, які мрієте відвідати', + 'atlas.unmark': 'Видалити', + 'atlas.confirmMark': 'Позначити цю країну як відвідану?', + 'atlas.confirmUnmark': 'Видалити цю країну зі списку відвіданих?', + 'atlas.confirmUnmarkRegion': 'Видалити цей регіон зі списку відвіданих?', + 'atlas.markVisited': 'Позначити як відвідану', + 'atlas.markVisitedHint': 'Додати цю країну до списку відвіданих', + 'atlas.markRegionVisitedHint': 'Додати цей регіон до списку відвіданих', + 'atlas.addToBucket': 'До списку бажань', + 'atlas.addPoi': 'Додати місце', + 'atlas.searchCountry': 'Пошук країни...', + 'atlas.month': 'Місяць', + 'atlas.addToBucketHint': 'Зберегти як місце для відвідування', + 'atlas.bucketWhen': 'Коли ви плануєте поїхати?', +}; +export default atlas; diff --git a/shared/src/i18n/uk/backup.ts b/shared/src/i18n/uk/backup.ts new file mode 100644 index 0000000000000000000000000000000000000000..04646ee79f4a594928c415953a8b268eaed043e1 --- /dev/null +++ b/shared/src/i18n/uk/backup.ts @@ -0,0 +1,76 @@ +import type { TranslationStrings } from '../types'; + +const backup: TranslationStrings = { + 'backup.title': 'Резервна копія', + 'backup.subtitle': 'База даних та всі завантажені файли', + 'backup.refresh': 'Оновити', + 'backup.upload': 'Завантажити копію', + 'backup.uploading': 'Завантаження…', + 'backup.create': 'Створити копію', + 'backup.creating': 'Створення…', + 'backup.empty': 'Резервних копій немає', + 'backup.createFirst': 'Створити першу копію', + 'backup.download': 'Завантажити', + 'backup.restore': 'Відновити', + 'backup.confirm.restore': + 'Відновити копію «{name}»?\n\nУсі поточні дані будуть замінені даними з копії.', + 'backup.confirm.uploadRestore': + 'Завантажити та відновити файл копії «{name}»?\n\nУсі поточні дані будуть перезаписані.', + 'backup.confirm.delete': 'Видалити копію «{name}»?', + 'backup.toast.loadError': 'Не вдалося завантажити резервні копії', + 'backup.toast.created': 'Резервну копію створено', + 'backup.toast.createError': 'Не вдалося створити резервну копію', + 'backup.toast.restored': 'Копію відновлено. Сторінка перезавантажиться…', + 'backup.toast.restoreError': 'Помилка відновлення', + 'backup.toast.uploadError': 'Помилка завантаження', + 'backup.toast.deleted': 'Резервну копію видалено', + 'backup.toast.deleteError': 'Помилка видалення', + 'backup.toast.downloadError': 'Помилка завантаження', + 'backup.toast.settingsSaved': 'Налаштування автокопіювання збережено', + 'backup.toast.settingsError': 'Не вдалося зберегти налаштування', + 'backup.auto.title': 'Автокопіювання', + 'backup.auto.subtitle': 'Автоматичне резервне копіювання за розкладом', + 'backup.auto.enable': 'Увімкнути автокопіювання', + 'backup.auto.enableHint': + 'Резервні копії створюватимуться автоматично за обраним графіком', + 'backup.auto.interval': 'Інтервал', + 'backup.auto.hour': 'Запуск о', + 'backup.auto.hourHint': 'Місцевий час сервера (формат {format})', + 'backup.auto.dayOfWeek': 'День тижня', + 'backup.auto.dayOfMonth': 'День місяця', + 'backup.auto.dayOfMonthHint': 'Обмежено 1–28 для сумісності з усіма місяцями', + 'backup.auto.scheduleSummary': 'Графік', + 'backup.auto.summaryDaily': 'Щодня о {hour}:00', + 'backup.auto.summaryWeekly': 'Щотижня в {day} о {hour}:00', + 'backup.auto.summaryMonthly': '{day}-го числа кожного місяця о {hour}:00', + 'backup.auto.envLocked': 'Docker', + 'backup.auto.envLockedHint': + 'Автокопіювання налаштовано через змінні оточення Docker. Щоб змінити параметри, оновіть docker-compose.yml і перезапустіть контейнер.', + 'backup.auto.copyEnv': 'Скопіювати змінні оточення Docker', + 'backup.auto.envCopied': 'Змінні оточення Docker скопійовано в буфер обміну', + 'backup.auto.keepLabel': 'Видаляти старі копії через', + 'backup.dow.sunday': 'Нд', + 'backup.dow.monday': 'Пн', + 'backup.dow.tuesday': 'Вт', + 'backup.dow.wednesday': 'Ср', + 'backup.dow.thursday': 'Чт', + 'backup.dow.friday': 'Пт', + 'backup.dow.saturday': 'Сб', + 'backup.interval.hourly': 'Кожну годину', + 'backup.interval.daily': 'Щодня', + 'backup.interval.weekly': 'Щотижня', + 'backup.interval.monthly': 'Щомісяця', + 'backup.keep.1day': '1 день', + 'backup.keep.3days': '3 дні', + 'backup.keep.7days': '7 днів', + 'backup.keep.14days': '14 днів', + 'backup.keep.30days': '30 днів', + 'backup.keep.forever': 'Зберігати вічно', + 'backup.restoreConfirmTitle': 'Відновити копію?', + 'backup.restoreWarning': + 'Усі поточні дані (поїздки, місця, користувачі, завантаження) будуть безповоротно замінені даними з копії. Цю дію неможливо скасувати.', + 'backup.restoreTip': + 'Порада: створіть резервну копію поточного стану перед відновленням.', + 'backup.restoreConfirm': 'Так, відновити', +}; +export default backup; diff --git a/shared/src/i18n/uk/budget.ts b/shared/src/i18n/uk/budget.ts new file mode 100644 index 0000000000000000000000000000000000000000..889940b53fb415729406837470e94bc7b25f8bf7 --- /dev/null +++ b/shared/src/i18n/uk/budget.ts @@ -0,0 +1,116 @@ +import type { TranslationStrings } from '../types'; + +const budget: TranslationStrings = { + 'budget.title': 'Бюджет', + 'budget.exportCsv': 'Експорт CSV', + 'budget.emptyTitle': 'Бюджет ще не створено', + 'budget.emptyText': + 'Створіть категорії й записи для планування бюджету поїздки', + 'budget.emptyPlaceholder': 'Введіть назву категорії...', + 'budget.createCategory': 'Створити категорію', + 'budget.category': 'Категорія', + 'budget.categoryName': 'Назва категорії', + 'budget.table.name': 'Назва', + 'budget.table.total': 'Всього', + 'budget.table.persons': 'Осіб', + 'budget.table.days': 'Днів', + 'budget.table.perPerson': 'На особу', + 'budget.table.perDay': 'На день', + 'budget.table.perPersonDay': 'Ос./день', + 'budget.table.note': 'Нотатка', + 'budget.table.date': 'Дата', + 'budget.newEntry': 'Новий запис', + 'budget.defaultEntry': 'Новий запис', + 'budget.defaultCategory': 'Нова категорія', + 'budget.total': 'Всього', + 'budget.totalBudget': 'Загальний бюджет', + 'budget.byCategory': 'За категоріями', + 'budget.editTooltip': 'Натисніть для редагування', + 'budget.linkedToReservation': 'Пов’язано з бронюванням — редагуйте назву там', + 'budget.confirm.deleteCategory': + 'Ви впевнені, що хочете видалити категорію «{name}» з {count} записами?', + 'budget.deleteCategory': 'Видалити категорію', + 'budget.perPerson': 'На особу', + 'budget.paid': 'Оплачено', + 'budget.open': 'Не оплачено', + 'budget.noMembers': 'Учасники не призначені', + 'budget.settlement': 'Взаєморозрахунок', + 'budget.settlementInfo': + 'Натисніть на аватар учасника в рядку бюджету, щоб відзначити його зеленим — це означає, що він заплатив. Взаєморозрахунок покаже, хто кому і скільки винен.', + 'budget.netBalances': 'Чисті баланси', + 'budget.categoriesLabel': 'категорії', + "costs.you": "Ви", + "costs.youShort": "Ви", + "costs.youLower": "ви", + "costs.youOwe": "Ви винні", + "costs.youOweSub": "Ви маєте заплатити іншим", + "costs.youreOwed": "Вам винні", + "costs.youreOwedSub": "Інші мають заплатити вам", + "costs.totalSpend": "Загальні витрати поїздки", + "costs.totalSpendSub": "Серед усіх мандрівників", + "costs.to": "Кому", + "costs.from": "Від", + "costs.allSettled": "Усі розрахунки завершено", + "costs.nothingOwed": "Вам нічого не винні", + "costs.yourShare": "Ваша частка", + "costs.youPaid": "Ви заплатили", + "costs.expenses": "Витрати", + "costs.entries": "{count} записів", + "costs.searchPlaceholder": "Пошук витрат…", + "costs.filter.all": "Усі", + "costs.filter.mine": "Сплачено мною", + "costs.filter.owed": "Мені винні", + "costs.addExpense": "Додати витрату", + "costs.editExpense": "Редагувати витрату", + "costs.noMatch": "Жодна витрата не відповідає пошуку.", + "costs.emptyText": "Витрат ще немає. Додайте першу.", + "costs.spent": "Витрачено {amount}", + "costs.noDate": "Без дати", + "costs.noOnePaid": "Ще ніхто не заплатив", + "costs.youLent": "ви позичили {amount}", + "costs.youBorrowed": "ви заборгували {amount}", + "costs.settleUp": "Розрахуватися", + "costs.history": "Історія", + "costs.everyoneSquare": "Усі розрахувалися", + "costs.nothingOutstanding": "Зараз немає непогашених платежів.", + "costs.pay": "заплатити", + "costs.pays": "платить", + "costs.settle": "Розрахувати", + "costs.balances": "Баланси", + "costs.byCategory": "За категоріями", + "costs.noCategories": "Витрат ще немає.", + "costs.settleHistory": "Історія розрахунків", + "costs.noSettlements": "Розрахованих платежів ще немає.", + "costs.paymentsSettled": "Розраховано платежів: {count}", + "costs.paid": "сплачено", + "costs.undo": "Скасувати", + "costs.whatFor": "За що це було?", + "costs.namePlaceholder": "напр. вечеря, сувеніри, пальне…", + "costs.totalAmount": "Загальна сума", + "costs.currency": "Валюта", + "costs.day": "День", + "costs.rateLabel": "1 {from} у {to}", + "costs.category": "Категорія", + "costs.whoPaid": "Хто заплатив?", + "costs.splitBetween": "Розділити порівну між", + "costs.pickSomeone": "Виберіть хоча б одну особу для розподілу.", + "costs.splitSummary": "Розділено на {count} · по {amount}", + "costs.cat.accommodation": "Проживання", + "costs.cat.food": "Їжа та напої", + "costs.cat.groceries": "Продукти", + "costs.cat.transport": "Транспорт", + "costs.cat.flights": "Авіапереліт", + "costs.cat.activities": "Активності", + "costs.cat.sightseeing": "Огляд пам’яток", + "costs.cat.shopping": "Покупки", + "costs.cat.fees": "Збори та квитки", + "costs.cat.health": "Здоров’я", + "costs.cat.tips": "Чайові", + "costs.cat.other": "Інше", + "costs.daysCount": "{count} днів", + "costs.travelers": "{count} мандрівників", + "costs.liveRate": "поточний курс", + "costs.settleAll": "Розрахувати все", +}; + +export default budget; diff --git a/shared/src/i18n/uk/categories.ts b/shared/src/i18n/uk/categories.ts new file mode 100644 index 0000000000000000000000000000000000000000..f0f2617df8b28db57ac2e09aeab6dfccd3bee8e2 --- /dev/null +++ b/shared/src/i18n/uk/categories.ts @@ -0,0 +1,26 @@ +import type { TranslationStrings } from '../types'; + +const categories: TranslationStrings = { + 'categories.title': 'Категорії', + 'categories.subtitle': 'Управління категоріями місць', + 'categories.new': 'Нова категорія', + 'categories.empty': 'Категорій поки немає', + 'categories.namePlaceholder': 'Назва категорії', + 'categories.icon': 'Іконка', + 'categories.color': 'Колір', + 'categories.customColor': 'Вибрати свій колір', + 'categories.preview': 'Попередній перегляд', + 'categories.defaultName': 'Категорія', + 'categories.update': 'Оновити', + 'categories.create': 'Створити', + 'categories.confirm.delete': + 'Видалити категорію? Місця в цій категорії не будуть видалені.', + 'categories.toast.loadError': 'Не вдалося завантажити категорії', + 'categories.toast.nameRequired': 'Введіть назву', + 'categories.toast.updated': 'Категорію оновлено', + 'categories.toast.created': 'Категорію створено', + 'categories.toast.saveError': 'Помилка збереження', + 'categories.toast.deleted': 'Категорію видалено', + 'categories.toast.deleteError': 'Помилка видалення', +}; +export default categories; diff --git a/shared/src/i18n/uk/collab.ts b/shared/src/i18n/uk/collab.ts new file mode 100644 index 0000000000000000000000000000000000000000..97692b15a1d4fc887192e39831f9d7425dfd91c2 --- /dev/null +++ b/shared/src/i18n/uk/collab.ts @@ -0,0 +1,76 @@ +import type { TranslationStrings } from '../types'; + +const collab: TranslationStrings = { + 'collab.tabs.chat': 'Чат', + 'collab.tabs.notes': 'Нотатки', + 'collab.tabs.polls': 'Опитування', + 'collab.whatsNext.title': 'Що далі', + 'collab.whatsNext.today': 'Сьогодні', + 'collab.whatsNext.tomorrow': 'Завтра', + 'collab.whatsNext.empty': 'Немає майбутніх активностей', + 'collab.whatsNext.until': 'до', + 'collab.whatsNext.emptyHint': 'Активності з часом відображатимуться тут', + 'collab.chat.send': 'Відправити', + 'collab.chat.placeholder': 'Введіть повідомлення...', + 'collab.chat.empty': 'Розпочніть розмову', + 'collab.chat.emptyHint': 'Повідомлення видимі всім учасникам поїздки', + 'collab.chat.emptyDesc': + 'Діліться ідеями, планами та новинами з вашою групою', + 'collab.chat.today': 'Сьогодні', + 'collab.chat.yesterday': 'Вчора', + 'collab.chat.deletedMessage': 'видалив(ла) повідомлення', + 'collab.chat.reply': 'Відповісти', + 'collab.chat.loadMore': 'Завантажити старі повідомлення', + 'collab.chat.justNow': 'щойно', + 'collab.chat.minutesAgo': '{n} хв. тому', + 'collab.chat.hoursAgo': '{n} год. тому', + 'collab.notes.title': 'Нотатки', + 'collab.notes.new': 'Нова нотатка', + 'collab.notes.empty': 'Нотаток поки що немає', + 'collab.notes.emptyHint': 'Почніть записувати ідеї та плани', + 'collab.notes.all': 'Усі', + 'collab.notes.titlePlaceholder': 'Назва нотатки', + 'collab.notes.contentPlaceholder': 'Напишіть щось...', + 'collab.notes.categoryPlaceholder': 'Категорія', + 'collab.notes.newCategory': 'Нова категорія...', + 'collab.notes.category': 'Категорія', + 'collab.notes.noCategory': 'Без категорії', + 'collab.notes.color': 'Колір', + 'collab.notes.save': 'Зберегти', + 'collab.notes.cancel': 'Скасувати', + 'collab.notes.edit': 'Редагувати', + 'collab.notes.delete': 'Видалити', + 'collab.notes.confirmDeleteTitle': 'Видалити нотатку?', + 'collab.notes.confirmDeleteBody': 'Цю нотатку буде видалено назавжди.', + 'collab.notes.pin': 'Закріпити', + 'collab.notes.unpin': 'Відкріпити', + 'collab.notes.daysAgo': '{n} дн. тому', + 'collab.notes.categorySettings': 'Керування категоріями', + 'collab.notes.create': 'Створити', + 'collab.notes.website': 'Сайт', + 'collab.notes.websitePlaceholder': 'https://...', + 'collab.notes.attachFiles': 'Прикріпити файли', + 'collab.notes.noCategoriesYet': 'Категорій поки що немає', + 'collab.notes.emptyDesc': 'Створіть нотатку, щоб почати', + 'collab.polls.title': 'Опитування', + 'collab.polls.new': 'Нове опитування', + 'collab.polls.empty': 'Опитувань поки що немає', + 'collab.polls.emptyHint': 'Поставте питання групі і голосуйте разом', + 'collab.polls.question': 'Питання', + 'collab.polls.questionPlaceholder': 'Що нам робити?', + 'collab.polls.addOption': '+ Додати варіант', + 'collab.polls.optionPlaceholder': 'Варіант {n}', + 'collab.polls.create': 'Створити опитування', + 'collab.polls.close': 'Закрити', + 'collab.polls.closed': 'Закрите', + 'collab.polls.votes': '{n} голосів', + 'collab.polls.vote': '{n} голос', + 'collab.polls.multipleChoice': 'Багатоваріантний вибір', + 'collab.polls.multiChoice': 'Багатоваріантний вибір', + 'collab.polls.deadline': 'Термін', + 'collab.polls.option': 'Варіант', + 'collab.polls.options': 'Варіанти', + 'collab.polls.delete': 'Видалити', + 'collab.polls.closedSection': 'Закриті', +}; +export default collab; diff --git a/shared/src/i18n/uk/common.ts b/shared/src/i18n/uk/common.ts new file mode 100644 index 0000000000000000000000000000000000000000..3b19358d862fa43a6061da30799ed4f4db64f6d3 --- /dev/null +++ b/shared/src/i18n/uk/common.ts @@ -0,0 +1,54 @@ +import type { TranslationStrings } from '../types'; + +const common: TranslationStrings = { + 'common.save': 'Зберегти', + 'common.showMore': 'Показати більше', + 'common.showLess': 'Показати менше', + 'common.cancel': 'Скасувати', + 'common.clear': 'Очистити', + 'common.delete': 'Видалити', + 'common.edit': 'Редагувати', + 'common.add': 'Додати', + 'common.loading': 'Завантаження...', + 'common.import': 'Імпорт', + 'common.select': 'Вибрати', + 'common.selectAll': 'Вибрати все', + 'common.deselectAll': 'Зняти виділення з усіх', + 'common.error': 'Помилка', + 'common.unknownError': 'Невідома помилка', + 'common.tooManyAttempts': 'Занадто багато спроб. Спробуйте пізніше.', + 'common.back': 'Назад', + 'common.all': 'Все', + 'common.close': 'Закрити', + 'common.open': 'Відкрити', + 'common.upload': 'Завантажити', + 'common.search': 'Пошук', + 'common.confirm': 'Підтвердити', + 'common.ok': 'ОК', + 'common.yes': 'Так', + 'common.no': 'Ні', + 'common.or': 'або', + 'common.none': 'Немає', + 'common.date': 'Дата', + 'common.rename': 'Перейменувати', + 'common.discardChanges': 'Скасувати зміни', + 'common.discard': 'Скасувати', + 'common.name': "Ім'я", + 'common.email': 'Ел. пошта', + 'common.password': 'Пароль', + 'common.saving': 'Збереження...', + 'common.saved': 'Збережено', + 'common.expand': 'Розгорнути', + 'common.collapse': 'Згорнути', + 'common.update': 'Оновити', + 'common.change': 'Змінити', + 'common.uploading': 'Завантаження…', + 'common.backToPlanning': 'Повернутися до планування', + 'common.reset': 'Скинути', + 'common.copy': 'Копіювати', + 'common.copied': 'Скопійовано', + 'common.justNow': 'щойно', + 'common.hoursAgo': '{count} год. тому', + 'common.daysAgo': '{count} дн. тому', +}; +export default common; diff --git a/shared/src/i18n/uk/dashboard.ts b/shared/src/i18n/uk/dashboard.ts new file mode 100644 index 0000000000000000000000000000000000000000..0060d66e10459614736c44651a26647b78b2ab82 --- /dev/null +++ b/shared/src/i18n/uk/dashboard.ts @@ -0,0 +1,169 @@ +import type { TranslationStrings } from '../types'; + +const dashboard: TranslationStrings = { + 'dashboard.title': 'Мої поїздки', + 'dashboard.subtitle.loading': 'Завантаження поїздок...', + 'dashboard.subtitle.trips': '{count} поїздок ({archived} в архіві)', + 'dashboard.subtitle.empty': 'Почніть свою першу поїздку', + 'dashboard.subtitle.activeOne': '{count} активна поїздка', + 'dashboard.subtitle.activeMany': '{count} активних поїздок', + 'dashboard.subtitle.archivedSuffix': ' · {count} в архіві', + 'dashboard.newTrip': 'Нова поїздка', + 'dashboard.newTripSub': 'Сплануйте нову поїздку з нуля', + 'dashboard.gridView': 'Плитка', + 'dashboard.listView': 'Список', + 'dashboard.currency': 'Валюта', + 'dashboard.timezone': 'Часові пояси', + 'dashboard.localTime': 'Місцеве', + 'dashboard.timezoneCustomTitle': 'Свій часовий пояс', + 'dashboard.timezoneCustomLabelPlaceholder': "Назва (необов'язково)", + 'dashboard.timezoneCustomTzPlaceholder': 'напр. America/New_York', + 'dashboard.timezoneCustomAdd': 'Додати', + 'dashboard.timezoneCustomErrorEmpty': 'Введіть ідентифікатор часового поясу', + 'dashboard.timezoneCustomErrorInvalid': + 'Невірний часовий пояс. Використовуйте формат Europe/Berlin', + 'dashboard.timezoneCustomErrorDuplicate': 'Вже додано', + 'dashboard.emptyTitle': 'Немає поїздок', + 'dashboard.emptyText': 'Створіть свою першу поїздку і почніть планувати!', + 'dashboard.emptyButton': 'Створити першу поїздку', + 'dashboard.nextTrip': 'Наступна поїздка', + 'dashboard.shared': 'Спільна', + 'dashboard.sharedBy': 'Поділився {name}', + 'dashboard.days': 'Дні', + 'dashboard.places': 'Місця', + 'dashboard.members': 'Попутники', + 'dashboard.archive': 'Архівувати', + 'dashboard.copyTrip': 'Копіювати', + 'dashboard.copySuffix': 'копія', + 'dashboard.restore': 'Відновити', + 'dashboard.archived': 'В архіві', + 'dashboard.status.ongoing': 'Триває', + 'dashboard.status.today': 'Сьогодні', + 'dashboard.status.tomorrow': 'Завтра', + 'dashboard.status.past': 'Минуло', + 'dashboard.status.daysLeft': 'залишилось {count} дн.', + 'dashboard.toast.loadError': 'Не вдалося завантажити поїздки', + 'dashboard.toast.created': 'Поїздка створена!', + 'dashboard.toast.createError': 'Не вдалося створити поїздку', + 'dashboard.toast.updated': 'Поїздка оновлена!', + 'dashboard.toast.updateError': 'Не вдалося оновити поїздку', + 'dashboard.toast.deleted': 'Поїздка видалена', + 'dashboard.toast.deleteError': 'Не вдалося видалити поїздку', + 'dashboard.toast.archived': 'Поїздка архівована', + 'dashboard.toast.archiveError': 'Не вдалося архівувати поїздку', + 'dashboard.toast.restored': 'Поїздка відновлена', + 'dashboard.toast.restoreError': 'Не вдалося відновити поїздку', + 'dashboard.toast.copied': 'Поїздка скопійована!', + 'dashboard.toast.copyError': 'Не вдалося скопіювати поїздку', + 'dashboard.confirm.copy.confirm': 'Скопіювати поїздку', + 'dashboard.confirm.copy.title': 'Скопіювати цю поїздку?', + 'dashboard.confirm.copy.will1': 'Дні, місця та призначення за днями', + 'dashboard.confirm.copy.will2': 'Проживання та бронювання', + 'dashboard.confirm.copy.will3': 'Статті бюджету та порядок категорій', + 'dashboard.confirm.copy.will4': 'Списки речей (непозначені)', + 'dashboard.confirm.copy.will5': 'Задачі (непризначені та непозначені)', + 'dashboard.confirm.copy.will6': 'Нотатки дня', + 'dashboard.confirm.copy.willCopy': 'Буде скопійовано', + 'dashboard.confirm.copy.wont1': 'Учасники та їх призначення', + 'dashboard.confirm.copy.wont2': 'Спільні нотатки, опитування та повідомлення', + 'dashboard.confirm.copy.wont3': 'Файли та фото', + 'dashboard.confirm.copy.wont4': 'Токени доступу', + 'dashboard.confirm.copy.wontCopy': 'Не буде скопійовано', + 'dashboard.confirm.delete': + 'Видалити поїздку «{title}»? Всі місця та плани будуть безповоротно видалені.', + 'dashboard.editTrip': 'Редагувати поїздку', + 'dashboard.createTrip': 'Створити нову поїздку', + 'dashboard.tripTitle': 'Назва', + 'dashboard.tripTitlePlaceholder': 'напр. Літо в Японії', + 'dashboard.tripDescription': 'Опис', + 'dashboard.tripDescriptionPlaceholder': 'Про що ця поїздка?', + 'dashboard.startDate': 'Дата початку', + 'dashboard.endDate': 'Дата закінчення', + 'dashboard.dayCount': 'Кількість днів', + 'dashboard.dayCountHint': + 'Скільки днів планувати, якщо дати поїздки не вказані.', + 'dashboard.noDateHint': + 'Дата не вказана — буде створено 7 днів за замовчуванням. Ви можете змінити це в будь-який час.', + 'dashboard.coverImage': 'Обкладинка', + 'dashboard.addCoverImage': 'Додати обкладинку', + 'dashboard.addMembers': 'Учасники', + 'dashboard.addMember': 'Додати учасника', + 'dashboard.coverSaved': 'Обкладинка збережена', + 'dashboard.coverUploadError': 'Помилка завантаження', + 'dashboard.coverRemoveError': 'Помилка видалення', + 'dashboard.titleRequired': "Назва обов'язкова", + 'dashboard.endDateError': 'Дата закінчення повинна бути пізніше дати початку', + 'dashboard.greeting.morning': 'Доброго ранку,', + 'dashboard.greeting.afternoon': 'Доброго дня,', + 'dashboard.greeting.evening': 'Доброго вечора,', + 'dashboard.mobile.liveNow': 'Зараз у дорозі', + 'dashboard.mobile.tripProgress': 'Прогрес поїздки', + 'dashboard.mobile.daysLeft': 'залишилось {count} дн.', + 'dashboard.mobile.places': 'Місця', + 'dashboard.mobile.buddies': 'Учасники', + 'dashboard.mobile.newTrip': 'Нова поїздка', + 'dashboard.mobile.currency': 'Валюта', + 'dashboard.mobile.timezone': 'Часовий пояс', + 'dashboard.mobile.upcomingTrips': 'Найближчі поїздки', + 'dashboard.mobile.yourTrips': 'Ваші поїздки', + 'dashboard.mobile.trips': 'поїздок', + 'dashboard.mobile.starts': 'Початок', + 'dashboard.mobile.duration': 'Тривалість', + 'dashboard.mobile.day': 'день', + 'dashboard.mobile.days': 'днів', + 'dashboard.mobile.ongoing': 'Триває', + 'dashboard.mobile.startsToday': 'Починається сьогодні', + 'dashboard.mobile.tomorrow': 'Завтра', + 'dashboard.mobile.inDays': 'Через {count} дн.', + 'dashboard.mobile.inMonths': 'Через {count} міс.', + 'dashboard.mobile.completed': 'Завершено', + 'dashboard.mobile.currencyConverter': 'Конвертер валют', + 'dashboard.filter.planned': 'Заплановані', + 'dashboard.hero.badgeLive': 'ЗАРАЗ У ДОРОЗІ', + 'dashboard.hero.badgeToday': 'ПОЧИНАЄТЬСЯ СЬОГОДНІ', + 'dashboard.hero.badgeTomorrow': 'ЗАВТРА', + 'dashboard.hero.badgeNext': 'ДАЛІ', + 'dashboard.hero.badgeRecent': 'НЕЩОДАВНО', + 'dashboard.hero.tripDates': 'Дати поїздки', + 'dashboard.hero.noDates': 'Дати не задано', + 'dashboard.hero.travelerOne': '{count} мандрівник', + 'dashboard.hero.travelerMany': '{count} мандрівників', + 'dashboard.hero.destinationOne': '{count} напрямок', + 'dashboard.hero.destinationMany': '{count} напрямків', + 'dashboard.hero.dayUnitOne': 'день', + 'dashboard.hero.dayUnitMany': 'дн.', + 'dashboard.hero.dayLeft': 'Залишився день', + 'dashboard.hero.daysLeft': 'Залишилось днів', + 'dashboard.hero.lastDay': 'Останній день', + 'dashboard.hero.untilStart': 'До початку', + 'dashboard.hero.startsIn': 'Старт через', + 'dashboard.atlas.countriesVisited': 'Атлас · Відвідані країни', + 'dashboard.atlas.ofTotal': 'з {total}', + 'dashboard.atlas.tripsTotal': 'Усього поїздок', + 'dashboard.atlas.placesMapped': '{count} місць на карті', + 'dashboard.atlas.daysTraveled': 'Днів у дорозі', + 'dashboard.atlas.daysUnit': 'дн.', + 'dashboard.atlas.acrossAllTrips': 'за всіма поїздками', + 'dashboard.atlas.distanceFlown': 'Подолана відстань', + 'dashboard.atlas.kmUnit': 'km', + 'dashboard.atlas.aroundEquator': '≈ {count}× навколо екватора', + 'dashboard.card.idea': 'Ідея', + 'dashboard.card.buddyOne': 'Супутник', + 'dashboard.fx.from': 'З', + 'dashboard.fx.to': 'У', + 'dashboard.fx.unavailable': 'Курс недоступний', + 'dashboard.tz.searchPlaceholder': 'Пошук часового поясу…', + 'dashboard.tz.empty': + 'Інших часових поясів поки немає — додайте за допомогою +', + 'dashboard.upcoming.title': 'Найближчі бронювання', + 'dashboard.upcoming.empty': 'Поки нічого не заброньовано.', + 'dashboard.aria.toggleView': 'Перемкнути вигляд', + 'dashboard.aria.filter': 'Фільтр', + 'dashboard.aria.duplicate': 'Дублювати', + 'dashboard.aria.refreshRates': 'Оновити курси', + 'dashboard.aria.swapCurrencies': 'Поміняти валюти', + 'dashboard.aria.addTimezone': 'Додати часовий пояс', + 'dashboard.aria.removeTimezone': 'Вилучити {city}', + 'dashboard.dayCountRequired': 'Вкажіть кількість днів', +}; +export default dashboard; diff --git a/shared/src/i18n/uk/day.ts b/shared/src/i18n/uk/day.ts new file mode 100644 index 0000000000000000000000000000000000000000..1353354652a63a487e879e0ba47d0e5803a2b69a --- /dev/null +++ b/shared/src/i18n/uk/day.ts @@ -0,0 +1,26 @@ +import type { TranslationStrings } from '../types'; + +const day: TranslationStrings = { + 'day.precipProb': 'Ймовірність опадів', + 'day.precipitation': 'Опади', + 'day.wind': 'Вітер', + 'day.sunrise': 'Схід', + 'day.sunset': 'Захід', + 'day.hourlyForecast': 'Погодний прогноз по годинах', + 'day.climateHint': + 'Історичні середні — реальний прогноз доступний за 16 днів до цієї дати.', + 'day.noWeather': 'Дані про погоду недоступні. Додайте місце з координатами.', + 'day.overview': 'Огляд дня', + 'day.accommodation': 'Проживання', + 'day.addAccommodation': 'Додати проживання', + 'day.hotelDayRange': 'Застосувати до днів', + 'day.noPlacesForHotel': 'Спочатку додайте місця до поїздки', + 'day.allDays': 'Усі', + 'day.checkIn': 'Заїзд', + 'day.checkInUntil': 'До', + 'day.checkOut': 'Виїзд', + 'day.confirmation': 'Підтвердження', + 'day.editAccommodation': 'Редагувати проживання', + 'day.reservations': 'Бронювання', +}; +export default day; diff --git a/shared/src/i18n/uk/dayplan.ts b/shared/src/i18n/uk/dayplan.ts new file mode 100644 index 0000000000000000000000000000000000000000..a57ff455b641ba236d422c8a06066fb4f0aede81 --- /dev/null +++ b/shared/src/i18n/uk/dayplan.ts @@ -0,0 +1,60 @@ +import type { TranslationStrings } from '../types'; + +const dayplan: TranslationStrings = { + 'dayplan.icsTooltip': 'Експорт календаря (ICS)', + 'dayplan.emptyDay': 'На цей день місць не заплановано', + 'dayplan.addNote': 'Додати нотатку', + 'dayplan.editNote': 'Редагувати нотатку', + 'dayplan.noteAdd': 'Додати нотатку', + 'dayplan.noteEdit': 'Редагувати нотатку', + 'dayplan.noteTitle': 'Нотатка', + 'dayplan.noteSubtitle': 'Нотатка на день', + 'dayplan.collapseAll': 'Згорнути всі дні', + 'dayplan.expandAll': 'Розгорнути всі дні', + 'dayplan.totalCost': 'Загальна вартість', + 'dayplan.days': 'Дни', + 'dayplan.dayN': 'День {n}', + 'dayplan.calculating': 'Розрахунок...', + 'dayplan.route': 'Маршрут', + 'dayplan.optimize': 'Оптимізувати', + 'dayplan.optimized': 'Маршрут оптимізовано', + 'dayplan.routeError': 'Не вдалося розрахувати маршрут', + 'dayplan.toast.needTwoPlaces': + 'Для оптимизации маршрута нужно минимум два места', + 'dayplan.toast.routeOptimized': 'Маршрут оптимизирован', + 'dayplan.toast.routeOptimizedFromHotel': 'Маршрут оптимізовано від вашого житла', + 'dayplan.toast.noGeoPlaces': + 'Не знайдено місць з координатами для розрахунку маршруту', + 'dayplan.confirmed': 'Подтверждено', + 'dayplan.pendingRes': 'Ожидание', + 'dayplan.pdf': 'PDF', + 'dayplan.pdfTooltip': 'Експортувати план дня в PDF', + 'dayplan.pdfError': 'Помилка експорту PDF', + 'dayplan.cannotReorderTransport': + 'Бронювання з фіксованим часом не можна переміщувати', + 'dayplan.confirmRemoveTimeTitle': 'Видалити час?', + 'dayplan.confirmRemoveTimeBody': + 'У цього місця фіксований час ({time}). При переміщенні час буде видалено, і стане доступне вільне сортування.', + 'dayplan.confirmRemoveTimeAction': 'Видалити час і перемістити', + 'dayplan.confirmDeleteNoteTitle': 'Видалити нотатку?', + 'dayplan.confirmDeleteNoteBody': 'Цю нотатку буде видалено назавжди.', + 'dayplan.cannotDropOnTimed': + 'Елементи не можна розміщувати між записами з фіксованим часом', + 'dayplan.cannotBreakChronology': + 'Це порушить хронологічний порядок запланованих елементів і бронювань', + 'dayplan.mobile.addPlace': 'Додати місце', + 'dayplan.mobile.searchPlaces': 'Пошук місць...', + 'dayplan.mobile.allAssigned': 'Усі місця розподілені', + 'dayplan.mobile.noMatch': 'Немає збігів', + 'dayplan.mobile.createNew': 'Створити нове місце', + 'dayplan.reorderDays': 'Змінити порядок днів', + 'dayplan.reorderTitle': 'Змінити порядок днів', + 'dayplan.reorderHint': 'Місця, нотатки та бронювання дня переміщуються разом із ним.', + 'dayplan.addDay': 'Додати день', + 'dayplan.moveUp': 'Перемістити вгору', + 'dayplan.moveDown': 'Перемістити вниз', + 'dayplan.reorderUndo': 'Змінити порядок днів', + 'dayplan.reorderError': 'Не вдалося змінити порядок днів', + 'dayplan.addDayError': 'Не вдалося додати день', +}; +export default dayplan; diff --git a/shared/src/i18n/uk/externalNotifications.ts b/shared/src/i18n/uk/externalNotifications.ts new file mode 100644 index 0000000000000000000000000000000000000000..50d2b8e38fa6527133c2d7acd70ca496fff472b0 --- /dev/null +++ b/shared/src/i18n/uk/externalNotifications.ts @@ -0,0 +1,63 @@ +import type { NotificationLocale } from '../externalNotifications/types'; + +const uk: NotificationLocale = { + email: { + footer: 'Ви отримали це, оскільки увімкнули сповіщення в TREK.', + manage: 'Керувати налаштуваннями у Налаштуваннях', + madeWith: 'Made with', + openTrek: 'Відкрити TREK', + }, + events: { + trip_invite: (p) => ({ + title: `Запрошення до "${p.trip}"`, + body: `${p.actor} запросив ${p.invitee || 'учасника'} до подорожі "${p.trip}".`, + }), + booking_change: (p) => ({ + title: `Нове бронювання: ${p.booking}`, + body: `${p.actor} додав бронювання "${p.booking}" (${p.type}) до "${p.trip}".`, + }), + trip_reminder: (p) => ({ + title: `Нагадування про подорож: ${p.trip}`, + body: `Ваша подорож "${p.trip}" наближається!`, + }), + todo_due: (p) => ({ + title: `Завдання з терміном: ${p.todo}`, + body: `"${p.todo}" у "${p.trip}" — термін ${p.due}.`, + }), + vacay_invite: (p) => ({ + title: 'Запрошення Vacay Fusion', + body: `${p.actor} запрошує вас об'єднати плани відпустки. Відкрийте TREK, щоб прийняти або відхилити.`, + }), + photos_shared: (p) => ({ + title: `${p.count} фото поділились`, + body: `${p.actor} поділився ${p.count} фото у "${p.trip}".`, + }), + collab_message: (p) => ({ + title: `Нове повідомлення у "${p.trip}"`, + body: `${p.actor}: ${p.preview}`, + }), + packing_tagged: (p) => ({ + title: `Пакування: ${p.category}`, + body: `${p.actor} призначив вас до категорії "${p.category}" у "${p.trip}".`, + }), + version_available: (p) => ({ + title: 'Доступна нова версія TREK', + body: `TREK ${p.version} тепер доступний. Перейдіть до панелі адміністратора для оновлення.`, + }), + synology_session_cleared: () => ({ + title: 'Сеанс Synology скинуто', + body: 'Ваш обліковий запис або URL Synology змінився. Ви вийшли з Synology Photos.', + }), + }, + passwordReset: { + subject: 'Скидання пароля', + greeting: 'Привіт', + body: 'Ми отримали запит на скидання пароля вашого облікового запису TREK. Натисніть кнопку нижче, щоб встановити новий пароль.', + ctaIntro: 'Скинути пароль', + expiry: 'Це посилання дійсне протягом 60 хвилин.', + ignore: + 'Якщо ви не надсилали цей запит, просто проігноруйте цей лист — ваш пароль залишиться незмінним.', + }, +}; + +export default uk; diff --git a/shared/src/i18n/uk/files.ts b/shared/src/i18n/uk/files.ts new file mode 100644 index 0000000000000000000000000000000000000000..7d04fd9f66f6b90b7028d18d1c35e32f7361d513 --- /dev/null +++ b/shared/src/i18n/uk/files.ts @@ -0,0 +1,62 @@ +import type { TranslationStrings } from '../types'; + +const files: TranslationStrings = { + 'files.title': 'Файли', + 'files.pageTitle': 'Файли та документи', + 'files.subtitle': '{count} файлів для {trip}', + 'files.download': 'Завантажити', + 'files.openError': 'Не вдалося відкрити файл', + 'files.downloadPdf': 'Завантажити PDF', + 'files.count': '{count} файлів', + 'files.countSingular': '1 файл', + 'files.uploaded': '{count} завантажено', + 'files.uploadError': 'Помилка завантаження', + 'files.dropzone': 'Перетягніть файли сюди', + 'files.dropzoneHint': 'або натисніть для вибору', + 'files.allowedTypes': + 'Зображення, PDF, DOC, DOCX, XLS, XLSX, TXT, CSV · Макс. 50 МБ', + 'files.uploading': 'Завантаження...', + 'files.filterAll': 'Усі', + 'files.filterPdf': 'PDF', + 'files.filterImages': 'Зображення', + 'files.filterDocs': 'Документи', + 'files.filterCollab': 'Нотатки Collab', + 'files.sourceCollab': 'З нотаток Collab', + 'files.empty': 'Файлів поки немає', + 'files.emptyHint': 'Завантажте файли, щоб прикріпити їх до поїздки', + 'files.openTab': 'Відкрити в новій вкладці', + 'files.confirm.delete': 'Ви впевнені, що хочете видалити цей файл?', + 'files.toast.deleted': 'Файл видалено', + 'files.toast.deleteError': 'Не вдалося видалити файл', + 'files.sourcePlan': 'План дня', + 'files.sourceBooking': 'Бронювання', + 'files.attach': 'Прикріпити', + 'files.pasteHint': 'Також можна вставити зображення з буфера обміну (Ctrl+V)', + 'files.trash': 'Кошик', + 'files.trashEmpty': 'Кошик порожній', + 'files.emptyTrash': 'Очистити кошик', + 'files.restore': 'Відновити', + 'files.star': 'У фаворити', + 'files.unstar': 'Зняти з фаворитів', + 'files.assign': 'Призначити', + 'files.assignTitle': 'Призначити файл', + 'files.assignPlace': 'Місце', + 'files.assignBooking': 'Бронювання', + 'files.unassigned': 'Не призначено', + 'files.unlink': 'Видалити зв’язок', + 'files.toast.trashed': 'Переміщено до кошика', + 'files.toast.restored': 'Файл відновлено', + 'files.toast.trashEmptied': 'Кошик очищено', + 'files.toast.assigned': 'Файл призначено', + 'files.toast.assignError': 'Помилка призначення', + 'files.toast.restoreError': 'Помилка відновлення', + 'files.confirm.permanentDelete': + 'Безповоротно видалити цей файл? Цю дію неможливо скасувати.', + 'files.confirm.emptyTrash': + 'Безповоротно видалити всі файли з кошика? Цю дію неможливо скасувати.', + 'files.noteLabel': 'Нотатка', + 'files.notePlaceholder': 'Додати нотатку...', + 'files.assignTransport': 'Транспорт', + 'files.sourceTransport': 'Транспорт', +}; +export default files; diff --git a/shared/src/i18n/uk/index.ts b/shared/src/i18n/uk/index.ts new file mode 100644 index 0000000000000000000000000000000000000000..77aeb6a09fb62e2522e8b4c04e4169a94c2f8d99 --- /dev/null +++ b/shared/src/i18n/uk/index.ts @@ -0,0 +1,86 @@ +import admin from './admin'; +import airport from './airport'; +import atlas from './atlas'; +import backup from './backup'; +import budget from './budget'; +import categories from './categories'; +import collab from './collab'; +import common from './common'; +import dashboard from './dashboard'; +import day from './day'; +import dayplan from './dayplan'; +import files from './files'; +import inspector from './inspector'; +import journey from './journey'; +import login from './login'; +import map from './map'; +import members from './members'; +import memories from './memories'; +import nav from './nav'; +import notif from './notif'; +import notifications from './notifications'; +import oauth from './oauth'; +import packing from './packing'; +import pdf from './pdf'; +import perm from './perm'; +import photos from './photos'; +import places from './places'; +import planner from './planner'; +import register from './register'; +import reservations from './reservations'; +import settings from './settings'; +import share from './share'; +import shared from './shared'; +import stats from './stats'; +import system_notice from './system_notice'; +import todo from './todo'; +import transport from './transport'; +import trip from './trip'; +import trips from './trips'; +import undo from './undo'; +import vacay from './vacay'; + +const locale = { + ...common, + ...trips, + ...nav, + ...dashboard, + ...settings, + ...admin, + ...dayplan, + ...share, + ...shared, + ...login, + ...register, + ...vacay, + ...atlas, + ...trip, + ...places, + ...inspector, + ...reservations, + ...airport, + ...map, + ...budget, + ...files, + ...packing, + ...members, + ...categories, + ...backup, + ...photos, + ...pdf, + ...planner, + ...stats, + ...day, + ...memories, + ...collab, + ...perm, + ...undo, + ...notifications, + ...todo, + ...notif, + ...journey, + ...oauth, + ...system_notice, + ...transport, +}; +export default locale; diff --git a/shared/src/i18n/uk/inspector.ts b/shared/src/i18n/uk/inspector.ts new file mode 100644 index 0000000000000000000000000000000000000000..ff0ef9d7b7f897ec601ed435ef2c20afd056858a --- /dev/null +++ b/shared/src/i18n/uk/inspector.ts @@ -0,0 +1,22 @@ +import type { TranslationStrings } from '../types'; + +const inspector: TranslationStrings = { + 'inspector.opened': 'Відкрито', + 'inspector.closed': 'Закрито', + 'inspector.openingHours': 'Години роботи', + 'inspector.showHours': 'Показати години роботи', + 'inspector.files': 'Файли', + 'inspector.filesCount': '{count} файлів', + 'inspector.removeFromDay': 'Прибрати з дня', + 'inspector.remove': 'Видалити', + 'inspector.addToDay': 'Додати до дня', + 'inspector.confirmedRes': 'Підтверджене бронювання', + 'inspector.pendingRes': 'Очікуване бронювання', + 'inspector.google': 'Відкрити в Google Maps', + 'inspector.website': 'Відкрити сайт', + 'inspector.addRes': 'Бронювання', + 'inspector.editRes': 'Редагувати бронювання', + 'inspector.participants': 'Учасники', + 'inspector.trackStats': 'Дані маршруту', +}; +export default inspector; diff --git a/shared/src/i18n/uk/journey.ts b/shared/src/i18n/uk/journey.ts new file mode 100644 index 0000000000000000000000000000000000000000..161533e34073a07169461ffb172e3791a5b7c83f --- /dev/null +++ b/shared/src/i18n/uk/journey.ts @@ -0,0 +1,245 @@ +import type { TranslationStrings } from '../types'; + +const journey: TranslationStrings = { + 'journey.search.placeholder': 'Пошук подорожей…', + 'journey.search.noResults': 'Подорожей за запитом «{query}» не знайдено', + 'journey.title': 'Journey', + 'journey.subtitle': 'Відстежуйте свої подорожі в реальному часі', + 'journey.new': 'Нова подорож', + 'journey.create': 'Створити', + 'journey.titlePlaceholder': 'Куди ви їдете?', + 'journey.empty': 'Поки що немає подорожей', + 'journey.emptyHint': 'Почніть документувати свою наступну поїздку', + 'journey.deleted': 'Подорож видалено', + 'journey.createError': 'Не вдалося створити подорож', + 'journey.deleteError': 'Не вдалося видалити подорож', + 'journey.deleteConfirmTitle': 'Видалити', + 'journey.deleteConfirmMessage': + 'Видалити «{title}»? Цю дію не можна скасувати.', + 'journey.deleteConfirmGeneric': 'Ви впевнені, що хочете це видалити?', + 'journey.notFound': 'Подорож не знайдено', + 'journey.photos': 'Фото', + 'journey.timelineEmpty': 'Поки що немає зупинок', + 'journey.timelineEmptyHint': 'Додайте позначку або напишіть запис у щоденник', + 'journey.status.draft': 'Чернетка', + 'journey.status.active': 'Активно', + 'journey.status.completed': 'Завершено', + 'journey.status.upcoming': 'Найближчим часом', + 'journey.status.archived': 'В архіві', + 'journey.checkin.add': 'Відзначитись', + 'journey.checkin.namePlaceholder': 'Назва місця', + 'journey.checkin.notesPlaceholder': 'Нотатки (необов’язково)', + 'journey.checkin.save': 'Зберегти', + 'journey.checkin.error': 'Не вдалося зберегти позначку', + 'journey.entry.add': 'Щоденник', + 'journey.entry.edit': 'Редагувати запис', + 'journey.entry.titlePlaceholder': 'Заголовок (необов’язково)', + 'journey.entry.bodyPlaceholder': 'Що сталося сьогодні?', + 'journey.entry.save': 'Зберегти', + 'journey.entry.error': 'Не вдалося зберегти запис', + 'journey.photo.add': 'Фото', + 'journey.photo.uploadError': 'Завантаження не вдалося', + 'journey.share.share': 'Поділитися', + 'journey.share.public': 'Публічний', + 'journey.share.linkCopied': 'Публічне посилання скопійовано', + 'journey.share.disabled': 'Публічний доступ вимкнено', + 'journey.editor.titlePlaceholder': 'Дайте назву цьому моменту...', + 'journey.editor.bodyPlaceholder': 'Розкажіть історію цього дня...', + 'journey.editor.placePlaceholder': 'Місце розташування (необов’язково)', + 'journey.editor.tagsPlaceholder': + 'Теги: прихована перлина, найкраща їжа, варто повернутися...', + 'journey.visibility.private': 'Приватний', + 'journey.visibility.shared': 'Спільний', + 'journey.visibility.public': 'Публічний', + 'journey.emptyState.title': 'Ваша історія починається тут', + 'journey.emptyState.subtitle': + 'Позначтесь у місці або напишіть перший запис у щоденник', + 'journey.frontpage.subtitle': + 'Перетворюйте поїздки на історії, які ви ніколи не забудете', + 'journey.frontpage.createJourney': 'Створити подорож', + 'journey.frontpage.activeJourney': 'Активна подорож', + 'journey.frontpage.allJourneys': 'Усі подорожі', + 'journey.frontpage.journeys': 'подорожей', + 'journey.frontpage.createNew': 'Створити нову подорож', + 'journey.frontpage.createNewSub': + 'Оберіть поїздки, пишіть історії, діліться пригодами', + 'journey.frontpage.live': 'В ефірі', + 'journey.frontpage.synced': 'Синхронізовано', + 'journey.frontpage.continueWriting': 'Продовжити писати', + 'journey.frontpage.updated': 'Оновлено {time}', + 'journey.frontpage.suggestionLabel': 'Поїздка щойно завершилась', + 'journey.frontpage.suggestionText': + 'Перетворіть {title} на подорож', + 'journey.frontpage.dismiss': 'Приховати', + 'journey.frontpage.journeyName': 'Назва подорожі', + 'journey.frontpage.namePlaceholder': 'наприклад, Південно-Східна Азія 2026', + 'journey.frontpage.selectTrips': 'Оберіть поїздки', + 'journey.frontpage.tripsSelected': 'поїздок вибрано', + 'journey.frontpage.trips': 'поїздок', + 'journey.frontpage.placesImported': 'місць буде імпортовано', + 'journey.frontpage.places': 'місць', + 'journey.detail.backToJourney': 'Назад до подорожі', + 'journey.detail.syncedWithTrips': 'Синхронізовано з поїздками', + 'journey.detail.addEntry': 'Додати запис', + 'journey.detail.newEntry': 'Новий запис', + 'journey.detail.editEntry': 'Редагувати запис', + 'journey.detail.noEntries': 'Поки що немає записів', + 'journey.detail.noEntriesHint': + 'Додайте подорож, щоб почати зі шаблонних записів', + 'journey.detail.noPhotos': 'Поки що немає фото', + 'journey.detail.noPhotosHint': + 'Завантажте фото до записів або перегляньте бібліотеку Immich/Synology', + 'journey.detail.journeyStats': 'Статистика подорожі', + 'journey.detail.syncedTrips': 'Синхронізовані поїздки', + 'journey.detail.noTripsLinked': 'Поки що немає прив’язаних поїздок', + 'journey.detail.contributors': 'Учасники', + 'journey.detail.journeyTab': 'Journey', + 'journey.detail.readMore': 'Читати далі', + 'journey.detail.prosCons': 'Плюси й мінуси', + 'journey.detail.photos': 'фото', + 'journey.detail.day': 'День {number}', + 'journey.detail.places': 'місць', + 'journey.stats.days': 'Днів', + 'journey.stats.cities': 'Міст', + 'journey.stats.entries': 'Записів', + 'journey.stats.photos': 'Фото', + 'journey.stats.places': 'Місць', + 'journey.skeletons.show': 'Показати пропозиції', + 'journey.skeletons.hide': 'Приховати пропозиції', + 'journey.verdict.lovedIt': 'Сподобалось', + 'journey.verdict.couldBeBetter': 'Могло бути краще', + 'journey.synced.places': 'місць', + 'journey.synced.synced': 'синхронізовано', + 'journey.editor.discardChangesConfirm': + 'У вас є незбережені зміни. Відмінити?', + 'journey.editor.uploadPhotos': 'Завантажити фото', + 'journey.editor.uploading': 'Завантаження...', + 'journey.editor.fromGallery': 'Зі галереї', + 'journey.editor.allPhotosAdded': 'Усі фото вже додано', + 'journey.editor.writeStory': 'Напишіть свою історію...', + 'journey.editor.prosCons': 'Плюси й мінуси', + 'journey.editor.pros': 'Плюси', + 'journey.editor.cons': 'Мінуси', + 'journey.editor.proPlaceholder': 'Щось чудове...', + 'journey.editor.conPlaceholder': 'Не дуже добре...', + 'journey.editor.addAnother': 'Додати ще', + 'journey.editor.date': 'Дата', + 'journey.editor.location': 'Місце розташування', + 'journey.editor.searchLocation': 'Пошук місця розташування...', + 'journey.editor.mood': 'Настрій', + 'journey.editor.weather': 'Погода', + 'journey.editor.photoFirst': '1-е', + 'journey.editor.makeFirst': 'Зробити першим', + 'journey.editor.searching': 'Пошук...', + 'journey.mood.amazing': 'Неймовірно', + 'journey.mood.good': 'Добре', + 'journey.mood.neutral': 'Нейтрально', + 'journey.mood.rough': 'Важко', + 'journey.weather.sunny': 'Сонячно', + 'journey.weather.partly': 'Перемінна хмарність', + 'journey.weather.cloudy': 'Хмарно', + 'journey.weather.rainy': 'Дощ', + 'journey.weather.stormy': 'Гроза', + 'journey.weather.cold': 'Сніжно', + 'journey.trips.linkTrip': 'Прив’язати поїздку', + 'journey.trips.searchTrip': 'Пошук поїздки', + 'journey.trips.searchPlaceholder': 'Назва поїздки або напрям...', + 'journey.trips.noTripsAvailable': 'Немає доступних поїздок', + 'journey.trips.link': 'Прив’язати', + 'journey.trips.tripLinked': 'Поїздка прив’язана', + 'journey.trips.linkFailed': 'Не вдалося прив’язати поїздку', + 'journey.trips.addTrip': 'Додати поїздку', + 'journey.trips.unlinkTrip': 'Відв’язати поїздку', + 'journey.trips.unlinkMessage': + 'Відв’язати «{title}»? Усі синхронізовані записи та фото з цієї поїздки будуть безповоротно видалені. Цю дію не можна скасувати.', + 'journey.trips.unlink': 'Відв’язати', + 'journey.trips.tripUnlinked': 'Поїздка відв’язана', + 'journey.trips.unlinkFailed': 'Не вдалося відв’язати поїздку', + 'journey.trips.noTripsLinkedSettings': 'Немає прив’язаних поїздок', + 'journey.contributors.invite': 'Запросити учасника', + 'journey.contributors.searchUser': 'Пошук користувача', + 'journey.contributors.searchPlaceholder': 'Ім’я користувача або email...', + 'journey.contributors.noUsers': 'Користувачів не знайдено', + 'journey.contributors.role': 'Роль', + 'journey.contributors.added': 'Учасника додано', + 'journey.contributors.addFailed': 'Не вдалося додати учасника', + 'journey.contributors.remove': 'Вилучити учасника', + 'journey.contributors.removeConfirm': 'Вилучити {username} з цієї подорожі?', + 'journey.contributors.removeFailed': 'Не вдалося вилучити учасника', + 'journey.contributors.removed': 'Учасника вилучено', + 'journey.share.publicShare': 'Публічний доступ', + 'journey.share.createLink': 'Створити посилання для спільного доступу', + 'journey.share.linkCreated': 'Посилання створено', + 'journey.share.createFailed': 'Не вдалося створити посилання', + 'journey.share.copy': 'Копіювати', + 'journey.share.copied': 'Скопійовано!', + 'journey.share.timeline': 'Хронологія', + 'journey.share.gallery': 'Галерея', + 'journey.share.map': 'Карта', + 'journey.share.removeLink': 'Видалити посилання', + 'journey.share.linkDeleted': 'Посилання видалено', + 'journey.share.deleteFailed': 'Не вдалося видалити', + 'journey.share.updateFailed': 'Не вдалося оновити', + 'journey.invite.role': 'Роль', + 'journey.invite.viewer': 'Спостерігач', + 'journey.invite.editor': 'Редактор', + 'journey.invite.invite': 'Запросити', + 'journey.invite.inviting': 'Запрошуємо...', + 'journey.settings.title': 'Налаштування подорожі', + 'journey.settings.coverImage': 'Обкладинка', + 'journey.settings.changeCover': 'Змінити обкладинку', + 'journey.settings.addCover': 'Додати обкладинку', + 'journey.settings.name': 'Назва', + 'journey.settings.subtitle': 'Підзаголовок', + 'journey.settings.subtitlePlaceholder': + 'наприклад Таїланд, В’єтнам і Камбоджа', + 'journey.settings.endJourney': 'Архівувати подорож', + 'journey.settings.reopenJourney': 'Відновити подорож', + 'journey.settings.archived': 'Подорож архівовано', + 'journey.settings.reopened': 'Подорож відновлено', + 'journey.settings.endDescription': + 'Приховує значок «В ефірі». Ви можете відновити у будь-який час.', + 'journey.settings.delete': 'Видалити', + 'journey.settings.deleteJourney': 'Видалити подорож', + 'journey.settings.deleteMessage': + 'Видалити «{title}»? Усі записи та фото будуть втрачені.', + 'journey.settings.saved': 'Налаштування збережено', + 'journey.settings.saveFailed': 'Не вдалося зберегти', + 'journey.settings.coverUpdated': 'Обкладинка оновлено', + 'journey.settings.coverFailed': 'Завантаження не вдалося', + 'journey.settings.failedToDelete': 'Не вдалося видалити', + 'journey.entries.deleteTitle': 'Видалити запис', + 'journey.photosUploaded': '{count} фото завантажено', + 'journey.photosAdded': '{count} фото додано', + 'journey.public.notFound': 'Не знайдено', + 'journey.public.notFoundMessage': + 'Ця подорож не існує або посилання застаріло.', + 'journey.public.readOnly': 'Тільки для читання · Публічна подорож', + 'journey.public.tagline': 'Інструмент планування та дослідження подорожей', + 'journey.public.sharedVia': 'Опубліковано через', + 'journey.public.madeWith': 'Зроблено з допомогою', + 'journey.pdf.journeyBook': 'Книга подорожі', + 'journey.pdf.madeWith': 'Зроблено з допомогою TREK', + 'journey.pdf.day': 'День', + 'journey.pdf.theEnd': 'Кінець', + 'journey.pdf.saveAsPdf': 'Зберегти як PDF', + 'journey.pdf.pages': 'сторінок', + 'journey.picker.tripPeriod': 'Період подорожі', + 'journey.picker.dateRange': 'Діапазон дат', + 'journey.picker.allPhotos': 'Усі фото', + 'journey.picker.albums': 'Альбоми', + 'journey.picker.selected': 'вибрано', + 'journey.picker.addTo': 'Додати до', + 'journey.picker.newGallery': 'Нова галерея', + 'journey.picker.selectAll': 'Вибрати все', + 'journey.picker.deselectAll': 'Скасувати вибір', + 'journey.picker.noAlbums': 'Альбомів не знайдено', + 'journey.picker.selectDate': 'Оберіть дату', + 'journey.picker.search': 'Пошук', + 'journey.editor.uploadingProgress': 'Завантаження {done}/{total}…', + 'journey.editor.uploadFailed': 'Не вдалося завантажити фото', + 'journey.editor.uploadPartialFailed': + '{failed} з {total} фото не вдалося завантажити — збережіть ще раз, щоб повторити', + 'journey.photosUploadFailed': 'Деякі фото не вдалося завантажити', +}; +export default journey; diff --git a/shared/src/i18n/uk/login.ts b/shared/src/i18n/uk/login.ts new file mode 100644 index 0000000000000000000000000000000000000000..75cdbb45717548f3e7ded18d072bfed49a0cb9fc --- /dev/null +++ b/shared/src/i18n/uk/login.ts @@ -0,0 +1,101 @@ +import type { TranslationStrings } from '../types'; + +const login: TranslationStrings = { + 'login.error': 'Помилка входу. Перевірте свої облікові дані.', + 'login.tagline': 'Ваші поїздки.\nВаш план.', + 'login.description': + 'Плануйте поїздки разом з інтерактивними картами, бюджетами та синхронізацією в реальному часі.', + 'login.features.maps': 'Інтерактивні карти', + 'login.features.mapsDesc': 'Google Places, маршрути та кластеризація', + 'login.features.realtime': 'Синхронізація в реальному часі', + 'login.features.realtimeDesc': 'Плануйте разом через WebSocket', + 'login.features.budget': 'Контроль бюджету', + 'login.features.budgetDesc': 'Категорії, графіки та витрати на особу', + 'login.features.collab': 'Спільна робота', + 'login.features.collabDesc': + 'Багатокористувацький режим зі спільними поїздками', + 'login.features.packing': 'Списки речей', + 'login.features.packingDesc': 'Категорії, прогрес та підказки', + 'login.features.bookings': 'Бронювання', + 'login.features.bookingsDesc': + 'Авіаквитки, готелі, ресторани та багато іншого', + 'login.features.files': 'Документи', + 'login.features.filesDesc': 'Завантажуйте та керуйте документами', + 'login.features.routes': 'Розумні маршрути', + 'login.features.routesDesc': 'Автооптимізація та експорт з Google Maps', + 'login.selfHosted': + 'Self-hosted · Відкритий код · Ваші дані залишаються у вас', + 'login.title': 'Вхід', + 'login.subtitle': 'З поверненням', + 'login.signingIn': 'Вхід…', + 'login.signIn': 'Увійти', + 'login.createAdmin': 'Створити акаунт адміністратора', + 'login.createAdminHint': 'Налаштуйте перший акаунт адміністратора для TREK.', + 'login.setNewPassword': 'Встановити новий пароль', + 'login.setNewPasswordHint': 'Ви повинні змінити пароль, перш ніж продовжити.', + 'login.createAccount': 'Створити акаунт', + 'login.createAccountHint': 'Зареєструйте новий акаунт.', + 'login.creating': 'Створення…', + 'login.noAccount': 'Немає акаунту?', + 'login.hasAccount': 'Вже є акаунт?', + 'login.register': 'Реєстрація', + 'login.emailPlaceholder': 'ваш@email.com', + 'login.username': 'Ім’я користувача', + 'login.oidc.registrationDisabled': + 'Реєстрацію вимкнено. Зверніться до адміністратора.', + 'login.oidc.noEmail': 'Провайдер не надав адресу електронної пошти.', + 'login.mfaTitle': 'Двофакторна автентифікація', + 'login.mfaSubtitle': 'Введіть 6-значний код з додатка-автентифікатора.', + 'login.mfaCodeLabel': 'Код підтвердження', + 'login.mfaCodeRequired': 'Введіть код із додатка-автентифікатора.', + 'login.mfaHint': + 'Відкрийте Google Authenticator, Authy або інший TOTP-додаток.', + 'login.mfaBack': '← Назад до входу', + 'login.mfaVerify': 'Підтвердити', + 'login.invalidInviteLink': 'Недійсне або прострочене посилання-запрошення', + 'login.oidcFailed': 'Помилка входу через OIDC', + 'login.usernameRequired': 'Ім’я користувача обов’язкове', + 'login.passwordMinLength': 'Пароль має містити щонайменше 8 символів', + 'login.forgotPassword': 'Забули пароль?', + 'login.rememberMe': "Запам'ятати мене", + 'login.forgotPasswordTitle': 'Скидання пароля', + 'login.forgotPasswordBody': + 'Введіть електронну пошту, з якою ви реєструвалися. Якщо акаунт існує — буде надіслано посилання для скидання.', + 'login.forgotPasswordSubmit': 'Надіслати посилання', + 'login.forgotPasswordSentTitle': 'Перевірте пошту', + 'login.forgotPasswordSentBody': + 'Якщо акаунт існує, посилання для скидання має бути вже відправлено. Воно дійсне 60 хвилин.', + 'login.forgotPasswordSmtpHintOff': + 'Зверніть увагу: адміністратор не налаштував SMTP, тому посилання для скидання буде записано в консоль сервера замість відправки електронною поштою.', + 'login.backToLogin': 'Повернутись до входу', + 'login.newPassword': 'Новий пароль', + 'login.confirmPassword': 'Підтвердіть новий пароль', + 'login.passwordsDontMatch': 'Паролі не співпадають', + 'login.mfaCode': 'Код 2FA', + 'login.resetPasswordTitle': 'Встановіть новий пароль', + 'login.resetPasswordBody': + 'Виберіть надійний пароль, який ви ще не використовували. Мінімум 8 символів.', + 'login.resetPasswordMfaBody': + 'Введіть код 2FA або резервний код, щоб завершити скидання.', + 'login.resetPasswordSubmit': 'Скинути пароль', + 'login.resetPasswordVerify': 'Перевірити та скинути', + 'login.resetPasswordSuccessTitle': 'Пароль оновлено', + 'login.resetPasswordSuccessBody': 'Тепер ви можете увійти з новим паролем.', + 'login.resetPasswordInvalidLink': 'Неправильне посилання для скидання', + 'login.resetPasswordInvalidLinkBody': + 'Посилання відсутнє або пошкоджене. Запитайте нове, щоб продовжити.', + 'login.resetPasswordFailed': + 'Скидання не вдалося. Можливо, термін дії посилання минув.', + 'login.oidc.tokenFailed': 'Автентифікація не вдалася.', + 'login.oidc.invalidState': 'Недійсна сесія. Спробуйте знову.', + 'login.demoFailed': 'Помилка демо-входу', + 'login.oidcSignIn': 'Увійти через {name}', + 'login.oidcOnly': + 'Вхід за паролем вимкнено. Використайте вашого SSO-провайдера для входу.', + 'login.oidcLoggedOut': + 'Ви вийшли з системи. Увійдіть знову через вашого SSO-провайдера.', + 'login.demoHint': 'Спробуйте демо — реєстрація не потрібна', + 'login.passkey.signIn': 'Увійти за допомогою passkey', + 'login.passkey.failed': 'Не вдалося увійти за допомогою passkey. Спробуйте ще раз.', +}; +export default login; diff --git a/shared/src/i18n/uk/map.ts b/shared/src/i18n/uk/map.ts new file mode 100644 index 0000000000000000000000000000000000000000..894bebe931f55fc199d805e265234c7a4dbf3904 --- /dev/null +++ b/shared/src/i18n/uk/map.ts @@ -0,0 +1,17 @@ +import type { TranslationStrings } from '../types'; + +const map: TranslationStrings = { + 'map.connections': 'Сполучення', + 'map.showConnections': 'Показати маршрути бронювань', + 'map.hideConnections': 'Приховати маршрути бронювань', + 'poi.searchThisArea': 'Шукати в цій області', + 'poi.cat.restaurants': 'Ресторани', + 'poi.cat.cafes': 'Кафе', + 'poi.cat.bars': 'Бари та нічне життя', + 'poi.cat.hotels': 'Житло', + 'poi.cat.sights': 'Визначні місця', + 'poi.cat.museums': 'Музеї та культура', + 'poi.cat.nature': 'Природа та парки', + 'poi.cat.activities': 'Активності', +}; +export default map; diff --git a/shared/src/i18n/uk/members.ts b/shared/src/i18n/uk/members.ts new file mode 100644 index 0000000000000000000000000000000000000000..ac28a9fa04513ee010f669bb504be6d2f9c05a1f --- /dev/null +++ b/shared/src/i18n/uk/members.ts @@ -0,0 +1,24 @@ +import type { TranslationStrings } from '../types'; + +const members: TranslationStrings = { + 'members.shareTrip': 'Поділитися поїздкою', + 'members.inviteUser': 'Запросити користувача', + 'members.selectUser': 'Оберіть користувача…', + 'members.invite': 'Запросити', + 'members.allHaveAccess': 'У всіх користувачів вже є доступ.', + 'members.access': 'Доступ', + 'members.person': 'особа', + 'members.persons': 'осіб', + 'members.you': 'ви', + 'members.owner': 'Власник', + 'members.leaveTrip': 'Покинути поїздку', + 'members.removeAccess': 'Відкликати доступ', + 'members.confirmLeave': 'Покинути поїздку? Ви втратите доступ.', + 'members.confirmRemove': 'Відкликати доступ у цього користувача?', + 'members.loadError': 'Не вдалося завантажити учасників', + 'members.added': 'додано', + 'members.addError': 'Помилка додавання', + 'members.removed': 'Учасник видалений', + 'members.removeError': 'Помилка видалення', +}; +export default members; diff --git a/shared/src/i18n/uk/memories.ts b/shared/src/i18n/uk/memories.ts new file mode 100644 index 0000000000000000000000000000000000000000..40f50b436b65058c777f8de7e9575ccea2311b00 --- /dev/null +++ b/shared/src/i18n/uk/memories.ts @@ -0,0 +1,81 @@ +import type { TranslationStrings } from '../types'; + +const memories: TranslationStrings = { + 'memories.title': 'Фото', + 'memories.notConnected': 'Immich не підключено', + 'memories.notConnectedHint': + 'Підключіть Immich у налаштуваннях, щоб бачити фотографії з поїздок.', + 'memories.notConnectedMultipleHint': + 'Підключіть одного з цих фотопровайдерів: {provider_names} у Налаштуваннях, щоб додавати фотографії до цієї подорожі.', + 'memories.noDates': 'Додайте дати поїздки, щоб завантажити фотографії.', + 'memories.noPhotos': 'Фотографій не знайдено', + 'memories.noPhotosHint': 'В Immich немає фотографій за період цієї поїздки.', + 'memories.photosFound': 'фото', + 'memories.fromOthers': 'від інших', + 'memories.sharePhotos': 'Поділитися фото', + 'memories.sharing': 'Спільний доступ', + 'memories.reviewTitle': 'Перевірте свої фото', + 'memories.reviewHint': + 'Натисніть на фото, щоб виключити його зі спільного доступу.', + 'memories.shareCount': 'Поділитися ({count} фото)', + 'memories.providerUrl': 'URL сервера', + 'memories.providerApiKey': 'API-ключ', + 'memories.providerUsername': 'Ім’я користувача', + 'memories.providerPassword': 'Пароль', + 'memories.providerOTP': 'Код MFA (якщо увімкнено)', + 'memories.skipSSLVerification': 'Пропустити перевірку SSL-сертифіката', + 'memories.immichAutoUpload': + 'Дублювати фото journey в Immich при завантаженні', + 'memories.providerUrlHintSynology': + 'Включіть шлях додатку Photos в URL, наприклад https://nas:5001/photo', + 'memories.testConnection': 'Перевірити підключення', + 'memories.testShort': 'Перевірити', + 'memories.testFirst': 'Спершу перевірте підключення', + 'memories.connected': 'Підключено', + 'memories.disconnected': 'Не підключено', + 'memories.connectionSuccess': 'Підключення до Immich встановлено', + 'memories.connectionError': 'Не вдалося підключитися до Immich', + 'memories.saved': 'Налаштування {provider_name} збережено', + 'memories.providerDisconnectedBanner': + 'З’єднання з {provider_name} втрачено. Перепідключіться в Налаштуваннях для перегляду фото.', + 'memories.saveError': 'Не вдалося зберегти налаштування {provider_name}', + 'memories.oldest': 'Спочатку старі', + 'memories.newest': 'Спочатку нові', + 'memories.allLocations': 'Усі місця', + 'memories.addPhotos': 'Додати фото', + 'memories.linkAlbum': 'Прив’язати альбом', + 'memories.selectAlbum': 'Вибрати альбом Immich', + 'memories.selectAlbumMultiple': 'Вибрати альбом', + 'memories.noAlbums': 'Альбомів не знайдено', + 'memories.syncAlbum': 'Синхронізувати', + 'memories.unlinkAlbum': 'Відв’язати', + 'memories.photos': 'фото', + 'memories.selectPhotos': 'Вибрати фото з Immich', + 'memories.selectPhotosMultiple': 'Вибрати фотографії', + 'memories.selectHint': 'Натисніть на фото, щоб вибрати їх.', + 'memories.selected': 'вибрано', + 'memories.addSelected': 'Додати {count} фото', + 'memories.alreadyAdded': 'Додано', + 'memories.private': 'Приватне', + 'memories.stopSharing': 'Припинити доступ', + 'memories.tripDates': 'Дати поїздки', + 'memories.allPhotos': 'Усі фото', + 'memories.confirmShareTitle': 'Поділитися з учасниками поїздки?', + 'memories.confirmShareHint': + '{count} фото стануть видимі всім учасникам цієї поїздки. Ви зможете зробити окремі фото приватними пізніше.', + 'memories.confirmShareButton': 'Поділитися фото', + 'memories.error.loadAlbums': 'Не вдалося завантажити альбоми', + 'memories.error.linkAlbum': "Не вдалося прив'язати альбом", + 'memories.error.unlinkAlbum': "Не вдалося від'вязати альбом", + 'memories.error.syncAlbum': 'Не вдалося синхронізувати альбом', + 'memories.error.loadPhotos': 'Не вдалося завантажити фотографії', + 'memories.error.addPhotos': 'Не вдалося додати фотографії', + 'memories.error.removePhoto': 'Не вдалося видалити фотографію', + 'memories.error.toggleSharing': 'Не вдалося оновити налаштування доступу', + 'memories.saveRouteNotConfigured': + 'Маршрут збереження не налаштовано для цього провайдера', + 'memories.testRouteNotConfigured': + 'Маршрут тестування не налаштовано для цього провайдера', + 'memories.fillRequiredFields': 'Будь ласка, заповніть усі обов’язкові поля', +}; +export default memories; diff --git a/shared/src/i18n/uk/nav.ts b/shared/src/i18n/uk/nav.ts new file mode 100644 index 0000000000000000000000000000000000000000..90ddf147b2ac11937dd278aafc36ca5a1b74ded5 --- /dev/null +++ b/shared/src/i18n/uk/nav.ts @@ -0,0 +1,20 @@ +import type { TranslationStrings } from '../types'; + +const nav: TranslationStrings = { + 'nav.trip': 'Поїздка', + 'nav.share': 'Поділитися', + 'nav.settings': 'Налаштування', + 'nav.admin': 'Адмін', + 'nav.logout': 'Вийти', + 'nav.lightMode': 'Світла тема', + 'nav.darkMode': 'Темна тема', + 'nav.autoMode': 'Авто', + 'nav.administrator': 'Адміністратор', + 'nav.myTrips': 'Мої поїздки', + 'nav.profile': 'Профіль', + 'nav.bottomSettings': 'Налаштування', + 'nav.bottomAdmin': 'Адміністрування', + 'nav.bottomLogout': 'Вийти', + 'nav.bottomAdminBadge': 'Адмін', +}; +export default nav; diff --git a/shared/src/i18n/uk/notif.ts b/shared/src/i18n/uk/notif.ts new file mode 100644 index 0000000000000000000000000000000000000000..d84d7f2d28cd992ec3176d512db1084f821a9615 --- /dev/null +++ b/shared/src/i18n/uk/notif.ts @@ -0,0 +1,42 @@ +import type { TranslationStrings } from '../types'; + +const notif: TranslationStrings = { + 'notif.test.title': '[Тест] Сповіщення', + 'notif.test.simple.text': 'Це просте тестове сповіщення.', + 'notif.test.boolean.text': 'Ви приймаєте це тестове сповіщення?', + 'notif.test.navigate.text': + 'Натисніть нижче, щоб перейти на панель управління.', + 'notif.trip_invite.title': 'Запрошення до поїздки', + 'notif.trip_invite.text': '{actor} запросив вас до {trip}', + 'notif.booking_change.title': 'Бронювання оновлено', + 'notif.booking_change.text': '{actor} оновив бронювання в {trip}', + 'notif.trip_reminder.title': 'Нагадування про поїздку', + 'notif.trip_reminder.text': 'Ваша поїздка {trip} скоро почнеться!', + 'notif.todo_due.title': 'Завдання до терміну', + 'notif.todo_due.text': '{todo} у {trip} — термін {due}', + 'notif.vacay_invite.title': 'Запрошення Vacay Fusion', + 'notif.vacay_invite.text': '{actor} запрошує вас об’єднати плани відпустки', + 'notif.photos_shared.title': 'Фото опубліковано', + 'notif.photos_shared.text': '{actor} поділився {count} фото у {trip}', + 'notif.collab_message.title': 'Нове повідомлення', + 'notif.collab_message.text': '{actor} надіслав повідомлення в {trip}', + 'notif.packing_tagged.title': 'Завдання для пакування', + 'notif.packing_tagged.text': '{actor} призначив вас у {category} у {trip}', + 'notif.version_available.title': 'Доступна нова версія', + 'notif.version_available.text': 'TREK {version} тепер доступний', + 'notif.action.view_trip': 'Відкрити поїздку', + 'notif.action.view_collab': 'Відкрити повідомлення', + 'notif.action.view_packing': 'Відкрити пакування', + 'notif.action.view_photos': 'Відкрити фото', + 'notif.action.view_vacay': 'Відкрити Vacay', + 'notif.action.view_admin': 'Перейти в адмін', + 'notif.action.view': 'Відкрити', + 'notif.action.accept': 'Прийняти', + 'notif.action.decline': 'Відхилити', + 'notif.generic.title': 'Сповіщення', + 'notif.generic.text': 'У вас нове сповіщення', + 'notif.dev.unknown_event.title': '[DEV] Невідома подія', + 'notif.dev.unknown_event.text': + 'Тип події "{event}" не зареєстровано в EVENT_NOTIFICATION_CONFIG', +}; +export default notif; diff --git a/shared/src/i18n/uk/notifications.ts b/shared/src/i18n/uk/notifications.ts new file mode 100644 index 0000000000000000000000000000000000000000..28a882d59ef9cbb077a39ec60cdb5d3ff7992935 --- /dev/null +++ b/shared/src/i18n/uk/notifications.ts @@ -0,0 +1,37 @@ +import type { TranslationStrings } from '../types'; + +const notifications: TranslationStrings = { + 'notifications.title': 'Сповіщення', + 'notifications.markAllRead': 'Позначити всі прочитаними', + 'notifications.deleteAll': 'Видалити всі', + 'notifications.showAll': 'Показати всі сповіщення', + 'notifications.empty': 'Немає сповіщень', + 'notifications.emptyDescription': 'Ви в курсі всіх подій!', + 'notifications.all': 'Усі', + 'notifications.unreadOnly': 'Непрочитані', + 'notifications.markRead': 'Позначити як прочитане', + 'notifications.markUnread': 'Позначити як непрочитане', + 'notifications.delete': 'Видалити', + 'notifications.system': 'Система', + 'notifications.synologySessionCleared.title': 'Synology Photos відключено', + 'notifications.synologySessionCleared.text': + 'Ваш сервер або акаунт змінено — перейдіть у Налаштування, щоб перевірити з’єднання знову.', + 'notifications.test.title': 'Тестове сповіщення від {actor}', + 'notifications.test.text': 'Це просте тестове сповіщення.', + 'notifications.test.booleanTitle': '{actor} запрошує підтвердження', + 'notifications.test.booleanText': 'Тестове сповіщення з вибором.', + 'notifications.test.accept': 'Підтвердити', + 'notifications.test.decline': 'Відхилити', + 'notifications.test.navigateTitle': 'Подивіться на це', + 'notifications.test.navigateText': 'Тестове сповіщення з переходом.', + 'notifications.test.goThere': 'Перейти', + 'notifications.test.adminTitle': 'Розсилка адміністратора', + 'notifications.test.adminText': + '{actor} надіслав тестове сповіщення всім адміністраторам.', + 'notifications.test.tripTitle': '{actor} написав у вашій поїздці', + 'notifications.test.tripText': 'Тестове сповіщення для поїздки "{trip}".', + 'notifications.versionAvailable.title': 'Доступне оновлення', + 'notifications.versionAvailable.text': 'TREK {version} тепер доступний.', + 'notifications.versionAvailable.button': 'Докладніше', +}; +export default notifications; diff --git a/shared/src/i18n/uk/oauth.ts b/shared/src/i18n/uk/oauth.ts new file mode 100644 index 0000000000000000000000000000000000000000..b14621128b3cbe1450a30532767fe62c242ea427 --- /dev/null +++ b/shared/src/i18n/uk/oauth.ts @@ -0,0 +1,123 @@ +import type { TranslationStrings } from '../types'; + +const oauth: TranslationStrings = { + 'oauth.scope.group.trips': 'Поїздки', + 'oauth.scope.group.places': 'Місця', + 'oauth.scope.group.atlas': 'Atlas', + 'oauth.scope.group.packing': 'Речі', + 'oauth.scope.group.todos': 'Задачі', + 'oauth.scope.group.budget': 'Бюджет', + 'oauth.scope.group.reservations': 'Бронювання', + 'oauth.scope.group.collab': 'Співпраця', + 'oauth.scope.group.notifications': 'Сповіщення', + 'oauth.scope.group.vacay': 'Відпустка', + 'oauth.scope.group.geo': 'Geo', + 'oauth.scope.group.weather': 'Погода', + 'oauth.scope.group.journey': 'Подорожі', + 'oauth.scope.trips:read.label': 'Перегляд поїздок і маршрутів', + 'oauth.scope.trips:read.description': + 'Читання поїздок, днів, нотаток і учасників', + 'oauth.scope.trips:write.label': 'Редагування поїздок і маршрутів', + 'oauth.scope.trips:write.description': + 'Створення та оновлення поїздок, днів, нотаток і керування учасниками', + 'oauth.scope.trips:delete.label': 'Видалення поїздок', + 'oauth.scope.trips:delete.description': + 'Безповоротне видалення поїздок — ця дія незворотна', + 'oauth.scope.trips:share.label': 'Керування посиланнями спільного доступу', + 'oauth.scope.trips:share.description': + 'Створення, оновлення та відкликання публічних посилань на поїздки', + 'oauth.scope.places:read.label': 'Перегляд місць і даних карти', + 'oauth.scope.places:read.description': + 'Читання місць, призначень за днями, тегів і категорій', + 'oauth.scope.places:write.label': 'Керування місцями', + 'oauth.scope.places:write.description': + 'Створення, оновлення та видалення місць, призначень і тегів', + 'oauth.scope.atlas:read.label': 'Перегляд Atlas', + 'oauth.scope.atlas:read.description': + 'Читання відвіданих країн, регіонів і списку бажань', + 'oauth.scope.atlas:write.label': 'Керування Atlas', + 'oauth.scope.atlas:write.description': + 'Позначення відвіданих країн і регіонів, керування списком бажань', + 'oauth.scope.packing:read.label': 'Перегляд списків речей', + 'oauth.scope.packing:read.description': + 'Читання речей, сумок і призначень категорій', + 'oauth.scope.packing:write.label': 'Керування списками речей', + 'oauth.scope.packing:write.description': + 'Додавання, оновлення, видалення, позначення і переставлення речей та сумок', + 'oauth.scope.todos:read.label': 'Перегляд списків задач', + 'oauth.scope.todos:read.description': + 'Читання задач поїздки і призначень категорій', + 'oauth.scope.todos:write.label': 'Керування списками задач', + 'oauth.scope.todos:write.description': + 'Створення, оновлення, позначення, видалення і переставлення задач', + 'oauth.scope.budget:read.label': 'Перегляд бюджету', + 'oauth.scope.budget:read.description': + 'Читання статей бюджету і розбивки витрат', + 'oauth.scope.budget:write.label': 'Керування бюджетом', + 'oauth.scope.budget:write.description': + 'Створення, оновлення і видалення статей бюджету', + 'oauth.scope.reservations:read.label': 'Перегляд бронювань', + 'oauth.scope.reservations:read.description': + 'Читання бронювань і відомостей про проживання', + 'oauth.scope.reservations:write.label': 'Керування бронюваннями', + 'oauth.scope.reservations:write.description': + 'Створення, оновлення, видалення і переставлення бронювань', + 'oauth.scope.collab:read.label': 'Перегляд співпраці', + 'oauth.scope.collab:read.description': + 'Читання спільних нотаток, опитувань і повідомлень', + 'oauth.scope.collab:write.label': 'Керування співпрацею', + 'oauth.scope.collab:write.description': + 'Створення, оновлення і видалення нотаток, опитувань і повідомлень', + 'oauth.scope.notifications:read.label': 'Перегляд сповіщень', + 'oauth.scope.notifications:read.description': + 'Читання сповіщень у додатку та кількості непрочитаних', + 'oauth.scope.notifications:write.label': 'Керування сповіщеннями', + 'oauth.scope.notifications:write.description': + 'Позначення сповіщень як прочитаних і відповіді на них', + 'oauth.scope.vacay:read.label': 'Перегляд планів відпустки', + 'oauth.scope.vacay:read.description': + 'Читання даних планування відпустки, записів і статистики', + 'oauth.scope.vacay:write.label': 'Керування планами відпустки', + 'oauth.scope.vacay:write.description': + 'Створення і керування записами відпустки, святами і командними планами', + 'oauth.scope.geo:read.label': 'Карти і геокодування', + 'oauth.scope.geo:read.description': + 'Пошук місць, розв’язання URL карт і зворотне геокодування координат', + 'oauth.scope.weather:read.label': 'Прогнози погоди', + 'oauth.scope.weather:read.description': + 'Отримання прогнозів погоди для місць і дат поїздки', + 'oauth.scope.journey:read.label': 'Перегляд подорожей', + 'oauth.scope.journey:read.description': + 'Читання подорожей, записів і списку учасників', + 'oauth.scope.journey:write.label': 'Керування подорожами', + 'oauth.scope.journey:write.description': + 'Створення, оновлення і видалення подорожей та їх записів', + 'oauth.scope.journey:share.label': 'Керування посиланнями на подорожі', + 'oauth.scope.journey:share.description': + 'Створення, оновлення і відкликання публічних посилань на подорожі', + 'oauth.authorize.authorizing': 'Authorizing…', // en-fallback + 'oauth.authorize.loading': 'Loading…', // en-fallback + 'oauth.authorize.errorTitle': 'Authorization Error', // en-fallback + 'oauth.authorize.loginTitle': 'Sign in to continue', // en-fallback + 'oauth.authorize.loginDescription': + '{client} wants access to your TREK account. Please sign in first.', // en-fallback + 'oauth.authorize.loginButton': 'Sign in to TREK', // en-fallback + 'oauth.authorize.requestLabel': 'Authorization Request', // en-fallback + 'oauth.authorize.requestDescription': + 'This application is requesting access to your TREK account.', // en-fallback + 'oauth.authorize.trustNote': + 'Only grant access to applications you trust. Your data stays on your server.', // en-fallback + 'oauth.authorize.selectScope': 'Select at least one scope', // en-fallback + 'oauth.authorize.approveOneScope': 'Approve ({count} scope)', // en-fallback + 'oauth.authorize.approveManyScopes': 'Approve ({count} scopes)', // en-fallback + 'oauth.authorize.approveAccess': 'Approve Access', // en-fallback + 'oauth.authorize.deny': 'Deny', // en-fallback + 'oauth.authorize.choosePermissions': 'Choose which permissions to grant', // en-fallback + 'oauth.authorize.permissionsRequested': 'Permissions requested', // en-fallback + 'oauth.authorize.alwaysIncluded': 'Always included', // en-fallback + 'oauth.authorize.alwaysTool.listTrips': + 'List your trips so the AI can discover trip IDs', // en-fallback + 'oauth.authorize.alwaysTool.getTripSummary': + 'Read a trip overview needed to use any other tool', // en-fallback +}; +export default oauth; diff --git a/shared/src/i18n/uk/packing.ts b/shared/src/i18n/uk/packing.ts new file mode 100644 index 0000000000000000000000000000000000000000..416f16f361d23da6c9ba6ec8be728f6cbb7e1d09 --- /dev/null +++ b/shared/src/i18n/uk/packing.ts @@ -0,0 +1,186 @@ +import type { TranslationStrings } from '../types'; + +const packing: TranslationStrings = { + 'packing.title': 'Список речей', + 'packing.empty': 'Список речей порожній', + 'packing.import': 'Імпорт', + 'packing.importTitle': 'Імпорт списку речей', + 'packing.importHint': + 'Один предмет у рядок. Категорію та кількість — через кому, крапку з комою або табуляцію: Назва, Категорія, Кількість', + 'packing.importPlaceholder': + 'Зубна щітка\nСонцезахисний крем, Гігієна\nФутболки, Одяг, 5\nПаспорт, Документи', + 'packing.importCsv': 'Завантажити CSV/TXT', + 'packing.importAction': 'Імпортувати {count}', + 'packing.importSuccess': '{count} предметів імпортовано', + 'packing.importError': 'Помилка імпорту', + 'packing.importEmpty': 'Немає предметів для імпорту', + 'packing.progress': '{packed} з {total} зібрано ({percent}%)', + 'packing.clearChecked': 'Видалити {count} позначених', + 'packing.clearCheckedShort': 'Видалити {count}', + 'packing.suggestions': 'Підказки', + 'packing.suggestionsTitle': 'Додати підказки', + 'packing.allSuggested': 'Усі підказки додано', + 'packing.allPacked': 'Усе зібрано!', + 'packing.addPlaceholder': 'Додати річ...', + 'packing.categoryPlaceholder': 'Категорія...', + 'packing.filterAll': 'Усі', + 'packing.filterOpen': 'Не зібрано', + 'packing.filterDone': 'Зібрано', + 'packing.emptyTitle': 'Список речей порожній', + 'packing.emptyHint': 'Додайте речі або використайте підказки', + 'packing.emptyFiltered': 'Немає речей, що відповідають фільтру', + 'packing.menuRename': 'Перейменувати', + 'packing.menuCheckAll': 'Позначити все', + 'packing.menuUncheckAll': 'Зняти позначки', + 'packing.menuDeleteCat': 'Видалити категорію', + 'packing.addItem': 'Додати річ', + 'packing.addItemPlaceholder': 'Назва...', + 'packing.addCategory': 'Додати категорію', + 'packing.newCategoryPlaceholder': 'Назва категорії (наприклад, Одяг)', + 'packing.applyTemplate': 'Застосувати шаблон', + 'packing.template': 'Шаблон', + 'packing.templateApplied': '{count} речей додано з шаблону', + 'packing.templateError': 'Помилка застосування шаблону', + 'packing.saveAsTemplate': 'Зберегти як шаблон', + 'packing.templateName': 'Назва шаблону', + 'packing.templateSaved': 'Список речей збережено як шаблон', + 'packing.noMembers': 'Немає учасників', + 'packing.bags': 'Багаж', + 'packing.noBag': 'Не призначено', + 'packing.totalWeight': 'Загальна вага', + 'packing.bagName': 'Назва...', + 'packing.addBag': 'Додати багаж', + 'packing.changeCategory': 'Змінити категорію', + 'packing.confirm.clearChecked': + 'Ви впевнені, що хочете видалити {count} позначених речей?', + 'packing.confirm.deleteCat': + 'Ви впевнені, що хочете видалити категорію «{name}» з {count} речами?', + 'packing.defaultCategory': 'Інше', + 'packing.toast.saveError': 'Помилка збереження', + 'packing.toast.deleteError': 'Помилка видалення', + 'packing.toast.renameError': 'Помилка перейменування', + 'packing.toast.addError': 'Помилка додавання', + 'packing.suggestions.items': [ + { + name: 'Паспорт', + category: 'Документи', + }, + { + name: 'Посвідчення особи', + category: 'Документи', + }, + { + name: 'Страхування', + category: 'Документи', + }, + { + name: 'Авіаквитки', + category: 'Документи', + }, + { + name: 'Банківська картка', + category: 'Фінанси', + }, + { + name: 'Готівка', + category: 'Фінанси', + }, + { + name: 'Віза', + category: 'Документи', + }, + { + name: 'Футболки', + category: 'Одяг', + }, + { + name: 'Штани', + category: 'Одяг', + }, + { + name: 'Нижня білизна', + category: 'Одяг', + }, + { + name: 'Шкарпетки', + category: 'Одяг', + }, + { + name: 'Куртка', + category: 'Одяг', + }, + { + name: 'Піжама', + category: 'Одяг', + }, + { + name: 'Купальник', + category: 'Одяг', + }, + { + name: 'Дощовик', + category: 'Одяг', + }, + { + name: 'Зручне взуття', + category: 'Одяг', + }, + { + name: 'Зубна щітка', + category: 'Гігієна', + }, + { + name: 'Зубна паста', + category: 'Гігієна', + }, + { + name: 'Шампунь', + category: 'Гігієна', + }, + { + name: 'Дезодорант', + category: 'Гігієна', + }, + { + name: 'Сонцезахисний крем', + category: 'Гігієна', + }, + { + name: 'Пасок', + category: 'Гігієна', + }, + { + name: 'Зарядний пристрій', + category: 'Електроніка', + }, + { + name: 'Зовнішній акумулятор', + category: 'Електроніка', + }, + { + name: 'Навушники', + category: 'Електроніка', + }, + { + name: 'Адаптер для розеток', + category: 'Електроніка', + }, + { + name: 'Фотоапарат', + category: 'Електроніка', + }, + { + name: 'Знеболювальні', + category: 'Здоров’я', + }, + { + name: 'Пластирі', + category: 'Здоров’я', + }, + { + name: 'Антисептик', + category: 'Здоров’я', + }, + ], +}; +export default packing; diff --git a/shared/src/i18n/uk/pdf.ts b/shared/src/i18n/uk/pdf.ts new file mode 100644 index 0000000000000000000000000000000000000000..30073b81a92b365ccc395d59e569138ecc9e001f --- /dev/null +++ b/shared/src/i18n/uk/pdf.ts @@ -0,0 +1,10 @@ +import type { TranslationStrings } from '../types'; + +const pdf: TranslationStrings = { + 'pdf.travelPlan': 'План поїздки', + 'pdf.planned': 'Заплановано', + 'pdf.costLabel': 'Вартість EUR', + 'pdf.preview': 'Попередній перегляд PDF', + 'pdf.saveAsPdf': 'Зберегти як PDF', +}; +export default pdf; diff --git a/shared/src/i18n/uk/perm.ts b/shared/src/i18n/uk/perm.ts new file mode 100644 index 0000000000000000000000000000000000000000..3c484c94573ddbcc2716d9bedbfac8e8c4513ffa --- /dev/null +++ b/shared/src/i18n/uk/perm.ts @@ -0,0 +1,63 @@ +import type { TranslationStrings } from '../types'; + +const perm: TranslationStrings = { + 'perm.title': 'Налаштування дозволів', + 'perm.subtitle': 'Керуйте тим, хто може виконувати дії в додатку', + 'perm.saved': 'Налаштування дозволів збережено', + 'perm.resetDefaults': 'Скинути за замовчуванням', + 'perm.customized': 'змінено', + 'perm.level.admin': 'Тільки адміністратор', + 'perm.level.tripOwner': 'Власник поїздки', + 'perm.level.tripMember': 'Учасники поїздки', + 'perm.level.everybody': 'Усі', + 'perm.cat.trip': 'Керування поїздками', + 'perm.cat.members': 'Керування учасниками', + 'perm.cat.files': 'Файли', + 'perm.cat.content': 'Контент та розклад', + 'perm.cat.extras': 'Бюджет, збори та співпраця', + 'perm.action.trip_create': 'Створювати поїздки', + 'perm.action.trip_edit': 'Редагувати деталі поїздки', + 'perm.action.trip_delete': 'Видаляти поїздки', + 'perm.action.trip_archive': 'Архівувати / розархівувати поїздки', + 'perm.action.trip_cover_upload': 'Завантажувати обкладинку', + 'perm.action.member_manage': 'Додавати / видаляти учасників', + 'perm.action.file_upload': 'Завантажувати файли', + 'perm.action.file_edit': 'Редагувати метадані файлів', + 'perm.action.file_delete': 'Видаляти файли', + 'perm.action.place_edit': 'Додавати / редагувати / видаляти місця', + 'perm.action.day_edit': 'Редагувати дні, нотатки та призначення', + 'perm.action.reservation_edit': 'Керувати бронюваннями', + 'perm.action.budget_edit': 'Керувати бюджетом', + 'perm.action.packing_edit': 'Керувати списками речей', + 'perm.action.collab_edit': 'Співпраця (нотатки, опитування, чат)', + 'perm.action.share_manage': 'Керувати посиланнями для обміну', + 'perm.actionHint.trip_create': 'Хто може створювати нові поїздки', + 'perm.actionHint.trip_edit': + 'Хто може змінювати назву, дати, опис і валюту поїздки', + 'perm.actionHint.trip_delete': 'Хто може безповоротно видалити поїздку', + 'perm.actionHint.trip_archive': + 'Хто може архівувати або розархівувати поїздку', + 'perm.actionHint.trip_cover_upload': + 'Хто може завантажувати або змінювати обкладинку', + 'perm.actionHint.member_manage': + 'Хто може запрошувати або видаляти учасників поїздки', + 'perm.actionHint.file_upload': 'Хто може завантажувати файли до поїздки', + 'perm.actionHint.file_edit': 'Хто може редагувати описи та посилання файлів', + 'perm.actionHint.file_delete': + 'Хто може переміщувати файли до кошика або безповоротно видаляти', + 'perm.actionHint.place_edit': + 'Хто може додавати, редагувати або видаляти місця', + 'perm.actionHint.day_edit': + 'Хто може редагувати дні, нотатки до днів та призначення місць', + 'perm.actionHint.reservation_edit': + 'Хто може створювати, редагувати або видаляти бронювання', + 'perm.actionHint.budget_edit': + 'Хто може створювати, редагувати або видаляти статті бюджету', + 'perm.actionHint.packing_edit': + 'Хто може керувати речами для зборів і сумками', + 'perm.actionHint.collab_edit': + 'Хто може створювати нотатки, опитування та надсилати повідомлення', + 'perm.actionHint.share_manage': + 'Хто може створювати або видаляти публічні посилання для обміну', +}; +export default perm; diff --git a/shared/src/i18n/uk/photos.ts b/shared/src/i18n/uk/photos.ts new file mode 100644 index 0000000000000000000000000000000000000000..94c6904cb8df9182481332d5571a3c49cdc608ef --- /dev/null +++ b/shared/src/i18n/uk/photos.ts @@ -0,0 +1,25 @@ +import type { TranslationStrings } from '../types'; + +const photos: TranslationStrings = { + 'photos.title': 'Фотографії', + 'photos.subtitle': '{count} фото для {trip}', + 'photos.dropHere': 'Перетягніть фото сюди...', + 'photos.dropHereActive': 'Перетягніть фото сюди', + 'photos.captionForAll': 'Підпис (для всіх)', + 'photos.captionPlaceholder': 'Необов’язковий підпис...', + 'photos.addCaption': 'Додати підпис...', + 'photos.allDays': 'Усі дні', + 'photos.noPhotos': 'Фото поки немає', + 'photos.uploadHint': 'Завантажте фото з поїздки', + 'photos.clickToSelect': 'або натисніть для вибору', + 'photos.linkPlace': 'Прив’язати місце', + 'photos.noPlace': 'Без місця', + 'photos.uploadN': '{n} фото завантажено', + 'photos.linkDay': 'Прив’язати день', + 'photos.noDay': 'Немає дня', + 'photos.dayLabel': 'День {number}', + 'photos.photoSelected': 'Фото вибрано', + 'photos.photosSelected': 'Фото вибрано', + 'photos.fileTypeHint': 'JPG, PNG, WebP · макс. 10 МБ · до 30 фото', +}; +export default photos; diff --git a/shared/src/i18n/uk/places.ts b/shared/src/i18n/uk/places.ts new file mode 100644 index 0000000000000000000000000000000000000000..38fa79f51c948c18e18a6672ab341abc9c56bdc9 --- /dev/null +++ b/shared/src/i18n/uk/places.ts @@ -0,0 +1,97 @@ +import type { TranslationStrings } from '../types'; + +const places: TranslationStrings = { + 'places.addPlace': 'Додати місце/активність', + 'places.importFile': 'Імпортувати файл', + 'places.sidebarDrop': 'Відпустіть для імпорту', + 'places.importFileHint': + 'Імпортуйте файли .gpx, .kml або .kmz із інструментів, таких як Google My Maps, Google Earth або GPS-трекер.', + 'places.importFileDropHere': + 'Натисніть, щоб вибрати файл, або перетягніть його сюди', + 'places.importFileDropActive': 'Відпустіть файл для вибору', + 'places.importFileUnsupported': + 'Непідтримуваний тип файлу. Використовуйте .gpx, .kml або .kmz.', + 'places.importFileTooLarge': + 'Файл занадто великий. Максимальний розмір завантаження — {maxMb} МБ.', + 'places.importFileError': 'Помилка імпорту', + 'places.importAllSkipped': 'Усі місця вже були в подорожі.', + 'places.gpxImported': '{count} місць імпортовано з GPX', + 'places.gpxImportTypes': 'Що імпортувати?', + 'places.gpxImportWaypoints': 'Путеві точки', + 'places.gpxImportRoutes': 'Маршрути', + 'places.gpxImportTracks': 'Треки (з геометрією маршруту)', + 'places.gpxImportNoneSelected': 'Оберіть щонайменше один тип для імпорту.', + 'places.kmlImportTypes': 'Що ви хочете імпортувати?', + 'places.kmlImportPoints': 'Точки (Placemark)', + 'places.kmlImportPaths': 'Маршрути (LineStrings)', + 'places.kmlImportNoneSelected': 'Виберіть щонайменше один тип.', + 'places.selectionCount': '{count} вибрано', + 'places.deleteSelected': 'Видалити вибране', + 'places.kmlKmzImported': '{count} місць імпортовано з KMZ/KML', + 'places.urlResolved': 'Місце імпортовано з URL', + 'places.importList': 'Імпорт списку', + 'places.kmlKmzSummaryValues': + 'Позначки: {total} • Імпортовано: {created} • Пропущено: {skipped}', + 'places.importGoogleList': 'Список Google', + 'places.importNaverList': 'Список Naver', + 'places.googleListHint': + 'Вставте посилання на спільний список Google Maps для імпорту всіх місць.', + 'places.googleListImported': '{count} місць імпортовано з "{list}"', + 'places.googleListError': 'Не вдалося імпортувати список Google Maps', + 'places.naverListHint': + 'Вставте посилання на спільний список Naver Maps для імпорту всіх місць.', + 'places.naverListImported': '{count} місць імпортовано з "{list}"', + 'places.naverListError': 'Не вдалося імпортувати список Naver Maps', + 'places.viewDetails': 'Деталі', + 'places.assignToDay': 'Додати на який день?', + 'places.all': 'Усі', + 'places.unplanned': 'Незаплановані', + 'places.filterTracks': 'Треки', + 'places.search': 'Пошук місць...', + 'places.allCategories': 'Всі категорії', + 'places.categoriesSelected': 'категорій', + 'places.clearFilter': 'Скинути фільтр', + 'places.count': '{count} місць', + 'places.countSingular': '1 місце', + 'places.allPlanned': 'Усі місця заплановані', + 'places.noneFound': 'Місця не знайдені', + 'places.editPlace': 'Редагувати місце', + 'places.formName': 'Назва', + 'places.formNamePlaceholder': 'наприклад, Ейфелева вежа', + 'places.formDescription': 'Опис', + 'places.formDescriptionPlaceholder': 'Короткий опис...', + 'places.formAddress': 'Адреса', + 'places.formAddressPlaceholder': 'Вулиця, місто, країна', + 'places.formLat': 'Широта (наприклад, 48.8566)', + 'places.formLng': 'Довгота (наприклад, 2.3522)', + 'places.formCategory': 'Категорія', + 'places.noCategory': 'Без категорії', + 'places.categoryNamePlaceholder': 'Назва категорії', + 'places.formTime': 'Час', + 'places.startTime': 'Початок', + 'places.endTime': 'Кінець', + 'places.endTimeBeforeStart': 'Час закінчення раніше за час початку', + 'places.timeCollision': 'Перетин за часом із:', + 'places.formWebsite': 'Веб-сайт', + 'places.formNotes': 'Нотатки', + 'places.formNotesPlaceholder': 'Особисті нотатки...', + 'places.formReservation': 'Бронювання', + 'places.reservationNotesPlaceholder': + 'Нотатки про бронювання, номер підтвердження...', + 'places.mapsSearchPlaceholder': 'Пошук місць...', + 'places.mapsSearchError': 'Помилка пошуку місць.', + 'places.loadingDetails': 'Завантаження даних про місце…', + 'places.osmHint': + 'Пошук через OpenStreetMap (без фото, годин роботи та рейтингів). Додайте API-ключ Google у налаштуваннях для повної інформації.', + 'places.osmActive': + 'Пошук через OpenStreetMap (без фото, рейтингів та годин роботи). Додайте API-ключ Google у налаштуваннях для розширених даних.', + 'places.categoryCreateError': 'Не вдалося створити категорію', + 'places.nameRequired': 'Введіть назву', + 'places.saveError': 'Помилка збереження', + 'places.duplicateExists': "'{name}' вже є в цій подорожі.", + 'places.addAnyway': 'Все одно додати', + 'places.enrichOnImport': 'Збагатити місця через Google', + 'places.enrichOnImportHint': + 'Знаходить кожне імпортоване місце й додає фото, адресу та контакти. Потрібен ключ Google Maps.', +}; +export default places; diff --git a/shared/src/i18n/uk/planner.ts b/shared/src/i18n/uk/planner.ts new file mode 100644 index 0000000000000000000000000000000000000000..14d5743e73414fe90a96acffe73337b4f2e55c5a --- /dev/null +++ b/shared/src/i18n/uk/planner.ts @@ -0,0 +1,68 @@ +import type { TranslationStrings } from '../types'; + +const planner: TranslationStrings = { + 'planner.places': 'Місця', + 'planner.bookings': 'Бронювання', + 'planner.packingList': 'Список речей', + 'planner.documents': 'Документи', + 'planner.dayPlan': 'План дня', + 'planner.reservations': 'Бронювання', + 'planner.minTwoPlaces': 'Потрібно мінімум 2 місця з координатами', + 'planner.noGeoPlaces': 'Немає місць з координатами', + 'planner.routeCalculated': 'Маршрут розраховано', + 'planner.routeCalcFailed': 'Не вдалося розрахувати маршрут', + 'planner.routeError': 'Помилка розрахунку маршруту', + 'planner.icsExportFailed': 'Не вдалося експортувати ICS', + 'planner.routeOptimized': 'Маршрут оптимізовано', + 'planner.reservationUpdated': 'Бронювання оновлено', + 'planner.reservationAdded': 'Бронювання додано', + 'planner.confirmDeleteReservation': 'Видалити бронювання?', + 'planner.reservationDeleted': 'Бронювання видалено', + 'planner.days': 'Дні', + 'planner.allPlaces': 'Усі місця', + 'planner.totalPlaces': 'Усього {n} місць', + 'planner.noDaysPlanned': 'Дні ще не заплановано', + 'planner.editTrip': 'Редагувати поїздку →', + 'planner.placeOne': '1 місце', + 'planner.placeN': '{n} місць', + 'planner.addNote': 'Додати нотатку', + 'planner.noEntries': 'На цей день записів немає', + 'planner.addPlace': 'Додати місце/активність', + 'planner.addPlaceShort': '+ Додати місце/активність', + 'planner.resPending': 'Бронювання очікує · ', + 'planner.resConfirmed': 'Бронювання підтверджено · ', + 'planner.notePlaceholder': 'Нотатка…', + 'planner.noteTimePlaceholder': 'Час (необов’язково)', + 'planner.noteExamplePlaceholder': + 'наприклад, S3 о 14:30 з вокзалу, пором з причалу 7, обідня перерва…', + 'planner.totalCost': 'Загальна вартість', + 'planner.searchPlaces': 'Пошук місць…', + 'planner.allCategories': 'Усі категорії', + 'planner.noPlacesFound': 'Місця не знайдені', + 'planner.addFirstPlace': 'Додати перше місце', + 'planner.noReservations': 'Немає бронювань', + 'planner.addFirstReservation': 'Додати перше бронювання', + 'planner.new': 'Нове', + 'planner.addToDay': '+ День', + 'planner.calculating': 'Розрахунок…', + 'planner.route': 'Маршрут', + 'planner.optimize': 'Оптимізувати', + 'planner.openGoogleMaps': 'Відкрити в Google Maps', + 'planner.selectDayHint': + 'Оберіть день зі списку ліворуч для перегляду плану дня', + 'planner.noPlacesForDay': 'На цей день місць поки немає', + 'planner.addPlacesLink': 'Додати місця →', + 'planner.minTotal': 'мін. всього', + 'planner.noReservation': 'Немає бронювання', + 'planner.removeFromDay': 'Прибрати з дня', + 'planner.addToThisDay': 'Додати до дня', + 'planner.overview': 'Огляд', + 'planner.noDays': 'Днів немає', + 'planner.editTripToAddDays': 'Відредагуйте поїздку, щоб додати дні', + 'planner.dayCount': '{n} днів', + 'planner.clickToUnlock': 'Натисніть, щоб розблокувати', + 'planner.keepPosition': 'Зберегти позицію при оптимізації маршруту', + 'planner.dayDetails': 'Подробиці дня', + 'planner.dayN': 'День {n}', +}; +export default planner; diff --git a/shared/src/i18n/uk/register.ts b/shared/src/i18n/uk/register.ts new file mode 100644 index 0000000000000000000000000000000000000000..588e01e8f75f491afa8f89beab614acb780bfac2 --- /dev/null +++ b/shared/src/i18n/uk/register.ts @@ -0,0 +1,25 @@ +import type { TranslationStrings } from '../types'; + +const register: TranslationStrings = { + 'register.passwordMismatch': 'Паролі не співпадають', + 'register.passwordTooShort': 'Пароль має містити щонайменше 8 символів', + 'register.failed': 'Помилка реєстрації', + 'register.getStarted': 'Почати', + 'register.subtitle': 'Створіть акаунт та почніть планувати подорожі мрії.', + 'register.feature1': 'Необмежена кількість планів подорожей', + 'register.feature2': 'Інтерактивна карта', + 'register.feature3': 'Керування місцями та категоріями', + 'register.feature4': 'Відстеження бронювань', + 'register.feature5': 'Створення списків речей', + 'register.feature6': 'Зберігання фото та файлів', + 'register.createAccount': 'Створити акаунт', + 'register.startPlanning': 'Почніть планувати свої поїздки', + 'register.minChars': 'Мін. 6 символів', + 'register.confirmPassword': 'Підтвердіть пароль', + 'register.repeatPassword': 'Повторіть пароль', + 'register.registering': 'Реєстрація...', + 'register.register': 'Зареєструватися', + 'register.hasAccount': 'Вже є акаунт?', + 'register.signIn': 'Увійти', +}; +export default register; diff --git a/shared/src/i18n/uk/reservations.ts b/shared/src/i18n/uk/reservations.ts new file mode 100644 index 0000000000000000000000000000000000000000..9cc101736e3be8b196f27c4c21477a81570095a1 --- /dev/null +++ b/shared/src/i18n/uk/reservations.ts @@ -0,0 +1,163 @@ +import type { TranslationStrings } from '../types'; + +const reservations: TranslationStrings = { + 'reservations.title': 'Бронювання', + 'reservations.empty': 'Поки немає бронювань', + 'reservations.emptyHint': 'Додайте бронювання на авіаквитки, готелі та інше', + 'reservations.add': 'Додати бронювання', + 'reservations.addManual': 'Ручне бронювання', + 'reservations.placeHint': + 'Порада: бронювання краще створювати безпосередньо з місця, щоб пов’язати їх з планом дня.', + 'reservations.confirmed': 'Підтверджено', + 'reservations.pending': 'Очікування', + 'reservations.summary': '{confirmed} підтвр., {pending} очікувань', + 'reservations.fromPlan': 'З плану', + 'reservations.showFiles': 'Показати файли', + 'reservations.editTitle': 'Редагувати бронювання', + 'reservations.status': 'Статус', + 'reservations.datetime': 'Дата і час', + 'reservations.startTime': 'Час початку', + 'reservations.endTime': 'Час закінчення', + 'reservations.date': 'Дата', + 'reservations.time': 'Час', + 'reservations.timeAlt': 'Час (альтернативний, напр. 19:30)', + 'reservations.notes': 'Нотатки', + 'reservations.notesPlaceholder': 'Додаткові нотатки...', + 'reservations.meta.airline': 'Авіакомпанія', + 'reservations.meta.flightNumber': 'Номер рейсу', + 'reservations.meta.from': 'Звідки', + 'reservations.meta.to': 'Куди', + 'reservations.layover.route': 'Маршрут', + 'reservations.layover.stop': 'Зупинка', + 'reservations.layover.addStop': 'Додати зупинку', + 'reservations.layover.connection': 'Пересадка', + 'reservations.layover.layover': 'Очікування', + 'reservations.needsReview': 'Перевірити', + 'reservations.needsReviewHint': + 'Аеропорт не вдалося визначити автоматично — підтвердіть місцезнаходження.', + 'reservations.searchLocation': 'Шукати станцію, порт, адресу...', + 'reservations.meta.trainNumber': 'Номер поїзда', + 'reservations.meta.platform': 'Платформа', + 'reservations.meta.seat': 'Місце', + 'reservations.meta.checkIn': 'Заїзд', + 'reservations.meta.checkInUntil': 'Заселення до', + 'reservations.meta.checkOut': 'Виїзд', + 'reservations.meta.linkAccommodation': 'Житло', + 'reservations.meta.pickAccommodation': 'Прив’язати до житла', + 'reservations.meta.noAccommodation': 'Ні', + 'reservations.meta.hotelPlace': 'Житло', + 'reservations.meta.pickHotel': 'Оберіть житло', + 'reservations.meta.fromDay': 'З', + 'reservations.meta.toDay': 'По', + 'reservations.meta.selectDay': 'Оберіть день', + 'reservations.type.flight': 'Авіаквиток', + 'reservations.type.hotel': 'Житло', + 'reservations.type.restaurant': 'Ресторан', + 'reservations.type.train': 'Поїзд', + 'reservations.type.car': 'Автомобіль', + 'reservations.type.cruise': 'Круїз', + 'reservations.type.event': 'Заходи', + 'reservations.type.tour': 'Екскурсія', + 'reservations.type.other': 'Інше', + 'reservations.type.bus': 'Автобус', + 'reservations.type.ferry': 'Пором', + 'reservations.type.bicycle': 'Велосипед', + 'reservations.type.taxi': 'Таксі', + 'reservations.type.transport_other': 'Інше', + 'reservations.confirm.delete': + 'Ви впевнені, що хочете видалити бронювання «{name}»?', + 'reservations.confirm.deleteTitle': 'Видалити бронювання?', + 'reservations.confirm.deleteBody': '«{name}» буде видалено назавжди.', + 'reservations.toast.updated': 'Бронювання оновлено', + 'reservations.toast.removed': 'Бронювання видалено', + 'reservations.toast.fileUploaded': 'Файл завантажено', + 'reservations.toast.uploadError': 'Помилка завантаження', + 'reservations.newTitle': 'Нове бронювання', + 'reservations.bookingType': 'Тип бронювання', + 'reservations.titleLabel': 'Назва', + 'reservations.titlePlaceholder': + 'наприклад, Lufthansa LH123, Hotel Adlon, ...', + 'reservations.locationAddress': 'Місцезнаходження / Адреса', + 'reservations.locationPlaceholder': 'Адреса, аеропорт, готель...', + 'reservations.confirmationCode': 'Код бронювання', + 'reservations.confirmationPlaceholder': 'наприклад, ABC12345', + 'reservations.day': 'День', + 'reservations.noDay': 'Без дня', + 'reservations.place': 'Місце', + 'reservations.noPlace': 'Без місця', + 'reservations.pendingSave': 'буде збережено…', + 'reservations.uploading': 'Завантаження...', + 'reservations.attachFile': 'Прикріпити файл', + 'reservations.linkExisting': 'Прив’язати існуючий файл', + 'reservations.toast.saveError': 'Помилка збереження', + 'reservations.toast.updateError': 'Помилка оновлення', + 'reservations.toast.deleteError': 'Помилка видалення', + 'reservations.confirm.remove': 'Видалити бронювання для «{name}»?', + 'reservations.linkAssignment': 'Прив’язати до призначення дня', + 'reservations.pickAssignment': 'Оберіть призначення з вашого плану...', + 'reservations.noAssignment': 'Без прив’язки (самостійно)', + 'reservations.price': 'Ціна', + 'reservations.budgetCategory': 'Категорія бюджету', + 'reservations.budgetCategoryPlaceholder': 'наприклад, Транспорт, Проживання', + 'reservations.budgetCategoryAuto': 'Авто (за типом бронювання)', + 'reservations.budgetHint': + 'При збереженні буде автоматично створено запис бюджету.', + 'reservations.departureDate': 'Виліт', + 'reservations.arrivalDate': 'Приліт', + 'reservations.departureTime': 'Час вильоту', + 'reservations.arrivalTime': 'Час прильоту', + 'reservations.pickupDate': 'Отримання', + 'reservations.returnDate': 'Повернення', + 'reservations.pickupTime': 'Час отримання', + 'reservations.returnTime': 'Час повернення', + 'reservations.endDate': 'Дата закінчення', + 'reservations.meta.departureTimezone': 'TZ вильоту', + 'reservations.meta.arrivalTimezone': 'TZ прильоту', + 'reservations.span.departure': 'Виліт', + 'reservations.span.arrival': 'Приліт', + 'reservations.span.inTransit': 'У дорозі', + 'reservations.span.pickup': 'Отримання', + 'reservations.span.return': 'Повернення', + 'reservations.span.active': 'Активно', + 'reservations.span.start': 'Початок', + 'reservations.span.end': 'Кінець', + 'reservations.span.ongoing': 'Триває', + 'reservations.validation.endBeforeStart': + 'Дата/час закінчення повинен бути пізніше дати/часу початку', + 'reservations.addBooking': 'Добавить бронирование', + 'reservations.import.title': 'Імпорт підтверджень бронювання', + 'reservations.import.cta': 'Імпортувати з файлу', + 'reservations.import.dropHere': 'Перетягніть файли підтверджень бронювання сюди або натисніть для вибору', + 'reservations.import.dropActive': 'Відпустіть файли для імпорту', + 'reservations.import.acceptedFormats': 'Підтримуються: EML, PDF, PKPass, HTML, TXT (макс. 10 МБ кожен, до 5 файлів)', + 'reservations.import.parsing': 'Обробка файлів…', + 'reservations.import.previewHeading': 'Знайдено {count} бронювання(нь)', + 'reservations.import.previewEmpty': 'З завантажених файлів не вдалося витягти бронювання.', + 'reservations.import.removeItem': 'Видалити', + 'reservations.import.confirm': 'Імпортувати {count} бронювання(нь)', + 'reservations.import.back': 'Назад', + 'reservations.import.success': '{count} бронювання(нь) імпортовано', + 'reservations.import.partialFailure': '{created} імпортовано, {failed} не вдалося', + 'reservations.import.error': 'Обробка не вдалася. Переконайтесь, що файл є дійсним підтвердженням бронювання.', + 'reservations.import.unavailable': 'Імпорт бронювань недоступний на цьому сервері.', + 'reservations.import.unsupportedFormat': 'Непідтримуваний формат файлу. Використовуйте EML, PDF, PKPass, HTML або TXT.', + 'reservations.import.fileTooLarge': 'Файл «{name}» перевищує обмеження в 10 МБ.', + 'reservations.airtrail.title': 'Імпорт з AirTrail', + 'reservations.airtrail.cta': 'AirTrail', + 'reservations.airtrail.synced': 'AirTrail', + 'reservations.airtrail.syncedHint': 'Синхронізовано з AirTrail — зміни синхронізуються в обидва боки.', + 'reservations.airtrail.notSynced': 'Не синхронізовано', + 'reservations.airtrail.notSyncedHint': 'Цей рейс було видалено в AirTrail і він більше не синхронізується.', + 'reservations.airtrail.loadError': 'Не вдалося завантажити ваші рейси з AirTrail.', + 'reservations.airtrail.imported': '{count} рейс(ів) імпортовано', + 'reservations.airtrail.skippedDuplicate': '{count} вже в цій подорожі, пропущено', + 'reservations.airtrail.nothingImported': 'Немає чого імпортувати.', + 'reservations.airtrail.importError': 'Імпорт не вдався. Спробуйте ще раз.', + 'reservations.airtrail.undo': 'Імпорт з AirTrail', + 'reservations.airtrail.alreadyImported': 'Імпортовано', + 'reservations.airtrail.duringTrip': 'Під час цієї подорожі', + 'reservations.airtrail.otherFlights': 'Інші рейси', + 'reservations.airtrail.empty': 'У вашому акаунті AirTrail не знайдено рейсів.', + 'reservations.airtrail.importCta': 'Імпортувати {count}', +}; +export default reservations; diff --git a/shared/src/i18n/uk/settings.ts b/shared/src/i18n/uk/settings.ts new file mode 100644 index 0000000000000000000000000000000000000000..dd54c33ddb3d0e48eaebca6df528f00867d71c51 --- /dev/null +++ b/shared/src/i18n/uk/settings.ts @@ -0,0 +1,344 @@ +import type { TranslationStrings } from '../types'; + +const settings: TranslationStrings = { + 'settings.title': 'Налаштування', + 'settings.subtitle': 'Налаштуйте свої персональні параметри', + 'settings.tabs.display': 'Відображення', + 'settings.tabs.map': 'Карта', + 'settings.tabs.notifications': 'Сповіщення', + 'settings.tabs.integrations': 'Інтеграції', + 'settings.tabs.account': 'Обліковий запис', + 'settings.tabs.offline': 'Офлайн', + 'settings.tabs.about': 'Про застосунок', + 'settings.map': 'Карта', + 'settings.mapTemplate': 'Шаблон карти', + 'settings.mapTemplatePlaceholder.select': 'Виберіть шаблон...', + 'settings.mapDefaultHint': + 'Залиште порожнім для OpenStreetMap (за замовчуванням)', + 'settings.mapTemplatePlaceholder': + 'https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', + 'settings.mapHint': 'URL-шаблон для тайлів карти', + 'settings.mapProvider': 'Провайдер карти', + 'settings.mapProviderHint': + 'Застосовується до Trip Planner та Journey. Atlas завжди використовує Leaflet.', + 'settings.mapLeafletSubtitle': 'Класичні 2D, будь-які растрові тайли', + 'settings.mapMapboxSubtitle': 'Векторні тайли, 3D-будинки та рельєф', + 'settings.mapExperimental': 'Експериментально', + 'settings.mapMapboxToken': 'Токен доступу Mapbox', + 'settings.mapMapboxTokenHint': 'Публічний токен (pk.*) з', + 'settings.mapMapboxTokenLink': 'mapbox.com → Токени доступу', + 'settings.mapStyle': 'Стиль карти', + 'settings.mapStylePlaceholder': 'Виберіть стиль Mapbox', + 'settings.mapStyleHint': 'Preset або власний URL mapbox://styles/USER/ID', + 'settings.map3dBuildings': '3D-будинки та рельєф', + 'settings.map3dHint': + 'Нахил + справжні 3D-будинки — працює з усіма стилями, включаючи супутник.', + 'settings.mapHighQuality': 'Режим високої якості', + 'settings.mapHighQualityHint': + 'Згладжування + проекція глобуса для більш чітких країв та реалістичного вигляду світу.', + 'settings.mapHighQualityWarning': + 'Може вплинути на продуктивність на слабких пристроях.', + 'settings.mapTipLabel': 'Порада:', + 'settings.mapTip': + 'Затисніть праву кнопку миші та перетягніть, щоб повернути/нахилити карту. Клік середньою кнопкою — додати місце (права кнопка зарезервована для обертання).', + 'settings.latitude': 'Широта', + 'settings.longitude': 'Довгота', + 'settings.saveMap': 'Зберегти карту', + 'settings.apiKeys': 'API-ключі', + 'settings.mapsKey': 'API-ключ Google Maps', + 'settings.mapsKeyHint': + 'Для пошуку місць. Потрібен Places API (New). Отримайте на console.cloud.google.com', + 'settings.weatherKey': 'API-ключ OpenWeatherMap', + 'settings.weatherKeyHint': + 'Для даних про погоду. Безкоштовно на openweathermap.org/api', + 'settings.keyPlaceholder': 'Введіть ключ...', + 'settings.configured': 'Налаштовано', + 'settings.saveKeys': 'Зберегти ключі', + 'settings.display': 'Відображення', + 'settings.colorMode': 'Кольорова схема', + 'settings.light': 'Світла', + 'settings.dark': 'Темна', + 'settings.auto': 'Авто', + 'settings.language': 'Мова', + 'settings.temperature': 'Одиниця температури', + 'settings.timeFormat': 'Формат часу', + 'settings.blurBookingCodes': 'Приховати коди бронювання', + 'settings.optimizeFromAccommodation': 'Оптимізувати маршрут від житла', + 'settings.optimizeFromAccommodationHint': + 'Під час оптимізації дня починайте маршрут від готелю, у якому ви прокидаєтеся, і завершуйте його тим, у який ви заселяєтеся ввечері.', + 'settings.notifications': 'Сповіщення', + 'settings.notifyTripInvite': 'Запрошення до поїздки', + 'settings.notifyBookingChange': 'Зміни бронювань', + 'settings.notifyTripReminder': 'Нагадування про поїздку', + 'settings.notifyTodoDue': 'Завдання до терміну', + 'settings.notifyVacayInvite': "Запрошення об'єднання Vacay", + 'settings.notifyPhotosShared': 'Спільні фото (Immich)', + 'settings.notifyCollabMessage': 'Повідомлення чату (Collab)', + 'settings.notifyPackingTagged': 'Список речей: призначення', + 'settings.notifyWebhook': 'Webhook-сповіщення', + 'settings.notificationsDisabled': + 'Сповіщення не налаштовані. Попросіть адміністратора ввімкнути сповіщення електронною поштою або webhook.', + 'settings.notificationsActive': 'Активний канал', + 'settings.notificationsManagedByAdmin': + 'Події сповіщень налаштовуються адміністратором.', + 'settings.on': 'Увімк.', + 'settings.off': 'Вимк.', + 'settings.mcp.title': 'Налаштування MCP', + 'settings.mcp.endpoint': 'MCP-ендпоінт', + 'settings.mcp.clientConfig': 'Конфігурація клієнта', + 'settings.mcp.clientConfigHint': + 'Замініть на API-токен зі списку нижче. Шлях до npx може потребувати налаштування для вашої системи (наприклад, C:\\PROGRA~1\\nodejs\\npx.cmd у Windows).', + 'settings.mcp.clientConfigHintOAuth': + 'Замініть і на облікові дані з вищезазначеного клієнта OAuth 2.1. При першому підключенні mcp-remote відкриє браузер для завершення авторизації. Шлях до npx може потребувати налаштування для вашої системи (наприклад, C:\\PROGRA~1\\nodejs\\npx.cmd у Windows).', + 'settings.mcp.copy': 'Копіювати', + 'settings.mcp.copied': 'Скопійовано!', + 'settings.mcp.apiTokens': 'API-токени', + 'settings.mcp.createToken': 'Створити токен', + 'settings.mcp.noTokens': + 'Токенів поки немає. Створіть один для підключення MCP-клієнтів.', + 'settings.mcp.tokenCreatedAt': 'Створено', + 'settings.mcp.tokenUsedAt': 'Використано', + 'settings.mcp.deleteTokenTitle': 'Видалити токен', + 'settings.mcp.deleteTokenMessage': + 'Цей токен перестане працювати одразу. Будь-який MCP-клієнт, що його використовує, втратить доступ.', + 'settings.mcp.modal.createTitle': 'Створити API-токен', + 'settings.mcp.modal.tokenName': 'Назва токена', + 'settings.mcp.modal.tokenNamePlaceholder': + 'наприклад Claude Desktop, Робочий ноутбук', + 'settings.mcp.modal.creating': 'Створення…', + 'settings.mcp.modal.create': 'Створити токен', + 'settings.mcp.modal.createdTitle': 'Токен створено', + 'settings.mcp.modal.createdWarning': + 'Цей токен буде показано лише один раз. Скопіюйте і збережіть його зараз — відновити його не можна.', + 'settings.mcp.modal.done': 'Готово', + 'settings.mcp.toast.created': 'Токен створено', + 'settings.mcp.toast.createError': 'Не вдалося створити токен', + 'settings.mcp.toast.deleted': 'Токен видалено', + 'settings.mcp.toast.deleteError': 'Не вдалося видалити токен', + 'settings.mcp.apiTokensDeprecated': + 'API-токени застаріли і будуть видалені в наступній версії. Будь ласка, використовуйте клієнти OAuth 2.1.', + 'settings.oauth.clients': 'Клієнти OAuth 2.1', + 'settings.oauth.clientsHint': + 'Зареєструйте клієнтів OAuth 2.1, щоб сторонні MCP-застосунки (Claude Web, Cursor тощо) могли підключатися без статичних токенів.', + 'settings.oauth.createClient': 'Новий клієнт', + 'settings.oauth.noClients': 'Немає зареєстрованих клієнтів OAuth.', + 'settings.oauth.clientId': 'ID клієнта', + 'settings.oauth.clientSecret': 'Секрет клієнта', + 'settings.oauth.deleteClient': 'Видалити клієнта', + 'settings.oauth.deleteClientMessage': + 'Цей клієнт і всі активні сесії будуть видалені назавжди. Будь-який застосунок, що його використовує, одразу втратить доступ.', + 'settings.oauth.rotateSecret': 'Оновити секрет', + 'settings.oauth.rotateSecretMessage': + 'Буде згенеровано новий секрет клієнта, а всі існуючі сесії будуть негайно анульовані. Оновіть застосунок перед закриттям цього діалогу.', + 'settings.oauth.rotateSecretConfirm': 'Оновити', + 'settings.oauth.rotateSecretConfirming': 'Оновлення…', + 'settings.oauth.rotateSecretDoneTitle': 'Новий секрет згенеровано', + 'settings.oauth.rotateSecretDoneWarning': + 'Цей секрет відображається лише один раз. Скопіюйте його зараз і оновіть застосунок — всі попередні сесії були анульовані.', + 'settings.oauth.activeSessions': 'Активні сесії OAuth', + 'settings.oauth.sessionScopes': 'Області доступу', + 'settings.oauth.sessionExpires': 'Закінчується', + 'settings.oauth.revoke': 'Відкликати', + 'settings.oauth.revokeSession': 'Відкликати сесію', + 'settings.oauth.revokeSessionMessage': + 'Це негайно відкличе доступ для даної сесії OAuth.', + 'settings.oauth.modal.createTitle': 'Зареєструвати клієнта OAuth', + 'settings.oauth.modal.presets': 'Швидкі налаштування', + 'settings.oauth.modal.clientName': 'Назва застосунку', + 'settings.oauth.modal.clientNamePlaceholder': + 'напр. Claude Web, Мій MCP-застосунок', + 'settings.oauth.modal.redirectUris': 'URI перенаправлення', + 'settings.oauth.modal.redirectUrisPlaceholder': + 'https://your-app.com/callback\nhttps://your-app.com/auth', + 'settings.oauth.modal.redirectUrisHint': + 'Один URI на рядок. Потрібен HTTPS (localhost виключено). Потрібне точне співпадіння.', + 'settings.oauth.modal.scopes': 'Дозволені області доступу', + 'settings.oauth.modal.scopesHint': + 'list_trips і get_trip_summary завжди доступні — область не потрібна. Вони допомагають ШІ знаходити потрібні ID поїздок.', + 'settings.oauth.modal.selectAll': 'Вибрати все', + 'settings.oauth.modal.deselectAll': 'Зняти вибір', + 'settings.oauth.modal.creating': 'Реєстрація…', + 'settings.oauth.modal.create': 'Зареєструвати клієнта', + 'settings.oauth.modal.createdTitle': 'Клієнт зареєстровано', + 'settings.oauth.modal.createdWarning': + 'Секрет клієнта показується лише один раз. Скопіюйте його зараз — його не можна буде відновити.', + 'settings.oauth.toast.createError': 'Не вдалося зареєструвати клієнта OAuth', + 'settings.oauth.toast.deleted': 'Клієнт OAuth видалено', + 'settings.oauth.toast.deleteError': 'Не вдалося видалити клієнта OAuth', + 'settings.oauth.toast.revoked': 'Сесію відкликано', + 'settings.oauth.toast.revokeError': 'Не вдалося відкликати сесію', + 'settings.oauth.toast.rotateError': 'Не вдалося оновити секрет клієнта', + 'settings.account': 'Обліковий запис', + 'settings.about': 'Про застосунок', + 'settings.about.reportBug': 'Повідомити про помилку', + 'settings.about.reportBugHint': 'Знайшли проблему? Повідомте нам', + 'settings.about.featureRequest': 'Запропонувати функцію', + 'settings.about.featureRequestHint': 'Запропонуйте нову функцію', + 'settings.about.wikiHint': 'Документація та керівництва', + 'settings.about.supporters.badge': 'Щомісячні спонсори', + 'settings.about.supporters.title': 'Спутники TREK', + 'settings.about.supporters.subtitle': + 'Поки ти плануєш наступний маршрут, ці люди разом зі мною планують майбутнє TREK. Їхній щомісячний внесок йде безпосередньо в розробку та реальні витрачені години — щоб TREK залишався Open Source.', + 'settings.about.supporters.since': 'спонсор з {date}', + 'settings.about.supporters.tierEmpty': 'Стань першим', + 'settings.about.supporter.tier.noReturnTicket': 'No Return Ticket', + 'settings.about.supporter.tier.lostLuggageVip': 'Lost Luggage VIP', + 'settings.about.supporter.tier.businessClassDreamer': + 'Business Class Dreamer', + 'settings.about.supporter.tier.budgetTraveller': 'Budget Traveller', + 'settings.about.supporter.tier.hostelBunkmate': 'Hostel Bunkmate', + 'settings.about.description': + 'TREK — це self-hosted планувальник подорожей, який допомагає організувати поїздки від першої ідеї до останнього спогаду. Планування по днях, бюджет, списки речей, фото та багато іншого — все в одному місці, на вашому власному сервері.', + 'settings.about.madeWith': 'Зроблено з', + 'settings.about.madeBy': 'Морісом і зростаючою open-source спільнотою.', + 'settings.username': "Ім'я користувача", + 'settings.email': 'Ел. пошта', + 'settings.role': 'Роль', + 'settings.roleAdmin': 'Адміністратор', + 'settings.oidcLinked': 'Пов’язаний з', + 'settings.changePassword': 'Змінити пароль', + 'settings.mustChangePassword': + 'Ви повинні змінити пароль перед продовженням. Будь ласка, встановіть новий пароль нижче.', + 'settings.currentPassword': 'Поточний пароль', + 'settings.currentPasswordRequired': 'Поточний пароль обов’язковий', + 'settings.newPassword': 'Новий пароль', + 'settings.confirmPassword': 'Підтвердіть новий пароль', + 'settings.updatePassword': 'Оновити пароль', + 'settings.passwordRequired': 'Введіть поточний та новий паролі', + 'settings.passwordTooShort': 'Пароль повинен містити не менше 8 символів', + 'settings.passwordMismatch': 'Паролі не збігаються', + 'settings.passwordWeak': + 'Пароль повинен містити великі й малі літери, цифру та спеціальний символ', + 'settings.passwordChanged': 'Пароль успішно змінено', + 'settings.deleteAccount': 'Видалити акаунт', + 'settings.deleteAccountTitle': 'Видалити ваш акаунт?', + 'settings.deleteAccountWarning': + 'Ваш акаунт і всі поїздки, місця та файли будуть безповоротно видалені. Цю дію неможливо скасувати.', + 'settings.deleteAccountConfirm': 'Видалити безповоротно', + 'settings.deleteBlockedTitle': 'Видалення неможливе', + 'settings.deleteBlockedMessage': + 'Ви єдиний адміністратор. Призначте іншого користувача адміністратором перед видаленням свого акаунта.', + 'settings.roleUser': 'Користувач', + 'settings.saveProfile': 'Зберегти профіль', + 'settings.mfa.title': 'Двофакторна аутентифікація (2FA)', + 'settings.mfa.description': + 'Додає другий крок при вході. Використовуйте додаток-аутентифікатор (Google Authenticator, Authy та ін.).', + 'settings.mfa.requiredByPolicy': + 'Адміністратор вимагає двофакторної аутентифікації. Налаштуйте додаток-аутентифікатор нижче, перш ніж продовжити.', + 'settings.mfa.backupTitle': 'Резервні коди', + 'settings.mfa.backupDescription': + 'Використовуйте ці одноразові коди, якщо втратите доступ до додатку-аутентифікатора.', + 'settings.mfa.backupWarning': + 'Збережіть їх зараз. Кожен код можна використати лише один раз.', + 'settings.mfa.backupCopy': 'Скопіювати коди', + 'settings.mfa.backupDownload': 'Завантажити TXT', + 'settings.mfa.backupPrint': 'Друк / PDF', + 'settings.mfa.backupCopied': 'Резервні коди скопійовано', + 'settings.mfa.enabled': '2FA увімкнено для вашого акаунта.', + 'settings.mfa.disabled': '2FA не увімкнено.', + 'settings.mfa.setup': 'Налаштувати автентифікатор', + 'settings.mfa.scanQr': 'Відскануйте QR-код додатком або введіть ключ вручну.', + 'settings.mfa.secretLabel': 'Секретний ключ (ручний ввід)', + 'settings.mfa.codePlaceholder': '6-значний код', + 'settings.mfa.enable': 'Увімкнути 2FA', + 'settings.mfa.cancelSetup': 'Скасувати', + 'settings.mfa.disableTitle': 'Вимкнути 2FA', + 'settings.mfa.disableHint': + 'Введіть пароль акаунта та поточний код з автентифікатора.', + 'settings.mfa.disable': 'Вимкнути 2FA', + 'settings.mfa.toastEnabled': 'Двофакторна автентифікація увімкнена', + 'settings.mfa.toastDisabled': 'Двофакторна автентифікація вимкнена', + 'settings.mfa.demoBlocked': 'Недоступно в демо-режимі', + 'settings.toast.mapSaved': 'Налаштування карти збережено', + 'settings.toast.keysSaved': 'API-ключі збережено', + 'settings.toast.displaySaved': 'Налаштування відображення збережено', + 'settings.toast.profileSaved': 'Профіль збережено', + 'settings.uploadAvatar': 'Завантажити фото профілю', + 'settings.removeAvatar': 'Видалити фото профілю', + 'settings.avatarUploaded': 'Фото профілю оновлено', + 'settings.avatarRemoved': 'Фото профілю видалено', + 'settings.avatarError': 'Помилка завантаження', + 'settings.bookingLabels': 'Підписи маршрутів бронювань', + 'settings.bookingLabelsHint': + 'Показує назви станцій / аеропортів на карті. Якщо вимкнено, показується лише значок.', + 'settings.notifyVersionAvailable': 'Доступна нова версія', + 'settings.notificationPreferences.noChannels': + 'Канали сповіщень не налаштовані. Попросіть адміністратора налаштувати сповіщення електронною поштою або через webhook.', + 'settings.webhookUrl.label': 'URL вебхука', + 'settings.webhookUrl.placeholder': 'https://discord.com/api/webhooks/...', + 'settings.webhookUrl.hint': + 'Введіть URL вашого вебхука Discord, Slack або власного для отримання сповіщень.', + 'settings.webhookUrl.saved': 'URL вебхука збережено', + 'settings.webhookUrl.test': 'Тест', + 'settings.webhookUrl.testSuccess': 'Тестовий вебхук успішно надіслано', + 'settings.webhookUrl.testFailed': 'Помилка тестового вебхука', + 'settings.ntfyUrl.topicLabel': 'Тема Ntfy', + 'settings.ntfyUrl.topicPlaceholder': 'my-trek-alerts', + 'settings.ntfyUrl.serverLabel': 'URL сервера Ntfy (необов’язково)', + 'settings.ntfyUrl.serverPlaceholder': 'https://ntfy.sh', + 'settings.ntfyUrl.hint': + 'Введіть тему Ntfy для отримання push-сповіщень. Залиште поле сервера пустим, щоб використовувати налаштування за замовчуванням, задані адміністратором.', + 'settings.ntfyUrl.tokenLabel': 'Токен доступу (необов’язково)', + 'settings.ntfyUrl.tokenHint': 'Потрібно для тем, захищених паролем.', + 'settings.ntfyUrl.saved': 'Налаштування Ntfy збережені', + 'settings.ntfyUrl.test': 'Тест', + 'settings.ntfyUrl.testSuccess': 'Тестове сповіщення Ntfy успішно надіслано', + 'settings.ntfyUrl.testFailed': 'Помилка надсилання тестового сповіщення Ntfy', + 'settings.ntfyUrl.tokenCleared': 'Токен доступу очищено', + 'settings.notificationPreferences.inapp': 'In-App', + 'settings.notificationPreferences.webhook': 'Webhook', + 'settings.notificationPreferences.email': 'Email', + 'settings.notificationPreferences.ntfy': 'Ntfy', + 'settings.oauth.modal.machineClient': + 'Машинний клієнт (без входу через браузер)', + 'settings.oauth.modal.machineClientHint': + 'Використовуйте надання client_credentials — URI перенаправлення не потрібні. Токен видається безпосередньо через client_id + client_secret і діє від вашого імені в межах вибраних областей.', + 'settings.oauth.modal.machineClientUsage': + 'Отримати токен: POST /oauth/token з grant_type=client_credentials, client_id і client_secret. Без браузера, без токена оновлення.', + 'settings.oauth.badge.machine': 'машина', + "settings.currency": "Currency", + "settings.currencyHint": "All amounts in Costs are converted to and shown in this currency.", + 'settings.passkey.title': 'Passkeys', + 'settings.passkey.description': + 'Входьте швидше та з захистом від фішингу за допомогою passkey — відбитка пальця, обличчя, PIN-коду або апаратного ключа. Ваш пароль залишається як резервний варіант.', + 'settings.passkey.notConfigured': + 'Passkeys увімкнено, але цей сервер ще не повністю налаштовано. Попросіть адміністратора вказати домен WebAuthn.', + 'settings.passkey.add': 'Додати passkey', + 'settings.passkey.addTitle': 'Додати passkey', + 'settings.passkey.passwordPrompt': + 'Підтвердіть поточний пароль, а потім дотримуйтесь підказок на вашому пристрої.', + 'settings.passkey.passwordRequired': 'Потрібен ваш поточний пароль.', + 'settings.passkey.namePlaceholder': 'Назва (необов’язково, напр. "iPhone")', + 'settings.passkey.addedToast': 'Passkey додано', + 'settings.passkey.added': 'Додано', + 'settings.passkey.addError': 'Не вдалося додати passkey', + 'settings.passkey.cancelled': 'Налаштування passkey скасовано', + 'settings.passkey.deleted': 'Passkey видалено', + 'settings.passkey.deleteConfirm': + 'Видалити цей passkey? Підтвердіть паролем.', + 'settings.passkey.rename': 'Перейменувати', + 'settings.passkey.defaultName': 'Passkey', + 'settings.passkey.synced': 'Синхронізовано', + 'settings.passkey.deviceBound': 'Цей пристрій', + 'settings.passkey.lastUsed': 'Останнє використання', + 'settings.passkey.neverUsed': 'Не використовувався', + 'settings.mapPoiPill': 'Досліджуйте місця на карті', + 'settings.mapPoiPillHint': 'Показувати на карті подорожі плашку категорій, щоб знаходити поблизу ресторани, готелі та інше з OpenStreetMap.', + 'settings.airtrail.title': 'AirTrail', + 'settings.airtrail.hint': 'Підключіть свій самостійно розміщений AirTrail, щоб імпортувати та синхронізувати рейси. Створіть API-ключ в AirTrail у розділі Налаштування → Безпека.', + 'settings.airtrail.url': 'URL екземпляра', + 'settings.airtrail.apiKey': 'API-ключ', + 'settings.airtrail.apiKeyPlaceholder': 'Bearer API-ключ', + 'settings.airtrail.apiKeyHint': 'Згенеровано в AirTrail у розділі Налаштування → Безпека. Зберігається в зашифрованому вигляді.', + 'settings.airtrail.allowInsecureTls': 'Дозволити самопідписані сертифікати', + 'settings.airtrail.allowInsecureTlsHint': 'Вмикайте лише для довіреного екземпляра у вашій власній мережі.', + 'settings.airtrail.connected': 'Підключено', + 'settings.airtrail.notConnected': 'Не підключено', + 'settings.airtrail.toast.saved': 'Підключення AirTrail збережено', + 'settings.airtrail.toast.saveError': 'Не вдалося зберегти підключення', + 'settings.airtrail.test.button': 'Перевірити підключення', + 'settings.airtrail.test.success': 'Підключено — знайдено {count} рейс(ів)', + 'settings.airtrail.test.failed': 'Не вдалося підключитися', +}; + +export default settings; diff --git a/shared/src/i18n/uk/share.ts b/shared/src/i18n/uk/share.ts new file mode 100644 index 0000000000000000000000000000000000000000..7ca7befd1e177fe4e3349dc07332e0ed8f25d93c --- /dev/null +++ b/shared/src/i18n/uk/share.ts @@ -0,0 +1,16 @@ +import type { TranslationStrings } from '../types'; + +const share: TranslationStrings = { + 'share.linkTitle': 'Публічне посилання', + 'share.linkHint': + 'Створіть посилання, за яким будь-хто зможе переглянути цю поїздку без входу. Тільки читання — редагувати не можна.', + 'share.createLink': 'Створити посилання', + 'share.deleteLink': 'Видалити посилання', + 'share.createError': 'Не вдалося створити посилання', + 'share.permMap': 'Карта і план', + 'share.permBookings': 'Бронювання', + 'share.permPacking': 'Речі', + 'share.permBudget': 'Бюджет', + 'share.permCollab': 'Чат', +}; +export default share; diff --git a/shared/src/i18n/uk/shared.ts b/shared/src/i18n/uk/shared.ts new file mode 100644 index 0000000000000000000000000000000000000000..397171484f811c8e1d9b29a05329a78b76e93f30 --- /dev/null +++ b/shared/src/i18n/uk/shared.ts @@ -0,0 +1,21 @@ +import type { TranslationStrings } from '../types'; + +const shared: TranslationStrings = { + 'shared.expired': 'Посилання прострочено або недійсне', + 'shared.expiredHint': 'Це посилання на поїздку більше не активне.', + 'shared.readOnly': 'Тільки для читання', + 'shared.tabPlan': 'План', + 'shared.tabBookings': 'Бронювання', + 'shared.tabPacking': 'Багаж', + 'shared.tabBudget': 'Бюджет', + 'shared.tabChat': 'Чат', + 'shared.days': 'днів', + 'shared.places': 'місць', + 'shared.other': 'Інше', + 'shared.totalBudget': 'Загальний бюджет', + 'shared.messages': 'повідомлень', + 'shared.sharedVia': 'Поділено через', + 'shared.confirmed': 'Підтверджено', + 'shared.pending': 'Очікує', +}; +export default shared; diff --git a/shared/src/i18n/uk/stats.ts b/shared/src/i18n/uk/stats.ts new file mode 100644 index 0000000000000000000000000000000000000000..bfd1cfb54d24620b414510889b5cbbcbe8d4cd92 --- /dev/null +++ b/shared/src/i18n/uk/stats.ts @@ -0,0 +1,13 @@ +import type { TranslationStrings } from '../types'; + +const stats: TranslationStrings = { + 'stats.countries': 'Країни', + 'stats.cities': 'Міста', + 'stats.trips': 'Поїздки', + 'stats.places': 'Місця', + 'stats.worldProgress': 'Прогрес по світу', + 'stats.visited': 'відвідано', + 'stats.remaining': 'залишилось', + 'stats.visitedCountries': 'Відвідані країни', +}; +export default stats; diff --git a/shared/src/i18n/uk/system_notice.ts b/shared/src/i18n/uk/system_notice.ts new file mode 100644 index 0000000000000000000000000000000000000000..5477b8cb7b6eb2b07a5bcb216d9f0107ce891872 --- /dev/null +++ b/shared/src/i18n/uk/system_notice.ts @@ -0,0 +1,59 @@ +import type { TranslationStrings } from '../types'; + +const system_notice: TranslationStrings = { + 'system_notice.welcome_v1.title': 'Ласкаво просимо в TREK', + 'system_notice.welcome_v1.body': + 'Ваш універсальний планувальник подорожей. Створюйте маршрути, діліться поїздками з друзями та залишайтесь організованими — онлайн та офлайн.', + 'system_notice.welcome_v1.cta_label': 'Спланувати поїздку', + 'system_notice.welcome_v1.hero_alt': + 'Живописне місце призначення з інтерфейсом TREK', + 'system_notice.welcome_v1.highlight_plan': + 'Детальні плани по днях для будь-яких поїздок', + 'system_notice.welcome_v1.highlight_share': 'Спільне планування', + 'system_notice.welcome_v1.highlight_offline': 'Працює офлайн на мобільному', + 'system_notice.dev_test_modal.title': '[Dev] Test notice', + 'system_notice.dev_test_modal.body': 'This is a dev-only test notice.', + 'system_notice.pager.prev': 'Попереднє повідомлення', + 'system_notice.pager.next': 'Наступне повідомлення', + 'system_notice.pager.counter': '{current} / {total}', + 'system_notice.pager.goto': 'Перейти до повідомлення {n}', + 'system_notice.pager.position': 'Повідомлення {current} із {total}', + 'system_notice.v3_photos.title': 'Фото переміщено у версії 3.0', + 'system_notice.v3_photos.body': + 'Вкладку **Фото** в Планувальнику подорожей видалено. Ваші фото в безпеці — TREK ніколи не змінював вашу бібліотеку Immich або Synology.\n\nФото тепер доступні у доповненні **Journey**. Journey необов’язковий — якщо він ще недоступний, попросіть адміністратора включити його в розділі Адмін → Додатки.', + 'system_notice.v3_journey.title': 'Знайомтесь із Journey', + 'system_notice.v3_journey.body': + 'Документуйте подорожі як історії з хронологіями, фотогалереями та інтерактивними картами.', + 'system_notice.v3_journey.cta_label': 'Відкрити Journey', + 'system_notice.v3_journey.highlight_timeline': + 'Щоденна хронологія та галерея', + 'system_notice.v3_journey.highlight_photos': 'Імпорт з Immich або Synology', + 'system_notice.v3_journey.highlight_share': 'Спільний доступ — без входу', + 'system_notice.v3_journey.highlight_export': 'Експорт у PDF-фотокнигу', + 'system_notice.v3_features.title': 'Ще більше нового у версії 3.0', + 'system_notice.v3_features.body': + 'Декілька інших важливих нововведень у цьому релізі.', + 'system_notice.v3_features.highlight_dashboard': + 'Перероблена панель у mobile-first стилі', + 'system_notice.v3_features.highlight_offline': 'Повний офлайн-режим як PWA', + 'system_notice.v3_features.highlight_search': + 'Автодоповнення пошуку місць у реальному часі', + 'system_notice.v3_features.highlight_import': 'Імпорт місць з KMZ/KML-файлів', + 'system_notice.v3_mcp.title': 'MCP: оновлення OAuth 2.1', + 'system_notice.v3_mcp.body': + 'Інтеграція MCP була повністю перероблена. OAuth 2.1 тепер є рекомендованим методом автентифікації. Статичні токени (trek_…) застаріли і будуть видалені в майбутній версії.', + 'system_notice.v3_mcp.highlight_oauth': + 'OAuth 2.1 рекомендовано (mcp-remote)', + 'system_notice.v3_mcp.highlight_scopes': '24 детальні області дозволів', + 'system_notice.v3_mcp.highlight_deprecated': + 'Статичні токени trek_ застаріли', + 'system_notice.v3_mcp.highlight_tools': 'Розширений набір інструментів', + 'system_notice.v3_thankyou.title': 'Особливе слово від мене', + 'system_notice.v3_thankyou.body': + 'Перш ніж продовжити — хочу зупинитися на мить.\n\nTREK починався як сторонній проєкт, який я створив для власних поїздок. Я ніколи не думав, що він виросте в щось, чому 4 000 з вас довіряють планування своїх пригод. Кожна зірочка, кожен issue, кожен запит на фічу — я читаю їх усі, і саме вони підтримують мене у пізні ночі між основною роботою та університетом.\n\nХочу, щоб ви знали: TREK завжди буде open source, завжди self-hosted, завжди вашим. Жодного стеження, жодних підписок, жодних підводних каменів. Просто інструмент, створений людиною, яка любить подорожувати так само, як і ви.\n\nОсоблива подяка [jubnl](https://github.com/jubnl) — ти став неймовірним соратником. Багато з того, що робить версію 3.0 чудовою, несе твій відбиток. Дякую, що повірив у цей проєкт, коли він ще був сирим.\n\nІ кожному з вас, хто повідомив про помилку, переклав рядок, поділився TREK з другом або просто використовував його для планування поїздки — **дякую**. Ви — причина, чому все це існує.\n\nЗа багато нових пригод разом.\n\n— Maurice\n\n---\n\n[Приєднуйтесь до спільноти в Discord](https://discord.gg/7Q6M6jDwzf)\n\nЯкщо TREK робить ваші подорожі кращими, [невелика кава](https://ko-fi.com/mauriceboe) завжди допомагає тримати світло ввімкненим.', + 'system_notice.v3014_whitespace_collision.title': + 'Потрібна дія: конфлікт облікового запису користувача', + 'system_notice.v3014_whitespace_collision.body': + 'Оновлення 3.0.14 виявило один або кілька конфліктів імен користувачів або електронних адрес, спричинених початковими або кінцевими пробілами в збережених облікових записах. Уражені облікові записи було автоматично перейменовано. Перевірте журнали сервера на рядки, що починаються з **[migration] WHITESPACE COLLISION**, щоб визначити, які облікові записи потребують перевірки.', +}; +export default system_notice; diff --git a/shared/src/i18n/uk/todo.ts b/shared/src/i18n/uk/todo.ts new file mode 100644 index 0000000000000000000000000000000000000000..3cea20b249745df8fa61ca9335b0d845037a3172 --- /dev/null +++ b/shared/src/i18n/uk/todo.ts @@ -0,0 +1,40 @@ +import type { TranslationStrings } from '../types'; + +const todo: TranslationStrings = { + 'todo.subtab.packing': 'Список речей', + 'todo.subtab.todo': 'Задачі', + 'todo.completed': 'виконано', + 'todo.filter.all': 'Усі', + 'todo.filter.open': 'Відкриття', + 'todo.filter.done': 'Виконані', + 'todo.uncategorized': 'Без категорії', + 'todo.namePlaceholder': 'Назва завдання', + 'todo.descriptionPlaceholder': 'Опис (необов’язково)', + 'todo.unassigned': 'Не призначено', + 'todo.noCategory': 'Без категорії', + 'todo.hasDescription': 'Є опис', + 'todo.addItem': 'Нова задача', + 'todo.sidebar.sortBy': 'Сорзувати за', + 'todo.priority': 'Пріоритет', + 'todo.newCategoryLabel': 'нова', + 'todo.newCategory': 'Назва категорії', + 'todo.addCategory': 'Додати категорію', + 'todo.newItem': 'Нова задача', + 'todo.empty': 'Задач поки немає. Додайте задачу, щоб почати!', + 'todo.filter.my': 'Мої задачі', + 'todo.filter.overdue': 'Просрочені', + 'todo.sidebar.tasks': 'Задачі', + 'todo.sidebar.categories': 'Категорії', + 'todo.detail.title': 'Задача', + 'todo.detail.description': 'Опис', + 'todo.detail.category': 'Категорія', + 'todo.detail.dueDate': 'Строк виконання', + 'todo.detail.assignedTo': 'Назначено', + 'todo.detail.delete': 'Видалити', + 'todo.detail.save': 'Зберегти зміни', + 'todo.detail.create': 'Створити задачу', + 'todo.detail.priority': 'Пріоритет', + 'todo.detail.noPriority': 'Немає', + 'todo.sortByPrio': 'Пріоритет', +}; +export default todo; diff --git a/shared/src/i18n/uk/transport.ts b/shared/src/i18n/uk/transport.ts new file mode 100644 index 0000000000000000000000000000000000000000..6a3915e1a3557cef6a5454fb0fab38107489e350 --- /dev/null +++ b/shared/src/i18n/uk/transport.ts @@ -0,0 +1,10 @@ +import type { TranslationStrings } from '../types'; + +const transport: TranslationStrings = { + 'transport.addTransport': 'Додати транспорт', + 'transport.modalTitle.create': 'Додати транспорт', + 'transport.modalTitle.edit': 'Змінити транспорт', + 'transport.title': 'Транспорт', + 'transport.addManual': 'Ручний транспорт', +}; +export default transport; diff --git a/shared/src/i18n/uk/trip.ts b/shared/src/i18n/uk/trip.ts new file mode 100644 index 0000000000000000000000000000000000000000..37f0cd8c31192477a929a7de8f6a183580c5d92d --- /dev/null +++ b/shared/src/i18n/uk/trip.ts @@ -0,0 +1,31 @@ +import type { TranslationStrings } from '../types'; + +const trip: TranslationStrings = { + 'trip.tabs.plan': 'План', + 'trip.tabs.transports': 'Транспорт', + 'trip.tabs.reservations': 'Бронювання', + 'trip.tabs.reservationsShort': 'Броні', + 'trip.tabs.packing': 'Список речей', + 'trip.tabs.packingShort': 'Речі', + 'trip.tabs.lists': 'Списки', + 'trip.tabs.listsShort': 'Списки', + 'trip.tabs.budget': "Costs", + 'trip.tabs.files': 'Файли', + 'trip.loading': 'Завантаження поїздки...', + 'trip.loadingPhotos': 'Завантаження фото місць...', + 'trip.mobilePlan': 'План', + 'trip.mobilePlaces': 'Місця', + 'trip.toast.placeUpdated': 'Місце оновлено', + 'trip.toast.placeAdded': 'Місце додано', + 'trip.toast.placeDeleted': 'Місце видалено', + 'trip.toast.selectDay': 'Спочатку виберіть день', + 'trip.toast.assignedToDay': 'Місце призначено на день', + 'trip.toast.reorderError': 'Помилка зміни порядку', + 'trip.toast.reservationUpdated': 'Бронювання оновлено', + 'trip.toast.reservationAdded': 'Бронювання додано', + 'trip.toast.deleted': 'Видалено', + 'trip.confirm.deletePlace': 'Ви впевнені, що хочете видалити це місце?', + 'trip.confirm.deletePlaces': 'Видалити {count} місць?', + 'trip.toast.placesDeleted': '{count} місць видалено', +}; +export default trip; diff --git a/shared/src/i18n/uk/trips.ts b/shared/src/i18n/uk/trips.ts new file mode 100644 index 0000000000000000000000000000000000000000..3a0f17320c8cf76391eac6d9f53c81082bc18a2b --- /dev/null +++ b/shared/src/i18n/uk/trips.ts @@ -0,0 +1,17 @@ +import type { TranslationStrings } from '../types'; + +const trips: TranslationStrings = { + 'trips.memberRemoved': '{username} видалений', + 'trips.memberRemoveError': 'Не вдалося видалити', + 'trips.memberAdded': '{username} доданий', + 'trips.memberAddError': 'Не вдалося додати', + 'trips.reminder': 'Нагадування', + 'trips.reminderNone': 'Немає', + 'trips.reminderDay': 'день', + 'trips.reminderDays': 'днів', + 'trips.reminderCustom': 'Інше', + 'trips.reminderDaysBefore': "днів до від'їзду", + 'trips.reminderDisabledHint': + 'Нагадування про поїздки вимкнено. Увімкніть їх в Адмін > Налаштування > Сповіщення.', +}; +export default trips; diff --git a/shared/src/i18n/uk/undo.ts b/shared/src/i18n/uk/undo.ts new file mode 100644 index 0000000000000000000000000000000000000000..3b81c22bda05ff9ce5993c2a14b3ff7dca471ef0 --- /dev/null +++ b/shared/src/i18n/uk/undo.ts @@ -0,0 +1,22 @@ +import type { TranslationStrings } from '../types'; + +const undo: TranslationStrings = { + 'undo.button': 'Відмінити', + 'undo.tooltip': 'Відмінити: {action}', + 'undo.assignPlace': 'Місце додано до дня', + 'undo.removeAssignment': 'Місце вилучено з дня', + 'undo.reorder': 'Місця переставлено', + 'undo.optimize': 'Маршрут оптимізовано', + 'undo.deletePlace': 'Місце видалено', + 'undo.deletePlaces': 'Місця видалено', + 'undo.moveDay': 'Місце переміщено в інший день', + 'undo.lock': 'Блокування місця змінено', + 'undo.importGpx': 'Імпорт GPX', + 'undo.importKeyholeMarkup': 'Імпорт KMZ/KML', + 'undo.importGoogleList': 'Імпорт з Google Maps', + 'undo.importNaverList': 'Імпорт з Naver Maps', + 'undo.addPlace': 'Місце додано', + 'undo.done': 'Відмінено: {action}', + 'undo.importBooking': 'Імпорт підтвердження бронювання', +}; +export default undo; diff --git a/shared/src/i18n/uk/vacay.ts b/shared/src/i18n/uk/vacay.ts new file mode 100644 index 0000000000000000000000000000000000000000..3990d6149b2d9503f227522396f878a2671832f4 --- /dev/null +++ b/shared/src/i18n/uk/vacay.ts @@ -0,0 +1,107 @@ +import type { TranslationStrings } from '../types'; + +const vacay: TranslationStrings = { + 'vacay.subtitle': 'Плануйте й керуйте днями відпустки', + 'vacay.settings': 'Налаштування', + 'vacay.year': 'Рік', + 'vacay.addYear': 'Додати наступний рік', + 'vacay.addPrevYear': 'Додати попередній рік', + 'vacay.removeYear': 'Видалити рік', + 'vacay.removeYearConfirm': 'Видалити {year}?', + 'vacay.removeYearHint': + 'Усі записи про відпустку і корпоративні вихідні за цей рік будуть безповоротно видалені.', + 'vacay.remove': 'Видалити', + 'vacay.persons': 'Люди', + 'vacay.noPersons': 'Ніхто не доданий', + 'vacay.addPerson': 'Додати людину', + 'vacay.editPerson': 'Редагувати', + 'vacay.removePerson': 'Видалити людину', + 'vacay.removePersonConfirm': 'Видалити {name}?', + 'vacay.removePersonHint': + 'Усі записи про відпустку цієї людини будуть безповоротно видалені.', + 'vacay.personName': 'Ім’я', + 'vacay.personNamePlaceholder': 'Введіть ім’я', + 'vacay.color': 'Колір', + 'vacay.add': 'Додати', + 'vacay.legend': 'Легенда', + 'vacay.publicHoliday': 'Державне свято', + 'vacay.companyHoliday': 'Корпоративний вихідний', + 'vacay.weekend': 'Вихідні', + 'vacay.modeVacation': 'Відпустка', + 'vacay.modeCompany': 'Корпоративний вихідний', + 'vacay.entitlement': 'Право на відпустку', + 'vacay.entitlementDays': 'Дні', + 'vacay.used': 'Використано', + 'vacay.remaining': 'Залишилося', + 'vacay.carriedOver': 'із {year}', + 'vacay.blockWeekends': 'Блокувати вихідні', + 'vacay.blockWeekendsHint': + 'Заборонити записи про відпустку в суботу та неділю', + 'vacay.weekendDays': 'Вихідні дні', + 'vacay.mon': 'Пн', + 'vacay.tue': 'Вт', + 'vacay.wed': 'Ср', + 'vacay.thu': 'Чт', + 'vacay.fri': 'Пт', + 'vacay.sat': 'Сб', + 'vacay.sun': 'Нд', + 'vacay.publicHolidays': 'Державні свята', + 'vacay.publicHolidaysHint': 'Позначати державні свята в календарі', + 'vacay.selectCountry': 'Виберіть країну', + 'vacay.selectRegion': 'Виберіть регіон (необов’язково)', + 'vacay.companyHolidays': 'Корпоративні вихідні', + 'vacay.companyHolidaysHint': 'Дозволити позначати корпоративні вихідні', + 'vacay.companyHolidaysNoDeduct': + 'Корпоративні вихідні не віднімаються від днів відпустки.', + 'vacay.weekStart': 'Тиждень починається з', + 'vacay.weekStartHint': + 'Виберіть, чи тиждень починається з понеділка чи неділі', + 'vacay.carryOver': 'Переносити', + 'vacay.carryOverHint': + 'Автоматично переносити залишкові дні відпустки на наступний рік', + 'vacay.sharing': 'Спільний доступ', + 'vacay.sharingHint': + 'Поділіться планом відпустки з іншими користувачами TREK', + 'vacay.owner': 'Власник', + 'vacay.shareEmailPlaceholder': 'Ел. пошта користувача TREK', + 'vacay.shareSuccess': 'План успішно надано', + 'vacay.shareError': 'Не вдалося поділитися планом', + 'vacay.dissolve': 'Розділити об’єднання', + 'vacay.dissolveHint': + 'Знову розділити календарі. Ваші записи будуть збережені.', + 'vacay.dissolveAction': 'Розділити', + 'vacay.dissolved': 'Календар розділено', + 'vacay.fusedWith': 'Об’єднано з', + 'vacay.you': 'ви', + 'vacay.noData': 'Немає даних', + 'vacay.changeColor': 'Змінити колір', + 'vacay.inviteUser': 'Запросити користувача', + 'vacay.inviteHint': + 'Запросіть іншого користувача TREK для спільного календаря відпусток.', + 'vacay.selectUser': 'Виберіть користувача', + 'vacay.sendInvite': 'Надіслати запрошення', + 'vacay.inviteSent': 'Запрошення надіслано', + 'vacay.inviteError': 'Не вдалося надіслати запрошення', + 'vacay.pending': 'очікування', + 'vacay.noUsersAvailable': 'Немає доступних користувачів', + 'vacay.accept': 'Прийняти', + 'vacay.decline': 'Відхилити', + 'vacay.acceptFusion': 'Прийняти й об’єднати', + 'vacay.inviteTitle': 'Запит на об’єднання', + 'vacay.inviteWantsToFuse': 'хоче об’єднати календар відпусток з вами.', + 'vacay.fuseInfo1': + 'Ви обидва бачитимете всі записи про відпустки в одному спільному календарі.', + 'vacay.fuseInfo2': + 'Обидві сторони можуть створювати та редагувати записи одна для одної.', + 'vacay.fuseInfo3': + 'Обидві сторони можуть видаляти записи та змінювати право на відпустку.', + 'vacay.fuseInfo4': + 'Налаштування, такі як свята та корпоративні вихідні, стають спільними.', + 'vacay.fuseInfo5': + 'Об’єднання можна скасувати будь-коли з будь-якого боку. Ваші записи будуть збережені.', + 'vacay.addCalendar': 'Добавить календарь', + 'vacay.calendarColor': 'Колір', + 'vacay.calendarLabel': 'Назва', + 'vacay.noCalendars': 'Немає календарів', +}; +export default vacay; diff --git a/shared/src/i18n/zh-TW/admin.ts b/shared/src/i18n/zh-TW/admin.ts new file mode 100644 index 0000000000000000000000000000000000000000..2e25ef1e07e40ea793cd52946f40589206f9c8c6 --- /dev/null +++ b/shared/src/i18n/zh-TW/admin.ts @@ -0,0 +1,359 @@ +import type { TranslationStrings } from '../types'; + +const admin: TranslationStrings = { + 'admin.notifications.title': '通知', + 'admin.notifications.hint': '選擇一個通知渠道。一次只能啟用一個。', + 'admin.notifications.none': '已停用', + 'admin.notifications.email': '電子郵件 (SMTP)', + 'admin.notifications.webhook': 'Webhook', + 'admin.notifications.save': '儲存通知設定', + 'admin.notifications.saved': '通知設定已儲存', + 'admin.notifications.testWebhook': '傳送測試 Webhook', + 'admin.notifications.testWebhookSuccess': '測試 Webhook 傳送成功', + 'admin.notifications.testWebhookFailed': '測試 Webhook 傳送失敗', + 'admin.notifications.emailPanel.title': '電子郵件 (SMTP)', + 'admin.notifications.webhookPanel.title': 'Webhook', + 'admin.notifications.inappPanel.title': '應用程式內通知', + 'admin.notifications.inappPanel.hint': + '應用程式內通知始終啟用,無法全域性停用。', + 'admin.notifications.adminWebhookPanel.title': '管理員 Webhook', + 'admin.notifications.adminWebhookPanel.hint': + '此 Webhook 專用於管理員通知(例如版本提醒)。它與每位使用者的 Webhook 分開,設定後始終會觸發。', + 'admin.notifications.adminWebhookPanel.saved': '管理員 Webhook URL 已儲存', + 'admin.notifications.adminWebhookPanel.testSuccess': '測試 Webhook 傳送成功', + 'admin.notifications.adminWebhookPanel.testFailed': '測試 Webhook 傳送失敗', + 'admin.notifications.adminWebhookPanel.alwaysOnHint': + '配置 URL 後,管理員 Webhook 始終觸發', + 'admin.notifications.ntfy': 'Ntfy', + 'admin.ntfy.hint': + '允許使用者設定自己的 ntfy 主題以接收推播通知。在下方設定預設伺服器以預先填入使用者設定。', + 'admin.notifications.testNtfy': '傳送測試 Ntfy', + 'admin.notifications.testNtfySuccess': '測試 Ntfy 傳送成功', + 'admin.notifications.testNtfyFailed': '測試 Ntfy 失敗', + 'admin.notifications.adminNtfyPanel.title': '管理員 Ntfy', + 'admin.notifications.adminNtfyPanel.hint': + '此 Ntfy 主題專用於管理員通知(例如版本提醒)。它與每位使用者的主題分開,設定後始終會觸發。', + 'admin.notifications.adminNtfyPanel.serverLabel': 'Ntfy 伺服器 URL', + 'admin.notifications.adminNtfyPanel.serverHint': + '同時用作使用者 ntfy 通知的預設伺服器。留空則預設使用 ntfy.sh。使用者可在自己的設定中覆寫此項。', + 'admin.notifications.adminNtfyPanel.serverPlaceholder': 'https://ntfy.sh', + 'admin.notifications.adminNtfyPanel.topicLabel': '管理員主題', + 'admin.notifications.adminNtfyPanel.topicPlaceholder': 'trek-admin-alerts', + 'admin.notifications.adminNtfyPanel.tokenLabel': '存取權杖(選填)', + 'admin.notifications.adminNtfyPanel.tokenCleared': '管理員存取權杖已清除', + 'admin.notifications.adminNtfyPanel.saved': '管理員 Ntfy 設定已儲存', + 'admin.notifications.adminNtfyPanel.test': '傳送測試 Ntfy', + 'admin.notifications.adminNtfyPanel.testSuccess': '測試 Ntfy 傳送成功', + 'admin.notifications.adminNtfyPanel.testFailed': '測試 Ntfy 失敗', + 'admin.notifications.adminNtfyPanel.alwaysOnHint': + '設定主題後管理員 Ntfy 始終觸發', + 'admin.notifications.adminNotificationsHint': + '配置哪些渠道傳遞僅管理員通知(例如版本提醒)。', + 'admin.notifications.tripReminders.title': '行程提醒', + 'admin.notifications.tripReminders.hint': + '在行程開始前發送提醒通知(需要在行程中設定提醒天數)。', + 'admin.notifications.tripReminders.enabled': '行程提醒已啟用', + 'admin.notifications.tripReminders.disabled': '行程提醒已停用', + 'admin.smtp.title': '郵件與通知', + 'admin.smtp.hint': '用於傳送電子郵件通知的 SMTP 配置。', + 'admin.smtp.testButton': '傳送測試郵件', + 'admin.webhook.hint': + '允許使用者配置自己的 Webhook URL 以接收通知(Discord、Slack 等)。', + 'admin.smtp.testSuccess': '測試郵件傳送成功', + 'admin.smtp.testFailed': '測試郵件傳送失敗', + 'admin.title': '管理後臺', + 'admin.subtitle': '使用者管理和系統設定', + 'admin.tabs.users': '使用者', + 'admin.tabs.categories': '分類', + 'admin.tabs.backup': '備份', + 'admin.tabs.audit': '審計日誌', + 'admin.tabs.notifications': '通知', + 'admin.stats.users': '使用者', + 'admin.stats.trips': '旅行', + 'admin.stats.places': '地點', + 'admin.stats.photos': '照片', + 'admin.stats.files': '檔案', + 'admin.table.user': '使用者', + 'admin.table.email': '郵箱', + 'admin.table.role': '角色', + 'admin.table.created': '建立時間', + 'admin.table.lastLogin': '最後登入', + 'admin.table.actions': '操作', + 'admin.you': '(你)', + 'admin.editUser': '編輯使用者', + 'admin.newPassword': '新密碼', + 'admin.newPasswordHint': '留空則保持當前密碼', + 'admin.deleteUser': '刪除使用者「{name}」?所有旅行將被永久刪除。', + 'admin.deleteUserTitle': '刪除使用者', + 'admin.newPasswordPlaceholder': '輸入新密碼…', + 'admin.toast.loadError': '載入管理資料失敗', + 'admin.toast.userUpdated': '使用者已更新', + 'admin.toast.updateError': '更新失敗', + 'admin.toast.userDeleted': '使用者已刪除', + 'admin.toast.deleteError': '刪除失敗', + 'admin.toast.cannotDeleteSelf': '不能刪除自己的賬戶', + 'admin.toast.userCreated': '使用者已建立', + 'admin.toast.createError': '建立使用者失敗', + 'admin.toast.fieldsRequired': '使用者名稱、郵箱和密碼為必填項', + 'admin.createUser': '建立使用者', + 'admin.invite.title': '邀請連結', + 'admin.invite.subtitle': '建立一次性註冊連結', + 'admin.invite.create': '建立連結', + 'admin.invite.createAndCopy': '建立並複製', + 'admin.invite.empty': '尚未建立邀請連結', + 'admin.invite.maxUses': '最大使用次數', + 'admin.invite.expiry': '有效期', + 'admin.invite.uses': '已使用', + 'admin.invite.expiresAt': '過期時間', + 'admin.invite.createdBy': '由', + 'admin.invite.active': '有效', + 'admin.invite.expired': '已過期', + 'admin.invite.usedUp': '已用完', + 'admin.invite.copied': '邀請連結已複製', + 'admin.invite.copyLink': '複製連結', + 'admin.invite.deleted': '邀請連結已刪除', + 'admin.invite.createError': '建立連結失敗', + 'admin.invite.deleteError': '刪除連結失敗', + 'admin.tabs.settings': '設定', + 'admin.allowRegistration': '允許註冊', + 'admin.allowRegistrationHint': '新使用者可以自行註冊', + 'admin.authMethods': 'Authentication Methods', + 'admin.passwordLogin': 'Password Login', + 'admin.passwordLoginHint': 'Allow users to sign in with email and password', + 'admin.passwordRegistration': 'Password Registration', + 'admin.passwordRegistrationHint': + 'Allow new users to register with email and password', + 'admin.oidcLogin': 'SSO Login', + 'admin.oidcLoginHint': 'Allow users to sign in with SSO', + 'admin.oidcRegistration': 'SSO Auto-Provisioning', + 'admin.oidcRegistrationHint': + 'Automatically create accounts for new SSO users', + 'admin.envOverrideHint': + 'Password login settings are controlled by the OIDC_ONLY environment variable and cannot be changed here.', + 'admin.lockoutWarning': 'At least one login method must remain enabled', + 'admin.requireMfa': '要求雙因素身份驗證(2FA)', + 'admin.requireMfaHint': + '未啟用 2FA 的使用者必須先完成設定中的配置才能使用應用。', + 'admin.apiKeys': 'API 金鑰', + 'admin.apiKeysHint': '可選。啟用地點的擴充套件資料,如照片和天氣。', + 'admin.mapsKey': 'Google Maps API 金鑰', + 'admin.mapsKeyHint': '用於地點搜尋。在 console.cloud.google.com 獲取', + 'admin.mapsKeyHintLong': + '沒有 API 金鑰時,使用 OpenStreetMap 搜尋地點。有了 Google API 金鑰,還可以載入照片、評分和營業時間。在 console.cloud.google.com 獲取。', + 'admin.recommended': '推薦', + 'admin.weatherKey': 'OpenWeatherMap API 金鑰', + 'admin.weatherKeyHint': '用於天氣資料。在 openweathermap.org 免費獲取', + 'admin.validateKey': '測試', + 'admin.keyValid': '已連線', + 'admin.keyInvalid': '無效', + 'admin.keySaved': 'API 金鑰已儲存', + 'admin.oidcTitle': '單點登入 (OIDC)', + 'admin.oidcSubtitle': + '允許透過 Google、Apple、Authentik 或 Keycloak 等外部提供商登入。', + 'admin.oidcDisplayName': '顯示名稱', + 'admin.oidcIssuer': '頒發者 URL', + 'admin.oidcIssuerHint': + '提供商的 OpenID Connect 頒發者 URL。如 https://accounts.google.com', + 'admin.oidcSaved': 'OIDC 配置已儲存', + 'admin.oidcOnlyMode': '停用密碼登入', + 'admin.oidcOnlyModeHint': '啟用後,僅允許 SSO 登入。密碼登入和註冊將被停用。', + 'admin.fileTypes': '允許的檔案型別', + 'admin.fileTypesHint': '配置使用者可以上傳的檔案型別。', + 'admin.fileTypesFormat': + '以逗號分隔的副檔名(如 jpg,png,pdf,doc)。使用 * 允許所有型別。', + 'admin.fileTypesSaved': '檔案型別設定已儲存', + 'admin.placesPhotos.title': '地點照片', + 'admin.placesPhotos.subtitle': + '從 Google Places API 獲取照片。停用可節省 API 配額。Wikimedia 照片不受影響。', + 'admin.placesAutocomplete.title': '地點自動補全', + 'admin.placesAutocomplete.subtitle': + '使用 Google Places API 提供搜尋建議。停用可節省 API 配額。', + 'admin.placesDetails.title': '地點詳情', + 'admin.placesDetails.subtitle': + '從 Google Places API 獲取地點詳細資訊(營業時間、評分、網站)。停用可節省 API 配額。', + 'admin.bagTracking.title': '行李追蹤', + 'admin.bagTracking.subtitle': '為打包物品啟用重量和行李分配', + 'admin.collab.chat.title': '聊天', + 'admin.collab.chat.subtitle': '即時訊息協作', + 'admin.collab.notes.title': '筆記', + 'admin.collab.notes.subtitle': '共享筆記和文件', + 'admin.collab.polls.title': '投票', + 'admin.collab.polls.subtitle': '群組投票和表決', + 'admin.collab.whatsnext.title': '下一步', + 'admin.collab.whatsnext.subtitle': '活動建議和後續步驟', + 'admin.tabs.config': '配置', + 'admin.tabs.defaults': '用戶預設設定', + 'admin.defaultSettings.title': '用戶預設設定', + 'admin.defaultSettings.description': + '設定整個執行個體的預設值。未更改設定的用戶將看到這些值。用戶自己的更改始終優先。', + 'admin.defaultSettings.saved': '預設值已儲存', + 'admin.defaultSettings.reset': '重設為內建預設值', + 'admin.defaultSettings.resetToBuiltIn': '重設', + 'admin.tabs.templates': '打包模板', + 'admin.packingTemplates.title': '打包模板', + 'admin.packingTemplates.subtitle': '建立可複用的旅行打包清單', + 'admin.packingTemplates.create': '新建模板', + 'admin.packingTemplates.namePlaceholder': '模板名稱(如:海灘度假)', + 'admin.packingTemplates.empty': '尚未建立模板', + 'admin.packingTemplates.items': '物品', + 'admin.packingTemplates.categories': '分類', + 'admin.packingTemplates.itemName': '物品名稱', + 'admin.packingTemplates.itemCategory': '分類', + 'admin.packingTemplates.categoryName': '分類名稱(如:衣物)', + 'admin.packingTemplates.addCategory': '新增分類', + 'admin.packingTemplates.created': '模板已建立', + 'admin.packingTemplates.deleted': '模板已刪除', + 'admin.packingTemplates.loadError': '載入模板失敗', + 'admin.packingTemplates.createError': '建立模板失敗', + 'admin.packingTemplates.deleteError': '刪除模板失敗', + 'admin.packingTemplates.saveError': '儲存失敗', + 'admin.tabs.addons': '擴充套件', + 'admin.addons.title': '擴充套件', + 'admin.addons.subtitle': '啟用或停用功能以自定義你的 TREK 體驗。', + 'admin.addons.catalog.memories.name': '照片 (Immich)', + 'admin.addons.catalog.memories.description': '透過 Immich 例項分享旅行照片', + 'admin.addons.catalog.mcp.name': 'MCP', + 'admin.addons.catalog.mcp.description': '用於 AI 助手整合的模型上下文協議', + 'admin.addons.catalog.packing.name': '行李', + 'admin.addons.catalog.packing.description': '每次旅行的行李準備清單', + 'admin.addons.catalog.budget.name': '預算', + 'admin.addons.catalog.budget.description': '跟蹤支出並規劃旅行預算', + 'admin.addons.catalog.documents.name': '文件', + 'admin.addons.catalog.documents.description': '儲存和管理旅行文件', + 'admin.addons.catalog.vacay.name': 'Vacay', + 'admin.addons.catalog.vacay.description': '帶日曆檢視的個人假期規劃器', + 'admin.addons.catalog.atlas.name': 'Atlas', + 'admin.addons.catalog.atlas.description': + '標記已訪問國家和旅行統計的世界地圖', + 'admin.addons.catalog.collab.name': 'Collab', + 'admin.addons.catalog.collab.description': '旅行規劃的即時筆記、投票和聊天', + 'admin.addons.subtitleBefore': '啟用或停用功能以自定義你的 ', + 'admin.addons.subtitleAfter': ' 體驗。', + 'admin.addons.enabled': '已啟用', + 'admin.addons.disabled': '已停用', + 'admin.addons.type.trip': '旅行', + 'admin.addons.type.global': '全域性', + 'admin.addons.type.integration': '整合', + 'admin.addons.tripHint': '在每次旅行中作為標籤頁顯示', + 'admin.addons.globalHint': '在主導航中作為獨立板塊顯示', + 'admin.addons.integrationHint': '後端服務和 API 整合,無專屬頁面', + 'admin.addons.toast.updated': '擴充套件已更新', + 'admin.addons.toast.error': '更新擴充套件失敗', + 'admin.addons.noAddons': '暫無可用擴充套件', + 'admin.weather.title': '天氣資料', + 'admin.weather.badge': '自 2026 年 3 月 24 日起', + 'admin.weather.description': + 'TREK 使用 Open-Meteo 作為天氣資料來源。Open-Meteo 是免費的開源天氣服務——無需 API 金鑰。', + 'admin.weather.forecast': '16 天天氣預報', + 'admin.weather.forecastDesc': '之前為 5 天 (OpenWeatherMap)', + 'admin.weather.climate': '歷史氣候資料', + 'admin.weather.climateDesc': '16 天預報之外的日期使用過去 85 年的平均值', + 'admin.weather.requests': '每天 10,000 次請求', + 'admin.weather.requestsDesc': '免費,無需 API 金鑰', + 'admin.weather.locationHint': + '天氣基於每天中第一個有座標的地點。如果當天沒有分配地點,則使用地點列表中的任意地點作為參考。', + 'admin.tabs.mcpTokens': 'MCP 存取', + 'admin.mcpTokens.title': 'MCP 存取', + 'admin.mcpTokens.subtitle': '管理所有使用者的 OAuth 工作階段和 API 令牌', + 'admin.mcpTokens.sectionTitle': 'API 令牌', + 'admin.mcpTokens.owner': '所有者', + 'admin.mcpTokens.tokenName': '令牌名稱', + 'admin.mcpTokens.created': '建立時間', + 'admin.mcpTokens.lastUsed': '最後使用', + 'admin.mcpTokens.never': '從未', + 'admin.mcpTokens.empty': '尚未建立任何 MCP 令牌', + 'admin.mcpTokens.deleteTitle': '刪除令牌', + 'admin.mcpTokens.deleteMessage': + '此令牌將立即被撤銷。使用者將失去透過此令牌的 MCP 訪問許可權。', + 'admin.mcpTokens.deleteSuccess': '令牌已刪除', + 'admin.mcpTokens.deleteError': '刪除令牌失敗', + 'admin.mcpTokens.loadError': '載入令牌失敗', + 'admin.oauthSessions.sectionTitle': 'OAuth 工作階段', + 'admin.oauthSessions.clientName': '客戶端', + 'admin.oauthSessions.owner': '所有者', + 'admin.oauthSessions.scopes': '權限範圍', + 'admin.oauthSessions.created': '建立時間', + 'admin.oauthSessions.empty': '目前沒有活躍的 OAuth 工作階段', + 'admin.oauthSessions.revokeTitle': '撤銷工作階段', + 'admin.oauthSessions.revokeMessage': + '此 OAuth 工作階段將立即被撤銷。客戶端將失去 MCP 存取權限。', + 'admin.oauthSessions.revokeSuccess': '工作階段已撤銷', + 'admin.oauthSessions.revokeError': '撤銷工作階段失敗', + 'admin.oauthSessions.loadError': '載入 OAuth 工作階段失敗', + 'admin.tabs.github': 'GitHub', + 'admin.audit.subtitle': '安全與管理員操作記錄(備份、使用者、MFA、設定)。', + 'admin.audit.empty': '暫無審計記錄。', + 'admin.audit.refresh': '重新整理', + 'admin.audit.loadMore': '載入更多', + 'admin.audit.showing': '已載入 {count} 條 · 共 {total} 條', + 'admin.audit.col.time': '時間', + 'admin.audit.col.user': '使用者', + 'admin.audit.col.action': '操作', + 'admin.audit.col.resource': '資源', + 'admin.audit.col.ip': 'IP', + 'admin.audit.col.details': '詳情', + 'admin.github.title': '版本歷史', + 'admin.github.subtitle': '{repo} 的最新更新', + 'admin.github.latest': '最新', + 'admin.github.prerelease': '預釋出', + 'admin.github.showDetails': '顯示詳情', + 'admin.github.hideDetails': '隱藏詳情', + 'admin.github.loadMore': '載入更多', + 'admin.github.loading': '載入中...', + 'admin.github.support': '幫助我繼續開發 TREK', + 'admin.github.error': '載入版本失敗', + 'admin.github.by': '作者', + 'admin.update.available': '有可用更新', + 'admin.update.text': 'TREK {version} 已釋出。你當前使用的是 {current}。', + 'admin.update.button': '在 GitHub 檢視', + 'admin.update.install': '安裝更新', + 'admin.update.confirmTitle': '確定安裝更新?', + 'admin.update.confirmText': + 'TREK 將從 {current} 更新到 {version}。伺服器將自動重啟。', + 'admin.update.dataInfo': + '你的所有資料(旅行、使用者、API 金鑰、上傳檔案、Vacay、Atlas、預算)將被保留。', + 'admin.update.warning': '重啟期間應用將短暫不可用。', + 'admin.update.confirm': '立即更新', + 'admin.update.installing': '更新中…', + 'admin.update.success': '更新已安裝!伺服器正在重啟…', + 'admin.update.failed': '更新失敗', + 'admin.update.backupHint': '建議在更新前建立備份。', + 'admin.update.backupLink': '前往備份', + 'admin.update.howTo': '如何更新', + 'admin.update.dockerText': + '你的 TREK 例項執行在 Docker 中。要更新到 {version},請在伺服器上執行以下命令:', + 'admin.update.reloadHint': '請在幾秒後重新整理頁面。', + 'admin.tabs.permissions': '許可權', + 'admin.addons.catalog.journey.name': '旅程', + 'admin.addons.catalog.journey.description': + '旅行追蹤與旅行日誌,包含打卡、照片和每日故事', + 'admin.passkey.title': 'Passkey 登入', + 'admin.passkey.cardHint': '讓使用者使用 Passkey(WebAuthn)登入。預設為關閉。', + 'admin.passkey.login': '啟用 Passkey 登入', + 'admin.passkey.loginHint': + '顯示「使用 Passkey 登入」選項,並讓使用者在設定中註冊 Passkey。', + 'admin.passkey.notConfigured': + '此部署尚未解析出任何 WebAuthn 網域。請設定下方的 APP_URL 或 Relying Party ID——在此之前 Passkey 將保持隱藏。', + 'admin.passkey.rpId': 'Relying Party ID(網域)', + 'admin.passkey.rpIdHint': + 'Passkey 綁定的純網域,例如 trek.example.org。留空則從 APP_URL 推導。日後變更將使現有 Passkey 失效。', + 'admin.passkey.origins': '允許的來源', + 'admin.passkey.originsHint': + '以逗號分隔的完整來源,例如 https://trek.example.org。留空則使用 APP_URL。', + 'admin.passkey.reset': '重設 Passkey', + 'admin.passkey.resetHint': + '移除此使用者的所有 Passkey(例如裝置遺失時)。他們仍可使用密碼登入。', + 'admin.passkey.resetConfirm': '要移除 {name} 的所有 Passkey 嗎?', + 'admin.passkey.resetDone': '已移除 {count} 個 Passkey', + 'admin.defaultSettings.mapProvider': '地圖引擎', + 'admin.defaultSettings.mapProviderHint': '此執行個體上所有人的預設地圖。每位使用者仍可在自己的設定中覆寫此項。', + 'admin.defaultSettings.providerLeaflet': '標準(免費)', + 'admin.defaultSettings.providerMapbox': 'Mapbox(3D)', + 'admin.defaultSettings.mapboxToken': '共用的 Mapbox 權杖', + 'admin.defaultSettings.mapboxTokenHint': '用於每一位尚未輸入自己權杖的使用者 — 如此整個執行個體都能使用 Mapbox,而無需個別共享金鑰。以加密方式儲存。', + 'admin.defaultSettings.mapboxStyle': '地圖樣式', + 'admin.defaultSettings.mapboxStylePlaceholder': '選擇樣式…', + 'admin.defaultSettings.mapbox3d': '3D 建築物與地形', + 'admin.defaultSettings.mapboxQuality': '高品質模式', +}; +export default admin; diff --git a/shared/src/i18n/zh-TW/airport.ts b/shared/src/i18n/zh-TW/airport.ts new file mode 100644 index 0000000000000000000000000000000000000000..bc8e33d00eec4b7f9ad63561133aac6092504d78 --- /dev/null +++ b/shared/src/i18n/zh-TW/airport.ts @@ -0,0 +1,6 @@ +import type { TranslationStrings } from '../types'; + +const airport: TranslationStrings = { + 'airport.searchPlaceholder': '機場代碼或城市(例如 FRA)', +}; +export default airport; diff --git a/shared/src/i18n/zh-TW/atlas.ts b/shared/src/i18n/zh-TW/atlas.ts new file mode 100644 index 0000000000000000000000000000000000000000..f141c3cd47901085c2d3a9c5db72894041b0705a --- /dev/null +++ b/shared/src/i18n/zh-TW/atlas.ts @@ -0,0 +1,58 @@ +import type { TranslationStrings } from '../types'; + +const atlas: TranslationStrings = { + 'atlas.subtitle': '你的全球旅行足跡', + 'atlas.countries': '國家', + 'atlas.trips': '旅行', + 'atlas.places': '地點', + 'atlas.days': '天', + 'atlas.visitedCountries': '已訪問國家', + 'atlas.cities': '城市', + 'atlas.noData': '暫無旅行資料', + 'atlas.noDataHint': '建立旅行並新增地點以檢視世界地圖', + 'atlas.lastTrip': '上次旅行', + 'atlas.nextTrip': '下次旅行', + 'atlas.daysLeft': '天后出發', + 'atlas.streak': '連續', + 'atlas.year': '年', + 'atlas.years': '年', + 'atlas.yearInRow': '年連續', + 'atlas.yearsInRow': '年連續', + 'atlas.tripIn': '次旅行在', + 'atlas.tripsIn': '次旅行在', + 'atlas.since': '自', + 'atlas.europe': '歐洲', + 'atlas.asia': '亞洲', + 'atlas.northAmerica': '北美洲', + 'atlas.southAmerica': '南美洲', + 'atlas.africa': '非洲', + 'atlas.oceania': '大洋洲', + 'atlas.other': '其他', + 'atlas.firstVisit': '首次旅行', + 'atlas.lastVisitLabel': '最近旅行', + 'atlas.tripSingular': '次旅行', + 'atlas.tripPlural': '次旅行', + 'atlas.placeVisited': '個地點已訪問', + 'atlas.placesVisited': '個地點已訪問', + 'atlas.statsTab': '統計', + 'atlas.bucketTab': '心願單', + 'atlas.addBucket': '新增到心願單', + 'atlas.bucketNamePlaceholder': '地點或目的地...', + 'atlas.bucketNotesPlaceholder': '備註(可選)', + 'atlas.bucketEmpty': '你的心願單是空的', + 'atlas.bucketEmptyHint': '新增你夢想去的地方', + 'atlas.unmark': '移除', + 'atlas.confirmMark': '將此國家標記為已訪問?', + 'atlas.confirmUnmark': '從已訪問列表中移除此國家?', + 'atlas.confirmUnmarkRegion': '從已訪問列表中移除此地區?', + 'atlas.markVisited': '標記為已訪問', + 'atlas.markVisitedHint': '將此國家新增到已訪問列表', + 'atlas.markRegionVisitedHint': '將此地區新增到已訪問列表', + 'atlas.addToBucket': '新增到心願單', + 'atlas.addPoi': '新增地點', + 'atlas.searchCountry': '搜尋國家...', + 'atlas.month': '月份', + 'atlas.addToBucketHint': '儲存為想去的地方', + 'atlas.bucketWhen': '你計劃什麼時候去?', +}; +export default atlas; diff --git a/shared/src/i18n/zh-TW/backup.ts b/shared/src/i18n/zh-TW/backup.ts new file mode 100644 index 0000000000000000000000000000000000000000..1d4b5cc8a178a0c2d38a4d9a50caeec3778b3988 --- /dev/null +++ b/shared/src/i18n/zh-TW/backup.ts @@ -0,0 +1,74 @@ +import type { TranslationStrings } from '../types'; + +const backup: TranslationStrings = { + 'backup.title': '資料備份', + 'backup.subtitle': '資料庫和所有上傳檔案', + 'backup.refresh': '重新整理', + 'backup.upload': '上傳備份', + 'backup.uploading': '上傳中…', + 'backup.create': '建立備份', + 'backup.creating': '建立中…', + 'backup.empty': '暫無備份', + 'backup.createFirst': '建立第一個備份', + 'backup.download': '下載', + 'backup.restore': '恢復', + 'backup.confirm.restore': + '恢復備份「{name}」?\n\n所有當前資料將被備份資料替換。', + 'backup.confirm.uploadRestore': + '上傳並恢復備份檔案「{name}」?\n\n所有當前資料將被覆蓋。', + 'backup.confirm.delete': '刪除備份「{name}」?', + 'backup.toast.loadError': '載入備份失敗', + 'backup.toast.created': '備份建立成功', + 'backup.toast.createError': '建立備份失敗', + 'backup.toast.restored': '備份已恢復。頁面即將重新整理…', + 'backup.toast.restoreError': '恢復失敗', + 'backup.toast.uploadError': '上傳失敗', + 'backup.toast.deleted': '備份已刪除', + 'backup.toast.deleteError': '刪除失敗', + 'backup.toast.downloadError': '下載失敗', + 'backup.toast.settingsSaved': '自動備份設定已儲存', + 'backup.toast.settingsError': '儲存設定失敗', + 'backup.auto.title': '自動備份', + 'backup.auto.subtitle': '按計劃自動備份', + 'backup.auto.enable': '啟用自動備份', + 'backup.auto.enableHint': '將按所選計劃自動建立備份', + 'backup.auto.interval': '間隔', + 'backup.auto.hour': '執行時間', + 'backup.auto.hourHint': '伺服器本地時間({format} 格式)', + 'backup.auto.dayOfWeek': '星期幾', + 'backup.auto.dayOfMonth': '每月幾號', + 'backup.auto.dayOfMonthHint': '限 1–28 以相容所有月份', + 'backup.auto.scheduleSummary': '計劃', + 'backup.auto.summaryDaily': '每天 {hour}:00', + 'backup.auto.summaryWeekly': '每{day} {hour}:00', + 'backup.auto.summaryMonthly': '每月 {day} 號 {hour}:00', + 'backup.auto.envLocked': 'Docker', + 'backup.auto.envLockedHint': + '自動備份透過 Docker 環境變數配置。要更改設定,請更新 docker-compose.yml 並重啟容器。', + 'backup.auto.copyEnv': '複製 Docker 環境變數', + 'backup.auto.envCopied': 'Docker 環境變數已複製到剪貼簿', + 'backup.auto.keepLabel': '自動刪除舊備份', + 'backup.dow.sunday': '週日', + 'backup.dow.monday': '週一', + 'backup.dow.tuesday': '週二', + 'backup.dow.wednesday': '週三', + 'backup.dow.thursday': '週四', + 'backup.dow.friday': '週五', + 'backup.dow.saturday': '週六', + 'backup.interval.hourly': '每小時', + 'backup.interval.daily': '每天', + 'backup.interval.weekly': '每週', + 'backup.interval.monthly': '每月', + 'backup.keep.1day': '1 天', + 'backup.keep.3days': '3 天', + 'backup.keep.7days': '7 天', + 'backup.keep.14days': '14 天', + 'backup.keep.30days': '30 天', + 'backup.keep.forever': '永久保留', + 'backup.restoreConfirmTitle': '恢復備份?', + 'backup.restoreWarning': + '所有當前資料(旅行、地點、使用者、上傳檔案)將被備份資料永久替換。此操作無法撤銷。', + 'backup.restoreTip': '提示:恢復前建議先備份當前狀態。', + 'backup.restoreConfirm': '確認恢復', +}; +export default backup; diff --git a/shared/src/i18n/zh-TW/budget.ts b/shared/src/i18n/zh-TW/budget.ts new file mode 100644 index 0000000000000000000000000000000000000000..14aa722512298b512388401bf7e8e0bc9877268e --- /dev/null +++ b/shared/src/i18n/zh-TW/budget.ts @@ -0,0 +1,115 @@ +import type { TranslationStrings } from '../types'; + +const budget: TranslationStrings = { + 'budget.title': '預算', + 'budget.exportCsv': '匯出 CSV', + 'budget.emptyTitle': '尚未建立預算', + 'budget.emptyText': '建立分類和條目來規劃旅行預算', + 'budget.emptyPlaceholder': '輸入分類名稱...', + 'budget.createCategory': '建立分類', + 'budget.category': '分類', + 'budget.categoryName': '分類名稱', + 'budget.table.name': '名稱', + 'budget.table.total': '合計', + 'budget.table.persons': '人數', + 'budget.table.days': '天數', + 'budget.table.perPerson': '人均', + 'budget.table.perDay': '日均', + 'budget.table.perPersonDay': '人日均', + 'budget.table.note': '備註', + 'budget.table.date': '日期', + 'budget.newEntry': '新建條目', + 'budget.defaultEntry': '新建條目', + 'budget.defaultCategory': '新分類', + 'budget.total': '合計', + 'budget.totalBudget': '總預算', + 'budget.byCategory': '按分類', + 'budget.editTooltip': '點選編輯', + 'budget.linkedToReservation': '已連結至預訂——請在那裡編輯名稱', + 'budget.confirm.deleteCategory': + '確定刪除分類「{name}」及其 {count} 個條目?', + 'budget.deleteCategory': '刪除分類', + 'budget.perPerson': '人均', + 'budget.paid': '已支付', + 'budget.open': '未支付', + 'budget.noMembers': '未分配成員', + 'budget.settlement': '結算', + 'budget.settlementInfo': + '點選預算專案上的成員頭像將其標記為綠色——表示該成員已付款。結算會顯示誰欠誰多少。', + 'budget.netBalances': '淨餘額', + 'budget.categoriesLabel': '類別', + "costs.you": "你", + "costs.youShort": "Y", + "costs.youLower": "你", + "costs.youOwe": "你欠款", + "costs.youOweSub": "你需付款給他人", + "costs.youreOwed": "他人欠你", + "costs.youreOwedSub": "他人需付款給你", + "costs.totalSpend": "旅程總支出", + "costs.totalSpendSub": "所有旅伴合計", + "costs.to": "給", + "costs.from": "來自", + "costs.allSettled": "你已全部結清", + "costs.nothingOwed": "沒有人欠你", + "costs.yourShare": "你的分攤", + "costs.youPaid": "你支付了", + "costs.expenses": "支出", + "costs.entries": "{count} 筆", + "costs.searchPlaceholder": "搜尋支出…", + "costs.filter.all": "全部", + "costs.filter.mine": "我支付的", + "costs.filter.owed": "他人欠我", + "costs.addExpense": "新增支出", + "costs.editExpense": "編輯支出", + "costs.noMatch": "沒有符合搜尋的支出。", + "costs.emptyText": "尚無支出,新增第一筆吧。", + "costs.spent": "支出 {amount}", + "costs.noDate": "無日期", + "costs.noOnePaid": "尚無人付款", + "costs.youLent": "你借出 {amount}", + "costs.youBorrowed": "你借入 {amount}", + "costs.settleUp": "結清", + "costs.history": "歷史紀錄", + "costs.everyoneSquare": "大家都已結清", + "costs.nothingOutstanding": "目前沒有待付款項。", + "costs.pay": "支付", + "costs.pays": "支付", + "costs.settle": "結算", + "costs.balances": "餘額", + "costs.byCategory": "按分類", + "costs.noCategories": "尚無支出。", + "costs.settleHistory": "結算紀錄", + "costs.noSettlements": "尚無已結清的款項。", + "costs.paymentsSettled": "已結清 {count} 筆款項", + "costs.paid": "已付", + "costs.undo": "復原", + "costs.whatFor": "這筆是什麼支出?", + "costs.namePlaceholder": "例如:晚餐、紀念品、油費…", + "costs.totalAmount": "總金額", + "costs.currency": "貨幣", + "costs.day": "日期", + "costs.rateLabel": "1 {from} 兌 {to}", + "costs.category": "分類", + "costs.whoPaid": "誰付的款?", + "costs.splitBetween": "平均分攤給", + "costs.pickSomeone": "至少選擇一人來分攤。", + "costs.splitSummary": "分 {count} 份 · 每份 {amount}", + "costs.cat.accommodation": "住宿", + "costs.cat.food": "餐飲", + "costs.cat.groceries": "雜貨", + "costs.cat.transport": "交通", + "costs.cat.flights": "機票", + "costs.cat.activities": "活動", + "costs.cat.sightseeing": "觀光", + "costs.cat.shopping": "購物", + "costs.cat.fees": "費用與票券", + "costs.cat.health": "健康", + "costs.cat.tips": "小費", + "costs.cat.other": "其他", + "costs.daysCount": "{count} 天", + "costs.travelers": "{count} 位旅伴", + "costs.liveRate": "即時匯率", + "costs.settleAll": "全部結清", +}; + +export default budget; diff --git a/shared/src/i18n/zh-TW/categories.ts b/shared/src/i18n/zh-TW/categories.ts new file mode 100644 index 0000000000000000000000000000000000000000..3cd57ecdb71de2b76dbe11548e294a38684aff06 --- /dev/null +++ b/shared/src/i18n/zh-TW/categories.ts @@ -0,0 +1,25 @@ +import type { TranslationStrings } from '../types'; + +const categories: TranslationStrings = { + 'categories.title': '分類', + 'categories.subtitle': '管理地點分類', + 'categories.new': '新建分類', + 'categories.empty': '暫無分類', + 'categories.namePlaceholder': '分類名稱', + 'categories.icon': '圖示', + 'categories.color': '顏色', + 'categories.customColor': '選擇自定義顏色', + 'categories.preview': '預覽', + 'categories.defaultName': '分類', + 'categories.update': '更新', + 'categories.create': '建立', + 'categories.confirm.delete': '刪除分類?該分類下的地點不會被刪除。', + 'categories.toast.loadError': '載入分類失敗', + 'categories.toast.nameRequired': '請輸入名稱', + 'categories.toast.updated': '分類已更新', + 'categories.toast.created': '分類已建立', + 'categories.toast.saveError': '儲存失敗', + 'categories.toast.deleted': '分類已刪除', + 'categories.toast.deleteError': '刪除失敗', +}; +export default categories; diff --git a/shared/src/i18n/zh-TW/collab.ts b/shared/src/i18n/zh-TW/collab.ts new file mode 100644 index 0000000000000000000000000000000000000000..58df7797ff63fc33a165ef0d5a38ca4a54b971dc --- /dev/null +++ b/shared/src/i18n/zh-TW/collab.ts @@ -0,0 +1,75 @@ +import type { TranslationStrings } from '../types'; + +const collab: TranslationStrings = { + 'collab.tabs.chat': '聊天', + 'collab.tabs.notes': '筆記', + 'collab.tabs.polls': '投票', + 'collab.whatsNext.title': '接下來', + 'collab.whatsNext.today': '今天', + 'collab.whatsNext.tomorrow': '明天', + 'collab.whatsNext.empty': '暫無活動', + 'collab.whatsNext.until': '至', + 'collab.whatsNext.emptyHint': '有時間安排的活動將顯示在此', + 'collab.chat.send': '傳送', + 'collab.chat.placeholder': '輸入訊息...', + 'collab.chat.empty': '開始對話', + 'collab.chat.emptyHint': '訊息對所有旅行成員可見', + 'collab.chat.emptyDesc': '與旅伴分享想法、計劃和動態', + 'collab.chat.today': '今天', + 'collab.chat.yesterday': '昨天', + 'collab.chat.deletedMessage': '刪除了一條訊息', + 'collab.chat.reply': '回覆', + 'collab.chat.loadMore': '載入更早的訊息', + 'collab.chat.justNow': '剛剛', + 'collab.chat.minutesAgo': '{n} 分鐘前', + 'collab.chat.hoursAgo': '{n} 小時前', + 'collab.notes.title': '筆記', + 'collab.notes.new': '新建筆記', + 'collab.notes.empty': '暫無筆記', + 'collab.notes.emptyHint': '開始記錄想法和計劃', + 'collab.notes.all': '全部', + 'collab.notes.titlePlaceholder': '筆記標題', + 'collab.notes.contentPlaceholder': '寫點什麼...', + 'collab.notes.categoryPlaceholder': '分類', + 'collab.notes.newCategory': '新建分類...', + 'collab.notes.category': '分類', + 'collab.notes.noCategory': '無分類', + 'collab.notes.color': '顏色', + 'collab.notes.save': '儲存', + 'collab.notes.cancel': '取消', + 'collab.notes.edit': '編輯', + 'collab.notes.delete': '刪除', + 'collab.notes.confirmDeleteTitle': '刪除筆記?', + 'collab.notes.confirmDeleteBody': '此筆記將被永久刪除。', + 'collab.notes.pin': '置頂', + 'collab.notes.unpin': '取消置頂', + 'collab.notes.daysAgo': '{n} 天前', + 'collab.notes.categorySettings': '管理分類', + 'collab.notes.create': '建立', + 'collab.notes.website': '網站', + 'collab.notes.websitePlaceholder': 'https://...', + 'collab.notes.attachFiles': '附加檔案', + 'collab.notes.noCategoriesYet': '暫無分類', + 'collab.notes.emptyDesc': '建立一個筆記開始吧', + 'collab.polls.title': '投票', + 'collab.polls.new': '新建投票', + 'collab.polls.empty': '暫無投票', + 'collab.polls.emptyHint': '向團隊提問並一起投票', + 'collab.polls.question': '問題', + 'collab.polls.questionPlaceholder': '我們應該做什麼?', + 'collab.polls.addOption': '+ 新增選項', + 'collab.polls.optionPlaceholder': '選項 {n}', + 'collab.polls.create': '建立投票', + 'collab.polls.close': '關閉', + 'collab.polls.closed': '已關閉', + 'collab.polls.votes': '{n} 票', + 'collab.polls.vote': '{n} 票', + 'collab.polls.multipleChoice': '多選', + 'collab.polls.multiChoice': '多選', + 'collab.polls.deadline': '截止時間', + 'collab.polls.option': '選項', + 'collab.polls.options': '選項', + 'collab.polls.delete': '刪除', + 'collab.polls.closedSection': '已關閉', +}; +export default collab; diff --git a/shared/src/i18n/zh-TW/common.ts b/shared/src/i18n/zh-TW/common.ts new file mode 100644 index 0000000000000000000000000000000000000000..da543769a235f5d66107d8a9ca65fc5a9f247618 --- /dev/null +++ b/shared/src/i18n/zh-TW/common.ts @@ -0,0 +1,54 @@ +import type { TranslationStrings } from '../types'; + +const common: TranslationStrings = { + 'common.save': '儲存', + 'common.showMore': '顯示更多', + 'common.showLess': '收起', + 'common.cancel': '取消', + 'common.clear': '清除', + 'common.delete': '刪除', + 'common.edit': '編輯', + 'common.add': '新增', + 'common.loading': '載入中...', + 'common.import': '匯入', + 'common.select': '選擇', + 'common.selectAll': '全選', + 'common.deselectAll': '取消全選', + 'common.error': '錯誤', + 'common.unknownError': '未知錯誤', + 'common.tooManyAttempts': '嘗試次數過多,請稍後再試。', + 'common.back': '返回', + 'common.all': '全部', + 'common.close': '關閉', + 'common.open': '開啟', + 'common.upload': '上傳', + 'common.search': '搜尋', + 'common.confirm': '確認', + 'common.ok': '確定', + 'common.yes': '是', + 'common.no': '否', + 'common.or': '或', + 'common.none': '無', + 'common.date': '日期', + 'common.rename': '重新命名', + 'common.discardChanges': '捨棄變更', + 'common.discard': '捨棄', + 'common.name': '名稱', + 'common.email': '郵箱', + 'common.password': '密碼', + 'common.saving': '儲存中...', + 'common.saved': '已儲存', + 'common.expand': '展開', + 'common.collapse': '折疊', + 'common.update': '更新', + 'common.change': '修改', + 'common.uploading': '上傳中…', + 'common.backToPlanning': '返回規劃', + 'common.reset': '重置', + 'common.copy': '複製', + 'common.copied': '已複製', + 'common.justNow': '剛剛', + 'common.hoursAgo': '{count}小時前', + 'common.daysAgo': '{count}天前', +}; +export default common; diff --git a/shared/src/i18n/zh-TW/dashboard.ts b/shared/src/i18n/zh-TW/dashboard.ts new file mode 100644 index 0000000000000000000000000000000000000000..61edec6f3e2ee76c98785bf787cafa0b0515380f --- /dev/null +++ b/shared/src/i18n/zh-TW/dashboard.ts @@ -0,0 +1,166 @@ +import type { TranslationStrings } from '../types'; + +const dashboard: TranslationStrings = { + 'dashboard.title': '我的旅行', + 'dashboard.subtitle.loading': '載入旅行中...', + 'dashboard.subtitle.trips': '{count} 次旅行({archived} 已歸檔)', + 'dashboard.subtitle.empty': '開始你的第一次旅行', + 'dashboard.subtitle.activeOne': '{count} 個進行中的旅行', + 'dashboard.subtitle.activeMany': '{count} 個進行中的旅行', + 'dashboard.subtitle.archivedSuffix': ' · {count} 已歸檔', + 'dashboard.newTrip': '新建旅行', + 'dashboard.newTripSub': '從零開始規劃新旅行', + 'dashboard.gridView': '網格檢視', + 'dashboard.listView': '列表檢視', + 'dashboard.currency': '貨幣', + 'dashboard.timezone': '時區', + 'dashboard.localTime': '本地', + 'dashboard.timezoneCustomTitle': '自定義時區', + 'dashboard.timezoneCustomLabelPlaceholder': '標籤(可選)', + 'dashboard.timezoneCustomTzPlaceholder': '如 America/New_York', + 'dashboard.timezoneCustomAdd': '新增', + 'dashboard.timezoneCustomErrorEmpty': '請輸入時區識別符號', + 'dashboard.timezoneCustomErrorInvalid': + '無效的時區。請使用 Europe/Berlin 這樣的格式', + 'dashboard.timezoneCustomErrorDuplicate': '已新增', + 'dashboard.emptyTitle': '暫無旅行', + 'dashboard.emptyText': '建立你的第一次旅行,開始規劃吧!', + 'dashboard.emptyButton': '建立第一次旅行', + 'dashboard.nextTrip': '下次旅行', + 'dashboard.shared': '共享', + 'dashboard.sharedBy': '由 {name} 分享', + 'dashboard.days': '天', + 'dashboard.places': '地點', + 'dashboard.members': '旅伴', + 'dashboard.archive': '歸檔', + 'dashboard.copyTrip': '複製', + 'dashboard.copySuffix': '副本', + 'dashboard.restore': '恢復', + 'dashboard.archived': '已歸檔', + 'dashboard.status.ongoing': '進行中', + 'dashboard.status.today': '今天', + 'dashboard.status.tomorrow': '明天', + 'dashboard.status.past': '已結束', + 'dashboard.status.daysLeft': '還剩 {count} 天', + 'dashboard.toast.loadError': '載入旅行失敗', + 'dashboard.toast.created': '旅行建立成功!', + 'dashboard.toast.createError': '建立旅行失敗', + 'dashboard.toast.updated': '旅行已更新!', + 'dashboard.toast.updateError': '更新旅行失敗', + 'dashboard.toast.deleted': '旅行已刪除', + 'dashboard.toast.deleteError': '刪除旅行失敗', + 'dashboard.toast.archived': '旅行已歸檔', + 'dashboard.toast.archiveError': '歸檔旅行失敗', + 'dashboard.toast.restored': '旅行已恢復', + 'dashboard.toast.restoreError': '恢復旅行失敗', + 'dashboard.toast.copied': '旅行已複製!', + 'dashboard.toast.copyError': '複製旅行失敗', + 'dashboard.confirm.delete': + '刪除旅行「{title}」?所有地點和計劃將被永久刪除。', + 'dashboard.editTrip': '編輯旅行', + 'dashboard.createTrip': '建立新旅行', + 'dashboard.tripTitle': '標題', + 'dashboard.tripTitlePlaceholder': '如:日本夏日之旅', + 'dashboard.tripDescription': '描述', + 'dashboard.tripDescriptionPlaceholder': '這次旅行是關於什麼的?', + 'dashboard.startDate': '開始日期', + 'dashboard.endDate': '結束日期', + 'dashboard.dayCount': '天數', + 'dashboard.dayCountHint': '未設定旅行日期時,要規劃的天數。', + 'dashboard.noDateHint': '未設定日期——將預設建立 7 天。你可以隨時修改。', + 'dashboard.coverImage': '封面圖片', + 'dashboard.addCoverImage': '新增封面圖片', + 'dashboard.addMembers': '旅伴', + 'dashboard.addMember': '新增成員', + 'dashboard.coverSaved': '封面圖片已儲存', + 'dashboard.coverUploadError': '上傳失敗', + 'dashboard.coverRemoveError': '移除失敗', + 'dashboard.titleRequired': '標題為必填項', + 'dashboard.endDateError': '結束日期必須晚於開始日期', + 'dashboard.greeting.morning': '早安,', + 'dashboard.greeting.afternoon': '午安,', + 'dashboard.greeting.evening': '晚安,', + 'dashboard.mobile.liveNow': '進行中', + 'dashboard.mobile.tripProgress': '旅行進度', + 'dashboard.mobile.daysLeft': '還剩 {count} 天', + 'dashboard.mobile.places': '地點', + 'dashboard.mobile.buddies': '旅伴', + 'dashboard.mobile.newTrip': '新建旅行', + 'dashboard.mobile.currency': '貨幣', + 'dashboard.mobile.timezone': '時區', + 'dashboard.mobile.upcomingTrips': '即將到來的旅行', + 'dashboard.mobile.yourTrips': '我的旅行', + 'dashboard.mobile.trips': '個旅行', + 'dashboard.mobile.starts': '出發', + 'dashboard.mobile.duration': '時長', + 'dashboard.mobile.day': '天', + 'dashboard.mobile.days': '天', + 'dashboard.mobile.ongoing': '進行中', + 'dashboard.mobile.startsToday': '今天出發', + 'dashboard.mobile.tomorrow': '明天', + 'dashboard.mobile.inDays': '{count} 天後', + 'dashboard.mobile.inMonths': '{count} 個月後', + 'dashboard.mobile.completed': '已完成', + 'dashboard.mobile.currencyConverter': '匯率轉換', + 'dashboard.filter.planned': '已規劃', + 'dashboard.hero.badgeLive': '進行中', + 'dashboard.hero.badgeToday': '今天開始', + 'dashboard.hero.badgeTomorrow': '明天', + 'dashboard.hero.badgeNext': '即將開始', + 'dashboard.hero.badgeRecent': '最近', + 'dashboard.hero.tripDates': '旅行日期', + 'dashboard.hero.noDates': '未設定日期', + 'dashboard.hero.travelerOne': '{count} 位旅客', + 'dashboard.hero.travelerMany': '{count} 位旅客', + 'dashboard.hero.destinationOne': '{count} 個目的地', + 'dashboard.hero.destinationMany': '{count} 個目的地', + 'dashboard.hero.dayUnitOne': '天', + 'dashboard.hero.dayUnitMany': '天', + 'dashboard.hero.dayLeft': '剩 1 天', + 'dashboard.hero.daysLeft': '剩餘天數', + 'dashboard.hero.lastDay': '最後一天', + 'dashboard.hero.untilStart': '距開始', + 'dashboard.hero.startsIn': '距出發', + 'dashboard.atlas.countriesVisited': '地圖集 · 已造訪國家', + 'dashboard.atlas.ofTotal': '/ {total}', + 'dashboard.atlas.tripsTotal': '旅行總數', + 'dashboard.atlas.placesMapped': '已標記 {count} 個地點', + 'dashboard.atlas.daysTraveled': '旅行天數', + 'dashboard.atlas.daysUnit': '天', + 'dashboard.atlas.acrossAllTrips': '所有旅行累計', + 'dashboard.atlas.distanceFlown': '飛行距離', + 'dashboard.atlas.kmUnit': 'km', + 'dashboard.atlas.aroundEquator': '≈ 繞赤道 {count} 圈', + 'dashboard.card.idea': '想法', + 'dashboard.card.buddyOne': '旅伴', + 'dashboard.fx.from': '從', + 'dashboard.fx.to': '到', + 'dashboard.fx.unavailable': '無法取得匯率', + 'dashboard.tz.searchPlaceholder': '搜尋時區…', + 'dashboard.tz.empty': '還沒有其他時區 — 用 + 新增一個', + 'dashboard.upcoming.title': '即將到來的預訂', + 'dashboard.upcoming.empty': '尚未預訂任何內容。', + 'dashboard.confirm.copy.title': '複製這次旅行?', + 'dashboard.confirm.copy.willCopy': '將被複製', + 'dashboard.confirm.copy.will1': '天數、地點和每日安排', + 'dashboard.confirm.copy.will2': '住宿和預訂', + 'dashboard.confirm.copy.will3': '預算項目和分類順序', + 'dashboard.confirm.copy.will4': '打包清單(未勾選)', + 'dashboard.confirm.copy.will5': '待辦事項(未指派且未勾選)', + 'dashboard.confirm.copy.will6': '每日筆記', + 'dashboard.confirm.copy.wontCopy': '不會被複製', + 'dashboard.confirm.copy.wont1': '協作者和成員指派', + 'dashboard.confirm.copy.wont2': '協作筆記、投票和訊息', + 'dashboard.confirm.copy.wont3': '檔案和照片', + 'dashboard.confirm.copy.wont4': '共享權杖', + 'dashboard.confirm.copy.confirm': '複製旅行', + 'dashboard.aria.toggleView': '切換檢視', + 'dashboard.aria.filter': '篩選', + 'dashboard.aria.duplicate': '複製', + 'dashboard.aria.refreshRates': '重新整理匯率', + 'dashboard.aria.swapCurrencies': '交換貨幣', + 'dashboard.aria.addTimezone': '新增時區', + 'dashboard.aria.removeTimezone': '移除 {city}', + 'dashboard.dayCountRequired': '天數為必填項', +}; +export default dashboard; diff --git a/shared/src/i18n/zh-TW/day.ts b/shared/src/i18n/zh-TW/day.ts new file mode 100644 index 0000000000000000000000000000000000000000..59f241890118cf879970f6fdec91071a69cdda64 --- /dev/null +++ b/shared/src/i18n/zh-TW/day.ts @@ -0,0 +1,25 @@ +import type { TranslationStrings } from '../types'; + +const day: TranslationStrings = { + 'day.precipProb': '降水機率', + 'day.precipitation': '降水量', + 'day.wind': '風速', + 'day.sunrise': '日出', + 'day.sunset': '日落', + 'day.hourlyForecast': '逐小時預報', + 'day.climateHint': '歷史平均值——實際預報在該日期前 16 天內可用。', + 'day.noWeather': '無天氣資料。請新增有座標的地點。', + 'day.overview': '每日概覽', + 'day.accommodation': '住宿', + 'day.addAccommodation': '新增住宿', + 'day.hotelDayRange': '應用到天數', + 'day.noPlacesForHotel': '請先在旅行中新增地點', + 'day.allDays': '全部', + 'day.checkIn': '入住', + 'day.checkInUntil': '截止', + 'day.checkOut': '退房', + 'day.confirmation': '確認號', + 'day.editAccommodation': '編輯住宿', + 'day.reservations': '預訂', +}; +export default day; diff --git a/shared/src/i18n/zh-TW/dayplan.ts b/shared/src/i18n/zh-TW/dayplan.ts new file mode 100644 index 0000000000000000000000000000000000000000..f986e845d63a9758da9e2fc717f6993e4e11b016 --- /dev/null +++ b/shared/src/i18n/zh-TW/dayplan.ts @@ -0,0 +1,55 @@ +import type { TranslationStrings } from '../types'; + +const dayplan: TranslationStrings = { + 'dayplan.icsTooltip': '匯出日曆 (ICS)', + 'dayplan.emptyDay': '當天暫無計劃', + 'dayplan.addNote': '新增備註', + 'dayplan.editNote': '編輯備註', + 'dayplan.noteAdd': '新增備註', + 'dayplan.noteEdit': '編輯備註', + 'dayplan.noteTitle': '備註', + 'dayplan.noteSubtitle': '每日備註', + 'dayplan.totalCost': '總費用', + 'dayplan.days': '天', + 'dayplan.dayN': '第 {n} 天', + 'dayplan.calculating': '計算中...', + 'dayplan.route': '路線', + 'dayplan.optimize': '最佳化', + 'dayplan.optimized': '路線已最佳化', + 'dayplan.routeError': '路線計算失敗', + 'dayplan.toast.needTwoPlaces': '路線最佳化至少需要兩個地點', + 'dayplan.toast.routeOptimized': '路線已最佳化', + 'dayplan.toast.routeOptimizedFromHotel': '已從你的住宿地點最佳化路線', + 'dayplan.toast.noGeoPlaces': '未找到有座標的地點用於路線計算', + 'dayplan.confirmed': '已確認', + 'dayplan.pendingRes': '待確認', + 'dayplan.pdf': 'PDF', + 'dayplan.pdfTooltip': '匯出當天計劃為 PDF', + 'dayplan.pdfError': 'PDF 匯出失敗', + 'dayplan.cannotReorderTransport': '有固定時間的預訂無法重新排序', + 'dayplan.confirmRemoveTimeTitle': '移除時間?', + 'dayplan.confirmRemoveTimeBody': + '此地點有固定時間({time})。移動後將移除時間並允許自由排序。', + 'dayplan.confirmRemoveTimeAction': '移除時間並移動', + 'dayplan.confirmDeleteNoteTitle': '刪除筆記?', + 'dayplan.confirmDeleteNoteBody': '此筆記將被永久刪除。', + 'dayplan.cannotDropOnTimed': '無法將專案放置在有固定時間的條目之間', + 'dayplan.cannotBreakChronology': '這將打亂已計劃專案和預訂的時間順序', + 'dayplan.mobile.addPlace': '新增地點', + 'dayplan.mobile.searchPlaces': '搜尋地點...', + 'dayplan.mobile.allAssigned': '所有地點已分配', + 'dayplan.mobile.noMatch': '無匹配', + 'dayplan.mobile.createNew': '建立新地點', + 'dayplan.expandAll': 'Expand all days', // en-fallback + 'dayplan.collapseAll': 'Collapse all days', // en-fallback + 'dayplan.reorderDays': '重新排序日期', + 'dayplan.reorderTitle': '重新排序日期', + 'dayplan.reorderHint': '該日的地點、筆記和預訂都會一併移動。', + 'dayplan.addDay': '新增日期', + 'dayplan.moveUp': '上移', + 'dayplan.moveDown': '下移', + 'dayplan.reorderUndo': '重新排序日期', + 'dayplan.reorderError': '重新排序日期失敗', + 'dayplan.addDayError': '新增日期失敗', +}; +export default dayplan; diff --git a/shared/src/i18n/zh-TW/externalNotifications.ts b/shared/src/i18n/zh-TW/externalNotifications.ts new file mode 100644 index 0000000000000000000000000000000000000000..2f5d28e28186fe18dc7f30bb21aed4a336d596fb --- /dev/null +++ b/shared/src/i18n/zh-TW/externalNotifications.ts @@ -0,0 +1,62 @@ +import type { NotificationLocale } from '../externalNotifications/types'; + +const zhTW: NotificationLocale = { + email: { + footer: '您收到這封郵件是因為您在 TREK 中啟用了通知。', + manage: '管理偏好設定', + madeWith: 'Made with', + openTrek: '開啟 TREK', + }, + events: { + trip_invite: (p) => ({ + title: `邀請加入「${p.trip}」`, + body: `${p.actor} 邀請了 ${p.invitee || '成員'} 加入行程「${p.trip}」。`, + }), + booking_change: (p) => ({ + title: `新預訂:${p.booking}`, + body: `${p.actor} 在「${p.trip}」中新增了預訂「${p.booking}」(${p.type})。`, + }), + trip_reminder: (p) => ({ + title: `行程提醒:${p.trip}`, + body: `您的行程「${p.trip}」即將開始!`, + }), + todo_due: (p) => ({ + title: `待辦事項即將到期:${p.todo}`, + body: `「${p.trip}」中的「${p.todo}」將於 ${p.due} 到期。`, + }), + vacay_invite: (p) => ({ + title: 'Vacay 融合邀請', + body: `${p.actor} 邀請您合併假期計畫。開啟 TREK 以接受或拒絕。`, + }), + photos_shared: (p) => ({ + title: `已分享 ${p.count} 張照片`, + body: `${p.actor} 在「${p.trip}」中分享了 ${p.count} 張照片。`, + }), + collab_message: (p) => ({ + title: `「${p.trip}」中的新訊息`, + body: `${p.actor}:${p.preview}`, + }), + packing_tagged: (p) => ({ + title: `打包清單:${p.category}`, + body: `${p.actor} 已將您指派到「${p.trip}」中的「${p.category}」分類。`, + }), + version_available: (p) => ({ + title: '新版 TREK 可用', + body: `TREK ${p.version} 現已可用。請前往管理面板進行更新。`, + }), + synology_session_cleared: () => ({ + title: 'Synology 工作階段已清除', + body: '您的 Synology 帳戶或 URL 已變更,您已登出 Synology Photos。', + }), + }, + passwordReset: { + subject: '重設您的密碼', + greeting: '您好', + body: '我們收到了重設您 TREK 帳號密碼的請求。點擊下方按鈕以設定新密碼。', + ctaIntro: '重設密碼', + expiry: '此連結將於 60 分鐘後失效。', + ignore: '若非您本人發起的請求,請忽略此郵件 — 您的密碼不會變更。', + }, +}; + +export default zhTW; diff --git a/shared/src/i18n/zh-TW/files.ts b/shared/src/i18n/zh-TW/files.ts new file mode 100644 index 0000000000000000000000000000000000000000..ecd2e2e1bbb0156c7fabd50b30eed5012c361302 --- /dev/null +++ b/shared/src/i18n/zh-TW/files.ts @@ -0,0 +1,60 @@ +import type { TranslationStrings } from '../types'; + +const files: TranslationStrings = { + 'files.title': '檔案', + 'files.pageTitle': '檔案與文件', + 'files.subtitle': '{trip} 的 {count} 個檔案', + 'files.download': '下載', + 'files.openError': '無法開啟檔案', + 'files.downloadPdf': '下載 PDF', + 'files.count': '{count} 個檔案', + 'files.countSingular': '1 個檔案', + 'files.uploaded': '已上傳 {count} 個', + 'files.uploadError': '上傳失敗', + 'files.dropzone': '將檔案拖放到此處', + 'files.dropzoneHint': '或點選瀏覽', + 'files.allowedTypes': + '圖片、PDF、DOC、DOCX、XLS、XLSX、TXT、CSV · 最大 50 MB', + 'files.uploading': '上傳中...', + 'files.filterAll': '全部', + 'files.filterPdf': 'PDF', + 'files.filterImages': '圖片', + 'files.filterDocs': '文件', + 'files.filterCollab': '協作筆記', + 'files.sourceCollab': '來自協作筆記', + 'files.empty': '暫無檔案', + 'files.emptyHint': '上傳檔案以附加到旅行中', + 'files.openTab': '在新標籤頁中開啟', + 'files.confirm.delete': '確定要刪除此檔案嗎?', + 'files.toast.deleted': '檔案已刪除', + 'files.toast.deleteError': '刪除檔案失敗', + 'files.sourcePlan': '日程計劃', + 'files.sourceBooking': '預訂', + 'files.sourceTransport': '交通', + 'files.attach': '附加', + 'files.pasteHint': '也可以從剪貼簿貼上圖片 (Ctrl+V)', + 'files.trash': '回收站', + 'files.trashEmpty': '回收站為空', + 'files.emptyTrash': '清空回收站', + 'files.restore': '恢復', + 'files.star': '收藏', + 'files.unstar': '取消收藏', + 'files.assign': '分配', + 'files.assignTitle': '分配檔案', + 'files.assignPlace': '地點', + 'files.assignBooking': '預訂', + 'files.assignTransport': '交通', + 'files.unassigned': '未分配', + 'files.unlink': '移除關聯', + 'files.toast.trashed': '已移至回收站', + 'files.toast.restored': '檔案已恢復', + 'files.toast.trashEmptied': '回收站已清空', + 'files.toast.assigned': '檔案已分配', + 'files.toast.assignError': '分配失敗', + 'files.toast.restoreError': '恢復失敗', + 'files.confirm.permanentDelete': '永久刪除此檔案?此操作無法撤銷。', + 'files.confirm.emptyTrash': '永久刪除回收站中的所有檔案?此操作無法撤銷。', + 'files.noteLabel': '備註', + 'files.notePlaceholder': '新增備註...', +}; +export default files; diff --git a/shared/src/i18n/zh-TW/index.ts b/shared/src/i18n/zh-TW/index.ts new file mode 100644 index 0000000000000000000000000000000000000000..b67d1baa31a077a284251791b484fbdfc3808353 --- /dev/null +++ b/shared/src/i18n/zh-TW/index.ts @@ -0,0 +1,86 @@ +import admin from './admin'; +import airport from './airport'; +import atlas from './atlas'; +import backup from './backup'; +import budget from './budget'; +import categories from './categories'; +import collab from './collab'; +import common from './common'; +import dashboard from './dashboard'; +import day from './day'; +import dayplan from './dayplan'; +import files from './files'; +import inspector from './inspector'; +import journey from './journey'; +import login from './login'; +import map from './map'; +import members from './members'; +import memories from './memories'; +import nav from './nav'; +import notif from './notif'; +import notifications from './notifications'; +import oauth from './oauth'; +import packing from './packing'; +import pdf from './pdf'; +import perm from './perm'; +import photos from './photos'; +import places from './places'; +import planner from './planner'; +import register from './register'; +import reservations from './reservations'; +import settings from './settings'; +import share from './share'; +import shared from './shared'; +import stats from './stats'; +import system_notice from './system_notice'; +import todo from './todo'; +import transport from './transport'; +import trip from './trip'; +import trips from './trips'; +import undo from './undo'; +import vacay from './vacay'; + +const locale = { + ...common, + ...trips, + ...nav, + ...dashboard, + ...settings, + ...admin, + ...dayplan, + ...share, + ...shared, + ...login, + ...register, + ...vacay, + ...atlas, + ...trip, + ...places, + ...inspector, + ...reservations, + ...airport, + ...map, + ...budget, + ...files, + ...packing, + ...members, + ...categories, + ...backup, + ...photos, + ...pdf, + ...planner, + ...stats, + ...day, + ...memories, + ...collab, + ...perm, + ...undo, + ...todo, + ...notifications, + ...journey, + ...notif, + ...oauth, + ...system_notice, + ...transport, +}; +export default locale; diff --git a/shared/src/i18n/zh-TW/inspector.ts b/shared/src/i18n/zh-TW/inspector.ts new file mode 100644 index 0000000000000000000000000000000000000000..65f9b2cd7cf3a6e2a732f0b9297985c563c4ae3d --- /dev/null +++ b/shared/src/i18n/zh-TW/inspector.ts @@ -0,0 +1,22 @@ +import type { TranslationStrings } from '../types'; + +const inspector: TranslationStrings = { + 'inspector.opened': '營業中', + 'inspector.closed': '已關閉', + 'inspector.openingHours': '營業時間', + 'inspector.showHours': '顯示營業時間', + 'inspector.files': '檔案', + 'inspector.filesCount': '{count} 個檔案', + 'inspector.removeFromDay': '從當天移除', + 'inspector.remove': '刪除', + 'inspector.addToDay': '新增到當天', + 'inspector.confirmedRes': '已確認預訂', + 'inspector.pendingRes': '待確認預訂', + 'inspector.google': '在 Google Maps 中開啟', + 'inspector.website': '開啟網站', + 'inspector.addRes': '預訂', + 'inspector.editRes': '編輯預訂', + 'inspector.participants': '參與者', + 'inspector.trackStats': '軌跡資料', +}; +export default inspector; diff --git a/shared/src/i18n/zh-TW/journey.ts b/shared/src/i18n/zh-TW/journey.ts new file mode 100644 index 0000000000000000000000000000000000000000..c78ff82981dd087796bd808e0d8b15b7a12a5e3f --- /dev/null +++ b/shared/src/i18n/zh-TW/journey.ts @@ -0,0 +1,234 @@ +import type { TranslationStrings } from '../types'; + +const journey: TranslationStrings = { + 'journey.search.placeholder': '搜尋旅程…', + 'journey.search.noResults': '沒有符合「{query}」的旅程', + 'journey.title': '旅程', + 'journey.subtitle': '即時記錄你的旅行', + 'journey.new': '新建旅程', + 'journey.create': '建立', + 'journey.titlePlaceholder': '你要去哪裡?', + 'journey.empty': '還沒有旅程', + 'journey.emptyHint': '開始記錄你的下一次旅行', + 'journey.deleted': '旅程已刪除', + 'journey.createError': '無法建立旅程', + 'journey.deleteError': '無法刪除旅程', + 'journey.deleteConfirmTitle': '刪除', + 'journey.deleteConfirmMessage': '刪除「{title}」?此操作無法復原。', + 'journey.deleteConfirmGeneric': '確定要刪除嗎?', + 'journey.notFound': '未找到旅程', + 'journey.photos': '照片', + 'journey.timelineEmpty': '還沒有行程', + 'journey.timelineEmptyHint': '新增一個打卡或寫一篇日誌開始記錄', + 'journey.status.draft': '草稿', + 'journey.status.active': '進行中', + 'journey.status.completed': '已完成', + 'journey.status.upcoming': '即將開始', + 'journey.status.archived': '已封存', + 'journey.checkin.add': '打卡', + 'journey.checkin.namePlaceholder': '地點名稱', + 'journey.checkin.notesPlaceholder': '備註(可選)', + 'journey.checkin.save': '儲存', + 'journey.checkin.error': '無法儲存打卡', + 'journey.entry.add': '日誌', + 'journey.entry.edit': '編輯條目', + 'journey.entry.titlePlaceholder': '標題(可選)', + 'journey.entry.bodyPlaceholder': '今天發生了什麼?', + 'journey.entry.save': '儲存', + 'journey.entry.error': '無法儲存條目', + 'journey.photo.add': '照片', + 'journey.photo.uploadError': '上傳失敗', + 'journey.share.share': '分享', + 'journey.share.public': '公開', + 'journey.share.linkCopied': '公開連結已複製', + 'journey.share.disabled': '已關閉公開分享', + 'journey.editor.titlePlaceholder': '給這個瞬間起個名字...', + 'journey.editor.bodyPlaceholder': '講述這一天的故事...', + 'journey.editor.placePlaceholder': '地點(可選)', + 'journey.editor.tagsPlaceholder': '標籤:隱藏寶藏、最佳美食、值得再訪...', + 'journey.visibility.private': '私密', + 'journey.visibility.shared': '共享', + 'journey.visibility.public': '公開', + 'journey.emptyState.title': '你的故事從這裡開始', + 'journey.emptyState.subtitle': '在某個地方打卡或寫下你的第一篇日誌', + 'journey.frontpage.subtitle': '將旅行變成永遠不會忘記的故事', + 'journey.frontpage.createJourney': '建立旅程', + 'journey.frontpage.activeJourney': '進行中的旅程', + 'journey.frontpage.allJourneys': '所有旅程', + 'journey.frontpage.journeys': '個旅程', + 'journey.frontpage.createNew': '建立新旅程', + 'journey.frontpage.createNewSub': '選擇旅行、寫故事、分享你的冒險', + 'journey.frontpage.live': '即時', + 'journey.frontpage.synced': '已同步', + 'journey.frontpage.continueWriting': '繼續撰寫', + 'journey.frontpage.updated': '更新於 {time}', + 'journey.frontpage.suggestionLabel': '旅行剛結束', + 'journey.frontpage.suggestionText': + '將 {title} 變成一段旅程', + 'journey.frontpage.dismiss': '忽略', + 'journey.frontpage.journeyName': '旅程名稱', + 'journey.frontpage.namePlaceholder': '例如 東南亞 2026', + 'journey.frontpage.selectTrips': '選擇旅行', + 'journey.frontpage.tripsSelected': '個旅行已選擇', + 'journey.frontpage.trips': '個旅行', + 'journey.frontpage.placesImported': '個地點將被匯入', + 'journey.frontpage.places': '個地點', + 'journey.detail.backToJourney': '返回旅程', + 'journey.detail.syncedWithTrips': '已與旅行同步', + 'journey.detail.addEntry': '新增條目', + 'journey.detail.newEntry': '新建條目', + 'journey.detail.editEntry': '編輯條目', + 'journey.detail.noEntries': '還沒有條目', + 'journey.detail.noEntriesHint': '新增一個旅行以產生骨架條目', + 'journey.detail.noPhotos': '還沒有照片', + 'journey.detail.noPhotosHint': + '上傳照片到條目或瀏覽你的 Immich/Synology 相簿', + 'journey.detail.journeyStats': '旅程統計', + 'journey.detail.syncedTrips': '已同步的旅行', + 'journey.detail.noTripsLinked': '尚未關聯旅行', + 'journey.detail.contributors': '貢獻者', + 'journey.detail.readMore': '閱讀更多', + 'journey.detail.prosCons': '優缺點', + 'journey.detail.photos': '照片', + 'journey.detail.day': '第{number}天', + 'journey.detail.places': '個地點', + 'journey.stats.days': '天', + 'journey.stats.cities': '城市', + 'journey.stats.entries': '條目', + 'journey.stats.photos': '照片', + 'journey.stats.places': '地點', + 'journey.skeletons.show': '顯示建議', + 'journey.skeletons.hide': '隱藏建議', + 'journey.verdict.lovedIt': '非常喜歡', + 'journey.verdict.couldBeBetter': '有待改進', + 'journey.synced.places': '個地點', + 'journey.synced.synced': '已同步', + 'journey.editor.discardChangesConfirm': '您有未儲存的變更。要放棄嗎?', + 'journey.editor.uploadFailed': '照片上傳失敗', + 'journey.editor.uploadPhotos': '上傳照片', + 'journey.editor.uploading': '上傳中...', + 'journey.editor.uploadingProgress': '上傳中 {done}/{total}…', + 'journey.editor.uploadPartialFailed': + '{total} 張中有 {failed} 張上傳失敗 — 再次儲存以重試', + 'journey.editor.fromGallery': '從相簿', + 'journey.editor.allPhotosAdded': '所有照片已新增', + 'journey.editor.writeStory': '寫下你的故事...', + 'journey.editor.prosCons': '優缺點', + 'journey.editor.pros': '優點', + 'journey.editor.cons': '缺點', + 'journey.editor.proPlaceholder': '好的方面...', + 'journey.editor.conPlaceholder': '不好的方面...', + 'journey.editor.addAnother': '再新增一個', + 'journey.editor.date': '日期', + 'journey.editor.location': '地點', + 'journey.editor.searchLocation': '搜尋地點...', + 'journey.editor.mood': '心情', + 'journey.editor.weather': '天氣', + 'journey.editor.photoFirst': '第1張', + 'journey.editor.makeFirst': '設為第1張', + 'journey.editor.searching': '搜尋中...', + 'journey.mood.amazing': '太棒了', + 'journey.mood.good': '不錯', + 'journey.mood.neutral': '一般', + 'journey.mood.rough': '糟糕', + 'journey.weather.sunny': '晴天', + 'journey.weather.partly': '多雲', + 'journey.weather.cloudy': '陰天', + 'journey.weather.rainy': '雨天', + 'journey.weather.stormy': '暴風雨', + 'journey.weather.cold': '雪天', + 'journey.trips.linkTrip': '關聯旅行', + 'journey.trips.searchTrip': '搜尋旅行', + 'journey.trips.searchPlaceholder': '旅行名稱或目的地...', + 'journey.trips.noTripsAvailable': '沒有可用的旅行', + 'journey.trips.link': '關聯', + 'journey.trips.tripLinked': '旅行已關聯', + 'journey.trips.linkFailed': '關聯旅行失敗', + 'journey.trips.addTrip': '新增旅行', + 'journey.trips.unlinkTrip': '取消關聯旅行', + 'journey.trips.unlinkMessage': + '取消關聯「{title}」?此旅行中所有已同步的條目和照片將被永久刪除。此操作無法復原。', + 'journey.trips.unlink': '取消關聯', + 'journey.trips.tripUnlinked': '旅行已取消關聯', + 'journey.trips.unlinkFailed': '取消關聯失敗', + 'journey.trips.noTripsLinkedSettings': '未關聯旅行', + 'journey.contributors.invite': '邀請貢獻者', + 'journey.contributors.searchUser': '搜尋使用者', + 'journey.contributors.searchPlaceholder': '使用者名稱或郵箱...', + 'journey.contributors.noUsers': '未找到使用者', + 'journey.contributors.role': '角色', + 'journey.contributors.added': '貢獻者已新增', + 'journey.contributors.addFailed': '新增貢獻者失敗', + 'journey.share.publicShare': '公開分享', + 'journey.share.createLink': '建立分享連結', + 'journey.share.linkCreated': '分享連結已建立', + 'journey.share.createFailed': '建立連結失敗', + 'journey.share.copy': '複製', + 'journey.share.copied': '已複製!', + 'journey.share.timeline': '時間線', + 'journey.share.gallery': '圖庫', + 'journey.share.map': '地圖', + 'journey.share.removeLink': '移除分享連結', + 'journey.share.linkDeleted': '分享連結已刪除', + 'journey.share.deleteFailed': '刪除失敗', + 'journey.share.updateFailed': '更新失敗', + 'journey.invite.role': '角色', + 'journey.invite.viewer': '檢視者', + 'journey.invite.editor': '編輯者', + 'journey.invite.invite': '邀請', + 'journey.invite.inviting': '邀請中...', + 'journey.settings.title': '旅程設定', + 'journey.settings.coverImage': '封面圖片', + 'journey.settings.changeCover': '更換封面', + 'journey.settings.addCover': '新增封面圖片', + 'journey.settings.name': '名稱', + 'journey.settings.subtitle': '副標題', + 'journey.settings.subtitlePlaceholder': '例如 泰國、越南和柬埔寨', + 'journey.settings.endJourney': '封存旅程', + 'journey.settings.reopenJourney': '還原旅程', + 'journey.settings.archived': '旅程已封存', + 'journey.settings.reopened': '旅程已重新開啟', + 'journey.settings.endDescription': '隱藏直播標記。您可以隨時重新開啟。', + 'journey.settings.delete': '刪除', + 'journey.settings.deleteJourney': '刪除旅程', + 'journey.settings.deleteMessage': '刪除「{title}」?所有條目和照片將遺失。', + 'journey.settings.saved': '設定已儲存', + 'journey.settings.saveFailed': '儲存失敗', + 'journey.settings.coverUpdated': '封面已更新', + 'journey.settings.coverFailed': '上傳失敗', + 'journey.settings.failedToDelete': '刪除失敗', + 'journey.entries.deleteTitle': '刪除條目', + 'journey.photosUploaded': '{count} 張照片已上傳', + 'journey.photosUploadFailed': '部分照片上傳失敗', + 'journey.photosAdded': '{count} 張照片已新增', + 'journey.public.notFound': '未找到', + 'journey.public.notFoundMessage': '此旅程不存在或連結已過期。', + 'journey.public.readOnly': '唯讀 · 公開旅程', + 'journey.public.tagline': '旅行資源與探索工具包', + 'journey.public.sharedVia': '分享自', + 'journey.public.madeWith': '由', + 'journey.pdf.journeyBook': '旅程手冊', + 'journey.pdf.madeWith': '由 TREK 製作', + 'journey.pdf.day': '第', + 'journey.pdf.theEnd': '終', + 'journey.pdf.saveAsPdf': '儲存為 PDF', + 'journey.pdf.pages': '頁', + 'journey.picker.tripPeriod': '旅行期間', + 'journey.picker.dateRange': '日期範圍', + 'journey.picker.allPhotos': '所有照片', + 'journey.picker.albums': '相簿', + 'journey.picker.selected': '已選擇', + 'journey.picker.addTo': '新增至', + 'journey.picker.newGallery': '新相簿', + 'journey.picker.selectAll': '全選', + 'journey.picker.deselectAll': '取消全選', + 'journey.picker.noAlbums': '未找到相簿', + 'journey.picker.selectDate': '選擇日期', + 'journey.picker.search': '搜尋', + 'journey.detail.journeyTab': 'Journey', // en-fallback + 'journey.contributors.remove': 'Remove contributor', // en-fallback + 'journey.contributors.removeConfirm': 'Remove {username} from this journey?', // en-fallback + 'journey.contributors.removed': 'Contributor removed', // en-fallback + 'journey.contributors.removeFailed': 'Failed to remove contributor', // en-fallback +}; +export default journey; diff --git a/shared/src/i18n/zh-TW/login.ts b/shared/src/i18n/zh-TW/login.ts new file mode 100644 index 0000000000000000000000000000000000000000..56a52e9a6feba758cc148ccfb5514d273aeb6173 --- /dev/null +++ b/shared/src/i18n/zh-TW/login.ts @@ -0,0 +1,91 @@ +import type { TranslationStrings } from '../types'; + +const login: TranslationStrings = { + 'login.error': '登入失敗,請檢查你的憑據。', + 'login.tagline': '你的旅行。\n你的計劃。', + 'login.description': '透過互動地圖、預算管理和即時同步,協同規劃旅行。', + 'login.features.maps': '互動地圖', + 'login.features.mapsDesc': 'Google Places、路線和聚類', + 'login.features.realtime': '即時同步', + 'login.features.realtimeDesc': '透過 WebSocket 協同規劃', + 'login.features.budget': '預算跟蹤', + 'login.features.budgetDesc': '分類、圖表和人均費用', + 'login.features.collab': '協作', + 'login.features.collabDesc': '多使用者共享旅行', + 'login.features.packing': '行李清單', + 'login.features.packingDesc': '分類、進度和建議', + 'login.features.bookings': '預訂', + 'login.features.bookingsDesc': '航班、酒店、餐廳等', + 'login.features.files': '文件', + 'login.features.filesDesc': '上傳和管理文件', + 'login.features.routes': '智慧路線', + 'login.features.routesDesc': '自動最佳化和匯出到 Google Maps', + 'login.selfHosted': '自託管 · 開源 · 資料由你掌控', + 'login.title': '登入', + 'login.subtitle': '歡迎回來', + 'login.signingIn': '登入中…', + 'login.signIn': '登入', + 'login.createAdmin': '建立管理員賬戶', + 'login.createAdminHint': '為 TREK 設定第一個管理員賬戶。', + 'login.setNewPassword': '設定新密碼', + 'login.setNewPasswordHint': '您必須更改密碼才能繼續。', + 'login.createAccount': '建立賬戶', + 'login.createAccountHint': '註冊新賬戶。', + 'login.creating': '建立中…', + 'login.noAccount': '還沒有賬戶?', + 'login.hasAccount': '已有賬戶?', + 'login.register': '註冊', + 'login.emailPlaceholder': 'your@email.com', + 'login.username': '使用者名稱', + 'login.oidc.registrationDisabled': '註冊已關閉。請聯絡管理員。', + 'login.oidc.noEmail': '未從提供商獲取到郵箱。', + 'login.mfaTitle': '雙因素認證', + 'login.mfaSubtitle': '請輸入身份驗證器應用中的 6 位驗證碼。', + 'login.mfaCodeLabel': '驗證碼', + 'login.mfaCodeRequired': '請輸入身份驗證器應用中的驗證碼。', + 'login.mfaHint': '開啟 Google Authenticator、Authy 或其他 TOTP 應用。', + 'login.mfaBack': '← 返回登入', + 'login.mfaVerify': '驗證', + 'login.invalidInviteLink': '邀請連結無效或已過期', + 'login.oidcFailed': 'OIDC 登入失敗', + 'login.usernameRequired': '使用者名稱為必填', + 'login.passwordMinLength': '密碼至少需要8個字元', + 'login.forgotPassword': '忘記密碼?', + 'login.rememberMe': '記住我', + 'login.forgotPasswordTitle': '重設密碼', + 'login.forgotPasswordBody': + '請輸入您註冊時使用的電子郵件。若帳號存在,我們將傳送重設連結。', + 'login.forgotPasswordSubmit': '傳送重設連結', + 'login.forgotPasswordSentTitle': '請查看您的電子郵件', + 'login.forgotPasswordSentBody': + '若此電子郵件存在帳號,重設連結正在傳送中。連結將於 60 分鐘後失效。', + 'login.forgotPasswordSmtpHintOff': + '提醒:管理員尚未設定 SMTP,重設連結將寫入伺服器控制台,而非透過電子郵件寄送。', + 'login.backToLogin': '返回登入', + 'login.newPassword': '新密碼', + 'login.confirmPassword': '確認新密碼', + 'login.passwordsDontMatch': '兩次輸入的密碼不一致', + 'login.mfaCode': '2FA 驗證碼', + 'login.resetPasswordTitle': '設定新密碼', + 'login.resetPasswordBody': + '請選擇您在此處尚未使用過的強密碼。至少 8 個字元。', + 'login.resetPasswordMfaBody': '請輸入您的 2FA 驗證碼或備用代碼以完成重設。', + 'login.resetPasswordSubmit': '重設密碼', + 'login.resetPasswordVerify': '驗證並重設', + 'login.resetPasswordSuccessTitle': '密碼已更新', + 'login.resetPasswordSuccessBody': '您現在可以使用新密碼登入。', + 'login.resetPasswordInvalidLink': '無效的重設連結', + 'login.resetPasswordInvalidLinkBody': + '此連結遺失或已損壞。請重新申請以繼續。', + 'login.resetPasswordFailed': '重設失敗。連結可能已過期。', + 'login.oidc.tokenFailed': '認證失敗。', + 'login.oidc.invalidState': '會話無效,請重試。', + 'login.demoFailed': '演示登入失敗', + 'login.oidcSignIn': '透過 {name} 登入', + 'login.oidcOnly': '密碼登入已關閉。請透過 SSO 提供商登入。', + 'login.oidcLoggedOut': '您已登出。請重新透過 SSO 提供商登入。', + 'login.demoHint': '試用演示——無需註冊', + 'login.passkey.signIn': '使用 Passkey 登入', + 'login.passkey.failed': 'Passkey 登入失敗,請重試。', +}; +export default login; diff --git a/shared/src/i18n/zh-TW/map.ts b/shared/src/i18n/zh-TW/map.ts new file mode 100644 index 0000000000000000000000000000000000000000..142312266480538dc6191691314bda55fb98163b --- /dev/null +++ b/shared/src/i18n/zh-TW/map.ts @@ -0,0 +1,17 @@ +import type { TranslationStrings } from '../types'; + +const map: TranslationStrings = { + 'map.connections': '連接', + 'map.showConnections': '顯示預訂路線', + 'map.hideConnections': '隱藏預訂路線', + 'poi.searchThisArea': '搜尋此區域', + 'poi.cat.restaurants': '餐廳', + 'poi.cat.cafes': '咖啡廳', + 'poi.cat.bars': '酒吧與夜生活', + 'poi.cat.hotels': '住宿', + 'poi.cat.sights': '景點', + 'poi.cat.museums': '博物館與文化', + 'poi.cat.nature': '自然與公園', + 'poi.cat.activities': '活動', +}; +export default map; diff --git a/shared/src/i18n/zh-TW/members.ts b/shared/src/i18n/zh-TW/members.ts new file mode 100644 index 0000000000000000000000000000000000000000..17049fe3f2d199db43b18f6f84f32bfc7b556909 --- /dev/null +++ b/shared/src/i18n/zh-TW/members.ts @@ -0,0 +1,24 @@ +import type { TranslationStrings } from '../types'; + +const members: TranslationStrings = { + 'members.shareTrip': '分享旅行', + 'members.inviteUser': '邀請使用者', + 'members.selectUser': '選擇使用者…', + 'members.invite': '邀請', + 'members.allHaveAccess': '所有使用者均已擁有訪問許可權。', + 'members.access': '訪問許可權', + 'members.person': '人', + 'members.persons': '人', + 'members.you': '你', + 'members.owner': '所有者', + 'members.leaveTrip': '退出旅行', + 'members.removeAccess': '移除訪問許可權', + 'members.confirmLeave': '退出旅行?你將失去訪問許可權。', + 'members.confirmRemove': '移除該使用者的訪問許可權?', + 'members.loadError': '載入成員失敗', + 'members.added': '已新增', + 'members.addError': '新增失敗', + 'members.removed': '成員已移除', + 'members.removeError': '移除失敗', +}; +export default members; diff --git a/shared/src/i18n/zh-TW/memories.ts b/shared/src/i18n/zh-TW/memories.ts new file mode 100644 index 0000000000000000000000000000000000000000..0d76375f1f14aa843ea9f5154998ae00a76572cf --- /dev/null +++ b/shared/src/i18n/zh-TW/memories.ts @@ -0,0 +1,77 @@ +import type { TranslationStrings } from '../types'; + +const memories: TranslationStrings = { + 'memories.title': '照片', + 'memories.notConnected': '{provider_name} 未連線', + 'memories.notConnectedHint': + '在設定中連線您的 {provider_name} 例項以在此旅行中新增照片。', + 'memories.notConnectedMultipleHint': + '在設定中連線以下任一照片提供商:{provider_names} 以在此旅行中新增照片。', + 'memories.noDates': '為旅行新增日期以載入照片。', + 'memories.noPhotos': '未找到照片', + 'memories.noPhotosHint': '{provider_name} 中未找到此旅行日期範圍內的照片。', + 'memories.photosFound': '張照片', + 'memories.fromOthers': '來自他人', + 'memories.sharePhotos': '分享照片', + 'memories.sharing': '分享中', + 'memories.reviewTitle': '審查您的照片', + 'memories.reviewHint': '點選照片以將其從分享中排除。', + 'memories.shareCount': '分享 {count} 張照片', + 'memories.providerUrl': '伺服器 URL', + 'memories.providerApiKey': 'API 金鑰', + 'memories.providerUsername': '使用者名稱', + 'memories.providerPassword': '密碼', + 'memories.providerOTP': 'MFA 驗證碼(如已啟用)', + 'memories.skipSSLVerification': '跳過 SSL 憑證驗證', + 'memories.immichAutoUpload': '上傳 Journey 照片時同步到 Immich', + 'memories.providerUrlHintSynology': + '在網址中包含照片應用程式路徑,例如 https://nas:5001/photo', + 'memories.testConnection': '測試連線', + 'memories.testShort': '測試', + 'memories.testFirst': '請先測試連線', + 'memories.connected': '已連線', + 'memories.disconnected': '未連線', + 'memories.connectionSuccess': '已連線到 {provider_name}', + 'memories.connectionError': '無法連線到 {provider_name}', + 'memories.saved': '{provider_name} 設定已儲存', + 'memories.providerDisconnectedBanner': + '您與 {provider_name} 的連線已中斷。請在設定中重新連線以查看照片。', + 'memories.saveError': '無法儲存 {provider_name} 設定', + 'memories.oldest': '最早優先', + 'memories.newest': '最新優先', + 'memories.allLocations': '所有地點', + 'memories.addPhotos': '新增照片', + 'memories.linkAlbum': '關聯相簿', + 'memories.selectAlbum': '選擇 {provider_name} 相簿', + 'memories.selectAlbumMultiple': '選擇相簿', + 'memories.noAlbums': '未找到相簿', + 'memories.syncAlbum': '同步相簿', + 'memories.unlinkAlbum': '取消關聯', + 'memories.photos': '張照片', + 'memories.selectPhotos': '從 {provider_name} 選擇照片', + 'memories.selectPhotosMultiple': '選擇照片', + 'memories.selectHint': '點選照片以選擇。', + 'memories.selected': '已選擇', + 'memories.addSelected': '新增 {count} 張照片', + 'memories.alreadyAdded': '已新增', + 'memories.private': '私密', + 'memories.stopSharing': '停止分享', + 'memories.tripDates': '旅行日期', + 'memories.allPhotos': '所有照片', + 'memories.confirmShareTitle': '與旅行成員分享?', + 'memories.confirmShareHint': + '{count} 張照片將對本次旅行的所有成員可見。你可以稍後將單張照片設為私密。', + 'memories.confirmShareButton': '分享照片', + 'memories.error.loadAlbums': '載入相簿失敗', + 'memories.error.linkAlbum': '關聯相簿失敗', + 'memories.error.unlinkAlbum': '取消關聯相簿失敗', + 'memories.error.syncAlbum': '同步相簿失敗', + 'memories.error.loadPhotos': '載入照片失敗', + 'memories.error.addPhotos': '新增照片失敗', + 'memories.error.removePhoto': '刪除照片失敗', + 'memories.error.toggleSharing': '更新共享設定失敗', + 'memories.saveRouteNotConfigured': '此提供商未設定儲存路由', + 'memories.testRouteNotConfigured': '此提供商未設定測試路由', + 'memories.fillRequiredFields': '請填寫所有必填欄位', +}; +export default memories; diff --git a/shared/src/i18n/zh-TW/nav.ts b/shared/src/i18n/zh-TW/nav.ts new file mode 100644 index 0000000000000000000000000000000000000000..35f4ec90ac779ca19a6761c8f91d20c90bd60e2b --- /dev/null +++ b/shared/src/i18n/zh-TW/nav.ts @@ -0,0 +1,20 @@ +import type { TranslationStrings } from '../types'; + +const nav: TranslationStrings = { + 'nav.trip': '旅行', + 'nav.share': '分享', + 'nav.settings': '設定', + 'nav.admin': '管理', + 'nav.logout': '退出登入', + 'nav.lightMode': '淺色模式', + 'nav.darkMode': '深色模式', + 'nav.autoMode': '自動模式', + 'nav.administrator': '管理員', + 'nav.myTrips': '我的旅行', + 'nav.profile': '個人資料', + 'nav.bottomSettings': '設定', + 'nav.bottomAdmin': '管理設定', + 'nav.bottomLogout': '退出登入', + 'nav.bottomAdminBadge': '管理員', +}; +export default nav; diff --git a/shared/src/i18n/zh-TW/notif.ts b/shared/src/i18n/zh-TW/notif.ts new file mode 100644 index 0000000000000000000000000000000000000000..f6abef7ae0cbf69cdb853a7b5b81a435e1e4b4b4 --- /dev/null +++ b/shared/src/i18n/zh-TW/notif.ts @@ -0,0 +1,41 @@ +import type { TranslationStrings } from '../types'; + +const notif: TranslationStrings = { + 'notif.test.title': '[測試] 通知', + 'notif.test.simple.text': '這是一則簡單的測試通知。', + 'notif.test.boolean.text': '你是否接受這則測試通知?', + 'notif.test.navigate.text': '點擊下方前往儀表板。', + 'notif.trip_invite.title': '旅行邀請', + 'notif.trip_invite.text': '{actor} 邀請你加入 {trip}', + 'notif.booking_change.title': '預訂已更新', + 'notif.booking_change.text': '{actor} 更新了 {trip} 中的預訂', + 'notif.trip_reminder.title': '旅行提醒', + 'notif.trip_reminder.text': '你的旅行 {trip} 即將開始!', + 'notif.todo_due.title': '待辦事項即將到期', + 'notif.todo_due.text': '{trip} 中的 {todo} 將於 {due} 到期', + 'notif.vacay_invite.title': 'Vacay Fusion 邀請', + 'notif.vacay_invite.text': '{actor} 邀請你合併假期計畫', + 'notif.photos_shared.title': '照片已分享', + 'notif.photos_shared.text': '{actor} 在 {trip} 中分享了 {count} 張照片', + 'notif.collab_message.title': '新訊息', + 'notif.collab_message.text': '{actor} 在 {trip} 中傳送了一則訊息', + 'notif.packing_tagged.title': '打包指派', + 'notif.packing_tagged.text': '{actor} 在 {trip} 中將 {category} 指派給你', + 'notif.version_available.title': '有新版本可用', + 'notif.version_available.text': 'TREK {version} 現已推出', + 'notif.action.view_trip': '查看旅行', + 'notif.action.view_collab': '查看訊息', + 'notif.action.view_packing': '查看打包', + 'notif.action.view_photos': '查看照片', + 'notif.action.view_vacay': '查看 Vacay', + 'notif.action.view_admin': '前往管理', + 'notif.action.view': '查看', + 'notif.action.accept': '接受', + 'notif.action.decline': '拒絕', + 'notif.generic.title': '通知', + 'notif.generic.text': '你有一則新通知', + 'notif.dev.unknown_event.title': '[DEV] 未知事件', + 'notif.dev.unknown_event.text': + '事件類型「{event}」未在 EVENT_NOTIFICATION_CONFIG 中註冊', +}; +export default notif; diff --git a/shared/src/i18n/zh-TW/notifications.ts b/shared/src/i18n/zh-TW/notifications.ts new file mode 100644 index 0000000000000000000000000000000000000000..afd9fc37f129701de0907628326bad7c2e183411 --- /dev/null +++ b/shared/src/i18n/zh-TW/notifications.ts @@ -0,0 +1,36 @@ +import type { TranslationStrings } from '../types'; + +const notifications: TranslationStrings = { + 'notifications.title': '通知', + 'notifications.markAllRead': '全部標為已讀', + 'notifications.deleteAll': '全部刪除', + 'notifications.showAll': '檢視所有通知', + 'notifications.empty': '暫無通知', + 'notifications.emptyDescription': '您已全部查閱!', + 'notifications.all': '全部', + 'notifications.unreadOnly': '未讀', + 'notifications.markRead': '標為已讀', + 'notifications.markUnread': '標為未讀', + 'notifications.delete': '刪除', + 'notifications.system': '系統', + 'notifications.synologySessionCleared.title': 'Synology Photos 已斷線', + 'notifications.synologySessionCleared.text': + '您的伺服器或帳號已更改 — 請前往設定重新測試連線。', + 'notifications.test.title': '來自 {actor} 的測試通知', + 'notifications.test.text': '這是一條簡單的測試通知。', + 'notifications.test.booleanTitle': '{actor} 請求您的審批', + 'notifications.test.booleanText': '測試布林通知。', + 'notifications.test.accept': '批准', + 'notifications.test.decline': '拒絕', + 'notifications.test.navigateTitle': '檢視詳情', + 'notifications.test.navigateText': '測試跳轉通知。', + 'notifications.test.goThere': '前往', + 'notifications.test.adminTitle': '管理員廣播', + 'notifications.test.adminText': '{actor} 向所有管理員傳送了測試通知。', + 'notifications.test.tripTitle': '{actor} 在您的行程中發帖', + 'notifications.test.tripText': '行程"{trip}"的測試通知。', + 'notifications.versionAvailable.title': '有可用更新', + 'notifications.versionAvailable.text': 'TREK {version} 現已推出。', + 'notifications.versionAvailable.button': '查看詳情', +}; +export default notifications; diff --git a/shared/src/i18n/zh-TW/oauth.ts b/shared/src/i18n/zh-TW/oauth.ts new file mode 100644 index 0000000000000000000000000000000000000000..c70c2d730a34d517342597dcd9b6996e29162c2d --- /dev/null +++ b/shared/src/i18n/zh-TW/oauth.ts @@ -0,0 +1,101 @@ +import type { TranslationStrings } from '../types'; + +const oauth: TranslationStrings = { + 'oauth.scope.group.trips': '行程', + 'oauth.scope.group.places': '地點', + 'oauth.scope.group.atlas': 'Atlas', + 'oauth.scope.group.packing': '行李', + 'oauth.scope.group.todos': '待辦事項', + 'oauth.scope.group.budget': '預算', + 'oauth.scope.group.reservations': '預訂', + 'oauth.scope.group.collab': '協作', + 'oauth.scope.group.notifications': '通知', + 'oauth.scope.group.vacay': '假期', + 'oauth.scope.group.geo': 'Geo', + 'oauth.scope.group.weather': '天氣', + 'oauth.scope.group.journey': '旅程', + 'oauth.scope.trips:read.label': '檢視行程與旅遊計畫', + 'oauth.scope.trips:read.description': '讀取行程、天數、每日筆記及成員', + 'oauth.scope.trips:write.label': '編輯行程與旅遊計畫', + 'oauth.scope.trips:write.description': '建立及更新行程、天數、筆記並管理成員', + 'oauth.scope.trips:delete.label': '刪除行程', + 'oauth.scope.trips:delete.description': '永久刪除整個行程——此操作無法復原', + 'oauth.scope.trips:share.label': '管理分享連結', + 'oauth.scope.trips:share.description': '建立、更新及撤銷行程的公開分享連結', + 'oauth.scope.places:read.label': '檢視地點與地圖資料', + 'oauth.scope.places:read.description': '讀取地點、每日指派、標籤及類別', + 'oauth.scope.places:write.label': '管理地點', + 'oauth.scope.places:write.description': '建立、更新及刪除地點、指派及標籤', + 'oauth.scope.atlas:read.label': '檢視 Atlas', + 'oauth.scope.atlas:read.description': '讀取已造訪的國家、地區及願望清單', + 'oauth.scope.atlas:write.label': '管理 Atlas', + 'oauth.scope.atlas:write.description': '標記已造訪的國家及地區,管理願望清單', + 'oauth.scope.packing:read.label': '檢視行李清單', + 'oauth.scope.packing:read.description': '讀取行李物品、行李袋及類別負責人', + 'oauth.scope.packing:write.label': '管理行李清單', + 'oauth.scope.packing:write.description': + '新增、更新、刪除、勾選及重新排序行李物品和行李袋', + 'oauth.scope.todos:read.label': '檢視待辦清單', + 'oauth.scope.todos:read.description': '讀取行程待辦事項及類別負責人', + 'oauth.scope.todos:write.label': '管理待辦清單', + 'oauth.scope.todos:write.description': + '建立、更新、勾選、刪除及重新排序待辦事項', + 'oauth.scope.budget:read.label': '檢視預算', + 'oauth.scope.budget:read.description': '讀取預算項目及費用明細', + 'oauth.scope.budget:write.label': '管理預算', + 'oauth.scope.budget:write.description': '建立、更新及刪除預算項目', + 'oauth.scope.reservations:read.label': '檢視預訂', + 'oauth.scope.reservations:read.description': '讀取預訂及住宿詳情', + 'oauth.scope.reservations:write.label': '管理預訂', + 'oauth.scope.reservations:write.description': + '建立、更新、刪除及重新排序預訂', + 'oauth.scope.collab:read.label': '檢視協作', + 'oauth.scope.collab:read.description': '讀取協作筆記、投票及訊息', + 'oauth.scope.collab:write.label': '管理協作', + 'oauth.scope.collab:write.description': + '建立、更新及刪除協作筆記、投票及訊息', + 'oauth.scope.notifications:read.label': '檢視通知', + 'oauth.scope.notifications:read.description': '讀取應用程式通知及未讀數量', + 'oauth.scope.notifications:write.label': '管理通知', + 'oauth.scope.notifications:write.description': '將通知標為已讀並回覆', + 'oauth.scope.vacay:read.label': '檢視假期計畫', + 'oauth.scope.vacay:read.description': '讀取假期計畫資料、項目及統計', + 'oauth.scope.vacay:write.label': '管理假期計畫', + 'oauth.scope.vacay:write.description': '建立及管理假期項目、節假日及團隊計畫', + 'oauth.scope.geo:read.label': '地圖與地理編碼', + 'oauth.scope.geo:read.description': + '搜尋地點、解析地圖 URL 及反向地理編碼坐標', + 'oauth.scope.weather:read.label': '天氣預報', + 'oauth.scope.weather:read.description': '取得行程地點及日期的天氣預報', + 'oauth.scope.journey:read.label': '檢視旅程', + 'oauth.scope.journey:read.description': '讀取旅程、條目及貢獻者清單', + 'oauth.scope.journey:write.label': '管理旅程', + 'oauth.scope.journey:write.description': '建立、更新及刪除旅程及其條目', + 'oauth.scope.journey:share.label': '管理旅程連結', + 'oauth.scope.journey:share.description': '建立、更新及撤銷旅程的公開分享連結', + 'oauth.authorize.authorizing': 'Authorizing…', // en-fallback + 'oauth.authorize.loading': 'Loading…', // en-fallback + 'oauth.authorize.errorTitle': 'Authorization Error', // en-fallback + 'oauth.authorize.loginTitle': 'Sign in to continue', // en-fallback + 'oauth.authorize.loginDescription': + '{client} wants access to your TREK account. Please sign in first.', // en-fallback + 'oauth.authorize.loginButton': 'Sign in to TREK', // en-fallback + 'oauth.authorize.requestLabel': 'Authorization Request', // en-fallback + 'oauth.authorize.requestDescription': + 'This application is requesting access to your TREK account.', // en-fallback + 'oauth.authorize.trustNote': + 'Only grant access to applications you trust. Your data stays on your server.', // en-fallback + 'oauth.authorize.selectScope': 'Select at least one scope', // en-fallback + 'oauth.authorize.approveOneScope': 'Approve ({count} scope)', // en-fallback + 'oauth.authorize.approveManyScopes': 'Approve ({count} scopes)', // en-fallback + 'oauth.authorize.approveAccess': 'Approve Access', // en-fallback + 'oauth.authorize.deny': 'Deny', // en-fallback + 'oauth.authorize.choosePermissions': 'Choose which permissions to grant', // en-fallback + 'oauth.authorize.permissionsRequested': 'Permissions requested', // en-fallback + 'oauth.authorize.alwaysIncluded': 'Always included', // en-fallback + 'oauth.authorize.alwaysTool.listTrips': + 'List your trips so the AI can discover trip IDs', // en-fallback + 'oauth.authorize.alwaysTool.getTripSummary': + 'Read a trip overview needed to use any other tool', // en-fallback +}; +export default oauth; diff --git a/shared/src/i18n/zh-TW/packing.ts b/shared/src/i18n/zh-TW/packing.ts new file mode 100644 index 0000000000000000000000000000000000000000..01de6880565109aa5bd72ae802b2f54ee1bbf33d --- /dev/null +++ b/shared/src/i18n/zh-TW/packing.ts @@ -0,0 +1,183 @@ +import type { TranslationStrings } from '../types'; + +const packing: TranslationStrings = { + 'packing.title': '行李清單', + 'packing.empty': '行李清單為空', + 'packing.import': '匯入', + 'packing.importTitle': '匯入裝箱清單', + 'packing.importHint': + '每行一個物品。可選用逗號、分號或製表符分隔類別和數量:名稱, 類別, 數量', + 'packing.importPlaceholder': '牙刷\n防曬霜, 衛生\nT恤, 衣物, 5\n護照, 證件', + 'packing.importCsv': '載入 CSV/TXT', + 'packing.importAction': '匯入 {count}', + 'packing.importSuccess': '已匯入 {count} 項', + 'packing.importError': '匯入失敗', + 'packing.importEmpty': '沒有可匯入的專案', + 'packing.progress': '已打包 {packed}/{total}({percent}%)', + 'packing.clearChecked': '移除 {count} 個已勾選', + 'packing.clearCheckedShort': '移除 {count} 個', + 'packing.suggestions': '建議', + 'packing.suggestionsTitle': '新增建議', + 'packing.allSuggested': '所有建議已新增', + 'packing.allPacked': '全部打包完成!', + 'packing.addPlaceholder': '新增新物品...', + 'packing.categoryPlaceholder': '分類...', + 'packing.filterAll': '全部', + 'packing.filterOpen': '未完成', + 'packing.filterDone': '已完成', + 'packing.emptyTitle': '行李清單為空', + 'packing.emptyHint': '新增物品或使用建議', + 'packing.emptyFiltered': '沒有匹配的物品', + 'packing.menuRename': '重新命名', + 'packing.menuCheckAll': '全部勾選', + 'packing.menuUncheckAll': '取消全部勾選', + 'packing.menuDeleteCat': '刪除分類', + 'packing.addItem': '新增物品', + 'packing.addItemPlaceholder': '物品名稱...', + 'packing.addCategory': '新增分類', + 'packing.newCategoryPlaceholder': '分類名稱(如:衣物)', + 'packing.applyTemplate': '應用模板', + 'packing.template': '模板', + 'packing.templateApplied': '已從模板新增 {count} 個物品', + 'packing.templateError': '應用模板失敗', + 'packing.saveAsTemplate': '儲存為範本', + 'packing.templateName': '範本名稱', + 'packing.templateSaved': '行李清單已儲存為範本', + 'packing.noMembers': '無成員', + 'packing.bags': '行李', + 'packing.noBag': '未分配', + 'packing.totalWeight': '總重量', + 'packing.bagName': '名稱...', + 'packing.addBag': '新增行李', + 'packing.changeCategory': '更改分類', + 'packing.confirm.clearChecked': '確定移除 {count} 個已勾選的物品?', + 'packing.confirm.deleteCat': '確定刪除分類「{name}」及其 {count} 個物品?', + 'packing.defaultCategory': '其他', + 'packing.toast.saveError': '儲存失敗', + 'packing.toast.deleteError': '刪除失敗', + 'packing.toast.renameError': '重新命名失敗', + 'packing.toast.addError': '新增失敗', + 'packing.suggestions.items': [ + { + name: '護照', + category: '證件', + }, + { + name: '身份證', + category: '證件', + }, + { + name: '旅行保險', + category: '證件', + }, + { + name: '機票', + category: '證件', + }, + { + name: '信用卡', + category: '財務', + }, + { + name: '現金', + category: '財務', + }, + { + name: '簽證', + category: '證件', + }, + { + name: 'T恤', + category: '衣物', + }, + { + name: '褲子', + category: '衣物', + }, + { + name: '內衣', + category: '衣物', + }, + { + name: '襪子', + category: '衣物', + }, + { + name: '外套', + category: '衣物', + }, + { + name: '睡衣', + category: '衣物', + }, + { + name: '泳衣', + category: '衣物', + }, + { + name: '雨衣', + category: '衣物', + }, + { + name: '舒適的鞋子', + category: '衣物', + }, + { + name: '牙刷', + category: '洗漱用品', + }, + { + name: '牙膏', + category: '洗漱用品', + }, + { + name: '洗髮水', + category: '洗漱用品', + }, + { + name: '除臭劑', + category: '洗漱用品', + }, + { + name: '防曬霜', + category: '洗漱用品', + }, + { + name: '剃鬚刀', + category: '洗漱用品', + }, + { + name: '充電器', + category: '電子產品', + }, + { + name: '充電寶', + category: '電子產品', + }, + { + name: '耳機', + category: '電子產品', + }, + { + name: '旅行轉換插頭', + category: '電子產品', + }, + { + name: '相機', + category: '電子產品', + }, + { + name: '止痛藥', + category: '健康', + }, + { + name: '創可貼', + category: '健康', + }, + { + name: '消毒液', + category: '健康', + }, + ], +}; +export default packing; diff --git a/shared/src/i18n/zh-TW/pdf.ts b/shared/src/i18n/zh-TW/pdf.ts new file mode 100644 index 0000000000000000000000000000000000000000..9636e197e9d6f5cad276718bf3a95f76020d296e --- /dev/null +++ b/shared/src/i18n/zh-TW/pdf.ts @@ -0,0 +1,10 @@ +import type { TranslationStrings } from '../types'; + +const pdf: TranslationStrings = { + 'pdf.travelPlan': '旅行計劃', + 'pdf.planned': '已規劃', + 'pdf.costLabel': '費用 EUR', + 'pdf.preview': 'PDF 預覽', + 'pdf.saveAsPdf': '儲存為 PDF', +}; +export default pdf; diff --git a/shared/src/i18n/zh-TW/perm.ts b/shared/src/i18n/zh-TW/perm.ts new file mode 100644 index 0000000000000000000000000000000000000000..e37e6ebe949860bbe946e29ca03e3398aef0cba4 --- /dev/null +++ b/shared/src/i18n/zh-TW/perm.ts @@ -0,0 +1,51 @@ +import type { TranslationStrings } from '../types'; + +const perm: TranslationStrings = { + 'perm.title': '許可權設定', + 'perm.subtitle': '控制誰可以在應用中執行操作', + 'perm.saved': '許可權設定已儲存', + 'perm.resetDefaults': '恢復預設', + 'perm.customized': '已自定義', + 'perm.level.admin': '僅管理員', + 'perm.level.tripOwner': '旅行所有者', + 'perm.level.tripMember': '旅行成員', + 'perm.level.everybody': '所有人', + 'perm.cat.trip': '旅行管理', + 'perm.cat.members': '成員管理', + 'perm.cat.files': '檔案', + 'perm.cat.content': '內容與日程', + 'perm.cat.extras': '預算、行李與協作', + 'perm.action.trip_create': '建立旅行', + 'perm.action.trip_edit': '編輯旅行詳情', + 'perm.action.trip_delete': '刪除旅行', + 'perm.action.trip_archive': '歸檔 / 取消歸檔旅行', + 'perm.action.trip_cover_upload': '上傳封面圖片', + 'perm.action.member_manage': '新增 / 移除成員', + 'perm.action.file_upload': '上傳檔案', + 'perm.action.file_edit': '編輯檔案後設資料', + 'perm.action.file_delete': '刪除檔案', + 'perm.action.place_edit': '新增 / 編輯 / 刪除地點', + 'perm.action.day_edit': '編輯日程、備註與分配', + 'perm.action.reservation_edit': '管理預訂', + 'perm.action.budget_edit': '管理預算', + 'perm.action.packing_edit': '管理行李清單', + 'perm.action.collab_edit': '協作(筆記、投票、聊天)', + 'perm.action.share_manage': '管理分享連結', + 'perm.actionHint.trip_create': '誰可以建立新旅行', + 'perm.actionHint.trip_edit': '誰可以更改旅行名稱、日期、描述和貨幣', + 'perm.actionHint.trip_delete': '誰可以永久刪除旅行', + 'perm.actionHint.trip_archive': '誰可以歸檔或取消歸檔旅行', + 'perm.actionHint.trip_cover_upload': '誰可以上傳或更改封面圖片', + 'perm.actionHint.member_manage': '誰可以邀請或移除旅行成員', + 'perm.actionHint.file_upload': '誰可以向旅行上傳檔案', + 'perm.actionHint.file_edit': '誰可以編輯檔案描述和連結', + 'perm.actionHint.file_delete': '誰可以將檔案移至回收站或永久刪除', + 'perm.actionHint.place_edit': '誰可以新增、編輯或刪除地點', + 'perm.actionHint.day_edit': '誰可以編輯日程、日程備註和地點分配', + 'perm.actionHint.reservation_edit': '誰可以建立、編輯或刪除預訂', + 'perm.actionHint.budget_edit': '誰可以建立、編輯或刪除預算專案', + 'perm.actionHint.packing_edit': '誰可以管理行李物品和包袋', + 'perm.actionHint.collab_edit': '誰可以建立筆記、投票和傳送訊息', + 'perm.actionHint.share_manage': '誰可以建立或刪除公開分享連結', +}; +export default perm; diff --git a/shared/src/i18n/zh-TW/photos.ts b/shared/src/i18n/zh-TW/photos.ts new file mode 100644 index 0000000000000000000000000000000000000000..2e8bcf43511dc1231cf2a2f6fe1ad31bae1709f9 --- /dev/null +++ b/shared/src/i18n/zh-TW/photos.ts @@ -0,0 +1,25 @@ +import type { TranslationStrings } from '../types'; + +const photos: TranslationStrings = { + 'photos.title': '照片', + 'photos.subtitle': '{trip} 的 {count} 張照片', + 'photos.dropHere': '將照片拖放至此...', + 'photos.dropHereActive': '將照片拖放至此', + 'photos.captionForAll': '標題(所有)', + 'photos.captionPlaceholder': '可選標題...', + 'photos.addCaption': '新增標題...', + 'photos.allDays': '所有天', + 'photos.noPhotos': '暫無照片', + 'photos.uploadHint': '上傳你的旅行照片', + 'photos.clickToSelect': '或點選選擇', + 'photos.linkPlace': '關聯地點', + 'photos.noPlace': '無地點', + 'photos.uploadN': '上傳 {n} 張照片', + 'photos.linkDay': '關聯天數', + 'photos.noDay': '無天數', + 'photos.dayLabel': '第 {number} 天', + 'photos.photoSelected': '張照片已選擇', + 'photos.photosSelected': '張照片已選擇', + 'photos.fileTypeHint': 'JPG, PNG, WebP · 最大 10 MB · 最多 30 張照片', +}; +export default photos; diff --git a/shared/src/i18n/zh-TW/places.ts b/shared/src/i18n/zh-TW/places.ts new file mode 100644 index 0000000000000000000000000000000000000000..4676ccf43fa2c6810f7330fa6c4fe0b91b023dc9 --- /dev/null +++ b/shared/src/i18n/zh-TW/places.ts @@ -0,0 +1,92 @@ +import type { TranslationStrings } from '../types'; + +const places: TranslationStrings = { + 'places.addPlace': '新增地點/活動', + 'places.importFile': '匯入檔案', + 'places.sidebarDrop': '拖放以匯入', + 'places.importFileHint': + '從 Google My Maps、Google Earth 或 GPS 追蹤器等工具匯入 .gpx、.kml 或 .kmz 檔案。', + 'places.importFileDropHere': '點選以選取檔案或拖放至此處', + 'places.importFileDropActive': '放開檔案以選取', + 'places.importFileUnsupported': + '不支援的檔案類型,請使用 .gpx、.kml 或 .kmz。', + 'places.importFileTooLarge': '檔案過大。最大上傳大小為 {maxMb} MB。', + 'places.importFileError': '匯入失敗', + 'places.importAllSkipped': '所有地點已在行程中。', + 'places.gpxImported': '已從 GPX 匯入 {count} 個地點', + 'places.gpxImportTypes': '要匯入什麼?', + 'places.gpxImportWaypoints': '路點', + 'places.gpxImportRoutes': '路線', + 'places.gpxImportTracks': '軌跡(含路徑幾何)', + 'places.gpxImportNoneSelected': '請至少選擇一種匯入類型。', + 'places.kmlImportTypes': '要匯入什麼?', + 'places.kmlImportPoints': '點(Placemarks)', + 'places.kmlImportPaths': '路徑(LineStrings)', + 'places.kmlImportNoneSelected': '請至少選擇一種類型。', + 'places.selectionCount': '已選 {count} 項', + 'places.deleteSelected': '刪除所選', + 'places.kmlKmzImported': '已從 KMZ/KML 匯入 {count} 個地點', + 'places.urlResolved': '已從 URL 匯入地點', + 'places.importList': '列表匯入', + 'places.kmlKmzSummaryValues': + 'Placemarks:{total} • 已匯入:{created} • 已略過:{skipped}', + 'places.importGoogleList': 'Google 列表', + 'places.importNaverList': 'Naver 列表', + 'places.googleListHint': '貼上共享的 Google Maps 列表連結以匯入所有地點。', + 'places.googleListImported': '已從"{list}"匯入 {count} 個地點', + 'places.googleListError': 'Google Maps 列表匯入失敗', + 'places.naverListHint': '貼上共享的 Naver Maps 列表連結以匯入所有地點。', + 'places.naverListImported': '已從"{list}"匯入 {count} 個地點', + 'places.naverListError': 'Naver Maps 列表匯入失敗', + 'places.viewDetails': '檢視詳情', + 'places.assignToDay': '新增到哪一天?', + 'places.all': '全部', + 'places.unplanned': '未規劃', + 'places.filterTracks': '路線', + 'places.search': '搜尋地點...', + 'places.allCategories': '所有分類', + 'places.categoriesSelected': '個分類', + 'places.clearFilter': '清除篩選', + 'places.count': '{count} 個地點', + 'places.countSingular': '1 個地點', + 'places.allPlanned': '所有地點已規劃', + 'places.noneFound': '未找到地點', + 'places.editPlace': '編輯地點', + 'places.formName': '名稱', + 'places.formNamePlaceholder': '如:埃菲爾鐵塔', + 'places.formDescription': '描述', + 'places.formDescriptionPlaceholder': '簡短描述...', + 'places.formAddress': '地址', + 'places.formAddressPlaceholder': '街道、城市、國家', + 'places.formLat': '緯度(如 48.8566)', + 'places.formLng': '經度(如 2.3522)', + 'places.formCategory': '分類', + 'places.noCategory': '無分類', + 'places.categoryNamePlaceholder': '分類名稱', + 'places.formTime': '時間', + 'places.startTime': '開始', + 'places.endTime': '結束', + 'places.endTimeBeforeStart': '結束時間早於開始時間', + 'places.timeCollision': '時間衝突:', + 'places.formWebsite': '網站', + 'places.formNotes': '備註', + 'places.formNotesPlaceholder': '個人備註...', + 'places.formReservation': '預訂', + 'places.reservationNotesPlaceholder': '預訂備註、確認號...', + 'places.mapsSearchPlaceholder': '搜尋地點...', + 'places.mapsSearchError': '地點搜尋失敗。', + 'places.loadingDetails': '正在載入地點詳情…', + 'places.osmHint': + '使用 OpenStreetMap 搜尋(無照片、營業時間或評分)。在設定中新增 Google API 金鑰以獲取完整資訊。', + 'places.osmActive': + '透過 OpenStreetMap 搜尋(無照片、評分或營業時間)。在設定中新增 Google API 金鑰以獲取增強資料。', + 'places.categoryCreateError': '建立分類失敗', + 'places.nameRequired': '請輸入名稱', + 'places.saveError': '儲存失敗', + 'places.duplicateExists': "'{name}' 已在此行程中。", + 'places.addAnyway': '仍要新增', + 'places.enrichOnImport': '透過 Google 豐富地點資訊', + 'places.enrichOnImportHint': + '查詢每個匯入的地點以補上照片、地址與聯絡資訊。需要 Google Maps 金鑰。', +}; +export default places; diff --git a/shared/src/i18n/zh-TW/planner.ts b/shared/src/i18n/zh-TW/planner.ts new file mode 100644 index 0000000000000000000000000000000000000000..ad0c561cbda097347c1872d38c55f88ae34284b4 --- /dev/null +++ b/shared/src/i18n/zh-TW/planner.ts @@ -0,0 +1,67 @@ +import type { TranslationStrings } from '../types'; + +const planner: TranslationStrings = { + 'planner.places': '地點', + 'planner.bookings': '預訂', + 'planner.packingList': '行李清單', + 'planner.documents': '文件', + 'planner.dayPlan': '日程計劃', + 'planner.reservations': '預訂', + 'planner.minTwoPlaces': '至少需要 2 個有座標的地點', + 'planner.noGeoPlaces': '沒有有座標的地點', + 'planner.routeCalculated': '路線已計算', + 'planner.routeCalcFailed': '無法計算路線', + 'planner.routeError': '路線計算錯誤', + 'planner.icsExportFailed': 'ICS 匯出失敗', + 'planner.routeOptimized': '路線已最佳化', + 'planner.reservationUpdated': '預訂已更新', + 'planner.reservationAdded': '預訂已新增', + 'planner.confirmDeleteReservation': '刪除預訂?', + 'planner.reservationDeleted': '預訂已刪除', + 'planner.days': '天', + 'planner.allPlaces': '所有地點', + 'planner.totalPlaces': '共 {n} 個地點', + 'planner.noDaysPlanned': '尚未規劃天數', + 'planner.editTrip': '編輯旅行 →', + 'planner.placeOne': '1 個地點', + 'planner.placeN': '{n} 個地點', + 'planner.addNote': '新增備註', + 'planner.noEntries': '當天無條目', + 'planner.addPlace': '新增地點/活動', + 'planner.addPlaceShort': '+ 新增地點/活動', + 'planner.resPending': '預訂待確認 · ', + 'planner.resConfirmed': '預訂已確認 · ', + 'planner.notePlaceholder': '備註…', + 'planner.noteTimePlaceholder': '時間(可選)', + 'planner.noteExamplePlaceholder': + '如:14:30 從中央車站乘 S3,7 號碼頭渡輪,午餐休息…', + 'planner.totalCost': '總費用', + 'planner.searchPlaces': '搜尋地點…', + 'planner.allCategories': '所有分類', + 'planner.noPlacesFound': '未找到地點', + 'planner.addFirstPlace': '新增第一個地點', + 'planner.noReservations': '暫無預訂', + 'planner.addFirstReservation': '新增第一個預訂', + 'planner.new': '新建', + 'planner.addToDay': '+ 天', + 'planner.calculating': '計算中…', + 'planner.route': '路線', + 'planner.optimize': '最佳化', + 'planner.openGoogleMaps': '在 Google Maps 中開啟', + 'planner.selectDayHint': '從左側列表選擇一天以檢視日程計劃', + 'planner.noPlacesForDay': '當天暫無地點', + 'planner.addPlacesLink': '新增地點 →', + 'planner.minTotal': '分鐘 合計', + 'planner.noReservation': '無預訂', + 'planner.removeFromDay': '從當天移除', + 'planner.addToThisDay': '新增到當天', + 'planner.overview': '概覽', + 'planner.noDays': '暫無天數', + 'planner.editTripToAddDays': '編輯旅行以新增天數', + 'planner.dayCount': '{n} 天', + 'planner.clickToUnlock': '點選解鎖', + 'planner.keepPosition': '路線最佳化時保持位置', + 'planner.dayDetails': '日程詳情', + 'planner.dayN': '第 {n} 天', +}; +export default planner; diff --git a/shared/src/i18n/zh-TW/register.ts b/shared/src/i18n/zh-TW/register.ts new file mode 100644 index 0000000000000000000000000000000000000000..dd22ae77e419391d969db4ec11cd728f84a361e2 --- /dev/null +++ b/shared/src/i18n/zh-TW/register.ts @@ -0,0 +1,25 @@ +import type { TranslationStrings } from '../types'; + +const register: TranslationStrings = { + 'register.passwordMismatch': '兩次輸入的密碼不一致', + 'register.passwordTooShort': '密碼至少需要 8 個字元', + 'register.failed': '註冊失敗', + 'register.getStarted': '開始使用', + 'register.subtitle': '建立賬戶,開始規劃你的夢想旅行。', + 'register.feature1': '無限旅行計劃', + 'register.feature2': '互動地圖檢視', + 'register.feature3': '管理地點和分類', + 'register.feature4': '跟蹤預訂', + 'register.feature5': '建立行李清單', + 'register.feature6': '儲存照片和檔案', + 'register.createAccount': '建立賬戶', + 'register.startPlanning': '開始規劃你的旅行', + 'register.minChars': '至少 6 個字元', + 'register.confirmPassword': '確認密碼', + 'register.repeatPassword': '重複密碼', + 'register.registering': '註冊中...', + 'register.register': '註冊', + 'register.hasAccount': '已有賬戶?', + 'register.signIn': '登入', +}; +export default register; diff --git a/shared/src/i18n/zh-TW/reservations.ts b/shared/src/i18n/zh-TW/reservations.ts new file mode 100644 index 0000000000000000000000000000000000000000..638524a8cc064f22416dbef7b0af7b4fbe08dc7d --- /dev/null +++ b/shared/src/i18n/zh-TW/reservations.ts @@ -0,0 +1,159 @@ +import type { TranslationStrings } from '../types'; + +const reservations: TranslationStrings = { + 'reservations.title': '預訂', + 'reservations.empty': '暫無預訂', + 'reservations.emptyHint': '新增航班、酒店等預訂資訊', + 'reservations.add': '新增預訂', + 'reservations.addManual': '手動新增', + 'reservations.placeHint': + '提示:建議從地點直接建立預訂,以便與日程計劃關聯。', + 'reservations.confirmed': '已確認', + 'reservations.pending': '待確認', + 'reservations.summary': '{confirmed} 已確認,{pending} 待確認', + 'reservations.fromPlan': '來自計劃', + 'reservations.showFiles': '檢視檔案', + 'reservations.editTitle': '編輯預訂', + 'reservations.status': '狀態', + 'reservations.datetime': '日期和時間', + 'reservations.startTime': '開始時間', + 'reservations.endTime': '結束時間', + 'reservations.date': '日期', + 'reservations.time': '時間', + 'reservations.timeAlt': '時間(備選,如 19:30)', + 'reservations.notes': '備註', + 'reservations.notesPlaceholder': '其他備註...', + 'reservations.meta.airline': '航空公司', + 'reservations.meta.flightNumber': '航班號', + 'reservations.meta.from': '出發', + 'reservations.meta.to': '到達', + 'reservations.layover.route': '航線', + 'reservations.layover.stop': '中轉站', + 'reservations.layover.addStop': '新增中轉站', + 'reservations.layover.connection': '轉乘航班', + 'reservations.layover.layover': '轉機等候', + 'reservations.needsReview': '待確認', + 'reservations.needsReviewHint': '無法自動匹配機場 — 請確認位置。', + 'reservations.searchLocation': '搜尋車站、港口、地址...', + 'reservations.meta.trainNumber': '車次', + 'reservations.meta.platform': '站臺', + 'reservations.meta.seat': '座位', + 'reservations.meta.checkIn': '入住', + 'reservations.meta.checkInUntil': '入住截止', + 'reservations.meta.checkOut': '退房', + 'reservations.meta.linkAccommodation': '住宿', + 'reservations.meta.pickAccommodation': '關聯住宿', + 'reservations.meta.noAccommodation': '無', + 'reservations.meta.hotelPlace': '住宿', + 'reservations.meta.pickHotel': '選擇住宿', + 'reservations.meta.fromDay': '從', + 'reservations.meta.toDay': '到', + 'reservations.meta.selectDay': '選擇日期', + 'reservations.type.flight': '航班', + 'reservations.type.hotel': '住宿', + 'reservations.type.restaurant': '餐廳', + 'reservations.type.train': '火車', + 'reservations.type.car': '汽車', + 'reservations.type.cruise': '郵輪', + 'reservations.type.event': '活動', + 'reservations.type.tour': '旅遊團', + 'reservations.type.other': '其他', + 'reservations.type.bus': '公車', + 'reservations.type.ferry': '渡輪', + 'reservations.type.bicycle': '自行車', + 'reservations.type.taxi': '計程車', + 'reservations.type.transport_other': '其他', + 'reservations.confirm.delete': '確定要刪除預訂「{name}」嗎?', + 'reservations.confirm.deleteTitle': '刪除預訂?', + 'reservations.confirm.deleteBody': '"{name}" 將被永久刪除。', + 'reservations.toast.updated': '預訂已更新', + 'reservations.toast.removed': '預訂已刪除', + 'reservations.toast.fileUploaded': '檔案已上傳', + 'reservations.toast.uploadError': '上傳失敗', + 'reservations.newTitle': '新建預訂', + 'reservations.bookingType': '預訂型別', + 'reservations.titleLabel': '標題', + 'reservations.titlePlaceholder': '如:漢莎 LH123、阿德隆酒店...', + 'reservations.locationAddress': '地點 / 地址', + 'reservations.locationPlaceholder': '地址、機場、酒店...', + 'reservations.confirmationCode': '預訂碼', + 'reservations.confirmationPlaceholder': '如:ABC12345', + 'reservations.day': '日期', + 'reservations.noDay': '無日期', + 'reservations.place': '地點', + 'reservations.noPlace': '無地點', + 'reservations.pendingSave': '將被儲存…', + 'reservations.uploading': '上傳中...', + 'reservations.attachFile': '附加檔案', + 'reservations.linkExisting': '關聯已有檔案', + 'reservations.toast.saveError': '儲存失敗', + 'reservations.toast.updateError': '更新失敗', + 'reservations.toast.deleteError': '刪除失敗', + 'reservations.confirm.remove': '移除「{name}」的預訂?', + 'reservations.linkAssignment': '關聯日程分配', + 'reservations.pickAssignment': '從計劃中選擇一個分配...', + 'reservations.noAssignment': '無關聯(獨立)', + 'reservations.price': '價格', + 'reservations.budgetCategory': '預算分類', + 'reservations.budgetCategoryPlaceholder': '如:交通、住宿', + 'reservations.budgetCategoryAuto': '自動(依預訂類型)', + 'reservations.budgetHint': '儲存時將自動建立預算條目。', + 'reservations.departureDate': '出發日期', + 'reservations.arrivalDate': '到達日期', + 'reservations.departureTime': '出發時間', + 'reservations.arrivalTime': '到達時間', + 'reservations.pickupDate': '取車日期', + 'reservations.returnDate': '還車日期', + 'reservations.pickupTime': '取車時間', + 'reservations.returnTime': '還車時間', + 'reservations.endDate': '結束日期', + 'reservations.meta.departureTimezone': '出發時區', + 'reservations.meta.arrivalTimezone': '到達時區', + 'reservations.span.departure': '出發', + 'reservations.span.arrival': '到達', + 'reservations.span.inTransit': '途中', + 'reservations.span.pickup': '取車', + 'reservations.span.return': '還車', + 'reservations.span.active': '進行中', + 'reservations.span.start': '開始', + 'reservations.span.end': '結束', + 'reservations.span.ongoing': '進行中', + 'reservations.validation.endBeforeStart': + '結束日期/時間必須晚於開始日期/時間', + 'reservations.addBooking': '新增預訂', + 'reservations.import.title': '匯入訂位確認', + 'reservations.import.cta': '從檔案匯入', + 'reservations.import.dropHere': '將訂位確認檔案拖放到此處,或點擊選擇', + 'reservations.import.dropActive': '放開檔案以匯入', + 'reservations.import.acceptedFormats': '支援格式:EML、PDF、PKPass、HTML、TXT(每個最大 10 MB,最多 5 個檔案)', + 'reservations.import.parsing': '正在解析檔案…', + 'reservations.import.previewHeading': '找到 {count} 筆預訂', + 'reservations.import.previewEmpty': '無法從上傳的檔案中提取任何預訂資訊。', + 'reservations.import.removeItem': '移除', + 'reservations.import.confirm': '匯入 {count} 筆預訂', + 'reservations.import.back': '返回', + 'reservations.import.success': '已匯入 {count} 筆預訂', + 'reservations.import.partialFailure': '已匯入 {created} 筆,{failed} 筆失敗', + 'reservations.import.error': '解析失敗。請確保檔案是有效的訂位確認。', + 'reservations.import.unavailable': '此伺服器上的預訂匯入功能不可用。', + 'reservations.import.unsupportedFormat': '不支援的檔案格式。請使用 EML、PDF、PKPass、HTML 或 TXT。', + 'reservations.import.fileTooLarge': '檔案「{name}」超過 10 MB 限制。', + 'reservations.airtrail.title': '從 AirTrail 匯入', + 'reservations.airtrail.cta': 'AirTrail', + 'reservations.airtrail.synced': 'AirTrail', + 'reservations.airtrail.syncedHint': '已從 AirTrail 同步——編輯會雙向保持同步。', + 'reservations.airtrail.notSynced': '未同步', + 'reservations.airtrail.notSyncedHint': '此航班已在 AirTrail 中移除,不再同步。', + 'reservations.airtrail.loadError': '無法載入你的 AirTrail 航班。', + 'reservations.airtrail.imported': '已匯入 {count} 筆航班', + 'reservations.airtrail.skippedDuplicate': '{count} 筆已在此行程中,已略過', + 'reservations.airtrail.nothingImported': '沒有可匯入的項目。', + 'reservations.airtrail.importError': '匯入失敗。請再試一次。', + 'reservations.airtrail.undo': '從 AirTrail 匯入', + 'reservations.airtrail.alreadyImported': '已匯入', + 'reservations.airtrail.duringTrip': '行程期間', + 'reservations.airtrail.otherFlights': '其他航班', + 'reservations.airtrail.empty': '在你的 AirTrail 帳戶中找不到任何航班。', + 'reservations.airtrail.importCta': '匯入 {count}', +}; +export default reservations; diff --git a/shared/src/i18n/zh-TW/settings.ts b/shared/src/i18n/zh-TW/settings.ts new file mode 100644 index 0000000000000000000000000000000000000000..aaf8cbc0825960746030d569e7f2fc518b0f6c10 --- /dev/null +++ b/shared/src/i18n/zh-TW/settings.ts @@ -0,0 +1,331 @@ +import type { TranslationStrings } from '../types'; + +const settings: TranslationStrings = { + 'settings.title': '設定', + 'settings.subtitle': '配置你的個人設定', + 'settings.tabs.display': '顯示', + 'settings.tabs.map': '地圖', + 'settings.tabs.notifications': '通知', + 'settings.tabs.integrations': '整合', + 'settings.tabs.account': '帳戶', + 'settings.tabs.offline': 'Offline', + 'settings.tabs.about': '關於', + 'settings.map': '地圖', + 'settings.mapTemplate': '地圖模板', + 'settings.mapTemplatePlaceholder.select': '選擇模板...', + 'settings.mapDefaultHint': '留空則使用 OpenStreetMap(預設)', + 'settings.mapTemplatePlaceholder': + 'https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', + 'settings.mapHint': '地圖瓦片 URL 模板', + 'settings.mapProvider': '地圖提供商', + 'settings.mapProviderHint': + '影響行程規劃和旅程地圖。Atlas 始終使用 Leaflet。', + 'settings.mapLeafletSubtitle': '經典 2D,任何柵格瓦片', + 'settings.mapMapboxSubtitle': '向量瓦片、3D 建築和地形', + 'settings.mapExperimental': '實驗性', + 'settings.mapMapboxToken': 'Mapbox 存取權杖', + 'settings.mapMapboxTokenHint': '公開權杖 (pk.*) 來自', + 'settings.mapMapboxTokenLink': 'mapbox.com → 存取權杖', + 'settings.mapStyle': '地圖樣式', + 'settings.mapStylePlaceholder': '選擇 Mapbox 樣式', + 'settings.mapStyleHint': '預設或您自己的 mapbox://styles/USER/ID URL', + 'settings.map3dBuildings': '3D 建築和地形', + 'settings.map3dHint': '傾斜 + 真實 3D 建築拉伸 — 適用於所有樣式,包括衛星。', + 'settings.mapHighQuality': '高畫質模式', + 'settings.mapHighQualityHint': + '抗鋸齒 + 地球投影,帶來更清晰的邊緣和更真實的世界視圖。', + 'settings.mapHighQualityWarning': '可能影響低階裝置的效能。', + 'settings.mapTipLabel': '提示:', + 'settings.mapTip': + '右鍵點擊並拖曳以旋轉/傾斜地圖。中鍵點擊新增地點(右鍵用於旋轉)。', + 'settings.latitude': '緯度', + 'settings.longitude': '經度', + 'settings.saveMap': '儲存地圖', + 'settings.apiKeys': 'API 金鑰', + 'settings.mapsKey': 'Google Maps API 金鑰', + 'settings.mapsKeyHint': + '用於地點搜尋。需要 Places API (New)。在 console.cloud.google.com 獲取', + 'settings.weatherKey': 'OpenWeatherMap API 金鑰', + 'settings.weatherKeyHint': '用於天氣資料。在 openweathermap.org/api 免費獲取', + 'settings.keyPlaceholder': '輸入金鑰...', + 'settings.configured': '已配置', + 'settings.saveKeys': '儲存金鑰', + 'settings.display': '顯示', + 'settings.colorMode': '顏色模式', + 'settings.light': '淺色', + 'settings.dark': '深色', + 'settings.auto': '自動', + 'settings.language': '語言', + 'settings.temperature': '溫度單位', + 'settings.timeFormat': '時間格式', + 'settings.blurBookingCodes': '模糊預訂程式碼', + 'settings.optimizeFromAccommodation': '從住宿地點最佳化路線', + 'settings.optimizeFromAccommodationHint': + '最佳化某一天的行程時,路線從你早上起床的飯店出發,並在你當晚入住的飯店結束。', + 'settings.notifications': '通知', + 'settings.notifyTripInvite': '旅行邀請', + 'settings.notifyBookingChange': '預訂變更', + 'settings.notifyTripReminder': '旅行提醒', + 'settings.notifyTodoDue': '待辦事項即將到期', + 'settings.notifyVacayInvite': 'Vacay 融合邀請', + 'settings.notifyPhotosShared': '共享照片 (Immich)', + 'settings.notifyCollabMessage': '聊天訊息 (Collab)', + 'settings.notifyPackingTagged': '行李清單:分配', + 'settings.notifyWebhook': 'Webhook 通知', + 'settings.notifyVersionAvailable': '有新版本可用', + 'settings.notificationPreferences.email': '電子郵件', + 'settings.notificationPreferences.webhook': 'Webhook', + 'settings.notificationPreferences.inapp': '應用程式內', + 'settings.notificationPreferences.ntfy': 'Ntfy', + 'settings.notificationPreferences.noChannels': + '未配置通知渠道。請聯絡管理員設定電子郵件或 Webhook 通知。', + 'settings.webhookUrl.label': 'Webhook URL', + 'settings.webhookUrl.placeholder': 'https://discord.com/api/webhooks/...', + 'settings.webhookUrl.hint': + '輸入您的 Discord、Slack 或自訂 Webhook URL 以接收通知。', + 'settings.webhookUrl.saved': 'Webhook URL 已儲存', + 'settings.webhookUrl.test': '測試', + 'settings.webhookUrl.testSuccess': '測試 Webhook 傳送成功', + 'settings.webhookUrl.testFailed': '測試 Webhook 傳送失敗', + 'settings.ntfyUrl.topicLabel': 'Ntfy 主題', + 'settings.ntfyUrl.topicPlaceholder': 'my-trek-alerts', + 'settings.ntfyUrl.serverLabel': 'Ntfy 伺服器 URL(選填)', + 'settings.ntfyUrl.serverPlaceholder': 'https://ntfy.sh', + 'settings.ntfyUrl.hint': + '輸入您的 Ntfy 主題以接收推播通知。將伺服器留空以使用管理員設定的預設值。', + 'settings.ntfyUrl.tokenLabel': '存取權杖(選填)', + 'settings.ntfyUrl.tokenHint': '受密碼保護的主題需要此項目。', + 'settings.ntfyUrl.saved': 'Ntfy 設定已儲存', + 'settings.ntfyUrl.test': '測試', + 'settings.ntfyUrl.testSuccess': '測試 Ntfy 通知傳送成功', + 'settings.ntfyUrl.testFailed': '測試 Ntfy 通知失敗', + 'settings.ntfyUrl.tokenCleared': '存取權杖已清除', + 'settings.notificationsDisabled': + '通知尚未配置。請聯絡管理員啟用電子郵件或 Webhook 通知。', + 'settings.notificationsActive': '活躍頻道', + 'settings.notificationsManagedByAdmin': '通知事件由管理員配置。', + 'settings.on': '開', + 'settings.off': '關', + 'settings.mcp.title': 'MCP 配置', + 'settings.mcp.endpoint': 'MCP 端點', + 'settings.mcp.clientConfig': '客戶端配置', + 'settings.mcp.clientConfigHint': + '將 替換為下方列表中的 API 令牌。npx 的路徑可能需要根據您的系統進行調整(例如 Windows 上為 C:\\PROGRA~1\\nodejs\\npx.cmd)。', + 'settings.mcp.clientConfigHintOAuth': + '將 和 替換為上方建立的 OAuth 2.1 客戶端所顯示的憑據。首次連線時,mcp-remote 將開啟瀏覽器完成授權。npx 的路徑可能需要根據您的系統進行調整(例如 Windows 上為 C:\\PROGRA~1\\nodejs\\npx.cmd)。', + 'settings.mcp.copy': '複製', + 'settings.mcp.copied': '已複製!', + 'settings.mcp.apiTokens': 'API 令牌', + 'settings.mcp.createToken': '建立新令牌', + 'settings.mcp.noTokens': '暫無令牌,請建立一個以連線 MCP 客戶端。', + 'settings.mcp.tokenCreatedAt': '創建於', + 'settings.mcp.tokenUsedAt': '使用於', + 'settings.mcp.deleteTokenTitle': '刪除令牌', + 'settings.mcp.deleteTokenMessage': + '此令牌將立即失效,使用它的所有 MCP 客戶端將失去訪問許可權。', + 'settings.mcp.modal.createTitle': '建立 API 令牌', + 'settings.mcp.modal.tokenName': '令牌名稱', + 'settings.mcp.modal.tokenNamePlaceholder': '例如:Claude Desktop、工作電腦', + 'settings.mcp.modal.creating': '建立中…', + 'settings.mcp.modal.create': '建立令牌', + 'settings.mcp.modal.createdTitle': '令牌已建立', + 'settings.mcp.modal.createdWarning': + '此令牌只會顯示一次,請立即複製並妥善儲存——無法找回。', + 'settings.mcp.modal.done': '完成', + 'settings.mcp.toast.created': '令牌已建立', + 'settings.mcp.toast.createError': '建立令牌失敗', + 'settings.mcp.toast.deleted': '令牌已刪除', + 'settings.mcp.toast.deleteError': '刪除令牌失敗', + 'settings.mcp.apiTokensDeprecated': + 'API 金鑰已棄用,將於未來版本中移除。請改用 OAuth 2.1 客戶端。', + 'settings.oauth.clients': 'OAuth 2.1 客戶端', + 'settings.oauth.clientsHint': + '註冊 OAuth 2.1 客戶端,讓第三方 MCP 應用程式(Claude Web、Cursor 等)無需靜態金鑰即可連線。', + 'settings.oauth.createClient': '新增客戶端', + 'settings.oauth.noClients': '尚無已註冊的 OAuth 客戶端。', + 'settings.oauth.clientId': '客戶端 ID', + 'settings.oauth.clientSecret': '客戶端密鑰', + 'settings.oauth.deleteClient': '刪除客戶端', + 'settings.oauth.deleteClientMessage': + '此客戶端及所有活躍工作階段將被永久刪除。任何使用此客戶端的應用程式將立即失去存取權限。', + 'settings.oauth.rotateSecret': '輪換密鑰', + 'settings.oauth.rotateSecretMessage': + '將產生新的客戶端密鑰,所有現有工作階段將立即失效。請在關閉此對話框前更新您的應用程式。', + 'settings.oauth.rotateSecretConfirm': '輪換', + 'settings.oauth.rotateSecretConfirming': '輪換中…', + 'settings.oauth.rotateSecretDoneTitle': '已產生新密鑰', + 'settings.oauth.rotateSecretDoneWarning': + '此密鑰僅顯示一次。請立即複製並更新您的應用程式——所有先前的工作階段已失效。', + 'settings.oauth.activeSessions': '活躍的 OAuth 工作階段', + 'settings.oauth.sessionScopes': '授權範圍', + 'settings.oauth.sessionExpires': '到期時間', + 'settings.oauth.revoke': '撤銷', + 'settings.oauth.revokeSession': '撤銷工作階段', + 'settings.oauth.revokeSessionMessage': + '這將立即撤銷此 OAuth 工作階段的存取權限。', + 'settings.oauth.modal.createTitle': '註冊 OAuth 客戶端', + 'settings.oauth.modal.presets': '快速預設', + 'settings.oauth.modal.clientName': '應用程式名稱', + 'settings.oauth.modal.clientNamePlaceholder': + '例如 Claude Web、我的 MCP 應用程式', + 'settings.oauth.modal.redirectUris': '重新導向 URI', + 'settings.oauth.modal.redirectUrisPlaceholder': + 'https://your-app.com/callback\nhttps://your-app.com/auth', + 'settings.oauth.modal.redirectUrisHint': + '每行一個 URI。需要 HTTPS(localhost 除外)。需要完全符合。', + 'settings.oauth.modal.scopes': '允許的授權範圍', + 'settings.oauth.modal.scopesHint': + 'list_trips 和 get_trip_summary 始終可用——不需要授權範圍。它們可幫助 AI 找到所需的行程 ID。', + 'settings.oauth.modal.selectAll': '全選', + 'settings.oauth.modal.deselectAll': '取消全選', + 'settings.oauth.modal.creating': '註冊中…', + 'settings.oauth.modal.create': '註冊客戶端', + 'settings.oauth.modal.createdTitle': '客戶端已註冊', + 'settings.oauth.modal.createdWarning': + '客戶端密鑰僅顯示一次。請立即複製——無法恢復。', + 'settings.oauth.toast.createError': '註冊 OAuth 客戶端失敗', + 'settings.oauth.toast.deleted': 'OAuth 客戶端已刪除', + 'settings.oauth.toast.deleteError': '刪除 OAuth 客戶端失敗', + 'settings.oauth.toast.revoked': '工作階段已撤銷', + 'settings.oauth.toast.revokeError': '撤銷工作階段失敗', + 'settings.oauth.toast.rotateError': '輪換客戶端密鑰失敗', + 'settings.oauth.modal.machineClient': '機器客戶端(無需瀏覽器登入)', + 'settings.oauth.modal.machineClientHint': + '使用 client_credentials 授權——無需重新導向 URI。令牌透過 client_id + client_secret 直接簽發,並在所選範圍內以您的身份運行。', + 'settings.oauth.modal.machineClientUsage': + '取得令牌:向 /oauth/token 發送 POST 請求,攜帶 grant_type=client_credentials、client_id 和 client_secret。無需瀏覽器,無重整令牌。', + 'settings.oauth.badge.machine': '機器', + 'settings.account': '賬戶', + 'settings.about': '關於', + 'settings.about.reportBug': '回報錯誤', + 'settings.about.reportBugHint': '發現問題?告訴我們', + 'settings.about.featureRequest': '功能建議', + 'settings.about.featureRequestHint': '建議新功能', + 'settings.about.wikiHint': '文件與指南', + 'settings.about.supporters.badge': '月度支持者', + 'settings.about.supporters.title': '與 TREK 同行的夥伴', + 'settings.about.supporters.subtitle': + '當你規劃下一段路線時,這些人也在一起規劃 TREK 的未來。他們每月的支持直接用於開發與實際投入的時間——讓 TREK 保持開源。', + 'settings.about.supporters.since': '自 {date} 起的支持者', + 'settings.about.supporters.tierEmpty': '成為第一個', + 'settings.about.supporter.tier.noReturnTicket': 'No Return Ticket', + 'settings.about.supporter.tier.lostLuggageVip': 'Lost Luggage VIP', + 'settings.about.supporter.tier.businessClassDreamer': + 'Business Class Dreamer', + 'settings.about.supporter.tier.budgetTraveller': 'Budget Traveller', + 'settings.about.supporter.tier.hostelBunkmate': 'Hostel Bunkmate', + 'settings.about.description': + 'TREK 是一款自架旅遊規劃器,幫助您從最初構想到最後回憶,整理每次旅行。日程規劃、預算、行李清單、照片及更多功能——全部集中在您自己的伺服器上。', + 'settings.about.madeWith': '以', + 'settings.about.madeBy': '由 Maurice 及不斷成長的開源社群製作。', + 'settings.username': '使用者名稱', + 'settings.email': '郵箱', + 'settings.role': '角色', + 'settings.roleAdmin': '管理員', + 'settings.oidcLinked': '已關聯', + 'settings.changePassword': '修改密碼', + 'settings.mustChangePassword': '您必須更改密碼才能繼續。請在下方設定新密碼。', + 'settings.currentPassword': '當前密碼', + 'settings.currentPasswordRequired': '請輸入當前密碼', + 'settings.newPassword': '新密碼', + 'settings.confirmPassword': '確認新密碼', + 'settings.updatePassword': '更新密碼', + 'settings.passwordRequired': '請輸入當前密碼和新密碼', + 'settings.passwordTooShort': '密碼至少需要 8 個字元', + 'settings.passwordMismatch': '兩次輸入的密碼不一致', + 'settings.passwordWeak': '密碼必須包含大寫字母、小寫字母、數字和特殊字元', + 'settings.passwordChanged': '密碼修改成功', + 'settings.deleteAccount': '刪除賬戶', + 'settings.deleteAccountTitle': '確定刪除賬戶?', + 'settings.deleteAccountWarning': + '你的賬戶以及所有旅行、地點和檔案將被永久刪除。此操作無法撤銷。', + 'settings.deleteAccountConfirm': '永久刪除', + 'settings.deleteBlockedTitle': '無法刪除', + 'settings.deleteBlockedMessage': + '你是唯一的管理員。請先將其他使用者提升為管理員,然後再刪除賬戶。', + 'settings.roleUser': '使用者', + 'settings.saveProfile': '儲存資料', + 'settings.mfa.title': '雙因素認證 (2FA)', + 'settings.mfa.description': + '登入時新增第二步驗證。使用身份驗證器應用(Google Authenticator、Authy 等)。', + 'settings.mfa.requiredByPolicy': + '管理員要求雙因素身份驗證。請先完成下方的身份驗證器設定後再繼續。', + 'settings.mfa.backupTitle': '備用程式碼', + 'settings.mfa.backupDescription': + '如果你無法使用身份驗證器應用,可使用這些一次性備用程式碼登入。', + 'settings.mfa.backupWarning': + '請立即儲存這些程式碼。每個程式碼只能使用一次。', + 'settings.mfa.backupCopy': '複製程式碼', + 'settings.mfa.backupDownload': '下載 TXT', + 'settings.mfa.backupPrint': '列印 / PDF', + 'settings.mfa.backupCopied': '備用程式碼已複製', + 'settings.mfa.enabled': '您的賬戶已啟用 2FA。', + 'settings.mfa.disabled': '2FA 未啟用。', + 'settings.mfa.setup': '設定身份驗證器', + 'settings.mfa.scanQr': '使用應用掃描此二維碼,或手動輸入金鑰。', + 'settings.mfa.secretLabel': '金鑰(手動輸入)', + 'settings.mfa.codePlaceholder': '6 位驗證碼', + 'settings.mfa.enable': '啟用 2FA', + 'settings.mfa.cancelSetup': '取消', + 'settings.mfa.disableTitle': '停用 2FA', + 'settings.mfa.disableHint': '輸入您的賬戶密碼和身份驗證器中的當前驗證碼。', + 'settings.mfa.disable': '停用 2FA', + 'settings.mfa.toastEnabled': '雙因素認證已啟用', + 'settings.mfa.toastDisabled': '雙因素認證已停用', + 'settings.mfa.demoBlocked': '演示模式下不可用', + 'settings.toast.mapSaved': '地圖設定已儲存', + 'settings.toast.keysSaved': 'API 金鑰已儲存', + 'settings.toast.displaySaved': '顯示設定已儲存', + 'settings.toast.profileSaved': '資料已儲存', + 'settings.uploadAvatar': '上傳頭像', + 'settings.removeAvatar': '移除頭像', + 'settings.avatarUploaded': '頭像已更新', + 'settings.avatarRemoved': '頭像已移除', + 'settings.avatarError': '上傳失敗', + 'settings.bookingLabels': '預訂路線標籤', + 'settings.bookingLabelsHint': + '在地圖上顯示車站 / 機場名稱。關閉時僅顯示圖示。', + "settings.currency": "Currency", + "settings.currencyHint": "All amounts in Costs are converted to and shown in this currency.", + 'settings.passkey.title': 'Passkey', + 'settings.passkey.description': + '使用 Passkey 更快登入,並可抵禦網路釣魚——透過你的指紋、臉部、PIN 碼或硬體金鑰。你的密碼仍會保留作為備援。', + 'settings.passkey.notConfigured': + 'Passkey 已啟用,但此伺服器尚未完成設定。請聯絡管理員設定 WebAuthn 網域。', + 'settings.passkey.add': '新增 Passkey', + 'settings.passkey.addTitle': '新增 Passkey', + 'settings.passkey.passwordPrompt': '請確認你目前的密碼,然後依照裝置提示操作。', + 'settings.passkey.passwordRequired': '請輸入你目前的密碼。', + 'settings.passkey.namePlaceholder': '名稱(選填,例如 "iPhone")', + 'settings.passkey.addedToast': 'Passkey 已新增', + 'settings.passkey.added': '已新增', + 'settings.passkey.addError': '無法新增 Passkey', + 'settings.passkey.cancelled': 'Passkey 設定已取消', + 'settings.passkey.deleted': 'Passkey 已移除', + 'settings.passkey.deleteConfirm': '要移除此 Passkey 嗎?請以密碼確認。', + 'settings.passkey.rename': '重新命名', + 'settings.passkey.defaultName': 'Passkey', + 'settings.passkey.synced': '已同步', + 'settings.passkey.deviceBound': '此裝置', + 'settings.passkey.lastUsed': '上次使用', + 'settings.passkey.neverUsed': '從未使用', + 'settings.mapPoiPill': '在地圖上探索地點', + 'settings.mapPoiPillHint': '在行程地圖上顯示分類標籤,透過 OpenStreetMap 尋找附近的餐廳、住宿等地點。', + 'settings.airtrail.title': 'AirTrail', + 'settings.airtrail.hint': '連接你自架的 AirTrail 以匯入及同步航班。在 AirTrail 的「設定 → 安全性」中建立 API 金鑰。', + 'settings.airtrail.url': '執行個體網址', + 'settings.airtrail.apiKey': 'API 金鑰', + 'settings.airtrail.apiKeyPlaceholder': 'Bearer API 金鑰', + 'settings.airtrail.apiKeyHint': '在 AirTrail 的「設定 → 安全性」中產生。以加密方式儲存。', + 'settings.airtrail.allowInsecureTls': '允許自簽憑證', + 'settings.airtrail.allowInsecureTlsHint': '僅在你自己網路上受信任的執行個體啟用。', + 'settings.airtrail.connected': '已連接', + 'settings.airtrail.notConnected': '未連接', + 'settings.airtrail.toast.saved': '已儲存 AirTrail 連接', + 'settings.airtrail.toast.saveError': '無法儲存連接', + 'settings.airtrail.test.button': '測試連接', + 'settings.airtrail.test.success': '已連接——找到 {count} 筆航班', + 'settings.airtrail.test.failed': '連接失敗', +}; + +export default settings; diff --git a/shared/src/i18n/zh-TW/share.ts b/shared/src/i18n/zh-TW/share.ts new file mode 100644 index 0000000000000000000000000000000000000000..7c31f8cc8b60aa5440dffb6a74999114637ead19 --- /dev/null +++ b/shared/src/i18n/zh-TW/share.ts @@ -0,0 +1,16 @@ +import type { TranslationStrings } from '../types'; + +const share: TranslationStrings = { + 'share.linkTitle': '公開連結', + 'share.linkHint': + '建立一個連結,任何人無需登入即可檢視此旅行。僅可檢視,無法編輯。', + 'share.createLink': '建立連結', + 'share.deleteLink': '刪除連結', + 'share.createError': '無法建立連結', + 'share.permMap': '地圖與計劃', + 'share.permBookings': '預訂', + 'share.permPacking': '行李', + 'share.permBudget': '預算', + 'share.permCollab': '聊天', +}; +export default share; diff --git a/shared/src/i18n/zh-TW/shared.ts b/shared/src/i18n/zh-TW/shared.ts new file mode 100644 index 0000000000000000000000000000000000000000..b4162a637924480df5f0ab8b9c87881f745a493e --- /dev/null +++ b/shared/src/i18n/zh-TW/shared.ts @@ -0,0 +1,21 @@ +import type { TranslationStrings } from '../types'; + +const shared: TranslationStrings = { + 'shared.expired': '連結已過期或無效', + 'shared.expiredHint': '此共享旅行連結已失效。', + 'shared.readOnly': '只讀共享檢視', + 'shared.tabPlan': '計劃', + 'shared.tabBookings': '預訂', + 'shared.tabPacking': '行李', + 'shared.tabBudget': '預算', + 'shared.tabChat': '聊天', + 'shared.days': '天', + 'shared.places': '個地點', + 'shared.other': '其他', + 'shared.totalBudget': '總預算', + 'shared.messages': '條訊息', + 'shared.sharedVia': '透過以下分享', + 'shared.confirmed': '已確認', + 'shared.pending': '待確認', +}; +export default shared; diff --git a/shared/src/i18n/zh-TW/stats.ts b/shared/src/i18n/zh-TW/stats.ts new file mode 100644 index 0000000000000000000000000000000000000000..7e75a0b59685d76a86a1ec3bc95a685361c9905a --- /dev/null +++ b/shared/src/i18n/zh-TW/stats.ts @@ -0,0 +1,13 @@ +import type { TranslationStrings } from '../types'; + +const stats: TranslationStrings = { + 'stats.countries': '國家', + 'stats.cities': '城市', + 'stats.trips': '旅行', + 'stats.places': '地點', + 'stats.worldProgress': '全球進度', + 'stats.visited': '已訪問', + 'stats.remaining': '未訪問', + 'stats.visitedCountries': '已訪問國家', +}; +export default stats; diff --git a/shared/src/i18n/zh-TW/system_notice.ts b/shared/src/i18n/zh-TW/system_notice.ts new file mode 100644 index 0000000000000000000000000000000000000000..b13b93849cb28090b6d236323b3f4d7a301d133d --- /dev/null +++ b/shared/src/i18n/zh-TW/system_notice.ts @@ -0,0 +1,50 @@ +import type { TranslationStrings } from '../types'; + +const system_notice: TranslationStrings = { + 'system_notice.welcome_v1.title': '歡迎使用 TREK', + 'system_notice.welcome_v1.body': + '您的全方位旅遊規劃器。建立行程、與朋友分享旅遊,隨時保持條理分明——無論線上或離線皆可。', + 'system_notice.welcome_v1.cta_label': '規劃行程', + 'system_notice.welcome_v1.hero_alt': '風景優美的旅遊目的地與 TREK 介面', + 'system_notice.welcome_v1.highlight_plan': '逐日行程規劃', + 'system_notice.welcome_v1.highlight_share': '與旅伴協作規劃', + 'system_notice.welcome_v1.highlight_offline': '行動裝置支援離線使用', + 'system_notice.dev_test_modal.title': '[Dev] Test notice', + 'system_notice.dev_test_modal.body': 'This is a dev-only test notice.', + 'system_notice.pager.prev': '上一則通知', + 'system_notice.pager.next': '下一則通知', + 'system_notice.pager.counter': '{current} / {total}', + 'system_notice.pager.goto': '前往通知 {n}', + 'system_notice.pager.position': '通知 {current}/{total}', + 'system_notice.v3_photos.title': '3.0 版相片已移至', + 'system_notice.v3_photos.body': + '行程規劃器中的​**相片**標籤已被移除。您的相片安全— TREK 從未修改您的 Immich 或 Synology 相簿。\n\n相片現在位於 **Journey** 附加元件中。Journey 為選用 — 若尚未啟用,請聯絡管理員於 Admin → 附加元件 中開啟。', + 'system_notice.v3_journey.title': '認識 Journey — 旅行日記', + 'system_notice.v3_journey.body': + '將您的旅程記錄為具有時間軸、相片畫庫與互動地圖的豐富旅行故事。', + 'system_notice.v3_journey.cta_label': '開啟 Journey', + 'system_notice.v3_journey.highlight_timeline': '每日時間軸與畫庫', + 'system_notice.v3_journey.highlight_photos': '從 Immich 或 Synology 匯入', + 'system_notice.v3_journey.highlight_share': '公開分享 — 無需登入', + 'system_notice.v3_journey.highlight_export': '匯出為 PDF 相簿书', + 'system_notice.v3_features.title': '3.0 版更多亮點', + 'system_notice.v3_features.body': '這個版本還有一些其他專項值得了解。', + 'system_notice.v3_features.highlight_dashboard': '行動先行儀表板重設計', + 'system_notice.v3_features.highlight_offline': '作為 PWA 的完整離線模式', + 'system_notice.v3_features.highlight_search': '地點搜尋即時自動補全', + 'system_notice.v3_features.highlight_import': '從 KMZ/KML 檔案匯入地點', + 'system_notice.v3_mcp.title': 'MCP:OAuth 2.1 升級', + 'system_notice.v3_mcp.body': + 'MCP 整合已全面重構。OAuth 2.1 現為建議的身份驗證方式。靜態令牌(trek_…)已棄用,將於未來版本移除。', + 'system_notice.v3_mcp.highlight_oauth': 'OAuth 2.1 建議(mcp-remote)', + 'system_notice.v3_mcp.highlight_scopes': '24 個細粒度權限範圍', + 'system_notice.v3_mcp.highlight_deprecated': '靜態 trek_ 令牌已棄用', + 'system_notice.v3_mcp.highlight_tools': '擴展工具集與提示詞', + 'system_notice.v3_thankyou.title': '來自我的一封私人信', + 'system_notice.v3_thankyou.body': + '在你繼續之前——我想停下來說幾句。\n\nTREK 最初只是我為自己的旅行而做的一個業餘專案。我從未想過它會成長為 4,000 人信賴的冒險規劃工具。每一顆星標、每一個 issue、每一個功能請求——我都會讀,它們在全職工作和大學學業之間的深夜裡支撐著我繼續前行。\n\n我想讓你們知道:TREK 將永遠開源,永遠可自託管,永遠屬於你們。沒有追蹤,沒有訂閱,沒有任何附加條件。只是一個熱愛旅行的人為同樣熱愛旅行的你們打造的工具。\n\n特別感謝 [jubnl](https://github.com/jubnl)——你已經成為一位不可思議的合作者。3.0 版本中許多精彩之處都留下了你的印記。感謝你在這個專案還很粗糙的時候就選擇了相信它。\n\n也感謝你們每一位——回報了 bug、翻譯了文字、向朋友分享了 TREK,或者只是用它規劃了一次旅行——**謝謝你們**。你們是這一切存在的原因。\n\n願我們一起踏上更多的冒險旅程。\n\n— Maurice\n\n---\n\n[加入 Discord 社群](https://discord.gg/7Q6M6jDwzf)\n\n如果 TREK 讓你的旅行更美好,一杯[小小的咖啡](https://ko-fi.com/mauriceboe)能讓這盞燈一直亮著。', + 'system_notice.v3014_whitespace_collision.title': '需要操作:使用者帳戶衝突', + 'system_notice.v3014_whitespace_collision.body': + '3.0.14 版本升級偵測到一個或多個由儲存帳戶中前後空白字元引發的使用者名稱或電子郵件衝突。受影響的帳戶已自動重新命名。請檢查伺服器日誌中以 **[migration] WHITESPACE COLLISION** 開頭的行,以確認哪些帳戶需要審查。', +}; +export default system_notice; diff --git a/shared/src/i18n/zh-TW/todo.ts b/shared/src/i18n/zh-TW/todo.ts new file mode 100644 index 0000000000000000000000000000000000000000..e2765369755bfc94df89a094d0c0e7352af759ce --- /dev/null +++ b/shared/src/i18n/zh-TW/todo.ts @@ -0,0 +1,40 @@ +import type { TranslationStrings } from '../types'; + +const todo: TranslationStrings = { + 'todo.subtab.packing': '行李清單', + 'todo.subtab.todo': '待辦事項', + 'todo.completed': '已完成', + 'todo.filter.all': '全部', + 'todo.filter.open': '未完成', + 'todo.filter.done': '已完成', + 'todo.uncategorized': '未分類', + 'todo.namePlaceholder': '任務名稱', + 'todo.descriptionPlaceholder': '說明(可選)', + 'todo.unassigned': '未指派', + 'todo.noCategory': '無分類', + 'todo.hasDescription': '有說明', + 'todo.addItem': '新增任務', + 'todo.sidebar.sortBy': '排序方式', + 'todo.priority': '優先順序', + 'todo.newCategoryLabel': '新增', + 'todo.newCategory': '分類名稱', + 'todo.addCategory': '新增分類', + 'todo.newItem': '新任務', + 'todo.empty': '尚無任務。新增任務以開始!', + 'todo.filter.my': '我的任務', + 'todo.filter.overdue': '已逾期', + 'todo.sidebar.tasks': '任務', + 'todo.sidebar.categories': '分類', + 'todo.detail.title': '任務', + 'todo.detail.description': '說明', + 'todo.detail.category': '分類', + 'todo.detail.dueDate': '到期日', + 'todo.detail.assignedTo': '指派給', + 'todo.detail.delete': '刪除', + 'todo.detail.save': '儲存變更', + 'todo.sortByPrio': '優先順序', + 'todo.detail.priority': '優先順序', + 'todo.detail.noPriority': '無', + 'todo.detail.create': '建立任務', +}; +export default todo; diff --git a/shared/src/i18n/zh-TW/transport.ts b/shared/src/i18n/zh-TW/transport.ts new file mode 100644 index 0000000000000000000000000000000000000000..607f4d8340ced54f2f7b5a2048fdfd8ebe954fa7 --- /dev/null +++ b/shared/src/i18n/zh-TW/transport.ts @@ -0,0 +1,10 @@ +import type { TranslationStrings } from '../types'; + +const transport: TranslationStrings = { + 'transport.addTransport': '新增交通', + 'transport.modalTitle.create': '新增交通', + 'transport.modalTitle.edit': '編輯交通', + 'transport.title': '交通', + 'transport.addManual': '手動新增交通', +}; +export default transport; diff --git a/shared/src/i18n/zh-TW/trip.ts b/shared/src/i18n/zh-TW/trip.ts new file mode 100644 index 0000000000000000000000000000000000000000..2409a157e4a6c73341a88ca88b02372f4e7b1e60 --- /dev/null +++ b/shared/src/i18n/zh-TW/trip.ts @@ -0,0 +1,31 @@ +import type { TranslationStrings } from '../types'; + +const trip: TranslationStrings = { + 'trip.tabs.plan': '計劃', + 'trip.tabs.transports': '交通', + 'trip.tabs.reservations': '預訂', + 'trip.tabs.reservationsShort': '預訂', + 'trip.tabs.packing': '行李清單', + 'trip.tabs.packingShort': '行李', + 'trip.tabs.lists': '清單', + 'trip.tabs.listsShort': '清單', + 'trip.tabs.budget': "Costs", + 'trip.tabs.files': '檔案', + 'trip.loading': '載入旅行中...', + 'trip.loadingPhotos': '正在載入地點照片...', + 'trip.mobilePlan': '計劃', + 'trip.mobilePlaces': '地點', + 'trip.toast.placeUpdated': '地點已更新', + 'trip.toast.placeAdded': '地點已新增', + 'trip.toast.placeDeleted': '地點已刪除', + 'trip.toast.selectDay': '請先選擇一天', + 'trip.toast.assignedToDay': '地點已分配到當天', + 'trip.toast.reorderError': '排序失敗', + 'trip.toast.reservationUpdated': '預訂已更新', + 'trip.toast.reservationAdded': '預訂已新增', + 'trip.toast.deleted': '已刪除', + 'trip.confirm.deletePlace': '確定要刪除這個地點嗎?', + 'trip.confirm.deletePlaces': '刪除 {count} 個地點?', + 'trip.toast.placesDeleted': '已刪除 {count} 個地點', +}; +export default trip; diff --git a/shared/src/i18n/zh-TW/trips.ts b/shared/src/i18n/zh-TW/trips.ts new file mode 100644 index 0000000000000000000000000000000000000000..a2c1dbba90222b863d2b5601464e35f41f4c1a09 --- /dev/null +++ b/shared/src/i18n/zh-TW/trips.ts @@ -0,0 +1,17 @@ +import type { TranslationStrings } from '../types'; + +const trips: TranslationStrings = { + 'trips.memberRemoved': '{username} 已移除', + 'trips.memberRemoveError': '移除失敗', + 'trips.memberAdded': '{username} 已新增', + 'trips.memberAddError': '新增失敗', + 'trips.reminder': '提醒', + 'trips.reminderNone': '無', + 'trips.reminderDay': '天', + 'trips.reminderDays': '天', + 'trips.reminderCustom': '自定義', + 'trips.reminderDaysBefore': '天前提醒', + 'trips.reminderDisabledHint': + '旅行提醒已停用。請在管理 > 設定 > 通知中啟用。', +}; +export default trips; diff --git a/shared/src/i18n/zh-TW/undo.ts b/shared/src/i18n/zh-TW/undo.ts new file mode 100644 index 0000000000000000000000000000000000000000..147945707c8b8c3d7c9ba56f156e3c1c3c1e0bb6 --- /dev/null +++ b/shared/src/i18n/zh-TW/undo.ts @@ -0,0 +1,22 @@ +import type { TranslationStrings } from '../types'; + +const undo: TranslationStrings = { + 'undo.button': '撤銷', + 'undo.tooltip': '撤銷:{action}', + 'undo.assignPlace': '地點已分配至某天', + 'undo.removeAssignment': '地點已從某天移除', + 'undo.reorder': '地點已重新排序', + 'undo.optimize': '路線已最佳化', + 'undo.deletePlace': '地點已刪除', + 'undo.deletePlaces': '地點已刪除', + 'undo.moveDay': '地點已移至另一天', + 'undo.lock': '地點鎖定已切換', + 'undo.importGpx': 'GPX 匯入', + 'undo.importKeyholeMarkup': 'KMZ/KML 匯入', + 'undo.importGoogleList': 'Google 地圖匯入', + 'undo.importNaverList': 'Naver 地圖匯入', + 'undo.addPlace': '地點已新增', + 'undo.done': '已撤銷:{action}', + 'undo.importBooking': '匯入訂位確認', +}; +export default undo; diff --git a/shared/src/i18n/zh-TW/vacay.ts b/shared/src/i18n/zh-TW/vacay.ts new file mode 100644 index 0000000000000000000000000000000000000000..c2eda2bae2adf05d6ff7bb3200356f967bf9bae6 --- /dev/null +++ b/shared/src/i18n/zh-TW/vacay.ts @@ -0,0 +1,93 @@ +import type { TranslationStrings } from '../types'; + +const vacay: TranslationStrings = { + 'vacay.subtitle': '規劃和管理假期', + 'vacay.settings': '設定', + 'vacay.year': '年份', + 'vacay.addYear': '新增下一年', + 'vacay.addPrevYear': '新增上一年', + 'vacay.removeYear': '移除年份', + 'vacay.removeYearConfirm': '移除 {year}?', + 'vacay.removeYearHint': '該年度所有假期記錄和公司假日將被永久刪除。', + 'vacay.remove': '移除', + 'vacay.persons': '成員', + 'vacay.noPersons': '暫無成員', + 'vacay.addPerson': '新增成員', + 'vacay.editPerson': '編輯成員', + 'vacay.removePerson': '移除成員', + 'vacay.removePersonConfirm': '移除 {name}?', + 'vacay.removePersonHint': '該成員的所有假期記錄將被永久刪除。', + 'vacay.personName': '姓名', + 'vacay.personNamePlaceholder': '輸入姓名', + 'vacay.color': '顏色', + 'vacay.add': '新增', + 'vacay.legend': '圖例', + 'vacay.publicHoliday': '公共假日', + 'vacay.companyHoliday': '公司假日', + 'vacay.weekend': '週末', + 'vacay.modeVacation': '休假', + 'vacay.modeCompany': '公司假日', + 'vacay.entitlement': '年假額度', + 'vacay.entitlementDays': '天', + 'vacay.used': '已用', + 'vacay.remaining': '剩餘', + 'vacay.carriedOver': '從 {year} 結轉', + 'vacay.blockWeekends': '鎖定週末', + 'vacay.blockWeekendsHint': '禁止在週六和週日安排假期', + 'vacay.weekendDays': '週末', + 'vacay.mon': '週一', + 'vacay.tue': '週二', + 'vacay.wed': '週三', + 'vacay.thu': '週四', + 'vacay.fri': '週五', + 'vacay.sat': '週六', + 'vacay.sun': '週日', + 'vacay.publicHolidays': '公共假日', + 'vacay.publicHolidaysHint': '在日曆中標記公共假日', + 'vacay.selectCountry': '選擇國家', + 'vacay.selectRegion': '選擇地區(可選)', + 'vacay.companyHolidays': '公司假日', + 'vacay.companyHolidaysHint': '允許標記公司統一休假日', + 'vacay.companyHolidaysNoDeduct': '公司假日不計入年假天數。', + 'vacay.weekStart': '每週開始於', + 'vacay.weekStartHint': '選擇日曆週從週一還是週日開始', + 'vacay.carryOver': '結轉', + 'vacay.carryOverHint': '自動將剩餘年假天數結轉到下一年', + 'vacay.sharing': '共享', + 'vacay.sharingHint': '與其他 TREK 使用者共享你的假期計劃', + 'vacay.owner': '所有者', + 'vacay.shareEmailPlaceholder': 'TREK 使用者郵箱', + 'vacay.shareSuccess': '計劃共享成功', + 'vacay.shareError': '無法共享計劃', + 'vacay.dissolve': '解除合併', + 'vacay.dissolveHint': '重新分離日曆。你的記錄將被保留。', + 'vacay.dissolveAction': '解除', + 'vacay.dissolved': '日曆已分離', + 'vacay.fusedWith': '已合併', + 'vacay.you': '你', + 'vacay.noData': '暫無資料', + 'vacay.changeColor': '更改顏色', + 'vacay.inviteUser': '邀請使用者', + 'vacay.inviteHint': '邀請其他 TREK 使用者共享合併的假期日曆。', + 'vacay.selectUser': '選擇使用者', + 'vacay.sendInvite': '傳送邀請', + 'vacay.inviteSent': '邀請已傳送', + 'vacay.inviteError': '無法傳送邀請', + 'vacay.pending': '待處理', + 'vacay.noUsersAvailable': '沒有可用使用者', + 'vacay.accept': '接受', + 'vacay.decline': '拒絕', + 'vacay.acceptFusion': '接受併合並', + 'vacay.inviteTitle': '合併請求', + 'vacay.inviteWantsToFuse': '想要與你共享假期日曆。', + 'vacay.fuseInfo1': '你們雙方將在一個共享日曆中看到所有假期記錄。', + 'vacay.fuseInfo2': '雙方都可以為對方建立和編輯記錄。', + 'vacay.fuseInfo3': '雙方都可以刪除記錄和修改年假額度。', + 'vacay.fuseInfo4': '公共假日和公司假日等設定將共享。', + 'vacay.fuseInfo5': '任何一方都可以隨時解除合併。你的記錄將被保留。', + 'vacay.addCalendar': '新增日曆', + 'vacay.calendarColor': '顏色', + 'vacay.calendarLabel': '標籤', + 'vacay.noCalendars': '無日曆', +}; +export default vacay; diff --git a/shared/src/i18n/zh/admin.ts b/shared/src/i18n/zh/admin.ts new file mode 100644 index 0000000000000000000000000000000000000000..76bb3d4ab9706845fe2b0c6a1f28043e70186d7d --- /dev/null +++ b/shared/src/i18n/zh/admin.ts @@ -0,0 +1,358 @@ +import type { TranslationStrings } from '../types'; + +const admin: TranslationStrings = { + 'admin.notifications.title': '通知', + 'admin.notifications.hint': '选择一个通知渠道。一次只能激活一个。', + 'admin.notifications.none': '已禁用', + 'admin.notifications.email': '电子邮件 (SMTP)', + 'admin.notifications.webhook': 'Webhook', + 'admin.notifications.save': '保存通知设置', + 'admin.notifications.saved': '通知设置已保存', + 'admin.notifications.testWebhook': '发送测试 Webhook', + 'admin.notifications.testWebhookSuccess': '测试 Webhook 发送成功', + 'admin.notifications.testWebhookFailed': '测试 Webhook 发送失败', + 'admin.smtp.title': '邮件与通知', + 'admin.smtp.hint': '用于发送电子邮件通知的 SMTP 配置。', + 'admin.smtp.testButton': '发送测试邮件', + 'admin.webhook.hint': '向外部 Webhook 发送通知(Discord、Slack 等)。', + 'admin.smtp.testSuccess': '测试邮件发送成功', + 'admin.smtp.testFailed': '测试邮件发送失败', + 'admin.title': '管理后台', + 'admin.subtitle': '用户管理和系统设置', + 'admin.tabs.users': '用户', + 'admin.tabs.categories': '分类', + 'admin.tabs.backup': '备份', + 'admin.tabs.audit': '审计', + 'admin.stats.users': '用户', + 'admin.stats.trips': '旅行', + 'admin.stats.places': '地点', + 'admin.stats.photos': '照片', + 'admin.stats.files': '文件', + 'admin.table.user': '用户', + 'admin.table.email': '邮箱', + 'admin.table.role': '角色', + 'admin.table.created': '创建时间', + 'admin.table.lastLogin': '最后登录', + 'admin.table.actions': '操作', + 'admin.you': '(你)', + 'admin.editUser': '编辑用户', + 'admin.newPassword': '新密码', + 'admin.newPasswordHint': '留空则保持当前密码', + 'admin.deleteUser': '删除用户「{name}」?所有旅行将被永久删除。', + 'admin.deleteUserTitle': '删除用户', + 'admin.newPasswordPlaceholder': '输入新密码…', + 'admin.toast.loadError': '加载管理数据失败', + 'admin.toast.userUpdated': '用户已更新', + 'admin.toast.updateError': '更新失败', + 'admin.toast.userDeleted': '用户已删除', + 'admin.toast.deleteError': '删除失败', + 'admin.toast.cannotDeleteSelf': '不能删除自己的账户', + 'admin.toast.userCreated': '用户已创建', + 'admin.toast.createError': '创建用户失败', + 'admin.toast.fieldsRequired': '用户名、邮箱和密码为必填项', + 'admin.createUser': '创建用户', + 'admin.invite.title': '邀请链接', + 'admin.invite.subtitle': '创建一次性注册链接', + 'admin.invite.create': '创建链接', + 'admin.invite.createAndCopy': '创建并复制', + 'admin.invite.empty': '尚未创建邀请链接', + 'admin.invite.maxUses': '最大使用次数', + 'admin.invite.expiry': '有效期', + 'admin.invite.uses': '已使用', + 'admin.invite.expiresAt': '过期时间', + 'admin.invite.createdBy': '由', + 'admin.invite.active': '有效', + 'admin.invite.expired': '已过期', + 'admin.invite.usedUp': '已用完', + 'admin.invite.copied': '邀请链接已复制', + 'admin.invite.copyLink': '复制链接', + 'admin.invite.deleted': '邀请链接已删除', + 'admin.invite.createError': '创建链接失败', + 'admin.invite.deleteError': '删除链接失败', + 'admin.tabs.settings': '设置', + 'admin.allowRegistration': '允许注册', + 'admin.allowRegistrationHint': '新用户可以自行注册', + 'admin.authMethods': 'Authentication Methods', + 'admin.passwordLogin': 'Password Login', + 'admin.passwordLoginHint': 'Allow users to sign in with email and password', + 'admin.passwordRegistration': 'Password Registration', + 'admin.passwordRegistrationHint': + 'Allow new users to register with email and password', + 'admin.oidcLogin': 'SSO Login', + 'admin.oidcLoginHint': 'Allow users to sign in with SSO', + 'admin.oidcRegistration': 'SSO Auto-Provisioning', + 'admin.oidcRegistrationHint': + 'Automatically create accounts for new SSO users', + 'admin.envOverrideHint': + 'Password login settings are controlled by the OIDC_ONLY environment variable and cannot be changed here.', + 'admin.lockoutWarning': 'At least one login method must remain enabled', + 'admin.requireMfa': '要求双因素身份验证(2FA)', + 'admin.requireMfaHint': + '未启用 2FA 的用户必须先完成设置中的配置才能使用应用。', + 'admin.apiKeys': 'API 密钥', + 'admin.apiKeysHint': '可选。启用地点的扩展数据,如照片和天气。', + 'admin.mapsKey': 'Google Maps API 密钥', + 'admin.mapsKeyHint': '用于地点搜索。在 console.cloud.google.com 获取', + 'admin.mapsKeyHintLong': + '没有 API 密钥时,使用 OpenStreetMap 搜索地点。有了 Google API 密钥,还可以加载照片、评分和营业时间。在 console.cloud.google.com 获取。', + 'admin.recommended': '推荐', + 'admin.weatherKey': 'OpenWeatherMap API 密钥', + 'admin.weatherKeyHint': '用于天气数据。在 openweathermap.org 免费获取', + 'admin.validateKey': '测试', + 'admin.keyValid': '已连接', + 'admin.keyInvalid': '无效', + 'admin.keySaved': 'API 密钥已保存', + 'admin.oidcTitle': '单点登录 (OIDC)', + 'admin.oidcSubtitle': + '允许通过 Google、Apple、Authentik 或 Keycloak 等外部提供商登录。', + 'admin.oidcDisplayName': '显示名称', + 'admin.oidcIssuer': '颁发者 URL', + 'admin.oidcIssuerHint': + '提供商的 OpenID Connect 颁发者 URL。如 https://accounts.google.com', + 'admin.oidcSaved': 'OIDC 配置已保存', + 'admin.oidcOnlyMode': '禁用密码登录', + 'admin.oidcOnlyModeHint': '启用后,仅允许 SSO 登录。密码登录和注册将被禁用。', + 'admin.fileTypes': '允许的文件类型', + 'admin.fileTypesHint': '配置用户可以上传的文件类型。', + 'admin.fileTypesFormat': + '以逗号分隔的扩展名(如 jpg,png,pdf,doc)。使用 * 允许所有类型。', + 'admin.fileTypesSaved': '文件类型设置已保存', + 'admin.placesPhotos.title': '地点照片', + 'admin.placesPhotos.subtitle': + '从 Google Places API 获取照片。禁用可节省 API 配额。Wikimedia 照片不受影响。', + 'admin.placesAutocomplete.title': '地点自动补全', + 'admin.placesAutocomplete.subtitle': + '使用 Google Places API 提供搜索建议。禁用可节省 API 配额。', + 'admin.placesDetails.title': '地点详情', + 'admin.placesDetails.subtitle': + '从 Google Places API 获取地点详细信息(营业时间、评分、网站)。禁用可节省 API 配额。', + 'admin.bagTracking.title': '行李追踪', + 'admin.bagTracking.subtitle': '为打包物品启用重量和行李分配', + 'admin.collab.chat.title': '聊天', + 'admin.collab.chat.subtitle': '实时消息协作', + 'admin.collab.notes.title': '笔记', + 'admin.collab.notes.subtitle': '共享笔记和文档', + 'admin.collab.polls.title': '投票', + 'admin.collab.polls.subtitle': '群组投票和表决', + 'admin.collab.whatsnext.title': '下一步', + 'admin.collab.whatsnext.subtitle': '活动建议和后续步骤', + 'admin.tabs.config': '个性化', + 'admin.tabs.defaults': '用户默认设置', + 'admin.defaultSettings.title': '用户默认设置', + 'admin.defaultSettings.description': + '设置实例范围的默认值。未更改设置的用户将看到这些值。用户自己的更改始终优先。', + 'admin.defaultSettings.saved': '默认值已保存', + 'admin.defaultSettings.reset': '重置为内置默认值', + 'admin.defaultSettings.resetToBuiltIn': '重置', + 'admin.tabs.templates': '打包模板', + 'admin.packingTemplates.title': '打包模板', + 'admin.packingTemplates.subtitle': '创建可复用的旅行打包清单', + 'admin.packingTemplates.create': '新建模板', + 'admin.packingTemplates.namePlaceholder': '模板名称(如:海滩度假)', + 'admin.packingTemplates.empty': '尚未创建模板', + 'admin.packingTemplates.items': '物品', + 'admin.packingTemplates.categories': '分类', + 'admin.packingTemplates.itemName': '物品名称', + 'admin.packingTemplates.itemCategory': '分类', + 'admin.packingTemplates.categoryName': '分类名称(如:衣物)', + 'admin.packingTemplates.addCategory': '添加分类', + 'admin.packingTemplates.created': '模板已创建', + 'admin.packingTemplates.deleted': '模板已删除', + 'admin.packingTemplates.loadError': '加载模板失败', + 'admin.packingTemplates.createError': '创建模板失败', + 'admin.packingTemplates.deleteError': '删除模板失败', + 'admin.packingTemplates.saveError': '保存失败', + 'admin.tabs.addons': '扩展', + 'admin.addons.title': '扩展', + 'admin.addons.subtitle': '启用或禁用功能以自定义你的 TREK 体验。', + 'admin.addons.catalog.memories.name': '照片 (Immich)', + 'admin.addons.catalog.memories.description': '通过 Immich 实例分享旅行照片', + 'admin.addons.catalog.mcp.name': 'MCP', + 'admin.addons.catalog.mcp.description': '用于 AI 助手集成的模型上下文协议', + 'admin.addons.catalog.packing.name': '列表', + 'admin.addons.catalog.packing.description': '行程打包清单与待办任务', + 'admin.addons.catalog.budget.name': '预算', + 'admin.addons.catalog.budget.description': '跟踪支出并规划旅行预算', + 'admin.addons.catalog.documents.name': '文档', + 'admin.addons.catalog.documents.description': '存储和管理旅行文档', + 'admin.addons.catalog.vacay.name': 'Vacay', + 'admin.addons.catalog.vacay.description': '带日历视图的个人假期规划器', + 'admin.addons.catalog.atlas.name': 'Atlas', + 'admin.addons.catalog.atlas.description': + '标记已访问国家和旅行统计的世界地图', + 'admin.addons.catalog.collab.name': 'Collab', + 'admin.addons.catalog.collab.description': '旅行规划的实时笔记、投票和聊天', + 'admin.addons.subtitleBefore': '启用或禁用功能以自定义你的 ', + 'admin.addons.subtitleAfter': ' 体验。', + 'admin.addons.enabled': '已启用', + 'admin.addons.disabled': '已禁用', + 'admin.addons.type.trip': '旅行', + 'admin.addons.type.global': '全局', + 'admin.addons.type.integration': '集成', + 'admin.addons.tripHint': '在每次旅行中作为标签页显示', + 'admin.addons.globalHint': '在主导航中作为独立板块显示', + 'admin.addons.integrationHint': '后端服务和 API 集成,无专属页面', + 'admin.addons.toast.updated': '扩展已更新', + 'admin.addons.toast.error': '更新扩展失败', + 'admin.addons.noAddons': '暂无可用扩展', + 'admin.weather.title': '天气数据', + 'admin.weather.badge': '自 2026 年 3 月 24 日起', + 'admin.weather.description': + 'TREK 使用 Open-Meteo 作为天气数据源。Open-Meteo 是免费的开源天气服务——无需 API 密钥。', + 'admin.weather.forecast': '16 天天气预报', + 'admin.weather.forecastDesc': '之前为 5 天 (OpenWeatherMap)', + 'admin.weather.climate': '历史气候数据', + 'admin.weather.climateDesc': '16 天预报之外的日期使用过去 85 年的平均值', + 'admin.weather.requests': '每天 10,000 次请求', + 'admin.weather.requestsDesc': '免费,无需 API 密钥', + 'admin.weather.locationHint': + '天气基于每天中第一个有坐标的地点。如果当天没有分配地点,则使用地点列表中的任意地点作为参考。', + 'admin.tabs.mcpTokens': 'MCP 访问', + 'admin.mcpTokens.title': 'MCP 访问', + 'admin.mcpTokens.subtitle': '管理所有用户的 OAuth 会话和 API 令牌', + 'admin.mcpTokens.sectionTitle': 'API 令牌', + 'admin.mcpTokens.owner': '所有者', + 'admin.mcpTokens.tokenName': '令牌名称', + 'admin.mcpTokens.created': '创建时间', + 'admin.mcpTokens.lastUsed': '最后使用', + 'admin.mcpTokens.never': '从未', + 'admin.mcpTokens.empty': '尚未创建任何 MCP 令牌', + 'admin.mcpTokens.deleteTitle': '删除令牌', + 'admin.mcpTokens.deleteMessage': + '此令牌将立即被撤销。用户将失去通过此令牌的 MCP 访问权限。', + 'admin.mcpTokens.deleteSuccess': '令牌已删除', + 'admin.mcpTokens.deleteError': '删除令牌失败', + 'admin.mcpTokens.loadError': '加载令牌失败', + 'admin.oauthSessions.sectionTitle': 'OAuth 会话', + 'admin.oauthSessions.clientName': '客户端', + 'admin.oauthSessions.owner': '所有者', + 'admin.oauthSessions.scopes': '权限范围', + 'admin.oauthSessions.created': '创建时间', + 'admin.oauthSessions.empty': '暂无活跃的 OAuth 会话', + 'admin.oauthSessions.revokeTitle': '撤销会话', + 'admin.oauthSessions.revokeMessage': + '此 OAuth 会话将立即被撤销。客户端将失去 MCP 访问权限。', + 'admin.oauthSessions.revokeSuccess': '会话已撤销', + 'admin.oauthSessions.revokeError': '撤销会话失败', + 'admin.oauthSessions.loadError': '加载 OAuth 会话失败', + 'admin.tabs.github': 'GitHub', + 'admin.audit.subtitle': '安全与管理员操作记录(备份、用户、MFA、设置)。', + 'admin.audit.empty': '暂无审计记录。', + 'admin.audit.refresh': '刷新', + 'admin.audit.loadMore': '加载更多', + 'admin.audit.showing': '已加载 {count} 条 · 共 {total} 条', + 'admin.audit.col.time': '时间', + 'admin.audit.col.user': '用户', + 'admin.audit.col.action': '操作', + 'admin.audit.col.resource': '资源', + 'admin.audit.col.ip': 'IP', + 'admin.audit.col.details': '详情', + 'admin.github.title': '版本历史', + 'admin.github.subtitle': '{repo} 的最新更新', + 'admin.github.latest': '最新', + 'admin.github.prerelease': '预发布', + 'admin.github.showDetails': '显示详情', + 'admin.github.hideDetails': '隐藏详情', + 'admin.github.loadMore': '加载更多', + 'admin.github.loading': '加载中...', + 'admin.github.support': '帮助我继续开发 TREK', + 'admin.github.error': '加载版本失败', + 'admin.github.by': '作者', + 'admin.update.available': '有可用更新', + 'admin.update.text': 'TREK {version} 已发布。你当前使用的是 {current}。', + 'admin.update.button': '在 GitHub 查看', + 'admin.update.install': '安装更新', + 'admin.update.confirmTitle': '确定安装更新?', + 'admin.update.confirmText': + 'TREK 将从 {current} 更新到 {version}。服务器将自动重启。', + 'admin.update.dataInfo': + '你的所有数据(旅行、用户、API 密钥、上传文件、Vacay、Atlas、预算)将被保留。', + 'admin.update.warning': '重启期间应用将短暂不可用。', + 'admin.update.confirm': '立即更新', + 'admin.update.installing': '更新中…', + 'admin.update.success': '更新已安装!服务器正在重启…', + 'admin.update.failed': '更新失败', + 'admin.update.backupHint': '建议在更新前创建备份。', + 'admin.update.backupLink': '前往备份', + 'admin.update.howTo': '如何更新', + 'admin.update.dockerText': + '你的 TREK 实例运行在 Docker 中。要更新到 {version},请在服务器上执行以下命令:', + 'admin.update.reloadHint': '请在几秒后刷新页面。', + 'admin.tabs.permissions': '权限', + 'admin.notifications.emailPanel.title': 'Email (SMTP)', + 'admin.notifications.webhookPanel.title': 'Webhook', + 'admin.notifications.inappPanel.title': 'In-App', + 'admin.notifications.inappPanel.hint': + '应用内通知始终处于活跃状态,无法全局禁用。', + 'admin.notifications.adminWebhookPanel.title': '管理员 Webhook', + 'admin.notifications.adminWebhookPanel.hint': + '此 Webhook 专用于管理员通知(如版本更新提醒)。它与用户 Webhook 相互独立,配置 URL 后自动触发。', + 'admin.notifications.adminWebhookPanel.saved': '管理员 Webhook URL 已保存', + 'admin.notifications.adminWebhookPanel.testSuccess': '测试 Webhook 发送成功', + 'admin.notifications.adminWebhookPanel.testFailed': '测试 Webhook 失败', + 'admin.notifications.adminWebhookPanel.alwaysOnHint': + '配置 URL 后管理员 Webhook 自动触发', + 'admin.notifications.ntfy': 'Ntfy', + 'admin.ntfy.hint': + '允许用户配置自己的 ntfy 主题以接收推送通知。在下方设置默认服务器以预填充用户设置。', + 'admin.notifications.testNtfy': '发送测试 Ntfy', + 'admin.notifications.testNtfySuccess': '测试 Ntfy 发送成功', + 'admin.notifications.testNtfyFailed': '测试 Ntfy 失败', + 'admin.notifications.adminNtfyPanel.title': '管理员 Ntfy', + 'admin.notifications.adminNtfyPanel.hint': + '此 Ntfy 主题专用于管理员通知(如版本更新提醒)。它与每用户主题相互独立,配置后始终触发。', + 'admin.notifications.adminNtfyPanel.serverLabel': 'Ntfy 服务器 URL', + 'admin.notifications.adminNtfyPanel.serverHint': + '同时用作用户 ntfy 通知的默认服务器。留空则默认使用 ntfy.sh。用户可在其自己的设置中覆盖此项。', + 'admin.notifications.adminNtfyPanel.serverPlaceholder': 'https://ntfy.sh', + 'admin.notifications.adminNtfyPanel.topicLabel': '管理员主题', + 'admin.notifications.adminNtfyPanel.topicPlaceholder': 'trek-admin-alerts', + 'admin.notifications.adminNtfyPanel.tokenLabel': '访问令牌(可选)', + 'admin.notifications.adminNtfyPanel.tokenCleared': '管理员访问令牌已清除', + 'admin.notifications.adminNtfyPanel.saved': '管理员 Ntfy 设置已保存', + 'admin.notifications.adminNtfyPanel.test': '发送测试 Ntfy', + 'admin.notifications.adminNtfyPanel.testSuccess': '测试 Ntfy 发送成功', + 'admin.notifications.adminNtfyPanel.testFailed': '测试 Ntfy 失败', + 'admin.notifications.adminNtfyPanel.alwaysOnHint': + '配置主题后管理员 Ntfy 始终触发', + 'admin.notifications.adminNotificationsHint': + '配置哪些渠道发送管理员通知(如版本更新提醒)。设置管理员 Webhook URL 后,Webhook 将自动触发。', + 'admin.notifications.tripReminders.title': '行程提醒', + 'admin.notifications.tripReminders.hint': + '在行程开始前发送提醒通知(需要在行程中设置提醒天数)。', + 'admin.notifications.tripReminders.enabled': '行程提醒已启用', + 'admin.notifications.tripReminders.disabled': '行程提醒已禁用', + 'admin.tabs.notifications': '通知', + 'admin.addons.catalog.journey.name': '旅程', + 'admin.addons.catalog.journey.description': + '旅行追踪与旅行日志,包含签到、照片和每日故事', + 'admin.passkey.title': '通行密钥登录', + 'admin.passkey.cardHint': '允许用户使用通行密钥(WebAuthn)登录。默认关闭。', + 'admin.passkey.login': '启用通行密钥登录', + 'admin.passkey.loginHint': + '显示"使用通行密钥登录"选项,并允许用户在其设置中注册通行密钥。', + 'admin.passkey.notConfigured': + '此部署尚未解析出有效的 WebAuthn 域名。请设置 APP_URL 或下方的 Relying Party ID——在此之前通行密钥将保持隐藏。', + 'admin.passkey.rpId': 'Relying Party ID(域名)', + 'admin.passkey.rpIdHint': + '通行密钥所绑定的纯域名,如 trek.example.org。留空则从 APP_URL 推导。之后更改将使现有通行密钥失效。', + 'admin.passkey.origins': '允许的来源', + 'admin.passkey.originsHint': + '以逗号分隔的完整来源,如 https://trek.example.org。留空则使用 APP_URL。', + 'admin.passkey.reset': '重置通行密钥', + 'admin.passkey.resetHint': + '移除该用户的所有通行密钥(如设备丢失时)。他们仍可使用密码登录。', + 'admin.passkey.resetConfirm': '移除 {name} 的所有通行密钥?', + 'admin.passkey.resetDone': '已移除 {count} 个通行密钥', + 'admin.defaultSettings.mapProvider': '地图引擎', + 'admin.defaultSettings.mapProviderHint': '本实例中所有用户的默认地图。每位用户仍可在自己的设置中更改此项。', + 'admin.defaultSettings.providerLeaflet': '标准(免费)', + 'admin.defaultSettings.providerMapbox': 'Mapbox(3D)', + 'admin.defaultSettings.mapboxToken': '共享 Mapbox 令牌', + 'admin.defaultSettings.mapboxTokenHint': '用于所有未输入自己令牌的用户 — 这样无需逐个分享密钥,整个实例即可使用 Mapbox。以加密方式存储。', + 'admin.defaultSettings.mapboxStyle': '地图样式', + 'admin.defaultSettings.mapboxStylePlaceholder': '选择一种样式…', + 'admin.defaultSettings.mapbox3d': '3D 建筑与地形', + 'admin.defaultSettings.mapboxQuality': '高质量模式', +}; +export default admin; diff --git a/shared/src/i18n/zh/airport.ts b/shared/src/i18n/zh/airport.ts new file mode 100644 index 0000000000000000000000000000000000000000..f96c89db18389b16d4bb91070f173b95e8ab6ae9 --- /dev/null +++ b/shared/src/i18n/zh/airport.ts @@ -0,0 +1,6 @@ +import type { TranslationStrings } from '../types'; + +const airport: TranslationStrings = { + 'airport.searchPlaceholder': '机场代码或城市(如 FRA)', +}; +export default airport; diff --git a/shared/src/i18n/zh/atlas.ts b/shared/src/i18n/zh/atlas.ts new file mode 100644 index 0000000000000000000000000000000000000000..c42cfe7649806ddc3d6ef1a97aa5180c2fefd9f4 --- /dev/null +++ b/shared/src/i18n/zh/atlas.ts @@ -0,0 +1,58 @@ +import type { TranslationStrings } from '../types'; + +const atlas: TranslationStrings = { + 'atlas.subtitle': '你的全球旅行足迹', + 'atlas.countries': '国家', + 'atlas.trips': '旅行', + 'atlas.places': '地点', + 'atlas.days': '天', + 'atlas.visitedCountries': '已访问国家', + 'atlas.cities': '城市', + 'atlas.noData': '暂无旅行数据', + 'atlas.noDataHint': '创建旅行并添加地点以查看世界地图', + 'atlas.lastTrip': '上次旅行', + 'atlas.nextTrip': '下次旅行', + 'atlas.daysLeft': '天后出发', + 'atlas.streak': '连续', + 'atlas.year': '年', + 'atlas.years': '年', + 'atlas.yearInRow': '年连续', + 'atlas.yearsInRow': '年连续', + 'atlas.tripIn': '次旅行在', + 'atlas.tripsIn': '次旅行在', + 'atlas.since': '自', + 'atlas.europe': '欧洲', + 'atlas.asia': '亚洲', + 'atlas.northAmerica': '北美洲', + 'atlas.southAmerica': '南美洲', + 'atlas.africa': '非洲', + 'atlas.oceania': '大洋洲', + 'atlas.other': '其他', + 'atlas.firstVisit': '首次旅行', + 'atlas.lastVisitLabel': '最近旅行', + 'atlas.tripSingular': '次旅行', + 'atlas.tripPlural': '次旅行', + 'atlas.placeVisited': '个地点已访问', + 'atlas.placesVisited': '个地点已访问', + 'atlas.statsTab': '统计', + 'atlas.bucketTab': '心愿单', + 'atlas.addBucket': '添加到心愿单', + 'atlas.bucketNamePlaceholder': '地点或目的地...', + 'atlas.bucketNotesPlaceholder': '备注(可选)', + 'atlas.bucketEmpty': '你的心愿单是空的', + 'atlas.bucketEmptyHint': '添加你梦想去的地方', + 'atlas.unmark': '移除', + 'atlas.confirmMark': '将此国家标记为已访问?', + 'atlas.confirmUnmark': '从已访问列表中移除此国家?', + 'atlas.confirmUnmarkRegion': '从已访问列表中移除此地区?', + 'atlas.markVisited': '标记为已访问', + 'atlas.markVisitedHint': '将此国家添加到已访问列表', + 'atlas.markRegionVisitedHint': '将此地区添加到已访问列表', + 'atlas.addToBucket': '添加到心愿单', + 'atlas.addPoi': '添加地点', + 'atlas.searchCountry': '搜索国家...', + 'atlas.month': '月份', + 'atlas.addToBucketHint': '保存为想去的地方', + 'atlas.bucketWhen': '你计划什么时候去?', +}; +export default atlas; diff --git a/shared/src/i18n/zh/backup.ts b/shared/src/i18n/zh/backup.ts new file mode 100644 index 0000000000000000000000000000000000000000..8092734a98719387a0a3c35f6c99e5a3109e6bcc --- /dev/null +++ b/shared/src/i18n/zh/backup.ts @@ -0,0 +1,74 @@ +import type { TranslationStrings } from '../types'; + +const backup: TranslationStrings = { + 'backup.title': '数据备份', + 'backup.subtitle': '数据库和所有上传文件', + 'backup.refresh': '刷新', + 'backup.upload': '上传备份', + 'backup.uploading': '上传中…', + 'backup.create': '创建备份', + 'backup.creating': '创建中…', + 'backup.empty': '暂无备份', + 'backup.createFirst': '创建第一个备份', + 'backup.download': '下载', + 'backup.restore': '恢复', + 'backup.confirm.restore': + '恢复备份「{name}」?\n\n所有当前数据将被备份数据替换。', + 'backup.confirm.uploadRestore': + '上传并恢复备份文件「{name}」?\n\n所有当前数据将被覆盖。', + 'backup.confirm.delete': '删除备份「{name}」?', + 'backup.toast.loadError': '加载备份失败', + 'backup.toast.created': '备份创建成功', + 'backup.toast.createError': '创建备份失败', + 'backup.toast.restored': '备份已恢复。页面即将刷新…', + 'backup.toast.restoreError': '恢复失败', + 'backup.toast.uploadError': '上传失败', + 'backup.toast.deleted': '备份已删除', + 'backup.toast.deleteError': '删除失败', + 'backup.toast.downloadError': '下载失败', + 'backup.toast.settingsSaved': '自动备份设置已保存', + 'backup.toast.settingsError': '保存设置失败', + 'backup.auto.title': '自动备份', + 'backup.auto.subtitle': '按计划自动备份', + 'backup.auto.enable': '启用自动备份', + 'backup.auto.enableHint': '将按所选计划自动创建备份', + 'backup.auto.interval': '间隔', + 'backup.auto.hour': '执行时间', + 'backup.auto.hourHint': '服务器本地时间({format} 格式)', + 'backup.auto.dayOfWeek': '星期几', + 'backup.auto.dayOfMonth': '每月几号', + 'backup.auto.dayOfMonthHint': '限 1–28 以兼容所有月份', + 'backup.auto.scheduleSummary': '计划', + 'backup.auto.summaryDaily': '每天 {hour}:00', + 'backup.auto.summaryWeekly': '每{day} {hour}:00', + 'backup.auto.summaryMonthly': '每月 {day} 号 {hour}:00', + 'backup.auto.envLocked': 'Docker', + 'backup.auto.envLockedHint': + '自动备份通过 Docker 环境变量配置。要更改设置,请更新 docker-compose.yml 并重启容器。', + 'backup.auto.copyEnv': '复制 Docker 环境变量', + 'backup.auto.envCopied': 'Docker 环境变量已复制到剪贴板', + 'backup.auto.keepLabel': '自动删除旧备份', + 'backup.dow.sunday': '周日', + 'backup.dow.monday': '周一', + 'backup.dow.tuesday': '周二', + 'backup.dow.wednesday': '周三', + 'backup.dow.thursday': '周四', + 'backup.dow.friday': '周五', + 'backup.dow.saturday': '周六', + 'backup.interval.hourly': '每小时', + 'backup.interval.daily': '每天', + 'backup.interval.weekly': '每周', + 'backup.interval.monthly': '每月', + 'backup.keep.1day': '1 天', + 'backup.keep.3days': '3 天', + 'backup.keep.7days': '7 天', + 'backup.keep.14days': '14 天', + 'backup.keep.30days': '30 天', + 'backup.keep.forever': '永久保留', + 'backup.restoreConfirmTitle': '恢复备份?', + 'backup.restoreWarning': + '所有当前数据(旅行、地点、用户、上传文件)将被备份数据永久替换。此操作无法撤销。', + 'backup.restoreTip': '提示:恢复前建议先备份当前状态。', + 'backup.restoreConfirm': '确认恢复', +}; +export default backup; diff --git a/shared/src/i18n/zh/budget.ts b/shared/src/i18n/zh/budget.ts new file mode 100644 index 0000000000000000000000000000000000000000..b2e93c315ef9430a9057f4160d35553d118b324e --- /dev/null +++ b/shared/src/i18n/zh/budget.ts @@ -0,0 +1,115 @@ +import type { TranslationStrings } from '../types'; + +const budget: TranslationStrings = { + 'budget.title': '预算', + 'budget.exportCsv': '导出 CSV', + 'budget.emptyTitle': '尚未创建预算', + 'budget.emptyText': '创建分类和条目来规划旅行预算', + 'budget.emptyPlaceholder': '输入分类名称...', + 'budget.createCategory': '创建分类', + 'budget.category': '分类', + 'budget.categoryName': '分类名称', + 'budget.table.name': '名称', + 'budget.table.total': '合计', + 'budget.table.persons': '人数', + 'budget.table.days': '天数', + 'budget.table.perPerson': '人均', + 'budget.table.perDay': '日均', + 'budget.table.perPersonDay': '人日均', + 'budget.table.note': '备注', + 'budget.table.date': '日期', + 'budget.newEntry': '新建条目', + 'budget.defaultEntry': '新建条目', + 'budget.defaultCategory': '新分类', + 'budget.total': '合计', + 'budget.totalBudget': '总预算', + 'budget.byCategory': '按分类', + 'budget.editTooltip': '点击编辑', + 'budget.linkedToReservation': '已关联到预订——请在那里编辑名称', + 'budget.confirm.deleteCategory': + '确定删除分类「{name}」及其 {count} 个条目?', + 'budget.deleteCategory': '删除分类', + 'budget.perPerson': '人均', + 'budget.paid': '已支付', + 'budget.open': '未支付', + 'budget.noMembers': '未分配成员', + 'budget.settlement': '结算', + 'budget.settlementInfo': + '点击预算项目上的成员头像将其标记为绿色——表示该成员已付款。结算会显示谁欠谁多少。', + 'budget.netBalances': '净余额', + 'budget.categoriesLabel': '类别', + "costs.you": "你", + "costs.youShort": "你", + "costs.youLower": "你", + "costs.youOwe": "你欠款", + "costs.youOweSub": "你需要付钱给其他人", + "costs.youreOwed": "别人欠你", + "costs.youreOwedSub": "其他人需要付钱给你", + "costs.totalSpend": "行程总支出", + "costs.totalSpendSub": "所有同行者合计", + "costs.to": "收款方", + "costs.from": "付款方", + "costs.allSettled": "你已全部结清", + "costs.nothingOwed": "没有人欠你", + "costs.yourShare": "你的份额", + "costs.youPaid": "你已支付", + "costs.expenses": "支出", + "costs.entries": "{count} 条记录", + "costs.searchPlaceholder": "搜索支出…", + "costs.filter.all": "全部", + "costs.filter.mine": "我支付的", + "costs.filter.owed": "别人欠我", + "costs.addExpense": "添加支出", + "costs.editExpense": "编辑支出", + "costs.noMatch": "没有符合搜索条件的支出。", + "costs.emptyText": "暂无支出。添加第一笔吧。", + "costs.spent": "已花费 {amount}", + "costs.noDate": "无日期", + "costs.noOnePaid": "尚无人支付", + "costs.youLent": "你垫付了 {amount}", + "costs.youBorrowed": "你欠了 {amount}", + "costs.settleUp": "结算", + "costs.history": "历史记录", + "costs.everyoneSquare": "大家已两清", + "costs.nothingOutstanding": "目前没有待结算的款项。", + "costs.pay": "支付", + "costs.pays": "支付", + "costs.settle": "结算", + "costs.balances": "余额", + "costs.byCategory": "按分类", + "costs.noCategories": "暂无支出。", + "costs.settleHistory": "结算历史", + "costs.noSettlements": "暂无已结算的款项。", + "costs.paymentsSettled": "已结算 {count} 笔付款", + "costs.paid": "已支付", + "costs.undo": "撤销", + "costs.whatFor": "这笔花在哪了?", + "costs.namePlaceholder": "例如:晚餐、纪念品、油费…", + "costs.totalAmount": "总金额", + "costs.currency": "货币", + "costs.day": "日期", + "costs.rateLabel": "1 {from} = {to}", + "costs.category": "分类", + "costs.whoPaid": "谁支付的?", + "costs.splitBetween": "平均分摊给", + "costs.pickSomeone": "至少选择一人参与分摊。", + "costs.splitSummary": "分 {count} 份 · 每份 {amount}", + "costs.cat.accommodation": "住宿", + "costs.cat.food": "餐饮", + "costs.cat.groceries": "采买", + "costs.cat.transport": "交通", + "costs.cat.flights": "机票", + "costs.cat.activities": "活动", + "costs.cat.sightseeing": "观光", + "costs.cat.shopping": "购物", + "costs.cat.fees": "费用与门票", + "costs.cat.health": "健康", + "costs.cat.tips": "小费", + "costs.cat.other": "其他", + "costs.daysCount": "{count} 天", + "costs.travelers": "{count} 位同行者", + "costs.liveRate": "实时汇率", + "costs.settleAll": "全部结算", +}; + +export default budget; diff --git a/shared/src/i18n/zh/categories.ts b/shared/src/i18n/zh/categories.ts new file mode 100644 index 0000000000000000000000000000000000000000..4e48a53a043535572681ef4b6950829256ec2182 --- /dev/null +++ b/shared/src/i18n/zh/categories.ts @@ -0,0 +1,25 @@ +import type { TranslationStrings } from '../types'; + +const categories: TranslationStrings = { + 'categories.title': '分类', + 'categories.subtitle': '管理地点分类', + 'categories.new': '新建分类', + 'categories.empty': '暂无分类', + 'categories.namePlaceholder': '分类名称', + 'categories.icon': '图标', + 'categories.color': '颜色', + 'categories.customColor': '选择自定义颜色', + 'categories.preview': '预览', + 'categories.defaultName': '分类', + 'categories.update': '更新', + 'categories.create': '创建', + 'categories.confirm.delete': '删除分类?该分类下的地点不会被删除。', + 'categories.toast.loadError': '加载分类失败', + 'categories.toast.nameRequired': '请输入名称', + 'categories.toast.updated': '分类已更新', + 'categories.toast.created': '分类已创建', + 'categories.toast.saveError': '保存失败', + 'categories.toast.deleted': '分类已删除', + 'categories.toast.deleteError': '删除失败', +}; +export default categories; diff --git a/shared/src/i18n/zh/collab.ts b/shared/src/i18n/zh/collab.ts new file mode 100644 index 0000000000000000000000000000000000000000..3ce9689eb96524bbad8bc3de9d07fbd5beec4575 --- /dev/null +++ b/shared/src/i18n/zh/collab.ts @@ -0,0 +1,75 @@ +import type { TranslationStrings } from '../types'; + +const collab: TranslationStrings = { + 'collab.tabs.chat': '聊天', + 'collab.tabs.notes': '笔记', + 'collab.tabs.polls': '投票', + 'collab.whatsNext.title': '接下来', + 'collab.whatsNext.today': '今天', + 'collab.whatsNext.tomorrow': '明天', + 'collab.whatsNext.empty': '暂无活动', + 'collab.whatsNext.until': '至', + 'collab.whatsNext.emptyHint': '有时间安排的活动将显示在此', + 'collab.chat.send': '发送', + 'collab.chat.placeholder': '输入消息...', + 'collab.chat.empty': '开始对话', + 'collab.chat.emptyHint': '消息对所有旅行成员可见', + 'collab.chat.emptyDesc': '与旅伴分享想法、计划和动态', + 'collab.chat.today': '今天', + 'collab.chat.yesterday': '昨天', + 'collab.chat.deletedMessage': '删除了一条消息', + 'collab.chat.reply': '回复', + 'collab.chat.loadMore': '加载更早的消息', + 'collab.chat.justNow': '刚刚', + 'collab.chat.minutesAgo': '{n} 分钟前', + 'collab.chat.hoursAgo': '{n} 小时前', + 'collab.notes.title': '笔记', + 'collab.notes.new': '新建笔记', + 'collab.notes.empty': '暂无笔记', + 'collab.notes.emptyHint': '开始记录想法和计划', + 'collab.notes.all': '全部', + 'collab.notes.titlePlaceholder': '笔记标题', + 'collab.notes.contentPlaceholder': '写点什么...', + 'collab.notes.categoryPlaceholder': '分类', + 'collab.notes.newCategory': '新建分类...', + 'collab.notes.category': '分类', + 'collab.notes.noCategory': '无分类', + 'collab.notes.color': '颜色', + 'collab.notes.save': '保存', + 'collab.notes.cancel': '取消', + 'collab.notes.edit': '编辑', + 'collab.notes.delete': '删除', + 'collab.notes.confirmDeleteTitle': '删除备注?', + 'collab.notes.confirmDeleteBody': '此备注将被永久删除。', + 'collab.notes.pin': '置顶', + 'collab.notes.unpin': '取消置顶', + 'collab.notes.daysAgo': '{n} 天前', + 'collab.notes.categorySettings': '管理分类', + 'collab.notes.create': '创建', + 'collab.notes.website': '网站', + 'collab.notes.websitePlaceholder': 'https://...', + 'collab.notes.attachFiles': '附加文件', + 'collab.notes.noCategoriesYet': '暂无分类', + 'collab.notes.emptyDesc': '创建一个笔记开始吧', + 'collab.polls.title': '投票', + 'collab.polls.new': '新建投票', + 'collab.polls.empty': '暂无投票', + 'collab.polls.emptyHint': '向团队提问并一起投票', + 'collab.polls.question': '问题', + 'collab.polls.questionPlaceholder': '我们应该做什么?', + 'collab.polls.addOption': '+ 添加选项', + 'collab.polls.optionPlaceholder': '选项 {n}', + 'collab.polls.create': '创建投票', + 'collab.polls.close': '关闭', + 'collab.polls.closed': '已关闭', + 'collab.polls.votes': '{n} 票', + 'collab.polls.vote': '{n} 票', + 'collab.polls.multipleChoice': '多选', + 'collab.polls.multiChoice': '多选', + 'collab.polls.deadline': '截止时间', + 'collab.polls.option': '选项', + 'collab.polls.options': '选项', + 'collab.polls.delete': '删除', + 'collab.polls.closedSection': '已关闭', +}; +export default collab; diff --git a/shared/src/i18n/zh/common.ts b/shared/src/i18n/zh/common.ts new file mode 100644 index 0000000000000000000000000000000000000000..d335d6b0cf9d1ef5e8185b67da627013174fd918 --- /dev/null +++ b/shared/src/i18n/zh/common.ts @@ -0,0 +1,54 @@ +import type { TranslationStrings } from '../types'; + +const common: TranslationStrings = { + 'common.save': '保存', + 'common.showMore': '显示更多', + 'common.showLess': '收起', + 'common.cancel': '取消', + 'common.clear': '清除', + 'common.delete': '删除', + 'common.edit': '编辑', + 'common.add': '添加', + 'common.loading': '加载中...', + 'common.import': '导入', + 'common.select': '选择', + 'common.selectAll': '全选', + 'common.deselectAll': '取消全选', + 'common.error': '错误', + 'common.unknownError': '未知错误', + 'common.tooManyAttempts': '尝试次数过多,请稍后再试。', + 'common.back': '返回', + 'common.all': '全部', + 'common.close': '关闭', + 'common.open': '打开', + 'common.upload': '上传', + 'common.search': '搜索', + 'common.confirm': '确认', + 'common.ok': '确定', + 'common.yes': '是', + 'common.no': '否', + 'common.or': '或', + 'common.none': '无', + 'common.date': '日期', + 'common.rename': '重命名', + 'common.discardChanges': '放弃更改', + 'common.discard': '放弃', + 'common.name': '名称', + 'common.email': '邮箱', + 'common.password': '密码', + 'common.saving': '保存中...', + 'common.saved': '已保存', + 'common.expand': '展开', + 'common.collapse': '折叠', + 'common.update': '更新', + 'common.change': '修改', + 'common.uploading': '上传中…', + 'common.backToPlanning': '返回规划', + 'common.reset': '重置', + 'common.copy': '复制', + 'common.copied': '已复制', + 'common.justNow': '刚刚', + 'common.hoursAgo': '{count}小时前', + 'common.daysAgo': '{count}天前', +}; +export default common; diff --git a/shared/src/i18n/zh/dashboard.ts b/shared/src/i18n/zh/dashboard.ts new file mode 100644 index 0000000000000000000000000000000000000000..688eeb0aa8b9c0362926a03010962c0a11e6ee38 --- /dev/null +++ b/shared/src/i18n/zh/dashboard.ts @@ -0,0 +1,166 @@ +import type { TranslationStrings } from '../types'; + +const dashboard: TranslationStrings = { + 'dashboard.title': '我的旅行', + 'dashboard.subtitle.loading': '加载旅行中...', + 'dashboard.subtitle.trips': '{count} 次旅行({archived} 已归档)', + 'dashboard.subtitle.empty': '开始你的第一次旅行', + 'dashboard.subtitle.activeOne': '{count} 个进行中的旅行', + 'dashboard.subtitle.activeMany': '{count} 个进行中的旅行', + 'dashboard.subtitle.archivedSuffix': ' · {count} 已归档', + 'dashboard.newTrip': '新建旅行', + 'dashboard.newTripSub': '从零开始规划新旅行', + 'dashboard.gridView': '网格视图', + 'dashboard.listView': '列表视图', + 'dashboard.currency': '货币', + 'dashboard.timezone': '时区', + 'dashboard.localTime': '本地', + 'dashboard.timezoneCustomTitle': '自定义时区', + 'dashboard.timezoneCustomLabelPlaceholder': '标签(可选)', + 'dashboard.timezoneCustomTzPlaceholder': '如 America/New_York', + 'dashboard.timezoneCustomAdd': '添加', + 'dashboard.timezoneCustomErrorEmpty': '请输入时区标识符', + 'dashboard.timezoneCustomErrorInvalid': + '无效的时区。请使用 Europe/Berlin 这样的格式', + 'dashboard.timezoneCustomErrorDuplicate': '已添加', + 'dashboard.emptyTitle': '暂无旅行', + 'dashboard.emptyText': '创建你的第一次旅行,开始规划吧!', + 'dashboard.emptyButton': '创建第一次旅行', + 'dashboard.nextTrip': '下次旅行', + 'dashboard.shared': '共享', + 'dashboard.sharedBy': '由 {name} 分享', + 'dashboard.days': '天', + 'dashboard.places': '地点', + 'dashboard.members': '旅伴', + 'dashboard.archive': '归档', + 'dashboard.copyTrip': '复制', + 'dashboard.copySuffix': '副本', + 'dashboard.restore': '恢复', + 'dashboard.archived': '已归档', + 'dashboard.status.ongoing': '进行中', + 'dashboard.status.today': '今天', + 'dashboard.status.tomorrow': '明天', + 'dashboard.status.past': '已结束', + 'dashboard.status.daysLeft': '还剩 {count} 天', + 'dashboard.toast.loadError': '加载旅行失败', + 'dashboard.toast.created': '旅行创建成功!', + 'dashboard.toast.createError': '创建旅行失败', + 'dashboard.toast.updated': '旅行已更新!', + 'dashboard.toast.updateError': '更新旅行失败', + 'dashboard.toast.deleted': '旅行已删除', + 'dashboard.toast.deleteError': '删除旅行失败', + 'dashboard.toast.archived': '旅行已归档', + 'dashboard.toast.archiveError': '归档旅行失败', + 'dashboard.toast.restored': '旅行已恢复', + 'dashboard.toast.restoreError': '恢复旅行失败', + 'dashboard.toast.copied': '旅行已复制!', + 'dashboard.toast.copyError': '复制旅行失败', + 'dashboard.confirm.delete': + '删除旅行「{title}」?所有地点和计划将被永久删除。', + 'dashboard.editTrip': '编辑旅行', + 'dashboard.createTrip': '创建新旅行', + 'dashboard.tripTitle': '标题', + 'dashboard.tripTitlePlaceholder': '如:日本夏日之旅', + 'dashboard.tripDescription': '描述', + 'dashboard.tripDescriptionPlaceholder': '这次旅行是关于什么的?', + 'dashboard.startDate': '开始日期', + 'dashboard.endDate': '结束日期', + 'dashboard.dayCount': '天数', + 'dashboard.dayCountHint': '未设置旅行日期时要规划的天数。', + 'dashboard.noDateHint': '未设置日期——将默认创建 7 天。你可以随时修改。', + 'dashboard.coverImage': '封面图片', + 'dashboard.addCoverImage': '添加封面图片', + 'dashboard.addMembers': '旅伴', + 'dashboard.addMember': '添加成员', + 'dashboard.coverSaved': '封面图片已保存', + 'dashboard.coverUploadError': '上传失败', + 'dashboard.coverRemoveError': '移除失败', + 'dashboard.titleRequired': '标题为必填项', + 'dashboard.endDateError': '结束日期必须晚于开始日期', + 'dashboard.greeting.morning': '早上好,', + 'dashboard.greeting.afternoon': '下午好,', + 'dashboard.greeting.evening': '晚上好,', + 'dashboard.mobile.liveNow': '进行中', + 'dashboard.mobile.tripProgress': '旅行进度', + 'dashboard.mobile.daysLeft': '还剩 {count} 天', + 'dashboard.mobile.places': '地点', + 'dashboard.mobile.buddies': '旅伴', + 'dashboard.mobile.newTrip': '新建旅行', + 'dashboard.mobile.currency': '货币', + 'dashboard.mobile.timezone': '时区', + 'dashboard.mobile.upcomingTrips': '即将到来的旅行', + 'dashboard.mobile.yourTrips': '我的旅行', + 'dashboard.mobile.trips': '个旅行', + 'dashboard.mobile.starts': '出发', + 'dashboard.mobile.duration': '时长', + 'dashboard.mobile.day': '天', + 'dashboard.mobile.days': '天', + 'dashboard.mobile.ongoing': '进行中', + 'dashboard.mobile.startsToday': '今天出发', + 'dashboard.mobile.tomorrow': '明天', + 'dashboard.mobile.inDays': '{count} 天后', + 'dashboard.mobile.inMonths': '{count} 个月后', + 'dashboard.mobile.completed': '已完成', + 'dashboard.mobile.currencyConverter': '汇率转换', + 'dashboard.filter.planned': '已计划', + 'dashboard.hero.badgeLive': '进行中', + 'dashboard.hero.badgeToday': '今天开始', + 'dashboard.hero.badgeTomorrow': '明天', + 'dashboard.hero.badgeNext': '即将开始', + 'dashboard.hero.badgeRecent': '最近', + 'dashboard.hero.tripDates': '旅行日期', + 'dashboard.hero.noDates': '未设置日期', + 'dashboard.hero.travelerOne': '{count} 位旅客', + 'dashboard.hero.travelerMany': '{count} 位旅客', + 'dashboard.hero.destinationOne': '{count} 个目的地', + 'dashboard.hero.destinationMany': '{count} 个目的地', + 'dashboard.hero.dayUnitOne': '天', + 'dashboard.hero.dayUnitMany': '天', + 'dashboard.hero.dayLeft': '剩 1 天', + 'dashboard.hero.daysLeft': '剩余天数', + 'dashboard.hero.lastDay': '最后一天', + 'dashboard.hero.untilStart': '距开始', + 'dashboard.hero.startsIn': '距出发', + 'dashboard.atlas.countriesVisited': '地图集 · 已访问国家', + 'dashboard.atlas.ofTotal': '/ {total}', + 'dashboard.atlas.tripsTotal': '旅行总数', + 'dashboard.atlas.placesMapped': '已标记 {count} 个地点', + 'dashboard.atlas.daysTraveled': '旅行天数', + 'dashboard.atlas.daysUnit': '天', + 'dashboard.atlas.acrossAllTrips': '所有旅行累计', + 'dashboard.atlas.distanceFlown': '飞行距离', + 'dashboard.atlas.kmUnit': 'km', + 'dashboard.atlas.aroundEquator': '≈ 绕赤道 {count} 圈', + 'dashboard.card.idea': '想法', + 'dashboard.card.buddyOne': '旅伴', + 'dashboard.fx.from': '从', + 'dashboard.fx.to': '到', + 'dashboard.fx.unavailable': '无法获取汇率', + 'dashboard.tz.searchPlaceholder': '搜索时区…', + 'dashboard.tz.empty': '还没有其他时区 — 用 + 添加一个', + 'dashboard.upcoming.title': '即将到来的预订', + 'dashboard.upcoming.empty': '尚未预订任何内容。', + 'dashboard.confirm.copy.title': '复制这次旅行?', + 'dashboard.confirm.copy.willCopy': '将被复制', + 'dashboard.confirm.copy.will1': '天数、地点和每日安排', + 'dashboard.confirm.copy.will2': '住宿和预订', + 'dashboard.confirm.copy.will3': '预算项和分类顺序', + 'dashboard.confirm.copy.will4': '打包清单(未勾选)', + 'dashboard.confirm.copy.will5': '待办事项(未分配且未勾选)', + 'dashboard.confirm.copy.will6': '每日笔记', + 'dashboard.confirm.copy.wontCopy': '不会被复制', + 'dashboard.confirm.copy.wont1': '协作者和成员分配', + 'dashboard.confirm.copy.wont2': '协作笔记、投票和消息', + 'dashboard.confirm.copy.wont3': '文件和照片', + 'dashboard.confirm.copy.wont4': '共享令牌', + 'dashboard.confirm.copy.confirm': '复制旅行', + 'dashboard.aria.toggleView': '切换视图', + 'dashboard.aria.filter': '筛选', + 'dashboard.aria.duplicate': '复制', + 'dashboard.aria.refreshRates': '刷新汇率', + 'dashboard.aria.swapCurrencies': '交换货币', + 'dashboard.aria.addTimezone': '添加时区', + 'dashboard.aria.removeTimezone': '移除 {city}', + 'dashboard.dayCountRequired': '天数为必填项', +}; +export default dashboard; diff --git a/shared/src/i18n/zh/day.ts b/shared/src/i18n/zh/day.ts new file mode 100644 index 0000000000000000000000000000000000000000..dbd04fa4f94b35414153afb5888df91c0a21dd06 --- /dev/null +++ b/shared/src/i18n/zh/day.ts @@ -0,0 +1,25 @@ +import type { TranslationStrings } from '../types'; + +const day: TranslationStrings = { + 'day.precipProb': '降水概率', + 'day.precipitation': '降水量', + 'day.wind': '风速', + 'day.sunrise': '日出', + 'day.sunset': '日落', + 'day.hourlyForecast': '逐小时预报', + 'day.climateHint': '历史平均值——实际预报在该日期前 16 天内可用。', + 'day.noWeather': '无天气数据。请添加有坐标的地点。', + 'day.overview': '每日概览', + 'day.accommodation': '住宿', + 'day.addAccommodation': '添加住宿', + 'day.hotelDayRange': '应用到天数', + 'day.noPlacesForHotel': '请先在旅行中添加地点', + 'day.allDays': '全部', + 'day.checkIn': '入住', + 'day.checkInUntil': '截止', + 'day.checkOut': '退房', + 'day.confirmation': '确认号', + 'day.editAccommodation': '编辑住宿', + 'day.reservations': '预订', +}; +export default day; diff --git a/shared/src/i18n/zh/dayplan.ts b/shared/src/i18n/zh/dayplan.ts new file mode 100644 index 0000000000000000000000000000000000000000..06d5a7a579c7945baeccd6cab3cbeed3376c5fa8 --- /dev/null +++ b/shared/src/i18n/zh/dayplan.ts @@ -0,0 +1,55 @@ +import type { TranslationStrings } from '../types'; + +const dayplan: TranslationStrings = { + 'dayplan.icsTooltip': '导出日历 (ICS)', + 'dayplan.emptyDay': '当天暂无计划', + 'dayplan.addNote': '添加备注', + 'dayplan.editNote': '编辑备注', + 'dayplan.noteAdd': '添加备注', + 'dayplan.noteEdit': '编辑备注', + 'dayplan.noteTitle': '备注', + 'dayplan.noteSubtitle': '每日备注', + 'dayplan.totalCost': '总费用', + 'dayplan.days': '天', + 'dayplan.dayN': '第 {n} 天', + 'dayplan.calculating': '计算中...', + 'dayplan.route': '路线', + 'dayplan.optimize': '优化', + 'dayplan.optimized': '路线已优化', + 'dayplan.routeError': '路线计算失败', + 'dayplan.toast.needTwoPlaces': '路线优化至少需要两个地点', + 'dayplan.toast.routeOptimized': '路线已优化', + 'dayplan.toast.routeOptimizedFromHotel': '已根据您的住宿优化路线', + 'dayplan.toast.noGeoPlaces': '未找到有坐标的地点用于路线计算', + 'dayplan.confirmed': '已确认', + 'dayplan.pendingRes': '待确认', + 'dayplan.pdf': 'PDF', + 'dayplan.pdfTooltip': '导出当天计划为 PDF', + 'dayplan.pdfError': 'PDF 导出失败', + 'dayplan.cannotReorderTransport': '有固定时间的预订无法重新排序', + 'dayplan.confirmRemoveTimeTitle': '移除时间?', + 'dayplan.confirmRemoveTimeBody': + '此地点有固定时间({time})。移动后将移除时间并允许自由排序。', + 'dayplan.confirmRemoveTimeAction': '移除时间并移动', + 'dayplan.confirmDeleteNoteTitle': '删除备注?', + 'dayplan.confirmDeleteNoteBody': '此备注将被永久删除。', + 'dayplan.cannotDropOnTimed': '无法将项目放置在有固定时间的条目之间', + 'dayplan.cannotBreakChronology': '这将打乱已计划项目和预订的时间顺序', + 'dayplan.mobile.addPlace': '添加地点', + 'dayplan.mobile.searchPlaces': '搜索地点...', + 'dayplan.mobile.allAssigned': '所有地点已分配', + 'dayplan.mobile.noMatch': '无匹配', + 'dayplan.mobile.createNew': '创建新地点', + 'dayplan.expandAll': 'Expand all days', // en-fallback + 'dayplan.collapseAll': 'Collapse all days', // en-fallback + 'dayplan.reorderDays': '调整日期顺序', + 'dayplan.reorderTitle': '调整日期顺序', + 'dayplan.reorderHint': '该天的地点、备注和预订会随之一起移动。', + 'dayplan.addDay': '添加一天', + 'dayplan.moveUp': '上移', + 'dayplan.moveDown': '下移', + 'dayplan.reorderUndo': '调整日期顺序', + 'dayplan.reorderError': '调整日期顺序失败', + 'dayplan.addDayError': '添加一天失败', +}; +export default dayplan; diff --git a/shared/src/i18n/zh/externalNotifications.ts b/shared/src/i18n/zh/externalNotifications.ts new file mode 100644 index 0000000000000000000000000000000000000000..9759e5b57e63ea7f6f0387e9fabe532c1bbf569f --- /dev/null +++ b/shared/src/i18n/zh/externalNotifications.ts @@ -0,0 +1,62 @@ +import type { NotificationLocale } from '../externalNotifications/types'; + +const zh: NotificationLocale = { + email: { + footer: '您收到此邮件是因为您在 TREK 中启用了通知。', + manage: '管理偏好设置', + madeWith: 'Made with', + openTrek: '打开 TREK', + }, + events: { + trip_invite: (p) => ({ + title: `邀请加入"${p.trip}"`, + body: `${p.actor} 邀请了 ${p.invitee || '成员'} 加入旅行"${p.trip}"。`, + }), + booking_change: (p) => ({ + title: `新预订:${p.booking}`, + body: `${p.actor} 在"${p.trip}"中添加了预订"${p.booking}"(${p.type})。`, + }), + trip_reminder: (p) => ({ + title: `旅行提醒:${p.trip}`, + body: `你的旅行"${p.trip}"即将开始!`, + }), + todo_due: (p) => ({ + title: `待办事项即将到期:${p.todo}`, + body: `"${p.trip}" 中的"${p.todo}"将于 ${p.due} 到期。`, + }), + vacay_invite: (p) => ({ + title: 'Vacay 融合邀请', + body: `${p.actor} 邀请你合并假期计划。打开 TREK 接受或拒绝。`, + }), + photos_shared: (p) => ({ + title: `${p.count} 张照片已分享`, + body: `${p.actor} 在"${p.trip}"中分享了 ${p.count} 张照片。`, + }), + collab_message: (p) => ({ + title: `"${p.trip}"中的新消息`, + body: `${p.actor}:${p.preview}`, + }), + packing_tagged: (p) => ({ + title: `行李清单:${p.category}`, + body: `${p.actor} 将你分配到"${p.trip}"中的"${p.category}"类别。`, + }), + version_available: (p) => ({ + title: '新版 TREK 可用', + body: `TREK ${p.version} 现已可用。请前往管理面板进行更新。`, + }), + synology_session_cleared: () => ({ + title: 'Synology 会话已清除', + body: '您的 Synology 账户或 URL 已更改,您已退出 Synology Photos。', + }), + }, + passwordReset: { + subject: '重置您的密码', + greeting: '您好', + body: '我们收到了重置您的 TREK 账户密码的请求。点击下方按钮设置新密码。', + ctaIntro: '重置密码', + expiry: '此链接将在 60 分钟后失效。', + ignore: '如果这不是您本人的请求,可以忽略本邮件 — 您的密码不会改变。', + }, +}; + +export default zh; diff --git a/shared/src/i18n/zh/files.ts b/shared/src/i18n/zh/files.ts new file mode 100644 index 0000000000000000000000000000000000000000..da379d105a0414ceefef5255ea8c4f3972d7fce3 --- /dev/null +++ b/shared/src/i18n/zh/files.ts @@ -0,0 +1,60 @@ +import type { TranslationStrings } from '../types'; + +const files: TranslationStrings = { + 'files.title': '文件', + 'files.pageTitle': '文件与文档', + 'files.subtitle': '{trip} 的 {count} 个文件', + 'files.download': '下载', + 'files.openError': '无法打开文件', + 'files.downloadPdf': '下载 PDF', + 'files.count': '{count} 个文件', + 'files.countSingular': '1 个文件', + 'files.uploaded': '已上传 {count} 个', + 'files.uploadError': '上传失败', + 'files.dropzone': '将文件拖放到此处', + 'files.dropzoneHint': '或点击浏览', + 'files.allowedTypes': + '图片、PDF、DOC、DOCX、XLS、XLSX、TXT、CSV · 最大 50 MB', + 'files.uploading': '上传中...', + 'files.filterAll': '全部', + 'files.filterPdf': 'PDF', + 'files.filterImages': '图片', + 'files.filterDocs': '文档', + 'files.filterCollab': '协作笔记', + 'files.sourceCollab': '来自协作笔记', + 'files.empty': '暂无文件', + 'files.emptyHint': '上传文件以附加到旅行中', + 'files.openTab': '在新标签页中打开', + 'files.confirm.delete': '确定要删除此文件吗?', + 'files.toast.deleted': '文件已删除', + 'files.toast.deleteError': '删除文件失败', + 'files.sourcePlan': '日程计划', + 'files.sourceBooking': '预订', + 'files.sourceTransport': '交通', + 'files.attach': '附加', + 'files.pasteHint': '也可以从剪贴板粘贴图片 (Ctrl+V)', + 'files.trash': '回收站', + 'files.trashEmpty': '回收站为空', + 'files.emptyTrash': '清空回收站', + 'files.restore': '恢复', + 'files.star': '收藏', + 'files.unstar': '取消收藏', + 'files.assign': '分配', + 'files.assignTitle': '分配文件', + 'files.assignPlace': '地点', + 'files.assignBooking': '预订', + 'files.assignTransport': '交通', + 'files.unassigned': '未分配', + 'files.unlink': '移除关联', + 'files.toast.trashed': '已移至回收站', + 'files.toast.restored': '文件已恢复', + 'files.toast.trashEmptied': '回收站已清空', + 'files.toast.assigned': '文件已分配', + 'files.toast.assignError': '分配失败', + 'files.toast.restoreError': '恢复失败', + 'files.confirm.permanentDelete': '永久删除此文件?此操作无法撤销。', + 'files.confirm.emptyTrash': '永久删除回收站中的所有文件?此操作无法撤销。', + 'files.noteLabel': '备注', + 'files.notePlaceholder': '添加备注...', +}; +export default files; diff --git a/shared/src/i18n/zh/index.ts b/shared/src/i18n/zh/index.ts new file mode 100644 index 0000000000000000000000000000000000000000..77aeb6a09fb62e2522e8b4c04e4169a94c2f8d99 --- /dev/null +++ b/shared/src/i18n/zh/index.ts @@ -0,0 +1,86 @@ +import admin from './admin'; +import airport from './airport'; +import atlas from './atlas'; +import backup from './backup'; +import budget from './budget'; +import categories from './categories'; +import collab from './collab'; +import common from './common'; +import dashboard from './dashboard'; +import day from './day'; +import dayplan from './dayplan'; +import files from './files'; +import inspector from './inspector'; +import journey from './journey'; +import login from './login'; +import map from './map'; +import members from './members'; +import memories from './memories'; +import nav from './nav'; +import notif from './notif'; +import notifications from './notifications'; +import oauth from './oauth'; +import packing from './packing'; +import pdf from './pdf'; +import perm from './perm'; +import photos from './photos'; +import places from './places'; +import planner from './planner'; +import register from './register'; +import reservations from './reservations'; +import settings from './settings'; +import share from './share'; +import shared from './shared'; +import stats from './stats'; +import system_notice from './system_notice'; +import todo from './todo'; +import transport from './transport'; +import trip from './trip'; +import trips from './trips'; +import undo from './undo'; +import vacay from './vacay'; + +const locale = { + ...common, + ...trips, + ...nav, + ...dashboard, + ...settings, + ...admin, + ...dayplan, + ...share, + ...shared, + ...login, + ...register, + ...vacay, + ...atlas, + ...trip, + ...places, + ...inspector, + ...reservations, + ...airport, + ...map, + ...budget, + ...files, + ...packing, + ...members, + ...categories, + ...backup, + ...photos, + ...pdf, + ...planner, + ...stats, + ...day, + ...memories, + ...collab, + ...perm, + ...undo, + ...notifications, + ...todo, + ...notif, + ...journey, + ...oauth, + ...system_notice, + ...transport, +}; +export default locale; diff --git a/shared/src/i18n/zh/inspector.ts b/shared/src/i18n/zh/inspector.ts new file mode 100644 index 0000000000000000000000000000000000000000..b2c0d908b12365f0a6ca7cbe6bf83b17f0754450 --- /dev/null +++ b/shared/src/i18n/zh/inspector.ts @@ -0,0 +1,22 @@ +import type { TranslationStrings } from '../types'; + +const inspector: TranslationStrings = { + 'inspector.opened': '营业中', + 'inspector.closed': '已关闭', + 'inspector.openingHours': '营业时间', + 'inspector.showHours': '显示营业时间', + 'inspector.files': '文件', + 'inspector.filesCount': '{count} 个文件', + 'inspector.removeFromDay': '从当天移除', + 'inspector.remove': '删除', + 'inspector.addToDay': '添加到当天', + 'inspector.confirmedRes': '已确认预订', + 'inspector.pendingRes': '待确认预订', + 'inspector.google': '在 Google Maps 中打开', + 'inspector.website': '打开网站', + 'inspector.addRes': '预订', + 'inspector.editRes': '编辑预订', + 'inspector.participants': '参与者', + 'inspector.trackStats': '轨迹数据', +}; +export default inspector; diff --git a/shared/src/i18n/zh/journey.ts b/shared/src/i18n/zh/journey.ts new file mode 100644 index 0000000000000000000000000000000000000000..d3510b704ba1a911e214a3db495285bcaa7eb235 --- /dev/null +++ b/shared/src/i18n/zh/journey.ts @@ -0,0 +1,234 @@ +import type { TranslationStrings } from '../types'; + +const journey: TranslationStrings = { + 'journey.search.placeholder': '搜索旅程…', + 'journey.search.noResults': '没有与"{query}"匹配的旅程', + 'journey.title': '旅程', + 'journey.subtitle': '实时记录你的旅行', + 'journey.new': '新建旅程', + 'journey.create': '创建', + 'journey.titlePlaceholder': '你要去哪里?', + 'journey.empty': '还没有旅程', + 'journey.emptyHint': '开始记录你的下一次旅行', + 'journey.deleted': '旅程已删除', + 'journey.createError': '无法创建旅程', + 'journey.deleteError': '无法删除旅程', + 'journey.deleteConfirmTitle': '删除', + 'journey.deleteConfirmMessage': '删除"{title}"?此操作无法撤销。', + 'journey.deleteConfirmGeneric': '确定要删除吗?', + 'journey.notFound': '未找到旅程', + 'journey.photos': '照片', + 'journey.timelineEmpty': '还没有行程', + 'journey.timelineEmptyHint': '添加一个签到或写一篇日志开始记录', + 'journey.status.draft': '草稿', + 'journey.status.active': '进行中', + 'journey.status.completed': '已完成', + 'journey.status.upcoming': '即将开始', + 'journey.status.archived': '已归档', + 'journey.checkin.add': '签到', + 'journey.checkin.namePlaceholder': '地点名称', + 'journey.checkin.notesPlaceholder': '备注(可选)', + 'journey.checkin.save': '保存', + 'journey.checkin.error': '无法保存签到', + 'journey.entry.add': '日志', + 'journey.entry.edit': '编辑条目', + 'journey.entry.titlePlaceholder': '标题(可选)', + 'journey.entry.bodyPlaceholder': '今天发生了什么?', + 'journey.entry.save': '保存', + 'journey.entry.error': '无法保存条目', + 'journey.photo.add': '照片', + 'journey.photo.uploadError': '上传失败', + 'journey.share.share': '分享', + 'journey.share.public': '公开', + 'journey.share.linkCopied': '公开链接已复制', + 'journey.share.disabled': '已关闭公开分享', + 'journey.editor.titlePlaceholder': '给这个瞬间起个名字...', + 'journey.editor.bodyPlaceholder': '讲述这一天的故事...', + 'journey.editor.placePlaceholder': '地点(可选)', + 'journey.editor.tagsPlaceholder': '标签:隐藏宝藏、最佳美食、值得再去...', + 'journey.visibility.private': '私密', + 'journey.visibility.shared': '共享', + 'journey.visibility.public': '公开', + 'journey.emptyState.title': '你的故事从这里开始', + 'journey.emptyState.subtitle': '在某个地方签到或写下你的第一篇日志', + 'journey.frontpage.subtitle': '将旅行变成永远不会忘记的故事', + 'journey.frontpage.createJourney': '创建旅程', + 'journey.frontpage.activeJourney': '进行中的旅程', + 'journey.frontpage.allJourneys': '所有旅程', + 'journey.frontpage.journeys': '个旅程', + 'journey.frontpage.createNew': '创建新旅程', + 'journey.frontpage.createNewSub': '选择旅行、写故事、分享你的冒险', + 'journey.frontpage.live': '实时', + 'journey.frontpage.synced': '已同步', + 'journey.frontpage.continueWriting': '继续写作', + 'journey.frontpage.updated': '更新于 {time}', + 'journey.frontpage.suggestionLabel': '旅行刚结束', + 'journey.frontpage.suggestionText': + '将 {title} 变成一段旅程', + 'journey.frontpage.dismiss': '忽略', + 'journey.frontpage.journeyName': '旅程名称', + 'journey.frontpage.namePlaceholder': '例如 东南亚 2026', + 'journey.frontpage.selectTrips': '选择旅行', + 'journey.frontpage.tripsSelected': '个旅行已选择', + 'journey.frontpage.trips': '个旅行', + 'journey.frontpage.placesImported': '个地点将被导入', + 'journey.frontpage.places': '个地点', + 'journey.detail.backToJourney': '返回旅程', + 'journey.detail.syncedWithTrips': '已与旅行同步', + 'journey.detail.addEntry': '添加条目', + 'journey.detail.newEntry': '新建条目', + 'journey.detail.editEntry': '编辑条目', + 'journey.detail.noEntries': '还没有条目', + 'journey.detail.noEntriesHint': '添加一个旅行以生成骨架条目', + 'journey.detail.noPhotos': '还没有照片', + 'journey.detail.noPhotosHint': + '上传照片到条目或浏览你的 Immich/Synology 相册', + 'journey.detail.journeyStats': '旅程统计', + 'journey.detail.syncedTrips': '已同步的旅行', + 'journey.detail.noTripsLinked': '尚未关联旅行', + 'journey.detail.contributors': '贡献者', + 'journey.detail.readMore': '阅读更多', + 'journey.detail.prosCons': '优缺点', + 'journey.detail.photos': '照片', + 'journey.detail.day': '第{number}天', + 'journey.detail.places': '个地点', + 'journey.stats.days': '天', + 'journey.stats.cities': '城市', + 'journey.stats.entries': '条目', + 'journey.stats.photos': '照片', + 'journey.stats.places': '地点', + 'journey.skeletons.show': '显示建议', + 'journey.skeletons.hide': '隐藏建议', + 'journey.verdict.lovedIt': '非常喜欢', + 'journey.verdict.couldBeBetter': '有待改进', + 'journey.synced.places': '个地点', + 'journey.synced.synced': '已同步', + 'journey.editor.discardChangesConfirm': '您有未保存的更改。要放弃吗?', + 'journey.editor.uploadFailed': '照片上传失败', + 'journey.editor.uploadPhotos': '上传照片', + 'journey.editor.uploading': '上传中...', + 'journey.editor.uploadingProgress': '上传中 {done}/{total}…', + 'journey.editor.uploadPartialFailed': + '{total} 张中有 {failed} 张上传失败 — 再次保存以重试', + 'journey.editor.fromGallery': '从相册', + 'journey.editor.allPhotosAdded': '所有照片已添加', + 'journey.editor.writeStory': '写下你的故事...', + 'journey.editor.prosCons': '优缺点', + 'journey.editor.pros': '优点', + 'journey.editor.cons': '缺点', + 'journey.editor.proPlaceholder': '好的方面...', + 'journey.editor.conPlaceholder': '不好的方面...', + 'journey.editor.addAnother': '再添加一个', + 'journey.editor.date': '日期', + 'journey.editor.location': '地点', + 'journey.editor.searchLocation': '搜索地点...', + 'journey.editor.mood': '心情', + 'journey.editor.weather': '天气', + 'journey.editor.photoFirst': '第1张', + 'journey.editor.makeFirst': '设为第1张', + 'journey.editor.searching': '搜索中...', + 'journey.mood.amazing': '太棒了', + 'journey.mood.good': '不错', + 'journey.mood.neutral': '一般', + 'journey.mood.rough': '糟糕', + 'journey.weather.sunny': '晴天', + 'journey.weather.partly': '多云', + 'journey.weather.cloudy': '阴天', + 'journey.weather.rainy': '雨天', + 'journey.weather.stormy': '暴风雨', + 'journey.weather.cold': '雪天', + 'journey.trips.linkTrip': '关联旅行', + 'journey.trips.searchTrip': '搜索旅行', + 'journey.trips.searchPlaceholder': '旅行名称或目的地...', + 'journey.trips.noTripsAvailable': '没有可用的旅行', + 'journey.trips.link': '关联', + 'journey.trips.tripLinked': '旅行已关联', + 'journey.trips.linkFailed': '关联旅行失败', + 'journey.trips.addTrip': '添加旅行', + 'journey.trips.unlinkTrip': '取消关联旅行', + 'journey.trips.unlinkMessage': + '取消关联"{title}"?此旅行中所有已同步的条目和照片将被永久删除。此操作无法撤销。', + 'journey.trips.unlink': '取消关联', + 'journey.trips.tripUnlinked': '旅行已取消关联', + 'journey.trips.unlinkFailed': '取消关联失败', + 'journey.trips.noTripsLinkedSettings': '未关联旅行', + 'journey.contributors.invite': '邀请贡献者', + 'journey.contributors.searchUser': '搜索用户', + 'journey.contributors.searchPlaceholder': '用户名或邮箱...', + 'journey.contributors.noUsers': '未找到用户', + 'journey.contributors.role': '角色', + 'journey.contributors.added': '贡献者已添加', + 'journey.contributors.addFailed': '添加贡献者失败', + 'journey.share.publicShare': '公开分享', + 'journey.share.createLink': '创建分享链接', + 'journey.share.linkCreated': '分享链接已创建', + 'journey.share.createFailed': '创建链接失败', + 'journey.share.copy': '复制', + 'journey.share.copied': '已复制!', + 'journey.share.timeline': '时间线', + 'journey.share.gallery': '图库', + 'journey.share.map': '地图', + 'journey.share.removeLink': '移除分享链接', + 'journey.share.linkDeleted': '分享链接已删除', + 'journey.share.deleteFailed': '删除失败', + 'journey.share.updateFailed': '更新失败', + 'journey.invite.role': '角色', + 'journey.invite.viewer': '查看者', + 'journey.invite.editor': '编辑者', + 'journey.invite.invite': '邀请', + 'journey.invite.inviting': '邀请中...', + 'journey.settings.title': '旅程设置', + 'journey.settings.coverImage': '封面图片', + 'journey.settings.changeCover': '更换封面', + 'journey.settings.addCover': '添加封面图片', + 'journey.settings.name': '名称', + 'journey.settings.subtitle': '副标题', + 'journey.settings.subtitlePlaceholder': '例如 泰国、越南和柬埔寨', + 'journey.settings.endJourney': '归档旅程', + 'journey.settings.reopenJourney': '恢复旅程', + 'journey.settings.archived': '旅程已归档', + 'journey.settings.reopened': '旅程已重新开启', + 'journey.settings.endDescription': '隐藏直播标记。您可以随时重新开启。', + 'journey.settings.delete': '删除', + 'journey.settings.deleteJourney': '删除旅程', + 'journey.settings.deleteMessage': '删除"{title}"?所有条目和照片将丢失。', + 'journey.settings.saved': '设置已保存', + 'journey.settings.saveFailed': '保存失败', + 'journey.settings.coverUpdated': '封面已更新', + 'journey.settings.coverFailed': '上传失败', + 'journey.settings.failedToDelete': '删除失败', + 'journey.entries.deleteTitle': '删除条目', + 'journey.photosUploaded': '{count} 张照片已上传', + 'journey.photosUploadFailed': '部分照片上传失败', + 'journey.photosAdded': '{count} 张照片已添加', + 'journey.public.notFound': '未找到', + 'journey.public.notFoundMessage': '此旅程不存在或链接已过期。', + 'journey.public.readOnly': '只读 · 公开旅程', + 'journey.public.tagline': '旅行资源与探索工具包', + 'journey.public.sharedVia': '分享自', + 'journey.public.madeWith': '由', + 'journey.pdf.journeyBook': '旅程手册', + 'journey.pdf.madeWith': '由 TREK 制作', + 'journey.pdf.day': '第', + 'journey.pdf.theEnd': '终', + 'journey.pdf.saveAsPdf': '保存为 PDF', + 'journey.pdf.pages': '页', + 'journey.picker.tripPeriod': '旅行时间段', + 'journey.picker.dateRange': '日期范围', + 'journey.picker.allPhotos': '所有照片', + 'journey.picker.albums': '相册', + 'journey.picker.selected': '已选择', + 'journey.picker.addTo': '添加到', + 'journey.picker.newGallery': '新相册', + 'journey.picker.selectAll': '全选', + 'journey.picker.deselectAll': '取消全选', + 'journey.picker.noAlbums': '未找到相册', + 'journey.picker.selectDate': '选择日期', + 'journey.picker.search': '搜索', + 'journey.detail.journeyTab': 'Journey', // en-fallback + 'journey.contributors.remove': 'Remove contributor', // en-fallback + 'journey.contributors.removeConfirm': 'Remove {username} from this journey?', // en-fallback + 'journey.contributors.removed': 'Contributor removed', // en-fallback + 'journey.contributors.removeFailed': 'Failed to remove contributor', // en-fallback +}; +export default journey; diff --git a/shared/src/i18n/zh/login.ts b/shared/src/i18n/zh/login.ts new file mode 100644 index 0000000000000000000000000000000000000000..6c6fff97d83256e09b78bf4f71f13094b0c75ffd --- /dev/null +++ b/shared/src/i18n/zh/login.ts @@ -0,0 +1,90 @@ +import type { TranslationStrings } from '../types'; + +const login: TranslationStrings = { + 'login.error': '登录失败,请检查你的凭据。', + 'login.tagline': '你的旅行。\n你的计划。', + 'login.description': '通过互动地图、预算管理和实时同步,协同规划旅行。', + 'login.features.maps': '互动地图', + 'login.features.mapsDesc': 'Google Places、路线和聚类', + 'login.features.realtime': '实时同步', + 'login.features.realtimeDesc': '通过 WebSocket 协同规划', + 'login.features.budget': '预算跟踪', + 'login.features.budgetDesc': '分类、图表和人均费用', + 'login.features.collab': '协作', + 'login.features.collabDesc': '多用户共享旅行', + 'login.features.packing': '行李清单', + 'login.features.packingDesc': '分类、进度和建议', + 'login.features.bookings': '预订', + 'login.features.bookingsDesc': '航班、酒店、餐厅等', + 'login.features.files': '文档', + 'login.features.filesDesc': '上传和管理文档', + 'login.features.routes': '智能路线', + 'login.features.routesDesc': '自动优化和导出到 Google Maps', + 'login.selfHosted': '自托管 · 开源 · 数据由你掌控', + 'login.title': '登录', + 'login.subtitle': '欢迎回来', + 'login.signingIn': '登录中…', + 'login.signIn': '登录', + 'login.createAdmin': '创建管理员账户', + 'login.createAdminHint': '为 TREK 设置第一个管理员账户。', + 'login.setNewPassword': '设置新密码', + 'login.setNewPasswordHint': '您必须更改密码才能继续。', + 'login.createAccount': '创建账户', + 'login.createAccountHint': '注册新账户。', + 'login.creating': '创建中…', + 'login.noAccount': '还没有账户?', + 'login.hasAccount': '已有账户?', + 'login.register': '注册', + 'login.emailPlaceholder': 'your@email.com', + 'login.username': '用户名', + 'login.oidc.registrationDisabled': '注册已关闭。请联系管理员。', + 'login.oidc.noEmail': '未从提供商获取到邮箱。', + 'login.mfaTitle': '双因素认证', + 'login.mfaSubtitle': '请输入身份验证器应用中的 6 位验证码。', + 'login.mfaCodeLabel': '验证码', + 'login.mfaCodeRequired': '请输入身份验证器应用中的验证码。', + 'login.mfaHint': '打开 Google Authenticator、Authy 或其他 TOTP 应用。', + 'login.mfaBack': '← 返回登录', + 'login.mfaVerify': '验证', + 'login.invalidInviteLink': '邀请链接无效或已过期', + 'login.oidcFailed': 'OIDC 登录失败', + 'login.usernameRequired': '用户名为必填项', + 'login.passwordMinLength': '密码至少需要8个字符', + 'login.forgotPassword': '忘记密码?', + 'login.rememberMe': '记住我', + 'login.forgotPasswordTitle': '重置密码', + 'login.forgotPasswordBody': + '输入您注册时使用的邮箱地址。若账户存在,我们将发送重置链接。', + 'login.forgotPasswordSubmit': '发送重置链接', + 'login.forgotPasswordSentTitle': '请查看邮箱', + 'login.forgotPasswordSentBody': + '若该邮箱存在账户,重置链接正在发送中。链接将在 60 分钟后失效。', + 'login.forgotPasswordSmtpHintOff': + '提示:管理员未配置 SMTP,重置链接将被写入服务器控制台,而不是通过电子邮件发送。', + 'login.backToLogin': '返回登录', + 'login.newPassword': '新密码', + 'login.confirmPassword': '确认新密码', + 'login.passwordsDontMatch': '两次输入的密码不一致', + 'login.mfaCode': '二步验证码', + 'login.resetPasswordTitle': '设置新密码', + 'login.resetPasswordBody': '请选择您在此处未使用过的强密码。至少 8 位。', + 'login.resetPasswordMfaBody': '输入您的二步验证码或备用代码以完成重置。', + 'login.resetPasswordSubmit': '重置密码', + 'login.resetPasswordVerify': '验证并重置', + 'login.resetPasswordSuccessTitle': '密码已更新', + 'login.resetPasswordSuccessBody': '您现在可以使用新密码登录了。', + 'login.resetPasswordInvalidLink': '无效的重置链接', + 'login.resetPasswordInvalidLinkBody': + '此链接已丢失或损坏。请重新申请以继续。', + 'login.resetPasswordFailed': '重置失败。链接可能已过期。', + 'login.oidc.tokenFailed': '认证失败。', + 'login.oidc.invalidState': '会话无效,请重试。', + 'login.demoFailed': '演示登录失败', + 'login.oidcSignIn': '通过 {name} 登录', + 'login.oidcOnly': '密码登录已关闭。请通过 SSO 提供商登录。', + 'login.oidcLoggedOut': '您已退出登录。请重新通过 SSO 提供商登录。', + 'login.demoHint': '试用演示——无需注册', + 'login.passkey.signIn': '使用通行密钥登录', + 'login.passkey.failed': '通行密钥登录失败,请重试。', +}; +export default login; diff --git a/shared/src/i18n/zh/map.ts b/shared/src/i18n/zh/map.ts new file mode 100644 index 0000000000000000000000000000000000000000..002e32ae6a969429db445895e45bac0ab0ecd42e --- /dev/null +++ b/shared/src/i18n/zh/map.ts @@ -0,0 +1,17 @@ +import type { TranslationStrings } from '../types'; + +const map: TranslationStrings = { + 'map.connections': '连接', + 'map.showConnections': '显示预订路线', + 'map.hideConnections': '隐藏预订路线', + 'poi.searchThisArea': '搜索此区域', + 'poi.cat.restaurants': '餐厅', + 'poi.cat.cafes': '咖啡馆', + 'poi.cat.bars': '酒吧与夜生活', + 'poi.cat.hotels': '住宿', + 'poi.cat.sights': '景点', + 'poi.cat.museums': '博物馆与文化', + 'poi.cat.nature': '自然与公园', + 'poi.cat.activities': '活动', +}; +export default map; diff --git a/shared/src/i18n/zh/members.ts b/shared/src/i18n/zh/members.ts new file mode 100644 index 0000000000000000000000000000000000000000..d2a62003e606061b97b6aaac33555c25f849afb5 --- /dev/null +++ b/shared/src/i18n/zh/members.ts @@ -0,0 +1,24 @@ +import type { TranslationStrings } from '../types'; + +const members: TranslationStrings = { + 'members.shareTrip': '分享旅行', + 'members.inviteUser': '邀请用户', + 'members.selectUser': '选择用户…', + 'members.invite': '邀请', + 'members.allHaveAccess': '所有用户均已拥有访问权限。', + 'members.access': '访问权限', + 'members.person': '人', + 'members.persons': '人', + 'members.you': '你', + 'members.owner': '所有者', + 'members.leaveTrip': '退出旅行', + 'members.removeAccess': '移除访问权限', + 'members.confirmLeave': '退出旅行?你将失去访问权限。', + 'members.confirmRemove': '移除该用户的访问权限?', + 'members.loadError': '加载成员失败', + 'members.added': '已添加', + 'members.addError': '添加失败', + 'members.removed': '成员已移除', + 'members.removeError': '移除失败', +}; +export default members; diff --git a/shared/src/i18n/zh/memories.ts b/shared/src/i18n/zh/memories.ts new file mode 100644 index 0000000000000000000000000000000000000000..10638946835bde448d2036a1208e6bdf99c87551 --- /dev/null +++ b/shared/src/i18n/zh/memories.ts @@ -0,0 +1,77 @@ +import type { TranslationStrings } from '../types'; + +const memories: TranslationStrings = { + 'memories.title': '照片', + 'memories.notConnected': 'Immich 未连接', + 'memories.notConnectedHint': + '在设置中连接您的 Immich 实例以在此查看旅行照片。', + 'memories.notConnectedMultipleHint': + '请在设置中连接以下任一照片提供商:{provider_names},以便向此行程添加照片。', + 'memories.noDates': '为旅行添加日期以加载照片。', + 'memories.noPhotos': '未找到照片', + 'memories.noPhotosHint': 'Immich 中未找到此旅行日期范围内的照片。', + 'memories.photosFound': '张照片', + 'memories.fromOthers': '来自他人', + 'memories.sharePhotos': '分享照片', + 'memories.sharing': '分享中', + 'memories.reviewTitle': '审查您的照片', + 'memories.reviewHint': '点击照片以将其从分享中排除。', + 'memories.shareCount': '分享 {count} 张照片', + 'memories.providerUrl': '服务器 URL', + 'memories.providerApiKey': 'API 密钥', + 'memories.providerUsername': '用户名', + 'memories.providerPassword': '密码', + 'memories.providerOTP': 'MFA 验证码(如已启用)', + 'memories.skipSSLVerification': '跳过 SSL 证书验证', + 'memories.immichAutoUpload': '上传 Journey 照片时同步到 Immich', + 'memories.providerUrlHintSynology': + '在 URL 中包含照片应用路径,例如 https://nas:5001/photo', + 'memories.testConnection': '测试连接', + 'memories.testShort': '测试', + 'memories.testFirst': '请先测试连接', + 'memories.connected': '已连接', + 'memories.disconnected': '未连接', + 'memories.connectionSuccess': '已连接到 Immich', + 'memories.connectionError': '无法连接到 Immich', + 'memories.saved': '{provider_name} 设置已保存', + 'memories.providerDisconnectedBanner': + '您与 {provider_name} 的连接已断开。请在设置中重新连接以查看照片。', + 'memories.saveError': '无法保存 {provider_name} 设置', + 'memories.oldest': '最早优先', + 'memories.newest': '最新优先', + 'memories.allLocations': '所有地点', + 'memories.addPhotos': '添加照片', + 'memories.linkAlbum': '关联相册', + 'memories.selectAlbum': '选择 Immich 相册', + 'memories.selectAlbumMultiple': '选择相册', + 'memories.noAlbums': '未找到相册', + 'memories.syncAlbum': '同步相册', + 'memories.unlinkAlbum': '取消关联', + 'memories.photos': '张照片', + 'memories.selectPhotos': '从 Immich 选择照片', + 'memories.selectPhotosMultiple': '选择照片', + 'memories.selectHint': '点击照片以选择。', + 'memories.selected': '已选择', + 'memories.addSelected': '添加 {count} 张照片', + 'memories.alreadyAdded': '已添加', + 'memories.private': '私密', + 'memories.stopSharing': '停止分享', + 'memories.tripDates': '旅行日期', + 'memories.allPhotos': '所有照片', + 'memories.confirmShareTitle': '与旅行成员分享?', + 'memories.confirmShareHint': + '{count} 张照片将对本次旅行的所有成员可见。你可以稍后将单张照片设为私密。', + 'memories.confirmShareButton': '分享照片', + 'memories.error.loadAlbums': '加载相册失败', + 'memories.error.linkAlbum': '关联相册失败', + 'memories.error.unlinkAlbum': '取消关联相册失败', + 'memories.error.syncAlbum': '同步相册失败', + 'memories.error.loadPhotos': '加载照片失败', + 'memories.error.addPhotos': '添加照片失败', + 'memories.error.removePhoto': '删除照片失败', + 'memories.error.toggleSharing': '更新共享设置失败', + 'memories.saveRouteNotConfigured': '此提供商未配置保存路由', + 'memories.testRouteNotConfigured': '此提供商未配置测试路由', + 'memories.fillRequiredFields': '请填写所有必填字段', +}; +export default memories; diff --git a/shared/src/i18n/zh/nav.ts b/shared/src/i18n/zh/nav.ts new file mode 100644 index 0000000000000000000000000000000000000000..d632bde6e82164fb08c5f0b410bd879e14fe30ed --- /dev/null +++ b/shared/src/i18n/zh/nav.ts @@ -0,0 +1,20 @@ +import type { TranslationStrings } from '../types'; + +const nav: TranslationStrings = { + 'nav.trip': '旅行', + 'nav.share': '分享', + 'nav.settings': '设置', + 'nav.admin': '管理', + 'nav.logout': '退出登录', + 'nav.lightMode': '浅色模式', + 'nav.darkMode': '深色模式', + 'nav.autoMode': '自动模式', + 'nav.administrator': '管理员', + 'nav.myTrips': '我的旅行', + 'nav.profile': '个人资料', + 'nav.bottomSettings': '设置', + 'nav.bottomAdmin': '管理设置', + 'nav.bottomLogout': '退出登录', + 'nav.bottomAdminBadge': '管理员', +}; +export default nav; diff --git a/shared/src/i18n/zh/notif.ts b/shared/src/i18n/zh/notif.ts new file mode 100644 index 0000000000000000000000000000000000000000..8c12337690fdf9ee1451cd30860cca5f90088e05 --- /dev/null +++ b/shared/src/i18n/zh/notif.ts @@ -0,0 +1,41 @@ +import type { TranslationStrings } from '../types'; + +const notif: TranslationStrings = { + 'notif.test.title': '[测试] 通知', + 'notif.test.simple.text': '这是一条简单的测试通知。', + 'notif.test.boolean.text': '您是否接受此测试通知?', + 'notif.test.navigate.text': '点击下方前往控制台。', + 'notif.trip_invite.title': '旅行邀请', + 'notif.trip_invite.text': '{actor} 邀请您加入 {trip}', + 'notif.booking_change.title': '预订已更新', + 'notif.booking_change.text': '{actor} 更新了 {trip} 中的预订', + 'notif.trip_reminder.title': '旅行提醒', + 'notif.trip_reminder.text': '您的旅行 {trip} 即将开始!', + 'notif.todo_due.title': '待办事项即将到期', + 'notif.todo_due.text': '{trip} 中的 {todo} 将于 {due} 到期', + 'notif.vacay_invite.title': 'Vacay 融合邀请', + 'notif.vacay_invite.text': '{actor} 邀请您合并假期计划', + 'notif.photos_shared.title': '照片已分享', + 'notif.photos_shared.text': '{actor} 在 {trip} 中分享了 {count} 张照片', + 'notif.collab_message.title': '新消息', + 'notif.collab_message.text': '{actor} 在 {trip} 中发送了消息', + 'notif.packing_tagged.title': '行李分配', + 'notif.packing_tagged.text': '{actor} 将您分配到 {trip} 中的 {category}', + 'notif.version_available.title': '新版本可用', + 'notif.version_available.text': 'TREK {version} 现已可用', + 'notif.action.view_trip': '查看旅行', + 'notif.action.view_collab': '查看消息', + 'notif.action.view_packing': '查看行李', + 'notif.action.view_photos': '查看照片', + 'notif.action.view_vacay': '查看 Vacay', + 'notif.action.view_admin': '前往管理', + 'notif.action.view': '查看', + 'notif.action.accept': '接受', + 'notif.action.decline': '拒绝', + 'notif.generic.title': '通知', + 'notif.generic.text': '您有一条新通知', + 'notif.dev.unknown_event.title': '[DEV] 未知事件', + 'notif.dev.unknown_event.text': + '事件类型 "{event}" 未在 EVENT_NOTIFICATION_CONFIG 中注册', +}; +export default notif; diff --git a/shared/src/i18n/zh/notifications.ts b/shared/src/i18n/zh/notifications.ts new file mode 100644 index 0000000000000000000000000000000000000000..daf0f462a4ec404a2e4c75c30bcba049cf5f557b --- /dev/null +++ b/shared/src/i18n/zh/notifications.ts @@ -0,0 +1,36 @@ +import type { TranslationStrings } from '../types'; + +const notifications: TranslationStrings = { + 'notifications.title': '通知', + 'notifications.markAllRead': '全部标为已读', + 'notifications.deleteAll': '全部删除', + 'notifications.showAll': '查看所有通知', + 'notifications.empty': '暂无通知', + 'notifications.emptyDescription': '您已全部查阅!', + 'notifications.all': '全部', + 'notifications.unreadOnly': '未读', + 'notifications.markRead': '标为已读', + 'notifications.markUnread': '标为未读', + 'notifications.delete': '删除', + 'notifications.system': '系统', + 'notifications.synologySessionCleared.title': 'Synology Photos 已断开连接', + 'notifications.synologySessionCleared.text': + '您的服务器或账户已更改 — 请前往设置重新测试您的连接。', + 'notifications.test.title': '来自 {actor} 的测试通知', + 'notifications.test.text': '这是一条简单的测试通知。', + 'notifications.test.booleanTitle': '{actor} 请求您的审批', + 'notifications.test.booleanText': '测试布尔通知。', + 'notifications.test.accept': '批准', + 'notifications.test.decline': '拒绝', + 'notifications.test.navigateTitle': '查看详情', + 'notifications.test.navigateText': '测试跳转通知。', + 'notifications.test.goThere': '前往', + 'notifications.test.adminTitle': '管理员广播', + 'notifications.test.adminText': '{actor} 向所有管理员发送了测试通知。', + 'notifications.test.tripTitle': '{actor} 在您的行程中发帖', + 'notifications.test.tripText': '行程"{trip}"的测试通知。', + 'notifications.versionAvailable.title': '有可用更新', + 'notifications.versionAvailable.text': 'TREK {version} 现已可用。', + 'notifications.versionAvailable.button': '查看详情', +}; +export default notifications; diff --git a/shared/src/i18n/zh/oauth.ts b/shared/src/i18n/zh/oauth.ts new file mode 100644 index 0000000000000000000000000000000000000000..2fc581a55f43c4696bd6e4484afe1f7cc539ba6f --- /dev/null +++ b/shared/src/i18n/zh/oauth.ts @@ -0,0 +1,101 @@ +import type { TranslationStrings } from '../types'; + +const oauth: TranslationStrings = { + 'oauth.scope.group.trips': '行程', + 'oauth.scope.group.places': '地点', + 'oauth.scope.group.atlas': 'Atlas', + 'oauth.scope.group.packing': '行李', + 'oauth.scope.group.todos': '待办事项', + 'oauth.scope.group.budget': '预算', + 'oauth.scope.group.reservations': '预订', + 'oauth.scope.group.collab': '协作', + 'oauth.scope.group.notifications': '通知', + 'oauth.scope.group.vacay': '假期', + 'oauth.scope.group.geo': 'Geo', + 'oauth.scope.group.weather': '天气', + 'oauth.scope.group.journey': '旅程', + 'oauth.scope.trips:read.label': '查看行程和行程计划', + 'oauth.scope.trips:read.description': '读取行程、天数、每日笔记和成员', + 'oauth.scope.trips:write.label': '编辑行程和行程计划', + 'oauth.scope.trips:write.description': '创建和更新行程、天数、笔记并管理成员', + 'oauth.scope.trips:delete.label': '删除行程', + 'oauth.scope.trips:delete.description': '永久删除整个行程——此操作不可撤销', + 'oauth.scope.trips:share.label': '管理分享链接', + 'oauth.scope.trips:share.description': '创建、更新和撤销行程的公开分享链接', + 'oauth.scope.places:read.label': '查看地点和地图数据', + 'oauth.scope.places:read.description': '读取地点、每日分配、标签和分类', + 'oauth.scope.places:write.label': '管理地点', + 'oauth.scope.places:write.description': '创建、更新和删除地点、分配和标签', + 'oauth.scope.atlas:read.label': '查看 Atlas', + 'oauth.scope.atlas:read.description': '读取已访问国家、地区和心愿清单', + 'oauth.scope.atlas:write.label': '管理 Atlas', + 'oauth.scope.atlas:write.description': '标记已访问国家和地区,管理心愿清单', + 'oauth.scope.packing:read.label': '查看行李清单', + 'oauth.scope.packing:read.description': '读取行李物品、包袋和分类负责人', + 'oauth.scope.packing:write.label': '管理行李清单', + 'oauth.scope.packing:write.description': + '添加、更新、删除、勾选和重新排列行李物品和包袋', + 'oauth.scope.todos:read.label': '查看待办清单', + 'oauth.scope.todos:read.description': '读取行程待办事项和分类负责人', + 'oauth.scope.todos:write.label': '管理待办清单', + 'oauth.scope.todos:write.description': + '创建、更新、勾选、删除和重新排列待办事项', + 'oauth.scope.budget:read.label': '查看预算', + 'oauth.scope.budget:read.description': '读取预算条目和费用明细', + 'oauth.scope.budget:write.label': '管理预算', + 'oauth.scope.budget:write.description': '创建、更新和删除预算条目', + 'oauth.scope.reservations:read.label': '查看预订', + 'oauth.scope.reservations:read.description': '读取预订和住宿详情', + 'oauth.scope.reservations:write.label': '管理预订', + 'oauth.scope.reservations:write.description': + '创建、更新、删除和重新排列预订', + 'oauth.scope.collab:read.label': '查看协作', + 'oauth.scope.collab:read.description': '读取协作笔记、投票和消息', + 'oauth.scope.collab:write.label': '管理协作', + 'oauth.scope.collab:write.description': + '创建、更新和删除协作笔记、投票和消息', + 'oauth.scope.notifications:read.label': '查看通知', + 'oauth.scope.notifications:read.description': '读取应用内通知和未读数量', + 'oauth.scope.notifications:write.label': '管理通知', + 'oauth.scope.notifications:write.description': '将通知标记为已读并回复', + 'oauth.scope.vacay:read.label': '查看假期计划', + 'oauth.scope.vacay:read.description': '读取假期计划数据、条目和统计', + 'oauth.scope.vacay:write.label': '管理假期计划', + 'oauth.scope.vacay:write.description': '创建和管理假期条目、节假日和团队计划', + 'oauth.scope.geo:read.label': '地图和地理编码', + 'oauth.scope.geo:read.description': + '搜索位置、解析地图 URL 和反向地理编码坐标', + 'oauth.scope.weather:read.label': '天气预报', + 'oauth.scope.weather:read.description': '获取行程地点和日期的天气预报', + 'oauth.scope.journey:read.label': '查看旅程', + 'oauth.scope.journey:read.description': '读取旅程、条目和贡献者列表', + 'oauth.scope.journey:write.label': '管理旅程', + 'oauth.scope.journey:write.description': '创建、更新和删除旅程及其条目', + 'oauth.scope.journey:share.label': '管理旅程链接', + 'oauth.scope.journey:share.description': '创建、更新和撤销旅程的公开分享链接', + 'oauth.authorize.authorizing': 'Authorizing…', // en-fallback + 'oauth.authorize.loading': 'Loading…', // en-fallback + 'oauth.authorize.errorTitle': 'Authorization Error', // en-fallback + 'oauth.authorize.loginTitle': 'Sign in to continue', // en-fallback + 'oauth.authorize.loginDescription': + '{client} wants access to your TREK account. Please sign in first.', // en-fallback + 'oauth.authorize.loginButton': 'Sign in to TREK', // en-fallback + 'oauth.authorize.requestLabel': 'Authorization Request', // en-fallback + 'oauth.authorize.requestDescription': + 'This application is requesting access to your TREK account.', // en-fallback + 'oauth.authorize.trustNote': + 'Only grant access to applications you trust. Your data stays on your server.', // en-fallback + 'oauth.authorize.selectScope': 'Select at least one scope', // en-fallback + 'oauth.authorize.approveOneScope': 'Approve ({count} scope)', // en-fallback + 'oauth.authorize.approveManyScopes': 'Approve ({count} scopes)', // en-fallback + 'oauth.authorize.approveAccess': 'Approve Access', // en-fallback + 'oauth.authorize.deny': 'Deny', // en-fallback + 'oauth.authorize.choosePermissions': 'Choose which permissions to grant', // en-fallback + 'oauth.authorize.permissionsRequested': 'Permissions requested', // en-fallback + 'oauth.authorize.alwaysIncluded': 'Always included', // en-fallback + 'oauth.authorize.alwaysTool.listTrips': + 'List your trips so the AI can discover trip IDs', // en-fallback + 'oauth.authorize.alwaysTool.getTripSummary': + 'Read a trip overview needed to use any other tool', // en-fallback +}; +export default oauth; diff --git a/shared/src/i18n/zh/packing.ts b/shared/src/i18n/zh/packing.ts new file mode 100644 index 0000000000000000000000000000000000000000..88b441602b79b692069fc03aee0cb2b9b2cfa18b --- /dev/null +++ b/shared/src/i18n/zh/packing.ts @@ -0,0 +1,183 @@ +import type { TranslationStrings } from '../types'; + +const packing: TranslationStrings = { + 'packing.title': '行李清单', + 'packing.empty': '行李清单为空', + 'packing.import': '导入', + 'packing.importTitle': '导入装箱清单', + 'packing.importHint': + '每行一个物品。可选用逗号、分号或制表符分隔类别和数量:名称, 类别, 数量', + 'packing.importPlaceholder': '牙刷\n防晒霜, 卫生\nT恤, 衣物, 5\n护照, 证件', + 'packing.importCsv': '加载 CSV/TXT', + 'packing.importAction': '导入 {count}', + 'packing.importSuccess': '已导入 {count} 项', + 'packing.importError': '导入失败', + 'packing.importEmpty': '没有可导入的项目', + 'packing.progress': '已打包 {packed}/{total}({percent}%)', + 'packing.clearChecked': '移除 {count} 个已勾选', + 'packing.clearCheckedShort': '移除 {count} 个', + 'packing.suggestions': '建议', + 'packing.suggestionsTitle': '添加建议', + 'packing.allSuggested': '所有建议已添加', + 'packing.allPacked': '全部打包完成!', + 'packing.addPlaceholder': '添加新物品...', + 'packing.categoryPlaceholder': '分类...', + 'packing.filterAll': '全部', + 'packing.filterOpen': '未完成', + 'packing.filterDone': '已完成', + 'packing.emptyTitle': '行李清单为空', + 'packing.emptyHint': '添加物品或使用建议', + 'packing.emptyFiltered': '没有匹配的物品', + 'packing.menuRename': '重命名', + 'packing.menuCheckAll': '全部勾选', + 'packing.menuUncheckAll': '取消全部勾选', + 'packing.menuDeleteCat': '删除分类', + 'packing.addItem': '添加物品', + 'packing.addItemPlaceholder': '物品名称...', + 'packing.addCategory': '添加分类', + 'packing.newCategoryPlaceholder': '分类名称(如:衣物)', + 'packing.applyTemplate': '应用模板', + 'packing.template': '模板', + 'packing.templateApplied': '已从模板添加 {count} 个物品', + 'packing.templateError': '应用模板失败', + 'packing.saveAsTemplate': '保存为模板', + 'packing.templateName': '模板名称', + 'packing.templateSaved': '行李清单已保存为模板', + 'packing.noMembers': '无成员', + 'packing.bags': '行李', + 'packing.noBag': '未分配', + 'packing.totalWeight': '总重量', + 'packing.bagName': '名称...', + 'packing.addBag': '添加行李', + 'packing.changeCategory': '更改分类', + 'packing.confirm.clearChecked': '确定移除 {count} 个已勾选的物品?', + 'packing.confirm.deleteCat': '确定删除分类「{name}」及其 {count} 个物品?', + 'packing.defaultCategory': '其他', + 'packing.toast.saveError': '保存失败', + 'packing.toast.deleteError': '删除失败', + 'packing.toast.renameError': '重命名失败', + 'packing.toast.addError': '添加失败', + 'packing.suggestions.items': [ + { + name: '护照', + category: '证件', + }, + { + name: '身份证', + category: '证件', + }, + { + name: '旅行保险', + category: '证件', + }, + { + name: '机票', + category: '证件', + }, + { + name: '信用卡', + category: '财务', + }, + { + name: '现金', + category: '财务', + }, + { + name: '签证', + category: '证件', + }, + { + name: 'T恤', + category: '衣物', + }, + { + name: '裤子', + category: '衣物', + }, + { + name: '内衣', + category: '衣物', + }, + { + name: '袜子', + category: '衣物', + }, + { + name: '外套', + category: '衣物', + }, + { + name: '睡衣', + category: '衣物', + }, + { + name: '泳衣', + category: '衣物', + }, + { + name: '雨衣', + category: '衣物', + }, + { + name: '舒适的鞋子', + category: '衣物', + }, + { + name: '牙刷', + category: '洗漱用品', + }, + { + name: '牙膏', + category: '洗漱用品', + }, + { + name: '洗发水', + category: '洗漱用品', + }, + { + name: '除臭剂', + category: '洗漱用品', + }, + { + name: '防晒霜', + category: '洗漱用品', + }, + { + name: '剃须刀', + category: '洗漱用品', + }, + { + name: '充电器', + category: '电子产品', + }, + { + name: '充电宝', + category: '电子产品', + }, + { + name: '耳机', + category: '电子产品', + }, + { + name: '旅行转换插头', + category: '电子产品', + }, + { + name: '相机', + category: '电子产品', + }, + { + name: '止痛药', + category: '健康', + }, + { + name: '创可贴', + category: '健康', + }, + { + name: '消毒液', + category: '健康', + }, + ], +}; +export default packing; diff --git a/shared/src/i18n/zh/pdf.ts b/shared/src/i18n/zh/pdf.ts new file mode 100644 index 0000000000000000000000000000000000000000..2eb2e11cf3696a0b9b2c0ee40e2bad6189f56b0e --- /dev/null +++ b/shared/src/i18n/zh/pdf.ts @@ -0,0 +1,10 @@ +import type { TranslationStrings } from '../types'; + +const pdf: TranslationStrings = { + 'pdf.travelPlan': '旅行计划', + 'pdf.planned': '已规划', + 'pdf.costLabel': '费用 EUR', + 'pdf.preview': 'PDF 预览', + 'pdf.saveAsPdf': '保存为 PDF', +}; +export default pdf; diff --git a/shared/src/i18n/zh/perm.ts b/shared/src/i18n/zh/perm.ts new file mode 100644 index 0000000000000000000000000000000000000000..1df2b6c07d0b332121b5e6e89abaf21658a844ad --- /dev/null +++ b/shared/src/i18n/zh/perm.ts @@ -0,0 +1,51 @@ +import type { TranslationStrings } from '../types'; + +const perm: TranslationStrings = { + 'perm.title': '权限设置', + 'perm.subtitle': '控制谁可以在应用中执行操作', + 'perm.saved': '权限设置已保存', + 'perm.resetDefaults': '恢复默认', + 'perm.customized': '已自定义', + 'perm.level.admin': '仅管理员', + 'perm.level.tripOwner': '旅行所有者', + 'perm.level.tripMember': '旅行成员', + 'perm.level.everybody': '所有人', + 'perm.cat.trip': '旅行管理', + 'perm.cat.members': '成员管理', + 'perm.cat.files': '文件', + 'perm.cat.content': '内容与日程', + 'perm.cat.extras': '预算、行李与协作', + 'perm.action.trip_create': '创建旅行', + 'perm.action.trip_edit': '编辑旅行详情', + 'perm.action.trip_delete': '删除旅行', + 'perm.action.trip_archive': '归档 / 取消归档旅行', + 'perm.action.trip_cover_upload': '上传封面图片', + 'perm.action.member_manage': '添加 / 移除成员', + 'perm.action.file_upload': '上传文件', + 'perm.action.file_edit': '编辑文件元数据', + 'perm.action.file_delete': '删除文件', + 'perm.action.place_edit': '添加 / 编辑 / 删除地点', + 'perm.action.day_edit': '编辑日程、备注与分配', + 'perm.action.reservation_edit': '管理预订', + 'perm.action.budget_edit': '管理预算', + 'perm.action.packing_edit': '管理行李清单', + 'perm.action.collab_edit': '协作(笔记、投票、聊天)', + 'perm.action.share_manage': '管理分享链接', + 'perm.actionHint.trip_create': '谁可以创建新旅行', + 'perm.actionHint.trip_edit': '谁可以更改旅行名称、日期、描述和货币', + 'perm.actionHint.trip_delete': '谁可以永久删除旅行', + 'perm.actionHint.trip_archive': '谁可以归档或取消归档旅行', + 'perm.actionHint.trip_cover_upload': '谁可以上传或更改封面图片', + 'perm.actionHint.member_manage': '谁可以邀请或移除旅行成员', + 'perm.actionHint.file_upload': '谁可以向旅行上传文件', + 'perm.actionHint.file_edit': '谁可以编辑文件描述和链接', + 'perm.actionHint.file_delete': '谁可以将文件移至回收站或永久删除', + 'perm.actionHint.place_edit': '谁可以添加、编辑或删除地点', + 'perm.actionHint.day_edit': '谁可以编辑日程、日程备注和地点分配', + 'perm.actionHint.reservation_edit': '谁可以创建、编辑或删除预订', + 'perm.actionHint.budget_edit': '谁可以创建、编辑或删除预算项目', + 'perm.actionHint.packing_edit': '谁可以管理行李物品和包袋', + 'perm.actionHint.collab_edit': '谁可以创建笔记、投票和发送消息', + 'perm.actionHint.share_manage': '谁可以创建或删除公开分享链接', +}; +export default perm; diff --git a/shared/src/i18n/zh/photos.ts b/shared/src/i18n/zh/photos.ts new file mode 100644 index 0000000000000000000000000000000000000000..ee8e4751e06665e0f56faed5826419f85646d640 --- /dev/null +++ b/shared/src/i18n/zh/photos.ts @@ -0,0 +1,25 @@ +import type { TranslationStrings } from '../types'; + +const photos: TranslationStrings = { + 'photos.title': '照片', + 'photos.subtitle': '{trip} 的 {count} 张照片', + 'photos.dropHere': '将照片拖放至此...', + 'photos.dropHereActive': '将照片拖放至此', + 'photos.captionForAll': '标题(所有)', + 'photos.captionPlaceholder': '可选标题...', + 'photos.addCaption': '添加标题...', + 'photos.allDays': '所有天', + 'photos.noPhotos': '暂无照片', + 'photos.uploadHint': '上传你的旅行照片', + 'photos.clickToSelect': '或点击选择', + 'photos.linkPlace': '关联地点', + 'photos.noPlace': '无地点', + 'photos.uploadN': '上传 {n} 张照片', + 'photos.linkDay': '关联天数', + 'photos.noDay': '无天数', + 'photos.dayLabel': '第 {number} 天', + 'photos.photoSelected': '张照片已选择', + 'photos.photosSelected': '张照片已选择', + 'photos.fileTypeHint': 'JPG, PNG, WebP · 最大 10 MB · 最多 30 张照片', +}; +export default photos; diff --git a/shared/src/i18n/zh/places.ts b/shared/src/i18n/zh/places.ts new file mode 100644 index 0000000000000000000000000000000000000000..724b9afa15728cb6cecefe43134c0e95c6487b9f --- /dev/null +++ b/shared/src/i18n/zh/places.ts @@ -0,0 +1,92 @@ +import type { TranslationStrings } from '../types'; + +const places: TranslationStrings = { + 'places.addPlace': '添加地点/活动', + 'places.importFile': '导入文件', + 'places.sidebarDrop': '拖放以导入', + 'places.importFileHint': + '从 Google My Maps、Google Earth 或 GPS 追踪器等工具导入 .gpx、.kml 或 .kmz 文件。', + 'places.importFileDropHere': '点击选择文件或拖放到此处', + 'places.importFileDropActive': '释放文件以选择', + 'places.importFileUnsupported': + '不支持的文件类型,请使用 .gpx、.kml 或 .kmz。', + 'places.importFileTooLarge': '文件过大。最大上传大小为 {maxMb} MB。', + 'places.importFileError': '导入失败', + 'places.importAllSkipped': '所有地点已在行程中。', + 'places.gpxImported': '已从 GPX 导入 {count} 个地点', + 'places.gpxImportTypes': '要导入什么?', + 'places.gpxImportWaypoints': '路点', + 'places.gpxImportRoutes': '路线', + 'places.gpxImportTracks': '轨迹(含路径几何)', + 'places.gpxImportNoneSelected': '请至少选择一种导入类型。', + 'places.kmlImportTypes': '要导入什么?', + 'places.kmlImportPoints': '点(Placemarks)', + 'places.kmlImportPaths': '路径(LineStrings)', + 'places.kmlImportNoneSelected': '请至少选择一种类型。', + 'places.selectionCount': '已选 {count} 项', + 'places.deleteSelected': '删除所选', + 'places.kmlKmzImported': '已从 KMZ/KML 导入 {count} 个地点', + 'places.urlResolved': '已从 URL 导入地点', + 'places.importList': '列表导入', + 'places.kmlKmzSummaryValues': + 'Placemarks:{total} • 已导入:{created} • 已跳过:{skipped}', + 'places.importGoogleList': 'Google 列表', + 'places.importNaverList': 'Naver 列表', + 'places.googleListHint': '粘贴共享的 Google Maps 列表链接以导入所有地点。', + 'places.googleListImported': '已从"{list}"导入 {count} 个地点', + 'places.googleListError': 'Google Maps 列表导入失败', + 'places.naverListHint': '粘贴共享的 Naver Maps 列表链接以导入所有地点。', + 'places.naverListImported': '已从"{list}"导入 {count} 个地点', + 'places.naverListError': 'Naver Maps 列表导入失败', + 'places.viewDetails': '查看详情', + 'places.assignToDay': '添加到哪一天?', + 'places.all': '全部', + 'places.unplanned': '未规划', + 'places.filterTracks': '路线', + 'places.search': '搜索地点...', + 'places.allCategories': '所有分类', + 'places.categoriesSelected': '个分类', + 'places.clearFilter': '清除筛选', + 'places.count': '{count} 个地点', + 'places.countSingular': '1 个地点', + 'places.allPlanned': '所有地点已规划', + 'places.noneFound': '未找到地点', + 'places.editPlace': '编辑地点', + 'places.formName': '名称', + 'places.formNamePlaceholder': '如:埃菲尔铁塔', + 'places.formDescription': '描述', + 'places.formDescriptionPlaceholder': '简短描述...', + 'places.formAddress': '地址', + 'places.formAddressPlaceholder': '街道、城市、国家', + 'places.formLat': '纬度(如 48.8566)', + 'places.formLng': '经度(如 2.3522)', + 'places.formCategory': '分类', + 'places.noCategory': '无分类', + 'places.categoryNamePlaceholder': '分类名称', + 'places.formTime': '时间', + 'places.startTime': '开始', + 'places.endTime': '结束', + 'places.endTimeBeforeStart': '结束时间早于开始时间', + 'places.timeCollision': '时间冲突:', + 'places.formWebsite': '网站', + 'places.formNotes': '备注', + 'places.formNotesPlaceholder': '个人备注...', + 'places.formReservation': '预订', + 'places.reservationNotesPlaceholder': '预订备注、确认号...', + 'places.mapsSearchPlaceholder': '搜索地点...', + 'places.mapsSearchError': '地点搜索失败。', + 'places.loadingDetails': '正在加载地点详情…', + 'places.osmHint': + '使用 OpenStreetMap 搜索(无照片、营业时间或评分)。在设置中添加 Google API 密钥以获取完整信息。', + 'places.osmActive': + '通过 OpenStreetMap 搜索(无照片、评分或营业时间)。在设置中添加 Google API 密钥以获取增强数据。', + 'places.categoryCreateError': '创建分类失败', + 'places.nameRequired': '请输入名称', + 'places.saveError': '保存失败', + 'places.duplicateExists': "'{name}' 已在此行程中。", + 'places.addAnyway': '仍然添加', + 'places.enrichOnImport': '通过 Google 丰富地点信息', + 'places.enrichOnImportHint': + '查找每个导入的地点以补充照片、地址和联系方式。需要 Google Maps 密钥。', +}; +export default places; diff --git a/shared/src/i18n/zh/planner.ts b/shared/src/i18n/zh/planner.ts new file mode 100644 index 0000000000000000000000000000000000000000..3722b1de21ba4ff6bb6a9b933fb0e7bf7515cdf7 --- /dev/null +++ b/shared/src/i18n/zh/planner.ts @@ -0,0 +1,67 @@ +import type { TranslationStrings } from '../types'; + +const planner: TranslationStrings = { + 'planner.places': '地点', + 'planner.bookings': '预订', + 'planner.packingList': '行李清单', + 'planner.documents': '文档', + 'planner.dayPlan': '日程计划', + 'planner.reservations': '预订', + 'planner.minTwoPlaces': '至少需要 2 个有坐标的地点', + 'planner.noGeoPlaces': '没有有坐标的地点', + 'planner.routeCalculated': '路线已计算', + 'planner.routeCalcFailed': '无法计算路线', + 'planner.routeError': '路线计算错误', + 'planner.icsExportFailed': 'ICS 导出失败', + 'planner.routeOptimized': '路线已优化', + 'planner.reservationUpdated': '预订已更新', + 'planner.reservationAdded': '预订已添加', + 'planner.confirmDeleteReservation': '删除预订?', + 'planner.reservationDeleted': '预订已删除', + 'planner.days': '天', + 'planner.allPlaces': '所有地点', + 'planner.totalPlaces': '共 {n} 个地点', + 'planner.noDaysPlanned': '尚未规划天数', + 'planner.editTrip': '编辑旅行 →', + 'planner.placeOne': '1 个地点', + 'planner.placeN': '{n} 个地点', + 'planner.addNote': '添加备注', + 'planner.noEntries': '当天无条目', + 'planner.addPlace': '添加地点/活动', + 'planner.addPlaceShort': '+ 添加地点/活动', + 'planner.resPending': '预订待确认 · ', + 'planner.resConfirmed': '预订已确认 · ', + 'planner.notePlaceholder': '备注…', + 'planner.noteTimePlaceholder': '时间(可选)', + 'planner.noteExamplePlaceholder': + '如:14:30 从中央车站乘 S3,7 号码头渡轮,午餐休息…', + 'planner.totalCost': '总费用', + 'planner.searchPlaces': '搜索地点…', + 'planner.allCategories': '所有分类', + 'planner.noPlacesFound': '未找到地点', + 'planner.addFirstPlace': '添加第一个地点', + 'planner.noReservations': '暂无预订', + 'planner.addFirstReservation': '添加第一个预订', + 'planner.new': '新建', + 'planner.addToDay': '+ 天', + 'planner.calculating': '计算中…', + 'planner.route': '路线', + 'planner.optimize': '优化', + 'planner.openGoogleMaps': '在 Google Maps 中打开', + 'planner.selectDayHint': '从左侧列表选择一天以查看日程计划', + 'planner.noPlacesForDay': '当天暂无地点', + 'planner.addPlacesLink': '添加地点 →', + 'planner.minTotal': '分钟 合计', + 'planner.noReservation': '无预订', + 'planner.removeFromDay': '从当天移除', + 'planner.addToThisDay': '添加到当天', + 'planner.overview': '概览', + 'planner.noDays': '暂无天数', + 'planner.editTripToAddDays': '编辑旅行以添加天数', + 'planner.dayCount': '{n} 天', + 'planner.clickToUnlock': '点击解锁', + 'planner.keepPosition': '路线优化时保持位置', + 'planner.dayDetails': '日程详情', + 'planner.dayN': '第 {n} 天', +}; +export default planner; diff --git a/shared/src/i18n/zh/register.ts b/shared/src/i18n/zh/register.ts new file mode 100644 index 0000000000000000000000000000000000000000..e7c74448e5102ea06b7eb8c7aa5b7cfbe1bc334a --- /dev/null +++ b/shared/src/i18n/zh/register.ts @@ -0,0 +1,25 @@ +import type { TranslationStrings } from '../types'; + +const register: TranslationStrings = { + 'register.passwordMismatch': '两次输入的密码不一致', + 'register.passwordTooShort': '密码至少需要 8 个字符', + 'register.failed': '注册失败', + 'register.getStarted': '开始使用', + 'register.subtitle': '创建账户,开始规划你的梦想旅行。', + 'register.feature1': '无限旅行计划', + 'register.feature2': '互动地图视图', + 'register.feature3': '管理地点和分类', + 'register.feature4': '跟踪预订', + 'register.feature5': '创建行李清单', + 'register.feature6': '存储照片和文件', + 'register.createAccount': '创建账户', + 'register.startPlanning': '开始规划你的旅行', + 'register.minChars': '至少 6 个字符', + 'register.confirmPassword': '确认密码', + 'register.repeatPassword': '重复密码', + 'register.registering': '注册中...', + 'register.register': '注册', + 'register.hasAccount': '已有账户?', + 'register.signIn': '登录', +}; +export default register; diff --git a/shared/src/i18n/zh/reservations.ts b/shared/src/i18n/zh/reservations.ts new file mode 100644 index 0000000000000000000000000000000000000000..85b91a6417903f25a40525c84bb4760629d61281 --- /dev/null +++ b/shared/src/i18n/zh/reservations.ts @@ -0,0 +1,159 @@ +import type { TranslationStrings } from '../types'; + +const reservations: TranslationStrings = { + 'reservations.title': '预订', + 'reservations.empty': '暂无预订', + 'reservations.emptyHint': '添加航班、酒店等预订信息', + 'reservations.add': '添加预订', + 'reservations.addManual': '手动添加', + 'reservations.placeHint': + '提示:建议从地点直接创建预订,以便与日程计划关联。', + 'reservations.confirmed': '已确认', + 'reservations.pending': '待确认', + 'reservations.summary': '{confirmed} 已确认,{pending} 待确认', + 'reservations.fromPlan': '来自计划', + 'reservations.showFiles': '查看文件', + 'reservations.editTitle': '编辑预订', + 'reservations.status': '状态', + 'reservations.datetime': '日期和时间', + 'reservations.startTime': '开始时间', + 'reservations.endTime': '结束时间', + 'reservations.date': '日期', + 'reservations.time': '时间', + 'reservations.timeAlt': '时间(备选,如 19:30)', + 'reservations.notes': '备注', + 'reservations.notesPlaceholder': '其他备注...', + 'reservations.meta.airline': '航空公司', + 'reservations.meta.flightNumber': '航班号', + 'reservations.meta.from': '出发', + 'reservations.meta.to': '到达', + 'reservations.layover.route': '航线', + 'reservations.layover.stop': '经停', + 'reservations.layover.addStop': '添加经停', + 'reservations.layover.connection': '转机', + 'reservations.layover.layover': '中转停留', + 'reservations.needsReview': '待确认', + 'reservations.needsReviewHint': '无法自动匹配机场 — 请确认位置。', + 'reservations.searchLocation': '搜索车站、港口、地址...', + 'reservations.meta.trainNumber': '车次', + 'reservations.meta.platform': '站台', + 'reservations.meta.seat': '座位', + 'reservations.meta.checkIn': '入住', + 'reservations.meta.checkInUntil': '入住截止', + 'reservations.meta.checkOut': '退房', + 'reservations.meta.linkAccommodation': '住宿', + 'reservations.meta.pickAccommodation': '关联住宿', + 'reservations.meta.noAccommodation': '无', + 'reservations.meta.hotelPlace': '住宿', + 'reservations.meta.pickHotel': '选择住宿', + 'reservations.meta.fromDay': '从', + 'reservations.meta.toDay': '到', + 'reservations.meta.selectDay': '选择日期', + 'reservations.type.flight': '航班', + 'reservations.type.hotel': '住宿', + 'reservations.type.restaurant': '餐厅', + 'reservations.type.train': '火车', + 'reservations.type.car': '汽车', + 'reservations.type.cruise': '邮轮', + 'reservations.type.event': '活动', + 'reservations.type.tour': '旅游团', + 'reservations.type.other': '其他', + 'reservations.type.bus': '公交车', + 'reservations.type.ferry': '渡轮', + 'reservations.type.bicycle': '自行车', + 'reservations.type.taxi': '出租车', + 'reservations.type.transport_other': '其他', + 'reservations.confirm.delete': '确定要删除预订「{name}」吗?', + 'reservations.confirm.deleteTitle': '删除预订?', + 'reservations.confirm.deleteBody': '"{name}" 将被永久删除。', + 'reservations.toast.updated': '预订已更新', + 'reservations.toast.removed': '预订已删除', + 'reservations.toast.fileUploaded': '文件已上传', + 'reservations.toast.uploadError': '上传失败', + 'reservations.newTitle': '新建预订', + 'reservations.bookingType': '预订类型', + 'reservations.titleLabel': '标题', + 'reservations.titlePlaceholder': '如:汉莎 LH123、阿德隆酒店...', + 'reservations.locationAddress': '地点 / 地址', + 'reservations.locationPlaceholder': '地址、机场、酒店...', + 'reservations.confirmationCode': '预订码', + 'reservations.confirmationPlaceholder': '如:ABC12345', + 'reservations.day': '日期', + 'reservations.noDay': '无日期', + 'reservations.place': '地点', + 'reservations.noPlace': '无地点', + 'reservations.pendingSave': '将被保存…', + 'reservations.uploading': '上传中...', + 'reservations.attachFile': '附加文件', + 'reservations.linkExisting': '关联已有文件', + 'reservations.toast.saveError': '保存失败', + 'reservations.toast.updateError': '更新失败', + 'reservations.toast.deleteError': '删除失败', + 'reservations.confirm.remove': '移除「{name}」的预订?', + 'reservations.linkAssignment': '关联日程分配', + 'reservations.pickAssignment': '从计划中选择一个分配...', + 'reservations.noAssignment': '无关联(独立)', + 'reservations.price': '价格', + 'reservations.budgetCategory': '预算类别', + 'reservations.budgetCategoryPlaceholder': '例:交通、住宿', + 'reservations.budgetCategoryAuto': '自动(按预订类型)', + 'reservations.budgetHint': '保存时将自动创建预算条目。', + 'reservations.departureDate': '出发', + 'reservations.arrivalDate': '到达', + 'reservations.departureTime': '出发时间', + 'reservations.arrivalTime': '到达时间', + 'reservations.pickupDate': '取车', + 'reservations.returnDate': '还车', + 'reservations.pickupTime': '取车时间', + 'reservations.returnTime': '还车时间', + 'reservations.endDate': '结束日期', + 'reservations.meta.departureTimezone': '出发时区', + 'reservations.meta.arrivalTimezone': '到达时区', + 'reservations.span.departure': '出发', + 'reservations.span.arrival': '到达', + 'reservations.span.inTransit': '途中', + 'reservations.span.pickup': '取车', + 'reservations.span.return': '还车', + 'reservations.span.active': '使用中', + 'reservations.span.start': '开始', + 'reservations.span.end': '结束', + 'reservations.span.ongoing': '进行中', + 'reservations.validation.endBeforeStart': + '结束日期/时间必须晚于开始日期/时间', + 'reservations.addBooking': '添加预订', + 'reservations.import.title': '导入预订确认', + 'reservations.import.cta': '从文件导入', + 'reservations.import.dropHere': '将预订确认文件拖放到此处,或点击选择', + 'reservations.import.dropActive': '松开文件以导入', + 'reservations.import.acceptedFormats': '支持格式:EML、PDF、PKPass、HTML、TXT(每个最大 10 MB,最多 5 个文件)', + 'reservations.import.parsing': '正在解析文件…', + 'reservations.import.previewHeading': '找到 {count} 个预订', + 'reservations.import.previewEmpty': '无法从上传的文件中提取任何预订信息。', + 'reservations.import.removeItem': '移除', + 'reservations.import.confirm': '导入 {count} 个预订', + 'reservations.import.back': '返回', + 'reservations.import.success': '已导入 {count} 个预订', + 'reservations.import.partialFailure': '已导入 {created} 个,{failed} 个失败', + 'reservations.import.error': '解析失败。请确保文件是有效的预订确认。', + 'reservations.import.unavailable': '此服务器上的预订导入功能不可用。', + 'reservations.import.unsupportedFormat': '不支持的文件格式。请使用 EML、PDF、PKPass、HTML 或 TXT。', + 'reservations.import.fileTooLarge': '文件"{name}"超过 10 MB 限制。', + 'reservations.airtrail.title': '从 AirTrail 导入', + 'reservations.airtrail.cta': 'AirTrail', + 'reservations.airtrail.synced': 'AirTrail', + 'reservations.airtrail.syncedHint': '已从 AirTrail 同步——编辑会双向保持同步。', + 'reservations.airtrail.notSynced': '未同步', + 'reservations.airtrail.notSyncedHint': '此航班已在 AirTrail 中删除,不再同步。', + 'reservations.airtrail.loadError': '无法加载您的 AirTrail 航班。', + 'reservations.airtrail.imported': '已导入 {count} 个航班', + 'reservations.airtrail.skippedDuplicate': '{count} 个已在此行程中,已跳过', + 'reservations.airtrail.nothingImported': '没有可导入的内容。', + 'reservations.airtrail.importError': '导入失败。请重试。', + 'reservations.airtrail.undo': '从 AirTrail 导入', + 'reservations.airtrail.alreadyImported': '已导入', + 'reservations.airtrail.duringTrip': '行程期间', + 'reservations.airtrail.otherFlights': '其他航班', + 'reservations.airtrail.empty': '您的 AirTrail 账户中未找到航班。', + 'reservations.airtrail.importCta': '导入 {count}', +}; +export default reservations; diff --git a/shared/src/i18n/zh/settings.ts b/shared/src/i18n/zh/settings.ts new file mode 100644 index 0000000000000000000000000000000000000000..0729c9162ed862a4ef6512d64bbb1db2abe16313 --- /dev/null +++ b/shared/src/i18n/zh/settings.ts @@ -0,0 +1,330 @@ +import type { TranslationStrings } from '../types'; + +const settings: TranslationStrings = { + 'settings.title': '设置', + 'settings.subtitle': '配置你的个人设置', + 'settings.tabs.display': '显示', + 'settings.tabs.map': '地图', + 'settings.tabs.notifications': '通知', + 'settings.tabs.integrations': '集成', + 'settings.tabs.account': '账户', + 'settings.tabs.offline': 'Offline', + 'settings.tabs.about': '关于', + 'settings.map': '地图', + 'settings.mapTemplate': '地图模板', + 'settings.mapTemplatePlaceholder.select': '选择模板...', + 'settings.mapDefaultHint': '留空则使用 OpenStreetMap(默认)', + 'settings.mapTemplatePlaceholder': + 'https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', + 'settings.mapHint': '地图瓦片 URL 模板', + 'settings.mapProvider': '地图提供商', + 'settings.mapProviderHint': + '影响行程规划和旅程地图。Atlas 始终使用 Leaflet。', + 'settings.mapLeafletSubtitle': '经典 2D,任何栅格瓦片', + 'settings.mapMapboxSubtitle': '矢量瓦片、3D 建筑和地形', + 'settings.mapExperimental': '实验性', + 'settings.mapMapboxToken': 'Mapbox 访问令牌', + 'settings.mapMapboxTokenHint': '公共令牌 (pk.*) 来自', + 'settings.mapMapboxTokenLink': 'mapbox.com → 访问令牌', + 'settings.mapStyle': '地图样式', + 'settings.mapStylePlaceholder': '选择 Mapbox 样式', + 'settings.mapStyleHint': '预设或您自己的 mapbox://styles/USER/ID URL', + 'settings.map3dBuildings': '3D 建筑和地形', + 'settings.map3dHint': '倾斜 + 真实 3D 建筑拉伸 — 适用于所有样式,包括卫星。', + 'settings.mapHighQuality': '高画质模式', + 'settings.mapHighQualityHint': + '抗锯齿 + 地球投影,带来更清晰的边缘和更真实的世界视图。', + 'settings.mapHighQualityWarning': '可能影响低端设备的性能。', + 'settings.mapTipLabel': '提示:', + 'settings.mapTip': + '右键点击并拖动以旋转/倾斜地图。中键点击添加地点(右键用于旋转)。', + 'settings.latitude': '纬度', + 'settings.longitude': '经度', + 'settings.saveMap': '保存地图', + 'settings.apiKeys': 'API 密钥', + 'settings.mapsKey': 'Google Maps API 密钥', + 'settings.mapsKeyHint': + '用于地点搜索。需要 Places API (New)。在 console.cloud.google.com 获取', + 'settings.weatherKey': 'OpenWeatherMap API 密钥', + 'settings.weatherKeyHint': '用于天气数据。在 openweathermap.org/api 免费获取', + 'settings.keyPlaceholder': '输入密钥...', + 'settings.configured': '已配置', + 'settings.saveKeys': '保存密钥', + 'settings.display': '显示', + 'settings.colorMode': '颜色模式', + 'settings.light': '浅色', + 'settings.dark': '深色', + 'settings.auto': '自动', + 'settings.language': '语言', + 'settings.temperature': '温度单位', + 'settings.timeFormat': '时间格式', + 'settings.blurBookingCodes': '模糊预订代码', + 'settings.optimizeFromAccommodation': '从住宿地优化路线', + 'settings.optimizeFromAccommodationHint': + '优化某一天时,路线将从您醒来时所在的酒店出发,并在当晚入住的酒店结束。', + 'settings.notifications': '通知', + 'settings.notifyTripInvite': '旅行邀请', + 'settings.notifyBookingChange': '预订变更', + 'settings.notifyTripReminder': '旅行提醒', + 'settings.notifyTodoDue': '待办事项即将到期', + 'settings.notifyVacayInvite': 'Vacay 融合邀请', + 'settings.notifyPhotosShared': '共享照片 (Immich)', + 'settings.notifyCollabMessage': '聊天消息 (Collab)', + 'settings.notifyPackingTagged': '行李清单:分配', + 'settings.notifyWebhook': 'Webhook 通知', + 'settings.notificationsDisabled': + '通知尚未配置。请联系管理员启用电子邮件或 Webhook 通知。', + 'settings.notificationsActive': '活跃频道', + 'settings.notificationsManagedByAdmin': '通知事件由管理员配置。', + 'settings.on': '开', + 'settings.off': '关', + 'settings.mcp.title': 'MCP 配置', + 'settings.mcp.endpoint': 'MCP 端点', + 'settings.mcp.clientConfig': '客户端配置', + 'settings.mcp.clientConfigHint': + '将 替换为下方列表中的 API 令牌。npx 的路径可能需要根据您的系统进行调整(例如 Windows 上为 C:\\PROGRA~1\\nodejs\\npx.cmd)。', + 'settings.mcp.clientConfigHintOAuth': + '将 和 替换为上方创建的 OAuth 2.1 客户端凭据。首次连接时,mcp-remote 将打开浏览器完成授权。npx 的路径可能需要根据您的系统进行调整(例如 Windows 上为 C:\\PROGRA~1\\nodejs\\npx.cmd)。', + 'settings.mcp.copy': '复制', + 'settings.mcp.copied': '已复制!', + 'settings.mcp.apiTokens': 'API 令牌', + 'settings.mcp.createToken': '创建新令牌', + 'settings.mcp.noTokens': '暂无令牌,请创建一个以连接 MCP 客户端。', + 'settings.mcp.tokenCreatedAt': '创建于', + 'settings.mcp.tokenUsedAt': '使用于', + 'settings.mcp.deleteTokenTitle': '删除令牌', + 'settings.mcp.deleteTokenMessage': + '此令牌将立即失效,使用它的所有 MCP 客户端将失去访问权限。', + 'settings.mcp.modal.createTitle': '创建 API 令牌', + 'settings.mcp.modal.tokenName': '令牌名称', + 'settings.mcp.modal.tokenNamePlaceholder': '例如:Claude Desktop、工作电脑', + 'settings.mcp.modal.creating': '创建中…', + 'settings.mcp.modal.create': '创建令牌', + 'settings.mcp.modal.createdTitle': '令牌已创建', + 'settings.mcp.modal.createdWarning': + '此令牌只会显示一次,请立即复制并妥善保存——无法找回。', + 'settings.mcp.modal.done': '完成', + 'settings.mcp.toast.created': '令牌已创建', + 'settings.mcp.toast.createError': '创建令牌失败', + 'settings.mcp.toast.deleted': '令牌已删除', + 'settings.mcp.toast.deleteError': '删除令牌失败', + 'settings.mcp.apiTokensDeprecated': + 'API 令牌已弃用,将在未来版本中移除。请改用 OAuth 2.1 客户端。', + 'settings.oauth.clients': 'OAuth 2.1 客户端', + 'settings.oauth.clientsHint': + '注册 OAuth 2.1 客户端,让第三方 MCP 应用程序(Claude Web、Cursor 等)无需静态令牌即可连接。', + 'settings.oauth.createClient': '新建客户端', + 'settings.oauth.noClients': '没有已注册的 OAuth 客户端。', + 'settings.oauth.clientId': '客户端 ID', + 'settings.oauth.clientSecret': '客户端密钥', + 'settings.oauth.deleteClient': '删除客户端', + 'settings.oauth.deleteClientMessage': + '此客户端及所有活跃会话将被永久删除。使用此客户端的任何应用程序将立即失去访问权限。', + 'settings.oauth.rotateSecret': '轮换密钥', + 'settings.oauth.rotateSecretMessage': + '将生成新的客户端密钥,所有现有会话将立即失效。在关闭此对话框之前,请更新您的应用程序。', + 'settings.oauth.rotateSecretConfirm': '轮换', + 'settings.oauth.rotateSecretConfirming': '轮换中…', + 'settings.oauth.rotateSecretDoneTitle': '已生成新密钥', + 'settings.oauth.rotateSecretDoneWarning': + '此密钥仅显示一次。请立即复制并更新您的应用程序——所有之前的会话已失效。', + 'settings.oauth.activeSessions': '活跃的 OAuth 会话', + 'settings.oauth.sessionScopes': '权限范围', + 'settings.oauth.sessionExpires': '过期时间', + 'settings.oauth.revoke': '撤销', + 'settings.oauth.revokeSession': '撤销会话', + 'settings.oauth.revokeSessionMessage': + '这将立即撤销此 OAuth 会话的访问权限。', + 'settings.oauth.modal.createTitle': '注册 OAuth 客户端', + 'settings.oauth.modal.presets': '快速预设', + 'settings.oauth.modal.clientName': '应用程序名称', + 'settings.oauth.modal.clientNamePlaceholder': + '例如 Claude Web、我的 MCP 应用', + 'settings.oauth.modal.redirectUris': '重定向 URI', + 'settings.oauth.modal.redirectUrisPlaceholder': + 'https://your-app.com/callback\nhttps://your-app.com/auth', + 'settings.oauth.modal.redirectUrisHint': + '每行一个 URI。需要 HTTPS(localhost 除外)。要求精确匹配。', + 'settings.oauth.modal.scopes': '允许的权限范围', + 'settings.oauth.modal.scopesHint': + 'list_trips 和 get_trip_summary 始终可用——无需权限范围。它们帮助 AI 发现所需的行程 ID。', + 'settings.oauth.modal.selectAll': '全选', + 'settings.oauth.modal.deselectAll': '取消全选', + 'settings.oauth.modal.creating': '注册中…', + 'settings.oauth.modal.create': '注册客户端', + 'settings.oauth.modal.createdTitle': '客户端已注册', + 'settings.oauth.modal.createdWarning': + '客户端密钥仅显示一次。请立即复制——无法恢复。', + 'settings.oauth.toast.createError': '注册 OAuth 客户端失败', + 'settings.oauth.toast.deleted': 'OAuth 客户端已删除', + 'settings.oauth.toast.deleteError': '删除 OAuth 客户端失败', + 'settings.oauth.toast.revoked': '会话已撤销', + 'settings.oauth.toast.revokeError': '撤销会话失败', + 'settings.oauth.toast.rotateError': '轮换客户端密钥失败', + 'settings.oauth.modal.machineClient': '机器客户端(无需浏览器登录)', + 'settings.oauth.modal.machineClientHint': + '使用 client_credentials 授权——无需重定向 URI。令牌通过 client_id + client_secret 直接颁发,并在所选范围内以您的身份运行。', + 'settings.oauth.modal.machineClientUsage': + '获取令牌:向 /oauth/token 发送 POST 请求,携带 grant_type=client_credentials、client_id 和 client_secret。无需浏览器,无刷新令牌。', + 'settings.oauth.badge.machine': '机器', + 'settings.account': '账户', + 'settings.about': '关于', + 'settings.about.reportBug': '报告错误', + 'settings.about.reportBugHint': '发现问题?告诉我们', + 'settings.about.featureRequest': '功能建议', + 'settings.about.featureRequestHint': '建议一个新功能', + 'settings.about.wikiHint': '文档和指南', + 'settings.about.supporters.badge': '月度支持者', + 'settings.about.supporters.title': '与 TREK 同行的伙伴', + 'settings.about.supporters.subtitle': + '当你在规划下一段路线时,这些人也在一起规划 TREK 的未来。他们每月的支持直接用于开发与真实投入的时间——让 TREK 保持开源。', + 'settings.about.supporters.since': '{date} 起的支持者', + 'settings.about.supporters.tierEmpty': '成为第一个', + 'settings.about.supporter.tier.noReturnTicket': 'No Return Ticket', + 'settings.about.supporter.tier.lostLuggageVip': 'Lost Luggage VIP', + 'settings.about.supporter.tier.businessClassDreamer': + 'Business Class Dreamer', + 'settings.about.supporter.tier.budgetTraveller': 'Budget Traveller', + 'settings.about.supporter.tier.hostelBunkmate': 'Hostel Bunkmate', + 'settings.about.description': + 'TREK 是一个自托管的旅行规划工具,帮助你从最初的想法到最后的回忆,全程组织你的旅行。日程规划、预算、行李清单、照片等——一切尽在一处,在你自己的服务器上。', + 'settings.about.madeWith': '用', + 'settings.about.madeBy': '由 Maurice 和不断壮大的开源社区打造。', + 'settings.username': '用户名', + 'settings.email': '邮箱', + 'settings.role': '角色', + 'settings.roleAdmin': '管理员', + 'settings.oidcLinked': '已关联', + 'settings.changePassword': '修改密码', + 'settings.mustChangePassword': '您必须更改密码才能继续。请在下方设置新密码。', + 'settings.currentPassword': '当前密码', + 'settings.currentPasswordRequired': '请输入当前密码', + 'settings.newPassword': '新密码', + 'settings.confirmPassword': '确认新密码', + 'settings.updatePassword': '更新密码', + 'settings.passwordRequired': '请输入当前密码和新密码', + 'settings.passwordTooShort': '密码至少需要 8 个字符', + 'settings.passwordMismatch': '两次输入的密码不一致', + 'settings.passwordWeak': '密码必须包含大写字母、小写字母、数字和特殊字符', + 'settings.passwordChanged': '密码修改成功', + 'settings.deleteAccount': '删除账户', + 'settings.deleteAccountTitle': '确定删除账户?', + 'settings.deleteAccountWarning': + '你的账户以及所有旅行、地点和文件将被永久删除。此操作无法撤销。', + 'settings.deleteAccountConfirm': '永久删除', + 'settings.deleteBlockedTitle': '无法删除', + 'settings.deleteBlockedMessage': + '你是唯一的管理员。请先将其他用户提升为管理员,然后再删除账户。', + 'settings.roleUser': '用户', + 'settings.saveProfile': '保存资料', + 'settings.mfa.title': '双因素认证 (2FA)', + 'settings.mfa.description': + '登录时添加第二步验证。使用身份验证器应用(Google Authenticator、Authy 等)。', + 'settings.mfa.requiredByPolicy': + '管理员要求双因素身份验证。请先完成下方的身份验证器设置后再继续。', + 'settings.mfa.backupTitle': '备用代码', + 'settings.mfa.backupDescription': + '如果你无法使用身份验证器应用,可使用这些一次性备用代码登录。', + 'settings.mfa.backupWarning': '请立即保存这些代码。每个代码只能使用一次。', + 'settings.mfa.backupCopy': '复制代码', + 'settings.mfa.backupDownload': '下载 TXT', + 'settings.mfa.backupPrint': '打印 / PDF', + 'settings.mfa.backupCopied': '备用代码已复制', + 'settings.mfa.enabled': '您的账户已启用 2FA。', + 'settings.mfa.disabled': '2FA 未启用。', + 'settings.mfa.setup': '设置身份验证器', + 'settings.mfa.scanQr': '使用应用扫描此二维码,或手动输入密钥。', + 'settings.mfa.secretLabel': '密钥(手动输入)', + 'settings.mfa.codePlaceholder': '6 位验证码', + 'settings.mfa.enable': '启用 2FA', + 'settings.mfa.cancelSetup': '取消', + 'settings.mfa.disableTitle': '停用 2FA', + 'settings.mfa.disableHint': '输入您的账户密码和身份验证器中的当前验证码。', + 'settings.mfa.disable': '停用 2FA', + 'settings.mfa.toastEnabled': '双因素认证已启用', + 'settings.mfa.toastDisabled': '双因素认证已停用', + 'settings.mfa.demoBlocked': '演示模式下不可用', + 'settings.toast.mapSaved': '地图设置已保存', + 'settings.toast.keysSaved': 'API 密钥已保存', + 'settings.toast.displaySaved': '显示设置已保存', + 'settings.toast.profileSaved': '资料已保存', + 'settings.uploadAvatar': '上传头像', + 'settings.removeAvatar': '移除头像', + 'settings.avatarUploaded': '头像已更新', + 'settings.avatarRemoved': '头像已移除', + 'settings.avatarError': '上传失败', + 'settings.bookingLabels': '预订路线标签', + 'settings.bookingLabelsHint': + '在地图上显示车站 / 机场名称。关闭时仅显示图标。', + 'settings.notifyVersionAvailable': '有新版本可用', + 'settings.notificationPreferences.noChannels': + '未配置通知渠道。请联系管理员设置电子邮件或 Webhook 通知。', + 'settings.webhookUrl.label': 'Webhook URL', + 'settings.webhookUrl.placeholder': 'https://discord.com/api/webhooks/...', + 'settings.webhookUrl.hint': + '输入您的 Discord、Slack 或自定义 Webhook URL 以接收通知。', + 'settings.webhookUrl.saved': 'Webhook URL 已保存', + 'settings.webhookUrl.test': '测试', + 'settings.webhookUrl.testSuccess': '测试 Webhook 发送成功', + 'settings.webhookUrl.testFailed': '测试 Webhook 失败', + 'settings.ntfyUrl.topicLabel': 'Ntfy 主题', + 'settings.ntfyUrl.topicPlaceholder': 'my-trek-alerts', + 'settings.ntfyUrl.serverLabel': 'Ntfy 服务器 URL(可选)', + 'settings.ntfyUrl.serverPlaceholder': 'https://ntfy.sh', + 'settings.ntfyUrl.hint': + '输入您的 Ntfy 主题以接收推送通知。将服务器留空以使用管理员配置的默认值。', + 'settings.ntfyUrl.tokenLabel': '访问令牌(可选)', + 'settings.ntfyUrl.tokenHint': '受密码保护的主题需要此项。', + 'settings.ntfyUrl.saved': 'Ntfy 设置已保存', + 'settings.ntfyUrl.test': '测试', + 'settings.ntfyUrl.testSuccess': '测试 Ntfy 通知发送成功', + 'settings.ntfyUrl.testFailed': '测试 Ntfy 通知失败', + 'settings.ntfyUrl.tokenCleared': '访问令牌已清除', + 'settings.notificationPreferences.inapp': 'In-App', + 'settings.notificationPreferences.webhook': 'Webhook', + 'settings.notificationPreferences.email': 'Email', + 'settings.notificationPreferences.ntfy': 'Ntfy', + "settings.currency": "Currency", + "settings.currencyHint": "All amounts in Costs are converted to and shown in this currency.", + 'settings.passkey.title': '通行密钥', + 'settings.passkey.description': + '使用通行密钥更快登录,并能抵御钓鱼攻击——通过指纹、面容、PIN 或硬件密钥验证。你的密码仍可作为备用方式。', + 'settings.passkey.notConfigured': + '通行密钥已启用,但此服务器尚未完成完整配置。请联系管理员设置 WebAuthn 域名。', + 'settings.passkey.add': '添加通行密钥', + 'settings.passkey.addTitle': '添加通行密钥', + 'settings.passkey.passwordPrompt': '确认你的当前密码,然后按照设备提示操作。', + 'settings.passkey.passwordRequired': '需要输入你的当前密码。', + 'settings.passkey.namePlaceholder': '名称(可选,如 "iPhone")', + 'settings.passkey.addedToast': '通行密钥已添加', + 'settings.passkey.added': '已添加', + 'settings.passkey.addError': '无法添加通行密钥', + 'settings.passkey.cancelled': '已取消通行密钥设置', + 'settings.passkey.deleted': '通行密钥已移除', + 'settings.passkey.deleteConfirm': '移除此通行密钥?请输入密码确认。', + 'settings.passkey.rename': '重命名', + 'settings.passkey.defaultName': '通行密钥', + 'settings.passkey.synced': '已同步', + 'settings.passkey.deviceBound': '此设备', + 'settings.passkey.lastUsed': '上次使用', + 'settings.passkey.neverUsed': '从未使用', + 'settings.mapPoiPill': '在地图上探索地点', + 'settings.mapPoiPillHint': '在行程地图上显示分类标签,从 OpenStreetMap 查找附近的餐厅、酒店等。', + 'settings.airtrail.title': 'AirTrail', + 'settings.airtrail.hint': '连接您的自托管 AirTrail 以导入和同步航班。在 AirTrail 的“设置 → 安全”中创建 API 密钥。', + 'settings.airtrail.url': '实例 URL', + 'settings.airtrail.apiKey': 'API 密钥', + 'settings.airtrail.apiKeyPlaceholder': 'Bearer API 密钥', + 'settings.airtrail.apiKeyHint': '在 AirTrail 的“设置 → 安全”中生成。加密存储。', + 'settings.airtrail.allowInsecureTls': '允许自签名证书', + 'settings.airtrail.allowInsecureTlsHint': '仅对您自己网络中受信任的实例启用。', + 'settings.airtrail.connected': '已连接', + 'settings.airtrail.notConnected': '未连接', + 'settings.airtrail.toast.saved': 'AirTrail 连接已保存', + 'settings.airtrail.toast.saveError': '无法保存连接', + 'settings.airtrail.test.button': '测试连接', + 'settings.airtrail.test.success': '已连接——找到 {count} 个航班', + 'settings.airtrail.test.failed': '连接失败', +}; + +export default settings; diff --git a/shared/src/i18n/zh/share.ts b/shared/src/i18n/zh/share.ts new file mode 100644 index 0000000000000000000000000000000000000000..d7a6e76782cb4029c4af72c9e654e248f5d278ea --- /dev/null +++ b/shared/src/i18n/zh/share.ts @@ -0,0 +1,16 @@ +import type { TranslationStrings } from '../types'; + +const share: TranslationStrings = { + 'share.linkTitle': '公开链接', + 'share.linkHint': + '创建一个链接,任何人无需登录即可查看此旅行。仅可查看,无法编辑。', + 'share.createLink': '创建链接', + 'share.deleteLink': '删除链接', + 'share.createError': '无法创建链接', + 'share.permMap': '地图与计划', + 'share.permBookings': '预订', + 'share.permPacking': '行李', + 'share.permBudget': '预算', + 'share.permCollab': '聊天', +}; +export default share; diff --git a/shared/src/i18n/zh/shared.ts b/shared/src/i18n/zh/shared.ts new file mode 100644 index 0000000000000000000000000000000000000000..e76f2116a6282d80fc57519bdf11ebbc5ca301a9 --- /dev/null +++ b/shared/src/i18n/zh/shared.ts @@ -0,0 +1,21 @@ +import type { TranslationStrings } from '../types'; + +const shared: TranslationStrings = { + 'shared.expired': '链接已过期或无效', + 'shared.expiredHint': '此共享旅行链接已失效。', + 'shared.readOnly': '只读共享视图', + 'shared.tabPlan': '计划', + 'shared.tabBookings': '预订', + 'shared.tabPacking': '行李', + 'shared.tabBudget': '预算', + 'shared.tabChat': '聊天', + 'shared.days': '天', + 'shared.places': '个地点', + 'shared.other': '其他', + 'shared.totalBudget': '总预算', + 'shared.messages': '条消息', + 'shared.sharedVia': '通过以下分享', + 'shared.confirmed': '已确认', + 'shared.pending': '待确认', +}; +export default shared; diff --git a/shared/src/i18n/zh/stats.ts b/shared/src/i18n/zh/stats.ts new file mode 100644 index 0000000000000000000000000000000000000000..268f186c5716dc907f1f574639d5842cf7817449 --- /dev/null +++ b/shared/src/i18n/zh/stats.ts @@ -0,0 +1,13 @@ +import type { TranslationStrings } from '../types'; + +const stats: TranslationStrings = { + 'stats.countries': '国家', + 'stats.cities': '城市', + 'stats.trips': '旅行', + 'stats.places': '地点', + 'stats.worldProgress': '全球进度', + 'stats.visited': '已访问', + 'stats.remaining': '未访问', + 'stats.visitedCountries': '已访问国家', +}; +export default stats; diff --git a/shared/src/i18n/zh/system_notice.ts b/shared/src/i18n/zh/system_notice.ts new file mode 100644 index 0000000000000000000000000000000000000000..26436fcfc43a930a37d0d6427f80f13d221aaa5f --- /dev/null +++ b/shared/src/i18n/zh/system_notice.ts @@ -0,0 +1,50 @@ +import type { TranslationStrings } from '../types'; + +const system_notice: TranslationStrings = { + 'system_notice.welcome_v1.title': '欢迎使用 TREK', + 'system_notice.welcome_v1.body': + '您的全能旅行规划器。制定行程、与朋友分享旅行,随时保持井然有序——在线或离线均可。', + 'system_notice.welcome_v1.cta_label': '规划行程', + 'system_notice.welcome_v1.hero_alt': '风景优美的旅游目的地与 TREK 界面', + 'system_notice.welcome_v1.highlight_plan': '逐日行程规划', + 'system_notice.welcome_v1.highlight_share': '与旅行伙伴协作', + 'system_notice.welcome_v1.highlight_offline': '移动端支持离线使用', + 'system_notice.dev_test_modal.title': '[Dev] Test notice', + 'system_notice.dev_test_modal.body': 'This is a dev-only test notice.', + 'system_notice.pager.prev': '上一条通知', + 'system_notice.pager.next': '下一条通知', + 'system_notice.pager.counter': '{current} / {total}', + 'system_notice.pager.goto': '转到通知 {n}', + 'system_notice.pager.position': '通知 {current}/{total}', + 'system_notice.v3_photos.title': '3.0 版照片已迁移', + 'system_notice.v3_photos.body': + '行程规划器中的​**照片**标签已被移除。您的照片安全无虑 — TREK 从未修改您的 Immich 或 Synology 相册。\n\n照片现在位于 **Journey** 插件中。Journey 是可选的 — 如果尚未启用,请联系管理员在 Admin → 插件 中开启。', + 'system_notice.v3_journey.title': '认识 Journey — 旅行日记', + 'system_notice.v3_journey.body': + '将您的旅程记录为展示时间线、照片画廊和互动地图的丰富旅行故事。', + 'system_notice.v3_journey.cta_label': '打开 Journey', + 'system_notice.v3_journey.highlight_timeline': '每日时间线与画廊', + 'system_notice.v3_journey.highlight_photos': '从 Immich 或 Synology 导入', + 'system_notice.v3_journey.highlight_share': '公开分享 — 无需登录', + 'system_notice.v3_journey.highlight_export': '导出为 PDF 相册书', + 'system_notice.v3_features.title': '3.0 版更多亮点', + 'system_notice.v3_features.body': '此版本还有一些其他值得了解的新功能。', + 'system_notice.v3_features.highlight_dashboard': '移动优先仪表板重设计', + 'system_notice.v3_features.highlight_offline': '作为 PWA 的完整离线模式', + 'system_notice.v3_features.highlight_search': '地点搜索实时自动补全', + 'system_notice.v3_features.highlight_import': '从 KMZ/KML 文件导入地点', + 'system_notice.v3_mcp.title': 'MCP:OAuth 2.1 升级', + 'system_notice.v3_mcp.body': + 'MCP 集成已全面重构。OAuth 2.1 现为推荐的身份验证方式。静态令牌(trek_…)已弃用,将在未来版本中移除。', + 'system_notice.v3_mcp.highlight_oauth': 'OAuth 2.1 推荐(mcp-remote)', + 'system_notice.v3_mcp.highlight_scopes': '24 个细粒度权限范围', + 'system_notice.v3_mcp.highlight_deprecated': '静态 trek_ 令牌已弃用', + 'system_notice.v3_mcp.highlight_tools': '扩展工具集与提示词', + 'system_notice.v3_thankyou.title': '来自我的一封私人信', + 'system_notice.v3_thankyou.body': + '在你继续之前——我想停下来说几句。\n\nTREK 最初只是我为自己的旅行而做的一个业余项目。我从未想过它会成长为 4,000 人信赖的冒险规划工具。每一颗星标、每一个 issue、每一个功能请求——我都会读,它们在全职工作和大学学业之间的深夜里支撑着我继续前行。\n\n我想让你们知道:TREK 将永远开源,永远可自托管,永远属于你们。没有追踪,没有订阅,没有任何附加条件。只是一个热爱旅行的人为同样热爱旅行的你们打造的工具。\n\n特别感谢 [jubnl](https://github.com/jubnl)——你已经成为一位不可思议的合作者。3.0 版本中许多精彩之处都留下了你的印记。感谢你在这个项目还很粗糙的时候就选择了相信它。\n\n也感谢你们每一位——报告了 bug、翻译了文本、向朋友分享了 TREK,或者只是用它规划了一次旅行——**谢谢你们**。你们是这一切存在的原因。\n\n愿我们一起踏上更多的冒险旅程。\n\n— Maurice\n\n---\n\n[加入 Discord 社区](https://discord.gg/7Q6M6jDwzf)\n\n如果 TREK 让你的旅行更美好,一杯[小小的咖啡](https://ko-fi.com/mauriceboe)能让这盏灯一直亮着。', + 'system_notice.v3014_whitespace_collision.title': '需要操作:用户账户冲突', + 'system_notice.v3014_whitespace_collision.body': + '3.0.14 版本升级检测到一个或多个由存储账户中首尾空白字符引发的用户名或邮箱冲突。受影响的账户已自动重命名。请检查服务器日志中以 **[migration] WHITESPACE COLLISION** 开头的行,以确认哪些账户需要审查。', +}; +export default system_notice; diff --git a/shared/src/i18n/zh/todo.ts b/shared/src/i18n/zh/todo.ts new file mode 100644 index 0000000000000000000000000000000000000000..87a024f31acea22d7ff7eba1abb0803c4cb9add5 --- /dev/null +++ b/shared/src/i18n/zh/todo.ts @@ -0,0 +1,40 @@ +import type { TranslationStrings } from '../types'; + +const todo: TranslationStrings = { + 'todo.subtab.packing': '行李清单', + 'todo.subtab.todo': '待办事项', + 'todo.completed': '已完成', + 'todo.filter.all': '全部', + 'todo.filter.open': '进行中', + 'todo.filter.done': '已完成', + 'todo.uncategorized': '未分类', + 'todo.namePlaceholder': '任务名称', + 'todo.descriptionPlaceholder': '描述(可选)', + 'todo.unassigned': '未分配', + 'todo.noCategory': '无分类', + 'todo.hasDescription': '有描述', + 'todo.addItem': '新建任务', + 'todo.sidebar.sortBy': '排序方式', + 'todo.priority': '优先级', + 'todo.newCategoryLabel': '新建', + 'todo.newCategory': '分类名称', + 'todo.addCategory': '添加分类', + 'todo.newItem': '新任务', + 'todo.empty': '暂无任务,添加一个任务开始吧!', + 'todo.filter.my': '我的任务', + 'todo.filter.overdue': '已逾期', + 'todo.sidebar.tasks': '任务', + 'todo.sidebar.categories': '分类', + 'todo.detail.title': '任务', + 'todo.detail.description': '描述', + 'todo.detail.category': '分类', + 'todo.detail.dueDate': '截止日期', + 'todo.detail.assignedTo': '分配给', + 'todo.detail.delete': '删除', + 'todo.detail.save': '保存更改', + 'todo.detail.create': '创建任务', + 'todo.detail.priority': '优先级', + 'todo.detail.noPriority': '无', + 'todo.sortByPrio': '优先级', +}; +export default todo; diff --git a/shared/src/i18n/zh/transport.ts b/shared/src/i18n/zh/transport.ts new file mode 100644 index 0000000000000000000000000000000000000000..886b68f5dc760d01905b7fea9ea7b370a2371c0c --- /dev/null +++ b/shared/src/i18n/zh/transport.ts @@ -0,0 +1,10 @@ +import type { TranslationStrings } from '../types'; + +const transport: TranslationStrings = { + 'transport.addTransport': '添加交通', + 'transport.modalTitle.create': '添加交通', + 'transport.modalTitle.edit': '编辑交通', + 'transport.title': '交通', + 'transport.addManual': '手动添加交通', +}; +export default transport; diff --git a/shared/src/i18n/zh/trip.ts b/shared/src/i18n/zh/trip.ts new file mode 100644 index 0000000000000000000000000000000000000000..9df70d17b0f0b0dd773d257c3ba82e8a6d4d5098 --- /dev/null +++ b/shared/src/i18n/zh/trip.ts @@ -0,0 +1,31 @@ +import type { TranslationStrings } from '../types'; + +const trip: TranslationStrings = { + 'trip.tabs.plan': '计划', + 'trip.tabs.transports': '交通', + 'trip.tabs.reservations': '预订', + 'trip.tabs.reservationsShort': '预订', + 'trip.tabs.packing': '行李清单', + 'trip.tabs.packingShort': '行李', + 'trip.tabs.lists': '列表', + 'trip.tabs.listsShort': '列表', + 'trip.tabs.budget': "Costs", + 'trip.tabs.files': '文件', + 'trip.loading': '加载旅行中...', + 'trip.loadingPhotos': '正在加载地点照片...', + 'trip.mobilePlan': '计划', + 'trip.mobilePlaces': '地点', + 'trip.toast.placeUpdated': '地点已更新', + 'trip.toast.placeAdded': '地点已添加', + 'trip.toast.placeDeleted': '地点已删除', + 'trip.toast.selectDay': '请先选择一天', + 'trip.toast.assignedToDay': '地点已分配到当天', + 'trip.toast.reorderError': '排序失败', + 'trip.toast.reservationUpdated': '预订已更新', + 'trip.toast.reservationAdded': '预订已添加', + 'trip.toast.deleted': '已删除', + 'trip.confirm.deletePlace': '确定要删除这个地点吗?', + 'trip.confirm.deletePlaces': '删除 {count} 个地点?', + 'trip.toast.placesDeleted': '已删除 {count} 个地点', +}; +export default trip; diff --git a/shared/src/i18n/zh/trips.ts b/shared/src/i18n/zh/trips.ts new file mode 100644 index 0000000000000000000000000000000000000000..bf13ecef30c8da1aac854a4cc09197bcd119a057 --- /dev/null +++ b/shared/src/i18n/zh/trips.ts @@ -0,0 +1,17 @@ +import type { TranslationStrings } from '../types'; + +const trips: TranslationStrings = { + 'trips.memberRemoved': '{username} 已移除', + 'trips.memberRemoveError': '移除失败', + 'trips.memberAdded': '{username} 已添加', + 'trips.memberAddError': '添加失败', + 'trips.reminder': '提醒', + 'trips.reminderNone': '无', + 'trips.reminderDay': '天', + 'trips.reminderDays': '天', + 'trips.reminderCustom': '自定义', + 'trips.reminderDaysBefore': '天前提醒', + 'trips.reminderDisabledHint': + '旅行提醒已禁用。请在管理 > 设置 > 通知中启用。', +}; +export default trips; diff --git a/shared/src/i18n/zh/undo.ts b/shared/src/i18n/zh/undo.ts new file mode 100644 index 0000000000000000000000000000000000000000..14f157525f9e51493ec493a4145a8a99c99b5076 --- /dev/null +++ b/shared/src/i18n/zh/undo.ts @@ -0,0 +1,22 @@ +import type { TranslationStrings } from '../types'; + +const undo: TranslationStrings = { + 'undo.button': '撤销', + 'undo.tooltip': '撤销:{action}', + 'undo.assignPlace': '地点已分配至某天', + 'undo.removeAssignment': '地点已从某天移除', + 'undo.reorder': '地点已重新排序', + 'undo.optimize': '路线已优化', + 'undo.deletePlace': '地点已删除', + 'undo.deletePlaces': '地点已删除', + 'undo.moveDay': '地点已移至另一天', + 'undo.lock': '地点锁定已切换', + 'undo.importGpx': 'GPX 导入', + 'undo.importKeyholeMarkup': 'KMZ/KML 导入', + 'undo.importGoogleList': 'Google 地图导入', + 'undo.importNaverList': 'Naver 地图导入', + 'undo.addPlace': '地点已添加', + 'undo.done': '已撤销:{action}', + 'undo.importBooking': '导入预订确认', +}; +export default undo; diff --git a/shared/src/i18n/zh/vacay.ts b/shared/src/i18n/zh/vacay.ts new file mode 100644 index 0000000000000000000000000000000000000000..804927f2b81595c1e4741539553f4ee9d004a32e --- /dev/null +++ b/shared/src/i18n/zh/vacay.ts @@ -0,0 +1,93 @@ +import type { TranslationStrings } from '../types'; + +const vacay: TranslationStrings = { + 'vacay.subtitle': '规划和管理假期', + 'vacay.settings': '设置', + 'vacay.year': '年份', + 'vacay.addYear': '添加下一年', + 'vacay.addPrevYear': '添加上一年', + 'vacay.removeYear': '移除年份', + 'vacay.removeYearConfirm': '移除 {year}?', + 'vacay.removeYearHint': '该年度所有假期记录和公司假日将被永久删除。', + 'vacay.remove': '移除', + 'vacay.persons': '成员', + 'vacay.noPersons': '暂无成员', + 'vacay.addPerson': '添加成员', + 'vacay.editPerson': '编辑成员', + 'vacay.removePerson': '移除成员', + 'vacay.removePersonConfirm': '移除 {name}?', + 'vacay.removePersonHint': '该成员的所有假期记录将被永久删除。', + 'vacay.personName': '姓名', + 'vacay.personNamePlaceholder': '输入姓名', + 'vacay.color': '颜色', + 'vacay.add': '添加', + 'vacay.legend': '图例', + 'vacay.publicHoliday': '公共假日', + 'vacay.companyHoliday': '公司假日', + 'vacay.weekend': '周末', + 'vacay.modeVacation': '休假', + 'vacay.modeCompany': '公司假日', + 'vacay.entitlement': '年假额度', + 'vacay.entitlementDays': '天', + 'vacay.used': '已用', + 'vacay.remaining': '剩余', + 'vacay.carriedOver': '从 {year} 结转', + 'vacay.blockWeekends': '锁定周末', + 'vacay.blockWeekendsHint': '禁止在周六和周日安排假期', + 'vacay.weekendDays': '周末', + 'vacay.mon': '周一', + 'vacay.tue': '周二', + 'vacay.wed': '周三', + 'vacay.thu': '周四', + 'vacay.fri': '周五', + 'vacay.sat': '周六', + 'vacay.sun': '周日', + 'vacay.publicHolidays': '公共假日', + 'vacay.publicHolidaysHint': '在日历中标记公共假日', + 'vacay.selectCountry': '选择国家', + 'vacay.selectRegion': '选择地区(可选)', + 'vacay.companyHolidays': '公司假日', + 'vacay.companyHolidaysHint': '允许标记公司统一休假日', + 'vacay.companyHolidaysNoDeduct': '公司假日不计入年假天数。', + 'vacay.weekStart': '每周开始于', + 'vacay.weekStartHint': '选择日历周从周一还是周日开始', + 'vacay.carryOver': '结转', + 'vacay.carryOverHint': '自动将剩余年假天数结转到下一年', + 'vacay.sharing': '共享', + 'vacay.sharingHint': '与其他 TREK 用户共享你的假期计划', + 'vacay.owner': '所有者', + 'vacay.shareEmailPlaceholder': 'TREK 用户邮箱', + 'vacay.shareSuccess': '计划共享成功', + 'vacay.shareError': '无法共享计划', + 'vacay.dissolve': '解除合并', + 'vacay.dissolveHint': '重新分离日历。你的记录将被保留。', + 'vacay.dissolveAction': '解除', + 'vacay.dissolved': '日历已分离', + 'vacay.fusedWith': '已合并', + 'vacay.you': '你', + 'vacay.noData': '暂无数据', + 'vacay.changeColor': '更改颜色', + 'vacay.inviteUser': '邀请用户', + 'vacay.inviteHint': '邀请其他 TREK 用户共享合并的假期日历。', + 'vacay.selectUser': '选择用户', + 'vacay.sendInvite': '发送邀请', + 'vacay.inviteSent': '邀请已发送', + 'vacay.inviteError': '无法发送邀请', + 'vacay.pending': '待处理', + 'vacay.noUsersAvailable': '没有可用用户', + 'vacay.accept': '接受', + 'vacay.decline': '拒绝', + 'vacay.acceptFusion': '接受并合并', + 'vacay.inviteTitle': '合并请求', + 'vacay.inviteWantsToFuse': '想要与你共享假期日历。', + 'vacay.fuseInfo1': '你们双方将在一个共享日历中看到所有假期记录。', + 'vacay.fuseInfo2': '双方都可以为对方创建和编辑记录。', + 'vacay.fuseInfo3': '双方都可以删除记录和修改年假额度。', + 'vacay.fuseInfo4': '公共假日和公司假日等设置将共享。', + 'vacay.fuseInfo5': '任何一方都可以随时解除合并。你的记录将被保留。', + 'vacay.addCalendar': '添加日历', + 'vacay.calendarColor': '颜色', + 'vacay.calendarLabel': '标签', + 'vacay.noCalendars': '无日历', +}; +export default vacay; diff --git a/shared/src/index.ts b/shared/src/index.ts new file mode 100644 index 0000000000000000000000000000000000000000..881ce3a6b64f29ad3cd19d859b71b3f7829c7431 --- /dev/null +++ b/shared/src/index.ts @@ -0,0 +1,50 @@ +/** + * @trek/shared — single source of truth for TREK's API contracts. + * + * Zod schemas defined here are consumed by BOTH the server (validation + + * inferred DTO types) and the client (typed requests/responses). A route is + * only considered "migrated" once its contract lives in this package. + * + * Layout: one folder per domain (e.g. src/trip/trip.schema.ts), plus the + * domain-agnostic primitives below. See the board card "Module blueprint". + */ +export * from './common/primitives.schema'; +export * from './common/pagination.schema'; + +// Domain contracts +export * from './weather/weather.schema'; +export * from './airport/airport.schema'; +export * from './config/config.schema'; +export * from './system-notice/system-notice.schema'; +export * from './maps/maps.schema'; +export * from './category/category.schema'; +export * from './tag/tag.schema'; +export * from './notification/notification.schema'; +export * from './atlas/atlas.schema'; +export * from './vacay/vacay.schema'; +export * from './packing/packing.schema'; +export * from './todo/todo.schema'; +export * from './budget/budget.schema'; +export * from './reservation/reservation.schema'; +export * from './airtrail/airtrail.schema'; +export * from './day/day.schema'; +export * from './assignment/assignment.schema'; +export * from './place/place.schema'; +export * from './trip/trip.schema'; +export * from './collab/collab.schema'; +export * from './file/file.schema'; +export * from './journey/journey.schema'; +export * from './share/share.schema'; +export * from './settings/settings.schema'; +export * from './backup/backup.schema'; +export * from './auth/auth.schema'; +export * from './oidc/oidc.schema'; +export * from './oauth/oauth.schema'; +export * from './admin/admin.schema'; + +// Sanitisation helpers — used by the client today, scoped here so the server +// has them ready if rich-text input ever ships. +export * from './sanitize/sanitize'; + +// i18n registry (language list + pure helpers — no locale data) +export * from './i18n/languages'; diff --git a/shared/src/journey/journey.schema.spec.ts b/shared/src/journey/journey.schema.spec.ts new file mode 100644 index 0000000000000000000000000000000000000000..6fec24e154846c0711393b50a91792dd4b4dd7ef --- /dev/null +++ b/shared/src/journey/journey.schema.spec.ts @@ -0,0 +1,98 @@ +import { + journeyCreateRequestSchema, + journeyAddTripRequestSchema, + journeyReorderEntriesRequestSchema, + journeyContributorRequestSchema, + journeyProviderPhotosRequestSchema, + journeyShareLinkRequestSchema, +} from './journey.schema'; + +import { describe, it, expect } from 'vitest'; + +describe('journeyCreateRequestSchema', () => { + it('requires a title; subtitle + trip_ids optional', () => { + expect( + journeyCreateRequestSchema.safeParse({ title: 'Trip of a lifetime' }) + .success, + ).toBe(true); + expect( + journeyCreateRequestSchema.safeParse({ title: 'X', trip_ids: [1, '2'] }) + .success, + ).toBe(true); + expect( + journeyCreateRequestSchema.safeParse({ subtitle: 'no title' }).success, + ).toBe(false); + }); +}); + +describe('journeyAddTripRequestSchema', () => { + it('requires a trip_id (string or number)', () => { + expect(journeyAddTripRequestSchema.safeParse({ trip_id: 5 }).success).toBe( + true, + ); + expect( + journeyAddTripRequestSchema.safeParse({ trip_id: '5' }).success, + ).toBe(true); + expect(journeyAddTripRequestSchema.safeParse({}).success).toBe(false); + }); +}); + +describe('journeyReorderEntriesRequestSchema', () => { + it('requires a non-empty orderedIds array', () => { + expect( + journeyReorderEntriesRequestSchema.safeParse({ orderedIds: [3, 1, 2] }) + .success, + ).toBe(true); + expect( + journeyReorderEntriesRequestSchema.safeParse({ orderedIds: [] }).success, + ).toBe(false); + }); +}); + +describe('journeyContributorRequestSchema', () => { + it('requires user_id; role limited to editor/viewer', () => { + expect( + journeyContributorRequestSchema.safeParse({ user_id: 2 }).success, + ).toBe(true); + expect( + journeyContributorRequestSchema.safeParse({ user_id: 2, role: 'editor' }) + .success, + ).toBe(true); + expect( + journeyContributorRequestSchema.safeParse({ user_id: 2, role: 'admin' }) + .success, + ).toBe(false); + }); +}); + +describe('journeyProviderPhotosRequestSchema', () => { + it('requires a provider; accepts single asset_id or a batch', () => { + expect( + journeyProviderPhotosRequestSchema.safeParse({ + provider: 'immich', + asset_id: 'a1', + }).success, + ).toBe(true); + expect( + journeyProviderPhotosRequestSchema.safeParse({ + provider: 'immich', + asset_ids: ['a1', 'a2'], + }).success, + ).toBe(true); + expect( + journeyProviderPhotosRequestSchema.safeParse({ asset_id: 'a1' }).success, + ).toBe(false); + }); +}); + +describe('journeyShareLinkRequestSchema', () => { + it('accepts optional share toggles', () => { + expect( + journeyShareLinkRequestSchema.safeParse({ + share_timeline: true, + share_gallery: false, + }).success, + ).toBe(true); + expect(journeyShareLinkRequestSchema.safeParse({}).success).toBe(true); + }); +}); diff --git a/shared/src/journey/journey.schema.ts b/shared/src/journey/journey.schema.ts new file mode 100644 index 0000000000000000000000000000000000000000..1c8e5735d7f7e711c2bc62a5636dc865274fe8e4 --- /dev/null +++ b/shared/src/journey/journey.schema.ts @@ -0,0 +1,61 @@ +import { z } from 'zod'; + +/** + * Journey API contract — cross-trip travel narrative (journeys, dated entries, + * a photo gallery with provider mirroring, contributors, per-user preferences + * and public share links). + * + * Authenticated routes live under /api/journeys (gated by the Journey addon); + * the public read/photo-proxy routes live under /api/public/journey and are + * share-token validated. Access control lives inside journeyService (it returns + * null/false → the controller maps to 403/404), so these schemas pin the + * well-defined request bodies; entry create/update stay open-ended (forwarded + * to the service) and the bespoke 400/403/404 messages pin the rest. + */ + +export const journeyCreateRequestSchema = z.object({ + title: z.string().min(1), + subtitle: z.string().optional(), + trip_ids: z.array(z.union([z.string(), z.number()])).optional(), +}); +export type JourneyCreateRequest = z.infer; + +export const journeyAddTripRequestSchema = z.object({ + trip_id: z.union([z.string(), z.number()]), +}); +export type JourneyAddTripRequest = z.infer; + +export const journeyReorderEntriesRequestSchema = z.object({ + orderedIds: z.array(z.union([z.string(), z.number()])).min(1), +}); +export type JourneyReorderEntriesRequest = z.infer< + typeof journeyReorderEntriesRequestSchema +>; + +export const journeyContributorRequestSchema = z.object({ + user_id: z.union([z.string(), z.number()]), + role: z.enum(['editor', 'viewer']).optional(), +}); +export type JourneyContributorRequest = z.infer< + typeof journeyContributorRequestSchema +>; + +export const journeyProviderPhotosRequestSchema = z.object({ + provider: z.string().min(1), + asset_id: z.string().optional(), + asset_ids: z.array(z.union([z.string(), z.number()])).optional(), + caption: z.string().optional(), + passphrase: z.string().optional(), +}); +export type JourneyProviderPhotosRequest = z.infer< + typeof journeyProviderPhotosRequestSchema +>; + +export const journeyShareLinkRequestSchema = z.object({ + share_timeline: z.boolean().optional(), + share_gallery: z.boolean().optional(), + share_map: z.boolean().optional(), +}); +export type JourneyShareLinkRequest = z.infer< + typeof journeyShareLinkRequestSchema +>; diff --git a/shared/src/maps/maps.schema.spec.ts b/shared/src/maps/maps.schema.spec.ts new file mode 100644 index 0000000000000000000000000000000000000000..b831901eb75ea4d64336c2d03a4d149c9e353905 --- /dev/null +++ b/shared/src/maps/maps.schema.spec.ts @@ -0,0 +1,62 @@ +import { + mapsSearchRequestSchema, + mapsAutocompleteRequestSchema, + mapsReverseQuerySchema, + mapsResolveUrlRequestSchema, +} from './maps.schema'; + +import { describe, it, expect } from 'vitest'; + +describe('mapsSearchRequestSchema', () => { + it('requires a non-empty query', () => { + expect(mapsSearchRequestSchema.safeParse({ query: 'berlin' }).success).toBe( + true, + ); + expect(mapsSearchRequestSchema.safeParse({ query: '' }).success).toBe( + false, + ); + expect(mapsSearchRequestSchema.safeParse({}).success).toBe(false); + }); +}); + +describe('mapsAutocompleteRequestSchema', () => { + it('caps input at 200 chars and allows an optional locationBias', () => { + expect( + mapsAutocompleteRequestSchema.safeParse({ input: 'be' }).success, + ).toBe(true); + expect( + mapsAutocompleteRequestSchema.safeParse({ input: 'x'.repeat(201) }) + .success, + ).toBe(false); + expect( + mapsAutocompleteRequestSchema.safeParse({ + input: 'be', + locationBias: { low: { lat: 1, lng: 2 }, high: { lat: 3, lng: 4 } }, + }).success, + ).toBe(true); + }); +}); + +describe('mapsReverseQuerySchema', () => { + it('requires lat and lng as strings (the route parses them downstream)', () => { + expect( + mapsReverseQuerySchema.safeParse({ lat: '52.5', lng: '13.4' }).success, + ).toBe(true); + expect(mapsReverseQuerySchema.safeParse({ lat: '52.5' }).success).toBe( + false, + ); + }); +}); + +describe('mapsResolveUrlRequestSchema', () => { + it('requires a non-empty url', () => { + expect( + mapsResolveUrlRequestSchema.safeParse({ + url: 'https://maps.app.goo.gl/x', + }).success, + ).toBe(true); + expect(mapsResolveUrlRequestSchema.safeParse({ url: '' }).success).toBe( + false, + ); + }); +}); diff --git a/shared/src/maps/maps.schema.ts b/shared/src/maps/maps.schema.ts new file mode 100644 index 0000000000000000000000000000000000000000..f982a61a0a80e775d92b9f9c05baabab8b5616db --- /dev/null +++ b/shared/src/maps/maps.schema.ts @@ -0,0 +1,94 @@ +import { z } from 'zod'; + +/** + * Maps / geo API contract — single source of truth for the /api/maps endpoints. + * + * The legacy Express route (server/src/routes/maps.ts) is a thin layer over + * services/mapsService.ts, which talks to Nominatim/Overpass (and optionally + * Google Places when a key is configured) and applies the SSRF guard on every + * outbound URL. The place objects these return are provider-shaped and vary by + * source, so the response schemas keep them as open records — the contract pins + * down the request shapes and the stable envelope fields, not the provider blobs. + * + * The bespoke 400 validation messages and the per-endpoint kill-switch responses + * are reproduced in the controller, not derived from these schemas, so the bodies + * stay byte-identical to Express. + */ + +const latLng = z.object({ lat: z.number(), lng: z.number() }); + +export const mapsSearchRequestSchema = z.object({ + query: z.string().min(1), +}); +export type MapsSearchRequest = z.infer; + +export const mapsAutocompleteRequestSchema = z.object({ + input: z.string().min(1).max(200), + lang: z.string().optional(), + locationBias: z.object({ low: latLng, high: latLng }).optional(), +}); +export type MapsAutocompleteRequest = z.infer< + typeof mapsAutocompleteRequestSchema +>; + +export const mapsReverseQuerySchema = z.object({ + lat: z.string().min(1), + lng: z.string().min(1), + lang: z.string().optional(), +}); +export type MapsReverseQuery = z.infer; + +export const mapsResolveUrlRequestSchema = z.object({ + url: z.string().min(1), +}); +export type MapsResolveUrlRequest = z.infer; + +/** Provider-shaped place blob (Google/OSM fields differ); kept open by design. */ +const placeRecord = z.record(z.string(), z.unknown()); + +export const mapsSearchResultSchema = z.object({ + places: z.array(placeRecord), + source: z.string(), +}); +export type MapsSearchResult = z.infer; + +export const mapsAutocompleteSuggestionSchema = z.object({ + placeId: z.string(), + mainText: z.string(), + secondaryText: z.string(), +}); +export const mapsAutocompleteResultSchema = z.object({ + suggestions: z.array(mapsAutocompleteSuggestionSchema), + source: z.string(), +}); +export type MapsAutocompleteResult = z.infer< + typeof mapsAutocompleteResultSchema +>; + +export const mapsPlaceDetailsResultSchema = z.object({ + place: placeRecord.nullable(), + disabled: z.boolean().optional(), +}); +export type MapsPlaceDetailsResult = z.infer< + typeof mapsPlaceDetailsResultSchema +>; + +export const mapsPlacePhotoResultSchema = z.object({ + photoUrl: z.string().nullable(), + attribution: z.string().nullable().optional(), +}); +export type MapsPlacePhotoResult = z.infer; + +export const mapsReverseResultSchema = z.object({ + name: z.string().nullable(), + address: z.string().nullable(), +}); +export type MapsReverseResult = z.infer; + +export const mapsResolveUrlResultSchema = z.object({ + lat: z.number(), + lng: z.number(), + name: z.string().nullable(), + address: z.string().nullable(), +}); +export type MapsResolveUrlResult = z.infer; diff --git a/shared/src/notification/notification.schema.spec.ts b/shared/src/notification/notification.schema.spec.ts new file mode 100644 index 0000000000000000000000000000000000000000..d425eccdb120113748e44a83cbc7b33dd163b174 --- /dev/null +++ b/shared/src/notification/notification.schema.spec.ts @@ -0,0 +1,59 @@ +import { + preferencesUpdateRequestSchema, + notificationRespondRequestSchema, + channelTestResultSchema, + inAppListResultSchema, +} from './notification.schema'; + +import { describe, it, expect } from 'vitest'; + +describe('preferencesUpdateRequestSchema', () => { + it('accepts a nested event/channel/enabled matrix', () => { + expect( + preferencesUpdateRequestSchema.safeParse({ + trip_invite: { inapp: true, email: false }, + }).success, + ).toBe(true); + expect( + preferencesUpdateRequestSchema.safeParse({ + trip_invite: { inapp: 'yes' }, + }).success, + ).toBe(false); + }); +}); + +describe('notificationRespondRequestSchema', () => { + it('only accepts positive/negative', () => { + expect( + notificationRespondRequestSchema.safeParse({ response: 'positive' }) + .success, + ).toBe(true); + expect( + notificationRespondRequestSchema.safeParse({ response: 'maybe' }).success, + ).toBe(false); + }); +}); + +describe('channelTestResultSchema', () => { + it('accepts a success result and an error result', () => { + expect(channelTestResultSchema.safeParse({ success: true }).success).toBe( + true, + ); + expect( + channelTestResultSchema.safeParse({ success: false, error: 'SMTP down' }) + .success, + ).toBe(true); + }); +}); + +describe('inAppListResultSchema', () => { + it('accepts the list envelope with open notification rows', () => { + expect( + inAppListResultSchema.safeParse({ + notifications: [{ id: 1, type: 'info', anything: 'goes' }], + total: 1, + unread_count: 0, + }).success, + ).toBe(true); + }); +}); diff --git a/shared/src/notification/notification.schema.ts b/shared/src/notification/notification.schema.ts new file mode 100644 index 0000000000000000000000000000000000000000..129c85f1c3da85deba5b6195e9df0044f7882129 --- /dev/null +++ b/shared/src/notification/notification.schema.ts @@ -0,0 +1,61 @@ +import { z } from 'zod'; + +/** + * Notification API contract — single source of truth for the /api/notifications + * endpoints (channel-preference matrix, channel test pings, and in-app + * notifications). + * + * The notification row and the preferences matrix are wide, DB- and + * registry-derived shapes; the response schemas keep them as open records and + * pin the stable envelope fields, while the request schemas and the bespoke + * 400/403/404 controller messages capture the parts the client depends on. + * Real-time delivery happens over the existing WebSocket path inside the + * services and is untouched by this contract. + */ + +/** Channel preference matrix update: { eventType: { channel: enabled } }. */ +export const preferencesUpdateRequestSchema = z.record( + z.string(), + z.record(z.string(), z.boolean()), +); +export type PreferencesUpdateRequest = z.infer< + typeof preferencesUpdateRequestSchema +>; + +export const testSmtpRequestSchema = z.object({ email: z.string().optional() }); +export const testWebhookRequestSchema = z.object({ + url: z.string().optional(), +}); +export const testNtfyRequestSchema = z.object({ + topic: z.string().optional(), + server: z.string().optional(), + token: z.string().optional(), +}); + +/** Result of a channel test ping. */ +export const channelTestResultSchema = z.object({ + success: z.boolean(), + error: z.string().optional(), +}); +export type ChannelTestResult = z.infer; + +/** Respond to a boolean (yes/no) notification. */ +export const notificationRespondRequestSchema = z.object({ + response: z.enum(['positive', 'negative']), +}); +export type NotificationRespondRequest = z.infer< + typeof notificationRespondRequestSchema +>; + +/** A single in-app notification row (DB-shaped; kept open). */ +export const notificationRowSchema = z.record(z.string(), z.unknown()); + +export const inAppListResultSchema = z.object({ + notifications: z.array(notificationRowSchema), + total: z.number(), + unread_count: z.number(), +}); +export type InAppListResult = z.infer; + +export const unreadCountResultSchema = z.object({ count: z.number() }); +export type UnreadCountResult = z.infer; diff --git a/shared/src/oauth/oauth.schema.spec.ts b/shared/src/oauth/oauth.schema.spec.ts new file mode 100644 index 0000000000000000000000000000000000000000..5bb0ff5f91c8dbe82e3ac132b162326a7b8341f4 --- /dev/null +++ b/shared/src/oauth/oauth.schema.spec.ts @@ -0,0 +1,71 @@ +import { + oauthTokenRequestSchema, + oauthConsentRequestSchema, + oauthClientCreateRequestSchema, +} from './oauth.schema'; + +import { describe, it, expect } from 'vitest'; + +describe('oauthTokenRequestSchema', () => { + it('is permissive across grant types and passes extras through', () => { + expect( + oauthTokenRequestSchema.safeParse({ + grant_type: 'authorization_code', + client_id: 'c', + code: 'x', + redirect_uri: 'u', + code_verifier: 'v', + }).success, + ).toBe(true); + expect( + oauthTokenRequestSchema.safeParse({ + grant_type: 'client_credentials', + client_id: 'c', + client_secret: 's', + scope: 'a b', + }).success, + ).toBe(true); + expect(oauthTokenRequestSchema.safeParse({}).success).toBe(true); + }); +}); + +describe('oauthConsentRequestSchema', () => { + it('requires the PKCE consent fields + approved flag', () => { + expect( + oauthConsentRequestSchema.safeParse({ + client_id: 'c', + redirect_uri: 'u', + scope: 's', + code_challenge: 'cc', + code_challenge_method: 'S256', + approved: true, + }).success, + ).toBe(true); + expect( + oauthConsentRequestSchema.safeParse({ + client_id: 'c', + redirect_uri: 'u', + scope: 's', + code_challenge: 'cc', + code_challenge_method: 'S256', + }).success, + ).toBe(false); + }); +}); + +describe('oauthClientCreateRequestSchema', () => { + it('requires name + allowed_scopes', () => { + expect( + oauthClientCreateRequestSchema.safeParse({ + name: 'CLI', + allowed_scopes: ['trips:read'], + }).success, + ).toBe(true); + expect( + oauthClientCreateRequestSchema.safeParse({ name: 'CLI' }).success, + ).toBe(false); + expect( + oauthClientCreateRequestSchema.safeParse({ allowed_scopes: [] }).success, + ).toBe(false); + }); +}); diff --git a/shared/src/oauth/oauth.schema.ts b/shared/src/oauth/oauth.schema.ts new file mode 100644 index 0000000000000000000000000000000000000000..14438eb9ea21b2e29c1b79278ce0f18c9a8b2ed1 --- /dev/null +++ b/shared/src/oauth/oauth.schema.ts @@ -0,0 +1,46 @@ +import { z } from 'zod'; + +/** + * OAuth 2.1 server contract for /oauth/* (public) + /api/oauth/* (SPA). + * + * The token endpoint accepts JSON or form-encoded bodies across three grant + * types, so its body stays permissive (the service enforces grant-specific + * rules + the RFC error codes). These schemas pin the consent submit and the + * client-create body the SPA sends. + */ +export const oauthTokenRequestSchema = z + .object({ + grant_type: z.string().optional(), + client_id: z.string().optional(), + client_secret: z.string().optional(), + code: z.string().optional(), + redirect_uri: z.string().optional(), + code_verifier: z.string().optional(), + refresh_token: z.string().optional(), + scope: z.string().optional(), + resource: z.string().optional(), + }) + .passthrough(); +export type OauthTokenRequest = z.infer; + +export const oauthConsentRequestSchema = z.object({ + client_id: z.string(), + redirect_uri: z.string(), + scope: z.string(), + state: z.string().optional(), + code_challenge: z.string(), + code_challenge_method: z.string(), + approved: z.boolean(), + resource: z.string().optional(), +}); +export type OauthConsentRequest = z.infer; + +export const oauthClientCreateRequestSchema = z.object({ + name: z.string().min(1), + redirect_uris: z.array(z.string()).optional(), + allowed_scopes: z.array(z.string()), + allows_client_credentials: z.boolean().optional(), +}); +export type OauthClientCreateRequest = z.infer< + typeof oauthClientCreateRequestSchema +>; diff --git a/shared/src/oidc/oidc.schema.spec.ts b/shared/src/oidc/oidc.schema.spec.ts new file mode 100644 index 0000000000000000000000000000000000000000..dc180f819a5526f2ffc986faba1fe656756c6161 --- /dev/null +++ b/shared/src/oidc/oidc.schema.spec.ts @@ -0,0 +1,25 @@ +import { + oidcCallbackQuerySchema, + oidcExchangeQuerySchema, +} from './oidc.schema'; + +import { describe, it, expect } from 'vitest'; + +describe('oidcCallbackQuerySchema', () => { + it('accepts code+state, an error, or nothing (all optional)', () => { + expect( + oidcCallbackQuerySchema.safeParse({ code: 'c', state: 's' }).success, + ).toBe(true); + expect( + oidcCallbackQuerySchema.safeParse({ error: 'access_denied' }).success, + ).toBe(true); + expect(oidcCallbackQuerySchema.safeParse({}).success).toBe(true); + }); +}); + +describe('oidcExchangeQuerySchema', () => { + it('requires a code', () => { + expect(oidcExchangeQuerySchema.safeParse({ code: 'c' }).success).toBe(true); + expect(oidcExchangeQuerySchema.safeParse({}).success).toBe(false); + }); +}); diff --git a/shared/src/oidc/oidc.schema.ts b/shared/src/oidc/oidc.schema.ts new file mode 100644 index 0000000000000000000000000000000000000000..bbbaa84851ccbc9322c948ed065c10d2f253ac91 --- /dev/null +++ b/shared/src/oidc/oidc.schema.ts @@ -0,0 +1,21 @@ +import { z } from 'zod'; + +/** + * OIDC SSO contract for /api/auth/oidc. + * + * The flow is redirect-based and carries no request bodies — inputs arrive as + * query params (the provider callback's code/state/error, the optional invite on + * /login, and the auth-code on /exchange). These schemas pin those query shapes; + * the cryptographic verification + provisioning live in the OIDC service. + */ +export const oidcCallbackQuerySchema = z.object({ + code: z.string().optional(), + state: z.string().optional(), + error: z.string().optional(), +}); +export type OidcCallbackQuery = z.infer; + +export const oidcExchangeQuerySchema = z.object({ + code: z.string(), +}); +export type OidcExchangeQuery = z.infer; diff --git a/shared/src/packing/packing.schema.spec.ts b/shared/src/packing/packing.schema.spec.ts new file mode 100644 index 0000000000000000000000000000000000000000..0b221c5cfc09968371986ecc5341f7c679e05431 --- /dev/null +++ b/shared/src/packing/packing.schema.spec.ts @@ -0,0 +1,56 @@ +import { + packingCreateItemRequestSchema, + packingImportRequestSchema, + packingCreateBagRequestSchema, + packingSaveTemplateRequestSchema, +} from './packing.schema'; + +import { describe, it, expect } from 'vitest'; + +describe('packingCreateItemRequestSchema', () => { + it('requires a non-empty name; category/checked optional', () => { + expect( + packingCreateItemRequestSchema.safeParse({ name: 'Socks' }).success, + ).toBe(true); + expect( + packingCreateItemRequestSchema.safeParse({ + name: 'Socks', + category: 'Clothes', + checked: true, + }).success, + ).toBe(true); + expect(packingCreateItemRequestSchema.safeParse({ name: '' }).success).toBe( + false, + ); + }); +}); + +describe('packingImportRequestSchema', () => { + it('accepts an array of open item rows', () => { + expect( + packingImportRequestSchema.safeParse({ + items: [{ name: 'a' }, { name: 'b', anything: 1 }], + }).success, + ).toBe(true); + }); +}); + +describe('packingCreateBagRequestSchema', () => { + it('requires a name', () => { + expect( + packingCreateBagRequestSchema.safeParse({ name: 'Carry-on' }).success, + ).toBe(true); + expect(packingCreateBagRequestSchema.safeParse({}).success).toBe(false); + }); +}); + +describe('packingSaveTemplateRequestSchema', () => { + it('requires a name', () => { + expect( + packingSaveTemplateRequestSchema.safeParse({ name: 'Summer' }).success, + ).toBe(true); + expect( + packingSaveTemplateRequestSchema.safeParse({ name: '' }).success, + ).toBe(false); + }); +}); diff --git a/shared/src/packing/packing.schema.ts b/shared/src/packing/packing.schema.ts new file mode 100644 index 0000000000000000000000000000000000000000..826bf5ed24c0727af4438f2880b37c0e7973dfe9 --- /dev/null +++ b/shared/src/packing/packing.schema.ts @@ -0,0 +1,150 @@ +import { z } from 'zod'; + +/** + * Packing API contract — single source of truth for the + * /api/trips/:tripId/packing endpoints (items, bags, templates, assignees). + * + * Trip-scoped: every endpoint verifies trip access (404 "Trip not found") and + * mutations additionally check the 'packing_edit' permission (403 "No + * permission"). The legacy route (server/src/routes/packing.ts) wraps + * services/packingService.ts; rows are DB-shaped and kept as open records here. + * Mutations broadcast over WebSocket using the forwarded X-Socket-Id. + */ + +const open = z.record(z.string(), z.unknown()); + +/** + * Packing item entity as returned by the packing endpoints + * (server/src/services/packingService.ts -> SELECT * FROM packing_items). + * `checked` is the raw SQLite INTEGER (0/1). Columns match the packing_items + * table (see server DB): weight_grams/bag_id are nullable, quantity defaults 1. + */ +export const packingItemSchema = z.object({ + id: z.number(), + trip_id: z.number(), + name: z.string(), + checked: z.number(), + category: z.string().nullable().optional(), + sort_order: z.number(), + weight_grams: z.number().nullable().optional(), + bag_id: z.number().nullable().optional(), + quantity: z.number().optional(), + created_at: z.string().optional(), +}); +export type PackingItem = z.infer; + +/** + * Packing bag member embedded on a bag (server packingService -> listBags). + * `avatar` is the resolved avatar URL. + */ +export const packingBagMemberSchema = z.object({ + user_id: z.number(), + username: z.string(), + avatar: z.string().nullable().optional(), +}); +export type PackingBagMember = z.infer; + +/** + * Packing bag entity (server packingService -> listBags). Columns of the + * packing_bags table plus the embedded `members` array (and the optional + * `assigned_username` join present on updateBag). + */ +export const packingBagSchema = z.object({ + id: z.number(), + trip_id: z.number(), + name: z.string(), + color: z.string(), + weight_limit_grams: z.number().nullable().optional(), + sort_order: z.number(), + user_id: z.number().nullable().optional(), + assigned_username: z.string().nullable().optional(), + created_at: z.string().optional(), + members: z.array(packingBagMemberSchema).optional(), +}); +export type PackingBag = z.infer; + +export const packingCreateItemRequestSchema = z.object({ + name: z.string().min(1), + category: z.string().optional(), + checked: z.boolean().optional(), +}); +export type PackingCreateItemRequest = z.infer< + typeof packingCreateItemRequestSchema +>; + +export const packingUpdateItemRequestSchema = z.object({ + name: z.string().optional(), + checked: z.boolean().optional(), + category: z.string().optional(), + weight_grams: z.number().nullable().optional(), + bag_id: z.number().nullable().optional(), + quantity: z.number().optional(), +}); +export type PackingUpdateItemRequest = z.infer< + typeof packingUpdateItemRequestSchema +>; + +export const packingImportRequestSchema = z.object({ + items: z.array(open), +}); +export type PackingImportRequest = z.infer; + +export const packingReorderRequestSchema = z.object({ + orderedIds: z.array(z.number()), +}); +export type PackingReorderRequest = z.infer; + +export const packingCreateBagRequestSchema = z.object({ + name: z.string().min(1), + color: z.string().optional(), +}); +export type PackingCreateBagRequest = z.infer< + typeof packingCreateBagRequestSchema +>; + +export const packingUpdateBagRequestSchema = z.object({ + name: z.string().optional(), + color: z.string().optional(), + weight_limit_grams: z.number().nullable().optional(), + user_id: z.number().nullable().optional(), +}); +export type PackingUpdateBagRequest = z.infer< + typeof packingUpdateBagRequestSchema +>; + +export const packingBagMembersRequestSchema = z.object({ + user_ids: z.array(z.number()), +}); +export type PackingBagMembersRequest = z.infer< + typeof packingBagMembersRequestSchema +>; + +export const packingSaveTemplateRequestSchema = z.object({ + name: z.string().min(1), +}); +export type PackingSaveTemplateRequest = z.infer< + typeof packingSaveTemplateRequestSchema +>; + +export const packingTemplateSummarySchema = z.object({ + id: z.number(), + name: z.string(), + item_count: z.number(), +}); +export type PackingTemplateSummary = z.infer< + typeof packingTemplateSummarySchema +>; + +export const packingTemplatesResponseSchema = z.object({ + templates: z.array(packingTemplateSummarySchema), +}); +export type PackingTemplatesResponse = z.infer< + typeof packingTemplatesResponseSchema +>; + +export const packingCategoryAssigneesRequestSchema = z.object({ + user_ids: z.array(z.number()), +}); +export type PackingCategoryAssigneesRequest = z.infer< + typeof packingCategoryAssigneesRequestSchema +>; diff --git a/shared/src/place/place.schema.spec.ts b/shared/src/place/place.schema.spec.ts new file mode 100644 index 0000000000000000000000000000000000000000..f7c40f089f5e06c26aa35b4f6d7a332545de9b46 --- /dev/null +++ b/shared/src/place/place.schema.spec.ts @@ -0,0 +1,43 @@ +import { + placeCreateRequestSchema, + placeBulkDeleteRequestSchema, + placeImportListRequestSchema, +} from './place.schema'; + +import { describe, it, expect } from 'vitest'; + +describe('placeCreateRequestSchema', () => { + it('requires a name and keeps the other place fields open', () => { + expect( + placeCreateRequestSchema.safeParse({ + name: 'Spot', + lat: 1, + lng: 2, + anything: true, + }).success, + ).toBe(true); + expect(placeCreateRequestSchema.safeParse({ lat: 1 }).success).toBe(false); + }); +}); + +describe('placeBulkDeleteRequestSchema', () => { + it('requires a numeric ids array', () => { + expect( + placeBulkDeleteRequestSchema.safeParse({ ids: [1, 2] }).success, + ).toBe(true); + expect(placeBulkDeleteRequestSchema.safeParse({ ids: ['a'] }).success).toBe( + false, + ); + }); +}); + +describe('placeImportListRequestSchema', () => { + it('requires a non-empty url', () => { + expect( + placeImportListRequestSchema.safeParse({ url: 'http://x' }).success, + ).toBe(true); + expect(placeImportListRequestSchema.safeParse({ url: '' }).success).toBe( + false, + ); + }); +}); diff --git a/shared/src/place/place.schema.ts b/shared/src/place/place.schema.ts new file mode 100644 index 0000000000000000000000000000000000000000..b61c9cb60c7968dd005d097a3785071840f79cd8 --- /dev/null +++ b/shared/src/place/place.schema.ts @@ -0,0 +1,134 @@ +import { tagSchema } from '../tag/tag.schema'; + +import { z } from 'zod'; + +/** + * Place API contract — single source of truth for the /api/trips/:tripId/places + * endpoints (place pool CRUD, GPX/map/list imports, image search, bulk delete). + * + * Trip-scoped; mutations use the 'place_edit' permission. The legacy route + * (server/src/routes/places.ts) wraps placeService and fires the journey + * place-created/updated/deleted hooks. Place rows are wide and provider-derived, + * so create/update payloads stay mostly open with `name` pinned; string fields + * are capped (name 200, description 2000, address 500, notes 2000) by the legacy + * validateStringLengths, reproduced in the controller. + */ + +const open = z.record(z.string(), z.unknown()); + +/** + * Embedded category as returned on a place — a trimmed projection of the + * categories row (id/name/color/icon), built inline by placeService and + * getPlaceWithTags. `null` when the place has no category_id. + */ +export const placeCategorySchema = z + .object({ + id: z.number(), + name: z.string().nullable(), + color: z.string().nullable(), + icon: z.string().nullable(), + }) + .nullable(); +export type PlaceCategory = z.infer; + +/** + * Full place entity as returned by the place list / get / create / update + * endpoints (server/src/services/placeService.ts -> getPlaceWithTags). All + * columns of the `places` table (see server/data DB) plus the joined `category` + * projection and `tags` array. Numbers (lat/lng/price) are SQLite REAL, ids are + * INTEGER; provider-derived columns are nullable. + */ +export const placeSchema = z.object({ + id: z.number(), + trip_id: z.number(), + name: z.string(), + description: z.string().nullable().optional(), + lat: z.number().nullable().optional(), + lng: z.number().nullable().optional(), + address: z.string().nullable().optional(), + category_id: z.number().nullable().optional(), + price: z.number().nullable().optional(), + currency: z.string().nullable().optional(), + reservation_status: z.string().nullable().optional(), + reservation_notes: z.string().nullable().optional(), + reservation_datetime: z.string().nullable().optional(), + place_time: z.string().nullable().optional(), + end_time: z.string().nullable().optional(), + duration_minutes: z.number().nullable().optional(), + notes: z.string().nullable().optional(), + image_url: z.string().nullable().optional(), + google_place_id: z.string().nullable().optional(), + osm_id: z.string().nullable().optional(), + route_geometry: z.string().nullable().optional(), + website: z.string().nullable().optional(), + phone: z.string().nullable().optional(), + transport_mode: z.string().nullable().optional(), + created_at: z.string().optional(), + updated_at: z.string().optional(), + category: placeCategorySchema.optional(), + tags: z.array(tagSchema.partial()).optional(), +}); +export type Place = z.infer; + +/** + * Trimmed place projection embedded inside a day-assignment response + * (server/src/services/queryHelpers.ts -> formatAssignmentWithPlace). This is a + * SUBSET of the full place: no trip_id / osm_id / route_geometry / created_at / + * reservation_* — only the fields the planner needs to render the itinerary card. + */ +export const assignmentPlaceSchema = z.object({ + id: z.number(), + name: z.string(), + description: z.string().nullable().optional(), + lat: z.number().nullable().optional(), + lng: z.number().nullable().optional(), + address: z.string().nullable().optional(), + category_id: z.number().nullable().optional(), + price: z.number().nullable().optional(), + currency: z.string().nullable().optional(), + place_time: z.string().nullable().optional(), + end_time: z.string().nullable().optional(), + duration_minutes: z.number().nullable().optional(), + notes: z.string().nullable().optional(), + image_url: z.string().nullable().optional(), + transport_mode: z.string().nullable().optional(), + google_place_id: z.string().nullable().optional(), + website: z.string().nullable().optional(), + phone: z.string().nullable().optional(), + category: placeCategorySchema.optional(), + tags: z.array(tagSchema.partial()).optional(), +}); +export type AssignmentPlace = z.infer; + +export const placeCreateRequestSchema = open.and( + z.object({ name: z.string().min(1) }), +); +export type PlaceCreateRequest = z.infer; + +export const placeUpdateRequestSchema = open; +export type PlaceUpdateRequest = z.infer; + +export const placeBulkDeleteRequestSchema = z.object({ + ids: z.array(z.number()), +}); +export type PlaceBulkDeleteRequest = z.infer< + typeof placeBulkDeleteRequestSchema +>; + +export const placeImportListRequestSchema = z.object({ + url: z.string().min(1), + // Opt-in: enrich imported places via the Places API (#886). Requires a Google + // Maps key; runs as a background pass after the import returns. + enrich: z.boolean().optional(), +}); +export type PlaceImportListRequest = z.infer< + typeof placeImportListRequestSchema +>; + +/** Query filters for the place list. */ +export const placeListQuerySchema = z.object({ + search: z.string().optional(), + category: z.string().optional(), + tag: z.string().optional(), +}); +export type PlaceListQuery = z.infer; diff --git a/shared/src/reservation/reservation.schema.spec.ts b/shared/src/reservation/reservation.schema.spec.ts new file mode 100644 index 0000000000000000000000000000000000000000..d2fb7bd20265693a4e4a2c4c3b9d353b6af86d4d --- /dev/null +++ b/shared/src/reservation/reservation.schema.spec.ts @@ -0,0 +1,52 @@ +import { + reservationCreateRequestSchema, + reservationPositionsRequestSchema, + accommodationCreateRequestSchema, +} from './reservation.schema'; + +import { describe, it, expect } from 'vitest'; + +describe('reservationCreateRequestSchema', () => { + it('requires a title and keeps the other booking fields open', () => { + expect( + reservationCreateRequestSchema.safeParse({ + title: 'Hotel', + anything: 1, + metadata: {}, + }).success, + ).toBe(true); + expect( + reservationCreateRequestSchema.safeParse({ location: 'x' }).success, + ).toBe(false); + }); +}); + +describe('reservationPositionsRequestSchema', () => { + it('requires positions with id + day_plan_position', () => { + expect( + reservationPositionsRequestSchema.safeParse({ + positions: [{ id: 1, day_plan_position: 0 }], + day_id: 3, + }).success, + ).toBe(true); + expect( + reservationPositionsRequestSchema.safeParse({ positions: [{ id: 1 }] }) + .success, + ).toBe(false); + }); +}); + +describe('accommodationCreateRequestSchema', () => { + it('requires place + start/end day; check-in/out optional', () => { + expect( + accommodationCreateRequestSchema.safeParse({ + place_id: 2, + start_day_id: 10, + end_day_id: 11, + }).success, + ).toBe(true); + expect( + accommodationCreateRequestSchema.safeParse({ place_id: 2 }).success, + ).toBe(false); + }); +}); diff --git a/shared/src/reservation/reservation.schema.ts b/shared/src/reservation/reservation.schema.ts new file mode 100644 index 0000000000000000000000000000000000000000..5a6d090d443b5fafd4cbdc18d8e10f7006c402fe --- /dev/null +++ b/shared/src/reservation/reservation.schema.ts @@ -0,0 +1,212 @@ +import { z } from 'zod'; + +/** + * Reservation + accommodation API contract — single source of truth for the + * /api/trips/:tripId/reservations and /api/trips/:tripId/accommodations endpoints. + * + * Trip-scoped. Reservations use the 'reservation_edit' permission; accommodations + * use 'day_edit' (they live in the day/accommodation service). The legacy routes + * (server/src/routes/reservations.ts + the accommodations sub-router in + * routes/days.ts) carry several side effects — auto-creating/updating/deleting a + * linked budget item, accommodation broadcasts and booking notifications — which + * the Nest service reproduces 1:1. Reservation bodies are wide and provider-ish, + * so the create/update payloads stay mostly open with `title` pinned. + */ + +const open = z.record(z.string(), z.unknown()); + +/** + * A reservation endpoint (flight/train leg terminal) — row of the + * reservation_endpoints table (server/src/services/reservationService.ts). + */ +export const reservationEndpointSchema = z.object({ + id: z.number().optional(), + reservation_id: z.number().optional(), + role: z.enum(['from', 'to', 'stop']), + sequence: z.number(), + name: z.string(), + code: z.string().nullable(), + lat: z.number(), + lng: z.number(), + timezone: z.string().nullable(), + local_time: z.string().nullable(), + local_date: z.string().nullable(), +}); +export type ReservationEndpoint = z.infer; + +/** + * Reservation entity as returned by the reservation list endpoint + * (server/src/services/reservationService.ts -> listReservations). Columns of + * the `reservations` table plus the joined day_number / place_name / linked + * accommodation fields and the computed `day_positions` + `endpoints`. + * `accommodation_id` is stored as TEXT in the DB. + */ +export const reservationSchema = z.object({ + id: z.number(), + trip_id: z.number(), + day_id: z.number().nullable().optional(), + end_day_id: z.number().nullable().optional(), + place_id: z.number().nullable().optional(), + assignment_id: z.number().nullable().optional(), + title: z.string(), + reservation_time: z.string().nullable().optional(), + reservation_end_time: z.string().nullable().optional(), + location: z.string().nullable().optional(), + confirmation_number: z.string().nullable().optional(), + notes: z.string().nullable().optional(), + status: z.string(), + type: z.string(), + accommodation_id: z.union([z.number(), z.string()]).nullable().optional(), + metadata: z.string().nullable().optional(), + needs_review: z.number().optional(), + day_plan_position: z.number().nullable().optional(), + created_at: z.string().optional(), + // AirTrail (or future provider) linkage — drives the "synced" badge (#214). + external_source: z.string().nullable().optional(), + external_id: z.string().nullable().optional(), + external_owner_user_id: z.number().nullable().optional(), + external_synced_at: z.string().nullable().optional(), + sync_enabled: z.number().nullable().optional(), + // joined / computed in listReservations + day_number: z.number().nullable().optional(), + place_name: z.string().nullable().optional(), + accommodation_place_id: z.number().nullable().optional(), + accommodation_name: z.string().nullable().optional(), + accommodation_start_day_id: z.number().nullable().optional(), + accommodation_end_day_id: z.number().nullable().optional(), + day_positions: z.record(z.string(), z.number()).nullable().optional(), + endpoints: z.array(reservationEndpointSchema).optional(), +}); +export type Reservation = z.infer; + +/** + * Accommodation entity as returned by listAccommodations / getAccommodationWithPlace + * (server/src/services/dayService.ts). Columns of the day_accommodations table + * plus the joined place fields and (on list) the linked reservation_title. + */ +export const accommodationSchema = z.object({ + id: z.number(), + trip_id: z.number(), + place_id: z.number().nullable().optional(), + start_day_id: z.number(), + end_day_id: z.number(), + check_in: z.string().nullable().optional(), + check_in_end: z.string().nullable().optional(), + check_out: z.string().nullable().optional(), + confirmation: z.string().nullable().optional(), + notes: z.string().nullable().optional(), + created_at: z.string().optional(), + // joined in listAccommodations / getAccommodationWithPlace + place_name: z.string().nullable().optional(), + place_address: z.string().nullable().optional(), + place_image: z.string().nullable().optional(), + place_lat: z.number().nullable().optional(), + place_lng: z.number().nullable().optional(), + reservation_title: z.string().nullable().optional(), +}); +export type Accommodation = z.infer; + +/** Reservation create: title is required; the many optional fields stay open. */ +export const reservationCreateRequestSchema = open.and( + z.object({ title: z.string().min(1) }), +); +export type ReservationCreateRequest = z.infer< + typeof reservationCreateRequestSchema +>; + +export const reservationUpdateRequestSchema = open; +export type ReservationUpdateRequest = z.infer< + typeof reservationUpdateRequestSchema +>; + +export const reservationPositionsRequestSchema = z.object({ + positions: z.array( + z.object({ id: z.number(), day_plan_position: z.number() }), + ), + day_id: z.union([z.number(), z.string()]).nullable().optional(), +}); +export type ReservationPositionsRequest = z.infer< + typeof reservationPositionsRequestSchema +>; + +export const accommodationCreateRequestSchema = z.object({ + place_id: z.union([z.number(), z.string()]), + start_day_id: z.union([z.number(), z.string()]), + end_day_id: z.union([z.number(), z.string()]), + check_in: z.string().nullable().optional(), + check_in_end: z.string().nullable().optional(), + check_out: z.string().nullable().optional(), + confirmation: z.string().nullable().optional(), + notes: z.string().nullable().optional(), +}); +export type AccommodationCreateRequest = z.infer< + typeof accommodationCreateRequestSchema +>; + +export const accommodationUpdateRequestSchema = open; +export type AccommodationUpdateRequest = z.infer< + typeof accommodationUpdateRequestSchema +>; + +// --------------------------------------------------------------------------- +// Booking import (KItinerary) +// --------------------------------------------------------------------------- + +const bookingImportEndpointSchema = z.object({ + role: z.enum(['from', 'to', 'stop']), + sequence: z.number(), + name: z.string(), + code: z.string().nullable(), + lat: z.number(), + lng: z.number(), + timezone: z.string().nullable(), + local_time: z.string().nullable(), + local_date: z.string().nullable(), +}); + +const bookingImportVenueSchema = z.object({ + name: z.string(), + lat: z.number().optional(), + lng: z.number().optional(), + address: z.string().optional(), + website: z.string().optional(), + phone: z.string().optional(), +}); + +const bookingImportAccommodationSchema = z.object({ + check_in: z.string().optional(), + check_out: z.string().optional(), + confirmation: z.string().optional(), +}); + +export const bookingImportPreviewItemSchema = z.object({ + type: z.string(), + title: z.string().min(1), + reservation_time: z.string().nullable().optional(), + reservation_end_time: z.string().nullable().optional(), + confirmation_number: z.string().nullable().optional(), + location: z.string().nullable().optional(), + metadata: z.record(z.string(), z.unknown()).optional(), + endpoints: z.array(bookingImportEndpointSchema).optional(), + needs_review: z.boolean().optional(), + _venue: bookingImportVenueSchema.optional(), + _accommodation: bookingImportAccommodationSchema.optional(), + source: z.object({ fileName: z.string(), index: z.number() }), +}); +export type BookingImportPreviewItem = z.infer; + +export const bookingImportPreviewResponseSchema = z.object({ + items: z.array(bookingImportPreviewItemSchema), + warnings: z.array(z.string()), +}); +export type BookingImportPreviewResponse = z.infer; + +export const bookingImportConfirmRequestSchema = z.object({ + items: z.array(bookingImportPreviewItemSchema).min(1), +}); +export type BookingImportConfirmRequest = z.infer; + +export const bookingImportConfirmResponseSchema = z.object({ + created: z.array(reservationSchema), +}); +export type BookingImportConfirmResponse = z.infer; diff --git a/shared/src/sanitize/sanitize.spec.ts b/shared/src/sanitize/sanitize.spec.ts new file mode 100644 index 0000000000000000000000000000000000000000..27eb19ac5b610d1436771fbc1878be35f2f45edf --- /dev/null +++ b/shared/src/sanitize/sanitize.spec.ts @@ -0,0 +1,139 @@ +import { + sanitizeInlineHtml, + sanitizeRichTextHtml, + escapeHtml, +} from './sanitize'; + +import { describe, it, expect } from 'vitest'; + +describe('escapeHtml', () => { + it('escapes the five metacharacters', () => { + expect(escapeHtml(`a & b < c > d " e ' f`)).toBe( + 'a & b < c > d " e ' f', + ); + }); + + it('escapes ampersands first (no double-escape of entities)', () => { + expect(escapeHtml('<')).toBe('&lt;'); + }); + + it('returns empty string for empty input', () => { + expect(escapeHtml('')).toBe(''); + }); + + it('leaves plain ASCII text untouched', () => { + expect(escapeHtml('Paris Adventure 2026')).toBe('Paris Adventure 2026'); + }); + + it('neutralises a script tag without sanitising', () => { + expect(escapeHtml('')).toBe( + '<script>alert(1)</script>', + ); + }); +}); + +describe('sanitizeInlineHtml', () => { + it('returns empty string for empty input', () => { + expect(sanitizeInlineHtml('')).toBe(''); + }); + + it('preserves the allowed inline tags', () => { + expect(sanitizeInlineHtml('a b c')).toBe( + 'a b c', + ); + expect(sanitizeInlineHtml('x')).toBe('x'); + }); + + it('strips text'); + expect(out).not.toContain(' (no img tag in inline allow-list)', () => { + expect(sanitizeInlineHtml('')).toBe(''); + }); + + it('strips on* event handlers from preserved tags', () => { + const out = sanitizeInlineHtml('hi'); + expect(out).not.toContain('onclick'); + expect(out).toContain('hi'); + }); + + it('strips style attribute (CSS-injection surface)', () => { + const out = sanitizeInlineHtml( + 'x', + ); + expect(out).not.toContain('style='); + expect(out).not.toContain('javascript:'); + }); + + it('strips iframe / object / embed / svg-with-script', () => { + expect(sanitizeInlineHtml('')).toBe(''); + expect(sanitizeInlineHtml('')).toBe(''); + expect(sanitizeInlineHtml('')).toBe(''); + expect( + sanitizeInlineHtml(''), + ).not.toContain('script'); + }); + + it('does not preserve href / target on the inline tag set', () => { + // is not in the inline allow-list, so href can never appear here. + const out = sanitizeInlineHtml('x'); + expect(out).toBe('x'); + }); + + it('keeps user text content when the wrapping tag is stripped', () => { + expect(sanitizeInlineHtml('hello')).toBe('hello'); + }); +}); + +describe('sanitizeRichTextHtml', () => { + it('preserves the full prose tag set', () => { + const html = '

hello world

  • one
'; + const out = sanitizeRichTextHtml(html); + expect(out).toContain('

'); + expect(out).toContain('world'); + expect(out).toContain('

  • one
  • '); + }); + + it('still strips ', + ); + expect(out).not.toContain('onclick'); + expect(out).not.toContain('style='); + expect(out).not.toContain(' { + const out = sanitizeRichTextHtml('x'); + expect(out).not.toContain('javascript:'); + }); + + it('blocks data: hrefs that smuggle scripts', () => { + const out = sanitizeRichTextHtml( + 'x', + ); + expect(out).not.toContain('data:text/html'); + }); + + it('keeps http(s) hrefs intact', () => { + const out = sanitizeRichTextHtml('link'); + expect(out).toContain('href="https://example.com"'); + }); + + it('strips disallowed tags but keeps their content', () => { + expect( + sanitizeRichTextHtml('

    beforemiddleafter

    '), + ).toContain('middle'); + }); + + it('drops mathml + svg shorthand vectors', () => { + const mathPayload = ''; + const out = sanitizeRichTextHtml(mathPayload); + expect(out).not.toContain('/g, '>') + .replace(/"/g, '"') + .replace(/'/g, '''); +} + +/** + * Strict inline sanitiser. Use for short, mostly-text strings that may include + * basic emphasis (``, ``, …) — e.g. the Journey suggestion banner + * where a translated template embeds a user-controlled trip title. + * + * Drops every tag outside the inline allow-list, strips all attributes, and + * blocks every URL scheme except http/https/mailto/tel via DOMPurify's + * built-in URL allow-list. + */ +export function sanitizeInlineHtml(html: string): string { + if (!html) return ''; + return DOMPurify.sanitize(html, { + ALLOWED_TAGS: [...INLINE_TAGS], + ALLOWED_ATTR: [], + KEEP_CONTENT: true, + ALLOW_DATA_ATTR: false, + }); +} + +/** + * Permissive rich-text sanitiser. Use when a surface legitimately renders a + * prose document (lists, paragraphs, links). Keeps the same tag families as + * the inline sanitiser plus block-level markup and anchors with safe attrs. + */ +export function sanitizeRichTextHtml(html: string): string { + if (!html) return ''; + return DOMPurify.sanitize(html, { + ALLOWED_TAGS: [...FULL_TAGS], + ALLOWED_ATTR: [...SAFE_ATTRIBUTES], + ALLOW_DATA_ATTR: false, + }); +} diff --git a/shared/src/settings/settings.schema.spec.ts b/shared/src/settings/settings.schema.spec.ts new file mode 100644 index 0000000000000000000000000000000000000000..beee0f14b3baffb428e2927e1dda999c530e01ef --- /dev/null +++ b/shared/src/settings/settings.schema.spec.ts @@ -0,0 +1,41 @@ +import { + settingUpsertRequestSchema, + settingsBulkRequestSchema, + MASKED_SETTING_VALUE, +} from './settings.schema'; + +import { describe, it, expect } from 'vitest'; + +describe('settingUpsertRequestSchema', () => { + it('requires a key; value is any/optional', () => { + expect( + settingUpsertRequestSchema.safeParse({ key: 'theme', value: 'dark' }) + .success, + ).toBe(true); + expect(settingUpsertRequestSchema.safeParse({ key: 'theme' }).success).toBe( + true, + ); + expect( + settingUpsertRequestSchema.safeParse({ value: 'dark' }).success, + ).toBe(false); + }); +}); + +describe('settingsBulkRequestSchema', () => { + it('requires a settings record', () => { + expect( + settingsBulkRequestSchema.safeParse({ settings: { a: 1, b: 'x' } }) + .success, + ).toBe(true); + expect(settingsBulkRequestSchema.safeParse({ settings: {} }).success).toBe( + true, + ); + expect(settingsBulkRequestSchema.safeParse({}).success).toBe(false); + }); +}); + +describe('MASKED_SETTING_VALUE', () => { + it('is the bullet sentinel the client echoes for unchanged secrets', () => { + expect(MASKED_SETTING_VALUE).toBe('••••••••'); + }); +}); diff --git a/shared/src/settings/settings.schema.ts b/shared/src/settings/settings.schema.ts new file mode 100644 index 0000000000000000000000000000000000000000..0e56a9d853f95465deaa23e8e8054f293ce5993f --- /dev/null +++ b/shared/src/settings/settings.schema.ts @@ -0,0 +1,22 @@ +import { z } from 'zod'; + +/** + * User-settings API contract — per-user key/value preferences under + * /api/settings (get all, upsert one, bulk upsert). + * + * Values are intentionally untyped (settings hold strings, numbers, booleans + * and small objects). A masked value of '••••••••' on a single upsert is a + * no-op sentinel (the client echoes the masked secret back unchanged). + */ +export const MASKED_SETTING_VALUE = '••••••••'; + +export const settingUpsertRequestSchema = z.object({ + key: z.string().min(1), + value: z.unknown().optional(), +}); +export type SettingUpsertRequest = z.infer; + +export const settingsBulkRequestSchema = z.object({ + settings: z.record(z.string(), z.unknown()), +}); +export type SettingsBulkRequest = z.infer; diff --git a/shared/src/share/share.schema.spec.ts b/shared/src/share/share.schema.spec.ts new file mode 100644 index 0000000000000000000000000000000000000000..b4962a775505c6ab54a47aaa5a1ad45760ed7981 --- /dev/null +++ b/shared/src/share/share.schema.spec.ts @@ -0,0 +1,19 @@ +import { shareLinkRequestSchema } from './share.schema'; + +import { describe, it, expect } from 'vitest'; + +describe('shareLinkRequestSchema', () => { + it('accepts any subset of section toggles (all optional) and an empty body', () => { + expect( + shareLinkRequestSchema.safeParse({ share_map: true, share_budget: false }) + .success, + ).toBe(true); + expect(shareLinkRequestSchema.safeParse({}).success).toBe(true); + }); + + it('rejects a non-boolean toggle', () => { + expect(shareLinkRequestSchema.safeParse({ share_map: 'yes' }).success).toBe( + false, + ); + }); +}); diff --git a/shared/src/share/share.schema.ts b/shared/src/share/share.schema.ts new file mode 100644 index 0000000000000000000000000000000000000000..ab7ac1eaccc70082ac9ed4059ed9102a651b13ba --- /dev/null +++ b/shared/src/share/share.schema.ts @@ -0,0 +1,19 @@ +import { z } from 'zod'; + +/** + * Trip share-link API contract. + * + * Owner/members create a public read-only token for a trip under + * /api/trips/:tripId/share-link (gated by 'share_manage'); anyone can read the + * shared snapshot at /api/shared/:token (no auth). The per-section toggles + * default server-side (map/bookings on, packing/budget/collab off), so every + * field is optional here. + */ +export const shareLinkRequestSchema = z.object({ + share_map: z.boolean().optional(), + share_bookings: z.boolean().optional(), + share_packing: z.boolean().optional(), + share_budget: z.boolean().optional(), + share_collab: z.boolean().optional(), +}); +export type ShareLinkRequest = z.infer; diff --git a/shared/src/system-notice/system-notice.schema.spec.ts b/shared/src/system-notice/system-notice.schema.spec.ts new file mode 100644 index 0000000000000000000000000000000000000000..73f8c9817281d291daf09e3be9a7fb18c7881b9f --- /dev/null +++ b/shared/src/system-notice/system-notice.schema.spec.ts @@ -0,0 +1,78 @@ +import { systemNoticeDtoSchema } from './system-notice.schema'; + +import { describe, it, expect } from 'vitest'; + +describe('systemNoticeDtoSchema', () => { + it('accepts a minimal notice (required fields only)', () => { + const parsed = systemNoticeDtoSchema.parse({ + id: 'welcome', + display: 'modal', + severity: 'info', + titleKey: 'notice.welcome.title', + bodyKey: 'notice.welcome.body', + dismissible: true, + }); + expect(parsed.id).toBe('welcome'); + }); + + it('accepts a rich notice with media, highlights and a nav CTA', () => { + expect( + systemNoticeDtoSchema.safeParse({ + id: 'release', + display: 'banner', + severity: 'warn', + titleKey: 't', + bodyKey: 'b', + dismissible: false, + bodyParams: { version: '3.1' }, + icon: 'sparkles', + media: { src: '/img.png', altKey: 'alt', placement: 'hero' }, + highlights: [{ labelKey: 'h1', iconName: 'check' }], + cta: { kind: 'nav', labelKey: 'open', href: '/whats-new' }, + }).success, + ).toBe(true); + }); + + it('accepts an action CTA with the discriminated-union shape', () => { + expect( + systemNoticeDtoSchema.safeParse({ + id: 'x', + display: 'toast', + severity: 'critical', + titleKey: 't', + bodyKey: 'b', + dismissible: true, + cta: { + kind: 'action', + labelKey: 'do', + actionId: 'reload', + dismissOnAction: true, + }, + }).success, + ).toBe(true); + }); + + it('rejects an unknown display value and a malformed CTA', () => { + expect( + systemNoticeDtoSchema.safeParse({ + id: 'x', + display: 'popup', + severity: 'info', + titleKey: 't', + bodyKey: 'b', + dismissible: true, + }).success, + ).toBe(false); + expect( + systemNoticeDtoSchema.safeParse({ + id: 'x', + display: 'modal', + severity: 'info', + titleKey: 't', + bodyKey: 'b', + dismissible: true, + cta: { kind: 'nav', labelKey: 'open' }, + }).success, + ).toBe(false); + }); +}); diff --git a/shared/src/system-notice/system-notice.schema.ts b/shared/src/system-notice/system-notice.schema.ts new file mode 100644 index 0000000000000000000000000000000000000000..6192a88d3d07bb4daa477a97b7e6ae47c721258c --- /dev/null +++ b/shared/src/system-notice/system-notice.schema.ts @@ -0,0 +1,58 @@ +import { z } from 'zod'; + +/** + * System-notice API contract — the /api/system-notices endpoints. + * + * Notices are server-side announcements (release notes, onboarding hints, ...) + * defined in a static registry. The server evaluates each notice's conditions + * for the current user and returns only the active, non-dismissed ones, sorted + * by priority/severity/date. The DTO sent to the client is the notice minus the + * server-only fields (conditions, publishedAt, version bounds, priority) — see + * SystemNoticeDTO in server/src/systemNotices/types.ts, which this mirrors. + * + * The bespoke 404 `{ error: 'NOTICE_NOT_FOUND' }` body and the 204 dismiss + * response are reproduced in the controller, not derived from this schema. + */ + +export const noticeDisplaySchema = z.enum(['modal', 'banner', 'toast']); +export const noticeSeveritySchema = z.enum(['info', 'warn', 'critical']); + +const noticeMediaSchema = z.object({ + src: z.string(), + srcDark: z.string().optional(), + altKey: z.string(), + placement: z.enum(['hero', 'inline']).optional(), + aspectRatio: z.string().optional(), +}); + +const noticeHighlightSchema = z.object({ + labelKey: z.string(), + iconName: z.string().optional(), +}); + +/** Call-to-action: either a navigation link or an in-app action. */ +const noticeCtaSchema = z.discriminatedUnion('kind', [ + z.object({ kind: z.literal('nav'), labelKey: z.string(), href: z.string() }), + z.object({ + kind: z.literal('action'), + labelKey: z.string(), + actionId: z.string(), + dismissOnAction: z.boolean().optional(), + }), +]); + +/** The client-facing notice (server-evaluated; conditions/versioning stripped). */ +export const systemNoticeDtoSchema = z.object({ + id: z.string(), + display: noticeDisplaySchema, + severity: noticeSeveritySchema, + titleKey: z.string(), + bodyKey: z.string(), + bodyParams: z.record(z.string(), z.string()).optional(), + icon: z.string().optional(), + media: noticeMediaSchema.optional(), + highlights: z.array(noticeHighlightSchema).optional(), + cta: noticeCtaSchema.optional(), + dismissible: z.boolean(), +}); +export type SystemNoticeDto = z.infer; diff --git a/shared/src/tag/tag.schema.spec.ts b/shared/src/tag/tag.schema.spec.ts new file mode 100644 index 0000000000000000000000000000000000000000..3f7c70322cd8fe981fdfa14f8bd0aee30db6a17c --- /dev/null +++ b/shared/src/tag/tag.schema.spec.ts @@ -0,0 +1,35 @@ +import { + tagSchema, + createTagRequestSchema, + updateTagRequestSchema, +} from './tag.schema'; + +import { describe, it, expect } from 'vitest'; + +describe('tagSchema', () => { + it('accepts a full tag', () => { + expect( + tagSchema.safeParse({ + id: 1, + user_id: 5, + name: 'Beach', + color: '#10b981', + }).success, + ).toBe(true); + }); +}); + +describe('createTagRequestSchema', () => { + it('requires a non-empty name; colour optional', () => { + expect(createTagRequestSchema.safeParse({ name: 'Beach' }).success).toBe( + true, + ); + expect(createTagRequestSchema.safeParse({ name: '' }).success).toBe(false); + }); +}); + +describe('updateTagRequestSchema', () => { + it('allows every field to be omitted', () => { + expect(updateTagRequestSchema.safeParse({}).success).toBe(true); + }); +}); diff --git a/shared/src/tag/tag.schema.ts b/shared/src/tag/tag.schema.ts new file mode 100644 index 0000000000000000000000000000000000000000..f82ca85ee500246b438647d5b10cd9cd55aa0ecd --- /dev/null +++ b/shared/src/tag/tag.schema.ts @@ -0,0 +1,41 @@ +import { z } from 'zod'; + +/** + * Tag API contract — single source of truth for the /api/tags endpoints. + * + * Tags are per-user place labels (used for filtering). Unlike categories they + * are NOT admin-gated: every endpoint is scoped to the authenticated user's own + * tags. The legacy route (server/src/routes/tags.ts) wraps services/tagService.ts + * 1:1; update/delete first verify ownership via getTagByIdAndUser, 404ing + * otherwise. + * + * The bespoke 400 ("Tag name is required") and 404 ("Tag not found") messages are + * reproduced in the controller so the bodies stay byte-identical. + */ + +export const tagSchema = z.object({ + id: z.number(), + user_id: z.number(), + name: z.string(), + color: z.string(), + created_at: z.string().optional(), +}); +export type Tag = z.infer; + +export const createTagRequestSchema = z.object({ + name: z.string().min(1), + color: z.string().optional(), +}); +export type CreateTagRequest = z.infer; + +/** Both fields optional — the service COALESCEs each against the stored value. */ +export const updateTagRequestSchema = z.object({ + name: z.string().optional(), + color: z.string().optional(), +}); +export type UpdateTagRequest = z.infer; + +export const tagListResponseSchema = z.object({ + tags: z.array(tagSchema), +}); +export type TagListResponse = z.infer; diff --git a/shared/src/todo/todo.schema.spec.ts b/shared/src/todo/todo.schema.spec.ts new file mode 100644 index 0000000000000000000000000000000000000000..fc2240256d70b793edaadc2ea303a87b7a6cc233 --- /dev/null +++ b/shared/src/todo/todo.schema.spec.ts @@ -0,0 +1,51 @@ +import { + todoCreateItemRequestSchema, + todoUpdateItemRequestSchema, + todoReorderRequestSchema, +} from './todo.schema'; + +import { describe, it, expect } from 'vitest'; + +describe('todoCreateItemRequestSchema', () => { + it('requires a name; metadata optional with the service shapes', () => { + expect( + todoCreateItemRequestSchema.safeParse({ name: 'Book hotel' }).success, + ).toBe(true); + expect( + todoCreateItemRequestSchema.safeParse({ + name: 'X', + due_date: '2026-07-01', + priority: 2, + assigned_user_id: 3, + }).success, + ).toBe(true); + expect(todoCreateItemRequestSchema.safeParse({ name: '' }).success).toBe( + false, + ); + // priority is numeric (matches the service), not a string + expect( + todoCreateItemRequestSchema.safeParse({ name: 'X', priority: 'high' }) + .success, + ).toBe(false); + }); +}); + +describe('todoUpdateItemRequestSchema', () => { + it('allows every field to be omitted and accepts checked', () => { + expect(todoUpdateItemRequestSchema.safeParse({}).success).toBe(true); + expect( + todoUpdateItemRequestSchema.safeParse({ checked: true }).success, + ).toBe(true); + }); +}); + +describe('todoReorderRequestSchema', () => { + it('requires an array of numeric ids', () => { + expect( + todoReorderRequestSchema.safeParse({ orderedIds: [1, 2, 3] }).success, + ).toBe(true); + expect( + todoReorderRequestSchema.safeParse({ orderedIds: ['a'] }).success, + ).toBe(false); + }); +}); diff --git a/shared/src/todo/todo.schema.ts b/shared/src/todo/todo.schema.ts new file mode 100644 index 0000000000000000000000000000000000000000..dab8bef4b2a70d415b1aa15a4a3436610e236ac1 --- /dev/null +++ b/shared/src/todo/todo.schema.ts @@ -0,0 +1,44 @@ +import { z } from 'zod'; + +/** + * To-do API contract — single source of truth for the /api/trips/:tripId/todo + * endpoints (trip task list with categories + assignees). + * + * Trip-scoped like packing: every endpoint verifies trip access (404 "Trip not + * found") and mutations check the same 'packing_edit' permission the legacy route + * uses (403 "No permission"). Rows are DB-shaped and kept open. Mutations + * broadcast over WebSocket with the forwarded X-Socket-Id. + */ + +export const todoCreateItemRequestSchema = z.object({ + name: z.string().min(1), + category: z.string().optional(), + due_date: z.string().optional(), + description: z.string().optional(), + assigned_user_id: z.number().optional(), + priority: z.number().optional(), +}); +export type TodoCreateItemRequest = z.infer; + +export const todoUpdateItemRequestSchema = z.object({ + name: z.string().optional(), + checked: z.boolean().optional(), + category: z.string().optional(), + due_date: z.string().optional(), + description: z.string().optional(), + assigned_user_id: z.number().optional(), + priority: z.number().optional(), +}); +export type TodoUpdateItemRequest = z.infer; + +export const todoReorderRequestSchema = z.object({ + orderedIds: z.array(z.number()), +}); +export type TodoReorderRequest = z.infer; + +export const todoCategoryAssigneesRequestSchema = z.object({ + user_ids: z.array(z.number()), +}); +export type TodoCategoryAssigneesRequest = z.infer< + typeof todoCategoryAssigneesRequestSchema +>; diff --git a/shared/src/trip/trip.schema.spec.ts b/shared/src/trip/trip.schema.spec.ts new file mode 100644 index 0000000000000000000000000000000000000000..84378005803804dcb09526210f40afdbe176eb91 --- /dev/null +++ b/shared/src/trip/trip.schema.spec.ts @@ -0,0 +1,42 @@ +import { + tripCreateRequestSchema, + tripUpdateRequestSchema, + tripAddMemberRequestSchema, +} from './trip.schema'; + +import { describe, it, expect } from 'vitest'; + +describe('tripCreateRequestSchema', () => { + it('requires a title; dates/currency/reminder optional', () => { + expect(tripCreateRequestSchema.safeParse({ title: 'Japan' }).success).toBe( + true, + ); + expect( + tripCreateRequestSchema.safeParse({ + title: 'Japan', + start_date: '2026-07-01', + day_count: 7, + }).success, + ).toBe(true); + expect(tripCreateRequestSchema.safeParse({}).success).toBe(false); + }); +}); + +describe('tripUpdateRequestSchema', () => { + it('is fully partial and accepts is_archived + cover_image', () => { + expect(tripUpdateRequestSchema.safeParse({}).success).toBe(true); + expect( + tripUpdateRequestSchema.safeParse({ is_archived: 1, cover_image: null }) + .success, + ).toBe(true); + }); +}); + +describe('tripAddMemberRequestSchema', () => { + it('requires an identifier', () => { + expect( + tripAddMemberRequestSchema.safeParse({ identifier: 'bob@x.y' }).success, + ).toBe(true); + expect(tripAddMemberRequestSchema.safeParse({}).success).toBe(false); + }); +}); diff --git a/shared/src/trip/trip.schema.ts b/shared/src/trip/trip.schema.ts new file mode 100644 index 0000000000000000000000000000000000000000..1e1db07dacaea213f5fd0495ae6a3163c829dfc2 --- /dev/null +++ b/shared/src/trip/trip.schema.ts @@ -0,0 +1,94 @@ +import { z } from 'zod'; + +/** + * Trip API contract — single source of truth for the /api/trips aggregate-root + * endpoints (list/create/get/update/delete a trip, cover upload, copy, members, + * offline bundle, ICS export). + * + * The aggregate root shares its path with the trip sub-domains (days, places, + * collab, files, ...), so in the strangler it uses EXACT prefixes (`/api/trips|`, + * `/api/trips/:tripId|`) plus the specific sub-route prefixes — never a broad + * `/api/trips`, which would swallow not-yet-migrated nested mounts. The legacy + * route (server/src/routes/trips.ts) wraps tripService and does per-field + * permission checks + audit logging. Trip rows are wide, so responses stay open. + */ + +/** + * Trip entity as returned by the trip list / get / create / update endpoints + * (server/src/services/tripService.ts -> TRIP_SELECT). Columns of the `trips` + * table plus the computed list fields (day_count, place_count, is_owner as 0/1, + * owner_username, shared_count). `is_archived` is the raw SQLite INTEGER. + */ +export const tripSchema = z.object({ + id: z.number(), + user_id: z.number(), + title: z.string(), + description: z.string().nullable().optional(), + start_date: z.string().nullable().optional(), + end_date: z.string().nullable().optional(), + currency: z.string(), + cover_image: z.string().nullable().optional(), + is_archived: z.number(), + reminder_days: z.number(), + created_at: z.string().optional(), + updated_at: z.string().optional(), + // computed in TRIP_SELECT (list/get) + day_count: z.number().optional(), + place_count: z.number().optional(), + is_owner: z.number().optional(), + owner_username: z.string().optional(), + shared_count: z.number().optional(), +}); +export type Trip = z.infer; + +/** + * Trip member as returned by the members endpoint + * (server/src/services/tripService.ts -> listMembers). Owner + collaborators + * share this shape; `avatar_url` is resolved from the stored avatar. + */ +export const tripMemberSchema = z.object({ + id: z.number(), + username: z.string(), + email: z.string().optional(), + avatar: z.string().nullable().optional(), + avatar_url: z.string().nullable().optional(), + role: z.string().optional(), + added_at: z.string().nullable().optional(), + invited_by_username: z.string().nullable().optional(), +}); +export type TripMember = z.infer; + +export const tripCreateRequestSchema = z.object({ + title: z.string().min(1), + description: z.string().nullable().optional(), + start_date: z.string().nullable().optional(), + end_date: z.string().nullable().optional(), + currency: z.string().optional(), + reminder_days: z.number().optional(), + day_count: z.number().optional(), +}); +export type TripCreateRequest = z.infer; + +/** Update is partial; the route runs per-field permission checks on what's present. */ +export const tripUpdateRequestSchema = z.object({ + title: z.string().optional(), + description: z.string().nullable().optional(), + start_date: z.string().nullable().optional(), + end_date: z.string().nullable().optional(), + currency: z.string().optional(), + reminder_days: z.number().optional(), + day_count: z.number().optional(), + is_archived: z.union([z.boolean(), z.number()]).optional(), + cover_image: z.string().nullable().optional(), +}); +export type TripUpdateRequest = z.infer; + +export const tripCopyRequestSchema = z.object({ + title: z.string().optional(), +}); +export type TripCopyRequest = z.infer; + +export const tripAddMemberRequestSchema = z.object({ + identifier: z.string(), +}); +export type TripAddMemberRequest = z.infer; diff --git a/shared/src/vacay/vacay.schema.spec.ts b/shared/src/vacay/vacay.schema.spec.ts new file mode 100644 index 0000000000000000000000000000000000000000..6393c4ad079a1a18b3b1559116f9618f3cdfeeda --- /dev/null +++ b/shared/src/vacay/vacay.schema.spec.ts @@ -0,0 +1,65 @@ +import { + vacayAddHolidayCalendarRequestSchema, + vacayInviteRequestSchema, + vacayToggleEntryRequestSchema, + vacayAddYearRequestSchema, +} from './vacay.schema'; + +import { describe, it, expect } from 'vitest'; + +describe('vacayAddHolidayCalendarRequestSchema', () => { + it('requires a region; label/color/sort_order optional', () => { + expect( + vacayAddHolidayCalendarRequestSchema.safeParse({ region: 'DE-BY' }) + .success, + ).toBe(true); + expect( + vacayAddHolidayCalendarRequestSchema.safeParse({ + region: 'DE-BY', + label: null, + }).success, + ).toBe(true); + expect(vacayAddHolidayCalendarRequestSchema.safeParse({}).success).toBe( + false, + ); + }); +}); + +describe('vacayInviteRequestSchema', () => { + it('accepts a numeric or string user_id', () => { + expect(vacayInviteRequestSchema.safeParse({ user_id: 2 }).success).toBe( + true, + ); + expect(vacayInviteRequestSchema.safeParse({ user_id: '2' }).success).toBe( + true, + ); + expect(vacayInviteRequestSchema.safeParse({}).success).toBe(false); + }); +}); + +describe('vacayToggleEntryRequestSchema', () => { + it('requires a date; target_user_id optional', () => { + expect( + vacayToggleEntryRequestSchema.safeParse({ date: '2026-07-01' }).success, + ).toBe(true); + expect( + vacayToggleEntryRequestSchema.safeParse({ + date: '2026-07-01', + target_user_id: 3, + }).success, + ).toBe(true); + expect(vacayToggleEntryRequestSchema.safeParse({}).success).toBe(false); + }); +}); + +describe('vacayAddYearRequestSchema', () => { + it('accepts a numeric or string year', () => { + expect(vacayAddYearRequestSchema.safeParse({ year: 2027 }).success).toBe( + true, + ); + expect(vacayAddYearRequestSchema.safeParse({ year: '2027' }).success).toBe( + true, + ); + expect(vacayAddYearRequestSchema.safeParse({}).success).toBe(false); + }); +}); diff --git a/shared/src/vacay/vacay.schema.ts b/shared/src/vacay/vacay.schema.ts new file mode 100644 index 0000000000000000000000000000000000000000..1f5d3b41eb459e83a92d6cb6261de660f8cce480 --- /dev/null +++ b/shared/src/vacay/vacay.schema.ts @@ -0,0 +1,78 @@ +import { z } from 'zod'; + +/** + * Vacay API contract — single source of truth for the /api/addons/vacay endpoints + * (shared vacation-day planner: plan, holiday calendars, members/invites, years, + * entries, stats, public-holiday lookups). + * + * Parity note: like atlas, the legacy vacay route is NOT addon-gated at the mount + * (app.ts), so the migration adds no gate. Plan/entry/stats shapes are wide and + * DB-derived, so the response schemas stay open records; the request schemas and + * the bespoke 400/403/404/502 controller messages pin the client-facing parts. + * + * Many mutations carry an `X-Socket-Id` header that the services use to suppress + * the echo broadcast to the originating client — it is forwarded unchanged. + */ + +const open = z.record(z.string(), z.unknown()); + +export const vacayAddHolidayCalendarRequestSchema = z.object({ + region: z.string().min(1), + label: z.string().nullable().optional(), + color: z.string().optional(), + sort_order: z.number().optional(), +}); +export type VacayAddHolidayCalendarRequest = z.infer< + typeof vacayAddHolidayCalendarRequestSchema +>; + +export const vacaySetColorRequestSchema = z.object({ + color: z.string().optional(), + target_user_id: z.union([z.number(), z.string()]).optional(), +}); +export type VacaySetColorRequest = z.infer; + +export const vacayInviteRequestSchema = z.object({ + user_id: z.union([z.number(), z.string()]), +}); +export type VacayInviteRequest = z.infer; + +export const vacayInviteActionRequestSchema = z.object({ + plan_id: z.number().optional(), +}); +export type VacayInviteActionRequest = z.infer< + typeof vacayInviteActionRequestSchema +>; + +export const vacayAddYearRequestSchema = z.object({ + year: z.union([z.number(), z.string()]), +}); +export type VacayAddYearRequest = z.infer; + +export const vacayToggleEntryRequestSchema = z.object({ + date: z.string().min(1), + target_user_id: z.union([z.number(), z.string()]).optional(), +}); +export type VacayToggleEntryRequest = z.infer< + typeof vacayToggleEntryRequestSchema +>; + +export const vacayCompanyHolidayRequestSchema = z.object({ + date: z.string(), + note: z.string().optional(), +}); +export type VacayCompanyHolidayRequest = z.infer< + typeof vacayCompanyHolidayRequestSchema +>; + +export const vacayUpdateStatsRequestSchema = z.object({ + vacation_days: z.number().optional(), + target_user_id: z.union([z.number(), z.string()]).optional(), +}); +export type VacayUpdateStatsRequest = z.infer< + typeof vacayUpdateStatsRequestSchema +>; + +/** Plan / entries / stats payloads are wide and DB-derived; kept open. */ +export const vacayPlanDataSchema = open; +export type VacayPlanData = z.infer; diff --git a/shared/src/weather/weather.schema.spec.ts b/shared/src/weather/weather.schema.spec.ts new file mode 100644 index 0000000000000000000000000000000000000000..60b4ba25c1aa6228d579cdbb8bcbebacc31473d5 --- /dev/null +++ b/shared/src/weather/weather.schema.spec.ts @@ -0,0 +1,93 @@ +import { + weatherQuerySchema, + detailedWeatherQuerySchema, + weatherResultSchema, +} from './weather.schema'; + +import { describe, it, expect } from 'vitest'; + +describe('weatherQuerySchema', () => { + it('accepts lat/lng and defaults lang to "de"', () => { + const parsed = weatherQuerySchema.parse({ lat: '52.5', lng: '13.4' }); + expect(parsed).toEqual({ lat: '52.5', lng: '13.4', lang: 'de' }); + }); + + it('keeps an explicit lang and optional date', () => { + const parsed = weatherQuerySchema.parse({ + lat: '1', + lng: '2', + date: '2026-07-01', + lang: 'en', + }); + expect(parsed.lang).toBe('en'); + expect(parsed.date).toBe('2026-07-01'); + }); + + it('rejects missing lat/lng', () => { + expect(weatherQuerySchema.safeParse({ lng: '13.4' }).success).toBe(false); + expect(weatherQuerySchema.safeParse({ lat: '', lng: '13.4' }).success).toBe( + false, + ); + }); +}); + +describe('detailedWeatherQuerySchema', () => { + it('requires a date', () => { + expect( + detailedWeatherQuerySchema.safeParse({ lat: '1', lng: '2' }).success, + ).toBe(false); + expect( + detailedWeatherQuerySchema.safeParse({ + lat: '1', + lng: '2', + date: '2026-07-01', + }).success, + ).toBe(true); + }); +}); + +describe('weatherResultSchema', () => { + it('accepts a minimal current-weather result', () => { + const r = weatherResultSchema.parse({ + temp: 21, + main: 'Clear', + description: 'Klar', + type: 'current', + }); + expect(r.temp).toBe(21); + }); + + it('accepts a detailed result with hourly entries and a no_forecast error', () => { + expect( + weatherResultSchema.safeParse({ + temp: 0, + main: '', + description: '', + type: '', + error: 'no_forecast', + }).success, + ).toBe(true); + expect( + weatherResultSchema.safeParse({ + temp: 18, + main: 'Rain', + description: 'Regen', + type: 'forecast', + sunrise: '05:30', + sunset: '21:10', + precipitation_sum: 2.4, + hourly: [ + { + hour: 9, + temp: 17, + precipitation: 0.1, + precipitation_probability: 20, + main: 'Clouds', + wind: 12, + humidity: 80, + }, + ], + }).success, + ).toBe(true); + }); +}); diff --git a/shared/src/weather/weather.schema.ts b/shared/src/weather/weather.schema.ts new file mode 100644 index 0000000000000000000000000000000000000000..9a79738ac679e97250925700382ad5ca9011a21d --- /dev/null +++ b/shared/src/weather/weather.schema.ts @@ -0,0 +1,60 @@ +import { z } from 'zod'; + +/** + * Weather API contract — single source of truth for the /api/weather endpoints. + * + * The legacy Express routes treat lat/lng as opaque strings (they are parsed with + * parseFloat inside the service) and only check for presence, so the query schemas + * mirror that: non-empty strings, not coerced numbers. `lang` defaults to 'de', + * matching the Express default. + * + * The bespoke "X is required" 400 messages are reproduced in the controller, not + * derived from these schemas, so the error body stays byte-identical to Express. + */ + +export const weatherQuerySchema = z.object({ + lat: z.string().min(1), + lng: z.string().min(1), + date: z.string().min(1).optional(), + lang: z.string().min(1).default('de'), +}); +export type WeatherQuery = z.infer; + +/** Detailed weather requires a date (the Express route 400s without it). */ +export const detailedWeatherQuerySchema = weatherQuerySchema.extend({ + date: z.string().min(1), +}); +export type DetailedWeatherQuery = z.infer; + +export const hourlyEntrySchema = z.object({ + hour: z.number(), + temp: z.number(), + precipitation: z.number(), + precipitation_probability: z.number(), + main: z.string(), + wind: z.number(), + humidity: z.number(), +}); +export type HourlyEntry = z.infer; + +/** + * Weather response DTO. Fields are optional because the Express service emits + * different subsets depending on the request type (current / forecast / climate / + * detailed) and on error (`{ ..., error: 'no_forecast' }`). + */ +export const weatherResultSchema = z.object({ + temp: z.number(), + temp_max: z.number().optional(), + temp_min: z.number().optional(), + main: z.string(), + description: z.string(), + type: z.string(), + sunrise: z.string().nullable().optional(), + sunset: z.string().nullable().optional(), + precipitation_sum: z.number().optional(), + precipitation_probability_max: z.number().optional(), + wind_max: z.number().optional(), + hourly: z.array(hourlyEntrySchema).optional(), + error: z.string().optional(), +}); +export type WeatherResult = z.infer; diff --git a/shared/tsconfig.json b/shared/tsconfig.json new file mode 100644 index 0000000000000000000000000000000000000000..b46b47b0256da0270b9431b9f3beb0b5ecdf7f9d --- /dev/null +++ b/shared/tsconfig.json @@ -0,0 +1,17 @@ +{ + "compilerOptions": { + "target": "ES2022", + "module": "ESNext", + "moduleResolution": "Bundler", + "lib": ["ES2022"], + "declaration": true, + "strict": true, + "noUncheckedIndexedAccess": true, + "esModuleInterop": true, + "skipLibCheck": true, + "forceConsistentCasingInFileNames": true, + "noEmit": true, + "ignoreDeprecations": "6.0" + }, + "include": ["src"] +} diff --git a/shared/tsdown.config.ts b/shared/tsdown.config.ts new file mode 100644 index 0000000000000000000000000000000000000000..c1e5ade88d1a2b8084ddf559e86900ba0e4f1c27 --- /dev/null +++ b/shared/tsdown.config.ts @@ -0,0 +1,13 @@ +import { defineConfig } from 'tsdown' + +export default defineConfig({ + // Root barrel + i18n metadata barrel + one entry per locale (lazy-load chunks) + entry: ['src/index.ts', 'src/i18n/index.ts', 'src/i18n/*/index.ts'], + format: ['cjs', 'esm'], + dts: true, + clean: true, + deps: { + neverBundle: ['zod'], + }, + target: false, +}) diff --git a/sonar-project.properties b/sonar-project.properties new file mode 100644 index 0000000000000000000000000000000000000000..771b1f12a9cbec00482c6e564bf4f4afec7520c2 --- /dev/null +++ b/sonar-project.properties @@ -0,0 +1,28 @@ +sonar.projectKey=TREK +sonar.projectName=TREK +sonar.sourceEncoding=UTF-8 + +# Sources +sonar.sources=client/src,server/src +sonar.exclusions=**/node_modules/**,**/dist/**,**/build/** + +# Tests +sonar.tests=server/tests,client/tests,client/src +sonar.test.inclusions=server/tests/**/*.ts,client/**/*.test.ts,client/**/*.test.tsx + +# Coverage — path relative to repo root +sonar.javascript.lcov.reportPaths=server/coverage/lcov.info,client/coverage/lcov.info + +# Exclude test files from source analysis and exclude infrastructure/bootstrap files +sonar.exclusions=**/node_modules/**,**/dist/**,**/build/**,**/*.test.ts,**/*.test.tsx +sonar.coverage.exclusions=\ + server/src/index.ts,\ + server/src/db/database.ts,\ + server/src/db/seeds.ts,\ + server/src/demo/**,\ + server/src/config.ts,\ + server/src/db/migrations.ts,\ + server/src/scheduler.ts,\ + client/src/main.tsx,\ + client/src/types.ts,\ + client/src/components/Memories/MemoriesPanel.tsx diff --git a/unraid-template.xml b/unraid-template.xml new file mode 100644 index 0000000000000000000000000000000000000000..00068d8bae416c765ea4fe5e648d5df2179b8dc9 --- /dev/null +++ b/unraid-template.xml @@ -0,0 +1,66 @@ + + + TREK + mauriceboe/trek + https://hub.docker.com/r/mauriceboe/trek + + latest + Latest stable release + + bridge + false + https://github.com/mauriceboe/TREK/issues + https://github.com/mauriceboe/TREK + TREK is a self-hosted, real-time collaborative travel planner with interactive maps, budgets, bookings, packing lists, file management, and more. Plan trips together with your group — changes sync instantly across all connected users. Includes OIDC/SSO support, dark mode, PWA, and a modular addon system (Vacay, Atlas, Collab, Budget, Packing). + Productivity: Tools: + http://[IP]:[PORT:3000] + https://raw.githubusercontent.com/mauriceboe/TREK/main/unraid-template.xml + https://raw.githubusercontent.com/mauriceboe/TREK/main/docs/trek-icon.png + + + Support TREK development + https://ko-fi.com/mauriceboe + + + + 3000 + /mnt/user/appdata/trek/data + /mnt/user/appdata/trek/uploads + + + + 3000 + production + UTC + info + en + + + false + false + true + 1 + false + 24h + 30d + + + admin@trek.local + + + + + + + SSO + false + + + openid email profile + + + + false + 300 + 20 + diff --git a/wiki/Accommodations.md b/wiki/Accommodations.md new file mode 100644 index 0000000000000000000000000000000000000000..10b78753731b6a58d3e6cbd2049e17cd730f9d56 --- /dev/null +++ b/wiki/Accommodations.md @@ -0,0 +1,54 @@ +# Accommodations + +Link an accommodation to specific check-in and check-out days so it appears for every day you are staying there. Accommodations are a distinct record type backed by the `day_accommodations` table and are separate from regular reservations, though each accommodation automatically creates a linked **Hotel** reservation. + + + +## Creating an accommodation + +There are two ways to create an accommodation: + +**From the Reservations panel:** Click **Add** and select **Hotel** as the booking type. When the type is set to Hotel, the date/time and location fields are replaced by accommodation-specific inputs (see below). Saving the form creates both the hotel reservation and the underlying accommodation record at the same time. + +**From the Day Detail panel:** Click the hotel icon or the **Add accommodation** button in the Day Detail overlay. A picker appears that lets you select a place from the trip, choose the day range, and optionally fill in check-in/check-out times and a confirmation code. This creates the accommodation record and its linked Hotel reservation together. + +![Accommodation reservation card showing check-in details](assets/Hotel-ReservationCard.png) + +## Accommodation-specific fields + +When creating or editing via the Reservations panel with type set to **Hotel**, the date/time and location fields are replaced by accommodation-specific inputs: + +| Field | Description | +|-------|-------------| +| **Accommodation** | Search for or select an existing trip place to link as the property. Selecting a place pre-fills the title if it is empty and pre-fills the location field if the place has an address | +| **From** | The check-in day | +| **To** | The check-out day | +| **Check-in** | The earliest time you can check in | +| **Check-in until** | The latest time the front desk accepts check-in | +| **Check-out** | The latest time you must check out | + +The **Confirmation code**, **Status** (Pending / Confirmed), and **Notes** fields are also available, as they are for all reservation types. + +## In the Day Detail panel + +For each day between the **From** day and **To** day (inclusive), the accommodation appears in the Day Detail panel overlay. It shows the linked place name and address, a check-in or check-out label for the relevant boundary days, and the check-in window, check-out time, and confirmation code if set. Middle nights show the place name without a check-in/check-out label. The linked Hotel reservation's status and confirmation number are also shown inline. + +![Day planner side bar with accomodation](assets/Hotel-ReservationDaySidebar.png) + +## In the day plan sidebar + +Accommodations appear as small colour-coded badges in the day header row of the day plan sidebar: + +- **Green badge** — check-in day +- **Red badge** — check-out day +- **Neutral badge** — nights in between (ongoing stay) + +Clicking a badge navigates to the linked place. Hotel-type reservations are filtered out of the inline transport card list between places; they do not appear as transport items in the timeline. + +## In the Reservations panel + +Hotel reservation cards in the Reservations panel show the linked accommodation name (place name) alongside the standard reservation fields such as the confirmation code and status. The check-in and check-out times are displayed in the metadata section of the card when they have been set. + +--- + +**See also:** [Reservations-and-Bookings](Reservations-and-Bookings) · [Transport-Flights-Trains-Cars](Transport-Flights-Trains-Cars) · [Day-Plans-and-Notes](Day-Plans-and-Notes) diff --git a/wiki/Addons-Overview.md b/wiki/Addons-Overview.md new file mode 100644 index 0000000000000000000000000000000000000000..60a403307bf58f7717dc5d44f315859fcafa8272 --- /dev/null +++ b/wiki/Addons-Overview.md @@ -0,0 +1,34 @@ +# Addons Overview + +Addons are optional features that an admin can enable or disable for the entire TREK instance. When an addon is disabled, its navigation tabs, menu items, and API routes are hidden from all users. + +![Addon overview](assets/Addons-Overview.png) + +## What addons are + +Each addon extends TREK with functionality beyond the core trip-planning features. Addons are managed globally — you cannot enable an addon for one user only. Once enabled, the feature becomes available to all users on the instance. + +## Addon list + +The following addons are registered in the system (defined in `server/src/db/seeds.ts`; the TypeScript constant `ADDON_IDS` in `server/src/addons.ts` covers all addons except `naver_list_import`): + +| Addon ID | Type | Description | +|---|---|---| +| `mcp` | integration | Exposes TREK data and actions through the Model Context Protocol for AI assistant integrations. | +| `packing` | trip | Packing list management — create templates and lists linked to trips. See [Packing-Lists](Packing-Lists). | +| `budget` | trip | Trip budget tracking — log expenses, set budgets, and track spending per trip. See [Budget-Tracking](Budget-Tracking). | +| `documents` | trip | Document and file attachments for trips — store itineraries, visa copies, and other files. See [Documents-and-Files](Documents-and-Files). | +| `vacay` | global | Personal vacation day planner with a year calendar, holiday packs, and collaborator fusion. See [Vacay](Vacay). | +| `atlas` | global | Interactive world map showing countries and regions you have visited, plus a bucket list. See [Atlas](Atlas). | +| `collab` | trip | Notes, polls, and live chat for trip collaboration. See [Real-Time-Collaboration](Real-Time-Collaboration). | +| `journey` | global | Trip tracking and travel journal — check-ins, photos, and daily stories. See [Journey-Journal](Journey-Journal). | +| `naver_list_import` | trip | Import places from shared Naver Maps lists directly into a trip. | + + +## Enabling addons + +> **Admin:** all addons are toggled from the admin panel. Navigate to [Admin-Addons](Admin-Addons) to enable or disable individual addons for your instance. + +## Per-addon sub-features + +Some addons expose sub-features that an admin can independently toggle. The [Real-Time-Collaboration](Real-Time-Collaboration) addon, for example, lets an admin decide which of its four sub-features (chat, notes, polls, and what's next) are active across the instance. These are configured from the [Admin-Addons](Admin-Addons) panel alongside the addon's main toggle. diff --git a/wiki/Admin-Addons.md b/wiki/Admin-Addons.md new file mode 100644 index 0000000000000000000000000000000000000000..81553305d81440a1ced8ef713dce64df16bd8c49 --- /dev/null +++ b/wiki/Admin-Addons.md @@ -0,0 +1,70 @@ +# Admin — Addons + +The **Addons** tab lets you enable or disable optional features for the entire TREK instance. Toggling an addon affects all users immediately — disabling one hides its UI elements and blocks its API routes instance-wide. + + + +![Addon overview](assets/Addons-Overview.png) + +## What addons control + +Each addon toggle controls a feature set. When you disable an addon, users lose access to that feature everywhere in the app. No data is deleted; re-enabling the addon restores access to existing data. + +## Addon categories + +Addons are grouped into three categories, shown as labeled sections. + +### Trip addons + +Trip addons add per-trip feature panels. They appear in every trip where the addon is enabled. + +The default trip addons are: **Lists**, **Budget**, **Documents**, **Collab**, and **Naver List Import** (all enabled by default). The exact list is determined by what is registered in your TREK database. + +**Sub-toggles on trip addons:** + +- **Lists** — when enabled, a nested **Bag Tracking** toggle appears. Bag Tracking lets users assign packed items to specific bags. +- **Collab** — when enabled, four sub-toggles appear for individual collaboration features: + - **Chat** — in-trip real-time chat + - **Notes** — shared trip notes + - **Polls** — trip polls + - **What's Next** — the "what's next" widget + +Each sub-toggle can be disabled independently while the parent addon remains enabled. + +### Global addons + +Global addons add features that are not tied to a single trip. The default global addons are **Vacay**, **Atlas**, and **Journey**. + +- **Vacay** — personal vacation day planner with calendar view. Enabled by default. +- **Atlas** — world map of visited countries with travel stats. Enabled by default. +- **Journey** — trip tracking and travel journal (check-ins, photos, daily stories). **Disabled by default.** + +**Sub-items on global addons:** + +- The **Journey** addon shows photo provider toggles underneath it. Each photo provider (e.g., Immich, Synology Photos) can be enabled or disabled independently. + +### Integration addons + +Integration addons connect TREK to external services. Enabling an integration addon typically requires additional configuration (API keys, URLs) in the **Settings** tab. + +- The **MCP** addon requires `APP_URL` to be set in your environment. When enabled, the **MCP Access** tab appears in the Admin Panel. **Disabled by default.** See [MCP-Overview](MCP-Overview) for full details. + +## Enabling or disabling an addon + +Click the toggle switch on any addon row. The change is applied immediately — no save button is needed. A brief success toast confirms the update. + +If a toggle fails (e.g., network error), it rolls back to its previous state. + +## Additional configuration + +Some addons require credentials or environment variables before they are functional: + +- **Journey** — works without any external integration. To embed photos from Immich or Synology Photos, enable the corresponding photo-provider toggle listed under Journey, then configure credentials per-user in **Settings → Integrations**. See [Photo-Providers](Photo-Providers). +- **MCP** — requires `APP_URL` to be set so OAuth redirect URIs resolve correctly. + +## Related pages + +- [Admin-Panel-Overview](Admin-Panel-Overview) +- [Admin-MCP-Tokens](Admin-MCP-Tokens) +- [MCP-Overview](MCP-Overview) +- [Addons-Overview](Addons-Overview) diff --git a/wiki/Admin-Categories.md b/wiki/Admin-Categories.md new file mode 100644 index 0000000000000000000000000000000000000000..61ebdcdee9247c85214948d4d7705048113f71d2 --- /dev/null +++ b/wiki/Admin-Categories.md @@ -0,0 +1,47 @@ +# Admin — Categories + +The **Personalization** tab → **Categories** section lets you manage global place categories. Categories are shared across all trips and all users on the instance. + + + +![Category Manager](assets/CategoryManager.png) + +## What categories are + +A category is a label consisting of a name, a color, and an icon. Users assign categories to places when creating or editing a place. Categories appear: + +- In the place form's category selector +- As colored chips on place cards +- In the places filter panel +- In the map legend + +## Creating a category + +Click **New Category** (top-right of the category section). A form appears inline: + +1. **Name** — required. Free-text label for the category. +2. **Icon** — a scrollable grid of ~47 curated Lucide icons (Pin, Hotel, Restaurant, Transport, Nature, etc.). Click any icon to select it. The default icon is `MapPin`. +3. **Color** — 12 preset color swatches plus a custom color picker (pipette button). The default color is `#6366f1` (indigo). The 12 presets are: + + `#6366f1` · `#8b5cf6` · `#ec4899` · `#ef4444` · `#f97316` · `#f59e0b` · `#10b981` · `#06b6d4` · `#3b82f6` · `#84cc16` · `#6b7280` · `#1f2937` + +4. A **live preview** chip shows how the category will appear to users as you make selections. + +Click **Create** to save. + +## Editing a category + +Click the pencil icon on any category row. The same form appears in-place with the existing values pre-filled. Change any field and click **Update**. + +## Deleting a category + +Click the trash icon on a category row and confirm. Deletion sets `category_id` to `NULL` on any places that had the category assigned — the places themselves are not affected, they become uncategorized. + +## List ordering + +Categories are always displayed in alphabetical order by name. There is no manual reordering. + +## Related pages + +- [Places-and-Search](Places-and-Search) +- [Admin-Panel-Overview](Admin-Panel-Overview) diff --git a/wiki/Admin-GitHub-Releases.md b/wiki/Admin-GitHub-Releases.md new file mode 100644 index 0000000000000000000000000000000000000000..fc2196f26f7c754326361ba5b304f26ae1361c7d --- /dev/null +++ b/wiki/Admin-GitHub-Releases.md @@ -0,0 +1,50 @@ +# Admin — GitHub Releases + +The **GitHub** tab shows the TREK release history fetched from GitHub and provides links to community resources and support options. + + + +![GitHub tab](assets/GithubReleases.png) + +## Support and resources + +Six cards at the top of the tab link to external resources: + +| Card | Link | +|------|------| +| **Ko-fi** | Support the project financially | +| **Buy Me a Coffee** | Alternative support link | +| **Discord** | Join the TREK community | +| **Report a Bug** | Open a GitHub issue with the bug report template | +| **Feature Request** | Open a GitHub Discussion in the feature requests category | +| **Wiki** | Open the GitHub Wiki | + +## Release timeline + +Below the support cards, a chronological timeline lists GitHub releases for the `mauriceboe/TREK` repository. Each entry shows: + +- **Version tag** (e.g., `v2.9.14`) +- A **Latest** badge on the first (most recent) entry in the displayed list +- **Release date** and author +- A **Show details / Hide details** toggle that expands the release notes (Markdown rendered inline) + +When the running server version is a stable release, pre-release entries are filtered out of the timeline. + +Releases load 10 at a time. Click **Load more** at the bottom of the timeline to fetch additional pages. + +If the admin API request fails, the timeline section shows an error message. If the server cannot reach the GitHub API, the timeline displays no releases (the server returns an empty list rather than an error). + +## Version check + +The server checks for available updates daily at 9 AM (server timezone, defaults to UTC) and sends an admin notification when a newer version is published. When an update is available, a banner also appears at the top of the Admin page on next load. + +Results are cached for 5 minutes to avoid repeated API calls. + +## When to check + +Review the GitHub tab before performing an upgrade to read the release notes for any versions between your current install and the target version. See [Updating](Updating) for the upgrade procedure. + +## Related pages + +- [Updating](Updating) +- [Admin-Panel-Overview](Admin-Panel-Overview) diff --git a/wiki/Admin-MCP-Tokens.md b/wiki/Admin-MCP-Tokens.md new file mode 100644 index 0000000000000000000000000000000000000000..22ff210a1d1adc72a1b3309306aa3c9f5d901019 --- /dev/null +++ b/wiki/Admin-MCP-Tokens.md @@ -0,0 +1,48 @@ +# Admin — MCP Tokens + +The **MCP Access** panel shows all active MCP OAuth sessions and API tokens across every user on the instance. As an admin you can revoke sessions and delete tokens. + +This panel is only visible when the **MCP addon** is enabled in the [Admin-Addons](Admin-Addons) panel. + + + +![MCP Access](assets/MCPAccess.png) + +## OAuth Sessions + +OAuth sessions are created when a user authorizes an MCP client via the OAuth 2.1 flow. These are the recommended way to connect MCP clients to TREK. + +**Columns:** + +| Column | Description | +|--------|-------------| +| Client name | The name of the registered OAuth client. Granted scopes are shown as badges below the name (up to 6 are shown; click "+N more" to expand) | +| Owner | The username of the user who authorized the session | +| Created | Date the session was established | +| (actions) | Trash icon button to revoke | + +**Revoking a session:** Click the trash icon on the row and confirm. The session is invalidated immediately and the revocation is recorded in the audit log. The user's MCP client will need to re-authorize before it can make further requests. + +OAuth access tokens use the prefix `trekoa_`. + +## API Tokens + +API tokens are long-lived tokens that users create in their personal settings. They are identified by the `trek_` prefix. + +**Columns:** + +| Column | Description | +|--------|-------------| +| Token name | The label the user gave the token, with its truncated prefix shown below | +| Owner | The username of the user who created it | +| Created | Date the token was created | +| Last used | Date of the most recent API call using this token, or "Never" if unused | +| (actions) | Trash icon button to delete | + +**Deleting a token:** Click the trash icon and confirm. The token is invalidated immediately. The user must create a new token in their settings if they still need access. + +## Related pages + +- [MCP-Overview](MCP-Overview) +- [MCP-Setup](MCP-Setup) +- [Admin-Panel-Overview](Admin-Panel-Overview) diff --git a/wiki/Admin-Packing-Templates.md b/wiki/Admin-Packing-Templates.md new file mode 100644 index 0000000000000000000000000000000000000000..6ab467575d0a762b2860faf0aaf0abd72f35e298 --- /dev/null +++ b/wiki/Admin-Packing-Templates.md @@ -0,0 +1,65 @@ +# Admin — Packing Templates + +The **Personalization** tab → **Packing Templates** section lets you create reusable packing list templates that users can apply to any trip. + + + +![Packing Template Manager](assets/PackingTemplate.png) + +## What templates are + +A packing template is a three-level hierarchy: + +``` +Template +└── Category + └── Item +``` + +When a user applies a template to a trip, all categories and items from that template are copied into the trip's packing list. + +## Template list + +The template list shows each template as a collapsible row displaying: + +- Template name +- Category count and item count (e.g., `3 categories · 12 items`) +- Edit (rename) and delete buttons + +## Creating a template + +1. Click **New Template** (top-right of the panel). +2. Type a name and press **Enter** or click the confirm button. +3. The new template is added to the list and automatically expanded. + +## Adding categories to a template + +With a template expanded, click **Add category** (dashed border button at the bottom of the expanded section). Type a category name and press **Enter** or click confirm. + +## Adding items to a category + +Click the `+` button inside any category header. An inline input appears below the last item. Type an item name and press **Enter** to add it. You can add multiple items in sequence without closing the input — press **Enter** after each one. + +## Editing inline + +All editing is inline: + +- **Rename a template** — click the pencil icon on the template row. The name becomes an input; press **Enter** or click away to save. +- **Rename a category** — click the pencil icon in the category header. Press **Enter** or click away to save. +- **Rename an item** — hover the item row to reveal the pencil icon, then click it. Press **Enter** or click the confirm button to save (clicking away does not save). + +## Deleting + +- **Delete a template** — click the trash icon on the template row. The template is removed. This does not affect trips that already had items from this template applied. +- **Delete a category** — click the trash icon in the category header. All items in that category are also deleted from the template. +- **Delete an item** — hover the item row to reveal the trash icon. + +## Applying templates to a trip + +Users apply templates through the **Packing** panel inside the trip planner. See [Packing-Templates](Packing-Templates) for user-facing documentation. + +## Related pages + +- [Packing-Templates](Packing-Templates) +- [Packing-Lists](Packing-Lists) +- [Admin-Panel-Overview](Admin-Panel-Overview) diff --git a/wiki/Admin-Panel-Overview.md b/wiki/Admin-Panel-Overview.md new file mode 100644 index 0000000000000000000000000000000000000000..627e7f2a3cc1abac2c4983bfdd46ca97830a6815 --- /dev/null +++ b/wiki/Admin-Panel-Overview.md @@ -0,0 +1,39 @@ +# Admin Panel Overview + +The Admin Panel is the central control surface for TREK instance operators. It is only accessible to users with the `admin` role. + +## Accessing the Admin Panel + +Navigate to the **Admin** link in the top navbar. If you do not see it, your account does not have admin privileges. + + + +![Admin Panel](assets/AdminPanel.png) + +## Tabs + +The Admin Panel is divided into tabs. Most tabs are always visible; a few appear only under specific conditions. + +| Tab | Purpose | Conditional? | +|-----|---------|--------------| +| **Users** | Manage users, invite links, and permissions | No | +| **Personalization** | Packing templates and place categories | No | +| **User Defaults** | Default settings applied to new users | No | +| **Addons** | Enable or disable optional features instance-wide | No | +| **Settings** | Authentication methods, MFA, allowed file types, API keys, OIDC/SSO configuration, and JWT secret rotation | No | +| **Notifications** | SMTP, webhook, ntfy, and push notification channel configuration; trip reminder toggle; admin notification preferences | No | +| **Backup** | Manual and scheduled database backups | No | +| **Audit** | Chronological activity log | No | +| **MCP Access** | OAuth sessions and static API tokens | Only when the MCP addon is enabled | +| **GitHub** | Release timeline and support links | No | +| **Dev: Notifications** | Test notification dispatch | Only in development mode (`NODE_ENV=development`) | + +## Related pages + +- [Admin-Users-and-Invites](Admin-Users-and-Invites) +- [Admin-Addons](Admin-Addons) +- [Admin-Categories](Admin-Categories) +- [Admin-Packing-Templates](Admin-Packing-Templates) +- [Admin-Permissions](Admin-Permissions) +- [Admin-MCP-Tokens](Admin-MCP-Tokens) +- [Admin-GitHub-Releases](Admin-GitHub-Releases) diff --git a/wiki/Admin-Permissions.md b/wiki/Admin-Permissions.md new file mode 100644 index 0000000000000000000000000000000000000000..16bb08a823ab50748eab49d0838295d92f4c33e0 --- /dev/null +++ b/wiki/Admin-Permissions.md @@ -0,0 +1,76 @@ +# Admin — Permissions + +The Permissions panel, located at the bottom of the **Users** tab, controls which role level is required to perform each action. Changes apply immediately across the entire instance. + + + +![Permissions panel](assets/PermissionSettings.png) + +## Role model + +TREK uses four permission levels, ordered from most to least privileged: + +| Level | Who it includes | +|-------|----------------| +| `admin` | Instance administrators only | +| `trip_owner` | The user who created the trip | +| `trip_member` | Any user who is a member of the trip | +| `everybody` | Any authenticated user (for `trip_create`: no trip context required; for all other actions: any authenticated user with trip access) | + +Each action is assigned a minimum required level. A user whose role is at or above that level can perform the action. Not every level is available for every action — each action exposes only the levels that make sense for it. For example, `trip_create` only allows `everybody` or `admin`, while `trip_edit` only allows `trip_owner` or `trip_member`. + +## Action categories + +Actions are grouped into five categories: + +### Trip + +| Action key | What it controls | +|------------|-----------------| +| `trip_create` | Create a new trip | +| `trip_edit` | Edit trip name, dates, description, and currency | +| `trip_delete` | Permanently delete a trip | +| `trip_archive` | Archive or unarchive a trip | +| `trip_cover_upload` | Upload or change the cover image for a trip | + +### Members + +| Action key | What it controls | +|------------|-----------------| +| `member_manage` | Invite or remove trip members | + +### Files + +| Action key | What it controls | +|------------|-----------------| +| `file_upload` | Upload files to a trip | +| `file_edit` | Edit file descriptions and links | +| `file_delete` | Move files to trash or permanently delete them | + +### Content & Schedule + +| Action key | What it controls | +|------------|-----------------| +| `place_edit` | Add, edit, or delete places | +| `day_edit` | Edit days, day notes, and place assignments | +| `reservation_edit` | Create, edit, or delete reservations | + +### Budget, Packing & Collaboration + +| Action key | What it controls | +|------------|-----------------| +| `budget_edit` | Create, edit, or delete budget items | +| `packing_edit` | Manage packing items and bags | +| `collab_edit` | Create notes, polls, and send messages | +| `share_manage` | Create or delete public share links | + +## Changing permissions + +Each action row has a dropdown. Select the minimum role level required. A **customized** badge appears next to any action that has been changed from its default. + +Click **Save** (top-right of the panel) to persist your changes. Use the **Reset to defaults** button (circular arrow icon) to revert all actions to their shipped defaults without saving — you still need to click **Save** after resetting if you want to persist the reset state. + +## Related pages + +- [Admin-Panel-Overview](Admin-Panel-Overview) +- [Admin-Users-and-Invites](Admin-Users-and-Invites) diff --git a/wiki/Admin-Users-and-Invites.md b/wiki/Admin-Users-and-Invites.md new file mode 100644 index 0000000000000000000000000000000000000000..b44be98f1ab24e24b4c8c888b7e48f38c58b26fe --- /dev/null +++ b/wiki/Admin-Users-and-Invites.md @@ -0,0 +1,90 @@ +# Admin — Users and Invites + +The **Users** tab in the Admin Panel lets you view all registered users, manage their accounts, and create invite links so new people can register without open registration. + + + +![Users tab](assets/UsersAndInvites.png) + +## User list + +The user table shows every registered account with the following columns: + +| Column | Description | +|--------|-------------| +| **User** | Avatar, username, and an always-visible presence dot (green = online, grey = offline) | +| **Email** | Account email address | +| **Role** | Badge showing `admin` or `user` | +| **Created** | Account creation date | +| **Last Login** | Date and time of most recent login | +| **Actions** | Edit and delete buttons | + +Your own account row is highlighted. You cannot delete your own account. + +## User actions + +### Edit a user + +Click the pencil icon on any row to open the edit form. You can change: + +- **Username** +- **Email address** +- **Role** — toggle between `user` and `admin` +- **Password** — set a new password; must be at least 8 characters + +Click **Save** to apply changes. + +### Delete a user + +Click the trash icon and confirm. Deletion is permanent. The user's account is removed from the database along with their data (cascade behavior is enforced at the database level). + +You cannot delete your own account while logged in as that user. + +## Creating a user directly + +Click **Create User** (top-right of the Users tab) to create an account without an invite link. You set the username, email, password, and role at creation time. + +## Invite links + +Invite links let a specific number of people register themselves. This is useful when open registration is disabled. + +![Invite links](assets/InviteLinkForm.png) + +### Creating an invite + +Click **Create Invite** (invite links section, below the user table). Configure: + +- **Max uses** — how many times the link can be used before it expires: `1×`, `2×`, `3×`, `4×`, `5×`, or `∞` (unlimited). Defaults to `1×`. +- **Expiry** — how long the link remains valid: `1d`, `3d`, `7d`, `14d`, or `∞` (no expiry). Defaults to `7d`. + +After creation the link is copied to your clipboard automatically. Share it with the intended recipient. The URL format is: + +``` +/register?invite= +``` + +### Invite list + +Existing invites are listed below the creation button. Each row shows: + +- The invite token (truncated, monospace) +- A status badge — `active`, `used up`, or `expired` +- **Usage** — `used / max` (or `used / ∞` for unlimited) +- **Expiry** date, if set +- **Created by** — the admin who generated the link +- A **copy link** button (only shown for active invites) +- A **delete** (revoke) button + +Revoking an invite immediately invalidates it; anyone following the link after revocation will receive an error. + +## Permissions + +The **Users** tab also hosts the Permissions panel at the bottom, which controls what roles can perform which actions. See [Admin-Permissions](Admin-Permissions) for details. + +## Related pages + +- [Login-and-Registration](Login-and-Registration) +- [Invite-Links](Invite-Links) +- [Admin-Permissions](Admin-Permissions) +- [Two-Factor-Authentication](Two-Factor-Authentication) +- [Admin-Panel-Overview](Admin-Panel-Overview) diff --git a/wiki/Atlas.md b/wiki/Atlas.md new file mode 100644 index 0000000000000000000000000000000000000000..a3fd81b551eee41d2ba8445b5616d466686c375d --- /dev/null +++ b/wiki/Atlas.md @@ -0,0 +1,55 @@ +# Atlas + +Atlas is an interactive world map that shows countries and regions you have visited across all your trips, together with a bucket list of places you want to go. + +> **Admin:** enable Atlas in [Admin-Addons](Admin-Addons). + + + +![Atlas](assets/Atlas.png) + +## What Atlas is + +Atlas gives you a visual overview of your travel footprint. Visited countries are highlighted on the map. You can also mark individual sub-national regions and maintain a personal bucket list of future destinations. + +## Accessing Atlas + +When the admin has enabled the Atlas addon, an **Atlas** entry appears in the main navigation. Your visited countries are populated automatically from your existing trips. + +## Marking countries as visited + +Click any country on the map to open an action popup where you can mark it as visited or add it to your bucket list. Use the search bar at the top of the map to find and fly to a country — pressing Enter or selecting a result from the dropdown opens the same action popup. + +To remove a manually-marked country (one with no trips or places recorded in it), click it on the map and confirm removal in the popup. + +Visits detected automatically from your trips are shown in addition to any countries you mark manually. + +### Sub-national regions + +At zoom level 5 and above, the map switches to a sub-national region view (states, provinces, etc.). You can mark individual regions as visited or add them to your bucket list. Marking a region also counts the parent country as visited if it was not already. + +## Bucket list + +The bucket list is separate from "visited". Use it to track countries or places you want to visit in the future. Each bucket list item can have a name, coordinates, country code, optional notes, and a target date. + +## Statistics + +Your Atlas statistics panel shows: + +- **Countries visited** — total number of distinct countries. +- **Trips** — total number of trips across all time. +- **Places** — total number of individual places logged in trips. +- **Cities** — total number of distinct cities visited. +- **Travel days** — total days spent travelling. +- **Continent breakdown** — number of countries visited per continent (Europe, Asia, North America, South America, Africa, Oceania). +- **Travel streak** — number of consecutive years in which you have taken at least one trip. +- **Trips this year** — number of trips in the current calendar year. + +## Visual effect + +The desktop glass panel at the bottom of the map uses a liquid-glass visual effect — a dynamic inner glow and border highlight that follows your cursor across the panel. + +## See also + +- [Addons-Overview](Addons-Overview) +- [Admin-Addons](Admin-Addons) diff --git a/wiki/Audit-Log.md b/wiki/Audit-Log.md new file mode 100644 index 0000000000000000000000000000000000000000..c6fbd52e709eda4519360f9561e3adb6b5fcb4b9 --- /dev/null +++ b/wiki/Audit-Log.md @@ -0,0 +1,138 @@ +# Audit Log + +The audit log records significant actions taken on your TREK instance. Use it to monitor logins, admin changes, and integration configuration. + +## Where to find it + +**Admin Panel → Audit** tab. + + + +![Audit log](assets/Audit.png) + +## What the log captures + +Actions are grouped by area below. The **Action key** is the raw value stored in the log. + +### Authentication + +| Action key | Description | +|---|---| +| `user.register` | User registered | +| `user.login` | User logged in | +| `user.login_failed` | Login attempt failed | +| `user.password_change` | User changed their password | +| `user.account_delete` | User deleted their account | + +### MFA + +| Action key | Description | +|---|---| +| `user.mfa_enable` | MFA enabled on an account | +| `user.mfa_disable` | MFA disabled on an account | + +### Trips + +| Action key | Description | +|---|---| +| `trip.create` | Trip created (includes title) | +| `trip.update` | Trip updated (includes changed fields) | +| `trip.copy` | Trip duplicated (includes source and new trip IDs) | +| `trip.delete` | Trip deleted (includes trip ID and title) | + +### Admin actions + +| Action key | Description | +|---|---| +| `admin.user_create` | User created by admin | +| `admin.user_update` | User edited by admin (role, email, username, etc.) | +| `admin.user_delete` | User deleted by admin | +| `admin.invite_create` | Invite link created | +| `admin.invite_delete` | Invite link deleted | +| `admin.permissions_update` | Instance permissions updated | +| `admin.oidc_update` | OIDC/SSO settings updated | +| `admin.addon_update` | Addon enabled, disabled, or configured | +| `admin.oauth_session.revoke` | OAuth session revoked by admin | +| `admin.rotate_jwt_secret` | JWT secret rotated | +| `admin.bag_tracking` | Bag tracking feature toggled | +| `admin.places_photos` | Places photos feature toggled | +| `admin.places_autocomplete` | Places autocomplete feature toggled | +| `admin.places_details` | Places details feature toggled | +| `admin.collab_features` | Collaboration features updated | +| `admin.packing_template_delete` | Packing template deleted | +| `admin.default_user_settings_update` | Default user settings updated | +| `admin.demo_baseline_save` | Demo baseline snapshot saved | +| `settings.app_update` | App settings updated (SMTP, webhooks, MFA policy, etc.) | + +### Backups + +| Action key | Description | +|---|---| +| `backup.create` | Manual backup created | +| `backup.restore` | Restore from stored backup | +| `backup.upload_restore` | Restore from uploaded ZIP | +| `backup.delete` | Backup deleted | +| `backup.auto_settings` | Auto-backup schedule saved | + +### MCP + +| Action key | Description | +|---|---| +| `mcp.tool_call` | MCP tool invoked (resource = tool name) | + +### OAuth + +| Action key | Description | +|---|---| +| `oauth.client.create` | OAuth client application created | +| `oauth.client.rotate_secret` | OAuth client secret rotated | +| `oauth.client.delete` | OAuth client application deleted | +| `oauth.consent.grant` | User granted OAuth consent | +| `oauth.token.issue` | OAuth access token issued | +| `oauth.token.refresh` | OAuth access token refreshed | +| `oauth.token.revoke` | OAuth token revoked | +| `oauth.token.grant_failed` | OAuth token grant attempt failed | +| `oauth.token.client_auth_failed` | OAuth client authentication failed | + +### Integrations + +| Action key | Description | +|---|---| +| `immich.private_ip_configured` | Immich URL saved that resolves to a private IP | + +## Log columns + +| Column | Description | +|---|---| +| Time | Timestamp of the action | +| User | Username and email of the acting user (or `anonymous` for unauthenticated events) | +| Action | Action key (see tables above) | +| Resource | Affected resource (filename, trip ID, tool name, etc.) where applicable | +| IP | Client IP address | +| Details | Additional context in JSON format | + +## Pagination + +The panel loads 100 entries at a time by default. Click **Load more** at the bottom to fetch the next page. The total count is shown above the table. + +## IP addresses + +The client IP is read from the `X-Forwarded-For` header. When TREK is behind a reverse proxy, set `TRUST_PROXY=true` so the header is trusted and the real client IP is recorded. Without this setting, the proxy's own IP is logged instead. See [Environment-Variables](Environment-Variables). + +## Log file + +In addition to the database, audit events are written to a plain-text log file: + +- **Path:** `./data/logs/trek.log` +- **Rotation:** rotated when the file reaches 10 MB +- **Retention:** the 4 most recent rotated files are kept (`trek.log.1` through `trek.log.4`) + +## Database retention + +Audit entries in the database are never automatically deleted. They accumulate and are paginated in the UI. + +## See also + +- [Admin-Panel-Overview](Admin-Panel-Overview) +- [Security-Hardening](Security-Hardening) +- [Environment-Variables](Environment-Variables) diff --git a/wiki/Backups.md b/wiki/Backups.md new file mode 100644 index 0000000000000000000000000000000000000000..cf6d927e448399bc57606a2c9bb4e80b78f7e368 --- /dev/null +++ b/wiki/Backups.md @@ -0,0 +1,88 @@ +# Backups + +TREK stores all data in a single SQLite database (`travel.db`) plus an `uploads/` directory of attachments, cover photos, and avatars. The Backup panel lets you create, download, restore, and schedule backups of both. + +## Where to find it + +**Admin Panel → Backup** tab. + + + +![Backup tab](assets/Backup.png) + +## What a backup contains + +A backup is a ZIP archive with two entries: + +| Entry | Contents | +|---|---| +| `travel.db` | The full SQLite database | +| `uploads/` | All uploaded attachments, covers, and avatars | + +**Not included:** the encryption key. Store your `ENCRYPTION_KEY` separately from the backup ZIP — for example, in a password manager. See [Encryption-Key-Rotation](Encryption-Key-Rotation). + +## Manual backup + +Click **Create Backup** in the Backup tab. The server creates the ZIP and makes it available for download. Up to 3 manual backups can be created per hour per IP address (rate-limit window: 1 hour). + +You can also download or delete any existing backup from the list. + +## Restoring a backup + +You can restore from: + +- **A stored backup** — click **Restore** next to any backup in the list. +- **An uploaded ZIP** — click **Upload & Restore** and select a backup file from your computer (maximum upload size: 500 MB). + +Before restoring, TREK runs integrity checks on the uploaded database: + +1. **SQLite `PRAGMA integrity_check`** — verifies the database file is not corrupt. +2. **Required tables present** — confirms the file contains `users`, `trips`, `trip_members`, `places`, and `days`. Files missing any of these are rejected as not being a valid TREK backup. + +> **Warning:** Restoring replaces all current data. Back up your current state first if you want to keep it. + +## Auto-backup + +Enable scheduled backups in the **Auto-Backup** section of the Backup tab. + +**Interval** options: + +- Hourly +- Daily +- Weekly +- Monthly + +**Retention** (`Keep last … days`) — enter a number of days. Backups older than that many days are pruned after each auto-backup run. Set to **0** to keep all backups indefinitely (no pruning). + +**Schedule** options (depend on interval): + +- **Hour** — time of day for daily, weekly, and monthly backups (0–23). +- **Day of week** — Sunday through Saturday (for weekly backups). +- **Day of month** — 1–28 (for monthly backups). Day 29–31 is excluded to avoid months with fewer days. + +Auto-backup files are named `auto-backup-.zip` (manual backups use `backup-.zip`). + +After each auto-backup run, **all** backup files (manual and auto) older than `keep_days` are pruned. Set `keep_days` to `0` to disable pruning entirely. + +## Before updating TREK + +Always create a manual backup before updating. See [Updating](Updating). + +## Audit log + +The following actions are recorded in the [Audit-Log](Audit-Log): + +| Action key | When | +|---|---| +| `backup.create` | Manual backup created | +| `backup.restore` | Restore from stored backup | +| `backup.upload_restore` | Restore from uploaded ZIP | +| `backup.delete` | Backup deleted | +| `backup.auto_settings` | Auto-backup settings saved | + +## See also + +- [Encryption-Key-Rotation](Encryption-Key-Rotation) +- [Admin-Panel-Overview](Admin-Panel-Overview) +- [Security-Hardening](Security-Hardening) +- [Updating](Updating) diff --git a/wiki/Budget-Tracking.md b/wiki/Budget-Tracking.md new file mode 100644 index 0000000000000000000000000000000000000000..8014ce7ecb7cd24c5f9d038de761bf94eead8d4a --- /dev/null +++ b/wiki/Budget-Tracking.md @@ -0,0 +1,89 @@ +# Budget Tracking + +Track trip expenses by category, split costs between members, and visualize spending. + + + +![Budget panel](assets/Budget.png) + +## Where to find it + +Open the **Budget** tab inside the trip planner. The tab is only visible when the Budget addon is enabled. + +> **Admin:** Budget is an addon. Enable it in [Admin-Addons](Admin-Addons). + +![Create Budget](assets/BudgetCreateBudget.gif) + +## Currency + +Use the currency picker in the Budget toolbar to select one currency for the entire trip. 46 currencies are supported (EUR, USD, GBP, JPY, CHF, CZK, PLN, SEK, NOK, DKK, TRY, THB, AUD, CAD, NZD, BRL, MXN, INR, IDR, MYR, PHP, SGD, KRW, CNY, HKD, TWD, ZAR, AED, SAR, ILS, EGP, MAD, HUF, RON, BGN, HRK, ISK, RUB, UAH, BDT, LKR, VND, CLP, COP, PEN, ARS). All amounts are displayed in this currency. + +## Categories + +Expenses are grouped into categories. Each category is shown with a small colored square indicator that cycles through a 12-color palette as you add more categories. + +From the toolbar you can: + +- **Add a category** — type a name and click the **+** button (or press Enter). +- **Rename a category** — click the pencil icon next to its name in the category header. +- **Reorder categories** — drag the grip handle on the left of the category header. +- **Delete a category** — click the trash icon in the category header. This deletes all expense items inside it. + +## Expense items + +Each category contains a table of items with the following columns: + +| Column | Notes | +|---|---| +| Name | Editable inline. Read-only when linked to a reservation. | +| Total | The total cost for this item. | +| Persons | Number of persons (or member chips on multi-member trips). | +| Days | Number of days. | +| Per Person | Calculated: Total ÷ Persons. | +| Per Day | Calculated: Total ÷ Days. | +| Per Person/Day | Calculated: Total ÷ (Persons × Days). | +| Date | Optional expense date. | +| Note | Free-text note. | + +Click any editable cell to edit it inline. Drag the grip handle to reorder items within a category. + +Add a new item using the inline **add row** at the bottom of each category table. + +## Splitting costs + +The **Persons** column behaves differently depending on the trip: + +- **Single-user trip** — enter a number of persons directly. +- **Multi-member trip** — a member chip picker appears. Click the edit button to assign or remove members from an expense. Click an assigned member chip again to mark them as **paid** (the chip shows a green ring). + +![Add Expense](assets/BudgetAddExpensive.gif) + +## Settlement calculator + +When multiple members are assigned to expenses and there are outstanding debts between members, a collapsible **Settlement** section appears inside the total card. Click the section header to expand it. It shows the minimum number of transfers needed to settle all debts (using a greedy matching algorithm), including: + +- Transfer flows: who pays whom and how much. +- Net balances: each member's overall surplus or deficit. + +![Final Settlement](assets/BudgetFinalSettlement.gif) + +## Budget summary + +The right-hand column contains two widgets: + +- **Total card** — displays the grand total in large type. On multi-member trips it also shows a per-member breakdown with a proportional bar. +- **Donut chart** — spending by category. Each segment uses that category's color. The legend always shows the amount and percentage for each category; hovering a legend row highlights it. + +## Exporting + +Click the **CSV** button in the toolbar to download a semicolon-delimited file containing all categories and items. The columns exported are: Category, Name, Date, Total, Persons, Days, Per Person, Per Day, Per Person/Day, Note. + +## Permissions + +All write operations (adding/editing/deleting items and categories, changing currency) require the `budget_edit` permission. + +## See also + +- [Admin-Addons](Admin-Addons) +- [Reservations-and-Bookings](Reservations-and-Bookings) +- [Trip-Planner-Overview](Trip-Planner-Overview) diff --git a/wiki/Collab-Chat.md b/wiki/Collab-Chat.md new file mode 100644 index 0000000000000000000000000000000000000000..4236d93a957a33d2ef0ea18c3a96a96ea0372788 --- /dev/null +++ b/wiki/Collab-Chat.md @@ -0,0 +1,59 @@ +# Collab Chat + +Chat with your group in real time, without leaving the trip planner. + + + +![Collab Chat](assets/Collab.png) + +## Where to find it + +Open the trip planner and select the **Collab** tab. If the Chat sub-feature is enabled, a Chat panel appears — on desktop as the left column, on mobile as the first tab in the tab bar. + +The Collab addon must be enabled by an admin and the Chat sub-feature must be turned on. See [Real-Time-Collaboration](Real-Time-Collaboration). + +## Sending messages + +Type in the input field at the bottom and press **Enter** (or click the send button) to post. Hold **Shift + Enter** to insert a line break without sending. + +Messages load in pages of 100. A **Load more** button appears at the top of the chat when older messages are available. + +## Emoji + +Click the smiley-face button in the composer to open the emoji picker. The picker has three categories: + +- **Smileys** — facial expressions and gestures +- **Reactions** — hearts, fire, thumbs, and similar +- **Travel** — planes, maps, food, cameras, and destinations + +Emoji are rendered via Twemoji for consistent appearance across platforms. + +## Reactions + +**Right-click** a message on desktop (or **double-tap** on mobile) to open the quick-reaction menu. Eight quick reactions are available: ❤️ 😂 👍 😮 😢 🔥 👏 🎉. Click any reaction to toggle it on or off. Reactions from all users aggregate beneath the message; hover a reaction badge to see who reacted. + +## Replies + +Hover a message to reveal the action buttons. Click **Reply** to quote that message. A preview of the quoted text appears above your new message in the composer; click the **×** to cancel the reply. The quoted text is displayed inline inside your bubble when sent. + +## URL link previews + +When a message contains a URL, TREK automatically fetches an Open Graph preview (title, description, and thumbnail image) and displays it below the message text. Only the first URL in a message generates a preview. + +## Message styling + +Your own messages appear **right-aligned** with a blue bubble. Other members' messages appear **left-aligned** with a gray bubble. The username is shown above the first message in a group of consecutive messages from the same person; the avatar is shown beside the **last** message in that group. Timestamps appear below the last message in each group. + +Messages that consist of only 1–3 emoji are displayed larger without a bubble. + +## Deleting messages + +Hover your own message to reveal the delete button (trash icon). The delete button is only visible when you have the `collab_edit` permission. Deleting replaces the bubble with an italicised notice — showing your username, "deleted a message", and a timestamp — visible to all members. + +## Read-only viewers + +Users without the `collab_edit` permission can read all messages but the composer is disabled — they cannot send, react, or delete messages. The reply button is visible to all users, but completing a reply still requires `collab_edit` (the send button is hidden for read-only users). + +## Related pages + +[Real-Time-Collaboration](Real-Time-Collaboration) · [Collab-Notes](Collab-Notes) · [Collab-Polls](Collab-Polls) diff --git a/wiki/Collab-Notes.md b/wiki/Collab-Notes.md new file mode 100644 index 0000000000000000000000000000000000000000..ca1fd286eada76e7fdde60f1ff336778a0d46c74 --- /dev/null +++ b/wiki/Collab-Notes.md @@ -0,0 +1,72 @@ +# Collab Notes + +Share structured, richly formatted notes with your group. Notes are organized into color-coded categories and can be pinned, attached with files, and linked to external websites. + + + +![Collab Notes](assets/Collab.png) + +## Where to find it + +Open the trip planner → **Collab** tab → **Notes** section. The Collab addon must be enabled and the Notes sub-feature must be turned on. See [Real-Time-Collaboration](Real-Time-Collaboration). + +## Categories + +Notes are grouped into categories. Each category has a name and a color chosen from six swatches: **Indigo**, **Red**, **Amber**, **Emerald**, **Blue**, and **Violet**. + +To manage categories, click the settings (gear) icon in the Notes header (only visible to users with the `collab_edit` permission). From the category settings modal you can: + +- Add a new category (type a name and click **+**) +- Rename a category by clicking its name inline +- Change a category's color by clicking a swatch +- Delete a category + +All changes (including color updates) are staged locally and applied only when you click **Save** in the modal. Saving a color change updates every note in that category. + +## Creating a note + +Click **+ New Note** in the Notes header (only visible to users with the `collab_edit` permission). A modal opens with the following fields: + +| Field | Required | Notes | +|-------|----------|-------| +| Title | Yes | Plain text | +| Body | No | Markdown | +| Category | No | Select from existing categories | +| Website | No | URL; shows an Open Graph thumbnail on the note card | +| Attachments | No | Files up to 50 MB; see restrictions below | + +Click **Create** to save. + +## Markdown support + +Note bodies are rendered as GitHub Flavored Markdown with soft line breaks. Supported syntax includes headings, bold/italic, links, ordered and unordered lists, task lists, tables, fenced code blocks, and blockquotes. + +## Pinning + +Click the pin icon on a note card to pin it. Pinned notes sort to the top of the list (above all unpinned notes, regardless of category). Click again (shown as the unpin icon) to unpin. + +## Attachments + +You can attach images, PDFs, and other files to a note (requires the `file_upload` permission). Maximum file size is **50 MB** per file. + +The following file types are blocked: `.svg`, `.html`, `.htm`, `.xml`, `.xhtml`, `.js`, `.jsx`, `.ts`, `.exe`, `.bat`, `.sh`, `.cmd`, `.msi`, `.dll`, `.com`, `.vbs`, `.ps1`, `.php`. + +Image thumbnails are shown on the note card. Click a thumbnail to open a lightbox. PDFs open in a document viewer overlay. + +You can also paste images or PDFs directly into the create/edit form (if the `file_upload` permission is granted). + +## Editing a note + +Click the pencil icon on a note card to open the edit modal. All fields, including attachments, can be updated. To remove an existing attachment, click the **×** next to it in the edit form. + +## Expanding a note + +Click the expand icon (arrows) on a note card to open a full-content view in a portal overlay. Users with the `collab_edit` permission will see a pencil button in the overlay header to switch directly to the edit modal. + +## Filtering + +Use the category filter pills below the Notes header to show only notes belonging to a specific category. Click **All** to clear the filter. + +## Related pages + +[Real-Time-Collaboration](Real-Time-Collaboration) · [Collab-Chat](Collab-Chat) · [Collab-Polls](Collab-Polls) diff --git a/wiki/Collab-Polls.md b/wiki/Collab-Polls.md new file mode 100644 index 0000000000000000000000000000000000000000..3a4ce8a08d27a61a6a6d438b0563ea334d0fb1e7 --- /dev/null +++ b/wiki/Collab-Polls.md @@ -0,0 +1,61 @@ +# Collab Polls + +Create group polls to make decisions collaboratively — where to eat, which hotel, what to do on a free day. + + + +![Collab Polls](assets/Collab.png) + +## Where to find it + +Open the trip planner → **Collab** tab → **Polls** section. The Collab addon must be enabled and the Polls sub-feature must be turned on. See [Real-Time-Collaboration](Real-Time-Collaboration). + +## Creating a poll + +Users with `collab_edit` permission can click **+ New** in the Polls header. A modal opens with the following fields: + +| Field | Required | Notes | +|-------|----------|-------| +| Question | Yes | The poll prompt | +| Options | Yes | At least 2 options required; add more with **+ Add option** | +| Multiple choice | No | Toggle on to allow voters to select more than one option | + +Click **Create** to save and broadcast the poll to all connected members. + +## Voting + +Click an option button to vote. A filled circle and blue highlight indicate your selection. For **multiple-choice** polls, you can click additional options to select more than one; clicking an already-selected option removes your vote for that option. For **single-choice** polls, clicking a different option moves your vote to the new selection. + +Percentage bars and voter avatars are only visible **after you have voted** or once the poll is closed or expired. + +## Results + +Each option shows: + +- A **percentage fill bar** that expands proportionally to the votes received +- Up to **3 voter avatar chips** stacked next to the option +- The **percentage** of total votes in the right margin + +The option with the most votes is highlighted when the poll is closed or expired. + +## Deadline + +Polls may have an optional deadline set via the API. When a deadline is present, a live countdown badge appears on the poll card, updating every **30 seconds**. The badge shows the remaining time in days/hours/minutes format. + +When the deadline passes, the poll is automatically treated as closed: voting is disabled and results are displayed to everyone. + +## Closing a poll manually + +Users with `collab_edit` permission can click the lock icon on an open poll to close it immediately. Once closed, voting is permanently disabled. + +## Deleting a poll + +Users with `collab_edit` permission can delete a poll using the trash icon. Deletion is permanent and removes the poll for all members. + +## Active and closed sections + +Open polls appear at the top of the list. Closed or expired polls move to a **Closed** section below the active polls. + +## Related pages + +[Real-Time-Collaboration](Real-Time-Collaboration) · [Collab-Chat](Collab-Chat) · [Collab-Notes](Collab-Notes) diff --git a/wiki/Contributing.md b/wiki/Contributing.md new file mode 100644 index 0000000000000000000000000000000000000000..5d5c21d0f7c86ad44a12054a566980e45ad33cc6 --- /dev/null +++ b/wiki/Contributing.md @@ -0,0 +1,63 @@ +# Contributing + +Thanks for your interest in contributing to TREK! Here are the guidelines for submitting pull requests. + +## Before You Start + +- **Ask in Discord first** — Before writing any code, pitch your idea in the `#github-pr` channel on our [Discord server](https://discord.gg/NhZBDSd4qW). We'll let you know if the PR is wanted and give direction. PRs without prior approval will be closed +- **Check existing issues** — Look for open issues or discussions before starting work +- **Target the `dev` branch** — All PRs must be opened against `dev`, not `main`. Exception: PRs that only modify files under `wiki/` may target any branch +- **One thing per PR** — Keep PRs focused on a single change. Don't bundle unrelated fixes + +## Pull Request Guidelines + +### Code Quality + +- Write clean, readable code that matches the existing style +- No unnecessary abstractions or over-engineering +- Don't add features beyond what was discussed in the issue +- Don't add comments unless the logic isn't self-evident +- Don't add error handling for scenarios that can't happen + +### What We Look For + +- **Does it solve the stated problem?** — The PR should match the issue it addresses +- **Is it minimal?** — No extra refactoring, no "while I'm here" changes +- **Does it break anything?** — Breaking changes are not acceptable +- **Is the code clean?** — Consistent style, no debug logs, no dead code + +### Commit Messages + +Use conventional commits: +``` +fix(component): short description of what was fixed +feat(component): short description of new feature +``` + +### PR Description + +Follow the template provided by default (.github/PULL_REQUEST_TEMPLATE.md). + +### What Will Get Your PR Closed + +- PRs that weren't discussed and approved in `#github-pr` on Discord first +- PRs that add unnecessary complexity (e.g. a redo button when undo already exists) +- PRs with breaking changes +- PRs that change code style or formatting across unrelated files +- PRs that add dependencies without justification + +## Development Setup + +See the [[Development Environment|Development-environment]] page for the full setup guide, including forking, remote configuration, branch conventions, and available scripts. + +## Tech Stack + +| Layer | Technology | +|---|---------------------------------------------------------------------------------| +| Frontend | React 18, TypeScript, Zustand, Leaflet, Tailwind CSS, Vite | +| Backend | Express, TypeScript, better-sqlite3 | +| Real-time | WebSocket (ws) | +| Database | SQLite with WAL mode | +| Auth | JWT (HS256), bcrypt, TOTP MFA, OIDC | +| Maps | Leaflet + react-leaflet, OSRM, Nominatim, CartoDB tiles | +| i18n | 15 languages (EN, DE, ES, FR, NL, IT, PT-BR, CS, PL, HU, RU, ZH, ZH-TW, AR, ID) | diff --git a/wiki/Creating-a-Trip.md b/wiki/Creating-a-Trip.md new file mode 100644 index 0000000000000000000000000000000000000000..1e8e9bcb86834ebcf7100bb2df674b624553bbbb --- /dev/null +++ b/wiki/Creating-a-Trip.md @@ -0,0 +1,71 @@ +# Creating a Trip + + + +![Trip creation dialog](assets/TripCreate.png) + +## Opening the Dialog + +Click the **New Trip** button in the dashboard toolbar (or the **Create First Trip** button on the empty state) to open the Create Trip dialog. + +You can also open it directly via a deep link: navigate to `/dashboard?create=1`. This is the URL used by system notices that prompt you to create a trip. + +## Fields + +### Title (required) + +The trip name. Cannot be empty — saving is blocked until a title is entered. + +### Description (optional) + +A short free-text description shown on the trip card. + +### Dates + +Set a **Start date** and **End date** using the date picker. The day count is calculated automatically when both are set. + +If you leave **both** dates empty, a separate **Day count** field appears. Enter a number between **1 and 365** to create a date-less itinerary with a fixed number of days. + +You cannot set only one date and leave the other blank via normal interaction — setting a start date auto-fills or adjusts the end date to preserve the previous duration. + +### Cover Image + +The cover image is displayed on the trip card and as the background of the Spotlight card. You can add one in three ways: + +- **Drag and drop** an image file onto the dashed upload area. +- **Paste from clipboard** — if you have an image in your clipboard, paste it anywhere in the dialog. +- **File picker** — click the upload area to browse for a file. + +When **creating** a new trip the cover image field is always visible. When **editing** an existing trip it is only shown if you have the `trip_cover_upload` permission. For a new trip, the image is uploaded immediately after the trip is created. + +### Reminder + +A push notification sent before the trip departs. The field shows a set of preset options: + +| Option | Days before departure | +|---|---| +| None | 0 | +| 1 day | 1 | +| 3 days | 3 | +| 9 days | 9 | +| Custom | 1–30 (you enter the number) | + +When **creating** a new trip the reminder field is always visible. When **editing** an existing trip it is only shown to the **trip owner** or **admin** users. + +If reminders are disabled on your instance (`trip_reminders_enabled = false`), the reminder section is shown at reduced opacity with an informational message in place of the preset buttons. + +> **Admin:** Trip reminders are controlled by a server-side feature flag (`trip_reminders_enabled`). Contact your administrator to enable them. + +### Members + +Add initial trip members from the members selector. On a **new** trip, selected members are queued locally and added to the trip immediately after it is saved. The selector shows all registered users on your instance except yourself. + +## Saving + +Click **Create Trip**. The trip is saved and you are taken to the [Trip-Planner-Overview](Trip-Planner-Overview) for the new trip. + +## Related Pages + +- [Trip-Members-and-Sharing](Trip-Members-and-Sharing) +- [Trip-Planner-Overview](Trip-Planner-Overview) +- [My-Trips-Dashboard](My-Trips-Dashboard) diff --git a/wiki/Dashboard-Widgets.md b/wiki/Dashboard-Widgets.md new file mode 100644 index 0000000000000000000000000000000000000000..58ba21dd9037405b95339fdea72981b6199f6b2b --- /dev/null +++ b/wiki/Dashboard-Widgets.md @@ -0,0 +1,62 @@ +# Dashboard Widgets + +The My Trips dashboard includes two utility widgets: a currency converter and a timezone clock. + + + +![Dashboard Widgets](assets/DashboardWidgets.png) + +## Where they appear + +On large screens (desktop/wide tablet), both widgets appear in a sticky right-hand sidebar of the [My-Trips-Dashboard](My-Trips-Dashboard). On mobile and narrow screens, the widgets are accessible via **Quick Actions** buttons on the dashboard — tapping the Currency or Timezone button opens a bottom sheet containing the full widget. + +Each user configures their own widgets independently. Whether each widget is shown or hidden is saved to your account on the server (synced across devices). The selected currency pair and saved timezone list are stored in your browser's local storage and are device-specific. + +### Showing and hiding widgets + +On desktop, click the **Settings (gear) icon** in the dashboard toolbar to reveal toggle switches for each widget. Turning a widget off removes it from the sidebar; the preference is saved to your account. + +--- + +## Currency Converter + +The currency converter lets you quickly convert an amount between two currencies. + +**How to use:** + +1. Enter an amount in the input field. +2. Select a source currency from the left selector. +3. Select a target currency from the right selector. +4. The converted amount is displayed immediately below. + +You can also click the swap arrow to reverse source and target. + +**Exchange rates** are fetched from [Frankfurter](https://frankfurter.dev) using the `https://api.frankfurter.dev/v2/rates?base={from}` endpoint. Rates are refreshed each time you change a currency or click the refresh icon. + +**Supported currencies:** 162 currencies are available in the selector, including all major fiat currencies (USD, EUR, GBP, JPY, etc.) and many minor ones. + +--- + +## Timezone Clock + +The timezone clock displays live clocks for multiple time zones simultaneously. + +**How to use:** + +- Your local time is always shown at the top. +- Below it, any zones you have added are listed with their current time and offset relative to your local zone. +- Click **+** to add a zone. You can pick from 18 preset city zones, or enter any IANA timezone identifier (e.g. `America/Denver`) with an optional custom label (if omitted, the city portion of the identifier is used as the label). +- Hover over a zone row and click **×** to remove it. + +**Preset zones (18):** + +New York, London, Berlin, Paris, Dubai, Mumbai, Bangkok, Tokyo, Sydney, Los Angeles, Chicago, São Paulo, Istanbul, Singapore, Hong Kong, Seoul, Moscow, Cairo. + +Clocks update every 10 seconds. The 12-hour or 24-hour format follows your display settings (see [Display-Settings](Display-Settings)). + +--- + +## See also + +- [My-Trips-Dashboard](My-Trips-Dashboard) +- [Addons-Overview](Addons-Overview) diff --git a/wiki/Day-Plans-and-Notes.md b/wiki/Day-Plans-and-Notes.md new file mode 100644 index 0000000000000000000000000000000000000000..d9a3773e2142dd9a424f3b6a848474d1ad4e9cf3 --- /dev/null +++ b/wiki/Day-Plans-and-Notes.md @@ -0,0 +1,84 @@ +# Day Plans and Notes + +The Day Plan sidebar lets you organize places into days, add free-form notes, and manage the order of your itinerary. + + + +![Day Plan](assets/TripPlaner.png) + +## The Day Plan sidebar + +The Day Plan sidebar is the left panel in the trip planner. Each trip day is shown as a collapsible section. Expanded or collapsed state is saved per trip in `sessionStorage` (key: `day-expanded-{tripId}`), so your layout is preserved across page reloads in the same browser session. + +## Day timeline + +Each day shows a merged, time-ordered list of: + +- **Assigned places** — with time, category icon, and action buttons +- **Day notes** — with their selected icon and optional time +- **Reservations and transports** — non-hotel types (flights, trains, cars, cruises) appear inline; hotels appear in the Day Detail panel + +Items are sorted by their time or position index. + +## Assigning places to a day + +- **Drag and drop** — drag a place from the right-hand Places sidebar and drop it onto a day section or between existing items. + +![Adding a place by dragging](assets/DayItineraryAddPlaceDragging.gif) + +- **Add button** — Click on the day and then click the **+** button inside an expanded day section to open an inline search panel; find the place and tap it to assign. + +![Adding a place by button](assets/DayItineraryAddPlaceByButton.gif) + +- **Mobile** — tap the **Add Place** button inside an expanded day section to open an inline search panel; find the place and tap it to assign. + +You can also reorder places within a day, or move them to a different day, by dragging and dropping inside the sidebar. + +To remove a place from a day, click the **X** button next to the place in the day timeline. + +![Removing a place by button](assets/DayItineraryRemovePlaceByButton.gif) + +## Multi-day reservations + +A reservation that spans multiple days appears in each relevant day with a phase label: + +| Reservation type | Start day | Middle days | End day | +|---|---|---|---| +| Flight | Departure | In transit | Arrival | +| Car | Pickup | Active | Return | +| Other | Start | Ongoing | End | + +Car rentals that are in the "Active" (middle) phase are shown in the day header rather than the timeline. + +## Day notes + +Click the note **+** button in any day section to add a note. Notes have three fields: + +- **Title** (required) — the main note text shown in the timeline +- **Subtitle / detail** (optional) — a free-form text field (Markdown supported) displayed beneath the title +- **Icon** — choose from 20 icons: FileText, Info, Clock, MapPin, Navigation, Train, Plane, Bus, Car, Ship, Coffee, Ticket, Star, Heart, Camera, Flag, Lightbulb, AlertTriangle, ShoppingBag, Bookmark + +Notes interleave with places and transports in the day timeline and are ordered by their `sort_order`. Use the **↑ / ↓** chevron buttons on a note to reposition it within the merged timeline. Notes can also be repositioned by dragging. + +## Day Detail panel + +Click a day header to open the Day Detail panel. It appears as a floating panel centered in the map area and shows: + +- The weather forecast for that day (see [Weather-Forecasts](Weather-Forecasts)) +- Reservations linked to assignments on that day +- Accommodation block (hotel check-in / check-out, with check-in window and confirmation number) + +The panel can be collapsed to a slim header bar or closed entirely with the **X** button. + +## Toolbar actions + +At the top of the Day Plan sidebar: + +- **Export PDF** — downloads a PDF of the full trip plan. See [PDF-Export](PDF-Export). +- **ICS** — exports the trip as a calendar file (.ics) for import into calendar apps. +- **Expand / Collapse all** — toggles all day sections open or closed at once. +- **Undo** — reverses the last drag, reorder, or assign action. + +Route calculation controls (optimize order, open in Google Maps) appear inside each expanded day section after the place list. + +**See also:** [Places-and-Search](Places-and-Search) · [Map-Features](Map-Features) · [Route-Optimization](Route-Optimization) · [Weather-Forecasts](Weather-Forecasts) · [Reservations-and-Bookings](Reservations-and-Bookings) \ No newline at end of file diff --git a/wiki/Demo-Mode.md b/wiki/Demo-Mode.md new file mode 100644 index 0000000000000000000000000000000000000000..43d62e91fc2cc66c69fd271d098d09dfe2dc7c7f --- /dev/null +++ b/wiki/Demo-Mode.md @@ -0,0 +1,62 @@ +# Demo Mode + +Demo mode lets you run a public "try before you install" instance of TREK. A shared demo account is available for visitors, write operations are blocked for that account, and the database resets automatically every hour so the instance stays in a known state. + + + +## Enabling demo mode + +Set `DEMO_MODE=true` in your environment and restart TREK. See [Environment-Variables](Environment-Variables) for how to set environment variables. + +When demo mode is active, the login page shows a one-click **"Try the demo"** button. Clicking it logs the visitor in as the demo user immediately — no credentials need to be entered and no registration is required. + +**Demo account (auto-created on first start):** + +| Field | Value | +|---|---| +| Email | `demo@trek.app` | +| Password | `demo12345` | + +## What the demo user can and cannot do + +The demo user account has read access to the shared trip data but the following operations are permanently blocked: + +- **Password change** — returns 403. +- **Account deletion** — returns 403. +- **MFA enrollment or removal** — returns 403. +- **File uploads** — avatar uploads, trip cover uploads, and document/photo file attachments are blocked and return 403. +- **All MCP write tools** — create, update, and delete operations via the MCP API are blocked for the demo user. + +Registration is also disabled while demo mode is active — visitors cannot create new accounts. + +The admin account is unaffected and retains full access. + +## Hourly reset + +TREK schedules an automatic hourly reset of the demo database. At each reset: + +1. The current `travel.db` is replaced with the saved baseline (`travel-baseline.db`). +2. The admin account's credentials (`password_hash`, API keys, avatar) are re-applied on top of the restored baseline, so admin API keys and password changes survive the reset. + +If no baseline has been saved yet, the reset is skipped and a message is logged. + +## Saving a baseline + +The baseline is the snapshot the hourly reset restores to. The admin can update it at any time: + +**Endpoint:** `POST /admin/save-demo-baseline` + +This is available in the admin panel. The baseline captures the current state of the database — including trip data, settings, and encrypted API keys — so demo features (maps, photos, weather) continue to work after each reset. + +On first start with demo mode active, TREK seeds three example trips (Tokyo & Kyoto, Barcelona Long Weekend, New York City) owned by the admin and shared with the demo user, then saves the initial baseline automatically. + +## Limitations + +- Demo mode is not for production use with real user data. The hourly reset deletes all visitor-created content. +- All demo visitors share a single account — there is no isolation between sessions. +- File uploads (photos, documents, trip covers, avatars) are disabled for the demo user. + +## See also + +- [Environment-Variables](Environment-Variables) +- [Backups](Backups) diff --git a/wiki/Development-environment.md b/wiki/Development-environment.md new file mode 100644 index 0000000000000000000000000000000000000000..af0af4f4c50111736916bb04bb2c9f088821f459 --- /dev/null +++ b/wiki/Development-environment.md @@ -0,0 +1,243 @@ +# Developer Setup Guide + +> Before anything else, please read the [[Contributing]] guidelines. + +## Prerequisites + +- Node.js 22+ +- npm +- Git +- A GitHub account + +--- + +## 1. Fork & Clone the Repository + +Go to the [TREK repository](https://github.com/mauriceboe/TREK) and click **Fork** to create your own copy. + +Then clone your fork locally: + +```bash +# Clone your fork, checking out the dev branch +git clone -b dev git@github.com:your-username/TREK.git +cd TREK +``` + +--- + +## 2. Configure Git Remotes + +Add the original repository as `upstream` so you can pull in future updates: + +```bash +git remote add upstream git@github.com:mauriceboe/TREK.git +``` + +You should now have two remotes: + +| Remote | URL | Purpose | +|------------|----------------------------------------------|--------------------------------| +| `origin` | `git@github.com:your-username/TREK.git` | Your fork — push changes here | +| `upstream` | `git@github.com:mauriceboe/TREK.git` | Main repo — pull updates from here | + +--- + +## 3. Keep Your Fork Up to Date + +Before starting any work, make sure your local `dev` branch is in sync with upstream: + +```bash +git fetch upstream +git rebase upstream/dev # or: git merge upstream/dev +``` + +--- + +## 4. Create a Feature Branch + +Working on a dedicated branch keeps your changes isolated and makes PRs easier to review: + +```bash +# Create a new branch off of dev +git checkout -b fix/my-changes origin/dev +``` + +Branch naming conventions: +- `feat/short-description` for new features +- `fix/short-description` for bug fixes +- `chore/short-description` for maintenance tasks + +--- + +## 5. Install Dependencies + +The repo is an npm workspace monorepo. One command at the root installs everything: + +```bash +npm ci +``` + +--- + +## 6. Optional: KItinerary (Booking Import) + +The booking-confirmation import feature uses [KDE KItinerary](https://apps.kde.org/itinerary/) to parse travel documents. The server works without it, but the import endpoint will be non-functional. + +### Linux — amd64 + +Download the static binary from the KDE CDN and verify the checksum: + +```bash +wget -qO /tmp/ki.tgz https://cdn.kde.org/ci-builds/pim/kitinerary/release-26.04/linux/kitinerary-extractor-x86_64-26.04.0.tgz +echo "b7058d98990053c7b61847fef0c21e02d59b60e323e2b171ca210b682334e801 /tmp/ki.tgz" | sha256sum -c +sudo tar -xz -C /usr/local -f /tmp/ki.tgz bin/kitinerary-extractor share/locale +rm /tmp/ki.tgz +``` + +### Linux — arm64 + +```bash +sudo apt-get install -y libkitinerary-bin +sudo ln -sf "$(find /usr/lib -name kitinerary-extractor -type f | head -1)" /usr/local/bin/kitinerary-extractor +``` + +### Environment variables + +Add these to your local `.env` (or export them before starting the server): + +```bash +# Required: path to the extractor binary +KITINERARY_EXTRACTOR_PATH=/usr/local/bin/kitinerary-extractor + +# Prevent Qt from probing for a display in headless/server environments +QT_QPA_PLATFORM=offscreen + +# KDE cache directory (avoids writing to $HOME) +XDG_CACHE_HOME=/tmp/kf6-cache +``` + +You can override `KITINERARY_EXTRACTOR_PATH` if you installed the binary to a different location. + +--- + +## 7. Available Scripts + +### Root (`/`) + +These commands run across all workspaces at once and are the recommended way to work: + +| Command | Description | +|----------------------|---------------------------------------------------------------------| +| `npm run dev` | Build shared, then start shared (watch), server, and client together via `concurrently` | +| `npm run build` | Build shared → server → client in order | +| `npm test` | Run tests in shared, server, and client | +| `npm run test:cov` | Run coverage for server and client | +| `npm run test:e2e` | Run end-to-end tests (server) | +| `npm run lint` | Lint shared, server, and client | +| `npm run format` | Format shared, server, and client | +| `npm run format:check` | Check formatting across all workspaces | + +### Shared (`/shared`) + +The `@trek/shared` package is the single source of truth for code shared between the client and server. It holds the **Zod schemas that define the API contracts** (request/response shapes, common primitives, pagination) and the **i18n translation layer** (per-language keys and types). Both workspaces import from it, so schema and translation changes propagate to both sides from one place. + +> **Tip:** run `npm run i18n:parity` (or `i18n:parity:strict`) in this package to verify every locale exposes the same translation keys — the CI parity gate runs the strict variant. + +| Command | Description | +|-----------------------------|--------------------------------------| +| `npm run build` | Compile shared package (tsup) | +| `npm run build:watch` | Compile in watch mode | +| `npm test` | Run tests | +| `npm run typecheck` | Type-check without emitting | +| `npm run i18n:parity` | Check locale key parity | +| `npm run i18n:parity:strict`| Strict locale key parity (CI gate) | +| `npm run lint` | Lint source | +| `npm run format` | Format source | + +### Root (`/`) + +These commands run across all workspaces at once and are the recommended way to work: + +| Command | Description | +|----------------------|---------------------------------------------------------------------| +| `npm run dev` | Build shared, then start shared (watch), server, and client together via `concurrently` | +| `npm run build` | Build shared → server → client in order | +| `npm test` | Run tests in shared, server, and client | +| `npm run test:cov` | Run coverage for server and client | +| `npm run test:e2e` | Run end-to-end tests (server) | +| `npm run lint` | Lint shared, server, and client | +| `npm run format` | Format shared, server, and client | +| `npm run format:check` | Check formatting across all workspaces | + +### Shared (`/shared`) + +The `@trek/shared` package is the single source of truth for code shared between the client and server. It currently holds **Zod schemas that define API contracts** (request/response shapes, common primitives, pagination). Both workspaces import from it so schema changes automatically propagate to both sides. + +> **Upcoming:** the i18n translation layer will be migrated into this package so that translation keys and types are enforced across the stack from one place. + +| Command | Description | +|------------------------|------------------------------------| +| `npm run build` | Compile shared package (tsup) | +| `npm run build:watch` | Compile in watch mode | +| `npm test` | Run tests | +| `npm run typecheck` | Type-check without emitting | +| `npm run lint` | Lint source | +| `npm run format` | Format source | + +### Server (`/server`) + +| Command | Description | +|----------------------------|------------------------------------------| +| `npm start` | Start the server (production) | +| `npm run dev` | Start the server in watch mode | +| `npm run build` | Compile server | +| `npm run typecheck` | Type-check without emitting | +| `npm test` | Run all tests | +| `npm run test:unit` | Run unit tests only | +| `npm run test:integration` | Run integration tests | +| `npm run test:ws` | Run WebSocket tests | +| `npm run test:e2e` | Run end-to-end tests | +| `npm run test:watch` | Run tests in watch mode | +| `npm run test:coverage` | Run tests with coverage report | +| `npm run lint` | Lint source | +| `npm run format` | Format source | + +### Client (`/client`) + +| Command | Description | +|----------------------------|------------------------------------------------------| +| `npm run dev` | Start the Vite dev server | +| `npm run build` | Build for production (runs icon generation first) | +| `npm run preview` | Preview the production build locally | +| `npm test` | Run all tests | +| `npm run test:unit` | Run unit tests only | +| `npm run test:integration` | Run integration tests | +| `npm run test:watch` | Run tests in watch mode | +| `npm run test:coverage` | Run tests with coverage report | +| `npm run lint` | Lint source | +| `npm run format` | Format source | + +--- + +## 8. Commit & Push Your Changes + +```bash +git add . +git commit -m "fix: describe your change" + +# Push to your fork's dev branch +git push origin fix/my-changes + +# Or if working directly on dev +git push origin dev +``` + +Then open a Pull Request from your fork to `mauriceboe/TREK` targeting the `dev` branch. If your PR only modifies files under `wiki/`, it is exempt from branch enforcement and may target any branch. + +--- + +## Tips + +- Always branch off from an up-to-date `dev` — run `git fetch upstream && git rebase upstream/dev` before starting new work. +- Run tests before pushing: `npm test` at the repo root runs all workspaces. +- Follow the commit message conventions described in the [[Contributing]] guidelines. \ No newline at end of file diff --git a/wiki/Display-Settings.md b/wiki/Display-Settings.md new file mode 100644 index 0000000000000000000000000000000000000000..b35df364641dd2bf2046f48e5f1742215ddcdce4 --- /dev/null +++ b/wiki/Display-Settings.md @@ -0,0 +1,56 @@ +# Display Settings + +The Display tab (Settings → Display) controls the visual appearance and locale preferences of the app. All changes save immediately to your account and persist across devices. + + + +![Display Settings](assets/UsrSettings.png) + +## Color mode + +Choose between three options: + +| Option | Behaviour | +|--------|-----------| +| Light | Always uses the light theme | +| Dark | Always uses the dark theme | +| Auto | Follows your operating system / browser preference | + +## Language + +Select your preferred language from the button grid (desktop) or dropdown (mobile). The change takes effect immediately without a page reload. See [Languages](Languages) for the full list of supported languages. + +## Temperature unit + +Affects the weather widget on trip days. + +| Option | Display | +|--------|---------| +| °C Celsius | Metric | +| °F Fahrenheit | Imperial | + +## Time format + +Affects all time displays throughout the app. + +| Option | Example | +|--------|---------| +| 24h | 14:30 | +| 12h | 2:30 PM | + +## Route calculation + +Toggles automatic route calculation between places on the trip map. Set to **On** or **Off**. + +## Booking route labels + +Shows or hides labels on booking-related route segments on the map. Set to **On** or **Off**. + +## Blur booking codes + +When enabled, confirmation codes and reference numbers are blurred until you hover or tap. Set to **On** or **Off**. + +## See also + +- [Languages](Languages) +- [User-Settings](User-Settings) diff --git a/wiki/Documents-and-Files.md b/wiki/Documents-and-Files.md new file mode 100644 index 0000000000000000000000000000000000000000..1ba09ebe3433cc51622fe86804d3689a688d4e78 --- /dev/null +++ b/wiki/Documents-and-Files.md @@ -0,0 +1,76 @@ +# Documents and Files + +Attach and manage documents, tickets, and other files for your trip. + + + +![Files](assets/Files.png) + +## Where to find it + +Open the **Files** tab inside the trip planner, or navigate directly to `/trips/:id/files`. + +> **Admin:** Files is an addon. Enable it in [Admin-Addons](Admin-Addons). + +## Uploading + +Drag and drop files onto the upload area, click it to open the file picker, or paste an image directly into the Files panel. + +- **Maximum file size:** 50 MB per file. +- **Blocked file types:** `.svg`, `.html`, `.htm`, `.xml` — these are always rejected. +- **Default allowed types:** jpg, jpeg, png, gif, webp, heic, pdf, doc, docx, xls, xlsx, txt, csv, pkpass. An admin can customize the allowed list in [Admin-Addons](Admin-Addons). + +Requires the `file_upload` permission. + +## Browsing and filtering + +The toolbar provides filter tabs: **All**, **PDF**, **Images**, **Docs**, and conditionally **Starred** (only shown when at least one file is starred) and **Collab** (only shown when files exist from collaborative notes). Each tab shows a count badge. + +## Previewing files + +Clicking a non-image file (e.g., PDF) opens an inline preview modal with options to open in a new tab or download. Clicking an image file opens a full-screen lightbox. You can: + +- Navigate between images using the **arrow buttons** or the **left/right arrow keys**. +- Swipe left/right on touch devices. +- Jump to a specific image using the **thumbnail strip** at the bottom. +- Download or open the image in a new tab from the lightbox header. + +## Starring + +Click the **star icon** on any file to favorite it. Starred files sort to the top of the list and can be filtered with the Starred tab. + +Requires the `file_edit` permission. + +## Trash + +Deleting a file moves it to the trash. Switch to the trash view using the **Trash** button in the toolbar. From the trash view you can: + +- **Restore** a file to make it active again. +- **Permanently delete** a single file. +- **Empty trash** to permanently remove all trashed files at once. + +Restore and delete operations require the `file_delete` permission. + +## Linking files to places, reservations, or assignments + +A file can be attached to multiple places and reservations at the same time (many-to-many). From the file manager, click the **link (pencil) icon** on a file to open the assign modal. From there you can toggle links to any trip place or reservation. You can also add a descriptive note to the file in the same modal. + +From a reservation modal, use the "link existing file" picker to attach files directly. + +## Downloading + +Click the download icon on any file row to download it. `.pkpass` files (Apple Wallet passes) are served with the `application/vnd.apple.pkpass` MIME type, so Safari on iOS and macOS offers to add the pass to Wallet instead of saving it as a generic download. + +## Permissions + +| Permission | Controls | +|---|---| +| `file_upload` | Uploading new files. | +| `file_edit` | Starring and linking files. | +| `file_delete` | Moving to trash, restoring, and permanently deleting. | + +## See also + +- [Reservations-and-Bookings](Reservations-and-Bookings) +- [Admin-Addons](Admin-Addons) +- [Trip-Planner-Overview](Trip-Planner-Overview) diff --git a/wiki/Encryption-Key-Rotation.md b/wiki/Encryption-Key-Rotation.md new file mode 100644 index 0000000000000000000000000000000000000000..867e218cfc32a6dfe78a0ef74523ba4e7f7e078a --- /dev/null +++ b/wiki/Encryption-Key-Rotation.md @@ -0,0 +1,85 @@ +# Encryption Key Rotation + +## What the encryption key protects + +TREK encrypts sensitive settings at rest using AES-256-GCM. The following values are stored encrypted in the database: + +- Google Maps API key (per user) +- Mapbox access token (per user) +- OpenWeather API key (per user) +- Immich API key (per user) +- Synology Photos password, session ID, and device ID (per user) +- Per-user webhook URL and ntfy notification token (in `settings` table) +- OIDC client secret (global, in `app_settings`) +- SMTP password (global, in `app_settings`) +- Admin webhook URL and admin ntfy token (global, in `app_settings`) +- MFA (TOTP) secrets for all users +- Photo passphrases for Synology shared-link photos (in `trek_photos`) + +The encryption derives a key from `ENCRYPTION_KEY` using SHA-256 (with a domain suffix per secret type), so the raw `ENCRYPTION_KEY` value is never stored in the database. + +## Key resolution order + +On startup, TREK resolves the encryption key in this order: + +1. **`ENCRYPTION_KEY` environment variable** — explicit, always takes priority. When set, the value is also written to `./data/.encryption_key` so it survives container restarts if the env var is later removed. +2. **`./data/.encryption_key` file** — present on any install that has started at least once. +3. **`./data/.jwt_secret` file** — one-time fallback for older installs that pre-date the dedicated encryption key. The value is immediately persisted to `./data/.encryption_key` so future JWT rotations cannot break decryption. +4. **Auto-generated** — fresh install with none of the above. A random 32-byte hex key is generated and written to `./data/.encryption_key`. + +## What happens if the key is lost + +All encrypted settings (API keys, SMTP password, OIDC secret, MFA secrets, notification tokens, etc.) become unreadable — TREK cannot decrypt them. They must be re-entered manually after the key is restored or replaced. Unencrypted data (trips, places, users, etc.) is unaffected. + +## Backing up the key + +Your backup ZIP does **not** include the encryption key. Store the key separately from your backups — for example, in a password manager or a secrets manager. See [Backups](Backups). + +To find your current key: check the `ENCRYPTION_KEY` environment variable or read `./data/.encryption_key`. + +## Rotating the key + +Use `scripts/migrate-encryption.ts` to re-encrypt all stored secrets without downtime or manual re-entry. + +**Docker:** + +```bash +docker exec -it trek node --import tsx scripts/migrate-encryption.ts +``` + +**Host (run from the `server/` directory):** + +```bash +node --import tsx scripts/migrate-encryption.ts +``` + +The script: + +1. Prompts for the old and new encryption keys interactively (keys are never echoed to the terminal or written to shell history). +2. Asks for confirmation before making any changes. +3. Creates a timestamped backup of the database (e.g. `travel.db.backup-1713484800000`) before modifying anything. +4. Re-encrypts all stored secrets across all tables: + - `app_settings`: `oidc_client_secret`, `smtp_pass`, `admin_webhook_url`, `admin_ntfy_token` + - `users` (per user): `maps_api_key`, `openweather_api_key`, `immich_api_key`, `synology_password`, `synology_sid`, `synology_did`, `mfa_secret` + - `settings` (per user): `webhook_url`, `ntfy_token`, `mapbox_access_token` + - `trip_album_links`: `passphrase` + - `trek_photos`: `passphrase` +5. Reports counts of migrated, already-migrated, skipped (empty), and errored values. + +After a successful migration: + +1. Update `ENCRYPTION_KEY` in your environment to the new value. +2. Restart TREK. + +If any secrets could not be migrated, the script exits with a non-zero status and the original database backup is retained. + +## Upgrading from very old versions + +Old installs may have used `./data/.jwt_secret` as the encryption source (before a dedicated `ENCRYPTION_KEY` was introduced). The key resolution chain above handles this automatically on startup — the JWT secret is read, immediately written to `./data/.encryption_key`, and JWT rotation is then safe without breaking decryption. + +## See also + +- [Backups](Backups) +- [Security-Hardening](Security-Hardening) +- [Environment-Variables](Environment-Variables) +- [User-Settings](User-Settings) diff --git a/wiki/Environment-Variables.md b/wiki/Environment-Variables.md new file mode 100644 index 0000000000000000000000000000000000000000..4cb7b3d9854ff0550f4bb626a757cdcebc3013bc --- /dev/null +++ b/wiki/Environment-Variables.md @@ -0,0 +1,165 @@ +# Environment Variables + +Complete reference for all environment variables TREK reads. + +## How to Set Variables + +- **Docker Compose** — use the `environment:` block or a `.env` file alongside `docker-compose.yml` +- **Docker run** — pass each variable with `-e VARIABLE=value` +- **Helm** — use `env:` for plain values and `secretEnv:` for sensitive values in `values.yaml` +- **Unraid** — set in the container template editor + +--- + +## Core + +| Variable | Description | Default | +|---|---|---| +| `PORT` | Server port | `3000` | +| `HOST` | Bind address for the HTTP server (e.g. `127.0.0.1`, `10.0.0.72`). **Source / Proxmox installs only** — do not set this in Docker or any containerized deployment. See note below. | all interfaces | +| `NODE_ENV` | Environment (`production` / `development`) | `production` | +| `ENCRYPTION_KEY` | At-rest encryption key — see resolution order below | auto | +| `TZ` | Timezone for logs, reminders, and cron jobs (e.g. `Europe/Berlin`) | `UTC` | +| `LOG_LEVEL` | `info` = concise user actions; `debug` = verbose details | `info` | +| `DEFAULT_LANGUAGE` | Default language on the login page — see supported codes below | `en` | +| `SESSION_DURATION` | How long a login session stays valid before re-login is required. Used when **"Remember me" is unchecked** on the login form (the default): applies to the `trek_session` JWT `exp` claim, and the cookie is issued as a **browser-session cookie** (no `maxAge`, cleared when the browser closes). Accepts `ms`-style strings: `1h`, `12h`, `7d`, `30d`, `90d`. Invalid values warn at startup and fall back to the default. Does not affect the short-lived MFA challenge token or MCP OAuth tokens (those keep their own TTL). | `24h` | +| `SESSION_DURATION_REMEMBER` | Session length used when the user **ticks "Remember me"** on login: a longer-lived JWT `exp` claim plus a **persistent** `trek_session` cookie whose `maxAge` matches, so the session survives browser restarts. Same `ms`-style format and startup-fallback behaviour as `SESSION_DURATION`. | `30d` | +| `ALLOWED_ORIGINS` | Comma-separated origins for CORS and email notification links | same-origin | +| `ALLOW_INTERNAL_NETWORK` | Allow outbound requests to private/RFC-1918 IPs. Set `true` if Immich or other integrated services are on your local network. Loopback (`127.x`) and link-local (`169.254.x`) addresses remain blocked regardless. | `false` | +| `APP_URL` | Public base URL (e.g. `https://trek.example.com`). Required when OIDC is enabled — must match the redirect URI registered with your IdP. Also used as the base URL for email notification links. | — | + +### `HOST` — Source and Proxmox installs only + +By default TREK binds to all network interfaces (`0.0.0.0`), which is the correct behaviour inside a container because Docker handles port exposure at the host level. Setting `HOST` overrides the bind address at the Node.js level. + +**When to use it:** only when running TREK directly on a host (git sources or the [Proxmox community script](Install-Proxmox)) and you need to restrict which interface the server listens on — for example, to expose TREK only on a LAN interface while keeping it off the public-facing one. + +**Never set `HOST` in Docker, Docker Compose, Helm, or Unraid deployments.** Use Docker's `-p ::` syntax or your orchestrator's port binding instead. + +``` +# .env — source / Proxmox installs only +HOST=10.0.0.72 # bind only on this LAN interface +PORT=3001 +``` + +When `HOST` is set, the startup banner includes a `Host:` line confirming the bound address. + +### `ENCRYPTION_KEY` — Resolution Order + +`server/src/config.ts` resolves the encryption key in this order: + +1. **`ENCRYPTION_KEY` env var** — explicit value, always takes priority. Persisted to `data/.encryption_key` automatically. +2. **`data/.encryption_key` file** — present on any install that has started at least once. +3. **`data/.jwt_secret` file** — one-time fallback for existing installs upgrading without a pre-set key. The value is immediately persisted to `data/.encryption_key` so JWT rotation cannot break decryption later. +4. **Auto-generated** — fresh install with none of the above; persisted to `data/.encryption_key`. + +Setting `ENCRYPTION_KEY` explicitly is recommended so you can back it up independently of the data volume. + +### `DEFAULT_LANGUAGE` — Supported Codes + +Verified in `server/src/config.ts` (line 107): + +`de`, `en`, `es`, `fr`, `hu`, `nl`, `br`, `cs`, `pl`, `ru`, `zh`, `zh-TW`, `it`, `ar` + +> **Note:** `id` (Indonesian / Bahasa Indonesia) appears in `client/src/i18n/supportedLanguages.ts` but is not in the server's supported-codes list in `config.ts`. Setting `DEFAULT_LANGUAGE=id` will fall back to `en` with a warning in the server log. + +--- + +## HTTPS / Proxy + +These three variables work together behind a TLS-terminating reverse proxy. See [Reverse-Proxy](Reverse-Proxy) for the full explanation. + +| Variable | Description | Default | +|---|---|---| +| `FORCE_HTTPS` | When `true`: 301-redirects HTTP→HTTPS, sends HSTS (`max-age=31536000`), adds CSP `upgrade-insecure-requests`, forces cookie `secure` flag. Only useful behind a TLS proxy. Requires `TRUST_PROXY`. | `false` | +| `HSTS_INCLUDE_SUBDOMAINS` | When `true`: adds the `includeSubDomains` directive to the HSTS header, extending HTTPS enforcement to all subdomains. Only effective when HSTS is active (`FORCE_HTTPS=true` or `NODE_ENV=production`). Leave `false` if you run other services on sibling subdomains over plain HTTP. | `false` | +| `TRUST_PROXY` | Number of trusted proxy hops. Tells Express to read the real client IP from `X-Forwarded-For` and protocol from `X-Forwarded-Proto`. Defaults to `1` automatically in production. Required for `FORCE_HTTPS` to detect the forwarded protocol. | `1` (production) | +| `COOKIE_SECURE` | Controls the `secure` flag on the `trek_session` cookie. Auto-derived as `true` when `NODE_ENV=production` or `FORCE_HTTPS=true`. Set to `false` only as an escape hatch for LAN testing without TLS — not recommended in production. | auto | + +> **Warning:** `FORCE_HTTPS=true` without `TRUST_PROXY` set causes a redirect loop. + +--- + +## OIDC / SSO + +For setup instructions, see [OIDC-SSO](OIDC-SSO). + +| Variable | Description | Default | +|---|---|---| +| `OIDC_ISSUER` | OpenID Connect provider URL (e.g. `https://auth.example.com`) | — | +| `OIDC_CLIENT_ID` | OIDC client ID | — | +| `OIDC_CLIENT_SECRET` | OIDC client secret | — | +| `OIDC_DISPLAY_NAME` | Label shown on the SSO login button | `SSO` | +| `OIDC_ONLY` | Force SSO-only mode: disables password login and registration, overrides Admin > Settings toggles, cannot be changed at runtime. First SSO login becomes admin on a fresh instance. | `false` | +| `OIDC_ADMIN_CLAIM` | OIDC claim used to identify admin users (e.g. `groups`) | — | +| `OIDC_ADMIN_VALUE` | Value of the OIDC claim that grants admin role (e.g. `app-trek-admins`) | — | +| `OIDC_SCOPE` | Space-separated OIDC scopes to request. **Fully replaces** the default — always include `openid email profile` plus any extra scopes (e.g. add `groups` when using `OIDC_ADMIN_CLAIM`) | `openid email profile` | +| `OIDC_DISCOVERY_URL` | Override the auto-constructed OIDC discovery endpoint. Required for providers with a non-standard path (e.g. Authentik) | — | + +--- + +## Email / SMTP + +SMTP settings can be configured via the Admin panel or overridden with environment variables. Env vars take priority over the database values. + +| Variable | Description | Default | +|---|---|---| +| `SMTP_HOST` | SMTP server hostname (e.g. `smtp.example.com`) | — | +| `SMTP_PORT` | SMTP server port. Port `465` enables implicit TLS (`secure: true`); all other ports use STARTTLS or plain. | — | +| `SMTP_USER` | SMTP authentication username | — | +| `SMTP_PASS` | SMTP authentication password | — | +| `SMTP_FROM` | Sender address for outbound emails (e.g. `TREK `) | — | +| `SMTP_SKIP_TLS_VERIFY` | Set `true` to disable TLS certificate validation. Useful for self-signed certs on internal SMTP relays — not recommended in production. | `false` | + +`SMTP_HOST`, `SMTP_PORT`, and `SMTP_FROM` are all required for email delivery to work. `SMTP_USER` and `SMTP_PASS` are optional (for unauthenticated relays). + +--- + +## Initial Setup + +These variables only take effect on first boot, before any user exists. + +| Variable | Description | Default | +|---|---|---| +| `ADMIN_EMAIL` | Email for the first admin account | `admin@trek.local` | +| `ADMIN_PASSWORD` | Password for the first admin account | random | + +Both variables must be set together. If either is omitted, the account is created with email `admin@trek.local` and a randomly generated password that is printed to the server log. Once any user exists, these variables have no effect. + +--- + +## MCP + +For setup instructions, see [MCP-Overview](MCP-Overview). + +| Variable | Description | Default | +|---|---|---| +| `MCP_RATE_LIMIT` | Max MCP API requests per user per minute | `300` | +| `MCP_MAX_SESSION_PER_USER` | Max concurrent MCP sessions per user | `20` | + +--- + +## Booking Import (KDE Itinerary) + +| Variable | Description | Default | +|---|---|---| +| `KITINERARY_EXTRACTOR_PATH` | Full path to the `kitinerary-extractor` binary. When unset, TREK searches `/usr/lib/*/libexec/kf6/kitinerary-extractor` and then `PATH`. Set this if you install the binary to a non-standard location. | auto-detected | + +The official TREK Docker image bundles the binary automatically: on amd64 it downloads the static release from `https://cdn.kde.org/ci-builds/pim/kitinerary/`; on arm64 it installs `libkitinerary-bin` via apt (Debian trixie). When running TREK from source, install `libkitinerary-bin` (Debian trixie / Ubuntu 25.04+) or download the static binary directly and place it anywhere on `PATH`. The `GET /api/health/features` endpoint returns `{ "bookingImport": true }` when the binary is found, and the Import button in the Reservations panel is hidden when it is not. + +--- + +## Other + +| Variable | Description | Default | +|---|---|---| +| `DEMO_MODE` | Enable demo mode (hourly data resets). Not intended for regular use. | `false` | + +--- + +## Related Pages + +- [Reverse-Proxy](Reverse-Proxy) — HTTPS proxy setup and the `FORCE_HTTPS` / `TRUST_PROXY` / `COOKIE_SECURE` trio +- [OIDC-SSO](OIDC-SSO) — complete OIDC configuration guide +- [MCP-Overview](MCP-Overview) — MCP server setup and rate limiting +- [Encryption-Key-Rotation](Encryption-Key-Rotation) — rotating the `ENCRYPTION_KEY` without losing data diff --git a/wiki/FAQ.md b/wiki/FAQ.md new file mode 100644 index 0000000000000000000000000000000000000000..d969c3fed0e67db96fd704a7af11c3c4e879de37 --- /dev/null +++ b/wiki/FAQ.md @@ -0,0 +1,42 @@ +# FAQ + +## Do I need a Google Maps API key? + +No. When no Google Maps key is configured, TREK automatically falls back to OpenStreetMap (Nominatim) for place search — no API key or account required. If you want richer place data (photos, ratings, opening hours), an admin can optionally add a Google Maps key in [User Settings](User-Settings). + +## Can I use TREK offline? + +Yes. TREK is a Progressive Web App. After your first visit, the service worker (powered by Workbox) caches map tiles (Carto and OpenStreetMap), non-sensitive API responses, uploaded covers and avatars, and all static assets. Subsequent visits work without a network connection for already-cached content. See [Offline Mode and PWA](Offline-Mode-and-PWA) for installation instructions. + +> **Note:** Auth, admin, backup, and settings endpoints are intentionally excluded from the offline cache. + +## How many MCP tokens can I create? + +Each user can create up to **10 static API tokens**. Static tokens are deprecated — migrate to OAuth 2.1 when possible. + +For OAuth 2.1, each user can register up to **10 OAuth clients**. The default limit for concurrent MCP sessions is **20 per user** (configurable via `MCP_MAX_SESSION_PER_USER`). See [MCP Setup](MCP-Setup). + +> **Admin:** MCP must be enabled in Admin Panel > Addons before any user can access it. + +## Where is my data stored? + +| Type | Path | +|------|------| +| Database | `./data/travel.db` (SQLite) | +| Uploads | `./uploads/` | +| Logs | `./data/logs/trek.log` (auto-rotated) | +| Backups | `./data/backups/` | + +When running in Docker, mount `./data` and `./uploads` as volumes so your data survives container updates. See [Install: Docker Compose](Install-Docker-Compose). + +## How do I update TREK? + +Pull the new image and recreate the container. Your data is in the mounted volumes and is never modified by the update process. See [Updating](Updating) for the exact commands. + +## Can I restrict who can register? + +Yes. An admin can disable open registration so that new accounts can only be created via invite links. See [Admin: Users and Invites](Admin-Users-and-Invites). + +## Does TREK support single sign-on? + +Yes, via OpenID Connect (OIDC). Compatible providers include Google, Authentik, Keycloak, and any standard OIDC-compliant IdP. Set `OIDC_ONLY=true` to disable password login entirely. See [OIDC SSO](OIDC-SSO). diff --git a/wiki/Home.md b/wiki/Home.md new file mode 100644 index 0000000000000000000000000000000000000000..81f8ff682c149de46e667243f2a92ba88faf6876 --- /dev/null +++ b/wiki/Home.md @@ -0,0 +1,68 @@ +# TREK Wiki + +TREK is a self-hosted, real-time collaborative travel planner licensed under AGPL-3.0. + +![Dashboard](assets/DashboardWidgets.png) + +## Features + +### Planning +- **Drag & Drop Planner** — organize places into day plans with reordering and cross-day moves +- **Interactive Map** — Leaflet map with photo markers, clustering, route visualization, and customizable tile sources +- **Place Search** — Google Places (photos, ratings, hours) or OpenStreetMap (free, no API key needed) +- **Day Notes** — timestamped, icon-tagged notes per day +- **Route Optimization** — auto-optimize place order and export to Google Maps +- **Weather Forecasts** — 16-day forecasts via Open-Meteo (no API key required), historical climate averages as fallback + +### Travel Management +- **Reservations & Bookings** — track flights, accommodations, restaurants with confirmation numbers and file attachments +- **Budget Tracking** — category-based expenses with pie chart, per-person/per-day splitting, multi-currency support +- **Packing Lists** — category-based checklists with user assignment, templates, and progress tracking +- **Document Manager** — attach documents, tickets, and PDFs to trips, places, or reservations (up to 50 MB per file) +- **PDF Export** — export complete trip plans as PDF with cover page, images, and notes + +### Collaboration +- **Real-Time Sync** — WebSocket-based live sync; changes appear instantly for all connected users +- **Multi-User** — invite members with role-based access +- **Invite Links** — one-time registration links with configurable max uses and expiry +- **OIDC SSO** — sign in with Google, Apple, Authentik, Keycloak, or any OIDC provider +- **Two-Factor Authentication** — TOTP-based 2FA with QR code setup +- **Public Share Links** — share a read-only view of any trip + +### Addons _(admin-toggleable)_ +- **Lists** — packing lists and to-dos with templates, member assignments, optional bag tracking +- **Budget Planner** — expense tracker with category breakdown, splits, multi-currency +- **Documents** — file manager for trips, places, and reservations +- **Collab** — group chat, shared notes, polls, day-by-day attendance +- **Vacay** — personal vacation day planner with calendar view, public holidays, and carry-over tracking +- **Atlas** — interactive world map, bucket list, travel stats, continent breakdown +- **Journey** — magazine-style travel journal with entries, photos (via Immich/Synology Photos), maps, and moods +- **Naver List Import** — import places from shared Naver Maps lists +- **MCP** — expose TREK to AI assistants via the Model Context Protocol (OAuth 2.1) + +> Dashboard widgets (currency converter and timezone clock) are per-user preferences, not an admin-toggleable addon — see [Dashboard-Widgets](Dashboard-Widgets). + +### AI / MCP Integration +- **MCP Server** — built-in Model Context Protocol server with OAuth 2.1 authentication +- **150+ Tools** — create trips, plan itineraries, manage budgets, send messages, and more +- **30 Resources** — read-only `trek://` URIs for trips, days, places, budget, packing, journeys, and more +- **27 OAuth Scopes** — granular permissions across 13 permission groups +- **Pre-built Prompts** — `trip-summary`, `packing-list`, and `budget-overview` context loaders + +### Admin +- User management, invite links, packing templates, global categories +- Addon management, API key storage, scheduled auto-backups +- System notices for onboarding and announcements + +> **Admin:** Most configuration lives in the Admin Panel. On first boot TREK seeds an admin account automatically — credentials come from `ADMIN_EMAIL` / `ADMIN_PASSWORD` if set, otherwise a random password is printed to the container log. + +## Get Started + +| | | +|---|---| +| [Quick Start](Quick-Start) | Install in minutes with a single Docker command | +| [My Trips Dashboard](My-Trips-Dashboard) | Start planning your first trip | +| [Admin Panel](Admin-Panel-Overview) | Configure your instance | +| [MCP / AI Integration](MCP-Overview) | Connect Claude, Cursor, or any MCP client | +| [Contributing](Contributing) | Guidelines for submitting pull requests | +| [Development Environment](Development-environment) | Set up a local dev environment | diff --git a/wiki/Install-Docker-Compose.md b/wiki/Install-Docker-Compose.md new file mode 100644 index 0000000000000000000000000000000000000000..c12806ac0477ba854df8d3d7d0f1fff12024d078 --- /dev/null +++ b/wiki/Install-Docker-Compose.md @@ -0,0 +1,100 @@ +# Install: Docker Compose + +Production-ready setup using Docker Compose with security hardening enabled. + +## Compose File + +See https://github.com/mauriceboe/TREK/blob/main/docker-compose.yml + +## Security Hardening Explained + +The compose file ships with several hardening options enabled by default: + +| Setting | What it does | +|---|---| +| `read_only: true` | Mounts the container filesystem read-only; only the two named volumes and `/tmp` are writable | +| `security_opt: no-new-privileges:true` | Prevents the process from gaining additional Linux privileges via setuid/setgid executables | +| `cap_drop: [ALL]` | Drops all Linux capabilities from the container | +| `cap_add: [CHOWN, SETUID, SETGID]` | Adds back only the capabilities needed for the entrypoint to drop privileges to the `node` user | +| `tmpfs: /tmp:noexec,nosuid,size=64m` | Mounts a 64 MB in-memory `/tmp`; required because the container root is read-only | + +## Volumes + +| Host path | Container path | Contents | +|---|---|---| +| `./data` | `/app/data` | SQLite database, logs, `.jwt_secret`, `.encryption_key` | +| `./uploads` | `/app/uploads` | Uploaded files (photos, documents, covers, avatars) | + +### Named Volumes + +The compose file above uses bind mounts (`./data`, `./uploads`). You can switch to Docker named volumes, which are fully managed by Docker and not tied to a specific host path. See the [Docker Compose volumes reference](https://docs.docker.com/reference/compose-file/volumes/) for all options. + +```yaml +services: + app: + # ... (rest of service config unchanged) + volumes: + - trek_data:/app/data + - trek_uploads:/app/uploads + +volumes: + trek_data: + trek_uploads: +``` + +Docker creates the volumes automatically on first `docker compose up`. Use `docker volume ls` and `docker volume inspect` to manage them. + +## Environment Variables + +The compose file reads variables from a `.env` file placed alongside `docker-compose.yml`. At minimum, set: + +```bash +# .env +ENCRYPTION_KEY= +TZ=Europe/Berlin +ALLOWED_ORIGINS=https://trek.example.com +APP_URL=https://trek.example.com +``` + +Uncomment and fill in the OIDC, initial setup, or MCP variables as needed. For a full description of every variable, see [Environment-Variables](Environment-Variables). + +## Image Tags + +Three tag strategies are available: + +| Tag | Example | Behavior | +|---|---|---| +| `latest` | `mauriceboe/trek:latest` | Always the newest release across all major versions | +| Major version | `mauriceboe/trek:3` | Latest release pinned to that major version | +| Full version | `mauriceboe/trek:3.0.15` | Exact release; never changes | + +The compose file above uses `latest`. To pin, change the `image:` line: + +```yaml +image: mauriceboe/trek:3 # track major version 3 +image: mauriceboe/trek:3.0.15 # pin to exact release +``` + +## Start TREK + +```bash +docker compose up -d +``` + +Check the logs: + +```bash +docker compose logs -f +``` + +## HTTPS and Reverse Proxy + +This compose file is designed for deployments where a reverse proxy (nginx, Caddy, Traefik) terminates TLS in front of TREK. To enable HTTPS redirects and secure cookies, uncomment `FORCE_HTTPS=true` and `TRUST_PROXY=1`. + +See [Reverse-Proxy](Reverse-Proxy) for complete proxy configuration examples. + +## Next Steps + +- [Environment-Variables](Environment-Variables) — full variable reference +- [Reverse-Proxy](Reverse-Proxy) — HTTPS configuration +- [Updating](Updating) — how to pull a new image diff --git a/wiki/Install-Docker.md b/wiki/Install-Docker.md new file mode 100644 index 0000000000000000000000000000000000000000..6443ebc4a65c92e432aa00cf6fa593bd18b02a7f --- /dev/null +++ b/wiki/Install-Docker.md @@ -0,0 +1,103 @@ +# Install: Docker + +Single-container Docker run — suitable for testing or simple personal installs. + +## Run Command + +```bash +docker run -d \ + --name trek \ + -p 3000:3000 \ + -v ./data:/app/data \ + -v ./uploads:/app/uploads \ + -e ENCRYPTION_KEY= \ + --restart unless-stopped \ + mauriceboe/trek:latest +``` + +`ENCRYPTION_KEY` is strongly recommended but not strictly required. If omitted, a key is auto-generated on first start and persisted to `data/.encryption_key`. Setting it explicitly means you can recreate the container from scratch (e.g. on a new host) without losing access to stored encrypted data (API keys, SMTP credentials, OIDC secrets, MFA secrets). + +Generate an encryption key with: + +```bash +openssl rand -hex 32 +``` + +### Common optional variables + +Pass additional `-e` flags for timezone and CORS/email link support: + +```bash + -e TZ=Europe/Berlin \ + -e ALLOWED_ORIGINS=https://trek.example.com \ +``` + +See [Environment-Variables](Environment-Variables) for the full list. + +## Image Tags + +| Tag | Example | Behavior | +|---|---|---| +| `latest` | `mauriceboe/trek:latest` | Always the newest release across all major versions | +| Major version | `mauriceboe/trek:3` | Latest release pinned to that major version | +| Full version | `mauriceboe/trek:3.0.15` | Exact release; never changes | + +Replace `mauriceboe/trek:latest` in the run command with your chosen tag to pin to a major version or exact release. + +## Volume Reference + +| Volume | Container path | What lives there | +|---|---|---| +| `./data` | `/app/data` | `travel.db` (SQLite database), `logs/trek.log`, `.jwt_secret`, `.encryption_key` | +| `./uploads` | `/app/uploads` | Uploaded files (photos, documents, covers, avatars) | + +Both volumes must survive container replacement — they are your persistent state. Never remove them before pulling a new image. + +### Named Volumes + +The run command above uses bind mounts (`./data`, `./uploads`). You can use Docker named volumes instead, which are fully managed by Docker and not tied to a host path: + +```bash +docker run -d \ + --name trek \ + -p 3000:3000 \ + -v trek_data:/app/data \ + -v trek_uploads:/app/uploads \ + -e ENCRYPTION_KEY= \ + --restart unless-stopped \ + mauriceboe/trek:latest +``` + +Docker creates `trek_data` and `trek_uploads` automatically on first run. Named volumes are easier to manage with `docker volume` commands and work better in some NAS or container-management environments. + +## Health Check + +The container exposes a health endpoint at: + +``` +http://localhost:3000/api/health +``` + +Docker polls it automatically (interval: 30 s, timeout: 5 s, retries: 3, start period: 15 s). You can check it manually: + +```bash +curl -s http://localhost:3000/api/health +``` + +## Verify the Container Is Running + +```bash +docker ps --filter name=trek +docker logs trek +``` + +## Limitations of `docker run` + +A bare `docker run` command has no built-in secret management and is harder to reproduce after a system reboot. For production, see [Install-Docker-Compose](Install-Docker-Compose), which adds security hardening (`read_only`, `cap_drop`, `cap_add`, `no-new-privileges`, `tmpfs`) and makes it easy to manage environment variables through a `.env` file. + +## Next Steps + +- [Reverse-Proxy](Reverse-Proxy) — HTTPS is required for PWA install and the `trek_session` cookie `secure` flag +- [Install-Docker-Compose](Install-Docker-Compose) — recommended for production +- [Environment-Variables](Environment-Variables) — full list of configurable variables +- [Updating](Updating) — how to pull a new image without losing data diff --git a/wiki/Install-Helm.md b/wiki/Install-Helm.md new file mode 100644 index 0000000000000000000000000000000000000000..1a320a0918d715e24aea92fd4722ad89d628f507 --- /dev/null +++ b/wiki/Install-Helm.md @@ -0,0 +1,195 @@ +# Install: Helm + +Deploy TREK on Kubernetes using the official Helm chart. + +## Add the Chart Repository + +```bash +helm repo add trek https://mauriceboe.github.io/TREK +helm repo update +``` + +## Basic Install + +```bash +helm install trek trek/trek +``` + +This deploys TREK with default values: a `ClusterIP` service on port 3000, 1 Gi PVCs for data and uploads, and no ingress. + +## Encryption Key + +`ENCRYPTION_KEY` encrypts stored secrets (API keys, MFA, SMTP, OIDC) at rest. There are three ways to handle it: + +**Option 1 — Let the chart generate a random key (recommended for new installs):** + +```bash +helm install trek trek/trek --set generateEncryptionKey=true +``` + +The chart generates a 32-character alphanumeric key at install time and preserves it across upgrades. Note that this differs from the 64-character hex key produced by `openssl rand -hex 32` — both formats are accepted by the server. + +**Option 2 — Set an explicit key:** + +```bash +helm install trek trek/trek \ + --set secretEnv.ENCRYPTION_KEY=$(openssl rand -hex 32) +``` + +**Option 3 — Use an existing Kubernetes Secret:** + +```bash +kubectl create secret generic trek-secrets \ + --from-literal=ENCRYPTION_KEY=$(openssl rand -hex 32) + +helm install trek trek/trek \ + --set existingSecret=trek-secrets +``` + +If `existingSecret` uses a different key name than `ENCRYPTION_KEY`, specify it with `--set existingSecretKey=MY_KEY_NAME`. + +> **Note:** If both `generateEncryptionKey` and `existingSecret` are set, `existingSecret` takes precedence. Only one method should be active at a time. + +> **Note:** If `ENCRYPTION_KEY` is left empty, the server resolves it automatically: existing installs fall back to `data/.jwt_secret` (encrypted data stays readable after upgrade); fresh installs auto-generate a key persisted to the data PVC. + +> **Note:** `JWT_SECRET` is managed entirely by the server — auto-generated on first start and persisted to the data PVC. It can be rotated via the admin panel (Settings → Danger Zone → Rotate JWT Secret). No Helm configuration is needed or supported for it. + +## Admin Account + +`ADMIN_EMAIL` and `ADMIN_PASSWORD` are set via `secretEnv`. They are only used on first boot when no users exist yet. **Both must be set together** — if either is missing, the server ignores both values and instead creates the admin account with email `admin@trek.local` and a random password, which is printed to the server log. + +```bash +helm install trek trek/trek \ + --set secretEnv.ADMIN_EMAIL=admin@example.com \ + --set secretEnv.ADMIN_PASSWORD= +``` + +> **Note:** When `OIDC_ONLY=true` is configured together with `OIDC_ISSUER` and `OIDC_CLIENT_ID`, no local admin account is created on first boot. Instead, the first user to log in via SSO automatically becomes admin. + +## Key `values.yaml` Settings + +### Image + +```yaml +image: + repository: mauriceboe/trek + # tag: latest # defaults to the chart's appVersion + pullPolicy: IfNotPresent + +# Optional: pull secrets for private registries +imagePullSecrets: [] + # - name: my-registry-secret +``` + +### Service + +```yaml +service: + type: ClusterIP # change to LoadBalancer or NodePort to expose externally + port: 3000 +``` + +### Plain Environment Variables (`env`) + +```yaml +env: + NODE_ENV: production + PORT: 3000 + # TZ: "Europe/Berlin" # timezone for logs, reminders, cron jobs + # LOG_LEVEL: "info" # "info" = concise, "debug" = verbose + # DEFAULT_LANGUAGE: "en" # fallback language on login page; supported: de, en, es, fr, hu, nl, br, cs, pl, ru, zh, zh-TW, it, ar + # ALLOWED_ORIGINS: "https://trek.example.com" + # APP_URL: "https://trek.example.com" + # FORCE_HTTPS: "false" # enable HTTPS redirect + HSTS; requires TRUST_PROXY + # TRUST_PROXY: "1" # proxy hops for X-Forwarded-For/Proto; defaults to 1 in production + # COOKIE_SECURE: "true" # auto-derived; set "false" only for local HTTP testing + # ALLOW_INTERNAL_NETWORK: "false" # set "true" if Immich or other services are on a private network + # DEMO_MODE: "false" # enable demo mode (hourly data resets) + # MCP_RATE_LIMIT: "300" # max MCP requests per user per minute + # OIDC_ISSUER: "https://auth.example.com" + # OIDC_CLIENT_ID: "trek" + # OIDC_DISPLAY_NAME: "SSO" + # OIDC_ONLY: "false" # force SSO-only mode; disables password login + # OIDC_ADMIN_CLAIM: "" # OIDC claim used to identify admin users + # OIDC_ADMIN_VALUE: "" # value of that claim that grants admin role + # OIDC_SCOPE: "openid email profile groups" + # OIDC_DISCOVERY_URL: "" # override for providers with non-standard discovery paths (e.g. Authentik) +``` + +### Sensitive Variables (`secretEnv`) + +These are stored in a Kubernetes Secret and injected as environment variables: + +```yaml +secretEnv: + ENCRYPTION_KEY: "" # recommended: openssl rand -hex 32 + ADMIN_EMAIL: "" # initial admin email (first boot only) + ADMIN_PASSWORD: "" # initial admin password (first boot only) + OIDC_CLIENT_SECRET: "" # set if using OIDC +``` + +Alternatively, use `generateEncryptionKey: true` to let the chart generate and manage the encryption key, or point `existingSecret` / `existingSecretKey` at an existing Kubernetes Secret. + +### Persistent Storage + +```yaml +persistence: + enabled: true + data: + size: 1Gi # SQLite database, logs, secrets + uploads: + size: 1Gi # uploaded files — increase if you expect large media uploads +``` + +### Resource Limits + +```yaml +resources: + requests: + cpu: 100m + memory: 256Mi + limits: + cpu: 500m + memory: 512Mi +``` + +### Ingress + +```yaml +ingress: + enabled: true + className: "nginx" # your ingress class + annotations: + nginx.ingress.kubernetes.io/proxy-read-timeout: "86400" # required for WebSockets + nginx.ingress.kubernetes.io/proxy-body-size: "500m" # required for backup restore + hosts: + - host: trek.example.com + paths: + - / + tls: + - secretName: trek-tls + hosts: + - trek.example.com +``` + +> **Important:** TREK uses WebSockets on `/ws`. Your ingress controller must support WebSocket upgrades. Set `proxy-read-timeout` to at least `86400` and `proxy-body-size` to at least `500m` for backup restores. + +> **Note:** Keep `env.ALLOWED_ORIGINS` in sync with `ingress.hosts` — the chart does not synchronize these automatically. + +> **Note:** When using ingress with TLS termination, set `env.FORCE_HTTPS: "true"` and `env.TRUST_PROXY: "1"` to enable HTTPS redirects, HSTS, and secure cookies. + +## Upgrade + +```bash +helm repo update +helm upgrade trek trek/trek +``` + +## Full Values Reference + +See the [`charts/README.md`](https://github.com/mauriceboe/TREK/blob/main/charts/README.md) for all available values. + +## Next Steps + +- [Environment-Variables](Environment-Variables) — full variable reference +- [Reverse-Proxy](Reverse-Proxy) — proxy configuration for non-Kubernetes deployments diff --git a/wiki/Install-Portainer.md b/wiki/Install-Portainer.md new file mode 100644 index 0000000000000000000000000000000000000000..d9c555e0ca3ec70a0dc07b8d3f0bf20442f29ec1 --- /dev/null +++ b/wiki/Install-Portainer.md @@ -0,0 +1,99 @@ +# Install: Portainer + +Install TREK on Portainer using a Stack (Docker Compose). + +## Prerequisite + +Portainer must be installed and connected to your Docker environment. Use **Stacks** — it supports Docker Compose and gives you the full compose syntax including environment variables, volumes, and restart policies. + +## Create a Stack + +![Stacks page with arrows pointing to the Stacks menu item and the Add stack button](assets/portainer-add-stack.png) + +1. In Portainer, go to **Stacks → Add stack**. +2. Give the stack a name (e.g. `trek`). +3. Select **Web editor** and paste the compose file from [docker-compose.yml](https://github.com/mauriceboe/TREK/blob/main/docker-compose.yml). + +![Web editor with the docker-compose content pasted in](assets/portainer-stack-save.png) + +4. Fill in the environment variables at the bottom of the page. + +![Environment variables section with key/value fields filled in](assets/portainer-environment-variable.png) + +5. Click **Deploy the stack**. + +![Deploy the stack button highlighted](assets/portainer-deploy-stack.png) + +## Compose Content + +See https://github.com/mauriceboe/TREK/blob/main/docker-compose.yml + +Set at minimum `ENCRYPTION_KEY`, `TZ`, and `APP_URL` in the **Environment variables** section of the stack editor. Generate an encryption key with: + +```bash +openssl rand -hex 32 +``` + +## Image Tags + +Three tag strategies are available: + +| Tag | Example | Behavior | +|---|---|---| +| `latest` | `mauriceboe/trek:latest` | Always the newest release across all major versions | +| Major version | `mauriceboe/trek:3` | Latest release pinned to that major version | +| Full version | `mauriceboe/trek:3.0.15` | Exact release; never changes | + +Use `latest` or a major-version tag (e.g. `3`) if you want automatic updates on redeploy. Use a full version tag (e.g. `3.0.15`) if you want explicit control over which release runs. + +## Updating + +How you update depends on the tag you chose: + +**`latest` or major-version tag** — In Portainer, open the stack, click **Redeploy**, enable the **Re-pull image and redeploy** switch, then confirm. Portainer will pull the newest matching image and recreate the container. + +![Re-pull image and redeploy switch ticked, with arrows pointing to the switch and the Update button](assets/portainer-force-pull.png) + +**Pinned full-version tag** — Edit the stack, change the tag in the `image:` line (e.g. `3.0.15` → `3.0.16`), then click **Update the stack**. No need to toggle the re-pull switch — a tag change forces a fresh pull. + +![Edit stack page with an arrow pointing to the image tag in the compose editor](assets/portainer-update-version.png) + +![Edit stack page with an arrow pointing to the Update the stack button](assets/portainer-update-stack.png) + +> Back up your data before any update. Go to **Admin Panel → Backups** or copy your `./data` and `./uploads` directories. See [Backups](Backups). + +## Volumes + +| Stack-relative path | Container path | Contents | +|---|---|---| +| `./data` | `/app/data` | SQLite database, logs, encryption key | +| `./uploads` | `/app/uploads` | Uploaded files (photos, documents, covers, avatars) | + +Portainer resolves `./` relative to the stack's working directory. Confirm the paths under **Stack details** after deploying. + +### Named Volumes + +You can use Docker named volumes instead of bind mounts. Named volumes are fully managed by Docker and not tied to a host path — a good fit for Portainer where the working directory can vary. See the [Docker Compose volumes reference](https://docs.docker.com/reference/compose-file/volumes/) for all options. + +Replace the `volumes:` block in the service and add a top-level declaration: + +```yaml +services: + app: + # ... (rest of service config unchanged) + volumes: + - trek_data:/app/data + - trek_uploads:/app/uploads + +volumes: + trek_data: + trek_uploads: +``` + +Portainer lists named volumes under **Volumes** in the sidebar, where you can inspect or back them up. + +## Next Steps + +- [Environment-Variables](Environment-Variables) — full variable reference +- [Reverse-Proxy](Reverse-Proxy) — HTTPS configuration +- [Updating](Updating) — update strategies across all install methods diff --git a/wiki/Install-Proxmox.md b/wiki/Install-Proxmox.md new file mode 100644 index 0000000000000000000000000000000000000000..158472cccc286312d8316434c2c299feb3d090e7 --- /dev/null +++ b/wiki/Install-Proxmox.md @@ -0,0 +1,110 @@ +# Install: Proxmox VE (LXC) + +Install TREK on Proxmox VE as an LXC container using the [Proxmox VE Community Scripts](https://community-scripts.org/scripts/trek). + +> A big thank you to the members of [community-scripts](https://github.com/community-scripts) for adding TREK to their collection and maintaining the install and update scripts. + +## Prerequisites + +- Proxmox VE with shell access +- Internet access from the Proxmox host + +## Install + +Run the following command in the **Proxmox VE Shell**: + +```bash +bash -c "$(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/ct/trek.sh)" +``` + +> **Tip:** Always verify the latest command on the [community-scripts TREK page](https://community-scripts.org/scripts/trek) before running — the script URL may change between releases. + +The script will prompt you to choose between **Default** and **Advanced** settings. + +### Default container specs + +| Resource | Value | +|---|---| +| OS | Debian 13 | +| CPU | 2 cores | +| RAM | 2048 MB | +| Storage | 8 GB | +| Port | 3000 | + +The container is unprivileged. TREK is installed at `/opt/trek`. + +## After Install + +Once the container starts, open your browser at: + +``` +http://:3000 +``` + +On first boot, TREK automatically creates an admin account. The credentials are printed to the container log — check them with: + +```bash +journalctl -u trek -n 50 +``` + +The `ENCRYPTION_KEY` is auto-generated during setup and saved to `/opt/trek/server/.env`. Record that file in your backups. + +## Viewing Logs + +TREK runs as a systemd service named `trek` inside the LXC. To view logs from within the container: + +```bash +# Follow live logs +journalctl -u trek -f + +# Show last 100 lines +journalctl -u trek -n 100 + +# Show logs since last boot +journalctl -u trek -b +``` + +To access the container shell from the Proxmox VE host, click the container in the UI and open **Console**, or run: + +```bash +pct enter +``` + +## Configuration + +The environment file is located at `/opt/trek/server/.env` inside the container. Edit it to set variables like `ALLOWED_ORIGINS`, `APP_URL`, or `TZ`, then restart the service: + +```bash +systemctl restart trek +``` + +### Binding to a specific network interface + +If your Proxmox host has multiple network interfaces and you want TREK to listen on only one of them, set the `HOST` variable in `/opt/trek/server/.env`: + +``` +HOST=10.0.0.72 # bind only on this LAN interface +PORT=3001 +``` + +> **Note:** `HOST` is only relevant for source-based and Proxmox installs. Do not use it in Docker or any containerised deployment. + +See [Environment-Variables](Environment-Variables) for the full variable reference. + +## Updating + +Run the following command inside the **LXC container** and select **Update** when prompted: + +```bash +bash -c "$(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/ct/trek.sh)" +``` + +> **Tip:** Always check the [community-scripts TREK page](https://community-scripts.org/scripts/trek) to confirm the latest command before running. + +The script stops the service, backs up your data and uploads, applies the new release, restores the backup, and restarts. No manual steps required. + +## Next Steps + +- [Environment-Variables](Environment-Variables) — complete variable reference +- [Reverse-Proxy](Reverse-Proxy) — put TREK behind Nginx or Caddy +- [Updating](Updating) — general update notes diff --git a/wiki/Install-Unraid.md b/wiki/Install-Unraid.md new file mode 100644 index 0000000000000000000000000000000000000000..8f142ec19733a4faa100273db0ba2a9e85bdce8e --- /dev/null +++ b/wiki/Install-Unraid.md @@ -0,0 +1,73 @@ +# Install: Unraid + +Install TREK on Unraid via Community Applications or a direct template import. + + + +## Prerequisite + +Docker must be enabled in Unraid (**Settings → Docker → Enable Docker: Yes**). + +## Install via Community Applications + +1. Open the **Apps** tab in Unraid. +2. Search for **TREK**. +3. Click **Install** on the TREK result. + +If the app does not appear, you can install directly from the template URL. In **Docker → Add Container**, paste the template URL: + +``` +https://raw.githubusercontent.com/mauriceboe/TREK/main/unraid-template.xml +``` + +## Template Fields + +The Unraid template exposes the following fields in the container UI: + +### Ports & Paths + +| Field | Container path | Default host value | +|---|---|---| +| Web UI Port | `3000/tcp` | `3000` | +| Data | `/app/data` | `/mnt/user/appdata/trek/data` | +| Uploads | `/app/uploads` | `/mnt/user/appdata/trek/uploads` | + +### Core Variables (always visible) + +| Variable | Default | Notes | +|---|---|---| +| `ENCRYPTION_KEY` | *(empty)* | Set on first install. Generate with `openssl rand -hex 32` in the Unraid terminal. | +| `TZ` | `UTC` | Timezone for logs, reminders, and scheduled tasks (e.g. `Europe/Berlin`) | +| `ALLOWED_ORIGINS` | *(empty)* | Comma-separated origins for CORS and email notification links, e.g. `https://trek.example.com` | +| `APP_URL` | *(empty)* | Public base URL; required when OIDC is enabled (must match the redirect URI registered with your IdP) | +| `ADMIN_EMAIL` | *(empty)* | Email for the first admin account (first-boot only; no effect once any user exists). Must be set together with `ADMIN_PASSWORD`. | +| `ADMIN_PASSWORD` | *(empty)* | Password for the first admin account (first-boot only). Must be set together with `ADMIN_EMAIL`. If either is omitted, TREK creates the account with email `admin@trek.local` and a random password printed to the container log. | + +### Advanced Variables + +Additional variables (`PORT`, `NODE_ENV`, `LOG_LEVEL`, `DEFAULT_LANGUAGE`, `FORCE_HTTPS`, `TRUST_PROXY`, `COOKIE_SECURE`, `ALLOW_INTERNAL_NETWORK`, `SESSION_DURATION`, `SESSION_DURATION_REMEMBER`, all OIDC variables, `MCP_RATE_LIMIT`, `MCP_MAX_SESSION_PER_USER`, `DEMO_MODE`) are available under **Advanced View** in the template editor. + +## Setting the Encryption Key + +Generate a key in the Unraid terminal (**Tools → Terminal**): + +```bash +openssl rand -hex 32 +``` + +Copy the output into the `ENCRYPTION_KEY` field before starting the container for the first time. If you skip this, TREK auto-generates a key and saves it to `data/.encryption_key` — your data is still protected, but you should record that file in your backups. + +## After Install + +Once the container starts, open your browser at: + +``` +http://: +``` + +On first boot, TREK automatically creates an admin account. The credentials are printed to the container log — check **Docker → trek → Log** in the Unraid UI. If you set both `ADMIN_EMAIL` and `ADMIN_PASSWORD`, those values are used; otherwise the email is `admin@trek.local` and a random password is generated. + +## Next Steps + +- [Environment-Variables](Environment-Variables) — complete variable reference +- [Updating](Updating) — how to pull a new image on Unraid diff --git a/wiki/Internal-Network-Access.md b/wiki/Internal-Network-Access.md new file mode 100644 index 0000000000000000000000000000000000000000..981ae63d4a067642af7d0bbecf06522612db880a --- /dev/null +++ b/wiki/Internal-Network-Access.md @@ -0,0 +1,57 @@ +# Internal Network Access + +TREK makes outbound HTTP requests when you configure integrations such as Immich or Synology Photos. By default, it blocks requests to private and local IP ranges to prevent server-side request forgery (SSRF) attacks. You need to allow internal network access when those services are hosted on your LAN. + +## Default behavior + +All outbound requests go through an SSRF guard (`ssrfGuard.ts`). The guard resolves the hostname to an IP address before allowing the connection and blocks addresses in private ranges. + +## Always blocked (no override possible) + +These ranges are blocked regardless of any setting: + +| Range | Description | +|---|---| +| `127.0.0.0/8`, `::1` | Loopback | +| `0.0.0.0/8` | Unspecified | +| `169.254.0.0/16`, `fe80::/10` | Link-local / cloud metadata endpoints | +| `::ffff:127.x.x.x`, `::ffff:169.254.x.x` | IPv4-mapped loopback and link-local | + +## Blocked unless `ALLOW_INTERNAL_NETWORK=true` + +| Range / Hostname | Description | +|---|---| +| `10.0.0.0/8` | RFC-1918 private | +| `172.16.0.0/12` | RFC-1918 private | +| `192.168.0.0/16` | RFC-1918 private | +| `100.64.0.0/10` | CGNAT / Tailscale shared address space | +| `fc00::/7` | IPv6 ULA | +| IPv4-mapped RFC-1918 variants | e.g. `::ffff:10.x`, `::ffff:192.168.x` | +| `*.local`, `*.internal` hostnames | mDNS / internal DNS suffixes (e.g. Docker service names, LAN hosts) | + +The hostname `localhost` is not blocked at the hostname stage, but it resolves to `127.0.0.1` which is caught by the loopback rule above and is therefore always blocked. + +`*.local` and `*.internal` hostnames are permitted when `ALLOW_INTERNAL_NETWORK=true` — the guard still resolves them to an IP and enforces all IP-level rules, so any such hostname that resolves to a loopback or link-local address remains blocked regardless. + +## When to enable + +Set `ALLOW_INTERNAL_NETWORK=true` when Immich, Synology Photos, or another integrated service is hosted on your local network and you need TREK to reach it. + +See [Environment-Variables](Environment-Variables) for how to set environment variables. + +> **Admin:** Set `ALLOW_INTERNAL_NETWORK=true` in [Environment-Variables](Environment-Variables) before configuring Immich or Synology on a LAN. + +## DNS rebinding protection + +Even with `ALLOW_INTERNAL_NETWORK=true`, TREK pins the DNS resolution to prevent rebinding attacks. When the guard checks a URL, it resolves the hostname once and records the IP. The outbound connection is then made directly to that IP using a pinned dispatcher (via undici), so the hostname cannot re-resolve to a different address between the check and the actual request. + +## Audit log + +When a user saves an Immich URL that resolves to a private IP, TREK records an `immich.private_ip_configured` entry in the [Audit-Log](Audit-Log) including the URL and the resolved IP address. This audit event is specific to Immich; Synology Photos does not emit an equivalent event. + +## See also + +- [Photo-Providers](Photo-Providers) +- [User-Settings](User-Settings) +- [Environment-Variables](Environment-Variables) +- [Security-Hardening](Security-Hardening) diff --git a/wiki/Invite-Links.md b/wiki/Invite-Links.md new file mode 100644 index 0000000000000000000000000000000000000000..52d6224f53616b7b9fe40c9fb7db67477cec154d --- /dev/null +++ b/wiki/Invite-Links.md @@ -0,0 +1,35 @@ +# Invite Links + +Invite new users to register on your TREK instance, even when open registration is disabled. Invite links work by embedding a short-lived token in the registration URL. + + + +![Invite Links](assets/UsersAndInvites.png) + +## What invite links do + +An invite link lets a person register a new TREK account without requiring the site to have open registration enabled. Visiting `/register?invite=` pre-validates the token and switches the page to the Register form. The token's use count is incremented on successful registration, and the link stops working once the use limit is reached. + +## Creating invite links + +> **Admin:** invite link management is available in [Admin-Users-and-Invites](Admin-Users-and-Invites). Only admins can create invite links. + +When creating an invite link you set two parameters: + +**Max uses** — how many times the link can be used to register an account. Choose from preset buttons: **1×, 2×, 3×, 4×, 5×**, or **∞** (unlimited). + +**Expiry** — how long until the link stops working. Choose from preset buttons: **1d, 3d, 7d, 14d**, or **∞** (no expiry). + +Once created, a 32-character hexadecimal token is generated and the URL is automatically copied to your clipboard. + +## Sharing the link + +Copy the generated URL and send it directly to the person you want to invite. The link works in any browser without any prior authentication. + +## Revoking an invite link + +Delete the invite from [Admin-Users-and-Invites](Admin-Users-and-Invites). The token is invalidated immediately and visiting the URL will no longer unlock the Register form. + +## Related pages + +[Login-and-Registration](Login-and-Registration) · [Admin-Users-and-Invites](Admin-Users-and-Invites) diff --git a/wiki/Journey-Journal.md b/wiki/Journey-Journal.md new file mode 100644 index 0000000000000000000000000000000000000000..ceea0ca7ab14d4b3ead8d66009edd7c57d8d3e0f --- /dev/null +++ b/wiki/Journey-Journal.md @@ -0,0 +1,62 @@ +# Journey Journal + +Journey is a photo-first travel journal. Each journey is linked to one or more of your trips and contains per-day entries with text, photos, mood, and weather. + +> **Admin:** enable Journey in [Admin-Addons](Admin-Addons). + + + +![Journey screenshot](assets/Journey.png) + +## What Journey is + +Journey lets you write a narrative account of your travels alongside your trip plan. Entries are tied to specific days and can include prose, photos, a mood rating, weather conditions, and verdict cards. Completed journeys can be shared publicly with a read-only link. + +## Accessing Journey + +When the admin has enabled the Journey addon, a **Journey** entry appears in the main navigation. The Journey list page shows all your journals as cards with cover images, entry counts, photo counts, and place counts. + +## Creating a journey + +From the Journey list, click **Create journey**. Give it a title and optional subtitle, then select one or more existing trips to link. Linking a trip imports the trip's places as location anchors for your entries. You can link additional trips later from the journal settings. + +## Journal entries + +Each entry corresponds to a day in your journey. The entry editor provides: + +- **Title** — a short heading for the day. +- **Story** — free-form text that supports Markdown formatting. +- **Mood** — choose one of four values: + + | ID | Label | Color | + |---|---|---| + | `amazing` | Amazing | Pink | + | `good` | Good | Amber | + | `neutral` | Neutral | Grey | + | `rough` | Rough | Violet | + +- **Weather** — choose one of six values: Sunny, Partly cloudy, Cloudy, Rainy, Stormy, Cold. +- **Photos** — attach photos to the entry. The first photo becomes the card thumbnail in list views. + > **Note on HEIC files:** HEIC is an Apple-only format that many browsers and platforms do not recognise as an image. To ensure broad compatibility, HEIC/HEIF files are automatically converted to JPEG before upload. This conversion may result in the loss of embedded metadata (EXIF data such as GPS coordinates, camera information, etc.). +- **Pros / Cons** — optional verdict cards. Add items to a **Pros** list (thumbs-up) or a **Cons** list (thumbs-down) to summarise what you loved or what could have been better. These are stored in the `pros_cons.pros` and `pros_cons.cons` arrays on the entry. +- **Tags** — free-form labels (e.g. "hidden gem", "best meal"). +- **Location** — pin the entry to a map location. +- **Time** — optionally record a time of day for the entry. + +## Mobile timeline + +On mobile, entries are displayed in a horizontal scrolling timeline of card thumbnails. Tap a card to open the full entry view in a modal sheet. Each card shows the entry's first photo (or a placeholder pin), date, day number, mood icon, and weather icon. + +## Map view + +The journey detail page includes a map on the right (desktop) or an integrated map-timeline (mobile) showing all entry locations alongside the places from linked trips. + +## Public sharing + +You can share a journey with a read-only public link. When creating the link you can independently toggle which sections are visible to visitors: **Timeline** (entries and stories), **Gallery** (photos), and **Map**. Visitors can only see the sections you have enabled, and no TREK account is required. See [Public-Share-Links](Public-Share-Links) for details on the separate journey share token mechanism. + +## See also + +- [Addons-Overview](Addons-Overview) +- [Admin-Addons](Admin-Addons) +- [Public-Share-Links](Public-Share-Links) diff --git a/wiki/Languages.md b/wiki/Languages.md new file mode 100644 index 0000000000000000000000000000000000000000..418185eb322c51934aa3a6db9c7d3c668bdc527e --- /dev/null +++ b/wiki/Languages.md @@ -0,0 +1,51 @@ +# Languages + +TREK ships with translations for 15 languages. You can change your language at any time without logging out. + +## Supported languages + +| Code | Language | +|------|----------| +| `de` | Deutsch | +| `en` | English | +| `es` | Español | +| `fr` | Français | +| `hu` | Magyar | +| `nl` | Nederlands | +| `br` | Português (Brasil) | +| `cs` | Česky | +| `pl` | Polski | +| `ru` | Русский | +| `zh` | 简体中文 | +| `zh-TW` | 繁體中文 | +| `it` | Italiano | +| `ar` | العربية | +| `id` | Bahasa Indonesia | + +## RTL support + +Arabic (`ar`) uses a right-to-left layout. All other languages use left-to-right. + +## How language is detected + +TREK resolves the display language in this order: + +1. **User preference** — the language saved to your account (set in Settings → Display). +2. **Browser language** — `navigator.languages` (and `navigator.language`) reported by your browser. +3. **Server default** — the `DEFAULT_LANGUAGE` environment variable set by the admin. +4. **Fallback** — English (`en`). + +## Where the language picker appears + +- **Login / Register page** — before you are signed in. +- **Settings → Display** — after you are signed in. See [Display-Settings](Display-Settings). +- **Public share pages** — trip share links. +- **Public journey pages** — public-facing journey views. + +> **Admin:** The `DEFAULT_LANGUAGE` environment variable sets the fallback language shown on the login page and for unauthenticated users. See [Environment-Variables](Environment-Variables). + +## See also + +- [Display-Settings](Display-Settings) +- [Environment-Variables](Environment-Variables) +- [User-Settings](User-Settings) diff --git a/wiki/Login-and-Registration.md b/wiki/Login-and-Registration.md new file mode 100644 index 0000000000000000000000000000000000000000..253a4037c4c9227a4c983f52911436da0e4e8226 --- /dev/null +++ b/wiki/Login-and-Registration.md @@ -0,0 +1,77 @@ +# Login and Registration + + + +## Signing in + +Navigate to `/login` and enter your email and password. On success, the server sets a `trek_session` cookie — httpOnly, sameSite=`lax`, and secure in production — that persists your session for 24 hours across page reloads and browser restarts. You do not need to sign in again until the session expires or you explicitly log out. + +> **Note:** The `secure` flag on the cookie can be overridden by setting `COOKIE_SECURE=false` in the server environment (useful for plain-HTTP dev setups), or force-enabled with `FORCE_HTTPS=true`. + +If your account has two-factor authentication enabled, you are prompted for a TOTP code (or backup code) after the password step before the session cookie is issued. + +If you have forgotten your password, click the **"Forgot password?"** link below the password field to start the self-service reset flow. See [Password-Reset](Password-Reset) for details. + +### Forced password change + +If an admin has marked your account as requiring a password change, a **Set new password** form is shown immediately after a successful login (or after the MFA step). The session cookie is not issued until the new password is saved. + +## Registering + +The Register form appears under one of these conditions: + +- **Open registration** — the admin has enabled password registration for the instance (`password_registration` setting). +- **Valid invite link** — you visited `/login?invite=TOKEN` with a valid token (see below). +- **First user** — no accounts exist yet; the registration form is shown automatically and the first account created becomes an admin. + +Registration fields: **username**, **email**, and **password**. + +### Password requirements + +Passwords must meet all of the following rules: + +- Minimum **8 characters** +- At least one **uppercase letter** +- At least one **lowercase letter** +- At least one **number** +- At least one **special character** +- Must not be a commonly used password +- Must not consist of a single repeated character + +> **Admin:** You can disable open registration so only invite links work. See [Admin-Users-and-Invites](Admin-Users-and-Invites). + +### Invite link flow + +When an admin shares an invite link (`/login?invite=TOKEN`), visiting it: + +1. Validates the token against the server. +2. Switches the login page to Register mode automatically. +3. Passes the token during registration so it counts against the invite's use limit. + +If the token is invalid, expired, or exhausted, an error is shown. + +## First user + +On a fresh TREK instance with no existing accounts, the registration form opens immediately. The first account created is automatically assigned the **admin** role. + +## Rate limiting + +Failed login attempts are rate-limited to **10 attempts per 15-minute window** per IP address. After exceeding the limit, further attempts return HTTP 429 until the window resets. + +MFA verification attempts are rate-limited separately to **5 attempts per 15-minute window** per IP address. + +Forgot-password requests are rate-limited to **3 attempts per 15-minute window** per IP. Reset-password submissions are limited to **5 attempts per 15-minute window** per IP. + +## Demo mode + +When the server is started with `DEMO_MODE=true`, a **"Try demo"** button appears below the login form. Clicking it signs you in as the demo user without entering credentials. The demo credentials (`demo@trek.app` / `demo12345`) are also displayed in the app config for reference, but the one-click button is the intended entry point. + +## SSO + +If the admin has configured OpenID Connect, a **"Sign in with SSO"** button (labelled with the configured `OIDC_DISPLAY_NAME`, defaulting to `SSO`) appears below the login form. See [OIDC-SSO](OIDC-SSO) for details on setup and the sign-in flow. + +When OIDC-only mode is active (password login disabled), visiting `/login` automatically redirects the browser to the identity provider. The email/password form is not shown. The automatic redirect is suppressed only when you have explicitly logged out, in which case the SSO button is shown instead so you can choose to sign back in. + +--- + +**See also:** [OIDC-SSO](OIDC-SSO) · [Admin-Users-and-Invites](Admin-Users-and-Invites) · [Password-Reset](Password-Reset) diff --git a/wiki/MCP-Addon-Tools.md b/wiki/MCP-Addon-Tools.md new file mode 100644 index 0000000000000000000000000000000000000000..daca36af6e6c55a85ffda8a29caffbb0002a6719 --- /dev/null +++ b/wiki/MCP-Addon-Tools.md @@ -0,0 +1,176 @@ +# MCP Addon Tools and Resources + +This page covers MCP tools and resources that require specific addons to be enabled on your TREK instance. For core tools (trips, places, day planning, accommodations, transport, reservations, budget, tags, maps, and notifications) see [MCP-Tools-and-Resources](MCP-Tools-and-Resources). + +--- + +## Addon-gated tools + +### Packing _(Packing addon required)_ + +Requires `packing:read` or `packing:write` scope. + +| Tool | Description | +|---|---| +| `create_packing_item` | Add an item to the packing checklist with optional category. | +| `update_packing_item` | Rename an item or change its category. | +| `toggle_packing_item` | Check or uncheck a packing item. | +| `delete_packing_item` | Remove a packing item. | +| `reorder_packing_items` | Set the display order of packing items within a trip. | +| `bulk_import_packing` | Import multiple packing items at once from a list (with optional quantity). | +| `apply_packing_template` | Apply a saved packing template to a trip. | +| `save_packing_template` | Save the current packing list as a reusable template. | +| `list_packing_bags` | List all packing bags for a trip. | +| `create_packing_bag` | Create a new packing bag (e.g. "Carry-on", "Checked bag"). | +| `update_packing_bag` | Rename or recolor a packing bag. | +| `delete_packing_bag` | Delete a packing bag (items are unassigned, not deleted). | +| `set_bag_members` | Assign trip members to a packing bag. | +| `get_packing_category_assignees` | Get which trip members are assigned to each packing category. | +| `set_packing_category_assignees` | Assign trip members to a packing category. | + +### To-Dos _(Packing addon required)_ + +Requires `todos:read` or `todos:write` scope. + +| Tool | Description | +|---|---| +| `list_todos` | List all to-do items for a trip, ordered by position. | +| `create_todo` | Create a to-do item with name, category, due date, description, assignee, and priority. | +| `update_todo` | Update an existing to-do item. Pass `null` to clear nullable fields. | +| `toggle_todo` | Mark a to-do item as done or undone. | +| `delete_todo` | Delete a to-do item. | +| `reorder_todos` | Reorder to-do items by providing a new ordered list of IDs. | +| `get_todo_category_assignees` | Get the default assignees configured per to-do category for a trip. | +| `set_todo_category_assignees` | Set default assignees for a to-do category. Pass an empty array to clear. | + +### Atlas _(Atlas addon required)_ + +Requires `atlas:read` or `atlas:write` scope. + +| Tool | Description | +|---|---| +| `mark_country_visited` | Mark a country as visited using its ISO 3166-1 alpha-2 code (e.g. `"FR"`, `"JP"`). | +| `unmark_country_visited` | Remove a country from your visited list. | +| `get_atlas_stats` | Get atlas statistics — visited country counts, region counts, and continent breakdown. | +| `list_visited_regions` | List all manually visited sub-country regions for the current user. | +| `mark_region_visited` | Mark a sub-country region as visited (e.g. `"US-CA"`). | +| `unmark_region_visited` | Remove a region from the visited list. | +| `get_country_atlas_places` | Get places saved in the user's atlas for a specific country. | +| `create_bucket_list_item` | Add a destination to your personal bucket list with optional coordinates and country code. | +| `update_bucket_list_item` | Update a bucket list item (name, notes, coordinates, target date). | +| `delete_bucket_list_item` | Remove an item from your bucket list. | + +### Collab _(Collab addon required)_ + +Requires `collab:read` or `collab:write` scope. + +| Tool | Description | +|---|---| +| `create_collab_note` | Create a shared note visible to all trip members. Supports title, content, category, and color. | +| `update_collab_note` | Edit a collab note's content, category, color, or pin status. | +| `delete_collab_note` | Delete a collab note. | +| `list_collab_polls` | List all polls for a trip. | +| `create_collab_poll` | Create a poll with a question, options, optional multiple choice, and deadline. | +| `vote_collab_poll` | Vote on a poll option (or remove vote if already voted). | +| `close_collab_poll` | Close a poll so no more votes can be cast. | +| `delete_collab_poll` | Delete a poll and all its votes. | +| `list_collab_messages` | List chat messages for a trip (most recent 100, supports pagination via `before`). | +| `send_collab_message` | Send a chat message to a trip's collab channel, with optional reply threading. | +| `delete_collab_message` | Delete a chat message (own messages only). | +| `react_collab_message` | Toggle a reaction emoji on a chat message. | + +### Vacay _(Vacay addon required)_ + +Requires `vacay:read` or `vacay:write` scope. + +| Tool | Description | +|---|---| +| `get_vacay_plan` | Get the current user's active vacation plan. | +| `update_vacay_plan` | Update vacation plan settings (weekend blocking, holidays, carry-over). | +| `set_vacay_color` | Set the current user's color in the vacation plan calendar. | +| `get_available_vacay_users` | List users who can be invited to the current vacation plan. | +| `send_vacay_invite` | Invite a user to join the vacation plan by their user ID. | +| `accept_vacay_invite` | Accept a pending invitation to join another user's vacation plan. | +| `decline_vacay_invite` | Decline a pending vacation plan invitation. | +| `cancel_vacay_invite` | Cancel an outgoing invitation (owner only). | +| `dissolve_vacay_plan` | Dissolve the shared plan — all members return to their own individual plan. | +| `list_vacay_years` | List calendar years tracked in the current vacation plan. | +| `add_vacay_year` | Add a calendar year to the vacation plan. | +| `delete_vacay_year` | Remove a calendar year from the vacation plan. | +| `get_vacay_entries` | Get all vacation day entries for the active plan and a specific year. | +| `toggle_vacay_entry` | Toggle a day on or off as a vacation day for the current user. | +| `toggle_company_holiday` | Toggle a date as a company holiday for the whole plan. | +| `get_vacay_stats` | Get vacation statistics for a specific year (days used, remaining, carried over). | +| `update_vacay_stats` | Update the vacation day allowance for a specific user and year. | +| `add_holiday_calendar` | Add a public holiday calendar (by region code) to the vacation plan. | +| `update_holiday_calendar` | Update label or color for a holiday calendar. | +| `delete_holiday_calendar` | Remove a holiday calendar from the vacation plan. | +| `list_holiday_countries` | List countries available for public holiday calendars. | +| `list_holidays` | List public holidays for a country and year. | + +### Journey _(Journey addon required)_ + +Requires `journey:read` or `journey:write` scope. + +| Tool | Description | +|---|---| +| `list_journeys` | List all journeys owned or contributed to by the current user. | +| `get_journey` | Get a full snapshot of a journey — metadata, entries, contributors, and linked trips. | +| `create_journey` | Create a new journey with title, optional subtitle, and an initial list of trip IDs. | +| `update_journey` | Update a journey's title, subtitle, or status. | +| `delete_journey` | Delete a journey. | +| `add_journey_trip` | Link an existing trip to a journey. | +| `remove_journey_trip` | Remove a trip from a journey. | +| `list_journey_entries` | List all entries in a journey (date, text, mood, linked trip). | +| `create_journey_entry` | Add an entry with date (required), optional title, story text, time of day, location name, mood, and sort order. | +| `update_journey_entry` | Edit a journey entry's title, story, date, time of day, or mood. | +| `delete_journey_entry` | Remove an entry from a journey. | +| `reorder_journey_entries` | Reorder entries by providing the new ordered list of entry IDs. | +| `list_journey_contributors` | List the contributors of a journey (owner and editors/viewers). | +| `add_journey_contributor` | Invite a user to a journey with `editor` or `viewer` role. | +| `update_journey_contributor_role` | Change a contributor's role between `editor` and `viewer`. | +| `remove_journey_contributor` | Remove a contributor from a journey. | +| `update_journey_preferences` | Update display preferences for a journey. | +| `get_journey_suggestions` | Get suggested trips to add to journeys based on recent trip history. | +| `list_journey_available_trips` | List all trips available to the current user for linking to a journey. | +| `get_journey_share_link` | Get the current public share link for a journey. Requires `journey:share`. | +| `create_journey_share_link` | Create or update the public share link for a journey. Requires `journey:share`. | +| `delete_journey_share_link` | Revoke the public share link for a journey. Requires `journey:share`. | + +--- + +## Addon-gated resources + +Resources provide read-only access via `trek://` URIs. The following resources require their addon to be enabled. + +| URI | Addon | Scope required | Description | +|---|---|---|---| +| `trek://trips/{tripId}/budget` | Budget | `budget:read` | Budget and expense items | +| `trek://trips/{tripId}/budget/per-person` | Budget | `budget:read` | Per-person totals and split breakdown | +| `trek://trips/{tripId}/budget/settlement` | Budget | `budget:read` | Suggested transactions to settle who owes whom | +| `trek://trips/{tripId}/packing` | Packing | `packing:read` | Packing checklist | +| `trek://trips/{tripId}/packing/bags` | Packing | `packing:read` | Packing bags with their assigned members | +| `trek://trips/{tripId}/todos` | Packing | `todos:read` | To-do items ordered by position | +| `trek://trips/{tripId}/collab-notes` | Collab | `collab:read` | Shared collaborative notes | +| `trek://bucket-list` | Atlas | `atlas:read` | Your personal travel bucket list | +| `trek://visited-countries` | Atlas | `atlas:read` | Countries marked as visited in Atlas | +| `trek://atlas/stats` | Atlas | `atlas:read` | Visited country counts and continent breakdown | +| `trek://atlas/regions` | Atlas | `atlas:read` | Manually visited sub-country regions | +| `trek://trips/{tripId}/collab/polls` | Collab | `collab:read` | All polls for a trip with vote counts per option | +| `trek://trips/{tripId}/collab/messages` | Collab | `collab:read` | Most recent 100 chat messages for a trip | +| `trek://vacay/plan` | Vacay | `vacay:read` | Full snapshot of your active vacation plan (members, years, config) | +| `trek://vacay/entries/{year}` | Vacay | `vacay:read` | All vacation day entries for the active plan and a specific year | +| `trek://vacay/holidays/{year}` | Vacay | `vacay:read` | Public holidays for the plan's configured region and year | +| `trek://journeys` | Journey | `journey:read` | All journeys owned or contributed to by the current user | +| `trek://journeys/{journeyId}` | Journey | `journey:read` | Single journey with entries, contributors, and linked trips | +| `trek://journeys/{journeyId}/entries` | Journey | `journey:read` | All entries in a journey (date, text, mood, linked trip) | +| `trek://journeys/{journeyId}/contributors` | Journey | `journey:read` | Contributors (owner and collaborators) of a journey | + +--- + +## Related + +- [MCP-Tools-and-Resources](MCP-Tools-and-Resources) +- [MCP-Scopes](MCP-Scopes) +- [MCP-Prompts](MCP-Prompts) +- [MCP-Setup](MCP-Setup) diff --git a/wiki/MCP-Overview.md b/wiki/MCP-Overview.md new file mode 100644 index 0000000000000000000000000000000000000000..7992245267fec7a87ddd102bbc32fd2101474c73 --- /dev/null +++ b/wiki/MCP-Overview.md @@ -0,0 +1,59 @@ +# MCP Overview + +TREK includes a built-in [Model Context Protocol](https://modelcontextprotocol.io/) (MCP) server. MCP is an open standard that lets AI assistants read and modify data in external services through a structured API. When the MCP addon is enabled on your TREK instance, AI clients such as Claude.ai, Claude Desktop, Cursor, VS Code, and others can connect directly to your trips. + +## What you can do + +Once connected, an AI assistant can work with your TREK data in a single conversation: + +- Create and update trips, days, and itineraries +- Search for real-world places and add them to your trip +- Build and manage packing lists and to-do items +- Track budgets and expenses across trip members +- Create reservations, transport bookings, and accommodations +- Send collab messages and notes to other trip members +- Mark countries and regions as visited in Atlas +- Log vacation days in Vacay +- Write journey entries across multiple trips + +Changes made through MCP are broadcast to all connected clients in real-time — exactly like changes made in the web UI. + +## Authentication options + +| Use case | Method | +|---|---| +| Interactive client (Claude.ai, Cursor, VS Code…) | OAuth 2.1 with browser consent — TREK issues tokens after you approve scopes in a consent screen | +| AI agent or script running unattended | Machine client (client_credentials) — token obtained directly via `client_id` + `client_secret`, no browser ever opened | +| Legacy setups | Static API token — deprecated, full access, no scopes | + +See [MCP-Setup](MCP-Setup) for step-by-step instructions for each method. + +## Requirements + +- **MCP addon enabled** — an administrator must enable the MCP addon (`mcp`) from the Admin Panel before the `/mcp` endpoint becomes available and the MCP section appears in user settings. +- **`APP_URL` set** — the `APP_URL` environment variable must be configured to your TREK instance's public URL so that OAuth discovery works correctly. Without it, clients that use OAuth 2.1 cannot complete authentication. + +## Rate limits and session limits + +| Setting | Default | Environment variable | +|---|---|---| +| Requests per minute per user | 300 | `MCP_RATE_LIMIT` | +| Max concurrent sessions per user | 20 | `MCP_MAX_SESSION_PER_USER` | + +Rate limits are tracked per user–client pair, so each OAuth client has its own independent window. Sessions expire after 1 hour of inactivity. + +## Endpoint + +``` +https:///mcp +``` + +If the MCP addon is not enabled, this endpoint returns `403`. If authentication fails, it returns `401`. + +> **Admin:** Enable the MCP addon in [Admin-Addons](Admin-Addons). Set `APP_URL` for OAuth discovery. Revoke tokens and manage OAuth clients from [Admin-MCP-Tokens](Admin-MCP-Tokens). Adjust rate and session limits with `MCP_RATE_LIMIT` and `MCP_MAX_SESSION_PER_USER` — see [Environment-Variables](Environment-Variables). + +## Next steps + +1. [MCP-Setup](MCP-Setup) — connect your AI client +2. [MCP-Scopes](MCP-Scopes) — choose the right permissions +3. [MCP-Tools-and-Resources](MCP-Tools-and-Resources) — browse available tools diff --git a/wiki/MCP-Prompts.md b/wiki/MCP-Prompts.md new file mode 100644 index 0000000000000000000000000000000000000000..ea0ed84646148ce01771bfc61148226cea5d33ef --- /dev/null +++ b/wiki/MCP-Prompts.md @@ -0,0 +1,27 @@ +# MCP Prompts + +TREK includes built-in MCP prompts — pre-built context loaders that tell your AI client how to summarize or present your trip data in a structured way. Prompts are a standard MCP feature: compatible clients can invoke them by name to get a ready-made starting point for common tasks. + +## Built-in prompts + +| Prompt | Addon required | Description | +|---|---|---| +| `trip-summary` | — | Loads a formatted summary of a trip: dates, member list, day count, number of places per day, packing progress, budget total, reservation count, and collab note count. Use this before asking the AI to plan or modify a trip. | +| `packing-list` | Packing | Returns the full packing checklist for a trip, grouped by category, with each item marked checked or unchecked. | +| `budget-overview` | Budget | Returns a budget summary for a trip — total spend, breakdown by category (sorted descending), and a per-person cost estimate. | +| `token_auth_notice` | — | Deprecation notice for sessions authenticated with a static `trek_` token. Only available in static-token sessions. Explains that the token will stop working in a future version and how to migrate to OAuth 2.1. | + +`packing-list` and `budget-overview` are only registered when the corresponding addon is enabled on your TREK instance. + +`token_auth_notice` is only registered when the current session was authenticated with a legacy static API token — it does not appear in OAuth sessions. + +## How to use prompts + +In a compatible MCP client (such as Claude.ai or Claude Desktop), prompts typically appear as slash commands or in a prompts panel. You select the prompt, supply any required arguments (such as a `tripId`), and the client sends the formatted context to the AI before your next message. + +For example, invoking `trip-summary` with a trip ID gives the AI a compact snapshot of that trip — days, members, budget, packing — without needing to call multiple tools one by one. + +## Related + +- [MCP-Tools-and-Resources](MCP-Tools-and-Resources) +- [MCP-Setup](MCP-Setup) diff --git a/wiki/MCP-Scopes.md b/wiki/MCP-Scopes.md new file mode 100644 index 0000000000000000000000000000000000000000..54190293f96fc375166c7e577cb5545b0fc5013e --- /dev/null +++ b/wiki/MCP-Scopes.md @@ -0,0 +1,67 @@ +# MCP Scopes + +OAuth scopes control exactly which data your AI client can read or write in TREK. You select scopes during the OAuth consent screen or when pre-creating an OAuth client. You can revoke access at any time by deleting the OAuth client or token from **Settings → Integrations → MCP**. + +![OAuth consent screen](assets/OAuthConsentDCR.png) + +## All scopes + +TREK defines 27 scopes across 13 groups. + +| Group | Scope | Permission | +|---|---|---| +| **Trips** | `trips:read` | View trips, days, day notes, and members | +| | `trips:write` | Create, update, and delete trips, days, day notes, and accommodations; manage members; duplicate trips | +| | `trips:delete` | Permanently delete entire trips (irreversible) | +| | `trips:share` | Create, update, and revoke public share links for trips | +| **Places** | `places:read` | Read places, day assignments, tags, and categories | +| | `places:write` | Create, update, and delete places, assignments, and tags | +| **Atlas** | `atlas:read` | Read visited countries, regions, and bucket list | +| | `atlas:write` | Mark countries and regions visited, manage bucket list | +| **Packing** | `packing:read` | Read packing items, bags, and category assignees | +| | `packing:write` | Add, update, delete, toggle, and reorder packing items and bags | +| **To-dos** | `todos:read` | Read trip to-do items and category assignees | +| | `todos:write` | Create, update, toggle, delete, and reorder to-do items | +| **Budget** | `budget:read` | Read budget items and expense breakdown | +| | `budget:write` | Create, update, and delete budget items | +| **Reservations** | `reservations:read` | Read reservations and accommodation details | +| | `reservations:write` | Create, update, delete, and reorder reservations | +| **Collaboration** | `collab:read` | Read collab notes, polls, and messages | +| | `collab:write` | Create, update, and delete collab notes, polls, and messages | +| **Notifications** | `notifications:read` | Read in-app notifications and unread counts | +| | `notifications:write` | Mark notifications as read or unread (individually or all at once) | +| **Vacation** | `vacay:read` | Read vacation planning data, entries, and stats | +| | `vacay:write` | Create and manage vacation entries, holidays, and team plans | +| **Geo** | `geo:read` | Search locations, resolve map URLs, and reverse-geocode coordinates | +| **Weather** | `weather:read` | Fetch weather forecasts for trip locations and dates | +| **Journey** | `journey:read` | Read journeys, entries, and contributor list | +| | `journey:write` | Create, update, and delete journeys and their entries | +| | `journey:share` | Create, update, and revoke public share links for journeys | + +## Scope rules + +- A `:write` scope implies `:read` access for the same group (e.g. `budget:write` also grants read access to budget data). +- Any `trips:*` scope (`trips:read`, `trips:write`, `trips:delete`, or `trips:share`) grants trip read access. +- `journey:read` or `journey:write` grants journey read access. `journey:share` alone does **not** grant read access — it only enables managing public share links. +- `list_trips` and `get_trip_summary` are always available regardless of scope — they are navigation tools. +- Static tokens and web session JWTs have full access equivalent to all scopes. +- Addon-gated tools (Atlas, Collab, Vacay, Journey) require both the relevant scope **and** the corresponding addon to be enabled by an admin. + +## Choosing the right scopes + +Grant only what you need. Some examples: + +| Use case | Minimum scopes | +|---|---| +| Read-only AI assistant | All `:read` scopes relevant to your data | +| Full trip planner | All scopes except `:delete` (use the Claude.ai or Claude Desktop preset) | +| Budget review only | `trips:read` + `budget:read` | +| Packing list assistant | `trips:read` + `packing:read` + `packing:write` | +| Journey writer | `trips:read` + `journey:read` + `journey:write` | + +The preset buttons in **Settings → Integrations → MCP → OAuth Clients** fill in a reasonable scope set for common clients. VS Code defaults to read-only scopes; Claude.ai and Claude Desktop default to all scopes except `:delete`. + +## Related + +- [MCP-Setup](MCP-Setup) +- [MCP-Tools-and-Resources](MCP-Tools-and-Resources) diff --git a/wiki/MCP-Setup.md b/wiki/MCP-Setup.md new file mode 100644 index 0000000000000000000000000000000000000000..c26540ac711e0cb5f999ad43ae1573b9ce6cc1a7 --- /dev/null +++ b/wiki/MCP-Setup.md @@ -0,0 +1,156 @@ +# MCP Setup + +This page explains how to connect an AI assistant to your TREK instance. TREK supports three authentication methods: OAuth 2.1 with browser consent (recommended for interactive clients), machine clients with no browser login (recommended for AI agents and scripts), and static API tokens (deprecated). + + + +![MCP Setup](assets/MCPConfig.png) + +> **Cloudflare users:** If your TREK instance is proxied through Cloudflare, Bot Fight Mode and Super Bot Fight Mode will block MCP requests from ChatGPT. Claude.ai is not affected. See [Troubleshooting → MCP requests blocked by Cloudflare WAF](#mcp-requests-blocked-by-cloudflare-waf-bot-fight-mode) for the fix. + +## Option A: OAuth 2.1 (recommended) + +OAuth 2.1 is the preferred connection method. You grant specific scopes during the consent step and no token management is required afterward — TREK issues short-lived access tokens and automatically rotates refresh tokens. + +### Claude.ai + +Claude.ai (web) supports native MCP connections — no JSON config file required: + +1. In TREK, go to **Settings → Integrations → MCP → OAuth Clients** and click **Create**. +2. Select the **Claude.ai** preset. This fills in the redirect URI (`https://claude.ai/api/mcp/auth_callback`) and a default scope set. +3. Give the client a name, adjust scopes if needed, and save. Copy the client ID and client secret (`trekcs_` prefix) — the secret is shown only once. +4. In Claude.ai, open the MCP settings and add a new server using your TREK URL (`https:///mcp`). Claude.ai will open your browser to complete the OAuth consent flow. + +### Claude Desktop + +Claude Desktop supports native MCP connections — no JSON config file required: + +1. In TREK, go to **Settings → Integrations → MCP → OAuth Clients** and click **Create**. +2. Select the **Claude Desktop** preset. This fills in the redirect URI and a default scope set. +3. Give the client a name, adjust scopes if needed, and save. Copy the client ID and client secret — the secret is shown only once. +4. In Claude Desktop, open Settings → MCP and add a new server using your TREK URL (`https:///mcp`). Claude Desktop will open your browser to complete the OAuth consent flow. + +### Cursor, VS Code, Windsurf, and Zed + +Clients that support `mcp-remote` can connect in one of two ways. + +**Option 1 — dynamic registration (no pre-created client needed):** + +```json +{ + "mcpServers": { + "trek": { + "command": "npx", + "args": [ + "mcp-remote", + "https:///mcp" + ] + } + } +} +``` + +When the client starts, it fetches TREK's OAuth discovery document (`/.well-known/oauth-authorization-server`), registers itself automatically, and opens your browser to the TREK consent screen. You choose scopes there. + +**Option 2 — pre-created OAuth client:** + +Create a client in TREK using the appropriate preset (Cursor, VS Code, Windsurf, or Zed — all use `http://localhost` as redirect URI), then pass the credentials via `--static-oauth-client-info`: + +```json +{ + "mcpServers": { + "trek": { + "command": "npx", + "args": [ + "mcp-remote", + "https:///mcp", + "--static-oauth-client-info", + "{\"client_id\": \"\", \"client_secret\": \"\"}" + ] + } + } +} +``` + +> On Windows, `npx` may need a full path, for example `C:\PROGRA~1\nodejs\npx.cmd`. + +> **Requirement:** `APP_URL` must be set on the server for OAuth discovery to work. + +### Pre-created OAuth clients + +**Settings → Integrations → MCP → OAuth Clients** lets you create named OAuth clients before connecting. This gives you: + +- A fixed, named scope list defined up front +- A client secret (`trekcs_` prefix, shown once) for confidential client mode +- Preset buttons for Claude.ai, Claude Desktop, Cursor, VS Code, Windsurf, and Zed that fill in the correct redirect URIs and a sensible default scope set + +Each user can have up to **10 OAuth clients**. + +## Option B: Machine client — no browser login (for AI agents and scripts) + +Use this when your AI agent or automation script needs to authenticate silently without any browser interaction. Instead of going through an OAuth consent flow, the client exchanges a `client_id` and `client_secret` directly for an access token ([RFC 6749 §4.4 — Client Credentials grant](https://datatracker.ietf.org/doc/html/rfc6749#section-4.4)). + +**Why this exists:** browser-based OAuth flows break when an AI agent runs unattended. The agent may fire multiple concurrent token refreshes, causing replay detection to invalidate the session and open browser windows. Machine clients sidestep this entirely — there is no refresh token and no rotation race. + +**How it works:** the token acts as its owner (the user who created the client), scoped to the permissions chosen at creation. All TREK permission checks still apply — the AI agent can only access what you can access, narrowed further to the selected scopes. + +### Create a machine client + +1. Go to **Settings → Integrations → MCP → OAuth Clients** and click **New Client**. +2. Tick **Machine client (no browser login)**. The redirect URI field disappears — machine clients don't need one. +3. Give it a name, select scopes, and click **Register Client**. +4. Copy the `client_id` and `client_secret` shown — the secret is displayed only once. + +### How token management works + +Your AI client uses the `client_id` and `client_secret` to request a token directly from TREK (`POST /oauth/token` with `grant_type=client_credentials`). Tokens are valid for 1 hour. When one expires, the client requests a new one silently — no browser window, no user action, no consent screen. This is handled entirely by the client. + +### Who should use this + +Machine clients are designed for **AI agent frameworks and custom MCP client implementations** that can call the token endpoint themselves and handle renewal programmatically. TREK advertises `client_credentials` in its OAuth discovery document (`/.well-known/oauth-authorization-server`), so any compliant client can discover and use it automatically. + +> **`mcp-remote` users:** `mcp-remote` implements the browser-based `authorization_code` flow only — it does not support `client_credentials`. If you use `mcp-remote`, stick with Option A and use the preset for your client. The machine client option is not applicable. + +## Option C: Static API token (deprecated) + +> **Deprecated:** Static tokens will stop working in a future version of TREK. Migrate to OAuth 2.1 or machine clients. + +Static tokens grant full access to all tools and resources with no scope restrictions. Sessions using a static token will receive deprecation warnings in the AI client on every tool call. + +1. Go to **Settings → Integrations → MCP**, open the **API Tokens** sub-tab, and click **Create New Token**. +2. Give the token a name and copy it immediately — it is shown only once. The token starts with `trek_`. +3. Pass the token as a header in your client config: + +```json +{ + "mcpServers": { + "trek": { + "command": "npx", + "args": [ + "mcp-remote", + "https:///mcp", + "--header", + "Authorization: Bearer trek_your_token_here" + ] + } + } +} +``` + +Each user can create up to **10 static tokens**. + +## Authentication reference + +| Method | Grant | Token prefix | Access level | Expiry | +|---|---|---|---|---| +| OAuth 2.1 — browser consent | `authorization_code` | `trekoa_` | Scoped (per-consent) | 1 hour; auto-refreshed via 30-day rolling refresh token (`trekrf_`) | +| Machine client — no browser | `client_credentials` | `trekoa_` | Scoped (per-client), acts as owner | 1 hour; re-request silently, no refresh token | +| OAuth client secret | — | `trekcs_` | Used to authenticate the client at the token endpoint | No expiry (revoke via UI) | +| Static API token | — | `trek_` | Full access | No expiry — **deprecated** | + +## Related + +- [MCP-Overview](MCP-Overview) +- [MCP-Scopes](MCP-Scopes) +- [Admin-MCP-Tokens](Admin-MCP-Tokens) +- [Environment-Variables](Environment-Variables) diff --git a/wiki/MCP-Tools-and-Resources.md b/wiki/MCP-Tools-and-Resources.md new file mode 100644 index 0000000000000000000000000000000000000000..8d593c660284a7fbfc4eb2b569005c2ba33d8178 --- /dev/null +++ b/wiki/MCP-Tools-and-Resources.md @@ -0,0 +1,197 @@ +# MCP Tools and Resources + +TREK exposes **tools** (read and write actions) and **resources** (read-only `trek://` URIs). Tools are registered per-session based on OAuth scopes and enabled addons. + +For addon-gated tools (Packing, To-Dos, Atlas, Collab, Vacay, Journey) and their resources, see [MCP-Addon-Tools](MCP-Addon-Tools). + +## Tools + +### Trip Summary + +| Tool | Description | +|---|---| +| `get_trip_summary` | Full denormalized snapshot of a trip — metadata, members, days with assignments and notes, accommodations, budget, packing, reservations, collab notes, and to-dos in one call. Use this as your context loader before making changes. | + +### Compound tools + +Compound tools collapse multi-step workflows into a single atomic transaction. If the second step fails, the first is rolled back. + +> Use compound tools only when the place or item does not yet exist. For existing records, call the individual tools directly. + +| Tool | Wraps | Description | +|---|---|---| +| `create_and_assign_place` | `create_place` + `assign_place_to_day` | Create a place and assign it to a day. Returns `{ place, assignment }`. Requires `places:write`. | +| `create_place_accommodation` | `create_place` + `create_accommodation` | Create a place and book it as an accommodation. Returns `{ place, accommodation }`. Requires `trips:write`. | +| `create_budget_item_with_members` | `create_budget_item` + `set_budget_item_members` | Create a budget item and set splitting members. If `userIds` is omitted, behaves like `create_budget_item`. Returns `{ item }`. Requires `budget:write`. | + +### Trips + +Requires `trips:read` or `trips:write` scope. + +| Tool | Description | +|---|---| +| `list_trips` | List all trips you own or are a member of. Supports `include_archived` flag. | +| `create_trip` | Create a trip with title, dates, and currency. Days are auto-generated from the date range. | +| `update_trip` | Update a trip's title, description, dates, or currency. | +| `delete_trip` | Delete a trip. Owner only. Requires `trips:delete`. | +| `list_trip_members` | List the owner and all collaborators of a trip. | +| `add_trip_member` | Add a user to a trip by username or email. Owner only. | +| `remove_trip_member` | Remove a collaborator from a trip. Owner only. | +| `copy_trip` | Duplicate a trip (days, places, itinerary, packing, budget, reservations). Packing items reset to unchecked. | +| `export_trip_ics` | Export the trip itinerary and reservations as iCalendar (`.ics`) text. | +| `get_share_link` | Get the current public share link for a trip and its permission flags. Requires `trips:share`. | +| `create_share_link` | Create or update the public share link with configurable visibility flags. Requires `trips:share`. | +| `delete_share_link` | Revoke the public share link for a trip. Requires `trips:share`. | + +### Places + +Requires `places:read` or `places:write` scope. + +| Tool | Description | +|---|---| +| `list_places` | List places in a trip, optionally filtered by assignment status, category, tag, or search query. | +| `create_place` | Add a place with name, coordinates, address, category, notes, website, phone, and optional `google_place_id` / `osm_id`. | +| `update_place` | Update any field of an existing place including transport mode, timing, and price. | +| `delete_place` | Remove a place from a trip. Also removes all day assignments. | +| `bulk_delete_places` | Delete multiple places by ID. Removes all day assignments. Cannot be undone. | +| `import_places_from_url` | Import all places from a publicly shared Google Maps or Naver Maps list URL. | +| `list_categories` | List all available place categories with id, name, icon, and color. | +| `search_place` | Search for a place by name or address. Returns `osm_id` and `google_place_id` for use in `create_place`. | + +### Day Planning + +Requires `trips:read` or `trips:write` scope. + +| Tool | Description | +|---|---| +| `update_day` | Set or clear a day's title. | +| `create_day` | Add a new day to a trip with optional date and notes. | +| `delete_day` | Delete a day from a trip. | +| `assign_place_to_day` | Pin a place to a specific day in the itinerary. Requires `places:write`. | +| `unassign_place` | Remove a place assignment from a day. Requires `places:write`. | +| `reorder_day_assignments` | Reorder places within a day by providing assignment IDs in order. Requires `places:write`. | +| `update_assignment_time` | Set start/end times for a place assignment (e.g. `"09:00"` – `"11:30"`). Pass `null` to clear. Requires `places:write`. | +| `move_assignment` | Move a place assignment to a different day. Requires `places:write`. | +| `get_assignment_participants` | Get users participating in a specific place assignment. | +| `set_assignment_participants` | Set participants for a place assignment (replaces current list). | + +### Day Notes + +Requires `trips:read` or `trips:write` scope. + +| Tool | Description | +|---|---| +| `create_day_note` | Add a note to a specific day with optional time label and emoji icon. | +| `update_day_note` | Edit a day note's text, time, or icon. | +| `delete_day_note` | Remove a note from a day. | + +### Accommodations + +Requires `trips:read` or `trips:write` scope. + +| Tool | Description | +|---|---| +| `create_accommodation` | Add an accommodation (hotel, Airbnb, etc.) linked to a place and a check-in/check-out date range. | +| `update_accommodation` | Update fields on an existing accommodation including dates, times, confirmation, and notes. | +| `delete_accommodation` | Delete an accommodation record from a trip. | + +### Transport + +Requires `reservations:write` scope. + +| Tool | Description | +|---|---| +| `create_transport` | Create a transport booking (`flight`, `train`, `car`, `cruise`) with optional multi-stop endpoints, departure/arrival times, and confirmation details. | +| `update_transport` | Update an existing transport booking. Pass `endpoints[]` to replace all stops. | +| `delete_transport` | Delete a transport booking from a trip. | + +### Reservations + +Requires `reservations:read` or `reservations:write` scope. + +| Tool | Description | +|---|---| +| `create_reservation` | Create a pending reservation — hotels, restaurants, events, tours, activities, and other types. | +| `update_reservation` | Update any field including status (`pending` / `confirmed` / `cancelled`). | +| `delete_reservation` | Delete a reservation and its linked accommodation record if applicable. | +| `reorder_reservations` | Reorder reservations within a day. | +| `link_hotel_accommodation` | Set or update a hotel reservation's check-in/out day links and place. | + +### Budget + +Requires `budget:read` or `budget:write` scope. Budget addon must be enabled. + +| Tool | Description | +|---|---| +| `create_budget_item` | Add an expense with name, category, and price. | +| `update_budget_item` | Update an expense's details, split (persons/days), or notes. | +| `delete_budget_item` | Remove a budget item. | +| `set_budget_item_members` | Set which members are splitting a budget item (replaces current list). | +| `toggle_budget_member_paid` | Mark or unmark a member as having paid their share. | + +### Tags + +Requires `places:read` or `places:write` scope. + +| Tool | Description | +|---|---| +| `list_tags` | List all tags belonging to the current user. | +| `create_tag` | Create a new tag (user-scoped label for places) with optional hex color. | +| `update_tag` | Update the name or color of an existing tag. | +| `delete_tag` | Delete a tag (removes it from all attached places). | + +### Maps & Weather + +| Tool | Scope required | Description | +|---|---|---| +| `get_place_details` | `geo:read` | Fetch detailed information (hours, photos, ratings) about a place by its Google Place ID. | +| `reverse_geocode` | `geo:read` | Get a human-readable address for given coordinates. | +| `resolve_maps_url` | `geo:read` | Resolve a Google Maps share URL to coordinates and place name. | +| `search_airports` | `geo:read` | Search for airports by name, city, or IATA code. Returns IATA code, name, city, country, timezone. | +| `get_airport` | `geo:read` | Look up an airport by IATA code (e.g. `"ZRH"`, `"CDG"`). | +| `get_weather` | `weather:read` | Get a weather forecast for a location and date. | +| `get_detailed_weather` | `weather:read` | Get an hourly/detailed weather forecast for a location and date. | + +### Notifications + +Requires `notifications:read` or `notifications:write` scope. + +| Tool | Description | +|---|---| +| `list_notifications` | List in-app notifications with pagination and optional unread filter. | +| `get_unread_notification_count` | Get the unread notification count. | +| `mark_notification_read` | Mark a notification as read. | +| `mark_notification_unread` | Mark a notification as unread. | +| `mark_all_notifications_read` | Mark all notifications as read. | + +--- + +## Resources + +Resources provide read-only access via `trek://` URIs. Read them to understand current state before making changes. + +### Core resources + +| URI | Scope required | Description | +|---|---|---| +| `trek://trips` | `trips:*` | All trips you own or are a member of | +| `trek://trips/{tripId}` | `trips:*` | Single trip with metadata and member count | +| `trek://trips/{tripId}/days` | `trips:*` | Days of a trip with their assigned places | +| `trek://trips/{tripId}/places` | `places:read` | All places in a trip. Supports `?assignment=all\|unassigned\|assigned` | +| `trek://trips/{tripId}/reservations` | `reservations:read` | Flights, hotels, restaurants, and other reservations | +| `trek://trips/{tripId}/days/{dayId}/notes` | `trips:*` | Notes for a specific day | +| `trek://trips/{tripId}/accommodations` | `trips:*` | Hotels and rentals with check-in/out details | +| `trek://trips/{tripId}/members` | `trips:*` | Owner and collaborators | +| `trek://categories` | (any) | Available place categories (id, name, icon, color) | +| `trek://notifications/in-app` | `notifications:read` | Your in-app notifications (most recent 50, unread first) | + +For addon-gated resources (Budget, Packing, To-Dos, Collab, Atlas, Vacay, Journey), see [MCP-Addon-Tools](MCP-Addon-Tools). + +--- + +## Related + +- [MCP-Addon-Tools](MCP-Addon-Tools) +- [MCP-Scopes](MCP-Scopes) +- [MCP-Prompts](MCP-Prompts) +- [MCP-Setup](MCP-Setup) diff --git a/wiki/Map-Features.md b/wiki/Map-Features.md new file mode 100644 index 0000000000000000000000000000000000000000..3d8e170e429761b7132e9a7dbda3c76538672110 --- /dev/null +++ b/wiki/Map-Features.md @@ -0,0 +1,72 @@ +# Map Features + +The trip planner map shows your places, route lines, transport overlays, and your current location in real time. + + + +![Trip Planner Map](assets/TripPlannerWithPlane.png) + +## Map renderer + +TREK uses **Leaflet** by default. If you configure a Mapbox access token in Settings → Map, the map upgrades to **Mapbox GL** with higher-quality tiles, 3D buildings, and terrain. If Mapbox GL is selected but no access token is present, TREK falls back to Leaflet automatically so the map is never blank. + +The scopes required for Mapbox GL are: +- STYLES:TILES +- STYLES:READ +- FONTS:READ +- DATASETS:WRITE +- VISION:CREATE + +## Place markers + +Each place is shown as a circular marker: + +- **Photo marker** — if the place has a photo (proxied from Google or another provider), that image appears in the circle. +- **Icon marker** — if no photo is available, a category-colored icon is shown instead. +- **Selected place** — the active place has a larger marker. +- **Order badge** — a small badge at the bottom-right of each marker shows the order number(s) of that place within the day's itinerary. If the place appears on multiple days, all order positions are shown separated by `·`. + +When zoomed out, nearby markers are grouped into clusters. Clicking a cluster zooms the map to fit its members; at maximum zoom the cluster spiderfies to show individual markers. + +## Route lines + +When you have a day selected, a dark dashed line connects consecutive places in that day's order. + +## Route time pills + +At zoom level 12 or higher, small pill-shaped labels appear between consecutive places and show the estimated **walking time** and **driving time** for each segment. Below zoom 12 they are hidden to keep the map clean. + +> **Requires:** Settings → Display → **Route calculation** must be ON. When this setting is OFF, TREK never queries the routing service, so no pills are calculated or drawn at any zoom level. + +## Reservation and transport overlay + +Flights, trains, cars, and cruises can be drawn as overlays between their endpoint places. Overlays are **off by default** — activate each reservation individually by clicking the small **Route** icon next to the booking row in the day sidebar. The selection is remembered per trip in your browser. Click the icon again to hide it. + +- **Flights and cruises** — geodesic great-circle arcs +- **Trains and cars** — straight lines +- **Antimeridian crossings** — arcs that would cross the date line are split into sub-arcs to avoid wrapping across the map +- **Endpoint markers** — pill-shaped labels with the transport icon and the endpoint code (e.g. IATA airport code) or location name +- **Flight stats** — a floating label on the arc shows departure code → arrival code and, when times are available, the duration and great-circle distance. Stats labels are only rendered for flights and require Settings → Display → **Route calculation** to be ON. +- **Confirmed reservations** — solid line; **Pending** — dashed line + +> **Admin:** Whether endpoint text labels appear on the endpoint markers is controlled by the **Booking route labels** setting in Settings → Display (`map_booking_labels`). + +## Location button + +The location button sits in the bottom-right corner of the map on mobile devices and cycles through three states: + +| State | Icon | Behavior | +|---|---|---| +| Off | Outline locate | Location not tracked | +| Show | Solid blue locate | Your position is shown as a dot | +| Follow | Solid blue arrow | Map re-centers as you move | + +If geolocation is denied or unavailable, the button turns red. + +## Right-click / middle-click to create a place + +Right-click anywhere on the **Leaflet** map to open the Place form with the clicked coordinates and a reverse-geocoded address already filled in. + +On the **Mapbox GL** map, right-click is reserved for the built-in rotate/pitch gesture, so use **middle-click** instead to trigger the same Place form. + +**See also:** [Places-and-Search](Places-and-Search) · [Day-Plans-and-Notes](Day-Plans-and-Notes) · [Route-Optimization](Route-Optimization) · [Map-Settings](Map-Settings) · [Reservations-and-Bookings](Reservations-and-Bookings) diff --git a/wiki/Map-Settings.md b/wiki/Map-Settings.md new file mode 100644 index 0000000000000000000000000000000000000000..3dd8725c02ddcc14c7b2e3cf385016df77492464 --- /dev/null +++ b/wiki/Map-Settings.md @@ -0,0 +1,84 @@ +# Map Settings + +The Map tab (Settings → Map) controls which map engine and tile source TREK uses in the Trip Planner and Journey maps. Changes take effect after clicking **Save map settings**. + +> **Note:** The Atlas view always uses Leaflet regardless of this setting. + + + +![Map Settings](assets/UsrSettingsMap.png) + +## Map provider + +Choose the rendering engine: + +| Provider | Description | +|----------|-------------| +| **Leaflet** | Classic 2D renderer. Works with any raster tile URL. | +| **Mapbox GL** *(Experimental)* | Vector tiles with 3D buildings and terrain support. Requires a Mapbox access token. | + +## Leaflet — tile source + +When Leaflet is selected, pick a preset or enter a custom tile URL. + +**Built-in presets:** + +| Name | URL | +|------|-----| +| OpenStreetMap | `https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png` | +| OpenStreetMap DE | `https://tile.openstreetmap.de/{z}/{x}/{y}.png` | +| CartoDB Light | `https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png` | +| CartoDB Dark | `https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png` | +| Stadia Smooth | `https://tiles.stadiamaps.com/tiles/alidade_smooth/{z}/{x}/{y}{r}.png` | + +You can also type any XYZ tile URL directly into the text field. + +> **Admin:** The admin can set a default map tile URL for all new users via the **User Defaults** tab in the Admin Panel. See [Admin-Panel-Overview](Admin-Panel-Overview). + +## Mapbox GL — access token and style + +Enter your **public token** (`pk.*`) from [mapbox.com → Access tokens](https://console.mapbox.com/account/access-tokens/). + +Required scopes are: +- STYLES:TILES +- STYLES:READ +- FONTS:READ +- DATASETS:READ +- VISION:READ + +If Mapbox GL is selected but no token is saved, the map area shows an empty state with a prompt to configure the token under Settings → Map → Mapbox GL. + +**Built-in style presets:** + +| Style | Tags | +|-------|------| +| Mapbox Standard | 3D, Apple-like | +| Standard Satellite | 3D, Satellite | +| Streets | 3D, Classic | +| Outdoors | 3D, Terrain | +| Light | 3D, Minimal | +| Dark | 3D, Dark | +| Satellite | 3D, Satellite | +| Satellite Streets | 3D, Satellite | +| Navigation Day | 3D, Apple-like | +| Navigation Night | 3D, Dark | + +You can also enter a custom `mapbox://styles/USER/ID` URL directly. + +### 3D Buildings & Terrain + +Enables pitch and building extrusions on all styles. Terrain elevation (DEM-based height) is additionally applied on satellite styles (`Satellite` and `Satellite Streets`). On non-satellite styles only building extrusions are added; terrain is intentionally omitted on those styles because the elevation data would cause route lines to visually drift away from the HTML place markers. + +### High Quality Mode *(Experimental)* + +Enables antialiasing and globe projection for sharper edges. May impact performance on lower-end devices. + +## Default map center + +Set the default latitude, longitude, and zoom level for the map. You can also click on the map preview to move the center pin. + +## See also + +- [Map-Features](Map-Features) +- [Admin-Panel-Overview](Admin-Panel-Overview) +- [User-Settings](User-Settings) diff --git a/wiki/My-Trips-Dashboard.md b/wiki/My-Trips-Dashboard.md new file mode 100644 index 0000000000000000000000000000000000000000..91db89bc79af3684c8626d4c30224d0e946c8d83 --- /dev/null +++ b/wiki/My-Trips-Dashboard.md @@ -0,0 +1,66 @@ +# My Trips Dashboard + +The dashboard at `/dashboard` is your home base — it lists all your trips, lets you create new ones, and surfaces quick-access widgets. + + + +![My Trips Dashboard](assets/DashboardWidgets.png) + +## View Modes + +Use the toggle button in the top toolbar to switch between **grid** (card thumbnails) and **list** (compact rows). Your preference is saved in `localStorage` under the key `trek_dashboard_view` and persists across sessions. + +In grid mode the dashboard shows a large [Spotlight card](#spotlight-card) for your most relevant trip, with remaining trips in a responsive grid below. In list mode the Spotlight card is not shown separately — all trips (including the one that would be the spotlight) appear as uniform rows in the same sort order. + +## Sort Order + +Trips are always sorted in this order: + +1. **Ongoing** — trips where today falls between the start and end date. +2. **Upcoming** — future trips, sorted by start date ascending (soonest first). +3. **Past** — completed trips, sorted by start date descending (most recent first). + +Trips without dates are treated as past. + +## Spotlight Card + +The first ongoing trip — or the next upcoming trip if none is ongoing — is promoted to a full-width **Spotlight card** at the top of the grid on desktop. On mobile this card appears as a hero at the top of the page. The spotlight card shows a progress bar for ongoing trips and a stats strip (days, places, travel companions). + +If you have no trips yet, the spotlight card is not shown. + +## Archived Trips + +Archived trips are hidden from the main list and collapsed into a separate **Archived** section at the bottom of the page. Click the section header to expand it. You can **Copy**, **Restore**, or permanently **Delete** an archived trip from the row actions. + +## Greeting (Mobile) + +On mobile, the header shows a time-of-day greeting — "Good morning", "Good afternoon", or "Good evening" — along with your username and avatar. The greeting changes at 12:00 (noon) and 18:00. The mobile header also includes a **Notifications** button (bell icon) that navigates to `/notifications`. + +## Dashboard Widgets Sidebar + +On wide screens a sticky right column shows the **Currency Converter** and **Timezone Clock** widgets. Each can be toggled on or off via the Settings icon in the toolbar. On mobile, the widgets are available as a bottom sheet from the quick-action buttons at the top of the page. + +See [Dashboard-Widgets](Dashboard-Widgets) for full usage details. + +## Per-Trip Actions + +On desktop, hover over a card (or open the row actions in list view) to reveal the action buttons — they appear on mouse-over only. On mobile, action buttons are always visible directly on the card cover. The available actions are: + +| Action | Permission required | +|---|---| +| **Edit** | `trip_edit` or `trip_cover_upload` on that trip | +| **Copy** | `trip_create` | +| **Archive / Unarchive** | `trip_archive` on that trip | +| **Delete** | `trip_delete` on that trip | + +Actions not permitted for your role are hidden. Admins always see all actions. + +## Empty State + +When you have no trips, the dashboard shows an illustration and a **Plan your first trip** button that opens the [Creating-a-Trip](Creating-a-Trip) dialog. + +## Related Pages + +- [Creating-a-Trip](Creating-a-Trip) +- [Trip-Planner-Overview](Trip-Planner-Overview) +- [Dashboard-Widgets](Dashboard-Widgets) diff --git a/wiki/Notifications.md b/wiki/Notifications.md new file mode 100644 index 0000000000000000000000000000000000000000..00af021c7c672ae499b1716072d9599aa5be6bc7 --- /dev/null +++ b/wiki/Notifications.md @@ -0,0 +1,88 @@ +# Notifications + +The Notifications tab (Settings → Notifications) lets you choose which events notify you and through which channels. Each toggle saves immediately. + + + +![Notifications tab](assets/NotifSettings.png) + +## Notification channels + +TREK supports four delivery channels. Which channels appear depends on what the admin has enabled server-side. + +| Channel | Description | +|---------|-------------| +| **In-app** | Bell icon in the navigation bar. Always available. Delivered in real time via WebSocket. | +| **Email** | Delivered to your account email. Requires the admin to configure SMTP. | +| **Webhook** | TREK POSTs a JSON payload to a URL you specify. Discord and Slack webhook URLs are auto-detected and receive a natively formatted payload. | +| **ntfy** | Push notifications via [ntfy.sh](https://ntfy.sh) or a self-hosted ntfy server. | + +## Notification events + +The following events are configurable in user settings: + +| Event | Description | +|-------|-------------| +| `trip_invite` | Someone invited you to a trip | +| `booking_change` | A booking was added, updated, or removed in a trip you're part of | +| `trip_reminder` | Reminder before a trip starts | +| `vacay_invite` | You were invited to fuse vacation plans | +| `photos_shared` | Photos were shared with a trip | +| `collab_message` | A new message in a collaborative trip | +| `packing_tagged` | You were assigned to a packing category in a trip | + +All user-facing events support all four channels (in-app, email, webhook, ntfy). A dash (—) in the matrix means that channel/event combination is not implemented. + +### Admin-only events + +The following events are shown in the admin panel (Admin → Notifications) and are not configurable per user: + +| Event | Description | Channels | +|-------|-------------|---------| +| `version_available` | A new TREK version is available | in-app, email, webhook, ntfy | + +### System-only events + +The following events are fired automatically and are not exposed as toggles in any settings panel: + +| Event | Description | Channels | +|-------|-------------|---------| +| `synology_session_cleared` | Your Synology account or URL changed, clearing your Photos session | in-app only | + +## Configuring the matrix + +The preferences panel shows a grid of events × channels. Toggle each intersection independently. Changes are saved automatically. + +## Webhook configuration + +Enter a URL that TREK will POST to when a notification fires. Once saved, the URL is displayed as `••••••••`. Use the **Test** button to send a test payload to the saved URL. + +TREK auto-detects the webhook destination and adjusts the payload format: + +- **Discord** (`discord.com/api/webhooks/…`) — sends a rich embed with title, description, and a timestamp. +- **Slack** (`hooks.slack.com/…`) — sends a formatted Slack message block. +- **Generic** — sends a plain JSON object with `event`, `title`, `body`, `tripName`, `link`, `timestamp`, and `source` (`"TREK"`) fields. + +## ntfy configuration + +Enter your ntfy **topic** and optionally a custom **server URL** (defaults to the server-wide ntfy server set by the admin) and an **access token** for private topics. The token is stored encrypted and displayed as `••••••••` after saving. Use the **Test** button to verify delivery. + +## In-app notification center + +The bell icon in the navigation bar shows your unread notification count. Click it to open the notification panel where you can: + +- Mark individual items read or unread. +- Mark all notifications read at once. +- Delete individual notifications or clear all at once. +- Respond to **boolean notifications** (e.g. trip invites that offer Accept / Decline actions directly in the panel). + +In-app notifications are pushed in real time via WebSocket so the badge and panel update without a page refresh. + +## Per-trip preferences + +Notification preferences are configured globally in Settings → Notifications. There are no per-trip overrides — the same toggle applies across all trips. + +## See also + +- [Environment-Variables](Environment-Variables) +- [User-Settings](User-Settings) diff --git a/wiki/OIDC-SSO.md b/wiki/OIDC-SSO.md new file mode 100644 index 0000000000000000000000000000000000000000..69413bb0b54eb411e7af77854933e0c3153cbaac --- /dev/null +++ b/wiki/OIDC-SSO.md @@ -0,0 +1,79 @@ +# OIDC / Single Sign-On + + + +## What OIDC gives you + +OpenID Connect (OIDC) lets users log in with an existing identity provider — Google, Authentik, Keycloak, or any OIDC-compatible IdP — instead of a local email/password. On first SSO login, a TREK account is created automatically using the email from the provider. + +## User flow + +1. Click **"Sign in with SSO"** on the login page. +2. You are redirected to your identity provider's login page. +3. Authenticate and grant consent. +4. The provider redirects back to TREK at `GET /api/auth/oidc/callback`. If this is your first login, an account is created automatically (subject to registration settings). +5. The server issues a short-lived one-time code and redirects your browser to `/login?oidc_code=`. The frontend immediately exchanges that code at `GET /api/auth/oidc/exchange?code=` to obtain the session. +6. Your `trek_session` cookie is set and you land on the dashboard. + +## Prerequisites + +Set the following environment variables before starting the server: + +| Variable | Required | Description | +|---|---|---| +| `APP_URL` | Yes | Base URL of your TREK instance (e.g. `https://trek.example.com`). Used to build the redirect URI. Can also be set via Admin → Settings. | +| `OIDC_ISSUER` | Yes | Issuer URL of your identity provider. Must use HTTPS in production. | +| `OIDC_CLIENT_ID` | Yes | OAuth 2.0 client ID registered with your IdP. | +| `OIDC_CLIENT_SECRET` | Yes | OAuth 2.0 client secret. | + +Register the following **redirect URI** with your identity provider: + +``` +/api/auth/oidc/callback +``` + +For example: `https://trek.example.com/api/auth/oidc/callback` + +## Optional environment variables + +| Variable | Description | +|---|---| +| `OIDC_DISPLAY_NAME` | Label shown on the SSO button. Defaults to `SSO`. | +| `OIDC_ONLY` | Set to `true` to disable local password login and password registration. SSO login and SSO registration remain governed by their own toggles. This is an environment-variable-only setting and cannot be toggled at runtime via the admin panel. | +| `OIDC_ADMIN_CLAIM` | OIDC claim to inspect for admin role mapping. Defaults to `groups`. The claim value may be an array or a plain string. **Env var only — not configurable via the admin panel.** | +| `OIDC_ADMIN_VALUE` | Value that must be present in `OIDC_ADMIN_CLAIM` to grant the admin role. If unset, claim-based role mapping is disabled. When set, the role is re-evaluated on every login. **Env var only — not configurable via the admin panel.** | +| `OIDC_SCOPE` | Overrides the default scope list sent to the provider. Defaults to `openid email profile`. Ensure `openid` and `email` are always included. **Env var only — not configurable via the admin panel.** | +| `OIDC_DISCOVERY_URL` | Full URL to the OIDC discovery document. Use this for providers with non-standard discovery paths (e.g. Authentik tenants). If unset, discovery is attempted at `/.well-known/openid-configuration`. The discovery document is cached for 1 hour. | + +## New-user registration via SSO + +When an SSO login matches an existing TREK account by email or OIDC subject (`sub`), that account is used and the OIDC identity is linked automatically. If no matching account exists, TREK attempts to create one. The outcome depends on the following: + +- **First user ever**: always created as admin, no invite required. +- **Open SSO registration enabled** (admin panel toggle `oidc_registration`): account is created as a regular user. +- **Invite token present** in the login URL: account is created regardless of the registration toggle. Pass the token as `?invite=` when initiating SSO login (e.g. `GET /api/auth/oidc/login?invite=`). +- **SSO registration disabled and no invite**: login is rejected with a `registration_disabled` error. + +## Admin panel (runtime configuration) + +OIDC can also be configured without environment variables via **Admin → SSO**. The following fields are settable at runtime: + +| Field | Env var equivalent | +|---|---| +| Issuer URL | `OIDC_ISSUER` | +| Client ID | `OIDC_CLIENT_ID` | +| Client Secret | `OIDC_CLIENT_SECRET` | +| Display name | `OIDC_DISPLAY_NAME` | +| Discovery URL | `OIDC_DISCOVERY_URL` | + +Environment variables take priority over database settings when both are present. + +The following variables are **env var only** and have no admin panel equivalent: `OIDC_ONLY`, `OIDC_SCOPE`, `OIDC_ADMIN_CLAIM`, `OIDC_ADMIN_VALUE`. + +The `OIDC_ONLY` env var always overrides the panel's login-method toggles. To disable password login at runtime without `OIDC_ONLY`, use the **password_login** and **password_registration** toggles in Admin → Settings instead. + +> **Note:** The admin panel prevents you from disabling all login methods simultaneously. At least one method (password or SSO) must remain active. Similarly, you cannot remove the OIDC configuration from the admin panel while password login is disabled. + +--- + +**See also:** [Login-and-Registration](Login-and-Registration) · [Environment-Variables](Environment-Variables) diff --git a/wiki/Offline-Mode-and-PWA.md b/wiki/Offline-Mode-and-PWA.md new file mode 100644 index 0000000000000000000000000000000000000000..3f4cc08b2680b5c0af124efbfea1dbb504cdc2b6 --- /dev/null +++ b/wiki/Offline-Mode-and-PWA.md @@ -0,0 +1,76 @@ +# Offline Mode and PWA + +TREK can be installed as a Progressive Web App (PWA) and used without an internet connection for previously synced trips. + +## Install as an app (PWA) + +TREK must be served over **HTTPS** — the install prompt does not appear on plain HTTP. + +**iOS (Safari):** +1. Open TREK in Safari. +2. Tap the Share button. +3. Select **Add to Home Screen**. + +**Android (Chrome / Edge):** +1. Open TREK in the browser. +2. Tap the browser menu. +3. Select **Install app** or **Add to Home Screen**. + +Once installed, TREK launches in **standalone** mode (fullscreen, no browser UI) using the TREK icon. + +## What works offline + +TREK uses Workbox service-worker caching plus an IndexedDB database (Dexie) for structured trip data. The following content is available offline after the first sync: + +**Service-worker cache (Workbox)** + +| Content | Cache name | Strategy | Duration | Max entries | +|---------|------------|----------|----------|-------------| +| CartoDB / OpenStreetMap map tiles | `map-tiles` | CacheFirst | 30 days | 1 000 | +| Leaflet / CDN assets (unpkg) | `cdn-libs` | CacheFirst | 365 days | 30 | +| API responses (trips, places, bookings, etc.) | `api-data` | NetworkFirst (5 s timeout) | 24 hours | 200 | +| Cover images and avatars (`/uploads/covers`, `/uploads/avatars`) | `user-uploads` | CacheFirst | 7 days | 300 | +| App shell (HTML / JS / CSS) | precache | Precached | Until next deploy | — | + +> **Note:** The API cache excludes sensitive endpoints — `/api/auth`, `/api/admin`, `/api/backup`, and `/api/settings` are always fetched from the network. + +**IndexedDB (Dexie) — structured trip data** + +On login, after each trip-list refresh, and on WebSocket reconnect, TREK runs a background sync that writes full trip bundles into IndexedDB: + +- Trips, days, places, packing items, to-dos, budget items, reservations, accommodations, trip members, tags, and categories. +- Non-photo file attachments (PDFs, documents, etc.) are downloaded and stored as blobs in IndexedDB. +- Map tiles are pre-fetched into the service-worker `map-tiles` cache for zoom levels 10–16 across each trip's bounding box (capped at ~50 MB of tiles per sync). + +**Sync scope and eviction** + +- Only ongoing and future trips are cached (trips whose `end_date` is today or later, or has no end date). +- Trips that ended more than 7 days ago are automatically evicted from IndexedDB on the next sync. + +## Offline Cache (Settings → Offline) + +The **Offline Cache** section under Settings → Offline shows the current state of the local cache. + + + +**Stats panel:** +- **Cached trips** — number of trips stored in IndexedDB (Dexie). +- **Pending changes** — number of actions taken offline that are queued to sync. + +**Actions:** +- **Re-sync now** — forces a full sync with the server. Disabled when you are offline. +- **Clear cache** — removes all offline trip data from IndexedDB. You can re-sync any time while online. + +Each cached trip entry shows the trip name, date range, place count, and file count, plus the time of the last successful sync. + +## Limitations + +- New trips created while offline are queued and synced when connectivity is restored. +- Photo uploads require connectivity; non-photo file attachments are pre-cached automatically during sync. +- Real-time collaboration features require an active WebSocket connection. +- Mapbox GL tiles are not cached by the service worker (Mapbox manages its own tile cache internally). + +## See also + +- [User-Settings](User-Settings) +- [Display-Settings](Display-Settings) diff --git a/wiki/PDF-Export.md b/wiki/PDF-Export.md new file mode 100644 index 0000000000000000000000000000000000000000..6378de3e46925c2b1ac0510885d5bf965f2f99aa --- /dev/null +++ b/wiki/PDF-Export.md @@ -0,0 +1,98 @@ +# PDF Export + +TREK can generate two kinds of PDFs from your trip data: a structured **Trip Plan PDF** and a photo-book-style **Journey Book PDF**. Both render as HTML in a sandboxed iframe and open the browser's native print/save dialog — no server-side processing is involved. + + + +![PDF Export](assets/PDFTrip.png) + +--- + +## Trip Plan PDF + +### How to generate + +Open the Day Plan sidebar in the trip planner. Click the **PDF** button in the toolbar at the top of the sidebar. A preview modal opens immediately; click **Save as PDF** to open your browser's print dialog and save the file. + +### Cover page + +- Blurred cover image as background (if the trip has one), with the same image in a circular badge +- Trip title and description +- Date range (first day to last day) +- Stat tiles: + - **Days** — total number of days in the trip + - **Places** — total places in your trip's place list + - **Planned** — number of unique places assigned to at least one day + - **Estimated cost** — sum of all assigned place prices in EUR (hidden if zero) + +### Per-day pages + +Each day starts on a new page with a dark header bar showing the day number, day title, date, and the day's estimated cost. + +Below the header: + +- **Accommodation block** (if an accommodation covers that day): action label (Check-in on the first day, Check-out on the last day, or Accommodation for intermediate days), time, place name, address, notes, and confirmation code (only shown on the check-in day) +- **Timeline items** sorted by their order in the day plan: + - **Places** — thumbnail (or a colored category icon if no image is available), numbered badge, name, category label, address, description, time, price, and notes + - **Notes** — icon, text, and optional time + - **Reservations** — type icon, title, time, type-specific metadata (e.g. airline + flight number + route for flights; train number + platform + seat for trains; party size for restaurants; venue for events; operator for tours), location, and confirmation code + +### Footer + +Every printed page carries a small "made with TREK" logo at the bottom. + +### Font + +Poppins, loaded from Google Fonts at render time. + +--- + +## Journey Book PDF + +### How to generate + +Open a Journey entry in the Travel Journal. Click the **download icon** button in the journal's header area. A preview modal opens; click **Save as PDF** to print. + +![Journey Book PDF Preview](assets/PDFJourney.png) + +### Format + +A4 landscape (`@page { size: A4 landscape; margin: 0 }`). Font: Inter, loaded from Google Fonts. + +### Cover page + +- Hero image (journey cover image, or the first entry photo if none is set) +- Journey title and optional subtitle +- Stat tiles: Days, Entries, Photos + +### Entry pages + +One page per journal entry, in chronological order. The first entry of each date carries a day header (day number and full date) above the content. + +Photo layout adapts to the number of photos on the entry: + +| Photos | Layout | +|--------|--------| +| 1 | Single image, full width | +| 2 | Two images side by side | +| 3 or more | Large hero image on the left, two stacked images on the right | + +Below the photos: entry time and location, entry title, journal text (rendered from Markdown), and pros/cons verdict cards if present. + +### Closing page + +A dark "The End" card. + +--- + +## How rendering works + +Both PDFs use the same mechanism: the HTML document is written into a sandboxed `