![](https://img-blog.csdnimg.cn/20201014180756780.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
css
luodao_
这个作者很懒,什么都没留下…
展开
-
currentStyle、getComputedStyle区别
currentStyle可以获取通过内联或外部引入的css样式的值(仅限IE)getComputedStyle是Firefox的#div1 {width:100px; height:100px; background:red;}无标题文档function getStyle(obj, attr){ if(obj.currentStyle){ return o原创 2017-11-23 11:31:32 · 245 阅读 · 0 评论 -
<br>为什么会换行
在浏览器的默认样式中,是这样对br设置的br:before{content:"A"}:before, :after{white-space: pre-line}br中content:"00A"其实是在元素内容前面加上换行键,因为换行键的ASCII码是0A;然后设置white-space,这个属性是用来设置对于元素中空格和换行的处理方式,pre-line则表示合并多个空格并且保留换转载 2017-12-01 10:42:49 · 2370 阅读 · 0 评论 -
多行文字超出隐藏
display:-webkit-box; -webkit-box-orient:vertical; -webkit-line-clamp:2; overflow:hidden;原创 2018-07-16 20:14:08 · 258 阅读 · 0 评论 -
移除HTML5 input在type="number"时的上下小箭头
input::-webkit-outer-spin-button, input::-webkit-inner-spin-button{ -webkit-appearance: none !important; margin: 0; }input[type="number"]{ height: 25px; line-height...原创 2018-07-10 20:32:20 · 443 阅读 · 0 评论 -
css 强制换行
word-wrap: break-word;word-break: break-all;原创 2019-02-21 16:27:50 · 404 阅读 · 0 评论