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

[data grid] Grid does not autosize after cell edit #16306

Open
MordechaiWein opened this issue Jan 22, 2025 · 1 comment
Open

[data grid] Grid does not autosize after cell edit #16306

MordechaiWein opened this issue Jan 22, 2025 · 1 comment
Labels
bug 🐛 Something doesn't work component: data grid This is the name of the generic UI component, not the React module! feature: Editing Related to the data grid Editing feature status: waiting for author Issue with insufficient information

Comments

@MordechaiWein
Copy link

MordechaiWein commented Jan 22, 2025

Steps to reproduce

Steps:

  1. Open this link to live example: (required)

Current behavior

The mui x grid does not autosize correctly

Expected behavior

The grid should auto-size Upon completion of cell edit

Context

I had to do this as a workaround.

  useEffect(() => {
        if (apiRef.current) {
            setTimeout(() => {
                apiRef.current.autosizeColumns({includeOutliers: true})
            }, 5)
        }
    }, [merchants, apiRef])

very upsetting and not working in prod

Your environment

npx @mui/envinfo
  Don't forget to mention which browser you used.
  Output from `npx @mui/envinfo` goes here.

Search keywords: mui

@MordechaiWein MordechaiWein added the status: waiting for maintainer These issues haven't been looked at yet by a maintainer label Jan 22, 2025
@zannager zannager transferred this issue from mui/material-ui Jan 23, 2025
@zannager zannager added the component: data grid This is the name of the generic UI component, not the React module! label Jan 23, 2025
@michelengelen
Copy link
Member

To help us diagnose the issue efficiently, could you provide a stripped-down reproduction test case using the latest version? A live example would be fantastic! ✨

For your convenience, our documentation offers templates and guides on creating targeted examples: Support - Bug reproduction

Just a friendly reminder: clean, functional code with minimal dependencies is most helpful. Complex code can make it tougher to pinpoint the exact issue. Sometimes, simply going through the process of creating a minimal reproduction can even clarify the problem itself!

Thanks for your understanding! 🙇🏼

@michelengelen michelengelen added bug 🐛 Something doesn't work status: waiting for author Issue with insufficient information and removed status: waiting for maintainer These issues haven't been looked at yet by a maintainer labels Jan 23, 2025
@michelengelen michelengelen changed the title MUI X Data Grid autosizing issue [data grid] Grid does not autosize after cell edit Jan 23, 2025
@michelengelen michelengelen added the feature: Editing Related to the data grid Editing feature label Jan 23, 2025
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: Editing Related to the data grid Editing feature status: waiting for author Issue with insufficient information
Projects
None yet
Development

No branches or pull requests

3 participants