Allow toggling focus filters independently #6070
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR changes the focus filter controls to better support the existence of multiple focus filters.
On the main branch, all the active focus filters are combined into a single description, and there is one toggle button that activates / deactivates all of them. Here is a context where there is both a user filter and a page range filter active. This would represent for example a scenario where a teacher is grading a specific student in an ebook assignment where a page range is specified for the assignment:
The fact that we have two filters but one button leads to confusing labeling when we try to reflect the state when it is on/off. Here is the button after toggling "Show all":
On this branch, the two filters are represented as independent toggles (note the button presentation is not final, this PR is focused on the logical UI change):
With the page range filter deactivated:
Combined with a filter query:
The revised UI has several advantages over the previous approach:
There are some further changes planned but not implemented in this PR: