index.wxml 1.0 KB

123456789101112131415161718192021222324
  1. <view class="wux-class {{ classes.wrap }}" style="{{ style }}" bindtap="onTap" wx:if="{{ status !== 'unmounted' }}">
  2. <view class="{{ classes.inner }}">
  3. <image class="{{ classes.thumb }}" lazy-load="{{ lazyLoad }}" mode="{{ mode }}" src="{{ src }}" bindload="onLoad" binderror="onError" wx:if="{{ src }}" />
  4. <slot></slot>
  5. </view>
  6. <view class="{{ classes.mask }}" wx:if="{{ status === 'empty' }}">
  7. <view class="{{ classes.text }}" wx:if="{{ empty }}">{{ empty }}</view>
  8. <block wx:else>
  9. <slot name="empty"></slot>
  10. </block>
  11. </view>
  12. <view class="{{ classes.mask }}" wx:elif="{{ status === 'loading' }}">
  13. <view class="{{ classes.text }}" wx:if="{{ loading }}">{{ loading }}</view>
  14. <block wx:else>
  15. <slot name="loading"></slot>
  16. </block>
  17. </view>
  18. <view class="{{ classes.mask }}" wx:elif="{{ status === 'error' }}">
  19. <view class="{{ classes.text }}" wx:if="{{ error }}">{{ error }}</view>
  20. <block wx:else>
  21. <slot name="error"></slot>
  22. </block>
  23. </view>
  24. </view>