picker-item.wxml 735 B

12345678910111213141516171819202122232425
  1. <wxs src="../common/utils.wxs" module="_" />
  2. <view
  3. style="{{_._style([style, customStyle])}}"
  4. class="{{_.cls(classPrefix + '__group', [])}} class {{prefix}}-class"
  5. bind:touchstart="onTouchStart"
  6. catch:touchmove="onTouchMove"
  7. bind:touchend="onTouchEnd"
  8. bind:touchcancel="onTouchEnd"
  9. >
  10. <view
  11. class="{{classPrefix}}__wrapper"
  12. style="transition: transform {{ duration }}ms cubic-bezier(0.215, 0.61, 0.355, 1); transform: translate3d(0, {{ offset }}px, 0)"
  13. >
  14. <view
  15. class="{{_.cls(classPrefix + '__item', [['active', curIndex == index]])}}"
  16. wx:for="{{options}}"
  17. wx:key="index"
  18. wx:for-item="option"
  19. data-index="{{ index }}"
  20. >
  21. {{option.label}}
  22. </view>
  23. </view>
  24. </view>