Touche echap $(document).on('keydown', function(event) { if (event.key == "Escape") { $('.popup-ptf-close').click(); } });