Search…

X3 Photo Gallery Support Forums

Search…
 
User avatar
mjau-mjau
X3 Wizard
Topic Author
Posts: 12512
Joined: 30 Sep 2006, 03:37

X3 interface translations [BETA] :de::fr::es::it:

05 Jan 2021, 05:59

Howdy! Hallo! Hola! Bonjour! Ciao!
In release X3.30.0, we added support for interface translations. This means that words used in the X3 website interface like "Images" and "Folders", will automatically translate to the language of the visitors browser. For example, "Images" and "Folders" will display as "Bilder" and "Galerien" in German language browsers. Fully dynamic!

* This feature affects only the X3 website interface and has nothing to do with the panel or publishing your X3 website in multiple languages.

How does it work?
Simple yet effective, languages are stored in CSS files, which are dynamically loaded once the browser-language is detected. If the visitors browser language is not (yet) supported, default language will display (English by default, but can be changed). You can find the language files in /app/public/lang/*.css.

Options
You can find a few options under Settings > Advanced > Interface language. First option "interface language" sets the default language to use if the visitors browser-language is not supported or if "auto language" is disabled. Second option "auto language" will detect visitors browser-language and load appropriate language file if supported.
Image

How to override translations?
Once translation files are properly revised, I am hoping this won't be necessary. Although you can edit the translation files directly, you would then need to clear your browser cache, and these files will get overwritten on X3 updates. If you really need to override a specific translation, you can add it/them to Settings > Custom > Custom CSS like this:
Code
[data-lang="folders"]:after { content: 'alben' !important; }
Translations
I have already added translation files for German, Spanish, French and Italian. Apart from German, which I have had help to translate, other translations are basically done in Google Translate. Below are the translations. Feel free to suggest changes or add new languages! Thnx.

German :flag_de: / Deutsch / de.css
Code
[data-lang="chat"]:after { content: 'chat'; }
[data-lang="comments"]:after { content: 'kommentare'; }
[data-lang="folder"]:after { content: 'galerie'; }
[data-lang="folders"]:after { content: 'galerien'; }
[data-lang="image"]:after { content: 'bild'; }
[data-lang="images"]:after { content: 'bilder'; }
[data-lang="map"]:after { content: 'karte'; }
[data-lang="pause"]:after { content: 'anhalten'; }
[data-lang="play"]:after { content: 'abspielen'; }
[data-lang="styles"]:after { content: 'stile'; }
Spanish :flag_es: / Español / es.css
Code
[data-lang="chat"]:after { content: 'chat'; }
[data-lang="comments"]:after { content: 'comentarios'; }
[data-lang="folder"]:after { content: 'carpeta'; }
[data-lang="folders"]:after { content: 'carpetas'; }
[data-lang="image"]:after { content: 'imagen'; }
[data-lang="images"]:after { content: 'imagenes'; }
[data-lang="map"]:after { content: 'mapa'; }
[data-lang="pause"]:after { content: 'pausar'; }
[data-lang="play"]:after { content: 'reproducir'; }
[data-lang="styles"]:after { content: 'estilos'; }
French :flag_fr: / Français / fr.css
Code
[data-lang="chat"]:after { content: 'chat'; }
[data-lang="comments"]:after { content: 'commentaires'; }
[data-lang="folder"]:after { content: 'dossier'; }
[data-lang="folders"]:after { content: 'dossier'; }
[data-lang="image"]:after { content: 'image'; }
[data-lang="images"]:after { content: 'images'; }
[data-lang="map"]:after { content: 'carte'; }
[data-lang="pause"]:after { content: 'pause'; }
[data-lang="play"]:after { content: 'jouer'; }
[data-lang="styles"]:after { content: 'styles'; }
Italian :flag_it: / Italiano / it.css
Code
[data-lang="chat"]:after { content: 'chat'; }
[data-lang="comments"]:after { content: 'commenti'; }
[data-lang="folder"]:after { content: 'cartella'; }
[data-lang="folders"]:after { content: 'cartelle'; }
[data-lang="image"]:after { content: 'immagine'; }
[data-lang="images"]:after { content: 'immagini'; }
[data-lang="map"]:after { content: 'mappa'; }
[data-lang="pause"]:after { content: 'pausa'; }
[data-lang="play"]:after { content: 'riprodurre'; }
[data-lang="styles"]:after { content: 'stili'; }
 
kmorwath
Posts: 6
Joined: 23 Jan 2020, 15:11

Re: X3 interface translations [BETA] :de::fr::es::it:

08 Jan 2021, 04:10

Hi, thank you for the update and the translations.

In Italian, usually UI actions, when they are verbs, use the "imperative present tense", "second singular person" - i.e. "play" becomes "(you) play (!)" -> "riproduci", instead of "riprodurre" (the infinitive). That's a bit difficult to obtain through an automatic translator, though.

"Pause" -> "Pausa" is OK because in Italian it is usually translated as a noun, as there isn't such simple verb, it would be like "(put on) pause". The other translations are OK.

Other translations that could be useful for the actual UI:

"Share" -> "Condividi"
"Close" -> "Chiudi"
"Zoom" can be kept as it is, it became an Italian word too (otherwise in Italian would become "ingrandisci" when "zooming in" and "riduci" when "zooming out").
"Fullscreen" -> "Schermo intero"
"Block caption" -> "Blocca titolo" o "Blocca didascalia" ("didascalia" is the caption underneath an image).
"Unblock ..." -> "Sblocca ..."

Feel free to ask if more Italian translations are needed.
 
Zorugal
Posts: 7
Joined: 27 Feb 2020, 04:32

Re: X3 interface translations [BETA] :de::fr::es::it:

08 Jan 2021, 12:38

Thanks for the update! Haven't installed it yet, but will do later today.
The German translation is fine. Although the example in your post is wrong ;)
Plural of "Bild" (image) is "Bilder" not "Bilden". In the actual code snippet, it's correct though.

Unless it's on purpose for style reasons, nouns in German are always capitalized. You might want to change this.

Feel free to contact me, if you need further help with German translations.
 
User avatar
mjau-mjau
X3 Wizard
Topic Author
Posts: 12512
Joined: 30 Sep 2006, 03:37

Re: X3 interface translations [BETA] :de::fr::es::it:

09 Jan 2021, 03:25

kmorwath wrote:Feel free to ask if more Italian translations are needed.
Grazie! I have added your suggestion for next release.
Zorugal wrote:Plural of "Bild" (image) is "Bilder" not "Bilden". In the actual code snippet, it's correct though.
Fixed!
Zorugal wrote:Unless it's on purpose for style reasons, nouns in German are always capitalized. You might want to change this.
This was already noted in a different post a couple of weeks ago. X3 uses CSS to Capitalize words, and for consistency, I decided to keep the actual translations in lowercase. You can change the translated item from "bilder" to "Bilder", but it will output on the website as "Bilder" regardless.
 
wikipeter
Posts: 1
Joined: 12 Jan 2021, 09:49

Re: X3 interface translations [BETA] :de::fr::es::it:

12 Jan 2021, 10:54

Dutch :flag_nl: / Nederands / nl.css
Code
/* nl.css [Dutch] */
[data-lang="chat"]:after { content: 'chat'; }
[data-lang="comments"]:after { content: 'reacties'; }
[data-lang="folder"]:after { content: 'galerij'; }
[data-lang="folders"]:after { content: 'galerijen'; }
[data-lang="image"]:after { content: 'afbeelding'; }
[data-lang="images"]:after { content: 'afbeeldingen'; }
[data-lang="map"]:after { content: 'kaart'; }
[data-lang="pause"]:after { content: 'pauzeren'; }
[data-lang="play"]:after { content: 'afspelen'; }
[data-lang="styles"]:after { content: 'stijlen'; }
 
User avatar
mjau-mjau
X3 Wizard
Topic Author
Posts: 12512
Joined: 30 Sep 2006, 03:37

Re: X3 interface translations [BETA] :de::fr::es::it:

13 Jan 2021, 00:10

wikipeter wrote:Dutch :flag_nl: / Nederands / nl.css
Thanks :clap: :star:
 
nicky1605
Posts: 1
Joined: 17 Jan 2021, 07:03

Re: X3 interface translations [BETA] :de::fr::es::it:

17 Jan 2021, 23:00

China :cn: /中国 / cn.css
Code
/* cn.css [Chinsese-Simplified] */
[data-lang="chat"]:after { content: '聊天'; }
[data-lang="comments"]:after { content: '评论'; }
[data-lang="folder"]:after { content: '文件夹'; }
[data-lang="folders"]:after { content: '文件夹们'; }
[data-lang="image"]:after { content: '图片'; }
[data-lang="images"]:after { content: '图片们'; }
[data-lang="map"]:after { content: '地图'; }
[data-lang="pause"]:after { content: '暂停'; }
[data-lang="play"]:after { content: '播放'; }
[data-lang="styles"]:after { content: '样式'; }
 
User avatar
mjau-mjau
X3 Wizard
Topic Author
Posts: 12512
Joined: 30 Sep 2006, 03:37

Re: X3 interface translations [BETA] :de::fr::es::it:

18 Jan 2021, 01:24

nicky1605 wrote:China :cn: /中国 / cn.css
谢谢!:clap:
 
metallissimus
Experienced
Posts: 87
Joined: 17 Oct 2019, 06:54

Re: X3 interface translations [BETA] :de::fr::es::it:

Yesterday, 11:23

mjau-mjau wrote: Image
Small detail I just noticed: In the dropdown it should be "Deutsch", not "Deutsche".
 
User avatar
mjau-mjau
X3 Wizard
Topic Author
Posts: 12512
Joined: 30 Sep 2006, 03:37

Re: X3 interface translations [BETA] :de::fr::es::it:

Yesterday, 23:00

metallissimus wrote:Small detail I just noticed: In the dropdown it should be "Deutsch", not "Deutsche".
:clap: