Repository navigation
Open
Labels
Description
Problem
A :filterable: table puts its search box, its dropdown filters, and its "Showing N of M" count in one wrapping row above the table. On tables with several dropdowns, that row gets hard to use:
- The search box gets squeezed. Each dropdown takes space from the search box, and the controls wrap unevenly across several rows.
- Controls push the data down. A table with five dropdowns shows several rows of controls before any data. On the prototype prebuilt detection rules table, the controls take most of the first screen.
- It's hard to tell which filters are on. A dropdown set to a value looks the same as one set to All, so readers have to read every dropdown.
- Undoing filters takes several steps. Readers reset each dropdown and clear the search box one at a time.
- An empty result looks broken. When nothing matches, the table shows only its header row, with no explanation.
#4914 lets authors choose which columns get dropdowns, which makes tables with several deliberate dropdowns more common. These problems grow with them.
Proposal
Rework the controls so they stay out of the way until readers need them:
- Put the search box on its own row, with a Filters button beside it.
- Collapse the dropdowns behind the Filters button. Readers see the table first. The button shows how many filters are on, so readers can tell the table is narrowed even with the panel closed. On a table with no dropdowns, the button doesn't appear.
- Line the dropdowns up in equal columns, each with its label above it, wrapping into fewer columns on narrow screens.
- Highlight a dropdown that's narrowing the table, so readers can see at a glance which filters are on.
- Add a Clear button next to the count that resets the search and every dropdown at once.
- Explain an empty table. When nothing matches, show a message under the header row that names what's narrowing it: "No rows match your search.", "No rows match your filters.", or "No rows match your search and filters."
The controls must stay accessible: the Filters button announces whether the panel is open and how many filters are on, and the count keeps announcing "Showing N of M".
Related
- Let authors choose which columns get dropdowns in a
:filterable:table #4914 and Let authors choose which columns a filterable table offers as dropdowns #4915 add author control over which columns get dropdowns. - Let authors pin the first column of a wide table #4917 and Add a
:pin-first-column:option to the table directive #4918 add:pin-first-column:for wide tables, which filterable tables often are.
Activity