![](https://img-blog.csdnimg.cn/20201014180756916.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
css
css相关
hellohello3306
这个作者很懒,什么都没留下…
展开
-
同时解决高度塌陷和外边距重叠问题
/* clearfix 这个样式可以同时解决高度塌陷和外边距重叠的问题, 当你在遇到这些问题时,直接使用clearfix这个类即可 */ .clearfix::before, .clearfix::after{ content: ''; display: table; clear: both; } 使用: <div class="box1 clearfix"> .原创 2021-07-17 16:32:02 · 90 阅读 · 0 评论 -
让一个文字在父元素中垂直居中
让一个文字在父元素中垂直居中只需要将父元素的line-height设置成与父元素的height一样的值即可。原创 2021-07-13 12:13:49 · 221 阅读 · 0 评论 -
清除浏览器默认样式reset.css
/* v2.0 | 20110126 http://meyerweb.com/eric/tools/css/reset/ License: none (public domain) */ html, body, div, span, applet, object, iframe, h1, h2, h3, h4, h5, h6, p, blockquote, pre, a, abbr, acronym, address, big, cite, code, del, dfn, em, img, in.原创 2021-07-13 10:01:45 · 148 阅读 · 0 评论