From 0837621dd7a4d843adabd1ea80e42d8599cbe5f7 Mon Sep 17 00:00:00 2001 From: Tulio Casagrande Date: Thu, 23 Jun 2016 20:11:08 -0300 Subject: [#619] Fix some missing translation strings --- web-ui/app/js/helpers/monitored_ajax.js | 9 +++--- web-ui/app/js/mail_view/ui/forward_box.js | 2 +- web-ui/app/js/services/delete_service.js | 8 ++--- web-ui/app/locales/en-us/translation.json | 35 +++++++++++++++------- web-ui/app/locales/pt/translation.json | 14 ++++----- web-ui/app/locales/sv/translation.json | 12 ++++---- web-ui/app/templates/compose/reply_section.hbs | 2 +- web-ui/app/templates/mail_actions/actions_box.hbs | 6 ++-- .../templates/mail_actions/trash_actions_box.hbs | 4 +-- web-ui/app/templates/mails/draft.hbs | 2 +- web-ui/app/templates/mails/mail_actions.hbs | 4 +-- web-ui/app/templates/mails/sent.hbs | 2 +- web-ui/app/templates/page/logout.hbs | 2 +- web-ui/app/templates/page/logout_shortcut.hbs | 2 +- web-ui/app/templates/page/user_settings_box.hbs | 6 ++-- web-ui/app/templates/page/user_settings_icon.hbs | 2 +- web-ui/app/templates/page/version.hbs | 2 +- web-ui/app/templates/tags/tag_list.hbs | 4 +-- 18 files changed, 64 insertions(+), 54 deletions(-) diff --git a/web-ui/app/js/helpers/monitored_ajax.js b/web-ui/app/js/helpers/monitored_ajax.js index dc182d58..3dfec34a 100644 --- a/web-ui/app/js/helpers/monitored_ajax.js +++ b/web-ui/app/js/helpers/monitored_ajax.js @@ -20,9 +20,9 @@ define(['page/events', 'views/i18n', 'helpers/browser'], function (events, i18n, 'use strict'; var messages = { - timeout: 'a timeout occurred', - error: 'problems talking to server', - parseerror: 'got invalid response from server' + timeout: i18n('error.timeout'), + error: i18n('error.general'), + parseerror: i18n('error.parse') }; function monitoredAjax(on, url, config) { @@ -48,8 +48,7 @@ define(['page/events', 'views/i18n', 'helpers/browser'], function (events, i18n, return $.ajax(url, config).fail(function (xmlhttprequest, textstatus, message) { if (!config.skipErrorMessage) { var msg = (xmlhttprequest.responseJSON && xmlhttprequest.responseJSON.message) || - messages[textstatus] || - 'unexpected problem while talking to server'; + messages[textstatus] || messages.error; on.trigger(document, events.ui.userAlerts.displayMessage, {message: i18n(msg), class: 'error'}); } diff --git a/web-ui/app/js/mail_view/ui/forward_box.js b/web-ui/app/js/mail_view/ui/forward_box.js index 659968e5..f767915c 100644 --- a/web-ui/app/js/mail_view/ui/forward_box.js +++ b/web-ui/app/js/mail_view/ui/forward_box.js @@ -31,7 +31,7 @@ define( return defineComponent(forwardBox, withHideAndShow, withComposeInline); function forwardBox() { - var fwd = function(v) { return i18n('Fwd: ') + v; }; + var fwd = function(v) { return i18n('fwd') + ': ' + v; }; this.fetchTargetMail = function (ev) { this.trigger(document, events.mail.want, { mail: this.attr.ident, caller: this }); diff --git a/web-ui/app/js/services/delete_service.js b/web-ui/app/js/services/delete_service.js index 5cf86d63..4097ea7e 100644 --- a/web-ui/app/js/services/delete_service.js +++ b/web-ui/app/js/services/delete_service.js @@ -22,14 +22,14 @@ define(['flight/lib/component', 'page/events', 'views/i18n'], function (defineCo this.successDeleteMessageFor = function(mail) { return mail.isInTrash() ? - i18n('Your message was permanently deleted!') : - i18n('Your message was moved to trash!'); + i18n('delete-single') : + i18n('trash-single'); }; this.successDeleteManyMessageFor = function(mail) { return mail.isInTrash() ? - i18n('Your messages were permanently deleted!') : - i18n('Your messages were moved to trash!'); + i18n('delete-bulk') : + i18n('trash-bulk'); }; this.deleteEmail = function (event, data) { diff --git a/web-ui/app/locales/en-us/translation.json b/web-ui/app/locales/en-us/translation.json index 357187b0..718979cf 100644 --- a/web-ui/app/locales/en-us/translation.json +++ b/web-ui/app/locales/en-us/translation.json @@ -1,10 +1,12 @@ { "compose": "Compose", "re": "Re: ", - "Fwd: ": "Fwd: ", - "Your message was moved to trash!": "Your message was moved to trash!", + "fwd": "Fwd", + "trash-single": "Your message was moved to trash!", + "trash-bulk": "Your messages were moved to trash!", "Your message was archived": "Your message was archived", - "Your message was permanently deleted!": "Your message was permanently deleted!", + "delete-single": "Your message was permanently deleted!", + "delete-bulk": "Your messages were permanently deleted!", "Saved as draft.": "Saved as draft.", "One or more of the recipients are not valid emails": "One or more of the recipients are not valid emails", "Could not update mail tags": "Could not update mail tags", @@ -21,11 +23,12 @@ "Send": "Send", "Cancel": "Cancel", "Reply": "Reply", - "Reply to All": "Reply to All", - "Mark as read": "Mark as read", + "reply-to-all": "Reply to all", + "delete-this-message": "Delete this message", + "mark-as-read": "Mark as read", "mark-as-unread": "Mark as unread", - "Delete": "Delete", - "Archive": "Archive", + "delete": "Delete", + "archive": "Archive", "Close": "Close", "Trash this message": "Trash this message", "NOTHING SELECTED": "NOTHING SELECTED", @@ -38,7 +41,7 @@ "Archive:": "Archive:", "we will keep this message for 30 days, then delete it forever.": "we will keep this message for 30 days, then delete it forever.", "we will remove all the tags, but keep it in your account in case you need it.": "we will remove all the tags, but keep it in your account in case you need it.", - "to:": "to:", + "to": "to", "no_subject": "", "no_recipient": "", "you": "you", @@ -60,12 +63,24 @@ "Tags": "Tags", "Forward": "Forward", "feedback-placeholder": "Tell us what you liked, didn't like, what is missing and generally what you think about Pixelated.", - + "user-settings": "User Settings", + "email-address": "Email address", + "public-key-fingerprint": "Public key fingerprint", + "version": "version", + "logout": "Logout", + "delete-permanently": "Delete Permanently", + "move-to-inbox": "Move to Inbox", + "error": { + "timeout": "a timeout occurred", + "general": "problems talking to server", + "parse": "got invalid response from server" + }, "tags": { "inbox": "Inbox", "sent": "Sent", "drafts": "Drafts", "trash": "Trash", - "all": "All" + "all": "All", + "tags": "Tags" } } diff --git a/web-ui/app/locales/pt/translation.json b/web-ui/app/locales/pt/translation.json index 77525342..d20b02b3 100644 --- a/web-ui/app/locales/pt/translation.json +++ b/web-ui/app/locales/pt/translation.json @@ -1,10 +1,8 @@ { "compose": "Escrever", "re": "Res: ", - "Fwd: ": "Enc: ", - "Your message was moved to trash!": "Sua mensagem foi movida para a lixeira!", + "fwd": "Enc", "Your message was archived": "Sua mensagem foi arquivada!", - "Your message was permanently deleted!": "Sua mensagem foi permanentemente deletada!", "Saved as draft.": "Mensagem salva como rascunho.", "One or more of the recipients are not valid emails": "Email de um ou mais destinatários é inválido", "Could not update mail tags": "Não foi possível atualizar as etiquetas do email", @@ -21,11 +19,11 @@ "Send": "Enviar", "Cancel": "Cancelar", "Reply": "Responder", - "Reply to All": "Responder a todos", - "Mark as read": "Marcar como lida", + "reply-to-all": "Responder a todos", + "mark-as-read": "Marcar como lida", "mark-as-unread": "Marcar como não lida", - "Delete": "Descartar", - "Archive": "Arquivar", + "delete": "Apagar", + "archive": "Arquivar", "Close": "Fechar", "Trash this message": "Descartar essa mensagem", "NOTHING SELECTED": "NADA SELECIONADO", @@ -38,7 +36,7 @@ "Archive:": "Arquivo:", "we will keep this message for 30 days, then delete it forever.": "manteremos essa mensagem por 30 dias, após isso ela será excluída definitivamente.", "we will remove all the tags, but keep it in your account in case you need it.": "iremos remover todas as tags, mas manteremos em sua conta caso necessite.", - "to:": "para:", + "to": "para", "no_subject": "", "no_recipient": "", "you": "você", diff --git a/web-ui/app/locales/sv/translation.json b/web-ui/app/locales/sv/translation.json index 0c64d6d7..76c380c5 100644 --- a/web-ui/app/locales/sv/translation.json +++ b/web-ui/app/locales/sv/translation.json @@ -1,10 +1,8 @@ { "compose": "Skriv nytt", "re": "Sv: ", - "Fwd: ": "VB: ", - "Your message was moved to trash!": "Ditt meddelande har flyttats till papperskorgen!", + "fwd": "VB", "Your message was archived": "Ditt meddelande har arkiverats!", - "Your message was permanently deleted!": "Ditt meddelande har tagits bort permanent!", "Saved as draft.": "Sparat som utkast.", "One or more of the recipients are not valid emails": "En eller flera mottagare är inte giltiga epost-adresser", "Could not update mail tags": "Kan inte ändra taggar", @@ -21,10 +19,10 @@ "Send": "Skicka", "Cancel": "Avbryt", "Reply": "Svara", - "Reply to All": "Svara Alla", - "Mark as read": "Markera som läst", - "Delete": "Ta bort", - "Archive": "Arkivera", + "reply-to-all": "Svara Alla", + "mark-as-read": "Markera som läst", + "delete": "Ta bort", + "archive": "Arkivera", "Close": "Stäng", "Trash this message": "Kasta detta meddelande", "NOTHING SELECTED": "INGET VALT", diff --git a/web-ui/app/templates/compose/reply_section.hbs b/web-ui/app/templates/compose/reply_section.hbs index 9e833ffe..85ab49c4 100644 --- a/web-ui/app/templates/compose/reply_section.hbs +++ b/web-ui/app/templates/compose/reply_section.hbs @@ -1,6 +1,6 @@
- +
diff --git a/web-ui/app/templates/mail_actions/actions_box.hbs b/web-ui/app/templates/mail_actions/actions_box.hbs index 0c9b6737..68a8d0bf 100644 --- a/web-ui/app/templates/mail_actions/actions_box.hbs +++ b/web-ui/app/templates/mail_actions/actions_box.hbs @@ -1,7 +1,7 @@
  • -
  • +
  • -
  • -
  • +
  • +
  • diff --git a/web-ui/app/templates/mail_actions/trash_actions_box.hbs b/web-ui/app/templates/mail_actions/trash_actions_box.hbs index 7852bd6f..4e0ec332 100644 --- a/web-ui/app/templates/mail_actions/trash_actions_box.hbs +++ b/web-ui/app/templates/mail_actions/trash_actions_box.hbs @@ -1,5 +1,5 @@
  • -
  • -
  • +
  • +
  • diff --git a/web-ui/app/templates/mails/draft.hbs b/web-ui/app/templates/mails/draft.hbs index d223c0a4..942b9815 100644 --- a/web-ui/app/templates/mails/draft.hbs +++ b/web-ui/app/templates/mails/draft.hbs @@ -5,7 +5,7 @@
    - {{t 'to:'}} + {{t 'to'}}: {{#if header.to }} {{ header.to }} {{else}} diff --git a/web-ui/app/templates/mails/mail_actions.hbs b/web-ui/app/templates/mails/mail_actions.hbs index 0b717373..0adfe853 100644 --- a/web-ui/app/templates/mails/mail_actions.hbs +++ b/web-ui/app/templates/mails/mail_actions.hbs @@ -1,6 +1,6 @@
      -
    • {{t 'Reply to All'}}
    • -
    • {{t 'Delete this message'}}
    • +
    • {{t 'reply-to-all'}}
    • +
    • {{t 'delete-this-message'}}
    diff --git a/web-ui/app/templates/mails/sent.hbs b/web-ui/app/templates/mails/sent.hbs index a637e3d2..be51cfd4 100644 --- a/web-ui/app/templates/mails/sent.hbs +++ b/web-ui/app/templates/mails/sent.hbs @@ -4,7 +4,7 @@
    - {{t 'to:'}} + {{t 'to'}}: {{#if header.to }} {{ header.to }} {{else}} diff --git a/web-ui/app/templates/page/logout.hbs b/web-ui/app/templates/page/logout.hbs index 3768d24f..0cc079bc 100644 --- a/web-ui/app/templates/page/logout.hbs +++ b/web-ui/app/templates/page/logout.hbs @@ -3,7 +3,7 @@
  • - Logout + {{t 'logout'}}
  • diff --git a/web-ui/app/templates/page/logout_shortcut.hbs b/web-ui/app/templates/page/logout_shortcut.hbs index 4c1db89a..043ab0dc 100644 --- a/web-ui/app/templates/page/logout_shortcut.hbs +++ b/web-ui/app/templates/page/logout_shortcut.hbs @@ -1,6 +1,6 @@
  • -
    Logout
    +
    {{t 'logout'}}
  • diff --git a/web-ui/app/templates/page/user_settings_box.hbs b/web-ui/app/templates/page/user_settings_box.hbs index 761bfc16..962d0a69 100644 --- a/web-ui/app/templates/page/user_settings_box.hbs +++ b/web-ui/app/templates/page/user_settings_box.hbs @@ -1,10 +1,10 @@
    -

    User Settings

    +

    {{t 'user-settings'}}

    -

    E-Mail address

    +

    {{t 'email-address'}}

    {{ account_email }}

    -

    Public key fingerprint

    +

    {{t 'public-key-fingerprint'}}

    {{ formatFingerPrint fingerprint }}

    diff --git a/web-ui/app/templates/page/user_settings_icon.hbs b/web-ui/app/templates/page/user_settings_icon.hbs index 8b61655c..d689a2f8 100644 --- a/web-ui/app/templates/page/user_settings_icon.hbs +++ b/web-ui/app/templates/page/user_settings_icon.hbs @@ -2,7 +2,7 @@
  • - User Settings + {{t 'user-settings'}}
  • diff --git a/web-ui/app/templates/page/version.hbs b/web-ui/app/templates/page/version.hbs index 00344f60..5f43f78a 100644 --- a/web-ui/app/templates/page/version.hbs +++ b/web-ui/app/templates/page/version.hbs @@ -1,2 +1,2 @@ -version: UNKNOWN_VERSION
    +{{t 'version'}}: UNKNOWN_VERSION
    diff --git a/web-ui/app/templates/tags/tag_list.hbs b/web-ui/app/templates/tags/tag_list.hbs index e265354f..92a73283 100644 --- a/web-ui/app/templates/tags/tag_list.hbs +++ b/web-ui/app/templates/tags/tag_list.hbs @@ -1,6 +1,6 @@
      - Tags + {{t 'tags.tags'}}
      -
        \ No newline at end of file +
          -- cgit v1.2.3