Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Click to add filter" should allow adding inverse of filter #2184

Open
trevan opened this issue Dec 9, 2014 · 8 comments
Open

"Click to add filter" should allow adding inverse of filter #2184

trevan opened this issue Dec 9, 2014 · 8 comments
Labels
Feature:Visualizations Generic visualization features (in case no more specific feature label is available) impact:needs-assessment Product and/or Engineering needs to evaluate the impact of the change. release_note:enhancement Team:Visualizations Visualization editors, elastic-charts and infrastructure

Comments

@trevan
Copy link
Contributor

trevan commented Dec 9, 2014

The filter bar work in #2120 is nice but I sometimes want to be able to click in a visualization and have that value filtered for negated.

@magnusbjarnlid
Copy link

This is also important to us. Being able to remove certain entries is important when analyzing e.g. log files.

@rashidkpc
Copy link
Contributor

Agreed it would be really nice to have the ability to negate a filter before actually running it. Would love input on how the interaction should work here. Modifier key? I want to avoid popups.

@spalger spalger added Feature:Visualizations Generic visualization features (in case no more specific feature label is available) and removed :Discovery labels Jan 2, 2017
@thomasneirynck
Copy link
Contributor

Indeed, you can invert the filter by clicking on the invert-button when the filter is added to the filter-toolbar

In visualizations, you can also click on them on the legend and either apply the filter (the +magnifier) or the inversion of it (the -magnifier).
image

Let's close this since there are two available work-arounds. They also avoid the need for a more complicated UX-flow to do this transparently (e.g. with a modifier-key, or right click with context menu).

@trevan
Copy link
Contributor Author

trevan commented Jan 2, 2017

The problem with the work arounds is that the first one (negate in the filter bar) causes two lookups to elasticsearch which can be pretty intensive. The second one, only is available in a few cases.

So they really aren't that great of work-arounds. Maybe instead of auto submitting the new filter, it can let you edit the filter? This is used when you add more than one filter at a time already (though without the editing).

@trevan
Copy link
Contributor Author

trevan commented Jan 2, 2017

Or, what about allowing plugins to hook into the click event. Then a plugin can add right click menus, modifier-key, etc.

@thomasneirynck
Copy link
Contributor

@trevan fair enough, I'll reopen to reflect that work-arounds have some drawbacks.

As for the API suggestion, a documented public interface for plugins is lacking right now. But it's something that is on the table. The ability to hook into click events (or manage the filter bar for that manner), are things that will need to be taken into account when it does come around. If you have more ideas about what you'd like to see in a public plugin API, please don't hesitate to open an enhancement ticket.

@thomasneirynck thomasneirynck reopened this Jan 2, 2017
@thomasneirynck thomasneirynck changed the title "Click to add filter" should allow negatives "Click to add filter" should allow adding inverse of filter Jan 2, 2017
@ppisljar ppisljar removed the discuss label Jan 4, 2017
@epixa epixa removed the P4 label Apr 25, 2017
@timroes
Copy link
Contributor

timroes commented Jun 7, 2018

I think that issue is no longer relevant? With the filter bar editor you have all the negated options as "operators" available (like is not, is not between, etc.) that will add that filter in a negated state. And visualizations via their legend and discover table currently already support adding negated filters directly.

I think adding some APIs around that should not be tracked in that issue.

I'll close this issue, but please feel free to leave a comment, if you still consider it relevant.

@timroes timroes closed this as completed Jun 7, 2018
@trevan
Copy link
Contributor Author

trevan commented Jun 7, 2018

@timroes, per my comment #2184 (comment), this is not fixed.

This isn't talking about being able to create a negative filter from the filter bar. This is about clicking on items in visualizations and creating a negative. The table and legend are only available for some of the possibilities. And clicking on an item and then negating can be painful to the elasticsearch cluster and causes an unnecessary search.

Maybe if #17844 is done, then at least the extra search can be stopped early. But it would still be nice to not cause the unnecessary search.

#6189 is for the api change.

@timroes timroes reopened this Jun 8, 2018
@timroes timroes added the Team:Visualizations Visualization editors, elastic-charts and infrastructure label Sep 16, 2018
@stratoula stratoula added the impact:needs-assessment Product and/or Engineering needs to evaluate the impact of the change. label May 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature:Visualizations Generic visualization features (in case no more specific feature label is available) impact:needs-assessment Product and/or Engineering needs to evaluate the impact of the change. release_note:enhancement Team:Visualizations Visualization editors, elastic-charts and infrastructure
Projects
None yet
Development

No branches or pull requests

9 participants