[data grid] unstable_headerFilters
not showing correct value with controlled filterModel
#10325
Closed
2 tasks done
Labels
bug 🐛
Something doesn't work
component: data grid
This is the name of the generic UI component, not the React module!
Duplicates
Latest version
Steps to reproduce 🕹
Link to live example: https://codesandbox.io/s/musing-lake-9ltjdm?file=/Demo.tsx
Steps:
Current behavior 😯
The header filter input briefly displays the character(s) you typed, but the field is reset to "". The column displays like a filter has been enabled, with the filter menu button visible and the header filter input "X" clear button visible.
Clicking the filter menu button will show the filter correctly.
Expected behavior 🤔
The header filter input should show the correct value of the filter being applied to the column.
Context 🔦
I use a cache to remember the state of the DataGrid when navigating between pages. Most frequently the user will perform a search on the dataset using some specific criteria, investigate a specific row's detail page (on a detail view route), and then they navigate back to the table. Without maintaining the cache, they would have to set up their specific criteria again.
I am using the unstable_headerFilter in an attempt to replicate the behaviour of an old library we are deprecating since we upgraded to using DataGridPremium.
I have also noticed this behaviour doesn't appear when
Your environment 🌎
npx @mui/envinfo
Order ID or Support key 💳 (optional)
71984
The text was updated successfully, but these errors were encountered: