This commit is contained in:
yanran200730
2022-06-16 10:46:46 +08:00
parent f8cbc8d5aa
commit 4bdd07b3ca
2 changed files with 9 additions and 3 deletions

View File

@@ -7,7 +7,7 @@
<div class="photo-footer">
<div class="title">
<span @click="back">返回</span>
<h2>裁剪</h2>
<h2>图片处理</h2>
<span class="save-btn" @click="save">保存</span>
</div>
<scroll-view class="photo-bottom" scroll-x >
@@ -17,7 +17,7 @@
</div> -->
<div class="clipping-item" @click="currIndex = 1" :class="[currIndex === 1 ? 'active' : '']">
<image src="./images/clipping/clipping5.png" />
<span>自由</span>
<span>自由缩放</span>
</div>
<!-- <div class="clipping-item" @click="currIndex = 2" :class="[currIndex === 2 ? 'active' : '']">
<image src="./images/clipping/clipping4.png" />
@@ -80,6 +80,10 @@
uni.$emit('cropper', e.path)
this.back()
},
rotateAngle () {
this.$refs.Cropper.rotateAngle()
}
}
}

View File

@@ -1,5 +1,5 @@
<template>
<view v-show="url" :mode="modeValue" :change:mode="mwx.changeMode" :rotate="rotate" :change:rotate="mwx.changeRotate">
<view style="width: 100%; height: 100%; position: relative;" v-show="url" :mode="modeValue" :change:mode="mwx.changeMode" :rotate="rotate" :change:rotate="mwx.changeRotate">
<!-- #ifdef MP-WEIXIN -->
<canvas type="2d" class="canvas" :style="{width: target.width + 'px', height: target.height + 'px'}"></canvas>
<!-- #endif -->
@@ -785,6 +785,8 @@ export default {
<style scoped>
.panel {
position: absolute;
top: 0;
width: 100%;
height: 100%;
overflow: hidden;