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

[DataGridPro] Fix header filtering with boolean column type #15528

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

k-rajat19
Copy link
Contributor

@k-rajat19 k-rajat19 commented Nov 21, 2024

@mui-bot
Copy link

mui-bot commented Nov 21, 2024

Deploy preview: https://deploy-preview-15528--material-ui-x.netlify.app/

Generated by 🚫 dangerJS against 2d3521d

Copy link
Member

@michelengelen michelengelen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just 2 nitpicks

@@ -314,7 +314,7 @@ const GridHeaderFilterCell = React.forwardRef<HTMLDivElement, GridHeaderFilterCe

const isNoInputOperator = currentOperator.requiresFilterValue === false;

const isApplied = Boolean(item?.value) || isNoInputOperator;
const isApplied = item?.value !== undefined || isNoInputOperator;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same here

Suggested change
const isApplied = item?.value !== undefined || isNoInputOperator;
const isApplied = item?.value != undefined || isNoInputOperator;

@michelengelen michelengelen self-assigned this Nov 21, 2024
@michelengelen michelengelen added bug 🐛 Something doesn't work component: data grid This is the name of the generic UI component, not the React module! feature: Filtering on header Related to the header filtering (Pro) feature labels Nov 21, 2024
@k-rajat19 k-rajat19 marked this pull request as ready for review November 21, 2024 10:52
@michelengelen
Copy link
Member

all right ... I'll let @arminmeh as the main reviewer approve this! 👍🏼

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐛 Something doesn't work component: data grid This is the name of the generic UI component, not the React module! feature: Filtering on header Related to the header filtering (Pro) feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[data grid] boolean headerFilter with option false does not work
3 participants