index.wxml 520 B

1234567891011121314151617181920
  1. <wxs src="../wxs/utils.wxs" module="utils" />
  2. <view
  3. class="custom-class {{ classPrefix }} {{ isImageName ? 'van-icon--image' : classPrefix + '-' + name }}"
  4. style="color: {{ color }};font-size: {{ utils.addUnit(size) }};{{ customStyle }}"
  5. bind:tap="onClick"
  6. >
  7. <van-info
  8. wx:if="{{ info !== null || dot }}"
  9. dot="{{ dot }}"
  10. info="{{ info }}"
  11. custom-class="van-icon__info"
  12. />
  13. <image
  14. wx:if="{{ isImageName }}"
  15. src="{{ name }}"
  16. mode="aspectFit"
  17. class="van-icon__image"
  18. />
  19. </view>