I thought that some events were disabled by mui, so I deleted the css and Js of mui first, but it didn"t work either.
later I thought that there was something wrong with the package, so I used private network penetration to test!
the result is that there is no problem with picture rotation, but zooming is not allowed! double-click on mobile is also not allowed
<script>
/**/
import "swiper/dist/css/swiper.css"////
import { swiper, swiperSlide } from "vue-awesome-swiper"
export default {
name: "detail",
components: {swiper, swiperSlide},
data() {
return {
swiperOption: {
zoom: {
maxRatio: 10, //
minRatio: 2, //
toggle: true, //
},
},
};
},
computed: {
swiper() {
return this.$refs.mySwiper.swiper
}
},
mounted() {
console.log(this.swiper.zoom.enabled);
console.log(this.swiper.zoom.scale);
this.swiper.slideTo(3, 1000, false)
}
}
</script>