index.axml 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. <import-sjs
  2. from="./index.sjs"
  3. name="utils" />
  4. <view
  5. class="ant-steps ant-steps-{{ direction }} {{ className || '' }}"
  6. style="{{ style }}">
  7. <block
  8. a:for="{{ items }}"
  9. a:for-index="index"
  10. a:for-item="item">
  11. <view
  12. class="ant-steps-item ant-steps-item-{{ direction }} {{ index < current ? 'ant-steps-item-finish' : '' }} {{ index === current ? 'ant-steps-item-active' : '' }} {{ index > current ? 'ant-steps-item-non-active' : '' }}">
  13. <view
  14. class="ant-steps-item-indicator ant-steps-item-indicator-{{ direction }}">
  15. <view
  16. class="ant-steps-item-indicator-icon ant-steps-item-{{ utils.getClassName(current, index, status) }}-icon">
  17. <slot
  18. name="icon"
  19. value="{{ item }}"
  20. index="{{ index }}"
  21. current="{{ current }}"
  22. status="{{ status }}">
  23. <view
  24. class="ant-steps-item-{{ utils.getClassName(current, index, status) }}-icon-default" />
  25. </slot>
  26. </view>
  27. </view>
  28. <view class="ant-steps-item-text">
  29. <view
  30. class="ant-steps-item-title ant-steps-item-title-{{ utils.getClassName(current, index, status) }}">
  31. <slot
  32. name="title"
  33. value="{{ item }}"
  34. index="{{ index }}">
  35. {{ item.title }}
  36. </slot>
  37. </view>
  38. <view class="ant-steps-item-desc">
  39. <slot
  40. name="description"
  41. value="{{ item }}"
  42. index="{{ index }}">
  43. {{ item.description }}
  44. </slot>
  45. </view>
  46. </view>
  47. </view>
  48. </block>
  49. </view>