[improvement] Icon: optimize image icon style (#1840)

This commit is contained in:
neverland 2019-08-07 15:45:59 +08:00 committed by GitHub
parent dfdc001ea3
commit 73c3285603
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 8 deletions

View File

@ -8,14 +8,8 @@
} }
&__image { &__image {
position: absolute; width: 100%;
top: 0; height: 100%;
right: 0;
bottom: 0;
left: 0;
max-width: 100%;
max-height: 100%;
margin: auto;
} }
&__info { &__info {

View File

@ -13,6 +13,7 @@
<image <image
wx:if="{{ utils.isSrc(name) }}" wx:if="{{ utils.isSrc(name) }}"
src="{{ name }}" src="{{ name }}"
mode="aspectFit"
class="van-icon__image" class="van-icon__image"
/> />
</view> </view>