Swipeout fires wrong events on _first_ click


Dear all,
if have the following issue that swipeout fires events (swipeout/swipeout:close) on first click. I am using Windows10/Chrome for development:


	<ul id="id_list">
	   <li class="swipeout">
	      <div class="swipeout-content">
	         <a href="#" data-callback="item" class="item-link item-content">
	            <div class="item-inner">
	               <div class="item-title">test</div>
	     <div class="swipeout-actions-left">
	        <a href="#" class="color-blue">
	           <i class="f7-icons">compose</i>
	        <a href="#" class="color-red">
	           <i class="f7-icons">close_round</i>

JS Code

	$('#id_list').on('swipeout:close', 'li', function () {
		console.info("event swipeout:close");
	$('#id_list').on('swipeout', 'li', function () {
		console.info("event swipeout");
	$('#id_list').on('click', 'a', function () {
		console.info("event click");

On the first click I receive the following events:
event swipeout
event swipeout close
event click

Afterwards I receive for all events
event click

So, it seems that at the beginning something is not initalized!
I used a delegated event handler since li object are added dynamically.

Best regards


It doesn’t mean to work correct on desktop with mouse events. Do you have same issue if you are in device emulation mode?


Funny: in case of device emulation mode everything is perfect. I just receive the click event in case if I click on the elements.

When turn off the device emulation mode (without reloading the page), everthing still works (clicking -> click events)

But reloading the page (device emulation mode off) causes the same issue (1st click > swipeout, close and click events; all clicks afterwards -> click event).

So it seems that the first mouse event is handled different than a touch event. But a touch event results in initialize something…

Best regards


Additional finding: it seems that after calling “app.swipeout.close” the same issue is caused:

device emulation mode = off

n-th mouse click > just a “click” (a) event is triggered
(n+1)-th mouse click > “swipeout” (li), “swipeout:close” (li) and “click” (a) is triggered
(n+2)-th mouse clicke > “click” (a) event is triggered

device emulation mode = on
n-th touch > “click” (a) event
(n+1)-th touch > “click” (a) event

My assumption would be that the behavious is the same and should be like with device emulation mode enabled, correct? Is it a bug?

I am using “chrome” (windows 10), 64.0.3282.186 (64-Bit)