mirror of
https://github.com/youzan/vant.git
synced 2025-10-19 18:14:13 +00:00
[Improvement] Field: support clearable (#1309)
This commit is contained in:
@@ -30,5 +30,6 @@
|
||||
&-detail__finish {
|
||||
color: $blue;
|
||||
font-size: 12px;
|
||||
display: block;
|
||||
}
|
||||
}
|
||||
|
@@ -9,6 +9,11 @@
|
||||
position: relative;
|
||||
}
|
||||
|
||||
&__body {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
&__control {
|
||||
border: 0;
|
||||
margin: 0;
|
||||
@@ -25,17 +30,24 @@
|
||||
}
|
||||
}
|
||||
|
||||
&__icon {
|
||||
position: absolute;
|
||||
right: 0;
|
||||
top: 50%;
|
||||
color: $gray-dark;
|
||||
padding: 10px 0 10px 10px;
|
||||
transform: translate3d(0, -50%, 0);
|
||||
&__clear,
|
||||
&__icon,
|
||||
&__button {
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.van-icon {
|
||||
display: block;
|
||||
}
|
||||
&__clear,
|
||||
&__icon {
|
||||
padding: 0 10px;
|
||||
color: $gray-dark;
|
||||
line-height: inherit;
|
||||
margin-right: -10px;
|
||||
}
|
||||
|
||||
&__icon .van-icon {
|
||||
display: block;
|
||||
font-size: 16px;
|
||||
line-height: inherit;
|
||||
}
|
||||
|
||||
&__button {
|
||||
@@ -68,10 +80,4 @@
|
||||
min-height: 60px;
|
||||
}
|
||||
}
|
||||
|
||||
&--has-icon {
|
||||
.van-field__control {
|
||||
padding-right: 20px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user