WordPress / gutenberg

The Block Editor project for WordPress and beyond. Plugin is available from the official repository.
https://wordpress.org/gutenberg/
Other
10.48k stars 4.18k forks source link

Give posts (any type) higher priority in link search results #63683

Open richtabor opened 3 months ago

richtabor commented 3 months ago

In LinkControl you can search for content existing on your site. This is great, but I did find that attachments were surfaced higher in search results than posts matching the search requirements.

I propose that pages and posts of all type are prioritized in the search results, above all others. It's much more likely to link to pages and posts, than to attachments.

Visual

Maintain a consistent layout and style across patterns while

noisysocks commented 3 months ago

I propose that pages and posts of all type are prioritized in the search results, above all others.

Take this too literally and we'll cause a regression of https://github.com/WordPress/gutenberg/issues/56478 😀 I think we want to prioritise posts and pages but not always place them above every other result. It's important that users can easily link to tags and categories especially from the Navigation block.

richtabor commented 3 months ago

I'd say you are likely to search for and link a page many times more likely than a tag or category archive.

I would say given a page, tag, and attachment matched with patterns, the page should be first in that list.

Perhaps deprioritizing attachments would meet the expectations better?

noisysocks commented 3 months ago

Yeah in your example screenshot I'd expect Composing with patterns to be first but if you searched for "patterns-1" I'd expect patterns-1 to appear first.

The key thing to bear in mind is that we don't want to regress https://github.com/WordPress/gutenberg/issues/56478 as that bug made creating some types of navigation basically impossible.

I think giving posts a slight (25%? need to play with the exact number) boost and attachments a slight penalty (25%?) should work.

richtabor commented 3 months ago

I'm down for trying that.