Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FilterLiveSearch input cleared on navigation but filter remains #6052

Closed
ryan-dorman opened this issue Mar 17, 2021 · 1 comment · Fixed by #6066
Closed

FilterLiveSearch input cleared on navigation but filter remains #6052

ryan-dorman opened this issue Mar 17, 2021 · 1 comment · Fixed by #6066
Labels

Comments

@ryan-dorman
Copy link

What you were expecting:
When filtering a List with FilterLiveSearch the correct filter results display in the List. If you click on a record in the List or navigate to another view and then come back to the List it should still be filtered. Further, all filter components (e.g., FilterListItem, FilterLiveSearch , etc.) should indicate what filters are currently active.

What happened instead:
The FilterLiveSearch component no longer has any text input or indicates a search filter is active, but the List results are still filtered by the search. To clear the active filter you must reload the page or search for another term.

Steps to reproduce:

  • Go to the Customers resource in the demo: https://marmelab.com/react-admin-demo/#/customers
  • Type a partial name into the FilterLiveSearch input such as 'Ra'
  • Take note of the filtered List results
  • Navigate to another resource like 'Posters'
  • Return to the Customers List and notice the FilterLiveSearch is empty but the list results are still filtered
  • Reload the page to clear the search filter and see the original Customer list

Environment
React-admin version: 3.12.1
React version: 17.0.1
Browser: Chrome

@fzaninotto fzaninotto added the bug label Mar 18, 2021
@fzaninotto
Copy link
Member

Indeed, that's a bug. Thanks for reporting!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants