swiper 轮播图圆角滑动变会变成直角然后再回到圆角
发布于 4 年前 作者 min81 12010 次浏览 来自 问答

你好,我用swiper 实现轮播图 swiper圆角 图片滑动的时候会先变成直角然后变成圆角,怎么解决?

5 回复

给swiper外层套一个view设置border-radius和overflow:hidden应该就可以了

lz解决了吗?我也在烦恼这个问题中

在swiper上加overflow:hidden 和transform: translateY(0);,亲测有效

刚好看到,写一个自己的解决方法给大家参考。

<!-- { start -->
 
<view class="控制阴影">
    <view style="border-radius: 16rpx;overflow: hidden;">
        <swiper>...</swiper>
    </view>
</view>
  
<!-- end } -->

真机没有圆角参考:

https://developers.weixin.qq.com/community/develop/doc/00026658428810dd8c07c062556400

?怎么解决还是怎么实现

回到顶部