Problem/Motivation

Just prefer closing modals with the escape key.

Proposed resolution

Capture the keydown event and close the modal.

Remaining tasks

User interface changes

API changes

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

joelpittet’s picture

Here's a patch with that working.

joelpittet’s picture

Status: Active » Needs review
subhojit777’s picture

Thanks for the patch :) I was also thinking about the same.

joelpittet’s picture

Does it work for you?

subhojit777’s picture

I have not tested the code yet. Will do it soon. Thanks!

joelpittet’s picture

re-roll with latest dev changes.

subhojit777’s picture

Thank you :) Just a small change.

+++ b/js/dc_ajax_add_cart.js
@@ -1,9 +1,16 @@
+      function closeAddToCartOverlay() {

Can you please add a function description here.

joelpittet’s picture

Feel free to write what you want for the comment.

subhojit777’s picture

Status: Needs review » Fixed

Committed, thanks!

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.