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

[Masonry] has NaNpx height & margin. #33141

Closed
2 tasks done
ronaklalwaniii opened this issue Jun 14, 2022 · 5 comments · Fixed by #33384
Closed
2 tasks done

[Masonry] has NaNpx height & margin. #33141

ronaklalwaniii opened this issue Jun 14, 2022 · 5 comments · Fixed by #33384
Assignees
Labels
bug 🐛 Something doesn't work component: masonry This is the name of the generic UI component, not the React module! package: lab Specific to @mui/lab

Comments

@ronaklalwaniii
Copy link

Duplicates

  • I have searched the existing issues

Latest version

  • I have tested the latest version

Current behavior 😯

Masonary doesn't respect the columns refer to the attached image.

The problem seems to be with the height & margin of MuiMasonry-root class.

The height & margin properties have NaNpx value refer to the attached image.

I have changed the spacing to rem like shown in the docs that's the reason for NaN refer to the attached image.

What do you suggest to fix this?

image

image

image

Expected behavior 🤔

It should work like a normal Masonary.

Steps to reproduce 🕹

Steps:

  1. Just copy the masonary from MUI example.
  2. Change the spacing to rem like shown in the attached image

image

Context 🔦

No response

Your environment 🌎

Using chrome browser

`npx @mui/envinfo`
   System:
    OS: Windows 10 10.0.19044
  Binaries:
    Node: 16.15.0 - C:\Program Files\nodejs\node.EXE
    Yarn: 1.22.18 - ~\AppData\Roaming\npm\yarn.CMD
    npm: 8.5.5 - C:\Program Files\nodejs\npm.CMD
  Browsers:
    Chrome: Not Found
    Edge: Spartan (44.19041.1266.0), Chromium (102.0.1245.39)
  npmPackages:
    @emotion/react: ^11.7.0 => 11.9.0 
    @emotion/styled: ^11.6.0 => 11.8.1 
    @mui/base:  5.0.0-alpha.82 
    @mui/lab: ^5.0.0-alpha.80 => 5.0.0-alpha.83 
    @mui/material: ^5.6.4 => 5.8.1 
    @mui/private-theming:  5.8.0 
    @mui/styled-engine:  5.8.0 
    @mui/system:  5.8.1 
    @mui/types:  7.1.3 
    @mui/utils:  5.8.0 
    @mui/x-data-grid: 5.10.0 => 5.10.0 
    @mui/x-date-pickers:  5.0.0-alpha.1 
    @types/react: ^18.0.8 => 18.0.9 
    react: ^18.1.0 => 18.1.0 
    react-dom: ^18.1.0 => 18.1.0 
    typescript: ^4.6.4 => 4.7.2 
@ronaklalwaniii ronaklalwaniii added the status: waiting for maintainer These issues haven't been looked at yet by a maintainer label Jun 14, 2022
@vrushank
Copy link

+1

1 similar comment
@ghost
Copy link

ghost commented Jun 18, 2022

+1

@neelbrahmakshatriya
Copy link

+1

@ronaklalwaniii
Copy link
Author

Any update?

@hbjORbj hbjORbj changed the title Masonary has NaNpx height & margin. [Masonry] has NaNpx height & margin. Jun 27, 2022
@hbjORbj hbjORbj added bug 🐛 Something doesn't work package: lab Specific to @mui/lab component: masonry This is the name of the generic UI component, not the React module! and removed status: waiting for maintainer These issues haven't been looked at yet by a maintainer labels Jun 27, 2022
@hbjORbj
Copy link
Member

hbjORbj commented Jun 30, 2022

I am working on a fix right now. Will update you soon.

UPDATE: I just opened a pull request for the fix.

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: masonry This is the name of the generic UI component, not the React module! package: lab Specific to @mui/lab
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants