qianduanxiaocaij

直接上代码段:

<div style="background:red;width:400px;height:400px;padding:50px;">
  <div style="background:blue;width:200px;height:200px;margin:50px;">
  </div>
</div>

发现时会产生影响的

子元素的margin 相对于 父元素的 内容区域!

分类:

技术点:

相关文章:

  • 2022-12-23
  • 2021-11-15
  • 2021-12-31
  • 2022-02-09
  • 2021-08-05
  • 2021-05-05
  • 2022-12-23
  • 2021-07-29
猜你喜欢
  • 2021-12-31
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-07-26
  • 2021-11-29
相关资源
相似解决方案