mui / mui-x

MUI X: Build complex and data-rich applications using a growing list of advanced React components, like the Data Grid, Date and Time Pickers, Charts, and more!
https://mui.com/x/
4.05k stars 1.25k forks source link

[data grid] Show All Button Return Empty Object in GridToolbarColumnsButton #12236

Closed Shudhanshu-Appnox closed 5 months ago

Shudhanshu-Appnox commented 6 months ago

Steps to reproduce

Link to live example: (required)

Steps:

  1. Click on the Show All Button in GridToolbarColumnsButton
  2. onColumnVisibilityModelChange returns an empty object in the Model params

Expected behavior

When clicking on the Show all columns the model params in onColumnVisibilityModelChange must return an object where all the columns must have the true value.

Current behavior

When clicking on the Show all columns the model params in onColumnVisibilityModelChange return an Empty Object {}

Context

In the Export Data, we want to have only those columns that are currently visible for that we are using the onColumnVisibilityModelChange props but in the case of the show all it returns an empty object.

Your environment

@mui/x-data-grid": "^6.18.5 ``` Used the Google Chrome Output from `npx @mui/envinfo` goes here. ```

Search keywords: Data Grid, GridToolbarColumnsButton, Show All Order ID: #83077

shaharyar-shamshi commented 6 months ago

Hello @Shudhanshu-Appnox if you can provide some demo link of example it would be great help for us.

Shudhanshu-Appnox commented 6 months ago

Hello @shaharyar-shamshi Link

shaharyar-shamshi commented 6 months ago

Hello @shaharyar-shamshi Link

Cant access I think you need to make it public

michelengelen commented 6 months ago

Hey @Shudhanshu-Appnox ... thanks for raising this issue. 🙇🏼 I did put this on our board for the team to have a look.

Shudhanshu-Appnox commented 6 months ago

@shaharyar-shamshi I have made it public now

Shudhanshu-Appnox commented 6 months ago

Any Update?

michelengelen commented 6 months ago

@mui/xgrid this does seem like expected behavior, since it basically resets to initial state. WDYT?

github-actions[bot] commented 5 months ago

:warning: This issue has been closed. If you have a similar problem but not exactly the same, please open a new issue. Now, if you have additional information related to this issue or things that could help future readers, feel free to leave a comment.

@Shudhanshu-Appnox: How did we do? Your experience with our support team matters to us. If you have a moment, please share your thoughts in this short Support Satisfaction survey.