v-area-picker
Version:
34 lines (30 loc) • 719 B
text/stylus
/* 1个像素的边框 */
$border {
position: absolute;
content: ' ';
top: 0;
left: 0;
-webkit-transform-origin: top left;
transform-origin: top left;
width: 100%;
height: 100%;
-webkit-transform: scale(1);
transform: scale(1);
pointer-events: none;
for $i in 2 .. 3 {
@media (-webkit-min-device-pixel-ratio: $i), (min-device-pixel-ratio: $i) {
width: $i * 100 + '%';
height: $i * 100 + '%';
-webkit-transform: scale((1 / $i));
transform: scale((1 / $i));
}
}
}
/* 下边框 */
border1px-bottom($border-color = #cccccc, $border-style = solid) {
position: relative;
&:after {
border-bottom: 1px $border-style $border-color;
@extend $border;
}
}