FilterDropdown closes after selecting value without filtering
I have a table that have dropdown filters. For some reason when I updated antd to the latest version, it stopped working as expected. When I select value the dropdown disapears. So i can't press "Filter" button.
6 Replies
Hi @fristyr. I'm kapa.ai, your friendly support bot. I will try to answer your question by searching through the knowledge base. :wave:
----------------------
Based on the information provided in the knowledge sources, it appears that this issue has been addressed in a previous version of refine. The problem you're describing seems similar to an issue that was reported and fixed in the past.
According to the Github issue #1711, there was a bug where filters could only be applied immediately, and the filter dropdown would close after selection without applying the filter. This issue was resolved in version 3.14.1 of refine.
To solve your problem, you could try the following steps:
1. Make sure you're using the latest version of
@refinedev/antd
and @refinedev/core
.
2. If you're using the <FilterDropdown>
component, ensure you're passing all the necessary props from the Table.Column
's filterDropdown
prop. Here's an example of how it should be used:
3. If the issue persists, you might need to check if you're using the mapValue
function correctly in your <FilterDropdown>
component. The mapValue
function is used to transform the selectedKeys
based on certain events. You can find more information about this in the FilterDropdown documentation.
If these steps don't resolve your issue, it's possible that there's a new bug introduced in the latest version of Ant Design that's not yet addressed in refine. In that case, you might want to consider opening a new issue on the refine GitHub repository with a reproducible example of your problem.
----------------------
Note: you can ask me a follow up question by @ mentioning me again :speech_balloon:
----------------------<@757638374881493022> Kapa.ai is still learning and improving, please let me know how I did by reacting below.
fair-roseOP•5w ago
@kapa.ai Yes I am already doing everything that was described. It's probably a new bug
Let me check the knowledge base for you again. One moment! :books:
----------------------
I understand your frustration. Based on your confirmation that you've already implemented the suggested solutions and are still experiencing the issue, it does indeed seem like this could be a new bug, possibly related to the latest version of Ant Design that you mentioned updating to.
Given that this appears to be a new issue not covered in the existing knowledge sources, I would recommend the following steps:
1. Create a minimal reproducible example of your issue.
2. Open a new issue on the refine GitHub repository. When reporting the bug, be sure to include:
- The versions of
@refinedev/antd
, @refinedev/core
, and antd
that you're using
- Your minimal reproducible example
- A clear description of the expected behavior versus the actual behavior you're seeing
3. In the meantime, if possible, you might want to consider temporarily rolling back to a previous version of Ant Design where the filter dropdown was working correctly for you.
If you need guidance on how to open an issue or create a reproducible example, you can refer to the refine GitHub repository for their contribution guidelines.
The refine team is generally responsive to bug reports, and this will help them investigate and potentially fix the issue in a future release.
----------------------
Note: you can ask me a follow up question by @ mentioning me again :speech_balloon:
----------------------<@757638374881493022> Kapa.ai is still learning and improving, please let me know how I did by reacting below.
foreign-sapphire•4w ago
Hello @fristyr, thank you for the bug report.
It seems some others have mentioned this issue too, and I’ll look for a solution.
issue:https://github.com/ant-design/ant-design/issues/52282
Could you create an issue on the Refine repo with a reproducible example? It will make it easier to track.
GitHub
Bug: Antd 5.23 Dropdown misplaces/flashes children unless forwardRe...
Reproduction link Steps to reproduce Steps to reproduce: Create new React 19 project with Antd 5.23 Add @ant-design/v5-patch-for-react-19 and import it Render Dropdown with custom component as chil...