css样式初始化文件夹,CSS 样式初始化

去除浏览器对html的附加样式,避免不同浏览器之间的样式差异,给前端开发提供统一的样式基础。附加样式:

.clearfix - 清除浮动

.wordsBreak - 允许文本在任意位置的换行

.ellipsis - 超长文本截断,以省略号显示

@charset "utf-8";

body,div,dl,dt,dd,ul,ol,li,h1,h2,h3,h4,h5,h6,form,input,button,textarea,p,table,th,td,section,img{

margin:0;

padding:0;

-moz-box-sizing: border-box;

-webkit-box-sizing: border-box;

box-sizing: border-box;

}

article, aside, details, figcaption, figure, footer, header, menu, nav, section {

display: block;

margin:0;

padding:0;

-moz-box-sizing: border-box;

-webkit-box-sizing: border-box;

box-sizing: border-box;

}

ol,ul,li,dl,dt,dd {

list-style:none;

}

button, input, select, textarea {

font-family: Helvetica,Tahoma,Arial,"Helvetica Neue","Hiragino Sans GB","Microsoft YaHei";

-webkit-appearance:none;

-moz-appearance:none;

appearance:none;

outline: none;

border-radius: 0;

border: 1px solid #ccc;

}

i,em{

font-style:normal;

}

img {

border:none;

}

table{

border-collapse:collapse;

border-spacing:0;

}

html,body {

100%;

height: 100%;

background: #fff;

font-size: 14px;

line-height: 1.4;

font-family: Helvetica,Tahoma,Arial,"Helvetica Neue","Hiragino Sans GB","Microsoft YaHei";

color: #313135;

-webkit-text-size-adjust:100%;

-ms-text-size-adjust: 100%;

text-rendering: optimizelegibility;

}

a,a:hover,a:link,a:visited,a:active {

color: #313135;

text-decoration:none;

}

p,.wordsBreak{

word-wrap:break-word;

word-break:break-all;

}

.clearfix:after {

content: ".";

display: block;

height:0;

clear:both;

visibility: hidden;

}

.clearfix {

*zoom:1;

}

.ellipsis{

overflow: hidden;

white-space: nowrap;

text-overflow: ellipsis;

}

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值