From e3a1955276cb12e8eb57ede30bd1376f5a875310 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Tue, 23 Oct 2018 23:11:37 +0200 Subject: [PATCH 01/36] Bump i18n-tasks from 0.9.25 to 0.9.26 (#9071) Bumps [i18n-tasks](https://github.com/glebm/i18n-tasks) from 0.9.25 to 0.9.26. - [Release notes](https://github.com/glebm/i18n-tasks/releases) - [Changelog](https://github.com/glebm/i18n-tasks/blob/master/CHANGES.md) - [Commits](https://github.com/glebm/i18n-tasks/compare/v0.9.25...v0.9.26) Signed-off-by: dependabot[bot] --- Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile.lock b/Gemfile.lock index c43f3673f..960ef2083 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -271,7 +271,7 @@ GEM rainbow (>= 2.0.0) i18n (1.1.1) concurrent-ruby (~> 1.0) - i18n-tasks (0.9.25) + i18n-tasks (0.9.26) activesupport (>= 4.0.2) ast (>= 2.1.0) erubi From 01c169e796c4d8dd47526fcb07cb6cee1f034d9f Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Wed, 24 Oct 2018 01:31:31 +0200 Subject: [PATCH 02/36] Fix JS error when posting from page without router context (#9073) Fix #9057 --- app/javascript/mastodon/actions/compose.js | 2 +- .../mastodon/features/compose/components/compose_form.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/javascript/mastodon/actions/compose.js b/app/javascript/mastodon/actions/compose.js index fac8d32a1..86d83122f 100644 --- a/app/javascript/mastodon/actions/compose.js +++ b/app/javascript/mastodon/actions/compose.js @@ -142,7 +142,7 @@ export function submitCompose(routerHistory) { } }; - if (response.data.visibility === 'direct' && getState().getIn(['conversations', 'mounted']) <= 0) { + if (response.data.visibility === 'direct' && getState().getIn(['conversations', 'mounted']) <= 0 && routerHistory) { routerHistory.push('/timelines/direct'); } else if (response.data.visibility !== 'direct') { insertIfOnline('home'); diff --git a/app/javascript/mastodon/features/compose/components/compose_form.js b/app/javascript/mastodon/features/compose/components/compose_form.js index 27178fe19..0625ab223 100644 --- a/app/javascript/mastodon/features/compose/components/compose_form.js +++ b/app/javascript/mastodon/features/compose/components/compose_form.js @@ -88,7 +88,7 @@ class ComposeForm extends ImmutablePureComponent { return; } - this.props.onSubmit(this.context.router.history); + this.props.onSubmit(this.context.router ? this.context.router.history : null); } onSuggestionsClearRequested = () => { From c61af83de07aef48ce01df2ed2916c6b15e5ea6a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Wed, 24 Oct 2018 07:50:34 +0200 Subject: [PATCH 03/36] Bump i18n-tasks from 0.9.26 to 0.9.27 (#9079) Bumps [i18n-tasks](https://github.com/glebm/i18n-tasks) from 0.9.26 to 0.9.27. - [Release notes](https://github.com/glebm/i18n-tasks/releases) - [Changelog](https://github.com/glebm/i18n-tasks/blob/master/CHANGES.md) - [Commits](https://github.com/glebm/i18n-tasks/compare/v0.9.26...v0.9.27) Signed-off-by: dependabot[bot] --- Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile.lock b/Gemfile.lock index 960ef2083..75e00446d 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -271,7 +271,7 @@ GEM rainbow (>= 2.0.0) i18n (1.1.1) concurrent-ruby (~> 1.0) - i18n-tasks (0.9.26) + i18n-tasks (0.9.27) activesupport (>= 4.0.2) ast (>= 2.1.0) erubi From c64234c31fde3f9936b53c4eb491e48ada7b622f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Wed, 24 Oct 2018 07:51:04 +0200 Subject: [PATCH 04/36] Bump rspec-rails from 3.8.0 to 3.8.1 (#9078) Bumps [rspec-rails](https://github.com/rspec/rspec-rails) from 3.8.0 to 3.8.1. - [Release notes](https://github.com/rspec/rspec-rails/releases) - [Changelog](https://github.com/rspec/rspec-rails/blob/master/Changelog.md) - [Commits](https://github.com/rspec/rspec-rails/compare/v3.8.0...v3.8.1) Signed-off-by: dependabot[bot] --- Gemfile.lock | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index 75e00446d..c5584da29 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -501,13 +501,13 @@ GEM chunky_png (~> 1.0) rspec-core (3.8.0) rspec-support (~> 3.8.0) - rspec-expectations (3.8.1) + rspec-expectations (3.8.2) diff-lcs (>= 1.2.0, < 2.0) rspec-support (~> 3.8.0) rspec-mocks (3.8.0) diff-lcs (>= 1.2.0, < 2.0) rspec-support (~> 3.8.0) - rspec-rails (3.8.0) + rspec-rails (3.8.1) actionpack (>= 3.0) activesupport (>= 3.0) railties (>= 3.0) From 9f3283086fd0b1591ca657070cae73ff29881adb Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Wed, 24 Oct 2018 23:22:18 +0900 Subject: [PATCH 05/36] Bump capybara from 3.9.0 to 3.10.0 (#9077) Bumps [capybara](https://github.com/teamcapybara/capybara) from 3.9.0 to 3.10.0. - [Release notes](https://github.com/teamcapybara/capybara/releases) - [Changelog](https://github.com/teamcapybara/capybara/blob/master/History.md) - [Commits](https://github.com/teamcapybara/capybara/compare/3.9.0...3.10.0) Signed-off-by: dependabot[bot] --- Gemfile | 2 +- Gemfile.lock | 10 ++++++---- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/Gemfile b/Gemfile index ca38f033a..cfd88f323 100644 --- a/Gemfile +++ b/Gemfile @@ -106,7 +106,7 @@ group :production, :test do end group :test do - gem 'capybara', '~> 3.9' + gem 'capybara', '~> 3.10' gem 'climate_control', '~> 0.2' gem 'faker', '~> 1.9' gem 'microformats', '~> 4.0' diff --git a/Gemfile.lock b/Gemfile.lock index c5584da29..9fac173cc 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -126,13 +126,14 @@ GEM sshkit (~> 1.3) capistrano-yarn (2.0.2) capistrano (~> 3.0) - capybara (3.9.0) + capybara (3.10.0) addressable mini_mime (>= 0.1.3) nokogiri (~> 1.8) rack (>= 1.6.0) rack-test (>= 0.6.3) - xpath (~> 3.1) + regexp_parser (~> 1.2) + xpath (~> 3.2) case_transform (0.2) activesupport charlock_holmes (0.7.6) @@ -490,6 +491,7 @@ GEM redis-store (>= 1.2, < 2) redis-store (1.5.0) redis (>= 2.2, < 5) + regexp_parser (1.2.0) request_store (1.4.1) rack (>= 1.4) responders (2.4.0) @@ -640,7 +642,7 @@ GEM websocket-extensions (>= 0.1.0) websocket-extensions (0.1.3) wisper (2.0.0) - xpath (3.1.0) + xpath (3.2.0) nokogiri (~> 1.8) PLATFORMS @@ -663,7 +665,7 @@ DEPENDENCIES capistrano-rails (~> 1.4) capistrano-rbenv (~> 2.1) capistrano-yarn (~> 2.0) - capybara (~> 3.9) + capybara (~> 3.10) charlock_holmes (~> 0.7.6) chewy (~> 5.0) cld3 (~> 3.2.0) From 288e435fe536dc42fe7a13b8c965f21f8d68fb9e Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Wed, 24 Oct 2018 18:17:15 +0200 Subject: [PATCH 06/36] Show upload options on click as well as hover (#9074) Fix #8918 --- .../mastodon/features/compose/components/upload.js | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/app/javascript/mastodon/features/compose/components/upload.js b/app/javascript/mastodon/features/compose/components/upload.js index 66c93452c..a1e99dcbb 100644 --- a/app/javascript/mastodon/features/compose/components/upload.js +++ b/app/javascript/mastodon/features/compose/components/upload.js @@ -44,11 +44,13 @@ class Upload extends ImmutablePureComponent { this.props.onSubmit(this.context.router.history); } - handleUndoClick = () => { + handleUndoClick = e => { + e.stopPropagation(); this.props.onUndo(this.props.media.get('id')); } - handleFocalPointClick = () => { + handleFocalPointClick = e => { + e.stopPropagation(); this.props.onOpenFocalPoint(this.props.media.get('id')); } @@ -68,6 +70,10 @@ class Upload extends ImmutablePureComponent { this.setState({ focused: true }); } + handleClick = () => { + this.setState({ focused: true }); + } + handleInputBlur = () => { const { dirtyDescription } = this.state; @@ -88,7 +94,7 @@ class Upload extends ImmutablePureComponent { const y = ((focusY / -2) + .5) * 100; return ( -
+
{({ scale }) => (
From d723f2a0a88d4ac106638733b7ba17f8d205850a Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Wed, 24 Oct 2018 18:18:08 +0200 Subject: [PATCH 07/36] Fix RTL layout of status display names (#9075) Fix #2350 --- app/javascript/styles/mastodon/rtl.scss | 15 ++++----------- app/views/stream_entries/_simple_status.html.haml | 1 + 2 files changed, 5 insertions(+), 11 deletions(-) diff --git a/app/javascript/styles/mastodon/rtl.scss b/app/javascript/styles/mastodon/rtl.scss index a86e3e632..ccb53a090 100644 --- a/app/javascript/styles/mastodon/rtl.scss +++ b/app/javascript/styles/mastodon/rtl.scss @@ -130,17 +130,6 @@ body.rtl { float: left; } - .activity-stream .detailed-status.light .detailed-status__display-name > div { - float: right; - margin-right: 0; - margin-left: 10px; - } - - .activity-stream .detailed-status.light .detailed-status__meta span > span { - margin-left: 0; - margin-right: 6px; - } - .status__action-bar { &__counter { @@ -174,6 +163,10 @@ body.rtl { margin-right: 0; } + .detailed-status__display-name .display-name { + text-align: right; + } + .detailed-status__display-avatar { margin-right: 0; margin-left: 10px; diff --git a/app/views/stream_entries/_simple_status.html.haml b/app/views/stream_entries/_simple_status.html.haml index 1b00388b1..1a1dc37eb 100644 --- a/app/views/stream_entries/_simple_status.html.haml +++ b/app/views/stream_entries/_simple_status.html.haml @@ -15,6 +15,7 @@ %span.display-name %bdi %strong.display-name__html.p-name.emojify= display_name(status.account, custom_emojify: true, autoplay: autoplay) +   %span.display-name__account = acct(status.account) = fa_icon('lock') if status.account.locked? From df3a7e724dc72146a09fd72efd95d7e206b4b881 Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Thu, 25 Oct 2018 00:09:45 +0200 Subject: [PATCH 08/36] Fix missing plural keys (#9084) * Update i18n-tasks to feature-missing-plural-keys * Fix pluralizations with missing keys in Arabic Fix #8554 * Add i18n-tasks missing-plural-keys to CircleCI --- .circleci/config.yml | 1 + Gemfile | 2 +- Gemfile.lock | 27 ++++++++++++-------- config/locales/ar.yml | 48 +++++++++--------------------------- config/locales/devise.ar.yml | 4 +-- 5 files changed, 32 insertions(+), 50 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 674d1b02d..add73d677 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -175,6 +175,7 @@ jobs: - *attach_workspace - run: bundle exec i18n-tasks check-normalized - run: bundle exec i18n-tasks unused + - run: bundle exec i18n-tasks missing-plural-keys workflows: version: 2 diff --git a/Gemfile b/Gemfile index cfd88f323..c9a16ee14 100644 --- a/Gemfile +++ b/Gemfile @@ -95,7 +95,7 @@ gem 'rdf-normalize', '~> 0.3' group :development, :test do gem 'fabrication', '~> 2.20' gem 'fuubar', '~> 2.3' - gem 'i18n-tasks', '~> 0.9', require: false + gem 'i18n-tasks', '~> 0.9', require: false, git: 'https://github.com/Gargron/i18n-tasks.git', ref: '7a57fbe7000f4f8120e250a757ab345c28c6885c' gem 'pry-byebug', '~> 3.6' gem 'pry-rails', '~> 0.3' gem 'rspec-rails', '~> 3.8' diff --git a/Gemfile.lock b/Gemfile.lock index 9fac173cc..edb552abb 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,3 +1,19 @@ +GIT + remote: https://github.com/Gargron/i18n-tasks.git + revision: 7a57fbe7000f4f8120e250a757ab345c28c6885c + ref: 7a57fbe7000f4f8120e250a757ab345c28c6885c + specs: + i18n-tasks (0.9.27) + activesupport (>= 4.0.2) + ast (>= 2.1.0) + erubi + highline (>= 2.0.0) + i18n + parser (>= 2.2.3.0) + rails-i18n + rainbow (>= 2.2.2, < 4.0) + terminal-table (>= 1.5.1) + GIT remote: https://github.com/rtomayko/posix-spawn revision: 58465d2e213991f8afb13b984854a49fcdcc980c @@ -272,15 +288,6 @@ GEM rainbow (>= 2.0.0) i18n (1.1.1) concurrent-ruby (~> 1.0) - i18n-tasks (0.9.27) - activesupport (>= 4.0.2) - ast (>= 2.1.0) - erubi - highline (>= 2.0.0) - i18n - parser (>= 2.2.3.0) - rainbow (>= 2.2.2, < 4.0) - terminal-table (>= 1.5.1) idn-ruby (0.1.0) ipaddress (0.8.3) iso-639 (0.2.8) @@ -691,7 +698,7 @@ DEPENDENCIES http_accept_language (~> 2.1) http_parser.rb (~> 0.6)! httplog (~> 1.1) - i18n-tasks (~> 0.9) + i18n-tasks (~> 0.9)! idn-ruby iso-639 json-ld (~> 2.2) diff --git a/config/locales/ar.yml b/config/locales/ar.yml index 4499830f9..36922f1f8 100644 --- a/config/locales/ar.yml +++ b/config/locales/ar.yml @@ -30,22 +30,16 @@ ar: other_instances: خوادم أخرى privacy_policy: سياسة الخصوصية source_code: الشفرة المصدرية - status_count_after: - one: منشور - other: منشورات + status_count_after: منشورات status_count_before: نشروا terms: شروط الخدمة - user_count_after: - one: مستخدِم - other: مستخدِمين + user_count_after: مستخدِمين user_count_before: يستضيف what_is_mastodon: ما هو ماستدون ؟ accounts: choices_html: 'توصيات %{name} :' follow: إتبع - followers: - one: مُتابِع - other: مُتابِعون + followers: مُتابِعون following: مُتابَع joined: انضم·ت في %{date} link_verified_on: تم التحقق مِن مالك هذا الرابط بتاريخ %{date} @@ -57,9 +51,7 @@ ar: people_who_follow: الأشخاص الذين يتبعون %{name} pin_errors: following: يجب أن تكون مِن متابعي حساب الشخص الذي تريد إبرازه - posts: - one: تبويق - other: تبويقات + posts: تبويقات posts_tab_heading: تبويقات posts_with_replies: التبويقات و الردود reserved_username: إسم المستخدم محجوز @@ -268,9 +260,7 @@ ar: suspend: تعليق severity: الشدة show: - affected_accounts: - one: حساب واحد معني في قاعدة البيانات - other: "%{count} حسابات معنية في قاعدة البيانات" + affected_accounts: "%{count} حسابات معنية في قاعدة البيانات" retroactive: silence: إلغاء الكتم عن كافة الحسابات المتواجدة على هذا النطاق suspend: إلغاء التعليق المفروض على كافة حسابات هذا النطاق @@ -570,9 +560,7 @@ ar: generic: changes_saved_msg: تم حفظ التعديلات بنجاح ! save_changes: حفظ التغييرات - validation_errors: - one: هناك شيء ما لا يبدو أنه على ما يُرام بعدُ. يُرجى الإطلاع على الخطأ أدناه - other: هناك شيء ليس على ما يُرام! يُرجى معاينة الأخطاء الـ %{count} التالية + validation_errors: هناك شيء ليس على ما يُرام! يُرجى معاينة الأخطاء الـ %{count} التالية imports: preface: بإمكانك استيراد بيانات قد قُمتَ بتصديرها مِن مثيل خادوم آخَر، كقوائم المستخدِمين الذين كنتَ تتابِعهم أو قُمتَ بحظرهم. success: تم تحميل بياناتك بنجاح وسيتم معالجتها في الوقت المناسب @@ -595,9 +583,7 @@ ar: expires_in_prompt: أبدا generate: توليد invited_by: 'تمت دعوتك من طرف :' - max_uses: - one: استعمال واحد - other: "%{count} استخدامات" + max_uses: "%{count} استخدامات" max_uses_prompt: بلا حدود prompt: توليد و مشاركة روابط للسماح للآخَرين بالنفاذ إلى مثيل الخادوم هذا table: @@ -623,12 +609,8 @@ ar: action: معاينة كافة الإشعارات body: هذا هو مُلَخَّص الرسائل التي فاتتك وذلك منذ آخر زيارة لك في %{since} mention: "%{name} أشار إليك في :" - new_followers_summary: - one: و لقد تحصّلت أيضا على متابِع جديد أثناء فترة غيابك! يا للروعة! - other: رائع، لقد قام بمتابعتك %{count} مُتابِعون جُدد أثناء فترة غيابك عن ماستدون ! - subject: - one: "إشعار جديد واحد منذ آخر زيارة لك لـ \U0001F418" - other: "%{count} إشعارات جديدة منذ آخر زيارة لك إلى \U0001F418" + new_followers_summary: رائع، لقد قام بمتابعتك %{count} مُتابِعون جُدد أثناء فترة غيابك عن ماستدون ! + subject: "%{count} إشعارات جديدة منذ آخر زيارة لك إلى \U0001F418" title: أثناء فترة غيابك … favourite: body: 'أُعجب %{name} بمنشورك :' @@ -746,17 +728,11 @@ ar: statuses: attached: description: 'مُرفَق : %{attached}' - image: - one: "%{count} صورة" - other: "%{count} صُوَر" - video: - one: "%{count} فيديو" - other: "%{count} فيديوهات" + image: "%{count} صُوَر" + video: "%{count} فيديوهات" boosted_from_html: تم إعادة ترقيته مِن %{acct_link} content_warning: 'تحذير عن المحتوى : %{warning}' - disallowed_hashtags: - one: 'يحتوي على وسم ممنوع: %{tags}' - other: 'يحتوي على أحد الوسوم الممنوعة: %{tags}' + disallowed_hashtags: 'يحتوي على أحد الوسوم الممنوعة: %{tags}' language_detection: اكتشاف اللغة تلقائيا open_in_web: إفتح في الويب over_character_limit: تم تجاوز حد الـ %{max} حرف المسموح بها diff --git a/config/locales/devise.ar.yml b/config/locales/devise.ar.yml index cadc4daa8..4d80176c6 100644 --- a/config/locales/devise.ar.yml +++ b/config/locales/devise.ar.yml @@ -77,6 +77,4 @@ ar: expired: إنتهت مدة صلاحيته، الرجاء طلب واحد جديد not_found: لا يوجد not_locked: ليس مقفلاً - not_saved: - one: 'خطأ واحد منَعَ %{resource} مِن القيام بالإحتفاظ :' - other: "%{count} أخطاء منعت %{resource} مِن القيام بالإحتفاظ :" + not_saved: "%{count} أخطاء منعت %{resource} مِن القيام بالإحتفاظ :" From e8ffecbd3606a1558563e0cb5f8ea296a6ab2ede Mon Sep 17 00:00:00 2001 From: Yamagishi Kazutoshi Date: Thu, 25 Oct 2018 07:10:01 +0900 Subject: [PATCH 09/36] Set @body_classes to admin layout (#9081) --- app/controllers/admin/base_controller.rb | 11 +++++++++-- app/controllers/filters_controller.rb | 5 +++++ app/controllers/invites_controller.rb | 5 +++++ app/controllers/settings/applications_controller.rb | 5 +++++ app/controllers/settings/deletes_controller.rb | 5 +++++ app/controllers/settings/exports_controller.rb | 7 +++++++ .../settings/follower_domains_controller.rb | 5 +++++ app/controllers/settings/imports_controller.rb | 5 +++++ app/controllers/settings/migrations_controller.rb | 5 +++++ app/controllers/settings/notifications_controller.rb | 5 +++++ app/controllers/settings/preferences_controller.rb | 5 +++++ app/controllers/settings/profiles_controller.rb | 5 +++++ app/controllers/settings/sessions_controller.rb | 5 +++++ .../confirmations_controller.rb | 5 +++++ .../recovery_codes_controller.rb | 7 +++++++ .../settings/two_factor_authentications_controller.rb | 5 +++++ app/views/layouts/admin.html.haml | 2 +- 17 files changed, 89 insertions(+), 3 deletions(-) diff --git a/app/controllers/admin/base_controller.rb b/app/controllers/admin/base_controller.rb index 7fb69d578..8593b582a 100644 --- a/app/controllers/admin/base_controller.rb +++ b/app/controllers/admin/base_controller.rb @@ -5,8 +5,15 @@ module Admin include Authorization include AccountableConcern - before_action :require_staff! - layout 'admin' + + before_action :require_staff! + before_action :set_body_classes + + private + + def set_body_classes + @body_classes = 'admin' + end end end diff --git a/app/controllers/filters_controller.rb b/app/controllers/filters_controller.rb index 175dbab07..d2e0fb739 100644 --- a/app/controllers/filters_controller.rb +++ b/app/controllers/filters_controller.rb @@ -7,6 +7,7 @@ class FiltersController < ApplicationController before_action :set_filters, only: :index before_action :set_filter, only: [:edit, :update, :destroy] + before_action :set_body_classes def index @filters = current_account.custom_filters @@ -54,4 +55,8 @@ class FiltersController < ApplicationController def resource_params params.require(:custom_filter).permit(:phrase, :expires_in, :irreversible, :whole_word, context: []) end + + def set_body_classes + @body_classes = 'admin' + end end diff --git a/app/controllers/invites_controller.rb b/app/controllers/invites_controller.rb index 3aaa2776f..fdb3a0962 100644 --- a/app/controllers/invites_controller.rb +++ b/app/controllers/invites_controller.rb @@ -6,6 +6,7 @@ class InvitesController < ApplicationController layout 'admin' before_action :authenticate_user! + before_action :set_body_classes def index authorize :invite, :create? @@ -44,4 +45,8 @@ class InvitesController < ApplicationController def resource_params params.require(:invite).permit(:max_uses, :expires_in, :autofollow) end + + def set_body_classes + @body_classes = 'admin' + end end diff --git a/app/controllers/settings/applications_controller.rb b/app/controllers/settings/applications_controller.rb index 2a4962311..a1a2c57fa 100644 --- a/app/controllers/settings/applications_controller.rb +++ b/app/controllers/settings/applications_controller.rb @@ -6,6 +6,7 @@ class Settings::ApplicationsController < ApplicationController before_action :authenticate_user! before_action :set_application, only: [:show, :update, :destroy, :regenerate] before_action :prepare_scopes, only: [:create, :update] + before_action :set_body_classes def index @applications = current_user.applications.order(id: :desc).page(params[:page]) @@ -69,4 +70,8 @@ class Settings::ApplicationsController < ApplicationController scopes = params.fetch(:doorkeeper_application, {}).fetch(:scopes, nil) params[:doorkeeper_application][:scopes] = scopes.join(' ') if scopes.is_a? Array end + + def set_body_classes + @body_classes = 'admin' + end end diff --git a/app/controllers/settings/deletes_controller.rb b/app/controllers/settings/deletes_controller.rb index 80002b995..97f3946c8 100644 --- a/app/controllers/settings/deletes_controller.rb +++ b/app/controllers/settings/deletes_controller.rb @@ -5,6 +5,7 @@ class Settings::DeletesController < ApplicationController before_action :check_enabled_deletion before_action :authenticate_user! + before_action :set_body_classes def show @confirmation = Form::DeleteConfirmation.new @@ -29,4 +30,8 @@ class Settings::DeletesController < ApplicationController def delete_params params.require(:form_delete_confirmation).permit(:password) end + + def set_body_classes + @body_classes = 'admin' + end end diff --git a/app/controllers/settings/exports_controller.rb b/app/controllers/settings/exports_controller.rb index 869e11d3b..3a2334ef0 100644 --- a/app/controllers/settings/exports_controller.rb +++ b/app/controllers/settings/exports_controller.rb @@ -6,6 +6,7 @@ class Settings::ExportsController < ApplicationController layout 'admin' before_action :authenticate_user! + before_action :set_body_classes def show @export = Export.new(current_account) @@ -20,4 +21,10 @@ class Settings::ExportsController < ApplicationController redirect_to settings_export_path end + + private + + def set_body_classes + @body_classes = 'admin' + end end diff --git a/app/controllers/settings/follower_domains_controller.rb b/app/controllers/settings/follower_domains_controller.rb index a128bd136..9c39e66bb 100644 --- a/app/controllers/settings/follower_domains_controller.rb +++ b/app/controllers/settings/follower_domains_controller.rb @@ -4,6 +4,7 @@ class Settings::FollowerDomainsController < ApplicationController layout 'admin' before_action :authenticate_user! + before_action :set_body_classes def show @account = current_account @@ -25,4 +26,8 @@ class Settings::FollowerDomainsController < ApplicationController def bulk_params params.permit(select: []) end + + def set_body_classes + @body_classes = 'admin' + end end diff --git a/app/controllers/settings/imports_controller.rb b/app/controllers/settings/imports_controller.rb index 0db13d1ca..e9548ce62 100644 --- a/app/controllers/settings/imports_controller.rb +++ b/app/controllers/settings/imports_controller.rb @@ -5,6 +5,7 @@ class Settings::ImportsController < ApplicationController before_action :authenticate_user! before_action :set_account + before_action :set_body_classes def show @import = Import.new @@ -31,4 +32,8 @@ class Settings::ImportsController < ApplicationController def import_params params.require(:import).permit(:data, :type) end + + def set_body_classes + @body_classes = 'admin' + end end diff --git a/app/controllers/settings/migrations_controller.rb b/app/controllers/settings/migrations_controller.rb index bc6436b87..bd4f9c87a 100644 --- a/app/controllers/settings/migrations_controller.rb +++ b/app/controllers/settings/migrations_controller.rb @@ -4,6 +4,7 @@ class Settings::MigrationsController < ApplicationController layout 'admin' before_action :authenticate_user! + before_action :set_body_classes def show @migration = Form::Migration.new(account: current_account.moved_to_account) @@ -31,4 +32,8 @@ class Settings::MigrationsController < ApplicationController current_account.moved_to_account_id != @migration.account&.id && current_account.id != @migration.account&.id end + + def set_body_classes + @body_classes = 'admin' + end end diff --git a/app/controllers/settings/notifications_controller.rb b/app/controllers/settings/notifications_controller.rb index fe45c17b2..d0754296c 100644 --- a/app/controllers/settings/notifications_controller.rb +++ b/app/controllers/settings/notifications_controller.rb @@ -4,6 +4,7 @@ class Settings::NotificationsController < ApplicationController layout 'admin' before_action :authenticate_user! + before_action :set_body_classes def show; end @@ -29,4 +30,8 @@ class Settings::NotificationsController < ApplicationController interactions: %i(must_be_follower must_be_following must_be_following_dm) ) end + + def set_body_classes + @body_classes = 'admin' + end end diff --git a/app/controllers/settings/preferences_controller.rb b/app/controllers/settings/preferences_controller.rb index b83900f07..7bb5fb112 100644 --- a/app/controllers/settings/preferences_controller.rb +++ b/app/controllers/settings/preferences_controller.rb @@ -4,6 +4,7 @@ class Settings::PreferencesController < ApplicationController layout 'admin' before_action :authenticate_user! + before_action :set_body_classes def show; end @@ -51,4 +52,8 @@ class Settings::PreferencesController < ApplicationController interactions: %i(must_be_follower must_be_following) ) end + + def set_body_classes + @body_classes = 'admin' + end end diff --git a/app/controllers/settings/profiles_controller.rb b/app/controllers/settings/profiles_controller.rb index fe265c81d..5b3bfd71f 100644 --- a/app/controllers/settings/profiles_controller.rb +++ b/app/controllers/settings/profiles_controller.rb @@ -7,6 +7,7 @@ class Settings::ProfilesController < ApplicationController before_action :authenticate_user! before_action :set_account + before_action :set_body_classes obfuscate_filename [:account, :avatar] obfuscate_filename [:account, :header] @@ -34,4 +35,8 @@ class Settings::ProfilesController < ApplicationController def set_account @account = current_user.account end + + def set_body_classes + @body_classes = 'admin' + end end diff --git a/app/controllers/settings/sessions_controller.rb b/app/controllers/settings/sessions_controller.rb index 0da1b027b..74cebc07b 100644 --- a/app/controllers/settings/sessions_controller.rb +++ b/app/controllers/settings/sessions_controller.rb @@ -2,6 +2,7 @@ class Settings::SessionsController < ApplicationController before_action :set_session, only: :destroy + before_action :set_body_classes def destroy @session.destroy! @@ -14,4 +15,8 @@ class Settings::SessionsController < ApplicationController def set_session @session = current_user.session_activations.find(params[:id]) end + + def set_body_classes + @body_classes = 'admin' + end end diff --git a/app/controllers/settings/two_factor_authentication/confirmations_controller.rb b/app/controllers/settings/two_factor_authentication/confirmations_controller.rb index 8d534960d..ee567c2a7 100644 --- a/app/controllers/settings/two_factor_authentication/confirmations_controller.rb +++ b/app/controllers/settings/two_factor_authentication/confirmations_controller.rb @@ -7,6 +7,7 @@ module Settings before_action :authenticate_user! before_action :ensure_otp_secret + before_action :set_body_classes def new prepare_two_factor_form @@ -43,6 +44,10 @@ module Settings def ensure_otp_secret redirect_to settings_two_factor_authentication_path unless current_user.otp_secret end + + def set_body_classes + @body_classes = 'admin' + end end end end diff --git a/app/controllers/settings/two_factor_authentication/recovery_codes_controller.rb b/app/controllers/settings/two_factor_authentication/recovery_codes_controller.rb index e591e9502..bfb103620 100644 --- a/app/controllers/settings/two_factor_authentication/recovery_codes_controller.rb +++ b/app/controllers/settings/two_factor_authentication/recovery_codes_controller.rb @@ -6,6 +6,7 @@ module Settings layout 'admin' before_action :authenticate_user! + before_action :set_body_classes def create @recovery_codes = current_user.generate_otp_backup_codes! @@ -13,6 +14,12 @@ module Settings flash[:notice] = I18n.t('two_factor_authentication.recovery_codes_regenerated') render :index end + + private + + def set_body_classes + @body_classes = 'admin' + end end end end diff --git a/app/controllers/settings/two_factor_authentications_controller.rb b/app/controllers/settings/two_factor_authentications_controller.rb index 863cc7351..e4d8aed41 100644 --- a/app/controllers/settings/two_factor_authentications_controller.rb +++ b/app/controllers/settings/two_factor_authentications_controller.rb @@ -6,6 +6,7 @@ module Settings before_action :authenticate_user! before_action :verify_otp_required, only: [:create] + before_action :set_body_classes def show @confirmation = Form::TwoFactorConfirmation.new @@ -43,5 +44,9 @@ module Settings current_user.validate_and_consume_otp!(confirmation_params[:code]) || current_user.invalidate_otp_backup_code!(confirmation_params[:code]) end + + def set_body_classes + @body_classes = 'admin' + end end end diff --git a/app/views/layouts/admin.html.haml b/app/views/layouts/admin.html.haml index c98d85f7b..6ce67d91e 100644 --- a/app/views/layouts/admin.html.haml +++ b/app/views/layouts/admin.html.haml @@ -17,4 +17,4 @@ = yield -= render template: 'layouts/application', locals: { body_classes: 'admin' } += render template: 'layouts/application' From 9b5348240eb78814690691288c655ede7d7f9415 Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Thu, 25 Oct 2018 01:17:01 +0200 Subject: [PATCH 10/36] Add consistent interpolations check to CircleCI (#9072) * Add consistent interpolations check to CircleCI * Fix locale strings using wrong variables --- .circleci/config.yml | 5 +++-- config/locales/ar.yml | 12 ++++++------ config/locales/bg.yml | 6 ++---- config/locales/ca.yml | 2 +- config/locales/devise.bg.yml | 6 +++--- config/locales/devise.ca.yml | 2 +- config/locales/devise.fr.yml | 4 ++-- config/locales/devise.he.yml | 2 +- config/locales/devise.hr.yml | 2 +- config/locales/devise.hu.yml | 2 +- config/locales/devise.io.yml | 6 +++--- config/locales/devise.ja.yml | 2 +- config/locales/devise.nl.yml | 4 ++-- config/locales/devise.no.yml | 2 +- config/locales/devise.oc.yml | 4 ++-- config/locales/devise.pl.yml | 4 ++-- config/locales/devise.pt-BR.yml | 2 +- config/locales/devise.uk.yml | 2 +- config/locales/devise.zh-HK.yml | 2 +- config/locales/devise.zh-TW.yml | 2 +- config/locales/he.yml | 2 +- config/locales/hr.yml | 2 +- config/locales/id.yml | 6 ++---- config/locales/io.yml | 2 +- config/locales/pt.yml | 2 +- config/locales/simple_form.co.yml | 4 ++-- config/locales/simple_form.de.yml | 4 ++-- config/locales/simple_form.fi.yml | 4 ++-- config/locales/simple_form.fr.yml | 4 ++-- config/locales/simple_form.io.yml | 4 ++-- config/locales/simple_form.oc.yml | 4 ++-- config/locales/simple_form.uk.yml | 4 ++-- config/locales/simple_form.zh-CN.yml | 4 ++-- config/locales/sk.yml | 2 +- config/locales/sr-Latn.yml | 2 +- config/locales/sv.yml | 2 +- config/locales/th.yml | 1 - config/locales/tr.yml | 2 +- config/locales/zh-HK.yml | 6 ++---- 39 files changed, 64 insertions(+), 70 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index add73d677..c1b963472 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -13,8 +13,8 @@ aliases: ALLOW_NOPAM: true CONTINUOUS_INTEGRATION: true DISABLE_SIMPLECOV: true - PAM_ENABLED: true - PAM_DEFAULT_SERVICE: pam_test + PAM_ENABLED: true + PAM_DEFAULT_SERVICE: pam_test PAM_CONTROLLED_SERVICE: pam_test_controlled working_directory: ~/projects/mastodon/ @@ -176,6 +176,7 @@ jobs: - run: bundle exec i18n-tasks check-normalized - run: bundle exec i18n-tasks unused - run: bundle exec i18n-tasks missing-plural-keys + - run: bundle exec i18n-tasks check-consistent-interpolations workflows: version: 2 diff --git a/config/locales/ar.yml b/config/locales/ar.yml index 36922f1f8..afbb32088 100644 --- a/config/locales/ar.yml +++ b/config/locales/ar.yml @@ -162,8 +162,8 @@ ar: web: الويب action_logs: actions: - assigned_to_self_report: قام {name} بتعيين التقرير٪ {target} لأنفسهم - change_email_user: غيّر٪ {name} عنوان البريد الإلكتروني للمستخدم٪ {target} + assigned_to_self_report: قام %{name} بتعيين التقرير %{target} لأنفسهم + change_email_user: غيّر %{name} عنوان البريد الإلكتروني للمستخدم %{target} confirm_user: "%{name} قد قام بتأكيد عنوان البريد الإلكتروني لـ %{target}" create_custom_emoji: "%{name} قام برفع إيموجي جديد %{target}" create_domain_block: "%{name} قام بحجب نطاق %{target}" @@ -179,13 +179,13 @@ ar: enable_user: لقد قام %{name} بتنشيط تسجيل الدخول للمستخدِم %{target} memorialize_account: لقد قام %{name} بتحويل حساب %{target} إلى صفحة تذكارية promote_user: "%{name} قام بترقية المستخدم %{target}" - remove_avatar_user: تمت إزالة٪ {name} الصورة الرمزية٪ {target} - reopen_report: تمت إعادة فتح التقرير {name}٪ {target} + remove_avatar_user: تمت إزالة %{name} الصورة الرمزية %{target} + reopen_report: تمت إعادة فتح التقرير %{name} %{target} reset_password_user: "%{name} لقد قام بإعادة تعيين الكلمة السرية الخاصة بـ %{target}" resolve_report: قام %{name} بحل التقرير %{target} silence_account: لقد قام %{name} بكتم حساب %{target} suspend_account: لقد قام %{name} بتعليق حساب %{target} - unassigned_report: "٪ {name} تقرير غير معتمد٪ {target}" + unassigned_report: "%{name} تقرير غير معتمد %{target}" unsilence_account: لقد قام %{name} بإلغاء الكتم عن حساب %{target} unsuspend_account: لقد قام %{name} بإلغاء التعليق المفروض على حساب %{target} update_custom_emoji: "%{name} قام بتحديث الإيموجي %{target}" @@ -431,7 +431,7 @@ ar: admin_mailer: new_report: body: قام %{reporter} بالإبلاغ عن %{target} - body_remote: أبلغ شخص ما من٪ {domain} عن٪ {target} + body_remote: أبلغ شخص ما من %{domain} عن %{target} subject: تقرير جديد ل%{instance} (#%{id}) application_mailer: notification_preferences: تعديل خيارات البريد الإلكتروني diff --git a/config/locales/bg.yml b/config/locales/bg.yml index 8c11ac7b7..9813aea6f 100644 --- a/config/locales/bg.yml +++ b/config/locales/bg.yml @@ -61,9 +61,7 @@ bg: generic: changes_saved_msg: Успешно запазване на промените! save_changes: Запази промените - validation_errors: - one: Нещо все още не е наред! Моля, прегледай грешката по-долу - other: Нещо все още не е наред! Моля, прегледай грешките по-долу + validation_errors: Нещо все още не е наред! Моля, прегледай грешките по-долу imports: preface: Можеш да импортираш някои данни, като например всички хора, които следваш или блокираш в акаунта си на тази инстанция, от файлове, създадени чрез експорт в друга инстанция. success: Твоите данни бяха успешно качени и ще бъдат обработени впоследствие. @@ -77,7 +75,7 @@ bg: too_many: Не мога да прикача повече от 4 файла notification_mailer: digest: - body: 'Ето кратко резюме на нещата, които се случиха от последното ти посещение в %{instance} на %{since}:' + body: 'Ето кратко резюме на нещата, които се случиха от последното ти посещение на %{since}:' mention: "%{name} те спомена в:" new_followers_summary: one: Имаш един нов последовател! Ура! diff --git a/config/locales/ca.yml b/config/locales/ca.yml index d7211f654..74f76163c 100644 --- a/config/locales/ca.yml +++ b/config/locales/ca.yml @@ -617,7 +617,7 @@ ca: notification_mailer: digest: action: Veure totes les notificacions - body: Un resum del que et vas perdre en %{instance} desde la darrera visita el %{since} + body: Un resum del que et vas perdre desde la darrera visita el %{since} mention: "%{name} t'ha mencionat en:" new_followers_summary: one: A més, has adquirit un nou seguidor durant la teva absència! Visca! diff --git a/config/locales/devise.bg.yml b/config/locales/devise.bg.yml index 8e1ba6eb4..3c04af81b 100644 --- a/config/locales/devise.bg.yml +++ b/config/locales/devise.bg.yml @@ -8,16 +8,16 @@ bg: failure: already_authenticated: Вече си вътре в профила си. inactive: Профилът ти все още не е активиран. - invalid: Невалиден имейл адрес или парола. + invalid: Невалиден %{authentication_keys}. last_attempt: Разполагаш с още един опит преди профилът ти да бъде заключен. locked: Профилът ти е заключен. - not_found_in_database: Невалидни стойности за %{authentication_keys} или парола. + not_found_in_database: Невалиден %{authentication_keys}. timeout: Сесията ти изтече, моля влез отново, за да продължиш. unauthenticated: Преди да продължиш, трябва да влезеш в профила си или да се регистрираш. unconfirmed: Преди да продължиш, трябва да потвърдиш регистрацията си. mailer: confirmation_instructions: - subject: 'Mastodon: Инструкции за потвърждаване' + subject: 'Mastodon: Инструкции за потвърждаване %{instance}' password_change: subject: 'Mastodon: Паролата е променена' reset_password_instructions: diff --git a/config/locales/devise.ca.yml b/config/locales/devise.ca.yml index 808a5dd0a..4c17f3378 100644 --- a/config/locales/devise.ca.yml +++ b/config/locales/devise.ca.yml @@ -20,7 +20,7 @@ ca: action: Verifica l'adreça de correu explanation: Has creat un compte a %{host} amb aquesta adreça de correu electrònic. Estàs a un sol clic de l'activació. Si no fos així, ignora aquest correu electrònic. extra_html: Si us plau consulta també les regles de la instància i les nostres condicions de servei. - subject: 'Mastodon: Instruccions de confirmació' + subject: 'Mastodon: Instruccions de confirmació %{instance}' title: Verifica l'adreça de correu email_changed: explanation: 'L''adreça de correu del teu compte s''està canviant a:' diff --git a/config/locales/devise.fr.yml b/config/locales/devise.fr.yml index e9c98a63f..b6c9e5bd8 100644 --- a/config/locales/devise.fr.yml +++ b/config/locales/devise.fr.yml @@ -8,10 +8,10 @@ fr: failure: already_authenticated: Vous êtes déjà connecté⋅e. inactive: Votre compte n’est pas encore activé. - invalid: Courriel ou mot de passe incorrect. + invalid: "%{authentication_keys} incorrect." last_attempt: Vous avez droit à une tentative avant que votre compte ne soit verrouillé. locked: Votre compte est verrouillé. - not_found_in_database: Courriel ou mot de passe invalide. + not_found_in_database: "%{authentication_keys} invalide." timeout: Votre session a expiré. Veuillez vous reconnecter pour continuer. unauthenticated: Vous devez vous connecter ou vous inscrire pour continuer. unconfirmed: Vous devez valider votre compte pour continuer. diff --git a/config/locales/devise.he.yml b/config/locales/devise.he.yml index 4a2811b1f..3d8f7fa59 100644 --- a/config/locales/devise.he.yml +++ b/config/locales/devise.he.yml @@ -17,7 +17,7 @@ he: unconfirmed: יש לאמת את כתובת הדוא"ל על מנת להמשיך. mailer: confirmation_instructions: - subject: 'מסטודון: הוראות אימות' + subject: 'מסטודון: הוראות אימות %{instance}' password_change: subject: 'מסטודון: הסיסמא שונתה' reset_password_instructions: diff --git a/config/locales/devise.hr.yml b/config/locales/devise.hr.yml index d578e404f..07c0079ab 100644 --- a/config/locales/devise.hr.yml +++ b/config/locales/devise.hr.yml @@ -16,7 +16,7 @@ hr: unconfirmed: Moraš potvrditi svoju email adresu prije no što nastaviš. mailer: confirmation_instructions: - subject: 'Mastodon: Upute za potvrđivanje' + subject: 'Mastodon: Upute za potvrđivanje %{instance}' email_changed: subject: 'Mastodon: Email adresa je promijenjena' title: Nova email adresa diff --git a/config/locales/devise.hu.yml b/config/locales/devise.hu.yml index 79ee3b194..67baca016 100644 --- a/config/locales/devise.hu.yml +++ b/config/locales/devise.hu.yml @@ -20,7 +20,7 @@ hu: action: Erősítsd meg az e-mail címedet explanation: Ezzel az e-mail címmel kezdeményeztek regisztrációt a(z) %{host} oldalon. Csak egy kattintás, és a felhasználói fiókdat aktiváljuk. Ha a regisztrációt nem te kezdeményezted, kérjük tekintsd ezt az e-mailt tárgytalannak. extra_html: Kérjük tekintsd át a az instancia szabályzatát és a felhasználási feltételeket. - subject: 'Mastodon: Megerősítési lépések' + subject: 'Mastodon: Megerősítési lépések %{instance}' title: E-mail cím megerősítése email_changed: explanation: 'A fiókodhoz tartozó e-mail címet az alábbira módosítod:' diff --git a/config/locales/devise.io.yml b/config/locales/devise.io.yml index 6ba3038bd..fce061a65 100644 --- a/config/locales/devise.io.yml +++ b/config/locales/devise.io.yml @@ -8,16 +8,16 @@ io: failure: already_authenticated: Tu ya esas enirinta. inactive: Tua konto ankore ne konfirmesas. - invalid: Nejusta retpost-adreso o pasvorto. + invalid: Nejusta %{authentication_keys}. last_attempt: Tu ankore povas probar unfoye ante ke tua konto esos extingita. locked: Tua konto esas extingita. - not_found_in_database: Nejusta retpost-adreso o pasvorto. + not_found_in_database: Nejusta %{authentication_keys}. timeout: Tua kunsido expiris. Voluntez rienirar por durar. unauthenticated: Tu devas enirar o membreskar por durar. unconfirmed: Tu devas konfirmar tua konto por durar. mailer: confirmation_instructions: - subject: Instrucioni por konfirmar + subject: Instrucioni por konfirmar %{instance} password_change: subject: Tua pasvorto chanjesis senprobleme. reset_password_instructions: diff --git a/config/locales/devise.ja.yml b/config/locales/devise.ja.yml index 1f6395479..9df0c7332 100644 --- a/config/locales/devise.ja.yml +++ b/config/locales/devise.ja.yml @@ -20,7 +20,7 @@ ja: action: メールアドレスの確認 explanation: このメールアドレスで%{host}にアカウントを作成しました。有効にするまであと一歩です。もし心当たりがない場合、申し訳ありませんがこのメールを無視してください。 extra_html: また インスタンスのルール利用規約 もお読みください。 - subject: 'Mastodon: メールアドレスの確認' + subject: 'Mastodon: メールアドレスの確認 %{instance}' title: メールアドレスの確認 email_changed: explanation: 'アカウントのメールアドレスは以下のように変更されます:' diff --git a/config/locales/devise.nl.yml b/config/locales/devise.nl.yml index b21798deb..637b1e731 100644 --- a/config/locales/devise.nl.yml +++ b/config/locales/devise.nl.yml @@ -8,11 +8,11 @@ nl: failure: already_authenticated: Je bent al ingelogd. inactive: Jouw account is nog niet geactiveerd. - invalid: Ongeldig e-mailadres of wachtwoord. + invalid: Ongeldig %{authentication_keys}. invalid_token: Ongeldige bevestigingscode. last_attempt: Je hebt nog één poging over voordat jouw account wordt opgeschort. locked: Jouw account is opgeschort. - not_found_in_database: Ongeldig e-mailadres of wachtwoord. + not_found_in_database: Ongeldig %{authentication_keys}. timeout: Jouw sessie is verlopen, log opnieuw in. unauthenticated: Je dient in te loggen of te registreren. unconfirmed: Je dient eerst jouw account te bevestigen. diff --git a/config/locales/devise.no.yml b/config/locales/devise.no.yml index ca16c6ba5..222a91aa3 100644 --- a/config/locales/devise.no.yml +++ b/config/locales/devise.no.yml @@ -20,7 +20,7 @@ action: Bekreft e-postadresse explanation: Du har laget en konto på %{host} med denne e-postadressen. Du er ett klikk unna å aktivere den. Hvis dette ikke var deg, vennligst se bort fra denne e-posten. extra_html: Vennligst også sjekk ut instansens regler og våre bruksvilkår. - subject: 'Mastodon: Instruksjoner for å bekrefte e-postadresse' + subject: 'Mastodon: Instruksjoner for å bekrefte e-postadresse %{instance}' title: Bekreft e-postadresse email_changed: explanation: 'E-postadressen til din konto endres til:' diff --git a/config/locales/devise.oc.yml b/config/locales/devise.oc.yml index 06617af34..beecbb426 100644 --- a/config/locales/devise.oc.yml +++ b/config/locales/devise.oc.yml @@ -8,10 +8,10 @@ oc: failure: already_authenticated: Sètz ja connectat. inactive: Vòstre compte es pas encara activat. - invalid: Corrièl o senhal invalid. + invalid: "%{authentication_keys} invalid." last_attempt: Vos demòra un ensag abans que vòstre compte siasque blocat. locked: Vòstre compte es blocat. - not_found_in_database: Corrièl o senhal invalid. + not_found_in_database: "%{authentication_keys} invalid." timeout: Vòstra session a expirat. Mercés de vos tornar connectar per contunhar. unauthenticated: Vos cal vos connectar o marcar abans de contunhar. unconfirmed: Vos cal confirmar vòstra adreça de corrièl abans de contunhar. diff --git a/config/locales/devise.pl.yml b/config/locales/devise.pl.yml index 49fcca024..77afc4bf5 100644 --- a/config/locales/devise.pl.yml +++ b/config/locales/devise.pl.yml @@ -20,7 +20,7 @@ pl: action: Zweryfikuj adres e-mail explanation: Utworzyłeś(-aś) konto na %{host} podając ten adres e-mail. Jedno kliknięcie dzieli Cię od aktywacji tego konta. Jeżeli to nie Ty, zignoruj ten e-mail. extra_html: Przeczytaj też regulamin instancji i nasze zasady użytkowania. - subject: 'Mastodon: Instrukcje weryfikacji adresu e-mail' + subject: 'Mastodon: Instrukcje weryfikacji adresu e-mail na %{instance}' title: Zweryfikuj adres e-mail email_changed: explanation: 'Adres e-mail dla Twojego konta zostanie zmieniony na:' @@ -35,7 +35,7 @@ pl: reconfirmation_instructions: explanation: Potwierdź nowy adres aby zmienić e-mail. extra: Jeżeli nie próbowałeś(-aś) zmienić e-maila, zignoruj tą wiadomość. Adres e-mail przypisany do konta Mastodona nie ulegnie zmianie, jeżeli nie użyjesz powyższego odnośniku. - subject: 'Mastodon: Potwierdź adres e-mail na &{instance}' + subject: 'Mastodon: Potwierdź adres e-mail na %{instance}' title: Zweryfikuj adres e-mail reset_password_instructions: action: Zmień hasło diff --git a/config/locales/devise.pt-BR.yml b/config/locales/devise.pt-BR.yml index 5f47bc901..051329c20 100644 --- a/config/locales/devise.pt-BR.yml +++ b/config/locales/devise.pt-BR.yml @@ -20,7 +20,7 @@ pt-BR: action: Verificar endereço de e-mail explanation: Você criou uma conta em %{host} com esse endereço de e-mail. Você está a um clique de ativá-la. Se não foi você, por favor ignore esse e-mail. extra_html: Por favor confira também as regras da instância e nossos termos de serviço. - subject: 'Mastodon: Instruções de confirmação' + subject: 'Mastodon: Instruções de confirmação para %{instance}' title: Verifique o endereço de e-mail email_changed: explanation: 'O e-mail associado à sua conta será mudado para:' diff --git a/config/locales/devise.uk.yml b/config/locales/devise.uk.yml index 70ac6e4b2..149fc6ce5 100644 --- a/config/locales/devise.uk.yml +++ b/config/locales/devise.uk.yml @@ -17,7 +17,7 @@ uk: unconfirmed: Для продовження Вам потрібно підтвердити Вашу поштову скриньку. mailer: confirmation_instructions: - subject: 'Mastodon: Інструкції для підтвердження' + subject: 'Mastodon: Інструкції для підтвердження %{instance}' password_change: subject: 'Mastodon: Ваш пароль змінений' reset_password_instructions: diff --git a/config/locales/devise.zh-HK.yml b/config/locales/devise.zh-HK.yml index 79e5a3d25..b7d88ef94 100644 --- a/config/locales/devise.zh-HK.yml +++ b/config/locales/devise.zh-HK.yml @@ -20,7 +20,7 @@ zh-HK: action: 驗證電子郵件地址 explanation: 你在 %{host} 上使用這個電子郵件地址建立了一個帳戶。只需點擊下面的連結,即可啟用帳戶。如果你並沒有建立過帳戶,請忽略此郵件。 extra_html: 請記得閱讀本服務站的相關規定使用條款。 - subject: 'Mastodon: 確認電郵地址' + subject: 'Mastodon: 確認電郵地址 %{instance}' title: 驗證電子郵件地址 email_changed: explanation: 你的帳戶的電子郵件地址即將變更為: diff --git a/config/locales/devise.zh-TW.yml b/config/locales/devise.zh-TW.yml index 571429429..195f167a0 100644 --- a/config/locales/devise.zh-TW.yml +++ b/config/locales/devise.zh-TW.yml @@ -20,7 +20,7 @@ zh-TW: action: 驗證 E-mail 地址 explanation: 您已經在 %{host} 上以此 E-mail 地址建立了一個帳號。您距離啟用它只剩一次點擊之遙了。如果這不是你,請忽略此 E-mail 。 extra_html: 同時也請看看該站點的規則我們的服務條款。 - subject: 'Mastodon: 信箱驗證' + subject: 'Mastodon: 信箱驗證 %{instance}' title: 驗證 E-mail 地址 email_changed: explanation: 您帳號的 E-mail 地址被變更為: diff --git a/config/locales/he.yml b/config/locales/he.yml index 09d57da3b..79b1ed822 100644 --- a/config/locales/he.yml +++ b/config/locales/he.yml @@ -297,7 +297,7 @@ he: too_many: לא ניתן להוסיף יותר מארבעה קבצים notification_mailer: digest: - body: 'להלן סיכום זריז של הדברים שקרו על %{instance} מאז ביקורך האחרון ב-%{since}:' + body: 'להלן סיכום זריז של הדברים שקרו על מאז ביקורך האחרון ב-%{since}:' mention: "%{name} פנה אליך ב:" new_followers_summary: one: נוסף לך עוקב! סחתיין! diff --git a/config/locales/hr.yml b/config/locales/hr.yml index a6e7649f2..851b3623b 100644 --- a/config/locales/hr.yml +++ b/config/locales/hr.yml @@ -74,7 +74,7 @@ hr: upload: Upload notification_mailer: digest: - body: 'Ovo je kratak sažetak propuštenog %{instance} od tvog prošlog posjeta %{since}:' + body: 'Ovo je kratak sažetak propuštenog od tvog prošlog posjeta %{since}:' mention: "%{name} te je spomenuo:" new_followers_summary: one: Imaš novog sljedbenika! Yay! diff --git a/config/locales/id.yml b/config/locales/id.yml index 3da3583f6..8595fad99 100644 --- a/config/locales/id.yml +++ b/config/locales/id.yml @@ -204,9 +204,7 @@ id: generic: changes_saved_msg: Perubahan berhasil disimpan! save_changes: Simpan perubahan - validation_errors: - one: Ada yang tidak beres! Mohon tinjau error dibawah ini - other: Ada yang tidak beres! Mohon tinjau error dibawah ini + validation_errors: Ada yang tidak beres! Mohon tinjau error dibawah ini imports: preface: Anda bisa mengimpor data tertentu seperti orang-orang yang anda ikuti atau anda blokir di server ini, dari file yang dibuat oleh fitur expor di server lain. success: Data anda berhasil diupload dan akan diproses sesegera mungkin @@ -221,7 +219,7 @@ id: too_many: Tidak dapat melampirkan lebih dari 4 file notification_mailer: digest: - body: 'Ini adalah ringkasan singkat yang anda lewatkan pada %{instance} sejak kunjungan terakhir anda pada %{since}:' + body: 'Ini adalah ringkasan singkat yang anda lewatkan pada sejak kunjungan terakhir anda pada %{since}:' mention: "%{name} menyebut anda di:" new_followers_summary: one: Anda mendapatkan satu pengikut baru! Hore! diff --git a/config/locales/io.yml b/config/locales/io.yml index b739df3af..d07997663 100644 --- a/config/locales/io.yml +++ b/config/locales/io.yml @@ -201,7 +201,7 @@ io: too_many: Cannot attach more than 4 files notification_mailer: digest: - body: 'Yen mikra rezumo di to, quo eventis en %{instance}, depos ke tu laste vizitis en %{since}:' + body: 'Yen mikra rezumo di to, depos ke tu laste vizitis en %{since}:' mention: "%{name} mencionis tu en:" new_followers_summary: one: Tu obtenis nova sequanto! Yey! diff --git a/config/locales/pt.yml b/config/locales/pt.yml index 5f532ea37..b68ffbd7f 100644 --- a/config/locales/pt.yml +++ b/config/locales/pt.yml @@ -150,7 +150,7 @@ pt: enable_user: "%{name} ativou o acesso para o utilizador %{target}" memorialize_account: "%{name} transformou a conta de %{target} em um memorial" promote_user: "%{name} promoveu o utilizador %{target}" - reset_password_user: "%{name} restabeleceu a palavra-passe do utilizador %{target" + reset_password_user: "%{name} restabeleceu a palavra-passe do utilizador %{target}" resolve_report: "%{name} recusou o relatório %{target}" silence_account: "%{name} silenciou a conta de %{target}" suspend_account: "%{name} suspendeu a conta de %{target}" diff --git a/config/locales/simple_form.co.yml b/config/locales/simple_form.co.yml index c4a6bd169..fc0795a0b 100644 --- a/config/locales/simple_form.co.yml +++ b/config/locales/simple_form.co.yml @@ -4,7 +4,7 @@ co: hints: defaults: autofollow: Quelli·e chì s'arregistranu cù l'invitazione saranu autumaticamente abbunati·e à voi - avatar: Furmatu PNG, GIF o JPG. 2Mo o menu. Sarà ridottu à %{dimensions}px + avatar: Furmatu PNG, GIF o JPG. %{size} o menu. Sarà ridottu à %{dimensions}px bot: Stu contu hè autumatizatu è ùn hè forse micca survegliatu context: Cuntestu·i induve u filtru deve esse applicatu digest: Solu mandatu dopu à una longa perioda d’inattività, è solu s’elli ci sò novi missaghji diretti @@ -13,7 +13,7 @@ co: other: Ci fermanu %{count} caratteri email: Avete da riceve un'e-mail di cunfirmazione fields: Pudete avè fin’à 4 elementi mustrati cum’un tavulone nant’à u vostru prufile - header: Furmatu PNG, GIF o JPG. 2Mo o menu. Sarà ridottu à %{dimensions}px + header: Furmatu PNG, GIF o JPG. %{size} o menu. Sarà ridottu à %{dimensions}px inbox_url: Cupiate l'URL di a pagina d'accolta di u ripetitore chì vulete utilizà irreversible: I statuti filtrati saranu sguassati di manera irreversibile, ancu s'ellu hè toltu u filtru locale: A lingua di l'interfaccia utilizatore, di l'e-mail è di e nutificazione push diff --git a/config/locales/simple_form.de.yml b/config/locales/simple_form.de.yml index cca9361e4..340cd5ee7 100644 --- a/config/locales/simple_form.de.yml +++ b/config/locales/simple_form.de.yml @@ -4,7 +4,7 @@ de: hints: defaults: autofollow: Leute die sich über deine Einladung registrieren werden dir automatisch folgen - avatar: PNG, GIF oder JPG. Maximal %{size}. Wird auf 400×400 px herunterskaliert + avatar: PNG, GIF oder JPG. Maximal %{size}. Wird auf %{dimensions} px herunterskaliert bot: Dieses Konto führt lediglich automatisierte Aktionen durch und wird möglicherweise nicht überwacht context: Ein oder mehrere Aspekte, wo der Filter greifen soll digest: Wenn du lange Zeit inaktiv bist, wird dir eine Zusammenfassung von Erwähnungen in deiner Abwesenheit zugeschickt @@ -13,7 +13,7 @@ de: other: %{count} Zeichen verbleiben email: Du wirst ein Bestätigungs-E-Mail erhalten fields: Du kannst bis zu 4 Elemente als Tabelle dargestellt auf deinem Profil anzeigen lassen - header: PNG, GIF oder JPG. Maximal %{size}. Wird auf 700×335 px herunterskaliert + header: PNG, GIF oder JPG. Maximal %{size}. Wird auf %{dimensions} px herunterskaliert inbox_url: Kopiere die URL von der Startseite des gewünschten Relays irreversible: Gefilterte Beiträge werden unwiderruflich gefiltert, selbst wenn der Filter später entfernt wurde locale: Die Sprache der Oberfläche, E-Mails und Push-Benachrichtigungen diff --git a/config/locales/simple_form.fi.yml b/config/locales/simple_form.fi.yml index e90bd2e0b..e78ba9cc7 100644 --- a/config/locales/simple_form.fi.yml +++ b/config/locales/simple_form.fi.yml @@ -3,13 +3,13 @@ fi: simple_form: hints: defaults: - avatar: PNG, GIF tai JPG. Enintään 2 Mt. Skaalataan kokoon 400 x 400 px + avatar: PNG, GIF tai JPG. Enintään %{size}. Skaalataan kokoon %{dimensions} px digest: Lähetetään vain pitkän poissaolon jälkeen ja vain, jos olet saanut suoria viestejä poissaolosi aikana display_name: one: 1 merkki jäljellä other: %{count} merkkiä jäljellä fields: Sinulla voi olla korkeintaan 4 asiaa profiilissasi taulukossa - header: PNG, GIF tai JPG. Enintään 2 Mt. Skaalataan kokoon 700 x 335 px + header: PNG, GIF tai JPG. Enintään %{size}. Skaalataan kokoon %{dimensions} px locked: Sinun täytyy hyväksyä seuraajat manuaalisesti note: one: 1 merkki jäljellä diff --git a/config/locales/simple_form.fr.yml b/config/locales/simple_form.fr.yml index 6403bced3..40ae0400f 100644 --- a/config/locales/simple_form.fr.yml +++ b/config/locales/simple_form.fr.yml @@ -4,7 +4,7 @@ fr: hints: defaults: autofollow: Les personnes qui s’inscrivent grâce à l’invitation vous suivront automatiquement - avatar: Au format PNG, GIF ou JPG. 2 Mo maximum. Sera réduit à %{dimensions}px + avatar: Au format PNG, GIF ou JPG. %{size} maximum. Sera réduit à %{dimensions}px bot: Ce compte exécute principalement des actions automatisées et pourrait ne pas être surveillé context: Un ou plusieurs contextes où le filtre devrait s’appliquer digest: Uniquement envoyé après une longue période d’inactivité et uniquement si vous avez reçu des messages personnels pendant votre absence @@ -13,7 +13,7 @@ fr: other: %{count} caractères restants email: Vous recevrez un courriel de confirmation fields: Vous pouvez avoir jusqu’à 4 éléments affichés en tant que tableau sur votre profil - header: Au format PNG, GIF ou JPG. 2 Mo maximum. Sera réduit à %{dimensions}px + header: Au format PNG, GIF ou JPG. %{size} maximum. Sera réduit à %{dimensions}px inbox_url: Copiez l’URL depuis la page d’accueil du relais que vous souhaitez utiliser irreversible: Les pouets filtrés disparaîtront irrémédiablement, même si le filtre est supprimé plus tard locale: La langue de l’interface, des courriels et des notifications diff --git a/config/locales/simple_form.io.yml b/config/locales/simple_form.io.yml index cf87aa6d9..c4fc702fe 100644 --- a/config/locales/simple_form.io.yml +++ b/config/locales/simple_form.io.yml @@ -3,9 +3,9 @@ io: simple_form: hints: defaults: - avatar: En la formato PNG, GIF o JPG. Til 2Mo. Esos mikrigita a %{dimensions}px + avatar: En la formato PNG, GIF o JPG. Til %{size}. Esos mikrigita a %{dimensions}px display_name: 30 signi maxime - header: En la formato PNG, GIF o JPG. Til 2Mo. Esos mikrigita a %{dimensions}px + header: En la formato PNG, GIF o JPG. Til %{size}. Esos mikrigita a %{dimensions}px locked: Tu devos aprobar omna demandi di sequado, e tua mesaji esos senchanje nur por tua sequanti. note: 160 signi maxime imports: diff --git a/config/locales/simple_form.oc.yml b/config/locales/simple_form.oc.yml index 5363aa02a..d46befdc1 100644 --- a/config/locales/simple_form.oc.yml +++ b/config/locales/simple_form.oc.yml @@ -4,7 +4,7 @@ oc: hints: defaults: autofollow: Lo monde que se marcan gràcia a l’invitacion vos segràn automaticament - avatar: PNG, GIF o JPG. Maximum 2 Mo. Serà retalhat en %{dimensions}px + avatar: PNG, GIF o JPG. Maximum %{size}. Serà retalhat en %{dimensions}px bot: Avisar lo monde qu’aqueste compte es pas d’una persona context: Un o mai de contèxtes ont lo filtre deuriá s’aplicar digest: Solament enviat aprèp un long moment d’inactivitat e solament s’avètz recebut de messatges personals pendent vòstra abséncia @@ -12,7 +12,7 @@ oc: one: Demòra encara 1 caractèr other: Demòran encara %{count} caractèrs fields: Podètz far veire cap a 4 elements sus vòstre perfil - header: PNG, GIF o JPG. Maximum 2 Mo. Serà retalhada en %{dimensions}px + header: PNG, GIF o JPG. Maximum %{size}. Serà retalhada en %{dimensions}px inbox_url: Copiatz l’URL de la pagina màger del relai que volètz utilizar irreversible: Los tuts filtrats desapareisseràn irreversiblament, encara que lo filtre siá suprimit mai tard locale: La lenga de l’interfàcia d’utilizacion, los messatges e las notificacions diff --git a/config/locales/simple_form.uk.yml b/config/locales/simple_form.uk.yml index 834631fdf..ba25f53e2 100644 --- a/config/locales/simple_form.uk.yml +++ b/config/locales/simple_form.uk.yml @@ -3,10 +3,10 @@ uk: simple_form: hints: defaults: - avatar: PNG, GIF, або JPG. Максимум - 2МБ. Буде зменшено до %{dimensions}px + avatar: PNG, GIF, або JPG. Максимум - %{size}. Буде зменшено до %{dimensions}px bot: Цей аккаунт в основному виконує автоматичні дії та може не відстежуватіся display_name: 'Залишилося символів: %{count}' - header: PNG, GIF, або JPG. Максимум - 2МБ. Буде зменшено до %{dimensions}px + header: PNG, GIF, або JPG. Максимум - %{size}. Буде зменшено до %{dimensions}px locked: Буде вимагати від Вас самостійного підтверждення підписників, змінить приватність постів за замовчуванням на "тільки для підписників" note: 'Осталось символов: %{count}' imports: diff --git a/config/locales/simple_form.zh-CN.yml b/config/locales/simple_form.zh-CN.yml index 36b5a3f66..60a2548d2 100644 --- a/config/locales/simple_form.zh-CN.yml +++ b/config/locales/simple_form.zh-CN.yml @@ -4,12 +4,12 @@ zh-CN: hints: defaults: autofollow: 通过邀请链接注册的用户将会自动关注你 - avatar: 文件大小限制 %{size},只支持 PNG、GIF 或 JPG 格式。图片分辨率将会压缩至 400×400px + avatar: 文件大小限制 %{size},只支持 PNG、GIF 或 JPG 格式。图片分辨率将会压缩至 %{dimensions}px bot: 来自这个帐户的绝大多数操作都是自动进行的,并且可能无人监控 digest: 仅在你长时间未登录,且收到了私信时发送 display_name: 还能输入 %{count} 个字符 fields: 这将会在个人资料页上以表格的形式展示,最多 4 个项目 - header: 文件大小限制 %{size},只支持 PNG、GIF 或 JPG 格式。图片分辨率将会压缩至 700×335px + header: 文件大小限制 %{size},只支持 PNG、GIF 或 JPG 格式。图片分辨率将会压缩至 %{dimensions}px locale: 用户界面、电子邮件和推送通知中使用的语言 locked: 你需要手动审核所有关注请求 note: 还能输入 %{count} 个字符 diff --git a/config/locales/sk.yml b/config/locales/sk.yml index 2bdd3afa6..6b18d31de 100644 --- a/config/locales/sk.yml +++ b/config/locales/sk.yml @@ -332,7 +332,7 @@ sk: delete: Vymaž placeholder: Opíš aké opatrenia boli urobené, alebo akékoľvek iné súvisiace aktualizácie… reopen: Znovu otvor report - report: Nahlásiť + report: 'Nahlásiť #%{id}' reported_account: Nahlásený účet reported_by: Nahlásené užívateľom resolved: Vyriešené diff --git a/config/locales/sr-Latn.yml b/config/locales/sr-Latn.yml index ff31203c8..12867f4eb 100644 --- a/config/locales/sr-Latn.yml +++ b/config/locales/sr-Latn.yml @@ -465,7 +465,7 @@ sr-Latn: title: Moderacija notification_mailer: digest: - body: 'Evo kratak pregled šta ste propustili na instanci %{instance} od poslednje posete od %{since}:' + body: 'Evo kratak pregled šta ste propustili od poslednje posete od %{since}:' mention: "%{name} Vas je pomenuo u:" new_followers_summary: few: Dobili ste %{count} nova pratioca! Sjajno! diff --git a/config/locales/sv.yml b/config/locales/sv.yml index 4f80a46f1..465a9b127 100644 --- a/config/locales/sv.yml +++ b/config/locales/sv.yml @@ -808,7 +808,7 @@ sv: tip_bridge_html: Om du kommer från Twitter kan du hitta dina vänner på Mastodon genom att använda bridge-appen. Det fungerar dock bara om de också har använt bridge-appen! tip_federated_timeline: Den förenade tidslinjen är en störtflodsvy av Mastodon-nätverket. Men det inkluderar bara människor som dina grannar följer, så det är inte komplett. tip_following: Du följer din servers administratör(er) som standard. För att hitta fler intressanta personer, kolla de lokala och förenade tidslinjerna. - tip_local_timeline: Den lokala tidslinjen är en störtflodsvy av personer på% {instance}. Det här är dina närmaste grannar! + tip_local_timeline: Den lokala tidslinjen är en störtflodsvy av personer på %{instance}. Det här är dina närmaste grannar! tip_mobile_webapp: Om din mobila webbläsare erbjuder dig att lägga till Mastodon till ditt hemskärm kan du få push-meddelanden. Det fungerar som en inbyggd app på många sätt! tips: Tips title: Välkommen ombord, %{name}! diff --git a/config/locales/th.yml b/config/locales/th.yml index 3ed73c7f5..44ed5b99e 100644 --- a/config/locales/th.yml +++ b/config/locales/th.yml @@ -224,7 +224,6 @@ th: too_many: แนบมากกว่า 4 ไฟล์ไม่ได้ notification_mailer: digest: - body: 'Here is a brief summary of what you missed on %{instance} since your last visit on %{since}:' mention: "%{name} ส่งข้อความถึงคุณ:" new_followers_summary: one: ยินดีด้วยคุณได้ผู้ติดตามคนใหม่! Yay! diff --git a/config/locales/tr.yml b/config/locales/tr.yml index 99ba89397..3a7c2e68e 100644 --- a/config/locales/tr.yml +++ b/config/locales/tr.yml @@ -222,7 +222,7 @@ tr: too_many: 4'ten fazla dosya ekleyemezsiniz notification_mailer: digest: - body: 'Son ziyaretiniz olan %{since}''den beri %{instance}''da kaçırdığınız şeylerin özeti:' + body: 'Son ziyaretiniz olan %{since}''den beri''da kaçırdığınız şeylerin özeti:' mention: "%{name} senden bahsetti:" new_followers_summary: one: Yeni bir takipçiniz var! diff --git a/config/locales/zh-HK.yml b/config/locales/zh-HK.yml index db7c0c47c..939093595 100644 --- a/config/locales/zh-HK.yml +++ b/config/locales/zh-HK.yml @@ -224,9 +224,7 @@ zh-HK: suspend: 自動刪除 severity: 阻隔分級 show: - affected_accounts: - one: 資料庫中有 %{count} 個用戶受影響 - other: 資料庫中有%{count}個用戶受影響 + affected_accounts: 資料庫中有%{count}個用戶受影響 retroactive: silence: 對此域名的所有用戶取消靜音 suspend: 對此域名的所有用戶取消除名 @@ -530,7 +528,7 @@ zh-HK: notification_mailer: digest: action: 查看所有通知 - body: 這是自從你在%{since}使用%{instance}以後,你錯失了的訊息︰ + body: 這是自從你在%{since}使用以後,你錯失了的訊息︰ mention: "%{name} 在此提及了你︰" new_followers_summary: one: 你新獲得了 1 位關注者了!恭喜! From 4ea718ef18c2171edf8ed0089fd0d28bdfb78ba1 Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Thu, 25 Oct 2018 01:44:02 +0200 Subject: [PATCH 11/36] Migrate all old direct messages to new conversations schema (#9085) --- app/models/account_conversation.rb | 3 ++ ...024224956_migrate_account_conversations.rb | 43 +++++++++++++++++++ db/schema.rb | 2 +- 3 files changed, 47 insertions(+), 1 deletion(-) create mode 100644 db/migrate/20181024224956_migrate_account_conversations.rb diff --git a/app/models/account_conversation.rb b/app/models/account_conversation.rb index b7447d805..cc6b39279 100644 --- a/app/models/account_conversation.rb +++ b/app/models/account_conversation.rb @@ -58,6 +58,9 @@ class AccountConversation < ApplicationRecord def add_status(recipient, status) conversation = find_or_initialize_by(account: recipient, conversation_id: status.conversation_id, participant_account_ids: participants_from_status(recipient, status)) + + return conversation if conversation.status_ids.include?(status.id) + conversation.status_ids << status.id conversation.unread = status.account_id != recipient.id conversation.save diff --git a/db/migrate/20181024224956_migrate_account_conversations.rb b/db/migrate/20181024224956_migrate_account_conversations.rb new file mode 100644 index 000000000..1821e8c27 --- /dev/null +++ b/db/migrate/20181024224956_migrate_account_conversations.rb @@ -0,0 +1,43 @@ +class MigrateAccountConversations < ActiveRecord::Migration[5.2] + disable_ddl_transaction! + + def up + say '' + say 'WARNING: This migration may take a *long* time for large instances' + say 'It will *not* lock tables for any significant time, but it may run' + say 'for a very long time. We will pause for 10 seconds to allow you to' + say 'interrupt this migration if you are not ready.' + say '' + + 10.downto(1) do |i| + say "Continuing in #{i} second#{i == 1 ? '' : 's'}...", true + sleep 1 + end + + local_direct_statuses.find_each do |status| + AccountConversation.add_status(status.account, status) + end + + notifications_about_direct_statuses.find_each do |notification| + AccountConversation.add_status(notification.account, notification.target_status) + end + end + + def down + end + + private + + def local_direct_statuses + Status.unscoped + .local + .where(visibility: :direct) + .includes(:account, mentions: :account) + end + + def notifications_about_direct_statuses + Notification.joins(mention: :status) + .where(activity_type: 'Mention', statuses: { visibility: :direct }) + .includes(:account, mention: { status: [:account, mentions: :account] }) + end +end diff --git a/db/schema.rb b/db/schema.rb index 8facfa259..3c4f41648 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -10,7 +10,7 @@ # # It's strongly recommended that you check this file into your version control system. -ActiveRecord::Schema.define(version: 2018_10_18_205649) do +ActiveRecord::Schema.define(version: 2018_10_24_224956) do # These are extensions that must be enabled in order to support this database enable_extension "plpgsql" From 13e049d7729425ade92a6800357bfd6224a722b8 Mon Sep 17 00:00:00 2001 From: Ben Lubar Date: Wed, 24 Oct 2018 20:13:35 -0500 Subject: [PATCH 12/36] Allow cross-origin requests to /.well-known/* URLs. (#9083) Right now, this includes three endpoints: host-meta, webfinger, and change-password. host-meta and webfinger are publicly available and do not use any authentication. Nothing bad can be done by accessing them in a user's browser. change-password being CORS-enabled will only reveal the URL it redirects to (which is /auth/edit) but not anything about the actual /auth/edit page, because it does not have CORS enabled. The documentation for hosting an instance on a different domain should also be updated to point out that Access-Control-Allow-Origin: * should be set at a minimum for the /.well-known/host-meta redirect to allow browser-based non-proxied instance discovery. --- config/initializers/cors.rb | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/config/initializers/cors.rb b/config/initializers/cors.rb index 681a7498f..36d3663cb 100644 --- a/config/initializers/cors.rb +++ b/config/initializers/cors.rb @@ -9,6 +9,10 @@ Rails.application.config.middleware.insert_before 0, Rack::Cors do allow do origins '*' + resource '/.well-known/*', + headers: :any, + methods: [:get], + credentials: false resource '/@:username', headers: :any, methods: [:get], From 2f0797bdbd7c25b0df3adfaa91d7b4e7bf4d513c Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Thu, 25 Oct 2018 04:42:25 +0200 Subject: [PATCH 13/36] Bump version to 2.6.0rc2 (#9087) * Bump version to 2.6.0rc2 * Update CHANGELOG.md --- CHANGELOG.md | 5 +++++ lib/mastodon/version.rb | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 666ccd14b..f989f111e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -43,6 +43,8 @@ All notable changes to this project will be documented in this file. - Add `description` meta tag (#8941) - Add `Content-Security-Policy` header (#8957) - Add cache for the instance info API (#8765) +- Add suggested follows to search screen in mobile layout (#9010) +- Add CORS header to `/.well-known/*` routes (#9083) ### Changed @@ -57,6 +59,7 @@ All notable changes to this project will be documented in this file. - Change style of success and failure messages (#8973) - Change DM filtering to always allow DMs from staff (#8993) - Change recommended Ruby version to 2.5.3 (#9003) +- Change docker-compose default to persist volumes in current directory (#9055) ### Deprecated @@ -85,6 +88,8 @@ All notable changes to this project will be documented in this file. - Fix crash in streaming API when tag param missing (#8955) - Fix hotkeys not working when no element is focused (#8998) - Fix some hotkeys not working on detailed status view (#9006) +- Fix og:url on status pages (#9047) +- Fix upload option buttons only being visible on hover (#9074) ## [2.5.2] - 2018-10-12 ### Security diff --git a/lib/mastodon/version.rb b/lib/mastodon/version.rb index d0a1542dd..8b26f4ce6 100644 --- a/lib/mastodon/version.rb +++ b/lib/mastodon/version.rb @@ -21,7 +21,7 @@ module Mastodon end def flags - 'rc1' + 'rc2' end def to_a From 4e6cffe00c5d42576fe37771d71b87e1dee60e6b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Thu, 25 Oct 2018 08:29:12 +0200 Subject: [PATCH 14/36] Bump aws-sdk-s3 from 1.21.0 to 1.23.0 (#9089) Bumps [aws-sdk-s3](https://github.com/aws/aws-sdk-ruby) from 1.21.0 to 1.23.0. - [Release notes](https://github.com/aws/aws-sdk-ruby/releases) - [Changelog](https://github.com/aws/aws-sdk-ruby/blob/master/gems/aws-sdk-s3/CHANGELOG.md) - [Commits](https://github.com/aws/aws-sdk-ruby/commits) Signed-off-by: dependabot[bot] --- Gemfile | 2 +- Gemfile.lock | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Gemfile b/Gemfile index c9a16ee14..b68dc54d8 100644 --- a/Gemfile +++ b/Gemfile @@ -15,7 +15,7 @@ gem 'makara', '~> 0.4' gem 'pghero', '~> 2.2' gem 'dotenv-rails', '~> 2.5' -gem 'aws-sdk-s3', '~> 1.21', require: false +gem 'aws-sdk-s3', '~> 1.23', require: false gem 'fog-core', '<= 2.1.0' gem 'fog-openstack', '~> 0.3', require: false gem 'paperclip', '~> 6.0' diff --git a/Gemfile.lock b/Gemfile.lock index edb552abb..d4599590f 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -92,16 +92,16 @@ GEM av (0.9.0) cocaine (~> 0.5.3) aws-eventstream (1.0.1) - aws-partitions (1.105.0) - aws-sdk-core (3.30.0) + aws-partitions (1.106.0) + aws-sdk-core (3.35.0) aws-eventstream (~> 1.0) aws-partitions (~> 1.0) aws-sigv4 (~> 1.0) jmespath (~> 1.0) - aws-sdk-kms (1.9.0) + aws-sdk-kms (1.11.0) aws-sdk-core (~> 3, >= 3.26.0) aws-sigv4 (~> 1.0) - aws-sdk-s3 (1.21.0) + aws-sdk-s3 (1.23.0) aws-sdk-core (~> 3, >= 3.26.0) aws-sdk-kms (~> 1) aws-sigv4 (~> 1.0) @@ -660,7 +660,7 @@ DEPENDENCIES active_record_query_trace (~> 1.5) addressable (~> 2.5) annotate (~> 2.7) - aws-sdk-s3 (~> 1.21) + aws-sdk-s3 (~> 1.23) better_errors (~> 2.5) binding_of_caller (~> 0.7) bootsnap (~> 1.3) From 98b4cdf198d9499a2e51d984ed3eb188ed584c9b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Thu, 25 Oct 2018 08:29:25 +0200 Subject: [PATCH 15/36] Bump parallel_tests from 2.24.0 to 2.25.0 (#9090) Bumps [parallel_tests](https://github.com/grosser/parallel_tests) from 2.24.0 to 2.25.0. - [Release notes](https://github.com/grosser/parallel_tests/releases) - [Commits](https://github.com/grosser/parallel_tests/compare/v2.24.0...v2.25.0) Signed-off-by: dependabot[bot] --- Gemfile | 2 +- Gemfile.lock | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Gemfile b/Gemfile index b68dc54d8..1e48b500a 100644 --- a/Gemfile +++ b/Gemfile @@ -114,7 +114,7 @@ group :test do gem 'rspec-sidekiq', '~> 3.0' gem 'simplecov', '~> 0.16', require: false gem 'webmock', '~> 3.4' - gem 'parallel_tests', '~> 2.24' + gem 'parallel_tests', '~> 2.25' end group :development do diff --git a/Gemfile.lock b/Gemfile.lock index d4599590f..d7ccb59b8 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -393,7 +393,7 @@ GEM av (~> 0.9.0) paperclip (>= 2.5.2) parallel (1.12.1) - parallel_tests (2.24.0) + parallel_tests (2.25.0) parallel parser (2.5.1.2) ast (~> 2.4.0) @@ -723,7 +723,7 @@ DEPENDENCIES ox (~> 2.10) paperclip (~> 6.0) paperclip-av-transcoder (~> 0.6) - parallel_tests (~> 2.24) + parallel_tests (~> 2.25) pg (~> 1.1) pghero (~> 2.2) pkg-config (~> 1.3) From 8445f77a5b9b7c1c16216422f04c44783ffbd2db Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcin=20Miko=C5=82ajczak?= Date: Thu, 25 Oct 2018 12:45:18 +0200 Subject: [PATCH 16/36] i18n: Update Polish translation (#9070) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * i18n: Update Polish translation Signed-off-by: Marcin Mikołajczak * kruci Signed-off-by: Marcin Mikołajczak * Update config/locales/pl.yml Co-Authored-By: m4sk1n --- config/locales/pl.yml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/config/locales/pl.yml b/config/locales/pl.yml index 4921055e3..eb102cdec 100644 --- a/config/locales/pl.yml +++ b/config/locales/pl.yml @@ -136,7 +136,7 @@ pl: most_recent: Najnowsze title: Kolejność outbox_url: Adres skrzynki nadawczej - perform_full_suspension: Całkowicie zawieś + perform_full_suspension: Zawieś profile_url: Adres profilu promote: Podnieś uprawnienia protocol: Protokół @@ -185,6 +185,7 @@ pl: create_domain_block: "%{name} zablokował(a) domenę %{target}" create_email_domain_block: "%{name} dodał(a) domenę e-mail %{target} na czarną listę" demote_user: "%{name} zdegradował(a) użytkownika %{target}" + destroy_custom_emoji: "%{name} usunął(-ęła) emoji %{target}" destroy_domain_block: "%{name} odblokował(a) domenę %{target}" destroy_email_domain_block: "%{name} usunął(-ęła) domenę e-mail %{target} z czarnej listy" destroy_status: "%{name} usunął(-ęła) wpis użytkownika %{target}" @@ -270,6 +271,8 @@ pl: title: Nowa blokada domen reject_media: Odrzucaj pliki multimedialne reject_media_hint: Usuwa przechowywane lokalnie pliki multimedialne i nie pozwala na ich pobieranie. Nieprzydatne przy zawieszeniu + reject_reports: Odrzucaj zgłoszenia + reject_reports_hint: Zgłoszenia z tej instancji będą ignorowane. Nieprzydatne przy zawieszeniu severities: noop: Nic nie rób silence: Wycisz @@ -375,6 +378,9 @@ pl: hero: desc_html: Wyświetlany na stronie głównej. Zalecany jest rozmiar przynajmniej 600x100 pikseli. Jeżeli nie ustawiony, zostanie użyta miniatura instancji. title: Obraz bohatera + mascot: + desc_html: Wyświetlany na wielu stronach. Zalecany jest rozmiar przynajmniej 293px × 205px. Jeżeli nie ustawiono, zostanie użyta domyślna. + title: Obraz maskotki peers_api_enabled: desc_html: Nazwy domen, z którymi ta instancja wchodziła w interakcje title: Publikuj listę znanych instancji From b9d7021c1ba9abdfceeffb36cb7c67885b1fb9fc Mon Sep 17 00:00:00 2001 From: Sascha Date: Thu, 25 Oct 2018 16:05:33 +0200 Subject: [PATCH 17/36] cli: set exit_on_failure for all CLI classes (#9094) --- lib/cli.rb | 4 ++++ lib/mastodon/accounts_cli.rb | 3 +++ lib/mastodon/emoji_cli.rb | 3 +++ lib/mastodon/feeds_cli.rb | 3 +++ lib/mastodon/media_cli.rb | 3 +++ lib/mastodon/settings_cli.rb | 3 +++ 6 files changed, 19 insertions(+) diff --git a/lib/cli.rb b/lib/cli.rb index 208df660f..bff6d5809 100644 --- a/lib/cli.rb +++ b/lib/cli.rb @@ -9,6 +9,10 @@ require_relative 'mastodon/settings_cli' module Mastodon class CLI < Thor + def self.exit_on_failure? + true + end + desc 'media SUBCOMMAND ...ARGS', 'Manage media files' subcommand 'media', Mastodon::MediaCLI diff --git a/lib/mastodon/accounts_cli.rb b/lib/mastodon/accounts_cli.rb index a32bc9533..055333080 100644 --- a/lib/mastodon/accounts_cli.rb +++ b/lib/mastodon/accounts_cli.rb @@ -7,6 +7,9 @@ require_relative 'cli_helper' module Mastodon class AccountsCLI < Thor + def self.exit_on_failure? + true + end option :all, type: :boolean desc 'rotate [USERNAME]', 'Generate and broadcast new keys' long_desc <<-LONG_DESC diff --git a/lib/mastodon/emoji_cli.rb b/lib/mastodon/emoji_cli.rb index 5bc51d034..1987c6394 100644 --- a/lib/mastodon/emoji_cli.rb +++ b/lib/mastodon/emoji_cli.rb @@ -7,6 +7,9 @@ require_relative 'cli_helper' module Mastodon class EmojiCLI < Thor + def self.exit_on_failure? + true + end option :prefix option :suffix option :overwrite, type: :boolean diff --git a/lib/mastodon/feeds_cli.rb b/lib/mastodon/feeds_cli.rb index cca65cf87..817ed4e79 100644 --- a/lib/mastodon/feeds_cli.rb +++ b/lib/mastodon/feeds_cli.rb @@ -6,6 +6,9 @@ require_relative 'cli_helper' module Mastodon class FeedsCLI < Thor + def self.exit_on_failure? + true + end option :all, type: :boolean, default: false option :background, type: :boolean, default: false option :dry_run, type: :boolean, default: false diff --git a/lib/mastodon/media_cli.rb b/lib/mastodon/media_cli.rb index 8aa9f7903..95d2a8d64 100644 --- a/lib/mastodon/media_cli.rb +++ b/lib/mastodon/media_cli.rb @@ -6,6 +6,9 @@ require_relative 'cli_helper' module Mastodon class MediaCLI < Thor + def self.exit_on_failure? + true + end option :days, type: :numeric, default: 7 option :background, type: :boolean, default: false option :verbose, type: :boolean, default: false diff --git a/lib/mastodon/settings_cli.rb b/lib/mastodon/settings_cli.rb index 87c321013..69485600a 100644 --- a/lib/mastodon/settings_cli.rb +++ b/lib/mastodon/settings_cli.rb @@ -6,6 +6,9 @@ require_relative 'cli_helper' module Mastodon class RegistrationsCLI < Thor + def self.exit_on_failure? + true + end desc 'open', 'Open registrations' def open Setting.open_registrations = true From d4cf963749d2f6bb8e47a670e8cc4819ff659f49 Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Thu, 25 Oct 2018 18:12:22 +0200 Subject: [PATCH 18/36] Allow inbox owner to view implicitly targeted ActivityPub payload (#9093) Fix #9091 --- app/controllers/activitypub/inboxes_controller.rb | 2 +- app/lib/activitypub/activity/create.rb | 13 ++++++++++++- app/workers/activitypub/processing_worker.rb | 4 ++-- 3 files changed, 15 insertions(+), 4 deletions(-) diff --git a/app/controllers/activitypub/inboxes_controller.rb b/app/controllers/activitypub/inboxes_controller.rb index af51e32d5..8f5e1887e 100644 --- a/app/controllers/activitypub/inboxes_controller.rb +++ b/app/controllers/activitypub/inboxes_controller.rb @@ -36,6 +36,6 @@ class ActivityPub::InboxesController < Api::BaseController end def process_payload - ActivityPub::ProcessingWorker.perform_async(signed_request_account.id, body.force_encoding('UTF-8')) + ActivityPub::ProcessingWorker.perform_async(signed_request_account.id, body.force_encoding('UTF-8'), @account&.id) end end diff --git a/app/lib/activitypub/activity/create.rb b/app/lib/activitypub/activity/create.rb index 7e6702a63..92cdf4578 100644 --- a/app/lib/activitypub/activity/create.rb +++ b/app/lib/activitypub/activity/create.rb @@ -81,11 +81,22 @@ class ActivityPub::Activity::Create < ActivityPub::Activity @mentions << Mention.new(account: account, silent: true) # If there is at least one silent mention, then the status can be considered - # as a limited-audience status, and not strictly a direct message + # as a limited-audience status, and not strictly a direct message, but only + # if we considered a direct message in the first place next unless @params[:visibility] == :direct @params[:visibility] = :limited end + + # If the payload was delivered to a specific inbox, the inbox owner must have + # access to it, unless they already have access to it anyway + return if @options[:delivered_to_account_id].nil? || @mentions.any? { mention.account_id == @options[:delivered_to_account_id] } + + @mentions << Mention.new(account_id: @options[:delivered_to_account_id], silent: true) + + return unless @param[:visibility] == :direct + + @params[:visibility] = :limited end def attach_tags(status) diff --git a/app/workers/activitypub/processing_worker.rb b/app/workers/activitypub/processing_worker.rb index 0e2e0eddd..a8a3ebf0f 100644 --- a/app/workers/activitypub/processing_worker.rb +++ b/app/workers/activitypub/processing_worker.rb @@ -5,7 +5,7 @@ class ActivityPub::ProcessingWorker sidekiq_options backtrace: true - def perform(account_id, body) - ActivityPub::ProcessCollectionService.new.call(body, Account.find(account_id), override_timestamps: true) + def perform(account_id, body, delivered_to_account_id = nil) + ActivityPub::ProcessCollectionService.new.call(body, Account.find(account_id), override_timestamps: true, delivered_to_account_id: delivered_to_account_id) end end From 7fee968e9fb75d0f6d381009d5c4403c5a027174 Mon Sep 17 00:00:00 2001 From: ThibG Date: Thu, 25 Oct 2018 18:13:19 +0200 Subject: [PATCH 19/36] Do not fetch preview card for mentioned users (#6934) --- app/services/fetch_link_card_service.rb | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/app/services/fetch_link_card_service.rb b/app/services/fetch_link_card_service.rb index 4169c685b..4551aa7e0 100644 --- a/app/services/fetch_link_card_service.rb +++ b/app/services/fetch_link_card_service.rb @@ -17,7 +17,8 @@ class FetchLinkCardService < BaseService return if @url.nil? || @status.preview_cards.any? - @url = @url.to_s + @mentions = status.mentions + @url = @url.to_s RedisLock.acquire(lock_options) do |lock| if lock.acquired? @@ -81,9 +82,16 @@ class FetchLinkCardService < BaseService uri.host.blank? || TagManager.instance.local_url?(uri.to_s) || !%w(http https).include?(uri.scheme) end + def mention_link?(a) + return false if @mentions.nil? + @mentions.any? do |mention| + a['href'] == TagManager.instance.url_for(mention.target) + end + end + def skip_link?(a) # Avoid links for hashtags and mentions (microformats) - a['rel']&.include?('tag') || a['class']&.include?('u-url') + a['rel']&.include?('tag') || a['class']&.include?('u-url') || mention_link?(a) end def attempt_oembed From a2e3401e48a211f8feba85fb29435ee9100077fc Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Fri, 26 Oct 2018 01:54:58 +0200 Subject: [PATCH 20/36] Fix conversations not being marked read on click (#9103) Fix #9096 --- .../mastodon/features/direct_timeline/components/conversation.js | 1 + 1 file changed, 1 insertion(+) diff --git a/app/javascript/mastodon/features/direct_timeline/components/conversation.js b/app/javascript/mastodon/features/direct_timeline/components/conversation.js index 7277b7f0f..ffcd6d281 100644 --- a/app/javascript/mastodon/features/direct_timeline/components/conversation.js +++ b/app/javascript/mastodon/features/direct_timeline/components/conversation.js @@ -56,6 +56,7 @@ export default class Conversation extends ImmutablePureComponent { otherAccounts={accounts} onMoveUp={this.handleHotkeyMoveUp} onMoveDown={this.handleHotkeyMoveDown} + onClick={this.handleClick} /> ); } From 768b0f132d8680563cce34e9abd8f3f3ba8a9bb9 Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Fri, 26 Oct 2018 01:55:08 +0200 Subject: [PATCH 21/36] Fix direct messages column not loading more items on scroll (#9102) Fix #9097 --- .../components/conversations_list.js | 18 +++++++++--------- .../containers/conversations_list_container.js | 2 +- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/app/javascript/mastodon/features/direct_timeline/components/conversations_list.js b/app/javascript/mastodon/features/direct_timeline/components/conversations_list.js index 4684548e0..635c03c1d 100644 --- a/app/javascript/mastodon/features/direct_timeline/components/conversations_list.js +++ b/app/javascript/mastodon/features/direct_timeline/components/conversations_list.js @@ -9,14 +9,14 @@ import { debounce } from 'lodash'; export default class ConversationsList extends ImmutablePureComponent { static propTypes = { - conversationIds: ImmutablePropTypes.list.isRequired, + conversations: ImmutablePropTypes.list.isRequired, hasMore: PropTypes.bool, isLoading: PropTypes.bool, onLoadMore: PropTypes.func, shouldUpdateScroll: PropTypes.func, }; - getCurrentIndex = id => this.props.conversationIds.indexOf(id) + getCurrentIndex = id => this.props.conversations.findIndex(x => x.get('id') === id) handleMoveUp = id => { const elementIndex = this.getCurrentIndex(id) - 1; @@ -41,22 +41,22 @@ export default class ConversationsList extends ImmutablePureComponent { } handleLoadOlder = debounce(() => { - const last = this.props.conversationIds.last(); + const last = this.props.conversations.last(); - if (last) { - this.props.onLoadMore(last); + if (last && last.get('last_status')) { + this.props.onLoadMore(last.get('last_status')); } }, 300, { leading: true }) render () { - const { conversationIds, onLoadMore, ...other } = this.props; + const { conversations, onLoadMore, ...other } = this.props; return ( - {conversationIds.map(item => ( + {conversations.map(item => ( diff --git a/app/javascript/mastodon/features/direct_timeline/containers/conversations_list_container.js b/app/javascript/mastodon/features/direct_timeline/containers/conversations_list_container.js index 81ea812ad..57e17d96f 100644 --- a/app/javascript/mastodon/features/direct_timeline/containers/conversations_list_container.js +++ b/app/javascript/mastodon/features/direct_timeline/containers/conversations_list_container.js @@ -3,7 +3,7 @@ import ConversationsList from '../components/conversations_list'; import { expandConversations } from '../../../actions/conversations'; const mapStateToProps = state => ({ - conversationIds: state.getIn(['conversations', 'items']).map(x => x.get('id')), + conversations: state.getIn(['conversations', 'items']), isLoading: state.getIn(['conversations', 'isLoading'], true), hasMore: state.getIn(['conversations', 'hasMore'], false), }); From 161aeadbb4fcd08bc6a38acae9626f4124c78951 Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Fri, 26 Oct 2018 01:55:24 +0200 Subject: [PATCH 22/36] Remove character counter from edit profile (#9100) * Remove display name and bio counter hint, simply limit input * Remove now redundant translations * Fix code style issue --- app/javascript/packs/public.js | 16 +--------------- app/views/settings/profiles/show.html.haml | 8 ++++---- config/locales/simple_form.ar.yml | 2 -- config/locales/simple_form.ast.yml | 6 ------ config/locales/simple_form.bg.yml | 2 -- config/locales/simple_form.ca.yml | 6 ------ config/locales/simple_form.co.yml | 6 ------ config/locales/simple_form.cs.yml | 6 ------ config/locales/simple_form.cy.yml | 6 ------ config/locales/simple_form.da.yml | 6 ------ config/locales/simple_form.de.yml | 6 ------ config/locales/simple_form.el.yml | 6 ------ config/locales/simple_form.en.yml | 6 ------ config/locales/simple_form.eo.yml | 6 ------ config/locales/simple_form.es.yml | 6 ------ config/locales/simple_form.eu.yml | 6 ------ config/locales/simple_form.fa.yml | 6 ------ config/locales/simple_form.fi.yml | 6 ------ config/locales/simple_form.fr.yml | 6 ------ config/locales/simple_form.gl.yml | 6 ------ config/locales/simple_form.he.yml | 6 ------ config/locales/simple_form.hr.yml | 2 -- config/locales/simple_form.hu.yml | 6 ------ config/locales/simple_form.id.yml | 2 -- config/locales/simple_form.io.yml | 2 -- config/locales/simple_form.it.yml | 6 ------ config/locales/simple_form.ja.yml | 2 -- config/locales/simple_form.ka.yml | 6 ------ config/locales/simple_form.ko.yml | 6 ------ config/locales/simple_form.nl.yml | 6 ------ config/locales/simple_form.no.yml | 6 ------ config/locales/simple_form.oc.yml | 6 ------ config/locales/simple_form.pl.yml | 10 ---------- config/locales/simple_form.pt-BR.yml | 6 ------ config/locales/simple_form.pt.yml | 6 ------ config/locales/simple_form.ru.yml | 10 ---------- config/locales/simple_form.sk.yml | 8 -------- config/locales/simple_form.sl.yml | 3 --- config/locales/simple_form.sr-Latn.yml | 10 ---------- config/locales/simple_form.sr.yml | 10 ---------- config/locales/simple_form.sv.yml | 6 ------ config/locales/simple_form.th.yml | 6 ------ config/locales/simple_form.tr.yml | 2 -- config/locales/simple_form.uk.yml | 2 -- config/locales/simple_form.zh-CN.yml | 2 -- config/locales/simple_form.zh-HK.yml | 6 ------ config/locales/simple_form.zh-TW.yml | 6 ------ 47 files changed, 5 insertions(+), 268 deletions(-) diff --git a/app/javascript/packs/public.js b/app/javascript/packs/public.js index 11dc1bafc..3b02b7c39 100644 --- a/app/javascript/packs/public.js +++ b/app/javascript/packs/public.js @@ -21,7 +21,6 @@ window.addEventListener('message', e => { }); function main() { - const { length } = require('stringz'); const IntlMessageFormat = require('intl-messageformat').default; const { timeAgoString } = require('../mastodon/components/relative_timestamp'); const { delegate } = require('rails-ujs'); @@ -133,26 +132,13 @@ function main() { }); delegate(document, '#account_display_name', 'input', ({ target }) => { - const nameCounter = document.querySelector('.name-counter'); - const name = document.querySelector('.card .display-name strong'); - - if (nameCounter) { - nameCounter.textContent = 30 - length(target.value); - } + const name = document.querySelector('.card .display-name strong'); if (name) { name.innerHTML = emojify(target.value); } }); - delegate(document, '#account_note', 'input', ({ target }) => { - const noteCounter = document.querySelector('.note-counter'); - - if (noteCounter) { - noteCounter.textContent = 160 - length(target.value); - } - }); - delegate(document, '#account_avatar', 'change', ({ target }) => { const avatar = document.querySelector('.card .avatar img'); const [file] = target.files || []; diff --git a/app/views/settings/profiles/show.html.haml b/app/views/settings/profiles/show.html.haml index 42e3840a1..f5c50144b 100644 --- a/app/views/settings/profiles/show.html.haml +++ b/app/views/settings/profiles/show.html.haml @@ -6,8 +6,8 @@ .fields-row .fields-row__column.fields-group.fields-row__column-6 - = f.input :display_name, wrapper: :with_label, hint: t('simple_form.hints.defaults.display_name', count: 30 - @account.display_name.size).html_safe - = f.input :note, wrapper: :with_label, hint: t('simple_form.hints.defaults.note', count: 160 - @account.note.size).html_safe + = f.input :display_name, wrapper: :with_label, input_html: { maxlength: 30 }, hint: false + = f.input :note, wrapper: :with_label, input_html: { maxlength: 160 }, hint: false .fields-row .fields-row__column.fields-row__column-6 @@ -36,8 +36,8 @@ = f.simple_fields_for :fields do |fields_f| .row - = fields_f.input :name, placeholder: t('simple_form.labels.account.fields.name') - = fields_f.input :value, placeholder: t('simple_form.labels.account.fields.value') + = fields_f.input :name, placeholder: t('simple_form.labels.account.fields.name'), input_html: { maxlength: 255 } + = fields_f.input :value, placeholder: t('simple_form.labels.account.fields.value'), input_html: { maxlength: 255 } .fields-row__column.fields-group.fields-row__column-6 %h6= t('verification.verification') diff --git a/config/locales/simple_form.ar.yml b/config/locales/simple_form.ar.yml index dcdc1ffc1..cdd3ddf25 100644 --- a/config/locales/simple_form.ar.yml +++ b/config/locales/simple_form.ar.yml @@ -8,7 +8,6 @@ ar: bot: يُعلِم أنّ هذا الحساب لا يمثل شخصًا context: واحد أو أكثر من السياقات التي يجب أن ينطبق عليها عامل التصفية digest: تُرسَل إليك بعد مُضيّ مدة مِن خمول نشاطك و فقط إذا ما تلقيت رسائل شخصية مباشِرة أثناء فترة غيابك مِن الشبكة - display_name: %{count} حرف باق email: سوف تتلقى رسالة إلكترونية للتأكيد fields: يُمكنك عرض 4 عناصر على شكل جدول في ملفك الشخصي header: ملف PNG أو GIF أو JPG. حجمه على أقصى تصدير %{size}. سيتم تصغيره إلى %{dimensions}px @@ -16,7 +15,6 @@ ar: irreversible: التبويقات التي تم تصفيتها ستختفي لا محالة حتى و إن تمت إزالة عامِل التصفية لاحقًا locale: لغة واجهة المستخدم و الرسائل الإلكترونية و الإشعارات locked: يتطلب منك الموافقة يدويا على طلبات المتابعة - note: %{count} حرف باق password: يُنصح باستخدام 8 أحرف على الأقل phrase: سوف يتم العثور عليه مهما كان نوع النص أو حتى و إن كان داخل الويب فيه تحذير عن المحتوى scopes: ما هي المجالات المسموح بها في التطبيق ؟ إن قمت باختيار أعلى المجالات فيمكنك الإستغناء عن الخَيار اليدوي. diff --git a/config/locales/simple_form.ast.yml b/config/locales/simple_form.ast.yml index a6b3e0733..0d78f419f 100644 --- a/config/locales/simple_form.ast.yml +++ b/config/locales/simple_form.ast.yml @@ -6,13 +6,7 @@ ast: autofollow: La xente que se rexistre pente la invitación va siguite automáticamente bot: Esta cuenta fai principalmente aiciones automatizaes y podría nun supervisase digest: Namái s'unvia tres un periodu llargu d'inactividá y namái si recibiesti cualesquier mensaxe personal na to ausencia - display_name: - one: Queda 1 caráuter - other: Queden %{count} caráuteres irreversible: Los toots peñeraos van desapaecer de mou irreversible, magar que se desanicie la peñera dempués - note: - one: Queda 1 caráuter - other: Queden %{count} caráuteres setting_hide_network: La xente que sigas y teas siguiendo nun va amosase nel perfil setting_theme: Afeuta al aspeutu de Mastodon cuando anicies sesión dende cualesquier preséu. labels: diff --git a/config/locales/simple_form.bg.yml b/config/locales/simple_form.bg.yml index 938dacc95..9441e53b3 100644 --- a/config/locales/simple_form.bg.yml +++ b/config/locales/simple_form.bg.yml @@ -4,10 +4,8 @@ bg: hints: defaults: avatar: PNG, GIF или JPG. До %{size}. Ще бъде смалена до %{dimensions} пиксела - display_name: До 30 символа header: PNG, GIF или JPG. До %{size}. Ще бъде смалена до %{dimensions} пиксела locked: Изисква ръчно одобрение на последователите. По подразбиране, публикациите са достъпни само до последователи. - note: До 160 символа imports: data: CSV файл, експортиран от друга инстанция на Mastodon labels: diff --git a/config/locales/simple_form.ca.yml b/config/locales/simple_form.ca.yml index 53cf6db8e..6c8455a14 100644 --- a/config/locales/simple_form.ca.yml +++ b/config/locales/simple_form.ca.yml @@ -8,17 +8,11 @@ ca: bot: Aquest compte realitza principalment accions automatitzades i pot no estar controlat per cap persona context: Un o diversos contextos on s'ha d'aplicar el filtre digest: Només s'envia després d'un llarg període d'inactivitat amb un resum de les mencions que has rebut en la teva absència - display_name: - one: 1 càracter restant - other: %{count} càracters restans fields: Pots tenir fins a 4 elements que es mostren com a taula al teu perfil header: PNG, GIF o JPG. Màxim %{size}. S'escalarà a %{dimensions}px irreversible: Els nodes filtrats desapareixeran de manera irreversible, fins i tot si el filtre es retira més tard locale: El llenguatge de l’interfície d’usuari, els correus i les notificacions push locked: Requereix que aprovis manualment els seguidors - note: - one: 1 càracter restant - other: %{count} caràcters restants phrase: Es combinarà independentment del format en el text o l'avís de contingut d'un toot setting_default_language: La llengua dels teus toots pot ser detectada automàticament però no sempre acuradament setting_hide_network: Qui tu segueixes i els que et segueixen a tu no es mostraran en el teu perfil diff --git a/config/locales/simple_form.co.yml b/config/locales/simple_form.co.yml index fc0795a0b..b200dfb48 100644 --- a/config/locales/simple_form.co.yml +++ b/config/locales/simple_form.co.yml @@ -8,9 +8,6 @@ co: bot: Stu contu hè autumatizatu è ùn hè forse micca survegliatu context: Cuntestu·i induve u filtru deve esse applicatu digest: Solu mandatu dopu à una longa perioda d’inattività, è solu s’elli ci sò novi missaghji diretti - display_name: - one: Ci ferma 1 caratteru - other: Ci fermanu %{count} caratteri email: Avete da riceve un'e-mail di cunfirmazione fields: Pudete avè fin’à 4 elementi mustrati cum’un tavulone nant’à u vostru prufile header: Furmatu PNG, GIF o JPG. %{size} o menu. Sarà ridottu à %{dimensions}px @@ -18,9 +15,6 @@ co: irreversible: I statuti filtrati saranu sguassati di manera irreversibile, ancu s'ellu hè toltu u filtru locale: A lingua di l'interfaccia utilizatore, di l'e-mail è di e nutificazione push locked: Duvarete appruvà e dumande d’abbunamentu - note: - one: Ci ferma 1 caratteru - other: Ci fermanu %{count} caratteri password: Ci volenu almenu 8 caratteri phrase: Sarà trovu senza primura di e maiuscule o di l'avertimenti scopes: L'API à quelle l'applicazione averà accessu. S'è voi selezziunate un parametru d'altu livellu, un c'hè micca bisognu di selezziunà quell'individuali. diff --git a/config/locales/simple_form.cs.yml b/config/locales/simple_form.cs.yml index ed50e13ff..c2fd93ee1 100644 --- a/config/locales/simple_form.cs.yml +++ b/config/locales/simple_form.cs.yml @@ -8,9 +8,6 @@ cs: bot: Tento účet provádí hlavně automatizované akce a nemusí být spravován context: Jedno či více kontextů, ve kterých má být filtr uplatněn digest: Odesíláno pouze po dlouhé době nečinnosti a pouze, pokud jste při své nepřítomnosti obdržel/a osobní zprávy - display_name: - one: Zbývá 1 znak - other: Zbývá vám %{count} znaků email: Bude vám poslán potvrzovací e-mail fields: Na profilu můžete mít až 4 položky zobrazené jako tabulka header: PNG, GIF či JPG. Maximálně %{size}. Bude zmenšena na %{dimensions} px @@ -18,9 +15,6 @@ cs: irreversible: Filtrované tooty nenávratně zmizí, i pokud bude filtr později odstraněn locale: Jazyk uživatelského rozhraní, e-mailů a oznámení push locked: Vyžaduje manuální schvalování sledovatelů - note: - one: Zbývá 1znak - other: Zbývá %{count} znaků password: Použijte alespoň 8 znaků phrase: Shoda bude nalezena bez ohledu na velikost písmen v těle tootu či varování o obsahu scopes: Které API bude aplikace povolena používat. Pokud vyberete rozsah nejvyššího stupně, nebudete je muset vybírat po jednom. diff --git a/config/locales/simple_form.cy.yml b/config/locales/simple_form.cy.yml index 5a301f775..5653001b8 100644 --- a/config/locales/simple_form.cy.yml +++ b/config/locales/simple_form.cy.yml @@ -8,18 +8,12 @@ cy: bot: Mae'r cyfrif hwn yn perfformio gweithredoedd awtomataidd yn bennaf ac mae'n bosib nad yw'n cael ei fonitro context: Un neu fwy cyd-destun lle dylai'r hidlydd weithio digest: Dim ond yn cael eu hanfon ar ôl cyfnod hir o anweithgarwch ac ond os ydych wedi derbyn unrhyw negeseuon personol yn eich absenoldeb - display_name: - one: 1 nodyn ar ôl - other: %{count} nodyn ar ôl fields: Mae modd i chi arddangos hyd at 4 eitem fel tabl ar eich proffil header: PNG, GIF neu JPG. %{size} ar y mwyaf. Ceith ei israddio i %{dimensions}px inbox_url: Copïwch yr URL o dudalen flaen y relái yr ydych am ei ddefnyddio irreversible: Bydd tŵtiau wedi eu hidlo yn diflannu am byth, hyd yn oed os ceith yr hidlydd ei ddileu'n hwyrach locale: Iaith y rhyngwyneb, e-byst a hysbysiadau push locked: Ei wneud yn ofynnol arnoch chi i ganiatau dilynwyr a llaw - note: - one: 1 cymeriad ar ôl - other: %{count} o gymeriadau ar ôl scopes: Pa APIau y bydd gan y rhaglen ganiatad i gael mynediad iddynt. Os dewiswch maes lefel uchaf, yna nid oes angen dewis rhai unigol. setting_default_language: Mae modd adnabod iaith eich tŵtiau yn awtomatig, ond nid yw bob tro'n gywir setting_hide_network: Ni fydd pwy yr ydych yn ei ddilyn a phwy sy'n eich dilyn chi yn cael ei ddangos ar eich proffil diff --git a/config/locales/simple_form.da.yml b/config/locales/simple_form.da.yml index 7550122fc..64cdab07c 100644 --- a/config/locales/simple_form.da.yml +++ b/config/locales/simple_form.da.yml @@ -8,18 +8,12 @@ da: bot: Denne konto udfører hovedsageligt automatiserede handlinger og bliver muligvis ikke overvåget context: En eller flere sammenhænge hvor filteret skal være gældende digest: Sendes kun efter en lang periode med inaktivitet og kun hvis du har modtaget nogle personlige beskeder mens du er væk - display_name: - one: 1 tegn tilbage - other: %{count}tegn tilbage fields: Du kan have op til 4 ting vist som en tabel på din profil header: PNG, GIF eller JPG. Højest %{size}. Vil blive skaleret ned til %{dimensions}px inbox_url: Kopiere linket fra forsiden af den relay som du ønsker at bruge irreversible: Filtrerede trut vil forsvinde fulstændigt, selv hvis filteret senere skulle blive fjernet locale: Sproget på interfacet, emails og push beskeder locked: Kræver, at du godkender følgere manuelt - note: - one: 1 tegn tilbage - other: %{count} tegn tilbage phrase: Vil blive parret uanset om der er store eller små bogstaver i teksten eller om der er en advarsel om et trut scopes: Hvilke APIs applikationen vil få adgang til. Hvis du vælger et højtlevel omfang, behøver du ikke vælge enkeltstående. setting_default_language: Sproget for dine trut kan blive fundet automatisk, men det er ikke altid præcist diff --git a/config/locales/simple_form.de.yml b/config/locales/simple_form.de.yml index 340cd5ee7..9c2defd9e 100644 --- a/config/locales/simple_form.de.yml +++ b/config/locales/simple_form.de.yml @@ -8,9 +8,6 @@ de: bot: Dieses Konto führt lediglich automatisierte Aktionen durch und wird möglicherweise nicht überwacht context: Ein oder mehrere Aspekte, wo der Filter greifen soll digest: Wenn du lange Zeit inaktiv bist, wird dir eine Zusammenfassung von Erwähnungen in deiner Abwesenheit zugeschickt - display_name: - one: 1 Zeichen verbleibt - other: %{count} Zeichen verbleiben email: Du wirst ein Bestätigungs-E-Mail erhalten fields: Du kannst bis zu 4 Elemente als Tabelle dargestellt auf deinem Profil anzeigen lassen header: PNG, GIF oder JPG. Maximal %{size}. Wird auf %{dimensions} px herunterskaliert @@ -18,9 +15,6 @@ de: irreversible: Gefilterte Beiträge werden unwiderruflich gefiltert, selbst wenn der Filter später entfernt wurde locale: Die Sprache der Oberfläche, E-Mails und Push-Benachrichtigungen locked: Wer dir folgen möchte, muss um deine Erlaubnis bitten - note: - one: 1 Zeichen verbleibt - other: %{count} Zeichen verbleiben password: Verwende mindestens 8 Zeichen phrase: Wird unabhängig vom umgebenen Text oder Inhaltswarnung eines Beitrags verglichen scopes: Welche Schnittstellen der Applikation erlaubt sind. Wenn du einen Top-Level-Scope auswählst, dann musst du nicht jeden einzelnen darunter auswählen. diff --git a/config/locales/simple_form.el.yml b/config/locales/simple_form.el.yml index 823f25330..a13b44237 100644 --- a/config/locales/simple_form.el.yml +++ b/config/locales/simple_form.el.yml @@ -8,9 +8,6 @@ el: bot: Ο λογαριασμός αυτός εκτελεί κυρίως αυτοματοποιημένες ενέργειες και ίσως να μην παρακολουθείται context: Ένα ή περισσότερα πλαίσια στα οποία μπορεί να εφαρμόζεται αυτό το φίλτρο digest: Αποστέλλεται μόνο μετά από μακρά περίοδο αδράνειας και μόνο αν έχεις λάβει προσωπικά μηνύματα κατά την απουσία σου - display_name: - one: απομένει 1 χαρακτήρας - other: απομένουν %{count} χαρακτήρες email: Θα σου σταλεί email επιβεβαίωσης fields: Μπορείς να έχεις έως 4 σημειώσεις σε μορφή πίνακα στο προφίλ σου header: PNG, GIF ή JPG. Έως %{size}. Θα περιοριστεί σε διάσταση %{dimensions}px @@ -18,9 +15,6 @@ el: irreversible: Τα φιλτραρισμένα τουτ θα εξαφανιστούν αμετάκλητα, ακόμα και αν το φίλτρο αργότερα αφαιρεθεί locale: Η γλώσσα του περιβάλλοντος χρήσης, των email και των ειδοποιήσεων ώθησης locked: Απαιτεί να εγκρίνεις χειροκίνητα τους ακόλουθούς σου - note: - one: απομένει 1 χαρακτήρας - other: απομένουν %{count} χαρακτήρες password: Χρησιμοποίησε τουλάχιστον 8 χαρακτήρες phrase: Θα ταιριάζει ανεξαρτήτως πεζών/κεφαλαίων ή προειδοποίησης περιεχομένου του τουτ scopes: Ποια API θα επιτρέπεται στην εφαρμογή να χρησιμοποιήσεις. Αν επιλέξεις κάποιο υψηλό εύρος εφαρμογής, δε χρειάζεται να επιλέξεις και εξειδικευμένα. diff --git a/config/locales/simple_form.en.yml b/config/locales/simple_form.en.yml index e3d84dd07..d34ec79cc 100644 --- a/config/locales/simple_form.en.yml +++ b/config/locales/simple_form.en.yml @@ -8,9 +8,6 @@ en: bot: This account mainly performs automated actions and might not be monitored context: One or multiple contexts where the filter should apply digest: Only sent after a long period of inactivity and only if you have received any personal messages in your absence - display_name: - one: 1 character left - other: %{count} characters left email: You will be sent a confirmation e-mail fields: You can have up to 4 items displayed as a table on your profile header: PNG, GIF or JPG. At most %{size}. Will be downscaled to %{dimensions}px @@ -18,9 +15,6 @@ en: irreversible: Filtered toots will disappear irreversibly, even if filter is later removed locale: The language of the user interface, e-mails and push notifications locked: Requires you to manually approve followers - note: - one: 1 character left - other: %{count} characters left password: Use at least 8 characters phrase: Will be matched regardless of casing in text or content warning of a toot scopes: Which APIs the application will be allowed to access. If you select a top-level scope, you don't need to select individual ones. diff --git a/config/locales/simple_form.eo.yml b/config/locales/simple_form.eo.yml index 36f26035f..e8ddc075e 100644 --- a/config/locales/simple_form.eo.yml +++ b/config/locales/simple_form.eo.yml @@ -8,18 +8,12 @@ eo: bot: Tiu konto ĉefe faras aŭtomatajn agojn, kaj povas esti ne kontrolata context: Unu ol pluraj kuntekstoj kie la filtrilo devus agi digest: Sendita nur post longa tempo de neaktiveco, kaj nur se vi ricevis personan mesaĝon en via foresto - display_name: - one: 1 signo restas - other: %{count} signoj restas fields: Vi povas havi ĝis 4 tabelajn elementojn en via profilo header: Formato PNG, GIF aŭ JPG. Ĝis %{size}. Estos malgrandigita al %{dimensions}px inbox_url: Kopiu la URL de la ĉefpaĝo de la ripetilo, kiun vi volas uzi irreversible: Elfiltritaj mesaĝoj malaperos por ĉiam, eĉ se la filtrilo estas poste forigita locale: La lingvo de la uzant-interfaco, retmesaĝoj kaj puŝ-sciigoj locked: Vi devos aprobi ĉiun peton de sekvado mane - note: - one: 1 signo restas - other: %{count} signoj restas phrase: Estos provita senzorge pri la uskleco de teksto aŭ averto pri enhavo de mesaĝo setting_default_language: La lingvo de viaj mesaĝoj povas esti aŭtomate detektitaj, sed tio ne ĉiam ĝustas setting_hide_network: Tiuj, kiujn vi sekvas, kaj tiuj, kiuj sekvas vin ne estos videblaj en via profilo diff --git a/config/locales/simple_form.es.yml b/config/locales/simple_form.es.yml index 8c528144e..c0d72dc27 100644 --- a/config/locales/simple_form.es.yml +++ b/config/locales/simple_form.es.yml @@ -8,18 +8,12 @@ es: bot: Esta cuenta ejecuta principalmente acciones automatizadas y podría no ser monitorizada context: Uno o múltiples contextos en los que debe aplicarse el filtro digest: Solo enviado tras un largo periodo de inactividad y solo si has recibido mensajes personales durante tu ausencia - display_name: - one: 1 caracter restante - other: %{count} caracteres restantes fields: Puedes tener hasta 4 elementos mostrándose como una tabla en tu perfil header: PNG, GIF o JPG. Máximo %{size}. Será escalado a %{dimensions}px inbox_url: Copia la URL de la página principal del relés que quieres utilizar irreversible: Los toots filtrados desaparecerán irreversiblemente, incluso si este filtro es eliminado más adelante locale: El idioma de la interfaz de usuario, correos y notificaciones push locked: Requiere que manualmente apruebes seguidores y las publicaciones serán mostradas solamente a tus seguidores - note: - one: 1 carácter restante - other: %{count} caracteres restantes phrase: Se aplicará sin importar las mayúsculas o los avisos de contenido de un toot scopes: Qué APIs de la aplicación tendrán acceso. Si seleccionas el alcance de nivel mas alto, no necesitas seleccionar las individuales. setting_default_language: El idioma de tus toots podrá detectarse automáticamente, pero no siempre es preciso diff --git a/config/locales/simple_form.eu.yml b/config/locales/simple_form.eu.yml index 7fa8319ae..a658038b8 100644 --- a/config/locales/simple_form.eu.yml +++ b/config/locales/simple_form.eu.yml @@ -8,18 +8,12 @@ eu: bot: Kontu honek nagusiki automatizatutako ekintzak burutzen ditu eta agian ez du inork monitorizatzen context: Iragazkia aplikatzeko testuinguru bat edo batzuk digest: Soilik jarduerarik gabeko epe luze bat eta gero, eta soilik ez zeudela mezu pertsonalen bat jaso baduzu - display_name: - one: Karaktere 1 geratzen da - other: %{count} karaktere geratzen dira fields: 4 elementu bistaratu ditzakezu taula batean zure profilean header: PNG, GIF edo JPG. Gehienez %{size}. %{dimensions}px eskalara txikituko da inbox_url: Kopiatu erabili nahi duzun errelearen hasiera orriaren URLa irreversible: Iragazitako toot-ak betirako galduko dira, geroago iragazkia kentzen baduzu ere locale: Erabiltzaile-interfazea, e-mail mezuen eta jakinarazpenen hizkuntza locked: Jarraitzaileak eskuz onartu behar dituzu - note: - one: Karaktere1 geratzen da - other: %{count} karaktere geratzen dira phrase: Bat egingo du Maiuskula/minuskula kontuan hartu gabe eta edukiaren abisua kontuan hartu gabe scopes: Zeintzuk API atzitu ditzakeen aplikazioak. Goi mailako arloa aukeratzen baduzu, ez dituzu azpikoak aukeratu behar. setting_default_language: Zure toot-en hizkuntza automatikoki antzeman daiteke, baina ez da beti zehatza diff --git a/config/locales/simple_form.fa.yml b/config/locales/simple_form.fa.yml index 3e2398d55..198fb7067 100644 --- a/config/locales/simple_form.fa.yml +++ b/config/locales/simple_form.fa.yml @@ -8,9 +8,6 @@ fa: bot: این حساب بیشتر به طور خودکار فعالیت می‌کند و نظارت پیوسته‌ای روی آن وجود ندارد context: یک یا چند زمینه که فیلتر باید در آن‌ها اعمال شود digest: تنها وقتی فرستاده می‌شود که مدتی طولانی فعالیتی نداشته باشید و در این مدت برای شما پیغام خصوصی‌ای نوشته شده باشد - display_name: - one: 1 حرف باقی مانده - other: %{count} حرف باقی مانده email: به شما ایمیل تأییدی فرستاده خواهد شد fields: شما می‌توانید تا چهار مورد را در یک جدول در نمایهٔ خود نمایش دهید header: یکی از قالب‌های PNG یا GIF یا JPG. بیشترین اندازه %{size}. تصویر به اندازهٔ %{dimensions} پیکسل تبدیل خواهد شد @@ -18,9 +15,6 @@ fa: irreversible: بوق‌های فیلترشده به طور برگشت‌ناپذیری ناپدید می‌شوند، حتی اگر فیلتر را بعداً بردارید locale: زبان محیط کاربری، ایمیل‌ها، و اعلان‌ها locked: باید پیگیران تازه را خودتان تأیید کنید - note: - one: 1 حرف باقی مانده - other: %{count} حرف باقی مانده password: دست‌کم باید ۸ نویسه داشته باشد phrase: مستقل از کوچکی و بزرگی حروف، با متن اصلی یا هشدار محتوای بوق‌ها مقایسه می‌شود scopes: واسط‌های برنامه‌نویسی که این برنامه به آن دسترسی دارد. اگر بالاترین سطح دسترسی را انتخاب کنید، دیگر نیازی به انتخاب سطح‌های پایینی ندارید. diff --git a/config/locales/simple_form.fi.yml b/config/locales/simple_form.fi.yml index e78ba9cc7..b0f958f2f 100644 --- a/config/locales/simple_form.fi.yml +++ b/config/locales/simple_form.fi.yml @@ -5,15 +5,9 @@ fi: defaults: avatar: PNG, GIF tai JPG. Enintään %{size}. Skaalataan kokoon %{dimensions} px digest: Lähetetään vain pitkän poissaolon jälkeen ja vain, jos olet saanut suoria viestejä poissaolosi aikana - display_name: - one: 1 merkki jäljellä - other: %{count} merkkiä jäljellä fields: Sinulla voi olla korkeintaan 4 asiaa profiilissasi taulukossa header: PNG, GIF tai JPG. Enintään %{size}. Skaalataan kokoon %{dimensions} px locked: Sinun täytyy hyväksyä seuraajat manuaalisesti - note: - one: 1 merkki jäljellä - other: %{count} merkkiä jäljellä setting_noindex: Vaikuttaa julkiseen profiiliisi ja tilasivuihisi setting_theme: Vaikuttaa Mastodonin ulkoasuun millä tahansa laitteella kirjauduttaessa. imports: diff --git a/config/locales/simple_form.fr.yml b/config/locales/simple_form.fr.yml index 40ae0400f..c4d664877 100644 --- a/config/locales/simple_form.fr.yml +++ b/config/locales/simple_form.fr.yml @@ -8,9 +8,6 @@ fr: bot: Ce compte exécute principalement des actions automatisées et pourrait ne pas être surveillé context: Un ou plusieurs contextes où le filtre devrait s’appliquer digest: Uniquement envoyé après une longue période d’inactivité et uniquement si vous avez reçu des messages personnels pendant votre absence - display_name: - one: 1 caractère restant - other: %{count} caractères restants email: Vous recevrez un courriel de confirmation fields: Vous pouvez avoir jusqu’à 4 éléments affichés en tant que tableau sur votre profil header: Au format PNG, GIF ou JPG. %{size} maximum. Sera réduit à %{dimensions}px @@ -18,9 +15,6 @@ fr: irreversible: Les pouets filtrés disparaîtront irrémédiablement, même si le filtre est supprimé plus tard locale: La langue de l’interface, des courriels et des notifications locked: Vous devrez approuver chaque abonné⋅e et vos statuts ne s’afficheront qu’à vos abonné⋅es - note: - one: 1 caractère restant - other: %{count} caractères restants password: Utilisez au moins 8 caractères phrase: Sera trouvé sans que la case ou l’avertissement de contenu du pouet soit pris en compte scopes: À quelles APIs l’application sera autorisée à accéder. Si vous sélectionnez un périmètre de haut-niveau, vous n’avez pas besoin de sélectionner les individuels. diff --git a/config/locales/simple_form.gl.yml b/config/locales/simple_form.gl.yml index f81d34610..04a0fffa3 100644 --- a/config/locales/simple_form.gl.yml +++ b/config/locales/simple_form.gl.yml @@ -8,9 +8,6 @@ gl: bot: Esta conta realiza principalmente accións automatizadas e podería non estar monitorizada context: Un ou varios contextos onde se debería aplicar o filtro digest: Enviar só tras un longo período de inactividade e só si recibeu algunha mensaxe personal na súa ausencia - display_name: - one: 1 caracter restante - other: %{count} caracteres restantes email: Enviaráselle un correo-e de confirmación fields: Pode ter ate 4 elementos no seu perfil mostrados como unha táboa header: PNG, GIF ou JPG. Máximo %{size}. Será reducida a %{dimensions}px @@ -18,9 +15,6 @@ gl: irreversible: Os toots filtrados desaparecerán de xeito irreversible, incluso si despois se elimina o filtro locale: O idioma da interface de usuaria, correos e notificacións locked: Require que vostede acepte as seguidoras de xeito manual - note: - one: 1 caracter restante - other: %{count} caracteres restantes password: Utilice 8 caracteres ao menos phrase: Concordará independentemente das maiúsculas ou avisos de contido no toot scopes: A que APIs terá acceso a aplicación. Si selecciona un ámbito de alto nivel, non precisa seleccionar elementos individuais. diff --git a/config/locales/simple_form.he.yml b/config/locales/simple_form.he.yml index aa5c7e827..c86498c66 100644 --- a/config/locales/simple_form.he.yml +++ b/config/locales/simple_form.he.yml @@ -5,14 +5,8 @@ he: defaults: avatar: PNG, GIF או JPG. מקסימום %{size}. גודל התמונה יוקטן ל-%{dimensions}px digest: נשלח לאחר תקופה ארוכה של אי-פעילות עם סיכום איזכורים שקיבלת בהעדרך - display_name: - one: נותרה אותאחת - other: נותרו%{count} אותיות header: PNG, GIF או JPG. מקסימום %{size}. גודל התמונה יוקטן %{dimensions}px locked: מחייב אישור עוקבים באופן ידני. פרטיות ההודעות תהיה עוקבים-בלבד אלא אם יצוין אחרת - note: - one: נותרה אותאחת - other: נותרו %{count} אותיות setting_noindex: משפיע על הפרופיל הציבורי שלך ועמודי ההודעות setting_theme: משפיע על המראה של מסטודון בעת החיבור המזוהה מכל מכשיר שהוא. imports: diff --git a/config/locales/simple_form.hr.yml b/config/locales/simple_form.hr.yml index 2b3ebf91e..4b1d2b1e0 100644 --- a/config/locales/simple_form.hr.yml +++ b/config/locales/simple_form.hr.yml @@ -4,10 +4,8 @@ hr: hints: defaults: avatar: PNG, GIF ili JPG. Najviše %{size}. Bit će smanjen na %{dimensions}px - display_name: Najviše 30 znakova header: PNG, GIF ili JPG. Najviše %{size}. Bit će smanjen na %{dimensions}px locked: traži te da ručno odobriš sljedbenike i postavlja privatnost postova na dostupnu samo sljedbenicima - note: Najviše 160 znakova imports: data: CSV fajl izvezen iz druge Mastodon instance labels: diff --git a/config/locales/simple_form.hu.yml b/config/locales/simple_form.hu.yml index ef915dec5..f36fabda1 100644 --- a/config/locales/simple_form.hu.yml +++ b/config/locales/simple_form.hu.yml @@ -5,14 +5,8 @@ hu: defaults: avatar: PNG, GIF vagy JPG. Maximum %{size}. Át lesz méretezve %{dimensions} pixelre digest: Csak hosszú távollét esetén küldve és csak ha személyes üzenetet kaptál távollétedben - display_name: - one: 1karakter maradt - other: %{count}karakter maradt header: PNG, GIF vagy JPG. Maximum %{size}. Át lesz méretezve %{dimensions} pixelre locked: Egyenként engedélyezned kell a követőidet - note: - one: 1karakter maradt - other: %{count}karakter maradt setting_noindex: A publikus profilodra és státusz oldalra vonatkozik setting_theme: A bármely eszközről bejelentkezett felület kinézetére vonatkozik. imports: diff --git a/config/locales/simple_form.id.yml b/config/locales/simple_form.id.yml index fcd9d862c..c6da2beff 100644 --- a/config/locales/simple_form.id.yml +++ b/config/locales/simple_form.id.yml @@ -4,10 +4,8 @@ id: hints: defaults: avatar: PNG, GIF atau JPG. Maksimal %{size}. Ukuran dikecilkan menjadi %{dimensions}px - display_name: Maksimal 30 karakter header: PNG, GIF atau JPG. Maksimal %{size}. Ukuran dikecilkan menjadi %{dimensions}px locked: Anda harus menerima permintaan pengikut secara manual dan setting privasi postingan akan diubah khusus untuk pengikut - note: Maksimum 160 karakter imports: data: File CSV yang diexpor dari server Mastodon lain sessions: diff --git a/config/locales/simple_form.io.yml b/config/locales/simple_form.io.yml index c4fc702fe..c9fd9899e 100644 --- a/config/locales/simple_form.io.yml +++ b/config/locales/simple_form.io.yml @@ -4,10 +4,8 @@ io: hints: defaults: avatar: En la formato PNG, GIF o JPG. Til %{size}. Esos mikrigita a %{dimensions}px - display_name: 30 signi maxime header: En la formato PNG, GIF o JPG. Til %{size}. Esos mikrigita a %{dimensions}px locked: Tu devos aprobar omna demandi di sequado, e tua mesaji esos senchanje nur por tua sequanti. - note: 160 signi maxime imports: data: Dosiero CSV de altra instaluro di Mastodon sessions: diff --git a/config/locales/simple_form.it.yml b/config/locales/simple_form.it.yml index 841e65faa..4c6bb5acf 100644 --- a/config/locales/simple_form.it.yml +++ b/config/locales/simple_form.it.yml @@ -8,18 +8,12 @@ it: bot: Questo account esegue principalmente operazioni automatiche e potrebbe non essere tenuto sotto controllo da una persona context: Uno o più contesti nei quali il filtro dovrebbe essere applicato digest: Inviata solo dopo un lungo periodo di inattività e solo se hai ricevuto qualche messaggio personale in tua assenza - display_name: - one: 1 carattere rimanente - other: %{count} caratteri rimanenti fields: Puoi avere fino a 4 voci visualizzate come una tabella sul tuo profilo header: PNG, GIF o JPG. Al massimo %{size}. Verranno scalate a %{dimensions}px inbox_url: Copia la URL dalla pagina iniziale del ripetitore che vuoi usare irreversible: I toot filtrati scompariranno in modo irreversibile, anche se il filtro viene eliminato locale: La lingua dell'interfaccia utente, di email e notifiche push locked: Richiede che approvi i follower manualmente - note: - one: 1 carattere rimanente - other: %{count} caratteri rimanenti phrase: Il confronto sarà eseguito ignorando minuscole/maiuscole e i content warning scopes: A quali API l'applicazione potrà avere accesso. Se selezionate un ambito di alto livello, non c'è bisogno di selezionare quelle singole. setting_default_language: La lingua dei tuoi toot può essere individuata automaticamente, ma il risultato non è sempre accurato diff --git a/config/locales/simple_form.ja.yml b/config/locales/simple_form.ja.yml index 2ef459040..0ef55c980 100644 --- a/config/locales/simple_form.ja.yml +++ b/config/locales/simple_form.ja.yml @@ -8,7 +8,6 @@ ja: bot: このアカウントは主に自動で動作し、人が見ていない可能性があります context: フィルターを適用する対象 (複数選択可) digest: 長期間使用していない場合と不在時に返信を受けた場合のみ送信されます - display_name: あと%{count}文字入力できます。 email: 確認のメールが送信されます fields: プロフィールに表として4つまでの項目を表示することができます header: "%{size}までのPNG、GIF、JPGが利用可能です。 %{dimensions}pxまで縮小されます" @@ -16,7 +15,6 @@ ja: irreversible: フィルターが後で削除されても、除外されたトゥートは元に戻せなくなります locale: ユーザーインターフェース、メールやプッシュ通知の言語 locked: フォロワーを手動で承認する必要があります - note: あと%{count}文字入力できます。 password: 少なくとも8文字は入力してください phrase: トゥートの大文字小文字や閲覧注意に関係なく一致 scopes: アプリの API に許可するアクセス権を選択してください。最上位のスコープを選択する場合、個々のスコープを選択する必要はありません。 diff --git a/config/locales/simple_form.ka.yml b/config/locales/simple_form.ka.yml index b1b29a7ce..6bccb3134 100644 --- a/config/locales/simple_form.ka.yml +++ b/config/locales/simple_form.ka.yml @@ -8,18 +8,12 @@ ka: bot: ეს ანგარიში უმთავრესად ასრულებს ავტომატურ მოქმედებებს და შესაძლოა არ იყოს მონიტორინგის ქვეშ context: ერთ ან მრავალი კონტექსტი სადაც ფილტრი უნდა შესრულდეს digest: იგზავნება მხოლოდ ხანგრძლივი უაქტივობის პერიოდის შემდეგ და არყოფნისას თუ მიიღეთ ერთი წერილი მაინც - display_name: - one: დარჩა ერთი ნიშანი - other: დარჩა %{count} ნიშანი fields: პროფილზე ტაბულის სახით შესაძლოა საჩვენებლად გაგაჩნდეთ მაქს. 4 პუნქტი header: პნგ, გიფ ან ჯპგ. მაქს. %{size}. ზომა დაპატარავდება %{dimensions}პიქს.-ზე inbox_url: ურლ დააკოირეთ გამოყენებისთვის სასურველი რილეის წინა გვერდიდან irreversible: გაფილტრული ტუტები გაუქმდება აღუდგენლად, იმ შემთხვევაშიც კი თუ ფილტრი სამომავლოდ გაუქმდება locale: მომხმარებლის ინტერფეისის, ელ-ფოსტის წერილების და ფუშ შეტყობინებების ენა locked: საჭიროებს თქვენ მიერ მიმდევრების ხელით დადასტურებას - note: - one: დარჩა ერთი ნიშანი - other: დარჩა %{count} ნიშანი phrase: დამთხვევა მოხდება დიდი და პატარა ასოების ან კონტენტის გაფრთხილების გათვალისწინების გარეშე scopes: რომელი აპიებისადმი ექნება აპლიკაციას ცვდომა. თუ არიჩევთ უმთავრეს ფარგლებს, არ დაგჭირდებათ ინდივიდუალურების ამორჩევა. setting_default_language: თქვენი ტუტების ენა შეიძლება დადგინდეს ავტომატურად, მაგრამ ეს არაა ყოველთვის ზუსტი diff --git a/config/locales/simple_form.ko.yml b/config/locales/simple_form.ko.yml index 232844df8..4bf717c6d 100644 --- a/config/locales/simple_form.ko.yml +++ b/config/locales/simple_form.ko.yml @@ -8,18 +8,12 @@ ko: bot: 사람들에게 계정이 사람이 아님을 알립니다 context: 필터를 적용 할 한 개 이상의 컨텍스트 digest: 오랫동안 활동하지 않았을 때 받은 멘션들에 대한 요약 받기 - display_name: - one: 1 글자 남음 - other: %{count} 글자 남음 fields: 당신의 프로파일에 최대 4개까지 표 형식으로 나타낼 수 있습니다 header: PNG, GIF 혹은 JPG. 최대 %{size}. %{dimensions}px로 다운스케일 됨 inbox_url: 사용 할 릴레이 서버의 프론트페이지에서 URL을 복사합니다 irreversible: 필터링 된 툿은 나중에 필터가 사라지더라도 돌아오지 않게 됩니다 locale: 유저 인터페이스, 이메일, 푸시 알림 언어 locked: 수동으로 팔로워를 승인하고, 기본 툿 프라이버시 설정을 팔로워 전용으로 변경 - note: - one: 1 글자 남음 - other: %{count} 글자 남음 phrase: 툿 내용이나 CW 내용 안에서 대소문자 구분 없이 매칭 됩니다 scopes: 애플리케이션에 허용할 API들입니다. 최상위 스코프를 선택하면 개별적인 것은 선택하지 않아도 됩니다. setting_default_language: 작성한 툿의 언어는 자동으로 인식할 수 있지만, 언제나 정확한 건 아닙니다 diff --git a/config/locales/simple_form.nl.yml b/config/locales/simple_form.nl.yml index 32ad8d52c..516c1bddf 100644 --- a/config/locales/simple_form.nl.yml +++ b/config/locales/simple_form.nl.yml @@ -8,18 +8,12 @@ nl: bot: Dit is een geautomatiseerd account en wordt mogelijk niet gemonitord context: Een of meerdere locaties waar de filter actief moet zijn digest: Wordt alleen na een lange periode van inactiviteit verzonden en alleen wanneer je tijdens jouw afwezigheid persoonlijke berichten hebt ontvangen - display_name: - one: 1 teken over - other: %{count} tekens over fields: Je kan maximaal 4 items als een tabel op je profiel weergeven header: PNG, GIF of JPG. Maximaal %{size}. Wordt teruggeschaald naar %{dimensions}px inbox_url: Kopieer de URL van de voorpagina van de relayserver die je wil gebruiken irreversible: Gefilterde toots verdwijnen onomkeerbaar, zelfs als de filter later wordt verwijderd locale: De taal van de gebruikersomgeving, e-mails en pushmeldingen locked: Vereist dat je handmatig volgers moet accepteren - note: - one: 1 teken over - other: %{count} tekens over phrase: Komt overeen ongeacht hoofd-/kleine letters of tekstwaarschuwingen scopes: Tot welke API's heeft de toepassing toegang. Wanneer je een toestemming van het bovenste niveau kiest, hoef je geen individuele toestemmingen meer te kiezen. setting_default_language: De taal van jouw toots kan automatisch worden gedetecteerd, maar het is niet altijd accuraat diff --git a/config/locales/simple_form.no.yml b/config/locales/simple_form.no.yml index 98c6b82fe..fc339c3f2 100644 --- a/config/locales/simple_form.no.yml +++ b/config/locales/simple_form.no.yml @@ -5,14 +5,8 @@ defaults: avatar: PNG, GIF eller JPG. Maksimalt %{size}. Vil bli nedskalert til %{dimensions}px digest: Kun sendt etter en lang periode med inaktivitet og bare dersom du har mottatt noen personlige meldinger mens du var borte - display_name: - one: 1 tegn igjen - other: %{count} tegn igjen header: PNG, GIF eller JPG. Maksimalt %{size}. Vil bli nedskalert til %{dimensions}px locked: Krever at du manuelt godkjenner følgere - note: - one: 1 tegn igjen - other: %{count} tegn igjen setting_noindex: Påvirker din offentlige profil og statussider setting_theme: Påvirker hvordan Mastodon ser ut når du er logget inn fra uansett enhet. imports: diff --git a/config/locales/simple_form.oc.yml b/config/locales/simple_form.oc.yml index d46befdc1..11bf1dc8b 100644 --- a/config/locales/simple_form.oc.yml +++ b/config/locales/simple_form.oc.yml @@ -8,18 +8,12 @@ oc: bot: Avisar lo monde qu’aqueste compte es pas d’una persona context: Un o mai de contèxtes ont lo filtre deuriá s’aplicar digest: Solament enviat aprèp un long moment d’inactivitat e solament s’avètz recebut de messatges personals pendent vòstra abséncia - display_name: - one: Demòra encara 1 caractèr - other: Demòran encara %{count} caractèrs fields: Podètz far veire cap a 4 elements sus vòstre perfil header: PNG, GIF o JPG. Maximum %{size}. Serà retalhada en %{dimensions}px inbox_url: Copiatz l’URL de la pagina màger del relai que volètz utilizar irreversible: Los tuts filtrats desapareisseràn irreversiblament, encara que lo filtre siá suprimit mai tard locale: La lenga de l’interfàcia d’utilizacion, los messatges e las notificacions locked: Demanda qu’acceptetz manualament lo mond que vos sègon e botarà la visibilitat de vòstras publicacions coma accessiblas a vòstres seguidors solament - note: - one: Demòra encara 1 caractèr - other: Demòran encara %{count} caractèrs phrase: Serà pres en compte que siá en majuscula o minuscula o dins un avertiment de contengut sensible scopes: A quinas APIs poiràn accedir las aplicacions. Se seleccionatz un encastre de naut nivèl, fa pas mestièr de seleccionar los nivèls mai basses. setting_default_language: La lenga de vòstres tuts pòt èsser detectada automaticament, mas de còps es pas corrèctament determinada diff --git a/config/locales/simple_form.pl.yml b/config/locales/simple_form.pl.yml index 250e98c56..8febad488 100644 --- a/config/locales/simple_form.pl.yml +++ b/config/locales/simple_form.pl.yml @@ -8,22 +8,12 @@ pl: bot: To konto wykonuje głównie zautomatyzowane działania i może nie być monitorowane context: Jedno lub wiele miejsc, w których filtr zostanie zastosowany digest: Wysyłane tylko po długiej nieaktywności, jeżeli w tym czasie otrzymaleś jakąś wiadomość bezpośrednią - display_name: - few: Pozostały %{count} znaki. - many: Pozostało %{count} znaków - one: Pozostał 1 znak - other: Pozostało %{count} znaków fields: Możesz ustawić maksymalnie 4 niestandardowe pola wyświetlane jako tabela na Twoim profilu header: PNG, GIF lub JPG. Maksymalnie %{size}. Zostanie zmniejszony do %{dimensions}px inbox_url: Skopiuj adres ze strony głównej przekaźnika, którego chcesz użyć irreversible: Filtrowane wpisy znikną bezpowrotnie, nawet gdy filtr zostanie usunięty locale: Język interfejsu, wiadomości e-mail i powiadomieniach push locked: Musisz akceptować prośby o śledzenie - note: - few: Pozostały %{count} znaki. - many: Pozostało %{count} znaków - one: Pozostał 1 znak - other: Pozostało %{count} znaków phrase: Zostanie wykryte nawet, gdy znajduje się za ostrzeżeniem o zawartości scopes: Wybór API, do których aplikacja będzie miała dostęp. Jeżeli wybierzesz nadrzędny zakres, nie musisz wybierać jego elementów. setting_default_language: Język Twoich wpisów może być wykrywany automatycznie, ale nie zawsze jest to dokładne diff --git a/config/locales/simple_form.pt-BR.yml b/config/locales/simple_form.pt-BR.yml index 23272c41f..6fc5ca061 100644 --- a/config/locales/simple_form.pt-BR.yml +++ b/config/locales/simple_form.pt-BR.yml @@ -8,18 +8,12 @@ pt-BR: bot: Essa conta executa principalmente ações automatizadas e pode não ser monitorada context: Um ou mais contextos onde o filtro deve ser aplicado digest: Enviado após um longo período de inatividade com um resumo das menções que você recebeu em sua ausência - display_name: - one: 1 caracter restante - other: %{count} caracteres restantes fields: Você pode ter até 4 itens exibidos em forma de tabela no seu perfil header: PNG, GIF or JPG. Arquivos de até %{size}. Eles serão diminuídos para %{dimensions}px inbox_url: Copie a URL da página inicial do repetidor que você quer usar irreversible: Os toots filtrados vão desaparecer irreversivelmente, mesmo se o filtro for removido depois locale: O idioma das telas de usuário, e-mails e notificações push locked: Requer aprovação manual de seguidores - note: - one: 1 caracter restante - other: %{count} caracteres restantes phrase: Vai coincidir, independente de maiúsculas ou minúsculas, no texto ou no aviso de conteúdo de um toot scopes: Quais APIs a aplicação vai ter permissão de acessar. Se você selecionar um escopo de alto nível, você não precisa selecionar individualmente os outros. setting_default_language: O idioma de seus toots pode ser detectado automaticamente, mas isso nem sempre é preciso diff --git a/config/locales/simple_form.pt.yml b/config/locales/simple_form.pt.yml index 8c515c1de..88be3ac70 100644 --- a/config/locales/simple_form.pt.yml +++ b/config/locales/simple_form.pt.yml @@ -5,14 +5,8 @@ pt: defaults: avatar: PNG, GIF or JPG. Arquivos até %{size}. Vão ser reduzidos para %{dimensions}px digest: Enviado após um longo período de inatividade e apenas se foste mencionado na tua ausência - display_name: - one: 1 caracter restante - other: %{count} caracteres restantes header: PNG, GIF or JPG. Arquivos até %{size}. Vão ser reduzidos para %{dimensions}px locked: Requer aprovação manual de seguidores - note: - one: 1 caracter restante - other: %{count} caracteres restantes setting_noindex: Afecta o teu perfil público e as páginas das tuas publicações setting_theme: Afecta a aparência do Mastodon quando entras na tua conta em qualquer dispositivo. imports: diff --git a/config/locales/simple_form.ru.yml b/config/locales/simple_form.ru.yml index daeb7300a..44cd7ccd6 100644 --- a/config/locales/simple_form.ru.yml +++ b/config/locales/simple_form.ru.yml @@ -8,22 +8,12 @@ ru: bot: Этот аккаунт обычно выполяет автоматизированные действия и может не просматриваться владельцем context: Один или несколько контекстов, к которым должны быть применены фильтры digest: Отсылается лишь после длительной неактивности, если Вы в это время получали личные сообщения - display_name: - few: Осталось %{count} символа - many: Осталось %{count} символов - one: Остался 1 символ - other: Осталось %{count} символов fields: В профиле можно отобразить до 4 пунктов как таблицу header: PNG, GIF или JPG. Максимально %{size}. Будет уменьшено до %{dimensions}px inbox_url: Копировать URL с главной страницы ретранслятора, который Вы хотите использовать irreversible: Отфильтрованные статусы будут утеряны навсегда, даже если в будущем фильтр будет убран locale: Язык интерфейса, e-mail писем и push-уведомлений locked: Потребует от Вас ручного подтверждения подписчиков, изменит приватность постов по умолчанию на "только для подписчиков" - note: - few: Осталось %{count} символа - many: Осталось %{count} символов - one: Остался 1 символ - other: Осталось %{count} символов phrase: Будет сопоставлено независимо от присутствия в тексте или предупреждения о содержании статуса scopes: Какие API приложению будет позволено использовать. Если Вы выберите самый верхний, нижестоящие будут выбраны автоматически. setting_default_language: Язык Ваших статусов может быть определён автоматически, но не всегда правильно diff --git a/config/locales/simple_form.sk.yml b/config/locales/simple_form.sk.yml index 0fd8f66b6..3ff75c2f2 100644 --- a/config/locales/simple_form.sk.yml +++ b/config/locales/simple_form.sk.yml @@ -8,20 +8,12 @@ sk: bot: Tento účet vykonáva hlavne automatizované akcie, a je pravdepodobne nespravovaný context: Jedno, alebo viac kritérií, v ktorých má byť filtrovanie uplatnené digest: Odoslané iba v prípade dlhodobej neprítomnosti, a len ak si obdŕžal/a nejaké osobné správy kým si bol/a preč - display_name: - few: Ostávajú ti %{count} znaky - one: Ostáva ti 1 znak - other: Ostáva ti %{count} znakov fields: Môžeš mať 4 položky na svojom profile zobrazené vo forme tabuľky header: PNG, GIF alebo JPG. Maximálne %{size}. Bude zmenšený na %{dimensions}px inbox_url: Skopíruj adresu z hlavnej stránky mostíka, ktorý chceš používať irreversible: Vytriedené príspevky zmiznú nenávratne, aj keď triedenie neskôr zrušíš locale: Jazyk užívateľského rozhrania, emailových a nástenkových oboznámení locked: Vyžaduje manuálne schvalovať sledujúcich - note: - few: Ostávajú ti %{count} znaky - one: Ostáva ti 1 znak - other: Ostáva ti %{count} znakov phrase: Zhoda sa nájde nezávisle od toho, či je text napísaný, veľkými, alebo malými písmenami, či už v tele, alebo v hlavičke scopes: Ktoré API budú povolené aplikácii pre prístup. Ak vyberieš vrcholný stupeň, nemusíš už potom vyberať po jednom. setting_default_language: Jazyk tvojích príspevkov môže byť zistený automaticky, ale nieje to vždy presné diff --git a/config/locales/simple_form.sl.yml b/config/locales/simple_form.sl.yml index 0f86841d3..3c3a21480 100644 --- a/config/locales/simple_form.sl.yml +++ b/config/locales/simple_form.sl.yml @@ -6,9 +6,6 @@ sl: avatar: PNG, GIF ali JPG. Največ %{size}. Zmanjšana bo na %{dimensions}px bot: Opozarja ljudi, da račun ne predstavlja osebe digest: Pošlje se le po dolgem obdobju nedejavnosti in samo, če ste prejeli osebna sporočila v vaši odsotnosti - display_name: - one: 1 znak ostane - other: %{count} znakov ostane fields: Na svojem profilu lahko imate do 4 predmete prikazane kot tabelo. header: PNG, GIF ali JPG. Največ %{size}. Zmanjšana bo na %{dimensions}px imports: diff --git a/config/locales/simple_form.sr-Latn.yml b/config/locales/simple_form.sr-Latn.yml index 259ac0046..0ef85eaba 100644 --- a/config/locales/simple_form.sr-Latn.yml +++ b/config/locales/simple_form.sr-Latn.yml @@ -5,18 +5,8 @@ sr-Latn: defaults: avatar: PNG, GIF ili JPG. Najviše %{size}. Biće smanjena na %{dimensions}px digest: Poslato posle dužeg perioda neaktivnosti sa pregledom svih bitnih stvari koje ste dobili dok ste bili odsutni - display_name: - few: %{count} karaktera preostala - many: %{count} karaktera preostalo - one: 1 karakter preostao - other: %{count} karaktera preostalo header: PNG, GIF ili JPG. Najviše %{size}. Biće smanjena na %{dimensions}px locked: Zahteva da pojedinačno odobrite pratioce - note: - few: %{count} karaktera preostal - many: %{count} karaktera preostalo - one: 1 karakter preostao - other: %{count} karaktera preostalo setting_noindex: Utiče na Vaš javni profil i statusne strane setting_theme: Utiče kako će Mastodont izgledati kada ste prijavljeni sa bilo kog uređaja. imports: diff --git a/config/locales/simple_form.sr.yml b/config/locales/simple_form.sr.yml index 333685ed5..1af52a41c 100644 --- a/config/locales/simple_form.sr.yml +++ b/config/locales/simple_form.sr.yml @@ -8,22 +8,12 @@ sr: bot: Овај налог углавном врши аутоматизоване радње и можда се не надгледа context: Један или више контекста у којима треба да се примени филтер digest: Послато после дужег периода неактивности са прегледом свих битних ствари које сте добили док сте били одсутни - display_name: - few: %{count} карактера преостала - many: %{count} карактера преостало - one: 1 карактер преостао - other: %{count} карактера преостало fields: Можете имати до 4 ставке приказане као табела на вашем профилу header: PNG, GIF или JPG. Највише %{size}. Биће смањена на %{dimensions}px inbox_url: Копирајте URL са насловне стране релеја који желите користити irreversible: Филтриранe трубе ће нестати неповратно, чак и ако је филтер касније уклоњен locale: Језик корисничког интерфејса, е-поште и мобилних обавештења locked: Захтева да појединачно одобрите пратиоце - note: - few: %{count} карактера преостал - many: %{count} карактера преостало - one: 1 карактер преостао - other: %{count} карактера преостало phrase: Биће упарена без обзира на велико или мало слово у тексту или упозорења о садржају трубе scopes: Којим API-јима ће апликација дозволити приступ. Ако изаберете опсег највишег нивоа, не морате одабрати појединачне. setting_default_language: Језик ваших труба може бити аутоматски откривен, али није увек прецизан diff --git a/config/locales/simple_form.sv.yml b/config/locales/simple_form.sv.yml index 6f2e4b58f..8bc82c609 100644 --- a/config/locales/simple_form.sv.yml +++ b/config/locales/simple_form.sv.yml @@ -7,16 +7,10 @@ sv: avatar: Högst %{size}. Kommer att skalas ner till %{dimensions}px bot: Detta konto utför huvudsakligen automatiserade åtgärder och kanske inte övervakas digest: Skickas endast efter en lång period av inaktivitet och endast om du har fått några personliga meddelanden i din frånvaro - display_name: - one: 1 tecken kvar - other: %{count} tecken kvar fields: Du kan ha upp till 4 objekt visade som en tabell på din profil header: NG, GIF eller JPG. Högst %{size}. Kommer nedskalas till %{dimensions}px locale: Användargränssnittets språk, e-post och push aviseringar locked: Kräver att du manuellt godkänner följare - note: - one: 1 tecken kvar - other: %{count} tecken kvar setting_default_language: Språket av dina inlägg kan upptäckas automatiskt, men det är inte alltid rätt setting_hide_network: Vem du följer och vilka som följer dig kommer inte att visas på din profilsida setting_noindex: Påverkar din offentliga profil och statussidor diff --git a/config/locales/simple_form.th.yml b/config/locales/simple_form.th.yml index 29491de0b..a8611c2f7 100644 --- a/config/locales/simple_form.th.yml +++ b/config/locales/simple_form.th.yml @@ -4,14 +4,8 @@ th: hints: defaults: avatar: PNG, GIF or JPG. At most %{size}. Will be downscaled to %{dimensions}px - display_name: - one: 1 character left - other: %{count} characters left header: PNG, GIF or JPG. At most %{size}. Will be downscaled to %{dimensions}px locked: Requires you to manually approve followers and defaults post privacy to followers-only - note: - one: 1 character left - other: %{count} characters left imports: data: CSV file exported from another Mastodon instance sessions: diff --git a/config/locales/simple_form.tr.yml b/config/locales/simple_form.tr.yml index bd5c65d83..d0b50609b 100644 --- a/config/locales/simple_form.tr.yml +++ b/config/locales/simple_form.tr.yml @@ -4,10 +4,8 @@ tr: hints: defaults: avatar: En fazla %{size} olacak şekilde PNG, GIF veya JPG formatında yükleyiniz. %{dimensions}px büyüklüğüne indirgenecektir - display_name: %{count} karakter kaldı header: En fazla %{size} olacak şekilde PNG, GIF veya JPG formatında yükleyiniz. %{dimensions}px büyüklüğüne indirgenecektir. locked: Takipçilerinizi manuel olarak kabul etmenizi ve gönderilerinizi varsayılan olarak sadece takipçilerinizin göreceği şekilde paylaşmanızı sağlar. - note: %{count} karakter kaldı imports: data: Diğer Mastodon sunucusundan dışarı aktardığınız CSV dosyası sessions: diff --git a/config/locales/simple_form.uk.yml b/config/locales/simple_form.uk.yml index ba25f53e2..05d57509e 100644 --- a/config/locales/simple_form.uk.yml +++ b/config/locales/simple_form.uk.yml @@ -5,10 +5,8 @@ uk: defaults: avatar: PNG, GIF, або JPG. Максимум - %{size}. Буде зменшено до %{dimensions}px bot: Цей аккаунт в основному виконує автоматичні дії та може не відстежуватіся - display_name: 'Залишилося символів: %{count}' header: PNG, GIF, або JPG. Максимум - %{size}. Буде зменшено до %{dimensions}px locked: Буде вимагати від Вас самостійного підтверждення підписників, змінить приватність постів за замовчуванням на "тільки для підписників" - note: 'Осталось символов: %{count}' imports: data: Файл CSV, экспортированный с другого узла Mastodon sessions: diff --git a/config/locales/simple_form.zh-CN.yml b/config/locales/simple_form.zh-CN.yml index 60a2548d2..cfa6840a6 100644 --- a/config/locales/simple_form.zh-CN.yml +++ b/config/locales/simple_form.zh-CN.yml @@ -7,12 +7,10 @@ zh-CN: avatar: 文件大小限制 %{size},只支持 PNG、GIF 或 JPG 格式。图片分辨率将会压缩至 %{dimensions}px bot: 来自这个帐户的绝大多数操作都是自动进行的,并且可能无人监控 digest: 仅在你长时间未登录,且收到了私信时发送 - display_name: 还能输入 %{count} 个字符 fields: 这将会在个人资料页上以表格的形式展示,最多 4 个项目 header: 文件大小限制 %{size},只支持 PNG、GIF 或 JPG 格式。图片分辨率将会压缩至 %{dimensions}px locale: 用户界面、电子邮件和推送通知中使用的语言 locked: 你需要手动审核所有关注请求 - note: 还能输入 %{count} 个字符 setting_default_language: 嘟文语言自动检测的结果有可能不准确(此设置仅影响你的嘟文) setting_hide_network: 你关注的人和关注你的人将不会在你的个人资料页上展示 setting_noindex: 此设置会影响到你的公开个人资料以及嘟文页面 diff --git a/config/locales/simple_form.zh-HK.yml b/config/locales/simple_form.zh-HK.yml index 447b9ce7a..e28f935c2 100644 --- a/config/locales/simple_form.zh-HK.yml +++ b/config/locales/simple_form.zh-HK.yml @@ -7,16 +7,10 @@ zh-HK: avatar: 支援 PNG, GIF 或 JPG 圖片,檔案最大為 %{size},會縮裁成 %{dimensions}px bot: 提醒用戶本帳號是機械人 digest: 僅在你長時間未登錄,且收到了私信時發送 - display_name: - one: 尚餘 1 個字 - other: 尚餘 %{count} 個字 fields: 個人資料頁可顯示多至 4 個項目 header: 支援 PNG, GIF 或 JPG 圖片,檔案最大為 %{size},會縮裁成 %{dimensions}px locale: 使用者介面、電郵和通知的語言 locked: 你必須人手核准每個用戶對你的關注請求,而你的文章私隱會被預設為「只有關注你的人能看」 - note: - one: 尚餘 1 個字 - other: 尚餘 %{count} 個字 setting_default_language: 你文章的語言會被自動偵測,但不一定完全準確 setting_hide_network: 你關注的人和關注你的人將不會在你的個人資料頁上顯示 setting_noindex: 此設定會影響到你的公開個人資料以及文章頁面 diff --git a/config/locales/simple_form.zh-TW.yml b/config/locales/simple_form.zh-TW.yml index 7eae7e190..3747fbb98 100644 --- a/config/locales/simple_form.zh-TW.yml +++ b/config/locales/simple_form.zh-TW.yml @@ -8,18 +8,12 @@ zh-TW: bot: 這個帳號由程式進行自動式操作 context: 應該套用過濾器的一項或多項內容 digest: 僅在你長時間未登入,並且收到了私訊時發送 - display_name: - one: 尚餘 1 個字 - other: 尚餘 %{count} 個字 fields: 個人資訊頁至多可顯示 4 個項目 header: 支援 PNG, GIF 或 JPG 圖片,檔案最大為 %{size},會縮裁成 %{dimensions}px inbox_url: 從您想要使用的中繼首頁複製 URL irreversible: 已過濾的嘟文將會不可逆的消失,即便過濾器之後也一樣 locale: 使用者介面、 E-mail 與通知的語言 locked: 你必須手動核准每個使用者對你的關注請求,而你的貼文隱私將會被設定為「只有關注你的人能看」 - note: - one: 尚餘 1 個字 - other: 尚餘 %{count} 個字 phrase: 無論是嘟文的本文或是內容警告都會被過濾 scopes: 應用程式將會被允許存取哪些 API。若您選取了最高階的範圍,您就不需要再選取單獨的了。 setting_default_language: 你嘟文的語言會被自動偵測,但不一定完全準確 From 1e2695198a28e0bc15b32192f8e6abb0051f2159 Mon Sep 17 00:00:00 2001 From: abcang Date: Fri, 26 Oct 2018 10:31:23 +0900 Subject: [PATCH 23/36] Skip link-back check if body is nil (#9107) --- app/services/verify_link_service.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/services/verify_link_service.rb b/app/services/verify_link_service.rb index 3453b54c5..9f56249c7 100644 --- a/app/services/verify_link_service.rb +++ b/app/services/verify_link_service.rb @@ -25,7 +25,7 @@ class VerifyLinkService < BaseService end def link_back_present? - return false if @body.empty? + return false if @body.blank? links = Nokogiri::HTML(@body).xpath('//a[contains(concat(" ", normalize-space(@rel), " "), " me ")]|//link[contains(concat(" ", normalize-space(@rel), " "), " me ")]') From 82e7988afcde5b19b99ad9ecf7973560a8a17f7f Mon Sep 17 00:00:00 2001 From: ThibG Date: Fri, 26 Oct 2018 12:59:59 +0200 Subject: [PATCH 24/36] Fix missing `mention` argument when processing incoming Create activities (#9114) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Fix missing `mention` argument when processing incoming Create activities * Fix typo (param → params) --- app/lib/activitypub/activity/create.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/lib/activitypub/activity/create.rb b/app/lib/activitypub/activity/create.rb index 92cdf4578..ea9017b82 100644 --- a/app/lib/activitypub/activity/create.rb +++ b/app/lib/activitypub/activity/create.rb @@ -90,11 +90,11 @@ class ActivityPub::Activity::Create < ActivityPub::Activity # If the payload was delivered to a specific inbox, the inbox owner must have # access to it, unless they already have access to it anyway - return if @options[:delivered_to_account_id].nil? || @mentions.any? { mention.account_id == @options[:delivered_to_account_id] } + return if @options[:delivered_to_account_id].nil? || @mentions.any? { |mention| mention.account_id == @options[:delivered_to_account_id] } @mentions << Mention.new(account_id: @options[:delivered_to_account_id], silent: true) - return unless @param[:visibility] == :direct + return unless @params[:visibility] == :direct @params[:visibility] = :limited end From e53cc673e717e913e2538a560d02d31c7c02496a Mon Sep 17 00:00:00 2001 From: ThibG Date: Fri, 26 Oct 2018 22:48:35 +0200 Subject: [PATCH 25/36] Ignore invalid hashtags on remote statuses instead of rejecting them (#9118) Fixes #9115 --- app/lib/activitypub/activity/create.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/lib/activitypub/activity/create.rb b/app/lib/activitypub/activity/create.rb index ea9017b82..f1b38b18a 100644 --- a/app/lib/activitypub/activity/create.rb +++ b/app/lib/activitypub/activity/create.rb @@ -129,7 +129,7 @@ class ActivityPub::Activity::Create < ActivityPub::Activity return if tag['name'].blank? hashtag = tag['name'].gsub(/\A#/, '').mb_chars.downcase - hashtag = Tag.where(name: hashtag).first_or_create(name: hashtag) + hashtag = Tag.where(name: hashtag).first_or_create!(name: hashtag) return if @tags.include?(hashtag) From 215e6493911e92e385a51b7a2a88d472b1592d32 Mon Sep 17 00:00:00 2001 From: ThibG Date: Fri, 26 Oct 2018 22:49:17 +0200 Subject: [PATCH 26/36] Fix styling in /auth/edit (#9117) --- app/controllers/auth/registrations_controller.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/controllers/auth/registrations_controller.rb b/app/controllers/auth/registrations_controller.rb index a19f4e62e..088832be3 100644 --- a/app/controllers/auth/registrations_controller.rb +++ b/app/controllers/auth/registrations_controller.rb @@ -8,7 +8,7 @@ class Auth::RegistrationsController < Devise::RegistrationsController before_action :configure_sign_up_params, only: [:create] before_action :set_sessions, only: [:edit, :update] before_action :set_instance_presenter, only: [:new, :create, :update] - before_action :set_body_classes, only: [:new, :create] + before_action :set_body_classes, only: [:new, :create, :edit, :update] def destroy not_found @@ -81,7 +81,7 @@ class Auth::RegistrationsController < Devise::RegistrationsController end def set_body_classes - @body_classes = 'lighter' + @body_classes = %w(edit update).include?(action_name) ? 'admin' : 'lighter' end def set_invite From 6e1a4f85ad96b25087d98fed1e70044c0f45a132 Mon Sep 17 00:00:00 2001 From: Masoud Abkenar Date: Fri, 26 Oct 2018 22:49:39 +0200 Subject: [PATCH 27/36] RTL: fix column-back-button__icon margins/content (#9112) * RTL: fix column-back-button__icon margins/content * Update rtl.scss * Update rtl.scss --- app/javascript/styles/mastodon/rtl.scss | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/app/javascript/styles/mastodon/rtl.scss b/app/javascript/styles/mastodon/rtl.scss index ccb53a090..176fb5ce0 100644 --- a/app/javascript/styles/mastodon/rtl.scss +++ b/app/javascript/styles/mastodon/rtl.scss @@ -352,4 +352,22 @@ body.rtl { margin-right: 15px; text-align: right; } + + .fa-chevron-left::before { + content: "\F054"; + } + + .fa-chevron-right::before { + content: "\F053"; + } + + .column-back-button__icon { + margin-right: 0; + margin-left: 5px; + } + + .column-header__setting-arrows .column-header__setting-btn:last-child { + padding-left: 0; + padding-right: 10px; + } } From eef8d9a5f7d07bf785c6a7184e01374e211c6d7f Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Fri, 26 Oct 2018 23:08:34 +0200 Subject: [PATCH 28/36] Add locality check to ActivityPub::FetchRemoteAccountService (#9109) * Add locality check to ActivityPub::FetchRemoteAccountService Fix #8643 Because there are a few places where it is called, it is difficult to confirm if they all previously checked it for locality. It's better to make sure within the service. * Remove faux-remote duplicates of local accounts --- .../activitypub/fetch_remote_account_service.rb | 3 ++- ...4033_remove_faux_remote_account_duplicates.rb | 16 ++++++++++++++++ db/schema.rb | 2 +- 3 files changed, 19 insertions(+), 2 deletions(-) create mode 100644 db/migrate/20181026034033_remove_faux_remote_account_duplicates.rb diff --git a/app/services/activitypub/fetch_remote_account_service.rb b/app/services/activitypub/fetch_remote_account_service.rb index 1ec9ee5dd..8430d12d5 100644 --- a/app/services/activitypub/fetch_remote_account_service.rb +++ b/app/services/activitypub/fetch_remote_account_service.rb @@ -5,9 +5,10 @@ class ActivityPub::FetchRemoteAccountService < BaseService SUPPORTED_TYPES = %w(Application Group Organization Person Service).freeze - # Should be called when uri has already been checked for locality # Does a WebFinger roundtrip on each call def call(uri, id: true, prefetched_body: nil, break_on_redirect: false) + return ActivityPub::TagManager.instance.uri_to_resource(uri, Account) if ActivityPub::TagManager.instance.local_uri?(uri) + @json = if prefetched_body.nil? fetch_resource(uri, id) else diff --git a/db/migrate/20181026034033_remove_faux_remote_account_duplicates.rb b/db/migrate/20181026034033_remove_faux_remote_account_duplicates.rb new file mode 100644 index 000000000..bd4f4c2a3 --- /dev/null +++ b/db/migrate/20181026034033_remove_faux_remote_account_duplicates.rb @@ -0,0 +1,16 @@ +class RemoveFauxRemoteAccountDuplicates < ActiveRecord::Migration[5.2] + disable_ddl_transaction! + + def up + local_domain = Rails.configuration.x.local_domain + + # Just a safety measure to ensure that under no circumstance + # we will query `domain IS NULL` because that would return + # actually local accounts, the originals + return if local_domain.nil? + + Account.where(domain: local_domain).in_batches.destroy_all + end + + def down; end +end diff --git a/db/schema.rb b/db/schema.rb index 3c4f41648..731a84521 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -10,7 +10,7 @@ # # It's strongly recommended that you check this file into your version control system. -ActiveRecord::Schema.define(version: 2018_10_24_224956) do +ActiveRecord::Schema.define(version: 2018_10_26_034033) do # These are extensions that must be enabled in order to support this database enable_extension "plpgsql" From 008f98b30481dff2278d0687deb874f05de66b75 Mon Sep 17 00:00:00 2001 From: Thibaut Girka Date: Sat, 27 Oct 2018 18:55:11 +0200 Subject: [PATCH 29/36] [Glitch] RTL: fix column-back-button__icon margins/content Port 6e1a4f85ad96b25087d98fed1e70044c0f45a132 to glitch-soc --- app/javascript/flavours/glitch/styles/rtl.scss | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/app/javascript/flavours/glitch/styles/rtl.scss b/app/javascript/flavours/glitch/styles/rtl.scss index 3c775618e..d4618440d 100644 --- a/app/javascript/flavours/glitch/styles/rtl.scss +++ b/app/javascript/flavours/glitch/styles/rtl.scss @@ -363,4 +363,22 @@ body.rtl { margin-right: 15px; text-align: right; } + + .fa-chevron-left::before { + content: "\F054"; + } + + .fa-chevron-right::before { + content: "\F053"; + } + + .column-back-button__icon { + margin-right: 0; + margin-left: 5px; + } + + .column-header__setting-arrows .column-header__setting-btn:last-child { + padding-left: 0; + padding-right: 10px; + } } From a90b569350853b648610814a06f1e9c8a930e16a Mon Sep 17 00:00:00 2001 From: ThibG Date: Sat, 27 Oct 2018 22:32:54 +0200 Subject: [PATCH 30/36] When searching for an emoji with multiple separators, consider the full input (#9124) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit e.g., typing “blob_cat_p” used to search for “blob” and “cat”, but not “blob_cat_p”, which means “blob_cat_patpat” is very unlikely to show up, although it is likely what the user wanted to type in the first place. --- .../features/emoji/emoji_mart_search_light.js | 22 +++++++++++++------ 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/app/javascript/mastodon/features/emoji/emoji_mart_search_light.js b/app/javascript/mastodon/features/emoji/emoji_mart_search_light.js index 36351ec02..164fdcc0b 100644 --- a/app/javascript/mastodon/features/emoji/emoji_mart_search_light.js +++ b/app/javascript/mastodon/features/emoji/emoji_mart_search_light.js @@ -2,7 +2,7 @@ // https://github.com/missive/emoji-mart/blob/5f2ffcc/src/utils/emoji-index.js import data from './emoji_mart_data_light'; -import { getData, getSanitizedData, intersect } from './emoji_utils'; +import { getData, getSanitizedData, uniq, intersect } from './emoji_utils'; let originalPool = {}; let index = {}; @@ -103,7 +103,7 @@ function search(value, { emojisToShowFilter, maxResults, include, exclude, custo } } - allResults = values.map((value) => { + const searchValue = (value) => { let aPool = pool, aIndex = index, length = 0; @@ -150,15 +150,23 @@ function search(value, { emojisToShowFilter, maxResults, include, exclude, custo } return aIndex.results; - }).filter(a => a); + }; - if (allResults.length > 1) { - results = intersect.apply(null, allResults); - } else if (allResults.length) { - results = allResults[0]; + if (values.length > 1) { + results = searchValue(value); } else { results = []; } + + allResults = values.map(searchValue).filter(a => a); + + if (allResults.length > 1) { + allResults = intersect.apply(null, allResults); + } else if (allResults.length) { + allResults = allResults[0]; + } + + results = uniq(results.concat(allResults)); } if (results) { From 6f78500d4f515c65ec66416e2d78bc9ae247f91c Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Sat, 27 Oct 2018 22:56:16 +0200 Subject: [PATCH 31/36] Do not remove "dead" domains in tootctl accounts cull (#9108) Leave `tootctl accounts cull` to simply check removed accounts from live domains, and skip temporarily unavailable domains, while listing them in the final output for further action. Add `tootctl domains purge DOMAIN` to be able to purge a domain from that list manually --- lib/cli.rb | 4 ++++ lib/mastodon/accounts_cli.rb | 45 +++++++++++------------------------- lib/mastodon/domains_cli.rb | 40 ++++++++++++++++++++++++++++++++ lib/mastodon/emoji_cli.rb | 1 + lib/mastodon/feeds_cli.rb | 3 ++- lib/mastodon/media_cli.rb | 1 + lib/mastodon/settings_cli.rb | 1 + 7 files changed, 62 insertions(+), 33 deletions(-) create mode 100644 lib/mastodon/domains_cli.rb diff --git a/lib/cli.rb b/lib/cli.rb index bff6d5809..a810c632a 100644 --- a/lib/cli.rb +++ b/lib/cli.rb @@ -6,6 +6,7 @@ require_relative 'mastodon/emoji_cli' require_relative 'mastodon/accounts_cli' require_relative 'mastodon/feeds_cli' require_relative 'mastodon/settings_cli' +require_relative 'mastodon/domains_cli' module Mastodon class CLI < Thor @@ -27,5 +28,8 @@ module Mastodon desc 'settings SUBCOMMAND ...ARGS', 'Manage dynamic settings' subcommand 'settings', Mastodon::SettingsCLI + + desc 'domains SUBCOMMAND ...ARGS', 'Manage account domains' + subcommand 'domains', Mastodon::DomainsCLI end end diff --git a/lib/mastodon/accounts_cli.rb b/lib/mastodon/accounts_cli.rb index 055333080..142436c19 100644 --- a/lib/mastodon/accounts_cli.rb +++ b/lib/mastodon/accounts_cli.rb @@ -1,6 +1,6 @@ # frozen_string_literal: true -require 'rubygems/package' +require 'set' require_relative '../../config/boot' require_relative '../../config/environment' require_relative 'cli_helper' @@ -10,6 +10,7 @@ module Mastodon def self.exit_on_failure? true end + option :all, type: :boolean desc 'rotate [USERNAME]', 'Generate and broadcast new keys' long_desc <<-LONG_DESC @@ -210,33 +211,25 @@ module Mastodon Accounts that have had confirmed activity within the last week are excluded from the checks. - If 10 or more accounts from the same domain cannot be queried - due to a connection error (such as missing DNS records) then - the domain is considered dead, and all other accounts from it - are deleted without further querying. + Domains that are unreachable are not checked. With the --dry-run option, no deletes will actually be carried out. LONG_DESC def cull - domain_thresholds = Hash.new { |hash, key| hash[key] = 0 } - skip_threshold = 7.days.ago - culled = 0 - dead_servers = [] - dry_run = options[:dry_run] ? ' (DRY RUN)' : '' + skip_threshold = 7.days.ago + culled = 0 + skip_domains = Set.new + dry_run = options[:dry_run] ? ' (DRY RUN)' : '' Account.remote.where(protocol: :activitypub).partitioned.find_each do |account| next if account.updated_at >= skip_threshold || (account.last_webfingered_at.present? && account.last_webfingered_at >= skip_threshold) - unless dead_servers.include?(account.domain) + unless skip_domains.include?(account.domain) begin code = Request.new(:head, account.uri).perform(&:code) rescue HTTP::ConnectionError - domain_thresholds[account.domain] += 1 - - if domain_thresholds[account.domain] >= 10 - dead_servers << account.domain - end + skip_domains << account.domain rescue StandardError next end @@ -255,24 +248,12 @@ module Mastodon end end - # Remove dead servers - unless dead_servers.empty? || options[:dry_run] - dead_servers.each do |domain| - Account.where(domain: domain).find_each do |account| - SuspendAccountService.new.call(account) - account.destroy - culled += 1 - say('.', :green, false) - end - end - end - say - say("Removed #{culled} accounts (#{dead_servers.size} dead servers)#{dry_run}", :green) + say("Removed #{culled} accounts. #{skip_domains.size} servers skipped#{dry_run}", skip_domains.empty? ? :green : :yellow) - unless dead_servers.empty? - say('R.I.P.:', :yellow) - dead_servers.each { |domain| say(' ' + domain) } + unless skip_domains.empty? + say('The following servers were not available during the check:', :yellow) + skip_domains.each { |domain| say(' ' + domain) } end end diff --git a/lib/mastodon/domains_cli.rb b/lib/mastodon/domains_cli.rb new file mode 100644 index 000000000..a7a5caa11 --- /dev/null +++ b/lib/mastodon/domains_cli.rb @@ -0,0 +1,40 @@ +# frozen_string_literal: true + +require_relative '../../config/boot' +require_relative '../../config/environment' +require_relative 'cli_helper' + +module Mastodon + class DomainsCLI < Thor + def self.exit_on_failure? + true + end + + option :dry_run, type: :boolean + desc 'purge DOMAIN', 'Remove accounts from a DOMAIN without a trace' + long_desc <<-LONG_DESC + Remove all accounts from a given DOMAIN without leaving behind any + records. Unlike a suspension, if the DOMAIN still exists in the wild, + it means the accounts could return if they are resolved again. + LONG_DESC + def purge(domain) + removed = 0 + dry_run = options[:dry_run] ? ' (DRY RUN)' : '' + + Account.where(domain: domain).find_each do |account| + unless options[:dry_run] + SuspendAccountService.new.call(account) + account.destroy + end + + removed += 1 + say('.', :green, false) + end + + DomainBlock.where(domain: domain).destroy_all + + say + say("Removed #{removed} accounts#{dry_run}", :green) + end + end +end diff --git a/lib/mastodon/emoji_cli.rb b/lib/mastodon/emoji_cli.rb index 1987c6394..2262040d4 100644 --- a/lib/mastodon/emoji_cli.rb +++ b/lib/mastodon/emoji_cli.rb @@ -10,6 +10,7 @@ module Mastodon def self.exit_on_failure? true end + option :prefix option :suffix option :overwrite, type: :boolean diff --git a/lib/mastodon/feeds_cli.rb b/lib/mastodon/feeds_cli.rb index 817ed4e79..fe11c3df4 100644 --- a/lib/mastodon/feeds_cli.rb +++ b/lib/mastodon/feeds_cli.rb @@ -9,6 +9,7 @@ module Mastodon def self.exit_on_failure? true end + option :all, type: :boolean, default: false option :background, type: :boolean, default: false option :dry_run, type: :boolean, default: false @@ -58,7 +59,7 @@ module Mastodon account = Account.find_local(username) if account.nil? - say("Account #{username} is not found", :red) + say('No such account', :red) exit(1) end diff --git a/lib/mastodon/media_cli.rb b/lib/mastodon/media_cli.rb index 95d2a8d64..179d1b6b5 100644 --- a/lib/mastodon/media_cli.rb +++ b/lib/mastodon/media_cli.rb @@ -9,6 +9,7 @@ module Mastodon def self.exit_on_failure? true end + option :days, type: :numeric, default: 7 option :background, type: :boolean, default: false option :verbose, type: :boolean, default: false diff --git a/lib/mastodon/settings_cli.rb b/lib/mastodon/settings_cli.rb index 69485600a..c81cfbe52 100644 --- a/lib/mastodon/settings_cli.rb +++ b/lib/mastodon/settings_cli.rb @@ -9,6 +9,7 @@ module Mastodon def self.exit_on_failure? true end + desc 'open', 'Open registrations' def open Setting.open_registrations = true From 795f0107d23c1c9bd039f6449fa1e094ab7653a7 Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Sun, 28 Oct 2018 06:35:03 +0100 Subject: [PATCH 32/36] Include preview cards in status entity in REST API (#9120) * Include preview cards in status entity in REST API * Display preview card in-stream * Improve in-stream display of preview cards --- app/controllers/application_controller.rb | 1 + app/javascript/mastodon/components/status.js | 9 ++++++ .../features/status/components/card.js | 18 ++++++------ .../status/containers/card_container.js | 2 +- app/javascript/mastodon/reducers/index.js | 2 -- app/javascript/mastodon/reducers/statuses.js | 3 ++ .../styles/mastodon/components.scss | 28 +++++++++++++++++++ app/models/status.rb | 6 ++++ app/serializers/rest/status_serializer.rb | 2 ++ app/services/fetch_link_card_service.rb | 1 + 10 files changed, 61 insertions(+), 11 deletions(-) diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb index fb4283da3..7bb14aa4c 100644 --- a/app/controllers/application_controller.rb +++ b/app/controllers/application_controller.rb @@ -126,6 +126,7 @@ class ApplicationController < ActionController::Base def respond_with_error(code) respond_to do |format| format.any { head code } + format.html do set_locale render "errors/#{code}", layout: 'error', status: code diff --git a/app/javascript/mastodon/components/status.js b/app/javascript/mastodon/components/status.js index 0b23e51f8..9fa8cc008 100644 --- a/app/javascript/mastodon/components/status.js +++ b/app/javascript/mastodon/components/status.js @@ -9,6 +9,7 @@ import DisplayName from './display_name'; import StatusContent from './status_content'; import StatusActionBar from './status_action_bar'; import AttachmentList from './attachment_list'; +import Card from '../features/status/components/card'; import { injectIntl, FormattedMessage } from 'react-intl'; import ImmutablePureComponent from 'react-immutable-pure-component'; import { MediaGallery, Video } from '../features/ui/util/async-components'; @@ -256,6 +257,14 @@ class Status extends ImmutablePureComponent { ); } + } else if (status.get('spoiler_text').length === 0 && status.get('card')) { + media = ( + + ); } if (otherAccounts) { diff --git a/app/javascript/mastodon/features/status/components/card.js b/app/javascript/mastodon/features/status/components/card.js index b52f3c4fa..9a87f7a3f 100644 --- a/app/javascript/mastodon/features/status/components/card.js +++ b/app/javascript/mastodon/features/status/components/card.js @@ -59,10 +59,12 @@ export default class Card extends React.PureComponent { card: ImmutablePropTypes.map, maxDescription: PropTypes.number, onOpenMedia: PropTypes.func.isRequired, + compact: PropTypes.boolean, }; static defaultProps = { maxDescription: 50, + compact: false, }; state = { @@ -131,25 +133,25 @@ export default class Card extends React.PureComponent { } render () { - const { card, maxDescription } = this.props; - const { width, embedded } = this.state; + const { card, maxDescription, compact } = this.props; + const { width, embedded } = this.state; if (card === null) { return null; } const provider = card.get('provider_name').length === 0 ? decodeIDNA(getHostname(card.get('url'))) : card.get('provider_name'); - const horizontal = card.get('width') > card.get('height') && (card.get('width') + 100 >= width) || card.get('type') !== 'link'; - const className = classnames('status-card', { horizontal }); + const horizontal = (!compact && card.get('width') > card.get('height') && (card.get('width') + 100 >= width)) || card.get('type') !== 'link' || embedded; const interactive = card.get('type') !== 'link'; + const className = classnames('status-card', { horizontal, compact, interactive }); const title = interactive ? {card.get('title')} : {card.get('title')}; - const ratio = card.get('width') / card.get('height'); + const ratio = compact ? 16 / 9 : card.get('width') / card.get('height'); const height = card.get('width') > card.get('height') ? (width / ratio) : (width * ratio); const description = (
{title} - {!horizontal &&

{trim(card.get('description') || '', maxDescription)}

} + {!(horizontal || compact) &&

{trim(card.get('description') || '', maxDescription)}

} {provider}
); @@ -174,7 +176,7 @@ export default class Card extends React.PureComponent {
- + {horizontal && }
@@ -184,7 +186,7 @@ export default class Card extends React.PureComponent { return (
{embed} - {description} + {!compact && description}
); } else if (card.get('image')) { diff --git a/app/javascript/mastodon/features/status/containers/card_container.js b/app/javascript/mastodon/features/status/containers/card_container.js index a97404de1..6170d9fd8 100644 --- a/app/javascript/mastodon/features/status/containers/card_container.js +++ b/app/javascript/mastodon/features/status/containers/card_container.js @@ -2,7 +2,7 @@ import { connect } from 'react-redux'; import Card from '../components/card'; const mapStateToProps = (state, { statusId }) => ({ - card: state.getIn(['cards', statusId], null), + card: state.getIn(['statuses', statusId, 'card'], null), }); export default connect(mapStateToProps)(Card); diff --git a/app/javascript/mastodon/reducers/index.js b/app/javascript/mastodon/reducers/index.js index e98566e26..2c98af1db 100644 --- a/app/javascript/mastodon/reducers/index.js +++ b/app/javascript/mastodon/reducers/index.js @@ -14,7 +14,6 @@ import relationships from './relationships'; import settings from './settings'; import push_notifications from './push_notifications'; import status_lists from './status_lists'; -import cards from './cards'; import mutes from './mutes'; import reports from './reports'; import contexts from './contexts'; @@ -46,7 +45,6 @@ const reducers = { relationships, settings, push_notifications, - cards, mutes, reports, contexts, diff --git a/app/javascript/mastodon/reducers/statuses.js b/app/javascript/mastodon/reducers/statuses.js index 6e3d830da..2c58969f3 100644 --- a/app/javascript/mastodon/reducers/statuses.js +++ b/app/javascript/mastodon/reducers/statuses.js @@ -10,6 +10,7 @@ import { STATUS_REVEAL, STATUS_HIDE, } from '../actions/statuses'; +import { STATUS_CARD_FETCH_SUCCESS } from '../actions/cards'; import { TIMELINE_DELETE } from '../actions/timelines'; import { STATUS_IMPORT, STATUSES_IMPORT } from '../actions/importer'; import { Map as ImmutableMap, fromJS } from 'immutable'; @@ -65,6 +66,8 @@ export default function statuses(state = initialState, action) { }); case TIMELINE_DELETE: return deleteStatus(state, action.id, action.references); + case STATUS_CARD_FETCH_SUCCESS: + return state.setIn([action.id, 'card'], fromJS(action.card)); default: return state; } diff --git a/app/javascript/styles/mastodon/components.scss b/app/javascript/styles/mastodon/components.scss index f77dc405c..419f85c36 100644 --- a/app/javascript/styles/mastodon/components.scss +++ b/app/javascript/styles/mastodon/components.scss @@ -2560,6 +2560,9 @@ a.status-card { display: block; margin-top: 5px; font-size: 13px; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; } .status-card__image { @@ -2584,6 +2587,31 @@ a.status-card { } } +.status-card.compact { + border-color: lighten($ui-base-color, 4%); + + &.interactive { + border: 0; + } + + .status-card__content { + padding: 8px; + padding-top: 10px; + } + + .status-card__title { + white-space: nowrap; + } + + .status-card__image { + flex: 0 0 60px; + } +} + +a.status-card.compact:hover { + background-color: lighten($ui-base-color, 4%); +} + .status-card__image-image { border-radius: 4px 0 0 4px; display: block; diff --git a/app/models/status.rb b/app/models/status.rb index bcb7dd373..cb2c01040 100644 --- a/app/models/status.rb +++ b/app/models/status.rb @@ -89,6 +89,7 @@ class Status < ApplicationRecord :conversation, :status_stat, :tags, + :preview_cards, :stream_entry, active_mentions: :account, reblog: [ @@ -96,6 +97,7 @@ class Status < ApplicationRecord :application, :stream_entry, :tags, + :preview_cards, :media_attachments, :conversation, :status_stat, @@ -163,6 +165,10 @@ class Status < ApplicationRecord reblog end + def preview_card + preview_cards.first + end + def title if destroyed? "#{account.acct} deleted status" diff --git a/app/serializers/rest/status_serializer.rb b/app/serializers/rest/status_serializer.rb index 1f2f46b7e..bfc2d78b4 100644 --- a/app/serializers/rest/status_serializer.rb +++ b/app/serializers/rest/status_serializer.rb @@ -20,6 +20,8 @@ class REST::StatusSerializer < ActiveModel::Serializer has_many :tags has_many :emojis, serializer: REST::CustomEmojiSerializer + has_one :preview_card, key: :card, serializer: REST::PreviewCardSerializer + def id object.id.to_s end diff --git a/app/services/fetch_link_card_service.rb b/app/services/fetch_link_card_service.rb index 4551aa7e0..462e5ee13 100644 --- a/app/services/fetch_link_card_service.rb +++ b/app/services/fetch_link_card_service.rb @@ -63,6 +63,7 @@ class FetchLinkCardService < BaseService def attach_card @status.preview_cards << @card + Rails.cache.delete(@status) end def parse_urls From 678f5ed296e71bb80d170027b114d9d30a7ccab7 Mon Sep 17 00:00:00 2001 From: kedama Date: Sun, 28 Oct 2018 14:39:59 +0900 Subject: [PATCH 33/36] Set z-index of dropdown to 9999. (#9126) --- app/javascript/styles/mastodon/components.scss | 1 + 1 file changed, 1 insertion(+) diff --git a/app/javascript/styles/mastodon/components.scss b/app/javascript/styles/mastodon/components.scss index 419f85c36..e5d9f7b9f 100644 --- a/app/javascript/styles/mastodon/components.scss +++ b/app/javascript/styles/mastodon/components.scss @@ -1669,6 +1669,7 @@ a.account__display-name { padding: 4px 0; border-radius: 4px; box-shadow: 2px 4px 15px rgba($base-shadow-color, 0.4); + z-index: 9999; ul { list-style: none; From 93a1ab9030a358348addd55d5e18caaaec2d3a37 Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Sun, 28 Oct 2018 06:40:45 +0100 Subject: [PATCH 34/36] Add progress indicators to MigrateAccountConversations (#9101) * Add progress indicators to MigrateAccountConversations * Avoid running expensive query for explain * Use exec_query instead of execute --- ...024224956_migrate_account_conversations.rb | 50 +++++++++++++++---- 1 file changed, 41 insertions(+), 9 deletions(-) diff --git a/db/migrate/20181024224956_migrate_account_conversations.rb b/db/migrate/20181024224956_migrate_account_conversations.rb index 1821e8c27..47f7375ba 100644 --- a/db/migrate/20181024224956_migrate_account_conversations.rb +++ b/db/migrate/20181024224956_migrate_account_conversations.rb @@ -14,12 +14,29 @@ class MigrateAccountConversations < ActiveRecord::Migration[5.2] sleep 1 end - local_direct_statuses.find_each do |status| + total = estimate_rows(local_direct_statuses) + estimate_rows(notifications_about_direct_statuses) + migrated = 0 + started_time = Time.zone.now + last_time = Time.zone.now + + local_direct_statuses.includes(:account, mentions: :account).find_each do |status| AccountConversation.add_status(status.account, status) + migrated += 1 + + if Time.zone.now - last_time > 1 + say_progress(migrated, total, started_time) + last_time = Time.zone.now + end end - notifications_about_direct_statuses.find_each do |notification| + notifications_about_direct_statuses.includes(:account, mention: { status: [:account, mentions: :account] }).find_each do |notification| AccountConversation.add_status(notification.account, notification.target_status) + migrated += 1 + + if Time.zone.now - last_time > 1 + say_progress(migrated, total, started_time) + last_time = Time.zone.now + end end end @@ -28,16 +45,31 @@ class MigrateAccountConversations < ActiveRecord::Migration[5.2] private + def estimate_rows(query) + result = exec_query("EXPLAIN #{query.to_sql}").first + result['QUERY PLAN'].scan(/ rows=([\d]+)/).first&.first&.to_i || 0 + end + + def say_progress(migrated, total, started_time) + status = "Migrated #{migrated} rows" + + percentage = 100.0 * migrated / total + status += " (~#{sprintf('%.2f', percentage)}%, " + + remaining_time = (100.0 - percentage) * (Time.zone.now - started_time) / percentage + + status += "#{(remaining_time / 60).to_i}:" + status += sprintf('%02d', remaining_time.to_i % 60) + status += ' remaining)' + + say status, true + end + def local_direct_statuses - Status.unscoped - .local - .where(visibility: :direct) - .includes(:account, mentions: :account) + Status.unscoped.local.where(visibility: :direct) end def notifications_about_direct_statuses - Notification.joins(mention: :status) - .where(activity_type: 'Mention', statuses: { visibility: :direct }) - .includes(:account, mention: { status: [:account, mentions: :account] }) + Notification.joins(mention: :status).where(activity_type: 'Mention', statuses: { visibility: :direct }) end end From 11b3ee4f4c1ede03f31dff4048283480ee22dd5f Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Sun, 28 Oct 2018 06:42:34 +0100 Subject: [PATCH 35/36] Reset status cache when status_stat or media_attachment updates (#9119) * Reset status cache when status_stat or media_attachment updates Fix #8711 Media attachments are generally immutable, but admins can update the sensitive flag, and this would ensure the change is visible instantly. Same for updates to status stats. That is a regression from #8185, because even the correct updated_at fetched from a join doesn't seem to invalidate the cache. * Remove join from Status#cache_ids since it has no effect --- app/models/media_attachment.rb | 6 ++++++ app/models/status.rb | 4 ---- app/models/status_stat.rb | 8 ++++++++ 3 files changed, 14 insertions(+), 4 deletions(-) diff --git a/app/models/media_attachment.rb b/app/models/media_attachment.rb index 1e4fae3de..1bfe02fd6 100644 --- a/app/models/media_attachment.rb +++ b/app/models/media_attachment.rb @@ -130,6 +130,7 @@ class MediaAttachment < ApplicationRecord "#{x},#{y}" end + after_commit :reset_parent_cache, on: :update before_create :prepare_description, unless: :local? before_create :set_shortcode before_post_process :set_type_and_extension @@ -230,4 +231,9 @@ class MediaAttachment < ApplicationRecord bitrate: movie.bitrate, } end + + def reset_parent_cache + return if status_id.nil? + Rails.cache.delete("statuses/#{status_id}") + end end diff --git a/app/models/status.rb b/app/models/status.rb index cb2c01040..32fedb924 100644 --- a/app/models/status.rb +++ b/app/models/status.rb @@ -240,10 +240,6 @@ class Status < ApplicationRecord before_validation :set_local class << self - def cache_ids - left_outer_joins(:status_stat).select('statuses.id, greatest(statuses.updated_at, status_stats.updated_at) AS updated_at') - end - def selectable_visibilities visibilities.keys - %w(direct limited) end diff --git a/app/models/status_stat.rb b/app/models/status_stat.rb index 9d358776b..024c467e7 100644 --- a/app/models/status_stat.rb +++ b/app/models/status_stat.rb @@ -14,4 +14,12 @@ class StatusStat < ApplicationRecord belongs_to :status, inverse_of: :status_stat + + after_commit :reset_parent_cache + + private + + def reset_parent_cache + Rails.cache.delete("statuses/#{status_id}") + end end From 26fe37c41460d6db3b5dd975a86c14fdd8dfadf3 Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Sun, 28 Oct 2018 07:15:20 +0100 Subject: [PATCH 36/36] Update i18n-tasks and change CircleCI command (#9104) * Update i18n-tasks and CircleCI command * Fix #9088 * Update i18n-tasks * Fix ast --- .circleci/config.yml | 2 +- Gemfile | 2 +- Gemfile.lock | 4 +-- config/locales/activerecord.ast.yml | 1 + config/locales/ast.yml | 3 +- config/locales/cs.yml | 52 +++++++--------------------- config/locales/cy.yml | 24 ++++--------- config/locales/devise.ast.yml | 1 + config/locales/devise.cs.yml | 4 +-- config/locales/devise.cy.yml | 4 +-- config/locales/devise.hr.yml | 4 +-- config/locales/devise.pl.yml | 4 +-- config/locales/devise.zh-TW.yml | 4 +-- config/locales/doorkeeper.ast.yml | 1 + config/locales/en_GB.yml | 1 + config/locales/hr.yml | 12 ++----- config/locales/pl.yml | 13 ++----- config/locales/simple_form.en_GB.yml | 1 + config/locales/sk.yml | 20 +++-------- config/locales/sr.yml | 28 ++++----------- config/locales/uk.yml | 24 ++++--------- config/locales/zh-CN.yml | 7 ++-- config/locales/zh-TW.yml | 49 +++++++------------------- 23 files changed, 73 insertions(+), 192 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index c1b963472..1161e4076 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -175,7 +175,7 @@ jobs: - *attach_workspace - run: bundle exec i18n-tasks check-normalized - run: bundle exec i18n-tasks unused - - run: bundle exec i18n-tasks missing-plural-keys + - run: bundle exec i18n-tasks missing -t plural - run: bundle exec i18n-tasks check-consistent-interpolations workflows: diff --git a/Gemfile b/Gemfile index 1e48b500a..ca2d2d51a 100644 --- a/Gemfile +++ b/Gemfile @@ -95,7 +95,7 @@ gem 'rdf-normalize', '~> 0.3' group :development, :test do gem 'fabrication', '~> 2.20' gem 'fuubar', '~> 2.3' - gem 'i18n-tasks', '~> 0.9', require: false, git: 'https://github.com/Gargron/i18n-tasks.git', ref: '7a57fbe7000f4f8120e250a757ab345c28c6885c' + gem 'i18n-tasks', '~> 0.9', require: false, git: 'https://github.com/Gargron/i18n-tasks.git', ref: 'ab6e10878ccdb6243f934f30372276d260c14251' gem 'pry-byebug', '~> 3.6' gem 'pry-rails', '~> 0.3' gem 'rspec-rails', '~> 3.8' diff --git a/Gemfile.lock b/Gemfile.lock index d7ccb59b8..166dfdb4f 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,7 +1,7 @@ GIT remote: https://github.com/Gargron/i18n-tasks.git - revision: 7a57fbe7000f4f8120e250a757ab345c28c6885c - ref: 7a57fbe7000f4f8120e250a757ab345c28c6885c + revision: ab6e10878ccdb6243f934f30372276d260c14251 + ref: ab6e10878ccdb6243f934f30372276d260c14251 specs: i18n-tasks (0.9.27) activesupport (>= 4.0.2) diff --git a/config/locales/activerecord.ast.yml b/config/locales/activerecord.ast.yml index 0d161faf2..6e32cbc2f 100644 --- a/config/locales/activerecord.ast.yml +++ b/config/locales/activerecord.ast.yml @@ -1 +1,2 @@ +--- ast: {} diff --git a/config/locales/ast.yml b/config/locales/ast.yml index 98986cdd0..f787e98f8 100644 --- a/config/locales/ast.yml +++ b/config/locales/ast.yml @@ -21,8 +21,7 @@ ast: hosted_on: Mastodon ta agospiáu en %{domain} learn_more: Deprendi más source_code: Códigu fonte - status_count_after: - other: estaos + status_count_after: estaos terms: Términos del serviciu user_count_after: usuarios what_is_mastodon: "¿Qué ye Mastodon?" diff --git a/config/locales/cs.yml b/config/locales/cs.yml index 67bda70f1..c73c4fee1 100644 --- a/config/locales/cs.yml +++ b/config/locales/cs.yml @@ -30,22 +30,16 @@ cs: other_instances: Seznam instancí privacy_policy: Zásady soukromí source_code: Zdrojový kód - status_count_after: - one: příspěvek - other: příspěvků + status_count_after: příspěvků status_count_before: Kteří napsali terms: Podmínky používání - user_count_after: - one: uživatele - other: uživatelů + user_count_after: uživatelů user_count_before: Domov what_is_mastodon: Co je Mastodon? accounts: choices_html: 'Volby uživatele %{name}:' follow: Sledovat - followers: - one: Sledovatel - other: Sledovatelé + followers: Sledovatelé following: Sledovaní joined: Připojil/a se v %{date} link_verified_on: Vlastnictví tohoto odkazu bylo zkontrolováno %{date} @@ -57,9 +51,7 @@ cs: people_who_follow: Lidé, kteří sledují uživatele %{name} pin_errors: following: Musíte již sledovat osobu, kterou chcete podpořit - posts: - one: Toot - other: Tooty + posts: Tooty posts_tab_heading: Tooty posts_with_replies: Tooty a odpovědi reserved_username: Toto uživatelské jméno je rezervováno @@ -268,9 +260,7 @@ cs: suspend: Suspendovat severity: Přísnost show: - affected_accounts: - one: Jeden účet v databázi byl ovlivněn - other: "%{count} účtů v databázi byl ovlivněn" + affected_accounts: "%{count} účtů v databázi byl ovlivněn" retroactive: silence: Odtišit všechny existující účty z této domény suspend: Zrušit suspenzaci všech existujících účtů z této domény @@ -562,9 +552,7 @@ cs: followers_count: Počet sledovatelů lock_link: Zamkněte svůj účet purge: Odstranit ze sledovatelů - success: - one: V průběhu utišování sledovatelů z jedné domény... - other: V průběhu utišování sledovatelů z %{count} domén... + success: V průběhu utišování sledovatelů z %{count} domén... true_privacy_html: Berte prosím na vědomí, že skutečného soukromí se dá dosáhnout pouze za pomoci end-to-end šifrování. unlocked_warning_html: Kdokoliv vás může sledovat a okamžitě vidět vaše soukromé příspěvky. %{lock_link}, abyste mohl/a zkontrolovat a odmítnout sledovatele. unlocked_warning_title: Váš účet není zamknutý @@ -575,9 +563,7 @@ cs: generic: changes_saved_msg: Změny byly úspěšně uloženy! save_changes: Uložit změny - validation_errors: - one: Něco ještě není úplně v pořádku! Prosím zkontrolujte chybu níže - other: Něco ještě není úplně v pořádku! Prosím zkontrolujte %{count} chyb níže + validation_errors: Něco ještě není úplně v pořádku! Prosím zkontrolujte %{count} chyb níže imports: preface: Můžete importovat data, která jste exportoval/a z jiné instance, jako například seznam lidí, které sledujete či blokujete. success: Vaše data byla úspěšně nahrána a nyní budou zpracována v daný čas @@ -600,9 +586,7 @@ cs: expires_in_prompt: Nikdy generate: Vygenerovat invited_by: 'Byl/a jste pozván/a uživatelem:' - max_uses: - one: 1 použití - other: "%{count} použití" + max_uses: "%{count} použití" max_uses_prompt: Bez limitu prompt: Vygenerujte a sdílejte s ostatními odkazy a umožněte jim přístup na tuto instanci table: @@ -628,12 +612,8 @@ cs: action: Zobrazit všechna oznámení body: Zde najdete stručný souhrn zpráv, které jste zmeškal/a od vaší poslední návštěvy %{since} mention: "%{name} vás zmínil/a v:" - new_followers_summary: - one: Navíc jste získal/a jednoho nového sledovatele, zatímco jste byl/a pryč! Hurá! - other: Navíc jste získal/a %{count} nových sledovatelů, zatímco jste byl/a pryč! Hurá! - subject: - one: "Jedno nové oznámení od vaší poslední návštěvy \U0001F418" - other: "%{count} nových oznámení od vaší poslední návštěvy \U0001F418" + new_followers_summary: Navíc jste získal/a %{count} nových sledovatelů, zatímco jste byl/a pryč! Hurá! + subject: "%{count} nových oznámení od vaší poslední návštěvy \U0001F418" title: Ve vaší absenci... favourite: body: 'Váš příspěvek si oblíbil/a %{name}:' @@ -750,17 +730,11 @@ cs: statuses: attached: description: 'Přiloženo: %{attached}' - image: - one: "%{count} obrázek" - other: "%{count} obrázků" - video: - one: "%{count} video" - other: "%{count} videí" + image: "%{count} obrázků" + video: "%{count} videí" boosted_from_html: Boostnuto z %{acct_link} content_warning: 'Varování o obsahu: %{warning}' - disallowed_hashtags: - one: 'obsahuje nepovolený hashtag: %{tags}' - other: 'obsahuje nepovolené hashtagy: %{tags}' + disallowed_hashtags: 'obsahuje nepovolené hashtagy: %{tags}' language_detection: Zjistit jazyk automaticky open_in_web: Otevřít na webu over_character_limit: limit %{max} znaků byl překročen diff --git a/config/locales/cy.yml b/config/locales/cy.yml index 8b16949a5..3bf256ac5 100644 --- a/config/locales/cy.yml +++ b/config/locales/cy.yml @@ -30,22 +30,16 @@ cy: other_instances: Rhestr achosion privacy_policy: Polisi preifatrwydd source_code: Cod ffynhonnell - status_count_after: - one: statws - other: statws + status_count_after: statws status_count_before: Pwy ysgrifennodd terms: Telerau gwasanaeth - user_count_after: - one: defnyddiwr - other: defnyddwyr + user_count_after: defnyddwyr user_count_before: Cartref i what_is_mastodon: Beth yw Mastodon? accounts: choices_html: 'Dewisiadau %{name}:' follow: Dilynwch - followers: - one: Dilynwr - other: Dilynwyr + followers: Dilynwyr following: Yn dilyn joined: Ymunodd %{date} media: Cyfryngau @@ -56,9 +50,7 @@ cy: people_who_follow: Pobl sy'n dilyn %{name} pin_errors: following: Rhaid i ti fod yn dilyn y person yr ydych am ei gymeradwyo yn barod - posts: - one: Tŵt - other: Tŵtiau + posts: Tŵtiau posts_tab_heading: Tŵtiau posts_with_replies: Tŵtiau ac atebion reserved_username: Mae'r enw defnyddior yn neilltuedig @@ -262,9 +254,7 @@ cy: suspend: Atal severity: Difrifoldeb show: - affected_accounts: - one: Mae un cyfri yn y bas data wedi ei effeithio - other: "%{count} o gyfrifoedd yn y bas data wedi eu hefeithio" + affected_accounts: "%{count} o gyfrifoedd yn y bas data wedi eu hefeithio" retroactive: silence: Dad-dawelu pob cyfri presennol o'r parth hwn suspend: Dad-atal pob cyfrif o'r parth hwn sy'n bodoli @@ -508,9 +498,7 @@ cy: generic: changes_saved_msg: Llwyddwyd i gadw y newidiadau! save_changes: Cadw newidiadau - validation_errors: - one: Mae rhywbeth o'i le o hyd! Edrychwch ar y gwall isod os gwelwch yn dda - other: Mae rhywbeth o'i le o hyd! Edrychwch ar y %{count} gwall isod os gwelwch yn dda + validation_errors: Mae rhywbeth o'i le o hyd! Edrychwch ar y %{count} gwall isod os gwelwch yn dda imports: preface: Mae modd mewnforio data yr ydych wedi allforio o achos arall, megis rhestr o bobl yr ydych yn ei ddilyn neu yn blocio. success: Uwchlwyddwyd eich data yn llwyddiannus ac fe fydd yn cael ei brosesu mewn da bryd diff --git a/config/locales/devise.ast.yml b/config/locales/devise.ast.yml index 0d161faf2..6e32cbc2f 100644 --- a/config/locales/devise.ast.yml +++ b/config/locales/devise.ast.yml @@ -1 +1,2 @@ +--- ast: {} diff --git a/config/locales/devise.cs.yml b/config/locales/devise.cs.yml index 49814b368..4268dc0ad 100644 --- a/config/locales/devise.cs.yml +++ b/config/locales/devise.cs.yml @@ -77,6 +77,4 @@ cs: expired: vypršel, prosím vyžádejte si nový not_found: nenalezen not_locked: nebyl uzamčen - not_saved: - one: '1 chyba zabránila uložení tohoto %{resource}:' - other: "%{count} chyb zabránila uložení tohoto %{resource}:" + not_saved: "%{count} chyb zabránila uložení tohoto %{resource}:" diff --git a/config/locales/devise.cy.yml b/config/locales/devise.cy.yml index 9cf8b96f0..d7d694f14 100644 --- a/config/locales/devise.cy.yml +++ b/config/locales/devise.cy.yml @@ -77,6 +77,4 @@ cy: expired: wedi dod i ben, gwnewch gais am un newydd os gwelwch yn dda not_found: heb ei ganfod not_locked: heb ei gloi - not_saved: - one: 'Gwaharddwyd yr %{resource} rhag cael ei arbed oherwydd 1 gwall:' - other: 'Gwaharddwyd yr %{resource} rhag cael ei arbed oherwydd %{count} gwall:' + not_saved: 'Gwaharddwyd yr %{resource} rhag cael ei arbed oherwydd %{count} gwall:' diff --git a/config/locales/devise.hr.yml b/config/locales/devise.hr.yml index 07c0079ab..276d26cad 100644 --- a/config/locales/devise.hr.yml +++ b/config/locales/devise.hr.yml @@ -58,6 +58,4 @@ hr: expired: je istekao, zatraži novu not_found: nije nađen not_locked: nije zaključan - not_saved: - one: '1 greška je zabranila da ovaj %{resource} bude sačuvan:' - other: "%{count} greške su zabranile da ovaj %{resource} bude sačuvan:" + not_saved: "%{count} greške su zabranile da ovaj %{resource} bude sačuvan:" diff --git a/config/locales/devise.pl.yml b/config/locales/devise.pl.yml index 77afc4bf5..54bae2925 100644 --- a/config/locales/devise.pl.yml +++ b/config/locales/devise.pl.yml @@ -77,6 +77,4 @@ pl: expired: wygasło, poproś o nowe not_found: nie znaleziono not_locked: było zablokowane - not_saved: - one: '1 błąd uniemożliwił zapisanie zasobu %{resource}:' - other: 'Błędy (%{count}) uniemożliwiły zapisanie zasobu %{resource}:' + not_saved: 'Błędy (%{count}) uniemożliwiły zapisanie zasobu %{resource}:' diff --git a/config/locales/devise.zh-TW.yml b/config/locales/devise.zh-TW.yml index 195f167a0..6dec562e1 100644 --- a/config/locales/devise.zh-TW.yml +++ b/config/locales/devise.zh-TW.yml @@ -77,6 +77,4 @@ zh-TW: expired: 已經過期,請重新申請 not_found: 找不到 not_locked: 並未被鎖定 - not_saved: - one: 1 個錯誤使 %{resource} 無法被儲存︰ - other: "%{count} 個錯誤使 %{resource} 無法被儲存︰" + not_saved: "%{count} 個錯誤使 %{resource} 無法被儲存︰" diff --git a/config/locales/doorkeeper.ast.yml b/config/locales/doorkeeper.ast.yml index 0d161faf2..6e32cbc2f 100644 --- a/config/locales/doorkeeper.ast.yml +++ b/config/locales/doorkeeper.ast.yml @@ -1 +1,2 @@ +--- ast: {} diff --git a/config/locales/en_GB.yml b/config/locales/en_GB.yml index 0967ef424..d9e1a256f 100644 --- a/config/locales/en_GB.yml +++ b/config/locales/en_GB.yml @@ -1 +1,2 @@ +--- {} diff --git a/config/locales/hr.yml b/config/locales/hr.yml index 851b3623b..729206a98 100644 --- a/config/locales/hr.yml +++ b/config/locales/hr.yml @@ -61,9 +61,7 @@ hr: generic: changes_saved_msg: Izmjene su uspješno sačuvane! save_changes: Sačuvaj izmjene - validation_errors: - one: Nešto ne štima! Vidi grešku ispod - other: Nešto još uvijek ne štima! Vidi %{count} greške ispod + validation_errors: Nešto još uvijek ne štima! Vidi %{count} greške ispod imports: preface: Možeš uvesti određene podatke kao što su svi ljudi koje slijediš ili blokiraš u svoj račun na ovoj instanci, sa fajlova kreiranih izvozom sa druge instance. success: Tvoji podaci su uspješno uploadani i bit će obrađeni u dogledno vrijeme @@ -76,12 +74,8 @@ hr: digest: body: 'Ovo je kratak sažetak propuštenog od tvog prošlog posjeta %{since}:' mention: "%{name} te je spomenuo:" - new_followers_summary: - one: Imaš novog sljedbenika! Yay! - other: Imaš %{count} novih sljedbenika! Prekrašno! - subject: - one: "1 nova notifikacija od tvog prošlog posjeta \U0001F418" - other: "%{count} novih notifikacija od tvog prošlog posjeta \U0001F418" + new_followers_summary: Imaš %{count} novih sljedbenika! Prekrašno! + subject: "%{count} novih notifikacija od tvog prošlog posjeta \U0001F418" favourite: body: 'Tvoj status je %{name} označio kao omiljen:' subject: "%{name} je označio kao omiljen tvoj status" diff --git a/config/locales/pl.yml b/config/locales/pl.yml index eb102cdec..74b2470bd 100644 --- a/config/locales/pl.yml +++ b/config/locales/pl.yml @@ -279,10 +279,7 @@ pl: suspend: Zawieś severity: Priorytet show: - affected_accounts: - many: Dotyczy %{count} kont w bazie danych - one: Dotyczy jednego konta w bazie danych - other: Dotyczy %{count} kont w bazie danych + affected_accounts: Dotyczy %{count} kont w bazie danych retroactive: silence: Odwołaj wyciszenie wszystkich kont w tej domenie suspend: Odwołaj zawieszenie wszystkich kont w tej domenie @@ -577,9 +574,7 @@ pl: followers_count: Liczba śledzących lock_link: Zablokuj swoje konto purge: Przestań śledzić - success: - one: W trakcie usuwania śledzących z jednej domeny… - other: W trakcie usuwania śledzących z %{count} domen… + success: W trakcie usuwania śledzących z %{count} domen… true_privacy_html: Pamiętaj, że rzeczywista prywatność może zostać uzyskana wyłącznie dzięki szyfrowaniu end-to-end. unlocked_warning_html: Każdy może Cię śledzić, dzięki czemu może zobaczyć Twoje niepubliczne wpisy. %{lock_link} aby móc kontrolować, kto Cię śledzi. unlocked_warning_title: Twoje konto nie jest zablokowane @@ -786,9 +781,7 @@ pl: other: "%{count} filmów" boosted_from_html: Podbito przez %{acct_link} content_warning: 'Ostrzeżenie o zawartości: %{warning}' - disallowed_hashtags: - one: 'zawiera niedozwolony hashtag: %{tags}' - other: 'zawiera niedozwolone hashtagi: %{tags}' + disallowed_hashtags: 'zawiera niedozwolone hashtagi: %{tags}' language_detection: Automatycznie wykrywaj język open_in_web: Otwórz w przeglądarce over_character_limit: limit %{max} znaków przekroczony diff --git a/config/locales/simple_form.en_GB.yml b/config/locales/simple_form.en_GB.yml index 0967ef424..d9e1a256f 100644 --- a/config/locales/simple_form.en_GB.yml +++ b/config/locales/simple_form.en_GB.yml @@ -1 +1,2 @@ +--- {} diff --git a/config/locales/sk.yml b/config/locales/sk.yml index 6b18d31de..2b928169a 100644 --- a/config/locales/sk.yml +++ b/config/locales/sk.yml @@ -30,22 +30,16 @@ sk: other_instances: Zoznam ďalších inštancií privacy_policy: Ustanovenia o súkromí source_code: Zdrojový kód - status_count_after: - one: status - other: statusy + status_count_after: statusy status_count_before: Ktorí napísali terms: Podmienky užívania - user_count_after: - one: užívateľ - other: užívateľov + user_count_after: užívateľov user_count_before: Domov pre what_is_mastodon: Čo je Mastodon? accounts: choices_html: "%{name}vé voľby:" follow: Sledovať - followers: - one: Následovateľ - other: Sledovatelia + followers: Sledovatelia following: Sledovaní joined: Pridal/a sa %{date} media: Médiá @@ -56,9 +50,7 @@ sk: people_who_follow: Ľudia sledujúci %{name} pin_errors: following: Musíš už následovať toho človeka, ktorého si praješ zviditeľniť - posts: - one: Príspevok - other: Príspevky + posts: Príspevky posts_tab_heading: Príspevky posts_with_replies: Príspevky s odpoveďami reserved_username: Prihlasovacie meno je rezervované @@ -746,9 +738,7 @@ sk: other: "%{count} videí" boosted_from_html: Povýšené od %{acct_link} content_warning: 'Varovanie o obsahu: %{warning}' - disallowed_hashtags: - one: 'obsahuje nepovolený haštag: %{tags}' - other: 'obsahuje nepovolené haštagy: %{tags}' + disallowed_hashtags: 'obsahuje nepovolené haštagy: %{tags}' language_detection: Zisti jazyk automaticky open_in_web: Otvor v okne prehliadača over_character_limit: limit počtu %{max} znakov bol presiahnutý diff --git a/config/locales/sr.yml b/config/locales/sr.yml index 36d81886e..1ade87f9e 100644 --- a/config/locales/sr.yml +++ b/config/locales/sr.yml @@ -30,22 +30,16 @@ sr: other_instances: Листа инстанци privacy_policy: Полиса приватности source_code: Изворни код - status_count_after: - one: статус - other: статуси + status_count_after: статуси status_count_before: Који су написали terms: Услови коришћења - user_count_after: - one: корисник - other: корисници + user_count_after: корисници user_count_before: Дом за what_is_mastodon: Шта је Мастодон? accounts: choices_html: "%{name}'s избори:" follow: Запрати - followers: - one: Пратилац - other: Пратиоци + followers: Пратиоци following: Пратим joined: Придружио/ла се %{date} media: Медији @@ -56,9 +50,7 @@ sr: people_who_follow: Људи који прате %{name} pin_errors: following: Морате пратити ову особу ако хоћете да потврдите - posts: - one: Труба - other: Трубе + posts: Трубе posts_tab_heading: Трубе posts_with_replies: Трубе и одговори reserved_username: Корисничко име је резервисано @@ -754,17 +746,11 @@ sr: statuses: attached: description: 'У прилогу: %{attached}' - image: - one: "%{count} слику" - other: "%{count} слике" - video: - one: "%{count} видео" - other: "%{count} видеа" + image: "%{count} слике" + video: "%{count} видеа" boosted_from_html: Подржано од %{acct_link} content_warning: 'Упозорење на садржај: %{warning}' - disallowed_hashtags: - one: 'садржи забрањену тарабу: %{tags}' - other: 'садржи забрањене тарабе: %{tags}' + disallowed_hashtags: 'садржи забрањене тарабе: %{tags}' language_detection: Аутоматскo откривање језика open_in_web: Отвори у вебу over_character_limit: ограничење од %{max} карактера прекорачено diff --git a/config/locales/uk.yml b/config/locales/uk.yml index 83a315a37..986ef70ad 100644 --- a/config/locales/uk.yml +++ b/config/locales/uk.yml @@ -518,18 +518,14 @@ uk: followers_count: Кількість підписників lock_link: Закрийте акаунт purge: Видалити з підписників - success: - one: У процесі м'якого блокування підписників з одного домену... - other: У процесі м'якого блокування підписників з %{count} доменів... + success: У процесі м'якого блокування підписників з %{count} доменів... true_privacy_html: Будь ласка, помітьте, що справжняя конфіденційність може бути досягнена тільки за допомогою end-to-end шифрування. unlocked_warning_html: Хто завгодно може підписатися на Вас та отримати доступ до перегляду Ваших приватних статусів. %{lock_link}, щоб отримати можливість роздивлятися та вручну підтверджувати запити щодо підписки. unlocked_warning_title: Ваш аккаунт не закритий для підписки generic: changes_saved_msg: Зміни успішно збережені! save_changes: Зберегти зміни - validation_errors: - one: Щось тут не так! Будь ласка, ознайомтеся з помилкою нижче - other: Щось тут не так! Будь ласка, ознайомтеся з %{count} помилками нижче + validation_errors: Щось тут не так! Будь ласка, ознайомтеся з %{count} помилками нижче imports: preface: Вы можете завантажити деякі дані, наприклад, списки людей, на яких Ви підписані чи яких блокуєте, в Ваш акаунт на цій інстанції з файлів, експортованих з іншої інстанції. success: Ваші дані були успішно загружені та будуть оброблені в найближчий момент @@ -552,9 +548,7 @@ uk: expires_in_prompt: Ніколи generate: Згенерувати invited_by: 'Вас запросив(-ла):' - max_uses: - one: 1 використання - other: "%{count} використань" + max_uses: "%{count} використань" max_uses_prompt: Без обмеження prompt: Генеруйте та діліться посиланням з іншими для надання доступу до сайту table: @@ -703,17 +697,11 @@ uk: statuses: attached: description: 'Прикріплено: %{attached}' - image: - one: "%{count} картинка" - other: "%{count} картинки" - video: - one: "%{count} відео" - other: "%{count} відео" + image: "%{count} картинки" + video: "%{count} відео" boosted_from_html: Просунуто від %{acct_link} content_warning: 'Попередження про контент: %{warning}' - disallowed_hashtags: - one: 'містив заборонений хештеґ: %{tags}' - other: 'містив заборонені хештеґи: %{tags}' + disallowed_hashtags: 'містив заборонені хештеґи: %{tags}' language_detection: Автоматично визначати мову open_in_web: Відкрити у вебі over_character_limit: перевищено ліміт символів (%{max}) diff --git a/config/locales/zh-CN.yml b/config/locales/zh-CN.yml index 0ce1a0ed7..ca2d388b0 100644 --- a/config/locales/zh-CN.yml +++ b/config/locales/zh-CN.yml @@ -30,13 +30,10 @@ zh-CN: other_instances: 其他实例 privacy_policy: 隐私政策 source_code: 源代码 - status_count_after: - one: 条嘟文 + status_count_after: 条嘟文 status_count_before: 他们共嘟出了 terms: 使用条款 - user_count_after: - one: 位用户 - other: 位用户 + user_count_after: 位用户 user_count_before: 这里共注册有 what_is_mastodon: Mastodon 是什么? accounts: diff --git a/config/locales/zh-TW.yml b/config/locales/zh-TW.yml index d1b7633f3..9a7c2b293 100644 --- a/config/locales/zh-TW.yml +++ b/config/locales/zh-TW.yml @@ -29,18 +29,15 @@ zh-TW: learn_more: 了解詳細 other_instances: 其他站點 source_code: 原始碼 - status_count_after: - one: 狀態 + status_count_after: 狀態 status_count_before: 他們共嘟出了 terms: 使用條款 - user_count_after: - one: 使用者 + user_count_after: 使用者 user_count_before: 這裡共註冊有 what_is_mastodon: 什麼是 Mastodon? accounts: follow: 關注 - followers: - other: 關注者 + followers: 關注者 following: 正在關注 media: 媒體 moved_html: "%{name} 已經搬遷到 %{new_profile_link}:" @@ -48,9 +45,7 @@ zh-TW: nothing_here: 暫時沒有內容可供顯示! people_followed_by: "%{name} 關注的人" people_who_follow: 關注 %{name} 的人 - posts: - one: 嘟掉 - other: 嘟文 + posts: 嘟文 posts_tab_heading: 嘟文 posts_with_replies: 嘟文與回覆 reserved_username: 此用戶名已被保留 @@ -234,9 +229,7 @@ zh-TW: suspend: 自動封鎖 severity: 嚴重度 show: - affected_accounts: - one: 資料庫中有一個使用者受到影響 - other: 資料庫中有%{count}個使用者受影響 + affected_accounts: 資料庫中有%{count}個使用者受影響 retroactive: silence: 對此網域的所有使用者取消靜音 suspend: 對此網域的所有使用者取消封鎖 @@ -480,18 +473,14 @@ zh-TW: followers_count: 關注者數量 lock_link: 將你的帳戶設定為私人 purge: 移除關注者 - success: - one: 正準備軟性封鎖 1 個網域的關注者…… - other: 正準備軟性封鎖 %{count} 個網域的關注者…… + success: 正準備軟性封鎖 %{count} 個網域的關注者…… true_privacy_html: 請謹記,唯有點對點加密方可以真正確保你的隱私。 unlocked_warning_html: 任何人都可以在關注你後立即查看非公開的嘟文。只要%{lock_link},你就可以審核並拒絕關注請求。 unlocked_warning_title: 你的帳戶是公開的 generic: changes_saved_msg: 已成功儲存修改! save_changes: 儲存修改 - validation_errors: - one: 送出的資料有問題 - other: 送出的資料有 %{count} 個問題 + validation_errors: 送出的資料有 %{count} 個問題 imports: preface: 您可以在此匯入您在其他站點所匯出的資料檔,包括關注的使用者、封鎖的使用者名單。 success: 資料檔上傳成功,正在匯入,請稍候 @@ -514,9 +503,7 @@ zh-TW: expires_in_prompt: 永不過期 generate: 建立邀請連結 invited_by: 你的邀請人是: - max_uses: - one: 1 次 - other: "%{count} 次" + max_uses: "%{count} 次" max_uses_prompt: 無限制 prompt: 建立分享連結,邀請他人在本站點註冊 table: @@ -542,12 +529,8 @@ zh-TW: action: 閱覽所有通知 body: 以下是自%{since}你最後一次登入以來錯過的訊息摘要 mention: "%{name} 在此提及了你:" - new_followers_summary: - one: 而且,你不在的時候,有一個人關注你! 耶! - other: 而且,你不在的時候,有 %{count} 個人關注你了! 好棒! - subject: - one: "自從上次登入以來,你收到 1 則新的通知 \U0001F418" - other: "自從上次登入以來,你收到 %{count} 則新的通知 \U0001F418" + new_followers_summary: 而且,你不在的時候,有 %{count} 個人關注你了! 好棒! + subject: "自從上次登入以來,你收到 %{count} 則新的通知 \U0001F418" title: 你不在的時候... favourite: body: '你的嘟文被 %{name} 加入了最愛:' @@ -653,17 +636,11 @@ zh-TW: statuses: attached: description: 附件: %{attached} - image: - one: "%{count} 幅圖片" - other: "%{count} 幅圖片" - video: - one: "%{count} 段影片" - other: "%{count} 段影片" + image: "%{count} 幅圖片" + video: "%{count} 段影片" boosted_from_html: 轉嘟自 %{acct_link} content_warning: 內容警告: %{warning} - disallowed_hashtags: - one: 包含不允許的標籤: %{tags} - other: 包含不允許的標籤: %{tags} + disallowed_hashtags: 包含不允許的標籤: %{tags} language_detection: 自動偵測語言 open_in_web: 以網頁開啟 over_character_limit: 超過了 %{max} 字的限制