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

[css2.1] specification #192

Open
teazean opened this issue Dec 7, 2017 · 1 comment
Open

[css2.1] specification #192

teazean opened this issue Dec 7, 2017 · 1 comment

Comments

@teazean
Copy link
Owner

teazean commented Dec 7, 2017

最终重新回顾一下css的specification,准备阅读一下里面的一些基本章节,做一些知识点的纪要。

@teazean
Copy link
Owner Author

teazean commented Dec 7, 2017

Section 8:Box Model

margin

  1. margin percent value: The percentage is calculated with respect to the width of the generated box's containing block. Note that this is true for 'margin-top' and 'margin-bottom' as well. If the containing block's width depends on this element, then the resulting layout is undefined in CSS 2.1.

  2. margin collapse:

    • Horizontal margins never collapse.
    • 其他的情况:规范写的太深奥了,还是看 mdn文档

padding

  1. padding percent value: The percentage is calculated with respect to the width of the generated box's containing block, even for 'padding-top' and 'padding-bottom'. If the containing block's width depends on this element, then the resulting layout is undefined in CSS 2.1.

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

No branches or pull requests

1 participant