css常用初始化样式

页面初始化样式

*{
    font-family: 'Microsoft YaHei';
}
body {
  font-size: 14px;
	font-family: ' 微软雅黑';
	background-color:#F4F6F9;
	position: relative;
}
ul,
li {
  list-style: none;
}
a {
  text-decoration: none;
  color: #676767;
}
input,
button {
  list-style-type: none;
  border: 0px;
  outline: none;
}
.left{
  float: left !important;
}
.right{
  float: right !important;
}
.clearfix {
  zoom: 1;
}

.clearfix:after {
  content: '';
  width: 0;
  height: 0;
  clear: both;
  display: block;
}

table初始化样式

table,tr,td {
/*此处文字设置为打印页上主表以外的最通用的字体*/
 font-size: 14px;
 font-family: "微软雅黑";
 color: #333333;
 word-break: break-all;
 word-wrap: break-word;
 border-collapse: collapse;
}
.table {
width: 100%;
 // border: 1px solid #000000;
 background-color: #FFFFFF;
 text-align: center;
}
.table tr {
 /* height: 35px; */
}
.table td {
 font-size: 14px;
 /*最普遍的主表字体*/
 font-family: "微软雅黑";
 // border: 1px solid #000000;
padding: 10px 10px;
box-sizing: border-box;
}

滚动条自定义样式

/*定义滚动条高宽及背景 高宽分别对应横竖滚动条的尺寸*/
.scrollbar::-webkit-scrollbar
{
    width: 10px;
    height: 10px;
    background-color: #F5F5F5;
}
/*定义滚动条轨道 内阴影+圆角*/
.scrollbar::-webkit-scrollbar-track
{
    // -webkit-box-shadow: inset 0 0 6px #ccc;
    border-radius: 10px;
    background-color: #F5F5F5;
}
/*定义滑块 内阴影+圆角*/
.scrollbar::-webkit-scrollbar-thumb
{
    border-radius: 10px;
    // -webkit-box-shadow: inset 0 0 6px blue;
    background-color: #d7d7d7;
}

超出显示省略号

.overshow{
overflow: hidden;
text-overflow:ellipsis;
white-space: nowrap;
}

你可能感兴趣的:(常见问题,css初始化样式,滚动条自定义样式,table表格样式)