From ad44d832b8eaf42526b7bb26c94b39bfa6795457 Mon Sep 17 00:00:00 2001 From: Jeong Arm Date: Tue, 17 Oct 2023 23:12:03 +0900 Subject: [PATCH] Support "in:public" search filter (#26976) --- app/javascript/mastodon/features/compose/components/search.jsx | 2 +- app/lib/search_query_transformer.rb | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/app/javascript/mastodon/features/compose/components/search.jsx b/app/javascript/mastodon/features/compose/components/search.jsx index dfbfa98f5e9793..2525df77933254 100644 --- a/app/javascript/mastodon/features/compose/components/search.jsx +++ b/app/javascript/mastodon/features/compose/components/search.jsx @@ -64,7 +64,7 @@ class Search extends PureComponent { { label: <>before: , action: e => { e.preventDefault(); this._insertText('before:'); } }, { label: <>during: , action: e => { e.preventDefault(); this._insertText('during:'); } }, { label: <>after: , action: e => { e.preventDefault(); this._insertText('after:'); } }, - { label: <>in: , action: e => { e.preventDefault(); this._insertText('in:'); } } + { label: <>in: , action: e => { e.preventDefault(); this._insertText('in:'); } } ]; setRef = c => { diff --git a/app/lib/search_query_transformer.rb b/app/lib/search_query_transformer.rb index a45ae3d09bc1a7..927495eace9795 100644 --- a/app/lib/search_query_transformer.rb +++ b/app/lib/search_query_transformer.rb @@ -58,6 +58,8 @@ def indexes case @flags['in'] when 'library' [StatusesIndex] + when 'public' + [PublicStatusesIndex] else [PublicStatusesIndex, StatusesIndex] end