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

[condensed grid] wrapping columns collapse #4555

Closed
2 tasks
photodow opened this issue Nov 4, 2019 · 1 comment
Closed
2 tasks

[condensed grid] wrapping columns collapse #4555

photodow opened this issue Nov 4, 2019 · 1 comment

Comments

@photodow
Copy link
Contributor

photodow commented Nov 4, 2019

What package(s) are you using?

  • @carbon/grid
  • carbon-components

Detailed description

When using the condensed grid the vertical spacing is put on the bx--row class. This doesn't allow for wrapping of columns. For instance when you have 16 columns setup at (1, 16), and on the medium breakpoint they fall back to (1, 8). To get this the columns begin to wrap. You now have 2 rows of 8, but because the bx--row doesn't wrap with it the spacing in between the columns collapse and butt up against each other.

This is actually two rows of wrapped columns that demonstrates the problem.
image

Is this issue related to a specific component?

condensed grid

What did you expect to happen? What happened instead? What would you like to
see changed?

I expect each column to manage the vertical spacing so when they wrap, they get the proper spacing.

Thinking out loud here we could replace L323-L329 with something like this...

.#{$prefix}--grid--condensed [class*='#{$prefix}--col-'] {
    padding-top: $condensed-gutter / 2;
    padding-bottom: $condensed-gutter / 2;
}

What version of the Carbon Design System are you using?
10.6.0

What offering/product do you work on? Any pressing ship or release dates we
should be aware of?
IBM Dotcom

codesandbox example

https://codesandbox.io/s/unruffled-raman-6rl7u?fontsize=14

@tay1orjones
Copy link
Member

tay1orjones commented Mar 9, 2021

Looks like this was resolved back in #4960

https://codesandbox.io/s/serene-williams-s6pgw?file=/src/index.js

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants