js double-click and tripple click listener

علی ذوالفقار
1402/04/17 14:28:02 (312)
double-click : 

window.addEventListener("dblclick", function(event) { }, false);

tripple-click
window.addEventListener('click', function (evt) {
    if (evt.detail === 3) {
        alert('triple click!');
    }
});
Back