From 00586d27cb0f84377614a5ca2a3683c9fe9b74a5 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Wed, 28 Aug 2024 03:56:07 -0400 Subject: [PATCH 001/153] Convert `instance_actor` controller spec to request spec (#31621) --- .../instance_actors_controller_spec.rb | 54 -------------- spec/requests/instance_actor_spec.rb | 71 +++++++++++++++++++ 2 files changed, 71 insertions(+), 54 deletions(-) delete mode 100644 spec/controllers/instance_actors_controller_spec.rb create mode 100644 spec/requests/instance_actor_spec.rb diff --git a/spec/controllers/instance_actors_controller_spec.rb b/spec/controllers/instance_actors_controller_spec.rb deleted file mode 100644 index 42ffb67988..0000000000 --- a/spec/controllers/instance_actors_controller_spec.rb +++ /dev/null @@ -1,54 +0,0 @@ -# frozen_string_literal: true - -require 'rails_helper' - -RSpec.describe InstanceActorsController do - describe 'GET #show' do - context 'with JSON' do - let(:format) { 'json' } - - shared_examples 'shared behavior' do - before do - get :show, params: { format: format } - end - - it 'returns http success with correct media type and body' do - expect(response) - .to have_http_status(200) - .and have_attributes( - media_type: eq('application/activity+json') - ) - - expect(body_as_json) - .to include(:id, :type, :preferredUsername, :inbox, :publicKey, :inbox, :outbox, :url) - end - - it_behaves_like 'cacheable response' - end - - before do - allow(controller).to receive(:authorized_fetch_mode?).and_return(authorized_fetch_mode) - end - - context 'without authorized fetch mode' do - let(:authorized_fetch_mode) { false } - - it_behaves_like 'shared behavior' - end - - context 'with authorized fetch mode' do - let(:authorized_fetch_mode) { true } - - it_behaves_like 'shared behavior' - end - - context 'with a suspended instance actor' do - let(:authorized_fetch_mode) { false } - - before { Account.representative.update(suspended_at: 10.days.ago) } - - it_behaves_like 'shared behavior' - end - end - end -end diff --git a/spec/requests/instance_actor_spec.rb b/spec/requests/instance_actor_spec.rb new file mode 100644 index 0000000000..9c7ee9ff90 --- /dev/null +++ b/spec/requests/instance_actor_spec.rb @@ -0,0 +1,71 @@ +# frozen_string_literal: true + +require 'rails_helper' + +RSpec.describe 'Instance actor endpoint' do + describe 'GET /actor' do + before do + integration_session.https! # TODO: Move to global rails_helper for all request specs? + host! Rails.configuration.x.local_domain # TODO: Move to global rails_helper for all request specs? + end + + let!(:original_federation_mode) { Rails.configuration.x.limited_federation_mode } + + shared_examples 'instance actor endpoint' do + before { get instance_actor_path(format: :json) } + + it 'returns http success with correct media type and body' do + expect(response) + .to have_http_status(200) + expect(response.content_type) + .to start_with('application/activity+json') + expect(body_as_json) + .to include( + id: instance_actor_url, + type: 'Application', + preferredUsername: 'mastodon.internal', + inbox: instance_actor_inbox_url, + outbox: instance_actor_outbox_url, + publicKey: include( + id: instance_actor_url(anchor: 'main-key') + ), + url: about_more_url(instance_actor: true) + ) + end + + it_behaves_like 'cacheable response' + end + + context 'with limited federation mode disabled' do + before { Rails.configuration.x.limited_federation_mode = false } + after { Rails.configuration.x.limited_federation_mode = original_federation_mode } + + it_behaves_like 'instance actor endpoint' + + context 'with a disabled instance actor' do + before { disable_instance_actor } + + it_behaves_like 'instance actor endpoint' + end + end + + context 'with limited federation mode enabled' do + before { Rails.configuration.x.limited_federation_mode = true } + after { Rails.configuration.x.limited_federation_mode = original_federation_mode } + + it_behaves_like 'instance actor endpoint' + + context 'with a disabled instance actor' do + before { disable_instance_actor } + + it_behaves_like 'instance actor endpoint' + end + end + + def disable_instance_actor + Account + .representative + .update(suspended_at: 10.days.ago) + end + end +end From 0ef636f72d5cb5df93e558ffb0489b2804f4a815 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Wed, 28 Aug 2024 03:58:40 -0400 Subject: [PATCH 002/153] Convert `shares` controller spec to system spec (#31619) --- spec/controllers/shares_controller_spec.rb | 22 ------------ spec/system/share_entrypoint_spec.rb | 41 ++++++++++++++-------- 2 files changed, 27 insertions(+), 36 deletions(-) delete mode 100644 spec/controllers/shares_controller_spec.rb diff --git a/spec/controllers/shares_controller_spec.rb b/spec/controllers/shares_controller_spec.rb deleted file mode 100644 index 5dcc46e47a..0000000000 --- a/spec/controllers/shares_controller_spec.rb +++ /dev/null @@ -1,22 +0,0 @@ -# frozen_string_literal: true - -require 'rails_helper' - -describe SharesController do - render_views - - let(:user) { Fabricate(:user) } - - before { sign_in user } - - describe 'GET #show' do - subject(:body_classes) { assigns(:body_classes) } - - before { get :show, params: { title: 'test title', text: 'test text', url: 'url1 url2' } } - - it 'returns http success' do - expect(response).to have_http_status 200 - expect(body_classes).to eq 'modal-layout compose-standalone' - end - end -end diff --git a/spec/system/share_entrypoint_spec.rb b/spec/system/share_entrypoint_spec.rb index 5fdbeacefa..5e27781f2a 100644 --- a/spec/system/share_entrypoint_spec.rb +++ b/spec/system/share_entrypoint_spec.rb @@ -2,32 +2,45 @@ require 'rails_helper' -describe 'ShareEntrypoint', :js, :streaming do +describe 'Share page', :js, :streaming do include ProfileStories - subject { page } - let(:email) { 'test@example.com' } let(:password) { 'password' } let(:confirmed_at) { Time.zone.now } let(:finished_onboarding) { true } - before do - as_a_logged_in_user + before { as_a_logged_in_user } + + it 'allows posting a new status' do visit share_path + + expect(page) + .to have_css('.modal-layout__mastodon') + .and have_css('div#mastodon-compose') + .and have_css('.compose-form__submit') + + fill_in_form + + expect(page) + .to have_css('.notification-bar-message', text: translations['compose.published.body']) end - it 'can be used to post a new status' do - expect(subject).to have_css('div#mastodon-compose') - expect(subject).to have_css('.compose-form__submit') - - status_text = 'This is a new status!' - + def fill_in_form within('.compose-form') do - fill_in "What's on your mind?", with: status_text - click_on 'Post' + fill_in translations['compose_form.placeholder'], + with: 'This is a new status!' + click_on translations['compose_form.publish'] end + end - expect(subject).to have_css('.notification-bar-message', text: 'Post published.') + def translations + # TODO: Extract to system spec helper for re-use? + JSON.parse( + Rails + .root + .join('app', 'javascript', 'mastodon', 'locales', 'en.json') + .read + ) end end From 26d6d291c37194c40e3e5acbf4d8bae6734c2ace Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Wed, 28 Aug 2024 10:59:15 +0200 Subject: [PATCH 003/153] New Crowdin Translations (automated) (#31627) Co-authored-by: GitHub Actions --- app/javascript/mastodon/locales/cy.json | 39 +++++++++++++------- app/javascript/mastodon/locales/da.json | 4 +++ app/javascript/mastodon/locales/de.json | 4 +-- app/javascript/mastodon/locales/en-GB.json | 7 ++++ app/javascript/mastodon/locales/fo.json | 4 +++ app/javascript/mastodon/locales/fr-CA.json | 37 +++++++++++++++++-- app/javascript/mastodon/locales/fr.json | 41 +++++++++++++++++++--- app/javascript/mastodon/locales/he.json | 4 +++ app/javascript/mastodon/locales/hu.json | 4 +++ app/javascript/mastodon/locales/ia.json | 1 + app/javascript/mastodon/locales/it.json | 8 +++-- app/javascript/mastodon/locales/ja.json | 20 +++++++++++ app/javascript/mastodon/locales/ko.json | 4 +++ app/javascript/mastodon/locales/nl.json | 1 + app/javascript/mastodon/locales/nn.json | 4 +++ app/javascript/mastodon/locales/th.json | 4 +++ app/javascript/mastodon/locales/tr.json | 4 +++ app/javascript/mastodon/locales/uk.json | 4 +++ app/javascript/mastodon/locales/vi.json | 4 +++ app/javascript/mastodon/locales/zh-CN.json | 4 +++ config/locales/doorkeeper.fr.yml | 4 +-- config/locales/en-GB.yml | 7 ++++ config/locales/fr-CA.yml | 2 ++ config/locales/fr.yml | 4 ++- config/locales/nl.yml | 6 ++-- config/locales/simple_form.fr-CA.yml | 1 + config/locales/simple_form.fr.yml | 1 + 27 files changed, 199 insertions(+), 28 deletions(-) diff --git a/app/javascript/mastodon/locales/cy.json b/app/javascript/mastodon/locales/cy.json index 7e7bc25c9e..158f31aeb3 100644 --- a/app/javascript/mastodon/locales/cy.json +++ b/app/javascript/mastodon/locales/cy.json @@ -95,8 +95,10 @@ "block_modal.they_cant_see_posts": "Nid ydynt yn gallu gweld eich postiadau ac ni fyddwch yn gweld eu rhai hwy.", "block_modal.they_will_know": "Gallant weld eu bod wedi'u rhwystro.", "block_modal.title": "Blocio defnyddiwr?", - "block_modal.you_wont_see_mentions": "Ni welwch bostiadau sy'n sôn amdanynt.", + "block_modal.you_wont_see_mentions": "Fyddwch chi ddim yn gweld postiadau sy'n sôn amdanyn nhw.", "boost_modal.combo": "Mae modd pwyso {combo} er mwyn hepgor hyn tro nesa", + "boost_modal.reblog": "Hybu postiad", + "boost_modal.undo_reblog": "Dad-hybu postiad?", "bundle_column_error.copy_stacktrace": "Copïo'r adroddiad gwall", "bundle_column_error.error.body": "Nid oedd modd cynhyrchu'r dudalen honno. Gall fod oherwydd gwall yn ein cod neu fater cydnawsedd porwr.", "bundle_column_error.error.title": "O na!", @@ -145,7 +147,7 @@ "compose.language.search": "Chwilio ieithoedd...", "compose.published.body": "Postiad wedi ei gyhoeddi.", "compose.published.open": "Agor", - "compose.saved.body": "Post wedi'i gadw.", + "compose.saved.body": "Postiad wedi'i gadw.", "compose_form.direct_message_warning_learn_more": "Dysgu mwy", "compose_form.encryption_warning": "Dyw postiadau ar Mastodon ddim wedi'u hamgryptio o ben i ben. Peidiwch â rhannu unrhyw wybodaeth sensitif dros Mastodon.", "compose_form.hashtag_warning": "Ni fydd y postiad hwn wedi ei restru o dan unrhyw hashnod gan nad yw'n gyhoeddus. Dim ond postiadau cyhoeddus y mae modd eu chwilio drwy hashnod.", @@ -170,7 +172,7 @@ "confirmations.block.confirm": "Blocio", "confirmations.delete.confirm": "Dileu", "confirmations.delete.message": "Ydych chi'n sicr eich bod eisiau dileu y post hwn?", - "confirmations.delete.title": "Dileu post?", + "confirmations.delete.title": "Dileu postiad?", "confirmations.delete_list.confirm": "Dileu", "confirmations.delete_list.message": "Ydych chi'n siŵr eich bod eisiau dileu'r rhestr hwn am byth?", "confirmations.delete_list.title": "Dileu rhestr?", @@ -178,21 +180,21 @@ "confirmations.discard_edit_media.message": "Mae gennych newidiadau heb eu cadw i'r disgrifiad cyfryngau neu'r rhagolwg - eu dileu beth bynnag?", "confirmations.edit.confirm": "Golygu", "confirmations.edit.message": "Bydd golygu nawr yn trosysgrifennu'r neges rydych yn ei ysgrifennu ar hyn o bryd. Ydych chi'n siŵr eich bod eisiau gwneud hyn?", - "confirmations.edit.title": "Trosysgrifo post?", + "confirmations.edit.title": "Trosysgrifo'r postiad?", "confirmations.logout.confirm": "Allgofnodi", "confirmations.logout.message": "Ydych chi'n siŵr eich bod am allgofnodi?", "confirmations.logout.title": "Allgofnodi?", "confirmations.mute.confirm": "Tewi", "confirmations.redraft.confirm": "Dileu ac ailddrafftio", "confirmations.redraft.message": "Ydych chi wir eisiau'r dileu'r postiad hwn a'i ailddrafftio? Bydd ffefrynnau a hybiau'n cael eu colli, a bydd atebion i'r post gwreiddiol yn mynd yn amddifad.", - "confirmations.redraft.title": "Dileu & ailddraftio post?", + "confirmations.redraft.title": "Dileu & ailddraftio postiad?", "confirmations.reply.confirm": "Ateb", "confirmations.reply.message": "Bydd ateb nawr yn cymryd lle y neges yr ydych yn cyfansoddi ar hyn o bryd. Ydych chi'n siŵr eich bod am barhau?", - "confirmations.reply.title": "Trosysgrifo post?", + "confirmations.reply.title": "Trosysgrifo'r postiad?", "confirmations.unfollow.confirm": "Dad-ddilyn", "confirmations.unfollow.message": "Ydych chi'n siŵr eich bod am ddad-ddilyn {name}?", "confirmations.unfollow.title": "Dad-ddilyn defnyddiwr?", - "content_warning.hide": "Cuddio'r post", + "content_warning.hide": "Cuddio'r postiad", "content_warning.show": "Dangos beth bynnag", "conversation.delete": "Dileu sgwrs", "conversation.mark_as_read": "Nodi fel wedi'i ddarllen", @@ -256,7 +258,7 @@ "empty_column.account_timeline": "Dim postiadau yma!", "empty_column.account_unavailable": "Nid yw'r proffil ar gael", "empty_column.blocks": "Nid ydych wedi blocio unrhyw ddefnyddwyr eto.", - "empty_column.bookmarked_statuses": "Nid oes gennych unrhyw bostiad wedi'u cadw fel llyfrnodau eto. Pan fyddwch yn gosod nod tudalen i un, mi fydd yn ymddangos yma.", + "empty_column.bookmarked_statuses": "Nid oes gennych unrhyw bostiad wedi'u cadw fel nod tudalen eto. Pan fyddwch yn gosod nod tudalen i un, mi fydd yn ymddangos yma.", "empty_column.community": "Mae'r ffrwd lleol yn wag. Beth am ysgrifennu rhywbeth cyhoeddus!", "empty_column.direct": "Nid oes gennych unrhyw grybwylliadau preifat eto. Pan fyddwch chi'n anfon neu'n derbyn un, bydd yn ymddangos yma.", "empty_column.domain_blocks": "Nid oes unrhyw barthau wedi'u blocio eto.", @@ -351,9 +353,13 @@ "hashtag.follow": "Dilyn hashnod", "hashtag.unfollow": "Dad-ddilyn hashnod", "hashtags.and_other": "…a {count, plural, other {# more}}", + "hints.profiles.followers_may_be_missing": "Mae'n bosibl bod dilynwyr y proffil hwn ar goll.", + "hints.profiles.follows_may_be_missing": "Mae'n bosibl bod dilynwyr y proffil hwn ar goll.", + "hints.profiles.posts_may_be_missing": "Mae'n bosibl bod rhai postiadau y proffil hwn ar goll.", "hints.profiles.see_more_followers": "Gweld mwy o ddilynwyr ar {domain}", "hints.profiles.see_more_follows": "Gweld mwy o 'yn dilyn' ar {domain}", "hints.profiles.see_more_posts": "Gweld mwy o bostiadau ar {domain}", + "hints.threads.replies_may_be_missing": "Mae'n bosibl y bydd atebion gan weinyddion eraill ar goll.", "hints.threads.see_more": "Gweld mwy o atebion ar {domain}", "home.column_settings.show_reblogs": "Dangos hybiau", "home.column_settings.show_replies": "Dangos atebion", @@ -434,7 +440,7 @@ "limited_account_hint.title": "Mae'r proffil hwn wedi cael ei guddio gan gymedrolwyr {domain}.", "link_preview.author": "Gan {name}", "link_preview.more_from_author": "Mwy gan {name}", - "link_preview.shares": "{count, plural, one {{counter} post} two {{counter} bost} few {{counter} phost} many {{counter} post} other {{counter} post}}", + "link_preview.shares": "{count, plural, one {{counter} ostiad } two {{counter} bostiad } few {{counter} postiad} many {{counter} postiad} other {{counter} postiad}}", "lists.account.add": "Ychwanegu at restr", "lists.account.remove": "Tynnu o'r rhestr", "lists.delete": "Dileu rhestr", @@ -463,6 +469,7 @@ "mute_modal.you_wont_see_mentions": "Welwch chi ddim postiadau sy'n sôn amdanyn nhw.", "mute_modal.you_wont_see_posts": "Gallan nhw weld eich postiadau o hyd, ond fyddwch chi ddim yn gweld eu rhai hwy.", "navigation_bar.about": "Ynghylch", + "navigation_bar.administration": "Gweinyddiaeth", "navigation_bar.advanced_interface": "Agor mewn rhyngwyneb gwe uwch", "navigation_bar.blocks": "Defnyddwyr wedi eu blocio", "navigation_bar.bookmarks": "Nodau Tudalen", @@ -479,6 +486,7 @@ "navigation_bar.follows_and_followers": "Yn dilyn a dilynwyr", "navigation_bar.lists": "Rhestrau", "navigation_bar.logout": "Allgofnodi", + "navigation_bar.moderation": "Cymedroil", "navigation_bar.mutes": "Defnyddwyr wedi'u tewi", "navigation_bar.opened_in_classic_interface": "Mae postiadau, cyfrifon a thudalennau penodol eraill yn cael eu hagor fel rhagosodiad yn y rhyngwyneb gwe clasurol.", "navigation_bar.personal": "Personol", @@ -489,8 +497,8 @@ "navigation_bar.security": "Diogelwch", "not_signed_in_indicator.not_signed_in": "Rhaid i chi fewngofnodi i weld yr adnodd hwn.", "notification.admin.report": "Adroddwyd ar {name} {target}", - "notification.admin.report_account": "{name} reported {count, plural, one {un post} other {# postsiadau}} from {target} for {category}", - "notification.admin.report_account_other": "Adroddodd {name} {count, plural, one {un post} two {# bost} few {# phost} other {# post}} gan {target}", + "notification.admin.report_account": "{name} reported {count, plural, one {un postiad} other {# postiad}} from {target} for {category}", + "notification.admin.report_account_other": "Adroddodd {name} {count, plural, one {un postiad} two {# bostiad} few {# phost} other {# postiad}} gan {target}", "notification.admin.report_statuses": "Adroddodd {name} {target} ar gyfer {category}", "notification.admin.report_statuses_other": "Adroddodd {name} {target}", "notification.admin.sign_up": "Cofrestrodd {name}", @@ -498,7 +506,9 @@ "notification.favourite": "Ffafriodd {name} eich postiad", "notification.favourite.name_and_others_with_link": "Ffafriodd {name} a {count, plural, one {# arall} other {# eraill}} eich postiad", "notification.follow": "Dilynodd {name} chi", + "notification.follow.name_and_others": "Mae {name} a {count, plural, one {# other} other {# others}} wedi'ch dilyn chi", "notification.follow_request": "Mae {name} wedi gwneud cais i'ch dilyn", + "notification.follow_request.name_and_others": "Mae {name} a{count, plural, one {# other} other {# others}} wedi gofyn i'ch dilyn chi", "notification.label.mention": "Crybwyll", "notification.label.private_mention": "Crybwyll preifat", "notification.label.private_reply": "Ateb preifat", @@ -516,6 +526,7 @@ "notification.own_poll": "Mae eich pleidlais wedi dod i ben", "notification.poll": "Mae arolwg y gwnaethoch bleidleisio ynddo wedi dod i ben", "notification.reblog": "Hybodd {name} eich post", + "notification.reblog.name_and_others_with_link": "Mae {name} a {count, plural, one {# other} other {# others}} wedi hybu eich postiad", "notification.relationships_severance_event": "Wedi colli cysylltiad â {name}", "notification.relationships_severance_event.account_suspension": "Mae gweinyddwr o {from} wedi atal {target}, sy'n golygu na allwch dderbyn diweddariadau ganddynt mwyach na rhyngweithio â nhw.", "notification.relationships_severance_event.domain_block": "Mae gweinyddwr o {from} wedi blocio {target}, gan gynnwys {followersCount} o'ch dilynwyr a {followingCount, plural, one {# cyfrif} other {# cyfrif}} arall rydych chi'n ei ddilyn.", @@ -524,8 +535,12 @@ "notification.status": "{name} newydd ei bostio", "notification.update": "Golygodd {name} bostiad", "notification_requests.accept": "Derbyn", + "notification_requests.accept_multiple": "{count, plural, one {Accept # request…} other {Accept # requests…}}", + "notification_requests.confirm_accept_multiple.button": "{count, plural, one {Accept request} other {Accept requests}}", + "notification_requests.confirm_accept_multiple.message": "Rydych ar fin derbyn {count, plural, one {one notification request} other {# notification requests}}. Ydych chi'n siŵr eich bod am barhau?", "notification_requests.confirm_accept_multiple.title": "Derbyn ceisiadau hysbysu?", "notification_requests.confirm_dismiss_multiple.button": "{count, plural, one {Diystyru cais} other {Diystyru ceisiadau}}", + "notification_requests.confirm_dismiss_multiple.message": "Rydych ar fin diystyru {count, plural, one {un cais hysbysu} other {# cais hysbysiad}}. Fyddwch chi ddim yn gallu cyrchu {count, plural, one {it} other {them}} yn hawdd eto. Ydych chi'n yn siŵr eich bod am fwrw ymlaen?", "notification_requests.confirm_dismiss_multiple.title": "Diystyru ceisiadau hysbysu?", "notification_requests.dismiss": "Cau", "notification_requests.dismiss_multiple": "{count, plural, one {Diystyru # cais…} two {Diystyru # gais…} few {Diystyru # chais…} other {Diystyru # cais…}}", @@ -646,7 +661,7 @@ "poll_button.add_poll": "Ychwanegu pleidlais", "poll_button.remove_poll": "Tynnu pleidlais", "privacy.change": "Addasu preifatrwdd y post", - "privacy.direct.long": "Pawb sydd â son amdanyn nhw yn y postiad", + "privacy.direct.long": "Pawb sydd â sôn amdanyn nhw yn y postiad", "privacy.direct.short": "Pobl benodol", "privacy.private.long": "Eich dilynwyr yn unig", "privacy.private.short": "Dilynwyr", diff --git a/app/javascript/mastodon/locales/da.json b/app/javascript/mastodon/locales/da.json index a791ec75e0..732e4a100e 100644 --- a/app/javascript/mastodon/locales/da.json +++ b/app/javascript/mastodon/locales/da.json @@ -97,6 +97,8 @@ "block_modal.title": "Blokér bruger?", "block_modal.you_wont_see_mentions": "Du vil ikke se indlæg, som nævner vedkommende.", "boost_modal.combo": "Du kan trykke {combo} for at springe dette over næste gang", + "boost_modal.reblog": "Boost indlæg?", + "boost_modal.undo_reblog": "Fjern boost af indlæg?", "bundle_column_error.copy_stacktrace": "Kopiér fejlrapport", "bundle_column_error.error.body": "Den anmodede side kunne ikke gengives. Dette kan skyldes flere typer fejl.", "bundle_column_error.error.title": "Åh nej!", @@ -467,6 +469,7 @@ "mute_modal.you_wont_see_mentions": "Indlæg, som nævner vedkommende, vises ikke.", "mute_modal.you_wont_see_posts": "Vedkommende kan stadig se dine indlæg, med vedkommendes vise ikke.", "navigation_bar.about": "Om", + "navigation_bar.administration": "Håndtering", "navigation_bar.advanced_interface": "Åbn i avanceret webgrænseflade", "navigation_bar.blocks": "Blokerede brugere", "navigation_bar.bookmarks": "Bogmærker", @@ -483,6 +486,7 @@ "navigation_bar.follows_and_followers": "Følges og følgere", "navigation_bar.lists": "Lister", "navigation_bar.logout": "Log af", + "navigation_bar.moderation": "Moderering", "navigation_bar.mutes": "Skjulte brugere (mutede)", "navigation_bar.opened_in_classic_interface": "Indlæg, konti og visse andre sider åbnes som standard i den klassiske webgrænseflade.", "navigation_bar.personal": "Personlig", diff --git a/app/javascript/mastodon/locales/de.json b/app/javascript/mastodon/locales/de.json index 8e52cf1086..3c180f9f5c 100644 --- a/app/javascript/mastodon/locales/de.json +++ b/app/javascript/mastodon/locales/de.json @@ -355,11 +355,11 @@ "hashtags.and_other": "… und {count, plural, one{# weiterer} other {# weitere}}", "hints.profiles.followers_may_be_missing": "Möglicherweise werden für dieses Profil nicht alle Follower angezeigt.", "hints.profiles.follows_may_be_missing": "Möglicherweise werden für dieses Profil nicht alle gefolgten Profile angezeigt.", - "hints.profiles.posts_may_be_missing": "Möglicherweise werden für dieses Profil nicht alle Beiträge angezeigt.", + "hints.profiles.posts_may_be_missing": "Möglicherweise werden nicht alle Beiträge von diesem Profil angezeigt.", "hints.profiles.see_more_followers": "Weitere Follower auf {domain} ansehen", "hints.profiles.see_more_follows": "Weitere gefolgte Profile auf {domain} ansehen", "hints.profiles.see_more_posts": "Weitere Beiträge auf {domain} ansehen", - "hints.threads.replies_may_be_missing": "Möglicherweise werden für dieses Profil nicht alle Antworten angezeigt.", + "hints.threads.replies_may_be_missing": "Möglicherweise werden nicht alle Antworten von anderen Servern angezeigt.", "hints.threads.see_more": "Weitere Antworten auf {domain} ansehen", "home.column_settings.show_reblogs": "Geteilte Beiträge anzeigen", "home.column_settings.show_replies": "Antworten anzeigen", diff --git a/app/javascript/mastodon/locales/en-GB.json b/app/javascript/mastodon/locales/en-GB.json index ec0db40f77..e9007c8654 100644 --- a/app/javascript/mastodon/locales/en-GB.json +++ b/app/javascript/mastodon/locales/en-GB.json @@ -97,6 +97,8 @@ "block_modal.title": "Block user?", "block_modal.you_wont_see_mentions": "You won't see posts that mention them.", "boost_modal.combo": "You can press {combo} to skip this next time", + "boost_modal.reblog": "Boost post?", + "boost_modal.undo_reblog": "Unboost post?", "bundle_column_error.copy_stacktrace": "Copy error report", "bundle_column_error.error.body": "The requested page could not be rendered. It could be due to a bug in our code, or a browser compatibility issue.", "bundle_column_error.error.title": "Oh, no!", @@ -192,6 +194,8 @@ "confirmations.unfollow.confirm": "Unfollow", "confirmations.unfollow.message": "Are you sure you want to unfollow {name}?", "confirmations.unfollow.title": "Unfollow user?", + "content_warning.hide": "Hide post", + "content_warning.show": "Show anyway", "conversation.delete": "Delete conversation", "conversation.mark_as_read": "Mark as read", "conversation.open": "View conversation", @@ -299,6 +303,7 @@ "filter_modal.select_filter.subtitle": "Use an existing category or create a new one", "filter_modal.select_filter.title": "Filter this post", "filter_modal.title.status": "Filter a post", + "filter_warning.matches_filter": "Matches filter “{title}”", "filtered_notifications_banner.pending_requests": "From {count, plural, =0 {no one} one {one person} other {# people}} you may know", "filtered_notifications_banner.title": "Filtered notifications", "firehose.all": "All", @@ -464,6 +469,7 @@ "mute_modal.you_wont_see_mentions": "You won't see posts that mention them.", "mute_modal.you_wont_see_posts": "They can still see your posts, but you won't see theirs.", "navigation_bar.about": "About", + "navigation_bar.administration": "Administration", "navigation_bar.advanced_interface": "Open in advanced web interface", "navigation_bar.blocks": "Blocked users", "navigation_bar.bookmarks": "Bookmarks", @@ -480,6 +486,7 @@ "navigation_bar.follows_and_followers": "Follows and followers", "navigation_bar.lists": "Lists", "navigation_bar.logout": "Logout", + "navigation_bar.moderation": "Moderation", "navigation_bar.mutes": "Muted users", "navigation_bar.opened_in_classic_interface": "Posts, accounts, and other specific pages are opened by default in the classic web interface.", "navigation_bar.personal": "Personal", diff --git a/app/javascript/mastodon/locales/fo.json b/app/javascript/mastodon/locales/fo.json index 576cacef4e..d4e5d9ad54 100644 --- a/app/javascript/mastodon/locales/fo.json +++ b/app/javascript/mastodon/locales/fo.json @@ -97,6 +97,8 @@ "block_modal.title": "Banna brúkara?", "block_modal.you_wont_see_mentions": "Tú sært ikki postar, sum nevna tey.", "boost_modal.combo": "Tú kanst trýsta á {combo} fyri at loypa uppum hetta næstu ferð", + "boost_modal.reblog": "Stimbra post?", + "boost_modal.undo_reblog": "Strika stimbran av posti?", "bundle_column_error.copy_stacktrace": "Avrita feilfráboðan", "bundle_column_error.error.body": "Umbidna síðan kann ikki vísast. Tað kann vera orsakað av einum feili í koduni hjá okkum ella tað kann vera orsakað av kaganum, sum tú brúkar.", "bundle_column_error.error.title": "Áh, nei!", @@ -467,6 +469,7 @@ "mute_modal.you_wont_see_mentions": "Tú sært ikki postar, sum nevna tey.", "mute_modal.you_wont_see_posts": "Tey síggja framvegis tínar postar, men tú sært ikki teirra.", "navigation_bar.about": "Um", + "navigation_bar.administration": "Umsiting", "navigation_bar.advanced_interface": "Lat upp í framkomnum vevmarkamóti", "navigation_bar.blocks": "Bannaðir brúkarar", "navigation_bar.bookmarks": "Goymd", @@ -483,6 +486,7 @@ "navigation_bar.follows_and_followers": "Fylgd og fylgjarar", "navigation_bar.lists": "Listar", "navigation_bar.logout": "Rita út", + "navigation_bar.moderation": "Umsjón", "navigation_bar.mutes": "Doyvdir brúkarar", "navigation_bar.opened_in_classic_interface": "Postar, kontur og aðrar serstakar síður verða - um ikki annað er ásett - latnar upp í klassiska vev-markamótinum.", "navigation_bar.personal": "Persónligt", diff --git a/app/javascript/mastodon/locales/fr-CA.json b/app/javascript/mastodon/locales/fr-CA.json index 1a2a16f1f9..2961285267 100644 --- a/app/javascript/mastodon/locales/fr-CA.json +++ b/app/javascript/mastodon/locales/fr-CA.json @@ -96,6 +96,7 @@ "block_modal.title": "Bloquer l'utilisateur·rice ?", "block_modal.you_wont_see_mentions": "Vous ne verrez pas les publications qui le mentionne.", "boost_modal.combo": "Vous pouvez appuyer sur {combo} pour sauter ceci la prochaine fois", + "boost_modal.reblog": "Booster le message ?", "bundle_column_error.copy_stacktrace": "Copier le rapport d'erreur", "bundle_column_error.error.body": "La page demandée n'a pas pu être affichée. Cela pourrait être dû à un bogue dans notre code, ou à un problème de compatibilité avec le navigateur.", "bundle_column_error.error.title": "Oh non!", @@ -310,6 +311,7 @@ "follow_requests.unlocked_explanation": "Même si votre compte n’est pas privé, l’équipe de {domain} a pensé que vous pourriez vouloir peut-être consulter manuellement les demandes d'abonnement de ces comptes.", "follow_suggestions.curated_suggestion": "Choix du staff", "follow_suggestions.dismiss": "Ne plus afficher", + "follow_suggestions.featured_longer": "Sélectionné par l'équipe de {domain}", "follow_suggestions.friends_of_friends_longer": "Populaire dans le cercle des personnes que vous suivez", "follow_suggestions.hints.featured": "Ce profil a été sélectionné par l'équipe de {domain}.", "follow_suggestions.hints.friends_of_friends": "Ce profil est populaire parmi les personnes que vous suivez.", @@ -358,6 +360,17 @@ "home.pending_critical_update.link": "Voir les mises à jour", "home.pending_critical_update.title": "Une mise à jour de sécurité critique est disponible !", "home.show_announcements": "Afficher annonces", + "ignore_notifications_modal.disclaimer": "Mastodon ne peut pas indiquer aux utilisateurs que vous avez ignoré leurs notifications. Le fait d'ignorer les notifications n'empêchera pas la transmission des messages eux-mêmes.", + "ignore_notifications_modal.filter_instead": "Filtrer plutôt", + "ignore_notifications_modal.filter_to_act_users": "Vous serez toujours en mesure d'accepter, de rejeter ou de signaler les utilisateur·rice·s", + "ignore_notifications_modal.filter_to_avoid_confusion": "Le filtrage permet d'éviter toute éventuelle confusion", + "ignore_notifications_modal.filter_to_review_separately": "Vous pouvez réexaminer les notifications filtrées séparément", + "ignore_notifications_modal.ignore": "Ignorer les notifications", + "ignore_notifications_modal.limited_accounts_title": "Ignorer les notifications provenant des comptes modérés ?", + "ignore_notifications_modal.new_accounts_title": "Ignorer les notifications provenant des nouveaux comptes ?", + "ignore_notifications_modal.not_followers_title": "Ignorer les notifications provenant des personnes qui ne vous suivent pas ?", + "ignore_notifications_modal.not_following_title": "Ignorer les notifications provenant des personnes que vous ne suivez pas ?", + "ignore_notifications_modal.private_mentions_title": "Ignorer les notifications issues des mentions privées non sollicitées ?", "interaction_modal.description.favourite": "Avec un compte Mastodon, vous pouvez ajouter cette publication à vos favoris pour informer l'auteur⋅rice que vous l'appréciez et la sauvegarder pour plus tard.", "interaction_modal.description.follow": "Avec un compte Mastodon, vous pouvez suivre {name} et recevoir leurs publications dans votre fil d'accueil.", "interaction_modal.description.reblog": "Avec un compte Mastodon, vous pouvez booster cette publication pour la partager avec vos propres abonné·e·s.", @@ -448,6 +461,7 @@ "mute_modal.you_wont_see_mentions": "Vous ne verrez pas les publications qui le mentionne.", "mute_modal.you_wont_see_posts": "Il peut toujours voir vos publications, mais vous ne verrez pas les siennes.", "navigation_bar.about": "À propos", + "navigation_bar.administration": "Administration", "navigation_bar.advanced_interface": "Ouvrir dans l’interface avancée", "navigation_bar.blocks": "Comptes bloqués", "navigation_bar.bookmarks": "Signets", @@ -464,6 +478,7 @@ "navigation_bar.follows_and_followers": "Abonnements et abonnés", "navigation_bar.lists": "Listes", "navigation_bar.logout": "Se déconnecter", + "navigation_bar.moderation": "Modération", "navigation_bar.mutes": "Utilisateurs masqués", "navigation_bar.opened_in_classic_interface": "Les messages, les comptes et les pages spécifiques sont ouvertes dans l’interface classique.", "navigation_bar.personal": "Personnel", @@ -474,14 +489,23 @@ "navigation_bar.security": "Sécurité", "not_signed_in_indicator.not_signed_in": "Vous devez vous connecter pour accéder à cette ressource.", "notification.admin.report": "{name} a signalé {target}", + "notification.admin.report_account": "{name} a signalé {count, plural, one {un message} other {# messages}} de {target} pour {category}", + "notification.admin.report_account_other": "{name} a signalé {count, plural, one {un message} other {# messages}} depuis {target}", + "notification.admin.report_statuses": "{name} a signalé {target} pour {category}", + "notification.admin.report_statuses_other": "{name} a signalé {target}", "notification.admin.sign_up": "{name} s'est inscrit·e", + "notification.admin.sign_up.name_and_others": "{name} et {count, plural, one {# autre} other {# autres}} se sont inscrit", "notification.favourite": "{name} a ajouté votre publication à ses favoris", + "notification.favourite.name_and_others_with_link": "{name} et {count, plural, one {# autre} other {# autres}} ont mis votre message en favori", "notification.follow": "{name} vous suit", + "notification.follow.name_and_others": "{name} et {count, plural, one {# autre} other {# autres}} se sont abonné à votre compte", "notification.follow_request": "{name} a demandé à vous suivre", + "notification.follow_request.name_and_others": "{name} et {count, plural, one {# autre} other {# autres}} ont demandé à vous suivre", "notification.label.mention": "Mention", "notification.label.private_mention": "Mention privée", "notification.label.private_reply": "Répondre en privé", "notification.label.reply": "Réponse", + "notification.mention": "Mention", "notification.moderation-warning.learn_more": "En savoir plus", "notification.moderation_warning": "Vous avez reçu un avertissement de modération", "notification.moderation_warning.action_delete_statuses": "Certains de vos messages ont été supprimés.", @@ -494,6 +518,7 @@ "notification.own_poll": "Votre sondage est terminé", "notification.poll": "Un sondage auquel vous avez participé vient de se terminer", "notification.reblog": "{name} a boosté votre message", + "notification.reblog.name_and_others_with_link": "{name} et {count, plural, one {# autre} other {# autres}} ont boosté votre message", "notification.relationships_severance_event": "Connexions perdues avec {name}", "notification.relationships_severance_event.account_suspension": "Un·e administrateur·rice de {from} a suspendu {target}, ce qui signifie que vous ne pourrez plus recevoir de mises à jour ou interagir avec lui.", "notification.relationships_severance_event.domain_block": "Un·e administrateur·rice de {from} en a bloqué {target}, comprenant {followersCount} de vos abonné·e·s et {followingCount, plural, one {# compte} other {# comptes}} vous suivez.", @@ -505,8 +530,13 @@ "notification_requests.dismiss": "Rejeter", "notification_requests.edit_selection": "Modifier", "notification_requests.exit_selection": "Fait", + "notification_requests.explainer_for_limited_account": "Les notifications en provenance de ce compte ont été filtrées car le compte a été limité par un modérateur.", + "notification_requests.explainer_for_limited_remote_account": "Les notifications en provenance de ce compte ont été filtrées car le compte ou le serveur dont il est issu a été limité par un modérateur.", + "notification_requests.maximize": "Agrandir", + "notification_requests.minimize_banner": "Réduire la bannière des notifications filtrées", "notification_requests.notifications_from": "Notifications de {name}", "notification_requests.title": "Notifications filtrées", + "notification_requests.view": "Afficher les notifications", "notifications.clear": "Effacer notifications", "notifications.clear_confirmation": "Voulez-vous vraiment effacer toutes vos notifications?", "notifications.clear_title": "Effacer les notifications ?", @@ -548,7 +578,8 @@ "notifications.policy.drop": "Ignorer", "notifications.policy.drop_hint": "Expulser vers le vide, pour ne plus jamais les revoir", "notifications.policy.filter": "Filtrer", - "notifications.policy.filter_limited_accounts_hint": "Limité par les modérateur·rice·s du serveur", + "notifications.policy.filter_hint": "Envoyer à la boîte de réception des notifications filtrées", + "notifications.policy.filter_limited_accounts_hint": "Limités par les modérateur·rice·s du serveur", "notifications.policy.filter_limited_accounts_title": "Comptes modérés", "notifications.policy.filter_new_accounts.hint": "Créés au cours des derniers {days, plural, one {un jour} other {# jours}}", "notifications.policy.filter_new_accounts_title": "Nouveaux comptes", @@ -556,8 +587,9 @@ "notifications.policy.filter_not_followers_title": "Personnes qui ne vous suivent pas", "notifications.policy.filter_not_following_hint": "Jusqu'à ce que vous les validiez manuellement", "notifications.policy.filter_not_following_title": "Personnes que vous ne suivez pas", - "notifications.policy.filter_private_mentions_hint": "Filtré sauf si c'est en réponse à une mention de vous ou si vous suivez l'expéditeur", + "notifications.policy.filter_private_mentions_hint": "Filtrées sauf si c'est en réponse à l'une de vos mentions ou si vous suivez l'expéditeur·ice", "notifications.policy.filter_private_mentions_title": "Mentions privées non sollicitées", + "notifications.policy.title": "Gérer les notifications en provenance de …", "notifications_permission_banner.enable": "Activer les notifications de bureau", "notifications_permission_banner.how_to_control": "Pour recevoir des notifications lorsque Mastodon n’est pas ouvert, activez les notifications de bureau. Vous pouvez contrôler précisément quels types d’interactions génèrent des notifications de bureau via le bouton {icon} ci-dessus une fois qu’elles sont activées.", "notifications_permission_banner.title": "Ne rien rater", @@ -721,6 +753,7 @@ "server_banner.is_one_of_many": "{domain} est l'un des nombreux serveurs Mastodon indépendants que vous pouvez utiliser pour participer au fédiverse.", "server_banner.server_stats": "Statistiques du serveur:", "sign_in_banner.create_account": "Créer un compte", + "sign_in_banner.follow_anyone": "Suivez n'importe qui à travers le fédivers et affichez tout dans un ordre chronologique. Ni algorithmes, ni publicités, ni appâts à clics en perspective.", "sign_in_banner.mastodon_is": "Mastodon est le meilleur moyen de suivre ce qui se passe.", "sign_in_banner.sign_in": "Se connecter", "sign_in_banner.sso_redirect": "Se connecter ou s’inscrire", diff --git a/app/javascript/mastodon/locales/fr.json b/app/javascript/mastodon/locales/fr.json index 99592372cb..970103db83 100644 --- a/app/javascript/mastodon/locales/fr.json +++ b/app/javascript/mastodon/locales/fr.json @@ -96,6 +96,7 @@ "block_modal.title": "Bloquer l'utilisateur·rice ?", "block_modal.you_wont_see_mentions": "Vous ne verrez pas les publications qui le mentionne.", "boost_modal.combo": "Vous pouvez appuyer sur {combo} pour passer ceci la prochaine fois", + "boost_modal.reblog": "Booster le message ?", "bundle_column_error.copy_stacktrace": "Copier le rapport d'erreur", "bundle_column_error.error.body": "La page demandée n'a pas pu être affichée. Cela peut être dû à un bogue dans notre code, ou à un problème de compatibilité avec le navigateur.", "bundle_column_error.error.title": "Oh non !", @@ -288,7 +289,7 @@ "filter_modal.added.context_mismatch_title": "Incompatibilité du contexte !", "filter_modal.added.expired_explanation": "Cette catégorie de filtre a expiré, vous devrez modifier la date d'expiration pour qu'elle soit appliquée.", "filter_modal.added.expired_title": "Filtre expiré !", - "filter_modal.added.review_and_configure": "Pour examiner et affiner la configuration de cette catégorie de filtre, allez à {settings_link}.", + "filter_modal.added.review_and_configure": "Pour examiner et affiner la configuration de cette catégorie de filtres, allez à {settings_link}.", "filter_modal.added.review_and_configure_title": "Paramètres du filtre", "filter_modal.added.settings_link": "page des paramètres", "filter_modal.added.short_explanation": "Ce message a été ajouté à la catégorie de filtre suivante : {title}.", @@ -297,7 +298,7 @@ "filter_modal.select_filter.expired": "a expiré", "filter_modal.select_filter.prompt_new": "Nouvelle catégorie : {name}", "filter_modal.select_filter.search": "Rechercher ou créer", - "filter_modal.select_filter.subtitle": "Utilisez une catégorie existante ou en créer une nouvelle", + "filter_modal.select_filter.subtitle": "Utilisez une catégorie existante ou créez-en une nouvelle", "filter_modal.select_filter.title": "Filtrer ce message", "filter_modal.title.status": "Filtrer un message", "filter_warning.matches_filter": "Correspond au filtre « {title} »", @@ -310,6 +311,7 @@ "follow_requests.unlocked_explanation": "Même si votre compte n’est pas privé, l’équipe de {domain} a pensé que vous pourriez vouloir consulter manuellement les demandes de suivi de ces comptes.", "follow_suggestions.curated_suggestion": "Choix du staff", "follow_suggestions.dismiss": "Ne plus afficher", + "follow_suggestions.featured_longer": "Sélectionné par l'équipe de {domain}", "follow_suggestions.friends_of_friends_longer": "Populaire dans le cercle des personnes que vous suivez", "follow_suggestions.hints.featured": "Ce profil a été sélectionné par l'équipe de {domain}.", "follow_suggestions.hints.friends_of_friends": "Ce profil est populaire parmi les personnes que vous suivez.", @@ -358,6 +360,17 @@ "home.pending_critical_update.link": "Voir les mises à jour", "home.pending_critical_update.title": "Une mise à jour de sécurité critique est disponible !", "home.show_announcements": "Afficher les annonces", + "ignore_notifications_modal.disclaimer": "Mastodon ne peut pas indiquer aux utilisateurs que vous avez ignoré leurs notifications. Le fait d'ignorer les notifications n'empêchera pas la transmission des messages eux-mêmes.", + "ignore_notifications_modal.filter_instead": "Filtrer plutôt", + "ignore_notifications_modal.filter_to_act_users": "Vous serez toujours en mesure d'accepter, de rejeter ou de signaler les utilisateur·rice·s", + "ignore_notifications_modal.filter_to_avoid_confusion": "Le filtrage permet d'éviter toute éventuelle confusion", + "ignore_notifications_modal.filter_to_review_separately": "Vous pouvez réexaminer les notifications filtrées séparément", + "ignore_notifications_modal.ignore": "Ignorer les notifications", + "ignore_notifications_modal.limited_accounts_title": "Ignorer les notifications provenant des comptes modérés ?", + "ignore_notifications_modal.new_accounts_title": "Ignorer les notifications provenant des nouveaux comptes ?", + "ignore_notifications_modal.not_followers_title": "Ignorer les notifications provenant des personnes qui ne vous suivent pas ?", + "ignore_notifications_modal.not_following_title": "Ignorer les notifications provenant des personnes que vous ne suivez pas ?", + "ignore_notifications_modal.private_mentions_title": "Ignorer les notifications issues des mentions privées non sollicitées ?", "interaction_modal.description.favourite": "Avec un compte Mastodon, vous pouvez ajouter ce message à vos favoris pour informer l'auteur⋅rice que vous l'appréciez et pour le sauvegarder pour plus tard.", "interaction_modal.description.follow": "Avec un compte Mastodon, vous pouvez suivre {name} et recevoir leurs posts dans votre fil d'actualité.", "interaction_modal.description.reblog": "Avec un compte sur Mastodon, vous pouvez partager ce message pour le faire découvrir à vos propres abonné⋅e⋅s.", @@ -448,6 +461,7 @@ "mute_modal.you_wont_see_mentions": "Vous ne verrez pas les publications qui le mentionne.", "mute_modal.you_wont_see_posts": "Il peut toujours voir vos publications, mais vous ne verrez pas les siennes.", "navigation_bar.about": "À propos", + "navigation_bar.administration": "Administration", "navigation_bar.advanced_interface": "Ouvrir dans l’interface avancée", "navigation_bar.blocks": "Comptes bloqués", "navigation_bar.bookmarks": "Marque-pages", @@ -464,6 +478,7 @@ "navigation_bar.follows_and_followers": "Abonnements et abonnés", "navigation_bar.lists": "Listes", "navigation_bar.logout": "Déconnexion", + "navigation_bar.moderation": "Modération", "navigation_bar.mutes": "Comptes masqués", "navigation_bar.opened_in_classic_interface": "Les messages, les comptes et les pages spécifiques sont ouvertes dans l’interface classique.", "navigation_bar.personal": "Personnel", @@ -474,14 +489,23 @@ "navigation_bar.security": "Sécurité", "not_signed_in_indicator.not_signed_in": "Vous devez vous connecter pour accéder à cette ressource.", "notification.admin.report": "{name} a signalé {target}", + "notification.admin.report_account": "{name} a signalé {count, plural, one {un message} other {# messages}} de {target} pour {category}", + "notification.admin.report_account_other": "{name} a signalé {count, plural, one {un message} other {# messages}} depuis {target}", + "notification.admin.report_statuses": "{name} a signalé {target} pour {category}", + "notification.admin.report_statuses_other": "{name} a signalé {target}", "notification.admin.sign_up": "{name} s'est inscrit", + "notification.admin.sign_up.name_and_others": "{name} et {count, plural, one {# autre} other {# autres}} se sont inscrit", "notification.favourite": "{name} a ajouté votre message à ses favoris", + "notification.favourite.name_and_others_with_link": "{name} et {count, plural, one {# autre} other {# autres}} ont mis votre message en favori", "notification.follow": "{name} vous suit", + "notification.follow.name_and_others": "{name} et {count, plural, one {# autre} other {# autres}} se sont abonné à votre compte", "notification.follow_request": "{name} a demandé à vous suivre", + "notification.follow_request.name_and_others": "{name} et {count, plural, one {# autre} other {# autres}} ont demandé à vous suivre", "notification.label.mention": "Mention", "notification.label.private_mention": "Mention privée", "notification.label.private_reply": "Répondre en privé", "notification.label.reply": "Réponse", + "notification.mention": "Mention", "notification.moderation-warning.learn_more": "En savoir plus", "notification.moderation_warning": "Vous avez reçu un avertissement de modération", "notification.moderation_warning.action_delete_statuses": "Certains de vos messages ont été supprimés.", @@ -494,6 +518,7 @@ "notification.own_poll": "Votre sondage est terminé", "notification.poll": "Un sondage auquel vous avez participé vient de se terminer", "notification.reblog": "{name} a partagé votre message", + "notification.reblog.name_and_others_with_link": "{name} et {count, plural, one {# autre} other {# autres}} ont boosté votre message", "notification.relationships_severance_event": "Connexions perdues avec {name}", "notification.relationships_severance_event.account_suspension": "Un·e administrateur·rice de {from} a suspendu {target}, ce qui signifie que vous ne pourrez plus recevoir de mises à jour ou interagir avec lui.", "notification.relationships_severance_event.domain_block": "Un·e administrateur·rice de {from} en a bloqué {target}, comprenant {followersCount} de vos abonné·e·s et {followingCount, plural, one {# compte} other {# comptes}} vous suivez.", @@ -505,8 +530,13 @@ "notification_requests.dismiss": "Rejeter", "notification_requests.edit_selection": "Modifier", "notification_requests.exit_selection": "Fait", + "notification_requests.explainer_for_limited_account": "Les notifications en provenance de ce compte ont été filtrées car le compte a été limité par un modérateur.", + "notification_requests.explainer_for_limited_remote_account": "Les notifications en provenance de ce compte ont été filtrées car le compte ou le serveur dont il est issu a été limité par un modérateur.", + "notification_requests.maximize": "Agrandir", + "notification_requests.minimize_banner": "Réduire la bannière des notifications filtrées", "notification_requests.notifications_from": "Notifications de {name}", "notification_requests.title": "Notifications filtrées", + "notification_requests.view": "Afficher les notifications", "notifications.clear": "Effacer les notifications", "notifications.clear_confirmation": "Voulez-vous vraiment effacer toutes vos notifications ?", "notifications.clear_title": "Effacer les notifications ?", @@ -548,7 +578,8 @@ "notifications.policy.drop": "Ignorer", "notifications.policy.drop_hint": "Expulser vers le vide, pour ne plus jamais les revoir", "notifications.policy.filter": "Filtrer", - "notifications.policy.filter_limited_accounts_hint": "Limité par les modérateur·rice·s du serveur", + "notifications.policy.filter_hint": "Envoyer à la boîte de réception des notifications filtrées", + "notifications.policy.filter_limited_accounts_hint": "Limités par les modérateur·rice·s du serveur", "notifications.policy.filter_limited_accounts_title": "Comptes modérés", "notifications.policy.filter_new_accounts.hint": "Créés au cours des derniers {days, plural, one {un jour} other {# jours}}", "notifications.policy.filter_new_accounts_title": "Nouveaux comptes", @@ -556,8 +587,9 @@ "notifications.policy.filter_not_followers_title": "Personnes qui ne vous suivent pas", "notifications.policy.filter_not_following_hint": "Jusqu'à ce que vous les validiez manuellement", "notifications.policy.filter_not_following_title": "Personnes que vous ne suivez pas", - "notifications.policy.filter_private_mentions_hint": "Filtré sauf si c'est en réponse à une mention de vous ou si vous suivez l'expéditeur", + "notifications.policy.filter_private_mentions_hint": "Filtrées sauf si c'est en réponse à l'une de vos mentions ou si vous suivez l'expéditeur·ice", "notifications.policy.filter_private_mentions_title": "Mentions privées non sollicitées", + "notifications.policy.title": "Gérer les notifications en provenance de …", "notifications_permission_banner.enable": "Activer les notifications de bureau", "notifications_permission_banner.how_to_control": "Pour recevoir des notifications lorsque Mastodon n’est pas ouvert, activez les notifications du bureau. Vous pouvez contrôler précisément quels types d’interactions génèrent des notifications de bureau via le bouton {icon} ci-dessus une fois qu’elles sont activées.", "notifications_permission_banner.title": "Toujours au courant", @@ -721,6 +753,7 @@ "server_banner.is_one_of_many": "{domain} est l'un des nombreux serveurs Mastodon indépendants que vous pouvez utiliser pour participer au fédiverse.", "server_banner.server_stats": "Statistiques du serveur :", "sign_in_banner.create_account": "Créer un compte", + "sign_in_banner.follow_anyone": "Suivez n'importe qui à travers le fédivers et affichez tout dans un ordre chronologique. Ni algorithmes, ni publicités, ni appâts à clics en perspective.", "sign_in_banner.mastodon_is": "Mastodon est le meilleur moyen de suivre ce qui se passe.", "sign_in_banner.sign_in": "Se connecter", "sign_in_banner.sso_redirect": "Se connecter ou s’inscrire", diff --git a/app/javascript/mastodon/locales/he.json b/app/javascript/mastodon/locales/he.json index 3ccd951080..44c95d64c6 100644 --- a/app/javascript/mastodon/locales/he.json +++ b/app/javascript/mastodon/locales/he.json @@ -97,6 +97,8 @@ "block_modal.title": "לחסום משתמש?", "block_modal.you_wont_see_mentions": "לא תראה הודעות שמאזכרות אותם.", "boost_modal.combo": "ניתן להקיש {combo} כדי לדלג בפעם הבאה", + "boost_modal.reblog": "להדהד הודעה?", + "boost_modal.undo_reblog": "להסיר הדהוד?", "bundle_column_error.copy_stacktrace": "העתקת הודעת שגיאה", "bundle_column_error.error.body": "הדף המבוקש אינו זמין. זה עשוי להיות באג בקוד או בעייה בתאימות הדפדפן.", "bundle_column_error.error.title": "הו, לא!", @@ -467,6 +469,7 @@ "mute_modal.you_wont_see_mentions": "לא תראה הודעות שמאזכרות אותם.", "mute_modal.you_wont_see_posts": "הם יכולים לראות את הודעותכם, אבל אתם לא תוכלו לראות את שלהם.", "navigation_bar.about": "אודות", + "navigation_bar.administration": "ניהול", "navigation_bar.advanced_interface": "פתח במנשק ווב מתקדם", "navigation_bar.blocks": "משתמשים חסומים", "navigation_bar.bookmarks": "סימניות", @@ -483,6 +486,7 @@ "navigation_bar.follows_and_followers": "נעקבים ועוקבים", "navigation_bar.lists": "רשימות", "navigation_bar.logout": "התנתקות", + "navigation_bar.moderation": "פיקוח", "navigation_bar.mutes": "משתמשים בהשתקה", "navigation_bar.opened_in_classic_interface": "הודעות, חשבונות ושאר עמודי רשת יפתחו כברירת מחדל בדפדפן רשת קלאסי.", "navigation_bar.personal": "אישי", diff --git a/app/javascript/mastodon/locales/hu.json b/app/javascript/mastodon/locales/hu.json index b76b2e92cd..d55a85ee33 100644 --- a/app/javascript/mastodon/locales/hu.json +++ b/app/javascript/mastodon/locales/hu.json @@ -97,6 +97,8 @@ "block_modal.title": "Letiltsuk a felhasználót?", "block_modal.you_wont_see_mentions": "Nem látsz majd őt említő bejegyzéseket.", "boost_modal.combo": "Hogy átugord ezt következő alkalommal, használd {combo}", + "boost_modal.reblog": "Bejegyzés megtolása?", + "boost_modal.undo_reblog": "Megtolás visszavonása?", "bundle_column_error.copy_stacktrace": "Hibajelentés másolása", "bundle_column_error.error.body": "A kért lap nem jeleníthető meg. Ez lehet, hogy kódhiba, vagy böngészőkompatibitási hiba.", "bundle_column_error.error.title": "Jaj ne!", @@ -467,6 +469,7 @@ "mute_modal.you_wont_see_mentions": "Nem látsz majd őt említő bejegyzéseket.", "mute_modal.you_wont_see_posts": "Továbbra is látni fogja a bejegyzéseidet, de te nem fogod látni az övéit.", "navigation_bar.about": "Névjegy", + "navigation_bar.administration": "Adminisztráció", "navigation_bar.advanced_interface": "Megnyitás a speciális webes felületben", "navigation_bar.blocks": "Letiltott felhasználók", "navigation_bar.bookmarks": "Könyvjelzők", @@ -483,6 +486,7 @@ "navigation_bar.follows_and_followers": "Követések és követők", "navigation_bar.lists": "Listák", "navigation_bar.logout": "Kijelentkezés", + "navigation_bar.moderation": "Moderáció", "navigation_bar.mutes": "Némított felhasználók", "navigation_bar.opened_in_classic_interface": "A bejegyzések, fiókok és más speciális oldalak alapértelmezés szerint a klasszikus webes felületen nyílnak meg.", "navigation_bar.personal": "Személyes", diff --git a/app/javascript/mastodon/locales/ia.json b/app/javascript/mastodon/locales/ia.json index 2c3b04f998..31fb52552b 100644 --- a/app/javascript/mastodon/locales/ia.json +++ b/app/javascript/mastodon/locales/ia.json @@ -97,6 +97,7 @@ "block_modal.title": "Blocar usator?", "block_modal.you_wont_see_mentions": "Tu non videra le messages que mentiona iste persona.", "boost_modal.combo": "Tu pote premer {combo} pro saltar isto le proxime vice", + "boost_modal.reblog": "Impulsar le message?", "bundle_column_error.copy_stacktrace": "Copiar reporto de error", "bundle_column_error.error.body": "Le pagina requestate non pote esser visualisate. Pote esser a causa de un defecto in nostre codice o de un problema de compatibilitate del navigator.", "bundle_column_error.error.title": "Oh, no!", diff --git a/app/javascript/mastodon/locales/it.json b/app/javascript/mastodon/locales/it.json index 8e3082359e..46d1fdd7ab 100644 --- a/app/javascript/mastodon/locales/it.json +++ b/app/javascript/mastodon/locales/it.json @@ -97,6 +97,8 @@ "block_modal.title": "Bloccare l'utente?", "block_modal.you_wont_see_mentions": "Non vedrai i post che li menzionano.", "boost_modal.combo": "Puoi premere {combo} per saltare questo passaggio, la prossima volta", + "boost_modal.reblog": "Condividere il post?", + "boost_modal.undo_reblog": "Annullare la condivisione del post?", "bundle_column_error.copy_stacktrace": "Copia rapporto sull'errore", "bundle_column_error.error.body": "Impossibile rendedrizzare la pagina richiesta. Potrebbe dipendere da un bug nel nostro codice o da un problema di compatibilità di un browser.", "bundle_column_error.error.title": "Oh, no!", @@ -125,7 +127,7 @@ "column.firehose": "Feed dal vivo", "column.follow_requests": "Richieste di seguirti", "column.home": "Home", - "column.lists": "Elenchi", + "column.lists": "Liste", "column.mutes": "Utenti silenziati", "column.notifications": "Notifiche", "column.pins": "Post fissati", @@ -452,7 +454,7 @@ "lists.replies_policy.none": "Nessuno", "lists.replies_policy.title": "Mostra risposte a:", "lists.search": "Cerca tra le persone che segui", - "lists.subheading": "I tuoi elenchi", + "lists.subheading": "Le tue liste", "load_pending": "{count, plural, one {# nuovo oggetto} other {# nuovi oggetti}}", "loading_indicator.label": "Caricamento…", "media_gallery.toggle_visible": "{number, plural, one {Nascondi immagine} other {Nascondi immagini}}", @@ -467,6 +469,7 @@ "mute_modal.you_wont_see_mentions": "Non vedrai i post che li menzionano.", "mute_modal.you_wont_see_posts": "Possono ancora vedere i tuoi post, ma tu non vedrai i loro.", "navigation_bar.about": "Info", + "navigation_bar.administration": "Amministrazione", "navigation_bar.advanced_interface": "Apri nell'interfaccia web avanzata", "navigation_bar.blocks": "Utenti bloccati", "navigation_bar.bookmarks": "Segnalibri", @@ -483,6 +486,7 @@ "navigation_bar.follows_and_followers": "Seguiti e seguaci", "navigation_bar.lists": "Liste", "navigation_bar.logout": "Disconnettiti", + "navigation_bar.moderation": "Moderazione", "navigation_bar.mutes": "Utenti silenziati", "navigation_bar.opened_in_classic_interface": "Post, account e altre pagine specifiche sono aperti per impostazione predefinita nella classica interfaccia web.", "navigation_bar.personal": "Personale", diff --git a/app/javascript/mastodon/locales/ja.json b/app/javascript/mastodon/locales/ja.json index 8784c6d1a8..86ba4ad64d 100644 --- a/app/javascript/mastodon/locales/ja.json +++ b/app/javascript/mastodon/locales/ja.json @@ -351,6 +351,14 @@ "hashtag.follow": "ハッシュタグをフォローする", "hashtag.unfollow": "ハッシュタグのフォローを解除", "hashtags.and_other": "ほか{count, plural, other {#個}}", + "hints.profiles.followers_may_be_missing": "フォロワーの一覧は不正確な場合があります。", + "hints.profiles.follows_may_be_missing": "フォローの一覧は不正確な場合があります。", + "hints.profiles.posts_may_be_missing": "すべての投稿を表示できていない場合があります。", + "hints.profiles.see_more_followers": "{domain} で正確な情報を見る", + "hints.profiles.see_more_follows": "{domain} で正確な情報を見る", + "hints.profiles.see_more_posts": "{domain} でその他の投稿を見る", + "hints.threads.replies_may_be_missing": "リモートの返信は表示されない場合があります。", + "hints.threads.see_more": "{domain} でその他の返信を見る", "home.column_settings.show_reblogs": "ブースト表示", "home.column_settings.show_replies": "返信表示", "home.hide_announcements": "お知らせを隠す", @@ -358,6 +366,17 @@ "home.pending_critical_update.link": "詳細", "home.pending_critical_update.title": "緊急のセキュリティアップデートがあります", "home.show_announcements": "お知らせを表示", + "ignore_notifications_modal.disclaimer": "通知が無視されていることは通知の送信元の相手には伝わりません。通知が破棄されるのみで、投稿や返信の送信を止めさせる効果はありません。", + "ignore_notifications_modal.filter_instead": "「保留」に設定", + "ignore_notifications_modal.filter_to_act_users": "保留された通知は「受け入れ」「無視」を選択できます。当該ユーザーの通報も可能です", + "ignore_notifications_modal.filter_to_avoid_confusion": "通知の破棄による意図しない混乱を避けるためにも、「保留」設定の使用を検討してください", + "ignore_notifications_modal.filter_to_review_separately": "「保留」設定を使用することで、保留された通知を個別に確認できます", + "ignore_notifications_modal.ignore": "「無視」に設定", + "ignore_notifications_modal.limited_accounts_title": "本当に「モデレーションされたアカウントからの通知」を無視するようにしますか?", + "ignore_notifications_modal.new_accounts_title": "本当に「新しいアカウントからの通知」を無視するようにしますか?", + "ignore_notifications_modal.not_followers_title": "本当に「フォローされていないアカウントからの通知」を無視するようにしますか?", + "ignore_notifications_modal.not_following_title": "本当に「フォローしていないアカウントからの通知」を無視するようにしますか?", + "ignore_notifications_modal.private_mentions_title": "本当に「外部からの非公開の返信」を無視するようにしますか?", "interaction_modal.description.favourite": "Mastodonのアカウントがあれば投稿をお気に入り登録して投稿者に気持ちを伝えたり、あとで見返すことができます。", "interaction_modal.description.follow": "Mastodonのアカウントで{name}さんをフォローしてホームフィードで投稿を受け取れます。", "interaction_modal.description.reblog": "Mastodonのアカウントでこの投稿をブーストして自分のフォロワーに共有できます。", @@ -518,6 +537,7 @@ "notification_requests.minimize_banner": "「保留中の通知」のバナーを最小化する", "notification_requests.notifications_from": "{name}からの通知", "notification_requests.title": "保留中の通知", + "notification_requests.view": "通知を確認", "notifications.clear": "通知を消去", "notifications.clear_confirmation": "本当に通知を消去しますか?", "notifications.clear_title": "通知を消去しようとしています", diff --git a/app/javascript/mastodon/locales/ko.json b/app/javascript/mastodon/locales/ko.json index 3b4434fef7..0013632784 100644 --- a/app/javascript/mastodon/locales/ko.json +++ b/app/javascript/mastodon/locales/ko.json @@ -97,6 +97,8 @@ "block_modal.title": "사용자를 차단할까요?", "block_modal.you_wont_see_mentions": "그를 멘션하는 게시물을 더는 보지 않습니다.", "boost_modal.combo": "다음엔 {combo}를 눌러서 이 과정을 건너뛸 수 있습니다", + "boost_modal.reblog": "게시물을 부스트할까요?", + "boost_modal.undo_reblog": "게시물을 부스트 취소할까요?", "bundle_column_error.copy_stacktrace": "에러 리포트 복사하기", "bundle_column_error.error.body": "요청한 페이지를 렌더링 할 수 없습니다. 저희의 코드에 버그가 있거나, 브라우저 호환성 문제일 수 있습니다.", "bundle_column_error.error.title": "으악, 안돼!", @@ -467,6 +469,7 @@ "mute_modal.you_wont_see_mentions": "그를 멘션하는 게시물을 더는 보지 않게 됩니다.", "mute_modal.you_wont_see_posts": "내가 작성한 게시물을 볼 수는 있지만, 나는 그가 작성한 것을 보지 않게 됩니다.", "navigation_bar.about": "정보", + "navigation_bar.administration": "관리", "navigation_bar.advanced_interface": "고급 웹 인터페이스에서 열기", "navigation_bar.blocks": "차단한 사용자", "navigation_bar.bookmarks": "북마크", @@ -483,6 +486,7 @@ "navigation_bar.follows_and_followers": "팔로우와 팔로워", "navigation_bar.lists": "리스트", "navigation_bar.logout": "로그아웃", + "navigation_bar.moderation": "중재", "navigation_bar.mutes": "뮤트한 사용자", "navigation_bar.opened_in_classic_interface": "게시물, 계정, 기타 특정 페이지들은 기본적으로 기존 웹 인터페이스로 열리게 됩니다.", "navigation_bar.personal": "개인용", diff --git a/app/javascript/mastodon/locales/nl.json b/app/javascript/mastodon/locales/nl.json index 3362cf36ce..3526568249 100644 --- a/app/javascript/mastodon/locales/nl.json +++ b/app/javascript/mastodon/locales/nl.json @@ -98,6 +98,7 @@ "block_modal.you_wont_see_mentions": "Je ziet geen berichten meer die dit account vermelden.", "boost_modal.combo": "Je kunt {combo} klikken om dit de volgende keer over te slaan", "boost_modal.reblog": "Bericht boosten?", + "boost_modal.undo_reblog": "Bericht niet langer boosten?", "bundle_column_error.copy_stacktrace": "Foutrapportage kopiëren", "bundle_column_error.error.body": "De opgevraagde pagina kon niet worden weergegeven. Dit kan het gevolg zijn van een fout in onze broncode, of van een compatibiliteitsprobleem met je webbrowser.", "bundle_column_error.error.title": "O nee!", diff --git a/app/javascript/mastodon/locales/nn.json b/app/javascript/mastodon/locales/nn.json index 9ceb6eda92..393946ff18 100644 --- a/app/javascript/mastodon/locales/nn.json +++ b/app/javascript/mastodon/locales/nn.json @@ -97,6 +97,8 @@ "block_modal.title": "Blokker brukaren?", "block_modal.you_wont_see_mentions": "Du ser ikkje innlegg som nemner dei.", "boost_modal.combo": "Du kan trykkja {combo} for å hoppa over dette neste gong", + "boost_modal.reblog": "Framhev innlegget?", + "boost_modal.undo_reblog": "Fjern framhevinga?", "bundle_column_error.copy_stacktrace": "Kopier feilrapport", "bundle_column_error.error.body": "Den etterspurde sida kan ikke hentast fram. Det kan skuldast ein feil i koden vår eller eit kompatibilitetsproblem.", "bundle_column_error.error.title": "Ånei!", @@ -467,6 +469,7 @@ "mute_modal.you_wont_see_mentions": "Du vil ikkje sjå innlegg som nemner dei.", "mute_modal.you_wont_see_posts": "Dei kan framleis sjå innlegga dine, men du vil ikkje sjå deira.", "navigation_bar.about": "Om", + "navigation_bar.administration": "Administrasjon", "navigation_bar.advanced_interface": "Opne i avansert nettgrensesnitt", "navigation_bar.blocks": "Blokkerte brukarar", "navigation_bar.bookmarks": "Bokmerke", @@ -483,6 +486,7 @@ "navigation_bar.follows_and_followers": "Fylgje og fylgjarar", "navigation_bar.lists": "Lister", "navigation_bar.logout": "Logg ut", + "navigation_bar.moderation": "Moderering", "navigation_bar.mutes": "Målbundne brukarar", "navigation_bar.opened_in_classic_interface": "Innlegg, kontoar, og enkelte andre sider blir opna som standard i det klassiske webgrensesnittet.", "navigation_bar.personal": "Personleg", diff --git a/app/javascript/mastodon/locales/th.json b/app/javascript/mastodon/locales/th.json index 370b49e7e1..55f0fe02be 100644 --- a/app/javascript/mastodon/locales/th.json +++ b/app/javascript/mastodon/locales/th.json @@ -97,6 +97,8 @@ "block_modal.title": "ปิดกั้นผู้ใช้?", "block_modal.you_wont_see_mentions": "คุณจะไม่เห็นโพสต์ที่กล่าวถึงเขา", "boost_modal.combo": "คุณสามารถกด {combo} เพื่อข้ามสิ่งนี้ในครั้งถัดไป", + "boost_modal.reblog": "ดันโพสต์?", + "boost_modal.undo_reblog": "เลิกดันโพสต์?", "bundle_column_error.copy_stacktrace": "คัดลอกรายงานข้อผิดพลาด", "bundle_column_error.error.body": "ไม่สามารถแสดงผลหน้าที่ขอ ข้อผิดพลาดอาจเป็นเพราะข้อบกพร่องในโค้ดของเรา หรือปัญหาความเข้ากันได้ของเบราว์เซอร์", "bundle_column_error.error.title": "โอ้ ไม่!", @@ -467,6 +469,7 @@ "mute_modal.you_wont_see_mentions": "คุณจะไม่เห็นโพสต์ที่กล่าวถึงเขา", "mute_modal.you_wont_see_posts": "เขายังคงสามารถเห็นโพสต์ของคุณ แต่คุณจะไม่เห็นโพสต์ของเขา", "navigation_bar.about": "เกี่ยวกับ", + "navigation_bar.administration": "การดูแล", "navigation_bar.advanced_interface": "เปิดในส่วนติดต่อเว็บขั้นสูง", "navigation_bar.blocks": "ผู้ใช้ที่ปิดกั้นอยู่", "navigation_bar.bookmarks": "ที่คั่นหน้า", @@ -483,6 +486,7 @@ "navigation_bar.follows_and_followers": "การติดตามและผู้ติดตาม", "navigation_bar.lists": "รายการ", "navigation_bar.logout": "ออกจากระบบ", + "navigation_bar.moderation": "การกลั่นกรอง", "navigation_bar.mutes": "ผู้ใช้ที่ซ่อนอยู่", "navigation_bar.opened_in_classic_interface": "จะเปิดโพสต์, บัญชี และหน้าที่เฉพาะเจาะจงอื่น ๆ เป็นค่าเริ่มต้นในส่วนติดต่อเว็บแบบคลาสสิก", "navigation_bar.personal": "ส่วนบุคคล", diff --git a/app/javascript/mastodon/locales/tr.json b/app/javascript/mastodon/locales/tr.json index c80be8ab4c..9b94ede76a 100644 --- a/app/javascript/mastodon/locales/tr.json +++ b/app/javascript/mastodon/locales/tr.json @@ -97,6 +97,8 @@ "block_modal.title": "Kullanıcıyı engelle?", "block_modal.you_wont_see_mentions": "Onlardan bahseden gönderiler göremezsiniz.", "boost_modal.combo": "Bir daha ki sefere {combo} tuşuna basabilirsin", + "boost_modal.reblog": "Gönderiyi yeniden paylaş?", + "boost_modal.undo_reblog": "Gönderinin yeniden paylaşımını geri al?", "bundle_column_error.copy_stacktrace": "Hata raporunu kopyala", "bundle_column_error.error.body": "İstenen sayfa gösterilemiyor. Bu durum kodumuzdaki bir hatadan veya tarayıcı uyum sorunundan kaynaklanıyor olabilir.", "bundle_column_error.error.title": "Ah, hayır!", @@ -467,6 +469,7 @@ "mute_modal.you_wont_see_mentions": "Onlardan bahseden gönderiler göremezsiniz.", "mute_modal.you_wont_see_posts": "Onlar sizin gönderilerinizi görmeye devam edebilir, ancak siz onlarınkini göremezsiniz.", "navigation_bar.about": "Hakkında", + "navigation_bar.administration": "Yönetim", "navigation_bar.advanced_interface": "Gelişmiş web arayüzünde aç", "navigation_bar.blocks": "Engellenen kullanıcılar", "navigation_bar.bookmarks": "Yer İşaretleri", @@ -483,6 +486,7 @@ "navigation_bar.follows_and_followers": "Takip edilenler ve takipçiler", "navigation_bar.lists": "Listeler", "navigation_bar.logout": "Oturumu kapat", + "navigation_bar.moderation": "Moderasyon", "navigation_bar.mutes": "Sessize alınmış kullanıcılar", "navigation_bar.opened_in_classic_interface": "Gönderiler, hesaplar ve diğer belirli sayfalar klasik web arayüzünde varsayılan olarak açılıyorlar.", "navigation_bar.personal": "Kişisel", diff --git a/app/javascript/mastodon/locales/uk.json b/app/javascript/mastodon/locales/uk.json index 84ff487bda..905938d158 100644 --- a/app/javascript/mastodon/locales/uk.json +++ b/app/javascript/mastodon/locales/uk.json @@ -97,6 +97,8 @@ "block_modal.title": "Заблокувати користувача?", "block_modal.you_wont_see_mentions": "Ви не бачитимете дописів, де їх згадано.", "boost_modal.combo": "Ви можете натиснути {combo}, щоби пропустити це наступного разу", + "boost_modal.reblog": "Поширити допис?", + "boost_modal.undo_reblog": "Скасувати поширення?", "bundle_column_error.copy_stacktrace": "Копіювати звіт про помилку", "bundle_column_error.error.body": "Неможливо показати запитану сторінку. Це може бути спричинено помилкою у нашому коді, або через проблему сумісності з браузером.", "bundle_column_error.error.title": "О, ні!", @@ -467,6 +469,7 @@ "mute_modal.you_wont_see_mentions": "Ви не бачитимете дописів, де їх згадано.", "mute_modal.you_wont_see_posts": "Вони все ще можуть бачити ваші дописи, але ви не бачитимете їхніх.", "navigation_bar.about": "Про застосунок", + "navigation_bar.administration": "Адміністрування", "navigation_bar.advanced_interface": "Відкрити в розширеному вебінтерфейсі", "navigation_bar.blocks": "Заблоковані користувачі", "navigation_bar.bookmarks": "Закладки", @@ -483,6 +486,7 @@ "navigation_bar.follows_and_followers": "Підписки та підписники", "navigation_bar.lists": "Списки", "navigation_bar.logout": "Вийти", + "navigation_bar.moderation": "Модерування", "navigation_bar.mutes": "Приховані користувачі", "navigation_bar.opened_in_classic_interface": "Дописи, облікові записи та інші специфічні сторінки усталено відкриваються в класичному вебінтерфейсі.", "navigation_bar.personal": "Особисте", diff --git a/app/javascript/mastodon/locales/vi.json b/app/javascript/mastodon/locales/vi.json index 962984f100..48f56a0890 100644 --- a/app/javascript/mastodon/locales/vi.json +++ b/app/javascript/mastodon/locales/vi.json @@ -97,6 +97,8 @@ "block_modal.title": "Chặn người này?", "block_modal.you_wont_see_mentions": "Bạn sẽ không nhìn thấy tút có nhắc đến họ.", "boost_modal.combo": "Nhấn {combo} để bỏ qua bước này", + "boost_modal.reblog": "Đăng lại?", + "boost_modal.undo_reblog": "Hủy đăng lại?", "bundle_column_error.copy_stacktrace": "Sao chép báo lỗi", "bundle_column_error.error.body": "Không thể hiện trang này. Đây có thể là một lỗi trong mã lập trình của chúng tôi, hoặc là vấn đề tương thích của trình duyệt.", "bundle_column_error.error.title": "Ôi không!", @@ -458,6 +460,7 @@ "mute_modal.you_wont_see_mentions": "Bạn sẽ không nhìn thấy tút có nhắc đến họ.", "mute_modal.you_wont_see_posts": "Bạn sẽ không nhìn thấy tút của họ.", "navigation_bar.about": "Giới thiệu", + "navigation_bar.administration": "Quản trị", "navigation_bar.advanced_interface": "Dùng bố cục nhiều cột", "navigation_bar.blocks": "Người đã chặn", "navigation_bar.bookmarks": "Đã lưu", @@ -474,6 +477,7 @@ "navigation_bar.follows_and_followers": "Quan hệ", "navigation_bar.lists": "Danh sách", "navigation_bar.logout": "Đăng xuất", + "navigation_bar.moderation": "Kiểm duyệt", "navigation_bar.mutes": "Người đã ẩn", "navigation_bar.opened_in_classic_interface": "Tút, tài khoản và các trang cụ thể khác được mở theo mặc định trong giao diện web cổ điển.", "navigation_bar.personal": "Cá nhân", diff --git a/app/javascript/mastodon/locales/zh-CN.json b/app/javascript/mastodon/locales/zh-CN.json index aab806ec8e..fded16b195 100644 --- a/app/javascript/mastodon/locales/zh-CN.json +++ b/app/javascript/mastodon/locales/zh-CN.json @@ -97,6 +97,8 @@ "block_modal.title": "屏蔽该用户?", "block_modal.you_wont_see_mentions": "你将无法看到提及他们的嘟文。", "boost_modal.combo": "下次按住 {combo} 即可跳过此提示", + "boost_modal.reblog": "是否转嘟?", + "boost_modal.undo_reblog": "是否取消转嘟?", "bundle_column_error.copy_stacktrace": "复制错误报告", "bundle_column_error.error.body": "请求的页面无法渲染,可能是代码出现错误或浏览器存在兼容性问题。", "bundle_column_error.error.title": "糟糕!", @@ -467,6 +469,7 @@ "mute_modal.you_wont_see_mentions": "你看不到提及他们的嘟文。", "mute_modal.you_wont_see_posts": "他们可以看到你的嘟文,但是你看不到他们的。", "navigation_bar.about": "关于", + "navigation_bar.administration": "管理", "navigation_bar.advanced_interface": "在高级网页界面中打开", "navigation_bar.blocks": "已屏蔽的用户", "navigation_bar.bookmarks": "书签", @@ -483,6 +486,7 @@ "navigation_bar.follows_and_followers": "关注和粉丝", "navigation_bar.lists": "列表", "navigation_bar.logout": "退出登录", + "navigation_bar.moderation": "运营", "navigation_bar.mutes": "已隐藏的用户", "navigation_bar.opened_in_classic_interface": "嘟文、账户和其他特定页面默认在经典网页界面中打开。", "navigation_bar.personal": "个人", diff --git a/config/locales/doorkeeper.fr.yml b/config/locales/doorkeeper.fr.yml index a5d70030a5..8855ca5426 100644 --- a/config/locales/doorkeeper.fr.yml +++ b/config/locales/doorkeeper.fr.yml @@ -25,7 +25,7 @@ fr: edit: Modifier submit: Envoyer confirmations: - destroy: Voulez-vous vraiment faire ça ? + destroy: En êtes-vous sûr ? edit: title: Modifier l’application form: @@ -69,7 +69,7 @@ fr: buttons: revoke: Révoquer confirmations: - revoke: Voulez-vous vraiment faire ça ? + revoke: En êtes-vous sûr ? index: authorized_at: Autorisée le %{date} description_html: Ces applications peuvent accéder à votre compte via l'API. Si vous voyez ici des applications que vous ne reconnaissez pas ou qui ne fonctionnent pas normalement, vous pouvez en révoquer les accès. diff --git a/config/locales/en-GB.yml b/config/locales/en-GB.yml index 61dd5d9b38..ca747953f6 100644 --- a/config/locales/en-GB.yml +++ b/config/locales/en-GB.yml @@ -865,6 +865,8 @@ en-GB: links: allow: Allow link allow_provider: Allow publisher + confirm_disallow: Are you sure you want to disallow selected links? + confirm_disallow_provider: Are you sure you want to disallow selected providers? description_html: These are links that are currently being shared a lot by accounts that your server sees posts from. It can help your users find out what's going on in the world. No links are displayed publicly until you approve the publisher. You can also allow or reject individual links. disallow: Disallow link disallow_provider: Disallow publisher @@ -888,6 +890,10 @@ en-GB: statuses: allow: Allow post allow_account: Allow author + confirm_allow: Are you sure you want to allow selected statuses? + confirm_allow_account: Are you sure you want to allow selected accounts? + confirm_disallow: Are you sure you want to disallow selected statuses? + confirm_disallow_account: Are you sure you want to disallow selected accounts? description_html: These are posts that your server knows about that are currently being shared and favourited a lot at the moment. It can help your new and returning users to find more people to follow. No posts are displayed publicly until you approve the author, and the author allows their account to be suggested to others. You can also allow or reject individual posts. disallow: Disallow post disallow_account: Disallow author @@ -920,6 +926,7 @@ en-GB: used_by_over_week: one: Used by one person over the last week other: Used by %{count} people over the last week + title: Recommendations & Trends trending: Trending warning_presets: add_new: Add new diff --git a/config/locales/fr-CA.yml b/config/locales/fr-CA.yml index 4542b24858..e27750e1ad 100644 --- a/config/locales/fr-CA.yml +++ b/config/locales/fr-CA.yml @@ -722,6 +722,7 @@ fr-CA: desc_html: Ceci se base sur des scripts externes de hCaptcha, ce qui peut engendrer des soucis de sécurité et de confidentialité. De plus, cela peut rendre l'inscription beaucoup moins accessible pour certaines personnes (surtout les personnes handicapées). Pour ces raisons, veuillez envisager des mesures alternatives telles que l'inscription par acceptation ou par invitation. title: Obliger les nouveaux utilisateurs à résoudre un CAPTCHA pour vérifier leur compte content_retention: + danger_zone: Zone de danger preamble: Contrôle comment le contenu créé par les utilisateurs est enregistré et stocké dans Mastodon. title: Rétention du contenu default_noindex: @@ -761,6 +762,7 @@ fr-CA: destroyed_msg: Téléversement sur le site supprimé avec succès ! software_updates: critical_update: Critique — veuillez mettre à jour au plus vite + description: Il est recommandé de maintenir votre installation de Mastodon à jour afin de bénéficier des derniers correctifs et fonctionnalités. Par ailleurs, il est parfois critique de mettre à jour Mastodon en temps voulu de manière à éviter les incidents relatifs à la sécurité. Pour ces raisons, Mastodon examine la disponibilté des mises à jour toutes les 30 minutes, et vous en avisera en fonction de vos préférences de notification par messagerie électronique. documentation_link: En savoir plus release_notes: Notes de mises à jour title: Mises à jour disponibles diff --git a/config/locales/fr.yml b/config/locales/fr.yml index 0f2d247720..006696fc8d 100644 --- a/config/locales/fr.yml +++ b/config/locales/fr.yml @@ -574,7 +574,7 @@ fr: already_suspended_badges: local: Déjà suspendu sur ce serveur remote: Déjà suspendu sur le serveur distant - are_you_sure: Voulez-vous vraiment faire ça ? + are_you_sure: En êtes-vous sûr ? assign_to_self: Me l’assigner assigned: Modérateur assigné by_target_domain: Domaine du compte signalé @@ -722,6 +722,7 @@ fr: desc_html: Ceci se base sur des scripts externes venant de hCaptcha, ce qui peut engendrer des soucis de sécurité et de confidentialité. De plus, cela peut rendre l'inscription beaucoup moins accessible pour certaines personnes (comme les personnes handicapées). Pour ces raisons, veuillez envisager des mesures alternatives telles que l'inscription sur acceptation ou invitation. title: Exiger que les nouveaux utilisateurs résolvent un CAPTCHA pour confirmer leur compte content_retention: + danger_zone: Zone de danger preamble: Contrôle comment le contenu créé par les utilisateurs est enregistré et stocké dans Mastodon. title: Rétention du contenu default_noindex: @@ -761,6 +762,7 @@ fr: destroyed_msg: Téléversement sur le site supprimé avec succès ! software_updates: critical_update: Critique — veuillez mettre à jour au plus vite + description: Il est recommandé de maintenir votre installation de Mastodon à jour afin de bénéficier des derniers correctifs et fonctionnalités. Par ailleurs, il est parfois critique de mettre à jour Mastodon en temps voulu de manière à éviter les incidents relatifs à la sécurité. Pour ces raisons, Mastodon examine la disponibilté des mises à jour toutes les 30 minutes, et vous en avisera en fonction de vos préférences de notification par messagerie électronique. documentation_link: En savoir plus release_notes: Notes de mises à jour title: Mises à jour disponibles diff --git a/config/locales/nl.yml b/config/locales/nl.yml index 0c125acd07..cdd71112e9 100644 --- a/config/locales/nl.yml +++ b/config/locales/nl.yml @@ -505,8 +505,8 @@ nl: dashboard: instance_accounts_dimension: Meest door ons gevolgde accounts instance_accounts_measure: opgeslagen accounts - instance_followers_measure: daar ons daar gevolgd - instance_follows_measure: door hun hier gevolgd + instance_followers_measure: onze volgens daar + instance_follows_measure: hun volgers hier instance_languages_dimension: Meest actieve talen instance_media_attachments_measure: opgeslagen mediabestanden instance_reports_measure: rapportages over hun @@ -898,7 +898,7 @@ nl: name: Naam newest: Nieuwste oldest: Oudste - open: Openbaar bekijken + open: In het openbaar bekijken reset: Opnieuw review: Status beoordelen search: Zoeken diff --git a/config/locales/simple_form.fr-CA.yml b/config/locales/simple_form.fr-CA.yml index 4e67db2db6..e8aafa4b1c 100644 --- a/config/locales/simple_form.fr-CA.yml +++ b/config/locales/simple_form.fr-CA.yml @@ -82,6 +82,7 @@ fr-CA: closed_registrations_message: Affiché lorsque les inscriptions sont fermées custom_css: Vous pouvez appliquer des styles personnalisés sur la version Web de Mastodon. mascot: Remplace l'illustration dans l'interface Web avancée. + media_cache_retention_period: Les fichiers médias des messages publiés par des utilisateurs distants sont mis en cache sur votre serveur. Lorsque cette valeur est positive, les médias sont supprimés au terme du nombre de jours spécifié. Si les données des médias sont demandées après leur suppression, elles seront téléchargées à nouveau, dans la mesure où le contenu source est toujours disponible. En raison des restrictions concernant la fréquence à laquelle les cartes de prévisualisation des liens interrogent des sites tiers, il est recommandé de fixer cette valeur à au moins 14 jours, faute de quoi les cartes de prévisualisation des liens ne seront pas mises à jour à la demande avant cette échéance. peers_api_enabled: Une liste de noms de domaine que ce serveur a rencontrés dans le fédiverse. Aucune donnée indiquant si vous vous fédérez ou non avec un serveur particulier n'est incluse ici, seulement l'information que votre serveur connaît un autre serveur. Cette option est utilisée par les services qui collectent des statistiques sur la fédération en général. profile_directory: L'annuaire des profils répertorie tous les utilisateurs qui ont opté pour être découverts. require_invite_text: Lorsque les inscriptions nécessitent une approbation manuelle, rendre le texte de l’invitation "Pourquoi voulez-vous vous inscrire ?" obligatoire plutôt que facultatif diff --git a/config/locales/simple_form.fr.yml b/config/locales/simple_form.fr.yml index a9df5375f3..315e22c5fb 100644 --- a/config/locales/simple_form.fr.yml +++ b/config/locales/simple_form.fr.yml @@ -82,6 +82,7 @@ fr: closed_registrations_message: Affiché lorsque les inscriptions sont fermées custom_css: Vous pouvez appliquer des styles personnalisés sur la version Web de Mastodon. mascot: Remplace l'illustration dans l'interface Web avancée. + media_cache_retention_period: Les fichiers médias des messages publiés par des utilisateurs distants sont mis en cache sur votre serveur. Lorsque cette valeur est positive, les médias sont supprimés au terme du nombre de jours spécifié. Si les données des médias sont demandées après leur suppression, elles seront téléchargées à nouveau, dans la mesure où le contenu source est toujours disponible. En raison des restrictions concernant la fréquence à laquelle les cartes de prévisualisation des liens interrogent des sites tiers, il est recommandé de fixer cette valeur à au moins 14 jours, faute de quoi les cartes de prévisualisation des liens ne seront pas mises à jour à la demande avant cette échéance. peers_api_enabled: Une liste de noms de domaine que ce serveur a rencontrés dans le fédiverse. Aucune donnée indiquant si vous vous fédérez ou non avec un serveur particulier n'est incluse ici, seulement l'information que votre serveur connaît un autre serveur. Cette option est utilisée par les services qui collectent des statistiques sur la fédération en général. profile_directory: L'annuaire des profils répertorie tous les comptes qui choisi d'être découvrables. require_invite_text: Lorsque les inscriptions nécessitent une approbation manuelle, rendre le texte de l’invitation "Pourquoi voulez-vous vous inscrire ?" obligatoire plutôt que facultatif From 3c412578c916f4bdebb2abd3ca793f8fad00f921 Mon Sep 17 00:00:00 2001 From: HolgerHuo <50446405+HolgerHuo@users.noreply.github.com> Date: Wed, 28 Aug 2024 17:28:48 +0800 Subject: [PATCH 004/153] update: max_media_attachments follow server advertised value (#31616) --- app/javascript/mastodon/features/ui/index.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/javascript/mastodon/features/ui/index.jsx b/app/javascript/mastodon/features/ui/index.jsx index f36e0cf501..657c9e9e58 100644 --- a/app/javascript/mastodon/features/ui/index.jsx +++ b/app/javascript/mastodon/features/ui/index.jsx @@ -85,7 +85,7 @@ const mapStateToProps = state => ({ isComposing: state.getIn(['compose', 'is_composing']), hasComposingText: state.getIn(['compose', 'text']).trim().length !== 0, hasMediaAttachments: state.getIn(['compose', 'media_attachments']).size > 0, - canUploadMore: !state.getIn(['compose', 'media_attachments']).some(x => ['audio', 'video'].includes(x.get('type'))) && state.getIn(['compose', 'media_attachments']).size < 4, + canUploadMore: !state.getIn(['compose', 'media_attachments']).some(x => ['audio', 'video'].includes(x.get('type'))) && state.getIn(['compose', 'media_attachments']).size < state.getIn(['server', 'server', 'configuration', 'statuses', 'max_media_attachments']), firstLaunch: state.getIn(['settings', 'introductionVersion'], 0) < INTRODUCTION_VERSION, username: state.getIn(['accounts', me, 'username']), }); From f6fb9b75dbc10cee8beee4bcb84dd08e821baf1b Mon Sep 17 00:00:00 2001 From: Emelia Smith Date: Wed, 28 Aug 2024 12:40:37 +0200 Subject: [PATCH 005/153] Streaming: Fix BIND IPv6 handling (#31624) --- streaming/index.js | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/streaming/index.js b/streaming/index.js index d94649d6e2..5ef1f6f319 100644 --- a/streaming/index.js +++ b/streaming/index.js @@ -1351,15 +1351,23 @@ const startServer = async () => { * @param {function(string): void} [onSuccess] */ const attachServerWithConfig = (server, onSuccess) => { - if (process.env.SOCKET || process.env.PORT && isNaN(+process.env.PORT)) { - server.listen(process.env.SOCKET || process.env.PORT, () => { + if (process.env.SOCKET) { + server.listen(process.env.SOCKET, () => { if (onSuccess) { fs.chmodSync(server.address(), 0o666); onSuccess(server.address()); } }); } else { - server.listen(+(process.env.PORT || 4000), process.env.BIND || '127.0.0.1', () => { + const port = +(process.env.PORT || 4000); + let bind = process.env.BIND ?? '127.0.0.1'; + // Web uses the URI syntax for BIND, which means IPv6 addresses may + // be wrapped in square brackets: + if (bind.startsWith('[') && bind.endsWith(']')) { + bind = bind.slice(1, -1); + } + + server.listen(port, bind, () => { if (onSuccess) { onSuccess(`${server.address().address}:${server.address().port}`); } From dc7412c15f3e447a06cd0046c0a35c721878d49d Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Thu, 29 Aug 2024 10:18:41 +0200 Subject: [PATCH 006/153] Update opentelemetry-ruby (non-major) (#31646) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- Gemfile | 4 ++-- Gemfile.lock | 14 +++++++------- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/Gemfile b/Gemfile index 9a6db1ec09..3fcde202ad 100644 --- a/Gemfile +++ b/Gemfile @@ -99,10 +99,10 @@ gem 'json-ld' gem 'json-ld-preloaded', '~> 3.2' gem 'rdf-normalize', '~> 0.5' -gem 'opentelemetry-api', '~> 1.3.0' +gem 'opentelemetry-api', '~> 1.4.0' group :opentelemetry do - gem 'opentelemetry-exporter-otlp', '~> 0.28.0', require: false + gem 'opentelemetry-exporter-otlp', '~> 0.29.0', require: false gem 'opentelemetry-instrumentation-active_job', '~> 0.7.1', require: false gem 'opentelemetry-instrumentation-active_model_serializers', '~> 0.20.1', require: false gem 'opentelemetry-instrumentation-concurrent_ruby', '~> 0.21.2', require: false diff --git a/Gemfile.lock b/Gemfile.lock index d14fc0168f..3ae4de2329 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -290,8 +290,8 @@ GEM globalid (1.2.1) activesupport (>= 6.1) google-protobuf (3.25.4) - googleapis-common-protos-types (1.14.0) - google-protobuf (~> 3.18) + googleapis-common-protos-types (1.15.0) + google-protobuf (>= 3.18, < 5.a) haml (6.3.0) temple (>= 0.8.2) thor @@ -489,10 +489,10 @@ GEM openssl (3.2.0) openssl-signature_algorithm (1.3.0) openssl (> 2.0) - opentelemetry-api (1.3.0) - opentelemetry-common (0.20.1) + opentelemetry-api (1.4.0) + opentelemetry-common (0.21.0) opentelemetry-api (~> 1.0) - opentelemetry-exporter-otlp (0.28.1) + opentelemetry-exporter-otlp (0.29.0) google-protobuf (>= 3.18) googleapis-common-protos-types (~> 1.3) opentelemetry-api (~> 1.1) @@ -980,8 +980,8 @@ DEPENDENCIES omniauth-rails_csrf_protection (~> 1.0) omniauth-saml (~> 2.0) omniauth_openid_connect (~> 0.6.1) - opentelemetry-api (~> 1.3.0) - opentelemetry-exporter-otlp (~> 0.28.0) + opentelemetry-api (~> 1.4.0) + opentelemetry-exporter-otlp (~> 0.29.0) opentelemetry-instrumentation-active_job (~> 0.7.1) opentelemetry-instrumentation-active_model_serializers (~> 0.20.1) opentelemetry-instrumentation-concurrent_ruby (~> 0.21.2) From 099657be9a4f261e6502212689250b0af47b64da Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Thu, 29 Aug 2024 10:19:38 +0200 Subject: [PATCH 007/153] Update dependency flatware-rspec to v2.3.3 (#31636) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- Gemfile.lock | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index 3ae4de2329..cb9f92d335 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -264,10 +264,11 @@ GEM ffi-compiler (1.3.2) ffi (>= 1.15.5) rake - flatware (2.3.2) + flatware (2.3.3) + drb thor (< 2.0) - flatware-rspec (2.3.2) - flatware (= 2.3.2) + flatware-rspec (2.3.3) + flatware (= 2.3.3) rspec (>= 3.6) fog-core (2.5.0) builder @@ -710,7 +711,7 @@ GEM rspec-mocks (~> 3.13.0) rspec-core (3.13.0) rspec-support (~> 3.13.0) - rspec-expectations (3.13.1) + rspec-expectations (3.13.2) diff-lcs (>= 1.2.0, < 2.0) rspec-support (~> 3.13.0) rspec-github (2.4.0) From 8bd8238d4156a338e9e3790738fda80a29103789 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Thu, 29 Aug 2024 08:20:02 +0000 Subject: [PATCH 008/153] Update dependency selenium-webdriver to v4.24.0 (#31633) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile.lock b/Gemfile.lock index cb9f92d335..78fd21b4e8 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -781,7 +781,7 @@ GEM scenic (1.8.0) activerecord (>= 4.0.0) railties (>= 4.0.0) - selenium-webdriver (4.23.0) + selenium-webdriver (4.24.0) base64 (~> 0.2) logger (~> 1.4) rexml (~> 3.2, >= 3.2.5) From 4f4be654529429ff1886ce5b11ef1d1189d80d2d Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Thu, 29 Aug 2024 10:30:09 +0200 Subject: [PATCH 009/153] Update dependency @rails/ujs to v7.1.400 (#31628) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- package.json | 2 +- yarn.lock | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/package.json b/package.json index 7f21b11404..a6f86dfd4c 100644 --- a/package.json +++ b/package.json @@ -45,7 +45,7 @@ "@formatjs/intl-pluralrules": "^5.2.2", "@gamestdio/websocket": "^0.3.2", "@github/webauthn-json": "^2.1.1", - "@rails/ujs": "7.1.3", + "@rails/ujs": "7.1.400", "@reduxjs/toolkit": "^2.0.1", "@svgr/webpack": "^5.5.0", "arrow-key-navigation": "^1.2.0", diff --git a/yarn.lock b/yarn.lock index c3a7c6b1a5..b5c44fd306 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2757,7 +2757,7 @@ __metadata: "@formatjs/intl-pluralrules": "npm:^5.2.2" "@gamestdio/websocket": "npm:^0.3.2" "@github/webauthn-json": "npm:^2.1.1" - "@rails/ujs": "npm:7.1.3" + "@rails/ujs": "npm:7.1.400" "@reduxjs/toolkit": "npm:^2.0.1" "@svgr/webpack": "npm:^5.5.0" "@testing-library/dom": "npm:^10.2.0" @@ -3049,10 +3049,10 @@ __metadata: languageName: node linkType: hard -"@rails/ujs@npm:7.1.3": - version: 7.1.3 - resolution: "@rails/ujs@npm:7.1.3" - checksum: 10c0/68112d9add9dbc59b40c2ec1bc095a67445c57d20d0ab7d817ce3de0cd90374e2690af8ad54ce6ecc2d1c748b34c0c44d0fbd2f515ce2c443d7c5d23d00b9ce5 +"@rails/ujs@npm:7.1.400": + version: 7.1.400 + resolution: "@rails/ujs@npm:7.1.400" + checksum: 10c0/181329e731b925788a530dc5bc44eb4a07ae780e20b0309fd9140ebeeca30d9432ed50be0f25ae60f10beb3aa8883f6d662e4b9c6f6cd19a32c1f42ab2505c47 languageName: node linkType: hard From 5d725b2c12516f0dccc79cee47fd1f616082a21b Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Thu, 29 Aug 2024 10:30:39 +0200 Subject: [PATCH 010/153] New Crowdin Translations (automated) (#31647) Co-authored-by: GitHub Actions --- app/javascript/mastodon/locales/cs.json | 3 ++ app/javascript/mastodon/locales/eu.json | 45 ++++++++++++++++++++++ app/javascript/mastodon/locales/fr-CA.json | 11 +++++- app/javascript/mastodon/locales/fr.json | 11 +++++- app/javascript/mastodon/locales/pl.json | 1 + config/locales/doorkeeper.fr-CA.yml | 1 + config/locales/doorkeeper.fr.yml | 1 + config/locales/fr-CA.yml | 29 ++++++++++++++ config/locales/fr.yml | 29 ++++++++++++++ 9 files changed, 129 insertions(+), 2 deletions(-) diff --git a/app/javascript/mastodon/locales/cs.json b/app/javascript/mastodon/locales/cs.json index ebfaef3675..116a9c0148 100644 --- a/app/javascript/mastodon/locales/cs.json +++ b/app/javascript/mastodon/locales/cs.json @@ -97,6 +97,8 @@ "block_modal.title": "Zablokovat uživatele?", "block_modal.you_wont_see_mentions": "Neuvidíte příspěvky, které ho zmiňují.", "boost_modal.combo": "Příště můžete pro přeskočení stisknout {combo}", + "boost_modal.reblog": "Boostnout příspěvek?", + "boost_modal.undo_reblog": "Zrušit boostování příspěvku?", "bundle_column_error.copy_stacktrace": "Zkopírovat zprávu o chybě", "bundle_column_error.error.body": "Požadovanou stránku nelze vykreslit. Může to být způsobeno chybou v našem kódu nebo problémem s kompatibilitou prohlížeče.", "bundle_column_error.error.title": "Ale ne!", @@ -192,6 +194,7 @@ "confirmations.unfollow.confirm": "Přestat sledovat", "confirmations.unfollow.message": "Opravdu chcete {name} přestat sledovat?", "confirmations.unfollow.title": "Přestat sledovat uživatele?", + "content_warning.hide": "Skrýt příspěvek", "conversation.delete": "Smazat konverzaci", "conversation.mark_as_read": "Označit jako přečtené", "conversation.open": "Zobrazit konverzaci", diff --git a/app/javascript/mastodon/locales/eu.json b/app/javascript/mastodon/locales/eu.json index a8e2e668c3..f169e2905b 100644 --- a/app/javascript/mastodon/locales/eu.json +++ b/app/javascript/mastodon/locales/eu.json @@ -97,6 +97,8 @@ "block_modal.title": "Erabiltzailea blokeatu nahi duzu?", "block_modal.you_wont_see_mentions": "Ez duzu ikusiko bera aipatzen duen argitalpenik.", "boost_modal.combo": "{combo} sakatu dezakezu hurrengoan hau saltatzeko", + "boost_modal.reblog": "Bultzatu bidalketa?", + "boost_modal.undo_reblog": "Bidalketari bultzada kendu?", "bundle_column_error.copy_stacktrace": "Kopiatu errore-txostena", "bundle_column_error.error.body": "Eskatutako orria ezin izan da bistaratu. Kodeko errore bategatik izan daiteke edo nabigatzailearen bateragarritasun arazo bategatik.", "bundle_column_error.error.title": "O ez!", @@ -192,6 +194,8 @@ "confirmations.unfollow.confirm": "Utzi jarraitzeari", "confirmations.unfollow.message": "Ziur {name} jarraitzeari utzi nahi diozula?", "confirmations.unfollow.title": "Erabiltzailea jarraitzeari utzi?", + "content_warning.hide": "Tuta ezkutatu", + "content_warning.show": "Erakutsi hala ere", "conversation.delete": "Ezabatu elkarrizketa", "conversation.mark_as_read": "Markatu irakurrita bezala", "conversation.open": "Ikusi elkarrizketa", @@ -299,6 +303,8 @@ "filter_modal.select_filter.subtitle": "Hautatu lehendik dagoen kategoria bat edo sortu berria", "filter_modal.select_filter.title": "Iragazi bidalketa hau", "filter_modal.title.status": "Iragazi bidalketa bat", + "filter_warning.matches_filter": "“{title}” iragazkiarekin bat dator", + "filtered_notifications_banner.pending_requests": "Ezagutu dezakezun {count, plural, =0 {inoren} one {pertsona baten} other {# pertsonen}}", "filtered_notifications_banner.title": "Iragazitako jakinarazpenak", "firehose.all": "Guztiak", "firehose.local": "Zerbitzari hau", @@ -347,6 +353,14 @@ "hashtag.follow": "Jarraitu traolari", "hashtag.unfollow": "Utzi traola jarraitzeari", "hashtags.and_other": "…eta {count, plural, one {}other {# gehiago}}", + "hints.profiles.followers_may_be_missing": "Baliteke profil honen jarraitzaile guztiak ez agertzea.", + "hints.profiles.follows_may_be_missing": "Baliteke profil honek jarraitzen dituen profil guztiak ez erakustea.", + "hints.profiles.posts_may_be_missing": "Baliteke profil honen tut guztiak ez erakustea.", + "hints.profiles.see_more_followers": "Ikusi jarraitzaile gehiago {domain}-(e)n", + "hints.profiles.see_more_follows": "Ikusi jarraitzaile gehiago {domain}-(e)n", + "hints.profiles.see_more_posts": "Ikusi bidalketa gehiago {domain}-(e)n", + "hints.threads.replies_may_be_missing": "Baliteke beste zerbitzari batzuen erantzun batzuk ez erakustea.", + "hints.threads.see_more": "Ikusi erantzun gehiago {domain}-(e)n", "home.column_settings.show_reblogs": "Erakutsi bultzadak", "home.column_settings.show_replies": "Erakutsi erantzunak", "home.hide_announcements": "Ezkutatu iragarpenak", @@ -354,12 +368,17 @@ "home.pending_critical_update.link": "Ikusi eguneraketak", "home.pending_critical_update.title": "Segurtasun eguneraketa kritikoa eskuragarri!", "home.show_announcements": "Erakutsi iragarpenak", + "ignore_notifications_modal.disclaimer": "Mastodonek ezin die jakinarazi erabiltzaileei beraien jakinarazpenei ezikusiarena egingo diezula. Jakinarazpenei ezikusiarena egiteak ez du eragotziko mezuak bidaltzen jarraitzea.", "ignore_notifications_modal.filter_instead": "Iragazi ez ikusiarena egin beharrean", + "ignore_notifications_modal.filter_to_act_users": "Oraindik ere erabiltzaileak onartu, baztertu edo salatu ahal izango dituzu", + "ignore_notifications_modal.filter_to_avoid_confusion": "Iragazteak nahaste potentzialak saihesten laguntzen du", + "ignore_notifications_modal.filter_to_review_separately": "Banaka berrikus ditzakezu iragazitako jakinarazpenak", "ignore_notifications_modal.ignore": "Ezikusi jakinarazpenak", "ignore_notifications_modal.limited_accounts_title": "Moderatutako kontuen jakinarazpenei ez ikusiarena egin?", "ignore_notifications_modal.new_accounts_title": "Kontu berrien jakinarazpenei ez ikusiarena egin?", "ignore_notifications_modal.not_followers_title": "Jarraitzen ez zaituzten pertsonen jakinarazpenei ez ikusiarena egin?", "ignore_notifications_modal.not_following_title": "Jarraitzen ez dituzun pertsonen jakinarazpenei ez ikusiarena egin?", + "ignore_notifications_modal.private_mentions_title": "Eskatu gabeko aipamen pribatuen jakinarazpenei ez ikusiarena egin?", "interaction_modal.description.favourite": "Mastodon kontu batekin bidalketa hau gogoko egin dezakezu, egileari eskertzeko eta gerorako gordetzeko.", "interaction_modal.description.follow": "Mastodon kontu batekin {name} jarraitu dezakezu bere bidalketak zure hasierako denbora lerroan jasotzeko.", "interaction_modal.description.reblog": "Mastodon kontu batekin bidalketa hau bultzatu dezakezu, zure jarraitzaileekin partekatzeko.", @@ -420,6 +439,8 @@ "limited_account_hint.action": "Erakutsi profila hala ere", "limited_account_hint.title": "Profil hau ezkutatu egin dute {domain} zerbitzariko moderatzaileek.", "link_preview.author": "Egilea: {name}", + "link_preview.more_from_author": "{name} erabiltzaileaz gehiago jakin", + "link_preview.shares": "{count, plural, one {{counter} bidalketa} other {{counter} bidalketa}}", "lists.account.add": "Gehitu zerrendara", "lists.account.remove": "Kendu zerrendatik", "lists.delete": "Ezabatu zerrenda", @@ -448,6 +469,7 @@ "mute_modal.you_wont_see_mentions": "Ez duzu ikusiko bera aipatzen duen argitalpenik.", "mute_modal.you_wont_see_posts": "Zure argitalpenak ikus ditzake, baina ez dituzu bereak ikusiko.", "navigation_bar.about": "Honi buruz", + "navigation_bar.administration": "Administrazioa", "navigation_bar.advanced_interface": "Ireki web interfaze aurreratuan", "navigation_bar.blocks": "Blokeatutako erabiltzaileak", "navigation_bar.bookmarks": "Laster-markak", @@ -464,6 +486,7 @@ "navigation_bar.follows_and_followers": "Jarraitutakoak eta jarraitzaileak", "navigation_bar.lists": "Zerrendak", "navigation_bar.logout": "Amaitu saioa", + "navigation_bar.moderation": "Moderazioa", "navigation_bar.mutes": "Mutututako erabiltzaileak", "navigation_bar.opened_in_classic_interface": "Argitalpenak, kontuak eta beste orri jakin batzuk lehenespenez irekitzen dira web-interfaze klasikoan.", "navigation_bar.personal": "Pertsonala", @@ -474,10 +497,18 @@ "navigation_bar.security": "Segurtasuna", "not_signed_in_indicator.not_signed_in": "Baliabide honetara sarbidea izateko saioa hasi behar duzu.", "notification.admin.report": "{name} erabiltzaileak {target} salatu du", + "notification.admin.report_account": "{name}-(e)k {target}-ren {count, plural, one {bidalketa bat} other {# bidalketa}} salatu zituen {category} delakoagatik", + "notification.admin.report_account_other": "{name}-(e)k {target}-ren {count, plural, one {bidalketa bat salatu zuen} other {# bidalketa salatu zituen}}", + "notification.admin.report_statuses": "{name}-(e)k {target} salatu zuen {category} delakoagatik", + "notification.admin.report_statuses_other": "{name} erabiltzaileak {target} salatu du", "notification.admin.sign_up": "{name} erabiltzailea erregistratu da", + "notification.admin.sign_up.name_and_others": "{name} eta {count, plural, one {erabiltzaile # gehiago} other {# erabiltzaile gehiago}} erregistratu dira", "notification.favourite": "{name}(e)k zure bidalketa gogoko du", + "notification.favourite.name_and_others_with_link": "{name} eta {count, plural, one {erabiltzaile # gehiagok} other {# erabiltzaile gehiagok}} zure bidalketa gogoko dute", "notification.follow": "{name}(e)k jarraitzen dizu", + "notification.follow.name_and_others": "{name} eta {count, plural, one {erabiltzaile # gehiagok} other {# erabiltzaile gehiagok}} jarraitu dizute", "notification.follow_request": "{name}(e)k zu jarraitzeko eskaera egin du", + "notification.follow_request.name_and_others": "{name} eta {count, plural, one {erabiltzaile # gehiagok} other {# erabiltzaile gehiagok}} zu jarraitzeko eskaera egin dute", "notification.label.mention": "Aipamena", "notification.label.private_mention": "Aipamen pribatua", "notification.label.private_reply": "Erantzun pribatua", @@ -495,14 +526,26 @@ "notification.own_poll": "Zure inkesta amaitu da", "notification.poll": "Zuk erantzun duzun inkesta bat bukatu da", "notification.reblog": "{name}(e)k bultzada eman dio zure bidalketari", + "notification.reblog.name_and_others_with_link": "{name} eta {count, plural, one {erabiltzaile # gehiagok} other {# erabiltzaile gehiagok}} bultzada eman diote zure bidalketari", "notification.relationships_severance_event": "{name} erabiltzailearekin galdutako konexioak", "notification.relationships_severance_event.account_suspension": "{from} zerbitzariko administratzaile batek {target} bertan behera utzi du, hau da, ezin izango dituzu jaso hango eguneratzerik edo hangoekin elkarreragin.", "notification.relationships_severance_event.learn_more": "Informazio gehiago", "notification.status": "{name} erabiltzaileak bidalketa egin berri du", "notification.update": "{name} erabiltzaileak bidalketa bat editatu du", "notification_requests.accept": "Onartu", + "notification_requests.accept_multiple": "{count, plural, one {Onartu eskaera…} other {Onartu # eskaerak…}}", + "notification_requests.confirm_accept_multiple.button": "{count, plural, one {Onartu eskaera} other {Onartu eskaerak}}", + "notification_requests.confirm_accept_multiple.title": "Onartu jakinarazpen-eskaerak?", + "notification_requests.confirm_dismiss_multiple.button": "{count, plural, one {Baztertu eskaera} other {Baztertu eskaerak}}", + "notification_requests.confirm_dismiss_multiple.title": "Baztertu jakinarazpen-eskaerak?", "notification_requests.dismiss": "Baztertu", + "notification_requests.dismiss_multiple": "{count, plural, one {Baztertu eskaera…} other {Baztertu # eskaerak…}}", + "notification_requests.edit_selection": "Editatu", + "notification_requests.exit_selection": "Egina", + "notification_requests.explainer_for_limited_account": "Kontu honen jakinarazpenak iragazi egin dira, kontua moderatzaile batek mugatu duelako.", + "notification_requests.explainer_for_limited_remote_account": "Kontu horren jakinarazpenak iragazi egin dira kontua edo bere zerbitzaria moderatzaile batek mugatu duelako.", "notification_requests.maximize": "Maximizatu", + "notification_requests.minimize_banner": "Minimizatu iragazitako jakinarazpenen bannerra", "notification_requests.notifications_from": "{name} erabiltzailearen jakinarazpenak", "notification_requests.title": "Iragazitako jakinarazpenak", "notification_requests.view": "Ikusi jakinarazpenak", @@ -719,8 +762,10 @@ "server_banner.about_active_users": "Azken 30 egunetan zerbitzari hau erabili duen jendea (hilabeteko erabiltzaile aktiboak)", "server_banner.active_users": "erabiltzaile aktibo", "server_banner.administered_by": "Administratzailea(k):", + "server_banner.is_one_of_many": "{domain} fedibertsoan parte hartzeko erabil dezakezun Mastodonen zerbitzari independenteetako bat da.", "server_banner.server_stats": "Zerbitzariaren estatistikak:", "sign_in_banner.create_account": "Sortu kontua", + "sign_in_banner.follow_anyone": "Jarraitu edonori fedibertsoan eta ikusi dena ordena kronologikoan. Algoritmorik gabe, iragarki edo titulu gezurtirik gabe.", "sign_in_banner.mastodon_is": "Mastodon gertatzen ari denari buruz egunean egoteko modurik onena da.", "sign_in_banner.sign_in": "Hasi saioa", "sign_in_banner.sso_redirect": "Hasi saioa edo izena eman", diff --git a/app/javascript/mastodon/locales/fr-CA.json b/app/javascript/mastodon/locales/fr-CA.json index 2961285267..4327ccb366 100644 --- a/app/javascript/mastodon/locales/fr-CA.json +++ b/app/javascript/mastodon/locales/fr-CA.json @@ -302,6 +302,7 @@ "filter_modal.select_filter.title": "Filtrer cette publication", "filter_modal.title.status": "Filtrer une publication", "filter_warning.matches_filter": "Correspond au filtre « {title} »", + "filtered_notifications_banner.pending_requests": "De la part {count, plural, =0 {d’aucune personne} one {d'une personne} other {de # personnes}} que vous pourriez connaître", "filtered_notifications_banner.title": "Notifications filtrées", "firehose.all": "Tout", "firehose.local": "Ce serveur", @@ -527,7 +528,15 @@ "notification.status": "{name} vient de publier", "notification.update": "{name} a modifié une publication", "notification_requests.accept": "Accepter", + "notification_requests.accept_multiple": "{count, plural, one {Accepter # requête …} other {Accepter # requêtes …}}", + "notification_requests.confirm_accept_multiple.button": "{count, plural, one {Accepter la requête} other {Accepter les requêtes}}", + "notification_requests.confirm_accept_multiple.message": "Vous êtes sur le point d'accepter {count, plural, one {une requête de notification} other {# requêtes de notification}}. Êtes-vous sûr de vouloir continuer ?", + "notification_requests.confirm_accept_multiple.title": "Accepter les requêtes de notification ?", + "notification_requests.confirm_dismiss_multiple.button": "{count, plural, one {Ignorer la requête} other {Ignorer les requêtes}}", + "notification_requests.confirm_dismiss_multiple.message": "Vous êtes sur le point de rejeter {count, plural, one {une requête de notification} other {# requêtes de notification}}. Vous ne serez plus en mesure d'{count, plural, one {y} other {y}} accéder facilement, ultérieurement. Êtes-vous sûr de vouloir continuer ?", + "notification_requests.confirm_dismiss_multiple.title": "Rejeter les requêtes de notification ?", "notification_requests.dismiss": "Rejeter", + "notification_requests.dismiss_multiple": "{count, plural, one {Rejeter # requête …} other {Rejeter # requêtes …}}", "notification_requests.edit_selection": "Modifier", "notification_requests.exit_selection": "Fait", "notification_requests.explainer_for_limited_account": "Les notifications en provenance de ce compte ont été filtrées car le compte a été limité par un modérateur.", @@ -589,7 +598,7 @@ "notifications.policy.filter_not_following_title": "Personnes que vous ne suivez pas", "notifications.policy.filter_private_mentions_hint": "Filtrées sauf si c'est en réponse à l'une de vos mentions ou si vous suivez l'expéditeur·ice", "notifications.policy.filter_private_mentions_title": "Mentions privées non sollicitées", - "notifications.policy.title": "Gérer les notifications en provenance de …", + "notifications.policy.title": "Gestion des notifications des …", "notifications_permission_banner.enable": "Activer les notifications de bureau", "notifications_permission_banner.how_to_control": "Pour recevoir des notifications lorsque Mastodon n’est pas ouvert, activez les notifications de bureau. Vous pouvez contrôler précisément quels types d’interactions génèrent des notifications de bureau via le bouton {icon} ci-dessus une fois qu’elles sont activées.", "notifications_permission_banner.title": "Ne rien rater", diff --git a/app/javascript/mastodon/locales/fr.json b/app/javascript/mastodon/locales/fr.json index 970103db83..e38f5b33ce 100644 --- a/app/javascript/mastodon/locales/fr.json +++ b/app/javascript/mastodon/locales/fr.json @@ -302,6 +302,7 @@ "filter_modal.select_filter.title": "Filtrer ce message", "filter_modal.title.status": "Filtrer un message", "filter_warning.matches_filter": "Correspond au filtre « {title} »", + "filtered_notifications_banner.pending_requests": "De la part {count, plural, =0 {d’aucune personne} one {d'une personne} other {de # personnes}} que vous pourriez connaître", "filtered_notifications_banner.title": "Notifications filtrées", "firehose.all": "Tout", "firehose.local": "Ce serveur", @@ -527,7 +528,15 @@ "notification.status": "{name} vient de publier", "notification.update": "{name} a modifié un message", "notification_requests.accept": "Accepter", + "notification_requests.accept_multiple": "{count, plural, one {Accepter # requête …} other {Accepter # requêtes …}}", + "notification_requests.confirm_accept_multiple.button": "{count, plural, one {Accepter la requête} other {Accepter les requêtes}}", + "notification_requests.confirm_accept_multiple.message": "Vous êtes sur le point d'accepter {count, plural, one {une requête de notification} other {# requêtes de notification}}. Êtes-vous sûr de vouloir continuer ?", + "notification_requests.confirm_accept_multiple.title": "Accepter les requêtes de notification ?", + "notification_requests.confirm_dismiss_multiple.button": "{count, plural, one {Ignorer la requête} other {Ignorer les requêtes}}", + "notification_requests.confirm_dismiss_multiple.message": "Vous êtes sur le point de rejeter {count, plural, one {une requête de notification} other {# requêtes de notification}}. Vous ne serez plus en mesure d'{count, plural, one {y} other {y}} accéder facilement, ultérieurement. Êtes-vous sûr de vouloir continuer ?", + "notification_requests.confirm_dismiss_multiple.title": "Rejeter les requêtes de notification ?", "notification_requests.dismiss": "Rejeter", + "notification_requests.dismiss_multiple": "{count, plural, one {Rejeter # requête …} other {Rejeter # requêtes …}}", "notification_requests.edit_selection": "Modifier", "notification_requests.exit_selection": "Fait", "notification_requests.explainer_for_limited_account": "Les notifications en provenance de ce compte ont été filtrées car le compte a été limité par un modérateur.", @@ -589,7 +598,7 @@ "notifications.policy.filter_not_following_title": "Personnes que vous ne suivez pas", "notifications.policy.filter_private_mentions_hint": "Filtrées sauf si c'est en réponse à l'une de vos mentions ou si vous suivez l'expéditeur·ice", "notifications.policy.filter_private_mentions_title": "Mentions privées non sollicitées", - "notifications.policy.title": "Gérer les notifications en provenance de …", + "notifications.policy.title": "Gestion des notifications des …", "notifications_permission_banner.enable": "Activer les notifications de bureau", "notifications_permission_banner.how_to_control": "Pour recevoir des notifications lorsque Mastodon n’est pas ouvert, activez les notifications du bureau. Vous pouvez contrôler précisément quels types d’interactions génèrent des notifications de bureau via le bouton {icon} ci-dessus une fois qu’elles sont activées.", "notifications_permission_banner.title": "Toujours au courant", diff --git a/app/javascript/mastodon/locales/pl.json b/app/javascript/mastodon/locales/pl.json index 1af79127a5..09ac636185 100644 --- a/app/javascript/mastodon/locales/pl.json +++ b/app/javascript/mastodon/locales/pl.json @@ -531,6 +531,7 @@ "notification.relationships_severance_event.account_suspension": "Administrator z {from} zawiesił {target}, więc nie dostaniesz wieści ani nie wejdziesz w interakcje z użytkownikami z tego serwera.", "notification.relationships_severance_event.domain_block": "Administrator z {from} zablokował {target}, w tym {followersCount} z Twoich obserwujących i {followingCount, plural, one {# konto} other {# konta}} które obserwujesz.", "notification.relationships_severance_event.learn_more": "Dowiedz się więcej", + "notification.relationships_severance_event.user_domain_block": "Zablokowałeś {target}, w tym {followersCount} z Twoich obserwujących i {followingCount, plural, one {# konto} other {# konta}} które obserwujesz.", "notification.status": "{name} opublikował(a) nowy wpis", "notification.update": "{name} edytował(a) post", "notification_requests.accept": "Akceptuj", diff --git a/config/locales/doorkeeper.fr-CA.yml b/config/locales/doorkeeper.fr-CA.yml index 00df58be79..f06cc7804d 100644 --- a/config/locales/doorkeeper.fr-CA.yml +++ b/config/locales/doorkeeper.fr-CA.yml @@ -83,6 +83,7 @@ fr-CA: access_denied: Le/la propriétaire de la ressource ou le serveur d’autorisation a refusé la requête. credential_flow_not_configured: Le flux des identifiants du mot de passe du/de la propriétaire de la ressource a échoué car Doorkeeper.configure.resource_owner_from_credentials n’est pas configuré. invalid_client: L’authentification du client a échoué à cause d’un client inconnu, d’aucune authentification de client incluse ou d’une méthode d’authentification non prise en charge. + invalid_code_challenge_method: La méthode de contrôle du code doit être S256, le mode « en clair » n'est pas pris en charge. invalid_grant: L’autorisation accordée est invalide, expirée, révoquée, ne concorde pas avec l’URI de redirection utilisée dans la requête d’autorisation, ou a été délivrée à un autre client. invalid_redirect_uri: L’URI de redirection n’est pas valide. invalid_request: diff --git a/config/locales/doorkeeper.fr.yml b/config/locales/doorkeeper.fr.yml index 8855ca5426..cf8d1f08b4 100644 --- a/config/locales/doorkeeper.fr.yml +++ b/config/locales/doorkeeper.fr.yml @@ -83,6 +83,7 @@ fr: access_denied: Le propriétaire de la ressource ou le serveur d’autorisation a refusé la requête. credential_flow_not_configured: Le flux des identifiants du mot de passe du propriétaire de la ressource a échoué car Doorkeeper.configure.resource_owner_from_credentials n’est pas configuré. invalid_client: L’authentification du client a échoué à cause d’un client inconnu, d’aucune authentification de client incluse ou d’une méthode d’authentification non prise en charge. + invalid_code_challenge_method: La méthode de contrôle du code doit être S256, le mode « en clair » n'est pas pris en charge. invalid_grant: L’autorisation accordée est invalide, expirée, annulée, ne concorde pas avec l’URL de redirection utilisée dans la requête d’autorisation, ou a été délivrée à un autre client. invalid_redirect_uri: L’URL de redirection n’est pas valide. invalid_request: diff --git a/config/locales/fr-CA.yml b/config/locales/fr-CA.yml index e27750e1ad..52b3515725 100644 --- a/config/locales/fr-CA.yml +++ b/config/locales/fr-CA.yml @@ -169,13 +169,16 @@ fr-CA: approve_appeal: Approuver l'appel approve_user: Approuver l’utilisateur assigned_to_self_report: Affecter le signalement + change_email_user: Modification de l’adresse de messagerie électronique pour l'utilisateur·ce change_role_user: Changer le rôle de l’utilisateur·rice confirm_user: Confirmer l’utilisateur create_account_warning: Créer une alerte create_announcement: Créer une annonce + create_canonical_email_block: Création d'un blocage de courrier électronique create_custom_emoji: Créer des émojis personnalisés create_domain_allow: Créer un domaine autorisé create_domain_block: Créer un blocage de domaine + create_email_domain_block: Création d'un blocage de domaine de courrier électronique create_ip_block: Créer une règle IP create_unavailable_domain: Créer un domaine indisponible create_user_role: Créer le rôle @@ -417,8 +420,10 @@ fr-CA: new: create: Créer le blocage resolve: Résoudre le domaine + title: Blocage d'un nouveau domaine de messagerie électronique not_permitted: Non autorisé resolved_through_html: Résolu par %{domain} + title: Domaines de messagerie électronique bloqués export_domain_allows: new: title: Importer les autorisations de domaine @@ -443,6 +448,9 @@ fr-CA: title: Recommandations d'abonnement unsuppress: Rétablir les recommandations d'abonnement instances: + audit_log: + title: Journaux d'audit récents + view_all: Voir les journaux d'audit complets availability: description_html: one: Si la livraison au domaine échoue pendant %{count} jour, aucune autre tentative de livraison ne sera faite à moins qu'une livraison depuis le domaine ne soit reçue. @@ -610,6 +618,7 @@ fr-CA: report: 'Signalement #%{id}' reported_account: Compte signalé reported_by: Signalé par + reported_with_application: Signalé avec l'application resolved: Résolus resolved_msg: Signalement résolu avec succès ! skip_to_actions: Passer aux actions @@ -632,6 +641,7 @@ fr-CA: delete_data_html: effacer le profil de @%{acct} et ses contenus dans 30 jours, à moins que la suspension du compte ne soit annulée entre temps preview_preamble_html: "@%{acct} recevra un avertissement contenant les éléments suivants :" record_strike_html: enregistrer une sanction contre @%{acct} pour vous aider à prendre des mesures supplémentaires en cas d'infractions futures de ce compte + send_email_html: Envoyer un courriel d'avertissement à @%{acct} warning_placeholder: Arguments supplémentaires pour l'action de modération (facultatif). target_origin: Origine du compte signalé title: Signalements @@ -671,6 +681,7 @@ fr-CA: manage_appeals: Gérer les contestations manage_appeals_description: Permet aux utilisateur⋅rice⋅s d'examiner les appels contre les actions de modération manage_blocks: Gérer les blocages + manage_blocks_description: Permet aux utilisateur⋅rice⋅s de bloquer des fournisseurs de courriel et des adresses IP manage_custom_emojis: Gérer les émojis personnalisés manage_custom_emojis_description: Permet aux utilisateur⋅rice⋅s de gérer les émoticônes personnalisées sur le serveur manage_federation: Gérer de la féderation @@ -850,6 +861,9 @@ fr-CA: message_html: "Votre serveur web est mal configuré. La confidentialité de vos utilisateurs est en péril." tags: name: Nom + newest: Plus récents + oldest: Plus anciens + reset: Réinitialiser review: État du traitement search: Recherche title: Hashtags @@ -858,10 +872,16 @@ fr-CA: trends: allow: Autoriser approved: Approuvé + confirm_allow: Êtes-vous sûr de vouloir autoriser les hashtags sélectionnés ? + confirm_disallow: Êtes-vous sûr de vouloir interdire les hashtags sélectionnés ? disallow: Interdire links: allow: Autoriser le lien allow_provider: Autoriser l'éditeur + confirm_allow: Êtes-vous sûr de vouloir autoriser les liens sélectionnés ? + confirm_allow_provider: Êtes-vous sûr de vouloir autoriser les fournisseurs sélectionnés ? + confirm_disallow: Êtes-vous sûr de vouloir interdire les liens sélectionnés ? + confirm_disallow_provider: Êtes-vous sûr de vouloir interdire les fournisseurs sélectionnés ? description_html: Ces liens sont actuellement énormément partagés par des comptes dont votre serveur voit les messages. Cela peut aider vos utilisateur⋅rice⋅s à découvrir ce qu'il se passe dans le monde. Aucun lien n'est publiquement affiché tant que vous n'avez pas approuvé le compte qui le publie. Vous pouvez également autoriser ou rejeter les liens individuellement. disallow: Interdire le lien disallow_provider: Interdire l'éditeur @@ -1002,7 +1022,9 @@ fr-CA: guide_link_text: Tout le monde peut y contribuer. sensitive_content: Contenu sensible application_mailer: + notification_preferences: Modification des préférences de la messagerie salutation: "%{name}," + settings: 'Modifier les préférences de la messagerie : %{link}' unsubscribe: Se désabonner view: 'Voir :' view_profile: Voir le profil @@ -1022,6 +1044,7 @@ fr-CA: hint_html: Juste une autre chose! Nous avons besoin de confirmer que vous êtes un humain (pour que nous puissions empêcher les spams!). Résolvez le CAPTCHA ci-dessous et cliquez sur "Continuer". title: Vérification de sécurité confirmations: + awaiting_review: Votre adresse de messagerie est confirmée ! L'équipe de %{domain} est en train d'examiner votre inscription. Vous recevrez un e-mail si votre compte est approuvé ! awaiting_review_title: Votre inscription est en cours de validation clicking_this_link: cliquer sur ce lien login_link: vous connecter @@ -1029,6 +1052,7 @@ fr-CA: redirect_to_app_html: Vous auriez dû être redirigé vers l’application %{app_name}. Si cela ne s’est pas produit, essayez de %{clicking_this_link} ou de revenir manuellement à l’application. registration_complete: Votre inscription sur %{domain} est désormais terminée ! welcome_title: Bienvenue, %{name} ! + wrong_email_hint: Si cette adresse de messagerie est incorrecte, vous pouvez la modifier dans vos paramètres de compte. delete_account: Supprimer le compte delete_account_html: Si vous désirez supprimer votre compte, vous pouvez cliquer ici. Il vous sera demandé de confirmer cette action. description: @@ -1049,6 +1073,7 @@ fr-CA: or_log_in_with: Ou authentifiez-vous avec privacy_policy_agreement_html: J’ai lu et j’accepte la politique de confidentialité progress: + confirm: Confirmation de l'adresse mail details: Vos infos review: Notre avis rules: Accepter les règles @@ -1070,6 +1095,7 @@ fr-CA: security: Sécurité set_new_password: Définir le nouveau mot de passe setup: + email_below_hint_html: Consultez votre dossier de courrier indésirable ou demandez-en un autre. Vous pouvez corriger votre adresse e-mail si elle est incorrecte. email_settings_hint_html: Cliquez sur le lien que nous vous avons envoyé pour vérifier %{email}. Nous vous attendrons ici. link_not_received: Vous n'avez pas reçu de lien? new_confirmation_instructions_sent: Vous allez recevoir un nouvel e-mail avec le lien de confirmation dans quelques minutes ! @@ -1083,6 +1109,7 @@ fr-CA: title: Mettons les choses en place pour %{domain}. status: account_status: État du compte + confirming: En attente de la confirmation par courrier électronique. functional: Votre compte est entièrement opérationnel. pending: Votre demande est en attente d’examen par notre équipe. Cela peut prendre un certain temps. Vous recevrez un e-mail si votre demande est approuvée. redirecting_to: Votre compte est inactif car il est actuellement redirigé vers %{acct}. @@ -1128,6 +1155,8 @@ fr-CA: caches: Le contenu mis en cache par d'autres serveurs peut persister data_removal: Vos messages et autres données seront définitivement supprimés email_change_html: Vous pouvez modifier votre adresse e-mail sans supprimer votre compte + email_contact_html: S'il ne vous est toujours pas parvenu, vous pouvez envoyer un message à %{email} pour obtenir de l'aide + email_reconfirmation_html: Dans le cas où vous n'auriez pas reçu l'email de confirmation, vous pouvez en réclamer un nouveau irreversible: Vous ne pourrez pas restaurer ou réactiver votre compte more_details_html: Pour plus de détails, voir la politique de confidentialité. username_available: Votre nom d’utilisateur·rice sera à nouveau disponible diff --git a/config/locales/fr.yml b/config/locales/fr.yml index 006696fc8d..d7830bfe33 100644 --- a/config/locales/fr.yml +++ b/config/locales/fr.yml @@ -169,13 +169,16 @@ fr: approve_appeal: Approuver l'appel approve_user: Approuver le compte assigned_to_self_report: Affecter le signalement + change_email_user: Modification de l’adresse de messagerie électronique pour l'utilisateur·ce change_role_user: Changer le rôle du compte confirm_user: Confirmer le compte create_account_warning: Créer une alerte create_announcement: Créer une annonce + create_canonical_email_block: Création d'un blocage de courrier électronique create_custom_emoji: Créer des émojis personnalisés create_domain_allow: Créer un domaine autorisé create_domain_block: Créer un blocage de domaine + create_email_domain_block: Création d'un blocage de domaine de courrier électronique create_ip_block: Créer une règle IP create_unavailable_domain: Créer un domaine indisponible create_user_role: Créer le rôle @@ -417,8 +420,10 @@ fr: new: create: Créer le blocage resolve: Résoudre le domaine + title: Blocage d'un nouveau domaine de messagerie électronique not_permitted: Non autorisé resolved_through_html: Résolu par %{domain} + title: Domaines de messagerie électronique bloqués export_domain_allows: new: title: Importer les autorisations de domaine @@ -443,6 +448,9 @@ fr: title: Recommandations d'abonnement unsuppress: Rétablir les recommandations d'abonnement instances: + audit_log: + title: Journaux d'audit récents + view_all: Voir les journaux d'audit complets availability: description_html: one: Si la livraison au domaine échoue pendant %{count} jour, aucune autre tentative de livraison ne sera faite à moins qu'une livraison depuis le domaine ne soit reçue. @@ -610,6 +618,7 @@ fr: report: 'Signalement #%{id}' reported_account: Compte signalé reported_by: Signalé par + reported_with_application: Signalé avec l'application resolved: Résolus resolved_msg: Signalement résolu avec succès ! skip_to_actions: Passer aux actions @@ -632,6 +641,7 @@ fr: delete_data_html: effacer le profil de @%{acct} et ses contenus dans 30 jours, à moins que la suspension du compte ne soit annulée entre temps preview_preamble_html: "@%{acct} recevra un avertissement contenant les éléments suivants :" record_strike_html: enregistrer une sanction contre @%{acct} pour vous aider à prendre des mesures supplémentaires en cas d'infractions futures de ce compte + send_email_html: Envoyer un courriel d'avertissement à @%{acct} warning_placeholder: Arguments supplémentaires pour l'action de modération (facultatif). target_origin: Origine du compte signalé title: Signalements @@ -671,6 +681,7 @@ fr: manage_appeals: Gérer les contestations manage_appeals_description: Permet aux utilisateur⋅rice⋅s d'examiner les appels contre les actions de modération manage_blocks: Gérer les blocages + manage_blocks_description: Permet aux utilisateur⋅rice⋅s de bloquer des fournisseurs de courriel et des adresses IP manage_custom_emojis: Gérer les émojis personnalisés manage_custom_emojis_description: Permet aux utilisateur⋅rice⋅s de gérer les émoticônes personnalisées sur le serveur manage_federation: Gérer de la féderation @@ -850,6 +861,9 @@ fr: message_html: "Votre serveur web est mal configuré. La confidentialité de vos utilisateurs est en péril." tags: name: Nom + newest: Plus récents + oldest: Plus anciens + reset: Réinitialiser review: État du traitement search: Recherche title: Hashtags @@ -858,10 +872,16 @@ fr: trends: allow: Autoriser approved: Approuvé + confirm_allow: Êtes-vous sûr de vouloir autoriser les hashtags sélectionnés ? + confirm_disallow: Êtes-vous sûr de vouloir interdire les hashtags sélectionnés ? disallow: Interdire links: allow: Autoriser le lien allow_provider: Autoriser l'éditeur + confirm_allow: Êtes-vous sûr de vouloir autoriser les liens sélectionnés ? + confirm_allow_provider: Êtes-vous sûr de vouloir autoriser les fournisseurs sélectionnés ? + confirm_disallow: Êtes-vous sûr de vouloir interdire les liens sélectionnés ? + confirm_disallow_provider: Êtes-vous sûr de vouloir interdire les fournisseurs sélectionnés ? description_html: Ces liens sont actuellement énormément partagés par des comptes dont votre serveur voit les messages. Cela peut aider vos utilisateur⋅rice⋅s à découvrir ce qu'il se passe dans le monde. Aucun lien n'est publiquement affiché tant que vous n'avez pas approuvé le compte qui le publie. Vous pouvez également autoriser ou rejeter les liens individuellement. disallow: Interdire le lien disallow_provider: Interdire l'éditeur @@ -1002,7 +1022,9 @@ fr: guide_link_text: Tout le monde peut y contribuer. sensitive_content: Contenu sensible application_mailer: + notification_preferences: Modification des préférences de la messagerie salutation: "%{name}," + settings: 'Modifier les préférences de la messagerie : %{link}' unsubscribe: Se désabonner view: 'Voir :' view_profile: Voir le profil @@ -1022,6 +1044,7 @@ fr: hint_html: Encore une chose ! Nous avons besoin de confirmer que vous êtes un humain (c'est pour que nous puissions empêcher les spams !). Résolvez le CAPTCHA ci-dessous et cliquez sur "Continuer". title: Vérification de sécurité confirmations: + awaiting_review: Votre adresse de messagerie est confirmée ! L'équipe de %{domain} est en train d'examiner votre inscription. Vous recevrez un e-mail si votre compte est approuvé ! awaiting_review_title: Votre inscription est en cours de validation clicking_this_link: cliquer sur ce lien login_link: vous connecter @@ -1029,6 +1052,7 @@ fr: redirect_to_app_html: Vous auriez dû être redirigé vers l’application %{app_name}. Si cela ne s’est pas produit, essayez de %{clicking_this_link} ou de revenir manuellement à l’application. registration_complete: Votre inscription sur %{domain} est désormais terminée ! welcome_title: Bienvenue, %{name} ! + wrong_email_hint: Si cette adresse de messagerie est incorrecte, vous pouvez la modifier dans vos paramètres de compte. delete_account: Supprimer le compte delete_account_html: Si vous désirez supprimer votre compte, vous pouvez cliquer ici. Il vous sera demandé de confirmer cette action. description: @@ -1049,6 +1073,7 @@ fr: or_log_in_with: Ou authentifiez-vous avec privacy_policy_agreement_html: J’ai lu et j’accepte la politique de confidentialité progress: + confirm: Confirmation de l'adresse mail details: Vos infos review: Notre avis rules: Accepter les règles @@ -1070,6 +1095,7 @@ fr: security: Sécurité set_new_password: Définir le nouveau mot de passe setup: + email_below_hint_html: Consultez votre dossier de courrier indésirable ou demandez-en un autre. Vous pouvez corriger votre adresse e-mail si elle est incorrecte. email_settings_hint_html: Cliquez sur le lien que nous vous avons envoyé pour vérifier l’adresse %{email}. Nous vous attendons ici. link_not_received: Vous n'avez pas reçu de lien ? new_confirmation_instructions_sent: Vous allez recevoir un nouvel e-mail avec le lien de confirmation dans quelques minutes ! @@ -1083,6 +1109,7 @@ fr: title: Mettons les choses en place pour %{domain}. status: account_status: État du compte + confirming: En attente de la confirmation par courrier électronique. functional: Votre compte est entièrement opérationnel. pending: Votre demande est en attente d’examen par notre équipe. Cela peut prendre un certain temps. Vous recevrez un e-mail si votre demande est approuvée. redirecting_to: Votre compte est inactif car il est actuellement redirigé vers %{acct}. @@ -1128,6 +1155,8 @@ fr: caches: Le contenu mis en cache par d'autres serveurs peut persister data_removal: Vos messages et autres données seront définitivement supprimés email_change_html: Vous pouvez modifier votre adresse e-mail sans supprimer votre compte + email_contact_html: S'il ne vous est toujours pas parvenu, vous pouvez envoyer un message à %{email} pour obtenir de l'aide + email_reconfirmation_html: Dans le cas où vous n'auriez pas reçu l'email de confirmation, vous pouvez en réclamer un nouveau irreversible: Vous ne pourrez pas restaurer ou réactiver votre compte more_details_html: Pour plus de détails, voir la politique de confidentialité. username_available: Votre nom d’utilisateur·rice sera à nouveau disponible From b9269c8d3800bab8f1d37bfec755eb7b0e860553 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Thu, 29 Aug 2024 04:38:17 -0400 Subject: [PATCH 011/153] Convert `admin/reset` controller spec to system spec (#31643) --- .../admin/accounts/_local_account.html.haml | 2 +- .../admin/resets_controller_spec.rb | 35 --------------- spec/system/admin/reset_spec.rb | 45 +++++++++++++++++++ 3 files changed, 46 insertions(+), 36 deletions(-) delete mode 100644 spec/controllers/admin/resets_controller_spec.rb create mode 100644 spec/system/admin/reset_spec.rb diff --git a/app/views/admin/accounts/_local_account.html.haml b/app/views/admin/accounts/_local_account.html.haml index 3ad47d8dfb..5357ebcce9 100644 --- a/app/views/admin/accounts/_local_account.html.haml +++ b/app/views/admin/accounts/_local_account.html.haml @@ -52,7 +52,7 @@ - if can?(:reset_password, account.user) %tr %td - = table_link_to 'key', t('admin.accounts.reset_password'), admin_account_reset_path(account.id), method: :create, data: { confirm: t('admin.accounts.are_you_sure') } + = table_link_to 'key', t('admin.accounts.reset_password'), admin_account_reset_path(account.id), method: :post, data: { confirm: t('admin.accounts.are_you_sure') } %tr %th= t('simple_form.labels.defaults.locale') %td= standard_locale_name(account.user_locale) diff --git a/spec/controllers/admin/resets_controller_spec.rb b/spec/controllers/admin/resets_controller_spec.rb deleted file mode 100644 index 0cbc3b60ab..0000000000 --- a/spec/controllers/admin/resets_controller_spec.rb +++ /dev/null @@ -1,35 +0,0 @@ -# frozen_string_literal: true - -require 'rails_helper' - -describe Admin::ResetsController do - render_views - - subject { post :create, params: { account_id: account.id } } - - let(:account) { Fabricate(:account) } - - before do - sign_in Fabricate(:user, role: UserRole.find_by(name: 'Admin')), scope: :user - end - - describe 'POST #create', :inline_jobs do - it 'redirects to admin accounts page' do - emails = capture_emails { subject } - - expect(emails.size) - .to eq(2) - expect(emails).to have_attributes( - first: have_attributes( - to: include(account.user.email), - subject: I18n.t('devise.mailer.password_change.subject') - ), - last: have_attributes( - to: include(account.user.email), - subject: I18n.t('devise.mailer.reset_password_instructions.subject') - ) - ) - expect(response).to redirect_to(admin_account_path(account.id)) - end - end -end diff --git a/spec/system/admin/reset_spec.rb b/spec/system/admin/reset_spec.rb new file mode 100644 index 0000000000..50fb4b46df --- /dev/null +++ b/spec/system/admin/reset_spec.rb @@ -0,0 +1,45 @@ +# frozen_string_literal: true + +require 'rails_helper' + +describe 'Admin::Reset' do + it 'Resets password for account user' do + account = Fabricate :account + sign_in admin_user + visit admin_account_path(account.id) + + emails = capture_emails do + expect { submit_reset } + .to change(Admin::ActionLog.where(target: account.user), :count).by(1) + end + + expect(emails.first) + .to be_present + .and(deliver_to(account.user.email)) + .and(have_subject(password_change_subject)) + + expect(emails.last) + .to be_present + .and(deliver_to(account.user.email)) + .and(have_subject(reset_instructions_subject)) + + expect(page) + .to have_content(account.username) + end + + def admin_user + Fabricate(:user, role: UserRole.find_by(name: 'Admin')) + end + + def submit_reset + click_on I18n.t('admin.accounts.reset_password') + end + + def password_change_subject + I18n.t('devise.mailer.password_change.subject') + end + + def reset_instructions_subject + I18n.t('devise.mailer.reset_password_instructions.subject') + end +end From 02585d87894c52bb182260b3f33e6212a90e9ca7 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Thu, 29 Aug 2024 04:46:00 -0400 Subject: [PATCH 012/153] Convert `media` controller spec to request spec (#31634) --- spec/controllers/media_controller_spec.rb | 65 ---------------- spec/requests/media_spec.rb | 90 +++++++++++++++++++++++ 2 files changed, 90 insertions(+), 65 deletions(-) delete mode 100644 spec/controllers/media_controller_spec.rb create mode 100644 spec/requests/media_spec.rb diff --git a/spec/controllers/media_controller_spec.rb b/spec/controllers/media_controller_spec.rb deleted file mode 100644 index efd15b5b40..0000000000 --- a/spec/controllers/media_controller_spec.rb +++ /dev/null @@ -1,65 +0,0 @@ -# frozen_string_literal: true - -require 'rails_helper' - -describe MediaController do - render_views - - describe '#show' do - it 'raises when shortcode cant be found' do - get :show, params: { id: 'missing' } - - expect(response).to have_http_status(404) - end - - context 'when the media attachment has a shortcode' do - it 'redirects to the file url when attached to a status' do - status = Fabricate(:status) - media_attachment = Fabricate(:media_attachment, status: status, shortcode: 'OI6IgDzG-nYTqvDQ994') - get :show, params: { id: media_attachment.to_param } - - expect(response).to redirect_to(media_attachment.file.url(:original)) - end - - it 'responds with missing when there is not an attached status' do - media_attachment = Fabricate(:media_attachment, status: nil, shortcode: 'OI6IgDzG-nYTqvDQ994') - get :show, params: { id: media_attachment.to_param } - - expect(response).to have_http_status(404) - end - - it 'raises when not permitted to view' do - status = Fabricate(:status, visibility: :direct) - media_attachment = Fabricate(:media_attachment, status: status, shortcode: 'OI6IgDzG-nYTqvDQ994') - get :show, params: { id: media_attachment.to_param } - - expect(response).to have_http_status(404) - end - end - - context 'when the media attachment has no shortcode' do - it 'redirects to the file url when attached to a status' do - status = Fabricate(:status) - media_attachment = Fabricate(:media_attachment, status: status) - get :show, params: { id: media_attachment.to_param } - - expect(response).to redirect_to(media_attachment.file.url(:original)) - end - - it 'responds with missing when there is not an attached status' do - media_attachment = Fabricate(:media_attachment, status: nil) - get :show, params: { id: media_attachment.to_param } - - expect(response).to have_http_status(404) - end - - it 'raises when not permitted to view' do - status = Fabricate(:status, visibility: :direct) - media_attachment = Fabricate(:media_attachment, status: status) - get :show, params: { id: media_attachment.to_param } - - expect(response).to have_http_status(404) - end - end - end -end diff --git a/spec/requests/media_spec.rb b/spec/requests/media_spec.rb new file mode 100644 index 0000000000..a448a87492 --- /dev/null +++ b/spec/requests/media_spec.rb @@ -0,0 +1,90 @@ +# frozen_string_literal: true + +require 'rails_helper' + +RSpec.describe 'Media' do + describe 'GET /media/:id' do + context 'when the media attachment does not exist' do + it 'responds with not found' do + get '/media/missing' + + expect(response) + .to have_http_status(404) + end + end + + context 'when the media attachment has a shortcode' do + let(:media_attachment) { Fabricate :media_attachment, status: status, shortcode: 'OI6IgDzG-nYTqvDQ994' } + + context 'when attached to a status' do + let(:status) { Fabricate :status } + + it 'redirects to file url' do + get medium_path(id: media_attachment.shortcode) + + expect(response) + .to redirect_to(media_attachment.file.url(:original)) + end + end + + context 'when not attached to a status' do + let(:status) { nil } + + it 'responds with not found' do + get medium_path(id: media_attachment.shortcode) + + expect(response) + .to have_http_status(404) + end + end + + context 'when attached to non-public status' do + let(:status) { Fabricate :status, visibility: :direct } + + it 'responds with not found' do + get medium_path(id: media_attachment.shortcode) + + expect(response) + .to have_http_status(404) + end + end + end + + context 'when the media attachment does not have a shortcode' do + let(:media_attachment) { Fabricate :media_attachment, status: status, shortcode: nil } + + context 'when attached to a status' do + let(:status) { Fabricate :status } + + it 'redirects to file url' do + get medium_path(id: media_attachment.id) + + expect(response) + .to redirect_to(media_attachment.file.url(:original)) + end + end + + context 'when not attached to a status' do + let(:status) { nil } + + it 'responds with not found' do + get medium_path(id: media_attachment.id) + + expect(response) + .to have_http_status(404) + end + end + + context 'when attached to non-public status' do + let(:status) { Fabricate :status, visibility: :direct } + + it 'responds with not found' do + get medium_path(id: media_attachment.id) + + expect(response) + .to have_http_status(404) + end + end + end + end +end From 662f87dbe9c23e505fc9ffa3f21d6a623f4df974 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Thu, 29 Aug 2024 04:52:29 -0400 Subject: [PATCH 013/153] Use `MediaAttachment.supported_mime_types` method where relevant (#31635) --- app/serializers/rest/instance_serializer.rb | 2 +- app/serializers/rest/v1/instance_serializer.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/serializers/rest/instance_serializer.rb b/app/serializers/rest/instance_serializer.rb index 084701657e..cced83587d 100644 --- a/app/serializers/rest/instance_serializer.rb +++ b/app/serializers/rest/instance_serializer.rb @@ -77,7 +77,7 @@ class REST::InstanceSerializer < ActiveModel::Serializer }, media_attachments: { - supported_mime_types: MediaAttachment::IMAGE_MIME_TYPES + MediaAttachment::VIDEO_MIME_TYPES + MediaAttachment::AUDIO_MIME_TYPES, + supported_mime_types: MediaAttachment.supported_mime_types, image_size_limit: MediaAttachment::IMAGE_LIMIT, image_matrix_limit: Attachmentable::MAX_MATRIX_LIMIT, video_size_limit: MediaAttachment::VIDEO_LIMIT, diff --git a/app/serializers/rest/v1/instance_serializer.rb b/app/serializers/rest/v1/instance_serializer.rb index 636925b973..7f9f21c5af 100644 --- a/app/serializers/rest/v1/instance_serializer.rb +++ b/app/serializers/rest/v1/instance_serializer.rb @@ -69,7 +69,7 @@ class REST::V1::InstanceSerializer < ActiveModel::Serializer }, media_attachments: { - supported_mime_types: MediaAttachment::IMAGE_MIME_TYPES + MediaAttachment::VIDEO_MIME_TYPES + MediaAttachment::AUDIO_MIME_TYPES, + supported_mime_types: MediaAttachment.supported_mime_types, image_size_limit: MediaAttachment::IMAGE_LIMIT, image_matrix_limit: Attachmentable::MAX_MATRIX_LIMIT, video_size_limit: MediaAttachment::VIDEO_LIMIT, From ad0a28a8bfb8b527eae11cdc29829d87b07db53c Mon Sep 17 00:00:00 2001 From: Claire Date: Thu, 29 Aug 2024 14:39:07 +0200 Subject: [PATCH 014/153] Add `grouped_types` parameter to allow clients to restrict which notifications types get grouped (#31594) --- .../api/v2_alpha/notifications_controller.rb | 10 ++--- app/models/notification.rb | 45 ++++++++++++++----- app/models/notification_group.rb | 9 ++-- app/services/notify_service.rb | 2 +- .../api/v2_alpha/notifications_spec.rb | 43 ++++++++++++++++++ 5 files changed, 90 insertions(+), 19 deletions(-) diff --git a/app/controllers/api/v2_alpha/notifications_controller.rb b/app/controllers/api/v2_alpha/notifications_controller.rb index d0205ad6af..a9f4ac02a0 100644 --- a/app/controllers/api/v2_alpha/notifications_controller.rb +++ b/app/controllers/api/v2_alpha/notifications_controller.rb @@ -42,7 +42,7 @@ class Api::V2Alpha::NotificationsController < Api::BaseController limit = limit_param(DEFAULT_NOTIFICATIONS_COUNT_LIMIT, MAX_NOTIFICATIONS_COUNT_LIMIT) with_read_replica do - render json: { count: browserable_account_notifications.paginate_groups_by_min_id(limit, min_id: notification_marker&.last_read_id).count } + render json: { count: browserable_account_notifications.paginate_groups_by_min_id(limit, min_id: notification_marker&.last_read_id, grouped_types: params[:grouped_types]).count } end end @@ -68,7 +68,7 @@ class Api::V2Alpha::NotificationsController < Api::BaseController MastodonOTELTracer.in_span('Api::V2Alpha::NotificationsController#load_notifications') do notifications = browserable_account_notifications.includes(from_account: [:account_stat, :user]).to_a_grouped_paginated_by_id( limit_param(DEFAULT_NOTIFICATIONS_LIMIT), - params_slice(:max_id, :since_id, :min_id) + params.slice(:max_id, :since_id, :min_id, :grouped_types).permit(:max_id, :since_id, :min_id, grouped_types: []) ) Notification.preload_cache_collection_target_statuses(notifications) do |target_statuses| @@ -92,7 +92,7 @@ class Api::V2Alpha::NotificationsController < Api::BaseController def load_grouped_notifications MastodonOTELTracer.in_span('Api::V2Alpha::NotificationsController#load_grouped_notifications') do - @notifications.map { |notification| NotificationGroup.from_notification(notification, max_id: @group_metadata.dig(notification.group_key, :max_id)) } + @notifications.map { |notification| NotificationGroup.from_notification(notification, max_id: @group_metadata.dig(notification.group_key, :max_id), grouped_types: params[:grouped_types]) } end end @@ -125,11 +125,11 @@ class Api::V2Alpha::NotificationsController < Api::BaseController end def browserable_params - params.permit(:include_filtered, types: [], exclude_types: []) + params.slice(:include_filtered, :types, :exclude_types, :grouped_types).permit(:include_filtered, types: [], exclude_types: [], grouped_types: []) end def pagination_params(core_params) - params.slice(:limit, :types, :exclude_types, :include_filtered).permit(:limit, :include_filtered, types: [], exclude_types: []).merge(core_params) + params.slice(:limit, :include_filtered, :types, :exclude_types, :grouped_types).permit(:limit, :include_filtered, types: [], exclude_types: [], grouped_types: []).merge(core_params) end def expand_accounts_param diff --git a/app/models/notification.rb b/app/models/notification.rb index ae7c782bed..44a43d2ece 100644 --- a/app/models/notification.rb +++ b/app/models/notification.rb @@ -30,6 +30,8 @@ class Notification < ApplicationRecord 'Poll' => :poll, }.freeze + GROUPABLE_NOTIFICATION_TYPES = %i(favourite reblog).freeze + # Please update app/javascript/api_types/notification.ts if you change this PROPERTIES = { mention: { @@ -138,17 +140,40 @@ class Notification < ApplicationRecord end end - def paginate_groups(limit, pagination_order) + def paginate_groups(limit, pagination_order, grouped_types: nil) raise ArgumentError unless %i(asc desc).include?(pagination_order) query = reorder(id: pagination_order) + # Ideally `:types` would be a bind rather than part of the SQL itself, but that does not + # seem to be possible to do with Rails, considering that the expression would occur in + # multiple places, including in a `select` + group_key_sql = begin + if grouped_types.present? + # Normalize `grouped_types` so the number of different SQL query shapes remains small, and + # the queries can be analyzed in monitoring/telemetry tools + grouped_types = (grouped_types.map(&:to_sym) & GROUPABLE_NOTIFICATION_TYPES).sort + + sanitize_sql_array([<<~SQL.squish, { types: grouped_types }]) + COALESCE( + CASE + WHEN notifications.type IN (:types) THEN notifications.group_key + ELSE NULL + END, + 'ungrouped-' || notifications.id + ) + SQL + else + "COALESCE(notifications.group_key, 'ungrouped-' || notifications.id)" + end + end + unscoped .with_recursive( grouped_notifications: [ # Base case: fetching one notification and annotating it with visited groups query - .select('notifications.*', "ARRAY[COALESCE(notifications.group_key, 'ungrouped-' || notifications.id)] AS groups") + .select('notifications.*', "ARRAY[#{group_key_sql}] AS groups") .limit(1), # Recursive case, always yielding at most one annotated notification unscoped @@ -163,12 +188,12 @@ class Notification < ApplicationRecord # Recursive query, using `LATERAL` so we can refer to `wt` query .where(pagination_order == :desc ? 'notifications.id < wt.id' : 'notifications.id > wt.id') - .where.not("COALESCE(notifications.group_key, 'ungrouped-' || notifications.id) = ANY(wt.groups)") + .where.not("#{group_key_sql} = ANY(wt.groups)") .limit(1) .arel.lateral('notifications'), ] ) - .select('notifications.*', "array_append(wt.groups, COALESCE(notifications.group_key, 'ungrouped-' || notifications.id))"), + .select('notifications.*', "array_append(wt.groups, #{group_key_sql}) AS groups"), ] ) .from('grouped_notifications AS notifications') @@ -178,28 +203,28 @@ class Notification < ApplicationRecord # This returns notifications from the request page, but with at most one notification per group. # Notifications that have no `group_key` each count as a separate group. - def paginate_groups_by_max_id(limit, max_id: nil, since_id: nil) + def paginate_groups_by_max_id(limit, max_id: nil, since_id: nil, grouped_types: nil) query = reorder(id: :desc) query = query.where(id: ...(max_id.to_i)) if max_id.present? query = query.where(id: (since_id.to_i + 1)...) if since_id.present? - query.paginate_groups(limit, :desc) + query.paginate_groups(limit, :desc, grouped_types: grouped_types) end # Differs from :paginate_groups_by_max_id in that it gives the results immediately following min_id, # whereas since_id gives the items with largest id, but with since_id as a cutoff. # Results will be in ascending order by id. - def paginate_groups_by_min_id(limit, max_id: nil, min_id: nil) + def paginate_groups_by_min_id(limit, max_id: nil, min_id: nil, grouped_types: nil) query = reorder(id: :asc) query = query.where(id: (min_id.to_i + 1)...) if min_id.present? query = query.where(id: ...(max_id.to_i)) if max_id.present? - query.paginate_groups(limit, :asc) + query.paginate_groups(limit, :asc, grouped_types: grouped_types) end def to_a_grouped_paginated_by_id(limit, options = {}) if options[:min_id].present? - paginate_groups_by_min_id(limit, min_id: options[:min_id], max_id: options[:max_id]).reverse + paginate_groups_by_min_id(limit, min_id: options[:min_id], max_id: options[:max_id], grouped_types: options[:grouped_types]).reverse else - paginate_groups_by_max_id(limit, max_id: options[:max_id], since_id: options[:since_id]).to_a + paginate_groups_by_max_id(limit, max_id: options[:max_id], since_id: options[:since_id], grouped_types: options[:grouped_types]).to_a end end diff --git a/app/models/notification_group.rb b/app/models/notification_group.rb index 223945f07b..12294f24ec 100644 --- a/app/models/notification_group.rb +++ b/app/models/notification_group.rb @@ -6,8 +6,11 @@ class NotificationGroup < ActiveModelSerializers::Model # Try to keep this consistent with `app/javascript/mastodon/models/notification_group.ts` SAMPLE_ACCOUNTS_SIZE = 8 - def self.from_notification(notification, max_id: nil) - if notification.group_key.present? + def self.from_notification(notification, max_id: nil, grouped_types: nil) + grouped_types = grouped_types.presence&.map(&:to_sym) || Notification::GROUPABLE_NOTIFICATION_TYPES + groupable = notification.group_key.present? && grouped_types.include?(notification.type) + + if groupable # TODO: caching, and, if caching, preloading scope = notification.account.notifications.where(group_key: notification.group_key) scope = scope.where(id: ..max_id) if max_id.present? @@ -25,7 +28,7 @@ class NotificationGroup < ActiveModelSerializers::Model NotificationGroup.new( notification: notification, - group_key: notification.group_key || "ungrouped-#{notification.id}", + group_key: groupable ? notification.group_key : "ungrouped-#{notification.id}", sample_accounts: sample_accounts, notifications_count: notifications_count, most_recent_notification_id: most_recent_id diff --git a/app/services/notify_service.rb b/app/services/notify_service.rb index 695f4153c6..97eee05487 100644 --- a/app/services/notify_service.rb +++ b/app/services/notify_service.rb @@ -237,7 +237,7 @@ class NotifyService < BaseService private def notification_group_key - return nil if @notification.filtered || %i(favourite reblog).exclude?(@notification.type) + return nil if @notification.filtered || Notification::GROUPABLE_NOTIFICATION_TYPES.exclude?(@notification.type) type_prefix = "#{@notification.type}-#{@notification.target_status.id}" redis_key = "notif-group/#{@recipient.id}/#{type_prefix}" diff --git a/spec/requests/api/v2_alpha/notifications_spec.rb b/spec/requests/api/v2_alpha/notifications_spec.rb index a613158aa5..9d9eb34ebd 100644 --- a/spec/requests/api/v2_alpha/notifications_spec.rb +++ b/spec/requests/api/v2_alpha/notifications_spec.rb @@ -35,6 +35,17 @@ RSpec.describe 'Notifications' do end end + context 'with grouped_types parameter' do + let(:params) { { grouped_types: %w(reblog) } } + + it 'returns expected notifications count' do + subject + + expect(response).to have_http_status(200) + expect(body_as_json[:count]).to eq 5 + end + end + context 'with a read marker' do before do id = user.account.notifications.browserable.order(id: :desc).offset(2).first.id @@ -114,6 +125,38 @@ RSpec.describe 'Notifications' do end end + context 'with grouped_types param' do + let(:params) { { grouped_types: %w(reblog) } } + + it 'returns everything, but does not group favourites' do + subject + + expect(response).to have_http_status(200) + expect(body_as_json[:notification_groups]).to contain_exactly( + a_hash_including( + type: 'reblog', + sample_account_ids: [bob.account_id.to_s] + ), + a_hash_including( + type: 'mention', + sample_account_ids: [bob.account_id.to_s] + ), + a_hash_including( + type: 'favourite', + sample_account_ids: [bob.account_id.to_s] + ), + a_hash_including( + type: 'favourite', + sample_account_ids: [tom.account_id.to_s] + ), + a_hash_including( + type: 'follow', + sample_account_ids: [bob.account_id.to_s] + ) + ) + end + end + context 'with exclude_types param' do let(:params) { { exclude_types: %w(mention) } } From b0a30967d7f2a53aeaa3d3a630b0e012e5254231 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Fri, 30 Aug 2024 09:05:39 +0200 Subject: [PATCH 015/153] Update dependency thor to v1.3.2 (#31654) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile.lock b/Gemfile.lock index 78fd21b4e8..8c43ef054a 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -834,7 +834,7 @@ GEM terrapin (1.0.1) climate_control test-prof (1.4.1) - thor (1.3.1) + thor (1.3.2) tilt (2.3.0) timeout (0.4.1) tpm-key_attestation (0.12.0) From 92eba9096b6a75b46befb5c271755a6167ac342c Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Fri, 30 Aug 2024 09:12:56 +0200 Subject: [PATCH 016/153] New Crowdin Translations (automated) (#31656) Co-authored-by: GitHub Actions --- app/javascript/mastodon/locales/es-MX.json | 4 ++++ app/javascript/mastodon/locales/es.json | 4 ++++ app/javascript/mastodon/locales/fr-CA.json | 5 +++++ app/javascript/mastodon/locales/fr.json | 5 +++++ app/javascript/mastodon/locales/ja.json | 14 +++++++++++++- app/javascript/mastodon/locales/ru.json | 1 + app/javascript/mastodon/locales/ry.json | 5 +++++ config/locales/es.yml | 4 ++-- config/locales/fr-CA.yml | 9 +++++++++ config/locales/fr.yml | 9 +++++++++ config/locales/ja.yml | 17 +++++++++++++++++ 11 files changed, 74 insertions(+), 3 deletions(-) diff --git a/app/javascript/mastodon/locales/es-MX.json b/app/javascript/mastodon/locales/es-MX.json index 35ea5ba592..348300f728 100644 --- a/app/javascript/mastodon/locales/es-MX.json +++ b/app/javascript/mastodon/locales/es-MX.json @@ -97,6 +97,8 @@ "block_modal.title": "¿Bloquear usuario?", "block_modal.you_wont_see_mentions": "No verás publicaciones que los mencionen.", "boost_modal.combo": "Puedes hacer clic en {combo} para saltar este aviso la próxima vez", + "boost_modal.reblog": "¿Impulsar la publicación?", + "boost_modal.undo_reblog": "¿Dejar de impulsar la publicación?", "bundle_column_error.copy_stacktrace": "Copiar informe de error", "bundle_column_error.error.body": "La página solicitada no pudo ser renderizada. Podría deberse a un error en nuestro código o a un problema de compatibilidad con el navegador.", "bundle_column_error.error.title": "¡Oh, no!", @@ -467,6 +469,7 @@ "mute_modal.you_wont_see_mentions": "No verás publicaciones que los mencionen.", "mute_modal.you_wont_see_posts": "Todavía pueden ver tus publicaciones, pero tú no verás las de ellos.", "navigation_bar.about": "Acerca de", + "navigation_bar.administration": "Administración", "navigation_bar.advanced_interface": "Abrir en interfaz web avanzada", "navigation_bar.blocks": "Usuarios bloqueados", "navigation_bar.bookmarks": "Marcadores", @@ -483,6 +486,7 @@ "navigation_bar.follows_and_followers": "Siguiendo y seguidores", "navigation_bar.lists": "Listas", "navigation_bar.logout": "Cerrar sesión", + "navigation_bar.moderation": "Moderación", "navigation_bar.mutes": "Usuarios silenciados", "navigation_bar.opened_in_classic_interface": "Publicaciones, cuentas y otras páginas específicas se abren por defecto en la interfaz web clásica.", "navigation_bar.personal": "Personal", diff --git a/app/javascript/mastodon/locales/es.json b/app/javascript/mastodon/locales/es.json index 718c145216..85b160d7a8 100644 --- a/app/javascript/mastodon/locales/es.json +++ b/app/javascript/mastodon/locales/es.json @@ -97,6 +97,8 @@ "block_modal.title": "¿Bloquear usuario?", "block_modal.you_wont_see_mentions": "No verás mensajes que los mencionen.", "boost_modal.combo": "Puedes hacer clic en {combo} para saltar este aviso la próxima vez", + "boost_modal.reblog": "¿Impulsar la publicación?", + "boost_modal.undo_reblog": "¿Dejar de impulsar la publicación?", "bundle_column_error.copy_stacktrace": "Copiar informe de error", "bundle_column_error.error.body": "La página solicitada no pudo ser renderizada. Podría deberse a un error en nuestro código o a un problema de compatibilidad con el navegador.", "bundle_column_error.error.title": "¡Oh, no!", @@ -467,6 +469,7 @@ "mute_modal.you_wont_see_mentions": "No verás mensajes que los mencionen.", "mute_modal.you_wont_see_posts": "Todavía pueden ver tus publicaciones, pero tú no verás las suyas.", "navigation_bar.about": "Acerca de", + "navigation_bar.administration": "Administración", "navigation_bar.advanced_interface": "Abrir en la interfaz web avanzada", "navigation_bar.blocks": "Usuarios bloqueados", "navigation_bar.bookmarks": "Marcadores", @@ -483,6 +486,7 @@ "navigation_bar.follows_and_followers": "Siguiendo y seguidores", "navigation_bar.lists": "Listas", "navigation_bar.logout": "Cerrar sesión", + "navigation_bar.moderation": "Moderación", "navigation_bar.mutes": "Usuarios silenciados", "navigation_bar.opened_in_classic_interface": "Publicaciones, cuentas y otras páginas específicas se abren por defecto en la interfaz web clásica.", "navigation_bar.personal": "Personal", diff --git a/app/javascript/mastodon/locales/fr-CA.json b/app/javascript/mastodon/locales/fr-CA.json index 4327ccb366..c0a575637e 100644 --- a/app/javascript/mastodon/locales/fr-CA.json +++ b/app/javascript/mastodon/locales/fr-CA.json @@ -97,6 +97,7 @@ "block_modal.you_wont_see_mentions": "Vous ne verrez pas les publications qui le mentionne.", "boost_modal.combo": "Vous pouvez appuyer sur {combo} pour sauter ceci la prochaine fois", "boost_modal.reblog": "Booster le message ?", + "boost_modal.undo_reblog": "Annuler le boost du message ?", "bundle_column_error.copy_stacktrace": "Copier le rapport d'erreur", "bundle_column_error.error.body": "La page demandée n'a pas pu être affichée. Cela pourrait être dû à un bogue dans notre code, ou à un problème de compatibilité avec le navigateur.", "bundle_column_error.error.title": "Oh non!", @@ -351,8 +352,12 @@ "hashtag.follow": "Suivre ce hashtag", "hashtag.unfollow": "Ne plus suivre ce hashtag", "hashtags.and_other": "…et {count, plural, other {# de plus}}", + "hints.profiles.followers_may_be_missing": "Les abonné·e·s à ce profil peuvent être manquant·e·s.", + "hints.profiles.follows_may_be_missing": "Les abonnements pour ce profil peuvent être manquants.", + "hints.profiles.posts_may_be_missing": "Certains messages de ce profil peuvent être manquants.", "hints.profiles.see_more_followers": "Afficher plus d'abonné·e·s sur {domain}", "hints.profiles.see_more_posts": "Voir plus de messages sur {domain}", + "hints.threads.replies_may_be_missing": "Les réponses provenant des autres serveurs pourraient être manquantes.", "hints.threads.see_more": "Afficher plus de réponses sur {domain}", "home.column_settings.show_reblogs": "Afficher boosts", "home.column_settings.show_replies": "Afficher réponses", diff --git a/app/javascript/mastodon/locales/fr.json b/app/javascript/mastodon/locales/fr.json index e38f5b33ce..ed3533719e 100644 --- a/app/javascript/mastodon/locales/fr.json +++ b/app/javascript/mastodon/locales/fr.json @@ -97,6 +97,7 @@ "block_modal.you_wont_see_mentions": "Vous ne verrez pas les publications qui le mentionne.", "boost_modal.combo": "Vous pouvez appuyer sur {combo} pour passer ceci la prochaine fois", "boost_modal.reblog": "Booster le message ?", + "boost_modal.undo_reblog": "Annuler le boost du message ?", "bundle_column_error.copy_stacktrace": "Copier le rapport d'erreur", "bundle_column_error.error.body": "La page demandée n'a pas pu être affichée. Cela peut être dû à un bogue dans notre code, ou à un problème de compatibilité avec le navigateur.", "bundle_column_error.error.title": "Oh non !", @@ -351,8 +352,12 @@ "hashtag.follow": "Suivre le hashtag", "hashtag.unfollow": "Ne plus suivre le hashtag", "hashtags.and_other": "…et {count, plural, other {# de plus}}", + "hints.profiles.followers_may_be_missing": "Les abonné·e·s à ce profil peuvent être manquant·e·s.", + "hints.profiles.follows_may_be_missing": "Les abonnements pour ce profil peuvent être manquants.", + "hints.profiles.posts_may_be_missing": "Certains messages de ce profil peuvent être manquants.", "hints.profiles.see_more_followers": "Afficher plus d'abonné·e·s sur {domain}", "hints.profiles.see_more_posts": "Voir plus de messages sur {domain}", + "hints.threads.replies_may_be_missing": "Les réponses provenant des autres serveurs pourraient être manquantes.", "hints.threads.see_more": "Afficher plus de réponses sur {domain}", "home.column_settings.show_reblogs": "Afficher les partages", "home.column_settings.show_replies": "Afficher les réponses", diff --git a/app/javascript/mastodon/locales/ja.json b/app/javascript/mastodon/locales/ja.json index 86ba4ad64d..f24b54aa48 100644 --- a/app/javascript/mastodon/locales/ja.json +++ b/app/javascript/mastodon/locales/ja.json @@ -97,6 +97,8 @@ "block_modal.title": "ユーザーをブロックしますか?", "block_modal.you_wont_see_mentions": "宛先に相手が入っている投稿も閲覧できなくなります。", "boost_modal.combo": "次からは{combo}を押せばスキップできます", + "boost_modal.reblog": "ブーストしますか?", + "boost_modal.undo_reblog": "ブーストを解除しますか?", "bundle_column_error.copy_stacktrace": "エラーレポートをコピー", "bundle_column_error.error.body": "要求されたページをレンダリングできませんでした。コードのバグ、またはブラウザの互換性の問題が原因である可能性があります。", "bundle_column_error.error.title": "おっと!", @@ -498,9 +500,18 @@ "notification.admin.report_statuses": "{name}さんが{target}さんを「{category}」として通報しました", "notification.admin.report_statuses_other": "{name}さんが{target}さんを通報しました", "notification.admin.sign_up": "{name}さんがサインアップしました", + "notification.admin.sign_up.name_and_others": "{name}さんほか{count, plural, other {#人}}がサインアップしました", "notification.favourite": "{name}さんがお気に入りしました", + "notification.favourite.name_and_others_with_link": "{name}さんほか{count, plural, other {#人}}がお気に入りしました", "notification.follow": "{name}さんにフォローされました", + "notification.follow.name_and_others": "{name}さんほか{count, plural, other {#人}}にフォローされました", "notification.follow_request": "{name}さんがあなたにフォローリクエストしました", + "notification.follow_request.name_and_others": "{name}さんほか{count, plural, other {#人}}があなたにフォローリクエストしました", + "notification.label.mention": "メンション", + "notification.label.private_mention": "非公開の返信 (メンション)", + "notification.label.private_reply": "非公開の返信", + "notification.label.reply": "返信", + "notification.mention": "メンション", "notification.moderation-warning.learn_more": "さらに詳しく", "notification.moderation_warning": "管理者から警告が来ています", "notification.moderation_warning.action_delete_statuses": "あなたによるいくつかの投稿が削除されました。", @@ -513,6 +524,7 @@ "notification.own_poll": "アンケートが終了しました", "notification.poll": "投票したアンケートが終了しました", "notification.reblog": "{name}さんがあなたの投稿をブーストしました", + "notification.reblog.name_and_others_with_link": "{name}さんほか{count, plural, other {#人}}にブーストされました", "notification.relationships_severance_event": "{name} との関係が失われました", "notification.relationships_severance_event.account_suspension": "{from} の管理者が {target} さんを停止したため、今後このユーザーとの交流や新しい投稿の受け取りができなくなりました。", "notification.relationships_severance_event.domain_block": "{from} の管理者が {target} をブロックしました。これにより{followersCount}フォロワーと{followingCount, plural, other {#フォロー}}が失われました。", @@ -588,7 +600,7 @@ "notifications.policy.filter_not_followers_title": "フォローされていないアカウントからの通知", "notifications.policy.filter_not_following_hint": "手動で通知を受け入れたアカウントは対象外です", "notifications.policy.filter_not_following_title": "フォローしていないアカウントからの通知", - "notifications.policy.filter_private_mentions_hint": "あなたがメンションした相手からの返信、およびフォローしているアカウントからの返信は対象外です", + "notifications.policy.filter_private_mentions_hint": "メンションした相手からの返信、およびフォローしているアカウントからの返信は対象外です", "notifications.policy.filter_private_mentions_title": "外部からの非公開の返信", "notifications.policy.title": "通知のフィルタリング", "notifications_permission_banner.enable": "デスクトップ通知を有効にする", diff --git a/app/javascript/mastodon/locales/ru.json b/app/javascript/mastodon/locales/ru.json index 94f82e422d..cd64e8b8e5 100644 --- a/app/javascript/mastodon/locales/ru.json +++ b/app/javascript/mastodon/locales/ru.json @@ -189,6 +189,7 @@ "confirmations.unfollow.confirm": "Отписаться", "confirmations.unfollow.message": "Вы уверены, что хотите отписаться от {name}?", "confirmations.unfollow.title": "Отписаться?", + "content_warning.hide": "Скрыть пост", "conversation.delete": "Удалить беседу", "conversation.mark_as_read": "Отметить как прочитанное", "conversation.open": "Просмотр беседы", diff --git a/app/javascript/mastodon/locales/ry.json b/app/javascript/mastodon/locales/ry.json index b33b95fe51..02d1c005cf 100644 --- a/app/javascript/mastodon/locales/ry.json +++ b/app/javascript/mastodon/locales/ry.json @@ -148,6 +148,11 @@ "compose_form.publish_form": "Нова публикація", "compose_form.reply": "Удповідь", "compose_form.save_changes": "Усокотити", + "confirmations.logout.confirm": "Уйти гет", + "confirmations.logout.message": "Бизувні сьте ож хочете уйти?", + "confirmations.logout.title": "Уйти гет?", + "confirmations.mute.confirm": "Стишити", + "confirmations.reply.confirm": "Удповісти", "copypaste.copy_to_clipboard": "Копіровати у памнять", "directory.recently_active": "Недавно актівні", "disabled_account_banner.account_settings": "Штімованя акаунта", diff --git a/config/locales/es.yml b/config/locales/es.yml index dc52d8113d..0bbad767e3 100644 --- a/config/locales/es.yml +++ b/config/locales/es.yml @@ -1091,7 +1091,7 @@ es: proceed_to_login_html: Ahora puedes proceder a %{login_link}. redirect_to_app_html: Serás redirigido a la aplicación %{app_name}. Si esto no sucede, prueba %{clicking_this_link} o regresa manualmente a la aplicación. registration_complete: "¡Has completado tu registro en %{domain}!" - welcome_title: "¡Bienvenido, %{name}!" + welcome_title: "¡Te damos la bienvenida, %{name}!" wrong_email_hint: Si esa dirección de correo electrónico no es correcta, puedes cambiarla en la configuración de la cuenta. delete_account: Borrar cuenta delete_account_html: Si desea eliminar su cuenta, puede proceder aquí. Será pedido de una confirmación. @@ -1913,7 +1913,7 @@ es: follow_action: Seguir follow_step: Seguir a personas interesantes es de lo que trata Mastodon. follow_title: Personaliza tu línea de inicio - follows_subtitle: Seguir cuentas conocidas + follows_subtitle: Sigue a cuentas conocidas follows_title: A quién seguir follows_view_more: Ver más personas para seguir hashtags_recent_count: diff --git a/config/locales/fr-CA.yml b/config/locales/fr-CA.yml index 52b3515725..c38435c7fb 100644 --- a/config/locales/fr-CA.yml +++ b/config/locales/fr-CA.yml @@ -31,6 +31,7 @@ fr-CA: created_msg: Note de modération créée avec succès ! destroyed_msg: Note de modération supprimée avec succès ! accounts: + add_email_domain_block: Bloquer le domaine de messagerie approve: Approuver approved_msg: La demande d’inscription de %{username} a été approuvée avec succès are_you_sure: Voulez-vous vraiment faire ça ? @@ -860,6 +861,14 @@ fr-CA: action: Pour plus d'informations, cliquez ici message_html: "Votre serveur web est mal configuré. La confidentialité de vos utilisateurs est en péril." tags: + moderation: + not_usable: Non utilisable + pending_review: En attente de traitement + review_requested: Révision requise + reviewed: Traité + title: État + unreviewed: Non traité + usable: Utilisable name: Nom newest: Plus récents oldest: Plus anciens diff --git a/config/locales/fr.yml b/config/locales/fr.yml index d7830bfe33..42554aeb39 100644 --- a/config/locales/fr.yml +++ b/config/locales/fr.yml @@ -31,6 +31,7 @@ fr: created_msg: Note de modération créée avec succès ! destroyed_msg: Note de modération supprimée avec succès ! accounts: + add_email_domain_block: Bloquer le domaine de messagerie approve: Approuver approved_msg: La demande d’inscription de %{username} a été approuvée avec succès are_you_sure: Voulez-vous vraiment faire ça ? @@ -860,6 +861,14 @@ fr: action: Pour plus d'informations, cliquez ici message_html: "Votre serveur web est mal configuré. La confidentialité de vos utilisateurs est en péril." tags: + moderation: + not_usable: Non utilisable + pending_review: En attente de traitement + review_requested: Révision requise + reviewed: Traité + title: État + unreviewed: Non traité + usable: Utilisable name: Nom newest: Plus récents oldest: Plus anciens diff --git a/config/locales/ja.yml b/config/locales/ja.yml index a6b4822c58..ec7216b001 100644 --- a/config/locales/ja.yml +++ b/config/locales/ja.yml @@ -404,6 +404,7 @@ ja: allow_registrations_with_approval: 承認制での新規登録を可能にする attempts_over_week: other: 先週は%{count}回サインアップが試みられました + created_msg: メールドメインブロックを追加しました delete: 消去 dns: types: @@ -412,8 +413,12 @@ ja: new: create: ドメインを追加 resolve: ドメイン解決 + title: 新規メールドメインブロック + no_email_domain_block_selected: 変更対象のメールドメインブロックを選択してください not_permitted: 権限がありません + resolved_dns_records_hint_html: 入力されたドメイン名のMXレコードから以下のドメインが解決されました。MXレコードが指すドメインはメールの送受信において重要な役割をもっています。MXレコードのドメインをブロックすると、見た目のドメインが異なるメールアドレスからの登録であっても、そのドメイン名から解決されるMXレコードのドメインが同じ場合はブロックの対象になります。大手のメールプロバイダをブロックしないように注意してください。 resolved_through_html: "%{domain}を通して解決しました" + title: メールドメインブロック export_domain_allows: new: title: ドメイン許可をインポート @@ -900,6 +905,7 @@ ja: usage_comparison: 今日は%{today}回、昨日は%{yesterday}回使用されました。 used_by_over_week: other: 週間%{count}人に使用されました + title: おすすめとトレンド trending: トレンド warning_presets: add_new: 追加 @@ -1340,6 +1346,16 @@ ja: unsubscribe: action: 購読を解除する complete: 購読を解除しました + confirmation_html: Mastodon (%{domain}) による %{email} 宛の「%{type}」の配信を停止します。再度必要になった場合はメール通知の設定からいつでも再開できます。 + emails: + notification_emails: + favourite: お気に入りの通知メール + follow: フォローの通知メール + follow_request: フォローリクエストの通知メール + mention: 返信の通知メール + reblog: ブーストの通知メール + resubscribe_html: 誤って解除した場合はメール通知の設定から再購読できます。 + success_html: Mastodon (%{domain}) から %{email} への「%{type}」の配信が停止されました。 title: 購読の解除 media_attachments: validations: @@ -1578,6 +1594,7 @@ ja: import: データのインポート import_and_export: インポート・エクスポート migrate: アカウントの引っ越し + notifications: メール通知 preferences: ユーザー設定 profile: プロフィール relationships: フォロー・フォロワー From 1ee1c329cc12fa7a167eb312d6c91693f56327d9 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Fri, 30 Aug 2024 03:15:28 -0400 Subject: [PATCH 017/153] Convert `admin/announcements` controller spec to system spec (#31655) --- .../announcements/_announcement.html.haml | 2 +- .../admin/announcements_controller_spec.rb | 102 ------------- spec/system/admin/announcements_spec.rb | 134 ++++++++++++++++++ 3 files changed, 135 insertions(+), 103 deletions(-) delete mode 100644 spec/controllers/admin/announcements_controller_spec.rb create mode 100644 spec/system/admin/announcements_spec.rb diff --git a/app/views/admin/announcements/_announcement.html.haml b/app/views/admin/announcements/_announcement.html.haml index eac78efb28..8190f87d2f 100644 --- a/app/views/admin/announcements/_announcement.html.haml +++ b/app/views/admin/announcements/_announcement.html.haml @@ -1,4 +1,4 @@ -.announcements-list__item +.announcements-list__item{ id: dom_id(announcement) } = link_to edit_admin_announcement_path(announcement), class: 'announcements-list__item__title' do = truncate(announcement.text) diff --git a/spec/controllers/admin/announcements_controller_spec.rb b/spec/controllers/admin/announcements_controller_spec.rb deleted file mode 100644 index c2d3135d92..0000000000 --- a/spec/controllers/admin/announcements_controller_spec.rb +++ /dev/null @@ -1,102 +0,0 @@ -# frozen_string_literal: true - -require 'rails_helper' - -describe Admin::AnnouncementsController do - render_views - - let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } - - before do - sign_in user, scope: :user - end - - describe 'GET #index' do - it 'returns http success' do - get :index - - expect(response).to have_http_status(:success) - end - end - - describe 'GET #new' do - it 'returns http success and renders new' do - get :new - - expect(response).to have_http_status(:success) - expect(response).to render_template(:new) - end - end - - describe 'GET #edit' do - let(:announcement) { Fabricate(:announcement) } - - it 'returns http success and renders edit' do - get :edit, params: { id: announcement.id } - - expect(response).to have_http_status(:success) - expect(response).to render_template(:edit) - end - end - - describe 'POST #create' do - it 'creates a new announcement and redirects' do - expect do - post :create, params: { announcement: { text: 'The announcement message.' } } - end.to change(Announcement, :count).by(1) - - expect(response).to redirect_to(admin_announcements_path) - expect(flash.notice).to match(I18n.t('admin.announcements.published_msg')) - end - end - - describe 'PUT #update' do - let(:announcement) { Fabricate(:announcement, text: 'Original text') } - - it 'updates an announcement and redirects' do - put :update, params: { id: announcement.id, announcement: { text: 'Updated text.' } } - - expect(response).to redirect_to(admin_announcements_path) - expect(flash.notice).to match(I18n.t('admin.announcements.updated_msg')) - end - end - - describe 'DELETE #destroy' do - let!(:announcement) { Fabricate(:announcement, text: 'Original text') } - - it 'destroys an announcement and redirects' do - expect do - delete :destroy, params: { id: announcement.id } - end.to change(Announcement, :count).by(-1) - - expect(response).to redirect_to(admin_announcements_path) - expect(flash.notice).to match(I18n.t('admin.announcements.destroyed_msg')) - end - end - - describe 'POST #publish' do - subject { post :publish, params: { id: announcement.id } } - - let(:announcement) { Fabricate(:announcement, published_at: nil) } - - it 'marks announcement published' do - subject - - expect(announcement.reload).to be_published - expect(response).to redirect_to admin_announcements_path - end - end - - describe 'POST #unpublish' do - subject { post :unpublish, params: { id: announcement.id } } - - let(:announcement) { Fabricate(:announcement, published_at: 4.days.ago) } - - it 'marks announcement as not published' do - subject - - expect(announcement.reload).to_not be_published - expect(response).to redirect_to admin_announcements_path - end - end -end diff --git a/spec/system/admin/announcements_spec.rb b/spec/system/admin/announcements_spec.rb new file mode 100644 index 0000000000..5c4e5d3e6a --- /dev/null +++ b/spec/system/admin/announcements_spec.rb @@ -0,0 +1,134 @@ +# frozen_string_literal: true + +require 'rails_helper' + +describe 'Admin::Announcements' do + include ActionView::RecordIdentifier + + describe 'Viewing announcements' do + it 'can view a list of existing announcements' do + announcement = Fabricate :announcement, text: 'Test Announcement' + sign_in admin_user + visit admin_announcements_path + + within css_id(announcement) do + expect(page) + .to have_content(announcement.text) + end + end + end + + describe 'Creating announcements' do + it 'create a new announcement' do + sign_in admin_user + visit new_admin_announcement_path + + fill_in text_label, + with: 'Announcement text' + + expect { submit_form } + .to change(Announcement, :count).by(1) + expect(page) + .to have_content(I18n.t('admin.announcements.published_msg')) + end + end + + describe 'Updating announcements' do + it 'updates an existing announcement' do + announcement = Fabricate :announcement, text: 'Test Announcement' + sign_in admin_user + visit admin_announcements_path + + within css_id(announcement) do + click_on announcement.text + end + + fill_in text_label, + with: 'Announcement text' + save_changes + + expect(page) + .to have_content(I18n.t('admin.announcements.updated_msg')) + end + end + + describe 'Deleting announcements' do + it 'deletes an existing announcement' do + announcement = Fabricate :announcement, text: 'Test Announcement' + sign_in admin_user + visit admin_announcements_path + + expect { delete_announcement(announcement) } + .to change(Announcement, :count).by(-1) + + expect(page) + .to have_content(I18n.t('admin.announcements.destroyed_msg')) + end + end + + describe 'Publishing announcements' do + it 'publishes an existing announcement' do + announcement = Fabricate :announcement, published: false, scheduled_at: 10.days.from_now + sign_in admin_user + visit admin_announcements_path + + expect { publish_announcement(announcement) } + .to change { announcement.reload.published? }.to(true) + + expect(page) + .to have_content(I18n.t('admin.announcements.published_msg')) + end + + it 'unpublishes an existing announcement' do + announcement = Fabricate :announcement, published: true + sign_in admin_user + visit admin_announcements_path + + expect { unpublish_announcement(announcement) } + .to change { announcement.reload.published? }.to(false) + + expect(page) + .to have_content(I18n.t('admin.announcements.unpublished_msg')) + end + end + + private + + def css_id(record) + "##{dom_id(record)}" # TODO: Extract to system spec helper? + end + + def publish_announcement(announcement) + within css_id(announcement) do + click_on I18n.t('admin.announcements.publish') + end + end + + def unpublish_announcement(announcement) + within css_id(announcement) do + click_on I18n.t('admin.announcements.unpublish') + end + end + + def delete_announcement(announcement) + within css_id(announcement) do + click_on I18n.t('generic.delete') + end + end + + def save_changes + click_on I18n.t('generic.save_changes') + end + + def submit_form + click_on I18n.t('admin.announcements.new.create') + end + + def text_label + I18n.t('simple_form.labels.announcement.text') + end + + def admin_user + Fabricate(:user, role: UserRole.find_by(name: 'Admin')) + end +end From 35538fe694765d0fa20bb85047680704f85be795 Mon Sep 17 00:00:00 2001 From: Claire Date: Fri, 30 Aug 2024 11:37:39 +0200 Subject: [PATCH 018/153] Fix inconsistencies between code and notification source translation strings (#31658) --- .../features/notifications/components/notification.jsx | 8 ++++---- .../components/notification_favourite.tsx | 2 +- .../notifications_v2/components/notification_reblog.tsx | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/app/javascript/mastodon/features/notifications/components/notification.jsx b/app/javascript/mastodon/features/notifications/components/notification.jsx index f1eada1359..7e3a860e3e 100644 --- a/app/javascript/mastodon/features/notifications/components/notification.jsx +++ b/app/javascript/mastodon/features/notifications/components/notification.jsx @@ -31,11 +31,11 @@ import { RelationshipsSeveranceEvent } from './relationships_severance_event'; import Report from './report'; const messages = defineMessages({ - favourite: { id: 'notification.favourite', defaultMessage: '{name} favorited your status' }, + favourite: { id: 'notification.favourite', defaultMessage: '{name} favorited your post' }, follow: { id: 'notification.follow', defaultMessage: '{name} followed you' }, ownPoll: { id: 'notification.own_poll', defaultMessage: 'Your poll has ended' }, poll: { id: 'notification.poll', defaultMessage: 'A poll you voted in has ended' }, - reblog: { id: 'notification.reblog', defaultMessage: '{name} boosted your status' }, + reblog: { id: 'notification.reblog', defaultMessage: '{name} boosted your post' }, status: { id: 'notification.status', defaultMessage: '{name} just posted' }, update: { id: 'notification.update', defaultMessage: '{name} edited a post' }, adminSignUp: { id: 'notification.admin.sign_up', defaultMessage: '{name} signed up' }, @@ -201,7 +201,7 @@ class Notification extends ImmutablePureComponent { - + @@ -231,7 +231,7 @@ class Notification extends ImmutablePureComponent { - + diff --git a/app/javascript/mastodon/features/notifications_v2/components/notification_favourite.tsx b/app/javascript/mastodon/features/notifications_v2/components/notification_favourite.tsx index eba37fe937..49866540e5 100644 --- a/app/javascript/mastodon/features/notifications_v2/components/notification_favourite.tsx +++ b/app/javascript/mastodon/features/notifications_v2/components/notification_favourite.tsx @@ -14,7 +14,7 @@ const labelRenderer: LabelRenderer = (displayedName, total, seeMoreHref) => { return ( ); diff --git a/app/javascript/mastodon/features/notifications_v2/components/notification_reblog.tsx b/app/javascript/mastodon/features/notifications_v2/components/notification_reblog.tsx index 7b3bda85e5..36a798032b 100644 --- a/app/javascript/mastodon/features/notifications_v2/components/notification_reblog.tsx +++ b/app/javascript/mastodon/features/notifications_v2/components/notification_reblog.tsx @@ -14,7 +14,7 @@ const labelRenderer: LabelRenderer = (displayedName, total, seeMoreHref) => { return ( ); From 3ddeaca863999270719752aff49d55d73ae5f412 Mon Sep 17 00:00:00 2001 From: Claire Date: Fri, 30 Aug 2024 11:42:48 +0200 Subject: [PATCH 019/153] Change background color of notifications on private messages (#31657) --- .../components/notification_group_with_status.tsx | 11 +++++++++-- app/javascript/styles/mastodon/components.scss | 3 ++- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/app/javascript/mastodon/features/notifications_v2/components/notification_group_with_status.tsx b/app/javascript/mastodon/features/notifications_v2/components/notification_group_with_status.tsx index 343a9bc4c1..91f8ae2d40 100644 --- a/app/javascript/mastodon/features/notifications_v2/components/notification_group_with_status.tsx +++ b/app/javascript/mastodon/features/notifications_v2/components/notification_group_with_status.tsx @@ -9,7 +9,7 @@ import { navigateToStatus } from 'mastodon/actions/statuses'; import type { IconProp } from 'mastodon/components/icon'; import { Icon } from 'mastodon/components/icon'; import { RelativeTimestamp } from 'mastodon/components/relative_timestamp'; -import { useAppDispatch } from 'mastodon/store'; +import { useAppSelector, useAppDispatch } from 'mastodon/store'; import { AvatarGroup } from './avatar_group'; import { DisplayedName } from './displayed_name'; @@ -60,6 +60,10 @@ export const NotificationGroupWithStatus: React.FC<{ [labelRenderer, accountIds, count, labelSeeMoreHref], ); + const isPrivateMention = useAppSelector( + (state) => state.statuses.getIn([statusId, 'visibility']) === 'direct', + ); + const handlers = useMemo( () => ({ open: () => { @@ -79,7 +83,10 @@ export const NotificationGroupWithStatus: React.FC<{ role='button' className={classNames( `notification-group focusable notification-group--${type}`, - { 'notification-group--unread': unread }, + { + 'notification-group--unread': unread, + 'notification-group--direct': isPrivateMention, + }, )} tabIndex={0} > diff --git a/app/javascript/styles/mastodon/components.scss b/app/javascript/styles/mastodon/components.scss index 0b0cbbfa84..208cdd6768 100644 --- a/app/javascript/styles/mastodon/components.scss +++ b/app/javascript/styles/mastodon/components.scss @@ -1626,7 +1626,8 @@ body > [data-popper-placement] { } .status__wrapper-direct, -.notification-ungrouped--direct { +.notification-ungrouped--direct, +.notification-group--direct { background: rgba($ui-highlight-color, 0.05); &:focus { From 85e8d1f2859742c3f455ed6b70ba06b4ee86d249 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Fri, 30 Aug 2024 05:46:09 -0400 Subject: [PATCH 020/153] Use rails configuration storage for paperclip path (#31651) --- config/initializers/paperclip.rb | 3 ++- lib/mastodon/cli/media.rb | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/config/initializers/paperclip.rb b/config/initializers/paperclip.rb index 6b14985ae3..ed16d50a76 100644 --- a/config/initializers/paperclip.rb +++ b/config/initializers/paperclip.rb @@ -160,9 +160,10 @@ elsif ENV['AZURE_ENABLED'] == 'true' ) end else + Rails.configuration.x.file_storage_root_path = ENV.fetch('PAPERCLIP_ROOT_PATH', File.join(':rails_root', 'public', 'system')) Paperclip::Attachment.default_options.merge!( storage: :filesystem, - path: File.join(ENV.fetch('PAPERCLIP_ROOT_PATH', File.join(':rails_root', 'public', 'system')), ':prefix_path:class', ':attachment', ':id_partition', ':style', ':filename'), + path: File.join(Rails.configuration.x.file_storage_root_path, ':prefix_path:class', ':attachment', ':id_partition', ':style', ':filename'), url: ENV.fetch('PAPERCLIP_ROOT_URL', '/system') + "/#{PATH}" ) end diff --git a/lib/mastodon/cli/media.rb b/lib/mastodon/cli/media.rb index 123973d195..70c11ee1a1 100644 --- a/lib/mastodon/cli/media.rb +++ b/lib/mastodon/cli/media.rb @@ -157,7 +157,7 @@ module Mastodon::CLI when :filesystem require 'find' - root_path = ENV.fetch('PAPERCLIP_ROOT_PATH', File.join(':rails_root', 'public', 'system')).gsub(':rails_root', Rails.root.to_s) + root_path = Rails.configuration.x.file_storage_root_path.gsub(':rails_root', Rails.root.to_s) Find.find(File.join(*[root_path, prefix].compact)) do |path| next if File.directory?(path) From 3655e3204fbf70d14ce60e4aa67a331e63668e62 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Fri, 30 Aug 2024 09:46:53 +0000 Subject: [PATCH 021/153] Update dependency @babel/runtime to v7.25.6 (#31649) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index b5c44fd306..5596ed536d 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1487,11 +1487,11 @@ __metadata: linkType: hard "@babel/runtime@npm:^7.0.0, @babel/runtime@npm:^7.1.2, @babel/runtime@npm:^7.11.2, @babel/runtime@npm:^7.12.0, @babel/runtime@npm:^7.12.13, @babel/runtime@npm:^7.12.5, @babel/runtime@npm:^7.13.8, @babel/runtime@npm:^7.18.3, @babel/runtime@npm:^7.2.0, @babel/runtime@npm:^7.20.13, @babel/runtime@npm:^7.22.3, @babel/runtime@npm:^7.3.1, @babel/runtime@npm:^7.5.5, @babel/runtime@npm:^7.6.3, @babel/runtime@npm:^7.8.4, @babel/runtime@npm:^7.8.7, @babel/runtime@npm:^7.9.2": - version: 7.25.4 - resolution: "@babel/runtime@npm:7.25.4" + version: 7.25.6 + resolution: "@babel/runtime@npm:7.25.6" dependencies: regenerator-runtime: "npm:^0.14.0" - checksum: 10c0/33e937e685f0bfc2d40c219261e2e50d0df7381a6e7cbf56b770e0c5d77cb0c21bf4d97da566cf0164317ed7508e992082c7b6cce7aaa3b17da5794f93fbfb46 + checksum: 10c0/d6143adf5aa1ce79ed374e33fdfd74fa975055a80bc6e479672ab1eadc4e4bfd7484444e17dd063a1d180e051f3ec62b357c7a2b817e7657687b47313158c3d2 languageName: node linkType: hard From 02633d6ebbe944a8769c8f2229fa9e0d6c7d1142 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Fri, 30 Aug 2024 09:48:54 +0000 Subject: [PATCH 022/153] Update dependency jsdom to v25 (#31578) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- streaming/package.json | 2 +- yarn.lock | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/streaming/package.json b/streaming/package.json index 444d9483e4..64947749a1 100644 --- a/streaming/package.json +++ b/streaming/package.json @@ -21,7 +21,7 @@ "dotenv": "^16.0.3", "express": "^4.18.2", "ioredis": "^5.3.2", - "jsdom": "^24.0.0", + "jsdom": "^25.0.0", "pg": "^8.5.0", "pg-connection-string": "^2.6.0", "pino": "^9.0.0", diff --git a/yarn.lock b/yarn.lock index 5596ed536d..49373fb3ca 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2926,7 +2926,7 @@ __metadata: eslint-define-config: "npm:^2.0.0" express: "npm:^4.18.2" ioredis: "npm:^5.3.2" - jsdom: "npm:^24.0.0" + jsdom: "npm:^25.0.0" pg: "npm:^8.5.0" pg-connection-string: "npm:^2.6.0" pino: "npm:^9.0.0" @@ -11060,9 +11060,9 @@ __metadata: languageName: node linkType: hard -"jsdom@npm:^24.0.0": - version: 24.1.3 - resolution: "jsdom@npm:24.1.3" +"jsdom@npm:^25.0.0": + version: 25.0.0 + resolution: "jsdom@npm:25.0.0" dependencies: cssstyle: "npm:^4.0.1" data-urls: "npm:^5.0.0" @@ -11090,7 +11090,7 @@ __metadata: peerDependenciesMeta: canvas: optional: true - checksum: 10c0/e48b342afacd7418a23dac204a62deea729c50f4d072a7c04c09fd32355fdb4335f8779fa79fd0277a2dbeb2d356250a950955719d00047324b251233b11277f + checksum: 10c0/1552bcfb816b2c69ae159ba0cd79e8964030c106cc0cb2deb20a64c1ca54e1ea41352b9802d89b7cf823e43e6d74ed7289abff4aacc95b1b2bc936570aab3594 languageName: node linkType: hard From 4f1da814a873608f8dd5d14ff7ec011c80876013 Mon Sep 17 00:00:00 2001 From: Claire Date: Fri, 30 Aug 2024 11:37:39 +0200 Subject: [PATCH 023/153] [Glitch] Fix inconsistencies between code and notification source translation strings Port 35538fe694765d0fa20bb85047680704f85be795 to glitch-soc Signed-off-by: Claire --- app/javascript/flavours/glitch/components/status_prepend.jsx | 4 ++-- .../notifications_v2/components/notification_favourite.tsx | 2 +- .../notifications_v2/components/notification_reblog.tsx | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/app/javascript/flavours/glitch/components/status_prepend.jsx b/app/javascript/flavours/glitch/components/status_prepend.jsx index 0777ffcda6..4756b36696 100644 --- a/app/javascript/flavours/glitch/components/status_prepend.jsx +++ b/app/javascript/flavours/glitch/components/status_prepend.jsx @@ -66,7 +66,7 @@ export default class StatusPrepend extends PureComponent { return ( ); @@ -74,7 +74,7 @@ export default class StatusPrepend extends PureComponent { return ( ); diff --git a/app/javascript/flavours/glitch/features/notifications_v2/components/notification_favourite.tsx b/app/javascript/flavours/glitch/features/notifications_v2/components/notification_favourite.tsx index ad01f622f6..e2aae3c8e6 100644 --- a/app/javascript/flavours/glitch/features/notifications_v2/components/notification_favourite.tsx +++ b/app/javascript/flavours/glitch/features/notifications_v2/components/notification_favourite.tsx @@ -14,7 +14,7 @@ const labelRenderer: LabelRenderer = (displayedName, total, seeMoreHref) => { return ( ); diff --git a/app/javascript/flavours/glitch/features/notifications_v2/components/notification_reblog.tsx b/app/javascript/flavours/glitch/features/notifications_v2/components/notification_reblog.tsx index 1029bae33c..525037d095 100644 --- a/app/javascript/flavours/glitch/features/notifications_v2/components/notification_reblog.tsx +++ b/app/javascript/flavours/glitch/features/notifications_v2/components/notification_reblog.tsx @@ -14,7 +14,7 @@ const labelRenderer: LabelRenderer = (displayedName, total, seeMoreHref) => { return ( ); From ee2c38fcb8141584644928ece32461768a59fba4 Mon Sep 17 00:00:00 2001 From: Claire Date: Fri, 30 Aug 2024 11:42:48 +0200 Subject: [PATCH 024/153] [Glitch] Change background color of notifications on private messages Port 3ddeaca863999270719752aff49d55d73ae5f412 to glitch-soc Signed-off-by: Claire --- .../components/notification_group_with_status.tsx | 11 +++++++++-- app/javascript/flavours/glitch/styles/components.scss | 3 ++- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/app/javascript/flavours/glitch/features/notifications_v2/components/notification_group_with_status.tsx b/app/javascript/flavours/glitch/features/notifications_v2/components/notification_group_with_status.tsx index 233caaf65e..99045fa53b 100644 --- a/app/javascript/flavours/glitch/features/notifications_v2/components/notification_group_with_status.tsx +++ b/app/javascript/flavours/glitch/features/notifications_v2/components/notification_group_with_status.tsx @@ -9,7 +9,7 @@ import { navigateToStatus } from 'flavours/glitch/actions/statuses'; import type { IconProp } from 'flavours/glitch/components/icon'; import { Icon } from 'flavours/glitch/components/icon'; import { RelativeTimestamp } from 'flavours/glitch/components/relative_timestamp'; -import { useAppDispatch } from 'flavours/glitch/store'; +import { useAppSelector, useAppDispatch } from 'flavours/glitch/store'; import { AvatarGroup } from './avatar_group'; import { DisplayedName } from './displayed_name'; @@ -60,6 +60,10 @@ export const NotificationGroupWithStatus: React.FC<{ [labelRenderer, accountIds, count, labelSeeMoreHref], ); + const isPrivateMention = useAppSelector( + (state) => state.statuses.getIn([statusId, 'visibility']) === 'direct', + ); + const handlers = useMemo( () => ({ open: () => { @@ -79,7 +83,10 @@ export const NotificationGroupWithStatus: React.FC<{ role='button' className={classNames( `notification-group focusable notification-group--${type}`, - { 'notification-group--unread': unread }, + { + 'notification-group--unread': unread, + 'notification-group--direct': isPrivateMention, + }, )} tabIndex={0} > diff --git a/app/javascript/flavours/glitch/styles/components.scss b/app/javascript/flavours/glitch/styles/components.scss index 662607a7ca..ca841b5e47 100644 --- a/app/javascript/flavours/glitch/styles/components.scss +++ b/app/javascript/flavours/glitch/styles/components.scss @@ -1795,7 +1795,8 @@ body > [data-popper-placement] { } .status__wrapper-direct, -.notification-ungrouped--direct { +.notification-ungrouped--direct, +.notification-group--direct { background: rgba($ui-highlight-color, 0.05); &:focus { From 5f8f8cc98f5101db827ffd9e264ed32ba4b7bd85 Mon Sep 17 00:00:00 2001 From: Claire Date: Sat, 31 Aug 2024 17:33:06 +0200 Subject: [PATCH 025/153] Fix crowdin upload workflow not running on glitch-soc (#2830) --- .github/workflows/crowdin-upload.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/crowdin-upload.yml b/.github/workflows/crowdin-upload.yml index 5c20faf3be..d07f661ace 100644 --- a/.github/workflows/crowdin-upload.yml +++ b/.github/workflows/crowdin-upload.yml @@ -19,7 +19,7 @@ on: jobs: upload-translations: runs-on: ubuntu-latest - if: github.repository == 'mastodon/mastodon' + if: github.repository == 'glitch-soc/mastodon' steps: - name: Checkout From b06907e4e4725cf28dc53d65e5e166a16e2b814c Mon Sep 17 00:00:00 2001 From: Claire Date: Sat, 31 Aug 2024 18:41:25 +0200 Subject: [PATCH 026/153] Rewrite favourite modal as a Typescript functional component, use revamped design (#2831) --- .../ui/components/favourite_modal.jsx | 92 ------------------- .../ui/components/favourite_modal.tsx | 90 ++++++++++++++++++ .../features/ui/components/modal_root.jsx | 2 +- .../flavours/glitch/locales/en.json | 2 +- 4 files changed, 92 insertions(+), 94 deletions(-) delete mode 100644 app/javascript/flavours/glitch/features/ui/components/favourite_modal.jsx create mode 100644 app/javascript/flavours/glitch/features/ui/components/favourite_modal.tsx diff --git a/app/javascript/flavours/glitch/features/ui/components/favourite_modal.jsx b/app/javascript/flavours/glitch/features/ui/components/favourite_modal.jsx deleted file mode 100644 index 138f44f21c..0000000000 --- a/app/javascript/flavours/glitch/features/ui/components/favourite_modal.jsx +++ /dev/null @@ -1,92 +0,0 @@ -import PropTypes from 'prop-types'; - -import { defineMessages, injectIntl, FormattedMessage } from 'react-intl'; - -import classNames from 'classnames'; -import { withRouter } from 'react-router-dom'; - -import ImmutablePropTypes from 'react-immutable-proptypes'; -import ImmutablePureComponent from 'react-immutable-pure-component'; - -import StarIcon from '@/material-icons/400-24px/star-fill.svg?react'; -import AttachmentList from 'flavours/glitch/components/attachment_list'; -import { Avatar } from 'flavours/glitch/components/avatar'; -import { Button } from 'flavours/glitch/components/button'; -import { DisplayName } from 'flavours/glitch/components/display_name'; -import { Icon } from 'flavours/glitch/components/icon'; -import { RelativeTimestamp } from 'flavours/glitch/components/relative_timestamp'; -import StatusContent from 'flavours/glitch/components/status_content'; -import { VisibilityIcon } from 'flavours/glitch/components/visibility_icon'; -import { WithRouterPropTypes } from 'flavours/glitch/utils/react_router'; - -const messages = defineMessages({ - favourite: { id: 'status.favourite', defaultMessage: 'Favorite' }, -}); - -class FavouriteModal extends ImmutablePureComponent { - - static propTypes = { - status: ImmutablePropTypes.map.isRequired, - onFavourite: PropTypes.func.isRequired, - onClose: PropTypes.func.isRequired, - intl: PropTypes.object.isRequired, - ...WithRouterPropTypes, - }; - - handleFavourite = () => { - this.props.onFavourite(this.props.status); - this.props.onClose(); - }; - - handleAccountClick = (e) => { - if (e.button === 0) { - e.preventDefault(); - this.props.onClose(); - this.props.history.push(`/@${this.props.status.getIn(['account', 'acct'])}`); - } - }; - - render () { - const { status, intl } = this.props; - - return ( -
-
-
- - - - - {status.get('media_attachments').size > 0 && ( - - )} -
-
- -
-
Shift + }} />
-
-
- ); - } - -} - -export default withRouter(injectIntl(FavouriteModal)); diff --git a/app/javascript/flavours/glitch/features/ui/components/favourite_modal.tsx b/app/javascript/flavours/glitch/features/ui/components/favourite_modal.tsx new file mode 100644 index 0000000000..88d8bb91b8 --- /dev/null +++ b/app/javascript/flavours/glitch/features/ui/components/favourite_modal.tsx @@ -0,0 +1,90 @@ +import { useCallback } from 'react'; + +import { defineMessages, FormattedMessage, useIntl } from 'react-intl'; + +import classNames from 'classnames'; + +import StarIcon from '@/material-icons/400-24px/star.svg?react'; +import { Button } from 'flavours/glitch/components/button'; +import { Icon } from 'flavours/glitch/components/icon'; +import { EmbeddedStatus } from 'flavours/glitch/features/notifications_v2/components/embedded_status'; +import type { Status } from 'flavours/glitch/models/status'; + +const messages = defineMessages({ + favourite: { id: 'status.favourite', defaultMessage: 'Favorite' }, +}); + +export const FavouriteModal: React.FC<{ + status: Status; + onClose: () => void; + onFavourite: (status: Status) => void; +}> = ({ status, onFavourite, onClose }) => { + const intl = useIntl(); + + const statusId = status.get('id') as string; + + const handleFavourite = useCallback(() => { + onFavourite(status); + onClose(); + }, [onClose, onFavourite, status]); + + const handleCancel = useCallback(() => { + onClose(); + }, [onClose]); + + return ( +
+
+
+
+ +
+ +
+

+ +

+
+ + Shift+ + + ), + }} + /> +
+
+
+ +
+ +
+
+ +
+
+
+ + + +
+
+
+ ); +}; diff --git a/app/javascript/flavours/glitch/features/ui/components/modal_root.jsx b/app/javascript/flavours/glitch/features/ui/components/modal_root.jsx index 64c6b52c31..83345905be 100644 --- a/app/javascript/flavours/glitch/features/ui/components/modal_root.jsx +++ b/app/javascript/flavours/glitch/features/ui/components/modal_root.jsx @@ -41,7 +41,7 @@ import { } from './confirmation_modals'; import DeprecatedSettingsModal from './deprecated_settings_modal'; import DoodleModal from './doodle_modal'; -import FavouriteModal from './favourite_modal'; +import { FavouriteModal } from './favourite_modal'; import FocalPointModal from './focal_point_modal'; import ImageModal from './image_modal'; import MediaModal from './media_modal'; diff --git a/app/javascript/flavours/glitch/locales/en.json b/app/javascript/flavours/glitch/locales/en.json index 3faf16c335..3b0439e7ed 100644 --- a/app/javascript/flavours/glitch/locales/en.json +++ b/app/javascript/flavours/glitch/locales/en.json @@ -36,7 +36,7 @@ "confirmations.missing_media_description.message": "At least one media attachment is lacking a description. Consider describing all media attachments for the visually impaired before sending your toot.", "direct.group_by_conversations": "Group by conversation", "endorsed_accounts_editor.endorsed_accounts": "Featured accounts", - "favourite_modal.combo": "You can press {combo} to skip this next time", + "favourite_modal.favourite": "Favourite post?", "federation.federated.long": "Allow this post to reach other servers", "federation.federated.short": "Federated", "federation.local_only.long": "Prevent this post from reaching other servers", From 1701b1fc8011748070084015c3d01cb0d0806cde Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Mon, 2 Sep 2024 10:26:43 +0200 Subject: [PATCH 027/153] Update dependency axios to v1.7.7 (#31670) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index 49373fb3ca..451902a1d4 100644 --- a/yarn.lock +++ b/yarn.lock @@ -5121,13 +5121,13 @@ __metadata: linkType: hard "axios@npm:^1.4.0": - version: 1.7.5 - resolution: "axios@npm:1.7.5" + version: 1.7.7 + resolution: "axios@npm:1.7.7" dependencies: follow-redirects: "npm:^1.15.6" form-data: "npm:^4.0.0" proxy-from-env: "npm:^1.1.0" - checksum: 10c0/1d5daeb28b3d1bb2a7b9f0743433c4bfbeaddc15461e50ebde487eec6c009af2515749d5261096dd430c90cd891bd310bcba5ec3967bae2033c4a307f58a6ad3 + checksum: 10c0/4499efc89e86b0b49ffddc018798de05fab26e3bf57913818266be73279a6418c3ce8f9e934c7d2d707ab8c095e837fc6c90608fb7715b94d357720b5f568af7 languageName: node linkType: hard From 2f2b98c8cbc4997a39b121fada23975214479394 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Mon, 2 Sep 2024 10:35:09 +0200 Subject: [PATCH 028/153] New Crowdin Translations (automated) (#31671) Co-authored-by: GitHub Actions --- app/javascript/mastodon/locales/bg.json | 24 +++++ app/javascript/mastodon/locales/eo.json | 2 +- app/javascript/mastodon/locales/et.json | 39 +++++++ app/javascript/mastodon/locales/fr-CA.json | 2 +- app/javascript/mastodon/locales/fr.json | 4 +- app/javascript/mastodon/locales/gd.json | 4 + app/javascript/mastodon/locales/ia.json | 27 ++++- app/javascript/mastodon/locales/ja.json | 7 +- app/javascript/mastodon/locales/kab.json | 5 + app/javascript/mastodon/locales/ko.json | 2 +- app/javascript/mastodon/locales/lad.json | 7 ++ app/javascript/mastodon/locales/lt.json | 2 +- app/javascript/mastodon/locales/no.json | 116 ++++++++++++++++++++- app/javascript/mastodon/locales/pt-BR.json | 38 +++++++ app/javascript/mastodon/locales/pt-PT.json | 11 ++ app/javascript/mastodon/locales/sk.json | 12 +++ app/javascript/mastodon/locales/uk.json | 8 +- app/javascript/mastodon/locales/vi.json | 31 ++++-- config/locales/doorkeeper.et.yml | 1 + config/locales/doorkeeper.ja.yml | 1 + config/locales/en-GB.yml | 27 +++++ config/locales/et.yml | 22 ++++ config/locales/fr.yml | 2 +- config/locales/ia.yml | 58 +++++++++++ config/locales/ja.yml | 71 +++++++++++++ config/locales/lad.yml | 3 + config/locales/lt.yml | 4 +- config/locales/no.yml | 1 + config/locales/simple_form.et.yml | 1 + config/locales/simple_form.ia.yml | 1 + config/locales/simple_form.ja.yml | 1 + config/locales/simple_form.kab.yml | 2 +- config/locales/simple_form.uk.yml | 2 +- config/locales/sk.yml | 6 ++ config/locales/uk.yml | 2 +- 35 files changed, 519 insertions(+), 27 deletions(-) diff --git a/app/javascript/mastodon/locales/bg.json b/app/javascript/mastodon/locales/bg.json index 5fb254e390..828092d430 100644 --- a/app/javascript/mastodon/locales/bg.json +++ b/app/javascript/mastodon/locales/bg.json @@ -97,6 +97,8 @@ "block_modal.title": "Блокирате ли потребителя?", "block_modal.you_wont_see_mentions": "Няма да виждате публикациите, които ги споменават.", "boost_modal.combo": "Можете да натиснете {combo}, за да пропуснете това следващия път", + "boost_modal.reblog": "Подсилвате ли публикация?", + "boost_modal.undo_reblog": "Без подсилване на публикация ли?", "bundle_column_error.copy_stacktrace": "Копиране на доклада за грешката", "bundle_column_error.error.body": "Заявената страница не може да се изобрази. Това може да е заради грешка в кода ни или проблем със съвместимостта на браузъра.", "bundle_column_error.error.title": "О, не!", @@ -349,6 +351,14 @@ "hashtag.follow": "Следване на хаштаг", "hashtag.unfollow": "Спиране на следване на хаштаг", "hashtags.and_other": "…и {count, plural, other {# още}}", + "hints.profiles.followers_may_be_missing": "Последователи за този профил може да липсват.", + "hints.profiles.follows_may_be_missing": "Последванията за този профил може да липсват.", + "hints.profiles.posts_may_be_missing": "Някои публикации от този профил може да липсват.", + "hints.profiles.see_more_followers": "Преглед на още последователи на {domain}", + "hints.profiles.see_more_follows": "Преглед на още последвания на {domain}", + "hints.profiles.see_more_posts": "Преглед на още публикации на {domain}", + "hints.threads.replies_may_be_missing": "Отговори от други сървъри може да липсват.", + "hints.threads.see_more": "Преглед на още отговори на {domain}", "home.column_settings.show_reblogs": "Показване на подсилванията", "home.column_settings.show_replies": "Показване на отговорите", "home.hide_announcements": "Скриване на оповестяванията", @@ -446,6 +456,7 @@ "mute_modal.you_wont_see_mentions": "Няма да виждате споменаващите ги публикации.", "mute_modal.you_wont_see_posts": "Още могат да виждат публикациите ви, но вие техните не.", "navigation_bar.about": "Относно", + "navigation_bar.administration": "Администрация", "navigation_bar.advanced_interface": "Отваряне в разширен уебинтерфейс", "navigation_bar.blocks": "Блокирани потребители", "navigation_bar.bookmarks": "Отметки", @@ -462,6 +473,7 @@ "navigation_bar.follows_and_followers": "Последвания и последователи", "navigation_bar.lists": "Списъци", "navigation_bar.logout": "Излизане", + "navigation_bar.moderation": "Модериране", "navigation_bar.mutes": "Заглушени потребители", "navigation_bar.opened_in_classic_interface": "Публикации, акаунти и други особени страници се отварят по подразбиране в класическия мрежови интерфейс.", "navigation_bar.personal": "Лично", @@ -477,10 +489,17 @@ "notification.admin.report_statuses": "{name} докладва {target} за {category}", "notification.admin.report_statuses_other": "{name} докладва {target}", "notification.admin.sign_up": "{name} се регистрира", + "notification.admin.sign_up.name_and_others": "{name} и {count, plural, one {# друг} other {# други}} се регистрираха", "notification.favourite": "{name} направи любима публикацията ви", + "notification.favourite.name_and_others_with_link": "{name} и {count, plural, one {# друг} other {# други}} направиха любима ваша публикация", "notification.follow": "{name} ви последва", + "notification.follow.name_and_others": "{name} и {count, plural, one {# друг} other {# други}} ви последваха", "notification.follow_request": "{name} поиска да ви последва", + "notification.follow_request.name_and_others": "{name} и {count, plural, one {# друг} other {# други}} поискаха да ви последват", "notification.label.mention": "Споменаване", + "notification.label.private_mention": "Частно споменаване", + "notification.label.private_reply": "Личен отговор", + "notification.label.reply": "Отговор", "notification.mention": "Споменаване", "notification.moderation-warning.learn_more": "Научете повече", "notification.moderation_warning": "Получихте предупреждение за модериране", @@ -494,6 +513,7 @@ "notification.own_poll": "Анкетата ви приключи", "notification.poll": "Анкета, в която гласувахте, приключи", "notification.reblog": "{name} подсили ваша публикация", + "notification.reblog.name_and_others_with_link": "{name} и {count, plural, one {# друг} other {# други}} подсилиха ваша публикация", "notification.relationships_severance_event": "Изгуби се връзката с {name}", "notification.relationships_severance_event.account_suspension": "Администратор от {from} спря {target}, което значи че повече не може да получавате новости от тях или да взаимодействате с тях.", "notification.relationships_severance_event.domain_block": "Администратор от {from} блокира {target}, вкючващо {followersCount} от последователите ви и {followingCount, plural, one {# акаунт, който} other {# акаунта, които}} следвате.", @@ -502,6 +522,9 @@ "notification.status": "{name} току-що публикува", "notification.update": "{name} промени публикация", "notification_requests.accept": "Приемам", + "notification_requests.confirm_accept_multiple.message": "На път сте да приемете {count, plural, one {едно известие за заявка} other {# известия за заявки}}. Наистина ли искате да продължите?", + "notification_requests.confirm_accept_multiple.title": "Приемате ли заявките за известие?", + "notification_requests.confirm_dismiss_multiple.title": "Отхвърляте ли заявките за известие?", "notification_requests.dismiss": "Отхвърлям", "notification_requests.edit_selection": "Редактиране", "notification_requests.exit_selection": "Готово", @@ -561,6 +584,7 @@ "notifications.policy.filter_not_following_title": "Хора, които не следвате", "notifications.policy.filter_private_mentions_hint": "Филтрирано, освен ако е отговор към ваше собствено споменаване или ако следвате подателя", "notifications.policy.filter_private_mentions_title": "Непоискани частни споменавания", + "notifications.policy.title": "Управление на известията от…", "notifications_permission_banner.enable": "Включване на известията на работния плот", "notifications_permission_banner.how_to_control": "За да получавате известия, когато Mastodon не е отворен, включете известията на работния плот. Може да управлявате точно кои видове взаимодействия пораждат известия на работния плот чрез бутона {icon} по-горе, след като бъдат включени.", "notifications_permission_banner.title": "Никога не пропускайте нищо", diff --git a/app/javascript/mastodon/locales/eo.json b/app/javascript/mastodon/locales/eo.json index 76ca4980fa..40eee9805a 100644 --- a/app/javascript/mastodon/locales/eo.json +++ b/app/javascript/mastodon/locales/eo.json @@ -67,7 +67,7 @@ "account.unblock_domain": "Malbloki la domajnon {domain}", "account.unblock_short": "Malbloki", "account.unendorse": "Ne plu rekomendi ĉe la profilo", - "account.unfollow": "Malaboni", + "account.unfollow": "Ĉesi sekvi", "account.unmute": "Ne plu silentigi @{name}", "account.unmute_notifications_short": "Malsilentigu Sciigojn", "account.unmute_short": "Ne plu silentigi", diff --git a/app/javascript/mastodon/locales/et.json b/app/javascript/mastodon/locales/et.json index 5caa258cd2..4838f70155 100644 --- a/app/javascript/mastodon/locales/et.json +++ b/app/javascript/mastodon/locales/et.json @@ -11,6 +11,7 @@ "about.not_available": "See info ei ole sellel serveril saadavaks tehtud.", "about.powered_by": "Hajutatud sotsiaalmeedia, mille taga on {mastodon}", "about.rules": "Serveri reeglid", + "account.account_note_header": "Isiklik märge", "account.add_or_remove_from_list": "Lisa või Eemalda nimekirjadest", "account.badges.bot": "Robot", "account.badges.group": "Grupp", @@ -96,6 +97,8 @@ "block_modal.title": "Blokeeri kasutaja?", "block_modal.you_wont_see_mentions": "Sa ei näe postitusi, mis mainivad teda.", "boost_modal.combo": "Vajutades {combo}, saab selle edaspidi vahele jätta", + "boost_modal.reblog": "Jagada postitust?", + "boost_modal.undo_reblog": "Tühista postituse jagamine?", "bundle_column_error.copy_stacktrace": "Kopeeri veateade", "bundle_column_error.error.body": "Soovitud lehte ei õnnestunud esitada. See võib olla meie koodiviga või probleem brauseri ühilduvusega.", "bundle_column_error.error.title": "Oh, ei!", @@ -169,21 +172,30 @@ "confirmations.block.confirm": "Blokeeri", "confirmations.delete.confirm": "Kustuta", "confirmations.delete.message": "Oled kindel, et soovid postituse kustutada?", + "confirmations.delete.title": "Kustutada postitus?", "confirmations.delete_list.confirm": "Kustuta", "confirmations.delete_list.message": "Oled kindel, et soovid selle loetelu pöördumatult kustutada?", + "confirmations.delete_list.title": "Kustutada loetelu?", "confirmations.discard_edit_media.confirm": "Hülga", "confirmations.discard_edit_media.message": "Sul on salvestamata muudatusi meediakirjelduses või eelvaates, kas hülgad need?", "confirmations.edit.confirm": "Muuda", "confirmations.edit.message": "Muutes praegu kirjutatakse hetkel loodav sõnum üle. Kas oled kindel, et soovid jätkata?", + "confirmations.edit.title": "Kirjutada postitus üle?", "confirmations.logout.confirm": "Välju", "confirmations.logout.message": "Kas oled kindel, et soovid välja logida?", + "confirmations.logout.title": "Logida välja?", "confirmations.mute.confirm": "Vaigista", "confirmations.redraft.confirm": "Kustuta & taasalusta", "confirmations.redraft.message": "Kindel, et soovid postituse kustutada ja võtta uue aluseks? Lemmikuks märkimised ja jagamised lähevad kaotsi ning vastused jäävad ilma algse postituseta.", + "confirmations.redraft.title": "Kustudada ja luua postituse mustand?", "confirmations.reply.confirm": "Vasta", "confirmations.reply.message": "Praegu vastamine kirjutab hetkel koostatava sõnumi üle. Oled kindel, et soovid jätkata?", + "confirmations.reply.title": "Kirjutada postitus üle?", "confirmations.unfollow.confirm": "Ära jälgi", "confirmations.unfollow.message": "Oled kindel, et ei soovi rohkem jälgida kasutajat {name}?", + "confirmations.unfollow.title": "Ei jälgi enam kasutajat?", + "content_warning.hide": "Peida postitus", + "content_warning.show": "Näita ikkagi", "conversation.delete": "Kustuta vestlus", "conversation.mark_as_read": "Märgi loetuks", "conversation.open": "Vaata vestlust", @@ -291,6 +303,8 @@ "filter_modal.select_filter.subtitle": "Kasuta olemasolevat kategooriat või loo uus", "filter_modal.select_filter.title": "Filtreeri seda postitust", "filter_modal.title.status": "Postituse filtreerimine", + "filter_warning.matches_filter": "Sobib filtriga “{title}”", + "filtered_notifications_banner.pending_requests": "{count, plural, =0 {Mitte üheltki inimeselt} one {Ühelt inimeselt} other {# inimeselt}}, keda võid teada", "filtered_notifications_banner.title": "Filtreeritud teavitused", "firehose.all": "Kõik", "firehose.local": "See server", @@ -436,6 +450,7 @@ "mute_modal.you_wont_see_mentions": "Sa ei näe postitusi, mis teda mainivad.", "mute_modal.you_wont_see_posts": "Ta näeb jätkuvalt sinu postitusi, kuid sa ei näe tema omi.", "navigation_bar.about": "Teave", + "navigation_bar.administration": "Administreerimine", "navigation_bar.advanced_interface": "Ava kohandatud veebiliides", "navigation_bar.blocks": "Blokeeritud kasutajad", "navigation_bar.bookmarks": "Järjehoidjad", @@ -452,6 +467,7 @@ "navigation_bar.follows_and_followers": "Jälgitavad ja jälgijad", "navigation_bar.lists": "Nimekirjad", "navigation_bar.logout": "Logi välja", + "navigation_bar.moderation": "Modereerimine", "navigation_bar.mutes": "Vaigistatud kasutajad", "navigation_bar.opened_in_classic_interface": "Postitused, kontod ja teised spetsiaalsed lehed avatakse vaikimisi klassikalises veebiliideses.", "navigation_bar.personal": "Isiklik", @@ -462,10 +478,19 @@ "navigation_bar.security": "Turvalisus", "not_signed_in_indicator.not_signed_in": "Pead sisse logima, et saada ligipääsu sellele ressursile.", "notification.admin.report": "{name} saatis teavituse {target} kohta", + "notification.admin.report_account": "{name} raporteeris {count, plural, one {ühest postitusest} other {# postitusest}} kohast {target} kategooriast {category}", + "notification.admin.report_account_other": "{name} raporteeris {count, plural, one {ühest postitusest} other {# postitusest}} kohast {target}", + "notification.admin.report_statuses": "{name} raporteeris {target} kategooriast {category}", + "notification.admin.report_statuses_other": "{name} raporteeris kohast {target}", "notification.admin.sign_up": "{name} registreerus", "notification.favourite": "{name} märkis su postituse lemmikuks", "notification.follow": "{name} alustas su jälgimist", "notification.follow_request": "{name} soovib sind jälgida", + "notification.label.mention": "Mainimine", + "notification.label.private_mention": "Privaatne mainimine", + "notification.label.private_reply": "Privaatne vastus", + "notification.label.reply": "Vastus", + "notification.mention": "Mainimine", "notification.moderation-warning.learn_more": "Vaata lisa", "notification.moderation_warning": "Said modereerimise hoiatuse", "notification.moderation_warning.action_delete_statuses": "Mõni su postitus on eemaldatud.", @@ -476,6 +501,7 @@ "notification.moderation_warning.action_silence": "Su kontole pandi piirang.", "notification.moderation_warning.action_suspend": "Su konto on peatatud.", "notification.own_poll": "Su küsitlus on lõppenud", + "notification.poll": "Hääletus, millel osalesid, on lõppenud", "notification.reblog": "{name} jagas edasi postitust", "notification.relationships_severance_event": "Kadunud ühendus kasutajaga {name}", "notification.relationships_severance_event.account_suspension": "{from} admin on kustutanud {target}, mis tähendab, et sa ei saa enam neilt uuendusi või suhelda nendega.", @@ -486,13 +512,20 @@ "notification.update": "{name} muutis postitust", "notification_requests.accept": "Nõus", "notification_requests.dismiss": "Hülga", + "notification_requests.explainer_for_limited_account": "Sellelt kontolt tulevad teavitused on filtreeritud, sest moderaator on seda kontot piiranud.", + "notification_requests.explainer_for_limited_remote_account": "Sellelt kontolt tulevad teavitused on filtreeritud, sest moderaator on seda kontot või serverit piiranud.", + "notification_requests.maximize": "Maksimeeri", + "notification_requests.minimize_banner": "Minimeeri filtreeritud teavituste bänner", "notification_requests.notifications_from": "Teavitus kasutajalt {name}", "notification_requests.title": "Filtreeritud teavitused", "notifications.clear": "Puhasta teated", "notifications.clear_confirmation": "Oled kindel, et soovid püsivalt kõik oma teated eemaldada?", + "notifications.clear_title": "Tühjenda teavitus?", "notifications.column_settings.admin.report": "Uued teavitused:", "notifications.column_settings.admin.sign_up": "Uued kasutajad:", "notifications.column_settings.alert": "Töölauateated", + "notifications.column_settings.beta.category": "Eksperimentaalsed oskused", + "notifications.column_settings.beta.grouping": "Teavituste rühmitamine", "notifications.column_settings.favourite": "Lemmikud:", "notifications.column_settings.filter_bar.advanced": "Näita kõiki kategooriaid", "notifications.column_settings.filter_bar.category": "Kiirfiltri riba", @@ -521,6 +554,8 @@ "notifications.permission_denied": "Töölauamärguanded pole saadaval, kuna eelnevalt keelduti lehitsejale teavituste luba andmast", "notifications.permission_denied_alert": "Töölaua märguandeid ei saa lubada, kuna brauseri luba on varem keeldutud", "notifications.permission_required": "Töölaua märguanded ei ole saadaval, kuna vajalik luba pole antud.", + "notifications.policy.filter_limited_accounts_hint": "Piiratud serveri moderaatorite poolt", + "notifications.policy.filter_limited_accounts_title": "Modereeritud kontod", "notifications.policy.filter_new_accounts.hint": "Loodud viimase {days, plural, one {ühe päeva} other {# päeva}} jooksul", "notifications.policy.filter_new_accounts_title": "Uued kontod", "notifications.policy.filter_not_followers_hint": "Kaasates kasutajad, kes on sind jälginud vähem kui {days, plural, one {ühe päeva} other {# päeva}}", @@ -655,9 +690,13 @@ "report.unfollow_explanation": "Jälgid seda kontot. Et mitte näha tema postitusi oma koduvoos, lõpeta ta jälgimine.", "report_notification.attached_statuses": "{count, plural, one {{count} postitus} other {{count} postitust}} listatud", "report_notification.categories.legal": "Õiguslik", + "report_notification.categories.legal_sentence": "ebaseaduslik sisu", "report_notification.categories.other": "Muu", + "report_notification.categories.other_sentence": "muu", "report_notification.categories.spam": "Rämpspost", + "report_notification.categories.spam_sentence": "rämps", "report_notification.categories.violation": "Reeglite rikkumine", + "report_notification.categories.violation_sentence": "reeglite rikkumine", "report_notification.open": "Ava teavitus", "search.no_recent_searches": "Pole viimatisi otsinguid", "search.placeholder": "Otsi", diff --git a/app/javascript/mastodon/locales/fr-CA.json b/app/javascript/mastodon/locales/fr-CA.json index c0a575637e..983f737a79 100644 --- a/app/javascript/mastodon/locales/fr-CA.json +++ b/app/javascript/mastodon/locales/fr-CA.json @@ -538,7 +538,7 @@ "notification_requests.confirm_accept_multiple.message": "Vous êtes sur le point d'accepter {count, plural, one {une requête de notification} other {# requêtes de notification}}. Êtes-vous sûr de vouloir continuer ?", "notification_requests.confirm_accept_multiple.title": "Accepter les requêtes de notification ?", "notification_requests.confirm_dismiss_multiple.button": "{count, plural, one {Ignorer la requête} other {Ignorer les requêtes}}", - "notification_requests.confirm_dismiss_multiple.message": "Vous êtes sur le point de rejeter {count, plural, one {une requête de notification} other {# requêtes de notification}}. Vous ne serez plus en mesure d'{count, plural, one {y} other {y}} accéder facilement, ultérieurement. Êtes-vous sûr de vouloir continuer ?", + "notification_requests.confirm_dismiss_multiple.message": "Vous êtes sur le point de rejeter {count, plural, one {une requête de notification} other {# requêtes de notification}}. Vous ne serez plus en mesure d’{count, plural, one {y} other {y}} accéder facilement, ultérieurement. Êtes-vous sûr de vouloir continuer ?", "notification_requests.confirm_dismiss_multiple.title": "Rejeter les requêtes de notification ?", "notification_requests.dismiss": "Rejeter", "notification_requests.dismiss_multiple": "{count, plural, one {Rejeter # requête …} other {Rejeter # requêtes …}}", diff --git a/app/javascript/mastodon/locales/fr.json b/app/javascript/mastodon/locales/fr.json index ed3533719e..2b22f4ba32 100644 --- a/app/javascript/mastodon/locales/fr.json +++ b/app/javascript/mastodon/locales/fr.json @@ -538,7 +538,7 @@ "notification_requests.confirm_accept_multiple.message": "Vous êtes sur le point d'accepter {count, plural, one {une requête de notification} other {# requêtes de notification}}. Êtes-vous sûr de vouloir continuer ?", "notification_requests.confirm_accept_multiple.title": "Accepter les requêtes de notification ?", "notification_requests.confirm_dismiss_multiple.button": "{count, plural, one {Ignorer la requête} other {Ignorer les requêtes}}", - "notification_requests.confirm_dismiss_multiple.message": "Vous êtes sur le point de rejeter {count, plural, one {une requête de notification} other {# requêtes de notification}}. Vous ne serez plus en mesure d'{count, plural, one {y} other {y}} accéder facilement, ultérieurement. Êtes-vous sûr de vouloir continuer ?", + "notification_requests.confirm_dismiss_multiple.message": "Vous êtes sur le point de rejeter {count, plural, one {une requête de notification} other {# requêtes de notification}}. Vous ne serez plus en mesure d’{count, plural, one {y} other {y}} accéder facilement, ultérieurement. Êtes-vous sûr de vouloir continuer ?", "notification_requests.confirm_dismiss_multiple.title": "Rejeter les requêtes de notification ?", "notification_requests.dismiss": "Rejeter", "notification_requests.dismiss_multiple": "{count, plural, one {Rejeter # requête …} other {Rejeter # requêtes …}}", @@ -727,7 +727,7 @@ "report.thanks.title": "Vous ne voulez pas voir cela ?", "report.thanks.title_actionable": "Merci pour votre signalement, nous allons investiguer.", "report.unfollow": "Ne plus suivre @{name}", - "report.unfollow_explanation": "Vous êtes abonné à ce compte. Pour ne plus voir ses publications dans votre flux principal, retirez-le de votre liste d'abonnements.", + "report.unfollow_explanation": "Vous êtes abonné à ce compte. Pour ne plus voir ses publications dans votre fil principal, retirez-le de votre liste d'abonnements.", "report_notification.attached_statuses": "{count, plural, one {{count} message lié} other {{count} messages liés}}", "report_notification.categories.legal": "Légal", "report_notification.categories.legal_sentence": "contenu illégal", diff --git a/app/javascript/mastodon/locales/gd.json b/app/javascript/mastodon/locales/gd.json index aecc26477c..1090df0881 100644 --- a/app/javascript/mastodon/locales/gd.json +++ b/app/javascript/mastodon/locales/gd.json @@ -97,6 +97,8 @@ "block_modal.title": "A bheil thu airson an cleachdaiche a bhacadh?", "block_modal.you_wont_see_mentions": "Chan fhaic thu na postaichean a bheir iomradh orra.", "boost_modal.combo": "Brùth air {combo} nam b’ fheàrr leat leum a ghearradh thar seo an ath-thuras", + "boost_modal.reblog": "A bheil thu airson am post a bhrosnachadh?", + "boost_modal.undo_reblog": "A bheil thu airson sgur de bhrosnachadh a’ phuist?", "bundle_column_error.copy_stacktrace": "Dèan lethbhreac de aithris na mearachd", "bundle_column_error.error.body": "Cha b’ urrainn dhuinn an duilleag a dh’iarr thu a reandaradh. Dh’fhaoidte gu bheil buga sa chòd againn no duilgheadas co-chòrdalachd leis a’ bhrabhsair.", "bundle_column_error.error.title": "Ìoc!", @@ -467,6 +469,7 @@ "mute_modal.you_wont_see_mentions": "Chan fhaic thu na postaichean a bheir iomradh orra.", "mute_modal.you_wont_see_posts": "Chì iad na postaichean agad fhathast ach chan fhaic thu na postaichean aca-san.", "navigation_bar.about": "Mu dhèidhinn", + "navigation_bar.administration": "Rianachd", "navigation_bar.advanced_interface": "Fosgail san eadar-aghaidh-lìn adhartach", "navigation_bar.blocks": "Cleachdaichean bacte", "navigation_bar.bookmarks": "Comharran-lìn", @@ -483,6 +486,7 @@ "navigation_bar.follows_and_followers": "Dàimhean leantainn", "navigation_bar.lists": "Liostaichean", "navigation_bar.logout": "Clàraich a-mach", + "navigation_bar.moderation": "Maorsainneachd", "navigation_bar.mutes": "Cleachdaichean mùchte", "navigation_bar.opened_in_classic_interface": "Thèid postaichean, cunntasan ’s duilleagan sònraichte eile fhosgladh san eadar-aghaidh-lìn chlasaigeach a ghnàth.", "navigation_bar.personal": "Pearsanta", diff --git a/app/javascript/mastodon/locales/ia.json b/app/javascript/mastodon/locales/ia.json index 31fb52552b..9bf89ce716 100644 --- a/app/javascript/mastodon/locales/ia.json +++ b/app/javascript/mastodon/locales/ia.json @@ -191,6 +191,8 @@ "confirmations.unfollow.confirm": "Non plus sequer", "confirmations.unfollow.message": "Es tu secur que tu vole cessar de sequer {name}?", "confirmations.unfollow.title": "Cessar de sequer le usator?", + "content_warning.hide": "Celar le message", + "content_warning.show": "Monstrar in omne caso", "conversation.delete": "Deler conversation", "conversation.mark_as_read": "Marcar como legite", "conversation.open": "Vider conversation", @@ -298,6 +300,7 @@ "filter_modal.select_filter.subtitle": "Usa un categoria existente o crea un nove", "filter_modal.select_filter.title": "Filtrar iste message", "filter_modal.title.status": "Filtrar un message", + "filter_warning.matches_filter": "Corresponde al filtro “{title}”", "filtered_notifications_banner.title": "Notificationes filtrate", "firehose.all": "Toto", "firehose.local": "Iste servitor", @@ -346,6 +349,10 @@ "hashtag.follow": "Sequer hashtag", "hashtag.unfollow": "Non sequer plus le hashtag", "hashtags.and_other": "…e {count, plural, one {}other {# plus}}", + "hints.profiles.see_more_followers": "Vider plus de sequitores sur {domain}", + "hints.profiles.see_more_follows": "Vider plus de sequites sur {domain}", + "hints.profiles.see_more_posts": "Vider plus de messages sur {domain}", + "hints.threads.see_more": "Vider plus de responsas sur {domain}", "home.column_settings.show_reblogs": "Monstrar impulsos", "home.column_settings.show_replies": "Monstrar responsas", "home.hide_announcements": "Celar annuncios", @@ -443,6 +450,7 @@ "mute_modal.you_wont_see_mentions": "Tu non videra le messages que mentiona iste persona.", "mute_modal.you_wont_see_posts": "Iste persona pote totevia vider tu messages, ma tu non videra le sues.", "navigation_bar.about": "A proposito", + "navigation_bar.administration": "Administration", "navigation_bar.advanced_interface": "Aperir in le interfacie web avantiate", "navigation_bar.blocks": "Usatores blocate", "navigation_bar.bookmarks": "Marcapaginas", @@ -459,6 +467,7 @@ "navigation_bar.follows_and_followers": "Sequites e sequitores", "navigation_bar.lists": "Listas", "navigation_bar.logout": "Clauder session", + "navigation_bar.moderation": "Moderation", "navigation_bar.mutes": "Usatores silentiate", "navigation_bar.opened_in_classic_interface": "Messages, contos e altere paginas specific es aperite per predefinition in le interfacie web classic.", "navigation_bar.personal": "Personal", @@ -469,6 +478,8 @@ "navigation_bar.security": "Securitate", "not_signed_in_indicator.not_signed_in": "Es necessari aperir session pro acceder a iste ressource.", "notification.admin.report": "{name} ha reportate {target}", + "notification.admin.report_statuses": "{name} ha reportate {target} pro {category}", + "notification.admin.report_statuses_other": "{name} ha reportate {target}", "notification.admin.sign_up": "{name} se ha inscribite", "notification.favourite": "{name} ha marcate tu message como favorite", "notification.follow": "{name} te ha sequite", @@ -488,6 +499,7 @@ "notification.moderation_warning.action_silence": "Tu conto ha essite limitate.", "notification.moderation_warning.action_suspend": "Tu conto ha essite suspendite.", "notification.own_poll": "Tu sondage ha finite", + "notification.poll": "Un sondage in le qual tu ha votate ha finite", "notification.reblog": "{name} ha impulsate tu message", "notification.relationships_severance_event": "Connexiones perdite con {name}", "notification.relationships_severance_event.account_suspension": "Un administrator de {from} ha suspendiute {target}. Isto significa que tu non pote plus reciper actualisationes de iste persona o interager con ille.", @@ -497,9 +509,14 @@ "notification.status": "{name} ha justo ora publicate", "notification.update": "{name} ha modificate un message", "notification_requests.accept": "Acceptar", + "notification_requests.confirm_accept_multiple.title": "Acceptar petitiones de notification?", + "notification_requests.confirm_dismiss_multiple.title": "Dimitter petitiones de notification?", "notification_requests.dismiss": "Clauder", + "notification_requests.edit_selection": "Modificar", + "notification_requests.exit_selection": "Facite", "notification_requests.notifications_from": "Notificationes de {name}", "notification_requests.title": "Notificationes filtrate", + "notification_requests.view": "Vider notificationes", "notifications.clear": "Rader notificationes", "notifications.clear_confirmation": "Es tu secur que tu vole rader permanentemente tote tu notificationes?", "notifications.clear_title": "Rader le notificationes?", @@ -536,6 +553,11 @@ "notifications.permission_denied": "Le notificationes de scriptorio es indisponibile a causa de un requesta anteriormente refusate de permissiones del navigator", "notifications.permission_denied_alert": "Le notificationes de scriptorio non pote esser activate perque le permission del navigator ha essite refusate anteriormente", "notifications.permission_required": "Le notificationes de scriptorio es indisponibile perque le permission necessari non ha essite concedite.", + "notifications.policy.accept": "Acceptar", + "notifications.policy.accept_hint": "Monstrar in le notificationes", + "notifications.policy.filter": "Filtrar", + "notifications.policy.filter_hint": "Inviar al cassa de notificationes filtrate", + "notifications.policy.filter_limited_accounts_title": "Contos moderate", "notifications.policy.filter_new_accounts.hint": "Create in le ultime {days, plural, one {die} other {# dies}}", "notifications.policy.filter_new_accounts_title": "Nove contos", "notifications.policy.filter_not_followers_hint": "Includente le personas que te ha sequite durante minus de {days, plural, one {un die} other {# dies}}", @@ -544,6 +566,7 @@ "notifications.policy.filter_not_following_title": "Personas que tu non seque", "notifications.policy.filter_private_mentions_hint": "Filtrate, excepte si es in responsa a tu proprie mention o si tu seque le expeditor", "notifications.policy.filter_private_mentions_title": "Mentiones private indesirate", + "notifications.policy.title": "Gerer notificationes de…", "notifications_permission_banner.enable": "Activar notificationes de scriptorio", "notifications_permission_banner.how_to_control": "Pro reciper notificationes quando Mastodon non es aperte, activa le notificationes de scriptorio. Post lor activation, es possibile controlar precisemente qual typos de interaction genera notificationes de scriptorio per medio del button {icon} hic supra.", "notifications_permission_banner.title": "Non mancar jammais a un cosa", @@ -596,8 +619,8 @@ "poll.vote": "Votar", "poll.voted": "Tu ha votate pro iste responsa", "poll.votes": "{votes, plural, one {# voto} other {# votos}}", - "poll_button.add_poll": "Adder un inquesta", - "poll_button.remove_poll": "Remover un inquesta", + "poll_button.add_poll": "Adder un sondage", + "poll_button.remove_poll": "Remover un sondage", "privacy.change": "Cambiar le confidentialitate del message", "privacy.direct.long": "Tote le personas mentionate in le message", "privacy.direct.short": "Personas specific", diff --git a/app/javascript/mastodon/locales/ja.json b/app/javascript/mastodon/locales/ja.json index f24b54aa48..489ff9c8e7 100644 --- a/app/javascript/mastodon/locales/ja.json +++ b/app/javascript/mastodon/locales/ja.json @@ -194,7 +194,7 @@ "confirmations.unfollow.confirm": "フォロー解除", "confirmations.unfollow.message": "本当に{name}さんのフォローを解除しますか?", "confirmations.unfollow.title": "フォローを解除しようとしています", - "content_warning.hide": "投稿を隠す", + "content_warning.hide": "内容を隠す", "content_warning.show": "承知の上で表示", "conversation.delete": "会話を削除", "conversation.mark_as_read": "既読にする", @@ -469,6 +469,7 @@ "mute_modal.you_wont_see_mentions": "宛先に相手が入っている投稿も閲覧できなくなります。", "mute_modal.you_wont_see_posts": "相手はあなたの投稿を今までどおり閲覧できますが、あなたは相手の投稿を閲覧できなくなります。", "navigation_bar.about": "概要", + "navigation_bar.administration": "管理", "navigation_bar.advanced_interface": "上級者向けUIに戻る", "navigation_bar.blocks": "ブロックしたユーザー", "navigation_bar.bookmarks": "ブックマーク", @@ -485,6 +486,7 @@ "navigation_bar.follows_and_followers": "フォロー・フォロワー", "navigation_bar.lists": "リスト", "navigation_bar.logout": "ログアウト", + "navigation_bar.moderation": "モデレーション", "navigation_bar.mutes": "ミュートしたユーザー", "navigation_bar.opened_in_classic_interface": "投稿やプロフィールを直接開いた場合は一時的に標準UIで表示されます。", "navigation_bar.personal": "個人用", @@ -546,10 +548,11 @@ "notification_requests.exit_selection": "選択の終了", "notification_requests.explainer_for_limited_account": "このアカウントはモデレーターにより制限が課されているため、このアカウントによる通知は保留されています", "notification_requests.explainer_for_limited_remote_account": "このアカウントが所属するサーバーはモデレーターにより制限が課されているため、このアカウントによる通知は保留されています", + "notification_requests.maximize": "最大化", "notification_requests.minimize_banner": "「保留中の通知」のバナーを最小化する", "notification_requests.notifications_from": "{name}からの通知", "notification_requests.title": "保留中の通知", - "notification_requests.view": "通知を確認", + "notification_requests.view": "通知を見る", "notifications.clear": "通知を消去", "notifications.clear_confirmation": "本当に通知を消去しますか?", "notifications.clear_title": "通知を消去しようとしています", diff --git a/app/javascript/mastodon/locales/kab.json b/app/javascript/mastodon/locales/kab.json index c5c0fa94c1..a1e95fd8d1 100644 --- a/app/javascript/mastodon/locales/kab.json +++ b/app/javascript/mastodon/locales/kab.json @@ -158,6 +158,8 @@ "confirmations.reply.message": "Tiririt akka tura ad k-degger izen-agi i tettaruḍ. Tebɣiḍ ad tkemmleḍ?", "confirmations.unfollow.confirm": "Ur ḍḍafaṛ ara", "confirmations.unfollow.message": "Tetḥeqqeḍ belli tebɣiḍ ur teṭafaṛeḍ ara {name}?", + "content_warning.hide": "Ffer tasuffeɣt", + "content_warning.show": "Ssken-d akken tebɣu tili", "conversation.delete": "Kkes adiwenni", "conversation.mark_as_read": "Creḍ yettwaɣṛa", "conversation.open": "Ssken adiwenni", @@ -360,6 +362,7 @@ "mute_modal.you_wont_see_mentions": "Ur tezmireḍ ara ad twaliḍ tisuffaɣ anda d-yettwabdar.", "mute_modal.you_wont_see_posts": "Yezmer ad yettwali tisuffaɣ-ik·im, maca ur tettwaliḍ ara tidak-is.", "navigation_bar.about": "Ɣef", + "navigation_bar.administration": "Tadbelt", "navigation_bar.advanced_interface": "Ldi deg ugrudem n web leqqayen", "navigation_bar.blocks": "Iseqdacen yettusḥebsen", "navigation_bar.bookmarks": "Ticraḍ", @@ -390,6 +393,7 @@ "notification.favourite": "{name} yesmenyaf addad-ik·im", "notification.follow": "iṭṭafar-ik·em-id {name}", "notification.follow_request": "{name} yessuter-d ad k·m-yeḍfeṛ", + "notification.label.mention": "Abdar", "notification.label.private_mention": "Abdar uslig", "notification.label.private_reply": "Tiririt tusligt", "notification.label.reply": "Tiririt", @@ -402,6 +406,7 @@ "notification.status": "{name} akken i d-yessufeɣ", "notification_requests.accept": "Qbel", "notification_requests.dismiss": "Agi", + "notification_requests.exit_selection": "Immed", "notification_requests.notifications_from": "Alɣuten sɣur {name}", "notifications.clear": "Sfeḍ alɣuten", "notifications.clear_confirmation": "Tebɣiḍ s tidet ad tekkseḍ akk alɣuten-inek·em i lebda?", diff --git a/app/javascript/mastodon/locales/ko.json b/app/javascript/mastodon/locales/ko.json index 0013632784..b3d3476e4f 100644 --- a/app/javascript/mastodon/locales/ko.json +++ b/app/javascript/mastodon/locales/ko.json @@ -605,7 +605,7 @@ "notifications.policy.filter_not_following_title": "내가 팔로우하지 않는 사람들", "notifications.policy.filter_private_mentions_hint": "내가 한 멘션에 단 답글이거나 내가 발신자를 팔로우 한 것이 아닌 이상 걸러집니다", "notifications.policy.filter_private_mentions_title": "청하지 않은 개인적인 멘션", - "notifications.policy.title": "…의 알림 설정", + "notifications.policy.title": "알림 조건 설정", "notifications_permission_banner.enable": "데스크탑 알림 활성화", "notifications_permission_banner.how_to_control": "마스토돈이 열려 있지 않을 때에도 알림을 받으려면, 데스크탑 알림을 활성화 하세요. 당신은 어떤 종류의 반응이 데스크탑 알림을 발생할 지를 {icon} 버튼을 통해 세세하게 설정할 수 있습니다.", "notifications_permission_banner.title": "아무것도 놓치지 마세요", diff --git a/app/javascript/mastodon/locales/lad.json b/app/javascript/mastodon/locales/lad.json index 48aeec0795..3d0bfcb4be 100644 --- a/app/javascript/mastodon/locales/lad.json +++ b/app/javascript/mastodon/locales/lad.json @@ -92,6 +92,7 @@ "block_modal.title": "Bloka utilizador?", "block_modal.you_wont_see_mentions": "No veras publikasyones ke lo enmentan.", "boost_modal.combo": "Puedes klikar {combo} para ometer esto la proksima vez", + "boost_modal.reblog": "Repartajar puvlikasyon?", "bundle_column_error.copy_stacktrace": "Kopia el raporto de yerro", "bundle_column_error.error.body": "La pajina solisitada no pudo ser renderada. Podria ser por un yerro en muestro kodiche o un problem de kompatibilita kon el navigador.", "bundle_column_error.error.title": "Atyo, no!", @@ -185,6 +186,8 @@ "confirmations.unfollow.confirm": "Desige", "confirmations.unfollow.message": "Estas siguro ke keres deshar de segir a {name}?", "confirmations.unfollow.title": "Desige utilizador?", + "content_warning.hide": "Eskonde puvlikasyon", + "content_warning.show": "Amostra entanto", "conversation.delete": "Efasa konversasyon", "conversation.mark_as_read": "Marka komo meldado", "conversation.open": "Ve konversasyon", @@ -425,6 +428,7 @@ "mute_modal.title": "Silensiar utilizador?", "mute_modal.you_wont_see_mentions": "No veras publikasyones ke lo enmentan.", "navigation_bar.about": "Sovre mozotros", + "navigation_bar.administration": "Administrasyon", "navigation_bar.advanced_interface": "Avre en la enterfaz avanzada", "navigation_bar.blocks": "Utilizadores blokados", "navigation_bar.bookmarks": "Markadores", @@ -441,6 +445,7 @@ "navigation_bar.follows_and_followers": "Segidos i suivantes", "navigation_bar.lists": "Listas", "navigation_bar.logout": "Salir", + "navigation_bar.moderation": "Moderasyon", "navigation_bar.mutes": "Utilizadores silensiados", "navigation_bar.opened_in_classic_interface": "Publikasyones, kuentos i otras pajinas espesifikas se avren kon preferensyas predeterminadas en la enterfaz web klasika.", "navigation_bar.personal": "Personal", @@ -475,6 +480,8 @@ "notification.update": "{name} edito una publikasyon", "notification_requests.accept": "Acheta", "notification_requests.dismiss": "Kita", + "notification_requests.edit_selection": "Edita", + "notification_requests.exit_selection": "Fecho", "notification_requests.notifications_from": "Avizos de {name}", "notification_requests.title": "Avizos filtrados", "notification_requests.view": "Amostra avizos", diff --git a/app/javascript/mastodon/locales/lt.json b/app/javascript/mastodon/locales/lt.json index 051fd3717c..f58c405f28 100644 --- a/app/javascript/mastodon/locales/lt.json +++ b/app/javascript/mastodon/locales/lt.json @@ -635,7 +635,7 @@ "onboarding.steps.share_profile.title": "Bendrink savo Mastodon profilį", "onboarding.tips.2fa": "Ar žinojai? Savo paskyrą gali apsaugoti nustatant dviejų veiksnių tapatybės nustatymą paskyros nustatymuose. Jis veikia su bet kuria pasirinkta TOTP programėle, telefono numeris nebūtinas.", "onboarding.tips.accounts_from_other_servers": "Ar žinojai? Kadangi Mastodon decentralizuotas, kai kurie profiliai, su kuriais susidursi, bus talpinami ne tavo, o kituose serveriuose. Ir vis tiek galėsi su jais sklandžiai bendrauti! Jų serveris yra antroje naudotojo vardo pusėje.", - "onboarding.tips.migration": "Ar žinojai? Jei manai, kad {domain} serveris ateityje tau netiks, gali persikelti į kitą Mastodon serverį neprarandant savo sekėjų. Gali net talpinti savo paties serverį.", + "onboarding.tips.migration": "Ar žinojai? Jei manai, kad {domain} serveris ateityje tau netiks, gali persikelti į kitą „Mastodon“ serverį neprarandant savo sekėjų. Gali net talpinti savo paties serverį!", "onboarding.tips.verification": "Ar žinojai? Savo paskyrą gali patvirtinti pateikęs (-usi) nuorodą į Mastodon profilį savo interneto svetainėje ir pridėjęs (-usi) svetainę prie savo profilio. Nereikia jokių mokesčių ar dokumentų.", "password_confirmation.exceeds_maxlength": "Slaptažodžio patvirtinimas viršija maksimalų slaptažodžio ilgį.", "password_confirmation.mismatching": "Slaptažodžio patvirtinimas nesutampa.", diff --git a/app/javascript/mastodon/locales/no.json b/app/javascript/mastodon/locales/no.json index a3780de550..bb41754e7d 100644 --- a/app/javascript/mastodon/locales/no.json +++ b/app/javascript/mastodon/locales/no.json @@ -11,6 +11,7 @@ "about.not_available": "Denne informasjonen er ikke gjort tilgjengelig på denne tjeneren.", "about.powered_by": "Desentraliserte sosiale medier drevet av {mastodon}", "about.rules": "Regler for serveren", + "account.account_note_header": "Personlig notat", "account.add_or_remove_from_list": "Legg til eller fjern fra lister", "account.badges.bot": "Automatisert", "account.badges.group": "Gruppe", @@ -33,7 +34,9 @@ "account.follow_back": "Følg tilbake", "account.followers": "Følgere", "account.followers.empty": "Ingen følger denne brukeren ennå.", + "account.followers_counter": "{count, plural, one {{counter} følger} other {{counter} følgere}}", "account.following": "Følger", + "account.following_counter": "{count, plural, one {{counter} som følges} other {{counter} som følges}}", "account.follows.empty": "Denne brukeren følger ikke noen enda.", "account.go_to_profile": "Gå til profil", "account.hide_reblogs": "Skjul fremhevinger fra @{name}", @@ -59,6 +62,7 @@ "account.requested_follow": "{name} har bedt om å få følge deg", "account.share": "Del @{name} sin profil", "account.show_reblogs": "Vis fremhevinger fra @{name}", + "account.statuses_counter": "{count, plural, one {{counter} innlegg} other {{counter} innlegg}}", "account.unblock": "Opphev blokkering av @{name}", "account.unblock_domain": "Opphev blokkering av {domain}", "account.unblock_short": "Opphev blokkering", @@ -84,7 +88,17 @@ "announcement.announcement": "Kunngjøring", "attachments_list.unprocessed": "(ubehandlet)", "audio.hide": "Skjul lyd", + "block_modal.remote_users_caveat": "Vi vil be serveren {domain} om å respektere din beslutning. Det er imidlertid ingen garanti at det blir overholdt, siden noen servere kan håndtere blokkeringer på forskjellig vis. Offentlige innlegg kan fortsatt være synlige for ikke-innloggede brukere.", + "block_modal.show_less": "Vis mindre", + "block_modal.show_more": "Vis mer", + "block_modal.they_cant_mention": "De kan ikke nevne eller følge deg.", + "block_modal.they_cant_see_posts": "De kan ikke se dine innlegg og du kommer ikke til å se deres.", + "block_modal.they_will_know": "De kan se at de er blitt blokkert.", + "block_modal.title": "Blokker bruker?", + "block_modal.you_wont_see_mentions": "Du kommer ikke til å se innlegg som nevner dem.", "boost_modal.combo": "You kan trykke {combo} for å hoppe over dette neste gang", + "boost_modal.reblog": "Fremhev innlegg?", + "boost_modal.undo_reblog": "Fjern fremheving?", "bundle_column_error.copy_stacktrace": "Kopier feilrapport", "bundle_column_error.error.body": "Den forespurte siden kan ikke gjengis. Den kan skyldes en feil i vår kode eller et kompatibilitetsproblem med nettleseren.", "bundle_column_error.error.title": "Å nei!", @@ -158,21 +172,30 @@ "confirmations.block.confirm": "Blokkèr", "confirmations.delete.confirm": "Slett", "confirmations.delete.message": "Er du sikker på at du vil slette dette innlegget?", + "confirmations.delete.title": "Slett innlegg?", "confirmations.delete_list.confirm": "Slett", "confirmations.delete_list.message": "Er du sikker på at du vil slette denne listen permanent?", + "confirmations.delete_list.title": "Slett liste?", "confirmations.discard_edit_media.confirm": "Forkast", "confirmations.discard_edit_media.message": "Du har ulagrede endringer i mediebeskrivelsen eller i forhåndsvisning, forkast dem likevel?", "confirmations.edit.confirm": "Redigér", "confirmations.edit.message": "Å redigere nå vil overskrive meldingen du skriver for øyeblikket. Er du sikker på at du vil fortsette?", + "confirmations.edit.title": "Overskriv innlegg?", "confirmations.logout.confirm": "Logg ut", "confirmations.logout.message": "Er du sikker på at du vil logge ut?", + "confirmations.logout.title": "Logg ut?", "confirmations.mute.confirm": "Demp", "confirmations.redraft.confirm": "Slett og skriv på nytt", "confirmations.redraft.message": "Er du sikker på at du vil slette dette innlegget og lagre det på nytt? Favoritter og fremhevinger vil gå tapt, og svar til det originale innlegget vil bli foreldreløse.", + "confirmations.redraft.title": "Slett og skriv på nytt?", "confirmations.reply.confirm": "Svar", "confirmations.reply.message": "Å svare nå vil overskrive meldingen du skriver for øyeblikket. Er du sikker på at du vil fortsette?", + "confirmations.reply.title": "Overskriv innlegg?", "confirmations.unfollow.confirm": "Slutt å følge", "confirmations.unfollow.message": "Er du sikker på at du vil slutte å følge {name}?", + "confirmations.unfollow.title": "Slutt å følge bruker?", + "content_warning.hide": "Skjul innlegg", + "content_warning.show": "Vis likevel", "conversation.delete": "Slett samtalen", "conversation.mark_as_read": "Marker som lest", "conversation.open": "Vis samtale", @@ -192,6 +215,27 @@ "dismissable_banner.explore_statuses": "Disse innleggene fra denne og andre servere i det desentraliserte nettverket får økt oppmerksomhet på denne serveren akkurat nå. Nyere innlegg med flere fremhevinger og favoritter er rangert høyere.", "dismissable_banner.explore_tags": "Disse emneknaggene snakker folk om akkurat nå, på denne og andre servere i det desentraliserte nettverket.", "dismissable_banner.public_timeline": "Dette er de siste offentlige innleggene fra mennesker på det sosiale nettet som folk på {domain} følger.", + "domain_block_modal.block": "Blokker server", + "domain_block_modal.block_account_instead": "Blokker @{name} i stedet", + "domain_block_modal.they_can_interact_with_old_posts": "Personer fra denne serveren kan samhandle med dine gamle innlegg.", + "domain_block_modal.they_cant_follow": "Ingen fra denne serveren kan følge deg.", + "domain_block_modal.they_wont_know": "De kommer ikke til å få vite at du har valgt å blokkere dem.", + "domain_block_modal.title": "Blokker domenet?", + "domain_block_modal.you_will_lose_followers": "Alle dine følgere fra denne serveren vil bli fjernet.", + "domain_block_modal.you_wont_see_posts": "Du vil ikke se innlegg eller få varsler fra brukere på denne serveren.", + "domain_pill.activitypub_lets_connect": "Den lar deg koble til og samhandle med folk ikke bare på Mastodon, men også på tvers av forskjellige sosiale apper.", + "domain_pill.activitypub_like_language": "ActivityPub er liksom språket Mastodon snakker med andre sosiale nettverk.", + "domain_pill.server": "Server", + "domain_pill.their_handle": "Deres håndtak:", + "domain_pill.their_server": "Deres digitale hjem, hvor alle innleggene deres bor.", + "domain_pill.their_username": "Deres unike identifikator på serveren sin. Det er mulig å finne brukere med samme brukernavn på forskjellige servere.", + "domain_pill.username": "Brukernavn", + "domain_pill.whats_in_a_handle": "Hva er et håndtak?", + "domain_pill.who_they_are": "Siden håndtakene sier hvem noen er og hvor de er, kan du samhandle med folk på tvers av det sosiale nettverket bestående av .", + "domain_pill.who_you_are": "Fordi ditt håndtak sier hvem du er og hvor du er, kan folk kommunisere med deg på tvers av .", + "domain_pill.your_handle": "Din håndtak:", + "domain_pill.your_server": "Ditt digitale hjem, hvor alle dine innlegg bor. Liker du ikke denne? Flytt till en annen server når som helst og ta med følgerne dine.", + "domain_pill.your_username": "Din unike identifikator på denne serveren. Det er mulig å finne brukere med samme brukernavn på forskjellige servere.", "embed.instructions": "Kopier koden under for å bygge inn denne statusen på hjemmesiden din.", "embed.preview": "Slik kommer det til å se ut:", "emoji_button.activity": "Aktivitet", @@ -228,6 +272,7 @@ "empty_column.list": "Det er ingenting i denne listen ennå. Når medlemmene av denne listen legger ut nye statuser vil de dukke opp her.", "empty_column.lists": "Du har ingen lister enda. Når du lager en, vil den dukke opp her.", "empty_column.mutes": "Du har ikke dempet noen brukere enda.", + "empty_column.notification_requests": "Alt klart! Det er ingenting her. Når du mottar nye varsler, vises de her i henhold til dine innstillinger.", "empty_column.notifications": "Du har ingen varsler ennå. Kommuniser med andre for å begynne samtalen.", "empty_column.public": "Det er ingenting her! Skriv noe offentlig, eller følg brukere manuelt fra andre instanser for å fylle den opp", "error.unexpected_crash.explanation": "På grunn av en bug i koden vår eller et nettleserkompatibilitetsproblem, kunne denne siden ikke vises riktig.", @@ -258,13 +303,30 @@ "filter_modal.select_filter.subtitle": "Bruk en eksisterende kategori eller opprett en ny", "filter_modal.select_filter.title": "Filtrer dette innlegget", "filter_modal.title.status": "Filtrer et innlegg", + "filter_warning.matches_filter": "Passer med filteret «{title}»", + "filtered_notifications_banner.pending_requests": "Fra {count, plural, =0 {ingen} one {en person} other {# folk}} du kanskje kjenner", + "filtered_notifications_banner.title": "Filtrerte varsler", "firehose.all": "Alt", "firehose.local": "Denne serveren", "firehose.remote": "Andre servere", "follow_request.authorize": "Autoriser", "follow_request.reject": "Avvis", "follow_requests.unlocked_explanation": "Selv om kontoen din ikke er låst, tror {domain} ansatte at du kanskje vil gjennomgå forespørsler fra disse kontoene manuelt.", + "follow_suggestions.curated_suggestion": "Utvalgt av staben", + "follow_suggestions.dismiss": "Ikke vis igjen", + "follow_suggestions.featured_longer": "Håndplukket av {domain}-teamet", + "follow_suggestions.friends_of_friends_longer": "Populært blant personer du følger", + "follow_suggestions.hints.featured": "Denne profilen er håndplukket av {domain}-teamet.", + "follow_suggestions.hints.friends_of_friends": "Denne profilen er populær blant de du følger.", + "follow_suggestions.hints.most_followed": "Denne profilen er en av de på {domain} som har flest følgere.", + "follow_suggestions.hints.most_interactions": "Denne profilen fått mye oppmerksomhet i det siste på {domain}.", + "follow_suggestions.hints.similar_to_recently_followed": "Denne profilen ligner på profilene du nylig har fulgt.", + "follow_suggestions.personalized_suggestion": "Personlig forslag", + "follow_suggestions.popular_suggestion": "Populært forslag", + "follow_suggestions.popular_suggestion_longer": "Populært på {domain}", + "follow_suggestions.similar_to_recently_followed_longer": "Likner på profiler du nylig har fulgt", "follow_suggestions.view_all": "Vis alle", + "follow_suggestions.who_to_follow": "Hvem du kan følge", "followed_tags": "Fulgte emneknagger", "footer.about": "Om", "footer.directory": "Profilkatalog", @@ -291,6 +353,14 @@ "hashtag.follow": "Følg emneknagg", "hashtag.unfollow": "Slutt å følge emneknagg", "hashtags.and_other": "…og {count, plural, one{en til} other {# til}}", + "hints.profiles.followers_may_be_missing": "Følgere for denne profilen mangler kanskje.", + "hints.profiles.follows_may_be_missing": "Hvem denne profilen følger mangler kanskje.", + "hints.profiles.posts_may_be_missing": "Det kan hende at noen av innleggene til denne profilen mangler.", + "hints.profiles.see_more_followers": "Se flere følgere på {domain}", + "hints.profiles.see_more_follows": "Se flere som følger på {domain}", + "hints.profiles.see_more_posts": "Se flere innlegg på {domain}", + "hints.threads.replies_may_be_missing": "Svar fra andre servere mangler kanskje.", + "hints.threads.see_more": "Se flere svar på {domain}", "home.column_settings.show_reblogs": "Vis fremhevinger", "home.column_settings.show_replies": "Vis svar", "home.hide_announcements": "Skjul kunngjøring", @@ -298,6 +368,17 @@ "home.pending_critical_update.link": "Se oppdateringer", "home.pending_critical_update.title": "Kritisk sikkerhetsoppdatering er tilgjengelig!", "home.show_announcements": "Vis kunngjøring", + "ignore_notifications_modal.disclaimer": "Mastodon kan ikke informere brukere at du har ignorert deres varsler. Å ignorere varsler vil ikke stoppe meldinger selv fra å bli sendt.", + "ignore_notifications_modal.filter_instead": "Filtrer i stedet", + "ignore_notifications_modal.filter_to_act_users": "Du kan fremdeles akseptere, avvise eller rapportere brukere", + "ignore_notifications_modal.filter_to_avoid_confusion": "Filtrering bidrar til å unngå potensiell forvirring", + "ignore_notifications_modal.filter_to_review_separately": "Du kan gjennomgå filtrerte varsler for seg", + "ignore_notifications_modal.ignore": "Overse varsler", + "ignore_notifications_modal.limited_accounts_title": "Overse varsler fra modererte kontoer?", + "ignore_notifications_modal.new_accounts_title": "Overse varsler fra nye kontoer?", + "ignore_notifications_modal.not_followers_title": "Overse varsler fra folk som ikke følger deg?", + "ignore_notifications_modal.not_following_title": "Overse varsler fra folk du ikke følger?", + "ignore_notifications_modal.private_mentions_title": "Overse varsler fra uoppfordrede private omtaler?", "interaction_modal.description.favourite": "Med en konto på Mastodon, kan du favorittmarkere dette innlegget for å la forfatteren vite at du satte pris på det, og lagre innlegget til senere.", "interaction_modal.description.follow": "Med en konto på Mastodon, kan du følge {name} for å få innleggene deres i tidslinjen din.", "interaction_modal.description.reblog": "Med en konto på Mastodon, kan du fremheve dette innlegget for å dele det med dine egne følgere.", @@ -358,6 +439,8 @@ "limited_account_hint.action": "Vis profil likevel", "limited_account_hint.title": "Denne profilen har blitt skjult av moderatorene til {domain}.", "link_preview.author": "Av {name}", + "link_preview.more_from_author": "Mer fra {name}", + "link_preview.shares": "{count, plural, one {{counter} innlegg} other {{counter} innlegg}}", "lists.account.add": "Legg til i listen", "lists.account.remove": "Fjern fra listen", "lists.delete": "Slett listen", @@ -376,7 +459,17 @@ "loading_indicator.label": "Laster…", "media_gallery.toggle_visible": "Veksle synlighet", "moved_to_account_banner.text": "Din konto {disabledAccount} er for øyeblikket deaktivert fordi du flyttet til {movedToAccount}.", + "mute_modal.hide_from_notifications": "Ikke varsle", + "mute_modal.hide_options": "Skjul alternativer", + "mute_modal.indefinite": "Til jeg opphever dempingen", + "mute_modal.show_options": "Vis alternativer", + "mute_modal.they_can_mention_and_follow": "De kan nevne og følge deg, men du kommer ikke til å se dem.", + "mute_modal.they_wont_know": "De kommer ikke til å få vite at du har valgt å skjule dem.", + "mute_modal.title": "Demp bruker?", + "mute_modal.you_wont_see_mentions": "Du kommer ikke til å se innlegg som nevner dem.", + "mute_modal.you_wont_see_posts": "De kan fremdeles se dine innlegg, men du kommer ikke til å se deres.", "navigation_bar.about": "Om", + "navigation_bar.administration": "Administrasjon", "navigation_bar.advanced_interface": "Åpne i det avanserte nettgrensesnittet", "navigation_bar.blocks": "Blokkerte brukere", "navigation_bar.bookmarks": "Bokmerker", @@ -393,6 +486,7 @@ "navigation_bar.follows_and_followers": "Følginger og følgere", "navigation_bar.lists": "Lister", "navigation_bar.logout": "Logg ut", + "navigation_bar.moderation": "Moderering", "navigation_bar.mutes": "Dempede brukere", "navigation_bar.opened_in_classic_interface": "Innlegg, kontoer og andre spesifikke sider åpnes som standard i det klassiske webgrensesnittet.", "navigation_bar.personal": "Personlig", @@ -403,6 +497,7 @@ "navigation_bar.security": "Sikkerhet", "not_signed_in_indicator.not_signed_in": "Du må logge inn for å få tilgang til denne ressursen.", "notification.admin.report": "{name} rapporterte {target}", + "notification.admin.report_account": "{name} rapporterte {count, plural, one {et innlegg} other {# innlegg}} fra {target} for {category}", "notification.admin.sign_up": "{name} registrerte seg", "notification.favourite": "{name} favorittmarkerte innlegget ditt", "notification.follow": "{name} fulgte deg", @@ -417,6 +512,8 @@ "notifications.column_settings.admin.sign_up": "Nye registreringer:", "notifications.column_settings.alert": "Skrivebordsvarslinger", "notifications.column_settings.favourite": "Favoritter:", + "notifications.column_settings.filter_bar.advanced": "Vis alle kategorier", + "notifications.column_settings.filter_bar.category": "Hurtigfiltreringslinje", "notifications.column_settings.follow": "Nye følgere:", "notifications.column_settings.follow_request": "Nye følgerforespørsler:", "notifications.column_settings.mention": "Nevnt:", @@ -442,6 +539,23 @@ "notifications.permission_denied": "Skrivebordsvarsler er ikke tilgjengelige på grunn av tidligere nektet nettlesertillatelser", "notifications.permission_denied_alert": "Skrivebordsvarsler kan ikke aktiveres, ettersom lesertillatelse har blitt nektet før", "notifications.permission_required": "Skrivebordsvarsler er utilgjengelige fordi nødvendige rettigheter ikke er gitt.", + "notifications.policy.accept": "Godta", + "notifications.policy.accept_hint": "Vis i varsler", + "notifications.policy.drop": "Overse", + "notifications.policy.drop_hint": "Send til avgrunnen, for aldri å bli sett igjen", + "notifications.policy.filter": "Filter", + "notifications.policy.filter_hint": "Send til filtrert varslingsinnboks", + "notifications.policy.filter_limited_accounts_hint": "Begrenset av serverens moderatorer", + "notifications.policy.filter_limited_accounts_title": "Modererte kontoer", + "notifications.policy.filter_new_accounts.hint": "Opprettet {days, plural, one {den siste dagen} other {i de siste # dagene}}", + "notifications.policy.filter_new_accounts_title": "Nye kontoer", + "notifications.policy.filter_not_followers_hint": "Inkludert personer som har fulgt deg mindre enn {days, plural, one {en dag} other {# dager}}", + "notifications.policy.filter_not_followers_title": "Personer som ikke følger deg", + "notifications.policy.filter_not_following_hint": "Inntil du manuelt godkjenner dem", + "notifications.policy.filter_not_following_title": "Personer du ikke følger", + "notifications.policy.filter_private_mentions_hint": "Filtrert med mindre det er et svar som omtaler deg, eller hvis du følger avsenderen", + "notifications.policy.filter_private_mentions_title": "Uoppfordrede private omtaler", + "notifications.policy.title": "Behandle varsler fra…", "notifications_permission_banner.enable": "Skru på skrivebordsvarsler", "notifications_permission_banner.how_to_control": "For å motta varsler når Mastodon ikke er åpne, aktiver desktop varsler. Du kan kontrollere nøyaktig hvilke typer interaksjoner genererer skrivebordsvarsler gjennom {icon} -knappen ovenfor når de er aktivert.", "notifications_permission_banner.title": "Aldri gå glipp av noe", @@ -602,7 +716,7 @@ "sign_in_banner.sso_redirect": "Logg inn eller registrer deg", "status.admin_account": "Åpne moderatorgrensesnittet for @{name}", "status.admin_domain": "Åpne moderatorgrensesnittet for {domain}", - "status.admin_status": "Åpne denne statusen i moderatorgrensesnittet", + "status.admin_status": "Åpne dette innlegget i moderatorgrensesnittet", "status.block": "Blokker @{name}", "status.bookmark": "Bokmerke", "status.cancel_reblog_private": "Fjern fremheving", diff --git a/app/javascript/mastodon/locales/pt-BR.json b/app/javascript/mastodon/locales/pt-BR.json index 14957c16d4..e925246bf7 100644 --- a/app/javascript/mastodon/locales/pt-BR.json +++ b/app/javascript/mastodon/locales/pt-BR.json @@ -11,6 +11,7 @@ "about.not_available": "Esta informação não foi disponibilizada neste servidor.", "about.powered_by": "Redes sociais descentralizadas alimentadas por {mastodon}", "about.rules": "Regras do servidor", + "account.account_note_header": "Nota pessoal", "account.add_or_remove_from_list": "Adicionar ou remover de listas", "account.badges.bot": "Robô", "account.badges.group": "Grupo", @@ -61,6 +62,7 @@ "account.requested_follow": "{name} quer te seguir", "account.share": "Compartilhar perfil de @{name}", "account.show_reblogs": "Mostrar boosts de @{name}", + "account.statuses_counter": "{count, plural, one {{counter} publicação} other {{counter} publicações}}", "account.unblock": "Desbloquear @{name}", "account.unblock_domain": "Desbloquear domínio {domain}", "account.unblock_short": "Desbloquear", @@ -95,6 +97,8 @@ "block_modal.title": "Bloquear usuário?", "block_modal.you_wont_see_mentions": "Você não verá publicações que os mencionem.", "boost_modal.combo": "Pressione {combo} para pular isso na próxima vez", + "boost_modal.reblog": "Impulsionar a publicação?", + "boost_modal.undo_reblog": "Retirar o impulsionamento do post?", "bundle_column_error.copy_stacktrace": "Copiar relatório do erro", "bundle_column_error.error.body": "A página solicitada não pôde ser renderizada. Pode ser devido a um erro no nosso código, ou um problema de compatibilidade do seu navegador.", "bundle_column_error.error.title": "Ah, não!", @@ -190,6 +194,8 @@ "confirmations.unfollow.confirm": "Deixar de seguir", "confirmations.unfollow.message": "Você tem certeza de que deseja deixar de seguir {name}?", "confirmations.unfollow.title": "Deixar de seguir o usuário?", + "content_warning.hide": "Ocultar post", + "content_warning.show": "Mostrar mesmo assim", "conversation.delete": "Excluir conversa", "conversation.mark_as_read": "Marcar como lida", "conversation.open": "Ver conversa", @@ -297,6 +303,8 @@ "filter_modal.select_filter.subtitle": "Use uma categoria existente ou crie uma nova", "filter_modal.select_filter.title": "Filtrar esta publicação", "filter_modal.title.status": "Filtrar uma publicação", + "filter_warning.matches_filter": "Correspondente ao filtro “{title}”", + "filtered_notifications_banner.pending_requests": "Por {count, plural, =0 {no one} one {one person} other {# people}} que você talvez conheça", "filtered_notifications_banner.title": "Notificações filtradas", "firehose.all": "Tudo", "firehose.local": "Este servidor", @@ -345,6 +353,14 @@ "hashtag.follow": "Seguir hashtag", "hashtag.unfollow": "Parar de seguir hashtag", "hashtags.and_other": "…e {count, plural, one {}other {outros #}}", + "hints.profiles.followers_may_be_missing": "Os seguidores deste perfil podem estar faltando.", + "hints.profiles.follows_may_be_missing": "Os seguidores deste perfil podem estar faltando.", + "hints.profiles.posts_may_be_missing": "É possível que algumas publicações deste perfil estejam faltando.", + "hints.profiles.see_more_followers": "Ver mais seguidores no {domain}", + "hints.profiles.see_more_follows": "Ver mais seguidores no {domain}", + "hints.profiles.see_more_posts": "Ver mais publicações em {domain}", + "hints.threads.replies_may_be_missing": "Respostas de outros servidores podem estar faltando.", + "hints.threads.see_more": "Ver mais respostas no {domain}", "home.column_settings.show_reblogs": "Mostrar boosts", "home.column_settings.show_replies": "Mostrar respostas", "home.hide_announcements": "Ocultar comunicados", @@ -352,6 +368,13 @@ "home.pending_critical_update.link": "Ver atualizações", "home.pending_critical_update.title": "Atualização de segurança crítica disponível!", "home.show_announcements": "Mostrar comunicados", + "ignore_notifications_modal.disclaimer": "O Mastodon não pode informar aos usuários que você ignorou suas notificações. Ignorar notificações não impedirá que as próprias mensagens sejam enviadas.", + "ignore_notifications_modal.filter_instead": "Filtrar em vez disso", + "ignore_notifications_modal.filter_to_act_users": "Você ainda conseguirá aceitar, rejeitar ou denunciar usuários", + "ignore_notifications_modal.filter_to_avoid_confusion": "A filtragem ajuda a evitar confusão potencial", + "ignore_notifications_modal.filter_to_review_separately": "Você pode rever notificações filtradas separadamente", + "ignore_notifications_modal.ignore": "Ignorar notificações", + "ignore_notifications_modal.limited_accounts_title": "Ignorar notificações de contas moderadas?", "ignore_notifications_modal.new_accounts_title": "Ignorar notificações de novas contas?", "ignore_notifications_modal.not_followers_title": "Ignorar notificações de pessoas que não seguem você?", "ignore_notifications_modal.not_following_title": "Ignorar notificações de pessoas que você não segue?", @@ -446,6 +469,7 @@ "mute_modal.you_wont_see_mentions": "Você não verá publicações que os mencionem.", "mute_modal.you_wont_see_posts": "Eles ainda poderão ver suas publicações, mas você não verá as deles.", "navigation_bar.about": "Sobre", + "navigation_bar.administration": "Administração", "navigation_bar.advanced_interface": "Ativar na interface web avançada", "navigation_bar.blocks": "Usuários bloqueados", "navigation_bar.bookmarks": "Salvos", @@ -462,6 +486,7 @@ "navigation_bar.follows_and_followers": "Segue e seguidores", "navigation_bar.lists": "Listas", "navigation_bar.logout": "Sair", + "navigation_bar.moderation": "Moderação", "navigation_bar.mutes": "Usuários silenciados", "navigation_bar.opened_in_classic_interface": "Publicações, contas e outras páginas específicas são abertas por padrão na interface 'web' clássica.", "navigation_bar.personal": "Pessoal", @@ -472,10 +497,23 @@ "navigation_bar.security": "Segurança", "not_signed_in_indicator.not_signed_in": "Você precisa se autenticar para acessar este recurso.", "notification.admin.report": "{name} denunciou {target}", + "notification.admin.report_account": "{name} reportou {count, plural, one {Um post} other {# posts}} de {target} para {category}", + "notification.admin.report_account_other": "{name} reportou {count, plural, one {Um post} other {# posts}} de {target}", + "notification.admin.report_statuses": "{name} Reportou {target} para {category}", + "notification.admin.report_statuses_other": "{name} denunciou {target}", "notification.admin.sign_up": "{name} se inscreveu", + "notification.admin.sign_up.name_and_others": "{name} e {count, plural, one {# other} other {# outros}}", "notification.favourite": "{name} favoritou sua publicação", + "notification.favourite.name_and_others_with_link": "{name} e {count, plural, one {# outro} other {# others}} favoritaram a publicação", "notification.follow": "{name} te seguiu", + "notification.follow.name_and_others": "{name} e {count, plural, one {# other} other {# outros}} seguiu você", "notification.follow_request": "{name} quer te seguir", + "notification.follow_request.name_and_others": "{name} e {count, plural, one {# other} other {# outros}} pediu para seguir você", + "notification.label.mention": "Menção", + "notification.label.private_mention": "Menção privada", + "notification.label.private_reply": "Resposta privada", + "notification.label.reply": "Resposta", + "notification.mention": "Menção", "notification.moderation-warning.learn_more": "Aprender mais", "notification.moderation_warning": "Você recebeu um aviso de moderação", "notification.moderation_warning.action_delete_statuses": "Algumas das suas publicações foram removidas.", diff --git a/app/javascript/mastodon/locales/pt-PT.json b/app/javascript/mastodon/locales/pt-PT.json index e2414963c5..c5d84b9ac6 100644 --- a/app/javascript/mastodon/locales/pt-PT.json +++ b/app/javascript/mastodon/locales/pt-PT.json @@ -97,6 +97,8 @@ "block_modal.title": "Bloquear utilizador?", "block_modal.you_wont_see_mentions": "Não verá publicações que os mencionem.", "boost_modal.combo": "Pode clicar {combo} para não voltar a ver", + "boost_modal.reblog": "Impulsionar a publicação?", + "boost_modal.undo_reblog": "Retirar post?", "bundle_column_error.copy_stacktrace": "Copiar relatório de erros", "bundle_column_error.error.body": "A página solicitada não pôde ser sintetizada. Isto pode ser devido a uma falha no nosso código ou a um problema de compatibilidade com o navegador.", "bundle_column_error.error.title": "Ó, não!", @@ -192,6 +194,8 @@ "confirmations.unfollow.confirm": "Deixar de seguir", "confirmations.unfollow.message": "De certeza que queres deixar de seguir {name}?", "confirmations.unfollow.title": "Deixar de seguir utilizador?", + "content_warning.hide": "Ocultar publicação", + "content_warning.show": "Mostrar mesmo assim", "conversation.delete": "Eliminar conversa", "conversation.mark_as_read": "Marcar como lida", "conversation.open": "Ver conversa", @@ -299,6 +303,7 @@ "filter_modal.select_filter.subtitle": "Utilize uma categoria existente ou crie uma nova", "filter_modal.select_filter.title": "Filtrar esta publicação", "filter_modal.title.status": "Filtrar uma publicação", + "filter_warning.matches_filter": "Corresponde ao filtro “{title}”", "filtered_notifications_banner.pending_requests": "De {count, plural, =0 {ninguém} one {uma pessoa} other {# pessoas}} que pode conhecer", "filtered_notifications_banner.title": "Notificações filtradas", "firehose.all": "Todas", @@ -348,6 +353,12 @@ "hashtag.follow": "Seguir #etiqueta", "hashtag.unfollow": "Deixar de seguir #etiqueta", "hashtags.and_other": "…e {count, plural, other {mais #}}", + "hints.profiles.followers_may_be_missing": "Podem faltar seguidores neste perfil.", + "hints.profiles.follows_may_be_missing": "O número de perfis seguidos por este perfil pode faltar.", + "hints.profiles.posts_may_be_missing": "Podem faltar alguns posts deste perfil.", + "hints.profiles.see_more_followers": "Ver mais seguidores no {domain}", + "hints.profiles.see_more_follows": "Veja mais perfis seguidos em {domain}", + "hints.profiles.see_more_posts": "Ver mais posts em {domain}", "home.column_settings.show_reblogs": "Mostrar impulsos", "home.column_settings.show_replies": "Mostrar respostas", "home.hide_announcements": "Ocultar comunicações", diff --git a/app/javascript/mastodon/locales/sk.json b/app/javascript/mastodon/locales/sk.json index dfb1309ddf..3d7c5416c9 100644 --- a/app/javascript/mastodon/locales/sk.json +++ b/app/javascript/mastodon/locales/sk.json @@ -92,6 +92,7 @@ "block_modal.title": "Blokovať užívateľa?", "block_modal.you_wont_see_mentions": "Neuvidíš príspevky, ktoré ich spomínajú.", "boost_modal.combo": "Nabudúce môžete preskočiť stlačením {combo}", + "boost_modal.reblog": "Vyzdvihnúť príspevok?", "bundle_column_error.copy_stacktrace": "Kopírovať chybovú hlášku", "bundle_column_error.error.body": "Požadovanú stránku nebolo možné vykresliť. Môže to byť spôsobené chybou v našom kóde alebo problémom s kompatibilitou prehliadača.", "bundle_column_error.error.title": "Ale nie!", @@ -187,6 +188,8 @@ "confirmations.unfollow.confirm": "Prestať sledovať", "confirmations.unfollow.message": "Určite chcete prestať sledovať {name}?", "confirmations.unfollow.title": "Prestať sledovať užívateľa?", + "content_warning.hide": "Skryť príspevok", + "content_warning.show": "Aj tak zobraziť", "conversation.delete": "Vymazať konverzáciu", "conversation.mark_as_read": "Označiť ako prečítanú", "conversation.open": "Zobraziť konverzáciu", @@ -285,6 +288,7 @@ "filter_modal.select_filter.subtitle": "Použite existujúcu kategóriu alebo vytvorte novú", "filter_modal.select_filter.title": "Filtrovanie tohto príspevku", "filter_modal.title.status": "Filtrovanie príspevku", + "filter_warning.matches_filter": "Zhody triedenia “{title}”", "filtered_notifications_banner.title": "Filtrované oznámenia", "firehose.all": "Všetko", "firehose.local": "Tento server", @@ -424,6 +428,7 @@ "mute_modal.show_options": "Zobraziť možnosti", "mute_modal.title": "Stíšiť užívateľa?", "navigation_bar.about": "O tomto serveri", + "navigation_bar.administration": "Spravovanie", "navigation_bar.advanced_interface": "Otvoriť v pokročilom webovom rozhraní", "navigation_bar.blocks": "Blokované účty", "navigation_bar.bookmarks": "Záložky", @@ -440,6 +445,7 @@ "navigation_bar.follows_and_followers": "Sledovania a sledovatelia", "navigation_bar.lists": "Zoznamy", "navigation_bar.logout": "Odhlásiť sa", + "navigation_bar.moderation": "Moderovanie", "navigation_bar.mutes": "Stíšené účty", "navigation_bar.opened_in_classic_interface": "Príspevky, účty a iné špeciálne stránky sú predvolene otvárané v klasickom webovom rozhraní.", "navigation_bar.personal": "Osobné", @@ -474,8 +480,11 @@ "notification.update": "{name} upravuje príspevok", "notification_requests.accept": "Prijať", "notification_requests.dismiss": "Zamietnuť", + "notification_requests.edit_selection": "Uprav", + "notification_requests.exit_selection": "Hotovo", "notification_requests.notifications_from": "Oboznámenia od {name}", "notification_requests.title": "Filtrované oboznámenia", + "notification_requests.view": "Zobraz upozornenia", "notifications.clear": "Vyčistiť upozornenia", "notifications.clear_confirmation": "Určite chcete nenávratne odstrániť všetky svoje upozornenia?", "notifications.clear_title": "Vyčistiť upozornenia?", @@ -509,6 +518,9 @@ "notifications.permission_denied": "Upozornenia na ploche sú nedostupné pre už skôr zamietnutú požiadavku prehliadača", "notifications.permission_denied_alert": "Upozornenia na ploche nemôžu byť zapnuté, pretože požiadavka prehliadača bola už skôr zamietnutá", "notifications.permission_required": "Upozornenia na ploche sú nedostupné, pretože neboli udelené potrebné povolenia.", + "notifications.policy.drop": "Ignoruj", + "notifications.policy.filter": "Triediť", + "notifications.policy.filter_limited_accounts_title": "Moderované účty", "notifications.policy.filter_new_accounts_title": "Nové účty", "notifications.policy.filter_not_followers_title": "Ľudia, ktorí ťa nenasledujú", "notifications.policy.filter_not_following_title": "Ľudia, ktorých nenasleduješ", diff --git a/app/javascript/mastodon/locales/uk.json b/app/javascript/mastodon/locales/uk.json index 905938d158..714348db25 100644 --- a/app/javascript/mastodon/locales/uk.json +++ b/app/javascript/mastodon/locales/uk.json @@ -514,13 +514,13 @@ "notification.label.private_reply": "Приватна відповідь", "notification.label.reply": "Відповідь", "notification.mention": "Згадка", - "notification.moderation-warning.learn_more": "Дізнатися більше", + "notification.moderation-warning.learn_more": "Докладніше", "notification.moderation_warning": "Ви отримали попередження модерації", - "notification.moderation_warning.action_delete_statuses": "Деякі з ваших дописів було видалено.", + "notification.moderation_warning.action_delete_statuses": "Деякі з ваших дописів було вилучено.", "notification.moderation_warning.action_disable": "Ваш обліковий запис було вимкнено.", - "notification.moderation_warning.action_mark_statuses_as_sensitive": "Деякі з ваших дописів були позначені як чутливі.", + "notification.moderation_warning.action_mark_statuses_as_sensitive": "Деякі з ваших дописів були позначені делікатними.", "notification.moderation_warning.action_none": "Ваш обліковий запис отримав попередження модерації.", - "notification.moderation_warning.action_sensitive": "Відтепер ваші дописи будуть позначені як чутливі.", + "notification.moderation_warning.action_sensitive": "Відтепер ваші дописи будуть позначені делікатними.", "notification.moderation_warning.action_silence": "Ваш обліковий запис було обмежено.", "notification.moderation_warning.action_suspend": "Ваш обліковий запис було заблоковано.", "notification.own_poll": "Ваше опитування завершилося", diff --git a/app/javascript/mastodon/locales/vi.json b/app/javascript/mastodon/locales/vi.json index 48f56a0890..80a766683a 100644 --- a/app/javascript/mastodon/locales/vi.json +++ b/app/javascript/mastodon/locales/vi.json @@ -56,7 +56,7 @@ "account.no_bio": "Chưa có miêu tả.", "account.open_original_page": "Mở trang gốc", "account.posts": "Tút", - "account.posts_with_replies": "Lượt trả lời", + "account.posts_with_replies": "Trả lời", "account.report": "Báo cáo @{name}", "account.requested": "Đang chờ chấp thuận. Nhấp vào đây để hủy yêu cầu theo dõi", "account.requested_follow": "{name} yêu cầu theo dõi bạn", @@ -118,15 +118,15 @@ "closed_registrations_modal.title": "Đăng ký Mastodon", "column.about": "Giới thiệu", "column.blocks": "Người đã chặn", - "column.bookmarks": "Đã lưu", + "column.bookmarks": "Những tút đã lưu", "column.community": "Máy chủ này", "column.direct": "Nhắn riêng", "column.directory": "Tìm người cùng sở thích", "column.domain_blocks": "Máy chủ đã chặn", - "column.favourites": "Lượt thích", + "column.favourites": "Những tút đã thích", "column.firehose": "Bảng tin", "column.follow_requests": "Yêu cầu theo dõi", - "column.home": "Trang chính", + "column.home": "Trang chủ", "column.lists": "Danh sách", "column.mutes": "Người đã ẩn", "column.notifications": "Thông báo", @@ -368,8 +368,17 @@ "home.pending_critical_update.link": "Xem bản cập nhật", "home.pending_critical_update.title": "Có bản cập nhật bảo mật quan trọng!", "home.show_announcements": "Xem thông báo máy chủ", + "ignore_notifications_modal.disclaimer": "Mastodon sẽ không thông báo cho người dùng rằng bạn đã bỏ qua thông báo của họ. Họ sẽ vẫn có thể tương tác với bạn.", + "ignore_notifications_modal.filter_instead": "Lọc thay thế", "ignore_notifications_modal.filter_to_act_users": "Bạn vẫn có thể chấp nhận, từ chối hoặc báo cáo người khác", - "ignore_notifications_modal.filter_to_review_separately": "Bạn có thể xem lại các thông báo đã lọc riêng biệt", + "ignore_notifications_modal.filter_to_avoid_confusion": "Lọc giúp tránh nhầm lẫn tiềm ẩn", + "ignore_notifications_modal.filter_to_review_separately": "Bạn có thể xem lại riêng các thông báo đã lọc", + "ignore_notifications_modal.ignore": "Bỏ qua thông báo", + "ignore_notifications_modal.limited_accounts_title": "Bỏ qua thông báo từ các tài khoản bị kiểm duyệt?", + "ignore_notifications_modal.new_accounts_title": "Bỏ qua thông báo từ các tài khoản mới đăng ký?", + "ignore_notifications_modal.not_followers_title": "Bỏ qua thông báo từ những người chưa theo dõi bạn?", + "ignore_notifications_modal.not_following_title": "Bỏ qua thông báo từ những người bạn không theo dõi?", + "ignore_notifications_modal.private_mentions_title": "Bỏ qua thông báo từ những lượt Nhắn Riêng không mong muốn?", "interaction_modal.description.favourite": "Với tài khoản Mastodon, bạn có thể cho người đăng biết bạn thích tút này và lưu lại tút.", "interaction_modal.description.follow": "Với tài khoản Mastodon, bạn có thể theo dõi {name} để tút của họ hiện trên bảng tin của mình.", "interaction_modal.description.reblog": "Với tài khoản Mastodon, bạn có thể đăng lại tút này để chia sẻ nó với những người đang theo dõi bạn.", @@ -463,14 +472,14 @@ "navigation_bar.administration": "Quản trị", "navigation_bar.advanced_interface": "Dùng bố cục nhiều cột", "navigation_bar.blocks": "Người đã chặn", - "navigation_bar.bookmarks": "Đã lưu", + "navigation_bar.bookmarks": "Tút lưu", "navigation_bar.community_timeline": "Cộng đồng", "navigation_bar.compose": "Soạn tút mới", "navigation_bar.direct": "Nhắn riêng", "navigation_bar.discover": "Khám phá", "navigation_bar.domain_blocks": "Máy chủ đã ẩn", "navigation_bar.explore": "Xu hướng", - "navigation_bar.favourites": "Lượt thích", + "navigation_bar.favourites": "Tút thích", "navigation_bar.filters": "Bộ lọc từ ngữ", "navigation_bar.follow_requests": "Yêu cầu theo dõi", "navigation_bar.followed_tags": "Hashtag theo dõi", @@ -543,6 +552,7 @@ "notification_requests.minimize_banner": "Tinh giản banner lọc thông báo", "notification_requests.notifications_from": "Thông báo từ {name}", "notification_requests.title": "Thông báo đã lọc", + "notification_requests.view": "Hiện thông báo", "notifications.clear": "Xóa hết thông báo", "notifications.clear_confirmation": "Bạn thật sự muốn xóa vĩnh viễn tất cả thông báo của mình?", "notifications.clear_title": "Xóa hết thông báo?", @@ -579,6 +589,12 @@ "notifications.permission_denied": "Trình duyệt không cho phép hiển thị thông báo trên màn hình.", "notifications.permission_denied_alert": "Không thể bật thông báo trên màn hình bởi vì trình duyệt đã cấm trước đó", "notifications.permission_required": "Không hiện thông báo trên màn hình bởi vì chưa cho phép.", + "notifications.policy.accept": "Có", + "notifications.policy.accept_hint": "Hiện trong thông báo", + "notifications.policy.drop": "Không", + "notifications.policy.drop_hint": "Loại bỏ vĩnh viễn", + "notifications.policy.filter": "Lọc", + "notifications.policy.filter_hint": "Cho vào mục thông báo bị lọc", "notifications.policy.filter_limited_accounts_hint": "Chỉ dành cho kiểm duyệt viên", "notifications.policy.filter_limited_accounts_title": "Kiểm duyệt tài khoản", "notifications.policy.filter_new_accounts.hint": "Đã tạo trong vòng {days, plural, other {# ngày}}", @@ -589,6 +605,7 @@ "notifications.policy.filter_not_following_title": "Những người bạn không theo dõi", "notifications.policy.filter_private_mentions_hint": "Được lọc trừ khi nó trả lời lượt nhắc từ bạn hoặc nếu bạn theo dõi người gửi", "notifications.policy.filter_private_mentions_title": "Lượt nhắc riêng tư không được yêu cầu", + "notifications.policy.title": "Quản lý thông báo từ…", "notifications_permission_banner.enable": "Cho phép thông báo trên màn hình", "notifications_permission_banner.how_to_control": "Hãy bật thông báo trên màn hình để không bỏ lỡ những thông báo từ Mastodon. Một khi đã bật, bạn có thể lựa chọn từng loại thông báo khác nhau thông qua {icon} nút bên dưới.", "notifications_permission_banner.title": "Không bỏ lỡ điều thú vị nào", diff --git a/config/locales/doorkeeper.et.yml b/config/locales/doorkeeper.et.yml index 13d3f40fea..ffc42239a9 100644 --- a/config/locales/doorkeeper.et.yml +++ b/config/locales/doorkeeper.et.yml @@ -83,6 +83,7 @@ et: access_denied: Ressursi omanik või autoriseerimisserver lükkas taotluse tagasi. credential_flow_not_configured: Resource Owner Password Credentials vool ebaõnnestus, kuna Doorkeeper.configure.resource_owner_from_credentials ei ole seadistatud. invalid_client: Kliendi autentimine ebaõnnestus. Põhjus kas tundmatu klient, puudulik autentimine või toetamata autentimismeetod. + invalid_code_challenge_method: Code challenge meetod peab olema S256,, plain ei ole toetatud. invalid_grant: Antud autoriseerimisluba on vale, aegunud, tagasi võetud, ei kattu kasutatud ümbersuunamise URLid või oli antud teisele kliendile. invalid_redirect_uri: Antud ümbersuunamise URL ei ole õige. invalid_request: diff --git a/config/locales/doorkeeper.ja.yml b/config/locales/doorkeeper.ja.yml index 26f7ff5635..38c4d2c1aa 100644 --- a/config/locales/doorkeeper.ja.yml +++ b/config/locales/doorkeeper.ja.yml @@ -83,6 +83,7 @@ ja: access_denied: リソースの所有者または認証サーバーが要求を拒否しました。 credential_flow_not_configured: リソース所有者のパスワード Doorkeeper.configure.resource_owner_from_credentials が設定されていないためクレデンシャルフローに失敗しました。 invalid_client: 不明なクライアントであるか、クライアント情報が含まれていない、またはサポートされていない認証方法のため、クライアントの認証に失敗しました。 + invalid_code_challenge_method: code challenge methodはS256のみが利用可能です。plainはサポートされていません。 invalid_grant: 指定された認証許可は無効であるか、期限切れ、取り消されている、リダイレクトURIの不一致、または別のクライアントに発行されています。 invalid_redirect_uri: 無効なリダイレクトURIが含まれています。 invalid_request: diff --git a/config/locales/en-GB.yml b/config/locales/en-GB.yml index ca747953f6..012d0d91ee 100644 --- a/config/locales/en-GB.yml +++ b/config/locales/en-GB.yml @@ -31,6 +31,7 @@ en-GB: created_msg: Moderation note successfully created! destroyed_msg: Moderation note successfully destroyed! accounts: + add_email_domain_block: Block email domain approve: Approve approved_msg: Successfully approved %{username}'s sign-up application are_you_sure: Are you sure? @@ -57,6 +58,7 @@ en-GB: demote: Demote destroyed_msg: "%{username}'s data is now queued to be deleted imminently" disable: Freeze + disable_sign_in_token_auth: Disable email token authentication disable_two_factor_authentication: Disable 2FA disabled: Frozen display_name: Display name @@ -65,6 +67,7 @@ en-GB: email: Email email_status: Email status enable: Unfreeze + enable_sign_in_token_auth: Enable email token authentication enabled: Enabled enabled_msg: Successfully unfroze %{username}'s account followers: Followers @@ -129,6 +132,7 @@ en-GB: resubscribe: Resubscribe role: Role search: Search + search_same_email_domain: Other users with the same email domain search_same_ip: Other users with the same IP security: Security security_measures: @@ -169,10 +173,12 @@ en-GB: approve_appeal: Approve Appeal approve_user: Approve User assigned_to_self_report: Assign Report + change_email_user: Change Email for User change_role_user: Change Role of User confirm_user: Confirm User create_account_warning: Create Warning create_announcement: Create Announcement + create_canonical_email_block: Create Email Block create_custom_emoji: Create Custom Emoji create_domain_allow: Create Domain Allow create_domain_block: Create Domain Block @@ -1081,6 +1087,7 @@ en-GB: setup: email_settings_hint_html: Click the link we sent you to verify %{email}. We'll wait right here. link_not_received: Didn't get a link? + new_confirmation_instructions_sent: You will receive a new email with the confirmation link in a few minutes! title: Check your inbox sign_in: preamble_html: Log in with your %{domain} credentials. If your account is hosted on a different server, you will not be able to log in here. @@ -1091,7 +1098,9 @@ en-GB: title: Let's get you set up on %{domain}. status: account_status: Account status + confirming: Waiting for email confirmation to be completed. functional: Your account is fully operational. + pending: Your application is pending review by our staff. This may take some time. You will receive an email if your application is approved. redirecting_to: Your account is inactive because it is currently redirecting to %{acct}. self_destruct: As %{domain} is closing down, you will only get limited access to your account. view_strikes: View past strikes against your account @@ -1134,6 +1143,9 @@ en-GB: before: 'Before proceeding, please read these notes carefully:' caches: Content that has been cached by other servers may persist data_removal: Your posts and other data will be permanently removed + email_change_html: You can change your email address without deleting your account + email_contact_html: If it still doesn't arrive, you can email %{email} for help + email_reconfirmation_html: If you are not receiving the confirmation email, you can request it again irreversible: You will not be able to restore or reactivate your account more_details_html: For more details, see the privacy policy. username_available: Your username will become available again @@ -1366,6 +1378,7 @@ en-GB: authentication_methods: otp: two-factor authentication app password: password + sign_in_token: email security code webauthn: security keys description_html: If you see activity that you don't recognise, consider changing your password and enabling two-factor authentication. empty: No authentication history available @@ -1376,6 +1389,16 @@ en-GB: unsubscribe: action: Yes, unsubscribe complete: Unsubscribed + confirmation_html: Are you sure you want to unsubscribe from receiving %{type} for Mastodon on %{domain} to your email at %{email}? You can always re-subscribe from your email notification settings. + emails: + notification_emails: + favourite: favourite notification emails + follow: follow notification emails + follow_request: follow request emails + mention: mention notification emails + reblog: boost notification emails + resubscribe_html: If you've unsubscribed by mistake, you can re-subscribe from your email notification settings. + success_html: You'll no longer receive %{type} for Mastodon on %{domain} to your email at %{email}. title: Unsubscribe media_attachments: validations: @@ -1456,6 +1479,8 @@ en-GB: update: subject: "%{name} edited a post" notifications: + administration_emails: Admin email notifications + email_events: Events for email notifications email_events_hint: 'Select events that you want to receive notifications for:' number: human: @@ -1614,6 +1639,7 @@ en-GB: import: Import import_and_export: Import and export migrate: Account migration + notifications: Email notifications preferences: Preferences profile: Profile relationships: Follows and followers @@ -1860,6 +1886,7 @@ en-GB: invalid_otp_token: Invalid two-factor code otp_lost_help_html: If you lost access to both, you may get in touch with %{email} rate_limited: Too many authentication attempts, try again later. + seamless_external_login: You are logged in via an external service, so password and email settings are not available. signed_in_as: 'Logged in as:' verification: extra_instructions_html: Tip: The link on your website can be invisible. The important part is rel="me" which prevents impersonation on websites with user-generated content. You can even use a link tag in the header of the page instead of a, but the HTML must be accessible without executing JavaScript. diff --git a/config/locales/et.yml b/config/locales/et.yml index 547cc8a643..17fd41a8e3 100644 --- a/config/locales/et.yml +++ b/config/locales/et.yml @@ -215,6 +215,7 @@ et: update_custom_emoji: Uuendas kohandatud emotikoni update_domain_block: Uuenda domeenipiirangut update_ip_block: IP-reegli uuendamine + update_report: Uuendamise raport update_status: Uuenda postitust update_user_role: Uuenda rolli actions: @@ -445,6 +446,9 @@ et: title: Jälgimissoovitused unsuppress: Taasta jälgimissoovitused instances: + audit_log: + title: Viimatised auditi logid + view_all: Vaata täielikke auditi logisid availability: description_html: one: Kui domeenile edastamine nurjub %{count} päeval, siis ei tehta enam edastamiskatseid, välja arvatud juhul, kui domeenilt võetakse vastu saadetis. @@ -612,6 +616,7 @@ et: report: 'Teavitus #%{id}' reported_account: Teavitatud kontost reported_by: Teavitaja + reported_with_application: Raporteeritud rakendusega resolved: Lahendatud resolved_msg: Teavituse lahendamine õnnestus! skip_to_actions: Otsuste juurde @@ -850,7 +855,24 @@ et: action: Klõpsa lisainfo saamiseks siia message_html: "Objektihoidla on valesti seadistatud. Kasutajate privaatsus on ohustatud." tags: + moderation: + not_trendable: Pole trendis + not_usable: Pole kasutatav + pending_review: Ootab läbivaatust + review_requested: Taodeldud läbivaatust + reviewed: Läbivaadatud + title: Olek + trendable: Trendil + unreviewed: Läbivaatamata + usable: Kasutatav + name: Nimi + newest: Uusim + oldest: Vanim + open: Vaata avalikult + reset: Lähtesta review: Vaata olek üle + search: Otsi + title: Märksõnad updated_msg: Sildi sätted edukalt uuendatud title: Administreerimine trends: diff --git a/config/locales/fr.yml b/config/locales/fr.yml index 42554aeb39..c3fa237759 100644 --- a/config/locales/fr.yml +++ b/config/locales/fr.yml @@ -431,7 +431,7 @@ fr: no_file: Aucun fichier sélectionné export_domain_blocks: import: - description_html: Vous êtes sur le point d'importer une liste de bloqueurs de domaine. Veuillez examiner cette liste très attentivement, surtout si vous ne l'avez pas créée vous-même. + description_html: Vous êtes sur le point d'importer une liste de blocage de domaines. Veuillez examiner cette liste très attentivement, surtout si vous ne l'avez pas créée vous-même. existing_relationships_warning: Relations d'abonnement existantes private_comment_description_html: 'Pour vous aider à savoir d''où proviennent les blocages importés, ceux-ci seront créés avec le commentaire privé suivant : %{comment}' private_comment_template: Importé depuis %{source} le %{date} diff --git a/config/locales/ia.yml b/config/locales/ia.yml index 698c7c49e1..c282a17f92 100644 --- a/config/locales/ia.yml +++ b/config/locales/ia.yml @@ -31,6 +31,7 @@ ia: created_msg: Nota de moderation create con successo! destroyed_msg: Nota de moderation destruite con successo! accounts: + add_email_domain_block: Blocar dominio de e-mail approve: Approbar approved_msg: Demanda de inscription de %{username} approbate con successo are_you_sure: Es tu secur? @@ -57,6 +58,7 @@ ia: demote: Degradar destroyed_msg: Le datos de %{username} es ora in cauda pro lor imminente deletion disable: Gelar + disable_sign_in_token_auth: Disactivar le authentication per token in e-mail disable_two_factor_authentication: Disactivar A2F disabled: Gelate display_name: Nomine a monstrar @@ -65,6 +67,7 @@ ia: email: E-mail email_status: Stato de e-mail enable: Disgelar + enable_sign_in_token_auth: Activar le authentication per token in e-mail enabled: Activate enabled_msg: Conto de %{username} disgelate con successo followers: Sequitores @@ -129,6 +132,7 @@ ia: resubscribe: Resubscriber role: Rolo search: Cercar + search_same_email_domain: Altere usatores con le mesme dominio de e-mail search_same_ip: Altere usatores con le mesme IP security: Securitate security_measures: @@ -169,21 +173,26 @@ ia: approve_appeal: Approbar appello approve_user: Approbar usator assigned_to_self_report: Assignar reporto + change_email_user: Cambiar e-mail pro le usator change_role_user: Cambiar le rolo del usator confirm_user: Confirmar le usator create_account_warning: Crear un advertimento create_announcement: Crear annuncio + create_canonical_email_block: Crear blocada de e-mail create_custom_emoji: Crear emoji personalisate create_domain_allow: Crear permisso de dominio create_domain_block: Crear blocada de dominio + create_email_domain_block: Crear blocada de dominio de e-mail create_ip_block: Crear un regula IP create_unavailable_domain: Crear dominio indisponibile create_user_role: Crear un rolo demote_user: Degradar usator destroy_announcement: Deler annuncio + destroy_canonical_email_block: Deler blocada de e-mail destroy_custom_emoji: Deler emoji personalisate destroy_domain_allow: Deler permisso de dominio destroy_domain_block: Deler blocada de dominio + destroy_email_domain_block: Deler blocada de dominio de e-mail destroy_instance: Purgar dominio destroy_ip_block: Deler le regula IP destroy_status: Deler message @@ -191,8 +200,10 @@ ia: destroy_user_role: Destruer rolo disable_2fa_user: Disactivar A2F disable_custom_emoji: Disactivar emoji personalisate + disable_sign_in_token_auth_user: Disactivar le authentication per token de e-mail pro le usator disable_user: Disactivar le usator enable_custom_emoji: Activar emoji personalisate + enable_sign_in_token_auth_user: Activar le authentication per token de e-mail pro le usator enable_user: Activar le usator memorialize_account: Converter conto in memorial promote_user: Promover usator @@ -222,20 +233,26 @@ ia: approve_appeal_html: "%{name} approbava appello del decision de moderation de %{target}" approve_user_html: "%{name} approbava inscription de %{target}" assigned_to_self_report_html: "%{name} assignava reporto %{target} a se mesme" + change_email_user_html: "%{name} cambiava le adresse de e-mail address del usator %{target}" change_role_user_html: "%{name} cambiava rolo de %{target}" + confirm_user_html: "%{name} confirmava le adresse de e-mail del. usator %{target}" create_account_warning_html: "%{name} inviava un advertimento a %{target}" create_announcement_html: "%{name} creava un nove annuncio %{target}" + create_canonical_email_block_html: "%{name} blocava le e-mail con le hash %{target}" create_custom_emoji_html: "%{name} incargava le nove emoji %{target}" create_domain_allow_html: "%{name} permitteva federation con dominio %{target}" create_domain_block_html: "%{name} blocava dominio %{target}" + create_email_domain_block_html: "%{name} blocava le dominio de e-mail %{target}" create_ip_block_html: "%{name} creava regula pro IP %{target}" create_unavailable_domain_html: "%{name} stoppava livration al dominio %{target}" create_user_role_html: "%{name} creava rolo de %{target}" demote_user_html: "%{name} degradava usator %{target}" destroy_announcement_html: "%{name} deleva annuncio %{target}" + destroy_canonical_email_block_html: "%{name} disblocava le e-mail con le hash %{target}" destroy_custom_emoji_html: "%{name} deleva emoji %{target}" destroy_domain_allow_html: "%{name} impediva le federation con dominio %{target}" destroy_domain_block_html: "%{name} disblocava dominio %{target}" + destroy_email_domain_block_html: "%{name} disblocava le dominio de e-mail %{target}" destroy_instance_html: "%{name} purgava le dominio %{target}" destroy_ip_block_html: "%{name} deleva le regula pro IP %{target}" destroy_status_html: "%{name} removeva un message de %{target}" @@ -243,8 +260,10 @@ ia: destroy_user_role_html: "%{name} deleva le rolo %{target}" disable_2fa_user_html: "%{name} disactivava le authentication a duo factores pro le usator %{target}" disable_custom_emoji_html: "%{name} disactivava le emoji %{target}" + disable_sign_in_token_auth_user_html: "%{name} disactivava le authentication per token de e-mail pro %{target}" disable_user_html: "%{name} disactivava le apertura de session pro le usator %{target}" enable_custom_emoji_html: "%{name} activava le emoji %{target}" + enable_sign_in_token_auth_user_html: "%{name} activava le authentication per token de e-mail pro %{target}" enable_user_html: "%{name} activava le apertura de session pro le usator %{target}" memorialize_account_html: "%{name} converteva le conto de %{target} in un pagina commemorative" promote_user_html: "%{name} promoveva le usator %{target}" @@ -252,6 +271,7 @@ ia: reject_user_html: "%{name} refusava le inscription de %{target}" remove_avatar_user_html: "%{name} removeva le avatar de %{target}" reopen_report_html: "%{name} reaperiva le reporto %{target}" + resend_user_html: "%{name} reinviava le e-mail de confirmation pro %{target}" reset_password_user_html: "%{name} reinitialisava le contrasigno del usator %{target}" resolve_report_html: "%{name} resolveva le reporto %{target}" sensitive_account_html: "%{name} marcava le multimedia de %{target} como sensibile" @@ -412,6 +432,7 @@ ia: attempts_over_week: one: "%{count} tentativa de inscription in le ultime septimana" other: "%{count} tentativas de inscription in le ultime septimana" + created_msg: Le dominio de e-mail ha essite blocate con successo delete: Deler dns: types: @@ -420,8 +441,12 @@ ia: new: create: Adder un dominio resolve: Resolver dominio + title: Blocar un nove dominio de e-mail + no_email_domain_block_selected: Necun blocadas de dominio de e-mail ha essite cambiate perque necun ha essite seligite not_permitted: Non permittite + resolved_dns_records_hint_html: Le nomine de dominio se resolve al sequente dominios MX, le quales ha le ultime responsibilitate pro le reception de e-mail. Blocar un dominio MX blocara le inscriptiones de qualcunque adresse de e-mail que usa le mesme dominio MX, mesmo si le nomine de dominio visibile es differente. Presta attention a evitar de blocar le grande fornitores de e-mail. resolved_through_html: Resolvite per %{domain} + title: Dominios de e-mail blocate export_domain_allows: new: title: Importar permissiones de dominio @@ -868,10 +893,15 @@ ia: allow: Permitter approved: Approbate confirm_allow: Es tu secur que tu vole permitter le etiquettas seligite? + confirm_disallow: Es tu secur que tu vole cessar de permitter le etiquettas seligite? disallow: Refusar links: allow: Permitter ligamine allow_provider: Autorisar le publicator + confirm_allow: Es tu secur que tu vole permitter le ligamines seligite? + confirm_allow_provider: Es tu secur que tu vole permitter le fornitores seligite? + confirm_disallow: Es tu secur que tu vole cessar de permitter le ligamines seligite? + confirm_disallow_provider: Es tu secur que tu vole cessar de permitter le fornitores seligite? description_html: Istes es ligamines que es actualmente compartite multo per contos del quales tu servitor recipe messages. Illos pote adjutar tu usatores a discoperir lo que eveni in le mundo. Necun ligamine es monstrate publicamente usque tu autorisa le publicator. Tu pote tamben permitter o rejectar ligamines singule. disallow: Prohibir le ligamine disallow_provider: Prohibir le publicator @@ -895,6 +925,8 @@ ia: statuses: allow: Permitter message allow_account: Permitter autor + confirm_allow_account: Es tu secur que tu vole permitter le contos seligite? + confirm_disallow_account: Es tu secur que tu vole cessar de permitter le contos seligite? description_html: Istes es le messages cognoscite sur tu servitor que al momento es multo compartite e marcate como favorite. Illos pote adjutar tu usatores nove e reveniente a trovar plus personas a sequer. Necun message es monstrate publicamente usque tu approba le autor, a condition que le autor permitte que su conto es suggerite a alteres. Tu pote tamben permitter o rejectar messages singule. disallow: Non permitter message disallow_account: Non permitter autor @@ -1011,7 +1043,9 @@ ia: guide_link_text: Totes pote contribuer. sensitive_content: Contento sensibile application_mailer: + notification_preferences: Cambiar preferentias de e-mail salutation: "%{name}," + settings: 'Cambiar preferentias de e-mail: %{link}' unsubscribe: Desubscriber view: 'Visita:' view_profile: Vider profilo @@ -1031,6 +1065,7 @@ ia: hint_html: Solo un altere cosa! Nos debe confirmar que tu es un humano (de sorta que nos pote mantener le spam foras!). Solve le CAPTCHA infra e clicca sur "Continuar". title: Controlo de securitate confirmations: + awaiting_review: Tu adresse de e-mail es confirmate! Le personal de %{domain} ora revide tu registration. Tu recipera un e-mail si illes approba tu conto! awaiting_review_title: Tu inscription es in curso de revision clicking_this_link: cliccar sur iste ligamine login_link: aperir session @@ -1038,6 +1073,7 @@ ia: redirect_to_app_html: Tu deberea haber essite redirigite al app %{app_name}. Si isto non ha evenite, tenta %{clicking_this_link} o retornar manualmente al app. registration_complete: Tu inscription sur %{domain} es ora concludite! welcome_title: Benvenite, %{name}! + wrong_email_hint: Si ille adresse de e-mail non es correcte, tu pote cambiar lo in le parametros del conto. delete_account: Deler le conto delete_account_html: Si tu vole deler tu conto, tu pote facer lo hic. Te essera demandate un confirmation. description: @@ -1058,6 +1094,7 @@ ia: or_log_in_with: O aperi session con privacy_policy_agreement_html: Io ha legite e accepta le politica de confidentialitate progress: + confirm: Confirmar e-mail details: Tu detalios review: Nostre revision rules: Accepta le regulas @@ -1079,8 +1116,10 @@ ia: security: Securitate set_new_password: Definir un nove contrasigno setup: + email_below_hint_html: Consulta tu dossier de spam, o requesta un altere ligamine de confirmation. Tu pote corriger tu adresse de e-mail si illo es errate. email_settings_hint_html: Clicca sur le ligamine que nos te ha inviate pro verificar %{email}. Nos te attendera hic. link_not_received: Necun ligamine recipite? + new_confirmation_instructions_sent: Tu recipera un nove e-mail con le ligamine de confirmation in poc minutas! title: Consulta tu cassa de entrata sign_in: preamble_html: Aperi session con tu credentiales de %{domain}. Si tu conto es albergate sur un altere servitor, tu non potera aperir session hic. @@ -1091,7 +1130,9 @@ ia: title: Lassa nos installar tu conto sur %{domain}. status: account_status: Stato del conto + confirming: Attendente le termination del confirmation del adresse de e-mail. functional: Tu conto es completemente operative. + pending: Tu demanda attende le revision per nostre personal. Isto pote prender alcun tempore. Tu recipera un e-mail si tu demanda es approbate. redirecting_to: Tu conto es inactive perque illo actualmente redirige a %{acct}. self_destruct: Perque %{domain} va clauder, tu solo habera accesso limitate a tu conto. view_strikes: Examinar le sanctiones passate contra tu conto @@ -1134,6 +1175,9 @@ ia: before: 'Ante de continuar, per favor lege attentemente iste notas:' caches: Le contento que altere servitores ha immagazinate in cache pote persister data_removal: Tu messages e altere datos essera removite permanentemente + email_change_html: Tu pote cambiar tu adresse de e-mail sin deler tu conto + email_contact_html: Si illo ancora non arriva, tu pote inviar e-mail a %{email} pro peter adjuta + email_reconfirmation_html: Si tu non recipe le e-mail de confirmation, tu pote politica de confidentialitate. username_available: Tu nomine de usator essera disponibile novemente @@ -1377,6 +1421,16 @@ ia: unsubscribe: action: Si, desubscriber complete: Desubscribite + confirmation_html: Es tu secur de voler cancellar le subscription al %{type} de Mastodon sur %{domain} pro tu adresse de e-mail %{email}? Tu pote sempre resubscriber te a partir del parametros de notification in e-mail. + emails: + notification_emails: + favourite: notificationes de favorites in e-mail + follow: notificationes de sequimento in e-mail + follow_request: requestas de sequimento in e-mail + mention: notificationes de mentiones in e-mail + reblog: notificationes de impulsos in e-mail + resubscribe_html: Si tu ha cancellate le subscription in error, tu pote resubscriber te a partir del parametros de notification in e-mail. + success_html: Tu non recipera plus %{type} pro Mastodon sur %{domain} a tu adresse de e-mail %{email}. title: Desubcriber media_attachments: validations: @@ -1457,6 +1511,8 @@ ia: update: subject: "%{name} ha modificate un message" notifications: + administration_emails: Notificationes per e-mail pro administratores + email_events: Eventos pro notificationes per e-mail email_events_hint: 'Selige eventos pro le quales tu vole reciper notificationes:' number: human: @@ -1615,6 +1671,7 @@ ia: import: Importar import_and_export: Importar e exportar migrate: Migration de conto + notifications: Notificationes per e-mail preferences: Preferentias profile: Profilo public relationships: Sequites e sequitores @@ -1861,6 +1918,7 @@ ia: invalid_otp_token: Codice de duo factores non valide otp_lost_help_html: Si tu ha perdite le accesso a ambes, tu pote contactar %{email} rate_limited: Troppo de tentativas de authentication. Per favor reessaya plus tarde. + seamless_external_login: Tu ha aperite session per medio de un servicio externe. Le parametros de contrasigno e de e-mail es dunque indisponibile. signed_in_as: 'Session aperite como:' verification: extra_instructions_html: Consilio: Le ligamine sur tu sito web pote esser invisibile. Le parte importante es rel="me" que impedi le usurpation de identitate sur sitos web con contento generate per usatores. Tu pote mesmo usar un etiquetta link in le capite del pagina in vice de a, ma le codice HTML debe esser accessibile sin executar JavaScript. diff --git a/config/locales/ja.yml b/config/locales/ja.yml index ec7216b001..b54707c7cc 100644 --- a/config/locales/ja.yml +++ b/config/locales/ja.yml @@ -29,6 +29,7 @@ ja: created_msg: モデレーションメモを書き込みました! destroyed_msg: モデレーションメモを削除しました! accounts: + add_email_domain_block: メールのドメインをブロック approve: 承認 approved_msg: "%{username}さんの登録申請を承認しました" are_you_sure: 本当に実行しますか? @@ -55,6 +56,7 @@ ja: demote: 降格 destroyed_msg: "%{username}さんのデータは完全に削除されるよう登録されました" disable: 無効化 + disable_sign_in_token_auth: メールトークン認証を無効化 disable_two_factor_authentication: 二要素認証を無効にする disabled: 無効 display_name: 表示名 @@ -63,6 +65,7 @@ ja: email: メールアドレス email_status: メールアドレスの状態 enable: 有効化 + enable_sign_in_token_auth: メールトークン認証を有効化 enabled: 有効 enabled_msg: "%{username}の無効化を解除しました" followers: フォロワー数 @@ -126,6 +129,7 @@ ja: resubscribe: 再講読 role: ロール search: 検索 + search_same_email_domain: 同じメールドメインを持つ他のユーザ search_same_ip: 同じIPのユーザーを検索 security: 認証方法 security_measures: @@ -166,21 +170,26 @@ ja: approve_appeal: 抗議を承認 approve_user: ユーザーの承認 assigned_to_self_report: 通報の担当者に設定 + change_email_user: ユーザーのメールアドレスの変更 change_role_user: ユーザーのロールを変更 confirm_user: ユーザーの確認 create_account_warning: 警告を作成 create_announcement: お知らせを作成 + create_canonical_email_block: メールアドレスブロックの作成 create_custom_emoji: カスタム絵文字を作成 create_domain_allow: 連合を許可 create_domain_block: ドメインブロックを作成 + create_email_domain_block: メールドメインブロックを作成 create_ip_block: IPルールを作成 create_unavailable_domain: 配送できないドメインを作成 create_user_role: ロールを作成 demote_user: ユーザーを降格 destroy_announcement: お知らせを削除 + destroy_canonical_email_block: メールアドレスブロックの削除 destroy_custom_emoji: カスタム絵文字を削除 destroy_domain_allow: 連合許可を外す destroy_domain_block: ドメインブロックを削除 + destroy_email_domain_block: メールドメインブロックを削除 destroy_instance: ドメインをブロックする destroy_ip_block: IPルールを削除 destroy_status: 投稿を削除 @@ -188,8 +197,10 @@ ja: destroy_user_role: ロールを削除 disable_2fa_user: 二要素認証を無効化 disable_custom_emoji: カスタム絵文字を無効化 + disable_sign_in_token_auth_user: ユーザのメールトークン認証を無効化 disable_user: ユーザーを無効化 enable_custom_emoji: カスタム絵文字を有効化 + enable_sign_in_token_auth_user: ユーザのメールトークン認証を有効化 enable_user: ユーザーを有効化 memorialize_account: 追悼アカウント化 promote_user: ユーザーを昇格 @@ -219,20 +230,26 @@ ja: approve_appeal_html: "%{name}さんが%{target}さんからの抗議を承認しました" approve_user_html: "%{name}さんが%{target}さんからの登録を承認しました" assigned_to_self_report_html: "%{name}さんが通報 %{target}を自身の担当に割り当てました" + change_email_user_html: "%{name}さんが%{target}さんのメールアドレスを変更しました" change_role_user_html: "%{name}さんが%{target}さんのロールを変更しました" + confirm_user_html: "%{name}さんが%{target}さんのメールアドレスを確認済みにしました" create_account_warning_html: "%{name}さんが%{target}さんに警告メールを送信しました" create_announcement_html: "%{name}さんが新しいお知らせ %{target}を作成しました" + create_canonical_email_block_html: "%{name}さんがメールアドレス (ハッシュ値: %{target}) をブロックしました" create_custom_emoji_html: "%{name}さんがカスタム絵文字 %{target}を追加しました" create_domain_allow_html: "%{name}さんが%{target}の連合を許可しました" create_domain_block_html: "%{name}さんがドメイン %{target}をブロックしました" + create_email_domain_block_html: "%{name}さんがメールドメイン %{target} をブロックしました" create_ip_block_html: "%{name}さんがIP %{target}のルールを作成しました" create_unavailable_domain_html: "%{name}がドメイン %{target}への配送を停止しました" create_user_role_html: "%{name}さんがロール『%{target}』を作成しました" demote_user_html: "%{name}さんが%{target}さんを降格しました" destroy_announcement_html: "%{name}さんがお知らせ %{target}を削除しました" + destroy_canonical_email_block_html: "%{name}さんがメールアドレス (ハッシュ値: %{target}) のブロックを外しました" destroy_custom_emoji_html: "%{name}さんがカスタム絵文字『%{target}』を削除しました" destroy_domain_allow_html: "%{name}さんが%{target}の連合許可を外しました" destroy_domain_block_html: "%{name}さんがドメイン %{target}のブロックを外しました" + destroy_email_domain_block_html: "%{name} がメールドメイン %{target} のブロックを外しました" destroy_instance_html: "%{name}さんがドメイン %{target}をブロックしました" destroy_ip_block_html: "%{name}さんが IP %{target}のルールを削除しました" destroy_status_html: "%{name}さんが%{target}さんの投稿を削除しました" @@ -240,8 +257,10 @@ ja: destroy_user_role_html: "%{name}さんがロール『%{target}』を削除しました" disable_2fa_user_html: "%{name}さんが%{target}さんの二要素認証を無効化しました" disable_custom_emoji_html: "%{name}さんがカスタム絵文字 %{target}を無効化しました" + disable_sign_in_token_auth_user_html: "%{name} が %{target} のメールトークン認証を無効化しました" disable_user_html: "%{name}さんが%{target}さんのログインを無効化しました" enable_custom_emoji_html: "%{name}さんがカスタム絵文字 %{target}を有効化しました" + enable_sign_in_token_auth_user_html: "%{name} が %{target} のメールトークン認証を有効化しました" enable_user_html: "%{name}さんが%{target}さんのログインを有効化しました" memorialize_account_html: "%{name}さんが%{target}さんを追悼アカウントページに登録しました" promote_user_html: "%{name}さんが%{target}さんを昇格しました" @@ -249,6 +268,7 @@ ja: reject_user_html: "%{name}さんが%{target}さんからの登録を拒否しました" remove_avatar_user_html: "%{name}さんが%{target}さんのアイコンを削除しました" reopen_report_html: "%{name}さんが通報 %{target}を未解決に戻しました" + resend_user_html: "%{name}さんが %{target} の確認メールを再送信しました" reset_password_user_html: "%{name}さんが%{target}さんのパスワードをリセットしました" resolve_report_html: "%{name}さんが通報 %{target}を解決済みにしました" sensitive_account_html: "%{name}さんが%{target}さんのメディアを閲覧注意にマークしました" @@ -443,6 +463,9 @@ ja: title: おすすめフォロー unsuppress: おすすめフォローを復元 instances: + audit_log: + title: 最近の監査ログ + view_all: 全ての監査ログを閲覧 availability: description_html: other: ドメインへの配信が %{count} 日失敗した場合、そのドメインからの配信を受信しない限り、それ以上の配信を行いません。 @@ -565,6 +588,7 @@ ja: resolve_description_html: 報告されたアカウントに対していかなる措置も取られず、ストライクも記録されず、報告は終了します。 silence_description_html: このアカウントは、すでにフォローしている人、または手動で検索した人にしか見えないため、リーチが極端に制限されます。いつでも元に戻すことができます。このアカウントに対するすべての通報をクローズします。 suspend_description_html: アカウントとそのすべての内容にアクセスできなくなり、最終的に削除され、やり取りは不可能になります。 30日以内であれば元に戻すことができます。このアカウントに対するすべての通報をクローズします。 + actions_description_html: このレポートへのアクションを決定してください。アカウントへ懲罰的な措置を取った場合、Spanカテゴリが選択されている場合を除き、メール通知が送信されます。 actions_description_remote_html: この通報を解決するためのアクションを選択してください。これはあなたのサーバーがこのリモートアカウントと通信し、そのコンテンツを処理する時のみ影響します。 add_to_report: 通報にさらに追加 already_suspended_badges: @@ -629,6 +653,7 @@ ja: delete_data_html: 停止が解除されないまま30日経過すると、@%{acct}さんのプロフィールとコンテンツは削除されます preview_preamble_html: "@%{acct}さんに次の内容の警告を通知します:" record_strike_html: 今後、@%{acct}さんが違反行為をしたときにエスカレーションできるように、このアカウントに対するストライクを記録します + send_email_html: "@%{acct}さんに警告メールを送信します" warning_placeholder: アクションを行使する追加の理由(オプション) target_origin: 報告されたアカウントの起源 title: 通報 @@ -666,6 +691,7 @@ ja: manage_appeals: 抗議の管理 manage_appeals_description: ユーザーはモデレーションアクションに対する抗議を確認できます manage_blocks: ブロックの管理 + manage_blocks_description: メールプロバイダとIPアドレスのブロックを許可 manage_custom_emojis: カスタム絵文字を管理 manage_custom_emojis_description: ユーザーがサーバー上のカスタム絵文字を管理できるようにします manage_federation: 連合の管理 @@ -683,6 +709,7 @@ ja: manage_taxonomies: 分類の管理 manage_taxonomies_description: トレンドコンテンツの確認とハッシュタグの設定の更新 manage_user_access: アクセス権を管理 + manage_user_access_description: 他のユーザの二段階認証の無効化、メールアドレスの変更、パスワードリセットを許可 manage_users: ユーザーの管理 manage_users_description: 他のユーザーの詳細情報を閲覧し、モデレーションを行うことができます。 manage_webhooks: Webhookの管理 @@ -757,6 +784,7 @@ ja: destroyed_msg: ファイルを削除しました! software_updates: critical_update: "※緊急 (速やかに適用してください)" + description: Mastodonサーバーはいつでも最新の状態を保ち、新しい機能や修正を利用できるようにしておくことをおすすめします。またセキュリティの問題が発生した場合は、速やかにMastodonをアップデートすることが大切です。Mastodonは30分おきにアップデートを確認し、通知設定に応じて新しいアップデートをメールで通知します。 documentation_link: もっと見る release_notes: リリースノート title: 利用可能なアップデート @@ -843,16 +871,39 @@ ja: action: ここを開いて詳細を確認してください message_html: "オブジェクトストレージが正しく設定されていません。ユーザーのプライバシーが危険な状態になっています。" tags: + moderation: + not_trendable: トレンド不許可 + not_usable: 使用不可 + pending_review: 審査を保留中 + review_requested: 審査待ち + reviewed: 審査済 + title: ステータス + trendable: トレンド許可済 + unreviewed: 未審査 + usable: 使用可能 + name: タグ名 + newest: 新しい順 + oldest: 古い順 + open: タグ検索を見る + reset: リセット review: 審査状況 + search: 検索 + title: ハッシュタグ updated_msg: ハッシュタグ設定が更新されました title: 管理 trends: allow: 許可 approved: 承認 + confirm_allow: 本当に選択されたタグを許可しますか? + confirm_disallow: 本当に選択されたタグを禁止しますか? disallow: 拒否 links: allow: リンクの許可 allow_provider: 発行者の承認 + confirm_allow: 本当に選択されたリンクを許可しますか? + confirm_allow_provider: 本当に選択されたプロバイダを許可しますか? + confirm_disallow: 本当に選択されたリンクを禁止しますか? + confirm_disallow_provider: 本当に選択されたプロバイダを禁止しますか? description_html: これらは、多くのユーザーに共有されているリンクです。あなたのユーザーが世の中の動きを知るのに役立ちます。あなたが公開者を承認するまで、リンクは一般に表示されません。また、個別のリンクの許可・拒否も可能です。 disallow: リンクの拒否 disallow_provider: 発行者の拒否 @@ -875,6 +926,10 @@ ja: statuses: allow: 掲載を許可 allow_account: 投稿者を許可 + confirm_allow: 本当に選択されたトゥートを許可しますか? + confirm_allow_account: 本当に選択されたアカウントを許可しますか? + confirm_disallow: 本当に選択されたトゥートを禁止しますか? + confirm_disallow_account: 本当に選択されたアカウントを禁止しますか? description_html: これらは、このサーバーが知っている、たくさんシェアされ、お気に入り登録されている投稿です。新しいユーザーや久しぶりにアクセスするユーザーがフォローする人を探すのに役立ちます。あなたが投稿者を承認し、投稿者が許可するまで、表示されることはありません。また、個別の投稿を許可または拒否することもできます。 disallow: 掲載を拒否 disallow_account: 投稿者を拒否 @@ -989,7 +1044,9 @@ ja: guide_link_text: 誰でも参加することができます。 sensitive_content: 閲覧注意コンテンツ application_mailer: + notification_preferences: メール設定の変更 salutation: "%{name}さん" + settings: 'メール設定の変更: %{link}' unsubscribe: 購読解除 view: 'リンク:' view_profile: プロフィールを表示 @@ -1009,6 +1066,7 @@ ja: hint_html: もう一つだけ!あなたが人間であることを確認する必要があります(スパムを防ぐためです!)。 以下のCAPTCHAを解き、「続ける」をクリックします。 title: セキュリティチェック confirmations: + awaiting_review: メールアドレスが確認できました。%{domain} のスタッフからの審査をお待ちください。承認された場合、メールにより連絡します。 awaiting_review_title: 登録の審査待ちです clicking_this_link: このリンクを押す login_link: ログイン @@ -1016,6 +1074,7 @@ ja: redirect_to_app_html: 自動的に%{app_name}に戻らなかった場合、%{clicking_this_link}か、手動でアプリを切り替えてください。 registration_complete: "%{domain} へのアカウント登録が完了しました。" welcome_title: ようこそ、%{name}さん! + wrong_email_hint: メールアドレスが正しくない場合は、アカウント設定画面で変更できます。 delete_account: アカウントの削除 delete_account_html: アカウントを削除したい場合、こちらから手続きが行えます。削除する前に、確認画面があります。 description: @@ -1036,6 +1095,7 @@ ja: or_log_in_with: または次のサービスでログイン privacy_policy_agreement_html: プライバシーポリシーを読み、同意します progress: + confirm: メールアドレスの確認 details: ユーザー情報 review: 承認 rules: ルール @@ -1057,8 +1117,10 @@ ja: security: セキュリティ set_new_password: 新しいパスワード setup: + email_below_hint_html: 確認メールが迷惑メールフォルダに振り分けられていないか確認してください。メールアドレスを間違えた場合は、ここでメールアドレスの変更と確認メールの再送ができます。 email_settings_hint_html: メールに記載のリンクを開いて %{email} を確認してください。 link_not_received: 確認メールを受信できない場合は + new_confirmation_instructions_sent: 確認用のリンクを記載した新しいメールを送信しました title: 確認メールを送信しました sign_in: preamble_html: "%{domain} の資格情報でサインインします。 あなたのアカウントが別のサーバーでホストされている場合は、ここでログインすることはできません。" @@ -1069,7 +1131,9 @@ ja: title: さあ %{domain} でセットアップしましょう. status: account_status: アカウントの状態 + confirming: メールアドレスの確認が完了するのを待っています。 functional: アカウントは完全に機能しています。 + pending: あなたの申請は現在サーバー管理者による審査待ちです。これにはしばらくかかります。申請が承認されるとメールが届きます。 redirecting_to: アカウントは%{acct}に引っ越し設定されているため非アクティブになっています。 self_destruct: "%{domain} は閉鎖されるため、今後このアカウントでは限られた操作しかできません。" view_strikes: 過去のストライクを表示 @@ -1112,6 +1176,9 @@ ja: before: '続行する前に、次の点を再度確認してください:' caches: 他のサーバーにコンテンツのキャッシュがずっと残る場合があります data_removal: あなたの投稿やその他のデータはこのサーバーから完全に削除されます + email_change_html: アカウントを削除しなくてもメールアドレスを変更できます + email_contact_html: それでも届かない場合、%{email}までメールで問い合わせてください + email_reconfirmation_html: 確認メールが届かない場合はこちらから確認メールを再送してみてください irreversible: 削除操作の撤回やアカウントの復活はできません more_details_html: 詳しくはプライバシーポリシーをご覧ください。 username_available: あなたのユーザー名は再利用できるようになります @@ -1336,6 +1403,7 @@ ja: authentication_methods: otp: 二要素認証アプリ password: パスワード + sign_in_token: メール認証 webauthn: セキュリティキー description_html: 認識できないアクティビティが表示された場合は、パスワードの変更と二要素認証の有効化を検討してください。 empty: 利用可能な認証履歴がありません @@ -1436,6 +1504,8 @@ ja: update: subject: "%{name}さんが投稿を更新しました" notifications: + administration_emails: 管理にかかわるメール通知 + email_events: メールによる通知 email_events_hint: '受信する通知を選択:' number: human: @@ -1834,6 +1904,7 @@ ja: invalid_otp_token: 二要素認証コードが間違っています otp_lost_help_html: どちらも使用できない場合、%{email}に連絡を取ると解決できるかもしれません rate_limited: 認証に失敗した回数が多すぎます。時間をおいてからログインしてください。 + seamless_external_login: あなたは外部サービスを介してログインしているため、パスワードとメールアドレスの設定は利用できません。 signed_in_as: '下記でログイン中:' verification: extra_instructions_html: ワンポイント: webサイト上のプロフィールへのリンクは表示上見えなくてもかまいません。重要な部分は rel="me" で、これはユーザーが自由にリンクを作成可能なサイトを悪用してなりすまされるのを防ぐための情報です。a タグを配置する代わりに link タグをHTMLヘッダーに挿入することでも認証が可能です。ただし、HTMLにはJavaScriptを使わなくてもアクセスできるようにしてください。 diff --git a/config/locales/lad.yml b/config/locales/lad.yml index 40be2627da..0de73fd279 100644 --- a/config/locales/lad.yml +++ b/config/locales/lad.yml @@ -440,8 +440,11 @@ lad: create: Adjusta domeno resolve: Rezolve domeno title: Bloka muevo domeno de posta + no_email_domain_block_selected: No se tienen trokado blokos de domeno porke dinguno a sido eskojido not_permitted: Sin permiso + resolved_dns_records_hint_html: El nombre de domeno rezolve los sigientes domenos MX, los kualos son responsavles en ultima instansya de achetar la posta elektronika. Blokar un domeno MX blokara los rejistros de kualkier adreso de posta elektronika ke utilize el mezmo domeno MX, inkluzo si el nombre de domeno vizivle es desferente. Tenga kudiado de no blokar los prinsipales domenos de posta elektronika. resolved_through_html: Rezolvido por %{domain} + title: Domenos de posta blokados export_domain_allows: new: title: Importa permisos de domeno diff --git a/config/locales/lt.yml b/config/locales/lt.yml index fd3dbc00b1..6cc35d939d 100644 --- a/config/locales/lt.yml +++ b/config/locales/lt.yml @@ -582,6 +582,8 @@ lt: trending: Tendencinga with_media: Su medija system_checks: + database_schema_check: + message_html: Laukiama duomenų bazės perkėlimo. Paleisk juos, kad įsitikintum, jog programa veikia taip, kaip tikimasi. elasticsearch_health_yellow: message_html: Elasticsearch klasteris yra nesveikas (geltona būsena), galbūt norėsi išsiaiškinti priežastį elasticsearch_preset: @@ -836,7 +838,7 @@ lt: title: Nepavyko saugumo patvirtinimas '429': Stabdomas '500': - content: Atsiprašome, tačiau mūsų pusėje įvyko klaida. + content: Atsiprašome, bet kažkas nutiko ne taip mūsų pusėje. title: Netinkamas puslapis noscript_html: Kad naudotumėtės Mastodon web aplikacija, prašome įsijungti JavaScript. Alternatyviai, pabandykite viena iš vietinių aplikacijų Mastodon savo platformai. exports: diff --git a/config/locales/no.yml b/config/locales/no.yml index 1087e6485e..e2ede9328b 100644 --- a/config/locales/no.yml +++ b/config/locales/no.yml @@ -31,6 +31,7 @@ created_msg: Moderasjonsnotat laget uten problem! destroyed_msg: Moderasjonsnotat slettet uten problem! accounts: + add_email_domain_block: Blokker e-postdomenet approve: Godkjenn approved_msg: Godkjent %{username} sin registreringsapplikasjon are_you_sure: Er du sikker? diff --git a/config/locales/simple_form.et.yml b/config/locales/simple_form.et.yml index 2109ceb496..9fd9e238aa 100644 --- a/config/locales/simple_form.et.yml +++ b/config/locales/simple_form.et.yml @@ -314,6 +314,7 @@ et: listable: Luba sellel sildil ilmuda profiilide kataloogis name: Silt trendable: Luba sellel sildil trendida + usable: Luba seda märksõna postitustes kasutada lokaalselt user: role: Roll time_zone: Ajavöönd diff --git a/config/locales/simple_form.ia.yml b/config/locales/simple_form.ia.yml index 00226aee90..76990527a0 100644 --- a/config/locales/simple_form.ia.yml +++ b/config/locales/simple_form.ia.yml @@ -313,6 +313,7 @@ ia: listable: Permitter a iste hashtag apparer in le recercas e suggestiones name: Hashtag trendable: Permitter a iste hashtag de sub tendentias + usable: Permitter al messages usar iste hashtag localmente user: role: Rolo time_zone: Fuso horari diff --git a/config/locales/simple_form.ja.yml b/config/locales/simple_form.ja.yml index 7f4a9daeff..8815af9933 100644 --- a/config/locales/simple_form.ja.yml +++ b/config/locales/simple_form.ja.yml @@ -314,6 +314,7 @@ ja: listable: 検索とディレクトリへの使用を許可する name: ハッシュタグ trendable: トレンドへの表示を許可する + usable: このサーバーのユーザーがタグをつけて投稿することを許可する user: role: ロール time_zone: タイムゾーン diff --git a/config/locales/simple_form.kab.yml b/config/locales/simple_form.kab.yml index 16f4bdd416..68fc629d9e 100644 --- a/config/locales/simple_form.kab.yml +++ b/config/locales/simple_form.kab.yml @@ -20,7 +20,7 @@ kab: irreversible: Tisuffaɣ i tessazedgeḍ ad ttwakksent i lebda, ula ma tekkseḍ imsizdeg-nni ar zdat locale: Tutlayt n ugrudem, imaylen d walɣuten yettudemren password: Seqdec ma drus 8 n yisekkilen - setting_display_media_default: Ffer teywalt yettwacreḍ d tanafrit + setting_display_media_default: Ffer imidyaten yettwacreḍ d infariyen setting_display_media_hide_all: Ffer yal tikkelt akk taywalt setting_display_media_show_all: Ffer yal tikkelt teywalt yettwacreḍ d tanafrit username: Tzemreḍ ad tesqedceḍ isekkilen, uṭṭunen akked yijerriden n wadda diff --git a/config/locales/simple_form.uk.yml b/config/locales/simple_form.uk.yml index 1206714869..c6305598b1 100644 --- a/config/locales/simple_form.uk.yml +++ b/config/locales/simple_form.uk.yml @@ -85,7 +85,7 @@ uk: custom_css: Ви можете застосувати користувацькі стилі у вебверсії Mastodon. favicon: WEBP, PNG, GIF або JPG. Замінює стандартну піктограму Mastodon на власну. mascot: Змінює ілюстрацію в розширеному вебінтерфейсі. - media_cache_retention_period: Медіафайли з дописів віддалених користувачів кешуються на вашому сервері. Якщо встановлено додатне значення, медіа буде видалено через вказану кількість днів. Якщо медіа-дані будуть запитані після видалення, вони будуть завантажені повторно, якщо вихідний вміст все ще доступний. Через обмеження на частоту опитування карток попереднього перегляду посилань на сторонніх сайтах, рекомендується встановити це значення не менше 14 днів, інакше картки попереднього перегляду посилань не будуть оновлюватися на вимогу раніше цього часу. + media_cache_retention_period: Медіафайли з дописів віддалених користувачів кешуються на вашому сервері. Якщо встановлено додатне значення, медіа буде видалено через вказану кількість днів. Якщо медіадані будуть запитані після видалення, вони будуть завантажені повторно, якщо вихідний вміст все ще доступний. Через обмеження на частоту опитування карток попереднього перегляду посилань на сторонніх сайтах, рекомендується встановити це значення не менше 14 днів, інакше картки попереднього перегляду посилань не будуть оновлюватися на вимогу раніше цього часу. peers_api_enabled: Список доменів імен цього сервера з'явився у федівсесвіті. Сюди не входять дані чи ви пов'язані федерацією з цим сервером, а лише відомості, що вашому серверу відомо про нього. Його використовують служби, які збирають загальну статистику про федерації. profile_directory: У каталозі профілів перераховані всі користувачі, які погодились бути видимими. require_invite_text: Якщо реєстрація вимагає власноручного затвердження, зробіть текстове поле «Чому ви хочете приєднатися?» обов'язковим, а не додатковим diff --git a/config/locales/sk.yml b/config/locales/sk.yml index ac6134caa7..ad9f8fb5ee 100644 --- a/config/locales/sk.yml +++ b/config/locales/sk.yml @@ -35,6 +35,7 @@ sk: created_msg: Poznámka moderátora bola úspešne vytvorená! destroyed_msg: Moderátorska poznámka bola úspešne zmazaná! accounts: + add_email_domain_block: Blokuj emailovú doménu approve: Schváľ approved_msg: Úspešne schválená prihláška %{username} are_you_sure: Si si istý/á? @@ -170,10 +171,12 @@ sk: approve_appeal: Schváľ námietku approve_user: Odobri užívateľa assigned_to_self_report: Priraď hlásenie + change_email_user: Zmeň email pre užívateľa change_role_user: Zmeň užívateľskú rolu confirm_user: Potvrď užívateľa create_account_warning: Vytvor výstrahu create_announcement: Vytvor oboznámenie + create_canonical_email_block: Vytvor blokovanie emailu create_custom_emoji: Vytvor vlastné emotikony create_domain_allow: Vytvor povolenie pre doménu create_domain_block: Vytvor zákaz domény @@ -224,10 +227,13 @@ sk: change_role_user_html: "%{name} zmenil/a rolu pre %{target}" create_account_warning_html: "%{name} poslal/a upozornenie užívateľovi %{target}" create_announcement_html: "%{name} vytvoril/a nové oboznámenie %{target}" + create_canonical_email_block_html: "%{name} zablokoval/a email s hašom %{target}" create_custom_emoji_html: "%{name} nahral/a novú emotikonu %{target}" create_domain_allow_html: "%{name} povolil/a federáciu s doménou %{target}" create_domain_block_html: "%{name} zablokoval/a doménu %{target}" + create_email_domain_block_html: "%{name} zablokoval/a emailovú doménu %{target}" create_ip_block_html: "%{name} vytvoril/a pravidlo pre IP %{target}" + create_unavailable_domain_html: "%{name} pozastavil/a doručovanie k doméne %{target}" create_user_role_html: "%{name} vytvoril/a rolu pre %{target}" demote_user_html: "%{name} degradoval/a užívateľa %{target}" destroy_announcement_html: "%{name} vymazal/a oboznámenie %{target}" diff --git a/config/locales/uk.yml b/config/locales/uk.yml index faff0b4e42..c24ed77aef 100644 --- a/config/locales/uk.yml +++ b/config/locales/uk.yml @@ -786,7 +786,7 @@ uk: desc_html: Це залежить від зовнішніх скриптів hCaptcha, що може становити загрозу безпеці та приватності. Крім того, це може зробити процес реєстрації значно менш доступним для деяких людей (особливо з обмеженими можливостями). З цих причин, будь ласка, розгляньте альтернативні заходи, такі як реєстрація на основі схвалення або на основі запрошення. title: Вимагати нових користувачів розв'язувати CAPTCHA для підтвердження облікового запису content_retention: - danger_zone: Зони небезпеки + danger_zone: Небезпечна зона preamble: Контролюйте, як зберігаються користувацькі матеріали в Mastodon. title: Зберігання вмісту default_noindex: From 478155b015d0af5e7caf4e2aab4644cb6c6b9238 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Mon, 2 Sep 2024 10:35:28 +0200 Subject: [PATCH 029/153] Update dependency postcss to v8.4.43 (#31676) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index 451902a1d4..05de52b098 100644 --- a/yarn.lock +++ b/yarn.lock @@ -14016,13 +14016,13 @@ __metadata: linkType: hard "postcss@npm:^8.2.15, postcss@npm:^8.4.24, postcss@npm:^8.4.41": - version: 8.4.41 - resolution: "postcss@npm:8.4.41" + version: 8.4.43 + resolution: "postcss@npm:8.4.43" dependencies: nanoid: "npm:^3.3.7" picocolors: "npm:^1.0.1" source-map-js: "npm:^1.2.0" - checksum: 10c0/c1828fc59e7ec1a3bf52b3a42f615dba53c67960ed82a81df6441b485fe43c20aba7f4e7c55425762fd99c594ecabbaaba8cf5b30fd79dfec5b52a9f63a2d690 + checksum: 10c0/7cc9c6393ca00fcdca6fef8d119218df9357389b9fed30b6d4b463fc0e85159595a877f4ac0a2a565ea4c447cab1f424e527e68d8b7d40b8c94a6684663d45c5 languageName: node linkType: hard From 25d5e19b8348f40ee5b0fdb16b9a1f612031e26d Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Mon, 2 Sep 2024 10:35:51 +0200 Subject: [PATCH 030/153] Update DefinitelyTyped types (non-major) (#31683) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- yarn.lock | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/yarn.lock b/yarn.lock index 05de52b098..31dd9ab7d6 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3754,13 +3754,13 @@ __metadata: linkType: hard "@types/pg@npm:^8.6.6": - version: 8.11.6 - resolution: "@types/pg@npm:8.11.6" + version: 8.11.8 + resolution: "@types/pg@npm:8.11.8" dependencies: "@types/node": "npm:*" pg-protocol: "npm:*" pg-types: "npm:^4.0.1" - checksum: 10c0/e68e057d9500b25cd776f4fcc547b4880c4f3b0c7b6e03c8a0e5e262b6189dd7a00f4edc8937ffc55a9f6a136a78d7e4a9b6bbe6a46122a95c134f7be66f6842 + checksum: 10c0/040eb04edda338a13dccee47585b4479549fd54561e1bc3768690545adb8708a089b178e04fab9241935d7bad361314fc57af3ad87b391cfb9dc0895dd049763 languageName: node linkType: hard @@ -3917,12 +3917,12 @@ __metadata: linkType: hard "@types/react@npm:*, @types/react@npm:16 || 17 || 18, @types/react@npm:>=16.9.11, @types/react@npm:^18.2.7": - version: 18.3.4 - resolution: "@types/react@npm:18.3.4" + version: 18.3.5 + resolution: "@types/react@npm:18.3.5" dependencies: "@types/prop-types": "npm:*" csstype: "npm:^3.0.2" - checksum: 10c0/5c52e1e6f540cff21e3c2a5212066d02e005f6fb21e4a536a29097fae878db9f407cd7a4b43778f51359349c5f692e08bc77ddb5f5cecbfca9ca4d4e3c91a48e + checksum: 10c0/548b1d3d7c2f0242fbfdbbd658731b4ce69a134be072fa83e6ab516f2840402a3f20e3e7f72e95133b23d4880ef24a6d864050dc8e1f7c68f39fa87ca8445917 languageName: node linkType: hard From d1cca521e1a011255b91f9af9e0cdaebab6c0dab Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Mon, 2 Sep 2024 08:36:56 +0000 Subject: [PATCH 031/153] Update devDependencies (non-major) (#31686) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- yarn.lock | 52 ++++++++++++++++++++++++++-------------------------- 1 file changed, 26 insertions(+), 26 deletions(-) diff --git a/yarn.lock b/yarn.lock index 31dd9ab7d6..44e8ba025e 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1579,7 +1579,7 @@ __metadata: languageName: node linkType: hard -"@csstools/css-parser-algorithms@npm:^3.0.0, @csstools/css-parser-algorithms@npm:^3.0.1": +"@csstools/css-parser-algorithms@npm:^3.0.1": version: 3.0.1 resolution: "@csstools/css-parser-algorithms@npm:3.0.1" peerDependencies: @@ -1588,14 +1588,14 @@ __metadata: languageName: node linkType: hard -"@csstools/css-tokenizer@npm:^3.0.0, @csstools/css-tokenizer@npm:^3.0.1": +"@csstools/css-tokenizer@npm:^3.0.1": version: 3.0.1 resolution: "@csstools/css-tokenizer@npm:3.0.1" checksum: 10c0/c9ed4373e5731b5375ea9791590081019c04e95f08b46b272977e5e7b8c3d560affc62e82263cb8def1df1e57f0673140e7e16a14a5e7be04e6a234be088d1d3 languageName: node linkType: hard -"@csstools/media-query-list-parser@npm:^3.0.0, @csstools/media-query-list-parser@npm:^3.0.1": +"@csstools/media-query-list-parser@npm:^3.0.1": version: 3.0.1 resolution: "@csstools/media-query-list-parser@npm:3.0.1" peerDependencies: @@ -3380,8 +3380,8 @@ __metadata: linkType: hard "@testing-library/react@npm:^16.0.0": - version: 16.0.0 - resolution: "@testing-library/react@npm:16.0.0" + version: 16.0.1 + resolution: "@testing-library/react@npm:16.0.1" dependencies: "@babel/runtime": "npm:^7.12.5" peerDependencies: @@ -3395,7 +3395,7 @@ __metadata: optional: true "@types/react-dom": optional: true - checksum: 10c0/297f97bf4722dad05f11d9cafd47d387dbdb096fea4b79b876c7466460f0f2e345b55b81b3e37fc81ed8185c528cb53dd8455ca1b6b019b229edf6c796f11c9f + checksum: 10c0/67d05dec5ad5a2e6f92b6a3234af785435c7bb62bdbf12f3bfc89c9bca0c871a189e88c4ba023ed4cea504704c87c6ac7e86e24a3962df6c521ae89b62f48ff7 languageName: node linkType: hard @@ -11335,8 +11335,8 @@ __metadata: linkType: hard "lint-staged@npm:^15.0.0": - version: 15.2.9 - resolution: "lint-staged@npm:15.2.9" + version: 15.2.10 + resolution: "lint-staged@npm:15.2.10" dependencies: chalk: "npm:~5.3.0" commander: "npm:~12.1.0" @@ -11344,13 +11344,13 @@ __metadata: execa: "npm:~8.0.1" lilconfig: "npm:~3.1.2" listr2: "npm:~8.2.4" - micromatch: "npm:~4.0.7" + micromatch: "npm:~4.0.8" pidtree: "npm:~0.6.0" string-argv: "npm:~0.3.2" yaml: "npm:~2.5.0" bin: lint-staged: bin/lint-staged.js - checksum: 10c0/820c622378b62b826974af17f1747e2a4b0556e4fb99d101af89ad298d392ff079f580fdc576f16a27e975d726b95d73495fd524139402ff654c4649ef2f1a6a + checksum: 10c0/6ad7b41f5e87a84fa2eb1990080ea3c68a2f2031b4e81edcdc2a458cc878538eedb310e6f98ffd878a1287e1a52ac968e540ee8a0e96c247e04b0cbc36421cdd languageName: node linkType: hard @@ -11827,13 +11827,13 @@ __metadata: languageName: node linkType: hard -"micromatch@npm:^4.0.4, micromatch@npm:^4.0.7, micromatch@npm:~4.0.7": - version: 4.0.7 - resolution: "micromatch@npm:4.0.7" +"micromatch@npm:^4.0.4, micromatch@npm:^4.0.8, micromatch@npm:~4.0.8": + version: 4.0.8 + resolution: "micromatch@npm:4.0.8" dependencies: braces: "npm:^3.0.3" picomatch: "npm:^2.3.1" - checksum: 10c0/58fa99bc5265edec206e9163a1d2cec5fabc46a5b473c45f4a700adce88c2520456ae35f2b301e4410fb3afb27e9521fb2813f6fc96be0a48a89430e0916a772 + checksum: 10c0/166fa6eb926b9553f32ef81f5f531d27b4ce7da60e5baf8c021d043b27a388fb95e46a8038d5045877881e673f8134122b59624d5cecbd16eb50a42e7a6b5ca8 languageName: node linkType: hard @@ -16622,12 +16622,12 @@ __metadata: linkType: hard "stylelint@npm:^16.0.2": - version: 16.8.2 - resolution: "stylelint@npm:16.8.2" + version: 16.9.0 + resolution: "stylelint@npm:16.9.0" dependencies: - "@csstools/css-parser-algorithms": "npm:^3.0.0" - "@csstools/css-tokenizer": "npm:^3.0.0" - "@csstools/media-query-list-parser": "npm:^3.0.0" + "@csstools/css-parser-algorithms": "npm:^3.0.1" + "@csstools/css-tokenizer": "npm:^3.0.1" + "@csstools/media-query-list-parser": "npm:^3.0.1" "@csstools/selector-specificity": "npm:^4.0.0" "@dual-bundle/import-meta-resolve": "npm:^4.1.0" balanced-match: "npm:^2.0.0" @@ -16649,7 +16649,7 @@ __metadata: known-css-properties: "npm:^0.34.0" mathml-tag-names: "npm:^2.1.3" meow: "npm:^13.2.0" - micromatch: "npm:^4.0.7" + micromatch: "npm:^4.0.8" normalize-path: "npm:^3.0.0" picocolors: "npm:^1.0.1" postcss: "npm:^8.4.41" @@ -16660,13 +16660,13 @@ __metadata: resolve-from: "npm:^5.0.0" string-width: "npm:^4.2.3" strip-ansi: "npm:^7.1.0" - supports-hyperlinks: "npm:^3.0.0" + supports-hyperlinks: "npm:^3.1.0" svg-tags: "npm:^1.0.0" table: "npm:^6.8.2" write-file-atomic: "npm:^5.0.1" bin: stylelint: bin/stylelint.mjs - checksum: 10c0/898cde9b5d981f249133df709458eebf2af0a525e72410ddfafd76a7308f7da493578b6a909c593cc70061556b9eda1fed4f477385ee615435f0996d9e18d8df + checksum: 10c0/d3ff9c8945c56b04a2fa16ec33d163325496d5db94b6fcb5adf74c76f7f794ac992888273f9a3317652ba8b6195168b2ffff382ca2a667a241e2ace8c9505ae2 languageName: node linkType: hard @@ -16720,13 +16720,13 @@ __metadata: languageName: node linkType: hard -"supports-hyperlinks@npm:^3.0.0": - version: 3.0.0 - resolution: "supports-hyperlinks@npm:3.0.0" +"supports-hyperlinks@npm:^3.1.0": + version: 3.1.0 + resolution: "supports-hyperlinks@npm:3.1.0" dependencies: has-flag: "npm:^4.0.0" supports-color: "npm:^7.0.0" - checksum: 10c0/36aaa55e67645dded8e0f846fd81d7dd05ce82ea81e62347f58d86213577eb627b2b45298656ce7a70e7155e39f071d0d3f83be91e112aed801ebaa8db1ef1d0 + checksum: 10c0/78cc3e17eb27e6846fa355a8ebf343befe36272899cd409e45317a06c1997e95c23ff99d91080a517bd8c96508d4fa456e6ceb338c02ba5d7544277dbec0f10f languageName: node linkType: hard From 5439af327646de337b16e6706d412f8fbaffc8a7 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Mon, 2 Sep 2024 04:46:50 -0400 Subject: [PATCH 032/153] Bump Bundler/Ruby versions in lockfile, misc gem version bumps (#31666) --- Gemfile.lock | 61 ++++++++++++++++++++++++++++------------------------ 1 file changed, 33 insertions(+), 28 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index 8c43ef054a..11e8aee83b 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -100,8 +100,8 @@ GEM attr_required (1.0.2) awrence (1.2.1) aws-eventstream (1.3.0) - aws-partitions (1.966.0) - aws-sdk-core (3.201.5) + aws-partitions (1.969.0) + aws-sdk-core (3.202.1) aws-eventstream (~> 1, >= 1.3.0) aws-partitions (~> 1, >= 1.651.0) aws-sigv4 (~> 1.9) @@ -164,20 +164,22 @@ GEM activesupport (>= 5.2) elasticsearch (>= 7.14.0, < 8) elasticsearch-dsl + childprocess (5.1.0) + logger (~> 1.5) chunky_png (1.4.0) climate_control (1.2.0) cocoon (1.2.15) color_diff (0.1) concurrent-ruby (1.3.4) connection_pool (2.4.1) - cose (1.3.0) + cose (1.3.1) cbor (~> 0.5.9) openssl-signature_algorithm (~> 1.0) crack (1.0.0) bigdecimal rexml crass (1.0.6) - css_parser (1.17.1) + css_parser (1.19.0) addressable csv (3.3.0) database_cleaner-active_record (2.2.0) @@ -206,20 +208,21 @@ GEM diff-lcs (1.5.1) discard (1.3.0) activerecord (>= 4.2, < 8) - docile (1.4.0) + docile (1.4.1) domain_name (0.6.20240107) doorkeeper (5.7.1) railties (>= 5) dotenv (3.1.2) drb (2.2.1) ed25519 (1.3.0) - elasticsearch (7.17.10) - elasticsearch-api (= 7.17.10) - elasticsearch-transport (= 7.17.10) - elasticsearch-api (7.17.10) + elasticsearch (7.17.11) + elasticsearch-api (= 7.17.11) + elasticsearch-transport (= 7.17.11) + elasticsearch-api (7.17.11) multi_json elasticsearch-dsl (0.1.10) - elasticsearch-transport (7.17.10) + elasticsearch-transport (7.17.11) + base64 faraday (>= 1, < 3) multi_json email_spec (2.3.0) @@ -251,7 +254,7 @@ GEM faraday-httpclient (1.0.1) faraday-multipart (1.0.4) multipart-post (~> 2) - faraday-net_http (1.0.1) + faraday-net_http (1.0.2) faraday-net_http_persistent (1.2.0) faraday-patron (1.0.0) faraday-rack (1.0.0) @@ -308,11 +311,12 @@ GEM rainbow rubocop (>= 1.0) sysexits (~> 1.1) - hashdiff (1.1.0) + hashdiff (1.1.1) hashie (5.0.0) hcaptcha (7.1.0) json - highline (3.0.1) + highline (3.1.1) + reline hiredis (0.6.3) hkdf (0.3.0) htmlentities (4.3.4) @@ -392,8 +396,9 @@ GEM mime-types terrapin (>= 0.6.0, < 2.0) language_server-protocol (3.17.0.3) - launchy (2.5.2) + launchy (3.0.1) addressable (~> 2.8) + childprocess (~> 5.0) letter_opener (1.10.0) launchy (>= 2.2, < 4) letter_opener_web (3.0.0) @@ -430,19 +435,19 @@ GEM memory_profiler (1.0.2) mime-types (3.5.2) mime-types-data (~> 3.2015) - mime-types-data (3.2024.0702) + mime-types-data (3.2024.0820) mini_mime (1.1.5) mini_portile2 (2.8.7) minitest (5.25.1) msgpack (1.7.2) multi_json (1.15.0) - multipart-post (2.4.0) + multipart-post (2.4.1) mutex_m (0.2.0) net-http (0.4.1) uri net-http-persistent (4.0.2) connection_pool (~> 2.2) - net-imap (0.4.14) + net-imap (0.4.15) date net-protocol net-ldap (0.19.0) @@ -581,8 +586,8 @@ GEM orm_adapter (0.5.0) ostruct (0.6.0) ox (2.14.18) - parallel (1.25.1) - parser (3.3.4.0) + parallel (1.26.3) + parser (3.3.4.2) ast (~> 2.4.1) racc parslet (2.0.0) @@ -591,9 +596,9 @@ GEM pg (1.5.7) pghero (3.6.0) activerecord (>= 6.1) - premailer (1.23.0) + premailer (1.27.0) addressable - css_parser (>= 1.12.0) + css_parser (>= 1.19.0) htmlentities (>= 4.0.0) premailer-rails (1.12.0) actionmailer (>= 3) @@ -699,7 +704,7 @@ GEM rexml (3.3.6) strscan rotp (6.3.0) - rouge (4.2.1) + rouge (4.3.0) rpam2 (4.0.2) rqrcode (2.2.0) chunky_png (~> 1.0) @@ -744,7 +749,7 @@ GEM rubocop-ast (>= 1.31.1, < 2.0) ruby-progressbar (~> 1.7) unicode-display_width (>= 2.4.0, < 3.0) - rubocop-ast (1.31.3) + rubocop-ast (1.32.1) parser (>= 3.3.1.0) rubocop-capybara (2.21.0) rubocop (~> 1.41) @@ -835,9 +840,9 @@ GEM climate_control test-prof (1.4.1) thor (1.3.2) - tilt (2.3.0) + tilt (2.4.0) timeout (0.4.1) - tpm-key_attestation (0.12.0) + tpm-key_attestation (0.12.1) bindata (~> 2.4) openssl (> 2.0) openssl-signature_algorithm (~> 1.0) @@ -862,7 +867,7 @@ GEM unf_ext unf_ext (0.0.9.1) unicode-display_width (2.5.0) - uri (0.13.0) + uri (0.13.1) validate_email (0.1.6) activemodel (>= 3.0) mail (>= 2.2.5) @@ -1057,7 +1062,7 @@ DEPENDENCIES xorcist (~> 1.1) RUBY VERSION - ruby 3.3.2p78 + ruby 3.3.4p94 BUNDLED WITH - 2.5.11 + 2.5.18 From fc870c7e5ac7de96bfa90b67c013f87d62fc8fb2 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Mon, 2 Sep 2024 11:35:43 +0200 Subject: [PATCH 033/153] Update dependency postcss to v8.4.44 (#31691) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index 44e8ba025e..57e928c4de 100644 --- a/yarn.lock +++ b/yarn.lock @@ -14016,13 +14016,13 @@ __metadata: linkType: hard "postcss@npm:^8.2.15, postcss@npm:^8.4.24, postcss@npm:^8.4.41": - version: 8.4.43 - resolution: "postcss@npm:8.4.43" + version: 8.4.44 + resolution: "postcss@npm:8.4.44" dependencies: nanoid: "npm:^3.3.7" picocolors: "npm:^1.0.1" source-map-js: "npm:^1.2.0" - checksum: 10c0/7cc9c6393ca00fcdca6fef8d119218df9357389b9fed30b6d4b463fc0e85159595a877f4ac0a2a565ea4c447cab1f424e527e68d8b7d40b8c94a6684663d45c5 + checksum: 10c0/53c33338261a3d4f4198f8893e9dfe8b828d8d9186142ee85f02d228f04245c5bbe31239411a357a556ad20ed96f28db24d0921d63edc428fdc9133289371a1d languageName: node linkType: hard From a23b3747ac7131a1725748b386109732942120fc Mon Sep 17 00:00:00 2001 From: Claire Date: Mon, 2 Sep 2024 11:56:00 +0200 Subject: [PATCH 034/153] Fix N+1s in grouped notifications (#31638) --- .../api/v2_alpha/notifications_controller.rb | 20 +--- app/models/notification_group.rb | 105 ++++++++++++++---- .../rest/notification_group_serializer.rb | 11 +- 3 files changed, 88 insertions(+), 48 deletions(-) diff --git a/app/controllers/api/v2_alpha/notifications_controller.rb b/app/controllers/api/v2_alpha/notifications_controller.rb index a9f4ac02a0..13a016aeb7 100644 --- a/app/controllers/api/v2_alpha/notifications_controller.rb +++ b/app/controllers/api/v2_alpha/notifications_controller.rb @@ -13,7 +13,6 @@ class Api::V2Alpha::NotificationsController < Api::BaseController def index with_read_replica do @notifications = load_notifications - @group_metadata = load_group_metadata @grouped_notifications = load_grouped_notifications @relationships = StatusRelationshipsPresenter.new(target_statuses_from_notifications, current_user&.account_id) @presenter = GroupedNotificationsPresenter.new(@grouped_notifications, expand_accounts: expand_accounts_param) @@ -34,7 +33,7 @@ class Api::V2Alpha::NotificationsController < Api::BaseController 'app.notification_grouping.expand_accounts_param' => expand_accounts_param ) - render json: @presenter, serializer: REST::DedupNotificationGroupSerializer, relationships: @relationships, group_metadata: @group_metadata, expand_accounts: expand_accounts_param + render json: @presenter, serializer: REST::DedupNotificationGroupSerializer, relationships: @relationships, expand_accounts: expand_accounts_param end end @@ -48,7 +47,7 @@ class Api::V2Alpha::NotificationsController < Api::BaseController def show @notification = current_account.notifications.without_suspended.find_by!(group_key: params[:id]) - presenter = GroupedNotificationsPresenter.new([NotificationGroup.from_notification(@notification)]) + presenter = GroupedNotificationsPresenter.new(NotificationGroup.from_notifications([@notification])) render json: presenter, serializer: REST::DedupNotificationGroupSerializer end @@ -77,22 +76,9 @@ class Api::V2Alpha::NotificationsController < Api::BaseController end end - def load_group_metadata - return {} if @notifications.empty? - - MastodonOTELTracer.in_span('Api::V2Alpha::NotificationsController#load_group_metadata') do - browserable_account_notifications - .where(group_key: @notifications.filter_map(&:group_key)) - .where(id: (@notifications.last.id)..(@notifications.first.id)) - .group(:group_key) - .pluck(:group_key, 'min(notifications.id) as min_id', 'max(notifications.id) as max_id', 'max(notifications.created_at) as latest_notification_at') - .to_h { |group_key, min_id, max_id, latest_notification_at| [group_key, { min_id: min_id, max_id: max_id, latest_notification_at: latest_notification_at }] } - end - end - def load_grouped_notifications MastodonOTELTracer.in_span('Api::V2Alpha::NotificationsController#load_grouped_notifications') do - @notifications.map { |notification| NotificationGroup.from_notification(notification, max_id: @group_metadata.dig(notification.group_key, :max_id), grouped_types: params[:grouped_types]) } + NotificationGroup.from_notifications(@notifications, pagination_range: (@notifications.last.id)..(@notifications.first.id), grouped_types: params[:grouped_types]) end end diff --git a/app/models/notification_group.rb b/app/models/notification_group.rb index 12294f24ec..b6aa4d309c 100644 --- a/app/models/notification_group.rb +++ b/app/models/notification_group.rb @@ -1,38 +1,49 @@ # frozen_string_literal: true class NotificationGroup < ActiveModelSerializers::Model - attributes :group_key, :sample_accounts, :notifications_count, :notification, :most_recent_notification_id + attributes :group_key, :sample_accounts, :notifications_count, :notification, :most_recent_notification_id, :pagination_data # Try to keep this consistent with `app/javascript/mastodon/models/notification_group.ts` SAMPLE_ACCOUNTS_SIZE = 8 - def self.from_notification(notification, max_id: nil, grouped_types: nil) + def self.from_notifications(notifications, pagination_range: nil, grouped_types: nil) + return [] if notifications.empty? + grouped_types = grouped_types.presence&.map(&:to_sym) || Notification::GROUPABLE_NOTIFICATION_TYPES - groupable = notification.group_key.present? && grouped_types.include?(notification.type) - if groupable - # TODO: caching, and, if caching, preloading - scope = notification.account.notifications.where(group_key: notification.group_key) - scope = scope.where(id: ..max_id) if max_id.present? + grouped_notifications = notifications.filter { |notification| notification.group_key.present? && grouped_types.include?(notification.type) } + group_keys = grouped_notifications.pluck(:group_key) - # Ideally, we would not load accounts for each notification group - most_recent_notifications = scope.order(id: :desc).includes(:from_account).take(SAMPLE_ACCOUNTS_SIZE) - most_recent_id = most_recent_notifications.first.id - sample_accounts = most_recent_notifications.map(&:from_account) - notifications_count = scope.count - else - most_recent_id = notification.id - sample_accounts = [notification.from_account] - notifications_count = 1 + groups_data = load_groups_data(notifications.first.account_id, group_keys, pagination_range: pagination_range) + accounts_map = Account.where(id: groups_data.values.pluck(1).flatten).index_by(&:id) + + notifications.map do |notification| + if notification.group_key.present? && grouped_types.include?(notification.type) + most_recent_notification_id, sample_account_ids, count, *raw_pagination_data = groups_data[notification.group_key] + + pagination_data = raw_pagination_data.empty? ? nil : { min_id: raw_pagination_data[0], latest_notification_at: raw_pagination_data[1] } + + NotificationGroup.new( + notification: notification, + group_key: notification.group_key, + sample_accounts: sample_account_ids.map { |id| accounts_map[id] }, + notifications_count: count, + most_recent_notification_id: most_recent_notification_id, + pagination_data: pagination_data + ) + else + pagination_data = pagination_range.blank? ? nil : { min_id: notification.id, latest_notification_at: notification.created_at } + + NotificationGroup.new( + notification: notification, + group_key: "ungrouped-#{notification.id}", + sample_accounts: [notification.from_account], + notifications_count: 1, + most_recent_notification_id: notification.id, + pagination_data: pagination_data + ) + end end - - NotificationGroup.new( - notification: notification, - group_key: groupable ? notification.group_key : "ungrouped-#{notification.id}", - sample_accounts: sample_accounts, - notifications_count: notifications_count, - most_recent_notification_id: most_recent_id - ) end delegate :type, @@ -41,4 +52,50 @@ class NotificationGroup < ActiveModelSerializers::Model :account_relationship_severance_event, :account_warning, to: :notification, prefix: false + + class << self + private + + def load_groups_data(account_id, group_keys, pagination_range: nil) + return {} if group_keys.empty? + + if pagination_range.present? + binds = [ + account_id, + SAMPLE_ACCOUNTS_SIZE, + pagination_range.begin, + pagination_range.end, + ActiveRecord::Relation::QueryAttribute.new('group_keys', group_keys, ActiveRecord::ConnectionAdapters::PostgreSQL::OID::Array.new(ActiveModel::Type::String.new)), + ] + + ActiveRecord::Base.connection.select_all(<<~SQL.squish, 'grouped_notifications', binds).cast_values.to_h { |k, *values| [k, values] } + SELECT + groups.group_key, + (SELECT id FROM notifications WHERE notifications.account_id = $1 AND notifications.group_key = groups.group_key AND id <= $4 ORDER BY id DESC LIMIT 1), + array(SELECT from_account_id FROM notifications WHERE notifications.account_id = $1 AND notifications.group_key = groups.group_key AND id <= $4 ORDER BY id DESC LIMIT $2), + (SELECT count(*) FROM notifications WHERE notifications.account_id = $1 AND notifications.group_key = groups.group_key AND id <= $4) AS notifications_count, + (SELECT id FROM notifications WHERE notifications.account_id = $1 AND notifications.group_key = groups.group_key AND id >= $3 ORDER BY id ASC LIMIT 1) AS min_id, + (SELECT created_at FROM notifications WHERE notifications.account_id = $1 AND notifications.group_key = groups.group_key AND id <= $4 ORDER BY id DESC LIMIT 1) + FROM + unnest($5::text[]) AS groups(group_key); + SQL + else + binds = [ + account_id, + SAMPLE_ACCOUNTS_SIZE, + ActiveRecord::Relation::QueryAttribute.new('group_keys', group_keys, ActiveRecord::ConnectionAdapters::PostgreSQL::OID::Array.new(ActiveModel::Type::String.new)), + ] + + ActiveRecord::Base.connection.select_all(<<~SQL.squish, 'grouped_notifications', binds).cast_values.to_h { |k, *values| [k, values] } + SELECT + groups.group_key, + (SELECT id FROM notifications WHERE notifications.account_id = $1 AND notifications.group_key = groups.group_key ORDER BY id DESC LIMIT 1), + array(SELECT from_account_id FROM notifications WHERE notifications.account_id = $1 AND notifications.group_key = groups.group_key ORDER BY id DESC LIMIT $2), + (SELECT count(*) FROM notifications WHERE notifications.account_id = $1 AND notifications.group_key = groups.group_key) AS notifications_count + FROM + unnest($3::text[]) AS groups(group_key); + SQL + end + end + end end diff --git a/app/serializers/rest/notification_group_serializer.rb b/app/serializers/rest/notification_group_serializer.rb index b855f1cba9..7e8f00df3c 100644 --- a/app/serializers/rest/notification_group_serializer.rb +++ b/app/serializers/rest/notification_group_serializer.rb @@ -39,21 +39,18 @@ class REST::NotificationGroupSerializer < ActiveModel::Serializer end def page_min_id - range = instance_options[:group_metadata][object.group_key] - range.present? ? range[:min_id].to_s : object.notification.id.to_s + object.pagination_data[:min_id].to_s end def page_max_id - range = instance_options[:group_metadata][object.group_key] - range.present? ? range[:max_id].to_s : object.notification.id.to_s + object.most_recent_notification_id.to_s end def latest_page_notification_at - range = instance_options[:group_metadata][object.group_key] - range.present? ? range[:latest_notification_at] : object.notification.created_at + object.pagination_data[:latest_notification_at] end def paginated? - !instance_options[:group_metadata].nil? + object.pagination_data.present? end end From 388d5473e11f1e1b4119cf55b9f499cf87f87c8b Mon Sep 17 00:00:00 2001 From: David Roetzel Date: Mon, 2 Sep 2024 16:19:55 +0200 Subject: [PATCH 035/153] Refactor (ruby) redis configuration (#31694) --- ...s_configuration.rb => redis_connection.rb} | 29 ++- app/models/concerns/redisable.rb | 4 +- config/application.rb | 3 +- config/environments/development.rb | 2 +- config/environments/production.rb | 2 +- config/initializers/sidekiq.rb | 4 +- config/initializers/stoplight.rb | 2 +- .../20170920032311_fix_reblogs_in_feeds.rb | 2 +- ...00407202420_migrate_unavailable_inboxes.rb | 2 +- lib/chewy/strategy/mastodon.rb | 2 +- lib/mastodon/cli/base.rb | 2 +- lib/mastodon/cli/progress_helper.rb | 2 +- lib/mastodon/rack_middleware.rb | 2 +- lib/mastodon/redis_config.rb | 53 ------ lib/mastodon/redis_configuration.rb | 96 ++++++++++ lib/mastodon/sidekiq_middleware.rb | 2 +- spec/lib/mastodon/redis_configuration_spec.rb | 170 ++++++++++++++++++ spec/rails_helper.rb | 2 +- spec/services/resolve_account_service_spec.rb | 2 +- spec/support/streaming_server_manager.rb | 2 +- 20 files changed, 295 insertions(+), 90 deletions(-) rename app/lib/{redis_configuration.rb => redis_connection.rb} (65%) delete mode 100644 lib/mastodon/redis_config.rb create mode 100644 lib/mastodon/redis_configuration.rb create mode 100644 spec/lib/mastodon/redis_configuration_spec.rb diff --git a/app/lib/redis_configuration.rb b/app/lib/redis_connection.rb similarity index 65% rename from app/lib/redis_configuration.rb rename to app/lib/redis_connection.rb index fb1249640f..24e376e6a5 100644 --- a/app/lib/redis_configuration.rb +++ b/app/lib/redis_connection.rb @@ -1,6 +1,6 @@ # frozen_string_literal: true -class RedisConfiguration +class RedisConnection class << self def establish_pool(new_pool_size) @pool&.shutdown(&:close) @@ -22,33 +22,24 @@ class RedisConfiguration end end + attr_reader :config + + def initialize + @config = REDIS_CONFIGURATION.base + end + def connection - if namespace? + namespace = config[:namespace] + if namespace.present? Redis::Namespace.new(namespace, redis: raw_connection) else raw_connection end end - def namespace? - namespace.present? - end - - def namespace - ENV.fetch('REDIS_NAMESPACE', nil) - end - - def url - ENV['REDIS_URL'] - end - - def redis_driver - ENV.fetch('REDIS_DRIVER', 'hiredis') == 'ruby' ? :ruby : :hiredis - end - private def raw_connection - Redis.new(url: url, driver: redis_driver) + Redis.new(**config) end end diff --git a/app/models/concerns/redisable.rb b/app/models/concerns/redisable.rb index 0dad3abb2b..01763fa297 100644 --- a/app/models/concerns/redisable.rb +++ b/app/models/concerns/redisable.rb @@ -2,10 +2,10 @@ module Redisable def redis - Thread.current[:redis] ||= RedisConfiguration.pool.checkout + Thread.current[:redis] ||= RedisConnection.pool.checkout end def with_redis(&block) - RedisConfiguration.with(&block) + RedisConnection.with(&block) end end diff --git a/config/application.rb b/config/application.rb index 3c62a49228..0013c78858 100644 --- a/config/application.rb +++ b/config/application.rb @@ -101,7 +101,8 @@ module Mastodon end config.before_configuration do - require 'mastodon/redis_config' + require 'mastodon/redis_configuration' + ::REDIS_CONFIGURATION = Mastodon::RedisConfiguration.new config.x.use_vips = ENV['MASTODON_USE_LIBVIPS'] == 'true' diff --git a/config/environments/development.rb b/config/environments/development.rb index e4da60ac8e..74f0913da2 100644 --- a/config/environments/development.rb +++ b/config/environments/development.rb @@ -25,7 +25,7 @@ Rails.application.configure do config.action_controller.perform_caching = true config.action_controller.enable_fragment_cache_logging = true - config.cache_store = :redis_cache_store, REDIS_CACHE_PARAMS + config.cache_store = :redis_cache_store, REDIS_CONFIGURATION.cache config.public_file_server.headers = { 'Cache-Control' => "public, max-age=#{2.days.to_i}", } diff --git a/config/environments/production.rb b/config/environments/production.rb index b42f78b14e..5129b73e41 100644 --- a/config/environments/production.rb +++ b/config/environments/production.rb @@ -57,7 +57,7 @@ Rails.application.configure do config.log_tags = [:request_id] # Use a different cache store in production. - config.cache_store = :redis_cache_store, REDIS_CACHE_PARAMS + config.cache_store = :redis_cache_store, REDIS_CONFIGURATION.cache # Use a real queuing backend for Active Job (and separate queues per environment). # config.active_job.queue_adapter = :resque diff --git a/config/initializers/sidekiq.rb b/config/initializers/sidekiq.rb index 5b2f317bf2..5b281c4339 100644 --- a/config/initializers/sidekiq.rb +++ b/config/initializers/sidekiq.rb @@ -3,7 +3,7 @@ require_relative '../../lib/mastodon/sidekiq_middleware' Sidekiq.configure_server do |config| - config.redis = REDIS_SIDEKIQ_PARAMS + config.redis = REDIS_CONFIGURATION.sidekiq # This is used in Kubernetes setups, to signal that the Sidekiq process has started and will begin processing jobs # This comes from https://github.com/sidekiq/sidekiq/wiki/Kubernetes#sidekiq @@ -51,7 +51,7 @@ Sidekiq.configure_server do |config| end Sidekiq.configure_client do |config| - config.redis = REDIS_SIDEKIQ_PARAMS + config.redis = REDIS_CONFIGURATION.sidekiq config.client_middleware do |chain| chain.add SidekiqUniqueJobs::Middleware::Client diff --git a/config/initializers/stoplight.rb b/config/initializers/stoplight.rb index 7c13d50637..0ade504f67 100644 --- a/config/initializers/stoplight.rb +++ b/config/initializers/stoplight.rb @@ -3,6 +3,6 @@ require 'stoplight' Rails.application.reloader.to_prepare do - Stoplight.default_data_store = Stoplight::DataStore::Redis.new(RedisConfiguration.new.connection) + Stoplight.default_data_store = Stoplight::DataStore::Redis.new(RedisConnection.new.connection) Stoplight.default_notifiers = [Stoplight::Notifier::Logger.new(Rails.logger)] end diff --git a/db/migrate/20170920032311_fix_reblogs_in_feeds.rb b/db/migrate/20170920032311_fix_reblogs_in_feeds.rb index fd6ad39f08..e752915fb9 100644 --- a/db/migrate/20170920032311_fix_reblogs_in_feeds.rb +++ b/db/migrate/20170920032311_fix_reblogs_in_feeds.rb @@ -2,7 +2,7 @@ class FixReblogsInFeeds < ActiveRecord::Migration[5.1] def up - redis = RedisConfiguration.pool.checkout + redis = RedisConnection.pool.checkout fm = FeedManager.instance # Old scheme: diff --git a/db/migrate/20200407202420_migrate_unavailable_inboxes.rb b/db/migrate/20200407202420_migrate_unavailable_inboxes.rb index a79045839b..3caacbe90b 100644 --- a/db/migrate/20200407202420_migrate_unavailable_inboxes.rb +++ b/db/migrate/20200407202420_migrate_unavailable_inboxes.rb @@ -4,7 +4,7 @@ class MigrateUnavailableInboxes < ActiveRecord::Migration[5.2] disable_ddl_transaction! def up - redis = RedisConfiguration.pool.checkout + redis = RedisConnection.pool.checkout urls = redis.smembers('unavailable_inboxes') hosts = urls.filter_map do |url| diff --git a/lib/chewy/strategy/mastodon.rb b/lib/chewy/strategy/mastodon.rb index ee8b921865..a4b655c506 100644 --- a/lib/chewy/strategy/mastodon.rb +++ b/lib/chewy/strategy/mastodon.rb @@ -14,7 +14,7 @@ module Chewy end def leave - RedisConfiguration.with do |redis| + RedisConnection.with do |redis| redis.pipelined do |pipeline| @stash.each do |type, ids| pipeline.sadd("chewy:queue:#{type.name}", ids) diff --git a/lib/mastodon/cli/base.rb b/lib/mastodon/cli/base.rb index 93dec1fb8f..dfdcec57be 100644 --- a/lib/mastodon/cli/base.rb +++ b/lib/mastodon/cli/base.rb @@ -40,7 +40,7 @@ module Mastodon .dup .tap { |config| config['pool'] = options[:concurrency] + 1 } ) - RedisConfiguration.establish_pool(options[:concurrency]) + RedisConnection.establish_pool(options[:concurrency]) end end end diff --git a/lib/mastodon/cli/progress_helper.rb b/lib/mastodon/cli/progress_helper.rb index f22492afcf..5634343796 100644 --- a/lib/mastodon/cli/progress_helper.rb +++ b/lib/mastodon/cli/progress_helper.rb @@ -51,7 +51,7 @@ module Mastodon::CLI result = ActiveRecord::Base.connection_pool.with_connection do yield(item) ensure - RedisConfiguration.pool.checkin if Thread.current[:redis] + RedisConnection.pool.checkin if Thread.current[:redis] Thread.current[:redis] = nil end diff --git a/lib/mastodon/rack_middleware.rb b/lib/mastodon/rack_middleware.rb index 8aa7911fe7..0e452f06d6 100644 --- a/lib/mastodon/rack_middleware.rb +++ b/lib/mastodon/rack_middleware.rb @@ -19,7 +19,7 @@ class Mastodon::RackMiddleware end def clean_up_redis_socket! - RedisConfiguration.pool.checkin if Thread.current[:redis] + RedisConnection.pool.checkin if Thread.current[:redis] Thread.current[:redis] = nil end diff --git a/lib/mastodon/redis_config.rb b/lib/mastodon/redis_config.rb deleted file mode 100644 index c858b61a05..0000000000 --- a/lib/mastodon/redis_config.rb +++ /dev/null @@ -1,53 +0,0 @@ -# frozen_string_literal: true - -def setup_redis_env_url(prefix = nil, defaults = true) - prefix = "#{prefix.to_s.upcase}_" unless prefix.nil? - prefix = '' if prefix.nil? - - return if ENV["#{prefix}REDIS_URL"].present? - - password = ENV.fetch("#{prefix}REDIS_PASSWORD") { '' if defaults } - host = ENV.fetch("#{prefix}REDIS_HOST") { 'localhost' if defaults } - port = ENV.fetch("#{prefix}REDIS_PORT") { 6379 if defaults } - db = ENV.fetch("#{prefix}REDIS_DB") { 0 if defaults } - - ENV["#{prefix}REDIS_URL"] = begin - if [password, host, port, db].all?(&:nil?) - ENV['REDIS_URL'] - else - Addressable::URI.parse("redis://#{host}:#{port}/#{db}").tap do |uri| - uri.password = password if password.present? - end.normalize.to_str - end - end -end - -setup_redis_env_url -setup_redis_env_url(:cache, false) -setup_redis_env_url(:sidekiq, false) - -namespace = ENV.fetch('REDIS_NAMESPACE', nil) -cache_namespace = namespace ? "#{namespace}_cache" : 'cache' -sidekiq_namespace = namespace - -redis_driver = ENV.fetch('REDIS_DRIVER', 'hiredis') == 'ruby' ? :ruby : :hiredis - -REDIS_CACHE_PARAMS = { - driver: redis_driver, - url: ENV['CACHE_REDIS_URL'], - expires_in: 10.minutes, - namespace: "#{cache_namespace}:7.1", - connect_timeout: 5, - pool: { - size: Sidekiq.server? ? Sidekiq[:concurrency] : Integer(ENV['MAX_THREADS'] || 5), - timeout: 5, - }, -}.freeze - -REDIS_SIDEKIQ_PARAMS = { - driver: redis_driver, - url: ENV['SIDEKIQ_REDIS_URL'], - namespace: sidekiq_namespace, -}.freeze - -ENV['REDIS_NAMESPACE'] = "mastodon_test#{ENV['TEST_ENV_NUMBER']}" if Rails.env.test? diff --git a/lib/mastodon/redis_configuration.rb b/lib/mastodon/redis_configuration.rb new file mode 100644 index 0000000000..3cd121e4ac --- /dev/null +++ b/lib/mastodon/redis_configuration.rb @@ -0,0 +1,96 @@ +# frozen_string_literal: true + +class Mastodon::RedisConfiguration + def base + @base ||= { + url: setup_base_redis_url, + driver: driver, + namespace: base_namespace, + } + end + + def sidekiq + @sidekiq ||= { + url: setup_prefixed_redis_url(:sidekiq), + driver: driver, + namespace: sidekiq_namespace, + } + end + + def cache + @cache ||= { + url: setup_prefixed_redis_url(:cache), + driver: driver, + namespace: cache_namespace, + expires_in: 10.minutes, + connect_timeout: 5, + pool: { + size: Sidekiq.server? ? Sidekiq[:concurrency] : Integer(ENV['MAX_THREADS'] || 5), + timeout: 5, + }, + } + end + + private + + def driver + ENV['REDIS_DRIVER'] == 'ruby' ? :ruby : :hiredis + end + + def namespace + @namespace ||= ENV.fetch('REDIS_NAMESPACE', nil) + end + + def base_namespace + return "mastodon_test#{ENV.fetch('TEST_ENV_NUMBER', nil)}" if Rails.env.test? + + namespace + end + + def sidekiq_namespace + namespace + end + + def cache_namespace + namespace ? "#{namespace}_cache" : 'cache' + end + + def setup_base_redis_url + url = ENV.fetch('REDIS_URL', nil) + return url if url.present? + + user = ENV.fetch('REDIS_USER', '') + password = ENV.fetch('REDIS_PASSWORD', '') + host = ENV.fetch('REDIS_HOST', 'localhost') + port = ENV.fetch('REDIS_PORT', 6379) + db = ENV.fetch('REDIS_DB', 0) + + construct_uri(host, port, db, user, password) + end + + def setup_prefixed_redis_url(prefix) + prefix = "#{prefix.to_s.upcase}_" + url = ENV.fetch("#{prefix}REDIS_URL", nil) + + return url if url.present? + + user = ENV.fetch("#{prefix}REDIS_USER", nil) + password = ENV.fetch("#{prefix}REDIS_PASSWORD", nil) + host = ENV.fetch("#{prefix}REDIS_HOST", nil) + port = ENV.fetch("#{prefix}REDIS_PORT", nil) + db = ENV.fetch("#{prefix}REDIS_DB", nil) + + if host.nil? + base[:url] + else + construct_uri(host, port, db, user, password) + end + end + + def construct_uri(host, port, db, user, password) + Addressable::URI.parse("redis://#{host}:#{port}/#{db}").tap do |uri| + uri.user = user if user.present? + uri.password = password if password.present? + end.normalize.to_str + end +end diff --git a/lib/mastodon/sidekiq_middleware.rb b/lib/mastodon/sidekiq_middleware.rb index c5f4d8da35..8ce1124c69 100644 --- a/lib/mastodon/sidekiq_middleware.rb +++ b/lib/mastodon/sidekiq_middleware.rb @@ -53,7 +53,7 @@ class Mastodon::SidekiqMiddleware end def clean_up_redis_socket! - RedisConfiguration.pool.checkin if Thread.current[:redis] + RedisConnection.pool.checkin if Thread.current[:redis] Thread.current[:redis] = nil end diff --git a/spec/lib/mastodon/redis_configuration_spec.rb b/spec/lib/mastodon/redis_configuration_spec.rb new file mode 100644 index 0000000000..c7326fd411 --- /dev/null +++ b/spec/lib/mastodon/redis_configuration_spec.rb @@ -0,0 +1,170 @@ +# frozen_string_literal: true + +require 'rails_helper' + +RSpec.describe Mastodon::RedisConfiguration do + let(:redis_environment) { described_class.new } + + before do + # We use one numbered namespace per parallel test runner + # in the test env. This here should test the non-test + # behavior, so we disable it temporarily. + allow(Rails.env).to receive(:test?).and_return(false) + end + + shared_examples 'setting a different driver' do + context 'when setting the `REDIS_DRIVER` variable to `ruby`' do + around do |example| + ClimateControl.modify REDIS_DRIVER: 'ruby' do + example.run + end + end + + it 'sets the driver accordingly' do + expect(subject[:driver]).to eq :ruby + end + end + end + + shared_examples 'setting a namespace' do + context 'when setting the `REDIS_NAMESPACE` variable' do + around do |example| + ClimateControl.modify REDIS_NAMESPACE: 'testns' do + example.run + end + end + + it 'uses the value for the namespace' do + expect(subject[:namespace]).to eq 'testns' + end + end + end + + shared_examples 'secondary configuration' do |prefix| + context "when no `#{prefix}_REDIS_` environment variables are present" do + it 'uses the url from the base config' do + expect(subject[:url]).to eq 'redis://localhost:6379/0' + end + end + + context "when the `#{prefix}_REDIS_URL` environment variable is present" do + around do |example| + ClimateControl.modify "#{prefix}_REDIS_URL": 'redis::/user@other.example.com/4' do + example.run + end + end + + it 'uses the provided URL' do + expect(subject[:url]).to eq 'redis::/user@other.example.com/4' + end + end + + context 'when giving separate environment variables' do + around do |example| + ClimateControl.modify "#{prefix}_REDIS_PASSWORD": 'testpass1', "#{prefix}_REDIS_HOST": 'redis2.example.com', "#{prefix}_REDIS_PORT": '3322', "#{prefix}_REDIS_DB": '8' do + example.run + end + end + + it 'constructs the url from them' do + expect(subject[:url]).to eq 'redis://:testpass1@redis2.example.com:3322/8' + end + end + end + + describe '#base' do + subject { redis_environment.base } + + context 'when no `REDIS_` environment variables are present' do + it 'uses defaults' do + expect(subject).to eq({ + url: 'redis://localhost:6379/0', + driver: :hiredis, + namespace: nil, + }) + end + end + + context 'when the `REDIS_URL` environment variable is present' do + around do |example| + ClimateControl.modify REDIS_URL: 'redis::/user@example.com/2' do + example.run + end + end + + it 'uses the provided URL' do + expect(subject).to eq({ + url: 'redis::/user@example.com/2', + driver: :hiredis, + namespace: nil, + }) + end + end + + context 'when giving separate environment variables' do + around do |example| + ClimateControl.modify REDIS_PASSWORD: 'testpass', REDIS_HOST: 'redis.example.com', REDIS_PORT: '3333', REDIS_DB: '3' do + example.run + end + end + + it 'constructs the url from them' do + expect(subject).to eq({ + url: 'redis://:testpass@redis.example.com:3333/3', + driver: :hiredis, + namespace: nil, + }) + end + end + + include_examples 'setting a different driver' + include_examples 'setting a namespace' + end + + describe '#sidekiq' do + subject { redis_environment.sidekiq } + + include_examples 'secondary configuration', 'SIDEKIQ' + include_examples 'setting a different driver' + include_examples 'setting a namespace' + end + + describe '#cache' do + subject { redis_environment.cache } + + it 'includes extra configuration' do + expect(subject).to eq({ + url: 'redis://localhost:6379/0', + driver: :hiredis, + namespace: 'cache', + expires_in: 10.minutes, + connect_timeout: 5, + pool: { + size: 5, + timeout: 5, + }, + }) + end + + context 'when `REDIS_NAMESPACE` is not set' do + it 'uses the `cache` namespace' do + expect(subject[:namespace]).to eq 'cache' + end + end + + context 'when setting the `REDIS_NAMESPACE` variable' do + around do |example| + ClimateControl.modify REDIS_NAMESPACE: 'testns' do + example.run + end + end + + it 'attaches the `_cache` postfix to the namespace' do + expect(subject[:namespace]).to eq 'testns_cache' + end + end + + include_examples 'secondary configuration', 'CACHE' + include_examples 'setting a different driver' + end +end diff --git a/spec/rails_helper.rb b/spec/rails_helper.rb index 9af2d1e337..ba712c08f9 100644 --- a/spec/rails_helper.rb +++ b/spec/rails_helper.rb @@ -176,5 +176,5 @@ def stub_reset_connection_pools # TODO: Is there a better way to correctly run specs without stubbing this? # (Avoids reset_connection_pools! in test env) allow(ActiveRecord::Base).to receive(:establish_connection) - allow(RedisConfiguration).to receive(:establish_pool) + allow(RedisConnection).to receive(:establish_pool) end diff --git a/spec/services/resolve_account_service_spec.rb b/spec/services/resolve_account_service_spec.rb index e0084a1579..a856e019a7 100644 --- a/spec/services/resolve_account_service_spec.rb +++ b/spec/services/resolve_account_service_spec.rb @@ -228,7 +228,7 @@ RSpec.describe ResolveAccountService do rescue ActiveRecord::RecordNotUnique fail_occurred = true ensure - RedisConfiguration.pool.checkin if Thread.current[:redis] + RedisConnection.pool.checkin if Thread.current[:redis] end end diff --git a/spec/support/streaming_server_manager.rb b/spec/support/streaming_server_manager.rb index 376d6b8725..78cadcf6ad 100644 --- a/spec/support/streaming_server_manager.rb +++ b/spec/support/streaming_server_manager.rb @@ -17,7 +17,7 @@ class StreamingServerManager @running_thread = Thread.new do Open3.popen2e( { - 'REDIS_NAMESPACE' => ENV.fetch('REDIS_NAMESPACE'), + 'REDIS_NAMESPACE' => REDIS_CONFIGURATION.base[:namespace], 'DB_NAME' => "#{ENV.fetch('DB_NAME', 'mastodon')}_test#{ENV.fetch('TEST_ENV_NUMBER', '')}", 'RAILS_ENV' => ENV.fetch('RAILS_ENV', 'test'), 'NODE_ENV' => ENV.fetch('STREAMING_NODE_ENV', 'development'), From 40f993b3a0cadfdc9765363e89fdd222bc4c5c4f Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Mon, 2 Sep 2024 10:25:21 -0400 Subject: [PATCH 036/153] Use built-in `response.parsed_body` for JSON response specs (#31674) --- spec/requests/api/v1/admin/domain_blocks_spec.rb | 2 +- .../requests/api/v1/instances/translation_languages_spec.rb | 2 +- spec/requests/api/v1/lists_spec.rb | 4 ++-- spec/requests/api/v1/notifications/requests_spec.rb | 4 ++-- spec/requests/api/v1/statuses/sources_spec.rb | 4 ++-- spec/requests/api/v1/statuses_spec.rb | 2 +- spec/requests/api/v2/filters_spec.rb | 2 +- spec/requests/api/v2_alpha/notifications_spec.rb | 2 +- spec/spec_helper.rb | 6 +----- spec/support/matchers/json/match_json_schema.rb | 4 +++- 10 files changed, 15 insertions(+), 17 deletions(-) diff --git a/spec/requests/api/v1/admin/domain_blocks_spec.rb b/spec/requests/api/v1/admin/domain_blocks_spec.rb index 415281a932..3aa79d3ce5 100644 --- a/spec/requests/api/v1/admin/domain_blocks_spec.rb +++ b/spec/requests/api/v1/admin/domain_blocks_spec.rb @@ -94,7 +94,7 @@ RSpec.describe 'Domain Blocks' do subject expect(response).to have_http_status(200) - expect(body_as_json).to eq( + expect(body_as_json).to match( { id: domain_block.id.to_s, domain: domain_block.domain, diff --git a/spec/requests/api/v1/instances/translation_languages_spec.rb b/spec/requests/api/v1/instances/translation_languages_spec.rb index 0b7dd8314d..7cfb24e86f 100644 --- a/spec/requests/api/v1/instances/translation_languages_spec.rb +++ b/spec/requests/api/v1/instances/translation_languages_spec.rb @@ -26,7 +26,7 @@ describe 'Translation Languages' do .to have_http_status(200) expect(body_as_json) - .to eq({ und: %w(en de), en: ['de'] }) + .to match({ und: %w(en de), en: ['de'] }) end private diff --git a/spec/requests/api/v1/lists_spec.rb b/spec/requests/api/v1/lists_spec.rb index 4635e936f5..cf5ac28a56 100644 --- a/spec/requests/api/v1/lists_spec.rb +++ b/spec/requests/api/v1/lists_spec.rb @@ -60,7 +60,7 @@ RSpec.describe 'Lists' do subject expect(response).to have_http_status(200) - expect(body_as_json).to eq({ + expect(body_as_json).to match({ id: list.id.to_s, title: list.title, replies_policy: list.replies_policy, @@ -144,7 +144,7 @@ RSpec.describe 'Lists' do expect(response).to have_http_status(200) list.reload - expect(body_as_json).to eq({ + expect(body_as_json).to match({ id: list.id.to_s, title: list.title, replies_policy: list.replies_policy, diff --git a/spec/requests/api/v1/notifications/requests_spec.rb b/spec/requests/api/v1/notifications/requests_spec.rb index c385fb3499..45bb71adb0 100644 --- a/spec/requests/api/v1/notifications/requests_spec.rb +++ b/spec/requests/api/v1/notifications/requests_spec.rb @@ -133,7 +133,7 @@ RSpec.describe 'Requests' do subject expect(response).to have_http_status(200) - expect(body_as_json).to eq({ merged: true }) + expect(body_as_json).to match({ merged: true }) end end @@ -146,7 +146,7 @@ RSpec.describe 'Requests' do subject expect(response).to have_http_status(200) - expect(body_as_json).to eq({ merged: false }) + expect(body_as_json).to match({ merged: false }) end end end diff --git a/spec/requests/api/v1/statuses/sources_spec.rb b/spec/requests/api/v1/statuses/sources_spec.rb index 723b81905e..c7b1603824 100644 --- a/spec/requests/api/v1/statuses/sources_spec.rb +++ b/spec/requests/api/v1/statuses/sources_spec.rb @@ -22,7 +22,7 @@ RSpec.describe 'Sources' do subject expect(response).to have_http_status(200) - expect(body_as_json).to eq({ + expect(body_as_json).to match({ id: status.id.to_s, text: status.text, spoiler_text: status.spoiler_text, @@ -51,7 +51,7 @@ RSpec.describe 'Sources' do subject expect(response).to have_http_status(200) - expect(body_as_json).to eq({ + expect(body_as_json).to match({ id: status.id.to_s, text: status.text, spoiler_text: status.spoiler_text, diff --git a/spec/requests/api/v1/statuses_spec.rb b/spec/requests/api/v1/statuses_spec.rb index 2f99b35e74..3e91fcdd98 100644 --- a/spec/requests/api/v1/statuses_spec.rb +++ b/spec/requests/api/v1/statuses_spec.rb @@ -154,7 +154,7 @@ describe '/api/v1/statuses' do subject expect(response).to have_http_status(422) - expect(body_as_json[:unexpected_accounts].map { |a| a.slice(:id, :acct) }).to eq [{ id: bob.id.to_s, acct: bob.acct }] + expect(body_as_json[:unexpected_accounts].map { |a| a.slice(:id, :acct) }).to match [{ id: bob.id.to_s, acct: bob.acct }] end end diff --git a/spec/requests/api/v2/filters_spec.rb b/spec/requests/api/v2/filters_spec.rb index fd0483abbe..8609e7dca1 100644 --- a/spec/requests/api/v2/filters_spec.rb +++ b/spec/requests/api/v2/filters_spec.rb @@ -63,7 +63,7 @@ RSpec.describe 'Filters' do expect(json[:title]).to eq 'magic' expect(json[:filter_action]).to eq 'hide' expect(json[:context]).to eq ['home'] - expect(json[:keywords].map { |keyword| keyword.slice(:keyword, :whole_word) }).to eq [{ keyword: 'magic', whole_word: true }] + expect(json[:keywords].map { |keyword| keyword.slice(:keyword, :whole_word) }).to match [{ keyword: 'magic', whole_word: true }] end it 'creates a filter', :aggregate_failures do diff --git a/spec/requests/api/v2_alpha/notifications_spec.rb b/spec/requests/api/v2_alpha/notifications_spec.rb index 9d9eb34ebd..7663d215eb 100644 --- a/spec/requests/api/v2_alpha/notifications_spec.rb +++ b/spec/requests/api/v2_alpha/notifications_spec.rb @@ -235,7 +235,7 @@ RSpec.describe 'Notifications' do expect(response).to have_http_status(200) expect(body_as_json[:partial_accounts].size).to be > 0 - expect(body_as_json[:partial_accounts][0].keys).to contain_exactly(:acct, :avatar, :avatar_static, :bot, :id, :locked, :url) + expect(body_as_json[:partial_accounts][0].keys.map(&:to_sym)).to contain_exactly(:acct, :avatar, :avatar_static, :bot, :id, :locked, :url) expect(body_as_json[:partial_accounts].pluck(:id)).to_not include(recent_account.id.to_s) expect(body_as_json[:accounts].pluck(:id)).to include(recent_account.id.to_s) end diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 496ebfd09d..248c2c4105 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -39,11 +39,7 @@ RSpec.configure do |config| end def body_as_json - json_str_to_hash(response.body) -end - -def json_str_to_hash(str) - JSON.parse(str, symbolize_names: true) + response.parsed_body end def serialized_record_json(record, serializer, adapter: nil) diff --git a/spec/support/matchers/json/match_json_schema.rb b/spec/support/matchers/json/match_json_schema.rb index b4ced8addb..05dc1ee5a0 100644 --- a/spec/support/matchers/json/match_json_schema.rb +++ b/spec/support/matchers/json/match_json_schema.rb @@ -9,7 +9,9 @@ end RSpec::Matchers.define :match_json_values do |values| match do |string| - expect(json_str_to_hash(string)) + parsed_json = JSON.parse(string, symbolize_names: true) + + expect(parsed_json) .to include(values) end From 491033c86cc9c29302bfe68cc94dabad82ded4cc Mon Sep 17 00:00:00 2001 From: Christian Schmidt Date: Mon, 2 Sep 2024 17:30:48 +0200 Subject: [PATCH 037/153] Reject status creation with invalid `media_ids` parameter (#31681) --- app/services/post_status_service.rb | 3 +++ app/services/update_status_service.rb | 3 +++ config/locales/en.yml | 1 + spec/services/post_status_service_spec.rb | 15 +++++++++------ 4 files changed, 16 insertions(+), 6 deletions(-) diff --git a/app/services/post_status_service.rb b/app/services/post_status_service.rb index 8b18ce038d..727f9dc56b 100644 --- a/app/services/post_status_service.rb +++ b/app/services/post_status_service.rb @@ -134,6 +134,9 @@ class PostStatusService < BaseService @media = @account.media_attachments.where(status_id: nil).where(id: @options[:media_ids].take(Status::MEDIA_ATTACHMENTS_LIMIT).map(&:to_i)) + not_found_ids = @options[:media_ids] - @media.map(&:id) + raise Mastodon::ValidationError, I18n.t('media_attachments.validations.not_found', ids: not_found_ids.join(', ')) if not_found_ids.any? + raise Mastodon::ValidationError, I18n.t('media_attachments.validations.images_and_video') if @media.size > 1 && @media.find(&:audio_or_video?) raise Mastodon::ValidationError, I18n.t('media_attachments.validations.not_ready') if @media.any?(&:not_processed?) end diff --git a/app/services/update_status_service.rb b/app/services/update_status_service.rb index dc7d177e2d..cd82a0b997 100644 --- a/app/services/update_status_service.rb +++ b/app/services/update_status_service.rb @@ -73,6 +73,9 @@ class UpdateStatusService < BaseService media_attachments = @status.account.media_attachments.where(status_id: [nil, @status.id]).where(scheduled_status_id: nil).where(id: @options[:media_ids].take(Status::MEDIA_ATTACHMENTS_LIMIT).map(&:to_i)).to_a + not_found_ids = @options[:media_ids] - media_attachments.map(&:id) + raise Mastodon::ValidationError, I18n.t('media_attachments.validations.not_found', ids: not_found_ids.join(', ')) if not_found_ids.any? + raise Mastodon::ValidationError, I18n.t('media_attachments.validations.images_and_video') if media_attachments.size > 1 && media_attachments.find(&:audio_or_video?) raise Mastodon::ValidationError, I18n.t('media_attachments.validations.not_ready') if media_attachments.any?(&:not_processed?) diff --git a/config/locales/en.yml b/config/locales/en.yml index 99dcb657f4..267e04618b 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -1454,6 +1454,7 @@ en: media_attachments: validations: images_and_video: Cannot attach a video to a post that already contains images + not_found: Media %{ids} not found or already attached to another post not_ready: Cannot attach files that have not finished processing. Try again in a moment! too_many: Cannot attach more than 4 files migrations: diff --git a/spec/services/post_status_service_spec.rb b/spec/services/post_status_service_spec.rb index f21548b5f2..5857263f61 100644 --- a/spec/services/post_status_service_spec.rb +++ b/spec/services/post_status_service_spec.rb @@ -229,13 +229,16 @@ RSpec.describe PostStatusService do account = Fabricate(:account) media = Fabricate(:media_attachment, account: Fabricate(:account)) - subject.call( - account, - text: 'test status update', - media_ids: [media.id] + expect do + subject.call( + account, + text: 'test status update', + media_ids: [media.id] + ) + end.to raise_error( + Mastodon::ValidationError, + I18n.t('media_attachments.validations.not_found', ids: media.id) ) - - expect(media.reload.status).to be_nil end it 'does not allow attaching more files than configured limit' do From c1795ee9639b56d14687416135c627bb99efbff2 Mon Sep 17 00:00:00 2001 From: Claire Date: Mon, 2 Sep 2024 22:14:04 +0200 Subject: [PATCH 038/153] Fix not being able to load more notifications after trimming (#31652) --- .../mastodon/reducers/notification_groups.ts | 25 ++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) diff --git a/app/javascript/mastodon/reducers/notification_groups.ts b/app/javascript/mastodon/reducers/notification_groups.ts index b3535d7b67..f3c83ccd8d 100644 --- a/app/javascript/mastodon/reducers/notification_groups.ts +++ b/app/javascript/mastodon/reducers/notification_groups.ts @@ -248,8 +248,9 @@ function processNewNotification( } function trimNotifications(state: NotificationGroupsState) { - if (state.scrolledToTop) { + if (state.scrolledToTop && state.groups.length > NOTIFICATIONS_TRIM_LIMIT) { state.groups.splice(NOTIFICATIONS_TRIM_LIMIT); + ensureTrailingGap(state.groups); } } @@ -400,6 +401,28 @@ function ensureLeadingGap( } } +// Ensure the groups list ends with a gap suitable for loading more, mutating it to append one if needed +function ensureTrailingGap( + groups: NotificationGroupsState['groups'], +): NotificationGap { + const groupOrGap = groups.at(-1); + + if (groupOrGap?.type === 'gap') { + // We're expecting older notifications, so discard sinceId if it's set + groupOrGap.sinceId = undefined; + + return groupOrGap; + } else { + const gap: NotificationGap = { + type: 'gap', + maxId: groupOrGap?.page_min_id, + }; + + groups.push(gap); + return gap; + } +} + export const notificationGroupsReducer = createReducer( initialState, (builder) => { From a5bbe83dfd456c72855f7e2b25eabe28d37ddb40 Mon Sep 17 00:00:00 2001 From: Christian Schmidt Date: Mon, 2 Sep 2024 22:18:09 +0200 Subject: [PATCH 039/153] media_ids is an array of strings (#31709) --- app/services/post_status_service.rb | 2 +- app/services/update_status_service.rb | 2 +- spec/services/post_status_service_spec.rb | 12 ++++++------ spec/services/update_status_service_spec.rb | 4 ++-- 4 files changed, 10 insertions(+), 10 deletions(-) diff --git a/app/services/post_status_service.rb b/app/services/post_status_service.rb index 727f9dc56b..98fd95f025 100644 --- a/app/services/post_status_service.rb +++ b/app/services/post_status_service.rb @@ -134,7 +134,7 @@ class PostStatusService < BaseService @media = @account.media_attachments.where(status_id: nil).where(id: @options[:media_ids].take(Status::MEDIA_ATTACHMENTS_LIMIT).map(&:to_i)) - not_found_ids = @options[:media_ids] - @media.map(&:id) + not_found_ids = @options[:media_ids].map(&:to_i) - @media.map(&:id) raise Mastodon::ValidationError, I18n.t('media_attachments.validations.not_found', ids: not_found_ids.join(', ')) if not_found_ids.any? raise Mastodon::ValidationError, I18n.t('media_attachments.validations.images_and_video') if @media.size > 1 && @media.find(&:audio_or_video?) diff --git a/app/services/update_status_service.rb b/app/services/update_status_service.rb index cd82a0b997..7837d37c95 100644 --- a/app/services/update_status_service.rb +++ b/app/services/update_status_service.rb @@ -73,7 +73,7 @@ class UpdateStatusService < BaseService media_attachments = @status.account.media_attachments.where(status_id: [nil, @status.id]).where(scheduled_status_id: nil).where(id: @options[:media_ids].take(Status::MEDIA_ATTACHMENTS_LIMIT).map(&:to_i)).to_a - not_found_ids = @options[:media_ids] - media_attachments.map(&:id) + not_found_ids = @options[:media_ids].map(&:to_i) - media_attachments.map(&:id) raise Mastodon::ValidationError, I18n.t('media_attachments.validations.not_found', ids: not_found_ids.join(', ')) if not_found_ids.any? raise Mastodon::ValidationError, I18n.t('media_attachments.validations.images_and_video') if media_attachments.size > 1 && media_attachments.find(&:audio_or_video?) diff --git a/spec/services/post_status_service_spec.rb b/spec/services/post_status_service_spec.rb index 5857263f61..7e44789628 100644 --- a/spec/services/post_status_service_spec.rb +++ b/spec/services/post_status_service_spec.rb @@ -34,7 +34,7 @@ RSpec.describe PostStatusService do it 'schedules a status for future creation and does not create one immediately' do media = Fabricate(:media_attachment, account: account) - status = subject.call(account, text: 'Hi future!', media_ids: [media.id], scheduled_at: future) + status = subject.call(account, text: 'Hi future!', media_ids: [media.id.to_s], scheduled_at: future) expect(status) .to be_a(ScheduledStatus) @@ -42,7 +42,7 @@ RSpec.describe PostStatusService do scheduled_at: eq(future), params: include( 'text' => eq('Hi future!'), - 'media_ids' => contain_exactly(media.id) + 'media_ids' => contain_exactly(media.id.to_s) ) ) expect(media.reload.status).to be_nil @@ -219,7 +219,7 @@ RSpec.describe PostStatusService do status = subject.call( account, text: 'test status update', - media_ids: [media.id] + media_ids: [media.id.to_s] ) expect(media.reload.status).to eq status @@ -233,7 +233,7 @@ RSpec.describe PostStatusService do subject.call( account, text: 'test status update', - media_ids: [media.id] + media_ids: [media.id.to_s] ) end.to raise_error( Mastodon::ValidationError, @@ -249,7 +249,7 @@ RSpec.describe PostStatusService do subject.call( account, text: 'test status update', - media_ids: Array.new(2) { Fabricate(:media_attachment, account: account) }.map(&:id) + media_ids: Array.new(2) { Fabricate(:media_attachment, account: account) }.map { |m| m.id.to_s } ) end.to raise_error( Mastodon::ValidationError, @@ -271,7 +271,7 @@ RSpec.describe PostStatusService do media_ids: [ video, image, - ].map(&:id) + ].map { |m| m.id.to_s } ) end.to raise_error( Mastodon::ValidationError, diff --git a/spec/services/update_status_service_spec.rb b/spec/services/update_status_service_spec.rb index 47be53f4fc..de06fb13c6 100644 --- a/spec/services/update_status_service_spec.rb +++ b/spec/services/update_status_service_spec.rb @@ -69,7 +69,7 @@ RSpec.describe UpdateStatusService do before do status.media_attachments << detached_media_attachment - subject.call(status, status.account_id, text: 'Foo', media_ids: [attached_media_attachment.id]) + subject.call(status, status.account_id, text: 'Foo', media_ids: [attached_media_attachment.id.to_s]) end it 'updates media attachments' do @@ -95,7 +95,7 @@ RSpec.describe UpdateStatusService do before do status.media_attachments << media_attachment - subject.call(status, status.account_id, text: 'Foo', media_ids: [media_attachment.id], media_attributes: [{ id: media_attachment.id, description: 'New description' }]) + subject.call(status, status.account_id, text: 'Foo', media_ids: [media_attachment.id.to_s], media_attributes: [{ id: media_attachment.id, description: 'New description' }]) end it 'does not detach media attachment' do From 5f7a3958482762d3907375e3813fb7b44d2b7629 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Tue, 3 Sep 2024 10:00:52 +0200 Subject: [PATCH 040/153] Update dependency rspec-rails to v7 (#31710) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- Gemfile | 2 +- Gemfile.lock | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/Gemfile b/Gemfile index 3fcde202ad..f2851c55c5 100644 --- a/Gemfile +++ b/Gemfile @@ -210,7 +210,7 @@ group :development, :test do gem 'test-prof' # RSpec runner for rails - gem 'rspec-rails', '~> 6.0' + gem 'rspec-rails', '~> 7.0' end group :production do diff --git a/Gemfile.lock b/Gemfile.lock index 11e8aee83b..7813a71edd 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -724,10 +724,10 @@ GEM rspec-mocks (3.13.1) diff-lcs (>= 1.2.0, < 2.0) rspec-support (~> 3.13.0) - rspec-rails (6.1.4) - actionpack (>= 6.1) - activesupport (>= 6.1) - railties (>= 6.1) + rspec-rails (7.0.0) + actionpack (>= 7.0) + activesupport (>= 7.0) + railties (>= 7.0) rspec-core (~> 3.13) rspec-expectations (~> 3.13) rspec-mocks (~> 3.13) @@ -906,7 +906,7 @@ GEM xorcist (1.1.3) xpath (3.2.0) nokogiri (~> 1.8) - zeitwerk (2.6.17) + zeitwerk (2.6.18) PLATFORMS ruby @@ -1024,7 +1024,7 @@ DEPENDENCIES redis-namespace (~> 1.10) rqrcode (~> 2.2) rspec-github (~> 2.4) - rspec-rails (~> 6.0) + rspec-rails (~> 7.0) rspec-sidekiq (~> 5.0) rubocop rubocop-capybara From 754baf00c01e0f682ec5fcdd024e46d6d48d1502 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Tue, 3 Sep 2024 10:01:12 +0200 Subject: [PATCH 041/153] Update dependency inline_svg to v1.10.0 (#31717) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile.lock b/Gemfile.lock index 7813a71edd..b6235402b0 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -347,7 +347,7 @@ GEM rainbow (>= 2.2.2, < 4.0) terminal-table (>= 1.5.1) idn-ruby (0.1.5) - inline_svg (1.9.0) + inline_svg (1.10.0) activesupport (>= 3.0) nokogiri (>= 1.6) io-console (0.7.2) From e5155c50fd1585ac32f7fcc2eb7201e0f67085fd Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Tue, 3 Sep 2024 08:02:08 +0000 Subject: [PATCH 042/153] New Crowdin Translations (automated) (#31716) Co-authored-by: GitHub Actions --- app/javascript/mastodon/locales/fy.json | 89 +++++++++++++++++++++++++ app/javascript/mastodon/locales/ia.json | 1 + config/locales/ca.yml | 1 + config/locales/da.yml | 1 + config/locales/de.yml | 1 + config/locales/doorkeeper.fy.yml | 1 + config/locales/es-AR.yml | 1 + config/locales/fi.yml | 1 + config/locales/fo.yml | 1 + config/locales/fy.yml | 85 +++++++++++++++++++++++ config/locales/gl.yml | 1 + config/locales/ia.yml | 5 ++ config/locales/it.yml | 1 + config/locales/ko.yml | 1 + config/locales/lt.yml | 1 + config/locales/nl.yml | 1 + config/locales/pl.yml | 1 + config/locales/simple_form.fy.yml | 1 + config/locales/sq.yml | 1 + config/locales/uk.yml | 1 + config/locales/vi.yml | 1 + config/locales/zh-TW.yml | 1 + 22 files changed, 198 insertions(+) diff --git a/app/javascript/mastodon/locales/fy.json b/app/javascript/mastodon/locales/fy.json index 0a985a0310..bb409b63c1 100644 --- a/app/javascript/mastodon/locales/fy.json +++ b/app/javascript/mastodon/locales/fy.json @@ -11,6 +11,7 @@ "about.not_available": "Dizze ynformaasje is troch dizze server net iepenbier makke.", "about.powered_by": "Desintralisearre sosjale media, mooglik makke troch {mastodon}", "about.rules": "Serverrigels", + "account.account_note_header": "Persoanlike opmerking", "account.add_or_remove_from_list": "Tafoegje oan of fuortsmite út listen", "account.badges.bot": "Automatisearre", "account.badges.group": "Groep", @@ -96,6 +97,8 @@ "block_modal.title": "Brûker blokkearje?", "block_modal.you_wont_see_mentions": "Jo sjogge gjin berjochten mear dy’t dizze account fermelde.", "boost_modal.combo": "Jo kinne op {combo} drukke om dit de folgjende kear oer te slaan", + "boost_modal.reblog": "Berjocht booste?", + "boost_modal.undo_reblog": "Berjocht net langer booste?", "bundle_column_error.copy_stacktrace": "Flaterrapport kopiearje", "bundle_column_error.error.body": "De opfrege side koe net werjûn wurde. It kin wêze troch in flater yn ús koade, of in probleem mei browserkompatibiliteit.", "bundle_column_error.error.title": "Oh nee!", @@ -169,21 +172,30 @@ "confirmations.block.confirm": "Blokkearje", "confirmations.delete.confirm": "Fuortsmite", "confirmations.delete.message": "Binne jo wis dat jo dit berjocht fuortsmite wolle?", + "confirmations.delete.title": "Berjocht fuortsmite?", "confirmations.delete_list.confirm": "Fuortsmite", "confirmations.delete_list.message": "Binne jo wis dat jo dizze list foar permanint fuortsmite wolle?", + "confirmations.delete_list.title": "List fuortsmite?", "confirmations.discard_edit_media.confirm": "Fuortsmite", "confirmations.discard_edit_media.message": "Jo hawwe net-bewarre wizigingen yn de mediabeskriuwing of foarfertoaning, wolle jo dizze dochs fuortsmite?", "confirmations.edit.confirm": "Bewurkje", "confirmations.edit.message": "Troch no te bewurkjen sil it berjocht dat jo no oan it skriuwen binne oerskreaun wurde. Wolle jo trochgean?", + "confirmations.edit.title": "Berjocht oerskriuwe?", "confirmations.logout.confirm": "Ofmelde", "confirmations.logout.message": "Binne jo wis dat jo ôfmelde wolle?", + "confirmations.logout.title": "Ofmelde?", "confirmations.mute.confirm": "Negearje", "confirmations.redraft.confirm": "Fuortsmite en opnij opstelle", "confirmations.redraft.message": "Binne jo wis dat jo dit berjocht fuortsmite en opnij opstelle wolle? Favoriten en boosts geane dan ferlern en reaksjes op it oarspronklike berjocht reitsje jo kwyt.", + "confirmations.redraft.title": "Berjocht fuortsmite en opnij opstelle?", "confirmations.reply.confirm": "Reagearje", "confirmations.reply.message": "Troch no te reagearjen sil it berjocht dat jo no oan it skriuwen binne oerskreaun wurde. Wolle jo trochgean?", + "confirmations.reply.title": "Berjocht oerskriuwe?", "confirmations.unfollow.confirm": "Net mear folgje", "confirmations.unfollow.message": "Binne jo wis dat jo {name} net mear folgje wolle?", + "confirmations.unfollow.title": "Brûker net mear folgje?", + "content_warning.hide": "Berjocht ferstopje", + "content_warning.show": "Dochs toane", "conversation.delete": "Petear fuortsmite", "conversation.mark_as_read": "As lêzen markearje", "conversation.open": "Petear toane", @@ -220,7 +232,9 @@ "domain_pill.username": "Brûkersnamme", "domain_pill.whats_in_a_handle": "Wat is in fediverse-adres?", "domain_pill.who_they_are": "Omdat jo oan in fediverse-adres sjen kinne hoe’t ien hjit en op hokker server dy sit, kinne jo mei minsken op it troch sosjale web (fediverse) kommunisearje.", + "domain_pill.who_you_are": "Omdat jo oan in fediverse-adres sjen kinne hoe’t jo hjitte en op hokker server jo sitte, kinne jo mei minsken op it troch sosjale web (fediverse) kommunisearje.", "domain_pill.your_handle": "Jo fediverse-adres:", + "domain_pill.your_server": "Jo digitale thús, wer't al jo berjochten stean. Is dizze server dochs net nei jo winsk? Dan kinne jo op elk momint nei in oare server ferhúzje en ek jo folgers oerbringe.", "domain_pill.your_username": "Jo unike identifikaasje-adres op dizze server. It is mooglik dat der brûkers mei deselde brûkersnamme op ferskate servers te finen binne.", "embed.instructions": "Embed this status on your website by copying the code below.", "embed.preview": "Sa komt it der út te sjen:", @@ -258,6 +272,7 @@ "empty_column.list": "There is nothing in this list yet. When members of this list post new statuses, they will appear here.", "empty_column.lists": "Jo hawwe noch gjin inkelde list. Wannear’t jo der ien oanmakke hawwe, falt dat hjir te sjen.", "empty_column.mutes": "Jo hawwe noch gjin brûkers negearre.", + "empty_column.notification_requests": "Hielendal leech! Der is hjir neat. Wannear’t jo nije meldingen ûntfange, ferskine dizze hjir neffens jo ynstellingen.", "empty_column.notifications": "Jo hawwe noch gjin meldingen. Ynteraksjes mei oare minsken sjogge jo hjir.", "empty_column.public": "Der is hjir neat! Skriuw eat publyklik, of folgje sels brûkers fan oare servers om it hjir te foljen", "error.unexpected_crash.explanation": "Troch in bug in ús koade of in probleem mei de komptabiliteit fan jo browser, koe dizze side net toand wurde.", @@ -288,6 +303,8 @@ "filter_modal.select_filter.subtitle": "In besteande kategory brûke of in nije oanmeitsje", "filter_modal.select_filter.title": "Dit berjocht filterje", "filter_modal.title.status": "In berjocht filterje", + "filter_warning.matches_filter": "Komt oerien mei filter ‘{title}’", + "filtered_notifications_banner.pending_requests": "Fan {count, plural, =0 {net ien} one {ien persoan} other {# persoanen}} dy’t jo mooglik kinne", "filtered_notifications_banner.title": "Filtere meldingen", "firehose.all": "Alles", "firehose.local": "Dizze server", @@ -336,6 +353,14 @@ "hashtag.follow": "Hashtag folgje", "hashtag.unfollow": "Hashtag ûntfolgje", "hashtags.and_other": "…en {count, plural, one {}other {# mear}}", + "hints.profiles.followers_may_be_missing": "Folgers foar dit profyl kinne ûntbrekke.", + "hints.profiles.follows_may_be_missing": "De folgers foar dit profyl kinne ûntbrekke.", + "hints.profiles.posts_may_be_missing": "Der ûntbrekke mooglik berjochten fan dit profyl.", + "hints.profiles.see_more_followers": "Besjoch mear folgers op {domain}", + "hints.profiles.see_more_follows": "Besjoch mear folge accounts op {domain}", + "hints.profiles.see_more_posts": "Besjoch mear berjochten op {domain}", + "hints.threads.replies_may_be_missing": "Antwurden fan oare servers kinne ûntbrekke.", + "hints.threads.see_more": "Besjoch mear reaksjes op {domain}", "home.column_settings.show_reblogs": "Boosts toane", "home.column_settings.show_replies": "Reaksjes toane", "home.hide_announcements": "Meidielingen ferstopje", @@ -343,6 +368,17 @@ "home.pending_critical_update.link": "Fernijingen besjen", "home.pending_critical_update.title": "Kritike befeiligingsfernijing beskikber!", "home.show_announcements": "Meidielingen toane", + "ignore_notifications_modal.disclaimer": "Mastodon kin brûkers net ynformearje dat jo harren meldingen negearre hawwe. Meldingen negearje sil net foarkomme dat de berjochten sels ferstjoerd wurde.", + "ignore_notifications_modal.filter_instead": "Yn stee derfan filterje", + "ignore_notifications_modal.filter_to_act_users": "Jo binne noch hieltyd yn steat om folchfersiken goed- of ôf te karren en om brûkers te rapportearjen", + "ignore_notifications_modal.filter_to_avoid_confusion": "Filterjen foarkomt potinsjele betizing", + "ignore_notifications_modal.filter_to_review_separately": "Jo kinne filtere meldingen ôfsûnderlik beoardiele", + "ignore_notifications_modal.ignore": "Meldingen negearje", + "ignore_notifications_modal.limited_accounts_title": "Meldingen fan beheinde accounts negearje?", + "ignore_notifications_modal.new_accounts_title": "Meldingen fan nije accounts negearje?", + "ignore_notifications_modal.not_followers_title": "Meldingen negearje fan minsken dy’t jo net folgje?", + "ignore_notifications_modal.not_following_title": "Meldingen negearje fan minsken dy’t josels net folgje?", + "ignore_notifications_modal.private_mentions_title": "Meldingen negearje fan net frege priveeberjochten?", "interaction_modal.description.favourite": "Jo kinne mei in Mastodon-account dit berjocht as favoryt markearje, om dy brûker witte te litten dat jo it berjocht wurdearje en om it te bewarjen.", "interaction_modal.description.follow": "Jo kinne mei in Mastodon-account {name} folgje, om sa harren berjochten op jo starttiidline te ûntfangen.", "interaction_modal.description.reblog": "Jo kinne mei in Mastodon-account dit berjocht booste, om it sa mei jo folgers te dielen.", @@ -433,6 +469,7 @@ "mute_modal.you_wont_see_mentions": "Jo sjogge gjin berjochten mear dy’t dizze account fermelde.", "mute_modal.you_wont_see_posts": "De persoan kin jo berjochten noch hieltyd sjen, mar jo sjogge harren berjochten net mear.", "navigation_bar.about": "Oer", + "navigation_bar.administration": "Behear", "navigation_bar.advanced_interface": "Yn avansearre webomjouwing iepenje", "navigation_bar.blocks": "Blokkearre brûkers", "navigation_bar.bookmarks": "Blêdwizers", @@ -449,6 +486,7 @@ "navigation_bar.follows_and_followers": "Folgers en folgjenden", "navigation_bar.lists": "Listen", "navigation_bar.logout": "Ofmelde", + "navigation_bar.moderation": "Moderaasje", "navigation_bar.mutes": "Negearre brûkers", "navigation_bar.opened_in_classic_interface": "Berjochten, accounts en oare spesifike siden, wurde standert iepene yn de klassike webinterface.", "navigation_bar.personal": "Persoanlik", @@ -464,9 +502,18 @@ "notification.admin.report_statuses": "{name} rapportearre {target} foar {category}", "notification.admin.report_statuses_other": "{name} hat {target} rapportearre", "notification.admin.sign_up": "{name} hat harren registrearre", + "notification.admin.sign_up.name_and_others": "{name} en {count, plural, one {# oar} other {# oaren}} hawwe harren registrearre", "notification.favourite": "{name} hat jo berjocht as favoryt markearre", + "notification.favourite.name_and_others_with_link": "{name} en {count, plural, one {# oar} other {# oaren}} hawwe jo berjocht as favoryt markearre", "notification.follow": "{name} folget dy", + "notification.follow.name_and_others": "{name} en {count, plural, one {# oar} other {# oaren}} hawwe jo folge", "notification.follow_request": "{name} hat dy in folchfersyk stjoerd", + "notification.follow_request.name_and_others": "{name} en {count, plural, one {# oar} other {# oaren}} hawwe frege om jo te folgjen", + "notification.label.mention": "Fermelding", + "notification.label.private_mention": "Priveeberjocht", + "notification.label.private_reply": "Priveereaksje", + "notification.label.reply": "Beäntwurdzje", + "notification.mention": "Fermelding", "notification.moderation-warning.learn_more": "Mear ynfo", "notification.moderation_warning": "Jo hawwe in moderaasje-warskôging ûntfongen", "notification.moderation_warning.action_delete_statuses": "Guon fan jo berjochten binne fuortsmiten.", @@ -479,23 +526,44 @@ "notification.own_poll": "Jo poll is beëinige", "notification.poll": "In enkête dêr’t jo oan meidien hawwe is beëinige", "notification.reblog": "{name} hat jo berjocht boost", + "notification.reblog.name_and_others_with_link": "{name} en {count, plural, one {# oar} other {# oaren}} hawwe jo berjocht boost", "notification.relationships_severance_event": "Ferlerne ferbiningen mei {name}", "notification.relationships_severance_event.account_suspension": "In behearder fan {from} hat {target} útsteld, wat betsjut dat jo gjin updates mear fan harren ûntfange kinne of mei harren kommunisearje kinne.", "notification.relationships_severance_event.domain_block": "In behearder fan {from} hat {target} blokkearre, ynklusyf {followersCount} fan jo folgers en {followingCount, plural, one {# account} other {# accounts}} dy’t jo folgje.", "notification.relationships_severance_event.learn_more": "Mear ynfo", + "notification.relationships_severance_event.user_domain_block": "Jo hawwe {target} blokkearre, wêrmei’t jo {followersCount} fan jo folgers en {followingCount, plural, one {# account} other {# accounts}} dy’t jo folgje ferlern binne.", "notification.status": "{name} hat in berjocht pleatst", "notification.update": "{name} hat in berjocht bewurke", "notification_requests.accept": "Akseptearje", + "notification_requests.accept_multiple": "{count, plural, one {# fersyk akseptearje…} other {# fersiken akseptearje…}}", + "notification_requests.confirm_accept_multiple.button": "{count, plural, one {Fersyk akseptearje} other {Fersiken akseptearje}}", + "notification_requests.confirm_accept_multiple.message": "Jo steane op it punt om {count, plural, one {ien meldingsfersyk} other {# meldingsfersiken}} te akseptearjen. Binne jo wis dat jo trochgean wolle?", + "notification_requests.confirm_accept_multiple.title": "Meldingsfersiken akseptearje?", + "notification_requests.confirm_dismiss_multiple.button": "{count, plural, one {Fersyk ôfwize} other {Fersiken ôfwize}}", + "notification_requests.confirm_dismiss_multiple.message": "Jo steane op it punt om {count, plural, one {ien meldingsfersyk} other {# meldingsfersiken}} ôf te wizen. Jo sille net yn steat wêze om {count, plural, one {hier} other {hier}} wer maklik tagong ta te krijen. Wolle jo trochgean?", + "notification_requests.confirm_dismiss_multiple.title": "Meldingsfersiken ôfwize?", "notification_requests.dismiss": "Ofwize", + "notification_requests.dismiss_multiple": "{count, plural, one {# fersyk ôfwize…} other {# fersiken ôfwize…}}", + "notification_requests.edit_selection": "Bewurkje", + "notification_requests.exit_selection": "Klear", + "notification_requests.explainer_for_limited_account": "Meldingen fan dizze account binne filtere, omdat dizze account troch in moderator beheind is.", + "notification_requests.explainer_for_limited_remote_account": "Meldingen fan dizze account binne filtere, omdat dizze account of harren server troch in moderator beheind is.", + "notification_requests.maximize": "Maksimalisearje", + "notification_requests.minimize_banner": "Banner mei filtere meldingen minimalisearje", "notification_requests.notifications_from": "Meldingen fan {name}", "notification_requests.title": "Filtere meldingen", + "notification_requests.view": "Meldingen besjen", "notifications.clear": "Meldingen wiskje", "notifications.clear_confirmation": "Binne jo wis dat jo al jo meldingen permanint fuortsmite wolle?", + "notifications.clear_title": "Meldingen fuortsmite?", "notifications.column_settings.admin.report": "Nije rapportaazjes:", "notifications.column_settings.admin.sign_up": "Nije registraasjes:", "notifications.column_settings.alert": "Desktopmeldingen", + "notifications.column_settings.beta.category": "Eksperimintele funksjes", + "notifications.column_settings.beta.grouping": "Notifikaasjes groepearje", "notifications.column_settings.favourite": "Favoriten:", "notifications.column_settings.filter_bar.advanced": "Alle kategoryen toane", + "notifications.column_settings.filter_bar.category": "Flugge filterbalke", "notifications.column_settings.follow": "Nije folgers:", "notifications.column_settings.follow_request": "Nij folchfersyk:", "notifications.column_settings.mention": "Fermeldingen:", @@ -521,6 +589,23 @@ "notifications.permission_denied": "Desktopmeldingen binne net beskikber, omdat in eardere browsertastimming wegere waard", "notifications.permission_denied_alert": "Desktopmeldingen kinne net ynskeakele wurde, omdat in eardere browsertastimming wegere waard", "notifications.permission_required": "Desktopmeldingen binne net beskikber, omdat de nedige tastimming net ferliend is.", + "notifications.policy.accept": "Akseptearje", + "notifications.policy.accept_hint": "Yn meldingen toane", + "notifications.policy.drop": "Negearje", + "notifications.policy.drop_hint": "Permanint fuortsmite", + "notifications.policy.filter": "Filter", + "notifications.policy.filter_hint": "Nei filtere ynboks foar meldingen ferstjoere", + "notifications.policy.filter_limited_accounts_hint": "Beheind troch servermoderatoren", + "notifications.policy.filter_limited_accounts_title": "Moderearre accounts", + "notifications.policy.filter_new_accounts.hint": "Yn de ôfrûne {days, plural, one {dei} other {# dagen}} registrearre", + "notifications.policy.filter_new_accounts_title": "Nije accounts", + "notifications.policy.filter_not_followers_hint": "Ynklusyf minsken dy’t jo koarter as {days, plural, one {dei} other {# dagen}} folgje", + "notifications.policy.filter_not_followers_title": "Minsken dy’t jo net folgje", + "notifications.policy.filter_not_following_hint": "Oant jo se hânmjittich goedkarre", + "notifications.policy.filter_not_following_title": "Minsken dy’t josels net folgje", + "notifications.policy.filter_private_mentions_hint": "Unsichtber útsein it in antwurd is op in priveeberjocht fan jo of wannear’t jo de ôfstjoerder folgje", + "notifications.policy.filter_private_mentions_title": "Net frege priveeberjochten", + "notifications.policy.title": "Meldingen beheare fan…", "notifications_permission_banner.enable": "Desktopmeldingen ynskeakelje", "notifications_permission_banner.how_to_control": "Om meldingen te ûntfangen wannear’t Mastodon net iepen stiet. Jo kinne krekt bepale hokker soarte fan ynteraksjes wol of gjin desktopmeldingen jouwe fia de boppesteande {icon} knop.", "notifications_permission_banner.title": "Mis neat", @@ -647,6 +732,7 @@ "report.unfollow_explanation": "Jo folgje dizze account. Om harren berjochten net mear op jo starttiidline te sjen, kinne jo dyjinge ûntfolgje.", "report_notification.attached_statuses": "{count, plural, one {{count} berjocht} other {{count} berjochten}} tafoege", "report_notification.categories.legal": "Juridysk", + "report_notification.categories.legal_sentence": "yllegale ynhâld", "report_notification.categories.other": "Oars", "report_notification.categories.other_sentence": "oars", "report_notification.categories.spam": "Spam", @@ -680,8 +766,11 @@ "server_banner.about_active_users": "Oantal brûkers yn de ôfrûne 30 dagen (MAU)", "server_banner.active_users": "warbere brûkers", "server_banner.administered_by": "Beheard troch:", + "server_banner.is_one_of_many": "{domain} is ien fan de protte ôfhinklike Mastodon-servers dy’t jo brûke kinne om diel te nimmen oan de fediverse.", "server_banner.server_stats": "Serverstatistiken:", "sign_in_banner.create_account": "Account registrearje", + "sign_in_banner.follow_anyone": "Folgje elkenien yn de fediverse en sjoch it allegearre yn gronologyske folchoarder. Gjin algoritmen, advertinsjes of clickbaits.", + "sign_in_banner.mastodon_is": "Mastodon is de beste manier om wat der bart by te hâlden.", "sign_in_banner.sign_in": "Oanmelde", "sign_in_banner.sso_redirect": "Oanmelde of Registrearje", "status.admin_account": "Moderaasje-omjouwing fan @{name} iepenje", diff --git a/app/javascript/mastodon/locales/ia.json b/app/javascript/mastodon/locales/ia.json index 9bf89ce716..f575c005d8 100644 --- a/app/javascript/mastodon/locales/ia.json +++ b/app/javascript/mastodon/locales/ia.json @@ -98,6 +98,7 @@ "block_modal.you_wont_see_mentions": "Tu non videra le messages que mentiona iste persona.", "boost_modal.combo": "Tu pote premer {combo} pro saltar isto le proxime vice", "boost_modal.reblog": "Impulsar le message?", + "boost_modal.undo_reblog": "Cessar de impulsar le message?", "bundle_column_error.copy_stacktrace": "Copiar reporto de error", "bundle_column_error.error.body": "Le pagina requestate non pote esser visualisate. Pote esser a causa de un defecto in nostre codice o de un problema de compatibilitate del navigator.", "bundle_column_error.error.title": "Oh, no!", diff --git a/config/locales/ca.yml b/config/locales/ca.yml index d8de84c283..9a8f32117e 100644 --- a/config/locales/ca.yml +++ b/config/locales/ca.yml @@ -1412,6 +1412,7 @@ ca: media_attachments: validations: images_and_video: No es pot adjuntar un vídeo a una publicació que ja contingui imatges + not_found: No s'ha trobat el contingut multimèdia %{ids} o ja s'ha adjuntat a una altra publicació not_ready: No es poden adjuntar fitxers que no s'hagin acabat de processar. Torna-ho a provar en un moment! too_many: No es poden adjuntar més de 4 fitxers migrations: diff --git a/config/locales/da.yml b/config/locales/da.yml index 94f2369f8e..1366370eb0 100644 --- a/config/locales/da.yml +++ b/config/locales/da.yml @@ -1454,6 +1454,7 @@ da: media_attachments: validations: images_and_video: En video kan ikke vedhæftes et indlæg med billedindhold + not_found: Mediet %{ids} ikke fundet eller allerede vedhæftet andet indlæg not_ready: Filer under behandling kan ikke vedhæftes. Forsøg igen senere! too_many: Maks. 4 filer kan vedhæftes migrations: diff --git a/config/locales/de.yml b/config/locales/de.yml index a852c736cf..e5e3f37a36 100644 --- a/config/locales/de.yml +++ b/config/locales/de.yml @@ -1454,6 +1454,7 @@ de: media_attachments: validations: images_and_video: Es kann kein Video an einen Beitrag angehängt werden, der bereits Bilder enthält + not_found: Medien %{ids} nicht verfügbar oder bereits an einen anderen Beitrag angehängt not_ready: Dateien, die noch nicht verarbeitet wurden, können nicht angehängt werden. Versuche es gleich noch einmal! too_many: Mehr als vier Dateien können nicht angehängt werden migrations: diff --git a/config/locales/doorkeeper.fy.yml b/config/locales/doorkeeper.fy.yml index 1cf2d32212..f15389faf9 100644 --- a/config/locales/doorkeeper.fy.yml +++ b/config/locales/doorkeeper.fy.yml @@ -83,6 +83,7 @@ fy: access_denied: De boarne-eigener of autorisaasjeserver hat it fersyk wegere. credential_flow_not_configured: De wachtwurdgegevens-flow fan de boarne-eigener is mislearre, omdat Doorkeeper.configure.resource_owner_from_credentials net ynsteld is. invalid_client: Clientferifikaasje is mislearre troch in ûnbekende client, ûntbrekkende client-autentikaasje of in net stipe autentikaasjemetoade. + invalid_code_challenge_method: De koadechallengemetoade moat S256 wezen, plain wurdt net stipe. invalid_grant: De opjûne autorisaasje is ûnjildich, ferrûn, ynlutsen, komt net oerien mei de redirect-URI dy’t opjûn is of útjûn waard oan in oere client. invalid_redirect_uri: De opjûne redirect-URI is ûnjildich. invalid_request: diff --git a/config/locales/es-AR.yml b/config/locales/es-AR.yml index b0882e0a27..ab0dcb58fa 100644 --- a/config/locales/es-AR.yml +++ b/config/locales/es-AR.yml @@ -1454,6 +1454,7 @@ es-AR: media_attachments: validations: images_and_video: No se puede adjuntar un video a un mensaje que ya contenga imágenes + not_found: Medios %{ids} no encontrados o ya adjuntados a otro mensaje not_ready: No se pueden adjuntar archivos que no se han terminado de procesar. ¡Intentá de nuevo en un rato! too_many: No se pueden adjuntar más de 4 archivos migrations: diff --git a/config/locales/fi.yml b/config/locales/fi.yml index 95190d8846..42d1977662 100644 --- a/config/locales/fi.yml +++ b/config/locales/fi.yml @@ -1454,6 +1454,7 @@ fi: media_attachments: validations: images_and_video: Videota ei voi liittää tilapäivitykseen, jossa on jo kuvia + not_found: Mediaa %{ids} ei löytynyt, tai se on jo liitetty toiseen julkaisuun not_ready: Ei voi liittää tiedostoja, joiden käsittely on kesken. Yritä hetken kuluttua uudelleen! too_many: Tiedostoja voi liittää enintään 4 migrations: diff --git a/config/locales/fo.yml b/config/locales/fo.yml index b2309694b1..0c3620ad42 100644 --- a/config/locales/fo.yml +++ b/config/locales/fo.yml @@ -1454,6 +1454,7 @@ fo: media_attachments: validations: images_and_video: Kann ikki viðfesta sjónfílu til ein post, sum longu inniheldur myndir + not_found: Miðilin %{ids} ikki funnin ella longu knýttur at øðrum posti not_ready: Kann ikki viðfesta fílur, sum ikki eru liðugt viðgjørdar. Roynd aftur um eina løtu! too_many: Kann ikki viðfest fleiri enn 4 fílur migrations: diff --git a/config/locales/fy.yml b/config/locales/fy.yml index 62889c0b28..d0127f77b1 100644 --- a/config/locales/fy.yml +++ b/config/locales/fy.yml @@ -31,6 +31,7 @@ fy: created_msg: Oanmeitsjen fan opmerking foar moderatoaren slagge! destroyed_msg: Fuortsmiten fan opmerking foar moderatoaren slagge! accounts: + add_email_domain_block: E-maildomein blokkearje approve: Goedkarre approved_msg: It goedkarren fan de account fan %{username} is slagge are_you_sure: Binne jo wis? @@ -57,6 +58,7 @@ fy: demote: Degradearje destroyed_msg: It fuortsmiten fan de gegevens fan %{username} stiet no yn de wachtrige disable: Befrieze + disable_sign_in_token_auth: Ferifikaasje mei in tagongskoade fia e-mail útskeakelje disable_two_factor_authentication: 2FA útskeakelje disabled: Beferzen display_name: Werjeftenamme @@ -65,6 +67,7 @@ fy: email: E-mailadres email_status: E-mailsteat enable: Untteie + enable_sign_in_token_auth: Ferifikaasje mei in tagongskoade fia e-mail ynskeakelje enabled: Ynskeakele enabled_msg: It ûntteie fan de account fan %{username} is slagge followers: Folgers @@ -129,6 +132,7 @@ fy: resubscribe: Opnij abonnearje role: Rol search: Sykje + search_same_email_domain: Oare brûkers mei itselde e-maildomein search_same_ip: Oare brûkers mei itselde IP-adres security: Befeiliging security_measures: @@ -169,21 +173,26 @@ fy: approve_appeal: Beswier goedkarre approve_user: Brûker goedkarre assigned_to_self_report: Rapportaazje tawize + change_email_user: E-mailadres fan brûker wizigje change_role_user: Brûkersrol wizigje confirm_user: Brûker befêstigje create_account_warning: Warskôging oanmeitsje create_announcement: Meidieling oanmeitsje + create_canonical_email_block: E-mailblokkade oanmeitsje create_custom_emoji: Lokale emoji oanmeitsje create_domain_allow: Domeingoedkarring oanmeitsje create_domain_block: Domeinblokkade oanmeitsje + create_email_domain_block: E-maildomeinblokkade oanmeitsje create_ip_block: IP-rigel oanmeitsje create_unavailable_domain: Net beskikber domein oanmeitsje create_user_role: Rol oanmeitsje demote_user: Brûker degradearje destroy_announcement: Meidieling fuortsmite + destroy_canonical_email_block: E-mailblokkade fuortsmite destroy_custom_emoji: Lokale emoji fuortsmite destroy_domain_allow: Domeingoedkarring fuortsmite destroy_domain_block: Domeinblokkade fuortsmite + destroy_email_domain_block: E-maildomeinblokkade fuortsmite destroy_instance: Domein folslein fuortsmite destroy_ip_block: IP-rigel fuortsmite destroy_status: Toot fuortsmite @@ -191,8 +200,10 @@ fy: destroy_user_role: Rol permanint fuortsmite disable_2fa_user: Twa-stapsferifikaasje útskeakelje disable_custom_emoji: Lokale emoji útskeakelje + disable_sign_in_token_auth_user: Ferifikaasje mei in tagongskoade fia e-mail foar de brûker útskeakelje disable_user: Brûker útskeakelje enable_custom_emoji: Lokale emoji ynskeakelje + enable_sign_in_token_auth_user: Ferifikaasje mei in tagongskoade fia e-mail foar de brûker ynskeakelje enable_user: Brûker ynskeakelje memorialize_account: De account yn in Yn memoriam wizigje promote_user: Brûker promovearje @@ -222,20 +233,26 @@ fy: approve_appeal_html: "%{name} hat it beswier tsjin de moderaasjemaatregel fan %{target} goedkard" approve_user_html: "%{name} hat de registraasje fan %{target} goedkard" assigned_to_self_report_html: "%{name} hat rapportaazje %{target} oan harrensels tawiisd" + change_email_user_html: "%{name} hat it e-mailadres fan brûker %{target} wizige" change_role_user_html: "%{name} hat de rol fan %{target} wizige" + confirm_user_html: E-mailadres fan brûker %{target} is troch %{name} befêstige create_account_warning_html: "%{name} hat in warskôging nei %{target} ferstjoerd" create_announcement_html: "%{name} hat de nije meidieling %{target} oanmakke" + create_canonical_email_block_html: "%{name} hat it e-mailberjocht mei de hash %{target} blokkearre" create_custom_emoji_html: Nije emoji %{target} is troch %{name} opladen create_domain_allow_html: "%{name} hat de federaasje mei it domein %{target} goedkard" create_domain_block_html: Domein %{target} is troch %{name} blokkearre + create_email_domain_block_html: "%{name} hat it e-maildomein %{target} blokkearre" create_ip_block_html: "%{name} hat de rigel foar IP %{target} oanmakke" create_unavailable_domain_html: "%{name} hat de besoarging foar domein %{target} beëinige" create_user_role_html: "%{name} hat de rol %{target} oanmakke" demote_user_html: Brûker %{target} is troch %{name} degradearre destroy_announcement_html: "%{name} hat de meidieling %{target} fuortsmiten" + destroy_canonical_email_block_html: "%{name} hat it e-mailberjocht mei de hash %{target} deblokkearre" destroy_custom_emoji_html: Emoji %{target} is troch %{name} fuortsmiten destroy_domain_allow_html: "%{name} hat de federaasje mei it domein %{target} ôfkard" destroy_domain_block_html: Domein %{target} is troch %{name} deblokkearre + destroy_email_domain_block_html: "%{name} hat it e-maildomein %{target} deblokkearre" destroy_instance_html: "%{name} hat it domein %{target} folslein fuortsmiten" destroy_ip_block_html: "%{name} hat de rigel foar IP %{target} fuortsmiten" destroy_status_html: Berjocht fan %{target} is troch %{name} fuortsmiten @@ -243,8 +260,10 @@ fy: destroy_user_role_html: "%{name} hat de rol %{target} fuortsmiten" disable_2fa_user_html: De fereaske twa-stapsferifikaasje foar %{target} is troch %{name} útskeakele disable_custom_emoji_html: Emoji %{target} is troch %{name} útskeakele + disable_sign_in_token_auth_user_html: "%{name} hat ferifikaasje mei in tagongskoade fia e-mail útskeakele foar %{target}" disable_user_html: Oanmelden foar %{target} is troch %{name} útskeakele enable_custom_emoji_html: Emoji %{target} is troch %{name} ynskeakele + enable_sign_in_token_auth_user_html: "%{name} hat ferifikaasje mei in tagongskoade fia e-mail ynskeakele foar %{target}" enable_user_html: Oanmelden foar %{target} is troch %{name} ynskeakele memorialize_account_html: De account %{target} is troch %{name} yn in Yn memoriam wizige promote_user_html: Brûker %{target} is troch %{name} promovearre @@ -252,6 +271,7 @@ fy: reject_user_html: "%{name} hat de registraasje fan %{target} ôfwêzen" remove_avatar_user_html: "%{name} hat de profylfoto fan %{target} fuortsmiten" reopen_report_html: "%{name} hat rapportaazje %{target} opnij iepene" + resend_user_html: "%{name} hat it befêstigings-e-mailberjocht foar %{target} opnij ferstjoerd" reset_password_user_html: Wachtwurd fan brûker %{target} is troch %{name} opnij ynsteld resolve_report_html: "%{name} hat rapportaazje %{target} oplost" sensitive_account_html: "%{name} markearre de media fan %{target} as gefoelich" @@ -412,6 +432,7 @@ fy: attempts_over_week: one: "%{count} registraasjebesykjen yn de ôfrûne wike" other: "%{count} registraasjebesykjen yn de ôfrûne wike" + created_msg: E-maildomein blokkearjen slagge delete: Fuortsmite dns: types: @@ -420,8 +441,12 @@ fy: new: create: Domein tafoegje resolve: Domein opsykje + title: Nije e-maildomein blokkearje + no_email_domain_block_selected: Der binne gjin e-maildomeinblokkaden wizige, omdat der gjin ien selektearre waard not_permitted: Net tastien + resolved_dns_records_hint_html: De domeinnamme slacht op de folgjende MX-domeinen dy’t úteinlik ferantwurdlik binne foar it akseptearjen fan e-mail. It blokkearjen fan in MX-domein blokkearret oanmeldingen fan elk e-mailadres dat itselde MX-domein brûkt, sels as de sichtbere domeinnamme oars is. Pas op dat jo gjin grutte e-mailproviders blokkearje. resolved_through_html: Blokkearre fia %{domain} + title: Blokkearre e-maildomeinen export_domain_allows: new: title: Tastiene domeinen ymportearje @@ -575,6 +600,7 @@ fy: resolve_description_html: Der wurdt tsjin it rapportearre account gjin maatregel nommen, gjin oertrêding registrearre en de rapportaazje wurdt markearre as oplost. silence_description_html: De account sil allinnich sichtber wêze foar dyjinge dy’t it al folgje of it hânmjittich opsykje, wêrtroch it berik earnstich beheind wurdt. Kin altyd weromdraaid wurde. Dit slút alle rapportaazjes oer dizze account. suspend_description_html: De account en alle ynhâld sil net tagonklik wêze en úteinlik fuortsmiten wurde, en ynteraksje hjirmei sil net mooglik wêze. Binnen 30 dagen werom te draaien. Dit slút alle rapportaazjes oer dizze account. + actions_description_html: Beslis hokker maatregel nommen wurde moat om dizze rapportaazje op te lossen. Wannear’t jo in (straf)maatregel tsjin it rapportearre account nimme, kriget de account in e-mailmelding, behalve wannear’t de spam-kategory keazen is. actions_description_remote_html: Beslút hokker aksje nommen wurde moat om dizze rapportaazje ôf te hanneljen. Dit hat allinnich ynfloed op hoe’t jo server kommunisearret mei dizze eksterne account en omgiet mei de ynhâld. add_to_report: Mear oan de rapportaazje tafoegje already_suspended_badges: @@ -639,6 +665,7 @@ fy: delete_data_html: It profyl en de ynhâld fan @%{acct} wurde nei 30 dagen fan no ôf fuortsmiten, útsein as de account yn de tuskentiid net mear blokkearre wurdt preview_preamble_html: "@%{acct} sil in warskôging ûntfange mei de folgjende ynhâld:" record_strike_html: In ban tsjin @%{acct} ynstelle, om jo te helpen by takomstige skeiningen fan dizze acount te eskalearjen + send_email_html: Stjoer @%{acct} in warskôgings-e-mailberjocht warning_placeholder: Ekstra opsjonele reden foar de moderaasje-aksje. target_origin: Orizjineel fan rapportearre account title: Rapportaazjes @@ -678,6 +705,7 @@ fy: manage_appeals: Beswieren beheare manage_appeals_description: Stiet brûkers ta om beswieren tsjin moderaasjemaatregelen te beoardielen manage_blocks: Blokkaden beheare + manage_blocks_description: Stiet brûkers ta om e-mailproviders en IP-adressen te blokkearjen manage_custom_emojis: Lokale emoji’s beheare manage_custom_emojis_description: Stiet brûkers ta om lokale emoji’s op de server te behearen manage_federation: Federaasje beheare @@ -695,6 +723,7 @@ fy: manage_taxonomies: Trends en hashtags beheare manage_taxonomies_description: Stiet brûkers ta om trending ynhâld te besjen en om hashtagynstellingen by te wurkjen manage_user_access: Brûkerstagong beheare + manage_user_access_description: Stiet brûkers ta om twa-stapsferifikaasje fan oare brûkers út te skeakeljen, om harren e-mailadres te wizigjen en om harren wachtwurd opnij yn te stellen manage_users: Brûkers beheare manage_users_description: Stiet brûkers ta om brûkersdetails fan oaren te besjen en moderaasjemaatregelen tsjin harren te nimmen manage_webhooks: Webhooks beheare @@ -769,6 +798,7 @@ fy: destroyed_msg: Fuortsmiten website-oplaad slagge! software_updates: critical_update: Krityk — fernij sa gau as mooglik + description: It wurdt oanrekommandearre om jo Mastodon-ynstallaasje by-de-tiid te hâlden om gebrûk meitsje te kinnen fan de nijste oplossingen en funksjes. Boppe dat is it somtiden krúsjaal om Mastodon tidich by te wurkjen om feiligheidsproblemen foar te kommen. Om dizze redenen kontrolearret Mastodon elke 30 minuten fernijingen en bringt jo hjirfan op de hichte neffens jo foarkarren foar e-mailmeldingen. documentation_link: Mear ynfo release_notes: Utjefte-opmerkingen title: Beskikbere fernijingen @@ -855,16 +885,39 @@ fy: action: Klik hjir foar mear ynformaasje message_html: "Jo objektûnthâld is ferkeard konfigurearre. De privacy fan jo brûkers is yn gefaar." tags: + moderation: + not_trendable: Net trendber + not_usable: Net brûkber + pending_review: Moat noch beoardiele wurde + review_requested: Beoardieling oanfrege + reviewed: Beoardiele + title: Status + trendable: Trendber + unreviewed: Net beoardiele + usable: Brûkber + name: Namme + newest: Nijste + oldest: Aldste + open: Yn it iepenbier besjen + reset: Opnij ynstelle review: Steat beoardiele + search: Sykje + title: Hashtags updated_msg: Hashtagynstellingen mei sukses bywurke title: Behear trends: allow: Tastean approved: Goedkarre + confirm_allow: Binne jo wis dat jo de selektearre hashtags tastean wolle? + confirm_disallow: Binne jo wis dat jo de selektearre hashtags ôfkarre wolle? disallow: Ofkarre links: allow: Keppeling goedkarre allow_provider: Auteur goedkarre + confirm_allow: Binne jo wis dat jo de selektearre keppelingen tastean wolle? + confirm_allow_provider: Binne jo wis dat jo de selektearre websites tastean wolle? + confirm_disallow: Binne jo wis dat jo de selektearre keppelingen ôfkarre wolle? + confirm_disallow_provider: Binne jo wis dat jo de selektearre providers ôfkarre wolle? description_html: Dit binne keppelingen dy’t op dit stuit in protte dield wurde troch accounts wêr’t jo server berjochten fan ûntfangt. Hjirtroch kinne jo brûkers sjen wat der yn de wrâld oan de hân is. Der wurde gjin keppelingen werjûn oant jo de website goedkard hawwe. Jo kinne ek yndividuele keppelingen goed- of ôfkarre. disallow: Keppeling ôfkarre disallow_provider: Website ôfkarre @@ -888,6 +941,10 @@ fy: statuses: allow: Berjocht goedkarre allow_account: Account goedkarre + confirm_allow: Binne jo wis dat jo de selektearre statussen ofkarre wolle? + confirm_allow_account: Binne jo wis dat jo de selektearre accounts tastean wolle? + confirm_disallow: Binne jo wis dat jo de selektearre statussen ôfkarre wolle? + confirm_disallow_account: Binne jo wis dat jo de selektearre accounts ôfkarre wolle? description_html: Dit binne berjochten dy’t op jo server bekend binne en dy’t op dit stuit in protte dield wurde en as favoryt markearre wurde. Hjirmei kinne nije en weromkearende brûkers mear minsken fine om te folgjen. Der wurde gjin berjochten yn it iepenbier werjûn oant de account troch jo goedkard is en de brûker tastiet dat harren account oan oaren oanrekommandearre wurdt. Jo kinne ek yndividuele berjochten goed- of ôfkarre. disallow: Berjocht ôfkarre disallow_account: Account ôfkarre @@ -920,6 +977,7 @@ fy: used_by_over_week: one: Dizze wike troch ien persoan brûkt other: Dizze wike troch %{count} persoanen brûkt + title: Oanrekommandaasjes & trends trending: Trending warning_presets: add_new: Nije tafoegje @@ -1004,7 +1062,9 @@ fy: guide_link_text: Elkenien kin bydrage. sensitive_content: Gefoelige ynhâld application_mailer: + notification_preferences: E-mailynstellingen wizigje salutation: "%{name}," + settings: 'E-mailfoarkarren wizigje: %{link}' unsubscribe: Ofmelde view: 'Besjoch:' view_profile: Profyl besjen @@ -1024,6 +1084,7 @@ fy: hint_html: Noch ien ding! Jo moatte befêstigje dat jo in minske binne (dit is om de spam bûten de doar te hâlden!). Los de ûndersteande CAPTCHA op en klik op ‘Trochgean’. title: Befeiligingskontrôle confirmations: + awaiting_review: Jo e-mailadres is befêstige! De %{domain}-meiwurkers binne no dwaande mei it besjen fan jo registraasje. Jo ûntfange in e-mailberjocht as de jo account goedkarre! awaiting_review_title: Jo registraasje wurdt beoardield clicking_this_link: klik op dizze keppeling login_link: oanmelde @@ -1031,6 +1092,7 @@ fy: redirect_to_app_html: Jo soene omlaad wêze moatte nei de %{app_name} app. As dat net bard is, probearje dan %{clicking_this_link} of kear hânmjittich werom nei de app. registration_complete: Jo registraasje op %{domain} is no foltôge! welcome_title: Wolkom, %{name}! + wrong_email_hint: As it e-mailadres net korrekt is, kinne jo dat wizigje yn de accountynstellingen. delete_account: Account fuortsmite delete_account_html: Wannear’t jo jo account graach fuortsmite wolle, kinne jo dat hjir dwaan. Wy freegje jo dêr om in befêstiging. description: @@ -1051,6 +1113,7 @@ fy: or_log_in_with: Of oanmelde mei privacy_policy_agreement_html: Ik haw it privacybelied lêzen en gean dêrmei akkoard progress: + confirm: E-mailadres werhelje details: Jo gegevens review: Us beoardieling rules: Regels akseptearje @@ -1072,8 +1135,10 @@ fy: security: Befeiliging set_new_password: Nij wachtwurd ynstelle setup: + email_below_hint_html: Kontrolearje jo map Net-winske, of freegje in nije befêstigingskeppeling oan. Jo kinne jo e-mailadres wizigje as it ferkeard is. email_settings_hint_html: Klik op de keppeling dy’t wy jo stjoerd hawwe om %{email} te ferifiearjen. Wy wachtsje wol even. link_not_received: Gjin keppeling krigen? + new_confirmation_instructions_sent: Jo ûntfange binnen inkelde minuten in nij e-mailberjocht mei de befêstigingskeppeling! title: Kontrolearje jo Postfek YN sign_in: preamble_html: Meld jo oan mei de oanmeldgegevens fan %{domain}. As jo account op in oare server stiet, kinne jo hjir net oanmelde. @@ -1084,7 +1149,9 @@ fy: title: Litte wy jo account op %{domain} ynstelle. status: account_status: Accountsteat + confirming: Oan it wachtsjen oant it e-mailadres befêstige is. functional: Jo account kin folslein brûkt wurde. + pending: Jo oanfraach moat noch beoardiele wurde troch ien fan ús meiwurkers. Dit kin miskien efkes duorje. Jo ûntfangt in e-mailberjocht wannear’t jo oanfraach goedkard is. redirecting_to: Jo account is ynaktyf, omdat it op dit stuit trochferwezen wurdt nei %{acct}. self_destruct: Omdat %{domain} sluten sil, krije jo mar beheind tagong ta jo account. view_strikes: Besjoch de earder troch moderatoaren fêststelde skeiningen dy’t jo makke hawwe @@ -1127,6 +1194,9 @@ fy: before: 'Lês dizze tekst soarchfâldich eardat jo troch gean:' caches: Berjochten en media dy’t op oare servers bewarre binne kinne dêr efterbliuwe data_removal: Jo berjochten en oare gegevens wurde permanint fuortmiten + email_change_html: Jo kinne jo e-mailadres wizigje sûnder dat jo jo account fuort hoege te smiten + email_contact_html: Wannear’t it noch hieltyd net oankomt, kinne jo foar help in e-mailberjocht stjoere nei %{email} + email_reconfirmation_html: Wannear’t jo it befêstigings-e-mailberjocht net ûntfongen hawwe, kinne jo dizze opnij oanfreegje irreversible: Jo sille net yn steat wêze om jo account te werstellen of te de-aktivearjen more_details_html: Sjoch it privacybelied foar mear ynformaasje. username_available: Jo brûkersnamme sil wer beskikber komme @@ -1359,6 +1429,7 @@ fy: authentication_methods: otp: twa-stapsferifikaasje-app password: wachtwurd + sign_in_token: befeiligingskoade fia e-mailberjocht webauthn: befeiligingskaaien description_html: Wannear’t jo aktiviteit sjogge dy’t jo net werkenne, tink dan nei om jo wachtwurd te wizigjen en twa-stapsferifikaasje yn te skeakeljen. empty: Gjin oanmeldskiednis beskikber @@ -1369,6 +1440,16 @@ fy: unsubscribe: action: Ja, ôfmelde complete: Ofmelden + confirmation_html: Binne jo wis dat jo jo ôfmelde wolle foar it ûntfangen fan %{type} fan Mastodon op %{domain} op jo e-mailadres %{email}? Jo kinne jo altyd opnij abonnearje yn jo ynstellingen foar e-mailmeldingen. + emails: + notification_emails: + favourite: e-mailmeldingen foar favoriten + follow: e-mailmeldingen foar nije folgers + follow_request: e-mailmeldingen foar folchfersiken + mention: e-mailmeldingen foar fermeldingen + reblog: e-mailmeldingen foar boosts + resubscribe_html: As jo jo mei fersin ôfmeld hawwe, kinne jo jo opnij abonnearje yn jo ynstellingen foar e-mailmeldingen. + success_html: Jo ûntfange net langer %{type} fan Mastodon op %{domain} op jo e-mailadres %{email}. title: Ofmelde media_attachments: validations: @@ -1449,6 +1530,8 @@ fy: update: subject: "%{name} hat in berjocht bewurke" notifications: + administration_emails: E-mailmeldingen behearder + email_events: E-mailmeldingen foar eveneminten email_events_hint: 'Selektearje eveneminten wêrfoar’t jo meldingen ûntfange wolle:' number: human: @@ -1607,6 +1690,7 @@ fy: import: Ymportearje import_and_export: Ymportearje en eksportearje migrate: Accountmigraasje + notifications: E-mailmeldingen preferences: Ynstellingen profile: Profyl relationships: Folgers en folgjenden @@ -1853,6 +1937,7 @@ fy: invalid_otp_token: Unjildige twa-stapstagongskoade otp_lost_help_html: As jo tagong ta beide kwytrekke binne, nim dan kontakt op fia %{email} rate_limited: Te folle autentikaasjebesykjen, probearje it letter opnij. + seamless_external_login: Jo binne oanmeld fia in eksterne tsjinst, dêrom binne wachtwurden en e-mailynstellingen net beskikber. signed_in_as: 'Oanmeld as:' verification: extra_instructions_html: Tip: De keppeling op jo website kin ûnsichtber wêze. It wichtige part is rel="me" dat ympersonaasje op websites mei user-generated ynhâld foarkomt. Jo kinne sels in link-label brûke yn de header fan de side yn stee fan a, mar de HTML moat ek sûnder JavaScript tagonklik wêze. diff --git a/config/locales/gl.yml b/config/locales/gl.yml index 71df4c8d93..b43ec5d172 100644 --- a/config/locales/gl.yml +++ b/config/locales/gl.yml @@ -1454,6 +1454,7 @@ gl: media_attachments: validations: images_and_video: Non podes anexar un vídeo a unha publicación que xa contén imaxes + not_found: Non se atopou o multimedia %{ids} ou xa é adxunto noutra publicación not_ready: Non se poden anexar ficheiros que aínda se están a procesar. Agarda un intre! too_many: Non pode anexar máis de 4 ficheiros migrations: diff --git a/config/locales/ia.yml b/config/locales/ia.yml index c282a17f92..5596aacf2d 100644 --- a/config/locales/ia.yml +++ b/config/locales/ia.yml @@ -661,6 +661,7 @@ ia: delete_data_html: Deler le profilo e contento de @%{acct} in 30 dies excepte si le suspension es disfacite intertanto preview_preamble_html: "@%{acct} recipera un advertimento con le sequente contento:" record_strike_html: Registra un sanction contra @%{acct} pro adjutar te a prender mesuras adequate in caso de futur violationes committite desde iste conto + send_email_html: Inviar un e-mail de advertimento a @%{acct} warning_placeholder: Motivation supplementari facultative pro le action de moderation. target_origin: Origine del conto reportate title: Reportos @@ -700,6 +701,7 @@ ia: manage_appeals: Gerer appellos manage_appeals_description: Permitte que usatores revide appellos contra actiones de moderation manage_blocks: Gerer blocadas + manage_blocks_description: Permitter que usatores bloca le fornitores de e-mail e le adresses IP manage_custom_emojis: Gerer emojis personalisate manage_custom_emojis_description: Permitte que usatores gere emojis personalisate sur le servitor manage_federation: Gerer federation @@ -717,6 +719,7 @@ ia: manage_taxonomies: Gerer taxonomias manage_taxonomies_description: Permitte que usatores revide contento in tendentias e actualisa le parametros de hashtag manage_user_access: Gerer le accesso de usatores + manage_user_access_description: Permitte que usatores disactiva le authentication bifactorial de altere usatores, cambia lor adresses de e-mail, e reinitialisa lor contrasigno manage_users: Gerer usatores manage_users_description: Permitte que usatores vide le detalios de altere usatores e exeque actiones de moderation contra illes manage_webhooks: Gerer Webhooks @@ -791,6 +794,7 @@ ia: destroyed_msg: Le file incargate al sito ha essite delite! software_updates: critical_update: Critic – per favor, actualisa rapidemente + description: Il es recommendate mantener tu installation de Mastodon actualisate pro beneficiar del ultime reparationes e functiones. In ultra, de tempore a tempore, il es de importantia critic actualisar Mastodon in tempore utile pro evitar problemas de securitate. Pro iste rationes, Mastodon verifica le presentia de actualisationes cata 30 minutas, e te notificara secundo tu preferentias de notification in e-mail. documentation_link: Pro saper plus release_notes: Notas de version title: Actualisationes disponibile @@ -878,6 +882,7 @@ ia: message_html: "Tu immagazinage de objectos es mal configurate. Le confidentialitate de tu usatores es in risco." tags: moderation: + not_trendable: Non pro tendentia pending_review: Attende revision title: Stato name: Nomine diff --git a/config/locales/it.yml b/config/locales/it.yml index bc60b6ea50..54e122fd75 100644 --- a/config/locales/it.yml +++ b/config/locales/it.yml @@ -1456,6 +1456,7 @@ it: media_attachments: validations: images_and_video: Impossibile allegare video a un post che contiene già immagini + not_found: Media %{ids} non trovato o già collegato a un altro post not_ready: Impossibile allegare file per cui l'elaborazione non è finita. Riprova tra poco! too_many: Impossibile allegare più di 4 file migrations: diff --git a/config/locales/ko.yml b/config/locales/ko.yml index e919e183d4..9632a3027b 100644 --- a/config/locales/ko.yml +++ b/config/locales/ko.yml @@ -1430,6 +1430,7 @@ ko: media_attachments: validations: images_and_video: 이미 사진이 첨부된 게시물엔 동영상을 첨부할 수 없습니다. + not_found: 미디어 %{ids}는 찾을 수 없거나 이미 다른 게시물에 첨부되었습니다 not_ready: 처리가 끝나지 않은 파일은 첨부할 수 없습니다. 잠시 후에 다시 시도해 주세요! too_many: 최대 4개까지 첨부할 수 있습니다 migrations: diff --git a/config/locales/lt.yml b/config/locales/lt.yml index 6cc35d939d..8c3b8e2e73 100644 --- a/config/locales/lt.yml +++ b/config/locales/lt.yml @@ -941,6 +941,7 @@ lt: media_attachments: validations: images_and_video: Negalima pridėti video prie statuso, kuris jau turi nuotrauką + not_found: Medija %{ids} nerasta arba jau pridėta prie kito įrašo. too_many: Negalima pridėti daugiau nei 4 failų migrations: acct: Perkelta į diff --git a/config/locales/nl.yml b/config/locales/nl.yml index cdd71112e9..46ed411776 100644 --- a/config/locales/nl.yml +++ b/config/locales/nl.yml @@ -1454,6 +1454,7 @@ nl: media_attachments: validations: images_and_video: Een video kan niet aan een bericht met afbeeldingen worden gekoppeld + not_found: Media %{ids} niet gevonden of al toegevoegd aan een ander bericht not_ready: Kan geen bestanden toevoegen die nog niet zijn verwerkt. Probeer het later opnieuw! too_many: Er kunnen niet meer dan 4 afbeeldingen toegevoegd worden migrations: diff --git a/config/locales/pl.yml b/config/locales/pl.yml index d79df666e5..95746bd10b 100644 --- a/config/locales/pl.yml +++ b/config/locales/pl.yml @@ -1506,6 +1506,7 @@ pl: media_attachments: validations: images_and_video: Nie możesz załączyć pliku wideo do wpisu, który zawiera już zdjęcia + not_found: Nie znaleziono mediów %{ids}, lub są już dołączone do innego wpisu not_ready: Nie można załączyć plików których przetwarzanie nie zostało ukończone. Spróbuj ponownie za chwilę! too_many: Nie możesz załączyć więcej niż 4 plików migrations: diff --git a/config/locales/simple_form.fy.yml b/config/locales/simple_form.fy.yml index bde97237f6..e6c1b0ee82 100644 --- a/config/locales/simple_form.fy.yml +++ b/config/locales/simple_form.fy.yml @@ -314,6 +314,7 @@ fy: listable: Tastean dat dizze hashtag yn sykopdrachten en oanrekommandaasjes te sjen is name: Hashtag trendable: Goedkarre dat dizze hashtag ûnder trends te sjen is + usable: Berjochten tastean dizze hashtag lokaal te brûken user: role: Rol time_zone: Tiidsône diff --git a/config/locales/sq.yml b/config/locales/sq.yml index ffaa8e00b9..b3d273024b 100644 --- a/config/locales/sq.yml +++ b/config/locales/sq.yml @@ -1446,6 +1446,7 @@ sq: media_attachments: validations: images_and_video: S’mund të bashkëngjitet video te një gjendje që përmban figura tashmë + not_found: S’u gjet media %{ids}, ose është bashkëngjitur tashmë një tjetër postimi not_ready: S’mund të bashkëngjiten kartela që s’kanë përfunduar së përpunuari. Riprovoni pas një çasti! too_many: S’mund të bashkëngjiten më shumë se 4 kartela migrations: diff --git a/config/locales/uk.yml b/config/locales/uk.yml index c24ed77aef..544e2671c6 100644 --- a/config/locales/uk.yml +++ b/config/locales/uk.yml @@ -1506,6 +1506,7 @@ uk: media_attachments: validations: images_and_video: Не можна додати відео до допису з зображеннями + not_found: Медіа %{ids} не знайдено або вже прикріплено до іншого допису not_ready: Не можна прикріпити файли, оброблення яких ще не закінчилося. Спробуйте ще раз через хвилину! too_many: Не можна додати більше 4 файлів migrations: diff --git a/config/locales/vi.yml b/config/locales/vi.yml index 9b3d2a1d75..2f607d1ecb 100644 --- a/config/locales/vi.yml +++ b/config/locales/vi.yml @@ -1428,6 +1428,7 @@ vi: media_attachments: validations: images_and_video: Không thể đính kèm video vào tút đã chứa hình ảnh + not_found: Không tìm thấy %{ids} hoặc nó đã bị đính kèm với tút khác not_ready: Tập tin này vẫn chưa xử lý xong. Hãy thử lại sau! too_many: Không thể đính kèm hơn 4 tệp migrations: diff --git a/config/locales/zh-TW.yml b/config/locales/zh-TW.yml index f85646b5bc..97a4399b21 100644 --- a/config/locales/zh-TW.yml +++ b/config/locales/zh-TW.yml @@ -1430,6 +1430,7 @@ zh-TW: media_attachments: validations: images_and_video: 無法於已有圖片之嘟文中加入影片 + not_found: 找不到多媒體 %{ids} 或已附加於另一嘟文中 not_ready: 修但幾勒!不能附加未完成處理的檔案欸,咁按呢? too_many: 無法加入超過 4 個檔案 migrations: From 24a0b20408447d44dfb166e6da3aff4856b1827b Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 04:03:08 -0400 Subject: [PATCH 043/153] Use `body_as_json` directly instead of via local var assignment (#31696) --- spec/requests/api/v1/accounts_spec.rb | 18 +++++----- .../v1/admin/canonical_email_blocks_spec.rb | 9 ++--- .../api/v1/admin/domain_blocks_spec.rb | 8 ++--- spec/requests/api/v1/admin/ip_blocks_spec.rb | 19 +++++----- spec/requests/api/v1/apps_spec.rb | 32 +++++++++-------- spec/requests/api/v1/blocks_spec.rb | 12 +++---- spec/requests/api/v1/featured_tags_spec.rb | 23 ++++++------ spec/requests/api/v1/markers_spec.rb | 11 +++--- spec/requests/api/v1/mutes_spec.rb | 12 +++---- spec/requests/api/v1/statuses/reblogs_spec.rb | 35 +++++++++++-------- spec/requests/api/v1/suggestions_spec.rb | 6 ++-- spec/requests/api/v2/filters/keywords_spec.rb | 16 +++++---- spec/requests/api/v2/filters/statuses_spec.rb | 12 ++++--- spec/requests/api/v2/filters_spec.rb | 15 ++++---- spec/requests/well_known/webfinger_spec.rb | 8 +++-- 15 files changed, 123 insertions(+), 113 deletions(-) diff --git a/spec/requests/api/v1/accounts_spec.rb b/spec/requests/api/v1/accounts_spec.rb index 3d9eb65019..3432106a46 100644 --- a/spec/requests/api/v1/accounts_spec.rb +++ b/spec/requests/api/v1/accounts_spec.rb @@ -114,10 +114,11 @@ describe '/api/v1/accounts' do expect(response).to have_http_status(200) - json = body_as_json - - expect(json[:following]).to be true - expect(json[:requested]).to be false + expect(body_as_json) + .to include( + following: true, + requested: false + ) expect(user.account.following?(other_account)).to be true end @@ -133,10 +134,11 @@ describe '/api/v1/accounts' do expect(response).to have_http_status(200) - json = body_as_json - - expect(json[:following]).to be false - expect(json[:requested]).to be true + expect(body_as_json) + .to include( + following: false, + requested: true + ) expect(user.account.requested?(other_account)).to be true end diff --git a/spec/requests/api/v1/admin/canonical_email_blocks_spec.rb b/spec/requests/api/v1/admin/canonical_email_blocks_spec.rb index 3f33b50f39..0cddf2c69e 100644 --- a/spec/requests/api/v1/admin/canonical_email_blocks_spec.rb +++ b/spec/requests/api/v1/admin/canonical_email_blocks_spec.rb @@ -96,10 +96,11 @@ RSpec.describe 'Canonical Email Blocks' do subject expect(response).to have_http_status(200) - json = body_as_json - - expect(json[:id]).to eq(canonical_email_block.id.to_s) - expect(json[:canonical_email_hash]).to eq(canonical_email_block.canonical_email_hash) + expect(body_as_json) + .to include( + id: eq(canonical_email_block.id.to_s), + canonical_email_hash: eq(canonical_email_block.canonical_email_hash) + ) end end diff --git a/spec/requests/api/v1/admin/domain_blocks_spec.rb b/spec/requests/api/v1/admin/domain_blocks_spec.rb index 3aa79d3ce5..7f7b9aa48a 100644 --- a/spec/requests/api/v1/admin/domain_blocks_spec.rb +++ b/spec/requests/api/v1/admin/domain_blocks_spec.rb @@ -133,10 +133,8 @@ RSpec.describe 'Domain Blocks' do it 'creates a domain block with the expected domain name and severity', :aggregate_failures do subject - body = body_as_json - expect(response).to have_http_status(200) - expect(body).to match a_hash_including( + expect(body_as_json).to match a_hash_including( { domain: 'foo.bar.com', severity: 'silence', @@ -156,10 +154,8 @@ RSpec.describe 'Domain Blocks' do it 'creates a domain block with the expected domain name and severity', :aggregate_failures do subject - body = body_as_json - expect(response).to have_http_status(200) - expect(body).to match a_hash_including( + expect(body_as_json).to match a_hash_including( { domain: 'foo.bar.com', severity: 'suspend', diff --git a/spec/requests/api/v1/admin/ip_blocks_spec.rb b/spec/requests/api/v1/admin/ip_blocks_spec.rb index 98b954dd49..bd4015b2d9 100644 --- a/spec/requests/api/v1/admin/ip_blocks_spec.rb +++ b/spec/requests/api/v1/admin/ip_blocks_spec.rb @@ -88,10 +88,12 @@ RSpec.describe 'IP Blocks' do subject expect(response).to have_http_status(200) - json = body_as_json - expect(json[:ip]).to eq("#{ip_block.ip}/#{ip_block.ip.prefix}") - expect(json[:severity]).to eq(ip_block.severity.to_s) + expect(body_as_json) + .to include( + ip: eq("#{ip_block.ip}/#{ip_block.ip.prefix}"), + severity: eq(ip_block.severity.to_s) + ) end context 'when ip block does not exist' do @@ -118,11 +120,12 @@ RSpec.describe 'IP Blocks' do subject expect(response).to have_http_status(200) - json = body_as_json - - expect(json[:ip]).to eq("#{params[:ip]}/32") - expect(json[:severity]).to eq(params[:severity]) - expect(json[:comment]).to eq(params[:comment]) + expect(body_as_json) + .to include( + ip: eq("#{params[:ip]}/32"), + severity: eq(params[:severity]), + comment: eq(params[:comment]) + ) end context 'when the required ip param is not provided' do diff --git a/spec/requests/api/v1/apps_spec.rb b/spec/requests/api/v1/apps_spec.rb index 1f01bddf3c..81d6c68126 100644 --- a/spec/requests/api/v1/apps_spec.rb +++ b/spec/requests/api/v1/apps_spec.rb @@ -61,9 +61,10 @@ RSpec.describe 'Apps' do expect(response).to have_http_status(200) expect(Doorkeeper::Application.find_by(name: client_name)).to be_present - body = body_as_json - - expect(body[:scopes]).to eq Doorkeeper.config.default_scopes.to_a + expect(body_as_json) + .to include( + scopes: Doorkeeper.config.default_scopes.to_a + ) end end @@ -81,9 +82,10 @@ RSpec.describe 'Apps' do expect(app).to be_present expect(app.scopes.to_s).to eq 'read' - body = body_as_json - - expect(body[:scopes]).to eq ['read'] + expect(body_as_json) + .to include( + scopes: %w(read) + ) end end @@ -163,10 +165,11 @@ RSpec.describe 'Apps' do expect(app.redirect_uri).to eq redirect_uris expect(app.redirect_uris).to eq redirect_uris.split - body = body_as_json - - expect(body[:redirect_uri]).to eq redirect_uris - expect(body[:redirect_uris]).to eq redirect_uris.split + expect(body_as_json) + .to include( + redirect_uri: redirect_uris, + redirect_uris: redirect_uris.split + ) end end @@ -184,10 +187,11 @@ RSpec.describe 'Apps' do expect(app.redirect_uri).to eq redirect_uris.join "\n" expect(app.redirect_uris).to eq redirect_uris - body = body_as_json - - expect(body[:redirect_uri]).to eq redirect_uris.join "\n" - expect(body[:redirect_uris]).to eq redirect_uris + expect(body_as_json) + .to include( + redirect_uri: redirect_uris.join("\n"), + redirect_uris: redirect_uris + ) end end diff --git a/spec/requests/api/v1/blocks_spec.rb b/spec/requests/api/v1/blocks_spec.rb index c6c2d56f36..06d2c4d997 100644 --- a/spec/requests/api/v1/blocks_spec.rb +++ b/spec/requests/api/v1/blocks_spec.rb @@ -55,10 +55,8 @@ RSpec.describe 'Blocks' do it 'queries the blocks in range according to max_id', :aggregate_failures do subject - response_body = body_as_json - - expect(response_body.size).to be 1 - expect(response_body[0][:id]).to eq(blocks[0].target_account.id.to_s) + expect(body_as_json) + .to contain_exactly(include(id: blocks.first.target_account.id.to_s)) end end @@ -68,10 +66,8 @@ RSpec.describe 'Blocks' do it 'queries the blocks in range according to since_id', :aggregate_failures do subject - response_body = body_as_json - - expect(response_body.size).to be 1 - expect(response_body[0][:id]).to eq(blocks[2].target_account.id.to_s) + expect(body_as_json) + .to contain_exactly(include(id: blocks[2].target_account.id.to_s)) end end end diff --git a/spec/requests/api/v1/featured_tags_spec.rb b/spec/requests/api/v1/featured_tags_spec.rb index 4b96988704..81e99e015b 100644 --- a/spec/requests/api/v1/featured_tags_spec.rb +++ b/spec/requests/api/v1/featured_tags_spec.rb @@ -37,9 +37,7 @@ RSpec.describe 'FeaturedTags' do it 'returns an empty body' do get '/api/v1/featured_tags', headers: headers - body = body_as_json - - expect(body).to be_empty + expect(body_as_json).to be_empty end end @@ -49,10 +47,10 @@ RSpec.describe 'FeaturedTags' do it 'returns only the featured tags belonging to the requesting user' do get '/api/v1/featured_tags', headers: headers - body = body_as_json - expected_ids = user_featured_tags.pluck(:id).map(&:to_s) - - expect(body.pluck(:id)).to match_array(expected_ids) + expect(body_as_json.pluck(:id)) + .to match_array( + user_featured_tags.pluck(:id).map(&:to_s) + ) end end end @@ -69,9 +67,10 @@ RSpec.describe 'FeaturedTags' do it 'returns the correct tag name' do post '/api/v1/featured_tags', headers: headers, params: params - body = body_as_json - - expect(body[:name]).to eq(params[:name]) + expect(body_as_json) + .to include( + name: params[:name] + ) end it 'creates a new featured tag for the requesting user' do @@ -142,9 +141,7 @@ RSpec.describe 'FeaturedTags' do it 'returns an empty body' do delete "/api/v1/featured_tags/#{id}", headers: headers - body = body_as_json - - expect(body).to be_empty + expect(body_as_json).to be_empty end it 'deletes the featured tag', :inline_jobs do diff --git a/spec/requests/api/v1/markers_spec.rb b/spec/requests/api/v1/markers_spec.rb index b04adf2594..2dbb9d205a 100644 --- a/spec/requests/api/v1/markers_spec.rb +++ b/spec/requests/api/v1/markers_spec.rb @@ -17,13 +17,12 @@ RSpec.describe 'API Markers' do end it 'returns markers', :aggregate_failures do - json = body_as_json - expect(response).to have_http_status(200) - expect(json.key?(:home)).to be true - expect(json[:home][:last_read_id]).to eq '123' - expect(json.key?(:notifications)).to be true - expect(json[:notifications][:last_read_id]).to eq '456' + expect(body_as_json) + .to include( + home: include(last_read_id: '123'), + notifications: include(last_read_id: '456') + ) end end diff --git a/spec/requests/api/v1/mutes_spec.rb b/spec/requests/api/v1/mutes_spec.rb index 019bf16584..988bb3c399 100644 --- a/spec/requests/api/v1/mutes_spec.rb +++ b/spec/requests/api/v1/mutes_spec.rb @@ -58,10 +58,8 @@ RSpec.describe 'Mutes' do it 'queries mutes in range according to max_id', :aggregate_failures do subject - body = body_as_json - - expect(body.size).to eq 1 - expect(body[0][:id]).to eq mutes[0].target_account_id.to_s + expect(body_as_json) + .to contain_exactly(include(id: mutes.first.target_account_id.to_s)) end end @@ -71,10 +69,8 @@ RSpec.describe 'Mutes' do it 'queries mutes in range according to since_id', :aggregate_failures do subject - body = body_as_json - - expect(body.size).to eq 1 - expect(body[0][:id]).to eq mutes[1].target_account_id.to_s + expect(body_as_json) + .to contain_exactly(include(id: mutes[1].target_account_id.to_s)) end end diff --git a/spec/requests/api/v1/statuses/reblogs_spec.rb b/spec/requests/api/v1/statuses/reblogs_spec.rb index 503d804ed0..77542d294e 100644 --- a/spec/requests/api/v1/statuses/reblogs_spec.rb +++ b/spec/requests/api/v1/statuses/reblogs_spec.rb @@ -24,11 +24,14 @@ describe 'API V1 Statuses Reblogs' do expect(user.account.reblogged?(status)).to be true - hash_body = body_as_json - - expect(hash_body[:reblog][:id]).to eq status.id.to_s - expect(hash_body[:reblog][:reblogs_count]).to eq 1 - expect(hash_body[:reblog][:reblogged]).to be true + expect(body_as_json) + .to include( + reblog: include( + id: status.id.to_s, + reblogs_count: 1, + reblogged: true + ) + ) end end @@ -57,11 +60,12 @@ describe 'API V1 Statuses Reblogs' do expect(user.account.reblogged?(status)).to be false - hash_body = body_as_json - - expect(hash_body[:id]).to eq status.id.to_s - expect(hash_body[:reblogs_count]).to eq 0 - expect(hash_body[:reblogged]).to be false + expect(body_as_json) + .to include( + id: status.id.to_s, + reblogs_count: 0, + reblogged: false + ) end end @@ -81,11 +85,12 @@ describe 'API V1 Statuses Reblogs' do expect(user.account.reblogged?(status)).to be false - hash_body = body_as_json - - expect(hash_body[:id]).to eq status.id.to_s - expect(hash_body[:reblogs_count]).to eq 0 - expect(hash_body[:reblogged]).to be false + expect(body_as_json) + .to include( + id: status.id.to_s, + reblogs_count: 0, + reblogged: false + ) end end diff --git a/spec/requests/api/v1/suggestions_spec.rb b/spec/requests/api/v1/suggestions_spec.rb index dc89613fc5..b900c910df 100644 --- a/spec/requests/api/v1/suggestions_spec.rb +++ b/spec/requests/api/v1/suggestions_spec.rb @@ -32,10 +32,8 @@ RSpec.describe 'Suggestions' do it 'returns accounts' do subject - body = body_as_json - - expect(body.size).to eq 2 - expect(body.pluck(:id)).to match_array([bob, jeff].map { |i| i.id.to_s }) + expect(body_as_json) + .to contain_exactly(include(id: bob.id.to_s), include(id: jeff.id.to_s)) end context 'with limit param' do diff --git a/spec/requests/api/v2/filters/keywords_spec.rb b/spec/requests/api/v2/filters/keywords_spec.rb index 55fb2afd95..69eff5a064 100644 --- a/spec/requests/api/v2/filters/keywords_spec.rb +++ b/spec/requests/api/v2/filters/keywords_spec.rb @@ -42,9 +42,11 @@ RSpec.describe 'API V2 Filters Keywords' do it 'creates a filter', :aggregate_failures do expect(response).to have_http_status(200) - json = body_as_json - expect(json[:keyword]).to eq 'magic' - expect(json[:whole_word]).to be false + expect(body_as_json) + .to include( + keyword: 'magic', + whole_word: false + ) filter = user.account.custom_filters.first expect(filter).to_not be_nil @@ -71,9 +73,11 @@ RSpec.describe 'API V2 Filters Keywords' do it 'responds with the keyword', :aggregate_failures do expect(response).to have_http_status(200) - json = body_as_json - expect(json[:keyword]).to eq 'foo' - expect(json[:whole_word]).to be false + expect(body_as_json) + .to include( + keyword: 'foo', + whole_word: false + ) end context "when trying to access another user's filter keyword" do diff --git a/spec/requests/api/v2/filters/statuses_spec.rb b/spec/requests/api/v2/filters/statuses_spec.rb index 26d2fb00e1..5969327829 100644 --- a/spec/requests/api/v2/filters/statuses_spec.rb +++ b/spec/requests/api/v2/filters/statuses_spec.rb @@ -43,8 +43,10 @@ RSpec.describe 'API V2 Filters Statuses' do it 'creates a filter', :aggregate_failures do expect(response).to have_http_status(200) - json = body_as_json - expect(json[:status_id]).to eq status.id.to_s + expect(body_as_json) + .to include( + status_id: status.id.to_s + ) filter = user.account.custom_filters.first expect(filter).to_not be_nil @@ -71,8 +73,10 @@ RSpec.describe 'API V2 Filters Statuses' do it 'responds with the filter', :aggregate_failures do expect(response).to have_http_status(200) - json = body_as_json - expect(json[:status_id]).to eq status_filter.status_id.to_s + expect(body_as_json) + .to include( + status_id: status_filter.status.id.to_s + ) end context "when trying to access another user's filter keyword" do diff --git a/spec/requests/api/v2/filters_spec.rb b/spec/requests/api/v2/filters_spec.rb index 8609e7dca1..036a6a65a9 100644 --- a/spec/requests/api/v2/filters_spec.rb +++ b/spec/requests/api/v2/filters_spec.rb @@ -58,12 +58,15 @@ RSpec.describe 'Filters' do it 'returns a filter with keywords', :aggregate_failures do subject - json = body_as_json - - expect(json[:title]).to eq 'magic' - expect(json[:filter_action]).to eq 'hide' - expect(json[:context]).to eq ['home'] - expect(json[:keywords].map { |keyword| keyword.slice(:keyword, :whole_word) }).to match [{ keyword: 'magic', whole_word: true }] + expect(body_as_json) + .to include( + title: 'magic', + filter_action: 'hide', + context: %w(home), + keywords: contain_exactly( + include(keyword: 'magic', whole_word: true) + ) + ) end it 'creates a filter', :aggregate_failures do diff --git a/spec/requests/well_known/webfinger_spec.rb b/spec/requests/well_known/webfinger_spec.rb index 0aafdf5624..cd8a35c702 100644 --- a/spec/requests/well_known/webfinger_spec.rb +++ b/spec/requests/well_known/webfinger_spec.rb @@ -129,9 +129,11 @@ describe 'The /.well-known/webfinger endpoint' do end it 'returns links for the internal account' do - json = body_as_json - expect(json[:subject]).to eq 'acct:mastodon.internal@cb6e6126.ngrok.io' - expect(json[:aliases]).to eq ['https://cb6e6126.ngrok.io/actor'] + expect(body_as_json) + .to include( + subject: 'acct:mastodon.internal@cb6e6126.ngrok.io', + aliases: ['https://cb6e6126.ngrok.io/actor'] + ) end end From 406b8211f554bfa68058632f849690395c18fe82 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 04:03:25 -0400 Subject: [PATCH 044/153] Remove unused `Mention#active?` method (#31697) --- app/models/mention.rb | 4 ---- 1 file changed, 4 deletions(-) diff --git a/app/models/mention.rb b/app/models/mention.rb index af9bb7378b..a508ed630e 100644 --- a/app/models/mention.rb +++ b/app/models/mention.rb @@ -29,8 +29,4 @@ class Mention < ApplicationRecord to: :account, prefix: true ) - - def active? - !silent? - end end From 48379e62e4a4aae0464b6eecba5ee60e528dcce1 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 04:04:00 -0400 Subject: [PATCH 045/153] Remove unused `User#inactive_message` method (#31698) --- app/models/user.rb | 4 ---- 1 file changed, 4 deletions(-) diff --git a/app/models/user.rb b/app/models/user.rb index f22b7ec684..fcb0eced72 100644 --- a/app/models/user.rb +++ b/app/models/user.rb @@ -246,10 +246,6 @@ class User < ApplicationRecord unconfirmed? || pending? end - def inactive_message - approved? ? super : :pending - end - def approve! return if approved? From 25bbb01666222c5f6a277775b43e6151fc9c39f8 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 04:04:22 -0400 Subject: [PATCH 046/153] Remove unused helper method in spec (#31699) --- spec/helpers/statuses_helper_spec.rb | 6 ------ 1 file changed, 6 deletions(-) diff --git a/spec/helpers/statuses_helper_spec.rb b/spec/helpers/statuses_helper_spec.rb index ba6fe361d9..b7531ec0b7 100644 --- a/spec/helpers/statuses_helper_spec.rb +++ b/spec/helpers/statuses_helper_spec.rb @@ -23,12 +23,6 @@ describe StatusesHelper do end end - def status_text_summary(status) - return if status.spoiler_text.blank? - - I18n.t('statuses.content_warning', warning: status.spoiler_text) - end - describe 'fa_visibility_icon' do context 'with a status that is public' do let(:status) { Status.new(visibility: 'public') } From b8957241af9ffa0b3e4a9a6adaa043799621d421 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 04:41:11 -0400 Subject: [PATCH 047/153] Add coverage for `JsonLdHelper#uri_from_bearcap` method (#31700) --- spec/helpers/json_ld_helper_spec.rb | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/spec/helpers/json_ld_helper_spec.rb b/spec/helpers/json_ld_helper_spec.rb index 4855085027..f4b849d7a1 100644 --- a/spec/helpers/json_ld_helper_spec.rb +++ b/spec/helpers/json_ld_helper_spec.rb @@ -21,6 +21,34 @@ describe JsonLdHelper do end end + describe '#uri_from_bearcap' do + subject { helper.uri_from_bearcap(string) } + + context 'when a bear string has a u param' do + let(:string) { 'bear:?t=TOKEN&u=https://example.com/foo' } + + it 'returns the value from the u query param' do + expect(subject).to eq('https://example.com/foo') + end + end + + context 'when a bear string does not have a u param' do + let(:string) { 'bear:?t=TOKEN&h=https://example.com/foo' } + + it 'returns nil' do + expect(subject).to be_nil + end + end + + context 'when a non-bear string' do + let(:string) { 'http://example.com' } + + it 'returns the string' do + expect(subject).to eq('http://example.com') + end + end + end + describe '#first_of_value' do context 'when value.is_a?(Array)' do it 'returns value.first' do From 3efe98aa9589cec628da0ef928f2e4cd7d16654c Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Tue, 3 Sep 2024 10:55:24 +0200 Subject: [PATCH 048/153] Update libretranslate/libretranslate Docker tag to v1.6.0 (#31687) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- .devcontainer/compose.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.devcontainer/compose.yaml b/.devcontainer/compose.yaml index 1e2e1ba7de..f87082013c 100644 --- a/.devcontainer/compose.yaml +++ b/.devcontainer/compose.yaml @@ -69,7 +69,7 @@ services: hard: -1 libretranslate: - image: libretranslate/libretranslate:v1.5.7 + image: libretranslate/libretranslate:v1.6.0 restart: unless-stopped volumes: - lt-data:/home/libretranslate/.local From 2a244e2fdb7cce8288ecf015fd2e370e2ddb0360 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 04:59:37 -0400 Subject: [PATCH 049/153] Remove unused `merge_context` helper (#31703) --- app/helpers/jsonld_helper.rb | 8 -------- 1 file changed, 8 deletions(-) diff --git a/app/helpers/jsonld_helper.rb b/app/helpers/jsonld_helper.rb index 932a3420db..ba096427cf 100644 --- a/app/helpers/jsonld_helper.rb +++ b/app/helpers/jsonld_helper.rb @@ -200,14 +200,6 @@ module JsonLdHelper nil end - def merge_context(context, new_context) - if context.is_a?(Array) - context << new_context - else - [context, new_context] - end - end - def response_successful?(response) (200...300).cover?(response.code) end From 31c00108a447ff482dd7c9f47d9a8eaa3189d9b2 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 05:05:26 -0400 Subject: [PATCH 050/153] Add first pass coverage for `AnnualReport` class (#31704) --- spec/lib/annual_report_spec.rb | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 spec/lib/annual_report_spec.rb diff --git a/spec/lib/annual_report_spec.rb b/spec/lib/annual_report_spec.rb new file mode 100644 index 0000000000..ffb742697b --- /dev/null +++ b/spec/lib/annual_report_spec.rb @@ -0,0 +1,16 @@ +# frozen_string_literal: true + +require 'rails_helper' + +describe AnnualReport do + describe '#generate' do + subject { described_class.new(account, Time.zone.now.year) } + + let(:account) { Fabricate :account } + + it 'builds a report for an account' do + expect { subject.generate } + .to change(GeneratedAnnualReport, :count).by(1) + end + end +end From 4819fc72ee9941e40aea8a1e6d63dff5f479efda Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 05:13:54 -0400 Subject: [PATCH 051/153] Remove `config/secrets.yml` file (#31562) --- config/secrets.yml | 22 ---------------------- 1 file changed, 22 deletions(-) delete mode 100644 config/secrets.yml diff --git a/config/secrets.yml b/config/secrets.yml deleted file mode 100644 index 51681d7a5c..0000000000 --- a/config/secrets.yml +++ /dev/null @@ -1,22 +0,0 @@ -# Be sure to restart your server when you modify this file. - -# Your secret key is used for verifying the integrity of signed cookies. -# If you change this key, all old signed cookies will become invalid! - -# Make sure the secret is at least 30 characters and all random, -# no regular words or you'll be exposed to dictionary attacks. -# You can use `rails secret` to generate a secure secret key. - -# Make sure the secrets in this file are kept private -# if you're sharing your code publicly. - -development: - secret_key_base: d4398e4af52f1fc5be5c3c8764e9ecce7beac5462826cb8b649373b2aad5a0f133598ed817c4e9931e943041460d6b6eda40a854e825e1bbd510c4594b1538f2 - -test: - secret_key_base: 5be187ddbd651211a906f9aa399f4a148edf6e06b971c7c0b5429b9483df6e21d262cc846447d0f89b89c32d56a99e151039df5dd874ede7f712afbe041a9269 - -# Do not keep production secrets in the repository, -# instead read values from the environment. -production: - secret_key_base: <%= ENV["SECRET_KEY_BASE"] %> From 611533cd12059d365ca0267342b750e615637bd4 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Tue, 3 Sep 2024 09:53:44 +0000 Subject: [PATCH 052/153] Update dependency json-schema to v5 (#31499) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- Gemfile | 2 +- Gemfile.lock | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Gemfile b/Gemfile index f2851c55c5..af05ec8402 100644 --- a/Gemfile +++ b/Gemfile @@ -149,7 +149,7 @@ group :test do gem 'rails-controller-testing', '~> 1.0' # Validate schemas in specs - gem 'json-schema', '~> 4.0' + gem 'json-schema', '~> 5.0' # Test harness fo rack components gem 'rack-test', '~> 2.1' diff --git a/Gemfile.lock b/Gemfile.lock index b6235402b0..6d13efdb66 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -373,8 +373,8 @@ GEM json-ld-preloaded (3.3.0) json-ld (~> 3.3) rdf (~> 3.3) - json-schema (4.3.1) - addressable (>= 2.8) + json-schema (5.0.0) + addressable (~> 2.8) jsonapi-renderer (0.2.2) jwt (2.7.1) kaminari (1.2.2) @@ -965,7 +965,7 @@ DEPENDENCIES irb (~> 1.8) json-ld json-ld-preloaded (~> 3.2) - json-schema (~> 4.0) + json-schema (~> 5.0) kaminari (~> 1.2) kt-paperclip (~> 7.2) letter_opener (~> 1.8) From e9adba60af868fedc17c7303aa5ef21e7d22a778 Mon Sep 17 00:00:00 2001 From: Claire Date: Mon, 2 Sep 2024 22:14:04 +0200 Subject: [PATCH 053/153] [Glitch] Fix not being able to load more notifications after trimming Port c1795ee9639b56d14687416135c627bb99efbff2 to glitch-soc Signed-off-by: Claire --- .../glitch/reducers/notification_groups.ts | 25 ++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) diff --git a/app/javascript/flavours/glitch/reducers/notification_groups.ts b/app/javascript/flavours/glitch/reducers/notification_groups.ts index 0fabf21b53..30f7b58737 100644 --- a/app/javascript/flavours/glitch/reducers/notification_groups.ts +++ b/app/javascript/flavours/glitch/reducers/notification_groups.ts @@ -248,8 +248,9 @@ function processNewNotification( } function trimNotifications(state: NotificationGroupsState) { - if (state.scrolledToTop) { + if (state.scrolledToTop && state.groups.length > NOTIFICATIONS_TRIM_LIMIT) { state.groups.splice(NOTIFICATIONS_TRIM_LIMIT); + ensureTrailingGap(state.groups); } } @@ -400,6 +401,28 @@ function ensureLeadingGap( } } +// Ensure the groups list ends with a gap suitable for loading more, mutating it to append one if needed +function ensureTrailingGap( + groups: NotificationGroupsState['groups'], +): NotificationGap { + const groupOrGap = groups.at(-1); + + if (groupOrGap?.type === 'gap') { + // We're expecting older notifications, so discard sinceId if it's set + groupOrGap.sinceId = undefined; + + return groupOrGap; + } else { + const gap: NotificationGap = { + type: 'gap', + maxId: groupOrGap?.page_min_id, + }; + + groups.push(gap); + return gap; + } +} + export const notificationGroupsReducer = createReducer( initialState, (builder) => { From 0437dd9e770c293ec4f16d0513d1d5dd65209406 Mon Sep 17 00:00:00 2001 From: Claire Date: Tue, 3 Sep 2024 13:37:09 +0200 Subject: [PATCH 054/153] Fix radio buttons styling in web UI (#31723) --- app/javascript/styles/mastodon/components.scss | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/javascript/styles/mastodon/components.scss b/app/javascript/styles/mastodon/components.scss index 208cdd6768..c1e5075702 100644 --- a/app/javascript/styles/mastodon/components.scss +++ b/app/javascript/styles/mastodon/components.scss @@ -7580,7 +7580,7 @@ a.status-card { } } -.radio-button.checked::before { +.radio-button__input.checked::before { position: absolute; left: 2px; top: 2px; From 219458d7d4c9bb9ee0ed3c89c72438ee4edc2e1c Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 09:18:53 -0400 Subject: [PATCH 055/153] Convert `tags` controller spec to system and request specs (#31708) --- spec/controllers/tags_controller_spec.rb | 45 ------------------ spec/requests/tags_spec.rb | 59 ++++++++++++++++++++++++ spec/system/tags_spec.rb | 16 +++++++ 3 files changed, 75 insertions(+), 45 deletions(-) delete mode 100644 spec/controllers/tags_controller_spec.rb create mode 100644 spec/requests/tags_spec.rb create mode 100644 spec/system/tags_spec.rb diff --git a/spec/controllers/tags_controller_spec.rb b/spec/controllers/tags_controller_spec.rb deleted file mode 100644 index 2bb0c8de3b..0000000000 --- a/spec/controllers/tags_controller_spec.rb +++ /dev/null @@ -1,45 +0,0 @@ -# frozen_string_literal: true - -require 'rails_helper' - -RSpec.describe TagsController do - render_views - - describe 'GET #show' do - let(:format) { 'html' } - let(:tag) { Fabricate(:tag, name: 'test') } - let(:tag_name) { tag&.name } - - before do - get :show, params: { id: tag_name, format: format } - end - - context 'when tag exists' do - context 'when requested as HTML' do - it 'returns http success' do - expect(response).to have_http_status(200) - end - - it_behaves_like 'cacheable response', expects_vary: 'Accept, Accept-Language, Cookie' - end - - context 'when requested as JSON' do - let(:format) { 'json' } - - it 'returns http success' do - expect(response).to have_http_status(200) - end - - it_behaves_like 'cacheable response', expects_vary: 'Accept, Accept-Language, Cookie' - end - end - - context 'when tag does not exist' do - let(:tag_name) { 'hoge' } - - it 'returns http not found' do - expect(response).to have_http_status(404) - end - end - end -end diff --git a/spec/requests/tags_spec.rb b/spec/requests/tags_spec.rb new file mode 100644 index 0000000000..c037bbef5a --- /dev/null +++ b/spec/requests/tags_spec.rb @@ -0,0 +1,59 @@ +# frozen_string_literal: true + +require 'rails_helper' + +RSpec.describe 'Tags' do + describe 'GET /tags/:id' do + context 'when tag exists' do + let(:tag) { Fabricate :tag } + + context 'with HTML format' do + # TODO: Convert the cacheable response shared example into a matcher, + # remove this example, rely on system spec (which should use matcher) + before { get tag_path(tag) } + + it 'returns http success' do + expect(response) + .to have_http_status(200) + end + + it_behaves_like 'cacheable response', expects_vary: 'Accept, Accept-Language, Cookie' + end + + context 'with JSON format' do + before { get tag_path(tag, format: :json) } + + it 'returns http success' do + expect(response) + .to have_http_status(200) + expect(response.content_type) + .to start_with('application/activity+json') + end + + it_behaves_like 'cacheable response', expects_vary: 'Accept, Accept-Language, Cookie' + end + + context 'with RSS format' do + before { get tag_path(tag, format: :rss) } + + it 'returns http success' do + expect(response) + .to have_http_status(200) + expect(response.content_type) + .to start_with('application/rss+xml') + end + + it_behaves_like 'cacheable response', expects_vary: 'Accept, Accept-Language, Cookie' + end + end + + context 'when tag does not exist' do + before { get tag_path('missing') } + + it 'returns http not found' do + expect(response) + .to have_http_status(404) + end + end + end +end diff --git a/spec/system/tags_spec.rb b/spec/system/tags_spec.rb new file mode 100644 index 0000000000..e9ad970a54 --- /dev/null +++ b/spec/system/tags_spec.rb @@ -0,0 +1,16 @@ +# frozen_string_literal: true + +require 'rails_helper' + +RSpec.describe 'Tags' do + describe 'Viewing a tag' do + let(:tag) { Fabricate(:tag, name: 'test') } + + it 'visits the tag page and renders the web app' do + visit tag_path(tag) + + expect(page) + .to have_css('noscript', text: /Mastodon/) + end + end +end From c9641c8070c07caa2da1e2875367a6bad8f0ecca Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 09:19:48 -0400 Subject: [PATCH 056/153] Remove un-needed edge case sort condition in languages helper (#31724) --- app/helpers/languages_helper.rb | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/app/helpers/languages_helper.rb b/app/helpers/languages_helper.rb index 9e1c0a7db1..b6c09b7314 100644 --- a/app/helpers/languages_helper.rb +++ b/app/helpers/languages_helper.rb @@ -238,9 +238,7 @@ module LanguagesHelper # Helper for self.sorted_locale_keys private_class_method def self.locale_name_for_sorting(locale) - if locale.blank? || locale == 'und' - '000' - elsif (supported_locale = SUPPORTED_LOCALES[locale.to_sym]) + if (supported_locale = SUPPORTED_LOCALES[locale.to_sym]) ASCIIFolding.new.fold(supported_locale[1]).downcase elsif (regional_locale = REGIONAL_LOCALE_NAMES[locale.to_sym]) ASCIIFolding.new.fold(regional_locale).downcase From ea0d691e196753b1a5b6747b014bac5b7da50e97 Mon Sep 17 00:00:00 2001 From: Claire Date: Tue, 3 Sep 2024 16:32:26 +0200 Subject: [PATCH 057/153] Add `GET /api/v2_alpha/notifications/:group_key/accounts` (#31725) --- .../notifications/accounts_controller.rb | 50 ++++++++++++ .../api/v2_alpha/notifications_controller.rb | 4 +- config/routes/api.rb | 4 +- .../v2_alpha/notifications/accounts_spec.rb | 80 +++++++++++++++++++ 4 files changed, 135 insertions(+), 3 deletions(-) create mode 100644 app/controllers/api/v2_alpha/notifications/accounts_controller.rb create mode 100644 spec/requests/api/v2_alpha/notifications/accounts_spec.rb diff --git a/app/controllers/api/v2_alpha/notifications/accounts_controller.rb b/app/controllers/api/v2_alpha/notifications/accounts_controller.rb new file mode 100644 index 0000000000..9933b63373 --- /dev/null +++ b/app/controllers/api/v2_alpha/notifications/accounts_controller.rb @@ -0,0 +1,50 @@ +# frozen_string_literal: true + +class Api::V2Alpha::Notifications::AccountsController < Api::BaseController + before_action -> { doorkeeper_authorize! :read, :'read:notifications' } + before_action :require_user! + before_action :set_notifications! + after_action :insert_pagination_headers, only: :index + + def index + @accounts = load_accounts + render json: @accounts, each_serializer: REST::AccountSerializer + end + + private + + def load_accounts + @paginated_notifications.map(&:from_account) + end + + def set_notifications! + @paginated_notifications = begin + current_account + .notifications + .without_suspended + .where(group_key: params[:notification_group_key]) + .includes(from_account: [:account_stat, :user]) + .paginate_by_max_id( + limit_param(DEFAULT_ACCOUNTS_LIMIT), + params[:max_id], + params[:since_id] + ) + end + end + + def next_path + api_v2_alpha_notification_accounts_url pagination_params(max_id: pagination_max_id) if records_continue? + end + + def prev_path + api_v2_alpha_notification_accounts_url pagination_params(min_id: pagination_since_id) unless @paginated_notifications.empty? + end + + def pagination_collection + @paginated_notifications + end + + def records_continue? + @paginated_notifications.size == limit_param(DEFAULT_ACCOUNTS_LIMIT) + end +end diff --git a/app/controllers/api/v2_alpha/notifications_controller.rb b/app/controllers/api/v2_alpha/notifications_controller.rb index 13a016aeb7..bd6979955a 100644 --- a/app/controllers/api/v2_alpha/notifications_controller.rb +++ b/app/controllers/api/v2_alpha/notifications_controller.rb @@ -46,7 +46,7 @@ class Api::V2Alpha::NotificationsController < Api::BaseController end def show - @notification = current_account.notifications.without_suspended.find_by!(group_key: params[:id]) + @notification = current_account.notifications.without_suspended.find_by!(group_key: params[:group_key]) presenter = GroupedNotificationsPresenter.new(NotificationGroup.from_notifications([@notification])) render json: presenter, serializer: REST::DedupNotificationGroupSerializer end @@ -57,7 +57,7 @@ class Api::V2Alpha::NotificationsController < Api::BaseController end def dismiss - current_account.notifications.where(group_key: params[:id]).destroy_all + current_account.notifications.where(group_key: params[:group_key]).destroy_all render_empty end diff --git a/config/routes/api.rb b/config/routes/api.rb index c5addd3385..df975065bd 100644 --- a/config/routes/api.rb +++ b/config/routes/api.rb @@ -344,7 +344,7 @@ namespace :api, format: false do end namespace :v2_alpha do - resources :notifications, only: [:index, :show] do + resources :notifications, param: :group_key, only: [:index, :show] do collection do post :clear get :unread_count @@ -353,6 +353,8 @@ namespace :api, format: false do member do post :dismiss end + + resources :accounts, only: [:index], module: :notifications end end diff --git a/spec/requests/api/v2_alpha/notifications/accounts_spec.rb b/spec/requests/api/v2_alpha/notifications/accounts_spec.rb new file mode 100644 index 0000000000..6a6ce043d3 --- /dev/null +++ b/spec/requests/api/v2_alpha/notifications/accounts_spec.rb @@ -0,0 +1,80 @@ +# frozen_string_literal: true + +require 'rails_helper' + +RSpec.describe 'Accounts in grouped notifications' do + let(:user) { Fabricate(:user, account_attributes: { username: 'alice' }) } + let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } + let(:scopes) { 'read:notifications write:notifications' } + let(:headers) { { 'Authorization' => "Bearer #{token.token}" } } + + describe 'GET /api/v2_alpha/notifications/:group_key/accounts', :inline_jobs do + subject do + get "/api/v2_alpha/notifications/#{user.account.notifications.first.group_key}/accounts", headers: headers, params: params + end + + let(:params) { {} } + + before do + first_status = PostStatusService.new.call(user.account, text: 'Test') + FavouriteService.new.call(Fabricate(:account), first_status) + FavouriteService.new.call(Fabricate(:account), first_status) + ReblogService.new.call(Fabricate(:account), first_status) + FollowService.new.call(Fabricate(:account), user.account) + FavouriteService.new.call(Fabricate(:account), first_status) + end + + it_behaves_like 'forbidden for wrong scope', 'write write:notifications' + + it 'returns a list of accounts' do + subject + + expect(response).to have_http_status(200) + + # The group we are interested in is only favorites + notifications = user.account.notifications.where(type: 'favourite').reorder(id: :desc) + expect(body_as_json).to match( + [ + a_hash_including( + id: notifications.first.from_account_id.to_s + ), + a_hash_including( + id: notifications.second.from_account_id.to_s + ), + a_hash_including( + id: notifications.third.from_account_id.to_s + ), + ] + ) + end + + context 'with limit param' do + let(:params) { { limit: 2 } } + + it 'returns the requested number of accounts, with pagination headers' do + subject + + expect(response).to have_http_status(200) + + # The group we are interested in is only favorites + notifications = user.account.notifications.where(type: 'favourite').reorder(id: :desc) + expect(body_as_json).to match( + [ + a_hash_including( + id: notifications.first.from_account_id.to_s + ), + a_hash_including( + id: notifications.second.from_account_id.to_s + ), + ] + ) + + expect(response) + .to include_pagination_headers( + prev: api_v2_alpha_notification_accounts_url(limit: params[:limit], min_id: notifications.first.id), + next: api_v2_alpha_notification_accounts_url(limit: params[:limit], max_id: notifications.second.id) + ) + end + end + end +end From 97bb8df1c1ba33631c71df13210aa4b7a9ce06f1 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Tue, 3 Sep 2024 16:32:59 +0200 Subject: [PATCH 058/153] Update dependency rspec-rails to v7.0.1 (#31695) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- Gemfile.lock | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index 6d13efdb66..192142fc5f 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -714,7 +714,7 @@ GEM rspec-core (~> 3.13.0) rspec-expectations (~> 3.13.0) rspec-mocks (~> 3.13.0) - rspec-core (3.13.0) + rspec-core (3.13.1) rspec-support (~> 3.13.0) rspec-expectations (3.13.2) diff-lcs (>= 1.2.0, < 2.0) @@ -724,7 +724,7 @@ GEM rspec-mocks (3.13.1) diff-lcs (>= 1.2.0, < 2.0) rspec-support (~> 3.13.0) - rspec-rails (7.0.0) + rspec-rails (7.0.1) actionpack (>= 7.0) activesupport (>= 7.0) railties (>= 7.0) From ae363f05555115503ab4679e826c6658416c38b5 Mon Sep 17 00:00:00 2001 From: Claire Date: Tue, 3 Sep 2024 16:43:34 +0200 Subject: [PATCH 059/153] Fix spacing between icons and labels in settings/admin interface (#31728) --- app/helpers/application_helper.rb | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index f1c77d40eb..7c91df8d4f 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -106,11 +106,16 @@ module ApplicationHelper end def material_symbol(icon, attributes = {}) - inline_svg_tag( - "400-24px/#{icon}.svg", - class: ['icon', "material-#{icon}"].concat(attributes[:class].to_s.split), - role: :img, - data: attributes[:data] + safe_join( + [ + inline_svg_tag( + "400-24px/#{icon}.svg", + class: ['icon', "material-#{icon}"].concat(attributes[:class].to_s.split), + role: :img, + data: attributes[:data] + ), + ' ', + ] ) end From 5b595b8a5a0872a5c4eaaca83a60ba7b3652e847 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 11:23:16 -0400 Subject: [PATCH 060/153] Remove usage of `assigns` in controller specs (#30195) --- app/views/settings/imports/index.html.haml | 2 +- .../admin/accounts_controller_spec.rb | 11 ++++---- .../admin/domain_allows_controller_spec.rb | 1 - .../admin/domain_blocks_controller_spec.rb | 2 -- .../export_domain_blocks_controller_spec.rb | 22 +++++++++------- .../admin/instances_controller_spec.rb | 9 ++++--- .../admin/invites_controller_spec.rb | 3 ++- .../admin/reports_controller_spec.rb | 26 +++++++++---------- .../authorize_interactions_controller_spec.rb | 10 ++++--- .../account_controller_concern_spec.rb | 7 ++--- .../settings/imports_controller_spec.rb | 8 +++--- .../confirmations_controller_spec.rb | 13 +++++++--- .../recovery_codes_controller_spec.rb | 3 ++- 13 files changed, 66 insertions(+), 51 deletions(-) diff --git a/app/views/settings/imports/index.html.haml b/app/views/settings/imports/index.html.haml index ca815720fd..bfddd45460 100644 --- a/app/views/settings/imports/index.html.haml +++ b/app/views/settings/imports/index.html.haml @@ -46,7 +46,7 @@ %th= t('imports.failures') %tbody - @recent_imports.each do |import| - %tr + %tr{ id: dom_id(import) } %td= t("imports.types.#{import.type}") %td - if import.state_unconfirmed? diff --git a/spec/controllers/admin/accounts_controller_spec.rb b/spec/controllers/admin/accounts_controller_spec.rb index f241d261b1..89a7239f53 100644 --- a/spec/controllers/admin/accounts_controller_spec.rb +++ b/spec/controllers/admin/accounts_controller_spec.rb @@ -40,15 +40,16 @@ RSpec.describe Admin::AccountsController do expect(response) .to have_http_status(200) - expect(assigns(:accounts)) - .to have_attributes( - count: eq(1), - klass: be(Account) - ) + expect(accounts_table_rows.size) + .to eq(1) expect(AccountFilter) .to have_received(:new) .with(hash_including(params)) end + + def accounts_table_rows + Nokogiri::Slop(response.body).css('table.accounts-table tr') + end end describe 'GET #show' do diff --git a/spec/controllers/admin/domain_allows_controller_spec.rb b/spec/controllers/admin/domain_allows_controller_spec.rb index 6f82f322b5..036d229091 100644 --- a/spec/controllers/admin/domain_allows_controller_spec.rb +++ b/spec/controllers/admin/domain_allows_controller_spec.rb @@ -13,7 +13,6 @@ RSpec.describe Admin::DomainAllowsController do it 'assigns a new domain allow' do get :new - expect(assigns(:domain_allow)).to be_instance_of(DomainAllow) expect(response).to have_http_status(200) end end diff --git a/spec/controllers/admin/domain_blocks_controller_spec.rb b/spec/controllers/admin/domain_blocks_controller_spec.rb index eb2c6265d1..a99ca6c641 100644 --- a/spec/controllers/admin/domain_blocks_controller_spec.rb +++ b/spec/controllers/admin/domain_blocks_controller_spec.rb @@ -13,7 +13,6 @@ RSpec.describe Admin::DomainBlocksController do it 'assigns a new domain block' do get :new - expect(assigns(:domain_block)).to be_instance_of(DomainBlock) expect(response).to have_http_status(200) end end @@ -171,7 +170,6 @@ RSpec.describe Admin::DomainBlocksController do it 'returns http success' do get :edit, params: { id: domain_block.id } - expect(assigns(:domain_block)).to be_instance_of(DomainBlock) expect(response).to have_http_status(200) end end diff --git a/spec/controllers/admin/export_domain_blocks_controller_spec.rb b/spec/controllers/admin/export_domain_blocks_controller_spec.rb index bfcccfa06c..39195716c5 100644 --- a/spec/controllers/admin/export_domain_blocks_controller_spec.rb +++ b/spec/controllers/admin/export_domain_blocks_controller_spec.rb @@ -42,11 +42,8 @@ RSpec.describe Admin::ExportDomainBlocksController do post :import, params: { admin_import: { data: fixture_file_upload('domain_blocks.csv') } } end - it 'renders page with expected domain blocks' do - expect(assigns(:domain_blocks).map { |block| [block.domain, block.severity.to_sym] }).to contain_exactly(['bad.domain', :silence], ['worse.domain', :suspend], ['reject.media', :noop]) - end - - it 'returns http success' do + it 'renders page with expected domain blocks and returns http success' do + expect(mapped_batch_table_rows).to contain_exactly(['bad.domain', :silence], ['worse.domain', :suspend], ['reject.media', :noop]) expect(response).to have_http_status(200) end end @@ -56,14 +53,19 @@ RSpec.describe Admin::ExportDomainBlocksController do post :import, params: { admin_import: { data: fixture_file_upload('domain_blocks_list.txt') } } end - it 'renders page with expected domain blocks' do - expect(assigns(:domain_blocks).map { |block| [block.domain, block.severity.to_sym] }).to contain_exactly(['bad.domain', :suspend], ['worse.domain', :suspend], ['reject.media', :suspend]) - end - - it 'returns http success' do + it 'renders page with expected domain blocks and returns http success' do + expect(mapped_batch_table_rows).to contain_exactly(['bad.domain', :suspend], ['worse.domain', :suspend], ['reject.media', :suspend]) expect(response).to have_http_status(200) end end + + def mapped_batch_table_rows + batch_table_rows.map { |row| [row.at_css('[id$=_domain]')['value'], row.at_css('[id$=_severity]')['value'].to_sym] } + end + + def batch_table_rows + Nokogiri::Slop(response.body).css('body div.batch-table__row') + end end it 'displays error on no file selected' do diff --git a/spec/controllers/admin/instances_controller_spec.rb b/spec/controllers/admin/instances_controller_spec.rb index ca64dd90a0..a64bbb2c9f 100644 --- a/spec/controllers/admin/instances_controller_spec.rb +++ b/spec/controllers/admin/instances_controller_spec.rb @@ -28,12 +28,15 @@ RSpec.describe Admin::InstancesController do it 'renders instances' do get :index, params: { page: 2 } - instances = assigns(:instances).to_a - expect(instances.size).to eq 1 - expect(instances[0].domain).to eq 'less.popular' + expect(instance_directory_links.size).to eq(1) + expect(instance_directory_links.first.text.strip).to match('less.popular') expect(response).to have_http_status(200) end + + def instance_directory_links + Nokogiri::Slop(response.body).css('div.directory__tag a') + end end describe 'GET #show' do diff --git a/spec/controllers/admin/invites_controller_spec.rb b/spec/controllers/admin/invites_controller_spec.rb index 71748cbbec..8638f8e214 100644 --- a/spec/controllers/admin/invites_controller_spec.rb +++ b/spec/controllers/admin/invites_controller_spec.rb @@ -18,7 +18,8 @@ describe Admin::InvitesController do it 'renders index page' do expect(subject).to render_template :index - expect(assigns(:invites)).to include invite + expect(response.body) + .to include(invite.code) end end diff --git a/spec/controllers/admin/reports_controller_spec.rb b/spec/controllers/admin/reports_controller_spec.rb index 5849163b5f..67fb28e7a5 100644 --- a/spec/controllers/admin/reports_controller_spec.rb +++ b/spec/controllers/admin/reports_controller_spec.rb @@ -13,39 +13,39 @@ describe Admin::ReportsController do describe 'GET #index' do it 'returns http success with no filters' do - specified = Fabricate(:report, action_taken_at: nil) - Fabricate(:report, action_taken_at: Time.now.utc) + specified = Fabricate(:report, action_taken_at: nil, comment: 'First report') + other = Fabricate(:report, action_taken_at: Time.now.utc, comment: 'Second report') get :index - reports = assigns(:reports).to_a - expect(reports.size).to eq 1 - expect(reports[0]).to eq specified expect(response).to have_http_status(200) + expect(response.body) + .to include(specified.comment) + .and not_include(other.comment) end it 'returns http success with resolved filter' do - specified = Fabricate(:report, action_taken_at: Time.now.utc) - Fabricate(:report, action_taken_at: nil) + specified = Fabricate(:report, action_taken_at: Time.now.utc, comment: 'First report') + other = Fabricate(:report, action_taken_at: nil, comment: 'Second report') get :index, params: { resolved: '1' } - reports = assigns(:reports).to_a - expect(reports.size).to eq 1 - expect(reports[0]).to eq specified - expect(response).to have_http_status(200) + expect(response.body) + .to include(specified.comment) + .and not_include(other.comment) end end describe 'GET #show' do it 'renders report' do - report = Fabricate(:report) + report = Fabricate(:report, comment: 'A big problem') get :show, params: { id: report } - expect(assigns(:report)).to eq report expect(response).to have_http_status(200) + expect(response.body) + .to include(report.comment) end end diff --git a/spec/controllers/authorize_interactions_controller_spec.rb b/spec/controllers/authorize_interactions_controller_spec.rb index 5282a196a6..ed55df08d9 100644 --- a/spec/controllers/authorize_interactions_controller_spec.rb +++ b/spec/controllers/authorize_interactions_controller_spec.rb @@ -46,8 +46,9 @@ describe AuthorizeInteractionsController do get :show, params: { acct: 'http://example.com' } - expect(response).to have_http_status(302) - expect(assigns(:resource)).to eq account + expect(response) + .to have_http_status(302) + .and redirect_to(web_url("@#{account.pretty_acct}")) end it 'sets resource from acct uri' do @@ -58,8 +59,9 @@ describe AuthorizeInteractionsController do get :show, params: { acct: 'acct:found@hostname' } - expect(response).to have_http_status(302) - expect(assigns(:resource)).to eq account + expect(response) + .to have_http_status(302) + .and redirect_to(web_url("@#{account.pretty_acct}")) end end end diff --git a/spec/controllers/concerns/account_controller_concern_spec.rb b/spec/controllers/concerns/account_controller_concern_spec.rb index 6eb970dedb..122ef21e93 100644 --- a/spec/controllers/concerns/account_controller_concern_spec.rb +++ b/spec/controllers/concerns/account_controller_concern_spec.rb @@ -7,7 +7,7 @@ describe AccountControllerConcern do include AccountControllerConcern def success - head 200 + render plain: @account.username # rubocop:disable RSpec/InstanceVariable end end @@ -51,12 +51,13 @@ describe AccountControllerConcern do context 'when account is not suspended' do let(:account) { Fabricate(:account, username: 'username') } - it 'assigns @account, returns success, and sets link headers' do + it 'Prepares the account, returns success, and sets link headers' do get 'success', params: { account_username: account.username } - expect(assigns(:account)).to eq account expect(response).to have_http_status(200) expect(response.headers['Link'].to_s).to eq(expected_link_headers) + expect(response.body) + .to include(account.username) end def expected_link_headers diff --git a/spec/controllers/settings/imports_controller_spec.rb b/spec/controllers/settings/imports_controller_spec.rb index 89ec39e54d..219b882e6d 100644 --- a/spec/controllers/settings/imports_controller_spec.rb +++ b/spec/controllers/settings/imports_controller_spec.rb @@ -21,9 +21,10 @@ RSpec.describe Settings::ImportsController do it 'assigns the expected imports', :aggregate_failures do expect(response).to have_http_status(200) - expect(assigns(:recent_imports)).to eq [import] - expect(assigns(:recent_imports)).to_not include(other_import) expect(response.headers['Cache-Control']).to include('private, no-store') + expect(response.body) + .to include("bulk_import_#{import.id}") + .and not_include("bulk_import_#{other_import.id}") end end @@ -261,7 +262,8 @@ RSpec.describe Settings::ImportsController do it 'does not creates an unconfirmed bulk_import', :aggregate_failures do expect { subject }.to_not(change { user.account.bulk_imports.count }) - expect(assigns(:import).errors).to_not be_empty + expect(response.body) + .to include('field_with_errors') end end diff --git a/spec/controllers/settings/two_factor_authentication/confirmations_controller_spec.rb b/spec/controllers/settings/two_factor_authentication/confirmations_controller_spec.rb index 1b3b0cb0ae..1c8b483a0a 100644 --- a/spec/controllers/settings/two_factor_authentication/confirmations_controller_spec.rb +++ b/spec/controllers/settings/two_factor_authentication/confirmations_controller_spec.rb @@ -9,11 +9,16 @@ describe Settings::TwoFactorAuthentication::ConfirmationsController do it 'renders the new view' do subject - expect(assigns(:confirmation)).to be_instance_of Form::TwoFactorConfirmation - expect(assigns(:provision_url)).to eq 'otpauth://totp/cb6e6126.ngrok.io:local-part%40domain?secret=thisisasecretforthespecofnewview&issuer=cb6e6126.ngrok.io' - expect(assigns(:qrcode)).to be_instance_of RQRCode::QRCode expect(response).to have_http_status(200) expect(response).to render_template(:new) + expect(response.body) + .to include(qr_code_markup) + end + + def qr_code_markup + RQRCode::QRCode.new( + 'otpauth://totp/cb6e6126.ngrok.io:local-part%40domain?secret=thisisasecretforthespecofnewview&issuer=cb6e6126.ngrok.io' + ).as_svg(padding: 0, module_size: 4) end end @@ -61,10 +66,10 @@ describe Settings::TwoFactorAuthentication::ConfirmationsController do expect { post_create_with_options } .to change { user.reload.otp_secret }.to 'thisisasecretforthespecofnewview' - expect(assigns(:recovery_codes)).to eq otp_backup_codes expect(flash[:notice]).to eq 'Two-factor authentication successfully enabled' expect(response).to have_http_status(200) expect(response).to render_template('settings/two_factor_authentication/recovery_codes/index') + expect(response.body).to include(*otp_backup_codes) end end diff --git a/spec/controllers/settings/two_factor_authentication/recovery_codes_controller_spec.rb b/spec/controllers/settings/two_factor_authentication/recovery_codes_controller_spec.rb index 28a40e138c..dbc2e3059c 100644 --- a/spec/controllers/settings/two_factor_authentication/recovery_codes_controller_spec.rb +++ b/spec/controllers/settings/two_factor_authentication/recovery_codes_controller_spec.rb @@ -15,10 +15,11 @@ describe Settings::TwoFactorAuthentication::RecoveryCodesController do sign_in user, scope: :user post :create, session: { challenge_passed_at: Time.now.utc } - expect(assigns(:recovery_codes)).to eq otp_backup_codes expect(flash[:notice]).to eq 'Recovery codes successfully regenerated' expect(response).to have_http_status(200) expect(response).to render_template(:index) + expect(response.body) + .to include(*otp_backup_codes) end it 'redirects when not signed in' do From 79b1841805f47cd3931bfdb7d51e1791529c3845 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 11:23:57 -0400 Subject: [PATCH 061/153] Disable `without_verify_partial_doubles` in statuses/show view spec (#29132) --- spec/spec_helper.rb | 6 ------ spec/views/statuses/show.html.haml_spec.rb | 21 +++++++++++++++++---- 2 files changed, 17 insertions(+), 10 deletions(-) diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 248c2c4105..2d20239b27 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -8,12 +8,6 @@ RSpec.configure do |config| config.mock_with :rspec do |mocks| mocks.verify_partial_doubles = true - - config.around(:example, :without_verify_partial_doubles) do |example| - mocks.verify_partial_doubles = false - example.call - mocks.verify_partial_doubles = true - end end config.before :suite do diff --git a/spec/views/statuses/show.html.haml_spec.rb b/spec/views/statuses/show.html.haml_spec.rb index 1c408db6c5..fd08f2772d 100644 --- a/spec/views/statuses/show.html.haml_spec.rb +++ b/spec/views/statuses/show.html.haml_spec.rb @@ -2,14 +2,13 @@ require 'rails_helper' -describe 'statuses/show.html.haml', :without_verify_partial_doubles do +describe 'statuses/show.html.haml' do let(:alice) { Fabricate(:account, username: 'alice', display_name: 'Alice') } let(:status) { Fabricate(:status, account: alice, text: 'Hello World') } before do - allow(view).to receive_messages(api_oembed_url: '', site_title: 'example site', site_hostname: 'example.com', full_asset_url: '//asset.host/image.svg', current_account: nil, single_user_mode?: false) - allow(view).to receive(:local_time) - allow(view).to receive(:local_time_ago) + view.extend view_helpers + assign(:instance_presenter, InstancePresenter.new) Fabricate(:media_attachment, account: alice, status: status, type: :video) @@ -40,4 +39,18 @@ describe 'statuses/show.html.haml', :without_verify_partial_doubles do def header_tags view.content_for(:header_tags) end + + def view_helpers + Module.new do + def api_oembed_url(_) = '' + def show_landing_strip? = true + def site_title = 'example site' + def site_hostname = 'example.com' + def full_asset_url(_) = '//asset.host/image.svg' + def current_account = nil + def single_user_mode? = false + def local_time = nil + def local_time_ago = nil + end + end end From dc2f67f69bfd0536564268eb73a79f1eec80cb03 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 11:24:31 -0400 Subject: [PATCH 062/153] Remove `fuubar` gem and custom rspec `--format` setting (#30594) --- .gitignore | 3 +++ .rspec | 1 - Gemfile | 3 --- Gemfile.lock | 4 ---- 4 files changed, 3 insertions(+), 8 deletions(-) diff --git a/.gitignore b/.gitignore index a70f30f952..a74317bd7d 100644 --- a/.gitignore +++ b/.gitignore @@ -71,3 +71,6 @@ docker-compose.override.yml # Ignore dotenv .local files .env*.local + +# Ignore local-only rspec configuration +.rspec-local diff --git a/.rspec b/.rspec index 9a8e706d09..83e16f8044 100644 --- a/.rspec +++ b/.rspec @@ -1,3 +1,2 @@ --color --require spec_helper ---format Fuubar diff --git a/Gemfile b/Gemfile index af05ec8402..6538067cff 100644 --- a/Gemfile +++ b/Gemfile @@ -126,9 +126,6 @@ group :test do # Adds RSpec Error/Warning annotations to GitHub PRs on the Files tab gem 'rspec-github', '~> 2.4', require: false - # RSpec progress bar formatter - gem 'fuubar', '~> 2.5' - # RSpec helpers for email specs gem 'email_spec' diff --git a/Gemfile.lock b/Gemfile.lock index 192142fc5f..2e9037d8a6 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -288,9 +288,6 @@ GEM fugit (1.11.1) et-orbi (~> 1, >= 1.2.11) raabro (~> 1.4) - fuubar (2.5.1) - rspec-core (~> 3.0) - ruby-progressbar (~> 1.4) globalid (1.2.1) activesupport (>= 6.1) google-protobuf (3.25.4) @@ -949,7 +946,6 @@ DEPENDENCIES flatware-rspec fog-core (<= 2.5.0) fog-openstack (~> 1.0) - fuubar (~> 2.5) haml-rails (~> 2.0) haml_lint hcaptcha (~> 7.1) From ef4920c6c92b4191b12f0de820d694e8abf14d4a Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 11:28:57 -0400 Subject: [PATCH 063/153] Pull out https/hostname setup for request specs to shared config (#31622) --- spec/rails_helper.rb | 6 ++++++ spec/requests/account_show_page_spec.rb | 2 +- spec/requests/api/v1/streaming_spec.rb | 5 ++--- spec/requests/link_headers_spec.rb | 2 +- spec/requests/media_proxy_spec.rb | 17 +++++++++++------ 5 files changed, 21 insertions(+), 11 deletions(-) diff --git a/spec/rails_helper.rb b/spec/rails_helper.rb index ba712c08f9..0c3d01c785 100644 --- a/spec/rails_helper.rb +++ b/spec/rails_helper.rb @@ -142,6 +142,12 @@ RSpec.configure do |config| end end + config.before :each, type: :request do + # Use https and configured hostname in request spec requests + integration_session.https! + host! Rails.configuration.x.local_domain + end + config.after do Rails.cache.clear redis.del(redis.keys) diff --git a/spec/requests/account_show_page_spec.rb b/spec/requests/account_show_page_spec.rb index 830d778608..bdcec12fdb 100644 --- a/spec/requests/account_show_page_spec.rb +++ b/spec/requests/account_show_page_spec.rb @@ -14,7 +14,7 @@ describe 'The account show page' do expect(head_meta_content('og:title')).to match alice.display_name expect(head_meta_content('og:type')).to eq 'profile' expect(head_meta_content('og:image')).to match '.+' - expect(head_meta_content('og:url')).to match 'http://.+' + expect(head_meta_content('og:url')).to eq short_account_url(username: alice.username) end def head_link_icons diff --git a/spec/requests/api/v1/streaming_spec.rb b/spec/requests/api/v1/streaming_spec.rb index 6b550dfa60..6ce35c2fe6 100644 --- a/spec/requests/api/v1/streaming_spec.rb +++ b/spec/requests/api/v1/streaming_spec.rb @@ -10,12 +10,11 @@ describe 'API V1 Streaming' do Rails.configuration.x.streaming_api_base_url = before end - let(:headers) { { 'Host' => Rails.configuration.x.web_domain } } - context 'with streaming api on same host' do describe 'GET /api/v1/streaming' do it 'raises ActiveRecord::RecordNotFound' do - get '/api/v1/streaming', headers: headers + integration_session.https!(false) + get '/api/v1/streaming' expect(response).to have_http_status(404) end diff --git a/spec/requests/link_headers_spec.rb b/spec/requests/link_headers_spec.rb index b822adbfb8..522cff4642 100644 --- a/spec/requests/link_headers_spec.rb +++ b/spec/requests/link_headers_spec.rb @@ -13,7 +13,7 @@ describe 'Link headers' do it 'contains webfinger url in link header' do link_header = link_header_with_type('application/jrd+json') - expect(link_header.href).to eq 'http://www.example.com/.well-known/webfinger?resource=acct%3Atest%40cb6e6126.ngrok.io' + expect(link_header.href).to eq 'https://cb6e6126.ngrok.io/.well-known/webfinger?resource=acct%3Atest%40cb6e6126.ngrok.io' expect(link_header.attr_pairs.first).to eq %w(rel lrdd) end diff --git a/spec/requests/media_proxy_spec.rb b/spec/requests/media_proxy_spec.rb index 0524105d90..814d4c1166 100644 --- a/spec/requests/media_proxy_spec.rb +++ b/spec/requests/media_proxy_spec.rb @@ -4,12 +4,7 @@ require 'rails_helper' describe 'Media Proxy' do describe 'GET /media_proxy/:id' do - before do - integration_session.https! # TODO: Move to global rails_helper for all request specs? - host! Rails.configuration.x.local_domain # TODO: Move to global rails_helper for all request specs? - - stub_request(:get, 'http://example.com/attachment.png').to_return(request_fixture('avatar.txt')) - end + before { stub_attachment_request } context 'when attached to a status' do let(:status) { Fabricate(:status) } @@ -63,5 +58,15 @@ describe 'Media Proxy' do .to have_http_status(404) end end + + def stub_attachment_request + stub_request( + :get, + 'http://example.com/attachment.png' + ) + .to_return( + request_fixture('avatar.txt') + ) + end end end From 928390c2ba4e8c6f433025f3eb3ecd89337a2660 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 11:29:32 -0400 Subject: [PATCH 064/153] Convert `admin/settings` controller specs to system specs (#31548) --- .../admin/settings/about_controller_spec.rb | 29 --------------- .../settings/appearance_controller_spec.rb | 29 --------------- .../settings/branding_controller_spec.rb | 17 --------- .../content_retention_controller_spec.rb | 29 --------------- .../settings/discovery_controller_spec.rb | 29 --------------- .../settings/registrations_controller_spec.rb | 29 --------------- spec/rails_helper.rb | 1 + spec/support/system_helpers.rb | 19 ++++++++++ spec/system/admin/settings/about_spec.rb | 22 +++++++++++ spec/system/admin/settings/appearance_spec.rb | 22 +++++++++++ spec/system/admin/settings/branding_spec.rb | 37 +++++++++++++++++++ .../admin/settings/content_retention_spec.rb | 22 +++++++++++ spec/system/admin/settings/discovery_spec.rb | 21 +++++++++++ .../admin/settings/registrations_spec.rb | 26 +++++++++++++ 14 files changed, 170 insertions(+), 162 deletions(-) delete mode 100644 spec/controllers/admin/settings/about_controller_spec.rb delete mode 100644 spec/controllers/admin/settings/appearance_controller_spec.rb delete mode 100644 spec/controllers/admin/settings/content_retention_controller_spec.rb delete mode 100644 spec/controllers/admin/settings/discovery_controller_spec.rb delete mode 100644 spec/controllers/admin/settings/registrations_controller_spec.rb create mode 100644 spec/support/system_helpers.rb create mode 100644 spec/system/admin/settings/about_spec.rb create mode 100644 spec/system/admin/settings/appearance_spec.rb create mode 100644 spec/system/admin/settings/branding_spec.rb create mode 100644 spec/system/admin/settings/content_retention_spec.rb create mode 100644 spec/system/admin/settings/discovery_spec.rb create mode 100644 spec/system/admin/settings/registrations_spec.rb diff --git a/spec/controllers/admin/settings/about_controller_spec.rb b/spec/controllers/admin/settings/about_controller_spec.rb deleted file mode 100644 index f322cb4434..0000000000 --- a/spec/controllers/admin/settings/about_controller_spec.rb +++ /dev/null @@ -1,29 +0,0 @@ -# frozen_string_literal: true - -require 'rails_helper' - -describe Admin::Settings::AboutController do - render_views - - let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } - - before do - sign_in user, scope: :user - end - - describe 'GET #show' do - it 'returns http success' do - get :show - - expect(response).to have_http_status(:success) - end - end - - describe 'PUT #update' do - it 'updates the settings' do - put :update, params: { form_admin_settings: { site_extended_description: 'new site description' } } - - expect(response).to redirect_to(admin_settings_about_path) - end - end -end diff --git a/spec/controllers/admin/settings/appearance_controller_spec.rb b/spec/controllers/admin/settings/appearance_controller_spec.rb deleted file mode 100644 index ea6f3b7833..0000000000 --- a/spec/controllers/admin/settings/appearance_controller_spec.rb +++ /dev/null @@ -1,29 +0,0 @@ -# frozen_string_literal: true - -require 'rails_helper' - -describe Admin::Settings::AppearanceController do - render_views - - let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } - - before do - sign_in user, scope: :user - end - - describe 'GET #show' do - it 'returns http success' do - get :show - - expect(response).to have_http_status(:success) - end - end - - describe 'PUT #update' do - it 'updates the settings' do - put :update, params: { form_admin_settings: { custom_css: 'html { display: inline; }' } } - - expect(response).to redirect_to(admin_settings_appearance_path) - end - end -end diff --git a/spec/controllers/admin/settings/branding_controller_spec.rb b/spec/controllers/admin/settings/branding_controller_spec.rb index e30300b4e4..5e46910cc6 100644 --- a/spec/controllers/admin/settings/branding_controller_spec.rb +++ b/spec/controllers/admin/settings/branding_controller_spec.rb @@ -10,14 +10,6 @@ RSpec.describe Admin::Settings::BrandingController do sign_in Fabricate(:user, role: UserRole.find_by(name: 'Admin')), scope: :user end - describe 'GET #show' do - it 'returns http success' do - get :show - - expect(response).to have_http_status(200) - end - end - describe 'PUT #update' do it 'cannot create a setting value for a non-admin key' do expect(Setting.new_setting_key).to be_blank @@ -27,15 +19,6 @@ RSpec.describe Admin::Settings::BrandingController do expect(response).to redirect_to(admin_settings_branding_path) expect(Setting.new_setting_key).to be_nil end - - it 'creates a settings value that didnt exist before for eligible key' do - expect(Setting.site_short_description).to be_blank - - patch :update, params: { form_admin_settings: { site_short_description: 'New key value' } } - - expect(response).to redirect_to(admin_settings_branding_path) - expect(Setting.site_short_description).to eq 'New key value' - end end end end diff --git a/spec/controllers/admin/settings/content_retention_controller_spec.rb b/spec/controllers/admin/settings/content_retention_controller_spec.rb deleted file mode 100644 index fb6a3d2848..0000000000 --- a/spec/controllers/admin/settings/content_retention_controller_spec.rb +++ /dev/null @@ -1,29 +0,0 @@ -# frozen_string_literal: true - -require 'rails_helper' - -describe Admin::Settings::ContentRetentionController do - render_views - - let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } - - before do - sign_in user, scope: :user - end - - describe 'GET #show' do - it 'returns http success' do - get :show - - expect(response).to have_http_status(:success) - end - end - - describe 'PUT #update' do - it 'updates the settings' do - put :update, params: { form_admin_settings: { media_cache_retention_period: '2' } } - - expect(response).to redirect_to(admin_settings_content_retention_path) - end - end -end diff --git a/spec/controllers/admin/settings/discovery_controller_spec.rb b/spec/controllers/admin/settings/discovery_controller_spec.rb deleted file mode 100644 index 33109e3c01..0000000000 --- a/spec/controllers/admin/settings/discovery_controller_spec.rb +++ /dev/null @@ -1,29 +0,0 @@ -# frozen_string_literal: true - -require 'rails_helper' - -describe Admin::Settings::DiscoveryController do - render_views - - let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } - - before do - sign_in user, scope: :user - end - - describe 'GET #show' do - it 'returns http success' do - get :show - - expect(response).to have_http_status(:success) - end - end - - describe 'PUT #update' do - it 'updates the settings' do - put :update, params: { form_admin_settings: { trends: '1' } } - - expect(response).to redirect_to(admin_settings_discovery_path) - end - end -end diff --git a/spec/controllers/admin/settings/registrations_controller_spec.rb b/spec/controllers/admin/settings/registrations_controller_spec.rb deleted file mode 100644 index e076544603..0000000000 --- a/spec/controllers/admin/settings/registrations_controller_spec.rb +++ /dev/null @@ -1,29 +0,0 @@ -# frozen_string_literal: true - -require 'rails_helper' - -describe Admin::Settings::RegistrationsController do - render_views - - let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } - - before do - sign_in user, scope: :user - end - - describe 'GET #show' do - it 'returns http success' do - get :show - - expect(response).to have_http_status(:success) - end - end - - describe 'PUT #update' do - it 'updates the settings' do - put :update, params: { form_admin_settings: { registrations_mode: 'open' } } - - expect(response).to redirect_to(admin_settings_registrations_path) - end - end -end diff --git a/spec/rails_helper.rb b/spec/rails_helper.rb index 0c3d01c785..2a602d113a 100644 --- a/spec/rails_helper.rb +++ b/spec/rails_helper.rb @@ -112,6 +112,7 @@ RSpec.configure do |config| config.include ThreadingHelpers config.include SignedRequestHelpers, type: :request config.include CommandLineHelpers, type: :cli + config.include SystemHelpers, type: :system config.around(:each, use_transactional_tests: false) do |example| self.use_transactional_tests = false diff --git a/spec/support/system_helpers.rb b/spec/support/system_helpers.rb new file mode 100644 index 0000000000..05c9d3b125 --- /dev/null +++ b/spec/support/system_helpers.rb @@ -0,0 +1,19 @@ +# frozen_string_literal: true + +module SystemHelpers + def admin_user + Fabricate(:user, role: UserRole.find_by(name: 'Admin')) + end + + def submit_button + I18n.t('generic.save_changes') + end + + def success_message + I18n.t('generic.changes_saved_msg') + end + + def form_label(key) + I18n.t key, scope: 'simple_form.labels' + end +end diff --git a/spec/system/admin/settings/about_spec.rb b/spec/system/admin/settings/about_spec.rb new file mode 100644 index 0000000000..0f8ae5605c --- /dev/null +++ b/spec/system/admin/settings/about_spec.rb @@ -0,0 +1,22 @@ +# frozen_string_literal: true + +require 'rails_helper' + +describe 'Admin::Settings::About' do + it 'Saves changes to about settings' do + sign_in admin_user + visit admin_settings_about_path + + fill_in extended_description_field, + with: 'new site description' + + click_on submit_button + + expect(page) + .to have_content(success_message) + end + + def extended_description_field + form_label 'form_admin_settings.site_extended_description' + end +end diff --git a/spec/system/admin/settings/appearance_spec.rb b/spec/system/admin/settings/appearance_spec.rb new file mode 100644 index 0000000000..99e97ea4d1 --- /dev/null +++ b/spec/system/admin/settings/appearance_spec.rb @@ -0,0 +1,22 @@ +# frozen_string_literal: true + +require 'rails_helper' + +describe 'Admin::Settings::Appearance' do + it 'Saves changes to appearance settings' do + sign_in admin_user + visit admin_settings_appearance_path + + fill_in custom_css_field, + with: 'html { display: inline; }' + + click_on submit_button + + expect(page) + .to have_content(success_message) + end + + def custom_css_field + form_label 'form_admin_settings.custom_css' + end +end diff --git a/spec/system/admin/settings/branding_spec.rb b/spec/system/admin/settings/branding_spec.rb new file mode 100644 index 0000000000..ac47e04d53 --- /dev/null +++ b/spec/system/admin/settings/branding_spec.rb @@ -0,0 +1,37 @@ +# frozen_string_literal: true + +require 'rails_helper' + +describe 'Admin::Settings::Branding' do + it 'Saves changes to branding settings' do + sign_in admin_user + visit admin_settings_branding_path + + fill_in short_description_field, + with: 'new key value' + + fill_in site_contact_email_field, + with: User.last.email + + fill_in site_contact_username_field, + with: Account.last.username + + expect { click_on submit_button } + .to change(Setting, :site_short_description).to('new key value') + + expect(page) + .to have_content(success_message) + end + + def short_description_field + form_label 'form_admin_settings.site_short_description' + end + + def site_contact_email_field + form_label 'form_admin_settings.site_contact_email' + end + + def site_contact_username_field + form_label 'form_admin_settings.site_contact_username' + end +end diff --git a/spec/system/admin/settings/content_retention_spec.rb b/spec/system/admin/settings/content_retention_spec.rb new file mode 100644 index 0000000000..9867122675 --- /dev/null +++ b/spec/system/admin/settings/content_retention_spec.rb @@ -0,0 +1,22 @@ +# frozen_string_literal: true + +require 'rails_helper' + +describe 'Admin::Settings::ContentRetention' do + it 'Saves changes to content retention settings' do + sign_in admin_user + visit admin_settings_content_retention_path + + fill_in media_cache_retention_period_field, + with: '2' + + click_on submit_button + + expect(page) + .to have_content(success_message) + end + + def media_cache_retention_period_field + form_label 'form_admin_settings.media_cache_retention_period' + end +end diff --git a/spec/system/admin/settings/discovery_spec.rb b/spec/system/admin/settings/discovery_spec.rb new file mode 100644 index 0000000000..bdab91107d --- /dev/null +++ b/spec/system/admin/settings/discovery_spec.rb @@ -0,0 +1,21 @@ +# frozen_string_literal: true + +require 'rails_helper' + +describe 'Admin::Settings::Discovery' do + it 'Saves changes to discovery settings' do + sign_in admin_user + visit admin_settings_discovery_path + + check trends_box + + click_on submit_button + + expect(page) + .to have_content(success_message) + end + + def trends_box + form_label 'form_admin_settings.trends' + end +end diff --git a/spec/system/admin/settings/registrations_spec.rb b/spec/system/admin/settings/registrations_spec.rb new file mode 100644 index 0000000000..88c750e8ee --- /dev/null +++ b/spec/system/admin/settings/registrations_spec.rb @@ -0,0 +1,26 @@ +# frozen_string_literal: true + +require 'rails_helper' + +describe 'Admin::Settings::Registrations' do + it 'Saves changes to registrations settings' do + sign_in admin_user + visit admin_settings_registrations_path + + select open_mode_option, + from: registrations_mode_field + + click_on submit_button + + expect(page) + .to have_content(success_message) + end + + def open_mode_option + I18n.t('admin.settings.registrations_mode.modes.open') + end + + def registrations_mode_field + form_label 'form_admin_settings.registrations_mode' + end +end From fcb83be8b23f64d336d7d3aca2829e9b92ff1df2 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 11:30:13 -0400 Subject: [PATCH 065/153] Improve coverage specificity for Webhook enable/disable/secret specs (#31194) --- spec/models/webhook_spec.rb | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/spec/models/webhook_spec.rb b/spec/models/webhook_spec.rb index effaf92e9c..864baf2e1a 100644 --- a/spec/models/webhook_spec.rb +++ b/spec/models/webhook_spec.rb @@ -38,28 +38,28 @@ RSpec.describe Webhook do describe '#rotate_secret!' do it 'changes the secret' do - previous_value = webhook.secret - webhook.rotate_secret! - expect(webhook.secret).to_not be_blank - expect(webhook.secret).to_not eq previous_value + expect { webhook.rotate_secret! } + .to change(webhook, :secret) + expect(webhook.secret) + .to_not be_blank end end describe '#enable!' do - before do - webhook.disable! - end + let(:webhook) { Fabricate(:webhook, enabled: false) } it 'enables the webhook' do - webhook.enable! - expect(webhook.enabled?).to be true + expect { webhook.enable! } + .to change(webhook, :enabled?).to(true) end end describe '#disable!' do + let(:webhook) { Fabricate(:webhook, enabled: true) } + it 'disables the webhook' do - webhook.disable! - expect(webhook.enabled?).to be false + expect { webhook.disable! } + .to change(webhook, :enabled?).to(false) end end end From 67faaf555723e8b202620725b7144a183543809e Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 11:30:57 -0400 Subject: [PATCH 066/153] Simplify account model username presence validation spec (#31013) --- Gemfile | 2 ++ Gemfile.lock | 3 +++ spec/models/account_spec.rb | 6 +----- spec/support/shoulda_matchers.rb | 8 ++++++++ 4 files changed, 14 insertions(+), 5 deletions(-) create mode 100644 spec/support/shoulda_matchers.rb diff --git a/Gemfile b/Gemfile index 6538067cff..4c808fa480 100644 --- a/Gemfile +++ b/Gemfile @@ -151,6 +151,8 @@ group :test do # Test harness fo rack components gem 'rack-test', '~> 2.1' + gem 'shoulda-matchers' + # Coverage formatter for RSpec test if DISABLE_SIMPLECOV is false gem 'simplecov', '~> 0.22', require: false gem 'simplecov-lcov', '~> 0.8', require: false diff --git a/Gemfile.lock b/Gemfile.lock index 2e9037d8a6..461a2d43a2 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -790,6 +790,8 @@ GEM rubyzip (>= 1.2.2, < 3.0) websocket (~> 1.0) semantic_range (3.0.0) + shoulda-matchers (6.3.1) + activesupport (>= 5.2.0) sidekiq (6.5.12) connection_pool (>= 2.2.5, < 3) rack (~> 2.0) @@ -1035,6 +1037,7 @@ DEPENDENCIES sanitize (~> 6.0) scenic (~> 1.7) selenium-webdriver + shoulda-matchers sidekiq (~> 6.5) sidekiq-bulk (~> 0.2.0) sidekiq-scheduler (~> 5.0) diff --git a/spec/models/account_spec.rb b/spec/models/account_spec.rb index 8e5648a0b0..14528ed17b 100644 --- a/spec/models/account_spec.rb +++ b/spec/models/account_spec.rb @@ -722,11 +722,7 @@ RSpec.describe Account do end describe 'validations' do - it 'is invalid without a username' do - account = Fabricate.build(:account, username: nil) - account.valid? - expect(account).to model_have_error_on_field(:username) - end + it { is_expected.to validate_presence_of(:username) } it 'squishes the username before validation' do account = Fabricate(:account, domain: nil, username: " \u3000bob \t \u00a0 \n ") diff --git a/spec/support/shoulda_matchers.rb b/spec/support/shoulda_matchers.rb new file mode 100644 index 0000000000..edcf9dd859 --- /dev/null +++ b/spec/support/shoulda_matchers.rb @@ -0,0 +1,8 @@ +# frozen_string_literal: true + +Shoulda::Matchers.configure do |config| + config.integrate do |with| + with.test_framework :rspec + with.library :rails + end +end From 8922786ef48951a3d4ce719a0e40ef96d2a3792c Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 11:32:12 -0400 Subject: [PATCH 067/153] Fix `RSpec/LetSetup` cop in api/v1/timelines/tag spec (#30796) --- spec/requests/api/v1/timelines/tag_spec.rb | 23 ++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) diff --git a/spec/requests/api/v1/timelines/tag_spec.rb b/spec/requests/api/v1/timelines/tag_spec.rb index 5e1415bb1a..cfbfa0291c 100644 --- a/spec/requests/api/v1/timelines/tag_spec.rb +++ b/spec/requests/api/v1/timelines/tag_spec.rb @@ -8,22 +8,25 @@ RSpec.describe 'Tag' do let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:headers) { { 'Authorization' => "Bearer #{token.token}" } } - shared_examples 'a successful request to the tag timeline' do - it 'returns the expected statuses', :aggregate_failures do - subject - - expect(response).to have_http_status(200) - expect(body_as_json.pluck(:id)).to match_array(expected_statuses.map { |status| status.id.to_s }) - end - end - describe 'GET /api/v1/timelines/tag/:hashtag' do subject do get "/api/v1/timelines/tag/#{hashtag}", headers: headers, params: params end + shared_examples 'a successful request to the tag timeline' do + it 'returns the expected statuses', :aggregate_failures do + subject + + expect(response) + .to have_http_status(200) + expect(body_as_json.pluck(:id)) + .to match_array(expected_statuses.map { |status| status.id.to_s }) + .and not_include(private_status.id) + end + end + let(:account) { Fabricate(:account) } - let!(:private_status) { PostStatusService.new.call(account, visibility: :private, text: '#life could be a dream') } # rubocop:disable RSpec/LetSetup + let!(:private_status) { PostStatusService.new.call(account, visibility: :private, text: '#life could be a dream') } let!(:life_status) { PostStatusService.new.call(account, text: 'tell me what is my #life without your #love') } let!(:war_status) { PostStatusService.new.call(user.account, text: '#war, war never changes') } let!(:love_status) { PostStatusService.new.call(account, text: 'what is #love?') } From 46828044481f2a2698483d7bfa4ca36b04980d40 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 11:32:22 -0400 Subject: [PATCH 068/153] Fix `Rails/ReversibleMigration` cop for `remove_index` (#30832) --- db/migrate/20161122163057_remove_unneeded_indexes.rb | 6 +++--- db/migrate/20171129172043_add_index_on_stream_entries.rb | 2 +- .../20171212195226_remove_duplicate_indexes_in_lists.rb | 4 ++-- .../20171226094803_more_faster_index_on_notifications.rb | 2 +- ...x_on_statuses_for_api_v1_accounts_account_id_statuses.rb | 2 +- db/migrate/20180617162849_remove_unused_indexes.rb | 6 +++--- 6 files changed, 11 insertions(+), 11 deletions(-) diff --git a/db/migrate/20161122163057_remove_unneeded_indexes.rb b/db/migrate/20161122163057_remove_unneeded_indexes.rb index 7ed92127d7..2496184703 100644 --- a/db/migrate/20161122163057_remove_unneeded_indexes.rb +++ b/db/migrate/20161122163057_remove_unneeded_indexes.rb @@ -2,8 +2,8 @@ class RemoveUnneededIndexes < ActiveRecord::Migration[5.0] def change - remove_index :notifications, name: 'index_notifications_on_account_id' - remove_index :settings, name: 'index_settings_on_target_type_and_target_id' - remove_index :statuses_tags, name: 'index_statuses_tags_on_tag_id' + remove_index :notifications, :account_id, name: 'index_notifications_on_account_id' + remove_index :settings, [:target_type, :target_id], name: 'index_settings_on_target_type_and_target_id' + remove_index :statuses_tags, :tag_id, name: 'index_statuses_tags_on_tag_id' end end diff --git a/db/migrate/20171129172043_add_index_on_stream_entries.rb b/db/migrate/20171129172043_add_index_on_stream_entries.rb index c959135c22..e861cdc2d1 100644 --- a/db/migrate/20171129172043_add_index_on_stream_entries.rb +++ b/db/migrate/20171129172043_add_index_on_stream_entries.rb @@ -5,6 +5,6 @@ class AddIndexOnStreamEntries < ActiveRecord::Migration[5.2] def change add_index :stream_entries, [:account_id, :activity_type, :id], algorithm: :concurrently - remove_index :stream_entries, name: :index_stream_entries_on_account_id + remove_index :stream_entries, :account_id, name: :index_stream_entries_on_account_id end end diff --git a/db/migrate/20171212195226_remove_duplicate_indexes_in_lists.rb b/db/migrate/20171212195226_remove_duplicate_indexes_in_lists.rb index 362b1367df..6f51f0a063 100644 --- a/db/migrate/20171212195226_remove_duplicate_indexes_in_lists.rb +++ b/db/migrate/20171212195226_remove_duplicate_indexes_in_lists.rb @@ -2,7 +2,7 @@ class RemoveDuplicateIndexesInLists < ActiveRecord::Migration[5.2] def change - remove_index :list_accounts, name: 'index_list_accounts_on_account_id' - remove_index :list_accounts, name: 'index_list_accounts_on_list_id' + remove_index :list_accounts, :account_id, name: 'index_list_accounts_on_account_id' + remove_index :list_accounts, :list_id, name: 'index_list_accounts_on_list_id' end end diff --git a/db/migrate/20171226094803_more_faster_index_on_notifications.rb b/db/migrate/20171226094803_more_faster_index_on_notifications.rb index 429eab96a1..b2fc040e2e 100644 --- a/db/migrate/20171226094803_more_faster_index_on_notifications.rb +++ b/db/migrate/20171226094803_more_faster_index_on_notifications.rb @@ -5,6 +5,6 @@ class MoreFasterIndexOnNotifications < ActiveRecord::Migration[5.2] def change add_index :notifications, [:account_id, :id], order: { id: :desc }, algorithm: :concurrently - remove_index :notifications, name: :index_notifications_on_id_and_account_id_and_activity_type + remove_index :notifications, [:id, :account_id, :activity_type], name: :index_notifications_on_id_and_account_id_and_activity_type end end diff --git a/db/migrate/20180106000232_add_index_on_statuses_for_api_v1_accounts_account_id_statuses.rb b/db/migrate/20180106000232_add_index_on_statuses_for_api_v1_accounts_account_id_statuses.rb index 1531c4dd29..4c3a25e838 100644 --- a/db/migrate/20180106000232_add_index_on_statuses_for_api_v1_accounts_account_id_statuses.rb +++ b/db/migrate/20180106000232_add_index_on_statuses_for_api_v1_accounts_account_id_statuses.rb @@ -7,6 +7,6 @@ class AddIndexOnStatusesForApiV1AccountsAccountIdStatuses < ActiveRecord::Migrat safety_assured do add_index :statuses, [:account_id, :id, :visibility, :updated_at], order: { id: :desc }, algorithm: :concurrently, name: :index_statuses_20180106 end - remove_index :statuses, name: :index_statuses_on_account_id_id + remove_index :statuses, [:account_id, :id], name: :index_statuses_on_account_id_id end end diff --git a/db/migrate/20180617162849_remove_unused_indexes.rb b/db/migrate/20180617162849_remove_unused_indexes.rb index 14766589fd..cf8faceb3a 100644 --- a/db/migrate/20180617162849_remove_unused_indexes.rb +++ b/db/migrate/20180617162849_remove_unused_indexes.rb @@ -2,8 +2,8 @@ class RemoveUnusedIndexes < ActiveRecord::Migration[5.2] def change - remove_index :statuses, name: 'index_statuses_on_conversation_id' - remove_index :users, name: 'index_users_on_filtered_languages' - remove_index :backups, name: 'index_backups_on_user_id' + remove_index :statuses, :conversation_id, name: 'index_statuses_on_conversation_id' + remove_index :users, :filtered_languages, name: 'index_users_on_filtered_languages' + remove_index :backups, :user_id, name: 'index_backups_on_user_id' end end From 490bdb7944fd2fe323494b3bbd60130673ccfa33 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 11:34:09 -0400 Subject: [PATCH 069/153] Add coverage for `StatusesHelper#media_summary` method (#31726) --- spec/helpers/statuses_helper_spec.rb | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/spec/helpers/statuses_helper_spec.rb b/spec/helpers/statuses_helper_spec.rb index b7531ec0b7..66eb996f99 100644 --- a/spec/helpers/statuses_helper_spec.rb +++ b/spec/helpers/statuses_helper_spec.rb @@ -23,6 +23,19 @@ describe StatusesHelper do end end + describe '#media_summary' do + it 'describes the media on a status' do + status = Fabricate :status + Fabricate :media_attachment, status: status, type: :video + Fabricate :media_attachment, status: status, type: :audio + Fabricate :media_attachment, status: status, type: :image + + result = helper.media_summary(status) + + expect(result).to eq('Attached: 1 image · 1 video · 1 audio') + end + end + describe 'fa_visibility_icon' do context 'with a status that is public' do let(:status) { Status.new(visibility: 'public') } From e1fa456c7cfa5dc41cec21a94573bc6cb1ec60cc Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 11:35:19 -0400 Subject: [PATCH 070/153] Add `have_cacheable_headers` matcher for responses (#31727) --- .../collections_controller_spec.rb | 13 ++--- .../activitypub/outboxes_controller_spec.rb | 14 +++--- .../activitypub/replies_controller_spec.rb | 7 +-- spec/controllers/statuses_controller_spec.rb | 9 ++-- spec/requests/accounts_spec.rb | 32 ++++++------ spec/requests/custom_stylesheets_spec.rb | 3 +- spec/requests/instance_actor_spec.rb | 3 +- spec/requests/manifest_spec.rb | 3 +- spec/requests/tags_spec.rb | 13 ++--- spec/support/examples/cache.rb | 14 ------ spec/support/matchers/cacheable_response.rb | 50 +++++++++++++++++++ 11 files changed, 96 insertions(+), 65 deletions(-) delete mode 100644 spec/support/examples/cache.rb create mode 100644 spec/support/matchers/cacheable_response.rb diff --git a/spec/controllers/activitypub/collections_controller_spec.rb b/spec/controllers/activitypub/collections_controller_spec.rb index a5718fbd7d..0880273853 100644 --- a/spec/controllers/activitypub/collections_controller_spec.rb +++ b/spec/controllers/activitypub/collections_controller_spec.rb @@ -25,10 +25,10 @@ RSpec.describe ActivityPub::CollectionsController do context 'without signature' do let(:remote_account) { nil } - it_behaves_like 'cacheable response' - it 'returns http success and correct media type and correct items' do - expect(response).to have_http_status(200) + expect(response) + .to have_http_status(200) + .and have_cacheable_headers expect(response.media_type).to eq 'application/activity+json' expect(body_as_json[:orderedItems]) @@ -64,10 +64,11 @@ RSpec.describe ActivityPub::CollectionsController do let(:remote_account) { Fabricate(:account, domain: 'example.com') } context 'when getting a featured resource' do - it_behaves_like 'cacheable response' - it 'returns http success and correct media type and expected items' do - expect(response).to have_http_status(200) + expect(response) + .to have_http_status(200) + .and have_cacheable_headers + expect(response.media_type).to eq 'application/activity+json' expect(body_as_json[:orderedItems]) diff --git a/spec/controllers/activitypub/outboxes_controller_spec.rb b/spec/controllers/activitypub/outboxes_controller_spec.rb index 3c8e8e399f..26a52bad93 100644 --- a/spec/controllers/activitypub/outboxes_controller_spec.rb +++ b/spec/controllers/activitypub/outboxes_controller_spec.rb @@ -25,10 +25,11 @@ RSpec.describe ActivityPub::OutboxesController do context 'with page not requested' do let(:page) { nil } - it_behaves_like 'cacheable response' - it 'returns http success and correct media type and headers and items count' do - expect(response).to have_http_status(200) + expect(response) + .to have_http_status(200) + .and have_cacheable_headers + expect(response.media_type).to eq 'application/activity+json' expect(response.headers['Vary']).to be_nil expect(body[:totalItems]).to eq 4 @@ -59,10 +60,11 @@ RSpec.describe ActivityPub::OutboxesController do context 'with page requested' do let(:page) { 'true' } - it_behaves_like 'cacheable response' - it 'returns http success and correct media type and vary header and items' do - expect(response).to have_http_status(200) + expect(response) + .to have_http_status(200) + .and have_cacheable_headers + expect(response.media_type).to eq 'application/activity+json' expect(response.headers['Vary']).to include 'Signature' diff --git a/spec/controllers/activitypub/replies_controller_spec.rb b/spec/controllers/activitypub/replies_controller_spec.rb index c556e07270..c10c782c9a 100644 --- a/spec/controllers/activitypub/replies_controller_spec.rb +++ b/spec/controllers/activitypub/replies_controller_spec.rb @@ -68,10 +68,11 @@ RSpec.describe ActivityPub::RepliesController do let(:parent_visibility) { :public } let(:page_json) { body_as_json[:first] } - it_behaves_like 'cacheable response' - it 'returns http success and correct media type' do - expect(response).to have_http_status(200) + expect(response) + .to have_http_status(200) + .and have_cacheable_headers + expect(response.media_type).to eq 'application/activity+json' end diff --git a/spec/controllers/statuses_controller_spec.rb b/spec/controllers/statuses_controller_spec.rb index fe40ee6de1..084dcfaa75 100644 --- a/spec/controllers/statuses_controller_spec.rb +++ b/spec/controllers/statuses_controller_spec.rb @@ -72,13 +72,12 @@ describe StatusesController do context 'with JSON' do let(:format) { 'json' } - it_behaves_like 'cacheable response', expects_vary: 'Accept, Accept-Language, Cookie' - it 'renders ActivityPub Note object successfully', :aggregate_failures do expect(response) .to have_http_status(200) + .and have_cacheable_headers.with_vary('Accept, Accept-Language, Cookie') + expect(response.headers).to include( - 'Vary' => 'Accept, Accept-Language, Cookie', 'Content-Type' => include('application/activity+json'), 'Link' => satisfy { |header| header.to_s.include?('activity+json') } ) @@ -380,13 +379,11 @@ describe StatusesController do context 'with JSON' do let(:format) { 'json' } - it_behaves_like 'cacheable response', expects_vary: 'Accept, Accept-Language, Cookie' - it 'renders ActivityPub Note object successfully', :aggregate_failures do expect(response) .to have_http_status(200) + .and have_cacheable_headers.with_vary('Accept, Accept-Language, Cookie') expect(response.headers).to include( - 'Vary' => 'Accept, Accept-Language, Cookie', 'Content-Type' => include('application/activity+json'), 'Link' => satisfy { |header| header.to_s.include?('activity+json') } ) diff --git a/spec/requests/accounts_spec.rb b/spec/requests/accounts_spec.rb index bf067cdc38..238524c75c 100644 --- a/spec/requests/accounts_spec.rb +++ b/spec/requests/accounts_spec.rb @@ -130,6 +130,7 @@ describe 'Accounts show response' do it 'returns a JSON version of the account', :aggregate_failures do expect(response) .to have_http_status(200) + .and have_cacheable_headers.with_vary('Accept, Accept-Language, Cookie') .and have_attributes( media_type: eq('application/activity+json') ) @@ -137,8 +138,6 @@ describe 'Accounts show response' do expect(body_as_json).to include(:id, :type, :preferredUsername, :inbox, :publicKey, :name, :summary) end - it_behaves_like 'cacheable response', expects_vary: 'Accept, Accept-Language, Cookie' - context 'with authorized fetch mode' do let(:authorized_fetch_mode) { true } @@ -179,6 +178,7 @@ describe 'Accounts show response' do it 'returns a JSON version of the account', :aggregate_failures do expect(response) .to have_http_status(200) + .and have_cacheable_headers.with_vary('Accept, Accept-Language, Cookie') .and have_attributes( media_type: eq('application/activity+json') ) @@ -186,8 +186,6 @@ describe 'Accounts show response' do expect(body_as_json).to include(:id, :type, :preferredUsername, :inbox, :publicKey, :name, :summary) end - it_behaves_like 'cacheable response', expects_vary: 'Accept, Accept-Language, Cookie' - context 'with authorized fetch mode' do let(:authorized_fetch_mode) { true } @@ -215,10 +213,10 @@ describe 'Accounts show response' do get short_account_path(username: account.username, format: format) end - it_behaves_like 'cacheable response', expects_vary: 'Accept, Accept-Language, Cookie' - it 'responds with correct statuses', :aggregate_failures do - expect(response).to have_http_status(200) + expect(response) + .to have_http_status(200) + .and have_cacheable_headers.with_vary('Accept, Accept-Language, Cookie') expect(response.body).to include(status_tag_for(status_media)) expect(response.body).to include(status_tag_for(status_self_reply)) expect(response.body).to include(status_tag_for(status)) @@ -234,10 +232,11 @@ describe 'Accounts show response' do get short_account_with_replies_path(username: account.username, format: format) end - it_behaves_like 'cacheable response', expects_vary: 'Accept, Accept-Language, Cookie' - it 'responds with correct statuses with replies', :aggregate_failures do - expect(response).to have_http_status(200) + expect(response) + .to have_http_status(200) + .and have_cacheable_headers.with_vary('Accept, Accept-Language, Cookie') + expect(response.body).to include(status_tag_for(status_media)) expect(response.body).to include(status_tag_for(status_reply)) expect(response.body).to include(status_tag_for(status_self_reply)) @@ -253,10 +252,10 @@ describe 'Accounts show response' do get short_account_media_path(username: account.username, format: format) end - it_behaves_like 'cacheable response', expects_vary: 'Accept, Accept-Language, Cookie' - it 'responds with correct statuses with media', :aggregate_failures do - expect(response).to have_http_status(200) + expect(response) + .to have_http_status(200) + .and have_cacheable_headers.with_vary('Accept, Accept-Language, Cookie') expect(response.body).to include(status_tag_for(status_media)) expect(response.body).to_not include(status_tag_for(status_direct)) expect(response.body).to_not include(status_tag_for(status_private)) @@ -277,10 +276,11 @@ describe 'Accounts show response' do get short_account_tag_path(username: account.username, tag: tag, format: format) end - it_behaves_like 'cacheable response', expects_vary: 'Accept, Accept-Language, Cookie' - it 'responds with correct statuses with a tag', :aggregate_failures do - expect(response).to have_http_status(200) + expect(response) + .to have_http_status(200) + .and have_cacheable_headers.with_vary('Accept, Accept-Language, Cookie') + expect(response.body).to include(status_tag_for(status_tag)) expect(response.body).to_not include(status_tag_for(status_direct)) expect(response.body).to_not include(status_tag_for(status_media)) diff --git a/spec/requests/custom_stylesheets_spec.rb b/spec/requests/custom_stylesheets_spec.rb index 982511297b..128d173f3a 100644 --- a/spec/requests/custom_stylesheets_spec.rb +++ b/spec/requests/custom_stylesheets_spec.rb @@ -9,11 +9,10 @@ describe 'Custom stylesheets' do it 'returns http success' do expect(response) .to have_http_status(200) + .and have_cacheable_headers .and have_attributes( content_type: match('text/css') ) end - - it_behaves_like 'cacheable response' end end diff --git a/spec/requests/instance_actor_spec.rb b/spec/requests/instance_actor_spec.rb index 9c7ee9ff90..7e4784203f 100644 --- a/spec/requests/instance_actor_spec.rb +++ b/spec/requests/instance_actor_spec.rb @@ -17,6 +17,7 @@ RSpec.describe 'Instance actor endpoint' do it 'returns http success with correct media type and body' do expect(response) .to have_http_status(200) + .and have_cacheable_headers expect(response.content_type) .to start_with('application/activity+json') expect(body_as_json) @@ -32,8 +33,6 @@ RSpec.describe 'Instance actor endpoint' do url: about_more_url(instance_actor: true) ) end - - it_behaves_like 'cacheable response' end context 'with limited federation mode disabled' do diff --git a/spec/requests/manifest_spec.rb b/spec/requests/manifest_spec.rb index 749c4038df..55b8147d7e 100644 --- a/spec/requests/manifest_spec.rb +++ b/spec/requests/manifest_spec.rb @@ -9,6 +9,7 @@ describe 'Manifest' do it 'returns http success' do expect(response) .to have_http_status(200) + .and have_cacheable_headers .and have_attributes( content_type: match('application/json') ) @@ -18,7 +19,5 @@ describe 'Manifest' do name: 'Mastodon' ) end - - it_behaves_like 'cacheable response' end end diff --git a/spec/requests/tags_spec.rb b/spec/requests/tags_spec.rb index c037bbef5a..7974a6b152 100644 --- a/spec/requests/tags_spec.rb +++ b/spec/requests/tags_spec.rb @@ -8,16 +8,15 @@ RSpec.describe 'Tags' do let(:tag) { Fabricate :tag } context 'with HTML format' do - # TODO: Convert the cacheable response shared example into a matcher, - # remove this example, rely on system spec (which should use matcher) + # TODO: Update the have_cacheable_headers matcher to operate on capybara sessions + # Remove this example, rely on system spec (which should use matcher) before { get tag_path(tag) } it 'returns http success' do expect(response) .to have_http_status(200) + .and have_cacheable_headers.with_vary('Accept, Accept-Language, Cookie') end - - it_behaves_like 'cacheable response', expects_vary: 'Accept, Accept-Language, Cookie' end context 'with JSON format' do @@ -26,11 +25,10 @@ RSpec.describe 'Tags' do it 'returns http success' do expect(response) .to have_http_status(200) + .and have_cacheable_headers.with_vary('Accept, Accept-Language, Cookie') expect(response.content_type) .to start_with('application/activity+json') end - - it_behaves_like 'cacheable response', expects_vary: 'Accept, Accept-Language, Cookie' end context 'with RSS format' do @@ -39,11 +37,10 @@ RSpec.describe 'Tags' do it 'returns http success' do expect(response) .to have_http_status(200) + .and have_cacheable_headers.with_vary('Accept, Accept-Language, Cookie') expect(response.content_type) .to start_with('application/rss+xml') end - - it_behaves_like 'cacheable response', expects_vary: 'Accept, Accept-Language, Cookie' end end diff --git a/spec/support/examples/cache.rb b/spec/support/examples/cache.rb deleted file mode 100644 index 60e522f426..0000000000 --- a/spec/support/examples/cache.rb +++ /dev/null @@ -1,14 +0,0 @@ -# frozen_string_literal: true - -shared_examples 'cacheable response' do |expects_vary: false| - it 'sets correct cache and vary headers and does not set cookies or session', :aggregate_failures do - expect(response.cookies).to be_empty - expect(response.headers['Set-Cookies']).to be_nil - - expect(session).to be_empty - - expect(response.headers['Vary']).to include(expects_vary) if expects_vary - - expect(response.headers['Cache-Control']).to include('public') - end -end diff --git a/spec/support/matchers/cacheable_response.rb b/spec/support/matchers/cacheable_response.rb new file mode 100644 index 0000000000..da8570c8c5 --- /dev/null +++ b/spec/support/matchers/cacheable_response.rb @@ -0,0 +1,50 @@ +# frozen_string_literal: true + +RSpec::Matchers.define :have_cacheable_headers do + match do |response| + @response = response + + @errors = [].tap do |errors| + errors << check_cookies + errors << check_cookie_headers + errors << check_session + errors << check_cache_control + errors << check_vary if @expected_vary.present? + end + + @errors.compact.empty? + end + + chain :with_vary do |string| + @expected_vary = string + end + + failure_message do + <<~ERROR + Expected that the response would be cacheable but it was not: + - #{@errors.compact.join("\n - ")} + ERROR + end + + def check_vary + puts @expected_vary + pp @response.headers + "Response `Vary` header does not contain `#{@expected_vary}`" unless @response.headers['Vary'].include?(@expected_vary) + end + + def check_cookies + 'Reponse cookies are present' unless @response.cookies.empty? + end + + def check_cookie_headers + 'Response `Set-Cookies` headers are present' if @response.headers['Set-Cookies'].present? + end + + def check_session + 'The session is not empty' unless session.empty? + end + + def check_cache_control + 'The `Cache-Control` header does not contain `public`' unless @response.headers['Cache-Control'].include?('public') + end +end From 2f0d0fc127c73d74c7105441bf6dd8163b14450c Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 11:36:59 -0400 Subject: [PATCH 071/153] Add coverage for `CLI::Accounts#fix_duplications` task (#30639) --- app/models/account.rb | 1 + lib/mastodon/cli/accounts.rb | 2 +- spec/lib/mastodon/cli/accounts_spec.rb | 19 +++++++++++++++++++ 3 files changed, 21 insertions(+), 1 deletion(-) diff --git a/app/models/account.rb b/app/models/account.rb index 482eaa4aba..04095890ef 100644 --- a/app/models/account.rb +++ b/app/models/account.rb @@ -145,6 +145,7 @@ class Account < ApplicationRecord scope :with_username, ->(value) { where arel_table[:username].lower.eq(value.to_s.downcase) } scope :with_domain, ->(value) { where arel_table[:domain].lower.eq(value&.to_s&.downcase) } scope :without_memorial, -> { where(memorial: false) } + scope :duplicate_uris, -> { select(:uri, Arel.star.count).group(:uri).having(Arel.star.count.gt(1)) } after_update_commit :trigger_update_webhooks diff --git a/lib/mastodon/cli/accounts.rb b/lib/mastodon/cli/accounts.rb index d3b7ebe580..0cdf68158f 100644 --- a/lib/mastodon/cli/accounts.rb +++ b/lib/mastodon/cli/accounts.rb @@ -252,7 +252,7 @@ module Mastodon::CLI domain configuration. LONG_DESC def fix_duplicates - Account.remote.select(:uri, 'count(*)').group(:uri).having('count(*) > 1').pluck(:uri).each do |uri| + Account.remote.duplicate_uris.pluck(:uri).each do |uri| say("Duplicates found for #{uri}") begin ActivityPub::FetchRemoteAccountService.new.call(uri) unless dry_run? diff --git a/spec/lib/mastodon/cli/accounts_spec.rb b/spec/lib/mastodon/cli/accounts_spec.rb index 137f85c6ca..3988e0b027 100644 --- a/spec/lib/mastodon/cli/accounts_spec.rb +++ b/spec/lib/mastodon/cli/accounts_spec.rb @@ -613,6 +613,25 @@ describe Mastodon::CLI::Accounts do end end + describe '#fix_duplicates' do + let(:action) { :fix_duplicates } + let(:service_double) { instance_double(ActivityPub::FetchRemoteAccountService, call: nil) } + let(:uri) { 'https://host.example/same/value' } + + context 'when there are duplicate URI accounts' do + before do + Fabricate.times(2, :account, domain: 'host.example', uri: uri) + allow(ActivityPub::FetchRemoteAccountService).to receive(:new).and_return(service_double) + end + + it 'finds the duplicates and calls fetch remote account service' do + expect { subject } + .to output_results('Duplicates found') + expect(service_double).to have_received(:call).with(uri) + end + end + end + describe '#backup' do let(:action) { :backup } From 7c26e5e4a101e2784d8c627055b4caad5812015f Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 11:37:45 -0400 Subject: [PATCH 072/153] Add `Reviewable` model concern (#31152) --- app/models/account.rb | 17 +----- app/models/concerns/reviewable.rb | 21 ++++++++ app/models/preview_card_provider.rb | 17 +----- app/models/tag.rb | 18 +------ spec/models/account_spec.rb | 2 + spec/models/preview_card_provider_spec.rb | 2 + spec/models/tag_spec.rb | 2 + .../examples/models/concerns/reviewable.rb | 54 +++++++++++++++++++ 8 files changed, 85 insertions(+), 48 deletions(-) create mode 100644 app/models/concerns/reviewable.rb create mode 100644 spec/support/examples/models/concerns/reviewable.rb diff --git a/app/models/account.rb b/app/models/account.rb index 04095890ef..c20b72658b 100644 --- a/app/models/account.rb +++ b/app/models/account.rb @@ -89,6 +89,7 @@ class Account < ApplicationRecord include DomainMaterializable include DomainNormalizable include Paginable + include Reviewable enum :protocol, { ostatus: 0, activitypub: 1 } enum :suspension_origin, { local: 0, remote: 1 }, prefix: true @@ -426,22 +427,6 @@ class Account < ApplicationRecord @synchronization_uri_prefix ||= "#{uri[URL_PREFIX_RE]}/" end - def requires_review? - reviewed_at.nil? - end - - def reviewed? - reviewed_at.present? - end - - def requested_review? - requested_review_at.present? - end - - def requires_review_notification? - requires_review? && !requested_review? - end - class << self def readonly_attributes super - %w(statuses_count following_count followers_count) diff --git a/app/models/concerns/reviewable.rb b/app/models/concerns/reviewable.rb new file mode 100644 index 0000000000..1f70474b35 --- /dev/null +++ b/app/models/concerns/reviewable.rb @@ -0,0 +1,21 @@ +# frozen_string_literal: true + +module Reviewable + extend ActiveSupport::Concern + + def requires_review? + reviewed_at.nil? + end + + def reviewed? + reviewed_at.present? + end + + def requested_review? + requested_review_at.present? + end + + def requires_review_notification? + requires_review? && !requested_review? + end +end diff --git a/app/models/preview_card_provider.rb b/app/models/preview_card_provider.rb index 756707e3f1..48944fe638 100644 --- a/app/models/preview_card_provider.rb +++ b/app/models/preview_card_provider.rb @@ -21,6 +21,7 @@ class PreviewCardProvider < ApplicationRecord include Paginable include DomainNormalizable include Attachmentable + include Reviewable ICON_MIME_TYPES = %w(image/x-icon image/vnd.microsoft.icon image/png).freeze LIMIT = 1.megabyte @@ -36,22 +37,6 @@ class PreviewCardProvider < ApplicationRecord scope :reviewed, -> { where.not(reviewed_at: nil) } scope :pending_review, -> { where(reviewed_at: nil) } - def requires_review? - reviewed_at.nil? - end - - def reviewed? - reviewed_at.present? - end - - def requested_review? - requested_review_at.present? - end - - def requires_review_notification? - requires_review? && !requested_review? - end - def self.matching_domain(domain) segments = domain.split('.') where(domain: segments.map.with_index { |_, i| segments[i..].join('.') }).by_domain_length.first diff --git a/app/models/tag.rb b/app/models/tag.rb index 9006e1f25d..acf514919b 100644 --- a/app/models/tag.rb +++ b/app/models/tag.rb @@ -21,6 +21,8 @@ class Tag < ApplicationRecord include Paginable + include Reviewable + # rubocop:disable Rails/HasAndBelongsToMany has_and_belongs_to_many :statuses has_and_belongs_to_many :accounts @@ -97,22 +99,6 @@ class Tag < ApplicationRecord alias trendable? trendable - def requires_review? - reviewed_at.nil? - end - - def reviewed? - reviewed_at.present? - end - - def requested_review? - requested_review_at.present? - end - - def requires_review_notification? - requires_review? && !requested_review? - end - def decaying? max_score_at && max_score_at >= Trends.tags.options[:max_score_cooldown].ago && max_score_at < 1.day.ago end diff --git a/spec/models/account_spec.rb b/spec/models/account_spec.rb index 14528ed17b..83f1585b61 100644 --- a/spec/models/account_spec.rb +++ b/spec/models/account_spec.rb @@ -3,6 +3,8 @@ require 'rails_helper' RSpec.describe Account do + include_examples 'Reviewable' + context 'with an account record' do subject { Fabricate(:account) } diff --git a/spec/models/preview_card_provider_spec.rb b/spec/models/preview_card_provider_spec.rb index 7425b93946..8b18b3d2b7 100644 --- a/spec/models/preview_card_provider_spec.rb +++ b/spec/models/preview_card_provider_spec.rb @@ -3,6 +3,8 @@ require 'rails_helper' describe PreviewCardProvider do + include_examples 'Reviewable' + describe 'scopes' do let(:trendable_and_reviewed) { Fabricate(:preview_card_provider, trendable: true, reviewed_at: 5.days.ago) } let(:not_trendable_and_not_reviewed) { Fabricate(:preview_card_provider, trendable: false, reviewed_at: nil) } diff --git a/spec/models/tag_spec.rb b/spec/models/tag_spec.rb index ff0a055113..18dd26be94 100644 --- a/spec/models/tag_spec.rb +++ b/spec/models/tag_spec.rb @@ -3,6 +3,8 @@ require 'rails_helper' RSpec.describe Tag do + include_examples 'Reviewable' + describe 'validations' do it 'invalid with #' do expect(described_class.new(name: '#hello_world')).to_not be_valid diff --git a/spec/support/examples/models/concerns/reviewable.rb b/spec/support/examples/models/concerns/reviewable.rb new file mode 100644 index 0000000000..562183d1cc --- /dev/null +++ b/spec/support/examples/models/concerns/reviewable.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +shared_examples 'Reviewable' do + subject { described_class.new(reviewed_at: reviewed_at, requested_review_at: requested_review_at) } + + let(:reviewed_at) { nil } + let(:requested_review_at) { nil } + + describe '#requires_review?' do + it { is_expected.to be_requires_review } + + context 'when reviewed_at is not null' do + let(:reviewed_at) { 5.days.ago } + + it { is_expected.to_not be_requires_review } + end + end + + describe '#reviewed?' do + it { is_expected.to_not be_reviewed } + + context 'when reviewed_at is not null' do + let(:reviewed_at) { 5.days.ago } + + it { is_expected.to be_reviewed } + end + end + + describe '#requested_review?' do + it { is_expected.to_not be_requested_review } + + context 'when requested_reviewed_at is not null' do + let(:requested_review_at) { 5.days.ago } + + it { is_expected.to be_requested_review } + end + end + + describe '#requires_review_notification?' do + it { is_expected.to be_requires_review_notification } + + context 'when reviewed_at is not null' do + let(:reviewed_at) { 5.days.ago } + + it { is_expected.to_not be_requires_review_notification } + end + + context 'when requested_reviewed_at is not null' do + let(:requested_review_at) { 5.days.ago } + + it { is_expected.to_not be_requires_review_notification } + end + end +end From 69dbc2303826d4a90322892f1fdf96c5ec22a948 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 11:38:38 -0400 Subject: [PATCH 073/153] Only enable chewy in search-tagged specs (#30583) --- spec/rails_helper.rb | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/spec/rails_helper.rb b/spec/rails_helper.rb index 2a602d113a..883eaec84c 100644 --- a/spec/rails_helper.rb +++ b/spec/rails_helper.rb @@ -55,6 +55,8 @@ Sidekiq.logger = nil DatabaseCleaner.strategy = [:deletion] +Chewy.settings[:enabled] = false + Devise::Test::ControllerHelpers.module_eval do alias_method :original_sign_in, :sign_in @@ -129,6 +131,12 @@ RSpec.configure do |config| example.run end + config.around(:each, type: :search) do |example| + Chewy.settings[:enabled] = true + example.run + Chewy.settings[:enabled] = false + end + config.before :each, type: :cli do stub_reset_connection_pools end From 19849eb91d1a7f8b5700abc50cbd84181666fa2c Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 11:39:19 -0400 Subject: [PATCH 074/153] Skip paperclip spoof detector unless opted into attachment processing specs (#31454) --- spec/rails_helper.rb | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/spec/rails_helper.rb b/spec/rails_helper.rb index 883eaec84c..0b24f68f73 100644 --- a/spec/rails_helper.rb +++ b/spec/rails_helper.rb @@ -147,7 +147,10 @@ RSpec.configure do |config| config.before do |example| unless example.metadata[:attachment_processing] - allow_any_instance_of(Paperclip::Attachment).to receive(:post_process).and_return(true) # rubocop:disable RSpec/AnyInstance + # rubocop:disable RSpec/AnyInstance + allow_any_instance_of(Paperclip::Attachment).to receive(:post_process).and_return(true) + allow_any_instance_of(Paperclip::MediaTypeSpoofDetector).to receive(:spoofed?).and_return(false) + # rubocop:enable RSpec/AnyInstance end end From 8adf67f2dbde0ae249ccadd8cbd2156e14932f52 Mon Sep 17 00:00:00 2001 From: Christian Schmidt Date: Tue, 3 Sep 2024 17:55:13 +0200 Subject: [PATCH 075/153] `frequentlyUsedLanguages` not updated correctly (#31386) --- app/javascript/mastodon/actions/languages.js | 12 ------------ .../compose/components/language_dropdown.jsx | 4 ---- .../containers/language_dropdown_container.js | 6 ------ app/javascript/mastodon/reducers/settings.js | 4 ++-- 4 files changed, 2 insertions(+), 24 deletions(-) delete mode 100644 app/javascript/mastodon/actions/languages.js diff --git a/app/javascript/mastodon/actions/languages.js b/app/javascript/mastodon/actions/languages.js deleted file mode 100644 index ad186ba0cc..0000000000 --- a/app/javascript/mastodon/actions/languages.js +++ /dev/null @@ -1,12 +0,0 @@ -import { saveSettings } from './settings'; - -export const LANGUAGE_USE = 'LANGUAGE_USE'; - -export const useLanguage = language => dispatch => { - dispatch({ - type: LANGUAGE_USE, - language, - }); - - dispatch(saveSettings()); -}; diff --git a/app/javascript/mastodon/features/compose/components/language_dropdown.jsx b/app/javascript/mastodon/features/compose/components/language_dropdown.jsx index 47e81cf134..b164a07cbd 100644 --- a/app/javascript/mastodon/features/compose/components/language_dropdown.jsx +++ b/app/javascript/mastodon/features/compose/components/language_dropdown.jsx @@ -240,7 +240,6 @@ class LanguageDropdown extends PureComponent { frequentlyUsedLanguages: PropTypes.arrayOf(PropTypes.string), intl: PropTypes.object.isRequired, onChange: PropTypes.func, - onClose: PropTypes.func, }; state = { @@ -257,14 +256,11 @@ class LanguageDropdown extends PureComponent { }; handleClose = () => { - const { value, onClose } = this.props; - if (this.state.open && this.activeElement) { this.activeElement.focus({ preventScroll: true }); } this.setState({ open: false }); - onClose(value); }; handleChange = value => { diff --git a/app/javascript/mastodon/features/compose/containers/language_dropdown_container.js b/app/javascript/mastodon/features/compose/containers/language_dropdown_container.js index ba4b5f05a5..64c90afa92 100644 --- a/app/javascript/mastodon/features/compose/containers/language_dropdown_container.js +++ b/app/javascript/mastodon/features/compose/containers/language_dropdown_container.js @@ -4,7 +4,6 @@ import { connect } from 'react-redux'; import { changeComposeLanguage } from 'mastodon/actions/compose'; -import { useLanguage } from 'mastodon/actions/languages'; import LanguageDropdown from '../components/language_dropdown'; @@ -28,11 +27,6 @@ const mapDispatchToProps = dispatch => ({ dispatch(changeComposeLanguage(value)); }, - onClose (value) { - // eslint-disable-next-line react-hooks/rules-of-hooks -- this is not a react hook - dispatch(useLanguage(value)); - }, - }); export default connect(mapStateToProps, mapDispatchToProps)(LanguageDropdown); diff --git a/app/javascript/mastodon/reducers/settings.js b/app/javascript/mastodon/reducers/settings.js index 6f55241dc1..e5ff2ff910 100644 --- a/app/javascript/mastodon/reducers/settings.js +++ b/app/javascript/mastodon/reducers/settings.js @@ -1,8 +1,8 @@ import { Map as ImmutableMap, fromJS } from 'immutable'; import { COLUMN_ADD, COLUMN_REMOVE, COLUMN_MOVE, COLUMN_PARAMS_CHANGE } from '../actions/columns'; +import { COMPOSE_LANGUAGE_CHANGE } from '../actions/compose'; import { EMOJI_USE } from '../actions/emojis'; -import { LANGUAGE_USE } from '../actions/languages'; import { LIST_DELETE_SUCCESS, LIST_FETCH_FAIL } from '../actions/lists'; import { NOTIFICATIONS_FILTER_SET } from '../actions/notifications'; import { SETTING_CHANGE, SETTING_SAVE } from '../actions/settings'; @@ -175,7 +175,7 @@ export default function settings(state = initialState, action) { return changeColumnParams(state, action.uuid, action.path, action.value); case EMOJI_USE: return updateFrequentEmojis(state, action.emoji); - case LANGUAGE_USE: + case COMPOSE_LANGUAGE_CHANGE: return updateFrequentLanguages(state, action.language); case SETTING_SAVE: return state.set('saved', true); From 8c928faff3b9de1087b5cf983fd0e575bd2181dc Mon Sep 17 00:00:00 2001 From: zunda Date: Tue, 3 Sep 2024 16:03:00 +0000 Subject: [PATCH 076/153] Refresh Heroku related thingy for heroku-24 stack (#31135) --- .profile | 1 - Aptfile | 10 +++++----- Procfile | 2 +- app.json | 9 ++++++++- 4 files changed, 14 insertions(+), 8 deletions(-) delete mode 100644 .profile diff --git a/.profile b/.profile deleted file mode 100644 index f4826ea303..0000000000 --- a/.profile +++ /dev/null @@ -1 +0,0 @@ -LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/app/.apt/lib/x86_64-linux-gnu:/app/.apt/usr/lib/x86_64-linux-gnu/mesa:/app/.apt/usr/lib/x86_64-linux-gnu/pulseaudio:/app/.apt/usr/lib/x86_64-linux-gnu/openblas-pthread diff --git a/Aptfile b/Aptfile index 5e033f1365..06c91d4c7b 100644 --- a/Aptfile +++ b/Aptfile @@ -1,5 +1,5 @@ -ffmpeg -libopenblas0-pthread -libpq-dev -libxdamage1 -libxfixes3 +libidn12 +# for idn-ruby on heroku-24 stack + +# use https://github.com/heroku/heroku-buildpack-activestorage-preview +# in place for ffmpeg and its dependent packages to reduce slag size diff --git a/Procfile b/Procfile index d15c835b86..f033fd36c6 100644 --- a/Procfile +++ b/Procfile @@ -11,4 +11,4 @@ worker: bundle exec sidekiq # # and let the main app use the separate app: # -# heroku config:set STREAMING_API_BASE_URL=wss://.herokuapp.com -a +# heroku config:set STREAMING_API_BASE_URL=wss://.herokuapp.com -a diff --git a/app.json b/app.json index 4f05a64f51..5e5a3dc1e7 100644 --- a/app.json +++ b/app.json @@ -90,9 +90,15 @@ } }, "buildpacks": [ + { + "url": "https://github.com/heroku/heroku-buildpack-activestorage-preview" + }, { "url": "https://github.com/heroku/heroku-buildpack-apt" }, + { + "url": "heroku/nodejs" + }, { "url": "heroku/ruby" } @@ -100,5 +106,6 @@ "scripts": { "postdeploy": "bundle exec rails db:migrate && bundle exec rails db:seed" }, - "addons": ["heroku-postgresql", "heroku-redis"] + "addons": ["heroku-postgresql", "heroku-redis"], + "stack": "heroku-24" } From c9ea91f8683cd5c0cfac14071a17e3956ac6d3b0 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 3 Sep 2024 12:10:48 -0400 Subject: [PATCH 077/153] Add coverage for `api/v1/annual_reports` area (#31730) --- .../generated_annual_report_fabricator.rb | 8 +++ spec/requests/api/v1/annual_reports_spec.rb | 57 +++++++++++++++++++ 2 files changed, 65 insertions(+) create mode 100644 spec/fabricators/generated_annual_report_fabricator.rb create mode 100644 spec/requests/api/v1/annual_reports_spec.rb diff --git a/spec/fabricators/generated_annual_report_fabricator.rb b/spec/fabricators/generated_annual_report_fabricator.rb new file mode 100644 index 0000000000..462d0cf4bc --- /dev/null +++ b/spec/fabricators/generated_annual_report_fabricator.rb @@ -0,0 +1,8 @@ +# frozen_string_literal: true + +Fabricator(:generated_annual_report) do + account { Fabricate.build(:account) } + data { { test: :data } } + schema_version { AnnualReport::SCHEMA } + year { sequence(:year) { |i| 2000 + i } } +end diff --git a/spec/requests/api/v1/annual_reports_spec.rb b/spec/requests/api/v1/annual_reports_spec.rb new file mode 100644 index 0000000000..60cd8ed526 --- /dev/null +++ b/spec/requests/api/v1/annual_reports_spec.rb @@ -0,0 +1,57 @@ +# frozen_string_literal: true + +require 'rails_helper' + +describe 'API V1 Annual Reports' do + let(:user) { Fabricate(:user) } + let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } + let(:headers) { { 'Authorization' => "Bearer #{token.token}" } } + + describe 'GET /api/v1/annual_reports' do + context 'when not authorized' do + it 'returns http unauthorized' do + get api_v1_annual_reports_path + + expect(response) + .to have_http_status(401) + end + end + + context 'with wrong scope' do + before do + get api_v1_annual_reports_path, headers: headers + end + + it_behaves_like 'forbidden for wrong scope', 'write write:accounts' + end + + context 'with correct scope' do + let(:scopes) { 'read:accounts' } + + it 'returns http success' do + get api_v1_annual_reports_path, headers: headers + + expect(response) + .to have_http_status(200) + + expect(body_as_json) + .to be_present + end + end + end + + describe 'POST /api/v1/annual_reports/:id/read' do + context 'with correct scope' do + let(:scopes) { 'write:accounts' } + + it 'returns success and marks the report as read' do + annual_report = Fabricate :generated_annual_report, account: user.account + + expect { post read_api_v1_annual_report_path(id: annual_report.year), headers: headers } + .to change { annual_report.reload.viewed? }.to(true) + expect(response) + .to have_http_status(200) + end + end + end +end From 663cebbe3b47942b695ad2be8b576539c8b83874 Mon Sep 17 00:00:00 2001 From: Claire Date: Tue, 3 Sep 2024 13:37:09 +0200 Subject: [PATCH 078/153] [Glitch] Fix radio buttons styling in web UI Port 0437dd9e770c293ec4f16d0513d1d5dd65209406 to glitch-soc Signed-off-by: Claire --- app/javascript/flavours/glitch/styles/components.scss | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/javascript/flavours/glitch/styles/components.scss b/app/javascript/flavours/glitch/styles/components.scss index ca841b5e47..26be1f866c 100644 --- a/app/javascript/flavours/glitch/styles/components.scss +++ b/app/javascript/flavours/glitch/styles/components.scss @@ -8112,7 +8112,7 @@ img.modal-warning { } } -.radio-button.checked::before { +.radio-button__input.checked::before { position: absolute; left: 2px; top: 2px; From 8e3c47aff5327c52ce92b4821cf4bb54ece5d441 Mon Sep 17 00:00:00 2001 From: Christian Schmidt Date: Tue, 3 Sep 2024 17:55:13 +0200 Subject: [PATCH 079/153] [Glitch] `frequentlyUsedLanguages` not updated correctly Port 8adf67f2dbde0ae249ccadd8cbd2156e14932f52 to glitch-soc Signed-off-by: Claire --- app/javascript/flavours/glitch/actions/languages.js | 12 ------------ .../compose/components/language_dropdown.jsx | 4 ---- .../containers/language_dropdown_container.js | 6 ------ app/javascript/flavours/glitch/reducers/settings.js | 4 ++-- 4 files changed, 2 insertions(+), 24 deletions(-) delete mode 100644 app/javascript/flavours/glitch/actions/languages.js diff --git a/app/javascript/flavours/glitch/actions/languages.js b/app/javascript/flavours/glitch/actions/languages.js deleted file mode 100644 index ad186ba0cc..0000000000 --- a/app/javascript/flavours/glitch/actions/languages.js +++ /dev/null @@ -1,12 +0,0 @@ -import { saveSettings } from './settings'; - -export const LANGUAGE_USE = 'LANGUAGE_USE'; - -export const useLanguage = language => dispatch => { - dispatch({ - type: LANGUAGE_USE, - language, - }); - - dispatch(saveSettings()); -}; diff --git a/app/javascript/flavours/glitch/features/compose/components/language_dropdown.jsx b/app/javascript/flavours/glitch/features/compose/components/language_dropdown.jsx index 1ad9e03040..a2efa0d500 100644 --- a/app/javascript/flavours/glitch/features/compose/components/language_dropdown.jsx +++ b/app/javascript/flavours/glitch/features/compose/components/language_dropdown.jsx @@ -240,7 +240,6 @@ class LanguageDropdown extends PureComponent { frequentlyUsedLanguages: PropTypes.arrayOf(PropTypes.string), intl: PropTypes.object.isRequired, onChange: PropTypes.func, - onClose: PropTypes.func, }; state = { @@ -257,14 +256,11 @@ class LanguageDropdown extends PureComponent { }; handleClose = () => { - const { value, onClose } = this.props; - if (this.state.open && this.activeElement) { this.activeElement.focus({ preventScroll: true }); } this.setState({ open: false }); - onClose(value); }; handleChange = value => { diff --git a/app/javascript/flavours/glitch/features/compose/containers/language_dropdown_container.js b/app/javascript/flavours/glitch/features/compose/containers/language_dropdown_container.js index 9388cb0059..7d1b1e8d42 100644 --- a/app/javascript/flavours/glitch/features/compose/containers/language_dropdown_container.js +++ b/app/javascript/flavours/glitch/features/compose/containers/language_dropdown_container.js @@ -4,7 +4,6 @@ import { connect } from 'react-redux'; import { changeComposeLanguage } from 'flavours/glitch/actions/compose'; -import { useLanguage } from 'flavours/glitch/actions/languages'; import LanguageDropdown from '../components/language_dropdown'; @@ -28,11 +27,6 @@ const mapDispatchToProps = dispatch => ({ dispatch(changeComposeLanguage(value)); }, - onClose (value) { - // eslint-disable-next-line react-hooks/rules-of-hooks -- this is not a react hook - dispatch(useLanguage(value)); - }, - }); export default connect(mapStateToProps, mapDispatchToProps)(LanguageDropdown); diff --git a/app/javascript/flavours/glitch/reducers/settings.js b/app/javascript/flavours/glitch/reducers/settings.js index ff4af68752..660b5f11ca 100644 --- a/app/javascript/flavours/glitch/reducers/settings.js +++ b/app/javascript/flavours/glitch/reducers/settings.js @@ -1,8 +1,8 @@ import { Map as ImmutableMap, fromJS } from 'immutable'; import { COLUMN_ADD, COLUMN_REMOVE, COLUMN_MOVE, COLUMN_PARAMS_CHANGE } from '../actions/columns'; +import { COMPOSE_LANGUAGE_CHANGE } from '../actions/compose'; import { EMOJI_USE } from '../actions/emojis'; -import { LANGUAGE_USE } from '../actions/languages'; import { LIST_DELETE_SUCCESS, LIST_FETCH_FAIL } from '../actions/lists'; import { NOTIFICATIONS_FILTER_SET } from '../actions/notifications'; import { SETTING_CHANGE, SETTING_SAVE } from '../actions/settings'; @@ -182,7 +182,7 @@ export default function settings(state = initialState, action) { return changeColumnParams(state, action.uuid, action.path, action.value); case EMOJI_USE: return updateFrequentEmojis(state, action.emoji); - case LANGUAGE_USE: + case COMPOSE_LANGUAGE_CHANGE: return updateFrequentLanguages(state, action.language); case SETTING_SAVE: return state.set('saved', true); From f1003b256055e7eaf5d81cc95c370fc1ab82dfde Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Wed, 4 Sep 2024 01:12:25 -0400 Subject: [PATCH 080/153] Enable "zero monkey patching" mode in RSpec (#31614) --- spec/chewy/accounts_index_spec.rb | 2 +- spec/chewy/public_statuses_index_spec.rb | 2 +- spec/chewy/statuses_index_spec.rb | 2 +- spec/chewy/tags_index_spec.rb | 2 +- spec/config/initializers/rack/attack_spec.rb | 2 +- spec/controllers/activitypub/claims_controller_spec.rb | 2 +- spec/controllers/admin/account_actions_controller_spec.rb | 2 +- spec/controllers/admin/action_logs_controller_spec.rb | 2 +- spec/controllers/admin/base_controller_spec.rb | 2 +- spec/controllers/admin/custom_emojis_controller_spec.rb | 2 +- spec/controllers/admin/dashboard_controller_spec.rb | 2 +- .../admin/follow_recommendations_controller_spec.rb | 2 +- spec/controllers/admin/invites_controller_spec.rb | 2 +- spec/controllers/admin/ip_blocks_controller_spec.rb | 2 +- spec/controllers/admin/relationships_controller_spec.rb | 2 +- spec/controllers/admin/relays_controller_spec.rb | 2 +- spec/controllers/admin/report_notes_controller_spec.rb | 2 +- spec/controllers/admin/reports/actions_controller_spec.rb | 2 +- spec/controllers/admin/reports_controller_spec.rb | 2 +- spec/controllers/admin/roles_controller_spec.rb | 2 +- spec/controllers/admin/rules_controller_spec.rb | 2 +- spec/controllers/admin/site_uploads_controller_spec.rb | 2 +- spec/controllers/admin/statuses_controller_spec.rb | 2 +- .../trends/links/preview_card_providers_controller_spec.rb | 2 +- spec/controllers/admin/trends/links_controller_spec.rb | 2 +- spec/controllers/admin/trends/statuses_controller_spec.rb | 2 +- spec/controllers/admin/trends/tags_controller_spec.rb | 2 +- spec/controllers/admin/users/roles_controller_spec.rb | 2 +- .../admin/users/two_factor_authentications_controller_spec.rb | 2 +- spec/controllers/admin/warning_presets_controller_spec.rb | 2 +- spec/controllers/admin/webhooks/secrets_controller_spec.rb | 2 +- spec/controllers/admin/webhooks_controller_spec.rb | 2 +- spec/controllers/api/base_controller_spec.rb | 2 +- .../controllers/api/web/push_subscriptions_controller_spec.rb | 2 +- spec/controllers/application_controller_spec.rb | 2 +- spec/controllers/auth/challenges_controller_spec.rb | 2 +- spec/controllers/auth/confirmations_controller_spec.rb | 2 +- spec/controllers/auth/passwords_controller_spec.rb | 2 +- spec/controllers/auth/setup_controller_spec.rb | 2 +- spec/controllers/authorize_interactions_controller_spec.rb | 2 +- spec/controllers/concerns/account_controller_concern_spec.rb | 2 +- spec/controllers/concerns/api/error_handling_spec.rb | 2 +- spec/controllers/concerns/api/rate_limit_headers_spec.rb | 2 +- spec/controllers/concerns/localized_spec.rb | 2 +- .../concerns/settings/export_controller_concern_spec.rb | 2 +- spec/controllers/concerns/user_tracking_concern_spec.rb | 2 +- spec/controllers/filters/statuses_controller_spec.rb | 2 +- spec/controllers/filters_controller_spec.rb | 2 +- spec/controllers/follower_accounts_controller_spec.rb | 2 +- spec/controllers/following_accounts_controller_spec.rb | 2 +- spec/controllers/invites_controller_spec.rb | 2 +- .../oauth/authorized_applications_controller_spec.rb | 2 +- spec/controllers/relationships_controller_spec.rb | 2 +- spec/controllers/settings/aliases_controller_spec.rb | 2 +- spec/controllers/settings/applications_controller_spec.rb | 2 +- spec/controllers/settings/deletes_controller_spec.rb | 2 +- spec/controllers/settings/exports_controller_spec.rb | 2 +- spec/controllers/settings/featured_tags_controller_spec.rb | 2 +- spec/controllers/settings/login_activities_controller_spec.rb | 2 +- .../settings/migration/redirects_controller_spec.rb | 2 +- spec/controllers/settings/migrations_controller_spec.rb | 2 +- spec/controllers/settings/pictures_controller_spec.rb | 2 +- .../settings/preferences/appearance_controller_spec.rb | 2 +- spec/controllers/settings/preferences/base_controller_spec.rb | 2 +- .../settings/preferences/notifications_controller_spec.rb | 2 +- .../controllers/settings/preferences/other_controller_spec.rb | 2 +- spec/controllers/settings/sessions_controller_spec.rb | 2 +- .../confirmations_controller_spec.rb | 2 +- .../otp_authentication_controller_spec.rb | 2 +- .../recovery_codes_controller_spec.rb | 2 +- .../webauthn_credentials_controller_spec.rb | 2 +- .../two_factor_authentication_methods_controller_spec.rb | 2 +- spec/controllers/statuses_controller_spec.rb | 2 +- spec/fabrication/fabricators_spec.rb | 2 +- spec/generators/post_deployment_migration_generator_spec.rb | 2 +- spec/helpers/admin/dashboard_helper_spec.rb | 2 +- spec/helpers/admin/disputes_helper_spec.rb | 2 +- spec/helpers/admin/filter_helper_spec.rb | 2 +- spec/helpers/admin/trends/statuses_helper_spec.rb | 2 +- spec/helpers/application_helper_spec.rb | 2 +- spec/helpers/flashes_helper_spec.rb | 2 +- spec/helpers/formatting_helper_spec.rb | 2 +- spec/helpers/instance_helper_spec.rb | 2 +- spec/helpers/json_ld_helper_spec.rb | 2 +- spec/helpers/languages_helper_spec.rb | 2 +- spec/helpers/media_component_helper_spec.rb | 2 +- spec/helpers/react_component_helper_spec.rb | 2 +- spec/helpers/settings_helper_spec.rb | 2 +- spec/helpers/statuses_helper_spec.rb | 2 +- spec/helpers/theme_helper_spec.rb | 2 +- .../metrics/dimension/instance_accounts_dimension_spec.rb | 2 +- .../metrics/dimension/instance_languages_dimension_spec.rb | 2 +- spec/lib/admin/metrics/dimension/languages_dimension_spec.rb | 2 +- spec/lib/admin/metrics/dimension/servers_dimension_spec.rb | 2 +- .../metrics/dimension/software_versions_dimension_spec.rb | 2 +- spec/lib/admin/metrics/dimension/sources_dimension_spec.rb | 2 +- .../lib/admin/metrics/dimension/space_usage_dimension_spec.rb | 2 +- .../admin/metrics/dimension/tag_languages_dimension_spec.rb | 2 +- .../lib/admin/metrics/dimension/tag_servers_dimension_spec.rb | 2 +- spec/lib/admin/metrics/dimension_spec.rb | 2 +- spec/lib/admin/metrics/measure/active_users_measure_spec.rb | 2 +- .../admin/metrics/measure/instance_accounts_measure_spec.rb | 2 +- .../admin/metrics/measure/instance_followers_measure_spec.rb | 2 +- .../admin/metrics/measure/instance_follows_measure_spec.rb | 2 +- .../measure/instance_media_attachments_measure_spec.rb | 2 +- .../admin/metrics/measure/instance_reports_measure_spec.rb | 2 +- .../admin/metrics/measure/instance_statuses_measure_spec.rb | 2 +- spec/lib/admin/metrics/measure/interactions_measure_spec.rb | 2 +- spec/lib/admin/metrics/measure/new_users_measure_spec.rb | 2 +- spec/lib/admin/metrics/measure/opened_reports_measure_spec.rb | 2 +- .../admin/metrics/measure/resolved_reports_measure_spec.rb | 2 +- spec/lib/admin/metrics/measure/tag_accounts_measure_spec.rb | 2 +- spec/lib/admin/metrics/measure/tag_servers_measure_spec.rb | 2 +- spec/lib/admin/metrics/measure/tag_uses_measure_spec.rb | 2 +- spec/lib/admin/metrics/measure_spec.rb | 2 +- spec/lib/admin/system_check/base_check_spec.rb | 2 +- spec/lib/admin/system_check/database_schema_check_spec.rb | 2 +- spec/lib/admin/system_check/elasticsearch_check_spec.rb | 2 +- spec/lib/admin/system_check/media_privacy_check_spec.rb | 2 +- spec/lib/admin/system_check/message_spec.rb | 2 +- spec/lib/admin/system_check/rules_check_spec.rb | 2 +- spec/lib/admin/system_check/sidekiq_process_check_spec.rb | 2 +- spec/lib/admin/system_check/software_version_check_spec.rb | 2 +- spec/lib/admin/system_check_spec.rb | 2 +- spec/lib/annual_report_spec.rb | 2 +- spec/lib/cache_buster_spec.rb | 2 +- spec/lib/connection_pool/shared_connection_pool_spec.rb | 2 +- spec/lib/connection_pool/shared_timed_stack_spec.rb | 2 +- spec/lib/content_security_policy_spec.rb | 2 +- spec/lib/delivery_failure_tracker_spec.rb | 2 +- spec/lib/extractor_spec.rb | 2 +- spec/lib/fast_ip_map_spec.rb | 2 +- spec/lib/hashtag_normalizer_spec.rb | 2 +- spec/lib/importer/accounts_index_importer_spec.rb | 2 +- spec/lib/importer/base_importer_spec.rb | 2 +- spec/lib/importer/public_statuses_index_importer_spec.rb | 2 +- spec/lib/importer/statuses_index_importer_spec.rb | 2 +- spec/lib/importer/tags_index_importer_spec.rb | 2 +- spec/lib/mastodon/cli/accounts_spec.rb | 2 +- spec/lib/mastodon/cli/cache_spec.rb | 2 +- spec/lib/mastodon/cli/canonical_email_blocks_spec.rb | 2 +- spec/lib/mastodon/cli/domains_spec.rb | 2 +- spec/lib/mastodon/cli/email_domain_blocks_spec.rb | 2 +- spec/lib/mastodon/cli/emoji_spec.rb | 2 +- spec/lib/mastodon/cli/feeds_spec.rb | 2 +- spec/lib/mastodon/cli/ip_blocks_spec.rb | 2 +- spec/lib/mastodon/cli/main_spec.rb | 2 +- spec/lib/mastodon/cli/maintenance_spec.rb | 2 +- spec/lib/mastodon/cli/media_spec.rb | 2 +- spec/lib/mastodon/cli/preview_cards_spec.rb | 2 +- spec/lib/mastodon/cli/search_spec.rb | 2 +- spec/lib/mastodon/cli/settings_spec.rb | 2 +- spec/lib/mastodon/cli/statuses_spec.rb | 2 +- spec/lib/mastodon/cli/upgrade_spec.rb | 2 +- spec/lib/mastodon/migration_warning_spec.rb | 2 +- spec/lib/ostatus/tag_manager_spec.rb | 2 +- spec/lib/paperclip/response_with_limit_adapter_spec.rb | 2 +- spec/lib/permalink_redirector_spec.rb | 2 +- spec/lib/request_pool_spec.rb | 2 +- spec/lib/request_spec.rb | 2 +- spec/lib/sanitize/config_spec.rb | 2 +- spec/lib/scope_transformer_spec.rb | 2 +- spec/lib/search_query_parser_spec.rb | 2 +- spec/lib/search_query_transformer_spec.rb | 2 +- spec/lib/status_cache_hydrator_spec.rb | 2 +- spec/lib/status_filter_spec.rb | 2 +- spec/lib/status_finder_spec.rb | 2 +- spec/lib/status_reach_finder_spec.rb | 2 +- spec/lib/webfinger_resource_spec.rb | 2 +- spec/lib/webhooks/payload_renderer_spec.rb | 2 +- spec/locales/i18n_spec.rb | 2 +- spec/mailers/user_mailer_spec.rb | 2 +- spec/models/account_filter_spec.rb | 2 +- spec/models/account_warning_preset_spec.rb | 2 +- spec/models/admin/appeal_filter_spec.rb | 2 +- spec/models/admin/tag_filter_spec.rb | 2 +- spec/models/announcement_spec.rb | 2 +- spec/models/appeal_spec.rb | 2 +- spec/models/concerns/account/counters_spec.rb | 2 +- spec/models/concerns/account/finder_concern_spec.rb | 2 +- spec/models/concerns/account/interactions_spec.rb | 2 +- spec/models/concerns/account/statuses_search_spec.rb | 2 +- spec/models/concerns/status/threading_concern_spec.rb | 2 +- spec/models/custom_emoji_category_spec.rb | 2 +- spec/models/domain_allow_spec.rb | 2 +- spec/models/export_spec.rb | 2 +- spec/models/extended_description_spec.rb | 2 +- spec/models/form/admin_settings_spec.rb | 2 +- spec/models/form/custom_emoji_batch_spec.rb | 2 +- spec/models/form/status_filter_batch_action_spec.rb | 2 +- spec/models/ip_block_spec.rb | 2 +- spec/models/marker_spec.rb | 2 +- spec/models/one_time_key_spec.rb | 2 +- spec/models/poll_spec.rb | 2 +- spec/models/preview_card_provider_spec.rb | 2 +- spec/models/preview_card_spec.rb | 2 +- spec/models/privacy_policy_spec.rb | 2 +- spec/models/relationship_filter_spec.rb | 2 +- spec/models/report_filter_spec.rb | 2 +- spec/models/report_spec.rb | 2 +- spec/models/rule_spec.rb | 2 +- spec/models/status_edit_spec.rb | 2 +- spec/models/tag_feed_spec.rb | 2 +- spec/policies/account_warning_preset_policy_spec.rb | 2 +- spec/policies/admin/status_policy_spec.rb | 2 +- spec/policies/announcement_policy_spec.rb | 2 +- spec/policies/appeal_policy_spec.rb | 2 +- spec/policies/canonical_email_block_policy_spec.rb | 2 +- spec/policies/delivery_policy_spec.rb | 2 +- spec/policies/follow_recommendation_policy_spec.rb | 2 +- spec/policies/ip_block_policy_spec.rb | 2 +- spec/policies/preview_card_policy_spec.rb | 2 +- spec/policies/preview_card_provider_policy_spec.rb | 2 +- spec/policies/rule_policy_spec.rb | 2 +- spec/policies/webhook_policy_spec.rb | 2 +- spec/presenters/instance_presenter_spec.rb | 2 +- spec/requests/account_show_page_spec.rb | 2 +- spec/requests/accounts_spec.rb | 2 +- spec/requests/anonymous_cookies_spec.rb | 2 +- spec/requests/api/v1/accounts/familiar_followers_spec.rb | 2 +- spec/requests/api/v1/accounts/follower_accounts_spec.rb | 2 +- spec/requests/api/v1/accounts/following_accounts_spec.rb | 2 +- spec/requests/api/v1/accounts/identity_proofs_spec.rb | 2 +- spec/requests/api/v1/accounts/lists_spec.rb | 2 +- spec/requests/api/v1/accounts/lookup_spec.rb | 2 +- spec/requests/api/v1/accounts/notes_spec.rb | 2 +- spec/requests/api/v1/accounts/pins_spec.rb | 2 +- spec/requests/api/v1/accounts/relationships_spec.rb | 2 +- spec/requests/api/v1/accounts/search_spec.rb | 2 +- spec/requests/api/v1/accounts/statuses_spec.rb | 2 +- spec/requests/api/v1/accounts_spec.rb | 2 +- spec/requests/api/v1/admin/dimensions_spec.rb | 2 +- spec/requests/api/v1/admin/measures_spec.rb | 2 +- spec/requests/api/v1/admin/retention_spec.rb | 2 +- spec/requests/api/v1/admin/trends/links/links_spec.rb | 2 +- .../api/v1/admin/trends/links/preview_card_providers_spec.rb | 2 +- spec/requests/api/v1/admin/trends/statuses_spec.rb | 2 +- spec/requests/api/v1/admin/trends/tags_spec.rb | 2 +- spec/requests/api/v1/annual_reports_spec.rb | 2 +- spec/requests/api/v1/apps/credentials_spec.rb | 2 +- spec/requests/api/v1/csp_spec.rb | 2 +- spec/requests/api/v1/custom_emojis_spec.rb | 2 +- spec/requests/api/v1/directories_spec.rb | 2 +- spec/requests/api/v1/endorsements_spec.rb | 2 +- spec/requests/api/v1/featured_tags/suggestions_spec.rb | 2 +- spec/requests/api/v1/instance_spec.rb | 2 +- spec/requests/api/v1/instances/translation_languages_spec.rb | 2 +- spec/requests/api/v1/peers/search_spec.rb | 2 +- spec/requests/api/v1/preferences_spec.rb | 2 +- spec/requests/api/v1/push/subscriptions_spec.rb | 2 +- spec/requests/api/v1/scheduled_status_spec.rb | 2 +- spec/requests/api/v1/statuses/histories_spec.rb | 2 +- spec/requests/api/v1/statuses/mutes_spec.rb | 2 +- spec/requests/api/v1/statuses/pins_spec.rb | 2 +- spec/requests/api/v1/statuses/reblogs_spec.rb | 2 +- spec/requests/api/v1/statuses/translations_spec.rb | 2 +- spec/requests/api/v1/statuses_spec.rb | 2 +- spec/requests/api/v1/streaming_spec.rb | 2 +- spec/requests/api/v1/timelines/home_spec.rb | 2 +- spec/requests/api/v1/timelines/link_spec.rb | 2 +- spec/requests/api/v1/timelines/list_spec.rb | 2 +- spec/requests/api/v1/timelines/public_spec.rb | 2 +- spec/requests/api/v2/instance_spec.rb | 2 +- spec/requests/api/v2/search_spec.rb | 2 +- spec/requests/api/v2/suggestions_spec.rb | 2 +- spec/requests/backups_spec.rb | 2 +- spec/requests/cache_spec.rb | 2 +- spec/requests/catch_all_route_request_spec.rb | 2 +- spec/requests/content_security_policy_spec.rb | 2 +- spec/requests/custom_css_spec.rb | 2 +- spec/requests/custom_stylesheets_spec.rb | 2 +- spec/requests/disabled_oauth_endpoints_spec.rb | 2 +- spec/requests/emojis_spec.rb | 2 +- spec/requests/health_spec.rb | 2 +- spec/requests/invite_spec.rb | 2 +- spec/requests/link_headers_spec.rb | 2 +- spec/requests/localization_spec.rb | 2 +- spec/requests/log_out_spec.rb | 2 +- spec/requests/manifest_spec.rb | 2 +- spec/requests/media_proxy_spec.rb | 2 +- spec/requests/omniauth_callbacks_spec.rb | 2 +- spec/requests/remote_interaction_helper_spec.rb | 2 +- spec/requests/self_destruct_spec.rb | 2 +- spec/requests/settings/exports/blocked_accounts_spec.rb | 2 +- spec/requests/settings/exports/blocked_domains_spec.rb | 2 +- spec/requests/settings/exports/bookmarks_spec.rb | 2 +- spec/requests/settings/exports/following_accounts_spec.rb | 2 +- spec/requests/settings/exports/lists_spec.rb | 2 +- spec/requests/settings/exports/muted_accounts_spec.rb | 2 +- spec/requests/signature_verification_spec.rb | 2 +- spec/requests/well_known/change_password_spec.rb | 2 +- spec/requests/well_known/host_meta_spec.rb | 2 +- spec/requests/well_known/node_info_spec.rb | 2 +- spec/requests/well_known/oauth_metadata_spec.rb | 2 +- spec/requests/well_known/webfinger_spec.rb | 2 +- spec/routing/accounts_routing_spec.rb | 2 +- spec/routing/api_routing_spec.rb | 2 +- spec/routing/well_known_routes_spec.rb | 2 +- spec/search/models/concerns/account/search_spec.rb | 2 +- spec/search/models/concerns/account/statuses_search_spec.rb | 2 +- spec/serializers/activitypub/device_serializer_spec.rb | 2 +- spec/serializers/activitypub/note_serializer_spec.rb | 2 +- spec/serializers/activitypub/one_time_key_serializer_spec.rb | 2 +- spec/serializers/activitypub/undo_like_serializer_spec.rb | 2 +- spec/serializers/activitypub/update_poll_serializer_spec.rb | 2 +- spec/serializers/activitypub/vote_serializer_spec.rb | 2 +- spec/serializers/rest/account_serializer_spec.rb | 2 +- spec/serializers/rest/encrypted_message_serializer_spec.rb | 2 +- spec/serializers/rest/instance_serializer_spec.rb | 2 +- spec/serializers/rest/keys/claim_result_serializer_spec.rb | 2 +- spec/serializers/rest/keys/device_serializer_spec.rb | 2 +- spec/serializers/rest/keys/query_result_serializer_spec.rb | 2 +- spec/serializers/rest/suggestion_serializer_spec.rb | 2 +- spec/services/account_search_service_spec.rb | 2 +- spec/services/account_statuses_cleanup_service_spec.rb | 2 +- spec/services/fetch_oembed_service_spec.rb | 2 +- spec/services/resolve_url_service_spec.rb | 2 +- spec/services/search_service_spec.rb | 2 +- spec/services/unblock_domain_service_spec.rb | 2 +- spec/spec_helper.rb | 2 ++ spec/support/examples/api.rb | 4 ++-- spec/support/examples/cli.rb | 2 +- spec/support/examples/lib/admin/checks.rb | 2 +- spec/support/examples/mailers.rb | 2 +- spec/support/examples/models/concerns/account_avatar.rb | 2 +- spec/support/examples/models/concerns/account_header.rb | 2 +- spec/support/examples/models/concerns/reviewable.rb | 2 +- spec/system/about_spec.rb | 2 +- spec/system/admin/accounts_spec.rb | 2 +- spec/system/admin/announcements_spec.rb | 2 +- spec/system/admin/custom_emojis_spec.rb | 2 +- spec/system/admin/domain_blocks_spec.rb | 2 +- spec/system/admin/email_domain_blocks_spec.rb | 2 +- spec/system/admin/ip_blocks_spec.rb | 2 +- spec/system/admin/reset_spec.rb | 2 +- spec/system/admin/settings/about_spec.rb | 2 +- spec/system/admin/settings/appearance_spec.rb | 2 +- spec/system/admin/settings/branding_spec.rb | 2 +- spec/system/admin/settings/content_retention_spec.rb | 2 +- spec/system/admin/settings/discovery_spec.rb | 2 +- spec/system/admin/settings/registrations_spec.rb | 2 +- spec/system/admin/software_updates_spec.rb | 2 +- spec/system/admin/statuses_spec.rb | 2 +- spec/system/admin/trends/links/preview_card_providers_spec.rb | 2 +- spec/system/admin/trends/links_spec.rb | 2 +- spec/system/admin/trends/statuses_spec.rb | 2 +- spec/system/admin/trends/tags_spec.rb | 2 +- spec/system/captcha_spec.rb | 2 +- spec/system/filters_spec.rb | 2 +- spec/system/home_spec.rb | 2 +- spec/system/log_in_spec.rb | 2 +- spec/system/log_out_spec.rb | 2 +- spec/system/new_statuses_spec.rb | 2 +- spec/system/oauth_spec.rb | 2 +- spec/system/ocr_spec.rb | 2 +- spec/system/privacy_spec.rb | 2 +- spec/system/profile_spec.rb | 2 +- spec/system/redirections_spec.rb | 2 +- spec/system/report_interface_spec.rb | 2 +- spec/system/severed_relationships_spec.rb | 2 +- spec/system/share_entrypoint_spec.rb | 2 +- spec/system/unlogged_spec.rb | 2 +- spec/validators/email_mx_validator_spec.rb | 2 +- spec/validators/existing_username_validator_spec.rb | 2 +- spec/validators/language_validator_spec.rb | 2 +- spec/validators/note_length_validator_spec.rb | 2 +- spec/validators/reaction_validator_spec.rb | 2 +- spec/validators/status_length_validator_spec.rb | 2 +- spec/validators/unique_username_validator_spec.rb | 2 +- spec/validators/unreserved_username_validator_spec.rb | 2 +- spec/validators/url_validator_spec.rb | 2 +- spec/views/admin/trends/links/_preview_card.html.haml_spec.rb | 2 +- spec/views/statuses/show.html.haml_spec.rb | 2 +- spec/workers/account_refresh_worker_spec.rb | 2 +- spec/workers/activitypub/delivery_worker_spec.rb | 2 +- .../workers/activitypub/distribute_poll_update_worker_spec.rb | 2 +- spec/workers/activitypub/distribution_worker_spec.rb | 2 +- spec/workers/activitypub/fetch_replies_worker_spec.rb | 2 +- spec/workers/activitypub/move_distribution_worker_spec.rb | 2 +- spec/workers/activitypub/post_upgrade_worker_spec.rb | 2 +- spec/workers/activitypub/processing_worker_spec.rb | 2 +- .../activitypub/status_update_distribution_worker_spec.rb | 2 +- .../synchronize_featured_tags_collection_worker_spec.rb | 2 +- spec/workers/activitypub/update_distribution_worker_spec.rb | 2 +- spec/workers/add_to_public_statuses_index_worker_spec.rb | 2 +- spec/workers/admin/account_deletion_worker_spec.rb | 2 +- spec/workers/admin/domain_purge_worker_spec.rb | 2 +- spec/workers/admin/suspension_worker_spec.rb | 2 +- spec/workers/after_account_domain_block_worker_spec.rb | 2 +- spec/workers/backup_worker_spec.rb | 2 +- spec/workers/bulk_import_worker_spec.rb | 2 +- spec/workers/cache_buster_worker_spec.rb | 2 +- spec/workers/delete_mute_worker_spec.rb | 2 +- spec/workers/domain_block_worker_spec.rb | 2 +- spec/workers/domain_clear_media_worker_spec.rb | 2 +- spec/workers/feed_insert_worker_spec.rb | 2 +- spec/workers/filtered_notification_cleanup_worker_spec.rb | 2 +- spec/workers/import/row_worker_spec.rb | 2 +- spec/workers/import_worker_spec.rb | 2 +- spec/workers/move_worker_spec.rb | 2 +- spec/workers/poll_expiration_notify_worker_spec.rb | 2 +- spec/workers/post_process_media_worker_spec.rb | 2 +- spec/workers/publish_announcement_reaction_worker_spec.rb | 2 +- spec/workers/publish_scheduled_announcement_worker_spec.rb | 2 +- spec/workers/publish_scheduled_status_worker_spec.rb | 2 +- spec/workers/push_conversation_worker_spec.rb | 2 +- spec/workers/push_encrypted_message_worker_spec.rb | 2 +- spec/workers/push_update_worker_spec.rb | 2 +- spec/workers/redownload_avatar_worker_spec.rb | 2 +- spec/workers/redownload_header_worker_spec.rb | 2 +- spec/workers/redownload_media_worker_spec.rb | 2 +- spec/workers/refollow_worker_spec.rb | 2 +- spec/workers/regeneration_worker_spec.rb | 2 +- spec/workers/removal_worker_spec.rb | 2 +- spec/workers/remove_featured_tag_worker_spec.rb | 2 +- spec/workers/remove_from_public_statuses_index_worker_spec.rb | 2 +- spec/workers/resolve_account_worker_spec.rb | 2 +- .../scheduler/accounts_statuses_cleanup_scheduler_spec.rb | 2 +- .../scheduler/auto_close_registrations_scheduler_spec.rb | 2 +- .../scheduler/follow_recommendations_scheduler_spec.rb | 2 +- spec/workers/scheduler/indexing_scheduler_spec.rb | 2 +- spec/workers/scheduler/instance_refresh_scheduler_spec.rb | 2 +- spec/workers/scheduler/ip_cleanup_scheduler_spec.rb | 2 +- spec/workers/scheduler/pghero_scheduler_spec.rb | 2 +- spec/workers/scheduler/scheduled_statuses_scheduler_spec.rb | 2 +- spec/workers/scheduler/self_destruct_scheduler_spec.rb | 2 +- .../workers/scheduler/software_update_check_scheduler_spec.rb | 2 +- .../scheduler/suspended_user_cleanup_scheduler_spec.rb | 2 +- spec/workers/scheduler/trends/refresh_scheduler_spec.rb | 2 +- .../scheduler/trends/review_notifications_scheduler_spec.rb | 2 +- spec/workers/scheduler/user_cleanup_scheduler_spec.rb | 2 +- spec/workers/scheduler/vacuum_scheduler_spec.rb | 2 +- spec/workers/tag_unmerge_worker_spec.rb | 2 +- spec/workers/unfilter_notifications_worker_spec.rb | 2 +- spec/workers/unfollow_follow_worker_spec.rb | 2 +- spec/workers/unpublish_announcement_worker_spec.rb | 2 +- spec/workers/verify_account_links_worker_spec.rb | 2 +- spec/workers/web/push_notification_worker_spec.rb | 2 +- spec/workers/webhooks/delivery_worker_spec.rb | 2 +- 439 files changed, 441 insertions(+), 439 deletions(-) diff --git a/spec/chewy/accounts_index_spec.rb b/spec/chewy/accounts_index_spec.rb index f9c5922c76..f7b5b2e249 100644 --- a/spec/chewy/accounts_index_spec.rb +++ b/spec/chewy/accounts_index_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe AccountsIndex do +RSpec.describe AccountsIndex do describe 'Searching the index' do before do mock_elasticsearch_response(described_class, raw_response) diff --git a/spec/chewy/public_statuses_index_spec.rb b/spec/chewy/public_statuses_index_spec.rb index 2f93d0ff02..6bc08832f3 100644 --- a/spec/chewy/public_statuses_index_spec.rb +++ b/spec/chewy/public_statuses_index_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe PublicStatusesIndex do +RSpec.describe PublicStatusesIndex do describe 'Searching the index' do before do mock_elasticsearch_response(described_class, raw_response) diff --git a/spec/chewy/statuses_index_spec.rb b/spec/chewy/statuses_index_spec.rb index 768e9415fc..e3899f3a17 100644 --- a/spec/chewy/statuses_index_spec.rb +++ b/spec/chewy/statuses_index_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe StatusesIndex do +RSpec.describe StatusesIndex do describe 'Searching the index' do before do mock_elasticsearch_response(described_class, raw_response) diff --git a/spec/chewy/tags_index_spec.rb b/spec/chewy/tags_index_spec.rb index 054589bdfb..6b57da65e4 100644 --- a/spec/chewy/tags_index_spec.rb +++ b/spec/chewy/tags_index_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe TagsIndex do +RSpec.describe TagsIndex do describe 'Searching the index' do before do mock_elasticsearch_response(described_class, raw_response) diff --git a/spec/config/initializers/rack/attack_spec.rb b/spec/config/initializers/rack/attack_spec.rb index 19de480898..c7af11bea7 100644 --- a/spec/config/initializers/rack/attack_spec.rb +++ b/spec/config/initializers/rack/attack_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Rack::Attack, type: :request do +RSpec.describe Rack::Attack, type: :request do def app Rails.application end diff --git a/spec/controllers/activitypub/claims_controller_spec.rb b/spec/controllers/activitypub/claims_controller_spec.rb index f00eeb732a..e887be2cbe 100644 --- a/spec/controllers/activitypub/claims_controller_spec.rb +++ b/spec/controllers/activitypub/claims_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ActivityPub::ClaimsController do +RSpec.describe ActivityPub::ClaimsController do let(:account) { Fabricate(:account) } describe 'POST #create' do diff --git a/spec/controllers/admin/account_actions_controller_spec.rb b/spec/controllers/admin/account_actions_controller_spec.rb index b8dae79939..d513b3d4a0 100644 --- a/spec/controllers/admin/account_actions_controller_spec.rb +++ b/spec/controllers/admin/account_actions_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::AccountActionsController do +RSpec.describe Admin::AccountActionsController do render_views let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } diff --git a/spec/controllers/admin/action_logs_controller_spec.rb b/spec/controllers/admin/action_logs_controller_spec.rb index be4222df08..3daf260672 100644 --- a/spec/controllers/admin/action_logs_controller_spec.rb +++ b/spec/controllers/admin/action_logs_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::ActionLogsController do +RSpec.describe Admin::ActionLogsController do render_views # Action logs typically cause issues when their targets are not in the database diff --git a/spec/controllers/admin/base_controller_spec.rb b/spec/controllers/admin/base_controller_spec.rb index 1f1fa8441a..8b8b7fe63d 100644 --- a/spec/controllers/admin/base_controller_spec.rb +++ b/spec/controllers/admin/base_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::BaseController do +RSpec.describe Admin::BaseController do controller do def success authorize :dashboard, :index? diff --git a/spec/controllers/admin/custom_emojis_controller_spec.rb b/spec/controllers/admin/custom_emojis_controller_spec.rb index 9e732200dd..57c2a6d21b 100644 --- a/spec/controllers/admin/custom_emojis_controller_spec.rb +++ b/spec/controllers/admin/custom_emojis_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::CustomEmojisController do +RSpec.describe Admin::CustomEmojisController do render_views let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } diff --git a/spec/controllers/admin/dashboard_controller_spec.rb b/spec/controllers/admin/dashboard_controller_spec.rb index 3e29ce1278..9177be4b6d 100644 --- a/spec/controllers/admin/dashboard_controller_spec.rb +++ b/spec/controllers/admin/dashboard_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::DashboardController do +RSpec.describe Admin::DashboardController do render_views describe 'GET #index' do diff --git a/spec/controllers/admin/follow_recommendations_controller_spec.rb b/spec/controllers/admin/follow_recommendations_controller_spec.rb index f62aa6e4b2..d614f2ef43 100644 --- a/spec/controllers/admin/follow_recommendations_controller_spec.rb +++ b/spec/controllers/admin/follow_recommendations_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::FollowRecommendationsController do +RSpec.describe Admin::FollowRecommendationsController do render_views let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } diff --git a/spec/controllers/admin/invites_controller_spec.rb b/spec/controllers/admin/invites_controller_spec.rb index 8638f8e214..b6471e80b2 100644 --- a/spec/controllers/admin/invites_controller_spec.rb +++ b/spec/controllers/admin/invites_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::InvitesController do +RSpec.describe Admin::InvitesController do render_views let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } diff --git a/spec/controllers/admin/ip_blocks_controller_spec.rb b/spec/controllers/admin/ip_blocks_controller_spec.rb index 05190f1340..2e32db5a01 100644 --- a/spec/controllers/admin/ip_blocks_controller_spec.rb +++ b/spec/controllers/admin/ip_blocks_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::IpBlocksController do +RSpec.describe Admin::IpBlocksController do render_views let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } diff --git a/spec/controllers/admin/relationships_controller_spec.rb b/spec/controllers/admin/relationships_controller_spec.rb index 1099a37a3b..214be7c7cd 100644 --- a/spec/controllers/admin/relationships_controller_spec.rb +++ b/spec/controllers/admin/relationships_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::RelationshipsController do +RSpec.describe Admin::RelationshipsController do render_views let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } diff --git a/spec/controllers/admin/relays_controller_spec.rb b/spec/controllers/admin/relays_controller_spec.rb index ca351c39b2..c6251a6d76 100644 --- a/spec/controllers/admin/relays_controller_spec.rb +++ b/spec/controllers/admin/relays_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::RelaysController do +RSpec.describe Admin::RelaysController do render_views let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } diff --git a/spec/controllers/admin/report_notes_controller_spec.rb b/spec/controllers/admin/report_notes_controller_spec.rb index 8d5b5c7aec..423a64ebc4 100644 --- a/spec/controllers/admin/report_notes_controller_spec.rb +++ b/spec/controllers/admin/report_notes_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::ReportNotesController do +RSpec.describe Admin::ReportNotesController do render_views let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } diff --git a/spec/controllers/admin/reports/actions_controller_spec.rb b/spec/controllers/admin/reports/actions_controller_spec.rb index 06d4b31f54..6185702c30 100644 --- a/spec/controllers/admin/reports/actions_controller_spec.rb +++ b/spec/controllers/admin/reports/actions_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Reports::ActionsController do +RSpec.describe Admin::Reports::ActionsController do render_views let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } diff --git a/spec/controllers/admin/reports_controller_spec.rb b/spec/controllers/admin/reports_controller_spec.rb index 67fb28e7a5..d07468a37b 100644 --- a/spec/controllers/admin/reports_controller_spec.rb +++ b/spec/controllers/admin/reports_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::ReportsController do +RSpec.describe Admin::ReportsController do render_views let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } diff --git a/spec/controllers/admin/roles_controller_spec.rb b/spec/controllers/admin/roles_controller_spec.rb index 223d0a472a..2c43a0ca87 100644 --- a/spec/controllers/admin/roles_controller_spec.rb +++ b/spec/controllers/admin/roles_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::RolesController do +RSpec.describe Admin::RolesController do render_views let(:permissions) { UserRole::Flags::NONE } diff --git a/spec/controllers/admin/rules_controller_spec.rb b/spec/controllers/admin/rules_controller_spec.rb index 92ffb41567..1b2a2010d0 100644 --- a/spec/controllers/admin/rules_controller_spec.rb +++ b/spec/controllers/admin/rules_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::RulesController do +RSpec.describe Admin::RulesController do render_views let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } diff --git a/spec/controllers/admin/site_uploads_controller_spec.rb b/spec/controllers/admin/site_uploads_controller_spec.rb index 4ea37f396a..9c65c63b78 100644 --- a/spec/controllers/admin/site_uploads_controller_spec.rb +++ b/spec/controllers/admin/site_uploads_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::SiteUploadsController do +RSpec.describe Admin::SiteUploadsController do render_views let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } diff --git a/spec/controllers/admin/statuses_controller_spec.rb b/spec/controllers/admin/statuses_controller_spec.rb index 4ab6d109ef..e6053a6e8a 100644 --- a/spec/controllers/admin/statuses_controller_spec.rb +++ b/spec/controllers/admin/statuses_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::StatusesController do +RSpec.describe Admin::StatusesController do render_views let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } diff --git a/spec/controllers/admin/trends/links/preview_card_providers_controller_spec.rb b/spec/controllers/admin/trends/links/preview_card_providers_controller_spec.rb index 95ed38d6b1..ce62a13db6 100644 --- a/spec/controllers/admin/trends/links/preview_card_providers_controller_spec.rb +++ b/spec/controllers/admin/trends/links/preview_card_providers_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Trends::Links::PreviewCardProvidersController do +RSpec.describe Admin::Trends::Links::PreviewCardProvidersController do render_views let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } diff --git a/spec/controllers/admin/trends/links_controller_spec.rb b/spec/controllers/admin/trends/links_controller_spec.rb index 7c67f5e5aa..984f3007c2 100644 --- a/spec/controllers/admin/trends/links_controller_spec.rb +++ b/spec/controllers/admin/trends/links_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Trends::LinksController do +RSpec.describe Admin::Trends::LinksController do render_views let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } diff --git a/spec/controllers/admin/trends/statuses_controller_spec.rb b/spec/controllers/admin/trends/statuses_controller_spec.rb index b752234d3c..eecf4ab4f2 100644 --- a/spec/controllers/admin/trends/statuses_controller_spec.rb +++ b/spec/controllers/admin/trends/statuses_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Trends::StatusesController do +RSpec.describe Admin::Trends::StatusesController do render_views let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } diff --git a/spec/controllers/admin/trends/tags_controller_spec.rb b/spec/controllers/admin/trends/tags_controller_spec.rb index 4f74a55455..51ad1860c8 100644 --- a/spec/controllers/admin/trends/tags_controller_spec.rb +++ b/spec/controllers/admin/trends/tags_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Trends::TagsController do +RSpec.describe Admin::Trends::TagsController do render_views let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } diff --git a/spec/controllers/admin/users/roles_controller_spec.rb b/spec/controllers/admin/users/roles_controller_spec.rb index 97f69a0b0a..bfc2bb151f 100644 --- a/spec/controllers/admin/users/roles_controller_spec.rb +++ b/spec/controllers/admin/users/roles_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Users::RolesController do +RSpec.describe Admin::Users::RolesController do render_views let(:current_role) { UserRole.create(name: 'Foo', permissions: UserRole::FLAGS[:manage_roles], position: 10) } diff --git a/spec/controllers/admin/users/two_factor_authentications_controller_spec.rb b/spec/controllers/admin/users/two_factor_authentications_controller_spec.rb index eb10d47963..1f0a6ac34d 100644 --- a/spec/controllers/admin/users/two_factor_authentications_controller_spec.rb +++ b/spec/controllers/admin/users/two_factor_authentications_controller_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'webauthn/fake_client' -describe Admin::Users::TwoFactorAuthenticationsController do +RSpec.describe Admin::Users::TwoFactorAuthenticationsController do render_views let(:user) { Fabricate(:user) } diff --git a/spec/controllers/admin/warning_presets_controller_spec.rb b/spec/controllers/admin/warning_presets_controller_spec.rb index b32a58e990..4171bbad82 100644 --- a/spec/controllers/admin/warning_presets_controller_spec.rb +++ b/spec/controllers/admin/warning_presets_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::WarningPresetsController do +RSpec.describe Admin::WarningPresetsController do render_views let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } diff --git a/spec/controllers/admin/webhooks/secrets_controller_spec.rb b/spec/controllers/admin/webhooks/secrets_controller_spec.rb index 291a10fba5..61ae8cdaa5 100644 --- a/spec/controllers/admin/webhooks/secrets_controller_spec.rb +++ b/spec/controllers/admin/webhooks/secrets_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Webhooks::SecretsController do +RSpec.describe Admin::Webhooks::SecretsController do render_views let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } diff --git a/spec/controllers/admin/webhooks_controller_spec.rb b/spec/controllers/admin/webhooks_controller_spec.rb index 17d8506025..4fe787c26c 100644 --- a/spec/controllers/admin/webhooks_controller_spec.rb +++ b/spec/controllers/admin/webhooks_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::WebhooksController do +RSpec.describe Admin::WebhooksController do render_views let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } diff --git a/spec/controllers/api/base_controller_spec.rb b/spec/controllers/api/base_controller_spec.rb index 659d55f801..1e0e7c8f4d 100644 --- a/spec/controllers/api/base_controller_spec.rb +++ b/spec/controllers/api/base_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Api::BaseController do +RSpec.describe Api::BaseController do controller do def success head 200 diff --git a/spec/controllers/api/web/push_subscriptions_controller_spec.rb b/spec/controllers/api/web/push_subscriptions_controller_spec.rb index 58677841ca..acc0312113 100644 --- a/spec/controllers/api/web/push_subscriptions_controller_spec.rb +++ b/spec/controllers/api/web/push_subscriptions_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Api::Web::PushSubscriptionsController do +RSpec.describe Api::Web::PushSubscriptionsController do render_views let(:user) { Fabricate(:user) } diff --git a/spec/controllers/application_controller_spec.rb b/spec/controllers/application_controller_spec.rb index f595e8ca19..4ee951628e 100644 --- a/spec/controllers/application_controller_spec.rb +++ b/spec/controllers/application_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ApplicationController do +RSpec.describe ApplicationController do controller do def success head 200 diff --git a/spec/controllers/auth/challenges_controller_spec.rb b/spec/controllers/auth/challenges_controller_spec.rb index 32bbedde63..56fdfa61b5 100644 --- a/spec/controllers/auth/challenges_controller_spec.rb +++ b/spec/controllers/auth/challenges_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Auth::ChallengesController do +RSpec.describe Auth::ChallengesController do render_views let(:password) { 'foobar12345' } diff --git a/spec/controllers/auth/confirmations_controller_spec.rb b/spec/controllers/auth/confirmations_controller_spec.rb index 15403e8ea1..a5b212e660 100644 --- a/spec/controllers/auth/confirmations_controller_spec.rb +++ b/spec/controllers/auth/confirmations_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Auth::ConfirmationsController do +RSpec.describe Auth::ConfirmationsController do render_views describe 'GET #new' do diff --git a/spec/controllers/auth/passwords_controller_spec.rb b/spec/controllers/auth/passwords_controller_spec.rb index d70490abcf..9ccbb9e494 100644 --- a/spec/controllers/auth/passwords_controller_spec.rb +++ b/spec/controllers/auth/passwords_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Auth::PasswordsController do +RSpec.describe Auth::PasswordsController do include Devise::Test::ControllerHelpers describe 'GET #new' do diff --git a/spec/controllers/auth/setup_controller_spec.rb b/spec/controllers/auth/setup_controller_spec.rb index 75e42aaf96..28b07cb4b2 100644 --- a/spec/controllers/auth/setup_controller_spec.rb +++ b/spec/controllers/auth/setup_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Auth::SetupController do +RSpec.describe Auth::SetupController do render_views describe 'GET #show' do diff --git a/spec/controllers/authorize_interactions_controller_spec.rb b/spec/controllers/authorize_interactions_controller_spec.rb index ed55df08d9..2a0422efa9 100644 --- a/spec/controllers/authorize_interactions_controller_spec.rb +++ b/spec/controllers/authorize_interactions_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe AuthorizeInteractionsController do +RSpec.describe AuthorizeInteractionsController do render_views describe 'GET #show' do diff --git a/spec/controllers/concerns/account_controller_concern_spec.rb b/spec/controllers/concerns/account_controller_concern_spec.rb index 122ef21e93..3eee46d7b9 100644 --- a/spec/controllers/concerns/account_controller_concern_spec.rb +++ b/spec/controllers/concerns/account_controller_concern_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe AccountControllerConcern do +RSpec.describe AccountControllerConcern do controller(ApplicationController) do include AccountControllerConcern diff --git a/spec/controllers/concerns/api/error_handling_spec.rb b/spec/controllers/concerns/api/error_handling_spec.rb index 9b36fc20a3..eff01605d2 100644 --- a/spec/controllers/concerns/api/error_handling_spec.rb +++ b/spec/controllers/concerns/api/error_handling_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Api::ErrorHandling do +RSpec.describe Api::ErrorHandling do before do stub_const('FakeService', Class.new) end diff --git a/spec/controllers/concerns/api/rate_limit_headers_spec.rb b/spec/controllers/concerns/api/rate_limit_headers_spec.rb index 2050de2aed..6372c94e6c 100644 --- a/spec/controllers/concerns/api/rate_limit_headers_spec.rb +++ b/spec/controllers/concerns/api/rate_limit_headers_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Api::RateLimitHeaders do +RSpec.describe Api::RateLimitHeaders do controller(ApplicationController) do include Api::RateLimitHeaders diff --git a/spec/controllers/concerns/localized_spec.rb b/spec/controllers/concerns/localized_spec.rb index ce31e786f0..b1f805ae50 100644 --- a/spec/controllers/concerns/localized_spec.rb +++ b/spec/controllers/concerns/localized_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Localized do +RSpec.describe Localized do controller(ApplicationController) do include Localized diff --git a/spec/controllers/concerns/settings/export_controller_concern_spec.rb b/spec/controllers/concerns/settings/export_controller_concern_spec.rb index a19af8689a..2c67991e3a 100644 --- a/spec/controllers/concerns/settings/export_controller_concern_spec.rb +++ b/spec/controllers/concerns/settings/export_controller_concern_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Settings::ExportControllerConcern do +RSpec.describe Settings::ExportControllerConcern do controller(ApplicationController) do include Settings::ExportControllerConcern diff --git a/spec/controllers/concerns/user_tracking_concern_spec.rb b/spec/controllers/concerns/user_tracking_concern_spec.rb index f23d482f5f..cc61e285cc 100644 --- a/spec/controllers/concerns/user_tracking_concern_spec.rb +++ b/spec/controllers/concerns/user_tracking_concern_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe UserTrackingConcern do +RSpec.describe UserTrackingConcern do controller(ApplicationController) do include UserTrackingConcern diff --git a/spec/controllers/filters/statuses_controller_spec.rb b/spec/controllers/filters/statuses_controller_spec.rb index 2c80613302..f1fed76fca 100644 --- a/spec/controllers/filters/statuses_controller_spec.rb +++ b/spec/controllers/filters/statuses_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Filters::StatusesController do +RSpec.describe Filters::StatusesController do render_views describe 'GET #index' do diff --git a/spec/controllers/filters_controller_spec.rb b/spec/controllers/filters_controller_spec.rb index 091f714bb3..de043e8ae3 100644 --- a/spec/controllers/filters_controller_spec.rb +++ b/spec/controllers/filters_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe FiltersController do +RSpec.describe FiltersController do render_views describe 'GET #index' do diff --git a/spec/controllers/follower_accounts_controller_spec.rb b/spec/controllers/follower_accounts_controller_spec.rb index dd78c96c05..e84528d13e 100644 --- a/spec/controllers/follower_accounts_controller_spec.rb +++ b/spec/controllers/follower_accounts_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe FollowerAccountsController do +RSpec.describe FollowerAccountsController do render_views let(:alice) { Fabricate(:account, username: 'alice') } diff --git a/spec/controllers/following_accounts_controller_spec.rb b/spec/controllers/following_accounts_controller_spec.rb index 7bb78fb420..1e01b9f494 100644 --- a/spec/controllers/following_accounts_controller_spec.rb +++ b/spec/controllers/following_accounts_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe FollowingAccountsController do +RSpec.describe FollowingAccountsController do render_views let(:alice) { Fabricate(:account, username: 'alice') } diff --git a/spec/controllers/invites_controller_spec.rb b/spec/controllers/invites_controller_spec.rb index 5221941267..192c5b00ba 100644 --- a/spec/controllers/invites_controller_spec.rb +++ b/spec/controllers/invites_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe InvitesController do +RSpec.describe InvitesController do render_views let(:user) { Fabricate(:user) } diff --git a/spec/controllers/oauth/authorized_applications_controller_spec.rb b/spec/controllers/oauth/authorized_applications_controller_spec.rb index 3fd9f9499f..52d3dbde83 100644 --- a/spec/controllers/oauth/authorized_applications_controller_spec.rb +++ b/spec/controllers/oauth/authorized_applications_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Oauth::AuthorizedApplicationsController do +RSpec.describe Oauth::AuthorizedApplicationsController do render_views describe 'GET #index' do diff --git a/spec/controllers/relationships_controller_spec.rb b/spec/controllers/relationships_controller_spec.rb index 9495fc214f..323fcc995d 100644 --- a/spec/controllers/relationships_controller_spec.rb +++ b/spec/controllers/relationships_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe RelationshipsController do +RSpec.describe RelationshipsController do render_views let(:user) { Fabricate(:user) } diff --git a/spec/controllers/settings/aliases_controller_spec.rb b/spec/controllers/settings/aliases_controller_spec.rb index 18e568be0b..4858c15298 100644 --- a/spec/controllers/settings/aliases_controller_spec.rb +++ b/spec/controllers/settings/aliases_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Settings::AliasesController do +RSpec.describe Settings::AliasesController do render_views let!(:user) { Fabricate(:user) } diff --git a/spec/controllers/settings/applications_controller_spec.rb b/spec/controllers/settings/applications_controller_spec.rb index ce2e0749a7..721741bacb 100644 --- a/spec/controllers/settings/applications_controller_spec.rb +++ b/spec/controllers/settings/applications_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Settings::ApplicationsController do +RSpec.describe Settings::ApplicationsController do render_views let!(:user) { Fabricate(:user) } diff --git a/spec/controllers/settings/deletes_controller_spec.rb b/spec/controllers/settings/deletes_controller_spec.rb index 3342599bc1..98104b8454 100644 --- a/spec/controllers/settings/deletes_controller_spec.rb +++ b/spec/controllers/settings/deletes_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Settings::DeletesController do +RSpec.describe Settings::DeletesController do render_views describe 'GET #show' do diff --git a/spec/controllers/settings/exports_controller_spec.rb b/spec/controllers/settings/exports_controller_spec.rb index 3399f78ac5..1eafabc7e5 100644 --- a/spec/controllers/settings/exports_controller_spec.rb +++ b/spec/controllers/settings/exports_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Settings::ExportsController do +RSpec.describe Settings::ExportsController do render_views describe 'GET #show' do diff --git a/spec/controllers/settings/featured_tags_controller_spec.rb b/spec/controllers/settings/featured_tags_controller_spec.rb index 4e1dd52945..a56ae1c498 100644 --- a/spec/controllers/settings/featured_tags_controller_spec.rb +++ b/spec/controllers/settings/featured_tags_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Settings::FeaturedTagsController do +RSpec.describe Settings::FeaturedTagsController do render_views shared_examples 'authenticate user' do diff --git a/spec/controllers/settings/login_activities_controller_spec.rb b/spec/controllers/settings/login_activities_controller_spec.rb index 294bf85c97..3447620abb 100644 --- a/spec/controllers/settings/login_activities_controller_spec.rb +++ b/spec/controllers/settings/login_activities_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Settings::LoginActivitiesController do +RSpec.describe Settings::LoginActivitiesController do render_views let!(:user) { Fabricate(:user) } diff --git a/spec/controllers/settings/migration/redirects_controller_spec.rb b/spec/controllers/settings/migration/redirects_controller_spec.rb index b909a02668..d853fe8ae6 100644 --- a/spec/controllers/settings/migration/redirects_controller_spec.rb +++ b/spec/controllers/settings/migration/redirects_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Settings::Migration::RedirectsController do +RSpec.describe Settings::Migration::RedirectsController do render_views let!(:user) { Fabricate(:user, password: 'testtest') } diff --git a/spec/controllers/settings/migrations_controller_spec.rb b/spec/controllers/settings/migrations_controller_spec.rb index f3340574d0..93c5de0899 100644 --- a/spec/controllers/settings/migrations_controller_spec.rb +++ b/spec/controllers/settings/migrations_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Settings::MigrationsController do +RSpec.describe Settings::MigrationsController do render_views shared_examples 'authenticate user' do diff --git a/spec/controllers/settings/pictures_controller_spec.rb b/spec/controllers/settings/pictures_controller_spec.rb index 705878f03d..683d231ed1 100644 --- a/spec/controllers/settings/pictures_controller_spec.rb +++ b/spec/controllers/settings/pictures_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Settings::PicturesController do +RSpec.describe Settings::PicturesController do render_views let!(:user) { Fabricate(:user) } diff --git a/spec/controllers/settings/preferences/appearance_controller_spec.rb b/spec/controllers/settings/preferences/appearance_controller_spec.rb index 84b8277250..14f9b244ab 100644 --- a/spec/controllers/settings/preferences/appearance_controller_spec.rb +++ b/spec/controllers/settings/preferences/appearance_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Settings::Preferences::AppearanceController do +RSpec.describe Settings::Preferences::AppearanceController do render_views let!(:user) { Fabricate(:user) } diff --git a/spec/controllers/settings/preferences/base_controller_spec.rb b/spec/controllers/settings/preferences/base_controller_spec.rb index 53b3a461ed..75fc999a48 100644 --- a/spec/controllers/settings/preferences/base_controller_spec.rb +++ b/spec/controllers/settings/preferences/base_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Settings::Preferences::BaseController do +RSpec.describe Settings::Preferences::BaseController do describe 'after_update_redirect_path' do it 'raises error when called' do expect { described_class.new.send(:after_update_redirect_path) }.to raise_error(/Override/) diff --git a/spec/controllers/settings/preferences/notifications_controller_spec.rb b/spec/controllers/settings/preferences/notifications_controller_spec.rb index e0f0bc55a7..edfdea50e0 100644 --- a/spec/controllers/settings/preferences/notifications_controller_spec.rb +++ b/spec/controllers/settings/preferences/notifications_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Settings::Preferences::NotificationsController do +RSpec.describe Settings::Preferences::NotificationsController do render_views let(:user) { Fabricate(:user) } diff --git a/spec/controllers/settings/preferences/other_controller_spec.rb b/spec/controllers/settings/preferences/other_controller_spec.rb index 61a94a4142..117fdeea7c 100644 --- a/spec/controllers/settings/preferences/other_controller_spec.rb +++ b/spec/controllers/settings/preferences/other_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Settings::Preferences::OtherController do +RSpec.describe Settings::Preferences::OtherController do render_views let(:user) { Fabricate(:user, chosen_languages: []) } diff --git a/spec/controllers/settings/sessions_controller_spec.rb b/spec/controllers/settings/sessions_controller_spec.rb index a4248e1bde..c098af7485 100644 --- a/spec/controllers/settings/sessions_controller_spec.rb +++ b/spec/controllers/settings/sessions_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Settings::SessionsController do +RSpec.describe Settings::SessionsController do render_views let(:user) { Fabricate(:user) } diff --git a/spec/controllers/settings/two_factor_authentication/confirmations_controller_spec.rb b/spec/controllers/settings/two_factor_authentication/confirmations_controller_spec.rb index 1c8b483a0a..34eaacdf49 100644 --- a/spec/controllers/settings/two_factor_authentication/confirmations_controller_spec.rb +++ b/spec/controllers/settings/two_factor_authentication/confirmations_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Settings::TwoFactorAuthentication::ConfirmationsController do +RSpec.describe Settings::TwoFactorAuthentication::ConfirmationsController do render_views shared_examples 'renders :new' do diff --git a/spec/controllers/settings/two_factor_authentication/otp_authentication_controller_spec.rb b/spec/controllers/settings/two_factor_authentication/otp_authentication_controller_spec.rb index 007df87d95..a03c4a4adb 100644 --- a/spec/controllers/settings/two_factor_authentication/otp_authentication_controller_spec.rb +++ b/spec/controllers/settings/two_factor_authentication/otp_authentication_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Settings::TwoFactorAuthentication::OtpAuthenticationController do +RSpec.describe Settings::TwoFactorAuthentication::OtpAuthenticationController do render_views let(:user) { Fabricate(:user) } diff --git a/spec/controllers/settings/two_factor_authentication/recovery_codes_controller_spec.rb b/spec/controllers/settings/two_factor_authentication/recovery_codes_controller_spec.rb index dbc2e3059c..0defc52cde 100644 --- a/spec/controllers/settings/two_factor_authentication/recovery_codes_controller_spec.rb +++ b/spec/controllers/settings/two_factor_authentication/recovery_codes_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Settings::TwoFactorAuthentication::RecoveryCodesController do +RSpec.describe Settings::TwoFactorAuthentication::RecoveryCodesController do render_views describe 'POST #create' do diff --git a/spec/controllers/settings/two_factor_authentication/webauthn_credentials_controller_spec.rb b/spec/controllers/settings/two_factor_authentication/webauthn_credentials_controller_spec.rb index 41a3ba5eb5..cccf3c51d3 100644 --- a/spec/controllers/settings/two_factor_authentication/webauthn_credentials_controller_spec.rb +++ b/spec/controllers/settings/two_factor_authentication/webauthn_credentials_controller_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'webauthn/fake_client' -describe Settings::TwoFactorAuthentication::WebauthnCredentialsController do +RSpec.describe Settings::TwoFactorAuthentication::WebauthnCredentialsController do render_views let(:user) { Fabricate(:user) } diff --git a/spec/controllers/settings/two_factor_authentication_methods_controller_spec.rb b/spec/controllers/settings/two_factor_authentication_methods_controller_spec.rb index de0d28463b..c55f113d4d 100644 --- a/spec/controllers/settings/two_factor_authentication_methods_controller_spec.rb +++ b/spec/controllers/settings/two_factor_authentication_methods_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Settings::TwoFactorAuthenticationMethodsController do +RSpec.describe Settings::TwoFactorAuthenticationMethodsController do render_views context 'when not signed in' do diff --git a/spec/controllers/statuses_controller_spec.rb b/spec/controllers/statuses_controller_spec.rb index 084dcfaa75..289109a1fa 100644 --- a/spec/controllers/statuses_controller_spec.rb +++ b/spec/controllers/statuses_controller_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe StatusesController do +RSpec.describe StatusesController do render_views describe 'GET #show' do diff --git a/spec/fabrication/fabricators_spec.rb b/spec/fabrication/fabricators_spec.rb index 2cf45041a4..f7bb504543 100644 --- a/spec/fabrication/fabricators_spec.rb +++ b/spec/fabrication/fabricators_spec.rb @@ -5,7 +5,7 @@ require 'rails_helper' Fabrication.manager.load_definitions if Fabrication.manager.empty? Fabrication.manager.schematics.map(&:first).each do |factory_name| - describe "The #{factory_name} factory" do + RSpec.describe "The #{factory_name} factory" do it 'is able to create valid records' do records = Fabricate.times(2, factory_name) # Create multiple of each to uncover uniqueness issues expect(records).to all(be_valid) diff --git a/spec/generators/post_deployment_migration_generator_spec.rb b/spec/generators/post_deployment_migration_generator_spec.rb index 55e70a7917..1aa8e0915c 100644 --- a/spec/generators/post_deployment_migration_generator_spec.rb +++ b/spec/generators/post_deployment_migration_generator_spec.rb @@ -6,7 +6,7 @@ require 'rails/generators/testing/assertions' require 'generators/post_deployment_migration/post_deployment_migration_generator' -describe PostDeploymentMigrationGenerator, type: :generator do +RSpec.describe PostDeploymentMigrationGenerator, type: :generator do include Rails::Generators::Testing::Behavior include Rails::Generators::Testing::Assertions include FileUtils diff --git a/spec/helpers/admin/dashboard_helper_spec.rb b/spec/helpers/admin/dashboard_helper_spec.rb index 59062e4839..9c674fb4b9 100644 --- a/spec/helpers/admin/dashboard_helper_spec.rb +++ b/spec/helpers/admin/dashboard_helper_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::DashboardHelper do +RSpec.describe Admin::DashboardHelper do describe 'relevant_account_timestamp' do context 'with an account with older sign in' do let(:account) { Fabricate(:account) } diff --git a/spec/helpers/admin/disputes_helper_spec.rb b/spec/helpers/admin/disputes_helper_spec.rb index 5f9a85df86..a6ac021bd4 100644 --- a/spec/helpers/admin/disputes_helper_spec.rb +++ b/spec/helpers/admin/disputes_helper_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::DisputesHelper do +RSpec.describe Admin::DisputesHelper do describe 'strike_action_label' do it 'returns html describing the appeal' do adam = Account.new(username: 'Adam') diff --git a/spec/helpers/admin/filter_helper_spec.rb b/spec/helpers/admin/filter_helper_spec.rb index 40ed63239f..d07a6e1bb7 100644 --- a/spec/helpers/admin/filter_helper_spec.rb +++ b/spec/helpers/admin/filter_helper_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::FilterHelper do +RSpec.describe Admin::FilterHelper do it 'Uses filter_link_to to create filter links' do params = ActionController::Parameters.new( { test: 'test' } diff --git a/spec/helpers/admin/trends/statuses_helper_spec.rb b/spec/helpers/admin/trends/statuses_helper_spec.rb index 92caae6909..fa5c337e97 100644 --- a/spec/helpers/admin/trends/statuses_helper_spec.rb +++ b/spec/helpers/admin/trends/statuses_helper_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Trends::StatusesHelper do +RSpec.describe Admin::Trends::StatusesHelper do describe '.one_line_preview' do before do allow(helper).to receive(:current_user).and_return(Fabricate.build(:user)) diff --git a/spec/helpers/application_helper_spec.rb b/spec/helpers/application_helper_spec.rb index 0bfce6946b..c2e618c7de 100644 --- a/spec/helpers/application_helper_spec.rb +++ b/spec/helpers/application_helper_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ApplicationHelper do +RSpec.describe ApplicationHelper do describe 'body_classes' do context 'with a body class string from a controller' do before { helper.extend controller_helpers } diff --git a/spec/helpers/flashes_helper_spec.rb b/spec/helpers/flashes_helper_spec.rb index a6a3b062d7..aaef7ab144 100644 --- a/spec/helpers/flashes_helper_spec.rb +++ b/spec/helpers/flashes_helper_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe FlashesHelper do +RSpec.describe FlashesHelper do describe 'user_facing_flashes' do before do # rubocop:disable Rails/I18nLocaleTexts diff --git a/spec/helpers/formatting_helper_spec.rb b/spec/helpers/formatting_helper_spec.rb index d6e7631f66..136a609b1c 100644 --- a/spec/helpers/formatting_helper_spec.rb +++ b/spec/helpers/formatting_helper_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe FormattingHelper do +RSpec.describe FormattingHelper do include Devise::Test::ControllerHelpers describe '#rss_status_content_format' do diff --git a/spec/helpers/instance_helper_spec.rb b/spec/helpers/instance_helper_spec.rb index 9a2d884158..e7b15e6513 100644 --- a/spec/helpers/instance_helper_spec.rb +++ b/spec/helpers/instance_helper_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe InstanceHelper do +RSpec.describe InstanceHelper do describe 'site_title' do it 'Uses the Setting.site_title value when it exists' do Setting.site_title = 'New site title' diff --git a/spec/helpers/json_ld_helper_spec.rb b/spec/helpers/json_ld_helper_spec.rb index f4b849d7a1..d76c5167a7 100644 --- a/spec/helpers/json_ld_helper_spec.rb +++ b/spec/helpers/json_ld_helper_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe JsonLdHelper do +RSpec.describe JsonLdHelper do describe '#equals_or_includes?' do it 'returns true when value equals' do expect(helper.equals_or_includes?('foo', 'foo')).to be true diff --git a/spec/helpers/languages_helper_spec.rb b/spec/helpers/languages_helper_spec.rb index 99461b293b..dd9b6004d1 100644 --- a/spec/helpers/languages_helper_spec.rb +++ b/spec/helpers/languages_helper_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe LanguagesHelper do +RSpec.describe LanguagesHelper do describe 'the SUPPORTED_LOCALES constant' do it 'includes all i18n locales' do expect(Set.new(described_class::SUPPORTED_LOCALES.keys + described_class::REGIONAL_LOCALE_NAMES.keys)).to include(*I18n.available_locales) diff --git a/spec/helpers/media_component_helper_spec.rb b/spec/helpers/media_component_helper_spec.rb index af5d92769c..ec87a707cb 100644 --- a/spec/helpers/media_component_helper_spec.rb +++ b/spec/helpers/media_component_helper_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe MediaComponentHelper do +RSpec.describe MediaComponentHelper do before { helper.extend controller_helpers } describe 'render_video_component' do diff --git a/spec/helpers/react_component_helper_spec.rb b/spec/helpers/react_component_helper_spec.rb index 28208b619b..202694fbe4 100644 --- a/spec/helpers/react_component_helper_spec.rb +++ b/spec/helpers/react_component_helper_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ReactComponentHelper do +RSpec.describe ReactComponentHelper do describe 'react_component' do context 'with no block passed in' do let(:result) { helper.react_component('name', { one: :two }) } diff --git a/spec/helpers/settings_helper_spec.rb b/spec/helpers/settings_helper_spec.rb index ca447d8ce1..ecff2edbfa 100644 --- a/spec/helpers/settings_helper_spec.rb +++ b/spec/helpers/settings_helper_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe SettingsHelper do +RSpec.describe SettingsHelper do describe 'session_device_icon' do context 'with a mobile device' do let(:session) { SessionActivation.new(user_agent: 'Mozilla/5.0 (iPhone)') } diff --git a/spec/helpers/statuses_helper_spec.rb b/spec/helpers/statuses_helper_spec.rb index 66eb996f99..8809d0afae 100644 --- a/spec/helpers/statuses_helper_spec.rb +++ b/spec/helpers/statuses_helper_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe StatusesHelper do +RSpec.describe StatusesHelper do describe 'status_text_summary' do context 'with blank text' do let(:status) { Status.new(spoiler_text: '') } diff --git a/spec/helpers/theme_helper_spec.rb b/spec/helpers/theme_helper_spec.rb index c0b6380a1f..7663e59436 100644 --- a/spec/helpers/theme_helper_spec.rb +++ b/spec/helpers/theme_helper_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ThemeHelper do +RSpec.describe ThemeHelper do describe 'theme_style_tags' do let(:result) { helper.theme_style_tags(theme) } diff --git a/spec/lib/admin/metrics/dimension/instance_accounts_dimension_spec.rb b/spec/lib/admin/metrics/dimension/instance_accounts_dimension_spec.rb index 2b14e6956c..c8683afda9 100644 --- a/spec/lib/admin/metrics/dimension/instance_accounts_dimension_spec.rb +++ b/spec/lib/admin/metrics/dimension/instance_accounts_dimension_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Dimension::InstanceAccountsDimension do +RSpec.describe Admin::Metrics::Dimension::InstanceAccountsDimension do subject { described_class.new(start_at, end_at, limit, params) } let(:start_at) { 2.days.ago } diff --git a/spec/lib/admin/metrics/dimension/instance_languages_dimension_spec.rb b/spec/lib/admin/metrics/dimension/instance_languages_dimension_spec.rb index e4e9fbe2b7..c633041f9d 100644 --- a/spec/lib/admin/metrics/dimension/instance_languages_dimension_spec.rb +++ b/spec/lib/admin/metrics/dimension/instance_languages_dimension_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Dimension::InstanceLanguagesDimension do +RSpec.describe Admin::Metrics::Dimension::InstanceLanguagesDimension do subject { described_class.new(start_at, end_at, limit, params) } let(:start_at) { 2.days.ago } diff --git a/spec/lib/admin/metrics/dimension/languages_dimension_spec.rb b/spec/lib/admin/metrics/dimension/languages_dimension_spec.rb index 9d80970693..801b3d84df 100644 --- a/spec/lib/admin/metrics/dimension/languages_dimension_spec.rb +++ b/spec/lib/admin/metrics/dimension/languages_dimension_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Dimension::LanguagesDimension do +RSpec.describe Admin::Metrics::Dimension::LanguagesDimension do subject { described_class.new(start_at, end_at, limit, params) } let(:start_at) { 2.days.ago } diff --git a/spec/lib/admin/metrics/dimension/servers_dimension_spec.rb b/spec/lib/admin/metrics/dimension/servers_dimension_spec.rb index 5661441d5d..d86ccd099a 100644 --- a/spec/lib/admin/metrics/dimension/servers_dimension_spec.rb +++ b/spec/lib/admin/metrics/dimension/servers_dimension_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Dimension::ServersDimension do +RSpec.describe Admin::Metrics::Dimension::ServersDimension do subject { described_class.new(start_at, end_at, limit, params) } let(:start_at) { 2.days.ago } diff --git a/spec/lib/admin/metrics/dimension/software_versions_dimension_spec.rb b/spec/lib/admin/metrics/dimension/software_versions_dimension_spec.rb index 5d31121ab3..5b0fb902e0 100644 --- a/spec/lib/admin/metrics/dimension/software_versions_dimension_spec.rb +++ b/spec/lib/admin/metrics/dimension/software_versions_dimension_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Dimension::SoftwareVersionsDimension do +RSpec.describe Admin::Metrics::Dimension::SoftwareVersionsDimension do subject { described_class.new(start_at, end_at, limit, params) } let(:start_at) { 2.days.ago } diff --git a/spec/lib/admin/metrics/dimension/sources_dimension_spec.rb b/spec/lib/admin/metrics/dimension/sources_dimension_spec.rb index 5fa5aa8af5..ca7f716afd 100644 --- a/spec/lib/admin/metrics/dimension/sources_dimension_spec.rb +++ b/spec/lib/admin/metrics/dimension/sources_dimension_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Dimension::SourcesDimension do +RSpec.describe Admin::Metrics::Dimension::SourcesDimension do subject { described_class.new(start_at, end_at, limit, params) } let(:start_at) { 2.days.ago } diff --git a/spec/lib/admin/metrics/dimension/space_usage_dimension_spec.rb b/spec/lib/admin/metrics/dimension/space_usage_dimension_spec.rb index 96ff9c66dc..4be5ed30ee 100644 --- a/spec/lib/admin/metrics/dimension/space_usage_dimension_spec.rb +++ b/spec/lib/admin/metrics/dimension/space_usage_dimension_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Dimension::SpaceUsageDimension do +RSpec.describe Admin::Metrics::Dimension::SpaceUsageDimension do subject { described_class.new(start_at, end_at, limit, params) } let(:start_at) { 2.days.ago } diff --git a/spec/lib/admin/metrics/dimension/tag_languages_dimension_spec.rb b/spec/lib/admin/metrics/dimension/tag_languages_dimension_spec.rb index c1dfd0eaf4..166edf92b0 100644 --- a/spec/lib/admin/metrics/dimension/tag_languages_dimension_spec.rb +++ b/spec/lib/admin/metrics/dimension/tag_languages_dimension_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Dimension::TagLanguagesDimension do +RSpec.describe Admin::Metrics::Dimension::TagLanguagesDimension do subject { described_class.new(start_at, end_at, limit, params) } let(:start_at) { 2.days.ago } diff --git a/spec/lib/admin/metrics/dimension/tag_servers_dimension_spec.rb b/spec/lib/admin/metrics/dimension/tag_servers_dimension_spec.rb index 025cf1b7ec..7391b55456 100644 --- a/spec/lib/admin/metrics/dimension/tag_servers_dimension_spec.rb +++ b/spec/lib/admin/metrics/dimension/tag_servers_dimension_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Dimension::TagServersDimension do +RSpec.describe Admin::Metrics::Dimension::TagServersDimension do subject { described_class.new(start_at, end_at, limit, params) } let(:start_at) { 2.days.ago } diff --git a/spec/lib/admin/metrics/dimension_spec.rb b/spec/lib/admin/metrics/dimension_spec.rb index 109250b72b..0a52d442be 100644 --- a/spec/lib/admin/metrics/dimension_spec.rb +++ b/spec/lib/admin/metrics/dimension_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Dimension do +RSpec.describe Admin::Metrics::Dimension do describe '.retrieve' do subject { described_class.retrieve(reports, start_at, end_at, 5, params) } diff --git a/spec/lib/admin/metrics/measure/active_users_measure_spec.rb b/spec/lib/admin/metrics/measure/active_users_measure_spec.rb index 38ee14075b..653e677354 100644 --- a/spec/lib/admin/metrics/measure/active_users_measure_spec.rb +++ b/spec/lib/admin/metrics/measure/active_users_measure_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Measure::ActiveUsersMeasure do +RSpec.describe Admin::Metrics::Measure::ActiveUsersMeasure do subject { described_class.new(start_at, end_at, params) } let(:start_at) { 2.days.ago } diff --git a/spec/lib/admin/metrics/measure/instance_accounts_measure_spec.rb b/spec/lib/admin/metrics/measure/instance_accounts_measure_spec.rb index 0d2ad31c39..f974f2ca46 100644 --- a/spec/lib/admin/metrics/measure/instance_accounts_measure_spec.rb +++ b/spec/lib/admin/metrics/measure/instance_accounts_measure_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Measure::InstanceAccountsMeasure do +RSpec.describe Admin::Metrics::Measure::InstanceAccountsMeasure do subject { described_class.new(start_at, end_at, params) } let(:domain) { 'example.com' } diff --git a/spec/lib/admin/metrics/measure/instance_followers_measure_spec.rb b/spec/lib/admin/metrics/measure/instance_followers_measure_spec.rb index 27bf30d17d..643249fa4e 100644 --- a/spec/lib/admin/metrics/measure/instance_followers_measure_spec.rb +++ b/spec/lib/admin/metrics/measure/instance_followers_measure_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Measure::InstanceFollowersMeasure do +RSpec.describe Admin::Metrics::Measure::InstanceFollowersMeasure do subject { described_class.new(start_at, end_at, params) } let(:domain) { 'example.com' } diff --git a/spec/lib/admin/metrics/measure/instance_follows_measure_spec.rb b/spec/lib/admin/metrics/measure/instance_follows_measure_spec.rb index 9961ea56c4..70f5004fef 100644 --- a/spec/lib/admin/metrics/measure/instance_follows_measure_spec.rb +++ b/spec/lib/admin/metrics/measure/instance_follows_measure_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Measure::InstanceFollowsMeasure do +RSpec.describe Admin::Metrics::Measure::InstanceFollowsMeasure do subject { described_class.new(start_at, end_at, params) } let(:domain) { 'example.com' } diff --git a/spec/lib/admin/metrics/measure/instance_media_attachments_measure_spec.rb b/spec/lib/admin/metrics/measure/instance_media_attachments_measure_spec.rb index 3634450930..11f13b85bc 100644 --- a/spec/lib/admin/metrics/measure/instance_media_attachments_measure_spec.rb +++ b/spec/lib/admin/metrics/measure/instance_media_attachments_measure_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Measure::InstanceMediaAttachmentsMeasure do +RSpec.describe Admin::Metrics::Measure::InstanceMediaAttachmentsMeasure do subject { described_class.new(start_at, end_at, params) } let(:domain) { 'example.com' } diff --git a/spec/lib/admin/metrics/measure/instance_reports_measure_spec.rb b/spec/lib/admin/metrics/measure/instance_reports_measure_spec.rb index ca64049d92..62c9dec464 100644 --- a/spec/lib/admin/metrics/measure/instance_reports_measure_spec.rb +++ b/spec/lib/admin/metrics/measure/instance_reports_measure_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Measure::InstanceReportsMeasure do +RSpec.describe Admin::Metrics::Measure::InstanceReportsMeasure do subject { described_class.new(start_at, end_at, params) } let(:domain) { 'example.com' } diff --git a/spec/lib/admin/metrics/measure/instance_statuses_measure_spec.rb b/spec/lib/admin/metrics/measure/instance_statuses_measure_spec.rb index ac28658ea0..0fc903a2a8 100644 --- a/spec/lib/admin/metrics/measure/instance_statuses_measure_spec.rb +++ b/spec/lib/admin/metrics/measure/instance_statuses_measure_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Measure::InstanceStatusesMeasure do +RSpec.describe Admin::Metrics::Measure::InstanceStatusesMeasure do subject { described_class.new(start_at, end_at, params) } let(:domain) { 'example.com' } diff --git a/spec/lib/admin/metrics/measure/interactions_measure_spec.rb b/spec/lib/admin/metrics/measure/interactions_measure_spec.rb index ed333380cf..edbec2eabf 100644 --- a/spec/lib/admin/metrics/measure/interactions_measure_spec.rb +++ b/spec/lib/admin/metrics/measure/interactions_measure_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Measure::InteractionsMeasure do +RSpec.describe Admin::Metrics::Measure::InteractionsMeasure do subject { described_class.new(start_at, end_at, params) } let(:start_at) { 2.days.ago } diff --git a/spec/lib/admin/metrics/measure/new_users_measure_spec.rb b/spec/lib/admin/metrics/measure/new_users_measure_spec.rb index 085acbcede..5c03b67a18 100644 --- a/spec/lib/admin/metrics/measure/new_users_measure_spec.rb +++ b/spec/lib/admin/metrics/measure/new_users_measure_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Measure::NewUsersMeasure do +RSpec.describe Admin::Metrics::Measure::NewUsersMeasure do subject { described_class.new(start_at, end_at, params) } let(:start_at) { 2.days.ago } diff --git a/spec/lib/admin/metrics/measure/opened_reports_measure_spec.rb b/spec/lib/admin/metrics/measure/opened_reports_measure_spec.rb index d5ba78527e..f4d3a66454 100644 --- a/spec/lib/admin/metrics/measure/opened_reports_measure_spec.rb +++ b/spec/lib/admin/metrics/measure/opened_reports_measure_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Measure::OpenedReportsMeasure do +RSpec.describe Admin::Metrics::Measure::OpenedReportsMeasure do subject { described_class.new(start_at, end_at, params) } let(:start_at) { 2.days.ago } diff --git a/spec/lib/admin/metrics/measure/resolved_reports_measure_spec.rb b/spec/lib/admin/metrics/measure/resolved_reports_measure_spec.rb index f7b497590d..432dbbe796 100644 --- a/spec/lib/admin/metrics/measure/resolved_reports_measure_spec.rb +++ b/spec/lib/admin/metrics/measure/resolved_reports_measure_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Measure::ResolvedReportsMeasure do +RSpec.describe Admin::Metrics::Measure::ResolvedReportsMeasure do subject { described_class.new(start_at, end_at, params) } let(:start_at) { 2.days.ago } diff --git a/spec/lib/admin/metrics/measure/tag_accounts_measure_spec.rb b/spec/lib/admin/metrics/measure/tag_accounts_measure_spec.rb index b33ae7bb71..577b1260ff 100644 --- a/spec/lib/admin/metrics/measure/tag_accounts_measure_spec.rb +++ b/spec/lib/admin/metrics/measure/tag_accounts_measure_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Measure::TagAccountsMeasure do +RSpec.describe Admin::Metrics::Measure::TagAccountsMeasure do subject { described_class.new(start_at, end_at, params) } let!(:tag) { Fabricate(:tag) } diff --git a/spec/lib/admin/metrics/measure/tag_servers_measure_spec.rb b/spec/lib/admin/metrics/measure/tag_servers_measure_spec.rb index e1e2ced43a..42715e5adc 100644 --- a/spec/lib/admin/metrics/measure/tag_servers_measure_spec.rb +++ b/spec/lib/admin/metrics/measure/tag_servers_measure_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Measure::TagServersMeasure do +RSpec.describe Admin::Metrics::Measure::TagServersMeasure do subject { described_class.new(start_at, end_at, params) } let!(:tag) { Fabricate(:tag) } diff --git a/spec/lib/admin/metrics/measure/tag_uses_measure_spec.rb b/spec/lib/admin/metrics/measure/tag_uses_measure_spec.rb index dd66f00de0..b258455dab 100644 --- a/spec/lib/admin/metrics/measure/tag_uses_measure_spec.rb +++ b/spec/lib/admin/metrics/measure/tag_uses_measure_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Measure::TagUsesMeasure do +RSpec.describe Admin::Metrics::Measure::TagUsesMeasure do subject { described_class.new(start_at, end_at, params) } let!(:tag) { Fabricate(:tag) } diff --git a/spec/lib/admin/metrics/measure_spec.rb b/spec/lib/admin/metrics/measure_spec.rb index c9809b0f79..49a5aecc61 100644 --- a/spec/lib/admin/metrics/measure_spec.rb +++ b/spec/lib/admin/metrics/measure_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::Metrics::Measure do +RSpec.describe Admin::Metrics::Measure do describe '.retrieve' do subject { described_class.retrieve(reports, start_at, end_at, params) } diff --git a/spec/lib/admin/system_check/base_check_spec.rb b/spec/lib/admin/system_check/base_check_spec.rb index fdd9f6b6c4..769e0e1d18 100644 --- a/spec/lib/admin/system_check/base_check_spec.rb +++ b/spec/lib/admin/system_check/base_check_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::SystemCheck::BaseCheck do +RSpec.describe Admin::SystemCheck::BaseCheck do subject(:check) { described_class.new(user) } let(:user) { Fabricate(:user) } diff --git a/spec/lib/admin/system_check/database_schema_check_spec.rb b/spec/lib/admin/system_check/database_schema_check_spec.rb index db1dcb52fa..311d524956 100644 --- a/spec/lib/admin/system_check/database_schema_check_spec.rb +++ b/spec/lib/admin/system_check/database_schema_check_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::SystemCheck::DatabaseSchemaCheck do +RSpec.describe Admin::SystemCheck::DatabaseSchemaCheck do subject(:check) { described_class.new(user) } let(:user) { Fabricate(:user) } diff --git a/spec/lib/admin/system_check/elasticsearch_check_spec.rb b/spec/lib/admin/system_check/elasticsearch_check_spec.rb index 8f210579d0..05d204c453 100644 --- a/spec/lib/admin/system_check/elasticsearch_check_spec.rb +++ b/spec/lib/admin/system_check/elasticsearch_check_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::SystemCheck::ElasticsearchCheck do +RSpec.describe Admin::SystemCheck::ElasticsearchCheck do subject(:check) { described_class.new(user) } let(:user) { Fabricate(:user) } diff --git a/spec/lib/admin/system_check/media_privacy_check_spec.rb b/spec/lib/admin/system_check/media_privacy_check_spec.rb index 316bf12156..0d5bcdb3e8 100644 --- a/spec/lib/admin/system_check/media_privacy_check_spec.rb +++ b/spec/lib/admin/system_check/media_privacy_check_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::SystemCheck::MediaPrivacyCheck do +RSpec.describe Admin::SystemCheck::MediaPrivacyCheck do subject(:check) { described_class.new(user) } let(:user) { Fabricate(:user) } diff --git a/spec/lib/admin/system_check/message_spec.rb b/spec/lib/admin/system_check/message_spec.rb index c0671f3452..81ef4f2f09 100644 --- a/spec/lib/admin/system_check/message_spec.rb +++ b/spec/lib/admin/system_check/message_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::SystemCheck::Message do +RSpec.describe Admin::SystemCheck::Message do subject(:check) { described_class.new(:key_value, :value_value, :action_value, :critical_value) } it 'providers readers when initialized' do diff --git a/spec/lib/admin/system_check/rules_check_spec.rb b/spec/lib/admin/system_check/rules_check_spec.rb index fb3293fb2d..32650d9cd8 100644 --- a/spec/lib/admin/system_check/rules_check_spec.rb +++ b/spec/lib/admin/system_check/rules_check_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::SystemCheck::RulesCheck do +RSpec.describe Admin::SystemCheck::RulesCheck do subject(:check) { described_class.new(user) } let(:user) { Fabricate(:user) } diff --git a/spec/lib/admin/system_check/sidekiq_process_check_spec.rb b/spec/lib/admin/system_check/sidekiq_process_check_spec.rb index 9bd9daddf6..992fd7aee0 100644 --- a/spec/lib/admin/system_check/sidekiq_process_check_spec.rb +++ b/spec/lib/admin/system_check/sidekiq_process_check_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::SystemCheck::SidekiqProcessCheck do +RSpec.describe Admin::SystemCheck::SidekiqProcessCheck do subject(:check) { described_class.new(user) } let(:user) { Fabricate(:user) } diff --git a/spec/lib/admin/system_check/software_version_check_spec.rb b/spec/lib/admin/system_check/software_version_check_spec.rb index de4335fc51..1affaa3a96 100644 --- a/spec/lib/admin/system_check/software_version_check_spec.rb +++ b/spec/lib/admin/system_check/software_version_check_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::SystemCheck::SoftwareVersionCheck do +RSpec.describe Admin::SystemCheck::SoftwareVersionCheck do include RoutingHelper subject(:check) { described_class.new(user) } diff --git a/spec/lib/admin/system_check_spec.rb b/spec/lib/admin/system_check_spec.rb index 30048fd3ad..92852ab025 100644 --- a/spec/lib/admin/system_check_spec.rb +++ b/spec/lib/admin/system_check_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::SystemCheck do +RSpec.describe Admin::SystemCheck do let(:user) { Fabricate(:user) } describe 'perform' do diff --git a/spec/lib/annual_report_spec.rb b/spec/lib/annual_report_spec.rb index ffb742697b..bd4d0f3387 100644 --- a/spec/lib/annual_report_spec.rb +++ b/spec/lib/annual_report_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe AnnualReport do +RSpec.describe AnnualReport do describe '#generate' do subject { described_class.new(account, Time.zone.now.year) } diff --git a/spec/lib/cache_buster_spec.rb b/spec/lib/cache_buster_spec.rb index 84085608e8..f7cff9c1c3 100644 --- a/spec/lib/cache_buster_spec.rb +++ b/spec/lib/cache_buster_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe CacheBuster do +RSpec.describe CacheBuster do subject { described_class.new(secret_header: secret_header, secret: secret, http_method: http_method) } let(:secret_header) { nil } diff --git a/spec/lib/connection_pool/shared_connection_pool_spec.rb b/spec/lib/connection_pool/shared_connection_pool_spec.rb index a2fe75f742..2352703b5a 100644 --- a/spec/lib/connection_pool/shared_connection_pool_spec.rb +++ b/spec/lib/connection_pool/shared_connection_pool_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ConnectionPool::SharedConnectionPool do +RSpec.describe ConnectionPool::SharedConnectionPool do subject { described_class.new(size: 5, timeout: 5) { |site| mini_connection_class.new(site) } } let(:mini_connection_class) do diff --git a/spec/lib/connection_pool/shared_timed_stack_spec.rb b/spec/lib/connection_pool/shared_timed_stack_spec.rb index 04d550eec5..7469664ea0 100644 --- a/spec/lib/connection_pool/shared_timed_stack_spec.rb +++ b/spec/lib/connection_pool/shared_timed_stack_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ConnectionPool::SharedTimedStack do +RSpec.describe ConnectionPool::SharedTimedStack do subject { described_class.new(5) { |site| mini_connection_class.new(site) } } let(:mini_connection_class) do diff --git a/spec/lib/content_security_policy_spec.rb b/spec/lib/content_security_policy_spec.rb index 27a3e80257..5ecea60543 100644 --- a/spec/lib/content_security_policy_spec.rb +++ b/spec/lib/content_security_policy_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ContentSecurityPolicy do +RSpec.describe ContentSecurityPolicy do subject { described_class.new } around do |example| diff --git a/spec/lib/delivery_failure_tracker_spec.rb b/spec/lib/delivery_failure_tracker_spec.rb index c8179ebd91..40c8adc4c8 100644 --- a/spec/lib/delivery_failure_tracker_spec.rb +++ b/spec/lib/delivery_failure_tracker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe DeliveryFailureTracker do +RSpec.describe DeliveryFailureTracker do subject { described_class.new('http://example.com/inbox') } describe '#track_success!' do diff --git a/spec/lib/extractor_spec.rb b/spec/lib/extractor_spec.rb index af5c62d4c8..bc3ee8ac49 100644 --- a/spec/lib/extractor_spec.rb +++ b/spec/lib/extractor_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Extractor do +RSpec.describe Extractor do describe 'extract_mentions_or_lists_with_indices' do it 'returns an empty array if the given string does not have at signs' do text = 'a string without at signs' diff --git a/spec/lib/fast_ip_map_spec.rb b/spec/lib/fast_ip_map_spec.rb index 78b3ddb054..a3a647e3e3 100644 --- a/spec/lib/fast_ip_map_spec.rb +++ b/spec/lib/fast_ip_map_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe FastIpMap do +RSpec.describe FastIpMap do describe '#include?' do subject { described_class.new([IPAddr.new('20.4.0.0/16'), IPAddr.new('145.22.30.0/24'), IPAddr.new('189.45.86.3')]) } diff --git a/spec/lib/hashtag_normalizer_spec.rb b/spec/lib/hashtag_normalizer_spec.rb index fbb9f37c07..796445043a 100644 --- a/spec/lib/hashtag_normalizer_spec.rb +++ b/spec/lib/hashtag_normalizer_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe HashtagNormalizer do +RSpec.describe HashtagNormalizer do subject { described_class.new } describe '#normalize' do diff --git a/spec/lib/importer/accounts_index_importer_spec.rb b/spec/lib/importer/accounts_index_importer_spec.rb index 73f9bce399..a5d11c747a 100644 --- a/spec/lib/importer/accounts_index_importer_spec.rb +++ b/spec/lib/importer/accounts_index_importer_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Importer::AccountsIndexImporter do +RSpec.describe Importer::AccountsIndexImporter do describe 'import!' do let(:pool) { Concurrent::FixedThreadPool.new(5) } let(:importer) { described_class.new(batch_size: 123, executor: pool) } diff --git a/spec/lib/importer/base_importer_spec.rb b/spec/lib/importer/base_importer_spec.rb index 78e9a869b8..0d12f975aa 100644 --- a/spec/lib/importer/base_importer_spec.rb +++ b/spec/lib/importer/base_importer_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Importer::BaseImporter do +RSpec.describe Importer::BaseImporter do describe 'import!' do let(:pool) { Concurrent::FixedThreadPool.new(5) } let(:importer) { described_class.new(batch_size: 123, executor: pool) } diff --git a/spec/lib/importer/public_statuses_index_importer_spec.rb b/spec/lib/importer/public_statuses_index_importer_spec.rb index bc7c038a97..2407717409 100644 --- a/spec/lib/importer/public_statuses_index_importer_spec.rb +++ b/spec/lib/importer/public_statuses_index_importer_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Importer::PublicStatusesIndexImporter do +RSpec.describe Importer::PublicStatusesIndexImporter do describe 'import!' do let(:pool) { Concurrent::FixedThreadPool.new(5) } let(:importer) { described_class.new(batch_size: 123, executor: pool) } diff --git a/spec/lib/importer/statuses_index_importer_spec.rb b/spec/lib/importer/statuses_index_importer_spec.rb index d5e1c9f2cb..f6fac3bd67 100644 --- a/spec/lib/importer/statuses_index_importer_spec.rb +++ b/spec/lib/importer/statuses_index_importer_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Importer::StatusesIndexImporter do +RSpec.describe Importer::StatusesIndexImporter do describe 'import!' do let(:pool) { Concurrent::FixedThreadPool.new(5) } let(:importer) { described_class.new(batch_size: 123, executor: pool) } diff --git a/spec/lib/importer/tags_index_importer_spec.rb b/spec/lib/importer/tags_index_importer_spec.rb index 348990c01e..44de9e7c34 100644 --- a/spec/lib/importer/tags_index_importer_spec.rb +++ b/spec/lib/importer/tags_index_importer_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Importer::TagsIndexImporter do +RSpec.describe Importer::TagsIndexImporter do describe 'import!' do let(:pool) { Concurrent::FixedThreadPool.new(5) } let(:importer) { described_class.new(batch_size: 123, executor: pool) } diff --git a/spec/lib/mastodon/cli/accounts_spec.rb b/spec/lib/mastodon/cli/accounts_spec.rb index 3988e0b027..f6cc28297a 100644 --- a/spec/lib/mastodon/cli/accounts_spec.rb +++ b/spec/lib/mastodon/cli/accounts_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'mastodon/cli/accounts' -describe Mastodon::CLI::Accounts do +RSpec.describe Mastodon::CLI::Accounts do subject { cli.invoke(action, arguments, options) } let(:cli) { described_class.new } diff --git a/spec/lib/mastodon/cli/cache_spec.rb b/spec/lib/mastodon/cli/cache_spec.rb index 247a14f9e2..dc571238d2 100644 --- a/spec/lib/mastodon/cli/cache_spec.rb +++ b/spec/lib/mastodon/cli/cache_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'mastodon/cli/cache' -describe Mastodon::CLI::Cache do +RSpec.describe Mastodon::CLI::Cache do subject { cli.invoke(action, arguments, options) } let(:cli) { described_class.new } diff --git a/spec/lib/mastodon/cli/canonical_email_blocks_spec.rb b/spec/lib/mastodon/cli/canonical_email_blocks_spec.rb index 1745ea01bf..faa5ec7cb8 100644 --- a/spec/lib/mastodon/cli/canonical_email_blocks_spec.rb +++ b/spec/lib/mastodon/cli/canonical_email_blocks_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'mastodon/cli/canonical_email_blocks' -describe Mastodon::CLI::CanonicalEmailBlocks do +RSpec.describe Mastodon::CLI::CanonicalEmailBlocks do subject { cli.invoke(action, arguments, options) } let(:cli) { described_class.new } diff --git a/spec/lib/mastodon/cli/domains_spec.rb b/spec/lib/mastodon/cli/domains_spec.rb index 448e6fe42b..d1c26546f0 100644 --- a/spec/lib/mastodon/cli/domains_spec.rb +++ b/spec/lib/mastodon/cli/domains_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'mastodon/cli/domains' -describe Mastodon::CLI::Domains do +RSpec.describe Mastodon::CLI::Domains do subject { cli.invoke(action, arguments, options) } let(:cli) { described_class.new } diff --git a/spec/lib/mastodon/cli/email_domain_blocks_spec.rb b/spec/lib/mastodon/cli/email_domain_blocks_spec.rb index 55e3da0bb8..a5fbd23e65 100644 --- a/spec/lib/mastodon/cli/email_domain_blocks_spec.rb +++ b/spec/lib/mastodon/cli/email_domain_blocks_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'mastodon/cli/email_domain_blocks' -describe Mastodon::CLI::EmailDomainBlocks do +RSpec.describe Mastodon::CLI::EmailDomainBlocks do subject { cli.invoke(action, arguments, options) } let(:cli) { described_class.new } diff --git a/spec/lib/mastodon/cli/emoji_spec.rb b/spec/lib/mastodon/cli/emoji_spec.rb index d05e972e77..4336db17d3 100644 --- a/spec/lib/mastodon/cli/emoji_spec.rb +++ b/spec/lib/mastodon/cli/emoji_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'mastodon/cli/emoji' -describe Mastodon::CLI::Emoji do +RSpec.describe Mastodon::CLI::Emoji do subject { cli.invoke(action, arguments, options) } let(:cli) { described_class.new } diff --git a/spec/lib/mastodon/cli/feeds_spec.rb b/spec/lib/mastodon/cli/feeds_spec.rb index 420cb3d587..75a8cb3ebc 100644 --- a/spec/lib/mastodon/cli/feeds_spec.rb +++ b/spec/lib/mastodon/cli/feeds_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'mastodon/cli/feeds' -describe Mastodon::CLI::Feeds do +RSpec.describe Mastodon::CLI::Feeds do subject { cli.invoke(action, arguments, options) } let(:cli) { described_class.new } diff --git a/spec/lib/mastodon/cli/ip_blocks_spec.rb b/spec/lib/mastodon/cli/ip_blocks_spec.rb index d44b1b9fe4..68d6b19859 100644 --- a/spec/lib/mastodon/cli/ip_blocks_spec.rb +++ b/spec/lib/mastodon/cli/ip_blocks_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'mastodon/cli/ip_blocks' -describe Mastodon::CLI::IpBlocks do +RSpec.describe Mastodon::CLI::IpBlocks do subject { cli.invoke(action, arguments, options) } let(:cli) { described_class.new } diff --git a/spec/lib/mastodon/cli/main_spec.rb b/spec/lib/mastodon/cli/main_spec.rb index 99d770a81d..a63b798683 100644 --- a/spec/lib/mastodon/cli/main_spec.rb +++ b/spec/lib/mastodon/cli/main_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'mastodon/cli/main' -describe Mastodon::CLI::Main do +RSpec.describe Mastodon::CLI::Main do subject { cli.invoke(action, arguments, options) } let(:cli) { described_class.new } diff --git a/spec/lib/mastodon/cli/maintenance_spec.rb b/spec/lib/mastodon/cli/maintenance_spec.rb index cde25d39ed..6a15677f43 100644 --- a/spec/lib/mastodon/cli/maintenance_spec.rb +++ b/spec/lib/mastodon/cli/maintenance_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'mastodon/cli/maintenance' -describe Mastodon::CLI::Maintenance do +RSpec.describe Mastodon::CLI::Maintenance do subject { cli.invoke(action, arguments, options) } let(:cli) { described_class.new } diff --git a/spec/lib/mastodon/cli/media_spec.rb b/spec/lib/mastodon/cli/media_spec.rb index ecc7101b6c..fa7a3161d0 100644 --- a/spec/lib/mastodon/cli/media_spec.rb +++ b/spec/lib/mastodon/cli/media_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'mastodon/cli/media' -describe Mastodon::CLI::Media do +RSpec.describe Mastodon::CLI::Media do subject { cli.invoke(action, arguments, options) } let(:cli) { described_class.new } diff --git a/spec/lib/mastodon/cli/preview_cards_spec.rb b/spec/lib/mastodon/cli/preview_cards_spec.rb index 951ae3758f..949787a759 100644 --- a/spec/lib/mastodon/cli/preview_cards_spec.rb +++ b/spec/lib/mastodon/cli/preview_cards_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'mastodon/cli/preview_cards' -describe Mastodon::CLI::PreviewCards do +RSpec.describe Mastodon::CLI::PreviewCards do subject { cli.invoke(action, arguments, options) } let(:cli) { described_class.new } diff --git a/spec/lib/mastodon/cli/search_spec.rb b/spec/lib/mastodon/cli/search_spec.rb index ed3789c3e7..8a6c2492aa 100644 --- a/spec/lib/mastodon/cli/search_spec.rb +++ b/spec/lib/mastodon/cli/search_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'mastodon/cli/search' -describe Mastodon::CLI::Search do +RSpec.describe Mastodon::CLI::Search do subject { cli.invoke(action, arguments, options) } let(:cli) { described_class.new } diff --git a/spec/lib/mastodon/cli/settings_spec.rb b/spec/lib/mastodon/cli/settings_spec.rb index e1b353eb90..5565b798ef 100644 --- a/spec/lib/mastodon/cli/settings_spec.rb +++ b/spec/lib/mastodon/cli/settings_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'mastodon/cli/settings' -describe Mastodon::CLI::Settings do +RSpec.describe Mastodon::CLI::Settings do it_behaves_like 'CLI Command' describe 'subcommand "registrations"' do diff --git a/spec/lib/mastodon/cli/statuses_spec.rb b/spec/lib/mastodon/cli/statuses_spec.rb index 161b7c02bb..2597ad7f27 100644 --- a/spec/lib/mastodon/cli/statuses_spec.rb +++ b/spec/lib/mastodon/cli/statuses_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'mastodon/cli/statuses' -describe Mastodon::CLI::Statuses do +RSpec.describe Mastodon::CLI::Statuses do subject { cli.invoke(action, arguments, options) } let(:cli) { described_class.new } diff --git a/spec/lib/mastodon/cli/upgrade_spec.rb b/spec/lib/mastodon/cli/upgrade_spec.rb index 6861e04887..6861e1a068 100644 --- a/spec/lib/mastodon/cli/upgrade_spec.rb +++ b/spec/lib/mastodon/cli/upgrade_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'mastodon/cli/upgrade' -describe Mastodon::CLI::Upgrade do +RSpec.describe Mastodon::CLI::Upgrade do subject { cli.invoke(action, arguments, options) } let(:cli) { described_class.new } diff --git a/spec/lib/mastodon/migration_warning_spec.rb b/spec/lib/mastodon/migration_warning_spec.rb index 4adf0837ab..d796d1e902 100644 --- a/spec/lib/mastodon/migration_warning_spec.rb +++ b/spec/lib/mastodon/migration_warning_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'mastodon/migration_warning' -describe Mastodon::MigrationWarning do +RSpec.describe Mastodon::MigrationWarning do describe 'migration_duration_warning' do before do allow(migration).to receive(:valid_environment?).and_return(true) diff --git a/spec/lib/ostatus/tag_manager_spec.rb b/spec/lib/ostatus/tag_manager_spec.rb index 0e20f26c7c..f808b96289 100644 --- a/spec/lib/ostatus/tag_manager_spec.rb +++ b/spec/lib/ostatus/tag_manager_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe OStatus::TagManager do +RSpec.describe OStatus::TagManager do describe '#unique_tag' do it 'returns a unique tag' do expect(described_class.instance.unique_tag(Time.utc(2000), 12, 'Status')).to eq 'tag:cb6e6126.ngrok.io,2000-01-01:objectId=12:objectType=Status' diff --git a/spec/lib/paperclip/response_with_limit_adapter_spec.rb b/spec/lib/paperclip/response_with_limit_adapter_spec.rb index baf8bf5bb7..3db52ffa0d 100644 --- a/spec/lib/paperclip/response_with_limit_adapter_spec.rb +++ b/spec/lib/paperclip/response_with_limit_adapter_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Paperclip::ResponseWithLimitAdapter do +RSpec.describe Paperclip::ResponseWithLimitAdapter do subject { described_class.new(response_with_limit) } before { stub_request(:get, url).to_return(headers: headers, body: body) } diff --git a/spec/lib/permalink_redirector_spec.rb b/spec/lib/permalink_redirector_spec.rb index a009136561..3f77d7665a 100644 --- a/spec/lib/permalink_redirector_spec.rb +++ b/spec/lib/permalink_redirector_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe PermalinkRedirector do +RSpec.describe PermalinkRedirector do let(:remote_account) { Fabricate(:account, username: 'alice', domain: 'example.com', url: 'https://example.com/@alice', id: 2) } describe '#redirect_url' do diff --git a/spec/lib/request_pool_spec.rb b/spec/lib/request_pool_spec.rb index a82eb5a188..2e8c785de8 100644 --- a/spec/lib/request_pool_spec.rb +++ b/spec/lib/request_pool_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe RequestPool do +RSpec.describe RequestPool do subject { described_class.new } describe '#with' do diff --git a/spec/lib/request_spec.rb b/spec/lib/request_spec.rb index c99f18838b..c600a48ee2 100644 --- a/spec/lib/request_spec.rb +++ b/spec/lib/request_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'securerandom' -describe Request do +RSpec.describe Request do subject { described_class.new(:get, 'http://example.com') } describe '#headers' do diff --git a/spec/lib/sanitize/config_spec.rb b/spec/lib/sanitize/config_spec.rb index fe0b272c0a..17b78a95f6 100644 --- a/spec/lib/sanitize/config_spec.rb +++ b/spec/lib/sanitize/config_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Sanitize::Config do +RSpec.describe Sanitize::Config do describe '::MASTODON_STRICT' do subject { described_class::MASTODON_STRICT } diff --git a/spec/lib/scope_transformer_spec.rb b/spec/lib/scope_transformer_spec.rb index 7bc226e94f..09a31e04c5 100644 --- a/spec/lib/scope_transformer_spec.rb +++ b/spec/lib/scope_transformer_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ScopeTransformer do +RSpec.describe ScopeTransformer do describe '#apply' do subject { described_class.new.apply(ScopeParser.new.parse(input)) } diff --git a/spec/lib/search_query_parser_spec.rb b/spec/lib/search_query_parser_spec.rb index 66b0e8f9e2..22149b3402 100644 --- a/spec/lib/search_query_parser_spec.rb +++ b/spec/lib/search_query_parser_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'parslet/rig/rspec' -describe SearchQueryParser do +RSpec.describe SearchQueryParser do let(:parser) { described_class.new } context 'with term' do diff --git a/spec/lib/search_query_transformer_spec.rb b/spec/lib/search_query_transformer_spec.rb index 5817e3d1d2..00220f84fd 100644 --- a/spec/lib/search_query_transformer_spec.rb +++ b/spec/lib/search_query_transformer_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe SearchQueryTransformer do +RSpec.describe SearchQueryTransformer do subject { described_class.new.apply(parser, current_account: account) } let(:account) { Fabricate(:account) } diff --git a/spec/lib/status_cache_hydrator_spec.rb b/spec/lib/status_cache_hydrator_spec.rb index 5b80ccb970..958e2f62d7 100644 --- a/spec/lib/status_cache_hydrator_spec.rb +++ b/spec/lib/status_cache_hydrator_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe StatusCacheHydrator do +RSpec.describe StatusCacheHydrator do let(:status) { Fabricate(:status) } let(:account) { Fabricate(:account) } diff --git a/spec/lib/status_filter_spec.rb b/spec/lib/status_filter_spec.rb index cf6f3c7959..16c2e84f22 100644 --- a/spec/lib/status_filter_spec.rb +++ b/spec/lib/status_filter_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe StatusFilter do +RSpec.describe StatusFilter do describe '#filtered?' do let(:status) { Fabricate(:status) } diff --git a/spec/lib/status_finder_spec.rb b/spec/lib/status_finder_spec.rb index 53f5039af9..4d1c27afff 100644 --- a/spec/lib/status_finder_spec.rb +++ b/spec/lib/status_finder_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe StatusFinder do +RSpec.describe StatusFinder do include RoutingHelper describe '#status' do diff --git a/spec/lib/status_reach_finder_spec.rb b/spec/lib/status_reach_finder_spec.rb index 7181717dc1..c045980ea9 100644 --- a/spec/lib/status_reach_finder_spec.rb +++ b/spec/lib/status_reach_finder_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe StatusReachFinder do +RSpec.describe StatusReachFinder do describe '#inboxes' do context 'with a local status' do subject { described_class.new(status) } diff --git a/spec/lib/webfinger_resource_spec.rb b/spec/lib/webfinger_resource_spec.rb index 442f91aad0..0b86b41c48 100644 --- a/spec/lib/webfinger_resource_spec.rb +++ b/spec/lib/webfinger_resource_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe WebfingerResource do +RSpec.describe WebfingerResource do around do |example| before_local = Rails.configuration.x.local_domain before_web = Rails.configuration.x.web_domain diff --git a/spec/lib/webhooks/payload_renderer_spec.rb b/spec/lib/webhooks/payload_renderer_spec.rb index 074847c74c..0623edd254 100644 --- a/spec/lib/webhooks/payload_renderer_spec.rb +++ b/spec/lib/webhooks/payload_renderer_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Webhooks::PayloadRenderer do +RSpec.describe Webhooks::PayloadRenderer do subject(:renderer) { described_class.new(json) } let(:event) { Webhooks::EventPresenter.new(type, object) } diff --git a/spec/locales/i18n_spec.rb b/spec/locales/i18n_spec.rb index cfce8e2234..8facf6612c 100644 --- a/spec/locales/i18n_spec.rb +++ b/spec/locales/i18n_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'I18n' do +RSpec.describe 'I18n' do describe 'Pluralizing locale translations' do subject { I18n.t('generic.validation_errors', count: 1) } diff --git a/spec/mailers/user_mailer_spec.rb b/spec/mailers/user_mailer_spec.rb index 5a8c293740..0257465817 100644 --- a/spec/mailers/user_mailer_spec.rb +++ b/spec/mailers/user_mailer_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe UserMailer do +RSpec.describe UserMailer do let(:receiver) { Fabricate(:user) } describe '#confirmation_instructions' do diff --git a/spec/models/account_filter_spec.rb b/spec/models/account_filter_spec.rb index fa47b5954a..5cb7fa92d4 100644 --- a/spec/models/account_filter_spec.rb +++ b/spec/models/account_filter_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe AccountFilter do +RSpec.describe AccountFilter do describe 'with empty params' do it 'excludes instance actor by default' do filter = described_class.new({}) diff --git a/spec/models/account_warning_preset_spec.rb b/spec/models/account_warning_preset_spec.rb index f171df7c97..e7a9855175 100644 --- a/spec/models/account_warning_preset_spec.rb +++ b/spec/models/account_warning_preset_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe AccountWarningPreset do +RSpec.describe AccountWarningPreset do describe 'alphabetical' do let(:first) { Fabricate(:account_warning_preset, title: 'aaa', text: 'aaa') } let(:second) { Fabricate(:account_warning_preset, title: 'bbb', text: 'aaa') } diff --git a/spec/models/admin/appeal_filter_spec.rb b/spec/models/admin/appeal_filter_spec.rb index e840bc3bc1..8303e58ad6 100644 --- a/spec/models/admin/appeal_filter_spec.rb +++ b/spec/models/admin/appeal_filter_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::AppealFilter do +RSpec.describe Admin::AppealFilter do describe '#results' do let(:approved_appeal) { Fabricate(:appeal, approved_at: 10.days.ago) } let(:not_approved_appeal) { Fabricate(:appeal, approved_at: nil) } diff --git a/spec/models/admin/tag_filter_spec.rb b/spec/models/admin/tag_filter_spec.rb index 21dc28affb..1baae117b8 100644 --- a/spec/models/admin/tag_filter_spec.rb +++ b/spec/models/admin/tag_filter_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::TagFilter do +RSpec.describe Admin::TagFilter do describe 'with invalid params' do it 'raises with key error' do filter = described_class.new(wrong: true) diff --git a/spec/models/announcement_spec.rb b/spec/models/announcement_spec.rb index 1e7283ca77..e3865e6fc7 100644 --- a/spec/models/announcement_spec.rb +++ b/spec/models/announcement_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Announcement do +RSpec.describe Announcement do describe 'Scopes' do context 'with published and unpublished records' do let!(:published) { Fabricate(:announcement, published: true) } diff --git a/spec/models/appeal_spec.rb b/spec/models/appeal_spec.rb index 13ca3a2d90..7e324582ed 100644 --- a/spec/models/appeal_spec.rb +++ b/spec/models/appeal_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Appeal do +RSpec.describe Appeal do describe 'Validations' do it 'validates text length is under limit' do appeal = Fabricate.build( diff --git a/spec/models/concerns/account/counters_spec.rb b/spec/models/concerns/account/counters_spec.rb index ccac9e95de..bbbaa7d06c 100644 --- a/spec/models/concerns/account/counters_spec.rb +++ b/spec/models/concerns/account/counters_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Account::Counters do +RSpec.describe Account::Counters do let!(:account) { Fabricate(:account) } describe '#increment_count!' do diff --git a/spec/models/concerns/account/finder_concern_spec.rb b/spec/models/concerns/account/finder_concern_spec.rb index ab5149e987..b3fae56dfc 100644 --- a/spec/models/concerns/account/finder_concern_spec.rb +++ b/spec/models/concerns/account/finder_concern_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Account::FinderConcern do +RSpec.describe Account::FinderConcern do describe 'local finders' do let!(:account) { Fabricate(:account, username: 'Alice') } diff --git a/spec/models/concerns/account/interactions_spec.rb b/spec/models/concerns/account/interactions_spec.rb index 3f2c601f38..4868054df7 100644 --- a/spec/models/concerns/account/interactions_spec.rb +++ b/spec/models/concerns/account/interactions_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Account::Interactions do +RSpec.describe Account::Interactions do let(:account) { Fabricate(:account, username: 'account') } let(:account_id) { account.id } let(:account_ids) { [account_id] } diff --git a/spec/models/concerns/account/statuses_search_spec.rb b/spec/models/concerns/account/statuses_search_spec.rb index ab249d62d0..9488d42021 100644 --- a/spec/models/concerns/account/statuses_search_spec.rb +++ b/spec/models/concerns/account/statuses_search_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Account::StatusesSearch do +RSpec.describe Account::StatusesSearch do let(:account) { Fabricate(:account, indexable: indexable) } before do diff --git a/spec/models/concerns/status/threading_concern_spec.rb b/spec/models/concerns/status/threading_concern_spec.rb index 09fb218566..a13487c10a 100644 --- a/spec/models/concerns/status/threading_concern_spec.rb +++ b/spec/models/concerns/status/threading_concern_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Status::ThreadingConcern do +RSpec.describe Status::ThreadingConcern do describe '#ancestors' do let!(:alice) { Fabricate(:account, username: 'alice') } let!(:bob) { Fabricate(:account, username: 'bob', domain: 'example.com') } diff --git a/spec/models/custom_emoji_category_spec.rb b/spec/models/custom_emoji_category_spec.rb index 30de07bd81..3da77344e2 100644 --- a/spec/models/custom_emoji_category_spec.rb +++ b/spec/models/custom_emoji_category_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe CustomEmojiCategory do +RSpec.describe CustomEmojiCategory do describe 'validations' do it 'validates name presence' do record = described_class.new(name: nil) diff --git a/spec/models/domain_allow_spec.rb b/spec/models/domain_allow_spec.rb index 12504211a1..92f1ef8ccf 100644 --- a/spec/models/domain_allow_spec.rb +++ b/spec/models/domain_allow_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe DomainAllow do +RSpec.describe DomainAllow do describe 'Validations' do it 'is invalid without a domain' do domain_allow = Fabricate.build(:domain_allow, domain: nil) diff --git a/spec/models/export_spec.rb b/spec/models/export_spec.rb index 75468898d2..06bf07ed78 100644 --- a/spec/models/export_spec.rb +++ b/spec/models/export_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Export do +RSpec.describe Export do let(:account) { Fabricate(:account) } let(:target_accounts) do [{}, { username: 'one', domain: 'local.host' }].map(&method(:Fabricate).curry(2).call(:account)) diff --git a/spec/models/extended_description_spec.rb b/spec/models/extended_description_spec.rb index ecc27c0f6d..368ca33f5b 100644 --- a/spec/models/extended_description_spec.rb +++ b/spec/models/extended_description_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ExtendedDescription do +RSpec.describe ExtendedDescription do describe '.current' do context 'with the default values' do it 'makes a new instance' do diff --git a/spec/models/form/admin_settings_spec.rb b/spec/models/form/admin_settings_spec.rb index 0dc2d881ad..6080b9e081 100644 --- a/spec/models/form/admin_settings_spec.rb +++ b/spec/models/form/admin_settings_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Form::AdminSettings do +RSpec.describe Form::AdminSettings do describe 'validations' do describe 'site_contact_username' do context 'with no accounts' do diff --git a/spec/models/form/custom_emoji_batch_spec.rb b/spec/models/form/custom_emoji_batch_spec.rb index abeada5d50..180c6abd23 100644 --- a/spec/models/form/custom_emoji_batch_spec.rb +++ b/spec/models/form/custom_emoji_batch_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Form::CustomEmojiBatch do +RSpec.describe Form::CustomEmojiBatch do describe '#save' do subject { described_class.new({ current_account: account }.merge(options)) } diff --git a/spec/models/form/status_filter_batch_action_spec.rb b/spec/models/form/status_filter_batch_action_spec.rb index f06a11cc8b..8ea9d7545e 100644 --- a/spec/models/form/status_filter_batch_action_spec.rb +++ b/spec/models/form/status_filter_batch_action_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Form::StatusFilterBatchAction do +RSpec.describe Form::StatusFilterBatchAction do describe '#save!' do it 'does nothing if status_filter_ids is empty' do batch_action = described_class.new(status_filter_ids: []) diff --git a/spec/models/ip_block_spec.rb b/spec/models/ip_block_spec.rb index 290b99b288..6f1eb38425 100644 --- a/spec/models/ip_block_spec.rb +++ b/spec/models/ip_block_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe IpBlock do +RSpec.describe IpBlock do describe 'validations' do it 'validates ip presence', :aggregate_failures do ip_block = described_class.new(ip: nil, severity: :no_access) diff --git a/spec/models/marker_spec.rb b/spec/models/marker_spec.rb index 51dd584388..8339f8e259 100644 --- a/spec/models/marker_spec.rb +++ b/spec/models/marker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Marker do +RSpec.describe Marker do describe 'validations' do describe 'timeline' do it 'must be included in valid list' do diff --git a/spec/models/one_time_key_spec.rb b/spec/models/one_time_key_spec.rb index 6ff7ffc5c1..17fcdf3788 100644 --- a/spec/models/one_time_key_spec.rb +++ b/spec/models/one_time_key_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe OneTimeKey do +RSpec.describe OneTimeKey do describe 'validations' do context 'with an invalid signature' do let(:one_time_key) { Fabricate.build(:one_time_key, signature: 'wrong!') } diff --git a/spec/models/poll_spec.rb b/spec/models/poll_spec.rb index ebcc459078..740ef63d81 100644 --- a/spec/models/poll_spec.rb +++ b/spec/models/poll_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Poll do +RSpec.describe Poll do describe 'scopes' do let(:status) { Fabricate(:status) } let(:attached_poll) { Fabricate(:poll, status: status) } diff --git a/spec/models/preview_card_provider_spec.rb b/spec/models/preview_card_provider_spec.rb index 8b18b3d2b7..12bca83440 100644 --- a/spec/models/preview_card_provider_spec.rb +++ b/spec/models/preview_card_provider_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe PreviewCardProvider do +RSpec.describe PreviewCardProvider do include_examples 'Reviewable' describe 'scopes' do diff --git a/spec/models/preview_card_spec.rb b/spec/models/preview_card_spec.rb index a17c7532e9..2f0ea38ee4 100644 --- a/spec/models/preview_card_spec.rb +++ b/spec/models/preview_card_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe PreviewCard do +RSpec.describe PreviewCard do describe 'validations' do describe 'urls' do it 'allows http schemes' do diff --git a/spec/models/privacy_policy_spec.rb b/spec/models/privacy_policy_spec.rb index 03bbe7264b..742cac8e18 100644 --- a/spec/models/privacy_policy_spec.rb +++ b/spec/models/privacy_policy_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe PrivacyPolicy do +RSpec.describe PrivacyPolicy do describe '.current' do context 'with the default values' do it 'has the privacy text' do diff --git a/spec/models/relationship_filter_spec.rb b/spec/models/relationship_filter_spec.rb index fccd42aaad..b56da91f8d 100644 --- a/spec/models/relationship_filter_spec.rb +++ b/spec/models/relationship_filter_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe RelationshipFilter do +RSpec.describe RelationshipFilter do let(:account) { Fabricate(:account) } describe '#results' do diff --git a/spec/models/report_filter_spec.rb b/spec/models/report_filter_spec.rb index 6baf0ea421..8668eb3d10 100644 --- a/spec/models/report_filter_spec.rb +++ b/spec/models/report_filter_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ReportFilter do +RSpec.describe ReportFilter do describe 'with empty params' do it 'defaults to unresolved reports list' do filter = described_class.new({}) diff --git a/spec/models/report_spec.rb b/spec/models/report_spec.rb index d01d37bd8b..a0e4f6fafd 100644 --- a/spec/models/report_spec.rb +++ b/spec/models/report_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Report do +RSpec.describe Report do describe 'statuses' do it 'returns the statuses for the report' do status = Fabricate(:status) diff --git a/spec/models/rule_spec.rb b/spec/models/rule_spec.rb index c9b9c55028..375483e0db 100644 --- a/spec/models/rule_spec.rb +++ b/spec/models/rule_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Rule do +RSpec.describe Rule do describe 'scopes' do describe 'ordered' do let(:deleted_rule) { Fabricate(:rule, deleted_at: 10.days.ago) } diff --git a/spec/models/status_edit_spec.rb b/spec/models/status_edit_spec.rb index 2d33514522..7a469b44dc 100644 --- a/spec/models/status_edit_spec.rb +++ b/spec/models/status_edit_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe StatusEdit do +RSpec.describe StatusEdit do describe '#reblog?' do it 'returns false' do record = described_class.new diff --git a/spec/models/tag_feed_spec.rb b/spec/models/tag_feed_spec.rb index 61b8d8d824..578fc78238 100644 --- a/spec/models/tag_feed_spec.rb +++ b/spec/models/tag_feed_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe TagFeed do +RSpec.describe TagFeed do describe '#get' do let(:account) { Fabricate(:account) } let(:tag_cats) { Fabricate(:tag, name: 'cats') } diff --git a/spec/policies/account_warning_preset_policy_spec.rb b/spec/policies/account_warning_preset_policy_spec.rb index 63bf33de24..53e224f19f 100644 --- a/spec/policies/account_warning_preset_policy_spec.rb +++ b/spec/policies/account_warning_preset_policy_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'pundit/rspec' -describe AccountWarningPresetPolicy do +RSpec.describe AccountWarningPresetPolicy do let(:policy) { described_class } let(:admin) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')).account } let(:john) { Fabricate(:account) } diff --git a/spec/policies/admin/status_policy_spec.rb b/spec/policies/admin/status_policy_spec.rb index af9f7716be..07af425516 100644 --- a/spec/policies/admin/status_policy_spec.rb +++ b/spec/policies/admin/status_policy_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'pundit/rspec' -describe Admin::StatusPolicy do +RSpec.describe Admin::StatusPolicy do let(:policy) { described_class } let(:admin) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')).account } let(:john) { Fabricate(:account) } diff --git a/spec/policies/announcement_policy_spec.rb b/spec/policies/announcement_policy_spec.rb index 3d230b3cb4..503ffca6dc 100644 --- a/spec/policies/announcement_policy_spec.rb +++ b/spec/policies/announcement_policy_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'pundit/rspec' -describe AnnouncementPolicy do +RSpec.describe AnnouncementPolicy do let(:policy) { described_class } let(:admin) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')).account } let(:john) { Fabricate(:account) } diff --git a/spec/policies/appeal_policy_spec.rb b/spec/policies/appeal_policy_spec.rb index d7498eb9f0..1bf8ce0a0d 100644 --- a/spec/policies/appeal_policy_spec.rb +++ b/spec/policies/appeal_policy_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'pundit/rspec' -describe AppealPolicy do +RSpec.describe AppealPolicy do let(:policy) { described_class } let(:admin) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')).account } let(:john) { Fabricate(:account) } diff --git a/spec/policies/canonical_email_block_policy_spec.rb b/spec/policies/canonical_email_block_policy_spec.rb index 0e55febfa9..f5029d9e6b 100644 --- a/spec/policies/canonical_email_block_policy_spec.rb +++ b/spec/policies/canonical_email_block_policy_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'pundit/rspec' -describe CanonicalEmailBlockPolicy do +RSpec.describe CanonicalEmailBlockPolicy do let(:policy) { described_class } let(:admin) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')).account } let(:john) { Fabricate(:account) } diff --git a/spec/policies/delivery_policy_spec.rb b/spec/policies/delivery_policy_spec.rb index fbcbf390d7..bb82389eec 100644 --- a/spec/policies/delivery_policy_spec.rb +++ b/spec/policies/delivery_policy_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'pundit/rspec' -describe DeliveryPolicy do +RSpec.describe DeliveryPolicy do let(:policy) { described_class } let(:admin) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')).account } let(:john) { Fabricate(:account) } diff --git a/spec/policies/follow_recommendation_policy_spec.rb b/spec/policies/follow_recommendation_policy_spec.rb index 01f4da0be2..ae74d5c3a8 100644 --- a/spec/policies/follow_recommendation_policy_spec.rb +++ b/spec/policies/follow_recommendation_policy_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'pundit/rspec' -describe FollowRecommendationPolicy do +RSpec.describe FollowRecommendationPolicy do let(:policy) { described_class } let(:admin) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')).account } let(:john) { Fabricate(:account) } diff --git a/spec/policies/ip_block_policy_spec.rb b/spec/policies/ip_block_policy_spec.rb index 3cfa85863c..97bc239e9a 100644 --- a/spec/policies/ip_block_policy_spec.rb +++ b/spec/policies/ip_block_policy_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'pundit/rspec' -describe IpBlockPolicy do +RSpec.describe IpBlockPolicy do let(:policy) { described_class } let(:admin) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')).account } let(:john) { Fabricate(:account) } diff --git a/spec/policies/preview_card_policy_spec.rb b/spec/policies/preview_card_policy_spec.rb index d6675c5b34..a1944303e1 100644 --- a/spec/policies/preview_card_policy_spec.rb +++ b/spec/policies/preview_card_policy_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'pundit/rspec' -describe PreviewCardPolicy do +RSpec.describe PreviewCardPolicy do let(:policy) { described_class } let(:admin) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')).account } let(:john) { Fabricate(:account) } diff --git a/spec/policies/preview_card_provider_policy_spec.rb b/spec/policies/preview_card_provider_policy_spec.rb index 8d3715de95..676039a1b7 100644 --- a/spec/policies/preview_card_provider_policy_spec.rb +++ b/spec/policies/preview_card_provider_policy_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'pundit/rspec' -describe PreviewCardProviderPolicy do +RSpec.describe PreviewCardProviderPolicy do let(:policy) { described_class } let(:admin) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')).account } let(:john) { Fabricate(:account) } diff --git a/spec/policies/rule_policy_spec.rb b/spec/policies/rule_policy_spec.rb index 0e45f6df02..5d435e38c1 100644 --- a/spec/policies/rule_policy_spec.rb +++ b/spec/policies/rule_policy_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'pundit/rspec' -describe RulePolicy do +RSpec.describe RulePolicy do let(:policy) { described_class } let(:admin) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')).account } let(:john) { Fabricate(:account) } diff --git a/spec/policies/webhook_policy_spec.rb b/spec/policies/webhook_policy_spec.rb index 909311461a..96aaae2c30 100644 --- a/spec/policies/webhook_policy_spec.rb +++ b/spec/policies/webhook_policy_spec.rb @@ -3,7 +3,7 @@ require 'rails_helper' require 'pundit/rspec' -describe WebhookPolicy do +RSpec.describe WebhookPolicy do let(:policy) { described_class } let(:admin) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')).account } let(:john) { Fabricate(:account) } diff --git a/spec/presenters/instance_presenter_spec.rb b/spec/presenters/instance_presenter_spec.rb index 516c7e9896..42f5200f3a 100644 --- a/spec/presenters/instance_presenter_spec.rb +++ b/spec/presenters/instance_presenter_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe InstancePresenter do +RSpec.describe InstancePresenter do let(:instance_presenter) { described_class.new } describe '#description' do diff --git a/spec/requests/account_show_page_spec.rb b/spec/requests/account_show_page_spec.rb index bdcec12fdb..d0857c8980 100644 --- a/spec/requests/account_show_page_spec.rb +++ b/spec/requests/account_show_page_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'The account show page' do +RSpec.describe 'The account show page' do it 'has valid opengraph tags' do alice = Fabricate(:account, username: 'alice', display_name: 'Alice') _status = Fabricate(:status, account: alice, text: 'Hello World') diff --git a/spec/requests/accounts_spec.rb b/spec/requests/accounts_spec.rb index 238524c75c..d53816eff0 100644 --- a/spec/requests/accounts_spec.rb +++ b/spec/requests/accounts_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Accounts show response' do +RSpec.describe 'Accounts show response' do let(:account) { Fabricate(:account) } context 'with an unapproved account' do diff --git a/spec/requests/anonymous_cookies_spec.rb b/spec/requests/anonymous_cookies_spec.rb index 337ed4ec31..235dd46a63 100644 --- a/spec/requests/anonymous_cookies_spec.rb +++ b/spec/requests/anonymous_cookies_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Anonymous visits' do +RSpec.describe 'Anonymous visits' do around do |example| old = ActionController::Base.allow_forgery_protection ActionController::Base.allow_forgery_protection = true diff --git a/spec/requests/api/v1/accounts/familiar_followers_spec.rb b/spec/requests/api/v1/accounts/familiar_followers_spec.rb index fdc0a3a932..475f1b17e4 100644 --- a/spec/requests/api/v1/accounts/familiar_followers_spec.rb +++ b/spec/requests/api/v1/accounts/familiar_followers_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Accounts Familiar Followers API' do +RSpec.describe 'Accounts Familiar Followers API' do let(:user) { Fabricate(:user) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:scopes) { 'read:follows' } diff --git a/spec/requests/api/v1/accounts/follower_accounts_spec.rb b/spec/requests/api/v1/accounts/follower_accounts_spec.rb index 7ff92d6a48..400b1c7aff 100644 --- a/spec/requests/api/v1/accounts/follower_accounts_spec.rb +++ b/spec/requests/api/v1/accounts/follower_accounts_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'API V1 Accounts FollowerAccounts' do +RSpec.describe 'API V1 Accounts FollowerAccounts' do let(:user) { Fabricate(:user) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:scopes) { 'read:accounts' } diff --git a/spec/requests/api/v1/accounts/following_accounts_spec.rb b/spec/requests/api/v1/accounts/following_accounts_spec.rb index b343a48654..b0bb5141ca 100644 --- a/spec/requests/api/v1/accounts/following_accounts_spec.rb +++ b/spec/requests/api/v1/accounts/following_accounts_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'API V1 Accounts FollowingAccounts' do +RSpec.describe 'API V1 Accounts FollowingAccounts' do let(:user) { Fabricate(:user) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:scopes) { 'read:accounts' } diff --git a/spec/requests/api/v1/accounts/identity_proofs_spec.rb b/spec/requests/api/v1/accounts/identity_proofs_spec.rb index 3727af7e89..d1d9db8e73 100644 --- a/spec/requests/api/v1/accounts/identity_proofs_spec.rb +++ b/spec/requests/api/v1/accounts/identity_proofs_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Accounts Identity Proofs API' do +RSpec.describe 'Accounts Identity Proofs API' do let(:user) { Fabricate(:user) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:scopes) { 'read:accounts' } diff --git a/spec/requests/api/v1/accounts/lists_spec.rb b/spec/requests/api/v1/accounts/lists_spec.rb index 48c0337e54..8b04f07f65 100644 --- a/spec/requests/api/v1/accounts/lists_spec.rb +++ b/spec/requests/api/v1/accounts/lists_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Accounts Lists API' do +RSpec.describe 'Accounts Lists API' do let(:user) { Fabricate(:user) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:scopes) { 'read:lists' } diff --git a/spec/requests/api/v1/accounts/lookup_spec.rb b/spec/requests/api/v1/accounts/lookup_spec.rb index 4c022c7c13..dfd9fad49d 100644 --- a/spec/requests/api/v1/accounts/lookup_spec.rb +++ b/spec/requests/api/v1/accounts/lookup_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Accounts Lookup API' do +RSpec.describe 'Accounts Lookup API' do let(:user) { Fabricate(:user) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:scopes) { 'read:accounts' } diff --git a/spec/requests/api/v1/accounts/notes_spec.rb b/spec/requests/api/v1/accounts/notes_spec.rb index 4f3ac68c74..b8c493abcc 100644 --- a/spec/requests/api/v1/accounts/notes_spec.rb +++ b/spec/requests/api/v1/accounts/notes_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Accounts Notes API' do +RSpec.describe 'Accounts Notes API' do let(:user) { Fabricate(:user) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:scopes) { 'write:accounts' } diff --git a/spec/requests/api/v1/accounts/pins_spec.rb b/spec/requests/api/v1/accounts/pins_spec.rb index c293715f7e..c66b80c7fd 100644 --- a/spec/requests/api/v1/accounts/pins_spec.rb +++ b/spec/requests/api/v1/accounts/pins_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Accounts Pins API' do +RSpec.describe 'Accounts Pins API' do let(:user) { Fabricate(:user) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:scopes) { 'write:accounts' } diff --git a/spec/requests/api/v1/accounts/relationships_spec.rb b/spec/requests/api/v1/accounts/relationships_spec.rb index b06ce0509d..76b1830bbe 100644 --- a/spec/requests/api/v1/accounts/relationships_spec.rb +++ b/spec/requests/api/v1/accounts/relationships_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'GET /api/v1/accounts/relationships' do +RSpec.describe 'GET /api/v1/accounts/relationships' do subject do get '/api/v1/accounts/relationships', headers: headers, params: params end diff --git a/spec/requests/api/v1/accounts/search_spec.rb b/spec/requests/api/v1/accounts/search_spec.rb index 76b32e7b2c..f6ab7a8531 100644 --- a/spec/requests/api/v1/accounts/search_spec.rb +++ b/spec/requests/api/v1/accounts/search_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Accounts Search API' do +RSpec.describe 'Accounts Search API' do let(:user) { Fabricate(:user) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:scopes) { 'read:accounts' } diff --git a/spec/requests/api/v1/accounts/statuses_spec.rb b/spec/requests/api/v1/accounts/statuses_spec.rb index 97cdbe0156..4a4d9383db 100644 --- a/spec/requests/api/v1/accounts/statuses_spec.rb +++ b/spec/requests/api/v1/accounts/statuses_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'API V1 Accounts Statuses' do +RSpec.describe 'API V1 Accounts Statuses' do let(:user) { Fabricate(:user) } let(:scopes) { 'read:statuses' } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } diff --git a/spec/requests/api/v1/accounts_spec.rb b/spec/requests/api/v1/accounts_spec.rb index 3432106a46..e31644352b 100644 --- a/spec/requests/api/v1/accounts_spec.rb +++ b/spec/requests/api/v1/accounts_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe '/api/v1/accounts' do +RSpec.describe '/api/v1/accounts' do let(:user) { Fabricate(:user) } let(:scopes) { '' } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } diff --git a/spec/requests/api/v1/admin/dimensions_spec.rb b/spec/requests/api/v1/admin/dimensions_spec.rb index 87534a74b8..43e2db00c5 100644 --- a/spec/requests/api/v1/admin/dimensions_spec.rb +++ b/spec/requests/api/v1/admin/dimensions_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Admin Dimensions' do +RSpec.describe 'Admin Dimensions' do let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:headers) { { 'Authorization' => "Bearer #{token.token}" } } diff --git a/spec/requests/api/v1/admin/measures_spec.rb b/spec/requests/api/v1/admin/measures_spec.rb index 80fed79d9a..56a2c1eaee 100644 --- a/spec/requests/api/v1/admin/measures_spec.rb +++ b/spec/requests/api/v1/admin/measures_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Admin Measures' do +RSpec.describe 'Admin Measures' do let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:headers) { { 'Authorization' => "Bearer #{token.token}" } } diff --git a/spec/requests/api/v1/admin/retention_spec.rb b/spec/requests/api/v1/admin/retention_spec.rb index 9178335ba5..138959a0ab 100644 --- a/spec/requests/api/v1/admin/retention_spec.rb +++ b/spec/requests/api/v1/admin/retention_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Admin Retention' do +RSpec.describe 'Admin Retention' do let(:user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:headers) { { 'Authorization' => "Bearer #{token.token}" } } diff --git a/spec/requests/api/v1/admin/trends/links/links_spec.rb b/spec/requests/api/v1/admin/trends/links/links_spec.rb index 48842828b3..082af785ab 100644 --- a/spec/requests/api/v1/admin/trends/links/links_spec.rb +++ b/spec/requests/api/v1/admin/trends/links/links_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Links' do +RSpec.describe 'Links' do let(:role) { UserRole.find_by(name: 'Admin') } let(:user) { Fabricate(:user, role: role) } let(:scopes) { 'admin:read admin:write' } diff --git a/spec/requests/api/v1/admin/trends/links/preview_card_providers_spec.rb b/spec/requests/api/v1/admin/trends/links/preview_card_providers_spec.rb index 384a305d4a..193906ab05 100644 --- a/spec/requests/api/v1/admin/trends/links/preview_card_providers_spec.rb +++ b/spec/requests/api/v1/admin/trends/links/preview_card_providers_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'API V1 Admin Trends Links Preview Card Providers' do +RSpec.describe 'API V1 Admin Trends Links Preview Card Providers' do let(:role) { UserRole.find_by(name: 'Admin') } let(:user) { Fabricate(:user, role: role) } let(:scopes) { 'admin:read admin:write' } diff --git a/spec/requests/api/v1/admin/trends/statuses_spec.rb b/spec/requests/api/v1/admin/trends/statuses_spec.rb index 04aa0465f2..e33a9658a9 100644 --- a/spec/requests/api/v1/admin/trends/statuses_spec.rb +++ b/spec/requests/api/v1/admin/trends/statuses_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'API V1 Admin Trends Statuses' do +RSpec.describe 'API V1 Admin Trends Statuses' do let(:role) { UserRole.find_by(name: 'Admin') } let(:user) { Fabricate(:user, role: role) } let(:scopes) { 'admin:read admin:write' } diff --git a/spec/requests/api/v1/admin/trends/tags_spec.rb b/spec/requests/api/v1/admin/trends/tags_spec.rb index b1437dad8d..748a27283c 100644 --- a/spec/requests/api/v1/admin/trends/tags_spec.rb +++ b/spec/requests/api/v1/admin/trends/tags_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'API V1 Admin Trends Tags' do +RSpec.describe 'API V1 Admin Trends Tags' do let(:role) { UserRole.find_by(name: 'Admin') } let(:user) { Fabricate(:user, role: role) } let(:scopes) { 'admin:read admin:write' } diff --git a/spec/requests/api/v1/annual_reports_spec.rb b/spec/requests/api/v1/annual_reports_spec.rb index 60cd8ed526..bab184787f 100644 --- a/spec/requests/api/v1/annual_reports_spec.rb +++ b/spec/requests/api/v1/annual_reports_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'API V1 Annual Reports' do +RSpec.describe 'API V1 Annual Reports' do let(:user) { Fabricate(:user) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:headers) { { 'Authorization' => "Bearer #{token.token}" } } diff --git a/spec/requests/api/v1/apps/credentials_spec.rb b/spec/requests/api/v1/apps/credentials_spec.rb index 6e6970ce53..b899999640 100644 --- a/spec/requests/api/v1/apps/credentials_spec.rb +++ b/spec/requests/api/v1/apps/credentials_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Credentials' do +RSpec.describe 'Credentials' do describe 'GET /api/v1/apps/verify_credentials' do subject do get '/api/v1/apps/verify_credentials', headers: headers diff --git a/spec/requests/api/v1/csp_spec.rb b/spec/requests/api/v1/csp_spec.rb index 2db52ac725..5d61d7f3f5 100644 --- a/spec/requests/api/v1/csp_spec.rb +++ b/spec/requests/api/v1/csp_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'API namespace minimal Content-Security-Policy' do +RSpec.describe 'API namespace minimal Content-Security-Policy' do before { stub_tests_controller } after { Rails.application.reload_routes! } diff --git a/spec/requests/api/v1/custom_emojis_spec.rb b/spec/requests/api/v1/custom_emojis_spec.rb index 2f0dc72944..798d8e29ed 100644 --- a/spec/requests/api/v1/custom_emojis_spec.rb +++ b/spec/requests/api/v1/custom_emojis_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Custom Emojis' do +RSpec.describe 'Custom Emojis' do let(:user) { Fabricate(:user) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id) } let(:headers) { { 'Authorization' => "Bearer #{token.token}" } } diff --git a/spec/requests/api/v1/directories_spec.rb b/spec/requests/api/v1/directories_spec.rb index 0a1864d136..94306c06ec 100644 --- a/spec/requests/api/v1/directories_spec.rb +++ b/spec/requests/api/v1/directories_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Directories API' do +RSpec.describe 'Directories API' do let(:user) { Fabricate(:user, confirmed_at: nil) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:scopes) { 'read:follows' } diff --git a/spec/requests/api/v1/endorsements_spec.rb b/spec/requests/api/v1/endorsements_spec.rb index e267f2abd2..255211a404 100644 --- a/spec/requests/api/v1/endorsements_spec.rb +++ b/spec/requests/api/v1/endorsements_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Endorsements' do +RSpec.describe 'Endorsements' do let(:user) { Fabricate(:user) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:headers) { { 'Authorization' => "Bearer #{token.token}" } } diff --git a/spec/requests/api/v1/featured_tags/suggestions_spec.rb b/spec/requests/api/v1/featured_tags/suggestions_spec.rb index 00451540ca..0a7bfe5cda 100644 --- a/spec/requests/api/v1/featured_tags/suggestions_spec.rb +++ b/spec/requests/api/v1/featured_tags/suggestions_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Featured Tags Suggestions API' do +RSpec.describe 'Featured Tags Suggestions API' do let(:user) { Fabricate(:user) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:scopes) { 'read:accounts' } diff --git a/spec/requests/api/v1/instance_spec.rb b/spec/requests/api/v1/instance_spec.rb index 9cac280c4d..f0a4ceadb8 100644 --- a/spec/requests/api/v1/instance_spec.rb +++ b/spec/requests/api/v1/instance_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Instances' do +RSpec.describe 'Instances' do let(:user) { Fabricate(:user) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id) } let(:headers) { { 'Authorization' => "Bearer #{token.token}" } } diff --git a/spec/requests/api/v1/instances/translation_languages_spec.rb b/spec/requests/api/v1/instances/translation_languages_spec.rb index 7cfb24e86f..e5a480c175 100644 --- a/spec/requests/api/v1/instances/translation_languages_spec.rb +++ b/spec/requests/api/v1/instances/translation_languages_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Translation Languages' do +RSpec.describe 'Translation Languages' do describe 'GET /api/v1/instances/translation_languages' do context 'when no translation service is configured' do it 'returns empty language matrix', :aggregate_failures do diff --git a/spec/requests/api/v1/peers/search_spec.rb b/spec/requests/api/v1/peers/search_spec.rb index dcdea387a5..87b0dc4f64 100644 --- a/spec/requests/api/v1/peers/search_spec.rb +++ b/spec/requests/api/v1/peers/search_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'API Peers Search' do +RSpec.describe 'API Peers Search' do describe 'GET /api/v1/peers/search' do context 'when peers api is disabled' do before do diff --git a/spec/requests/api/v1/preferences_spec.rb b/spec/requests/api/v1/preferences_spec.rb index 6f4188c35a..6508b51c04 100644 --- a/spec/requests/api/v1/preferences_spec.rb +++ b/spec/requests/api/v1/preferences_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Preferences' do +RSpec.describe 'Preferences' do let(:user) { Fabricate(:user) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:headers) { { 'Authorization' => "Bearer #{token.token}" } } diff --git a/spec/requests/api/v1/push/subscriptions_spec.rb b/spec/requests/api/v1/push/subscriptions_spec.rb index 54ef5a13ad..6674b048e8 100644 --- a/spec/requests/api/v1/push/subscriptions_spec.rb +++ b/spec/requests/api/v1/push/subscriptions_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'API V1 Push Subscriptions' do +RSpec.describe 'API V1 Push Subscriptions' do let(:user) { Fabricate(:user) } let(:endpoint) { 'https://fcm.googleapis.com/fcm/send/fiuH06a27qE:APA91bHnSiGcLwdaxdyqVXNDR9w1NlztsHb6lyt5WDKOC_Z_Q8BlFxQoR8tWFSXUIDdkyw0EdvxTu63iqamSaqVSevW5LfoFwojws8XYDXv_NRRLH6vo2CdgiN4jgHv5VLt2A8ah6lUX' } let(:keys) do diff --git a/spec/requests/api/v1/scheduled_status_spec.rb b/spec/requests/api/v1/scheduled_status_spec.rb index f4612410bf..b35d297a60 100644 --- a/spec/requests/api/v1/scheduled_status_spec.rb +++ b/spec/requests/api/v1/scheduled_status_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Scheduled Statuses' do +RSpec.describe 'Scheduled Statuses' do let(:user) { Fabricate(:user) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:headers) { { 'Authorization' => "Bearer #{token.token}" } } diff --git a/spec/requests/api/v1/statuses/histories_spec.rb b/spec/requests/api/v1/statuses/histories_spec.rb index b3761ca688..f13bf79867 100644 --- a/spec/requests/api/v1/statuses/histories_spec.rb +++ b/spec/requests/api/v1/statuses/histories_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'API V1 Statuses Histories' do +RSpec.describe 'API V1 Statuses Histories' do let(:user) { Fabricate(:user) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:scopes) { 'read:statuses' } diff --git a/spec/requests/api/v1/statuses/mutes_spec.rb b/spec/requests/api/v1/statuses/mutes_spec.rb index 72fd7d9d11..69ae948852 100644 --- a/spec/requests/api/v1/statuses/mutes_spec.rb +++ b/spec/requests/api/v1/statuses/mutes_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'API V1 Statuses Mutes' do +RSpec.describe 'API V1 Statuses Mutes' do let(:user) { Fabricate(:user) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:scopes) { 'write:mutes' } diff --git a/spec/requests/api/v1/statuses/pins_spec.rb b/spec/requests/api/v1/statuses/pins_spec.rb index db07fa424f..3be1a16ee1 100644 --- a/spec/requests/api/v1/statuses/pins_spec.rb +++ b/spec/requests/api/v1/statuses/pins_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Pins' do +RSpec.describe 'Pins' do let(:user) { Fabricate(:user) } let(:scopes) { 'write:accounts' } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } diff --git a/spec/requests/api/v1/statuses/reblogs_spec.rb b/spec/requests/api/v1/statuses/reblogs_spec.rb index 77542d294e..0978c890a4 100644 --- a/spec/requests/api/v1/statuses/reblogs_spec.rb +++ b/spec/requests/api/v1/statuses/reblogs_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'API V1 Statuses Reblogs' do +RSpec.describe 'API V1 Statuses Reblogs' do let(:user) { Fabricate(:user) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:scopes) { 'write:statuses' } diff --git a/spec/requests/api/v1/statuses/translations_spec.rb b/spec/requests/api/v1/statuses/translations_spec.rb index e2ab5d0b80..047b2f0485 100644 --- a/spec/requests/api/v1/statuses/translations_spec.rb +++ b/spec/requests/api/v1/statuses/translations_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'API V1 Statuses Translations' do +RSpec.describe 'API V1 Statuses Translations' do let(:user) { Fabricate(:user) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:scopes) { 'read:statuses' } diff --git a/spec/requests/api/v1/statuses_spec.rb b/spec/requests/api/v1/statuses_spec.rb index 3e91fcdd98..1a211d14d8 100644 --- a/spec/requests/api/v1/statuses_spec.rb +++ b/spec/requests/api/v1/statuses_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe '/api/v1/statuses' do +RSpec.describe '/api/v1/statuses' do context 'with an oauth token' do let(:user) { Fabricate(:user) } let(:client_app) { Fabricate(:application, name: 'Test app', website: 'http://testapp.com') } diff --git a/spec/requests/api/v1/streaming_spec.rb b/spec/requests/api/v1/streaming_spec.rb index 6ce35c2fe6..a1f64846cf 100644 --- a/spec/requests/api/v1/streaming_spec.rb +++ b/spec/requests/api/v1/streaming_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'API V1 Streaming' do +RSpec.describe 'API V1 Streaming' do around do |example| before = Rails.configuration.x.streaming_api_base_url Rails.configuration.x.streaming_api_base_url = "wss://#{Rails.configuration.x.web_domain}" diff --git a/spec/requests/api/v1/timelines/home_spec.rb b/spec/requests/api/v1/timelines/home_spec.rb index 96bd153aff..d158e0801c 100644 --- a/spec/requests/api/v1/timelines/home_spec.rb +++ b/spec/requests/api/v1/timelines/home_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Home', :inline_jobs do +RSpec.describe 'Home', :inline_jobs do let(:user) { Fabricate(:user) } let(:scopes) { 'read:statuses' } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } diff --git a/spec/requests/api/v1/timelines/link_spec.rb b/spec/requests/api/v1/timelines/link_spec.rb index e1c914ab81..67d8bca022 100644 --- a/spec/requests/api/v1/timelines/link_spec.rb +++ b/spec/requests/api/v1/timelines/link_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Link' do +RSpec.describe 'Link' do let(:user) { Fabricate(:user) } let(:scopes) { 'read:statuses' } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } diff --git a/spec/requests/api/v1/timelines/list_spec.rb b/spec/requests/api/v1/timelines/list_spec.rb index 98d2456745..753c784866 100644 --- a/spec/requests/api/v1/timelines/list_spec.rb +++ b/spec/requests/api/v1/timelines/list_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'API V1 Timelines List' do +RSpec.describe 'API V1 Timelines List' do let(:user) { Fabricate(:user) } let(:scopes) { 'read:statuses' } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } diff --git a/spec/requests/api/v1/timelines/public_spec.rb b/spec/requests/api/v1/timelines/public_spec.rb index 100f6c1bfc..1fc62b3932 100644 --- a/spec/requests/api/v1/timelines/public_spec.rb +++ b/spec/requests/api/v1/timelines/public_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Public' do +RSpec.describe 'Public' do let(:user) { Fabricate(:user) } let(:scopes) { 'read:statuses' } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } diff --git a/spec/requests/api/v2/instance_spec.rb b/spec/requests/api/v2/instance_spec.rb index 2636970d6e..2f01db5003 100644 --- a/spec/requests/api/v2/instance_spec.rb +++ b/spec/requests/api/v2/instance_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Instances' do +RSpec.describe 'Instances' do let(:user) { Fabricate(:user) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id) } let(:headers) { { 'Authorization' => "Bearer #{token.token}" } } diff --git a/spec/requests/api/v2/search_spec.rb b/spec/requests/api/v2/search_spec.rb index 13bcf17984..039e7513cd 100644 --- a/spec/requests/api/v2/search_spec.rb +++ b/spec/requests/api/v2/search_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Search API' do +RSpec.describe 'Search API' do context 'with token' do let(:user) { Fabricate(:user) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } diff --git a/spec/requests/api/v2/suggestions_spec.rb b/spec/requests/api/v2/suggestions_spec.rb index a7d6a0864f..8895efd23d 100644 --- a/spec/requests/api/v2/suggestions_spec.rb +++ b/spec/requests/api/v2/suggestions_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Suggestions API' do +RSpec.describe 'Suggestions API' do let(:user) { Fabricate(:user) } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } let(:scopes) { 'read' } diff --git a/spec/requests/backups_spec.rb b/spec/requests/backups_spec.rb index a6c2efe0db..a8c1124ed2 100644 --- a/spec/requests/backups_spec.rb +++ b/spec/requests/backups_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Backups' do +RSpec.describe 'Backups' do include RoutingHelper describe 'GET backups#download' do diff --git a/spec/requests/cache_spec.rb b/spec/requests/cache_spec.rb index 91e5b022e3..9cce241b38 100644 --- a/spec/requests/cache_spec.rb +++ b/spec/requests/cache_spec.rb @@ -118,7 +118,7 @@ module TestEndpoints end end -describe 'Caching behavior' do +RSpec.describe 'Caching behavior' do shared_examples 'cachable response' do |http_success: false| it 'does not set cookies or set public cache control', :aggregate_failures do expect(response.cookies).to be_empty diff --git a/spec/requests/catch_all_route_request_spec.rb b/spec/requests/catch_all_route_request_spec.rb index e600bedfe0..e7ea21524c 100644 --- a/spec/requests/catch_all_route_request_spec.rb +++ b/spec/requests/catch_all_route_request_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'The catch all route' do +RSpec.describe 'The catch all route' do describe 'with a simple value' do it 'returns a 404 page as html' do get '/test' diff --git a/spec/requests/content_security_policy_spec.rb b/spec/requests/content_security_policy_spec.rb index ba6fe47741..7520ecb0db 100644 --- a/spec/requests/content_security_policy_spec.rb +++ b/spec/requests/content_security_policy_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Content-Security-Policy' do +RSpec.describe 'Content-Security-Policy' do before { allow(SecureRandom).to receive(:base64).with(16).and_return('ZbA+JmE7+bK8F5qvADZHuQ==') } it 'sets the expected CSP headers' do diff --git a/spec/requests/custom_css_spec.rb b/spec/requests/custom_css_spec.rb index 5271ed4a5a..a46ebd7281 100644 --- a/spec/requests/custom_css_spec.rb +++ b/spec/requests/custom_css_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Custom CSS' do +RSpec.describe 'Custom CSS' do include RoutingHelper describe 'GET /custom.css' do diff --git a/spec/requests/custom_stylesheets_spec.rb b/spec/requests/custom_stylesheets_spec.rb index 128d173f3a..9c5c058344 100644 --- a/spec/requests/custom_stylesheets_spec.rb +++ b/spec/requests/custom_stylesheets_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Custom stylesheets' do +RSpec.describe 'Custom stylesheets' do describe 'GET /custom.css' do before { get '/custom.css' } diff --git a/spec/requests/disabled_oauth_endpoints_spec.rb b/spec/requests/disabled_oauth_endpoints_spec.rb index 7c2c09f380..279d2576a3 100644 --- a/spec/requests/disabled_oauth_endpoints_spec.rb +++ b/spec/requests/disabled_oauth_endpoints_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Disabled OAuth routes' do +RSpec.describe 'Disabled OAuth routes' do # These routes are disabled via the doorkeeper configuration for # `admin_authenticator`, as these routes should only be accessible by server # administrators. For now, these routes are not properly designed and diff --git a/spec/requests/emojis_spec.rb b/spec/requests/emojis_spec.rb index 458d500762..b2e4702f2d 100644 --- a/spec/requests/emojis_spec.rb +++ b/spec/requests/emojis_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Emojis' do +RSpec.describe 'Emojis' do describe 'GET /emojis/:id' do let(:emoji) { Fabricate(:custom_emoji, shortcode: 'coolcat') } diff --git a/spec/requests/health_spec.rb b/spec/requests/health_spec.rb index 03317f9723..1d2f96bb3d 100644 --- a/spec/requests/health_spec.rb +++ b/spec/requests/health_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Health check endpoint' do +RSpec.describe 'Health check endpoint' do describe 'GET /health' do it 'returns http success when server is functioning' do get '/health' diff --git a/spec/requests/invite_spec.rb b/spec/requests/invite_spec.rb index c44ef2419c..4ce6c78e94 100644 --- a/spec/requests/invite_spec.rb +++ b/spec/requests/invite_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'invites' do +RSpec.describe 'invites' do let(:invite) { Fabricate(:invite) } context 'when requesting a JSON document' do diff --git a/spec/requests/link_headers_spec.rb b/spec/requests/link_headers_spec.rb index 522cff4642..3116a54d6a 100644 --- a/spec/requests/link_headers_spec.rb +++ b/spec/requests/link_headers_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Link headers' do +RSpec.describe 'Link headers' do describe 'on the account show page' do let(:account) { Fabricate(:account, username: 'test') } diff --git a/spec/requests/localization_spec.rb b/spec/requests/localization_spec.rb index b7fb53ed8d..26fc204ea4 100644 --- a/spec/requests/localization_spec.rb +++ b/spec/requests/localization_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Localization' do +RSpec.describe 'Localization' do around do |example| I18n.with_locale(I18n.locale) do example.run diff --git a/spec/requests/log_out_spec.rb b/spec/requests/log_out_spec.rb index 62ca1ac547..62ede0c106 100644 --- a/spec/requests/log_out_spec.rb +++ b/spec/requests/log_out_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Log Out' do +RSpec.describe 'Log Out' do include RoutingHelper describe 'DELETE /auth/sign_out' do diff --git a/spec/requests/manifest_spec.rb b/spec/requests/manifest_spec.rb index 55b8147d7e..69e308e3ce 100644 --- a/spec/requests/manifest_spec.rb +++ b/spec/requests/manifest_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Manifest' do +RSpec.describe 'Manifest' do describe 'GET /manifest' do before { get '/manifest' } diff --git a/spec/requests/media_proxy_spec.rb b/spec/requests/media_proxy_spec.rb index 814d4c1166..fb4801ee67 100644 --- a/spec/requests/media_proxy_spec.rb +++ b/spec/requests/media_proxy_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Media Proxy' do +RSpec.describe 'Media Proxy' do describe 'GET /media_proxy/:id' do before { stub_attachment_request } diff --git a/spec/requests/omniauth_callbacks_spec.rb b/spec/requests/omniauth_callbacks_spec.rb index 095535e485..e13a49ec62 100644 --- a/spec/requests/omniauth_callbacks_spec.rb +++ b/spec/requests/omniauth_callbacks_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'OmniAuth callbacks' do +RSpec.describe 'OmniAuth callbacks' do shared_examples 'omniauth provider callbacks' do |provider| subject { post send :"user_#{provider}_omniauth_callback_path" } diff --git a/spec/requests/remote_interaction_helper_spec.rb b/spec/requests/remote_interaction_helper_spec.rb index e6364fe8ce..942f70b9a4 100644 --- a/spec/requests/remote_interaction_helper_spec.rb +++ b/spec/requests/remote_interaction_helper_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Remote Interaction Helper' do +RSpec.describe 'Remote Interaction Helper' do describe 'GET /remote_interaction_helper' do it 'returns http success' do get remote_interaction_helper_path diff --git a/spec/requests/self_destruct_spec.rb b/spec/requests/self_destruct_spec.rb index f71a2325e2..651a894c89 100644 --- a/spec/requests/self_destruct_spec.rb +++ b/spec/requests/self_destruct_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Self-destruct mode' do +RSpec.describe 'Self-destruct mode' do before do allow(SelfDestructHelper).to receive(:self_destruct?).and_return(true) end diff --git a/spec/requests/settings/exports/blocked_accounts_spec.rb b/spec/requests/settings/exports/blocked_accounts_spec.rb index f335ba18c0..9d0768a1e3 100644 --- a/spec/requests/settings/exports/blocked_accounts_spec.rb +++ b/spec/requests/settings/exports/blocked_accounts_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Settings / Exports / Blocked Accounts' do +RSpec.describe 'Settings / Exports / Blocked Accounts' do describe 'GET /settings/exports/blocks' do context 'with a signed in user who has blocked accounts' do let(:user) { Fabricate :user } diff --git a/spec/requests/settings/exports/blocked_domains_spec.rb b/spec/requests/settings/exports/blocked_domains_spec.rb index 762907585f..838baf8cdb 100644 --- a/spec/requests/settings/exports/blocked_domains_spec.rb +++ b/spec/requests/settings/exports/blocked_domains_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Settings / Exports / Blocked Domains' do +RSpec.describe 'Settings / Exports / Blocked Domains' do describe 'GET /settings/exports/domain_blocks' do context 'with a signed in user who has blocked domains' do let(:account) { Fabricate :account, domain: 'example.com' } diff --git a/spec/requests/settings/exports/bookmarks_spec.rb b/spec/requests/settings/exports/bookmarks_spec.rb index f200e70383..e97f4a84d2 100644 --- a/spec/requests/settings/exports/bookmarks_spec.rb +++ b/spec/requests/settings/exports/bookmarks_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Settings / Exports / Bookmarks' do +RSpec.describe 'Settings / Exports / Bookmarks' do describe 'GET /settings/exports/bookmarks' do context 'with a signed in user who has bookmarks' do let(:account) { Fabricate(:account, domain: 'foo.bar') } diff --git a/spec/requests/settings/exports/following_accounts_spec.rb b/spec/requests/settings/exports/following_accounts_spec.rb index 268b72c412..c34ec261a6 100644 --- a/spec/requests/settings/exports/following_accounts_spec.rb +++ b/spec/requests/settings/exports/following_accounts_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Settings / Exports / Following Accounts' do +RSpec.describe 'Settings / Exports / Following Accounts' do describe 'GET /settings/exports/follows' do context 'with a signed in user who is following accounts' do let(:user) { Fabricate :user } diff --git a/spec/requests/settings/exports/lists_spec.rb b/spec/requests/settings/exports/lists_spec.rb index b868f8dfda..4c13225bb9 100644 --- a/spec/requests/settings/exports/lists_spec.rb +++ b/spec/requests/settings/exports/lists_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Settings / Exports / Lists' do +RSpec.describe 'Settings / Exports / Lists' do describe 'GET /settings/exports/lists' do context 'with a signed in user who has lists' do let(:account) { Fabricate(:account, username: 'test', domain: 'example.com') } diff --git a/spec/requests/settings/exports/muted_accounts_spec.rb b/spec/requests/settings/exports/muted_accounts_spec.rb index efdb0d8221..98ccb3e4a2 100644 --- a/spec/requests/settings/exports/muted_accounts_spec.rb +++ b/spec/requests/settings/exports/muted_accounts_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Settings / Exports / Muted Accounts' do +RSpec.describe 'Settings / Exports / Muted Accounts' do describe 'GET /settings/exports/mutes' do context 'with a signed in user who has muted accounts' do let(:user) { Fabricate :user } diff --git a/spec/requests/signature_verification_spec.rb b/spec/requests/signature_verification_spec.rb index 401828c4a3..580d028338 100644 --- a/spec/requests/signature_verification_spec.rb +++ b/spec/requests/signature_verification_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'signature verification concern' do +RSpec.describe 'signature verification concern' do before do stub_tests_controller diff --git a/spec/requests/well_known/change_password_spec.rb b/spec/requests/well_known/change_password_spec.rb index 04134b71ff..77fec15412 100644 --- a/spec/requests/well_known/change_password_spec.rb +++ b/spec/requests/well_known/change_password_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'The /.well-known/change-password request' do +RSpec.describe 'The /.well-known/change-password request' do it 'redirects to the change password page' do get '/.well-known/change-password' diff --git a/spec/requests/well_known/host_meta_spec.rb b/spec/requests/well_known/host_meta_spec.rb index ca10a51a01..09f17baa89 100644 --- a/spec/requests/well_known/host_meta_spec.rb +++ b/spec/requests/well_known/host_meta_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'The /.well-known/host-meta request' do +RSpec.describe 'The /.well-known/host-meta request' do it 'returns http success with valid XML response' do get '/.well-known/host-meta' diff --git a/spec/requests/well_known/node_info_spec.rb b/spec/requests/well_known/node_info_spec.rb index 0934b0fde6..d02732c32b 100644 --- a/spec/requests/well_known/node_info_spec.rb +++ b/spec/requests/well_known/node_info_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'The well-known node-info endpoints' do +RSpec.describe 'The well-known node-info endpoints' do describe 'The /.well-known/node-info endpoint' do it 'returns JSON document pointing to node info' do get '/.well-known/nodeinfo' diff --git a/spec/requests/well_known/oauth_metadata_spec.rb b/spec/requests/well_known/oauth_metadata_spec.rb index 9d2d202286..378295b5a3 100644 --- a/spec/requests/well_known/oauth_metadata_spec.rb +++ b/spec/requests/well_known/oauth_metadata_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'The /.well-known/oauth-authorization-server request' do +RSpec.describe 'The /.well-known/oauth-authorization-server request' do let(:protocol) { ENV.fetch('LOCAL_HTTPS', true) ? :https : :http } before do diff --git a/spec/requests/well_known/webfinger_spec.rb b/spec/requests/well_known/webfinger_spec.rb index cd8a35c702..e5ce352d50 100644 --- a/spec/requests/well_known/webfinger_spec.rb +++ b/spec/requests/well_known/webfinger_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'The /.well-known/webfinger endpoint' do +RSpec.describe 'The /.well-known/webfinger endpoint' do subject(:perform_request!) { get webfinger_url(resource: resource) } let(:alternate_domains) { [] } diff --git a/spec/routing/accounts_routing_spec.rb b/spec/routing/accounts_routing_spec.rb index 588855943e..8ff711a681 100644 --- a/spec/routing/accounts_routing_spec.rb +++ b/spec/routing/accounts_routing_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Routes under accounts/' do +RSpec.describe 'Routes under accounts/' do context 'with local username' do let(:username) { 'alice' } diff --git a/spec/routing/api_routing_spec.rb b/spec/routing/api_routing_spec.rb index a822fba4c5..c46fa75d1f 100644 --- a/spec/routing/api_routing_spec.rb +++ b/spec/routing/api_routing_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'API routes' do +RSpec.describe 'API routes' do describe 'Credentials routes' do it 'routes to verify credentials' do expect(get('/api/v1/accounts/verify_credentials')) diff --git a/spec/routing/well_known_routes_spec.rb b/spec/routing/well_known_routes_spec.rb index 8cf08c13c1..6578e939ae 100644 --- a/spec/routing/well_known_routes_spec.rb +++ b/spec/routing/well_known_routes_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Well Known routes' do +RSpec.describe 'Well Known routes' do describe 'the host-meta route' do it 'routes to correct place with xml format' do expect(get('/.well-known/host-meta')) diff --git a/spec/search/models/concerns/account/search_spec.rb b/spec/search/models/concerns/account/search_spec.rb index d8d7f355dd..de12161ef9 100644 --- a/spec/search/models/concerns/account/search_spec.rb +++ b/spec/search/models/concerns/account/search_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Account::Search do +RSpec.describe Account::Search do describe 'a non-discoverable account becoming discoverable' do let(:account) { Account.find_by(username: 'search_test_account_1') } diff --git a/spec/search/models/concerns/account/statuses_search_spec.rb b/spec/search/models/concerns/account/statuses_search_spec.rb index b1bf4968ca..bce1aecd75 100644 --- a/spec/search/models/concerns/account/statuses_search_spec.rb +++ b/spec/search/models/concerns/account/statuses_search_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Account::StatusesSearch, :inline_jobs do +RSpec.describe Account::StatusesSearch, :inline_jobs do describe 'a non-indexable account becoming indexable' do let(:account) { Account.find_by(username: 'search_test_account_1') } diff --git a/spec/serializers/activitypub/device_serializer_spec.rb b/spec/serializers/activitypub/device_serializer_spec.rb index 23f0b24c4e..226e136446 100644 --- a/spec/serializers/activitypub/device_serializer_spec.rb +++ b/spec/serializers/activitypub/device_serializer_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ActivityPub::DeviceSerializer do +RSpec.describe ActivityPub::DeviceSerializer do let(:serialization) { serialized_record_json(record, described_class) } let(:record) { Fabricate(:device) } diff --git a/spec/serializers/activitypub/note_serializer_spec.rb b/spec/serializers/activitypub/note_serializer_spec.rb index 338d66b308..285b241ee2 100644 --- a/spec/serializers/activitypub/note_serializer_spec.rb +++ b/spec/serializers/activitypub/note_serializer_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ActivityPub::NoteSerializer do +RSpec.describe ActivityPub::NoteSerializer do subject { serialized_record_json(parent, described_class, adapter: ActivityPub::Adapter) } let!(:account) { Fabricate(:account) } diff --git a/spec/serializers/activitypub/one_time_key_serializer_spec.rb b/spec/serializers/activitypub/one_time_key_serializer_spec.rb index 89efe95c8c..b9792ebae3 100644 --- a/spec/serializers/activitypub/one_time_key_serializer_spec.rb +++ b/spec/serializers/activitypub/one_time_key_serializer_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ActivityPub::OneTimeKeySerializer do +RSpec.describe ActivityPub::OneTimeKeySerializer do let(:serialization) { serialized_record_json(record, described_class) } let(:record) { Fabricate(:one_time_key) } diff --git a/spec/serializers/activitypub/undo_like_serializer_spec.rb b/spec/serializers/activitypub/undo_like_serializer_spec.rb index 3d61e86751..c7190adc1a 100644 --- a/spec/serializers/activitypub/undo_like_serializer_spec.rb +++ b/spec/serializers/activitypub/undo_like_serializer_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ActivityPub::UndoLikeSerializer do +RSpec.describe ActivityPub::UndoLikeSerializer do let(:serialization) { serialized_record_json(record, described_class) } let(:record) { Fabricate(:favourite) } diff --git a/spec/serializers/activitypub/update_poll_serializer_spec.rb b/spec/serializers/activitypub/update_poll_serializer_spec.rb index 8ff4fd2701..6a4d8177fc 100644 --- a/spec/serializers/activitypub/update_poll_serializer_spec.rb +++ b/spec/serializers/activitypub/update_poll_serializer_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ActivityPub::UpdatePollSerializer do +RSpec.describe ActivityPub::UpdatePollSerializer do subject { serialized_record_json(status, described_class, adapter: ActivityPub::Adapter) } let(:account) { Fabricate(:account) } diff --git a/spec/serializers/activitypub/vote_serializer_spec.rb b/spec/serializers/activitypub/vote_serializer_spec.rb index b7c0b8928b..4e8a2beca3 100644 --- a/spec/serializers/activitypub/vote_serializer_spec.rb +++ b/spec/serializers/activitypub/vote_serializer_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ActivityPub::VoteSerializer do +RSpec.describe ActivityPub::VoteSerializer do let(:serialization) { serialized_record_json(record, described_class) } let(:record) { Fabricate(:poll_vote) } diff --git a/spec/serializers/rest/account_serializer_spec.rb b/spec/serializers/rest/account_serializer_spec.rb index 15939e484d..7daa0796a9 100644 --- a/spec/serializers/rest/account_serializer_spec.rb +++ b/spec/serializers/rest/account_serializer_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe REST::AccountSerializer do +RSpec.describe REST::AccountSerializer do subject { serialized_record_json(account, described_class) } let(:role) { Fabricate(:user_role, name: 'Role', highlighted: true) } diff --git a/spec/serializers/rest/encrypted_message_serializer_spec.rb b/spec/serializers/rest/encrypted_message_serializer_spec.rb index 01db1149af..a4b8ee83b2 100644 --- a/spec/serializers/rest/encrypted_message_serializer_spec.rb +++ b/spec/serializers/rest/encrypted_message_serializer_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe REST::EncryptedMessageSerializer do +RSpec.describe REST::EncryptedMessageSerializer do let(:serialization) { serialized_record_json(record, described_class) } let(:record) { Fabricate(:encrypted_message) } diff --git a/spec/serializers/rest/instance_serializer_spec.rb b/spec/serializers/rest/instance_serializer_spec.rb index 39e6b3820b..2d8d14e39a 100644 --- a/spec/serializers/rest/instance_serializer_spec.rb +++ b/spec/serializers/rest/instance_serializer_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe REST::InstanceSerializer do +RSpec.describe REST::InstanceSerializer do let(:serialization) { serialized_record_json(record, described_class) } let(:record) { InstancePresenter.new } diff --git a/spec/serializers/rest/keys/claim_result_serializer_spec.rb b/spec/serializers/rest/keys/claim_result_serializer_spec.rb index 7f7fb850cd..e45112705b 100644 --- a/spec/serializers/rest/keys/claim_result_serializer_spec.rb +++ b/spec/serializers/rest/keys/claim_result_serializer_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe REST::Keys::ClaimResultSerializer do +RSpec.describe REST::Keys::ClaimResultSerializer do let(:serialization) { serialized_record_json(record, described_class) } let(:record) { Keys::ClaimService::Result.new(Account.new(id: 123), 456) } diff --git a/spec/serializers/rest/keys/device_serializer_spec.rb b/spec/serializers/rest/keys/device_serializer_spec.rb index 28177a3db5..b8370beac7 100644 --- a/spec/serializers/rest/keys/device_serializer_spec.rb +++ b/spec/serializers/rest/keys/device_serializer_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe REST::Keys::DeviceSerializer do +RSpec.describe REST::Keys::DeviceSerializer do let(:serialization) { serialized_record_json(record, described_class) } let(:record) { Device.new(name: 'Device name') } diff --git a/spec/serializers/rest/keys/query_result_serializer_spec.rb b/spec/serializers/rest/keys/query_result_serializer_spec.rb index ef67d70675..41492f5e78 100644 --- a/spec/serializers/rest/keys/query_result_serializer_spec.rb +++ b/spec/serializers/rest/keys/query_result_serializer_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe REST::Keys::QueryResultSerializer do +RSpec.describe REST::Keys::QueryResultSerializer do let(:serialization) { serialized_record_json(record, described_class) } let(:record) { Keys::QueryService::Result.new(Account.new(id: 123), []) } diff --git a/spec/serializers/rest/suggestion_serializer_spec.rb b/spec/serializers/rest/suggestion_serializer_spec.rb index b5efba082d..288d1daa23 100644 --- a/spec/serializers/rest/suggestion_serializer_spec.rb +++ b/spec/serializers/rest/suggestion_serializer_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe REST::SuggestionSerializer do +RSpec.describe REST::SuggestionSerializer do let(:serialization) { serialized_record_json(record, described_class) } let(:record) do AccountSuggestions::Suggestion.new( diff --git a/spec/services/account_search_service_spec.rb b/spec/services/account_search_service_spec.rb index 5ec0885903..7d251641ee 100644 --- a/spec/services/account_search_service_spec.rb +++ b/spec/services/account_search_service_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe AccountSearchService do +RSpec.describe AccountSearchService do describe '#call' do context 'with a query to ignore' do it 'returns empty array for missing query' do diff --git a/spec/services/account_statuses_cleanup_service_spec.rb b/spec/services/account_statuses_cleanup_service_spec.rb index 403c4632d7..857bd4fda4 100644 --- a/spec/services/account_statuses_cleanup_service_spec.rb +++ b/spec/services/account_statuses_cleanup_service_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe AccountStatusesCleanupService do +RSpec.describe AccountStatusesCleanupService do let(:account) { Fabricate(:account, username: 'alice', domain: nil) } let(:account_policy) { Fabricate(:account_statuses_cleanup_policy, account: account) } let!(:unrelated_status) { Fabricate(:status, created_at: 3.years.ago) } diff --git a/spec/services/fetch_oembed_service_spec.rb b/spec/services/fetch_oembed_service_spec.rb index c9f84048b6..52d2b9cf22 100644 --- a/spec/services/fetch_oembed_service_spec.rb +++ b/spec/services/fetch_oembed_service_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe FetchOEmbedService do +RSpec.describe FetchOEmbedService do subject { described_class.new } before do diff --git a/spec/services/resolve_url_service_spec.rb b/spec/services/resolve_url_service_spec.rb index 3d59a55f10..80f2a5a4ba 100644 --- a/spec/services/resolve_url_service_spec.rb +++ b/spec/services/resolve_url_service_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ResolveURLService do +RSpec.describe ResolveURLService do subject { described_class.new } describe '#call' do diff --git a/spec/services/search_service_spec.rb b/spec/services/search_service_spec.rb index 394ee7c3a6..cd4c424630 100644 --- a/spec/services/search_service_spec.rb +++ b/spec/services/search_service_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe SearchService do +RSpec.describe SearchService do subject { described_class.new } describe '#call' do diff --git a/spec/services/unblock_domain_service_spec.rb b/spec/services/unblock_domain_service_spec.rb index 289ddfc218..405fe1cfd2 100644 --- a/spec/services/unblock_domain_service_spec.rb +++ b/spec/services/unblock_domain_service_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe UnblockDomainService do +RSpec.describe UnblockDomainService do subject { described_class.new } describe 'call' do diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 2d20239b27..60bec918ea 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -6,6 +6,8 @@ RSpec.configure do |config| expectations.include_chain_clauses_in_custom_matcher_descriptions = true end + config.disable_monkey_patching! + config.mock_with :rspec do |mocks| mocks.verify_partial_doubles = true end diff --git a/spec/support/examples/api.rb b/spec/support/examples/api.rb index d531860abf..ddc61fcbe0 100644 --- a/spec/support/examples/api.rb +++ b/spec/support/examples/api.rb @@ -1,6 +1,6 @@ # frozen_string_literal: true -shared_examples 'forbidden for wrong scope' do |wrong_scope| +RSpec.shared_examples 'forbidden for wrong scope' do |wrong_scope| let(:scopes) { wrong_scope } it 'returns http forbidden' do @@ -11,7 +11,7 @@ shared_examples 'forbidden for wrong scope' do |wrong_scope| end end -shared_examples 'forbidden for wrong role' do |wrong_role| +RSpec.shared_examples 'forbidden for wrong role' do |wrong_role| let(:role) { UserRole.find_by(name: wrong_role) } it 'returns http forbidden' do diff --git a/spec/support/examples/cli.rb b/spec/support/examples/cli.rb index 091c842bd1..5f357fc915 100644 --- a/spec/support/examples/cli.rb +++ b/spec/support/examples/cli.rb @@ -1,6 +1,6 @@ # frozen_string_literal: true -shared_examples 'CLI Command' do +RSpec.shared_examples 'CLI Command' do it 'configures Thor to exit on failure' do expect(described_class.exit_on_failure?).to be true end diff --git a/spec/support/examples/lib/admin/checks.rb b/spec/support/examples/lib/admin/checks.rb index b50faa77ba..e8c1336c5f 100644 --- a/spec/support/examples/lib/admin/checks.rb +++ b/spec/support/examples/lib/admin/checks.rb @@ -1,6 +1,6 @@ # frozen_string_literal: true -shared_examples 'a check available to devops users' do +RSpec.shared_examples 'a check available to devops users' do describe 'skip?' do context 'when user can view devops' do before { allow(user).to receive(:can?).with(:view_devops).and_return(true) } diff --git a/spec/support/examples/mailers.rb b/spec/support/examples/mailers.rb index 213e873b4e..a8469f1964 100644 --- a/spec/support/examples/mailers.rb +++ b/spec/support/examples/mailers.rb @@ -1,6 +1,6 @@ # frozen_string_literal: true -shared_examples 'localized subject' do |*args, **kwrest| +RSpec.shared_examples 'localized subject' do |*args, **kwrest| it 'renders subject localized for the locale of the receiver' do locale = :de receiver.update!(locale: locale) diff --git a/spec/support/examples/models/concerns/account_avatar.rb b/spec/support/examples/models/concerns/account_avatar.rb index ab6020d834..232f51fa3c 100644 --- a/spec/support/examples/models/concerns/account_avatar.rb +++ b/spec/support/examples/models/concerns/account_avatar.rb @@ -1,6 +1,6 @@ # frozen_string_literal: true -shared_examples 'AccountAvatar' do |fabricator| +RSpec.shared_examples 'AccountAvatar' do |fabricator| describe 'static avatars', :attachment_processing do describe 'when GIF' do it 'creates a png static style' do diff --git a/spec/support/examples/models/concerns/account_header.rb b/spec/support/examples/models/concerns/account_header.rb index 43bbdaacf4..af8d22d633 100644 --- a/spec/support/examples/models/concerns/account_header.rb +++ b/spec/support/examples/models/concerns/account_header.rb @@ -1,6 +1,6 @@ # frozen_string_literal: true -shared_examples 'AccountHeader' do |fabricator| +RSpec.shared_examples 'AccountHeader' do |fabricator| describe 'base64-encoded files', :attachment_processing do let(:base64_attachment) { "data:image/jpeg;base64,#{Base64.encode64(attachment_fixture('attachment.jpg').read)}" } let(:account) { Fabricate(fabricator, header: base64_attachment) } diff --git a/spec/support/examples/models/concerns/reviewable.rb b/spec/support/examples/models/concerns/reviewable.rb index 562183d1cc..b63e44b43f 100644 --- a/spec/support/examples/models/concerns/reviewable.rb +++ b/spec/support/examples/models/concerns/reviewable.rb @@ -1,6 +1,6 @@ # frozen_string_literal: true -shared_examples 'Reviewable' do +RSpec.shared_examples 'Reviewable' do subject { described_class.new(reviewed_at: reviewed_at, requested_review_at: requested_review_at) } let(:reviewed_at) { nil } diff --git a/spec/system/about_spec.rb b/spec/system/about_spec.rb index dc976b91e0..f832802f91 100644 --- a/spec/system/about_spec.rb +++ b/spec/system/about_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'About page' do +RSpec.describe 'About page' do it 'visits the about page and renders the web app' do visit about_path diff --git a/spec/system/admin/accounts_spec.rb b/spec/system/admin/accounts_spec.rb index 20813f6be4..c21e01e4f3 100644 --- a/spec/system/admin/accounts_spec.rb +++ b/spec/system/admin/accounts_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Admin::Accounts' do +RSpec.describe 'Admin::Accounts' do let(:current_user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } before do diff --git a/spec/system/admin/announcements_spec.rb b/spec/system/admin/announcements_spec.rb index 5c4e5d3e6a..1da5699656 100644 --- a/spec/system/admin/announcements_spec.rb +++ b/spec/system/admin/announcements_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Admin::Announcements' do +RSpec.describe 'Admin::Announcements' do include ActionView::RecordIdentifier describe 'Viewing announcements' do diff --git a/spec/system/admin/custom_emojis_spec.rb b/spec/system/admin/custom_emojis_spec.rb index 8a8b6efcd1..e47f21f8a9 100644 --- a/spec/system/admin/custom_emojis_spec.rb +++ b/spec/system/admin/custom_emojis_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Admin::CustomEmojis' do +RSpec.describe 'Admin::CustomEmojis' do let(:current_user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } before do diff --git a/spec/system/admin/domain_blocks_spec.rb b/spec/system/admin/domain_blocks_spec.rb index 99aa7cf1a7..9a39e29062 100644 --- a/spec/system/admin/domain_blocks_spec.rb +++ b/spec/system/admin/domain_blocks_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'blocking domains through the moderation interface' do +RSpec.describe 'blocking domains through the moderation interface' do before do allow(DomainBlockWorker).to receive(:perform_async).and_return(true) sign_in Fabricate(:user, role: UserRole.find_by(name: 'Admin')), scope: :user diff --git a/spec/system/admin/email_domain_blocks_spec.rb b/spec/system/admin/email_domain_blocks_spec.rb index 14959cbe74..a90bede827 100644 --- a/spec/system/admin/email_domain_blocks_spec.rb +++ b/spec/system/admin/email_domain_blocks_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Admin::EmailDomainBlocks' do +RSpec.describe 'Admin::EmailDomainBlocks' do let(:current_user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } before do diff --git a/spec/system/admin/ip_blocks_spec.rb b/spec/system/admin/ip_blocks_spec.rb index c9b16f6f78..9c03520277 100644 --- a/spec/system/admin/ip_blocks_spec.rb +++ b/spec/system/admin/ip_blocks_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Admin::IpBlocks' do +RSpec.describe 'Admin::IpBlocks' do let(:current_user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } before do diff --git a/spec/system/admin/reset_spec.rb b/spec/system/admin/reset_spec.rb index 50fb4b46df..1e787ea110 100644 --- a/spec/system/admin/reset_spec.rb +++ b/spec/system/admin/reset_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Admin::Reset' do +RSpec.describe 'Admin::Reset' do it 'Resets password for account user' do account = Fabricate :account sign_in admin_user diff --git a/spec/system/admin/settings/about_spec.rb b/spec/system/admin/settings/about_spec.rb index 0f8ae5605c..c7405a8d5a 100644 --- a/spec/system/admin/settings/about_spec.rb +++ b/spec/system/admin/settings/about_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Admin::Settings::About' do +RSpec.describe 'Admin::Settings::About' do it 'Saves changes to about settings' do sign_in admin_user visit admin_settings_about_path diff --git a/spec/system/admin/settings/appearance_spec.rb b/spec/system/admin/settings/appearance_spec.rb index 99e97ea4d1..56af58c812 100644 --- a/spec/system/admin/settings/appearance_spec.rb +++ b/spec/system/admin/settings/appearance_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Admin::Settings::Appearance' do +RSpec.describe 'Admin::Settings::Appearance' do it 'Saves changes to appearance settings' do sign_in admin_user visit admin_settings_appearance_path diff --git a/spec/system/admin/settings/branding_spec.rb b/spec/system/admin/settings/branding_spec.rb index ac47e04d53..5cd9319ce0 100644 --- a/spec/system/admin/settings/branding_spec.rb +++ b/spec/system/admin/settings/branding_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Admin::Settings::Branding' do +RSpec.describe 'Admin::Settings::Branding' do it 'Saves changes to branding settings' do sign_in admin_user visit admin_settings_branding_path diff --git a/spec/system/admin/settings/content_retention_spec.rb b/spec/system/admin/settings/content_retention_spec.rb index 9867122675..f788f8eea0 100644 --- a/spec/system/admin/settings/content_retention_spec.rb +++ b/spec/system/admin/settings/content_retention_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Admin::Settings::ContentRetention' do +RSpec.describe 'Admin::Settings::ContentRetention' do it 'Saves changes to content retention settings' do sign_in admin_user visit admin_settings_content_retention_path diff --git a/spec/system/admin/settings/discovery_spec.rb b/spec/system/admin/settings/discovery_spec.rb index bdab91107d..f000d18370 100644 --- a/spec/system/admin/settings/discovery_spec.rb +++ b/spec/system/admin/settings/discovery_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Admin::Settings::Discovery' do +RSpec.describe 'Admin::Settings::Discovery' do it 'Saves changes to discovery settings' do sign_in admin_user visit admin_settings_discovery_path diff --git a/spec/system/admin/settings/registrations_spec.rb b/spec/system/admin/settings/registrations_spec.rb index 88c750e8ee..d026b07c85 100644 --- a/spec/system/admin/settings/registrations_spec.rb +++ b/spec/system/admin/settings/registrations_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Admin::Settings::Registrations' do +RSpec.describe 'Admin::Settings::Registrations' do it 'Saves changes to registrations settings' do sign_in admin_user visit admin_settings_registrations_path diff --git a/spec/system/admin/software_updates_spec.rb b/spec/system/admin/software_updates_spec.rb index 4a635d1a79..77e9f16684 100644 --- a/spec/system/admin/software_updates_spec.rb +++ b/spec/system/admin/software_updates_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'finding software updates through the admin interface' do +RSpec.describe 'finding software updates through the admin interface' do before do Fabricate(:software_update, version: '99.99.99', type: 'major', urgent: true, release_notes: 'https://github.com/mastodon/mastodon/releases/v99') diff --git a/spec/system/admin/statuses_spec.rb b/spec/system/admin/statuses_spec.rb index 531d0de953..bb76a2963d 100644 --- a/spec/system/admin/statuses_spec.rb +++ b/spec/system/admin/statuses_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Admin::Statuses' do +RSpec.describe 'Admin::Statuses' do let(:current_user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } before do diff --git a/spec/system/admin/trends/links/preview_card_providers_spec.rb b/spec/system/admin/trends/links/preview_card_providers_spec.rb index dca89117b1..16343a6891 100644 --- a/spec/system/admin/trends/links/preview_card_providers_spec.rb +++ b/spec/system/admin/trends/links/preview_card_providers_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Admin::Trends::Links::PreviewCardProviders' do +RSpec.describe 'Admin::Trends::Links::PreviewCardProviders' do let(:current_user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } before do diff --git a/spec/system/admin/trends/links_spec.rb b/spec/system/admin/trends/links_spec.rb index 99638bc069..7a51c337c9 100644 --- a/spec/system/admin/trends/links_spec.rb +++ b/spec/system/admin/trends/links_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Admin::Trends::Links' do +RSpec.describe 'Admin::Trends::Links' do let(:current_user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } before do diff --git a/spec/system/admin/trends/statuses_spec.rb b/spec/system/admin/trends/statuses_spec.rb index 779a15d38f..13fc966dfd 100644 --- a/spec/system/admin/trends/statuses_spec.rb +++ b/spec/system/admin/trends/statuses_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Admin::Trends::Statuses' do +RSpec.describe 'Admin::Trends::Statuses' do let(:current_user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } before do diff --git a/spec/system/admin/trends/tags_spec.rb b/spec/system/admin/trends/tags_spec.rb index 52e49c3a5d..d914badbd4 100644 --- a/spec/system/admin/trends/tags_spec.rb +++ b/spec/system/admin/trends/tags_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Admin::Trends::Tags' do +RSpec.describe 'Admin::Trends::Tags' do let(:current_user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } before do diff --git a/spec/system/captcha_spec.rb b/spec/system/captcha_spec.rb index 06c823adf2..4c0ce02d1b 100644 --- a/spec/system/captcha_spec.rb +++ b/spec/system/captcha_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'email confirmation flow when captcha is enabled' do +RSpec.describe 'email confirmation flow when captcha is enabled' do let(:user) { Fabricate(:user, confirmed_at: nil, confirmation_token: 'foobar', created_by_application: client_app) } let(:client_app) { nil } diff --git a/spec/system/filters_spec.rb b/spec/system/filters_spec.rb index a0cb965a61..052b5e1730 100644 --- a/spec/system/filters_spec.rb +++ b/spec/system/filters_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Filters' do +RSpec.describe 'Filters' do let(:user) { Fabricate(:user) } let(:filter_title) { 'Filter of fun and games' } diff --git a/spec/system/home_spec.rb b/spec/system/home_spec.rb index 08b9737d6b..c1ce4e1726 100644 --- a/spec/system/home_spec.rb +++ b/spec/system/home_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Home page' do +RSpec.describe 'Home page' do context 'when signed in' do before { sign_in Fabricate(:user) } diff --git a/spec/system/log_in_spec.rb b/spec/system/log_in_spec.rb index 8a73c42d2e..f8765e8e1c 100644 --- a/spec/system/log_in_spec.rb +++ b/spec/system/log_in_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Log in' do +RSpec.describe 'Log in' do include ProfileStories subject { page } diff --git a/spec/system/log_out_spec.rb b/spec/system/log_out_spec.rb index f50f7c2d18..2e52254ca0 100644 --- a/spec/system/log_out_spec.rb +++ b/spec/system/log_out_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Log out' do +RSpec.describe 'Log out' do include ProfileStories before do diff --git a/spec/system/new_statuses_spec.rb b/spec/system/new_statuses_spec.rb index 2f2fcf2248..317508a0bb 100644 --- a/spec/system/new_statuses_spec.rb +++ b/spec/system/new_statuses_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'NewStatuses', :inline_jobs, :js, :streaming do +RSpec.describe 'NewStatuses', :inline_jobs, :js, :streaming do include ProfileStories subject { page } diff --git a/spec/system/oauth_spec.rb b/spec/system/oauth_spec.rb index 5d06f6111c..0f96a59675 100644 --- a/spec/system/oauth_spec.rb +++ b/spec/system/oauth_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Using OAuth from an external app' do +RSpec.describe 'Using OAuth from an external app' do include ProfileStories subject { visit "/oauth/authorize?#{params.to_query}" } diff --git a/spec/system/ocr_spec.rb b/spec/system/ocr_spec.rb index 17d18af158..fc816b6dba 100644 --- a/spec/system/ocr_spec.rb +++ b/spec/system/ocr_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'OCR', :attachment_processing, :inline_jobs, :js, :streaming do +RSpec.describe 'OCR', :attachment_processing, :inline_jobs, :js, :streaming do include ProfileStories let(:email) { 'test@example.com' } diff --git a/spec/system/privacy_spec.rb b/spec/system/privacy_spec.rb index f2ab1310cc..631440ebb2 100644 --- a/spec/system/privacy_spec.rb +++ b/spec/system/privacy_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Privacy policy page' do +RSpec.describe 'Privacy policy page' do it 'visits the privacy policy page and renders the web app' do visit privacy_policy_path diff --git a/spec/system/profile_spec.rb b/spec/system/profile_spec.rb index 2517e823b5..7e3cbfd334 100644 --- a/spec/system/profile_spec.rb +++ b/spec/system/profile_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Profile' do +RSpec.describe 'Profile' do include ProfileStories subject { page } diff --git a/spec/system/redirections_spec.rb b/spec/system/redirections_spec.rb index f73ab58470..860bbdd6b7 100644 --- a/spec/system/redirections_spec.rb +++ b/spec/system/redirections_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'redirection confirmations' do +RSpec.describe 'redirection confirmations' do let(:account) { Fabricate(:account, domain: 'example.com', uri: 'https://example.com/users/foo', url: 'https://example.com/@foo') } let(:status) { Fabricate(:status, account: account, uri: 'https://example.com/users/foo/statuses/1', url: 'https://example.com/@foo/1') } diff --git a/spec/system/report_interface_spec.rb b/spec/system/report_interface_spec.rb index e6cc3b1b68..257a1cd6fd 100644 --- a/spec/system/report_interface_spec.rb +++ b/spec/system/report_interface_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'report interface', :attachment_processing, :js, :streaming do +RSpec.describe 'report interface', :attachment_processing, :js, :streaming do include ProfileStories let(:email) { 'admin@example.com' } diff --git a/spec/system/severed_relationships_spec.rb b/spec/system/severed_relationships_spec.rb index b933398a08..4a7bf3e280 100644 --- a/spec/system/severed_relationships_spec.rb +++ b/spec/system/severed_relationships_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Severed relationships page' do +RSpec.describe 'Severed relationships page' do include ProfileStories describe 'GET severed_relationships#index' do diff --git a/spec/system/share_entrypoint_spec.rb b/spec/system/share_entrypoint_spec.rb index 5e27781f2a..7ccfee599a 100644 --- a/spec/system/share_entrypoint_spec.rb +++ b/spec/system/share_entrypoint_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'Share page', :js, :streaming do +RSpec.describe 'Share page', :js, :streaming do include ProfileStories let(:email) { 'test@example.com' } diff --git a/spec/system/unlogged_spec.rb b/spec/system/unlogged_spec.rb index 417ccdaeb6..26d1bd4542 100644 --- a/spec/system/unlogged_spec.rb +++ b/spec/system/unlogged_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'UnloggedBrowsing', :js, :streaming do +RSpec.describe 'UnloggedBrowsing', :js, :streaming do subject { page } before do diff --git a/spec/validators/email_mx_validator_spec.rb b/spec/validators/email_mx_validator_spec.rb index 23a5f768ef..7109c9f4e2 100644 --- a/spec/validators/email_mx_validator_spec.rb +++ b/spec/validators/email_mx_validator_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe EmailMxValidator do +RSpec.describe EmailMxValidator do describe '#validate' do let(:user) { instance_double(User, email: 'foo@example.com', sign_up_ip: '1.2.3.4', errors: instance_double(ActiveModel::Errors, add: nil)) } let(:resolv_dns_double) { instance_double(Resolv::DNS) } diff --git a/spec/validators/existing_username_validator_spec.rb b/spec/validators/existing_username_validator_spec.rb index 4f1dd55a17..25ecb1fbcd 100644 --- a/spec/validators/existing_username_validator_spec.rb +++ b/spec/validators/existing_username_validator_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ExistingUsernameValidator do +RSpec.describe ExistingUsernameValidator do let(:record_class) do Class.new do include ActiveModel::Validations diff --git a/spec/validators/language_validator_spec.rb b/spec/validators/language_validator_spec.rb index cb693dcd81..19e55f3467 100644 --- a/spec/validators/language_validator_spec.rb +++ b/spec/validators/language_validator_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe LanguageValidator do +RSpec.describe LanguageValidator do let(:record_class) do Class.new do include ActiveModel::Validations diff --git a/spec/validators/note_length_validator_spec.rb b/spec/validators/note_length_validator_spec.rb index 3bca93a283..3fdb4ae8b9 100644 --- a/spec/validators/note_length_validator_spec.rb +++ b/spec/validators/note_length_validator_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe NoteLengthValidator do +RSpec.describe NoteLengthValidator do subject { described_class.new(attributes: { note: true }, maximum: 500) } describe '#validate' do diff --git a/spec/validators/reaction_validator_spec.rb b/spec/validators/reaction_validator_spec.rb index f99c1cb5f9..c4d4a51779 100644 --- a/spec/validators/reaction_validator_spec.rb +++ b/spec/validators/reaction_validator_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ReactionValidator do +RSpec.describe ReactionValidator do let(:announcement) { Fabricate(:announcement) } describe '#validate' do diff --git a/spec/validators/status_length_validator_spec.rb b/spec/validators/status_length_validator_spec.rb index 249b90f490..ecbfd4ba37 100644 --- a/spec/validators/status_length_validator_spec.rb +++ b/spec/validators/status_length_validator_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe StatusLengthValidator do +RSpec.describe StatusLengthValidator do describe '#validate' do before { stub_const("#{described_class}::MAX_CHARS", 500) } # Example values below are relative to this baseline diff --git a/spec/validators/unique_username_validator_spec.rb b/spec/validators/unique_username_validator_spec.rb index 0d172c8408..037ddadb9f 100644 --- a/spec/validators/unique_username_validator_spec.rb +++ b/spec/validators/unique_username_validator_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe UniqueUsernameValidator do +RSpec.describe UniqueUsernameValidator do describe '#validate' do context 'when local account' do it 'does not add errors if username is nil' do diff --git a/spec/validators/unreserved_username_validator_spec.rb b/spec/validators/unreserved_username_validator_spec.rb index 0eb5f83683..ad1092109d 100644 --- a/spec/validators/unreserved_username_validator_spec.rb +++ b/spec/validators/unreserved_username_validator_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe UnreservedUsernameValidator do +RSpec.describe UnreservedUsernameValidator do let(:record_class) do Class.new do include ActiveModel::Validations diff --git a/spec/validators/url_validator_spec.rb b/spec/validators/url_validator_spec.rb index 4f32b7b399..2297dddaa0 100644 --- a/spec/validators/url_validator_spec.rb +++ b/spec/validators/url_validator_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe URLValidator do +RSpec.describe URLValidator do let(:record_class) do Class.new do include ActiveModel::Validations diff --git a/spec/views/admin/trends/links/_preview_card.html.haml_spec.rb b/spec/views/admin/trends/links/_preview_card.html.haml_spec.rb index 82a1dee6d7..47a8564eff 100644 --- a/spec/views/admin/trends/links/_preview_card.html.haml_spec.rb +++ b/spec/views/admin/trends/links/_preview_card.html.haml_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'admin/trends/links/_preview_card.html.haml' do +RSpec.describe 'admin/trends/links/_preview_card.html.haml' do it 'correctly escapes user supplied url values' do form = instance_double(ActionView::Helpers::FormHelper, check_box: nil) trend = PreviewCardTrend.new(allowed: false) diff --git a/spec/views/statuses/show.html.haml_spec.rb b/spec/views/statuses/show.html.haml_spec.rb index fd08f2772d..1afcb046d4 100644 --- a/spec/views/statuses/show.html.haml_spec.rb +++ b/spec/views/statuses/show.html.haml_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'statuses/show.html.haml' do +RSpec.describe 'statuses/show.html.haml' do let(:alice) { Fabricate(:account, username: 'alice', display_name: 'Alice') } let(:status) { Fabricate(:status, account: alice, text: 'Hello World') } diff --git a/spec/workers/account_refresh_worker_spec.rb b/spec/workers/account_refresh_worker_spec.rb index 361d69aa0a..3e88e8db28 100644 --- a/spec/workers/account_refresh_worker_spec.rb +++ b/spec/workers/account_refresh_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe AccountRefreshWorker do +RSpec.describe AccountRefreshWorker do let(:worker) { described_class.new } let(:service) { instance_double(ResolveAccountService, call: true) } diff --git a/spec/workers/activitypub/delivery_worker_spec.rb b/spec/workers/activitypub/delivery_worker_spec.rb index efce610ae4..3dfbef31a4 100644 --- a/spec/workers/activitypub/delivery_worker_spec.rb +++ b/spec/workers/activitypub/delivery_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ActivityPub::DeliveryWorker do +RSpec.describe ActivityPub::DeliveryWorker do include RoutingHelper subject { described_class.new } diff --git a/spec/workers/activitypub/distribute_poll_update_worker_spec.rb b/spec/workers/activitypub/distribute_poll_update_worker_spec.rb index 4427cfdf95..9ff4731f96 100644 --- a/spec/workers/activitypub/distribute_poll_update_worker_spec.rb +++ b/spec/workers/activitypub/distribute_poll_update_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ActivityPub::DistributePollUpdateWorker do +RSpec.describe ActivityPub::DistributePollUpdateWorker do subject { described_class.new } let(:account) { Fabricate(:account) } diff --git a/spec/workers/activitypub/distribution_worker_spec.rb b/spec/workers/activitypub/distribution_worker_spec.rb index 0eb6227859..9e5db53185 100644 --- a/spec/workers/activitypub/distribution_worker_spec.rb +++ b/spec/workers/activitypub/distribution_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ActivityPub::DistributionWorker do +RSpec.describe ActivityPub::DistributionWorker do subject { described_class.new } let(:status) { Fabricate(:status) } diff --git a/spec/workers/activitypub/fetch_replies_worker_spec.rb b/spec/workers/activitypub/fetch_replies_worker_spec.rb index 2d080e286e..56d19705a4 100644 --- a/spec/workers/activitypub/fetch_replies_worker_spec.rb +++ b/spec/workers/activitypub/fetch_replies_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ActivityPub::FetchRepliesWorker do +RSpec.describe ActivityPub::FetchRepliesWorker do subject { described_class.new } let(:account) { Fabricate(:account, domain: 'example.com') } diff --git a/spec/workers/activitypub/move_distribution_worker_spec.rb b/spec/workers/activitypub/move_distribution_worker_spec.rb index c810b33c23..63396834de 100644 --- a/spec/workers/activitypub/move_distribution_worker_spec.rb +++ b/spec/workers/activitypub/move_distribution_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ActivityPub::MoveDistributionWorker do +RSpec.describe ActivityPub::MoveDistributionWorker do subject { described_class.new } let(:migration) { Fabricate(:account_migration) } diff --git a/spec/workers/activitypub/post_upgrade_worker_spec.rb b/spec/workers/activitypub/post_upgrade_worker_spec.rb index 08de150ad9..fe1c5e895e 100644 --- a/spec/workers/activitypub/post_upgrade_worker_spec.rb +++ b/spec/workers/activitypub/post_upgrade_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ActivityPub::PostUpgradeWorker do +RSpec.describe ActivityPub::PostUpgradeWorker do let(:worker) { described_class.new } describe '#perform' do diff --git a/spec/workers/activitypub/processing_worker_spec.rb b/spec/workers/activitypub/processing_worker_spec.rb index 66d1cf4890..c06ba63d39 100644 --- a/spec/workers/activitypub/processing_worker_spec.rb +++ b/spec/workers/activitypub/processing_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ActivityPub::ProcessingWorker do +RSpec.describe ActivityPub::ProcessingWorker do subject { described_class.new } let(:account) { Fabricate(:account) } diff --git a/spec/workers/activitypub/status_update_distribution_worker_spec.rb b/spec/workers/activitypub/status_update_distribution_worker_spec.rb index 66e52c4f28..e9a70d11d1 100644 --- a/spec/workers/activitypub/status_update_distribution_worker_spec.rb +++ b/spec/workers/activitypub/status_update_distribution_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ActivityPub::StatusUpdateDistributionWorker do +RSpec.describe ActivityPub::StatusUpdateDistributionWorker do subject { described_class.new } let(:status) { Fabricate(:status, text: 'foo') } diff --git a/spec/workers/activitypub/synchronize_featured_tags_collection_worker_spec.rb b/spec/workers/activitypub/synchronize_featured_tags_collection_worker_spec.rb index 8cf13cb900..d10ea8a75e 100644 --- a/spec/workers/activitypub/synchronize_featured_tags_collection_worker_spec.rb +++ b/spec/workers/activitypub/synchronize_featured_tags_collection_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ActivityPub::SynchronizeFeaturedTagsCollectionWorker do +RSpec.describe ActivityPub::SynchronizeFeaturedTagsCollectionWorker do let(:worker) { described_class.new } let(:service) { instance_double(ActivityPub::FetchFeaturedTagsCollectionService, call: true) } diff --git a/spec/workers/activitypub/update_distribution_worker_spec.rb b/spec/workers/activitypub/update_distribution_worker_spec.rb index b183a58dfd..7d78606398 100644 --- a/spec/workers/activitypub/update_distribution_worker_spec.rb +++ b/spec/workers/activitypub/update_distribution_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ActivityPub::UpdateDistributionWorker do +RSpec.describe ActivityPub::UpdateDistributionWorker do subject { described_class.new } let(:account) { Fabricate(:account) } diff --git a/spec/workers/add_to_public_statuses_index_worker_spec.rb b/spec/workers/add_to_public_statuses_index_worker_spec.rb index fa15072241..edaec1dd3a 100644 --- a/spec/workers/add_to_public_statuses_index_worker_spec.rb +++ b/spec/workers/add_to_public_statuses_index_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe AddToPublicStatusesIndexWorker do +RSpec.describe AddToPublicStatusesIndexWorker do describe '#perform' do let(:account) { Fabricate(:account, indexable: indexable) } let(:account_id) { account.id } diff --git a/spec/workers/admin/account_deletion_worker_spec.rb b/spec/workers/admin/account_deletion_worker_spec.rb index 631cab6648..e41b734f21 100644 --- a/spec/workers/admin/account_deletion_worker_spec.rb +++ b/spec/workers/admin/account_deletion_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::AccountDeletionWorker do +RSpec.describe Admin::AccountDeletionWorker do let(:worker) { described_class.new } describe 'perform' do diff --git a/spec/workers/admin/domain_purge_worker_spec.rb b/spec/workers/admin/domain_purge_worker_spec.rb index 861fd71a7f..32bdd0868b 100644 --- a/spec/workers/admin/domain_purge_worker_spec.rb +++ b/spec/workers/admin/domain_purge_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::DomainPurgeWorker do +RSpec.describe Admin::DomainPurgeWorker do subject { described_class.new } describe 'perform' do diff --git a/spec/workers/admin/suspension_worker_spec.rb b/spec/workers/admin/suspension_worker_spec.rb index da12037edc..445e0b635e 100644 --- a/spec/workers/admin/suspension_worker_spec.rb +++ b/spec/workers/admin/suspension_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Admin::SuspensionWorker do +RSpec.describe Admin::SuspensionWorker do let(:worker) { described_class.new } let(:service) { instance_double(SuspendAccountService, call: true) } diff --git a/spec/workers/after_account_domain_block_worker_spec.rb b/spec/workers/after_account_domain_block_worker_spec.rb index 54a113a2b3..56f5957ea2 100644 --- a/spec/workers/after_account_domain_block_worker_spec.rb +++ b/spec/workers/after_account_domain_block_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe AfterAccountDomainBlockWorker do +RSpec.describe AfterAccountDomainBlockWorker do let(:worker) { described_class.new } let(:service) { instance_double(AfterBlockDomainFromAccountService, call: true) } diff --git a/spec/workers/backup_worker_spec.rb b/spec/workers/backup_worker_spec.rb index db1b50140b..5d1d91267a 100644 --- a/spec/workers/backup_worker_spec.rb +++ b/spec/workers/backup_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe BackupWorker do +RSpec.describe BackupWorker do let(:worker) { described_class.new } let(:service) { instance_double(BackupService, call: true) } diff --git a/spec/workers/bulk_import_worker_spec.rb b/spec/workers/bulk_import_worker_spec.rb index 91f51fbb42..2d429c880b 100644 --- a/spec/workers/bulk_import_worker_spec.rb +++ b/spec/workers/bulk_import_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe BulkImportWorker do +RSpec.describe BulkImportWorker do subject { described_class.new } let(:import) { Fabricate(:bulk_import, state: :scheduled) } diff --git a/spec/workers/cache_buster_worker_spec.rb b/spec/workers/cache_buster_worker_spec.rb index adeb287fa3..b6948395b8 100644 --- a/spec/workers/cache_buster_worker_spec.rb +++ b/spec/workers/cache_buster_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe CacheBusterWorker do +RSpec.describe CacheBusterWorker do let(:worker) { described_class.new } describe 'perform' do diff --git a/spec/workers/delete_mute_worker_spec.rb b/spec/workers/delete_mute_worker_spec.rb index 1fc84491c3..a5d1fe343d 100644 --- a/spec/workers/delete_mute_worker_spec.rb +++ b/spec/workers/delete_mute_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe DeleteMuteWorker do +RSpec.describe DeleteMuteWorker do let(:worker) { described_class.new } let(:service) { instance_double(UnmuteService, call: true) } diff --git a/spec/workers/domain_block_worker_spec.rb b/spec/workers/domain_block_worker_spec.rb index 33c3ca009a..c55aa2c0c3 100644 --- a/spec/workers/domain_block_worker_spec.rb +++ b/spec/workers/domain_block_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe DomainBlockWorker do +RSpec.describe DomainBlockWorker do subject { described_class.new } describe 'perform' do diff --git a/spec/workers/domain_clear_media_worker_spec.rb b/spec/workers/domain_clear_media_worker_spec.rb index 21f8f87b2f..20911007b0 100644 --- a/spec/workers/domain_clear_media_worker_spec.rb +++ b/spec/workers/domain_clear_media_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe DomainClearMediaWorker do +RSpec.describe DomainClearMediaWorker do subject { described_class.new } describe 'perform' do diff --git a/spec/workers/feed_insert_worker_spec.rb b/spec/workers/feed_insert_worker_spec.rb index e9484879ff..92ae304d0e 100644 --- a/spec/workers/feed_insert_worker_spec.rb +++ b/spec/workers/feed_insert_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe FeedInsertWorker do +RSpec.describe FeedInsertWorker do subject { described_class.new } describe 'perform' do diff --git a/spec/workers/filtered_notification_cleanup_worker_spec.rb b/spec/workers/filtered_notification_cleanup_worker_spec.rb index 2636b70ad4..5ecd4291af 100644 --- a/spec/workers/filtered_notification_cleanup_worker_spec.rb +++ b/spec/workers/filtered_notification_cleanup_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe FilteredNotificationCleanupWorker do +RSpec.describe FilteredNotificationCleanupWorker do describe '#perform' do let(:sender) { Fabricate(:account) } let(:recipient) { Fabricate(:account) } diff --git a/spec/workers/import/row_worker_spec.rb b/spec/workers/import/row_worker_spec.rb index 0a71a838fc..edb02cb391 100644 --- a/spec/workers/import/row_worker_spec.rb +++ b/spec/workers/import/row_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Import::RowWorker do +RSpec.describe Import::RowWorker do subject { described_class.new } let(:row) { Fabricate(:bulk_import_row, bulk_import: import) } diff --git a/spec/workers/import_worker_spec.rb b/spec/workers/import_worker_spec.rb index 4095a5d354..1d34aafe86 100644 --- a/spec/workers/import_worker_spec.rb +++ b/spec/workers/import_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ImportWorker do +RSpec.describe ImportWorker do let(:worker) { described_class.new } let(:service) { instance_double(ImportService, call: true) } diff --git a/spec/workers/move_worker_spec.rb b/spec/workers/move_worker_spec.rb index b25992e44b..a24de57e27 100644 --- a/spec/workers/move_worker_spec.rb +++ b/spec/workers/move_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe MoveWorker do +RSpec.describe MoveWorker do subject { described_class.new } let(:local_follower) { Fabricate(:account, domain: nil) } diff --git a/spec/workers/poll_expiration_notify_worker_spec.rb b/spec/workers/poll_expiration_notify_worker_spec.rb index 4bd90270d8..b3ccdd3d77 100644 --- a/spec/workers/poll_expiration_notify_worker_spec.rb +++ b/spec/workers/poll_expiration_notify_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe PollExpirationNotifyWorker do +RSpec.describe PollExpirationNotifyWorker do let(:worker) { described_class.new } let(:account) { Fabricate(:account, domain: remote? ? 'example.com' : nil) } let(:status) { Fabricate(:status, account: account) } diff --git a/spec/workers/post_process_media_worker_spec.rb b/spec/workers/post_process_media_worker_spec.rb index 1a274623d7..f4b441a920 100644 --- a/spec/workers/post_process_media_worker_spec.rb +++ b/spec/workers/post_process_media_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe PostProcessMediaWorker, :attachment_processing do +RSpec.describe PostProcessMediaWorker, :attachment_processing do let(:worker) { described_class.new } describe '#perform' do diff --git a/spec/workers/publish_announcement_reaction_worker_spec.rb b/spec/workers/publish_announcement_reaction_worker_spec.rb index 91668b5ada..37687ca1a8 100644 --- a/spec/workers/publish_announcement_reaction_worker_spec.rb +++ b/spec/workers/publish_announcement_reaction_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe PublishAnnouncementReactionWorker do +RSpec.describe PublishAnnouncementReactionWorker do let(:worker) { described_class.new } describe '#perform' do diff --git a/spec/workers/publish_scheduled_announcement_worker_spec.rb b/spec/workers/publish_scheduled_announcement_worker_spec.rb index 2e50d4a50d..c4e17903a9 100644 --- a/spec/workers/publish_scheduled_announcement_worker_spec.rb +++ b/spec/workers/publish_scheduled_announcement_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe PublishScheduledAnnouncementWorker do +RSpec.describe PublishScheduledAnnouncementWorker do subject { described_class.new } let!(:remote_account) { Fabricate(:account, domain: 'domain.com', username: 'foo', uri: 'https://domain.com/users/foo') } diff --git a/spec/workers/publish_scheduled_status_worker_spec.rb b/spec/workers/publish_scheduled_status_worker_spec.rb index f8547e6fe2..35e510d253 100644 --- a/spec/workers/publish_scheduled_status_worker_spec.rb +++ b/spec/workers/publish_scheduled_status_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe PublishScheduledStatusWorker do +RSpec.describe PublishScheduledStatusWorker do subject { described_class.new } let(:scheduled_status) { Fabricate(:scheduled_status, params: { text: 'Hello world, future!' }) } diff --git a/spec/workers/push_conversation_worker_spec.rb b/spec/workers/push_conversation_worker_spec.rb index 5fbb4c6853..d651059c9a 100644 --- a/spec/workers/push_conversation_worker_spec.rb +++ b/spec/workers/push_conversation_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe PushConversationWorker do +RSpec.describe PushConversationWorker do let(:worker) { described_class.new } describe 'perform' do diff --git a/spec/workers/push_encrypted_message_worker_spec.rb b/spec/workers/push_encrypted_message_worker_spec.rb index 3cd04ce7b4..311545cf56 100644 --- a/spec/workers/push_encrypted_message_worker_spec.rb +++ b/spec/workers/push_encrypted_message_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe PushEncryptedMessageWorker do +RSpec.describe PushEncryptedMessageWorker do let(:worker) { described_class.new } describe 'perform' do diff --git a/spec/workers/push_update_worker_spec.rb b/spec/workers/push_update_worker_spec.rb index c8f94fa82a..6206ab5986 100644 --- a/spec/workers/push_update_worker_spec.rb +++ b/spec/workers/push_update_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe PushUpdateWorker do +RSpec.describe PushUpdateWorker do let(:worker) { described_class.new } describe 'perform' do diff --git a/spec/workers/redownload_avatar_worker_spec.rb b/spec/workers/redownload_avatar_worker_spec.rb index 6ef320bc4f..6712ce8f40 100644 --- a/spec/workers/redownload_avatar_worker_spec.rb +++ b/spec/workers/redownload_avatar_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe RedownloadAvatarWorker do +RSpec.describe RedownloadAvatarWorker do let(:worker) { described_class.new } describe '#perform' do diff --git a/spec/workers/redownload_header_worker_spec.rb b/spec/workers/redownload_header_worker_spec.rb index 746c1a63ff..a57ed31792 100644 --- a/spec/workers/redownload_header_worker_spec.rb +++ b/spec/workers/redownload_header_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe RedownloadHeaderWorker do +RSpec.describe RedownloadHeaderWorker do let(:worker) { described_class.new } describe '#perform' do diff --git a/spec/workers/redownload_media_worker_spec.rb b/spec/workers/redownload_media_worker_spec.rb index cd561d148b..adf9a7171c 100644 --- a/spec/workers/redownload_media_worker_spec.rb +++ b/spec/workers/redownload_media_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe RedownloadMediaWorker do +RSpec.describe RedownloadMediaWorker do let(:worker) { described_class.new } describe '#perform' do diff --git a/spec/workers/refollow_worker_spec.rb b/spec/workers/refollow_worker_spec.rb index 5718d4db49..30d5327947 100644 --- a/spec/workers/refollow_worker_spec.rb +++ b/spec/workers/refollow_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe RefollowWorker do +RSpec.describe RefollowWorker do subject { described_class.new } let(:account) { Fabricate(:account, domain: 'example.org', protocol: :activitypub) } diff --git a/spec/workers/regeneration_worker_spec.rb b/spec/workers/regeneration_worker_spec.rb index 37b0a04c49..980f1d81db 100644 --- a/spec/workers/regeneration_worker_spec.rb +++ b/spec/workers/regeneration_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe RegenerationWorker do +RSpec.describe RegenerationWorker do subject { described_class.new } describe 'perform' do diff --git a/spec/workers/removal_worker_spec.rb b/spec/workers/removal_worker_spec.rb index 5071e882b6..784e72441c 100644 --- a/spec/workers/removal_worker_spec.rb +++ b/spec/workers/removal_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe RemovalWorker do +RSpec.describe RemovalWorker do let(:worker) { described_class.new } let(:service) { instance_double(RemoveStatusService, call: true) } diff --git a/spec/workers/remove_featured_tag_worker_spec.rb b/spec/workers/remove_featured_tag_worker_spec.rb index a64bd0605f..7866824ee7 100644 --- a/spec/workers/remove_featured_tag_worker_spec.rb +++ b/spec/workers/remove_featured_tag_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe RemoveFeaturedTagWorker do +RSpec.describe RemoveFeaturedTagWorker do let(:worker) { described_class.new } describe 'perform' do diff --git a/spec/workers/remove_from_public_statuses_index_worker_spec.rb b/spec/workers/remove_from_public_statuses_index_worker_spec.rb index 43ff211eaa..90f05d6a26 100644 --- a/spec/workers/remove_from_public_statuses_index_worker_spec.rb +++ b/spec/workers/remove_from_public_statuses_index_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe RemoveFromPublicStatusesIndexWorker do +RSpec.describe RemoveFromPublicStatusesIndexWorker do describe '#perform' do let(:account) { Fabricate(:account, indexable: indexable) } let(:account_id) { account.id } diff --git a/spec/workers/resolve_account_worker_spec.rb b/spec/workers/resolve_account_worker_spec.rb index 6f3cff099f..de349adacb 100644 --- a/spec/workers/resolve_account_worker_spec.rb +++ b/spec/workers/resolve_account_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe ResolveAccountWorker do +RSpec.describe ResolveAccountWorker do let(:worker) { described_class.new } describe 'perform' do diff --git a/spec/workers/scheduler/accounts_statuses_cleanup_scheduler_spec.rb b/spec/workers/scheduler/accounts_statuses_cleanup_scheduler_spec.rb index 08ebf82785..28a4176193 100644 --- a/spec/workers/scheduler/accounts_statuses_cleanup_scheduler_spec.rb +++ b/spec/workers/scheduler/accounts_statuses_cleanup_scheduler_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Scheduler::AccountsStatusesCleanupScheduler do +RSpec.describe Scheduler::AccountsStatusesCleanupScheduler do subject { described_class.new } let!(:account_alice) { Fabricate(:account, domain: nil, username: 'alice') } diff --git a/spec/workers/scheduler/auto_close_registrations_scheduler_spec.rb b/spec/workers/scheduler/auto_close_registrations_scheduler_spec.rb index c0c50b128d..d9355248ba 100644 --- a/spec/workers/scheduler/auto_close_registrations_scheduler_spec.rb +++ b/spec/workers/scheduler/auto_close_registrations_scheduler_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Scheduler::AutoCloseRegistrationsScheduler do +RSpec.describe Scheduler::AutoCloseRegistrationsScheduler do subject { described_class.new } describe '#perform' do diff --git a/spec/workers/scheduler/follow_recommendations_scheduler_spec.rb b/spec/workers/scheduler/follow_recommendations_scheduler_spec.rb index 246012e128..eb9d88e59a 100644 --- a/spec/workers/scheduler/follow_recommendations_scheduler_spec.rb +++ b/spec/workers/scheduler/follow_recommendations_scheduler_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Scheduler::FollowRecommendationsScheduler do +RSpec.describe Scheduler::FollowRecommendationsScheduler do let!(:target_accounts) do Fabricate.times(3, :account) do statuses(count: 6) diff --git a/spec/workers/scheduler/indexing_scheduler_spec.rb b/spec/workers/scheduler/indexing_scheduler_spec.rb index 568f0fc84d..39a88e8063 100644 --- a/spec/workers/scheduler/indexing_scheduler_spec.rb +++ b/spec/workers/scheduler/indexing_scheduler_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Scheduler::IndexingScheduler do +RSpec.describe Scheduler::IndexingScheduler do let(:worker) { described_class.new } describe 'perform' do diff --git a/spec/workers/scheduler/instance_refresh_scheduler_spec.rb b/spec/workers/scheduler/instance_refresh_scheduler_spec.rb index 8f686a6998..37682ebb8f 100644 --- a/spec/workers/scheduler/instance_refresh_scheduler_spec.rb +++ b/spec/workers/scheduler/instance_refresh_scheduler_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Scheduler::InstanceRefreshScheduler do +RSpec.describe Scheduler::InstanceRefreshScheduler do let(:worker) { described_class.new } describe 'perform' do diff --git a/spec/workers/scheduler/ip_cleanup_scheduler_spec.rb b/spec/workers/scheduler/ip_cleanup_scheduler_spec.rb index 50af030117..7071fa6e98 100644 --- a/spec/workers/scheduler/ip_cleanup_scheduler_spec.rb +++ b/spec/workers/scheduler/ip_cleanup_scheduler_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Scheduler::IpCleanupScheduler do +RSpec.describe Scheduler::IpCleanupScheduler do let(:worker) { described_class.new } describe 'perform' do diff --git a/spec/workers/scheduler/pghero_scheduler_spec.rb b/spec/workers/scheduler/pghero_scheduler_spec.rb index e404e5fe47..c99e5bb164 100644 --- a/spec/workers/scheduler/pghero_scheduler_spec.rb +++ b/spec/workers/scheduler/pghero_scheduler_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Scheduler::PgheroScheduler do +RSpec.describe Scheduler::PgheroScheduler do let(:worker) { described_class.new } describe 'perform' do diff --git a/spec/workers/scheduler/scheduled_statuses_scheduler_spec.rb b/spec/workers/scheduler/scheduled_statuses_scheduler_spec.rb index 13c853c62a..2eeaeffe37 100644 --- a/spec/workers/scheduler/scheduled_statuses_scheduler_spec.rb +++ b/spec/workers/scheduler/scheduled_statuses_scheduler_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Scheduler::ScheduledStatusesScheduler do +RSpec.describe Scheduler::ScheduledStatusesScheduler do let(:worker) { described_class.new } describe 'perform' do diff --git a/spec/workers/scheduler/self_destruct_scheduler_spec.rb b/spec/workers/scheduler/self_destruct_scheduler_spec.rb index 2bf5783571..a79559efdd 100644 --- a/spec/workers/scheduler/self_destruct_scheduler_spec.rb +++ b/spec/workers/scheduler/self_destruct_scheduler_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Scheduler::SelfDestructScheduler do +RSpec.describe Scheduler::SelfDestructScheduler do let(:worker) { described_class.new } describe '#perform' do diff --git a/spec/workers/scheduler/software_update_check_scheduler_spec.rb b/spec/workers/scheduler/software_update_check_scheduler_spec.rb index f596c0a1ec..c88dbfe0af 100644 --- a/spec/workers/scheduler/software_update_check_scheduler_spec.rb +++ b/spec/workers/scheduler/software_update_check_scheduler_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Scheduler::SoftwareUpdateCheckScheduler do +RSpec.describe Scheduler::SoftwareUpdateCheckScheduler do subject { described_class.new } describe 'perform' do diff --git a/spec/workers/scheduler/suspended_user_cleanup_scheduler_spec.rb b/spec/workers/scheduler/suspended_user_cleanup_scheduler_spec.rb index 25f0e1fce4..2782848e76 100644 --- a/spec/workers/scheduler/suspended_user_cleanup_scheduler_spec.rb +++ b/spec/workers/scheduler/suspended_user_cleanup_scheduler_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Scheduler::SuspendedUserCleanupScheduler do +RSpec.describe Scheduler::SuspendedUserCleanupScheduler do let(:worker) { described_class.new } describe 'perform' do diff --git a/spec/workers/scheduler/trends/refresh_scheduler_spec.rb b/spec/workers/scheduler/trends/refresh_scheduler_spec.rb index c0c5f032bf..34bcd8fdd8 100644 --- a/spec/workers/scheduler/trends/refresh_scheduler_spec.rb +++ b/spec/workers/scheduler/trends/refresh_scheduler_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Scheduler::Trends::RefreshScheduler do +RSpec.describe Scheduler::Trends::RefreshScheduler do let(:worker) { described_class.new } describe 'perform' do diff --git a/spec/workers/scheduler/trends/review_notifications_scheduler_spec.rb b/spec/workers/scheduler/trends/review_notifications_scheduler_spec.rb index cc971c24b4..ec35236172 100644 --- a/spec/workers/scheduler/trends/review_notifications_scheduler_spec.rb +++ b/spec/workers/scheduler/trends/review_notifications_scheduler_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Scheduler::Trends::ReviewNotificationsScheduler do +RSpec.describe Scheduler::Trends::ReviewNotificationsScheduler do let(:worker) { described_class.new } describe 'perform' do diff --git a/spec/workers/scheduler/user_cleanup_scheduler_spec.rb b/spec/workers/scheduler/user_cleanup_scheduler_spec.rb index 7952f2c146..b1be7c4611 100644 --- a/spec/workers/scheduler/user_cleanup_scheduler_spec.rb +++ b/spec/workers/scheduler/user_cleanup_scheduler_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Scheduler::UserCleanupScheduler do +RSpec.describe Scheduler::UserCleanupScheduler do subject { described_class.new } let!(:new_unconfirmed_user) { Fabricate(:user) } diff --git a/spec/workers/scheduler/vacuum_scheduler_spec.rb b/spec/workers/scheduler/vacuum_scheduler_spec.rb index 36ecc93d8e..29a7eeac40 100644 --- a/spec/workers/scheduler/vacuum_scheduler_spec.rb +++ b/spec/workers/scheduler/vacuum_scheduler_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Scheduler::VacuumScheduler do +RSpec.describe Scheduler::VacuumScheduler do let(:worker) { described_class.new } describe 'perform' do diff --git a/spec/workers/tag_unmerge_worker_spec.rb b/spec/workers/tag_unmerge_worker_spec.rb index 5d3a12c449..a0e53e36d9 100644 --- a/spec/workers/tag_unmerge_worker_spec.rb +++ b/spec/workers/tag_unmerge_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe TagUnmergeWorker do +RSpec.describe TagUnmergeWorker do subject { described_class.new } describe 'perform' do diff --git a/spec/workers/unfilter_notifications_worker_spec.rb b/spec/workers/unfilter_notifications_worker_spec.rb index 629eb644e4..464a4520ff 100644 --- a/spec/workers/unfilter_notifications_worker_spec.rb +++ b/spec/workers/unfilter_notifications_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe UnfilterNotificationsWorker do +RSpec.describe UnfilterNotificationsWorker do let(:recipient) { Fabricate(:account) } let(:sender) { Fabricate(:account) } diff --git a/spec/workers/unfollow_follow_worker_spec.rb b/spec/workers/unfollow_follow_worker_spec.rb index 8025b88c0c..7b9d49b902 100644 --- a/spec/workers/unfollow_follow_worker_spec.rb +++ b/spec/workers/unfollow_follow_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe UnfollowFollowWorker do +RSpec.describe UnfollowFollowWorker do subject { described_class.new } let(:local_follower) { Fabricate(:account) } diff --git a/spec/workers/unpublish_announcement_worker_spec.rb b/spec/workers/unpublish_announcement_worker_spec.rb index c742c30bce..f4838ac248 100644 --- a/spec/workers/unpublish_announcement_worker_spec.rb +++ b/spec/workers/unpublish_announcement_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe UnpublishAnnouncementWorker do +RSpec.describe UnpublishAnnouncementWorker do let(:worker) { described_class.new } describe 'perform' do diff --git a/spec/workers/verify_account_links_worker_spec.rb b/spec/workers/verify_account_links_worker_spec.rb index 227591392c..3f600b8c97 100644 --- a/spec/workers/verify_account_links_worker_spec.rb +++ b/spec/workers/verify_account_links_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe VerifyAccountLinksWorker do +RSpec.describe VerifyAccountLinksWorker do let(:worker) { described_class.new } describe 'perform' do diff --git a/spec/workers/web/push_notification_worker_spec.rb b/spec/workers/web/push_notification_worker_spec.rb index 637206a409..ced21d5bf7 100644 --- a/spec/workers/web/push_notification_worker_spec.rb +++ b/spec/workers/web/push_notification_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Web::PushNotificationWorker do +RSpec.describe Web::PushNotificationWorker do subject { described_class.new } let(:p256dh) { 'BN4GvZtEZiZuqFxSKVZfSfluwKBD7UxHNBmWkfiZfCtgDE8Bwh-_MtLXbBxTBAWH9r7IPKL0lhdcaqtL1dfxU5E=' } diff --git a/spec/workers/webhooks/delivery_worker_spec.rb b/spec/workers/webhooks/delivery_worker_spec.rb index 6a5483d1d4..48fcfc607b 100644 --- a/spec/workers/webhooks/delivery_worker_spec.rb +++ b/spec/workers/webhooks/delivery_worker_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe Webhooks::DeliveryWorker do +RSpec.describe Webhooks::DeliveryWorker do let(:worker) { described_class.new } describe '#perform' do From 9ed1aab9b7a96076e949d5c47b391376af23d9c8 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Wed, 4 Sep 2024 01:12:35 -0400 Subject: [PATCH 081/153] Remove accidental matcher debug code (#31732) --- spec/support/matchers/cacheable_response.rb | 2 -- 1 file changed, 2 deletions(-) diff --git a/spec/support/matchers/cacheable_response.rb b/spec/support/matchers/cacheable_response.rb index da8570c8c5..e48eb28cc1 100644 --- a/spec/support/matchers/cacheable_response.rb +++ b/spec/support/matchers/cacheable_response.rb @@ -27,8 +27,6 @@ RSpec::Matchers.define :have_cacheable_headers do end def check_vary - puts @expected_vary - pp @response.headers "Response `Vary` header does not contain `#{@expected_vary}`" unless @response.headers['Vary'].include?(@expected_vary) end From 14af5b47ac2230937e9244bec41390301c7b0067 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Wed, 4 Sep 2024 01:12:40 -0400 Subject: [PATCH 082/153] Add coverage for model normalizations (#31734) --- spec/models/account_alias_spec.rb | 11 +++++++ spec/models/account_migration_spec.rb | 6 ++++ spec/models/account_spec.rb | 11 +++---- spec/models/account_warning_spec.rb | 11 +++++++ spec/models/custom_emoji_spec.rb | 19 ++----------- spec/models/custom_filter_spec.rb | 6 ++-- spec/models/featured_tag_spec.rb | 11 +++++++ spec/models/relay_spec.rb | 11 +++++++ spec/models/user_spec.rb | 41 +++++---------------------- spec/models/webhook_spec.rb | 6 ++-- 10 files changed, 70 insertions(+), 63 deletions(-) create mode 100644 spec/models/account_alias_spec.rb create mode 100644 spec/models/account_warning_spec.rb create mode 100644 spec/models/featured_tag_spec.rb create mode 100644 spec/models/relay_spec.rb diff --git a/spec/models/account_alias_spec.rb b/spec/models/account_alias_spec.rb new file mode 100644 index 0000000000..fc8c6bd250 --- /dev/null +++ b/spec/models/account_alias_spec.rb @@ -0,0 +1,11 @@ +# frozen_string_literal: true + +require 'rails_helper' + +RSpec.describe AccountAlias do + describe 'Normalizations' do + describe 'acct' do + it { is_expected.to normalize(:acct).from(' @username@domain ').to('username@domain') } + end + end +end diff --git a/spec/models/account_migration_spec.rb b/spec/models/account_migration_spec.rb index 1f32c6082e..d658915ce3 100644 --- a/spec/models/account_migration_spec.rb +++ b/spec/models/account_migration_spec.rb @@ -3,6 +3,12 @@ require 'rails_helper' RSpec.describe AccountMigration do + describe 'Normalizations' do + describe 'acct' do + it { is_expected.to normalize(:acct).from(' @username@domain ').to('username@domain') } + end + end + describe 'validations' do subject { described_class.new(account: source_account, acct: target_acct) } diff --git a/spec/models/account_spec.rb b/spec/models/account_spec.rb index 83f1585b61..27707fa897 100644 --- a/spec/models/account_spec.rb +++ b/spec/models/account_spec.rb @@ -723,14 +723,15 @@ RSpec.describe Account do end end + describe 'Normalizations' do + describe 'username' do + it { is_expected.to normalize(:username).from(" \u3000bob \t \u00a0 \n ").to('bob') } + end + end + describe 'validations' do it { is_expected.to validate_presence_of(:username) } - it 'squishes the username before validation' do - account = Fabricate(:account, domain: nil, username: " \u3000bob \t \u00a0 \n ") - expect(account.username).to eq 'bob' - end - context 'when is local' do it 'is invalid if the username is not unique in case-insensitive comparison among local accounts' do _account = Fabricate(:account, username: 'the_doctor') diff --git a/spec/models/account_warning_spec.rb b/spec/models/account_warning_spec.rb new file mode 100644 index 0000000000..37866ce3da --- /dev/null +++ b/spec/models/account_warning_spec.rb @@ -0,0 +1,11 @@ +# frozen_string_literal: true + +require 'rails_helper' + +RSpec.describe AccountWarning do + describe 'Normalizations' do + describe 'text' do + it { is_expected.to normalize(:text).from(nil).to('') } + end + end +end diff --git a/spec/models/custom_emoji_spec.rb b/spec/models/custom_emoji_spec.rb index cb8cb5c11b..87b111441a 100644 --- a/spec/models/custom_emoji_spec.rb +++ b/spec/models/custom_emoji_spec.rb @@ -79,22 +79,9 @@ RSpec.describe CustomEmoji, :attachment_processing do end describe 'Normalizations' do - describe 'downcase domain value' do - context 'with a mixed case domain value' do - it 'normalizes the value to downcased' do - custom_emoji = Fabricate.build(:custom_emoji, domain: 'wWw.MaStOdOn.CoM') - - expect(custom_emoji.domain).to eq('www.mastodon.com') - end - end - - context 'with a nil domain value' do - it 'leaves the value as nil' do - custom_emoji = Fabricate.build(:custom_emoji, domain: nil) - - expect(custom_emoji.domain).to be_nil - end - end + describe 'domain' do + it { is_expected.to normalize(:domain).from('wWw.MaStOdOn.CoM').to('www.mastodon.com') } + it { is_expected.to normalize(:domain).from(nil).to(nil) } end end end diff --git a/spec/models/custom_filter_spec.rb b/spec/models/custom_filter_spec.rb index 8ac9dbb896..5bb615bb37 100644 --- a/spec/models/custom_filter_spec.rb +++ b/spec/models/custom_filter_spec.rb @@ -34,10 +34,8 @@ RSpec.describe CustomFilter do end describe 'Normalizations' do - it 'cleans up context values' do - record = described_class.new(context: ['home', 'notifications', 'public ', '']) - - expect(record.context).to eq(%w(home notifications public)) + describe 'context' do + it { is_expected.to normalize(:context).from(['home', 'notifications', 'public ', '']).to(%w(home notifications public)) } end end end diff --git a/spec/models/featured_tag_spec.rb b/spec/models/featured_tag_spec.rb new file mode 100644 index 0000000000..6056e645e0 --- /dev/null +++ b/spec/models/featured_tag_spec.rb @@ -0,0 +1,11 @@ +# frozen_string_literal: true + +require 'rails_helper' + +RSpec.describe FeaturedTag do + describe 'Normalizations' do + describe 'name' do + it { is_expected.to normalize(:name).from(' #hashtag ').to('hashtag') } + end + end +end diff --git a/spec/models/relay_spec.rb b/spec/models/relay_spec.rb new file mode 100644 index 0000000000..4b95c596e4 --- /dev/null +++ b/spec/models/relay_spec.rb @@ -0,0 +1,11 @@ +# frozen_string_literal: true + +require 'rails_helper' + +RSpec.describe Relay do + describe 'Normalizations' do + describe 'inbox_url' do + it { is_expected.to normalize(:inbox_url).from(' http://host.example ').to('http://host.example') } + end + end +end diff --git a/spec/models/user_spec.rb b/spec/models/user_spec.rb index 0f3e25576e..5c2af4dc39 100644 --- a/spec/models/user_spec.rb +++ b/spec/models/user_spec.rb @@ -59,45 +59,18 @@ RSpec.describe User do describe 'Normalizations' do describe 'locale' do - it 'preserves valid locale' do - user = Fabricate.build(:user, locale: 'en') - - expect(user.locale).to eq('en') - end - - it 'cleans out invalid locale' do - user = Fabricate.build(:user, locale: 'toto') - - expect(user.locale).to be_nil - end + it { is_expected.to_not normalize(:locale).from('en') } + it { is_expected.to normalize(:locale).from('toto').to(nil) } end describe 'time_zone' do - it 'preserves valid timezone' do - user = Fabricate.build(:user, time_zone: 'UTC') - - expect(user.time_zone).to eq('UTC') - end - - it 'cleans out invalid timezone' do - user = Fabricate.build(:user, time_zone: 'toto') - - expect(user.time_zone).to be_nil - end + it { is_expected.to_not normalize(:time_zone).from('UTC') } + it { is_expected.to normalize(:time_zone).from('toto').to(nil) } end - describe 'languages' do - it 'preserves valid options for languages' do - user = Fabricate.build(:user, chosen_languages: ['en', 'fr', '']) - - expect(user.chosen_languages).to eq(['en', 'fr']) - end - - it 'cleans out empty string from languages' do - user = Fabricate.build(:user, chosen_languages: ['']) - - expect(user.chosen_languages).to be_nil - end + describe 'chosen_languages' do + it { is_expected.to normalize(:chosen_languages).from(['en', 'fr', '']).to(%w(en fr)) } + it { is_expected.to normalize(:chosen_languages).from(['']).to(nil) } end end diff --git a/spec/models/webhook_spec.rb b/spec/models/webhook_spec.rb index 864baf2e1a..1b2d803bd7 100644 --- a/spec/models/webhook_spec.rb +++ b/spec/models/webhook_spec.rb @@ -29,10 +29,8 @@ RSpec.describe Webhook do end describe 'Normalizations' do - it 'cleans up events values' do - record = described_class.new(events: ['account.approved', 'account.created ', '']) - - expect(record.events).to eq(%w(account.approved account.created)) + describe 'events' do + it { is_expected.to normalize(:events).from(['account.approved', 'account.created ', '']).to(%w(account.approved account.created)) } end end From a24049db306a97dc5b29da4d794751b4757529bf Mon Sep 17 00:00:00 2001 From: Michael Stanclift Date: Wed, 4 Sep 2024 03:20:46 -0500 Subject: [PATCH 083/153] Fix Corepack prompt on Devcontainer (#31729) --- .devcontainer/Dockerfile | 3 +++ .devcontainer/codespaces/devcontainer.json | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/.devcontainer/Dockerfile b/.devcontainer/Dockerfile index c6dcc4d46a..3aa0bbf7da 100644 --- a/.devcontainer/Dockerfile +++ b/.devcontainer/Dockerfile @@ -11,5 +11,8 @@ RUN apt-get update && \ export DEBIAN_FRONTEND=noninteractive && \ apt-get -y install --no-install-recommends libicu-dev libidn11-dev ffmpeg imagemagick libvips42 libpam-dev +# Disable download prompt for Corepack +ENV COREPACK_ENABLE_DOWNLOAD_PROMPT=0 + # Move welcome message to where VS Code expects it COPY .devcontainer/welcome-message.txt /usr/local/etc/vscode-dev-containers/first-run-notice.txt diff --git a/.devcontainer/codespaces/devcontainer.json b/.devcontainer/codespaces/devcontainer.json index 8acffec825..d2358657f6 100644 --- a/.devcontainer/codespaces/devcontainer.json +++ b/.devcontainer/codespaces/devcontainer.json @@ -39,7 +39,7 @@ }, "onCreateCommand": "git config --global --add safe.directory ${containerWorkspaceFolder}", - "postCreateCommand": "COREPACK_ENABLE_DOWNLOAD_PROMPT=0 bin/setup", + "postCreateCommand": "bin/setup", "waitFor": "postCreateCommand", "customizations": { From 612802b9e5ede73e76e711a65f5c95e451fab0b7 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 4 Sep 2024 08:22:44 +0000 Subject: [PATCH 084/153] Update dependency sass to v1.78.0 (#31739) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index 57e928c4de..727dfacd92 100644 --- a/yarn.lock +++ b/yarn.lock @@ -15441,15 +15441,15 @@ __metadata: linkType: hard "sass@npm:^1.62.1": - version: 1.77.8 - resolution: "sass@npm:1.77.8" + version: 1.78.0 + resolution: "sass@npm:1.78.0" dependencies: chokidar: "npm:>=3.0.0 <4.0.0" immutable: "npm:^4.0.0" source-map-js: "npm:>=0.6.2 <2.0.0" bin: sass: sass.js - checksum: 10c0/2bfd62794070352c804f949e69bd8bb5b4ec846deeb924251b2c3f7b503170fb1ae186f513f0166907749eb34e0277dee747edcb78c886fb471aac01be1e864c + checksum: 10c0/6577a87c00b03a5a50f3a11b4b6592f28abce34e61812e381535a3b712151bd94db3ca06467d20395431e0f38a23f99e616d6859d771fb6d4617c359f590c48c languageName: node linkType: hard From 3553d6c36f522d4b3365db0139ff40261fc0728b Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 4 Sep 2024 08:23:00 +0000 Subject: [PATCH 085/153] Update dependency aws-sdk-s3 to v1.160.0 (#31735) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- Gemfile.lock | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index 461a2d43a2..dcd82b273a 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -100,17 +100,17 @@ GEM attr_required (1.0.2) awrence (1.2.1) aws-eventstream (1.3.0) - aws-partitions (1.969.0) - aws-sdk-core (3.202.1) + aws-partitions (1.970.0) + aws-sdk-core (3.203.0) aws-eventstream (~> 1, >= 1.3.0) aws-partitions (~> 1, >= 1.651.0) aws-sigv4 (~> 1.9) jmespath (~> 1, >= 1.6.1) - aws-sdk-kms (1.88.0) - aws-sdk-core (~> 3, >= 3.201.0) + aws-sdk-kms (1.89.0) + aws-sdk-core (~> 3, >= 3.203.0) aws-sigv4 (~> 1.5) - aws-sdk-s3 (1.159.0) - aws-sdk-core (~> 3, >= 3.201.0) + aws-sdk-s3 (1.160.0) + aws-sdk-core (~> 3, >= 3.203.0) aws-sdk-kms (~> 1) aws-sigv4 (~> 1.5) aws-sigv4 (1.9.1) From 2c6131c9a1957b4847cf6d0b23986824e64c60c2 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 4 Sep 2024 10:23:15 +0200 Subject: [PATCH 086/153] Update dependency test-prof to v1.4.2 (#31733) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile.lock b/Gemfile.lock index dcd82b273a..09be3e6921 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -837,7 +837,7 @@ GEM unicode-display_width (>= 1.1.1, < 3) terrapin (1.0.1) climate_control - test-prof (1.4.1) + test-prof (1.4.2) thor (1.3.2) tilt (2.4.0) timeout (0.4.1) From 393a5504e58e05e389781abe7f17e153eb4583eb Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 4 Sep 2024 10:25:37 +0200 Subject: [PATCH 087/153] Update dependency ruby to v3.3.5 (#31719) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- .ruby-version | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.ruby-version b/.ruby-version index a0891f563f..fa7adc7ac7 100644 --- a/.ruby-version +++ b/.ruby-version @@ -1 +1 @@ -3.3.4 +3.3.5 From 1c17dca6d9c36371cbcdd0f9a610e9c5eb53718b Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Wed, 4 Sep 2024 10:42:36 +0200 Subject: [PATCH 088/153] New Crowdin Translations (automated) (#31741) Co-authored-by: GitHub Actions --- app/javascript/mastodon/locales/pt-BR.json | 28 +++++++ config/locales/activerecord.pt-BR.yml | 14 ++-- config/locales/devise.pt-BR.yml | 10 +-- config/locales/doorkeeper.pt-BR.yml | 35 ++++---- config/locales/en-GB.yml | 22 ++++++ config/locales/fr-CA.yml | 16 ++++ config/locales/fr.yml | 16 ++++ config/locales/he.yml | 1 + config/locales/hu.yml | 1 + config/locales/is.yml | 1 + config/locales/ko.yml | 2 +- config/locales/nn.yml | 1 + config/locales/pt-BR.yml | 92 ++++++++++++++++++++-- config/locales/simple_form.pt-BR.yml | 4 + config/locales/tr.yml | 1 + 15 files changed, 209 insertions(+), 35 deletions(-) diff --git a/app/javascript/mastodon/locales/pt-BR.json b/app/javascript/mastodon/locales/pt-BR.json index e925246bf7..aeff65485e 100644 --- a/app/javascript/mastodon/locales/pt-BR.json +++ b/app/javascript/mastodon/locales/pt-BR.json @@ -524,7 +524,9 @@ "notification.moderation_warning.action_silence": "Sua conta foi limitada.", "notification.moderation_warning.action_suspend": "Sua conta foi suspensa.", "notification.own_poll": "Sua enquete terminou", + "notification.poll": "Uma enquete que você votou terminou", "notification.reblog": "{name} deu boost no teu toot", + "notification.reblog.name_and_others_with_link": "{name} e {count, plural, one {# outra} other {# outras}} impulsionaram a publicação", "notification.relationships_severance_event": "Conexões perdidas com {name}", "notification.relationships_severance_event.account_suspension": "Um administrador de {from} suspendeu {target}, o que significa que você não pode mais receber atualizações deles ou interagir com eles.", "notification.relationships_severance_event.domain_block": "An admin from {from} has blocked {target}, including {followersCount} of your followers and {followingCount, plural, one {# account} other {# accounts}} you follow.", @@ -533,16 +535,32 @@ "notification.status": "{name} acabou de tootar", "notification.update": "{name} editou uma publicação", "notification_requests.accept": "Aceitar", + "notification_requests.accept_multiple": "{count, plural, one {Aceite # pedido…} other {Aceite # pedidos…}}", + "notification_requests.confirm_accept_multiple.button": "{count, plural, one {Aceite # pedido} other {Aceite # pedidos}}", + "notification_requests.confirm_accept_multiple.message": "Você está prestes a aceitar {count, plural, one {um pedido de notificação} other {# pedidos de notificação}}. Tem certeza de que deseja continuar?", + "notification_requests.confirm_accept_multiple.title": "Aceitar solicitações de notificação?", + "notification_requests.confirm_dismiss_multiple.button": "{count, plural, one {Dispensar pedido} other {Dispensar pedidos}}", + "notification_requests.confirm_dismiss_multiple.message": "Você está prestes a descartar {count, plural, one {um pedido de notificação} other {# pedidos de notificação}}. Você não será capaz de acessar facilmente{count, plural, one {} other {}} novamente. Tem certeza de que deseja continuar?", + "notification_requests.confirm_dismiss_multiple.title": "Descartar solicitações de notificação?", "notification_requests.dismiss": "Rejeitar", + "notification_requests.dismiss_multiple": "{count, plural, one {Dispensar # pedido…} other {Dispensar # pedidos…}}", + "notification_requests.edit_selection": "Editar", + "notification_requests.exit_selection": "Concluído", + "notification_requests.explainer_for_limited_account": "As notificações desta conta foram filtradas porque a conta foi limitada por um moderador.", + "notification_requests.explainer_for_limited_remote_account": "As notificações desta conta foram filtradas porque a conta ou o seu servidor foi limitado por um moderador.", "notification_requests.maximize": "Maximizar", + "notification_requests.minimize_banner": "Minimizar banner de notificações filtradas", "notification_requests.notifications_from": "Notificações de {name}", "notification_requests.title": "Notificações filtradas", + "notification_requests.view": "Ver notificações", "notifications.clear": "Limpar notificações", "notifications.clear_confirmation": "Você tem certeza de que deseja limpar todas as suas notificações?", "notifications.clear_title": "Limpar notificações?", "notifications.column_settings.admin.report": "Novas denúncias:", "notifications.column_settings.admin.sign_up": "Novas inscrições:", "notifications.column_settings.alert": "Notificações no computador", + "notifications.column_settings.beta.category": "Recursos experimentais", + "notifications.column_settings.beta.grouping": "Agrupar notificações", "notifications.column_settings.favourite": "Favoritos:", "notifications.column_settings.filter_bar.advanced": "Exibir todas as categorias", "notifications.column_settings.filter_bar.category": "Barra de filtro rápido", @@ -574,6 +592,11 @@ "notifications.policy.accept": "Aceitar", "notifications.policy.accept_hint": "Mostrar nas notificações", "notifications.policy.drop": "Ignorar", + "notifications.policy.drop_hint": "Envie para o void, para nunca mais ser visto novamente", + "notifications.policy.filter": "Filtrar", + "notifications.policy.filter_hint": "Enviar para caixa de notificações filtradas", + "notifications.policy.filter_limited_accounts_hint": "Limitado pelos moderadores do servidor", + "notifications.policy.filter_limited_accounts_title": "Contas moderadas", "notifications.policy.filter_new_accounts.hint": "Created within the past {days, plural, one {one day} other {# days}}", "notifications.policy.filter_new_accounts_title": "Novas contas", "notifications.policy.filter_not_followers_hint": "Including people who have been following you fewer than {days, plural, one {one day} other {# days}}", @@ -582,6 +605,7 @@ "notifications.policy.filter_not_following_title": "Pessoas que você não segue", "notifications.policy.filter_private_mentions_hint": "Filtrado, a menos que respondido em sua própria menção ou se você segue o remetente", "notifications.policy.filter_private_mentions_title": "Menções privadas não solicitadas", + "notifications.policy.title": "Gerenciar notificações de…", "notifications_permission_banner.enable": "Ativar notificações no computador", "notifications_permission_banner.how_to_control": "Para receber notificações quando o Mastodon não estiver aberto, ative as notificações no computador. Você pode controlar precisamente quais tipos de interações geram notificações no computador através do botão {icon}.", "notifications_permission_banner.title": "Nunca perca nada", @@ -708,9 +732,13 @@ "report.unfollow_explanation": "Você está seguindo esta conta. Para não ver as publicações dela em sua página inicial, deixe de segui-la.", "report_notification.attached_statuses": "{count, plural, one {{count} publicação anexada} other {{count} publicações anexadas}}", "report_notification.categories.legal": "Legal", + "report_notification.categories.legal_sentence": "conteúdo ilegal", "report_notification.categories.other": "Outro", + "report_notification.categories.other_sentence": "outro", "report_notification.categories.spam": "Spam", + "report_notification.categories.spam_sentence": "spam", "report_notification.categories.violation": "Violação de regra", + "report_notification.categories.violation_sentence": "violação de regra", "report_notification.open": "Abrir denúncia", "search.no_recent_searches": "Nenhuma busca recente", "search.placeholder": "Pesquisar", diff --git a/config/locales/activerecord.pt-BR.yml b/config/locales/activerecord.pt-BR.yml index ae78026629..3199eb8e2d 100644 --- a/config/locales/activerecord.pt-BR.yml +++ b/config/locales/activerecord.pt-BR.yml @@ -32,7 +32,7 @@ pt-BR: import: attributes: data: - malformed: está incorreto + malformed: está malformado status: attributes: reblog: @@ -43,16 +43,16 @@ pt-BR: blocked: usa provedor de e-mail não permitido unreachable: parece não existir role_id: - elevated: não pode ser maior que seu cargo atual + elevated: não pode maior que sua função atual user_role: attributes: permissions_as_keys: - dangerous: incluir permissões que não são seguras para o cargo base - elevated: não pode incluir permissões que o seu cargo atual não possui - own_role: não pode ser alterado com seu cargo atual + dangerous: incluir permissões que não são seguras para a função base + elevated: não pode incluir permissões que a sua função atual não possui + own_role: não pode ser alterado com sua função atual position: - elevated: não pode ser maior do que seu cargo atual - own_role: não pode ser alterado com seu cargo atual + elevated: não pode ser maior do que sua função atual + own_role: não pode ser alterado com sua função atual webhook: attributes: events: diff --git a/config/locales/devise.pt-BR.yml b/config/locales/devise.pt-BR.yml index 4a7f346fab..8f504362de 100644 --- a/config/locales/devise.pt-BR.yml +++ b/config/locales/devise.pt-BR.yml @@ -14,7 +14,7 @@ pt-BR: not_found_in_database: "%{authentication_keys} ou senha inválida." omniauth_user_creation_failure: Erro ao criar uma conta para esta identidade. pending: Sua conta está sendo revisada. - timeout: Sua sessão expirou. Por favor, entre novamente para continuar. + timeout: Sua sessão expirou. Faça ‘login’ novamente para continuar. unauthenticated: Você precisa entrar ou criar uma conta antes de continuar. unconfirmed: Você precisa confirmar o seu endereço de e-mail antes de continuar. mailer: @@ -48,12 +48,12 @@ pt-BR: subject: 'Mastodon: Instruções para alterar senha' title: Redefinir senha two_factor_disabled: - explanation: O ‘login’ agora é possível usando apenas o endereço de e-mail e senha. + explanation: O ‘login’ agora é possível usando apenas o endereço eletrônico e senha. subject: 'Mastodon: Autenticação de dois fatores desativada' subtitle: A autenticação de dois fatores foi desativada. title: 2FA desativada two_factor_enabled: - explanation: Será necessário um código gerado pelo aplicativo de autenticação para fazer login. + explanation: Será necessário um código gerado pelo aplicativo de autenticação TOTP para fazer login. subject: 'Mastodon: Autenticação de dois fatores ativada' subtitle: A autenticação de dois fatores foi ativada para sua conta. title: 2FA ativada @@ -75,11 +75,11 @@ pt-BR: title: Uma das suas chaves de segurança foi excluída webauthn_disabled: explanation: A autenticação por chaves de segurança foi desativada para sua conta. - extra: O login agora é possível usando o código gerado por um aplicativo de autenticação de dois fatores. + extra: Agora você pode fazer login usando apenas o código gerado pelo aplicativo de autenticação TOTP. subject: 'Mastodon: Autenticação por chaves de segurança desativada' title: Chaves de segurança desativadas webauthn_enabled: - explanation: Autenticação por chave de segurança foi ativada para sua conta. + explanation: A autenticação por chave de segurança foi ativada para sua conta. extra: Sua chave de segurança agora pode ser usada para ‘login’. subject: 'Mastodon: Autenticação por chaves de segurança ativada' title: Chaves de segurança ativadas diff --git a/config/locales/doorkeeper.pt-BR.yml b/config/locales/doorkeeper.pt-BR.yml index 6b076e9081..c991850c68 100644 --- a/config/locales/doorkeeper.pt-BR.yml +++ b/config/locales/doorkeeper.pt-BR.yml @@ -60,8 +60,8 @@ pt-BR: error: title: Ocorreu um erro new: - prompt_html: O %{client_name} gostaria de ter permissão para acessar sua conta. É uma aplicação de terceiros. Se você não confia, então você não deve autorizá-lo. - review_permissions: Revisar permissões + prompt_html: O %{client_name} gostaria de ter permissão para acessar sua conta. Trata-se de uma aplicação de terceiros. Se você não confia nesta aplicação, então você não deve autorizá-la. + review_permissions: Rever permissões title: Autorização necessária show: title: Copie este código de autorização e cole no aplicativo. @@ -72,8 +72,8 @@ pt-BR: revoke: Você tem certeza? index: authorized_at: Autorizado em %{date} - description_html: Estas são as aplicações que podem acessar sua conta usando a API. Se houver aplicativos que você não reconhece ou com mau funcionamento, você pode revogar seu acesso. - last_used_at: Última vez usado em %{date} + description_html: Estas são as aplicações que podem acessar sua conta usando a API. Se houver aplicações que você não reconhece ou que não funcionem corretamente, você pode revogar os acessos. + last_used_at: Usado pela última vez em %{date} never_used: Nunca usado scopes: Permissões superapp: Interno @@ -83,6 +83,7 @@ pt-BR: access_denied: O proprietário do recurso ou servidor de autorização recusou a solicitação. credential_flow_not_configured: Fluxo das Credenciais de Senha do Proprietário do Recurso falhou porque Doorkeeper.configure.resource_owner_from_credentials não foi configurado. invalid_client: Autenticação do cliente falhou por causa de um cliente desconhecido, nenhum cliente de autenticação foi incluído ou o método de autenticação não é suportado. + invalid_code_challenge_method: O método de desafio de código deve ser S256; o método 'plain' não é suportado. invalid_grant: A garantia de autorização está inválida, expirou ou foi revogada, não é equivalente ao link de redirecionamento usado na solicitação de autorização ou foi emitido por outro cliente. invalid_redirect_uri: O link de redirecionamento é inválido. invalid_request: @@ -114,23 +115,23 @@ pt-BR: notice: Aplicativo revogado. grouped_scopes: access: - read: Acesso somente para leitura + read: Acesso somente leitura read/write: Acesso de leitura e escrita - write: Acesso somente para escrita + write: Acesso somente escrita title: accounts: Contas admin/accounts: Administração de contas admin/all: Todas as funções administrativas - admin/reports: Controle de denúncias + admin/reports: Administração de denúncias all: Acesso total à sua conta Mastodon blocks: Bloqueios bookmarks: Salvos conversations: Conversas crypto: Criptografia de ponta a ponta - favourites: Favoritas + favourites: Favoritos filters: Filtros - follow: Seguidores, Silenciados e Bloqueados - follows: Seguidores + follow: Seguimentos, Silenciamentos e Bloqueios + follows: Seguidos lists: Listas media: Mídias anexadas mutes: Silenciados @@ -151,17 +152,17 @@ pt-BR: admin:read: ler todos os dados no servidor admin:read:accounts: ler informações sensíveis de todas as contas admin:read:canonical_email_blocks: ler informações sensíveis de todos os blocos de e-mail canônicos - admin:read:domain_allows: ler informações sensíveis de todos os domínios (URL) permitidos - admin:read:domain_blocks: ler informações sensíveis de todos os domínios (URL) bloqueados - admin:read:email_domain_blocks: ler informações sensíveis de todos os e-mails de domínios bloqueados + admin:read:domain_allows: ler informações sensíveis de todos os domínios permitidos + admin:read:domain_blocks: ler informações sensíveis de todos os domínios bloqueados + admin:read:email_domain_blocks: ler informações sensíveis de todos os domínios de e-mail bloqueados admin:read:ip_blocks: ler informações sensíveis de todos os endereços de IP bloqueados admin:read:reports: ler informações sensíveis de todas as denúncias e contas denunciadas admin:write: alterar todos os dados no servidor admin:write:accounts: executar ações de moderação em contas admin:write:canonical_email_blocks: executar ações de moderação em blocos canônicos de e-mail - admin:write:domain_allows: executar ações de moderação em domínios (URL) permitidos - admin:write:domain_blocks: executar ações de moderação em domínios (URL) bloqueados - admin:write:email_domain_blocks: executar ações de moderação em blocos de e-mail bloqueados + admin:write:domain_allows: executar ações de moderação em domínios permitidos + admin:write:domain_blocks: executar ações de moderação em domínios bloqueados + admin:write:email_domain_blocks: executar ações de moderação em domínios de e-mail bloqueados admin:write:ip_blocks: executar ações de moderação em IPs bloqueados admin:write:reports: executar ações de moderação em denúncias crypto: usar criptografia de ponta-a-ponta @@ -172,7 +173,7 @@ pt-BR: read:accounts: ver informações das contas read:blocks: ver seus bloqueados read:bookmarks: ver seus salvos - read:favourites: veja suas favoritas + read:favourites: veja seus favoritos read:filters: ver seus filtros read:follows: ver quem você segue read:lists: ver suas listas diff --git a/config/locales/en-GB.yml b/config/locales/en-GB.yml index 012d0d91ee..bcde9956c2 100644 --- a/config/locales/en-GB.yml +++ b/config/locales/en-GB.yml @@ -182,14 +182,17 @@ en-GB: create_custom_emoji: Create Custom Emoji create_domain_allow: Create Domain Allow create_domain_block: Create Domain Block + create_email_domain_block: Create Email Domain Block create_ip_block: Create IP rule create_unavailable_domain: Create Unavailable Domain create_user_role: Create Role demote_user: Demote User destroy_announcement: Delete Announcement + destroy_canonical_email_block: Delete Email Block destroy_custom_emoji: Delete Custom Emoji destroy_domain_allow: Delete Domain Allow destroy_domain_block: Delete Domain Block + destroy_email_domain_block: Delete Email Domain Block destroy_instance: Purge Domain destroy_ip_block: Delete IP rule destroy_status: Delete Post @@ -197,8 +200,10 @@ en-GB: destroy_user_role: Destroy Role disable_2fa_user: Disable 2FA disable_custom_emoji: Disable Custom Emoji + disable_sign_in_token_auth_user: Disable Email Token Authentication for User disable_user: Disable User enable_custom_emoji: Enable Custom Emoji + enable_sign_in_token_auth_user: Enable Email Token Authentication for User enable_user: Enable User memorialize_account: Memorialise Account promote_user: Promote User @@ -228,20 +233,26 @@ en-GB: approve_appeal_html: "%{name} approved moderation decision appeal from %{target}" approve_user_html: "%{name} approved sign-up from %{target}" assigned_to_self_report_html: "%{name} assigned report %{target} to themselves" + change_email_user_html: "%{name} changed the email address of user %{target}" change_role_user_html: "%{name} changed role of %{target}" + confirm_user_html: "%{name} confirmed email address of user %{target}" create_account_warning_html: "%{name} sent a warning to %{target}" create_announcement_html: "%{name} created new announcement %{target}" + create_canonical_email_block_html: "%{name} blocked email with the hash %{target}" create_custom_emoji_html: "%{name} uploaded new emoji %{target}" create_domain_allow_html: "%{name} allowed federation with domain %{target}" create_domain_block_html: "%{name} blocked domain %{target}" + create_email_domain_block_html: "%{name} blocked email domain %{target}" create_ip_block_html: "%{name} created rule for IP %{target}" create_unavailable_domain_html: "%{name} stopped delivery to domain %{target}" create_user_role_html: "%{name} created %{target} role" demote_user_html: "%{name} demoted user %{target}" destroy_announcement_html: "%{name} deleted announcement %{target}" + destroy_canonical_email_block_html: "%{name} unblocked email with the hash %{target}" destroy_custom_emoji_html: "%{name} deleted emoji %{target}" destroy_domain_allow_html: "%{name} disallowed federation with domain %{target}" destroy_domain_block_html: "%{name} unblocked domain %{target}" + destroy_email_domain_block_html: "%{name} unblocked email domain %{target}" destroy_instance_html: "%{name} purged domain %{target}" destroy_ip_block_html: "%{name} deleted rule for IP %{target}" destroy_status_html: "%{name} removed post by %{target}" @@ -249,8 +260,10 @@ en-GB: destroy_user_role_html: "%{name} deleted %{target} role" disable_2fa_user_html: "%{name} disabled two factor requirement for user %{target}" disable_custom_emoji_html: "%{name} disabled emoji %{target}" + disable_sign_in_token_auth_user_html: "%{name} disabled email token authentication for %{target}" disable_user_html: "%{name} disabled login for user %{target}" enable_custom_emoji_html: "%{name} enabled emoji %{target}" + enable_sign_in_token_auth_user_html: "%{name} enabled email token authentication for %{target}" enable_user_html: "%{name} enabled login for user %{target}" memorialize_account_html: "%{name} turned %{target}'s account into a memoriam page" promote_user_html: "%{name} promoted user %{target}" @@ -258,6 +271,7 @@ en-GB: reject_user_html: "%{name} rejected sign-up from %{target}" remove_avatar_user_html: "%{name} removed %{target}'s avatar" reopen_report_html: "%{name} reopened report %{target}" + resend_user_html: "%{name} resent confirmation email for %{target}" reset_password_user_html: "%{name} reset password of user %{target}" resolve_report_html: "%{name} resolved report %{target}" sensitive_account_html: "%{name} marked %{target}'s media as sensitive" @@ -418,6 +432,7 @@ en-GB: attempts_over_week: one: "%{count} attempt over the last week" other: "%{count} sign-up attempts over the last week" + created_msg: Successfully blocked email domain delete: Delete dns: types: @@ -426,8 +441,12 @@ en-GB: new: create: Add domain resolve: Resolve domain + title: Block new email domain + no_email_domain_block_selected: No email domain blocks were changed as none were selected not_permitted: Not permitted + resolved_dns_records_hint_html: The domain name resolves to the following MX domains, which are ultimately responsible for accepting email. Blocking an MX domain will block sign-ups from any email address which uses the same MX domain, even if the visible domain name is different. Be careful not to block major email providers. resolved_through_html: Resolved through %{domain} + title: Blocked email domains export_domain_allows: new: title: Import domain allows @@ -581,6 +600,7 @@ en-GB: resolve_description_html: No action will be taken against the reported account, no strike recorded, and the report will be closed. silence_description_html: The account will be visible only to those who already follow it or manually look it up, severely limiting its reach. Can always be reverted. Closes all reports against this account. suspend_description_html: The account and all its contents will be inaccessible and eventually deleted, and interacting with it will be impossible. Reversible within 30 days. Closes all reports against this account. + actions_description_html: Decide which action to take to resolve this report. If you take a punitive action against the reported account, an email notification will be sent to them, except when the Spam category is selected. actions_description_remote_html: Decide which action to take to resolve this report. This will only affect how your server communicates with this remote account and handle its content. add_to_report: Add more to report already_suspended_badges: @@ -645,6 +665,7 @@ en-GB: delete_data_html: Delete @%{acct}'s profile and contents 30 days from now unless they get unsuspended in the meantime preview_preamble_html: "@%{acct} will receive a warning with the following contents:" record_strike_html: Record a strike against @%{acct} to help you escalate on future violations from this account + send_email_html: Send @%{acct} a warning email warning_placeholder: Optional additional reasoning for the moderation action. target_origin: Origin of reported account title: Reports @@ -684,6 +705,7 @@ en-GB: manage_appeals: Manage Appeals manage_appeals_description: Allows users to review appeals against moderation actions manage_blocks: Manage Blocks + manage_blocks_description: Allows users to block email providers and IP addresses manage_custom_emojis: Manage Custom Emojis manage_custom_emojis_description: Allows users to manage custom emojis on the server manage_federation: Manage Federation diff --git a/config/locales/fr-CA.yml b/config/locales/fr-CA.yml index c38435c7fb..45c6baece9 100644 --- a/config/locales/fr-CA.yml +++ b/config/locales/fr-CA.yml @@ -58,6 +58,7 @@ fr-CA: demote: Rétrograder destroyed_msg: Les données de %{username} sont maintenant en file d’attente pour être supprimées imminemment disable: Geler + disable_sign_in_token_auth: Désactiver le jeton d'authentification par e-mail disable_two_factor_authentication: Désactiver l’authentification à deux facteurs disabled: Gelé display_name: Nom affiché @@ -66,6 +67,7 @@ fr-CA: email: Courriel email_status: État du courriel enable: Dégeler + enable_sign_in_token_auth: Activer le jeton d'authentification par e-mail enabled: Activé enabled_msg: Le compte de %{username} a été dégelé avec succès followers: Abonné·e·s @@ -195,8 +197,10 @@ fr-CA: destroy_user_role: Détruire le rôle disable_2fa_user: Désactiver l’A2F disable_custom_emoji: Désactiver les émojis personnalisés + disable_sign_in_token_auth_user: Désactiver le jeton d'authentification par e-mail pour l'utilisateur disable_user: Désactiver le compte enable_custom_emoji: Activer les émojis personnalisées + enable_sign_in_token_auth_user: Activer le jeton d'authentification par e-mail pour l'utilisateur enable_user: Activer l’utilisateur memorialize_account: Ériger en mémorial promote_user: Promouvoir l’utilisateur @@ -219,18 +223,22 @@ fr-CA: update_custom_emoji: Mettre à jour les émojis personnalisés update_domain_block: Mettre à jour le blocage de domaine update_ip_block: Mettre à jour la règle IP + update_report: Mettre à jour le rapport update_status: Mettre à jour le message update_user_role: Mettre à jour le rôle actions: approve_appeal_html: "%{name} a approuvé l'appel de la décision de modération émis par %{target}" approve_user_html: "%{name} a approuvé l’inscription de %{target}" assigned_to_self_report_html: "%{name} s’est assigné·e le signalement de %{target}" + change_email_user_html: "%{name} a changé l'adresse e-mail de l'utilisateur \n%{target}" change_role_user_html: "%{name} a changé le rôle de %{target}" + confirm_user_html: "%{name} a confirmé l'adresse e-mail de l'utilisateur %{target}" create_account_warning_html: "%{name} a envoyé un avertissement à %{target}" create_announcement_html: "%{name} a créé une nouvelle annonce %{target}" create_custom_emoji_html: "%{name} a téléversé un nouvel émoji %{target}" create_domain_allow_html: "%{name} a autorisé la fédération avec le domaine %{target}" create_domain_block_html: "%{name} a bloqué le domaine %{target}" + create_email_domain_block_html: "%{name} a bloqué le domaine d'e-mail %{target}" create_ip_block_html: "%{name} a créé une règle pour l'IP %{target}" create_unavailable_domain_html: "%{name} a arrêté la livraison vers le domaine %{target}" create_user_role_html: "%{name} a créé le rôle %{target}" @@ -239,6 +247,7 @@ fr-CA: destroy_custom_emoji_html: "%{name} a supprimé l'émoji %{target}" destroy_domain_allow_html: "%{name} a rejeté la fédération avec le domaine %{target}" destroy_domain_block_html: "%{name} a débloqué le domaine %{target}" + destroy_email_domain_block_html: "%{name} a débloqué le domaine d'e-mail %{target}" destroy_instance_html: "%{name} a purgé le domaine %{target}" destroy_ip_block_html: "%{name} a supprimé la règle pour l'IP %{target}" destroy_status_html: "%{name} a supprimé le message de %{target}" @@ -276,6 +285,7 @@ fr-CA: filter_by_action: Filtrer par action filter_by_user: Filtrer par utilisateur·ice title: Journal d’audit + unavailable_instance: "(nom de domaine indisponible)" announcements: destroyed_msg: Annonce supprimée avec succès ! edit: @@ -413,6 +423,7 @@ fr-CA: attempts_over_week: one: "%{count} tentative au cours de la dernière semaine" other: "%{count} tentatives au cours de la dernière semaine" + created_msg: Domaine d'e-mail bloqué avec succès delete: Supprimer dns: types: @@ -914,6 +925,10 @@ fr-CA: statuses: allow: Autoriser le message allow_account: Autoriser l'auteur·rice + confirm_allow: Êtes-vous sûr de vouloir autoriser les statuts sélectionnés ? + confirm_allow_account: Êtes-vous sûr de vouloir autoriser les comptes sélectionnés ? + confirm_disallow: Êtes-vous sûr de vouloir rejeter les statuts sélectionnés ? + confirm_disallow_account: Êtes-vous sûr de vouloir rejeter les comptes sélectionnés ? description_html: Voici les messages dont votre serveur a connaissance qui sont beaucoup partagés et mis en favoris en ce moment. Cela peut aider vos utilisateur⋅rice⋅s, néophytes comme aguerri⋅e⋅s, à trouver plus de comptes à suivre. Aucun message n'est publiquement affiché tant que vous n'en avez pas approuvé l'auteur⋅rice, et seulement si icellui permet que son compte soit suggéré aux autres. Vous pouvez également autoriser ou rejeter les messages individuellement. disallow: Proscrire le message disallow_account: Proscrire l'auteur·rice @@ -1896,6 +1911,7 @@ fr-CA: invalid_otp_token: Le code d’authentification à deux facteurs est invalide otp_lost_help_html: Si vous perdez accès aux deux, vous pouvez contacter %{email} rate_limited: Trop de tentatives d'authentification, réessayez plus tard. + seamless_external_login: Vous êtes connectés sur un service externe, de fait les paramètres de mot de passe et d'e-mail ne sont pas disponibles. signed_in_as: 'Connecté·e en tant que :' verification: extra_instructions_html: Astuce: Le lien sur votre site Web peut être invisible. La partie importante est rel="me" qui évite d’autres liens provenant de contenu générés par des utilisateurs tiers d'être pris en compte. Vous pouvez même utiliser une balise link dans l’en-tête de la page au lieu de a, mais le HTML doit être accessible sans avoir besoin d’exécuter du JavaScript. diff --git a/config/locales/fr.yml b/config/locales/fr.yml index c3fa237759..4434a16531 100644 --- a/config/locales/fr.yml +++ b/config/locales/fr.yml @@ -58,6 +58,7 @@ fr: demote: Rétrograder destroyed_msg: Les données de %{username} sont maintenant en file d’attente pour être supprimées imminemment disable: Geler + disable_sign_in_token_auth: Désactiver le jeton d'authentification par e-mail disable_two_factor_authentication: Désactiver l’authentification à deux facteurs disabled: Gelé display_name: Nom affiché @@ -66,6 +67,7 @@ fr: email: Adresse de courriel email_status: État du courriel enable: Dégeler + enable_sign_in_token_auth: Activer le jeton d'authentification par e-mail enabled: Activé enabled_msg: Le compte de %{username} a été dégelé avec succès followers: Abonné·e·s @@ -195,8 +197,10 @@ fr: destroy_user_role: Détruire le rôle disable_2fa_user: Désactiver l’A2F disable_custom_emoji: Désactiver les émojis personnalisés + disable_sign_in_token_auth_user: Désactiver le jeton d'authentification par e-mail pour l'utilisateur disable_user: Désactiver le compte enable_custom_emoji: Activer les émojis personnalisées + enable_sign_in_token_auth_user: Activer le jeton d'authentification par e-mail pour l'utilisateur enable_user: Activer le compte memorialize_account: Ériger en mémorial promote_user: Promouvoir le compte @@ -219,18 +223,22 @@ fr: update_custom_emoji: Mettre à jour les émojis personnalisés update_domain_block: Mettre à jour le blocage de domaine update_ip_block: Mettre à jour la règle IP + update_report: Mettre à jour le rapport update_status: Mettre à jour le message update_user_role: Mettre à jour le rôle actions: approve_appeal_html: "%{name} a approuvé l'appel de la décision de modération émis par %{target}" approve_user_html: "%{name} a approuvé l’inscription de %{target}" assigned_to_self_report_html: "%{name} s’est assigné·e le signalement de %{target}" + change_email_user_html: "%{name} a changé l'adresse e-mail de l'utilisateur \n%{target}" change_role_user_html: "%{name} a changé le rôle de %{target}" + confirm_user_html: "%{name} a confirmé l'adresse e-mail de l'utilisateur %{target}" create_account_warning_html: "%{name} a envoyé un avertissement à %{target}" create_announcement_html: "%{name} a créé une nouvelle annonce %{target}" create_custom_emoji_html: "%{name} a téléversé un nouvel émoji %{target}" create_domain_allow_html: "%{name} a autorisé la fédération avec le domaine %{target}" create_domain_block_html: "%{name} a bloqué le domaine %{target}" + create_email_domain_block_html: "%{name} a bloqué le domaine d'e-mail %{target}" create_ip_block_html: "%{name} a créé une règle pour l'IP %{target}" create_unavailable_domain_html: "%{name} a arrêté la livraison vers le domaine %{target}" create_user_role_html: "%{name} a créé le rôle %{target}" @@ -239,6 +247,7 @@ fr: destroy_custom_emoji_html: "%{name} a supprimé l'émoji %{target}" destroy_domain_allow_html: "%{name} a rejeté la fédération avec le domaine %{target}" destroy_domain_block_html: "%{name} a débloqué le domaine %{target}" + destroy_email_domain_block_html: "%{name} a débloqué le domaine d'e-mail %{target}" destroy_instance_html: "%{name} a purgé le domaine %{target}" destroy_ip_block_html: "%{name} a supprimé la règle pour l'IP %{target}" destroy_status_html: "%{name} a supprimé le message de %{target}" @@ -276,6 +285,7 @@ fr: filter_by_action: Filtrer par action filter_by_user: Filtrer par utilisateur·ice title: Journal d’audit + unavailable_instance: "(nom de domaine indisponible)" announcements: destroyed_msg: Annonce supprimée avec succès ! edit: @@ -413,6 +423,7 @@ fr: attempts_over_week: one: "%{count} tentative au cours de la dernière semaine" other: "%{count} tentatives au cours de la dernière semaine" + created_msg: Domaine d'e-mail bloqué avec succès delete: Supprimer dns: types: @@ -914,6 +925,10 @@ fr: statuses: allow: Autoriser le message allow_account: Autoriser l'auteur·rice + confirm_allow: Êtes-vous sûr de vouloir autoriser les statuts sélectionnés ? + confirm_allow_account: Êtes-vous sûr de vouloir autoriser les comptes sélectionnés ? + confirm_disallow: Êtes-vous sûr de vouloir rejeter les statuts sélectionnés ? + confirm_disallow_account: Êtes-vous sûr de vouloir rejeter les comptes sélectionnés ? description_html: Voici les messages dont votre serveur a connaissance qui sont beaucoup partagés et mis en favoris en ce moment. Cela peut aider vos utilisateur⋅rice⋅s, néophytes comme aguerri⋅e⋅s, à trouver plus de comptes à suivre. Aucun message n'est publiquement affiché tant que vous n'en avez pas approuvé l'auteur⋅rice, et seulement si icellui permet que son compte soit suggéré aux autres. Vous pouvez également autoriser ou rejeter les messages individuellement. disallow: Proscrire le message disallow_account: Proscrire l'auteur·rice @@ -1896,6 +1911,7 @@ fr: invalid_otp_token: Le code d’authentification à deux facteurs est invalide otp_lost_help_html: Si vous perdez accès aux deux, vous pouvez contacter %{email} rate_limited: Trop de tentatives d'authentification, réessayez plus tard. + seamless_external_login: Vous êtes connectés sur un service externe, de fait les paramètres de mot de passe et d'e-mail ne sont pas disponibles. signed_in_as: 'Connecté·e en tant que :' verification: extra_instructions_html: Astuce : Le lien sur votre site Web peut être invisible. La partie importante est rel="me" qui évite que soient pris en compte d’autres liens provenant de contenu générés par des utilisateurs tiers. Vous pouvez même utiliser une balise link dans l’en-tête de la page au lieu de a, mais le HTML doit être accessible sans avoir besoin d’exécuter du JavaScript. diff --git a/config/locales/he.yml b/config/locales/he.yml index 72b4156dbf..47ec5cafbe 100644 --- a/config/locales/he.yml +++ b/config/locales/he.yml @@ -1506,6 +1506,7 @@ he: media_attachments: validations: images_and_video: לא ניתן להוסיף וידאו להודעה שכבר מכילה תמונות + not_found: קובץ %{ids} לא נמצא, או שהוצמד כבר להודעה אחרת not_ready: לא ניתן להצמיד קבצים שהעלאתם לא הסתיימה. נסה/י שוב בעוד רגע! too_many: לא ניתן להוסיף יותר מארבעה קבצים migrations: diff --git a/config/locales/hu.yml b/config/locales/hu.yml index cdddc79b0e..2bf138d9be 100644 --- a/config/locales/hu.yml +++ b/config/locales/hu.yml @@ -1454,6 +1454,7 @@ hu: media_attachments: validations: images_and_video: Nem csatolhatsz videót olyan bejegyzéshez, amelyhez már csatoltál képet + not_found: A(z) %{ids} média nem található, vagy már egy másik bejegyzéshez lett csatolva not_ready: Nem lehet olyan fájlt csatolni, melynek még nem fejeződött be a feldolgozása. Próbáld kicsit később! too_many: Maximum négy fájlt csatolhatsz migrations: diff --git a/config/locales/is.yml b/config/locales/is.yml index 41347d44bb..2c73dbae74 100644 --- a/config/locales/is.yml +++ b/config/locales/is.yml @@ -1458,6 +1458,7 @@ is: media_attachments: validations: images_and_video: Ekki er hægt að hengja myndskeið við færslu sem þegar inniheldur myndir + not_found: Myndefnið %{ids} fannst ekki eða er þegar hengt við aðra færslu not_ready: Ekki er hægt að hengja við skrár sem ekki er búið að vinna til fulls. Prófaðu aftur eftir augnablik! too_many: Ekki er hægt að hengja við fleiri en 4 skrár migrations: diff --git a/config/locales/ko.yml b/config/locales/ko.yml index 9632a3027b..ef3775d4df 100644 --- a/config/locales/ko.yml +++ b/config/locales/ko.yml @@ -830,7 +830,7 @@ ko: sensitive: "%{name} 님이 %{target}의 계정을 민감함으로 표시했습니다" silence: "%{name} 님이 %{target}의 계정을 제한시켰습니다" suspend: "%{name} 님이 %{target}의 계정을 정지시켰습니다" - appeal_approved: 이의제기됨 + appeal_approved: 이의 받아들여짐 appeal_pending: 이의제기 대기중 appeal_rejected: 이의 제기 거절됨 system_checks: diff --git a/config/locales/nn.yml b/config/locales/nn.yml index 90b3d216c3..f301b8ca98 100644 --- a/config/locales/nn.yml +++ b/config/locales/nn.yml @@ -1454,6 +1454,7 @@ nn: media_attachments: validations: images_and_video: Kan ikkje leggja ved video til status som allereie inneheld bilete + not_found: Media %{ids} vart ikkje funne eller er allereie kopla til eit anna innlegg not_ready: Kan ikke legge til filer som ikke er ferdigbehandlet. Prøv igjen om et øyeblikk! too_many: Kan ikkje leggja til meir enn 4 filer migrations: diff --git a/config/locales/pt-BR.yml b/config/locales/pt-BR.yml index 418d3d059e..579dbd967f 100644 --- a/config/locales/pt-BR.yml +++ b/config/locales/pt-BR.yml @@ -4,7 +4,7 @@ pt-BR: about_mastodon_html: 'A rede social do futuro: Sem anúncios, sem vigilância corporativa, com design ético e muita descentralização! Possua seus próprios dados com o Mastodon!' contact_missing: Não definido contact_unavailable: Não disponível - hosted_on: Servidor Mastodon em %{domain} + hosted_on: Mastodon hospedado em %{domain} title: Sobre accounts: follow: Seguir @@ -31,6 +31,7 @@ pt-BR: created_msg: Nota de moderação criada! destroyed_msg: Nota de moderação excluída! accounts: + add_email_domain_block: Bloquear domínio de email approve: Aprovar approved_msg: O registro de %{username} foi aprovado are_you_sure: Você tem certeza? @@ -44,10 +45,10 @@ pt-BR: submit: Alterar e-mail title: Alterar e-mail para %{username} change_role: - changed_msg: Cargo alterado! - label: Alterar cargo - no_role: Sem cargo - title: Alterar cargo para %{username} + changed_msg: Função alterada com sucesso! + label: Alterar função + no_role: Nenhuma função + title: Alterar função para %{username} confirm: Confirmar confirmed: Confirmado confirming: Confirmando @@ -57,6 +58,7 @@ pt-BR: demote: Rebaixar destroyed_msg: Os dados de %{username} estão na fila para serem excluídos em breve disable: Congelar + disable_sign_in_token_auth: Desativar autenticação via token por email disable_two_factor_authentication: Desativar autenticação de dois fatores disabled: Congelada display_name: Nome de exibição @@ -65,6 +67,7 @@ pt-BR: email: E-mail email_status: Estado do e-mail enable: Descongelar + enable_sign_in_token_auth: Ativar autenticação via token por email enabled: Ativada enabled_msg: A conta de %{username} foi descongelada followers: Seguidores @@ -129,6 +132,7 @@ pt-BR: resubscribe: Reinscrever-se role: Cargo search: Buscar + search_same_email_domain: Outros usuários com o mesmo domínio de e-mail search_same_ip: Outros usuários com o mesmo IP security: Segurança security_measures: @@ -169,21 +173,26 @@ pt-BR: approve_appeal: Aprovar revisão approve_user: Aprovar usuário assigned_to_self_report: Atribuir denúncia + change_email_user: Alterar o Email para o usuário change_role_user: Alterar cargo do usuário confirm_user: Confirmar usuário create_account_warning: Criar aviso create_announcement: Criar anúncio + create_canonical_email_block: Criar bloqueio de Email create_custom_emoji: Criar emoji personalizado create_domain_allow: Permitir domínio create_domain_block: Bloquear domínio + create_email_domain_block: Criar Bloqueio de Domínio de Email create_ip_block: Criar regra de IP create_unavailable_domain: Criar domínio indisponível create_user_role: Criar cargo demote_user: Rebaixar usuário destroy_announcement: Excluir anúncio + destroy_canonical_email_block: Deletar bloqueio de Email destroy_custom_emoji: Excluir emoji personalizado destroy_domain_allow: Excluir domínio permitido destroy_domain_block: Desbloquear domínio + destroy_email_domain_block: Deletar bloqueio de domínio Email destroy_instance: Limpar domínio destroy_ip_block: Excluir regra de IP destroy_status: Excluir publicação @@ -191,8 +200,10 @@ pt-BR: destroy_user_role: Destruir cargo disable_2fa_user: Desativar autenticação de dois fatores disable_custom_emoji: Desativar emoji personalizado + disable_sign_in_token_auth_user: Desativar autenticação via Token de Email para Usuário disable_user: Desativar usuário enable_custom_emoji: Ativar emoji personalizado + enable_sign_in_token_auth_user: Desativar autenticação via token por e-mail para o usuário enable_user: Ativar usuário memorialize_account: Converter conta em memorial promote_user: Promover usuário @@ -215,6 +226,7 @@ pt-BR: update_custom_emoji: Editar Emoji Personalizado update_domain_block: Atualizar bloqueio de domínio update_ip_block: Atualizar regra de IP + update_report: Atualizar Relatório update_status: Editar Status update_user_role: Atualizar cargo actions: @@ -223,19 +235,24 @@ pt-BR: assigned_to_self_report_html: "%{name} atribuiu a denúncia %{target} para si" change_email_user_html: "%{name} alterou o endereço de e-mail do usuário %{target}" change_role_user_html: "%{name} alterou o cargo de %{target}" + confirm_user_html: "%{name} confirmou o endereço de e-mail do usuário %{target}" create_account_warning_html: "%{name} enviou um aviso para %{target}" create_announcement_html: "%{name} criou o novo anúncio %{target}" + create_canonical_email_block_html: "%{name} bloqueou o endereço de e-mail com o hash %{target}" create_custom_emoji_html: "%{name} enviou o novo emoji %{target}" create_domain_allow_html: "%{name} permitiu federação com domínio %{target}" create_domain_block_html: "%{name} bloqueou o domínio %{target}" + create_email_domain_block_html: "%{name} bloqueou o domínio de e-mail %{target}" create_ip_block_html: "%{name} criou a regra para o IP %{target}" create_unavailable_domain_html: "%{name} parou a entrega ao domínio %{target}" create_user_role_html: "%{name} criou o cargo %{target}" demote_user_html: "%{name} rebaixou o usuário %{target}" destroy_announcement_html: "%{name} excluiu o anúncio %{target}" + destroy_canonical_email_block_html: "%{name} desbloqueou o endereço e-mail com o hash %{target}" destroy_custom_emoji_html: "%{name} apagou o emoji %{target}" destroy_domain_allow_html: "%{name} bloqueou federação com domínio %{target}" destroy_domain_block_html: "%{name} desbloqueou o domínio %{target}" + destroy_email_domain_block_html: "%{name} desbloqueou o domínio de e-mail %{target}" destroy_instance_html: "%{name} limpou o domínio %{target}" destroy_ip_block_html: "%{name} excluiu a regra para o IP %{target}" destroy_status_html: "%{name} removeu a publicação de %{target}" @@ -243,8 +260,10 @@ pt-BR: destroy_user_role_html: "%{name} excluiu o cargo %{target}" disable_2fa_user_html: "%{name} desativou a exigência da autenticação de dois fatores para o usuário %{target}" disable_custom_emoji_html: "%{name} desativou o emoji %{target}" + disable_sign_in_token_auth_user_html: "%{name} desativou a autenticação via token por e-mail para %{target}" disable_user_html: "%{name} desativou o login para %{target}" enable_custom_emoji_html: "%{name} ativou o emoji %{target}" + enable_sign_in_token_auth_user_html: "%{name} ativou a autenticação via token por e-mail para %{target}" enable_user_html: "%{name} ativou o login para %{target}" memorialize_account_html: "%{name} transformou a conta de %{target} em um memorial" promote_user_html: "%{name} promoveu o usuário %{target}" @@ -252,6 +271,7 @@ pt-BR: reject_user_html: "%{name} rejeitou a inscrição de %{target}" remove_avatar_user_html: "%{name} removeu a imagem de perfil de %{target}" reopen_report_html: "%{name} reabriu a denúncia %{target}" + resend_user_html: "%{name} reenviou um e-mail de confirmação para %{target}" reset_password_user_html: "%{name} redefiniu a senha de %{target}" resolve_report_html: "%{name} resolveu a denúncia %{target}" sensitive_account_html: "%{name} marcou a mídia de %{target} como sensível" @@ -412,6 +432,7 @@ pt-BR: attempts_over_week: one: "%{count} tentativa na última semana" other: "%{count} tentativas de inscrição na última semana" + created_msg: Domínio de e-mail bloqueado com sucesso delete: Excluir dns: types: @@ -420,8 +441,11 @@ pt-BR: new: create: Adicionar domínio resolve: Resolver domínio + title: Bloquear novo domínio de e-mail not_permitted: Não permitido + resolved_dns_records_hint_html: O nome de domínio é associado aos seguintes domínios MX, que são responsáveis por aceitar e-mails. Ao bloquear um domínio MX, você bloqueará as inscrições de qualquer endereço de e-mail que use o mesmo domínio MX, mesmo que o nome de domínio visível seja diferente. Tenha cuidado para não bloquear os principais provedores de e-mail. resolved_through_html: Resolvido através de %{domain} + title: Domínios de e-mail bloqueados export_domain_allows: new: title: Importar domínios permitidos @@ -446,6 +470,9 @@ pt-BR: title: Recomendações de contas unsuppress: Restaurar recomendação de contas instances: + audit_log: + title: Logs de auditoria recentes + view_all: Ver todos os logs de auditoria availability: description_html: one: Se a entrega ao domínio falhar em %{count} dia sem sucesso, nenhuma tentativa de entrega será feita a menos que uma entrega do domínio seja recebida. @@ -572,6 +599,7 @@ pt-BR: resolve_description_html: Nenhuma ação será tomada contra a conta denunciada, nenhuma violação será guardada e a denúncia será encerrada. silence_description_html: A conta ficará visível apenas para aqueles que já a seguem ou que a procuram manualmente, limitando severamente seu alcance. Pode ser revertido a qualquer momento. Fecha todas as denúncias desta conta. suspend_description_html: A conta e todo o seu conteúdo ficará inacessível e, eventualmente, excluído e interagir com ela será impossível. Reversível dentro de 30 dias. Encerra todas as denúncias contra esta conta. + actions_description_html: Decida qual ação tomar para responder a essa denúncia. Se você tomar uma ação punitiva contra a conta denunciada, uma notificação por e-mail será enviada ao usuário, exceto quando a categoria Spam for selecionada. actions_description_remote_html: Decida quais medidas tomará para resolver esta denúncia. Isso só afetará como seu servidor se comunica com esta conta remota e manipula seu conteúdo. add_to_report: Adicionar mais à denúncia already_suspended_badges: @@ -613,6 +641,7 @@ pt-BR: report: 'Denúncia #%{id}' reported_account: Conta denunciada reported_by: Denunciada por + reported_with_application: Denunciado pelo aplicativo resolved: Resolvido resolved_msg: Denúncia resolvida! skip_to_actions: Pular para ações @@ -635,6 +664,7 @@ pt-BR: delete_data_html: Exclua o perfil e o conteúdo de @%{acct} daqui a 30 dias, a menos que a suspensão seja desfeita nesse meio tempo preview_preamble_html: "@%{acct} receberá um aviso com o seguinte conteúdo:" record_strike_html: Registre uma ação contra @%{acct} para te ajudar em futuras violações desta conta + send_email_html: Enviar @%{acct} um e-mail de alerta warning_placeholder: Argumentos adicionais para a ação de moderação. target_origin: Origem da conta denunciada title: Denúncias @@ -674,6 +704,7 @@ pt-BR: manage_appeals: Gerenciar revisões manage_appeals_description: Permite aos usuários visualizar as revisões das decisões da moderação manage_blocks: Gerenciar Bloqueios + manage_blocks_description: Permite aos usuários bloquear provedores de e-mail e endereços IP manage_custom_emojis: Gerenciar Emojis Personalizados manage_custom_emojis_description: Permite aos usuários gerenciar emojis personalizados no servidor manage_federation: Gerenciar Federação @@ -691,6 +722,7 @@ pt-BR: manage_taxonomies: Gerenciar taxonomias manage_taxonomies_description: Permite aos usuários rever o conteúdo em alta e atualizar as configurações de hashtag manage_user_access: Gerenciar Acesso de Usuário + manage_user_access_description: Permite aos usuários desativar a autenticação de dois fatores de outros usuários, alterar seu endereço de e-mail e redefinir sua senha manage_users: Gerenciar usuários manage_users_description: Permite aos usuários ver os detalhes de outros usuários e executar ações de moderação contra eles manage_webhooks: Gerenciar Webhooks @@ -765,6 +797,7 @@ pt-BR: destroyed_msg: Upload do site excluído com sucesso! software_updates: critical_update: Crítico — por favor, atualize rapidamente + description: É recomendável que você mantenha a instalação do Mastodon atualizada para se beneficiar das correções e das novas funcionalidades. Além disso, às vezes é imprescindível atualizar o Mastodon rapidamente para evitar problemas de segurança. Por esses motivos, o Mastodon verifica se há atualizações a cada 30 minutos e notificará você de acordo com as suas preferências de notificação por e-mail. documentation_link: Saiba mais release_notes: Notas de lançamento title: Atualizações disponíveis @@ -851,16 +884,39 @@ pt-BR: action: Confira aqui para mais informações message_html: "Seu armazenamento de objetos está mal configurado. A privacidade de seus usuários está em risco." tags: + moderation: + not_trendable: Fora de moda + not_usable: Não utilizável + pending_review: Revisão pendente + review_requested: Revisão solicitada + reviewed: Revisado + title: Status + trendable: Tendências + unreviewed: Não revisado + usable: Utilizável + name: Nome + newest: Mais recente + oldest: Mais antigos + open: Visualizar Publicamente + reset: Reinicializar review: Status da revisão + search: Buscar + title: Hashtags updated_msg: Configurações de hashtag atualizadas title: Administração trends: allow: Permitir approved: Aprovado + confirm_allow: Você tem certeza que deseja permitir as tags selecionadas? + confirm_disallow: Você tem certeza de que deseja vetar as tags selecionadas? disallow: Impedir links: allow: Permitir link allow_provider: Permitir editor + confirm_allow: Tem certeza que deseja permitir os links selecionados? + confirm_allow_provider: Tem certeza que deseja permitir os provedores selecionados? + confirm_disallow: Tem certeza que deseja vetar os links selecionados? + confirm_disallow_provider: Tem certeza que deseja vetar os provedores selecionados? description_html: Estes são links que estão sendo compartilhados por contas que seu servidor vê. Você pode ajudar seus usuários a descobrir o que está acontecendo no mundo. Nenhum link é exibido publicamente até que você aprove o editor. Você também pode permitir ou rejeitar links individuais. disallow: Proibir link disallow_provider: Proibir autor @@ -884,6 +940,10 @@ pt-BR: statuses: allow: Permitir publicação allow_account: Permitir autor + confirm_allow: Tem certeza que deseja permitir os status selecionados? + confirm_allow_account: Tem certeza que deseja permitir as contas selecionadas? + confirm_disallow: Tem certeza que deseja vetar os status selecionados? + confirm_disallow_account: Tem certeza que deseja vetar as contas selecionadas? description_html: Estes são as publicações que seu servidor sabe que estão sendo muito compartilhadas e favorecidas no momento. Isso pode ajudar seus usuários, novos e atuais, a encontrar mais pessoas para seguir. Nenhuma publicação é exibida publicamente até que você aprove o autor e o autor permitir que sua conta seja sugerida a outros. Você também pode permitir ou rejeitar publicações individuais. disallow: Proibir publicação disallow_account: Proibir autor @@ -916,6 +976,7 @@ pt-BR: used_by_over_week: one: Usado por uma pessoa na última semana other: Usado por %{count} pessoas na última semana + title: Recomendações e tendências trending: Em alta warning_presets: add_new: Adicionar novo @@ -1000,7 +1061,9 @@ pt-BR: guide_link_text: Todos podem contribuir. sensitive_content: Conteúdo sensível application_mailer: + notification_preferences: Alterar preferências de e-mail salutation: "%{name}," + settings: 'Alterar preferências de e-mail: %{link}' unsubscribe: Desinscrever view: 'Ver:' view_profile: Ver perfil @@ -1020,6 +1083,7 @@ pt-BR: hint_html: Só mais uma coisa! Precisamos confirmar que você é um humano (isso é para que possamos evitar o spam!). Resolva o CAPTCHA abaixo e clique em "Continuar". title: Verificação de segurança confirmations: + awaiting_review: Seu endereço de e-mail está confirmado! A equipe %{domain} está agora revisando a sua inscrição. Você receberá um e-mail se a sua conta for aprovada! awaiting_review_title: Seu cadastro está sendo analisado clicking_this_link: clicar este link login_link: entrar @@ -1027,6 +1091,7 @@ pt-BR: redirect_to_app_html: Você deveria ter sido redirecionado para o aplicativo %{app_name}. Se isso não aconteceu, tente %{clicking_this_link} ou volte manualmente para o aplicativo. registration_complete: Seu cadastro no %{domain} foi concluído! welcome_title: Boas vindas, %{name}! + wrong_email_hint: Se esse endereço de e-mail não estiver correto, você pode alterá-lo nas configurações da conta. delete_account: Excluir conta delete_account_html: Se você deseja excluir sua conta, você pode fazer isso aqui. Uma confirmação será solicitada. description: @@ -1047,6 +1112,7 @@ pt-BR: or_log_in_with: Ou entre com privacy_policy_agreement_html: Eu li e concordo com a política de privacidade progress: + confirm: Confirmar e-mail details: Suas informações review: Nossa avaliação rules: Aceitar regras @@ -1068,8 +1134,10 @@ pt-BR: security: Segurança set_new_password: Definir uma nova senha setup: + email_below_hint_html: Verifique a sua pasta de spam, ou solicite outra. Você pode corrigir o seu endereço de e-mail se estiver errado. email_settings_hint_html: Clique no link que te enviamos para verificar %{email}. Esperaremos aqui. link_not_received: Não recebeu um link? + new_confirmation_instructions_sent: Você receberá um novo e-mail com o link de confirmação em alguns minutos! title: Verifique sua caixa de entrada sign_in: preamble_html: Entre com suas credenciais de domínios ( %{domain} ) . Se sua conta estiver hospedada em um servidor diferente, você não deve conseguir acessar este conteúdo. @@ -1080,7 +1148,9 @@ pt-BR: title: Então vamos lá criar uma conta em %{domain}. status: account_status: Status da conta + confirming: Confirmação por e-mail pendente. functional: Sua conta está totalmente operacional. + pending: Sua inscrição está aguardando revisão pela nossa equipe. Isto pode levar algum tempo. Você receberá um e-mail se sua inscrição for aprovada. redirecting_to: Sua conta está inativa porque atualmente está redirecionando para %{acct}. self_destruct: Como %{domain} está se encerrando, você só terá acesso limitado à sua conta. view_strikes: Veja os avisos anteriores em relação à sua conta @@ -1123,6 +1193,9 @@ pt-BR: before: 'Antes de prosseguir, leia com cuidado:' caches: Conteúdo que foi armazenado em cache por outros servidores pode continuar a existir data_removal: Suas publicações e outros dados serão removidos permanentemente + email_change_html: Você pode alterar seu endereço de e-mail sem excluir sua conta + email_contact_html: Se ainda não chegar, você pode enviar um e-mail para %{email} para obter ajuda + email_reconfirmation_html: Se você não recebeu o e-mail de confirmação, você pode solicitá-lo novamente irreversible: Você não conseguirá restaurar ou reativar a sua conta more_details_html: Para mais detalhes, consulte a Política de Privacidade. username_available: Seu nome de usuário ficará disponível novamente @@ -1355,6 +1428,7 @@ pt-BR: authentication_methods: otp: autenticação de dois fatores password: senha + sign_in_token: código de segurança do e-mail webauthn: chaves de segurança description_html: Se você vir atividades suspeitas ou não reconhecidas, considere alterar sua senha e ativar a autenticação de dois fatores. empty: Sem histórico de autenticação disponível @@ -1365,10 +1439,14 @@ pt-BR: unsubscribe: action: Sim, cancelar subscrição complete: Desinscrito + confirmation_html: Tem certeza que deseja cancelar a assinatura de %{type} para Mastodon no %{domain} para o seu endereço de e-mail %{email}? Você sempre pode se inscrever novamente nas configurações de notificação de email. + resubscribe_html: Se você cancelou sua inscrição por engano, você pode se inscrever novamente em suas configurações de notificações por e-mail. + success_html: Você não mais receberá %{type} no Mastodon em %{domain} ao seu endereço de e-mail %{email}. title: Cancelar inscrição media_attachments: validations: images_and_video: Não foi possível anexar um vídeo a uma publicação que já contém imagens + not_found: Mídia %{ids} não encontrada ou já anexada a outra publicação not_ready: Não é possível anexar arquivos que não terminaram de ser processados. Tente novamente daqui a pouco! too_many: Não foi possível anexar mais de 4 imagens migrations: @@ -1445,6 +1523,8 @@ pt-BR: update: subject: "%{name} editou uma publicação" notifications: + administration_emails: Notificações de e-mail do administrador + email_events: Eventos para notificações por e-mail email_events_hint: 'Selecione os eventos que deseja receber notificações:' number: human: @@ -1603,6 +1683,7 @@ pt-BR: import: Importar import_and_export: Importar e exportar migrate: Migração de conta + notifications: Notificações por e-mail preferences: Preferências profile: Perfil relationships: Seguindo e seguidores @@ -1849,6 +1930,7 @@ pt-BR: invalid_otp_token: Código de dois fatores inválido otp_lost_help_html: Se você perder o acesso à ambos, você pode entrar em contato com %{email} rate_limited: Muitas tentativas de autenticação; tente novamente mais tarde. + seamless_external_login: Você está logado através de um serviço externo, portanto as configurações de senha e e-mail não estão disponíveis. signed_in_as: 'Entrou como:' verification: extra_instructions_html: Dica: O link do seu site não precisa ser visível. O importante é a parte rel="me", que impede a personificação em sites com conteúdo gerado pelo usuário. Você pode até usar uma tag link no cabeçalho da página ao invés de uma tag a, mas é importante que o HTML esteja acessível sem executar JavaScript. diff --git a/config/locales/simple_form.pt-BR.yml b/config/locales/simple_form.pt-BR.yml index fc3c09cf1d..65d3883690 100644 --- a/config/locales/simple_form.pt-BR.yml +++ b/config/locales/simple_form.pt-BR.yml @@ -211,6 +211,7 @@ pt-BR: setting_default_privacy: Privacidade dos toots setting_default_sensitive: Sempre marcar mídia como sensível setting_delete_modal: Solicitar confirmação antes de excluir toot + setting_disable_hover_cards: Desativar visualização de perfil ao passar o mouse por cima setting_disable_swiping: Desabilitar movimentos deslizantes setting_display_media: Exibição das mídias setting_display_media_default: Padrão @@ -242,11 +243,13 @@ pt-BR: warn: Ocultar com um aviso form_admin_settings: activity_api_enabled: Publicar estatísticas agregadas sobre atividade de usuários na API + app_icon: Ícone do aplicativo backups_retention_period: Período de retenção do arquivo de usuário bootstrap_timeline_accounts: Sempre recomendar essas contas para novos usuários closed_registrations_message: Mensagem personalizada quando inscrições não estão disponíveis content_cache_retention_period: Período de retenção de conteúdo remoto custom_css: CSS personalizável + favicon: Favicon mascot: Mascote personalizado (legado) media_cache_retention_period: Período de retenção do cachê de mídia peers_api_enabled: Publicar lista de instâncias de servidor descobertas na API @@ -311,6 +314,7 @@ pt-BR: listable: Permitir que esta hashtag apareça em pesquisas e sugestões name: Hashtag trendable: Permitir que esta hashtag fique em alta + usable: Permitir que as publicações usem esta hashtag localmente user: role: Cargo time_zone: Fuso horário diff --git a/config/locales/tr.yml b/config/locales/tr.yml index fc9fde3615..4318f4eac4 100644 --- a/config/locales/tr.yml +++ b/config/locales/tr.yml @@ -1454,6 +1454,7 @@ tr: media_attachments: validations: images_and_video: Zaten resim içeren bir duruma video eklenemez + not_found: "%{ids} medya dosyaları bulunamadı veya başka bir gönderiye zaten eklenmiş" not_ready: İşlemi tamamlanmamış dosyalar eklenemez. Birazdan tekrar deneyin! too_many: 4'ten fazla dosya eklenemiyor migrations: From 58df00f04d39cf25e7d4d4cbb111bc4cfe1875c4 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Wed, 4 Sep 2024 04:52:37 -0400 Subject: [PATCH 089/153] Extract method for self-referencing records in `AccountStatusCleanupPolicy` (#31244) --- app/models/account_statuses_cleanup_policy.rb | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/app/models/account_statuses_cleanup_policy.rb b/app/models/account_statuses_cleanup_policy.rb index a102795446..e2c035284b 100644 --- a/app/models/account_statuses_cleanup_policy.rb +++ b/app/models/account_statuses_cleanup_policy.rb @@ -145,15 +145,15 @@ class AccountStatusesCleanupPolicy < ApplicationRecord end def without_self_fav_scope - Status.where('NOT EXISTS (SELECT 1 FROM favourites fav WHERE fav.account_id = statuses.account_id AND fav.status_id = statuses.id)') + Status.where.not(self_status_reference_exists(Favourite)) end def without_self_bookmark_scope - Status.where('NOT EXISTS (SELECT 1 FROM bookmarks bookmark WHERE bookmark.account_id = statuses.account_id AND bookmark.status_id = statuses.id)') + Status.where.not(self_status_reference_exists(Bookmark)) end def without_pinned_scope - Status.where('NOT EXISTS (SELECT 1 FROM status_pins pin WHERE pin.account_id = statuses.account_id AND pin.status_id = statuses.id)') + Status.where.not(self_status_reference_exists(StatusPin)) end def without_media_scope @@ -174,4 +174,13 @@ class AccountStatusesCleanupPolicy < ApplicationRecord def account_statuses Status.where(account_id: account_id) end + + def self_status_reference_exists(model) + model + .where(model.arel_table[:account_id].eq Status.arel_table[:account_id]) + .where(model.arel_table[:status_id].eq Status.arel_table[:id]) + .select(1) + .arel + .exists + end end From ffe29ce4174673cd4b19d0ef330c56e584f284e6 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 4 Sep 2024 08:58:28 +0000 Subject: [PATCH 090/153] Update dependency shoulda-matchers to v6.4.0 (#31731) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile.lock b/Gemfile.lock index 09be3e6921..a533b66241 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -790,7 +790,7 @@ GEM rubyzip (>= 1.2.2, < 3.0) websocket (~> 1.0) semantic_range (3.0.0) - shoulda-matchers (6.3.1) + shoulda-matchers (6.4.0) activesupport (>= 5.2.0) sidekiq (6.5.12) connection_pool (>= 2.2.5, < 3) From d8bd9ef19082ab3bccd4a8d2b6727e56de25b335 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 4 Sep 2024 09:25:25 +0000 Subject: [PATCH 091/153] Update eslint (non-major) (#31684) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- package.json | 4 +- yarn.lock | 193 +++++++++++++++++++++++++++++---------------------- 2 files changed, 113 insertions(+), 84 deletions(-) diff --git a/package.json b/package.json index a6f86dfd4c..ddf7ee75a2 100644 --- a/package.json +++ b/package.json @@ -175,9 +175,9 @@ "eslint-define-config": "^2.0.0", "eslint-import-resolver-typescript": "^3.5.5", "eslint-plugin-formatjs": "^4.10.1", - "eslint-plugin-import": "~2.29.0", + "eslint-plugin-import": "~2.30.0", "eslint-plugin-jsdoc": "^50.0.0", - "eslint-plugin-jsx-a11y": "~6.9.0", + "eslint-plugin-jsx-a11y": "~6.10.0", "eslint-plugin-promise": "~7.1.0", "eslint-plugin-react": "^7.33.2", "eslint-plugin-react-hooks": "^4.6.0", diff --git a/yarn.lock b/yarn.lock index 727dfacd92..e9ab694ffe 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2819,9 +2819,9 @@ __metadata: eslint-define-config: "npm:^2.0.0" eslint-import-resolver-typescript: "npm:^3.5.5" eslint-plugin-formatjs: "npm:^4.10.1" - eslint-plugin-import: "npm:~2.29.0" + eslint-plugin-import: "npm:~2.30.0" eslint-plugin-jsdoc: "npm:^50.0.0" - eslint-plugin-jsx-a11y: "npm:~6.9.0" + eslint-plugin-jsx-a11y: "npm:~6.10.0" eslint-plugin-promise: "npm:~7.1.0" eslint-plugin-react: "npm:^7.33.2" eslint-plugin-react-hooks: "npm:^4.6.0" @@ -2972,6 +2972,13 @@ __metadata: languageName: node linkType: hard +"@nolyfill/is-core-module@npm:1.0.39": + version: 1.0.39 + resolution: "@nolyfill/is-core-module@npm:1.0.39" + checksum: 10c0/34ab85fdc2e0250879518841f74a30c276bca4f6c3e13526d2d1fe515e1adf6d46c25fcd5989d22ea056d76f7c39210945180b4859fc83b050e2da411aa86289 + languageName: node + linkType: hard + "@npmcli/agent@npm:^2.0.0": version: 2.2.0 resolution: "@npmcli/agent@npm:2.2.0" @@ -3180,6 +3187,13 @@ __metadata: languageName: node linkType: hard +"@rtsao/scc@npm:^1.1.0": + version: 1.1.0 + resolution: "@rtsao/scc@npm:1.1.0" + checksum: 10c0/b5bcfb0d87f7d1c1c7c0f7693f53b07866ed9fec4c34a97a8c948fb9a7c0082e416ce4d3b60beb4f5e167cbe04cdeefbf6771320f3ede059b9ce91188c409a5b + languageName: node + linkType: hard + "@sinclair/typebox@npm:^0.27.8": version: 0.27.8 resolution: "@sinclair/typebox@npm:0.27.8" @@ -4830,7 +4844,7 @@ __metadata: languageName: node linkType: hard -"array-includes@npm:^3.1.6, array-includes@npm:^3.1.7, array-includes@npm:^3.1.8": +"array-includes@npm:^3.1.6, array-includes@npm:^3.1.8": version: 3.1.8 resolution: "array-includes@npm:3.1.8" dependencies: @@ -4888,16 +4902,17 @@ __metadata: languageName: node linkType: hard -"array.prototype.findlastindex@npm:^1.2.3": - version: 1.2.3 - resolution: "array.prototype.findlastindex@npm:1.2.3" +"array.prototype.findlastindex@npm:^1.2.5": + version: 1.2.5 + resolution: "array.prototype.findlastindex@npm:1.2.5" dependencies: - call-bind: "npm:^1.0.2" - define-properties: "npm:^1.2.0" - es-abstract: "npm:^1.22.1" - es-shim-unscopables: "npm:^1.0.0" - get-intrinsic: "npm:^1.2.1" - checksum: 10c0/2c5c4d3f07512d6729f728f6260a314c00f2eb0a243123092661fa1bc65dce90234c3b483b5f978396eccef6f69c50f0bea248448aaf9cdfcd1cedad6217acbb + call-bind: "npm:^1.0.7" + define-properties: "npm:^1.2.1" + es-abstract: "npm:^1.23.2" + es-errors: "npm:^1.3.0" + es-object-atoms: "npm:^1.0.0" + es-shim-unscopables: "npm:^1.0.2" + checksum: 10c0/962189487728b034f3134802b421b5f39e42ee2356d13b42d2ddb0e52057ffdcc170b9524867f4f0611a6f638f4c19b31e14606e8bcbda67799e26685b195aa3 languageName: node linkType: hard @@ -5113,10 +5128,10 @@ __metadata: languageName: node linkType: hard -"axe-core@npm:^4.9.1": - version: 4.9.1 - resolution: "axe-core@npm:4.9.1" - checksum: 10c0/ac9e5a0c6fa115a43ebffc32a1d2189e1ca6431b5a78e88cdcf94a72a25c5964185682edd94fe6bdb1cb4266c0d06301b022866e0e50dcdf6e3cefe556470110 +"axe-core@npm:^4.10.0": + version: 4.10.0 + resolution: "axe-core@npm:4.10.0" + checksum: 10c0/732c171d48caaace5e784895c4dacb8ca6155e9d98045138ebe3952f78457dd05b92c57d05b41ce2a570aff87dbd0471e8398d2c0f6ebe79617b746c8f658998 languageName: node linkType: hard @@ -5131,12 +5146,10 @@ __metadata: languageName: node linkType: hard -"axobject-query@npm:~3.1.1": - version: 3.1.1 - resolution: "axobject-query@npm:3.1.1" - dependencies: - deep-equal: "npm:^2.0.5" - checksum: 10c0/fff3175a22fd1f41fceb7ae0cd25f6594a0d7fba28c2335dd904538b80eb4e1040432564a3c643025cd2bb748f68d35aaabffb780b794da97ecfc748810b25ad +"axobject-query@npm:^4.1.0": + version: 4.1.0 + resolution: "axobject-query@npm:4.1.0" + checksum: 10c0/c470e4f95008f232eadd755b018cb55f16c03ccf39c027b941cd8820ac6b68707ce5d7368a46756db4256fbc91bb4ead368f84f7fb034b2b7932f082f6dc0775 languageName: node linkType: hard @@ -6906,7 +6919,7 @@ __metadata: languageName: node linkType: hard -"debug@npm:4, debug@npm:^4.1.0, debug@npm:^4.1.1, debug@npm:^4.3.1, debug@npm:^4.3.2, debug@npm:^4.3.4, debug@npm:^4.3.6, debug@npm:~4.3.6": +"debug@npm:4, debug@npm:^4.1.0, debug@npm:^4.1.1, debug@npm:^4.3.1, debug@npm:^4.3.2, debug@npm:^4.3.4, debug@npm:^4.3.5, debug@npm:^4.3.6, debug@npm:~4.3.6": version: 4.3.6 resolution: "debug@npm:4.3.6" dependencies: @@ -7515,13 +7528,13 @@ __metadata: languageName: node linkType: hard -"enhanced-resolve@npm:^5.12.0": - version: 5.15.0 - resolution: "enhanced-resolve@npm:5.15.0" +"enhanced-resolve@npm:^5.15.0": + version: 5.17.1 + resolution: "enhanced-resolve@npm:5.17.1" dependencies: graceful-fs: "npm:^4.2.4" tapable: "npm:^2.2.0" - checksum: 10c0/69984a7990913948b4150855aed26a84afb4cb1c5a94fb8e3a65bd00729a73fc2eaff6871fb8e345377f294831afe349615c93560f2f54d61b43cdfdf668f19a + checksum: 10c0/81a0515675eca17efdba2cf5bad87abc91a528fc1191aad50e275e74f045b41506167d420099022da7181c8d787170ea41e4a11a0b10b7a16f6237daecb15370 languageName: node linkType: hard @@ -7824,32 +7837,39 @@ __metadata: linkType: hard "eslint-import-resolver-typescript@npm:^3.5.5": - version: 3.6.1 - resolution: "eslint-import-resolver-typescript@npm:3.6.1" + version: 3.6.3 + resolution: "eslint-import-resolver-typescript@npm:3.6.3" dependencies: - debug: "npm:^4.3.4" - enhanced-resolve: "npm:^5.12.0" - eslint-module-utils: "npm:^2.7.4" - fast-glob: "npm:^3.3.1" - get-tsconfig: "npm:^4.5.0" - is-core-module: "npm:^2.11.0" + "@nolyfill/is-core-module": "npm:1.0.39" + debug: "npm:^4.3.5" + enhanced-resolve: "npm:^5.15.0" + eslint-module-utils: "npm:^2.8.1" + fast-glob: "npm:^3.3.2" + get-tsconfig: "npm:^4.7.5" + is-bun-module: "npm:^1.0.2" is-glob: "npm:^4.0.3" peerDependencies: eslint: "*" eslint-plugin-import: "*" - checksum: 10c0/cb1cb4389916fe78bf8c8567aae2f69243dbfe624bfe21078c56ad46fa1ebf0634fa7239dd3b2055ab5c27359e4b4c28b69b11fcb3a5df8a9e6f7add8e034d86 + eslint-plugin-import-x: "*" + peerDependenciesMeta: + eslint-plugin-import: + optional: true + eslint-plugin-import-x: + optional: true + checksum: 10c0/5933b00791b7b077725b9ba9a85327d2e2dc7c8944c18a868feb317a0bf0e1e77aed2254c9c5e24dcc49360d119331d2c15281837f4269592965ace380a75111 languageName: node linkType: hard -"eslint-module-utils@npm:^2.7.4, eslint-module-utils@npm:^2.8.0": - version: 2.8.0 - resolution: "eslint-module-utils@npm:2.8.0" +"eslint-module-utils@npm:^2.8.1, eslint-module-utils@npm:^2.9.0": + version: 2.9.0 + resolution: "eslint-module-utils@npm:2.9.0" dependencies: debug: "npm:^3.2.7" peerDependenciesMeta: eslint: optional: true - checksum: 10c0/c7a8d1a58d76ec8217a8fea49271ec8132d1b9390965a75f6a4ecbc9e5983d742195b46d2e4378231d2186801439fe1aa5700714b0bfd4eb17aac6e1b65309df + checksum: 10c0/7c45c5b54402a969e99315890c10e9bf8c8bee16c7890573343af05dfa04566d61546585678c413e5228af0550e39461be47e35a8ff0d1863e113bdbb28d1d29 languageName: node linkType: hard @@ -7874,30 +7894,31 @@ __metadata: languageName: node linkType: hard -"eslint-plugin-import@npm:~2.29.0": - version: 2.29.1 - resolution: "eslint-plugin-import@npm:2.29.1" +"eslint-plugin-import@npm:~2.30.0": + version: 2.30.0 + resolution: "eslint-plugin-import@npm:2.30.0" dependencies: - array-includes: "npm:^3.1.7" - array.prototype.findlastindex: "npm:^1.2.3" + "@rtsao/scc": "npm:^1.1.0" + array-includes: "npm:^3.1.8" + array.prototype.findlastindex: "npm:^1.2.5" array.prototype.flat: "npm:^1.3.2" array.prototype.flatmap: "npm:^1.3.2" debug: "npm:^3.2.7" doctrine: "npm:^2.1.0" eslint-import-resolver-node: "npm:^0.3.9" - eslint-module-utils: "npm:^2.8.0" - hasown: "npm:^2.0.0" - is-core-module: "npm:^2.13.1" + eslint-module-utils: "npm:^2.9.0" + hasown: "npm:^2.0.2" + is-core-module: "npm:^2.15.1" is-glob: "npm:^4.0.3" minimatch: "npm:^3.1.2" - object.fromentries: "npm:^2.0.7" - object.groupby: "npm:^1.0.1" - object.values: "npm:^1.1.7" + object.fromentries: "npm:^2.0.8" + object.groupby: "npm:^1.0.3" + object.values: "npm:^1.2.0" semver: "npm:^6.3.1" tsconfig-paths: "npm:^3.15.0" peerDependencies: eslint: ^2 || ^3 || ^4 || ^5 || ^6 || ^7.2.0 || ^8 - checksum: 10c0/5f35dfbf4e8e67f741f396987de9504ad125c49f4144508a93282b4ea0127e052bde65ab6def1f31b6ace6d5d430be698333f75bdd7dca3bc14226c92a083196 + checksum: 10c0/4c9dcb1f27505c4d5dd891d2b551f56c70786d136aa3992a77e785bdc67c9f60200a2c7fb0ce55b7647fe550b12bc433d5dfa59e2c00ab44227791c5ab86badf languageName: node linkType: hard @@ -7922,16 +7943,16 @@ __metadata: languageName: node linkType: hard -"eslint-plugin-jsx-a11y@npm:~6.9.0": - version: 6.9.0 - resolution: "eslint-plugin-jsx-a11y@npm:6.9.0" +"eslint-plugin-jsx-a11y@npm:~6.10.0": + version: 6.10.0 + resolution: "eslint-plugin-jsx-a11y@npm:6.10.0" dependencies: aria-query: "npm:~5.1.3" array-includes: "npm:^3.1.8" array.prototype.flatmap: "npm:^1.3.2" ast-types-flow: "npm:^0.0.8" - axe-core: "npm:^4.9.1" - axobject-query: "npm:~3.1.1" + axe-core: "npm:^4.10.0" + axobject-query: "npm:^4.1.0" damerau-levenshtein: "npm:^1.0.8" emoji-regex: "npm:^9.2.2" es-iterator-helpers: "npm:^1.0.19" @@ -7943,8 +7964,8 @@ __metadata: safe-regex-test: "npm:^1.0.3" string.prototype.includes: "npm:^2.0.0" peerDependencies: - eslint: ^3 || ^4 || ^5 || ^6 || ^7 || ^8 - checksum: 10c0/72ac719ca90b6149c8f3c708ac5b1177f6757668b6e174d72a78512d4ac10329331b9c666c21e9561237a96a45d7f147f6a5d270dadbb99eb4ee093f127792c3 + eslint: ^3 || ^4 || ^5 || ^6 || ^7 || ^8 || ^9 + checksum: 10c0/9f8e29a3317fb6a82e2ecd333fe0fab3a69fff786d087eb65dc723d6e954473ab681d14a252d7cb2971f5e7f68816cb6f7731766558e1833a77bd73af1b5ab34 languageName: node linkType: hard @@ -7967,8 +7988,8 @@ __metadata: linkType: hard "eslint-plugin-react@npm:^7.33.2": - version: 7.35.0 - resolution: "eslint-plugin-react@npm:7.35.0" + version: 7.35.2 + resolution: "eslint-plugin-react@npm:7.35.2" dependencies: array-includes: "npm:^3.1.8" array.prototype.findlast: "npm:^1.2.5" @@ -7990,7 +8011,7 @@ __metadata: string.prototype.repeat: "npm:^1.0.0" peerDependencies: eslint: ^3 || ^4 || ^5 || ^6 || ^7 || ^8 || ^9.7 - checksum: 10c0/eedcc33de4b2cda91d56ae517a4f771a0c76da9c1e26c95543969012871381e11d4d6cffdf6fa8423036585c289eb3500f3f93fb1d314fb2624e0aa1e463305e + checksum: 10c0/5f891f5a77e902a0ca8d10b23d0b800e90a09400187febe5986c5078d6277baa4b974d6acdbba25baae065dbcf12eb9241b5f5782527d0780314c2ee5006a8af languageName: node linkType: hard @@ -8402,7 +8423,7 @@ __metadata: languageName: node linkType: hard -"fast-glob@npm:^3.2.9, fast-glob@npm:^3.3.1, fast-glob@npm:^3.3.2": +"fast-glob@npm:^3.2.9, fast-glob@npm:^3.3.2": version: 3.3.2 resolution: "fast-glob@npm:3.3.2" dependencies: @@ -8931,12 +8952,12 @@ __metadata: languageName: node linkType: hard -"get-tsconfig@npm:^4.5.0": - version: 4.7.2 - resolution: "get-tsconfig@npm:4.7.2" +"get-tsconfig@npm:^4.7.5": + version: 4.8.0 + resolution: "get-tsconfig@npm:4.8.0" dependencies: resolve-pkg-maps: "npm:^1.0.0" - checksum: 10c0/169b2beababfbb16e8a0ae813ee59d3e14d4960231c816615161ab5be68ec07a394dce59695742ac84295e2efab8d9e89bcf3abaf5e253dfbec3496e01bb9a65 + checksum: 10c0/943721c996d9a77351aa7c07956de77baece97f997bd30f3247f46907e4b743f7b9da02c7b3692a36f0884d3724271faeb88ed1c3aca3aba2afe3f27d6c4aeb3 languageName: node linkType: hard @@ -9908,6 +9929,15 @@ __metadata: languageName: node linkType: hard +"is-bun-module@npm:^1.0.2": + version: 1.1.0 + resolution: "is-bun-module@npm:1.1.0" + dependencies: + semver: "npm:^7.6.3" + checksum: 10c0/17cae968c3fe08e2bd66f8477e4d5a166d6299b5e7ce5c7558355551c50267f77dd386297fada6b68e4a32f01ce8920b0423e4d258242ea463b45901ec474beb + languageName: node + linkType: hard + "is-callable@npm:^1.1.3, is-callable@npm:^1.1.4, is-callable@npm:^1.2.7": version: 1.2.7 resolution: "is-callable@npm:1.2.7" @@ -9915,12 +9945,12 @@ __metadata: languageName: node linkType: hard -"is-core-module@npm:^2.11.0, is-core-module@npm:^2.13.0, is-core-module@npm:^2.13.1": - version: 2.13.1 - resolution: "is-core-module@npm:2.13.1" +"is-core-module@npm:^2.13.0, is-core-module@npm:^2.15.1": + version: 2.15.1 + resolution: "is-core-module@npm:2.15.1" dependencies: - hasown: "npm:^2.0.0" - checksum: 10c0/2cba9903aaa52718f11c4896dabc189bab980870aae86a62dc0d5cedb546896770ee946fb14c84b7adf0735f5eaea4277243f1b95f5cefa90054f92fbcac2518 + hasown: "npm:^2.0.2" + checksum: 10c0/53432f10c69c40bfd2fa8914133a68709ff9498c86c3bf5fca3cdf3145a56fd2168cbf4a43b29843a6202a120a5f9c5ffba0a4322e1e3441739bc0b641682612 languageName: node linkType: hard @@ -12471,7 +12501,7 @@ __metadata: languageName: node linkType: hard -"object.fromentries@npm:^2.0.7, object.fromentries@npm:^2.0.8": +"object.fromentries@npm:^2.0.8": version: 2.0.8 resolution: "object.fromentries@npm:2.0.8" dependencies: @@ -12496,15 +12526,14 @@ __metadata: languageName: node linkType: hard -"object.groupby@npm:^1.0.1": - version: 1.0.1 - resolution: "object.groupby@npm:1.0.1" +"object.groupby@npm:^1.0.3": + version: 1.0.3 + resolution: "object.groupby@npm:1.0.3" dependencies: - call-bind: "npm:^1.0.2" - define-properties: "npm:^1.2.0" - es-abstract: "npm:^1.22.1" - get-intrinsic: "npm:^1.2.1" - checksum: 10c0/61e41fbf08cc04ed860363db9629eedeaa590fce243c0960e948fd7b11f78a9d4350065c339936d118a2dd8775d7259e26207340cc8ce688bec66cb615fec6fe + call-bind: "npm:^1.0.7" + define-properties: "npm:^1.2.1" + es-abstract: "npm:^1.23.2" + checksum: 10c0/60d0455c85c736fbfeda0217d1a77525956f76f7b2495edeca9e9bbf8168a45783199e77b894d30638837c654d0cc410e0e02cbfcf445bc8de71c3da1ede6a9c languageName: node linkType: hard @@ -12517,7 +12546,7 @@ __metadata: languageName: node linkType: hard -"object.values@npm:^1.1.0, object.values@npm:^1.1.6, object.values@npm:^1.1.7, object.values@npm:^1.2.0": +"object.values@npm:^1.1.0, object.values@npm:^1.1.6, object.values@npm:^1.2.0": version: 1.2.0 resolution: "object.values@npm:1.2.0" dependencies: From 44fd0803cea855ef28fc3fe709b3febd9caa8eed Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 4 Sep 2024 09:27:12 +0000 Subject: [PATCH 092/153] Update dependency pino to v9.4.0 (#31720) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index e9ab694ffe..74d545d587 100644 --- a/yarn.lock +++ b/yarn.lock @@ -13197,8 +13197,8 @@ __metadata: linkType: hard "pino@npm:^9.0.0": - version: 9.3.2 - resolution: "pino@npm:9.3.2" + version: 9.4.0 + resolution: "pino@npm:9.4.0" dependencies: atomic-sleep: "npm:^1.0.0" fast-redact: "npm:^3.1.1" @@ -13213,7 +13213,7 @@ __metadata: thread-stream: "npm:^3.0.0" bin: pino: bin.js - checksum: 10c0/698eb2ebfcc4252da9d035fcf9c999bf27615b66ebc47f9b3d7e942750e50ebe38429e6457abcf8014d70125964ddf114e696cb8225b480d9930271708e3fb52 + checksum: 10c0/12a3d74968964d92b18ca7d6095a3c5b86478dc22264a37486d64e102085ed08820fcbe75e640acc3542fdf2937a34e5050b624f98e6ac62dd10f5e1328058a2 languageName: node linkType: hard From 7fb8834dd79b93f164369d252d505ad983be027b Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 4 Sep 2024 09:29:14 +0000 Subject: [PATCH 093/153] Update dependency pino-http to v10.3.0 (#31721) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- yarn.lock | 15 ++++----------- 1 file changed, 4 insertions(+), 11 deletions(-) diff --git a/yarn.lock b/yarn.lock index 74d545d587..9825260d6b 100644 --- a/yarn.lock +++ b/yarn.lock @@ -13154,14 +13154,14 @@ __metadata: linkType: hard "pino-http@npm:^10.0.0": - version: 10.2.0 - resolution: "pino-http@npm:10.2.0" + version: 10.3.0 + resolution: "pino-http@npm:10.3.0" dependencies: get-caller-file: "npm:^2.0.5" pino: "npm:^9.0.0" pino-std-serializers: "npm:^7.0.0" - process-warning: "npm:^3.0.0" - checksum: 10c0/0b79cd3602531ee5043693e2a3ccf9d955bd93759e80c0b3a458b95b241f36ca8ebc72c8050b395e9d8fcb9581ebc18ecd6b7dc136526bebe924bc5c5079374d + process-warning: "npm:^4.0.0" + checksum: 10c0/da95d93e1176c02201f9b9bb0af53ad737105c5772acbb077dcad0f52ebce2438e0e9fc8216cd96396d1305d0ecf1f1d23142c7a50110a701ea093b2ee999ea7 languageName: node linkType: hard @@ -14181,13 +14181,6 @@ __metadata: languageName: node linkType: hard -"process-warning@npm:^3.0.0": - version: 3.0.0 - resolution: "process-warning@npm:3.0.0" - checksum: 10c0/60f3c8ddee586f0706c1e6cb5aa9c86df05774b9330d792d7c8851cf0031afd759d665404d07037e0b4901b55c44a423f07bdc465c63de07d8d23196bb403622 - languageName: node - linkType: hard - "process-warning@npm:^4.0.0": version: 4.0.0 resolution: "process-warning@npm:4.0.0" From 36710aec8b2cc622034828f0fe7f6c9a649bc0ce Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 4 Sep 2024 09:57:28 +0000 Subject: [PATCH 094/153] Update dependency postcss to v8.4.45 (#31742) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index 9825260d6b..c77ebfa444 100644 --- a/yarn.lock +++ b/yarn.lock @@ -14045,13 +14045,13 @@ __metadata: linkType: hard "postcss@npm:^8.2.15, postcss@npm:^8.4.24, postcss@npm:^8.4.41": - version: 8.4.44 - resolution: "postcss@npm:8.4.44" + version: 8.4.45 + resolution: "postcss@npm:8.4.45" dependencies: nanoid: "npm:^3.3.7" picocolors: "npm:^1.0.1" source-map-js: "npm:^1.2.0" - checksum: 10c0/53c33338261a3d4f4198f8893e9dfe8b828d8d9186142ee85f02d228f04245c5bbe31239411a357a556ad20ed96f28db24d0921d63edc428fdc9133289371a1d + checksum: 10c0/ad6f8b9b1157d678560373696109745ab97a947d449f8a997acac41c7f1e4c0f3ca4b092d6df1387f430f2c9a319987b1780dbdc27e35800a88cde9b606c1e8f languageName: node linkType: hard From ee55d20fd57fefc3bd865fb0a172bd64e908af3b Mon Sep 17 00:00:00 2001 From: Claire Date: Wed, 4 Sep 2024 12:46:28 +0200 Subject: [PATCH 095/153] Allow `POST /oauth/revoke` through CORS (#31743) --- config/initializers/cors.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/config/initializers/cors.rb b/config/initializers/cors.rb index 37a818bf46..c530693a3f 100644 --- a/config/initializers/cors.rb +++ b/config/initializers/cors.rb @@ -22,6 +22,7 @@ Rails.application.config.middleware.insert_before 0, Rack::Cors do expose: %w(Link X-RateLimit-Reset X-RateLimit-Limit X-RateLimit-Remaining X-Request-Id), methods: %i(post put delete get patch options) resource '/oauth/token', methods: [:post] + resource '/oauth/revoke', methods: [:post] end end end From 1fcffa573cf1ca9373ac1b65b2f7e805cc691927 Mon Sep 17 00:00:00 2001 From: Claire Date: Wed, 4 Sep 2024 14:54:15 +0200 Subject: [PATCH 096/153] Fix 500 error in `GET /api/v2_alpha/notifications` when there are no notifications to return (#31746) --- .../api/v2_alpha/notifications_controller.rb | 2 ++ spec/requests/api/v2_alpha/notifications_spec.rb | 13 +++++++++++++ 2 files changed, 15 insertions(+) diff --git a/app/controllers/api/v2_alpha/notifications_controller.rb b/app/controllers/api/v2_alpha/notifications_controller.rb index bd6979955a..e8aa0b9e49 100644 --- a/app/controllers/api/v2_alpha/notifications_controller.rb +++ b/app/controllers/api/v2_alpha/notifications_controller.rb @@ -77,6 +77,8 @@ class Api::V2Alpha::NotificationsController < Api::BaseController end def load_grouped_notifications + return [] if @notifications.empty? + MastodonOTELTracer.in_span('Api::V2Alpha::NotificationsController#load_grouped_notifications') do NotificationGroup.from_notifications(@notifications, pagination_range: (@notifications.last.id)..(@notifications.first.id), grouped_types: params[:grouped_types]) end diff --git a/spec/requests/api/v2_alpha/notifications_spec.rb b/spec/requests/api/v2_alpha/notifications_spec.rb index 7663d215eb..8009e7edce 100644 --- a/spec/requests/api/v2_alpha/notifications_spec.rb +++ b/spec/requests/api/v2_alpha/notifications_spec.rb @@ -116,6 +116,19 @@ RSpec.describe 'Notifications' do it_behaves_like 'forbidden for wrong scope', 'write write:notifications' + context 'when there are no notifications' do + before do + user.account.notifications.destroy_all + end + + it 'returns 0 notifications' do + subject + + expect(response).to have_http_status(200) + expect(body_as_json[:notification_groups]).to eq [] + end + end + context 'with no options' do it 'returns expected notification types', :aggregate_failures do subject From fab29ebbe864f0aec84857fc3d87f0d56f4f6b9b Mon Sep 17 00:00:00 2001 From: Claire Date: Wed, 4 Sep 2024 15:28:16 +0200 Subject: [PATCH 097/153] Fix all notification types being stored without filtering when polling (#31745) --- .../mastodon/actions/notification_groups.ts | 33 ++++++++++--------- 1 file changed, 17 insertions(+), 16 deletions(-) diff --git a/app/javascript/mastodon/actions/notification_groups.ts b/app/javascript/mastodon/actions/notification_groups.ts index 51f83f1d24..2ee46500ab 100644 --- a/app/javascript/mastodon/actions/notification_groups.ts +++ b/app/javascript/mastodon/actions/notification_groups.ts @@ -18,7 +18,7 @@ import { selectSettingsNotificationsQuickFilterActive, selectSettingsNotificationsShows, } from 'mastodon/selectors/settings'; -import type { AppDispatch } from 'mastodon/store'; +import type { AppDispatch, RootState } from 'mastodon/store'; import { createAppAsyncThunk, createDataLoadingThunk, @@ -32,6 +32,14 @@ function excludeAllTypesExcept(filter: string) { return allNotificationTypes.filter((item) => item !== filter); } +function getExcludedTypes(state: RootState) { + const activeFilter = selectSettingsNotificationsQuickFilterActive(state); + + return activeFilter === 'all' + ? selectSettingsNotificationsExcludedTypes(state) + : excludeAllTypesExcept(activeFilter); +} + function dispatchAssociatedRecords( dispatch: AppDispatch, notifications: ApiNotificationGroupJSON[] | ApiNotificationJSON[], @@ -62,17 +70,8 @@ function dispatchAssociatedRecords( export const fetchNotifications = createDataLoadingThunk( 'notificationGroups/fetch', - async (_params, { getState }) => { - const activeFilter = - selectSettingsNotificationsQuickFilterActive(getState()); - - return apiFetchNotifications({ - exclude_types: - activeFilter === 'all' - ? selectSettingsNotificationsExcludedTypes(getState()) - : excludeAllTypesExcept(activeFilter), - }); - }, + async (_params, { getState }) => + apiFetchNotifications({ exclude_types: getExcludedTypes(getState()) }), ({ notifications, accounts, statuses }, { dispatch }) => { dispatch(importFetchedAccounts(accounts)); dispatch(importFetchedStatuses(statuses)); @@ -92,9 +91,11 @@ export const fetchNotifications = createDataLoadingThunk( export const fetchNotificationsGap = createDataLoadingThunk( 'notificationGroups/fetchGap', - async (params: { gap: NotificationGap }) => - apiFetchNotifications({ max_id: params.gap.maxId }), - + async (params: { gap: NotificationGap }, { getState }) => + apiFetchNotifications({ + max_id: params.gap.maxId, + exclude_types: getExcludedTypes(getState()), + }), ({ notifications, accounts, statuses }, { dispatch }) => { dispatch(importFetchedAccounts(accounts)); dispatch(importFetchedStatuses(statuses)); @@ -109,6 +110,7 @@ export const pollRecentNotifications = createDataLoadingThunk( async (_params, { getState }) => { return apiFetchNotifications({ max_id: undefined, + exclude_types: getExcludedTypes(getState()), // In slow mode, we don't want to include notifications that duplicate the already-displayed ones since_id: usePendingItems ? getState().notificationGroups.groups.find( @@ -183,7 +185,6 @@ export const setNotificationsFilter = createAppAsyncThunk( path: ['notifications', 'quickFilter', 'active'], value: filterType, }); - // dispatch(expandNotifications({ forceLoad: true })); void dispatch(fetchNotifications()); dispatch(saveSettings()); }, From 585e369e0bb0e17ff5e025385dfefde1e9e81fa3 Mon Sep 17 00:00:00 2001 From: Claire Date: Wed, 4 Sep 2024 15:43:08 +0200 Subject: [PATCH 098/153] Fix display name being displayed instead of domain in remote reports (#31613) --- .../components/notification_admin_report.tsx | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-) diff --git a/app/javascript/mastodon/features/notifications_v2/components/notification_admin_report.tsx b/app/javascript/mastodon/features/notifications_v2/components/notification_admin_report.tsx index fda5798ae9..e41a6b2736 100644 --- a/app/javascript/mastodon/features/notifications_v2/components/notification_admin_report.tsx +++ b/app/javascript/mastodon/features/notifications_v2/components/notification_admin_report.tsx @@ -42,19 +42,11 @@ export const NotificationAdminReport: React.FC<{ if (!account || !targetAccount) return null; + const domain = account.acct.split('@')[1]; + const values = { - name: ( - - ), - target: ( - - ), + name: {domain ?? `@${account.acct}`}, + target: @{targetAccount.acct}, category: intl.formatMessage(messages[report.category]), count: report.status_ids.length, }; From 9ba81eae3e526724dda1c693117aae5c0c235fe9 Mon Sep 17 00:00:00 2001 From: Emelia Smith Date: Wed, 4 Sep 2024 16:10:26 +0200 Subject: [PATCH 099/153] Streaming: Improve Redis connection options handling (#31623) --- streaming/index.js | 64 +++++++++++++++++------- streaming/redis.js | 120 +++++++++++++++++++++++++++++++++++---------- 2 files changed, 142 insertions(+), 42 deletions(-) diff --git a/streaming/index.js b/streaming/index.js index 5ef1f6f319..b302565a4e 100644 --- a/streaming/index.js +++ b/streaming/index.js @@ -111,6 +111,35 @@ const startServer = async () => { const server = http.createServer(); const wss = new WebSocketServer({ noServer: true }); + /** + * Adds a namespace to Redis keys or channel names + * Fixes: https://github.com/redis/ioredis/issues/1910 + * @param {string} keyOrChannel + * @returns {string} + */ + function redisNamespaced(keyOrChannel) { + if (redisConfig.namespace) { + return `${redisConfig.namespace}:${keyOrChannel}`; + } else { + return keyOrChannel; + } + } + + /** + * Removes the redis namespace from a channel name + * @param {string} channel + * @returns {string} + */ + function redisUnnamespaced(channel) { + if (typeof redisConfig.namespace === "string") { + // Note: this removes the configured namespace and the colon that is used + // to separate it: + return channel.slice(redisConfig.namespace.length + 1); + } else { + return channel; + } + } + // Set the X-Request-Id header on WebSockets: wss.on("headers", function onHeaders(headers, req) { headers.push(`X-Request-Id: ${req.id}`); @@ -200,7 +229,6 @@ const startServer = async () => { const subs = {}; const redisSubscribeClient = Redis.createClient(redisConfig, logger); - const { redisPrefix } = redisConfig; // When checking metrics in the browser, the favicon is requested this // prevents the request from falling through to the API Router, which would @@ -222,7 +250,7 @@ const startServer = async () => { const interval = 6 * 60; const tellSubscribed = () => { - channels.forEach(channel => redisClient.set(`${redisPrefix}subscribed:${channel}`, '1', 'EX', interval * 3)); + channels.forEach(channel => redisClient.set(redisNamespaced(`subscribed:${channel}`), '1', 'EX', interval * 3)); }; tellSubscribed(); @@ -240,11 +268,10 @@ const startServer = async () => { */ const onRedisMessage = (channel, message) => { metrics.redisMessagesReceived.inc(); + logger.debug(`New message on channel ${channel}`); - const callbacks = subs[channel]; - - logger.debug(`New message on channel ${redisPrefix}${channel}`); - + const key = redisUnnamespaced(channel); + const callbacks = subs[key]; if (!callbacks) { return; } @@ -273,7 +300,8 @@ const startServer = async () => { if (subs[channel].length === 0) { logger.debug(`Subscribe ${channel}`); - redisSubscribeClient.subscribe(channel, (err, count) => { + + redisSubscribeClient.subscribe(redisNamespaced(channel), (err, count) => { if (err) { logger.error(`Error subscribing to ${channel}`); } else if (typeof count === 'number') { @@ -300,7 +328,9 @@ const startServer = async () => { if (subs[channel].length === 0) { logger.debug(`Unsubscribe ${channel}`); - redisSubscribeClient.unsubscribe(channel, (err, count) => { + + // FIXME: https://github.com/redis/ioredis/issues/1910 + redisSubscribeClient.unsubscribe(redisNamespaced(channel), (err, count) => { if (err) { logger.error(`Error unsubscribing to ${channel}`); } else if (typeof count === 'number') { @@ -481,14 +511,14 @@ const startServer = async () => { }); res.on('close', () => { - unsubscribe(`${redisPrefix}${accessTokenChannelId}`, listener); - unsubscribe(`${redisPrefix}${systemChannelId}`, listener); + unsubscribe(accessTokenChannelId, listener); + unsubscribe(systemChannelId, listener); metrics.connectedChannels.labels({ type: 'eventsource', channel: 'system' }).dec(2); }); - subscribe(`${redisPrefix}${accessTokenChannelId}`, listener); - subscribe(`${redisPrefix}${systemChannelId}`, listener); + subscribe(accessTokenChannelId, listener); + subscribe(systemChannelId, listener); metrics.connectedChannels.labels({ type: 'eventsource', channel: 'system' }).inc(2); }; @@ -805,11 +835,11 @@ const startServer = async () => { }; channelIds.forEach(id => { - subscribe(`${redisPrefix}${id}`, listener); + subscribe(id, listener); }); if (typeof attachCloseHandler === 'function') { - attachCloseHandler(channelIds.map(id => `${redisPrefix}${id}`), listener); + attachCloseHandler(channelIds, listener); } return listener; @@ -1156,7 +1186,7 @@ const startServer = async () => { } channelIds.forEach(channelId => { - unsubscribe(`${redisPrefix}${channelId}`, subscription.listener); + unsubscribe(channelId, subscription.listener); }); metrics.connectedChannels.labels({ type: 'websocket', channel: subscription.channelName }).dec(); @@ -1200,8 +1230,8 @@ const startServer = async () => { }, }); - subscribe(`${redisPrefix}${accessTokenChannelId}`, listener); - subscribe(`${redisPrefix}${systemChannelId}`, listener); + subscribe(accessTokenChannelId, listener); + subscribe(systemChannelId, listener); subscriptions[accessTokenChannelId] = { channelName: 'system', diff --git a/streaming/redis.js b/streaming/redis.js index 208d6ae078..2a36b89dc5 100644 --- a/streaming/redis.js +++ b/streaming/redis.js @@ -4,44 +4,114 @@ import { parseIntFromEnvValue } from './utils.js'; /** * @typedef RedisConfiguration - * @property {import('ioredis').RedisOptions} redisParams - * @property {string} redisPrefix - * @property {string|undefined} redisUrl + * @property {string|undefined} namespace + * @property {string|undefined} url + * @property {import('ioredis').RedisOptions} options */ +/** + * + * @param {NodeJS.ProcessEnv} env + * @returns {boolean} + */ +function hasSentinelConfiguration(env) { + return ( + typeof env.REDIS_SENTINELS === 'string' && + env.REDIS_SENTINELS.length > 0 && + typeof env.REDIS_SENTINEL_MASTER === 'string' && + env.REDIS_SENTINEL_MASTER.length > 0 + ); +} + +/** + * + * @param {NodeJS.ProcessEnv} env + * @param {import('ioredis').SentinelConnectionOptions} commonOptions + * @returns {import('ioredis').SentinelConnectionOptions} + */ +function getSentinelConfiguration(env, commonOptions) { + const redisDatabase = parseIntFromEnvValue(env.REDIS_DB, 0, 'REDIS_DB'); + const sentinelPort = parseIntFromEnvValue(env.REDIS_SENTINEL_PORT, 26379, 'REDIS_SENTINEL_PORT'); + + const sentinels = env.REDIS_SENTINELS.split(',').map((sentinel) => { + const [host, port] = sentinel.split(':', 2); + + /** @type {import('ioredis').SentinelAddress} */ + return { + host: host, + port: port ?? sentinelPort, + // Force support for both IPv6 and IPv4, by default ioredis sets this to 4, + // only allowing IPv4 connections: + // https://github.com/redis/ioredis/issues/1576 + family: 0 + }; + }); + + return { + db: redisDatabase, + name: env.REDIS_SENTINEL_MASTER, + username: env.REDIS_USERNAME, + password: env.REDIS_PASSWORD, + sentinelUsername: env.REDIS_SENTINEL_USERNAME ?? env.REDIS_USERNAME, + sentinelPassword: env.REDIS_SENTINEL_PASSWORD ?? env.REDIS_PASSWORD, + sentinels, + ...commonOptions, + }; +} + /** * @param {NodeJS.ProcessEnv} env the `process.env` value to read configuration from * @returns {RedisConfiguration} configuration for the Redis connection */ export function configFromEnv(env) { - // ioredis *can* transparently add prefixes for us, but it doesn't *in some cases*, - // which means we can't use it. But this is something that should be looked into. - const redisPrefix = env.REDIS_NAMESPACE ? `${env.REDIS_NAMESPACE}:` : ''; + const redisNamespace = env.REDIS_NAMESPACE; + // These options apply for both REDIS_URL based connections and connections + // using the other REDIS_* environment variables: + const commonOptions = { + // Force support for both IPv6 and IPv4, by default ioredis sets this to 4, + // only allowing IPv4 connections: + // https://github.com/redis/ioredis/issues/1576 + family: 0 + // Note: we don't use auto-prefixing of keys since this doesn't apply to + // subscribe/unsubscribe which have "channel" instead of "key" arguments + }; + + // If we receive REDIS_URL, don't continue parsing any other REDIS_* + // environment variables: + if (typeof env.REDIS_URL === 'string' && env.REDIS_URL.length > 0) { + return { + url: env.REDIS_URL, + options: commonOptions, + namespace: redisNamespace + }; + } + + // If we have configuration for Redis Sentinel mode, prefer that: + if (hasSentinelConfiguration(env)) { + return { + options: getSentinelConfiguration(env, commonOptions), + namespace: redisNamespace + }; + } + + // Finally, handle all the other REDIS_* environment variables: let redisPort = parseIntFromEnvValue(env.REDIS_PORT, 6379, 'REDIS_PORT'); let redisDatabase = parseIntFromEnvValue(env.REDIS_DB, 0, 'REDIS_DB'); /** @type {import('ioredis').RedisOptions} */ - const redisParams = { - host: env.REDIS_HOST || '127.0.0.1', + const options = { + host: env.REDIS_HOST ?? '127.0.0.1', port: redisPort, - // Force support for both IPv6 and IPv4, by default ioredis sets this to 4, - // only allowing IPv4 connections: - // https://github.com/redis/ioredis/issues/1576 - family: 0, db: redisDatabase, - password: env.REDIS_PASSWORD || undefined, + username: env.REDIS_USERNAME, + password: env.REDIS_PASSWORD, + ...commonOptions, }; - // redisParams.path takes precedence over host and port. - if (env.REDIS_URL && env.REDIS_URL.startsWith('unix://')) { - redisParams.path = env.REDIS_URL.slice(7); - } - return { - redisParams, - redisPrefix, - redisUrl: typeof env.REDIS_URL === 'string' ? env.REDIS_URL : undefined, + options, + namespace: redisNamespace }; } @@ -50,13 +120,13 @@ export function configFromEnv(env) { * @param {import('pino').Logger} logger * @returns {Redis} */ -export function createClient({ redisParams, redisUrl }, logger) { +export function createClient({ url, options }, logger) { let client; - if (typeof redisUrl === 'string') { - client = new Redis(redisUrl, redisParams); + if (typeof url === 'string') { + client = new Redis(url, options); } else { - client = new Redis(redisParams); + client = new Redis(options); } client.on('error', (err) => logger.error({ err }, 'Redis Client Error!')); From ef2bc8ea261838cf31fe4fe11b2954a19c864295 Mon Sep 17 00:00:00 2001 From: David Roetzel Date: Wed, 4 Sep 2024 16:10:45 +0200 Subject: [PATCH 100/153] Add redis sentinel support to ruby part of code (#31744) --- lib/mastodon/redis_configuration.rb | 102 ++++++++++-------- spec/lib/mastodon/redis_configuration_spec.rb | 56 ++++++++++ 2 files changed, 112 insertions(+), 46 deletions(-) diff --git a/lib/mastodon/redis_configuration.rb b/lib/mastodon/redis_configuration.rb index 3cd121e4ac..9139d87583 100644 --- a/lib/mastodon/redis_configuration.rb +++ b/lib/mastodon/redis_configuration.rb @@ -1,34 +1,33 @@ # frozen_string_literal: true class Mastodon::RedisConfiguration + DEFAULTS = { + host: 'localhost', + port: 6379, + db: 0, + }.freeze + def base - @base ||= { - url: setup_base_redis_url, - driver: driver, - namespace: base_namespace, - } + @base ||= setup_config(prefix: nil, defaults: DEFAULTS) + .merge(namespace: base_namespace) end def sidekiq - @sidekiq ||= { - url: setup_prefixed_redis_url(:sidekiq), - driver: driver, - namespace: sidekiq_namespace, - } + @sidekiq ||= setup_config(prefix: 'SIDEKIQ_') + .merge(namespace: sidekiq_namespace) end def cache - @cache ||= { - url: setup_prefixed_redis_url(:cache), - driver: driver, - namespace: cache_namespace, - expires_in: 10.minutes, - connect_timeout: 5, - pool: { - size: Sidekiq.server? ? Sidekiq[:concurrency] : Integer(ENV['MAX_THREADS'] || 5), - timeout: 5, - }, - } + @cache ||= setup_config(prefix: 'CACHE_') + .merge({ + namespace: cache_namespace, + expires_in: 10.minutes, + connect_timeout: 5, + pool: { + size: Sidekiq.server? ? Sidekiq[:concurrency] : Integer(ENV['MAX_THREADS'] || 5), + timeout: 5, + }, + }) end private @@ -55,42 +54,53 @@ class Mastodon::RedisConfiguration namespace ? "#{namespace}_cache" : 'cache' end - def setup_base_redis_url - url = ENV.fetch('REDIS_URL', nil) - return url if url.present? + def setup_config(prefix: nil, defaults: {}) + prefix = "#{prefix}REDIS_" - user = ENV.fetch('REDIS_USER', '') - password = ENV.fetch('REDIS_PASSWORD', '') - host = ENV.fetch('REDIS_HOST', 'localhost') - port = ENV.fetch('REDIS_PORT', 6379) - db = ENV.fetch('REDIS_DB', 0) + url = ENV.fetch("#{prefix}URL", nil) + user = ENV.fetch("#{prefix}USER", nil) + password = ENV.fetch("#{prefix}PASSWORD", nil) + host = ENV.fetch("#{prefix}HOST", defaults[:host]) + port = ENV.fetch("#{prefix}PORT", defaults[:port]) + db = ENV.fetch("#{prefix}DB", defaults[:db]) + name = ENV.fetch("#{prefix}SENTINEL_MASTER", nil) + sentinels = parse_sentinels(ENV.fetch("#{prefix}SENTINELS", nil)) - construct_uri(host, port, db, user, password) - end + return { url:, driver: } if url - def setup_prefixed_redis_url(prefix) - prefix = "#{prefix.to_s.upcase}_" - url = ENV.fetch("#{prefix}REDIS_URL", nil) - - return url if url.present? - - user = ENV.fetch("#{prefix}REDIS_USER", nil) - password = ENV.fetch("#{prefix}REDIS_PASSWORD", nil) - host = ENV.fetch("#{prefix}REDIS_HOST", nil) - port = ENV.fetch("#{prefix}REDIS_PORT", nil) - db = ENV.fetch("#{prefix}REDIS_DB", nil) - - if host.nil? - base[:url] + if name.present? && sentinels.present? + host = name + port = nil + db ||= 0 else - construct_uri(host, port, db, user, password) + sentinels = nil + end + + url = construct_uri(host, port, db, user, password) + + if url.present? + { url:, driver:, name:, sentinels: } + else + # Fall back to base config. This has defaults for the URL + # so this cannot lead to an endless loop. + base end end def construct_uri(host, port, db, user, password) + return nil if host.blank? + Addressable::URI.parse("redis://#{host}:#{port}/#{db}").tap do |uri| uri.user = user if user.present? uri.password = password if password.present? end.normalize.to_str end + + def parse_sentinels(sentinels_string) + (sentinels_string || '').split(',').map do |sentinel| + host, port = sentinel.split(':') + port = port.present? ? port.to_i : 26_379 + { host: host, port: port } + end.presence + end end diff --git a/spec/lib/mastodon/redis_configuration_spec.rb b/spec/lib/mastodon/redis_configuration_spec.rb index c7326fd411..a48ffc80e6 100644 --- a/spec/lib/mastodon/redis_configuration_spec.rb +++ b/spec/lib/mastodon/redis_configuration_spec.rb @@ -45,6 +45,20 @@ RSpec.describe Mastodon::RedisConfiguration do it 'uses the url from the base config' do expect(subject[:url]).to eq 'redis://localhost:6379/0' end + + context 'when the base config uses sentinel' do + around do |example| + ClimateControl.modify REDIS_SENTINELS: '192.168.0.1:3000,192.168.0.2:4000', REDIS_SENTINEL_MASTER: 'mainsentinel' do + example.run + end + end + + it 'uses the sentinel configuration from base config' do + expect(subject[:url]).to eq 'redis://mainsentinel/0' + expect(subject[:name]).to eq 'mainsentinel' + expect(subject[:sentinels]).to contain_exactly({ host: '192.168.0.1', port: 3000 }, { host: '192.168.0.2', port: 4000 }) + end + end end context "when the `#{prefix}_REDIS_URL` environment variable is present" do @@ -72,6 +86,39 @@ RSpec.describe Mastodon::RedisConfiguration do end end + shared_examples 'sentinel support' do |prefix = nil| + prefix = prefix ? "#{prefix}_" : '' + + context 'when configuring sentinel support' do + around do |example| + ClimateControl.modify "#{prefix}REDIS_PASSWORD": 'testpass1', "#{prefix}REDIS_HOST": 'redis2.example.com', "#{prefix}REDIS_SENTINELS": '192.168.0.1:3000,192.168.0.2:4000', "#{prefix}REDIS_SENTINEL_MASTER": 'mainsentinel' do + example.run + end + end + + it 'constructs the url using the sentinel master name' do + expect(subject[:url]).to eq 'redis://:testpass1@mainsentinel/0' + end + + it 'includes the sentinel master name and list of sentinels' do + expect(subject[:name]).to eq 'mainsentinel' + expect(subject[:sentinels]).to contain_exactly({ host: '192.168.0.1', port: 3000 }, { host: '192.168.0.2', port: 4000 }) + end + end + + context 'when giving sentinels without port numbers' do + around do |example| + ClimateControl.modify "#{prefix}REDIS_SENTINELS": '192.168.0.1,192.168.0.2', "#{prefix}REDIS_SENTINEL_MASTER": 'mainsentinel' do + example.run + end + end + + it 'uses the default sentinel port' do + expect(subject[:sentinels]).to contain_exactly({ host: '192.168.0.1', port: 26_379 }, { host: '192.168.0.2', port: 26_379 }) + end + end + end + describe '#base' do subject { redis_environment.base } @@ -81,6 +128,8 @@ RSpec.describe Mastodon::RedisConfiguration do url: 'redis://localhost:6379/0', driver: :hiredis, namespace: nil, + name: nil, + sentinels: nil, }) end end @@ -113,12 +162,15 @@ RSpec.describe Mastodon::RedisConfiguration do url: 'redis://:testpass@redis.example.com:3333/3', driver: :hiredis, namespace: nil, + name: nil, + sentinels: nil, }) end end include_examples 'setting a different driver' include_examples 'setting a namespace' + include_examples 'sentinel support' end describe '#sidekiq' do @@ -127,6 +179,7 @@ RSpec.describe Mastodon::RedisConfiguration do include_examples 'secondary configuration', 'SIDEKIQ' include_examples 'setting a different driver' include_examples 'setting a namespace' + include_examples 'sentinel support', 'SIDEKIQ' end describe '#cache' do @@ -139,6 +192,8 @@ RSpec.describe Mastodon::RedisConfiguration do namespace: 'cache', expires_in: 10.minutes, connect_timeout: 5, + name: nil, + sentinels: nil, pool: { size: 5, timeout: 5, @@ -166,5 +221,6 @@ RSpec.describe Mastodon::RedisConfiguration do include_examples 'secondary configuration', 'CACHE' include_examples 'setting a different driver' + include_examples 'sentinel support', 'CACHE' end end From fe04291af46d7cb9d3439fa73739b2ffb2b53d72 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Wed, 4 Sep 2024 13:19:53 -0400 Subject: [PATCH 101/153] Use more accurate beginning/ending times in annual report source (#31751) --- app/lib/annual_report/source.rb | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/app/lib/annual_report/source.rb b/app/lib/annual_report/source.rb index 1ccb622676..d56a1fcccf 100644 --- a/app/lib/annual_report/source.rb +++ b/app/lib/annual_report/source.rb @@ -11,6 +11,16 @@ class AnnualReport::Source protected def year_as_snowflake_range - (Mastodon::Snowflake.id_at(DateTime.new(year, 1, 1))..Mastodon::Snowflake.id_at(DateTime.new(year, 12, 31))) + (beginning_snowflake_id..ending_snowflake_id) + end + + private + + def beginning_snowflake_id + Mastodon::Snowflake.id_at DateTime.new(year).beginning_of_year + end + + def ending_snowflake_id + Mastodon::Snowflake.id_at DateTime.new(year).end_of_year end end From e1b5f3fc6f1bb6e77a7cad725a963d008c7ce983 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Wed, 4 Sep 2024 13:29:05 -0400 Subject: [PATCH 102/153] Use `response.parsed_body` for html response checks (#31750) --- spec/controllers/admin/accounts_controller_spec.rb | 2 +- .../admin/export_domain_blocks_controller_spec.rb | 2 +- .../controllers/admin/instances_controller_spec.rb | 2 +- .../auth/registrations_controller_spec.rb | 2 +- spec/requests/account_show_page_spec.rb | 14 ++++++++------ 5 files changed, 12 insertions(+), 10 deletions(-) diff --git a/spec/controllers/admin/accounts_controller_spec.rb b/spec/controllers/admin/accounts_controller_spec.rb index 89a7239f53..ca399fbd9b 100644 --- a/spec/controllers/admin/accounts_controller_spec.rb +++ b/spec/controllers/admin/accounts_controller_spec.rb @@ -48,7 +48,7 @@ RSpec.describe Admin::AccountsController do end def accounts_table_rows - Nokogiri::Slop(response.body).css('table.accounts-table tr') + response.parsed_body.css('table.accounts-table tr') end end diff --git a/spec/controllers/admin/export_domain_blocks_controller_spec.rb b/spec/controllers/admin/export_domain_blocks_controller_spec.rb index 39195716c5..564f5a88c5 100644 --- a/spec/controllers/admin/export_domain_blocks_controller_spec.rb +++ b/spec/controllers/admin/export_domain_blocks_controller_spec.rb @@ -64,7 +64,7 @@ RSpec.describe Admin::ExportDomainBlocksController do end def batch_table_rows - Nokogiri::Slop(response.body).css('body div.batch-table__row') + response.parsed_body.css('body div.batch-table__row') end end diff --git a/spec/controllers/admin/instances_controller_spec.rb b/spec/controllers/admin/instances_controller_spec.rb index a64bbb2c9f..1e65373e1f 100644 --- a/spec/controllers/admin/instances_controller_spec.rb +++ b/spec/controllers/admin/instances_controller_spec.rb @@ -35,7 +35,7 @@ RSpec.describe Admin::InstancesController do end def instance_directory_links - Nokogiri::Slop(response.body).css('div.directory__tag a') + response.parsed_body.css('div.directory__tag a') end end diff --git a/spec/controllers/auth/registrations_controller_spec.rb b/spec/controllers/auth/registrations_controller_spec.rb index 75ab287652..6118edf4e3 100644 --- a/spec/controllers/auth/registrations_controller_spec.rb +++ b/spec/controllers/auth/registrations_controller_spec.rb @@ -342,7 +342,7 @@ RSpec.describe Auth::RegistrationsController do end def username_error_text - Nokogiri::Slop(response.body).css('.user_account_username .error').text + response.parsed_body.css('.user_account_username .error').text end end diff --git a/spec/requests/account_show_page_spec.rb b/spec/requests/account_show_page_spec.rb index d0857c8980..7f3ea2595f 100644 --- a/spec/requests/account_show_page_spec.rb +++ b/spec/requests/account_show_page_spec.rb @@ -18,14 +18,16 @@ RSpec.describe 'The account show page' do end def head_link_icons - head_section.css('link[rel=icon]') + response + .parsed_body + .search('html head link[rel=icon]') end def head_meta_content(property) - head_section.meta("[@property='#{property}']")[:content] - end - - def head_section - Nokogiri::Slop(response.body).html.head + response + .parsed_body + .search("html head meta[property='#{property}']") + .attr('content') + .text end end From 559958f8c540a28c9f41da040fa23a228fadad0b Mon Sep 17 00:00:00 2001 From: Claire Date: Wed, 4 Sep 2024 19:35:40 +0200 Subject: [PATCH 103/153] Fix email language when recipient has no selected locale (#31747) --- app/mailers/application_mailer.rb | 2 +- app/mailers/user_mailer.rb | 24 ++++++++++++------------ 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/app/mailers/application_mailer.rb b/app/mailers/application_mailer.rb index 3312183d47..35f0b5fee1 100644 --- a/app/mailers/application_mailer.rb +++ b/app/mailers/application_mailer.rb @@ -12,7 +12,7 @@ class ApplicationMailer < ActionMailer::Base protected def locale_for_account(account, &block) - I18n.with_locale(account.user_locale || I18n.locale || I18n.default_locale, &block) + I18n.with_locale(account.user_locale || I18n.default_locale, &block) end def set_autoreply_headers! diff --git a/app/mailers/user_mailer.rb b/app/mailers/user_mailer.rb index 81a2c0c6d0..5c9e5c96d9 100644 --- a/app/mailers/user_mailer.rb +++ b/app/mailers/user_mailer.rb @@ -33,7 +33,7 @@ class UserMailer < Devise::Mailer return unless @resource.active_for_authentication? - I18n.with_locale(locale) do + I18n.with_locale(locale(use_current_locale: true)) do mail subject: default_devise_subject end end @@ -43,7 +43,7 @@ class UserMailer < Devise::Mailer return unless @resource.active_for_authentication? - I18n.with_locale(locale) do + I18n.with_locale(locale(use_current_locale: true)) do mail subject: default_devise_subject end end @@ -53,7 +53,7 @@ class UserMailer < Devise::Mailer return unless @resource.active_for_authentication? - I18n.with_locale(locale) do + I18n.with_locale(locale(use_current_locale: true)) do mail subject: default_devise_subject end end @@ -63,7 +63,7 @@ class UserMailer < Devise::Mailer return unless @resource.active_for_authentication? - I18n.with_locale(locale) do + I18n.with_locale(locale(use_current_locale: true)) do mail subject: default_devise_subject end end @@ -73,7 +73,7 @@ class UserMailer < Devise::Mailer return unless @resource.active_for_authentication? - I18n.with_locale(locale) do + I18n.with_locale(locale(use_current_locale: true)) do mail subject: default_devise_subject end end @@ -83,7 +83,7 @@ class UserMailer < Devise::Mailer return unless @resource.active_for_authentication? - I18n.with_locale(locale) do + I18n.with_locale(locale(use_current_locale: true)) do mail subject: default_devise_subject end end @@ -93,7 +93,7 @@ class UserMailer < Devise::Mailer return unless @resource.active_for_authentication? - I18n.with_locale(locale) do + I18n.with_locale(locale(use_current_locale: true)) do mail subject: default_devise_subject end end @@ -103,7 +103,7 @@ class UserMailer < Devise::Mailer return unless @resource.active_for_authentication? - I18n.with_locale(locale) do + I18n.with_locale(locale(use_current_locale: true)) do mail subject: default_devise_subject end end @@ -114,7 +114,7 @@ class UserMailer < Devise::Mailer return unless @resource.active_for_authentication? - I18n.with_locale(locale) do + I18n.with_locale(locale(use_current_locale: true)) do mail subject: I18n.t('devise.mailer.webauthn_credential.added.subject') end end @@ -125,7 +125,7 @@ class UserMailer < Devise::Mailer return unless @resource.active_for_authentication? - I18n.with_locale(locale) do + I18n.with_locale(locale(use_current_locale: true)) do mail subject: I18n.t('devise.mailer.webauthn_credential.deleted.subject') end end @@ -219,7 +219,7 @@ class UserMailer < Devise::Mailer @instance = Rails.configuration.x.local_domain end - def locale - @resource.locale.presence || I18n.locale || I18n.default_locale + def locale(use_current_locale: false) + @resource.locale.presence || (use_current_locale && I18n.locale) || I18n.default_locale end end From 1d86377ba90c640763cb61ae3a6d79544a92e8df Mon Sep 17 00:00:00 2001 From: Claire Date: Wed, 4 Sep 2024 15:28:16 +0200 Subject: [PATCH 104/153] [Glitch] Fix all notification types being stored without filtering when polling Port fab29ebbe864f0aec84857fc3d87f0d56f4f6b9b to glitch-soc Signed-off-by: Claire --- .../glitch/actions/notification_groups.ts | 33 ++++++++++--------- 1 file changed, 17 insertions(+), 16 deletions(-) diff --git a/app/javascript/flavours/glitch/actions/notification_groups.ts b/app/javascript/flavours/glitch/actions/notification_groups.ts index ba93ab776b..b0a54ad5b4 100644 --- a/app/javascript/flavours/glitch/actions/notification_groups.ts +++ b/app/javascript/flavours/glitch/actions/notification_groups.ts @@ -18,7 +18,7 @@ import { selectSettingsNotificationsQuickFilterActive, selectSettingsNotificationsShows, } from 'flavours/glitch/selectors/settings'; -import type { AppDispatch } from 'flavours/glitch/store'; +import type { AppDispatch, RootState } from 'flavours/glitch/store'; import { createAppAsyncThunk, createDataLoadingThunk, @@ -32,6 +32,14 @@ function excludeAllTypesExcept(filter: string) { return allNotificationTypes.filter((item) => item !== filter); } +function getExcludedTypes(state: RootState) { + const activeFilter = selectSettingsNotificationsQuickFilterActive(state); + + return activeFilter === 'all' + ? selectSettingsNotificationsExcludedTypes(state) + : excludeAllTypesExcept(activeFilter); +} + function dispatchAssociatedRecords( dispatch: AppDispatch, notifications: ApiNotificationGroupJSON[] | ApiNotificationJSON[], @@ -62,17 +70,8 @@ function dispatchAssociatedRecords( export const fetchNotifications = createDataLoadingThunk( 'notificationGroups/fetch', - async (_params, { getState }) => { - const activeFilter = - selectSettingsNotificationsQuickFilterActive(getState()); - - return apiFetchNotifications({ - exclude_types: - activeFilter === 'all' - ? selectSettingsNotificationsExcludedTypes(getState()) - : excludeAllTypesExcept(activeFilter), - }); - }, + async (_params, { getState }) => + apiFetchNotifications({ exclude_types: getExcludedTypes(getState()) }), ({ notifications, accounts, statuses }, { dispatch }) => { dispatch(importFetchedAccounts(accounts)); dispatch(importFetchedStatuses(statuses)); @@ -92,9 +91,11 @@ export const fetchNotifications = createDataLoadingThunk( export const fetchNotificationsGap = createDataLoadingThunk( 'notificationGroups/fetchGap', - async (params: { gap: NotificationGap }) => - apiFetchNotifications({ max_id: params.gap.maxId }), - + async (params: { gap: NotificationGap }, { getState }) => + apiFetchNotifications({ + max_id: params.gap.maxId, + exclude_types: getExcludedTypes(getState()), + }), ({ notifications, accounts, statuses }, { dispatch }) => { dispatch(importFetchedAccounts(accounts)); dispatch(importFetchedStatuses(statuses)); @@ -109,6 +110,7 @@ export const pollRecentNotifications = createDataLoadingThunk( async (_params, { getState }) => { return apiFetchNotifications({ max_id: undefined, + exclude_types: getExcludedTypes(getState()), // In slow mode, we don't want to include notifications that duplicate the already-displayed ones since_id: usePendingItems ? getState().notificationGroups.groups.find( @@ -183,7 +185,6 @@ export const setNotificationsFilter = createAppAsyncThunk( path: ['notifications', 'quickFilter', 'active'], value: filterType, }); - // dispatch(expandNotifications({ forceLoad: true })); void dispatch(fetchNotifications()); dispatch(saveSettings()); }, From 1fb31ad9b1be6d7c629300657d773b803c943ff1 Mon Sep 17 00:00:00 2001 From: Claire Date: Wed, 4 Sep 2024 15:43:08 +0200 Subject: [PATCH 105/153] [Glitch] Fix display name being displayed instead of domain in remote reports Port 585e369e0bb0e17ff5e025385dfefde1e9e81fa3 to glitch-soc Signed-off-by: Claire --- .../components/notification_admin_report.tsx | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-) diff --git a/app/javascript/flavours/glitch/features/notifications_v2/components/notification_admin_report.tsx b/app/javascript/flavours/glitch/features/notifications_v2/components/notification_admin_report.tsx index fc2d3149b3..3ab8729163 100644 --- a/app/javascript/flavours/glitch/features/notifications_v2/components/notification_admin_report.tsx +++ b/app/javascript/flavours/glitch/features/notifications_v2/components/notification_admin_report.tsx @@ -42,19 +42,11 @@ export const NotificationAdminReport: React.FC<{ if (!account || !targetAccount) return null; + const domain = account.acct.split('@')[1]; + const values = { - name: ( - - ), - target: ( - - ), + name: {domain ?? `@${account.acct}`}, + target: @{targetAccount.acct}, category: intl.formatMessage(messages[report.category]), count: report.status_ids.length, }; From cb1eaa10f21ae0524a0ea909c6271be2621dfade Mon Sep 17 00:00:00 2001 From: Claire Date: Wed, 4 Sep 2024 20:07:23 +0200 Subject: [PATCH 106/153] Fix glitch-soc-only tests --- spec/requests/api/v1/timelines/direct_spec.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spec/requests/api/v1/timelines/direct_spec.rb b/spec/requests/api/v1/timelines/direct_spec.rb index f882e4ccc5..2551060fa9 100644 --- a/spec/requests/api/v1/timelines/direct_spec.rb +++ b/spec/requests/api/v1/timelines/direct_spec.rb @@ -2,7 +2,7 @@ require 'rails_helper' -describe 'API V1 Direct Timeline' do +RSpec.describe 'API V1 Direct Timeline' do let(:user) { Fabricate(:user) } let(:scopes) { 'read:statuses' } let(:token) { Fabricate(:accessible_access_token, resource_owner_id: user.id, scopes: scopes) } From 4678473e54de33200919ad39f08162aed9350e8a Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Wed, 4 Sep 2024 15:50:33 -0400 Subject: [PATCH 107/153] Add `AnnualReport::Source#report_statuses` method for subclasses to use (#31753) --- app/lib/annual_report/archetype.rb | 12 ++++-------- .../commonly_interacted_with_accounts.rb | 2 +- app/lib/annual_report/most_reblogged_accounts.rb | 2 +- app/lib/annual_report/most_used_apps.rb | 2 +- app/lib/annual_report/percentiles.rb | 2 +- app/lib/annual_report/source.rb | 7 +++++++ app/lib/annual_report/time_series.rb | 2 +- app/lib/annual_report/top_hashtags.rb | 2 +- app/lib/annual_report/top_statuses.rb | 2 +- app/lib/annual_report/type_distribution.rb | 14 ++++---------- 10 files changed, 22 insertions(+), 25 deletions(-) diff --git a/app/lib/annual_report/archetype.rb b/app/lib/annual_report/archetype.rb index ea9ef366df..c02b28dfda 100644 --- a/app/lib/annual_report/archetype.rb +++ b/app/lib/annual_report/archetype.rb @@ -28,22 +28,18 @@ class AnnualReport::Archetype < AnnualReport::Source end def polls_count - @polls_count ||= base_scope.where.not(poll_id: nil).count + @polls_count ||= report_statuses.where.not(poll_id: nil).count end def reblogs_count - @reblogs_count ||= base_scope.where.not(reblog_of_id: nil).count + @reblogs_count ||= report_statuses.where.not(reblog_of_id: nil).count end def replies_count - @replies_count ||= base_scope.where.not(in_reply_to_id: nil).where.not(in_reply_to_account_id: @account.id).count + @replies_count ||= report_statuses.where.not(in_reply_to_id: nil).where.not(in_reply_to_account_id: @account.id).count end def standalone_count - @standalone_count ||= base_scope.without_replies.without_reblogs.count - end - - def base_scope - @account.statuses.where(id: year_as_snowflake_range) + @standalone_count ||= report_statuses.without_replies.without_reblogs.count end end diff --git a/app/lib/annual_report/commonly_interacted_with_accounts.rb b/app/lib/annual_report/commonly_interacted_with_accounts.rb index af5e854c22..e7482f0d52 100644 --- a/app/lib/annual_report/commonly_interacted_with_accounts.rb +++ b/app/lib/annual_report/commonly_interacted_with_accounts.rb @@ -17,6 +17,6 @@ class AnnualReport::CommonlyInteractedWithAccounts < AnnualReport::Source private def commonly_interacted_with_accounts - @account.statuses.reorder(nil).where(id: year_as_snowflake_range).where.not(in_reply_to_account_id: @account.id).group(:in_reply_to_account_id).having('count(*) > 1').order(total: :desc).limit(SET_SIZE).pluck(Arel.sql('in_reply_to_account_id, count(*) AS total')) + report_statuses.where.not(in_reply_to_account_id: @account.id).group(:in_reply_to_account_id).having('count(*) > 1').order(total: :desc).limit(SET_SIZE).pluck(Arel.sql('in_reply_to_account_id, count(*) AS total')) end end diff --git a/app/lib/annual_report/most_reblogged_accounts.rb b/app/lib/annual_report/most_reblogged_accounts.rb index e3e8a7c90b..39ed3868ea 100644 --- a/app/lib/annual_report/most_reblogged_accounts.rb +++ b/app/lib/annual_report/most_reblogged_accounts.rb @@ -17,6 +17,6 @@ class AnnualReport::MostRebloggedAccounts < AnnualReport::Source private def most_reblogged_accounts - @account.statuses.reorder(nil).where(id: year_as_snowflake_range).where.not(reblog_of_id: nil).joins(reblog: :account).group('accounts.id').having('count(*) > 1').order(total: :desc).limit(SET_SIZE).pluck(Arel.sql('accounts.id, count(*) as total')) + report_statuses.where.not(reblog_of_id: nil).joins(reblog: :account).group('accounts.id').having('count(*) > 1').order(total: :desc).limit(SET_SIZE).pluck(Arel.sql('accounts.id, count(*) as total')) end end diff --git a/app/lib/annual_report/most_used_apps.rb b/app/lib/annual_report/most_used_apps.rb index 85ff1ff86e..fb1ca1d167 100644 --- a/app/lib/annual_report/most_used_apps.rb +++ b/app/lib/annual_report/most_used_apps.rb @@ -17,6 +17,6 @@ class AnnualReport::MostUsedApps < AnnualReport::Source private def most_used_apps - @account.statuses.reorder(nil).where(id: year_as_snowflake_range).joins(:application).group('oauth_applications.name').order(total: :desc).limit(SET_SIZE).pluck(Arel.sql('oauth_applications.name, count(*) as total')) + report_statuses.joins(:application).group('oauth_applications.name').order(total: :desc).limit(SET_SIZE).pluck(Arel.sql('oauth_applications.name, count(*) as total')) end end diff --git a/app/lib/annual_report/percentiles.rb b/app/lib/annual_report/percentiles.rb index 9fe4698ee5..0251cb66ad 100644 --- a/app/lib/annual_report/percentiles.rb +++ b/app/lib/annual_report/percentiles.rb @@ -17,7 +17,7 @@ class AnnualReport::Percentiles < AnnualReport::Source end def statuses_created - @statuses_created ||= @account.statuses.where(id: year_as_snowflake_range).count + @statuses_created ||= report_statuses.count end def total_with_fewer_followers diff --git a/app/lib/annual_report/source.rb b/app/lib/annual_report/source.rb index d56a1fcccf..cb9f7b16e3 100644 --- a/app/lib/annual_report/source.rb +++ b/app/lib/annual_report/source.rb @@ -10,6 +10,13 @@ class AnnualReport::Source protected + def report_statuses + @account + .statuses + .where(id: year_as_snowflake_range) + .reorder(nil) + end + def year_as_snowflake_range (beginning_snowflake_id..ending_snowflake_id) end diff --git a/app/lib/annual_report/time_series.rb b/app/lib/annual_report/time_series.rb index a144bac0d1..65a188eda7 100644 --- a/app/lib/annual_report/time_series.rb +++ b/app/lib/annual_report/time_series.rb @@ -17,7 +17,7 @@ class AnnualReport::TimeSeries < AnnualReport::Source private def statuses_per_month - @statuses_per_month ||= @account.statuses.reorder(nil).where(id: year_as_snowflake_range).group(:period).pluck(Arel.sql("date_part('month', created_at)::int AS period, count(*)")).to_h + @statuses_per_month ||= report_statuses.group(:period).pluck(Arel.sql("date_part('month', created_at)::int AS period, count(*)")).to_h end def following_per_month diff --git a/app/lib/annual_report/top_hashtags.rb b/app/lib/annual_report/top_hashtags.rb index 488dacb1b4..32bd10d698 100644 --- a/app/lib/annual_report/top_hashtags.rb +++ b/app/lib/annual_report/top_hashtags.rb @@ -17,6 +17,6 @@ class AnnualReport::TopHashtags < AnnualReport::Source private def top_hashtags - Tag.joins(:statuses).where(statuses: { id: @account.statuses.where(id: year_as_snowflake_range).reorder(nil).select(:id) }).group(:id).having('count(*) > 1').order(total: :desc).limit(SET_SIZE).pluck(Arel.sql('COALESCE(tags.display_name, tags.name), count(*) AS total')) + Tag.joins(:statuses).where(statuses: { id: report_statuses.select(:id) }).group(:id).having('count(*) > 1').order(total: :desc).limit(SET_SIZE).pluck(Arel.sql('COALESCE(tags.display_name, tags.name), count(*) AS total')) end end diff --git a/app/lib/annual_report/top_statuses.rb b/app/lib/annual_report/top_statuses.rb index 1ab1709523..c5abeaa58d 100644 --- a/app/lib/annual_report/top_statuses.rb +++ b/app/lib/annual_report/top_statuses.rb @@ -16,6 +16,6 @@ class AnnualReport::TopStatuses < AnnualReport::Source end def base_scope - @account.statuses.public_visibility.joins(:status_stat).where(id: year_as_snowflake_range).reorder(nil) + report_statuses.public_visibility.joins(:status_stat) end end diff --git a/app/lib/annual_report/type_distribution.rb b/app/lib/annual_report/type_distribution.rb index fc12a6f1f4..fe38d8a8a2 100644 --- a/app/lib/annual_report/type_distribution.rb +++ b/app/lib/annual_report/type_distribution.rb @@ -4,17 +4,11 @@ class AnnualReport::TypeDistribution < AnnualReport::Source def generate { type_distribution: { - total: base_scope.count, - reblogs: base_scope.where.not(reblog_of_id: nil).count, - replies: base_scope.where.not(in_reply_to_id: nil).where.not(in_reply_to_account_id: @account.id).count, - standalone: base_scope.without_replies.without_reblogs.count, + total: report_statuses.count, + reblogs: report_statuses.where.not(reblog_of_id: nil).count, + replies: report_statuses.where.not(in_reply_to_id: nil).where.not(in_reply_to_account_id: @account.id).count, + standalone: report_statuses.without_replies.without_reblogs.count, }, } end - - private - - def base_scope - @account.statuses.where(id: year_as_snowflake_range) - end end From 4d5c91e99a3897addd737b12b8b6e3baded6d2d9 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Wed, 4 Sep 2024 15:51:40 -0400 Subject: [PATCH 108/153] Remove `before` block in spec with TODOs which have been TO-DONE already (#31754) --- spec/requests/instance_actor_spec.rb | 5 ----- 1 file changed, 5 deletions(-) diff --git a/spec/requests/instance_actor_spec.rb b/spec/requests/instance_actor_spec.rb index 7e4784203f..bb294b04a4 100644 --- a/spec/requests/instance_actor_spec.rb +++ b/spec/requests/instance_actor_spec.rb @@ -4,11 +4,6 @@ require 'rails_helper' RSpec.describe 'Instance actor endpoint' do describe 'GET /actor' do - before do - integration_session.https! # TODO: Move to global rails_helper for all request specs? - host! Rails.configuration.x.local_domain # TODO: Move to global rails_helper for all request specs? - end - let!(:original_federation_mode) { Rails.configuration.x.limited_federation_mode } shared_examples 'instance actor endpoint' do From 7d91723f052f42a2b5fed365b007767e5717a9bb Mon Sep 17 00:00:00 2001 From: David Roetzel Date: Thu, 5 Sep 2024 11:26:49 +0200 Subject: [PATCH 109/153] Support `REDIS_SENTINEL_PORT` variables (#31767) --- lib/mastodon/redis_configuration.rb | 23 ++++++------ spec/lib/mastodon/redis_configuration_spec.rb | 36 ++++++++++++++++--- 2 files changed, 44 insertions(+), 15 deletions(-) diff --git a/lib/mastodon/redis_configuration.rb b/lib/mastodon/redis_configuration.rb index 9139d87583..5a096a1bf2 100644 --- a/lib/mastodon/redis_configuration.rb +++ b/lib/mastodon/redis_configuration.rb @@ -57,17 +57,20 @@ class Mastodon::RedisConfiguration def setup_config(prefix: nil, defaults: {}) prefix = "#{prefix}REDIS_" - url = ENV.fetch("#{prefix}URL", nil) - user = ENV.fetch("#{prefix}USER", nil) - password = ENV.fetch("#{prefix}PASSWORD", nil) - host = ENV.fetch("#{prefix}HOST", defaults[:host]) - port = ENV.fetch("#{prefix}PORT", defaults[:port]) - db = ENV.fetch("#{prefix}DB", defaults[:db]) - name = ENV.fetch("#{prefix}SENTINEL_MASTER", nil) - sentinels = parse_sentinels(ENV.fetch("#{prefix}SENTINELS", nil)) + url = ENV.fetch("#{prefix}URL", nil) + user = ENV.fetch("#{prefix}USER", nil) + password = ENV.fetch("#{prefix}PASSWORD", nil) + host = ENV.fetch("#{prefix}HOST", defaults[:host]) + port = ENV.fetch("#{prefix}PORT", defaults[:port]) + db = ENV.fetch("#{prefix}DB", defaults[:db]) + name = ENV.fetch("#{prefix}SENTINEL_MASTER", nil) + sentinel_port = ENV.fetch("#{prefix}SENTINEL_PORT", 26_379) + sentinel_list = ENV.fetch("#{prefix}SENTINELS", nil) return { url:, driver: } if url + sentinels = parse_sentinels(sentinel_list, default_port: sentinel_port) + if name.present? && sentinels.present? host = name port = nil @@ -96,10 +99,10 @@ class Mastodon::RedisConfiguration end.normalize.to_str end - def parse_sentinels(sentinels_string) + def parse_sentinels(sentinels_string, default_port: 26_379) (sentinels_string || '').split(',').map do |sentinel| host, port = sentinel.split(':') - port = port.present? ? port.to_i : 26_379 + port = (port || default_port).to_i { host: host, port: port } end.presence end diff --git a/spec/lib/mastodon/redis_configuration_spec.rb b/spec/lib/mastodon/redis_configuration_spec.rb index a48ffc80e6..d14adf9518 100644 --- a/spec/lib/mastodon/redis_configuration_spec.rb +++ b/spec/lib/mastodon/redis_configuration_spec.rb @@ -107,14 +107,40 @@ RSpec.describe Mastodon::RedisConfiguration do end context 'when giving sentinels without port numbers' do - around do |example| - ClimateControl.modify "#{prefix}REDIS_SENTINELS": '192.168.0.1,192.168.0.2', "#{prefix}REDIS_SENTINEL_MASTER": 'mainsentinel' do - example.run + context "when no default port is given via `#{prefix}REDIS_SENTINEL_PORT`" do + around do |example| + ClimateControl.modify "#{prefix}REDIS_SENTINELS": '192.168.0.1,192.168.0.2', "#{prefix}REDIS_SENTINEL_MASTER": 'mainsentinel' do + example.run + end + end + + it 'uses the default sentinel port' do + expect(subject[:sentinels]).to contain_exactly({ host: '192.168.0.1', port: 26_379 }, { host: '192.168.0.2', port: 26_379 }) end end - it 'uses the default sentinel port' do - expect(subject[:sentinels]).to contain_exactly({ host: '192.168.0.1', port: 26_379 }, { host: '192.168.0.2', port: 26_379 }) + context 'when adding port numbers to some, but not all sentinels' do + around do |example| + ClimateControl.modify "#{prefix}REDIS_SENTINELS": '192.168.0.1:5678,192.168.0.2', "#{prefix}REDIS_SENTINEL_MASTER": 'mainsentinel' do + example.run + end + end + + it 'uses the given port number when available and the default otherwise' do + expect(subject[:sentinels]).to contain_exactly({ host: '192.168.0.1', port: 5678 }, { host: '192.168.0.2', port: 26_379 }) + end + end + + context "when a default port is given via `#{prefix}REDIS_SENTINEL_PORT`" do + around do |example| + ClimateControl.modify "#{prefix}REDIS_SENTINEL_PORT": '1234', "#{prefix}REDIS_SENTINELS": '192.168.0.1,192.168.0.2', "#{prefix}REDIS_SENTINEL_MASTER": 'mainsentinel' do + example.run + end + end + + it 'uses the given port number' do + expect(subject[:sentinels]).to contain_exactly({ host: '192.168.0.1', port: 1234 }, { host: '192.168.0.2', port: 1234 }) + end end end end From ec4c49082edb5f4941bd4e129900628c6b30101e Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Thu, 5 Sep 2024 11:39:59 +0200 Subject: [PATCH 110/153] Change design of unread conversations in web UI (#31763) --- .../components/conversation.jsx | 2 +- .../styles/mastodon/components.scss | 19 ++----------------- 2 files changed, 3 insertions(+), 18 deletions(-) diff --git a/app/javascript/mastodon/features/direct_timeline/components/conversation.jsx b/app/javascript/mastodon/features/direct_timeline/components/conversation.jsx index 6588c8b763..0d154db1e1 100644 --- a/app/javascript/mastodon/features/direct_timeline/components/conversation.jsx +++ b/app/javascript/mastodon/features/direct_timeline/components/conversation.jsx @@ -170,7 +170,7 @@ export const Conversation = ({ conversation, scrollKey, onMoveUp, onMoveDown }) return ( -
+
diff --git a/app/javascript/styles/mastodon/components.scss b/app/javascript/styles/mastodon/components.scss index c1e5075702..d892c008bc 100644 --- a/app/javascript/styles/mastodon/components.scss +++ b/app/javascript/styles/mastodon/components.scss @@ -8522,22 +8522,6 @@ noscript { word-break: break-word; } } - - &--unread { - background: lighten($ui-base-color, 2%); - - &:focus { - background: lighten($ui-base-color, 4%); - } - - .conversation__content__info { - font-weight: 700; - } - - .conversation__content__relative-time { - color: $primary-text-color; - } - } } .announcements { @@ -8732,7 +8716,8 @@ noscript { } .notification, -.status__wrapper { +.status__wrapper, +.conversation { position: relative; &.unread { From eb23d9f0f6d8415551e31d264418de733f71d83d Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Thu, 5 Sep 2024 09:40:38 +0000 Subject: [PATCH 111/153] New Crowdin Translations (automated) (#31765) Co-authored-by: GitHub Actions --- app/javascript/mastodon/locales/ar.json | 22 ++- app/javascript/mastodon/locales/fr-CA.json | 1 + app/javascript/mastodon/locales/fr.json | 1 + app/javascript/mastodon/locales/pt-PT.json | 78 ++++----- config/locales/activerecord.pt-PT.yml | 10 +- config/locales/ar.yml | 23 ++- config/locales/devise.pt-PT.yml | 106 ++++++------- config/locales/doorkeeper.pt-PT.yml | 72 ++++----- config/locales/gl.yml | 4 +- config/locales/pt-PT.yml | 175 +++++++++++---------- config/locales/simple_form.ar.yml | 2 +- config/locales/simple_form.pt-PT.yml | 24 +-- 12 files changed, 272 insertions(+), 246 deletions(-) diff --git a/app/javascript/mastodon/locales/ar.json b/app/javascript/mastodon/locales/ar.json index c1cb734a63..d83a42a6c7 100644 --- a/app/javascript/mastodon/locales/ar.json +++ b/app/javascript/mastodon/locales/ar.json @@ -95,6 +95,8 @@ "block_modal.title": "أتريد حظر هذا المستخدم؟", "block_modal.you_wont_see_mentions": "لن تر المنشورات التي يُشار فيهم إليه.", "boost_modal.combo": "يُمكنك الضّغط على {combo} لتخطي هذا في المرة المُقبلة", + "boost_modal.reblog": "أتريد إعادة نشر المنشور؟", + "boost_modal.undo_reblog": "أتريد إلغاء إعادة نشر المنشور؟", "bundle_column_error.copy_stacktrace": "انسخ تقرير الخطأ", "bundle_column_error.error.body": "لا يمكن تقديم الصفحة المطلوبة. قد يكون بسبب خطأ في التعليمات البرمجية، أو مشكلة توافق المتصفح.", "bundle_column_error.error.title": "أوه لا!", @@ -230,7 +232,7 @@ "domain_pill.who_they_are": "بما أن المعرفات تقول من هو الشخص ومكان وجوده، يمكنك التفاعل مع الناس عبر الويب الاجتماعي لل .", "domain_pill.who_you_are": "بما أن معرفك يقول من أنت ومكان وجوده، يمكن للناس التفاعل معك عبر الويب الاجتماعي لل .", "domain_pill.your_handle": "عنوانك الكامل:", - "domain_pill.your_server": "منزلك الرقمي، حيث تعيش جميع مشاركاتك. لا تحب هذا؟ إنقل الخوادم في أي وقت واخضر متابعينك أيضًا.", + "domain_pill.your_server": "موطِنك الرقمي، حيث توجد فيه كافة منشوراتك. ألا يعجبك المكان؟ يمكنك الانتقال بين الخوادم في أي وقت واصطحاب متابعيك أيضاً.", "domain_pill.your_username": "معرفك الفريد على هذا الخادم. من الممكن العثور على مستخدمين بنفس إسم المستخدم على خوادم مختلفة.", "embed.instructions": "يمكنكم إدماج هذا المنشور على موقعكم الإلكتروني عن طريق نسخ الشفرة أدناه.", "embed.preview": "إليك ما سيبدو عليه:", @@ -290,7 +292,7 @@ "filter_modal.added.review_and_configure": "لمراجعة وزيادة تكوين فئة عوامل التصفية هذه، انتقل إلى {settings_link}.", "filter_modal.added.review_and_configure_title": "إعدادات التصفية", "filter_modal.added.settings_link": "صفحة الإعدادات", - "filter_modal.added.short_explanation": "تمت إضافة هذه المشاركة إلى فئة الفلاتر التالية: {title}.", + "filter_modal.added.short_explanation": "تمت إضافة هذا المنشور إلى فئة عوامل التصفية التالية: {title}.", "filter_modal.added.title": "تمت إضافة عامل التصفية!", "filter_modal.select_filter.context_mismatch": "لا ينطبق على هذا السياق", "filter_modal.select_filter.expired": "منتهية الصلاحيّة", @@ -348,6 +350,9 @@ "hashtag.follow": "اتبع الوسم", "hashtag.unfollow": "ألغِ متابعة الوسم", "hashtags.and_other": "…و {count, plural, zero {} one {# واحد آخر} two {# اثنان آخران} few {# آخرون} many {# آخَرًا}other {# آخرون}}", + "hints.profiles.see_more_followers": "عرض المزيد من المتابعين على {domain}", + "hints.profiles.see_more_posts": "عرض المزيد من المنشورات من {domain}", + "hints.threads.see_more": "اطلع على المزيد من الردود على {domain}", "home.column_settings.show_reblogs": "اعرض المعاد نشرها", "home.column_settings.show_replies": "اعرض الردود", "home.hide_announcements": "إخفاء الإعلانات", @@ -356,8 +361,10 @@ "home.pending_critical_update.title": "تحديث أمان حرج متوفر!", "home.show_announcements": "إظهار الإعلانات", "ignore_notifications_modal.disclaimer": "لا يمكن لـ Mastodon إبلاغ المستخدمين بأنك قد تجاهلت إشعاراتهم. تجاهل الإشعارات لن يمنع إرسال الرسائل نفسها.", + "ignore_notifications_modal.filter_instead": "تصفيتها بدلا من ذلك", "ignore_notifications_modal.ignore": "تجاهل الإشعارات", "ignore_notifications_modal.limited_accounts_title": "تجاهل الإشعارات من الحسابات التي هي تحت الإشراف؟", + "ignore_notifications_modal.new_accounts_title": "تجاهل الإشعارات الصادرة من الحسابات الجديدة؟", "interaction_modal.description.favourite": "بفضل حساب على ماستدون، يمكنك إضافة هذا المنشور إلى مفضلتك لإبلاغ الناشر عن تقديرك وكذا للاحتفاظ بالمنشور إلى وقت لاحق.", "interaction_modal.description.follow": "بفضل حساب في ماستدون، يمكنك متابعة {name} وتلقي منشوراته في موجزات خيطك الرئيس.", "interaction_modal.description.reblog": "مع حساب في ماستدون، يمكنك تعزيز هذا المنشور ومشاركته مع مُتابِعيك.", @@ -447,6 +454,7 @@ "mute_modal.you_wont_see_mentions": "لن تر المنشورات التي يُشار فيها إليه.", "mute_modal.you_wont_see_posts": "سيكون بإمكانه رؤية منشوراتك، لكنك لن ترى منشوراته.", "navigation_bar.about": "عن", + "navigation_bar.administration": "الإدارة", "navigation_bar.advanced_interface": "افتحه في واجهة الويب المتقدمة", "navigation_bar.blocks": "الحسابات المحجوبة", "navigation_bar.bookmarks": "الفواصل المرجعية", @@ -463,6 +471,7 @@ "navigation_bar.follows_and_followers": "المتابِعون والمتابَعون", "navigation_bar.lists": "القوائم", "navigation_bar.logout": "خروج", + "navigation_bar.moderation": "الإشراف", "navigation_bar.mutes": "الحسابات المكتومة", "navigation_bar.opened_in_classic_interface": "تُفتَح المنشورات والحسابات وغيرها من الصفحات الخاصة بشكل مبدئي على واجهة الويب التقليدية.", "navigation_bar.personal": "شخصي", @@ -484,7 +493,7 @@ "notification.mention": "إشارة", "notification.moderation-warning.learn_more": "اعرف المزيد", "notification.moderation_warning": "لقد تلقيت تحذيرًا بالإشراف", - "notification.moderation_warning.action_delete_statuses": "تم إزالة بعض مشاركاتك.", + "notification.moderation_warning.action_delete_statuses": "تم حذف بعض من منشوراتك.", "notification.moderation_warning.action_disable": "تم تعطيل حسابك.", "notification.moderation_warning.action_mark_statuses_as_sensitive": "بعض من منشوراتك تم تصنيفها على أنها حساسة.", "notification.moderation_warning.action_none": "لقد تلقى حسابك تحذيرا بالإشراف.", @@ -502,12 +511,15 @@ "notification.status": "{name} نشر للتو", "notification.update": "عدّلَ {name} منشورًا", "notification_requests.accept": "موافقة", + "notification_requests.confirm_accept_multiple.title": "قبول طلبات الإشعار؟", + "notification_requests.confirm_dismiss_multiple.title": "تجاهل طلبات الإشعار؟", "notification_requests.dismiss": "تخطي", "notification_requests.edit_selection": "تعديل", "notification_requests.exit_selection": "تمّ", "notification_requests.explainer_for_limited_account": "تم تصفية الإشعارات من هذا الحساب لأن الحساب تم تقييده من قبل مشرف.", "notification_requests.notifications_from": "إشعارات من {name}", "notification_requests.title": "الإشعارات المصفاة", + "notification_requests.view": "عرض الإشعارات", "notifications.clear": "مسح الإشعارات", "notifications.clear_confirmation": "متأكد من أنك تود مسح جميع الإشعارات الخاصة بك و المتلقاة إلى حد الآن ؟", "notifications.clear_title": "أترغب في مسح الإشعارات؟", @@ -520,7 +532,7 @@ "notifications.column_settings.filter_bar.advanced": "عرض جميع الفئات", "notifications.column_settings.filter_bar.category": "شريط التصفية السريعة", "notifications.column_settings.follow": "متابعُون جُدُد:", - "notifications.column_settings.follow_request": "الطلبات الجديد لِمتابَعتك:", + "notifications.column_settings.follow_request": "الطلبات الجديدة لِمتابَعتك:", "notifications.column_settings.mention": "الإشارات:", "notifications.column_settings.poll": "نتائج استطلاع الرأي:", "notifications.column_settings.push": "الإشعارات", @@ -747,7 +759,7 @@ "status.history.edited": "عدله {name} {date}", "status.load_more": "حمّل المزيد", "status.media.open": "اضغط للفتح", - "status.media.show": "اضغط للإظهار", + "status.media.show": "اضغط لإظهاره", "status.media_hidden": "وسائط مخفية", "status.mention": "أذكُر @{name}", "status.more": "المزيد", diff --git a/app/javascript/mastodon/locales/fr-CA.json b/app/javascript/mastodon/locales/fr-CA.json index 983f737a79..a1d4061eba 100644 --- a/app/javascript/mastodon/locales/fr-CA.json +++ b/app/javascript/mastodon/locales/fr-CA.json @@ -356,6 +356,7 @@ "hints.profiles.follows_may_be_missing": "Les abonnements pour ce profil peuvent être manquants.", "hints.profiles.posts_may_be_missing": "Certains messages de ce profil peuvent être manquants.", "hints.profiles.see_more_followers": "Afficher plus d'abonné·e·s sur {domain}", + "hints.profiles.see_more_follows": "Afficher plus d'abonné·e·s sur {domain}", "hints.profiles.see_more_posts": "Voir plus de messages sur {domain}", "hints.threads.replies_may_be_missing": "Les réponses provenant des autres serveurs pourraient être manquantes.", "hints.threads.see_more": "Afficher plus de réponses sur {domain}", diff --git a/app/javascript/mastodon/locales/fr.json b/app/javascript/mastodon/locales/fr.json index 2b22f4ba32..9f55634b29 100644 --- a/app/javascript/mastodon/locales/fr.json +++ b/app/javascript/mastodon/locales/fr.json @@ -356,6 +356,7 @@ "hints.profiles.follows_may_be_missing": "Les abonnements pour ce profil peuvent être manquants.", "hints.profiles.posts_may_be_missing": "Certains messages de ce profil peuvent être manquants.", "hints.profiles.see_more_followers": "Afficher plus d'abonné·e·s sur {domain}", + "hints.profiles.see_more_follows": "Afficher plus d'abonné·e·s sur {domain}", "hints.profiles.see_more_posts": "Voir plus de messages sur {domain}", "hints.threads.replies_may_be_missing": "Les réponses provenant des autres serveurs pourraient être manquantes.", "hints.threads.see_more": "Afficher plus de réponses sur {domain}", diff --git a/app/javascript/mastodon/locales/pt-PT.json b/app/javascript/mastodon/locales/pt-PT.json index c5d84b9ac6..2d0013d607 100644 --- a/app/javascript/mastodon/locales/pt-PT.json +++ b/app/javascript/mastodon/locales/pt-PT.json @@ -43,7 +43,7 @@ "account.in_memoriam": "Em Memória.", "account.joined_short": "Juntou-se a", "account.languages": "Alterar línguas subscritas", - "account.link_verified_on": "A posse desta ligação foi verificada em {date}", + "account.link_verified_on": "O proprietário desta hiperligação foi verificado em {date}", "account.locked_info": "Esta conta é privada. O proprietário revê manualmente quem o pode seguir.", "account.media": "Média", "account.mention": "Mencionar @{name}", @@ -154,15 +154,15 @@ "compose_form.lock_disclaimer": "A sua conta não é {locked}. Qualquer pessoa pode segui-lo e ver as publicações direcionadas apenas a seguidores.", "compose_form.lock_disclaimer.lock": "fechada", "compose_form.placeholder": "Em que está a pensar?", - "compose_form.poll.duration": "Duração do inquérito", + "compose_form.poll.duration": "Duração da sondagem", "compose_form.poll.multiple": "Escolha múltipla", "compose_form.poll.option_placeholder": "Opção {number}", "compose_form.poll.single": "Escolha uma", - "compose_form.poll.switch_to_multiple": "Alterar o inquérito para permitir várias respostas", - "compose_form.poll.switch_to_single": "Alterar o inquérito para permitir uma única resposta", + "compose_form.poll.switch_to_multiple": "Alterar a sondagem para permitir várias respostas", + "compose_form.poll.switch_to_single": "Alterar a sondagem para permitir uma única resposta", "compose_form.poll.type": "Estilo", "compose_form.publish": "Publicar", - "compose_form.publish_form": "Publicar", + "compose_form.publish_form": "Nova publicação", "compose_form.reply": "Responder", "compose_form.save_changes": "Atualizar", "compose_form.spoiler.marked": "Texto escondido atrás de aviso", @@ -189,7 +189,7 @@ "confirmations.redraft.message": "Tem a certeza de que quer eliminar e reescrever esta publicação? Os favoritos e partilhas perder-se-ão e as respostas à publicação original ficarão órfãs.", "confirmations.redraft.title": "Eliminar e reescrever publicação?", "confirmations.reply.confirm": "Responder", - "confirmations.reply.message": "Responder agora irá reescrever a mensagem que está a compor actualmente. Tem a certeza que quer continuar?", + "confirmations.reply.message": "Se responder agora, a mensagem que está a escrever será substituída. Tem a certeza que pretende continuar?", "confirmations.reply.title": "Sobrescrever publicação?", "confirmations.unfollow.confirm": "Deixar de seguir", "confirmations.unfollow.message": "De certeza que queres deixar de seguir {name}?", @@ -206,14 +206,14 @@ "directory.federated": "Do fediverso conhecido", "directory.local": "Apenas de {domain}", "directory.new_arrivals": "Recém chegados", - "directory.recently_active": "Com actividade recente", + "directory.recently_active": "Recentemente ativo", "disabled_account_banner.account_settings": "Definições da conta", "disabled_account_banner.text": "A sua conta {disabledAccount} está presentemente desativada.", "dismissable_banner.community_timeline": "Estas são as publicações públicas mais recentes de pessoas cujas contas são hospedadas por {domain}.", "dismissable_banner.dismiss": "Descartar", "dismissable_banner.explore_links": "Essas histórias de notícias estão, no momento, a ser faladas por pessoas neste e noutros servidores da rede descentralizada.", "dismissable_banner.explore_statuses": "Estas são publicações de toda a rede social que estão a ganhar popularidade atualmente. As mensagens mais recentes com mais partilhas e favoritos obtêm uma classificação mais elevada.", - "dismissable_banner.explore_tags": "Estas #etiquetas estão presentemente a ganhar atenção entre as pessoas neste e noutros servidores da rede descentralizada.", + "dismissable_banner.explore_tags": "Estas são hashtags que estão a ganhar força na rede social atualmente. As hashtags que são utilizadas por mais pessoas diferentes têm uma classificação mais elevada.", "dismissable_banner.public_timeline": "Estas são as publicações públicas mais recentes de pessoas na rede social que as pessoas em {domain} seguem.", "domain_block_modal.block": "Bloquear servidor", "domain_block_modal.block_account_instead": "Bloquear @{name} em alternativa", @@ -238,7 +238,7 @@ "domain_pill.your_username": "O seu identificador único neste servidor. É possível encontrar utilizadores com o mesmo nome de utilizador em diferentes servidores.", "embed.instructions": "Incorpore esta publicação no seu site copiando o código abaixo.", "embed.preview": "Podes ver aqui como irá ficar:", - "emoji_button.activity": "Actividade", + "emoji_button.activity": "Atividade", "emoji_button.clear": "Limpar", "emoji_button.custom": "Personalizar", "emoji_button.flags": "Bandeiras", @@ -246,7 +246,7 @@ "emoji_button.label": "Inserir Emoji", "emoji_button.nature": "Natureza", "emoji_button.not_found": "Nenhum emoji correspondente encontrado", - "emoji_button.objects": "Objectos", + "emoji_button.objects": "Objetos", "emoji_button.people": "Pessoas", "emoji_button.recent": "Utilizados regularmente", "emoji_button.search": "Pesquisar...", @@ -258,24 +258,24 @@ "empty_column.account_timeline": "Sem publicações por aqui!", "empty_column.account_unavailable": "Perfil indisponível", "empty_column.blocks": "Ainda não bloqueaste qualquer utilizador.", - "empty_column.bookmarked_statuses": "Ainda não adicionou nenhuma publicação aos itens salvos. Quando adicionar, eles serão exibidos aqui.", + "empty_column.bookmarked_statuses": "Ainda não tem nenhuma publicação marcada. Quando marcar uma, ela aparecerá aqui.", "empty_column.community": "A cronologia local está vazia. Escreve algo público para começar!", "empty_column.direct": "Ainda não tem qualquer menção privada. Quando enviar ou receber uma, ela irá aparecer aqui.", "empty_column.domain_blocks": "Ainda não há qualquer domínio escondido.", - "empty_column.explore_statuses": "Nada está em alta no momento. Volte mais tarde!", + "empty_column.explore_statuses": "Nada é tendência neste momento. Volte mais tarde!", "empty_column.favourited_statuses": "Ainda não assinalou qualquer publicação como favorita. Quando o fizer, aparecerá aqui.", "empty_column.favourites": "Ainda ninguém assinalou esta publicação como favorita. Quando alguém o fizer, aparecerá aqui.", "empty_column.follow_requests": "Ainda não tens nenhum pedido de seguidor. Quando receberes algum, ele irá aparecer aqui.", "empty_column.followed_tags": "Ainda não segue nenhuma hashtag. Quando o fizer, ela aparecerá aqui.", "empty_column.hashtag": "Não foram encontradas publicações com essa #etiqueta.", - "empty_column.home": "Ainda não segues qualquer utilizador. Visita {public} ou utiliza a pesquisa para procurar outros utilizadores.", + "empty_column.home": "A sua linha cronológica inicial está vazia! Siga mais pessoas para a preencher.", "empty_column.list": "Ainda não existem publicações nesta lista. Quando membros desta lista fizerem novas publicações, elas aparecerão aqui.", "empty_column.lists": "Ainda não tem qualquer lista. Quando criar uma, ela irá aparecer aqui.", "empty_column.mutes": "Ainda não silenciaste qualquer utilizador.", "empty_column.notification_requests": "Tudo limpo! Não há nada aqui. Quando você receber novas notificações, elas aparecerão aqui conforme as suas configurações.", "empty_column.notifications": "Não tens notificações. Interage com outros utilizadores para iniciar uma conversa.", "empty_column.public": "Não há nada aqui! Escreve algo publicamente ou segue outros utilizadores para veres aqui os conteúdos públicos", - "error.unexpected_crash.explanation": "Devido a um erro no nosso código ou a uma compatilidade com o seu navegador, esta página não pôde ser apresentada correctamente.", + "error.unexpected_crash.explanation": "Devido a um erro no nosso código ou a um problema de compatibilidade do navegador, esta página não pôde ser apresentada corretamente.", "error.unexpected_crash.explanation_addons": "Esta página não pôde ser exibida corretamente. Este erro provavelmente é causado por um complemento do navegador ou ferramentas de tradução automática.", "error.unexpected_crash.next_steps": "Tente atualizar a página. Se isso não ajudar, pode usar o Mastodon através de um navegador diferente ou uma aplicação nativa.", "error.unexpected_crash.next_steps_addons": "Tente desabilitá-los e atualizar a página. Se isso não ajudar, você ainda poderá usar o Mastodon por meio de um navegador diferente ou de um aplicativo nativo.", @@ -355,10 +355,10 @@ "hashtags.and_other": "…e {count, plural, other {mais #}}", "hints.profiles.followers_may_be_missing": "Podem faltar seguidores neste perfil.", "hints.profiles.follows_may_be_missing": "O número de perfis seguidos por este perfil pode faltar.", - "hints.profiles.posts_may_be_missing": "Podem faltar alguns posts deste perfil.", + "hints.profiles.posts_may_be_missing": "Podem faltar algumas publicações deste perfil.", "hints.profiles.see_more_followers": "Ver mais seguidores no {domain}", "hints.profiles.see_more_follows": "Veja mais perfis seguidos em {domain}", - "hints.profiles.see_more_posts": "Ver mais posts em {domain}", + "hints.profiles.see_more_posts": "Ver mais publicações em {domain}", "home.column_settings.show_reblogs": "Mostrar impulsos", "home.column_settings.show_replies": "Mostrar respostas", "home.hide_announcements": "Ocultar comunicações", @@ -406,7 +406,7 @@ "keyboard_shortcuts.my_profile": "para abrir o teu perfil", "keyboard_shortcuts.notifications": "para abrir a coluna das notificações", "keyboard_shortcuts.open_media": "para abrir media", - "keyboard_shortcuts.pinned": "para abrir a lista dos toots fixados", + "keyboard_shortcuts.pinned": "Abrir lista de publicações fixadas", "keyboard_shortcuts.profile": "para abrir o perfil do autor", "keyboard_shortcuts.reply": "para responder", "keyboard_shortcuts.requests": "para abrir a lista dos pedidos de seguidor", @@ -475,7 +475,7 @@ "navigation_bar.mutes": "Utilizadores silenciados", "navigation_bar.opened_in_classic_interface": "Por norma, publicações, contas, e outras páginas específicas são abertas na interface web clássica.", "navigation_bar.personal": "Pessoal", - "navigation_bar.pins": "Toots afixados", + "navigation_bar.pins": "Publicações fixadas", "navigation_bar.preferences": "Preferências", "navigation_bar.public_timeline": "Cronologia federada", "navigation_bar.search": "Pesquisar", @@ -504,8 +504,8 @@ "notification.moderation_warning.action_sensitive": "As suas publicações serão, a partir de agora, assinaladas como sensíveis.", "notification.moderation_warning.action_silence": "A sua conta foi limitada.", "notification.moderation_warning.action_suspend": "A sua conta foi suspensa.", - "notification.own_poll": "A sua votação terminou", - "notification.poll": "Uma votação em que participaste chegou ao fim", + "notification.own_poll": "A sua sondagem terminou", + "notification.poll": "Terminou uma sondagem em que votou", "notification.reblog": "{name} reforçou a tua publicação", "notification.relationships_severance_event": "Perdeu as ligações com {name}", "notification.relationships_severance_event.account_suspension": "Um administrador de {from} suspendeu {target}, o que significa que já não pode receber atualizações dele ou interagir com ele.", @@ -536,7 +536,7 @@ "notifications.column_settings.follow": "Novos seguidores:", "notifications.column_settings.follow_request": "Novos pedidos de seguidor:", "notifications.column_settings.mention": "Menções:", - "notifications.column_settings.poll": "Resultados do inquérito:", + "notifications.column_settings.poll": "Resultados da sondagem:", "notifications.column_settings.push": "Notificações Push", "notifications.column_settings.reblog": "Reforços:", "notifications.column_settings.show": "Mostrar na coluna", @@ -550,7 +550,7 @@ "notifications.filter.favourites": "Favoritos", "notifications.filter.follows": "Seguidores", "notifications.filter.mentions": "Menções", - "notifications.filter.polls": "Resultados do inquérito", + "notifications.filter.polls": "Resultados da sondagem", "notifications.filter.statuses": "Atualizações de pessoas que você segue", "notifications.grant_permission": "Conceder permissão.", "notifications.group": "{count} notificações", @@ -573,7 +573,7 @@ "notifications_permission_banner.title": "Nunca perca nada", "onboarding.action.back": "Voltar atrás", "onboarding.actions.back": "Voltar atrás", - "onboarding.actions.go_to_explore": "Veja as tendências atuais", + "onboarding.actions.go_to_explore": "Ver tendências atuais", "onboarding.actions.go_to_home": "Ir para a sua página inicial", "onboarding.compose.template": "Olá #Mastodon!", "onboarding.follows.empty": "Infelizmente, não é possível mostrar resultados neste momento. Pode tentar utilizar a pesquisa ou navegar na página \"Explorar\" para encontrar pessoas para seguir ou tentar novamente mais tarde.", @@ -599,7 +599,7 @@ "onboarding.start.title": "Conseguiu!", "onboarding.steps.follow_people.body": "Seguir pessoas interessantes é o propósito do Mastodon. ", "onboarding.steps.follow_people.title": "Personalize o seu feed", - "onboarding.steps.publish_status.body": "Diga olá ao mundo com texto, fotos, vídeos ou votos {emoji}", + "onboarding.steps.publish_status.body": "Diga olá ao mundo com texto, fotos, vídeos ou sondagens {emoji}", "onboarding.steps.publish_status.title": "Faça a sua primeira publicação", "onboarding.steps.setup_profile.body": "Promova as suas interações para ter um perfil preenchido. ", "onboarding.steps.setup_profile.title": "Personalize o seu perfil", @@ -608,19 +608,19 @@ "onboarding.tips.2fa": "Sabia? Pode proteger a sua conta ativando a autenticação em duas etapas nas configurações de conta. Funciona com qualquer aplicativo TOTP à sua escolha, sem necessitar de um número de telefone!", "onboarding.tips.accounts_from_other_servers": "Sabia? Como o Mastodon é descentralizado, alguns perfis que encontra estarão hospedados noutros servidores que não os seus. E ainda assim pode interagir com eles perfeitamente! O servidor deles está na segunda metade do nome de utilizador!", "onboarding.tips.migration": "Sabia? Se sentir que o {domain} não é um bom servidor para si, no futuro pode mudar para outro servidor Mastodon sem perder os seus seguidores. Pode até mesmo hospedar o seu próprio servidor!", - "onboarding.tips.verification": "Sabia que? Pode fazer a verificação do seu site, adicionando o link do seu perfil à primeira página do seu site, como também pode adicionar o seu site ao seu perfil? Sem taxas ou documentos!", + "onboarding.tips.verification": "Sabia que? Pode verificar a sua conta colocando uma hiperligação para o seu perfil Mastodon no seu próprio site e adicionando o site ao seu perfil. Sem taxas ou documentos!", "password_confirmation.exceeds_maxlength": "A confirmação da palavra-passe excedeu o tamanho máximo ", "password_confirmation.mismatching": "A confirmação da palavra-passe não corresponde", "picture_in_picture.restore": "Colocá-lo de volta", "poll.closed": "Fechado", - "poll.refresh": "Recarregar", + "poll.refresh": "Atualizar", "poll.reveal": "Ver resultados", "poll.total_people": "{count, plural, one {# pessoa} other {# pessoas}}", "poll.total_votes": "{count, plural, one {# voto} other {# votos}}", "poll.vote": "Votar", - "poll.voted": "Votaste nesta resposta", + "poll.voted": "Votou nesta resposta", "poll.votes": "{votes, plural, one {# voto } other {# votos}}", - "poll_button.add_poll": "Adicionar votação", + "poll_button.add_poll": "Adicionar uma sondagem", "poll_button.remove_poll": "Remover sondagem", "privacy.change": "Ajustar a privacidade da publicação", "privacy.direct.long": "Todos os mencionados na publicação", @@ -635,7 +635,7 @@ "privacy_policy.last_updated": "Última atualização em {date}", "privacy_policy.title": "Política de privacidade", "recommended": "Recomendado", - "refresh": "Actualizar", + "refresh": "Atualizar", "regeneration_indicator.label": "A carregar…", "regeneration_indicator.sublabel": "A tua página inicial está a ser preparada!", "relative_time.days": "{number}d", @@ -677,7 +677,7 @@ "report.reasons.other": "É outra coisa", "report.reasons.other_description": "O problema não se encaixa nas outras categorias", "report.reasons.spam": "É spam", - "report.reasons.spam_description": "Hiperligações maliciosas, contactos falsos, ou respostas repetitivas", + "report.reasons.spam_description": "Hiperligações maliciosas, contactos falsos ou respostas repetitivas", "report.reasons.violation": "Viola as regras do servidor", "report.reasons.violation_description": "Está ciente de que infringe regras específicas", "report.rules.subtitle": "Selecione tudo o que se aplicar", @@ -733,8 +733,8 @@ "sign_in_banner.create_account": "Criar conta", "sign_in_banner.follow_anyone": "Siga alguém no fediverso e veja tudo em ordem cronológica. Sem algoritmos, anúncios ou clickbait à vista.", "sign_in_banner.mastodon_is": "O Mastodon é a melhor maneira de acompanhar o que está a acontecer.", - "sign_in_banner.sign_in": "Iniciar Sessão", - "sign_in_banner.sso_redirect": "Inicie Sessão ou Registe-se", + "sign_in_banner.sign_in": "Iniciar sessão", + "sign_in_banner.sso_redirect": "Inicie sessão ou registe-se", "status.admin_account": "Abrir a interface de moderação para @{name}", "status.admin_domain": "Abrir interface de moderação para {domain}", "status.admin_status": "Abrir esta publicação na interface de moderação", @@ -742,7 +742,7 @@ "status.bookmark": "Guardar nos marcadores", "status.cancel_reblog_private": "Deixar de reforçar", "status.cannot_reblog": "Não é possível partilhar esta publicação", - "status.copy": "Copiar ligação para a publicação", + "status.copy": "Copiar hiperligação para a publicação", "status.delete": "Eliminar", "status.detailed_status": "Vista pormenorizada da conversa", "status.direct": "Mencionar @{name} em privado", @@ -801,15 +801,15 @@ "time_remaining.moments": "Momentos restantes", "time_remaining.seconds": "{número, plural, um {# second} outro {# seconds}} faltam", "trends.counter_by_accounts": "{count, plural, one {{counter} pessoa} other {{counter} pessoas}} {days, plural, one {no último dia} other {nos últimos {days} dias}}", - "trends.trending_now": "Em alta neste momento", + "trends.trending_now": "Tendências atuais", "ui.beforeunload": "O teu rascunho será perdido se abandonares o Mastodon.", "units.short.billion": "{count}MM", "units.short.million": "{count}M", "units.short.thousand": "{count}m", - "upload_area.title": "Arraste e solte para enviar", - "upload_button.label": "Juntar imagens, um vídeo, ou um ficheiro de som", - "upload_error.limit": "Limite máximo do ficheiro a carregar excedido.", - "upload_error.poll": "O carregamento de ficheiros não é permitido em sondagens.", + "upload_area.title": "Arrastar e largar para enviar", + "upload_button.label": "Adicionar imagens, um vídeo ou um ficheiro de som", + "upload_error.limit": "Limite de envio de ficheiros excedido.", + "upload_error.poll": "Não é permitido o envio de ficheiros em sondagens.", "upload_form.audio_description": "Descreva para pessoas com diminuição da acuidade auditiva", "upload_form.description": "Descreva para pessoas com diminuição da acuidade visual", "upload_form.edit": "Editar", @@ -820,7 +820,7 @@ "upload_modal.applying": "A aplicar…", "upload_modal.choose_image": "Escolher imagem", "upload_modal.description_placeholder": "Grave e cabisbaixo, o filho justo zelava pela querida mãe doente", - "upload_modal.detect_text": "Detectar texto na imagem", + "upload_modal.detect_text": "Detetar texto na imagem", "upload_modal.edit_media": "Editar media", "upload_modal.hint": "Clique ou arraste o círculo na pré-visualização para escolher o ponto focal que será sempre visível em todas as miniaturas.", "upload_modal.preparing_ocr": "A preparar o reconhecimento de caracteres (OCR)…", diff --git a/config/locales/activerecord.pt-PT.yml b/config/locales/activerecord.pt-PT.yml index ba738741f8..60f3def5d3 100644 --- a/config/locales/activerecord.pt-PT.yml +++ b/config/locales/activerecord.pt-PT.yml @@ -6,7 +6,7 @@ pt-PT: expires_at: Prazo options: Escolhas user: - agreement: Acordo de serviço + agreement: Contrato de prestação de serviço email: Endereço de correio electrónico locale: Região password: Palavra-passe @@ -19,7 +19,7 @@ pt-PT: account: attributes: username: - invalid: apenas letras, números e underscores + invalid: deve conter apenas letras, números e traços inferiores reserved: está reservado admin/webhook: attributes: @@ -43,15 +43,15 @@ pt-PT: blocked: usa um fornecedor de e-mail que não é permitido unreachable: não parece existir role_id: - elevated: não pode ser maior que o da sua função atual + elevated: não pode ser superior à sua função atual user_role: attributes: permissions_as_keys: dangerous: incluir permissões que não são seguras para a função base - elevated: não pode incluir permissões que a sua função atual não possui + elevated: não pode incluir permissões que a sua função atual não possua own_role: não pode ser alterado com a sua função atual position: - elevated: não pode ser maior que o da sua função atual + elevated: não pode ser superior à sua função atual own_role: não pode ser alterado com a sua função atual webhook: attributes: diff --git a/config/locales/ar.yml b/config/locales/ar.yml index 027d80215d..7ab1b4f075 100644 --- a/config/locales/ar.yml +++ b/config/locales/ar.yml @@ -906,6 +906,7 @@ ar: moderation: title: الحالة newest: الأحدث + reset: إعادة التعيين review: حالة المراجعة search: البحث title: الوسوم @@ -985,6 +986,7 @@ ar: other: مستخدَم من قِبل %{count} شخص خلال الأسبوع الماضي two: مستخدَم من قِبل %{count} شخصين خلال الأسبوع الماضي zero: مستخدَم من قِبل %{count} شخص خلال الأسبوع الماضي + title: التوصيات والرائجة trending: المتداولة warning_presets: add_new: إضافة واحد جديد @@ -1141,8 +1143,10 @@ ar: security: الأمان set_new_password: إدخال كلمة مرور جديدة setup: + email_below_hint_html: قم بفحص مجلد البريد المزعج الخاص بك، أو قم بطلب آخر. يمكنك تصحيح عنوان بريدك الإلكتروني إن كان خاطئا. email_settings_hint_html: انقر على الرابط الذي أرسلناه لك للتحقق من %{email}. سننتظر هنا. link_not_received: ألم تحصل على رابط؟ + new_confirmation_instructions_sent: سوف تتلقى رسالة بريد إلكتروني جديدة مع رابط التأكيد في غضون بضع دقائق! title: تحقَّق من بريدك الوارِد sign_in: preamble_html: قم بتسجيل الدخول باستخدام بيانات الاعتماد الخاصة بك على %{domain}. إن استُضيف حسابك على خادم مختلف عن هذا الخادم، لن تتمكن من الولوج هنا. @@ -1153,7 +1157,9 @@ ar: title: دعنا نجهّز %{domain}. status: account_status: حالة الحساب + confirming: في انتظار اكتمال تأكيد البريد الإلكتروني. functional: حسابك يعمل بشكل كامل. + pending: إن طلبك قيد المراجعة من قبل فريقنا. قد يستغرق هذا بعض الوقت. سوف تتلقى بريدا إلكترونيا إذا تمت الموافقة على طلبك. redirecting_to: حسابك غير نشط لأنه تم تحويله حاليا إلى %{acct}. self_destruct: نظرًا لإغلاق %{domain}، ستحصل فقط على وصول محدود إلى حسابك. view_strikes: عرض العقوبات السابقة المُطَبَّقة ضد حسابك @@ -1196,6 +1202,9 @@ ar: before: 'يرجى قراءة هذه الملاحظات بتأنّي قبل المواصلة:' caches: قد يبقى المحتوى الذي تم تخزينه مؤقتًا مِن طرف الخوادم الأخرى data_removal: سوف تُحذَف منشوراتك والبيانات الأخرى نهائيا + email_change_html: بإمكانك تغيير عنوان بريدك الإلكتروني دون أن يُحذف حسابك + email_contact_html: إن لم تتلقّ أي شيء ، يمكنك مراسلة %{email} لطلب المساعدة + email_reconfirmation_html: إن لم تتلقّ الرسالة الإلكترونية للتأكيد ، بإمكانك إعادة طلبها ثانيةً irreversible: لن يكون بإمكانك استرجاع أو إعادة تنشيط حسابك more_details_html: للمزيد مِن التفاصيل ، يرجى الإطلاع على سياسة الخصوصية. username_available: سيصبح اسم مستخدمك متوفرا ثانية @@ -1448,7 +1457,7 @@ ar: two: "%{count} استخدامات" zero: "%{count} استخدامات" max_uses_prompt: بلا حدود - prompt: توليد و مشاركة روابط للسماح للآخَرين بالنفاذ إلى مثيل الخادم هذا + prompt: توليد و مشاركة روابط للسماح للآخَرين النفاذ إلى هذا الخادم table: expires_at: تنتهي مدة صلاحيتها في uses: عدد الاستخدامات @@ -1460,6 +1469,7 @@ ar: authentication_methods: otp: تطبيق المصادقة الثنائية password: كلمة المرور + sign_in_token: رمز الأمان للبريد الإلكتروني webauthn: مفاتيح الأمان description_html: إذا رأيت النشاط الذي لا تتعرف عليه، فكر في تغيير كلمة المرور الخاصة بك وتفعيل المصادقة ذات العاملين. empty: لا يوجد سجل مصادقة متاح @@ -1553,6 +1563,7 @@ ar: update: subject: قام %{name} بتحرير منشور notifications: + administration_emails: إشعارات البريد الإلكتروني الإدارية email_events_hint: 'اختر الأحداث التي تريد أن تصِلَك اشعارات عنها:' number: human: @@ -1811,13 +1822,13 @@ ar: keep_media: الاحتفاظ بالمنشورات ذات وسائط مرفقة keep_media_hint: لن تُحذف أي من منشوراتك التي تحتوي على وسائط مرفقة keep_pinned: الاحتفاظ بالمنشورات المثبتة - keep_pinned_hint: لم تقوم بحذف أي من مشاركتك المثبتة + keep_pinned_hint: لن تحذف أي من منشوراتك المثبتة keep_polls: الاحتفاظ باستطلاعات الرأي keep_polls_hint: لم تقم بحذف أي من استطلاعاتك keep_self_bookmark: احتفظ بالمنشورات التي أدرجتها في الفواصل المرجعية - keep_self_bookmark_hint: لم تقم بحذف مشاركاتك الخاصة إذا قمت بوضع علامة مرجعية عليها + keep_self_bookmark_hint: لن تحذف منشوراتك الخاصة إذا قمت بوضع علامة مرجعية عليها keep_self_fav: احتفظ بالمنشورات التي أدرجتها في المفضلة - keep_self_fav_hint: لم تقم بحذف مشاركاتك الخاصة إذا كنت قد فضلتهم + keep_self_fav_hint: لن تحذف منشوراتك الخاصة إذا كنت قد فضلتها min_age: '1209600': أسبوعان '15778476': 6 أشهر @@ -1828,9 +1839,9 @@ ar: '63113904': سنتان '7889238': 3 أشهر min_age_label: عتبة العمر - min_favs: إبقاء المشاركات المفضلة أكثر من + min_favs: إبقاء المنشورات المفضلة على الأقل min_favs_hint: لن تُحذف أي من منشوراتك التي تلقّت على الأقل هذا العدد من المفضلات. اتركه فارغاً لحذف المنشورات مهما كان عدد المفضلات التي تلقتها - min_reblogs: إبقاء المنشورات المعاد نشرها أكثر من + min_reblogs: إبقاء المنشورات المعاد نشرها على الأقل min_reblogs_hint: لن تُحذف أي من منشوراتك التي أعيد مشاركتها أكثر من هذا العدد من المرات. اتركه فارغاً لحذف المنشورات بغض النظر عن عدد إعادات النشر stream_entries: sensitive_content: محتوى حساس diff --git a/config/locales/devise.pt-PT.yml b/config/locales/devise.pt-PT.yml index c66181fc5b..edfb798509 100644 --- a/config/locales/devise.pt-PT.yml +++ b/config/locales/devise.pt-PT.yml @@ -2,117 +2,117 @@ pt-PT: devise: confirmations: - confirmed: O seu endereço correio electrónico foi correctamente confirmado. - send_instructions: Vais receber um e-mail com as instruções para confirmar o teu endereço de e-mail dentro de alguns minutos. Por favor, verifica a caixa de spam se não recebeu o e-mail. - send_paranoid_instructions: Se o teu endereço de e-mail já existir na nossa base de dados, vais receber um e-mail com as instruções de confirmação dentro de alguns minutos. Por favor, verifica a caixa de spam se não recebeu o e-mail. + confirmed: O seu endereço de e-mail foi corretamente confirmado. + send_instructions: Irá receber um e-mail com instruções sobre como confirmar o seu endereço de e-mail dentro de alguns minutos. Verifique a sua pasta de spam se não recebeu este e-mail. + send_paranoid_instructions: Se o seu endereço de e-mail existir na nossa base de dados, receberá um e-mail com instruções sobre como confirmar o seu endereço de e-mail dentro de alguns minutos. Verifique a sua pasta de spam se não recebeu este e-mail. failure: - already_authenticated: A tua sessão já está aberta. - inactive: A tua conta ainda não está ativada. + already_authenticated: Já tem sessão iniciada. + inactive: A sua conta ainda não está ativada. invalid: "%{authentication_keys} ou palavra-passe inválida." last_attempt: Tem só mais uma tentativa antes da sua conta ser bloqueada. - locked: A tua conta está bloqueada. + locked: A sua conta está bloqueada. not_found_in_database: "%{authentication_keys} ou palavra-passe inválida." omniauth_user_creation_failure: Erro ao criar uma conta para esta identidade. pending: A sua conta está ainda a aguardar revisão. - timeout: A tua sessão expirou. Por favor, entra de novo para continuares. - unauthenticated: Precisas de entrar na tua conta ou de te registares antes de continuar. - unconfirmed: Tens de confirmar o teu endereço de e-mail antes de continuar. + timeout: A sua sessão expirou. Inicie sessão novamente para continuar. + unauthenticated: É necessário iniciar sessão ou registar-se antes de continuar. + unconfirmed: Tem de confirmar o seu endereço de e-mail antes de continuar. mailer: confirmation_instructions: action: Verificar o endereço de e-mail action_with_app: Confirmar e regressar a %{app} - explanation: Criou uma conta em %{host} com este endereço de e-mail. Está a um clique de ativá-la. Se não foi você que fez este registo, por favor ignore esta mensagem. + explanation: Foi criada uma conta em %{host} com este endereço de e-mail. Está a um clique de ativá-la. Se não foi você que fez este registo, por favor ignore esta mensagem. explanation_when_pending: Candidatou-se com um convite para %{host} com este endereço de e-mail. Logo que confirme o seu endereço de e-mail, iremos rever a sua candidatura. Pode iniciar sessão para alterar os seus dados ou eliminar a sua conta, mas não poderá aceder à maioria das funções até que a sua conta seja aprovada. Se a sua inscrição for indeferida, os seus dados serão eliminados, pelo que não será necessária qualquer ação adicional da sua parte. Se não solicitou este convite, queira ignorar este e-mail. - extra_html: Por favor leia as regras da instância e os nossos termos de serviço. - subject: 'Mastodon: Instruções de confirmação %{instance}' + extra_html: Por favor leia as regras do servidor e os nossos termos de serviço. + subject: 'Mastodon: instruções de confirmação para %{instance}' title: Verificar o endereço de e-mail email_changed: explanation: 'O e-mail associado à sua conta será alterado para:' - extra: Se não alterou o seu e-mail, é possível que alguém tenha conseguido aceder à sua conta. Por favor altere a sua palavra-passe imediatamente ou entra em contacto com um administrador da instância se tiver ficado sem acesso à sua conta. - subject: 'Mastodon: E-mail alterado' + extra: Se não alterou o seu e-mail, é possível que alguém tenha conseguido aceder à sua conta. Por favor altere a sua palavra-passe imediatamente ou entre em contacto com um administrador do servidor se tiver ficado sem acesso à sua conta. + subject: 'Mastodon: e-mail alterado' title: Novo endereço de e-mail password_change: - explanation: A palavra-passe da tua conta foi alterada. - extra: Se não alterou a sua palavra-passe, é possível que alguém tenha conseguido aceder à sua conta. Por favor altere a sua palavra-passe imediatamente ou entre em contacto com um administrador da instância se tiver ficado sem acesso à sua conta. + explanation: A palavra-passe da sua conta foi alterada. + extra: Se não alterou a sua palavra-passe, é possível que alguém tenha conseguido aceder à sua conta. Por favor altere a sua palavra-passe imediatamente ou entre em contacto com um administrador do servidor se tiver ficado sem acesso à sua conta. subject: 'Mastodon: palavra-passe alterada' title: Palavra-passe alterada reconfirmation_instructions: explanation: Confirme o seu novo endereço para alterar o e-mail. - extra: Se esta mudança não foi iniciada por si, queira ignorar este e-mail. O endereço de correio electrónico da sua conta do Mastodon não irá mudar enquanto não aceder à hiperligação acima. - subject: 'Mastodon: Confirmação de e-mail %{instance}' + extra: Se esta alteração não foi iniciada por si, ignore este e-mail. O endereço de e-mail da conta Mastodon não será alterado até aceder à hiperligação acima. + subject: 'Mastodon: confirmação de e-mail para %{instance}' title: Validar o endereço de e-mail reset_password_instructions: action: Alterar palavra-passe - explanation: Pediste a alteração da palavra-passe da tua conta. - extra: Se não fez este pedido, queira ignorar este e-mail. A sua palavra-passe não irá mudar se não aceder à hiperligação acima e criar uma nova. - subject: 'Mastodon: Instruções para redefinir a palavra-passe' + explanation: Solicitou uma nova palavra-passe para a sua conta. + extra: Se não solicitou esta alteração, ignore este e-mail. A sua palavra-passe não será alterada até aceder à hiperligação acima e criar uma nova. + subject: 'Mastodon: instruções para redefinir a palavra-passe' title: Solicitar nova palavra-passe two_factor_disabled: - explanation: O acesso agora é possível usando apenas o endereço de correio eletrónico e palavra-passe. - subject: 'Mastodon: Autenticação de duas etapas desativada' + explanation: O início de sessão é agora possível utilizando apenas o endereço de e-mail e a palavra-passe. + subject: 'Mastodon: autenticação de duas etapas desativada' subtitle: A autenticação de dois fatores foi desativada para a sua conta. title: 2FA desativado two_factor_enabled: - explanation: Um token gerado pelo aplicativo TOTP emparelhado será necessário para login. - subject: 'Mastodon: Autenticação em duas etapas ativada' - subtitle: A autenticação de dois fatores foi habilitada para sua conta. + explanation: Para iniciar sessão, será necessário um token gerado pela aplicação TOTP emparelhada. + subject: 'Mastodon: autenticação em duas etapas ativada' + subtitle: A autenticação de dois fatores foi ativada para a sua conta. title: 2FA ativado two_factor_recovery_codes_changed: - explanation: Os códigos de recuperação anteriores foram invalidados e novos foram gerados. - subject: 'Mastodon: Gerados novos códigos de recuperação em duas etapas' - subtitle: Os códigos de recuperação anteriores foram invalidados e novos foram gerados. + explanation: Os códigos de recuperação anteriores foram invalidados e foram gerados novos códigos. + subject: 'Mastodon: gerados novos códigos de recuperação em duas etapas' + subtitle: Os códigos de recuperação anteriores foram invalidados e foram gerados novos códigos. title: Códigos de recuperação 2FA alterados unlock_instructions: - subject: 'Mastodon: Instruções para desbloquear a tua conta' + subject: 'Mastodon: instruções para desbloquear' webauthn_credential: added: explanation: A seguinte chave de segurança foi adicionada à sua conta - subject: 'Mastodon: Nova chave de segurança' + subject: 'Mastodon: nova chave de segurança' title: Foi adicionada uma nova chave de segurança deleted: explanation: A seguinte chave de segurança foi eliminada da sua conta - subject: 'Mastodon: Chave de segurança eliminada' + subject: 'Mastodon: chave de segurança eliminada' title: Uma das suas chaves de segurança foi eliminada webauthn_disabled: explanation: A autenticação com chaves de segurança foi desativada para sua conta. - extra: O login agora é possível usando apenas o token gerado pelo aplicativo TOTP emparelhado. - subject: 'Mastodon: Autenticação com chave de segurança desativada' + extra: O início de sessão é agora possível utilizando apenas o token gerado pela aplicação TOTP emparelhada. + subject: 'Mastodon: autenticação com chave de segurança desativada' title: Chaves de segurança desativadas webauthn_enabled: - explanation: A autenticação da chave de segurança foi habilitada para sua conta. - extra: Sua chave de segurança agora pode ser usada para login. - subject: 'Mastodon: Autenticação com chave de segurança ativada' + explanation: A autenticação por chave de segurança foi ativada para a sua conta. + extra: A sua chave de segurança pode agora ser utilizada para iniciar sessão. + subject: 'Mastodon: autenticação com chave de segurança ativada' title: Chaves de segurança ativadas omniauth_callbacks: failure: Não foi possível autenticar %{kind} porque "%{reason}". success: Autenticado correctamente na conta %{kind}. passwords: - no_token: Não pode aceder a esta página se não vier através da ligação enviada por e-mail para alteração da sua palavra-passe. Se de facto usou essa ligação para chegar até aqui, queira garantir de que usou o endereço URL completo. - send_instructions: Vai receber um e-mail com instruções para alterar a palavra-passe dentro de alguns minutos. - send_paranoid_instructions: Se o seu endereço de e-mail existir na nossa base de dados, dentro de alguns minutos irá receber uma ligação para recuperar a palavra-passe. - updated: A tua palavra-passe foi alterada. Estás agora autenticado na tua conta. + no_token: Não pode aceder a esta página se não vier através da hiperligação enviada por e-mail para alteração da sua palavra-passe. Se de facto usou essa hiperligação para chegar até aqui, verifique se usou o endereço URL completo. + send_instructions: Se o seu endereço de e-mail existir na nossa base de dados, receberá uma hiperligação de recuperação da palavra-passe no seu endereço de e-mail dentro de alguns minutos. Verifique a sua pasta de spam se não recebeu esta mensagem de correio eletrónico. + send_paranoid_instructions: Se o seu endereço de e-mail existir na nossa base de dados, receberá uma hiperligação de recuperação da palavra-passe no seu endereço de e-mail dentro de alguns minutos. Verifique a sua pasta de spam se não recebeu esta mensagem de correio eletrónico. + updated: A sua palavra-passe foi alterada com sucesso. Está agora autenticado. updated_not_active: A tua palavra-passe foi alterada. registrations: - destroyed: Adeus! A tua conta foi cancelada. Esperamos ver-te em breve. - signed_up: Seja bem-vindo! A sua conta foi correctamente registada. - signed_up_but_inactive: A tua conta foi registada. No entanto ainda não está activa. - signed_up_but_locked: A sua conta foi correctamente registada. Contudo, não pudemos iniciar sessão porque a sua conta está bloqueada. - signed_up_but_pending: Foi enviada uma hiperligação de confirmação para o seu correio electrónico. Só depois de clicar na hiperligação avaliaremos a sua inscrição. Será notificado caso a sua conta seja aprovada. - signed_up_but_unconfirmed: Foi enviada uma hiperligação de confirmação para o seu correio electrónico. Queira usar essa hiperligação para activar a sua conta. - update_needs_confirmation: Solicitou uma alteração da informação da sua conta, mas para tal é necessário confirmá-la. Queira ver o seu correio electrónico e seguir a hiperligação para a confirmar. Se não encontrar essa mensagem, veja se está na pasta de lixo electrónico. - updated: A sua conta foi correctamente actualizada. + destroyed: Adeus! A sua conta foi cancelada com sucesso. Esperamos voltar a vê-lo em breve. + signed_up: Bem-vindo! A sua conta foi registada com sucesso. + signed_up_but_inactive: Registou-se com sucesso. No entanto, não foi possível iniciar sessão porque a sua conta ainda não está ativada. + signed_up_but_locked: Registou-se com sucesso. No entanto, não foi possível iniciar sessão porque a sua conta está bloqueada. + signed_up_but_pending: Foi enviada uma mensagem com uma hiperligação de confirmação para o seu endereço de e-mail. Depois de clicar na hiperligação, analisaremos a sua candidatura. Será notificado se for aprovado. + signed_up_but_unconfirmed: Foi enviada para o seu endereço de e-mail uma mensagem com uma hiperligação de confirmação. Siga a hiperligação para ativar a sua conta. Verifique a sua pasta de spam se não recebeu esta mensagem de e-mail. + update_needs_confirmation: Atualizou a sua conta com sucesso, mas temos de verificar o seu novo endereço de e-mail. Verifique o seu e-mail e siga a hiperligação de confirmação para confirmar o seu novo endereço de e-mail. Verifique a sua pasta de spam se não recebeu esta mensagem de correio eletrónico. + updated: A sua conta foi corretamente atualizada. sessions: already_signed_out: Sessão encerrada. signed_in: Sessão iniciada. signed_out: Sessão encerrada. unlocks: - send_instructions: Dentro de alguns momentos, irá receber um e-mail com instruções para desbloquear a sua conta. Consulte a sua pasta de lixo electrónico se não o encontrar. - send_paranoid_instructions: Se a sua conta existir, dentro de momentos irá receber um e-mail com instruções para a desbloquear. Consulte a sua pasta de lixo electrónico se não o encontrar. - unlocked: A sua conta foi correctamente desbloqueada. Queira iniciar uma nova sessão para continuar. + send_instructions: Receberá um e-mail com instruções sobre como desbloquear a sua conta dentro de alguns minutos. Verifique a sua pasta de spam se não recebeu este e-mail. + send_paranoid_instructions: Se a sua conta existir, receberá um e-mail com instruções sobre como a desbloquear dentro de alguns minutos. Verifique a sua pasta de spam se não recebeu este e-mail. + unlocked: A sua conta foi desbloqueada com sucesso. Inicie sessão para continuar. errors: messages: already_confirmed: já confirmado, por favor tente iniciar sessão - confirmation_period_expired: tem de ser confirmado durante %{period}, por favor tenta outra vez + confirmation_period_expired: tem de ser confirmado dentro de %{period}, por favor tente outra vez expired: expirou, por favor tente outra vez not_found: não encontrado not_locked: não estava bloqueada diff --git a/config/locales/doorkeeper.pt-PT.yml b/config/locales/doorkeeper.pt-PT.yml index 30ea62d9eb..3b4439584b 100644 --- a/config/locales/doorkeeper.pt-PT.yml +++ b/config/locales/doorkeeper.pt-PT.yml @@ -4,9 +4,9 @@ pt-PT: attributes: doorkeeper/application: name: Nome da aplicação - redirect_uri: URI de redireccionamento + redirect_uri: URI de redirecionamento scopes: Âmbitos - website: Página na teia da aplicação + website: Site da aplicação errors: models: doorkeeper/application: @@ -31,11 +31,11 @@ pt-PT: form: error: Ups! Verifique que o formulário não tem erros help: - native_redirect_uri: Usa %{native_redirect_uri} para testes locais - redirect_uri: Utiliza uma linha por URI - scopes: Separe as esferas de acção com espaços. Deixe em branco para usar autorizações predefinidas. + native_redirect_uri: Usar %{native_redirect_uri} para testes locais + redirect_uri: Usar uma linha por URI + scopes: Separe os âmbitos de aplicação com espaços. Deixe em branco para utilizar os âmbitos de aplicação predefinidos. index: - application: Aplicações + application: Aplicação callback_url: URL de retorno delete: Eliminar empty: Não tem aplicações. @@ -48,31 +48,31 @@ pt-PT: title: Nova aplicação show: actions: Ações - application_id: Id de Aplicação - callback_urls: Callback urls - scopes: Autorizações + application_id: Chave da aplicação + callback_urls: URLs de retorno + scopes: Âmbitos secret: Segredo title: 'Aplicação: %{name}' authorizations: buttons: - authorize: Autorize - deny: Não autorize + authorize: Autorizar + deny: Negar error: title: Ocorreu um erro new: prompt_html: "%{client_name} pretende ter permissão para aceder à sua conta. É uma aplicação de terceiros. Se não confia nesta aplicação, então não deve autorizá-la." review_permissions: Rever permissões - title: Autorização é necessária + title: Autorização necessária show: - title: Copiar o código desta autorização e colar na aplicação. + title: Copie este código de autorização e cole-o na aplicação. authorized_applications: buttons: revoke: Revogar confirmations: - revoke: Tens a certeza? + revoke: Tem a certeza? index: authorized_at: Autorizado em %{date} - description_html: Estas são aplicações que podem aceder à sua conta utilizando a API. Se encontrar aqui aplicativos que não reconhece, ou um aplicativo está com mau funcionamento, pode revogar o seu acesso. + description_html: Estas são as aplicações que podem aceder à sua conta utilizando a API. Se houver aplicações que não reconhece aqui, ou se uma aplicação estiver a comportar-se mal, pode revogar o seu acesso. last_used_at: Última utilização em %{date} never_used: Nunca utilizado scopes: Permissões @@ -81,15 +81,15 @@ pt-PT: errors: messages: access_denied: O proprietário do recurso ou servidor de autorização negou o pedido. - credential_flow_not_configured: As credenciais da palavra-passe do proprietário do recurso falhou devido a que Doorkeeper.configure.resource_owner_from_credentials não foram configuradas. - invalid_client: Autenticação do cliente falhou por causa de um cliente desconhecido, nenhum cliente de autenticação incluído ou método de autenticação não suportado. + credential_flow_not_configured: Falha no fluxo de credenciais da palavra-passe do proprietário do recurso porque Doorkeeper.configure.resource_owner_from_credentials não está configurado. + invalid_client: A autenticação do cliente falhou devido a cliente desconhecido, sem autenticação de cliente incluída ou método de autenticação não suportado. invalid_code_challenge_method: O método de validação do código tem de ser S256, o método simples não é suportado. invalid_grant: A concessão de autorização fornecida é inválida, expirou, foi revogada, não corresponde à URI de redirecionamento usada no pedido de autorização ou foi emitida para outro cliente. invalid_redirect_uri: A URI de redirecionamento incluída não é válida. invalid_request: missing_param: 'Parâmetro requerido em falta: %{value}.' - request_not_authorized: O pedido precisa ser autorizado. O parâmetro requerido para autorização da solicitação está ausente ou é inválido. - unknown: A solicitação não possui um parâmetro requerido, inclui um valor de parâmetro não suportado ou tem outro tipo de formato incorreto. + request_not_authorized: O pedido tem de ser autorizado. O parâmetro necessário para autorizar o pedido está em falta ou é inválido. + unknown: O pedido não tem um parâmetro obrigatório, inclui um valor de parâmetro não suportado ou está mal formado. invalid_resource_owner: As credenciais do proprietário do recurso não são válidas ou o proprietário do recurso não pode ser encontrado invalid_scope: O âmbito solicitado é inválido, desconhecido ou tem um formato incorreto. invalid_token: @@ -98,7 +98,7 @@ pt-PT: unknown: O token de acesso é inválido resource_owner_authenticator_not_configured: A procura pelo proprietário do recurso falhou porque Doorkeeper.configure.resource_owner_authenticator não foi configurado. server_error: O servidor de autorização encontrou uma condição inesperada que impediu o cumprimento do pedido . - temporarily_unavailable: O servidor de autorização não é capaz de lidar com o pedido devido a uma sobrecarga ou mantenimento do servidor. + temporarily_unavailable: O servidor de autorização não pode atualmente tratar o pedido devido a uma sobrecarga temporária ou à manutenção do servidor. unauthorized_client: O cliente não está autorizado a realizar esta solicitação usando este método. unsupported_grant_type: O tipo de concessão de autorização não é suportado pelo servidor de autorização. unsupported_response_type: O servidor de autorização não suporta este tipo de resposta. @@ -125,12 +125,12 @@ pt-PT: admin/reports: Administração de denúncias all: Acesso total à sua conta Mastodon blocks: Bloqueios - bookmarks: Itens Salvos + bookmarks: Marcadores conversations: Conversas - crypto: Encriptação ponta-a-ponta + crypto: Encriptação ponta a ponta favourites: Favoritos filters: Filtros - follow: A seguir, a silenciar, e a bloquear + follow: A seguir, a silenciar e a bloquear follows: Seguidores lists: Listas media: Anexos de media @@ -139,7 +139,7 @@ pt-PT: profile: O seu perfil Mastodon push: Notificações push reports: Denúncias - search: Pesquisa + search: Pesquisar statuses: Publicações layouts: admin: @@ -165,14 +165,14 @@ pt-PT: admin:write:email_domain_blocks: executar ações de moderação no bloqueio de domínios de e-mail admin:write:ip_blocks: executar ações de moderação no bloqueio de IPs admin:write:reports: executar ações de moderação em denúncias - crypto: usa encriptação ponta-a-ponta - follow: siga, bloqueie, desbloqueie, e deixa de seguir contas - profile: apenas ler as informações do perfil da sua conta + crypto: usar encriptação ponta a ponta + follow: alterar relações de conta + profile: ler apenas as informações do perfil da sua conta push: receber as suas notificações push - read: tenha acesso aos dados da tua conta + read: ler todos os dados da sua conta read:accounts: ver as informações da conta read:blocks: ver os seus bloqueios - read:bookmarks: ver os seus favoritos + read:bookmarks: ver os seus marcadores read:favourites: ver os seus favoritos read:filters: ver os seus filtros read:follows: ver quem você segue @@ -181,18 +181,18 @@ pt-PT: read:notifications: ver as suas notificações read:reports: ver as suas denúncias read:search: pesquisar em seu nome - read:statuses: ver todos os estados - write: publique por ti - write:accounts: modificar o seu perfil + read:statuses: ver todas as publicações + write: alterar todos os dados da sua conta + write:accounts: alterar o seu perfil write:blocks: bloquear contas e domínios - write:bookmarks: estado dos favoritos + write:bookmarks: marcar publicações write:conversations: silenciar e eliminar conversas - write:favourites: assinalar como favoritas + write:favourites: favoritar publicações write:filters: criar filtros write:follows: seguir pessoas write:lists: criar listas - write:media: carregar arquivos de media + write:media: enviar ficheiros de media write:mutes: silenciar pessoas e conversas write:notifications: limpar as suas notificações write:reports: denunciar outras pessoas - write:statuses: publicar estado + write:statuses: publicar publicações diff --git a/config/locales/gl.yml b/config/locales/gl.yml index b43ec5d172..86010b0665 100644 --- a/config/locales/gl.yml +++ b/config/locales/gl.yml @@ -343,7 +343,7 @@ gl: title: Emoticonas personalizadas uncategorized: Sen categoría unlist: Non listar - unlisted: Sen listar + unlisted: Fóra das listas update_failed_msg: Non foi posíbel actualizar a emoticona updated_msg: Actualizouse a emoticona de xeito correcto! upload: Subir @@ -1756,7 +1756,7 @@ gl: private_long: Mostrar só as seguidoras public: Público public_long: Visible para calquera - unlisted: Sen listar + unlisted: Fóra das listas unlisted_long: Visible para calquera, pero non en cronoloxías públicas statuses_cleanup: enabled: Borrar automáticamente publicacións antigas diff --git a/config/locales/pt-PT.yml b/config/locales/pt-PT.yml index 262063698b..1bd724595d 100644 --- a/config/locales/pt-PT.yml +++ b/config/locales/pt-PT.yml @@ -12,8 +12,8 @@ pt-PT: one: Seguidor other: Seguidores following: A seguir - instance_actor_flash: Esta conta é um actor virtual usado para representar a própria instância e não um utilizador individual. É usada para motivos de federação e não deve ser suspenso. - last_active: última vez activo + instance_actor_flash: Esta conta é um ator virtual utilizado para representar o servidor em si e não um utilizador individual. É utilizada para efeitos de federação e não deve ser suspensa. + last_active: última atividade link_verified_on: A posse desta hiperligação foi verificada em %{date} nothing_here: Não há nada aqui! pin_errors: @@ -25,19 +25,19 @@ pt-PT: admin: account_actions: action: Executar acção - title: Executar acção de moderação em %{acct} + title: Executar ação de moderação em %{acct} account_moderation_notes: create: Deixar uma nota - created_msg: Nota de moderação correctamente criada! + created_msg: Nota de moderação criada com sucesso! destroyed_msg: Nota de moderação destruída! accounts: approve: Aprovar - approved_msg: Inscrição de %{username} aprovada correctamente + approved_msg: Inscrição de %{username} aprovada com sucesso are_you_sure: Tens a certeza? avatar: Imagem de perfil by_domain: Domínio change_email: - changed_msg: Endereço de correio electrónico alterado! + changed_msg: E-mail alterado com sucesso! current_email: E-mail atual label: Alterar e-mail new_email: Novo e-mail @@ -57,12 +57,12 @@ pt-PT: demote: Despromoveu destroyed_msg: Os dados de %{username} estão agora em fila de espera para serem eliminados de imediato disable: Congelar - disable_two_factor_authentication: Desactivar autenticação por dois factores (2FA) + disable_two_factor_authentication: Desativar autenticação por dois fatores (2FA) disabled: Congelada display_name: Nome a mostrar domain: Domínio edit: Editar - email: Correio electrónico + email: E-mail email_status: Estado do e-mail enable: Descongelar enabled: Ativado @@ -86,7 +86,7 @@ pt-PT: memorialized: Em memória memorialized_msg: Conta %{username} transformada com sucesso em memorial moderation: - active: Activo + active: Ativo all: Todos disabled: Desativado pending: Pendente @@ -94,7 +94,7 @@ pt-PT: suspended: Supensos title: Moderação moderation_notes: Notas de moderação - most_recent_activity: Actividade mais recente + most_recent_activity: Atividade mais recente most_recent_ip: IP mais recente no_account_selected: Nenhuma conta foi alterada porque nenhuma foi selecionada no_limits_imposed: Sem limites impostos @@ -111,9 +111,9 @@ pt-PT: public: Público push_subscription_expires: A Inscrição PuSH expira redownload: Atualizar perfil - redownloaded_msg: Perfil de %{username} correctamente actualizado a partir da origem + redownloaded_msg: Perfil de %{username} atualizado a partir da origem com sucesso reject: Rejeitar - rejected_msg: Inscrição de %{username} correctamente rejeitada + rejected_msg: Inscrição de %{username} rejeitada com sucesso remote_suspension_irreversible: Os dados desta conta foram eliminados irreversivelmente. remote_suspension_reversible_hint_html: A conta foi suspensa no servidor de origem e os seus dados serão totalmente eliminados em %{date}. Até lá, o servidor de origem poderá recuperar esta conta sem quaisquer efeitos negativos. Se desejar eliminar todos os dados desta conta imediatamente, pode fazê-lo em baixo. remove_avatar: Remover a imagem de perfil @@ -152,7 +152,7 @@ pt-PT: title: Contas unblock_email: Desbloquear endereço de e-mail unblocked_email_msg: Endereço de e-mail de %{username} desbloqueado - unconfirmed_email: Correio electrónico por confirmar + unconfirmed_email: E-mail por confirmar undo_sensitized: Desmarcar como problemático undo_silenced: Desfazer silenciar undo_suspension: Desfazer supensão @@ -226,7 +226,7 @@ pt-PT: create_account_warning_html: "%{name} enviou um aviso para %{target}" create_announcement_html: "%{name} criou o novo anúncio %{target}" create_custom_emoji_html: "%{name} carregou o novo emoji %{target}" - create_domain_allow_html: "%{name} habilitou a federação com o domínio %{target}" + create_domain_allow_html: "%{name} permitiu a federação com o domínio %{target}" create_domain_block_html: "%{name} bloqueou o domínio %{target}" create_ip_block_html: "%{name} criou regra para o IP %{target}" create_unavailable_domain_html: "%{name} parou a entrega ao domínio %{target}" @@ -244,7 +244,7 @@ pt-PT: disable_2fa_user_html: "%{name} desativou o requerimento de autenticação em dois passos para o utilizador %{target}" disable_custom_emoji_html: "%{name} desabilitou o emoji %{target}" disable_user_html: "%{name} desativou o acesso para o utilizador %{target}" - enable_custom_emoji_html: "%{name} habilitou o emoji %{target}" + enable_custom_emoji_html: "%{name} ativou o emoji %{target}" enable_user_html: "%{name} ativou o acesso para o utilizador %{target}" memorialize_account_html: "%{name} transformou a conta de %{target} em um memorial" promote_user_html: "%{name} promoveu o utilizador %{target}" @@ -276,22 +276,22 @@ pt-PT: title: Registo de auditoria unavailable_instance: "(nome de domínio indisponível)" announcements: - destroyed_msg: Comunicado correctamente eliminado! + destroyed_msg: Comunicado eliminado com sucesso! edit: title: Editar comunicado empty: Nenhum comunicado encontrado. - live: Em directo + live: Em direto new: create: Criar comunicado title: Novo comunicado publish: Publicar - published_msg: Comunicado correctamente publicado! + published_msg: Comunicado publicado com sucesso! scheduled_for: Agendado para %{time} scheduled_msg: Comunicado agendado para publicação! title: Comunicados unpublish: Anular publicação - unpublished_msg: Comunicado correctamente retirado de publicação! - updated_msg: Comunicado correctamente actualizado! + unpublished_msg: Comunicado corretamente retirado de publicação! + updated_msg: Comunicado atualizado com sucesso! critical_update_pending: Atualização crítica pendente custom_emojis: assign_category: Atribuir categoria @@ -319,16 +319,16 @@ pt-PT: not_permitted: Não está autorizado a executar esta ação overwrite: Escrever por cima shortcode: Código de atalho - shortcode_hint: Pelo menos 2 caracteres, apenas caracteres alfanuméricos e underscores + shortcode_hint: Pelo menos 2 caracteres, apenas caracteres alfanuméricos e traços inferiores title: Emojis personalizados uncategorized: Não categorizados unlist: Não listar unlisted: Não inventariado update_failed_msg: Não foi possível atualizar esse emoji - updated_msg: Emoji correctamente actualizado! + updated_msg: Emoji atualizado com sucesso! upload: Enviar dashboard: - active_users: utilizadores activos + active_users: utilizadores ativos interactions: interações media_storage: Armazenamento de media new_users: novos utilizadores @@ -350,8 +350,8 @@ pt-PT: sources: Origem de inscrições space: Utilização do espaço title: Painel de controlo - top_languages: Principais idiomas activos - top_servers: Servidores mais activos + top_languages: Principais idiomas ativos + top_servers: Servidores mais ativos website: Página na teia disputes: appeals: @@ -359,7 +359,7 @@ pt-PT: title: Recursos domain_allows: add_new: Permitir federação com o domínio - created_msg: Permissão correctamente atribuída para federação + created_msg: O domínio foi autorizado com êxito para a federação destroyed_msg: Revogada a permissão de federação para o domínio export: Exportar import: Importar @@ -385,14 +385,14 @@ pt-PT: import: Importar new: create: Criar bloqueio - hint: O bloqueio por domínio não vai prevenir a criação de contas na base de dados, mas irá retroactiva e automaticamente aplicar certos métodos de moderação nessas contas. + hint: O bloqueio do domínio não impedirá a criação de registos de contas na base de dados, mas aplicará retroativamente e automaticamente métodos de moderação específicos a essas contas. severity: desc_html: "Limitar tornará as mensagens das contas neste domínio invisíveis a qualquer pessoa que não as esteja a seguir. Suspender removerá do seu servidor todo o conteúdo, media, e dados de perfil das contas deste domínio. Utilize Nenhum se apenas quiser rejeitar ficheiros media." noop: Nenhum silence: Limitar suspend: Suspender title: Novo bloqueio de domínio - no_domain_block_selected: Nenhum bloqueio de domínio foi alterado, pois nenhum foi seleccionado + no_domain_block_selected: Nenhum bloqueio de domínio foi alterado pois nenhum foi selecionado not_permitted: Não está autorizado a executar esta ação obfuscate: Ofuscar nome de domínio obfuscate_hint: Ofuscar parcialmente o nome de domínio na lista, caso estejam definidas limitações na publicação da lista de domínios @@ -527,7 +527,7 @@ pt-PT: title: Convites ip_blocks: add_new: Criar regra - created_msg: Nova regra de IP correctamente adicionada + created_msg: Nova regra de IP corretamente adicionada delete: Eliminar expires_in: '1209600': 2 semanas @@ -547,15 +547,15 @@ pt-PT: delete: Eliminar description_html: Um repetidor de federação é um servidor intermediário que troca grandes volumes de publicações públicas entre instâncias que o subscrevem e publicam. Ele pode ajudar pequenas e medias instâncias a descobrir conteúdo do fediverso que, de outro modo, exigiria que os utilizadores locais seguissem manualmente outras pessoas em instâncias remotas. disable: Desativar - disabled: Desactivado - enable: Activar + disabled: Desativado + enable: Ativar enable_hint: Uma vez ativado, a tua instância irá assinar todas as publicações deste repetidor e irá começar a enviar as suas publicações públicas para lá. enabled: Ativado inbox_url: URL do repetidor pending: À espera da aprovação do repetidor save_and_enable: Guardar e ativar setup: Configurar uma ligação ao repetidor - signatures_not_enabled: Os repetidores não funcionarão correctamente enquanto o modo seguro ou o modo de lista branca estiverem activados + signatures_not_enabled: Os repetidores não funcionarão corretamente enquanto o modo seguro ou o modo de lista branca estiverem ativados status: Estado title: Retransmissores report_notes: @@ -618,27 +618,27 @@ pt-PT: reported_by: Denunciado por reported_with_application: Reportado com a aplicação resolved: Resolvido - resolved_msg: Denúncia correctamente resolvida! + resolved_msg: Denúncia resolvida com sucesso! skip_to_actions: Passar para as ações status: Estado statuses: Conteúdo denunciado statuses_description_html: O conteúdo ofensivo será citado na comunicação com a conta denunciada summary: action_preambles: - delete_html: 'Você está prestes a remover algumas das publicações de @%{acct}. Isto irá:' - mark_as_sensitive_html: 'Você está prestes a marcar alguns dos posts de @%{acct}como sensível. Isto irá:' - silence_html: 'Você está prestes a limitar a conta do @%{acct}. Isto irá:' - suspend_html: 'Você está prestes a suspender a conta de @%{acct}. Isto irá:' + delete_html: 'Está prestes a remover algumas das publicações de @%{acct}. Isto irá:' + mark_as_sensitive_html: 'Está prestes a marcar algumas das publicações de @%{acct}como sensível. Isto irá:' + silence_html: 'Está prestes a limitar a conta de @%{acct}. Isto irá:' + suspend_html: 'Está prestes a suspender a conta de @%{acct}. Isto irá:' actions: delete_html: Excluir as publicações ofensivas mark_as_sensitive_html: Marcar a mídia dos posts ofensivos como sensível silence_html: Limitar firmemente o alcance de @%{acct}, tornando seus perfis e conteúdos apenas visíveis para pessoas que já os estão seguindo ou olhando manualmente no perfil - suspend_html: Suspender @%{acct}, tornando seu perfil e conteúdo inacessíveis e impossível de interagir com + suspend_html: Suspender @%{acct}, tornando seu perfil e conteúdo inacessíveis e impossível de interagir close_report: 'Marcar relatório #%{id} como resolvido' - close_reports_html: Marcar todos os relatórios contra @%{acct} como resolvidos - delete_data_html: Excluir @%{acct}perfil e conteúdo 30 dias a menos que sejam dessuspensos + close_reports_html: Marcar todas as denúncias contra @%{acct} como resolvidas + delete_data_html: Eliminar o perfil de @%{acct} e conteúdos daqui a 30 dias, a menos que entretanto sejam suspensos preview_preamble_html: "@%{acct} receberá um aviso com o seguinte conteúdo:" - record_strike_html: Registre um ataque contra @%{acct} para ajudá-lo a escalar futuras violações desta conta + record_strike_html: Registar um ataque contra @%{acct} para ajudar a escalar futuras violações desta conta warning_placeholder: Argumentos adicionais opcionais para a acção de moderação. target_origin: Origem da conta denunciada title: Denúncias @@ -693,7 +693,7 @@ pt-PT: manage_settings: Gerir Configurações manage_settings_description: Permite aos utilizadores alterar as configurações do sítio na teia manage_taxonomies: Gerir Taxonomias - manage_taxonomies_description: 'Permite aos utilizadores avaliar o conteúdo em alta e atualizar as configurações de #etiquetas' + manage_taxonomies_description: Permite aos utilizadores rever o conteúdo em tendência e atualizar as configurações de hashtag manage_user_access: Gerir Acesso de Utilizador manage_users: Gerir Utilizadores manage_users_description: Permite aos utilizadores ver os detalhes de outros utilizadores e executar ações de moderação contra eles @@ -743,13 +743,13 @@ pt-PT: publish_discovered_servers: Publicar servidores descobertos publish_statistics: Publicar estatísticas title: Descobrir - trends: Em alta + trends: Tendências domain_blocks: all: Para toda a gente disabled: Para ninguém users: Para utilizadores locais que se encontrem autenticados registrations: - moderation_recommandation: Por favor, certifique-se de que você tem uma equipe de moderação adequada e reativa antes de abrir os registros para todos! + moderation_recommandation: Certifique-se de que dispõe de uma equipa de moderação adequada e reativa antes de abrir as inscrições a todos! preamble: Controle quem pode criar uma conta no seu servidor. title: Inscrições registrations_mode: @@ -757,7 +757,7 @@ pt-PT: approved: Registo sujeito a aprovação none: Ninguém se pode registar open: Qualquer pessoa se pode registar - warning_hint: Recomendamos o uso de "Aprovação necessária para se cadastrar", a menos que você esteja confiante de que sua equipe de moderação pode lidar com spam e registros maliciosos em tempo hábil. + warning_hint: Recomendamos a utilização de “É necessária aprovação para o registo”, a menos que esteja confiante de que a sua equipa de moderação pode tratar o spam e os registos maliciosos de forma atempada. security: authorized_fetch: Exigir autenticação de servidores federados authorized_fetch_hint: Exigir autenticação de servidores federados permite uma aplicação mais rigorosa de bloqueios tanto ao nível do utilizador como do servidor. No entanto, isso é feito à custa de uma diminuição de desempenho, reduz o alcance das suas respostas e pode introduzir problemas de compatibilidade com alguns serviços federados. Além disso, isso não impede os atores mais empenhados de aceder às suas publicações e contas públicas. @@ -766,7 +766,7 @@ pt-PT: title: Definições do servidor site_uploads: delete: Eliminar arquivo carregado - destroyed_msg: Envio de sítio na teia correctamente eliminado! + destroyed_msg: Envio do site eliminado com sucesso! software_updates: critical_update: Crítico — por favor, atualize rapidamente documentation_link: Saber mais @@ -800,7 +800,7 @@ pt-PT: reblogs: Re-publicacões status_changed: Publicação alterada title: Estado das contas - trending: Em alta + trending: Em tendência visibility: Visibilidade with_media: Com media strikes: @@ -823,7 +823,7 @@ pt-PT: elasticsearch_health_yellow: message_html: O cluster elasticsearch não está de boa saúde (estado amarelo), pode querer investigar o motivo elasticsearch_index_mismatch: - message_html: Os mapeamentos elasticsearch estão desatualizados. Por favor, execute tootctl search deploy --only=%{value} + message_html: Os mapeamentos de índice Elasticsearch estão desatualizados. Execute tootctl search deploy --only=%{value} elasticsearch_preset: action: Ver a documentação message_html: O seu cluster elasticsearch tem mais de um nó, mas o Mastodon não está configurado para os usar. @@ -831,9 +831,9 @@ pt-PT: action: Ver documentação message_html: O seu cluster elasticsearch tem apenas um nó, ES_PRESET deve ser configurado para single_node_cluster. elasticsearch_reset_chewy: - message_html: O seu índice de sistema elasticsearch está desatualizado devido a uma mudança de configuração. Por favor, execute tootctl search deploy --reset-chewy para o atualizar. + message_html: O seu índice de sistema Elasticsearch está desatualizado devido a uma mudança de configuração. Execute tootctl search deploy --reset-chewy para o atualizar. elasticsearch_running_check: - message_html: Não foi possível conectar ao Elasticsearch. Por favor, verifique se está em execução, ou desabilite a pesquisa de texto completo + message_html: Não foi possível conectar ao Elasticsearch. Verifique se está em execução ou desative a pesquisa de texto completo elasticsearch_version_check: message_html: 'Versão de Elasticsearch incompatível: %{value}' version_comparison: A versão de Elasticsearch %{running_version} está em execução. No entanto, é obrigatória a versão %{required_version} @@ -872,14 +872,14 @@ pt-PT: review: Estado da revisão search: Pesquisar title: Hashtags - updated_msg: 'Definições de #etiquetas correctamente actualizadas' + updated_msg: 'Definições de #etiquetas atualizadas com sucesso' title: Administração trends: allow: Permitir approved: Aprovado disallow: Não permitir links: - allow: Permitir ligação + allow: Permitir hiperligação allow_provider: Permitir editor description_html: Estas são as ligações que presentemente estão a ser muito partilhadas por contas visíveis pelo seu servidor. Estas podem ajudar os seus utilizador a descobrir o que está a acontecer no mundo. Nenhuma ligação é exibida publicamente até que o editor a aprove. Também pode permitir ou rejeitar ligações em avulso. disallow: Não permitir ligação @@ -890,15 +890,15 @@ pt-PT: shared_by_over_week: one: Partilhado por uma pessoa na última semana other: Partilhado por %{count} pessoas na última semana - title: Ligações em alta + title: Hiperligações em tendência usage_comparison: Partilhado %{today} vezes hoje, em comparação com %{yesterday} ontem not_allowed_to_trend: Não permitido para tendência only_allowed: Apenas permitidos pending_review: Pendente de revisão preview_card_providers: - allowed: Ligações deste editor poderão vir a ficar em alta + allowed: As hiperligações deste editor podem ser tendência description_html: Estes são os domínios a partir dos quais ligações são frequentemente partilhadas no seu servidor. As suas ligações não serão colocadas em alta a menos que o seu domínio de origem seja aprovado. A sua aprovação (ou rejeição) estende-se a subdomínios. - rejected: Ligações deste editor não serão postas em alta + rejected: As hiperligações deste editor não podem ser tendência title: Editores rejected: Rejeitado statuses: @@ -907,18 +907,18 @@ pt-PT: description_html: Estas são publicações que o seu servidor conhece e que atualmente estão a ser frequentemente partilhadas e adicionadas aos favoritos. Isto pode ajudar os seus utilizadores, novos e retornados, a encontrar mais pessoas para seguir. Nenhuma publicação será exibida publicamente até que aprove o autor, e o autor permita que a sua conta seja sugerida a outros. Você também pode permitir ou rejeitar publicações individualmente. disallow: Não permitir publicação disallow_account: Não permitir autor - no_status_selected: Nenhuma publicação em alta foi alterada, pois nenhuma foi selecionada + no_status_selected: Não foram alteradas quaisquer publicações de tendências, uma vez que nenhuma foi selecionada not_discoverable: O autor optou por não permitir que a sua conta seja sugerida a outros shared_by: one: Partilhado ou adicionado aos marcadores uma vez other: Partilhado e adicionado aos marcadores %{friendly_count} vezes - title: Publicações em alta + title: Publicações em tendência tags: current_score: Pontuação atual %{score} dashboard: tag_accounts_measure: utilizadores únicos tag_languages_dimension: Idiomas mais populares - tag_servers_dimension: Topo de servidores + tag_servers_dimension: Servidores mais populares tag_servers_measure: servidores diferentes tag_uses_measure: utilizações totais description_html: 'Estas são as #etiquetas que aparecem atualmente com frequência em publicações visíveis pelo seu servidor. Isto pode ajudar os seus utilizadores a descobrir o que está ser mais falado no momento. Nenhuma #etiqueta será exibida publicamente até que a aprove.' @@ -928,15 +928,16 @@ pt-PT: not_trendable: Não aparecerá nas tendências not_usable: Não pode ser utilizada peaked_on_and_decaying: Máximo em %{date}, agora a decair - title: Etiquetas em alta - trendable: Pode aparecer em alta - trending_rank: 'Em alta #%{rank}' + title: Etiquetas em tendência + trendable: Pode aparecer nas tendências + trending_rank: 'Tendência #%{rank}' usable: Pode ser utilizada usage_comparison: Utilizada %{today} vezes hoje, em comparação com %{yesterday} ontem used_by_over_week: one: Utilizada por uma pessoa na última semana other: Utilizada por %{count} pessoas na última semana - trending: Em alta + title: Recomendações e tendências + trending: Em tendência warning_presets: add_new: Adicionar novo delete: Eliminar @@ -946,13 +947,13 @@ pt-PT: webhooks: add_new: Adicionar endpoint delete: Eliminar - description_html: Um webhook possibilita que o Mastodon envie notificações em tempo real de eventos seleccionados, para uma aplicação sua, de modo que esta possa espoletar ações automaticamente. + description_html: Um webhook possibilita que o Mastodon envie notificações em tempo real de eventos selecionados, para uma aplicação sua, de modo que esta possa despoletar ações automaticamente. disable: Desativar disabled: Desativado edit: Editar endpoint empty: Não tem ainda qualquer endpoint de webhook configurado. enable: Ativar - enabled: Activo + enabled: Ativo enabled_events: one: 1 evento ativado other: "%{count} eventos ativados" @@ -993,18 +994,18 @@ pt-PT: body: Foram lançadas novas versões do Mastodon, talvez queira atualizar! subject: Estão disponíveis novas versões do Mastodon para %{instance}! new_trends: - body: 'Os seguintes itens precisam ser revistos antes de poderem ser exibidos publicamente:' + body: 'Os seguintes itens necessitam de uma revisão antes de poderem ser apresentados publicamente:' new_trending_links: - title: Ligações em alta + title: Hiperligações em tendência new_trending_statuses: - title: Publicações em alta + title: Publicações em tendência new_trending_tags: - title: Etiquetas em alta + title: Etiquetas em tendência subject: Novas tendências para revisão em %{instance} aliases: add_new: Criar pseudónimo created_msg: Criou com sucesso um novo pseudónimo. Pode agora iniciar a migração da conta antiga. - deleted_msg: O pseudónimo foi correctamente eliminado. Não será mais possível migrar a partir dessa conta. + deleted_msg: O pseudónimo foi removido com êxito. Deixará de ser possível passar dessa conta para esta. empty: Não tem pseudónimos. hint_html: Se quiser mudar de outra conta para esta, pode criar aqui um pseudónimo, que é necessário antes de poder prosseguir com a migração de seguidores da conta antiga para esta. Esta ação por si só é inofensiva e reversível. A migração da conta é iniciada a partir da conta antiga. remove: Desvincular pseudónimo @@ -1026,8 +1027,8 @@ pt-PT: view_profile: Ver perfil view_status: Ver publicação applications: - created: Aplicação correctamente criada - destroyed: Aplicação correctamente eliminada + created: Aplicação criada com sucesso + destroyed: Aplicação eliminada com sucesso logout: Sair regenerate_token: Regenerar token de acesso token_regenerated: Token de acesso regenerado com sucesso @@ -1036,7 +1037,7 @@ pt-PT: auth: apply_for_account: Solicitar uma conta captcha_confirmation: - help_html: Se tiver problemas a resolver o CAPTCHA, pode entrar em contacto conosco através de %{email} e poderemos ajudá-lo. + help_html: Se tiver problemas a resolver o CAPTCHA, pode entrar em contacto connosco através de %{email} e poderemos ajudá-lo. hint_html: Só mais uma coisa! Precisamos confirmar que você é um humano (isto para que possamos evitar spam!). Resolva o CAPTCHA abaixo e clique em "Continuar". title: Verificação de segurança confirmations: @@ -1138,7 +1139,7 @@ pt-PT: confirm_password: Insira sua palavra-passe atual para verificar a sua identidade confirm_username: Insira seu nome de utilizador para confirmar o procedimento proceed: Eliminar conta - success_msg: A sua conta foi correctamente eliminada + success_msg: A sua conta foi eliminada com sucesso warning: before: 'Antes de continuar, por favor leia cuidadosamente estas notas:' caches: O conteúdo que foi armazenado em cache por outras instâncias pode perdurar @@ -1335,11 +1336,11 @@ pt-PT: muting: Importando contas silenciadas type: Tipo de importação type_groups: - constructive: Seguidores e Marcadores + constructive: Seguidores e marcadores destructive: Bloqueios e silenciamentos types: blocking: Lista de bloqueio - bookmarks: Itens salvos + bookmarks: Marcadores domain_blocking: Lista de domínios bloqueados following: Lista de pessoas que estás a seguir lists: Listas @@ -1395,7 +1396,7 @@ pt-PT: acct: Mudou-se para cancel: Cancelar redirecionamento cancel_explanation: Cancelar o redirecionamento irá reativar a sua conta atual, mas não trará de volta os seguidores que foram migrados para essa conta. - cancelled_msg: Cancelou correctamente o redireccionamento. + cancelled_msg: Cancelou corretamente o redirecionamento. errors: already_moved: é a mesma conta para a qual já migrou missing_also_known_as: não é um pseudónimo dessa conta @@ -1405,13 +1406,13 @@ pt-PT: followers_count: Seguidores no momento da migração incoming_migrations: A migrar de uma conta diferente incoming_migrations_html: Para migrar de outra conta para esta, primeiro você precisa criar um pseudónimo. - moved_msg: A sua conta está agora a ser redireccionada para %{acct} e os seus seguidores estão a ser transferidos. + moved_msg: A sua conta está agora a ser redirecionada para %{acct} e os seus seguidores estão a ser transferidos. not_redirecting: A sua conta não está atualmente a ser redirecionada para nenhuma outra conta. on_cooldown: Migrou recentemente a sua conta. Esta função ficará disponível novamente em %{count} dias. past_migrations: Migrações anteriores proceed_with_move: Migrar seguidores - redirected_msg: A sua conta está agora a ser redireccionada para %{acct}. - redirecting_to: A sua conta está a ser redireccionada para %{acct}. + redirected_msg: A sua conta está agora a ser redirecionada para %{acct}. + redirecting_to: A sua conta está a ser redirecionada para %{acct}. set_redirect: Definir redirecionamento warning: backreference_required: A nova conta deve primeiro ser configurada para que esta seja referenciada @@ -1419,7 +1420,7 @@ pt-PT: cooldown: Após a migração, há um período de tempo de espera durante o qual não poderá voltar a migrar disabled_account: Posteriormente, a sua conta atual não será totalmente utilizável. No entanto, continuará a ter acesso à exportação de dados, bem como à reativação. followers: Esta ação irá migrar todos os seguidores da conta atual para a nova conta - only_redirect_html: Em alternativa, pode apenas colocar um redireccionamento no seu perfil. + only_redirect_html: Em alternativa, pode apenas colocar um redirecionamento no seu perfil. other_data: Nenhum outro dado será migrado automaticamente redirect: O perfil da sua conta atual será atualizado com um aviso de redirecionamento e será excluído das pesquisas moderation: @@ -1546,7 +1547,7 @@ pt-PT: remove_selected_follows: Deixar de seguir os utilizadores selecionados status: Estado da conta remote_follow: - missing_resource: Não foi possível encontrar o URL de redireccionamento para a sua conta + missing_resource: Não foi possível encontrar o URL de redirecionamento para a sua conta reports: errors: invalid_rules: não faz referência a regras válidas @@ -1639,7 +1640,7 @@ pt-PT: user_domain_block: Bloqueou %{target_name} lost_followers: Seguidores perdidos lost_follows: Pessoas que segue perdidas - preamble: Pode perder seguidores e pessoas que segue quando bloqueia um domínio ou quando os seus moderadores decidem suspender um servidor remoto. Quando isso acontecer, poderá descarregar listas de relações cessadas, para serem inspeccionadas e possivelmente importadas para outro servidor. + preamble: Pode perder seguidores e pessoas que segue quando bloqueia um domínio ou quando os seus moderadores decidem suspender um servidor remoto. Quando isso acontecer, poderá descarregar listas de relações cortadas, para serem inspecionadas e possivelmente importadas para outro servidor. purged: Informações sobre este servidor foram purgadas pelos administradores do seu servidor. type: Evento statuses: @@ -1706,8 +1707,8 @@ pt-PT: keep_pinned_hint: Não apagar nenhuma das suas publicações afixadas keep_polls: Manter sondagens keep_polls_hint: Não apaga nenhuma das suas sondagens - keep_self_bookmark: Manter as publicações que guardou - keep_self_bookmark_hint: Não apaga as suas próprias publicações se as tiver guardado + keep_self_bookmark: Manter as publicações que marcou + keep_self_bookmark_hint: Não elimina as suas próprias publicações se as tiver nos marcadores keep_self_fav: Manter as publicações que marcou keep_self_fav_hint: Não apaga as suas próprias publicações se as tiver marcado min_age: @@ -1852,8 +1853,8 @@ pt-PT: one: "%{people} pessoa nos últimos 2 dias" other: "%{people} pessoas nos últimos 2 dias" hashtags_subtitle: Explore o que está em tendência desde os últimos 2 dias - hashtags_title: Trending hashtags - hashtags_view_more: Ver mais hashtags em alta + hashtags_title: Etiquetas em tendência + hashtags_view_more: Ver mais etiquetas em tendência post_action: Compor post_step: Diga olá para o mundo com texto, fotos, vídeos ou enquetes. post_title: Faça a sua primeira publicação @@ -1874,7 +1875,7 @@ pt-PT: extra_instructions_html: Dica: A ligação no seu site pode ser invisível. A parte importante é rel="me" que impede a personificação em sites com conteúdo gerado pelo utilizador. Pode até utilizar uma etiqueta link no cabeçalho da página ao invés de a, mas o HTML deve ser acessível sem executar JavaScript. here_is_how: Veja como hint_html: "Verificar a sua identidade no Mastodon é para todos. Baseado em normas públicas da web, agora e para sempre gratuitas. Tudo o que precisa é de um site pessoal pelo qual as pessoas o reconheçam. Quando coloca no seu perfil uma ligação para esse site, vamos verificar que o site tem uma ligação de volta para o seu perfil e mostrar um indicador visual." - instructions_html: Copie e cole o código abaixo no HTML do seu site. Em seguida, adicione o endereço do seu site em um dos campos extras no seu perfil, na aba "Editar perfil" e salve as alterações. + instructions_html: Copie e cole o código abaixo no HTML do seu site. Em seguida, adicione o endereço do seu site num dos campos extras no seu perfil, na aba "Editar perfil" e guarde as alterações. verification: Verificação verified_links: As suas ligações verificadas webauthn_credentials: diff --git a/config/locales/simple_form.ar.yml b/config/locales/simple_form.ar.yml index e552b42b18..81be19a44e 100644 --- a/config/locales/simple_form.ar.yml +++ b/config/locales/simple_form.ar.yml @@ -206,7 +206,7 @@ ar: setting_aggregate_reblogs: جمّع المنشورات المعاد نشرها في الخيوط الزمنية setting_always_send_emails: ارسل إشعارات البريد الإلكتروني دائماً setting_auto_play_gif: تشغيل تلقائي لِوَسائط جيف المتحركة - setting_boost_modal: إظهار مربع حوار التأكيد قبل إعادة مشاركة أي منشور + setting_boost_modal: إظهار مربع حوار التأكيد قبل إعادة نشر أي منشور setting_default_language: لغة النشر setting_default_privacy: خصوصية المنشور setting_default_sensitive: اعتبر الوسائط دائما كمحتوى حساس diff --git a/config/locales/simple_form.pt-PT.yml b/config/locales/simple_form.pt-PT.yml index a76076a5cb..25348f2770 100644 --- a/config/locales/simple_form.pt-PT.yml +++ b/config/locales/simple_form.pt-PT.yml @@ -52,7 +52,7 @@ pt-PT: locale: O idioma da interface de utilizador, e-mails e notificações push password: Use pelo menos 8 caracteres phrase: Será correspondido independentemente da capitalização ou do aviso de conteúdo duma publicação - scopes: Quais as API a que será concedido acesso. Se escolher uma abrangência de nível superior, não precisará de as seleccionar individualmente. + scopes: Quais as API a que a aplicação terá permissão para aceder. Se selecionar um âmbito de nível superior, não precisa de selecionar âmbitos individuais. setting_aggregate_reblogs: Não mostrar novos reforços de publicações recentemente reforçadas (só afecta publicações acabadas de reforçar) setting_always_send_emails: Normalmente as notificações por e-mail não serão enviadas quando estiver a utilizar ativamente o Mastodon setting_default_sensitive: Media problemática oculta por padrão, pode ser revelada com um clique @@ -81,7 +81,7 @@ pt-PT: backups_retention_period: Os utilizadores têm a possibilidade de gerar arquivos das suas mensagens para descarregar mais tarde. Quando definido para um valor positivo, estes arquivos serão automaticamente eliminados do seu armazenamento após o número de dias especificado. bootstrap_timeline_accounts: Estas contas serão destacadas no topo das recomendações aos novos utilizadores. closed_registrations_message: Apresentado quando as inscrições estiverem encerradas - content_cache_retention_period: Todas as publicações de outros servidores (incluindo boosts e respostas) serão eliminadas após o número de dias especificado, independentemente de qualquer interação do utilizador local com essas publicações. Isto inclui publicações em que um utilizador local as tenha marcado como favoritas ou adicionado aos items salvos. As menções privadas entre utilizadores de instâncias diferentes também se perderão e serão impossíveis de restaurar. A utilização desta definição destina-se a instâncias para fins especiais e quebra muitas expectativas dos utilizadores quando implementada para utilização geral. + content_cache_retention_period: Todas as publicações de outros servidores (incluindo boosts e respostas) serão eliminadas após o número de dias especificado, independentemente de qualquer interação do utilizador local com essas publicações. Isto inclui publicações em que um utilizador local as tenha marcado ou favoritado. As menções privadas entre utilizadores de instâncias diferentes também se perderão e serão impossíveis de restaurar. A utilização desta definição destina-se a instâncias para fins especiais e quebra muitas expectativas dos utilizadores quando implementada para utilização geral. custom_css: Pode aplicar estilos personalizados na versão web do Mastodon. favicon: WEBP, PNG, GIF ou JPG. Substitui o ícone de favorito padrão do Mastodon por um ícone personalizado. mascot: Sobrepõe-se à ilustração na interface web avançada. @@ -99,9 +99,9 @@ pt-PT: theme: Tema que os visitantes e os novos utilizadores veem. thumbnail: Uma imagem de cerca de 2:1, apresentada ao lado da informação do seu servidor. timeline_preview: Os visitantes sem sessão iniciada poderão consultar as publicações públicas mais recentes disponíveis no servidor. - trendable_by_default: Ignorar a revisão manual do conteúdo em alta. Elementos em avulso poderão ainda assim ser retirados das tendências mesmo após a sua apresentação. - trends: As publicações em alta mostram quais as publicações, etiquetas e notícias que estão a ganhar destaque no seu servidor. - trends_as_landing_page: Mostrar conteúdo de tendências para usuários logados e visitantes em vez de uma descrição deste servidor. Requer que as tendências sejam ativadas. + trendable_by_default: Ignorar a revisão manual do conteúdo de tendências. Os itens individuais ainda podem ser removidos das tendências após a apresentação. + trends: As tendências mostram quais as publicações, etiquetas e notícias que estão a ganhar destaque no seu servidor. + trends_as_landing_page: Mostrar conteúdo de tendências a utilizadores e visitantes com sessão terminada em vez de uma descrição deste servidor. Requer que as tendências estejam ativadas. form_challenge: current_password: Está a entrar numa área segura imports: @@ -129,7 +129,7 @@ pt-PT: tag: name: Só pode alterar a capitalização das letras, por exemplo, para torná-las mais legíveis user: - chosen_languages: Quando seleccionado, só serão mostradas nas cronologias públicas as publicações nos idiomas escolhidos + chosen_languages: Quando selecionado, só serão mostradas nas cronologias públicas as publicações nos idiomas escolhidos role: A função controla que permissões o utilizador tem user_role: color: Cor a ser utilizada para a função em toda a interface de utilizador, como RGB no formato hexadecimal @@ -222,7 +222,7 @@ pt-PT: setting_reduce_motion: Reduz movimento em animações setting_system_font_ui: Usar o tipo de letra padrão do sistema setting_theme: Tema do sítio - setting_trends: Mostrar o que está hoje em alta + setting_trends: Mostrar as tendências de hoje setting_unfollow_modal: Solicitar confirmação antes de deixar de seguir alguém setting_use_blurhash: Mostrar gradientes coloridos para medias ocultas setting_use_pending_items: Modo lento @@ -253,7 +253,7 @@ pt-PT: mascot: Mascote personalizada (legado) media_cache_retention_period: Período de retenção de ficheiros de media em cache peers_api_enabled: Publicar lista de servidores descobertos na API - profile_directory: Habilitar diretório de perfis + profile_directory: Ativar o diretório de perfis registrations_mode: Quem se pode inscrever require_invite_text: Requerer uma razão para entrar show_domain_blocks: Mostrar domínios bloqueados @@ -268,8 +268,8 @@ pt-PT: theme: Tema predefinido thumbnail: Miniatura do servidor timeline_preview: Permitir acesso não autenticado às cronologias públicas - trendable_by_default: Permitir publicações em alta sem revisão prévia - trends: Activar publicações em alta + trendable_by_default: Permitir tendências sem revisão prévia + trends: Ativar tendências trends_as_landing_page: Usar tendências como página inicial interactions: must_be_follower: Bloquear notificações de não-seguidores @@ -303,7 +303,7 @@ pt-PT: label: Está disponível uma nova versão do Mastodon none: Nunca notificar atualizações (não recomendado) patch: Notificar sobre atualizações de correções de problemas - trending_tag: Uma nova publicação em alta requer avaliação + trending_tag: Uma nova publicação em tendência requer revisão rule: hint: Informação Adicional text: Regra @@ -313,7 +313,7 @@ pt-PT: tag: listable: Permitir que esta etiqueta apareça em pesquisas e no diretório de perfis name: Etiqueta - trendable: Permitir que esta etiqueta apareça em alta + trendable: Permitir que esta etiqueta apareça nas tendências usable: Permitir que as publicações usem esta hashtag localmente user: role: Cargo From b265a654d74f649b6a58debe39a439cc9b07b730 Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Thu, 5 Sep 2024 11:46:11 +0200 Subject: [PATCH 112/153] Fix wrong width on content warnings and filters in web UI (#31761) --- 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 d892c008bc..2fc195a3bd 100644 --- a/app/javascript/styles/mastodon/components.scss +++ b/app/javascript/styles/mastodon/components.scss @@ -10916,6 +10916,7 @@ noscript { } .content-warning { + box-sizing: border-box; background: rgba($ui-highlight-color, 0.05); color: $secondary-text-color; border-top: 1px solid; From ba9fd1c32e760582041758105b2844debed640a3 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Thu, 5 Sep 2024 05:48:33 -0400 Subject: [PATCH 113/153] Add coverage for `Account#prepare_contents` callback (#31748) --- spec/models/account_spec.rb | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/spec/models/account_spec.rb b/spec/models/account_spec.rb index 27707fa897..1e8e4b1e4d 100644 --- a/spec/models/account_spec.rb +++ b/spec/models/account_spec.rb @@ -723,6 +723,30 @@ RSpec.describe Account do end end + describe '#prepare_contents' do + subject { Fabricate.build :account, domain: domain, note: ' padded note ', display_name: ' padded name ' } + + context 'with local account' do + let(:domain) { nil } + + it 'strips values' do + expect { subject.valid? } + .to change(subject, :note).to('padded note') + .and(change(subject, :display_name).to('padded name')) + end + end + + context 'with remote account' do + let(:domain) { 'host.example' } + + it 'preserves values' do + expect { subject.valid? } + .to not_change(subject, :note) + .and(not_change(subject, :display_name)) + end + end + end + describe 'Normalizations' do describe 'username' do it { is_expected.to normalize(:username).from(" \u3000bob \t \u00a0 \n ").to('bob') } From f9712fad1b62e93961280243970c6ccff4d3e3ff Mon Sep 17 00:00:00 2001 From: James May Date: Thu, 5 Sep 2024 19:48:42 +1000 Subject: [PATCH 114/153] Direct link to each authorized_application entry with html anchor (#31677) Co-authored-by: Matt Jankowski --- app/views/oauth/authorized_applications/index.html.haml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/oauth/authorized_applications/index.html.haml b/app/views/oauth/authorized_applications/index.html.haml index b6819bbd72..eb544d079b 100644 --- a/app/views/oauth/authorized_applications/index.html.haml +++ b/app/views/oauth/authorized_applications/index.html.haml @@ -7,7 +7,7 @@ .applications-list - @applications.each do |application| - .applications-list__item + .applications-list__item{ id: dom_id(application) } - if application.website.present? = link_to application.name, application.website, target: '_blank', rel: 'noopener noreferrer', class: 'announcements-list__item__title' - else From bd8cd0c6e746356eea83ffc4d3185a51e4eeb5dc Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Thu, 5 Sep 2024 09:50:38 +0000 Subject: [PATCH 115/153] Update dependency cssnano to v7.0.6 (#31757) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- yarn.lock | 110 +++++++++++++++++++++++++++--------------------------- 1 file changed, 55 insertions(+), 55 deletions(-) diff --git a/yarn.lock b/yarn.lock index c77ebfa444..1b3a7f1e40 100644 --- a/yarn.lock +++ b/yarn.lock @@ -6717,26 +6717,26 @@ __metadata: languageName: node linkType: hard -"cssnano-preset-default@npm:^7.0.5": - version: 7.0.5 - resolution: "cssnano-preset-default@npm:7.0.5" +"cssnano-preset-default@npm:^7.0.6": + version: 7.0.6 + resolution: "cssnano-preset-default@npm:7.0.6" dependencies: browserslist: "npm:^4.23.3" css-declaration-sorter: "npm:^7.2.0" cssnano-utils: "npm:^5.0.0" - postcss-calc: "npm:^10.0.1" + postcss-calc: "npm:^10.0.2" postcss-colormin: "npm:^7.0.2" - postcss-convert-values: "npm:^7.0.3" - postcss-discard-comments: "npm:^7.0.2" + postcss-convert-values: "npm:^7.0.4" + postcss-discard-comments: "npm:^7.0.3" postcss-discard-duplicates: "npm:^7.0.1" postcss-discard-empty: "npm:^7.0.0" postcss-discard-overridden: "npm:^7.0.0" - postcss-merge-longhand: "npm:^7.0.3" - postcss-merge-rules: "npm:^7.0.3" + postcss-merge-longhand: "npm:^7.0.4" + postcss-merge-rules: "npm:^7.0.4" postcss-minify-font-values: "npm:^7.0.0" postcss-minify-gradients: "npm:^7.0.0" postcss-minify-params: "npm:^7.0.2" - postcss-minify-selectors: "npm:^7.0.3" + postcss-minify-selectors: "npm:^7.0.4" postcss-normalize-charset: "npm:^7.0.0" postcss-normalize-display-values: "npm:^7.0.0" postcss-normalize-positions: "npm:^7.0.0" @@ -6750,10 +6750,10 @@ __metadata: postcss-reduce-initial: "npm:^7.0.2" postcss-reduce-transforms: "npm:^7.0.0" postcss-svgo: "npm:^7.0.1" - postcss-unique-selectors: "npm:^7.0.2" + postcss-unique-selectors: "npm:^7.0.3" peerDependencies: postcss: ^8.4.31 - checksum: 10c0/ffa7c6fa16c6ad98b7732fc563de74d492e6ad6d243a9f00431c0cbdbc576bcd49226d2695d881465d32dea0a2916add40ac10e7560dd7b5de9fd0fa25ee081b + checksum: 10c0/5c827a9f6b35475267af0512d55f569994b8334eb06565498daa2070ef52f0cdd2013f5efc1cbc0b4664370f491b0080f93c8ee56a7730d38fdf451fb65b030c languageName: node linkType: hard @@ -6767,14 +6767,14 @@ __metadata: linkType: hard "cssnano@npm:^7.0.0": - version: 7.0.5 - resolution: "cssnano@npm:7.0.5" + version: 7.0.6 + resolution: "cssnano@npm:7.0.6" dependencies: - cssnano-preset-default: "npm:^7.0.5" + cssnano-preset-default: "npm:^7.0.6" lilconfig: "npm:^3.1.2" peerDependencies: postcss: ^8.4.31 - checksum: 10c0/cb43ed964787dca33efb44d8f4fea8a49c495db44d1d12940493f0dd5d63db78e01c5b140fe42b480b332733602a25f4c85186d00977eb3070b29f7422761985 + checksum: 10c0/19ff09931a1531e7c0c0d8928da554d99213aa0bb1f3b93cc6b4987727d60a8cd5537b113a5cf4f95cc1db65bba3f2b35476bd63bb57e7469d4eab73e07d736d languageName: node linkType: hard @@ -13278,15 +13278,15 @@ __metadata: languageName: node linkType: hard -"postcss-calc@npm:^10.0.1": - version: 10.0.1 - resolution: "postcss-calc@npm:10.0.1" +"postcss-calc@npm:^10.0.2": + version: 10.0.2 + resolution: "postcss-calc@npm:10.0.2" dependencies: - postcss-selector-parser: "npm:^6.1.1" + postcss-selector-parser: "npm:^6.1.2" postcss-value-parser: "npm:^4.2.0" peerDependencies: postcss: ^8.4.38 - checksum: 10c0/5e38cc6f082f87e82067497b41684410784223ecd3701bf52242ea9f2f467f1fad6b5a561f8aa3be307d89435b4060f58aeb27c4064003586daf653cc4d91fef + checksum: 10c0/f57c9db7a7a2f3a0cdf45990089c051248d995bb2b9d1bd1fcd1634507851e92ea85bbc71a3594e359e9e9287ba0a820c90d6d292126a4b735cda364a86ce9cf languageName: node linkType: hard @@ -13354,15 +13354,15 @@ __metadata: languageName: node linkType: hard -"postcss-convert-values@npm:^7.0.3": - version: 7.0.3 - resolution: "postcss-convert-values@npm:7.0.3" +"postcss-convert-values@npm:^7.0.4": + version: 7.0.4 + resolution: "postcss-convert-values@npm:7.0.4" dependencies: browserslist: "npm:^4.23.3" postcss-value-parser: "npm:^4.2.0" peerDependencies: postcss: ^8.4.31 - checksum: 10c0/dbb6278bd8d8b11e448933d823426c883bff3f6abeaa23c7530cc4668b9da6f714e073840f280273f8a14022c3a99eb461ec732f7539e062b32f5281e1be6526 + checksum: 10c0/9839b29f7c638672115c9fef5ed7df016aa43ea9dd42a4a2ace16e6a49c75246d2c19f3e03a6409ed3bc7c2fa4de6203bf5789cef8268c76618326b68e3bc591 languageName: node linkType: hard @@ -13420,14 +13420,14 @@ __metadata: languageName: node linkType: hard -"postcss-discard-comments@npm:^7.0.2": - version: 7.0.2 - resolution: "postcss-discard-comments@npm:7.0.2" +"postcss-discard-comments@npm:^7.0.3": + version: 7.0.3 + resolution: "postcss-discard-comments@npm:7.0.3" dependencies: - postcss-selector-parser: "npm:^6.1.1" + postcss-selector-parser: "npm:^6.1.2" peerDependencies: postcss: ^8.4.31 - checksum: 10c0/c01632e643b6ec1f61ad59efe06a9e8dfc7fcedeb1551ae48fc33fa801353f6222e31954286cd97171c694f34c2b4c7f7a2213fd0f913e37c34d0353258ed234 + checksum: 10c0/7700c8fb9a83c6ea5cc784267b9afd6e2968fda0358d583af5913baa28dfc91b0f2a4bd0b2bd62a86ebcb8dadb2547e287beae25b5a097e21c1f723367ccf112 languageName: node linkType: hard @@ -13572,29 +13572,29 @@ __metadata: languageName: node linkType: hard -"postcss-merge-longhand@npm:^7.0.3": - version: 7.0.3 - resolution: "postcss-merge-longhand@npm:7.0.3" +"postcss-merge-longhand@npm:^7.0.4": + version: 7.0.4 + resolution: "postcss-merge-longhand@npm:7.0.4" dependencies: postcss-value-parser: "npm:^4.2.0" - stylehacks: "npm:^7.0.3" + stylehacks: "npm:^7.0.4" peerDependencies: postcss: ^8.4.31 - checksum: 10c0/b968c3d16f3edc6075b20219a1165c089dc454a6a42951dcdfc94adb932fb96ef7bcd465c6cd21b0e5b55ac08921355ddbbbc7cdcf87a345e4bef8b3cdd2e7e9 + checksum: 10c0/6f50f7775dd361f83daf1acb3e0001d700ed2b7b9bea02df172143adc7fa196ce9209c9e482010ce36fd704512433b62692c5ab2eef5226db71ea3e694654dc7 languageName: node linkType: hard -"postcss-merge-rules@npm:^7.0.3": - version: 7.0.3 - resolution: "postcss-merge-rules@npm:7.0.3" +"postcss-merge-rules@npm:^7.0.4": + version: 7.0.4 + resolution: "postcss-merge-rules@npm:7.0.4" dependencies: browserslist: "npm:^4.23.3" caniuse-api: "npm:^3.0.0" cssnano-utils: "npm:^5.0.0" - postcss-selector-parser: "npm:^6.1.1" + postcss-selector-parser: "npm:^6.1.2" peerDependencies: postcss: ^8.4.31 - checksum: 10c0/3cd20484ab6d15c62eded408248d5eeaba52a573935943f933865680e070a0e75b3a7447802c575bc86e1fae667cf51d9d5766537835d9b8c090337b5adf928e + checksum: 10c0/fffdcef4ada68e92ab8e6dc34a3b9aa2b87188cd4d08f5ba0ff2aff7e3e3c7f086830748ff64db091b5ccb9ac59ac37cfaab1268ed3efb50ab9c4f3714eb5f6d languageName: node linkType: hard @@ -13635,15 +13635,15 @@ __metadata: languageName: node linkType: hard -"postcss-minify-selectors@npm:^7.0.3": - version: 7.0.3 - resolution: "postcss-minify-selectors@npm:7.0.3" +"postcss-minify-selectors@npm:^7.0.4": + version: 7.0.4 + resolution: "postcss-minify-selectors@npm:7.0.4" dependencies: cssesc: "npm:^3.0.0" - postcss-selector-parser: "npm:^6.1.1" + postcss-selector-parser: "npm:^6.1.2" peerDependencies: postcss: ^8.4.31 - checksum: 10c0/5211f63a1672f646a1bab57bd8eac0816d42adacb5e286ad5e6e342a795bb0d086bd6044a1b338311ca28f33f2c1833165ee611eaa671287379821ba3c5d68ad + checksum: 10c0/212b8f3d62eb2a27ed57d4e76b75b0886806ddb9e2497c0bb79308fa75dabaaaa4ed2b97734896e87603272d05231fd74aee2c256a48d77aa468b5b64cc7866a languageName: node linkType: hard @@ -14004,7 +14004,7 @@ __metadata: languageName: node linkType: hard -"postcss-selector-parser@npm:^6.0.13, postcss-selector-parser@npm:^6.0.2, postcss-selector-parser@npm:^6.0.4, postcss-selector-parser@npm:^6.1.0, postcss-selector-parser@npm:^6.1.1, postcss-selector-parser@npm:^6.1.2": +"postcss-selector-parser@npm:^6.0.13, postcss-selector-parser@npm:^6.0.2, postcss-selector-parser@npm:^6.0.4, postcss-selector-parser@npm:^6.1.0, postcss-selector-parser@npm:^6.1.2": version: 6.1.2 resolution: "postcss-selector-parser@npm:6.1.2" dependencies: @@ -14026,14 +14026,14 @@ __metadata: languageName: node linkType: hard -"postcss-unique-selectors@npm:^7.0.2": - version: 7.0.2 - resolution: "postcss-unique-selectors@npm:7.0.2" +"postcss-unique-selectors@npm:^7.0.3": + version: 7.0.3 + resolution: "postcss-unique-selectors@npm:7.0.3" dependencies: - postcss-selector-parser: "npm:^6.1.1" + postcss-selector-parser: "npm:^6.1.2" peerDependencies: postcss: ^8.4.31 - checksum: 10c0/cc54c57cd1c5a6e3e166ec63cc036d9e2df80b05e508d9ce754ca4193bf8c1bfcc16b3c6f0d81b8352a3282201d249b90bb87abacfcfb9065c9e3705ea5d110e + checksum: 10c0/2eb90eb0745d1e29d411ea5108f1cd9737de5b8f739cabc717074872bc4015950c9963f870b23b33b9ef45e7887eecfe5560cffee56616d4e0b8d0fac4f7cb10 languageName: node linkType: hard @@ -16551,15 +16551,15 @@ __metadata: languageName: node linkType: hard -"stylehacks@npm:^7.0.3": - version: 7.0.3 - resolution: "stylehacks@npm:7.0.3" +"stylehacks@npm:^7.0.4": + version: 7.0.4 + resolution: "stylehacks@npm:7.0.4" dependencies: browserslist: "npm:^4.23.3" - postcss-selector-parser: "npm:^6.1.1" + postcss-selector-parser: "npm:^6.1.2" peerDependencies: postcss: ^8.4.31 - checksum: 10c0/5030334b06ef705b5700444dab120b540b09159e935e75b60f25bd56db1d85f0d11755f0b0f64ce3f12c5a72ff1b6f57fea49c26d18eb0de2334d6a143b94f8d + checksum: 10c0/b4d0b280ba274503ecc04111cc11c713e0d65db079fbcd8b42d6350be1cca20e28611eddee93b419aa208176a0d3a5fff83d83ef958d1876713809b6a2787c0c languageName: node linkType: hard From 8fd3e37747b6cdde100bae33ac5d84f3255c24ce Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Thu, 5 Sep 2024 06:20:27 -0400 Subject: [PATCH 116/153] Update `parser` and `rubocop` gems (#31760) --- .rubocop_todo.yml | 5 +---- Gemfile.lock | 13 +++++-------- 2 files changed, 6 insertions(+), 12 deletions(-) diff --git a/.rubocop_todo.yml b/.rubocop_todo.yml index 09acb795bf..a6e51d6aee 100644 --- a/.rubocop_todo.yml +++ b/.rubocop_todo.yml @@ -1,6 +1,6 @@ # This configuration was generated by # `rubocop --auto-gen-config --auto-gen-only-exclude --no-offense-counts --no-auto-gen-timestamp` -# using RuboCop version 1.65.0. +# using RuboCop version 1.66.1. # The point is for the user to remove these configuration records # one by one as the offenses are removed from the code base. # Note that changes in the inspected code, or installation of new @@ -35,7 +35,6 @@ Rails/OutputSafety: # Configuration parameters: AllowedVars. Style/FetchEnvVar: Exclude: - - 'app/lib/redis_configuration.rb' - 'app/lib/translation_service.rb' - 'config/environments/production.rb' - 'config/initializers/2_limited_federation_mode.rb' @@ -44,7 +43,6 @@ Style/FetchEnvVar: - 'config/initializers/devise.rb' - 'config/initializers/paperclip.rb' - 'config/initializers/vapid.rb' - - 'lib/mastodon/redis_config.rb' - 'lib/tasks/repo.rake' # This cop supports safe autocorrection (--autocorrect). @@ -93,7 +91,6 @@ Style/OptionalBooleanParameter: - 'app/services/fetch_resource_service.rb' - 'app/workers/domain_block_worker.rb' - 'app/workers/unfollow_follow_worker.rb' - - 'lib/mastodon/redis_config.rb' # This cop supports unsafe autocorrection (--autocorrect-all). # Configuration parameters: EnforcedStyle. diff --git a/Gemfile.lock b/Gemfile.lock index a533b66241..c70823d051 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -584,7 +584,7 @@ GEM ostruct (0.6.0) ox (2.14.18) parallel (1.26.3) - parser (3.3.4.2) + parser (3.3.5.0) ast (~> 2.4.1) racc parslet (2.0.0) @@ -698,8 +698,7 @@ GEM responders (3.1.1) actionpack (>= 5.2) railties (>= 5.2) - rexml (3.3.6) - strscan + rexml (3.3.7) rotp (6.3.0) rouge (4.3.0) rpam2 (4.0.2) @@ -735,18 +734,17 @@ GEM rspec-mocks (~> 3.0) sidekiq (>= 5, < 8) rspec-support (3.13.1) - rubocop (1.65.1) + rubocop (1.66.1) json (~> 2.3) language_server-protocol (>= 3.17.0) parallel (~> 1.10) parser (>= 3.3.0.2) rainbow (>= 2.2.2, < 4.0) regexp_parser (>= 2.4, < 3.0) - rexml (>= 3.2.5, < 4.0) - rubocop-ast (>= 1.31.1, < 2.0) + rubocop-ast (>= 1.32.2, < 2.0) ruby-progressbar (~> 1.7) unicode-display_width (>= 2.4.0, < 3.0) - rubocop-ast (1.32.1) + rubocop-ast (1.32.3) parser (>= 3.3.1.0) rubocop-capybara (2.21.0) rubocop (~> 1.41) @@ -826,7 +824,6 @@ GEM stringio (3.1.1) strong_migrations (2.0.0) activerecord (>= 6.1) - strscan (3.1.0) swd (1.3.0) activesupport (>= 3) attr_required (>= 0.0.5) From 5b1ae15a368aa800fd045d6e3b6a7500c7196889 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Thu, 5 Sep 2024 13:06:05 +0200 Subject: [PATCH 117/153] Update docker.io/ruby Docker tag to v3.3.5 (#31758) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index cd555f7027..c7c02d9b46 100644 --- a/Dockerfile +++ b/Dockerfile @@ -12,7 +12,7 @@ ARG BUILDPLATFORM=${BUILDPLATFORM} # Ruby image to use for base image, change with [--build-arg RUBY_VERSION="3.3.x"] # renovate: datasource=docker depName=docker.io/ruby -ARG RUBY_VERSION="3.3.4" +ARG RUBY_VERSION="3.3.5" # # Node version to use in base image, change with [--build-arg NODE_MAJOR_VERSION="20"] # renovate: datasource=node-version depName=node ARG NODE_MAJOR_VERSION="20" From e820cc30b8798c1d9e30d4e780c511b5ab395345 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Thu, 5 Sep 2024 07:54:27 -0400 Subject: [PATCH 118/153] Convert invites controller spec to system/request specs (#31755) --- app/views/invites/_invite.html.haml | 2 +- spec/controllers/invites_controller_spec.rb | 84 ------------------ spec/requests/invites_spec.rb | 31 +++++++ .../support/matchers/private_cache_control.rb | 14 +++ spec/system/invites_spec.rb | 86 +++++++++++++++++++ spec/system/tags_spec.rb | 3 + 6 files changed, 135 insertions(+), 85 deletions(-) delete mode 100644 spec/controllers/invites_controller_spec.rb create mode 100644 spec/requests/invites_spec.rb create mode 100644 spec/support/matchers/private_cache_control.rb create mode 100644 spec/system/invites_spec.rb diff --git a/app/views/invites/_invite.html.haml b/app/views/invites/_invite.html.haml index 94e1a71125..892fdc5a0e 100644 --- a/app/views/invites/_invite.html.haml +++ b/app/views/invites/_invite.html.haml @@ -1,4 +1,4 @@ -%tr +%tr{ id: dom_id(invite) } %td .input-copy .input-copy__wrapper diff --git a/spec/controllers/invites_controller_spec.rb b/spec/controllers/invites_controller_spec.rb deleted file mode 100644 index 192c5b00ba..0000000000 --- a/spec/controllers/invites_controller_spec.rb +++ /dev/null @@ -1,84 +0,0 @@ -# frozen_string_literal: true - -require 'rails_helper' - -RSpec.describe InvitesController do - render_views - - let(:user) { Fabricate(:user) } - - before do - sign_in user - end - - describe 'GET #index' do - before do - Fabricate(:invite, user: user) - end - - context 'when everyone can invite' do - before do - UserRole.everyone.update(permissions: UserRole.everyone.permissions | UserRole::FLAGS[:invite_users]) - get :index - end - - it 'returns http success' do - expect(response).to have_http_status(:success) - end - - it 'returns private cache control headers' do - expect(response.headers['Cache-Control']).to include('private, no-store') - end - end - - context 'when not everyone can invite' do - before do - UserRole.everyone.update(permissions: UserRole.everyone.permissions & ~UserRole::FLAGS[:invite_users]) - get :index - end - - it 'returns http forbidden' do - expect(response).to have_http_status(403) - end - end - end - - describe 'POST #create' do - subject { post :create, params: { invite: { max_uses: '10', expires_in: 1800 } } } - - context 'when everyone can invite' do - before do - UserRole.everyone.update(permissions: UserRole.everyone.permissions | UserRole::FLAGS[:invite_users]) - end - - it 'succeeds to create a invite' do - expect { subject }.to change(Invite, :count).by(1) - expect(subject).to redirect_to invites_path - expect(Invite.last).to have_attributes(user_id: user.id, max_uses: 10) - end - end - - context 'when not everyone can invite' do - before do - UserRole.everyone.update(permissions: UserRole.everyone.permissions & ~UserRole::FLAGS[:invite_users]) - end - - it 'returns http forbidden' do - expect(subject).to have_http_status(403) - end - end - end - - describe 'DELETE #destroy' do - subject { delete :destroy, params: { id: invite.id } } - - let(:invite) { Fabricate(:invite, user: user, expires_at: nil) } - - it 'expires invite and redirects' do - expect { subject } - .to(change { invite.reload.expired? }.to(true)) - expect(response) - .to redirect_to invites_path - end - end -end diff --git a/spec/requests/invites_spec.rb b/spec/requests/invites_spec.rb new file mode 100644 index 0000000000..8a5ad2ccd1 --- /dev/null +++ b/spec/requests/invites_spec.rb @@ -0,0 +1,31 @@ +# frozen_string_literal: true + +require 'rails_helper' + +RSpec.describe 'Invites' do + let(:user) { Fabricate(:user) } + + before { sign_in user } + + context 'when not everyone can invite' do + before { UserRole.everyone.update(permissions: UserRole.everyone.permissions & ~UserRole::FLAGS[:invite_users]) } + + describe 'GET /invites' do + it 'returns http forbidden' do + get invites_path + + expect(response) + .to have_http_status(403) + end + end + + describe 'POST /invites' do + it 'returns http forbidden' do + post invites_path, params: { invite: { max_users: '10', expires_in: 1800 } } + + expect(response) + .to have_http_status(403) + end + end + end +end diff --git a/spec/support/matchers/private_cache_control.rb b/spec/support/matchers/private_cache_control.rb new file mode 100644 index 0000000000..7fcf56be3e --- /dev/null +++ b/spec/support/matchers/private_cache_control.rb @@ -0,0 +1,14 @@ +# frozen_string_literal: true + +RSpec::Matchers.define :have_private_cache_control do + match do |page| + page.response_headers['Cache-Control'] == 'private, no-store' + end + + failure_message do |page| + <<~ERROR + Expected page to have `Cache-Control` header with `private, no-store` but it has: + #{page.response_headers['Cache-Control']} + ERROR + end +end diff --git a/spec/system/invites_spec.rb b/spec/system/invites_spec.rb new file mode 100644 index 0000000000..648bbea825 --- /dev/null +++ b/spec/system/invites_spec.rb @@ -0,0 +1,86 @@ +# frozen_string_literal: true + +require 'rails_helper' + +RSpec.describe 'Invites' do + include ActionView::RecordIdentifier + + let(:user) { Fabricate :user } + + before do + host! 'localhost:3000' # TODO: Move into before for all system specs? + sign_in user + end + + describe 'Viewing invites' do + it 'Lists existing user invites' do + invite = Fabricate :invite, user: user + + visit invites_path + + within css_id(invite) do + expect(page) + .to have_content(invite.uses) + .and have_private_cache_control + expect(copyable_field.value) + .to eq(public_invite_url(invite_code: invite.code)) + end + end + end + + describe 'Creating a new invite' do + it 'Saves the invite for the user' do + visit invites_path + + fill_invite_form + + expect { submit_form } + .to change(user.invites, :count).by(1) + end + end + + describe 'Deleting an existing invite' do + it 'Expires the invite' do + invite = Fabricate :invite, user: user + + visit invites_path + + expect { delete_invite(invite) } + .to change { invite.reload.expired? }.to(true) + + within css_id(invite) do + expect(page).to have_content I18n.t('invites.expired') + end + end + end + + private + + def css_id(record) + "##{dom_id(record)}" # TODO: Extract to system spec helper? + end + + def copyable_field + within '.input-copy' do + find(:field, type: :text, readonly: true) + end + end + + def submit_form + click_on I18n.t('invites.generate') + end + + def delete_invite(invite) + within css_id(invite) do + click_on I18n.t('invites.delete') + end + end + + def fill_invite_form + select I18n.t('invites.max_uses', count: 100), + from: I18n.t('simple_form.labels.defaults.max_uses') + select I18n.t("invites.expires_in.#{30.minutes.to_i}"), + from: I18n.t('simple_form.labels.defaults.expires_in') + check I18n.t('simple_form.labels.defaults.autofollow') + end +end diff --git a/spec/system/tags_spec.rb b/spec/system/tags_spec.rb index e9ad970a54..f39c6bf0d8 100644 --- a/spec/system/tags_spec.rb +++ b/spec/system/tags_spec.rb @@ -6,11 +6,14 @@ RSpec.describe 'Tags' do describe 'Viewing a tag' do let(:tag) { Fabricate(:tag, name: 'test') } + before { sign_in Fabricate(:user) } + it 'visits the tag page and renders the web app' do visit tag_path(tag) expect(page) .to have_css('noscript', text: /Mastodon/) + .and have_private_cache_control end end end From b4b639ee4a059385874f143027b75516c8db17d9 Mon Sep 17 00:00:00 2001 From: Michael Stanclift Date: Thu, 5 Sep 2024 07:34:13 -0500 Subject: [PATCH 119/153] Fix radio checkbox visibility in Report dialogs (#31752) --- app/javascript/styles/mastodon/components.scss | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/app/javascript/styles/mastodon/components.scss b/app/javascript/styles/mastodon/components.scss index 2fc195a3bd..5936ef8a64 100644 --- a/app/javascript/styles/mastodon/components.scss +++ b/app/javascript/styles/mastodon/components.scss @@ -6437,7 +6437,7 @@ a.status-card { } .dialog-option .poll__input { - border-color: $inverted-text-color; + border-color: $darker-text-color; color: $ui-secondary-color; display: inline-flex; align-items: center; @@ -6451,13 +6451,13 @@ a.status-card { &:active, &:focus, &:hover { - border-color: lighten($inverted-text-color, 15%); + border-color: $valid-value-color; border-width: 4px; } &.active { - border-color: $inverted-text-color; - background: $inverted-text-color; + border-color: $valid-value-color; + background: $valid-value-color; } } From f85694acfdaf57c113bba49ca2aef949b16d4141 Mon Sep 17 00:00:00 2001 From: David Roetzel Date: Thu, 5 Sep 2024 16:06:58 +0200 Subject: [PATCH 120/153] Add credentials to redis sentinel configuration (#31768) --- lib/mastodon/redis_configuration.rb | 45 ++++++++++++------- spec/lib/mastodon/redis_configuration_spec.rb | 23 +++++++--- 2 files changed, 45 insertions(+), 23 deletions(-) diff --git a/lib/mastodon/redis_configuration.rb b/lib/mastodon/redis_configuration.rb index 5a096a1bf2..3d739a2ac6 100644 --- a/lib/mastodon/redis_configuration.rb +++ b/lib/mastodon/redis_configuration.rb @@ -57,39 +57,50 @@ class Mastodon::RedisConfiguration def setup_config(prefix: nil, defaults: {}) prefix = "#{prefix}REDIS_" - url = ENV.fetch("#{prefix}URL", nil) - user = ENV.fetch("#{prefix}USER", nil) - password = ENV.fetch("#{prefix}PASSWORD", nil) - host = ENV.fetch("#{prefix}HOST", defaults[:host]) - port = ENV.fetch("#{prefix}PORT", defaults[:port]) - db = ENV.fetch("#{prefix}DB", defaults[:db]) - name = ENV.fetch("#{prefix}SENTINEL_MASTER", nil) - sentinel_port = ENV.fetch("#{prefix}SENTINEL_PORT", 26_379) - sentinel_list = ENV.fetch("#{prefix}SENTINELS", nil) + url = ENV.fetch("#{prefix}URL", nil) + user = ENV.fetch("#{prefix}USER", nil) + password = ENV.fetch("#{prefix}PASSWORD", nil) + host = ENV.fetch("#{prefix}HOST", defaults[:host]) + port = ENV.fetch("#{prefix}PORT", defaults[:port]) + db = ENV.fetch("#{prefix}DB", defaults[:db]) return { url:, driver: } if url - sentinels = parse_sentinels(sentinel_list, default_port: sentinel_port) + sentinel_options = setup_sentinels(prefix, default_user: user, default_password: password) - if name.present? && sentinels.present? - host = name + if sentinel_options.present? + host = sentinel_options[:name] port = nil db ||= 0 - else - sentinels = nil end url = construct_uri(host, port, db, user, password) if url.present? - { url:, driver:, name:, sentinels: } + { url:, driver: }.merge(sentinel_options) else - # Fall back to base config. This has defaults for the URL - # so this cannot lead to an endless loop. + # Fall back to base config, which has defaults for the URL + # so this cannot lead to endless recursion. base end end + def setup_sentinels(prefix, default_user: nil, default_password: nil) + name = ENV.fetch("#{prefix}SENTINEL_MASTER", nil) + sentinel_port = ENV.fetch("#{prefix}SENTINEL_PORT", 26_379) + sentinel_list = ENV.fetch("#{prefix}SENTINELS", nil) + sentinel_username = ENV.fetch("#{prefix}SENTINEL_USERNAME", default_user) + sentinel_password = ENV.fetch("#{prefix}SENTINEL_PASSWORD", default_password) + + sentinels = parse_sentinels(sentinel_list, default_port: sentinel_port) + + if name.present? && sentinels.present? + { name:, sentinels:, sentinel_username:, sentinel_password: } + else + {} + end + end + def construct_uri(host, port, db, user, password) return nil if host.blank? diff --git a/spec/lib/mastodon/redis_configuration_spec.rb b/spec/lib/mastodon/redis_configuration_spec.rb index d14adf9518..e36dcfba0a 100644 --- a/spec/lib/mastodon/redis_configuration_spec.rb +++ b/spec/lib/mastodon/redis_configuration_spec.rb @@ -100,10 +100,27 @@ RSpec.describe Mastodon::RedisConfiguration do expect(subject[:url]).to eq 'redis://:testpass1@mainsentinel/0' end + it 'uses the redis password to authenticate with sentinels' do + expect(subject[:sentinel_password]).to eq 'testpass1' + end + it 'includes the sentinel master name and list of sentinels' do expect(subject[:name]).to eq 'mainsentinel' expect(subject[:sentinels]).to contain_exactly({ host: '192.168.0.1', port: 3000 }, { host: '192.168.0.2', port: 4000 }) end + + context "when giving dedicated credentials in `#{prefix}REDIS_SENTINEL_USERNAME` and `#{prefix}REDIS_SENTINEL_PASSWORD`" do + around do |example| + ClimateControl.modify "#{prefix}REDIS_SENTINEL_USERNAME": 'sentinel_user', "#{prefix}REDIS_SENTINEL_PASSWORD": 'sentinel_pass1' do + example.run + end + end + + it 'uses the credential to authenticate with sentinels' do + expect(subject[:sentinel_username]).to eq 'sentinel_user' + expect(subject[:sentinel_password]).to eq 'sentinel_pass1' + end + end end context 'when giving sentinels without port numbers' do @@ -154,8 +171,6 @@ RSpec.describe Mastodon::RedisConfiguration do url: 'redis://localhost:6379/0', driver: :hiredis, namespace: nil, - name: nil, - sentinels: nil, }) end end @@ -188,8 +203,6 @@ RSpec.describe Mastodon::RedisConfiguration do url: 'redis://:testpass@redis.example.com:3333/3', driver: :hiredis, namespace: nil, - name: nil, - sentinels: nil, }) end end @@ -218,8 +231,6 @@ RSpec.describe Mastodon::RedisConfiguration do namespace: 'cache', expires_in: 10.minutes, connect_timeout: 5, - name: nil, - sentinels: nil, pool: { size: 5, timeout: 5, From d58faa20181c95b82ace744494a683b81eea681a Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Thu, 5 Sep 2024 10:07:17 -0400 Subject: [PATCH 121/153] Remove references to deprecated `Import` model (#31759) --- app/views/settings/imports/index.html.haml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/settings/imports/index.html.haml b/app/views/settings/imports/index.html.haml index bfddd45460..634631b5aa 100644 --- a/app/views/settings/imports/index.html.haml +++ b/app/views/settings/imports/index.html.haml @@ -23,7 +23,7 @@ = f.input :mode, as: :radio_buttons, collection_wrapper_tag: 'ul', - collection: Import::MODES, + collection: Form::Import::MODES, item_wrapper_tag: 'li', label_method: ->(mode) { safe_join([I18n.t("imports.modes.#{mode}"), content_tag(:span, I18n.t("imports.modes.#{mode}_long"), class: 'hint')]) } From 850478dc140f16d407ade46f791e08f3ceb4bf2e Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Thu, 5 Sep 2024 10:41:14 -0400 Subject: [PATCH 122/153] Use `conflicted` configuration for renovate rebase strategy (#31770) --- .github/renovate.json5 | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/renovate.json5 b/.github/renovate.json5 index 968c77cac2..8a10676283 100644 --- a/.github/renovate.json5 +++ b/.github/renovate.json5 @@ -7,6 +7,7 @@ ':prConcurrentLimitNone', // Remove limit for open PRs at any time. ':prHourlyLimit2', // Rate limit PR creation to a maximum of two per hour. ], + rebaseWhen: 'conflicted', minimumReleaseAge: '3', // Wait 3 days after the package has been published before upgrading it // packageRules order is important, they are applied from top to bottom and are merged, // meaning the most important ones must be at the bottom, for example grouping rules From bc435c63bd99df757d02737674ca2f39aca49438 Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Thu, 5 Sep 2024 16:57:53 +0200 Subject: [PATCH 123/153] Change width of columns in advanced web UI (#31762) --- app/javascript/styles/mastodon/components.scss | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/javascript/styles/mastodon/components.scss b/app/javascript/styles/mastodon/components.scss index 5936ef8a64..0b7c9ac903 100644 --- a/app/javascript/styles/mastodon/components.scss +++ b/app/javascript/styles/mastodon/components.scss @@ -2789,7 +2789,7 @@ $ui-header-logo-wordmark-width: 99px; } .column { - width: 350px; + width: 400px; position: relative; box-sizing: border-box; display: flex; @@ -2822,7 +2822,7 @@ $ui-header-logo-wordmark-width: 99px; } .drawer { - width: 300px; + width: 350px; box-sizing: border-box; display: flex; flex-direction: column; From 5acec087caed4a2fdf0fd8ed11f891222496f321 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Thu, 5 Sep 2024 11:36:05 -0400 Subject: [PATCH 124/153] Simplify basic presence validations (#29664) --- spec/models/announcement_spec.rb | 9 +----- spec/models/block_spec.rb | 13 ++------- spec/models/custom_emoji_category_spec.rb | 7 +---- spec/models/custom_filter_spec.rb | 15 ++-------- spec/models/domain_allow_spec.rb | 6 +--- spec/models/domain_block_spec.rb | 6 +--- spec/models/follow_spec.rb | 13 ++------- spec/models/import_spec.rb | 17 ++--------- spec/models/ip_block_spec.rb | 15 ++-------- spec/models/marker_spec.rb | 11 ++----- spec/models/media_attachment_spec.rb | 7 +---- spec/models/mention_spec.rb | 13 ++------- spec/models/poll_spec.rb | 7 ++--- spec/models/user_spec.rb | 6 +--- spec/models/webauthn_credential_spec.rb | 35 +++-------------------- spec/models/webhook_spec.rb | 7 +---- 16 files changed, 28 insertions(+), 159 deletions(-) diff --git a/spec/models/announcement_spec.rb b/spec/models/announcement_spec.rb index e3865e6fc7..8bd1e74b29 100644 --- a/spec/models/announcement_spec.rb +++ b/spec/models/announcement_spec.rb @@ -64,14 +64,7 @@ RSpec.describe Announcement do end describe 'Validations' do - describe 'text' do - it 'validates presence of attribute' do - record = Fabricate.build(:announcement, text: nil) - - expect(record).to_not be_valid - expect(record.errors[:text]).to be_present - end - end + it { is_expected.to validate_presence_of(:text) } describe 'ends_at' do it 'validates presence when starts_at is present' do diff --git a/spec/models/block_spec.rb b/spec/models/block_spec.rb index 8249503c59..84f0f318f4 100644 --- a/spec/models/block_spec.rb +++ b/spec/models/block_spec.rb @@ -4,17 +4,8 @@ require 'rails_helper' RSpec.describe Block do describe 'validations' do - it 'is invalid without an account' do - block = Fabricate.build(:block, account: nil) - block.valid? - expect(block).to model_have_error_on_field(:account) - end - - it 'is invalid without a target_account' do - block = Fabricate.build(:block, target_account: nil) - block.valid? - expect(block).to model_have_error_on_field(:target_account) - end + it { is_expected.to belong_to(:account).required } + it { is_expected.to belong_to(:target_account).required } end it 'removes blocking cache after creation' do diff --git a/spec/models/custom_emoji_category_spec.rb b/spec/models/custom_emoji_category_spec.rb index 3da77344e2..2b414a66ee 100644 --- a/spec/models/custom_emoji_category_spec.rb +++ b/spec/models/custom_emoji_category_spec.rb @@ -4,11 +4,6 @@ require 'rails_helper' RSpec.describe CustomEmojiCategory do describe 'validations' do - it 'validates name presence' do - record = described_class.new(name: nil) - - expect(record).to_not be_valid - expect(record).to model_have_error_on_field(:name) - end + it { is_expected.to validate_presence_of(:name) } end end diff --git a/spec/models/custom_filter_spec.rb b/spec/models/custom_filter_spec.rb index 5bb615bb37..afbc420241 100644 --- a/spec/models/custom_filter_spec.rb +++ b/spec/models/custom_filter_spec.rb @@ -4,19 +4,8 @@ require 'rails_helper' RSpec.describe CustomFilter do describe 'Validations' do - it 'requires presence of title' do - record = described_class.new(title: '') - record.valid? - - expect(record).to model_have_error_on_field(:title) - end - - it 'requires presence of context' do - record = described_class.new(context: nil) - record.valid? - - expect(record).to model_have_error_on_field(:context) - end + it { is_expected.to validate_presence_of(:title) } + it { is_expected.to validate_presence_of(:context) } it 'requires non-empty of context' do record = described_class.new(context: []) diff --git a/spec/models/domain_allow_spec.rb b/spec/models/domain_allow_spec.rb index 92f1ef8ccf..d8f438f07e 100644 --- a/spec/models/domain_allow_spec.rb +++ b/spec/models/domain_allow_spec.rb @@ -4,11 +4,7 @@ require 'rails_helper' RSpec.describe DomainAllow do describe 'Validations' do - it 'is invalid without a domain' do - domain_allow = Fabricate.build(:domain_allow, domain: nil) - domain_allow.valid? - expect(domain_allow).to model_have_error_on_field(:domain) - end + it { is_expected.to validate_presence_of(:domain) } it 'is invalid if the same normalized domain already exists' do _domain_allow = Fabricate(:domain_allow, domain: 'にゃん') diff --git a/spec/models/domain_block_spec.rb b/spec/models/domain_block_spec.rb index d595441fd3..8278454cd7 100644 --- a/spec/models/domain_block_spec.rb +++ b/spec/models/domain_block_spec.rb @@ -4,11 +4,7 @@ require 'rails_helper' RSpec.describe DomainBlock do describe 'validations' do - it 'is invalid without a domain' do - domain_block = Fabricate.build(:domain_block, domain: nil) - domain_block.valid? - expect(domain_block).to model_have_error_on_field(:domain) - end + it { is_expected.to validate_presence_of(:domain) } it 'is invalid if the same normalized domain already exists' do _domain_block = Fabricate(:domain_block, domain: 'にゃん') diff --git a/spec/models/follow_spec.rb b/spec/models/follow_spec.rb index 9aa172b2f2..f22bd6ea88 100644 --- a/spec/models/follow_spec.rb +++ b/spec/models/follow_spec.rb @@ -9,17 +9,8 @@ RSpec.describe Follow do describe 'validations' do subject { described_class.new(account: alice, target_account: bob, rate_limit: true) } - it 'is invalid without an account' do - follow = Fabricate.build(:follow, account: nil) - follow.valid? - expect(follow).to model_have_error_on_field(:account) - end - - it 'is invalid without a target_account' do - follow = Fabricate.build(:follow, target_account: nil) - follow.valid? - expect(follow).to model_have_error_on_field(:target_account) - end + it { is_expected.to belong_to(:account).required } + it { is_expected.to belong_to(:target_account).required } it 'is invalid if account already follows too many people' do alice.update(following_count: FollowLimitValidator::LIMIT) diff --git a/spec/models/import_spec.rb b/spec/models/import_spec.rb index 10df5f8c0b..587e0a9d26 100644 --- a/spec/models/import_spec.rb +++ b/spec/models/import_spec.rb @@ -3,19 +3,8 @@ require 'rails_helper' RSpec.describe Import do - let(:account) { Fabricate(:account) } - let(:type) { 'following' } - let(:data) { attachment_fixture('imports.txt') } - - describe 'validations' do - it 'is invalid without an type' do - import = described_class.create(account: account, data: data) - expect(import).to model_have_error_on_field(:type) - end - - it 'is invalid without a data' do - import = described_class.create(account: account, type: type) - expect(import).to model_have_error_on_field(:data) - end + describe 'Validations' do + it { is_expected.to validate_presence_of(:type) } + it { is_expected.to validate_presence_of(:data) } end end diff --git a/spec/models/ip_block_spec.rb b/spec/models/ip_block_spec.rb index 6f1eb38425..ac9f5db601 100644 --- a/spec/models/ip_block_spec.rb +++ b/spec/models/ip_block_spec.rb @@ -4,19 +4,8 @@ require 'rails_helper' RSpec.describe IpBlock do describe 'validations' do - it 'validates ip presence', :aggregate_failures do - ip_block = described_class.new(ip: nil, severity: :no_access) - - expect(ip_block).to_not be_valid - expect(ip_block).to model_have_error_on_field(:ip) - end - - it 'validates severity presence', :aggregate_failures do - ip_block = described_class.new(ip: '127.0.0.1', severity: nil) - - expect(ip_block).to_not be_valid - expect(ip_block).to model_have_error_on_field(:severity) - end + it { is_expected.to validate_presence_of(:ip) } + it { is_expected.to validate_presence_of(:severity) } it 'validates ip uniqueness', :aggregate_failures do described_class.create!(ip: '127.0.0.1', severity: :no_access) diff --git a/spec/models/marker_spec.rb b/spec/models/marker_spec.rb index 8339f8e259..1da8eb6f43 100644 --- a/spec/models/marker_spec.rb +++ b/spec/models/marker_spec.rb @@ -3,14 +3,7 @@ require 'rails_helper' RSpec.describe Marker do - describe 'validations' do - describe 'timeline' do - it 'must be included in valid list' do - record = described_class.new(timeline: 'not real timeline') - - expect(record).to_not be_valid - expect(record).to model_have_error_on_field(:timeline) - end - end + describe 'Validations' do + it { is_expected.to validate_inclusion_of(:timeline).in_array(described_class::TIMELINES) } end end diff --git a/spec/models/media_attachment_spec.rb b/spec/models/media_attachment_spec.rb index 50f8d00a54..5f91ae0967 100644 --- a/spec/models/media_attachment_spec.rb +++ b/spec/models/media_attachment_spec.rb @@ -257,12 +257,7 @@ RSpec.describe MediaAttachment, :attachment_processing do end end - it 'is invalid without file' do - media = described_class.new - - expect(media.valid?).to be false - expect(media).to model_have_error_on_field(:file) - end + it { is_expected.to validate_presence_of(:file) } describe 'size limit validation' do it 'rejects video files that are too large' do diff --git a/spec/models/mention_spec.rb b/spec/models/mention_spec.rb index b241049a54..3a9b9fddf2 100644 --- a/spec/models/mention_spec.rb +++ b/spec/models/mention_spec.rb @@ -4,16 +4,7 @@ require 'rails_helper' RSpec.describe Mention do describe 'validations' do - it 'is invalid without an account' do - mention = Fabricate.build(:mention, account: nil) - mention.valid? - expect(mention).to model_have_error_on_field(:account) - end - - it 'is invalid without a status' do - mention = Fabricate.build(:mention, status: nil) - mention.valid? - expect(mention).to model_have_error_on_field(:status) - end + it { is_expected.to belong_to(:account).required } + it { is_expected.to belong_to(:status).required } end end diff --git a/spec/models/poll_spec.rb b/spec/models/poll_spec.rb index 740ef63d81..736f3615d0 100644 --- a/spec/models/poll_spec.rb +++ b/spec/models/poll_spec.rb @@ -32,12 +32,9 @@ RSpec.describe Poll do describe 'validations' do context 'when not valid' do - let(:poll) { Fabricate.build(:poll, expires_at: nil) } + subject { Fabricate.build(:poll) } - it 'is invalid without an expire date' do - poll.valid? - expect(poll).to model_have_error_on_field(:expires_at) - end + it { is_expected.to validate_presence_of(:expires_at) } end end end diff --git a/spec/models/user_spec.rb b/spec/models/user_spec.rb index 5c2af4dc39..fcff4c0d3b 100644 --- a/spec/models/user_spec.rb +++ b/spec/models/user_spec.rb @@ -32,11 +32,7 @@ RSpec.describe User do end describe 'validations' do - it 'is invalid without an account' do - user = Fabricate.build(:user, account: nil) - user.valid? - expect(user).to model_have_error_on_field(:account) - end + it { is_expected.to belong_to(:account).required } it 'is invalid without a valid email' do user = Fabricate.build(:user, email: 'john@') diff --git a/spec/models/webauthn_credential_spec.rb b/spec/models/webauthn_credential_spec.rb index 23f0229a67..c4105d9150 100644 --- a/spec/models/webauthn_credential_spec.rb +++ b/spec/models/webauthn_credential_spec.rb @@ -4,37 +4,10 @@ require 'rails_helper' RSpec.describe WebauthnCredential do describe 'validations' do - it 'is invalid without an external id' do - webauthn_credential = Fabricate.build(:webauthn_credential, external_id: nil) - - webauthn_credential.valid? - - expect(webauthn_credential).to model_have_error_on_field(:external_id) - end - - it 'is invalid without a public key' do - webauthn_credential = Fabricate.build(:webauthn_credential, public_key: nil) - - webauthn_credential.valid? - - expect(webauthn_credential).to model_have_error_on_field(:public_key) - end - - it 'is invalid without a nickname' do - webauthn_credential = Fabricate.build(:webauthn_credential, nickname: nil) - - webauthn_credential.valid? - - expect(webauthn_credential).to model_have_error_on_field(:nickname) - end - - it 'is invalid without a sign_count' do - webauthn_credential = Fabricate.build(:webauthn_credential, sign_count: nil) - - webauthn_credential.valid? - - expect(webauthn_credential).to model_have_error_on_field(:sign_count) - end + it { is_expected.to validate_presence_of(:external_id) } + it { is_expected.to validate_presence_of(:public_key) } + it { is_expected.to validate_presence_of(:nickname) } + it { is_expected.to validate_presence_of(:sign_count) } it 'is invalid if already exist a webauthn credential with the same external id' do Fabricate(:webauthn_credential, external_id: '_Typ0ygudDnk9YUVWLQayw') diff --git a/spec/models/webhook_spec.rb b/spec/models/webhook_spec.rb index 1b2d803bd7..03ef1dcc68 100644 --- a/spec/models/webhook_spec.rb +++ b/spec/models/webhook_spec.rb @@ -6,12 +6,7 @@ RSpec.describe Webhook do let(:webhook) { Fabricate(:webhook) } describe 'Validations' do - it 'requires presence of events' do - record = described_class.new(events: nil) - record.valid? - - expect(record).to model_have_error_on_field(:events) - end + it { is_expected.to validate_presence_of(:events) } it 'requires non-empty events value' do record = described_class.new(events: []) From cb324b5d7c6eba78aad28bfee1c806dc01517f2b Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Thu, 5 Sep 2024 11:39:59 +0200 Subject: [PATCH 125/153] [Glitch] Change design of unread conversations in web UI Port ec4c49082edb5f4941bd4e129900628c6b30101e to glitch-soc Signed-off-by: Claire --- .../components/conversation.jsx | 2 +- .../flavours/glitch/styles/components.scss | 19 ++----------------- 2 files changed, 3 insertions(+), 18 deletions(-) diff --git a/app/javascript/flavours/glitch/features/direct_timeline/components/conversation.jsx b/app/javascript/flavours/glitch/features/direct_timeline/components/conversation.jsx index 50b2a9d5ab..e7fc914b65 100644 --- a/app/javascript/flavours/glitch/features/direct_timeline/components/conversation.jsx +++ b/app/javascript/flavours/glitch/features/direct_timeline/components/conversation.jsx @@ -197,7 +197,7 @@ export const Conversation = ({ conversation, scrollKey, onMoveUp, onMoveDown }) return ( -
+
diff --git a/app/javascript/flavours/glitch/styles/components.scss b/app/javascript/flavours/glitch/styles/components.scss index 26be1f866c..c26ce0d62c 100644 --- a/app/javascript/flavours/glitch/styles/components.scss +++ b/app/javascript/flavours/glitch/styles/components.scss @@ -9055,22 +9055,6 @@ noscript { margin: 0; } } - - &--unread { - background: lighten($ui-base-color, 2%); - - &:focus { - background: lighten($ui-base-color, 4%); - } - - .conversation__content__info { - font-weight: 700; - } - - .conversation__content__relative-time { - color: $primary-text-color; - } - } } .announcements { @@ -9265,7 +9249,8 @@ noscript { } .notification, -.status__wrapper { +.status__wrapper, +.conversation { position: relative; &.unread { From db6b1fe8fb56c5eab4f11cc2cd79703739ca2608 Mon Sep 17 00:00:00 2001 From: Michael Stanclift Date: Thu, 5 Sep 2024 07:34:13 -0500 Subject: [PATCH 126/153] [Glitch] Fix radio checkbox visibility in Report dialogs Port b4b639ee4a059385874f143027b75516c8db17d9 to glitch-soc Signed-off-by: Claire --- app/javascript/flavours/glitch/styles/components.scss | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/app/javascript/flavours/glitch/styles/components.scss b/app/javascript/flavours/glitch/styles/components.scss index c26ce0d62c..4ae330d0a5 100644 --- a/app/javascript/flavours/glitch/styles/components.scss +++ b/app/javascript/flavours/glitch/styles/components.scss @@ -6899,7 +6899,7 @@ a.status-card { } .dialog-option .poll__input { - border-color: $inverted-text-color; + border-color: $darker-text-color; color: $ui-secondary-color; display: inline-flex; align-items: center; @@ -6913,13 +6913,13 @@ a.status-card { &:active, &:focus, &:hover { - border-color: lighten($inverted-text-color, 15%); + border-color: $valid-value-color; border-width: 4px; } &.active { - border-color: $inverted-text-color; - background: $inverted-text-color; + border-color: $valid-value-color; + background: $valid-value-color; } } From 09017dd8f063926738b253fe964a6b12faaa744f Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Thu, 5 Sep 2024 15:51:17 -0400 Subject: [PATCH 127/153] Add worker spec for annual report worker (#31778) --- .../generate_annual_report_worker_spec.rb | 27 +++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 spec/workers/generate_annual_report_worker_spec.rb diff --git a/spec/workers/generate_annual_report_worker_spec.rb b/spec/workers/generate_annual_report_worker_spec.rb new file mode 100644 index 0000000000..69b0d4424b --- /dev/null +++ b/spec/workers/generate_annual_report_worker_spec.rb @@ -0,0 +1,27 @@ +# frozen_string_literal: true + +require 'rails_helper' + +RSpec.describe GenerateAnnualReportWorker do + let(:worker) { described_class.new } + let(:account) { Fabricate :account } + + describe '#perform' do + it 'generates new report for the account' do + expect { worker.perform(account.id, Date.current.year) } + .to change(account_reports, :count).by(1) + end + + it 'returns true for non-existent record' do + result = worker.perform(123_123_123, Date.current.year) + + expect(result).to be(true) + end + + def account_reports + GeneratedAnnualReport + .where(account: account) + .where(year: Date.current.year) + end + end +end From 7efe0bde9dc363de57fc350dbcdb0b099bd1329a Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Thu, 5 Sep 2024 16:05:38 -0400 Subject: [PATCH 128/153] Add `have_http_link_header` matcher and set header values as strings (#31010) --- .../concerns/account_controller_concern.rb | 2 +- app/controllers/concerns/api/pagination.rb | 2 +- app/controllers/statuses_controller.rb | 4 ++- .../account_controller_concern_spec.rb | 13 +++----- spec/requests/accounts_spec.rb | 3 +- spec/requests/api/v1/timelines/home_spec.rb | 5 +-- spec/requests/api/v1/timelines/list_spec.rb | 5 +-- spec/requests/link_headers_spec.rb | 24 +++----------- spec/support/matchers/api_pagination.rb | 2 +- spec/support/matchers/http_link_header.rb | 33 +++++++++++++++++++ 10 files changed, 54 insertions(+), 39 deletions(-) create mode 100644 spec/support/matchers/http_link_header.rb diff --git a/app/controllers/concerns/account_controller_concern.rb b/app/controllers/concerns/account_controller_concern.rb index d63bcc85c9..b75f3e3581 100644 --- a/app/controllers/concerns/account_controller_concern.rb +++ b/app/controllers/concerns/account_controller_concern.rb @@ -20,7 +20,7 @@ module AccountControllerConcern webfinger_account_link, actor_url_link, ] - ) + ).to_s end def webfinger_account_link diff --git a/app/controllers/concerns/api/pagination.rb b/app/controllers/concerns/api/pagination.rb index 7f06dc0202..b0b4ae4603 100644 --- a/app/controllers/concerns/api/pagination.rb +++ b/app/controllers/concerns/api/pagination.rb @@ -19,7 +19,7 @@ module Api::Pagination links = [] links << [next_path, [%w(rel next)]] if next_path links << [prev_path, [%w(rel prev)]] if prev_path - response.headers['Link'] = LinkHeader.new(links) unless links.empty? + response.headers['Link'] = LinkHeader.new(links).to_s unless links.empty? end def require_valid_pagination_options! diff --git a/app/controllers/statuses_controller.rb b/app/controllers/statuses_controller.rb index db7eddd78b..a0885b469b 100644 --- a/app/controllers/statuses_controller.rb +++ b/app/controllers/statuses_controller.rb @@ -56,7 +56,9 @@ class StatusesController < ApplicationController end def set_link_headers - response.headers['Link'] = LinkHeader.new([[ActivityPub::TagManager.instance.uri_for(@status), [%w(rel alternate), %w(type application/activity+json)]]]) + response.headers['Link'] = LinkHeader.new( + [[ActivityPub::TagManager.instance.uri_for(@status), [%w(rel alternate), %w(type application/activity+json)]]] + ).to_s end def set_status diff --git a/spec/controllers/concerns/account_controller_concern_spec.rb b/spec/controllers/concerns/account_controller_concern_spec.rb index 3eee46d7b9..384406a0ea 100644 --- a/spec/controllers/concerns/account_controller_concern_spec.rb +++ b/spec/controllers/concerns/account_controller_concern_spec.rb @@ -54,17 +54,12 @@ RSpec.describe AccountControllerConcern do it 'Prepares the account, returns success, and sets link headers' do get 'success', params: { account_username: account.username } - expect(response).to have_http_status(200) - expect(response.headers['Link'].to_s).to eq(expected_link_headers) + expect(response) + .to have_http_status(200) + .and have_http_link_header('http://test.host/.well-known/webfinger?resource=acct%3Ausername%40cb6e6126.ngrok.io').for(rel: 'lrdd', type: 'application/jrd+json') + .and have_http_link_header('https://cb6e6126.ngrok.io/users/username').for(rel: 'alternate', type: 'application/activity+json') expect(response.body) .to include(account.username) end - - def expected_link_headers - [ - '; rel="lrdd"; type="application/jrd+json"', - '; rel="alternate"; type="application/activity+json"', - ].join(', ') - end end end diff --git a/spec/requests/accounts_spec.rb b/spec/requests/accounts_spec.rb index d53816eff0..3615868d74 100644 --- a/spec/requests/accounts_spec.rb +++ b/spec/requests/accounts_spec.rb @@ -69,8 +69,7 @@ RSpec.describe 'Accounts show response' do expect(response) .to have_http_status(200) .and render_template(:show) - - expect(response.headers['Link'].to_s).to include ActivityPub::TagManager.instance.uri_for(account) + .and have_http_link_header(ActivityPub::TagManager.instance.uri_for(account)).for(rel: 'alternate') end end diff --git a/spec/requests/api/v1/timelines/home_spec.rb b/spec/requests/api/v1/timelines/home_spec.rb index d158e0801c..9dd102fcb6 100644 --- a/spec/requests/api/v1/timelines/home_spec.rb +++ b/spec/requests/api/v1/timelines/home_spec.rb @@ -94,8 +94,9 @@ RSpec.describe 'Home', :inline_jobs do it 'returns http unprocessable entity', :aggregate_failures do subject - expect(response).to have_http_status(422) - expect(response.headers['Link']).to be_nil + expect(response) + .to have_http_status(422) + .and not_have_http_link_header end end end diff --git a/spec/requests/api/v1/timelines/list_spec.rb b/spec/requests/api/v1/timelines/list_spec.rb index 753c784866..eb4395d1f9 100644 --- a/spec/requests/api/v1/timelines/list_spec.rb +++ b/spec/requests/api/v1/timelines/list_spec.rb @@ -47,8 +47,9 @@ RSpec.describe 'API V1 Timelines List' do it 'returns http unprocessable entity' do get "/api/v1/timelines/list/#{list.id}", headers: headers - expect(response).to have_http_status(422) - expect(response.headers['Link']).to be_nil + expect(response) + .to have_http_status(422) + .and not_have_http_link_header end end end diff --git a/spec/requests/link_headers_spec.rb b/spec/requests/link_headers_spec.rb index 3116a54d6a..e20f5e79e5 100644 --- a/spec/requests/link_headers_spec.rb +++ b/spec/requests/link_headers_spec.rb @@ -6,28 +6,12 @@ RSpec.describe 'Link headers' do describe 'on the account show page' do let(:account) { Fabricate(:account, username: 'test') } - before do + it 'contains webfinger and activitypub urls in link header' do get short_account_path(username: account) - end - it 'contains webfinger url in link header' do - link_header = link_header_with_type('application/jrd+json') - - expect(link_header.href).to eq 'https://cb6e6126.ngrok.io/.well-known/webfinger?resource=acct%3Atest%40cb6e6126.ngrok.io' - expect(link_header.attr_pairs.first).to eq %w(rel lrdd) - end - - it 'contains activitypub url in link header' do - link_header = link_header_with_type('application/activity+json') - - expect(link_header.href).to eq 'https://cb6e6126.ngrok.io/users/test' - expect(link_header.attr_pairs.first).to eq %w(rel alternate) - end - - def link_header_with_type(type) - LinkHeader.parse(response.headers['Link'].to_s).links.find do |link| - link.attr_pairs.any?(['type', type]) - end + expect(response) + .to have_http_link_header('https://cb6e6126.ngrok.io/.well-known/webfinger?resource=acct%3Atest%40cb6e6126.ngrok.io').for(rel: 'lrdd', type: 'application/jrd+json') + .and have_http_link_header('https://cb6e6126.ngrok.io/users/test').for(rel: 'alternate', type: 'application/activity+json') end end end diff --git a/spec/support/matchers/api_pagination.rb b/spec/support/matchers/api_pagination.rb index f7d552b242..1a4f53a84a 100644 --- a/spec/support/matchers/api_pagination.rb +++ b/spec/support/matchers/api_pagination.rb @@ -3,7 +3,7 @@ RSpec::Matchers.define :include_pagination_headers do |links| match do |response| links.map do |key, value| - response.headers['Link'].find_link(['rel', key.to_s]).href == value + expect(response).to have_http_link_header(value).for(rel: key.to_s) end.all? end diff --git a/spec/support/matchers/http_link_header.rb b/spec/support/matchers/http_link_header.rb new file mode 100644 index 0000000000..3e658071c9 --- /dev/null +++ b/spec/support/matchers/http_link_header.rb @@ -0,0 +1,33 @@ +# frozen_string_literal: true + +RSpec::Matchers.define :have_http_link_header do |href| + match do |response| + @response = response + + header_link&.href == href + end + + match_when_negated do |response| + response.headers['Link'].blank? + end + + chain :for do |attributes| + @attributes = attributes + end + + failure_message do |response| + "Expected `#{response.headers['Link']}` to include `href` value of `#{href}` for `#{@attributes}` but it did not." + end + + failure_message_when_negated do + "Expected response not to have a `Link` header but `#{response.headers['Link']}` is present." + end + + def header_link + LinkHeader + .parse(@response.headers['Link']) + .find_link(*@attributes.stringify_keys) + end +end + +RSpec::Matchers.define_negated_matcher :not_have_http_link_header, :have_http_link_header # Allow chaining From 60182db0ca49f863d8f81f50f31b22386f734c90 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Fri, 6 Sep 2024 09:30:53 +0200 Subject: [PATCH 129/153] Update dependency tzinfo-data to v1.2024.2 (#31780) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile.lock b/Gemfile.lock index c70823d051..8577a52691 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -857,7 +857,7 @@ GEM unf (~> 0.1.0) tzinfo (2.0.6) concurrent-ruby (~> 1.0) - tzinfo-data (1.2024.1) + tzinfo-data (1.2024.2) tzinfo (>= 1.0.0) unf (0.1.4) unf_ext From cc4865193a4454c8650bd6877c30dfec68d69d55 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Fri, 6 Sep 2024 07:38:08 +0000 Subject: [PATCH 130/153] New Crowdin Translations (automated) (#31781) Co-authored-by: GitHub Actions --- app/javascript/mastodon/locales/fi.json | 6 +++--- app/javascript/mastodon/locales/ga.json | 4 ++++ app/javascript/mastodon/locales/ru.json | 2 +- config/locales/fi.yml | 14 +++++++------- config/locales/fr-CA.yml | 2 ++ config/locales/fr.yml | 2 ++ config/locales/fy.yml | 1 + config/locales/ga.yml | 1 + config/locales/gd.yml | 1 + config/locales/pt-BR.yml | 10 +++++++++- config/locales/simple_form.fr-CA.yml | 1 + config/locales/simple_form.fr.yml | 1 + config/locales/zh-CN.yml | 1 + 13 files changed, 34 insertions(+), 12 deletions(-) diff --git a/app/javascript/mastodon/locales/fi.json b/app/javascript/mastodon/locales/fi.json index 39df3e010f..79ca95a58c 100644 --- a/app/javascript/mastodon/locales/fi.json +++ b/app/javascript/mastodon/locales/fi.json @@ -1,6 +1,6 @@ { "about.blocks": "Moderoidut palvelimet", - "about.contact": "Yhteydenotto:", + "about.contact": "Yhteystiedot:", "about.disclaimer": "Mastodon on vapaa avoimen lähdekoodin ohjelmisto ja Mastodon gGmbH:n tavaramerkki.", "about.domain_blocks.no_reason_available": "Syy ei ole tiedossa", "about.domain_blocks.preamble": "Mastodonin avulla voi yleensä tarkastella minkä tahansa fediversumiin kuuluvan palvelimen sisältöä ja olla yhteyksissä eri palvelinten käyttäjien kanssa. Nämä poikkeukset koskevat yksin tätä palvelinta.", @@ -304,7 +304,7 @@ "filter_modal.select_filter.title": "Suodata tämä julkaisu", "filter_modal.title.status": "Suodata julkaisu", "filter_warning.matches_filter": "Vastaa suodatinta ”{title}”", - "filtered_notifications_banner.pending_requests": "{count, plural, =0 {Ei keneltäkään, jonka} one {1 käyttäjältä, jonka} other {# käyttäjältä, jotka}} saatat tuntea", + "filtered_notifications_banner.pending_requests": "{count, plural, =0 {Ei keneltäkään, jonka} one {Yhdeltä käyttäjältä, jonka} other {# käyttäjältä, jotka}} saatat tuntea", "filtered_notifications_banner.title": "Suodatetut ilmoitukset", "firehose.all": "Kaikki", "firehose.local": "Tämä palvelin", @@ -370,7 +370,7 @@ "home.show_announcements": "Näytä tiedotteet", "ignore_notifications_modal.disclaimer": "Mastodon ei voi ilmoittaa käyttäjille, että olet sivuuttanut heidän ilmoituksensa. Ilmoitusten sivuuttaminen ei lopeta itse viestien lähetystä.", "ignore_notifications_modal.filter_instead": "Suodata sen sijaan", - "ignore_notifications_modal.filter_to_act_users": "Voit silti hyväksyä, hylätä tai raportoida käyttäjiä", + "ignore_notifications_modal.filter_to_act_users": "Voit kuitenkin yhä hyväksyä, hylätä tai raportoida käyttäjiä", "ignore_notifications_modal.filter_to_avoid_confusion": "Suodatus auttaa välttämään mahdollisia sekaannuksia", "ignore_notifications_modal.filter_to_review_separately": "Voit käydä suodatettuja ilmoituksia läpi erikseen", "ignore_notifications_modal.ignore": "Sivuuta ilmoitukset", diff --git a/app/javascript/mastodon/locales/ga.json b/app/javascript/mastodon/locales/ga.json index 71577be955..b51d4adf68 100644 --- a/app/javascript/mastodon/locales/ga.json +++ b/app/javascript/mastodon/locales/ga.json @@ -97,6 +97,8 @@ "block_modal.title": "An bhfuil fonn ort an t-úsáideoir a bhlocáil?", "block_modal.you_wont_see_mentions": "Ní fheicfidh tú postálacha a luann iad.", "boost_modal.combo": "Is féidir leat {combo} a bhrú chun é seo a scipeáil an chéad uair eile", + "boost_modal.reblog": "An post a threisiú?", + "boost_modal.undo_reblog": "An deireadh a chur le postáil?", "bundle_column_error.copy_stacktrace": "Cóipeáil tuairisc earráide", "bundle_column_error.error.body": "Ní féidir an leathanach a iarradh a sholáthar. Seans gurb amhlaidh mar gheall ar fhabht sa chód, nó mar gheall ar mhíréireacht leis an mbrabhsálaí.", "bundle_column_error.error.title": "Ó, níl sé sin go maith!", @@ -467,6 +469,7 @@ "mute_modal.you_wont_see_mentions": "Ní fheicfidh tú postálacha a luann iad.", "mute_modal.you_wont_see_posts": "Is féidir leo do phoist a fheiceáil go fóill, ach ní fheicfidh tú a gcuid postanna.", "navigation_bar.about": "Maidir le", + "navigation_bar.administration": "Riarachán", "navigation_bar.advanced_interface": "Oscail i gcomhéadan gréasáin chun cinn", "navigation_bar.blocks": "Cuntais bhactha", "navigation_bar.bookmarks": "Leabharmharcanna", @@ -483,6 +486,7 @@ "navigation_bar.follows_and_followers": "Ag leanúint agus do do leanúint", "navigation_bar.lists": "Liostaí", "navigation_bar.logout": "Logáil Amach", + "navigation_bar.moderation": "Measarthacht", "navigation_bar.mutes": "Úsáideoirí balbhaithe", "navigation_bar.opened_in_classic_interface": "Osclaítear poist, cuntais agus leathanaigh shonracha eile de réir réamhshocraithe sa chomhéadan gréasáin clasaiceach.", "navigation_bar.personal": "Pearsanta", diff --git a/app/javascript/mastodon/locales/ru.json b/app/javascript/mastodon/locales/ru.json index cd64e8b8e5..4439b8dc0a 100644 --- a/app/javascript/mastodon/locales/ru.json +++ b/app/javascript/mastodon/locales/ru.json @@ -48,7 +48,7 @@ "account.moved_to": "У {name} теперь новый аккаунт:", "account.mute": "Игнорировать @{name}", "account.mute_notifications_short": "Отключить уведомления", - "account.mute_short": "Немой", + "account.mute_short": "Глохни!", "account.muted": "Игнорируется", "account.mutual": "Взаимно", "account.no_bio": "Описание не предоставлено.", diff --git a/config/locales/fi.yml b/config/locales/fi.yml index 42d1977662..8f0c80f1df 100644 --- a/config/locales/fi.yml +++ b/config/locales/fi.yml @@ -442,9 +442,9 @@ fi: create: Lisää verkkotunnus resolve: Selvitä verkkotunnus title: Estä uusi sähköpostiverkkotunnus - no_email_domain_block_selected: Sähköpostin verkkotunnuksia ei muutettu, koska yhtään ei ollut valittuna + no_email_domain_block_selected: Sähköpostiverkkotunnusten estoja ei muutettu; yhtäkään ei ollut valittu not_permitted: Ei sallittu - resolved_dns_records_hint_html: Verkkotunnuksen nimi määräytyy seuraaviin MX-verkkotunnuksiin, jotka ovat viime kädessä vastuussa sähköpostin vastaanottamisesta. MX-verkkotunnuksen estäminen estää rekisteröitymisen mistä tahansa sähköpostiosoitteesta, joka käyttää samaa MX-verkkotunnusta, vaikka näkyvä verkkotunnuksen nimi olisikin erilainen. Varo estämästä suuria sähköpostin palveluntarjoajia. + resolved_dns_records_hint_html: Verkkotunnusnimi kytkeytyy seuraaviin MX-verkkotunnuksiin, jotka ovat viime kädessä vastuussa sähköpostin vastaanottamisesta. MX-verkkotunnuksen estäminen estää rekisteröitymisen mistä tahansa sähköpostiosoitteesta, joka käyttää samaa MX-verkkotunnusta, vaikka näkyvä verkkotunnuksen nimi olisikin erilainen. Varo estämästä suuria sähköpostipalvelujen tarjoajia. resolved_through_html: Ratkaistu verkkotunnuksen %{domain} kautta title: Estetyt sähköpostiverkkotunnukset export_domain_allows: @@ -600,7 +600,7 @@ fi: resolve_description_html: Ilmoitettua tiliä kohtaan ei ryhdytä toimiin, varoitusta ei kirjata ja raportti suljetaan. silence_description_html: Tili näkyy vain niille, jotka jo seuraavat sitä tai etsivät sen manuaalisesti, mikä rajoittaa merkittävästi sen tavoitettavuutta. Voidaan perua milloin vain. Sulkee kaikki tiliin kohdistuvat raportit. suspend_description_html: Tili ja mikään sen sisältö eivät ole käytettävissä, ja lopulta ne poistetaan ja vuorovaikutus tilin kanssa on mahdotonta. Peruttavissa 30 päivän ajan. Sulkee kaikki tiliin kohdistuvat raportit. - actions_description_html: Päätä, mihin toimiin ryhdyt tämän raportin ratkaisemiseksi. Jos ryhdyt rangaistustoimeen ilmoitettua tiliä kohtaan, hänelle lähetetään sähköposti-ilmoitus, paitsi jos Roskaposti-luokka on valittuna. + actions_description_html: Päätä, mihin toimiin ryhdyt tämän raportin ratkaisemiseksi. Jos ryhdyt rangaistustoimeen ilmoitettua tiliä kohtaan, hänelle lähetetään sähköpostitse ilmoitus asiasta, paitsi jos valittuna on Roskaposti-luokka. actions_description_remote_html: Päätä, mihin toimiin ryhdyt tämän raportin ratkaisemiseksi. Tämä vaikuttaa vain siihen, miten sinun palvelimesi viestii tämän etätilin kanssa ja käsittelee sen sisältöä. add_to_report: Lisää raporttiin already_suspended_badges: @@ -977,7 +977,7 @@ fi: used_by_over_week: one: Käyttänyt yksi käyttäjä viimeisen viikon aikana other: Käyttänyt %{count} käyttäjää viimeisen viikon aikana - title: Suositukset ja trendit + title: Suositukset ja suuntaukset trending: Trendaus warning_presets: add_new: Lisää uusi @@ -1135,7 +1135,7 @@ fi: security: Turvallisuus set_new_password: Aseta uusi salasana setup: - email_below_hint_html: Tarkista roskapostikansiosi tai pyydä uusi viesti. Voit korjata sähköpostiosoitteesi, jos se oli väärin. + email_below_hint_html: Tarkista roskapostikansiosi tai pyydä uusi viesti. Voit myös korjata sähköpostiosoitteesi tarvittaessa. email_settings_hint_html: Napsauta lähettämäämme linkkiä vahvistaaksesi osoitteen %{email}. Odotamme täällä. link_not_received: Etkö saanut linkkiä? new_confirmation_instructions_sent: Saat pian uuden vahvistuslinkin sisältävän sähköpostiviestin! @@ -1195,8 +1195,8 @@ fi: caches: Muiden palvelinten välimuistiinsa tallentamaa sisältöä voi säilyä data_removal: Julkaisusi ja muut tietosi poistetaan pysyvästi email_change_html: Voit muuttaa sähköpostiosoitettasi poistamatta tiliäsi - email_contact_html: Jos ei saavu perille, voit pyytää apua sähköpostilla %{email} - email_reconfirmation_html: Jos et saa vahvistuksen sähköpostia, niin voit pyytää sitä uudelleen + email_contact_html: Mikäli viesti ei vieläkään saavu perille, voit pyytää apua sähköpostitse osoitteella %{email} + email_reconfirmation_html: Jos et saa vahvistussähköpostiviestiä, voit pyytää sitä uudelleen irreversible: Et voi palauttaa tiliäsi etkä aktivoida sitä uudelleen more_details_html: Tarkempia tietoja saat tietosuojakäytännöstämme. username_available: Käyttäjänimesi tulee saataville uudelleen diff --git a/config/locales/fr-CA.yml b/config/locales/fr-CA.yml index 45c6baece9..140bc94344 100644 --- a/config/locales/fr-CA.yml +++ b/config/locales/fr-CA.yml @@ -132,6 +132,7 @@ fr-CA: resubscribe: Se réabonner role: Rôle search: Rechercher + search_same_email_domain: Autres utilisateurs avec le même domaine de courriel search_same_ip: Autres utilisateur·rice·s avec la même IP security: Sécurité security_measures: @@ -1428,6 +1429,7 @@ fr-CA: media_attachments: validations: images_and_video: Impossible de joindre une vidéo à un message contenant déjà des images + not_found: Média %{ids} introuvable ou déjà attaché à un autre message not_ready: Impossible de joindre les fichiers en cours de traitement. Réessayez dans un instant ! too_many: Impossible de joindre plus de 4 fichiers migrations: diff --git a/config/locales/fr.yml b/config/locales/fr.yml index 4434a16531..5646877d23 100644 --- a/config/locales/fr.yml +++ b/config/locales/fr.yml @@ -132,6 +132,7 @@ fr: resubscribe: Se réabonner role: Rôle search: Rechercher + search_same_email_domain: Autres utilisateurs avec le même domaine de courriel search_same_ip: Autres utilisateur·rice·s avec la même IP security: Sécurité security_measures: @@ -1428,6 +1429,7 @@ fr: media_attachments: validations: images_and_video: Impossible de joindre une vidéo à un message contenant déjà des images + not_found: Média %{ids} introuvable ou déjà attaché à un autre message not_ready: Impossible de joindre les fichiers en cours de traitement. Réessayez dans un instant ! too_many: Impossible de joindre plus de 4 fichiers migrations: diff --git a/config/locales/fy.yml b/config/locales/fy.yml index d0127f77b1..de7495dd55 100644 --- a/config/locales/fy.yml +++ b/config/locales/fy.yml @@ -1454,6 +1454,7 @@ fy: media_attachments: validations: images_and_video: In fideo kin net oan in berjocht mei ôfbyldingen keppele wurde + not_found: Media %{ids} net fûn of al tafoege oan in oar berjocht not_ready: Kin gjin bestannen tafoegje dy’t noch net ferwurke binne. Probearje it letter opnij! too_many: Der kinne net mear as 4 ôfbyldingen tafoege wurde migrations: diff --git a/config/locales/ga.yml b/config/locales/ga.yml index 27237bf3a4..ad9ee21d3e 100644 --- a/config/locales/ga.yml +++ b/config/locales/ga.yml @@ -1532,6 +1532,7 @@ ga: media_attachments: validations: images_and_video: Ní féidir físeán a cheangal le postáil a bhfuil íomhánna ann cheana féin + not_found: Meán %{ids} gan aimsiú nó ceangailte le postáil eile cheana not_ready: Ní féidir comhaid nach bhfuil próiseáil críochnaithe acu a cheangal. Bain triail eile as i gceann nóiméad! too_many: Ní féidir níos mó ná 4 chomhad a cheangal migrations: diff --git a/config/locales/gd.yml b/config/locales/gd.yml index ef4add838e..2af647ab9c 100644 --- a/config/locales/gd.yml +++ b/config/locales/gd.yml @@ -1506,6 +1506,7 @@ gd: media_attachments: validations: images_and_video: Chan urrainn dhut video a cheangal ri post sa bheil dealbh mu thràth + not_found: Cha deach na meadhanan %{ids} a lorg no chaidh an ceangal ri post eile mu thràth not_ready: Chan urrainn dhuinn faidhlichean a cheangal ris nach eil air am pròiseasadh fhathast. Feuch ris a-rithist an ceann greis! too_many: Chan urrainn dhut barrachd air 4 faidhlichean a ceangal ris migrations: diff --git a/config/locales/pt-BR.yml b/config/locales/pt-BR.yml index 579dbd967f..18496b9e1d 100644 --- a/config/locales/pt-BR.yml +++ b/config/locales/pt-BR.yml @@ -203,7 +203,7 @@ pt-BR: disable_sign_in_token_auth_user: Desativar autenticação via Token de Email para Usuário disable_user: Desativar usuário enable_custom_emoji: Ativar emoji personalizado - enable_sign_in_token_auth_user: Desativar autenticação via token por e-mail para o usuário + enable_sign_in_token_auth_user: Ativar autenticação via Token de Email para Usuário enable_user: Ativar usuário memorialize_account: Converter conta em memorial promote_user: Promover usuário @@ -442,6 +442,7 @@ pt-BR: create: Adicionar domínio resolve: Resolver domínio title: Bloquear novo domínio de e-mail + no_email_domain_block_selected: Nenhum bloco de domínio de email foi alterado, pois, nenhum foi selecionado not_permitted: Não permitido resolved_dns_records_hint_html: O nome de domínio é associado aos seguintes domínios MX, que são responsáveis por aceitar e-mails. Ao bloquear um domínio MX, você bloqueará as inscrições de qualquer endereço de e-mail que use o mesmo domínio MX, mesmo que o nome de domínio visível seja diferente. Tenha cuidado para não bloquear os principais provedores de e-mail. resolved_through_html: Resolvido através de %{domain} @@ -1440,6 +1441,13 @@ pt-BR: action: Sim, cancelar subscrição complete: Desinscrito confirmation_html: Tem certeza que deseja cancelar a assinatura de %{type} para Mastodon no %{domain} para o seu endereço de e-mail %{email}? Você sempre pode se inscrever novamente nas configurações de notificação de email. + emails: + notification_emails: + favourite: emails de notificação favoritos + follow: seguir emails de notificação + follow_request: emails de seguidores pendentes + mention: emails de notificação de menções + reblog: emails de notificação de boosts resubscribe_html: Se você cancelou sua inscrição por engano, você pode se inscrever novamente em suas configurações de notificações por e-mail. success_html: Você não mais receberá %{type} no Mastodon em %{domain} ao seu endereço de e-mail %{email}. title: Cancelar inscrição diff --git a/config/locales/simple_form.fr-CA.yml b/config/locales/simple_form.fr-CA.yml index e8aafa4b1c..640d7e344a 100644 --- a/config/locales/simple_form.fr-CA.yml +++ b/config/locales/simple_form.fr-CA.yml @@ -81,6 +81,7 @@ fr-CA: bootstrap_timeline_accounts: Ces comptes seront épinglés en tête de liste des recommandations pour les nouveaux utilisateurs. closed_registrations_message: Affiché lorsque les inscriptions sont fermées custom_css: Vous pouvez appliquer des styles personnalisés sur la version Web de Mastodon. + favicon: WEBP, PNG, GIF ou JPG. Remplace la favicon Mastodon par défaut avec une icône personnalisée. mascot: Remplace l'illustration dans l'interface Web avancée. media_cache_retention_period: Les fichiers médias des messages publiés par des utilisateurs distants sont mis en cache sur votre serveur. Lorsque cette valeur est positive, les médias sont supprimés au terme du nombre de jours spécifié. Si les données des médias sont demandées après leur suppression, elles seront téléchargées à nouveau, dans la mesure où le contenu source est toujours disponible. En raison des restrictions concernant la fréquence à laquelle les cartes de prévisualisation des liens interrogent des sites tiers, il est recommandé de fixer cette valeur à au moins 14 jours, faute de quoi les cartes de prévisualisation des liens ne seront pas mises à jour à la demande avant cette échéance. peers_api_enabled: Une liste de noms de domaine que ce serveur a rencontrés dans le fédiverse. Aucune donnée indiquant si vous vous fédérez ou non avec un serveur particulier n'est incluse ici, seulement l'information que votre serveur connaît un autre serveur. Cette option est utilisée par les services qui collectent des statistiques sur la fédération en général. diff --git a/config/locales/simple_form.fr.yml b/config/locales/simple_form.fr.yml index 315e22c5fb..04d48573a3 100644 --- a/config/locales/simple_form.fr.yml +++ b/config/locales/simple_form.fr.yml @@ -81,6 +81,7 @@ fr: bootstrap_timeline_accounts: Ces comptes seront épinglés en tête de liste des recommandations pour les nouveaux utilisateurs. closed_registrations_message: Affiché lorsque les inscriptions sont fermées custom_css: Vous pouvez appliquer des styles personnalisés sur la version Web de Mastodon. + favicon: WEBP, PNG, GIF ou JPG. Remplace la favicon Mastodon par défaut avec une icône personnalisée. mascot: Remplace l'illustration dans l'interface Web avancée. media_cache_retention_period: Les fichiers médias des messages publiés par des utilisateurs distants sont mis en cache sur votre serveur. Lorsque cette valeur est positive, les médias sont supprimés au terme du nombre de jours spécifié. Si les données des médias sont demandées après leur suppression, elles seront téléchargées à nouveau, dans la mesure où le contenu source est toujours disponible. En raison des restrictions concernant la fréquence à laquelle les cartes de prévisualisation des liens interrogent des sites tiers, il est recommandé de fixer cette valeur à au moins 14 jours, faute de quoi les cartes de prévisualisation des liens ne seront pas mises à jour à la demande avant cette échéance. peers_api_enabled: Une liste de noms de domaine que ce serveur a rencontrés dans le fédiverse. Aucune donnée indiquant si vous vous fédérez ou non avec un serveur particulier n'est incluse ici, seulement l'information que votre serveur connaît un autre serveur. Cette option est utilisée par les services qui collectent des statistiques sur la fédération en général. diff --git a/config/locales/zh-CN.yml b/config/locales/zh-CN.yml index c31a68926e..a8d401c7bb 100644 --- a/config/locales/zh-CN.yml +++ b/config/locales/zh-CN.yml @@ -1428,6 +1428,7 @@ zh-CN: media_attachments: validations: images_and_video: 无法在嘟文中同时插入视频和图片 + not_found: 未发现媒体%{ids} 或已附在另一条嘟文中 not_ready: 不能附加还在处理中的文件。请稍后再试! too_many: 最多只能添加 4 张图片 migrations: From be77a1098bef771dffe85d94e8ed4ddeb53cc768 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Fri, 6 Sep 2024 03:49:38 -0400 Subject: [PATCH 131/153] Extract `Account::AUTOMATED_ACTOR_TYPES` for "bot" actor_type values (#31772) --- app/models/account.rb | 7 +++++-- lib/mastodon/cli/accounts.rb | 2 +- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/app/models/account.rb b/app/models/account.rb index c20b72658b..d773d33441 100644 --- a/app/models/account.rb +++ b/app/models/account.rb @@ -75,6 +75,8 @@ class Account < ApplicationRecord DISPLAY_NAME_LENGTH_LIMIT = 30 NOTE_LENGTH_LIMIT = 500 + AUTOMATED_ACTOR_TYPES = %w(Application Service).freeze + include Attachmentable # Load prior to Avatar & Header concerns include Account::Associations @@ -127,7 +129,8 @@ class Account < ApplicationRecord scope :without_silenced, -> { where(silenced_at: nil) } scope :without_instance_actor, -> { where.not(id: INSTANCE_ACTOR_ID) } scope :recent, -> { reorder(id: :desc) } - scope :bots, -> { where(actor_type: %w(Application Service)) } + scope :bots, -> { where(actor_type: AUTOMATED_ACTOR_TYPES) } + scope :non_automated, -> { where.not(actor_type: AUTOMATED_ACTOR_TYPES) } scope :groups, -> { where(actor_type: 'Group') } scope :alphabetic, -> { order(domain: :asc, username: :asc) } scope :matches_uri_prefix, ->(value) { where(arel_table[:uri].matches("#{sanitize_sql_like(value)}/%", false, true)).or(where(uri: value)) } @@ -183,7 +186,7 @@ class Account < ApplicationRecord end def bot? - %w(Application Service).include? actor_type + AUTOMATED_ACTOR_TYPES.include?(actor_type) end def instance_actor? diff --git a/lib/mastodon/cli/accounts.rb b/lib/mastodon/cli/accounts.rb index 0cdf68158f..8a138323d4 100644 --- a/lib/mastodon/cli/accounts.rb +++ b/lib/mastodon/cli/accounts.rb @@ -502,7 +502,7 @@ module Mastodon::CLI - not muted/blocked by us LONG_DESC def prune - query = Account.remote.where.not(actor_type: %i(Application Service)) + query = Account.remote.non_automated query = query.where('NOT EXISTS (SELECT 1 FROM mentions WHERE account_id = accounts.id)') query = query.where('NOT EXISTS (SELECT 1 FROM favourites WHERE account_id = accounts.id)') query = query.where('NOT EXISTS (SELECT 1 FROM statuses WHERE account_id = accounts.id)') From 6b6a80b407e03c31326deb9838bc9c199bab39ea Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Fri, 6 Sep 2024 05:58:46 -0400 Subject: [PATCH 132/153] Remove `body_as_json` in favor of built-in `response.parsed_body` for JSON response specs (#31749) --- .../collections_controller_spec.rb | 8 ++-- ...lowers_synchronizations_controller_spec.rb | 3 +- .../activitypub/outboxes_controller_spec.rb | 41 +++++++++++-------- .../activitypub/replies_controller_spec.rb | 2 +- .../auth/sessions_controller_spec.rb | 2 +- .../follower_accounts_controller_spec.rb | 37 +++++++++-------- .../following_accounts_controller_spec.rb | 37 +++++++++-------- spec/controllers/statuses_controller_spec.rb | 14 +++---- spec/requests/accounts_spec.rb | 8 ++-- .../api/v1/accounts/credentials_spec.rb | 6 +-- .../v1/accounts/familiar_followers_spec.rb | 2 +- .../api/v1/accounts/featured_tags_spec.rb | 4 +- .../api/v1/accounts/follower_accounts_spec.rb | 14 +++---- .../v1/accounts/following_accounts_spec.rb | 14 +++---- .../api/v1/accounts/relationships_spec.rb | 14 +++---- .../requests/api/v1/accounts/statuses_spec.rb | 6 +-- spec/requests/api/v1/accounts_spec.rb | 20 ++++----- spec/requests/api/v1/admin/accounts_spec.rb | 6 +-- .../v1/admin/canonical_email_blocks_spec.rb | 22 +++++----- spec/requests/api/v1/admin/dimensions_spec.rb | 2 +- .../api/v1/admin/domain_allows_spec.rb | 12 +++--- .../api/v1/admin/domain_blocks_spec.rb | 40 +++++++++--------- .../api/v1/admin/email_domain_blocks_spec.rb | 16 ++++---- spec/requests/api/v1/admin/ip_blocks_spec.rb | 14 +++---- spec/requests/api/v1/admin/measures_spec.rb | 2 +- spec/requests/api/v1/admin/reports_spec.rb | 16 ++++---- spec/requests/api/v1/admin/retention_spec.rb | 2 +- spec/requests/api/v1/admin/tags_spec.rb | 14 +++---- .../api/v1/admin/trends/links/links_spec.rb | 4 +- spec/requests/api/v1/annual_reports_spec.rb | 2 +- spec/requests/api/v1/apps/credentials_spec.rb | 12 +++--- spec/requests/api/v1/apps_spec.rb | 10 ++--- spec/requests/api/v1/blocks_spec.rb | 8 ++-- spec/requests/api/v1/bookmarks_spec.rb | 4 +- spec/requests/api/v1/conversations_spec.rb | 8 ++-- spec/requests/api/v1/custom_emojis_spec.rb | 4 +- spec/requests/api/v1/directories_spec.rb | 20 ++++----- spec/requests/api/v1/domain_blocks_spec.rb | 4 +- .../api/v1/emails/confirmations_spec.rb | 8 ++-- spec/requests/api/v1/endorsements_spec.rb | 4 +- spec/requests/api/v1/favourites_spec.rb | 4 +- .../api/v1/featured_tags/suggestions_spec.rb | 2 +- spec/requests/api/v1/featured_tags_spec.rb | 8 ++-- spec/requests/api/v1/filters_spec.rb | 2 +- spec/requests/api/v1/follow_requests_spec.rb | 8 ++-- spec/requests/api/v1/followed_tags_spec.rb | 4 +- spec/requests/api/v1/instance_spec.rb | 4 +- .../api/v1/instances/activity_spec.rb | 2 +- .../api/v1/instances/domain_blocks_spec.rb | 2 +- .../instances/extended_descriptions_spec.rb | 2 +- .../api/v1/instances/languages_spec.rb | 2 +- spec/requests/api/v1/instances/peers_spec.rb | 2 +- .../api/v1/instances/privacy_policies_spec.rb | 2 +- spec/requests/api/v1/instances/rules_spec.rb | 2 +- .../instances/translation_languages_spec.rb | 4 +- spec/requests/api/v1/lists/accounts_spec.rb | 4 +- spec/requests/api/v1/lists_spec.rb | 8 ++-- spec/requests/api/v1/markers_spec.rb | 4 +- spec/requests/api/v1/media_spec.rb | 4 +- spec/requests/api/v1/mutes_spec.rb | 8 ++-- .../api/v1/notifications/policies_spec.rb | 4 +- .../api/v1/notifications/requests_spec.rb | 4 +- spec/requests/api/v1/notifications_spec.rb | 28 ++++++------- spec/requests/api/v1/peers/search_spec.rb | 8 ++-- spec/requests/api/v1/polls_spec.rb | 2 +- spec/requests/api/v1/preferences_spec.rb | 2 +- .../api/v1/push/subscriptions_spec.rb | 4 +- spec/requests/api/v1/reports_spec.rb | 2 +- spec/requests/api/v1/scheduled_status_spec.rb | 4 +- .../api/v1/statuses/bookmarks_spec.rb | 6 +-- .../statuses/favourited_by_accounts_spec.rb | 8 ++-- .../api/v1/statuses/favourites_spec.rb | 6 +-- .../api/v1/statuses/histories_spec.rb | 2 +- spec/requests/api/v1/statuses/pins_spec.rb | 4 +- .../v1/statuses/reblogged_by_accounts_spec.rb | 8 ++-- spec/requests/api/v1/statuses/reblogs_spec.rb | 6 +-- spec/requests/api/v1/statuses/sources_spec.rb | 4 +- spec/requests/api/v1/statuses_spec.rb | 10 ++--- spec/requests/api/v1/suggestions_spec.rb | 4 +- spec/requests/api/v1/tags_spec.rb | 2 +- spec/requests/api/v1/timelines/home_spec.rb | 4 +- spec/requests/api/v1/timelines/link_spec.rb | 4 +- spec/requests/api/v1/timelines/public_spec.rb | 4 +- spec/requests/api/v1/timelines/tag_spec.rb | 4 +- spec/requests/api/v2/admin/accounts_spec.rb | 2 +- spec/requests/api/v2/filters/keywords_spec.rb | 6 +-- spec/requests/api/v2/filters/statuses_spec.rb | 6 +-- spec/requests/api/v2/filters_spec.rb | 9 ++-- spec/requests/api/v2/instance_spec.rb | 4 +- spec/requests/api/v2/media_spec.rb | 8 ++-- .../api/v2/notifications/policies_spec.rb | 4 +- spec/requests/api/v2/search_spec.rb | 4 +- spec/requests/api/v2/suggestions_spec.rb | 2 +- .../v2_alpha/notifications/accounts_spec.rb | 4 +- .../api/v2_alpha/notifications_spec.rb | 34 +++++++-------- spec/requests/api/web/embeds_spec.rb | 6 +-- spec/requests/emojis_spec.rb | 2 +- spec/requests/instance_actor_spec.rb | 2 +- spec/requests/invite_spec.rb | 2 +- spec/requests/log_out_spec.rb | 2 +- spec/requests/manifest_spec.rb | 2 +- spec/requests/oauth/token_spec.rb | 6 +-- spec/requests/signature_verification_spec.rb | 30 +++++++------- spec/requests/well_known/node_info_spec.rb | 4 +- .../well_known/oauth_metadata_spec.rb | 2 +- spec/requests/well_known/webfinger_spec.rb | 12 +++--- spec/spec_helper.rb | 4 -- 107 files changed, 422 insertions(+), 413 deletions(-) diff --git a/spec/controllers/activitypub/collections_controller_spec.rb b/spec/controllers/activitypub/collections_controller_spec.rb index 0880273853..408e0dd2f6 100644 --- a/spec/controllers/activitypub/collections_controller_spec.rb +++ b/spec/controllers/activitypub/collections_controller_spec.rb @@ -31,7 +31,7 @@ RSpec.describe ActivityPub::CollectionsController do .and have_cacheable_headers expect(response.media_type).to eq 'application/activity+json' - expect(body_as_json[:orderedItems]) + expect(response.parsed_body[:orderedItems]) .to be_an(Array) .and have_attributes(size: 3) .and include(ActivityPub::TagManager.instance.uri_for(private_pinned)) @@ -71,7 +71,7 @@ RSpec.describe ActivityPub::CollectionsController do expect(response.media_type).to eq 'application/activity+json' - expect(body_as_json[:orderedItems]) + expect(response.parsed_body[:orderedItems]) .to be_an(Array) .and have_attributes(size: 3) .and include(ActivityPub::TagManager.instance.uri_for(private_pinned)) @@ -94,7 +94,7 @@ RSpec.describe ActivityPub::CollectionsController do expect(response.media_type).to eq 'application/activity+json' expect(response.headers['Cache-Control']).to include 'private' - expect(body_as_json[:orderedItems]) + expect(response.parsed_body[:orderedItems]) .to be_an(Array) .and be_empty end @@ -110,7 +110,7 @@ RSpec.describe ActivityPub::CollectionsController do expect(response.media_type).to eq 'application/activity+json' expect(response.headers['Cache-Control']).to include 'private' - expect(body_as_json[:orderedItems]) + expect(response.parsed_body[:orderedItems]) .to be_an(Array) .and be_empty end diff --git a/spec/controllers/activitypub/followers_synchronizations_controller_spec.rb b/spec/controllers/activitypub/followers_synchronizations_controller_spec.rb index c030078d43..cbd982f18f 100644 --- a/spec/controllers/activitypub/followers_synchronizations_controller_spec.rb +++ b/spec/controllers/activitypub/followers_synchronizations_controller_spec.rb @@ -34,7 +34,6 @@ RSpec.describe ActivityPub::FollowersSynchronizationsController do context 'with signature from example.com' do subject(:response) { get :show, params: { account_username: account.username } } - let(:body) { body_as_json } let(:remote_account) { Fabricate(:account, domain: 'example.com', uri: 'https://example.com/instance') } it 'returns http success and cache control and activity json types and correct items' do @@ -42,7 +41,7 @@ RSpec.describe ActivityPub::FollowersSynchronizationsController do expect(response.headers['Cache-Control']).to eq 'max-age=0, private' expect(response.media_type).to eq 'application/activity+json' - expect(body[:orderedItems]) + expect(response.parsed_body[:orderedItems]) .to be_an(Array) .and contain_exactly( follower_example_com_instance_actor.uri, diff --git a/spec/controllers/activitypub/outboxes_controller_spec.rb b/spec/controllers/activitypub/outboxes_controller_spec.rb index 26a52bad93..7ae28e8e09 100644 --- a/spec/controllers/activitypub/outboxes_controller_spec.rb +++ b/spec/controllers/activitypub/outboxes_controller_spec.rb @@ -19,7 +19,6 @@ RSpec.describe ActivityPub::OutboxesController do context 'without signature' do subject(:response) { get :show, params: { account_username: account.username, page: page } } - let(:body) { body_as_json } let(:remote_account) { nil } context 'with page not requested' do @@ -32,7 +31,7 @@ RSpec.describe ActivityPub::OutboxesController do expect(response.media_type).to eq 'application/activity+json' expect(response.headers['Vary']).to be_nil - expect(body[:totalItems]).to eq 4 + expect(response.parsed_body[:totalItems]).to eq 4 end context 'when account is permanently suspended' do @@ -68,9 +67,11 @@ RSpec.describe ActivityPub::OutboxesController do expect(response.media_type).to eq 'application/activity+json' expect(response.headers['Vary']).to include 'Signature' - expect(body[:orderedItems]).to be_an Array - expect(body[:orderedItems].size).to eq 2 - expect(body[:orderedItems].all? { |item| targets_public_collection?(item) }).to be true + expect(response.parsed_body) + .to include( + orderedItems: be_an(Array).and(have_attributes(size: 2)) + ) + expect(response.parsed_body[:orderedItems].all? { |item| targets_public_collection?(item) }).to be true end context 'when account is permanently suspended' do @@ -110,9 +111,11 @@ RSpec.describe ActivityPub::OutboxesController do expect(response.media_type).to eq 'application/activity+json' expect(response.headers['Cache-Control']).to eq 'max-age=60, private' - expect(body_as_json[:orderedItems]).to be_an Array - expect(body_as_json[:orderedItems].size).to eq 2 - expect(body_as_json[:orderedItems].all? { |item| targets_public_collection?(item) }).to be true + expect(response.parsed_body) + .to include( + orderedItems: be_an(Array).and(have_attributes(size: 2)) + ) + expect(response.parsed_body[:orderedItems].all? { |item| targets_public_collection?(item) }).to be true end end @@ -127,9 +130,11 @@ RSpec.describe ActivityPub::OutboxesController do expect(response.media_type).to eq 'application/activity+json' expect(response.headers['Cache-Control']).to eq 'max-age=60, private' - expect(body_as_json[:orderedItems]).to be_an Array - expect(body_as_json[:orderedItems].size).to eq 3 - expect(body_as_json[:orderedItems].all? { |item| targets_public_collection?(item) || targets_followers_collection?(item, account) }).to be true + expect(response.parsed_body) + .to include( + orderedItems: be_an(Array).and(have_attributes(size: 3)) + ) + expect(response.parsed_body[:orderedItems].all? { |item| targets_public_collection?(item) || targets_followers_collection?(item, account) }).to be true end end @@ -144,9 +149,10 @@ RSpec.describe ActivityPub::OutboxesController do expect(response.media_type).to eq 'application/activity+json' expect(response.headers['Cache-Control']).to eq 'max-age=60, private' - expect(body_as_json[:orderedItems]) - .to be_an(Array) - .and be_empty + expect(response.parsed_body) + .to include( + orderedItems: be_an(Array).and(be_empty) + ) end end @@ -161,9 +167,10 @@ RSpec.describe ActivityPub::OutboxesController do expect(response.media_type).to eq 'application/activity+json' expect(response.headers['Cache-Control']).to eq 'max-age=60, private' - expect(body_as_json[:orderedItems]) - .to be_an(Array) - .and be_empty + expect(response.parsed_body) + .to include( + orderedItems: be_an(Array).and(be_empty) + ) end end end diff --git a/spec/controllers/activitypub/replies_controller_spec.rb b/spec/controllers/activitypub/replies_controller_spec.rb index c10c782c9a..27821b0d4e 100644 --- a/spec/controllers/activitypub/replies_controller_spec.rb +++ b/spec/controllers/activitypub/replies_controller_spec.rb @@ -66,7 +66,7 @@ RSpec.describe ActivityPub::RepliesController do context 'when status is public' do let(:parent_visibility) { :public } - let(:page_json) { body_as_json[:first] } + let(:page_json) { response.parsed_body[:first] } it 'returns http success and correct media type' do expect(response) diff --git a/spec/controllers/auth/sessions_controller_spec.rb b/spec/controllers/auth/sessions_controller_spec.rb index 9a94e5e1a1..3cc3460718 100644 --- a/spec/controllers/auth/sessions_controller_spec.rb +++ b/spec/controllers/auth/sessions_controller_spec.rb @@ -402,7 +402,7 @@ RSpec.describe Auth::SessionsController do end it 'instructs the browser to redirect to home, logs the user in, and updates the sign count' do - expect(body_as_json[:redirect_path]).to eq(root_path) + expect(response.parsed_body[:redirect_path]).to eq(root_path) expect(controller.current_user).to eq user diff --git a/spec/controllers/follower_accounts_controller_spec.rb b/spec/controllers/follower_accounts_controller_spec.rb index e84528d13e..e14ed00e60 100644 --- a/spec/controllers/follower_accounts_controller_spec.rb +++ b/spec/controllers/follower_accounts_controller_spec.rb @@ -39,8 +39,6 @@ RSpec.describe FollowerAccountsController do end context 'when format is json' do - subject(:body) { response.parsed_body } - let(:response) { get :index, params: { account_username: alice.username, page: page, format: :json } } context 'with page' do @@ -48,15 +46,15 @@ RSpec.describe FollowerAccountsController do it 'returns followers' do expect(response).to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to include( orderedItems: contain_exactly( include(follow_from_bob.account.username), include(follow_from_chris.account.username) - ) + ), + totalItems: eq(2), + partOf: be_present ) - expect(body['totalItems']).to eq 2 - expect(body['partOf']).to be_present end context 'when account is permanently suspended' do @@ -86,8 +84,11 @@ RSpec.describe FollowerAccountsController do it 'returns followers' do expect(response).to have_http_status(200) - expect(body['totalItems']).to eq 2 - expect(body['partOf']).to be_blank + expect(response.parsed_body) + .to include( + totalItems: eq(2) + ) + .and not_include(:partOf) end context 'when account hides their network' do @@ -95,15 +96,17 @@ RSpec.describe FollowerAccountsController do alice.update(hide_collections: true) end - it 'returns followers count' do - expect(body['totalItems']).to eq 2 - end - - it 'does not return items' do - expect(body['items']).to be_blank - expect(body['orderedItems']).to be_blank - expect(body['first']).to be_blank - expect(body['last']).to be_blank + it 'returns followers count but not any items' do + expect(response.parsed_body) + .to include( + totalItems: eq(2) + ) + .and not_include( + :items, + :orderedItems, + :first, + :last + ) end end diff --git a/spec/controllers/following_accounts_controller_spec.rb b/spec/controllers/following_accounts_controller_spec.rb index 1e01b9f494..fea4d4845c 100644 --- a/spec/controllers/following_accounts_controller_spec.rb +++ b/spec/controllers/following_accounts_controller_spec.rb @@ -39,8 +39,6 @@ RSpec.describe FollowingAccountsController do end context 'when format is json' do - subject(:body) { response.parsed_body } - let(:response) { get :index, params: { account_username: alice.username, page: page, format: :json } } context 'with page' do @@ -48,15 +46,15 @@ RSpec.describe FollowingAccountsController do it 'returns followers' do expect(response).to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to include( orderedItems: contain_exactly( include(follow_of_bob.target_account.username), include(follow_of_chris.target_account.username) - ) + ), + totalItems: eq(2), + partOf: be_present ) - expect(body['totalItems']).to eq 2 - expect(body['partOf']).to be_present end context 'when account is permanently suspended' do @@ -86,8 +84,11 @@ RSpec.describe FollowingAccountsController do it 'returns followers' do expect(response).to have_http_status(200) - expect(body['totalItems']).to eq 2 - expect(body['partOf']).to be_blank + expect(response.parsed_body) + .to include( + totalItems: eq(2) + ) + .and not_include(:partOf) end context 'when account hides their network' do @@ -95,15 +96,17 @@ RSpec.describe FollowingAccountsController do alice.update(hide_collections: true) end - it 'returns followers count' do - expect(body['totalItems']).to eq 2 - end - - it 'does not return items' do - expect(body['items']).to be_blank - expect(body['orderedItems']).to be_blank - expect(body['first']).to be_blank - expect(body['last']).to be_blank + it 'returns followers count but not any items' do + expect(response.parsed_body) + .to include( + totalItems: eq(2) + ) + .and not_include( + :items, + :orderedItems, + :first, + :last + ) end end diff --git a/spec/controllers/statuses_controller_spec.rb b/spec/controllers/statuses_controller_spec.rb index 289109a1fa..2d5ff0135b 100644 --- a/spec/controllers/statuses_controller_spec.rb +++ b/spec/controllers/statuses_controller_spec.rb @@ -81,7 +81,7 @@ RSpec.describe StatusesController do 'Content-Type' => include('application/activity+json'), 'Link' => satisfy { |header| header.to_s.include?('activity+json') } ) - expect(body_as_json) + expect(response.parsed_body) .to include(content: include(status.text)) end end @@ -186,7 +186,7 @@ RSpec.describe StatusesController do 'Content-Type' => include('application/activity+json'), 'Link' => satisfy { |header| header.to_s.include?('activity+json') } ) - expect(body_as_json) + expect(response.parsed_body) .to include(content: include(status.text)) end end @@ -230,7 +230,7 @@ RSpec.describe StatusesController do 'Content-Type' => include('application/activity+json'), 'Link' => satisfy { |header| header.to_s.include?('activity+json') } ) - expect(body_as_json) + expect(response.parsed_body) .to include(content: include(status.text)) end end @@ -296,7 +296,7 @@ RSpec.describe StatusesController do 'Content-Type' => include('application/activity+json'), 'Link' => satisfy { |header| header.to_s.include?('activity+json') } ) - expect(body_as_json) + expect(response.parsed_body) .to include(content: include(status.text)) end end @@ -387,7 +387,7 @@ RSpec.describe StatusesController do 'Content-Type' => include('application/activity+json'), 'Link' => satisfy { |header| header.to_s.include?('activity+json') } ) - expect(body_as_json) + expect(response.parsed_body) .to include(content: include(status.text)) end end @@ -431,7 +431,7 @@ RSpec.describe StatusesController do 'Link' => satisfy { |header| header.to_s.include?('activity+json') } ) - expect(body_as_json) + expect(response.parsed_body) .to include(content: include(status.text)) end end @@ -497,7 +497,7 @@ RSpec.describe StatusesController do 'Content-Type' => include('application/activity+json'), 'Link' => satisfy { |header| header.to_s.include?('activity+json') } ) - expect(body_as_json) + expect(response.parsed_body) .to include(content: include(status.text)) end end diff --git a/spec/requests/accounts_spec.rb b/spec/requests/accounts_spec.rb index 3615868d74..e657ae6060 100644 --- a/spec/requests/accounts_spec.rb +++ b/spec/requests/accounts_spec.rb @@ -134,7 +134,7 @@ RSpec.describe 'Accounts show response' do media_type: eq('application/activity+json') ) - expect(body_as_json).to include(:id, :type, :preferredUsername, :inbox, :publicKey, :name, :summary) + expect(response.parsed_body).to include(:id, :type, :preferredUsername, :inbox, :publicKey, :name, :summary) end context 'with authorized fetch mode' do @@ -163,7 +163,7 @@ RSpec.describe 'Accounts show response' do expect(response.headers['Cache-Control']).to include 'private' - expect(body_as_json).to include(:id, :type, :preferredUsername, :inbox, :publicKey, :name, :summary) + expect(response.parsed_body).to include(:id, :type, :preferredUsername, :inbox, :publicKey, :name, :summary) end end @@ -182,7 +182,7 @@ RSpec.describe 'Accounts show response' do media_type: eq('application/activity+json') ) - expect(body_as_json).to include(:id, :type, :preferredUsername, :inbox, :publicKey, :name, :summary) + expect(response.parsed_body).to include(:id, :type, :preferredUsername, :inbox, :publicKey, :name, :summary) end context 'with authorized fetch mode' do @@ -198,7 +198,7 @@ RSpec.describe 'Accounts show response' do expect(response.headers['Cache-Control']).to include 'private' expect(response.headers['Vary']).to include 'Signature' - expect(body_as_json).to include(:id, :type, :preferredUsername, :inbox, :publicKey, :name, :summary) + expect(response.parsed_body).to include(:id, :type, :preferredUsername, :inbox, :publicKey, :name, :summary) end end end diff --git a/spec/requests/api/v1/accounts/credentials_spec.rb b/spec/requests/api/v1/accounts/credentials_spec.rb index a3f552cada..cc82e1892e 100644 --- a/spec/requests/api/v1/accounts/credentials_spec.rb +++ b/spec/requests/api/v1/accounts/credentials_spec.rb @@ -20,7 +20,7 @@ RSpec.describe 'credentials API' do expect(response) .to have_http_status(200) - expect(body_as_json).to include({ + expect(response.parsed_body).to include({ source: hash_including({ discoverable: false, indexable: false, @@ -37,7 +37,7 @@ RSpec.describe 'credentials API' do expect(response).to have_http_status(200) - expect(body_as_json).to include({ + expect(response.parsed_body).to include({ locked: true, }) end @@ -93,7 +93,7 @@ RSpec.describe 'credentials API' do expect(response) .to have_http_status(200) - expect(body_as_json).to include({ + expect(response.parsed_body).to include({ source: hash_including({ discoverable: true, indexable: true, diff --git a/spec/requests/api/v1/accounts/familiar_followers_spec.rb b/spec/requests/api/v1/accounts/familiar_followers_spec.rb index 475f1b17e4..8edfa4c883 100644 --- a/spec/requests/api/v1/accounts/familiar_followers_spec.rb +++ b/spec/requests/api/v1/accounts/familiar_followers_spec.rb @@ -24,7 +24,7 @@ RSpec.describe 'Accounts Familiar Followers API' do account_ids = [account_a, account_b, account_b, account_a, account_a].map { |a| a.id.to_s } get '/api/v1/accounts/familiar_followers', params: { id: account_ids }, headers: headers - expect(body_as_json.pluck(:id)).to contain_exactly(account_a.id.to_s, account_b.id.to_s) + expect(response.parsed_body.pluck(:id)).to contain_exactly(account_a.id.to_s, account_b.id.to_s) end end end diff --git a/spec/requests/api/v1/accounts/featured_tags_spec.rb b/spec/requests/api/v1/accounts/featured_tags_spec.rb index bae7d448b6..f48ed01def 100644 --- a/spec/requests/api/v1/accounts/featured_tags_spec.rb +++ b/spec/requests/api/v1/accounts/featured_tags_spec.rb @@ -23,7 +23,7 @@ RSpec.describe 'account featured tags API' do subject expect(response).to have_http_status(200) - expect(body_as_json).to contain_exactly(a_hash_including({ + expect(response.parsed_body).to contain_exactly(a_hash_including({ name: 'bar', url: "https://cb6e6126.ngrok.io/@#{account.username}/tagged/bar", }), a_hash_including({ @@ -37,7 +37,7 @@ RSpec.describe 'account featured tags API' do subject expect(response).to have_http_status(200) - expect(body_as_json).to contain_exactly(a_hash_including({ + expect(response.parsed_body).to contain_exactly(a_hash_including({ name: 'bar', url: "https://cb6e6126.ngrok.io/@#{account.pretty_acct}/tagged/bar", }), a_hash_including({ diff --git a/spec/requests/api/v1/accounts/follower_accounts_spec.rb b/spec/requests/api/v1/accounts/follower_accounts_spec.rb index 400b1c7aff..2672615390 100644 --- a/spec/requests/api/v1/accounts/follower_accounts_spec.rb +++ b/spec/requests/api/v1/accounts/follower_accounts_spec.rb @@ -21,8 +21,8 @@ RSpec.describe 'API V1 Accounts FollowerAccounts' do get "/api/v1/accounts/#{account.id}/followers", params: { limit: 2 }, headers: headers expect(response).to have_http_status(200) - expect(body_as_json.size).to eq 2 - expect([body_as_json[0][:id], body_as_json[1][:id]]).to contain_exactly(alice.id.to_s, bob.id.to_s) + expect(response.parsed_body.size).to eq 2 + expect([response.parsed_body[0][:id], response.parsed_body[1][:id]]).to contain_exactly(alice.id.to_s, bob.id.to_s) end it 'does not return blocked users', :aggregate_failures do @@ -30,8 +30,8 @@ RSpec.describe 'API V1 Accounts FollowerAccounts' do get "/api/v1/accounts/#{account.id}/followers", params: { limit: 2 }, headers: headers expect(response).to have_http_status(200) - expect(body_as_json.size).to eq 1 - expect(body_as_json[0][:id]).to eq alice.id.to_s + expect(response.parsed_body.size).to eq 1 + expect(response.parsed_body[0][:id]).to eq alice.id.to_s end context 'when requesting user is blocked' do @@ -41,7 +41,7 @@ RSpec.describe 'API V1 Accounts FollowerAccounts' do it 'hides results' do get "/api/v1/accounts/#{account.id}/followers", params: { limit: 2 }, headers: headers - expect(body_as_json.size).to eq 0 + expect(response.parsed_body.size).to eq 0 end end @@ -52,8 +52,8 @@ RSpec.describe 'API V1 Accounts FollowerAccounts' do account.mute!(bob) get "/api/v1/accounts/#{account.id}/followers", params: { limit: 2 }, headers: headers - expect(body_as_json.size).to eq 2 - expect([body_as_json[0][:id], body_as_json[1][:id]]).to contain_exactly(alice.id.to_s, bob.id.to_s) + expect(response.parsed_body.size).to eq 2 + expect([response.parsed_body[0][:id], response.parsed_body[1][:id]]).to contain_exactly(alice.id.to_s, bob.id.to_s) end end end diff --git a/spec/requests/api/v1/accounts/following_accounts_spec.rb b/spec/requests/api/v1/accounts/following_accounts_spec.rb index b0bb5141ca..19105ebf2f 100644 --- a/spec/requests/api/v1/accounts/following_accounts_spec.rb +++ b/spec/requests/api/v1/accounts/following_accounts_spec.rb @@ -21,8 +21,8 @@ RSpec.describe 'API V1 Accounts FollowingAccounts' do get "/api/v1/accounts/#{account.id}/following", params: { limit: 2 }, headers: headers expect(response).to have_http_status(200) - expect(body_as_json.size).to eq 2 - expect([body_as_json[0][:id], body_as_json[1][:id]]).to contain_exactly(alice.id.to_s, bob.id.to_s) + expect(response.parsed_body.size).to eq 2 + expect([response.parsed_body[0][:id], response.parsed_body[1][:id]]).to contain_exactly(alice.id.to_s, bob.id.to_s) end it 'does not return blocked users', :aggregate_failures do @@ -30,8 +30,8 @@ RSpec.describe 'API V1 Accounts FollowingAccounts' do get "/api/v1/accounts/#{account.id}/following", params: { limit: 2 }, headers: headers expect(response).to have_http_status(200) - expect(body_as_json.size).to eq 1 - expect(body_as_json[0][:id]).to eq alice.id.to_s + expect(response.parsed_body.size).to eq 1 + expect(response.parsed_body[0][:id]).to eq alice.id.to_s end context 'when requesting user is blocked' do @@ -41,7 +41,7 @@ RSpec.describe 'API V1 Accounts FollowingAccounts' do it 'hides results' do get "/api/v1/accounts/#{account.id}/following", params: { limit: 2 }, headers: headers - expect(body_as_json.size).to eq 0 + expect(response.parsed_body.size).to eq 0 end end @@ -52,8 +52,8 @@ RSpec.describe 'API V1 Accounts FollowingAccounts' do account.mute!(bob) get "/api/v1/accounts/#{account.id}/following", params: { limit: 2 }, headers: headers - expect(body_as_json.size).to eq 2 - expect([body_as_json[0][:id], body_as_json[1][:id]]).to contain_exactly(alice.id.to_s, bob.id.to_s) + expect(response.parsed_body.size).to eq 2 + expect([response.parsed_body[0][:id], response.parsed_body[1][:id]]).to contain_exactly(alice.id.to_s, bob.id.to_s) end end end diff --git a/spec/requests/api/v1/accounts/relationships_spec.rb b/spec/requests/api/v1/accounts/relationships_spec.rb index 76b1830bbe..9570d1214c 100644 --- a/spec/requests/api/v1/accounts/relationships_spec.rb +++ b/spec/requests/api/v1/accounts/relationships_spec.rb @@ -29,7 +29,7 @@ RSpec.describe 'GET /api/v1/accounts/relationships' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_an(Enumerable) .and contain_exactly( include( @@ -50,7 +50,7 @@ RSpec.describe 'GET /api/v1/accounts/relationships' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_an(Enumerable) .and have_attributes( size: 2 @@ -70,7 +70,7 @@ RSpec.describe 'GET /api/v1/accounts/relationships' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_an(Enumerable) .and have_attributes( size: 3 @@ -89,7 +89,7 @@ RSpec.describe 'GET /api/v1/accounts/relationships' do it 'removes duplicate account IDs from params' do subject - expect(body_as_json) + expect(response.parsed_body) .to be_an(Enumerable) .and have_attributes( size: 2 @@ -141,7 +141,7 @@ RSpec.describe 'GET /api/v1/accounts/relationships' do it 'returns JSON with correct data on previously cached requests' do # Initial request including multiple accounts in params get '/api/v1/accounts/relationships', headers: headers, params: { id: [simon.id, lewis.id] } - expect(body_as_json) + expect(response.parsed_body) .to have_attributes(size: 2) # Subsequent request with different id, should override cache from first request @@ -150,7 +150,7 @@ RSpec.describe 'GET /api/v1/accounts/relationships' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_an(Enumerable) .and have_attributes( size: 1 @@ -172,7 +172,7 @@ RSpec.describe 'GET /api/v1/accounts/relationships' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_an(Enumerable) .and contain_exactly( include( diff --git a/spec/requests/api/v1/accounts/statuses_spec.rb b/spec/requests/api/v1/accounts/statuses_spec.rb index 4a4d9383db..e056a78901 100644 --- a/spec/requests/api/v1/accounts/statuses_spec.rb +++ b/spec/requests/api/v1/accounts/statuses_spec.rb @@ -41,7 +41,7 @@ RSpec.describe 'API V1 Accounts Statuses' do it 'returns posts along with self replies', :aggregate_failures do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to have_attributes(size: 2) .and contain_exactly( include(id: status.id.to_s), @@ -102,7 +102,7 @@ RSpec.describe 'API V1 Accounts Statuses' do it 'lists the public status only' do get "/api/v1/accounts/#{account.id}/statuses", params: { pinned: true }, headers: headers - expect(body_as_json) + expect(response.parsed_body) .to contain_exactly( a_hash_including(id: status.id.to_s) ) @@ -117,7 +117,7 @@ RSpec.describe 'API V1 Accounts Statuses' do it 'lists both the public and the private statuses' do get "/api/v1/accounts/#{account.id}/statuses", params: { pinned: true }, headers: headers - expect(body_as_json) + expect(response.parsed_body) .to contain_exactly( a_hash_including(id: status.id.to_s), a_hash_including(id: private_status.id.to_s) diff --git a/spec/requests/api/v1/accounts_spec.rb b/spec/requests/api/v1/accounts_spec.rb index e31644352b..2ebe56fa7d 100644 --- a/spec/requests/api/v1/accounts_spec.rb +++ b/spec/requests/api/v1/accounts_spec.rb @@ -17,7 +17,7 @@ RSpec.describe '/api/v1/accounts' do get '/api/v1/accounts', headers: headers, params: { id: [account.id, other_account.id, 123_123] } expect(response).to have_http_status(200) - expect(body_as_json).to contain_exactly( + expect(response.parsed_body).to contain_exactly( hash_including(id: account.id.to_s), hash_including(id: other_account.id.to_s) ) @@ -32,7 +32,7 @@ RSpec.describe '/api/v1/accounts' do get "/api/v1/accounts/#{account.id}" expect(response).to have_http_status(200) - expect(body_as_json[:id]).to eq(account.id.to_s) + expect(response.parsed_body[:id]).to eq(account.id.to_s) end end @@ -41,7 +41,7 @@ RSpec.describe '/api/v1/accounts' do get '/api/v1/accounts/1' expect(response).to have_http_status(404) - expect(body_as_json[:error]).to eq('Record not found') + expect(response.parsed_body[:error]).to eq('Record not found') end end @@ -57,7 +57,7 @@ RSpec.describe '/api/v1/accounts' do subject expect(response).to have_http_status(200) - expect(body_as_json[:id]).to eq(account.id.to_s) + expect(response.parsed_body[:id]).to eq(account.id.to_s) end it_behaves_like 'forbidden for wrong scope', 'write:statuses' @@ -80,7 +80,7 @@ RSpec.describe '/api/v1/accounts' do subject expect(response).to have_http_status(200) - expect(body_as_json[:access_token]).to_not be_blank + expect(response.parsed_body[:access_token]).to_not be_blank user = User.find_by(email: 'hello@world.tld') expect(user).to_not be_nil @@ -114,7 +114,7 @@ RSpec.describe '/api/v1/accounts' do expect(response).to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to include( following: true, requested: false @@ -134,7 +134,7 @@ RSpec.describe '/api/v1/accounts' do expect(response).to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to include( following: false, requested: true @@ -157,7 +157,7 @@ RSpec.describe '/api/v1/accounts' do it 'changes reblogs option' do post "/api/v1/accounts/#{other_account.id}/follow", headers: headers, params: { reblogs: true } - expect(body_as_json).to include({ + expect(response.parsed_body).to include({ following: true, showing_reblogs: true, notifying: false, @@ -167,7 +167,7 @@ RSpec.describe '/api/v1/accounts' do it 'changes notify option' do post "/api/v1/accounts/#{other_account.id}/follow", headers: headers, params: { notify: true } - expect(body_as_json).to include({ + expect(response.parsed_body).to include({ following: true, showing_reblogs: false, notifying: true, @@ -177,7 +177,7 @@ RSpec.describe '/api/v1/accounts' do it 'changes languages option' do post "/api/v1/accounts/#{other_account.id}/follow", headers: headers, params: { languages: %w(en es) } - expect(body_as_json).to include({ + expect(response.parsed_body).to include({ following: true, showing_reblogs: false, notifying: false, diff --git a/spec/requests/api/v1/admin/accounts_spec.rb b/spec/requests/api/v1/admin/accounts_spec.rb index 1615581f0e..2dc45d5eb2 100644 --- a/spec/requests/api/v1/admin/accounts_spec.rb +++ b/spec/requests/api/v1/admin/accounts_spec.rb @@ -19,7 +19,7 @@ RSpec.describe 'Accounts' do subject expect(response).to have_http_status(200) - expect(body_as_json.pluck(:id)).to match_array(expected_results.map { |a| a.id.to_s }) + expect(response.parsed_body.pluck(:id)).to match_array(expected_results.map { |a| a.id.to_s }) end end @@ -93,7 +93,7 @@ RSpec.describe 'Accounts' do subject expect(response).to have_http_status(200) - expect(body_as_json.size).to eq(params[:limit]) + expect(response.parsed_body.size).to eq(params[:limit]) end end end @@ -112,7 +112,7 @@ RSpec.describe 'Accounts' do subject expect(response).to have_http_status(200) - expect(body_as_json).to match( + expect(response.parsed_body).to match( a_hash_including(id: account.id.to_s, username: account.username, email: account.user.email) ) end diff --git a/spec/requests/api/v1/admin/canonical_email_blocks_spec.rb b/spec/requests/api/v1/admin/canonical_email_blocks_spec.rb index 0cddf2c69e..dd7e119911 100644 --- a/spec/requests/api/v1/admin/canonical_email_blocks_spec.rb +++ b/spec/requests/api/v1/admin/canonical_email_blocks_spec.rb @@ -30,7 +30,7 @@ RSpec.describe 'Canonical Email Blocks' do it 'returns an empty list' do subject - expect(body_as_json).to be_empty + expect(response.parsed_body).to be_empty end end @@ -41,7 +41,7 @@ RSpec.describe 'Canonical Email Blocks' do it 'returns the correct canonical email hashes' do subject - expect(body_as_json.pluck(:canonical_email_hash)).to match_array(expected_email_hashes) + expect(response.parsed_body.pluck(:canonical_email_hash)).to match_array(expected_email_hashes) end context 'with limit param' do @@ -50,7 +50,7 @@ RSpec.describe 'Canonical Email Blocks' do it 'returns only the requested number of canonical email blocks' do subject - expect(body_as_json.size).to eq(params[:limit]) + expect(response.parsed_body.size).to eq(params[:limit]) end end @@ -62,7 +62,7 @@ RSpec.describe 'Canonical Email Blocks' do canonical_email_blocks_ids = canonical_email_blocks.pluck(:id).map(&:to_s) - expect(body_as_json.pluck(:id)).to match_array(canonical_email_blocks_ids[2..]) + expect(response.parsed_body.pluck(:id)).to match_array(canonical_email_blocks_ids[2..]) end end @@ -74,7 +74,7 @@ RSpec.describe 'Canonical Email Blocks' do canonical_email_blocks_ids = canonical_email_blocks.pluck(:id).map(&:to_s) - expect(body_as_json.pluck(:id)).to match_array(canonical_email_blocks_ids[..2]) + expect(response.parsed_body.pluck(:id)).to match_array(canonical_email_blocks_ids[..2]) end end end @@ -96,7 +96,7 @@ RSpec.describe 'Canonical Email Blocks' do subject expect(response).to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to include( id: eq(canonical_email_block.id.to_s), canonical_email_hash: eq(canonical_email_block.canonical_email_hash) @@ -142,7 +142,7 @@ RSpec.describe 'Canonical Email Blocks' do subject expect(response).to have_http_status(200) - expect(body_as_json[0][:canonical_email_hash]).to eq(canonical_email_block.canonical_email_hash) + expect(response.parsed_body.first[:canonical_email_hash]).to eq(canonical_email_block.canonical_email_hash) end end @@ -151,7 +151,7 @@ RSpec.describe 'Canonical Email Blocks' do subject expect(response).to have_http_status(200) - expect(body_as_json).to be_empty + expect(response.parsed_body).to be_empty end end end @@ -173,7 +173,7 @@ RSpec.describe 'Canonical Email Blocks' do subject expect(response).to have_http_status(200) - expect(body_as_json[:canonical_email_hash]).to eq(canonical_email_block.canonical_email_hash) + expect(response.parsed_body[:canonical_email_hash]).to eq(canonical_email_block.canonical_email_hash) end context 'when the required email param is not provided' do @@ -193,7 +193,7 @@ RSpec.describe 'Canonical Email Blocks' do subject expect(response).to have_http_status(200) - expect(body_as_json[:canonical_email_hash]).to eq(params[:canonical_email_hash]) + expect(response.parsed_body[:canonical_email_hash]).to eq(params[:canonical_email_hash]) end end @@ -204,7 +204,7 @@ RSpec.describe 'Canonical Email Blocks' do subject expect(response).to have_http_status(200) - expect(body_as_json[:canonical_email_hash]).to eq(canonical_email_block.canonical_email_hash) + expect(response.parsed_body[:canonical_email_hash]).to eq(canonical_email_block.canonical_email_hash) end end diff --git a/spec/requests/api/v1/admin/dimensions_spec.rb b/spec/requests/api/v1/admin/dimensions_spec.rb index 43e2db00c5..a28c2a9e3e 100644 --- a/spec/requests/api/v1/admin/dimensions_spec.rb +++ b/spec/requests/api/v1/admin/dimensions_spec.rb @@ -27,7 +27,7 @@ RSpec.describe 'Admin Dimensions' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_an(Array) end end diff --git a/spec/requests/api/v1/admin/domain_allows_spec.rb b/spec/requests/api/v1/admin/domain_allows_spec.rb index b8f0b0055c..26c962b347 100644 --- a/spec/requests/api/v1/admin/domain_allows_spec.rb +++ b/spec/requests/api/v1/admin/domain_allows_spec.rb @@ -30,7 +30,7 @@ RSpec.describe 'Domain Allows' do it 'returns an empty body' do subject - expect(body_as_json).to be_empty + expect(response.parsed_body).to be_empty end end @@ -49,7 +49,7 @@ RSpec.describe 'Domain Allows' do it 'returns the correct allowed domains' do subject - expect(body_as_json).to match_array(expected_response) + expect(response.parsed_body).to match_array(expected_response) end context 'with limit param' do @@ -58,7 +58,7 @@ RSpec.describe 'Domain Allows' do it 'returns only the requested number of allowed domains' do subject - expect(body_as_json.size).to eq(params[:limit]) + expect(response.parsed_body.size).to eq(params[:limit]) end end end @@ -79,7 +79,7 @@ RSpec.describe 'Domain Allows' do subject expect(response).to have_http_status(200) - expect(body_as_json[:domain]).to eq domain_allow.domain + expect(response.parsed_body[:domain]).to eq domain_allow.domain end context 'when the requested allowed domain does not exist' do @@ -107,7 +107,7 @@ RSpec.describe 'Domain Allows' do subject expect(response).to have_http_status(200) - expect(body_as_json[:domain]).to eq 'foo.bar.com' + expect(response.parsed_body[:domain]).to eq 'foo.bar.com' expect(DomainAllow.find_by(domain: 'foo.bar.com')).to be_present end end @@ -140,7 +140,7 @@ RSpec.describe 'Domain Allows' do it 'returns the existing allowed domain name' do subject - expect(body_as_json[:domain]).to eq(params[:domain]) + expect(response.parsed_body[:domain]).to eq(params[:domain]) end end end diff --git a/spec/requests/api/v1/admin/domain_blocks_spec.rb b/spec/requests/api/v1/admin/domain_blocks_spec.rb index 7f7b9aa48a..3f2cbbf113 100644 --- a/spec/requests/api/v1/admin/domain_blocks_spec.rb +++ b/spec/requests/api/v1/admin/domain_blocks_spec.rb @@ -30,7 +30,7 @@ RSpec.describe 'Domain Blocks' do it 'returns an empty list' do subject - expect(body_as_json).to be_empty + expect(response.parsed_body).to be_empty end end @@ -64,7 +64,7 @@ RSpec.describe 'Domain Blocks' do it 'returns the expected domain blocks' do subject - expect(body_as_json).to match_array(expected_responde) + expect(response.parsed_body).to match_array(expected_responde) end context 'with limit param' do @@ -73,7 +73,7 @@ RSpec.describe 'Domain Blocks' do it 'returns only the requested number of domain blocks' do subject - expect(body_as_json.size).to eq(params[:limit]) + expect(response.parsed_body.size).to eq(params[:limit]) end end end @@ -94,19 +94,17 @@ RSpec.describe 'Domain Blocks' do subject expect(response).to have_http_status(200) - expect(body_as_json).to match( - { - id: domain_block.id.to_s, - domain: domain_block.domain, - digest: domain_block.domain_digest, - created_at: domain_block.created_at.strftime('%Y-%m-%dT%H:%M:%S.%LZ'), - severity: domain_block.severity.to_s, - reject_media: domain_block.reject_media, - reject_reports: domain_block.reject_reports, - private_comment: domain_block.private_comment, - public_comment: domain_block.public_comment, - obfuscate: domain_block.obfuscate, - } + expect(response.parsed_body).to match( + id: domain_block.id.to_s, + domain: domain_block.domain, + digest: domain_block.domain_digest, + created_at: domain_block.created_at.strftime('%Y-%m-%dT%H:%M:%S.%LZ'), + severity: domain_block.severity.to_s, + reject_media: domain_block.reject_media, + reject_reports: domain_block.reject_reports, + private_comment: domain_block.private_comment, + public_comment: domain_block.public_comment, + obfuscate: domain_block.obfuscate ) end @@ -134,7 +132,7 @@ RSpec.describe 'Domain Blocks' do subject expect(response).to have_http_status(200) - expect(body_as_json).to match a_hash_including( + expect(response.parsed_body).to match a_hash_including( { domain: 'foo.bar.com', severity: 'silence', @@ -155,7 +153,7 @@ RSpec.describe 'Domain Blocks' do subject expect(response).to have_http_status(200) - expect(body_as_json).to match a_hash_including( + expect(response.parsed_body).to match a_hash_including( { domain: 'foo.bar.com', severity: 'suspend', @@ -175,7 +173,7 @@ RSpec.describe 'Domain Blocks' do subject expect(response).to have_http_status(422) - expect(body_as_json[:existing_domain_block][:domain]).to eq('foo.bar.com') + expect(response.parsed_body[:existing_domain_block][:domain]).to eq('foo.bar.com') end end @@ -188,7 +186,7 @@ RSpec.describe 'Domain Blocks' do subject expect(response).to have_http_status(422) - expect(body_as_json[:existing_domain_block][:domain]).to eq('bar.com') + expect(response.parsed_body[:existing_domain_block][:domain]).to eq('bar.com') end end @@ -219,7 +217,7 @@ RSpec.describe 'Domain Blocks' do subject expect(response).to have_http_status(200) - expect(body_as_json).to match a_hash_including( + expect(response.parsed_body).to match a_hash_including( { id: domain_block.id.to_s, domain: domain_block.domain, diff --git a/spec/requests/api/v1/admin/email_domain_blocks_spec.rb b/spec/requests/api/v1/admin/email_domain_blocks_spec.rb index 16656e0202..aa3073341a 100644 --- a/spec/requests/api/v1/admin/email_domain_blocks_spec.rb +++ b/spec/requests/api/v1/admin/email_domain_blocks_spec.rb @@ -31,7 +31,7 @@ RSpec.describe 'Email Domain Blocks' do it 'returns an empty list' do subject - expect(body_as_json).to be_empty + expect(response.parsed_body).to be_empty end end @@ -42,7 +42,7 @@ RSpec.describe 'Email Domain Blocks' do it 'return the correct blocked email domains' do subject - expect(body_as_json.pluck(:domain)).to match_array(blocked_email_domains) + expect(response.parsed_body.pluck(:domain)).to match_array(blocked_email_domains) end context 'with limit param' do @@ -51,7 +51,7 @@ RSpec.describe 'Email Domain Blocks' do it 'returns only the requested number of email domain blocks' do subject - expect(body_as_json.size).to eq(params[:limit]) + expect(response.parsed_body.size).to eq(params[:limit]) end end @@ -63,7 +63,7 @@ RSpec.describe 'Email Domain Blocks' do email_domain_blocks_ids = email_domain_blocks.pluck(:id).map(&:to_s) - expect(body_as_json.pluck(:id)).to match_array(email_domain_blocks_ids[2..]) + expect(response.parsed_body.pluck(:id)).to match_array(email_domain_blocks_ids[2..]) end end @@ -75,7 +75,7 @@ RSpec.describe 'Email Domain Blocks' do email_domain_blocks_ids = email_domain_blocks.pluck(:id).map(&:to_s) - expect(body_as_json.pluck(:id)).to match_array(email_domain_blocks_ids[..2]) + expect(response.parsed_body.pluck(:id)).to match_array(email_domain_blocks_ids[..2]) end end end @@ -97,7 +97,7 @@ RSpec.describe 'Email Domain Blocks' do subject expect(response).to have_http_status(200) - expect(body_as_json[:domain]).to eq(email_domain_block.domain) + expect(response.parsed_body[:domain]).to eq(email_domain_block.domain) end end @@ -125,7 +125,7 @@ RSpec.describe 'Email Domain Blocks' do subject expect(response).to have_http_status(200) - expect(body_as_json[:domain]).to eq(params[:domain]) + expect(response.parsed_body[:domain]).to eq(params[:domain]) end context 'when domain param is not provided' do @@ -176,7 +176,7 @@ RSpec.describe 'Email Domain Blocks' do subject expect(response).to have_http_status(200) - expect(body_as_json).to be_empty + expect(response.parsed_body).to be_empty expect(EmailDomainBlock.find_by(id: email_domain_block.id)).to be_nil end diff --git a/spec/requests/api/v1/admin/ip_blocks_spec.rb b/spec/requests/api/v1/admin/ip_blocks_spec.rb index bd4015b2d9..b18f8f885c 100644 --- a/spec/requests/api/v1/admin/ip_blocks_spec.rb +++ b/spec/requests/api/v1/admin/ip_blocks_spec.rb @@ -30,7 +30,7 @@ RSpec.describe 'IP Blocks' do it 'returns an empty body' do subject - expect(body_as_json).to be_empty + expect(response.parsed_body).to be_empty end end @@ -58,7 +58,7 @@ RSpec.describe 'IP Blocks' do it 'returns the correct blocked ips' do subject - expect(body_as_json).to match_array(expected_response) + expect(response.parsed_body).to match_array(expected_response) end context 'with limit param' do @@ -67,7 +67,7 @@ RSpec.describe 'IP Blocks' do it 'returns only the requested number of ip blocks' do subject - expect(body_as_json.size).to eq(params[:limit]) + expect(response.parsed_body.size).to eq(params[:limit]) end end end @@ -89,7 +89,7 @@ RSpec.describe 'IP Blocks' do expect(response).to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to include( ip: eq("#{ip_block.ip}/#{ip_block.ip.prefix}"), severity: eq(ip_block.severity.to_s) @@ -120,7 +120,7 @@ RSpec.describe 'IP Blocks' do subject expect(response).to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to include( ip: eq("#{params[:ip]}/32"), severity: eq(params[:severity]), @@ -185,7 +185,7 @@ RSpec.describe 'IP Blocks' do .and change_comment_value expect(response).to have_http_status(200) - expect(body_as_json).to match(hash_including({ + expect(response.parsed_body).to match(hash_including({ ip: "#{ip_block.ip}/#{ip_block.ip.prefix}", severity: 'sign_up_requires_approval', comment: 'Decreasing severity', @@ -220,7 +220,7 @@ RSpec.describe 'IP Blocks' do subject expect(response).to have_http_status(200) - expect(body_as_json).to be_empty + expect(response.parsed_body).to be_empty expect(IpBlock.find_by(id: ip_block.id)).to be_nil end diff --git a/spec/requests/api/v1/admin/measures_spec.rb b/spec/requests/api/v1/admin/measures_spec.rb index 56a2c1eaee..de359a5ccd 100644 --- a/spec/requests/api/v1/admin/measures_spec.rb +++ b/spec/requests/api/v1/admin/measures_spec.rb @@ -44,7 +44,7 @@ RSpec.describe 'Admin Measures' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_an(Array) end end diff --git a/spec/requests/api/v1/admin/reports_spec.rb b/spec/requests/api/v1/admin/reports_spec.rb index 4b0b7e1713..2c40f56dc8 100644 --- a/spec/requests/api/v1/admin/reports_spec.rb +++ b/spec/requests/api/v1/admin/reports_spec.rb @@ -29,7 +29,7 @@ RSpec.describe 'Reports' do it 'returns an empty list' do subject - expect(body_as_json).to be_empty + expect(response.parsed_body).to be_empty end end @@ -64,7 +64,7 @@ RSpec.describe 'Reports' do it 'returns all unresolved reports' do subject - expect(body_as_json).to match_array(expected_response) + expect(response.parsed_body).to match_array(expected_response) end context 'with resolved param' do @@ -74,7 +74,7 @@ RSpec.describe 'Reports' do it 'returns only the resolved reports' do subject - expect(body_as_json).to match_array(expected_response) + expect(response.parsed_body).to match_array(expected_response) end end @@ -85,7 +85,7 @@ RSpec.describe 'Reports' do it 'returns all unresolved reports filed by the specified account' do subject - expect(body_as_json).to match_array(expected_response) + expect(response.parsed_body).to match_array(expected_response) end end @@ -96,7 +96,7 @@ RSpec.describe 'Reports' do it 'returns all unresolved reports targeting the specified account' do subject - expect(body_as_json).to match_array(expected_response) + expect(response.parsed_body).to match_array(expected_response) end end @@ -106,7 +106,7 @@ RSpec.describe 'Reports' do it 'returns only the requested number of reports' do subject - expect(body_as_json.size).to eq(1) + expect(response.parsed_body.size).to eq(1) end end end @@ -126,7 +126,7 @@ RSpec.describe 'Reports' do subject expect(response).to have_http_status(200) - expect(body_as_json).to include( + expect(response.parsed_body).to include( { id: report.id.to_s, action_taken: report.action_taken?, @@ -159,7 +159,7 @@ RSpec.describe 'Reports' do report.reload - expect(body_as_json).to include( + expect(response.parsed_body).to include( { id: report.id.to_s, action_taken: report.action_taken?, diff --git a/spec/requests/api/v1/admin/retention_spec.rb b/spec/requests/api/v1/admin/retention_spec.rb index 138959a0ab..c28fa6de81 100644 --- a/spec/requests/api/v1/admin/retention_spec.rb +++ b/spec/requests/api/v1/admin/retention_spec.rb @@ -27,7 +27,7 @@ RSpec.describe 'Admin Retention' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_an(Array) end end diff --git a/spec/requests/api/v1/admin/tags_spec.rb b/spec/requests/api/v1/admin/tags_spec.rb index 031be17f52..2f730cdeb8 100644 --- a/spec/requests/api/v1/admin/tags_spec.rb +++ b/spec/requests/api/v1/admin/tags_spec.rb @@ -30,7 +30,7 @@ RSpec.describe 'Tags' do it 'returns an empty list' do subject - expect(body_as_json).to be_empty + expect(response.parsed_body).to be_empty end end @@ -47,7 +47,7 @@ RSpec.describe 'Tags' do it 'returns the expected tags' do subject tags.each do |tag| - expect(body_as_json.find { |item| item[:id] == tag.id.to_s && item[:name] == tag.name }).to_not be_nil + expect(response.parsed_body.find { |item| item[:id] == tag.id.to_s && item[:name] == tag.name }).to_not be_nil end end @@ -57,7 +57,7 @@ RSpec.describe 'Tags' do it 'returns only the requested number of tags' do subject - expect(body_as_json.size).to eq(params[:limit]) + expect(response.parsed_body.size).to eq(params[:limit]) end end end @@ -82,8 +82,8 @@ RSpec.describe 'Tags' do it 'returns expected tag content' do subject - expect(body_as_json[:id].to_i).to eq(tag.id) - expect(body_as_json[:name]).to eq(tag.name) + expect(response.parsed_body[:id].to_i).to eq(tag.id) + expect(response.parsed_body[:name]).to eq(tag.name) end context 'when the requested tag does not exist' do @@ -116,8 +116,8 @@ RSpec.describe 'Tags' do it 'returns updated tag' do subject - expect(body_as_json[:id].to_i).to eq(tag.id) - expect(body_as_json[:name]).to eq(tag.name.upcase) + expect(response.parsed_body[:id].to_i).to eq(tag.id) + expect(response.parsed_body[:name]).to eq(tag.name.upcase) end context 'when the updated display name is invalid' do diff --git a/spec/requests/api/v1/admin/trends/links/links_spec.rb b/spec/requests/api/v1/admin/trends/links/links_spec.rb index 082af785ab..c436b7081e 100644 --- a/spec/requests/api/v1/admin/trends/links/links_spec.rb +++ b/spec/requests/api/v1/admin/trends/links/links_spec.rb @@ -44,7 +44,7 @@ RSpec.describe 'Links' do end def expects_correct_link_data - expect(body_as_json).to match( + expect(response.parsed_body).to match( a_hash_including( url: preview_card.url, title: preview_card.title, @@ -98,7 +98,7 @@ RSpec.describe 'Links' do it 'returns the link data' do subject - expect(body_as_json).to match( + expect(response.parsed_body).to match( a_hash_including( url: preview_card.url, title: preview_card.title, diff --git a/spec/requests/api/v1/annual_reports_spec.rb b/spec/requests/api/v1/annual_reports_spec.rb index bab184787f..8051a65484 100644 --- a/spec/requests/api/v1/annual_reports_spec.rb +++ b/spec/requests/api/v1/annual_reports_spec.rb @@ -34,7 +34,7 @@ RSpec.describe 'API V1 Annual Reports' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_present end end diff --git a/spec/requests/api/v1/apps/credentials_spec.rb b/spec/requests/api/v1/apps/credentials_spec.rb index b899999640..1cd6a4178f 100644 --- a/spec/requests/api/v1/apps/credentials_spec.rb +++ b/spec/requests/api/v1/apps/credentials_spec.rb @@ -18,7 +18,7 @@ RSpec.describe 'Credentials' do expect(response).to have_http_status(200) - expect(body_as_json).to match( + expect(response.parsed_body).to match( a_hash_including( id: token.application.id.to_s, name: token.application.name, @@ -37,8 +37,8 @@ RSpec.describe 'Credentials' do expect(response).to have_http_status(200) - expect(body_as_json[:client_id]).to_not be_present - expect(body_as_json[:client_secret]).to_not be_present + expect(response.parsed_body[:client_id]).to_not be_present + expect(response.parsed_body[:client_secret]).to_not be_present end end @@ -56,7 +56,7 @@ RSpec.describe 'Credentials' do it 'returns the app information correctly' do subject - expect(body_as_json).to match( + expect(response.parsed_body).to match( a_hash_including( id: token.application.id.to_s, name: token.application.name, @@ -95,7 +95,7 @@ RSpec.describe 'Credentials' do it 'returns the error in the json response' do subject - expect(body_as_json).to match( + expect(response.parsed_body).to match( a_hash_including( error: 'The access token was revoked' ) @@ -117,7 +117,7 @@ RSpec.describe 'Credentials' do it 'returns the error in the json response' do subject - expect(body_as_json).to match( + expect(response.parsed_body).to match( a_hash_including( error: 'The access token is invalid' ) diff --git a/spec/requests/api/v1/apps_spec.rb b/spec/requests/api/v1/apps_spec.rb index 81d6c68126..51a0c3fd0c 100644 --- a/spec/requests/api/v1/apps_spec.rb +++ b/spec/requests/api/v1/apps_spec.rb @@ -35,7 +35,7 @@ RSpec.describe 'Apps' do expect(app.scopes.to_s).to eq scopes expect(app.redirect_uris).to eq redirect_uris - expect(body_as_json).to match( + expect(response.parsed_body).to match( a_hash_including( id: app.id.to_s, client_id: app.uid, @@ -61,7 +61,7 @@ RSpec.describe 'Apps' do expect(response).to have_http_status(200) expect(Doorkeeper::Application.find_by(name: client_name)).to be_present - expect(body_as_json) + expect(response.parsed_body) .to include( scopes: Doorkeeper.config.default_scopes.to_a ) @@ -82,7 +82,7 @@ RSpec.describe 'Apps' do expect(app).to be_present expect(app.scopes.to_s).to eq 'read' - expect(body_as_json) + expect(response.parsed_body) .to include( scopes: %w(read) ) @@ -165,7 +165,7 @@ RSpec.describe 'Apps' do expect(app.redirect_uri).to eq redirect_uris expect(app.redirect_uris).to eq redirect_uris.split - expect(body_as_json) + expect(response.parsed_body) .to include( redirect_uri: redirect_uris, redirect_uris: redirect_uris.split @@ -187,7 +187,7 @@ RSpec.describe 'Apps' do expect(app.redirect_uri).to eq redirect_uris.join "\n" expect(app.redirect_uris).to eq redirect_uris - expect(body_as_json) + expect(response.parsed_body) .to include( redirect_uri: redirect_uris.join("\n"), redirect_uris: redirect_uris diff --git a/spec/requests/api/v1/blocks_spec.rb b/spec/requests/api/v1/blocks_spec.rb index 06d2c4d997..d2f1c46a5b 100644 --- a/spec/requests/api/v1/blocks_spec.rb +++ b/spec/requests/api/v1/blocks_spec.rb @@ -26,7 +26,7 @@ RSpec.describe 'Blocks' do subject expect(response).to have_http_status(200) - expect(body_as_json).to match_array(expected_response) + expect(response.parsed_body).to match_array(expected_response) end context 'with limit param' do @@ -35,7 +35,7 @@ RSpec.describe 'Blocks' do it 'returns only the requested number of blocked accounts' do subject - expect(body_as_json.size).to eq(params[:limit]) + expect(response.parsed_body.size).to eq(params[:limit]) end it 'sets correct link header pagination' do @@ -55,7 +55,7 @@ RSpec.describe 'Blocks' do it 'queries the blocks in range according to max_id', :aggregate_failures do subject - expect(body_as_json) + expect(response.parsed_body) .to contain_exactly(include(id: blocks.first.target_account.id.to_s)) end end @@ -66,7 +66,7 @@ RSpec.describe 'Blocks' do it 'queries the blocks in range according to since_id', :aggregate_failures do subject - expect(body_as_json) + expect(response.parsed_body) .to contain_exactly(include(id: blocks[2].target_account.id.to_s)) end end diff --git a/spec/requests/api/v1/bookmarks_spec.rb b/spec/requests/api/v1/bookmarks_spec.rb index dc32820c89..95a71abcac 100644 --- a/spec/requests/api/v1/bookmarks_spec.rb +++ b/spec/requests/api/v1/bookmarks_spec.rb @@ -33,7 +33,7 @@ RSpec.describe 'Bookmarks' do it 'returns the bookmarked statuses' do subject - expect(body_as_json).to match_array(expected_response) + expect(response.parsed_body).to match_array(expected_response) end context 'with limit param' do @@ -42,7 +42,7 @@ RSpec.describe 'Bookmarks' do it 'paginates correctly', :aggregate_failures do subject - expect(body_as_json.size) + expect(response.parsed_body.size) .to eq(params[:limit]) expect(response) diff --git a/spec/requests/api/v1/conversations_spec.rb b/spec/requests/api/v1/conversations_spec.rb index f136e1f4e8..bd3cbfd0e7 100644 --- a/spec/requests/api/v1/conversations_spec.rb +++ b/spec/requests/api/v1/conversations_spec.rb @@ -31,8 +31,8 @@ RSpec.describe 'API V1 Conversations' do it 'returns conversations', :aggregate_failures do get '/api/v1/conversations', headers: headers - expect(body_as_json.size).to eq 2 - expect(body_as_json[0][:accounts].size).to eq 1 + expect(response.parsed_body.size).to eq 2 + expect(response.parsed_body.first[:accounts].size).to eq 1 end context 'with since_id' do @@ -40,7 +40,7 @@ RSpec.describe 'API V1 Conversations' do it 'returns conversations' do get '/api/v1/conversations', params: { since_id: Mastodon::Snowflake.id_at(1.hour.ago, with_random: false) }, headers: headers - expect(body_as_json.size).to eq 2 + expect(response.parsed_body.size).to eq 2 end end @@ -48,7 +48,7 @@ RSpec.describe 'API V1 Conversations' do it 'returns no conversation' do get '/api/v1/conversations', params: { since_id: Mastodon::Snowflake.id_at(1.hour.from_now, with_random: false) }, headers: headers - expect(body_as_json.size).to eq 0 + expect(response.parsed_body.size).to eq 0 end end end diff --git a/spec/requests/api/v1/custom_emojis_spec.rb b/spec/requests/api/v1/custom_emojis_spec.rb index 798d8e29ed..0942734ff3 100644 --- a/spec/requests/api/v1/custom_emojis_spec.rb +++ b/spec/requests/api/v1/custom_emojis_spec.rb @@ -19,7 +19,7 @@ RSpec.describe 'Custom Emojis' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_present .and have_attributes( first: include(shortcode: 'coolcat') @@ -34,7 +34,7 @@ RSpec.describe 'Custom Emojis' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_present .and have_attributes( first: include(shortcode: 'coolcat') diff --git a/spec/requests/api/v1/directories_spec.rb b/spec/requests/api/v1/directories_spec.rb index 94306c06ec..aa602a71cd 100644 --- a/spec/requests/api/v1/directories_spec.rb +++ b/spec/requests/api/v1/directories_spec.rb @@ -82,8 +82,8 @@ RSpec.describe 'Directories API' do get '/api/v1/directory', headers: headers expect(response).to have_http_status(200) - expect(body_as_json.size).to eq(2) - expect(body_as_json.pluck(:id)).to contain_exactly(eligible_remote_account.id.to_s, local_discoverable_account.id.to_s) + expect(response.parsed_body.size).to eq(2) + expect(response.parsed_body.pluck(:id)).to contain_exactly(eligible_remote_account.id.to_s, local_discoverable_account.id.to_s) end end @@ -101,8 +101,8 @@ RSpec.describe 'Directories API' do get '/api/v1/directory', headers: headers, params: { local: '1' } expect(response).to have_http_status(200) - expect(body_as_json.size).to eq(1) - expect(body_as_json.first[:id]).to include(local_account.id.to_s) + expect(response.parsed_body.size).to eq(1) + expect(response.parsed_body.first[:id]).to include(local_account.id.to_s) expect(response.body).to_not include(remote_account.id.to_s) end end @@ -115,9 +115,9 @@ RSpec.describe 'Directories API' do get '/api/v1/directory', headers: headers, params: { order: 'active' } expect(response).to have_http_status(200) - expect(body_as_json.size).to eq(2) - expect(body_as_json.first[:id]).to include(new_stat.account_id.to_s) - expect(body_as_json.second[:id]).to include(old_stat.account_id.to_s) + expect(response.parsed_body.size).to eq(2) + expect(response.parsed_body.first[:id]).to include(new_stat.account_id.to_s) + expect(response.parsed_body.second[:id]).to include(old_stat.account_id.to_s) end end @@ -130,9 +130,9 @@ RSpec.describe 'Directories API' do get '/api/v1/directory', headers: headers, params: { order: 'new' } expect(response).to have_http_status(200) - expect(body_as_json.size).to eq(2) - expect(body_as_json.first[:id]).to include(account_new.id.to_s) - expect(body_as_json.second[:id]).to include(account_old.id.to_s) + expect(response.parsed_body.size).to eq(2) + expect(response.parsed_body.first[:id]).to include(account_new.id.to_s) + expect(response.parsed_body.second[:id]).to include(account_old.id.to_s) end end end diff --git a/spec/requests/api/v1/domain_blocks_spec.rb b/spec/requests/api/v1/domain_blocks_spec.rb index 954497ebe1..8184c26bed 100644 --- a/spec/requests/api/v1/domain_blocks_spec.rb +++ b/spec/requests/api/v1/domain_blocks_spec.rb @@ -26,7 +26,7 @@ RSpec.describe 'Domain blocks' do subject expect(response).to have_http_status(200) - expect(body_as_json).to match_array(blocked_domains) + expect(response.parsed_body).to match_array(blocked_domains) end context 'with limit param' do @@ -35,7 +35,7 @@ RSpec.describe 'Domain blocks' do it 'returns only the requested number of blocked domains' do subject - expect(body_as_json.size).to eq(params[:limit]) + expect(response.parsed_body.size).to eq(params[:limit]) end end end diff --git a/spec/requests/api/v1/emails/confirmations_spec.rb b/spec/requests/api/v1/emails/confirmations_spec.rb index 8f5171ee78..0a419a10cf 100644 --- a/spec/requests/api/v1/emails/confirmations_spec.rb +++ b/spec/requests/api/v1/emails/confirmations_spec.rb @@ -111,7 +111,7 @@ RSpec.describe 'Confirmations' do subject expect(response).to have_http_status(200) - expect(body_as_json).to be false + expect(response.parsed_body).to be false end end @@ -122,7 +122,7 @@ RSpec.describe 'Confirmations' do subject expect(response).to have_http_status(200) - expect(body_as_json).to be true + expect(response.parsed_body).to be true end end end @@ -139,7 +139,7 @@ RSpec.describe 'Confirmations' do subject expect(response).to have_http_status(200) - expect(body_as_json).to be false + expect(response.parsed_body).to be false end end @@ -150,7 +150,7 @@ RSpec.describe 'Confirmations' do subject expect(response).to have_http_status(200) - expect(body_as_json).to be true + expect(response.parsed_body).to be true end end end diff --git a/spec/requests/api/v1/endorsements_spec.rb b/spec/requests/api/v1/endorsements_spec.rb index 255211a404..25917f527a 100644 --- a/spec/requests/api/v1/endorsements_spec.rb +++ b/spec/requests/api/v1/endorsements_spec.rb @@ -37,7 +37,7 @@ RSpec.describe 'Endorsements' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_present .and have_attributes( first: include(acct: account_pin.target_account.acct) @@ -52,7 +52,7 @@ RSpec.describe 'Endorsements' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to_not be_present end end diff --git a/spec/requests/api/v1/favourites_spec.rb b/spec/requests/api/v1/favourites_spec.rb index b988ac99db..78e9d61551 100644 --- a/spec/requests/api/v1/favourites_spec.rb +++ b/spec/requests/api/v1/favourites_spec.rb @@ -33,7 +33,7 @@ RSpec.describe 'Favourites' do it 'returns the favourites' do subject - expect(body_as_json).to match_array(expected_response) + expect(response.parsed_body).to match_array(expected_response) end context 'with limit param' do @@ -42,7 +42,7 @@ RSpec.describe 'Favourites' do it 'returns only the requested number of favourites' do subject - expect(body_as_json.size).to eq(params[:limit]) + expect(response.parsed_body.size).to eq(params[:limit]) end it 'sets the correct pagination headers' do diff --git a/spec/requests/api/v1/featured_tags/suggestions_spec.rb b/spec/requests/api/v1/featured_tags/suggestions_spec.rb index 0a7bfe5cda..8815c65cf1 100644 --- a/spec/requests/api/v1/featured_tags/suggestions_spec.rb +++ b/spec/requests/api/v1/featured_tags/suggestions_spec.rb @@ -32,7 +32,7 @@ RSpec.describe 'Featured Tags Suggestions API' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to contain_exactly( include(name: used_tag.name) ) diff --git a/spec/requests/api/v1/featured_tags_spec.rb b/spec/requests/api/v1/featured_tags_spec.rb index 81e99e015b..423cc0c560 100644 --- a/spec/requests/api/v1/featured_tags_spec.rb +++ b/spec/requests/api/v1/featured_tags_spec.rb @@ -37,7 +37,7 @@ RSpec.describe 'FeaturedTags' do it 'returns an empty body' do get '/api/v1/featured_tags', headers: headers - expect(body_as_json).to be_empty + expect(response.parsed_body).to be_empty end end @@ -47,7 +47,7 @@ RSpec.describe 'FeaturedTags' do it 'returns only the featured tags belonging to the requesting user' do get '/api/v1/featured_tags', headers: headers - expect(body_as_json.pluck(:id)) + expect(response.parsed_body.pluck(:id)) .to match_array( user_featured_tags.pluck(:id).map(&:to_s) ) @@ -67,7 +67,7 @@ RSpec.describe 'FeaturedTags' do it 'returns the correct tag name' do post '/api/v1/featured_tags', headers: headers, params: params - expect(body_as_json) + expect(response.parsed_body) .to include( name: params[:name] ) @@ -141,7 +141,7 @@ RSpec.describe 'FeaturedTags' do it 'returns an empty body' do delete "/api/v1/featured_tags/#{id}", headers: headers - expect(body_as_json).to be_empty + expect(response.parsed_body).to be_empty end it 'deletes the featured tag', :inline_jobs do diff --git a/spec/requests/api/v1/filters_spec.rb b/spec/requests/api/v1/filters_spec.rb index deb6e74217..93ed78b346 100644 --- a/spec/requests/api/v1/filters_spec.rb +++ b/spec/requests/api/v1/filters_spec.rb @@ -15,7 +15,7 @@ RSpec.describe 'API V1 Filters' do it 'returns http success' do get '/api/v1/filters', headers: headers expect(response).to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to contain_exactly( include(id: custom_filter_keyword.id.to_s) ) diff --git a/spec/requests/api/v1/follow_requests_spec.rb b/spec/requests/api/v1/follow_requests_spec.rb index a8898ccb3e..c143ccaec1 100644 --- a/spec/requests/api/v1/follow_requests_spec.rb +++ b/spec/requests/api/v1/follow_requests_spec.rb @@ -36,7 +36,7 @@ RSpec.describe 'Follow requests' do subject expect(response).to have_http_status(200) - expect(body_as_json).to match_array(expected_response) + expect(response.parsed_body).to match_array(expected_response) end context 'with limit param' do @@ -45,7 +45,7 @@ RSpec.describe 'Follow requests' do it 'returns only the requested number of follow requests' do subject - expect(body_as_json.size).to eq(params[:limit]) + expect(response.parsed_body.size).to eq(params[:limit]) end end end @@ -66,7 +66,7 @@ RSpec.describe 'Follow requests' do it 'allows the requesting follower to follow', :aggregate_failures do expect { subject }.to change { follower.following?(user.account) }.from(false).to(true) expect(response).to have_http_status(200) - expect(body_as_json[:followed_by]).to be true + expect(response.parsed_body[:followed_by]).to be true end end @@ -88,7 +88,7 @@ RSpec.describe 'Follow requests' do expect(response).to have_http_status(200) expect(FollowRequest.where(target_account: user.account, account: follower)).to_not exist - expect(body_as_json[:followed_by]).to be false + expect(response.parsed_body[:followed_by]).to be false end end end diff --git a/spec/requests/api/v1/followed_tags_spec.rb b/spec/requests/api/v1/followed_tags_spec.rb index 3d2d82d5db..f7787cb763 100644 --- a/spec/requests/api/v1/followed_tags_spec.rb +++ b/spec/requests/api/v1/followed_tags_spec.rb @@ -37,7 +37,7 @@ RSpec.describe 'Followed tags' do it 'returns the followed tags correctly' do subject - expect(body_as_json).to match_array(expected_response) + expect(response.parsed_body).to match_array(expected_response) end context 'with limit param' do @@ -46,7 +46,7 @@ RSpec.describe 'Followed tags' do it 'returns only the requested number of follow tags' do subject - expect(body_as_json.size).to eq(params[:limit]) + expect(response.parsed_body.size).to eq(params[:limit]) end it 'sets the correct pagination headers' do diff --git a/spec/requests/api/v1/instance_spec.rb b/spec/requests/api/v1/instance_spec.rb index f0a4ceadb8..8d6ba572e0 100644 --- a/spec/requests/api/v1/instance_spec.rb +++ b/spec/requests/api/v1/instance_spec.rb @@ -15,7 +15,7 @@ RSpec.describe 'Instances' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_present .and include(title: 'Mastodon') end @@ -28,7 +28,7 @@ RSpec.describe 'Instances' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_present .and include(title: 'Mastodon') end diff --git a/spec/requests/api/v1/instances/activity_spec.rb b/spec/requests/api/v1/instances/activity_spec.rb index 4f2bc91ad6..72e3faeb65 100644 --- a/spec/requests/api/v1/instances/activity_spec.rb +++ b/spec/requests/api/v1/instances/activity_spec.rb @@ -13,7 +13,7 @@ RSpec.describe 'Activity' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_present .and(be_an(Array)) .and(have_attributes(size: Api::V1::Instances::ActivityController::WEEKS_OF_ACTIVITY)) diff --git a/spec/requests/api/v1/instances/domain_blocks_spec.rb b/spec/requests/api/v1/instances/domain_blocks_spec.rb index 397ecff084..460d338607 100644 --- a/spec/requests/api/v1/instances/domain_blocks_spec.rb +++ b/spec/requests/api/v1/instances/domain_blocks_spec.rb @@ -17,7 +17,7 @@ RSpec.describe 'Domain Blocks' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_present .and(be_an(Array)) .and(have_attributes(size: 1)) diff --git a/spec/requests/api/v1/instances/extended_descriptions_spec.rb b/spec/requests/api/v1/instances/extended_descriptions_spec.rb index 64982de686..bf6d58216a 100644 --- a/spec/requests/api/v1/instances/extended_descriptions_spec.rb +++ b/spec/requests/api/v1/instances/extended_descriptions_spec.rb @@ -10,7 +10,7 @@ RSpec.describe 'Extended Descriptions' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_present .and include(:content) end diff --git a/spec/requests/api/v1/instances/languages_spec.rb b/spec/requests/api/v1/instances/languages_spec.rb index 8ab8bf99ce..79ea62c599 100644 --- a/spec/requests/api/v1/instances/languages_spec.rb +++ b/spec/requests/api/v1/instances/languages_spec.rb @@ -13,7 +13,7 @@ RSpec.describe 'Languages' do end it 'returns the supported languages' do - expect(body_as_json.pluck(:code)).to match_array LanguagesHelper::SUPPORTED_LOCALES.keys.map(&:to_s) + expect(response.parsed_body.pluck(:code)).to match_array LanguagesHelper::SUPPORTED_LOCALES.keys.map(&:to_s) end end end diff --git a/spec/requests/api/v1/instances/peers_spec.rb b/spec/requests/api/v1/instances/peers_spec.rb index 1a7975f8b7..1140612f0a 100644 --- a/spec/requests/api/v1/instances/peers_spec.rb +++ b/spec/requests/api/v1/instances/peers_spec.rb @@ -13,7 +13,7 @@ RSpec.describe 'Peers' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_an(Array) end end diff --git a/spec/requests/api/v1/instances/privacy_policies_spec.rb b/spec/requests/api/v1/instances/privacy_policies_spec.rb index 24de98d880..93490542cd 100644 --- a/spec/requests/api/v1/instances/privacy_policies_spec.rb +++ b/spec/requests/api/v1/instances/privacy_policies_spec.rb @@ -10,7 +10,7 @@ RSpec.describe 'Privacy Policy' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_present .and include(:content) end diff --git a/spec/requests/api/v1/instances/rules_spec.rb b/spec/requests/api/v1/instances/rules_spec.rb index 65b8d78c7d..620c991ae2 100644 --- a/spec/requests/api/v1/instances/rules_spec.rb +++ b/spec/requests/api/v1/instances/rules_spec.rb @@ -10,7 +10,7 @@ RSpec.describe 'Rules' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_an(Array) end end diff --git a/spec/requests/api/v1/instances/translation_languages_spec.rb b/spec/requests/api/v1/instances/translation_languages_spec.rb index e5a480c175..0de5ec3bc2 100644 --- a/spec/requests/api/v1/instances/translation_languages_spec.rb +++ b/spec/requests/api/v1/instances/translation_languages_spec.rb @@ -11,7 +11,7 @@ RSpec.describe 'Translation Languages' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to eq({}) end end @@ -25,7 +25,7 @@ RSpec.describe 'Translation Languages' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to match({ und: %w(en de), en: ['de'] }) end diff --git a/spec/requests/api/v1/lists/accounts_spec.rb b/spec/requests/api/v1/lists/accounts_spec.rb index de49982351..d147b21ee7 100644 --- a/spec/requests/api/v1/lists/accounts_spec.rb +++ b/spec/requests/api/v1/lists/accounts_spec.rb @@ -34,7 +34,7 @@ RSpec.describe 'Accounts' do subject expect(response).to have_http_status(200) - expect(body_as_json).to match_array(expected_response) + expect(response.parsed_body).to match_array(expected_response) end context 'with limit param' do @@ -43,7 +43,7 @@ RSpec.describe 'Accounts' do it 'returns only the requested number of accounts' do subject - expect(body_as_json.size).to eq(params[:limit]) + expect(response.parsed_body.size).to eq(params[:limit]) end end end diff --git a/spec/requests/api/v1/lists_spec.rb b/spec/requests/api/v1/lists_spec.rb index cf5ac28a56..2042a64d5c 100644 --- a/spec/requests/api/v1/lists_spec.rb +++ b/spec/requests/api/v1/lists_spec.rb @@ -43,7 +43,7 @@ RSpec.describe 'Lists' do subject expect(response).to have_http_status(200) - expect(body_as_json).to match_array(expected_response) + expect(response.parsed_body).to match_array(expected_response) end end @@ -60,7 +60,7 @@ RSpec.describe 'Lists' do subject expect(response).to have_http_status(200) - expect(body_as_json).to match({ + expect(response.parsed_body).to match({ id: list.id.to_s, title: list.title, replies_policy: list.replies_policy, @@ -100,7 +100,7 @@ RSpec.describe 'Lists' do subject expect(response).to have_http_status(200) - expect(body_as_json).to match(a_hash_including(title: 'my list', replies_policy: 'none', exclusive: true)) + expect(response.parsed_body).to match(a_hash_including(title: 'my list', replies_policy: 'none', exclusive: true)) expect(List.where(account: user.account).count).to eq(1) end @@ -144,7 +144,7 @@ RSpec.describe 'Lists' do expect(response).to have_http_status(200) list.reload - expect(body_as_json).to match({ + expect(response.parsed_body).to match({ id: list.id.to_s, title: list.title, replies_policy: list.replies_policy, diff --git a/spec/requests/api/v1/markers_spec.rb b/spec/requests/api/v1/markers_spec.rb index 2dbb9d205a..a10d2dc3e2 100644 --- a/spec/requests/api/v1/markers_spec.rb +++ b/spec/requests/api/v1/markers_spec.rb @@ -18,7 +18,7 @@ RSpec.describe 'API Markers' do it 'returns markers', :aggregate_failures do expect(response).to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to include( home: include(last_read_id: '123'), notifications: include(last_read_id: '456') @@ -61,7 +61,7 @@ RSpec.describe 'API Markers' do it 'returns error json' do expect(response) .to have_http_status(409) - expect(body_as_json) + expect(response.parsed_body) .to include(error: /Conflict during update/) end end diff --git a/spec/requests/api/v1/media_spec.rb b/spec/requests/api/v1/media_spec.rb index c89c49afdf..d0af334825 100644 --- a/spec/requests/api/v1/media_spec.rb +++ b/spec/requests/api/v1/media_spec.rb @@ -26,7 +26,7 @@ RSpec.describe 'Media' do it 'returns the media information' do subject - expect(body_as_json).to match( + expect(response.parsed_body).to match( a_hash_including( id: media.id.to_s, description: media.description, @@ -83,7 +83,7 @@ RSpec.describe 'Media' do expect(MediaAttachment.first).to be_present expect(MediaAttachment.first).to have_attached_file(:file) - expect(body_as_json).to match( + expect(response.parsed_body).to match( a_hash_including(id: MediaAttachment.first.id.to_s, description: params[:description], type: media_type) ) end diff --git a/spec/requests/api/v1/mutes_spec.rb b/spec/requests/api/v1/mutes_spec.rb index 988bb3c399..6402c908ff 100644 --- a/spec/requests/api/v1/mutes_spec.rb +++ b/spec/requests/api/v1/mutes_spec.rb @@ -29,7 +29,7 @@ RSpec.describe 'Mutes' do muted_accounts = mutes.map(&:target_account) - expect(body_as_json.pluck(:id)).to match_array(muted_accounts.map { |account| account.id.to_s }) + expect(response.parsed_body.pluck(:id)).to match_array(muted_accounts.map { |account| account.id.to_s }) end context 'with limit param' do @@ -38,7 +38,7 @@ RSpec.describe 'Mutes' do it 'returns only the requested number of muted accounts' do subject - expect(body_as_json.size).to eq(params[:limit]) + expect(response.parsed_body.size).to eq(params[:limit]) end it 'sets the correct pagination headers', :aggregate_failures do @@ -58,7 +58,7 @@ RSpec.describe 'Mutes' do it 'queries mutes in range according to max_id', :aggregate_failures do subject - expect(body_as_json) + expect(response.parsed_body) .to contain_exactly(include(id: mutes.first.target_account_id.to_s)) end end @@ -69,7 +69,7 @@ RSpec.describe 'Mutes' do it 'queries mutes in range according to since_id', :aggregate_failures do subject - expect(body_as_json) + expect(response.parsed_body) .to contain_exactly(include(id: mutes[1].target_account_id.to_s)) end end diff --git a/spec/requests/api/v1/notifications/policies_spec.rb b/spec/requests/api/v1/notifications/policies_spec.rb index a73d4217be..8bafcad2fe 100644 --- a/spec/requests/api/v1/notifications/policies_spec.rb +++ b/spec/requests/api/v1/notifications/policies_spec.rb @@ -26,7 +26,7 @@ RSpec.describe 'Policies' do subject expect(response).to have_http_status(200) - expect(body_as_json).to include( + expect(response.parsed_body).to include( filter_not_following: false, filter_not_followers: false, filter_new_accounts: false, @@ -54,7 +54,7 @@ RSpec.describe 'Policies' do .to change { NotificationPolicy.find_or_initialize_by(account: user.account).for_not_following.to_sym }.from(:accept).to(:filter) expect(response).to have_http_status(200) - expect(body_as_json).to include( + expect(response.parsed_body).to include( filter_not_following: true, filter_not_followers: false, filter_new_accounts: false, diff --git a/spec/requests/api/v1/notifications/requests_spec.rb b/spec/requests/api/v1/notifications/requests_spec.rb index 45bb71adb0..dc125bc7aa 100644 --- a/spec/requests/api/v1/notifications/requests_spec.rb +++ b/spec/requests/api/v1/notifications/requests_spec.rb @@ -133,7 +133,7 @@ RSpec.describe 'Requests' do subject expect(response).to have_http_status(200) - expect(body_as_json).to match({ merged: true }) + expect(response.parsed_body).to match({ merged: true }) end end @@ -146,7 +146,7 @@ RSpec.describe 'Requests' do subject expect(response).to have_http_status(200) - expect(body_as_json).to match({ merged: false }) + expect(response.parsed_body).to match({ merged: false }) end end end diff --git a/spec/requests/api/v1/notifications_spec.rb b/spec/requests/api/v1/notifications_spec.rb index 84e6db1e51..b74adb5dff 100644 --- a/spec/requests/api/v1/notifications_spec.rb +++ b/spec/requests/api/v1/notifications_spec.rb @@ -31,7 +31,7 @@ RSpec.describe 'Notifications' do subject expect(response).to have_http_status(200) - expect(body_as_json[:count]).to eq 5 + expect(response.parsed_body[:count]).to eq 5 end end @@ -45,7 +45,7 @@ RSpec.describe 'Notifications' do subject expect(response).to have_http_status(200) - expect(body_as_json[:count]).to eq 2 + expect(response.parsed_body[:count]).to eq 2 end end @@ -56,7 +56,7 @@ RSpec.describe 'Notifications' do subject expect(response).to have_http_status(200) - expect(body_as_json[:count]).to eq 4 + expect(response.parsed_body[:count]).to eq 4 end end @@ -67,7 +67,7 @@ RSpec.describe 'Notifications' do subject expect(response).to have_http_status(200) - expect(body_as_json[:count]).to eq 2 + expect(response.parsed_body[:count]).to eq 2 end end @@ -80,7 +80,7 @@ RSpec.describe 'Notifications' do subject expect(response).to have_http_status(200) - expect(body_as_json[:count]).to eq Api::V1::NotificationsController::DEFAULT_NOTIFICATIONS_COUNT_LIMIT + expect(response.parsed_body[:count]).to eq Api::V1::NotificationsController::DEFAULT_NOTIFICATIONS_COUNT_LIMIT end end end @@ -111,9 +111,9 @@ RSpec.describe 'Notifications' do subject expect(response).to have_http_status(200) - expect(body_as_json.size).to eq 5 + expect(response.parsed_body.size).to eq 5 expect(body_json_types).to include('reblog', 'mention', 'favourite', 'follow') - expect(body_as_json.any? { |x| x[:filtered] }).to be false + expect(response.parsed_body.any? { |x| x[:filtered] }).to be false end end @@ -124,9 +124,9 @@ RSpec.describe 'Notifications' do subject expect(response).to have_http_status(200) - expect(body_as_json.size).to eq 6 + expect(response.parsed_body.size).to eq 6 expect(body_json_types).to include('reblog', 'mention', 'favourite', 'follow') - expect(body_as_json.any? { |x| x[:filtered] }).to be true + expect(response.parsed_body.any? { |x| x[:filtered] }).to be true end end @@ -141,7 +141,7 @@ RSpec.describe 'Notifications' do end def body_json_account_ids - body_as_json.map { |x| x[:account][:id] } + response.parsed_body.map { |x| x[:account][:id] } end end @@ -152,7 +152,7 @@ RSpec.describe 'Notifications' do subject expect(response).to have_http_status(200) - expect(body_as_json.size).to eq 0 + expect(response.parsed_body.size).to eq 0 end end @@ -163,7 +163,7 @@ RSpec.describe 'Notifications' do subject expect(response).to have_http_status(200) - expect(body_as_json.size).to_not eq 0 + expect(response.parsed_body.size).to_not eq 0 expect(body_json_types.uniq).to_not include 'mention' end end @@ -187,7 +187,7 @@ RSpec.describe 'Notifications' do notifications = user.account.notifications.browserable.order(id: :asc) - expect(body_as_json.size) + expect(response.parsed_body.size) .to eq(params[:limit]) expect(response) @@ -199,7 +199,7 @@ RSpec.describe 'Notifications' do end def body_json_types - body_as_json.pluck(:type) + response.parsed_body.pluck(:type) end end diff --git a/spec/requests/api/v1/peers/search_spec.rb b/spec/requests/api/v1/peers/search_spec.rb index 87b0dc4f64..dc5f550d0e 100644 --- a/spec/requests/api/v1/peers/search_spec.rb +++ b/spec/requests/api/v1/peers/search_spec.rb @@ -23,7 +23,7 @@ RSpec.describe 'API Peers Search' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_blank end end @@ -34,7 +34,7 @@ RSpec.describe 'API Peers Search' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_blank end end @@ -49,9 +49,9 @@ RSpec.describe 'API Peers Search' do expect(response) .to have_http_status(200) - expect(body_as_json.size) + expect(response.parsed_body.size) .to eq(1) - expect(body_as_json.first) + expect(response.parsed_body.first) .to eq(account.domain) end end diff --git a/spec/requests/api/v1/polls_spec.rb b/spec/requests/api/v1/polls_spec.rb index 1c8a818d59..138a37a73c 100644 --- a/spec/requests/api/v1/polls_spec.rb +++ b/spec/requests/api/v1/polls_spec.rb @@ -23,7 +23,7 @@ RSpec.describe 'Polls' do subject expect(response).to have_http_status(200) - expect(body_as_json).to match( + expect(response.parsed_body).to match( a_hash_including( id: poll.id.to_s, voted: false, diff --git a/spec/requests/api/v1/preferences_spec.rb b/spec/requests/api/v1/preferences_spec.rb index 6508b51c04..d6991ca90c 100644 --- a/spec/requests/api/v1/preferences_spec.rb +++ b/spec/requests/api/v1/preferences_spec.rb @@ -34,7 +34,7 @@ RSpec.describe 'Preferences' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_present end end diff --git a/spec/requests/api/v1/push/subscriptions_spec.rb b/spec/requests/api/v1/push/subscriptions_spec.rb index 6674b048e8..a9587f8d58 100644 --- a/spec/requests/api/v1/push/subscriptions_spec.rb +++ b/spec/requests/api/v1/push/subscriptions_spec.rb @@ -65,7 +65,7 @@ RSpec.describe 'API V1 Push Subscriptions' do access_token_id: eq(token.id) ) - expect(body_as_json.with_indifferent_access) + expect(response.parsed_body.with_indifferent_access) .to include( { endpoint: create_payload[:subscription][:endpoint], alerts: {}, policy: 'all' } ) @@ -124,7 +124,7 @@ RSpec.describe 'API V1 Push Subscriptions' do ) end - expect(body_as_json.with_indifferent_access) + expect(response.parsed_body.with_indifferent_access) .to include( endpoint: create_payload[:subscription][:endpoint], alerts: alerts_payload[:data][:alerts], diff --git a/spec/requests/api/v1/reports_spec.rb b/spec/requests/api/v1/reports_spec.rb index a72d9bbcd8..a176bd78a6 100644 --- a/spec/requests/api/v1/reports_spec.rb +++ b/spec/requests/api/v1/reports_spec.rb @@ -37,7 +37,7 @@ RSpec.describe 'Reports' do emails = capture_emails { subject } expect(response).to have_http_status(200) - expect(body_as_json).to match( + expect(response.parsed_body).to match( a_hash_including( status_ids: [status.id.to_s], category: category, diff --git a/spec/requests/api/v1/scheduled_status_spec.rb b/spec/requests/api/v1/scheduled_status_spec.rb index b35d297a60..eb03827c9a 100644 --- a/spec/requests/api/v1/scheduled_status_spec.rb +++ b/spec/requests/api/v1/scheduled_status_spec.rb @@ -46,7 +46,7 @@ RSpec.describe 'Scheduled Statuses' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to_not be_present end end @@ -60,7 +60,7 @@ RSpec.describe 'Scheduled Statuses' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_present .and have_attributes( first: include(id: scheduled_status.id.to_s) diff --git a/spec/requests/api/v1/statuses/bookmarks_spec.rb b/spec/requests/api/v1/statuses/bookmarks_spec.rb index d3007740a5..f1bcfda0ff 100644 --- a/spec/requests/api/v1/statuses/bookmarks_spec.rb +++ b/spec/requests/api/v1/statuses/bookmarks_spec.rb @@ -28,7 +28,7 @@ RSpec.describe 'Bookmarks' do it 'returns json with updated attributes' do subject - expect(body_as_json).to match( + expect(response.parsed_body).to match( a_hash_including(id: status.id.to_s, bookmarked: true) ) end @@ -103,7 +103,7 @@ RSpec.describe 'Bookmarks' do it 'returns json with updated attributes' do subject - expect(body_as_json).to match( + expect(response.parsed_body).to match( a_hash_including(id: status.id.to_s, bookmarked: false) ) end @@ -127,7 +127,7 @@ RSpec.describe 'Bookmarks' do it 'returns json with updated attributes' do subject - expect(body_as_json).to match( + expect(response.parsed_body).to match( a_hash_including(id: status.id.to_s, bookmarked: false) ) end diff --git a/spec/requests/api/v1/statuses/favourited_by_accounts_spec.rb b/spec/requests/api/v1/statuses/favourited_by_accounts_spec.rb index 2fd79f424b..24bd03d343 100644 --- a/spec/requests/api/v1/statuses/favourited_by_accounts_spec.rb +++ b/spec/requests/api/v1/statuses/favourited_by_accounts_spec.rb @@ -34,9 +34,9 @@ RSpec.describe 'API V1 Statuses Favourited by Accounts' do next: api_v1_status_favourited_by_index_url(limit: 2, max_id: Favourite.first.id) ) - expect(body_as_json.size) + expect(response.parsed_body.size) .to eq(2) - expect(body_as_json) + expect(response.parsed_body) .to contain_exactly( include(id: alice.id.to_s), include(id: bob.id.to_s) @@ -48,9 +48,9 @@ RSpec.describe 'API V1 Statuses Favourited by Accounts' do subject - expect(body_as_json.size) + expect(response.parsed_body.size) .to eq 1 - expect(body_as_json.first[:id]).to eq(alice.id.to_s) + expect(response.parsed_body.first[:id]).to eq(alice.id.to_s) end end end diff --git a/spec/requests/api/v1/statuses/favourites_spec.rb b/spec/requests/api/v1/statuses/favourites_spec.rb index 22d0e4831f..f9f0ff6299 100644 --- a/spec/requests/api/v1/statuses/favourites_spec.rb +++ b/spec/requests/api/v1/statuses/favourites_spec.rb @@ -28,7 +28,7 @@ RSpec.describe 'Favourites', :inline_jobs do it 'returns json with updated attributes' do subject - expect(body_as_json).to match( + expect(response.parsed_body).to match( a_hash_including(id: status.id.to_s, favourites_count: 1, favourited: true) ) end @@ -95,7 +95,7 @@ RSpec.describe 'Favourites', :inline_jobs do it 'returns json with updated attributes' do subject - expect(body_as_json).to match( + expect(response.parsed_body).to match( a_hash_including(id: status.id.to_s, favourites_count: 0, favourited: false) ) end @@ -118,7 +118,7 @@ RSpec.describe 'Favourites', :inline_jobs do it 'returns json with updated attributes' do subject - expect(body_as_json).to match( + expect(response.parsed_body).to match( a_hash_including(id: status.id.to_s, favourites_count: 0, favourited: false) ) end diff --git a/spec/requests/api/v1/statuses/histories_spec.rb b/spec/requests/api/v1/statuses/histories_spec.rb index f13bf79867..4115a52fa8 100644 --- a/spec/requests/api/v1/statuses/histories_spec.rb +++ b/spec/requests/api/v1/statuses/histories_spec.rb @@ -18,7 +18,7 @@ RSpec.describe 'API V1 Statuses Histories' do it 'returns http success' do expect(response).to have_http_status(200) - expect(body_as_json.size).to_not be 0 + expect(response.parsed_body.size).to_not be 0 end end end diff --git a/spec/requests/api/v1/statuses/pins_spec.rb b/spec/requests/api/v1/statuses/pins_spec.rb index 3be1a16ee1..56e60c6d36 100644 --- a/spec/requests/api/v1/statuses/pins_spec.rb +++ b/spec/requests/api/v1/statuses/pins_spec.rb @@ -28,7 +28,7 @@ RSpec.describe 'Pins' do it 'return json with updated attributes' do subject - expect(body_as_json).to match( + expect(response.parsed_body).to match( a_hash_including(id: status.id.to_s, pinned: true) ) end @@ -96,7 +96,7 @@ RSpec.describe 'Pins' do it 'return json with updated attributes' do subject - expect(body_as_json).to match( + expect(response.parsed_body).to match( a_hash_including(id: status.id.to_s, pinned: false) ) end diff --git a/spec/requests/api/v1/statuses/reblogged_by_accounts_spec.rb b/spec/requests/api/v1/statuses/reblogged_by_accounts_spec.rb index 5fc54042f9..bd26c22f08 100644 --- a/spec/requests/api/v1/statuses/reblogged_by_accounts_spec.rb +++ b/spec/requests/api/v1/statuses/reblogged_by_accounts_spec.rb @@ -33,9 +33,9 @@ RSpec.describe 'API V1 Statuses Reblogged by Accounts' do next: api_v1_status_reblogged_by_index_url(limit: 2, max_id: alice.statuses.first.id) ) - expect(body_as_json.size) + expect(response.parsed_body.size) .to eq(2) - expect(body_as_json) + expect(response.parsed_body) .to contain_exactly( include(id: alice.id.to_s), include(id: bob.id.to_s) @@ -47,9 +47,9 @@ RSpec.describe 'API V1 Statuses Reblogged by Accounts' do subject - expect(body_as_json.size) + expect(response.parsed_body.size) .to eq 1 - expect(body_as_json.first[:id]).to eq(alice.id.to_s) + expect(response.parsed_body.first[:id]).to eq(alice.id.to_s) end end end diff --git a/spec/requests/api/v1/statuses/reblogs_spec.rb b/spec/requests/api/v1/statuses/reblogs_spec.rb index 0978c890a4..8c7894d875 100644 --- a/spec/requests/api/v1/statuses/reblogs_spec.rb +++ b/spec/requests/api/v1/statuses/reblogs_spec.rb @@ -24,7 +24,7 @@ RSpec.describe 'API V1 Statuses Reblogs' do expect(user.account.reblogged?(status)).to be true - expect(body_as_json) + expect(response.parsed_body) .to include( reblog: include( id: status.id.to_s, @@ -60,7 +60,7 @@ RSpec.describe 'API V1 Statuses Reblogs' do expect(user.account.reblogged?(status)).to be false - expect(body_as_json) + expect(response.parsed_body) .to include( id: status.id.to_s, reblogs_count: 0, @@ -85,7 +85,7 @@ RSpec.describe 'API V1 Statuses Reblogs' do expect(user.account.reblogged?(status)).to be false - expect(body_as_json) + expect(response.parsed_body) .to include( id: status.id.to_s, reblogs_count: 0, diff --git a/spec/requests/api/v1/statuses/sources_spec.rb b/spec/requests/api/v1/statuses/sources_spec.rb index c7b1603824..eab19d64da 100644 --- a/spec/requests/api/v1/statuses/sources_spec.rb +++ b/spec/requests/api/v1/statuses/sources_spec.rb @@ -22,7 +22,7 @@ RSpec.describe 'Sources' do subject expect(response).to have_http_status(200) - expect(body_as_json).to match({ + expect(response.parsed_body).to match({ id: status.id.to_s, text: status.text, spoiler_text: status.spoiler_text, @@ -51,7 +51,7 @@ RSpec.describe 'Sources' do subject expect(response).to have_http_status(200) - expect(body_as_json).to match({ + expect(response.parsed_body).to match({ id: status.id.to_s, text: status.text, spoiler_text: status.spoiler_text, diff --git a/spec/requests/api/v1/statuses_spec.rb b/spec/requests/api/v1/statuses_spec.rb index 1a211d14d8..057800a266 100644 --- a/spec/requests/api/v1/statuses_spec.rb +++ b/spec/requests/api/v1/statuses_spec.rb @@ -18,7 +18,7 @@ RSpec.describe '/api/v1/statuses' do get '/api/v1/statuses', headers: headers, params: { id: [status.id, other_status.id, 123_123] } expect(response).to have_http_status(200) - expect(body_as_json).to contain_exactly( + expect(response.parsed_body).to contain_exactly( hash_including(id: status.id.to_s), hash_including(id: other_status.id.to_s) ) @@ -52,7 +52,7 @@ RSpec.describe '/api/v1/statuses' do subject expect(response).to have_http_status(200) - expect(body_as_json[:filtered][0]).to include({ + expect(response.parsed_body[:filtered][0]).to include({ filter: a_hash_including({ id: user.account.custom_filters.first.id.to_s, title: 'filter1', @@ -75,7 +75,7 @@ RSpec.describe '/api/v1/statuses' do subject expect(response).to have_http_status(200) - expect(body_as_json[:filtered][0]).to include({ + expect(response.parsed_body[:filtered][0]).to include({ filter: a_hash_including({ id: user.account.custom_filters.first.id.to_s, title: 'filter1', @@ -97,7 +97,7 @@ RSpec.describe '/api/v1/statuses' do subject expect(response).to have_http_status(200) - expect(body_as_json[:reblog][:filtered][0]).to include({ + expect(response.parsed_body[:reblog][:filtered][0]).to include({ filter: a_hash_including({ id: user.account.custom_filters.first.id.to_s, title: 'filter1', @@ -154,7 +154,7 @@ RSpec.describe '/api/v1/statuses' do subject expect(response).to have_http_status(422) - expect(body_as_json[:unexpected_accounts].map { |a| a.slice(:id, :acct) }).to match [{ id: bob.id.to_s, acct: bob.acct }] + expect(response.parsed_body[:unexpected_accounts].map { |a| a.slice(:id, :acct) }).to match [{ id: bob.id.to_s, acct: bob.acct }] end end diff --git a/spec/requests/api/v1/suggestions_spec.rb b/spec/requests/api/v1/suggestions_spec.rb index b900c910df..8267bb92a0 100644 --- a/spec/requests/api/v1/suggestions_spec.rb +++ b/spec/requests/api/v1/suggestions_spec.rb @@ -32,7 +32,7 @@ RSpec.describe 'Suggestions' do it 'returns accounts' do subject - expect(body_as_json) + expect(response.parsed_body) .to contain_exactly(include(id: bob.id.to_s), include(id: jeff.id.to_s)) end @@ -42,7 +42,7 @@ RSpec.describe 'Suggestions' do it 'returns only the requested number of accounts' do subject - expect(body_as_json.size).to eq 1 + expect(response.parsed_body.size).to eq 1 end end diff --git a/spec/requests/api/v1/tags_spec.rb b/spec/requests/api/v1/tags_spec.rb index db74a6f037..9637823d45 100644 --- a/spec/requests/api/v1/tags_spec.rb +++ b/spec/requests/api/v1/tags_spec.rb @@ -21,7 +21,7 @@ RSpec.describe 'Tags' do subject expect(response).to have_http_status(200) - expect(body_as_json[:name]).to eq(name) + expect(response.parsed_body[:name]).to eq(name) end end diff --git a/spec/requests/api/v1/timelines/home_spec.rb b/spec/requests/api/v1/timelines/home_spec.rb index 9dd102fcb6..afad2988ca 100644 --- a/spec/requests/api/v1/timelines/home_spec.rb +++ b/spec/requests/api/v1/timelines/home_spec.rb @@ -40,7 +40,7 @@ RSpec.describe 'Home', :inline_jobs do it 'returns the statuses of followed users' do subject - expect(body_as_json.pluck(:id)).to match_array(home_statuses.map { |status| status.id.to_s }) + expect(response.parsed_body.pluck(:id)).to match_array(home_statuses.map { |status| status.id.to_s }) end context 'with limit param' do @@ -49,7 +49,7 @@ RSpec.describe 'Home', :inline_jobs do it 'returns only the requested number of statuses' do subject - expect(body_as_json.size).to eq(params[:limit]) + expect(response.parsed_body.size).to eq(params[:limit]) end it 'sets the correct pagination headers', :aggregate_failures do diff --git a/spec/requests/api/v1/timelines/link_spec.rb b/spec/requests/api/v1/timelines/link_spec.rb index 67d8bca022..8999364703 100644 --- a/spec/requests/api/v1/timelines/link_spec.rb +++ b/spec/requests/api/v1/timelines/link_spec.rb @@ -13,7 +13,7 @@ RSpec.describe 'Link' do subject expect(response).to have_http_status(200) - expect(body_as_json.pluck(:id)).to match_array(expected_statuses.map { |status| status.id.to_s }) + expect(response.parsed_body.pluck(:id)).to match_array(expected_statuses.map { |status| status.id.to_s }) end end @@ -127,7 +127,7 @@ RSpec.describe 'Link' do subject expect(response).to have_http_status(200) - expect(body_as_json.size).to eq(params[:limit]) + expect(response.parsed_body.size).to eq(params[:limit]) end it 'sets the correct pagination headers', :aggregate_failures do diff --git a/spec/requests/api/v1/timelines/public_spec.rb b/spec/requests/api/v1/timelines/public_spec.rb index 1fc62b3932..759e236d05 100644 --- a/spec/requests/api/v1/timelines/public_spec.rb +++ b/spec/requests/api/v1/timelines/public_spec.rb @@ -13,7 +13,7 @@ RSpec.describe 'Public' do subject expect(response).to have_http_status(200) - expect(body_as_json.pluck(:id)).to match_array(expected_statuses.map { |status| status.id.to_s }) + expect(response.parsed_body.pluck(:id)).to match_array(expected_statuses.map { |status| status.id.to_s }) end end @@ -81,7 +81,7 @@ RSpec.describe 'Public' do subject expect(response).to have_http_status(200) - expect(body_as_json.size).to eq(params[:limit]) + expect(response.parsed_body.size).to eq(params[:limit]) end it 'sets the correct pagination headers', :aggregate_failures do diff --git a/spec/requests/api/v1/timelines/tag_spec.rb b/spec/requests/api/v1/timelines/tag_spec.rb index cfbfa0291c..03d34e59f1 100644 --- a/spec/requests/api/v1/timelines/tag_spec.rb +++ b/spec/requests/api/v1/timelines/tag_spec.rb @@ -19,7 +19,7 @@ RSpec.describe 'Tag' do expect(response) .to have_http_status(200) - expect(body_as_json.pluck(:id)) + expect(response.parsed_body.pluck(:id)) .to match_array(expected_statuses.map { |status| status.id.to_s }) .and not_include(private_status.id) end @@ -70,7 +70,7 @@ RSpec.describe 'Tag' do it 'returns only the requested number of statuses' do subject - expect(body_as_json.size).to eq(params[:limit]) + expect(response.parsed_body.size).to eq(params[:limit]) end it 'sets the correct pagination headers', :aggregate_failures do diff --git a/spec/requests/api/v2/admin/accounts_spec.rb b/spec/requests/api/v2/admin/accounts_spec.rb index 8f52c6a613..17c38e2e55 100644 --- a/spec/requests/api/v2/admin/accounts_spec.rb +++ b/spec/requests/api/v2/admin/accounts_spec.rb @@ -76,7 +76,7 @@ RSpec.describe 'API V2 Admin Accounts' do end def body_json_ids - body_as_json.map { |a| a[:id].to_i } + response.parsed_body.map { |a| a[:id].to_i } end context 'with limit param' do diff --git a/spec/requests/api/v2/filters/keywords_spec.rb b/spec/requests/api/v2/filters/keywords_spec.rb index 69eff5a064..a31accaa5c 100644 --- a/spec/requests/api/v2/filters/keywords_spec.rb +++ b/spec/requests/api/v2/filters/keywords_spec.rb @@ -17,7 +17,7 @@ RSpec.describe 'API V2 Filters Keywords' do it 'returns http success' do get "/api/v2/filters/#{filter.id}/keywords", headers: headers expect(response).to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to contain_exactly( include(id: keyword.id.to_s) ) @@ -42,7 +42,7 @@ RSpec.describe 'API V2 Filters Keywords' do it 'creates a filter', :aggregate_failures do expect(response).to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to include( keyword: 'magic', whole_word: false @@ -73,7 +73,7 @@ RSpec.describe 'API V2 Filters Keywords' do it 'responds with the keyword', :aggregate_failures do expect(response).to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to include( keyword: 'foo', whole_word: false diff --git a/spec/requests/api/v2/filters/statuses_spec.rb b/spec/requests/api/v2/filters/statuses_spec.rb index 5969327829..aed8934a5e 100644 --- a/spec/requests/api/v2/filters/statuses_spec.rb +++ b/spec/requests/api/v2/filters/statuses_spec.rb @@ -17,7 +17,7 @@ RSpec.describe 'API V2 Filters Statuses' do it 'returns http success' do get "/api/v2/filters/#{filter.id}/statuses", headers: headers expect(response).to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to contain_exactly( include(id: status_filter.id.to_s) ) @@ -43,7 +43,7 @@ RSpec.describe 'API V2 Filters Statuses' do it 'creates a filter', :aggregate_failures do expect(response).to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to include( status_id: status.id.to_s ) @@ -73,7 +73,7 @@ RSpec.describe 'API V2 Filters Statuses' do it 'responds with the filter', :aggregate_failures do expect(response).to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to include( status_id: status_filter.status.id.to_s ) diff --git a/spec/requests/api/v2/filters_spec.rb b/spec/requests/api/v2/filters_spec.rb index 036a6a65a9..850c773df3 100644 --- a/spec/requests/api/v2/filters_spec.rb +++ b/spec/requests/api/v2/filters_spec.rb @@ -32,7 +32,7 @@ RSpec.describe 'Filters' do subject expect(response).to have_http_status(200) - expect(body_as_json.pluck(:id)).to match_array(filters.map { |filter| filter.id.to_s }) + expect(response.parsed_body.pluck(:id)).to match_array(filters.map { |filter| filter.id.to_s }) end end @@ -58,7 +58,7 @@ RSpec.describe 'Filters' do it 'returns a filter with keywords', :aggregate_failures do subject - expect(body_as_json) + expect(response.parsed_body) .to include( title: 'magic', filter_action: 'hide', @@ -127,7 +127,10 @@ RSpec.describe 'Filters' do subject expect(response).to have_http_status(200) - expect(body_as_json[:id]).to eq(filter.id.to_s) + expect(response.parsed_body) + .to include( + id: filter.id.to_s + ) end context 'when the filter belongs to someone else' do diff --git a/spec/requests/api/v2/instance_spec.rb b/spec/requests/api/v2/instance_spec.rb index 2f01db5003..d484dc7c46 100644 --- a/spec/requests/api/v2/instance_spec.rb +++ b/spec/requests/api/v2/instance_spec.rb @@ -15,7 +15,7 @@ RSpec.describe 'Instances' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_present .and include(title: 'Mastodon') .and include_api_versions @@ -30,7 +30,7 @@ RSpec.describe 'Instances' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_present .and include(title: 'Mastodon') .and include_api_versions diff --git a/spec/requests/api/v2/media_spec.rb b/spec/requests/api/v2/media_spec.rb index 97540413f1..06ce0053e8 100644 --- a/spec/requests/api/v2/media_spec.rb +++ b/spec/requests/api/v2/media_spec.rb @@ -21,7 +21,7 @@ RSpec.describe 'Media API', :attachment_processing do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to be_a(Hash) end end @@ -38,7 +38,7 @@ RSpec.describe 'Media API', :attachment_processing do expect(response) .to have_http_status(202) - expect(body_as_json) + expect(response.parsed_body) .to be_a(Hash) end end @@ -63,7 +63,7 @@ RSpec.describe 'Media API', :attachment_processing do expect(response) .to have_http_status(422) - expect(body_as_json) + expect(response.parsed_body) .to be_a(Hash) .and include(error: /File type/) end @@ -80,7 +80,7 @@ RSpec.describe 'Media API', :attachment_processing do expect(response) .to have_http_status(500) - expect(body_as_json) + expect(response.parsed_body) .to be_a(Hash) .and include(error: /processing/) end diff --git a/spec/requests/api/v2/notifications/policies_spec.rb b/spec/requests/api/v2/notifications/policies_spec.rb index f9860b5fb4..dc205b6ebb 100644 --- a/spec/requests/api/v2/notifications/policies_spec.rb +++ b/spec/requests/api/v2/notifications/policies_spec.rb @@ -26,7 +26,7 @@ RSpec.describe 'Policies' do subject expect(response).to have_http_status(200) - expect(body_as_json).to include( + expect(response.parsed_body).to include( for_not_following: 'accept', for_not_followers: 'accept', for_new_accounts: 'accept', @@ -56,7 +56,7 @@ RSpec.describe 'Policies' do .and change { NotificationPolicy.find_or_initialize_by(account: user.account).for_limited_accounts.to_sym }.from(:filter).to(:drop) expect(response).to have_http_status(200) - expect(body_as_json).to include( + expect(response.parsed_body).to include( for_not_following: 'filter', for_not_followers: 'accept', for_new_accounts: 'accept', diff --git a/spec/requests/api/v2/search_spec.rb b/spec/requests/api/v2/search_spec.rb index 039e7513cd..a59ec7ca6b 100644 --- a/spec/requests/api/v2/search_spec.rb +++ b/spec/requests/api/v2/search_spec.rb @@ -27,7 +27,7 @@ RSpec.describe 'Search API' do it 'returns all matching accounts' do get '/api/v2/search', headers: headers, params: params - expect(body_as_json[:accounts].pluck(:id)).to contain_exactly(bob.id.to_s, ana.id.to_s, tom.id.to_s) + expect(response.parsed_body[:accounts].pluck(:id)).to contain_exactly(bob.id.to_s, ana.id.to_s, tom.id.to_s) end context 'with truthy `resolve`' do @@ -80,7 +80,7 @@ RSpec.describe 'Search API' do it 'returns only the followed accounts' do get '/api/v2/search', headers: headers, params: params - expect(body_as_json[:accounts].pluck(:id)).to contain_exactly(ana.id.to_s) + expect(response.parsed_body[:accounts].pluck(:id)).to contain_exactly(ana.id.to_s) end end end diff --git a/spec/requests/api/v2/suggestions_spec.rb b/spec/requests/api/v2/suggestions_spec.rb index 8895efd23d..e92507ed66 100644 --- a/spec/requests/api/v2/suggestions_spec.rb +++ b/spec/requests/api/v2/suggestions_spec.rb @@ -22,7 +22,7 @@ RSpec.describe 'Suggestions API' do expect(response).to have_http_status(200) - expect(body_as_json).to match_array( + expect(response.parsed_body).to match_array( [bob, jeff].map do |account| hash_including({ source: 'staff', diff --git a/spec/requests/api/v2_alpha/notifications/accounts_spec.rb b/spec/requests/api/v2_alpha/notifications/accounts_spec.rb index 6a6ce043d3..3c5bcd8996 100644 --- a/spec/requests/api/v2_alpha/notifications/accounts_spec.rb +++ b/spec/requests/api/v2_alpha/notifications/accounts_spec.rb @@ -33,7 +33,7 @@ RSpec.describe 'Accounts in grouped notifications' do # The group we are interested in is only favorites notifications = user.account.notifications.where(type: 'favourite').reorder(id: :desc) - expect(body_as_json).to match( + expect(response.parsed_body).to match( [ a_hash_including( id: notifications.first.from_account_id.to_s @@ -58,7 +58,7 @@ RSpec.describe 'Accounts in grouped notifications' do # The group we are interested in is only favorites notifications = user.account.notifications.where(type: 'favourite').reorder(id: :desc) - expect(body_as_json).to match( + expect(response.parsed_body).to match( [ a_hash_including( id: notifications.first.from_account_id.to_s diff --git a/spec/requests/api/v2_alpha/notifications_spec.rb b/spec/requests/api/v2_alpha/notifications_spec.rb index 8009e7edce..b7821de561 100644 --- a/spec/requests/api/v2_alpha/notifications_spec.rb +++ b/spec/requests/api/v2_alpha/notifications_spec.rb @@ -31,7 +31,7 @@ RSpec.describe 'Notifications' do subject expect(response).to have_http_status(200) - expect(body_as_json[:count]).to eq 4 + expect(response.parsed_body[:count]).to eq 4 end end @@ -42,7 +42,7 @@ RSpec.describe 'Notifications' do subject expect(response).to have_http_status(200) - expect(body_as_json[:count]).to eq 5 + expect(response.parsed_body[:count]).to eq 5 end end @@ -56,7 +56,7 @@ RSpec.describe 'Notifications' do subject expect(response).to have_http_status(200) - expect(body_as_json[:count]).to eq 2 + expect(response.parsed_body[:count]).to eq 2 end end @@ -67,7 +67,7 @@ RSpec.describe 'Notifications' do subject expect(response).to have_http_status(200) - expect(body_as_json[:count]).to eq 3 + expect(response.parsed_body[:count]).to eq 3 end end @@ -78,7 +78,7 @@ RSpec.describe 'Notifications' do subject expect(response).to have_http_status(200) - expect(body_as_json[:count]).to eq 2 + expect(response.parsed_body[:count]).to eq 2 end end @@ -91,7 +91,7 @@ RSpec.describe 'Notifications' do subject expect(response).to have_http_status(200) - expect(body_as_json[:count]).to eq Api::V2Alpha::NotificationsController::DEFAULT_NOTIFICATIONS_COUNT_LIMIT + expect(response.parsed_body[:count]).to eq Api::V2Alpha::NotificationsController::DEFAULT_NOTIFICATIONS_COUNT_LIMIT end end end @@ -125,7 +125,7 @@ RSpec.describe 'Notifications' do subject expect(response).to have_http_status(200) - expect(body_as_json[:notification_groups]).to eq [] + expect(response.parsed_body[:notification_groups]).to eq [] end end @@ -145,7 +145,7 @@ RSpec.describe 'Notifications' do subject expect(response).to have_http_status(200) - expect(body_as_json[:notification_groups]).to contain_exactly( + expect(response.parsed_body[:notification_groups]).to contain_exactly( a_hash_including( type: 'reblog', sample_account_ids: [bob.account_id.to_s] @@ -177,7 +177,7 @@ RSpec.describe 'Notifications' do subject expect(response).to have_http_status(200) - expect(body_as_json.size).to_not eq 0 + expect(response.parsed_body.size).to_not eq 0 expect(body_json_types.uniq).to_not include 'mention' end end @@ -190,7 +190,7 @@ RSpec.describe 'Notifications' do expect(response).to have_http_status(200) expect(body_json_types.uniq).to eq ['mention'] - expect(body_as_json.dig(:notification_groups, 0, :page_min_id)).to_not be_nil + expect(response.parsed_body.dig(:notification_groups, 0, :page_min_id)).to_not be_nil end end @@ -201,7 +201,7 @@ RSpec.describe 'Notifications' do it 'returns the requested number of notifications paginated', :aggregate_failures do subject - expect(body_as_json[:notification_groups].size) + expect(response.parsed_body[:notification_groups].size) .to eq(params[:limit]) expect(response) @@ -221,7 +221,7 @@ RSpec.describe 'Notifications' do it 'returns the requested number of notifications paginated', :aggregate_failures do subject - expect(body_as_json[:notification_groups].size) + expect(response.parsed_body[:notification_groups].size) .to eq(2) expect(response) @@ -247,10 +247,10 @@ RSpec.describe 'Notifications' do subject expect(response).to have_http_status(200) - expect(body_as_json[:partial_accounts].size).to be > 0 - expect(body_as_json[:partial_accounts][0].keys.map(&:to_sym)).to contain_exactly(:acct, :avatar, :avatar_static, :bot, :id, :locked, :url) - expect(body_as_json[:partial_accounts].pluck(:id)).to_not include(recent_account.id.to_s) - expect(body_as_json[:accounts].pluck(:id)).to include(recent_account.id.to_s) + expect(response.parsed_body[:partial_accounts].size).to be > 0 + expect(response.parsed_body[:partial_accounts][0].keys.map(&:to_sym)).to contain_exactly(:acct, :avatar, :avatar_static, :bot, :id, :locked, :url) + expect(response.parsed_body[:partial_accounts].pluck(:id)).to_not include(recent_account.id.to_s) + expect(response.parsed_body[:accounts].pluck(:id)).to include(recent_account.id.to_s) end end @@ -265,7 +265,7 @@ RSpec.describe 'Notifications' do end def body_json_types - body_as_json[:notification_groups].pluck(:type) + response.parsed_body[:notification_groups].pluck(:type) end end diff --git a/spec/requests/api/web/embeds_spec.rb b/spec/requests/api/web/embeds_spec.rb index 0e6195204b..2b28502835 100644 --- a/spec/requests/api/web/embeds_spec.rb +++ b/spec/requests/api/web/embeds_spec.rb @@ -18,7 +18,7 @@ RSpec.describe '/api/web/embed' do subject expect(response).to have_http_status(200) - expect(body_as_json[:html]).to be_present + expect(response.parsed_body[:html]).to be_present end end @@ -71,7 +71,7 @@ RSpec.describe '/api/web/embed' do subject expect(response).to have_http_status(200) - expect(body_as_json[:html]).to be_present + expect(response.parsed_body[:html]).to be_present end context 'when the requesting user is blocked' do @@ -133,7 +133,7 @@ RSpec.describe '/api/web/embed' do subject expect(response).to have_http_status(200) - expect(body_as_json[:html]).to be_present + expect(response.parsed_body[:html]).to be_present end end diff --git a/spec/requests/emojis_spec.rb b/spec/requests/emojis_spec.rb index b2e4702f2d..644838dc65 100644 --- a/spec/requests/emojis_spec.rb +++ b/spec/requests/emojis_spec.rb @@ -11,7 +11,7 @@ RSpec.describe 'Emojis' do expect(response) .to have_http_status(200) - expect(body_as_json) + expect(response.parsed_body) .to include( name: ':coolcat:', type: 'Emoji' diff --git a/spec/requests/instance_actor_spec.rb b/spec/requests/instance_actor_spec.rb index bb294b04a4..b4a9b2ce6f 100644 --- a/spec/requests/instance_actor_spec.rb +++ b/spec/requests/instance_actor_spec.rb @@ -15,7 +15,7 @@ RSpec.describe 'Instance actor endpoint' do .and have_cacheable_headers expect(response.content_type) .to start_with('application/activity+json') - expect(body_as_json) + expect(response.parsed_body) .to include( id: instance_actor_url, type: 'Application', diff --git a/spec/requests/invite_spec.rb b/spec/requests/invite_spec.rb index 4ce6c78e94..ba04645389 100644 --- a/spec/requests/invite_spec.rb +++ b/spec/requests/invite_spec.rb @@ -12,7 +12,7 @@ RSpec.describe 'invites' do expect(response).to have_http_status(200) expect(response.media_type).to eq 'application/json' - expect(body_as_json[:invite_code]).to eq invite.code + expect(response.parsed_body[:invite_code]).to eq invite.code end end diff --git a/spec/requests/log_out_spec.rb b/spec/requests/log_out_spec.rb index 62ede0c106..25291fa796 100644 --- a/spec/requests/log_out_spec.rb +++ b/spec/requests/log_out_spec.rb @@ -24,7 +24,7 @@ RSpec.describe 'Log Out' do expect(response).to have_http_status(200) expect(response.media_type).to eq 'application/json' - expect(body_as_json[:redirect_to]).to eq '/auth/sign_in' + expect(response.parsed_body[:redirect_to]).to eq '/auth/sign_in' end end end diff --git a/spec/requests/manifest_spec.rb b/spec/requests/manifest_spec.rb index 69e308e3ce..8133c90ee5 100644 --- a/spec/requests/manifest_spec.rb +++ b/spec/requests/manifest_spec.rb @@ -13,7 +13,7 @@ RSpec.describe 'Manifest' do .and have_attributes( content_type: match('application/json') ) - expect(body_as_json) + expect(response.parsed_body) .to include( id: '/home', name: 'Mastodon' diff --git a/spec/requests/oauth/token_spec.rb b/spec/requests/oauth/token_spec.rb index 39ea9b35ff..18d232e5ab 100644 --- a/spec/requests/oauth/token_spec.rb +++ b/spec/requests/oauth/token_spec.rb @@ -34,7 +34,7 @@ RSpec.describe 'Obtaining OAuth Tokens' do subject expect(response).to have_http_status(200) - expect(body_as_json[:scope]).to eq 'read write' + expect(response.parsed_body[:scope]).to eq 'read write' end end @@ -76,7 +76,7 @@ RSpec.describe 'Obtaining OAuth Tokens' do subject expect(response).to have_http_status(200) - expect(body_as_json[:scope]).to eq('read') + expect(response.parsed_body[:scope]).to eq('read') end end @@ -88,7 +88,7 @@ RSpec.describe 'Obtaining OAuth Tokens' do subject expect(response).to have_http_status(200) - expect(body_as_json[:scope]).to eq 'read write' + expect(response.parsed_body[:scope]).to eq 'read write' end end diff --git a/spec/requests/signature_verification_spec.rb b/spec/requests/signature_verification_spec.rb index 580d028338..128e7c0787 100644 --- a/spec/requests/signature_verification_spec.rb +++ b/spec/requests/signature_verification_spec.rb @@ -50,7 +50,7 @@ RSpec.describe 'signature verification concern' do get '/activitypub/success' expect(response).to have_http_status(200) - expect(body_as_json).to match( + expect(response.parsed_body).to match( signed_request: false, signature_actor_id: nil, error: 'Request not signed' @@ -62,7 +62,7 @@ RSpec.describe 'signature verification concern' do get '/activitypub/signature_required' expect(response).to have_http_status(401) - expect(body_as_json).to match( + expect(response.parsed_body).to match( error: 'Request not signed' ) end @@ -87,7 +87,7 @@ RSpec.describe 'signature verification concern' do } expect(response).to have_http_status(200) - expect(body_as_json).to match( + expect(response.parsed_body).to match( signed_request: true, signature_actor_id: actor.id.to_s ) @@ -109,7 +109,7 @@ RSpec.describe 'signature verification concern' do } expect(response).to have_http_status(200) - expect(body_as_json).to match( + expect(response.parsed_body).to match( signed_request: true, signature_actor_id: actor.id.to_s ) @@ -131,7 +131,7 @@ RSpec.describe 'signature verification concern' do } expect(response).to have_http_status(200) - expect(body_as_json).to match( + expect(response.parsed_body).to match( signed_request: true, signature_actor_id: actor.id.to_s ) @@ -152,7 +152,7 @@ RSpec.describe 'signature verification concern' do 'Signature' => signature_header, } - expect(body_as_json).to match( + expect(response.parsed_body).to match( signed_request: true, signature_actor_id: nil, error: anything @@ -168,7 +168,7 @@ RSpec.describe 'signature verification concern' do 'Signature' => 'keyId="https://remote.domain/users/bob#main-key",algorithm="rsa-sha256",headers="date host (request-target)",signature="Z8ilar3J7bOwqZkMp7sL8sRs4B1FT+UorbmvWoE+A5UeoOJ3KBcUmbsh+k3wQwbP5gMNUrra9rEWabpasZGphLsbDxfbsWL3Cf0PllAc7c1c7AFEwnewtExI83/qqgEkfWc2z7UDutXc2NfgAx89Ox8DXU/fA2GG0jILjB6UpFyNugkY9rg6oI31UnvfVi3R7sr3/x8Ea3I9thPvqI2byF6cojknSpDAwYzeKdngX3TAQEGzFHz3SDWwyp3jeMWfwvVVbM38FxhvAnSumw7YwWW4L7M7h4M68isLimoT3yfCn2ucBVL5Dz8koBpYf/40w7QidClAwCafZQFC29yDOg=="', # rubocop:disable Layout/LineLength } - expect(body_as_json).to match( + expect(response.parsed_body).to match( signed_request: true, signature_actor_id: nil, error: anything @@ -184,7 +184,7 @@ RSpec.describe 'signature verification concern' do 'Signature' => 'keyId="https://remote.domain/users/bob#main-key",algorithm="rsa-sha256",headers="date host (request-target)",signature="Z8ilar3J7bOwqZkMp7sL8sRs4B1FT+UorbmvWoE+A5UeoOJ3KBcUmbsh+k3wQwbP5gMNUrra9rEWabpasZGphLsbDxfbsWL3Cf0PllAc7c1c7AFEwnewtExI83/qqgEkfWc2z7UDutXc2NfgAx89Ox8DXU/fA2GG0jILjB6UpFyNugkY9rg6oI31UnvfVi3R7sr3/x8Ea3I9thPvqI2byF6cojknSpDAwYzeKdngX3TAQEGzFHz3SDWwyp3jeMWfwvVVbM38FxhvAnSumw7YwWW4L7M7h4M68isLimoT3yfCn2ucBVL5Dz8koBpYf/40w7QidClAwCafZQFC29yDOg=="', # rubocop:disable Layout/LineLength } - expect(body_as_json).to match( + expect(response.parsed_body).to match( signed_request: true, signature_actor_id: nil, error: anything @@ -206,7 +206,7 @@ RSpec.describe 'signature verification concern' do 'Signature' => signature_header, } - expect(body_as_json).to match( + expect(response.parsed_body).to match( signed_request: true, signature_actor_id: nil, error: 'Invalid Date header: not RFC 2616 compliant date: "wrong date"' @@ -228,7 +228,7 @@ RSpec.describe 'signature verification concern' do 'Signature' => signature_header, } - expect(body_as_json).to match( + expect(response.parsed_body).to match( signed_request: true, signature_actor_id: nil, error: 'Signed request date outside acceptable time window' @@ -254,7 +254,7 @@ RSpec.describe 'signature verification concern' do } expect(response).to have_http_status(200) - expect(body_as_json).to match( + expect(response.parsed_body).to match( signed_request: true, signature_actor_id: actor.id.to_s ) @@ -278,7 +278,7 @@ RSpec.describe 'signature verification concern' do 'Signature' => signature_header, } - expect(body_as_json).to match( + expect(response.parsed_body).to match( signed_request: true, signature_actor_id: nil, error: 'Mastodon requires the Digest header to be signed when doing a POST request' @@ -303,7 +303,7 @@ RSpec.describe 'signature verification concern' do 'Signature' => signature_header, } - expect(body_as_json).to match( + expect(response.parsed_body).to match( signed_request: true, signature_actor_id: nil, error: 'Invalid Digest value. Computed SHA-256 digest: wFNeS+K3n/2TKRMFQ2v4iTFOSj+uwF7P/Lt98xrZ5Ro=; given: ZOyIygCyaOW6GjVnihtTFtIS9PNmskdyMlNKiuyjfzw=' @@ -321,7 +321,7 @@ RSpec.describe 'signature verification concern' do } expect(response).to have_http_status(200) - expect(body_as_json).to match( + expect(response.parsed_body).to match( signed_request: true, signature_actor_id: nil, error: anything @@ -342,7 +342,7 @@ RSpec.describe 'signature verification concern' do 'Signature' => 'keyId="https://remote.domain/users/alice#main-key",algorithm="rsa-sha256",headers="date host (request-target)",signature="Z8ilar3J7bOwqZkMp7sL8sRs4B1FT+UorbmvWoE+A5UeoOJ3KBcUmbsh+k3wQwbP5gMNUrra9rEWabpasZGphLsbDxfbsWL3Cf0PllAc7c1c7AFEwnewtExI83/qqgEkfWc2z7UDutXc2NfgAx89Ox8DXU/fA2GG0jILjB6UpFyNugkY9rg6oI31UnvfVi3R7sr3/x8Ea3I9thPvqI2byF6cojknSpDAwYzeKdngX3TAQEGzFHz3SDWwyp3jeMWfwvVVbM38FxhvAnSumw7YwWW4L7M7h4M68isLimoT3yfCn2ucBVL5Dz8koBpYf/40w7QidClAwCafZQFC29yDOg=="', # rubocop:disable Layout/LineLength } - expect(body_as_json).to match( + expect(response.parsed_body).to match( signed_request: true, signature_actor_id: nil, error: 'Unable to fetch key JSON at https://remote.domain/users/alice#main-key' diff --git a/spec/requests/well_known/node_info_spec.rb b/spec/requests/well_known/node_info_spec.rb index d02732c32b..3d5afc7e2d 100644 --- a/spec/requests/well_known/node_info_spec.rb +++ b/spec/requests/well_known/node_info_spec.rb @@ -13,7 +13,7 @@ RSpec.describe 'The well-known node-info endpoints' do media_type: 'application/json' ) - expect(body_as_json).to include( + expect(response.parsed_body).to include( links: be_an(Array).and( contain_exactly( include( @@ -39,7 +39,7 @@ RSpec.describe 'The well-known node-info endpoints' do expect(non_matching_hash) .to_not match_json_schema('nodeinfo_2.0') - expect(body_as_json) + expect(response.parsed_body) .to match_json_schema('nodeinfo_2.0') .and include( version: '2.0', diff --git a/spec/requests/well_known/oauth_metadata_spec.rb b/spec/requests/well_known/oauth_metadata_spec.rb index 378295b5a3..9c86dbedfe 100644 --- a/spec/requests/well_known/oauth_metadata_spec.rb +++ b/spec/requests/well_known/oauth_metadata_spec.rb @@ -21,7 +21,7 @@ RSpec.describe 'The /.well-known/oauth-authorization-server request' do grant_types_supported = Doorkeeper.configuration.grant_flows.dup grant_types_supported << 'refresh_token' if Doorkeeper.configuration.refresh_token_enabled? - expect(body_as_json).to include( + expect(response.parsed_body).to include( issuer: root_url(protocol: protocol), service_documentation: 'https://docs.joinmastodon.org/', authorization_endpoint: oauth_authorization_url(protocol: protocol), diff --git a/spec/requests/well_known/webfinger_spec.rb b/spec/requests/well_known/webfinger_spec.rb index e5ce352d50..6880ba4b58 100644 --- a/spec/requests/well_known/webfinger_spec.rb +++ b/spec/requests/well_known/webfinger_spec.rb @@ -24,7 +24,7 @@ RSpec.describe 'The /.well-known/webfinger endpoint' do expect(response.media_type).to eq 'application/jrd+json' - expect(body_as_json) + expect(response.parsed_body) .to include( subject: eq('acct:alice@cb6e6126.ngrok.io'), aliases: include('https://cb6e6126.ngrok.io/@alice', 'https://cb6e6126.ngrok.io/users/alice') @@ -129,7 +129,7 @@ RSpec.describe 'The /.well-known/webfinger endpoint' do end it 'returns links for the internal account' do - expect(body_as_json) + expect(response.parsed_body) .to include( subject: 'acct:mastodon.internal@cb6e6126.ngrok.io', aliases: ['https://cb6e6126.ngrok.io/actor'] @@ -168,7 +168,7 @@ RSpec.describe 'The /.well-known/webfinger endpoint' do it 'returns avatar in response' do perform_request! - avatar_link = get_avatar_link(body_as_json) + avatar_link = get_avatar_link(response.parsed_body) expect(avatar_link).to_not be_nil expect(avatar_link[:type]).to eq alice.avatar.content_type expect(avatar_link[:href]).to eq Addressable::URI.new(host: Rails.configuration.x.local_domain, path: alice.avatar.to_s, scheme: 'https').to_s @@ -182,7 +182,7 @@ RSpec.describe 'The /.well-known/webfinger endpoint' do it 'does not return avatar in response' do perform_request! - avatar_link = get_avatar_link(body_as_json) + avatar_link = get_avatar_link(response.parsed_body) expect(avatar_link).to be_nil end end @@ -197,7 +197,7 @@ RSpec.describe 'The /.well-known/webfinger endpoint' do it 'does not return avatar in response' do perform_request! - avatar_link = get_avatar_link(body_as_json) + avatar_link = get_avatar_link(response.parsed_body) expect(avatar_link).to be_nil end end @@ -212,7 +212,7 @@ RSpec.describe 'The /.well-known/webfinger endpoint' do end it 'does not return avatar in response' do - avatar_link = get_avatar_link(body_as_json) + avatar_link = get_avatar_link(response.parsed_body) expect(avatar_link).to be_nil end end diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 60bec918ea..2a27544407 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -34,10 +34,6 @@ RSpec.configure do |config| end end -def body_as_json - response.parsed_body -end - def serialized_record_json(record, serializer, adapter: nil) options = { serializer: serializer } options[:adapter] = adapter if adapter.present? From ebf09328d4b17ad199ecfe364b84aa9b3da3f9b3 Mon Sep 17 00:00:00 2001 From: Claire Date: Fri, 6 Sep 2024 12:58:53 +0200 Subject: [PATCH 133/153] Disable codecov github annotations (#31783) --- .github/codecov.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/codecov.yml b/.github/codecov.yml index 701ba3af8f..d9b43b2594 100644 --- a/.github/codecov.yml +++ b/.github/codecov.yml @@ -1,3 +1,4 @@ +annotations: false comment: false # Do not leave PR comments coverage: status: From 1fed11cfa77c12135c68d5eff8c0d8760605b2b2 Mon Sep 17 00:00:00 2001 From: Claire Date: Fri, 6 Sep 2024 14:33:38 +0200 Subject: [PATCH 134/153] Target firefox all the way back to Firefox 78 (#31782) --- .browserslistrc | 1 + 1 file changed, 1 insertion(+) diff --git a/.browserslistrc b/.browserslistrc index 0376af4bcc..6367e4d358 100644 --- a/.browserslistrc +++ b/.browserslistrc @@ -1,6 +1,7 @@ [production] defaults > 0.2% +firefox >= 78 ios >= 15.6 not dead not OperaMini all From fd7fc7bdc36ea559d70edfa8cc811bed18baefc9 Mon Sep 17 00:00:00 2001 From: Emelia Smith Date: Fri, 6 Sep 2024 14:50:30 +0200 Subject: [PATCH 135/153] Disable actions on reports that have already been taken (#31773) --- app/models/admin/account_action.rb | 8 ++++++++ app/views/admin/account_actions/new.html.haml | 8 ++++++++ app/views/admin/reports/_actions.html.haml | 12 +++++++++--- config/locales/en.yml | 3 +++ 4 files changed, 28 insertions(+), 3 deletions(-) diff --git a/app/models/admin/account_action.rb b/app/models/admin/account_action.rb index 3700ce4cd6..4be58ba853 100644 --- a/app/models/admin/account_action.rb +++ b/app/models/admin/account_action.rb @@ -73,6 +73,14 @@ class Admin::AccountAction end end + def disabled_types_for_account(account) + if account.suspended? + %w(silence suspend) + elsif account.silenced? + %w(silence) + end + end + def i18n_scope :activerecord end diff --git a/app/views/admin/account_actions/new.html.haml b/app/views/admin/account_actions/new.html.haml index bce1c31760..5b98582d8c 100644 --- a/app/views/admin/account_actions/new.html.haml +++ b/app/views/admin/account_actions/new.html.haml @@ -1,6 +1,13 @@ - content_for :page_title do = t('admin.account_actions.title', acct: @account.pretty_acct) +- if @account.suspended? + .flash-message.alert + = t('admin.account_actions.already_suspended') +- elsif @account.silenced? + .flash-message.warn + = t('admin.account_actions.already_silenced') + = simple_form_for @account_action, url: admin_account_action_path(@account.id) do |f| = f.input :report_id, as: :hidden @@ -9,6 +16,7 @@ = f.input :type, as: :radio_buttons, collection: Admin::AccountAction.types_for_account(@account), + disabled: Admin::AccountAction.disabled_types_for_account(@account), hint: t('simple_form.hints.admin_account_action.type_html', acct: @account.pretty_acct), include_blank: false, label_method: ->(type) { account_action_type_label(type) }, diff --git a/app/views/admin/reports/_actions.html.haml b/app/views/admin/reports/_actions.html.haml index 5fb540931b..7317d401e7 100644 --- a/app/views/admin/reports/_actions.html.haml +++ b/app/views/admin/reports/_actions.html.haml @@ -17,21 +17,27 @@ .report-actions__item__button = form.button t('admin.reports.delete_and_resolve'), name: :delete, - class: 'button button--destructive' + class: 'button button--destructive', + disabled: statuses.empty?, + title: statuses.empty? ? t('admin.reports.actions_no_posts') : '' .report-actions__item__description = t('admin.reports.actions.delete_description_html') .report-actions__item .report-actions__item__button = form.button t('admin.accounts.silence'), name: :silence, - class: 'button button--destructive' + class: 'button button--destructive', + disabled: report.target_account.silenced? || report.target_account.suspended?, + title: report.target_account.silenced? ? t('admin.account_actions.already_silenced') : '' .report-actions__item__description = t('admin.reports.actions.silence_description_html') .report-actions__item .report-actions__item__button = form.button t('admin.accounts.suspend'), name: :suspend, - class: 'button button--destructive' + class: 'button button--destructive', + disabled: report.target_account.suspended?, + title: report.target_account.suspended? ? t('admin.account_actions.already_suspended') : '' .report-actions__item__description = t('admin.reports.actions.suspend_description_html') .report-actions__item diff --git a/config/locales/en.yml b/config/locales/en.yml index 267e04618b..217b1537f4 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -25,6 +25,8 @@ en: admin: account_actions: action: Perform action + already_silenced: This account has already been silenced. + already_suspended: This account has already been suspended. title: Perform moderation action on %{acct} account_moderation_notes: create: Leave note @@ -602,6 +604,7 @@ en: suspend_description_html: The account and all its contents will be inaccessible and eventually deleted, and interacting with it will be impossible. Reversible within 30 days. Closes all reports against this account. actions_description_html: Decide which action to take to resolve this report. If you take a punitive action against the reported account, an email notification will be sent to them, except when the Spam category is selected. actions_description_remote_html: Decide which action to take to resolve this report. This will only affect how your server communicates with this remote account and handle its content. + actions_no_posts: This report doesn't have any associated posts to delete add_to_report: Add more to report already_suspended_badges: local: Already suspended on this server From a9d0b48b6566f5e06337a84745cdd624a6b31426 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Fri, 6 Sep 2024 09:58:46 -0400 Subject: [PATCH 136/153] Set "admin" body class from `admin` nested layout (#31269) --- app/controllers/admin/base_controller.rb | 5 ----- app/controllers/auth/registrations_controller.rb | 5 ----- app/controllers/disputes/base_controller.rb | 5 ----- app/controllers/filters/statuses_controller.rb | 5 ----- app/controllers/filters_controller.rb | 5 ----- app/controllers/invites_controller.rb | 5 ----- .../oauth/authorized_applications_controller.rb | 5 ----- app/controllers/relationships_controller.rb | 5 ----- app/controllers/settings/base_controller.rb | 5 ----- app/controllers/severed_relationships_controller.rb | 5 ----- app/controllers/statuses_cleanup_controller.rb | 5 ----- app/helpers/application_helper.rb | 1 + app/views/layouts/admin.html.haml | 2 ++ spec/helpers/application_helper_spec.rb | 11 ++++++++++- 14 files changed, 13 insertions(+), 56 deletions(-) diff --git a/app/controllers/admin/base_controller.rb b/app/controllers/admin/base_controller.rb index 4b5afbe157..48685db17a 100644 --- a/app/controllers/admin/base_controller.rb +++ b/app/controllers/admin/base_controller.rb @@ -7,17 +7,12 @@ module Admin layout 'admin' - before_action :set_body_classes before_action :set_cache_headers after_action :verify_authorized private - def set_body_classes - @body_classes = 'admin' - end - def set_cache_headers response.cache_control.replace(private: true, no_store: true) end diff --git a/app/controllers/auth/registrations_controller.rb b/app/controllers/auth/registrations_controller.rb index c12960934e..4d94c80158 100644 --- a/app/controllers/auth/registrations_controller.rb +++ b/app/controllers/auth/registrations_controller.rb @@ -11,7 +11,6 @@ class Auth::RegistrationsController < Devise::RegistrationsController before_action :configure_sign_up_params, only: [:create] before_action :set_sessions, only: [:edit, :update] before_action :set_strikes, only: [:edit, :update] - before_action :set_body_classes, only: [:new, :create, :edit, :update] before_action :require_not_suspended!, only: [:update] before_action :set_cache_headers, only: [:edit, :update] before_action :set_rules, only: :new @@ -104,10 +103,6 @@ class Auth::RegistrationsController < Devise::RegistrationsController private - def set_body_classes - @body_classes = 'admin' if %w(edit update).include?(action_name) - end - def set_invite @invite = begin invite = Invite.find_by(code: invite_code) if invite_code.present? diff --git a/app/controllers/disputes/base_controller.rb b/app/controllers/disputes/base_controller.rb index 1054f3db80..dd24a1b740 100644 --- a/app/controllers/disputes/base_controller.rb +++ b/app/controllers/disputes/base_controller.rb @@ -7,16 +7,11 @@ class Disputes::BaseController < ApplicationController skip_before_action :require_functional! - before_action :set_body_classes before_action :authenticate_user! before_action :set_cache_headers private - def set_body_classes - @body_classes = 'admin' - end - def set_cache_headers response.cache_control.replace(private: true, no_store: true) end diff --git a/app/controllers/filters/statuses_controller.rb b/app/controllers/filters/statuses_controller.rb index 94993f938b..7ada13f680 100644 --- a/app/controllers/filters/statuses_controller.rb +++ b/app/controllers/filters/statuses_controller.rb @@ -6,7 +6,6 @@ class Filters::StatusesController < ApplicationController before_action :authenticate_user! before_action :set_filter before_action :set_status_filters - before_action :set_body_classes before_action :set_cache_headers PER_PAGE = 20 @@ -42,10 +41,6 @@ class Filters::StatusesController < ApplicationController 'remove' if params[:remove] end - def set_body_classes - @body_classes = 'admin' - end - def set_cache_headers response.cache_control.replace(private: true, no_store: true) end diff --git a/app/controllers/filters_controller.rb b/app/controllers/filters_controller.rb index bd9964426b..8c4e867e93 100644 --- a/app/controllers/filters_controller.rb +++ b/app/controllers/filters_controller.rb @@ -5,7 +5,6 @@ class FiltersController < ApplicationController before_action :authenticate_user! before_action :set_filter, only: [:edit, :update, :destroy] - before_action :set_body_classes before_action :set_cache_headers def index @@ -52,10 +51,6 @@ class FiltersController < ApplicationController params.require(:custom_filter).permit(:title, :expires_in, :filter_action, context: [], keywords_attributes: [:id, :keyword, :whole_word, :_destroy]) end - def set_body_classes - @body_classes = 'admin' - end - def set_cache_headers response.cache_control.replace(private: true, no_store: true) end diff --git a/app/controllers/invites_controller.rb b/app/controllers/invites_controller.rb index 9bc5164d59..070852695e 100644 --- a/app/controllers/invites_controller.rb +++ b/app/controllers/invites_controller.rb @@ -6,7 +6,6 @@ class InvitesController < ApplicationController layout 'admin' before_action :authenticate_user! - before_action :set_body_classes before_action :set_cache_headers def index @@ -47,10 +46,6 @@ class InvitesController < ApplicationController params.require(:invite).permit(:max_uses, :expires_in, :autofollow, :comment) end - def set_body_classes - @body_classes = 'admin' - end - def set_cache_headers response.cache_control.replace(private: true, no_store: true) end diff --git a/app/controllers/oauth/authorized_applications_controller.rb b/app/controllers/oauth/authorized_applications_controller.rb index 7bb22453ca..267409a9ce 100644 --- a/app/controllers/oauth/authorized_applications_controller.rb +++ b/app/controllers/oauth/authorized_applications_controller.rb @@ -6,7 +6,6 @@ class Oauth::AuthorizedApplicationsController < Doorkeeper::AuthorizedApplicatio before_action :store_current_location before_action :authenticate_resource_owner! before_action :require_not_suspended!, only: :destroy - before_action :set_body_classes before_action :set_cache_headers before_action :set_last_used_at_by_app, only: :index, unless: -> { request.format == :json } @@ -23,10 +22,6 @@ class Oauth::AuthorizedApplicationsController < Doorkeeper::AuthorizedApplicatio private - def set_body_classes - @body_classes = 'admin' - end - def store_current_location store_location_for(:user, request.url) end diff --git a/app/controllers/relationships_controller.rb b/app/controllers/relationships_controller.rb index dd794f3199..d351afcfb7 100644 --- a/app/controllers/relationships_controller.rb +++ b/app/controllers/relationships_controller.rb @@ -6,7 +6,6 @@ class RelationshipsController < ApplicationController before_action :authenticate_user! before_action :set_accounts, only: :show before_action :set_relationships, only: :show - before_action :set_body_classes before_action :set_cache_headers helper_method :following_relationship?, :followed_by_relationship?, :mutual_relationship? @@ -68,10 +67,6 @@ class RelationshipsController < ApplicationController end end - def set_body_classes - @body_classes = 'admin' - end - def set_cache_headers response.cache_control.replace(private: true, no_store: true) end diff --git a/app/controllers/settings/base_controller.rb b/app/controllers/settings/base_controller.rb index f15140aa2b..188334ac23 100644 --- a/app/controllers/settings/base_controller.rb +++ b/app/controllers/settings/base_controller.rb @@ -4,15 +4,10 @@ class Settings::BaseController < ApplicationController layout 'admin' before_action :authenticate_user! - before_action :set_body_classes before_action :set_cache_headers private - def set_body_classes - @body_classes = 'admin' - end - def set_cache_headers response.cache_control.replace(private: true, no_store: true) end diff --git a/app/controllers/severed_relationships_controller.rb b/app/controllers/severed_relationships_controller.rb index 168e85e3fe..965753a26f 100644 --- a/app/controllers/severed_relationships_controller.rb +++ b/app/controllers/severed_relationships_controller.rb @@ -4,7 +4,6 @@ class SeveredRelationshipsController < ApplicationController layout 'admin' before_action :authenticate_user! - before_action :set_body_classes before_action :set_cache_headers before_action :set_event, only: [:following, :followers] @@ -51,10 +50,6 @@ class SeveredRelationshipsController < ApplicationController account.local? ? account.local_username_and_domain : account.acct end - def set_body_classes - @body_classes = 'admin' - end - def set_cache_headers response.cache_control.replace(private: true, no_store: true) end diff --git a/app/controllers/statuses_cleanup_controller.rb b/app/controllers/statuses_cleanup_controller.rb index 4a3fc10ca4..e517bf3ae8 100644 --- a/app/controllers/statuses_cleanup_controller.rb +++ b/app/controllers/statuses_cleanup_controller.rb @@ -5,7 +5,6 @@ class StatusesCleanupController < ApplicationController before_action :authenticate_user! before_action :set_policy - before_action :set_body_classes before_action :set_cache_headers def show; end @@ -34,10 +33,6 @@ class StatusesCleanupController < ApplicationController params.require(:account_statuses_cleanup_policy).permit(:enabled, :min_status_age, :keep_direct, :keep_pinned, :keep_polls, :keep_media, :keep_self_fav, :keep_self_bookmark, :min_favs, :min_reblogs) end - def set_body_classes - @body_classes = 'admin' - end - def set_cache_headers response.cache_control.replace(private: true, no_store: true) end diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index 7c91df8d4f..de00f76d36 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -159,6 +159,7 @@ module ApplicationHelper def body_classes output = body_class_string.split + output << content_for(:body_classes) output << "theme-#{current_theme.parameterize}" output << 'system-font' if current_account&.user&.setting_system_font_ui output << (current_account&.user&.setting_reduce_motion ? 'reduce-motion' : 'no-reduce-motion') diff --git a/app/views/layouts/admin.html.haml b/app/views/layouts/admin.html.haml index ebd236c628..3f7727cdfb 100644 --- a/app/views/layouts/admin.html.haml +++ b/app/views/layouts/admin.html.haml @@ -3,6 +3,8 @@ = javascript_pack_tag 'public', crossorigin: 'anonymous' = javascript_pack_tag 'admin', async: true, crossorigin: 'anonymous' +- content_for :body_classes, 'admin' + - content_for :content do .admin-wrapper .sidebar-wrapper diff --git a/spec/helpers/application_helper_spec.rb b/spec/helpers/application_helper_spec.rb index c2e618c7de..0f78dc82f5 100644 --- a/spec/helpers/application_helper_spec.rb +++ b/spec/helpers/application_helper_spec.rb @@ -8,7 +8,16 @@ RSpec.describe ApplicationHelper do before { helper.extend controller_helpers } it 'uses the controller body classes in the result' do - expect(helper.body_classes).to match(/modal-layout compose-standalone/) + expect(helper.body_classes) + .to match(/modal-layout compose-standalone/) + .and match(/theme-default/) + end + + it 'includes values set via content_for' do + helper.content_for(:body_classes) { 'admin' } + + expect(helper.body_classes) + .to match(/admin/) end private From c88ba523ee6eebb11413690639818ef1c926399c Mon Sep 17 00:00:00 2001 From: Emelia Smith Date: Fri, 6 Sep 2024 16:58:36 +0200 Subject: [PATCH 137/153] Fix sort order of moderation notes on Reports and Accounts (#31528) --- .../account_moderation_notes_controller.rb | 2 +- app/controllers/admin/accounts_controller.rb | 2 +- .../admin/report_notes_controller.rb | 2 +- app/controllers/admin/reports_controller.rb | 2 +- app/models/account_moderation_note.rb | 2 +- app/models/report_note.rb | 2 +- .../admin/accounts_controller_spec.rb | 17 ++++++++++ .../admin/reports_controller_spec.rb | 18 +++++++++++ .../account_moderation_note_fabricator.rb | 2 +- spec/fabricators/report_note_fabricator.rb | 2 +- spec/models/account_moderation_note_spec.rb | 31 +++++++++++++++++++ spec/models/report_note_spec.rb | 31 +++++++++++++++++++ 12 files changed, 105 insertions(+), 8 deletions(-) create mode 100644 spec/models/account_moderation_note_spec.rb create mode 100644 spec/models/report_note_spec.rb diff --git a/app/controllers/admin/account_moderation_notes_controller.rb b/app/controllers/admin/account_moderation_notes_controller.rb index 8b6c1a4454..a3c4adf59a 100644 --- a/app/controllers/admin/account_moderation_notes_controller.rb +++ b/app/controllers/admin/account_moderation_notes_controller.rb @@ -13,7 +13,7 @@ module Admin redirect_to admin_account_path(@account_moderation_note.target_account_id), notice: I18n.t('admin.account_moderation_notes.created_msg') else @account = @account_moderation_note.target_account - @moderation_notes = @account.targeted_moderation_notes.latest + @moderation_notes = @account.targeted_moderation_notes.chronological.includes(:account) @warnings = @account.strikes.custom.latest render 'admin/accounts/show' diff --git a/app/controllers/admin/accounts_controller.rb b/app/controllers/admin/accounts_controller.rb index 9beb8fde6b..7b169ba26a 100644 --- a/app/controllers/admin/accounts_controller.rb +++ b/app/controllers/admin/accounts_controller.rb @@ -33,7 +33,7 @@ module Admin @deletion_request = @account.deletion_request @account_moderation_note = current_account.account_moderation_notes.new(target_account: @account) - @moderation_notes = @account.targeted_moderation_notes.latest + @moderation_notes = @account.targeted_moderation_notes.chronological.includes(:account) @warnings = @account.strikes.includes(:target_account, :account, :appeal).latest @domain_block = DomainBlock.rule_for(@account.domain) end diff --git a/app/controllers/admin/report_notes_controller.rb b/app/controllers/admin/report_notes_controller.rb index b5f04a1caa..6b16c29fc7 100644 --- a/app/controllers/admin/report_notes_controller.rb +++ b/app/controllers/admin/report_notes_controller.rb @@ -21,7 +21,7 @@ module Admin redirect_to after_create_redirect_path, notice: I18n.t('admin.report_notes.created_msg') else - @report_notes = @report.notes.includes(:account).order(id: :desc) + @report_notes = @report.notes.chronological.includes(:account) @action_logs = @report.history.includes(:target) @form = Admin::StatusBatchAction.new @statuses = @report.statuses.with_includes diff --git a/app/controllers/admin/reports_controller.rb b/app/controllers/admin/reports_controller.rb index 00d200d7c8..aa877f1448 100644 --- a/app/controllers/admin/reports_controller.rb +++ b/app/controllers/admin/reports_controller.rb @@ -13,7 +13,7 @@ module Admin authorize @report, :show? @report_note = @report.notes.new - @report_notes = @report.notes.includes(:account).order(id: :desc) + @report_notes = @report.notes.chronological.includes(:account) @action_logs = @report.history.includes(:target) @form = Admin::StatusBatchAction.new @statuses = @report.statuses.with_includes diff --git a/app/models/account_moderation_note.rb b/app/models/account_moderation_note.rb index 79b8b4d25e..ca7f8e3d5f 100644 --- a/app/models/account_moderation_note.rb +++ b/app/models/account_moderation_note.rb @@ -18,7 +18,7 @@ class AccountModerationNote < ApplicationRecord belongs_to :account belongs_to :target_account, class_name: 'Account' - scope :latest, -> { reorder('created_at DESC') } + scope :chronological, -> { reorder(id: :asc) } validates :content, presence: true, length: { maximum: CONTENT_SIZE_LIMIT } end diff --git a/app/models/report_note.rb b/app/models/report_note.rb index 7361c97e67..9d3be52594 100644 --- a/app/models/report_note.rb +++ b/app/models/report_note.rb @@ -18,7 +18,7 @@ class ReportNote < ApplicationRecord belongs_to :account belongs_to :report, inverse_of: :notes, touch: true - scope :latest, -> { reorder(created_at: :desc) } + scope :chronological, -> { reorder(id: :asc) } validates :content, presence: true, length: { maximum: CONTENT_SIZE_LIMIT } end diff --git a/spec/controllers/admin/accounts_controller_spec.rb b/spec/controllers/admin/accounts_controller_spec.rb index ca399fbd9b..a182300106 100644 --- a/spec/controllers/admin/accounts_controller_spec.rb +++ b/spec/controllers/admin/accounts_controller_spec.rb @@ -55,6 +55,23 @@ RSpec.describe Admin::AccountsController do describe 'GET #show' do let(:current_user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) } + describe 'account moderation notes' do + let(:account) { Fabricate(:account) } + + it 'includes moderation notes' do + note1 = Fabricate(:account_moderation_note, target_account: account) + note2 = Fabricate(:account_moderation_note, target_account: account) + + get :show, params: { id: account.id } + expect(response).to have_http_status(200) + + moderation_notes = assigns(:moderation_notes).to_a + + expect(moderation_notes.size).to be 2 + expect(moderation_notes).to eq [note1, note2] + end + end + context 'with a remote account' do let(:account) { Fabricate(:account, domain: 'example.com') } diff --git a/spec/controllers/admin/reports_controller_spec.rb b/spec/controllers/admin/reports_controller_spec.rb index d07468a37b..1252ceb1f4 100644 --- a/spec/controllers/admin/reports_controller_spec.rb +++ b/spec/controllers/admin/reports_controller_spec.rb @@ -47,6 +47,24 @@ RSpec.describe Admin::ReportsController do expect(response.body) .to include(report.comment) end + + describe 'account moderation notes' do + let(:report) { Fabricate(:report) } + + it 'includes moderation notes' do + note1 = Fabricate(:report_note, report: report) + note2 = Fabricate(:report_note, report: report) + + get :show, params: { id: report } + + expect(response).to have_http_status(200) + + report_notes = assigns(:report_notes).to_a + + expect(report_notes.size).to be 2 + expect(report_notes).to eq [note1, note2] + end + end end describe 'POST #resolve' do diff --git a/spec/fabricators/account_moderation_note_fabricator.rb b/spec/fabricators/account_moderation_note_fabricator.rb index 05a687bf4e..1ded862638 100644 --- a/spec/fabricators/account_moderation_note_fabricator.rb +++ b/spec/fabricators/account_moderation_note_fabricator.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true Fabricator(:account_moderation_note) do - content 'MyText' + content { Faker::Lorem.sentences } account { Fabricate.build(:account) } target_account { Fabricate.build(:account) } end diff --git a/spec/fabricators/report_note_fabricator.rb b/spec/fabricators/report_note_fabricator.rb index 080fad51ac..a5e9cc9009 100644 --- a/spec/fabricators/report_note_fabricator.rb +++ b/spec/fabricators/report_note_fabricator.rb @@ -3,5 +3,5 @@ Fabricator(:report_note) do report { Fabricate.build(:report) } account { Fabricate.build(:account) } - content 'Test Content' + content { Faker::Lorem.sentences } end diff --git a/spec/models/account_moderation_note_spec.rb b/spec/models/account_moderation_note_spec.rb new file mode 100644 index 0000000000..079774c492 --- /dev/null +++ b/spec/models/account_moderation_note_spec.rb @@ -0,0 +1,31 @@ +# frozen_string_literal: true + +require 'rails_helper' + +RSpec.describe AccountModerationNote do + describe 'chronological scope' do + it 'returns account moderation notes oldest to newest' do + account = Fabricate(:account) + note1 = Fabricate(:account_moderation_note, target_account: account) + note2 = Fabricate(:account_moderation_note, target_account: account) + + expect(account.targeted_moderation_notes.chronological).to eq [note1, note2] + end + end + + describe 'validations' do + it 'is invalid if the content is empty' do + report = Fabricate.build(:account_moderation_note, content: '') + expect(report.valid?).to be false + end + + it 'is invalid if content is longer than character limit' do + report = Fabricate.build(:account_moderation_note, content: comment_over_limit) + expect(report.valid?).to be false + end + + def comment_over_limit + Faker::Lorem.paragraph_by_chars(number: described_class::CONTENT_SIZE_LIMIT * 2) + end + end +end diff --git a/spec/models/report_note_spec.rb b/spec/models/report_note_spec.rb new file mode 100644 index 0000000000..417971c9a1 --- /dev/null +++ b/spec/models/report_note_spec.rb @@ -0,0 +1,31 @@ +# frozen_string_literal: true + +require 'rails_helper' + +RSpec.describe ReportNote do + describe 'chronological scope' do + it 'returns report notes oldest to newest' do + report = Fabricate(:report) + note1 = Fabricate(:report_note, report: report) + note2 = Fabricate(:report_note, report: report) + + expect(report.notes.chronological).to eq [note1, note2] + end + end + + describe 'validations' do + it 'is invalid if the content is empty' do + report = Fabricate.build(:report_note, content: '') + expect(report.valid?).to be false + end + + it 'is invalid if content is longer than character limit' do + report = Fabricate.build(:report_note, content: comment_over_limit) + expect(report.valid?).to be false + end + + def comment_over_limit + Faker::Lorem.paragraph_by_chars(number: described_class::CONTENT_SIZE_LIMIT * 2) + end + end +end From b530fc5267e14b4eab0322d63af94525e999fd39 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Fri, 6 Sep 2024 11:22:35 -0400 Subject: [PATCH 138/153] Update rails to version 7.1.4 (#31563) --- Gemfile.lock | 106 +++++++++--------- .../initializers/active_record_encryption.rb | 4 - 2 files changed, 53 insertions(+), 57 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index 8577a52691..a988ad3f21 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -10,35 +10,35 @@ GIT GEM remote: https://rubygems.org/ specs: - actioncable (7.1.3.4) - actionpack (= 7.1.3.4) - activesupport (= 7.1.3.4) + actioncable (7.1.4) + actionpack (= 7.1.4) + activesupport (= 7.1.4) nio4r (~> 2.0) websocket-driver (>= 0.6.1) zeitwerk (~> 2.6) - actionmailbox (7.1.3.4) - actionpack (= 7.1.3.4) - activejob (= 7.1.3.4) - activerecord (= 7.1.3.4) - activestorage (= 7.1.3.4) - activesupport (= 7.1.3.4) + actionmailbox (7.1.4) + actionpack (= 7.1.4) + activejob (= 7.1.4) + activerecord (= 7.1.4) + activestorage (= 7.1.4) + activesupport (= 7.1.4) mail (>= 2.7.1) net-imap net-pop net-smtp - actionmailer (7.1.3.4) - actionpack (= 7.1.3.4) - actionview (= 7.1.3.4) - activejob (= 7.1.3.4) - activesupport (= 7.1.3.4) + actionmailer (7.1.4) + actionpack (= 7.1.4) + actionview (= 7.1.4) + activejob (= 7.1.4) + activesupport (= 7.1.4) mail (~> 2.5, >= 2.5.4) net-imap net-pop net-smtp rails-dom-testing (~> 2.2) - actionpack (7.1.3.4) - actionview (= 7.1.3.4) - activesupport (= 7.1.3.4) + actionpack (7.1.4) + actionview (= 7.1.4) + activesupport (= 7.1.4) nokogiri (>= 1.8.5) racc rack (>= 2.2.4) @@ -46,15 +46,15 @@ GEM rack-test (>= 0.6.3) rails-dom-testing (~> 2.2) rails-html-sanitizer (~> 1.6) - actiontext (7.1.3.4) - actionpack (= 7.1.3.4) - activerecord (= 7.1.3.4) - activestorage (= 7.1.3.4) - activesupport (= 7.1.3.4) + actiontext (7.1.4) + actionpack (= 7.1.4) + activerecord (= 7.1.4) + activestorage (= 7.1.4) + activesupport (= 7.1.4) globalid (>= 0.6.0) nokogiri (>= 1.8.5) - actionview (7.1.3.4) - activesupport (= 7.1.3.4) + actionview (7.1.4) + activesupport (= 7.1.4) builder (~> 3.1) erubi (~> 1.11) rails-dom-testing (~> 2.2) @@ -64,22 +64,22 @@ GEM activemodel (>= 4.1) case_transform (>= 0.2) jsonapi-renderer (>= 0.1.1.beta1, < 0.3) - activejob (7.1.3.4) - activesupport (= 7.1.3.4) + activejob (7.1.4) + activesupport (= 7.1.4) globalid (>= 0.3.6) - activemodel (7.1.3.4) - activesupport (= 7.1.3.4) - activerecord (7.1.3.4) - activemodel (= 7.1.3.4) - activesupport (= 7.1.3.4) + activemodel (7.1.4) + activesupport (= 7.1.4) + activerecord (7.1.4) + activemodel (= 7.1.4) + activesupport (= 7.1.4) timeout (>= 0.4.0) - activestorage (7.1.3.4) - actionpack (= 7.1.3.4) - activejob (= 7.1.3.4) - activerecord (= 7.1.3.4) - activesupport (= 7.1.3.4) + activestorage (7.1.4) + actionpack (= 7.1.4) + activejob (= 7.1.4) + activerecord (= 7.1.4) + activesupport (= 7.1.4) marcel (~> 1.0) - activesupport (7.1.3.4) + activesupport (7.1.4) base64 bigdecimal concurrent-ruby (~> 1.0, >= 1.0.2) @@ -638,20 +638,20 @@ GEM rackup (1.0.0) rack (< 3) webrick - rails (7.1.3.4) - actioncable (= 7.1.3.4) - actionmailbox (= 7.1.3.4) - actionmailer (= 7.1.3.4) - actionpack (= 7.1.3.4) - actiontext (= 7.1.3.4) - actionview (= 7.1.3.4) - activejob (= 7.1.3.4) - activemodel (= 7.1.3.4) - activerecord (= 7.1.3.4) - activestorage (= 7.1.3.4) - activesupport (= 7.1.3.4) + rails (7.1.4) + actioncable (= 7.1.4) + actionmailbox (= 7.1.4) + actionmailer (= 7.1.4) + actionpack (= 7.1.4) + actiontext (= 7.1.4) + actionview (= 7.1.4) + activejob (= 7.1.4) + activemodel (= 7.1.4) + activerecord (= 7.1.4) + activestorage (= 7.1.4) + activesupport (= 7.1.4) bundler (>= 1.15.0) - railties (= 7.1.3.4) + railties (= 7.1.4) rails-controller-testing (1.0.5) actionpack (>= 5.0.1.rc1) actionview (>= 5.0.1.rc1) @@ -666,9 +666,9 @@ GEM rails-i18n (7.0.9) i18n (>= 0.7, < 2) railties (>= 6.0.0, < 8) - railties (7.1.3.4) - actionpack (= 7.1.3.4) - activesupport (= 7.1.3.4) + railties (7.1.4) + actionpack (= 7.1.4) + activesupport (= 7.1.4) irb rackup (>= 1.0.0) rake (>= 12.2) diff --git a/config/initializers/active_record_encryption.rb b/config/initializers/active_record_encryption.rb index a83ca80765..b7a874e404 100644 --- a/config/initializers/active_record_encryption.rb +++ b/config/initializers/active_record_encryption.rb @@ -38,8 +38,4 @@ Rails.application.configure do config.active_record.encryption.key_derivation_salt = ENV.fetch('ACTIVE_RECORD_ENCRYPTION_KEY_DERIVATION_SALT') config.active_record.encryption.primary_key = ENV.fetch('ACTIVE_RECORD_ENCRYPTION_PRIMARY_KEY') config.active_record.encryption.support_sha1_for_non_deterministic_encryption = true - - # TODO: https://github.com/rails/rails/issues/50604#issuecomment-1880990392 - # Remove after updating to Rails 7.1.4 - ActiveRecord::Encryption.configure(**config.active_record.encryption) end From 4f81ad249477ad25aea191b1987cddb4222e65ba Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Fri, 6 Sep 2024 12:46:25 -0400 Subject: [PATCH 139/153] Add coverage for `media#player`, move body class to view (#31790) --- app/controllers/media_controller.rb | 4 +--- app/views/media/player.html.haml | 2 ++ spec/system/media_spec.rb | 23 +++++++++++++++++++++++ 3 files changed, 26 insertions(+), 3 deletions(-) create mode 100644 spec/system/media_spec.rb diff --git a/app/controllers/media_controller.rb b/app/controllers/media_controller.rb index 53eee40012..9d10468e69 100644 --- a/app/controllers/media_controller.rb +++ b/app/controllers/media_controller.rb @@ -19,9 +19,7 @@ class MediaController < ApplicationController redirect_to @media_attachment.file.url(:original) end - def player - @body_classes = 'player' - end + def player; end private diff --git a/app/views/media/player.html.haml b/app/views/media/player.html.haml index df02cc4110..6b6e566732 100644 --- a/app/views/media/player.html.haml +++ b/app/views/media/player.html.haml @@ -2,6 +2,8 @@ = render_initial_state = javascript_pack_tag 'public', crossorigin: 'anonymous' +- content_for :body_classes, 'player' + :ruby meta = @media_attachment.file.meta || {} diff --git a/spec/system/media_spec.rb b/spec/system/media_spec.rb new file mode 100644 index 0000000000..d014c7e88e --- /dev/null +++ b/spec/system/media_spec.rb @@ -0,0 +1,23 @@ +# frozen_string_literal: true + +require 'rails_helper' + +RSpec.describe 'Media' do + describe 'Player page' do + context 'when signed in' do + before { sign_in Fabricate(:user) } + + it 'visits the media player page and renders the media' do + status = Fabricate :status + media = Fabricate :media_attachment, type: :video + status.media_attachments << media + + visit medium_player_path(media) + + expect(page) + .to have_css('body', class: 'player') + .and have_css('div[data-component="Video"]') + end + end + end +end From 0a433d08fb51e0bfdd9e5f512af529f6abafa7a6 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Fri, 6 Sep 2024 12:46:55 -0400 Subject: [PATCH 140/153] Move shares/modal body class to layout (#31789) --- app/controllers/shares_controller.rb | 7 ------- app/views/layouts/modal.html.haml | 2 ++ 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/app/controllers/shares_controller.rb b/app/controllers/shares_controller.rb index 6546b84978..1aa0ce5a0d 100644 --- a/app/controllers/shares_controller.rb +++ b/app/controllers/shares_controller.rb @@ -4,13 +4,6 @@ class SharesController < ApplicationController layout 'modal' before_action :authenticate_user! - before_action :set_body_classes def show; end - - private - - def set_body_classes - @body_classes = 'modal-layout compose-standalone' - end end diff --git a/app/views/layouts/modal.html.haml b/app/views/layouts/modal.html.haml index bbc9185f5b..91bcb7c422 100644 --- a/app/views/layouts/modal.html.haml +++ b/app/views/layouts/modal.html.haml @@ -1,6 +1,8 @@ - content_for :header_tags do = javascript_pack_tag 'public', crossorigin: 'anonymous' +- content_for :body_classes, 'modal-layout compose-standalone' + - content_for :content do - if user_signed_in? && !@hide_header .account-header From 7335a43b6dac0e82c305ce4dec9db4da114c769e Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Fri, 6 Sep 2024 12:52:35 -0400 Subject: [PATCH 141/153] Use async count in admin dashboard (#30606) --- app/controllers/admin/dashboard_controller.rb | 8 ++++---- app/views/admin/dashboard/index.html.haml | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/app/controllers/admin/dashboard_controller.rb b/app/controllers/admin/dashboard_controller.rb index 3a6df662ea..5b0867dcfb 100644 --- a/app/controllers/admin/dashboard_controller.rb +++ b/app/controllers/admin/dashboard_controller.rb @@ -7,12 +7,12 @@ module Admin def index authorize :dashboard, :index? + @pending_appeals_count = Appeal.pending.async_count + @pending_reports_count = Report.unresolved.async_count + @pending_tags_count = Tag.pending_review.async_count + @pending_users_count = User.pending.async_count @system_checks = Admin::SystemCheck.perform(current_user) @time_period = (29.days.ago.to_date...Time.now.utc.to_date) - @pending_users_count = User.pending.count - @pending_reports_count = Report.unresolved.count - @pending_tags_count = Tag.pending_review.count - @pending_appeals_count = Appeal.pending.count end end end diff --git a/app/views/admin/dashboard/index.html.haml b/app/views/admin/dashboard/index.html.haml index 8430dd3c4f..27d8f4790b 100644 --- a/app/views/admin/dashboard/index.html.haml +++ b/app/views/admin/dashboard/index.html.haml @@ -56,19 +56,19 @@ .dashboard__item = link_to admin_reports_path, class: 'dashboard__quick-access' do - %span= t('admin.dashboard.pending_reports_html', count: @pending_reports_count) + %span= t('admin.dashboard.pending_reports_html', count: @pending_reports_count.value) = material_symbol 'chevron_right' = link_to admin_accounts_path(status: 'pending'), class: 'dashboard__quick-access' do - %span= t('admin.dashboard.pending_users_html', count: @pending_users_count) + %span= t('admin.dashboard.pending_users_html', count: @pending_users_count.value) = material_symbol 'chevron_right' = link_to admin_trends_tags_path(status: 'pending_review'), class: 'dashboard__quick-access' do - %span= t('admin.dashboard.pending_tags_html', count: @pending_tags_count) + %span= t('admin.dashboard.pending_tags_html', count: @pending_tags_count.value) = material_symbol 'chevron_right' = link_to admin_disputes_appeals_path(status: 'pending'), class: 'dashboard__quick-access' do - %span= t('admin.dashboard.pending_appeals_html', count: @pending_appeals_count) + %span= t('admin.dashboard.pending_appeals_html', count: @pending_appeals_count.value) = material_symbol 'chevron_right' .dashboard__item = react_admin_component :dimension, From b716248fc5bde4dc47b8104d092d092d87c50f1a Mon Sep 17 00:00:00 2001 From: Claire Date: Fri, 6 Sep 2024 19:21:49 +0200 Subject: [PATCH 142/153] Add link to `/admin/roles` in moderation interface when changing someone's role (#31791) --- app/views/admin/users/roles/show.html.haml | 3 ++- config/locales/en.yml | 1 + config/locales/simple_form.en.yml | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/app/views/admin/users/roles/show.html.haml b/app/views/admin/users/roles/show.html.haml index f26640f2a1..01b3830f4e 100644 --- a/app/views/admin/users/roles/show.html.haml +++ b/app/views/admin/users/roles/show.html.haml @@ -7,7 +7,8 @@ collection: UserRole.assignable, include_blank: I18n.t('admin.accounts.change_role.no_role'), label_method: :name, - wrapper: :with_block_label + wrapper: :with_block_label, + hint: safe_join([I18n.t('simple_form.hints.user.role'), ' ', link_to(I18n.t('admin.accounts.change_role.edit_roles'), admin_roles_path)]) .actions = f.button :button, diff --git a/config/locales/en.yml b/config/locales/en.yml index 217b1537f4..e8c9010486 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -48,6 +48,7 @@ en: title: Change email for %{username} change_role: changed_msg: Role successfully changed! + edit_roles: Manage user roles label: Change role no_role: No role title: Change role for %{username} diff --git a/config/locales/simple_form.en.yml b/config/locales/simple_form.en.yml index fee3a6151a..c1fae7e83e 100644 --- a/config/locales/simple_form.en.yml +++ b/config/locales/simple_form.en.yml @@ -130,7 +130,7 @@ en: name: You can only change the casing of the letters, for example, to make it more readable user: chosen_languages: When checked, only posts in selected languages will be displayed in public timelines - role: The role controls which permissions the user has + role: The role controls which permissions the user has. user_role: color: Color to be used for the role throughout the UI, as RGB in hex format highlighted: This makes the role publicly visible From af6ca96a4e1aa4fa718bc4929dab6618adf74c98 Mon Sep 17 00:00:00 2001 From: Claire Date: Fri, 6 Sep 2024 20:00:19 +0200 Subject: [PATCH 143/153] Fix tests in glitch-soc --- spec/helpers/application_helper_spec.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/spec/helpers/application_helper_spec.rb b/spec/helpers/application_helper_spec.rb index 50181fdb91..90dc0d36de 100644 --- a/spec/helpers/application_helper_spec.rb +++ b/spec/helpers/application_helper_spec.rb @@ -10,7 +10,8 @@ RSpec.describe ApplicationHelper do it 'uses the controller body classes in the result' do expect(helper.body_classes) .to match(/modal-layout compose-standalone/) - .and match(/theme-default/) + .and match(/flavour-glitch/) + .and match(/skin-default/) end it 'includes values set via content_for' do From 10143d053a99d69f5770f6a5478ab0f88a95ae5b Mon Sep 17 00:00:00 2001 From: Mike Dalessio Date: Sun, 8 Sep 2024 14:41:37 -0400 Subject: [PATCH 144/153] Change some instances of Nokogiri HTML4 parsing to HTML5 (#31812) --- app/helpers/admin/trends/statuses_helper.rb | 2 +- app/lib/emoji_formatter.rb | 8 ++++---- app/lib/plain_text_formatter.rb | 2 +- app/services/fetch_oembed_service.rb | 2 +- app/services/fetch_resource_service.rb | 2 +- app/services/translate_status_service.rb | 2 +- lib/sanitize_ext/sanitize_config.rb | 2 +- lib/tasks/emojis.rake | 2 +- 8 files changed, 11 insertions(+), 11 deletions(-) diff --git a/app/helpers/admin/trends/statuses_helper.rb b/app/helpers/admin/trends/statuses_helper.rb index 79fee44dc4..c7a59660cf 100644 --- a/app/helpers/admin/trends/statuses_helper.rb +++ b/app/helpers/admin/trends/statuses_helper.rb @@ -5,7 +5,7 @@ module Admin::Trends::StatusesHelper text = if status.local? status.text.split("\n").first else - Nokogiri::HTML(status.text).css('html > body > *').first&.text + Nokogiri::HTML5(status.text).css('html > body > *').first&.text end return '' if text.blank? diff --git a/app/lib/emoji_formatter.rb b/app/lib/emoji_formatter.rb index 2a3683c499..5f1a4651f7 100644 --- a/app/lib/emoji_formatter.rb +++ b/app/lib/emoji_formatter.rb @@ -24,7 +24,7 @@ class EmojiFormatter def to_s return html if custom_emojis.empty? || html.blank? - tree = Nokogiri::HTML.fragment(html) + tree = Nokogiri::HTML5.fragment(html) tree.xpath('./text()|.//text()[not(ancestor[@class="invisible"])]').to_a.each do |node| i = -1 inside_shortname = false @@ -43,8 +43,8 @@ class EmojiFormatter next unless (char_after.nil? || !DISALLOWED_BOUNDING_REGEX.match?(char_after)) && (emoji = emoji_map[shortcode]) - result << Nokogiri::XML::Text.new(text[last_index..shortname_start_index - 1], tree.document) if shortname_start_index.positive? - result << Nokogiri::HTML.fragment(tag_for_emoji(shortcode, emoji)) + result << tree.document.create_text_node(text[last_index..shortname_start_index - 1]) if shortname_start_index.positive? + result << tree.document.fragment(tag_for_emoji(shortcode, emoji)) last_index = i + 1 elsif text[i] == ':' && (i.zero? || !DISALLOWED_BOUNDING_REGEX.match?(text[i - 1])) @@ -53,7 +53,7 @@ class EmojiFormatter end end - result << Nokogiri::XML::Text.new(text[last_index..], tree.document) + result << tree.document.create_text_node(text[last_index..]) node.replace(result) end diff --git a/app/lib/plain_text_formatter.rb b/app/lib/plain_text_formatter.rb index d1ff6808b2..f960ba7acc 100644 --- a/app/lib/plain_text_formatter.rb +++ b/app/lib/plain_text_formatter.rb @@ -16,7 +16,7 @@ class PlainTextFormatter if local? text else - node = Nokogiri::HTML.fragment(insert_newlines) + node = Nokogiri::HTML5.fragment(insert_newlines) # Elements that are entirely removed with our Sanitize config node.xpath('.//iframe|.//math|.//noembed|.//noframes|.//noscript|.//plaintext|.//script|.//style|.//svg|.//xmp').remove node.text.chomp diff --git a/app/services/fetch_oembed_service.rb b/app/services/fetch_oembed_service.rb index dc84b16b68..c7d4f7e292 100644 --- a/app/services/fetch_oembed_service.rb +++ b/app/services/fetch_oembed_service.rb @@ -25,7 +25,7 @@ class FetchOEmbedService return if html.nil? @format = @options[:format] - page = Nokogiri::HTML(html) + page = Nokogiri::HTML5(html) if @format.nil? || @format == :json @endpoint_url ||= page.at_xpath('//link[@type="application/json+oembed"]|//link[@type="text/json+oembed"]')&.attribute('href')&.value diff --git a/app/services/fetch_resource_service.rb b/app/services/fetch_resource_service.rb index 84c36f6a10..b69015a5e9 100644 --- a/app/services/fetch_resource_service.rb +++ b/app/services/fetch_resource_service.rb @@ -73,7 +73,7 @@ class FetchResourceService < BaseService end def process_html(response) - page = Nokogiri::HTML(response.body_with_limit) + page = Nokogiri::HTML5(response.body_with_limit) json_link = page.xpath('//link[@rel="alternate"]').find { |link| ACTIVITY_STREAM_LINK_TYPES.include?(link['type']) } process(json_link['href'], terminal: true) unless json_link.nil? diff --git a/app/services/translate_status_service.rb b/app/services/translate_status_service.rb index 9ad146ae7d..e2e076e21b 100644 --- a/app/services/translate_status_service.rb +++ b/app/services/translate_status_service.rb @@ -100,7 +100,7 @@ class TranslateStatusService < BaseService end def unwrap_emoji_shortcodes(html) - fragment = Nokogiri::HTML.fragment(html) + fragment = Nokogiri::HTML5.fragment(html) fragment.css('span[translate="no"]').each do |element| element.remove_attribute('translate') element.replace(element.children) if element.attributes.empty? diff --git a/lib/sanitize_ext/sanitize_config.rb b/lib/sanitize_ext/sanitize_config.rb index ad310b393a..f0a7b65783 100644 --- a/lib/sanitize_ext/sanitize_config.rb +++ b/lib/sanitize_ext/sanitize_config.rb @@ -52,7 +52,7 @@ class Sanitize :relative end - current_node.replace(Nokogiri::XML::Text.new(current_node.text, current_node.document)) unless LINK_PROTOCOLS.include?(scheme) + current_node.replace(current_node.document.create_text_node(current_node.text)) unless LINK_PROTOCOLS.include?(scheme) end UNSUPPORTED_ELEMENTS_TRANSFORMER = lambda do |env| diff --git a/lib/tasks/emojis.rake b/lib/tasks/emojis.rake index e9fea2deea..fb18f21cf5 100644 --- a/lib/tasks/emojis.rake +++ b/lib/tasks/emojis.rake @@ -13,7 +13,7 @@ def gen_border(codepoint, color) view_box[3] += 4 svg['viewBox'] = view_box.join(' ') end - g = Nokogiri::XML::Node.new 'g', doc + g = doc.create_element('g') doc.css('svg > *').each do |elem| border_elem = elem.dup From afa2e257e481deb913ea04104966a613fc50a7f2 Mon Sep 17 00:00:00 2001 From: Mike Dalessio Date: Sun, 8 Sep 2024 14:50:22 -0400 Subject: [PATCH 145/153] Change verify link service to use CSS selectors instead of a complex XPath query (#31815) --- app/services/verify_link_service.rb | 2 +- spec/services/verify_link_service_spec.rb | 30 +++++++++++++++++------ 2 files changed, 24 insertions(+), 8 deletions(-) diff --git a/app/services/verify_link_service.rb b/app/services/verify_link_service.rb index b317fc31a8..c4f4191e1f 100644 --- a/app/services/verify_link_service.rb +++ b/app/services/verify_link_service.rb @@ -26,7 +26,7 @@ class VerifyLinkService < BaseService def link_back_present? return false if @body.blank? - links = Nokogiri::HTML5(@body).xpath('//a[contains(concat(" ", normalize-space(@rel), " "), " me ")]|//link[contains(concat(" ", normalize-space(@rel), " "), " me ")]') + links = Nokogiri::HTML5(@body).css("a[rel~='me'],link[rel~='me']") if links.any? { |link| link['href']&.downcase == @link_back.downcase } true diff --git a/spec/services/verify_link_service_spec.rb b/spec/services/verify_link_service_spec.rb index 0ce8c9a904..a4fd19751b 100644 --- a/spec/services/verify_link_service_spec.rb +++ b/spec/services/verify_link_service_spec.rb @@ -11,13 +11,14 @@ RSpec.describe VerifyLinkService do before do stub_request(:head, 'https://redirect.me/abc').to_return(status: 301, headers: { 'Location' => ActivityPub::TagManager.instance.url_for(account) }) + stub_request(:head, 'http://unrelated-site.com').to_return(status: 301) stub_request(:get, 'http://example.com').to_return(status: 200, body: html) subject.call(field) end context 'when a link contains an back' do let(:html) do - <<-HTML + <<~HTML Follow me on Mastodon @@ -30,9 +31,9 @@ RSpec.describe VerifyLinkService do end end - context 'when a link contains an back' do + context 'when a link contains an back' do let(:html) do - <<-HTML + <<~HTML Follow me on Mastodon @@ -47,7 +48,7 @@ RSpec.describe VerifyLinkService do context 'when a link contains a back' do let(:html) do - <<-HTML + <<~HTML @@ -62,7 +63,7 @@ RSpec.describe VerifyLinkService do context 'when a link goes through a redirect back' do let(:html) do - <<-HTML + <<~HTML @@ -113,7 +114,7 @@ RSpec.describe VerifyLinkService do context 'when link has no `href` attribute' do let(:html) do - <<-HTML + <<~HTML @@ -128,6 +129,21 @@ RSpec.describe VerifyLinkService do expect(field.verified?).to be false end end + + context 'when a link contains a link to an unexpected URL' do + let(:html) do + <<~HTML + + + Follow me on Unrelated Site + + HTML + end + + it 'does not mark the field as verified' do + expect(field.verified?).to be false + end + end end context 'when given a remote account' do @@ -141,7 +157,7 @@ RSpec.describe VerifyLinkService do context 'when a link contains an back' do let(:html) do - <<-HTML + <<~HTML Follow me on Mastodon From 82161d8ae54b94be701cba600536d87957361cea Mon Sep 17 00:00:00 2001 From: Mike Dalessio Date: Sun, 8 Sep 2024 14:56:18 -0400 Subject: [PATCH 146/153] Change Account::Field parsing to use HTML5::DocumentFragment (#31813) --- app/models/account/field.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/models/account/field.rb b/app/models/account/field.rb index 2bada6954b..bcd89015de 100644 --- a/app/models/account/field.rb +++ b/app/models/account/field.rb @@ -73,10 +73,10 @@ class Account::Field < ActiveModelSerializers::Model end def extract_url_from_html - doc = Nokogiri::HTML(value).at_xpath('//body') + doc = Nokogiri::HTML5.fragment(value) return if doc.nil? - return if doc.children.size > 1 + return if doc.children.size != 1 element = doc.children.first From c6a0768fe564d342e6ac6b70aff9d7c23b8a9ffc Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Mon, 9 Sep 2024 04:01:26 -0400 Subject: [PATCH 147/153] Use shared system spec helper methods (#31784) --- spec/support/system_helpers.rb | 4 ++++ spec/system/admin/announcements_spec.rb | 10 +--------- spec/system/admin/domain_blocks_spec.rb | 2 +- spec/system/filters_spec.rb | 2 +- spec/system/invites_spec.rb | 4 ---- 5 files changed, 7 insertions(+), 15 deletions(-) diff --git a/spec/support/system_helpers.rb b/spec/support/system_helpers.rb index 05c9d3b125..4cc1928701 100644 --- a/spec/support/system_helpers.rb +++ b/spec/support/system_helpers.rb @@ -16,4 +16,8 @@ module SystemHelpers def form_label(key) I18n.t key, scope: 'simple_form.labels' end + + def css_id(record) + "##{dom_id(record)}" + end end diff --git a/spec/system/admin/announcements_spec.rb b/spec/system/admin/announcements_spec.rb index 1da5699656..87b7332639 100644 --- a/spec/system/admin/announcements_spec.rb +++ b/spec/system/admin/announcements_spec.rb @@ -45,7 +45,7 @@ RSpec.describe 'Admin::Announcements' do fill_in text_label, with: 'Announcement text' - save_changes + click_on submit_button expect(page) .to have_content(I18n.t('admin.announcements.updated_msg')) @@ -94,10 +94,6 @@ RSpec.describe 'Admin::Announcements' do private - def css_id(record) - "##{dom_id(record)}" # TODO: Extract to system spec helper? - end - def publish_announcement(announcement) within css_id(announcement) do click_on I18n.t('admin.announcements.publish') @@ -116,10 +112,6 @@ RSpec.describe 'Admin::Announcements' do end end - def save_changes - click_on I18n.t('generic.save_changes') - end - def submit_form click_on I18n.t('admin.announcements.new.create') end diff --git a/spec/system/admin/domain_blocks_spec.rb b/spec/system/admin/domain_blocks_spec.rb index 9a39e29062..f00d65dfe0 100644 --- a/spec/system/admin/domain_blocks_spec.rb +++ b/spec/system/admin/domain_blocks_spec.rb @@ -91,7 +91,7 @@ RSpec.describe 'blocking domains through the moderation interface' do visit edit_admin_domain_block_path(domain_block) select I18n.t('admin.domain_blocks.new.severity.suspend'), from: 'domain_block_severity' - click_on I18n.t('generic.save_changes') + click_on submit_button # It doesn't immediately block but presents a confirmation screen expect(page).to have_title(I18n.t('admin.domain_blocks.confirm_suspension.title', domain: 'example.com')) diff --git a/spec/system/filters_spec.rb b/spec/system/filters_spec.rb index 052b5e1730..64de384c00 100644 --- a/spec/system/filters_spec.rb +++ b/spec/system/filters_spec.rb @@ -29,7 +29,7 @@ RSpec.describe 'Filters' do click_on filter_title fill_in filter_title_field, with: new_title - click_on I18n.t('generic.save_changes') + click_on submit_button expect(page).to have_content(new_title) end diff --git a/spec/system/invites_spec.rb b/spec/system/invites_spec.rb index 648bbea825..c57de871cc 100644 --- a/spec/system/invites_spec.rb +++ b/spec/system/invites_spec.rb @@ -56,10 +56,6 @@ RSpec.describe 'Invites' do private - def css_id(record) - "##{dom_id(record)}" # TODO: Extract to system spec helper? - end - def copyable_field within '.input-copy' do find(:field, type: :text, readonly: true) From 1f13b875671e203002207d9d794e26a17f41890e Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Mon, 9 Sep 2024 10:31:13 +0200 Subject: [PATCH 148/153] Update dependency pg to v1.5.8 (#31795) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile.lock b/Gemfile.lock index a988ad3f21..48fd05b1ac 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -590,7 +590,7 @@ GEM parslet (2.0.0) pastel (0.8.0) tty-color (~> 0.5) - pg (1.5.7) + pg (1.5.8) pghero (3.6.0) activerecord (>= 6.1) premailer (1.27.0) From e6969cf4e434abb7a03a1f1300e97f031b23a042 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Mon, 9 Sep 2024 04:33:51 -0400 Subject: [PATCH 149/153] Add method for media-referencing status in `AccountStatusCleanupPolicy` (#31798) --- app/models/account_statuses_cleanup_policy.rb | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/app/models/account_statuses_cleanup_policy.rb b/app/models/account_statuses_cleanup_policy.rb index e2c035284b..6e998e2dca 100644 --- a/app/models/account_statuses_cleanup_policy.rb +++ b/app/models/account_statuses_cleanup_policy.rb @@ -157,7 +157,7 @@ class AccountStatusesCleanupPolicy < ApplicationRecord end def without_media_scope - Status.where('NOT EXISTS (SELECT 1 FROM media_attachments media WHERE media.status_id = statuses.id)') + Status.where.not(status_media_reference_exists) end def without_poll_scope @@ -175,6 +175,14 @@ class AccountStatusesCleanupPolicy < ApplicationRecord Status.where(account_id: account_id) end + def status_media_reference_exists + MediaAttachment + .where(MediaAttachment.arel_table[:status_id].eq Status.arel_table[:id]) + .select(1) + .arel + .exists + end + def self_status_reference_exists(model) model .where(model.arel_table[:account_id].eq Status.arel_table[:account_id]) From 9d9901cc5bf9472ff52df87ed2d1cd096182d571 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Mon, 9 Sep 2024 10:43:12 +0200 Subject: [PATCH 150/153] Update peter-evans/create-pull-request action to v7 (#31818) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- .github/workflows/crowdin-download.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/crowdin-download.yml b/.github/workflows/crowdin-download.yml index 0faa7e4939..f1817b3e9a 100644 --- a/.github/workflows/crowdin-download.yml +++ b/.github/workflows/crowdin-download.yml @@ -52,7 +52,7 @@ jobs: # Create or update the pull request - name: Create Pull Request - uses: peter-evans/create-pull-request@v6.0.5 + uses: peter-evans/create-pull-request@v7.0.1 with: commit-message: 'New Crowdin translations' title: 'New Crowdin Translations (automated)' From a0ea2fa3b01c61d4d390b5e4b6cddc8006b204ec Mon Sep 17 00:00:00 2001 From: Mike Dalessio Date: Mon, 9 Sep 2024 06:59:42 -0400 Subject: [PATCH 151/153] Change fetch link card service to parse as HTML5 (#31814) --- app/lib/link_details_extractor.rb | 36 +++++++++---------- app/services/fetch_link_card_service.rb | 4 +-- spec/services/fetch_link_card_service_spec.rb | 4 +-- 3 files changed, 22 insertions(+), 22 deletions(-) diff --git a/app/lib/link_details_extractor.rb b/app/lib/link_details_extractor.rb index bd78aef7a9..dff57f74f3 100644 --- a/app/lib/link_details_extractor.rb +++ b/app/lib/link_details_extractor.rb @@ -157,11 +157,11 @@ class LinkDetailsExtractor end def title - html_entities_decode(structured_data&.headline || opengraph_tag('og:title') || document.xpath('//title').map(&:content).first)&.strip + html_entities.decode(structured_data&.headline || opengraph_tag('og:title') || document.xpath('//title').map(&:content).first)&.strip end def description - html_entities_decode(structured_data&.description || opengraph_tag('og:description') || meta_tag('description')) + html_entities.decode(structured_data&.description || opengraph_tag('og:description') || meta_tag('description')) end def published_at @@ -181,7 +181,7 @@ class LinkDetailsExtractor end def provider_name - html_entities_decode(structured_data&.publisher_name || opengraph_tag('og:site_name')) + html_entities.decode(structured_data&.publisher_name || opengraph_tag('og:site_name')) end def provider_url @@ -189,7 +189,7 @@ class LinkDetailsExtractor end def author_name - html_entities_decode(structured_data&.author_name || opengraph_tag('og:author') || opengraph_tag('og:author:username')) + html_entities.decode(structured_data&.author_name || opengraph_tag('og:author') || opengraph_tag('og:author:username')) end def author_url @@ -258,7 +258,7 @@ class LinkDetailsExtractor next if json_ld.blank? - structured_data = StructuredData.new(html_entities_decode(json_ld)) + structured_data = StructuredData.new(html_entities.decode(json_ld)) next unless structured_data.valid? @@ -274,11 +274,20 @@ class LinkDetailsExtractor end def detect_encoding_and_parse_document - [detect_encoding, nil, header_encoding].uniq.each do |encoding| - document = Nokogiri::HTML(@html, nil, encoding) - return document if document.to_s.valid_encoding? + html = nil + encoding = nil + + [detect_encoding, header_encoding].compact.each do |enc| + html = @html.dup.force_encoding(enc) + if html.valid_encoding? + encoding = enc + break + end end - Nokogiri::HTML(@html, nil, 'UTF-8') + + html = @html unless encoding + + Nokogiri::HTML5(html, nil, encoding) end def detect_encoding @@ -299,15 +308,6 @@ class LinkDetailsExtractor end end - def html_entities_decode(string) - return if string.nil? - - unicode_string = string.to_s.encode('UTF-8') - raise EncodingError, 'cannot convert string to valid UTF-8' unless unicode_string.valid_encoding? - - html_entities.decode(unicode_string) - end - def html_entities @html_entities ||= HTMLEntities.new(:expanded) end diff --git a/app/services/fetch_link_card_service.rb b/app/services/fetch_link_card_service.rb index 49b8205574..36d5c490a6 100644 --- a/app/services/fetch_link_card_service.rb +++ b/app/services/fetch_link_card_service.rb @@ -29,7 +29,7 @@ class FetchLinkCardService < BaseService end attach_card if @card&.persisted? - rescue HTTP::Error, OpenSSL::SSL::SSLError, Addressable::URI::InvalidURIError, Mastodon::HostValidationError, Mastodon::LengthValidationError, EncodingError, ActiveRecord::RecordInvalid => e + rescue HTTP::Error, OpenSSL::SSL::SSLError, Addressable::URI::InvalidURIError, Mastodon::HostValidationError, Mastodon::LengthValidationError, Encoding::UndefinedConversionError, ActiveRecord::RecordInvalid => e Rails.logger.debug { "Error fetching link #{@original_url}: #{e}" } nil end @@ -80,7 +80,7 @@ class FetchLinkCardService < BaseService urls = if @status.local? @status.text.scan(URL_PATTERN).map { |array| Addressable::URI.parse(array[1]).normalize } else - document = Nokogiri::HTML(@status.text) + document = Nokogiri::HTML5(@status.text) links = document.css('a') links.filter_map { |a| Addressable::URI.parse(a['href']) unless skip_link?(a) }.filter_map(&:normalize) diff --git a/spec/services/fetch_link_card_service_spec.rb b/spec/services/fetch_link_card_service_spec.rb index 2f64f40558..1d61e33c0b 100644 --- a/spec/services/fetch_link_card_service_spec.rb +++ b/spec/services/fetch_link_card_service_spec.rb @@ -192,8 +192,8 @@ RSpec.describe FetchLinkCardService do context 'when encoding problems appear in title tag' do let(:status) { Fabricate(:status, text: 'Check out http://example.com/latin1_posing_as_utf8_broken') } - it 'does not create a preview card' do - expect(status.preview_card).to be_nil + it 'creates a preview card anyway that replaces invalid bytes with U+FFFD (replacement char)' do + expect(status.preview_card.title).to eq("Tofu � l'orange") end end end From 1d03570080252ee70859f07638ab724fc4fadfc2 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Mon, 9 Sep 2024 13:16:09 +0200 Subject: [PATCH 152/153] Update dependency postcss-preset-env to v10.0.3 (#31821) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- yarn.lock | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/yarn.lock b/yarn.lock index 1b3a7f1e40..332f6d012f 100644 --- a/yarn.lock +++ b/yarn.lock @@ -6701,10 +6701,10 @@ __metadata: languageName: node linkType: hard -"cssdb@npm:^8.1.0": - version: 8.1.0 - resolution: "cssdb@npm:8.1.0" - checksum: 10c0/1fa1f1566c7e9964f5c71e443583eaba16a90933a3ef6803815c4281d084b75da948c415bade33d7085894fe0929c082fcb3135bf4400048cfff40d227ebd5dd +"cssdb@npm:^8.1.1": + version: 8.1.1 + resolution: "cssdb@npm:8.1.1" + checksum: 10c0/d60facfad3bca70e21100fc35b9205cb9d3d0ac642f44f0a687e54bf787f21c43d28ce2d17fcd405f67950fb4709516108fe1f3cb15df570eff1007b5fbbc787 languageName: node linkType: hard @@ -13802,12 +13802,12 @@ __metadata: languageName: node linkType: hard -"postcss-opacity-percentage@npm:^2.0.0": - version: 2.0.0 - resolution: "postcss-opacity-percentage@npm:2.0.0" +"postcss-opacity-percentage@npm:^3.0.0": + version: 3.0.0 + resolution: "postcss-opacity-percentage@npm:3.0.0" peerDependencies: - postcss: ^8.2 - checksum: 10c0/f031f3281060c4c0ede8f9a5832f65a3d8c2a1896ff324c41de42016e092635f0e0abee07545b01db93dc430a9741674a1d09c377c6c01cd8c2f4be65f889161 + postcss: ^8.4 + checksum: 10c0/15c7d66036fa966d265c8737196646b3f93deb83d4eea0b17ed5033460599afc31d3a989345e4d7c472963b2a2bb75c83d06979d5d30d6a60fcc7f74cb6d8d40 languageName: node linkType: hard @@ -13855,8 +13855,8 @@ __metadata: linkType: hard "postcss-preset-env@npm:^10.0.0": - version: 10.0.2 - resolution: "postcss-preset-env@npm:10.0.2" + version: 10.0.3 + resolution: "postcss-preset-env@npm:10.0.3" dependencies: "@csstools/postcss-cascade-layers": "npm:^5.0.0" "@csstools/postcss-color-function": "npm:^4.0.2" @@ -13893,7 +13893,7 @@ __metadata: css-blank-pseudo: "npm:^7.0.0" css-has-pseudo: "npm:^7.0.0" css-prefers-color-scheme: "npm:^10.0.0" - cssdb: "npm:^8.1.0" + cssdb: "npm:^8.1.1" postcss-attribute-case-insensitive: "npm:^7.0.0" postcss-clamp: "npm:^4.1.0" postcss-color-functional-notation: "npm:^7.0.2" @@ -13912,7 +13912,7 @@ __metadata: postcss-lab-function: "npm:^7.0.2" postcss-logical: "npm:^8.0.0" postcss-nesting: "npm:^13.0.0" - postcss-opacity-percentage: "npm:^2.0.0" + postcss-opacity-percentage: "npm:^3.0.0" postcss-overflow-shorthand: "npm:^6.0.0" postcss-page-break: "npm:^3.0.4" postcss-place: "npm:^10.0.0" @@ -13921,7 +13921,7 @@ __metadata: postcss-selector-not: "npm:^8.0.0" peerDependencies: postcss: ^8.4 - checksum: 10c0/51eb19994dfdbb041e87082833bedf8976053c182ae8dafab6b3ee1bf2cfd309ab9c186644ed032518011e44fbcc9f0552083bc431535779a80a919bbe78d10d + checksum: 10c0/da42caa2aab4d825fddfde00ebe2416d338c7b9a6f79a68840297888a8384f85991991c3fa10cf2d359fb230c885375f5cebd7bd63972725cd2a596d218f8b6a languageName: node linkType: hard From 2caa3f365ded73be17b623177967110e66f14061 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Mon, 9 Sep 2024 14:38:43 +0200 Subject: [PATCH 153/153] New Crowdin Translations (automated) (#31800) Co-authored-by: GitHub Actions --- app/javascript/mastodon/locales/ar.json | 6 +- app/javascript/mastodon/locales/et.json | 42 +++++++ app/javascript/mastodon/locales/fa.json | 99 ++++++++++++++++ app/javascript/mastodon/locales/ia.json | 10 ++ app/javascript/mastodon/locales/la.json | 18 +++ app/javascript/mastodon/locales/ms.json | 2 + app/javascript/mastodon/locales/ru.json | 1 + app/javascript/mastodon/locales/zh-CN.json | 20 ++-- app/javascript/mastodon/locales/zh-TW.json | 2 +- config/locales/activerecord.zh-CN.yml | 2 +- config/locales/ar.yml | 2 +- config/locales/ca.yml | 4 + config/locales/cy.yml | 5 + config/locales/da.yml | 4 + config/locales/de.yml | 6 +- config/locales/devise.zh-CN.yml | 10 +- config/locales/doorkeeper.fa.yml | 3 + config/locales/es-AR.yml | 4 + config/locales/es-MX.yml | 1 + config/locales/es.yml | 1 + config/locales/et.yml | 47 +++++++- config/locales/fi.yml | 12 +- config/locales/fo.yml | 4 + config/locales/fr-CA.yml | 7 ++ config/locales/fr.yml | 7 ++ config/locales/ga.yml | 4 + config/locales/gd.yml | 4 + config/locales/gl.yml | 4 + config/locales/hu.yml | 4 + config/locales/ia.yml | 4 + config/locales/is.yml | 4 + config/locales/it.yml | 4 + config/locales/ja.yml | 1 + config/locales/ko.yml | 4 + config/locales/lad.yml | 1 + config/locales/lt.yml | 3 +- config/locales/nl.yml | 4 + config/locales/pl.yml | 4 + config/locales/simple_form.an.yml | 1 - config/locales/simple_form.ar.yml | 1 - config/locales/simple_form.be.yml | 1 - config/locales/simple_form.bg.yml | 1 - config/locales/simple_form.ca.yml | 2 +- config/locales/simple_form.cs.yml | 1 - config/locales/simple_form.cy.yml | 2 +- config/locales/simple_form.da.yml | 2 +- config/locales/simple_form.de.yml | 2 +- config/locales/simple_form.el.yml | 1 - config/locales/simple_form.en-GB.yml | 1 - config/locales/simple_form.eo.yml | 1 - config/locales/simple_form.es-AR.yml | 2 +- config/locales/simple_form.es-MX.yml | 1 - config/locales/simple_form.es.yml | 1 - config/locales/simple_form.et.yml | 2 +- config/locales/simple_form.eu.yml | 1 - config/locales/simple_form.fa.yml | 4 + config/locales/simple_form.fi.yml | 2 +- config/locales/simple_form.fo.yml | 2 +- config/locales/simple_form.fr-CA.yml | 2 +- config/locales/simple_form.fr.yml | 2 +- config/locales/simple_form.fy.yml | 1 - config/locales/simple_form.ga.yml | 2 +- config/locales/simple_form.gd.yml | 2 +- config/locales/simple_form.gl.yml | 2 +- config/locales/simple_form.he.yml | 1 - config/locales/simple_form.hu.yml | 2 +- config/locales/simple_form.ia.yml | 1 - config/locales/simple_form.id.yml | 1 - config/locales/simple_form.ie.yml | 1 - config/locales/simple_form.io.yml | 1 - config/locales/simple_form.is.yml | 2 +- config/locales/simple_form.it.yml | 2 +- config/locales/simple_form.ja.yml | 1 - config/locales/simple_form.ko.yml | 2 +- config/locales/simple_form.ku.yml | 1 - config/locales/simple_form.lad.yml | 2 +- config/locales/simple_form.lt.yml | 1 - config/locales/simple_form.lv.yml | 1 - config/locales/simple_form.ms.yml | 1 - config/locales/simple_form.my.yml | 1 - config/locales/simple_form.nl.yml | 2 +- config/locales/simple_form.nn.yml | 1 - config/locales/simple_form.no.yml | 1 - config/locales/simple_form.pl.yml | 1 - config/locales/simple_form.pt-BR.yml | 1 - config/locales/simple_form.pt-PT.yml | 1 - config/locales/simple_form.ru.yml | 1 - config/locales/simple_form.sco.yml | 1 - config/locales/simple_form.sl.yml | 1 - config/locales/simple_form.sq.yml | 2 +- config/locales/simple_form.sr-Latn.yml | 1 - config/locales/simple_form.sr.yml | 1 - config/locales/simple_form.sv.yml | 2 +- config/locales/simple_form.tr.yml | 1 - config/locales/simple_form.uk.yml | 2 +- config/locales/simple_form.vi.yml | 2 +- config/locales/simple_form.zh-CN.yml | 16 +-- config/locales/simple_form.zh-HK.yml | 1 - config/locales/simple_form.zh-TW.yml | 4 +- config/locales/sq.yml | 4 + config/locales/sv.yml | 1 + config/locales/th.yml | 5 + config/locales/uk.yml | 2 + config/locales/vi.yml | 4 + config/locales/zh-CN.yml | 124 +++++++++++---------- config/locales/zh-TW.yml | 4 + 106 files changed, 456 insertions(+), 157 deletions(-) diff --git a/app/javascript/mastodon/locales/ar.json b/app/javascript/mastodon/locales/ar.json index d83a42a6c7..722f2bc98b 100644 --- a/app/javascript/mastodon/locales/ar.json +++ b/app/javascript/mastodon/locales/ar.json @@ -229,8 +229,8 @@ "domain_pill.their_username": "مُعرّفُهم الفريد على الخادم. من الممكن العثور على مستخدمين بنفس اسم المستخدم على خوادم مختلفة.", "domain_pill.username": "اسم المستخدم", "domain_pill.whats_in_a_handle": "ما المقصود بالمُعرِّف؟", - "domain_pill.who_they_are": "بما أن المعرفات تقول من هو الشخص ومكان وجوده، يمكنك التفاعل مع الناس عبر الويب الاجتماعي لل .", - "domain_pill.who_you_are": "بما أن معرفك يقول من أنت ومكان وجوده، يمكن للناس التفاعل معك عبر الويب الاجتماعي لل .", + "domain_pill.who_they_are": "بما أن المُعرّفات تحدد هوية الشخص ومكان وجوده، فبإمكانك التفاعل مع الأشخاص عبر الويب الاجتماعي لـ .", + "domain_pill.who_you_are": "بما أن مُعرّفك يحدد هويتك ومكان وجوده، فبإمكانك الآخرين التفاعل معك عبر الويب الاجتماعي لـ .", "domain_pill.your_handle": "عنوانك الكامل:", "domain_pill.your_server": "موطِنك الرقمي، حيث توجد فيه كافة منشوراتك. ألا يعجبك المكان؟ يمكنك الانتقال بين الخوادم في أي وقت واصطحاب متابعيك أيضاً.", "domain_pill.your_username": "معرفك الفريد على هذا الخادم. من الممكن العثور على مستخدمين بنفس إسم المستخدم على خوادم مختلفة.", @@ -352,6 +352,7 @@ "hashtags.and_other": "…و {count, plural, zero {} one {# واحد آخر} two {# اثنان آخران} few {# آخرون} many {# آخَرًا}other {# آخرون}}", "hints.profiles.see_more_followers": "عرض المزيد من المتابعين على {domain}", "hints.profiles.see_more_posts": "عرض المزيد من المنشورات من {domain}", + "hints.threads.replies_may_be_missing": "قد تكون الردود الواردة من الخوادم الأخرى غائبة.", "hints.threads.see_more": "اطلع على المزيد من الردود على {domain}", "home.column_settings.show_reblogs": "اعرض المعاد نشرها", "home.column_settings.show_replies": "اعرض الردود", @@ -517,6 +518,7 @@ "notification_requests.edit_selection": "تعديل", "notification_requests.exit_selection": "تمّ", "notification_requests.explainer_for_limited_account": "تم تصفية الإشعارات من هذا الحساب لأن الحساب تم تقييده من قبل مشرف.", + "notification_requests.minimize_banner": "تصغير شريط الإشعارات المُصفاة", "notification_requests.notifications_from": "إشعارات من {name}", "notification_requests.title": "الإشعارات المصفاة", "notification_requests.view": "عرض الإشعارات", diff --git a/app/javascript/mastodon/locales/et.json b/app/javascript/mastodon/locales/et.json index 4838f70155..d0fc80e60c 100644 --- a/app/javascript/mastodon/locales/et.json +++ b/app/javascript/mastodon/locales/et.json @@ -353,6 +353,14 @@ "hashtag.follow": "Jälgi silti", "hashtag.unfollow": "Lõpeta sildi jälgimine", "hashtags.and_other": "…ja {count, plural, one {}other {# veel}}", + "hints.profiles.followers_may_be_missing": "Selle profiili jälgijaid võib olla puudu.", + "hints.profiles.follows_may_be_missing": "Selle profiili poolt jälgitavaid võib olla puudu.", + "hints.profiles.posts_may_be_missing": "Mõned selle profiili postitused võivad olla puudu.", + "hints.profiles.see_more_followers": "Vaata rohkem jälgijaid kohas {domain}", + "hints.profiles.see_more_follows": "Vaata rohkem jälgitavaid kohas {domain}", + "hints.profiles.see_more_posts": "Vaata rohkem postitusi kohas {domain}", + "hints.threads.replies_may_be_missing": "Vastuseid teistest serveritest võib olla puudu.", + "hints.threads.see_more": "Vaata rohkem vastuseid kohas {domain}", "home.column_settings.show_reblogs": "Näita jagamisi", "home.column_settings.show_replies": "Näita vastuseid", "home.hide_announcements": "Peida teadaanded", @@ -360,6 +368,17 @@ "home.pending_critical_update.link": "Vaata uuendusi", "home.pending_critical_update.title": "Saadaval kriitiline turvauuendus!", "home.show_announcements": "Kuva teadaandeid", + "ignore_notifications_modal.disclaimer": "Mastodon ei saa teavitada kasutajaid, et ignoreerisid nende teavitusi. Teavituste ignoreerimine ei peata sõnumite endi saatmist.", + "ignore_notifications_modal.filter_instead": "Selle asemel filtreeri", + "ignore_notifications_modal.filter_to_act_users": "Saad endiselt kasutajaid vastu võtta, tagasi lükata või neist teatada", + "ignore_notifications_modal.filter_to_avoid_confusion": "Filtreerimine aitab vältida võimalikke segaminiajamisi", + "ignore_notifications_modal.filter_to_review_separately": "Saad filtreeritud teateid eraldi vaadata", + "ignore_notifications_modal.ignore": "Ignoreeri teavitusi", + "ignore_notifications_modal.limited_accounts_title": "Ignoreeri modereeritud kontode teavitusi?", + "ignore_notifications_modal.new_accounts_title": "Ignoreeri uute kontode teavitusi?", + "ignore_notifications_modal.not_followers_title": "Ignoreeri inimeste teavitusi, kes sind ei jälgi?", + "ignore_notifications_modal.not_following_title": "Ignoreeri inimeste teavitusi, keda sa ei jälgi?", + "ignore_notifications_modal.private_mentions_title": "Ignoreeri soovimatute eraviisiliste mainimiste teateid?", "interaction_modal.description.favourite": "Mastodoni kontoga saad postituse lemmikuks märkida, et autor teaks, et sa hindad seda, ja jätta see hiljemaks alles.", "interaction_modal.description.follow": "Mastodoni kontoga saad jälgida kasutajat {name}, et tema postitusi oma koduvoos näha.", "interaction_modal.description.reblog": "Mastodoni kontoga saad seda postitust levitada, jagades seda oma jälgijatele.", @@ -483,9 +502,13 @@ "notification.admin.report_statuses": "{name} raporteeris {target} kategooriast {category}", "notification.admin.report_statuses_other": "{name} raporteeris kohast {target}", "notification.admin.sign_up": "{name} registreerus", + "notification.admin.sign_up.name_and_others": "{name} ja {count, plural, one {# veel} other {# teist}} liitus", "notification.favourite": "{name} märkis su postituse lemmikuks", + "notification.favourite.name_and_others_with_link": "{name} ja {count, plural, one {# veel} other {# teist}} märkis su postituse lemmikuks", "notification.follow": "{name} alustas su jälgimist", + "notification.follow.name_and_others": "{name} ja {count, plural, one {# veel} other {# teist}} hakkas sind jälgima", "notification.follow_request": "{name} soovib sind jälgida", + "notification.follow_request.name_and_others": "{name} ja {count, plural, one {# veel} other {# teist}} taotles sinu jälgimist", "notification.label.mention": "Mainimine", "notification.label.private_mention": "Privaatne mainimine", "notification.label.private_reply": "Privaatne vastus", @@ -503,6 +526,7 @@ "notification.own_poll": "Su küsitlus on lõppenud", "notification.poll": "Hääletus, millel osalesid, on lõppenud", "notification.reblog": "{name} jagas edasi postitust", + "notification.reblog.name_and_others_with_link": "{name} ja {count, plural, one {# veel} other {# teist}} jagas su postitust", "notification.relationships_severance_event": "Kadunud ühendus kasutajaga {name}", "notification.relationships_severance_event.account_suspension": "{from} admin on kustutanud {target}, mis tähendab, et sa ei saa enam neilt uuendusi või suhelda nendega.", "notification.relationships_severance_event.domain_block": "{from} admin on blokeerinud {target}, sealhulgas {followersCount} sinu jälgijat ja {followingCount, plural, one {# konto} other {# kontot}}, mida jälgid.", @@ -511,13 +535,24 @@ "notification.status": "{name} just postitas", "notification.update": "{name} muutis postitust", "notification_requests.accept": "Nõus", + "notification_requests.accept_multiple": "{count, plural, one {Nõustu # taotlusega…} other {Nõustu # taotlusega…}}", + "notification_requests.confirm_accept_multiple.button": "{count, plural, one {Nõustu taotlusega} other {Nõustu taotlustega}}", + "notification_requests.confirm_accept_multiple.message": "Oled nõustumas {count, plural, one {ühe teavituse taotlusega} other {# teavituse taotlusega}}. Oled kindel, et soovid jätkata?", + "notification_requests.confirm_accept_multiple.title": "Nõustuda teavituste taotlustega?", + "notification_requests.confirm_dismiss_multiple.button": "{count, plural, one {Loobu taotlusest} other {Loobu taotlustest}}", + "notification_requests.confirm_dismiss_multiple.message": "Oled loobumas {count, plural, one {ühest teavituse taotlusest} other {# teavituse taotlusest}}. {count, plural, one {Sellele} other {Neile}} pole hiljem lihtne ligi pääseda. Oled kindel, et soovid jätkata?", + "notification_requests.confirm_dismiss_multiple.title": "Hüljata teavituse taotlused?", "notification_requests.dismiss": "Hülga", + "notification_requests.dismiss_multiple": "{count, plural, one {Loobuda # taotlusest…} other {Loobuda # taotlusest…}}", + "notification_requests.edit_selection": "Muuda", + "notification_requests.exit_selection": "Valmis", "notification_requests.explainer_for_limited_account": "Sellelt kontolt tulevad teavitused on filtreeritud, sest moderaator on seda kontot piiranud.", "notification_requests.explainer_for_limited_remote_account": "Sellelt kontolt tulevad teavitused on filtreeritud, sest moderaator on seda kontot või serverit piiranud.", "notification_requests.maximize": "Maksimeeri", "notification_requests.minimize_banner": "Minimeeri filtreeritud teavituste bänner", "notification_requests.notifications_from": "Teavitus kasutajalt {name}", "notification_requests.title": "Filtreeritud teavitused", + "notification_requests.view": "Vaata teavitusi", "notifications.clear": "Puhasta teated", "notifications.clear_confirmation": "Oled kindel, et soovid püsivalt kõik oma teated eemaldada?", "notifications.clear_title": "Tühjenda teavitus?", @@ -554,6 +589,12 @@ "notifications.permission_denied": "Töölauamärguanded pole saadaval, kuna eelnevalt keelduti lehitsejale teavituste luba andmast", "notifications.permission_denied_alert": "Töölaua märguandeid ei saa lubada, kuna brauseri luba on varem keeldutud", "notifications.permission_required": "Töölaua märguanded ei ole saadaval, kuna vajalik luba pole antud.", + "notifications.policy.accept": "Nõustun", + "notifications.policy.accept_hint": "Näita teavitustes", + "notifications.policy.drop": "Ignoreeri", + "notifications.policy.drop_hint": "Saada tühjusse, mitte kunagi seda enam näha", + "notifications.policy.filter": "Filter", + "notifications.policy.filter_hint": "Saadetud filtreeritud teavituste sisendkasti", "notifications.policy.filter_limited_accounts_hint": "Piiratud serveri moderaatorite poolt", "notifications.policy.filter_limited_accounts_title": "Modereeritud kontod", "notifications.policy.filter_new_accounts.hint": "Loodud viimase {days, plural, one {ühe päeva} other {# päeva}} jooksul", @@ -564,6 +605,7 @@ "notifications.policy.filter_not_following_title": "Inimesed, keda sa ei jälgi", "notifications.policy.filter_private_mentions_hint": "Filtreeritud, kui see pole vastus sinupoolt mainimisele või kui jälgid saatjat", "notifications.policy.filter_private_mentions_title": "Soovimatud privaatsed mainimised", + "notifications.policy.title": "Halda teavitusi kohast…", "notifications_permission_banner.enable": "Luba töölaua märguanded", "notifications_permission_banner.how_to_control": "Et saada teateid, ajal mil Mastodon pole avatud, luba töölauamärguanded. Saad täpselt määrata, mis tüüpi tegevused tekitavad märguandeid, kasutates peale teadaannete sisse lülitamist üleval olevat nuppu {icon}.", "notifications_permission_banner.title": "Ära jää millestki ilma", diff --git a/app/javascript/mastodon/locales/fa.json b/app/javascript/mastodon/locales/fa.json index 169c325ad7..50c376b3bd 100644 --- a/app/javascript/mastodon/locales/fa.json +++ b/app/javascript/mastodon/locales/fa.json @@ -11,6 +11,7 @@ "about.not_available": "این اطّلاعات روی این کارساز موجود نشده.", "about.powered_by": "رسانهٔ اجتماعی نامتمرکز قدرت گرفته از {mastodon}", "about.rules": "قوانین کارساز", + "account.account_note_header": "یادداشت شخصی", "account.add_or_remove_from_list": "افزودن یا برداشتن از سیاهه‌ها", "account.badges.bot": "خودکار", "account.badges.group": "گروه", @@ -33,7 +34,9 @@ "account.follow_back": "دنبال کردن متقابل", "account.followers": "پی‌گیرندگان", "account.followers.empty": "هنوز کسی پی‌گیر این کاربر نیست.", + "account.followers_counter": "{count, plural, one {{counter} پی‌گیرنده} other {{counter} پی‌گیرنده}}", "account.following": "پی می‌گیرید", + "account.following_counter": "{count, plural, one {{counter} پی‌گرفته} other {{counter} پی‌گرفته}}", "account.follows.empty": "این کاربر هنوز پی‌گیر کسی نیست.", "account.go_to_profile": "رفتن به نمایه", "account.hide_reblogs": "نهفتن تقویت‌های ‎@{name}", @@ -59,6 +62,7 @@ "account.requested_follow": "{name} درخواست پی‌گیریتان را داد", "account.share": "هم‌رسانی نمایهٔ ‎@{name}", "account.show_reblogs": "نمایش تقویت‌های ‎@{name}", + "account.statuses_counter": "{count, plural, one {{counter} فرسته} other {{counter} فرسته}}", "account.unblock": "رفع مسدودیت ‎@{name}", "account.unblock_domain": "رفع مسدودیت دامنهٔ {domain}", "account.unblock_short": "رفع مسدودیت", @@ -86,9 +90,14 @@ "audio.hide": "نهفتن صدا", "block_modal.show_less": "نمایش کم‌تر", "block_modal.show_more": "نمایش بیش‌تر", + "block_modal.they_cant_mention": "نمی‌توانند نامتان را برده یا پی‌تان بگیرند.", + "block_modal.they_cant_see_posts": "نمی‌توانند فرسته‌هایتان را دیده و فرسته‌هایشان را نمی‌بینید.", + "block_modal.they_will_know": "می‌توانند ببینند که مسدود شده‌اند.", "block_modal.title": "انسداد کاربر؟", "block_modal.you_wont_see_mentions": "فرسته‌هایی که از اون نام برده را نخواهید دید.", "boost_modal.combo": "دکمهٔ {combo} را بزنید تا دیگر این را نبینید", + "boost_modal.reblog": "تقویت فرسته؟", + "boost_modal.undo_reblog": "ناتقویت فرسته؟", "bundle_column_error.copy_stacktrace": "رونوشت از گزارش خطا", "bundle_column_error.error.body": "صفحهٔ درخواستی نتوانست پرداخت شود. ممکن است به خاطر اشکالی در کدمان یا مشکل سازگاری مرورگر باشد.", "bundle_column_error.error.title": "وای، نه!", @@ -184,6 +193,8 @@ "confirmations.unfollow.confirm": "پی‌نگرفتن", "confirmations.unfollow.message": "مطمئنید که می‌خواهید به پی‌گیری از {name} پایان دهید؟", "confirmations.unfollow.title": "ناپی‌گیری کاربر؟", + "content_warning.hide": "نهفتن فرسته", + "content_warning.show": "نمایش به هر روی", "conversation.delete": "حذف گفتگو", "conversation.mark_as_read": "علامت‌گذاری به عنوان خوانده شده", "conversation.open": "دیدن گفتگو", @@ -204,9 +215,24 @@ "dismissable_banner.explore_tags": "هم‌اکنون این برچسب‌ها بین افراد این کارساز و دیگر کارسازهای شبکهٔ نامتمرکز داغ شده‌اند.", "dismissable_banner.public_timeline": "این‌ها جدیدترین فرسته‌های عمومی از افرادی روی وب اجتماعیند که اعضای {domain} پی می‌گیرندشان.", "domain_block_modal.block": "انسداد کارساز", + "domain_block_modal.block_account_instead": "انسداد @{name} به جایش", + "domain_block_modal.they_can_interact_with_old_posts": "افزارد روی این کراساز می‌توانند با فرسته‌های قدیمیتان تعامل داشته باشند.", + "domain_block_modal.they_cant_follow": "هیچ‌کسی از این کارساز نمی‌تواند پیتان بگیرد.", + "domain_block_modal.they_wont_know": "نخواهند دانست که مسدود شده‌اند.", "domain_block_modal.title": "انسداد دامنه؟", + "domain_block_modal.you_will_lose_followers": "همهٔ پی‌گیرندگانتان از این کارساز برداشته خواهند شد.", + "domain_block_modal.you_wont_see_posts": "فرسته‌ها یا آگاهی‌ها از کاربران روی این کارساز را نخواهید دید.", "domain_pill.server": "کارساز", + "domain_pill.their_handle": "شناسه‌اش:", + "domain_pill.their_server": "خانهٔ رقمیش. جایی که همهٔ فرسته‌هایش می‌زیند.", + "domain_pill.their_username": "شناسهٔ یکتایش در کارسازش. ممکن است کاربرانی با نام کاربری مشابه روی کارسازهای مختلف باشند.", "domain_pill.username": "نام کاربری", + "domain_pill.whats_in_a_handle": "شناسه چیست؟", + "domain_pill.who_they_are": "از آن‌جا که شناسه‌ها کیستی و کجایی افراد را می‌گویند، می‌توانید با افرادی در سراسر وب اجتماعی تعامل داشته باشید.", + "domain_pill.who_you_are": "از آن‌جا که شناسه‌ها کیستی و کجاییتان را می‌گویند، افراد می‌توانند از سراسر وب اجتماعی با شما تعامل داشته باشند.", + "domain_pill.your_handle": "شناسه‌تان:", + "domain_pill.your_server": "خانهٔ رقمیتان. جایی که همهٔ فرسته‌هایتان می‌زیند. دوستش ندارید؟ در هر زمان کارسازتان را جابه‌جا کرده و پی‌گیرندگانتان را نیز بیاورید.", + "domain_pill.your_username": "شناسهٔ یکتایتان روی این کارساز. ممکن است کاربرانی با نام کاربری مشابه روی کارسازهای دیگر باشند.", "embed.instructions": "جاسازی این فرسته روی پایگاهتان با رونوشت کردن کد زیر.", "embed.preview": "این گونه دیده خواهد شد:", "emoji_button.activity": "فعالیت", @@ -273,6 +299,9 @@ "filter_modal.select_filter.subtitle": "استفاده از یک دستهً موجود یا ایجاد دسته‌ای جدید", "filter_modal.select_filter.title": "پالایش این فرسته", "filter_modal.title.status": "پالایش یک فرسته", + "filter_warning.matches_filter": "مطابق با پالایهٔ «{title}»", + "filtered_notifications_banner.pending_requests": "از {count, plural, =0 {هیچ‌کسی} one {فردی} other {# نفر}} که ممکن است بشناسید", + "filtered_notifications_banner.title": "آگاهی‌های پالوده", "firehose.all": "همه", "firehose.local": "این کارساز", "firehose.remote": "دیگر کارسازها", @@ -281,6 +310,8 @@ "follow_requests.unlocked_explanation": "با این که حسابتان قفل نیست، کارکنان {domain} فکر کردند که ممکن است بخواهید درخواست‌ها از این حساب‌ها را به صورت دستی بازبینی کنید.", "follow_suggestions.curated_suggestion": "گزینش سردبیر", "follow_suggestions.dismiss": "دیگر نشان داده نشود", + "follow_suggestions.featured_longer": "دست‌چین شده به دست گروه {domain}", + "follow_suggestions.friends_of_friends_longer": "محبوب بین کسانی که پی‌گرفته‌اید", "follow_suggestions.hints.featured": "این نمایه به دست گروه {domain} دستچین شده.", "follow_suggestions.hints.friends_of_friends": "این نمایه بین کسانی که پی می‌گیرید محبوب است.", "follow_suggestions.hints.most_followed": "این نمایه روی {domain} بسیار پی‌گرفته شده.", @@ -288,6 +319,8 @@ "follow_suggestions.hints.similar_to_recently_followed": "این نمایه شبیه نمایه‌هاییست که اخیراً پی‌گرفته‌اید.", "follow_suggestions.personalized_suggestion": "پیشنهاد شخصی", "follow_suggestions.popular_suggestion": "پیشنهاد محبوب", + "follow_suggestions.popular_suggestion_longer": "محبوب روی {domain}", + "follow_suggestions.similar_to_recently_followed_longer": "شبیه نمایه‌هایی که اخیراً پی گرفته‌اید", "follow_suggestions.view_all": "دیدن همه", "follow_suggestions.who_to_follow": "افرادی برای پی‌گیری", "followed_tags": "برچسب‌های پی‌گرفته", @@ -316,6 +349,14 @@ "hashtag.follow": "پی‌گرفتن برچسب", "hashtag.unfollow": "پی‌نگرفتن برچسب", "hashtags.and_other": "…و {count, plural, other {# بیش‌تر}}", + "hints.profiles.followers_may_be_missing": "شاید پی‌گیرندگان این نمایه نباشند.", + "hints.profiles.follows_may_be_missing": "شاید پی‌گرفته‌های این نمایه نباشند.", + "hints.profiles.posts_may_be_missing": "شاید فرسته‌هایی از این نمایه نباشند.", + "hints.profiles.see_more_followers": "دیدن پی‌گیرندگان بیش‌تر روی {domain}", + "hints.profiles.see_more_follows": "دیدن پی‌گرفته‌های بیش‌تر روی {domain}", + "hints.profiles.see_more_posts": "دیدن فرسته‌های بیش‌تر روی {domain}", + "hints.threads.replies_may_be_missing": "شاید پاسخ‌ها از دیگر کارسازها نباشند.", + "hints.threads.see_more": "دیدن پاسخ‌های بیش‌تر روی {domain}", "home.column_settings.show_reblogs": "نمایش تقویت‌ها", "home.column_settings.show_replies": "نمایش پاسخ‌ها", "home.hide_announcements": "نهفتن اعلامیه‌ها", @@ -323,6 +364,11 @@ "home.pending_critical_update.link": "دیدن به‌روز رسانی‌ها", "home.pending_critical_update.title": "به‌روز رسانی امنیتی بحرانی موجود است!", "home.show_announcements": "نمایش اعلامیه‌ها", + "ignore_notifications_modal.ignore": "چشم‌پوشی از آگاهی‌ها", + "ignore_notifications_modal.limited_accounts_title": "چشم‌پوشی از آگاهی‌های حساب‌های نظارت شده؟", + "ignore_notifications_modal.new_accounts_title": "چشم‌پوشی از آگاهی‌های حساب‌های جدید؟", + "ignore_notifications_modal.not_followers_title": "چشم‌پوشی از آگاهی‌های افرادی که پیتان نمی‌گیرند؟", + "ignore_notifications_modal.not_following_title": "چشم‌پوشی از آگاهی‌های افرادی که پیشان نمی‌گیرید؟", "interaction_modal.description.favourite": "با حسابی روی ماستودون می‌توانید این فرسته را برگزیده تا نگارنده بداند قدردانش هستید و برای آینده ذخیره‌اش می‌کنید.", "interaction_modal.description.follow": "با حسابی روی ماستودون می‌توانید {name} را برای دریافت فرسته‌هایش در خوراک خانگیتان دنبال کنید.", "interaction_modal.description.reblog": "با حسابی روی ماستودون می‌توانید این فرسته را با پی‌گیران خودتان هم‌رسانی کنید.", @@ -383,6 +429,8 @@ "limited_account_hint.action": "به هر روی نمایه نشان داده شود", "limited_account_hint.title": "این نمایه از سوی ناظم‌های {domain} پنهان شده.", "link_preview.author": "از {name}", + "link_preview.more_from_author": "بیش‌تر از {name}", + "link_preview.shares": "{count, plural, one {{counter} فرسته} other {{counter} فرسته}}", "lists.account.add": "افزودن به سیاهه", "lists.account.remove": "برداشتن از سیاهه", "lists.delete": "حذف سیاهه", @@ -401,9 +449,16 @@ "loading_indicator.label": "در حال بارگذاری…", "media_gallery.toggle_visible": "{number, plural, one {نهفتن تصویر} other {نهفتن تصاویر}}", "moved_to_account_banner.text": "حسابتان {disabledAccount} اکنون از کار افتاده؛ چرا که به {movedToAccount} منتقل شدید.", + "mute_modal.hide_from_notifications": "نهفتن از آگاهی‌ها", + "mute_modal.hide_options": "گزینه‌های نهفتن", + "mute_modal.indefinite": "تا وقتی ناخموشش کنم", "mute_modal.show_options": "نمایش گزینه‌ها", + "mute_modal.they_wont_know": "نخواهند دانست که خموش شده‌اند.", "mute_modal.title": "خموشی کاربر؟", + "mute_modal.you_wont_see_mentions": "فرسته‌هایی که به او اشاره کرده‌اند را نخواهید دید.", + "mute_modal.you_wont_see_posts": "هنوز می‌توانند فرسته‌هایتان را ببینند، ولی فرسته‌هایشان را نمی‌بینید.", "navigation_bar.about": "درباره", + "navigation_bar.administration": "مدیریت", "navigation_bar.advanced_interface": "بازکردن در رابط کاربری وب پیشرفته", "navigation_bar.blocks": "کاربران مسدود شده", "navigation_bar.bookmarks": "نشانک‌ها", @@ -420,6 +475,7 @@ "navigation_bar.follows_and_followers": "پی‌گرفتگان و پی‌گیرندگان", "navigation_bar.lists": "سیاهه‌ها", "navigation_bar.logout": "خروج", + "navigation_bar.moderation": "نظارت", "navigation_bar.mutes": "کاربران خموشانده", "navigation_bar.opened_in_classic_interface": "فرسته‌ها، حساب‌ها و دیگر صفحه‌های خاص به طور پیش‌گزیده در میانای وب کلاسیک گشوده می‌شوند.", "navigation_bar.personal": "شخصی", @@ -430,26 +486,54 @@ "navigation_bar.security": "امنیت", "not_signed_in_indicator.not_signed_in": "برای دسترسی به این منبع باید وارد شوید.", "notification.admin.report": "{name}، {target} را گزارش داد", + "notification.admin.report_statuses_other": "{name}، {target} را گزارش داد", "notification.admin.sign_up": "{name} ثبت نام کرد", "notification.favourite": "{name} فرسته‌تان را برگزید", "notification.follow": "‫{name}‬ پی‌گیرتان شد", "notification.follow_request": "{name} درخواست پی‌گیریتان را داد", + "notification.label.mention": "اشاره", + "notification.label.private_mention": "اشارهٔ خصوصی", + "notification.label.private_reply": "پاسخ خصوصی", + "notification.label.reply": "پاسخ", + "notification.mention": "اشاره", "notification.moderation-warning.learn_more": "بیشتر بدانید", + "notification.moderation_warning": "هشداری مدیریتی گرفته‌اید", + "notification.moderation_warning.action_delete_statuses": "برخی از فرسته‌هایتان برداشته شدند.", + "notification.moderation_warning.action_disable": "حسابتان از کار افتاد.", + "notification.moderation_warning.action_mark_statuses_as_sensitive": "برخی از فرسته‌هایتان به عنوان حسّاس علامت خوردند.", + "notification.moderation_warning.action_none": "حسابتان هشداری مدیریتی گرفت.", + "notification.moderation_warning.action_sensitive": "فرسته‌هایتان از اکنون به عنوان حسّاس علامت خواهند خورد.", + "notification.moderation_warning.action_silence": "حسابتان محدود شده.", + "notification.moderation_warning.action_suspend": "حسابتان معلّق شده.", "notification.own_poll": "نظرسنجیتان پایان یافت", + "notification.poll": "نظرسنجی‌ای که در آن رأی دادید به پایان رسید", "notification.reblog": "‫{name}‬ فرسته‌تان را تقویت کرد", + "notification.relationships_severance_event": "قطع ارتباط با {name}", "notification.relationships_severance_event.learn_more": "بیشتر بدانید", "notification.status": "{name} چیزی فرستاد", "notification.update": "{name} فرسته‌ای را ویرایش کرد", "notification_requests.accept": "پذیرش", + "notification_requests.confirm_accept_multiple.title": "پذیرش درخواست‌های آگاهی؟", + "notification_requests.confirm_dismiss_multiple.title": "رد کردن درخواست‌های آگاهی؟", "notification_requests.dismiss": "دورانداختن", + "notification_requests.edit_selection": "ویرایش", + "notification_requests.exit_selection": "انجام شد", "notification_requests.maximize": "بیشنه", + "notification_requests.minimize_banner": "کمینه کردن بیرق آگاهی‌های پالوده", + "notification_requests.notifications_from": "آگاهی‌ها از {name}", + "notification_requests.title": "آگاهی‌های پالوده", + "notification_requests.view": "دیدن آگاهی‌ها", "notifications.clear": "پاک‌سازی آگاهی‌ها", "notifications.clear_confirmation": "مطمئنید می‌خواهید همهٔ آگاهی‌هایتان را برای همیشه پاک کنید؟", + "notifications.clear_title": "پاک‌سازی آگاهی‌ها؟", "notifications.column_settings.admin.report": "گزارش‌های جدید:", "notifications.column_settings.admin.sign_up": "ثبت نام‌های جدید:", "notifications.column_settings.alert": "آگاهی‌های میزکار", "notifications.column_settings.beta.category": "ویژگی‌های آزمایشی", + "notifications.column_settings.beta.grouping": "گروه‌بندی آگاهی‌ها", "notifications.column_settings.favourite": "برگزیده‌ها:", + "notifications.column_settings.filter_bar.advanced": "نمایش همۀ دسته‌ها", + "notifications.column_settings.filter_bar.category": "نوار پالایش سریع", "notifications.column_settings.follow": "پی‌گیرندگان جدید:", "notifications.column_settings.follow_request": "درخواست‌های جدید پی‌گیری:", "notifications.column_settings.mention": "اشاره‌ها:", @@ -475,8 +559,19 @@ "notifications.permission_denied": "آگاهی‌های میزکار به دلیل رد کردن درخواست اجازهٔ پیشین مرورگر، در دسترس نیستند", "notifications.permission_denied_alert": "از آن‌جا که پیش از این اجازهٔ مرورگر رد شده است، آگاهی‌های میزکار نمی‌توانند به کار بیفتند", "notifications.permission_required": "آگاهی‌های میزکار در دسترس نیستند زیرا اجازه‌های لازم، اعطا نشده.", + "notifications.policy.accept": "پذیرش", + "notifications.policy.accept_hint": "نمایش در آگاهی‌ها", + "notifications.policy.drop": "چشم‌پوشی", + "notifications.policy.drop_hint": "فرستادن به هیچ. دیگر هرگز دیده نخواهند شد", + "notifications.policy.filter": "پالایش", + "notifications.policy.filter_hint": "فرستادن به صندوق آگاهی‌های پالوده", + "notifications.policy.filter_limited_accounts_hint": "محدود شده به دست ناظم‌های کارساز", + "notifications.policy.filter_limited_accounts_title": "حساب‌های مدیریت شده", + "notifications.policy.filter_new_accounts_title": "حساب‌های جدید", "notifications.policy.filter_not_followers_title": "کسانی که شما را دنبال میکنند", "notifications.policy.filter_not_following_hint": "", + "notifications.policy.filter_not_following_title": "کسانی که پی نمی‌گیرید", + "notifications.policy.title": "مدیریت آگاهی‌ها از…", "notifications_permission_banner.enable": "به کار انداختن آگاهی‌های میزکار", "notifications_permission_banner.how_to_control": "برای دریافت آگاهی‌ها هنگام باز نبودن ماستودون، آگاهی‌های میزکار را به کار بیندازید. پس از به کار افتادنشان می‌توانید گونه‌های دقیق برهم‌کنش‌هایی که آگاهی‌های میزکار تولید می‌کنند را از {icon} بالا واپایید.", "notifications_permission_banner.title": "هرگز چیزی را از دست ندهید", @@ -609,6 +704,7 @@ "report_notification.categories.spam": "هرزنامه", "report_notification.categories.spam_sentence": "هرزنامه", "report_notification.categories.violation": "تخطّی از قانون", + "report_notification.categories.violation_sentence": "تخطّی از قانون", "report_notification.open": "گشودن گزارش", "search.no_recent_searches": "جست‌وجوی اخیری نیست", "search.placeholder": "جست‌وجو", @@ -653,9 +749,11 @@ "status.direct": "اشارهٔ خصوصی به ‪@{name}‬", "status.direct_indicator": "اشارهٔ خصوصی", "status.edit": "ویرایش", + "status.edited": "آخرین ویرایش {date}", "status.edited_x_times": "{count, plural, one {{count} مرتبه} other {{count} مرتبه}} ویرایش شد", "status.embed": "جاسازی", "status.favourite": "برگزیده‌", + "status.favourites": "{count, plural, one {برگزیده} other {برگزیده}}", "status.filter": "پالایش این فرسته", "status.history.created": "توسط {name} در {date} ایجاد شد", "status.history.edited": "توسط {name} در {date} ویرایش شد", @@ -674,6 +772,7 @@ "status.reblog": "تقویت", "status.reblog_private": "تقویت برای مخاطبان نخستین", "status.reblogged_by": "‫{name}‬ تقویت کرد", + "status.reblogs": "{count, plural, one {تقویت} other {تقویت}}", "status.reblogs.empty": "هنوز هیچ کسی این فرسته را تقویت نکرده است. وقتی کسی چنین کاری کند، این‌جا نمایش داده خواهد شد.", "status.redraft": "حذف و بازنویسی", "status.remove_bookmark": "برداشتن نشانک", diff --git a/app/javascript/mastodon/locales/ia.json b/app/javascript/mastodon/locales/ia.json index f575c005d8..8a448920c1 100644 --- a/app/javascript/mastodon/locales/ia.json +++ b/app/javascript/mastodon/locales/ia.json @@ -180,6 +180,7 @@ "confirmations.discard_edit_media.message": "Tu ha cambiamentos non salvate in le description o previsualisation del objecto multimedial. Abandonar los?", "confirmations.edit.confirm": "Modificar", "confirmations.edit.message": "Si tu modifica isto ora, le message in curso de composition essera perdite. Es tu secur de voler continuar?", + "confirmations.edit.title": "Superscriber le message?", "confirmations.logout.confirm": "Clauder session", "confirmations.logout.message": "Es tu secur que tu vole clauder le session?", "confirmations.logout.title": "Clauder session?", @@ -189,6 +190,7 @@ "confirmations.redraft.title": "Deler e rescriber le message?", "confirmations.reply.confirm": "Responder", "confirmations.reply.message": "Si tu responde ora, le message in curso de composition essera perdite. Es tu secur de voler continuar?", + "confirmations.reply.title": "Superscriber le message?", "confirmations.unfollow.confirm": "Non plus sequer", "confirmations.unfollow.message": "Es tu secur que tu vole cessar de sequer {name}?", "confirmations.unfollow.title": "Cessar de sequer le usator?", @@ -361,6 +363,12 @@ "home.pending_critical_update.link": "Vider actualisationes", "home.pending_critical_update.title": "Actualisation de securitate critic disponibile!", "home.show_announcements": "Monstrar annuncios", + "ignore_notifications_modal.ignore": "Ignorar le notificationes", + "ignore_notifications_modal.limited_accounts_title": "Ignorar le notificationes de contos moderate?", + "ignore_notifications_modal.new_accounts_title": "Ignorar le notificationes de nove contos?", + "ignore_notifications_modal.not_followers_title": "Ignorar notificationes de personas qui non te seque?", + "ignore_notifications_modal.not_following_title": "Ignorar notificationes de personas que tu non seque?", + "ignore_notifications_modal.private_mentions_title": "Ignorar notificationes de mentiones private non requestate?", "interaction_modal.description.favourite": "Con un conto sur Mastodon, tu pote marcar iste message como favorite pro informar le autor que tu lo apprecia e lo salva pro plus tarde.", "interaction_modal.description.follow": "Con un conto sur Mastodon, tu pote sequer {name} e reciper su messages in tu fluxo de initio.", "interaction_modal.description.reblog": "Con un conto sur Mastodon, tu pote impulsar iste message pro condivider lo con tu proprie sequitores.", @@ -479,6 +487,8 @@ "navigation_bar.security": "Securitate", "not_signed_in_indicator.not_signed_in": "Es necessari aperir session pro acceder a iste ressource.", "notification.admin.report": "{name} ha reportate {target}", + "notification.admin.report_account": "{name} ha reportate {count, plural, one {un message} other {# messages}} de {target} per {category}", + "notification.admin.report_account_other": "{name} ha reportate {count, plural, one {un message} other {# messages}} de {target}", "notification.admin.report_statuses": "{name} ha reportate {target} pro {category}", "notification.admin.report_statuses_other": "{name} ha reportate {target}", "notification.admin.sign_up": "{name} se ha inscribite", diff --git a/app/javascript/mastodon/locales/la.json b/app/javascript/mastodon/locales/la.json index 5ef238a2bd..dc07961441 100644 --- a/app/javascript/mastodon/locales/la.json +++ b/app/javascript/mastodon/locales/la.json @@ -24,6 +24,7 @@ "announcement.announcement": "Proclamatio", "attachments_list.unprocessed": "(immūtātus)", "block_modal.you_wont_see_mentions": "Nuntios quibus eos commemorant non videbis.", + "boost_modal.combo": "Potes premēre {combo} ut hoc iterum transilīre", "bundle_column_error.error.title": "Eheu!", "bundle_column_error.retry": "Retemptare", "bundle_column_error.routing.title": "CCCCIIII", @@ -72,7 +73,10 @@ "empty_column.account_timeline": "Hic nulla contributa!", "empty_column.account_unavailable": "Notio non impetrabilis", "empty_column.blocks": "Nondum quemquam usorem obsēcāvisti.", + "empty_column.bookmarked_statuses": "Nūllae adhuc postēs notātī habēs. Ubi unum notāverīs, hic apparebit.", "empty_column.direct": "Nōn habēs adhūc ullo mentionēs prīvātās. Cum ūnam mīseris aut accipis, hīc apparēbit.", + "empty_column.favourited_statuses": "Nūllae adhuc postēs praeferendī habēs. Ubi unum praeferās, hic apparebit.", + "empty_column.follow_requests": "Nūllae adhuc petitionēs sequendi habēs. Ubi unum accipīs, hic apparebit.", "empty_column.followed_tags": "Nōn adhūc aliquem hastāginem secūtus es. Cum id fēceris, hic ostendētur.", "empty_column.home": "Tua linea temporum domesticus vacua est! Sequere plures personas ut eam compleas.", "empty_column.list": "There is nothing in this list yet. When members of this list post new statuses, they will appear here.", @@ -84,12 +88,19 @@ "firehose.all": "Omnis", "footer.about": "De", "generic.saved": "Servavit", + "hashtag.column_header.tag_mode.none": "sine {additional}", "hashtag.column_settings.tag_mode.all": "Haec omnia", "hashtag.column_settings.tag_toggle": "Include additional tags in this column", "hashtag.counter_by_accounts": "{count, plural, one {{counter} particeps} other {{counter} participēs}}", "hashtag.counter_by_uses": "{count, plural, one {{counter} nuntius} other {{counter} nuntii}}", "hashtag.counter_by_uses_today": "{count, plural, one {{counter} nuntius} other {{counter} nuntii}} hodie", "hashtags.and_other": "…et {count, plural, other {# plus}}", + "ignore_notifications_modal.filter_to_act_users": "Adhuc poteris accipere, reicere, vel referre usores", + "ignore_notifications_modal.filter_to_review_separately": "Percolantur notificatiōnes separātim recensere potes", + "interaction_modal.description.favourite": "Cum accūntū in Mastodon, hanc postem praeferre potes ut auctōrī indicēs tē eam aestimāre et ad posterius servēs.", + "interaction_modal.description.follow": "Cum accūntū in Mastodon, {name} sequī potes ut eōrum postēs in tēlā domī tuā recipiās.", + "interaction_modal.description.reply": "Mastodon de Ratione, huic nuntio respondere potes.", + "interaction_modal.sign_in": "Ad hōc servientem nōn dēlūxī. Ubi accūntum tuum hospitātum est?", "intervals.full.days": "{number, plural, one {# die} other {# dies}}", "intervals.full.hours": "{number, plural, one {# hora} other {# horae}}", "intervals.full.minutes": "{number, plural, one {# minutum} other {# minuta}}", @@ -155,6 +166,8 @@ "notification.status": "{name} nuper publicavit", "notification.update": "{name} nuntium correxit", "notification_requests.accept": "Accipe", + "notification_requests.confirm_accept_multiple.message": "Tu es accepturus {count, plural, one {una notitia petitionem} other {# notitia petitiones}}. Certus esne procedere vis?", + "notification_requests.confirm_dismiss_multiple.message": "Tu {count, plural, one {unam petitionem notificationis} other {# petitiones notificationum}} abrogāre prōximum es. {count, plural, one {Illa} other {Eae}} facile accessū nōn erit. Certus es tē procedere velle?", "notifications.filter.all": "Omnia", "notifications.filter.polls": "Eventus electionis", "notifications.group": "Notificātiōnēs", @@ -163,6 +176,8 @@ "onboarding.follows.lead": "Tua domus feed est principalis via Mastodon experīrī. Quō plūrēs persōnas sequeris, eō actīvior et interessantior erit. Ad tē incipiendum, ecce quaedam suāsiones:", "onboarding.follows.title": "Popular on Mastodon", "onboarding.profile.display_name_hint": "Tuum nomen completum aut tuum nomen ludens…", + "onboarding.profile.lead": "Hoc semper postea in ratiōnibus complērī potest, ubi etiam plūrēs optiōnēs personalizātiōnis praesto sunt.", + "onboarding.profile.note_hint": "Alios hominēs vel #hashtags @nōmināre potes…", "onboarding.start.lead": "Nunc pars es Mastodonis, singularis, socialis medii platformae decentralis ubi—non algorismus—tuam ipsius experientiam curas. Incipiāmus in nova hac socialis regione:", "onboarding.start.skip": "Want to skip right ahead?", "onboarding.start.title": "Perfecisti eam!", @@ -206,8 +221,11 @@ "report.mute_explanation": "Non videbis eōrum nuntiōs. Possunt adhuc tē sequī et tuōs nuntiōs vidēre, nec sciēbunt sē tacitōs esse.", "report.next": "Secundum", "report.placeholder": "Commentāriī adiūnctī", + "report.reasons.legal_description": "Putās id legem tuae aut servientis patriae violāre.", + "report.reasons.violation_description": "Scis quod certa praecepta frangit", "report.submit": "Mittere", "report.target": "Report {target}", + "report.unfollow_explanation": "Tu hanc rationem secutus es. Non videre stationes suas in domo tua amplius pascere, eas sequere.", "report_notification.attached_statuses": "{count, plural, one {{count} nuntius} other {{count} nuntii}} attachiatus", "report_notification.categories.other": "Altera", "search.placeholder": "Quaerere", diff --git a/app/javascript/mastodon/locales/ms.json b/app/javascript/mastodon/locales/ms.json index c9f8b7a274..4a32b1d820 100644 --- a/app/javascript/mastodon/locales/ms.json +++ b/app/javascript/mastodon/locales/ms.json @@ -11,6 +11,7 @@ "about.not_available": "Maklumat ini belum tersedia pada pelayan ini.", "about.powered_by": "Media sosial terpencar yang dikuasakan oleh {mastodon}", "about.rules": "Peraturan pelayan", + "account.account_note_header": "Personal note", "account.add_or_remove_from_list": "Tambah atau Buang dari senarai", "account.badges.bot": "Bot", "account.badges.group": "Kumpulan", @@ -33,6 +34,7 @@ "account.follow_back": "Ikut balik", "account.followers": "Pengikut", "account.followers.empty": "Belum ada yang mengikuti pengguna ini.", + "account.followers_counter": "{count, plural, one {{counter} Diikuti} other {{counter} Diikuti}}", "account.following": "Mengikuti", "account.follows.empty": "Pengguna ini belum mengikuti sesiapa.", "account.go_to_profile": "Pergi ke profil", diff --git a/app/javascript/mastodon/locales/ru.json b/app/javascript/mastodon/locales/ru.json index 4439b8dc0a..2c55da90b7 100644 --- a/app/javascript/mastodon/locales/ru.json +++ b/app/javascript/mastodon/locales/ru.json @@ -190,6 +190,7 @@ "confirmations.unfollow.message": "Вы уверены, что хотите отписаться от {name}?", "confirmations.unfollow.title": "Отписаться?", "content_warning.hide": "Скрыть пост", + "content_warning.show": "Всё равно показать", "conversation.delete": "Удалить беседу", "conversation.mark_as_read": "Отметить как прочитанное", "conversation.open": "Просмотр беседы", diff --git a/app/javascript/mastodon/locales/zh-CN.json b/app/javascript/mastodon/locales/zh-CN.json index fded16b195..ea4ebcda47 100644 --- a/app/javascript/mastodon/locales/zh-CN.json +++ b/app/javascript/mastodon/locales/zh-CN.json @@ -94,7 +94,7 @@ "block_modal.they_cant_mention": "他们不能提及或关注你。", "block_modal.they_cant_see_posts": "他们看不到你的嘟文,你也看不到他们的嘟文。", "block_modal.they_will_know": "他们将能看到他们被屏蔽。", - "block_modal.title": "屏蔽该用户?", + "block_modal.title": "是否屏蔽该用户?", "block_modal.you_wont_see_mentions": "你将无法看到提及他们的嘟文。", "boost_modal.combo": "下次按住 {combo} 即可跳过此提示", "boost_modal.reblog": "是否转嘟?", @@ -317,10 +317,10 @@ "follow_suggestions.featured_longer": "由 {domain} 管理团队精选", "follow_suggestions.friends_of_friends_longer": "在你关注的人中很受欢迎", "follow_suggestions.hints.featured": "该用户已被 {domain} 管理团队精选。", - "follow_suggestions.hints.friends_of_friends": "该用户在您关注的人中很受欢迎。", + "follow_suggestions.hints.friends_of_friends": "该用户在你关注的人中很受欢迎。", "follow_suggestions.hints.most_followed": "该用户是 {domain} 上关注度最高的用户之一。", "follow_suggestions.hints.most_interactions": "该用户最近在 {domain} 上获得了很多关注。", - "follow_suggestions.hints.similar_to_recently_followed": "该用户与您最近关注的用户类似。", + "follow_suggestions.hints.similar_to_recently_followed": "该用户与你最近关注的用户类似。", "follow_suggestions.personalized_suggestion": "个性化建议", "follow_suggestions.popular_suggestion": "热门建议", "follow_suggestions.popular_suggestion_longer": "在 {domain} 上很受欢迎", @@ -364,7 +364,7 @@ "home.column_settings.show_reblogs": "显示转嘟", "home.column_settings.show_replies": "显示回复", "home.hide_announcements": "隐藏公告", - "home.pending_critical_update.body": "请尽快更新您的 Mastodon 服务器!", + "home.pending_critical_update.body": "请尽快更新你的 Mastodon 服务器!", "home.pending_critical_update.link": "查看更新", "home.pending_critical_update.title": "紧急安全更新可用!", "home.show_announcements": "显示公告", @@ -618,12 +618,12 @@ "onboarding.follows.lead": "你管理你自己的家庭饲料。你关注的人越多,它将越活跃和有趣。 这些配置文件可能是一个很好的起点——你可以随时取消关注它们!", "onboarding.follows.title": "定制您的主页动态", "onboarding.profile.discoverable": "让我的资料卡可被他人发现", - "onboarding.profile.discoverable_hint": "当您选择在 Mastodon 上启用发现功能时,你的嘟文可能会出现在搜索结果和热门中,你的账户可能会被推荐给与你兴趣相似的人。", + "onboarding.profile.discoverable_hint": "当你选择在 Mastodon 上启用发现功能时,你的嘟文可能会出现在搜索结果和热门中,你的账户可能会被推荐给与你兴趣相似的人。", "onboarding.profile.display_name": "昵称", - "onboarding.profile.display_name_hint": "您的全名或昵称…", - "onboarding.profile.lead": "您可以稍后在设置中完成此操作,设置中有更多的自定义选项。", + "onboarding.profile.display_name_hint": "你的全名或昵称…", + "onboarding.profile.lead": "你可以稍后在设置中完成此操作,设置中有更多的自定义选项。", "onboarding.profile.note": "简介", - "onboarding.profile.note_hint": "您可以提及 @其他人 或 #标签…", + "onboarding.profile.note_hint": "你可以提及 @其他人 或 #标签…", "onboarding.profile.save_and_continue": "保存并继续", "onboarding.profile.title": "设置个人资料", "onboarding.profile.upload_avatar": "上传头像", @@ -632,7 +632,7 @@ "onboarding.share.message": "我是来自 #Mastodon 的 {username}!请在 {url} 关注我。", "onboarding.share.next_steps": "可能的下一步:", "onboarding.share.title": "分享你的个人资料", - "onboarding.start.lead": "您新的 Mastodon 帐户已准备好。下面是如何最大限度地利用它:", + "onboarding.start.lead": "你的新 Mastodon 帐户已准备好。下面是如何最大限度地利用它:", "onboarding.start.skip": "想要在前面跳过吗?", "onboarding.start.title": "你已经成功了!", "onboarding.steps.follow_people.body": "You curate your own feed. Lets fill it with interesting people.", @@ -644,7 +644,7 @@ "onboarding.steps.share_profile.body": "Let your friends know how to find you on Mastodon!", "onboarding.steps.share_profile.title": "分享你的个人资料", "onboarding.tips.2fa": "你知道吗?你可以在账户设置中配置双因素认证来保护账户安全。可以使用你选择的任何 TOTP 应用,无需电话号码!", - "onboarding.tips.accounts_from_other_servers": "您知道吗? 既然Mastodon是去中心化的,您所看到的一些账户将被托管在您以外的服务器上。 但你可以无缝地与他们交互!他们的服务器在他们的用户名的后半部分!", + "onboarding.tips.accounts_from_other_servers": "你知道吗? 既然Mastodon是去中心化的,你所看到的一些账户将被托管在你以外的服务器上。 但你可以无缝地与他们交互!他们的服务器在他们的用户名的后半部分!", "onboarding.tips.migration": "您知道吗? 如果你觉得你喜欢 {domain} 不是您未来的一个伟大的服务器选择。 您可以移动到另一个 Mastodon 服务器而不失去您的关注者。 您甚至可以主持您自己的服务器!", "onboarding.tips.verification": "您知道吗? 您可以通过在自己的网站上放置一个链接到您的 Mastodon 个人资料并将网站添加到您的个人资料来验证您的帐户。 无需收费或文书工作!", "password_confirmation.exceeds_maxlength": "密码确认超过最大密码长度", diff --git a/app/javascript/mastodon/locales/zh-TW.json b/app/javascript/mastodon/locales/zh-TW.json index df754f6d68..257bec0163 100644 --- a/app/javascript/mastodon/locales/zh-TW.json +++ b/app/javascript/mastodon/locales/zh-TW.json @@ -21,7 +21,7 @@ "account.blocked": "已封鎖", "account.cancel_follow_request": "收回跟隨請求", "account.copy": "複製個人檔案連結", - "account.direct": "私訊 @{name}", + "account.direct": " @{name}", "account.disable_notifications": "取消來自 @{name} 嘟文的通知", "account.domain_blocked": "已封鎖網域", "account.edit_profile": "編輯個人檔案", diff --git a/config/locales/activerecord.zh-CN.yml b/config/locales/activerecord.zh-CN.yml index c510a58d14..1b661266ca 100644 --- a/config/locales/activerecord.zh-CN.yml +++ b/config/locales/activerecord.zh-CN.yml @@ -56,4 +56,4 @@ zh-CN: webhook: attributes: events: - invalid_permissions: 不能包含您没有权限的事件 + invalid_permissions: 不能包含你没有权限的事件 diff --git a/config/locales/ar.yml b/config/locales/ar.yml index 7ab1b4f075..ee05684b6c 100644 --- a/config/locales/ar.yml +++ b/config/locales/ar.yml @@ -1824,7 +1824,7 @@ ar: keep_pinned: الاحتفاظ بالمنشورات المثبتة keep_pinned_hint: لن تحذف أي من منشوراتك المثبتة keep_polls: الاحتفاظ باستطلاعات الرأي - keep_polls_hint: لم تقم بحذف أي من استطلاعاتك + keep_polls_hint: لن يتم حذف أي من استطلاعات الرأي الخاصة بك keep_self_bookmark: احتفظ بالمنشورات التي أدرجتها في الفواصل المرجعية keep_self_bookmark_hint: لن تحذف منشوراتك الخاصة إذا قمت بوضع علامة مرجعية عليها keep_self_fav: احتفظ بالمنشورات التي أدرجتها في المفضلة diff --git a/config/locales/ca.yml b/config/locales/ca.yml index 9a8f32117e..8918228f46 100644 --- a/config/locales/ca.yml +++ b/config/locales/ca.yml @@ -25,6 +25,8 @@ ca: admin: account_actions: action: Realitza l'acció + already_silenced: Aquest compte ja s'ha silenciat. + already_suspended: Aquest compte ja s'ha suspès. title: Fer l'acció de moderació a %{acct} account_moderation_notes: create: Crea nota @@ -46,6 +48,7 @@ ca: title: Canvia l'adreça electrònica de %{username} change_role: changed_msg: Els privilegis del compte s'han canviat correctament! + edit_roles: Gestió de rols d'usuari label: Canvia rol no_role: Sense rol title: Canvia el rol per a %{username} @@ -585,6 +588,7 @@ ca: silence_description_html: El compte només serà visible a qui ja el seguia o l'ha cercat manualment, limitant-ne fortament l'abast. Sempre es pot revertir. Es tancaran tots els informes contra aquest compte. suspend_description_html: Aquest compte i tots els seus continguts seran inaccessibles i finalment eliminats, i interaccionar amb ell no serà possible. Reversible en 30 dies. Tanca tots els informes contra aquest compte. actions_description_remote_html: Decideix quina acció prendre per a resoldre aquest informe. Això només afectarà com el teu servidor es comunica amb aquest compte remot i en gestiona el contingut. + actions_no_posts: Aquest informe no té associada cap publicació a esborrar add_to_report: Afegir més al informe already_suspended_badges: local: Ja és suspès en aquest servidor diff --git a/config/locales/cy.yml b/config/locales/cy.yml index 492eb8af7e..4a01967e23 100644 --- a/config/locales/cy.yml +++ b/config/locales/cy.yml @@ -33,6 +33,8 @@ cy: admin: account_actions: action: Cyflawni gweithred + already_silenced: Mae'r cyfrif hwn eisoes wedi'i dewi. + already_suspended: Mae'r cyfrif hwn eisoes wedi'i atal. title: Cyflawni gweithred cymedroli ar %{acct} account_moderation_notes: create: Gadael nodyn @@ -54,6 +56,7 @@ cy: title: Newid e-bost i %{username} change_role: changed_msg: Rôl wedi ei newid yn llwyddiannus! + edit_roles: Rheoli rolau defnyddwyr label: Newid rôl no_role: Dim rôl title: Newid rôl %{username} @@ -650,6 +653,7 @@ cy: suspend_description_html: Bydd y cyfrif a'i holl gynnwys yn anhygyrch ac yn cael ei ddileu yn y pen draw, a bydd rhyngweithio ag ef yn amhosibl. Yn gildroadwy o fewn 30 diwrnod. Yn cau pob adroddiad yn erbyn y cyfrif hwn. actions_description_html: Penderfynwch pa gamau i'w cymryd i delio gyda'r adroddiad hwn. Os cymerwch gamau cosbi yn erbyn y cyfrif a adroddwyd, bydd hysbysiad e-bost yn cael ei anfon atyn nhw, ac eithrio pan fydd y categori Sbam yn cael ei ddewis. actions_description_remote_html: Penderfynwch pa gamau i'w cymryd i ddatrys yr adroddiad hwn. Bydd hyn ond yn effeithio ar sut mae'ch gweinydd yn cyfathrebu â'r cyfrif hwn o bell ac yn trin ei gynnwys. + actions_no_posts: Nid oes gan yr adroddiad hwn unrhyw bostiadau cysylltiedig i'w dileu add_to_report: Ychwanegu rhagor i adroddiad already_suspended_badges: local: Wedi atal dros dro ar y gweinydd hwn yn barod @@ -1558,6 +1562,7 @@ cy: media_attachments: validations: images_and_video: Methu atodi fideo i bostiad sydd eisoes yn cynnwys delweddau + not_found: Cyfryngau %{ids} heb eu canfod neu wedi'u hatodi i bostiad arall yn barod not_ready: Methu atodi ffeiliau nad ydynt wedi gorffen prosesu. Ceisiwch eto, cyn hir! too_many: Methu atodi mwy na 4 ffeil migrations: diff --git a/config/locales/da.yml b/config/locales/da.yml index 1366370eb0..e3f8343452 100644 --- a/config/locales/da.yml +++ b/config/locales/da.yml @@ -25,6 +25,8 @@ da: admin: account_actions: action: Udfør handling + already_silenced: Denne konto er allerede gjort tavs. + already_suspended: Denne konto er allerede suspenderet. title: Udfør moderatorhandling på %{acct} account_moderation_notes: create: Skriv notat @@ -46,6 +48,7 @@ da: title: Skift e-mail for %{username} change_role: changed_msg: Rolle ændret! + edit_roles: Håndtér brugerroller label: Ændr rolle no_role: Ingen rolle title: Ændr rolle for %{username} @@ -602,6 +605,7 @@ da: suspend_description_html: Kontoen inkl. alt indhold utilgængeliggøres og interaktion umuliggøres, og den slettes på et tidspunkt. Kan omgøres inden for 30 dage. Lukker alle indrapporteringer af kontoen. actions_description_html: Afgør, hvilke foranstaltning, der skal træffes for at løse denne anmeldelse. Ved en straffende foranstaltning mod den anmeldte konto, fremsendes en e-mailnotifikation, undtagen når kategorien Spam er valgt. actions_description_remote_html: Fastslå en nødvendig handling mhp. at løse denne anmeldelse. Dette vil kun påvirke din servers kommunikation med, og indholdshåndtering for, fjernkontoen. + actions_no_posts: Denne anmeldelse har ingen tilknyttede indlæg at slette add_to_report: Føj mere til anmeldelse already_suspended_badges: local: Allerede suspenderet på denne server diff --git a/config/locales/de.yml b/config/locales/de.yml index e5e3f37a36..2952d22d7c 100644 --- a/config/locales/de.yml +++ b/config/locales/de.yml @@ -25,6 +25,8 @@ de: admin: account_actions: action: Aktion ausführen + already_silenced: Dieses Konto wurde bereits stummgeschaltet. + already_suspended: Dieses Konto wurde bereits gesperrt. title: "@%{acct} moderieren" account_moderation_notes: create: Notiz abspeichern @@ -46,6 +48,7 @@ de: title: E-Mail-Adresse für %{username} ändern change_role: changed_msg: Rolle erfolgreich geändert! + edit_roles: Rollen verwalten label: Rolle ändern no_role: Keine Rolle title: Rolle für %{username} ändern @@ -602,6 +605,7 @@ de: suspend_description_html: Das Konto und alle Inhalte werden unzugänglich und ggf. gelöscht. Eine Interaktion mit dem Konto wird unmöglich. Dies kann innerhalb von 30 Tagen rückgängig gemacht werden. Alle Meldungen zu diesem Konto werden geschlossen. actions_description_html: Entscheide, welche Maßnahmen du zum Klären dieser Meldung ergreifen möchtest. Wenn du eine Strafmaßnahme gegen das gemeldete Konto ergreifst, wird eine E-Mail-Benachrichtigung an dieses gesendet, außer wenn die Spam-Kategorie ausgewählt ist. actions_description_remote_html: Entscheide, welche Maßnahmen du zum Klären dieser Meldung ergreifen möchtest. Dies wirkt sich lediglich darauf aus, wie dein Server mit diesem externen Konto kommuniziert und dessen Inhalt handhabt. + actions_no_posts: Diese Meldung enthält keine zu löschenden Beiträge add_to_report: Meldung ergänzen already_suspended_badges: local: Auf diesem Server bereits gesperrt @@ -1454,7 +1458,7 @@ de: media_attachments: validations: images_and_video: Es kann kein Video an einen Beitrag angehängt werden, der bereits Bilder enthält - not_found: Medien %{ids} nicht verfügbar oder bereits an einen anderen Beitrag angehängt + not_found: Medieninhalt(e) %{ids} nicht gefunden oder bereits an einen anderen Beitrag angehängt not_ready: Dateien, die noch nicht verarbeitet wurden, können nicht angehängt werden. Versuche es gleich noch einmal! too_many: Mehr als vier Dateien können nicht angehängt werden migrations: diff --git a/config/locales/devise.zh-CN.yml b/config/locales/devise.zh-CN.yml index 2a50c131d5..86e78c1b18 100644 --- a/config/locales/devise.zh-CN.yml +++ b/config/locales/devise.zh-CN.yml @@ -50,12 +50,12 @@ zh-CN: two_factor_disabled: explanation: 目前只能通过邮箱地址和密码登录。 subject: Mastodon:双因素认证已禁用 - subtitle: 您账户的双因素认证已被停用。 + subtitle: 你账户的双因素认证已被停用。 title: 双因素认证已停用 two_factor_enabled: explanation: 登录时需要输入先前配对好的TOTP应用生成的令牌。 subject: Mastodon:双因素认证已启用 - subtitle: 您账户的双因素认证已被启用。 + subtitle: 你账户的双因素认证已被启用。 title: 双因素认证已启用 two_factor_recovery_codes_changed: explanation: 新恢复码已生成,同时旧恢复码已失效。 @@ -74,13 +74,13 @@ zh-CN: subject: Mastodon:安全密钥已删除 title: 你的安全密钥之一已被删除 webauthn_disabled: - explanation: 您账户的安全密钥身份认证已被停用。 + explanation: 你账户的安全密钥身份认证已被停用。 extra: 目前只能用先前配对的TOTP应用生成的令牌登录。 subject: Mastodon:安全密钥认证已禁用 title: 安全密钥已禁用 webauthn_enabled: - explanation: 您账户的安全密钥身份认证已被启用。 - extra: 您的安全密钥现在可用于登录。 + explanation: 你账户的安全密钥身份认证已被启用。 + extra: 你的安全密钥现在可用于登录。 subject: Mastodon:安全密钥认证已启用 title: 已启用安全密钥 omniauth_callbacks: diff --git a/config/locales/doorkeeper.fa.yml b/config/locales/doorkeeper.fa.yml index c56e76e346..0ce7a9591d 100644 --- a/config/locales/doorkeeper.fa.yml +++ b/config/locales/doorkeeper.fa.yml @@ -83,6 +83,7 @@ fa: access_denied: صاحب منبع یا کارساز تأیید هویت، درخواست را رد کردند. credential_flow_not_configured: جریان اعتبارنامهٔ گذرواژهٔ مالک منبع به دلیل پیکربندی نشده بودن Doorkeeper.configure.resource_owner_from_credentials شکست خورد. invalid_client: تأیید هویت کارخواه به دلیل کارخواه ناشناخته، عدم وجود تأیید هویت کاره یا روش تأیید هویت پشتیبانی‌نشده شکست خورد. + invalid_code_challenge_method: روش چالش کدی باید S256 باشد. متن خام پشتیبانی نمی‌شود. invalid_grant: اعطای دسترسی فراهم ‌شده نامعتبر، منقضی یا نامطابق با نشانی بازگشت استفاده‌شده در درخواست تأیید هویت بوده و یا برای کارخواهی دیگر صادر شده است. invalid_redirect_uri: نشانی بازگشت موجود، معتبر نیست. invalid_request: @@ -135,6 +136,7 @@ fa: media: پیوست‌های رسانه‌ای mutes: خموش‌ها notifications: آگاهی‌ها + profile: نمایهٔ ماستودونتان push: آگاهی‌های ارسالی reports: گزارش‌ها search: جست‌وجو @@ -165,6 +167,7 @@ fa: admin:write:reports: انجام کنش مدیریتی روی گزارش‌ها crypto: از رمزگذاری سرتاسر استفاده کنید follow: پیگیری، مسدودسازی، لغو مسدودسازی، و لغو پیگیری حساب‌ها + profile: فقط خواندن اطّلاعات نمایهٔ حسابتان push: دریافت آگاهی‌ای ارسالیتان read: خواندن اطلاعات حساب شما read:accounts: دیدن اطّلاعات حساب diff --git a/config/locales/es-AR.yml b/config/locales/es-AR.yml index ab0dcb58fa..520211e2e2 100644 --- a/config/locales/es-AR.yml +++ b/config/locales/es-AR.yml @@ -25,6 +25,8 @@ es-AR: admin: account_actions: action: Ejecutar acción + already_silenced: Esta cuenta ya ha sido limitada. + already_suspended: Esta cuenta ya ha sido suspendida. title: Ejecutar acción de moderación en %{acct} account_moderation_notes: create: Dejar nota @@ -46,6 +48,7 @@ es-AR: title: Cambiar correo electrónico para %{username} change_role: changed_msg: "¡Rol cambiado exitosamente!" + edit_roles: Administrar roles de usuario label: Cambiar rol no_role: Sin rol title: Cambiar rol para %{username} @@ -602,6 +605,7 @@ es-AR: suspend_description_html: La cuenta y todos sus contenidos serán inaccesibles y finalmente eliminados, e interactuar con ella será imposible. Revertible en 30 días. Esto cierra todas las denuncias contra esta cuenta. actions_description_html: Decidí qué medidas tomar para resolver esta denuncia. Si tomás una acción punitiva contra la cuenta denunciada, se le enviará a dicha cuenta una notificación por correo electrónico, excepto cuando se seleccione la categoría Spam. actions_description_remote_html: Decidí qué medidas tomar para resolver esta denuncia. Esto sólo afectará la forma en que tu servidor se comunica con esta cuenta remota y maneja su contenido. + actions_no_posts: Esta denuncia no tiene ningún mensaje asociado para eliminar add_to_report: Agregar más a la denuncia already_suspended_badges: local: Ya suspendido en este servidor diff --git a/config/locales/es-MX.yml b/config/locales/es-MX.yml index 9df6a784de..52e440ffed 100644 --- a/config/locales/es-MX.yml +++ b/config/locales/es-MX.yml @@ -1454,6 +1454,7 @@ es-MX: media_attachments: validations: images_and_video: No se puede adjuntar un video a un estado que ya contenga imágenes + not_found: Archivos multimedia %{ids} no encontrados, o ya se encuentran adjuntos a otra publicación not_ready: No se pueden adjuntar archivos que no se han terminado de procesar. ¡Inténtalo de nuevo en un momento! too_many: No se pueden adjuntar más de 4 archivos migrations: diff --git a/config/locales/es.yml b/config/locales/es.yml index 0bbad767e3..21b900192a 100644 --- a/config/locales/es.yml +++ b/config/locales/es.yml @@ -1454,6 +1454,7 @@ es: media_attachments: validations: images_and_video: No se puede adjuntar un video a unapublicación que ya contenga imágenes + not_found: Archivos multimedia %{ids} no encontrados, o ya se encuentran adjuntos a otra publicación not_ready: No se pueden adjuntar archivos que no se han terminado de procesar. ¡Inténtalo de nuevo en un momento! too_many: No se pueden adjuntar más de 4 archivos migrations: diff --git a/config/locales/et.yml b/config/locales/et.yml index 17fd41a8e3..bbd1b4ab20 100644 --- a/config/locales/et.yml +++ b/config/locales/et.yml @@ -25,12 +25,15 @@ et: admin: account_actions: action: Täida tegevus + already_silenced: See konto on juba vaigistatud. + already_suspended: See konto on juba peatatud. title: Rakenda moderaatori tegevus kasutajale %{acct} account_moderation_notes: create: Jäta teade created_msg: Modereerimisteade edukalt koostatud! destroyed_msg: Modereerimisteade edukalt kustutatud! accounts: + add_email_domain_block: Blokeeri e-posti domeen approve: Võta vastu approved_msg: Kasutaja %{username} liitumisavaldus rahuldatud are_you_sure: Oled kindel? @@ -45,6 +48,7 @@ et: title: Muuda e-postiaadressi kasutajale %{username} change_role: changed_msg: Roll on muudetud! + edit_roles: Halda kasutaja rolle label: Muuda rolli no_role: Roll puudub title: "%{username} rolli muutmine" @@ -57,6 +61,7 @@ et: demote: Alanda destroyed_msg: "%{username} andmed on nüüd lõpliku kustutamise ootel" disable: Lukusta + disable_sign_in_token_auth: E-posti võtme abil autentimise väljalülitamine disable_two_factor_authentication: Keela 2FA disabled: Keelatud display_name: Kuvanimi @@ -65,6 +70,7 @@ et: email: E-post email_status: E-posti olek enable: Luba + enable_sign_in_token_auth: Luba e-posti võtme abil autentimine enabled: Lubatud enabled_msg: Kasutaja %{username} konto taastatud followers: Jälgijad @@ -191,8 +197,10 @@ et: destroy_user_role: Rolli kustutamine disable_2fa_user: Keela 2FA disable_custom_emoji: Keelas kohandatud emotikoni + disable_sign_in_token_auth_user: Keela e-posti võtme abil autentimine kasutajale disable_user: Keelas kasutaja enable_custom_emoji: Lubas kohandatud emotikoni + enable_sign_in_token_auth_user: Luba e-posti võtme abil autentimine kasutajale enable_user: Lubas kasutaja memorialize_account: Igaveselt lahkunuks märkimine promote_user: Edendas kasutaja @@ -243,8 +251,10 @@ et: destroy_user_role_html: "%{name} kustutas %{target} rolli" disable_2fa_user_html: "%{name} eemaldas kasutaja %{target} kahe etapise nõude" disable_custom_emoji_html: "%{name} keelas emotikooni %{target}" + disable_sign_in_token_auth_user_html: "%{name} keelas e-posti võtme abil autentimise %{target} jaoks" disable_user_html: "%{name} keelas %{target} sisenemise" enable_custom_emoji_html: "%{name} lubas emotikooni %{target}" + enable_sign_in_token_auth_user_html: "%{name} lubas e-posti võtme abil autentimise %{target} jaoks" enable_user_html: "%{name} lubas %{target} sisenemise" memorialize_account_html: "%{name} märkis %{target} igaveselt lahkunuks" promote_user_html: "%{name} ülendas kasutajat %{target}" @@ -576,6 +586,7 @@ et: silence_description_html: Konto saab olema nähtav ainult senistele jälgijatele või otsestele pöördujatele, mõjutates avalikku levi. On tagasipööratav. Sulgeb kõik konto suhtes esitatud raportid. suspend_description_html: See konto ja kogu selle sisu muutub kättesaamatuks ning kustub lõpuks ja igasugune suhtlus sellega muutub võimatuks. Tagasipööratav 30 päeva jooksul. Lõpetab kõik selle konto kohta esitatud kaebused. actions_description_remote_html: Otsusta, mida teha selle raporti lahendamiseks. See mõjutab ainult seda, kuidas Sinu server selle kaugkontoga suhtleb ning selle sisu käsitleb. + actions_no_posts: Selle raportiga pole seotud ühtegi postitust, mida kustutada add_to_report: Lisa raportile juurde already_suspended_badges: local: Juba kustutamisel selles serveris @@ -769,6 +780,7 @@ et: destroyed_msg: Üleslaetud fail edukalt kustutatud! software_updates: critical_update: Kriitiline — uuenda kiiresti + description: Soovitatav on hoida oma Mastodoni paigaldus ajakohasena, et saada kasu viimastest parandustest ja funktsioonidest. Lisaks sellele on mõnikord oluline Mastodoni õigeaegne uuendamine, et vältida turvaprobleeme. Neil põhjustel kontrollib Mastodon uuendusi iga 30 minuti järel ja teavitab vastavalt sinu e-posti teavitamise eelistustele. documentation_link: Vaata lisa release_notes: Väljalaskemärkused title: Saadaval uuendused @@ -878,10 +890,16 @@ et: trends: allow: Luba approved: Kinnitatud + confirm_allow: Oled kindel, et soovid valitud sildid lubada? + confirm_disallow: Oled kindel, et soovid valitud sildid keelata? disallow: Keela links: allow: Luba viit allow_provider: Luba autor + confirm_allow: Oled kindel, et soovid valitud lingid lubada? + confirm_allow_provider: Oled kindel, et soovid valitud teenusepakkujad lubada? + confirm_disallow: Oled kindel, et soovid valitud lingid keelata? + confirm_disallow_provider: Oled kindel, et soovid valitud teenusepakkujad keelata? description_html: Need on lingid, mida jagavad praegu paljud kontod, mille postitusi server näeb. See võib aidata kasutajatel teada saada, mis maailmas toimub. Ühtegi linki ei kuvata avalikult enne, kui avaldaja on heakskiidetud. Samuti saab üksikuid linke lubada või tagasi lükata. disallow: Keela viit disallow_provider: Keela autor @@ -905,6 +923,10 @@ et: statuses: allow: Luba postitada allow_account: Luba autor + confirm_allow: Oled kindel, et soovid valitud olekud lubada? + confirm_allow_account: Oled kindel, et soovid valitud kontod lubada? + confirm_disallow: Oled kindel, et soovid valitud olekud lubada? + confirm_disallow_account: Oled kindel, et soovid valitud kontod keelata? description_html: Need on postitused, millest server teab ja mida praegu jagatakse ja mis on hetkel paljude lemmikud. See võib aidata uutel ja naasvatel kasutajatel leida rohkem inimesi, keda jälgida. Ühtegi postitust ei kuvata avalikult enne, kui autor on heaks kiidetud ja autor lubab oma kontot teistele soovitada. Samuti saab üksikuid postitusi lubada või tagasi lükata. disallow: Ära luba postitada disallow_account: Keela autor @@ -937,6 +959,7 @@ et: used_by_over_week: one: Kasutatud ühe kasutaja pool viimase nädala jooksul other: Kasutatud %{count} kasutaja poolt viimase nädala jooksul + title: Soovitused ja trendid trending: Trendid warning_presets: add_new: Lisa uus @@ -1021,7 +1044,9 @@ et: guide_link_text: Panustada võib igaüks! sensitive_content: Tundlik sisu application_mailer: + notification_preferences: Muuda e-posti eelistusi salutation: "%{name}!" + settings: 'Muuda e-posti eelistusi: %{link}' unsubscribe: Loobu tellimisest view: 'Vaade:' view_profile: Vaata profiili @@ -1030,10 +1055,10 @@ et: created: Rakenduse loomine õnnestus destroyed: Rakenduse kustutamine õnnestus logout: Logi välja - regenerate_token: Loo uus access token - token_regenerated: Access tokeni loomine õnnestus + regenerate_token: Loo uus ligipääsuvõti + token_regenerated: Ligipääsuvõtme loomine õnnestus warning: Ole nende andmetega ettevaatlikud. Ära jaga neid kellegagi! - your_token: Su juurdepääsutunnus + your_token: Su juurdepääsuvõti auth: apply_for_account: Konto taotluse esitamine captcha_confirmation: @@ -1041,6 +1066,7 @@ et: hint_html: Üks asi veel! Me peame veenduma, et oled inimene (et me saaksime spämmi väljaspoole jätta!). Lahenda allpool olev CAPTCHA ja klõpsa "Jätka". title: Turvalisuse kontroll confirmations: + awaiting_review: Sinu e-posti aadress on kinnitatud! %{domain} meeskond vaatab praegu sinu registreeringut läbi. Saad e-kirja, kui nad konto heaks kiidavad! awaiting_review_title: Su registreeringut vaadatakse läbi clicking_this_link: klõpsates seda linki login_link: logi sisse @@ -1048,6 +1074,7 @@ et: redirect_to_app_html: Sind oleks pidanud suunatama rakendusse %{app_name}. Kui seda ei juhtunud, proovi %{clicking_this_link} või naase käsitsi rakendusse. registration_complete: Sinu registreering domeenil %{domain} on nüüd valmis! welcome_title: Tere tulemast, %{name}! + wrong_email_hint: Kui see e-postiaadress pole korrektne, saad seda muuta konto seadetes. delete_account: Konto kustutamine delete_account_html: Kui soovid oma konto kustutada, siis jätka siit. Pead kustutamise eraldi kinnitama. description: @@ -1068,6 +1095,7 @@ et: or_log_in_with: Või logi sisse koos privacy_policy_agreement_html: Olen tutvunud isikuandmete kaitse põhimõtetega ja nõustun nendega progress: + confirm: E-posti kinnitamine details: Sinu üksikasjad review: Meie ülevaatamine rules: Nõustu reeglitega @@ -1089,8 +1117,10 @@ et: security: Turvalisus set_new_password: Uue salasõna määramine setup: + email_below_hint_html: Kontrolli rämpsposti kausta või taotle uut. Saad oma e-posti aadressi parandada, kui see on vale. email_settings_hint_html: Klõpsa linki, mis saadeti sulle, et kinnitada %{email}. Seni me ootame. link_not_received: Kas ei saanud linki? + new_confirmation_instructions_sent: Saad mõne minuti pärast uue kinnituslingiga e-kirja! title: Kontrolli sisendkasti sign_in: preamble_html: Logi sisse oma %{domain} volitustega. Kui konto asub teises serveris, ei saa siin sisse logida. @@ -1101,7 +1131,9 @@ et: title: Loo konto serverisse %{domain}. status: account_status: Konto olek + confirming: E-posti kinnitamise ootamine. functional: Konto on täies mahus kasutatav. + pending: Sinu taotlus ootab meie meeskonna läbivaatamist. See võib võtta aega. Kui taotlus on heaks kiidetud, saadetakse sulle e-kiri. redirecting_to: See konto pole aktiivne, sest on suunatud aadressile %{acct}. self_destruct: Kuna %{domain} on sulgemisel, saad oma kontole vaid piiratud ligipääsu. view_strikes: Vaata enda eelnevaid juhtumeid @@ -1144,6 +1176,9 @@ et: before: 'Veendu, et saad aru, mida toob plaanitav muudatus kaasa:' caches: Teiste serverite poolt talletatud sisu võib jääda kättesaadavaks data_removal: Sinu postitused ning kontoandmed kustutatakse jäädavalt + email_change_html: Saad muuta oma e-postiaadressi ilma oma kontot kustutamata + email_contact_html: Kui see ikkagi ei saabu, võid abi saamiseks kirjutada %{email} + email_reconfirmation_html: Kui sa ei saa kinnituskirja, saad taotleda seda uuesti irreversible: Kustutatud kontot ei saa taastada ega uuesti aktiveerida more_details_html: Konto kustutamise kohta loe täpsemalt isikuandmete kaitse põhimõtetest. username_available: Kasutajanimi muutub uuesti kasutatavaks @@ -1376,6 +1411,7 @@ et: authentication_methods: otp: kaheastmelise autentimise rakendus password: salasõna + sign_in_token: e-posti turvvakood webauthn: turvavõtmed description_html: Kui paistab tundmatuid tegevusi, tuleks vahetada salasõna ja aktiveerida kaheastmeline autentimine. empty: Autentimisajalugu pole saadaval @@ -1390,6 +1426,7 @@ et: media_attachments: validations: images_and_video: Ei saa lisada video postitusele, milles on juba pildid + not_found: Meedia %{ids} pole leitav või juba teisele postitusele lisatud not_ready: Ei saa lisada faile, mida hetkel töödeldakse. Proovi uuesti mõne hetke pärast! too_many: Ei saa lisada rohkem, kui 4 faili migrations: @@ -1466,6 +1503,8 @@ et: update: subject: "%{name} muutis postitust" notifications: + administration_emails: Admini e-postiteated + email_events: Sündmused e-postiteavituste jaoks email_events_hint: 'Vali sündmused, mille kohta soovid teavitusi:' number: human: @@ -1624,6 +1663,7 @@ et: import: Impordi import_and_export: Import / eksport migrate: Konto kolimine + notifications: E-postiteated preferences: Eelistused profile: Profiil relationships: Jälgitud ja jälgijad @@ -1872,6 +1912,7 @@ et: invalid_otp_token: Vale kaheastmeline võti otp_lost_help_html: Kui kaotasid ligipääsu mõlemale, saad võtta ühendust %{email}-iga rate_limited: Liiga palju autentimise katseid, proovi hiljem uuesti. + seamless_external_login: Oled sisse logitud välise teenuse kaudu. Nii pole salasõna ja e-posti seaded saadaval. signed_in_as: 'Sisse logitud kasutajana:' verification: extra_instructions_html: Soovitus: Sinu kodulehel olev link võib olla nähtamatu. Oluline osa on rel="me", mis väldib kasutaja loodud sisuga lehtedel libaisikustamist. Sa saad isegi kasutada lehe HEADER osas silti link sildi a asemel, kuid HTML peab olema kättesaadav ilma JavaScripti käivitamata. diff --git a/config/locales/fi.yml b/config/locales/fi.yml index 8f0c80f1df..0c5d5ef987 100644 --- a/config/locales/fi.yml +++ b/config/locales/fi.yml @@ -25,6 +25,8 @@ fi: admin: account_actions: action: Suorita toimi + already_silenced: Tätä tiliä on jo rajoitettu. + already_suspended: Tämä tili on jo jäädytetty. title: Suorita moderointitoimi käyttäjälle %{acct} account_moderation_notes: create: Jätä muistiinpano @@ -46,6 +48,7 @@ fi: title: Vaihda käyttäjän %{username} sähköposti-osoite change_role: changed_msg: Roolin vaihto onnistui! + edit_roles: Hallinnoi käyttäjien rooleja label: Vaihda rooli no_role: Ei roolia title: Vaihda käyttäjän %{username} rooli @@ -442,7 +445,7 @@ fi: create: Lisää verkkotunnus resolve: Selvitä verkkotunnus title: Estä uusi sähköpostiverkkotunnus - no_email_domain_block_selected: Sähköpostiverkkotunnusten estoja ei muutettu; yhtäkään ei ollut valittu + no_email_domain_block_selected: Sähköpostiverkkotunnusten estoja ei muutettu, koska yhtäkään ei ollut valittuna not_permitted: Ei sallittu resolved_dns_records_hint_html: Verkkotunnusnimi kytkeytyy seuraaviin MX-verkkotunnuksiin, jotka ovat viime kädessä vastuussa sähköpostin vastaanottamisesta. MX-verkkotunnuksen estäminen estää rekisteröitymisen mistä tahansa sähköpostiosoitteesta, joka käyttää samaa MX-verkkotunnusta, vaikka näkyvä verkkotunnuksen nimi olisikin erilainen. Varo estämästä suuria sähköpostipalvelujen tarjoajia. resolved_through_html: Ratkaistu verkkotunnuksen %{domain} kautta @@ -600,8 +603,9 @@ fi: resolve_description_html: Ilmoitettua tiliä kohtaan ei ryhdytä toimiin, varoitusta ei kirjata ja raportti suljetaan. silence_description_html: Tili näkyy vain niille, jotka jo seuraavat sitä tai etsivät sen manuaalisesti, mikä rajoittaa merkittävästi sen tavoitettavuutta. Voidaan perua milloin vain. Sulkee kaikki tiliin kohdistuvat raportit. suspend_description_html: Tili ja mikään sen sisältö eivät ole käytettävissä, ja lopulta ne poistetaan ja vuorovaikutus tilin kanssa on mahdotonta. Peruttavissa 30 päivän ajan. Sulkee kaikki tiliin kohdistuvat raportit. - actions_description_html: Päätä, mihin toimiin ryhdyt tämän raportin ratkaisemiseksi. Jos ryhdyt rangaistustoimeen ilmoitettua tiliä kohtaan, hänelle lähetetään sähköpostitse ilmoitus asiasta, paitsi jos valittuna on Roskaposti-luokka. + actions_description_html: Päätä, mihin toimiin ryhdyt tämän raportin ratkaisemiseksi. Jos ryhdyt rangaistustoimeen raportoitua tiliä kohtaan, hänelle lähetetään sähköpostitse ilmoitus asiasta, paitsi jos valittuna on Roskaposti-luokka. actions_description_remote_html: Päätä, mihin toimiin ryhdyt tämän raportin ratkaisemiseksi. Tämä vaikuttaa vain siihen, miten sinun palvelimesi viestii tämän etätilin kanssa ja käsittelee sen sisältöä. + actions_no_posts: Tähän raporttiin ei liity poistettavia julkaisuja add_to_report: Lisää raporttiin already_suspended_badges: local: Jäädytetty jo tällä palvelimella @@ -1135,7 +1139,7 @@ fi: security: Turvallisuus set_new_password: Aseta uusi salasana setup: - email_below_hint_html: Tarkista roskapostikansiosi tai pyydä uusi viesti. Voit myös korjata sähköpostiosoitteesi tarvittaessa. + email_below_hint_html: Tarkista roskapostikansiosi tai pyydä uusi viesti. Voit korjata sähköpostiosoitteesi tarvittaessa. email_settings_hint_html: Napsauta lähettämäämme linkkiä vahvistaaksesi osoitteen %{email}. Odotamme täällä. link_not_received: Etkö saanut linkkiä? new_confirmation_instructions_sent: Saat pian uuden vahvistuslinkin sisältävän sähköpostiviestin! @@ -1195,7 +1199,7 @@ fi: caches: Muiden palvelinten välimuistiinsa tallentamaa sisältöä voi säilyä data_removal: Julkaisusi ja muut tietosi poistetaan pysyvästi email_change_html: Voit muuttaa sähköpostiosoitettasi poistamatta tiliäsi - email_contact_html: Mikäli viesti ei vieläkään saavu perille, voit pyytää apua sähköpostitse osoitteella %{email} + email_contact_html: Jos viesti ei vieläkään saavu perille, voit pyytää apua sähköpostitse osoitteella %{email} email_reconfirmation_html: Jos et saa vahvistussähköpostiviestiä, voit pyytää sitä uudelleen irreversible: Et voi palauttaa tiliäsi etkä aktivoida sitä uudelleen more_details_html: Tarkempia tietoja saat tietosuojakäytännöstämme. diff --git a/config/locales/fo.yml b/config/locales/fo.yml index 0c3620ad42..040e312d78 100644 --- a/config/locales/fo.yml +++ b/config/locales/fo.yml @@ -25,6 +25,8 @@ fo: admin: account_actions: action: Frem atgerð + already_silenced: Hendan kontan er longu gjørd kvirr. + already_suspended: Hendan kontan er longu ógildað. title: Frem umsjónaratgerð á %{acct} account_moderation_notes: create: Skriva umsjónarviðmerking @@ -46,6 +48,7 @@ fo: title: Broyt teldupostin hjá %{username} change_role: changed_msg: Leiklutur broyttur! + edit_roles: Stýr brúkaraleiklutir label: Broyt leiklut no_role: Eingin leiklutur title: Broyt leiklut hjá %{username} @@ -602,6 +605,7 @@ fo: suspend_description_html: Kontan og alt innihald hjá kontuni gerast óatkomulig og við tíðini strikaði, og tað verður ógjørligt at samvirka við henni. Kann angrast innan 30 dagar. Lukkar allar rapporteringar av hesi kontuni. actions_description_html: Ger av hvør atgerð skal takast fyri at avgreiða hesa meldingina. Revsitiltøk móti meldaðu kontuni føra við sær, at ein teldupostfráboðan verður send teimum, undantikið tá Ruskpostur verður valdur. actions_description_remote_html: Tak avgerð um hvat skal gerast fyri at avgreiða hesa rapporteringina. Hetta fer einans at ávirka, hvussu tín ambætari samskiftir við hesa fjarkontuna og hvussu hann handfer tilfar frá henni. + actions_no_posts: Hendan fráboðanin hevur ongar viðkomandi postar at strika add_to_report: Legg meira afturat meldingini already_suspended_badges: local: Longu gjørt óvirkin á hesum ambætaranum diff --git a/config/locales/fr-CA.yml b/config/locales/fr-CA.yml index 140bc94344..dd1f73c459 100644 --- a/config/locales/fr-CA.yml +++ b/config/locales/fr-CA.yml @@ -25,6 +25,8 @@ fr-CA: admin: account_actions: action: Effectuer l'action + already_silenced: Ce compte est déjà limité. + already_suspended: Ce compte est déjà suspendu. title: Effectuer une action de modération sur %{acct} account_moderation_notes: create: Laisser une remarque @@ -46,6 +48,7 @@ fr-CA: title: Modifier le courriel pour %{username} change_role: changed_msg: Rôle modifié avec succès ! + edit_roles: Gérer les rôles d'utilisateur·ices label: Modifier le rôle no_role: Aucun rôle title: Modifier le rôle de %{username} @@ -188,9 +191,11 @@ fr-CA: create_user_role: Créer le rôle demote_user: Rétrograder l’utilisateur·ice destroy_announcement: Supprimer l’annonce + destroy_canonical_email_block: Supprimer le blocage de courriel destroy_custom_emoji: Supprimer des émojis personnalisés destroy_domain_allow: Supprimer le domaine autorisé destroy_domain_block: Supprimer le blocage de domaine + destroy_email_domain_block: Supprimer le blocage de domaine de courriel destroy_instance: Purge du domaine destroy_ip_block: Supprimer la règle IP destroy_status: Supprimer le message @@ -236,6 +241,7 @@ fr-CA: confirm_user_html: "%{name} a confirmé l'adresse e-mail de l'utilisateur %{target}" create_account_warning_html: "%{name} a envoyé un avertissement à %{target}" create_announcement_html: "%{name} a créé une nouvelle annonce %{target}" + create_canonical_email_block_html: "%{name} a bloqué l'adresse email avec le hachage %{target}" create_custom_emoji_html: "%{name} a téléversé un nouvel émoji %{target}" create_domain_allow_html: "%{name} a autorisé la fédération avec le domaine %{target}" create_domain_block_html: "%{name} a bloqué le domaine %{target}" @@ -245,6 +251,7 @@ fr-CA: create_user_role_html: "%{name} a créé le rôle %{target}" demote_user_html: "%{name} a rétrogradé l'utilisateur·rice %{target}" destroy_announcement_html: "%{name} a supprimé l'annonce %{target}" + destroy_canonical_email_block_html: "%{name} a débloqué l'adresse email avec le hachage %{target}" destroy_custom_emoji_html: "%{name} a supprimé l'émoji %{target}" destroy_domain_allow_html: "%{name} a rejeté la fédération avec le domaine %{target}" destroy_domain_block_html: "%{name} a débloqué le domaine %{target}" diff --git a/config/locales/fr.yml b/config/locales/fr.yml index 5646877d23..7e30b517a6 100644 --- a/config/locales/fr.yml +++ b/config/locales/fr.yml @@ -25,6 +25,8 @@ fr: admin: account_actions: action: Effectuer l'action + already_silenced: Ce compte est déjà limité. + already_suspended: Ce compte est déjà suspendu. title: Effectuer une action de modération sur %{acct} account_moderation_notes: create: Laisser une remarque @@ -46,6 +48,7 @@ fr: title: Modifier l’adresse de courriel pour %{username} change_role: changed_msg: Rôle modifié avec succès ! + edit_roles: Gérer les rôles d'utilisateur·ices label: Modifier le rôle no_role: Aucun rôle title: Modifier le rôle de %{username} @@ -188,9 +191,11 @@ fr: create_user_role: Créer le rôle demote_user: Rétrograder l’utilisateur·ice destroy_announcement: Supprimer l’annonce + destroy_canonical_email_block: Supprimer le blocage de courriel destroy_custom_emoji: Supprimer des émojis personnalisés destroy_domain_allow: Supprimer le domaine autorisé destroy_domain_block: Supprimer le blocage de domaine + destroy_email_domain_block: Supprimer le blocage de domaine de courriel destroy_instance: Purge du domaine destroy_ip_block: Supprimer la règle IP destroy_status: Supprimer le message @@ -236,6 +241,7 @@ fr: confirm_user_html: "%{name} a confirmé l'adresse e-mail de l'utilisateur %{target}" create_account_warning_html: "%{name} a envoyé un avertissement à %{target}" create_announcement_html: "%{name} a créé une nouvelle annonce %{target}" + create_canonical_email_block_html: "%{name} a bloqué l'adresse email avec le hachage %{target}" create_custom_emoji_html: "%{name} a téléversé un nouvel émoji %{target}" create_domain_allow_html: "%{name} a autorisé la fédération avec le domaine %{target}" create_domain_block_html: "%{name} a bloqué le domaine %{target}" @@ -245,6 +251,7 @@ fr: create_user_role_html: "%{name} a créé le rôle %{target}" demote_user_html: "%{name} a rétrogradé l'utilisateur·rice %{target}" destroy_announcement_html: "%{name} a supprimé l'annonce %{target}" + destroy_canonical_email_block_html: "%{name} a débloqué l'adresse email avec le hachage %{target}" destroy_custom_emoji_html: "%{name} a supprimé l'émoji %{target}" destroy_domain_allow_html: "%{name} a rejeté la fédération avec le domaine %{target}" destroy_domain_block_html: "%{name} a débloqué le domaine %{target}" diff --git a/config/locales/ga.yml b/config/locales/ga.yml index ad9ee21d3e..4ea9cef73d 100644 --- a/config/locales/ga.yml +++ b/config/locales/ga.yml @@ -31,6 +31,8 @@ ga: admin: account_actions: action: Déan gníomh + already_silenced: Tá an cuntas seo ina thost cheana féin. + already_suspended: Tá an cuntas seo curtha ar fionraí cheana féin. title: Dean gníomh modhnóireachta ar %{acct} account_moderation_notes: create: Fág nóta @@ -52,6 +54,7 @@ ga: title: Athraigh ríomhphost do %{username} change_role: changed_msg: Athraíodh ról go rathúil! + edit_roles: Bainistigh róil úsáideora label: Athraigh ról no_role: Gan ról title: Athraigh ról do %{username} @@ -638,6 +641,7 @@ ga: suspend_description_html: Beidh an cuntas agus a bhfuil ann go léir dorochtana agus scriosfar iad ar deireadh, agus beidh sé dodhéanta idirghníomhú leis. Inchúlaithe laistigh de 30 lá. Dúnann sé gach tuairisc i gcoinne an chuntais seo. actions_description_html: Déan cinneadh ar an ngníomh atá le déanamh chun an tuarascáil seo a réiteach. Má dhéanann tú beart pionósach in aghaidh an chuntais tuairiscithe, seolfar fógra ríomhphoist chucu, ach amháin nuair a roghnaítear an chatagóir Turscar. actions_description_remote_html: Déan cinneadh ar an ngníomh atá le déanamh chun an tuarascáil seo a réiteach. Ní bheidh tionchar aige seo ach ar an gcaoi a ndéanann do fhreastalaí cumarsáid leis an gcianchuntas seo agus a láimhseálann sé a ábhar. + actions_no_posts: Níl aon phostáil ghaolmhar ag an tuarascáil seo le scriosadh add_to_report: Cuir tuilleadh leis an tuairisc already_suspended_badges: local: Ar fionraí cheana féin ar an bhfreastalaí seo diff --git a/config/locales/gd.yml b/config/locales/gd.yml index 2af647ab9c..f824e30815 100644 --- a/config/locales/gd.yml +++ b/config/locales/gd.yml @@ -29,6 +29,8 @@ gd: admin: account_actions: action: Gabh an gnìomh + already_silenced: Chaidh an cunntas seo a chuingeachadh mu thràth. + already_suspended: Chaidh an cunntas seo a chur à rèim mu thràth. title: Gabh gnìomh maorsainneachd air %{acct} account_moderation_notes: create: Fàg nòta @@ -50,6 +52,7 @@ gd: title: Atharraich am post-d airson %{username} change_role: changed_msg: Chaidh an dreuchd atharrachadh! + edit_roles: Stiùirich dreuchdan nan cleachdaichean label: Atharraich an dreuchd no_role: Gun dreuchd title: Atharraich an dreuchd aig %{username} @@ -626,6 +629,7 @@ gd: suspend_description_html: Cha ghabh an cunntas seo agus an t-susbaint gu leòr aige inntrigeadh gus an dèid a sguabadh às air deireadh na sgeòil agus cha ghabh eadar-ghabhail a dhèanamh leis. Gabhaidh seo a neo-dhèanamh am broinn 30 latha. Dùinidh seo gach gearan mun chunntas seo. actions_description_html: Cuir romhad dè nì thu airson an gearan seo fhuasgladh. Ma chuireas tu peanas air a’ chunntas le gearan air, gheibh iad brath air a’ phost-d mura tagh thu an roinn-seòrsa Spama. actions_description_remote_html: Cuir romhad dè an gnìomh a ghabhas tu airson an gearan seo fhuasgladh. Cha bheir seo buaidh ach air mar a làimhsicheas am frithealaiche agadsa an cunntas cèin seo is mar a nì e conaltradh leis. + actions_no_posts: Chan eil post ri sguabadh às ris a’ ghearan seo add_to_report: Cuir barrachd ris a’ ghearan already_suspended_badges: local: Chaidh an cur à rèim air an fhrithealaiche seo mu thràth diff --git a/config/locales/gl.yml b/config/locales/gl.yml index 86010b0665..de4840dda1 100644 --- a/config/locales/gl.yml +++ b/config/locales/gl.yml @@ -25,6 +25,8 @@ gl: admin: account_actions: action: Executar acción + already_silenced: Esta conta xa está silenciada. + already_suspended: Esta conta xa está suspendida. title: Executar acción de moderación a %{acct} account_moderation_notes: create: Deixar nota @@ -46,6 +48,7 @@ gl: title: Mudar email de %{username} change_role: changed_msg: Rol mudado correctamente! + edit_roles: Xestionar roles de usuarias label: Cambiar rol no_role: Sen rol title: Cambiar o rol de %{username} @@ -602,6 +605,7 @@ gl: suspend_description_html: A conta e todo o seu contido non serán accesible e finalmente eliminaranse, será imposible interactuar con ela. A decisión é reversible durante 30 días. Isto pecha tódalas denuncias sobre esta conta. actions_description_html: Decide a acción a tomar para resolver esta denuncia. Se tomas accións punitivas contra a conta denunciada enviaraselle un correo, excepto se está indicada a categoría Spam. actions_description_remote_html: Decide a acción a tomar para resolver a denuncia. Isto só lle afecta ao xeito en que o teu servidor se comunica con esta conta remota e xestiona o seu contido. + actions_no_posts: Esta denuncia non ten publicacións asociadas para eliminar add_to_report: Engadir máis á denuncia already_suspended_badges: local: Xa está suspendida neste servidor diff --git a/config/locales/hu.yml b/config/locales/hu.yml index 2bf138d9be..60fb96a121 100644 --- a/config/locales/hu.yml +++ b/config/locales/hu.yml @@ -25,6 +25,8 @@ hu: admin: account_actions: action: Művelet végrehajtása + already_silenced: Ezt a fiókot már elnémították. + already_suspended: Ezt a fiókot már felfüggesztették. title: 'Moderálási művelet végrehajtása ezen: %{acct}' account_moderation_notes: create: Megjegyzés hagyása @@ -46,6 +48,7 @@ hu: title: "%{username} e-mail-címének megváltoztatása" change_role: changed_msg: A szerep sikeresen megváltoztatva! + edit_roles: Felhasználói szerepkörök kezelése label: Szerep megváltoztatása no_role: Nincs szerep title: "%{username} szerepének megváltoztatása" @@ -602,6 +605,7 @@ hu: suspend_description_html: A fiók és minden tartalma elérhetetlenné válik és végül törlésre kerül. A fiókkal kapcsolatbalépni lehetetlen lesz. Ez a művelet 30 napig visszafordítható. A fiók ellen indított minden bejelentést lezárunk. actions_description_html: Döntsd el, mit csináljunk, hogy megoldjuk ezt a bejelentést. Ha valamilyen büntető intézkedést hozol a bejelentett fiók ellen, küldünk neki egy figyelmeztetést e-mailben, kivéve ha a Spam kategóriát választod. actions_description_remote_html: Döntsd el, mit tegyünk a bejelentés lezárásának érdekében. Ez csak azt befolyásolja, hogy a saját kiszolgálód hogyan kommunikál ezzel a távoli fiókkal és hogyan kezeli annak tartalmait. + actions_no_posts: Ennek a bejelentésnek nincs egyetlen törölhető, társított bejegyzése sem add_to_report: Továbbiak hozzáadása a bejelentéshez already_suspended_badges: local: Már felfüggesztették ezen a szerveren diff --git a/config/locales/ia.yml b/config/locales/ia.yml index 5596aacf2d..683edbe7cb 100644 --- a/config/locales/ia.yml +++ b/config/locales/ia.yml @@ -25,6 +25,8 @@ ia: admin: account_actions: action: Exequer action + already_silenced: Iste conto jam ha essite silentiate. + already_suspended: Iste conto jam ha essite suspendite. title: Exequer action de moderation sur %{acct} account_moderation_notes: create: Lassar un nota @@ -46,6 +48,7 @@ ia: title: Cambiar e-mail pro %{username} change_role: changed_msg: Rolo cambiate con successo! + edit_roles: Gerer le regulas de usator label: Cambiar rolo no_role: Necun rolo title: Cambiar rolo pro %{username} @@ -964,6 +967,7 @@ ia: used_by_over_week: one: Usate per un persona in le ultime septimana other: Usate per %{count} personas in le ultime septimana + title: Recommendationes e tendentias trending: In tendentia warning_presets: add_new: Adder nove diff --git a/config/locales/is.yml b/config/locales/is.yml index 2c73dbae74..0854d88123 100644 --- a/config/locales/is.yml +++ b/config/locales/is.yml @@ -25,6 +25,8 @@ is: admin: account_actions: action: Framkvæma aðgerð + already_silenced: Þessi aðgangur hefur þegar verið þaggaður. + already_suspended: Þessi aðgangur hefur þegar verið settur í frysti. title: Framkvæma umsjónaraðgerð á %{acct} account_moderation_notes: create: Skilja eftir minnispunkt @@ -46,6 +48,7 @@ is: title: Breyta tölvupóstfangi fyrir %{username} change_role: changed_msg: Tókst að breyta hlutverki! + edit_roles: Sýsla með hlutverk notenda label: Breyta hlutverki no_role: Ekkert hlutverk title: Breyta hlutverki fyrir %{username} @@ -602,6 +605,7 @@ is: suspend_description_html: Notandaaðgangurinn og allt efni á honum mun verða óaðgengilegt og á endanum eytt út og samskipti við aðganginn verða ekki möguleg. Hægt að afturkalla innan 30 daga. Lokar öllum kærum gagnvart þessum aðgangi. actions_description_html: Ákveddu til hvaða aðgerða eigi að taka til að leysa þessa kæru. Ef þú ákveður að refsa kærða notandaaðgangnum, verður viðkomandi send tilkynning í tölvupósti, nema ef flokkurinn Ruslpóstur sé valinn. actions_description_remote_html: Ákveddu til hvaða aðgerða eigi að taka til að leysa þessa kæru. Þetta mun aðeins hafa áhrif á hvernig netþjónninn þinn meðhöndlar þennan fjartengda aðgang og efnið á honum. + actions_no_posts: Þessi kæra er ekki með neinar tengdar færslur til að eyða add_to_report: Bæta fleiru í kæru already_suspended_badges: local: Þegar frystur á þessum netþjóni diff --git a/config/locales/it.yml b/config/locales/it.yml index 54e122fd75..66a462e61f 100644 --- a/config/locales/it.yml +++ b/config/locales/it.yml @@ -25,6 +25,8 @@ it: admin: account_actions: action: Esegui azione + already_silenced: Questo account è già stato silenziato. + already_suspended: Questo account è già stato sospeso. title: Esegui l'azione di moderazione su %{acct} account_moderation_notes: create: Lascia una nota @@ -46,6 +48,7 @@ it: title: Cambia l'email per %{username} change_role: changed_msg: Ruolo modificato correttamente! + edit_roles: Gestisci i ruoli utente label: Cambia il ruolo no_role: Nessun ruolo title: Cambia il ruolo per %{username} @@ -602,6 +605,7 @@ it: suspend_description_html: L'account e tutti i suoi contenuti saranno inaccessibili ed eventualmente cancellati, e interagire con esso sarà impossibile. Reversibile entro 30 giorni. Chiude tutte le segnalazioni contro questo account. actions_description_html: Decidi quale azione intraprendere per risolvere questa segnalazione. Se intraprendi un'azione punitiva nei confronti dell'account segnalato, gli verrà inviata una notifica via e-mail, tranne quando è selezionata la categoria Spam. actions_description_remote_html: Decide quali azioni intraprendere per risolvere la relazione. Questo influenzerà solo come il tuo server comunica con questo account remoto e ne gestisce il contenuto. + actions_no_posts: Questa segnalazione non ha alcun post associato da eliminare add_to_report: Aggiungi altro al report already_suspended_badges: local: Già sospeso su questo server diff --git a/config/locales/ja.yml b/config/locales/ja.yml index b54707c7cc..af9173cfc4 100644 --- a/config/locales/ja.yml +++ b/config/locales/ja.yml @@ -1428,6 +1428,7 @@ ja: media_attachments: validations: images_and_video: 既に画像が追加されているため、動画を追加することはできません + not_found: メディア (%{ids}) が存在しないか、すでに添付して投稿されています not_ready: ファイルのアップロードに失敗しました。しばらくしてからもう一度お試しください! too_many: 追加できるファイルは4つまでです migrations: diff --git a/config/locales/ko.yml b/config/locales/ko.yml index ef3775d4df..9bec26c450 100644 --- a/config/locales/ko.yml +++ b/config/locales/ko.yml @@ -23,6 +23,8 @@ ko: admin: account_actions: action: 조치 취하기 + already_silenced: 이 계정은 이미 침묵되었습니다. + already_suspended: 이 계정은 이미 정지되었습니다. title: "%{acct} 계정에 중재 취하기" account_moderation_notes: create: 참고사항 남기기 @@ -44,6 +46,7 @@ ko: title: "%{username}의 이메일 바꾸기" change_role: changed_msg: 역할이 성공적으로 변경되었습니다! + edit_roles: 사용자 역할 관리 label: 역할 변경 no_role: 역할 없음 title: "%{username}의 역할 변경" @@ -592,6 +595,7 @@ ko: suspend_description_html: 이 계정과 이 계정의 콘텐츠들은 접근 불가능해지고 삭제될 것이며, 상호작용은 불가능해집니다. 30일 이내에 되돌릴 수 있습니다. 이 계정에 대한 모든 신고를 닫습니다. actions_description_html: 이 신고를 해결하기 위해 취해야 할 조치를 지정해주세요. 신고된 계정에 대해 처벌 조치를 취하면, 스팸 카테고리가 선택된 경우를 제외하고 해당 계정으로 이메일 알림이 전송됩니다. actions_description_remote_html: 이 신고를 해결하기 위해 실행할 행동을 결정하세요. 이 결정은 이 원격 계정과 그 콘텐츠를 다루는 방식에 대해 이 서버에서만 영향을 끼칩니다 + actions_no_posts: 이 신고는 삭제할 관련 게시물이 없습니다 add_to_report: 신고에 더 추가하기 already_suspended_badges: local: 이 서버에서 이미 정지되었습니다 diff --git a/config/locales/lad.yml b/config/locales/lad.yml index 0de73fd279..5d60e6e9a1 100644 --- a/config/locales/lad.yml +++ b/config/locales/lad.yml @@ -25,6 +25,7 @@ lad: admin: account_actions: action: Realiza aksion + already_suspended: Este kuento ya tiene sido suspendido. title: Modera %{acct} account_moderation_notes: create: Kriya nota diff --git a/config/locales/lt.yml b/config/locales/lt.yml index 8c3b8e2e73..0fd71f52ed 100644 --- a/config/locales/lt.yml +++ b/config/locales/lt.yml @@ -1036,7 +1036,7 @@ lt: generic: Nežinoma naršyklė current_session: Dabartinis seansas date: Data - description: "%{browser} ant %{platform}" + description: "„%{browser}“ per „%{platform}“" explanation: Čia rodomos web naršyklės prijungtos prie Jūsų Mastodon paskyros. ip: IP platforms: @@ -1116,6 +1116,7 @@ lt: unlisted_long: matyti gali visi, bet nėra išvardyti į viešąsias laiko skales statuses_cleanup: enabled_hint: Automatiškai ištrina įrašus, kai jie pasiekia nustatytą amžiaus ribą, nebent jie atitinka vieną iš toliau nurodytų išimčių + interaction_exceptions_explanation: Atkreipk dėmesį, kad negarantuojama, jog įrašai nebus ištrinti, jei jų mėgstamumo ar pasidalinimo riba bus žemesnė, nors vieną kartą ji jau buvo viršyta. keep_polls_hint: Neištrina jokių tavo apklausų keep_self_bookmark: Laikyti įrašus, kuriuos pažymėjai keep_self_bookmark_hint: Neištrina tavo pačių įrašų, jei esi juos pažymėjęs (-usi) diff --git a/config/locales/nl.yml b/config/locales/nl.yml index 46ed411776..725d3915c2 100644 --- a/config/locales/nl.yml +++ b/config/locales/nl.yml @@ -25,6 +25,8 @@ nl: admin: account_actions: action: Actie uitvoeren + already_silenced: Dit account is al beperkt. + already_suspended: Dit account is al geschorst. title: Moderatiemaatregel tegen %{acct} nemen account_moderation_notes: create: Laat een opmerking achter @@ -46,6 +48,7 @@ nl: title: E-mailadres wijzigen voor %{username} change_role: changed_msg: Rol succesvol veranderd! + edit_roles: Gebruikersrollen beheren label: Rol veranderen no_role: Geen rol title: Rol van %{username} veranderen @@ -602,6 +605,7 @@ nl: suspend_description_html: Het account en de inhoud hiervan is niet meer toegankelijk, en het is ook niet meer mogelijk om ermee interactie te hebben. Uiteindelijk wordt het account volledig verwijderd. Dit is omkeerbaar binnen 30 dagen. Dit sluit alle rapporten tegen dit account af. actions_description_html: Beslis welke maatregel moet worden genomen om deze rapportage op te lossen. Wanneer je een (straf)maatregel tegen het gerapporteerde account neemt, krijgt het account een e-mailmelding, behalve wanneer de spam-categorie is gekozen. actions_description_remote_html: Beslis welke actie moet worden ondernomen om deze rapportage op te lossen. Dit is alleen van invloed op hoe jouw server met dit externe account communiceert en de inhoud ervan beheert. + actions_no_posts: Dit rapport heeft geen bijbehorende berichten om te verwijderen add_to_report: Meer aan de rapportage toevoegen already_suspended_badges: local: Al geschorst op deze server diff --git a/config/locales/pl.yml b/config/locales/pl.yml index 95746bd10b..2a1a0c8d75 100644 --- a/config/locales/pl.yml +++ b/config/locales/pl.yml @@ -29,6 +29,8 @@ pl: admin: account_actions: action: Wykonaj działanie + already_silenced: To konto zostało już wyciszone. + already_suspended: To konto zostało już zawieszone. title: Wykonaj działanie moderacyjne na %{acct} account_moderation_notes: create: Pozostaw notatkę @@ -50,6 +52,7 @@ pl: title: Zmień adres e-mail dla %{username} change_role: changed_msg: Pomyślnie zmieniono rolę! + edit_roles: Zarządzaj rolami użytkowników label: Zmień rolę no_role: Brak roli title: Zmień rolę dla %{username} @@ -626,6 +629,7 @@ pl: suspend_description_html: Konto i cała jego zawartość będą niedostępne i ostatecznie usunięte, a interakcja z nim będzie niemożliwa. Możliwość odwrócenia w ciągu 30 dni. Zamyka wszelkie zgłoszenia dotyczące tego konta. actions_description_html: Zdecyduj, jakie działania należy podjąć, aby rozstrzygnąć niniejsze zgłoszenie. Jeśli podejmiesz działania karne przeciwko zgłoszonemu kontowi, zostanie do nich wysłane powiadomienie e-mail, chyba że wybrano kategorię Spam. actions_description_remote_html: Zdecyduj, jakie działanie należy podjąć, aby rozwiązać to zgłoszenie. Będzie to miało wpływ jedynie na sposób, w jaki Twój serwer komunikuje się z tym kontem zdalnym i obsługuje jego zawartość. + actions_no_posts: Ten raport nie ma żadnych powiązanych wpisów do usunięcia add_to_report: Dodaj więcej do zgłoszenia already_suspended_badges: local: Już zawieszono na tym serwerze diff --git a/config/locales/simple_form.an.yml b/config/locales/simple_form.an.yml index 7119aadba2..c59391f552 100644 --- a/config/locales/simple_form.an.yml +++ b/config/locales/simple_form.an.yml @@ -108,7 +108,6 @@ an: name: Nomás se puede cambiar lo cajón d'as letras, per eixemplo, pa que sía mas leyible user: chosen_languages: Quan se marca, nomás s'amostrarán las publicacions en os idiomas triaus en as linias de tiempo publicas - role: Lo rol controla qué permisos tiene la usuaria user_role: color: Color que s'utilizará pa lo rol a lo largo d'a interficie d'usuario, como RGB en formato hexadecimal highlighted: Esto fa que lo rol sía publicament visible diff --git a/config/locales/simple_form.ar.yml b/config/locales/simple_form.ar.yml index 81be19a44e..0a665fb784 100644 --- a/config/locales/simple_form.ar.yml +++ b/config/locales/simple_form.ar.yml @@ -130,7 +130,6 @@ ar: name: يمكنك فقط تغيير غلاف الحروف ، على سبيل المثال ، لجعلها أكثر قابلية للقراءة user: chosen_languages: إن تم اختيارها، فلن تظهر على الخيوط العامة إلّا الرسائل المنشورة في تلك اللغات - role: الوظيفة تتحكم في الصلاحيات التي يملكها المستخدم user_role: color: اللون الذي سيتم استخدامه للوظيفه في جميع وحدات واجهة المستخدم، كـ RGB بتنسيق hex highlighted: وهذا يجعل الوظيفه مرئيا علنا diff --git a/config/locales/simple_form.be.yml b/config/locales/simple_form.be.yml index a50db22987..db6a94f8eb 100644 --- a/config/locales/simple_form.be.yml +++ b/config/locales/simple_form.be.yml @@ -130,7 +130,6 @@ be: name: Вы можаце змяняць толькі рэгістр літар, напрыклад для таго, каб падвысіць чытабельнасць user: chosen_languages: У публічных стужках будуць паказвацца допісы толькі на тых мовах, якія вы пазначыце - role: Гэтая роля кантралюе дазволы, якія мае карыстальнік user_role: color: Колер, які будзе выкарыстоўвацца для гэтай ролі па ўсім UI, у фармаце RGB ці hex highlighted: Гэта робіць ролю публічна бачнай diff --git a/config/locales/simple_form.bg.yml b/config/locales/simple_form.bg.yml index 333ab25c82..a2cf8e4222 100644 --- a/config/locales/simple_form.bg.yml +++ b/config/locales/simple_form.bg.yml @@ -130,7 +130,6 @@ bg: name: Можете да смените само употребата на големи/малки букви, например, за да е по-четимо user: chosen_languages: Само публикации на отметнатите езици ще се показват в публичните часови оси - role: Ролите управляват какви права има потребителят user_role: color: Цветът, използван за ролите в потребителския интерфейс, като RGB в шестнадесетичен формат highlighted: Това прави ролята обществено видима diff --git a/config/locales/simple_form.ca.yml b/config/locales/simple_form.ca.yml index 4daf657234..c628bebaad 100644 --- a/config/locales/simple_form.ca.yml +++ b/config/locales/simple_form.ca.yml @@ -130,7 +130,7 @@ ca: name: Només pots canviar la caixa de les lletres, per exemple, per fer-la més llegible user: chosen_languages: Quan estigui marcat, només es mostraran els tuts de les llengües seleccionades en les línies de temps públiques - role: El rol controla quines permissions té l'usuari + role: El rol controla quins permisos té l'usuari. user_role: color: Color que s'usarà per al rol a tota la interfície d'usuari, com a RGB en format hexadecimal highlighted: Això fa el rol visible públicament diff --git a/config/locales/simple_form.cs.yml b/config/locales/simple_form.cs.yml index 2fe08e698a..6242b1ca6e 100644 --- a/config/locales/simple_form.cs.yml +++ b/config/locales/simple_form.cs.yml @@ -130,7 +130,6 @@ cs: name: Můžete měnit pouze velikost písmen, například kvůli lepší čitelnosti user: chosen_languages: Po zaškrtnutí budou ve veřejných časových osách zobrazeny pouze příspěvky ve zvolených jazycích - role: Role určuje, která oprávnění má uživatel user_role: color: Barva, která má být použita pro roli v celém UI, jako RGB v hex formátu highlighted: Toto roli učiní veřejně viditelnou diff --git a/config/locales/simple_form.cy.yml b/config/locales/simple_form.cy.yml index 22545a776a..56586ecc96 100644 --- a/config/locales/simple_form.cy.yml +++ b/config/locales/simple_form.cy.yml @@ -130,7 +130,7 @@ cy: name: Dim ond er mwyn ei gwneud yn fwy darllenadwy y gallwch chi newid y llythrennau, er enghraifft user: chosen_languages: Wedi eu dewis, dim ond tŵtiau yn yr ieithoedd hyn bydd yn cael eu harddangos mewn ffrydiau cyhoeddus - role: Mae'r rôl yn rheoli pa ganiatâd sydd gan y defnyddiwr + role: Mae'r rôl yn rheoli pa ganiatâd sydd gan y defnyddiwr. user_role: color: Lliw i'w ddefnyddio ar gyfer y rôl drwy'r UI, fel RGB mewn fformat hecs highlighted: Mae hyn yn gwneud y rôl yn weladwy i'r cyhoedd diff --git a/config/locales/simple_form.da.yml b/config/locales/simple_form.da.yml index 5763885ac4..8bacdc46c3 100644 --- a/config/locales/simple_form.da.yml +++ b/config/locales/simple_form.da.yml @@ -130,7 +130,7 @@ da: name: Kun bogstavtyper (store/små) kan ændres, eksempelvis for at gøre det mere læsbart user: chosen_languages: Når markeret, vil kun indlæg på de valgte sprog fremgå på offentlige tidslinjer - role: Rollen styrer, hvilke tilladelser brugeren har + role: Rollen styrer, hvilke tilladelser brugeren er tildelt. user_role: color: Farven, i RGB hex-format, der skal bruges til rollen i hele UI'en highlighted: Dette gør rollen offentligt synlig diff --git a/config/locales/simple_form.de.yml b/config/locales/simple_form.de.yml index fb7bda9489..ddb6621aa6 100644 --- a/config/locales/simple_form.de.yml +++ b/config/locales/simple_form.de.yml @@ -130,7 +130,7 @@ de: name: Du kannst nur die Groß- und Kleinschreibung der Buchstaben ändern, um es z. B. lesbarer zu machen user: chosen_languages: Wenn du hier eine oder mehrere Sprachen auswählst, werden ausschließlich Beiträge in diesen Sprachen in deinen öffentlichen Timelines angezeigt - role: Die Rolle legt fest, welche Berechtigungen das Konto hat + role: Die Rolle bestimmt, welche Berechtigungen das Konto hat. user_role: color: Farbe, die für diese Rolle in der gesamten Benutzerschnittstelle verwendet wird, als RGB im Hexadezimalsystem highlighted: Dies macht die Rolle öffentlich im Profil sichtbar diff --git a/config/locales/simple_form.el.yml b/config/locales/simple_form.el.yml index af93f65fec..88c1c0e184 100644 --- a/config/locales/simple_form.el.yml +++ b/config/locales/simple_form.el.yml @@ -111,7 +111,6 @@ el: name: Μπορείς να αλλάξεις μόνο το πλαίσιο των χαρακτήρων, για παράδειγμα για να γίνει περισσότερο ευανάγνωστο user: chosen_languages: Όταν ενεργοποιηθεί, στη δημόσια ροή θα εμφανίζονται τουτ μόνο από τις επιλεγμένες γλώσσες - role: Ο ρόλος ελέγχει ποια δικαιώματα έχει ο χρήστης user_role: color: Το χρώμα που θα χρησιμοποιηθεί για το ρόλο σε ολόκληρη τη διεπαφή, ως RGB σε δεκαεξαδική μορφή highlighted: Αυτό καθιστά το ρόλο δημόσια ορατό diff --git a/config/locales/simple_form.en-GB.yml b/config/locales/simple_form.en-GB.yml index 2f40feb5ed..18776d67d6 100644 --- a/config/locales/simple_form.en-GB.yml +++ b/config/locales/simple_form.en-GB.yml @@ -130,7 +130,6 @@ en-GB: name: You can only change the casing of the letters, for example, to make it more readable user: chosen_languages: When checked, only posts in selected languages will be displayed in public timelines - role: The role controls which permissions the user has user_role: color: Color to be used for the role throughout the UI, as RGB in hex format highlighted: This makes the role publicly visible diff --git a/config/locales/simple_form.eo.yml b/config/locales/simple_form.eo.yml index 3b51c15908..053816ef88 100644 --- a/config/locales/simple_form.eo.yml +++ b/config/locales/simple_form.eo.yml @@ -122,7 +122,6 @@ eo: name: Vi povas ŝanĝi nur la majuskladon de la literoj, ekzemple, por igi ĝin pli legebla user: chosen_languages: Kun tio markita nur mesaĝoj en elektitaj lingvoj aperos en publikaj tempolinioj - role: La rolregiloj kies permesojn la uzanto havas user_role: color: Koloro uzita por la rolo sur la UI, kun RGB-formato highlighted: Ĉi tio igi la rolon publike videbla diff --git a/config/locales/simple_form.es-AR.yml b/config/locales/simple_form.es-AR.yml index e26af5b0c6..70573c75f4 100644 --- a/config/locales/simple_form.es-AR.yml +++ b/config/locales/simple_form.es-AR.yml @@ -130,7 +130,7 @@ es-AR: name: Sólo podés cambiar la capitalización de las letras, por ejemplo, para que sea más legible user: chosen_languages: Cuando estén marcados, sólo se mostrarán los mensajes en los idiomas seleccionados en las líneas temporales públicas - role: El rol controla qué permisos tiene el usuario + role: El rol controla qué permisos tiene el usuario. user_role: color: Color que se utilizará para el rol a lo largo de la interface de usuario, como RGB en formato hexadecimal highlighted: Esto hace que el rol sea públicamente visible diff --git a/config/locales/simple_form.es-MX.yml b/config/locales/simple_form.es-MX.yml index 733a5c2769..ff66bcb59e 100644 --- a/config/locales/simple_form.es-MX.yml +++ b/config/locales/simple_form.es-MX.yml @@ -130,7 +130,6 @@ es-MX: name: Sólo se puede cambiar el cajón de las letras, por ejemplo, para que sea más legible user: chosen_languages: Cuando se marca, solo se mostrarán los toots en los idiomas seleccionados en los timelines públicos - role: El rol controla qué permisos tiene el usuario user_role: color: Color que se utilizará para el rol a lo largo de la interfaz de usuario, como RGB en formato hexadecimal highlighted: Esto hace que el rol sea públicamente visible diff --git a/config/locales/simple_form.es.yml b/config/locales/simple_form.es.yml index 02f0562d28..143c5d8075 100644 --- a/config/locales/simple_form.es.yml +++ b/config/locales/simple_form.es.yml @@ -130,7 +130,6 @@ es: name: Sólo se puede cambiar el cajón de las letras, por ejemplo, para que sea más legible user: chosen_languages: Cuando se marca, solo se mostrarán las publicaciones en los idiomas seleccionados en las líneas de tiempo públicas - role: El rol controla qué permisos tiene el usuario user_role: color: Color que se utilizará para el rol a lo largo de la interfaz de usuario, como RGB en formato hexadecimal highlighted: Esto hace que el rol sea públicamente visible diff --git a/config/locales/simple_form.et.yml b/config/locales/simple_form.et.yml index 9fd9e238aa..4a9245682d 100644 --- a/config/locales/simple_form.et.yml +++ b/config/locales/simple_form.et.yml @@ -130,7 +130,7 @@ et: name: Saad muuta ainult tähtede suurtähelisust, näiteks selleks, et muuta seda loetavamaks user: chosen_languages: Keelte valimisel näidatakse avalikel ajajoontel ainult neis keeltes postitusi - role: See roll kontrollib, millised õigused kasutajal on + role: Rollid määravad, millised õigused kasutajal on. user_role: color: Rolli tähistamise värvus üle kasutajaliidese, RGB 16nd-formaadis highlighted: Teeb rolli avalikult nähtavaks diff --git a/config/locales/simple_form.eu.yml b/config/locales/simple_form.eu.yml index c7e2667cad..7647e187ec 100644 --- a/config/locales/simple_form.eu.yml +++ b/config/locales/simple_form.eu.yml @@ -130,7 +130,6 @@ eu: name: Letrak maiuskula/minuskulara aldatu ditzakezu besterik ez, adibidez irakurterrazago egiteko user: chosen_languages: Markatzean, hautatutako hizkuntzetan dauden tutak besterik ez dira erakutsiko. - role: Rolak erabiltzaileak dituen baimenak kontrolatzen ditu user_role: color: Rolarentzat erabiltzaile interfazean erabiliko den kolorea, formatu hamaseitarreko RGB bezala highlighted: Honek rola publikoki ikusgai jartzen du diff --git a/config/locales/simple_form.fa.yml b/config/locales/simple_form.fa.yml index 0610f7fced..bbb0523b17 100644 --- a/config/locales/simple_form.fa.yml +++ b/config/locales/simple_form.fa.yml @@ -188,6 +188,7 @@ fa: setting_default_privacy: حریم خصوصی نوشته‌ها setting_default_sensitive: همیشه تصاویر را به عنوان حساس علامت بزن setting_delete_modal: نمایش پیغام تأیید پیش از پاک کردن یک نوشته + setting_disable_hover_cards: از کار انداختن پیش‌نمایش نمایه هنگام رفتن رویش setting_disable_swiping: از کار انداختن حرکت‌های کشیدنی setting_display_media: نمایش عکس و ویدیو setting_display_media_default: پیش‌فرض @@ -219,6 +220,7 @@ fa: warn: نهفتن با هشدار form_admin_settings: activity_api_enabled: انتشار آمار تجمیعی دربارهٔ فعالیت کاربران در API + app_icon: نقشک کاره backups_retention_period: دورهٔ نگه‌داری بایگانی کاربری bootstrap_timeline_accounts: پیشنهاد همیشگی این حساب‌ها به کاربران جدید closed_registrations_message: پیام سفارشی هنگام در دسترس نبودن ثبت‌نام‌ها @@ -278,6 +280,7 @@ fa: patch: آگاهی برای به‌روز رسانی‌های رفع اشکال trending_tag: روند جدیدی نیازمند بازبینی است rule: + hint: اطّلاعات اضافی text: قانون settings: indexable: بودن صفحهٔ نمایه در نتیجه‌های جست‌وجو @@ -286,6 +289,7 @@ fa: listable: اجازه به این برچسب برای ظاهر شدن در جست‌وجوها و پیشنهادها name: برچسب trendable: بگذارید که این برچسب در موضوعات پرطرفدار دیده شود + usable: اجازه به فرسته‌ها برای استفتاده از این برچسب به صورت محلی user: role: نقش time_zone: منطقهٔ زمانی diff --git a/config/locales/simple_form.fi.yml b/config/locales/simple_form.fi.yml index c20ff9fa5f..d3f0628631 100644 --- a/config/locales/simple_form.fi.yml +++ b/config/locales/simple_form.fi.yml @@ -130,7 +130,7 @@ fi: name: Voit esimerkiksi vaihtaa suur- ja pienaakkosten kesken helppolukuistaaksesi tekstiäsi user: chosen_languages: Jos valitset kieliä oheisesta luettelosta, vain niidenkieliset julkaisut näkyvät sinulle julkisilla aikajanoilla - role: Rooli vaikuttaa käyttäjän käyttöoikeuksiin + role: Rooli määrää, millaiset käyttöoikeudet käyttäjällä on. user_role: color: Väri, jota käytetään roolille kaikkialla käyttöliittymässä, RGB-heksadesimaalimuodossa highlighted: Tämä tekee roolista julkisesti näkyvän diff --git a/config/locales/simple_form.fo.yml b/config/locales/simple_form.fo.yml index ecd8402680..35e42f6c74 100644 --- a/config/locales/simple_form.fo.yml +++ b/config/locales/simple_form.fo.yml @@ -130,7 +130,7 @@ fo: name: Tú kanst einans broyta millum stórar og smáar stavir, til dømis fyri at gera tað meira lesiligt user: chosen_languages: Tá hetta er valt, verða einans postar í valdum málum vístir á almennum tíðarlinjum - role: Leikluturin stýrir, hvørji loyvir brúkarin hevur + role: Leikluturin stýrir hvørji rættindi, brúkarin hevur. user_role: color: Litur, sum leikluturin hevur í øllum brúkaramarkamótinum, sum RGB og upplýst sum sekstandatal highlighted: Hetta ger, at leikluturin er alment sjónligur diff --git a/config/locales/simple_form.fr-CA.yml b/config/locales/simple_form.fr-CA.yml index 640d7e344a..1128335f11 100644 --- a/config/locales/simple_form.fr-CA.yml +++ b/config/locales/simple_form.fr-CA.yml @@ -128,7 +128,7 @@ fr-CA: name: Vous ne pouvez modifier que la casse des lettres, par exemple, pour le rendre plus lisible user: chosen_languages: Lorsque coché, seuls les messages dans les langues sélectionnées seront affichés sur les fils publics - role: Le rôle définit quelles autorisations a l'utilisateur⋅rice + role: Le rôle définit quelles autorisations a l'utilisateur⋅rice. user_role: color: Couleur à attribuer au rôle dans l'interface, au format hexadécimal RVB highlighted: Cela rend le rôle visible publiquement diff --git a/config/locales/simple_form.fr.yml b/config/locales/simple_form.fr.yml index 04d48573a3..c064532984 100644 --- a/config/locales/simple_form.fr.yml +++ b/config/locales/simple_form.fr.yml @@ -128,7 +128,7 @@ fr: name: Vous ne pouvez modifier que la casse des lettres, par exemple, pour le rendre plus lisible user: chosen_languages: Lorsque coché, seuls les messages dans les langues sélectionnées seront affichés sur les fils publics - role: Le rôle définit quelles autorisations a l'utilisateur⋅rice + role: Le rôle définit quelles autorisations a l'utilisateur⋅rice. user_role: color: Couleur à attribuer au rôle dans l'interface, au format hexadécimal RVB highlighted: Cela rend le rôle visible publiquement diff --git a/config/locales/simple_form.fy.yml b/config/locales/simple_form.fy.yml index e6c1b0ee82..e7deca9460 100644 --- a/config/locales/simple_form.fy.yml +++ b/config/locales/simple_form.fy.yml @@ -130,7 +130,6 @@ fy: name: Jo kinne elk wurd mei in haadletter begjinne, om sa bygelyks de tekst mear lêsber te meitsjen user: chosen_languages: Allinnich berjochten yn de selektearre talen wurde op de iepenbiere tiidline toand - role: De rol bepaalt hokker rjochten in brûker hat user_role: color: Kleur dy’t brûkt wurdt foar de rol yn de UI, as RGB yn heksadesimaal formaat highlighted: Dit makket de rol iepenbier sichtber diff --git a/config/locales/simple_form.ga.yml b/config/locales/simple_form.ga.yml index 15ea3094b2..7c125b165a 100644 --- a/config/locales/simple_form.ga.yml +++ b/config/locales/simple_form.ga.yml @@ -130,7 +130,7 @@ ga: name: Ní féidir leat ach cásáil na litreacha a athrú, mar shampla, chun é a dhéanamh níos inléite user: chosen_languages: Nuair a dhéantar iad a sheiceáil, ní thaispeánfar ach postálacha i dteangacha roghnaithe in amlínte poiblí - role: Rialaíonn an ról na ceadanna atá ag an úsáideoir + role: Rialaíonn an ról na ceadanna atá ag an úsáideoir. user_role: color: Dath le húsáid don ról ar fud an Chomhéadain, mar RGB i bhformáid heicsidheachúlach highlighted: Déanann sé seo an ról le feiceáil go poiblí diff --git a/config/locales/simple_form.gd.yml b/config/locales/simple_form.gd.yml index 4375feb492..9b6c156de7 100644 --- a/config/locales/simple_form.gd.yml +++ b/config/locales/simple_form.gd.yml @@ -130,7 +130,7 @@ gd: name: Mar eisimpleir, ’s urrainn dhut measgachadh de litrichean mòra ’s beaga a chleachdadh ach an gabh a leughadh nas fhasa user: chosen_languages: Nuair a bhios cromag ris, cha nochd ach postaichean sna cànain a thagh thu air loidhnichean-ama poblach - role: Stiùiridh an dreuchd dè na ceadan a bhios aig cleachdaiche + role: Stiùiridh an dreuchd dè na ceadan a bhios aig cleachdaiche. user_role: color: An datha a bhios air an dreuchd air feadh na h-eadar-aghaidh, ’na RGB san fhòrmat sia-dheicheach highlighted: Le seo, chithear an dreuchd gu poblach diff --git a/config/locales/simple_form.gl.yml b/config/locales/simple_form.gl.yml index aff8a95f0d..abb30fa48c 100644 --- a/config/locales/simple_form.gl.yml +++ b/config/locales/simple_form.gl.yml @@ -130,7 +130,7 @@ gl: name: Só podes cambiar maiús/minúsculas, por exemplo, mellorar a lexibilidade user: chosen_languages: Se ten marca, só as publicacións nos idiomas seleccionados serán mostrados en cronoloxías públicas - role: O control dos roles adxudicados ás usuarias + role: Os roles establecen os permisos que ten a usuaria. user_role: color: Cor que se usará para o rol a través da IU, como RGB en formato hex highlighted: Isto fai o rol publicamente visible diff --git a/config/locales/simple_form.he.yml b/config/locales/simple_form.he.yml index 9e2becc52f..f595a31997 100644 --- a/config/locales/simple_form.he.yml +++ b/config/locales/simple_form.he.yml @@ -130,7 +130,6 @@ he: name: ניתן רק להחליף בין אותיות קטנות וגדולות, למשל כדי לשפר את הקריאות user: chosen_languages: אם פעיל, רק הודעות בשפות הנבחרות יוצגו לפידים הפומביים - role: התפקיד שולט על אילו הרשאות יש למשתמש user_role: color: צבע לתפקיד בממשק המשתמש, כ RGB בפורמט הקסדצימלי highlighted: מאפשר נראות ציבורית של התפקיד diff --git a/config/locales/simple_form.hu.yml b/config/locales/simple_form.hu.yml index 512e13d3af..545fd4a8e9 100644 --- a/config/locales/simple_form.hu.yml +++ b/config/locales/simple_form.hu.yml @@ -130,7 +130,7 @@ hu: name: Csak a kis/nagybetűséget változtathatod meg, pl. hogy olvashatóbb legyen user: chosen_languages: Ha aktív, csak a kiválasztott nyelvű bejegyzések jelennek majd meg a nyilvános idővonalon - role: A szerep szabályozza, hogy a felhasználó milyen jogosultságokkal rendelkezik + role: A szerep szabályozza, hogy a felhasználó milyen jogosultságokkal rendelkezik. user_role: color: A szerephez használandó szín mindenhol a felhasználói felületen, hexa RGB formátumban highlighted: Ez nyilvánosan láthatóvá teszi a szerepet diff --git a/config/locales/simple_form.ia.yml b/config/locales/simple_form.ia.yml index 76990527a0..85fa74f1ed 100644 --- a/config/locales/simple_form.ia.yml +++ b/config/locales/simple_form.ia.yml @@ -130,7 +130,6 @@ ia: name: Tu pote solmente cambiar le litteras inter majusculas e minusculas, per exemplo, pro render lo plus legibile user: chosen_languages: Si marcate, solo le messages in le linguas seligite sera monstrate in chronologias public - role: Le rolo controla que permissos ha le usator user_role: color: Color a esser usate pro le rolo in omne parte del UI, como RGB in formato hexadecimal highlighted: Iste rende le rolo publicamente visibile diff --git a/config/locales/simple_form.id.yml b/config/locales/simple_form.id.yml index 99f4372cc1..0bc98874eb 100644 --- a/config/locales/simple_form.id.yml +++ b/config/locales/simple_form.id.yml @@ -107,7 +107,6 @@ id: name: Anda hanya dapat mengubahnya ke huruf kecil/besar, misalnya, agar lebih mudah dibaca user: chosen_languages: Ketika dicentang, hanya toot dalam bahasa yang dipilih yang akan ditampilkan di linimasa publik - role: Peran mengatur izin apa yang dimiliki pengguna user_role: color: Warna yang digunakan untuk peran di antarmuka pengguna, sebagai RGB dalam format hex highlighted: Ini membuat peran terlihat secara publik diff --git a/config/locales/simple_form.ie.yml b/config/locales/simple_form.ie.yml index 0828139a43..771e341616 100644 --- a/config/locales/simple_form.ie.yml +++ b/config/locales/simple_form.ie.yml @@ -130,7 +130,6 @@ ie: name: Tu posse changear solmen li minu/majusculitá del lítteres, por exemple, por far it plu leibil user: chosen_languages: Quande selectet, solmen postas in ti lingues va esser monstrat in public témpor-lineas - role: Permissiones de usator decidet per su rol user_role: color: Color a usar por li rol tra li UI, quam RGB (rubi-verdi-blu) in formate hex highlighted: Va far li rol publicmen visibil diff --git a/config/locales/simple_form.io.yml b/config/locales/simple_form.io.yml index 4de7475b2e..fe8243b0e9 100644 --- a/config/locales/simple_form.io.yml +++ b/config/locales/simple_form.io.yml @@ -122,7 +122,6 @@ io: name: Vu povas nur chanjar literkaso, por exemplo, por kauzigar lu divenar plu lektebla user: chosen_languages: Kande marketigesis, nur posti en selektesis lingui montresos en publika tempolinei - role: Rolo dominacas permisi quon uzanto havas user_role: color: Koloro quo uzesas por rolo en tota UI, quale RGB kun hexformato highlighted: Co kauzigas rolo divenar publike videbla diff --git a/config/locales/simple_form.is.yml b/config/locales/simple_form.is.yml index a7e2083f4d..d615e391ac 100644 --- a/config/locales/simple_form.is.yml +++ b/config/locales/simple_form.is.yml @@ -130,7 +130,7 @@ is: name: Þú getur aðeins breytt stafstöði mill há-/lágstafa, til gæmis til að gera þetta læsilegra user: chosen_languages: Þegar merkt er við þetta, birtast einungis færslur á völdum tungumálum á opinberum tímalínum - role: Hlutverk stýrir hvaða heimildir notandinn hefur + role: Hlutverk stýrir hvaða heimildir notandinn hefur. user_role: color: Litur sem notaður er fyrir hlutverkið allsstaðar í viðmótinu, sem RGB-gildi á hex-sniði highlighted: Þetta gerir hlutverk sýnilegt opinberlega diff --git a/config/locales/simple_form.it.yml b/config/locales/simple_form.it.yml index ea175e2bf5..1068b2f927 100644 --- a/config/locales/simple_form.it.yml +++ b/config/locales/simple_form.it.yml @@ -130,7 +130,7 @@ it: name: Puoi cambiare solo il minuscolo/maiuscolo delle lettere, ad esempio, per renderlo più leggibile user: chosen_languages: Quando una o più lingue sono contrassegnate, nelle timeline pubbliche vengono mostrati solo i toot nelle lingue selezionate - role: Il ruolo controlla quali permessi ha l'utente + role: Il ruolo controlla quali permessi ha l'utente. user_role: color: Colore da usare per il ruolo in tutta l'UI, come RGB in formato esadecimale highlighted: Rende il ruolo visibile diff --git a/config/locales/simple_form.ja.yml b/config/locales/simple_form.ja.yml index 8815af9933..2c1bd6a084 100644 --- a/config/locales/simple_form.ja.yml +++ b/config/locales/simple_form.ja.yml @@ -130,7 +130,6 @@ ja: name: 視認性向上などのためにアルファベット大文字小文字の変更のみ行うことができます user: chosen_languages: 選択すると、選択した言語の投稿のみが公開タイムラインに表示されるようになります - role: このロールはユーザーが持つ権限を管理します user_role: color: UI 全体でロールの表示に使用される色(16進数RGB形式) highlighted: これによりロールが公開されます。 diff --git a/config/locales/simple_form.ko.yml b/config/locales/simple_form.ko.yml index 5fa3aee6c4..fee07fa5e0 100644 --- a/config/locales/simple_form.ko.yml +++ b/config/locales/simple_form.ko.yml @@ -130,7 +130,7 @@ ko: name: 읽기 쉽게하기 위한 글자의 대소문자만 변경할 수 있습니다. user: chosen_languages: 체크하면, 선택 된 언어로 작성된 게시물들만 공개 타임라인에 보여집니다 - role: 역할은 사용자가 어떤 권한을 가지게 될 지 결정합니다 + role: 역할은 사용자가 어떤 권한을 가지게 될 지 결정합니다. user_role: color: 색상은 사용자 인터페이스에서 역할을 나타내기 위해 사용되며, RGB 16진수 형식입니다 highlighted: 이 역할이 공개적으로 보이도록 설정합니다 diff --git a/config/locales/simple_form.ku.yml b/config/locales/simple_form.ku.yml index 96e047d937..db50384c7e 100644 --- a/config/locales/simple_form.ku.yml +++ b/config/locales/simple_form.ku.yml @@ -106,7 +106,6 @@ ku: name: Tu dikarî tenê mezinahiya tîpan biguherînî bo mînak, da ku ew bêtir were xwendin user: chosen_languages: Dema were nîşankirin, tenê parvekirinên bi zimanên hilbijartî dê di rêzikên giştî de werin nîşandan - role: Rola kîjan mafdayînên bikarhêner heye kontrol dike user_role: color: Renga ku were bikaranîn ji bo rola li seranserê navrûya bikarhêneriyê, wekî RGB di forma hex highlighted: Ev rola xwe ji raya giştî re xuya dike diff --git a/config/locales/simple_form.lad.yml b/config/locales/simple_form.lad.yml index f7093ff73b..2a381534ba 100644 --- a/config/locales/simple_form.lad.yml +++ b/config/locales/simple_form.lad.yml @@ -125,7 +125,7 @@ lad: name: Solo se puede trokar la kapitalizasyon de las letras, por enshemplo, para ke sea mas meldable user: chosen_languages: Kuando se marka, solo se amostraran las publikasyones en las linguas eskojidas en las linyas de tiempo publikas - role: El rolo kontrola kualos permisos tiene el utilizador + role: El rolo kontrola kualos permisos tiene el utilizador. user_role: color: Color ke se utilizara para el rolo a lo largo de la enterfaz de utilizador, komo RGB en formato heksadesimal highlighted: Esto faze ke el rolo sea publikamente visible diff --git a/config/locales/simple_form.lt.yml b/config/locales/simple_form.lt.yml index 02f0360938..ecbf501389 100644 --- a/config/locales/simple_form.lt.yml +++ b/config/locales/simple_form.lt.yml @@ -101,7 +101,6 @@ lt: show_application: Neatsižvelgiant į tai, visada galėsi matyti, kuri programėlė paskelbė tavo įrašą. user: chosen_languages: Kai pažymėta, viešose laiko skalėse bus rodomi tik įrašai pasirinktomis kalbomis. - role: Vaidmuo valdo, kokius leidimus naudotojas (-a) turi labels: account: discoverable: Rekomenduoti profilį ir įrašus į atradimo algoritmus diff --git a/config/locales/simple_form.lv.yml b/config/locales/simple_form.lv.yml index eedae998e4..d96f57058b 100644 --- a/config/locales/simple_form.lv.yml +++ b/config/locales/simple_form.lv.yml @@ -128,7 +128,6 @@ lv: name: Tu vari mainīt tikai burtu lielumu, piemēram, lai tie būtu vieglāk lasāmi user: chosen_languages: Ja ieķeksēts, publiskos laika grafikos tiks parādītas tikai ziņas noteiktajās valodās - role: Loma kontrolē, kādas atļaujas ir lietotājam user_role: color: Krāsa, kas jāizmanto lomai visā lietotāja saskarnē, kā RGB hex formātā highlighted: Tas padara lomu publiski redzamu diff --git a/config/locales/simple_form.ms.yml b/config/locales/simple_form.ms.yml index da00e2dc2b..ecc3588d67 100644 --- a/config/locales/simple_form.ms.yml +++ b/config/locales/simple_form.ms.yml @@ -122,7 +122,6 @@ ms: name: Anda hanya boleh menukar selongsong huruf, sebagai contoh, untuk menjadikannya lebih mudah dibaca user: chosen_languages: Apabila disemak, hanya siaran dalam bahasa terpilih akan dipaparkan dalam garis masa awam - role: Peranan mengawal kebenaran yang dimiliki oleh pengguna user_role: color: Warna yang akan digunakan untuk peranan ini dalam seluruh UI, sebagai RGB dalam format hex highlighted: Ini menjadikan peranan ini dipaparkan secara umum diff --git a/config/locales/simple_form.my.yml b/config/locales/simple_form.my.yml index a44635edd4..abcb11bdaa 100644 --- a/config/locales/simple_form.my.yml +++ b/config/locales/simple_form.my.yml @@ -122,7 +122,6 @@ my: name: ဥပမာအားဖြင့် စာလုံးများကို ပိုမိုဖတ်ရှုနိုင်စေရန်မှာ သင်သာ ပြောင်းလဲနိုင်သည်။ user: chosen_languages: အမှန်ခြစ် ရွေးချယ်ထားသော ဘာသာစကားများဖြင့်သာ ပို့စ်များကို အများမြင်စာမျက်နှာတွင် ပြသပါမည် - role: အသုံးပြုသူ၏ ခွင့်ပြုချက်ကဏ္ဍကို ထိန်းချုပ်ထားသည် user_role: color: hex ပုံစံ RGB အဖြစ် UI တစ်လျှောက်လုံး အခန်းကဏ္ဍအတွက် အသုံးပြုရမည့်အရောင် highlighted: ယင်းက အခန်းကဏ္ဍကို အများမြင်အောင် ဖွင့်ပေးထားသည်။ diff --git a/config/locales/simple_form.nl.yml b/config/locales/simple_form.nl.yml index 91ee9bc3e3..066f6c2acb 100644 --- a/config/locales/simple_form.nl.yml +++ b/config/locales/simple_form.nl.yml @@ -130,7 +130,7 @@ nl: name: Je kunt elk woord met een hoofdletter beginnen, om zo bijvoorbeeld de tekst leesbaarder te maken user: chosen_languages: Alleen berichten in de aangevinkte talen worden op de openbare tijdlijnen getoond - role: De rol bepaalt welke rechten een gebruiker heeft + role: De rol bepaalt welke rechten de gebruiker heeft. user_role: color: Kleur die gebruikt wordt voor de rol in de UI, als RGB in hexadecimale formaat highlighted: Dit maakt de rol openbaar zichtbaar diff --git a/config/locales/simple_form.nn.yml b/config/locales/simple_form.nn.yml index c4d4438b94..500a41c8cc 100644 --- a/config/locales/simple_form.nn.yml +++ b/config/locales/simple_form.nn.yml @@ -130,7 +130,6 @@ nn: name: Du kan berre endra bruken av store/små bokstavar, t. d. for å gjera det meir leseleg user: chosen_languages: Når merka vil berre tuta på dei valde språka synast på offentlege tidsliner - role: Rolla kontrollerer kva tilgangar brukaren har user_role: color: Fargen som skal nyttast for denne rolla i heile brukargrensesnittet, som RGB i hex-format highlighted: Dette gjer rolla synleg offentleg diff --git a/config/locales/simple_form.no.yml b/config/locales/simple_form.no.yml index 82de0adb7b..73ba17cd4c 100644 --- a/config/locales/simple_form.no.yml +++ b/config/locales/simple_form.no.yml @@ -124,7 +124,6 @@ name: Du kan bare forandre bruken av store/små bokstaver, f.eks. for å gjøre det mer lesbart user: chosen_languages: Hvis noen av dem er valgt, vil kun innlegg i de valgte språkene bli vist i de offentlige tidslinjene - role: Rollekontroller som bestemmer rettigheter brukeren har user_role: color: Farge som skal brukes for rollen gjennom hele UI, som RGB i hex-format highlighted: Dette gjør rollen offentlig synlig diff --git a/config/locales/simple_form.pl.yml b/config/locales/simple_form.pl.yml index 1a9051b951..7419169890 100644 --- a/config/locales/simple_form.pl.yml +++ b/config/locales/simple_form.pl.yml @@ -130,7 +130,6 @@ pl: name: Możesz zmieniać tylko wielkość liter, np. aby były bardziej widoczne user: chosen_languages: Jeżeli zaznaczone, tylko wpisy w wybranych językach będą wyświetlane na publicznych osiach czasu - role: Rola kontroluje uprawnienia użytkownika user_role: color: Kolor używany dla roli w całym interfejsie użytkownika, wyrażony jako RGB w formacie szesnastkowym highlighted: To sprawia, że rola jest widoczna publicznie diff --git a/config/locales/simple_form.pt-BR.yml b/config/locales/simple_form.pt-BR.yml index 65d3883690..6b0bad0f08 100644 --- a/config/locales/simple_form.pt-BR.yml +++ b/config/locales/simple_form.pt-BR.yml @@ -130,7 +130,6 @@ pt-BR: name: Você pode mudar a capitalização das letras, por exemplo, para torná-la mais legível user: chosen_languages: Apenas as publicações dos idiomas selecionados serão exibidas nas linhas públicas - role: O cargo controla quais permissões o usuário tem user_role: color: Cor a ser usada para o cargo em toda a interface do usuário, como RGB no formato hexadecimal highlighted: Isso torna o cargo publicamente visível diff --git a/config/locales/simple_form.pt-PT.yml b/config/locales/simple_form.pt-PT.yml index 25348f2770..971773b2dc 100644 --- a/config/locales/simple_form.pt-PT.yml +++ b/config/locales/simple_form.pt-PT.yml @@ -130,7 +130,6 @@ pt-PT: name: Só pode alterar a capitalização das letras, por exemplo, para torná-las mais legíveis user: chosen_languages: Quando selecionado, só serão mostradas nas cronologias públicas as publicações nos idiomas escolhidos - role: A função controla que permissões o utilizador tem user_role: color: Cor a ser utilizada para a função em toda a interface de utilizador, como RGB no formato hexadecimal highlighted: Isto torna a função visível publicamente diff --git a/config/locales/simple_form.ru.yml b/config/locales/simple_form.ru.yml index 0f830174c8..b41457e86a 100644 --- a/config/locales/simple_form.ru.yml +++ b/config/locales/simple_form.ru.yml @@ -125,7 +125,6 @@ ru: name: Вы можете изменить только регистр букв чтобы, например, сделать тег более читаемым user: chosen_languages: Если выбрано, то в публичных лентах будут показаны только посты на выбранных языках. - role: Роль определяет, какие разрешения есть у пользователя user_role: color: Цвет, который будет использоваться для роли в интерфейсе (UI), как RGB в формате HEX highlighted: Это действие сделает роль публичной diff --git a/config/locales/simple_form.sco.yml b/config/locales/simple_form.sco.yml index 9fc6fd57db..2bc4f6a456 100644 --- a/config/locales/simple_form.sco.yml +++ b/config/locales/simple_form.sco.yml @@ -104,7 +104,6 @@ sco: name: Ye kin ainly chynge the case o the letters, fir example, fir tae mak it mair readable user: chosen_languages: Whan ticked, ainly posts in selectit leids wull be displayit in public timelines - role: The role controls whit permissions the uiser haes user_role: color: Colour tae be uised fir the role throuoot the UI, as RGB in hex format highlighted: This maks the role visible publicly diff --git a/config/locales/simple_form.sl.yml b/config/locales/simple_form.sl.yml index bb16e56a0c..d1ae553c8c 100644 --- a/config/locales/simple_form.sl.yml +++ b/config/locales/simple_form.sl.yml @@ -130,7 +130,6 @@ sl: name: Spremenite lahko le npr. velikost črk (velike/male), da je bolj berljivo user: chosen_languages: Ko je označeno, bodo v javnih časovnicah prikazane samo objave v izbranih jezikih - role: Vloga nadzira, katere pravice ima uporabnik user_role: color: Barva, uporabljena za vlogo po celem up. vmesniku, podana v šestnajstiškem zapisu RGB highlighted: S tem je vloga javno vidna diff --git a/config/locales/simple_form.sq.yml b/config/locales/simple_form.sq.yml index 8b00751d98..3d86557282 100644 --- a/config/locales/simple_form.sq.yml +++ b/config/locales/simple_form.sq.yml @@ -130,7 +130,7 @@ sq: name: Mund të ndryshoni shkronjat vetëm nga të mëdha në të vogla ose anasjelltas, për shembull, për t’i bërë më të lexueshme user: chosen_languages: Në iu vëntë shenjë, te rrjedha kohore publike do të shfaqen vetëm mesazhe në gjuhët e përzgjedhura - role: Roli kontrollon cilat leje ka përdoruesi + role: Roli kontrollon cilat leje ka përdoruesi. user_role: color: Ngjyrë për t’u përdorur për rolin nëpër UI, si RGB në format gjashtëmbëdhjetësh highlighted: Kjo e bën rolin të dukshëm publikisht diff --git a/config/locales/simple_form.sr-Latn.yml b/config/locales/simple_form.sr-Latn.yml index 527c5e0a1f..1dec901340 100644 --- a/config/locales/simple_form.sr-Latn.yml +++ b/config/locales/simple_form.sr-Latn.yml @@ -130,7 +130,6 @@ sr-Latn: name: Mogu se samo promeniti mala slova u velika ili obrnuto, na primer, da bi bilo čitljivije user: chosen_languages: Kada je označeno, objave u izabranim jezicima će biti prikazane na javnoj vremenskoj liniji - role: Uloga kontroliše koje dozvole korisnik ima user_role: color: Boja koja će se koristiti za ulogu u celom korisničkom okruženju, kao RGB u heksadecimalnom formatu highlighted: Ovo čini ulogu javno vidljivom diff --git a/config/locales/simple_form.sr.yml b/config/locales/simple_form.sr.yml index d541c0b49c..9566e09475 100644 --- a/config/locales/simple_form.sr.yml +++ b/config/locales/simple_form.sr.yml @@ -130,7 +130,6 @@ sr: name: Могу се само променити мала слова у велика или обрнуто, на пример, да би било читљивије user: chosen_languages: Када је означено, објаве у изабраним језицима ће бити приказане на јавној временској линији - role: Улога контролише које дозволе корисник има user_role: color: Боја која ће се користити за улогу у целом корисничком окружењу, као RGB у хексадецималном формату highlighted: Ово чини улогу јавно видљивом diff --git a/config/locales/simple_form.sv.yml b/config/locales/simple_form.sv.yml index 329cabf941..297e96a2bd 100644 --- a/config/locales/simple_form.sv.yml +++ b/config/locales/simple_form.sv.yml @@ -130,7 +130,7 @@ sv: name: Du kan bara ändra skriftläget av bokstäverna, till exempel, för att göra det mer läsbart user: chosen_languages: Vid aktivering visas bara inlägg på dina valda språk i offentliga tidslinjer - role: Rollen bestämmer vilka behörigheter användaren har + role: Rollen styr vilka behörigheter användaren har. user_role: color: Färgen som ska användas för rollen i användargränssnittet, som RGB i hex-format highlighted: Detta gör rollen synlig offentligt diff --git a/config/locales/simple_form.tr.yml b/config/locales/simple_form.tr.yml index c62be89b28..89fb1675fd 100644 --- a/config/locales/simple_form.tr.yml +++ b/config/locales/simple_form.tr.yml @@ -130,7 +130,6 @@ tr: name: Harflerin, örneğin daha okunabilir yapmak için, sadece büyük/küçük harf durumlarını değiştirebilirsiniz user: chosen_languages: İşaretlendiğinde, yalnızca seçilen dillerdeki gönderiler genel zaman çizelgelerinde görüntülenir - role: Rol, kullanıcıların sahip olduğu izinleri denetler user_role: color: Arayüz boyunca rol için kullanılacak olan renk, hex biçiminde RGB highlighted: Bu rolü herkese açık hale getirir diff --git a/config/locales/simple_form.uk.yml b/config/locales/simple_form.uk.yml index c6305598b1..e2a1562b53 100644 --- a/config/locales/simple_form.uk.yml +++ b/config/locales/simple_form.uk.yml @@ -130,7 +130,7 @@ uk: name: Тут ви можете лише змінювати регістр літер, щоб підвищити читабельність user: chosen_languages: У глобальних стрічках будуть показані дописи тільки вибраними мовами - role: Роль визначає права користувача + role: Роль визначає, які права має користувач. user_role: color: Колір, який буде використовуватися для ролі у всьому інтерфейсі, як RGB у форматі hex highlighted: Це робить роль видимою всім diff --git a/config/locales/simple_form.vi.yml b/config/locales/simple_form.vi.yml index 7954bb1e6f..4e7c8b0a97 100644 --- a/config/locales/simple_form.vi.yml +++ b/config/locales/simple_form.vi.yml @@ -130,7 +130,7 @@ vi: name: Bạn có thể thay đổi cách viết hoa các chữ cái để giúp nó dễ đọc hơn user: chosen_languages: Chỉ hiển thị những tút viết bằng các ngôn ngữ sau - role: Vai trò kiểm soát những quyền mà người dùng có + role: Vai trò kiểm soát những quyền mà người dùng có. user_role: color: Màu được sử dụng cho vai trò trong toàn bộ giao diện người dùng, dưới dạng RGB ở định dạng hex highlighted: Vai trò sẽ hiển thị công khai diff --git a/config/locales/simple_form.zh-CN.yml b/config/locales/simple_form.zh-CN.yml index 3f7b8782ee..cb4341b551 100644 --- a/config/locales/simple_form.zh-CN.yml +++ b/config/locales/simple_form.zh-CN.yml @@ -4,12 +4,12 @@ zh-CN: hints: account: discoverable: 您的公开嘟文和个人资料可能会在 Mastodon 的多个位置展示,您的个人资料可能会被推荐给其他用户。 - display_name: 您的全名或昵称。 + display_name: 你的全名或昵称。 fields: 你的主页、人称代词、年龄,以及任何你想要添加的内容。 indexable: 您的公开嘟文会出现在 Mastodon 的搜索结果中。无论是否勾选,与您的嘟文有过交互的人都可能通过搜索找到它们。 - note: '您可以提及 @其他人 或 #标签 。' + note: '你可以提及 @其他人 或 #标签 。' show_collections: 人们将能够浏览您的关注和追随者。您关注的人会看到您关注他们。 - unlocked: 人们将能够在不请求批准的情况下关注您。如果您希望审核关注请求并选择接受或拒绝新的粉丝,请取消勾选此项。 + unlocked: 人们将能够在不请求批准的情况下关注你。如果你希望审核关注请求并选择接受或拒绝新的粉丝,请取消勾选此项。 account_alias: acct: 指定你想要迁移过来的原账号:用户名@站点域名 account_migration: @@ -78,7 +78,7 @@ zh-CN: form_admin_settings: activity_api_enabled: 本站每周的嘟文数、活跃用户数和新注册用户数 app_icon: WEBP、PNG、GIF 或 JPG。使用自定义图标覆盖移动设备上的默认应用图标。 - backups_retention_period: 用户可以生成其嘟文存档以供之后下载。当该值被设为正值时,这些存档将在指定的天数后自动从您的存储中删除。 + backups_retention_period: 用户可以生成其嘟文存档以供之后下载。当该值被设为正值时,这些存档将在指定的天数后自动从你的存储中删除。 bootstrap_timeline_accounts: 这些账号将在新用户关注推荐中置顶。 closed_registrations_message: 在关闭注册时显示 content_cache_retention_period: 来自其它实例的所有嘟文(包括转嘟与回复)都将在指定天数后被删除,不论本实例用户是否与这些嘟文产生过交互。这包括被本实例用户喜欢和收藏的嘟文。实例间用户的私下提及也将丢失并无法恢复。此设置针对的是特殊用途的实例,用于一般用途时会打破许多用户的期望。 @@ -125,12 +125,12 @@ zh-CN: webauthn: 如果是 USB 密钥,请确保将其插入,如有必要,请点击它。 settings: indexable: 您的个人资料页面可能会出现在Google、Bing等搜索结果中。 - show_application: 无论如何,您始终可以看到是哪个应用发布了您的嘟文。 + show_application: 无论如何,你始终可以看到是哪个应用发布了你的嘟文。 tag: name: 你只能改变字母的大小写,让它更易读 user: chosen_languages: 仅选中语言的嘟文会出现在公共时间轴上(全不选则显示所有语言的嘟文) - role: 角色用于控制用户拥有的权限 + role: 角色用于控制用户拥有的权限。 user_role: color: 在界面各处用于标记该角色的颜色,以十六进制 RGB 格式表示 highlighted: 使角色公开可见 @@ -143,7 +143,7 @@ zh-CN: url: 事件将被发往的目的地 labels: account: - discoverable: 在发现算法中展示您的个人资料和嘟文 + discoverable: 在发现算法中展示你的个人资料和嘟文 fields: name: 标签 value: 内容 @@ -309,7 +309,7 @@ zh-CN: text: 规则 settings: indexable: 允许搜索引擎索引个人资料页面 - show_application: 显示您发嘟所用的应用 + show_application: 显示你发嘟所用的应用 tag: listable: 允许这个话题标签在用户目录中显示 name: 话题标签 diff --git a/config/locales/simple_form.zh-HK.yml b/config/locales/simple_form.zh-HK.yml index 6a7cd5a247..dd134a58fb 100644 --- a/config/locales/simple_form.zh-HK.yml +++ b/config/locales/simple_form.zh-HK.yml @@ -128,7 +128,6 @@ zh-HK: name: 你只能變更大小寫(以使其更易讀)。 user: chosen_languages: 只有被選擇的語言會在公開時間軸內顯示 - role: 角色控制使用者擁有的權限 user_role: color: 介面各處用於角色的顏色,是以十六進制 RGB 格式表示 highlighted: 這使該角色公開可見 diff --git a/config/locales/simple_form.zh-TW.yml b/config/locales/simple_form.zh-TW.yml index 05692243ad..8b4c440025 100644 --- a/config/locales/simple_form.zh-TW.yml +++ b/config/locales/simple_form.zh-TW.yml @@ -53,7 +53,7 @@ zh-TW: password: 使用至少 8 個字元 phrase: 無論是嘟文的本文或是內容警告都會被過濾 scopes: 允許使應用程式存取的 API。 若您選擇最高階範圍,則無須選擇個別項目。 - setting_aggregate_reblogs: 請勿顯示最近已被轉嘟之嘟文的最新轉嘟(只影響最新收到的嘟文) + setting_aggregate_reblogs: 不顯示最近已被轉嘟之嘟文的最新轉嘟(只影響最新收到的嘟文) setting_always_send_emails: 一般情況下若您活躍使用 Mastodon ,我們不會寄送電子郵件通知 setting_default_sensitive: 敏感內容媒體預設隱藏,且按一下即可重新顯示 setting_display_media_default: 隱藏標為敏感內容的媒體 @@ -130,7 +130,7 @@ zh-TW: name: 您只能變更大小寫,例如,以使其更易讀。 user: chosen_languages: 當選取時,只有選取語言之嘟文會於公開時間軸中顯示 - role: 角色控制使用者有哪些權限 + role: 角色控制使用者有哪些權限。 user_role: color: 於整個使用者介面中用於角色的顏色,十六進位格式的 RGB highlighted: 這將使角色公開可見 diff --git a/config/locales/sq.yml b/config/locales/sq.yml index b3d273024b..0f43f43988 100644 --- a/config/locales/sq.yml +++ b/config/locales/sq.yml @@ -25,6 +25,8 @@ sq: admin: account_actions: action: Kryeje veprimin + already_silenced: Kjo llogari është heshtuar tashmë. + already_suspended: Kjo llogari është pezulluar tashmë. title: Kryeni veprim moderimi te %{acct} account_moderation_notes: create: Lini një shënim @@ -46,6 +48,7 @@ sq: title: Ndrysho email-in për %{username} change_role: changed_msg: Roli u ndryshua me sukses! + edit_roles: Administroni role përdoruesish label: Ndryshoni rol no_role: Pa rol title: Ndryshoni rolin për %{username} @@ -600,6 +603,7 @@ sq: suspend_description_html: Llogaria dhe krejt lënda e saj s’do të jenë të përdorshme dhe, së fundi, do të fshihen dhe ndërveprimi me te do të jetë i pamundur. E prapakthyeshme brenda 30 ditësh. Mbyll krejt raportimet kundër kësaj llogarie. actions_description_html: Vendosni cili veprim të kryhet për të zgjidhur këtë raportim. Nëse ndërmerrni një veprim ndëshkues kundër llogarisë së raportuar, atyre do t’u dërgohet një njoftim me email, hiq rastin kur përzgjidhet kategoria I padëshiruar. actions_description_remote_html: Vendosni cili veprim të ndërmerret për zgjidhjen e këtij raportimi. Kjo do të prekë vetëm mënyrën se si shërbyesi juaj komunikon me këtë llogari të largët dhe se si e trajtojnë lëndën e saj. + actions_no_posts: Ky raportim s’ka ndonjë postim të përshoqëruar, për fshirje add_to_report: Shtoni më tepër te raportimi already_suspended_badges: local: Tashmë i pezulluar në këtë shërbyes diff --git a/config/locales/sv.yml b/config/locales/sv.yml index e47f506e6b..bcf1e3b816 100644 --- a/config/locales/sv.yml +++ b/config/locales/sv.yml @@ -46,6 +46,7 @@ sv: title: Byt e-postadress för %{username} change_role: changed_msg: Rollen har ändrats! + edit_roles: Hantera användarroller label: Ändra roll no_role: Ingen roll title: Ändra roll för %{username} diff --git a/config/locales/th.yml b/config/locales/th.yml index 7f90c3bc94..f119102112 100644 --- a/config/locales/th.yml +++ b/config/locales/th.yml @@ -23,6 +23,8 @@ th: admin: account_actions: action: ทำการกระทำ + already_silenced: มีการทำให้บัญชีนี้เงียบไปแล้ว + already_suspended: มีการระงับบัญชีนี้ไปแล้ว title: ทำการกระทำการกลั่นกรองต่อ %{acct} account_moderation_notes: create: เขียนหมายเหตุ @@ -44,6 +46,7 @@ th: title: เปลี่ยนอีเมลสำหรับ %{username} change_role: changed_msg: เปลี่ยนบทบาทสำเร็จ! + edit_roles: จัดการบทบาทผู้ใช้ label: เปลี่ยนบทบาท no_role: ไม่มีบทบาท title: เปลี่ยนบทบาทสำหรับ %{username} @@ -590,6 +593,7 @@ th: suspend_description_html: บัญชีและเนื้อหาของบัญชีทั้งหมดจะเข้าถึงไม่ได้และได้รับการลบในที่สุด และการโต้ตอบกับบัญชีจะเป็นไปไม่ได้ แปลงกลับได้ภายใน 30 วัน ปิดรายงานต่อบัญชีนี้ทั้งหมด actions_description_html: ตัดสินใจว่าการกระทำใดที่จะใช้เพื่อแก้ปัญหารายงานนี้ หากคุณใช้การกระทำที่เป็นการลงโทษต่อบัญชีที่รายงาน จะส่งการแจ้งเตือนอีเมลถึงเขา ยกเว้นเมื่อมีการเลือกหมวดหมู่ สแปม actions_description_remote_html: ตัดสินใจว่าการกระทำใดที่จะใช้เพื่อแก้ปัญหารายงานนี้ นี่จะมีผลต่อวิธีที่เซิร์ฟเวอร์ ของคุณ สื่อสารกับบัญชีระยะไกลนี้และจัดการเนื้อหาของบัญชีเท่านั้น + actions_no_posts: รายงานนี้ไม่มีโพสต์ที่เกี่ยวข้องใด ๆ ให้ลบ add_to_report: เพิ่มข้อมูลเพิ่มเติมไปยังรายงาน already_suspended_badges: local: ระงับในเซิร์ฟเวอร์นี้อยู่แล้ว @@ -1428,6 +1432,7 @@ th: media_attachments: validations: images_and_video: ไม่สามารถแนบวิดีโอกับโพสต์ที่มีภาพอยู่แล้ว + not_found: ไม่พบสื่อ %{ids} หรือได้แนบกับโพสต์อื่นไปแล้ว not_ready: ไม่สามารถแนบไฟล์ที่ยังประมวลผลไม่เสร็จ ลองอีกครั้งในอีกสักครู่! too_many: ไม่สามารถแนบมากกว่า 4 ไฟล์ migrations: diff --git a/config/locales/uk.yml b/config/locales/uk.yml index 544e2671c6..261c87cd75 100644 --- a/config/locales/uk.yml +++ b/config/locales/uk.yml @@ -29,6 +29,7 @@ uk: admin: account_actions: action: Виконати дію + already_suspended: Цей обліковий запис вже було призупинено. title: Здійснити модераційну дію над %{acct} account_moderation_notes: create: Залишити нотатку @@ -50,6 +51,7 @@ uk: title: Змінити адресу електронної пошти для %{username} change_role: changed_msg: Роль успішно змінено! + edit_roles: Керування ролями label: Змінити роль no_role: Немає ролі title: Змінити роль для %{username} diff --git a/config/locales/vi.yml b/config/locales/vi.yml index 2f607d1ecb..975df3024b 100644 --- a/config/locales/vi.yml +++ b/config/locales/vi.yml @@ -23,6 +23,8 @@ vi: admin: account_actions: action: Thực hiện hành động + already_silenced: Tài khoản này đã bị hạn chế. + already_suspended: Tài khoản này đã bị vô hiệu hóa. title: Áp đặt kiểm duyệt với %{acct} account_moderation_notes: create: Thêm lưu ý @@ -44,6 +46,7 @@ vi: title: Thay đổi email cho %{username} change_role: changed_msg: Vai trò đã thay đổi thành công! + edit_roles: Quản lý vai trò người dùng label: Đổi vai trò no_role: Chưa có vai trò title: Thay đổi vai trò %{username} @@ -590,6 +593,7 @@ vi: suspend_description_html: Tài khoản và tất cả nội dung của nó sẽ không thể truy cập được và cuối cùng sẽ bị xóa, đồng thời không thể tương tác với tài khoản đó. Có thể đảo ngược trong vòng 30 ngày. Đóng tất cả các báo cáo đối với tài khoản này. actions_description_html: Nếu áp đặt kiểm duyệt, một email thông báo sẽ được gửi cho người này, ngoại trừ Spam. actions_description_remote_html: Chọn hành động cần thực hiện để xử lý báo cáo này. Điều này sẽ chỉ ảnh hưởng đến cách máy chủ của bạn giao tiếp với tài khoản này và xử lý nội dung của nó. + actions_no_posts: Báo cáo này không có tút liên quan để xóa add_to_report: Bổ sung báo cáo already_suspended_badges: local: Đã vô hiệu hóa trên máy chủ này diff --git a/config/locales/zh-CN.yml b/config/locales/zh-CN.yml index a8d401c7bb..6b399d3499 100644 --- a/config/locales/zh-CN.yml +++ b/config/locales/zh-CN.yml @@ -23,6 +23,8 @@ zh-CN: admin: account_actions: action: 执行操作 + already_silenced: 此帐户已受限。 + already_suspended: 此帐户已被封禁。 title: 在 %{acct} 上执行管理操作 account_moderation_notes: create: 新建记录 @@ -44,6 +46,7 @@ zh-CN: title: 更改 %{username} 的电子邮箱 change_role: changed_msg: 已成功更改角色! + edit_roles: 管理用户角色 label: 更改角色 no_role: 没有角色 title: 更改 %{username} 的角色 @@ -383,9 +386,9 @@ zh-CN: cancel: 取消 confirm: 封禁 permanent_action: 撤销暂停不会恢复任何数据或关系。 - preamble_html: 您将要暂停 %{domain} 及其子域。 - remove_all_data: 这将从您的实例上删除此域名下账户的所有内容、媒体和个人资料数据。 - stop_communication: 您的实例将停止与这些实例的通信。 + preamble_html: 你将要暂停 %{domain} 及其子域。 + remove_all_data: 这将从你的实例上删除此域名下账户的所有内容、媒体和个人资料数据。 + stop_communication: 你的实例将停止与这些实例的通信。 title: 确认对 %{domain} 的封锁 undo_relationships: 这将解除你的实例与这些实例上账户之间的任何关注。 created_msg: 正在进行域名屏蔽 @@ -590,6 +593,7 @@ zh-CN: suspend_description_html: 该帐户及其所有内容将无法访问并最终被删除,且无法与该帐户进行互动。 在 30 天内可随时撤销。关闭针对此帐户的所有举报。 actions_description_html: 决定采取何种措施处理此举报。如果对被举报账号采取惩罚性措施,将向其发送一封电子邮件通知。但若选中垃圾信息类别则不会发送通知。 actions_description_remote_html: 决定采取何种行动来解决此举报。 这只会影响您的服务器如何与该远程帐户的通信并处理其内容。 + actions_no_posts: 该举报没有相关嘟文可供删除 add_to_report: 增加更多举报内容 already_suspended_badges: local: 已经在此服务器上暂停 @@ -609,7 +613,7 @@ zh-CN: created_at: 举报时间 delete_and_resolve: 删除嘟文 forwarded: 已转发 - forwarded_replies_explanation: 该举报来自外站用户,涉及外站内容。之所以转发给您,是因为被举报的内容是对您站点一位用户的回复。 + forwarded_replies_explanation: 该举报来自外站用户,涉及外站内容。之所以转发给你,是因为被举报的内容是对你站点一位用户的回复。 forwarded_to: 转发举报至 %{domain} mark_as_resolved: 标记为已处理 mark_as_sensitive: 标记为敏感内容 @@ -764,7 +768,7 @@ zh-CN: disabled: 不对任何人 users: 对本地已登录用户 registrations: - moderation_recommandation: 在向所有人开放注册之前,请确保您拥有一个人手足够且反应迅速的管理团队! + moderation_recommandation: 在向所有人开放注册之前,请确保你拥有一个人手足够且反应迅速的管理团队! preamble: 控制谁可以在你的服务器上创建账号。 title: 注册 registrations_mode: @@ -772,7 +776,7 @@ zh-CN: approved: 注册时需要批准 none: 关闭注册 open: 开放注册 - warning_hint: 我们建议使用“注册必须经过批准”,除非您确信您的管理团队能够及时处理骚扰和恶意注册。 + warning_hint: 我们建议使用“注册必须经过批准”,除非你确信你的管理团队能够及时处理骚扰和恶意注册。 security: authorized_fetch: 需要跨站认证 authorized_fetch_hint: 要求外站请求通过验证能够使用户级别与服务器级别的封锁更为严格。然而,这将带来额外的性能负担、减少回复触达范围、并可能导致与一些联邦宇宙服务的兼容性问题。此外,这并不能阻止他人针对性地获取公开嘟文与账户。 @@ -784,7 +788,7 @@ zh-CN: destroyed_msg: 站点上传的文件已经成功删除! software_updates: critical_update: 紧急 — 请尽快更新 - description: 建议你及时更新Mastodon实例,以便获得最新修复和功能。此外,为避免安全问题,有时及时更新Mastodon是至关重要的。出于这些原因,Mastodon每30分钟检查一次更新,并根据您的邮件通知偏好向您发送通知。 + description: 建议你及时更新Mastodon实例,以便获得最新修复和功能。此外,为避免安全问题,有时及时更新Mastodon是至关重要的。出于这些原因,Mastodon每30分钟检查一次更新,并根据你的邮件通知偏好向你发送通知。 documentation_link: 详细了解 release_notes: 发行说明 title: 可用的更新 @@ -837,17 +841,17 @@ zh-CN: elasticsearch_health_red: message_html: Elasticsearch 集群状态不健康(红色),搜索功能不可用 elasticsearch_health_yellow: - message_html: Elasticsearch 集群不健康(黄色状态),您可能想要调查原因 + message_html: Elasticsearch 集群不健康(黄色状态),你可能想要调查原因 elasticsearch_index_mismatch: message_html: Elasticsearch索引映射已过时。请运行tootctl search deploy --only=%{value}。 elasticsearch_preset: action: 查看文档 - message_html: 您的Elasticsearch集群有多个节点,但Mastodon未配置好使用它们。 + message_html: 你的Elasticsearch集群有多个节点,但Mastodon未配置好使用它们。 elasticsearch_preset_single_node: action: 查看文档 - message_html: 您的Elasticsearch集群只有一个节点,ES_PRESET应该设置为single_node_cluster。 + message_html: 你的Elasticsearch集群只有一个节点,ES_PRESET应该设置为single_node_cluster。 elasticsearch_reset_chewy: - message_html: 您的Elasticsearch系统索引已过时,可能是由于设置更改导致的。请运行tootctl search deploy --reset-chewy命令来更新它。 + message_html: 你的Elasticsearch系统索引已过时,可能是由于设置更改导致的。请运行tootctl search deploy --reset-chewy命令来更新它。 elasticsearch_running_check: message_html: 无法连接到 Elasticsearch。请检查它是否正在运行,或禁用全文搜索 elasticsearch_version_check: @@ -989,7 +993,7 @@ zh-CN: webhook: Webhook admin_mailer: auto_close_registrations: - body: 由于近期缺乏管理员活动, %{instance} 上的注册已自动切换为需要手动审核,以防止 %{instance} 被潜在的不良行为者用作平台。您可以随时将其切换回开放注册。 + body: 由于近期缺乏管理员活动, %{instance} 上的注册已自动切换为需要手动审核,以防止 %{instance} 被潜在的不良行为者用作平台。你可以随时将其切换回开放注册。 subject: "%{instance} 的注册已自动切换为需要批准" new_appeal: actions: @@ -1004,7 +1008,7 @@ zh-CN: next_steps: 你可以批准此申诉并撤销该审核结果,也可以忽略此申诉。 subject: "%{username} 对 %{instance} 的审核结果提出了申诉" new_critical_software_updates: - body: 新的紧急更新版本Mastodon已经发布,您可能希望尽快更新! + body: 新的紧急更新版本Mastodon已经发布,你可能希望尽快更新! subject: 适用于 %{instance} 的Mastodon紧急更新已经可用。 new_pending_account: body: 新账户的详细信息如下。你可以批准或拒绝此申请。 @@ -1014,7 +1018,7 @@ zh-CN: body_remote: 来自 %{domain} 的用户举报了用户 %{target} subject: 来自 %{instance} 的用户举报(#%{id}) new_software_updates: - body: 新的 Mastodon 版本已发布,您可能想要更新! + body: 新的 Mastodon 版本已发布,你可能想要更新! subject: 适用于 %{instance} 的Mastodon版本更新已经可用! new_trends: body: 以下项目需要审核才能公开显示: @@ -1062,18 +1066,18 @@ zh-CN: auth: apply_for_account: 申请账号 captcha_confirmation: - help_html: 如果您在输入验证码时遇到问题,可以通过%{email} 与我们联系,我们将为您提供帮助。 - hint_html: 只剩最后一件事了!我们需要确认您是一个人类(这样我们才能阻止恶意访问!)。请输入下面的验证码,然后点击“继续”。 + help_html: 如果你在输入验证码时遇到问题,可以通过%{email} 与我们联系,我们将为你提供帮助。 + hint_html: 只剩最后一件事了!我们需要确认你是一个人类(这样我们才能阻止恶意访问!)。请输入下面的验证码,然后点击“继续”。 title: 安全检查 confirmations: awaiting_review: 你的邮箱地址已确认!%{domain} 的工作人员正在审核你的注册信息。如果他们批准了你的账户,你将收到一封邮件通知! - awaiting_review_title: 您的注册申请正在审核中 + awaiting_review_title: 你的注册申请正在审核中 clicking_this_link: 点击此链接 login_link: 登录 - proceed_to_login_html: 现在您可以继续前往 %{login_link} 。 - redirect_to_app_html: 您应该已被重定向到 %{app_name} 应用程序。如果没有,请尝试 %{clicking_this_link} 或手动返回应用程序。 - registration_complete: 您在 %{domain} 上的注册现已完成! - welcome_title: 欢迎您,%{name}! + proceed_to_login_html: 现在你可以继续前往 %{login_link} 。 + redirect_to_app_html: 你应该已被重定向到 %{app_name} 应用程序。如果没有,请尝试 %{clicking_this_link} 或手动返回应用程序。 + registration_complete: 你在 %{domain} 上的注册现已完成! + welcome_title: 欢迎你,%{name}! wrong_email_hint: 如果该邮箱地址不正确,你可以在账户设置中进行更改。 delete_account: 删除帐户 delete_account_html: 如果你想删除你的帐户,请点击这里继续。你需要确认你的操作。 @@ -1111,7 +1115,7 @@ zh-CN: back: 返回 invited_by: 你可以加入%{domain},这是由于你收到了他人的邀请,邀请来自: preamble: 这些由 %{domain} 监察员设置和执行。 - preamble_invited: 在您继续之前,请考虑 %{domain} 的管理员设定的基本规则。 + preamble_invited: 在你继续之前,请考虑 %{domain} 的管理员设定的基本规则。 title: 一些基本规则。 title_invited: 您已经被邀请。 security: 账户安全 @@ -1325,26 +1329,26 @@ zh-CN: too_large: 文件过大 failures: 失败 imported: 已导入 - mismatched_types_warning: 您似乎选择了导入错误的类型,请再次检查。 + mismatched_types_warning: 你似乎选择了导入错误的类型,请再次检查。 modes: merge: 合并 merge_long: 保留现有记录并添加新的记录 overwrite: 覆盖 overwrite_long: 将当前记录替换为新记录 overwrite_preambles: - blocking_html: 您即将使用来自 %{filename} 的最多 %{total_items} 个账户替换您的屏蔽列表。 - bookmarks_html: 您即将使用来自 %{filename} %{total_items} 篇嘟文替换您的书签。 - domain_blocking_html: 您即将使用来自 %{filename} 的最多 %{total_items} 个域名替换您的域名屏蔽列表。 - following_html: 您即将从 %{filename} 关注 %{total_items} 个账户,并停止关注其他任何人。 + blocking_html: 你即将使用来自 %{filename} 的最多 %{total_items} 个账户替换你的屏蔽列表。 + bookmarks_html: 你即将使用来自 %{filename} %{total_items} 篇嘟文替换你的书签。 + domain_blocking_html: 你即将使用来自 %{filename} 的最多 %{total_items} 个域名替换你的域名屏蔽列表。 + following_html: 你即将从 %{filename} 关注 %{total_items} 个账户,并停止关注其他任何人。 lists_html: 你即将用 %{filename} 的内容替换你的列表。新列表中将添加 %{total_items} 个账户。 - muting_html: 您即将使用来自 %{filename} 的最多 %{total_items} 个账户替换您已隐藏的账户列表。 + muting_html: 你即将使用来自 %{filename} 的最多 %{total_items} 个账户替换你已隐藏的账户列表。 preambles: - blocking_html: 您即将从 %{filename} 封锁多达 %{total_items} 个账户。 - bookmarks_html: 您即将把来自 %{filename} %{total_items} 篇嘟文添加到您的书签中。 - domain_blocking_html: 您即将从 %{filename} 屏蔽 %{total_items} 个域名。 - following_html: 您即将从 %{filename} 关注最多 %{total_items} 个账户。 + blocking_html: 你即将从 %{filename} 封锁多达 %{total_items} 个账户。 + bookmarks_html: 你即将把来自 %{filename} %{total_items} 篇嘟文添加到你的书签中。 + domain_blocking_html: 你即将从 %{filename} 屏蔽 %{total_items} 个域名。 + following_html: 你即将从 %{filename} 关注最多 %{total_items} 个账户。 lists_html: 你即将从 %{filename} 中添加最多 %{total_items} 个账户到你的列表中。如果没有可用列表,将创建新的列表。 - muting_html: 您即将从 %{filename} 隐藏 %{total_items} 个账户。 + muting_html: 你即将从 %{filename} 隐藏 %{total_items} 个账户。 preface: 你可以在此导入你在其他实例导出的数据,比如你所关注或屏蔽的用户列表。 recent_imports: 最近导入 states: @@ -1414,7 +1418,7 @@ zh-CN: unsubscribe: action: 是,取消订阅 complete: 已取消订阅 - confirmation_html: 你确定要退订来自 %{domain} 上的 Mastodon 的 %{type} 到您的邮箱 %{email} 吗?您可以随时在邮件通知设置中重新订阅。 + confirmation_html: 你确定要退订来自 %{domain} 上的 Mastodon 的 %{type} 到你的邮箱 %{email} 吗?你可以随时在邮件通知设置中重新订阅。 emails: notification_emails: favourite: 嘟文被喜欢邮件通知 @@ -1428,7 +1432,7 @@ zh-CN: media_attachments: validations: images_and_video: 无法在嘟文中同时插入视频和图片 - not_found: 未发现媒体%{ids} 或已附在另一条嘟文中 + not_found: 媒体 %{ids} 未找到,有可能已随附于另一条嘟文。 not_ready: 不能附加还在处理中的文件。请稍后再试! too_many: 最多只能添加 4 张图片 migrations: @@ -1541,7 +1545,7 @@ zh-CN: expired: 投票已经结束 invalid_choice: 被选中的投票选项不存在 over_character_limit: 每条不能超过 %{max} 个字符 - self_vote: 您不能参与自己发起的投票 + self_vote: 你不能参与自己发起的投票 too_few_options: 至少需要两个选项 too_many_options: 不能超过 %{max} 项 preferences: @@ -1549,7 +1553,7 @@ zh-CN: posting_defaults: 发布默认值 public_timelines: 公共时间轴 privacy: - hint_html: "自定义您希望如何找到您的个人资料和嘟文。启用Mastodon中的各种功能可以帮助您扩大受众范围。请花点时间查看这些设置,确保它们适合您的使用情况。" + hint_html: "自定义你希望如何找到你的个人资料和嘟文。启用Mastodon中的各种功能可以帮助你扩大受众范围。请花点时间查看这些设置,确保它们适合你的使用情况。" privacy: 隐私 privacy_hint_html: 控制你愿意向他人透露多少信息。通过浏览他人的关注列表和查看他们发嘟所用的应用,人们可以发现有趣的用户和酷炫的应用,但你可能更喜欢将其隐藏起来。 reach: 范围 @@ -1564,8 +1568,8 @@ zh-CN: limit_reached: 互动种类的限制 unrecognized_emoji: 不是一个可识别的表情 redirects: - prompt: 如果您信任此链接,请单击以继续跳转。 - title: 您正在离开 %{instance} 。 + prompt: 如果你信任此链接,请单击以继续跳转。 + title: 你正在离开 %{instance} 。 relationships: activity: 账号活动 confirm_follow_selected_followers: 您确定想要关注所选的关注者吗? @@ -1803,22 +1807,22 @@ zh-CN: action: 账户设置 explanation: 你于 %{appeal_date} 对 %{strike_date} 在你账号上做出的处罚提出的申诉已被批准,你的账号已回到正常状态。 subject: 你于 %{date} 提出的申诉已被批准 - subtitle: 您的账户已再次回到良好状态。 + subtitle: 你的账户已再次回到良好状态。 title: 申诉已批准 appeal_rejected: explanation: 你于 %{appeal_date} 对 %{strike_date} 在你账号上做出的处罚提出的申诉已被驳回。 subject: 你于 %{date} 提出的申诉已被驳回 - subtitle: 您的申诉已被驳回。 + subtitle: 你的申诉已被驳回。 title: 申诉已驳回 backup_ready: - explanation: 您之前请求为您的 Mastodon 账户创建一份完整的备份。 + explanation: 你之前请求为你的 Mastodon 账户创建一份完整的备份。 extra: 现在它可以下载了! subject: 你的存档已经准备完毕 title: 存档导出 failed_2fa: details: 以下是该次登录尝试的详情: - explanation: 有人试图登录到您的账户,但提供了无效的辅助认证因子。 - further_actions_html: 如果这不是您所为,您的密码可能已经泄露,建议您立即 %{action} 。 + explanation: 有人试图登录到你的账户,但提供了无效的辅助认证因子。 + further_actions_html: 如果这不是你所为,你的密码可能已经泄露,建议你立即 %{action} 。 subject: 辅助认证失败 title: 辅助认证失败 suspicious_sign_in: @@ -1864,24 +1868,24 @@ zh-CN: apps_ios_action: 从 App Store 下载 apps_step: 下载我们的官方应用。 apps_title: Mastodon应用 - checklist_subtitle: 让我们带您开启这片社交新天地: + checklist_subtitle: 让我们带你开启这片社交新天地: checklist_title: 欢迎清单 edit_profile_action: 个性化 - edit_profile_step: 完善个人资料,提升您的互动体验。 - edit_profile_title: 个性化您的个人资料 + edit_profile_step: 完善个人资料,提升你的互动体验。 + edit_profile_title: 个性化你的个人资料 explanation: 下面是几个小贴士,希望它们能帮到你 feature_action: 了解更多 - feature_audience: Mastodon为您提供了无需中间商即可管理受众的独特可能。Mastodon可被部署在您自己的基础设施上,允许您关注其它任何Mastodon在线服务器的用户,或被任何其他在线 Mastodon 服务器的用户关注,并且不受您之外的任何人控制。 - feature_audience_title: 放手去建立起您的受众 - feature_control: 您最清楚您想在你自己的主页中看到什么动态。没有算法或广告浪费您的时间。您可以用一个账号关注任何 Mastodon 服务器上的任何人,并按时间顺序获得他们发布的嘟文,让您的互联网的角落更合自己的心意。 + feature_audience: Mastodon为你提供了无需中间商即可管理受众的独特可能。Mastodon可被部署在你自己的基础设施上,允许你关注其它任何Mastodon在线服务器的用户,或被任何其他在线 Mastodon 服务器的用户关注,并且不受你之外的任何人控制。 + feature_audience_title: 放手去建立起你的受众 + feature_control: 你最清楚你想在你自己的主页中看到什么动态。没有算法或广告浪费你的时间。你可以用一个账号关注任何 Mastodon 服务器上的任何人,并按时间顺序获得他们发布的嘟文,让你的互联网的角落更合自己的心意。 feature_control_title: 掌控自己的时间线 - feature_creativity: Mastodon支持音频、视频和图片、无障碍描述、投票、内容警告, 动画头像、自定义表情包、缩略图裁剪控制等功能,帮助您在网上尽情表达自己。无论您是要发布您的艺术作品、音乐还是播客,Mastodon 都能为您服务。 + feature_creativity: Mastodon支持音频、视频和图片、无障碍描述、投票、内容警告, 动画头像、自定义表情包、缩略图裁剪控制等功能,帮助你在网上尽情表达自己。无论你是要发布你的艺术作品、音乐还是播客,Mastodon 都能为你服务。 feature_creativity_title: 无与伦比的创造力 - feature_moderation: Mastodon将决策权交还给您。每个服务器都会创建自己的规则和条例,并在站点内施行,而不是像企业社交媒体那样居高临下,这使得它可以最灵活地响应不同人群的需求。加入一个您认同其规则的服务器,或托管您自己的服务器。 + feature_moderation: Mastodon将决策权交还给你。每个服务器都会创建自己的规则和条例,并在站点内施行,而不是像企业社交媒体那样居高临下,这使得它可以最灵活地响应不同人群的需求。加入一个你认同其规则的服务器,或托管你自己的服务器。 feature_moderation_title: 管理,本应如此 follow_action: 关注 follow_step: 关注有趣的人,这就是Mastodon的意义所在。 - follow_title: 个性化您的首页动态 + follow_title: 个性化你的首页动态 follows_subtitle: 关注知名账户 follows_title: 推荐关注 follows_view_more: 查看更多可关注的人 @@ -1892,10 +1896,10 @@ zh-CN: hashtags_view_more: 查看更多热门话题标签 post_action: 撰写 post_step: 向世界打个招呼吧。 - post_title: 发布您的第一条嘟文 + post_title: 发布你的第一条嘟文 share_action: 分享 - share_step: 让您的朋友知道如何在Mastodon找到你。 - share_title: 分享您的Mastodon个人资料 + share_step: 让你的朋友知道如何在Mastodon找到你。 + share_title: 分享你的Mastodon个人资料 sign_in_action: 登录 subject: 欢迎来到 Mastodon title: "%{name},欢迎你的加入!" @@ -1908,12 +1912,12 @@ zh-CN: seamless_external_login: 你通过外部服务登录,因此密码和邮件设置不可用。 signed_in_as: 当前登录的账户: verification: - extra_instructions_html: 提示:您网站上的链接可能是不可见的。重要的部分是 rel="me",它可以防止在具有用户生成内容的网站上冒充身份。您甚至可以在页面头部使用 link 标签而不是 a,但 HTML 必须能够在不执行 JavaScript 的情况下访问。 + extra_instructions_html: 提示:你网站上的链接可能是不可见的。重要的部分是 rel="me",它可以防止在具有用户生成内容的网站上冒充身份。你甚至可以在页面头部使用 link 标签而不是 a,但 HTML 必须能够在不执行 JavaScript 的情况下访问。 here_is_how: 具体方法如下: - hint_html: "在Mastodon上验证您的身份对每个人都是必要的。基于开放网络标准,现在和将来永远免费。您只需要一个被人们认可的个人网站。当您在个人资料中链接到这个网站时,我们会检查该网站是否回链到您的资料,并显示一个指示符号。" - instructions_html: 将下面的代码复制并粘贴到您网站的HTML中。然后在“编辑个人资料”选项卡中的附加字段之一添加您网站的地址,并保存更改。 + hint_html: "在Mastodon上验证你的身份对每个人都是必要的。基于开放网络标准,现在和将来永远免费。你只需要一个被人们认可的个人网站。当你在个人资料中链接到这个网站时,我们会检查该网站是否回链到你的资料,并显示一个指示符号。" + instructions_html: 将下面的代码复制并粘贴到你网站的HTML中。然后在“编辑个人资料”选项卡中的附加字段之一添加你网站的地址,并保存更改。 verification: 验证 - verified_links: 您已验证的链接 + verified_links: 你已验证的链接 webauthn_credentials: add: 添加新的安全密钥 create: diff --git a/config/locales/zh-TW.yml b/config/locales/zh-TW.yml index 97a4399b21..8288e9bfac 100644 --- a/config/locales/zh-TW.yml +++ b/config/locales/zh-TW.yml @@ -23,6 +23,8 @@ zh-TW: admin: account_actions: action: 執行動作 + already_silenced: 此帳號已被靜音。 + already_suspended: 此帳號已被停權。 title: 對 %{acct} 執行站務動作 account_moderation_notes: create: 新增站務記錄 @@ -44,6 +46,7 @@ zh-TW: title: 為 %{username} 變更電子郵件地址 change_role: changed_msg: 成功修改角色! + edit_roles: 管理使用者權限 label: 變更角色 no_role: 沒有角色 title: 為 %{username} 變更角色 @@ -590,6 +593,7 @@ zh-TW: suspend_description_html: 此帳號及其所有內容將不可被存取並且最終被移除,並且無法與之進行互動。三十天內可以撤銷此動作。關閉所有對此帳號之檢舉報告。 actions_description_html: 決定應對此報告採取何種行動。若您對檢舉之帳號採取懲罰措施,則將對他們發送 e-mail 通知,除非選擇了 垃圾郵件 類別。 actions_description_remote_html: 決定將對此檢舉報告採取何種動作。這將僅作用於您的伺服器與此遠端帳號及其內容之通訊行為。 + actions_no_posts: 此報告無任何需要刪除之相關嘟文 add_to_report: 加入更多至報告 already_suspended_badges: local: 已自此伺服器停權