Skip to content

Capture ESCAPE keypress #663

Closed
Closed
@rkyoku

Description

When pressing the ESCAPE key, lightbox closes itself. Nice! :)

However, it does not capture the event, which therefore bubbles up in another plugin I have, and I cannot modify the plugin code.

I will try and modify lightbox code instead, whilst waiting for an input on this one.

EDIT: more info: I am using MaterializeCSS modals. Inside some of them, I have some images that I use lightbox with. When lightbox is open on top of the modal and pressing the ESCAPE key (which closes the modal by default), lightbox should be the first to handle the event, and it should (IMHO) catch it and not let it propagate. That way, the modal does not closes whenever I close lightbox.

Thanks in advance!

Best,

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions