From f87b51fda899a07c064c27de74bd56b974b5e3a5 Mon Sep 17 00:00:00 2001 From: Matt Jankowski <mjankowski@thoughtbot.com> Date: Sun, 16 Apr 2017 13:37:01 -0400 Subject: [PATCH] I18n health warnings (#1949) * Rename admin.domain_block to admin.domain_blocks in prep for i18n improvement * Use implicit controller/action path for i18n in admin/domain_blocks * Add DomainBlock#accounts has_many * Avoid i18n health warning for `en` locale by using symbol scope with :count * Remove unused i18n key: plaintext_secret_html * Remove unused i18n key two_factor_auth.warning * Remove final will_paginate i18n keys * Remove unused key two_factor_auth.recovery_codes * Remove unused key: admin.reports.comment.none * Remove unused reports. i18n namespace (moved to admin.reports) * Ignore keys from locales which override activemodel and activerecord errors * Revert "Remove unused key: admin.reports.comment.none" This reverts commit 350ef2685fadc069e619bb6d1066190de195d942. * Update i18n key reference to match moved location * Add missing `en` keys to i18n * Tell i18n-tasks to ignore missing attributes that dont need overwriting * Add i18n-tasks unused to travis --- .travis.yml | 1 + .../admin/domain_blocks_controller.rb | 4 ++-- app/mailers/notification_mailer.rb | 7 +++++- app/models/domain_block.rb | 3 +++ app/views/admin/domain_blocks/index.html.haml | 14 +++++------ app/views/admin/domain_blocks/new.html.haml | 14 +++++------ app/views/admin/domain_blocks/show.html.haml | 12 +++++++--- app/views/admin/reports/show.html.haml | 2 +- config/i18n-tasks.yml | 14 +++++++++++ config/locales/bg.yml | 2 -- config/locales/en.yml | 24 +++---------------- config/locales/eo.yml | 2 -- config/locales/es.yml | 2 -- config/locales/fi.yml | 2 -- config/locales/fr.yml | 22 +---------------- config/locales/hr.yml | 2 -- config/locales/it.yml | 1 - config/locales/ja.yml | 22 +---------------- config/locales/nl.yml | 2 -- config/locales/no.yml | 2 -- config/locales/pl.yml | 4 ---- config/locales/pt.yml | 2 +- config/locales/ru.yml | 2 -- config/locales/zh-CN.yml | 2 -- config/locales/zh-HK.yml | 23 +----------------- config/locales/zh-TW.yml | 23 +----------------- config/navigation.rb | 2 +- 27 files changed, 59 insertions(+), 153 deletions(-) diff --git a/.travis.yml b/.travis.yml index a91d70cf5..564155c66 100644 --- a/.travis.yml +++ b/.travis.yml @@ -38,3 +38,4 @@ before_script: script: - bundle exec rspec - npm test + - i18n-tasks unused diff --git a/app/controllers/admin/domain_blocks_controller.rb b/app/controllers/admin/domain_blocks_controller.rb index 5d146d946..1932dc6a8 100644 --- a/app/controllers/admin/domain_blocks_controller.rb +++ b/app/controllers/admin/domain_blocks_controller.rb @@ -15,7 +15,7 @@ module Admin if @domain_block.save DomainBlockWorker.perform_async(@domain_block.id) - redirect_to admin_domain_blocks_path, notice: I18n.t('admin.domain_block.created_msg') + redirect_to admin_domain_blocks_path, notice: I18n.t('admin.domain_blocks.created_msg') else render action: :new end @@ -28,7 +28,7 @@ module Admin def destroy @domain_block = DomainBlock.find(params[:id]) UnblockDomainService.new.call(@domain_block, resource_params[:retroactive]) - redirect_to admin_domain_blocks_path, notice: I18n.t('admin.domain_block.destroyed_msg') + redirect_to admin_domain_blocks_path, notice: I18n.t('admin.domain_blocks.destroyed_msg') end private diff --git a/app/mailers/notification_mailer.rb b/app/mailers/notification_mailer.rb index bf4c16e43..a163edd3c 100644 --- a/app/mailers/notification_mailer.rb +++ b/app/mailers/notification_mailer.rb @@ -59,7 +59,12 @@ class NotificationMailer < ApplicationMailer return if @notifications.empty? I18n.with_locale(@me.user.locale || I18n.default_locale) do - mail to: @me.user.email, subject: I18n.t('notification_mailer.digest.subject', count: @notifications.size) + mail to: @me.user.email, + subject: I18n.t( + :subject, + scope: [:notification_mailer, :digest], + count: @notifications.size + ) end end end diff --git a/app/models/domain_block.rb b/app/models/domain_block.rb index 89c81f766..baf5c3973 100644 --- a/app/models/domain_block.rb +++ b/app/models/domain_block.rb @@ -7,6 +7,9 @@ class DomainBlock < ApplicationRecord validates :domain, presence: true, uniqueness: true + has_many :accounts, foreign_key: :domain, primary_key: :domain + delegate :count, to: :accounts, prefix: true + def self.blocked?(domain) where(domain: domain, severity: :suspend).exists? end diff --git a/app/views/admin/domain_blocks/index.html.haml b/app/views/admin/domain_blocks/index.html.haml index da9a07bbc..bdef4294e 100644 --- a/app/views/admin/domain_blocks/index.html.haml +++ b/app/views/admin/domain_blocks/index.html.haml @@ -1,24 +1,24 @@ - content_for :page_title do - = t('admin.domain_block.title') + = t('admin.domain_blocks.title') %table.table %thead %tr - %th= t('admin.domain_block.domain') - %th= t('admin.domain_block.severity') - %th= t('admin.domain_block.reject_media') + %th= t('admin.domain_blocks.domain') + %th= t('admin.domain_blocks.severity') + %th= t('admin.domain_blocks.reject_media') %th %tbody - @blocks.each do |block| %tr %td %samp= block.domain - %td= t("admin.domain_block.severities.#{block.severity}") + %td= t("admin.domain_blocks.severities.#{block.severity}") %td - if block.reject_media? || block.suspend? %i.fa.fa-check %td - = table_link_to 'undo', t('admin.domain_block.undo'), admin_domain_block_path(block) + = table_link_to 'undo', t('admin.domain_blocks.undo'), admin_domain_block_path(block) = paginate @blocks -= link_to t('admin.domain_block.add_new'), new_admin_domain_block_path, class: 'button' += link_to t('admin.domain_blocks.add_new'), new_admin_domain_block_path, class: 'button' diff --git a/app/views/admin/domain_blocks/new.html.haml b/app/views/admin/domain_blocks/new.html.haml index 603faeb55..38fa90169 100644 --- a/app/views/admin/domain_blocks/new.html.haml +++ b/app/views/admin/domain_blocks/new.html.haml @@ -1,17 +1,17 @@ - content_for :page_title do - = t('admin.domain_block.new.title') + = t('.title') = simple_form_for @domain_block, url: admin_domain_blocks_path do |f| = render 'shared/error_messages', object: @domain_block - %p.hint= t('admin.domain_block.new.hint') + %p.hint= t('.hint') - = f.input :domain, placeholder: t('admin.domain_block.domain') - = f.input :severity, collection: DomainBlock.severities.keys, wrapper: :with_label, include_blank: false, label_method: lambda { |type| I18n.t("admin.domain_block.new.severity.#{type}") } + = f.input :domain, placeholder: t('admin.domain_blocks.domain') + = f.input :severity, collection: DomainBlock.severities.keys, wrapper: :with_label, include_blank: false, label_method: lambda { |type| t(".severity.#{type}") } - %p.hint= t('admin.domain_block.new.severity.desc_html') + %p.hint= t('.severity.desc_html') - = f.input :reject_media, as: :boolean, wrapper: :with_label, label: I18n.t('admin.domain_block.reject_media'), hint: I18n.t('admin.domain_block.reject_media_hint') + = f.input :reject_media, as: :boolean, wrapper: :with_label, label: I18n.t('admin.domain_blocks.reject_media'), hint: I18n.t('admin.domain_blocks.reject_media_hint') .actions - = f.button :button, t('admin.domain_block.new.create'), type: :submit + = f.button :button, t('.create'), type: :submit diff --git a/app/views/admin/domain_blocks/show.html.haml b/app/views/admin/domain_blocks/show.html.haml index bf9011c52..70dfef9b2 100644 --- a/app/views/admin/domain_blocks/show.html.haml +++ b/app/views/admin/domain_blocks/show.html.haml @@ -1,9 +1,15 @@ - content_for :page_title do - = t('admin.domain_block.show.title', domain: @domain_block.domain) + = t('admin.domain_blocks.show.title', domain: @domain_block.domain) = simple_form_for @domain_block, url: admin_domain_block_path(@domain_block), method: :delete do |f| - = f.input :retroactive, as: :boolean, wrapper: :with_label, label: I18n.t("admin.domain_block.show.retroactive.#{@domain_block.severity}"), hint: I18n.t('admin.domain_block.show.affected_accounts', count: Account.where(domain: @domain_block.domain).count) + = f.input :retroactive, + as: :boolean, + wrapper: :with_label, + label: t(".retroactive.#{@domain_block.severity}"), + hint: t(:affected_accounts, + scope: [:admin, :domain_blocks, :show], + count: @domain_block.accounts_count) .actions - = f.button :button, t('admin.domain_block.show.undo'), type: :submit + = f.button :button, t('.undo'), type: :submit diff --git a/app/views/admin/reports/show.html.haml b/app/views/admin/reports/show.html.haml index 5391d99a8..aa144170d 100644 --- a/app/views/admin/reports/show.html.haml +++ b/app/views/admin/reports/show.html.haml @@ -12,7 +12,7 @@ %p %strong= t('admin.reports.comment.label') \: - = @report.comment.presence || t('reports.comment.none') + = @report.comment.presence || t('admin.reports.comment.none') - unless @report.statuses.empty? %hr/ diff --git a/config/i18n-tasks.yml b/config/i18n-tasks.yml index 7ae143f93..853d148b2 100644 --- a/config/i18n-tasks.yml +++ b/config/i18n-tasks.yml @@ -31,8 +31,22 @@ search: - app/assets/fonts - app/assets/videos +ignore_missing: + - 'activemodel.errors.*' + - 'activerecord.attributes.*' + - 'activerecord.errors.*' + - '{devise,pagination,doorkeeper}.*' + - '{datetime,time}.*' + - 'simple_form.{yes,no}' + - 'simple_form.{placeholders,hints,labels}.*' + - 'simple_form.{error_notification,required}.:' + - 'errors.messages.*' + - 'activerecord.errors.models.doorkeeper/*' + ignore_unused: + - 'activemodel.errors.*' - 'activerecord.attributes.*' + - 'activerecord.errors.*' - '{devise,pagination,doorkeeper}.*' - '{datetime,time}.*' - 'simple_form.{yes,no}' diff --git a/config/locales/bg.yml b/config/locales/bg.yml index e0e60adf7..f751c81a5 100644 --- a/config/locales/bg.yml +++ b/config/locales/bg.yml @@ -160,8 +160,6 @@ bg: disable: Деактивирай enable: Ðктивирай instructions_html: "<strong>Сканирай този QR код Ñ Google Authenticator или подобно приложение от ÑÐ²Ð¾Ñ Ñ‚ÐµÐ»ÐµÑ„Ð¾Ð½</strong>. OÑ‚Ñега нататък, това приложение ще генерира код, който ще трÑбва да въвеждаш при вÑÑко влизане." - plaintext_secret_html: 'Тайна в обикновен текÑÑ‚: <samp>%{secret}</samp>' - warning: Ðко не можеш да наÑтроиш приложението за удоÑтверÑване Ñега, избери "Деактивирай". Ð’ противен Ñлучай, нÑма да можеш да влезеш в акаунта Ñи. users: invalid_email: E-mail адреÑÑŠÑ‚ е невалиден invalid_otp_token: Ðевалиден код diff --git a/config/locales/en.yml b/config/locales/en.yml index 325df5045..039dabf87 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -71,6 +71,7 @@ en: profile_url: Profile URL public: Public push_subscription_expires: PuSH subscription expires + reset_password: Reset password salmon_url: Salmon URL silence: Silence statuses: Statuses @@ -79,7 +80,7 @@ en: undo_suspension: Undo suspension username: Username web: Web - domain_block: + domain_blocks: add_new: Add new created_msg: Domain block is now being processed destroyed_msg: Domain block has been undone @@ -106,6 +107,7 @@ en: silence: Unsilence all existing accounts from this domain suspend: Unsuspend all existing accounts from this domain title: Undo domain block for %{domain} + undo: Undo title: Domain Blocks undo: Undo pubsubhubbub: @@ -258,24 +260,6 @@ en: missing_resource: Could not find the required redirect URL for your account proceed: Proceed to follow prompt: 'You are going to follow:' - reports: - comment: - label: Comment - none: None - delete: Delete - id: ID - mark_as_resolved: Mark as resolved - report: 'Report #%{id}' - reported_account: Reported account - reported_by: Reported by - reports: Reports - resolved: Resolved - silence_account: Silence account - status: Status - suspend_account: Suspend account - target: Target - unresolved: Unresolved - view: View settings: authorized_apps: Authorized apps back: Back to Mastodon @@ -310,11 +294,9 @@ en: instructions_html: "<strong>Scan this QR code into Google Authenticator or a similiar TOTP app on your phone</strong>. From now on, that app will generate tokens that you will have to enter when logging in." lost_recovery_codes: Recovery codes allow you to regain access to your account if you lose your phone. If you've lost your recovery codes, you can regenerate them here. Your old recovery codes will be invalidated. manual_instructions: 'If you can''t scan the QR code and need to enter it manually, here is the plain-text secret:' - recovery_codes: Recovery Codes recovery_codes_regenerated: Recovery codes successfully regenerated recovery_instructions: If you ever lose access to your phone, you can use one of the recovery codes below to regain access to your account. Keep the recovery codes safe, for example by printing them and storing them with other important documents. setup: Set up - warning: If you cannot configure an authenticator app right now, you should click "disable" or you won't be able to login. wrong_code: The entered code was invalid! Are server time and device time correct? users: invalid_email: The e-mail address is invalid diff --git a/config/locales/eo.yml b/config/locales/eo.yml index bfcb13fc2..692fcc43a 100644 --- a/config/locales/eo.yml +++ b/config/locales/eo.yml @@ -155,8 +155,6 @@ eo: disable: Malebligi enable: Ebligi instructions_html: "<strong>Skanu tiun QR-kodon per Google Authenticator aÅ per simila aplikaĵo de via poÅtelefono</strong>. De tiam, la aplikaĵo kreos nombrojn, kiujn vi devos entajpi." - plaintext_secret_html: 'Rekte legebla sekreta kodo: <samp>%{secret}</samp>' - warning: Se vi ne povas agordi aÅtentigan aplikaĵon nun, elektu "malebligi" aÅ vi ne plu povos ensaluti. users: invalid_email: La retpoÅt-adreso ne estas valida invalid_otp_token: La dufaktora aÅtentigila kodo ne estas valida diff --git a/config/locales/es.yml b/config/locales/es.yml index a29fe17fd..e99c592ff 100644 --- a/config/locales/es.yml +++ b/config/locales/es.yml @@ -160,8 +160,6 @@ es: disable: Deshabilitar enable: Habilitar instructions_html: "<strong>Escanea este código QR desde Google Authenticator o una aplicación similar en su teléfono</strong>. Desde ahora, esta aplicación va a generar tokens que tienes que ingresar cuando quieras iniciar sesión." - plaintext_secret_html: 'Código en texto plano: <samp>%{secret}</samp>' - warning: Sà no puedes configurar una aplicación de autenticación ahora, deberás deshabilitar la autenticación de dos factores o no podrás iniciar sesión. users: invalid_email: La dirección de correo es incorrecta invalid_otp_token: Código de dos factores incorrecto diff --git a/config/locales/fi.yml b/config/locales/fi.yml index db8194ff2..3d5e240af 100644 --- a/config/locales/fi.yml +++ b/config/locales/fi.yml @@ -155,8 +155,6 @@ fi: disable: Poista käytöstä enable: Ota käyttöön instructions_html: "<strong>Skannaa tämä QR-koodi Google Authenticator- tai vastaavaan sovellukseen puhelimellasi</strong>. Tästä hetkestä lähtien ohjelma luo koodin, mikä sinun tarvitsee syöttää sisäänkirjautuessa." - plaintext_secret_html: 'Plain-text secret: <samp>%{secret}</samp>' - warning: Jos et juuri nyt voi konfiguroida authenticator-applikaatiota juuri nyt, sinun pitäisi klikata "Poista käytöstä" tai et voi kirjautua sisään. users: invalid_email: Virheellinen sähköposti invalid_otp_token: Virheellinen kaksivaihetunnistuskoodi diff --git a/config/locales/fr.yml b/config/locales/fr.yml index 754eabb95..ec38b411a 100644 --- a/config/locales/fr.yml +++ b/config/locales/fr.yml @@ -79,7 +79,7 @@ fr: undo_suspension: Annuler la suspension username: Nom d'utilisateur web: Web - domain_block: + domain_blocks: add_new: Ajouter domain: Domaine new: @@ -241,24 +241,6 @@ fr: missing_resource: L'URL de redirection n'a pas pu être trouvée proceed: Continuez pour suivre prompt: 'Vous allez suivre :' - reports: - comment: - label: Commentaire - none: Aucun - delete: Supprimer - id: ID - mark_as_resolved: Marqué comme résolu - report: 'Signalement #%{id}' - reported_account: Compte signalé - reported_by: Signalé par - reports: Signalements - resolved: Résolus - silence_account: Rendre le compte muet - status: Statut - suspend_account: Suspendre le compte - target: Cible - unresolved: Non résolus - view: Voir settings: authorized_apps: Applications autorisées back: Retour vers Mastodon @@ -288,8 +270,6 @@ fr: disable: Désactiver enable: Activer instructions_html: "<strong>Scannez ce QR code grâce à Google Authenticator, Authy ou une application similaire sur votre téléphone</strong>. Désormais, cette application générera des jetons que vous devrez saisir à chaque connexion." - plaintext_secret_html: 'Code secret en clair : <samp>%{secret}</samp>' - warning: Si vous ne pouvez pas configurer une application d'authentification maintenant, vous devriez cliquer sur "Désactiver" pour ne pas bloquer l'accès à votre compte. users: invalid_email: L'adresse courriel est invalide invalid_otp_token: Le code d'authentification à deux facteurs est invalide diff --git a/config/locales/hr.yml b/config/locales/hr.yml index f6e6ed446..fed8ea9e7 100644 --- a/config/locales/hr.yml +++ b/config/locales/hr.yml @@ -156,8 +156,6 @@ hr: disable: Onemogući enable: Omogući instructions_html: "<strong>Skeniraj ovaj QR kod into Google Authenticator or a similiar app on your phone</strong>. Od sada, ta aplikacija će generirati tokene koje ćeÅ¡ unijeti pri prijavljivanju." - plaintext_secret_html: 'Plain-text secret: <samp>%{secret}</samp>' - warning: Ako trenuno ne možeÅ¡ konfigurirati authenticator app, trebaÅ¡ kliknuti "onemogući" ili se nećeÅ¡ moći prijaviti. users: invalid_email: E-mail adresa nije valjana invalid_otp_token: Nevaljani dvo-faktorski kod diff --git a/config/locales/it.yml b/config/locales/it.yml index 453de87a5..0ace8a76a 100644 --- a/config/locales/it.yml +++ b/config/locales/it.yml @@ -165,7 +165,6 @@ it: instructions_html: "<strong>Scannerizza questo QR code con Google Authenticator o un'app TOTP simile sul tuo telefono</strong>. Da ora in poi, quell'applicazione genererà codici da inserire necessariamente per eseguire l'accesso." manual_instructions: 'Se non puoi scannerizzare il QR code e hai bisogno di inserirlo manualmente, questo è il codice segreto in chiaro:' setup: Configura - warning: Se non puoi convalidare immediatamente la tua app di autenticazione, dovresti selezionare "disabilita" o non sarai più in grado di eseguire l'accesso. wrong_code: Il codice inserito non è corretto! Assicurati che l'orario del server e l'orario del telefono siano corretti. users: invalid_email: L'indirizzo e-mail inserito non è valido diff --git a/config/locales/ja.yml b/config/locales/ja.yml index 5483e63b5..c9885b5f6 100644 --- a/config/locales/ja.yml +++ b/config/locales/ja.yml @@ -80,7 +80,7 @@ ja: undo_suspension: åœæ¢ã‹ã‚‰æˆ»ã™ username: ユーザーå web: Web - domain_block: + domain_blocks: add_new: æ–°è¦è¿½åŠ created_msg: ドメインブãƒãƒƒã‚¯å‡¦ç†ã‚’完了ã—ã¾ã—㟠destroyed_msg: ドメインブãƒãƒƒã‚¯ã‚’外ã—ã¾ã—㟠@@ -258,24 +258,6 @@ ja: missing_resource: リダイレクト先ãŒè¦‹ã¤ã‹ã‚Šã¾ã›ã‚“ã§ã—㟠proceed: フォãƒãƒ¼ã™ã‚‹ prompt: 'フォãƒãƒ¼ã—よã†ã¨ã—ã¦ã„ã¾ã™:' - reports: - comment: - label: コメント - none: ãªã— - delete: 削除 - id: ID - mark_as_resolved: 解決ã™ã‚‹ - report: 'é€šå ± #%{id}' - reported_account: é€šå ±ã•れã¦ã„るユーザー - reported_by: é€šå ±è€… - reports: é€šå ± - resolved: 解決済㿠- silence_account: ユーザーをサイレンスã™ã‚‹ - status: ç¾çж - suspend_account: ãƒ¦ãƒ¼ã‚¶ãƒ¼ã‚’åœæ¢ã™ã‚‹ - target: é€šå ±ã•れã¦ã„るユーザー - unresolved: 未決 - view: 見る settings: authorized_apps: èªè¨¼æ¸ˆã¿ã‚¢ãƒ—リ back: 戻る @@ -310,11 +292,9 @@ ja: instructions_html: "<strong>Google Authenticatorã‹ã€ã‚‚ã—ãã¯ã»ã‹ã®TOTPアプリã§ã“ã®QRコードをスã‚ャンã—ã¦ãã ã•ã„。</strong>ã“れ以é™ã€ãƒã‚°ã‚¤ãƒ³ã™ã‚‹ã¨ãã¯ãã®ã‚¢ãƒ—リã§ç”Ÿæˆã•れるコードãŒå¿…è¦ã«ãªã‚Šã¾ã™ã€‚" lost_recovery_codes: リカãƒãƒªã‚³ãƒ¼ãƒ‰ã‚’使用ã™ã‚‹ã¨æºå¸¯é›»è©±ã‚’紛失ã—ãŸå ´åˆã§ã‚‚アカウントã«ã‚¢ã‚¯ã‚»ã‚¹ã§ãるよã†ã«ãªã‚Šã¾ã™ã€‚ リカãƒãƒªãƒ¼ã‚³ãƒ¼ãƒ‰ã‚’紛失ã—ãŸå ´åˆã‚‚ã“ã“ã§å†ç”Ÿæˆã™ã‚‹ã“ã¨ãŒã§ãã¾ã™ãŒã€å¤ã„リカãƒãƒªã‚³ãƒ¼ãƒ‰ã¯ç„¡åйã«ãªã‚Šã¾ã™ã€‚ manual_instructions: 'QRコードãŒã‚¹ã‚ャンã§ããšã€æ‰‹å‹•ã§ã®ç™»éŒ²ã‚’希望ã®å ´åˆã¯ã“ã®ã‚·ãƒ¼ã‚¯ãƒ¬ãƒƒãƒˆã‚³ãƒ¼ãƒ‰ã‚’利用ã—ã¦ãã ã•ã„。:' - recovery_codes: リカãƒãƒªãƒ¼ã‚³ãƒ¼ãƒ‰ recovery_codes_regenerated: リカãƒãƒªãƒ¼ã‚³ãƒ¼ãƒ‰ãŒå†ç”Ÿæˆã•れã¾ã—ãŸã€‚ recovery_instructions: æºå¸¯é›»è©±ã‚’紛失ã—ãŸå ´åˆã€ä»¥ä¸‹ã®å†…ã©ã‚Œã‹ã®ãƒªã‚«ãƒãƒªã‚³ãƒ¼ãƒ‰ã‚’使用ã—ã¦ã‚¢ã‚«ã‚¦ãƒ³ãƒˆã¸ã‚¢ã‚¯ã‚»ã‚¹ã™ã‚‹ã“ã¨ãŒã§ãã¾ã™ã€‚ リカãƒãƒªã‚³ãƒ¼ãƒ‰ã¯å°åˆ·ã—ã¦å®‰å…¨ã«ä¿ç®¡ã—ã¦ãã ã•ã„。 setup: åˆæœŸè¨å®š - warning: ç¾åœ¨èªè¨¼ã‚¢ãƒ—リをè¨å®šã§ããªã„å ´åˆã€ç„¡åйã«è¨å®šã—ã¦ã€æœ‰åйã«ã—ãªã„ã§ãã ã•ã„。 wrong_code: コードãŒé–“é•ã£ã¦ã„ã¾ã™ã€‚サーãƒãƒ¼ä¸Šã®æ™‚é–“ã¨ãƒ‡ãƒã‚¤ã‚¹ä¸Šã®æ™‚é–“ãŒä¸€è‡´ã—ã¦ã„ã‚‹ã“ã¨ã‚’確èªã—ã¦ãã ã•ã„。 users: invalid_email: メールアドレスãŒç„¡åйã§ã™ diff --git a/config/locales/nl.yml b/config/locales/nl.yml index 0af0a99e4..577b32454 100644 --- a/config/locales/nl.yml +++ b/config/locales/nl.yml @@ -156,8 +156,6 @@ nl: disable: Uitschakelen enable: Inschakelen instructions_html: "<strong>Scan deze QR-code in Google Authenticator of een soortgelijke app op je mobiele telefoon</strong>. Van nu af aan creëert deze app tokens die je bij aanmelden moet invoeren." - plaintext_secret_html: 'Gewone-tekst geheim: <samp>%{secret}</samp>' - warning: Als je nu geen authenticator-app kunt installeren, moet je "Uitschakelen" kiezen of je kunt niet meer aanmelden. users: invalid_email: Het e-mailadres is ongeldig invalid_otp_token: Ongeldige twee-factorcode diff --git a/config/locales/no.yml b/config/locales/no.yml index d382db926..41a55c6e6 100644 --- a/config/locales/no.yml +++ b/config/locales/no.yml @@ -155,8 +155,6 @@ disable: Skru av enable: Skru pÃ¥ instructions_html: "<strong>Scan denne QR-koden i Google Authenticator eller en lignende app pÃ¥ telefonen din</strong>. Fra nÃ¥ av vil denne applikasjonen generere koder for deg som skal brukes under innlogging" - plaintext_secret_html: 'Plain-text secret: <samp>%{secret}</samp>' - warning: Hvis du ikke kan konfigurere en autentiseringsapp nÃ¥ bør du trykke "Skru av"; ellers vil du ikke kunne logge inn. users: invalid_email: E-postaddressen er ugyldig invalid_otp_token: Ugyldig tofaktorkode diff --git a/config/locales/pl.yml b/config/locales/pl.yml index 3c4c98bc8..f213f3249 100644 --- a/config/locales/pl.yml +++ b/config/locales/pl.yml @@ -155,10 +155,6 @@ pl: disable: Wyłącz enable: Włącz instructions_html: "<strong>Zeskanuj ten kod QR na swoim urzÄ…dzeniu za pomocÄ… Google Authenticator, FreeOTP lub podobnej aplikacji</strong>. Od teraz bÄ™dzie ona generowaÅ‚a kody wymagane przy logowaniu." - plaintext_secret_html: 'Sekret: <samp>%{secret}</samp>' - warning: JeÅ›li nie jesteÅ› w stanie skonfigurować aplikacji uwierzytelniania dwustopniowego w tej chwili, wyłącz uwierzytelnianie dwustopniowe. W przeciwnym wypadku nie bÄ™dziesz siÄ™ w stanie zalogować! users: invalid_email: Adres e-mail jest niepoprawny invalid_otp_token: Kod uwierzytelniajÄ…cy jest niepoprawny - will_paginate: - page_gap: "…" diff --git a/config/locales/pt.yml b/config/locales/pt.yml index 5e86f8b66..5ca18f929 100644 --- a/config/locales/pt.yml +++ b/config/locales/pt.yml @@ -77,7 +77,7 @@ pt: undo_suspension: Desfazer supensão username: Usuário web: Web - domain_block: + domain_blocks: add_new: Adicionar nova created_msg: Bloqueio do domÃnio está sendo processado destroyed_msg: Bloqueio de domÃnio está sendo desfeito diff --git a/config/locales/ru.yml b/config/locales/ru.yml index 4c8cb6a4c..8e6a813bb 100644 --- a/config/locales/ru.yml +++ b/config/locales/ru.yml @@ -158,9 +158,7 @@ ru: enable: Включить instructions_html: "<strong>ОтÑканируйте Ñтот QR-код Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ Google Authenticator или другого подобного Ð¿Ñ€Ð¸Ð»Ð¾Ð¶ÐµÐ½Ð¸Ñ Ð½Ð° Вашем телефоне</strong>. С Ñтого момента приложение будет генерировать токены, которые будет необходимо ввеÑти Ð´Ð»Ñ Ð²Ñ…Ð¾Ð´Ð°." manual_instructions: 'ЕÑли Ð’Ñ‹ не можете отÑканировать QR-код и хотите ввеÑти его вручную, Ñекрет предÑтавлен здеÑÑŒ открытым текÑтом:' - plaintext_secret_html: 'Секрет открытым текÑтом: <samp>%{secret}</samp>' setup: ÐаÑтроить - warning: ЕÑли ÑÐµÐ¹Ñ‡Ð°Ñ Ñƒ Ð’Ð°Ñ Ð½Ðµ получаетÑÑ Ð½Ð°Ñтроить аутентификатор, нажмите "отключить", иначе Ð’Ñ‹ не Ñможете войти! users: invalid_email: Введенный e-mail неверен invalid_otp_token: Введен неверный код diff --git a/config/locales/zh-CN.yml b/config/locales/zh-CN.yml index 48028d00c..667cfe943 100644 --- a/config/locales/zh-CN.yml +++ b/config/locales/zh-CN.yml @@ -145,8 +145,6 @@ zh-CN: disable: ç¦ç”¨ enable: å¯ç”¨ instructions_html: "<strong>使用 Google Authenticator 或类似 APP 扫æäºŒç»´ç </strong>。现在起,APP 将会生æˆç™»é™†æ—¶å¿…须的两æ¥éªŒè¯ç 。" - plaintext_secret_html: 密钥: <samp>%{secret}</samp> - warning: å¦‚æžœä½ çŽ°åœ¨æ²¡æœ‰ Google Authenticator æˆ–ç±»ä¼¼æŽˆæƒ APPï¼Œä½ åº”è¯¥å…ˆã€Œç¦ç”¨ã€æœ¬åŠŸèƒ½ï¼Œå¦åˆ™ä½ å°†ä¸èƒ½æ£å¸¸ç™»é™†ã€‚ users: invalid_email: æ— æ•ˆçš„é‚®ç®± invalid_otp_token: æ— æ•ˆçš„ä¸¤æ¥éªŒè¯ç diff --git a/config/locales/zh-HK.yml b/config/locales/zh-HK.yml index 595e8ffc1..6fe02376b 100644 --- a/config/locales/zh-HK.yml +++ b/config/locales/zh-HK.yml @@ -79,7 +79,7 @@ zh-HK: undo_suspension: è§£é™¤åœæ¬Š username: 用戶å稱 web: 用戶é é¢ - domain_block: + domain_blocks: add_new: 新增 domain: 域å阻隔 new: @@ -246,24 +246,6 @@ zh-HK: missing_resource: ç„¡æ³•æ‰¾åˆ°ä½ ç”¨æˆ¶çš„è½‰æŽ¥ç¶²å€ proceed: ä¸‹ä¸€æ¥ prompt: ä½ å¸Œæœ›é—œæ³¨ï¸° - reports: - comment: - label: 詳細解釋 - none: 沒有 - delete: 刪除 - id: ID - mark_as_resolved: 標示為「已處ç†ã€ - report: 'èˆ‰å ± #%{id}' - reported_account: èˆ‰å ± account - reported_by: èˆ‰å ±è€… - reports: èˆ‰å ± - resolved: 已處埋 - silence_account: 將用戶éœéŸ³ - status: 狀態 - suspend_account: å°‡ç”¨æˆ¶åœæ¬Š - target: å°åƒ - unresolved: 未處埋 - view: 檢視 settings: authorized_apps: æŽˆæ¬Šæ‡‰ç”¨ç¨‹å¼ back: 回到 Mastodon @@ -297,10 +279,7 @@ zh-HK: instructions_html: "<strong>è«‹ç”¨ä½ æ‰‹æ©Ÿçš„èªè‰å™¨æ‡‰ç”¨ç¨‹å¼ï¼ˆå¦‚ Google Authenticatorã€Authy),掃æé€™è£çš„QR 圖形碼</strong>。在雙é‡èªè‰å•Ÿç”¨å¾Œï¼Œä½ ç™»å…¥æ™‚å°‡é ˆè¦ä½¿ç”¨æ¤æ‡‰ç”¨ç¨‹å¼ç”¢ç”Ÿçš„èªè‰ç¢¼ã€‚" manual_instructions: å¦‚æžœä½ ç„¡æ³•æŽƒæ QR 圖形碼,請手動輸入這個文å—密碼︰ setup: è¨å®š - warning: å¦‚æžœä½ ç¾åœ¨ç„¡æ³•æ£ç¢ºè¨å®šä½ 的應用程å¼ï¼Œè«‹å³ã€Œåœç”¨ã€é›™é‡èªè‰ï¼Œå¦å‰‡æ—¥å¾Œå¯èƒ½ç„¡æ³•登入本站。 wrong_code: ä½ è¼¸å…¥çš„èªè‰ç¢¼ä¸¦ä¸æ£ç¢ºï¼å¯èƒ½ä¼ºæœå™¨æ™‚é–“å’Œä½ æ‰‹æ©Ÿä¸ä¸€è‡´ï¼Œè«‹æª¢æŸ¥ä½ 手機的時é˜ï¼Œæˆ–與本站管ç†å“¡è¯çµ¡ã€‚ users: invalid_email: é›»éƒµåœ°å€æ ¼å¼ä¸æ£ç¢º invalid_otp_token: é›™é‡èªè‰ç¢ºèªç¢¼ä¸æ£ç¢º - will_paginate: - page_gap: "…" diff --git a/config/locales/zh-TW.yml b/config/locales/zh-TW.yml index ba5e8d6f5..c29f2e231 100644 --- a/config/locales/zh-TW.yml +++ b/config/locales/zh-TW.yml @@ -79,7 +79,7 @@ zh-TW: undo_suspension: å–æ¶ˆåœæ¬Š username: 使用者å稱 web: Web - domain_block: + domain_blocks: add_new: 新增 domain: 網域 new: @@ -240,24 +240,6 @@ zh-TW: missing_resource: ç„¡æ³•æ‰¾åˆ°è³‡æº proceed: ä¸‹ä¸€æ¥ prompt: '您希望關注︰' - reports: - comment: - label: 留言 - none: ç„¡ - delete: 刪除 - id: ID - mark_as_resolved: 標記為已解決 - report: '檢舉 #%{id}' - reported_account: 被檢舉帳號 - reported_by: 檢舉人 - reports: 檢舉 - resolved: 已解決 - silence_account: éœéŸ³å¸³è™Ÿ - status: 狀態 - suspend_account: åœæ¬Šå¸³è™Ÿ - target: 目標 - unresolved: 未解決 - view: 檢視 settings: authorized_apps: å·²æŽˆæ¬Šæ‡‰ç”¨ç¨‹å¼ back: 回到 Mastodon @@ -291,10 +273,7 @@ zh-TW: instructions_html: <strong>請用您手機的èªè‰å™¨æ‡‰ç”¨ç¨‹å¼ï¼ˆå¦‚ Google Authenticatorã€Authy),掃æé€™è£¡çš„ QR 圖形碼</strong>ã€‚åœ¨é›™å› åèªè‰å•Ÿç”¨å¾Œï¼Œæ‚¨ç™»å…¥æ™‚å°‡é ˆè¦ä½¿ç”¨æ¤æ‡‰ç”¨ç¨‹å¼ç”¢ç”Ÿçš„èªè‰ç¢¼ã€‚ manual_instructions: 如果您無法掃æ QR 圖形碼,請手動輸入︰ setup: è¨å®š - warning: 如果您ç¾åœ¨ç„¡æ³•æ£ç¢ºè¨å®šæ‚¨çš„æ‡‰ç”¨ç¨‹å¼ï¼Œè«‹ç«‹åˆ»ã€Œåœç”¨ã€é›™å› åèªè‰ï¼Œå¦å‰‡æ—¥å¾Œå¯èƒ½ç„¡æ³•登入本站。 wrong_code: 您輸入的èªè‰ç¢¼ä¸¦ä¸æ£ç¢ºï¼å¯èƒ½ä¼ºæœå™¨æ™‚間和您手機ä¸ä¸€è‡´ï¼Œè«‹æª¢æŸ¥æ‚¨æ‰‹æ©Ÿçš„æ™‚間,或與本站管ç†å“¡è¯çµ¡ã€‚ users: invalid_email: ä¿¡ç®±åœ°å€æ ¼å¼ä¸æ£ç¢º invalid_otp_token: é›™å› åèªè‰ç¢¼ä¸æ£ç¢º - will_paginate: - page_gap: "…" diff --git a/config/navigation.rb b/config/navigation.rb index 3d5ba1741..6e2bcd001 100644 --- a/config/navigation.rb +++ b/config/navigation.rb @@ -18,7 +18,7 @@ SimpleNavigation::Configuration.run do |navigation| admin.item :reports, safe_join([fa_icon('flag fw'), t('admin.reports.title')]), admin_reports_url, highlights_on: %r{/admin/reports} admin.item :accounts, safe_join([fa_icon('users fw'), t('admin.accounts.title')]), admin_accounts_url, highlights_on: %r{/admin/accounts} admin.item :pubsubhubbubs, safe_join([fa_icon('paper-plane-o fw'), t('admin.pubsubhubbub.title')]), admin_pubsubhubbub_index_url - admin.item :domain_blocks, safe_join([fa_icon('lock fw'), t('admin.domain_block.title')]), admin_domain_blocks_url, highlights_on: %r{/admin/domain_blocks} + admin.item :domain_blocks, safe_join([fa_icon('lock fw'), t('admin.domain_blocks.title')]), admin_domain_blocks_url, highlights_on: %r{/admin/domain_blocks} admin.item :sidekiq, safe_join([fa_icon('diamond fw'), 'Sidekiq']), sidekiq_url admin.item :pghero, safe_join([fa_icon('database fw'), 'PgHero']), pghero_url admin.item :settings, safe_join([fa_icon('cogs fw'), t('admin.settings.title')]), admin_settings_url -- GitLab