-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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] Pasting in data grids with 200+ rows using TextField in renderEditCell jumps rows when getRowHeight={() => 'auto'}
#14808
Comments
getRowHeight={() => 'auto'}
Strongly related to #14802 ... The main problem seems to be that the grid needs to recalculate the row height and scrolls to the specific row being edited. If I remember this right we had this discussion somewhere else I don't know if this would be a viable solution for you, but you can always disable the virtualization if it fits your use case: Disable virtualization @romgrk might be able to dive a bit deeper into this topic. |
Given the scale of the number of rows in the Data Grid and the content I don't think disabling virtualization would be viable. But let me check with the team that reported it. |
Unfortunately they will not be able to disable virtualization. It sounds like they're already having performance issues. |
Ok, in this case: @romgrk could you have a look? Or provide some additional information? |
I'll have a look this week, I'll close and handle this as part of the other issue. |
This issue has been closed. If you have a similar problem but not exactly the same, please open a new issue. Note @annawatson-wk 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. |
Steps to reproduce
Link to live example: https://stackblitz.com/edit/react-yiiuuw?file=Demo.tsx
Steps:
TextField
.TextField
, note the new row numberCurrent behavior
When you edit the
TextField
and exit theTextfield
the row in the viewport jumps to show another row which was not being edited.Expected behavior
When you edit the
TextField
and exit theTextfield
the row in the viewport shows the same row which was being edited.Context
We had a customer report this jumping behavior when pasting. It's only an issue when using a
TextField
inrenderEditCell
in the column definition andgetRowHeight={() => 'auto'}
. Ideally we'd like the row that was being edited in the viewport in view in some capacity.Your environment
npx @mui/envinfo
Search keywords: data grid premium pro textfield renderEditCell TextField rows scroll jump getRowHeight={() => 'auto'}
Order ID: 82849
The text was updated successfully, but these errors were encountered: