uni-swipe-action 滑动操作 使用插槽多操作时IOS上操作错位

通过在touchend事件上添加.stop.prevent修饰符如@touchend.stop.prevent=handleBtnClick可以解决点击后不关闭问题,但需在navigateTo的success回调中调用this.$refs.swipeAction.closeAll()手动关闭所有滑动操作项。
摘要由CSDN通过智能技术生成

使用@touchend.stop="handleBtnClick"可以解决这个问题,但不会自动收回去,在navigateTo的success方法中调用this.$refs.swipeAction.closeAll()就可以了。

<uni-swipe-action ref="swipeAction" >
	<uni-swipe-action-item
		style="margin-bottom: 24rpx;"
	        v-for="(item, index) in dataList"
			:key="index">
			<view class="item_wrapper"
                //页面
			</view>
			<template v-slot:right>
			    <view class="slot_btn">
					<view class="slot-section edit-btn" @touchend.stop.prevent="goEdit(item,index)">
						编辑
					</view>
                    <view class="slot-section delete-btn" @touchend.stop.prevent="deleteCruise(item,index)">
						删除
					</view>
				</view>
			</template>
	</uni-swipe-action-item>
</uni-swipe-action>

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值