diff options
author | Brandon Labuschagne <blabuschagne@gitlab.com> | 2019-04-30 19:12:25 +0000 |
---|---|---|
committer | Tim Zallmann <tzallmann@gitlab.com> | 2019-04-30 19:12:25 +0000 |
commit | 099d3e111fe4c7eb4bc6353edd888d68e95099bc (patch) | |
tree | d708753ee204d79fb4ead51a737045e0e9ffd33a | |
parent | 29c5174274feafebc4ecb182eaece3dfb2197d22 (diff) | |
download | gitlab-ce-099d3e111fe4c7eb4bc6353edd888d68e95099bc.tar.gz |
Internationalisation of u2f directory
This is one of many MRs opened in order to improve the overall
internationalisation of the GitLab codebase.
i18n documentation
https://docs.gitlab.com/ee/development/i18n/externalization.html
-rw-r--r-- | app/assets/javascripts/u2f/error.js | 12 | ||||
-rw-r--r-- | locale/gitlab.pot | 12 |
2 files changed, 20 insertions, 4 deletions
diff --git a/app/assets/javascripts/u2f/error.js b/app/assets/javascripts/u2f/error.js index 1a98564ff55..ca0fc0700ad 100644 --- a/app/assets/javascripts/u2f/error.js +++ b/app/assets/javascripts/u2f/error.js @@ -1,3 +1,5 @@ +import { __ } from '~/locale'; + export default class U2FError { constructor(errorCode, u2fFlowType) { this.errorCode = errorCode; @@ -8,15 +10,17 @@ export default class U2FError { message() { if (this.errorCode === window.u2f.ErrorCodes.BAD_REQUEST && this.httpsDisabled) { - return 'U2F only works with HTTPS-enabled websites. Contact your administrator for more details.'; + return __( + 'U2F only works with HTTPS-enabled websites. Contact your administrator for more details.', + ); } else if (this.errorCode === window.u2f.ErrorCodes.DEVICE_INELIGIBLE) { if (this.u2fFlowType === 'authenticate') { - return 'This device has not been registered with us.'; + return __('This device has not been registered with us.'); } if (this.u2fFlowType === 'register') { - return 'This device has already been registered with us.'; + return __('This device has already been registered with us.'); } } - return 'There was a problem communicating with your device.'; + return __('There was a problem communicating with your device.'); } } diff --git a/locale/gitlab.pot b/locale/gitlab.pot index 57f89acf52f..7b5770a6075 100644 --- a/locale/gitlab.pot +++ b/locale/gitlab.pot @@ -9231,6 +9231,9 @@ msgstr "" msgid "There is already a repository with that name on disk" msgstr "" +msgid "There was a problem communicating with your device." +msgstr "" + msgid "There was an error loading users activity calendar." msgstr "" @@ -9309,6 +9312,12 @@ msgstr "" msgid "This container registry has been scheduled for deletion." msgstr "" +msgid "This device has already been registered with us." +msgstr "" + +msgid "This device has not been registered with us." +msgstr "" + msgid "This diff is collapsed." msgstr "" @@ -9895,6 +9904,9 @@ msgstr "" msgid "Type" msgstr "" +msgid "U2F only works with HTTPS-enabled websites. Contact your administrator for more details." +msgstr "" + msgid "Unable to connect to server: %{error}" msgstr "" |