tutao / tutanota

Tuta is an email service with a strong focus on security and privacy that lets you encrypt emails, contacts and calendar entries on all your devices.
https://tuta.com
GNU General Public License v3.0
6.05k stars 522 forks source link

No language match on Belarusian Linux #4197

Open DECHT opened 2 years ago

DECHT commented 2 years ago

The Tutanota Client for Linux v3.96.6 does not match the system language (Belarusian) of my Ubuntu 22.04, but it works if I change my system language to German or Ukrainian. So the automatic language is English in case I'm using Belarusian Ubuntu.

Even if I choose the Belarusian language in Tutanota, the months and days in calendar are still shown in English. There is no such a problem if I use German or Ukrainian translation.

image

I do not know, whether there is such a bug on Android, because at this moment the v3.96.6 is not available on F-Droid.

charlag commented 2 years ago

Dates are formatted using Intl.DateTimeFormat so it might depend on your system supporting be as a language. I checked and be which we use as the language tag is a valid BCP 47 language tag.

We will check but I think that's dependent on the system.

DECHT commented 2 years ago

Hmm... I have tried it with date in my terminal, it looks well:

image

DECHT commented 2 years ago

Maybe it should be something like be_BY? (BY not as Bayern, but from the sovietic "BYelorussia") :)

image

charlag commented 2 years ago
> new Intl.DateTimeFormat("be").format(new Date())
"23.5.2022"
> new Intl.DateTimeFormat("be_BY").format(new Date())
Uncaught RangeError: invalid language tag: "be_BY"
    <anonymous> debugger eval code:1
debugger eval code:1:1
charlag commented 2 years ago

But also (on my system)?

> new Intl.DateTimeFormat("be", {day: "numeric", month: "long"}).format(new Date())
"23 мая"

seems correct :thinking:

DECHT commented 2 years ago

It also seems to work with be-BY, but not with be_BY. I have no idea. Would ask my colleagues.

image

DECHT commented 2 years ago

It is a bit similar to Android: on Android the interface language matches to the system language, but the months are shown like "M01" for January, "M12" for December.