.one-pixel {
position: relative;
&::after {
content: '';
display: block;
position: absolute;
width: 100%;
left: 0;
top: 0;
height: 1px;
background-color: #f2f2f2;
transform: scaleY(0.5);
-webkit-transorm: scaleY(0.5);
-moz-transorm: scaleY(0.5);
}
}
上面是水平的,
下面是垂直的
.one-pixel {
position: relative;
&::before {
content: '';
display: block;
position: absolute;
width: 1px;
left: 0;
top: 0;
height: 100%;
background-color: #f2f2f2;
transform: scaleX(0.5);
-webkit-transorm: scaleX(0.5);
-moz-transorm: scaleX(0.5);
}
}