Skip to content

[css2] Fix wording for magins collapsing#13699

Open
Psychpsyo wants to merge 1 commit intow3c:mainfrom
Psychpsyo:patch-22
Open

[css2] Fix wording for magins collapsing#13699
Psychpsyo wants to merge 1 commit intow3c:mainfrom
Psychpsyo:patch-22

Conversation

@Psychpsyo
Copy link
Copy Markdown
Contributor

This matches the notes below that section and also matches implementations.
Consider:

<!DOCTYPE html>
Foo
<p><span style="display: block; margin-block: 1em"></span></p>
Bar

The current spec suggests that, since this paragraph has an in-flow child, its margins should not collapse, when in reality, all the margins here collapse into a single 1em gap, because there's nothing in-between.

This matches the notes below and also matches implementations.
@Psychpsyo
Copy link
Copy Markdown
Contributor Author

I'm also wondering whether or not the spec should really say "zero computed min-height" and "zero or auto computed height".
Since I can set either of these to fit-content on the paragraph in my example above and the margins still collapse.
In this case, the computed value is fit-content, not zero or auto.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant