Skip to content

ESC/Escape key closes containing jQueryUI dialog when Chosen drop-down list is showing [jsFiddle provided] #1256

@BrandonLWhite

Description

@BrandonLWhite

When using a Chosen drop-down list inside of a jQueryUI dialog, an issue exists with the ESC/Escape key where if the user presses ESC while the drop-down list is showing (ie. results_showing==true) then instead of the drop-down list disappearing as expected, the entire containing dialog is canceled.

Please refer to this jsFiddle for a demonstration of the issue and a workaround fix.

This appears to stem from the dialog looking for ESC on keydown whereas Chosen is looking for ESC on keyup.

Hopefully there is a more elegant way to resolve this, ideally from within Chosen and not externally as shown in my demo.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions