Quantcast
Channel: Issues for Drupal core
Viewing all articles
Browse latest Browse all 293694

It's possible to translate boolean config?

$
0
0

I with community created module for Russian new law https://www.drupal.org/project/fz152 and I faced with problem on Drupal 8 with configurations.

The main feature of module, it creates special page with privacy policy information and alter forms on site to satisfy the law. On Drupal 7 I use variable module, which don't have current problem with configuration. And the problem is, some configurations (radios) must be "translated".

For example we have radio input "Enable functionality" which must be translatable and that is boolean. This can help to disable all logic of module on languages which not needed this page and form alterations. This works correctly on D7, but not on D8. I've created config_translation file and defines schema file where this radio is set translatable: true.

With configuration inspector I see the correct form:

1

But on translation page I see only the string type is translatable which is by default.

So can I make boolean translatable, or better look for another solution? I just want to understand for myself, is this behavior is supported by core or not. Looks like not, but old documentations says that string and some other types translatable by default, but other types can be forced to translation with translatable: true, and this seems not works. The current documentation is not clear about it.

Seems like the replace radio with checkboxes with all available languages is the easiest solution in current situation.


Viewing all articles
Browse latest Browse all 293694

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>