Showing posts with label Things They Should Invent. Show all posts
Showing posts with label Things They Should Invent. Show all posts

Tuesday, November 21, 2023

Firefox's translation feature needs to be suppressed on pages that already have an official target language version

Recent versions of Firefox have a "translate this page" function that pops up if it detects that the webpage is in a language other than the preferred language indicated in your settings.

They need to figure out a way to stop this from automatically popping up when an official version of the page exists in your preferred language.

 
For example, if I, with my default English settings, end up on the French version of the federal government's COVID wastewater monitoring dashboard, a conspicuous "Translate this page" bubble pops up front and centre. 

This is a problem, because an official English version of the page exists. You can access it by clicking the English link on the top right. And the automatically translated version is never going to be as good or as authoritative as the official English version.

screenshot of the Tableau de bord sur la vigie de la COVID-19 dans les eaux usées, with the English link at the top right highlighted
Screenshot of linked page, with the English link at the top right highlighted


 
People outside of translation/language intersection spaces don't always know that pages with multiple language versions exist, but they are common, especially in institutional (government, education, etc.) spaces that provide official information.
 
Firefox's translation feature needs to avoid distracting these uninformed users from the existence of the official multilingual versions that they may not even know to look for.

So how do you do that from a programming perspective?

Preliminary idea to build on: what if the translation feature could detect the name of the target language in the target language? If the user has English set as their default language, it detects the word "English" on the page. Perhaps it could highlight it? Perhaps the translation feature could say "An official version may exist"?

This wouldn't catch every instance. Some websites use abbreviations (en, fr, de, es, pl) and some websites use flags. However, there may be a finite number of ways that these are coded, or commonalities to the scripts used to switch the language, or indicators in the metadata.

Another possibility would be to have the pop-up appear elsewhere on the page (maybe towards the bottom left of the visible portion?) so it's less likely to cover the link to the official version. 

In any case, however well-intentioned this automatic translation feature is, it needs to avoid making it difficult to find the official version of the page in the target language.