Coder Social home page Coder Social logo

[data grid] `CssBaseline`, `Stack` and adding a Border to a DataGrid causes the DataGrid to Infinitely expand Vertically about mui-x HOT 4 OPEN

bethmaloney avatar bethmaloney commented on August 16, 2024
[data grid] `CssBaseline`, `Stack` and adding a Border to a DataGrid causes the DataGrid to Infinitely expand Vertically

from mui-x.

Comments (4)

michelengelen avatar michelengelen commented on August 16, 2024

Hey @bethmaloney ... does this happen to you in production?
I can reproduce the issue in codesandbox, but not in my local instance.
Could be some specific to the styles applied by CSB.
I'll try to find something or add it to the board for deeper investigation

from mui-x.

michelengelen avatar michelengelen commented on August 16, 2024

I cannot reproduce this locally or in a build version!
This has to be specific to the environment.

One thing I could identify is that the Filler gets updated infinitely with a +1 px height. Might be related to the border being applied, since the jumps in height increase if you increase the border width.

I'll add this to the board for a deeper investigation!

CC @romgrk

from mui-x.

bethmaloney avatar bethmaloney commented on August 16, 2024

mui-expanding-grid.zip

@michelengelen I've attached a vite project that demonstrates the issue in a prod build (for me at least).

npm i
npm run build
npm run preview

Note that if you remove <CssBaseline /> the issue goes away.

from mui-x.

romgrk avatar romgrk commented on August 16, 2024

Removing border fixes the issue. The datagrid needs full control of its layout & dimensions to operate properly, so we can't support adding borders in some locations because it modifies the layout of the grid. It's preferable to either modify existing borders' color (e.g. to remove a border, make it transparent), or add borders via CSS that doesn't modify the dimensions (e.g. using floating ::after elements and adding borders on them). Would it be possible for you to use a different styling method?

from mui-x.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.