index.wxml 955 B

12345678910111213141516171819202122232425262728293031
  1. <view
  2. class="load-more wr-class"
  3. style="{{listIsEmpty && (status === 0 || status === 2) ? 'display: none' : '' }}"
  4. bindtap="tapHandle"
  5. >
  6. <!-- 加载中 -->
  7. <t-loading
  8. t-class="t-class-loading"
  9. t-class-text="t-class-loading-text"
  10. t-class-indicator="t-class-indicator"
  11. loading="{{status === 1}}"
  12. text="加载中..."
  13. theme="circular"
  14. size="40rpx"
  15. />
  16. <!-- 已全部加载 -->
  17. <t-divider wx:if="{{status === 2}}" t-class="t-class-divider" t-class-content="t-class-divider-content">
  18. <text slot="content">{{noMoreText}}</text>
  19. </t-divider>
  20. <!-- 加载失败 -->
  21. <view class="load-more__error" wx:if="{{status===3}}">
  22. 加载失败
  23. <text class="load-more__refresh-btn" bind:tap="tapHandle">刷新</text>
  24. </view>
  25. </view>
  26. <!-- 支持通过slot传入页面/列表的空态,load-more来控制空态的显示状态 -->
  27. <slot wx:if="{{listIsEmpty && (status === 0 || status === 2)}}" name="empty" />