Features Wishlist

Add language support

rhanninkSuggested this wish ·

Hello,

Can you add language support to this great project? I volunteer to do the Dutch language ;-)

Gr. Remco

Originally shared on GitHubOriginal authors and dates are preserved.

View original

Discussion 6

Add a comment
MaxGramser

Haha, yes! It all started Dutch. It’s on the roadmap to check with the device flash space but it’s a lot of work to make this happen. Thanks for proposing to help! Somewhere in the future it will happen.

Original on GitHub

echopage1964

If and when you decide to localize the interface, I am available for Italian.

Original on GitHub

alaltitov

You can simply take this, just like anything else.

Original on GitHub

MaxGramser

sorry, it's not that simple, as we also have the whole editor in vue

Original on GitHub

MaxGramser

I'm working on translations now, give me one day, and I'll add it. Then it would be nice if you can help to check the generated language files

Original on GitHub

MaxGramser

It's in: 0.2.90 / firmware 0.2.76.

What you get, without setting anything up:

  • The editor follows the language of your Home Assistant profile, so two people in one house each read their own.
  • The screens carry one language, built into the firmware: press Update on a screen (or let the nightly round do it). The clock (24 hours or 12 with AM/PM) and the number format change right away, without a new build.
  • Home Assistant's own words stay Home Assistant's: what a door, an airco or a robot says on a tile and in its card is the word its own dashboard shows, in your language.
  • Settings → Language & region in ESP Screens, when you want something other than Home Assistant's language.

In this release: English (US), English (UK), Nederlands, Deutsch, Français, Italiano, Español, Português, Polski.

Where help is needed

Every language except English is a first draft that still needs someone who speaks it. @rhannink for Dutch and @echopage1964 for Italian — your offers still stand?

One language is one file, screen_manager/translations/<code>.json: the screens, the editor and the app's messages together. docs/TRANSLATING.md walks through it, and you don't need Git: open the file on GitHub, press the pencil, change what's wrong and GitHub makes the pull request for you.

Two things to keep in mind while reading:

  • Keep the screen texts about as short as the English. A CYD tile has room for about 88 pixels of text; python3 tools/i18n.py check measures the lines under a tile's name in the screens' own font and says which ones are too wide.
  • Don't edit screen.ha, screen.date or screen.number. Those come from Home Assistant's own translations and from the Unicode CLDR. A wrong word there belongs in Home Assistant's translations; we pick it up from there.

When a file has been read through, set "checked": true in its _meta block, and say in the pull request which parts you checked.

A language that isn't there yet starts with one command: python3 tools/i18n.py new sv Svenska Swedish one_other. That writes the file with English as the starting point, the right clock and number format, and the weather days in two letters. Until such a file exists, the screens fall back to English while already using your country's clock and numbers — a Swedish Home Assistant gets 1 234,5 and a 24-hour clock today.

Thanks @alaltitov for the pointer; the screens' side is close to what you linked, but the editor and the app's own messages needed the same treatment, so it all lives in one file per language now.

Leaving this open for the translations themselves.

Original on GitHub

Add your thoughts, a screenshot or a useful link.

Markdown & basic HTML
Paste or drop images · URLs on their own line become previews0 / 10,000
Sign in with GitHub to commentYour draft stays in this browser tab.