-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
[DataGrid] Fix order of spread props on toolbar items #15556
[DataGrid] Fix order of spread props on toolbar items #15556
Conversation
Deploy preview: https://deploy-preview-15556--material-ui-x.netlify.app/ |
Cherry-pick PRs will be created targeting branches: v7.x |
onClick={showColumns} | ||
{...rootProps.slotProps?.baseButton} | ||
{...buttonProps} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hey @KenanYusuf i am seeing that this causes the showColumns function to not being called if the onClick is defined by the consumer
meaning the popover is not displayed to the user
the usecase for this would be to execute some code when the button is clicked (but the popover should still be shown)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for raising @marcelo-cardozo - I've created an issue so you can track the fix here #16354
Fixed the order of props being spread to toolbar items. Applying props to the individual toolbar items should take precedence over slot props applied at the root level.
Also added the ability to override badge props for
GridToolbarFilterButton
.Fixes #13416
Closes #15550