resize.wxml 2.3 KB

1234567891011121314151617181920212223242526272829303132
  1. <!--pages/image/resize.wxml-->
  2. <view style="width:100%;height:500rpx;">
  3. <image-cropper id="image-cropper" bindload="cropperload" bindimageload="loadimage" bindtapcut="clickcut" limit_move="{{limit_move}}" disable_rotate="{{disable_rotate}}" width="{{width}}" height="{{height}}" imgSrc="{{src}}" angle="{{angle}}" disable_width="{{disable_width}}" max_width="{{max_width}}" max_height="{{max_height}}" disable_height="{{disable_height}}" disable_ratio="{{disable_ratio}}">
  4. </image-cropper>
  5. </view>
  6. <text class="hint">点击中间裁剪框可查看裁剪后的图片</text>
  7. <view class='bottom'>
  8. <!-- <text style='color:white;margin-right:5rpx;'>锁定裁剪框宽</text>
  9. <switch checked='{{disable_width?true:false}}' bindchange="switchChangeDisableWidth" />
  10. <text style='color:white;margin-right:5rpx;'>锁定裁剪框高</text>
  11. <switch checked='{{disable_height?true:false}}' bindchange="switchChangeDisableHeight" />
  12. <button bindtap='submit'>确定</button>
  13. <text style='color:white;margin-right:5rpx;'>锁定比例</text>
  14. <switch checked='{{disable_ratio?true:false}}' bindchange="switchChangeDisableRatio" />
  15. <text></text>
  16. <text style='color:white;margin-right:5rpx;'>锁定旋转</text>
  17. <switch checked='{{disable_rotate?true:false}}' bindchange="switchChangeDisableRotate" />
  18. <text style='color:white;margin-right:5rpx;'>限制移动</text>
  19. <switch checked='{{limit_move?true:false}}' bindchange="switchChangeLimitMove" /> -->
  20. <!-- <button class="button" catchtouchstart='top' catchtouchend='end' data-type="top">上</button>-->
  21. <!-- <button class="button" catchtouchstart='bottom' catchtouchend='end' data-type="bottom">下</button>-->
  22. <!-- <button class="button" catchtouchstart='left' catchtouchend='end' data-type="left">左</button>-->
  23. <!-- <button class="button" catchtouchstart='right' catchtouchend='end' data-type="right">右</button>-->
  24. <button class="button" catchtouchstart='enlarge' catchtouchend='end' data-type="enlarge">放大</button>
  25. <button class="button" catchtouchstart='narrow' catchtouchend='end' data-type="narrow">缩小</button>
  26. <button class="button" catchtouchstart='rotate' catchtouchend='end' data-type="rotate">旋转</button>
  27. <view>
  28. <wux-button block type="light" bindtap='submit'>确定</wux-button>
  29. </view>
  30. </view>