Fix translations at login plugin

To be translatable text field should be marked
with @i18n. Also these messages should be provided by
i18n_messages.

Fixes: https://pagure.io/freeipa/issue/7559
Reviewed-By: Alexander Bokovoy <abokovoy@redhat.com>
Reviewed-By: Christian Heimes <cheimes@redhat.com>
Reviewed-By: Petr Vobornik <pvoborni@redhat.com>
This commit is contained in:
Stanislav Levin 2018-06-26 17:55:27 +03:00 committed by Rob Crittenden
parent 5d8fde0ac1
commit 2a81ec3b94
2 changed files with 5 additions and 3 deletions

View File

@ -26,9 +26,10 @@ define(['dojo/_base/declare',
'../phases', '../phases',
'../reg', '../reg',
'../widget', '../widget',
'../widgets/LoginScreen' '../widgets/LoginScreen',
'../text'
], ],
function(declare, lang, on, Facet, auth, phases, reg, widget, LoginScreen) { function(declare, lang, on, Facet, auth, phases, reg, widget, LoginScreen, text) {
/** /**
* Login Facet plugin * Login Facet plugin
@ -48,7 +49,7 @@ define(['dojo/_base/declare',
{ {
$type: 'activity', $type: 'activity',
name: 'activity', name: 'activity',
text: 'Authenticating', text: text.get('@i18n:login.authenticating', 'Authenticating'),
visible: false visible: false
}, },
{ {

View File

@ -340,6 +340,7 @@ class i18n_messages(Command):
"pad": _("PAD"), "pad": _("PAD"),
}, },
"login": { "login": {
"authenticating": _("Authenticating"),
"form_auth": _( "form_auth": _(
"<i class=\"fa fa-info-circle\"></i> To log in with " "<i class=\"fa fa-info-circle\"></i> To log in with "
"<strong>username and password</strong>, enter them in the " "<strong>username and password</strong>, enter them in the "