[improvement] Icon: use image component to display image (#3515)

This commit is contained in:
neverland
2019-06-14 20:16:55 +08:00
committed by GitHub
parent 7fbf943a2d
commit 09707479eb
3 changed files with 21 additions and 24 deletions
+1 -12
View File
@@ -2,19 +2,8 @@
@import '@vant/icons/src/index.less';
.van-icon {
&--image {
&__image {
width: 1em;
height: 1em;
img {
position: absolute;
top: 0;
right: 0;
bottom: 0;
left: 0;
max-width: 100%;
max-height: 100%;
margin: auto;
}
}
}