diff --git a/README.md b/README.md
index df3c74304..8f07aebdf 100644
--- a/README.md
+++ b/README.md
@@ -195,7 +195,8 @@ If you're having issues with [HRM](https://webpack.js.org/concepts/hot-module-re
You can either translate on-site via the translation mode, which will get merged eventually by the team
or by directly editing the corresponding `translation.suml`.
If a locale does not have a value translated, those inside `_base/translation.suml` are used.
-Please check `TODO` comments and translation values which have been copied, not translated from `_base`.
+Please check `TODO` comments and translation values which have been copied, but not translated from `_base`.
+If the original contains internal links, ensure that the route is also valid for your locale.
To check for missing translations, you can use the `admin/translations/missing` route.
### Creating a new language version
diff --git a/locale/de/translations.suml b/locale/de/translations.suml
index 0d15aa003..9aa1cc4a4 100644
--- a/locale/de/translations.suml
+++ b/locale/de/translations.suml
@@ -469,7 +469,7 @@ contact:
header: 'Erstelle eine neue Sprachversion'
description: >
Anweisungen zum Erstellen einer neuen Sprachversion findest du
- {https://en.pronouns.page/new-version=hier}. Bevor du beginnst, {/contact=kontaktiere uns} bitte, um sich
+ {https://en.pronouns.page/new-version=hier}. Bevor du beginnst, {/kontakt=kontaktiere uns} bitte, um sich
mit anderen abzustimmen, die möglicherweise auch daran arbeiten können.
translations:
header: 'Übersetzungen hinzufügen oder korrigieren'
diff --git a/locale/en/translations.suml b/locale/en/translations.suml
index c0d0f76e1..5e4117b65 100644
--- a/locale/en/translations.suml
+++ b/locale/en/translations.suml
@@ -1246,7 +1246,7 @@ privacy:
optional:
header: 'Optional cookies'
description: >
- We show ads to fund the project {/why-ads=(more details here)}.
+ We show ads to fund the project {/blog/why-ads=(more details here)}.
You can agree for related third-parties to store information about you
for the purposes of gathering statistics and personalising ads.
details: 'You can read more in Ezoic''s {https://g.ezoic.net/privacy/pronouns.page=Privacy Policy}.'
diff --git a/locale/es/translations.suml b/locale/es/translations.suml
index 5be9ea28e..e63090104 100644
--- a/locale/es/translations.suml
+++ b/locale/es/translations.suml
@@ -491,7 +491,7 @@ contact:
header: 'Crea una versión nueva en otro idioma'
description: >
Las intrucciones para crear una nueva versión en otro idioma están disponibles
- {https://en.pronouns.page/new-version=aquí}. Antes de empezar, por favor {/contact=contáctanos} para
+ {https://en.pronouns.page/new-version=aquí}. Antes de empezar, por favor {/contacto=contáctanos} para
coordinarte con otres que también puedan estar trabajando en esa versión también.
translations:
header: 'Agrega correcciones y traducciones'
@@ -668,7 +668,7 @@ profile:
Puedes también usar nuestro sitio web para crear una tarjeta {/@example=como esta},
que contenga tus nombres, pronombres, banderas de orgullo, palabras preferidas etc.
Después podrás poner un enlace a la tarjeta en tu biografía o tu firma de correo electrónico.
- Simplemente crea una cuenta {/account=aquí}.
+ Simplemente crea una cuenta {/cuenta=aquí}.
bannerButton: 'Crear una tarjeta'
card:
link: 'Imagen de la tarjeta'
@@ -708,7 +708,7 @@ profile:
sensitive:
header: 'Advertencia de contenido'
info: >
- Cierto contenido debe seguir nuestro {/terms=Terminos de Servicio} pero aún no es apropiado para menores, ser
+ Cierto contenido debe seguir nuestro {/terminos=Terminos de Servicio} pero aún no es apropiado para menores, ser
potencialmente desencadenante para personas con traumas, etc. Porfavor se reapetuoso con las personas que
visitan tu tarjeta y advierte antes de que avancen. Algunos ejemplos de CW pueden ser, "mención al alcohol",
"insinuaciones sexuales", "menciones a situaciones queerphobicas", etc.
@@ -1050,15 +1050,6 @@ ban:
header: 'Tu perfil no se mostrará a nadie.'
banned: 'Tu perfil no se mostrará a nadie.'
termsIntro: 'De acuerdo con nuestros {/terminos=Términos de Servicio}'
- # TODO
- appeal: >
- Moderation is a complex and delicate subject. It's being done by volunteers who might not always agree with each other
- or be aware of some issues. If you think your account didn't breach our {/terms=Terms of Service},
- please contact us at {mailto:contact@pronouns.page=contact@pronouns.page} and we might get another look in a bigger group.
- appealEmail: >
- Moderation is a complex and delicate subject. It's being done by volunteers who might not always agree with each other
- or be aware of some issues. If you think your account didn't breach our Terms of Service,
- please respond to this email and we might get another look in a bigger group.
report:
action: 'Reportar abuso'
diff --git a/locale/et/translations.suml b/locale/et/translations.suml
index a779766e0..6439f0410 100644
--- a/locale/et/translations.suml
+++ b/locale/et/translations.suml
@@ -71,7 +71,6 @@ pronouns:
description: >
Even though for many people it's incredibly important that people use specific pronouns to talk about them,
others don't mind being addressed in any way – as long as the context is clear as to who one talks about.
- options: 'check out the options [share]{/pronouns=here}.'
others: ''
othersRaw: ''
or: 'või'
@@ -613,15 +612,6 @@ profile:
description: 'Kirjeldus'
names: 'Nimed'
pronouns: 'Asesõnad'
- pronounsInfo: >
- You can enter a pronoun (eg. “they” or “she/her”)
- or a link (eg. “https://en.pronouns.page/e”)
- or the custom five forms (eg. “ze/zem/zir/zirs/zirself”).
- Keep in mind that all five forms are required in that case,
- otherwise the app can only guess what exactly do you mean.
- You can also use {/pronouns#generator=the generator} to fill out sentences with custom forms.
- If your pronouns follow the {/pronouns#nameself=nameself pattern},
- you can also use a colon shorthand (eg. “:star”).
pronounsNotFound: 'Unrecognised format. Please check out the instruction above.'
words: 'Sõnad'
wordsColumnHeader: 'Veeru päis'
diff --git a/locale/fr/translations.suml b/locale/fr/translations.suml
index 65a2630a3..a984ae28e 100644
--- a/locale/fr/translations.suml
+++ b/locale/fr/translations.suml
@@ -570,7 +570,8 @@ profile:
sensitive:
header: 'Avertissement de contenu'
info: >
- Certains contenus peuvent être autorisés par nos {/terms=Conditions d'utilisation}, mais ne pas convenir aux
+ Certains contenus peuvent être autorisés par nos {/termes=Conditions d'utilisation},
+ mais ne pas convenir aux
mineurs, être potentiellement déclencheurs pour les personnes souffrant de traumatismes, etc. Veuillez
respecter les personnes visitant votre carte et les avertir à l'avance. Des exemples de CW pourraient être
"mention d'alcool", "insinuations sexuelles", "mention d'une situation queerphobe".
@@ -615,7 +616,7 @@ profile:
Vous pouvez utiliser ce site pour créer votre carte, {/@example=comme celle ci},
avec vos noms, pronoms, drapeaux, mots préférés, etc…
Vous pourrez ensuite copier le lien dans votre bio ou dans vos signatures de mail.
- Créez votre compte {/account=ici}.
+ Créez votre compte {/compte=ici}.
example: 'Voir un exemple de carte'
bannerButton: 'Créer une carte'
@@ -710,7 +711,7 @@ confirm:
terms:
header: 'Conditions d''utilisation'
lastUpdate: 'Dernière mise à jour'
- consent: 'En vous inscrivant, vous acceptez les {/terms=Conditions d''utilisation}.'
+ consent: 'En vous inscrivant, vous acceptez les {/termes=Conditions d''utilisation}.'
update:
header: 'Nous avons mis à jour nos conditions d''utilisation.'
intro: >
@@ -783,7 +784,7 @@ ban:
termsIntro: 'Selon nos {/termes=Termes de service}'
appeal: >
La modération est un sujet complexe et délicat. Elle est assurée par des bénévoles qui ne sont pas toujours d'accord entre elleux
- ou ne sont pas toujours au courant de certains problèmes. Si vous pensez que votre compte n'a pas enfreint nos {/terms=Conditions d'utilisation},
+ ou ne sont pas toujours au courant de certains problèmes. Si vous pensez que votre compte n'a pas enfreint nos {/termes=Conditions d'utilisation},
veuillez nous contacter à {mailto:contact@pronouns.page=contact@pronouns.page} et nous pourrons peut-être nous pencher à nouveau sur la question au sein d'un groupe plus important.
appealEmail: >
La modération est un sujet complexe et délicat. Elle est assurée par des bénévoles qui ne sont pas toujours d'accord entre elleux
diff --git a/locale/ja/translations.suml b/locale/ja/translations.suml
index 7ff606710..658c20d75 100644
--- a/locale/ja/translations.suml
+++ b/locale/ja/translations.suml
@@ -545,7 +545,7 @@ profile:
hide: 'カードをぼかす'
display: 'カードを続ける'
info: >
- 一部のコンテンツは{/terms=Terms of Service}で許可されていることがありますが、未成年やPTSDを抱えている人にとって不適切で刺激的になる可能性があります。
+ 一部のコンテンツは{/利用規約=Terms of Service}で許可されていることがありますが、未成年やPTSDを抱えている人にとって不適切で刺激的になる可能性があります。
あなたのカードを訪問する人に敬意を払い、事前に警告してください。コンテンツの警告の例としては「アルコールの言及」、「性的ほのめかし」、「同性愛嫌悪の状況についての言及」などが挙げられます。
flagsCustomForm:
label: 'ラベル名'
@@ -754,7 +754,7 @@ ban:
# TODO
appeal: >
Moderation is a complex and delicate subject. It's being done by volunteers who might not always agree with each other
- or be aware of some issues. If you think your account didn't breach our {/terms=Terms of Service},
+ or be aware of some issues. If you think your account didn't breach our {/利用規約=Terms of Service},
please contact us at {mailto:contact@pronouns.page=contact@pronouns.page} and we might get another look in a bigger group.
appealEmail: >
Moderation is a complex and delicate subject. It's being done by volunteers who might not always agree with each other
@@ -766,7 +766,7 @@ report:
comment: 'このプロフィールのどこが問題かを簡潔に書いてください。'
confirm: '@%username%のプロフィールを報告してもよろしいですか?'
sent: '報告が送信されました。ご協力ありがとうございました!'
- terms: '{/terms=利用規約}で何が禁止されているかを確認してください:'
+ terms: '{/利用規約=利用規約}で何が禁止されているかを確認してください:'
hoarding: 'ユーザー名が他の人に予約されているという報告はしないでください。一定期間利用がないカードなしのアカウントは自動的に削除されます。報告しても削除が早くなることはありません。'
flags:
diff --git a/locale/lad/translations.suml b/locale/lad/translations.suml
index 8a6e59d25..eabbe06aa 100644
--- a/locale/lad/translations.suml
+++ b/locale/lad/translations.suml
@@ -502,7 +502,7 @@ profile:
Puedes tambien uzar muestro sitio internetiko para krear una karta {/@example=komo esta},
ke kontenga tus nombres, pronombres, bandieras de orgolyo, biervos preferidos ets.
Dospues podras meter un atadijo a la karta en tu biografia o tu sinyatura de posta elektronika.
- Simplemente krea un kuento {/account=aki}.
+ Simplemente krea un kuento {/kuento=aki}.
bannerButton: 'Krear una karta'
card:
link: 'Imaje de la karta'
@@ -624,15 +624,6 @@ ban:
header: 'Tu profil no se amostrara a dinguno.'
banned: 'Tu profil no se amostrara a dinguno.'
termsIntro: 'De akodro kon muestros {/terminos=Terminos de Servisio}:'
- # TODO
- appeal: >
- Moderation is a complex and delicate subject. It's being done by volunteers who might not always agree with each other
- or be aware of some issues. If you think your account didn't breach our {/terms=Terms of Service},
- please contact us at {mailto:contact@pronouns.page=contact@pronouns.page} and we might get another look in a bigger group.
- appealEmail: >
- Moderation is a complex and delicate subject. It's being done by volunteers who might not always agree with each other
- or be aware of some issues. If you think your account didn't breach our Terms of Service,
- please respond to this email and we might get another look in a bigger group.
report:
action: 'Denusyar abuzo'
diff --git a/locale/nl/translations.suml b/locale/nl/translations.suml
index 650ec5e78..26015c72a 100644
--- a/locale/nl/translations.suml
+++ b/locale/nl/translations.suml
@@ -638,7 +638,7 @@ confirm:
terms:
header: 'Gebruiksvoorwaarden'
lastUpdate: 'Laatst bijgewerkt'
- consent: 'Door te registreren accepteer je de {/terms=gebruiksvoorwaarden}.'
+ consent: 'Door te registreren accepteer je de {/voorwaarden=gebruiksvoorwaarden}.'
privacy:
header: 'Privacy Policy' # TODO
@@ -706,7 +706,7 @@ ban:
# TODO
appeal: >
Moderation is a complex and delicate subject. It's being done by volunteers who might not always agree with each other
- or be aware of some issues. If you think your account didn't breach our {/terms=Terms of Service},
+ or be aware of some issues. If you think your account didn't breach our {/voorwaarden=Terms of Service},
please contact us at {mailto:contact@pronouns.page=contact@pronouns.page} and we might get another look in a bigger group.
appealEmail: >
Moderation is a complex and delicate subject. It's being done by volunteers who might not always agree with each other
@@ -718,7 +718,7 @@ report:
comment: 'Leg kort uit wat ongepast is aan dit profiel'
confirm: 'Weet je zeker dat je @%username% wilt rapporteren?'
sent: 'Jouw rapportering was verzonden. Bedankt voor je hulp!'
- terms: 'Houd datgene wat verboden is volgens onze {/terms=Gebruiksvoorwaarden} in jouw achterhoofd.'
+ terms: 'Houd datgene wat verboden is volgens onze {/voorwaarden=Gebruiksvoorwaarden} in jouw achterhoofd.'
hoarding: ' Rapporteer alsjeblieft geen gebruikers die gebruikersnamen hamsteren. We verwijderen automatisch accounts zonder kaarten na een periode van inactiviteit. Jouw melding zal dit proces niet verspoedigen.'
translationMode:
diff --git a/locale/no/translations.suml b/locale/no/translations.suml
index 4a032bbd5..33e5ad076 100644
--- a/locale/no/translations.suml
+++ b/locale/no/translations.suml
@@ -398,7 +398,7 @@ contact:
header: 'Lag en ny språk versjon'
description: >
Intruksjoner for å lage en ny språk versjon er tilgjengelige {https://en.pronouns.page/new-version=her}.
- Før du starter, vennligst {/contact=kontakt oss} for å koordinere med andre om det.
+ Før du starter, vennligst {/kontakt=kontakt oss} for å koordinere med andre om det.
translations:
header: 'Legg til eller rett oversettelser'
description: >
@@ -543,7 +543,7 @@ profile:
Du kan også bruke nettsiden vår til å lage et kort, {/@example=sånn som denne},
som inneholder navnene dine, pronomen, pride flagg, likte ord, osv.
Så kan du linke den til din bio eller epost-signatur.
- Bare lag en bruker {/account=her}.
+ Bare lag en bruker {/bruker=her}.
bannerButton: 'Lag et kort'
card:
link: 'Kortbilde'
@@ -646,7 +646,7 @@ crud:
search: 'Søk…'
author: 'Lagt til av'
saved: 'Endringer er lagret!'
- loginRequired: '{/account=Log in} for å'
+ loginRequired: '{/bruker=Log in} for å'
copy: 'Kopier link'
download: 'Last ned'
loadAll: 'Last inn alle…'
@@ -696,7 +696,7 @@ confirm:
terms:
header: 'Vilkår og betingelser'
lastUpdate: 'Sist oppdatert'
- consent: 'Ved å registrere deg sier du ja til våre vilkår og betingelser {/vilkår=vilkår og betingelser}.'
+ consent: 'Ved å registrere deg sier du ja til våre vilkår og betingelser {/vilkar=vilkår og betingelser}.'
privacy:
header: 'Personvernerklæring '
@@ -760,24 +760,13 @@ ban:
confirm: 'Er du sikker på at du vil forby @%username%?'
header: 'Du er forbydd. Profilen din vil ikke bli vist til noen.'
banned: 'Forbydd'
- termsIntro: 'Ifølge våre {/termes=Terms of Service}'
- # TODO
- appeal: >
- Moderation is a complex and delicate subject. It's being done by volunteers who might not always agree with each other
- or be aware of some issues. If you think your account didn't breach our {/terms=Terms of Service},
- please contact us at {mailto:contact@pronouns.page=contact@pronouns.page} and we might get another look in a bigger group.
- appealEmail: >
- Moderation is a complex and delicate subject. It's being done by volunteers who might not always agree with each other
- or be aware of some issues. If you think your account didn't breach our Terms of Service,
- please respond to this email and we might get another look in a bigger group.
+ termsIntro: 'Ifølge våre {/vilkar=Terms of Service}'
report:
action: 'Rapporter problem'
comment: 'Vennligst forklar enkelt hva som er galt med denne profilen'
confirm: 'Er du sikker på at du vil rapportere @%username%?'
sent: 'Rapport sendt. Takk for hjelpen!'
- terms: 'Keep in mind what''s forbidden according to our {/terms=Terms of Service}' # TODO
- hoarding: 'Please don''t report for “username hoarding”. We automatically remove accounts without cards after a period of inactivity. Your report will not make it faster.' # TODO
translationMode:
changes: 'Endringer'
diff --git a/locale/pl/translations.suml b/locale/pl/translations.suml
index 927f47f2b..0d372c115 100644
--- a/locale/pl/translations.suml
+++ b/locale/pl/translations.suml
@@ -1368,7 +1368,7 @@ contact:
header: 'Stwórz nową wersję językową'
description: >
Instrukcje tworzenia nowej wersji językowej strony dostępne są {https://en.pronouns.page/new-version=tutaj}.
- Zanim zaczniesz pracę, {/contact=skontaktuj się z nami}, by skoordynować z innymi osobami.
+ Zanim zaczniesz pracę, {/kontakt=skontaktuj się z nami}, by skoordynować z innymi osobami.
technical:
header: 'Zgłoś pull requesta'
description: >
@@ -1834,7 +1834,7 @@ terms:
translationDisclaimer: >
Poniższy tekst jest wyłącznie pomocniczym tłumaczeniem.
Jedyną prawnie wiążącą wersją Regulaminu jest wersja anglojęzyczna dostępna
- {https://en.pronouns.page/terms=tutaj}.
+ {https://en.pronouns.page/regulamin=tutaj}.
content:
intro: >
Poniższy Regulamin reguluje Twój dostęp do oraz warunki użytkowania Usług dostępnych poprzez stronę
@@ -1901,10 +1901,6 @@ terms:
advertisement: 'reklamy'
copyright: 'naruszenia praw autorskich i znaków towarowych'
miscellaneous: 'inne'
- # TODO
- violationsStrict: >
- We reserve the right to interpret as hate-speech all instances of non-obvious, concealed hate speech
- (eg. telling some people to “DNI” because of their queer identity, transphobic dogwhistles like “superstraight” or “semibisexual”, etc.).
responsibility: >
Ponosisz odpowiedzialność za Treść, którą umieszczasz w Usługach.
Jeśli złamiesz ten Regulamin, usuniemy Twoje Treści bez uprzedniego powiadomienia,
@@ -2022,15 +2018,6 @@ ban:
header: 'Twoje konto jest zablokowane. Twoje profile nie są widoczne publicznie.'
banned: 'Konto nieaktywne'
termsIntro: 'Zgodnie z naszym {/regulamin=Regulaminem}'
- # TODO
- appeal: >
- Moderation is a complex and delicate subject. It's being done by volunteers who might not always agree with each other
- or be aware of some issues. If you think your account didn't breach our {/terms=Terms of Service},
- please contact us at {mailto:contact@pronouns.page=contact@pronouns.page} and we might get another look in a bigger group.
- appealEmail: >
- Moderation is a complex and delicate subject. It's being done by volunteers who might not always agree with each other
- or be aware of some issues. If you think your account didn't breach our Terms of Service,
- please respond to this email and we might get another look in a bigger group.
report:
action: 'Zgłoś profil'
diff --git a/locale/pt/translations.suml b/locale/pt/translations.suml
index 37e0be50d..6c888c2f4 100644
--- a/locale/pt/translations.suml
+++ b/locale/pt/translations.suml
@@ -439,7 +439,7 @@ contact:
header: 'Crie uma nova versão em outro idioma '
description: >
Instruções para criar uma nova versão em outro idioma estão disponíveis
- {https://en.pronouns.page/new-version=aqui}. Antes de começar, por favor, {/contact=contate-nos} para que
+ {https://en.pronouns.page/new-version=aqui}. Antes de começar, por favor, {/contato=contate-nos} para que
assim a gente possa coordenar com outres um trabalho em conjunto.
entries:
header: 'Adicione páginas'
@@ -665,7 +665,7 @@ profile:
Você pode usar o nosso site para criar cartões, {/@example=como esse},
que está incluindo seus nomes, prononomes, bandeiras, palavras de que se gosta, etc.
Depois pode por no seu bio ou rodapé de e-mail.
- Somente crie a sua conta {/account=aqui}.
+ Somente crie a sua conta {/conta=aqui}.
bannerButton: 'Crie um cartão'
card:
link: 'Imagem do cartão'
@@ -682,7 +682,7 @@ profile:
sensitive:
header: 'Aviso de conteúdo'
info: >
- Alguns conteúdos são permitidos pelos nossos {/terms=Termos de Serviço}, mas que ainda podem não ser
+ Alguns conteúdos são permitidos pelos nossos {/termos=Termos de Serviço}, mas que ainda podem não ser
apropriados para menores de idade, potencialmente engatilhando pessoas com traumas, etc. Por favor, aja com
respeito com quem visita seu cartão e avise previamente sobre tal conteúdo. Exemplos de Aviso de Conteúdo
podem ser a "menção ao álcool", "insinuações sexuais", "menção á uma situação queerfóbica"...
@@ -774,7 +774,7 @@ confirm:
terms:
header: 'Termos de Serviço'
lastUpdate: 'Atualizados pela última vez em'
- consent: 'Ao se registrar, você aceita os {/terinos=Termos de Serviço}.'
+ consent: 'Ao se registrar, você aceita os {/termos=Termos de Serviço}.'
privacy:
header: 'Política de Privacidade' # TODO
@@ -842,15 +842,6 @@ ban:
header: 'Seu perfil não mais aparecerá em nosso site.'
banned: 'Seu perfil não mais aparecerá em nosso site.'
termsIntro: 'De acordo com nossos {/termos=termos de uso}'
- # TODO
- appeal: >
- Moderation is a complex and delicate subject. It's being done by volunteers who might not always agree with each other
- or be aware of some issues. If you think your account didn't breach our {/terms=Terms of Service},
- please contact us at {mailto:contact@pronouns.page=contact@pronouns.page} and we might get another look in a bigger group.
- appealEmail: >
- Moderation is a complex and delicate subject. It's being done by volunteers who might not always agree with each other
- or be aware of some issues. If you think your account didn't breach our Terms of Service,
- please respond to this email and we might get another look in a bigger group.
report:
action: 'Reportar abuso'
diff --git a/locale/sv/translations.suml b/locale/sv/translations.suml
index 5f57618d1..cb815a91b 100644
--- a/locale/sv/translations.suml
+++ b/locale/sv/translations.suml
@@ -570,7 +570,7 @@ profile:
eller alla formerna (t.ex. “hen/henom/hens”).
Kom ihåg att alla tre formerna är nödvändiga i sådana fall,
annars kommer appen gissa vilka pronomen det är du menar.
- Du kan även använda {/pronouns#generator=generatorn} för att fylla ut meningar med anpassade former.
+ Du kan även använda {/pronomen#generator=generatorn} för att fylla ut meningar med anpassade former.
pronounsNotFound: 'Vi kan inte hitta någonting om dessa pronomen!'
words: 'Ord'
wordsColumnHeader: 'Kolumnrubrik'
@@ -727,7 +727,7 @@ crud:
search: 'Sök…'
author: 'Tillagd av'
saved: 'Ändringarna har sparats!'
- loginRequired: '{/account=Logga in} För att skicka in ett nytt inlägg'
+ loginRequired: '{/konto=Logga in} För att skicka in ett nytt inlägg'
copy: 'Kopiera länk'
download: 'Ladda ner'
loadAll: 'Ladda alla...'
diff --git a/locale/vi/translations.suml b/locale/vi/translations.suml
index 28d90b5ea..f4ddbd6a7 100644
--- a/locale/vi/translations.suml
+++ b/locale/vi/translations.suml
@@ -624,7 +624,7 @@ profile:
pronounsInfo: >
Bạn có thể nhập một danh xưng (ví dụ “anh ấy” hoặc “cô ấy”)
hoặc một đường link (ví dụ “https://vi.pronouns.page/:Vanh”).
- Bạn cũng có thể dùng {/pronouns#generator=trình tạo danh xưng} để điền vào câu với các danh xưng tùy ý.
+ Bạn cũng có thể dùng {/danh-xưng#generator=trình tạo danh xưng} để điền vào câu với các danh xưng tùy ý.
Nếu danh xưng của bạn là {/tránh=tên},
bạn cũng có thể sử dụng dấu hai chấm (ví dụ “:Vanh”).
pronounsNotFound: 'Định dạng không được chấp nhận. Vui lòng xem hướng dẫn ở trên.'
diff --git a/nuxt.config.js b/nuxt.config.js
index c1c91f38d..4d48a2bd1 100644
--- a/nuxt.config.js
+++ b/nuxt.config.js
@@ -4,6 +4,7 @@ import { loadSuml } from './server/loader.js';
import autoprefixer from 'autoprefixer';
import fs from 'fs';
import path from 'path';
+import rtlcss from 'rtlcss';
import { buildDict, buildList } from './src/helpers.js';
import buildLocaleList from './src/buildLocaleList.js';
import formatError from './src/error.js';
@@ -18,6 +19,9 @@ const description = translations.description;
const keywords = (translations?.seo?.keywords || []).join(', ');
const banner = `${process.env.BASE_URL}/api/banner/zaimki.png`;
const colour = '#C71585';
+
+const __dirname = new URL('.', import.meta.url).pathname;
+
const logo = fs.readFileSync(`${__dirname}/static/logo/logo.svg`).toString('utf-8')
.replace('/>', 'fill="currentColor"/>');
const versionFile = `${__dirname}/cache/version`;
@@ -88,7 +92,7 @@ const postCssPlugins = [
];
if (config.dir === 'rtl') {
- postCssPlugins.push(require('rtlcss'));
+ postCssPlugins.push(rtlcss);
}
const getAllFiles = function (dirPath, arrayOfFiles) {
diff --git a/test/locales/translations.test.js b/test/locales/translations.test.js
index f08a4d6e6..4aa6f8b70 100644
--- a/test/locales/translations.test.js
+++ b/test/locales/translations.test.js
@@ -1,7 +1,9 @@
-import { expect, test } from '@jest/globals';
+import { afterEach, beforeEach, describe, expect, jest, test } from '@jest/globals';
+import pathToRegexp from 'path-to-regexp';
import { loadSumlFromBase } from '../../server/loader.js';
import locales from '../../locale/locales.js';
+import { deepGet, deepListKeys } from '../../src/helpers.js';
const baseTranslations = loadSumlFromBase('locale/_base/translations');
const typeFlexibleKeys = new Set(['home.generator.alt']);
@@ -52,9 +54,75 @@ function recursivelyValidateSchema(actual, base, parentKey = '') {
return messages;
}
-test.each(locales)('translations of $code match schema of base translations', ({ code }) => {
+function toBeValidPath(actual, paths, key) {
+ const encoded = encodeURI(actual);
+ const pass = paths.some((matcher) => encoded.match(matcher));
+ if (pass) {
+ return {
+ message: () => `expected ${this.utils.printReceived(actual)} inside ${this.utils.printReceived(key)} ` +
+ 'to not be a known internal link',
+ pass: true,
+ };
+ } else {
+ return {
+ message: () => `expected ${this.utils.printReceived(actual)} inside ${this.utils.printReceived(key)} ` +
+ 'to be a known internal link',
+ pass: false,
+ };
+ }
+}
+
+const pathRegex = /\{(\/[^}]+?)(?:#[^}]+)?=[^}]+\}/g;
+
+describe.each(locales)('translations for $code', ({ code, published }) => {
+ const config = loadSumlFromBase(`locale/${code}/config`);
const translations = loadSumlFromBase(`locale/${code}/translations`);
- expect(translations).toMatchBaseTranslationSchema();
+
+ beforeEach(() => {
+ jest.unstable_mockModule('../../server/loader.js', () => {
+ return {
+ loadSuml(name) {
+ if (name === 'config') {
+ return config;
+ } else if (name === 'translations') {
+ return translations;
+ }
+ },
+ };
+ });
+ });
+
+ afterEach(() => {
+ jest.resetModules();
+ });
+
+ test('match schema of base translations', () => {
+ expect(translations).toMatchBaseTranslationSchema();
+ });
+
+ test('contain valid internal links', async () => {
+ if (!published) {
+ // unpublished versions are ignored for now because they have a lot of errors
+ return;
+ }
+
+ // use query string to force reload
+ const { default: nuxtConfig } = await import(`../../nuxt.config.js?${code}`);
+
+ const routes = [];
+ nuxtConfig.router.extendRoutes(routes, () => null);
+ const paths = routes.filter((route) => route.name !== 'all').map((route) => pathToRegexp(route.path));
+
+ for (const key of deepListKeys(translations)) {
+ const translation = deepGet(translations, key);
+ if (typeof translation !== 'string') {
+ continue;
+ }
+ for (const match of translation.matchAll(pathRegex)) {
+ expect(match[1]).toBeValidPath(paths, key);
+ }
+ }
+ });
});
-expect.extend({ toMatchBaseTranslationSchema: toMatchBaseTranslationsSchema });
+expect.extend({ toMatchBaseTranslationSchema: toMatchBaseTranslationsSchema, toBeValidPath });