DataTable cannot programmatically clear filters
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 24.4k
- Forks
- 2.3k
- Avg merge
- 2d 7h
- Merged PRs (30d)
- 13
Description
Describe your context
dash 2.3.0
dash-bootstrap-components 1.0.3
dash-core-components 2.0.0
dash-daq 0.5.0
dash-html-components 2.0.0
dash-table 5.0.0
Describe the bug
There is no way to programmatically clear a filter applied to a DataTable column via a callback. This has been documented by several other users in both the community forum and the old dash-table repo prior to the 2.0 release.
References:
- Community forum
- #715 from old repo
According to the references above, the filter_query property only reacts to valid, non-empty strings like '{col_1} = abc'. Requiring a valid, non-empty string prevents resetting the filter_query to an empty state.
Expected behavior
There should be a way to clear this displayed filter text via a callback. Possibly through some new operator in the filter_query syntax like '{col_1}' EMPTY
Screenshots
See references above.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing the DataTable filter_query behavior described in the issue and the linked community forum discussion and old dash-table issue #715. Determine how a callback can clear the displayed column-filter text, and consider whether the existing syntax or a new operator should define the completed behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- data-visualization, frontend
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100