Do not display <languages /> content as search excerpt
Closed, ResolvedPublic1 Estimated Story Points

Description

Go to https://www.mediawiki.org/w/index.php?search="Developer+Experience"&title=Special:Search
See the results not showing an excerpt of the page content but Translate's <languages /> content.

Screenshot from 2023-12-06 12-58-44.png (735×980 px, 119 KB)

Event Timeline

The "Developer Experience" section is empty and by default if no snippet is found, we show the first few words on the page. Which in this case is the list of languages. We might be able to find a simple tweak for this case.

If the template responsible for this language block (Template:Languages?) could wrap this under an html tag that has the class searchaux I believe that this would solve this problem.

Gehel set the point value for this task to 1.Dec 18 2023, 4:28 PM

Change 991662 had a related patch set uploaded (by Ebernhardson; author: Ebernhardson):

[mediawiki/extensions/Translate@master] Consider language selector an auxiliary page search element

https://gerrit.wikimedia.org/r/991662

Note that once deployed this will not instantly fix the pages. The pages will be fixed on the next edit, or when the background reindexer gets to the page (once every ~16 weeks).

Change 991662 merged by jenkins-bot:

[mediawiki/extensions/Translate@master] Consider language selector an auxiliary page search element

https://gerrit.wikimedia.org/r/991662