Skip to content

Close modal on escape key #41

@drjjw

Description

@drjjw

I added this code to close the video modal on pressing escape key:

jQuery(document).keyup(function(e) { if (e.keyCode == 27) { // Esc jQuery(".modal-video-close-btn.js-modal-video-dismiss-btn").trigger("click") } });

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions