Group name is translated in general but not in context47 45 Browser Info Environment
the group name "Administrators" is translated in user groups (in my case german: "Administratoren"). but not translated in some context e.g. in "Site Access" or in "View User" (see attached images).
I hope it's the right here place to spotlight this ;)
Indeed there are actually a quite a few places Group Names are not translated. I believe the only place was actually added around version 5.5 oddly enough with this commit
Since then, as I'm sure you are aware there has been much discussion about how we go about translating dynamic data.
That was just a quick grep, but these do not appear to be translating the group name. That said, it does appear to go along with what was discussed earlier about attribute names etc, that this should change.
I'd love to hear some insight from some of our more international community members on how we'd like to deal with with(tc() etc for context "GroupName"?).
I'd go for tc with a 'GroupName' context.
Extending the Localizer package would easily add support for this.
PS The Localizer it's still under review in the PRB, but you can find it also here:
BTW: there's still something to fix, namely about the GroupSearch::filterByKeywords method...
That was quite fast. I'm not sure about the Group::add() code? Why are we trying to translate that into the database? I thought we wanted to stay away from that? Are we just hoping that it will always be set to en_US?
Just to let you know that this will end up waiting until the next release as we kind of ran out of time on it with the additional changes beyond just the view wrapping.
I added tc() to Group::add because it's the only way we can extract translatable strings to be sent to Transifex.
As I said on GitHub (https://github.com/concrete5/concrete5/pull/1313#discussion_r6000310... ), I tested a fresh 5.6.2 installation with locale it_IT, and groups have been saved in en_US anyway. By tomorrow I'll do another fresh install to check again this and track if and when concrete5 resets (correctly) the locale to en_US when running setup routines.