diff --git a/client/src/components/Planner/usePlaceSearch.ts b/client/src/components/Planner/usePlaceSearch.ts index bb66620fa..a846bc8a5 100644 --- a/client/src/components/Planner/usePlaceSearch.ts +++ b/client/src/components/Planner/usePlaceSearch.ts @@ -60,6 +60,8 @@ export interface PlaceSearchOptions { * search ends the billing session, and a pick clears the typed-ahead list too. */ variant: 'dialog' | 'sheet'; + /** What the field starts with, such as a map link shared to the app (#2582). */ + initialQuery?: string; /** Where the trip is happening: autocomplete is biased to the box, the full search to its centre. */ locationBias: LocationBiasBox | undefined; t: ReturnType['t']; @@ -101,6 +103,7 @@ export function usePlaceSearch({ onMapLink, onCoordinates, onResolvingChange, + initialQuery, }: PlaceSearchOptions) { const sheet = variant === 'sheet'; // Place names in the language the user picked for them, the app's otherwise (#1799). @@ -110,7 +113,7 @@ export function usePlaceSearch({ // The same hint autocomplete gets, as a point instead of a box. const biasPoint = pointFromBox(locationBias); - const [query, setQuery] = useState(''); + const [query, setQuery] = useState(initialQuery ?? ''); const [results, setResults] = useState([]); /** What answered the last full search. Only a fallback: a merged list carries the source per place. */ const [searchSource, setSearchSource] = useState(''); diff --git a/client/src/mobile/components/NativeImportSheet.test.tsx b/client/src/mobile/components/NativeImportSheet.test.tsx index 0d0b7c454..e8760cc38 100644 --- a/client/src/mobile/components/NativeImportSheet.test.tsx +++ b/client/src/mobile/components/NativeImportSheet.test.tsx @@ -22,7 +22,7 @@ beforeEach(() => { // A second spyOn returns the first spy with its calls; start every test clean. vi.restoreAllMocks(); navigate.mockReset(); - useSharedImportStore.setState({ file: null, tripId: null, link: null }); + useSharedImportStore.setState({ file: null, tripId: null, link: null, placeLink: null }); useAddonStore.setState({ addons: [{ id: 'collab', enabled: true }] as never, loaded: true }); useTripAddonsStore.setState({ trips: {} }); // Every trip follows the instance switch unless a test says otherwise; answered at once, so no read outlives its test. @@ -217,6 +217,35 @@ describe('NativeImportSheet', () => { expect(saveSharedLink).toHaveBeenCalledTimes(1); }); + it('offers a shared map link as a place first, and hands it to the trip picked (#2582)', async () => { + const maps = { + url: 'https://www.google.com/maps/place/Time+Out+Market', + title: 'Time Out Market', + presetTripId: null, + }; + render(); + act(() => useSharedImportStore.getState().setFile(page(), maps)); + const choices = await screen.findAllByRole('button', { + name: /Add it as a place|Save to the trip's links|Read a booking/, + }); + expect(choices[0]).toHaveAccessibleName(/Add it as a place/); + + fireEvent.click(choices[0]); + expect(screen.getByText('Add the place to which trip?')).toBeInTheDocument(); + fireEvent.click(await screen.findByRole('button', { name: /Japan/ })); + expect(useSharedImportStore.getState().placeLink).toEqual({ tripId: 2, url: maps.url }); + expect(useSharedImportStore.getState().file).toBeNull(); + expect(navigate).toHaveBeenCalledWith('/trips/2'); + expect(saveSharedLink).not.toHaveBeenCalled(); + }); + + it('offers no place for a link that is not a map', async () => { + render(); + act(() => useSharedImportStore.getState().setFile(page(), link())); + await screen.findByText('What should TREK do with this link?'); + expect(screen.queryByRole('button', { name: /Add it as a place/ })).not.toBeInTheDocument(); + }); + it('stays closed with nothing shared', () => { render(); expect(screen.queryByRole('dialog')).not.toBeInTheDocument(); diff --git a/client/src/mobile/components/NativeImportSheet.tsx b/client/src/mobile/components/NativeImportSheet.tsx index 16e3c0db0..9f01fd28d 100644 --- a/client/src/mobile/components/NativeImportSheet.tsx +++ b/client/src/mobile/components/NativeImportSheet.tsx @@ -7,11 +7,14 @@ * (Collaboration, Links), or read as a booking. A bare link, whose page the phone * could not read, can only be kept; with Collaboration off, a page can only be read. * Collaboration counts per trip: a link goes only to a trip that has it on. + * A map link (Google Maps, Amap) can also become a place of the + * trip (#2582): the trip's new place sheet opens and looks the link up. */ -import { ChevronRight, FileText, Link2, ScanText } from 'lucide-react'; +import { ChevronRight, FileText, Link2, MapPin, ScanText } from 'lucide-react'; import React, { useEffect, useEffectEvent, useRef, useState } from 'react'; import { useLocation, useNavigate } from 'react-router'; import { useShallow } from 'zustand/react/shallow'; +import { isMapUrl } from '../../components/Planner/PlaceFormModal.helpers'; import { useToast } from '../../components/shared/Toast'; import { useTranslation } from '../../i18n'; import { saveSharedLink, useSharedImportStore, type SharedLink } from '../../native/sharedFiles'; @@ -31,11 +34,15 @@ interface TripRow { end_date?: string | null; } -type LinkChoice = 'link' | 'booking'; +type LinkChoice = 'link' | 'booking' | 'place'; -/** What to offer for a shared link: the links when Collaboration is on, the import when there is a page to read. */ -function linkChoicesOf(file: File, collabOn: boolean): LinkChoice[] { +/** + * What to offer for a shared link: a place first when it points at a map, the links + * when Collaboration is on, the import when there is a page to read. + */ +function linkChoicesOf(file: File, collabOn: boolean, url: string): LinkChoice[] { const choices: LinkChoice[] = []; + if (isMapUrl(url)) choices.push('place'); if (collabOn) choices.push('link'); if (file.type !== 'text/uri-list') choices.push('booking'); return choices; @@ -54,19 +61,22 @@ interface StageInput { /** Where the sheet stands for the shared item: what it asks, and what a tap on a trip does. */ function stageOf({ file, link, collabOn, picked, presetFailed, settled }: StageInput) { - if (!file || !link) return { choice: 'booking' as LinkChoice | null, asking: false, nowhere: false, showTrips: true }; - if (!settled) return { choice: null, asking: false, nowhere: false, showTrips: false }; - const choices = linkChoicesOf(file, collabOn); + const none: LinkChoice[] = []; + if (!file || !link) + return { choice: 'booking' as LinkChoice | null, asking: false, nowhere: false, choices: none, showTrips: true }; + if (!settled) return { choice: null, asking: false, nowhere: false, choices: none, showTrips: false }; + const choices = linkChoicesOf(file, collabOn, link.url); const choice = picked ?? (choices.length === 1 ? choices[0] : null); const asking = choice == null && choices.length > 1; const nowhere = choices.length === 0; // While the share sheet's trip takes the link there is nothing to choose. const presetTakes = link.presetTripId != null && choice === 'link' && !presetFailed; - return { choice, asking, nowhere, showTrips: !asking && !nowhere && !presetTakes }; + return { choice, asking, nowhere, choices, showTrips: !asking && !nowhere && !presetTakes }; } function sheetTitle(t: (key: string) => string, asking: boolean, choice: LinkChoice | null): string { if (asking) return t('native.share.linkTitle'); + if (choice === 'place') return t('native.share.placeTrip'); return choice === 'link' ? t('native.share.linkTrip') : t('native.share.title'); } @@ -151,6 +161,7 @@ export default function NativeImportSheet(): React.ReactElement | null { const tripId = useSharedImportStore((s) => s.tripId); const link = useSharedImportStore((s) => s.link); const chooseTrip = useSharedImportStore((s) => s.chooseTrip); + const choosePlaceTrip = useSharedImportStore((s) => s.choosePlaceTrip); const setFile = useSharedImportStore((s) => s.setFile); const instanceCollab = useAddonStore((s) => s.isEnabled('collab')); const open = !!file && tripId == null; @@ -164,7 +175,7 @@ export default function NativeImportSheet(): React.ReactElement | null { // The save in flight, kept off the state: it guards a second tap, it is not shown. const savingRef = useRef(null); const picked = pick && pick.file === file ? pick.choice : null; - const { choice, asking, nowhere, showTrips } = stageOf({ + const { choice, asking, nowhere, choices, showTrips } = stageOf({ file, link, collabOn, @@ -198,17 +209,28 @@ export default function NativeImportSheet(): React.ReactElement | null { ); }; + // The trip's new place sheet takes the map link from here (MTripShell, MPlaceEditSheet). + const addPlace = (id: number) => { + choosePlaceTrip(id); + void navigate(`/trips/${id}`); + }; + // The trip the share sheet picked, used as soon as it is clear what the link is for. const preset = link?.presetTripId ?? null; const applyPreset = useEffectEvent((id: number, use: LinkChoice) => { if (use === 'booking') chooseTrip(id); + else if (use === 'place') addPlace(id); else if (failedFile !== file) saveLink(id); }); useEffect(() => { if (preset != null && choice != null && file) applyPreset(preset, choice); }, [preset, choice, file]); - const pickTrip = (id: number) => (choice === 'link' ? saveLink(id) : chooseTrip(id)); + const pickTrip = (id: number) => { + if (choice === 'link') saveLink(id); + else if (choice === 'place') addPlace(id); + else chooseTrip(id); + }; return ( setFile(null)} variant="bottom" ariaLabel={t('native.share.title')}> @@ -222,7 +244,7 @@ export default function NativeImportSheet(): React.ReactElement | null { closeLabel={t('common.close')} /> - {asking && file && setPick({ file, choice: use })} />} + {asking && file && setPick({ file, choice: use })} />} {nowhere && (

{t('native.share.linkUnsupported')} @@ -234,22 +256,40 @@ export default function NativeImportSheet(): React.ReactElement | null { ); } -function LinkQuestion({ onPick }: { onPick: (choice: LinkChoice) => void }): React.ReactElement { +function LinkQuestion({ + choices, + onPick, +}: { + choices: LinkChoice[]; + onPick: (choice: LinkChoice) => void; +}): React.ReactElement { const { t } = useTranslation(); return (

- } - label={t('native.share.saveLink')} - hint={t('native.share.saveLinkHint')} - onClick={() => onPick('link')} - /> - } - label={t('native.share.readBooking')} - hint={t('native.share.readBookingHint')} - onClick={() => onPick('booking')} - /> + {choices.includes('place') && ( + } + label={t('native.share.addPlace')} + hint={t('native.share.addPlaceHint')} + onClick={() => onPick('place')} + /> + )} + {choices.includes('link') && ( + } + label={t('native.share.saveLink')} + hint={t('native.share.saveLinkHint')} + onClick={() => onPick('link')} + /> + )} + {choices.includes('booking') && ( + } + label={t('native.share.readBooking')} + hint={t('native.share.readBookingHint')} + onClick={() => onPick('booking')} + /> + )}
); } diff --git a/client/src/mobile/screens/trip/MTripShell.tsx b/client/src/mobile/screens/trip/MTripShell.tsx index 24562ef02..a6d82bfd7 100644 --- a/client/src/mobile/screens/trip/MTripShell.tsx +++ b/client/src/mobile/screens/trip/MTripShell.tsx @@ -324,6 +324,17 @@ export default function MTripShell({ setBookingImportKind('bookings') setShowBookingImport(true) }, [sharedTripId, tripId, setBookingImportKind, setShowBookingImport]) + // A map link shared to TREK and this trip picked for it (#2582): the new place + // sheet opens, and its search looks the link up (MPlaceEditSheet). + const sharedPlaceTripId = useSharedImportStore(s => s.placeLink?.tripId ?? null) + const { setEditingPlace, setEditingAssignmentId, setPrefillCoords, setShowPlaceForm } = planner + useEffect(() => { + if (sharedPlaceTripId == null || sharedPlaceTripId !== Number(tripId)) return + setEditingPlace(null) + setEditingAssignmentId(null) + setPrefillCoords(null) + setShowPlaceForm(true) + }, [sharedPlaceTripId, tripId, setEditingPlace, setEditingAssignmentId, setPrefillCoords, setShowPlaceForm]) // The day strip says when it runs on past an edge (a long trip, a narrow pane). const dayFade = useEdgeFade(dayRail) const dayPill = useActivePill(dayRail, '[aria-current="true"]', `${railDayId}:${days.map(d => d.id).join(',')}:${language}`) diff --git a/client/src/mobile/screens/trip/sheets/MPlaceEditSheet.tsx b/client/src/mobile/screens/trip/sheets/MPlaceEditSheet.tsx index 97dad1b99..63573f086 100644 --- a/client/src/mobile/screens/trip/sheets/MPlaceEditSheet.tsx +++ b/client/src/mobile/screens/trip/sheets/MPlaceEditSheet.tsx @@ -34,6 +34,7 @@ import { usePlaceImageField } from '../../../../components/Planner/usePlaceImage import { useTranslation } from '../../../../i18n' import { useAuthStore } from '../../../../store/authStore' import { useSettingsStore } from '../../../../store/settingsStore' +import { useSharedImportStore } from '../../../../native/sharedFiles' import type { Assignment, AssignmentsMap, Place } from '../../../../types' import type { TripPlanner } from '../MTripShell' import { useLocationBias } from '../../../../hooks/useLocationBias' @@ -103,6 +104,9 @@ export default function MPlaceEditSheet({ planner, onOpenExpense }: MPlaceEditSh const tagField = usePlaceTags({ tripId: planner.tripId, place: sheetPlace, tags: form.tags, setForm, t, toast }) const placesEnrichEnabled = useAuthStore(s => s.placesEnrichEnabled) + // A map link shared to TREK for this trip (#2582): a new place starts from it. + const sharedPlaceUrl = useSharedImportStore(s => (s.placeLink?.tripId === planner.tripId ? s.placeLink.url : null)) + const clearSharedPlace = useSharedImportStore(s => s.clearPlaceLink) const { language, locale } = useTranslation() const timeFormat = useSettingsStore(s => s.settings.time_format) || '24h' @@ -266,6 +270,8 @@ export default function MPlaceEditSheet({ planner, onOpenExpense }: MPlaceEditSh onPick={applyPick} onSuggestionName={name => setForm(prev => ({ ...prev, name }))} onResolvingChange={setResolvingPick} + initialQuery={!sheetPlace && sharedPlaceUrl ? sharedPlaceUrl : undefined} + onInitialQueryRun={clearSharedPlace} /> {placesEnrichEnabled && ( diff --git a/client/src/mobile/screens/trip/sheets/PlPlaceSearch.tsx b/client/src/mobile/screens/trip/sheets/PlPlaceSearch.tsx index 2a4637ad0..a16248bc0 100644 --- a/client/src/mobile/screens/trip/sheets/PlPlaceSearch.tsx +++ b/client/src/mobile/screens/trip/sheets/PlPlaceSearch.tsx @@ -1,4 +1,5 @@ import { Loader2, RotateCcw, Search } from 'lucide-react' +import { useEffect, useEffectEvent } from 'react' import { offersGoogleRetry } from '../../../../utils/placeSource' import { usePlaceSearch, type MapsPlace } from '../../../../components/Planner/usePlaceSearch' import { FIELD_CLS } from './PlSheetChrome' @@ -48,6 +49,10 @@ interface PlPlaceSearchProps { onSuggestionName: (name: string) => void /** True while a suggestion's details are being resolved (name spinner). */ onResolvingChange?: (resolving: boolean) => void + /** A query the field starts with and runs once, such as a shared map link (#2582). */ + initialQuery?: string + /** The starting query was sent, so whoever held it can let it go. */ + onInitialQueryRun?: () => void } function placeToPick(place: MapsPlace): PlSearchPick { @@ -73,7 +78,7 @@ function placeToPick(place: MapsPlace): PlSearchPick { * detection — the mobile counterpart of PlaceFormModal's search block, on the * same search logic (usePlaceSearch). */ -export default function PlPlaceSearch({ planner, locationBias, onPick, onSuggestionName, onResolvingChange }: PlPlaceSearchProps) { +export default function PlPlaceSearch({ planner, locationBias, onPick, onSuggestionName, onResolvingChange, initialQuery, onInitialQueryRun }: PlPlaceSearchProps) { const { t, toast } = planner const { query, setQuery, results, suggestions, setSuggestions, acSource, searchSource, searching, googleAnswers, @@ -94,8 +99,19 @@ export default function PlPlaceSearch({ planner, locationBias, onPick, onSuggest }), onCoordinates: (lat, lng) => onPick({ lat, lng }), onResolvingChange, + initialQuery, }) + // A map link shared to the app (#2582) is looked up as soon as the sheet opens, + // as if it had been pasted and searched. + const runInitial = useEffectEvent(() => { + void handleSearch() + onInitialQueryRun?.() + }) + useEffect(() => { + if (initialQuery) runInitial() + }, [initialQuery]) + return (
diff --git a/client/src/native/sharedFiles.ts b/client/src/native/sharedFiles.ts index 4e5faf701..6279edda1 100644 --- a/client/src/native/sharedFiles.ts +++ b/client/src/native/sharedFiles.ts @@ -22,13 +22,25 @@ export interface SharedLink { presetTripId: number | null; } +/** A shared map link on its way to a trip's new place (#2582). */ +export interface SharedPlaceLink { + tripId: number; + url: string; +} + interface SharedImportState { file: File | null; /** The trip whose booking import takes the file; the planner of that trip takes it from here. */ tripId: number | null; link: SharedLink | null; + /** A map link picked to become a place: the trip's new place sheet looks it up. */ + placeLink: SharedPlaceLink | null; setFile: (file: File | null, link?: SharedLink | null) => void; chooseTrip: (tripId: number) => void; + /** The shared link goes to this trip as a place; the sheet's queue is done with it. */ + choosePlaceTrip: (tripId: number) => void; + /** The trip's place sheet took the link up. */ + clearPlaceLink: () => void; /** The booking import took the file: the queue is empty again. */ take: () => File | null; } @@ -37,8 +49,14 @@ export const useSharedImportStore = create((set, get) => ({ file: null, tripId: null, link: null, + placeLink: null, setFile: (file, link = null) => set({ file, tripId: null, link: file ? link : null }), chooseTrip: (tripId) => set({ tripId }), + choosePlaceTrip: (tripId) => { + const { link } = get(); + set({ file: null, tripId: null, link: null, placeLink: link ? { tripId, url: link.url } : null }); + }, + clearPlaceLink: () => set({ placeLink: null }), take: () => { const { file } = get(); set({ file: null, tripId: null, link: null }); diff --git a/shared/src/i18n/ar/native.ts b/shared/src/i18n/ar/native.ts index b9972d3cc..7eb79485b 100644 --- a/shared/src/i18n/ar/native.ts +++ b/shared/src/i18n/ar/native.ts @@ -106,6 +106,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'يجده الجميع في الرحلة ضمن الروابط', 'native.share.readBooking': 'قراءة حجز منه', 'native.share.readBookingHint': 'لصفحة تأكيد', + 'native.share.addPlace': 'إضافته كمكان', + 'native.share.addPlaceHint': 'من رابط الخريطة إلى أماكن رحلة', + 'native.share.placeTrip': 'إلى أي رحلة تريد إضافة المكان؟', 'native.share.linkTrip': 'في أي رحلة يُحفظ الرابط؟', 'native.share.linkSaved': 'تم حفظ الرابط', 'native.share.linkUnsupported': 'فعّل Collab لحفظ الروابط في رحلة.', diff --git a/shared/src/i18n/az/native.ts b/shared/src/i18n/az/native.ts index acd1adddb..f2ce6842c 100644 --- a/shared/src/i18n/az/native.ts +++ b/shared/src/i18n/az/native.ts @@ -110,6 +110,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'Səyahətdəki hər kəs onu Keçidlər bölməsində tapır', 'native.share.readBooking': 'Ondan rezervasiya oxu', 'native.share.readBookingHint': 'Təsdiq səhifəsi üçün', + 'native.share.addPlace': 'Məkan kimi əlavə et', + 'native.share.addPlaceHint': 'Xəritə keçidindən, səfərin məkanlarına', + 'native.share.placeTrip': 'Məkanı hansı səfərə əlavə edək?', 'native.share.linkTrip': 'Keçid hansı səyahətə yadda saxlanılsın?', 'native.share.linkSaved': 'Keçid yadda saxlanıldı', 'native.share.linkUnsupported': 'Səyahətdə keçidləri saxlamaq üçün Collab funksiyasını aç.', diff --git a/shared/src/i18n/br/native.ts b/shared/src/i18n/br/native.ts index 4e7b86d26..22b46bce3 100644 --- a/shared/src/i18n/br/native.ts +++ b/shared/src/i18n/br/native.ts @@ -111,6 +111,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'Todos na viagem o encontram em Links', 'native.share.readBooking': 'Ler uma reserva dele', 'native.share.readBookingHint': 'Para uma página de confirmação', + 'native.share.addPlace': 'Adicionar como lugar', + 'native.share.addPlaceHint': 'A partir do link do mapa, aos lugares de uma viagem', + 'native.share.placeTrip': 'Adicionar o lugar a qual viagem?', 'native.share.linkTrip': 'Salvar o link em qual viagem?', 'native.share.linkSaved': 'Link salvo', 'native.share.linkUnsupported': 'Ative o Collab para guardar links em uma viagem.', diff --git a/shared/src/i18n/ca/native.ts b/shared/src/i18n/ca/native.ts index 813064206..cf7f07e7c 100644 --- a/shared/src/i18n/ca/native.ts +++ b/shared/src/i18n/ca/native.ts @@ -111,6 +111,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'Tothom al viatge el troba a Enllaços', 'native.share.readBooking': 'Llegeix-ne una reserva', 'native.share.readBookingHint': 'Per a una pàgina de confirmació', + 'native.share.addPlace': 'Afegeix-lo com a lloc', + 'native.share.addPlaceHint': "A partir de l'enllaç del mapa, als llocs d'un viatge", + 'native.share.placeTrip': 'A quin viatge vols afegir el lloc?', 'native.share.linkTrip': "A quin viatge desar l'enllaç?", 'native.share.linkSaved': 'Enllaç desat', 'native.share.linkUnsupported': 'Activa Collab per guardar enllaços en un viatge.', diff --git a/shared/src/i18n/cs/native.ts b/shared/src/i18n/cs/native.ts index fca141378..3725911bf 100644 --- a/shared/src/i18n/cs/native.ts +++ b/shared/src/i18n/cs/native.ts @@ -107,6 +107,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'Všichni v cestě ho najdou v Odkazech', 'native.share.readBooking': 'Přečíst z něj rezervaci', 'native.share.readBookingHint': 'Pro potvrzovací stránku', + 'native.share.addPlace': 'Přidat jako místo', + 'native.share.addPlaceHint': 'Z odkazu na mapu do míst výletu', + 'native.share.placeTrip': 'Do kterého výletu místo přidat?', 'native.share.linkTrip': 'Do které cesty odkaz uložit?', 'native.share.linkSaved': 'Odkaz uložen', 'native.share.linkUnsupported': 'Zapni Collab, abys mohl ukládat odkazy do cesty.', diff --git a/shared/src/i18n/de/native.ts b/shared/src/i18n/de/native.ts index d4489068d..a4d18264d 100644 --- a/shared/src/i18n/de/native.ts +++ b/shared/src/i18n/de/native.ts @@ -114,6 +114,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'Alle im Trip finden ihn unter Links', 'native.share.readBooking': 'Buchung daraus lesen', 'native.share.readBookingHint': 'Für eine Bestätigungsseite', + 'native.share.addPlace': 'Als Ort hinzufügen', + 'native.share.addPlaceHint': 'Aus dem Kartenlink, zu den Orten eines Trips', + 'native.share.placeTrip': 'Zu welchem Trip den Ort hinzufügen?', 'native.share.linkTrip': 'In welchem Trip den Link speichern?', 'native.share.linkSaved': 'Link gespeichert', 'native.share.linkUnsupported': 'Schalte Collab ein, um Links in einem Trip zu sammeln.', diff --git a/shared/src/i18n/en/native.ts b/shared/src/i18n/en/native.ts index eb4d997f7..f13de27ff 100644 --- a/shared/src/i18n/en/native.ts +++ b/shared/src/i18n/en/native.ts @@ -110,6 +110,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'Everyone on the trip finds it under Links', 'native.share.readBooking': 'Read a booking from it', 'native.share.readBookingHint': 'For a confirmation page', + 'native.share.addPlace': 'Add it as a place', + 'native.share.addPlaceHint': "Found from the map link, into a trip's places", + 'native.share.placeTrip': 'Add the place to which trip?', 'native.share.linkTrip': 'Save the link to which trip?', 'native.share.linkSaved': 'Link saved', 'native.share.linkUnsupported': 'Turn on Collab to keep links in a trip.', diff --git a/shared/src/i18n/es/native.ts b/shared/src/i18n/es/native.ts index ea38b5e29..3175c9603 100644 --- a/shared/src/i18n/es/native.ts +++ b/shared/src/i18n/es/native.ts @@ -110,6 +110,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'Todos en el viaje lo encuentran en Enlaces', 'native.share.readBooking': 'Leer una reserva de él', 'native.share.readBookingHint': 'Para una página de confirmación', + 'native.share.addPlace': 'Añadirlo como lugar', + 'native.share.addPlaceHint': 'Desde el enlace del mapa, a los lugares de un viaje', + 'native.share.placeTrip': '¿A qué viaje añadir el lugar?', 'native.share.linkTrip': '¿En qué viaje guardar el enlace?', 'native.share.linkSaved': 'Enlace guardado', 'native.share.linkUnsupported': 'Activa Collab para guardar enlaces en un viaje.', diff --git a/shared/src/i18n/et/native.ts b/shared/src/i18n/et/native.ts index 910a7fb6d..7d2999361 100644 --- a/shared/src/i18n/et/native.ts +++ b/shared/src/i18n/et/native.ts @@ -109,6 +109,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'Kõik reisil olijad leiavad selle jaotisest Lingid', 'native.share.readBooking': 'Loe sellest broneering', 'native.share.readBookingHint': 'Kinnituslehe jaoks', + 'native.share.addPlace': 'Lisa kohana', + 'native.share.addPlaceHint': 'Kaardilingist reisi kohtade hulka', + 'native.share.placeTrip': 'Millisesse reisi koht lisada?', 'native.share.linkTrip': 'Millisesse reisi link salvestada?', 'native.share.linkSaved': 'Link salvestatud', 'native.share.linkUnsupported': 'Lülita Collab sisse, et reisis linke hoida.', diff --git a/shared/src/i18n/fr/native.ts b/shared/src/i18n/fr/native.ts index 5e7c1e733..7ae377c04 100644 --- a/shared/src/i18n/fr/native.ts +++ b/shared/src/i18n/fr/native.ts @@ -112,6 +112,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'Tous les participants le trouvent sous Liens', 'native.share.readBooking': 'En extraire une réservation', 'native.share.readBookingHint': 'Pour une page de confirmation', + 'native.share.addPlace': "L'ajouter comme lieu", + 'native.share.addPlaceHint': "Depuis le lien de carte, dans les lieux d'un voyage", + 'native.share.placeTrip': 'Ajouter le lieu à quel voyage ?', 'native.share.linkTrip': 'Enregistrer le lien dans quel voyage ?', 'native.share.linkSaved': 'Lien enregistré', 'native.share.linkUnsupported': 'Activez Collab pour garder des liens dans un voyage.', diff --git a/shared/src/i18n/gr/native.ts b/shared/src/i18n/gr/native.ts index 79b1468e5..7078f99b7 100644 --- a/shared/src/i18n/gr/native.ts +++ b/shared/src/i18n/gr/native.ts @@ -113,6 +113,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'Όλοι στο ταξίδι τον βρίσκουν στους Συνδέσμους', 'native.share.readBooking': 'Ανάγνωση κράτησης από αυτόν', 'native.share.readBookingHint': 'Για σελίδα επιβεβαίωσης', + 'native.share.addPlace': 'Προσθήκη ως μέρος', + 'native.share.addPlaceHint': 'Από τον σύνδεσμο χάρτη, στα μέρη ενός ταξιδιού', + 'native.share.placeTrip': 'Σε ποιο ταξίδι να προστεθεί το μέρος;', 'native.share.linkTrip': 'Σε ποιο ταξίδι να αποθηκευτεί ο σύνδεσμος;', 'native.share.linkSaved': 'Ο σύνδεσμος αποθηκεύτηκε', 'native.share.linkUnsupported': 'Ενεργοποίησε το Collab για να κρατάς συνδέσμους σε ένα ταξίδι.', diff --git a/shared/src/i18n/he/native.ts b/shared/src/i18n/he/native.ts index 28dbe18b1..902e2abf3 100644 --- a/shared/src/i18n/he/native.ts +++ b/shared/src/i18n/he/native.ts @@ -106,6 +106,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'כל המשתתפים בטיול ימצאו אותו תחת קישורים', 'native.share.readBooking': 'קריאת הזמנה ממנו', 'native.share.readBookingHint': 'לדף אישור', + 'native.share.addPlace': 'להוסיף כמקום', + 'native.share.addPlaceHint': 'מקישור המפה אל המקומות של טיול', + 'native.share.placeTrip': 'לאיזה טיול להוסיף את המקום?', 'native.share.linkTrip': 'לאיזה טיול לשמור את הקישור?', 'native.share.linkSaved': 'הקישור נשמר', 'native.share.linkUnsupported': 'הפעל את Collab כדי לשמור קישורים בטיול.', diff --git a/shared/src/i18n/hu/native.ts b/shared/src/i18n/hu/native.ts index 2ca4880a0..9b9f93f9c 100644 --- a/shared/src/i18n/hu/native.ts +++ b/shared/src/i18n/hu/native.ts @@ -112,6 +112,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'Az utazás minden tagja megtalálja a Linkek között', 'native.share.readBooking': 'Foglalás kiolvasása belőle', 'native.share.readBookingHint': 'Visszaigazoló oldalhoz', + 'native.share.addPlace': 'Hozzáadás helyként', + 'native.share.addPlaceHint': 'A térképlinkből egy utazás helyei közé', + 'native.share.placeTrip': 'Melyik utazáshoz adjuk a helyet?', 'native.share.linkTrip': 'Melyik utazásba mentsem a linket?', 'native.share.linkSaved': 'Link mentve', 'native.share.linkUnsupported': 'Kapcsold be a Collabot, hogy linkeket tarts egy utazásban.', diff --git a/shared/src/i18n/id/native.ts b/shared/src/i18n/id/native.ts index 30642fb92..b69430e3c 100644 --- a/shared/src/i18n/id/native.ts +++ b/shared/src/i18n/id/native.ts @@ -112,6 +112,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'Semua orang di perjalanan menemukannya di Tautan', 'native.share.readBooking': 'Baca pemesanan darinya', 'native.share.readBookingHint': 'Untuk halaman konfirmasi', + 'native.share.addPlace': 'Tambahkan sebagai tempat', + 'native.share.addPlaceHint': 'Dari tautan peta, ke tempat-tempat sebuah perjalanan', + 'native.share.placeTrip': 'Tambahkan tempat ke perjalanan mana?', 'native.share.linkTrip': 'Simpan tautan ke perjalanan mana?', 'native.share.linkSaved': 'Tautan disimpan', 'native.share.linkUnsupported': 'Aktifkan Collab untuk menyimpan tautan dalam perjalanan.', diff --git a/shared/src/i18n/it/native.ts b/shared/src/i18n/it/native.ts index 8bcd93e2f..6f97ed30d 100644 --- a/shared/src/i18n/it/native.ts +++ b/shared/src/i18n/it/native.ts @@ -113,6 +113,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'Tutti nel viaggio lo trovano in Link', 'native.share.readBooking': 'Leggi una prenotazione', 'native.share.readBookingHint': 'Per una pagina di conferma', + 'native.share.addPlace': 'Aggiungilo come luogo', + 'native.share.addPlaceHint': 'Dal link della mappa, tra i luoghi di un viaggio', + 'native.share.placeTrip': 'A quale viaggio aggiungere il luogo?', 'native.share.linkTrip': 'In quale viaggio salvare il link?', 'native.share.linkSaved': 'Link salvato', 'native.share.linkUnsupported': 'Attiva Collab per conservare i link in un viaggio.', diff --git a/shared/src/i18n/ja/native.ts b/shared/src/i18n/ja/native.ts index 1c922fe9d..fe0b47c46 100644 --- a/shared/src/i18n/ja/native.ts +++ b/shared/src/i18n/ja/native.ts @@ -110,6 +110,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': '旅行のメンバー全員がリンクで見られます', 'native.share.readBooking': '予約を読み取る', 'native.share.readBookingHint': '確認ページの場合', + 'native.share.addPlace': '場所として追加', + 'native.share.addPlaceHint': '地図のリンクから旅行の場所へ', + 'native.share.placeTrip': 'どの旅行に場所を追加しますか?', 'native.share.linkTrip': 'どの旅行にリンクを保存しますか?', 'native.share.linkSaved': 'リンクを保存しました', 'native.share.linkUnsupported': '旅行にリンクを保存するにはCollabをオンにしてください。', diff --git a/shared/src/i18n/ko/native.ts b/shared/src/i18n/ko/native.ts index 620f9ee86..9bad4a736 100644 --- a/shared/src/i18n/ko/native.ts +++ b/shared/src/i18n/ko/native.ts @@ -106,6 +106,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': '여행의 모든 사람이 링크에서 볼 수 있어요', 'native.share.readBooking': '예약 정보 읽기', 'native.share.readBookingHint': '확인 페이지인 경우', + 'native.share.addPlace': '장소로 추가', + 'native.share.addPlaceHint': '지도 링크에서 여행의 장소로', + 'native.share.placeTrip': '어느 여행에 장소를 추가할까요?', 'native.share.linkTrip': '어느 여행에 링크를 저장할까요?', 'native.share.linkSaved': '링크를 저장했어요', 'native.share.linkUnsupported': '여행에 링크를 보관하려면 Collab을 켜세요.', diff --git a/shared/src/i18n/nl/native.ts b/shared/src/i18n/nl/native.ts index ead04eec1..07ac95149 100644 --- a/shared/src/i18n/nl/native.ts +++ b/shared/src/i18n/nl/native.ts @@ -112,6 +112,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'Iedereen op de reis vindt hem onder Links', 'native.share.readBooking': 'Er een boeking uit lezen', 'native.share.readBookingHint': 'Voor een bevestigingspagina', + 'native.share.addPlace': 'Toevoegen als plaats', + 'native.share.addPlaceHint': 'Vanuit de kaartlink, bij de plaatsen van een reis', + 'native.share.placeTrip': 'Aan welke reis de plaats toevoegen?', 'native.share.linkTrip': 'In welke reis de link opslaan?', 'native.share.linkSaved': 'Link opgeslagen', 'native.share.linkUnsupported': 'Zet Collab aan om links in een reis te bewaren.', diff --git a/shared/src/i18n/pl/native.ts b/shared/src/i18n/pl/native.ts index 2759583e1..96ce7093d 100644 --- a/shared/src/i18n/pl/native.ts +++ b/shared/src/i18n/pl/native.ts @@ -111,6 +111,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'Wszyscy w podróży znajdą go w Linkach', 'native.share.readBooking': 'Odczytaj z niego rezerwację', 'native.share.readBookingHint': 'Dla strony z potwierdzeniem', + 'native.share.addPlace': 'Dodaj jako miejsce', + 'native.share.addPlaceHint': 'Z linku do mapy, do miejsc podróży', + 'native.share.placeTrip': 'Do której podróży dodać miejsce?', 'native.share.linkTrip': 'Do której podróży zapisać link?', 'native.share.linkSaved': 'Link zapisany', 'native.share.linkUnsupported': 'Włącz Collab, aby przechowywać linki w podróży.', diff --git a/shared/src/i18n/ru/native.ts b/shared/src/i18n/ru/native.ts index dfa268ab6..5b6abf792 100644 --- a/shared/src/i18n/ru/native.ts +++ b/shared/src/i18n/ru/native.ts @@ -112,6 +112,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'Все участники поездки найдут её в разделе «Ссылки»', 'native.share.readBooking': 'Прочитать из неё бронирование', 'native.share.readBookingHint': 'Для страницы подтверждения', + 'native.share.addPlace': 'Добавить как место', + 'native.share.addPlaceHint': 'По ссылке на карту, в места поездки', + 'native.share.placeTrip': 'В какую поездку добавить место?', 'native.share.linkTrip': 'В какую поездку сохранить ссылку?', 'native.share.linkSaved': 'Ссылка сохранена', 'native.share.linkUnsupported': 'Включите Collab, чтобы хранить ссылки в поездке.', diff --git a/shared/src/i18n/sk/native.ts b/shared/src/i18n/sk/native.ts index 344d58f3b..98d65360e 100644 --- a/shared/src/i18n/sk/native.ts +++ b/shared/src/i18n/sk/native.ts @@ -108,6 +108,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'Všetci v ceste ho nájdu v Odkazoch', 'native.share.readBooking': 'Prečítať z neho rezerváciu', 'native.share.readBookingHint': 'Pre potvrdzovaciu stránku', + 'native.share.addPlace': 'Pridať ako miesto', + 'native.share.addPlaceHint': 'Z odkazu na mapu do miest výletu', + 'native.share.placeTrip': 'Do ktorého výletu pridať miesto?', 'native.share.linkTrip': 'Do ktorej cesty odkaz uložiť?', 'native.share.linkSaved': 'Odkaz uložený', 'native.share.linkUnsupported': 'Zapni Collab, aby si mohol ukladať odkazy do cesty.', diff --git a/shared/src/i18n/sv/native.ts b/shared/src/i18n/sv/native.ts index 546861721..ae8b09021 100644 --- a/shared/src/i18n/sv/native.ts +++ b/shared/src/i18n/sv/native.ts @@ -109,6 +109,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'Alla på resan hittar den under Länkar', 'native.share.readBooking': 'Läs en bokning ur den', 'native.share.readBookingHint': 'För en bekräftelsesida', + 'native.share.addPlace': 'Lägg till som plats', + 'native.share.addPlaceHint': 'Från kartlänken, bland en resas platser', + 'native.share.placeTrip': 'Till vilken resa ska platsen läggas?', 'native.share.linkTrip': 'Spara länken i vilken resa?', 'native.share.linkSaved': 'Länk sparad', 'native.share.linkUnsupported': 'Slå på Collab för att spara länkar i en resa.', diff --git a/shared/src/i18n/th/native.ts b/shared/src/i18n/th/native.ts index faa295c1f..22f71a37f 100644 --- a/shared/src/i18n/th/native.ts +++ b/shared/src/i18n/th/native.ts @@ -103,6 +103,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'ทุกคนในทริปจะพบได้ในส่วนลิงก์', 'native.share.readBooking': 'อ่านการจองจากลิงก์นี้', 'native.share.readBookingHint': 'สำหรับหน้ายืนยัน', + 'native.share.addPlace': 'เพิ่มเป็นสถานที่', + 'native.share.addPlaceHint': 'จากลิงก์แผนที่ ไปยังสถานที่ของทริป', + 'native.share.placeTrip': 'เพิ่มสถานที่ไปยังทริปไหน', 'native.share.linkTrip': 'บันทึกลิงก์ลงในทริปไหน?', 'native.share.linkSaved': 'บันทึกลิงก์แล้ว', 'native.share.linkUnsupported': 'เปิด Collab เพื่อเก็บลิงก์ในทริป', diff --git a/shared/src/i18n/tr/native.ts b/shared/src/i18n/tr/native.ts index 564520cac..1849622e9 100644 --- a/shared/src/i18n/tr/native.ts +++ b/shared/src/i18n/tr/native.ts @@ -108,6 +108,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'Seyahatteki herkes onu Bağlantılar altında bulur', 'native.share.readBooking': 'Ondan bir rezervasyon oku', 'native.share.readBookingHint': 'Bir onay sayfası için', + 'native.share.addPlace': 'Yer olarak ekle', + 'native.share.addPlaceHint': 'Harita bağlantısından, bir seyahatin yerlerine', + 'native.share.placeTrip': 'Yer hangi seyahate eklensin?', 'native.share.linkTrip': 'Bağlantı hangi seyahate kaydedilsin?', 'native.share.linkSaved': 'Bağlantı kaydedildi', 'native.share.linkUnsupported': 'Bir seyahatte bağlantı tutmak için Collab özelliğini aç.', diff --git a/shared/src/i18n/uk/native.ts b/shared/src/i18n/uk/native.ts index 52b67e318..e89675558 100644 --- a/shared/src/i18n/uk/native.ts +++ b/shared/src/i18n/uk/native.ts @@ -110,6 +110,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'Усі учасники подорожі знайдуть його в розділі «Посилання»', 'native.share.readBooking': 'Прочитати з нього бронювання', 'native.share.readBookingHint': 'Для сторінки підтвердження', + 'native.share.addPlace': 'Додати як місце', + 'native.share.addPlaceHint': 'За посиланням на мапу, до місць подорожі', + 'native.share.placeTrip': 'До якої подорожі додати місце?', 'native.share.linkTrip': 'У яку подорож зберегти посилання?', 'native.share.linkSaved': 'Посилання збережено', 'native.share.linkUnsupported': 'Увімкніть Collab, щоб зберігати посилання в подорожі.', diff --git a/shared/src/i18n/vi/native.ts b/shared/src/i18n/vi/native.ts index 5c29759ae..10c8109ad 100644 --- a/shared/src/i18n/vi/native.ts +++ b/shared/src/i18n/vi/native.ts @@ -110,6 +110,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': 'Mọi người trong chuyến đi đều thấy trong mục Liên kết', 'native.share.readBooking': 'Đọc đặt chỗ từ liên kết', 'native.share.readBookingHint': 'Cho trang xác nhận', + 'native.share.addPlace': 'Thêm làm địa điểm', + 'native.share.addPlaceHint': 'Từ liên kết bản đồ, vào các địa điểm của chuyến đi', + 'native.share.placeTrip': 'Thêm địa điểm vào chuyến đi nào?', 'native.share.linkTrip': 'Lưu liên kết vào chuyến đi nào?', 'native.share.linkSaved': 'Đã lưu liên kết', 'native.share.linkUnsupported': 'Bật Collab để lưu liên kết trong chuyến đi.', diff --git a/shared/src/i18n/zh-TW/native.ts b/shared/src/i18n/zh-TW/native.ts index 6e1e965da..cc6fffa57 100644 --- a/shared/src/i18n/zh-TW/native.ts +++ b/shared/src/i18n/zh-TW/native.ts @@ -103,6 +103,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': '行程中的所有人都能在「連結」中找到', 'native.share.readBooking': '從中讀取預訂', 'native.share.readBookingHint': '適用於確認頁面', + 'native.share.addPlace': '新增為地點', + 'native.share.addPlaceHint': '透過地圖連結,加入行程的地點', + 'native.share.placeTrip': '要將地點新增到哪個行程?', 'native.share.linkTrip': '將連結儲存到哪個行程?', 'native.share.linkSaved': '連結已儲存', 'native.share.linkUnsupported': '開啟 Collab 以在行程中保存連結。', diff --git a/shared/src/i18n/zh/native.ts b/shared/src/i18n/zh/native.ts index f955d0ee0..0fad516f2 100644 --- a/shared/src/i18n/zh/native.ts +++ b/shared/src/i18n/zh/native.ts @@ -102,6 +102,9 @@ const native: TranslationStrings = { 'native.share.saveLinkHint': '行程中的所有人都能在“链接”中找到', 'native.share.readBooking': '从中读取预订', 'native.share.readBookingHint': '适用于确认页面', + 'native.share.addPlace': '添加为地点', + 'native.share.addPlaceHint': '通过地图链接,加入行程的地点', + 'native.share.placeTrip': '将地点添加到哪个行程?', 'native.share.linkTrip': '将链接保存到哪个行程?', 'native.share.linkSaved': '链接已保存', 'native.share.linkUnsupported': '开启 Collab 以在行程中保存链接。',