fix: can't custom hairline border color (#4939)

This commit is contained in:
neverland 2019-11-06 10:21:23 +08:00 committed by GitHub
parent 80d8ef1ae2
commit 662a8da491
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,3 +1,5 @@
@import '../var';
.hairline-common() {
position: absolute;
box-sizing: border-box;
@ -5,23 +7,23 @@
pointer-events: none;
}
.hairline(@border-color: #ebedf0) {
.hairline(@color: @border-color) {
.hairline-common();
top: -50%;
right: -50%;
bottom: -50%;
left: -50%;
border: 0 solid @border-color;
border: 0 solid @color;
transform: scale(0.5);
}
.hairline-bottom(@border-color: #ebedf0, @left: 0) {
.hairline-bottom(@color: @border-color, @left: 0) {
.hairline-common();
right: 0;
bottom: 0;
left: @left;
border-bottom: 1px solid @border-color;
border-bottom: 1px solid @color;
transform: scaleY(0.5);
}