If the child is position:absolute and the parent is overflow:hidden, why does the child overflow?

前端 未结 4 1584
无人共我
无人共我 2020-12-11 07:24

If the child is position:absolute, the parent is overflow:hidden, and the parent is position:static, the child still overflows:

<
4条回答
  •  情书的邮戳
    2020-12-11 07:36

    The relative value for the position property is very similar to that of the static value. The primary difference is that the relative value accepts the box offset properties top, right, bottom, and left. These box offset properties allow the element to be precisely positioned, shifting the element from its default position in any direction

提交回复
热议问题