-
Notifications
You must be signed in to change notification settings - Fork 10
Decision: Impact of Filtering on Item Counts
Thing | Info |
---|---|
Relevant features | Search and Subject page filters |
Date started | 2024-10-16 |
Date finished | 2024-10-25 |
Decision status | Complete |
Summary of outcome | Item counts that we display, both on primary checkbox buttons and on more secondary dropdowns, will show the full count of results based on the current search query, not a reduced count based on what other filters are active. |
On the search result and subject listing pages, users can see a list of regulation (only on search results), public resources (on search results and subject listings) and/or internal resources (on search results and subject listings, but only for authenticated users). They can use filter elements to reduce the number of results they're looking at:
- Primary checkbox buttons for Regulations, Public Resources, and Internal Resources
- Secondary dropdown for Subject (currently does not apply to Regulations)
- Secondary dropdown for Category (does not apply to Regulations)
The search result and subject listing pages use a "counts" API endpoint to retrieve the total number of regulation, public, and internal results for the page they're displayed on.
What is the relationship of all filters, some of which may have already been interacted with, to the counts that are displayed when interacting with a specific filter?
- Item count, once set, is unchanged by interacting with the filters. It shows the full count of results for the result set they are using – the search query if they have searched for something, or the subject if they are on a subject page without a search query – on the following elements:
- Regulation button
- Public resources button
- Internal resources button (if authenticated)
- Subject dropdown (on search results, each subject in the dropdown will show how many public and internal resources it has, even if the user has already checked public or internal)
- Category dropdown (on search results and subject pages, each category will show how many public and internal resources it has, even if the user has already checked public or internal)
The differences between item counts on search results and subject pages are:
- A search result sets the item counts to the number of items in that search query, regardless of how it is filtered.
- A subject page without a search query sets the item counts to the number of items associated with that subject, regardless of how it is filtered. This changes if a search query is entered on the subject page, because then the user is taken to the search result screen.
It's possible that users might anticipate the counts on other filters to be reduced when they click a certain filter. Here's an example scenario:
- An authenticated user comes to the search results page
- The user clicks that they only want public resources
- The buttons for regulations, public resources, and internal resources all show the counts they would have if they were checked (our research shows that this works well)
- They click on the subject dropdown, which shows the subjects, and the counts for each subject, that apply to regulation results, public resources, and internal resources for their search query
- It's possible that users will be confused by this, and assume that the subject counts only apply to public resources since they've done an interaction
If we learn that this isn't a usable situation, we could:
- Allow any filter that is used to affect the counts on all of the other filters
- Allow the secondary subject and category filters to affect the counts on the more primary regulation/public/internal filters
Either of these would be theoretically possible, but would require some additional API and front end work.
Please note that all pages on this GitHub wiki are draft working documents, not complete or polished.
Our software team puts non-sensitive technical documentation on this wiki to help us maintain a shared understanding of our work, including what we've done and why. As an open source project, this documentation is public in case anything in here is helpful to other teams, including anyone who may be interested in reusing our code for other projects.
For context, see the HHS Open Source Software plan (2016) and CMS Technical Reference Architecture section about Open Source Software, including Business Rule BR-OSS-13: "CMS-Released OSS Code Must Include Documentation Accessible to the Open Source Community".
For CMS staff and contractors: internal documentation on Enterprise Confluence (requires login).
- Federal policy structured data options
- Regulations
- Resources
- Statute
- Citation formats
- Export data
- Site homepage
- Content authoring
- Search
- Timeline
- Not built
- 2021
- Reg content sources
- Default content view
- System last updated behavior
- Paragraph indenting
- Content authoring workflow
- Browser support
- Focus in left nav submenu
- Multiple content views
- Content review workflow
- Wayfinding while reading content
- Display of rules and NPRMs in sidebar
- Empty states for supplemental content
- 2022
- 2023
- 2024
- Medicaid and CHIP regulations user experience
- Initial pilot research outline
- Comparative analysis
- Statute research
- Usability study SOP
- 2021
- 2022
- 2023-2024: 🔒 Dovetail (requires login)
- 🔒 Overview (requires login)
- Authentication and authorization
- Frontend caching
- Validation checklist
- Search
- Security tools
- Tests and linting
- Archive