Files
TREK/shared/src/i18n/de/externalNotifications.ts
T
Maurice bee500880e fix(i18n): every language says one file and five files its own way
Finishes the plural work the previous wip commit started. t() picks a
count string's form by the language's own Intl.PluralRules, and every
locale now spells out the forms its language reaches with whole
numbers, about 160 count strings in all: one, few and many in Russian,
Ukrainian and Polish, one and few in Czech and Slovak, five forms in
Arabic, one in the others, none in Japanese, Korean, Chinese, Thai,
Vietnamese and Indonesian. Each language was translated and then
reviewed on its own. English no longer reads "1 files", "1 updates
available" or "photo(s)".

Count labels shown next to a number now take that number too: the
atlas and admin statistics, the trip cards, journey and shared trip
pills, packing templates, receipts, storage usage, the Studio export
note. A heading that shared its key with a counted label keeps a key of
its own (the boarding pass heading, the Bookings tab), so languages that
put a noun after a number in the singular keep a plural heading. The
plugin hosts chip passed its count through .replace() after t() and
never got a form; three toasts sent the count as text. Mail and push
texts for shared photos and suppressed storage failures pick their form
in code through pluralForm.

A whole number sent as text counts too, which is how in-app
notification params arrive, and the plural rule follows the language of
the strings on screen while another one still loads.

The parity check knows which forms each language needs and refuses
missing and impossible ones. It also reads keys that contain a colon
now: it skipped them, which hid 58 missing plugin permission texts in
Catalan and 35 in Vietnamese, both translated. The client parity test
covers every language of the registry instead of a hand-kept list of 19,
and the placeholder spec lets a form spell its number out only where
its category is that one number. Brazilian Portuguese error screens
were in Breton, and an Arabic dashboard label held Hebrew text.
2026-10-08 00:01:59 +00:00

87 lines
3.6 KiB
TypeScript

import type { NotificationLocale } from '../externalNotifications/types';
import { pluralForm } from '../plural';
const de: NotificationLocale = {
email: {
footer: 'Du erhältst diese E-Mail, weil du Benachrichtigungen in TREK aktiviert hast.',
manage: 'Einstellungen verwalten',
madeWith: 'Made with',
openTrek: 'TREK öffnen',
},
events: {
trip_invite: (p) => ({
title: `Einladung zu "${p.trip}"`,
body: `${p.actor} hat ${p.invitee || 'ein Mitglied'} zur Reise "${p.trip}" eingeladen.`,
}),
booking_change: (p) => ({
title: `Neue Buchung: ${p.booking}`,
body: `${p.actor} hat eine neue Buchung "${p.booking}" (${p.type}) zu "${p.trip}" hinzugefügt.`,
}),
trip_reminder: (p) => ({
title: `Reiseerinnerung: ${p.trip}`,
body: `Deine Reise "${p.trip}" steht bald an!`,
}),
todo_due: (p) => ({
title: `Aufgabe fällig: ${p.todo}`,
body: `"${p.todo}" in "${p.trip}" ist am ${p.due} fällig.`,
}),
vacay_invite: (p) => ({
title: 'Vacay Fusion-Einladung',
body: `${p.actor} hat dich eingeladen, Urlaubspläne zu fusionieren. Öffne TREK um anzunehmen oder abzulehnen.`,
}),
vacay_share: (p) => ({
title: 'Vacay Kalender geteilt',
body: `${p.actor} hat den eigenen Urlaubskalender mit dir geteilt. Öffne TREK um ihn anzusehen.`,
}),
collection_invite: (p) => ({
title: 'Sammlungs-Einladung',
body: `${p.actor} hat dich eingeladen, eine Sammlung zu teilen. Öffne TREK um anzunehmen oder abzulehnen.`,
}),
photos_shared: (p) => ({
title: pluralForm(p.count, 'de', { one: `${p.count} Foto geteilt`, other: `${p.count} Fotos geteilt` }),
body: pluralForm(p.count, 'de', {
one: `${p.actor} hat ${p.count} Foto in "${p.trip}" geteilt.`,
other: `${p.actor} hat ${p.count} Fotos in "${p.trip}" geteilt.`,
}),
}),
collab_message: (p) => ({
title: `Neue Nachricht in "${p.trip}"`,
body: `${p.actor}: ${p.preview}`,
}),
packing_tagged: (p) => ({
title: `Packliste: ${p.category}`,
body: `${p.actor} hat dich der Kategorie "${p.category}" in der Packliste von "${p.trip}" zugewiesen.`,
}),
version_available: (p) => ({
title: 'Neue TREK-Version verfügbar',
body: `TREK ${p.version} ist jetzt verfügbar. Besuche das Admin-Panel zum Aktualisieren.`,
}),
replica_failure: (p) => ({
title: 'Speicher-Replik-Fehler',
body:
`Schreibvorgang auf Replik '${p.backend}' fehlgeschlagen: ${p.op} von ${p.key} — ${p.error}.` +
(p.suppressed !== '0'
? pluralForm(p.suppressed, 'de', {
one: ` Seit der letzten Benachrichtigung wurde ${p.suppressed} weiterer Fehler unterdrückt.`,
other: ` Seit der letzten Benachrichtigung wurden ${p.suppressed} weitere Fehler unterdrückt.`,
})
: ''),
}),
synology_session_cleared: () => ({
title: 'Synology-Sitzung beendet',
body: 'Dein Synology-Konto oder die URL hat sich geändert. Du wurdest von Synology Photos abgemeldet.',
}),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
subject: 'Passwort zurücksetzen',
greeting: 'Hallo',
body: 'Wir haben eine Anfrage erhalten, das Passwort für dein TREK-Konto zurückzusetzen. Klicke auf den Button unten, um ein neues Passwort festzulegen.',
ctaIntro: 'Passwort zurücksetzen',
expiry: 'Dieser Link ist 60 Minuten gültig.',
ignore: 'Wenn du das nicht warst, ignoriere diese E-Mail — dein Passwort bleibt unverändert.',
},
};
export default de;