f7-list-item(title="Swipe" swipeout @click="onItemClick(item)")
I don’t want to trigger click event when I use swipe gesture. Possible?
f7-list-item(title="Swipe" swipeout @click="onItemClick(item)")
I don’t want to trigger click event when I use swipe gesture. Possible?
try like this.
if (Dom7(.swipeout-opened).length) e.preventDefault()
It is impossible to prevent it on Desktop (with mouse), on touch devices (iOS, Android), click event won’t be triggered
Thats good news.
Any ideas how i can achieve this behavior on a desktop version? During development in a browser?
Now I’m gonna catch mouse up/down events and compare x-y-coordinates…
Just switch to touch events by enabling some mobile device (iOS or Android) emulation and reloading the browser
Oh shi
A already tried enabling mobile emulation but didn’t reload the browser)
Thx a lot
I could fix it by using the swipeout open and closed events.
<ListItem
on:swipeoutOpen={e => {
swipingout = true;
}}
on:swipeoutClosed={e => {
swipingout = false;
}}
swipeout
on:click={e => {
if (!swipingout) {
f7router.navigate(’/Order/’ + order.id);
}
}}