index.axml 1.3 KB

1234567891011121314151617181920212223242526272829
  1. <view class='page-container-classname' ref='saveChildRef0'>
  2. <demo-block title='基础用法' ref='saveChildRef1'>
  3. <van-slider value='50' custom-class='slider' onChange='onChange' ref='saveChildRef2'>
  4. </van-slider>
  5. </demo-block>
  6. <demo-block title='指定选择范围' ref='saveChildRef3'>
  7. <van-slider custom-class='slider' min='-50' max='50' onChange='onChange' ref='saveChildRef4'>
  8. </van-slider>
  9. </demo-block>
  10. <demo-block title='禁用' ref='saveChildRef5'>
  11. <van-slider custom-class='slider' value='50' disabled=" " ref='saveChildRef6'>
  12. </van-slider>
  13. </demo-block>
  14. <demo-block title='指定步长' ref='saveChildRef7'>
  15. <van-slider custom-class='slider' value='50' step='10' onChange='onChange' ref='saveChildRef8'>
  16. </van-slider>
  17. </demo-block>
  18. <demo-block title='自定义样式' ref='saveChildRef9'>
  19. <van-slider value='50' custom-class='slider' bar-height='4px' active-color='#ee0a24' ref='saveChildRef10'>
  20. </van-slider>
  21. </demo-block>
  22. <demo-block title='自定义按钮' ref='saveChildRef11'>
  23. <van-slider value='{{ currentValue }}' custom-class='slider' use-button-slot=" " active-color='#ee0a24' onDrag='onDrag' ref='saveChildRef12'>
  24. <view class='custom-button' slot='button'>
  25. {{ currentValue }}
  26. </view>
  27. </van-slider>
  28. </demo-block>
  29. </view>