Special-case 'me' values in search queries (#11043)

This commit is contained in:
DS Boyce
2026-07-02 09:35:57 -07:00
committed by GitHub
parent 40df0d773a
commit b0a40145e9
6 changed files with 45 additions and 39 deletions
@@ -26,6 +26,23 @@ describe(`extractSearchPostsParams`, () => {
input: `cats to:alice`,
output: {q: `cats`, mentions: `alice`},
},
// `me` is resolved by the backend, so the :me operators stay in q verbatim
// instead of being lifted into author/mentions.
{
name: `keeps from:me in q verbatim`,
input: `cats from:me`,
output: {q: `cats from:me`},
},
{
name: `keeps to:me in q verbatim`,
input: `cats to:me`,
output: {q: `cats to:me`},
},
{
name: `keeps mentions:me in q verbatim`,
input: `cats mentions:me`,
output: {q: `cats mentions:me`},
},
{
name: `accumulates multiple hashtags into tag[]`,
input: `#cats #dogs`,