From b9a60ca5998fd8d06f17f4c3b8078cb840a33d90 Mon Sep 17 00:00:00 2001 From: shilangyu Date: Wed, 3 Mar 2021 13:16:05 +0100 Subject: [PATCH] Integrate more strings --- lib/l10n/intl_ca.arb | 2 +- lib/l10n/intl_da.arb | 2 +- lib/l10n/intl_de.arb | 2 +- lib/l10n/intl_el.arb | 2 +- lib/l10n/intl_en.arb | 6 +++--- lib/l10n/intl_eo.arb | 2 +- lib/l10n/intl_es.arb | 2 +- lib/l10n/intl_eu.arb | 2 +- lib/l10n/intl_fa.arb | 2 +- lib/l10n/intl_fi.arb | 2 +- lib/l10n/intl_fr.arb | 2 +- lib/l10n/intl_hu.arb | 2 +- lib/l10n/intl_it.arb | 2 +- lib/l10n/intl_ja.arb | 2 +- lib/l10n/intl_ka.arb | 2 +- lib/l10n/intl_ko.arb | 2 +- lib/l10n/intl_nl.arb | 2 +- lib/l10n/intl_pt_BR.arb | 2 +- lib/l10n/intl_sq.arb | 2 +- lib/l10n/intl_sv.arb | 2 +- lib/l10n/intl_tr.arb | 2 +- lib/l10n/intl_zh.arb | 2 +- lib/l10n/l10n_from_string.dart | 2 +- lib/l10n/untranslated.json | 28 ++++++++++++++-------------- lib/pages/community.dart | 12 ++++++++---- lib/pages/inbox.dart | 2 +- lib/pages/instance.dart | 18 ++++++++++++------ lib/pages/manage_account.dart | 21 +++++++++++---------- lib/pages/search_tab.dart | 5 +++-- lib/pages/write_message.dart | 2 +- lib/widgets/post.dart | 4 ++-- lib/widgets/user_profile.dart | 8 ++++---- scripts/migrate_lemmy_l10n.dart | 4 ++-- 33 files changed, 83 insertions(+), 71 deletions(-) diff --git a/lib/l10n/intl_ca.arb b/lib/l10n/intl_ca.arb index 80896c4..1678fe0 100644 --- a/lib/l10n/intl_ca.arb +++ b/lib/l10n/intl_ca.arb @@ -105,7 +105,7 @@ "post_title_too_long": "El títol de l’apunt és massa llarg.", "email_already_exists": "L’adreça ja és en ús.", "user_already_exists": "L’usuari ja existeix.", - "number_users_online": "{count,plural, =1{{count} usuari en línia} other{{count} usuaris en línia}}", + "number_of_users_online": "{count,plural, =1{{count} usuari en línia} other{{count} usuaris en línia}}", "number_of_comments": "{count,plural, =1{{count} comentari} other{{count} comentaris}}", "number_of_posts": "{count,plural, =1{{count} Publicació} other{{count} Publicacions}}", "number_of_subscribers": "{count,plural, =1{{count} subscriptor} other{{count} subscriptors}}", diff --git a/lib/l10n/intl_da.arb b/lib/l10n/intl_da.arb index 55a381d..6c08b01 100644 --- a/lib/l10n/intl_da.arb +++ b/lib/l10n/intl_da.arb @@ -105,7 +105,7 @@ "post_title_too_long": "Indlægstitel for lang.", "email_already_exists": "Emailen findes allerede.", "user_already_exists": "Brugeren findes allerede.", - "number_users_online": "{count,plural, =1{{count} Bruger Online} other{{count} Brugere Online}}", + "number_of_users_online": "{count,plural, =1{{count} Bruger Online} other{{count} Brugere Online}}", "number_of_comments": "{count,plural, =1{{count} Kommentar} other{{count} Kommentarer}}", "number_of_posts": "{count,plural, =1{{count} Indlæg} other{{count} Indlæg}}", "number_of_subscribers": "{count,plural, =1{{count} Abonnent} other{{count} Abonnenter}}", diff --git a/lib/l10n/intl_de.arb b/lib/l10n/intl_de.arb index af92051..dadb2a4 100644 --- a/lib/l10n/intl_de.arb +++ b/lib/l10n/intl_de.arb @@ -101,7 +101,7 @@ "post_title_too_long": "Posttitel zu lang.", "email_already_exists": "Email existiert bereits.", "user_already_exists": "Nutzer existiert bereits.", - "number_users_online": "{count,plural, =1{{count} Benutzer online} other{{count} Benutzer*innen online}}", + "number_of_users_online": "{count,plural, =1{{count} Benutzer online} other{{count} Benutzer*innen online}}", "number_of_comments": "{count,plural, =1{{count} Kommentar} other{{count} Kommentare}}", "number_of_posts": "{count,plural, =1{{count} Beitrag} other{{count} Beiträge}}", "number_of_subscribers": "{count,plural, =1{{count} Abonnent} other{{count} Abonnent*innen}}", diff --git a/lib/l10n/intl_el.arb b/lib/l10n/intl_el.arb index 5e13bca..fb63d0f 100644 --- a/lib/l10n/intl_el.arb +++ b/lib/l10n/intl_el.arb @@ -105,7 +105,7 @@ "post_title_too_long": "Η επικεφαλίδα της δημοσίευσης είναι υπερβολικά μεγάλη.", "email_already_exists": "Η διεύθυνση ηλεκτρονικού ταχυδρομείου υπάρχει ήδη.", "user_already_exists": "Ο χρήστης υπάρχει ήδη.", - "number_users_online": "{count,plural, =1{{count} ενεργός χρήστης} other{{count} ενεργοί χρήστες}}", + "number_of_users_online": "{count,plural, =1{{count} ενεργός χρήστης} other{{count} ενεργοί χρήστες}}", "number_of_comments": "{count,plural, =1{{count} Σχόλιο} other{{count} Σχόλια}}", "number_of_posts": "{count,plural, =1{{count} Δημοσίευση} other{{count} Δημοσιεύσεις}}", "number_of_subscribers": "{count,plural, =1{{count} εγγεγραμμένος} other{{count} εγγεγραμμένοι}}", diff --git a/lib/l10n/intl_en.arb b/lib/l10n/intl_en.arb index 570317f..86946e8 100644 --- a/lib/l10n/intl_en.arb +++ b/lib/l10n/intl_en.arb @@ -80,7 +80,7 @@ "@show_nsfw": {}, "send_notifications_to_email": "Send notifications to Email", "@send_notifications_to_email": {}, - "delete_account": "Delete Account", + "delete_account": "Delete account", "@delete_account": {}, "saved": "Saved", "@saved": {}, @@ -212,8 +212,8 @@ "@email_already_exists": {}, "user_already_exists": "User already exists.", "@user_already_exists": {}, - "number_users_online": "{count,plural, =1{{count} user online} other{{count} users online}}", - "@number_users_online": { + "number_of_users_online": "{count,plural, =1{{count} user online} other{{count} users online}}", + "@number_of_users_online": { "placeholders": { "count": {} } diff --git a/lib/l10n/intl_eo.arb b/lib/l10n/intl_eo.arb index 76255fd..0040c9d 100644 --- a/lib/l10n/intl_eo.arb +++ b/lib/l10n/intl_eo.arb @@ -105,7 +105,7 @@ "post_title_too_long": "Titolo de afiŝo estas tro longa.", "email_already_exists": "Retpoŝtadreso jam ekzistas.", "user_already_exists": "Uzanto jam ekzistas.", - "number_users_online": "{count,plural, =1{{count} uzanto enreta} other{{count} uzantoj enretaj}}", + "number_of_users_online": "{count,plural, =1{{count} uzanto enreta} other{{count} uzantoj enretaj}}", "number_of_comments": "{count,plural, =1{{count} komento} other{{count} komentoj}}", "number_of_posts": "{count,plural, =1{{count} afiŝo} other{{count} afiŝoj}}", "number_of_subscribers": "{count,plural, =1{{count} abonanto} other{{count} abonantoj}}", diff --git a/lib/l10n/intl_es.arb b/lib/l10n/intl_es.arb index a07c61f..cc741dc 100644 --- a/lib/l10n/intl_es.arb +++ b/lib/l10n/intl_es.arb @@ -105,7 +105,7 @@ "post_title_too_long": "El título de la publicación es muy largo.", "email_already_exists": "El correo ya está en uso.", "user_already_exists": "El usuario ya existe.", - "number_users_online": "{count,plural, =1{{count} usuario en línea} other{{count} usuarios en línea}}", + "number_of_users_online": "{count,plural, =1{{count} usuario en línea} other{{count} usuarios en línea}}", "number_of_comments": "{count,plural, =1{{count} Comentario} other{{count} Comentarios}}", "number_of_posts": "{count,plural, =1{{count} Publicación} other{{count} Publicaciones}}", "number_of_subscribers": "{count,plural, =1{{count} suscriptor} other{{count} suscriptores}}", diff --git a/lib/l10n/intl_eu.arb b/lib/l10n/intl_eu.arb index e2ebd3b..d124beb 100644 --- a/lib/l10n/intl_eu.arb +++ b/lib/l10n/intl_eu.arb @@ -105,7 +105,7 @@ "post_title_too_long": "Bidalketaren izenburua luzeegia da.", "email_already_exists": "Eposta hori dagoeneko existitzen da.", "user_already_exists": "Erabiltzaile hori dagoeneko existitzen da.", - "number_users_online": "{count,plural, =1{Erabiltzaile {count} konektatuta} other{{count} erabiltzaile konektatuta}}", + "number_of_users_online": "{count,plural, =1{Erabiltzaile {count} konektatuta} other{{count} erabiltzaile konektatuta}}", "number_of_comments": "{count,plural, =1{Iruzkin {count}} other{{count} iruzkin}}", "number_of_posts": "{count,plural, =1{Bidalketa {count}} other{{count} bidalketa}}", "number_of_subscribers": "{count,plural, =1{Harpidetu {count}} other{{count} harpidetu}}", diff --git a/lib/l10n/intl_fa.arb b/lib/l10n/intl_fa.arb index 67ae988..2d772a7 100644 --- a/lib/l10n/intl_fa.arb +++ b/lib/l10n/intl_fa.arb @@ -68,7 +68,7 @@ "couldnt_update_post": "ناتوای در به‌روزرسانی مطلب", "email_already_exists": "این رایانامه از قبل وجود دارد.", "user_already_exists": "این کاربر از قبل وجود دارد.", - "number_users_online": "{count,plural, =1{{count} کاربر برخط}}", + "number_of_users_online": "{count,plural, =1{{count} کاربر برخط}}", "number_of_comments": "{count,plural, =1{{count} نظر}}", "number_of_posts": "{count,plural, =1{{count} مطلب}}", "number_of_users": "{count,plural, =1{{count} کاربر}}", diff --git a/lib/l10n/intl_fi.arb b/lib/l10n/intl_fi.arb index 2244071..7d8f731 100644 --- a/lib/l10n/intl_fi.arb +++ b/lib/l10n/intl_fi.arb @@ -90,7 +90,7 @@ "post_title_too_long": "Viestin otsikko on liian pitkä.", "email_already_exists": "Sähköposti on jo olemassa.", "user_already_exists": "Käyttäjä on jo olemassa.", - "number_users_online": "{count,plural, =1{{count} käyttäjä aktiivisena} other{{count} käyttäjää aktiivisena}}", + "number_of_users_online": "{count,plural, =1{{count} käyttäjä aktiivisena} other{{count} käyttäjää aktiivisena}}", "number_of_comments": "{count,plural, =1{{count} kommentti} other{{count} kommenttia}}", "number_of_posts": "{count,plural, =1{{count} viesti} other{{count} viestiä}}", "number_of_subscribers": "{count,plural, =1{{count} tilaaja} other{{count} tilaajaa}}", diff --git a/lib/l10n/intl_fr.arb b/lib/l10n/intl_fr.arb index 8a4a9c1..5b892ad 100644 --- a/lib/l10n/intl_fr.arb +++ b/lib/l10n/intl_fr.arb @@ -104,7 +104,7 @@ "post_title_too_long": "Le titre de la publication est trop long.", "email_already_exists": "L’email existe déjà.", "user_already_exists": "L’utilisateur·rice existe déjà.", - "number_users_online": "{count,plural, =1{{count} Utilisateur en ligne} other{{count} Utilisateurs en ligne}}", + "number_of_users_online": "{count,plural, =1{{count} Utilisateur en ligne} other{{count} Utilisateurs en ligne}}", "number_of_comments": "{count,plural, =1{{count} Commentaire} other{{count} Commentaires}}", "number_of_posts": "{count,plural, =1{{count} Publication} other{{count} Publications}}", "number_of_subscribers": "{count,plural, =1{{count} Abonné} other{{count} Abonnés}}", diff --git a/lib/l10n/intl_hu.arb b/lib/l10n/intl_hu.arb index a56619f..5fd456a 100644 --- a/lib/l10n/intl_hu.arb +++ b/lib/l10n/intl_hu.arb @@ -91,7 +91,7 @@ "post_title_too_long": "A bejegyzés címe túl hosszú.", "email_already_exists": "Az email már létezik.", "user_already_exists": "A felhasználó már létezik.", - "number_users_online": "{count,plural, =1{{count} online felhasználó} other{{count} online felhasználó}}", + "number_of_users_online": "{count,plural, =1{{count} online felhasználó} other{{count} online felhasználó}}", "number_of_comments": "{count,plural, =1{{count} hozzászólás} other{{count} hozzászólás}}", "number_of_posts": "{count,plural, =1{{count} bejegyzés} other{{count} bejegyzés}}", "number_of_subscribers": "{count,plural, =1{{count} feliratkozó} other{{count} feliratkozó}}", diff --git a/lib/l10n/intl_it.arb b/lib/l10n/intl_it.arb index 6212ca0..ac03221 100644 --- a/lib/l10n/intl_it.arb +++ b/lib/l10n/intl_it.arb @@ -105,7 +105,7 @@ "post_title_too_long": "Titolo della pubblicazione troppo lungo.", "email_already_exists": "Indirizzo email già presente.", "user_already_exists": "L'utente esiste già.", - "number_users_online": "{count,plural, =1{{count} utente connesso} other{{count} utenti connessi}}", + "number_of_users_online": "{count,plural, =1{{count} utente connesso} other{{count} utenti connessi}}", "number_of_comments": "{count,plural, =1{{count} Commento} other{{count} Commenti}}", "number_of_posts": "{count,plural, =1{{count} Pubblicazione} other{{count} Pubblicazioni}}", "number_of_subscribers": "{count,plural, =1{{count} iscritto} other{{count} iscritti}}", diff --git a/lib/l10n/intl_ja.arb b/lib/l10n/intl_ja.arb index 10e9c42..2e8ec04 100644 --- a/lib/l10n/intl_ja.arb +++ b/lib/l10n/intl_ja.arb @@ -93,7 +93,7 @@ "post_title_too_long": "投稿のタイトルが長すぎます。", "email_already_exists": "メールアドレスが既に使用されています。", "user_already_exists": "ユーザーは既に存在します。", - "number_users_online": "{count,plural, =1{{count} 名のユーザーがオンライン}}", + "number_of_users_online": "{count,plural, =1{{count} 名のユーザーがオンライン}}", "number_of_comments": "{count,plural, =1{{count} 件のコメント}}", "number_of_posts": "{count,plural, =1{{count} 件の投稿}}", "number_of_subscribers": "{count,plural, =1{{count} 名の登録者}}", diff --git a/lib/l10n/intl_ka.arb b/lib/l10n/intl_ka.arb index b2f9dd7..102b0db 100644 --- a/lib/l10n/intl_ka.arb +++ b/lib/l10n/intl_ka.arb @@ -86,7 +86,7 @@ "post_title_too_long": "პოსტის სათაური ძალიან გრძელია.", "email_already_exists": "ელ-პოსტა უკვე არსებობს.", "user_already_exists": "მომხმარებელი უკვე არსებობს.", - "number_users_online": "{count,plural, =1{მომხმარებელი საიტზე} other{მომხმარებელი საიტზე}}", + "number_of_users_online": "{count,plural, =1{მომხმარებელი საიტზე} other{მომხმარებელი საიტზე}}", "number_of_comments": "{count,plural, =1{კომენტარი} other{კომანტარები}}", "number_of_posts": "{count,plural, =1{თარგმნა} other{თარგმნა}}", "number_of_subscribers": "{count,plural, =1{გამომწერი} other{გამომწერები}}", diff --git a/lib/l10n/intl_ko.arb b/lib/l10n/intl_ko.arb index 0608fb7..2397205 100644 --- a/lib/l10n/intl_ko.arb +++ b/lib/l10n/intl_ko.arb @@ -105,7 +105,7 @@ "post_title_too_long": "게시물 제목이 너무 깁니다.", "email_already_exists": "이메일이 이미 존재합니다.", "user_already_exists": "사용자가 이미 존재합니다.", - "number_users_online": "{count,plural, =1{접속자수 {count}}}", + "number_of_users_online": "{count,plural, =1{접속자수 {count}}}", "number_of_comments": "{count,plural, =1{덧글수 {count}}}", "number_of_posts": "{count,plural, =1{게시물 수 {count}}}", "number_of_subscribers": "{count,plural, =1{구독자수{count}}}", diff --git a/lib/l10n/intl_nl.arb b/lib/l10n/intl_nl.arb index 54410b4..eb31533 100644 --- a/lib/l10n/intl_nl.arb +++ b/lib/l10n/intl_nl.arb @@ -91,7 +91,7 @@ "post_title_too_long": "Posttitel te lang.", "email_already_exists": "Email bestaat al.", "user_already_exists": "Gebruiker bestaat al.", - "number_users_online": "{count,plural, =1{{count} gebruiker online} other{{count} gebruikers online}}", + "number_of_users_online": "{count,plural, =1{{count} gebruiker online} other{{count} gebruikers online}}", "number_of_comments": "{count,plural, =1{{count} reactie} other{{count} reacties}}", "number_of_posts": "{count,plural, =1{{count} post} other{{count} posts}}", "number_of_subscribers": "{count,plural, =1{{count} abonnee} other{{count} abonnees}}", diff --git a/lib/l10n/intl_pt_BR.arb b/lib/l10n/intl_pt_BR.arb index a206d4a..42a2882 100644 --- a/lib/l10n/intl_pt_BR.arb +++ b/lib/l10n/intl_pt_BR.arb @@ -101,7 +101,7 @@ "post_title_too_long": "Título da publicação muito longo.", "email_already_exists": "Este e-mail já existe.", "user_already_exists": "Este usuário já existe.", - "number_users_online": "{count,plural, =1{{count} usuário online} other{{count} usuários online}}", + "number_of_users_online": "{count,plural, =1{{count} usuário online} other{{count} usuários online}}", "number_of_comments": "{count,plural, =1{{count} comentário} other{{count} comentários}}", "number_of_posts": "{count,plural, =1{{count} publicação} other{{count} publicações}}", "number_of_subscribers": "{count,plural, =1{{count} inscrito} other{{count} inscritos}}", diff --git a/lib/l10n/intl_sq.arb b/lib/l10n/intl_sq.arb index f762301..e0bb169 100644 --- a/lib/l10n/intl_sq.arb +++ b/lib/l10n/intl_sq.arb @@ -91,7 +91,7 @@ "post_title_too_long": "Titulli i postimit ishte shumë i gjatë.", "email_already_exists": "Email-i tashmë ekziston.", "user_already_exists": "Përdoruesi tashmë ekziston.", - "number_users_online": "{count,plural, =1{{count} Përdorues Online} other{{count} Përdoruesa Online}}", + "number_of_users_online": "{count,plural, =1{{count} Përdorues Online} other{{count} Përdoruesa Online}}", "number_of_comments": "{count,plural, =1{{count} Koment} other{{count} Komente}}", "number_of_posts": "{count,plural, =1{{count} Postim} other{{count} Postime}}", "number_of_subscribers": "{count,plural, =1{{count} i abonuar} other{{count} të abonuar}}", diff --git a/lib/l10n/intl_sv.arb b/lib/l10n/intl_sv.arb index 68c35cd..7ce4674 100644 --- a/lib/l10n/intl_sv.arb +++ b/lib/l10n/intl_sv.arb @@ -105,7 +105,7 @@ "post_title_too_long": "Inläggstiteln är för lång.", "email_already_exists": "E-post finns redan.", "user_already_exists": "Användaren finns redan.", - "number_users_online": "{count,plural, =1{{count} användare inloggad} other{{count} användare inloggade}}", + "number_of_users_online": "{count,plural, =1{{count} användare inloggad} other{{count} användare inloggade}}", "number_of_comments": "{count,plural, =1{{count} kommentar} other{{count} kommentarer}}", "number_of_posts": "{count,plural, =1{{count} inlägg} other{{count} inlägg}}", "number_of_subscribers": "{count,plural, =1{{count} prenumerant} other{{count} prenumeranter}}", diff --git a/lib/l10n/intl_tr.arb b/lib/l10n/intl_tr.arb index 29442d4..b8f251d 100644 --- a/lib/l10n/intl_tr.arb +++ b/lib/l10n/intl_tr.arb @@ -91,7 +91,7 @@ "post_title_too_long": "Paylaşım başlığı çok uzun.", "email_already_exists": "Böyle bir e-mail adresi zaten var.", "user_already_exists": "Böyle bir kullanıcı zaten var.", - "number_users_online": "{count,plural, =1{{count} Kullanıcı Hatta} other{{count} Kullanıcı Hatta}}", + "number_of_users_online": "{count,plural, =1{{count} Kullanıcı Hatta} other{{count} Kullanıcı Hatta}}", "number_of_comments": "{count,plural, =1{{count} Yorum} other{{count} Yorum}}", "number_of_posts": "{count,plural, =1{{count} Paylaşım} other{{count} Paylaşım}}", "number_of_subscribers": "{count,plural, =1{{count} Takipçi} other{{count} Takipçi}}", diff --git a/lib/l10n/intl_zh.arb b/lib/l10n/intl_zh.arb index de2724f..ab521bb 100644 --- a/lib/l10n/intl_zh.arb +++ b/lib/l10n/intl_zh.arb @@ -105,7 +105,7 @@ "post_title_too_long": "帖子标题过长。", "email_already_exists": "邮箱已占用.", "user_already_exists": "用户已存在。", - "number_users_online": "{count,plural, =1{{count} 在线用户} other{{count} 名在线用户}}", + "number_of_users_online": "{count,plural, =1{{count} 在线用户} other{{count} 名在线用户}}", "number_of_comments": "{count,plural, =1{{count} 条评论} other{{count} 条评论}}", "number_of_posts": "{count,plural, =1{{count} 个帖子} other{{count} 条帖子}}", "number_of_subscribers": "{count,plural, =1{{count} 订阅者} other{{count} 名订阅者}}", diff --git a/lib/l10n/l10n_from_string.dart b/lib/l10n/l10n_from_string.dart index edd4125..54117c2 100644 --- a/lib/l10n/l10n_from_string.dart +++ b/lib/l10n/l10n_from_string.dart @@ -117,7 +117,7 @@ abstract class L10nStrings { static const post_title_too_long = 'post_title_too_long'; static const email_already_exists = 'email_already_exists'; static const user_already_exists = 'user_already_exists'; - static const number_users_online = 'number_users_online'; + static const number_of_users_online = 'number_of_users_online'; static const number_of_comments = 'number_of_comments'; static const number_of_posts = 'number_of_posts'; static const number_of_subscribers = 'number_of_subscribers'; diff --git a/lib/l10n/untranslated.json b/lib/l10n/untranslated.json index f4f3fe7..aaf4462 100644 --- a/lib/l10n/untranslated.json +++ b/lib/l10n/untranslated.json @@ -46,7 +46,7 @@ "couldnt_create_private_message", "no_private_message_edit_allowed", "post_title_too_long", - "number_users_online", + "number_of_users_online", "number_of_comments", "number_of_posts", "number_of_subscribers", @@ -163,7 +163,7 @@ "report_too_long", "couldnt_create_report", "couldnt_resolve_report", - "number_users_online", + "number_of_users_online", "number_of_comments", "number_of_posts", "number_of_subscribers", @@ -277,7 +277,7 @@ "post_title_too_long", "email_already_exists", "user_already_exists", - "number_users_online", + "number_of_users_online", "number_of_comments", "number_of_posts", "number_of_subscribers", @@ -385,7 +385,7 @@ "post_title_too_long", "email_already_exists", "user_already_exists", - "number_users_online", + "number_of_users_online", "number_of_subscribers", "number_of_users", "unsubscribe", @@ -506,7 +506,7 @@ "post_title_too_long", "email_already_exists", "user_already_exists", - "number_users_online", + "number_of_users_online", "number_of_comments", "number_of_posts", "number_of_subscribers", @@ -693,7 +693,7 @@ "post_title_too_long", "email_already_exists", "user_already_exists", - "number_users_online", + "number_of_users_online", "number_of_comments", "number_of_posts", "number_of_subscribers", @@ -840,7 +840,7 @@ "post_title_too_long", "email_already_exists", "user_already_exists", - "number_users_online", + "number_of_users_online", "number_of_comments", "number_of_posts", "number_of_subscribers", @@ -860,7 +860,7 @@ "pl": [ "not_a_mod_or_admin", - "number_users_online", + "number_of_users_online", "number_of_comments", "number_of_posts", "number_of_subscribers", @@ -974,7 +974,7 @@ "post_title_too_long", "email_already_exists", "user_already_exists", - "number_users_online", + "number_of_users_online", "number_of_comments", "number_of_posts", "number_of_subscribers", @@ -1002,7 +1002,7 @@ "ru": [ "not_a_mod_or_admin", - "number_users_online", + "number_of_users_online", "number_of_comments", "number_of_posts", "number_of_subscribers", @@ -1134,7 +1134,7 @@ "post_title_too_long", "email_already_exists", "user_already_exists", - "number_users_online", + "number_of_users_online", "number_of_comments", "number_of_posts", "number_of_subscribers", @@ -1240,7 +1240,7 @@ "post_title_too_long", "email_already_exists", "user_already_exists", - "number_users_online", + "number_of_users_online", "number_of_comments", "number_of_posts", "number_of_subscribers", @@ -1366,7 +1366,7 @@ "post_title_too_long", "email_already_exists", "user_already_exists", - "number_users_online", + "number_of_users_online", "number_of_comments", "number_of_posts", "number_of_subscribers", @@ -1418,7 +1418,7 @@ "invalid_password", "captcha_incorrect", "bio_length_overflow", - "number_users_online", + "number_of_users_online", "number_of_comments", "number_of_posts", "number_of_subscribers", diff --git a/lib/pages/community.dart b/lib/pages/community.dart index 6c60e7e..550c9ab 100644 --- a/lib/pages/community.dart +++ b/lib/pages/community.dart @@ -398,10 +398,12 @@ class _AboutTab extends StatelessWidget { scrollDirection: Axis.horizontal, padding: const EdgeInsets.symmetric(horizontal: 15), children: [ - Chip(label: Text('${onlineUsers ?? 'X'} users online')), Chip( - label: Text( - '${community.counts.subscribers} subscriber${pluralS(community.counts.subscribers)}')), + label: Text(L10n.of(context) + .number_of_users_online(onlineUsers ?? 0))), + Chip( + label: Text(L10n.of(context) + .number_of_subscribers(community.counts.subscribers))), Chip( label: Text( '${community.counts.posts} post${pluralS(community.counts.posts)}')), @@ -526,7 +528,9 @@ class _FollowButton extends HookWidget { icon: isSubbed.value ? const Icon(Icons.remove, size: 18) : const Icon(Icons.add, size: 18), - label: Text('${isSubbed.value ? 'un' : ''}subscribe'), + label: Text(isSubbed.value + ? L10n.of(context).unsubscribe + : L10n.of(context).subscribe), ), ), ), diff --git a/lib/pages/inbox.dart b/lib/pages/inbox.dart index d2be0a7..d101562 100644 --- a/lib/pages/inbox.dart +++ b/lib/pages/inbox.dart @@ -95,7 +95,7 @@ class InboxPage extends HookWidget { tabs: [ Tab(text: L10n.of(context).replies), Tab(text: L10n.of(context).mentions), - const Tab(text: 'Messages'), + Tab(text: L10n.of(context).messages), ], ), ), diff --git a/lib/pages/instance.dart b/lib/pages/instance.dart index d676d14..7ece646 100644 --- a/lib/pages/instance.dart +++ b/lib/pages/instance.dart @@ -216,11 +216,13 @@ class _AboutTab extends HookWidget { : assert(communitiesFuture != null), assert(instanceHost != null); - void goToBannedUsers(BuildContext c) { + void goToBannedUsers(BuildContext context) { goTo( - c, + context, (_) => UsersListPage( - users: site.banned.reversed.toList(), title: 'Banned users'), + users: site.banned.reversed.toList(), + title: L10n.of(context).banned_users, + ), ); } @@ -267,8 +269,12 @@ class _AboutTab extends HookWidget { scrollDirection: Axis.horizontal, padding: const EdgeInsets.symmetric(horizontal: 15), children: [ - Chip(label: Text('${site.online} users online')), - Chip(label: Text('${site.siteView.counts.users} users')), + Chip( + label: Text(L10n.of(context) + .number_of_users_online(site.online))), + Chip( + label: Text(L10n.of(context) + .number_of_users(site.siteView.counts.users))), Chip( label: Text( '${site.siteView.counts.communities} communities')), @@ -329,7 +335,7 @@ class _AboutTab extends HookWidget { ), const _Divider(), ListTile( - title: const Center(child: Text('Banned users')), + title: Center(child: Text(L10n.of(context).banned_users)), onTap: () => goToBannedUsers(context), ), ListTile( diff --git a/lib/pages/manage_account.dart b/lib/pages/manage_account.dart index 868d3de..49140e0 100644 --- a/lib/pages/manage_account.dart +++ b/lib/pages/manage_account.dart @@ -149,18 +149,18 @@ class _ManageAccount extends HookWidget { final confirmDelete = await showDialog( context: context, builder: (context) => AlertDialog( - title: const Text('Remove account?'), + title: Text( + '${L10n.of(context).delete_account} @${user.instanceHost}@${user.name}'), content: Column( mainAxisSize: MainAxisSize.min, children: [ - Text( - 'Are you sure you want to remove @${user.instanceHost}@${user.name}? ' - 'WARNING: this removes your account COMPLETELY, not from lemmur only', - ), + Text(L10n.of(context).delete_account_confirm), + const SizedBox(height: 10), TextField( controller: deleteAccountPasswordController, obscureText: true, - decoration: const InputDecoration(hintText: 'Password'), + decoration: + InputDecoration(hintText: L10n.of(context).password), ) ], ), @@ -236,19 +236,20 @@ class _ManageAccount extends HookWidget { Text(L10n.of(context).matrix_user, style: theme.textTheme.headline6), TextField(controller: matrixUserController), const SizedBox(height: 8), - Text('New password', style: theme.textTheme.headline6), + Text(L10n.of(context).new_password, style: theme.textTheme.headline6), TextField( controller: newPasswordController, obscureText: true, ), const SizedBox(height: 8), - Text('Verify password', style: theme.textTheme.headline6), + Text(L10n.of(context).verify_password, + style: theme.textTheme.headline6), TextField( controller: newPasswordVerifyController, obscureText: true, ), const SizedBox(height: 8), - Text('Old password', style: theme.textTheme.headline6), + Text(L10n.of(context).old_password, style: theme.textTheme.headline6), TextField( controller: oldPasswordController, obscureText: true, @@ -305,7 +306,7 @@ class _ManageAccount extends HookWidget { CheckboxListTile( value: showAvatars.value, onChanged: (checked) => showAvatars.value = checked, - title: const Text('Show avatars'), + title: Text(L10n.of(context).show_avatars), subtitle: const Text('This has currently no effect on lemmur'), dense: true, ), diff --git a/lib/pages/search_tab.dart b/lib/pages/search_tab.dart index c085260..e485b29 100644 --- a/lib/pages/search_tab.dart +++ b/lib/pages/search_tab.dart @@ -3,6 +3,7 @@ import 'package:flutter/material.dart'; import 'package:flutter_hooks/flutter_hooks.dart'; import '../hooks/stores.dart'; +import '../l10n/l10n.dart'; import '../util/goto.dart'; import '../widgets/radio_picker.dart'; import 'search_results.dart'; @@ -38,7 +39,7 @@ class SearchTab extends HookWidget { TextField( controller: searchInputController, textAlign: TextAlign.center, - decoration: const InputDecoration(hintText: 'search'), + decoration: InputDecoration(hintText: L10n.of(context).search), ), const SizedBox(height: 5), Row( @@ -65,7 +66,7 @@ class SearchTab extends HookWidget { instanceHost: instanceHost.value, query: searchInputController.text, )), - child: const Text('search'), + child: Text(L10n.of(context).search), ) ], ), diff --git a/lib/pages/write_message.dart b/lib/pages/write_message.dart index d800c0c..3992c18 100644 --- a/lib/pages/write_message.dart +++ b/lib/pages/write_message.dart @@ -43,7 +43,7 @@ class WriteMessagePage extends HookWidget { final loading = useState(false); final submit = _isEdit ? L10n.of(context).save : 'send'; - final title = _isEdit ? 'Edit message' : 'Send message'; + final title = _isEdit ? 'Edit message' : L10n.of(context).send_message; handleSubmit() async { if (_isEdit) { diff --git a/lib/widgets/post.dart b/lib/widgets/post.dart index 7615d28..959b58e 100644 --- a/lib/widgets/post.dart +++ b/lib/widgets/post.dart @@ -371,11 +371,11 @@ class PostWidget extends HookWidget { child: Row( children: [ const Icon(Icons.comment), + const SizedBox(width: 6), Expanded( flex: 999, child: Text( - ' ${NumberFormat.compact().format(post.counts.comments)}' - ' comment${post.counts.comments == 1 ? '' : 's'}', + L10n.of(context).number_of_comments(post.counts.comments), overflow: TextOverflow.fade, softWrap: false, ), diff --git a/lib/widgets/user_profile.dart b/lib/widgets/user_profile.dart index 2134ecb..67dcd95 100644 --- a/lib/widgets/user_profile.dart +++ b/lib/widgets/user_profile.dart @@ -11,7 +11,6 @@ import '../pages/manage_account.dart'; import '../util/extensions/api.dart'; import '../util/extensions/datetime.dart'; import '../util/goto.dart'; -import '../util/intl.dart'; import '../util/text_color.dart'; import 'avatar.dart'; import 'fullscreenable_image.dart'; @@ -256,8 +255,8 @@ class _UserOverview extends HookWidget { ), const SizedBox(width: 4), Text( - '${compactNumber(userView.counts.postCount)}' - ' Post${pluralS(userView.counts.postCount)}', + L10n.of(context) + .number_of_posts(userView.counts.postCount), style: TextStyle(color: colorOnTopOfAccentColor), ), ], @@ -274,7 +273,8 @@ class _UserOverview extends HookWidget { ), const SizedBox(width: 4), Text( - '${compactNumber(userView.counts.commentCount)} Comment${pluralS(userView.counts.commentCount)}', + L10n.of(context) + .number_of_comments(userView.counts.commentCount), style: TextStyle(color: colorOnTopOfAccentColor), ), ], diff --git a/scripts/migrate_lemmy_l10n.dart b/scripts/migrate_lemmy_l10n.dart index 92ce8a4..cc3cbec 100644 --- a/scripts/migrate_lemmy_l10n.dart +++ b/scripts/migrate_lemmy_l10n.dart @@ -84,7 +84,7 @@ const toMigrate = <_>[ _('type'), _('show_nsfw'), _('send_notifications_to_email'), - _('delete_account'), + _('delete_account', decapitalize: true), _('saved'), _('communities'), _('users'), @@ -150,7 +150,7 @@ const toMigrate = <_>[ _('post_title_too_long'), _('email_already_exists'), _('user_already_exists'), - _('number_online', rename: 'number_users_online'), + _('number_online', rename: 'number_of_users_online'), _('number_of_comments', type: 'int', format: 'compact', toLowerCase: true), _('number_of_posts', type: 'int', format: 'compact', toLowerCase: true), _('number_of_subscribers'),