Come dice già il titolo: sembra che le stringhe per i titoli nei grafici nella dashboard della community health non siano localizzate:
Quando si passa alla scheda dei report, vengono visualizzati i titoli localizzati:
Tuttavia, quando si guarda un singolo report/grafico, di nuovo viene utilizzato il titolo inglese e sia il giorno che il conteggio nelle intestazioni della tabella non sono localizzati:
1 Mi Piace
tvavrda
(Tomas Vavrda)
31 Dicembre 2024, 11:41am
2
Questo è ancora il caso. Notato anche qui: Report locale copies do not update with user locale .
Può essere risolto?
1 Mi Piace
sam
(Sam Saffron)
1 Gennaio 2025, 10:53pm
3
Ho segnalato questo al team, ma non c’è una tempistica su quando potremo risolvere questo problema.
Ti piacerebbe provare a creare una PR per migliorare questo?
2 Mi Piace
tvavrda
(Tomas Vavrda)
1 Gennaio 2025, 11:13pm
5
Potrebbe essere difficile per me
E mentre parliamo, l’e-mail di notifica che ho ricevuto non ha l’intestazione In Reply To localizzata, sebbene l’e-mail altrimenti sembri tradotta.
4 Mi Piace
martin
(Martin Brennan)
2 Gennaio 2025, 2:22am
6
Questo dovrebbe risolvere il problema del report:
main ← fix/report-i18n
opened 02:09AM - 02 Jan 25 UTC
Our bulk report endpoint uses `hijack`, which does not
use the current user's l… ocale via the `with_resolved_locale`
method in `ApplicationController`. This is happening because
we are doing `around_action` to set the locale, then calling
the code in the block inside the action directly when we use
`hijack`.
We can fix this by capturing `I18n.locale` when starting the
hijack then using `I18n.with_locale` when evaluating the
block inside `hijack`, this way the translations will always
use the correct locale based on the current user.
c.f. https://meta.discourse.org/t/titles-on-graphs-in-community-health-dashboard-are-not-localized/302776/5
Per il problema “In Reply To”, sembra che le nostre traduzioni ceche siano un po’ carenti, il nostro file server.de.yml tedesco ha user_notifications.in_reply_to ma server.cs.yml no. Le traduzioni tornano all’inglese quando le chiavi mancano.
5 Mi Piace
tvavrda
(Tomas Vavrda)
2 Gennaio 2025, 8:49am
7
Mi dispiace, hai ragione. Mi sono confuso. Ho tradotto la frase solo 4 giorni fa e ieri sembrava che avrebbe dovuto funzionare. Le traduzioni non sono ancora state confermate, però.
Grazie per la correzione, funziona!!
1 Mi Piace
tvavrda
(Tomas Vavrda)
2 Gennaio 2025, 2:04pm
8
Ho notato che le descrizioni comandi non sono tradotte.
Ho trovato anche il pezzo di codice:
return i18n("admin.dashboard.reports.trend_title", {
percent,
prev,
current,
});
}
changeTitle(valAtT1, valAtT2, prevPeriodString) {
const change = this.percentChangeString(valAtT1, valAtT2);
let title = "";
if (change) {
title += `${change} change. `;
}
title += `Was ${number(valAtT1)} ${prevPeriodString}.`;
return title;
}
@discourseComputed("yesterdayCount")
yesterdayCountTitle(yesterdayCount) {
return this.changeTitle(this.valueAt(2), yesterdayCount, "two days ago");
Sono solo un esperto di c#, quindi non sono in grado di creare PR.
2 Mi Piace
martin
(Martin Brennan)
3 Gennaio 2025, 12:09am
9
Dai, C# è abbastanza simile a Javascript! Grazie per averlo trovato, farò una PR per correggere il JS e usare I18n.
1 Mi Piace
martin
(Martin Brennan)
3 Gennaio 2025, 1:04am
10
Questo risolverà anche l’altro problema, anche se non vedrai alcun cambiamento pratico fino al nostro prossimo ciclo di traduzioni:
main ← fix/report-percent-tooltip
opened 01:03AM - 03 Jan 25 UTC
Use i18n in the JS code instead of concatenating English
strings.
c.f. https… ://meta.discourse.org/t/titles-on-graphs-in-community-health-dashboard-are-not-localized/302776/8?u=martin
1 Mi Piace
tvavrda
(Tomas Vavrda)
3 Gennaio 2025, 10:08am
11
Non è tutto. Ho commentato la PR anche se è stata unita, non sono sicuro che tu possa individuarlo.
Ci sono altre traduzioni di seguito (“due settimane fa” e “nel precedente periodo di 30 giorni”).
2 Mi Piace
martin
(Martin Brennan)
6 Gennaio 2025, 4:48am
12
Questo prossimo PR dovrebbe risolvere quei problemi, così come i commenti aggiunti da Gerhard!
main ← ux/more-admin-dash-translations
opened 04:47AM - 06 Jan 25 UTC
Followup 8d5c4ecc3398611764a4459c0e92f0fb90edd90f
Implement review suggestion… s from https://github.com/discourse/discourse/pull/30541
after merge, and also fix other hardcoded strings on this
dashboard.
2 Mi Piace
tvavrda
(Tomas Vavrda)
10 Gennaio 2025, 4:09pm
13
Sembrano esserci altri argomenti che si riferiscono allo stesso problema. Non voglio sollevarli tutti. Cosa è giusto fare? Lasciarli stare o dovrebbero essere in qualche modo aggiornati o chiusi?
Reports, along with their locale strings, are being cached in the server’s locale, such that users with a differing locale will see an incorrect locale on some reports - should Discourse also pass a localization string in reports so that reports are properly localized?
EG, this is a screenshot of a default EN site, with a sr user:
[Screen Shot 2019-12-13 at 11.37.29 AM]
Hello community ,
I noticed that the strings in the admin/moderator dashboard are not being translated. Tried multiple languages and it keeps those strings in English.
[image]
I wanted to add translations to those strings in Crowdin but those strings already have translations. So I ran a search query and found out this topic:
It looks like there was a PR but was not merged at the end.
Was there any progress with that issue?
Thank you
I have found some strings that are translated in Transifex, but doesn’t appear translated in production. They are in Admin>Dashboard: Signups, Topics, Posts, Daily Engaged Users, New Contributors, Top Referred Topics, Trending Search Terms, Users per Type… (with its corresponding tooltips).
This issue is common to all languages. I have checked different locales (French, German, Catalan…), and the strings always appear untranslated.
2 Mi Piace
Prima di tutto: grazie mille! Non ho avuto abbastanza tempo per commentare nel frattempo, ma vedo che la localizzazione è applicata molto più ampiamente nella dashboard ora.
Una piccola cosa che ho ancora notato: il link di ritorno alla pagina di panoramica dei report non sembra essere localizzato.
Anche le raccomandazioni relative alle impostazioni del sito appaiono in inglese:
Moin
18 Gennaio 2025, 4:25pm
15
Lo sono. Puoi vederlo quando abiliti “localizzazione dettagliata ” perché hanno un numero.
Queste sono solo nuove stringhe, entrambe sono state tradotte in tedesco 4 giorni fa, ma le traduzioni vengono unite solo una volta alla settimana. Quindi le stringhe nuovissime, che sono state aggiunte dopo che le traduzioni sono state unite (o leggermente prima e nessuno ha avuto il tempo di tradurle in tempo) tornano all’inglese. La traduzione verrà aggiunta la prossima volta che le traduzioni verranno unite (di solito il martedì ) e le vedrai dopo l’aggiornamento.
2 Mi Piace