This should be the real fix for the even recursion

There's a bogus duplicated mouse event for a.silence-duration-btn, which I added to fix css issues, get rid of it and replace with proper css selectors. And with that drop the event.stopPropagation call as it shouldn't be needed anymore
This commit is contained in:
Łukasz Mierzwa
2017-04-26 16:56:54 -07:00
parent efa1c2025b
commit 0e7fe10b46
3 changed files with 9 additions and 6 deletions

View File

@@ -436,8 +436,15 @@ table.table.silence-label-selects > tbody > tr > td {
font-size: 2em;
}
.silence-duration-btn:hover {
color: #fff;
background: #eee;
}
.silence-duration-btn:focus {
color: #18bc9c;
}
.silence-duration-btn:focus:hover {
color: #fff;
}
.silence-duration-btn > i {
pointer-events: none;
}

View File

@@ -205,9 +205,6 @@ var UI = (function(params) {
}
$("#endsAt").data('DateTimePicker').date(endsAt);
silenceFormCalculateDuration();
// prevent recursive events
event.stopPropagation();
};
@@ -313,7 +310,6 @@ var UI = (function(params) {
$("#endsAt").data('DateTimePicker').minDate(startsAt);
});
modal.on("click", "a.silence-duration-btn", silenceFormUpdateDuration);
modal.on("mousedown", "a.silence-duration-btn", false);
silenceFormCalculateDuration();
}
});

File diff suppressed because one or more lines are too long