Re: [csswg-drafts] [css-box] Explicit control over margin collapsing

> I agree that margin collapsing should be restricted to block layout and that Flexbox should rather get a flex-gap property controlling the distances between the flex items, which would serve the given use case and also align it more with the Grid specification. And this approach is already discussed in #592.

Yup (tho it needs two - main-gap and cross-gap - just like grid has row-gap and column-gap).

In general, we *do not* want margin-collapsing in Grid or Flex. Collapsing in Grid simply can't happen (a grid item can border multiple elements on a given side with different margins), and in Flex it's not actually desired (you instead want to "collapse away" the margins touching the flex container, which is a different behavior).  Gaps do what we want in Grid, and need to be added to Flexbox.

Closing in favor of #592 

-- 
GitHub Notification of comment by tabatkins
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/1324#issuecomment-311176689 using your GitHub account

Received on Monday, 26 June 2017 20:44:48 UTC