html块状元素高度,CSS:如何计算块元素的高度?
Block-level non-replaced elements in normal flow when ‘overflow’ computes to ‘visible’
This section also applies to block-level non-replaced elements in normal flow when ‘overflow’ does not compute to ‘visible’ but has been propagated to the viewport.
[. . .]
If ‘height’ is ‘auto’,the height depends on whether the element has any block-level children and whether it has padding or borders:
If it only has inline-level children,the height is the distance between the top of the topmost line Box and the bottom of the bottommost line Box.
If it has block-level children,the height is the distance between the top border-edge of the topmost block-level child Box that does not have margins collapsed through it and the bottom border-edge of the bottommost block-level child Box that does not have margins collapsed through it.
[. . . ]
Only children in the normal flow are taken into account (i.e.,floating Boxes and absolutely positioned Boxes are ignored,and relatively positioned Boxes are considered without their offset).
[. . . ]
Block-level,non-replaced elements in normal flow when ‘overflow’ does not compute to ‘visible’ (except if the ‘overflow’ property’s value has been propagated to the viewport).
If ‘height’ is ‘auto’,07001.
總結
以上是生活随笔為你收集整理的html块状元素高度,CSS:如何计算块元素的高度?的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 在大城市租房子,多少工资可以整租自己的房
- 下一篇: 60今天去了自助洗车的店子洗车,刚开始没