index.wxml 1.0 KB

1234567891011121314151617181920
  1. <view class="custom-class van-steps van-steps--{{ direction }}">
  2. <view class="van-step__wrapper">
  3. <view
  4. wx:for="{{ steps }}"
  5. wx:key="index"
  6. class="van-step van-hairline van-step--{{ direction }} {{ item.status ? 'van-step--' + item.status : '' }}"
  7. style="{{ width ? 'width:' + width + 'px' : '' }}"
  8. >
  9. <view class="van-step__title" style="{{ item.status === 'process' ? 'color: ' + activeColor : '' }}">
  10. <view>{{ item.text }}</view>
  11. <view>{{ item.desc }}</view>
  12. </view>
  13. <view class="van-step__circle-container">
  14. <view class="van-step__circle" wx:if="{{ item.status !== 'process' }}" style="{{ item.status === 'finish' ? 'background-color: ' + activeColor : '' }}" />
  15. <van-icon wx:else name="checked" color="{{ activeColor }}" custom-class="van-step__active" />
  16. </view>
  17. <view wx:if="{{ index !== steps.length - 1 }}" class="van-step__line" style="{{ item.status === 'finish' ? 'background-color: ' + activeColor : '' }}" />
  18. </view>
  19. </view>
  20. </view>