Files
TREK/shared/src/i18n/en/externalNotifications.ts
T
Maurice ec8509f2de feat(collections): backend for the Overall Places addon (#1081)
Adds the Collections addon backend: a server-wide-per-user library of saved
places, independent of any trip, with multiple named lists, an idea/want/visited
status, and Vacay-style fusion invitations to share a list with other users.

- Data: collection / collection_members / collection_places / collection_place_tags
  tables (+ migration and baseline schema). Saved places carry the owner plus a
  nullable saved_by so a member deleting their account can't drop shared content.
- Service: list + place CRUD with owner-or-accepted-member visibility, dedup,
  status, save-from-trip and copy-to-trip (reusing the trip copy column list),
  and the full fusion-invitation state machine mirrored from vacay (send / accept
  / decline / cancel / leave) with a websocket broadcast and an invite
  notification. Deleting a list snapshots its members and notifies them.
- NestJS module + addon guard (404 before auth), registered in the app module.
- Widens the place photo cache reference check to count collection places so the
  nightly sweep no longer evicts photos a saved place still uses.
- collection_invite notification wired across all 22 locales.
2026-07-01 18:02:44 +02:00

67 lines
2.4 KiB
TypeScript

import type { NotificationLocale } from '../externalNotifications/types';
const en: NotificationLocale = {
email: {
footer: 'You received this because you have notifications enabled in TREK.',
manage: 'Manage preferences in Settings',
madeWith: 'Made with',
openTrek: 'Open TREK',
},
events: {
trip_invite: (p) => ({
title: `Trip invite: "${p.trip}"`,
body: `${p.actor} invited ${p.invitee || 'a member'} to the trip "${p.trip}".`,
}),
booking_change: (p) => ({
title: `New booking: ${p.booking}`,
body: `${p.actor} added a new ${p.type} "${p.booking}" to "${p.trip}".`,
}),
trip_reminder: (p) => ({
title: `Trip reminder: ${p.trip}`,
body: `Your trip "${p.trip}" is coming up soon!`,
}),
todo_due: (p) => ({
title: `To-do due: ${p.todo}`,
body: `"${p.todo}" in "${p.trip}" is due on ${p.due}.`,
}),
vacay_invite: (p) => ({
title: 'Vacay Fusion Invite',
body: `${p.actor} invited you to fuse vacation plans. Open TREK to accept or decline.`,
}),
collection_invite: (p) => ({
title: 'Collection invite',
body: `${p.actor} invited you to share a collection. Open TREK to accept or decline.`,
}),
photos_shared: (p) => ({
title: `${p.count} photos shared`,
body: `${p.actor} shared ${p.count} photo(s) in "${p.trip}".`,
}),
collab_message: (p) => ({
title: `New message in "${p.trip}"`,
body: `${p.actor}: ${p.preview}`,
}),
packing_tagged: (p) => ({
title: `Packing: ${p.category}`,
body: `${p.actor} assigned you to the "${p.category}" packing category in "${p.trip}".`,
}),
version_available: (p) => ({
title: 'New TREK version available',
body: `TREK ${p.version} is now available. Visit the admin panel to update.`,
}),
synology_session_cleared: () => ({
title: 'Synology session cleared',
body: 'Your Synology account or URL changed. You have been logged out of Synology Photos.',
}),
},
passwordReset: {
subject: 'Reset your password',
greeting: 'Hi',
body: 'We received a request to reset the password for your TREK account. Click the button below to set a new password.',
ctaIntro: 'Reset password',
expiry: 'This link expires in 60 minutes.',
ignore: "If you didn't request this, you can safely ignore this email — your password won't change.",
},
};
export default en;