feat(collections): a list as a file, so it can leave the instance (#2198)

Sharing a list works between people on the same TREK. This is the other
case: giving one to somebody who runs their own, or keeping a copy. Export
sits beside Edit and Share in the list header and downloads the open list;
Import sits beside New list in the rail, reads a file, shows what is in it
and makes a new list of it. Desktop only, which the route already decides.

What travels is what somebody wrote down: the list's name, colour and
description, its labels, and each place with its address, coordinates,
notes, status, contact details, category name and labels. A file is dull
JSON on purpose, so it can be read and edited by a person.

What does not travel is everything that only means something on the instance
it came from. Ids of every kind, since the receiver issues its own and a
category crosses over by name. Star ratings and members, because a rating is
an opinion somebody gave the people on that list. Provenance into trips,
which points at rows the receiver cannot see. And an image path under
/uploads, which resolves on the sender's server: only an absolute https URL
survives.

A file is a stranger's JSON and is read as one. It is parsed in the browser
that chose it and never uploaded; the parsed list goes through the same
contract on both sides; and a link that is not http(s) arrives as nothing
rather than as an anchor. Strict where it must refuse, forgiving where it
can drop: a file that does not say what it is never reaches the importer,
while one unreadable place inside it is skipped and counted, and one bad
field on a good place costs that field alone.

An import is always a new list. Importing into an existing one would mean
deciding what happens to a place that is already there, and every answer to
that is a merge nobody asked for.
This commit is contained in:
Maurice
2026-09-11 14:06:05 +02:00
committed by Maurice
parent a8e4c45576
commit 2c06c9904b
43 changed files with 1803 additions and 16 deletions
@@ -0,0 +1,190 @@
import { placeWebsiteSchema } from '../place/place.schema';
import { collectionStatusSchema, collectionLinksSchema } from './collection.schema';
import { z } from 'zod';
/**
* A list as a file, so a list of places can leave the instance it was saved on.
*
* ── Why this is worth having ─────────────────────────────────────────────
*
* Somebody who has been to a place knows which twenty of its restaurants are
* worth the walk, and that knowledge currently exists in one account on one
* server. Sharing a list already works between members of the same instance;
* this is the other case, where the person you want to send it to runs their
* own TREK, or none yet (#2198).
*
* ── What travels ─────────────────────────────────────────────────────────
*
* What somebody wrote down: the list's own name, colour and description, and
* for each place its name, where it is, what was noted about it, how to reach
* it, and which of the list's labels it carries. Deliberately dull JSON, so a
* file can be read, edited and diffed by a person.
*
* ── What does not ────────────────────────────────────────────────────────
*
* **Ids of any kind.** A collection id, a place id, a category id and a user
* id all mean something only on the instance that issued them. The receiving
* instance issues its own; a category comes across as its name and is matched
* against the palette on the other side.
*
* **Other people.** Members, invitations, and the star ratings members gave
* (#1435). A rating is an opinion somebody expressed to the people on that
* list, not something the list's owner may forward.
*
* **Provenance into trips.** `source_trip_id` / `source_place_id` point at
* rows the receiver cannot see and must not be handed a reference to.
*
* **Instance-local image paths.** `/uploads/...` and the photo-proxy path
* resolve to a file on the *sender's* server, so on the receiver's screen they
* would either 404 or, behind the same reverse proxy, show a stranger's
* upload. Only an absolute https URL survives, and even that is rendered as an
* image rather than fetched by the server. A cover image is instance-local by
* definition, so a list arrives without one.
*
* **Tags.** A tag row carries a `user_id`; there is no meaningful way to give
* one to somebody else's account.
*
* ── What an imported file is trusted for ─────────────────────────────────
*
* Nothing. It is a stranger's JSON. It is read in the browser that chose it,
* never uploaded as a file, and what is sent to the server goes through this
* contract on both sides. Text is rendered as text; the two fields that would
* otherwise reach a browser API (`website` and a link's `url`) are pinned to
* http(s) by the schemas they borrow, so neither can be a `javascript:` value.
* The counts below are the other half: a file cannot ask the server for more
* rows than the UI that created it could.
*
* Strict where it must refuse, forgiving where it can drop. The envelope is
* checked hard — a file that does not say what it is never reaches the
* importer — while a single place inside it that does not parse is skipped and
* counted, and one unreadable field on an otherwise good place is dropped
* rather than taking the place with it.
*/
/** What the file says it is, so a stray JSON is refused rather than half-read. */
export const COLLECTION_FILE_FORMAT = 'trek.collection';
export const COLLECTION_FILE_VERSION = 1;
/**
* As many places as `collectionSaveFromTripManyRequestSchema` accepts in one
* go, which is the largest bulk write the list UI can already produce.
*/
export const MAX_COLLECTION_FILE_PLACES = 1000;
/** `MAX_LABELS_PER_COLLECTION` in collections.service.ts. */
export const MAX_COLLECTION_FILE_LABELS = 50;
/**
* A megabyte holds a thousand places with room to spare. The point of the
* limit is to refuse a hostile or mistaken file before parsing it.
*/
export const MAX_COLLECTION_FILE_BYTES = 1024 * 1024;
const hexColor = z
.string()
.regex(/^#([0-9a-fA-F]{3}|[0-9a-fA-F]{6})$/)
.nullable()
.optional();
/**
* An image the receiver may show: an absolute https URL and nothing else.
*
* Narrower than `placeImageUrlSchema`, which also admits an instance-local
* path and an inline data URI. Neither belongs in a file: the path resolves on
* the wrong server, and a data URI turns a list of a thousand places into a
* file nobody can send.
*/
export const collectionFileImageSchema = z
.string()
.max(2048)
.refine((v) => /^https:\/\//i.test(v), { message: 'must be an https URL' });
/**
* A value the reader keeps, or nothing.
*
* `.catch(null)` rather than a hard refusal, on the two fields that carry a
* URL: a place whose website is a `javascript:` value, or whose image points
* at the sender's own disk, is still a place worth having, and it arrives
* without that field. Refusing the whole file over one of them would lose a
* hundred good places to a single hand-edited line, and the failure would read
* as "the import is broken" rather than "that link was dropped".
*/
const droppable = <T extends z.ZodTypeAny>(schema: T) => schema.nullable().optional().catch(null);
export const collectionFileLabelSchema = z.object({
name: z.string().min(1).max(60),
color: hexColor,
});
export type CollectionFileLabel = z.infer<typeof collectionFileLabelSchema>;
export const collectionFilePlaceSchema = z.object({
name: z.string().min(1).max(500),
description: z.string().max(5000).nullable().optional(),
lat: z.number().min(-90).max(90).nullable().optional(),
lng: z.number().min(-180).max(180).nullable().optional(),
address: z.string().max(1000).nullable().optional(),
notes: z.string().max(5000).nullable().optional(),
price: z.number().nullable().optional(),
currency: z.string().max(10).nullable().optional(),
website: droppable(placeWebsiteSchema),
phone: z.string().max(60).nullable().optional(),
image_url: droppable(collectionFileImageSchema),
/** Provider ids identify the place itself, not a row on the sender's server. */
google_place_id: z.string().max(255).nullable().optional(),
google_ftid: z.string().max(255).nullable().optional(),
osm_id: z.string().max(255).nullable().optional(),
status: collectionStatusSchema.optional(),
links: collectionLinksSchema.optional(),
/** The category's NAME; the receiving instance matches it against its own palette. */
category: z.string().max(100).nullable().optional(),
/** Label names, matched against `labels` above. Unknown names are dropped. */
labels: z.array(z.string().min(1).max(60)).max(MAX_COLLECTION_FILE_LABELS).optional(),
});
export type CollectionFilePlace = z.infer<typeof collectionFilePlaceSchema>;
export const collectionFileSchema = z.object({
format: z.literal(COLLECTION_FILE_FORMAT),
/**
* Read but not yet branched on: version 1 is the only shape there is. A file
* from a later version still parses when its additions are optional, which
* is the point of keeping every field below optional.
*/
version: z.number().int().min(1),
name: z.string().min(1).max(120),
description: z.string().max(2000).nullable().optional(),
color: hexColor,
icon: z.string().max(40).nullable().optional(),
/** ISO timestamp, for a person reading the file. Nothing branches on it. */
exported_at: z.string().max(40).optional(),
labels: z.array(collectionFileLabelSchema).max(MAX_COLLECTION_FILE_LABELS).optional(),
/**
* Unknown at the envelope, checked one by one where they are written.
*
* A single unreadable place must not cost the other nine hundred: the
* envelope only counts them, and `collectionFilePlaceSchema` is applied per
* entry by the importer, which reports how many it had to drop. Same shape
* as the studio's spread file, for the same reason.
*/
places: z.array(z.unknown()).max(MAX_COLLECTION_FILE_PLACES),
});
export type CollectionFile = z.infer<typeof collectionFileSchema>;
/**
* The import request: the file itself, plus the one thing the importer may
* decide rather than the file. A list always arrives as a NEW list, so there
* is no target id here and no way for a file to write into an existing one.
*/
export const collectionImportRequestSchema = z.object({
file: collectionFileSchema,
/** Overrides the file's name when the importer typed one. */
name: z.string().min(1).max(120).optional(),
});
export type CollectionImportRequest = z.infer<typeof collectionImportRequestSchema>;
export interface CollectionImportResult {
/** The list as created, so the client can select it without a refetch. */
collection: unknown;
imported: number;
/** Places the file carried that the contract refused. */
skipped: number;
}
+16
View File
@@ -144,6 +144,22 @@ const collection: TranslationStrings = {
'collections.picker.hint': 'اختر مكانًا من مجموعاتك',
'collections.picker.use': 'استخدام',
// Export / import a list as a file (#2198)
'collections.file.export': 'تصدير',
'collections.file.exportTitle': 'تنزيل هذه القائمة كملف',
'collections.file.importButton': 'استيراد قائمة من ملف',
'collections.file.importTitle': 'استيراد قائمة',
'collections.file.choose': 'اختر ملف قائمة',
'collections.file.confirm': 'استيراد',
'collections.file.change': 'تغيير',
'collections.file.labelCount': '{count} تسمية',
'collections.file.hint': 'تصل الأماكن كقائمة جديدة خاصة بك. أما التقييمات والأعضاء والصور المرفوعة فلا تأتي معها.',
'collections.file.done': 'تم استيراد {count} مكانًا',
'collections.file.doneSkipped': 'تم استيراد {count} مكانًا وتخطّي {skipped}',
'collections.file.errorTooLarge': 'هذا الملف أكبر من أن يكون قائمة.',
'collections.file.errorUnreadable': 'تعذّرت قراءة هذا الملف.',
'collections.file.errorNotACollection': 'هذا ليس ملف قائمة من TREK.',
'collections.share.title': 'مشاركة القائمة',
'collections.share.titleNamed': 'مشاركة «{name}»',
'collections.share.button': 'مشاركة',
+17
View File
@@ -144,6 +144,23 @@ const collection: TranslationStrings = {
'collections.picker.hint': 'Escolha um lugar das suas coleções',
'collections.picker.use': 'Usar',
// Export / import a list as a file (#2198)
'collections.file.export': 'Exportar',
'collections.file.exportTitle': 'Baixar esta lista como arquivo',
'collections.file.importButton': 'Importar uma lista de um arquivo',
'collections.file.importTitle': 'Importar lista',
'collections.file.choose': 'Escolher um arquivo de lista',
'collections.file.confirm': 'Importar',
'collections.file.change': 'Trocar',
'collections.file.labelCount': '{count} etiquetas',
'collections.file.hint':
'Os lugares chegam como uma nova lista sua. Avaliações, membros e fotos enviadas ficam para trás.',
'collections.file.done': '{count} lugares importados',
'collections.file.doneSkipped': '{count} lugares importados, {skipped} ignorados',
'collections.file.errorTooLarge': 'Esse arquivo é grande demais para ser uma lista.',
'collections.file.errorUnreadable': 'Não foi possível ler esse arquivo.',
'collections.file.errorNotACollection': 'Esse não é um arquivo de lista do TREK.',
'collections.share.title': 'Compartilhar lista',
'collections.share.titleNamed': 'Compartilhar “{name}”',
'collections.share.button': 'Compartilhar',
+17
View File
@@ -135,6 +135,23 @@ const collection: TranslationStrings = {
'collections.picker.empty': 'No hi ha llocs desats per afegir',
'collections.picker.hint': 'Tria un lloc de les teves col·leccions',
'collections.picker.use': 'Utilitza',
// Export / import a list as a file (#2198)
'collections.file.export': 'Exporta',
'collections.file.exportTitle': 'Baixa aquesta llista com a fitxer',
'collections.file.importButton': 'Importa una llista des d’un fitxer',
'collections.file.importTitle': 'Importa una llista',
'collections.file.choose': 'Tria un fitxer de llista',
'collections.file.confirm': 'Importa',
'collections.file.change': 'Canvia',
'collections.file.labelCount': '{count} etiquetes',
'collections.file.hint':
'Els llocs arriben com una llista nova teva. Les valoracions, els membres i les fotos pujades es queden enrere.',
'collections.file.done': '{count} llocs importats',
'collections.file.doneSkipped': '{count} llocs importats, {skipped} omesos',
'collections.file.errorTooLarge': 'Aquest fitxer és massa gran per ser una llista.',
'collections.file.errorUnreadable': 'No s’ha pogut llegir aquest fitxer.',
'collections.file.errorNotACollection': 'Això no és un fitxer de llista del TREK.',
'collections.share.title': 'Compartir llista',
'collections.share.titleNamed': 'Compartir «{name}»',
'collections.share.button': 'Compartir',
+17
View File
@@ -143,6 +143,23 @@ const collection: TranslationStrings = {
'collections.picker.hint': 'Vyberte místo ze svých sbírek',
'collections.picker.use': 'Použít',
// Export / import a list as a file (#2198)
'collections.file.export': 'Exportovat',
'collections.file.exportTitle': 'Stáhnout tento seznam jako soubor',
'collections.file.importButton': 'Importovat seznam ze souboru',
'collections.file.importTitle': 'Import seznamu',
'collections.file.choose': 'Vyberte soubor se seznamem',
'collections.file.confirm': 'Importovat',
'collections.file.change': 'Změnit',
'collections.file.labelCount': 'Štítky: {count}',
'collections.file.hint':
'Místa se objeví jako váš nový seznam. Hodnocení, členové a nahrané fotky zůstanou tam, kde byly.',
'collections.file.done': 'Importováno míst: {count}',
'collections.file.doneSkipped': 'Importováno míst: {count}, přeskočeno: {skipped}',
'collections.file.errorTooLarge': 'Tento soubor je na seznam příliš velký.',
'collections.file.errorUnreadable': 'Tento soubor se nepodařilo přečíst.',
'collections.file.errorNotACollection': 'Toto není soubor se seznamem TREK.',
'collections.share.title': 'Sdílet seznam',
'collections.share.titleNamed': 'Sdílet „{name}“',
'collections.share.button': 'Sdílet',
+17
View File
@@ -145,6 +145,23 @@ const collection: TranslationStrings = {
'collections.picker.hint': 'Wähle einen Ort aus deinen Sammlungen',
'collections.picker.use': 'Übernehmen',
// Export / import a list as a file (#2198)
'collections.file.export': 'Exportieren',
'collections.file.exportTitle': 'Diese Liste als Datei herunterladen',
'collections.file.importButton': 'Liste aus einer Datei importieren',
'collections.file.importTitle': 'Liste importieren',
'collections.file.choose': 'Listendatei auswählen',
'collections.file.confirm': 'Importieren',
'collections.file.change': 'Ändern',
'collections.file.labelCount': '{count} Labels',
'collections.file.hint':
'Die Orte landen in einer neuen eigenen Liste. Bewertungen, Mitglieder und hochgeladene Fotos bleiben zurück.',
'collections.file.done': '{count} Orte importiert',
'collections.file.doneSkipped': '{count} Orte importiert, {skipped} übersprungen',
'collections.file.errorTooLarge': 'Diese Datei ist zu groß für eine Liste.',
'collections.file.errorUnreadable': 'Diese Datei konnte nicht gelesen werden.',
'collections.file.errorNotACollection': 'Das ist keine TREK-Listendatei.',
'collections.share.title': 'Liste teilen',
'collections.share.titleNamed': '„{name}“ teilen',
'collections.share.button': 'Teilen',
+17
View File
@@ -144,6 +144,23 @@ const collection: TranslationStrings = {
'collections.picker.hint': 'Pick a place from your collections',
'collections.picker.use': 'Use',
// Export / import a list as a file (#2198)
'collections.file.export': 'Export',
'collections.file.exportTitle': 'Download this list as a file',
'collections.file.importButton': 'Import a list from a file',
'collections.file.importTitle': 'Import a list',
'collections.file.choose': 'Choose a list file',
'collections.file.confirm': 'Import',
'collections.file.change': 'Change',
'collections.file.labelCount': '{count} labels',
'collections.file.hint':
'The places arrive as a new list of your own. Ratings, members and uploaded photos stay behind.',
'collections.file.done': '{count} places imported',
'collections.file.doneSkipped': '{count} places imported, {skipped} skipped',
'collections.file.errorTooLarge': 'That file is too large to be a list.',
'collections.file.errorUnreadable': 'That file could not be read.',
'collections.file.errorNotACollection': 'That is not a TREK list file.',
'collections.share.title': 'Share list',
'collections.share.titleNamed': 'Share “{name}”',
'collections.share.button': 'Share',
+17
View File
@@ -144,6 +144,23 @@ const collection: TranslationStrings = {
'collections.picker.hint': 'Elige un lugar de tus colecciones',
'collections.picker.use': 'Usar',
// Export / import a list as a file (#2198)
'collections.file.export': 'Exportar',
'collections.file.exportTitle': 'Descargar esta lista como archivo',
'collections.file.importButton': 'Importar una lista desde un archivo',
'collections.file.importTitle': 'Importar una lista',
'collections.file.choose': 'Elegir un archivo de lista',
'collections.file.confirm': 'Importar',
'collections.file.change': 'Cambiar',
'collections.file.labelCount': '{count} etiquetas',
'collections.file.hint':
'Los lugares llegan como una lista nueva tuya. Las valoraciones, los miembros y las fotos subidas se quedan atrás.',
'collections.file.done': '{count} lugares importados',
'collections.file.doneSkipped': '{count} lugares importados, {skipped} omitidos',
'collections.file.errorTooLarge': 'Ese archivo es demasiado grande para ser una lista.',
'collections.file.errorUnreadable': 'No se ha podido leer ese archivo.',
'collections.file.errorNotACollection': 'Ese no es un archivo de lista de TREK.',
'collections.share.title': 'Compartir lista',
'collections.share.titleNamed': 'Compartir «{name}»',
'collections.share.button': 'Compartir',
+17
View File
@@ -144,6 +144,23 @@ const collection: TranslationStrings = {
'collections.picker.hint': 'Choisissez un lieu dans vos collections',
'collections.picker.use': 'Utiliser',
// Export / import a list as a file (#2198)
'collections.file.export': 'Exporter',
'collections.file.exportTitle': 'Télécharger cette liste sous forme de fichier',
'collections.file.importButton': 'Importer une liste depuis un fichier',
'collections.file.importTitle': 'Importer une liste',
'collections.file.choose': 'Choisir un fichier de liste',
'collections.file.confirm': 'Importer',
'collections.file.change': 'Changer',
'collections.file.labelCount': '{count} étiquettes',
'collections.file.hint':
'Les lieux arrivent dans une nouvelle liste qui vous appartient. Les notes, les membres et les photos envoyées restent en arrière.',
'collections.file.done': '{count} lieux importés',
'collections.file.doneSkipped': '{count} lieux importés, {skipped} ignorés',
'collections.file.errorTooLarge': 'Ce fichier est trop volumineux pour être une liste.',
'collections.file.errorUnreadable': 'Ce fichier n’a pas pu être lu.',
'collections.file.errorNotACollection': 'Ce n’est pas un fichier de liste TREK.',
'collections.share.title': 'Partager la liste',
'collections.share.titleNamed': 'Partager « {name} »',
'collections.share.button': 'Partager',
+17
View File
@@ -144,6 +144,23 @@ const collection: TranslationStrings = {
'collections.picker.hint': 'Διάλεξε ένα μέρος από τις συλλογές σου',
'collections.picker.use': 'Χρήση',
// Export / import a list as a file (#2198)
'collections.file.export': 'Εξαγωγή',
'collections.file.exportTitle': 'Λήψη αυτής της λίστας ως αρχείο',
'collections.file.importButton': 'Εισαγωγή λίστας από αρχείο',
'collections.file.importTitle': 'Εισαγωγή λίστας',
'collections.file.choose': 'Επιλέξτε αρχείο λίστας',
'collections.file.confirm': 'Εισαγωγή',
'collections.file.change': 'Αλλαγή',
'collections.file.labelCount': '{count} ετικέτες',
'collections.file.hint':
'Τα μέρη έρχονται ως νέα δική σας λίστα. Οι βαθμολογίες, τα μέλη και οι φωτογραφίες που ανέβηκαν μένουν πίσω.',
'collections.file.done': 'Εισήχθησαν {count} μέρη',
'collections.file.doneSkipped': 'Εισήχθησαν {count} μέρη, παραλείφθηκαν {skipped}',
'collections.file.errorTooLarge': 'Αυτό το αρχείο είναι πολύ μεγάλο για λίστα.',
'collections.file.errorUnreadable': 'Δεν ήταν δυνατή η ανάγνωση αυτού του αρχείου.',
'collections.file.errorNotACollection': 'Αυτό δεν είναι αρχείο λίστας του TREK.',
'collections.share.title': 'Κοινή χρήση λίστας',
'collections.share.titleNamed': 'Κοινή χρήση «{name}»',
'collections.share.button': 'Κοινή χρήση',
+17
View File
@@ -145,6 +145,23 @@ const collection: TranslationStrings = {
'collections.picker.hint': 'Válassz egy helyet a gyűjteményeidből',
'collections.picker.use': 'Használat',
// Export / import a list as a file (#2198)
'collections.file.export': 'Exportálás',
'collections.file.exportTitle': 'A lista letöltése fájlként',
'collections.file.importButton': 'Lista importálása fájlból',
'collections.file.importTitle': 'Lista importálása',
'collections.file.choose': 'Válassz listafájlt',
'collections.file.confirm': 'Importálás',
'collections.file.change': 'Csere',
'collections.file.labelCount': '{count} címke',
'collections.file.hint':
'A helyek új, saját listaként érkeznek. Az értékelések, a tagok és a feltöltött fotók nem jönnek át.',
'collections.file.done': '{count} hely importálva',
'collections.file.doneSkipped': '{count} hely importálva, {skipped} kihagyva',
'collections.file.errorTooLarge': 'Ez a fájl túl nagy ahhoz, hogy lista legyen.',
'collections.file.errorUnreadable': 'Ezt a fájlt nem sikerült beolvasni.',
'collections.file.errorNotACollection': 'Ez nem TREK-listafájl.',
'collections.share.title': 'Lista megosztása',
'collections.share.titleNamed': '„{name}” megosztása',
'collections.share.button': 'Megosztás',
+17
View File
@@ -144,6 +144,23 @@ const collection: TranslationStrings = {
'collections.picker.hint': 'Pilih tempat dari koleksimu',
'collections.picker.use': 'Gunakan',
// Export / import a list as a file (#2198)
'collections.file.export': 'Ekspor',
'collections.file.exportTitle': 'Unduh daftar ini sebagai berkas',
'collections.file.importButton': 'Impor daftar dari berkas',
'collections.file.importTitle': 'Impor daftar',
'collections.file.choose': 'Pilih berkas daftar',
'collections.file.confirm': 'Impor',
'collections.file.change': 'Ganti',
'collections.file.labelCount': '{count} label',
'collections.file.hint':
'Tempat-tempat itu masuk sebagai daftar baru milikmu. Penilaian, anggota, dan foto yang diunggah tidak ikut.',
'collections.file.done': '{count} tempat diimpor',
'collections.file.doneSkipped': '{count} tempat diimpor, {skipped} dilewati',
'collections.file.errorTooLarge': 'Berkas ini terlalu besar untuk sebuah daftar.',
'collections.file.errorUnreadable': 'Berkas ini tidak bisa dibaca.',
'collections.file.errorNotACollection': 'Ini bukan berkas daftar TREK.',
'collections.share.title': 'Bagikan daftar',
'collections.share.titleNamed': 'Bagikan “{name}”',
'collections.share.button': 'Bagikan',
+17
View File
@@ -144,6 +144,23 @@ const collection: TranslationStrings = {
'collections.picker.hint': 'Scegli un luogo dalle tue raccolte',
'collections.picker.use': 'Usa',
// Export / import a list as a file (#2198)
'collections.file.export': 'Esporta',
'collections.file.exportTitle': 'Scarica questo elenco come file',
'collections.file.importButton': 'Importa un elenco da un file',
'collections.file.importTitle': 'Importa un elenco',
'collections.file.choose': 'Scegli un file di elenco',
'collections.file.confirm': 'Importa',
'collections.file.change': 'Cambia',
'collections.file.labelCount': '{count} etichette',
'collections.file.hint':
'I luoghi arrivano come un nuovo elenco tuo. Valutazioni, membri e foto caricate restano indietro.',
'collections.file.done': '{count} luoghi importati',
'collections.file.doneSkipped': '{count} luoghi importati, {skipped} saltati',
'collections.file.errorTooLarge': 'Questo file è troppo grande per essere un elenco.',
'collections.file.errorUnreadable': 'Non è stato possibile leggere questo file.',
'collections.file.errorNotACollection': 'Questo non è un file di elenco TREK.',
'collections.share.title': 'Condividi lista',
'collections.share.titleNamed': 'Condividi «{name}»',
'collections.share.button': 'Condividi',
+17
View File
@@ -143,6 +143,23 @@ const collection: TranslationStrings = {
'collections.picker.hint': 'コレクションから場所を選択',
'collections.picker.use': '使用',
// Export / import a list as a file (#2198)
'collections.file.export': 'エクスポート',
'collections.file.exportTitle': 'このリストをファイルとしてダウンロード',
'collections.file.importButton': 'ファイルからリストをインポート',
'collections.file.importTitle': 'リストのインポート',
'collections.file.choose': 'リストファイルを選択',
'collections.file.confirm': 'インポート',
'collections.file.change': '変更',
'collections.file.labelCount': 'ラベル {count} 件',
'collections.file.hint':
'場所は自分の新しいリストとして追加されます。評価、メンバー、アップロードした写真は引き継がれません。',
'collections.file.done': '{count} 件の場所をインポートしました',
'collections.file.doneSkipped': '{count} 件の場所をインポートし、{skipped} 件をスキップしました',
'collections.file.errorTooLarge': 'このファイルはリストとしては大きすぎます。',
'collections.file.errorUnreadable': 'このファイルを読み取れませんでした。',
'collections.file.errorNotACollection': 'これは TREK のリストファイルではありません。',
'collections.share.title': 'リストを共有',
'collections.share.titleNamed': '「{name}」を共有',
'collections.share.button': '共有',
+16
View File
@@ -143,6 +143,22 @@ const collection: TranslationStrings = {
'collections.picker.hint': '컬렉션에서 장소를 선택하세요',
'collections.picker.use': '사용',
// Export / import a list as a file (#2198)
'collections.file.export': '내보내기',
'collections.file.exportTitle': '이 목록을 파일로 다운로드',
'collections.file.importButton': '파일에서 목록 가져오기',
'collections.file.importTitle': '목록 가져오기',
'collections.file.choose': '목록 파일 선택',
'collections.file.confirm': '가져오기',
'collections.file.change': '변경',
'collections.file.labelCount': '라벨 {count}개',
'collections.file.hint': '장소는 내 새 목록으로 들어옵니다. 평가, 멤버, 업로드한 사진은 함께 오지 않습니다.',
'collections.file.done': '장소 {count}개를 가져왔습니다',
'collections.file.doneSkipped': '장소 {count}개를 가져오고 {skipped}개를 건너뛰었습니다',
'collections.file.errorTooLarge': '이 파일은 목록이라고 하기에 너무 큽니다.',
'collections.file.errorUnreadable': '이 파일을 읽을 수 없습니다.',
'collections.file.errorNotACollection': 'TREK 목록 파일이 아닙니다.',
'collections.share.title': '목록 공유',
'collections.share.titleNamed': '“{name}” 공유',
'collections.share.button': '공유',
+17
View File
@@ -144,6 +144,23 @@ const collection: TranslationStrings = {
'collections.picker.hint': 'Kies een plek uit je collecties',
'collections.picker.use': 'Gebruiken',
// Export / import a list as a file (#2198)
'collections.file.export': 'Exporteren',
'collections.file.exportTitle': 'Deze lijst als bestand downloaden',
'collections.file.importButton': 'Een lijst uit een bestand importeren',
'collections.file.importTitle': 'Lijst importeren',
'collections.file.choose': 'Kies een lijstbestand',
'collections.file.confirm': 'Importeren',
'collections.file.change': 'Wijzigen',
'collections.file.labelCount': '{count} labels',
'collections.file.hint':
'De plekken komen binnen als een nieuwe eigen lijst. Beoordelingen, leden en geüploade foto’s blijven achter.',
'collections.file.done': '{count} plekken geïmporteerd',
'collections.file.doneSkipped': '{count} plekken geïmporteerd, {skipped} overgeslagen',
'collections.file.errorTooLarge': 'Dit bestand is te groot om een lijst te zijn.',
'collections.file.errorUnreadable': 'Dit bestand kon niet worden gelezen.',
'collections.file.errorNotACollection': 'Dit is geen TREK-lijstbestand.',
'collections.share.title': 'Lijst delen',
'collections.share.titleNamed': '“{name}” delen',
'collections.share.button': 'Delen',
+17
View File
@@ -144,6 +144,23 @@ const collection: TranslationStrings = {
'collections.picker.hint': 'Wybierz miejsce ze swoich kolekcji',
'collections.picker.use': 'Użyj',
// Export / import a list as a file (#2198)
'collections.file.export': 'Eksportuj',
'collections.file.exportTitle': 'Pobierz tę listę jako plik',
'collections.file.importButton': 'Zaimportuj listę z pliku',
'collections.file.importTitle': 'Importuj listę',
'collections.file.choose': 'Wybierz plik listy',
'collections.file.confirm': 'Importuj',
'collections.file.change': 'Zmień',
'collections.file.labelCount': 'Etykiety: {count}',
'collections.file.hint':
'Miejsca trafią do nowej, własnej listy. Oceny, członkowie i wgrane zdjęcia zostaną pominięte.',
'collections.file.done': 'Zaimportowano miejsca: {count}',
'collections.file.doneSkipped': 'Zaimportowano miejsca: {count}, pominięto: {skipped}',
'collections.file.errorTooLarge': 'Ten plik jest za duży, aby był listą.',
'collections.file.errorUnreadable': 'Nie udało się odczytać tego pliku.',
'collections.file.errorNotACollection': 'To nie jest plik listy TREK.',
'collections.share.title': 'Udostępnij listę',
'collections.share.titleNamed': 'Udostępnij „{name}”',
'collections.share.button': 'Udostępnij',
+17
View File
@@ -143,6 +143,23 @@ const collection: TranslationStrings = {
'collections.picker.hint': 'Выберите место из своих коллекций',
'collections.picker.use': 'Использовать',
// Export / import a list as a file (#2198)
'collections.file.export': 'Экспорт',
'collections.file.exportTitle': 'Скачать этот список файлом',
'collections.file.importButton': 'Импортировать список из файла',
'collections.file.importTitle': 'Импорт списка',
'collections.file.choose': 'Выберите файл списка',
'collections.file.confirm': 'Импортировать',
'collections.file.change': 'Изменить',
'collections.file.labelCount': 'Меток: {count}',
'collections.file.hint':
'Места появятся в новом собственном списке. Оценки, участники и загруженные фотографии остаются на прежнем месте.',
'collections.file.done': 'Импортировано мест: {count}',
'collections.file.doneSkipped': 'Импортировано мест: {count}, пропущено: {skipped}',
'collections.file.errorTooLarge': 'Этот файл слишком велик для списка.',
'collections.file.errorUnreadable': 'Не удалось прочитать этот файл.',
'collections.file.errorNotACollection': 'Это не файл списка TREK.',
'collections.share.title': 'Поделиться списком',
'collections.share.titleNamed': 'Поделиться «{name}»',
'collections.share.button': 'Поделиться',
+17
View File
@@ -143,6 +143,23 @@ const collection: TranslationStrings = {
'collections.picker.hint': 'Välj en plats från dina samlingar',
'collections.picker.use': 'Använd',
// Export / import a list as a file (#2198)
'collections.file.export': 'Exportera',
'collections.file.exportTitle': 'Ladda ner den här listan som en fil',
'collections.file.importButton': 'Importera en lista från en fil',
'collections.file.importTitle': 'Importera lista',
'collections.file.choose': 'Välj en listfil',
'collections.file.confirm': 'Importera',
'collections.file.change': 'Byt',
'collections.file.labelCount': '{count} etiketter',
'collections.file.hint':
'Platserna kommer in som en ny egen lista. Betyg, medlemmar och uppladdade foton följer inte med.',
'collections.file.done': '{count} platser importerade',
'collections.file.doneSkipped': '{count} platser importerade, {skipped} överhoppade',
'collections.file.errorTooLarge': 'Filen är för stor för att vara en lista.',
'collections.file.errorUnreadable': 'Filen gick inte att läsa.',
'collections.file.errorNotACollection': 'Det här är ingen TREK-listfil.',
'collections.share.title': 'Dela lista',
'collections.share.titleNamed': 'Dela ”{name}”',
'collections.share.button': 'Dela',
+17
View File
@@ -144,6 +144,23 @@ const collection: TranslationStrings = {
'collections.picker.hint': 'Koleksiyonlarından bir yer seç',
'collections.picker.use': 'Kullan',
// Export / import a list as a file (#2198)
'collections.file.export': 'Dışa aktar',
'collections.file.exportTitle': 'Bu listeyi dosya olarak indir',
'collections.file.importButton': 'Dosyadan liste içe aktar',
'collections.file.importTitle': 'Liste içe aktar',
'collections.file.choose': 'Bir liste dosyası seç',
'collections.file.confirm': 'İçe aktar',
'collections.file.change': 'Değiştir',
'collections.file.labelCount': '{count} etiket',
'collections.file.hint':
'Yerler size ait yeni bir liste olarak gelir. Puanlar, üyeler ve yüklenen fotoğraflar geride kalır.',
'collections.file.done': '{count} yer içe aktarıldı',
'collections.file.doneSkipped': '{count} yer içe aktarıldı, {skipped} tanesi atlandı',
'collections.file.errorTooLarge': 'Bu dosya liste olamayacak kadar büyük.',
'collections.file.errorUnreadable': 'Bu dosya okunamadı.',
'collections.file.errorNotACollection': 'Bu bir TREK liste dosyası değil.',
'collections.share.title': 'Listeyi paylaş',
'collections.share.titleNamed': '“{name}” listesini paylaş',
'collections.share.button': 'Paylaş',
+17
View File
@@ -143,6 +143,23 @@ const collection: TranslationStrings = {
'collections.picker.hint': 'Виберіть місце зі своїх колекцій',
'collections.picker.use': 'Використати',
// Export / import a list as a file (#2198)
'collections.file.export': 'Експортувати',
'collections.file.exportTitle': 'Завантажити цей список файлом',
'collections.file.importButton': 'Імпортувати список із файлу',
'collections.file.importTitle': 'Імпорт списку',
'collections.file.choose': 'Виберіть файл списку',
'collections.file.confirm': 'Імпортувати',
'collections.file.change': 'Змінити',
'collections.file.labelCount': 'Міток: {count}',
'collections.file.hint':
'Місця з’являться як ваш новий список. Оцінки, учасники та завантажені фото не переносяться.',
'collections.file.done': 'Імпортовано місць: {count}',
'collections.file.doneSkipped': 'Імпортовано місць: {count}, пропущено: {skipped}',
'collections.file.errorTooLarge': 'Цей файл завеликий, щоб бути списком.',
'collections.file.errorUnreadable': 'Не вдалося прочитати цей файл.',
'collections.file.errorNotACollection': 'Це не файл списку TREK.',
'collections.share.title': 'Поділитися списком',
'collections.share.titleNamed': 'Поділитися «{name}»',
'collections.share.button': 'Поділитися',
+17
View File
@@ -144,6 +144,23 @@ const collection: TranslationStrings = {
'collections.picker.hint': 'Chọn một địa điểm từ bộ sưu tập của bạn',
'collections.picker.use': 'Dùng',
// Export / import a list as a file (#2198)
'collections.file.export': 'Xuất',
'collections.file.exportTitle': 'Tải danh sách này về dưới dạng tệp',
'collections.file.importButton': 'Nhập danh sách từ tệp',
'collections.file.importTitle': 'Nhập danh sách',
'collections.file.choose': 'Chọn tệp danh sách',
'collections.file.confirm': 'Nhập',
'collections.file.change': 'Đổi',
'collections.file.labelCount': '{count} nhãn',
'collections.file.hint':
'Các địa điểm sẽ vào một danh sách mới của bạn. Đánh giá, thành viên và ảnh đã tải lên không đi kèm.',
'collections.file.done': 'Đã nhập {count} địa điểm',
'collections.file.doneSkipped': 'Đã nhập {count} địa điểm, bỏ qua {skipped}',
'collections.file.errorTooLarge': 'Tệp này quá lớn để là một danh sách.',
'collections.file.errorUnreadable': 'Không đọc được tệp này.',
'collections.file.errorNotACollection': 'Đây không phải tệp danh sách của TREK.',
'collections.share.title': 'Chia sẻ danh sách',
'collections.share.titleNamed': 'Chia sẻ “{name}”',
'collections.share.button': 'Chia sẻ',
+16
View File
@@ -143,6 +143,22 @@ const collection: TranslationStrings = {
'collections.picker.hint': '從你的收藏中選擇一個地點',
'collections.picker.use': '使用',
// Export / import a list as a file (#2198)
'collections.file.export': '匯出',
'collections.file.exportTitle': '將此清單下載為檔案',
'collections.file.importButton': '從檔案匯入清單',
'collections.file.importTitle': '匯入清單',
'collections.file.choose': '選擇清單檔案',
'collections.file.confirm': '匯入',
'collections.file.change': '更換',
'collections.file.labelCount': '{count} 個標籤',
'collections.file.hint': '這些地點會成為你自己的新清單。評分、成員與上傳的照片不會一併匯入。',
'collections.file.done': '已匯入 {count} 個地點',
'collections.file.doneSkipped': '已匯入 {count} 個地點,略過 {skipped} 個',
'collections.file.errorTooLarge': '這個檔案太大,不像是一份清單。',
'collections.file.errorUnreadable': '無法讀取這個檔案。',
'collections.file.errorNotACollection': '這不是 TREK 清單檔案。',
'collections.share.title': '分享清單',
'collections.share.titleNamed': '分享「{name}」',
'collections.share.button': '分享',
+16
View File
@@ -143,6 +143,22 @@ const collection: TranslationStrings = {
'collections.picker.hint': '从你的收藏中选择一个地点',
'collections.picker.use': '使用',
// Export / import a list as a file (#2198)
'collections.file.export': '导出',
'collections.file.exportTitle': '将此列表下载为文件',
'collections.file.importButton': '从文件导入列表',
'collections.file.importTitle': '导入列表',
'collections.file.choose': '选择列表文件',
'collections.file.confirm': '导入',
'collections.file.change': '更换',
'collections.file.labelCount': '{count} 个标签',
'collections.file.hint': '这些地点会成为你自己的新列表。评分、成员和上传的照片不会一起导入。',
'collections.file.done': '已导入 {count} 个地点',
'collections.file.doneSkipped': '已导入 {count} 个地点,跳过 {skipped} 个',
'collections.file.errorTooLarge': '该文件太大,不像是一个列表。',
'collections.file.errorUnreadable': '无法读取该文件。',
'collections.file.errorNotACollection': '这不是 TREK 列表文件。',
'collections.share.title': '共享列表',
'collections.share.titleNamed': '共享“{name}”',
'collections.share.button': '共享',
+1
View File
@@ -41,6 +41,7 @@ export * from './place/place-match';
export * from './roadtrip/roadtrip.schema';
export * from './place/track-colors';
export * from './collection/collection.schema';
export * from './collection/collection-file.schema';
export * from './trip/trip.schema';
export * from './trip-invite/trip-invite.schema';
export * from './collab/collab.schema';