mirror of
https://github.com/mauriceboe/TREK.git
synced 2026-10-21 22:46:32 +00:00
bee500880e
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.
90 lines
5.1 KiB
TypeScript
90 lines
5.1 KiB
TypeScript
import type { NotificationLocale } from '../externalNotifications/types';
|
||
import { pluralForm } from '../plural';
|
||
|
||
const gr: NotificationLocale = {
|
||
email: {
|
||
footer: 'Λάβατε αυτό το μήνυμα επειδή έχετε ενεργοποιήσει τις ειδοποιήσεις στο TREK.',
|
||
manage: 'Διαχείριση προτιμήσεων στις Ρυθμίσεις',
|
||
madeWith: 'Δημιουργήθηκε με',
|
||
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: 'Πρόσκληση συγχώνευσης διακοπών',
|
||
body: `Ο/Η ${p.actor} σας προσκάλεσε να συγχωνεύσετε τα σχέδια διακοπών σας. Ανοίξτε το TREK για να αποδεχτείτε ή να απορρίψετε.`,
|
||
}),
|
||
vacay_share: (p) => ({
|
||
title: 'Κοινοποίηση Ημερολογίου Vacay',
|
||
body: `Ο/Η ${p.actor} κοινοποίησε το ημερολόγιο διακοπών του/της σε εσάς. Ανοίξτε το TREK για να το δείτε.`,
|
||
}),
|
||
collection_invite: (p) => ({
|
||
title: 'Πρόσκληση σε συλλογή',
|
||
body: `Ο/Η ${p.actor} σας προσκάλεσε να μοιραστείτε μια συλλογή. Ανοίξτε το TREK για να αποδεχτείτε ή να απορρίψετε.`,
|
||
}),
|
||
photos_shared: (p) => ({
|
||
title: pluralForm(p.count, 'el', {
|
||
one: `${p.count} φωτογραφία κοινοποιήθηκε`,
|
||
other: `${p.count} φωτογραφίες κοινοποιήθηκαν`,
|
||
}),
|
||
body: pluralForm(p.count, 'el', {
|
||
one: `Ο/Η ${p.actor} κοινοποίησε ${p.count} φωτογραφία στο "${p.trip}".`,
|
||
other: `Ο/Η ${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} είναι τώρα διαθέσιμη. Επισκεφθείτε τον πίνακα διαχείρισης για να ενημερώσετε.`,
|
||
}),
|
||
replica_failure: (p) => ({
|
||
title: 'Αποτυχία αντιγράφου αποθήκευσης',
|
||
body:
|
||
`Η εγγραφή στο αντίγραφο '${p.backend}' απέτυχε: ${p.op} του ${p.key} — ${p.error}.` +
|
||
(p.suppressed !== '0'
|
||
? pluralForm(p.suppressed, 'el', {
|
||
one: ` ${p.suppressed} επιπλέον αποτυχία αποκρύφθηκε από την τελευταία ειδοποίηση και μετά.`,
|
||
other: ` ${p.suppressed} επιπλέον αποτυχίες αποκρύφθηκαν από την τελευταία ειδοποίηση και μετά.`,
|
||
})
|
||
: ''),
|
||
}),
|
||
synology_session_cleared: () => ({
|
||
title: 'Η σύνδεση Synology τερματίστηκε',
|
||
body: 'Ο λογαριασμός σας Synology ή το URL άλλαξε. Έχετε αποσυνδεθεί από το Synology Photos.',
|
||
}),
|
||
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
|
||
},
|
||
passwordReset: {
|
||
subject: 'Επαναφορά κωδικού πρόσβασης',
|
||
greeting: 'Γεια σας',
|
||
body: 'Λάβαμε ένα αίτημα επαναφοράς του κωδικού πρόσβασης για τον λογαριασμό σας στο TREK. Κάντε κλικ στο παρακάτω κουμπί για να ορίσετε νέο κωδικό πρόσβασης.',
|
||
ctaIntro: 'Επαναφορά κωδικού',
|
||
expiry: 'Αυτός ο σύνδεσμος λήγει σε 60 λεπτά.',
|
||
ignore: 'Εάν δεν ζητήσατε αυτή την αλλαγή, μπορείτε να αγνοήσετε αυτό το μήνυμα — ο κωδικός σας δεν θα αλλάξει.',
|
||
},
|
||
};
|
||
|
||
export default gr;
|