# Translation does not work in Logged Out Page and Apply Filters in Unified Search

**URL:** <https://discuss.elastic.co/t/translation-does-not-work-in-logged-out-page-and-apply-filters-in-unified-search/338341>\
**Category:** Kibana\
**Created:** [July 13, 2023, 2:58pm UTC](https://discuss.elastic.co/t/translation-does-not-work-in-logged-out-page-and-apply-filters-in-unified-search/338341 "2023-07-13T14:58:40Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![wsbr](https://avatars.discourse-cdn.com/v4/letter/w/b9bd4f/32.png) [@wsbr](https://discuss.elastic.co/u/wsbr)\
**Post date:** [July 13, 2023, 2:58pm UTC](https://discuss.elastic.co/t/translation-does-not-work-in-logged-out-page-and-apply-filters-in-unified-search/338341/1 "2023-07-13T14:58:40Z")

</div>

Hi,

We are using Elasticsearch 8.7.1 and some actions does not be translated.

How to solve this problem?

 ![Captura de Tela 2023-07-13 às 11.48.58](https://us1.discourse-cdn.com/elastic/original/3X/3/b/3b8e2d6c15249b4b7acc012f2e27fbfe7b3a6fc6.png)  
 ![Captura de Tela 2023-07-13 às 11.49.19](https://us1.discourse-cdn.com/elastic/original/3X/5/9/590784eb8d360010d870a49a5acf15d5e877c80e.png)  
 ![Captura de Tela 2023-07-13 às 11.50.55](https://us1.discourse-cdn.com/elastic/original/3X/8/5/856da42b5d060dc1674a76787f80b87b47ffcf1b.png)  
 ![Captura de Tela 2023-07-13 às 11.51.59](https://us1.discourse-cdn.com/elastic/original/3X/9/f/9f2603e8139c58cfc91473c67500e56d24406c91.png)

---

<div class="post-metadata">

**Author:** ![jsanz](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jsanz/32/53734_2.png) [@jsanz](https://discuss.elastic.co/u/jsanz)\
**Post date:** [July 18, 2023, 1:01pm UTC](https://discuss.elastic.co/t/translation-does-not-work-in-logged-out-page-and-apply-filters-in-unified-search/338341/2 "2023-07-18T13:01:23Z")

</div>

Kibana supports translations in French, Japanese, and Chinese.

> <https://github.com/elastic/kibana/tree/main/x-pack/plugins/translations/translations>
>
> //github.com/elastic/kibana/tree/main/x-pack/plugins/translations/translations

Where does your translation from Portuguese come from?

---

<div class="post-metadata">

**Author:** ![wsbr](https://avatars.discourse-cdn.com/v4/letter/w/b9bd4f/32.png) [@wsbr](https://discuss.elastic.co/u/wsbr)\
**Post date:** [July 25, 2023, 3:59pm UTC](https://discuss.elastic.co/t/translation-does-not-work-in-logged-out-page-and-apply-filters-in-unified-search/338341/3 "2023-07-25T15:59:08Z")

</div>

I created my own translation file with this instructions

> <https://github.com/elastic/kibana/tree/main/packages/kbn-i18n>
>
> //github.com/elastic/kibana/tree/main/packages/kbn-i18n

like this guy does in Russian

> [@Локализация Кибаны](https://discuss.elastic.co/t/topic/228160):
>
> Друзья, кто-нибудь сталкивался с локализацией этой системы? Хотя бы частично.. Очень нужны какие-нибудь мануалы. А то мне индусы пишут, что только под китайский есть частичный перевод. [Ответ индусов](https://discuss.elastic.co/t/kibana-translate/226434/4)

I don't know why some parts still in English.

![Captura de Tela 2023-07-25 às 12.49.10](https://us1.discourse-cdn.com/elastic/original/3X/8/5/855cfb02a05b7668f77eab0fd199f617a580cae6.png)

![Captura de Tela 2023-07-25 às 12.49.19](https://us1.discourse-cdn.com/elastic/original/3X/f/e/fefca948ab12914a8e67860c4b8c9c1955711298.png)

![Captura de Tela 2023-07-25 às 12.49.32](https://us1.discourse-cdn.com/elastic/original/3X/5/f/5fc8e4e7f42a80125c4d60648be686e31ef2382f.png)

![Captura de Tela 2023-07-25 às 12.49.48](https://us1.discourse-cdn.com/elastic/original/3X/4/3/439ecb558b5cf68d13e59bbf547b38693906d734.png)

---

<div class="post-metadata">

**Author:** ![jsanz](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jsanz/32/53734_2.png) [@jsanz](https://discuss.elastic.co/u/jsanz)\
**Post date:** [July 25, 2023, 5:02pm UTC](https://discuss.elastic.co/t/translation-does-not-work-in-logged-out-page-and-apply-filters-in-unified-search/338341/4 "2023-07-25T17:02:54Z")

</div>

Sorry I could not replicate your issue, check a couple of examples I could locate from your screenshots:

 ![2023-07-25_18-53](https://us1.discourse-cdn.com/elastic/original/3X/5/1/51d36c431d2ea92345779d01f4182d0ecb41ebf9.png)

 ![2023-07-25_18-59](https://us1.discourse-cdn.com/elastic/original/3X/a/8/a86256a60ffd26bcbc4752c4e1429174dd1c7fc6.png)

What I did is:

- Start a development environment from the `main` branch of the Kibana repo
- Copy the `fr-FR.json` as `es-ES.json` to start with texts in French
- Add `i18n.locale: "es-ES"` to my `kibana.dev.yml` configuration file
- Add the translation to the `x-pack/.i18nrc.json` file

```auto
    "@kbn/translations-plugin/translations/es-ES.json"

```

- Locate a few messages in `es-ES.json` and translate them
- Start the Kibana development server

I'm not sure if you need to run `yarn kbn bootstrap` for the translations to be picked up, but other than that the translations are showing correctly on my environment.

Does this help?

---

<div class="post-metadata">

**Author:** ![wsbr](https://avatars.discourse-cdn.com/v4/letter/w/b9bd4f/32.png) [@wsbr](https://discuss.elastic.co/u/wsbr)\
**Post date:** [July 25, 2023, 7:03pm UTC](https://discuss.elastic.co/t/translation-does-not-work-in-logged-out-page-and-apply-filters-in-unified-search/338341/5 "2023-07-25T19:03:40Z")

</div>

I think the problem is because we use `i18n.locale: "pt-BR"`

Original French file, saved as fr-FR.json, everything it is ok:

 ![home-screen-fr-FR-with-name-fr-FR](https://us1.discourse-cdn.com/elastic/original/3X/f/f/ffa0e01663124db52c9fca0b1bd45c9cc0b4f416.png)

Same original French file, but now saved as pt-BR.json: some text blocks aren't translated

 ![home-screen-fr-FR-with-name-pt-BR](https://us1.discourse-cdn.com/elastic/original/3X/9/1/918fa6db5920c7fde53339f3412f91c8a7938d32.png)

---

<div class="post-metadata">

**Author:** ![wsbr](https://avatars.discourse-cdn.com/v4/letter/w/b9bd4f/32.png) [@wsbr](https://discuss.elastic.co/u/wsbr)\
**Post date:** [July 25, 2023, 9:30pm UTC](https://discuss.elastic.co/t/translation-does-not-work-in-logged-out-page-and-apply-filters-in-unified-search/338341/6 "2023-07-25T21:30:16Z")

</div>

If we use `i18n.locale: "es-ES"` with our "pt-BR.json" renamed to "es-ES.json" it works! 🤔

But in this cenario, the days of the week and months of the year stay in Spanish. 😭  
 ![Captura de Tela 2023-07-25 às 18.15.39](https://us1.discourse-cdn.com/elastic/original/3X/8/4/842accb44221277fb12966239627fdfb70501c2c.png)

The same if we use `i18n.locale: "ru"` with pt-BR translations inside "ru.json" file. Everything stays in Portuguese, except the days of the week, the months of the year....  
 ![Captura de Tela 2023-07-25 às 18.26.11](https://us1.discourse-cdn.com/elastic/original/3X/8/2/8242968a30eab44d26570c99fd8a36639e765fe6.png)

I tried to use "pt-PT" or "pt" and in this cases the result is same as "pt-BR": some parts still in English.

---

<div class="post-metadata">

**Author:** ![jsanz](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jsanz/32/53734_2.png) [@jsanz](https://discuss.elastic.co/u/jsanz)\
**Post date:** [July 27, 2023, 12:59pm UTC](https://discuss.elastic.co/t/translation-does-not-work-in-logged-out-page-and-apply-filters-in-unified-search/338341/7 "2023-07-27T12:59:53Z")

</div>

Hi @wsbr, just checked with the team and you indeed need to tweak this file to include those strings

> <https://github.com/elastic/kibana/blob/main/packages/kbn-i18n/src/core/locales.js>

For reference, this topic, actually also for Portuguese, was discussed on this other thread

> [@Translating Kibana to pt-BR](https://discuss.elastic.co/t/translating-kibana-to-pt-br/167113):
>
> Hello, I'm trying to translate kibana to Brazilian Portuguese. I created the pt-BR.json file inside the folder 'src/legacy/core\_plugins/kibana/translations/' And started kibana using: 'yarn start --i18n.locale=pt-BR' Then, the chrome console is printing this message: index.js:525 [React Intl] Missing locale data for locale: "pt-br". Using default locale: "en" as fallback. Well, I'm using the master branch of the kibana repo. Thank you.

Cheers!

---

<div class="post-metadata">

**Author:** ![wsbr](https://avatars.discourse-cdn.com/v4/letter/w/b9bd4f/32.png) [@wsbr](https://discuss.elastic.co/u/wsbr)\
**Post date:** [July 27, 2023, 5:36pm UTC](https://discuss.elastic.co/t/translation-does-not-work-in-logged-out-page-and-apply-filters-in-unified-search/338341/8 "2023-07-27T17:36:30Z")

</div>

Thank you a lot! It worked perfectly.

I suggest to commit the pt / pt-BR in the main code.

---

<div class="post-metadata">

**Author:** ![wsbr](https://avatars.discourse-cdn.com/v4/letter/w/b9bd4f/32.png) [@wsbr](https://discuss.elastic.co/u/wsbr)\
**Post date:** [July 28, 2023, 3:12pm UTC](https://discuss.elastic.co/t/translation-does-not-work-in-logged-out-page-and-apply-filters-in-unified-search/338341/9 "2023-07-28T15:12:11Z")

</div>

Issue created

> <https://github.com/elastic/kibana/issues/162714>
>
> \*\*Kibana version:\*\* 8.9
> 
> \*\*Describe the bug:\*\* As the thread in Discuss, https…://discuss.elastic.co/t/translation-does-not-work-in-logged-out-page-and-apply-filters-in-unified-search/338341 it is necessary ajust locales.js file to support pt / pt-BR.

PR requested

> <https://github.com/elastic/kibana/pull/162715>
>
> Including support to pt and pt-BR in locales.js to solve problems with using tra…nslations plugins issue #162714
> 
> Closes issue #162714 
> 
> label:review
> label:community
> 
> Thanks @jsanz for the help

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [August 25, 2023, 3:12pm UTC](https://discuss.elastic.co/t/translation-does-not-work-in-logged-out-page-and-apply-filters-in-unified-search/338341/10 "2023-08-25T15:12:19Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
