jitsi / jitsi-meet

Jitsi Meet - Secure, Simple and Scalable Video Conferences that you use as a standalone app or embed in your web application.
https://jitsi.org/meet
Apache License 2.0
22.1k stars 6.58k forks source link

Polish language detection does not work properly on Google Chrome. #14764

Open Maniues opened 1 month ago

Maniues commented 1 month ago

What happened?

Jitsi Meet does not detect Polish language encoded in navigator.language as pl-PL and sets English language.

On Firefox or MS Edge, Polish is encoded as pl and Jitsi Meet's language detection properly works with these browsers.

Platform

Browser / app / sdk version

Chrome 124.0.6367.208 / 125.0.6422.61 (tested on both)

Relevant log output

No response

Reproducibility

More details?

Tested on meet.jit.si and on internal deployment.

damencho commented 1 month ago

Have you tried in incognito?

Maniues commented 1 month ago

Yes, I did

Maniues commented 1 month ago

I checked, and it turned out that the problem occurs in incognito mode, but not necessarily in other modes.

I still find this a problem because in incognito mode the language value is pl-PL and our deployment is meant to use Polish language in this case.

damencho commented 1 month ago

What are the values of navigator.languages, navigator.userLanguage and navigator.language in the browsers it work and in the browsers it does not work?

Maniues commented 1 month ago

For browser with incorrect language: navigator.languages: ['pl-PL'] navigator.userLanguage: undefined navigator.language: 'pl-PL'

For browser with correct language: navigator.languages: ['pl-PL', 'pl', 'en-US', 'en'] navigator.userLanguage: undefined navigator.language: 'pl-PL'

saghul commented 1 month ago

@damencho IIRC there was a similar report for Spanish, being es-ES.

damencho commented 1 month ago

Yeah. And a PR will look at it when I find some time

saghul commented 1 month ago

Excellent, thanks!

damencho commented 1 month ago

@Maniues How did you change the language in chrome? If I go and change it via settings : image

I get: navigator.language: 'pl'

I wonder how do you get the pl-PL setting?

Maniues commented 1 month ago

I don't change my language, since I'm Polish. Please note that it only occurs in incognito mode.

I'll check this and let you know what settings I'm chrome return pl-PL l.

Maniues commented 1 month ago

I don't have any specific settings. This parameter may be controlled by Chrome 's default installer and the user's system location.

saghul commented 1 month ago

Does it happen in normal mode? What value do you get for the language in that case?

Maniues commented 1 month ago

For browser with incorrect language: navigator.languages: ['pl-PL'] navigator.userLanguage: undefined navigator.language: 'pl-PL'

For browser with correct language: navigator.languages: ['pl-PL', 'pl', 'en-US', 'en'] navigator.userLanguage: undefined navigator.language: 'pl-PL'

These are all values I got. Browser with correct language = normal mode, incorrect = incognito

Maniues commented 3 weeks ago

@damencho @saghul is there any update about this case available?