icon.wxml 557 B

123456789101112131415
  1. <wxs src="../common/utils.wxs" module="_" />
  2. <view
  3. class="{{ prefix ? prefix : classPrefix}} class {{componentPrefix}}-class"
  4. style="{{_._style([iconStyle, style, customStyle])}}"
  5. bind:tap="onTap"
  6. aria-hidden="{{ariaHidden}}"
  7. aria-label="{{ariaLabel}}"
  8. aria-role="{{ariaRole}}"
  9. >
  10. <view wx:if="{{ isImage }}" class="{{classPrefix}}--image">
  11. <image src="{{ name }}" mode="aspectFit" class="{{classPrefix}}__image" />
  12. </view>
  13. <label wx:else class="{{ prefix ? prefix : classPrefix }}-{{ name }} {{ classPrefix }}-base"> </label>
  14. </view>