Automattic / Automattic/jetpack

Search: allow excluding results with a filter rather than only including

Open
#17,869 1 comment 0 reactions 0 assignees View on GitHub
[Feature] Search Enhancement
Dominant language
PHP
Stars
1.8k
Forks
898
Avg merge
1d 18h
Merged PRs (30d)
774

Description

#### Is your feature request related to a problem? Please describe.

For large sites it is sometimes helpful to exclude a bunch of results that have a certain tag/category/etc (a8c FG is a good example).

#### Describe the solution you'd like

The filtering is easy, the UX is not as easy. Ideally something visual where the existing filters can either exclude or include:
- toggle the checkbox between three states instead of the current two
- offer two buttons on each item so you can exclude or include with one click (more discoverable). Kibana uses +/- inside of a magnifying glass (which is also non-obvious).
- ???

I think all solutions become problematic because they will complicate our empty states and the user will end up at deadends where there are no results. All exacerbated by:
- https://github.com/Automattic/jetpack/issues/14179
- https://github.com/Automattic/jetpack/issues/13814
- https://github.com/Automattic/jetpack/issues/8716

#### Describe alternatives you've considered

We could add some special syntax to the search box (`-term_to_exclude`) and use that. I don't like it being so hidden. Almost no one uses these.

#### Additional context

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.