diff --git a/app/models/concerns/has_user_settings.rb b/app/models/concerns/has_user_settings.rb index 475ab2c9d2..0fde83954b 100644 --- a/app/models/concerns/has_user_settings.rb +++ b/app/models/concerns/has_user_settings.rb @@ -55,6 +55,10 @@ module HasUserSettings settings['send_without_domain_blocks'] end + def setting_unsafe_limited_distribution + settings['unsafe_limited_distribution'] + end + def setting_stop_emoji_reaction_streaming settings['stop_emoji_reaction_streaming'] end diff --git a/app/models/user_settings.rb b/app/models/user_settings.rb index 7162d847b1..da518d7904 100644 --- a/app/models/user_settings.rb +++ b/app/models/user_settings.rb @@ -31,6 +31,7 @@ class UserSettings setting :reaction_deck, default: nil setting :stop_emoji_reaction_streaming, default: false setting :emoji_reaction_streaming_notify_impl2, default: false + setting :unsafe_limited_distribution, default: false namespace :web do setting :advanced_layout, default: false diff --git a/app/presenters/activitypub/activity_presenter.rb b/app/presenters/activitypub/activity_presenter.rb index fe04396cad..5066a57f8c 100644 --- a/app/presenters/activitypub/activity_presenter.rb +++ b/app/presenters/activitypub/activity_presenter.rb @@ -20,7 +20,7 @@ class ActivityPub::ActivityPresenter < ActiveModelSerializers::Model else ActivityPub::TagManager.instance.uri_for(status.proper) end - elsif status.limited_visibility? && use_bearcap + elsif status.limited_visibility? && use_bearcap && !status.account.user&.setting_unsafe_limited_distribution "bear:?#{{ u: ActivityPub::TagManager.instance.uri_for(status.proper), t: status.capability_tokens.first.token }.to_query}" else status.proper diff --git a/app/views/settings/preferences/other/show.html.haml b/app/views/settings/preferences/other/show.html.haml index c2fe16c16f..c6c267c8c7 100644 --- a/app/views/settings/preferences/other/show.html.haml +++ b/app/views/settings/preferences/other/show.html.haml @@ -42,6 +42,9 @@ .fields-group = ff.input :public_post_to_unlisted, wrapper: :with_label, kmyblue: true, label: I18n.t('simple_form.labels.defaults.setting_public_post_to_unlisted'), hint: I18n.t('simple_form.hints.defaults.setting_public_post_to_unlisted') + .fields-group + = ff.input :unsafe_limited_distribution, wrapper: :with_label, kmyblue: true, label: I18n.t('simple_form.labels.defaults.setting_unsafe_limited_distribution'), hint: I18n.t('simple_form.hints.defaults.setting_unsafe_limited_distribution') + .fields-group = ff.input :default_sensitive, wrapper: :with_label, label: I18n.t('simple_form.labels.defaults.setting_default_sensitive'), hint: I18n.t('simple_form.hints.defaults.setting_default_sensitive') diff --git a/config/locales/simple_form.en.yml b/config/locales/simple_form.en.yml index 17517fc6a2..7cd69e196d 100644 --- a/config/locales/simple_form.en.yml +++ b/config/locales/simple_form.en.yml @@ -247,6 +247,7 @@ en: setting_theme: Site theme setting_trends: Show today's trends setting_unfollow_modal: Show confirmation dialog before unfollowing someone + setting_unsafe_limited_distribution: Send limit posts with unsafe way to other servers setting_use_blurhash: Show colorful gradients for hidden media setting_use_pending_items: Slow mode severity: Severity diff --git a/config/locales/simple_form.ja.yml b/config/locales/simple_form.ja.yml index 5650d7f454..4a830e7c9a 100644 --- a/config/locales/simple_form.ja.yml +++ b/config/locales/simple_form.ja.yml @@ -73,6 +73,7 @@ ja: setting_reject_unlisted_subscription: Misskeyやそのフォーク(Calckeyなど)は、フォローしていないアカウントの「未収載」投稿を **購読・検索** することができます。これはkmyblueの挙動と異なります。そのようなサーバーのうち管理人が指定したものに、指定した公開範囲の投稿を「フォロワーのみ」として配送します。ただし構造上、完璧な対応は困難でたまに未収載として配信されること、ご理解ください setting_show_application: 投稿するのに使用したアプリが投稿の詳細ビューに表示されるようになります setting_stop_emoji_reaction_streaming: 通信容量の節約に役立ちます + setting_unsafe_limited_distribution: Mastodon 3.5、4.0、4.1のサーバーにも限定投稿(相互のみ)が届くようになりますが、安全でない方法で送信します setting_use_blurhash: ぼかしはメディアの色を元に生成されますが、細部は見えにくくなっています setting_use_pending_items: 新着があってもタイムラインを自動的にスクロールしないようにします username: アルファベット大文字と小文字、数字、アンダーバー「_」が使えます @@ -255,6 +256,7 @@ ja: setting_theme: サイトテーマ setting_trends: 本日のトレンドタグを表示する setting_unfollow_modal: フォローを解除する前に確認ダイアログを表示する + setting_unsafe_limited_distribution: 安全でない方法で限定投稿を他サーバーに配信する setting_use_blurhash: 非表示のメディアを色付きのぼかしで表示する setting_use_pending_items: 手動更新モード severity: 重大性