Skip to content

Instantly share code, notes, and snippets.

@ryanlid
Created July 3, 2017 06:49
Show Gist options
  • Save ryanlid/3b4ae18c9e021de268d3e764420c30ee to your computer and use it in GitHub Desktop.
Save ryanlid/3b4ae18c9e021de268d3e764420c30ee to your computer and use it in GitHub Desktop.
基本样式表
* {
box-sizing: border-box;
}
*:before,
*:after {
box-sizing: border-box;
}
body {
font-family: "Helvetica Neue", Helvetica, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "微软雅黑", Arial, sans-serif;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
height: 100%;
min-height: 100%;
font-size: 16px;
}
html,
body {
height: 100%
}
html,
body,
div,
p,
ul,
li,
dl,
dt,
dd {
padding: 0;
margin: 0;
}
ul,
ol,
dl {
list-style: none;
}
h1,
h2,
h3,
h4,
h5,
h6 {
margin: 0;
padding: 0;
font-size: 16px;
font-weight: normal;
}
.text-center {
text-align: center
}
/*浮动*/
.fl {
float: left;
}
.fr {
float: right;
}
.clearfix:after {
content: "";
display: block;
height: 0;
clear: both;
visibility: hidden;
zoom: 1;
}
/*超出一行隐藏*/
.text-truncate {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.hide {
display: none;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment